@erxes/ui 4.0.0-v2.0 → 4.0.0-v2.10
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/AGENTS.md +58 -0
- package/CATALOG.md +251 -0
- package/README.md +31 -8
- package/dist/base.css +17 -4
- package/dist/components/accordion.d.ts +7 -7
- package/dist/components/accordion.js +9 -13
- package/dist/components/alert-dialog.d.ts +16 -11
- package/dist/components/alert-dialog.js +30 -29
- package/dist/components/alert.d.ts +1 -0
- package/dist/components/alert.js +3 -2
- package/dist/components/avatar.d.ts +9 -5
- package/dist/components/avatar.js +31 -19
- package/dist/components/background-gradient-animation.d.ts +5 -11
- package/dist/components/background-gradient-animation.js +24 -50
- package/dist/components/badge.d.ts +6 -2
- package/dist/components/badge.js +38 -21
- package/dist/components/breadcrumb.d.ts +7 -4
- package/dist/components/breadcrumb.js +19 -14
- package/dist/components/button.d.ts +20 -7
- package/dist/components/button.js +50 -23
- package/dist/components/calendar.d.ts +5 -0
- package/dist/components/calendar.js +5 -1
- package/dist/components/card.d.ts +1 -0
- package/dist/components/card.js +2 -1
- package/dist/components/chart-config.d.ts +7 -18
- package/dist/components/chart-config.js +1 -6
- package/dist/components/charts.d.ts +7 -1
- package/dist/components/charts.js +31 -30
- package/dist/components/checkbox.d.ts +3 -3
- package/dist/components/checkbox.js +5 -6
- package/dist/components/choicebox-group.d.ts +2 -1
- package/dist/components/choicebox-group.js +6 -9
- package/dist/components/collapsible.d.ts +6 -9
- package/dist/components/collapsible.js +9 -25
- package/dist/components/color-picker.d.ts +1 -0
- package/dist/components/color-picker.js +21 -13
- package/dist/components/combobox.d.ts +11 -6
- package/dist/components/combobox.js +27 -18
- package/dist/components/command-bar.d.ts +4 -0
- package/dist/components/command-bar.js +26 -19
- package/dist/components/command.d.ts +22 -8
- package/dist/components/command.js +66 -26
- package/dist/components/context-menu.d.ts +18 -29
- package/dist/components/context-menu.js +21 -66
- package/dist/components/copy-text.d.ts +1 -0
- package/dist/components/copy-text.js +8 -11
- package/dist/components/date-picker-value.d.ts +5 -9
- package/dist/components/date-picker-value.js +15 -34
- package/dist/components/date-picker.d.ts +4 -4
- package/dist/components/date-picker.js +30 -25
- package/dist/components/date-text-input.d.ts +2 -4
- package/dist/components/date-text-input.js +14 -12
- package/dist/components/date-time-input.d.ts +12 -0
- package/dist/components/date-time-input.js +21 -0
- package/dist/components/dialog.d.ts +21 -12
- package/dist/components/dialog.js +40 -32
- package/dist/components/drag-handle.d.ts +3 -2
- package/dist/components/drag-handle.js +1 -1
- package/dist/components/dropdown-menu.d.ts +36 -16
- package/dist/components/dropdown-menu.js +79 -37
- package/dist/components/empty.d.ts +6 -1
- package/dist/components/empty.js +26 -3
- package/dist/components/form.d.ts +21 -8
- package/dist/components/form.js +42 -19
- package/dist/components/hover-card.d.ts +7 -5
- package/dist/components/hover-card.js +19 -9
- package/dist/components/icon-tip.d.ts +7 -0
- package/dist/components/icon-tip.js +16 -0
- package/dist/components/info-card.d.ts +4 -0
- package/dist/components/info-card.js +9 -6
- package/dist/components/input-group.d.ts +23 -0
- package/dist/components/input-group.js +43 -0
- package/dist/components/input.d.ts +12 -2
- package/dist/components/input.js +22 -8
- package/dist/components/kbd.d.ts +2 -1
- package/dist/components/kbd.js +4 -3
- package/dist/components/label.d.ts +3 -3
- package/dist/components/label.js +9 -6
- package/dist/components/multiselect.d.ts +22 -6
- package/dist/components/multiselect.js +82 -127
- package/dist/components/on-demand.d.ts +23 -0
- package/dist/components/on-demand.js +48 -0
- package/dist/components/popover.d.ts +22 -9
- package/dist/components/popover.js +42 -13
- package/dist/components/radio-group.d.ts +6 -5
- package/dist/components/radio-group.js +24 -29
- package/dist/components/resizable.d.ts +8 -21
- package/dist/components/resizable.js +5 -10
- package/dist/components/scroll-area.d.ts +13 -7
- package/dist/components/scroll-area.js +19 -18
- package/dist/components/select.d.ts +26 -14
- package/dist/components/select.js +96 -51
- package/dist/components/separator.d.ts +7 -3
- package/dist/components/separator.js +12 -12
- package/dist/components/sheet.d.ts +19 -11
- package/dist/components/sheet.js +70 -50
- package/dist/components/sidebar/context.js +4 -4
- package/dist/components/sidebar/group.d.ts +9 -8
- package/dist/components/sidebar/group.js +18 -13
- package/dist/components/sidebar/layout.d.ts +7 -2
- package/dist/components/sidebar/layout.js +11 -3
- package/dist/components/sidebar/menu-sub.d.ts +4 -3
- package/dist/components/sidebar/menu-sub.js +13 -13
- package/dist/components/sidebar/menu.d.ts +6 -6
- package/dist/components/sidebar/menu.js +28 -40
- package/dist/components/sidebar/panel.js +38 -21
- package/dist/components/sidebar/root.d.ts +1 -2
- package/dist/components/sidebar/root.js +7 -8
- package/dist/components/sidebar/trigger.js +1 -1
- package/dist/components/sidebar-tree-indicator.js +4 -4
- package/dist/components/sidebar.d.ts +1 -0
- package/dist/components/sidebar.js +1 -0
- package/dist/components/skeleton.d.ts +8 -1
- package/dist/components/skeleton.js +19 -2
- package/dist/components/slider.d.ts +5 -5
- package/dist/components/slider.js +20 -11
- package/dist/components/spinner.d.ts +3 -2
- package/dist/components/spinner.js +25 -188
- package/dist/components/string-array.js +3 -2
- package/dist/components/switch.d.ts +3 -3
- package/dist/components/switch.js +7 -8
- package/dist/components/table.d.ts +18 -3
- package/dist/components/table.js +37 -9
- package/dist/components/tabs.d.ts +41 -8
- package/dist/components/tabs.js +103 -23
- package/dist/components/text-overflow.d.ts +11 -10
- package/dist/components/text-overflow.js +36 -39
- package/dist/components/textarea.d.ts +9 -1
- package/dist/components/textarea.js +25 -3
- package/dist/components/toaster.d.ts +4 -0
- package/dist/components/toaster.js +44 -20
- package/dist/components/toggle-group.d.ts +10 -3
- package/dist/components/toggle-group.js +28 -21
- package/dist/components/toggle.d.ts +4 -4
- package/dist/components/toggle.js +7 -6
- package/dist/components/tooltip.d.ts +11 -6
- package/dist/components/tooltip.js +22 -8
- package/dist/components/upload.d.ts +11 -2
- package/dist/components/upload.js +47 -17
- package/dist/components.css +325 -0
- package/dist/constants/CountryPhoneCodes.d.ts +1 -1
- package/dist/constants/CountryPhoneCodes.js +2 -2
- package/dist/federation.d.ts +17 -0
- package/dist/federation.js +34 -0
- package/dist/fonts.css +1 -1
- package/dist/hooks/use-confirm.js +17 -19
- package/dist/hooks/use-item-keys.d.ts +11 -0
- package/dist/hooks/use-item-keys.js +24 -0
- package/dist/hooks/use-page-hotkey.d.ts +12 -0
- package/dist/hooks/use-page-hotkey.js +22 -0
- package/dist/hooks/use-toast.d.ts +19 -16
- package/dist/hooks/use-toast.js +18 -108
- package/dist/index.d.ts +41 -13
- package/dist/index.js +37 -10
- package/dist/lib/cn-tables.d.ts +27 -0
- package/dist/lib/cn-tables.js +128 -0
- package/dist/lib/format.d.ts +60 -0
- package/dist/lib/format.js +86 -0
- package/dist/lib/money.d.ts +13 -0
- package/dist/lib/money.js +21 -0
- package/dist/lib/stored.d.ts +13 -0
- package/dist/lib/stored.js +41 -0
- package/dist/lib/text.d.ts +11 -0
- package/dist/lib/text.js +18 -0
- package/dist/lib/utils.d.ts +14 -2
- package/dist/lib/utils.js +14 -6
- package/dist/modules/attachments/attachment-media.js +56 -56
- package/dist/modules/attachments/use-carousel.js +5 -10
- package/dist/modules/blocks/components/BarcodeAttribute.js +11 -8
- package/dist/modules/blocks/components/BarcodeSizeSettings.js +5 -6
- package/dist/modules/blocks/components/BlockEditor.js +14 -4
- package/dist/modules/blocks/components/BlockEditorInlineContent.d.ts +26 -36
- package/dist/modules/blocks/components/BlockEditorInlineContent.js +2 -2
- package/dist/modules/blocks/components/BlockToolbar.d.ts +6 -0
- package/dist/modules/blocks/components/BlockToolbar.js +19 -4
- package/dist/modules/blocks/components/CustomFileBlock.d.ts +13 -39
- package/dist/modules/blocks/components/CustomFileBlock.js +8 -9
- package/dist/modules/blocks/components/CustomImageBlock.d.ts +28 -78
- package/dist/modules/blocks/components/CustomImageBlock.js +20 -99
- package/dist/modules/blocks/components/CustomVideoBlock.d.ts +26 -63
- package/dist/modules/blocks/components/CustomVideoBlock.js +10 -8
- package/dist/modules/blocks/components/DocumentPlaceholderBlock.d.ts +13 -39
- package/dist/modules/blocks/components/DocumentPlaceholderBlock.js +1 -2
- package/dist/modules/blocks/components/Editor.d.ts +1 -1
- package/dist/modules/blocks/components/Editor.js +5 -4
- package/dist/modules/blocks/components/FontFamilyButton.js +25 -21
- package/dist/modules/blocks/components/FontSizeButton.js +26 -22
- package/dist/modules/blocks/components/GalleryBlock.d.ts +7 -25
- package/dist/modules/blocks/components/GalleryBlock.js +2 -35
- package/dist/modules/blocks/components/GalleryBlockContent.js +8 -3
- package/dist/modules/blocks/components/GalleryBlockParts.js +23 -21
- package/dist/modules/blocks/components/GalleryExternalHtml.d.ts +2 -0
- package/dist/modules/blocks/components/GalleryExternalHtml.js +36 -0
- package/dist/modules/blocks/components/ImageExternalHtml.d.ts +2 -0
- package/dist/modules/blocks/components/ImageExternalHtml.js +51 -0
- package/dist/modules/blocks/components/ImageStyleButton.js +22 -18
- package/dist/modules/blocks/components/LazyEditor.d.ts +9 -0
- package/dist/modules/blocks/components/LazyEditor.js +14 -0
- package/dist/modules/blocks/components/MediaBlockWrapper.d.ts +24 -0
- package/dist/modules/blocks/components/MediaBlockWrapper.js +98 -0
- package/dist/modules/blocks/components/SlashMenu.js +2 -2
- package/dist/modules/blocks/components/SuggestionMenu.js +5 -6
- package/dist/modules/blocks/components/TableColorPicker.d.ts +1 -1
- package/dist/modules/blocks/components/TableColorPicker.js +20 -27
- package/dist/modules/blocks/components/TableHandleWithRemove.js +34 -50
- package/dist/modules/blocks/components/toolbar/buttons/ToolbarButton.d.ts +2 -2
- package/dist/modules/blocks/components/toolbar/buttons/ToolbarButton.js +3 -4
- package/dist/modules/blocks/components/toolbar/buttons/ToolbarToggle.d.ts +2 -2
- package/dist/modules/blocks/components/toolbar/buttons/ToolbarToggle.js +3 -4
- package/dist/modules/blocks/components/toolbar/menus/MenuCheckboxItem.d.ts +3 -0
- package/dist/modules/blocks/components/toolbar/menus/MenuCheckboxItem.js +8 -0
- package/dist/modules/blocks/components/toolbar/menus/ToolbarMenuDropdown.js +1 -1
- package/dist/modules/blocks/components/toolbar/menus/ToolbarMenuItem.d.ts +2 -2
- package/dist/modules/blocks/components/toolbar/menus/ToolbarMenuItem.js +5 -16
- package/dist/modules/blocks/components/toolbar/menus/ToolbarSelect.d.ts +1 -1
- package/dist/modules/blocks/components/toolbar/menus/ToolbarSelect.js +24 -20
- package/dist/modules/blocks/constant/blockEditorSchema.d.ts +268 -653
- package/dist/modules/blocks/constant/blockEditorSchema.js +33 -41
- package/dist/modules/blocks/constant/galleryBlockConfig.d.ts +1 -2
- package/dist/modules/blocks/constant/imageBlockConfig.d.ts +46 -0
- package/dist/modules/blocks/constant/imageBlockConfig.js +39 -0
- package/dist/modules/blocks/constant/toolbar/editorUIComponents.d.ts +2 -3
- package/dist/modules/blocks/constant/toolbar/editorUIComponents.js +7 -9
- package/dist/modules/blocks/hooks/toolbar/useCodeActive.js +5 -7
- package/dist/modules/blocks/hooks/toolbar/useStringStyle.d.ts +9 -0
- package/dist/modules/blocks/hooks/toolbar/useStringStyle.js +27 -0
- package/dist/modules/blocks/hooks/useBarcodeSizeForm.d.ts +1 -1
- package/dist/modules/blocks/hooks/useBlockEditor.d.ts +2 -0
- package/dist/modules/blocks/hooks/useBlockEditor.js +9 -3
- package/dist/modules/blocks/hooks/useEditorValue.d.ts +2 -1
- package/dist/modules/blocks/hooks/useEditorValue.js +8 -19
- package/dist/modules/blocks/types/TextEditor.d.ts +3 -1
- package/dist/modules/blocks/types/toolbar/ImageStyleOption.d.ts +1 -1
- package/dist/modules/blocks/utils/getSlashMenuItems.js +0 -15
- package/dist/modules/blocks/utils/parseBlocks.d.ts +3 -1
- package/dist/modules/blocks/utils/parseBlocks.js +14 -1
- package/dist/modules/conditions/ConditionValueInput.d.ts +10 -0
- package/dist/modules/conditions/ConditionValueInput.js +166 -0
- package/dist/modules/conditions/ConditionsEditor.d.ts +11 -0
- package/dist/modules/conditions/ConditionsEditor.js +209 -0
- package/dist/modules/conditions/LazyConditionsEditor.d.ts +10 -0
- package/dist/modules/conditions/LazyConditionsEditor.js +11 -0
- package/dist/modules/conditions/PathPicker.d.ts +8 -0
- package/dist/modules/conditions/PathPicker.js +51 -0
- package/dist/modules/conditions/conditions.d.ts +66 -0
- package/dist/modules/conditions/conditions.js +136 -0
- package/dist/modules/display/components/EmailDisplay.d.ts +4 -0
- package/dist/modules/display/components/EmailDisplay.js +29 -27
- package/dist/modules/display/components/PhoneDisplay.d.ts +4 -0
- package/dist/modules/display/components/PhoneDisplay.js +6 -2
- package/dist/modules/display/components/RelativeDateDisplay.d.ts +8 -6
- package/dist/modules/display/components/RelativeDateDisplay.js +16 -17
- package/dist/modules/display/components/SexDisplay.d.ts +1 -0
- package/dist/modules/display/components/SexDisplay.js +1 -0
- package/dist/modules/filter/components/Filter.d.ts +4 -0
- package/dist/modules/filter/components/Filter.js +4 -0
- package/dist/modules/filter/components/FilterBar.js +11 -13
- package/dist/modules/filter/components/FilterDialog.js +17 -25
- package/dist/modules/filter/components/FilterPopover.js +21 -29
- package/dist/modules/filter/components/FilterProvider.d.ts +1 -2
- package/dist/modules/filter/components/FilterProvider.js +22 -16
- package/dist/modules/filter/hooks/useFilterContext.d.ts +1 -0
- package/dist/modules/filter/hooks/useFilterContext.js +1 -0
- package/dist/modules/filter/types/filter.d.ts +0 -1
- package/dist/modules/hotkey/components/PopoverScoped.d.ts +10 -4
- package/dist/modules/hotkey/components/PopoverScoped.js +10 -5
- package/dist/modules/hotkey/hooks/usePreviousHotkeyScope.d.ts +1 -0
- package/dist/modules/hotkey/hooks/usePreviousHotkeyScope.js +1 -0
- package/dist/modules/hotkey/hooks/useScopedHotkeys.d.ts +7 -3
- package/dist/modules/hotkey/hooks/useScopedHotkeys.js +19 -24
- package/dist/modules/icons/components/IconComponent.d.ts +5 -1
- package/dist/modules/icons/components/IconComponent.js +4 -0
- package/dist/modules/icons/components/IconPicker.d.ts +4 -0
- package/dist/modules/icons/components/IconPicker.js +20 -17
- package/dist/modules/icons/providers/IconsProvider.d.ts +1 -0
- package/dist/modules/icons/providers/IconsProvider.js +1 -0
- package/dist/modules/inputs/components/ContactFieldParts.js +13 -14
- package/dist/modules/inputs/components/EmailField.d.ts +4 -1
- package/dist/modules/inputs/components/EmailField.js +4 -1
- package/dist/modules/inputs/components/EmailFieldForm.js +2 -3
- package/dist/modules/inputs/components/FullNameField.d.ts +6 -0
- package/dist/modules/inputs/components/FullNameField.js +25 -11
- package/dist/modules/inputs/components/PhoneField.d.ts +4 -1
- package/dist/modules/inputs/components/PhoneField.js +4 -1
- package/dist/modules/inputs/components/PhoneFieldForm.js +2 -1
- package/dist/modules/inputs/components/SexField.d.ts +1 -0
- package/dist/modules/inputs/components/SexField.js +1 -0
- package/dist/modules/layout/components/AppLayout.d.ts +6 -6
- package/dist/modules/layout/components/AppLayout.js +29 -32
- package/dist/modules/layout/components/AppLayoutPageSlot.js +1 -1
- package/dist/modules/layout/components/AppLayoutResizeHandle.d.ts +5 -12
- package/dist/modules/layout/components/AppLayoutResizeHandle.js +16 -19
- package/dist/modules/layout/components/Page.d.ts +11 -1
- package/dist/modules/layout/components/Page.js +16 -3
- package/dist/modules/layout/components/PageHeader.d.ts +14 -4
- package/dist/modules/layout/components/PageHeader.js +27 -6
- package/dist/modules/list/DisplayMenu.d.ts +24 -0
- package/dist/modules/list/DisplayMenu.js +87 -0
- package/dist/modules/list/ListFilter.d.ts +63 -0
- package/dist/modules/list/ListFilter.js +44 -0
- package/dist/modules/list/ViewBar.d.ts +13 -0
- package/dist/modules/list/ViewBar.js +30 -0
- package/dist/modules/list/filter/AdvancedFilterDialog.d.ts +5 -0
- package/dist/modules/list/filter/AdvancedFilterDialog.js +52 -0
- package/dist/modules/list/filter/FieldMenus.d.ts +5 -0
- package/dist/modules/list/filter/FieldMenus.js +184 -0
- package/dist/modules/list/filter/ListFilterBar.d.ts +6 -0
- package/dist/modules/list/filter/ListFilterBar.js +246 -0
- package/dist/modules/list/filter/RecordCount.d.ts +7 -0
- package/dist/modules/list/filter/RecordCount.js +22 -0
- package/dist/modules/list/filter/RuleChips.d.ts +2 -0
- package/dist/modules/list/filter/RuleChips.js +157 -0
- package/dist/modules/list/filter/fieldIcons.d.ts +7 -0
- package/dist/modules/list/filter/fieldIcons.js +16 -0
- package/dist/modules/list/filter/filterRules.d.ts +46 -0
- package/dist/modules/list/filter/filterRules.js +166 -0
- package/dist/modules/list/filter/listFilterContext.d.ts +29 -0
- package/dist/modules/list/filter/listFilterContext.js +34 -0
- package/dist/modules/list/filter/listFilterQuery.d.ts +16 -0
- package/dist/modules/list/filter/listFilterQuery.js +22 -0
- package/dist/modules/navigation-menu/components/NavigationMenu.d.ts +4 -3
- package/dist/modules/navigation-menu/components/NavigationMenu.js +18 -21
- package/dist/modules/pickers/EntityPicker.d.ts +37 -0
- package/dist/modules/pickers/EntityPicker.js +67 -0
- package/dist/modules/pickers/LookupPicker.d.ts +51 -0
- package/dist/modules/pickers/LookupPicker.js +84 -0
- package/dist/modules/pickers/SelectMember.d.ts +41 -0
- package/dist/modules/pickers/SelectMember.js +122 -0
- package/dist/modules/pickers/members.d.ts +30 -0
- package/dist/modules/pickers/members.js +18 -0
- package/dist/modules/record-field/components/NumberField.d.ts +7 -2
- package/dist/modules/record-field/components/NumberField.js +33 -29
- package/dist/modules/record-field/components/TextField.d.ts +7 -3
- package/dist/modules/record-field/components/TextField.js +38 -30
- package/dist/modules/record-field/meta-inputs/components/PhoneInput.d.ts +8 -1
- package/dist/modules/record-field/meta-inputs/components/PhoneInput.js +23 -12
- package/dist/modules/record-list/RecordList.d.ts +18 -0
- package/dist/modules/record-list/RecordList.js +23 -0
- package/dist/modules/record-list/RecordListProvider.d.ts +30 -0
- package/dist/modules/record-list/RecordListProvider.js +57 -0
- package/dist/modules/record-list/RecordListRoot.d.ts +28 -0
- package/dist/modules/record-list/RecordListRoot.js +124 -0
- package/dist/modules/record-list/selection.d.ts +22 -0
- package/dist/modules/record-list/selection.js +54 -0
- package/dist/modules/record-panel/PanelDescriptionEditor.d.ts +9 -0
- package/dist/modules/record-panel/PanelDescriptionEditor.js +39 -0
- package/dist/modules/record-panel/PanelDescriptionField.d.ts +13 -0
- package/dist/modules/record-panel/PanelDescriptionField.js +39 -0
- package/dist/modules/record-panel/PanelField.d.ts +17 -0
- package/dist/modules/record-panel/PanelField.js +47 -0
- package/dist/modules/record-panel/PanelForm.d.ts +22 -0
- package/dist/modules/record-panel/PanelForm.js +81 -0
- package/dist/modules/record-panel/PanelLabel.d.ts +10 -0
- package/dist/modules/record-panel/PanelLabel.js +55 -0
- package/dist/modules/record-panel/PanelSection.d.ts +12 -0
- package/dist/modules/record-panel/PanelSection.js +24 -0
- package/dist/modules/record-panel/panelExpansion.d.ts +10 -0
- package/dist/modules/record-panel/panelExpansion.js +7 -0
- package/dist/modules/record-panel/useSaveOnLeave.d.ts +14 -0
- package/dist/modules/record-panel/useSaveOnLeave.js +42 -0
- package/dist/modules/record-table/components/CheckboxColumn.d.ts +4 -3
- package/dist/modules/record-table/components/CheckboxColumn.js +52 -35
- package/dist/modules/record-table/components/MoreColumn.js +4 -3
- package/dist/modules/record-table/components/RecordTable.d.ts +9 -2
- package/dist/modules/record-table/components/RecordTable.js +8 -1
- package/dist/modules/record-table/components/RecordTableCell.d.ts +15 -3
- package/dist/modules/record-table/components/RecordTableCell.js +31 -11
- package/dist/modules/record-table/components/RecordTableCellInline.d.ts +20 -4
- package/dist/modules/record-table/components/RecordTableCellInline.js +49 -24
- package/dist/modules/record-table/components/RecordTableColumnSelector.d.ts +1 -2
- package/dist/modules/record-table/components/RecordTableColumnSelector.js +48 -45
- package/dist/modules/record-table/components/RecordTableContainer.d.ts +8 -3
- package/dist/modules/record-table/components/RecordTableContainer.js +28 -16
- package/dist/modules/record-table/components/RecordTableCursor.js +33 -31
- package/dist/modules/record-table/components/RecordTableHead.d.ts +9 -4
- package/dist/modules/record-table/components/RecordTableHead.js +40 -34
- package/dist/modules/record-table/components/RecordTableHeader.js +24 -15
- package/dist/modules/record-table/components/RecordTableProvider.d.ts +30 -7
- package/dist/modules/record-table/components/RecordTableProvider.js +41 -26
- package/dist/modules/record-table/components/RecordTableRoot.d.ts +2 -1
- package/dist/modules/record-table/components/RecordTableRoot.js +7 -12
- package/dist/modules/record-table/components/RecordTableRow.d.ts +8 -1
- package/dist/modules/record-table/components/RecordTableRow.js +13 -12
- package/dist/modules/record-table/components/RecordTableRowList.d.ts +6 -1
- package/dist/modules/record-table/components/RecordTableRowList.js +28 -20
- package/dist/modules/record-table/components/RecordTableRowSkeleton.js +8 -12
- package/dist/modules/record-table/hooks/useColumnLayout.d.ts +2 -2
- package/dist/modules/record-table/hooks/useColumnLayout.js +8 -5
- package/dist/modules/record-table/hooks/useTablePreferences.d.ts +6 -6
- package/dist/modules/record-table/hooks/useTablePreferences.js +21 -34
- package/dist/modules/record-table/states/RecordTableCursorState.d.ts +21 -1
- package/dist/modules/record-table/states/RecordTableCursorState.js +21 -3
- package/dist/modules/record-table/types/RecordTableCursorTypes.d.ts +1 -0
- package/dist/modules/record-table/types/RecordTableCursorTypes.js +1 -0
- package/dist/modules/record-table/utils/columnLayout.d.ts +4 -4
- package/dist/modules/record-table/utils/columnLayout.js +7 -7
- package/dist/modules/record-table/utils/columnUtils.d.ts +3 -2
- package/dist/modules/record-table/utils/rowFields.d.ts +1 -0
- package/dist/modules/record-table/utils/rowFields.js +10 -9
- package/dist/modules/records/ContactLink.d.ts +13 -0
- package/dist/modules/records/ContactLink.js +77 -0
- package/dist/modules/records/contacts.d.ts +35 -0
- package/dist/modules/records/contacts.js +10 -0
- package/dist/modules/records/openRecord.d.ts +44 -0
- package/dist/modules/records/openRecord.js +48 -0
- package/dist/state/sidebarPanelState.d.ts +5 -1
- package/dist/state/sidebarPanelState.js +11 -3
- package/dist/state/themeState.d.ts +13 -2
- package/dist/state/themeState.js +18 -4
- package/dist/styles.css +3 -0
- package/dist/theme.css +106 -70
- package/dist/types/SexCode.d.ts +1 -0
- package/dist/types/SexCode.js +1 -0
- package/dist/types/UIConfig.d.ts +131 -3
- package/dist/utils/IsUndefinedOrNull.d.ts +1 -0
- package/dist/utils/IsUndefinedOrNull.js +1 -0
- package/dist/utils/file-storage.d.ts +2 -1
- package/dist/utils/file-storage.js +1 -0
- package/dist/utils/format/formatPhoneNumber.d.ts +4 -0
- package/dist/utils/format/formatPhoneNumber.js +4 -0
- package/dist/utils/getPluginAssetsUrl.d.ts +5 -0
- package/dist/utils/getPluginAssetsUrl.js +5 -0
- package/dist/utils/host-component.d.ts +10 -0
- package/dist/utils/host-component.js +34 -0
- package/dist/utils/json.d.ts +3 -2
- package/dist/utils/json.js +3 -2
- package/dist/utils/plugin-runtime.d.ts +21 -17
- package/dist/utils/plugin-runtime.js +59 -12
- package/dist/utils/plugin-styles.d.ts +7 -0
- package/dist/utils/plugin-styles.js +54 -0
- package/dist/utils/record-timeline.d.ts +10 -9
- package/dist/utils/record-timeline.js +12 -17
- package/exports.txt +226 -0
- package/package.json +37 -24
- package/dist/components/multiselect-options.d.ts +0 -16
- package/dist/components/multiselect-options.js +0 -13
- package/dist/components/multiselect-parts.d.ts +0 -23
- package/dist/components/multiselect-parts.js +0 -62
- package/dist/components/multiselect-state.d.ts +0 -66
- package/dist/components/multiselect-state.js +0 -131
- package/dist/components/time-picker.d.ts +0 -10
- package/dist/components/time-picker.js +0 -33
- package/dist/components/toasts.d.ts +0 -21
- package/dist/components/toasts.js +0 -69
- package/dist/constants/IntlLanguages.d.ts +0 -74
- package/dist/constants/IntlLanguages.js +0 -76
- package/dist/hooks/use-query-state.d.ts +0 -16
- package/dist/hooks/use-query-state.js +0 -122
- package/dist/modules/blocks/hooks/toolbar/useFontFamily.d.ts +0 -2
- package/dist/modules/blocks/hooks/toolbar/useFontFamily.js +0 -24
- package/dist/modules/blocks/hooks/toolbar/useFontSize.d.ts +0 -2
- package/dist/modules/blocks/hooks/toolbar/useFontSize.js +0 -24
- package/dist/modules/blocks/types/toolbar/EditorVisibleBounds.d.ts +0 -6
- package/dist/modules/blocks/types/toolbar/EditorVisibleBounds.js +0 -0
- package/dist/modules/blocks/types/toolbar/FontFamily.d.ts +0 -5
- package/dist/modules/blocks/types/toolbar/FontFamily.js +0 -0
- package/dist/modules/blocks/types/toolbar/FontSize.d.ts +0 -5
- package/dist/modules/blocks/types/toolbar/FontSize.js +0 -0
- package/dist/modules/blocks/types/toolbar/ToolbarMenuItemProps.d.ts +0 -4
- package/dist/modules/blocks/types/toolbar/ToolbarMenuItemProps.js +0 -0
- package/dist/modules/blocks/types/toolbar/ToolbarPositioningOptions.d.ts +0 -3
- package/dist/modules/blocks/types/toolbar/ToolbarPositioningOptions.js +0 -0
- package/dist/modules/blocks/utils/toolbar/getEditorVisibleBounds.d.ts +0 -2
- package/dist/modules/blocks/utils/toolbar/getEditorVisibleBounds.js +0 -30
- package/dist/modules/blocks/utils/toolbar/getToolbarPositioning.d.ts +0 -2
- package/dist/modules/blocks/utils/toolbar/getToolbarPositioning.js +0 -41
- package/dist/modules/filter/hooks/useFilterQueryState.d.ts +0 -4
- package/dist/modules/filter/hooks/useFilterQueryState.js +0 -14
- package/dist/modules/hotkey/hooks/useScopedHotKeysCallback.d.ts +0 -9
- package/dist/modules/hotkey/hooks/useScopedHotKeysCallback.js +0 -15
- package/dist/modules/hotkey/states/internal/pendingHotkeyState.d.ts +0 -4
- package/dist/modules/hotkey/states/internal/pendingHotkeyState.js +0 -4
- package/dist/types/Theme.d.ts +0 -1
- package/dist/types/Theme.js +0 -0
- package/dist/utils/localization/formatDateISOStringToRelativeDate.d.ts +0 -2
- package/dist/utils/localization/formatDateISOStringToRelativeDate.js +0 -16
|
@@ -1,30 +1,12 @@
|
|
|
1
1
|
import { endOfDay, format, getDaysInMonth, isAfter, isBefore, isValid, parse, parseISO, startOfDay } from "date-fns";
|
|
2
2
|
// src/components/date-picker-value.ts
|
|
3
|
-
|
|
4
|
-
const
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
"
|
|
9
|
-
"YYYY-MM-D",
|
|
10
|
-
"YYYY-M-DD"
|
|
3
|
+
const INPUT_PATTERN = "yyyy-MM-dd";
|
|
4
|
+
const LOOSE_INPUT_PATTERNS = [
|
|
5
|
+
INPUT_PATTERN,
|
|
6
|
+
"yyyy-M-d",
|
|
7
|
+
"yyyy-MM-d",
|
|
8
|
+
"yyyy-M-dd"
|
|
11
9
|
];
|
|
12
|
-
const DAYJS_TOKEN = /\[([^\]]*)]|YYYY|YY|DD|D|dddd|ddd|A|a|ZZ|Z/g;
|
|
13
|
-
const DATE_FNS_TOKEN = {
|
|
14
|
-
YYYY: "yyyy",
|
|
15
|
-
YY: "yy",
|
|
16
|
-
DD: "dd",
|
|
17
|
-
D: "d",
|
|
18
|
-
dddd: "EEEE",
|
|
19
|
-
ddd: "EEE",
|
|
20
|
-
A: "a",
|
|
21
|
-
a: "aaa",
|
|
22
|
-
ZZ: "xx",
|
|
23
|
-
Z: "xxx"
|
|
24
|
-
};
|
|
25
|
-
/** Turns a Day.js format string into the date-fns pattern with the same output. */
|
|
26
|
-
const toDateFnsPattern = (dayjsFormat) => dayjsFormat.replace(DAYJS_TOKEN, (token, escaped) => escaped === void 0 ? DATE_FNS_TOKEN[token] ?? token : `'${escaped.replaceAll("'", "''")}'`);
|
|
27
|
-
const formatWith = (date, dayjsFormat) => format(date, toDateFnsPattern(dayjsFormat));
|
|
28
10
|
const isDateInput = (value) => value instanceof Date || typeof value === "string" || typeof value === "number";
|
|
29
11
|
/** ISO strings without an offset are local time, like the Day.js parser this replaced. */
|
|
30
12
|
const toDate = (value) => {
|
|
@@ -80,7 +62,8 @@ const daysInMonth = (year, month) => {
|
|
|
80
62
|
if (year?.length !== 4 || !(monthNumber >= 1 && monthNumber <= 12)) return void 0;
|
|
81
63
|
return getDaysInMonth(new Date(Number(year), monthNumber - 1, 1));
|
|
82
64
|
};
|
|
83
|
-
|
|
65
|
+
/** Masks typed text as `yyyy-MM-dd`, clamping the month and day. */
|
|
66
|
+
const maskInputText = (value) => {
|
|
84
67
|
const [year, month, day] = splitDateSegments(value);
|
|
85
68
|
const normalizedMonth = month?.length === 2 ? String(Math.min(Number(month), 12)).padStart(2, "0") : month;
|
|
86
69
|
const maxDay = daysInMonth(year, normalizedMonth);
|
|
@@ -90,8 +73,6 @@ const formatDateMask = (value) => {
|
|
|
90
73
|
day?.length === 2 && maxDay ? String(Math.min(Number(day), maxDay)).padStart(2, "0") : day
|
|
91
74
|
].filter((segment) => segment !== void 0).join("-");
|
|
92
75
|
};
|
|
93
|
-
/** Masks typed text as `YYYY-MM-DD` when the picker uses the default format. */
|
|
94
|
-
const maskInputText = (rawValue, format) => format === "YYYY-MM-DD" ? formatDateMask(rawValue) : rawValue;
|
|
95
76
|
const getDateBounds = (withPresent, minDate, maxDate) => ({
|
|
96
77
|
minBound: minDate ?? (withPresent ? /* @__PURE__ */ new Date("1900-01-01") : void 0),
|
|
97
78
|
maxBound: maxDate ?? (withPresent ? /* @__PURE__ */ new Date() : void 0)
|
|
@@ -102,19 +83,19 @@ const getCalendarDisabled = (disabled, minBound, maxBound) => [
|
|
|
102
83
|
...maxBound ? [{ after: maxBound }] : []
|
|
103
84
|
];
|
|
104
85
|
const isWithinBounds = (date, minBound, maxBound) => !(minBound && isBefore(date, startOfDay(minBound))) && !(maxBound && isAfter(date, endOfDay(maxBound)));
|
|
105
|
-
/** Parses typed text strictly;
|
|
106
|
-
const parseInputDate = (text,
|
|
107
|
-
const parsed = (loose
|
|
86
|
+
/** Parses typed text strictly; `loose` also accepts unpadded months and days. */
|
|
87
|
+
const parseInputDate = (text, { minBound, maxBound, loose }) => {
|
|
88
|
+
const parsed = (loose ? LOOSE_INPUT_PATTERNS : [INPUT_PATTERN]).map((pattern) => ({
|
|
108
89
|
pattern,
|
|
109
90
|
date: parse(text, pattern, /* @__PURE__ */ new Date())
|
|
110
91
|
})).find(({ pattern, date }) => isValid(date) && format(date, pattern) === text)?.date;
|
|
111
92
|
return parsed && isWithinBounds(parsed, minBound, maxBound) ? parsed : void 0;
|
|
112
93
|
};
|
|
113
94
|
const isDateRange = (value) => value !== void 0 && !(value instanceof Date) && !Array.isArray(value);
|
|
114
|
-
const describeValue = (value,
|
|
95
|
+
const describeValue = (value, formatDay, formatMultiple) => {
|
|
115
96
|
if (Array.isArray(value)) return value.length ? formatMultiple(value.length) : void 0;
|
|
116
97
|
if (!isDateRange(value) || !value.from) return void 0;
|
|
117
|
-
const from =
|
|
118
|
-
return value.to ?
|
|
98
|
+
const from = formatDay(value.from);
|
|
99
|
+
return value.to ? [from, formatDay(value.to)].join(" - ") : from;
|
|
119
100
|
};
|
|
120
|
-
export {
|
|
101
|
+
export { describeValue, getAnchorDate, getCalendarDisabled, getDateBounds, isDateRange, maskInputText, normalizeValue, parseInputDate, toDate };
|
|
@@ -11,10 +11,6 @@ export type DatePickerProps = {
|
|
|
11
11
|
minDate?: Date;
|
|
12
12
|
maxDate?: Date;
|
|
13
13
|
mode?: DatePickerMode;
|
|
14
|
-
/** Day.js tokens, e.g. `YYYY-MM-DD`. */
|
|
15
|
-
format?: string;
|
|
16
|
-
/** Day.js tokens, e.g. `DD.MM.YYYY`. */
|
|
17
|
-
displayFormat?: string;
|
|
18
14
|
formatMultiple?: (count: number) => string;
|
|
19
15
|
variant?: 'outline' | 'default' | 'ghost';
|
|
20
16
|
allowNull?: boolean;
|
|
@@ -25,5 +21,9 @@ export type DatePickerProps = {
|
|
|
25
21
|
inline?: boolean;
|
|
26
22
|
disabled?: Matcher | Matcher[];
|
|
27
23
|
} & Omit<PropsBase, 'mode' | 'required' | 'disabled'>;
|
|
24
|
+
/**
|
|
25
|
+
* A date field with a calendar popover, for one day, several or a range.
|
|
26
|
+
* `mode` picks which; `inline` shows the calendar without the popover.
|
|
27
|
+
*/
|
|
28
28
|
export declare const DatePicker: (props: DatePickerProps) => import("react").JSX.Element;
|
|
29
29
|
export {};
|
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
import { Calendar } from "./calendar.js";
|
|
2
2
|
import { Button } from "./button.js";
|
|
3
3
|
import { Popover } from "./popover.js";
|
|
4
|
+
import { useFormat } from "../lib/format.js";
|
|
4
5
|
import { cn } from "../lib/utils.js";
|
|
5
|
-
import {
|
|
6
|
+
import { describeValue, getAnchorDate, getCalendarDisabled, getDateBounds, isDateRange, normalizeValue, toDate } from "./date-picker-value.js";
|
|
6
7
|
import { DateTextInput } from "./date-text-input.js";
|
|
7
|
-
import { useRef, useState } from "react";
|
|
8
8
|
import { Fragment, jsx, jsxs } from "react/jsx-runtime";
|
|
9
|
+
import { useRef, useState } from "react";
|
|
9
10
|
// src/components/date-picker.tsx
|
|
10
11
|
const defaultFormatMultiple = (count) => `${count} ${count > 1 ? "Days" : "Day"}`;
|
|
11
12
|
const ModeCalendar = ({ mode, value, onSelect, ...props }) => {
|
|
@@ -40,22 +41,25 @@ const PickerCalendar = ({ clearLabel, onClear, ...props }) => /* @__PURE__ */ js
|
|
|
40
41
|
children: clearLabel
|
|
41
42
|
})
|
|
42
43
|
})] });
|
|
43
|
-
const PickerPopover = ({ open, onOpenChange, trigger, contentProps, children }) =>
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
children: /* @__PURE__ */ jsx(
|
|
49
|
-
|
|
44
|
+
const PickerPopover = ({ open, onOpenChange, trigger, contentProps, children }) => {
|
|
45
|
+
const anchorRef = useRef(null);
|
|
46
|
+
return /* @__PURE__ */ jsxs(Popover, {
|
|
47
|
+
open,
|
|
48
|
+
onOpenChange,
|
|
49
|
+
children: [/* @__PURE__ */ jsx("div", {
|
|
50
|
+
ref: anchorRef,
|
|
51
|
+
className: "relative inline-block w-full",
|
|
50
52
|
children: trigger
|
|
51
|
-
})
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
})
|
|
53
|
+
}), /* @__PURE__ */ jsx(Popover.Content, {
|
|
54
|
+
align: "start",
|
|
55
|
+
anchor: anchorRef,
|
|
56
|
+
variant: "flush",
|
|
57
|
+
...contentProps,
|
|
58
|
+
className: cn("w-auto", contentProps?.className),
|
|
59
|
+
children
|
|
60
|
+
})]
|
|
61
|
+
});
|
|
62
|
+
};
|
|
59
63
|
/** Open state, the normalized value, bounds and the select and clear handlers. */
|
|
60
64
|
const useDatePicker = ({ value, onChange, mode, withPresent, minDate, maxDate, disabled }) => {
|
|
61
65
|
const [isOpen, setIsOpen] = useState(false);
|
|
@@ -85,7 +89,7 @@ const useDatePicker = ({ value, onChange, mode, withPresent, minDate, maxDate, d
|
|
|
85
89
|
};
|
|
86
90
|
};
|
|
87
91
|
/** The props with their defaults; what is left goes to the calendar. */
|
|
88
|
-
const resolveProps = ({ value, onChange, placeholder = "Pick a date", withPresent = false, minDate, maxDate, disabled, className, mode = "single",
|
|
92
|
+
const resolveProps = ({ value, onChange, placeholder = "Pick a date", withPresent = false, minDate, maxDate, disabled, className, mode = "single", formatMultiple = defaultFormatMultiple, variant = "outline", allowNull, clearable = allowNull ?? true, clearLabel = "Clear", calendarClassName, popoverContentProps, inline = false, defaultMonth, ...calendarProps }) => ({
|
|
89
93
|
value,
|
|
90
94
|
onChange,
|
|
91
95
|
placeholder,
|
|
@@ -95,8 +99,6 @@ const resolveProps = ({ value, onChange, placeholder = "Pick a date", withPresen
|
|
|
95
99
|
disabled,
|
|
96
100
|
className,
|
|
97
101
|
mode,
|
|
98
|
-
format,
|
|
99
|
-
displayFormat,
|
|
100
102
|
formatMultiple,
|
|
101
103
|
variant,
|
|
102
104
|
clearable,
|
|
@@ -107,15 +109,18 @@ const resolveProps = ({ value, onChange, placeholder = "Pick a date", withPresen
|
|
|
107
109
|
defaultMonth,
|
|
108
110
|
calendarProps
|
|
109
111
|
});
|
|
112
|
+
/**
|
|
113
|
+
* A date field with a calendar popover, for one day, several or a range.
|
|
114
|
+
* `mode` picks which; `inline` shows the calendar without the popover.
|
|
115
|
+
*/
|
|
110
116
|
const DatePicker = (props) => {
|
|
111
117
|
const { calendarProps, ...o } = resolveProps(props);
|
|
112
118
|
const picker = useDatePicker(o);
|
|
119
|
+
const fmt = useFormat();
|
|
113
120
|
const { normalizedValue, isDisabled, hasValue, setIsOpen } = picker;
|
|
114
121
|
const singleInput = /* @__PURE__ */ jsx(DateTextInput, {
|
|
115
122
|
singleDate: normalizedValue instanceof Date ? normalizedValue : void 0,
|
|
116
123
|
onChange: o.onChange,
|
|
117
|
-
format: o.format,
|
|
118
|
-
displayFormat: o.displayFormat,
|
|
119
124
|
bounds: picker.bounds,
|
|
120
125
|
calendarDisabled: picker.calendarDisabled,
|
|
121
126
|
clearable: o.clearable,
|
|
@@ -151,11 +156,11 @@ const DatePicker = (props) => {
|
|
|
151
156
|
onOpenChange: (open) => {
|
|
152
157
|
if (!open || !isDisabled) setIsOpen(open);
|
|
153
158
|
},
|
|
154
|
-
trigger: o.mode === "single" ? singleInput : /* @__PURE__ */ jsx(
|
|
155
|
-
variant: o.variant,
|
|
159
|
+
trigger: o.mode === "single" ? singleInput : /* @__PURE__ */ jsx(Popover.Trigger, {
|
|
160
|
+
render: /* @__PURE__ */ jsx(Button, { variant: o.variant }),
|
|
156
161
|
disabled: isDisabled,
|
|
157
162
|
className: cn("w-full justify-start text-left font-normal", o.className),
|
|
158
|
-
children: describeValue(normalizedValue,
|
|
163
|
+
children: describeValue(normalizedValue, fmt.date, o.formatMultiple) ?? o.placeholder
|
|
159
164
|
}),
|
|
160
165
|
contentProps: o.popoverContentProps,
|
|
161
166
|
children: calendar
|
|
@@ -3,7 +3,6 @@ import { Matcher } from "react-day-picker";
|
|
|
3
3
|
type DateDraftOptions = {
|
|
4
4
|
singleDate?: Date;
|
|
5
5
|
onChange: (date: Date | null) => void;
|
|
6
|
-
format: string;
|
|
7
6
|
bounds: {
|
|
8
7
|
minBound?: Date;
|
|
9
8
|
maxBound?: Date;
|
|
@@ -13,7 +12,6 @@ type DateDraftOptions = {
|
|
|
13
12
|
onOpen?: () => void;
|
|
14
13
|
};
|
|
15
14
|
type DateTextInputProps = DateDraftOptions & {
|
|
16
|
-
displayFormat: string;
|
|
17
15
|
clearLabel: string;
|
|
18
16
|
isDisabled: boolean;
|
|
19
17
|
placeholder: string;
|
|
@@ -21,6 +19,6 @@ type DateTextInputProps = DateDraftOptions & {
|
|
|
21
19
|
inputRef: RefObject<HTMLInputElement | null>;
|
|
22
20
|
onClear: () => void;
|
|
23
21
|
};
|
|
24
|
-
/** Typed date entry for single mode: the
|
|
25
|
-
export declare const DateTextInput: ({
|
|
22
|
+
/** Typed date entry for single mode: the date in the UI's language at rest, `yyyy-MM-dd` while typing. */
|
|
23
|
+
export declare const DateTextInput: ({ clearLabel, isDisabled, placeholder, className, inputRef, onClear, ...options }: DateTextInputProps) => import("react").JSX.Element;
|
|
26
24
|
export {};
|
|
@@ -1,16 +1,17 @@
|
|
|
1
1
|
import { cn } from "../lib/utils.js";
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
2
|
+
import { toIsoDay, useFormat } from "../lib/format.js";
|
|
3
|
+
import { maskInputText, parseInputDate } from "./date-picker-value.js";
|
|
4
4
|
import { IconCalendar, IconX } from "@tabler/icons-react";
|
|
5
5
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
6
|
+
import { useState } from "react";
|
|
6
7
|
import { dateMatchModifiers } from "react-day-picker";
|
|
7
8
|
// src/components/date-text-input.tsx
|
|
8
9
|
/** The text being typed (null while not editing, so the text follows the value) and its handlers. */
|
|
9
|
-
const useDateDraft = ({ singleDate, onChange,
|
|
10
|
+
const useDateDraft = ({ singleDate, onChange, bounds, calendarDisabled, clearable, onOpen }) => {
|
|
10
11
|
const [draft, setDraft] = useState(null);
|
|
11
12
|
const singleTime = singleDate?.getTime();
|
|
12
13
|
const parseDraft = (text, loose) => {
|
|
13
|
-
const date = text ? parseInputDate(text,
|
|
14
|
+
const date = text ? parseInputDate(text, {
|
|
14
15
|
...bounds,
|
|
15
16
|
loose
|
|
16
17
|
}) : void 0;
|
|
@@ -20,7 +21,7 @@ const useDateDraft = ({ singleDate, onChange, format, bounds, calendarDisabled,
|
|
|
20
21
|
if (date && date.getTime() !== singleTime) onChange(date);
|
|
21
22
|
};
|
|
22
23
|
const handleChange = (text) => {
|
|
23
|
-
const masked = maskInputText(text
|
|
24
|
+
const masked = maskInputText(text);
|
|
24
25
|
setDraft(masked);
|
|
25
26
|
if (masked) {
|
|
26
27
|
const parsed = parseDraft(masked, false);
|
|
@@ -34,7 +35,7 @@ const useDateDraft = ({ singleDate, onChange, format, bounds, calendarDisabled,
|
|
|
34
35
|
e.stopPropagation();
|
|
35
36
|
const typed = e.key === "Enter" ? parseDraft(draft, true) : void 0;
|
|
36
37
|
if (typed && typed.getTime() !== singleTime) {
|
|
37
|
-
setDraft(
|
|
38
|
+
setDraft(toIsoDay(typed));
|
|
38
39
|
onChange(typed);
|
|
39
40
|
} else if (opensPopover) onOpen?.();
|
|
40
41
|
};
|
|
@@ -43,21 +44,22 @@ const useDateDraft = ({ singleDate, onChange, format, bounds, calendarDisabled,
|
|
|
43
44
|
setDraft,
|
|
44
45
|
handleChange,
|
|
45
46
|
handleKeyDown,
|
|
46
|
-
handleFocus: () => setDraft((current) => current ?? (singleDate ?
|
|
47
|
+
handleFocus: () => setDraft((current) => current ?? (singleDate ? toIsoDay(singleDate) : "")),
|
|
47
48
|
handleBlur: () => {
|
|
48
49
|
changeTo(parseDraft(draft, true));
|
|
49
50
|
setDraft(null);
|
|
50
51
|
}
|
|
51
52
|
};
|
|
52
53
|
};
|
|
53
|
-
/** Typed date entry for single mode: the
|
|
54
|
-
const DateTextInput = ({
|
|
54
|
+
/** Typed date entry for single mode: the date in the UI's language at rest, `yyyy-MM-dd` while typing. */
|
|
55
|
+
const DateTextInput = ({ clearLabel, isDisabled, placeholder, className, inputRef, onClear, ...options }) => {
|
|
55
56
|
const { draft, setDraft, handleChange, handleKeyDown, handleFocus, handleBlur } = useDateDraft(options);
|
|
57
|
+
const fmt = useFormat();
|
|
56
58
|
const { singleDate } = options;
|
|
57
|
-
const inputText = draft ?? (singleDate ?
|
|
59
|
+
const inputText = draft ?? (singleDate ? fmt.date(singleDate) : "");
|
|
58
60
|
return /* @__PURE__ */ jsxs("div", {
|
|
59
61
|
"aria-disabled": isDisabled,
|
|
60
|
-
className: cn("flex h-7 w-full items-center gap-1 rounded-sm bg-background px-3 text-sm text-foreground shadow-xs transition
|
|
62
|
+
className: cn("flex h-7 w-full items-center gap-1 rounded-sm bg-background px-3 text-sm text-foreground shadow-xs transition focus-within:shadow-focus", isDisabled && "cursor-not-allowed opacity-50", className),
|
|
61
63
|
children: [/* @__PURE__ */ jsx("input", {
|
|
62
64
|
ref: inputRef,
|
|
63
65
|
type: "text",
|
|
@@ -69,7 +71,7 @@ const DateTextInput = ({ displayFormat, clearLabel, isDisabled, placeholder, cla
|
|
|
69
71
|
onBlur: handleBlur,
|
|
70
72
|
onKeyDown: handleKeyDown,
|
|
71
73
|
autoComplete: "off",
|
|
72
|
-
className: "h-full w-full min-w-0 flex-1 bg-transparent p-0 placeholder:text-accent-foreground
|
|
74
|
+
className: "h-full w-full min-w-0 flex-1 bg-transparent p-0 placeholder:text-accent-foreground focus-visible:outline-hidden disabled:cursor-not-allowed"
|
|
73
75
|
}), options.clearable && !isDisabled && inputText ? /* @__PURE__ */ jsx("button", {
|
|
74
76
|
type: "button",
|
|
75
77
|
"aria-label": clearLabel,
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { Input } from "@base-ui/react/input";
|
|
2
|
+
type DateTimeInputProps = Omit<Input.Props, 'type' | 'className'> & {
|
|
3
|
+
className?: string;
|
|
4
|
+
};
|
|
5
|
+
/** A time of day. `value` and `onValueChange` carry `HH:mm`, as the browser's time input does. */
|
|
6
|
+
export declare const TimeField: ({ className, ...props }: DateTimeInputProps) => import("react").JSX.Element;
|
|
7
|
+
/**
|
|
8
|
+
* A calendar date typed in. `value` and `onValueChange` carry `yyyy-MM-dd`, as the browser's date
|
|
9
|
+
* input does. DatePicker picks one from a calendar instead.
|
|
10
|
+
*/
|
|
11
|
+
export declare const DateInput: ({ className, ...props }: DateTimeInputProps) => import("react").JSX.Element;
|
|
12
|
+
export {};
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { inputVariants } from "./input.js";
|
|
2
|
+
import { cn } from "../lib/utils.js";
|
|
3
|
+
import { jsx } from "react/jsx-runtime";
|
|
4
|
+
import { Input } from "@base-ui/react/input";
|
|
5
|
+
// src/components/date-time-input.tsx
|
|
6
|
+
/** A time of day. `value` and `onValueChange` carry `HH:mm`, as the browser's time input does. */
|
|
7
|
+
const TimeField = ({ className, ...props }) => /* @__PURE__ */ jsx(Input, {
|
|
8
|
+
type: "time",
|
|
9
|
+
className: cn(inputVariants(), className),
|
|
10
|
+
...props
|
|
11
|
+
});
|
|
12
|
+
/**
|
|
13
|
+
* A calendar date typed in. `value` and `onValueChange` carry `yyyy-MM-dd`, as the browser's date
|
|
14
|
+
* input does. DatePicker picks one from a calendar instead.
|
|
15
|
+
*/
|
|
16
|
+
const DateInput = ({ className, ...props }) => /* @__PURE__ */ jsx(Input, {
|
|
17
|
+
type: "date",
|
|
18
|
+
className: cn(inputVariants(), className),
|
|
19
|
+
...props
|
|
20
|
+
});
|
|
21
|
+
export { DateInput, TimeField };
|
|
@@ -1,23 +1,32 @@
|
|
|
1
1
|
import React from "react";
|
|
2
|
-
import {
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
declare const
|
|
2
|
+
import { VariantProps } from "class-variance-authority";
|
|
3
|
+
import { Dialog as Dialog$1 } from "@base-ui/react/dialog";
|
|
4
|
+
/** Dims the page under a dialog. Content renders one; a hand-built popup in `Dialog.Portal` uses this. */
|
|
5
|
+
declare const DialogBackdrop: ({ className, ...props }: Dialog$1.Backdrop.Props) => React.JSX.Element;
|
|
6
|
+
declare const dialogContentVariants: (props?: ({
|
|
7
|
+
variant?: "bare" | "default" | null | undefined;
|
|
8
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
9
|
+
/** The backdrop dims the page and the viewport centers the popup; a press on either closes the dialog. */
|
|
10
|
+
declare const DialogContent: ({ className, variant, ...props }: Dialog$1.Popup.Props & VariantProps<typeof dialogContentVariants>) => React.JSX.Element;
|
|
6
11
|
declare const DialogCombinedHeader: ({ title, description, hideClose }: {
|
|
7
12
|
title: string;
|
|
8
13
|
description: string;
|
|
9
14
|
hideClose?: boolean;
|
|
10
15
|
}) => React.JSX.Element;
|
|
11
|
-
declare const DialogContentCombined: ({
|
|
16
|
+
declare const DialogContentCombined: ({ children, title, description, hideClose, ...props }: Dialog$1.Popup.Props & React.ComponentProps<typeof DialogCombinedHeader>) => React.JSX.Element;
|
|
12
17
|
declare const DialogHeader: ({ className, ...props }: React.HTMLAttributes<HTMLDivElement>) => React.JSX.Element;
|
|
13
18
|
declare const DialogFooter: ({ className, ...props }: React.HTMLAttributes<HTMLDivElement>) => React.JSX.Element;
|
|
14
|
-
declare const DialogTitle: ({
|
|
15
|
-
declare const DialogDescription: ({
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
19
|
+
declare const DialogTitle: ({ className, ...props }: Dialog$1.Title.Props) => React.JSX.Element;
|
|
20
|
+
declare const DialogDescription: ({ className, ...props }: Dialog$1.Description.Props) => React.JSX.Element;
|
|
21
|
+
/**
|
|
22
|
+
* A centered modal over a dimmed page, such as an image lightbox.
|
|
23
|
+
* Never a form: forms go in core's record side panel. To confirm an action, call `useConfirm`.
|
|
24
|
+
*/
|
|
25
|
+
export declare const Dialog: (<Payload>(props: Dialog$1.Root.Props<Payload>) => React.JSX.Element) & {
|
|
26
|
+
Trigger: Dialog$1.Trigger;
|
|
27
|
+
Close: React.ForwardRefExoticComponent<Omit<import("@base-ui/react").DialogCloseProps, "ref"> & React.RefAttributes<HTMLButtonElement>>;
|
|
28
|
+
Portal: React.ForwardRefExoticComponent<Omit<import("@base-ui/react").DialogPortalProps, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
29
|
+
Backdrop: typeof DialogBackdrop;
|
|
21
30
|
Content: typeof DialogContent;
|
|
22
31
|
HeaderCombined: typeof DialogCombinedHeader;
|
|
23
32
|
ContentCombined: typeof DialogContentCombined;
|
|
@@ -1,25 +1,34 @@
|
|
|
1
1
|
import { cn } from "../lib/utils.js";
|
|
2
2
|
import { Button } from "./button.js";
|
|
3
|
-
import "react";
|
|
4
|
-
import { Dialog as Dialog$1 } from "radix-ui";
|
|
5
3
|
import { IconX } from "@tabler/icons-react";
|
|
6
4
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
5
|
+
import "react";
|
|
6
|
+
import { cva } from "class-variance-authority";
|
|
7
7
|
import { useTranslation } from "react-i18next";
|
|
8
|
+
import { Dialog as Dialog$1 } from "@base-ui/react/dialog";
|
|
8
9
|
// src/components/dialog.tsx
|
|
9
|
-
|
|
10
|
-
const
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
ref,
|
|
14
|
-
className: cn("fixed inset-0 grid place-items-center z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 backdrop-blur-xs", "duration-200 ease-out", className),
|
|
10
|
+
/** Dims the page under a dialog. Content renders one; a hand-built popup in `Dialog.Portal` uses this. */
|
|
11
|
+
const DialogBackdrop = ({ className, ...props }) => /* @__PURE__ */ jsx(Dialog$1.Backdrop, {
|
|
12
|
+
forceRender: true,
|
|
13
|
+
className: cn("fixed inset-0 z-50 bg-black/80 backdrop-blur-xs data-open:animate-in data-closed:animate-out data-closed:fade-out-0 data-open:fade-in-0 duration-200 ease-out", className),
|
|
15
14
|
...props
|
|
16
15
|
});
|
|
17
|
-
const
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
}
|
|
16
|
+
const dialogContentVariants = cva("grid w-full max-w-lg gap-4 data-open:animate-in data-closed:animate-out data-closed:fade-out-0 data-open:fade-in-0 duration-200 ease-out will-change-transform sm:rounded-lg outline-hidden", {
|
|
17
|
+
variants: { variant: {
|
|
18
|
+
default: "border bg-background p-6 shadow-lg",
|
|
19
|
+
/** No panel: what it holds, such as an image in a lightbox, floats on the backdrop. */
|
|
20
|
+
bare: ""
|
|
21
|
+
} },
|
|
22
|
+
defaultVariants: { variant: "default" }
|
|
23
|
+
});
|
|
24
|
+
/** The backdrop dims the page and the viewport centers the popup; a press on either closes the dialog. */
|
|
25
|
+
const DialogContent = ({ className, variant, ...props }) => /* @__PURE__ */ jsxs(Dialog$1.Portal, { children: [/* @__PURE__ */ jsx(DialogBackdrop, {}), /* @__PURE__ */ jsx(Dialog$1.Viewport, {
|
|
26
|
+
className: "fixed inset-0 z-50 grid place-items-center",
|
|
27
|
+
children: /* @__PURE__ */ jsx(Dialog$1.Popup, {
|
|
28
|
+
className: cn(dialogContentVariants({ variant }), className),
|
|
29
|
+
...props
|
|
30
|
+
})
|
|
31
|
+
})] });
|
|
23
32
|
const DialogCombinedHeader = ({ title, description, hideClose }) => {
|
|
24
33
|
const { t } = useTranslation();
|
|
25
34
|
return /* @__PURE__ */ jsxs(Dialog.Header, { children: [
|
|
@@ -28,21 +37,18 @@ const DialogCombinedHeader = ({ title, description, hideClose }) => {
|
|
|
28
37
|
className: "sr-only",
|
|
29
38
|
children: description
|
|
30
39
|
}),
|
|
31
|
-
!hideClose && /* @__PURE__ */ jsx(Dialog.Close, {
|
|
32
|
-
asChild: true,
|
|
40
|
+
!hideClose && /* @__PURE__ */ jsx(Dialog$1.Close, {
|
|
33
41
|
"aria-label": t("close", "Close"),
|
|
34
|
-
|
|
42
|
+
render: /* @__PURE__ */ jsx(Button, {
|
|
35
43
|
variant: "secondary",
|
|
36
44
|
size: "icon",
|
|
37
|
-
className: "absolute right-4 top-3"
|
|
38
|
-
|
|
39
|
-
})
|
|
45
|
+
className: "absolute right-4 top-3"
|
|
46
|
+
}),
|
|
47
|
+
children: /* @__PURE__ */ jsx(IconX, {})
|
|
40
48
|
})
|
|
41
49
|
] });
|
|
42
50
|
};
|
|
43
|
-
const DialogContentCombined = ({
|
|
44
|
-
ref,
|
|
45
|
-
className: cn(className),
|
|
51
|
+
const DialogContentCombined = ({ children, title, description, hideClose, ...props }) => /* @__PURE__ */ jsxs(DialogContent, {
|
|
46
52
|
...props,
|
|
47
53
|
children: [/* @__PURE__ */ jsx(DialogCombinedHeader, {
|
|
48
54
|
title,
|
|
@@ -55,24 +61,26 @@ const DialogHeader = ({ className, ...props }) => /* @__PURE__ */ jsx("div", {
|
|
|
55
61
|
...props
|
|
56
62
|
});
|
|
57
63
|
const DialogFooter = ({ className, ...props }) => /* @__PURE__ */ jsx("div", {
|
|
58
|
-
className: cn("flex flex-col-reverse sm:flex-row sm:justify-end gap-2 sm:
|
|
64
|
+
className: cn("flex flex-col-reverse sm:flex-row sm:justify-end gap-2 sm:gap-4", className),
|
|
59
65
|
...props
|
|
60
66
|
});
|
|
61
|
-
const DialogTitle = ({
|
|
62
|
-
ref,
|
|
67
|
+
const DialogTitle = ({ className, ...props }) => /* @__PURE__ */ jsx(Dialog$1.Title, {
|
|
63
68
|
className: cn("text-lg font-semibold leading-none tracking-tight", className),
|
|
64
69
|
...props
|
|
65
70
|
});
|
|
66
|
-
const DialogDescription = ({
|
|
67
|
-
ref,
|
|
71
|
+
const DialogDescription = ({ className, ...props }) => /* @__PURE__ */ jsx(Dialog$1.Description, {
|
|
68
72
|
className: cn("text-sm text-accent-foreground", className),
|
|
69
73
|
...props
|
|
70
74
|
});
|
|
75
|
+
/**
|
|
76
|
+
* A centered modal over a dimmed page, such as an image lightbox.
|
|
77
|
+
* Never a form: forms go in core's record side panel. To confirm an action, call `useConfirm`.
|
|
78
|
+
*/
|
|
71
79
|
const Dialog = Object.assign(Dialog$1.Root, {
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
80
|
+
Trigger: Dialog$1.Trigger,
|
|
81
|
+
Close: Dialog$1.Close,
|
|
82
|
+
Portal: Dialog$1.Portal,
|
|
83
|
+
Backdrop: DialogBackdrop,
|
|
76
84
|
Content: DialogContent,
|
|
77
85
|
HeaderCombined: DialogCombinedHeader,
|
|
78
86
|
ContentCombined: DialogContentCombined,
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { ButtonProps } from "./button.js";
|
|
2
|
-
type DragHandleProps = Omit<ButtonProps, '
|
|
3
|
-
|
|
2
|
+
type DragHandleProps = Omit<ButtonProps, 'render' | 'children' | 'size'>;
|
|
3
|
+
/** A small grip button to drag a row or card by, for a sortable list. */
|
|
4
|
+
export declare const DragHandle: ({ ref, className, variant, ...props }: DragHandleProps) => import("react").JSX.Element;
|
|
4
5
|
export {};
|
|
@@ -3,13 +3,13 @@ import { cn } from "../lib/utils.js";
|
|
|
3
3
|
import { IconGripVertical } from "@tabler/icons-react";
|
|
4
4
|
import { jsx } from "react/jsx-runtime";
|
|
5
5
|
// src/components/drag-handle.tsx
|
|
6
|
+
/** A small grip button to drag a row or card by, for a sortable list. */
|
|
6
7
|
const DragHandle = ({ ref, className, variant = "ghost", ...props }) => /* @__PURE__ */ jsx(Button, {
|
|
7
8
|
className: cn("size-5 flex-none cursor-grab px-0 text-accent-foreground active:cursor-grabbing", className),
|
|
8
9
|
ref,
|
|
9
10
|
size: "icon",
|
|
10
11
|
variant,
|
|
11
12
|
...props,
|
|
12
|
-
asChild: false,
|
|
13
13
|
children: /* @__PURE__ */ jsx(IconGripVertical, {
|
|
14
14
|
className: "size-4",
|
|
15
15
|
stroke: 1.5
|
|
@@ -1,31 +1,51 @@
|
|
|
1
1
|
import React from "react";
|
|
2
|
-
import {
|
|
3
|
-
|
|
2
|
+
import { VariantProps } from "class-variance-authority";
|
|
3
|
+
import { Menu } from "@base-ui/react/menu";
|
|
4
|
+
/** Arrow keys stop at the first and last item, as they did under Radix. */
|
|
5
|
+
declare const DropdownMenuRoot: ({ loopFocus, ...props }: Menu.Root.Props) => React.JSX.Element;
|
|
6
|
+
declare const DropdownMenuSub: ({ loopFocus, ...props }: Menu.SubmenuRoot.Props) => React.JSX.Element;
|
|
7
|
+
export declare const popupAnimation = "data-open:animate-in data-closed:animate-out data-closed:fade-out-0 data-open:fade-in-0 data-closed:zoom-out-95 data-open:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2";
|
|
8
|
+
export type MenuPopupProps = Menu.Popup.Props & Pick<Menu.Positioner.Props, 'side' | 'sideOffset' | 'align' | 'alignOffset'>;
|
|
9
|
+
/** A menu popup in its portal and positioner, shared by the dropdown and context menus. */
|
|
10
|
+
export declare const MenuPopup: ({ side, sideOffset, align, alignOffset, ...props }: MenuPopupProps) => React.JSX.Element;
|
|
11
|
+
declare const DropdownMenuSubTrigger: ({ className, inset, ...props }: Menu.SubmenuTrigger.Props & {
|
|
4
12
|
inset?: boolean;
|
|
5
13
|
}) => React.JSX.Element;
|
|
6
|
-
declare const DropdownMenuSubContent: ({
|
|
7
|
-
declare const DropdownMenuContent: ({
|
|
8
|
-
declare const
|
|
9
|
-
|
|
14
|
+
declare const DropdownMenuSubContent: ({ className, side, align, ...props }: MenuPopupProps) => React.JSX.Element;
|
|
15
|
+
declare const DropdownMenuContent: ({ className, side, sideOffset, align, ...props }: MenuPopupProps) => React.JSX.Element;
|
|
16
|
+
declare const menuItemVariants: (props?: ({
|
|
17
|
+
variant?: "default" | "destructive" | null | undefined;
|
|
18
|
+
inset?: boolean | null | undefined;
|
|
19
|
+
} & import("class-variance-authority/types").ClassProp) | undefined) => string;
|
|
20
|
+
type MenuItemVariants = VariantProps<typeof menuItemVariants>;
|
|
21
|
+
declare const DropdownMenuItem: ({ className, variant, inset, ...props }: Menu.Item.Props & MenuItemVariants) => React.JSX.Element;
|
|
22
|
+
/** A menu item that navigates; it closes the menu like any other item. */
|
|
23
|
+
declare const DropdownMenuLinkItem: ({ className, variant, inset, closeOnClick, ...props }: Menu.LinkItem.Props & MenuItemVariants) => React.JSX.Element;
|
|
24
|
+
declare const DropdownMenuCheckboxItem: ({ className, children, closeOnClick, ...props }: Menu.CheckboxItem.Props) => React.JSX.Element;
|
|
25
|
+
declare const DropdownMenuRadioGroup: <Value>(props: Omit<Menu.RadioGroup.Props, 'value' | 'defaultValue' | 'onValueChange'> & {
|
|
26
|
+
value?: Value;
|
|
27
|
+
defaultValue?: Value;
|
|
28
|
+
onValueChange?: (value: Value, eventDetails: Menu.RadioGroup.ChangeEventDetails) => void;
|
|
10
29
|
}) => React.JSX.Element;
|
|
11
|
-
declare const
|
|
12
|
-
|
|
13
|
-
declare const DropdownMenuLabel: ({
|
|
30
|
+
declare const DropdownMenuRadioItem: ({ className, children, closeOnClick, ...props }: Menu.RadioItem.Props) => React.JSX.Element;
|
|
31
|
+
/** A heading inside a menu. It isn't an item, so arrow keys skip it. */
|
|
32
|
+
declare const DropdownMenuLabel: ({ className, inset, ...props }: React.ComponentProps<'div'> & {
|
|
14
33
|
inset?: boolean;
|
|
15
34
|
}) => React.JSX.Element;
|
|
16
|
-
declare const DropdownMenuSeparator: ({
|
|
35
|
+
declare const DropdownMenuSeparator: ({ className, ...props }: Menu.Separator.Props) => React.JSX.Element;
|
|
17
36
|
declare const DropdownMenuShortcut: ({ className, ...props }: React.HTMLAttributes<HTMLSpanElement>) => React.JSX.Element;
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
Sub:
|
|
37
|
+
/** A menu of actions that opens from a button, such as a row's "more" menu. */
|
|
38
|
+
export declare const DropdownMenu: typeof DropdownMenuRoot & {
|
|
39
|
+
Trigger: Menu.Trigger;
|
|
40
|
+
Group: React.ForwardRefExoticComponent<Omit<import("@base-ui/react").MenuGroupProps, "ref"> & React.RefAttributes<HTMLDivElement>>;
|
|
41
|
+
Sub: typeof DropdownMenuSub;
|
|
23
42
|
SubTrigger: typeof DropdownMenuSubTrigger;
|
|
24
43
|
SubContent: typeof DropdownMenuSubContent;
|
|
25
|
-
RadioGroup:
|
|
44
|
+
RadioGroup: typeof DropdownMenuRadioGroup;
|
|
26
45
|
RadioItem: typeof DropdownMenuRadioItem;
|
|
27
46
|
Content: typeof DropdownMenuContent;
|
|
28
47
|
Item: typeof DropdownMenuItem;
|
|
48
|
+
LinkItem: typeof DropdownMenuLinkItem;
|
|
29
49
|
CheckboxItem: typeof DropdownMenuCheckboxItem;
|
|
30
50
|
Label: typeof DropdownMenuLabel;
|
|
31
51
|
Shortcut: typeof DropdownMenuShortcut;
|