myshell-react-lib 0.1.35 → 0.1.36

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
@@ -423,7 +423,7 @@ type IconButtonProps<V extends VariantType = VariantType> = Omit<IconButtonBaseP
423
423
  color?: V extends keyof VariantColorMap ? VariantColorMap[V] : never;
424
424
  };
425
425
 
426
- type HeroIcon$1 = React$1.ForwardRefExoticComponent<React$1.PropsWithoutRef<React$1.SVGProps<SVGSVGElement>> & {
426
+ type HeroIcon = React$1.ForwardRefExoticComponent<React$1.PropsWithoutRef<React$1.SVGProps<SVGSVGElement>> & {
427
427
  title?: string;
428
428
  titleId?: string;
429
429
  } & React$1.RefAttributes<SVGSVGElement>>;
@@ -431,7 +431,7 @@ interface IconButtonComponentProps<V extends VariantType = VariantType> extends
431
431
  asChild?: boolean;
432
432
  loading?: boolean;
433
433
  disabled?: boolean;
434
- icon?: HeroIcon$1 | LucideIcon | IconComponent | React$1.ElementType;
434
+ icon?: HeroIcon | LucideIcon | IconComponent | React$1.ElementType;
435
435
  hoverText?: string;
436
436
  hoverSide?: 'top' | 'right' | 'bottom' | 'left';
437
437
  iconClassName?: ClassNameValue;
@@ -914,18 +914,6 @@ declare namespace SearchBar {
914
914
  var displayName: string;
915
915
  }
916
916
 
917
- /**
918
- * 通用类型定义
919
- */
920
- type HeroIcon = React.ForwardRefExoticComponent<React.PropsWithoutRef<React.SVGProps<SVGSVGElement>> & {
921
- title?: string;
922
- titleId?: string;
923
- } & React.RefAttributes<SVGSVGElement>>;
924
-
925
- type IIcons = {
926
- icon: HeroIcon | LucideIcon | React.ElementType;
927
- onClick?: () => void;
928
- };
929
917
  type ITopNavigationBar = {
930
918
  /**
931
919
  * 是否展示背景
@@ -946,22 +934,10 @@ type ITopNavigationBar = {
946
934
  */
947
935
  title?: string;
948
936
  /**
949
- * 是否展示搜索框
950
- * boolean
951
- *
952
- * @default false
953
- */
954
- showSearchBar?: boolean;
955
- /**
956
- * 搜索框值
957
- * string
958
- */
959
- searchValue?: string;
960
- /**
961
- * 搜索框占位值
962
- * string
937
+ * 搜索框自定义内容
938
+ * ReactNode
963
939
  */
964
- searchPlaceholder?: string;
940
+ searchElement?: React.ReactNode;
965
941
  /**
966
942
  * 是否显示底部border
967
943
  * boolean
@@ -984,11 +960,6 @@ type ITopNavigationBar = {
984
960
  * string
985
961
  */
986
962
  clearText?: string;
987
- /**
988
- * icon按钮配置
989
- * IIcons
990
- */
991
- icons?: IIcons[];
992
963
  /**
993
964
  * 头像配置
994
965
  * {
@@ -1012,18 +983,8 @@ type ITopNavigationBar = {
1012
983
  * () => void
1013
984
  */
1014
985
  onBack?: () => void;
1015
- /**
1016
- * 搜索框值变化回调
1017
- * (value: string) => void
1018
- */
1019
- onSearchChange?: (value: string) => void;
1020
- /**
1021
- * 清除按钮点击回调
1022
- * () => void
1023
- */
1024
- onClear?: () => void;
1025
986
  };
1026
- declare function TopNavigationBar({ showSearchBar, searchValue, searchPlaceholder, title, border, backUrl, children, hasBackground, avatar, onSearchChange, onBack, pageType, }: ITopNavigationBar): react_jsx_runtime.JSX.Element;
987
+ declare function TopNavigationBar({ searchElement, title, border, backUrl, children, hasBackground, avatar, onBack, pageType, }: ITopNavigationBar): react_jsx_runtime.JSX.Element;
1027
988
 
1028
989
  interface ISelectProps extends SelectPrimitive.SelectProps {
1029
990
  options?: Array<{
@@ -1634,4 +1595,4 @@ declare const RectangleGroupIcon: React$1.ForwardRefExoticComponent<React$1.HTML
1634
1595
  component?: React$1.ElementType;
1635
1596
  } & React$1.RefAttributes<SVGSVGElement>>;
1636
1597
 
1637
- export { Accordion, AccordionContent, AccordionItem, type AccordionItemProps, AccordionTrigger, AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger, ArrowLeftIcon, ArrowUpTrayIcon, AspectRatio, AudioPlayer, AudioPlaying, Avatar, AvatarImage, AvatarRoot, Badge, Button, type ButtonComponentProps, type ButtonProps, CaretDownIcon, type CascaderOption, CheckCircleIcon, Checkbox, Chips, 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, MiddleBar, Modal, ModalBody, ModalContent, ModalFooter, ModalHeader, ModalOverlay, ModalRoot, ModalTitle, 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, 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, TabsRoot, 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, TopNavigationBar, WindowIcon, buttonVariants, dangerouText, iconButtonVariants, reducer, toast, toggleVariants, useDevice, useFormField, useIsMobileByWindowWidth, useNativeBridge, useNotification, useToast, useWindowWidth };
1598
+ export { Accordion, AccordionContent, AccordionItem, type AccordionItemProps, AccordionTrigger, AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger, ArrowLeftIcon, ArrowUpTrayIcon, AspectRatio, AudioPlayer, AudioPlaying, Avatar, AvatarImage, AvatarRoot, Badge, Button, type ButtonComponentProps, type ButtonProps, CaretDownIcon, type CascaderOption, CheckCircleIcon, Checkbox, Chips, 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, 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, MiddleBar, Modal, ModalBody, ModalContent, ModalFooter, ModalHeader, ModalOverlay, ModalRoot, ModalTitle, 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, 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, TabsRoot, 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, TopNavigationBar, WindowIcon, buttonVariants, dangerouText, iconButtonVariants, reducer, toast, toggleVariants, useDevice, useFormField, useIsMobileByWindowWidth, useNativeBridge, useNotification, useToast, useWindowWidth };
package/dist/index.d.ts CHANGED
@@ -423,7 +423,7 @@ type IconButtonProps<V extends VariantType = VariantType> = Omit<IconButtonBaseP
423
423
  color?: V extends keyof VariantColorMap ? VariantColorMap[V] : never;
424
424
  };
425
425
 
426
- type HeroIcon$1 = React$1.ForwardRefExoticComponent<React$1.PropsWithoutRef<React$1.SVGProps<SVGSVGElement>> & {
426
+ type HeroIcon = React$1.ForwardRefExoticComponent<React$1.PropsWithoutRef<React$1.SVGProps<SVGSVGElement>> & {
427
427
  title?: string;
428
428
  titleId?: string;
429
429
  } & React$1.RefAttributes<SVGSVGElement>>;
@@ -431,7 +431,7 @@ interface IconButtonComponentProps<V extends VariantType = VariantType> extends
431
431
  asChild?: boolean;
432
432
  loading?: boolean;
433
433
  disabled?: boolean;
434
- icon?: HeroIcon$1 | LucideIcon | IconComponent | React$1.ElementType;
434
+ icon?: HeroIcon | LucideIcon | IconComponent | React$1.ElementType;
435
435
  hoverText?: string;
436
436
  hoverSide?: 'top' | 'right' | 'bottom' | 'left';
437
437
  iconClassName?: ClassNameValue;
@@ -914,18 +914,6 @@ declare namespace SearchBar {
914
914
  var displayName: string;
915
915
  }
916
916
 
917
- /**
918
- * 通用类型定义
919
- */
920
- type HeroIcon = React.ForwardRefExoticComponent<React.PropsWithoutRef<React.SVGProps<SVGSVGElement>> & {
921
- title?: string;
922
- titleId?: string;
923
- } & React.RefAttributes<SVGSVGElement>>;
924
-
925
- type IIcons = {
926
- icon: HeroIcon | LucideIcon | React.ElementType;
927
- onClick?: () => void;
928
- };
929
917
  type ITopNavigationBar = {
930
918
  /**
931
919
  * 是否展示背景
@@ -946,22 +934,10 @@ type ITopNavigationBar = {
946
934
  */
947
935
  title?: string;
948
936
  /**
949
- * 是否展示搜索框
950
- * boolean
951
- *
952
- * @default false
953
- */
954
- showSearchBar?: boolean;
955
- /**
956
- * 搜索框值
957
- * string
958
- */
959
- searchValue?: string;
960
- /**
961
- * 搜索框占位值
962
- * string
937
+ * 搜索框自定义内容
938
+ * ReactNode
963
939
  */
964
- searchPlaceholder?: string;
940
+ searchElement?: React.ReactNode;
965
941
  /**
966
942
  * 是否显示底部border
967
943
  * boolean
@@ -984,11 +960,6 @@ type ITopNavigationBar = {
984
960
  * string
985
961
  */
986
962
  clearText?: string;
987
- /**
988
- * icon按钮配置
989
- * IIcons
990
- */
991
- icons?: IIcons[];
992
963
  /**
993
964
  * 头像配置
994
965
  * {
@@ -1012,18 +983,8 @@ type ITopNavigationBar = {
1012
983
  * () => void
1013
984
  */
1014
985
  onBack?: () => void;
1015
- /**
1016
- * 搜索框值变化回调
1017
- * (value: string) => void
1018
- */
1019
- onSearchChange?: (value: string) => void;
1020
- /**
1021
- * 清除按钮点击回调
1022
- * () => void
1023
- */
1024
- onClear?: () => void;
1025
986
  };
1026
- declare function TopNavigationBar({ showSearchBar, searchValue, searchPlaceholder, title, border, backUrl, children, hasBackground, avatar, onSearchChange, onBack, pageType, }: ITopNavigationBar): react_jsx_runtime.JSX.Element;
987
+ declare function TopNavigationBar({ searchElement, title, border, backUrl, children, hasBackground, avatar, onBack, pageType, }: ITopNavigationBar): react_jsx_runtime.JSX.Element;
1027
988
 
1028
989
  interface ISelectProps extends SelectPrimitive.SelectProps {
1029
990
  options?: Array<{
@@ -1634,4 +1595,4 @@ declare const RectangleGroupIcon: React$1.ForwardRefExoticComponent<React$1.HTML
1634
1595
  component?: React$1.ElementType;
1635
1596
  } & React$1.RefAttributes<SVGSVGElement>>;
1636
1597
 
1637
- export { Accordion, AccordionContent, AccordionItem, type AccordionItemProps, AccordionTrigger, AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger, ArrowLeftIcon, ArrowUpTrayIcon, AspectRatio, AudioPlayer, AudioPlaying, Avatar, AvatarImage, AvatarRoot, Badge, Button, type ButtonComponentProps, type ButtonProps, CaretDownIcon, type CascaderOption, CheckCircleIcon, Checkbox, Chips, 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, MiddleBar, Modal, ModalBody, ModalContent, ModalFooter, ModalHeader, ModalOverlay, ModalRoot, ModalTitle, 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, 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, TabsRoot, 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, TopNavigationBar, WindowIcon, buttonVariants, dangerouText, iconButtonVariants, reducer, toast, toggleVariants, useDevice, useFormField, useIsMobileByWindowWidth, useNativeBridge, useNotification, useToast, useWindowWidth };
1598
+ export { Accordion, AccordionContent, AccordionItem, type AccordionItemProps, AccordionTrigger, AlertDialog, AlertDialogAction, AlertDialogCancel, AlertDialogContent, AlertDialogDescription, AlertDialogFooter, AlertDialogHeader, AlertDialogOverlay, AlertDialogPortal, AlertDialogTitle, AlertDialogTrigger, ArrowLeftIcon, ArrowUpTrayIcon, AspectRatio, AudioPlayer, AudioPlaying, Avatar, AvatarImage, AvatarRoot, Badge, Button, type ButtonComponentProps, type ButtonProps, CaretDownIcon, type CascaderOption, CheckCircleIcon, Checkbox, Chips, 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, 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, MiddleBar, Modal, ModalBody, ModalContent, ModalFooter, ModalHeader, ModalOverlay, ModalRoot, ModalTitle, 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, 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, TabsRoot, 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, TopNavigationBar, WindowIcon, buttonVariants, dangerouText, iconButtonVariants, reducer, toast, toggleVariants, useDevice, useFormField, useIsMobileByWindowWidth, useNativeBridge, useNotification, useToast, useWindowWidth };
package/dist/index.js CHANGED
@@ -10737,7 +10737,7 @@ import { useEffect as useEffect10, useRef as useRef6, useState as useState8 } fr
10737
10737
  import { useMedia as useMedia5 } from "react-use";
10738
10738
  import { jsx as jsx43, jsxs as jsxs24 } from "react/jsx-runtime";
10739
10739
  function TopNavigationBar(param) {
10740
- var _param_showSearchBar = param.showSearchBar, showSearchBar = _param_showSearchBar === void 0 ? true : _param_showSearchBar, searchValue = param.searchValue, searchPlaceholder = param.searchPlaceholder, title = param.title, border = param.border, backUrl = param.backUrl, children = param.children, _param_hasBackground = param.hasBackground, hasBackground = _param_hasBackground === void 0 ? true : _param_hasBackground, avatar = param.avatar, onSearchChange = param.onSearchChange, onBack = param.onBack, _param_pageType = param.pageType, pageType = _param_pageType === void 0 ? 2 : _param_pageType;
10740
+ var searchElement = param.searchElement, title = param.title, border = param.border, backUrl = param.backUrl, children = param.children, _param_hasBackground = param.hasBackground, hasBackground = _param_hasBackground === void 0 ? true : _param_hasBackground, avatar = param.avatar, onBack = param.onBack, _param_pageType = param.pageType, pageType = _param_pageType === void 0 ? 2 : _param_pageType;
10741
10741
  var isMobile2 = useMedia5("(max-width: 768px)");
10742
10742
  var navbarRef = useRef6(null);
10743
10743
  var _useState8 = _sliced_to_array(useState8(hasBackground), 2), showBackground = _useState8[0], setShowBackground = _useState8[1];
@@ -10794,7 +10794,7 @@ function TopNavigationBar(param) {
10794
10794
  })
10795
10795
  ]
10796
10796
  }),
10797
- title && (!showSearchBar || !isMobile2) && (!(avatar === null || avatar === void 0 ? void 0 : avatar.logo) || !isMobile2) && /* @__PURE__ */ jsx43(Display, {
10797
+ title && !(avatar === null || avatar === void 0 ? void 0 : avatar.logo) && /* @__PURE__ */ jsx43(Display, {
10798
10798
  size: isMobile2 ? "xs" : "sm",
10799
10799
  className: "line-clamp-1",
10800
10800
  children: title
@@ -10816,44 +10816,23 @@ function TopNavigationBar(param) {
10816
10816
  children: avatar.name
10817
10817
  })
10818
10818
  ]
10819
- }) : /* @__PURE__ */ jsx43("div", {
10820
- className: "w-[76px]"
10821
- })
10819
+ }) : null
10822
10820
  }),
10823
10821
  /* @__PURE__ */ jsx43("div", {
10824
10822
  className: "flex-1 flex justify-end items-center",
10825
10823
  children: /* @__PURE__ */ jsxs24("div", {
10826
10824
  className: "flex items-center space-x-3",
10827
10825
  children: [
10828
- showSearchBar && (!isMobile2 && pageType === 1 || pageType === 2) && /* @__PURE__ */ jsx43("div", {
10829
- className: "relative w-full md:w-60",
10830
- children: /* @__PURE__ */ jsx43(SearchBar, {
10831
- color: "gray",
10832
- size: "xs",
10833
- searchValue: searchValue,
10834
- placeholder: searchPlaceholder || "Search",
10835
- onSearchChange: function(value1) {
10836
- onSearchChange && onSearchChange(value1);
10837
- }
10838
- })
10839
- }),
10826
+ searchElement && (!isMobile2 && pageType === 1 || pageType === 2) && searchElement,
10840
10827
  children
10841
10828
  ]
10842
10829
  })
10843
10830
  })
10844
10831
  ]
10845
10832
  }),
10846
- showSearchBar && pageType === 1 && isMobile2 && /* @__PURE__ */ jsx43("div", {
10833
+ searchElement && pageType === 1 && isMobile2 && /* @__PURE__ */ jsx43("div", {
10847
10834
  className: "relative w-full h-13 py-2",
10848
- children: /* @__PURE__ */ jsx43(SearchBar, {
10849
- color: "gray",
10850
- size: "xs",
10851
- searchValue: searchValue,
10852
- placeholder: searchPlaceholder || "Search",
10853
- onSearchChange: function(value1) {
10854
- onSearchChange && onSearchChange(value1);
10855
- }
10856
- })
10835
+ children: searchElement
10857
10836
  })
10858
10837
  ]
10859
10838
  });