From 2d9890a70cf9d5b39f4f6d5828e7d4ccc3975db8 Mon Sep 17 00:00:00 2001 From: Aditya Arora Date: Tue, 30 Sep 2025 11:37:42 +0530 Subject: [PATCH 1/2] chore(dev-hub)-core-landing page --- .../src/app/price-feeds/core/page.tsx | 7 + .../src/components/Core/architecture-tabs.tsx | 124 ++++++++++++++++++ .../Pages/CoreLandingPage/index.tsx | 114 ++++++++++++++++ 3 files changed, 245 insertions(+) create mode 100644 apps/developer-hub/src/app/price-feeds/core/page.tsx create mode 100644 apps/developer-hub/src/components/Core/architecture-tabs.tsx create mode 100644 apps/developer-hub/src/components/Pages/CoreLandingPage/index.tsx diff --git a/apps/developer-hub/src/app/price-feeds/core/page.tsx b/apps/developer-hub/src/app/price-feeds/core/page.tsx new file mode 100644 index 0000000000..88b28fda10 --- /dev/null +++ b/apps/developer-hub/src/app/price-feeds/core/page.tsx @@ -0,0 +1,7 @@ +import { CoreLandingPage } from "../../../components/Pages/CoreLandingPage" + +export default function Page() { + return +} + + diff --git a/apps/developer-hub/src/components/Core/architecture-tabs.tsx b/apps/developer-hub/src/components/Core/architecture-tabs.tsx new file mode 100644 index 0000000000..cc302b1d2c --- /dev/null +++ b/apps/developer-hub/src/components/Core/architecture-tabs.tsx @@ -0,0 +1,124 @@ +"use client" + +import { TabList } from "@pythnetwork/component-library/TabList" +import { Tabs as UnstyledTabs } from "@pythnetwork/component-library/unstyled/Tabs" +import { Button } from "@pythnetwork/component-library/Button" +import { ArrowRight as ArrowRightIcon } from "@phosphor-icons/react/dist/ssr" +import { useState } from "react" + +type TabId = "pull" | "pusher" | "historical" + +export function ArchitectureTabs() { + const [activeTab, setActiveTab] = useState("pull") + + function renderDiagram() { + if (activeTab === "historical") { + return ( +
+
+
📊
+
Historical Data
+
+
+ ) + } + + const nodes = activeTab === "pull" + ? ["Publishers", "Pythnet", "User", "Your Contract"] + : ["Publishers", "Pythnet", "Price Pusher", "Your Contract"] + + return ( +
+ + {nodes.map((label, i) => { + const x = 80 + i * 240 + return ( + + + {label} + + ) + })} + {[0,1,2].map(i => { + const x1 = 80 + i * 240 + 70 + const x2 = 80 + (i+1) * 240 - 70 + const points = `${String(x2 - 10)},63 ${String(x2 - 10)},73 ${String(x2)},68` + return ( + + + + + ) + })} + +
+ ) + } + + function renderContent() { + if (activeTab === "pull") return ( +
+

+ Publishers stream signed updates to Pythnet roughly every 400 ms. Your app pulls and verifies + prices on demand, then your contract updates via updatePriceFeeds. +

+ +
+ ) + + if (activeTab === "pusher") return ( +
+

+ Automate on-chain updates using a Price Pusher. It listens to Pythnet and pushes fresh prices to + your contracts on your chosen schedule and conditions. +

+ +
+ ) + + if (activeTab === "historical") return ( +
+

+ Explore cryptographically verifiable historical prices for auditing, analytics, and backtesting. +

+ +
+ ) + + return null + } + + const items = [ + { id: "pull", href: "#pull", children: "Pull", onPress: () => { setActiveTab("pull") } }, + { id: "pusher", href: "#pusher", children: "Price Pusher", onPress: () => { setActiveTab("pusher") } }, + { id: "historical", href: "#historical", children: "Historical", onPress: () => { setActiveTab("historical") } }, + ] + + return ( +
+ + + + +
+
+ {renderDiagram()} +
+
+ {renderContent()} +
+
+
+ ) +} + + diff --git a/apps/developer-hub/src/components/Pages/CoreLandingPage/index.tsx b/apps/developer-hub/src/components/Pages/CoreLandingPage/index.tsx new file mode 100644 index 0000000000..b1b13ec733 --- /dev/null +++ b/apps/developer-hub/src/components/Pages/CoreLandingPage/index.tsx @@ -0,0 +1,114 @@ +"use client" + +import { ArrowRight as ArrowRightIcon } from "@phosphor-icons/react/dist/ssr" +import { Button } from "@pythnetwork/component-library/Button" + +import { ArchitectureTabs } from "../../Core/architecture-tabs" + +export function CoreLandingPage() { + return ( +
+
+
+
+

+ Real-Time Market Data, On-Chain +

+

+ Pyth Core delivers sub-second, signed prices across 100+ blockchains. Fetch live data, + automate updates using Price Pusher, and parse historical prices—all from one oracle network. +

+ +
+ + +
+
+
+
+ +
+
+

What is Pyth Core?

+

+ Pyth Core provides high-frequency, cryptographically signed price feeds that you can verify + on-chain. Publishers stream updates to Pythnet roughly every 400 ms. Your dApp pulls and + verifies prices whenever you need them. +

+
+
+ +
+
+

Integration Styles

+
+
+

Pull Oracle

+

+ The default approach: your dApp fetches and verifies prices on-demand whenever needed. +

+ +
+
+

Sponsored Updates

+

+ Automate price updates using a Price Pusher for push-like functionality with your own gas sponsorship. +

+ +
+
+
+
+ +
+
+

How it works

+ +
+
+ +
+
+

Why Pyth Core

+
+
+

Sub-second Data

+

Get signed prices refreshed every ~400 ms.

+
+
+

Verifiable

+

On-chain signature verification for trustless data.

+
+
+

Flexible Integration

+

Pull on demand or automate with a Price Pusher.

+
+
+

Historical Archive

+

Audit and backtest with cryptographically secure history.

+
+
+
+
+
+ ) +} + + From 672a4fe2d227f30c3c3f3577d3b9cc07e0dd2bcd Mon Sep 17 00:00:00 2001 From: Aditya Arora Date: Tue, 30 Sep 2025 20:33:53 +0530 Subject: [PATCH 2/2] chore(dev-hub) Fxies --- .../src/app/price-feeds/core/page.tsx | 6 +- .../src/components/Core/architecture-tabs.tsx | 213 ++++++++++++------ .../Pages/CoreLandingPage/index.tsx | 109 ++++++--- 3 files changed, 220 insertions(+), 108 deletions(-) diff --git a/apps/developer-hub/src/app/price-feeds/core/page.tsx b/apps/developer-hub/src/app/price-feeds/core/page.tsx index 88b28fda10..b21ac887d4 100644 --- a/apps/developer-hub/src/app/price-feeds/core/page.tsx +++ b/apps/developer-hub/src/app/price-feeds/core/page.tsx @@ -1,7 +1,5 @@ -import { CoreLandingPage } from "../../../components/Pages/CoreLandingPage" +import { CoreLandingPage } from "../../../components/Pages/CoreLandingPage"; export default function Page() { - return + return ; } - - diff --git a/apps/developer-hub/src/components/Core/architecture-tabs.tsx b/apps/developer-hub/src/components/Core/architecture-tabs.tsx index cc302b1d2c..fdd6fa45ee 100644 --- a/apps/developer-hub/src/components/Core/architecture-tabs.tsx +++ b/apps/developer-hub/src/components/Core/architecture-tabs.tsx @@ -1,15 +1,15 @@ -"use client" +"use client"; -import { TabList } from "@pythnetwork/component-library/TabList" -import { Tabs as UnstyledTabs } from "@pythnetwork/component-library/unstyled/Tabs" -import { Button } from "@pythnetwork/component-library/Button" -import { ArrowRight as ArrowRightIcon } from "@phosphor-icons/react/dist/ssr" -import { useState } from "react" +import { ArrowRight as ArrowRightIcon } from "@phosphor-icons/react/dist/ssr"; +import { Button } from "@pythnetwork/component-library/Button"; +import { TabList } from "@pythnetwork/component-library/TabList"; +import { Tabs as UnstyledTabs } from "@pythnetwork/component-library/unstyled/Tabs"; +import { useState } from "react"; -type TabId = "pull" | "pusher" | "historical" +type TabId = "pull" | "pusher" | "historical"; export function ArchitectureTabs() { - const [activeTab, setActiveTab] = useState("pull") + const [activeTab, setActiveTab] = useState("pull"); function renderDiagram() { if (activeTab === "historical") { @@ -17,108 +17,177 @@ export function ArchitectureTabs() {
📊
-
Historical Data
+
+ Historical Data +
- ) + ); } - const nodes = activeTab === "pull" - ? ["Publishers", "Pythnet", "User", "Your Contract"] - : ["Publishers", "Pythnet", "Price Pusher", "Your Contract"] + const nodes = + activeTab === "pull" + ? ["Publishers", "Pythnet", "User", "Your Contract"] + : ["Publishers", "Pythnet", "Price Pusher", "Your Contract"]; return (
- + {nodes.map((label, i) => { - const x = 80 + i * 240 + const x = 80 + i * 240; return ( - - {label} + + + {label} + - ) + ); })} - {[0,1,2].map(i => { - const x1 = 80 + i * 240 + 70 - const x2 = 80 + (i+1) * 240 - 70 - const points = `${String(x2 - 10)},63 ${String(x2 - 10)},73 ${String(x2)},68` + {[0, 1, 2].map((i) => { + const x1 = 80 + i * 240 + 70; + const x2 = 80 + (i + 1) * 240 - 70; + const points = `${String(x2 - 10)},63 ${String(x2 - 10)},73 ${String(x2)},68`; return ( - + - ) + ); })}
- ) + ); } function renderContent() { - if (activeTab === "pull") return ( -
-

- Publishers stream signed updates to Pythnet roughly every 400 ms. Your app pulls and verifies - prices on demand, then your contract updates via updatePriceFeeds. -

- -
- ) + if (activeTab === "pull") + return ( +
+

+ Publishers stream signed updates to Pythnet roughly every 400 ms. + Your app pulls and verifies prices on demand, then your contract + updates via updatePriceFeeds. +

+ +
+ ); - if (activeTab === "pusher") return ( -
-

- Automate on-chain updates using a Price Pusher. It listens to Pythnet and pushes fresh prices to - your contracts on your chosen schedule and conditions. -

- -
- ) + if (activeTab === "pusher") + return ( +
+

+ Automate on-chain updates using a Price Pusher. It listens to + Pythnet and pushes fresh prices to your contracts on your chosen + schedule and conditions. +

+ +
+ ); - if (activeTab === "historical") return ( -
-

- Explore cryptographically verifiable historical prices for auditing, analytics, and backtesting. -

- -
- ) + if (activeTab === "historical") + return ( +
+

+ Explore cryptographically verifiable historical prices for auditing, + analytics, and backtesting. +

+ +
+ ); - return null + return null; } const items = [ - { id: "pull", href: "#pull", children: "Pull", onPress: () => { setActiveTab("pull") } }, - { id: "pusher", href: "#pusher", children: "Price Pusher", onPress: () => { setActiveTab("pusher") } }, - { id: "historical", href: "#historical", children: "Historical", onPress: () => { setActiveTab("historical") } }, - ] + { + id: "pull", + href: "#pull", + children: "Pull", + onPress: () => { + setActiveTab("pull"); + }, + }, + { + id: "pusher", + href: "#pusher", + children: "Price Pusher", + onPress: () => { + setActiveTab("pusher"); + }, + }, + { + id: "historical", + href: "#historical", + children: "Historical", + onPress: () => { + setActiveTab("historical"); + }, + }, + ]; return (
- +
{renderDiagram()}
-
- {renderContent()} -
+
{renderContent()}
- ) + ); } - - diff --git a/apps/developer-hub/src/components/Pages/CoreLandingPage/index.tsx b/apps/developer-hub/src/components/Pages/CoreLandingPage/index.tsx index b1b13ec733..f185300317 100644 --- a/apps/developer-hub/src/components/Pages/CoreLandingPage/index.tsx +++ b/apps/developer-hub/src/components/Pages/CoreLandingPage/index.tsx @@ -1,9 +1,9 @@ -"use client" +"use client"; -import { ArrowRight as ArrowRightIcon } from "@phosphor-icons/react/dist/ssr" -import { Button } from "@pythnetwork/component-library/Button" +import { ArrowRight as ArrowRightIcon } from "@phosphor-icons/react/dist/ssr"; +import { Button } from "@pythnetwork/component-library/Button"; -import { ArchitectureTabs } from "../../Core/architecture-tabs" +import { ArchitectureTabs } from "../../Core/architecture-tabs"; export function CoreLandingPage() { return ( @@ -15,16 +15,23 @@ export function CoreLandingPage() { Real-Time Market Data, On-Chain

- Pyth Core delivers sub-second, signed prices across 100+ blockchains. Fetch live data, - automate updates using Price Pusher, and parse historical prices—all from one oracle network. + Pyth Core delivers sub-second, signed prices across 100+ + blockchains. Fetch live data, automate updates using Price Pusher, + and parse historical prices—all from one oracle network.

- -
@@ -36,38 +43,55 @@ export function CoreLandingPage() {

What is Pyth Core?

- Pyth Core provides high-frequency, cryptographically signed price feeds that you can verify - on-chain. Publishers stream updates to Pythnet roughly every 400 ms. Your dApp pulls and - verifies prices whenever you need them. + Pyth Core provides high-frequency, cryptographically signed price + feeds that you can verify on-chain. Publishers stream updates to + Pythnet roughly every 400 ms. Your dApp pulls and verifies prices + whenever you need them.

-

Integration Styles

+

+ Integration Styles +

-

Pull Oracle

+

+ Pull Oracle +

- The default approach: your dApp fetches and verifies prices on-demand whenever needed. + The default approach: your dApp fetches and verifies prices + on-demand whenever needed.

-

Sponsored Updates

+

+ Sponsored Updates +

- Automate price updates using a Price Pusher for push-like functionality with your own gas sponsorship. + Automate price updates using a Price Pusher for push-like + functionality with your own gas sponsorship.

-
+
-

How it works

+

+ How it works +

-

Why Pyth Core

+

+ Why Pyth Core +

-

Sub-second Data

-

Get signed prices refreshed every ~400 ms.

+

+ Sub-second Data +

+

+ Get signed prices refreshed every ~400 ms. +

-

Verifiable

-

On-chain signature verification for trustless data.

+

+ Verifiable +

+

+ On-chain signature verification for trustless data. +

-

Flexible Integration

-

Pull on demand or automate with a Price Pusher.

+

+ Flexible Integration +

+

+ Pull on demand or automate with a Price Pusher. +

-

Historical Archive

-

Audit and backtest with cryptographically secure history.

+

+ Historical Archive +

+

+ Audit and backtest with cryptographically secure history. +

- ) + ); } - -