@vllnt/ui 0.2.1-canary.06f0e84 → 0.2.1-canary.0aaaad2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/accordion/accordion.js +2 -2
- package/dist/components/activity-heatmap/activity-heatmap.js +15 -13
- package/dist/components/activity-log/activity-log.js +5 -5
- package/dist/components/agent-activity/agent-activity.js +8 -8
- package/dist/components/ai-artifact/ai-artifact.js +8 -8
- package/dist/components/ai-chat-input/ai-chat-input.js +2 -2
- package/dist/components/ai-message-bubble/ai-message-bubble.js +1 -1
- package/dist/components/ai-sidebar/ai-sidebar.js +4 -4
- package/dist/components/ai-source-citation/ai-source-citation.js +2 -2
- package/dist/components/ai-tool-call-display/ai-tool-call-display.js +4 -4
- package/dist/components/animated-text/animated-text.js +1 -4
- package/dist/components/auto-reload/auto-reload.js +14 -4
- package/dist/components/avatar/avatar.js +1 -1
- package/dist/components/avatar-group/avatar-group.js +4 -4
- package/dist/components/banner/banner.js +3 -3
- package/dist/components/bottom-activity-strip/bottom-activity-strip.js +1 -1
- package/dist/components/breadcrumb/breadcrumb.js +33 -26
- package/dist/components/button/button.js +1 -1
- package/dist/components/calendar/calendar.js +6 -6
- package/dist/components/callout/callout.js +1 -1
- package/dist/components/candlestick-chart/candlestick-chart.js +1 -1
- package/dist/components/canvas-shell/canvas-foundation-demo.js +4 -4
- package/dist/components/carousel/carousel.js +4 -4
- package/dist/components/chat-dock-section/chat-dock-section.js +1 -1
- package/dist/components/checkbox/checkbox.js +2 -2
- package/dist/components/checklist/checklist.js +3 -3
- package/dist/components/chronological-timeline/chronological-timeline.js +6 -5
- package/dist/components/civilization-card/civilization-card.js +1 -1
- package/dist/components/code-block/code-block.js +2 -2
- package/dist/components/code-playground/code-playground.js +8 -7
- package/dist/components/combobox/combobox.js +2 -2
- package/dist/components/command/command.js +1 -1
- package/dist/components/comment-pin/comment-pin.js +1 -1
- package/dist/components/comparison/comparison.js +9 -9
- package/dist/components/completion-dialog/completion-dialog.js +1 -1
- package/dist/components/content-intro/content-intro.js +7 -6
- package/dist/components/context-menu/context-menu.js +4 -4
- package/dist/components/conversation-thread/conversation-thread.js +8 -8
- package/dist/components/cookie-consent/cookie-consent.js +1 -1
- package/dist/components/copy-button/copy-button.js +3 -3
- package/dist/components/countdown-timer/countdown-timer.js +8 -7
- package/dist/components/credit-badge/credit-badge.js +1 -7
- package/dist/components/curriculum/curriculum.js +10 -10
- package/dist/components/data-list/data-list.js +1 -1
- package/dist/components/data-table/data-table.js +5 -4
- package/dist/components/date-picker/date-picker.js +1 -1
- package/dist/components/dialog/dialog.js +1 -1
- package/dist/components/dropdown-menu/dropdown-menu.js +3 -3
- package/dist/components/empty-state/empty-state.js +3 -3
- package/dist/components/exercise/exercise.js +4 -4
- package/dist/components/faq/faq.js +2 -2
- package/dist/components/file-upload/file-upload.js +3 -3
- package/dist/components/filter-bar/filter-bar.js +2 -1
- package/dist/components/flashcard/flashcard.js +1 -1
- package/dist/components/floating-action-button/floating-action-button.js +1 -1
- package/dist/components/floating-toolbar/floating-toolbar.js +1 -1
- package/dist/components/flow-diagram/flow-controls.js +9 -9
- package/dist/components/flow-diagram/flow-error-boundary.js +2 -2
- package/dist/components/flow-diagram/flow-fullscreen.js +2 -2
- package/dist/components/gantt-chart/gantt-chart.js +15 -13
- package/dist/components/handoff-beacon/handoff-beacon.js +1 -1
- package/dist/components/historic-timeline/historic-timeline.js +2 -2
- package/dist/components/historical-figure-card/historical-figure-card.js +4 -7
- package/dist/components/horizontal-scroll-row/horizontal-scroll-row.js +4 -4
- package/dist/components/input-otp/input-otp.js +1 -1
- package/dist/components/interactive-timeline/interactive-timeline.js +4 -4
- package/dist/components/jarvis-dock/jarvis-dock.js +2 -2
- package/dist/components/key-concept/key-concept.js +4 -4
- package/dist/components/keyboard-shortcuts-help/keyboard-shortcuts-help.js +2 -2
- package/dist/components/knowledge-check/knowledge-check.js +3 -3
- package/dist/components/learning-objectives/learning-objectives.js +12 -12
- package/dist/components/live-feed/live-feed.js +15 -13
- package/dist/components/map-2d/map-2d.js +2 -2
- package/dist/components/market-treemap/market-treemap.js +1 -1
- package/dist/components/mdx-content/mdx-content.js +2 -1
- package/dist/components/menubar/menubar.js +4 -4
- package/dist/components/metric-cluster/metric-cluster.js +1 -1
- package/dist/components/metric-gauge/metric-gauge.js +1 -1
- package/dist/components/model-comparison/model-comparison.js +2 -2
- package/dist/components/model-selector/model-selector.js +2 -2
- package/dist/components/multi-select/multi-select.js +3 -3
- package/dist/components/navbar-saas/navbar-saas.js +3 -2
- package/dist/components/navigation-menu/navigation-menu.js +2 -2
- package/dist/components/newsletter-signup/newsletter-signup.js +3 -3
- package/dist/components/number-input/number-input.js +1 -1
- package/dist/components/number-ticker/number-ticker.js +11 -4
- package/dist/components/object-inspector/object-inspector.js +1 -1
- package/dist/components/parallel-timeline/parallel-timeline.js +2 -2
- package/dist/components/password-input/password-input.js +1 -1
- package/dist/components/plan-badge/plan-badge.js +1 -7
- package/dist/components/presence-stack/presence-stack.js +2 -2
- package/dist/components/presence-sync-indicator/presence-sync-indicator.js +1 -1
- package/dist/components/pricing-table/pricing-table.js +3 -3
- package/dist/components/pro-tip/pro-tip.js +6 -6
- package/dist/components/profile-section/profile-section.js +1 -1
- package/dist/components/progress-card/progress-card.js +4 -3
- package/dist/components/progress-tracker/progress-tracker.js +7 -5
- package/dist/components/prompt-templates/prompt-templates.js +2 -2
- package/dist/components/quiz/quiz.js +5 -5
- package/dist/components/radio-group/radio-group.js +2 -2
- package/dist/components/rating/rating.js +3 -3
- package/dist/components/resizable/resizable.js +1 -1
- package/dist/components/runtime-overview-panel/runtime-overview-panel.js +1 -1
- package/dist/components/scope-selector/scope-selector.js +7 -7
- package/dist/components/search-bar/search-bar.js +24 -2
- package/dist/components/search-dialog/search-dialog.js +1 -1
- package/dist/components/select/select.js +5 -5
- package/dist/components/selection-halo/selection-halo.js +1 -1
- package/dist/components/severity-badge/severity-badge.js +2 -2
- package/dist/components/sheet/sheet.js +1 -1
- package/dist/components/sidebar/sidebar.js +1 -1
- package/dist/components/sidebar-toggle/sidebar-toggle.js +2 -2
- package/dist/components/slider/slider.js +1 -1
- package/dist/components/slideshow/slideshow.js +12 -11
- package/dist/components/social-fab/social-fab.js +2 -1
- package/dist/components/sparkline-grid/sparkline-grid.js +1 -1
- package/dist/components/spinner/spinner.js +3 -3
- package/dist/components/stat-card/stat-card.js +3 -3
- package/dist/components/state-badge-overlay/state-badge-overlay.js +1 -1
- package/dist/components/status-board/status-board.js +1 -1
- package/dist/components/status-indicator/status-indicator.js +3 -3
- package/dist/components/step-by-step/step-by-step.js +8 -7
- package/dist/components/step-navigation/step-navigation.js +2 -2
- package/dist/components/stepper/stepper.js +3 -3
- package/dist/components/sticky-metric/sticky-metric.js +1 -1
- package/dist/components/subscription-card/subscription-card.js +1 -1
- package/dist/components/switch/switch.js +1 -1
- package/dist/components/table-of-contents-panel/table-of-contents-panel.js +5 -5
- package/dist/components/tags-input/tags-input.js +1 -1
- package/dist/components/terminal/terminal.js +48 -34
- package/dist/components/thinking-block/thinking-block.js +1 -1
- package/dist/components/ticker-tape/ticker-tape.js +3 -3
- package/dist/components/timeline/timeline.js +2 -2
- package/dist/components/tldr-section/tldr-section.js +2 -2
- package/dist/components/tour/tour.js +1 -1
- package/dist/components/transaction-list/transaction-list.js +30 -9
- package/dist/components/tree-view/tree-view.js +2 -2
- package/dist/components/tutorial-complete/tutorial-complete.js +8 -8
- package/dist/components/usage-breakdown/usage-breakdown.js +9 -5
- package/dist/components/video-embed/video-embed.js +2 -2
- package/dist/components/viewport-bookmarks/viewport-bookmarks.js +1 -1
- package/dist/components/wallet-card/wallet-card.js +1 -1
- package/dist/components/watchlist/watchlist.js +5 -5
- package/dist/components/world-clock-bar/world-clock-bar.js +32 -12
- package/dist/index.d.ts +1 -1
- package/package.json +1 -1
|
@@ -64,7 +64,7 @@ function SubscriptionDetails({
|
|
|
64
64
|
/* @__PURE__ */ jsx("p", { className: "text-xs uppercase tracking-[0.18em] text-muted-foreground", children: "Monthly total" }),
|
|
65
65
|
/* @__PURE__ */ jsx("p", { className: "mt-2 text-3xl font-semibold tracking-tight", children: priceLabel })
|
|
66
66
|
] }),
|
|
67
|
-
/* @__PURE__ */ jsxs("div", { className: "space-y-3 rounded-lg border border-border/70 bg-muted/20
|
|
67
|
+
/* @__PURE__ */ jsxs("div", { className: "space-y-3 rounded-lg border border-border/70 bg-muted/20 p-4", children: [
|
|
68
68
|
/* @__PURE__ */ jsx(DetailRow, { label: "Renewal", value: renewalLabel }),
|
|
69
69
|
seatsLabel ? /* @__PURE__ */ jsx(DetailRow, { label: "Seats", value: seatsLabel }) : null,
|
|
70
70
|
usageLabel ? /* @__PURE__ */ jsx(DetailRow, { label: "Usage", value: usageLabel }) : null
|
|
@@ -16,7 +16,7 @@ const Switch = React.forwardRef(({ className, ...props }, ref) => /* @__PURE__ *
|
|
|
16
16
|
SwitchPrimitives.Thumb,
|
|
17
17
|
{
|
|
18
18
|
className: cn(
|
|
19
|
-
"pointer-events-none block
|
|
19
|
+
"pointer-events-none block size-4 rounded-full bg-background shadow-lg ring-0 transition-transform data-[state=checked]:translate-x-4 data-[state=unchecked]:translate-x-0"
|
|
20
20
|
)
|
|
21
21
|
}
|
|
22
22
|
)
|
|
@@ -73,14 +73,14 @@ function TableOfContentsPanelImpl({
|
|
|
73
73
|
"button",
|
|
74
74
|
{
|
|
75
75
|
"aria-label": "Close table of contents",
|
|
76
|
-
className: "flex
|
|
76
|
+
className: "flex size-8 items-center justify-center rounded-md hover:bg-muted",
|
|
77
77
|
onClick: onClose,
|
|
78
78
|
ref: closeButtonRef,
|
|
79
79
|
type: "button",
|
|
80
80
|
children: closeIcon ?? /* @__PURE__ */ jsx(
|
|
81
81
|
"svg",
|
|
82
82
|
{
|
|
83
|
-
className: "
|
|
83
|
+
className: "size-5",
|
|
84
84
|
fill: "none",
|
|
85
85
|
stroke: "currentColor",
|
|
86
86
|
viewBox: "0 0 24 24",
|
|
@@ -143,13 +143,13 @@ function TableOfContentsPanelImpl({
|
|
|
143
143
|
"span",
|
|
144
144
|
{
|
|
145
145
|
className: cn(
|
|
146
|
-
"flex
|
|
146
|
+
"flex size-5 shrink-0 items-center justify-center rounded-full border",
|
|
147
147
|
isCompleted ? "border-primary bg-primary text-primary-foreground" : "border-muted-foreground"
|
|
148
148
|
),
|
|
149
149
|
children: isCompleted ? /* @__PURE__ */ jsx(
|
|
150
150
|
"svg",
|
|
151
151
|
{
|
|
152
|
-
className: "
|
|
152
|
+
className: "size-3",
|
|
153
153
|
fill: "none",
|
|
154
154
|
stroke: "currentColor",
|
|
155
155
|
viewBox: "0 0 24 24",
|
|
@@ -175,7 +175,7 @@ function TableOfContentsPanelImpl({
|
|
|
175
175
|
)
|
|
176
176
|
]
|
|
177
177
|
}
|
|
178
|
-
) },
|
|
178
|
+
) }, section.id);
|
|
179
179
|
}) })
|
|
180
180
|
}
|
|
181
181
|
),
|
|
@@ -20,35 +20,42 @@ function Terminal({
|
|
|
20
20
|
return /* @__PURE__ */ jsxs("div", { className: "my-6 rounded-lg border bg-zinc-950 dark:bg-zinc-900 overflow-hidden", children: [
|
|
21
21
|
/* @__PURE__ */ jsxs("div", { className: "flex items-center justify-between px-4 py-2 bg-zinc-900 dark:bg-zinc-800 border-b border-zinc-800", children: [
|
|
22
22
|
/* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2", children: [
|
|
23
|
-
/* @__PURE__ */ jsx(TerminalIcon, { className: "
|
|
23
|
+
/* @__PURE__ */ jsx(TerminalIcon, { className: "size-4 text-zinc-400" }),
|
|
24
24
|
/* @__PURE__ */ jsx("span", { className: "text-sm font-medium text-zinc-300", children: title })
|
|
25
25
|
] }),
|
|
26
26
|
/* @__PURE__ */ jsxs("div", { className: "flex items-center gap-1.5", children: [
|
|
27
|
-
/* @__PURE__ */ jsx("div", { className: "
|
|
28
|
-
/* @__PURE__ */ jsx("div", { className: "
|
|
29
|
-
/* @__PURE__ */ jsx("div", { className: "
|
|
27
|
+
/* @__PURE__ */ jsx("div", { className: "size-3 rounded-full bg-red-500" }),
|
|
28
|
+
/* @__PURE__ */ jsx("div", { className: "size-3 rounded-full bg-yellow-500" }),
|
|
29
|
+
/* @__PURE__ */ jsx("div", { className: "size-3 rounded-full bg-green-500" })
|
|
30
30
|
] })
|
|
31
31
|
] }),
|
|
32
32
|
/* @__PURE__ */ jsxs("div", { className: "relative", children: [
|
|
33
|
-
/* @__PURE__ */ jsx("div", { className: "p-4 font-mono text-sm space-y-1 overflow-x-auto", children: lines.map((line
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
33
|
+
/* @__PURE__ */ jsx("div", { className: "p-4 font-mono text-sm space-y-1 overflow-x-auto", children: lines.map((line) => /* @__PURE__ */ jsxs(
|
|
34
|
+
"div",
|
|
35
|
+
{
|
|
36
|
+
className: "flex items-start",
|
|
37
|
+
children: [
|
|
38
|
+
line.type === "command" && /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
39
|
+
/* @__PURE__ */ jsx("span", { className: "text-green-400 mr-2 select-none", children: "$" }),
|
|
40
|
+
/* @__PURE__ */ jsx("span", { className: "text-zinc-100", children: line.content })
|
|
41
|
+
] }),
|
|
42
|
+
line.type === "output" && /* @__PURE__ */ jsx("span", { className: "text-zinc-400", children: line.content }),
|
|
43
|
+
line.type === "comment" && /* @__PURE__ */ jsxs("span", { className: "text-zinc-600 italic", children: [
|
|
44
|
+
"# ",
|
|
45
|
+
line.content
|
|
46
|
+
] })
|
|
47
|
+
]
|
|
48
|
+
},
|
|
49
|
+
`${line.type}-${line.content}`
|
|
50
|
+
)) }),
|
|
44
51
|
copyable && commands.length > 0 ? /* @__PURE__ */ jsx(
|
|
45
52
|
Button,
|
|
46
53
|
{
|
|
47
|
-
className: "absolute top-2 right-2
|
|
54
|
+
className: "absolute top-2 right-2 size-8 bg-zinc-800 hover:bg-zinc-700 text-zinc-300",
|
|
48
55
|
onClick: handleCopy,
|
|
49
56
|
size: "icon",
|
|
50
57
|
variant: "ghost",
|
|
51
|
-
children: copied ? /* @__PURE__ */ jsx(Check, { className: "
|
|
58
|
+
children: copied ? /* @__PURE__ */ jsx(Check, { className: "size-3" }) : /* @__PURE__ */ jsx(Copy, { className: "size-3" })
|
|
52
59
|
}
|
|
53
60
|
) : null
|
|
54
61
|
] })
|
|
@@ -79,35 +86,42 @@ function SimpleTerminal({
|
|
|
79
86
|
return /* @__PURE__ */ jsxs("div", { className: "my-6 rounded-lg border bg-zinc-950 dark:bg-zinc-900 overflow-hidden", children: [
|
|
80
87
|
/* @__PURE__ */ jsxs("div", { className: "flex items-center justify-between px-4 py-2 bg-zinc-900 dark:bg-zinc-800 border-b border-zinc-800", children: [
|
|
81
88
|
/* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2", children: [
|
|
82
|
-
/* @__PURE__ */ jsx(TerminalIcon, { className: "
|
|
89
|
+
/* @__PURE__ */ jsx(TerminalIcon, { className: "size-4 text-zinc-400" }),
|
|
83
90
|
/* @__PURE__ */ jsx("span", { className: "text-sm font-medium text-zinc-300", children: title })
|
|
84
91
|
] }),
|
|
85
92
|
/* @__PURE__ */ jsxs("div", { className: "flex items-center gap-1.5", children: [
|
|
86
|
-
/* @__PURE__ */ jsx("div", { className: "
|
|
87
|
-
/* @__PURE__ */ jsx("div", { className: "
|
|
88
|
-
/* @__PURE__ */ jsx("div", { className: "
|
|
93
|
+
/* @__PURE__ */ jsx("div", { className: "size-3 rounded-full bg-red-500" }),
|
|
94
|
+
/* @__PURE__ */ jsx("div", { className: "size-3 rounded-full bg-yellow-500" }),
|
|
95
|
+
/* @__PURE__ */ jsx("div", { className: "size-3 rounded-full bg-green-500" })
|
|
89
96
|
] })
|
|
90
97
|
] }),
|
|
91
98
|
/* @__PURE__ */ jsxs("div", { className: "relative", children: [
|
|
92
|
-
/* @__PURE__ */ jsx("div", { className: "p-4 font-mono text-sm space-y-1 overflow-x-auto", children: lines.map((line
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
99
|
+
/* @__PURE__ */ jsx("div", { className: "p-4 font-mono text-sm space-y-1 overflow-x-auto", children: lines.map((line) => /* @__PURE__ */ jsxs(
|
|
100
|
+
"div",
|
|
101
|
+
{
|
|
102
|
+
className: "flex items-start",
|
|
103
|
+
children: [
|
|
104
|
+
line.type === "command" && /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
105
|
+
/* @__PURE__ */ jsx("span", { className: "text-green-400 mr-2 select-none", children: "$" }),
|
|
106
|
+
/* @__PURE__ */ jsx("span", { className: "text-zinc-100", children: line.content })
|
|
107
|
+
] }),
|
|
108
|
+
line.type === "output" && /* @__PURE__ */ jsx("span", { className: "text-zinc-400", children: line.content }),
|
|
109
|
+
line.type === "comment" && /* @__PURE__ */ jsxs("span", { className: "text-zinc-600 italic", children: [
|
|
110
|
+
"# ",
|
|
111
|
+
line.content
|
|
112
|
+
] })
|
|
113
|
+
]
|
|
114
|
+
},
|
|
115
|
+
`${line.type}-${line.content}`
|
|
116
|
+
)) }),
|
|
103
117
|
commands.length > 0 && /* @__PURE__ */ jsx(
|
|
104
118
|
Button,
|
|
105
119
|
{
|
|
106
|
-
className: "absolute top-2 right-2
|
|
120
|
+
className: "absolute top-2 right-2 size-8 bg-zinc-800 hover:bg-zinc-700 text-zinc-300",
|
|
107
121
|
onClick: handleCopy,
|
|
108
122
|
size: "icon",
|
|
109
123
|
variant: "ghost",
|
|
110
|
-
children: copied ? /* @__PURE__ */ jsx(Check, { className: "
|
|
124
|
+
children: copied ? /* @__PURE__ */ jsx(Check, { className: "size-3" }) : /* @__PURE__ */ jsx(Copy, { className: "size-3" })
|
|
111
125
|
}
|
|
112
126
|
)
|
|
113
127
|
] })
|
|
@@ -30,7 +30,7 @@ function ThinkingBlock({
|
|
|
30
30
|
onClick: toggleExpanded,
|
|
31
31
|
type: "button",
|
|
32
32
|
children: [
|
|
33
|
-
isExpanded ? /* @__PURE__ */ jsx(ChevronDown, { className: "
|
|
33
|
+
isExpanded ? /* @__PURE__ */ jsx(ChevronDown, { className: "size-3" }) : /* @__PURE__ */ jsx(ChevronRight, { className: "size-3" }),
|
|
34
34
|
/* @__PURE__ */ jsxs("span", { children: [
|
|
35
35
|
"Thinking",
|
|
36
36
|
isStreaming ? /* @__PURE__ */ jsx("span", { className: "ml-1 animate-pulse", children: "..." }) : null
|
|
@@ -22,7 +22,7 @@ function formatChange(change) {
|
|
|
22
22
|
return `${sign}${change.toFixed(2)}%`;
|
|
23
23
|
}
|
|
24
24
|
function TickerTapeRow({ items }) {
|
|
25
|
-
return /* @__PURE__ */ jsx("div", { className: "flex min-w-max items-center gap-3
|
|
25
|
+
return /* @__PURE__ */ jsx("div", { className: "flex min-w-max items-center gap-3 p-3", children: items.map((item) => {
|
|
26
26
|
const isPositive = item.change >= 0;
|
|
27
27
|
const TrendIcon = isPositive ? ArrowUpRight : ArrowDownRight;
|
|
28
28
|
return /* @__PURE__ */ jsxs(
|
|
@@ -43,13 +43,13 @@ function TickerTapeRow({ items }) {
|
|
|
43
43
|
),
|
|
44
44
|
variant: "outline",
|
|
45
45
|
children: [
|
|
46
|
-
/* @__PURE__ */ jsx(TrendIcon, { className: "
|
|
46
|
+
/* @__PURE__ */ jsx(TrendIcon, { className: "size-3" }),
|
|
47
47
|
formatChange(item.change)
|
|
48
48
|
]
|
|
49
49
|
}
|
|
50
50
|
),
|
|
51
51
|
item.volume ? /* @__PURE__ */ jsxs("span", { className: "hidden items-center text-xs text-muted-foreground sm:inline-flex", children: [
|
|
52
|
-
/* @__PURE__ */ jsx(Dot, { className: "
|
|
52
|
+
/* @__PURE__ */ jsx(Dot, { className: "size-3.5" }),
|
|
53
53
|
item.volume
|
|
54
54
|
] }) : null
|
|
55
55
|
]
|
|
@@ -102,7 +102,7 @@ function Marker({ color, icon, status }) {
|
|
|
102
102
|
{
|
|
103
103
|
"aria-hidden": "true",
|
|
104
104
|
className: cn(
|
|
105
|
-
"relative z-10 flex
|
|
105
|
+
"relative z-10 flex size-6 shrink-0 items-center justify-center rounded-full border-2 bg-background text-[10px]",
|
|
106
106
|
borderClass
|
|
107
107
|
),
|
|
108
108
|
children: icon ? /* @__PURE__ */ jsx(
|
|
@@ -118,7 +118,7 @@ function Marker({ color, icon, status }) {
|
|
|
118
118
|
"span",
|
|
119
119
|
{
|
|
120
120
|
className: cn(
|
|
121
|
-
"
|
|
121
|
+
"size-2.5 rounded-full",
|
|
122
122
|
override ? fillClass : palette.markerFill
|
|
123
123
|
)
|
|
124
124
|
}
|
|
@@ -48,7 +48,7 @@ function TLDRSection({ children, label }) {
|
|
|
48
48
|
/* @__PURE__ */ jsx(
|
|
49
49
|
"svg",
|
|
50
50
|
{
|
|
51
|
-
className: "
|
|
51
|
+
className: "size-5 text-muted-foreground",
|
|
52
52
|
fill: "none",
|
|
53
53
|
stroke: "currentColor",
|
|
54
54
|
strokeWidth: "2",
|
|
@@ -69,7 +69,7 @@ function TLDRSection({ children, label }) {
|
|
|
69
69
|
/* @__PURE__ */ jsx(
|
|
70
70
|
"svg",
|
|
71
71
|
{
|
|
72
|
-
className: `
|
|
72
|
+
className: `size-4 text-muted-foreground transition-transform ${isExpanded ? "rotate-180" : ""}`,
|
|
73
73
|
fill: "none",
|
|
74
74
|
stroke: "currentColor",
|
|
75
75
|
strokeWidth: "2",
|
|
@@ -60,7 +60,7 @@ function TourFooter({
|
|
|
60
60
|
{
|
|
61
61
|
"aria-label": `Go to ${step.title}`,
|
|
62
62
|
className: cn(
|
|
63
|
-
"
|
|
63
|
+
"size-2.5 rounded-full transition-colors",
|
|
64
64
|
index === currentStep ? "bg-primary" : "bg-muted-foreground/30"
|
|
65
65
|
),
|
|
66
66
|
onClick: () => {
|
|
@@ -7,6 +7,32 @@ import { Badge } from "../badge/badge";
|
|
|
7
7
|
const CENTS_PER_UNIT = 100;
|
|
8
8
|
const DEFAULT_LOCALE = "en-US";
|
|
9
9
|
const DEFAULT_CURRENCY = "USD";
|
|
10
|
+
const CURRENCY_FORMATTER_CACHE = /* @__PURE__ */ new Map();
|
|
11
|
+
function getCurrencyFormatter(locale, currency) {
|
|
12
|
+
const key = `${locale}|${currency}`;
|
|
13
|
+
let formatter = CURRENCY_FORMATTER_CACHE.get(key);
|
|
14
|
+
if (!formatter) {
|
|
15
|
+
formatter = new Intl.NumberFormat(locale, {
|
|
16
|
+
currency,
|
|
17
|
+
style: "currency"
|
|
18
|
+
});
|
|
19
|
+
CURRENCY_FORMATTER_CACHE.set(key, formatter);
|
|
20
|
+
}
|
|
21
|
+
return formatter;
|
|
22
|
+
}
|
|
23
|
+
const DATE_FORMATTER_CACHE = /* @__PURE__ */ new Map();
|
|
24
|
+
function getTransactionDateFormatter(locale) {
|
|
25
|
+
let formatter = DATE_FORMATTER_CACHE.get(locale);
|
|
26
|
+
if (!formatter) {
|
|
27
|
+
formatter = new Intl.DateTimeFormat(locale, {
|
|
28
|
+
day: "numeric",
|
|
29
|
+
month: "short",
|
|
30
|
+
year: "numeric"
|
|
31
|
+
});
|
|
32
|
+
DATE_FORMATTER_CACHE.set(locale, formatter);
|
|
33
|
+
}
|
|
34
|
+
return formatter;
|
|
35
|
+
}
|
|
10
36
|
const DEFAULT_LABELS = {
|
|
11
37
|
active: "Active",
|
|
12
38
|
canceled: "Canceled",
|
|
@@ -44,17 +70,12 @@ const INTERVAL_LABEL = {
|
|
|
44
70
|
};
|
|
45
71
|
function formatTransactionAmount(amountCents, options = {}) {
|
|
46
72
|
const { currency = DEFAULT_CURRENCY, locale = DEFAULT_LOCALE } = options;
|
|
47
|
-
return
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
}).format(amountCents / CENTS_PER_UNIT);
|
|
73
|
+
return getCurrencyFormatter(locale, currency).format(
|
|
74
|
+
amountCents / CENTS_PER_UNIT
|
|
75
|
+
);
|
|
51
76
|
}
|
|
52
77
|
function formatTransactionDate(timestamp, locale = DEFAULT_LOCALE) {
|
|
53
|
-
return new
|
|
54
|
-
day: "numeric",
|
|
55
|
-
month: "short",
|
|
56
|
-
year: "numeric"
|
|
57
|
-
}).format(new Date(timestamp));
|
|
78
|
+
return getTransactionDateFormatter(locale).format(new Date(timestamp));
|
|
58
79
|
}
|
|
59
80
|
const TransactionListBase = forwardRef(
|
|
60
81
|
(props, ref) => {
|
|
@@ -92,14 +92,14 @@ function TreeRow({
|
|
|
92
92
|
{
|
|
93
93
|
"aria-hidden": "true",
|
|
94
94
|
className: cn(
|
|
95
|
-
"inline-flex
|
|
95
|
+
"inline-flex size-4 shrink-0 items-center justify-center text-xs text-muted-foreground transition-transform",
|
|
96
96
|
hasChildren ? "" : "opacity-0",
|
|
97
97
|
expanded ? "rotate-90" : ""
|
|
98
98
|
),
|
|
99
99
|
children: "\u25B8"
|
|
100
100
|
}
|
|
101
101
|
),
|
|
102
|
-
node.icon ? /* @__PURE__ */ jsx("span", { "aria-hidden": "true", className: "inline-flex
|
|
102
|
+
node.icon ? /* @__PURE__ */ jsx("span", { "aria-hidden": "true", className: "inline-flex size-4 shrink-0", children: node.icon }) : null,
|
|
103
103
|
/* @__PURE__ */ jsx("span", { className: "truncate", children: node.label })
|
|
104
104
|
]
|
|
105
105
|
}
|
|
@@ -32,11 +32,11 @@ function TutorialCompleteImpl({
|
|
|
32
32
|
/* @__PURE__ */ jsx(
|
|
33
33
|
"div",
|
|
34
34
|
{
|
|
35
|
-
className: `inline-flex items-center justify-center
|
|
35
|
+
className: `inline-flex items-center justify-center size-20 rounded-full mb-6 ${isFullyComplete ? "bg-green-100 dark:bg-green-900/30" : "bg-muted"}`,
|
|
36
36
|
children: /* @__PURE__ */ jsx(
|
|
37
37
|
Check,
|
|
38
38
|
{
|
|
39
|
-
className: `
|
|
39
|
+
className: `size-10 ${isFullyComplete ? "text-green-600 dark:text-green-400" : "text-muted-foreground"}`
|
|
40
40
|
}
|
|
41
41
|
)
|
|
42
42
|
}
|
|
@@ -44,7 +44,7 @@ function TutorialCompleteImpl({
|
|
|
44
44
|
/* @__PURE__ */ jsx("h2", { className: "text-3xl font-bold mb-2", children: isFullyComplete ? labels.tutorialComplete : labels.tutorialFinished }),
|
|
45
45
|
/* @__PURE__ */ jsx("p", { className: "text-muted-foreground mb-6", children: isFullyComplete ? `${labels.youveCompletedAll} "${title}"` : `${labels.youveFinishedWith} "${title}" (${completionPercent}%)` }),
|
|
46
46
|
/* @__PURE__ */ jsxs(Button, { className: "gap-2", onClick: onRestart, variant: "outline", children: [
|
|
47
|
-
/* @__PURE__ */ jsx(RotateCcw, { className: "
|
|
47
|
+
/* @__PURE__ */ jsx(RotateCcw, { className: "size-4" }),
|
|
48
48
|
labels.startOver
|
|
49
49
|
] })
|
|
50
50
|
] }),
|
|
@@ -64,15 +64,15 @@ function TutorialCompleteImpl({
|
|
|
64
64
|
/* @__PURE__ */ jsx(
|
|
65
65
|
"div",
|
|
66
66
|
{
|
|
67
|
-
className: `flex-shrink-0
|
|
68
|
-
children: isCompleted ? /* @__PURE__ */ jsx(Check, { className: "
|
|
67
|
+
className: `flex-shrink-0 size-5 rounded-full border-2 flex items-center justify-center ${isCompleted ? "bg-foreground border-foreground" : "border-muted-foreground"}`,
|
|
68
|
+
children: isCompleted ? /* @__PURE__ */ jsx(Check, { className: "size-3 text-background" }) : null
|
|
69
69
|
}
|
|
70
70
|
),
|
|
71
71
|
/* @__PURE__ */ jsx("span", { className: "flex-1 truncate", children: section.title }),
|
|
72
|
-
/* @__PURE__ */ jsx(ChevronRight, { className: "
|
|
72
|
+
/* @__PURE__ */ jsx(ChevronRight, { className: "size-4 text-muted-foreground" })
|
|
73
73
|
]
|
|
74
74
|
},
|
|
75
|
-
|
|
75
|
+
section.id
|
|
76
76
|
);
|
|
77
77
|
}) })
|
|
78
78
|
] }),
|
|
@@ -86,7 +86,7 @@ function TutorialCompleteImpl({
|
|
|
86
86
|
children: [
|
|
87
87
|
/* @__PURE__ */ jsx("span", { className: "text-xs uppercase text-muted-foreground font-medium", children: item.type }),
|
|
88
88
|
/* @__PURE__ */ jsx("span", { className: "flex-1 truncate", children: item.title }),
|
|
89
|
-
/* @__PURE__ */ jsx(ChevronRight, { className: "
|
|
89
|
+
/* @__PURE__ */ jsx(ChevronRight, { className: "size-4 text-muted-foreground" })
|
|
90
90
|
]
|
|
91
91
|
},
|
|
92
92
|
item.href
|
|
@@ -21,10 +21,14 @@ function formatPercent(value) {
|
|
|
21
21
|
if (!Number.isFinite(value)) return "0%";
|
|
22
22
|
return `${Math.round(value)}%`;
|
|
23
23
|
}
|
|
24
|
+
const LARGE_VALUE_FORMATTER = new Intl.NumberFormat("en-US", {
|
|
25
|
+
maximumFractionDigits: 0
|
|
26
|
+
});
|
|
27
|
+
const SMALL_VALUE_FORMATTER = new Intl.NumberFormat("en-US", {
|
|
28
|
+
maximumFractionDigits: 1
|
|
29
|
+
});
|
|
24
30
|
function formatValue(value) {
|
|
25
|
-
return
|
|
26
|
-
maximumFractionDigits: value >= 100 ? 0 : 1
|
|
27
|
-
}).format(value);
|
|
31
|
+
return value >= 100 ? LARGE_VALUE_FORMATTER.format(value) : SMALL_VALUE_FORMATTER.format(value);
|
|
28
32
|
}
|
|
29
33
|
function getRelativeWidth(value, maxValue) {
|
|
30
34
|
if (maxValue <= 0) return 0;
|
|
@@ -39,7 +43,7 @@ function UsageBreakdownTrend({ item }) {
|
|
|
39
43
|
const trendTone = item.tone ?? "default";
|
|
40
44
|
const TrendIcon = item.trend.direction === "down" ? ArrowDownRight : ArrowUpRight;
|
|
41
45
|
return /* @__PURE__ */ jsxs(Badge, { className: cn("gap-1 border", toneClasses[trendTone]), children: [
|
|
42
|
-
/* @__PURE__ */ jsx(TrendIcon, { className: "
|
|
46
|
+
/* @__PURE__ */ jsx(TrendIcon, { className: "size-3.5" }),
|
|
43
47
|
item.trend.label
|
|
44
48
|
] });
|
|
45
49
|
}
|
|
@@ -69,7 +73,7 @@ function UsageBreakdownRow({
|
|
|
69
73
|
totalValue
|
|
70
74
|
}) {
|
|
71
75
|
return /* @__PURE__ */ jsx("li", { className: "rounded-lg border bg-background/70 p-4", children: /* @__PURE__ */ jsxs("div", { className: "flex items-start gap-3", children: [
|
|
72
|
-
/* @__PURE__ */ jsx("div", { className: "flex
|
|
76
|
+
/* @__PURE__ */ jsx("div", { className: "flex size-10 shrink-0 items-center justify-center rounded-md border bg-muted text-sm font-semibold text-muted-foreground", children: item.icon ?? rank }),
|
|
73
77
|
/* @__PURE__ */ jsxs("div", { className: "min-w-0 flex-1 space-y-3", children: [
|
|
74
78
|
/* @__PURE__ */ jsxs("div", { className: "flex flex-col gap-2 sm:flex-row sm:items-start sm:justify-between", children: [
|
|
75
79
|
/* @__PURE__ */ jsxs("div", { className: "min-w-0 space-y-1", children: [
|
|
@@ -60,14 +60,14 @@ function VideoEmbed({
|
|
|
60
60
|
src: thumbnail
|
|
61
61
|
}
|
|
62
62
|
) : /* @__PURE__ */ jsx("div", { className: "absolute inset-0 bg-gradient-to-br from-muted to-muted-foreground/20" }),
|
|
63
|
-
/* @__PURE__ */ jsx("div", { className: "relative z-10 flex
|
|
63
|
+
/* @__PURE__ */ jsx("div", { className: "relative z-10 flex size-16 items-center justify-center rounded-full bg-primary text-primary-foreground shadow-lg transition-transform group-hover:scale-110", children: /* @__PURE__ */ jsx(Play, { className: "size-6 ml-1" }) })
|
|
64
64
|
]
|
|
65
65
|
}
|
|
66
66
|
)
|
|
67
67
|
}
|
|
68
68
|
),
|
|
69
69
|
/* @__PURE__ */ jsxs("p", { className: "mt-2 text-sm text-center text-muted-foreground flex items-center justify-center gap-1", children: [
|
|
70
|
-
/* @__PURE__ */ jsx(Video, { className: "
|
|
70
|
+
/* @__PURE__ */ jsx(Video, { className: "size-4" }),
|
|
71
71
|
title
|
|
72
72
|
] })
|
|
73
73
|
] });
|
|
@@ -31,7 +31,7 @@ function WalletDetails({
|
|
|
31
31
|
/* @__PURE__ */ jsx("p", { className: "text-xs uppercase tracking-[0.18em] text-muted-foreground", children: "Current balance" }),
|
|
32
32
|
/* @__PURE__ */ jsx("p", { className: "mt-2 text-3xl font-semibold tracking-tight", children: balanceLabel })
|
|
33
33
|
] }),
|
|
34
|
-
/* @__PURE__ */ jsxs("div", { className: "space-y-3 rounded-lg border border-border/70 bg-muted/20
|
|
34
|
+
/* @__PURE__ */ jsxs("div", { className: "space-y-3 rounded-lg border border-border/70 bg-muted/20 p-4", children: [
|
|
35
35
|
availableLabel ? /* @__PURE__ */ jsx(DetailRow, { label: "Available now", value: availableLabel }) : null,
|
|
36
36
|
pendingLabel ? /* @__PURE__ */ jsx(DetailRow, { label: "Pending", value: pendingLabel }) : null,
|
|
37
37
|
renewsLabel ? /* @__PURE__ */ jsx(DetailRow, { label: "Refresh", value: renewsLabel }) : null
|
|
@@ -21,13 +21,13 @@ function WatchlistRow({ item }) {
|
|
|
21
21
|
{
|
|
22
22
|
"aria-hidden": "true",
|
|
23
23
|
className: cn(
|
|
24
|
-
"flex
|
|
24
|
+
"flex size-7 items-center justify-center rounded-full border",
|
|
25
25
|
item.starred ? "border-amber-400/40 bg-amber-400/10 text-amber-500" : "border-border bg-background text-muted-foreground"
|
|
26
26
|
),
|
|
27
27
|
children: /* @__PURE__ */ jsx(
|
|
28
28
|
Star,
|
|
29
29
|
{
|
|
30
|
-
className: cn("
|
|
30
|
+
className: cn("size-3.5", item.starred && "fill-current"),
|
|
31
31
|
strokeWidth: 1.75
|
|
32
32
|
}
|
|
33
33
|
)
|
|
@@ -49,7 +49,7 @@ function WatchlistRow({ item }) {
|
|
|
49
49
|
isPositive ? "border-emerald-500/30 bg-emerald-500/10 text-emerald-600 dark:text-emerald-400" : "border-rose-500/30 bg-rose-500/10 text-rose-600 dark:text-rose-400"
|
|
50
50
|
),
|
|
51
51
|
children: [
|
|
52
|
-
/* @__PURE__ */ jsx(TrendIcon, { className: "
|
|
52
|
+
/* @__PURE__ */ jsx(TrendIcon, { className: "size-3" }),
|
|
53
53
|
formatChange(item.change)
|
|
54
54
|
]
|
|
55
55
|
}
|
|
@@ -87,12 +87,12 @@ const Watchlist = React.forwardRef(
|
|
|
87
87
|
] }),
|
|
88
88
|
/* @__PURE__ */ jsxs("div", { className: "flex items-center gap-2 text-xs text-muted-foreground", children: [
|
|
89
89
|
/* @__PURE__ */ jsxs("span", { className: "inline-flex items-center gap-1 rounded-full border border-emerald-500/30 bg-emerald-500/10 px-2 py-1 text-emerald-600 dark:text-emerald-400", children: [
|
|
90
|
-
/* @__PURE__ */ jsx(ArrowUpRight, { className: "
|
|
90
|
+
/* @__PURE__ */ jsx(ArrowUpRight, { className: "size-3" }),
|
|
91
91
|
advancing,
|
|
92
92
|
" up"
|
|
93
93
|
] }),
|
|
94
94
|
/* @__PURE__ */ jsxs("span", { className: "inline-flex items-center gap-1 rounded-full border border-rose-500/30 bg-rose-500/10 px-2 py-1 text-rose-600 dark:text-rose-400", children: [
|
|
95
|
-
/* @__PURE__ */ jsx(ArrowDownRight, { className: "
|
|
95
|
+
/* @__PURE__ */ jsx(ArrowDownRight, { className: "size-3" }),
|
|
96
96
|
declining,
|
|
97
97
|
" down"
|
|
98
98
|
] })
|
|
@@ -29,20 +29,40 @@ function useLiveDate(now, updateIntervalMs) {
|
|
|
29
29
|
}, [fixedNow, updateIntervalMs]);
|
|
30
30
|
return liveNow;
|
|
31
31
|
}
|
|
32
|
+
const TIME_FORMATTER_CACHE = /* @__PURE__ */ new Map();
|
|
33
|
+
function getTimeFormatter(locale, timeZone) {
|
|
34
|
+
const key = `${locale}|${timeZone}`;
|
|
35
|
+
let formatter = TIME_FORMATTER_CACHE.get(key);
|
|
36
|
+
if (!formatter) {
|
|
37
|
+
formatter = new Intl.DateTimeFormat(locale, {
|
|
38
|
+
hour: "numeric",
|
|
39
|
+
minute: "2-digit",
|
|
40
|
+
timeZone,
|
|
41
|
+
timeZoneName: "short"
|
|
42
|
+
});
|
|
43
|
+
TIME_FORMATTER_CACHE.set(key, formatter);
|
|
44
|
+
}
|
|
45
|
+
return formatter;
|
|
46
|
+
}
|
|
47
|
+
const DATE_FORMATTER_CACHE = /* @__PURE__ */ new Map();
|
|
48
|
+
function getDateFormatter(locale, timeZone) {
|
|
49
|
+
const key = `${locale}|${timeZone}`;
|
|
50
|
+
let formatter = DATE_FORMATTER_CACHE.get(key);
|
|
51
|
+
if (!formatter) {
|
|
52
|
+
formatter = new Intl.DateTimeFormat(locale, {
|
|
53
|
+
day: "numeric",
|
|
54
|
+
month: "short",
|
|
55
|
+
timeZone,
|
|
56
|
+
weekday: "short"
|
|
57
|
+
});
|
|
58
|
+
DATE_FORMATTER_CACHE.set(key, formatter);
|
|
59
|
+
}
|
|
60
|
+
return formatter;
|
|
61
|
+
}
|
|
32
62
|
function formatZoneDateTime(zone, date, showDate) {
|
|
33
63
|
const locale = zone.locale ?? "en-US";
|
|
34
|
-
const timeFormatter =
|
|
35
|
-
|
|
36
|
-
minute: "2-digit",
|
|
37
|
-
timeZone: zone.timeZone,
|
|
38
|
-
timeZoneName: "short"
|
|
39
|
-
});
|
|
40
|
-
const dateFormatter = new Intl.DateTimeFormat(locale, {
|
|
41
|
-
day: "numeric",
|
|
42
|
-
month: "short",
|
|
43
|
-
timeZone: zone.timeZone,
|
|
44
|
-
weekday: "short"
|
|
45
|
-
});
|
|
64
|
+
const timeFormatter = getTimeFormatter(locale, zone.timeZone);
|
|
65
|
+
const dateFormatter = getDateFormatter(locale, zone.timeZone);
|
|
46
66
|
return {
|
|
47
67
|
date: showDate ? dateFormatter.format(date) : "",
|
|
48
68
|
time: timeFormatter.format(date)
|
package/dist/index.d.ts
CHANGED
|
@@ -4692,7 +4692,7 @@ type SearchBarProps = {
|
|
|
4692
4692
|
onSearch?: (query: string) => void;
|
|
4693
4693
|
placeholder?: string;
|
|
4694
4694
|
};
|
|
4695
|
-
declare function SearchBar(
|
|
4695
|
+
declare function SearchBar(props: SearchBarProps): react_jsx_runtime.JSX.Element;
|
|
4696
4696
|
|
|
4697
4697
|
type ScopeSelectorNode = {
|
|
4698
4698
|
badge?: string;
|
package/package.json
CHANGED