@fabio.caffarello/react-design-system 3.8.0 → 3.10.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -1
- package/dist/granular/index.js +447 -0
- package/dist/granular/index.js.map +1 -0
- package/dist/granular/ui/components/Accordion/Accordion.js +105 -0
- package/dist/granular/ui/components/Accordion/Accordion.js.map +1 -0
- package/dist/granular/ui/components/Autocomplete/Autocomplete.js +133 -0
- package/dist/granular/ui/components/Autocomplete/Autocomplete.js.map +1 -0
- package/dist/granular/ui/components/Autocomplete/AutocompleteList.js +119 -0
- package/dist/granular/ui/components/Autocomplete/AutocompleteList.js.map +1 -0
- package/dist/granular/ui/components/Autocomplete/AutocompleteOption.js +42 -0
- package/dist/granular/ui/components/Autocomplete/AutocompleteOption.js.map +1 -0
- package/dist/granular/ui/components/Breadcrumb/Breadcrumb.js +100 -0
- package/dist/granular/ui/components/Breadcrumb/Breadcrumb.js.map +1 -0
- package/dist/granular/ui/components/Card/Card.js +113 -0
- package/dist/granular/ui/components/Card/Card.js.map +1 -0
- package/dist/granular/ui/components/Card/CardActions.js +51 -0
- package/dist/granular/ui/components/Card/CardActions.js.map +1 -0
- package/dist/granular/ui/components/Card/CardBody.js +32 -0
- package/dist/granular/ui/components/Card/CardBody.js.map +1 -0
- package/dist/granular/ui/components/Card/CardHeader.js +47 -0
- package/dist/granular/ui/components/Card/CardHeader.js.map +1 -0
- package/dist/granular/ui/components/Card/CardSubtitle.js +38 -0
- package/dist/granular/ui/components/Card/CardSubtitle.js.map +1 -0
- package/dist/granular/ui/components/Card/CardTitle.js +61 -0
- package/dist/granular/ui/components/Card/CardTitle.js.map +1 -0
- package/dist/granular/ui/components/ColorPicker/ColorPicker.js +250 -0
- package/dist/granular/ui/components/ColorPicker/ColorPicker.js.map +1 -0
- package/dist/granular/ui/components/CommandPalette/CommandPalette.js +274 -0
- package/dist/granular/ui/components/CommandPalette/CommandPalette.js.map +1 -0
- package/dist/granular/ui/components/DashboardLayout/DashboardLayout.js +37 -0
- package/dist/granular/ui/components/DashboardLayout/DashboardLayout.js.map +1 -0
- package/dist/granular/ui/components/DataGrid/DataGrid.js +155 -0
- package/dist/granular/ui/components/DataGrid/DataGrid.js.map +1 -0
- package/dist/granular/ui/components/DataTablePattern/DataTablePattern.js +113 -0
- package/dist/granular/ui/components/DataTablePattern/DataTablePattern.js.map +1 -0
- package/dist/granular/ui/components/DatePicker/DatePicker.js +126 -0
- package/dist/granular/ui/components/DatePicker/DatePicker.js.map +1 -0
- package/dist/granular/ui/components/DatePicker/DatePickerCalendar.js +294 -0
- package/dist/granular/ui/components/DatePicker/DatePickerCalendar.js.map +1 -0
- package/dist/granular/ui/components/DatePicker/DatePickerContext.js +16 -0
- package/dist/granular/ui/components/DatePicker/DatePickerContext.js.map +1 -0
- package/dist/granular/ui/components/DatePicker/DatePickerInput.js +119 -0
- package/dist/granular/ui/components/DatePicker/DatePickerInput.js.map +1 -0
- package/dist/granular/ui/components/DatePicker/DatePickerProvider.js +47 -0
- package/dist/granular/ui/components/DatePicker/DatePickerProvider.js.map +1 -0
- package/dist/granular/ui/components/Dialog/AlertDialog.js +48 -0
- package/dist/granular/ui/components/Dialog/AlertDialog.js.map +1 -0
- package/dist/granular/ui/components/Dialog/Dialog.js +36 -0
- package/dist/granular/ui/components/Dialog/Dialog.js.map +1 -0
- package/dist/granular/ui/components/Dialog/DialogClose.js +34 -0
- package/dist/granular/ui/components/Dialog/DialogClose.js.map +1 -0
- package/dist/granular/ui/components/Dialog/DialogContent.js +114 -0
- package/dist/granular/ui/components/Dialog/DialogContent.js.map +1 -0
- package/dist/granular/ui/components/Dialog/DialogDescription.js +51 -0
- package/dist/granular/ui/components/Dialog/DialogDescription.js.map +1 -0
- package/dist/granular/ui/components/Dialog/DialogFooter.js +45 -0
- package/dist/granular/ui/components/Dialog/DialogFooter.js.map +1 -0
- package/dist/granular/ui/components/Dialog/DialogHeader.js +45 -0
- package/dist/granular/ui/components/Dialog/DialogHeader.js.map +1 -0
- package/dist/granular/ui/components/Dialog/DialogTitle.js +53 -0
- package/dist/granular/ui/components/Dialog/DialogTitle.js.map +1 -0
- package/dist/granular/ui/components/Dialog/DialogTrigger.js +28 -0
- package/dist/granular/ui/components/Dialog/DialogTrigger.js.map +1 -0
- package/dist/granular/ui/components/Drawer/Drawer.js +47 -0
- package/dist/granular/ui/components/Drawer/Drawer.js.map +1 -0
- package/dist/granular/ui/components/Drawer/DrawerContent.js +140 -0
- package/dist/granular/ui/components/Drawer/DrawerContent.js.map +1 -0
- package/dist/granular/ui/components/Drawer/DrawerContext.js +21 -0
- package/dist/granular/ui/components/Drawer/DrawerContext.js.map +1 -0
- package/dist/granular/ui/components/Drawer/DrawerFooter.js +53 -0
- package/dist/granular/ui/components/Drawer/DrawerFooter.js.map +1 -0
- package/dist/granular/ui/components/Drawer/DrawerHeader.js +50 -0
- package/dist/granular/ui/components/Drawer/DrawerHeader.js.map +1 -0
- package/dist/granular/ui/components/Dropdown/Dropdown.js +243 -0
- package/dist/granular/ui/components/Dropdown/Dropdown.js.map +1 -0
- package/dist/granular/ui/components/EmptyState/EmptyState.js +102 -0
- package/dist/granular/ui/components/EmptyState/EmptyState.js.map +1 -0
- package/dist/granular/ui/components/FileUpload/FileUpload.js +342 -0
- package/dist/granular/ui/components/FileUpload/FileUpload.js.map +1 -0
- package/dist/granular/ui/components/FilterChips/FilterChips.js +67 -0
- package/dist/granular/ui/components/FilterChips/FilterChips.js.map +1 -0
- package/dist/granular/ui/components/Form/Form.js +184 -0
- package/dist/granular/ui/components/Form/Form.js.map +1 -0
- package/dist/granular/ui/components/Form/FormContext.js +19 -0
- package/dist/granular/ui/components/Form/FormContext.js.map +1 -0
- package/dist/granular/ui/components/Form/FormField.js +66 -0
- package/dist/granular/ui/components/Form/FormField.js.map +1 -0
- package/dist/granular/ui/components/Form/FormProvider.js +17 -0
- package/dist/granular/ui/components/Form/FormProvider.js.map +1 -0
- package/dist/granular/ui/components/Form/useFormFieldArray.js +29 -0
- package/dist/granular/ui/components/Form/useFormFieldArray.js.map +1 -0
- package/dist/granular/ui/components/FormWizardPattern/FormWizardPattern.js +121 -0
- package/dist/granular/ui/components/FormWizardPattern/FormWizardPattern.js.map +1 -0
- package/dist/granular/ui/components/Header/Header.js +98 -0
- package/dist/granular/ui/components/Header/Header.js.map +1 -0
- package/dist/granular/ui/components/Header/components/HeaderActions.js +21 -0
- package/dist/granular/ui/components/Header/components/HeaderActions.js.map +1 -0
- package/dist/granular/ui/components/Header/components/HeaderHamburger.js +31 -0
- package/dist/granular/ui/components/Header/components/HeaderHamburger.js.map +1 -0
- package/dist/granular/ui/components/Header/components/HeaderLogo.js +50 -0
- package/dist/granular/ui/components/Header/components/HeaderLogo.js.map +1 -0
- package/dist/granular/ui/components/Header/components/HeaderMobileMenu.js +38 -0
- package/dist/granular/ui/components/Header/components/HeaderMobileMenu.js.map +1 -0
- package/dist/granular/ui/components/Header/components/HeaderNavigation.js +27 -0
- package/dist/granular/ui/components/Header/components/HeaderNavigation.js.map +1 -0
- package/dist/granular/ui/components/Header/contexts/HeaderContext.js +49 -0
- package/dist/granular/ui/components/Header/contexts/HeaderContext.js.map +1 -0
- package/dist/granular/ui/components/LoginBox/LoginBox.js +84 -0
- package/dist/granular/ui/components/LoginBox/LoginBox.js.map +1 -0
- package/dist/granular/ui/components/Menu/Menu.js +45 -0
- package/dist/granular/ui/components/Menu/Menu.js.map +1 -0
- package/dist/granular/ui/components/Menu/MenuContent.js +94 -0
- package/dist/granular/ui/components/Menu/MenuContent.js.map +1 -0
- package/dist/granular/ui/components/Menu/MenuContext.js +21 -0
- package/dist/granular/ui/components/Menu/MenuContext.js.map +1 -0
- package/dist/granular/ui/components/Menu/MenuItem.js +93 -0
- package/dist/granular/ui/components/Menu/MenuItem.js.map +1 -0
- package/dist/granular/ui/components/Menu/MenuSeparator.js +46 -0
- package/dist/granular/ui/components/Menu/MenuSeparator.js.map +1 -0
- package/dist/granular/ui/components/Menu/MenuTrigger.js +71 -0
- package/dist/granular/ui/components/Menu/MenuTrigger.js.map +1 -0
- package/dist/granular/ui/components/Modal/Modal.js +171 -0
- package/dist/granular/ui/components/Modal/Modal.js.map +1 -0
- package/dist/granular/ui/components/MultiSelect/MultiSelect.js +193 -0
- package/dist/granular/ui/components/MultiSelect/MultiSelect.js.map +1 -0
- package/dist/granular/ui/components/Navigation/Navigation.js +141 -0
- package/dist/granular/ui/components/Navigation/Navigation.js.map +1 -0
- package/dist/granular/ui/components/PageHeader/PageHeader.js +95 -0
- package/dist/granular/ui/components/PageHeader/PageHeader.js.map +1 -0
- package/dist/granular/ui/components/Pagination/Pagination.js +156 -0
- package/dist/granular/ui/components/Pagination/Pagination.js.map +1 -0
- package/dist/granular/ui/components/Popover/Popover.js +171 -0
- package/dist/granular/ui/components/Popover/Popover.js.map +1 -0
- package/dist/granular/ui/components/Rating/Rating.js +110 -0
- package/dist/granular/ui/components/Rating/Rating.js.map +1 -0
- package/dist/granular/ui/components/SearchAndFilterPattern/SearchAndFilterPattern.js +120 -0
- package/dist/granular/ui/components/SearchAndFilterPattern/SearchAndFilterPattern.js.map +1 -0
- package/dist/granular/ui/components/SearchInput/SearchInput.js +103 -0
- package/dist/granular/ui/components/SearchInput/SearchInput.js.map +1 -0
- package/dist/granular/ui/components/SideNavbar/SideNavbar.js +143 -0
- package/dist/granular/ui/components/SideNavbar/SideNavbar.js.map +1 -0
- package/dist/granular/ui/components/SideNavbar/components/Navbar/Navbar.js +173 -0
- package/dist/granular/ui/components/SideNavbar/components/Navbar/Navbar.js.map +1 -0
- package/dist/granular/ui/components/SideNavbar/components/Navbar/NavbarGroup.js +87 -0
- package/dist/granular/ui/components/SideNavbar/components/Navbar/NavbarGroup.js.map +1 -0
- package/dist/granular/ui/components/SideNavbar/components/Navbar/NavbarItem.js +242 -0
- package/dist/granular/ui/components/SideNavbar/components/Navbar/NavbarItem.js.map +1 -0
- package/dist/granular/ui/components/SideNavbar/components/Navbar/NavbarSeparator.js +66 -0
- package/dist/granular/ui/components/SideNavbar/components/Navbar/NavbarSeparator.js.map +1 -0
- package/dist/granular/ui/components/SideNavbar/components/Navbar/NavbarToggle.js +108 -0
- package/dist/granular/ui/components/SideNavbar/components/Navbar/NavbarToggle.js.map +1 -0
- package/dist/granular/ui/components/SideNavbar/components/SideNavbarBackdrop.js +63 -0
- package/dist/granular/ui/components/SideNavbar/components/SideNavbarBackdrop.js.map +1 -0
- package/dist/granular/ui/components/SideNavbar/components/SideNavbarResizeHandle.js +113 -0
- package/dist/granular/ui/components/SideNavbar/components/SideNavbarResizeHandle.js.map +1 -0
- package/dist/granular/ui/components/SideNavbar/components/SideNavbarRoot.js +150 -0
- package/dist/granular/ui/components/SideNavbar/components/SideNavbarRoot.js.map +1 -0
- package/dist/granular/ui/components/SideNavbar/components/SideNavbarToggle.js +197 -0
- package/dist/granular/ui/components/SideNavbar/components/SideNavbarToggle.js.map +1 -0
- package/dist/granular/ui/components/SideNavbar/components/Sidebar/Sidebar.js +108 -0
- package/dist/granular/ui/components/SideNavbar/components/Sidebar/Sidebar.js.map +1 -0
- package/dist/granular/ui/components/SideNavbar/components/Sidebar/SidebarContent.js +71 -0
- package/dist/granular/ui/components/SideNavbar/components/Sidebar/SidebarContent.js.map +1 -0
- package/dist/granular/ui/components/SideNavbar/components/Sidebar/SidebarFooter.js +64 -0
- package/dist/granular/ui/components/SideNavbar/components/Sidebar/SidebarFooter.js.map +1 -0
- package/dist/granular/ui/components/SideNavbar/components/Sidebar/SidebarGroup.js +141 -0
- package/dist/granular/ui/components/SideNavbar/components/Sidebar/SidebarGroup.js.map +1 -0
- package/dist/granular/ui/components/SideNavbar/components/Sidebar/SidebarHeader.js +90 -0
- package/dist/granular/ui/components/SideNavbar/components/Sidebar/SidebarHeader.js.map +1 -0
- package/dist/granular/ui/components/SideNavbar/components/Sidebar/SidebarSlot.js +12 -0
- package/dist/granular/ui/components/SideNavbar/components/Sidebar/SidebarSlot.js.map +1 -0
- package/dist/granular/ui/components/SideNavbar/components/Sidebar/SidebarSlotContent.js +13 -0
- package/dist/granular/ui/components/SideNavbar/components/Sidebar/SidebarSlotContent.js.map +1 -0
- package/dist/granular/ui/components/SideNavbar/contexts/NavbarContext.js +20 -0
- package/dist/granular/ui/components/SideNavbar/contexts/NavbarContext.js.map +1 -0
- package/dist/granular/ui/components/SideNavbar/contexts/SideNavbarConfigContext.js +37 -0
- package/dist/granular/ui/components/SideNavbar/contexts/SideNavbarConfigContext.js.map +1 -0
- package/dist/granular/ui/components/SideNavbar/contexts/SideNavbarStateContext.js +20 -0
- package/dist/granular/ui/components/SideNavbar/contexts/SideNavbarStateContext.js.map +1 -0
- package/dist/granular/ui/components/SideNavbar/contexts/SideNavbarThemeContext.js +28 -0
- package/dist/granular/ui/components/SideNavbar/contexts/SideNavbarThemeContext.js.map +1 -0
- package/dist/granular/ui/components/SideNavbar/contexts/SideNavbarToggleContext.js +19 -0
- package/dist/granular/ui/components/SideNavbar/contexts/SideNavbarToggleContext.js.map +1 -0
- package/dist/granular/ui/components/SideNavbar/contexts/SidebarContext.js +20 -0
- package/dist/granular/ui/components/SideNavbar/contexts/SidebarContext.js.map +1 -0
- package/dist/granular/ui/components/SideNavbar/contexts/SidebarSlotContext.js +22 -0
- package/dist/granular/ui/components/SideNavbar/contexts/SidebarSlotContext.js.map +1 -0
- package/dist/granular/ui/components/SideNavbar/hooks/useFocusManagement.js +43 -0
- package/dist/granular/ui/components/SideNavbar/hooks/useFocusManagement.js.map +1 -0
- package/dist/granular/ui/components/SideNavbar/hooks/useGroupState.js +59 -0
- package/dist/granular/ui/components/SideNavbar/hooks/useGroupState.js.map +1 -0
- package/dist/granular/ui/components/SideNavbar/hooks/useKeyboardShortcut.js +34 -0
- package/dist/granular/ui/components/SideNavbar/hooks/useKeyboardShortcut.js.map +1 -0
- package/dist/granular/ui/components/SideNavbar/hooks/useResize.js +58 -0
- package/dist/granular/ui/components/SideNavbar/hooks/useResize.js.map +1 -0
- package/dist/granular/ui/components/SideNavbar/hooks/useResponsiveSidebar.js +35 -0
- package/dist/granular/ui/components/SideNavbar/hooks/useResponsiveSidebar.js.map +1 -0
- package/dist/granular/ui/components/SideNavbar/hooks/useSideNavbar.js +21 -0
- package/dist/granular/ui/components/SideNavbar/hooks/useSideNavbar.js.map +1 -0
- package/dist/granular/ui/components/SideNavbar/hooks/useSideNavbarContent.js +19 -0
- package/dist/granular/ui/components/SideNavbar/hooks/useSideNavbarContent.js.map +1 -0
- package/dist/granular/ui/components/SideNavbar/hooks/useSideNavbarNavigation.js +21 -0
- package/dist/granular/ui/components/SideNavbar/hooks/useSideNavbarNavigation.js.map +1 -0
- package/dist/granular/ui/components/SideNavbar/providers/SideNavbarConfigProvider.js +61 -0
- package/dist/granular/ui/components/SideNavbar/providers/SideNavbarConfigProvider.js.map +1 -0
- package/dist/granular/ui/components/SideNavbar/providers/SideNavbarProvider.js +82 -0
- package/dist/granular/ui/components/SideNavbar/providers/SideNavbarProvider.js.map +1 -0
- package/dist/granular/ui/components/SideNavbar/providers/SideNavbarStateProvider.js +165 -0
- package/dist/granular/ui/components/SideNavbar/providers/SideNavbarStateProvider.js.map +1 -0
- package/dist/granular/ui/components/SideNavbar/providers/SideNavbarThemeProvider.js +34 -0
- package/dist/granular/ui/components/SideNavbar/providers/SideNavbarThemeProvider.js.map +1 -0
- package/dist/granular/ui/components/SideNavbar/providers/SidebarSlotProvider.js +28 -0
- package/dist/granular/ui/components/SideNavbar/providers/SidebarSlotProvider.js.map +1 -0
- package/dist/granular/ui/components/SideNavbar/utils/parseKeyboardShortcut.js +60 -0
- package/dist/granular/ui/components/SideNavbar/utils/parseKeyboardShortcut.js.map +1 -0
- package/dist/granular/ui/components/SideNavbar/utils/parseWidth.js +19 -0
- package/dist/granular/ui/components/SideNavbar/utils/parseWidth.js.map +1 -0
- package/dist/granular/ui/components/Stat/Stat.js +84 -0
- package/dist/granular/ui/components/Stat/Stat.js.map +1 -0
- package/dist/granular/ui/components/Stat/StatGroup.js +61 -0
- package/dist/granular/ui/components/Stat/StatGroup.js.map +1 -0
- package/dist/granular/ui/components/Stepper/Stepper.js +248 -0
- package/dist/granular/ui/components/Stepper/Stepper.js.map +1 -0
- package/dist/granular/ui/components/Table/Table.js +162 -0
- package/dist/granular/ui/components/Table/Table.js.map +1 -0
- package/dist/granular/ui/components/Table/TableActions/TableActions.js +67 -0
- package/dist/granular/ui/components/Table/TableActions/TableActions.js.map +1 -0
- package/dist/granular/ui/components/Table/TableActions.js +44 -0
- package/dist/granular/ui/components/Table/TableActions.js.map +1 -0
- package/dist/granular/ui/components/Table/TableBody.js +134 -0
- package/dist/granular/ui/components/Table/TableBody.js.map +1 -0
- package/dist/granular/ui/components/Table/TableCell.js +40 -0
- package/dist/granular/ui/components/Table/TableCell.js.map +1 -0
- package/dist/granular/ui/components/Table/TableContext.js +19 -0
- package/dist/granular/ui/components/Table/TableContext.js.map +1 -0
- package/dist/granular/ui/components/Table/TableEmptyState.js +62 -0
- package/dist/granular/ui/components/Table/TableEmptyState.js.map +1 -0
- package/dist/granular/ui/components/Table/TableFilters/TableFilters.js +189 -0
- package/dist/granular/ui/components/Table/TableFilters/TableFilters.js.map +1 -0
- package/dist/granular/ui/components/Table/TableFilters.js +48 -0
- package/dist/granular/ui/components/Table/TableFilters.js.map +1 -0
- package/dist/granular/ui/components/Table/TableHeader.js +45 -0
- package/dist/granular/ui/components/Table/TableHeader.js.map +1 -0
- package/dist/granular/ui/components/Table/TableHeaderCell.js +117 -0
- package/dist/granular/ui/components/Table/TableHeaderCell.js.map +1 -0
- package/dist/granular/ui/components/Table/TableHeaderRow.js +89 -0
- package/dist/granular/ui/components/Table/TableHeaderRow.js.map +1 -0
- package/dist/granular/ui/components/Table/TablePagination/TablePagination.js +216 -0
- package/dist/granular/ui/components/Table/TablePagination/TablePagination.js.map +1 -0
- package/dist/granular/ui/components/Table/TablePagination.js +56 -0
- package/dist/granular/ui/components/Table/TablePagination.js.map +1 -0
- package/dist/granular/ui/components/Table/TableProvider.js +244 -0
- package/dist/granular/ui/components/Table/TableProvider.js.map +1 -0
- package/dist/granular/ui/components/Table/TableRow.js +95 -0
- package/dist/granular/ui/components/Table/TableRow.js.map +1 -0
- package/dist/granular/ui/components/Table/useColumnResizing.js +71 -0
- package/dist/granular/ui/components/Table/useColumnResizing.js.map +1 -0
- package/dist/granular/ui/components/Table/useVirtualScrolling.js +50 -0
- package/dist/granular/ui/components/Table/useVirtualScrolling.js.map +1 -0
- package/dist/granular/ui/components/Tabs/Tabs.js +39 -0
- package/dist/granular/ui/components/Tabs/Tabs.js.map +1 -0
- package/dist/granular/ui/components/Tabs/TabsContent.js +59 -0
- package/dist/granular/ui/components/Tabs/TabsContent.js.map +1 -0
- package/dist/granular/ui/components/Tabs/TabsContext.js +18 -0
- package/dist/granular/ui/components/Tabs/TabsContext.js.map +1 -0
- package/dist/granular/ui/components/Tabs/TabsList.js +84 -0
- package/dist/granular/ui/components/Tabs/TabsList.js.map +1 -0
- package/dist/granular/ui/components/Tabs/TabsProvider.js +31 -0
- package/dist/granular/ui/components/Tabs/TabsProvider.js.map +1 -0
- package/dist/granular/ui/components/Tabs/TabsTrigger.js +103 -0
- package/dist/granular/ui/components/Tabs/TabsTrigger.js.map +1 -0
- package/dist/granular/ui/components/TimePicker/TimePicker.js +216 -0
- package/dist/granular/ui/components/TimePicker/TimePicker.js.map +1 -0
- package/dist/granular/ui/components/Timeline/Timeline.js +152 -0
- package/dist/granular/ui/components/Timeline/Timeline.js.map +1 -0
- package/dist/granular/ui/components/Toast/Toast.js +159 -0
- package/dist/granular/ui/components/Toast/Toast.js.map +1 -0
- package/dist/granular/ui/components/Toast/ToastContainer.js +41 -0
- package/dist/granular/ui/components/Toast/ToastContainer.js.map +1 -0
- package/dist/granular/ui/components/Toast/useToast.js +64 -0
- package/dist/granular/ui/components/Toast/useToast.js.map +1 -0
- package/dist/granular/ui/hooks/createGenericContext.js +27 -0
- package/dist/granular/ui/hooks/createGenericContext.js.map +1 -0
- package/dist/granular/ui/hooks/focusable.js +14 -0
- package/dist/granular/ui/hooks/focusable.js.map +1 -0
- package/dist/granular/ui/hooks/useAutoFocus.js +23 -0
- package/dist/granular/ui/hooks/useAutoFocus.js.map +1 -0
- package/dist/granular/ui/hooks/useCollapsible.js +37 -0
- package/dist/granular/ui/hooks/useCollapsible.js.map +1 -0
- package/dist/granular/ui/hooks/useFocusRestore.js +20 -0
- package/dist/granular/ui/hooks/useFocusRestore.js.map +1 -0
- package/dist/granular/ui/hooks/useFocusTrap.js +31 -0
- package/dist/granular/ui/hooks/useFocusTrap.js.map +1 -0
- package/dist/granular/ui/hooks/useScrollSpy.js +23 -0
- package/dist/granular/ui/hooks/useScrollSpy.js.map +1 -0
- package/dist/granular/ui/layouts/Container/Container.js +73 -0
- package/dist/granular/ui/layouts/Container/Container.js.map +1 -0
- package/dist/granular/ui/layouts/Stack/Stack.js +79 -0
- package/dist/granular/ui/layouts/Stack/Stack.js.map +1 -0
- package/dist/granular/ui/primitives/Avatar/Avatar.js +122 -0
- package/dist/granular/ui/primitives/Avatar/Avatar.js.map +1 -0
- package/dist/granular/ui/primitives/Avatar/AvatarGroup.js +97 -0
- package/dist/granular/ui/primitives/Avatar/AvatarGroup.js.map +1 -0
- package/dist/granular/ui/primitives/Badge/Badge.js +212 -0
- package/dist/granular/ui/primitives/Badge/Badge.js.map +1 -0
- package/dist/granular/ui/primitives/Button/Button.js +288 -0
- package/dist/granular/ui/primitives/Button/Button.js.map +1 -0
- package/dist/granular/ui/primitives/Checkbox/Checkbox.js +129 -0
- package/dist/granular/ui/primitives/Checkbox/Checkbox.js.map +1 -0
- package/dist/granular/ui/primitives/Chip/Chip.js +206 -0
- package/dist/granular/ui/primitives/Chip/Chip.js.map +1 -0
- package/dist/granular/ui/primitives/Collapsible/Collapsible.js +115 -0
- package/dist/granular/ui/primitives/Collapsible/Collapsible.js.map +1 -0
- package/dist/granular/ui/primitives/ErrorMessage/ErrorMessage.js +54 -0
- package/dist/granular/ui/primitives/ErrorMessage/ErrorMessage.js.map +1 -0
- package/dist/granular/ui/primitives/Info/Info.js +57 -0
- package/dist/granular/ui/primitives/Info/Info.js.map +1 -0
- package/dist/granular/ui/primitives/Input/Input.js +351 -0
- package/dist/granular/ui/primitives/Input/Input.js.map +1 -0
- package/dist/granular/ui/primitives/Label/Label.js +61 -0
- package/dist/granular/ui/primitives/Label/Label.js.map +1 -0
- package/dist/granular/ui/primitives/NavLink/NavLink.js +229 -0
- package/dist/granular/ui/primitives/NavLink/NavLink.js.map +1 -0
- package/dist/granular/ui/primitives/NavLink/hooks/useNavLink.js +15 -0
- package/dist/granular/ui/primitives/NavLink/hooks/useNavLink.js.map +1 -0
- package/dist/granular/ui/primitives/Progress/Progress.js +182 -0
- package/dist/granular/ui/primitives/Progress/Progress.js.map +1 -0
- package/dist/granular/ui/primitives/Radio/Radio.js +118 -0
- package/dist/granular/ui/primitives/Radio/Radio.js.map +1 -0
- package/dist/granular/ui/primitives/Select/Select.js +210 -0
- package/dist/granular/ui/primitives/Select/Select.js.map +1 -0
- package/dist/granular/ui/primitives/Separator/Separator.js +69 -0
- package/dist/granular/ui/primitives/Separator/Separator.js.map +1 -0
- package/dist/granular/ui/primitives/Skeleton/Skeleton.js +87 -0
- package/dist/granular/ui/primitives/Skeleton/Skeleton.js.map +1 -0
- package/dist/granular/ui/primitives/Slider/Slider.js +291 -0
- package/dist/granular/ui/primitives/Slider/Slider.js.map +1 -0
- package/dist/granular/ui/primitives/Spinner/Spinner.js +95 -0
- package/dist/granular/ui/primitives/Spinner/Spinner.js.map +1 -0
- package/dist/granular/ui/primitives/Switch/Switch.js +212 -0
- package/dist/granular/ui/primitives/Switch/Switch.js.map +1 -0
- package/dist/granular/ui/primitives/Text/Text.js +118 -0
- package/dist/granular/ui/primitives/Text/Text.js.map +1 -0
- package/dist/granular/ui/primitives/Textarea/Textarea.js +129 -0
- package/dist/granular/ui/primitives/Textarea/Textarea.js.map +1 -0
- package/dist/granular/ui/primitives/Tooltip/Tooltip.js +227 -0
- package/dist/granular/ui/primitives/Tooltip/Tooltip.js.map +1 -0
- package/dist/granular/ui/providers/AppProvider.js +50 -0
- package/dist/granular/ui/providers/AppProvider.js.map +1 -0
- package/dist/granular/ui/providers/ConfigProvider.js +95 -0
- package/dist/granular/ui/providers/ConfigProvider.js.map +1 -0
- package/dist/granular/ui/providers/DialogContext.js +20 -0
- package/dist/granular/ui/providers/DialogContext.js.map +1 -0
- package/dist/granular/ui/providers/DialogProvider.js +32 -0
- package/dist/granular/ui/providers/DialogProvider.js.map +1 -0
- package/dist/granular/ui/providers/ThemeProvider.js +56 -0
- package/dist/granular/ui/providers/ThemeProvider.js.map +1 -0
- package/dist/granular/ui/providers/ToastContext.js +20 -0
- package/dist/granular/ui/providers/ToastContext.js.map +1 -0
- package/dist/granular/ui/providers/ToastProvider.js +47 -0
- package/dist/granular/ui/providers/ToastProvider.js.map +1 -0
- package/dist/granular/ui/providers/providers-bundle.js +23 -0
- package/dist/granular/ui/providers/providers-bundle.js.map +1 -0
- package/dist/granular/ui/tokens/animations.js +106 -0
- package/dist/granular/ui/tokens/animations.js.map +1 -0
- package/dist/granular/ui/tokens/borders.js +54 -0
- package/dist/granular/ui/tokens/borders.js.map +1 -0
- package/dist/granular/ui/tokens/breakpoints.js +43 -0
- package/dist/granular/ui/tokens/breakpoints.js.map +1 -0
- package/dist/granular/ui/tokens/colors/brand.js +67 -0
- package/dist/granular/ui/tokens/colors/brand.js.map +1 -0
- package/dist/granular/ui/tokens/colors/index.js +25 -0
- package/dist/granular/ui/tokens/colors/index.js.map +1 -0
- package/dist/granular/ui/tokens/colors/primitives.js +320 -0
- package/dist/granular/ui/tokens/colors/primitives.js.map +1 -0
- package/dist/granular/ui/tokens/colors/semantic.js +212 -0
- package/dist/granular/ui/tokens/colors/semantic.js.map +1 -0
- package/dist/granular/ui/tokens/colors/types.js +18 -0
- package/dist/granular/ui/tokens/colors/types.js.map +1 -0
- package/dist/granular/ui/tokens/colors/utils.js +131 -0
- package/dist/granular/ui/tokens/colors/utils.js.map +1 -0
- package/dist/granular/ui/tokens/opacity.js +59 -0
- package/dist/granular/ui/tokens/opacity.js.map +1 -0
- package/dist/granular/ui/tokens/radius.js +76 -0
- package/dist/granular/ui/tokens/radius.js.map +1 -0
- package/dist/granular/ui/tokens/shadows.js +63 -0
- package/dist/granular/ui/tokens/shadows.js.map +1 -0
- package/dist/granular/ui/tokens/sidebar.js +92 -0
- package/dist/granular/ui/tokens/sidebar.js.map +1 -0
- package/dist/granular/ui/tokens/spacing.js +143 -0
- package/dist/granular/ui/tokens/spacing.js.map +1 -0
- package/dist/granular/ui/tokens/switch.js +51 -0
- package/dist/granular/ui/tokens/switch.js.map +1 -0
- package/dist/granular/ui/tokens/typography.js +146 -0
- package/dist/granular/ui/tokens/typography.js.map +1 -0
- package/dist/granular/ui/tokens/z-index.js +79 -0
- package/dist/granular/ui/tokens/z-index.js.map +1 -0
- package/dist/granular/ui/utils/cn.js +10 -0
- package/dist/granular/ui/utils/cn.js.map +1 -0
- package/dist/granular/ui/utils/cva.js +14 -0
- package/dist/granular/ui/utils/cva.js.map +1 -0
- package/dist/granular/ui/utils/mergeRefs.js +11 -0
- package/dist/granular/ui/utils/mergeRefs.js.map +1 -0
- package/dist/granular/vite.svg +1 -0
- package/dist/index.cjs +46 -46
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +1172 -1135
- package/dist/index.js.map +1 -1
- package/dist/react-design-system.css +1 -1
- package/dist/server/index.cjs +23 -23
- package/dist/server/index.cjs.map +1 -1
- package/dist/server/index.js +882 -1179
- package/dist/server/index.js.map +1 -1
- package/dist/ui/components/FilterChips/FilterChips.d.ts +83 -0
- package/dist/ui/components/FilterChips/index.d.ts +2 -0
- package/dist/ui/components/index.d.ts +2 -0
- package/dist/ui/server.d.ts +2 -0
- package/package.json +9 -2
package/README.md
CHANGED
|
@@ -119,6 +119,7 @@ Consumers can import from:
|
|
|
119
119
|
- `@fabio.caffarello/react-design-system` — the default entry. Everything: providers, hooks, all primitives, components, layouts, tokens. The emitted bundle carries `"use client";` so RSC frameworks (Next App Router 15+/16, etc.) accept it from a Server Component without crashing on `React.createContext`. The whole module is treated as a client boundary by the consumer's bundler.
|
|
120
120
|
- `@fabio.caffarello/react-design-system/server` — the opt-in server entry (issue #150). Re-exports only the components whose render tree is safe to evaluate inside a React Server Component: presentational primitives (`Text`, `Skeleton`, `Spinner`, `Progress`, `Chip`, `ErrorMessage`, `Info`), layout (`Container`, `Stack`), and structural / informational components (`Breadcrumb`, `Timeline`, `AutocompleteOption`, `DialogHeader`, `DialogFooter`, `DrawerHeader`, `DrawerFooter`, `HeaderActions`, `HeaderNavigation`, `MenuSeparator`, `NavbarSeparator`, `TableCell`). The bundle carries NO `"use client"` directive, so importing from it in a Server Component does NOT cross a client boundary — useful for SEO-critical / first-paint-critical routes where the shell shouldn't ship JS to the client.
|
|
121
121
|
- `@fabio.caffarello/react-design-system/hooks` — the granular public-hooks entry (issue #203). Re-exports only the public hooks (today: `useScrollSpy`) as a tiny standalone client bundle (<1KB) with every dependency external. Use it when a route's client component needs a hook but nothing else from RDS: importing a hook from the main entry pulls the whole pre-bundled barrel into the route's client JS (+277KB minified measured on a Next 16 route), because the single-file `"use client"` bundle is opaque to the consumer bundler's tree-shaking. The same hooks remain available from the main entry for back-compat.
|
|
122
|
+
- `@fabio.caffarello/react-design-system/granular` — the granular client entry (issue #208). The SAME public surface as the default entry, emitted as a `preserveModules` tree (one module per source file, `"use client"` on every module, all deps external). Use it for leaf component imports on size-critical routes: importing one component from the default entry pulls the whole pre-bundled barrel (+264KB minified measured for `Accordion` on a Next 16 route); the same import from `./granular` ships only that component's module graph (~36KB, 13% of the barrel payload — gated in CI). Keep app-wide setup (`AppProvider`/providers) on the default entry: the single bundle preserves provider initialization order by construction.
|
|
122
123
|
- `@fabio.caffarello/react-design-system/styles` — the bundled CSS. Same stylesheet regardless of which JS entry you import.
|
|
123
124
|
|
|
124
125
|
The JS entries can be mixed in one Server Component — `import { Text } from "…/server"; import { Button } from "…"` is the normal pattern. The server entry is purely additive; consumers who never use it see no behavioural change.
|
|
@@ -142,7 +143,7 @@ export default function Profile() {
|
|
|
142
143
|
}
|
|
143
144
|
```
|
|
144
145
|
|
|
145
|
-
Sub-entries (`/primitives`, `/components`, `/tokens`, `/providers`) were removed in Phase 13d — they had been silently broken for external consumers since v1.0.0 because cross-chunk references to `cva` and other shared utilities failed at runtime. A single main entry collapses that class of bug structurally; tree-shaking still works at the named-export level via any modern bundler. The `./server
|
|
146
|
+
Sub-entries (`/primitives`, `/components`, `/tokens`, `/providers`) were removed in Phase 13d — they had been silently broken for external consumers since v1.0.0 because cross-chunk references to `cva` and other shared utilities failed at runtime. A single main entry collapses that class of bug structurally; tree-shaking still works at the named-export level via any modern bundler. The `./server`, `./hooks`, and `./granular` entries sidestep the same regression by each being their OWN independent Vite build with all third-party deps externalised — no chunks are shared between entries, and `./granular`'s preserveModules layout has no extracted chunks at all (source modules map 1:1 to output files).
|
|
146
147
|
|
|
147
148
|
## Working with Claude Code
|
|
148
149
|
|
|
@@ -0,0 +1,447 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { SIDEBAR_TOKENS as r, getNestedIndentClass as t } from "./ui/tokens/sidebar.js";
|
|
3
|
+
import { SPACING_TOKENS as f, SpacingTokenFactory as p, getSpacing as m, getSpacingClass as x } from "./ui/tokens/spacing.js";
|
|
4
|
+
import { FONT_FAMILY_TOKENS as s, FONT_WEIGHT_TOKENS as d, TYPOGRAPHY_TOKENS as i, TypographyTokenFactory as u, getTypography as n, getTypographyClasses as g, getTypographyLineHeight as S, getTypographySize as C, getTypographySizeFromFontSize as T, getTypographyWeight as b, getTypographyWeightFromFontWeight as v } from "./ui/tokens/typography.js";
|
|
5
|
+
import { BRAND_COLORS as c } from "./ui/tokens/colors/index.js";
|
|
6
|
+
import { BREAKPOINT_TOKENS as R, BreakpointTokenFactory as A, getBreakpoint as O, getMediaQuery as h } from "./ui/tokens/breakpoints.js";
|
|
7
|
+
import { getAnimation as E, getAnimationClass as y, getTransitionClass as F } from "./ui/tokens/animations.js";
|
|
8
|
+
import { getZIndex as L, getZIndexClass as H } from "./ui/tokens/z-index.js";
|
|
9
|
+
import { getOpacity as _, getOpacityClass as k } from "./ui/tokens/opacity.js";
|
|
10
|
+
import { AppProvider as G, useApp as K } from "./ui/providers/AppProvider.js";
|
|
11
|
+
import { useScrollSpy as W } from "./ui/hooks/useScrollSpy.js";
|
|
12
|
+
import { default as q } from "./ui/components/Accordion/Accordion.js";
|
|
13
|
+
import { AlertDialog as V } from "./ui/components/Dialog/AlertDialog.js";
|
|
14
|
+
import { default as Z } from "./ui/components/Autocomplete/Autocomplete.js";
|
|
15
|
+
import { default as j } from "./ui/components/Autocomplete/AutocompleteList.js";
|
|
16
|
+
import { default as X } from "./ui/components/Autocomplete/AutocompleteOption.js";
|
|
17
|
+
import { default as ee } from "./ui/primitives/Avatar/Avatar.js";
|
|
18
|
+
import { default as re } from "./ui/primitives/Badge/Badge.js";
|
|
19
|
+
import { default as ae } from "./ui/components/Breadcrumb/Breadcrumb.js";
|
|
20
|
+
import { Button as pe } from "./ui/primitives/Button/Button.js";
|
|
21
|
+
import { default as xe } from "./ui/components/Card/Card.js";
|
|
22
|
+
import { default as se } from "./ui/primitives/Checkbox/Checkbox.js";
|
|
23
|
+
import { default as ie } from "./ui/primitives/Chip/Chip.js";
|
|
24
|
+
import { default as ne } from "./ui/primitives/Collapsible/Collapsible.js";
|
|
25
|
+
import { default as Se } from "./ui/components/ColorPicker/ColorPicker.js";
|
|
26
|
+
import { default as Te } from "./ui/components/CommandPalette/CommandPalette.js";
|
|
27
|
+
import { default as ve } from "./ui/components/DataGrid/DataGrid.js";
|
|
28
|
+
import { default as ce } from "./ui/components/DatePicker/DatePicker.js";
|
|
29
|
+
import { default as Re } from "./ui/components/Dialog/Dialog.js";
|
|
30
|
+
import { default as Oe } from "./ui/components/Drawer/Drawer.js";
|
|
31
|
+
import { default as De } from "./ui/components/Drawer/DrawerContent.js";
|
|
32
|
+
import { default as ye } from "./ui/components/Drawer/DrawerFooter.js";
|
|
33
|
+
import { default as Ie } from "./ui/components/Drawer/DrawerHeader.js";
|
|
34
|
+
import { default as He } from "./ui/components/Dropdown/Dropdown.js";
|
|
35
|
+
import { default as _e } from "./ui/components/EmptyState/EmptyState.js";
|
|
36
|
+
import { default as Be } from "./ui/primitives/ErrorMessage/ErrorMessage.js";
|
|
37
|
+
import { default as Ke } from "./ui/components/FileUpload/FileUpload.js";
|
|
38
|
+
import { FilterChips as We } from "./ui/components/FilterChips/FilterChips.js";
|
|
39
|
+
import { default as qe } from "./ui/components/Form/Form.js";
|
|
40
|
+
import { Header as Ve, Header as Ue } from "./ui/components/Header/Header.js";
|
|
41
|
+
import { default as Qe } from "./ui/primitives/Info/Info.js";
|
|
42
|
+
import { default as Je } from "./ui/primitives/Input/Input.js";
|
|
43
|
+
import { default as $e } from "./ui/primitives/Label/Label.js";
|
|
44
|
+
import { default as oo } from "./ui/components/LoginBox/LoginBox.js";
|
|
45
|
+
import { default as to } from "./ui/components/Menu/Menu.js";
|
|
46
|
+
import { default as fo } from "./ui/components/Menu/MenuContent.js";
|
|
47
|
+
import { default as mo } from "./ui/components/Menu/MenuItem.js";
|
|
48
|
+
import { default as lo } from "./ui/components/Menu/MenuSeparator.js";
|
|
49
|
+
import { default as io } from "./ui/components/Menu/MenuTrigger.js";
|
|
50
|
+
import { default as no } from "./ui/components/Modal/Modal.js";
|
|
51
|
+
import { default as So } from "./ui/components/MultiSelect/MultiSelect.js";
|
|
52
|
+
import { NavLink as To } from "./ui/primitives/NavLink/NavLink.js";
|
|
53
|
+
import { default as vo } from "./ui/components/SideNavbar/components/Navbar/Navbar.js";
|
|
54
|
+
import { default as co } from "./ui/components/SideNavbar/components/Navbar/NavbarItem.js";
|
|
55
|
+
import { default as Ro } from "./ui/components/SideNavbar/components/Navbar/NavbarSeparator.js";
|
|
56
|
+
import { default as Oo } from "./ui/components/SideNavbar/components/Navbar/NavbarToggle.js";
|
|
57
|
+
import { Navigation as Do, Navigation as Eo } from "./ui/components/Navigation/Navigation.js";
|
|
58
|
+
import { PageHeader as Fo, PageHeader as Io } from "./ui/components/PageHeader/PageHeader.js";
|
|
59
|
+
import { default as Ho } from "./ui/components/Pagination/Pagination.js";
|
|
60
|
+
import { default as _o } from "./ui/components/Popover/Popover.js";
|
|
61
|
+
import { default as Bo } from "./ui/primitives/Progress/Progress.js";
|
|
62
|
+
import { default as Ko } from "./ui/primitives/Radio/Radio.js";
|
|
63
|
+
import { default as Wo } from "./ui/components/Rating/Rating.js";
|
|
64
|
+
import { default as qo } from "./ui/components/SearchInput/SearchInput.js";
|
|
65
|
+
import { default as Vo } from "./ui/primitives/Select/Select.js";
|
|
66
|
+
import { default as Zo } from "./ui/primitives/Separator/Separator.js";
|
|
67
|
+
import { default as jo } from "./ui/components/SideNavbar/SideNavbar.js";
|
|
68
|
+
import { default as Xo } from "./ui/components/SideNavbar/components/SideNavbarBackdrop.js";
|
|
69
|
+
import { default as er } from "./ui/components/SideNavbar/components/SideNavbarResizeHandle.js";
|
|
70
|
+
import { default as rr } from "./ui/components/SideNavbar/components/SideNavbarRoot.js";
|
|
71
|
+
import { default as ar } from "./ui/components/SideNavbar/components/SideNavbarToggle.js";
|
|
72
|
+
import { default as pr } from "./ui/components/SideNavbar/components/Sidebar/Sidebar.js";
|
|
73
|
+
import { default as xr } from "./ui/components/SideNavbar/components/Sidebar/SidebarContent.js";
|
|
74
|
+
import { default as sr } from "./ui/components/SideNavbar/components/Sidebar/SidebarFooter.js";
|
|
75
|
+
import { default as ir } from "./ui/components/SideNavbar/components/Sidebar/SidebarGroup.js";
|
|
76
|
+
import { default as nr } from "./ui/components/SideNavbar/components/Sidebar/SidebarHeader.js";
|
|
77
|
+
import { default as Sr } from "./ui/primitives/Skeleton/Skeleton.js";
|
|
78
|
+
import { default as Tr } from "./ui/primitives/Slider/Slider.js";
|
|
79
|
+
import { default as vr } from "./ui/primitives/Spinner/Spinner.js";
|
|
80
|
+
import { default as cr } from "./ui/components/Stepper/Stepper.js";
|
|
81
|
+
import { default as Rr } from "./ui/primitives/Switch/Switch.js";
|
|
82
|
+
import { default as Or } from "./ui/components/Table/Table.js";
|
|
83
|
+
import { default as Dr } from "./ui/components/Table/TableActions.js";
|
|
84
|
+
import { default as yr } from "./ui/components/Table/TableBody.js";
|
|
85
|
+
import { default as Ir } from "./ui/components/Table/TableCell.js";
|
|
86
|
+
import { default as Hr } from "./ui/components/Table/TableEmptyState.js";
|
|
87
|
+
import { default as _r } from "./ui/components/Table/TableFilters.js";
|
|
88
|
+
import { default as Br } from "./ui/components/Table/TableHeader.js";
|
|
89
|
+
import { default as Kr } from "./ui/components/Table/TableHeaderCell.js";
|
|
90
|
+
import { default as Wr } from "./ui/components/Table/TableHeaderRow.js";
|
|
91
|
+
import { default as qr } from "./ui/components/Table/TablePagination.js";
|
|
92
|
+
import { default as Vr } from "./ui/components/Table/TableRow.js";
|
|
93
|
+
import { default as Zr } from "./ui/components/Tabs/Tabs.js";
|
|
94
|
+
import { default as jr } from "./ui/primitives/Text/Text.js";
|
|
95
|
+
import { default as Xr } from "./ui/primitives/Textarea/Textarea.js";
|
|
96
|
+
import { default as et } from "./ui/components/TimePicker/TimePicker.js";
|
|
97
|
+
import { default as rt } from "./ui/components/Timeline/Timeline.js";
|
|
98
|
+
import { default as at } from "./ui/primitives/Tooltip/Tooltip.js";
|
|
99
|
+
import { AMBER as pt, BLUE as mt, CYAN as xt, EMERALD as lt, FUCHSIA as st, GRAY as dt, GREEN as it, INDIGO as ut, LIME as nt, ORANGE as gt, PINK as St, PRIMITIVE_COLORS as Ct, PURPLE as Tt, RED as bt, ROSE as vt, SKY as Nt, SLATE as ct, TEAL as Pt, VIOLET as Rt, YELLOW as At, getPrimitiveColor as Ot, getPrimitiveColorPalette as ht } from "./ui/tokens/colors/primitives.js";
|
|
100
|
+
import { AvatarGroup as Et } from "./ui/primitives/Avatar/AvatarGroup.js";
|
|
101
|
+
import { BRAND_PRIMARY as Ft, BRAND_SECONDARY as It } from "./ui/tokens/colors/brand.js";
|
|
102
|
+
import { COLOR_SCALES as Ht } from "./ui/tokens/colors/types.js";
|
|
103
|
+
import { ConfigProvider as _t, useConfig as kt } from "./ui/providers/ConfigProvider.js";
|
|
104
|
+
import { DashboardLayout as Gt } from "./ui/components/DashboardLayout/DashboardLayout.js";
|
|
105
|
+
import { DataTablePattern as wt } from "./ui/components/DataTablePattern/DataTablePattern.js";
|
|
106
|
+
import { DatePickerCalendar as Yt } from "./ui/components/DatePicker/DatePickerCalendar.js";
|
|
107
|
+
import { DatePickerInput as zt } from "./ui/components/DatePicker/DatePickerInput.js";
|
|
108
|
+
import { DatePickerProvider as Ut } from "./ui/components/DatePicker/DatePickerProvider.js";
|
|
109
|
+
import { DialogClose as Qt } from "./ui/components/Dialog/DialogClose.js";
|
|
110
|
+
import { DialogContent as Jt } from "./ui/components/Dialog/DialogContent.js";
|
|
111
|
+
import { DialogContext as $t, useDialogContext as ea, useDialogContextOptional as oa } from "./ui/providers/DialogContext.js";
|
|
112
|
+
import { DialogDescription as ta } from "./ui/components/Dialog/DialogDescription.js";
|
|
113
|
+
import { DialogFooter as fa } from "./ui/components/Dialog/DialogFooter.js";
|
|
114
|
+
import { DialogHeader as ma } from "./ui/components/Dialog/DialogHeader.js";
|
|
115
|
+
import { DialogProvider as la } from "./ui/providers/DialogProvider.js";
|
|
116
|
+
import { DialogTitle as da } from "./ui/components/Dialog/DialogTitle.js";
|
|
117
|
+
import { DialogTrigger as ua } from "./ui/components/Dialog/DialogTrigger.js";
|
|
118
|
+
import { FormContext as ga, useFormContext as Sa, useFormContextOptional as Ca } from "./ui/components/Form/FormContext.js";
|
|
119
|
+
import { FormField as ba } from "./ui/components/Form/FormField.js";
|
|
120
|
+
import { FormProvider as Na } from "./ui/components/Form/FormProvider.js";
|
|
121
|
+
import { FormWizardPattern as Pa } from "./ui/components/FormWizardPattern/FormWizardPattern.js";
|
|
122
|
+
import { HeaderActions as Aa } from "./ui/components/Header/components/HeaderActions.js";
|
|
123
|
+
import { HeaderHamburger as ha } from "./ui/components/Header/components/HeaderHamburger.js";
|
|
124
|
+
import { HeaderLogo as Ea } from "./ui/components/Header/components/HeaderLogo.js";
|
|
125
|
+
import { HeaderMobileMenu as Fa } from "./ui/components/Header/components/HeaderMobileMenu.js";
|
|
126
|
+
import { HeaderNavigation as La } from "./ui/components/Header/components/HeaderNavigation.js";
|
|
127
|
+
import { HeaderProvider as Ma, useHeaderContext as _a } from "./ui/components/Header/contexts/HeaderContext.js";
|
|
128
|
+
import { NavbarContext as Ba, useNavbar as Ga, useNavbarRequired as Ka } from "./ui/components/SideNavbar/contexts/NavbarContext.js";
|
|
129
|
+
import { NavbarGroup as Wa } from "./ui/components/SideNavbar/components/Navbar/NavbarGroup.js";
|
|
130
|
+
import { SEMANTIC_COLORS as qa, SEMANTIC_COLORS_DARK as za, SEMANTIC_COLORS_LIGHT as Va, getSemanticColor as Ua, getSemanticColorRole as Za } from "./ui/tokens/colors/semantic.js";
|
|
131
|
+
import { SearchAndFilterPattern as ja } from "./ui/components/SearchAndFilterPattern/SearchAndFilterPattern.js";
|
|
132
|
+
import { SideNavbarConfigContext as Xa, defaultConfigValues as $a, useSideNavbarConfig as ef, useSideNavbarConfigRequired as of } from "./ui/components/SideNavbar/contexts/SideNavbarConfigContext.js";
|
|
133
|
+
import { SideNavbarConfigProvider as tf } from "./ui/components/SideNavbar/providers/SideNavbarConfigProvider.js";
|
|
134
|
+
import { SideNavbarProvider as ff } from "./ui/components/SideNavbar/providers/SideNavbarProvider.js";
|
|
135
|
+
import { SideNavbarStateContext as mf, useSideNavbarState as xf, useSideNavbarStateRequired as lf } from "./ui/components/SideNavbar/contexts/SideNavbarStateContext.js";
|
|
136
|
+
import { SideNavbarStateProvider as df } from "./ui/components/SideNavbar/providers/SideNavbarStateProvider.js";
|
|
137
|
+
import { SideNavbarThemeContext as nf, defaultThemeValues as gf, useSideNavbarTheme as Sf, useSideNavbarThemeRequired as Cf } from "./ui/components/SideNavbar/contexts/SideNavbarThemeContext.js";
|
|
138
|
+
import { SideNavbarThemeProvider as bf } from "./ui/components/SideNavbar/providers/SideNavbarThemeProvider.js";
|
|
139
|
+
import { SideNavbarToggleContext as Nf, useSideNavbarToggleContext as cf, useSideNavbarToggleContextRequired as Pf } from "./ui/components/SideNavbar/contexts/SideNavbarToggleContext.js";
|
|
140
|
+
import { SidebarContext as Af, useSidebar as Of, useSidebarRequired as hf } from "./ui/components/SideNavbar/contexts/SidebarContext.js";
|
|
141
|
+
import { SidebarSlot as Ef } from "./ui/components/SideNavbar/components/Sidebar/SidebarSlot.js";
|
|
142
|
+
import { SidebarSlotContent as Ff } from "./ui/components/SideNavbar/components/Sidebar/SidebarSlotContent.js";
|
|
143
|
+
import { SidebarSlotContext as Lf, useSidebarSlot as Hf, useSidebarSlotRequired as Mf } from "./ui/components/SideNavbar/contexts/SidebarSlotContext.js";
|
|
144
|
+
import { SidebarSlotProvider as kf } from "./ui/components/SideNavbar/providers/SidebarSlotProvider.js";
|
|
145
|
+
import { Stat as Gf } from "./ui/components/Stat/Stat.js";
|
|
146
|
+
import { StatGroup as wf } from "./ui/components/Stat/StatGroup.js";
|
|
147
|
+
import { TableContext as Yf, useTableContext as qf, useTableContextOptional as zf } from "./ui/components/Table/TableContext.js";
|
|
148
|
+
import { TableProvider as Uf } from "./ui/components/Table/TableProvider.js";
|
|
149
|
+
import { TabsContent as Qf } from "./ui/components/Tabs/TabsContent.js";
|
|
150
|
+
import { TabsContext as Jf, useTabsContext as Xf, useTabsContextOptional as $f } from "./ui/components/Tabs/TabsContext.js";
|
|
151
|
+
import { TabsList as op } from "./ui/components/Tabs/TabsList.js";
|
|
152
|
+
import { TabsProvider as tp } from "./ui/components/Tabs/TabsProvider.js";
|
|
153
|
+
import { TabsTrigger as fp } from "./ui/components/Tabs/TabsTrigger.js";
|
|
154
|
+
import { ThemeProvider as mp, useTheme as xp } from "./ui/providers/ThemeProvider.js";
|
|
155
|
+
import { Toast as sp } from "./ui/components/Toast/Toast.js";
|
|
156
|
+
import { ToastContainer as ip } from "./ui/components/Toast/ToastContainer.js";
|
|
157
|
+
import { ToastContext as np, useToastContext as gp, useToastContextOptional as Sp } from "./ui/providers/ToastContext.js";
|
|
158
|
+
import { ToastProvider as Tp } from "./ui/providers/ToastProvider.js";
|
|
159
|
+
import { blendColors as vp, darken as Np, getColor as cp, getColorClass as Pp, getContrastColor as Rp, getFocusColorClass as Ap, getFocusRingClass as Op, getHoverColorClass as hp, getSemanticColorClass as Dp, getSemanticColorValue as Ep, isLightColor as yp, lighten as Fp, withOpacity as Ip } from "./ui/tokens/colors/utils.js";
|
|
160
|
+
import { clampWidth as Hp, parseWidthToPixels as Mp, validateWidthBounds as _p } from "./ui/components/SideNavbar/utils/parseWidth.js";
|
|
161
|
+
import { cn as Bp } from "./ui/utils/cn.js";
|
|
162
|
+
import { formatKeyboardShortcut as Kp, parseKeyboardShortcut as wp } from "./ui/components/SideNavbar/utils/parseKeyboardShortcut.js";
|
|
163
|
+
import { useColumnResizing as Yp } from "./ui/components/Table/useColumnResizing.js";
|
|
164
|
+
import { useFocusManagement as zp } from "./ui/components/SideNavbar/hooks/useFocusManagement.js";
|
|
165
|
+
import { useFormFieldArray as Up } from "./ui/components/Form/useFormFieldArray.js";
|
|
166
|
+
import { useGroupState as Qp } from "./ui/components/SideNavbar/hooks/useGroupState.js";
|
|
167
|
+
import { useKeyboardShortcut as Jp } from "./ui/components/SideNavbar/hooks/useKeyboardShortcut.js";
|
|
168
|
+
import { useNavLink as $p } from "./ui/primitives/NavLink/hooks/useNavLink.js";
|
|
169
|
+
import { useResize as om } from "./ui/components/SideNavbar/hooks/useResize.js";
|
|
170
|
+
import { useResponsiveSidebar as tm } from "./ui/components/SideNavbar/hooks/useResponsiveSidebar.js";
|
|
171
|
+
import { useSideNavbarCombined as fm } from "./ui/components/SideNavbar/hooks/useSideNavbar.js";
|
|
172
|
+
import { useSideNavbarContent as mm } from "./ui/components/SideNavbar/hooks/useSideNavbarContent.js";
|
|
173
|
+
import { useSideNavbarNavigation as lm } from "./ui/components/SideNavbar/hooks/useSideNavbarNavigation.js";
|
|
174
|
+
import { useToast as dm } from "./ui/components/Toast/useToast.js";
|
|
175
|
+
import { useVirtualScrolling as um } from "./ui/components/Table/useVirtualScrolling.js";
|
|
176
|
+
export {
|
|
177
|
+
pt as AMBER,
|
|
178
|
+
q as Accordion,
|
|
179
|
+
V as AlertDialog,
|
|
180
|
+
G as AppProvider,
|
|
181
|
+
Z as Autocomplete,
|
|
182
|
+
j as AutocompleteList,
|
|
183
|
+
X as AutocompleteOption,
|
|
184
|
+
ee as Avatar,
|
|
185
|
+
Et as AvatarGroup,
|
|
186
|
+
mt as BLUE,
|
|
187
|
+
c as BRAND_COLORS,
|
|
188
|
+
Ft as BRAND_PRIMARY,
|
|
189
|
+
It as BRAND_SECONDARY,
|
|
190
|
+
R as BREAKPOINT_TOKENS,
|
|
191
|
+
re as Badge,
|
|
192
|
+
ae as Breadcrumb,
|
|
193
|
+
A as BreakpointTokenFactory,
|
|
194
|
+
pe as Button,
|
|
195
|
+
Ht as COLOR_SCALES,
|
|
196
|
+
xt as CYAN,
|
|
197
|
+
xe as Card,
|
|
198
|
+
se as Checkbox,
|
|
199
|
+
ie as Chip,
|
|
200
|
+
ne as Collapsible,
|
|
201
|
+
Se as ColorPicker,
|
|
202
|
+
Te as CommandPalette,
|
|
203
|
+
_t as ConfigProvider,
|
|
204
|
+
Gt as DashboardLayout,
|
|
205
|
+
ve as DataGrid,
|
|
206
|
+
wt as DataTablePattern,
|
|
207
|
+
ce as DatePicker,
|
|
208
|
+
Yt as DatePickerCalendar,
|
|
209
|
+
zt as DatePickerInput,
|
|
210
|
+
Ut as DatePickerProvider,
|
|
211
|
+
Re as Dialog,
|
|
212
|
+
Qt as DialogClose,
|
|
213
|
+
Jt as DialogContent,
|
|
214
|
+
$t as DialogContext,
|
|
215
|
+
ta as DialogDescription,
|
|
216
|
+
fa as DialogFooter,
|
|
217
|
+
ma as DialogHeader,
|
|
218
|
+
la as DialogProvider,
|
|
219
|
+
da as DialogTitle,
|
|
220
|
+
ua as DialogTrigger,
|
|
221
|
+
Oe as Drawer,
|
|
222
|
+
De as DrawerContent,
|
|
223
|
+
ye as DrawerFooter,
|
|
224
|
+
Ie as DrawerHeader,
|
|
225
|
+
He as Dropdown,
|
|
226
|
+
lt as EMERALD,
|
|
227
|
+
_e as EmptyState,
|
|
228
|
+
Be as ErrorMessage,
|
|
229
|
+
s as FONT_FAMILY_TOKENS,
|
|
230
|
+
d as FONT_WEIGHT_TOKENS,
|
|
231
|
+
st as FUCHSIA,
|
|
232
|
+
Ke as FileUpload,
|
|
233
|
+
We as FilterChips,
|
|
234
|
+
qe as Form,
|
|
235
|
+
ga as FormContext,
|
|
236
|
+
ba as FormField,
|
|
237
|
+
Na as FormProvider,
|
|
238
|
+
Pa as FormWizardPattern,
|
|
239
|
+
dt as GRAY,
|
|
240
|
+
it as GREEN,
|
|
241
|
+
Ve as Header,
|
|
242
|
+
Aa as HeaderActions,
|
|
243
|
+
Ue as HeaderComponent,
|
|
244
|
+
ha as HeaderHamburger,
|
|
245
|
+
Ea as HeaderLogo,
|
|
246
|
+
Fa as HeaderMobileMenu,
|
|
247
|
+
La as HeaderNavigation,
|
|
248
|
+
Ma as HeaderProvider,
|
|
249
|
+
ut as INDIGO,
|
|
250
|
+
Qe as Info,
|
|
251
|
+
Je as Input,
|
|
252
|
+
nt as LIME,
|
|
253
|
+
$e as Label,
|
|
254
|
+
oo as LoginBox,
|
|
255
|
+
to as Menu,
|
|
256
|
+
fo as MenuContent,
|
|
257
|
+
mo as MenuItem,
|
|
258
|
+
lo as MenuSeparator,
|
|
259
|
+
io as MenuTrigger,
|
|
260
|
+
no as Modal,
|
|
261
|
+
So as MultiSelect,
|
|
262
|
+
To as NavLink,
|
|
263
|
+
vo as Navbar,
|
|
264
|
+
Ba as NavbarContext,
|
|
265
|
+
Wa as NavbarGroup,
|
|
266
|
+
co as NavbarItem,
|
|
267
|
+
Ro as NavbarSeparator,
|
|
268
|
+
Oo as NavbarToggle,
|
|
269
|
+
Do as Navigation,
|
|
270
|
+
Eo as NavigationComponent,
|
|
271
|
+
gt as ORANGE,
|
|
272
|
+
St as PINK,
|
|
273
|
+
Ct as PRIMITIVE_COLORS,
|
|
274
|
+
Tt as PURPLE,
|
|
275
|
+
Fo as PageHeader,
|
|
276
|
+
Io as PageHeaderComponent,
|
|
277
|
+
Ho as Pagination,
|
|
278
|
+
_o as Popover,
|
|
279
|
+
Bo as Progress,
|
|
280
|
+
bt as RED,
|
|
281
|
+
vt as ROSE,
|
|
282
|
+
Ko as Radio,
|
|
283
|
+
Wo as Rating,
|
|
284
|
+
qa as SEMANTIC_COLORS,
|
|
285
|
+
za as SEMANTIC_COLORS_DARK,
|
|
286
|
+
Va as SEMANTIC_COLORS_LIGHT,
|
|
287
|
+
r as SIDEBAR_TOKENS,
|
|
288
|
+
Nt as SKY,
|
|
289
|
+
ct as SLATE,
|
|
290
|
+
f as SPACING_TOKENS,
|
|
291
|
+
ja as SearchAndFilterPattern,
|
|
292
|
+
qo as SearchInput,
|
|
293
|
+
Vo as Select,
|
|
294
|
+
Zo as Separator,
|
|
295
|
+
jo as SideNavbar,
|
|
296
|
+
Xo as SideNavbarBackdrop,
|
|
297
|
+
Xa as SideNavbarConfigContext,
|
|
298
|
+
tf as SideNavbarConfigProvider,
|
|
299
|
+
ff as SideNavbarProvider,
|
|
300
|
+
er as SideNavbarResizeHandle,
|
|
301
|
+
rr as SideNavbarRoot,
|
|
302
|
+
mf as SideNavbarStateContext,
|
|
303
|
+
df as SideNavbarStateProvider,
|
|
304
|
+
nf as SideNavbarThemeContext,
|
|
305
|
+
bf as SideNavbarThemeProvider,
|
|
306
|
+
ar as SideNavbarToggle,
|
|
307
|
+
Nf as SideNavbarToggleContext,
|
|
308
|
+
pr as Sidebar,
|
|
309
|
+
xr as SidebarContent,
|
|
310
|
+
Af as SidebarContext,
|
|
311
|
+
sr as SidebarFooter,
|
|
312
|
+
ir as SidebarGroup,
|
|
313
|
+
nr as SidebarHeader,
|
|
314
|
+
Ef as SidebarSlot,
|
|
315
|
+
Ff as SidebarSlotContent,
|
|
316
|
+
Lf as SidebarSlotContext,
|
|
317
|
+
kf as SidebarSlotProvider,
|
|
318
|
+
Sr as Skeleton,
|
|
319
|
+
Tr as Slider,
|
|
320
|
+
p as SpacingTokenFactory,
|
|
321
|
+
vr as Spinner,
|
|
322
|
+
Gf as Stat,
|
|
323
|
+
wf as StatGroup,
|
|
324
|
+
cr as Stepper,
|
|
325
|
+
Rr as Switch,
|
|
326
|
+
Pt as TEAL,
|
|
327
|
+
i as TYPOGRAPHY_TOKENS,
|
|
328
|
+
Or as Table,
|
|
329
|
+
Dr as TableActions,
|
|
330
|
+
yr as TableBody,
|
|
331
|
+
Ir as TableCell,
|
|
332
|
+
Yf as TableContext,
|
|
333
|
+
Hr as TableEmptyState,
|
|
334
|
+
_r as TableFilters,
|
|
335
|
+
Br as TableHeader,
|
|
336
|
+
Kr as TableHeaderCell,
|
|
337
|
+
Wr as TableHeaderRow,
|
|
338
|
+
qr as TablePagination,
|
|
339
|
+
Uf as TableProvider,
|
|
340
|
+
Vr as TableRow,
|
|
341
|
+
Zr as Tabs,
|
|
342
|
+
Qf as TabsContent,
|
|
343
|
+
Jf as TabsContext,
|
|
344
|
+
op as TabsList,
|
|
345
|
+
tp as TabsProvider,
|
|
346
|
+
fp as TabsTrigger,
|
|
347
|
+
jr as Text,
|
|
348
|
+
Xr as Textarea,
|
|
349
|
+
mp as ThemeProvider,
|
|
350
|
+
et as TimePicker,
|
|
351
|
+
rt as Timeline,
|
|
352
|
+
sp as Toast,
|
|
353
|
+
ip as ToastContainer,
|
|
354
|
+
np as ToastContext,
|
|
355
|
+
Tp as ToastProvider,
|
|
356
|
+
at as Tooltip,
|
|
357
|
+
u as TypographyTokenFactory,
|
|
358
|
+
Rt as VIOLET,
|
|
359
|
+
At as YELLOW,
|
|
360
|
+
vp as blendColors,
|
|
361
|
+
Hp as clampWidth,
|
|
362
|
+
Bp as cn,
|
|
363
|
+
Np as darken,
|
|
364
|
+
$a as defaultConfigValues,
|
|
365
|
+
gf as defaultThemeValues,
|
|
366
|
+
Kp as formatKeyboardShortcut,
|
|
367
|
+
E as getAnimation,
|
|
368
|
+
y as getAnimationClass,
|
|
369
|
+
O as getBreakpoint,
|
|
370
|
+
cp as getColor,
|
|
371
|
+
Pp as getColorClass,
|
|
372
|
+
Rp as getContrastColor,
|
|
373
|
+
Ap as getFocusColorClass,
|
|
374
|
+
Op as getFocusRingClass,
|
|
375
|
+
hp as getHoverColorClass,
|
|
376
|
+
h as getMediaQuery,
|
|
377
|
+
t as getNestedIndentClass,
|
|
378
|
+
_ as getOpacity,
|
|
379
|
+
k as getOpacityClass,
|
|
380
|
+
Ot as getPrimitiveColor,
|
|
381
|
+
ht as getPrimitiveColorPalette,
|
|
382
|
+
Ua as getSemanticColor,
|
|
383
|
+
Dp as getSemanticColorClass,
|
|
384
|
+
Za as getSemanticColorRole,
|
|
385
|
+
Ep as getSemanticColorValue,
|
|
386
|
+
m as getSpacing,
|
|
387
|
+
x as getSpacingClass,
|
|
388
|
+
F as getTransitionClass,
|
|
389
|
+
n as getTypography,
|
|
390
|
+
g as getTypographyClasses,
|
|
391
|
+
S as getTypographyLineHeight,
|
|
392
|
+
C as getTypographySize,
|
|
393
|
+
T as getTypographySizeFromFontSize,
|
|
394
|
+
b as getTypographyWeight,
|
|
395
|
+
v as getTypographyWeightFromFontWeight,
|
|
396
|
+
L as getZIndex,
|
|
397
|
+
H as getZIndexClass,
|
|
398
|
+
yp as isLightColor,
|
|
399
|
+
Fp as lighten,
|
|
400
|
+
wp as parseKeyboardShortcut,
|
|
401
|
+
Mp as parseWidthToPixels,
|
|
402
|
+
K as useApp,
|
|
403
|
+
Yp as useColumnResizing,
|
|
404
|
+
kt as useConfig,
|
|
405
|
+
ea as useDialogContext,
|
|
406
|
+
oa as useDialogContextOptional,
|
|
407
|
+
zp as useFocusManagement,
|
|
408
|
+
Sa as useFormContext,
|
|
409
|
+
Ca as useFormContextOptional,
|
|
410
|
+
Up as useFormFieldArray,
|
|
411
|
+
Qp as useGroupState,
|
|
412
|
+
_a as useHeaderContext,
|
|
413
|
+
Jp as useKeyboardShortcut,
|
|
414
|
+
$p as useNavLink,
|
|
415
|
+
Ga as useNavbar,
|
|
416
|
+
Ka as useNavbarRequired,
|
|
417
|
+
om as useResize,
|
|
418
|
+
tm as useResponsiveSidebar,
|
|
419
|
+
W as useScrollSpy,
|
|
420
|
+
fm as useSideNavbarCombined,
|
|
421
|
+
ef as useSideNavbarConfig,
|
|
422
|
+
of as useSideNavbarConfigRequired,
|
|
423
|
+
mm as useSideNavbarContent,
|
|
424
|
+
lm as useSideNavbarNavigation,
|
|
425
|
+
xf as useSideNavbarState,
|
|
426
|
+
lf as useSideNavbarStateRequired,
|
|
427
|
+
Sf as useSideNavbarTheme,
|
|
428
|
+
Cf as useSideNavbarThemeRequired,
|
|
429
|
+
cf as useSideNavbarToggleContext,
|
|
430
|
+
Pf as useSideNavbarToggleContextRequired,
|
|
431
|
+
Of as useSidebar,
|
|
432
|
+
hf as useSidebarRequired,
|
|
433
|
+
Hf as useSidebarSlot,
|
|
434
|
+
Mf as useSidebarSlotRequired,
|
|
435
|
+
qf as useTableContext,
|
|
436
|
+
zf as useTableContextOptional,
|
|
437
|
+
Xf as useTabsContext,
|
|
438
|
+
$f as useTabsContextOptional,
|
|
439
|
+
xp as useTheme,
|
|
440
|
+
dm as useToast,
|
|
441
|
+
gp as useToastContext,
|
|
442
|
+
Sp as useToastContextOptional,
|
|
443
|
+
um as useVirtualScrolling,
|
|
444
|
+
_p as validateWidthBounds,
|
|
445
|
+
Ip as withOpacity
|
|
446
|
+
};
|
|
447
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsx as i, jsxs as m } from "react/jsx-runtime";
|
|
3
|
+
import { useState as h } from "react";
|
|
4
|
+
import { ChevronDown as v } from "lucide-react";
|
|
5
|
+
import { getSpacingClass as o } from "../../tokens/spacing.js";
|
|
6
|
+
import { getAnimationClass as l } from "../../tokens/animations.js";
|
|
7
|
+
import { getTypographyClasses as x } from "../../tokens/typography.js";
|
|
8
|
+
import { getRadiusClass as N } from "../../tokens/radius.js";
|
|
9
|
+
import { cn as t } from "../../utils/cn.js";
|
|
10
|
+
function k({
|
|
11
|
+
items: f,
|
|
12
|
+
type: p = "single",
|
|
13
|
+
defaultOpen: a,
|
|
14
|
+
onValueChange: c,
|
|
15
|
+
className: u = ""
|
|
16
|
+
}) {
|
|
17
|
+
const g = () => a === void 0 ? [] : Array.isArray(a) ? a : [a], [n, b] = h(g), y = (s) => {
|
|
18
|
+
var e;
|
|
19
|
+
if ((e = f.find((d) => d.id === s)) != null && e.disabled) return;
|
|
20
|
+
let r;
|
|
21
|
+
p === "single" ? r = n.includes(s) ? [] : [s] : r = n.includes(s) ? n.filter((d) => d !== s) : [...n, s], b(r), c == null || c(p === "single" ? r[0] || "" : r);
|
|
22
|
+
};
|
|
23
|
+
return /* @__PURE__ */ i("div", { className: `${o("xs", "space-y")} ${u}`, children: f.map((s) => {
|
|
24
|
+
const r = n.includes(s.id), e = s.disabled;
|
|
25
|
+
return /* @__PURE__ */ m(
|
|
26
|
+
"div",
|
|
27
|
+
{
|
|
28
|
+
className: t(
|
|
29
|
+
"border border-line-default",
|
|
30
|
+
N("md"),
|
|
31
|
+
"overflow-hidden",
|
|
32
|
+
s.className
|
|
33
|
+
),
|
|
34
|
+
children: [
|
|
35
|
+
/* @__PURE__ */ m(
|
|
36
|
+
"button",
|
|
37
|
+
{
|
|
38
|
+
type: "button",
|
|
39
|
+
onClick: () => y(s.id),
|
|
40
|
+
disabled: e,
|
|
41
|
+
className: t(
|
|
42
|
+
"w-full flex items-center justify-between",
|
|
43
|
+
o("base", "px"),
|
|
44
|
+
o("md", "py"),
|
|
45
|
+
x("label"),
|
|
46
|
+
"text-left text-fg-primary bg-surface-base hover:bg-surface-hover",
|
|
47
|
+
"focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-line-focus",
|
|
48
|
+
l("base"),
|
|
49
|
+
e ? "opacity-50 cursor-not-allowed" : "cursor-pointer",
|
|
50
|
+
s.triggerClassName
|
|
51
|
+
),
|
|
52
|
+
"aria-expanded": r,
|
|
53
|
+
"aria-controls": `accordion-content-${s.id}`,
|
|
54
|
+
"aria-disabled": e,
|
|
55
|
+
children: [
|
|
56
|
+
/* @__PURE__ */ i("span", { children: s.title }),
|
|
57
|
+
/* @__PURE__ */ i(
|
|
58
|
+
v,
|
|
59
|
+
{
|
|
60
|
+
className: `
|
|
61
|
+
${o("sm", "ml")}
|
|
62
|
+
${l("base")}
|
|
63
|
+
${r ? "transform rotate-180" : ""}
|
|
64
|
+
${e ? "opacity-50" : ""}
|
|
65
|
+
`,
|
|
66
|
+
"aria-hidden": "true"
|
|
67
|
+
}
|
|
68
|
+
)
|
|
69
|
+
]
|
|
70
|
+
}
|
|
71
|
+
),
|
|
72
|
+
/* @__PURE__ */ i(
|
|
73
|
+
"div",
|
|
74
|
+
{
|
|
75
|
+
id: `accordion-content-${s.id}`,
|
|
76
|
+
className: t(
|
|
77
|
+
"grid",
|
|
78
|
+
l("base"),
|
|
79
|
+
r ? "grid-rows-[1fr] opacity-100" : "grid-rows-[0fr] opacity-0"
|
|
80
|
+
),
|
|
81
|
+
"aria-hidden": !r,
|
|
82
|
+
children: /* @__PURE__ */ i("div", { className: "min-h-0 overflow-hidden", children: /* @__PURE__ */ i(
|
|
83
|
+
"div",
|
|
84
|
+
{
|
|
85
|
+
className: t(
|
|
86
|
+
o("base", "px"),
|
|
87
|
+
o("md", "py"),
|
|
88
|
+
"text-fg-secondary",
|
|
89
|
+
s.contentClassName
|
|
90
|
+
),
|
|
91
|
+
children: s.content
|
|
92
|
+
}
|
|
93
|
+
) })
|
|
94
|
+
}
|
|
95
|
+
)
|
|
96
|
+
]
|
|
97
|
+
},
|
|
98
|
+
s.id
|
|
99
|
+
);
|
|
100
|
+
}) });
|
|
101
|
+
}
|
|
102
|
+
export {
|
|
103
|
+
k as default
|
|
104
|
+
};
|
|
105
|
+
//# sourceMappingURL=Accordion.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Accordion.js","sources":["../../../../../src/ui/components/Accordion/Accordion.tsx"],"sourcesContent":["\"use client\";\n\nimport { useState, type ReactNode } from \"react\";\nimport { ChevronDown } from \"lucide-react\";\nimport { getSpacingClass } from \"../../tokens/spacing\";\nimport { getAnimationClass } from \"../../tokens/animations\";\nimport { getTypographyClasses } from \"../../tokens/typography\";\nimport { getRadiusClass } from \"../../tokens/radius\";\nimport { cn } from \"../../utils/cn\";\n\nexport type AccordionType = \"single\" | \"multiple\";\n\nexport interface AccordionItem {\n id: string;\n title: string;\n content: ReactNode;\n disabled?: boolean;\n /** Extra classes for the item wrapper (the bordered card). Merged after the defaults, so conflicting Tailwind classes win. */\n className?: string;\n /** Extra classes for the header button — overrides the default `label` typography (e.g. `font-semibold text-base`). */\n triggerClassName?: string;\n /** Extra classes for the content padding wrapper inside the panel. */\n contentClassName?: string;\n}\n\nexport interface AccordionProps {\n items: AccordionItem[];\n type?: AccordionType;\n defaultOpen?: string | string[];\n onValueChange?: (value: string | string[]) => void;\n className?: string;\n}\n\n/**\n * Accordion Component\n *\n * A collapsible content component that can display multiple items.\n * Supports single and multiple selection modes.\n *\n * Open panels animate via `grid-template-rows: 0fr → 1fr`, so content of\n * any height expands fully — there is no max-height clamp (issue #202).\n *\n * @example\n * ```tsx\n * <Accordion\n * type=\"single\"\n * items={[\n * { id: '1', title: 'Item 1', content: 'Content 1' },\n * { id: '2', title: 'Item 2', content: 'Content 2' },\n * ]}\n * />\n * ```\n */\nexport default function Accordion({\n items,\n type = \"single\",\n defaultOpen,\n onValueChange,\n className = \"\",\n}: AccordionProps) {\n const getInitialOpen = (): string[] => {\n if (defaultOpen === undefined) return [];\n return Array.isArray(defaultOpen) ? defaultOpen : [defaultOpen];\n };\n\n const [openItems, setOpenItems] = useState<string[]>(getInitialOpen);\n\n const handleToggle = (itemId: string) => {\n if (items.find((item) => item.id === itemId)?.disabled) return;\n\n let newOpenItems: string[];\n\n if (type === \"single\") {\n newOpenItems = openItems.includes(itemId) ? [] : [itemId];\n } else {\n newOpenItems = openItems.includes(itemId)\n ? openItems.filter((id) => id !== itemId)\n : [...openItems, itemId];\n }\n\n setOpenItems(newOpenItems);\n onValueChange?.(type === \"single\" ? newOpenItems[0] || \"\" : newOpenItems);\n };\n\n return (\n <div className={`${getSpacingClass(\"xs\", \"space-y\")} ${className}`}>\n {items.map((item) => {\n const isOpen = openItems.includes(item.id);\n const isDisabled = item.disabled;\n\n return (\n <div\n key={item.id}\n className={cn(\n \"border border-line-default\",\n getRadiusClass(\"md\"),\n \"overflow-hidden\",\n item.className,\n )}\n >\n <button\n type=\"button\"\n onClick={() => handleToggle(item.id)}\n disabled={isDisabled}\n className={cn(\n \"w-full flex items-center justify-between\",\n getSpacingClass(\"base\", \"px\"),\n getSpacingClass(\"md\", \"py\"),\n getTypographyClasses(\"label\"),\n \"text-left text-fg-primary bg-surface-base hover:bg-surface-hover\",\n \"focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-line-focus\",\n getAnimationClass(\"base\"),\n isDisabled ? \"opacity-50 cursor-not-allowed\" : \"cursor-pointer\",\n item.triggerClassName,\n )}\n aria-expanded={isOpen}\n aria-controls={`accordion-content-${item.id}`}\n aria-disabled={isDisabled}\n >\n <span>{item.title}</span>\n <ChevronDown\n className={`\n ${getSpacingClass(\"sm\", \"ml\")}\n ${getAnimationClass(\"base\")}\n ${isOpen ? \"transform rotate-180\" : \"\"}\n ${isDisabled ? \"opacity-50\" : \"\"}\n `}\n aria-hidden=\"true\"\n />\n </button>\n {/* grid-rows 0fr→1fr animates open/close at any content height\n (no max-height clamp — issue #202). The inner min-h-0 +\n overflow-hidden row is what lets the fraction collapse. */}\n <div\n id={`accordion-content-${item.id}`}\n className={cn(\n \"grid\",\n getAnimationClass(\"base\"),\n isOpen\n ? \"grid-rows-[1fr] opacity-100\"\n : \"grid-rows-[0fr] opacity-0\",\n )}\n aria-hidden={!isOpen}\n >\n <div className=\"min-h-0 overflow-hidden\">\n <div\n className={cn(\n getSpacingClass(\"base\", \"px\"),\n getSpacingClass(\"md\", \"py\"),\n \"text-fg-secondary\",\n item.contentClassName,\n )}\n >\n {item.content}\n </div>\n </div>\n </div>\n </div>\n );\n })}\n </div>\n );\n}\n"],"names":["Accordion","items","type","defaultOpen","onValueChange","className","getInitialOpen","openItems","setOpenItems","useState","handleToggle","itemId","_a","item","newOpenItems","id","jsx","getSpacingClass","isOpen","isDisabled","jsxs","cn","getRadiusClass","getTypographyClasses","getAnimationClass","ChevronDown"],"mappings":";;;;;;;;;AAqDA,SAAwBA,EAAU;AAAA,EAChC,OAAAC;AAAA,EACA,MAAAC,IAAO;AAAA,EACP,aAAAC;AAAA,EACA,eAAAC;AAAA,EACA,WAAAC,IAAY;AACd,GAAmB;AACjB,QAAMC,IAAiB,MACjBH,MAAgB,SAAkB,CAAA,IAC/B,MAAM,QAAQA,CAAW,IAAIA,IAAc,CAACA,CAAW,GAG1D,CAACI,GAAWC,CAAY,IAAIC,EAAmBH,CAAc,GAE7DI,IAAe,CAACC,MAAmB;;AACvC,SAAIC,IAAAX,EAAM,KAAK,CAACY,MAASA,EAAK,OAAOF,CAAM,MAAvC,QAAAC,EAA0C,SAAU;AAExD,QAAIE;AAEJ,IAAIZ,MAAS,WACXY,IAAeP,EAAU,SAASI,CAAM,IAAI,CAAA,IAAK,CAACA,CAAM,IAExDG,IAAeP,EAAU,SAASI,CAAM,IACpCJ,EAAU,OAAO,CAACQ,MAAOA,MAAOJ,CAAM,IACtC,CAAC,GAAGJ,GAAWI,CAAM,GAG3BH,EAAaM,CAAY,GACzBV,KAAA,QAAAA,EAAgBF,MAAS,WAAWY,EAAa,CAAC,KAAK,KAAKA;AAAA,EAC9D;AAEA,SACE,gBAAAE,EAAC,OAAA,EAAI,WAAW,GAAGC,EAAgB,MAAM,SAAS,CAAC,IAAIZ,CAAS,IAC7D,UAAAJ,EAAM,IAAI,CAACY,MAAS;AACnB,UAAMK,IAASX,EAAU,SAASM,EAAK,EAAE,GACnCM,IAAaN,EAAK;AAExB,WACE,gBAAAO;AAAA,MAAC;AAAA,MAAA;AAAA,QAEC,WAAWC;AAAA,UACT;AAAA,UACAC,EAAe,IAAI;AAAA,UACnB;AAAA,UACAT,EAAK;AAAA,QAAA;AAAA,QAGP,UAAA;AAAA,UAAA,gBAAAO;AAAA,YAAC;AAAA,YAAA;AAAA,cACC,MAAK;AAAA,cACL,SAAS,MAAMV,EAAaG,EAAK,EAAE;AAAA,cACnC,UAAUM;AAAA,cACV,WAAWE;AAAA,gBACT;AAAA,gBACAJ,EAAgB,QAAQ,IAAI;AAAA,gBAC5BA,EAAgB,MAAM,IAAI;AAAA,gBAC1BM,EAAqB,OAAO;AAAA,gBAC5B;AAAA,gBACA;AAAA,gBACAC,EAAkB,MAAM;AAAA,gBACxBL,IAAa,kCAAkC;AAAA,gBAC/CN,EAAK;AAAA,cAAA;AAAA,cAEP,iBAAeK;AAAA,cACf,iBAAe,qBAAqBL,EAAK,EAAE;AAAA,cAC3C,iBAAeM;AAAA,cAEf,UAAA;AAAA,gBAAA,gBAAAH,EAAC,QAAA,EAAM,YAAK,MAAA,CAAM;AAAA,gBAClB,gBAAAA;AAAA,kBAACS;AAAA,kBAAA;AAAA,oBACC,WAAW;AAAA,oBACPR,EAAgB,MAAM,IAAI,CAAC;AAAA,oBAC3BO,EAAkB,MAAM,CAAC;AAAA,oBACzBN,IAAS,yBAAyB,EAAE;AAAA,oBACpCC,IAAa,eAAe,EAAE;AAAA;AAAA,oBAElC,eAAY;AAAA,kBAAA;AAAA,gBAAA;AAAA,cACd;AAAA,YAAA;AAAA,UAAA;AAAA,UAKF,gBAAAH;AAAA,YAAC;AAAA,YAAA;AAAA,cACC,IAAI,qBAAqBH,EAAK,EAAE;AAAA,cAChC,WAAWQ;AAAA,gBACT;AAAA,gBACAG,EAAkB,MAAM;AAAA,gBACxBN,IACI,gCACA;AAAA,cAAA;AAAA,cAEN,eAAa,CAACA;AAAA,cAEd,UAAA,gBAAAF,EAAC,OAAA,EAAI,WAAU,2BACb,UAAA,gBAAAA;AAAA,gBAAC;AAAA,gBAAA;AAAA,kBACC,WAAWK;AAAA,oBACTJ,EAAgB,QAAQ,IAAI;AAAA,oBAC5BA,EAAgB,MAAM,IAAI;AAAA,oBAC1B;AAAA,oBACAJ,EAAK;AAAA,kBAAA;AAAA,kBAGN,UAAAA,EAAK;AAAA,gBAAA;AAAA,cAAA,EACR,CACF;AAAA,YAAA;AAAA,UAAA;AAAA,QACF;AAAA,MAAA;AAAA,MAhEKA,EAAK;AAAA,IAAA;AAAA,EAmEhB,CAAC,EAAA,CACH;AAEJ;"}
|