@6thbridge/hexa 0.0.0-pr87-182 → 0.0.0-pr88-183
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.mts +7 -18
- package/dist/index.d.ts +7 -18
- package/dist/index.js +3 -9
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +3 -9
- package/dist/index.mjs.map +1 -1
- package/dist/output.css +5 -9
- package/package.json +3 -3
- package/tsup.config.ts +0 -11
package/dist/index.d.mts
CHANGED
|
@@ -419,11 +419,8 @@ type DrawerPropsType = {
|
|
|
419
419
|
onOpenAutoFocus?: (e: Event) => void;
|
|
420
420
|
onCloseAutoFocus?: (e: Event) => void;
|
|
421
421
|
modal?: boolean;
|
|
422
|
-
size?: "default" | "full";
|
|
423
|
-
usePortal?: boolean;
|
|
424
|
-
showOverlay?: boolean;
|
|
425
422
|
};
|
|
426
|
-
declare const Drawer: ({ trigger, children, open, onOpenChange, hideCloseButton, footer, title, description, contentClassName, headerClassName, titleClassName, descriptionClassName, footerClassName, asChild, onOpenAutoFocus, drawerContentClassName, onCloseAutoFocus, id, modal,
|
|
423
|
+
declare const Drawer: ({ trigger, children, open, onOpenChange, hideCloseButton, footer, title, description, contentClassName, headerClassName, titleClassName, descriptionClassName, footerClassName, asChild, onOpenAutoFocus, drawerContentClassName, onCloseAutoFocus, id, modal, }: Omit<DrawerRootType, "value"> & DrawerPropsType) => React$1.JSX.Element;
|
|
427
424
|
|
|
428
425
|
type LocaleOption = {
|
|
429
426
|
key: string;
|
|
@@ -458,11 +455,9 @@ type ResourcePermission = {
|
|
|
458
455
|
action: string;
|
|
459
456
|
};
|
|
460
457
|
type ResourcePermissions = ResourcePermission[];
|
|
458
|
+
type ResourcePermissionInput = ResourcePermission | ResourcePermission[];
|
|
461
459
|
type ResourcePermissionProps = {
|
|
462
|
-
permission?:
|
|
463
|
-
resource?: string;
|
|
464
|
-
action?: string;
|
|
465
|
-
};
|
|
460
|
+
permission?: ResourcePermissionInput;
|
|
466
461
|
children: ReactNode;
|
|
467
462
|
};
|
|
468
463
|
|
|
@@ -472,7 +467,7 @@ type SingleLinkType = {
|
|
|
472
467
|
isHidden?: boolean;
|
|
473
468
|
icon?: ReactNode;
|
|
474
469
|
badge?: ReactNode;
|
|
475
|
-
permission?:
|
|
470
|
+
permission?: ResourcePermissionInput;
|
|
476
471
|
key?: string;
|
|
477
472
|
id: string;
|
|
478
473
|
};
|
|
@@ -703,15 +698,9 @@ declare const PermissionsProvider: ({ permissions, children, }: {
|
|
|
703
698
|
}) => React$1.JSX.Element;
|
|
704
699
|
|
|
705
700
|
declare const usePermissions: () => ResourcePermissions | undefined;
|
|
706
|
-
declare const useHasPermission: (permission
|
|
707
|
-
resource?: string;
|
|
708
|
-
action?: string;
|
|
709
|
-
}) => {
|
|
701
|
+
declare const useHasPermission: (permission?: ResourcePermissionInput) => {
|
|
710
702
|
hasPermission: boolean;
|
|
711
|
-
validatePermission: (
|
|
712
|
-
resource?: string;
|
|
713
|
-
action?: string;
|
|
714
|
-
}) => boolean;
|
|
703
|
+
validatePermission: (permissionToCheck?: ResourcePermissionInput) => boolean;
|
|
715
704
|
};
|
|
716
705
|
|
|
717
706
|
declare const HasResourcePermission: ({ permission, children, }: ResourcePermissionProps) => React$1.JSX.Element;
|
|
@@ -984,4 +973,4 @@ declare const TagsInput: ({ value, onChange, options, label, error, placeholder,
|
|
|
984
973
|
|
|
985
974
|
declare function cn(...inputs: ClassValue[]): string;
|
|
986
975
|
|
|
987
|
-
export { Accordion, type AccordionItemType, type AccordionProps, AmountAction, Banner, Button, CalendarInput, CopyableLabel, Country, type CountryProps, type CountrySelectOption$1 as CountrySelectOption, CurrencySymbolMap, DateAction, DebouncedInput, DevBanner, Dialog, Drawer, DrawerClose, type DrawerPropsType, DrawerRoot, FeatureBanner, type FilterFieldProps, type FilterListItem, type FilterListOptions, FilterPopover, FlagComponent, FormLabel, type FormatCurrencyOptions, HasResourcePermission, Input, Loader, LocaleSelector, MultiSelect, type MultiSelectDataType, MultiSelectTrigger, OTPInput, PageDataToolbar, Pagination, PasswordInput, PermissionsContext, PermissionsProvider, PhoneInput, Popover, PopoverContent, PopoverRoot, PopoverTrigger, RadioGroup, RadioGroupItem, type ResourcePermission, type ResourcePermissionProps, type ResourcePermissions, RichTextEditor, ScrollArea, Select, Sidebar, SplitButton, type SplitButtonItem, type SplitButtonProps, Status, StringAction, Table, type TableBulkRowActionsProps, type TablePaginationProps, Tabs, type TagOption, TagsInput, type TagsInputProps, TextOverflow, type TextOverflowProps, Textarea, Tooltip, TooltipContent, TooltipProvider, TooltipRoot, TooltipTrigger, buttonVariants, cn, useFilterStore, useHasPermission, usePermissions };
|
|
976
|
+
export { Accordion, type AccordionItemType, type AccordionProps, AmountAction, Banner, Button, CalendarInput, CopyableLabel, Country, type CountryProps, type CountrySelectOption$1 as CountrySelectOption, CurrencySymbolMap, DateAction, DebouncedInput, DevBanner, Dialog, Drawer, DrawerClose, type DrawerPropsType, DrawerRoot, FeatureBanner, type FilterFieldProps, type FilterListItem, type FilterListOptions, FilterPopover, FlagComponent, FormLabel, type FormatCurrencyOptions, HasResourcePermission, Input, Loader, LocaleSelector, MultiSelect, type MultiSelectDataType, MultiSelectTrigger, OTPInput, PageDataToolbar, Pagination, PasswordInput, PermissionsContext, PermissionsProvider, PhoneInput, Popover, PopoverContent, PopoverRoot, PopoverTrigger, RadioGroup, RadioGroupItem, type ResourcePermission, type ResourcePermissionInput, type ResourcePermissionProps, type ResourcePermissions, RichTextEditor, ScrollArea, Select, Sidebar, SplitButton, type SplitButtonItem, type SplitButtonProps, Status, StringAction, Table, type TableBulkRowActionsProps, type TablePaginationProps, Tabs, type TagOption, TagsInput, type TagsInputProps, TextOverflow, type TextOverflowProps, Textarea, Tooltip, TooltipContent, TooltipProvider, TooltipRoot, TooltipTrigger, buttonVariants, cn, useFilterStore, useHasPermission, usePermissions };
|
package/dist/index.d.ts
CHANGED
|
@@ -419,11 +419,8 @@ type DrawerPropsType = {
|
|
|
419
419
|
onOpenAutoFocus?: (e: Event) => void;
|
|
420
420
|
onCloseAutoFocus?: (e: Event) => void;
|
|
421
421
|
modal?: boolean;
|
|
422
|
-
size?: "default" | "full";
|
|
423
|
-
usePortal?: boolean;
|
|
424
|
-
showOverlay?: boolean;
|
|
425
422
|
};
|
|
426
|
-
declare const Drawer: ({ trigger, children, open, onOpenChange, hideCloseButton, footer, title, description, contentClassName, headerClassName, titleClassName, descriptionClassName, footerClassName, asChild, onOpenAutoFocus, drawerContentClassName, onCloseAutoFocus, id, modal,
|
|
423
|
+
declare const Drawer: ({ trigger, children, open, onOpenChange, hideCloseButton, footer, title, description, contentClassName, headerClassName, titleClassName, descriptionClassName, footerClassName, asChild, onOpenAutoFocus, drawerContentClassName, onCloseAutoFocus, id, modal, }: Omit<DrawerRootType, "value"> & DrawerPropsType) => React$1.JSX.Element;
|
|
427
424
|
|
|
428
425
|
type LocaleOption = {
|
|
429
426
|
key: string;
|
|
@@ -458,11 +455,9 @@ type ResourcePermission = {
|
|
|
458
455
|
action: string;
|
|
459
456
|
};
|
|
460
457
|
type ResourcePermissions = ResourcePermission[];
|
|
458
|
+
type ResourcePermissionInput = ResourcePermission | ResourcePermission[];
|
|
461
459
|
type ResourcePermissionProps = {
|
|
462
|
-
permission?:
|
|
463
|
-
resource?: string;
|
|
464
|
-
action?: string;
|
|
465
|
-
};
|
|
460
|
+
permission?: ResourcePermissionInput;
|
|
466
461
|
children: ReactNode;
|
|
467
462
|
};
|
|
468
463
|
|
|
@@ -472,7 +467,7 @@ type SingleLinkType = {
|
|
|
472
467
|
isHidden?: boolean;
|
|
473
468
|
icon?: ReactNode;
|
|
474
469
|
badge?: ReactNode;
|
|
475
|
-
permission?:
|
|
470
|
+
permission?: ResourcePermissionInput;
|
|
476
471
|
key?: string;
|
|
477
472
|
id: string;
|
|
478
473
|
};
|
|
@@ -703,15 +698,9 @@ declare const PermissionsProvider: ({ permissions, children, }: {
|
|
|
703
698
|
}) => React$1.JSX.Element;
|
|
704
699
|
|
|
705
700
|
declare const usePermissions: () => ResourcePermissions | undefined;
|
|
706
|
-
declare const useHasPermission: (permission
|
|
707
|
-
resource?: string;
|
|
708
|
-
action?: string;
|
|
709
|
-
}) => {
|
|
701
|
+
declare const useHasPermission: (permission?: ResourcePermissionInput) => {
|
|
710
702
|
hasPermission: boolean;
|
|
711
|
-
validatePermission: (
|
|
712
|
-
resource?: string;
|
|
713
|
-
action?: string;
|
|
714
|
-
}) => boolean;
|
|
703
|
+
validatePermission: (permissionToCheck?: ResourcePermissionInput) => boolean;
|
|
715
704
|
};
|
|
716
705
|
|
|
717
706
|
declare const HasResourcePermission: ({ permission, children, }: ResourcePermissionProps) => React$1.JSX.Element;
|
|
@@ -984,4 +973,4 @@ declare const TagsInput: ({ value, onChange, options, label, error, placeholder,
|
|
|
984
973
|
|
|
985
974
|
declare function cn(...inputs: ClassValue[]): string;
|
|
986
975
|
|
|
987
|
-
export { Accordion, type AccordionItemType, type AccordionProps, AmountAction, Banner, Button, CalendarInput, CopyableLabel, Country, type CountryProps, type CountrySelectOption$1 as CountrySelectOption, CurrencySymbolMap, DateAction, DebouncedInput, DevBanner, Dialog, Drawer, DrawerClose, type DrawerPropsType, DrawerRoot, FeatureBanner, type FilterFieldProps, type FilterListItem, type FilterListOptions, FilterPopover, FlagComponent, FormLabel, type FormatCurrencyOptions, HasResourcePermission, Input, Loader, LocaleSelector, MultiSelect, type MultiSelectDataType, MultiSelectTrigger, OTPInput, PageDataToolbar, Pagination, PasswordInput, PermissionsContext, PermissionsProvider, PhoneInput, Popover, PopoverContent, PopoverRoot, PopoverTrigger, RadioGroup, RadioGroupItem, type ResourcePermission, type ResourcePermissionProps, type ResourcePermissions, RichTextEditor, ScrollArea, Select, Sidebar, SplitButton, type SplitButtonItem, type SplitButtonProps, Status, StringAction, Table, type TableBulkRowActionsProps, type TablePaginationProps, Tabs, type TagOption, TagsInput, type TagsInputProps, TextOverflow, type TextOverflowProps, Textarea, Tooltip, TooltipContent, TooltipProvider, TooltipRoot, TooltipTrigger, buttonVariants, cn, useFilterStore, useHasPermission, usePermissions };
|
|
976
|
+
export { Accordion, type AccordionItemType, type AccordionProps, AmountAction, Banner, Button, CalendarInput, CopyableLabel, Country, type CountryProps, type CountrySelectOption$1 as CountrySelectOption, CurrencySymbolMap, DateAction, DebouncedInput, DevBanner, Dialog, Drawer, DrawerClose, type DrawerPropsType, DrawerRoot, FeatureBanner, type FilterFieldProps, type FilterListItem, type FilterListOptions, FilterPopover, FlagComponent, FormLabel, type FormatCurrencyOptions, HasResourcePermission, Input, Loader, LocaleSelector, MultiSelect, type MultiSelectDataType, MultiSelectTrigger, OTPInput, PageDataToolbar, Pagination, PasswordInput, PermissionsContext, PermissionsProvider, PhoneInput, Popover, PopoverContent, PopoverRoot, PopoverTrigger, RadioGroup, RadioGroupItem, type ResourcePermission, type ResourcePermissionInput, type ResourcePermissionProps, type ResourcePermissions, RichTextEditor, ScrollArea, Select, Sidebar, SplitButton, type SplitButtonItem, type SplitButtonProps, Status, StringAction, Table, type TableBulkRowActionsProps, type TablePaginationProps, Tabs, type TagOption, TagsInput, type TagsInputProps, TextOverflow, type TextOverflowProps, Textarea, Tooltip, TooltipContent, TooltipProvider, TooltipRoot, TooltipTrigger, buttonVariants, cn, useFilterStore, useHasPermission, usePermissions };
|