myshell-react-lib 0.1.19 → 0.1.21

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/index.d.cts CHANGED
@@ -141,13 +141,32 @@ declare const buttonVariants: (props?: ({
141
141
  color?: "default" | "brand" | "error" | null | undefined;
142
142
  size?: "sm" | "md" | "lg" | null | undefined;
143
143
  } & class_variance_authority_dist_types.ClassProp) | undefined) => string;
144
+ type VariantType$1 = 'primary' | 'secondary' | 'tertiary' | 'link' | 'plain' | 'opacity' | 'solid' | 'static';
145
+ type ButtonBaseProps = VariantProps<typeof buttonVariants>;
146
+ type VariantColorMap$1 = {
147
+ primary: 'default' | 'brand' | 'error';
148
+ secondary: 'default' | 'error';
149
+ tertiary: 'default';
150
+ link: 'default';
151
+ plain: 'default' | 'brand';
152
+ opacity: never;
153
+ solid: never;
154
+ static: never;
155
+ };
156
+ type ButtonProps$1<V extends VariantType$1 = VariantType$1> = Omit<ButtonBaseProps, 'color'> & {
157
+ variant?: V;
158
+ color?: V extends keyof VariantColorMap$1 ? VariantColorMap$1[V] : never;
159
+ };
144
160
 
145
- interface ButtonProps extends React$1.ButtonHTMLAttributes<HTMLButtonElement>, VariantProps<typeof buttonVariants> {
161
+ type ButtonProps = ButtonProps$1;
162
+ interface ButtonComponentProps<V extends VariantType$1 = VariantType$1> extends React$1.ButtonHTMLAttributes<HTMLButtonElement>, Omit<ButtonProps$1<V>, 'color'> {
146
163
  asChild?: boolean;
147
164
  loading?: boolean;
148
165
  icon?: React$1.ElementType;
149
166
  iconDirection?: 'left' | 'right';
150
- color?: 'default' | 'brand' | 'error';
167
+ variant?: V;
168
+ color?: V extends keyof VariantColorMap$1 ? VariantColorMap$1[V] : never;
169
+ size?: 'sm' | 'md' | 'lg';
151
170
  noStyle?: boolean;
152
171
  iconClassName?: string;
153
172
  iconOutBox?: boolean;
@@ -155,7 +174,11 @@ interface ButtonProps extends React$1.ButtonHTMLAttributes<HTMLButtonElement>, V
155
174
  asset?: 'energy' | 'coin';
156
175
  assetNumber?: number;
157
176
  }
158
- declare const Button: React$1.ForwardRefExoticComponent<ButtonProps & React$1.RefAttributes<HTMLButtonElement>>;
177
+ declare const Button: (<V extends VariantType$1>(props: ButtonComponentProps<V> & {
178
+ ref?: React$1.ForwardedRef<HTMLButtonElement>;
179
+ }) => JSX.Element) & {
180
+ displayName: string;
181
+ };
159
182
 
160
183
  interface CascaderOption {
161
184
  label: string;
@@ -381,29 +404,49 @@ declare const Icon: React$1.ForwardRefExoticComponent<React$1.HTMLAttributes<HTM
381
404
  } & React$1.RefAttributes<HTMLSpanElement>>;
382
405
  type IconComponent = React$1.ForwardRefExoticComponent<IconProps>;
383
406
 
407
+ type VariantType = 'primary' | 'secondary' | 'tertiary' | 'plain' | 'opacity' | 'solid' | 'static';
408
+ type ColorType = 'default' | 'brand' | 'error' | 'gray';
409
+ type SizeType = 'xs' | 'sm' | 'md' | 'lg';
384
410
  declare const iconButtonVariants: (props?: ({
385
- variant?: "opacity" | "static" | "primary" | "secondary" | "tertiary" | "plain" | "solid" | null | undefined;
386
- color?: "default" | "brand" | "error" | "gray" | null | undefined;
387
- size?: "xs" | "sm" | "md" | "lg" | null | undefined;
411
+ variant?: VariantType | null | undefined;
412
+ color?: ColorType | null | undefined;
413
+ size?: SizeType | null | undefined;
388
414
  } & class_variance_authority_dist_types.ClassProp) | undefined) => string;
389
415
  type IconButtonSize = 'xs' | 'sm' | 'md' | 'lg';
416
+ type IconButtonBaseProps = VariantProps<typeof iconButtonVariants>;
417
+ type VariantColorMap = {
418
+ primary: 'brand' | 'error';
419
+ secondary: 'default' | 'error';
420
+ tertiary: 'default';
421
+ plain: 'default' | 'error' | 'gray';
422
+ opacity: never;
423
+ solid: never;
424
+ static: never;
425
+ };
426
+ type IconButtonProps<V extends VariantType = VariantType> = Omit<IconButtonBaseProps, 'color'> & {
427
+ variant?: V;
428
+ color?: V extends keyof VariantColorMap ? VariantColorMap[V] : never;
429
+ };
390
430
 
391
431
  type HeroIcon$1 = React$1.ForwardRefExoticComponent<React$1.PropsWithoutRef<React$1.SVGProps<SVGSVGElement>> & {
392
432
  title?: string;
393
433
  titleId?: string;
394
434
  } & React$1.RefAttributes<SVGSVGElement>>;
395
- interface IconButtonProps extends React$1.ButtonHTMLAttributes<HTMLButtonElement>, VariantProps<typeof iconButtonVariants> {
435
+ interface IconButtonComponentProps<V extends VariantType = VariantType> extends Omit<React$1.ButtonHTMLAttributes<HTMLButtonElement>, 'color'>, IconButtonProps<V> {
396
436
  asChild?: boolean;
397
437
  loading?: boolean;
398
438
  disabled?: boolean;
399
- color?: 'default' | 'brand' | 'error' | 'gray';
400
439
  icon?: HeroIcon$1 | LucideIcon | IconComponent | React$1.ElementType;
401
440
  hoverText?: string;
402
441
  hoverSide?: 'top' | 'right' | 'bottom' | 'left';
403
442
  iconClassName?: ClassNameValue;
404
443
  size?: IconButtonSize;
444
+ variant?: V;
445
+ color?: V extends keyof VariantColorMap ? VariantColorMap[V] : never;
405
446
  }
406
- declare const IconButton: React$1.ForwardRefExoticComponent<IconButtonProps & React$1.RefAttributes<HTMLButtonElement>>;
447
+ declare const IconButton: <V extends VariantType>(props: IconButtonComponentProps<V> & {
448
+ ref?: React$1.ForwardedRef<HTMLButtonElement>;
449
+ }) => JSX.Element;
407
450
 
408
451
  interface ImageProps {
409
452
  /**
@@ -1571,4 +1614,4 @@ declare const RectangleGroupIcon: React$1.ForwardRefExoticComponent<React$1.HTML
1571
1614
  component?: React$1.ElementType;
1572
1615
  } & React$1.RefAttributes<SVGSVGElement>>;
1573
1616
 
1574
- export { Accordion, AccordionContent, AccordionItem, type AccordionItemProps, AccordionTrigger, Alert, AlertDescription, AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger, AlertTitle, ArrowLeftIcon, ArrowUpTrayIcon, AspectRatio, AudioPlayer, AudioPlaying, Avatar, AvatarImage, AvatarRoot, Badge, Button, type ButtonProps, CaretDownIcon, type CascaderOption, CheckCircleIcon, Checkbox, CodeIcon, Command, CommandDialog, CommandEmpty, CommandGroup, CommandInput, CommandItem, CommandList, CommandSeparator, CommandShortcut, ConfigIcon, ContextMenu, ContextMenuCheckboxItem, ContextMenuContent, ContextMenuGroup, ContextMenuItem, ContextMenuLabel, ContextMenuPortal, ContextMenuRadioGroup, ContextMenuRadioItem, ContextMenuSeparator, ContextMenuShortcut, ContextMenuSub, ContextMenuSubContent, ContextMenuSubTrigger, ContextMenuTrigger, type CustomToasterProps, Description, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, Display, DownIcon, DragIcon, 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, Form, FormControl, FormDescription, FormField, FormItem, FormLabel, FormMessage, Guide, Heading, type HeroIcon$1 as HeroIcon, type IAudioProps, type INumberInputProps, type ISelectProps, Icon, IconButton, type IconButtonProps, type IconComponent, type IconProps, Image, type ImageProps, Input, type InputProps, Label, Link, type LinkProps, Masonry, Menubar, MenubarCheckboxItem, MenubarContent, MenubarGroup, MenubarItem, MenubarLabel, MenubarMenu, MenubarPortal, MenubarRadioGroup, MenubarRadioItem, MenubarSeparator, MenubarShortcut, MenubarSub, MenubarSubContent, MenubarSubTrigger, MenubarTrigger, Message, Modal, ModalBody, ModalContent, ModalFooter, ModalHeader, ModalOverlay, ModalRoot, ModalTitle, NavigationBar, NumberInput, Paragraph, PencilSquareIcon, PhoneIcon, Popover, PopoverAnchor, PopoverContent, type PopoverContentExs, PopoverRoot, Progress, ProgressIndicator, type ProgressProps, ProgressRoot, type Props, RadioGroup, RadioGroupItem, RectangleGroupIcon, ScrollArea, ScrollBar, SearchBar, type SearchBarProps, type SearchInputProps, SecondaryNavigationBar, Select, SelectContent, SelectGroup, SelectIcon, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, Separator, Sheet, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetOverlay, SheetPortal, SheetTitle, SheetTrigger, Skeleton, Slider, SliderSingle, Spinner, SubHeading, SubTitle, Swiper, type SwiperProps, Switch, type TModalState, Tab, Tabs, TabsContent, TabsList, TabsTrigger, Text, Textarea, type TextareaProps, Title, Toast$1 as Toast, ToastAction, type ToastActionElement, ToastClose, ToastDescription, type ToastProps, ToastProvider, ToastTitle, type ToastType, ToastViewport, Toaster, type ToasterProps, Toggle, ToggleGroup, ToggleGroupItem, Tooltip, TooltipProvider, WindowIcon, buttonVariants, dangerouText, iconButtonVariants, reducer, toast, toggleVariants, useDevice, useFormField, useIsMobileByWindowWidth, useNativeBridge, useNotification, useToast, useWindowWidth };
1617
+ export { Accordion, AccordionContent, AccordionItem, type AccordionItemProps, AccordionTrigger, Alert, AlertDescription, AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger, AlertTitle, ArrowLeftIcon, ArrowUpTrayIcon, AspectRatio, AudioPlayer, AudioPlaying, Avatar, AvatarImage, AvatarRoot, Badge, Button, type ButtonComponentProps, type ButtonProps, CaretDownIcon, type CascaderOption, CheckCircleIcon, Checkbox, CodeIcon, Command, CommandDialog, CommandEmpty, CommandGroup, CommandInput, CommandItem, CommandList, CommandSeparator, CommandShortcut, ConfigIcon, ContextMenu, ContextMenuCheckboxItem, ContextMenuContent, ContextMenuGroup, ContextMenuItem, ContextMenuLabel, ContextMenuPortal, ContextMenuRadioGroup, ContextMenuRadioItem, ContextMenuSeparator, ContextMenuShortcut, ContextMenuSub, ContextMenuSubContent, ContextMenuSubTrigger, ContextMenuTrigger, type CustomToasterProps, Description, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, Display, DownIcon, DragIcon, 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, Form, FormControl, FormDescription, FormField, FormItem, FormLabel, FormMessage, Guide, Heading, type HeroIcon$1 as HeroIcon, type IAudioProps, type INumberInputProps, type ISelectProps, Icon, IconButton, type IconButtonComponentProps, type IconComponent, type IconProps, Image, type ImageProps, Input, type InputProps, Label, Link, type LinkProps, Masonry, Menubar, MenubarCheckboxItem, MenubarContent, MenubarGroup, MenubarItem, MenubarLabel, MenubarMenu, MenubarPortal, MenubarRadioGroup, MenubarRadioItem, MenubarSeparator, MenubarShortcut, MenubarSub, MenubarSubContent, MenubarSubTrigger, MenubarTrigger, Message, Modal, ModalBody, ModalContent, ModalFooter, ModalHeader, ModalOverlay, ModalRoot, ModalTitle, NavigationBar, NumberInput, Paragraph, PencilSquareIcon, PhoneIcon, Popover, PopoverAnchor, PopoverContent, type PopoverContentExs, PopoverRoot, Progress, ProgressIndicator, type ProgressProps, ProgressRoot, type Props, RadioGroup, RadioGroupItem, RectangleGroupIcon, ScrollArea, ScrollBar, SearchBar, type SearchBarProps, type SearchInputProps, SecondaryNavigationBar, Select, SelectContent, SelectGroup, SelectIcon, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, Separator, Sheet, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetOverlay, SheetPortal, SheetTitle, SheetTrigger, Skeleton, Slider, SliderSingle, Spinner, SubHeading, SubTitle, Swiper, type SwiperProps, Switch, type TModalState, Tab, Tabs, TabsContent, TabsList, TabsTrigger, Text, Textarea, type TextareaProps, Title, Toast$1 as Toast, ToastAction, type ToastActionElement, ToastClose, ToastDescription, type ToastProps, ToastProvider, ToastTitle, type ToastType, ToastViewport, Toaster, type ToasterProps, Toggle, ToggleGroup, ToggleGroupItem, Tooltip, TooltipProvider, WindowIcon, buttonVariants, dangerouText, iconButtonVariants, reducer, toast, toggleVariants, useDevice, useFormField, useIsMobileByWindowWidth, useNativeBridge, useNotification, useToast, useWindowWidth };
package/dist/index.d.ts CHANGED
@@ -141,13 +141,32 @@ declare const buttonVariants: (props?: ({
141
141
  color?: "default" | "brand" | "error" | null | undefined;
142
142
  size?: "sm" | "md" | "lg" | null | undefined;
143
143
  } & class_variance_authority_dist_types.ClassProp) | undefined) => string;
144
+ type VariantType$1 = 'primary' | 'secondary' | 'tertiary' | 'link' | 'plain' | 'opacity' | 'solid' | 'static';
145
+ type ButtonBaseProps = VariantProps<typeof buttonVariants>;
146
+ type VariantColorMap$1 = {
147
+ primary: 'default' | 'brand' | 'error';
148
+ secondary: 'default' | 'error';
149
+ tertiary: 'default';
150
+ link: 'default';
151
+ plain: 'default' | 'brand';
152
+ opacity: never;
153
+ solid: never;
154
+ static: never;
155
+ };
156
+ type ButtonProps$1<V extends VariantType$1 = VariantType$1> = Omit<ButtonBaseProps, 'color'> & {
157
+ variant?: V;
158
+ color?: V extends keyof VariantColorMap$1 ? VariantColorMap$1[V] : never;
159
+ };
144
160
 
145
- interface ButtonProps extends React$1.ButtonHTMLAttributes<HTMLButtonElement>, VariantProps<typeof buttonVariants> {
161
+ type ButtonProps = ButtonProps$1;
162
+ interface ButtonComponentProps<V extends VariantType$1 = VariantType$1> extends React$1.ButtonHTMLAttributes<HTMLButtonElement>, Omit<ButtonProps$1<V>, 'color'> {
146
163
  asChild?: boolean;
147
164
  loading?: boolean;
148
165
  icon?: React$1.ElementType;
149
166
  iconDirection?: 'left' | 'right';
150
- color?: 'default' | 'brand' | 'error';
167
+ variant?: V;
168
+ color?: V extends keyof VariantColorMap$1 ? VariantColorMap$1[V] : never;
169
+ size?: 'sm' | 'md' | 'lg';
151
170
  noStyle?: boolean;
152
171
  iconClassName?: string;
153
172
  iconOutBox?: boolean;
@@ -155,7 +174,11 @@ interface ButtonProps extends React$1.ButtonHTMLAttributes<HTMLButtonElement>, V
155
174
  asset?: 'energy' | 'coin';
156
175
  assetNumber?: number;
157
176
  }
158
- declare const Button: React$1.ForwardRefExoticComponent<ButtonProps & React$1.RefAttributes<HTMLButtonElement>>;
177
+ declare const Button: (<V extends VariantType$1>(props: ButtonComponentProps<V> & {
178
+ ref?: React$1.ForwardedRef<HTMLButtonElement>;
179
+ }) => JSX.Element) & {
180
+ displayName: string;
181
+ };
159
182
 
160
183
  interface CascaderOption {
161
184
  label: string;
@@ -381,29 +404,49 @@ declare const Icon: React$1.ForwardRefExoticComponent<React$1.HTMLAttributes<HTM
381
404
  } & React$1.RefAttributes<HTMLSpanElement>>;
382
405
  type IconComponent = React$1.ForwardRefExoticComponent<IconProps>;
383
406
 
407
+ type VariantType = 'primary' | 'secondary' | 'tertiary' | 'plain' | 'opacity' | 'solid' | 'static';
408
+ type ColorType = 'default' | 'brand' | 'error' | 'gray';
409
+ type SizeType = 'xs' | 'sm' | 'md' | 'lg';
384
410
  declare const iconButtonVariants: (props?: ({
385
- variant?: "opacity" | "static" | "primary" | "secondary" | "tertiary" | "plain" | "solid" | null | undefined;
386
- color?: "default" | "brand" | "error" | "gray" | null | undefined;
387
- size?: "xs" | "sm" | "md" | "lg" | null | undefined;
411
+ variant?: VariantType | null | undefined;
412
+ color?: ColorType | null | undefined;
413
+ size?: SizeType | null | undefined;
388
414
  } & class_variance_authority_dist_types.ClassProp) | undefined) => string;
389
415
  type IconButtonSize = 'xs' | 'sm' | 'md' | 'lg';
416
+ type IconButtonBaseProps = VariantProps<typeof iconButtonVariants>;
417
+ type VariantColorMap = {
418
+ primary: 'brand' | 'error';
419
+ secondary: 'default' | 'error';
420
+ tertiary: 'default';
421
+ plain: 'default' | 'error' | 'gray';
422
+ opacity: never;
423
+ solid: never;
424
+ static: never;
425
+ };
426
+ type IconButtonProps<V extends VariantType = VariantType> = Omit<IconButtonBaseProps, 'color'> & {
427
+ variant?: V;
428
+ color?: V extends keyof VariantColorMap ? VariantColorMap[V] : never;
429
+ };
390
430
 
391
431
  type HeroIcon$1 = React$1.ForwardRefExoticComponent<React$1.PropsWithoutRef<React$1.SVGProps<SVGSVGElement>> & {
392
432
  title?: string;
393
433
  titleId?: string;
394
434
  } & React$1.RefAttributes<SVGSVGElement>>;
395
- interface IconButtonProps extends React$1.ButtonHTMLAttributes<HTMLButtonElement>, VariantProps<typeof iconButtonVariants> {
435
+ interface IconButtonComponentProps<V extends VariantType = VariantType> extends Omit<React$1.ButtonHTMLAttributes<HTMLButtonElement>, 'color'>, IconButtonProps<V> {
396
436
  asChild?: boolean;
397
437
  loading?: boolean;
398
438
  disabled?: boolean;
399
- color?: 'default' | 'brand' | 'error' | 'gray';
400
439
  icon?: HeroIcon$1 | LucideIcon | IconComponent | React$1.ElementType;
401
440
  hoverText?: string;
402
441
  hoverSide?: 'top' | 'right' | 'bottom' | 'left';
403
442
  iconClassName?: ClassNameValue;
404
443
  size?: IconButtonSize;
444
+ variant?: V;
445
+ color?: V extends keyof VariantColorMap ? VariantColorMap[V] : never;
405
446
  }
406
- declare const IconButton: React$1.ForwardRefExoticComponent<IconButtonProps & React$1.RefAttributes<HTMLButtonElement>>;
447
+ declare const IconButton: <V extends VariantType>(props: IconButtonComponentProps<V> & {
448
+ ref?: React$1.ForwardedRef<HTMLButtonElement>;
449
+ }) => JSX.Element;
407
450
 
408
451
  interface ImageProps {
409
452
  /**
@@ -1571,4 +1614,4 @@ declare const RectangleGroupIcon: React$1.ForwardRefExoticComponent<React$1.HTML
1571
1614
  component?: React$1.ElementType;
1572
1615
  } & React$1.RefAttributes<SVGSVGElement>>;
1573
1616
 
1574
- export { Accordion, AccordionContent, AccordionItem, type AccordionItemProps, AccordionTrigger, Alert, AlertDescription, AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger, AlertTitle, ArrowLeftIcon, ArrowUpTrayIcon, AspectRatio, AudioPlayer, AudioPlaying, Avatar, AvatarImage, AvatarRoot, Badge, Button, type ButtonProps, CaretDownIcon, type CascaderOption, CheckCircleIcon, Checkbox, CodeIcon, Command, CommandDialog, CommandEmpty, CommandGroup, CommandInput, CommandItem, CommandList, CommandSeparator, CommandShortcut, ConfigIcon, ContextMenu, ContextMenuCheckboxItem, ContextMenuContent, ContextMenuGroup, ContextMenuItem, ContextMenuLabel, ContextMenuPortal, ContextMenuRadioGroup, ContextMenuRadioItem, ContextMenuSeparator, ContextMenuShortcut, ContextMenuSub, ContextMenuSubContent, ContextMenuSubTrigger, ContextMenuTrigger, type CustomToasterProps, Description, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, Display, DownIcon, DragIcon, 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, Form, FormControl, FormDescription, FormField, FormItem, FormLabel, FormMessage, Guide, Heading, type HeroIcon$1 as HeroIcon, type IAudioProps, type INumberInputProps, type ISelectProps, Icon, IconButton, type IconButtonProps, type IconComponent, type IconProps, Image, type ImageProps, Input, type InputProps, Label, Link, type LinkProps, Masonry, Menubar, MenubarCheckboxItem, MenubarContent, MenubarGroup, MenubarItem, MenubarLabel, MenubarMenu, MenubarPortal, MenubarRadioGroup, MenubarRadioItem, MenubarSeparator, MenubarShortcut, MenubarSub, MenubarSubContent, MenubarSubTrigger, MenubarTrigger, Message, Modal, ModalBody, ModalContent, ModalFooter, ModalHeader, ModalOverlay, ModalRoot, ModalTitle, NavigationBar, NumberInput, Paragraph, PencilSquareIcon, PhoneIcon, Popover, PopoverAnchor, PopoverContent, type PopoverContentExs, PopoverRoot, Progress, ProgressIndicator, type ProgressProps, ProgressRoot, type Props, RadioGroup, RadioGroupItem, RectangleGroupIcon, ScrollArea, ScrollBar, SearchBar, type SearchBarProps, type SearchInputProps, SecondaryNavigationBar, Select, SelectContent, SelectGroup, SelectIcon, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, Separator, Sheet, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetOverlay, SheetPortal, SheetTitle, SheetTrigger, Skeleton, Slider, SliderSingle, Spinner, SubHeading, SubTitle, Swiper, type SwiperProps, Switch, type TModalState, Tab, Tabs, TabsContent, TabsList, TabsTrigger, Text, Textarea, type TextareaProps, Title, Toast$1 as Toast, ToastAction, type ToastActionElement, ToastClose, ToastDescription, type ToastProps, ToastProvider, ToastTitle, type ToastType, ToastViewport, Toaster, type ToasterProps, Toggle, ToggleGroup, ToggleGroupItem, Tooltip, TooltipProvider, WindowIcon, buttonVariants, dangerouText, iconButtonVariants, reducer, toast, toggleVariants, useDevice, useFormField, useIsMobileByWindowWidth, useNativeBridge, useNotification, useToast, useWindowWidth };
1617
+ export { Accordion, AccordionContent, AccordionItem, type AccordionItemProps, AccordionTrigger, Alert, AlertDescription, AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger, AlertTitle, ArrowLeftIcon, ArrowUpTrayIcon, AspectRatio, AudioPlayer, AudioPlaying, Avatar, AvatarImage, AvatarRoot, Badge, Button, type ButtonComponentProps, type ButtonProps, CaretDownIcon, type CascaderOption, CheckCircleIcon, Checkbox, CodeIcon, Command, CommandDialog, CommandEmpty, CommandGroup, CommandInput, CommandItem, CommandList, CommandSeparator, CommandShortcut, ConfigIcon, ContextMenu, ContextMenuCheckboxItem, ContextMenuContent, ContextMenuGroup, ContextMenuItem, ContextMenuLabel, ContextMenuPortal, ContextMenuRadioGroup, ContextMenuRadioItem, ContextMenuSeparator, ContextMenuShortcut, ContextMenuSub, ContextMenuSubContent, ContextMenuSubTrigger, ContextMenuTrigger, type CustomToasterProps, Description, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, Display, DownIcon, DragIcon, 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, Form, FormControl, FormDescription, FormField, FormItem, FormLabel, FormMessage, Guide, Heading, type HeroIcon$1 as HeroIcon, type IAudioProps, type INumberInputProps, type ISelectProps, Icon, IconButton, type IconButtonComponentProps, type IconComponent, type IconProps, Image, type ImageProps, Input, type InputProps, Label, Link, type LinkProps, Masonry, Menubar, MenubarCheckboxItem, MenubarContent, MenubarGroup, MenubarItem, MenubarLabel, MenubarMenu, MenubarPortal, MenubarRadioGroup, MenubarRadioItem, MenubarSeparator, MenubarShortcut, MenubarSub, MenubarSubContent, MenubarSubTrigger, MenubarTrigger, Message, Modal, ModalBody, ModalContent, ModalFooter, ModalHeader, ModalOverlay, ModalRoot, ModalTitle, NavigationBar, NumberInput, Paragraph, PencilSquareIcon, PhoneIcon, Popover, PopoverAnchor, PopoverContent, type PopoverContentExs, PopoverRoot, Progress, ProgressIndicator, type ProgressProps, ProgressRoot, type Props, RadioGroup, RadioGroupItem, RectangleGroupIcon, ScrollArea, ScrollBar, SearchBar, type SearchBarProps, type SearchInputProps, SecondaryNavigationBar, Select, SelectContent, SelectGroup, SelectIcon, SelectItem, SelectLabel, SelectScrollDownButton, SelectScrollUpButton, SelectSeparator, SelectTrigger, SelectValue, Separator, Sheet, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetOverlay, SheetPortal, SheetTitle, SheetTrigger, Skeleton, Slider, SliderSingle, Spinner, SubHeading, SubTitle, Swiper, type SwiperProps, Switch, type TModalState, Tab, Tabs, TabsContent, TabsList, TabsTrigger, Text, Textarea, type TextareaProps, Title, Toast$1 as Toast, ToastAction, type ToastActionElement, ToastClose, ToastDescription, type ToastProps, ToastProvider, ToastTitle, type ToastType, ToastViewport, Toaster, type ToasterProps, Toggle, ToggleGroup, ToggleGroupItem, Tooltip, TooltipProvider, WindowIcon, buttonVariants, dangerouText, iconButtonVariants, reducer, toast, toggleVariants, useDevice, useFormField, useIsMobileByWindowWidth, useNativeBridge, useNotification, useToast, useWindowWidth };
package/dist/index.js CHANGED
@@ -5009,8 +5009,9 @@ var iconVariants2 = cva5("relative shrink-0 text-inherit inline-flex items-cente
5009
5009
  });
5010
5010
  // src/components/button/button.tsx
5011
5011
  import { Fragment, jsx as jsx8, jsxs as jsxs2 } from "react/jsx-runtime";
5012
- var Button = React6.forwardRef(function(_param, ref) {
5013
- var _param_className = _param.className, className = _param_className === void 0 ? "" : _param_className, iconClassName = _param.iconClassName, _param_variant = _param.variant, variant = _param_variant === void 0 ? "primary" : _param_variant, _param_color = _param.color, color = _param_color === void 0 ? "default" : _param_color, icon = _param.icon, _param_iconDirection = _param.iconDirection, iconDirection = _param_iconDirection === void 0 ? "left" : _param_iconDirection, size = _param.size, _param_asChild = _param.asChild, asChild = _param_asChild === void 0 ? false : _param_asChild, _param_loading = _param.loading, loading = _param_loading === void 0 ? false : _param_loading, _param_noStyle = _param.noStyle, noStyle = _param_noStyle === void 0 ? false : _param_noStyle, _param_iconOutBox = _param.iconOutBox, iconOutBox = _param_iconOutBox === void 0 ? false : _param_iconOutBox, _param_isBlock = _param.isBlock, isBlock = _param_isBlock === void 0 ? false : _param_isBlock, disabled = _param.disabled, children = _param.children, autoFocus = _param.autoFocus, asset = _param.asset, _param_assetNumber = _param.assetNumber, assetNumber = _param_assetNumber === void 0 ? 0 : _param_assetNumber, props = _object_without_properties(_param, [
5012
+ function createButtonWithVariant(props, ref) {
5013
+ var _props_className = props.className, className = _props_className === void 0 ? "" : _props_className, iconClassName = props.iconClassName, _props_variant = props.variant, variant = _props_variant === void 0 ? "primary" : _props_variant, // 设置默认值为primary
5014
+ userProvidedColor = props.color, icon = props.icon, _props_iconDirection = props.iconDirection, iconDirection = _props_iconDirection === void 0 ? "left" : _props_iconDirection, _props_size = props.size, size = _props_size === void 0 ? "lg" : _props_size, _props_asChild = props.asChild, asChild = _props_asChild === void 0 ? false : _props_asChild, _props_loading = props.loading, loading = _props_loading === void 0 ? false : _props_loading, _props_noStyle = props.noStyle, noStyle = _props_noStyle === void 0 ? false : _props_noStyle, _props_iconOutBox = props.iconOutBox, iconOutBox = _props_iconOutBox === void 0 ? false : _props_iconOutBox, _props_isBlock = props.isBlock, isBlock = _props_isBlock === void 0 ? false : _props_isBlock, disabled = props.disabled, children = props.children, autoFocus = props.autoFocus, asset = props.asset, _props_assetNumber = props.assetNumber, assetNumber = _props_assetNumber === void 0 ? 0 : _props_assetNumber, passProps = _object_without_properties(props, [
5014
5015
  "className",
5015
5016
  "iconClassName",
5016
5017
  "variant",
@@ -5029,6 +5030,7 @@ var Button = React6.forwardRef(function(_param, ref) {
5029
5030
  "asset",
5030
5031
  "assetNumber"
5031
5032
  ]);
5033
+ var color = userProvidedColor || "default";
5032
5034
  var Comp = asChild ? Slot : "button";
5033
5035
  var disable = disabled || loading;
5034
5036
  return /* @__PURE__ */ jsxs2(Comp, _object_spread_props(_object_spread({
@@ -5041,7 +5043,7 @@ var Button = React6.forwardRef(function(_param, ref) {
5041
5043
  ref: ref,
5042
5044
  disabled: disable,
5043
5045
  autoFocus: autoFocus
5044
- }, props), {
5046
+ }, passProps), {
5045
5047
  children: [
5046
5048
  loading && /* @__PURE__ */ jsx8("span", {
5047
5049
  className: "absolute left-1/2 top-1/2 flex -translate-x-1/2 -translate-y-1/2 items-center justify-center",
@@ -5112,9 +5114,12 @@ var Button = React6.forwardRef(function(_param, ref) {
5112
5114
  })
5113
5115
  ]
5114
5116
  }));
5117
+ }
5118
+ var Button = React6.forwardRef(function(props, ref) {
5119
+ return createButtonWithVariant(props, ref);
5115
5120
  });
5116
- var renderIcon = function(icon, direction, param) {
5117
- var loading = param.loading, noStyle = param.noStyle, iconClassName = param.iconClassName, _param_variant = param.variant, variant = _param_variant === void 0 ? "primary" : _param_variant, _param_color = param.color, color = _param_color === void 0 ? "brand" : _param_color, _param_size = param.size, size = _param_size === void 0 ? "lg" : _param_size;
5121
+ var renderIcon = function(icon, direction, props) {
5122
+ var loading = props.loading, noStyle = props.noStyle, iconClassName = props.iconClassName, variant = props.variant, size = props.size;
5118
5123
  return /* @__PURE__ */ jsx8(Icon, {
5119
5124
  component: icon,
5120
5125
  className: noStyle ? iconClassName : cn(iconVariants2({
@@ -5657,87 +5662,83 @@ var TooltipContent = React9.forwardRef(function(_param, ref) {
5657
5662
  TooltipContent.displayName = TooltipPrimitive.Content.displayName;
5658
5663
  // src/components/button/icon-button.styles.ts
5659
5664
  import { cva as cva6 } from "class-variance-authority";
5660
- var iconButtonVariants = cva6("shrink-0 inline-flex items-center justify-center whitespace-nowrap rounded-sm font-medium transition-colors focus-visible:outline-none focus-visible:shadow-none focus-visible:ring-2 focus-visible:ring-cc-Focus-Rings-Brand-default focus-visible:ring-offset-1 disabled:pointer-events-none disabled:opacity-30 disabled:shadow-none", {
5661
- variants: {
5662
- variant: {
5663
- primary: "",
5664
- secondary: "border shadow-none",
5665
- tertiary: "border shadow-none",
5666
- plain: "",
5667
- opacity: "backdrop-blur-2xl text-Colors-Text-Static-White bg-Colors-Beta-White-30 border border-Colors-Beta-White-12 shadow-none hover:bg-Colors-Beta-White-40 focus:shadow-cc-Focus-Rings-Brand-default active:bg-Colors-Beta-White-50 disabled:bg-Colors-Beta-White-60 disabled:text-Colors-Beta-White-80",
5668
- solid: "shadow-none text-Colors-Text-Subtle bg-cc-Button-Solid-bg-default border border-cc-Button-Solid-border-default hover:bg-cc-Button-Solid-bg-hover hover:border-cc-Button-Solid-border-alt active:bg-cc-Button-Solid-bg-active disabled:text-cc-Button-Solid-fg-alt",
5669
- static: "text-cc-Button-Static-fg-default border-cc-Button-Static-border-default bg-cc-Button-Static-bg-default hover:bg-cc-Button-Static-bg-hover active:bg-cc-Button-Static-bg-active disabled:bg-cc-Button-Static-bg-disabled disabled:text-cc-Button-Static-fg-alt"
5670
- },
5671
- color: {
5672
- default: "",
5673
- brand: "",
5674
- error: "",
5675
- gray: ""
5676
- },
5677
- size: {
5678
- xs: "h-5 w-5 text-xs",
5679
- sm: "h-7 w-7 text-sm",
5680
- md: "h-9 w-9 text-sm",
5681
- lg: "h-11 w-11"
5682
- }
5683
- },
5684
- compoundVariants: [
5685
- {
5686
- variant: "primary",
5687
- color: "default",
5688
- className: "bg-cc-Button-Primary-bg-default text-cc-Button-Primary-fg-default hover:bg-cc-Button-Primary-bg-hover active:bg-cc-Button-Primary-bg-active disabled:bg-cc-Button-Primary-bg-disabled"
5689
- },
5690
- {
5691
- variant: "primary",
5692
- color: "brand",
5693
- className: "text-cc-Icon-Button-Brand-fg-default bg-cc-Icon-Button-Brand-bg-default hover:bg-cc-Icon-Button-Brand-bg-hover active:bg-cc-Icon-Button-Brand-bg-active disabled:bg-cc-Icon-Button-Brand-bg-disabled disabled:text-cc-Icon-Button-Brand-fg-alt"
5694
- },
5695
- {
5696
- variant: "primary",
5697
- color: "error",
5698
- className: "text-cc-Button-Error-Primary-fg-default bg-cc-Button-Error-Primary-bg-default hover:bg-cc-Button-Error-Primary-bg-hover active:bg-cc-Button-Error-Primary-bg-active disabled:bg-cc-Button-Error-Primary-bg-disabled"
5699
- },
5700
- {
5701
- variant: "secondary",
5702
- color: "default",
5703
- className: "border-cc-Button-Secondary-border-default text-cc-Button-Secondary-fg-default bg-cc-Button-Secondary-bg-default hover:bg-cc-Button-Secondary-bg-hover active:bg-cc-Button-Secondary-bg-active disabled:text-cc-Button-Secondary-fg-alt disabled:border-cc-Button-Secondary-border-disabled"
5704
- },
5705
- {
5706
- variant: "tertiary",
5707
- color: "default",
5708
- className: "border-cc-Button-Tertiary-border-default text-cc-Button-Tertiary-fg-default bg-cc-Button-Tertiary-bg-default hover:bg-cc-Button-Tertiary-bg-hover hover:border-cc-Button-Tertiary-border-alt focus:shadow-button-tertiary-shadow active:bg-cc-Button-Tertiary-bg-active disabled:text-cc-Button-Tertiary-fg-alt"
5709
- },
5710
- {
5711
- variant: "secondary",
5712
- color: "error",
5713
- className: "border-cc-Button-Error-Secondary-border-default text-cc-Button-Error-Secondary-fg-default bg-cc-Button-Error-Secondary-bg-default hover:bg-cc-Button-Error-Secondary-bg-hover active:bg-cc-Button-Error-Secondary-bg-active disabled:text-cc-Button-Error-Secondary-fg-alt disabled:border-cc-Button-Error-Secondary-border-disabled"
5714
- },
5715
- {
5716
- variant: "secondary",
5717
- color: "gray",
5718
- className: "text-Colors-Foreground-Subtle hover:bg-Colors-Background-Normal-Primary-Hover"
5719
- },
5720
- {
5721
- variant: "plain",
5722
- color: "default",
5723
- className: "text-cc-Button-Plain-fg-default hover:bg-cc-Button-Plain-bg-hover focus:shadow-rings-brand active:bg-cc-Button-Plain-bg-active disabled:text-cc-Button-Plain-fg-alt"
5724
- },
5725
- {
5726
- variant: "plain",
5727
- color: "gray",
5728
- className: "text-cc-Icon-Button-Plain-Gray-fg-default bg-cc-Button-Plain-Brand-bg-default hover:bg-cc-Button-Plain-Brand-bg-hover active:bg-cc-Button-Plain-Brand-bg-active disabled:text-cc-Button-Plain-Gray-fg-alt"
5729
- },
5730
- {
5731
- variant: "plain",
5732
- color: "error",
5733
- className: "text-cc-Button-Error-Secondary-fg-default bg-cc-Button-Plain-bg-default hover:bg-cc-Button-Error-Secondary-bg-hover active:bg-cc-Button-Error-Secondary-bg-active disabled:text-cc-Button-Plain-fg-default"
5734
- }
5735
- ],
5736
- defaultVariants: {
5665
+ var BASE_STYLES = "shrink-0 inline-flex items-center justify-center whitespace-nowrap rounded-sm font-medium transition-colors focus-visible:outline-none focus-visible:shadow-none focus-visible:ring-2 focus-visible:ring-cc-Focus-Rings-Brand-default focus-visible:ring-offset-1 disabled:pointer-events-none disabled:opacity-30 disabled:shadow-none";
5666
+ var VARIANT_STYLES = {
5667
+ primary: "",
5668
+ secondary: "border shadow-none",
5669
+ tertiary: "border shadow-none",
5670
+ plain: "",
5671
+ opacity: "backdrop-blur-2xl text-Colors-Text-Static-White bg-Colors-Beta-White-30 border border-Colors-Beta-White-12 shadow-none hover:bg-Colors-Beta-White-40 focus:shadow-cc-Focus-Rings-Brand-default active:bg-Colors-Beta-White-50 disabled:bg-Colors-Beta-White-60 disabled:text-Colors-Beta-White-80",
5672
+ solid: "shadow-none text-Colors-Text-Subtle bg-cc-Button-Solid-bg-default border border-cc-Button-Solid-border-default hover:bg-cc-Button-Solid-bg-hover hover:border-cc-Button-Solid-border-alt active:bg-cc-Button-Solid-bg-active disabled:text-cc-Button-Solid-fg-alt",
5673
+ static: "text-cc-Button-Static-fg-default border-cc-Button-Static-border-default bg-cc-Button-Static-bg-default hover:bg-cc-Button-Static-bg-hover active:bg-cc-Button-Static-bg-active disabled:bg-cc-Button-Static-bg-disabled disabled:text-cc-Button-Static-fg-alt"
5674
+ };
5675
+ var COLOR_STYLES = {
5676
+ default: "",
5677
+ brand: "",
5678
+ error: "",
5679
+ gray: ""
5680
+ };
5681
+ var SIZE_STYLES = {
5682
+ xs: "h-5 w-5 text-xs",
5683
+ sm: "h-7 w-7 text-sm",
5684
+ md: "h-9 w-9 text-sm",
5685
+ lg: "h-11 w-11"
5686
+ };
5687
+ var COMPOUND_VARIANTS = [
5688
+ {
5737
5689
  variant: "primary",
5738
5690
  color: "brand",
5739
- size: "lg"
5691
+ className: "text-cc-Icon-Button-Brand-fg-default bg-cc-Icon-Button-Brand-bg-default hover:bg-cc-Icon-Button-Brand-bg-hover active:bg-cc-Icon-Button-Brand-bg-active disabled:bg-cc-Icon-Button-Brand-bg-disabled disabled:text-cc-Icon-Button-Brand-fg-alt"
5692
+ },
5693
+ {
5694
+ variant: "primary",
5695
+ color: "error",
5696
+ className: "text-cc-Button-Error-Primary-fg-default bg-cc-Button-Error-Primary-bg-default hover:bg-cc-Button-Error-Primary-bg-hover active:bg-cc-Button-Error-Primary-bg-active disabled:bg-cc-Button-Error-Primary-bg-disabled"
5697
+ },
5698
+ {
5699
+ variant: "secondary",
5700
+ color: "default",
5701
+ className: "border-cc-Button-Secondary-border-default text-cc-Button-Secondary-fg-default bg-cc-Button-Secondary-bg-default hover:bg-cc-Button-Secondary-bg-hover active:bg-cc-Button-Secondary-bg-active disabled:text-cc-Button-Secondary-fg-alt disabled:border-cc-Button-Secondary-border-disabled"
5702
+ },
5703
+ {
5704
+ variant: "secondary",
5705
+ color: "error",
5706
+ className: "border-cc-Button-Error-Secondary-border-default text-cc-Button-Error-Secondary-fg-default bg-cc-Button-Error-Secondary-bg-default hover:bg-cc-Button-Error-Secondary-bg-hover active:bg-cc-Button-Error-Secondary-bg-active disabled:text-cc-Button-Error-Secondary-fg-alt disabled:border-cc-Button-Error-Secondary-border-disabled"
5707
+ },
5708
+ {
5709
+ variant: "tertiary",
5710
+ color: "default",
5711
+ className: "border-cc-Button-Tertiary-border-default text-cc-Button-Tertiary-fg-default bg-cc-Button-Tertiary-bg-default hover:bg-cc-Button-Tertiary-bg-hover hover:border-cc-Button-Tertiary-border-alt focus:shadow-button-tertiary-shadow active:bg-cc-Button-Tertiary-bg-active disabled:text-cc-Button-Tertiary-fg-alt"
5712
+ },
5713
+ {
5714
+ variant: "plain",
5715
+ color: "default",
5716
+ className: "text-cc-Button-Plain-fg-default hover:bg-cc-Button-Plain-bg-hover focus:shadow-rings-brand active:bg-cc-Button-Plain-bg-active disabled:text-cc-Button-Plain-fg-alt"
5717
+ },
5718
+ {
5719
+ variant: "plain",
5720
+ color: "gray",
5721
+ className: "text-cc-Icon-Button-Plain-Gray-fg-default bg-cc-Button-Plain-Brand-bg-default hover:bg-cc-Button-Plain-Brand-bg-hover active:bg-cc-Button-Plain-Brand-bg-active disabled:text-cc-Button-Plain-Gray-fg-alt"
5722
+ },
5723
+ {
5724
+ variant: "plain",
5725
+ color: "error",
5726
+ className: "text-cc-Button-Error-Secondary-fg-default bg-cc-Button-Plain-bg-default hover:bg-cc-Button-Error-Secondary-bg-hover active:bg-cc-Button-Error-Secondary-bg-active disabled:text-cc-Button-Plain-fg-default"
5740
5727
  }
5728
+ ];
5729
+ var DEFAULT_VARIANTS = {
5730
+ variant: "primary",
5731
+ color: "default",
5732
+ size: "lg"
5733
+ };
5734
+ var iconButtonVariants = cva6(BASE_STYLES, {
5735
+ variants: {
5736
+ variant: VARIANT_STYLES,
5737
+ color: COLOR_STYLES,
5738
+ size: SIZE_STYLES
5739
+ },
5740
+ compoundVariants: COMPOUND_VARIANTS,
5741
+ defaultVariants: DEFAULT_VARIANTS
5741
5742
  });
5742
5743
  var iconSizeVariants = {
5743
5744
  xs: "w-3 h-3",
@@ -5747,8 +5748,16 @@ var iconSizeVariants = {
5747
5748
  };
5748
5749
  // src/components/button/icon-button.tsx
5749
5750
  import { jsx as jsx13 } from "react/jsx-runtime";
5750
- var IconButton = React10.forwardRef(function(_param, ref) {
5751
- var iconClassName = _param.iconClassName, className = _param.className, variant = _param.variant, _param_size = _param.size, size = _param_size === void 0 ? "lg" : _param_size, color = _param.color, _param_asChild = _param.asChild, asChild = _param_asChild === void 0 ? false : _param_asChild, _param_loading = _param.loading, loading = _param_loading === void 0 ? false : _param_loading, children = _param.children, IconEle = _param.icon, disabled = _param.disabled, hoverText = _param.hoverText, hoverSide = _param.hoverSide, passProps = _object_without_properties(_param, [
5751
+ function getDefaultColorForVariant(variant) {
5752
+ switch(variant){
5753
+ case "primary":
5754
+ return "brand";
5755
+ default:
5756
+ return "default";
5757
+ }
5758
+ }
5759
+ function createIconButtonWithVariant(props, ref) {
5760
+ var iconClassName = props.iconClassName, className = props.className, _props_variant = props.variant, variant = _props_variant === void 0 ? "primary" : _props_variant, _props_size = props.size, size = _props_size === void 0 ? "lg" : _props_size, userProvidedColor = props.color, _props_asChild = props.asChild, asChild = _props_asChild === void 0 ? false : _props_asChild, _props_loading = props.loading, loading = _props_loading === void 0 ? false : _props_loading, children = props.children, IconEle = props.icon, disabled = props.disabled, hoverText = props.hoverText, hoverSide = props.hoverSide, passProps = _object_without_properties(props, [
5752
5761
  "iconClassName",
5753
5762
  "className",
5754
5763
  "variant",
@@ -5762,6 +5771,7 @@ var IconButton = React10.forwardRef(function(_param, ref) {
5762
5771
  "hoverText",
5763
5772
  "hoverSide"
5764
5773
  ]);
5774
+ var color = userProvidedColor || getDefaultColorForVariant(variant);
5765
5775
  var isMobile2 = useMedia2("(max-width: 768px)");
5766
5776
  var Comp = asChild ? Slot2 : "button";
5767
5777
  var iconCls = cn(iconSizeVariants[size], iconClassName);
@@ -5790,6 +5800,9 @@ var IconButton = React10.forwardRef(function(_param, ref) {
5790
5800
  }) : null
5791
5801
  }))
5792
5802
  });
5803
+ }
5804
+ var IconButton = React10.forwardRef(function(props, ref) {
5805
+ return createIconButtonWithVariant(props, ref);
5793
5806
  });
5794
5807
  // src/components/audio-playing.tsx
5795
5808
  import Lottie from "lottie-web";
@@ -10963,7 +10976,7 @@ function SecondaryNavigationBar(param) {
10963
10976
  icons && icons.map(function(icon, index) {
10964
10977
  return /* @__PURE__ */ jsx46(IconButton, {
10965
10978
  variant: !hasBackground ? "tertiary" : "plain",
10966
- color: !hasBackground ? "default" : "brand",
10979
+ color: "default",
10967
10980
  size: "md",
10968
10981
  icon: icon.icon,
10969
10982
  onClick: icon.onClick
@@ -11016,7 +11029,6 @@ function SecondaryNavigationBar(param) {
11016
11029
  "aria-label": clearText || "Clear Filters",
11017
11030
  size: "md",
11018
11031
  variant: "primary",
11019
- color: "default",
11020
11032
  onClick: onClear,
11021
11033
  children: /* @__PURE__ */ jsx46("div", {
11022
11034
  className: "relative",