@trading-game/design-intelligence-layer 0.15.0 → 0.15.1
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 +2 -2
- package/dist/index.cjs +24 -21
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +21 -17
- package/dist/index.d.ts +21 -17
- package/dist/index.js +24 -21
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -65,7 +65,7 @@ declare function AvatarGroup({ className, ...props }: React$1.ComponentProps<"di
|
|
|
65
65
|
declare function AvatarGroupCount({ className, ...props }: React$1.ComponentProps<"div">): react_jsx_runtime.JSX.Element;
|
|
66
66
|
|
|
67
67
|
declare const badgeVariants: (props?: ({
|
|
68
|
-
variant?: "fill" | "default" | "standard" | "default-success" | "default-fail" | "default-warning" | "fill-success" | "fill-fail" | "fill-warning" | "fill-
|
|
68
|
+
variant?: "fill" | "default" | "standard" | "default-success" | "default-fail" | "default-warning" | "fill-success" | "fill-fail" | "fill-warning" | "fill-credit" | "ghost" | "ghost-success" | "ghost-fail" | "ghost-warning" | null | undefined;
|
|
69
69
|
size?: "lg" | "md" | "sm" | null | undefined;
|
|
70
70
|
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
71
71
|
declare function Badge({ className, variant, size, asChild, ...props }: React$1.ComponentProps<"span"> & VariantProps<typeof badgeVariants> & {
|
|
@@ -662,7 +662,7 @@ type TicketCardProps = {
|
|
|
662
662
|
compact?: boolean;
|
|
663
663
|
};
|
|
664
664
|
declare function TicketCard({ className, icon, label, value, currency, stubLabel, onStubClick, stubDisabled, compact, }: TicketCardProps): react_jsx_runtime.JSX.Element;
|
|
665
|
-
type
|
|
665
|
+
type CreditTicketCardProps = {
|
|
666
666
|
className?: string;
|
|
667
667
|
/** Optional icon rendered inside the left ring circle. */
|
|
668
668
|
icon?: React$1.ReactNode;
|
|
@@ -678,45 +678,49 @@ type BoostTicketCardProps = {
|
|
|
678
678
|
onStubClick?: () => void;
|
|
679
679
|
/** Disables the stub button. */
|
|
680
680
|
stubDisabled?: boolean;
|
|
681
|
-
/**
|
|
682
|
-
|
|
683
|
-
/**
|
|
684
|
-
|
|
681
|
+
/** Optional leading icon shown inside the credit badge. */
|
|
682
|
+
badgeIcon?: React$1.ReactNode;
|
|
683
|
+
/** Prefix label shown inside the badge (e.g. "Credit", "Bonus"). */
|
|
684
|
+
badgeLabel?: string;
|
|
685
|
+
/** Value shown in the badge (e.g. "0.00"). */
|
|
686
|
+
badgeValue?: string;
|
|
687
|
+
/** Currency shown in the badge (e.g. "USDT"). */
|
|
688
|
+
badgeCurrency?: string;
|
|
685
689
|
/**
|
|
686
|
-
* Optional content for the
|
|
687
|
-
* info icon on the
|
|
690
|
+
* Optional content for the badge info tooltip. When provided, the trailing
|
|
691
|
+
* info icon on the badge becomes a focusable button that opens a
|
|
688
692
|
* tooltip with this content on hover/focus. When omitted, the info icon is
|
|
689
693
|
* not rendered.
|
|
690
694
|
*/
|
|
691
|
-
|
|
695
|
+
badgeInfo?: React$1.ReactNode;
|
|
692
696
|
/**
|
|
693
|
-
* Side the
|
|
697
|
+
* Side the badge info tooltip opens on (desktop only — mobile always renders
|
|
694
698
|
* the info as a bottom-sheet drawer). Defaults to `"top"` to preserve the
|
|
695
699
|
* current behaviour.
|
|
696
700
|
*/
|
|
697
|
-
|
|
701
|
+
badgeInfoSide?: "top" | "bottom" | "left" | "right";
|
|
698
702
|
/**
|
|
699
|
-
* Alignment of the
|
|
703
|
+
* Alignment of the badge info tooltip relative to its trigger (desktop only).
|
|
700
704
|
* Defaults to `"center"`.
|
|
701
705
|
*/
|
|
702
|
-
|
|
706
|
+
badgeInfoAlign?: "start" | "center" | "end";
|
|
703
707
|
/**
|
|
704
708
|
* Heading shown at the top of the mobile drawer (forwarded to
|
|
705
709
|
* `TooltipContent.title`). Desktop tooltip ignores this. When omitted, the
|
|
706
710
|
* underlying `TooltipContent` falls back to its own `"Title"` placeholder.
|
|
707
711
|
*/
|
|
708
|
-
|
|
712
|
+
badgeInfoTitle?: string;
|
|
709
713
|
/**
|
|
710
714
|
* Label on the dismiss button at the bottom of the mobile drawer (forwarded
|
|
711
715
|
* to `TooltipContent.closeLabel`). Desktop tooltip ignores this. When
|
|
712
716
|
* omitted, the underlying `TooltipContent` falls back to its own `"Label"`
|
|
713
717
|
* placeholder.
|
|
714
718
|
*/
|
|
715
|
-
|
|
719
|
+
badgeInfoCloseLabel?: string;
|
|
716
720
|
/** Compact (mobile) layout — reduces horizontal padding from 16px to 8px. */
|
|
717
721
|
compact?: boolean;
|
|
718
722
|
};
|
|
719
|
-
declare function
|
|
723
|
+
declare function CreditTicketCard({ className, icon, label, value, currency, stubLabel, onStubClick, stubDisabled, badgeIcon, badgeLabel, badgeValue, badgeCurrency, badgeInfo, badgeInfoSide, badgeInfoAlign, badgeInfoTitle, badgeInfoCloseLabel, compact, }: CreditTicketCardProps): react_jsx_runtime.JSX.Element;
|
|
720
724
|
/** Alias for the Figma-named variant. */
|
|
721
725
|
declare const TicketCardDesktop: typeof TicketCard;
|
|
722
726
|
|
|
@@ -920,4 +924,4 @@ declare function cn(...inputs: ClassValue[]): string;
|
|
|
920
924
|
|
|
921
925
|
declare function useIsMobile(): boolean;
|
|
922
926
|
|
|
923
|
-
export { Accordion, AccordionContent, AccordionItem, AccordionTrigger, Alert, AlertDescription, AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogMedia, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger, AlertTitle, AspectRatio, AuthBlock, type AuthBlockMode, type AuthBlockProps, type AuthBlockProvider, Avatar, AvatarBadge, AvatarFallback, AvatarGroup, AvatarGroupCount, AvatarImage, Badge,
|
|
927
|
+
export { Accordion, AccordionContent, AccordionItem, AccordionTrigger, Alert, AlertDescription, AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogMedia, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger, AlertTitle, AspectRatio, AuthBlock, type AuthBlockMode, type AuthBlockProps, type AuthBlockProvider, Avatar, AvatarBadge, AvatarFallback, AvatarGroup, AvatarGroupCount, AvatarImage, Badge, type BoxOPosition, Breadcrumb, BreadcrumbEllipsis, BreadcrumbItem, BreadcrumbLink, BreadcrumbList, BreadcrumbPage, BreadcrumbSeparator, Button, Calendar, CalendarDayButton, Card, CardAction, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, Carousel, type CarouselApi, CarouselContent, CarouselItem, CarouselNext, CarouselPrevious, type ChartConfig, ChartContainer, ChartLegend, ChartLegendContent, ChartStyle, ChartTooltip, ChartTooltipContent, Checkbox, Collapsible, CollapsibleContent, CollapsibleTrigger, Combobox, ComboboxChip, ComboboxChips, ComboboxChipsInput, ComboboxCollection, ComboboxContent, ComboboxEmpty, ComboboxGroup, ComboboxInput, ComboboxItem, ComboboxLabel, ComboboxList, ComboboxSeparator, ComboboxTrigger, ComboboxValue, Command, CommandDialog, CommandEmpty, CommandGroup, CommandInput, CommandItem, CommandList, CommandSeparator, CommandShortcut, ContextMenu, ContextMenuCheckboxItem, ContextMenuContent, ContextMenuGroup, ContextMenuItem, ContextMenuLabel, ContextMenuPortal, ContextMenuRadioGroup, ContextMenuRadioItem, ContextMenuSeparator, ContextMenuShortcut, ContextMenuSub, ContextMenuSubContent, ContextMenuSubTrigger, ContextMenuTrigger, CreditTicketCard, type CreditTicketCardProps, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, type DigitsPosition, DirectionProvider, Drawer, DrawerClose, DrawerContent, DrawerDescription, DrawerFooter, DrawerHeader, DrawerOverlay, DrawerPortal, DrawerTitle, DrawerTrigger, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, Empty, EmptyContent, EmptyDescription, EmptyHeader, EmptyMedia, EmptyTitle, FAQBlock, type FAQBlockProps, type FAQItem, Field, FieldContent, FieldDescription, FieldError, FieldGroup, FieldLabel, FieldLegend, FieldSeparator, FieldSet, FieldTitle, Form, FormControl, FormDescription, FormField, FormItem, FormLabel, FormMessage, HeaderNavigationBlock, type HeaderNavigationBlockProps, HeroBlock, type HeroBlockCta, type HeroBlockProps, type HeroBlockTagline, HoverCard, HoverCardContent, HoverCardTrigger, Input, InputGroup, InputGroupAddon, InputGroupButton, InputGroupInput, InputGroupText, InputGroupTextarea, InputOTP, InputOTPGroup, InputOTPSeparator, InputOTPSlot, Item, ItemActions, ItemContent, ItemDescription, ItemFooter, ItemGroup, ItemHeader, ItemMedia, ItemSeparator, ItemTitle, Kbd, KbdGroup, Label, Link, Menubar, MenubarCheckboxItem, MenubarContent, MenubarGroup, MenubarItem, MenubarLabel, MenubarMenu, MenubarPortal, MenubarRadioGroup, MenubarRadioItem, MenubarSeparator, MenubarShortcut, MenubarSub, MenubarSubContent, MenubarSubTrigger, MenubarTrigger, NativeSelect, NativeSelectOptGroup, NativeSelectOption, NavBarBlock, type NavBarBlockLink, type NavBarBlockProps, NavigationButton, NavigationMenu, NavigationMenuContent, NavigationMenuIndicator, NavigationMenuItem, NavigationMenuLink, NavigationMenuList, NavigationMenuTrigger, NavigationMenuViewport, OpenPositionsBlock, type OpenPositionsBlockProps, Pagination, PaginationContent, PaginationEllipsis, PaginationItem, PaginationLink, PaginationNext, PaginationPrevious, Popover, PopoverAnchor, PopoverContent, PopoverDescription, PopoverHeader, PopoverTitle, PopoverTrigger, type Position, Progress, RadioGroup, RadioGroupItem, ResizableHandle, ResizablePanel, ResizablePanelGroup, ResultBlock, type ResultBlockCta, type ResultBlockProps, type ResultBlockStatus, ResultDialog, type ResultDialogProps, type RiseFallPosition, ScrollArea, ScrollBar, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, Separator, Sheet, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetTitle, SheetTrigger, Sidebar, SidebarContent, SidebarFooter, SidebarGroup, SidebarGroupAction, SidebarGroupContent, SidebarGroupLabel, SidebarHeader, SidebarInput, SidebarInset, SidebarMenu, SidebarMenuAction, SidebarMenuBadge, SidebarMenuButton, SidebarMenuItem, SidebarMenuSkeleton, SidebarMenuSub, SidebarMenuSubButton, SidebarMenuSubItem, SidebarProvider, SidebarRail, SidebarSeparator, SidebarTrigger, Skeleton, Slider, Spinner, Stepper, type StepperProps, type StepperSize, type SwipePosition, Switch, Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeader, TableRow, Tabs, TabsContent, TabsList, TabsTrigger, Textarea, TicketCard, TicketCardDesktop, type TicketCardProps, Toaster, Toggle, ToggleGroup, ToggleGroupItem, Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, type TooltipVariant, badgeVariants, buttonVariants, cn, inputVariants, linkVariants, navigationButtonVariants, navigationMenuTriggerStyle, tabsListVariants, toggleVariants, useComboboxAnchor, useDirection, useFormField, useIsMobile, useSidebar };
|
package/dist/index.d.ts
CHANGED
|
@@ -65,7 +65,7 @@ declare function AvatarGroup({ className, ...props }: React$1.ComponentProps<"di
|
|
|
65
65
|
declare function AvatarGroupCount({ className, ...props }: React$1.ComponentProps<"div">): react_jsx_runtime.JSX.Element;
|
|
66
66
|
|
|
67
67
|
declare const badgeVariants: (props?: ({
|
|
68
|
-
variant?: "fill" | "default" | "standard" | "default-success" | "default-fail" | "default-warning" | "fill-success" | "fill-fail" | "fill-warning" | "fill-
|
|
68
|
+
variant?: "fill" | "default" | "standard" | "default-success" | "default-fail" | "default-warning" | "fill-success" | "fill-fail" | "fill-warning" | "fill-credit" | "ghost" | "ghost-success" | "ghost-fail" | "ghost-warning" | null | undefined;
|
|
69
69
|
size?: "lg" | "md" | "sm" | null | undefined;
|
|
70
70
|
} & class_variance_authority_types.ClassProp) | undefined) => string;
|
|
71
71
|
declare function Badge({ className, variant, size, asChild, ...props }: React$1.ComponentProps<"span"> & VariantProps<typeof badgeVariants> & {
|
|
@@ -662,7 +662,7 @@ type TicketCardProps = {
|
|
|
662
662
|
compact?: boolean;
|
|
663
663
|
};
|
|
664
664
|
declare function TicketCard({ className, icon, label, value, currency, stubLabel, onStubClick, stubDisabled, compact, }: TicketCardProps): react_jsx_runtime.JSX.Element;
|
|
665
|
-
type
|
|
665
|
+
type CreditTicketCardProps = {
|
|
666
666
|
className?: string;
|
|
667
667
|
/** Optional icon rendered inside the left ring circle. */
|
|
668
668
|
icon?: React$1.ReactNode;
|
|
@@ -678,45 +678,49 @@ type BoostTicketCardProps = {
|
|
|
678
678
|
onStubClick?: () => void;
|
|
679
679
|
/** Disables the stub button. */
|
|
680
680
|
stubDisabled?: boolean;
|
|
681
|
-
/**
|
|
682
|
-
|
|
683
|
-
/**
|
|
684
|
-
|
|
681
|
+
/** Optional leading icon shown inside the credit badge. */
|
|
682
|
+
badgeIcon?: React$1.ReactNode;
|
|
683
|
+
/** Prefix label shown inside the badge (e.g. "Credit", "Bonus"). */
|
|
684
|
+
badgeLabel?: string;
|
|
685
|
+
/** Value shown in the badge (e.g. "0.00"). */
|
|
686
|
+
badgeValue?: string;
|
|
687
|
+
/** Currency shown in the badge (e.g. "USDT"). */
|
|
688
|
+
badgeCurrency?: string;
|
|
685
689
|
/**
|
|
686
|
-
* Optional content for the
|
|
687
|
-
* info icon on the
|
|
690
|
+
* Optional content for the badge info tooltip. When provided, the trailing
|
|
691
|
+
* info icon on the badge becomes a focusable button that opens a
|
|
688
692
|
* tooltip with this content on hover/focus. When omitted, the info icon is
|
|
689
693
|
* not rendered.
|
|
690
694
|
*/
|
|
691
|
-
|
|
695
|
+
badgeInfo?: React$1.ReactNode;
|
|
692
696
|
/**
|
|
693
|
-
* Side the
|
|
697
|
+
* Side the badge info tooltip opens on (desktop only — mobile always renders
|
|
694
698
|
* the info as a bottom-sheet drawer). Defaults to `"top"` to preserve the
|
|
695
699
|
* current behaviour.
|
|
696
700
|
*/
|
|
697
|
-
|
|
701
|
+
badgeInfoSide?: "top" | "bottom" | "left" | "right";
|
|
698
702
|
/**
|
|
699
|
-
* Alignment of the
|
|
703
|
+
* Alignment of the badge info tooltip relative to its trigger (desktop only).
|
|
700
704
|
* Defaults to `"center"`.
|
|
701
705
|
*/
|
|
702
|
-
|
|
706
|
+
badgeInfoAlign?: "start" | "center" | "end";
|
|
703
707
|
/**
|
|
704
708
|
* Heading shown at the top of the mobile drawer (forwarded to
|
|
705
709
|
* `TooltipContent.title`). Desktop tooltip ignores this. When omitted, the
|
|
706
710
|
* underlying `TooltipContent` falls back to its own `"Title"` placeholder.
|
|
707
711
|
*/
|
|
708
|
-
|
|
712
|
+
badgeInfoTitle?: string;
|
|
709
713
|
/**
|
|
710
714
|
* Label on the dismiss button at the bottom of the mobile drawer (forwarded
|
|
711
715
|
* to `TooltipContent.closeLabel`). Desktop tooltip ignores this. When
|
|
712
716
|
* omitted, the underlying `TooltipContent` falls back to its own `"Label"`
|
|
713
717
|
* placeholder.
|
|
714
718
|
*/
|
|
715
|
-
|
|
719
|
+
badgeInfoCloseLabel?: string;
|
|
716
720
|
/** Compact (mobile) layout — reduces horizontal padding from 16px to 8px. */
|
|
717
721
|
compact?: boolean;
|
|
718
722
|
};
|
|
719
|
-
declare function
|
|
723
|
+
declare function CreditTicketCard({ className, icon, label, value, currency, stubLabel, onStubClick, stubDisabled, badgeIcon, badgeLabel, badgeValue, badgeCurrency, badgeInfo, badgeInfoSide, badgeInfoAlign, badgeInfoTitle, badgeInfoCloseLabel, compact, }: CreditTicketCardProps): react_jsx_runtime.JSX.Element;
|
|
720
724
|
/** Alias for the Figma-named variant. */
|
|
721
725
|
declare const TicketCardDesktop: typeof TicketCard;
|
|
722
726
|
|
|
@@ -920,4 +924,4 @@ declare function cn(...inputs: ClassValue[]): string;
|
|
|
920
924
|
|
|
921
925
|
declare function useIsMobile(): boolean;
|
|
922
926
|
|
|
923
|
-
export { Accordion, AccordionContent, AccordionItem, AccordionTrigger, Alert, AlertDescription, AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogMedia, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger, AlertTitle, AspectRatio, AuthBlock, type AuthBlockMode, type AuthBlockProps, type AuthBlockProvider, Avatar, AvatarBadge, AvatarFallback, AvatarGroup, AvatarGroupCount, AvatarImage, Badge,
|
|
927
|
+
export { Accordion, AccordionContent, AccordionItem, AccordionTrigger, Alert, AlertDescription, AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogMedia, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger, AlertTitle, AspectRatio, AuthBlock, type AuthBlockMode, type AuthBlockProps, type AuthBlockProvider, Avatar, AvatarBadge, AvatarFallback, AvatarGroup, AvatarGroupCount, AvatarImage, Badge, type BoxOPosition, Breadcrumb, BreadcrumbEllipsis, BreadcrumbItem, BreadcrumbLink, BreadcrumbList, BreadcrumbPage, BreadcrumbSeparator, Button, Calendar, CalendarDayButton, Card, CardAction, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, Carousel, type CarouselApi, CarouselContent, CarouselItem, CarouselNext, CarouselPrevious, type ChartConfig, ChartContainer, ChartLegend, ChartLegendContent, ChartStyle, ChartTooltip, ChartTooltipContent, Checkbox, Collapsible, CollapsibleContent, CollapsibleTrigger, Combobox, ComboboxChip, ComboboxChips, ComboboxChipsInput, ComboboxCollection, ComboboxContent, ComboboxEmpty, ComboboxGroup, ComboboxInput, ComboboxItem, ComboboxLabel, ComboboxList, ComboboxSeparator, ComboboxTrigger, ComboboxValue, Command, CommandDialog, CommandEmpty, CommandGroup, CommandInput, CommandItem, CommandList, CommandSeparator, CommandShortcut, ContextMenu, ContextMenuCheckboxItem, ContextMenuContent, ContextMenuGroup, ContextMenuItem, ContextMenuLabel, ContextMenuPortal, ContextMenuRadioGroup, ContextMenuRadioItem, ContextMenuSeparator, ContextMenuShortcut, ContextMenuSub, ContextMenuSubContent, ContextMenuSubTrigger, ContextMenuTrigger, CreditTicketCard, type CreditTicketCardProps, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, type DigitsPosition, DirectionProvider, Drawer, DrawerClose, DrawerContent, DrawerDescription, DrawerFooter, DrawerHeader, DrawerOverlay, DrawerPortal, DrawerTitle, DrawerTrigger, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuSub, DropdownMenuSubContent, DropdownMenuSubTrigger, DropdownMenuTrigger, Empty, EmptyContent, EmptyDescription, EmptyHeader, EmptyMedia, EmptyTitle, FAQBlock, type FAQBlockProps, type FAQItem, Field, FieldContent, FieldDescription, FieldError, FieldGroup, FieldLabel, FieldLegend, FieldSeparator, FieldSet, FieldTitle, Form, FormControl, FormDescription, FormField, FormItem, FormLabel, FormMessage, HeaderNavigationBlock, type HeaderNavigationBlockProps, HeroBlock, type HeroBlockCta, type HeroBlockProps, type HeroBlockTagline, HoverCard, HoverCardContent, HoverCardTrigger, Input, InputGroup, InputGroupAddon, InputGroupButton, InputGroupInput, InputGroupText, InputGroupTextarea, InputOTP, InputOTPGroup, InputOTPSeparator, InputOTPSlot, Item, ItemActions, ItemContent, ItemDescription, ItemFooter, ItemGroup, ItemHeader, ItemMedia, ItemSeparator, ItemTitle, Kbd, KbdGroup, Label, Link, Menubar, MenubarCheckboxItem, MenubarContent, MenubarGroup, MenubarItem, MenubarLabel, MenubarMenu, MenubarPortal, MenubarRadioGroup, MenubarRadioItem, MenubarSeparator, MenubarShortcut, MenubarSub, MenubarSubContent, MenubarSubTrigger, MenubarTrigger, NativeSelect, NativeSelectOptGroup, NativeSelectOption, NavBarBlock, type NavBarBlockLink, type NavBarBlockProps, NavigationButton, NavigationMenu, NavigationMenuContent, NavigationMenuIndicator, NavigationMenuItem, NavigationMenuLink, NavigationMenuList, NavigationMenuTrigger, NavigationMenuViewport, OpenPositionsBlock, type OpenPositionsBlockProps, Pagination, PaginationContent, PaginationEllipsis, PaginationItem, PaginationLink, PaginationNext, PaginationPrevious, Popover, PopoverAnchor, PopoverContent, PopoverDescription, PopoverHeader, PopoverTitle, PopoverTrigger, type Position, Progress, RadioGroup, RadioGroupItem, ResizableHandle, ResizablePanel, ResizablePanelGroup, ResultBlock, type ResultBlockCta, type ResultBlockProps, type ResultBlockStatus, ResultDialog, type ResultDialogProps, type RiseFallPosition, ScrollArea, ScrollBar, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, Separator, Sheet, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetTitle, SheetTrigger, Sidebar, SidebarContent, SidebarFooter, SidebarGroup, SidebarGroupAction, SidebarGroupContent, SidebarGroupLabel, SidebarHeader, SidebarInput, SidebarInset, SidebarMenu, SidebarMenuAction, SidebarMenuBadge, SidebarMenuButton, SidebarMenuItem, SidebarMenuSkeleton, SidebarMenuSub, SidebarMenuSubButton, SidebarMenuSubItem, SidebarProvider, SidebarRail, SidebarSeparator, SidebarTrigger, Skeleton, Slider, Spinner, Stepper, type StepperProps, type StepperSize, type SwipePosition, Switch, Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeader, TableRow, Tabs, TabsContent, TabsList, TabsTrigger, Textarea, TicketCard, TicketCardDesktop, type TicketCardProps, Toaster, Toggle, ToggleGroup, ToggleGroupItem, Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, type TooltipVariant, badgeVariants, buttonVariants, cn, inputVariants, linkVariants, navigationButtonVariants, navigationMenuTriggerStyle, tabsListVariants, toggleVariants, useComboboxAnchor, useDirection, useFormField, useIsMobile, useSidebar };
|
package/dist/index.js
CHANGED
|
@@ -604,7 +604,7 @@ var badgeVariants = cva3(
|
|
|
604
604
|
"fill-success": "bg-semantic-win/10 border-transparent text-semantic-win",
|
|
605
605
|
"fill-fail": "bg-semantic-loss/10 border-transparent text-semantic-loss",
|
|
606
606
|
"fill-warning": "bg-semantic-warning/10 border-transparent text-semantic-warning",
|
|
607
|
-
"fill-
|
|
607
|
+
"fill-credit": "bg-semantic-boost/16 border-transparent text-on-semantic-boost !text-xs !font-semibold",
|
|
608
608
|
// Ghost (transparent)
|
|
609
609
|
ghost: "bg-transparent border-transparent text-primary [a&]:hover:bg-secondary-hover [a&]:hover:text-primary",
|
|
610
610
|
"ghost-success": "bg-transparent border-transparent text-semantic-win [a&]:hover:bg-semantic-win/10 [a&]:hover:text-semantic-win",
|
|
@@ -6319,7 +6319,7 @@ function TabsContent(_a) {
|
|
|
6319
6319
|
}
|
|
6320
6320
|
|
|
6321
6321
|
// components/ui/ticket-card.tsx
|
|
6322
|
-
import { ArrowRight as ArrowRight2, Info
|
|
6322
|
+
import { ArrowRight as ArrowRight2, Info } from "lucide-react";
|
|
6323
6323
|
import { Fragment as Fragment3, jsx as jsx57, jsxs as jsxs27 } from "react/jsx-runtime";
|
|
6324
6324
|
function formatBalanceValue(raw) {
|
|
6325
6325
|
const match = raw.match(/^(\D*)([\d,]+(?:\.\d+)?)(\D*)$/);
|
|
@@ -6402,7 +6402,7 @@ function TicketCard({
|
|
|
6402
6402
|
)
|
|
6403
6403
|
] }) });
|
|
6404
6404
|
}
|
|
6405
|
-
function
|
|
6405
|
+
function CreditTicketCard({
|
|
6406
6406
|
className,
|
|
6407
6407
|
icon,
|
|
6408
6408
|
label,
|
|
@@ -6411,34 +6411,37 @@ function BoostTicketCard({
|
|
|
6411
6411
|
stubLabel,
|
|
6412
6412
|
onStubClick,
|
|
6413
6413
|
stubDisabled = false,
|
|
6414
|
-
|
|
6415
|
-
|
|
6416
|
-
|
|
6417
|
-
|
|
6418
|
-
|
|
6419
|
-
|
|
6420
|
-
|
|
6414
|
+
badgeIcon,
|
|
6415
|
+
badgeLabel = "Label",
|
|
6416
|
+
badgeValue = "0.00",
|
|
6417
|
+
badgeCurrency = "USDT",
|
|
6418
|
+
badgeInfo,
|
|
6419
|
+
badgeInfoSide = "top",
|
|
6420
|
+
badgeInfoAlign = "center",
|
|
6421
|
+
badgeInfoTitle,
|
|
6422
|
+
badgeInfoCloseLabel,
|
|
6421
6423
|
compact = false
|
|
6422
6424
|
}) {
|
|
6423
6425
|
return /* @__PURE__ */ jsx57("div", { className: cn("flex w-full flex-col gap-2", className), children: /* @__PURE__ */ jsxs27("div", { className: "relative flex w-full items-stretch justify-between rounded-sm bg-subtle", children: [
|
|
6424
6426
|
(() => {
|
|
6425
|
-
const
|
|
6426
|
-
|
|
6427
|
-
|
|
6428
|
-
|
|
6427
|
+
const creditBadge = /* @__PURE__ */ jsxs27(Badge, { variant: "fill-credit", size: "sm", className: "!gap-1 !font-medium !tracking-normal", children: [
|
|
6428
|
+
badgeIcon,
|
|
6429
|
+
badgeLabel,
|
|
6430
|
+
": ",
|
|
6431
|
+
badgeValue,
|
|
6429
6432
|
" ",
|
|
6430
|
-
|
|
6431
|
-
|
|
6433
|
+
badgeCurrency,
|
|
6434
|
+
badgeInfo && /* @__PURE__ */ jsx57(TooltipProvider, { children: /* @__PURE__ */ jsxs27(Tooltip2, { children: [
|
|
6432
6435
|
/* @__PURE__ */ jsx57(TooltipTrigger, { asChild: true, children: /* @__PURE__ */ jsx57(
|
|
6433
6436
|
"button",
|
|
6434
6437
|
{
|
|
6435
6438
|
type: "button",
|
|
6436
|
-
"aria-label":
|
|
6439
|
+
"aria-label": `More info about ${badgeLabel.toLowerCase()}`,
|
|
6437
6440
|
className: "inline-flex shrink-0 items-center justify-center rounded-full text-on-semantic-boost outline-none transition-opacity hover:opacity-70 focus-visible:opacity-70 focus-visible:ring-2 focus-visible:ring-on-semantic-boost/40 cursor-pointer",
|
|
6438
6441
|
children: /* @__PURE__ */ jsx57(Info, { className: "!size-3.5", strokeWidth: 2 })
|
|
6439
6442
|
}
|
|
6440
6443
|
) }),
|
|
6441
|
-
/* @__PURE__ */ jsx57(TooltipContent, { side:
|
|
6444
|
+
/* @__PURE__ */ jsx57(TooltipContent, { side: badgeInfoSide, align: badgeInfoAlign, title: badgeInfoTitle, closeLabel: badgeInfoCloseLabel, variant: "inverse", className: "max-w-xs whitespace-normal", children: badgeInfo })
|
|
6442
6445
|
] }) })
|
|
6443
6446
|
] });
|
|
6444
6447
|
const labelValue = /* @__PURE__ */ jsxs27(Fragment3, { children: [
|
|
@@ -6457,7 +6460,7 @@ function BoostTicketCard({
|
|
|
6457
6460
|
/* Mobile / compact: badge stacked under the value */
|
|
6458
6461
|
/* @__PURE__ */ jsxs27("div", { className: "flex flex-col gap-2 whitespace-nowrap", children: [
|
|
6459
6462
|
/* @__PURE__ */ jsx57("div", { className: "flex flex-col gap-1", children: labelValue }),
|
|
6460
|
-
|
|
6463
|
+
creditBadge
|
|
6461
6464
|
] })
|
|
6462
6465
|
) : (
|
|
6463
6466
|
/* Desktop: badge inline next to the value (16px gap = gap-4) */
|
|
@@ -6471,7 +6474,7 @@ function BoostTicketCard({
|
|
|
6471
6474
|
/* @__PURE__ */ jsx57("span", { className: "text-sm text-on-subtle", children: currency })
|
|
6472
6475
|
] })
|
|
6473
6476
|
] }),
|
|
6474
|
-
|
|
6477
|
+
creditBadge
|
|
6475
6478
|
] })
|
|
6476
6479
|
] })
|
|
6477
6480
|
)
|
|
@@ -7159,7 +7162,6 @@ export {
|
|
|
7159
7162
|
AvatarGroupCount,
|
|
7160
7163
|
AvatarImage,
|
|
7161
7164
|
Badge,
|
|
7162
|
-
BoostTicketCard,
|
|
7163
7165
|
Breadcrumb,
|
|
7164
7166
|
BreadcrumbEllipsis,
|
|
7165
7167
|
BreadcrumbItem,
|
|
@@ -7231,6 +7233,7 @@ export {
|
|
|
7231
7233
|
ContextMenuSubContent,
|
|
7232
7234
|
ContextMenuSubTrigger,
|
|
7233
7235
|
ContextMenuTrigger,
|
|
7236
|
+
CreditTicketCard,
|
|
7234
7237
|
Dialog,
|
|
7235
7238
|
DialogClose,
|
|
7236
7239
|
DialogContent,
|