Crypto Dashboard for React
A crypto and finance dashboard template for React with candlesticks, live prices and a portfolio breakdown. Use it as a portfolio dashboard for a crypto or brokerage screen where the balance chart can be scrubbed to roll the big number to any moment or dragged to measure a move.
npx shadcn@latest add https://lokendra-builds.github.io/sheenui/r/analytics-demo-finance.jsonPortfolio
last 7 days
CascadeFinanceDashboarduseCascadedefaultFinanceLabels- +2 more
Live portfolio
Hover the balance chart and the big number rolls to that moment; drag across it to measure a move (on touch: hold, then drag). Pick an asset in the watchlist to load its candles. Prices tick live with rolling digits.
Markets & holdings
Your balance, how each holding moves and every trade, with live prices.
Total balance
Price history
Price candles and volume. Pick another asset in the watchlist.
Allocation
Watchlist
Live prices · 24h change
Transactions
Every trade, transfer and payout in the range.
import { FinanceDashboard } from "@/components/sheenui/blocks/analytics-finance";
// Package build (after the first npm release, or a packed tarball): import { FinanceDashboard } from "@sheenui/theme";
import { financeDemoLoader, financeLiveStep } from "@/components/sheenui/blocks/analytics/demo-finance";
// Package build (after the first npm release, or a packed tarball): import { financeDemoLoader, financeLiveStep } from "@sheenui/theme/demo-data";
export function Portfolio() {
return <FinanceDashboard load={financeDemoLoader} liveStep={financeLiveStep} headingLevel={3} />;
}Files to copy
21 folders · 54 files · 4 packages
- From
theme/src/ blocks/{analytics-finance.tsx, analytics-kit.ts, icons.tsx}components/button/components/charts/{candlestick-chart.tsx, category-bar.tsx, chart-export-menu.tsx, chart-export.ts, chart-figure.tsx, chart-fit.tsx, chart-icons.tsx, chart-parts.tsx, chart-patterns.tsx, chart-pointer.tsx, chart-tip.tsx, chart-utils.ts, donut-chart.tsx, flow-utils.tsx, heatmap.tsx, sparkline.tsx, treemap.tsx}components/charts/candlestick-chart/components/charts/category-bar/components/charts/chart-parts/components/charts/heatmap/components/drawer/parts/sheet.tsxcomponents/kbd/components/menu/components/segmented/components/skeleton/components/spinner/components/status-icons/components/tabs/blocks/analytics-finance/blocks/analytics/{bar-trend-chart.tsx, data.ts, glass.tsx, hooks.tsx, kpi.tsx, labels.ts, panel.tsx, shell.tsx, stacked-trend-chart.tsx, trend-chart.tsx, trend-frame.tsx}hooks/{use-controllable.ts, use-direction.ts, use-intersection.ts, use-latest.ts, use-magnetic.ts, use-media-query.ts, use-preferences.ts, use-resolved-scheme.ts}motion/{beat.ts, gate.ts, tokens.ts}lib/{cn.ts, csv.ts, form.ts, glide-highlight.tsx, heading.ts, math.ts, no-script-reveal.tsx, popup-a11y.ts, popup-motion.ts, state-light.tsx, warn-once.ts}styles/
- shadcn CLI (component only)
npx shadcn@latest add https://lokendra-builds.github.io/sheenui/r/analytics-finance.jsonRegistry item: analytics-finance. The styles need the Tailwind v4 glass UI setup.- Packages
pnpm add @base-ui/react clsx motion tailwind-merge
Next.js: samples here pass functions (formatters, seriesLegend, a dashboard's load), so put them in a file that starts with "use client".
Euro, German formatting, stocks only
Every number and date follows the locale and currency; filters, the asset and Compare can start pre-set.
Aktien & ETFs
Kurse, Verlauf und Käufe der letzten 12 Monate.
Total balance
Price history
Price candles and volume. Pick another asset in the watchlist.
Allocation
Watchlist
Live prices · 24h change
Transactions
Every trade, transfer and payout in the range.
import { FinanceDashboard } from "@/components/sheenui/blocks/analytics-finance";
// Package build (after the first npm release, or a packed tarball): import { FinanceDashboard } from "@sheenui/theme";
import { financeDemoLoader, financeLiveStep } from "@/components/sheenui/blocks/analytics/demo-finance";
// Package build (after the first npm release, or a packed tarball): import { financeDemoLoader, financeLiveStep } from "@sheenui/theme/demo-data";
<FinanceDashboard
load={financeDemoLoader}
liveStep={financeLiveStep}
locale="de-DE"
currency="EUR"
defaultRange="12m"
defaultClasses={["stocks", "etf"]}
defaultAsset="NWT"
defaultCompare
labels={{ title: "Aktien & ETFs", description: "Kurse, Verlauf und Käufe der letzten 12 Monate." }}
/>Loading, empty and error states
Your own `load` drives the dashboard. Try a slow network, an empty account and a failed request.
Portfolio from your API
Your balance, how each holding moves and every trade, with live prices.
Total balance
Price history
Price candles and volume. Pick another asset in the watchlist.
Allocation
Watchlist
Live prices · 24h change
Transactions
Every trade, transfer and payout in the range.
import { FinanceDashboard } from "@/components/sheenui/blocks/analytics-finance";
import { type FinanceQuery } from "@/components/sheenui/blocks/analytics-finance/model";
// Package build (after the first npm release, or a packed tarball): import { FinanceDashboard, type FinanceQuery } from "@sheenui/theme";
// `load` receives { range, classes, now }; return the data or a promise of it.
async function load(query: FinanceQuery) {
const res = await fetch(`/api/portfolio?range=${query.range}&classes=${query.classes.join(",")}`);
if (!res.ok) throw new Error(res.statusText);
return res.json();
}
<FinanceDashboard load={load} defaultLive={false} labels={{ title: "Portfolio from your API" }} />Data
load is required: FinanceDashboard never invents numbers. Return your own data (or a promise of it) from load. For demos and prototypes use the sample loader and live step from the separate @sheenui/theme/demo-data module:
import { FinanceDashboard } from "@/components/sheenui/blocks/analytics-finance";
// Package build (after the first npm release, or a packed tarball): import { FinanceDashboard } from "@sheenui/theme";
import { financeDemoLoader, financeLiveStep } from "@/components/sheenui/blocks/analytics/demo-finance";
// Package build (after the first npm release, or a packed tarball): import { financeDemoLoader, financeLiveStep } from "@sheenui/theme/demo-data";
<FinanceDashboard load={financeDemoLoader} liveStep={financeLiveStep} />With the shadcn CLI the sample data is its own optional item, which also installs the dashboard (the “with demo data” command at the top of this page): npx shadcn@latest add https://lokendra-builds.github.io/sheenui/r/analytics-demo-finance.json. The “component only” command under Files to copy leaves the sample data out, which is what a production build wants.
Props
FinanceLabels keys and English defaults (60)
Data: FinanceData
Keyboard
Accessibility
- The balance chart is keyboard-readable and announces each value (and the start and end of a measurement); the Table tab lists every point.
- Watchlist rows are toggle buttons (aria-pressed) whose name says the asset, its price and its 24-hour change; the price flash is decorative.
- Up / down is never color alone: candles are hollow or filled, badges carry arrows and signs, statuses carry icons and words.
- Prices tick visually only (no announcement per tick); the Live switch pauses them, and they stop off-screen and in background tabs.
- Reduced motion: no rolling digits, flashes, draw-ins or pings; data changes appear at once.
- The transactions table scrolls inside its own focusable region with a sticky header, so the page never scrolls sideways on phones.
Dashboard kit (analytics-kit.tsx)
Cascade props
All exports on this page
Cascade— Render-prop form of useCascade: only this wrapper re-renders when its turn comes, so the parent (and its other panels) stay untouched.FinanceDashboard— A finance / crypto dashboard: portfolio balance with a scrub-and-measure area chart, candles with volume for the selected asset.defaultFinanceLabels— The English FinanceLabels used when labels is omitted; a partial labels prop is merged over them.useCascade— Hands value on after index × step ms, in a transition: when a dashboard's data changes, its panels take the new data one after another.
When to use the crypto dashboard
- Use it for the home screen of a trading or wallet app, where the balance chart is scrubbed to read the figure at any moment, or dragged to measure the gain between two points.
- Use it for a trading watchlist with live ticking prices, candles with volume for the selected asset, and allocation as a donut or treemap beside a transactions table.
- Use currency, locale, defaultClasses and defaultAsset to start on euros in German formatting with stocks and ETFs only and a chosen symbol like NWT.
- Skip it when you need order entry or exchange-grade depth charts; this block is read-only analytics, so build trading forms with Input and Button, and use another chart for order books.
- Pair it with CandlestickChart, DonutChart and Sparkline for custom panels, SegmentedControl for the range, and NumberTicker for any extra price figures you add.
Frequently asked questions
Related pages
5 dashboards pages in all: browse them on All dashboards.
By Lokendra Singh Rathore (GitHub, opens in a new tab). Published , updated .