@chekinapp/ui 0.0.25 → 0.0.26
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.cjs +199 -166
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +11 -1
- package/dist/index.d.ts +11 -1
- package/dist/index.js +122 -90
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -2610,6 +2610,16 @@ interface UsePaginationReturn {
|
|
|
2610
2610
|
}
|
|
2611
2611
|
declare function usePagination(config: PaginationConfig): UsePaginationReturn;
|
|
2612
2612
|
|
|
2613
|
+
type UseCopyToClipboardProps = {
|
|
2614
|
+
value?: string | number;
|
|
2615
|
+
onCopiedLink?: () => void;
|
|
2616
|
+
onReset?: () => void;
|
|
2617
|
+
};
|
|
2618
|
+
declare function useCopyToClipboard({ value, onCopiedLink, onReset }: UseCopyToClipboardProps): {
|
|
2619
|
+
isCopied: boolean;
|
|
2620
|
+
copy: () => void;
|
|
2621
|
+
};
|
|
2622
|
+
|
|
2613
2623
|
type Props = {
|
|
2614
2624
|
seconds: number;
|
|
2615
2625
|
};
|
|
@@ -2639,4 +2649,4 @@ declare const usePromisedModalControls: () => {
|
|
|
2639
2649
|
|
|
2640
2650
|
declare function cn(...inputs: ClassValue[]): string;
|
|
2641
2651
|
|
|
2642
|
-
export { Accordion, AccordionContent, type AccordionContentProps, AccordionItem, AccordionTrigger, type AccordionTriggerProps, AirbnbInput, type AirbnbInputProps, AirbnbSearchInput, AirbnbSelect, type AirbnbSelectProps, AlertBox, type AlertBoxProps, AlertSize, AlertSizes, AlertType, AlertTypes, AudioPlayer, type AudioPlayerProps, Avatar, type AvatarProps, Badge, type BadgeProps, BaseCheckbox, type BaseCheckboxProps, BetaBadge, type BetaBadgeProps, BookmarkTabsList, type BookmarkTabsListProps, BookmarkTabsTrigger, type BookmarkTabsTriggerProps, BoxOptionSelector, type BoxOptionSelectorProps, type BoxOptionSelectorSwitchProps, Breadcrumb, type BreadcrumbProps, type BreadcrumbType, Breadcrumbs, type BreadcrumbsProps, Button, ButtonGroup, type ButtonGroupProps, ButtonGroupText, type ButtonGroupTextProps, type ButtonProps, type ButtonStatuses, ButtonsGroupLabel, type ButtonsGroupLabelProps, Calendar, type CalendarProps, Card, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, type ChannelOption, ChannelSelector, type ChannelSelectorProps, Checkbox, CheckboxGroup, type CheckboxGroupProps, type CheckboxOption, type CheckboxProps, CircularLoader, CommingSoonBadge, type CommingSoonBadgeProps, ConfirmationDialog, type ConfirmationDialogProps, CopyIcon, type CopyIconProps, CopyLinkButton, type CopyLinkButtonProps, type CustomIconEntry, DataTable, type DataTableProps, DatePicker, type DatePickerProps, type DatePickerValue, DefaultSelectTrigger, type DefaultSelectTriggerProps, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, DialogVisuallyHidden, DividingSubsection, DownloadEntryFormsButton, type DownloadEntryFormsButtonProps, Drawer, DrawerClose, DrawerContent, DrawerDescription, DrawerFooter, DrawerHeader, DrawerOverlay, DrawerPortal, DrawerTitle, DrawerTrigger, DropdownButton, type DropdownButtonProps, DropdownMenu, DropdownMenuContent, type DropdownMenuContentSide, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuSeparator, DropdownMenuTrigger, Empty, EmptyContent, EmptyDescription, EmptyHeader, EmptyMedia, EmptySectionPlaceholder, type EmptySectionPlaceholderProps, EmptyTitle, ErrorMessage, type ErrorMessageProps, ExternalLink, type ExternalLinkProps, FeatureCard, type FeatureCardProps, FieldErrorMessage, type FieldErrorMessageProps, FieldTrigger, type FieldTriggerProps, FileInputButton, type FileInputButtonProps, FormBox, Content as FormBoxContent, type FormBoxContentProps, Header as FormBoxHeader, type FormBoxHeaderProps, Root as FormBoxRoot, type FormBoxRootProps, SubHeader as FormBoxSubHeader, type FormBoxSubHeaderProps, FramedIcon, type FramedIconProps, FreeTextField, type FreeTextFieldProps, GridItems, type GridItemsProps, type GuestVerificationStatus, HALO_ICON_STATUS, HaloIcon, type HaloIconProps, HelpTooltip, type HelpTooltipProps, IVStatusBadge, type IVStatusBadgeProps, IV_BADGE_STATUS, Icon$1 as Icon, IconButton, type IconButtonProps, type IconEntry, type IconNames, type IconProps, IconRegistry, IconsDropdown, type IconsDropdownProps, Image, ImageFullScreenView, type ImageFullScreenViewProps, type ImageProps, InfoBox, type InfoBoxProps, Input, InputOTP, InputOTPGroup, type InputOTPProps, InputOTPSeparator, InputOTPSlot, type InputProps, LABEL_PLACEMENT, Label, type LabelProps, LargeModal, type LargeModalProps, LearnMoreButton, type LearnMoreButtonProps, Link, type LinkProps, Loader, type LoaderProps, LoadingBar, type LoadingBarProps, type LucideIconEntry, METRIC_CARD_VARIANTS, MetricCard, type MetricCardProps, Modal, ModalButton, ModalLoader, type ModalLoaderProps, type ModalProps, OverlayLoader, type OverlayLoaderProps, PageLoader, type PageLoaderProps, Pagination, type PaginationProps, type PaginationVariant, PhoneField, type PhoneFieldOption, type PhoneFieldProps, type PhoneFieldValue, Popover, PopoverAnchor, PopoverClose, PopoverContent, PopoverPortal, PopoverTrigger, Radio, RadioGroup, RadioGroupItem, type RadioOption, type RadioProps, RadioWithBorder, RatingProgress, type RatingProgressProps, RatingRadioGroup, type RatingRadioGroupProps, RatingStars, type RatingStarsProps, RegistryIcon, ResponsiveSheet, type ResponsiveSheetProps, RotateIcon, type RotateIconProps, ScrollArea, type ScrollAreaProps, ScrollBar, type ScrollBarProps, SearchButton, type SearchButtonProps, SearchInput, type SearchInputProps, SearchableSelect, type SearchableSelectProps, type SearchableSelectValue, Section, type SectionProps, SectionTag, SectionTagColors, type SectionTagProps, Select, SelectContent, type SelectForwardType, SelectGroup, SelectItem, SelectLabel, type SelectOption, SelectPortal, type SelectProps, SelectRoot, SelectSeparator, SelectTrigger, SelectValue$1 as SelectValue, SelectorButton, type SelectorButtonProps, type SelectorOption, Selectors, type SelectorsProps, Separator, type SeparatorProps, Sheet, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetTitle, SheetTrigger, Sidebar, SidebarContent, SidebarFooter, SidebarGroup, SidebarGroupAction, SidebarGroupContent, SidebarGroupLabel, SidebarHeader, SidebarIcon, SidebarInput, SidebarInset, SidebarMenu, SidebarMenuAction, SidebarMenuBadge, SidebarMenuButton, SidebarMenuItem, SidebarMenuSkeleton, SidebarMenuSub, SidebarMenuSubButton, SidebarMenuSubItem, SidebarProvider, SidebarRail, SidebarSeparator, SidebarTrigger, Skeleton, type SkeletonProps, SmallGridSingleItem, type SmallGridSingleItemProps, SortingAction, type SortingActionProps, type SortingActionValue, type SortingByVariant, StatusBadge, type StatusBadgeProps, type StatusBadgeVariant, StatusBox, type StatusBoxProps, StatusButton, type StatusButtonProps, Stepper, type StepperProps, SubSection, SubSectionSize, Switch, SwitchBlocks, type SwitchBlocksOption, type SwitchBlocksProps, SwitchGroup, type SwitchGroupProps, type SwitchOption, type SwitchProps, TASK_VARIANTS, TabbedSection, type TabbedSectionProps, Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeader, TablePlaceholder, type TablePlaceholderProps, TableRow, Tabs, TabsContent, TabsList, type TabsListProps, TabsTrigger, type TabsTriggerProps, TaskCard, type TaskCardProps, TextField, type TextFieldProps, Textarea, type TextareaProps, ThreeDotsLoader, type ThreeDotsLoaderProps, ToggleGroup, ToggleGroupItem, Toggles, type TogglesForwardType, type TogglesProps, Tooltip, TooltipContent, type TooltipContentProps, type TooltipProps, TooltipProvider, TooltipRoot, type TooltipRootProps, TooltipRootWrapper, TooltipTrigger, type UiKitLocale, UploadedFilesList, type UploadedFilesListProps, VideoPlayer, type VideoPlayerProps, WideButton, type WideButtonProps, badgeVariants, bookmarkTabsListVariants, bookmarkTabsTriggerVariants, buttonGroupVariants, buttonVariants, calendarClassNames, cn, copyToClipboard, emptyMediaVariants, getSidebarState, inputVariants, labelVariants, sectionTagVariants, switchThumbVariants, switchVariants, tabsListVariants, tabsTriggerVariants, toggleVariants, uiKitI18nResources, uiKitTranslations, useAbortController, useClickEscape, useCombinedRef, useDebounce, useDebouncedFunction, useEvent, useHover, useIsMobile, useIsMounted, useModalControls, useOutsideClick, usePagination, usePrevious, usePromisedModalControls, useRadioOptions, useScreenResize, useScrollFrameIntoView, useScrollToTop, useSidebar, useSidebarMenuButton, useSidebarSafe, useTimeout, useTimer, useUpdateToast };
|
|
2652
|
+
export { Accordion, AccordionContent, type AccordionContentProps, AccordionItem, AccordionTrigger, type AccordionTriggerProps, AirbnbInput, type AirbnbInputProps, AirbnbSearchInput, AirbnbSelect, type AirbnbSelectProps, AlertBox, type AlertBoxProps, AlertSize, AlertSizes, AlertType, AlertTypes, AudioPlayer, type AudioPlayerProps, Avatar, type AvatarProps, Badge, type BadgeProps, BaseCheckbox, type BaseCheckboxProps, BetaBadge, type BetaBadgeProps, BookmarkTabsList, type BookmarkTabsListProps, BookmarkTabsTrigger, type BookmarkTabsTriggerProps, BoxOptionSelector, type BoxOptionSelectorProps, type BoxOptionSelectorSwitchProps, Breadcrumb, type BreadcrumbProps, type BreadcrumbType, Breadcrumbs, type BreadcrumbsProps, Button, ButtonGroup, type ButtonGroupProps, ButtonGroupText, type ButtonGroupTextProps, type ButtonProps, type ButtonStatuses, ButtonsGroupLabel, type ButtonsGroupLabelProps, Calendar, type CalendarProps, Card, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, type ChannelOption, ChannelSelector, type ChannelSelectorProps, Checkbox, CheckboxGroup, type CheckboxGroupProps, type CheckboxOption, type CheckboxProps, CircularLoader, CommingSoonBadge, type CommingSoonBadgeProps, ConfirmationDialog, type ConfirmationDialogProps, CopyIcon, type CopyIconProps, CopyLinkButton, type CopyLinkButtonProps, type CustomIconEntry, DataTable, type DataTableProps, DatePicker, type DatePickerProps, type DatePickerValue, DefaultSelectTrigger, type DefaultSelectTriggerProps, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, DialogVisuallyHidden, DividingSubsection, DownloadEntryFormsButton, type DownloadEntryFormsButtonProps, Drawer, DrawerClose, DrawerContent, DrawerDescription, DrawerFooter, DrawerHeader, DrawerOverlay, DrawerPortal, DrawerTitle, DrawerTrigger, DropdownButton, type DropdownButtonProps, DropdownMenu, DropdownMenuContent, type DropdownMenuContentSide, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuSeparator, DropdownMenuTrigger, Empty, EmptyContent, EmptyDescription, EmptyHeader, EmptyMedia, EmptySectionPlaceholder, type EmptySectionPlaceholderProps, EmptyTitle, ErrorMessage, type ErrorMessageProps, ExternalLink, type ExternalLinkProps, FeatureCard, type FeatureCardProps, FieldErrorMessage, type FieldErrorMessageProps, FieldTrigger, type FieldTriggerProps, FileInputButton, type FileInputButtonProps, FormBox, Content as FormBoxContent, type FormBoxContentProps, Header as FormBoxHeader, type FormBoxHeaderProps, Root as FormBoxRoot, type FormBoxRootProps, SubHeader as FormBoxSubHeader, type FormBoxSubHeaderProps, FramedIcon, type FramedIconProps, FreeTextField, type FreeTextFieldProps, GridItems, type GridItemsProps, type GuestVerificationStatus, HALO_ICON_STATUS, HaloIcon, type HaloIconProps, HelpTooltip, type HelpTooltipProps, IVStatusBadge, type IVStatusBadgeProps, IV_BADGE_STATUS, Icon$1 as Icon, IconButton, type IconButtonProps, type IconEntry, type IconNames, type IconProps, IconRegistry, IconsDropdown, type IconsDropdownProps, Image, ImageFullScreenView, type ImageFullScreenViewProps, type ImageProps, InfoBox, type InfoBoxProps, Input, InputOTP, InputOTPGroup, type InputOTPProps, InputOTPSeparator, InputOTPSlot, type InputProps, LABEL_PLACEMENT, Label, type LabelProps, LargeModal, type LargeModalProps, LearnMoreButton, type LearnMoreButtonProps, Link, type LinkProps, Loader, type LoaderProps, LoadingBar, type LoadingBarProps, type LucideIconEntry, METRIC_CARD_VARIANTS, MetricCard, type MetricCardProps, Modal, ModalButton, ModalLoader, type ModalLoaderProps, type ModalProps, OverlayLoader, type OverlayLoaderProps, PageLoader, type PageLoaderProps, Pagination, type PaginationProps, type PaginationVariant, PhoneField, type PhoneFieldOption, type PhoneFieldProps, type PhoneFieldValue, Popover, PopoverAnchor, PopoverClose, PopoverContent, PopoverPortal, PopoverTrigger, Radio, RadioGroup, RadioGroupItem, type RadioOption, type RadioProps, RadioWithBorder, RatingProgress, type RatingProgressProps, RatingRadioGroup, type RatingRadioGroupProps, RatingStars, type RatingStarsProps, RegistryIcon, ResponsiveSheet, type ResponsiveSheetProps, RotateIcon, type RotateIconProps, ScrollArea, type ScrollAreaProps, ScrollBar, type ScrollBarProps, SearchButton, type SearchButtonProps, SearchInput, type SearchInputProps, SearchableSelect, type SearchableSelectProps, type SearchableSelectValue, Section, type SectionProps, SectionTag, SectionTagColors, type SectionTagProps, Select, SelectContent, type SelectForwardType, SelectGroup, SelectItem, SelectLabel, type SelectOption, SelectPortal, type SelectProps, SelectRoot, SelectSeparator, SelectTrigger, SelectValue$1 as SelectValue, SelectorButton, type SelectorButtonProps, type SelectorOption, Selectors, type SelectorsProps, Separator, type SeparatorProps, Sheet, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetTitle, SheetTrigger, Sidebar, SidebarContent, SidebarFooter, SidebarGroup, SidebarGroupAction, SidebarGroupContent, SidebarGroupLabel, SidebarHeader, SidebarIcon, SidebarInput, SidebarInset, SidebarMenu, SidebarMenuAction, SidebarMenuBadge, SidebarMenuButton, SidebarMenuItem, SidebarMenuSkeleton, SidebarMenuSub, SidebarMenuSubButton, SidebarMenuSubItem, SidebarProvider, SidebarRail, SidebarSeparator, SidebarTrigger, Skeleton, type SkeletonProps, SmallGridSingleItem, type SmallGridSingleItemProps, SortingAction, type SortingActionProps, type SortingActionValue, type SortingByVariant, StatusBadge, type StatusBadgeProps, type StatusBadgeVariant, StatusBox, type StatusBoxProps, StatusButton, type StatusButtonProps, Stepper, type StepperProps, SubSection, SubSectionSize, Switch, SwitchBlocks, type SwitchBlocksOption, type SwitchBlocksProps, SwitchGroup, type SwitchGroupProps, type SwitchOption, type SwitchProps, TASK_VARIANTS, TabbedSection, type TabbedSectionProps, Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeader, TablePlaceholder, type TablePlaceholderProps, TableRow, Tabs, TabsContent, TabsList, type TabsListProps, TabsTrigger, type TabsTriggerProps, TaskCard, type TaskCardProps, TextField, type TextFieldProps, Textarea, type TextareaProps, ThreeDotsLoader, type ThreeDotsLoaderProps, ToggleGroup, ToggleGroupItem, Toggles, type TogglesForwardType, type TogglesProps, Tooltip, TooltipContent, type TooltipContentProps, type TooltipProps, TooltipProvider, TooltipRoot, type TooltipRootProps, TooltipRootWrapper, TooltipTrigger, type UiKitLocale, UploadedFilesList, type UploadedFilesListProps, VideoPlayer, type VideoPlayerProps, WideButton, type WideButtonProps, badgeVariants, bookmarkTabsListVariants, bookmarkTabsTriggerVariants, buttonGroupVariants, buttonVariants, calendarClassNames, cn, copyToClipboard, emptyMediaVariants, getSidebarState, inputVariants, labelVariants, sectionTagVariants, switchThumbVariants, switchVariants, tabsListVariants, tabsTriggerVariants, toggleVariants, uiKitI18nResources, uiKitTranslations, useAbortController, useClickEscape, useCombinedRef, useCopyToClipboard, useDebounce, useDebouncedFunction, useEvent, useHover, useIsMobile, useIsMounted, useModalControls, useOutsideClick, usePagination, usePrevious, usePromisedModalControls, useRadioOptions, useScreenResize, useScrollFrameIntoView, useScrollToTop, useSidebar, useSidebarMenuButton, useSidebarSafe, useTimeout, useTimer, useUpdateToast };
|
package/dist/index.d.ts
CHANGED
|
@@ -2610,6 +2610,16 @@ interface UsePaginationReturn {
|
|
|
2610
2610
|
}
|
|
2611
2611
|
declare function usePagination(config: PaginationConfig): UsePaginationReturn;
|
|
2612
2612
|
|
|
2613
|
+
type UseCopyToClipboardProps = {
|
|
2614
|
+
value?: string | number;
|
|
2615
|
+
onCopiedLink?: () => void;
|
|
2616
|
+
onReset?: () => void;
|
|
2617
|
+
};
|
|
2618
|
+
declare function useCopyToClipboard({ value, onCopiedLink, onReset }: UseCopyToClipboardProps): {
|
|
2619
|
+
isCopied: boolean;
|
|
2620
|
+
copy: () => void;
|
|
2621
|
+
};
|
|
2622
|
+
|
|
2613
2623
|
type Props = {
|
|
2614
2624
|
seconds: number;
|
|
2615
2625
|
};
|
|
@@ -2639,4 +2649,4 @@ declare const usePromisedModalControls: () => {
|
|
|
2639
2649
|
|
|
2640
2650
|
declare function cn(...inputs: ClassValue[]): string;
|
|
2641
2651
|
|
|
2642
|
-
export { Accordion, AccordionContent, type AccordionContentProps, AccordionItem, AccordionTrigger, type AccordionTriggerProps, AirbnbInput, type AirbnbInputProps, AirbnbSearchInput, AirbnbSelect, type AirbnbSelectProps, AlertBox, type AlertBoxProps, AlertSize, AlertSizes, AlertType, AlertTypes, AudioPlayer, type AudioPlayerProps, Avatar, type AvatarProps, Badge, type BadgeProps, BaseCheckbox, type BaseCheckboxProps, BetaBadge, type BetaBadgeProps, BookmarkTabsList, type BookmarkTabsListProps, BookmarkTabsTrigger, type BookmarkTabsTriggerProps, BoxOptionSelector, type BoxOptionSelectorProps, type BoxOptionSelectorSwitchProps, Breadcrumb, type BreadcrumbProps, type BreadcrumbType, Breadcrumbs, type BreadcrumbsProps, Button, ButtonGroup, type ButtonGroupProps, ButtonGroupText, type ButtonGroupTextProps, type ButtonProps, type ButtonStatuses, ButtonsGroupLabel, type ButtonsGroupLabelProps, Calendar, type CalendarProps, Card, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, type ChannelOption, ChannelSelector, type ChannelSelectorProps, Checkbox, CheckboxGroup, type CheckboxGroupProps, type CheckboxOption, type CheckboxProps, CircularLoader, CommingSoonBadge, type CommingSoonBadgeProps, ConfirmationDialog, type ConfirmationDialogProps, CopyIcon, type CopyIconProps, CopyLinkButton, type CopyLinkButtonProps, type CustomIconEntry, DataTable, type DataTableProps, DatePicker, type DatePickerProps, type DatePickerValue, DefaultSelectTrigger, type DefaultSelectTriggerProps, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, DialogVisuallyHidden, DividingSubsection, DownloadEntryFormsButton, type DownloadEntryFormsButtonProps, Drawer, DrawerClose, DrawerContent, DrawerDescription, DrawerFooter, DrawerHeader, DrawerOverlay, DrawerPortal, DrawerTitle, DrawerTrigger, DropdownButton, type DropdownButtonProps, DropdownMenu, DropdownMenuContent, type DropdownMenuContentSide, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuSeparator, DropdownMenuTrigger, Empty, EmptyContent, EmptyDescription, EmptyHeader, EmptyMedia, EmptySectionPlaceholder, type EmptySectionPlaceholderProps, EmptyTitle, ErrorMessage, type ErrorMessageProps, ExternalLink, type ExternalLinkProps, FeatureCard, type FeatureCardProps, FieldErrorMessage, type FieldErrorMessageProps, FieldTrigger, type FieldTriggerProps, FileInputButton, type FileInputButtonProps, FormBox, Content as FormBoxContent, type FormBoxContentProps, Header as FormBoxHeader, type FormBoxHeaderProps, Root as FormBoxRoot, type FormBoxRootProps, SubHeader as FormBoxSubHeader, type FormBoxSubHeaderProps, FramedIcon, type FramedIconProps, FreeTextField, type FreeTextFieldProps, GridItems, type GridItemsProps, type GuestVerificationStatus, HALO_ICON_STATUS, HaloIcon, type HaloIconProps, HelpTooltip, type HelpTooltipProps, IVStatusBadge, type IVStatusBadgeProps, IV_BADGE_STATUS, Icon$1 as Icon, IconButton, type IconButtonProps, type IconEntry, type IconNames, type IconProps, IconRegistry, IconsDropdown, type IconsDropdownProps, Image, ImageFullScreenView, type ImageFullScreenViewProps, type ImageProps, InfoBox, type InfoBoxProps, Input, InputOTP, InputOTPGroup, type InputOTPProps, InputOTPSeparator, InputOTPSlot, type InputProps, LABEL_PLACEMENT, Label, type LabelProps, LargeModal, type LargeModalProps, LearnMoreButton, type LearnMoreButtonProps, Link, type LinkProps, Loader, type LoaderProps, LoadingBar, type LoadingBarProps, type LucideIconEntry, METRIC_CARD_VARIANTS, MetricCard, type MetricCardProps, Modal, ModalButton, ModalLoader, type ModalLoaderProps, type ModalProps, OverlayLoader, type OverlayLoaderProps, PageLoader, type PageLoaderProps, Pagination, type PaginationProps, type PaginationVariant, PhoneField, type PhoneFieldOption, type PhoneFieldProps, type PhoneFieldValue, Popover, PopoverAnchor, PopoverClose, PopoverContent, PopoverPortal, PopoverTrigger, Radio, RadioGroup, RadioGroupItem, type RadioOption, type RadioProps, RadioWithBorder, RatingProgress, type RatingProgressProps, RatingRadioGroup, type RatingRadioGroupProps, RatingStars, type RatingStarsProps, RegistryIcon, ResponsiveSheet, type ResponsiveSheetProps, RotateIcon, type RotateIconProps, ScrollArea, type ScrollAreaProps, ScrollBar, type ScrollBarProps, SearchButton, type SearchButtonProps, SearchInput, type SearchInputProps, SearchableSelect, type SearchableSelectProps, type SearchableSelectValue, Section, type SectionProps, SectionTag, SectionTagColors, type SectionTagProps, Select, SelectContent, type SelectForwardType, SelectGroup, SelectItem, SelectLabel, type SelectOption, SelectPortal, type SelectProps, SelectRoot, SelectSeparator, SelectTrigger, SelectValue$1 as SelectValue, SelectorButton, type SelectorButtonProps, type SelectorOption, Selectors, type SelectorsProps, Separator, type SeparatorProps, Sheet, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetTitle, SheetTrigger, Sidebar, SidebarContent, SidebarFooter, SidebarGroup, SidebarGroupAction, SidebarGroupContent, SidebarGroupLabel, SidebarHeader, SidebarIcon, SidebarInput, SidebarInset, SidebarMenu, SidebarMenuAction, SidebarMenuBadge, SidebarMenuButton, SidebarMenuItem, SidebarMenuSkeleton, SidebarMenuSub, SidebarMenuSubButton, SidebarMenuSubItem, SidebarProvider, SidebarRail, SidebarSeparator, SidebarTrigger, Skeleton, type SkeletonProps, SmallGridSingleItem, type SmallGridSingleItemProps, SortingAction, type SortingActionProps, type SortingActionValue, type SortingByVariant, StatusBadge, type StatusBadgeProps, type StatusBadgeVariant, StatusBox, type StatusBoxProps, StatusButton, type StatusButtonProps, Stepper, type StepperProps, SubSection, SubSectionSize, Switch, SwitchBlocks, type SwitchBlocksOption, type SwitchBlocksProps, SwitchGroup, type SwitchGroupProps, type SwitchOption, type SwitchProps, TASK_VARIANTS, TabbedSection, type TabbedSectionProps, Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeader, TablePlaceholder, type TablePlaceholderProps, TableRow, Tabs, TabsContent, TabsList, type TabsListProps, TabsTrigger, type TabsTriggerProps, TaskCard, type TaskCardProps, TextField, type TextFieldProps, Textarea, type TextareaProps, ThreeDotsLoader, type ThreeDotsLoaderProps, ToggleGroup, ToggleGroupItem, Toggles, type TogglesForwardType, type TogglesProps, Tooltip, TooltipContent, type TooltipContentProps, type TooltipProps, TooltipProvider, TooltipRoot, type TooltipRootProps, TooltipRootWrapper, TooltipTrigger, type UiKitLocale, UploadedFilesList, type UploadedFilesListProps, VideoPlayer, type VideoPlayerProps, WideButton, type WideButtonProps, badgeVariants, bookmarkTabsListVariants, bookmarkTabsTriggerVariants, buttonGroupVariants, buttonVariants, calendarClassNames, cn, copyToClipboard, emptyMediaVariants, getSidebarState, inputVariants, labelVariants, sectionTagVariants, switchThumbVariants, switchVariants, tabsListVariants, tabsTriggerVariants, toggleVariants, uiKitI18nResources, uiKitTranslations, useAbortController, useClickEscape, useCombinedRef, useDebounce, useDebouncedFunction, useEvent, useHover, useIsMobile, useIsMounted, useModalControls, useOutsideClick, usePagination, usePrevious, usePromisedModalControls, useRadioOptions, useScreenResize, useScrollFrameIntoView, useScrollToTop, useSidebar, useSidebarMenuButton, useSidebarSafe, useTimeout, useTimer, useUpdateToast };
|
|
2652
|
+
export { Accordion, AccordionContent, type AccordionContentProps, AccordionItem, AccordionTrigger, type AccordionTriggerProps, AirbnbInput, type AirbnbInputProps, AirbnbSearchInput, AirbnbSelect, type AirbnbSelectProps, AlertBox, type AlertBoxProps, AlertSize, AlertSizes, AlertType, AlertTypes, AudioPlayer, type AudioPlayerProps, Avatar, type AvatarProps, Badge, type BadgeProps, BaseCheckbox, type BaseCheckboxProps, BetaBadge, type BetaBadgeProps, BookmarkTabsList, type BookmarkTabsListProps, BookmarkTabsTrigger, type BookmarkTabsTriggerProps, BoxOptionSelector, type BoxOptionSelectorProps, type BoxOptionSelectorSwitchProps, Breadcrumb, type BreadcrumbProps, type BreadcrumbType, Breadcrumbs, type BreadcrumbsProps, Button, ButtonGroup, type ButtonGroupProps, ButtonGroupText, type ButtonGroupTextProps, type ButtonProps, type ButtonStatuses, ButtonsGroupLabel, type ButtonsGroupLabelProps, Calendar, type CalendarProps, Card, CardContent, CardDescription, CardFooter, CardHeader, CardTitle, type ChannelOption, ChannelSelector, type ChannelSelectorProps, Checkbox, CheckboxGroup, type CheckboxGroupProps, type CheckboxOption, type CheckboxProps, CircularLoader, CommingSoonBadge, type CommingSoonBadgeProps, ConfirmationDialog, type ConfirmationDialogProps, CopyIcon, type CopyIconProps, CopyLinkButton, type CopyLinkButtonProps, type CustomIconEntry, DataTable, type DataTableProps, DatePicker, type DatePickerProps, type DatePickerValue, DefaultSelectTrigger, type DefaultSelectTriggerProps, Dialog, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogOverlay, DialogPortal, DialogTitle, DialogTrigger, DialogVisuallyHidden, DividingSubsection, DownloadEntryFormsButton, type DownloadEntryFormsButtonProps, Drawer, DrawerClose, DrawerContent, DrawerDescription, DrawerFooter, DrawerHeader, DrawerOverlay, DrawerPortal, DrawerTitle, DrawerTrigger, DropdownButton, type DropdownButtonProps, DropdownMenu, DropdownMenuContent, type DropdownMenuContentSide, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuPortal, DropdownMenuSeparator, DropdownMenuTrigger, Empty, EmptyContent, EmptyDescription, EmptyHeader, EmptyMedia, EmptySectionPlaceholder, type EmptySectionPlaceholderProps, EmptyTitle, ErrorMessage, type ErrorMessageProps, ExternalLink, type ExternalLinkProps, FeatureCard, type FeatureCardProps, FieldErrorMessage, type FieldErrorMessageProps, FieldTrigger, type FieldTriggerProps, FileInputButton, type FileInputButtonProps, FormBox, Content as FormBoxContent, type FormBoxContentProps, Header as FormBoxHeader, type FormBoxHeaderProps, Root as FormBoxRoot, type FormBoxRootProps, SubHeader as FormBoxSubHeader, type FormBoxSubHeaderProps, FramedIcon, type FramedIconProps, FreeTextField, type FreeTextFieldProps, GridItems, type GridItemsProps, type GuestVerificationStatus, HALO_ICON_STATUS, HaloIcon, type HaloIconProps, HelpTooltip, type HelpTooltipProps, IVStatusBadge, type IVStatusBadgeProps, IV_BADGE_STATUS, Icon$1 as Icon, IconButton, type IconButtonProps, type IconEntry, type IconNames, type IconProps, IconRegistry, IconsDropdown, type IconsDropdownProps, Image, ImageFullScreenView, type ImageFullScreenViewProps, type ImageProps, InfoBox, type InfoBoxProps, Input, InputOTP, InputOTPGroup, type InputOTPProps, InputOTPSeparator, InputOTPSlot, type InputProps, LABEL_PLACEMENT, Label, type LabelProps, LargeModal, type LargeModalProps, LearnMoreButton, type LearnMoreButtonProps, Link, type LinkProps, Loader, type LoaderProps, LoadingBar, type LoadingBarProps, type LucideIconEntry, METRIC_CARD_VARIANTS, MetricCard, type MetricCardProps, Modal, ModalButton, ModalLoader, type ModalLoaderProps, type ModalProps, OverlayLoader, type OverlayLoaderProps, PageLoader, type PageLoaderProps, Pagination, type PaginationProps, type PaginationVariant, PhoneField, type PhoneFieldOption, type PhoneFieldProps, type PhoneFieldValue, Popover, PopoverAnchor, PopoverClose, PopoverContent, PopoverPortal, PopoverTrigger, Radio, RadioGroup, RadioGroupItem, type RadioOption, type RadioProps, RadioWithBorder, RatingProgress, type RatingProgressProps, RatingRadioGroup, type RatingRadioGroupProps, RatingStars, type RatingStarsProps, RegistryIcon, ResponsiveSheet, type ResponsiveSheetProps, RotateIcon, type RotateIconProps, ScrollArea, type ScrollAreaProps, ScrollBar, type ScrollBarProps, SearchButton, type SearchButtonProps, SearchInput, type SearchInputProps, SearchableSelect, type SearchableSelectProps, type SearchableSelectValue, Section, type SectionProps, SectionTag, SectionTagColors, type SectionTagProps, Select, SelectContent, type SelectForwardType, SelectGroup, SelectItem, SelectLabel, type SelectOption, SelectPortal, type SelectProps, SelectRoot, SelectSeparator, SelectTrigger, SelectValue$1 as SelectValue, SelectorButton, type SelectorButtonProps, type SelectorOption, Selectors, type SelectorsProps, Separator, type SeparatorProps, Sheet, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetTitle, SheetTrigger, Sidebar, SidebarContent, SidebarFooter, SidebarGroup, SidebarGroupAction, SidebarGroupContent, SidebarGroupLabel, SidebarHeader, SidebarIcon, SidebarInput, SidebarInset, SidebarMenu, SidebarMenuAction, SidebarMenuBadge, SidebarMenuButton, SidebarMenuItem, SidebarMenuSkeleton, SidebarMenuSub, SidebarMenuSubButton, SidebarMenuSubItem, SidebarProvider, SidebarRail, SidebarSeparator, SidebarTrigger, Skeleton, type SkeletonProps, SmallGridSingleItem, type SmallGridSingleItemProps, SortingAction, type SortingActionProps, type SortingActionValue, type SortingByVariant, StatusBadge, type StatusBadgeProps, type StatusBadgeVariant, StatusBox, type StatusBoxProps, StatusButton, type StatusButtonProps, Stepper, type StepperProps, SubSection, SubSectionSize, Switch, SwitchBlocks, type SwitchBlocksOption, type SwitchBlocksProps, SwitchGroup, type SwitchGroupProps, type SwitchOption, type SwitchProps, TASK_VARIANTS, TabbedSection, type TabbedSectionProps, Table, TableBody, TableCaption, TableCell, TableFooter, TableHead, TableHeader, TablePlaceholder, type TablePlaceholderProps, TableRow, Tabs, TabsContent, TabsList, type TabsListProps, TabsTrigger, type TabsTriggerProps, TaskCard, type TaskCardProps, TextField, type TextFieldProps, Textarea, type TextareaProps, ThreeDotsLoader, type ThreeDotsLoaderProps, ToggleGroup, ToggleGroupItem, Toggles, type TogglesForwardType, type TogglesProps, Tooltip, TooltipContent, type TooltipContentProps, type TooltipProps, TooltipProvider, TooltipRoot, type TooltipRootProps, TooltipRootWrapper, TooltipTrigger, type UiKitLocale, UploadedFilesList, type UploadedFilesListProps, VideoPlayer, type VideoPlayerProps, WideButton, type WideButtonProps, badgeVariants, bookmarkTabsListVariants, bookmarkTabsTriggerVariants, buttonGroupVariants, buttonVariants, calendarClassNames, cn, copyToClipboard, emptyMediaVariants, getSidebarState, inputVariants, labelVariants, sectionTagVariants, switchThumbVariants, switchVariants, tabsListVariants, tabsTriggerVariants, toggleVariants, uiKitI18nResources, uiKitTranslations, useAbortController, useClickEscape, useCombinedRef, useCopyToClipboard, useDebounce, useDebouncedFunction, useEvent, useHover, useIsMobile, useIsMounted, useModalControls, useOutsideClick, usePagination, usePrevious, usePromisedModalControls, useRadioOptions, useScreenResize, useScrollFrameIntoView, useScrollToTop, useSidebar, useSidebarMenuButton, useSidebarSafe, useTimeout, useTimer, useUpdateToast };
|
package/dist/index.js
CHANGED
|
@@ -2518,12 +2518,76 @@ function usePagination(config) {
|
|
|
2518
2518
|
};
|
|
2519
2519
|
}
|
|
2520
2520
|
|
|
2521
|
+
// src/hooks/use-copy-to-clipboard.ts
|
|
2522
|
+
import { useEffect as useEffect13, useRef as useRef8, useState as useState10 } from "react";
|
|
2523
|
+
|
|
2524
|
+
// src/lib/copy-to-clipboard.ts
|
|
2525
|
+
function copyToClipboardFallback(value) {
|
|
2526
|
+
const targetDocument = getDocument();
|
|
2527
|
+
const targetBody = targetDocument.body;
|
|
2528
|
+
if (!targetBody) {
|
|
2529
|
+
return;
|
|
2530
|
+
}
|
|
2531
|
+
const el = targetDocument.createElement("textarea");
|
|
2532
|
+
el.value = value;
|
|
2533
|
+
el.setAttribute("readonly", "");
|
|
2534
|
+
el.style.position = "fixed";
|
|
2535
|
+
el.style.opacity = "0";
|
|
2536
|
+
el.style.pointerEvents = "none";
|
|
2537
|
+
el.style.left = "-9999px";
|
|
2538
|
+
targetBody.appendChild(el);
|
|
2539
|
+
el.focus();
|
|
2540
|
+
el.select();
|
|
2541
|
+
targetDocument.execCommand("copy");
|
|
2542
|
+
targetBody.removeChild(el);
|
|
2543
|
+
}
|
|
2544
|
+
function copyToClipboard2(value) {
|
|
2545
|
+
const text = typeof value === "number" ? value.toString() : value;
|
|
2546
|
+
const targetDocument = getDocument();
|
|
2547
|
+
const clipboard = targetDocument.defaultView?.navigator?.clipboard ?? globalThis.navigator?.clipboard;
|
|
2548
|
+
if (!clipboard?.writeText) {
|
|
2549
|
+
copyToClipboardFallback(text);
|
|
2550
|
+
return;
|
|
2551
|
+
}
|
|
2552
|
+
void clipboard.writeText(text).catch(() => {
|
|
2553
|
+
copyToClipboardFallback(text);
|
|
2554
|
+
});
|
|
2555
|
+
}
|
|
2556
|
+
|
|
2557
|
+
// src/hooks/use-copy-to-clipboard.ts
|
|
2558
|
+
var COPIED_TIMEOUT_S = 1.5;
|
|
2559
|
+
function useCopyToClipboard({ value, onCopiedLink, onReset }) {
|
|
2560
|
+
const [isCopied, setIsLinkCopied] = useState10(false);
|
|
2561
|
+
const timeoutRef = useRef8();
|
|
2562
|
+
useEffect13(() => {
|
|
2563
|
+
return () => {
|
|
2564
|
+
if (timeoutRef.current) {
|
|
2565
|
+
clearTimeout(timeoutRef.current);
|
|
2566
|
+
}
|
|
2567
|
+
};
|
|
2568
|
+
}, []);
|
|
2569
|
+
const copy = () => {
|
|
2570
|
+
if (!value) return;
|
|
2571
|
+
if (timeoutRef.current) {
|
|
2572
|
+
clearTimeout(timeoutRef.current);
|
|
2573
|
+
}
|
|
2574
|
+
copyToClipboard2(value);
|
|
2575
|
+
setIsLinkCopied(true);
|
|
2576
|
+
timeoutRef.current = setTimeout(() => {
|
|
2577
|
+
setIsLinkCopied(false);
|
|
2578
|
+
onReset?.();
|
|
2579
|
+
}, COPIED_TIMEOUT_S * 1e3);
|
|
2580
|
+
onCopiedLink?.();
|
|
2581
|
+
};
|
|
2582
|
+
return { isCopied, copy };
|
|
2583
|
+
}
|
|
2584
|
+
|
|
2521
2585
|
// src/hooks/use-timer.ts
|
|
2522
|
-
import { useEffect as
|
|
2586
|
+
import { useEffect as useEffect14, useState as useState11 } from "react";
|
|
2523
2587
|
var useTimer = ({ seconds }) => {
|
|
2524
|
-
const [timeLeft, setTimeLeft] =
|
|
2525
|
-
const [isTimerRunning, setIsTimerRunning] =
|
|
2526
|
-
|
|
2588
|
+
const [timeLeft, setTimeLeft] = useState11(seconds);
|
|
2589
|
+
const [isTimerRunning, setIsTimerRunning] = useState11(true);
|
|
2590
|
+
useEffect14(() => {
|
|
2527
2591
|
if (!isTimerRunning) return;
|
|
2528
2592
|
const timer = setInterval(() => {
|
|
2529
2593
|
setTimeLeft((prev) => {
|
|
@@ -2549,9 +2613,9 @@ var useTimer = ({ seconds }) => {
|
|
|
2549
2613
|
};
|
|
2550
2614
|
|
|
2551
2615
|
// src/hooks/use-timeout.ts
|
|
2552
|
-
import { useCallback as useCallback9, useEffect as
|
|
2616
|
+
import { useCallback as useCallback9, useEffect as useEffect15, useRef as useRef9 } from "react";
|
|
2553
2617
|
function useTimeout() {
|
|
2554
|
-
const timeoutRef =
|
|
2618
|
+
const timeoutRef = useRef9();
|
|
2555
2619
|
const clearTimeoutRef = useCallback9(() => {
|
|
2556
2620
|
clearTimeout(timeoutRef.current);
|
|
2557
2621
|
timeoutRef.current = void 0;
|
|
@@ -2563,14 +2627,14 @@ function useTimeout() {
|
|
|
2563
2627
|
},
|
|
2564
2628
|
[clearTimeoutRef]
|
|
2565
2629
|
);
|
|
2566
|
-
|
|
2630
|
+
useEffect15(() => clearTimeoutRef, [clearTimeoutRef]);
|
|
2567
2631
|
return { scheduleTimeout, clearTimeoutRef };
|
|
2568
2632
|
}
|
|
2569
2633
|
|
|
2570
2634
|
// src/hooks/use-hover.ts
|
|
2571
|
-
import { useCallback as useCallback10, useState as
|
|
2635
|
+
import { useCallback as useCallback10, useState as useState12 } from "react";
|
|
2572
2636
|
function useHover() {
|
|
2573
|
-
const [isHovering, setIsHovering] =
|
|
2637
|
+
const [isHovering, setIsHovering] = useState12(false);
|
|
2574
2638
|
const handleMouseEnter = useCallback10(() => {
|
|
2575
2639
|
setIsHovering(true);
|
|
2576
2640
|
}, []);
|
|
@@ -2585,10 +2649,10 @@ function useHover() {
|
|
|
2585
2649
|
}
|
|
2586
2650
|
|
|
2587
2651
|
// src/hooks/use-promised-modal-controls.ts
|
|
2588
|
-
import { useRef as
|
|
2652
|
+
import { useRef as useRef10 } from "react";
|
|
2589
2653
|
var usePromisedModalControls = () => {
|
|
2590
2654
|
const { closeModal, isOpen, openModal } = useModalControls();
|
|
2591
|
-
const resolveRef =
|
|
2655
|
+
const resolveRef = useRef10();
|
|
2592
2656
|
const openModalWithPromise = async () => {
|
|
2593
2657
|
openModal();
|
|
2594
2658
|
return new Promise((resolve) => {
|
|
@@ -2838,7 +2902,7 @@ function DownloadEntryFormsButton({
|
|
|
2838
2902
|
}
|
|
2839
2903
|
|
|
2840
2904
|
// src/dropdown-button/DropdownButton.tsx
|
|
2841
|
-
import { useState as
|
|
2905
|
+
import { useState as useState13 } from "react";
|
|
2842
2906
|
|
|
2843
2907
|
// src/dropdown-menu/DropdownMenu.tsx
|
|
2844
2908
|
import * as React13 from "react";
|
|
@@ -2902,7 +2966,7 @@ function DropdownButton({
|
|
|
2902
2966
|
modal,
|
|
2903
2967
|
className
|
|
2904
2968
|
}) {
|
|
2905
|
-
const [isOpen, setIsOpen] =
|
|
2969
|
+
const [isOpen, setIsOpen] = useState13(false);
|
|
2906
2970
|
return /* @__PURE__ */ jsxs25(DropdownMenu, { onOpenChange: setIsOpen, modal, children: [
|
|
2907
2971
|
/* @__PURE__ */ jsx34(DropdownMenuTrigger, { asChild: true, children: typeof trigger === "function" ? trigger(isOpen) : trigger }),
|
|
2908
2972
|
/* @__PURE__ */ jsx34(
|
|
@@ -3240,7 +3304,7 @@ var Switch = React15.forwardRef(
|
|
|
3240
3304
|
Switch.displayName = SwitchPrimitives.Root.displayName;
|
|
3241
3305
|
|
|
3242
3306
|
// src/video-player/VideoPlayer.tsx
|
|
3243
|
-
import { useEffect as
|
|
3307
|
+
import { useEffect as useEffect17, useRef as useRef12, useState as useState14 } from "react";
|
|
3244
3308
|
import { useTranslation as useTranslation8 } from "react-i18next";
|
|
3245
3309
|
import {
|
|
3246
3310
|
Loader2,
|
|
@@ -3264,20 +3328,20 @@ function VideoPlayer({
|
|
|
3264
3328
|
autoPlay = false
|
|
3265
3329
|
}) {
|
|
3266
3330
|
const { t } = useTranslation8();
|
|
3267
|
-
const videoRef =
|
|
3268
|
-
const iframeRef =
|
|
3269
|
-
const containerRef =
|
|
3270
|
-
const [isPlaying, setIsPlaying] =
|
|
3271
|
-
const [isMuted, setIsMuted] =
|
|
3272
|
-
const [currentTime, setCurrentTime] =
|
|
3273
|
-
const [duration, setDuration] =
|
|
3274
|
-
const [isFullScreenMode, setIsFullScreenMode] =
|
|
3275
|
-
const [isLoading, setIsLoading] =
|
|
3276
|
-
const [videoSource, setVideoSource] =
|
|
3277
|
-
const [youtubeEmbedUrl, setYoutubeEmbedUrl] =
|
|
3278
|
-
const [vimeoEmbedUrl, setVimeoEmbedUrl] =
|
|
3331
|
+
const videoRef = useRef12(null);
|
|
3332
|
+
const iframeRef = useRef12(null);
|
|
3333
|
+
const containerRef = useRef12(null);
|
|
3334
|
+
const [isPlaying, setIsPlaying] = useState14(false);
|
|
3335
|
+
const [isMuted, setIsMuted] = useState14(false);
|
|
3336
|
+
const [currentTime, setCurrentTime] = useState14(0);
|
|
3337
|
+
const [duration, setDuration] = useState14(0);
|
|
3338
|
+
const [isFullScreenMode, setIsFullScreenMode] = useState14(isFullScreen);
|
|
3339
|
+
const [isLoading, setIsLoading] = useState14(true);
|
|
3340
|
+
const [videoSource, setVideoSource] = useState14("file");
|
|
3341
|
+
const [youtubeEmbedUrl, setYoutubeEmbedUrl] = useState14("");
|
|
3342
|
+
const [vimeoEmbedUrl, setVimeoEmbedUrl] = useState14("");
|
|
3279
3343
|
useClickEscape({ enabled: isFullScreenMode, onClick: onClose });
|
|
3280
|
-
|
|
3344
|
+
useEffect17(() => {
|
|
3281
3345
|
const youtubeRegex = /(?:youtube\.com\/watch\?v=|youtu\.be\/|youtube\.com\/embed\/)([a-zA-Z0-9_-]{11})/;
|
|
3282
3346
|
const vimeoRegex = /(?:vimeo\.com\/|vimeo\.com\/video\/)(\d+)/;
|
|
3283
3347
|
const youtubeMatch = src.match(youtubeRegex);
|
|
@@ -3306,7 +3370,7 @@ function VideoPlayer({
|
|
|
3306
3370
|
setYoutubeEmbedUrl("");
|
|
3307
3371
|
setVimeoEmbedUrl("");
|
|
3308
3372
|
}, [src, autoPlay]);
|
|
3309
|
-
|
|
3373
|
+
useEffect17(() => {
|
|
3310
3374
|
if (videoSource !== "file") return;
|
|
3311
3375
|
const video = videoRef.current;
|
|
3312
3376
|
if (!video) return;
|
|
@@ -3334,7 +3398,7 @@ function VideoPlayer({
|
|
|
3334
3398
|
video.removeEventListener("canplay", handleCanPlay);
|
|
3335
3399
|
};
|
|
3336
3400
|
}, [videoSource]);
|
|
3337
|
-
|
|
3401
|
+
useEffect17(() => {
|
|
3338
3402
|
if (isFullScreenMode && videoRef.current && videoSource === "file") {
|
|
3339
3403
|
void videoRef.current.play();
|
|
3340
3404
|
setIsPlaying(true);
|
|
@@ -3712,7 +3776,7 @@ var FormBox = {
|
|
|
3712
3776
|
import {
|
|
3713
3777
|
forwardRef as forwardRef20,
|
|
3714
3778
|
useId as useId4,
|
|
3715
|
-
useState as
|
|
3779
|
+
useState as useState15
|
|
3716
3780
|
} from "react";
|
|
3717
3781
|
import { useTranslation as useTranslation10 } from "react-i18next";
|
|
3718
3782
|
|
|
@@ -3744,8 +3808,8 @@ var FreeTextField = forwardRef20(
|
|
|
3744
3808
|
}, ref) => {
|
|
3745
3809
|
const { t } = useTranslation10();
|
|
3746
3810
|
const inputId = useId4();
|
|
3747
|
-
const [internalValue, setInternalValue] =
|
|
3748
|
-
const [isFocused, setIsFocused] =
|
|
3811
|
+
const [internalValue, setInternalValue] = useState15(defaultValue ?? "");
|
|
3812
|
+
const [isFocused, setIsFocused] = useState15(false);
|
|
3749
3813
|
const currentValue = value !== void 0 ? value : internalValue;
|
|
3750
3814
|
const isEmpty = !currentValue || String(currentValue).length === 0;
|
|
3751
3815
|
const hasError = Boolean(error);
|
|
@@ -4077,7 +4141,7 @@ function InfoBox({ className, children }) {
|
|
|
4077
4141
|
}
|
|
4078
4142
|
|
|
4079
4143
|
// src/image/Image.tsx
|
|
4080
|
-
import { useState as
|
|
4144
|
+
import { useState as useState16 } from "react";
|
|
4081
4145
|
import { jsx as jsx59 } from "react/jsx-runtime";
|
|
4082
4146
|
function Image2({
|
|
4083
4147
|
src,
|
|
@@ -4086,7 +4150,7 @@ function Image2({
|
|
|
4086
4150
|
fallbackSrc = "https://placehold.co/600x400?text=Image",
|
|
4087
4151
|
...props
|
|
4088
4152
|
}) {
|
|
4089
|
-
const [error, setError] =
|
|
4153
|
+
const [error, setError] = useState16(false);
|
|
4090
4154
|
return /* @__PURE__ */ jsx59(
|
|
4091
4155
|
"img",
|
|
4092
4156
|
{
|
|
@@ -4145,7 +4209,7 @@ function extractDigits(str) {
|
|
|
4145
4209
|
}
|
|
4146
4210
|
|
|
4147
4211
|
// src/input-otp/useInputOTP.ts
|
|
4148
|
-
import { useCallback as useCallback12, useEffect as
|
|
4212
|
+
import { useCallback as useCallback12, useEffect as useEffect18, useMemo as useMemo2, useRef as useRef13, useState as useState17 } from "react";
|
|
4149
4213
|
function useInputOTP({
|
|
4150
4214
|
maxLength,
|
|
4151
4215
|
value,
|
|
@@ -4154,11 +4218,11 @@ function useInputOTP({
|
|
|
4154
4218
|
autoFocus,
|
|
4155
4219
|
error
|
|
4156
4220
|
}) {
|
|
4157
|
-
const [activeIndex, setActiveIndex] =
|
|
4158
|
-
const inputRefs =
|
|
4159
|
-
const containerRef =
|
|
4160
|
-
const blurTimeoutRef =
|
|
4161
|
-
const slotsRef =
|
|
4221
|
+
const [activeIndex, setActiveIndex] = useState17(-1);
|
|
4222
|
+
const inputRefs = useRef13([]);
|
|
4223
|
+
const containerRef = useRef13(null);
|
|
4224
|
+
const blurTimeoutRef = useRef13();
|
|
4225
|
+
const slotsRef = useRef13(Array.from({ length: maxLength }, () => ""));
|
|
4162
4226
|
const slots = useMemo2(() => {
|
|
4163
4227
|
const nextSlots = Array.from({ length: maxLength }, () => "");
|
|
4164
4228
|
for (let index = 0; index < Math.min(value.length, maxLength); index += 1) {
|
|
@@ -4191,7 +4255,7 @@ function useInputOTP({
|
|
|
4191
4255
|
},
|
|
4192
4256
|
[onChange]
|
|
4193
4257
|
);
|
|
4194
|
-
|
|
4258
|
+
useEffect18(() => {
|
|
4195
4259
|
if (autoFocus && inputRefs.current[0]) {
|
|
4196
4260
|
inputRefs.current[0].focus();
|
|
4197
4261
|
}
|
|
@@ -4212,7 +4276,7 @@ function useInputOTP({
|
|
|
4212
4276
|
}
|
|
4213
4277
|
}, 0);
|
|
4214
4278
|
}, []);
|
|
4215
|
-
|
|
4279
|
+
useEffect18(() => () => clearTimeout(blurTimeoutRef.current), []);
|
|
4216
4280
|
const handleDigitInput = useCallback12(
|
|
4217
4281
|
(index, digit) => {
|
|
4218
4282
|
if (!DIGIT_REGEX.test(digit)) return;
|
|
@@ -4471,7 +4535,7 @@ var InputOTPSeparator = React19.forwardRef(
|
|
|
4471
4535
|
InputOTPSeparator.displayName = "InputOTPSeparator";
|
|
4472
4536
|
|
|
4473
4537
|
// src/icons-dropdown/IconsDropdown.tsx
|
|
4474
|
-
import { useState as
|
|
4538
|
+
import { useState as useState18 } from "react";
|
|
4475
4539
|
import { jsx as jsx62, jsxs as jsxs36 } from "react/jsx-runtime";
|
|
4476
4540
|
function IconsDropdown({
|
|
4477
4541
|
icons,
|
|
@@ -4483,7 +4547,7 @@ function IconsDropdown({
|
|
|
4483
4547
|
defaultOpen,
|
|
4484
4548
|
onOpenChange: onOpenChangeProp
|
|
4485
4549
|
}) {
|
|
4486
|
-
const [open, setOpen] =
|
|
4550
|
+
const [open, setOpen] = useState18(defaultOpen ?? false);
|
|
4487
4551
|
function handleOpenChange(value) {
|
|
4488
4552
|
setOpen(value);
|
|
4489
4553
|
onOpenChangeProp?.(value);
|
|
@@ -5090,14 +5154,14 @@ LinkInternal.displayName = "Link";
|
|
|
5090
5154
|
var Link = memo3(LinkInternal);
|
|
5091
5155
|
|
|
5092
5156
|
// src/image-full-screen-view/ImageFullScreenView.tsx
|
|
5093
|
-
import { useState as
|
|
5157
|
+
import { useState as useState19 } from "react";
|
|
5094
5158
|
import { RotateCw, X as X4, ZoomIn, ZoomOut } from "lucide-react";
|
|
5095
5159
|
import { useTranslation as useTranslation13 } from "react-i18next";
|
|
5096
5160
|
import { jsx as jsx67, jsxs as jsxs40 } from "react/jsx-runtime";
|
|
5097
5161
|
function ImageFullScreenView({ src, alt, onClose }) {
|
|
5098
5162
|
const { t } = useTranslation13();
|
|
5099
|
-
const [scale, setScale] =
|
|
5100
|
-
const [rotation, setRotation] =
|
|
5163
|
+
const [scale, setScale] = useState19(1);
|
|
5164
|
+
const [rotation, setRotation] = useState19(0);
|
|
5101
5165
|
useClickEscape({ onClick: onClose });
|
|
5102
5166
|
const zoomIn = () => setScale((value) => Math.min(value + 0.25, 3));
|
|
5103
5167
|
const zoomOut = () => setScale((value) => Math.max(value - 0.25, 0.5));
|
|
@@ -5295,7 +5359,7 @@ var METRIC_CARD_VARIANTS = {
|
|
|
5295
5359
|
};
|
|
5296
5360
|
|
|
5297
5361
|
// src/modal/Modal.tsx
|
|
5298
|
-
import { forwardRef as forwardRef28, useRef as
|
|
5362
|
+
import { forwardRef as forwardRef28, useRef as useRef14 } from "react";
|
|
5299
5363
|
import { X as X5 } from "lucide-react";
|
|
5300
5364
|
|
|
5301
5365
|
// src/modal/styles.module.css
|
|
@@ -5326,7 +5390,7 @@ function Modal({
|
|
|
5326
5390
|
container,
|
|
5327
5391
|
modal
|
|
5328
5392
|
}) {
|
|
5329
|
-
const contentRef =
|
|
5393
|
+
const contentRef = useRef14(null);
|
|
5330
5394
|
useScrollFrameIntoView(open, { elementRef: contentRef });
|
|
5331
5395
|
const handleClose = () => {
|
|
5332
5396
|
onOpenChange?.(false);
|
|
@@ -5807,10 +5871,10 @@ var RadioGroupItem = React22.forwardRef(({ className, ...props }, ref) => /* @__
|
|
|
5807
5871
|
RadioGroupItem.displayName = RadioGroupPrimitive.Item.displayName;
|
|
5808
5872
|
|
|
5809
5873
|
// src/radio/useRadioOptions.ts
|
|
5810
|
-
import { useCallback as useCallback14, useState as
|
|
5874
|
+
import { useCallback as useCallback14, useState as useState20 } from "react";
|
|
5811
5875
|
function useRadioOptions({ options, defaultValue, onChange }) {
|
|
5812
5876
|
const initialValue = (typeof defaultValue === "string" ? options.find((option) => option.value === defaultValue) : defaultValue) || "";
|
|
5813
|
-
const [selectedValue, setSelectedValue] =
|
|
5877
|
+
const [selectedValue, setSelectedValue] = useState20(initialValue);
|
|
5814
5878
|
const handleValueChange = useCallback14(
|
|
5815
5879
|
(value) => {
|
|
5816
5880
|
setSelectedValue(value);
|
|
@@ -6315,7 +6379,7 @@ import {
|
|
|
6315
6379
|
cloneElement as cloneElement2,
|
|
6316
6380
|
forwardRef as forwardRef34,
|
|
6317
6381
|
isValidElement as isValidElement2,
|
|
6318
|
-
useEffect as
|
|
6382
|
+
useEffect as useEffect19
|
|
6319
6383
|
} from "react";
|
|
6320
6384
|
|
|
6321
6385
|
// src/selector-button/styles.module.css
|
|
@@ -6434,7 +6498,7 @@ function SelectorsInternal({
|
|
|
6434
6498
|
}
|
|
6435
6499
|
};
|
|
6436
6500
|
const isAnyActive = getValueArray(value).length > 0;
|
|
6437
|
-
|
|
6501
|
+
useEffect19(() => {
|
|
6438
6502
|
onAnySelectorActive?.(isAnyActive);
|
|
6439
6503
|
}, [isAnyActive, onAnySelectorActive]);
|
|
6440
6504
|
return /* @__PURE__ */ jsxs56(Fragment8, { children: [
|
|
@@ -7912,10 +7976,10 @@ var TASK_VARIANTS = {
|
|
|
7912
7976
|
import { Toaster, toast as toast2 } from "sonner";
|
|
7913
7977
|
|
|
7914
7978
|
// src/toaster/useUpdateToast.ts
|
|
7915
|
-
import { useCallback as useCallback16, useRef as
|
|
7979
|
+
import { useCallback as useCallback16, useRef as useRef16 } from "react";
|
|
7916
7980
|
import { toast } from "sonner";
|
|
7917
7981
|
function useUpdateToast({ id }) {
|
|
7918
|
-
const toastIdRef =
|
|
7982
|
+
const toastIdRef = useRef16("");
|
|
7919
7983
|
const getToastOptions = useCallback16(
|
|
7920
7984
|
(options) => ({
|
|
7921
7985
|
id: toastIdRef.current,
|
|
@@ -8031,7 +8095,7 @@ var ToggleGroupItem = React27.forwardRef(({ className, children, variant, size,
|
|
|
8031
8095
|
ToggleGroupItem.displayName = ToggleGroupPrimitive.Item.displayName;
|
|
8032
8096
|
|
|
8033
8097
|
// src/toggle-group/Toggles.tsx
|
|
8034
|
-
import { forwardRef as forwardRef40, useEffect as
|
|
8098
|
+
import { forwardRef as forwardRef40, useEffect as useEffect21 } from "react";
|
|
8035
8099
|
import { jsx as jsx108, jsxs as jsxs69 } from "react/jsx-runtime";
|
|
8036
8100
|
var getValueArray2 = (value) => {
|
|
8037
8101
|
if (value) {
|
|
@@ -8106,7 +8170,7 @@ function TogglesInternal({
|
|
|
8106
8170
|
}
|
|
8107
8171
|
};
|
|
8108
8172
|
const isAnyActive = getValueArray2(value).length > 0;
|
|
8109
|
-
|
|
8173
|
+
useEffect21(() => {
|
|
8110
8174
|
onAnySelectorActive?.(isAnyActive);
|
|
8111
8175
|
}, [isAnyActive, onAnySelectorActive]);
|
|
8112
8176
|
const currentValue = getValueArray2(value).map((item) => String(item));
|
|
@@ -11693,39 +11757,6 @@ function getNextEnabledIndex(options, startIndex, step) {
|
|
|
11693
11757
|
}
|
|
11694
11758
|
return -1;
|
|
11695
11759
|
}
|
|
11696
|
-
|
|
11697
|
-
// src/lib/copy-to-clipboard.ts
|
|
11698
|
-
function copyToClipboardFallback(value) {
|
|
11699
|
-
const targetDocument = getDocument();
|
|
11700
|
-
const targetBody = targetDocument.body;
|
|
11701
|
-
if (!targetBody) {
|
|
11702
|
-
return;
|
|
11703
|
-
}
|
|
11704
|
-
const el = targetDocument.createElement("textarea");
|
|
11705
|
-
el.value = value;
|
|
11706
|
-
el.setAttribute("readonly", "");
|
|
11707
|
-
el.style.position = "fixed";
|
|
11708
|
-
el.style.opacity = "0";
|
|
11709
|
-
el.style.pointerEvents = "none";
|
|
11710
|
-
el.style.left = "-9999px";
|
|
11711
|
-
targetBody.appendChild(el);
|
|
11712
|
-
el.focus();
|
|
11713
|
-
el.select();
|
|
11714
|
-
targetDocument.execCommand("copy");
|
|
11715
|
-
targetBody.removeChild(el);
|
|
11716
|
-
}
|
|
11717
|
-
function copyToClipboard2(value) {
|
|
11718
|
-
const text = typeof value === "number" ? value.toString() : value;
|
|
11719
|
-
const targetDocument = getDocument();
|
|
11720
|
-
const clipboard = targetDocument.defaultView?.navigator?.clipboard ?? globalThis.navigator?.clipboard;
|
|
11721
|
-
if (!clipboard?.writeText) {
|
|
11722
|
-
copyToClipboardFallback(text);
|
|
11723
|
-
return;
|
|
11724
|
-
}
|
|
11725
|
-
void clipboard.writeText(text).catch(() => {
|
|
11726
|
-
copyToClipboardFallback(text);
|
|
11727
|
-
});
|
|
11728
|
-
}
|
|
11729
11760
|
export {
|
|
11730
11761
|
Accordion,
|
|
11731
11762
|
AccordionContent,
|
|
@@ -11994,6 +12025,7 @@ export {
|
|
|
11994
12025
|
useAbortController,
|
|
11995
12026
|
useClickEscape,
|
|
11996
12027
|
useCombinedRef,
|
|
12028
|
+
useCopyToClipboard,
|
|
11997
12029
|
useDebounce,
|
|
11998
12030
|
useDebouncedFunction,
|
|
11999
12031
|
useEvent,
|