@trading-game/design-intelligence-layer 0.12.4 → 0.13.0
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/README.md +41 -15
- package/dist/index.cjs +37 -34
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +9 -8
- package/dist/index.d.ts +9 -8
- package/dist/index.js +37 -35
- package/dist/index.js.map +1 -1
- package/guides/design-system-guide/trading-game-ds-guide.md +45 -28
- package/guides/rules/design-system-consuming-project.mdc +23 -8
- package/package.json +1 -1
- package/src/styles.css +39 -11
package/README.md
CHANGED
|
@@ -149,7 +149,7 @@ npm install react react-dom tailwindcss
|
|
|
149
149
|
| Table | `Table, TableHeader, TableBody, TableRow, TableHead, TableCell` |
|
|
150
150
|
| Tabs | `Tabs, TabsList, TabsTrigger, TabsContent` |
|
|
151
151
|
| Textarea | `Textarea` |
|
|
152
|
-
| Ticket Card | `TicketCard`, `
|
|
152
|
+
| Ticket Card | `TicketCard`, `BoostTicketCard` |
|
|
153
153
|
| Toast | `Toaster` |
|
|
154
154
|
| Toggle | `Toggle, toggleVariants` |
|
|
155
155
|
| Toggle Group | `ToggleGroup, ToggleGroupItem` |
|
|
@@ -220,7 +220,7 @@ States: hover (`bg-secondary-hover`), focus (3px `ring-ring/50`), active (`opaci
|
|
|
220
220
|
<Badge variant="fill-success" /> // Green tint
|
|
221
221
|
<Badge variant="fill-fail" /> // Red tint
|
|
222
222
|
<Badge variant="fill-warning" /> // Orange tint
|
|
223
|
-
<Badge variant="fill-
|
|
223
|
+
<Badge variant="fill-boost" /> // Amber-orange tint — boost/bonus labels (pair with a Rocket icon)
|
|
224
224
|
|
|
225
225
|
// Outline (black border, secondary-hover on hover)
|
|
226
226
|
<Badge variant="outline" />
|
|
@@ -288,6 +288,7 @@ All tokens are CSS custom properties, loaded automatically via `@trading-game/de
|
|
|
288
288
|
| Tailwind class | CSS variable | Value | Usage |
|
|
289
289
|
|---|---|---|---|
|
|
290
290
|
| `bg-prominent` | `--prominent` | `#FFFFFF` | Page background |
|
|
291
|
+
| `bg-prominent-inverse` | `--prominent-inverse` | `#000000` | Dark surface for use on light pages (e.g. toasts) |
|
|
291
292
|
| `bg-card` | `--card` | `#FFFFFF` | Card/panel surface |
|
|
292
293
|
| `bg-popover` | `--popover` | `#FFFFFF` | Popover/dropdown surface |
|
|
293
294
|
| `bg-subtle` | `--subtle` | `#F5F5F5` | Subtle tinted surface |
|
|
@@ -296,24 +297,33 @@ All tokens are CSS custom properties, loaded automatically via `@trading-game/de
|
|
|
296
297
|
| `bg-tabs-active` | `--tabs-active` | `#FFFFFF` | Active / selected tab pill |
|
|
297
298
|
| `bg-primary` | `--primary` | `#2323FF` | Brand blue — CTAs |
|
|
298
299
|
| `bg-primary-hover` | `--primary-hover` | `#0B0BD2` | Primary button hover (darker blue) |
|
|
300
|
+
| `bg-primary-inverse` | `--primary-inverse` | `#FFFFFF` | Inverted primary surface — white bg for use on dark/coloured areas |
|
|
299
301
|
| `bg-secondary-hover` | `--secondary-hover` | `#EEEEEE` | Outline/secondary hover (light grey) |
|
|
300
302
|
| `bg-semantic-win` | `--semantic-win` | green | Profit / positive state |
|
|
301
303
|
| `bg-semantic-loss` | `--semantic-loss` | red | Loss / negative state |
|
|
302
|
-
| `bg-semantic-
|
|
304
|
+
| `bg-semantic-boost` | `--semantic-boost` | `#F9840F` amber-orange | Boost / bonus badge background |
|
|
303
305
|
|
|
304
306
|
### Text tokens
|
|
305
307
|
|
|
308
|
+
> **Naming convention:** every surface (bg) token has a paired `text-on-<surface>` foreground (text/icon) token. Always use the pair together — `bg-primary` + `text-on-primary`, `bg-semantic-win` + `text-on-semantic-win`, etc. — for guaranteed legibility regardless of theme.
|
|
309
|
+
|
|
306
310
|
| Tailwind class | Value | Usage |
|
|
307
311
|
|---|---|---|
|
|
308
|
-
| `text-on-prominent` | `#000000` |
|
|
309
|
-
| `text-on-prominent-
|
|
310
|
-
| `text-on-subtle` | mid grey |
|
|
312
|
+
| `text-on-prominent` | `#000000` | Text on `bg-prominent` (default body text on light surfaces) |
|
|
313
|
+
| `text-on-prominent-inverse` | `#FFFFFF` | Text on `bg-prominent-inverse` (e.g. toast title/description) |
|
|
314
|
+
| `text-on-subtle` | mid grey | Text on `bg-subtle` (secondary / supporting text) |
|
|
311
315
|
| `text-on-disabled` | `#BBBBBB` | Disabled / inactive text |
|
|
312
|
-
|
|
313
|
-
| `text-primary` | `#2323FF` |
|
|
314
|
-
| `text-semantic-win` |
|
|
315
|
-
| `text-semantic-loss` |
|
|
316
|
-
| `text-semantic-
|
|
316
|
+
| `text-on-primary` | `#FFFFFF` | Text on `bg-primary` (e.g. primary button label, tooltip text) |
|
|
317
|
+
| `text-on-primary-inverse` | `#2323FF` | Text on `bg-primary-inverse` (e.g. primary-inverse button label) |
|
|
318
|
+
| `text-on-semantic-win` | `#FFFFFF` | Text on `bg-semantic-win` (e.g. success badge label) |
|
|
319
|
+
| `text-on-semantic-loss` | `#FFFFFF` | Text on `bg-semantic-loss` (e.g. fail badge label) |
|
|
320
|
+
| `text-on-semantic-warning` | `#FFFFFF` | Text on `bg-semantic-warning` (e.g. warning badge label) |
|
|
321
|
+
| `text-on-semantic-boost` | `#713813` dark amber | Text on `bg-semantic-boost` (e.g. boost badge label) |
|
|
322
|
+
| `text-primary` | `#2323FF` | Brand blue inline text (use as a foreground over neutral surfaces) |
|
|
323
|
+
| `text-semantic-win` | green | Profit / positive inline text |
|
|
324
|
+
| `text-semantic-loss` | red | Loss / negative inline text |
|
|
325
|
+
|
|
326
|
+
> **Deprecated:** `text-on-prominent-static-inverse` and the matching `--on-prominent-static-inverse` CSS variable are still defined for backwards-compat with external code that references them via raw `var()`. Internal components no longer use them. For new code, pick the explicit `text-on-<surface>` paired with the actual background.
|
|
317
327
|
|
|
318
328
|
### Border & focus tokens
|
|
319
329
|
|
|
@@ -514,7 +524,7 @@ See node_modules/@trading-game/design-intelligence-layer/README.md for complete
|
|
|
514
524
|
|---|---|---|
|
|
515
525
|
| `bg-gray-100` | `bg-subtle` | Raw Tailwind palette — use tokens |
|
|
516
526
|
| `bg-white` | `bg-prominent` or `bg-card` | Not a semantic token |
|
|
517
|
-
| `text-white` | `text-on-prominent-
|
|
527
|
+
| `text-white` | `text-on-<surface>` (e.g. `text-on-primary`, `text-on-prominent-inverse`, `text-on-semantic-win`) | Pick the paired foreground for the actual background |
|
|
518
528
|
| `text-black` | `text-on-prominent` | Not a semantic token |
|
|
519
529
|
| `text-gray-400` | `text-on-disabled` | Use the disabled text token |
|
|
520
530
|
| `bg-black/50` | `bg-overlay` | Overlay has its own token |
|
|
@@ -585,10 +595,26 @@ Design tokens are managed in Figma and exported as CSS variables. To update:
|
|
|
585
595
|
|
|
586
596
|
## Changelog
|
|
587
597
|
|
|
598
|
+
### Unreleased
|
|
599
|
+
- **Token convention — `on-<surface>` foreground pairs:** Added a Material-style paired foreground for every semantic surface so colour roles are self-documenting and resolve robustly across consumer setups (incl. Module Federation, where raw `var()` fallbacks were previously needed). New CSS variables and Tailwind utilities:
|
|
600
|
+
- `--on-primary` (white) / `text-on-primary` — paired with `bg-primary`
|
|
601
|
+
- `--primary-inverse` (white) / `bg-primary-inverse` — inverted primary surface for use on dark/coloured areas
|
|
602
|
+
- `--on-primary-inverse` (blue) / `text-on-primary-inverse` — paired with `bg-primary-inverse`
|
|
603
|
+
- `--prominent-inverse` (black) / `bg-prominent-inverse` — dark surface for use on light pages (e.g. toasts)
|
|
604
|
+
- `--on-prominent-inverse` (white) / `text-on-prominent-inverse` — paired with `bg-prominent-inverse`
|
|
605
|
+
- `--on-semantic-win` / `--on-semantic-loss` / `--on-semantic-warning` (all white) and `--on-semantic-boost` (dark amber) — paired with the matching `bg-semantic-*` surfaces.
|
|
606
|
+
- **Internal sweep:** all internal components (Button, Badge, Tooltip, Toast, Checkbox, Avatar, Input, NativeSelect, TicketCard, BoostTicketCard, sidebar mini-avatar) now use the explicit `on-<surface>` foregrounds — no more catch-all `text-on-prominent-static-inverse`.
|
|
607
|
+
- **Backwards-compat aliases preserved:** `--on-prominent-static-inverse` (→ `var(--on-prominent-inverse)`) and `--surface-inverse-static` (→ `var(--primary-inverse)`) remain defined in CSS so existing consumer code referencing them via raw `var()` (e.g. `var(--on-prominent-static-inverse, #fff)`) keeps working. The Tailwind utility `text-on-prominent-static-inverse` is also still emitted, but new code should pick the explicit paired token.
|
|
608
|
+
- **Sonner → Toast rename:** The toast wrapper file moved from `components/ui/sonner.tsx` to `components/ui/toast.tsx`. The wrapper component is still `Toaster`, and `toast` is now re-exported from this module so consumers no longer need `import { toast } from "sonner"` directly. Import path: `@trading-game/design-intelligence-layer` (was `... from "sonner"`).
|
|
609
|
+
- **`fill-credit` → `fill-boost` Badge variant rename:** The amber-orange badge variant for bonus labels is now `fill-boost` (uses `bg-semantic-boost/16` + `text-on-semantic-boost`). The CSS tokens were correspondingly renamed: `--semantic-credit` → `--semantic-boost`, `--semantic-credit-text` → `--on-semantic-boost`. **Breaking change** for consumers that referenced these by name.
|
|
610
|
+
- **`CreditTicketCard` → `BoostTicketCard` rename:** Component, props (`creditAmount` → `boostAmount`, `creditCurrency` → `boostCurrency`), and badge text (`"Credit: …"` → `"Boost: …"`) all renamed for consistency. The boost badge now uses a leading `Rocket` icon and a trailing `Info` icon (replacing the prior `TicketPlus`). **Breaking change.**
|
|
611
|
+
- **Button `primary-inverse` / `secondary-inverse`:** Now built from the new `bg-primary-inverse` / `text-on-primary-inverse` / `border-primary-inverse` / `text-on-prominent-inverse` tokens. Visually identical to before, but the underlying class names are different.
|
|
612
|
+
- **Toast — action button visual fix:** The toast action button (the inverse-coloured "Undo" pill) now uses `primary-inverse` colouring (white bg + blue text) to match the dark toast surface, instead of the previous `bg-primary` (blue on dark — low hierarchy / wrong surface-context).
|
|
613
|
+
|
|
588
614
|
### v0.12.0
|
|
589
|
-
- **New semantic tokens — credit:** `--semantic-credit` (`#F9840F` amber-orange) and `--semantic-credit-text` (`#713813` dark amber) added to both `src/styles.css` and `app/globals.css`. Tailwind utilities: `bg-semantic-credit`, `text-semantic-credit-text`.
|
|
590
|
-
- **Badge — `fill-credit` variant:**
|
|
591
|
-
- **New `CreditTicketCard` component:** Exported alongside `TicketCard`. Renders the same ticket shell (notches, tear-line, shimmer stub) but with a variable-height card body and an inline `<Badge variant="fill-credit">` below the value for credit/bonus display. Props: `icon`, `label`, `value`, `currency`, `stubLabel`, `onStubClick`, `stubDisabled`, `creditAmount` (default `"0.00"`), `creditCurrency` (default `"USDT"`), `compact`.
|
|
615
|
+
- **New semantic tokens — credit:** _(superseded — see Unreleased above for the `boost` rename)_ `--semantic-credit` (`#F9840F` amber-orange) and `--semantic-credit-text` (`#713813` dark amber) added to both `src/styles.css` and `app/globals.css`. Tailwind utilities: `bg-semantic-credit`, `text-semantic-credit-text`.
|
|
616
|
+
- **Badge — `fill-credit` variant:** _(superseded — now `fill-boost`)_ Variant for credit/bonus labels — `bg-semantic-credit/16` background with `text-semantic-credit-text` foreground. Pair with a `TicketPlus` icon. Badge base class no longer applies `tracking-wide`; letter spacing is default on all badge variants.
|
|
617
|
+
- **New `CreditTicketCard` component:** _(superseded — now `BoostTicketCard`)_ Exported alongside `TicketCard`. Renders the same ticket shell (notches, tear-line, shimmer stub) but with a variable-height card body and an inline `<Badge variant="fill-credit">` below the value for credit/bonus display. Props: `icon`, `label`, `value`, `currency`, `stubLabel`, `onStubClick`, `stubDisabled`, `creditAmount` (default `"0.00"`), `creditCurrency` (default `"USDT"`), `compact`.
|
|
592
618
|
- **`TicketCard` — `compact` prop:** New boolean prop (default `false`). When `true`, reduces left-content padding from `px-4 gap-4` to `px-2 gap-2` for mobile layouts.
|
|
593
619
|
- **`TicketCard` — welcome-credit props removed:** `welcomeCredit`, `freeCredit` (deprecated alias), `creditUsed`, `creditTotal`, `creditCurrency`, `creditLabel`, `creditFullWidth`, and the `Progress`-based credit bar have been removed. Use `CreditTicketCard` for the credit use case.
|
|
594
620
|
- **`tracking-wide` / `tracking-widest` removed from several components:** Badge base class, `Link` base class, `PaginationLink`, `CommandShortcut`, `ContextMenuShortcut`, `DropdownMenuShortcut`, and `MenubarShortcut` no longer apply letter-spacing overrides. All render with default tracking.
|
package/dist/index.cjs
CHANGED
|
@@ -87,6 +87,7 @@ __export(index_exports, {
|
|
|
87
87
|
AvatarGroupCount: () => AvatarGroupCount,
|
|
88
88
|
AvatarImage: () => AvatarImage,
|
|
89
89
|
Badge: () => Badge,
|
|
90
|
+
BoostTicketCard: () => BoostTicketCard,
|
|
90
91
|
Breadcrumb: () => Breadcrumb,
|
|
91
92
|
BreadcrumbEllipsis: () => BreadcrumbEllipsis,
|
|
92
93
|
BreadcrumbItem: () => BreadcrumbItem,
|
|
@@ -158,7 +159,6 @@ __export(index_exports, {
|
|
|
158
159
|
ContextMenuSubContent: () => ContextMenuSubContent,
|
|
159
160
|
ContextMenuSubTrigger: () => ContextMenuSubTrigger,
|
|
160
161
|
ContextMenuTrigger: () => ContextMenuTrigger,
|
|
161
|
-
CreditTicketCard: () => CreditTicketCard,
|
|
162
162
|
Dialog: () => Dialog,
|
|
163
163
|
DialogClose: () => DialogClose,
|
|
164
164
|
DialogContent: () => DialogContent,
|
|
@@ -374,6 +374,7 @@ __export(index_exports, {
|
|
|
374
374
|
navigationButtonVariants: () => navigationButtonVariants,
|
|
375
375
|
navigationMenuTriggerStyle: () => navigationMenuTriggerStyle,
|
|
376
376
|
tabsListVariants: () => tabsListVariants,
|
|
377
|
+
toast: () => import_sonner.toast,
|
|
377
378
|
toggleVariants: () => toggleVariants,
|
|
378
379
|
useComboboxAnchor: () => useComboboxAnchor,
|
|
379
380
|
useDirection: () => useDirection,
|
|
@@ -579,12 +580,12 @@ var buttonVariants = (0, import_class_variance_authority2.cva)(
|
|
|
579
580
|
variants: {
|
|
580
581
|
variant: {
|
|
581
582
|
// Primary brand blue (#2323FF)
|
|
582
|
-
primary: "bg-primary text-on-
|
|
583
|
+
primary: "bg-primary text-on-primary hover:bg-primary-hover",
|
|
583
584
|
// Primary Inverse — white bg + blue text; for use on dark/coloured surfaces
|
|
584
|
-
"primary-inverse": "bg-
|
|
585
|
+
"primary-inverse": "bg-primary-inverse text-on-primary-inverse hover:bg-primary-inverse/80",
|
|
585
586
|
secondary: "bg-transparent border-[1.5px] border-border-prominent text-on-prominent hover:bg-secondary-hover",
|
|
586
587
|
// Secondary Inverse — white border + white text; for use on dark/coloured surfaces
|
|
587
|
-
"secondary-inverse": "bg-transparent border-[1.5px] border-
|
|
588
|
+
"secondary-inverse": "bg-transparent border-[1.5px] border-primary-inverse text-on-prominent-inverse hover:bg-primary-inverse/10",
|
|
588
589
|
tertiary: "bg-transparent text-primary hover:bg-primary/[0.08]"
|
|
589
590
|
},
|
|
590
591
|
size: {
|
|
@@ -894,7 +895,7 @@ function AvatarBadge(_a) {
|
|
|
894
895
|
__spreadValues({
|
|
895
896
|
"data-slot": "avatar-badge",
|
|
896
897
|
className: cn(
|
|
897
|
-
"absolute right-0 bottom-0 z-10 inline-flex items-center justify-center rounded-full bg-primary text-on-
|
|
898
|
+
"absolute right-0 bottom-0 z-10 inline-flex items-center justify-center rounded-full bg-primary text-on-primary ring-2 ring-prominent select-none",
|
|
898
899
|
"group-data-[size=sm]/avatar:size-2 group-data-[size=sm]/avatar:[&>svg]:hidden",
|
|
899
900
|
"group-data-[size=default]/avatar:size-2.5 group-data-[size=default]/avatar:[&>svg]:size-2",
|
|
900
901
|
"group-data-[size=lg]/avatar:size-3 group-data-[size=lg]/avatar:[&>svg]:size-2",
|
|
@@ -945,16 +946,16 @@ var badgeVariants = (0, import_class_variance_authority3.cva)(
|
|
|
945
946
|
variants: {
|
|
946
947
|
variant: {
|
|
947
948
|
// Default (solid)
|
|
948
|
-
default: "bg-primary text-on-
|
|
949
|
-
"default-success": "bg-semantic-win text-on-
|
|
950
|
-
"default-fail": "bg-semantic-loss text-on-
|
|
951
|
-
"default-warning": "bg-semantic-warning text-on-
|
|
949
|
+
default: "bg-primary text-on-primary [a&]:hover:bg-primary/90",
|
|
950
|
+
"default-success": "bg-semantic-win text-on-semantic-win [a&]:hover:bg-semantic-win/90",
|
|
951
|
+
"default-fail": "bg-semantic-loss text-on-semantic-loss [a&]:hover:bg-semantic-loss/90",
|
|
952
|
+
"default-warning": "bg-semantic-warning text-on-semantic-warning [a&]:hover:bg-semantic-warning/90",
|
|
952
953
|
// Fill (tint)
|
|
953
954
|
fill: "bg-primary/10 border-transparent text-primary",
|
|
954
955
|
"fill-success": "bg-semantic-win/10 border-transparent text-semantic-win",
|
|
955
956
|
"fill-fail": "bg-semantic-loss/10 border-transparent text-semantic-loss",
|
|
956
957
|
"fill-warning": "bg-semantic-warning/10 border-transparent text-semantic-warning",
|
|
957
|
-
"fill-
|
|
958
|
+
"fill-boost": "bg-semantic-boost/16 border-transparent text-on-semantic-boost !text-xs !font-semibold",
|
|
958
959
|
// Ghost (transparent)
|
|
959
960
|
ghost: "bg-transparent border-transparent text-primary [a&]:hover:bg-secondary-hover [a&]:hover:text-primary",
|
|
960
961
|
"ghost-success": "bg-transparent border-transparent text-semantic-win [a&]:hover:bg-semantic-win/10 [a&]:hover:text-semantic-win",
|
|
@@ -1836,7 +1837,7 @@ function Checkbox(_a) {
|
|
|
1836
1837
|
__spreadProps(__spreadValues({
|
|
1837
1838
|
"data-slot": "checkbox",
|
|
1838
1839
|
className: cn(
|
|
1839
|
-
"peer size-4 shrink-0 rounded-[2px] border border-input shadow-xs transition-shadow outline-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:border-primary data-[state=checked]:bg-primary data-[state=checked]:text-on-
|
|
1840
|
+
"peer size-4 shrink-0 rounded-[2px] border border-input shadow-xs transition-shadow outline-none focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 data-[state=checked]:border-primary data-[state=checked]:bg-primary data-[state=checked]:text-on-primary",
|
|
1840
1841
|
className
|
|
1841
1842
|
)
|
|
1842
1843
|
}, props), {
|
|
@@ -1894,7 +1895,7 @@ var inputVariants = (0, import_class_variance_authority4.cva)(
|
|
|
1894
1895
|
[
|
|
1895
1896
|
"w-full min-w-0 rounded-sm border border-border-subtle bg-white/5",
|
|
1896
1897
|
"text-on-prominent font-body shadow-xs transition-[color,box-shadow] outline-none",
|
|
1897
|
-
"selection:bg-primary selection:text-on-
|
|
1898
|
+
"selection:bg-primary selection:text-on-primary",
|
|
1898
1899
|
"file:inline-flex file:border-0 file:bg-transparent file:font-medium file:text-on-prominent",
|
|
1899
1900
|
"placeholder:text-on-subtle",
|
|
1900
1901
|
"disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50",
|
|
@@ -4449,7 +4450,7 @@ function NativeSelect(_a) {
|
|
|
4449
4450
|
"data-slot": "native-select",
|
|
4450
4451
|
"data-size": size,
|
|
4451
4452
|
className: cn(
|
|
4452
|
-
"h-9 w-full min-w-0 appearance-none rounded-md border border-input bg-transparent px-3 py-2 pr-9 text-sm shadow-xs transition-[color,box-shadow] outline-none selection:bg-primary selection:text-on-
|
|
4453
|
+
"h-9 w-full min-w-0 appearance-none rounded-md border border-input bg-transparent px-3 py-2 pr-9 text-sm shadow-xs transition-[color,box-shadow] outline-none selection:bg-primary selection:text-on-primary placeholder:text-on-subtle disabled:pointer-events-none disabled:cursor-not-allowed data-[size=sm]:h-8 data-[size=sm]:py-1",
|
|
4453
4454
|
"focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50",
|
|
4454
4455
|
className
|
|
4455
4456
|
)
|
|
@@ -5446,7 +5447,7 @@ function TooltipContent(_a) {
|
|
|
5446
5447
|
"data-slot": "tooltip-content",
|
|
5447
5448
|
sideOffset,
|
|
5448
5449
|
className: cn(
|
|
5449
|
-
"z-50 w-fit origin-(--radix-tooltip-content-transform-origin) animate-in rounded-md bg-primary border-0 px-3 py-1.5 text-xs font-medium text-balance text-on-
|
|
5450
|
+
"z-50 w-fit origin-(--radix-tooltip-content-transform-origin) animate-in rounded-md bg-primary border-0 px-3 py-1.5 text-xs font-medium text-balance text-on-primary fade-in-0 zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95",
|
|
5450
5451
|
className
|
|
5451
5452
|
)
|
|
5452
5453
|
}, props), {
|
|
@@ -6164,7 +6165,7 @@ function Slider(_a) {
|
|
|
6164
6165
|
);
|
|
6165
6166
|
}
|
|
6166
6167
|
|
|
6167
|
-
// components/ui/
|
|
6168
|
+
// components/ui/toast.tsx
|
|
6168
6169
|
var import_lucide_react21 = require("lucide-react");
|
|
6169
6170
|
var import_next_themes = require("next-themes");
|
|
6170
6171
|
var import_sonner = require("sonner");
|
|
@@ -6190,15 +6191,15 @@ var Toaster = (_a) => {
|
|
|
6190
6191
|
},
|
|
6191
6192
|
toastOptions: {
|
|
6192
6193
|
classNames: {
|
|
6193
|
-
toast: "!bg-[var(--
|
|
6194
|
-
title: "!text-[var(--on-prominent-
|
|
6195
|
-
description: "!text-[var(--on-prominent-
|
|
6196
|
-
actionButton: "!bg-[var(--primary)] !text-[var(--on-
|
|
6194
|
+
toast: "!bg-[var(--prominent-inverse)] !border-none",
|
|
6195
|
+
title: "!text-[var(--on-prominent-inverse)] !font-display !font-bold",
|
|
6196
|
+
description: "!text-[var(--on-prominent-inverse)] !opacity-60 !font-body",
|
|
6197
|
+
actionButton: "!bg-[var(--primary-inverse)] !text-[var(--on-primary-inverse)]"
|
|
6197
6198
|
}
|
|
6198
6199
|
},
|
|
6199
6200
|
style: {
|
|
6200
|
-
"--normal-bg": "var(--
|
|
6201
|
-
"--normal-text": "var(--on-prominent-
|
|
6201
|
+
"--normal-bg": "var(--prominent-inverse)",
|
|
6202
|
+
"--normal-text": "var(--on-prominent-inverse)",
|
|
6202
6203
|
"--normal-border": "transparent",
|
|
6203
6204
|
"--border-radius": "var(--radius)"
|
|
6204
6205
|
}
|
|
@@ -6674,14 +6675,14 @@ function TicketCard({
|
|
|
6674
6675
|
}
|
|
6675
6676
|
}
|
|
6676
6677
|
),
|
|
6677
|
-
/* @__PURE__ */ (0, import_jsx_runtime57.jsx)(import_lucide_react23.ArrowRight, { className: "size-4 text-on-
|
|
6678
|
-
/* @__PURE__ */ (0, import_jsx_runtime57.jsx)("span", { className: "text-sm font-semibold text-on-
|
|
6678
|
+
/* @__PURE__ */ (0, import_jsx_runtime57.jsx)(import_lucide_react23.ArrowRight, { className: "size-4 text-on-primary" }),
|
|
6679
|
+
/* @__PURE__ */ (0, import_jsx_runtime57.jsx)("span", { className: "text-sm font-semibold text-on-primary", children: stubLabel })
|
|
6679
6680
|
]
|
|
6680
6681
|
}
|
|
6681
6682
|
)
|
|
6682
6683
|
] }) });
|
|
6683
6684
|
}
|
|
6684
|
-
function
|
|
6685
|
+
function BoostTicketCard({
|
|
6685
6686
|
className,
|
|
6686
6687
|
icon,
|
|
6687
6688
|
label,
|
|
@@ -6690,8 +6691,8 @@ function CreditTicketCard({
|
|
|
6690
6691
|
stubLabel,
|
|
6691
6692
|
onStubClick,
|
|
6692
6693
|
stubDisabled = false,
|
|
6693
|
-
|
|
6694
|
-
|
|
6694
|
+
boostAmount = "0.00",
|
|
6695
|
+
boostCurrency = "USDT",
|
|
6695
6696
|
compact = false
|
|
6696
6697
|
}) {
|
|
6697
6698
|
return /* @__PURE__ */ (0, import_jsx_runtime57.jsx)("div", { className: cn("flex w-full flex-col gap-2", className), children: /* @__PURE__ */ (0, import_jsx_runtime57.jsxs)("div", { className: "relative flex w-full items-stretch justify-between rounded-sm bg-subtle", children: [
|
|
@@ -6708,12 +6709,13 @@ function CreditTicketCard({
|
|
|
6708
6709
|
] })
|
|
6709
6710
|
] })
|
|
6710
6711
|
] }),
|
|
6711
|
-
/* @__PURE__ */ (0, import_jsx_runtime57.jsxs)(Badge, { variant: "fill-
|
|
6712
|
-
/* @__PURE__ */ (0, import_jsx_runtime57.jsx)(import_lucide_react23.
|
|
6713
|
-
"
|
|
6714
|
-
|
|
6712
|
+
/* @__PURE__ */ (0, import_jsx_runtime57.jsxs)(Badge, { variant: "fill-boost", size: "sm", className: "!gap-1 !font-medium !tracking-normal", children: [
|
|
6713
|
+
/* @__PURE__ */ (0, import_jsx_runtime57.jsx)(import_lucide_react23.Rocket, { className: "!size-3.5", strokeWidth: 2 }),
|
|
6714
|
+
"Boost: ",
|
|
6715
|
+
boostAmount,
|
|
6715
6716
|
" ",
|
|
6716
|
-
|
|
6717
|
+
boostCurrency,
|
|
6718
|
+
/* @__PURE__ */ (0, import_jsx_runtime57.jsx)(import_lucide_react23.Info, { className: "!size-3.5", strokeWidth: 2, "aria-label": "More info about boost" })
|
|
6717
6719
|
] })
|
|
6718
6720
|
] })
|
|
6719
6721
|
] }),
|
|
@@ -6754,8 +6756,8 @@ function CreditTicketCard({
|
|
|
6754
6756
|
}
|
|
6755
6757
|
}
|
|
6756
6758
|
),
|
|
6757
|
-
/* @__PURE__ */ (0, import_jsx_runtime57.jsx)(import_lucide_react23.ArrowRight, { className: "size-4 text-on-
|
|
6758
|
-
/* @__PURE__ */ (0, import_jsx_runtime57.jsx)("span", { className: "text-sm font-semibold text-on-
|
|
6759
|
+
/* @__PURE__ */ (0, import_jsx_runtime57.jsx)(import_lucide_react23.ArrowRight, { className: "size-4 text-on-primary" }),
|
|
6760
|
+
/* @__PURE__ */ (0, import_jsx_runtime57.jsx)("span", { className: "text-sm font-semibold text-on-primary", children: stubLabel })
|
|
6759
6761
|
]
|
|
6760
6762
|
}
|
|
6761
6763
|
)
|
|
@@ -6909,6 +6911,7 @@ function ToggleGroupItem(_a) {
|
|
|
6909
6911
|
AvatarGroupCount,
|
|
6910
6912
|
AvatarImage,
|
|
6911
6913
|
Badge,
|
|
6914
|
+
BoostTicketCard,
|
|
6912
6915
|
Breadcrumb,
|
|
6913
6916
|
BreadcrumbEllipsis,
|
|
6914
6917
|
BreadcrumbItem,
|
|
@@ -6980,7 +6983,6 @@ function ToggleGroupItem(_a) {
|
|
|
6980
6983
|
ContextMenuSubContent,
|
|
6981
6984
|
ContextMenuSubTrigger,
|
|
6982
6985
|
ContextMenuTrigger,
|
|
6983
|
-
CreditTicketCard,
|
|
6984
6986
|
Dialog,
|
|
6985
6987
|
DialogClose,
|
|
6986
6988
|
DialogContent,
|
|
@@ -7196,6 +7198,7 @@ function ToggleGroupItem(_a) {
|
|
|
7196
7198
|
navigationButtonVariants,
|
|
7197
7199
|
navigationMenuTriggerStyle,
|
|
7198
7200
|
tabsListVariants,
|
|
7201
|
+
toast,
|
|
7199
7202
|
toggleVariants,
|
|
7200
7203
|
useComboboxAnchor,
|
|
7201
7204
|
useDirection,
|