@cube-dev/ui-kit 0.120.1 → 0.121.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/CHANGELOG.md +20 -0
- package/dist/_internal/hooks/use-chained-callback.js +1 -1
- package/dist/_internal/hooks/use-debounced-value.js +1 -1
- package/dist/_internal/hooks/use-deprecation-warning.js +1 -1
- package/dist/_internal/hooks/use-event.js +1 -1
- package/dist/_internal/hooks/use-is-first-render.js +1 -1
- package/dist/_internal/hooks/use-sync-ref.js +1 -1
- package/dist/_internal/hooks/use-timer/timer.js +1 -1
- package/dist/_internal/hooks/use-timer/use-timer.js +1 -1
- package/dist/_internal/hooks/use-warn.js +1 -1
- package/dist/components/Block.js +1 -1
- package/dist/components/CollectionItem.js +1 -1
- package/dist/components/GlobalStyles.js +1 -1
- package/dist/components/GridProvider.js +1 -1
- package/dist/components/HiddenInput.js +1 -1
- package/dist/components/Root.js +1 -1
- package/dist/components/actions/Action/Action.js +1 -1
- package/dist/components/actions/Banner/Banner.js +1 -1
- package/dist/components/actions/Button/Button.d.ts +1 -0
- package/dist/components/actions/Button/Button.js +34 -14
- package/dist/components/actions/Button/Button.js.map +1 -1
- package/dist/components/actions/ButtonGroup/ButtonGroup.js +1 -1
- package/dist/components/actions/ButtonSplit/ButtonSplit.d.ts +47 -0
- package/dist/components/actions/ButtonSplit/ButtonSplit.js +105 -0
- package/dist/components/actions/ButtonSplit/ButtonSplit.js.map +1 -0
- package/dist/components/actions/ButtonSplit/context.d.ts +18 -0
- package/dist/components/actions/ButtonSplit/context.js +12 -0
- package/dist/components/actions/ButtonSplit/context.js.map +1 -0
- package/dist/components/actions/ButtonSplit/index.d.ts +3 -0
- package/dist/components/actions/CommandMenu/CommandMenu.js +1 -1
- package/dist/components/actions/CommandMenu/styled.js +1 -1
- package/dist/components/actions/ItemAction/ItemAction.js +1 -1
- package/dist/components/actions/ItemActionContext.js +1 -1
- package/dist/components/actions/ItemButton/ItemButton.js +1 -1
- package/dist/components/actions/Link/Link.js +1 -1
- package/dist/components/actions/Menu/Menu.d.ts +2 -2
- package/dist/components/actions/Menu/Menu.js +1 -1
- package/dist/components/actions/Menu/MenuItem.js +1 -1
- package/dist/components/actions/Menu/MenuSection.js +1 -1
- package/dist/components/actions/Menu/MenuTrigger.js +1 -1
- package/dist/components/actions/Menu/SubMenuTrigger.js +1 -1
- package/dist/components/actions/Menu/SubmenuTriggerContext.js +1 -1
- package/dist/components/actions/Menu/context.js +1 -1
- package/dist/components/actions/Menu/styled.js +1 -1
- package/dist/components/actions/index.d.ts +8 -3
- package/dist/components/actions/index.js +10 -5
- package/dist/components/actions/index.js.map +1 -1
- package/dist/components/actions/use-action.d.ts +1 -0
- package/dist/components/actions/use-action.js +21 -18
- package/dist/components/actions/use-action.js.map +1 -1
- package/dist/components/actions/use-anchored-menu.js +1 -1
- package/dist/components/actions/use-context-menu.js +1 -1
- package/dist/components/content/ActiveZone/ActiveZone.js +1 -1
- package/dist/components/content/Alert/Alert.js +1 -1
- package/dist/components/content/Alert/use-alert.js +1 -1
- package/dist/components/content/Avatar/Avatar.js +1 -1
- package/dist/components/content/Badge/Badge.js +2 -1
- package/dist/components/content/Badge/Badge.js.map +1 -1
- package/dist/components/content/Card/Card.js +1 -1
- package/dist/components/content/Content.js +1 -1
- package/dist/components/content/CopyPasteBlock/CopyPasteBlock.js +1 -1
- package/dist/components/content/CopySnippet/CopySnippet.js +1 -1
- package/dist/components/content/Disclosure/Disclosure.js +5 -2
- package/dist/components/content/Disclosure/Disclosure.js.map +1 -1
- package/dist/components/content/Divider.js +1 -1
- package/dist/components/content/Footer.js +1 -1
- package/dist/components/content/Header.js +1 -1
- package/dist/components/content/HotKeys/HotKeys.js +1 -1
- package/dist/components/content/Item/Item.js +1 -1
- package/dist/components/content/ItemBadge/ItemBadge.js +3 -2
- package/dist/components/content/ItemBadge/ItemBadge.js.map +1 -1
- package/dist/components/content/ItemCard/ItemCard.js +1 -1
- package/dist/components/content/Layout/GridLayout.js +1 -1
- package/dist/components/content/Layout/Layout.js +1 -1
- package/dist/components/content/Layout/LayoutBlock.js +1 -1
- package/dist/components/content/Layout/LayoutCenter.js +1 -1
- package/dist/components/content/Layout/LayoutContainer.js +1 -1
- package/dist/components/content/Layout/LayoutContent.js +1 -1
- package/dist/components/content/Layout/LayoutContext.js +1 -1
- package/dist/components/content/Layout/LayoutFlex.js +1 -1
- package/dist/components/content/Layout/LayoutFooter.js +1 -1
- package/dist/components/content/Layout/LayoutGrid.js +1 -1
- package/dist/components/content/Layout/LayoutHeader.js +1 -1
- package/dist/components/content/Layout/LayoutPane.js +1 -1
- package/dist/components/content/Layout/LayoutPanel.js +1 -1
- package/dist/components/content/Layout/LayoutPanelHeader.js +1 -1
- package/dist/components/content/Layout/LayoutToolbar.js +1 -1
- package/dist/components/content/Layout/hooks/useTinyScrollbar.js +1 -1
- package/dist/components/content/Layout/index.js +1 -1
- package/dist/components/content/Layout/utils.js +1 -1
- package/dist/components/content/Paragraph.js +1 -1
- package/dist/components/content/Placeholder/Placeholder.js +1 -1
- package/dist/components/content/PrismCode/PrismCode.js +1 -1
- package/dist/components/content/PrismCode/prismSetup.js +1 -1
- package/dist/components/content/PrismDiffCode/PrismDiffCode.js +1 -1
- package/dist/components/content/Result/Result.js +1 -1
- package/dist/components/content/Skeleton/Skeleton.js +1 -1
- package/dist/components/content/Tag/Tag.js +2 -1
- package/dist/components/content/Tag/Tag.js.map +1 -1
- package/dist/components/content/Text.js +1 -1
- package/dist/components/content/TextItem/TextItem.js +1 -1
- package/dist/components/content/Title.js +1 -1
- package/dist/components/content/highlightText.js +1 -1
- package/dist/components/content/use-auto-tooltip.js +1 -1
- package/dist/components/fields/Checkbox/Checkbox.js +1 -1
- package/dist/components/fields/Checkbox/CheckboxGroup.js +1 -1
- package/dist/components/fields/Checkbox/context.js +1 -1
- package/dist/components/fields/ComboBox/ComboBox.js +1 -1
- package/dist/components/fields/DatePicker/DateInput.js +1 -1
- package/dist/components/fields/DatePicker/DateInputBase.js +1 -1
- package/dist/components/fields/DatePicker/DatePicker.js +1 -1
- package/dist/components/fields/DatePicker/DatePickerButton.js +1 -1
- package/dist/components/fields/DatePicker/DatePickerElement.js +1 -1
- package/dist/components/fields/DatePicker/DatePickerInput.js +1 -1
- package/dist/components/fields/DatePicker/DatePickerSegment.js +1 -1
- package/dist/components/fields/DatePicker/DateRangePicker.js +1 -1
- package/dist/components/fields/DatePicker/DateRangeSeparatedPicker.js +1 -1
- package/dist/components/fields/DatePicker/TimeInput.js +1 -1
- package/dist/components/fields/DatePicker/intl.js +1 -1
- package/dist/components/fields/DatePicker/parseDate.js +1 -1
- package/dist/components/fields/DatePicker/props.js +1 -1
- package/dist/components/fields/DatePicker/utils.js +1 -1
- package/dist/components/fields/FileInput/FileInput.js +1 -1
- package/dist/components/fields/FilterListBox/FilterListBox.js +1 -1
- package/dist/components/fields/FilterPicker/FilterPicker.js +2 -2
- package/dist/components/fields/Input/Input.js +1 -1
- package/dist/components/fields/ListBox/ListBox.js +1 -1
- package/dist/components/fields/NumberInput/NumberInput.js +1 -1
- package/dist/components/fields/NumberInput/StepButton.js +1 -1
- package/dist/components/fields/PasswordInput/PasswordInput.js +1 -1
- package/dist/components/fields/Picker/Picker.js +2 -2
- package/dist/components/fields/RadioGroup/Radio.js +3 -1
- package/dist/components/fields/RadioGroup/Radio.js.map +1 -1
- package/dist/components/fields/RadioGroup/RadioGroup.js +1 -1
- package/dist/components/fields/RadioGroup/context.js +1 -1
- package/dist/components/fields/SearchInput/SearchInput.js +1 -1
- package/dist/components/fields/Select/Select.d.ts +8 -2
- package/dist/components/fields/Select/Select.js +1 -1
- package/dist/components/fields/Select/Select.js.map +1 -1
- package/dist/components/fields/Slider/Gradation.js +1 -1
- package/dist/components/fields/Slider/HueSlider.js +1 -1
- package/dist/components/fields/Slider/RangeSlider.js +1 -1
- package/dist/components/fields/Slider/Slider.js +1 -1
- package/dist/components/fields/Slider/SliderBase.js +1 -1
- package/dist/components/fields/Slider/SliderThumb.js +1 -1
- package/dist/components/fields/Slider/SliderTrack.js +1 -1
- package/dist/components/fields/Slider/elements.js +1 -1
- package/dist/components/fields/Slider/index.js +1 -1
- package/dist/components/fields/Switch/Switch.js +1 -1
- package/dist/components/fields/TextArea/TextArea.js +1 -1
- package/dist/components/fields/TextInput/TextInput.js +1 -1
- package/dist/components/fields/TextInput/TextInputBase.js +1 -1
- package/dist/components/fields/TextInputMapper/TextInputMapper.js +1 -1
- package/dist/components/form/FieldWrapper/FieldWrapper.js +1 -1
- package/dist/components/form/FieldWrapper/extract-field-wrapper-props.js +1 -1
- package/dist/components/form/Form/Field.js +1 -1
- package/dist/components/form/Form/Form.js +1 -1
- package/dist/components/form/Form/ResetButton/ResetButton.js +1 -1
- package/dist/components/form/Form/SubmitButton/SubmitButton.js +1 -1
- package/dist/components/form/Form/SubmitError.js +1 -1
- package/dist/components/form/Form/index.js +1 -1
- package/dist/components/form/Form/use-field/use-field-props.js +1 -1
- package/dist/components/form/Form/use-field/use-field.js +1 -1
- package/dist/components/form/Form/use-form.js +1 -1
- package/dist/components/form/Form/validation.js +1 -1
- package/dist/components/form/Label.js +1 -1
- package/dist/components/form/wrapper.js +1 -1
- package/dist/components/helpers/DisplayTransition/DisplayTransition.js +1 -1
- package/dist/components/helpers/IconSwitch/IconSwitch.js +1 -1
- package/dist/components/layout/Flex.js +1 -1
- package/dist/components/layout/Flow.js +1 -1
- package/dist/components/layout/Grid.js +1 -1
- package/dist/components/layout/Panel.js +1 -1
- package/dist/components/layout/Prefix.js +1 -1
- package/dist/components/layout/ResizablePanel.js +1 -1
- package/dist/components/layout/Space.js +1 -1
- package/dist/components/layout/Suffix.js +1 -1
- package/dist/components/navigation/Tabs/DraggableTabList.js +1 -1
- package/dist/components/navigation/Tabs/EditableTitle.js +1 -1
- package/dist/components/navigation/Tabs/TabButton.js +1 -1
- package/dist/components/navigation/Tabs/TabDropIndicator.js +1 -1
- package/dist/components/navigation/Tabs/TabPanel.js +1 -1
- package/dist/components/navigation/Tabs/TabPicker.js +2 -1
- package/dist/components/navigation/Tabs/TabPicker.js.map +1 -1
- package/dist/components/navigation/Tabs/Tabs.js +1 -1
- package/dist/components/navigation/Tabs/TabsAction.js +1 -1
- package/dist/components/navigation/Tabs/TabsContext.js +1 -1
- package/dist/components/navigation/Tabs/styled.js +3 -1
- package/dist/components/navigation/Tabs/styled.js.map +1 -1
- package/dist/components/navigation/Tabs/types.d.ts +2 -2
- package/dist/components/navigation/Tabs/types.js +1 -1
- package/dist/components/navigation/Tabs/types.js.map +1 -1
- package/dist/components/navigation/Tabs/use-tab-editing.js +1 -1
- package/dist/components/navigation/Tabs/use-tab-indicator.js +1 -1
- package/dist/components/organisms/FileTabs/FileTabs.js +1 -1
- package/dist/components/organisms/StatsCard/StatsCard.js +1 -1
- package/dist/components/other/Calendar/Calendar.js +1 -1
- package/dist/components/other/Calendar/CalendarCell.js +1 -1
- package/dist/components/other/Calendar/CalendarGrid.js +1 -1
- package/dist/components/other/Calendar/RangeCalendar.js +1 -1
- package/dist/components/other/CloudLogo/CloudLogo.js +1 -1
- package/dist/components/overlays/AlertDialog/AlertDialog.js +1 -1
- package/dist/components/overlays/AlertDialog/AlertDialogApiProvider.js +1 -1
- package/dist/components/overlays/AlertDialog/AlertDialogZone.js +1 -1
- package/dist/components/overlays/Dialog/Dialog.js +2 -2
- package/dist/components/overlays/Dialog/DialogContainer.js +1 -1
- package/dist/components/overlays/Dialog/DialogForm.js +1 -1
- package/dist/components/overlays/Dialog/DialogTrigger.js +1 -1
- package/dist/components/overlays/Dialog/context.js +1 -1
- package/dist/components/overlays/Dialog/use-dialog-container.js +1 -1
- package/dist/components/overlays/Modal/Modal.js +1 -1
- package/dist/components/overlays/Modal/OpenTransition.js +1 -1
- package/dist/components/overlays/Modal/Overlay.js +1 -1
- package/dist/components/overlays/Modal/Popover.js +1 -1
- package/dist/components/overlays/Modal/Tray.js +1 -1
- package/dist/components/overlays/Modal/Underlay.js +1 -1
- package/dist/components/overlays/Notifications/Notification.js +1 -1
- package/dist/components/overlays/Notifications/NotificationAction.js +1 -1
- package/dist/components/overlays/Notifications/NotificationCard.js +1 -1
- package/dist/components/overlays/Notifications/NotificationContext.js +1 -1
- package/dist/components/overlays/Notifications/NotificationItem.js +1 -1
- package/dist/components/overlays/Notifications/OverlayContainer.js +1 -1
- package/dist/components/overlays/Notifications/OverlayProvider.js +1 -1
- package/dist/components/overlays/Notifications/PersistentNotificationsList.js +1 -1
- package/dist/components/overlays/Notifications/dismissed-storage.js +1 -1
- package/dist/components/overlays/Notifications/format-relative-time.js +1 -1
- package/dist/components/overlays/Notifications/index.js +1 -1
- package/dist/components/overlays/Notifications/use-notification-state.js +1 -1
- package/dist/components/overlays/Notifications/use-notifications.js +1 -1
- package/dist/components/overlays/Notifications/use-overlay-timers.js +1 -1
- package/dist/components/overlays/Notifications/use-persistent-notifications.js +1 -1
- package/dist/components/overlays/Notifications/use-persistent-state.js +1 -1
- package/dist/components/overlays/Notifications/use-toast-state.js +1 -1
- package/dist/components/overlays/Toast/ToastItem.js +1 -1
- package/dist/components/overlays/Toast/index.js +1 -1
- package/dist/components/overlays/Toast/useProgressToast.js +1 -1
- package/dist/components/overlays/Toast/useToast.js +1 -1
- package/dist/components/overlays/Tooltip/Tooltip.js +1 -1
- package/dist/components/overlays/Tooltip/TooltipProvider.js +1 -1
- package/dist/components/overlays/Tooltip/TooltipTrigger.js +1 -1
- package/dist/components/overlays/Tooltip/context.js +1 -1
- package/dist/components/portal/Portal.js +1 -1
- package/dist/components/portal/PortalProvider.js +1 -1
- package/dist/components/portal/usePortal.js +1 -1
- package/dist/components/shared/InvalidIcon.js +1 -1
- package/dist/components/shared/ValidIcon.js +1 -1
- package/dist/components/status/LoadingAnimation/LoadingAnimation.js +1 -1
- package/dist/components/status/Spin/Cube.js +1 -1
- package/dist/components/status/Spin/InternalSpinner.js +1 -1
- package/dist/components/status/Spin/Spin.js +1 -1
- package/dist/components/status/Spin/SpinsContainer.js +1 -1
- package/dist/data/item-themes.js +6 -6
- package/dist/data/item-themes.js.map +1 -1
- package/dist/data/themes.js +1 -1
- package/dist/icons/AdjustmentsHorizontalIcon.js +1 -1
- package/dist/icons/AdjustmentsIcon.js +1 -1
- package/dist/icons/AiIcon.js +1 -1
- package/dist/icons/AreaChartIcon.js +1 -1
- package/dist/icons/BackwardIcon.js +1 -1
- package/dist/icons/BarChartIcon.js +1 -1
- package/dist/icons/BellFilledIcon.js +1 -1
- package/dist/icons/BellIcon.js +1 -1
- package/dist/icons/BooleanIcon.js +1 -1
- package/dist/icons/CalendarEditIcon.js +1 -1
- package/dist/icons/CalendarIcon.js +1 -1
- package/dist/icons/CaretDownIcon.js +1 -1
- package/dist/icons/CaretUpIcon.js +1 -1
- package/dist/icons/ChartAreaStackedIcon.js +1 -1
- package/dist/icons/ChartAreaStackedPercentageIcon.js +1 -1
- package/dist/icons/ChartBarGroupedHorizontalIcon.js +1 -1
- package/dist/icons/ChartBarGroupedIcon.js +1 -1
- package/dist/icons/ChartBarHorizontalIcon.js +1 -1
- package/dist/icons/ChartBarLineIcon.js +1 -1
- package/dist/icons/ChartBarStackedHorizontalIcon.js +1 -1
- package/dist/icons/ChartBarStackedIcon.js +1 -1
- package/dist/icons/ChartBarStackedPercentageHorizontalIcon.js +1 -1
- package/dist/icons/ChartBarStackedPercentageIcon.js +1 -1
- package/dist/icons/ChartBoxPlot2Icon.js +1 -1
- package/dist/icons/ChartBoxPlotIcon.js +1 -1
- package/dist/icons/ChartBubbleIcon.js +1 -1
- package/dist/icons/ChartDonut2Icon.js +1 -1
- package/dist/icons/ChartFunnelIcon.js +1 -1
- package/dist/icons/ChartHeatmapIcon.js +1 -1
- package/dist/icons/ChartKPIIcon.js +1 -1
- package/dist/icons/ChartPie2Icon.js +1 -1
- package/dist/icons/ChartScatterIcon.js +1 -1
- package/dist/icons/CheckCircleFilledIcon.js +1 -1
- package/dist/icons/CheckCircleIcon.js +1 -1
- package/dist/icons/CheckIcon.js +1 -1
- package/dist/icons/CircleFilledIcon.js +1 -1
- package/dist/icons/ClearIcon.js +1 -1
- package/dist/icons/CloseCircleFilledIcon.js +1 -1
- package/dist/icons/CloseCircleIcon.js +1 -1
- package/dist/icons/CloseIcon.js +1 -1
- package/dist/icons/CodeIcon.js +1 -1
- package/dist/icons/ColumnTotalIcon.js +1 -1
- package/dist/icons/CopyIcon.js +1 -1
- package/dist/icons/CountIcon.js +1 -1
- package/dist/icons/CubeIcon.js +1 -1
- package/dist/icons/CubePauseIcon.js +1 -1
- package/dist/icons/CubePlayIcon.js +1 -1
- package/dist/icons/CurrencyDollarIcon.js +1 -1
- package/dist/icons/DangerIcon.js +1 -1
- package/dist/icons/DashboardIcon.js +1 -1
- package/dist/icons/DatabaseIcon.js +1 -1
- package/dist/icons/DecimalDecreaseIcon.js +1 -1
- package/dist/icons/DecimalIncreaseIcon.js +1 -1
- package/dist/icons/DirectionIcon.js +1 -1
- package/dist/icons/DonutIcon.js +1 -1
- package/dist/icons/DownIcon.js +1 -1
- package/dist/icons/EditIcon.js +1 -1
- package/dist/icons/ExclamationCircleFilledIcon.js +1 -1
- package/dist/icons/ExclamationCircleIcon.js +1 -1
- package/dist/icons/ExclamationIcon.js +1 -1
- package/dist/icons/EyeIcon.js +1 -1
- package/dist/icons/EyeInvisibleIcon.js +1 -1
- package/dist/icons/FilterIcon.js +1 -1
- package/dist/icons/FolderFilledIcon.js +1 -1
- package/dist/icons/FolderIcon.js +1 -1
- package/dist/icons/FolderOpenFilledIcon.js +1 -1
- package/dist/icons/FolderOpenIcon.js +1 -1
- package/dist/icons/ForwardIcon.js +1 -1
- package/dist/icons/HierarchyIcon.js +1 -1
- package/dist/icons/HierarchyOpenIcon.js +1 -1
- package/dist/icons/Icon.js +1 -1
- package/dist/icons/InfoCircleIcon.js +1 -1
- package/dist/icons/InfoIcon.js +1 -1
- package/dist/icons/KeyIcon.js +1 -1
- package/dist/icons/LeftIcon.js +1 -1
- package/dist/icons/LineChartIcon.js +1 -1
- package/dist/icons/LoadingIcon.js +1 -1
- package/dist/icons/LockFilledIcon.js +1 -1
- package/dist/icons/LockIcon.js +1 -1
- package/dist/icons/MoreIcon.js +1 -1
- package/dist/icons/NotAllowedIcon.js +1 -1
- package/dist/icons/Number123Icon.js +1 -1
- package/dist/icons/NumberIcon.js +1 -1
- package/dist/icons/PauseCircleFilledIcon.js +1 -1
- package/dist/icons/PauseCircleIcon.js +1 -1
- package/dist/icons/PauseIcon.js +1 -1
- package/dist/icons/PercentageIcon.js +1 -1
- package/dist/icons/PieChartIcon.js +1 -1
- package/dist/icons/PlayCircleIcon.js +1 -1
- package/dist/icons/PlayIcon.js +1 -1
- package/dist/icons/PlusIcon.js +1 -1
- package/dist/icons/ProgressBarIcon.js +1 -1
- package/dist/icons/ReloadIcon.js +1 -1
- package/dist/icons/ReportIcon.js +1 -1
- package/dist/icons/ReturnIcon.js +1 -1
- package/dist/icons/RightIcon.js +1 -1
- package/dist/icons/RowTotalsIcon.js +1 -1
- package/dist/icons/SchemeIcon.js +1 -1
- package/dist/icons/SearchIcon.js +1 -1
- package/dist/icons/SemanticQueryIcon.js +1 -1
- package/dist/icons/SettingsIcon.js +1 -1
- package/dist/icons/ShieldFilledIcon.js +1 -1
- package/dist/icons/ShieldIcon.js +1 -1
- package/dist/icons/SlashIcon.js +1 -1
- package/dist/icons/SparklesIcon.js +1 -1
- package/dist/icons/SqlIcon.js +1 -1
- package/dist/icons/StatsIcon.js +1 -1
- package/dist/icons/StopIcon.js +1 -1
- package/dist/icons/StringIcon.js +1 -1
- package/dist/icons/SubtotalsIcon.js +1 -1
- package/dist/icons/SwitchIcon.js +1 -1
- package/dist/icons/TableIcon.js +1 -1
- package/dist/icons/ThumbsDownIcon.js +1 -1
- package/dist/icons/ThumbsUpIcon.js +1 -1
- package/dist/icons/ThunderboltCrossedIcon.js +1 -1
- package/dist/icons/ThunderboltFilledIcon.js +1 -1
- package/dist/icons/ThunderboltIcon.js +1 -1
- package/dist/icons/TimeIcon.js +1 -1
- package/dist/icons/TrashIcon.js +1 -1
- package/dist/icons/UnlockIcon.js +1 -1
- package/dist/icons/UpIcon.js +1 -1
- package/dist/icons/UserGroupIcon.js +1 -1
- package/dist/icons/UserIcon.js +1 -1
- package/dist/icons/UserLockIcon.js +1 -1
- package/dist/icons/ViewIcon.js +1 -1
- package/dist/icons/WarningFilledIcon.js +1 -1
- package/dist/icons/WarningIcon.js +1 -1
- package/dist/icons/wrap-icon.js +1 -1
- package/dist/index.d.ts +6 -4
- package/dist/index.js +7 -5
- package/dist/index.js.map +1 -1
- package/dist/provider.js +1 -1
- package/dist/providers/TrackingProvider.js +1 -1
- package/dist/providers/navigationAdapter.default.js +1 -1
- package/dist/tokens/base.js +1 -1
- package/dist/tokens/colors.js +1 -1
- package/dist/tokens/index.js +1 -1
- package/dist/tokens/layout.js +1 -1
- package/dist/tokens/shadows.js +1 -1
- package/dist/tokens/sizes.js +1 -1
- package/dist/tokens/spacing.js +1 -1
- package/dist/utils/ResizeSensor.js +1 -1
- package/dist/utils/is-dev-env.js +1 -1
- package/dist/utils/modules.js +1 -1
- package/dist/utils/promise.js +1 -1
- package/dist/utils/raf.js +1 -1
- package/dist/utils/random.js +1 -1
- package/dist/utils/range.js +1 -1
- package/dist/utils/react/RenderCache.js +1 -1
- package/dist/utils/react/Slots.js +1 -1
- package/dist/utils/react/chain.js +1 -1
- package/dist/utils/react/forwardRefWithGenerics.js +1 -1
- package/dist/utils/react/index.js +1 -1
- package/dist/utils/react/interactions.js +1 -1
- package/dist/utils/react/isTextOnly.js +1 -1
- package/dist/utils/react/mapProps.js +1 -1
- package/dist/utils/react/mergeProps.js +1 -1
- package/dist/utils/react/nullableValue.js +1 -1
- package/dist/utils/react/resolveIcon.js +1 -1
- package/dist/utils/react/sharedStore.js +1 -1
- package/dist/utils/react/useCombinedRefs.js +1 -1
- package/dist/utils/react/useControlledFocusVisible.js +1 -1
- package/dist/utils/react/useEventBus.js +1 -1
- package/dist/utils/react/useId.js +1 -1
- package/dist/utils/react/useIsDarwin.js +1 -1
- package/dist/utils/react/useKeySymbols.js +1 -1
- package/dist/utils/react/useLayoutEffect.js +1 -1
- package/dist/utils/react/useLocalStorage.js +1 -1
- package/dist/utils/react/useMergeStyles.js +1 -1
- package/dist/utils/react/useQaProps.js +1 -1
- package/dist/utils/react/useViewportSize.js +1 -1
- package/dist/utils/react/wrapNodeIfPlain.js +1 -1
- package/dist/utils/tree.js +1 -1
- package/dist/utils/warnings.js +1 -1
- package/dist/version.js +2 -2
- package/docs/BaseProperties.md +78 -0
- package/docs/ComplexLayout.md +459 -0
- package/docs/CreateComponent.md +410 -0
- package/docs/FieldProperties.md +117 -0
- package/docs/Introduction.md +122 -0
- package/docs/RenderCache.md +177 -0
- package/docs/Result.md +42 -0
- package/docs/SimpleLayout.md +26 -0
- package/docs/Typography.md +38 -0
- package/docs/components/Block.md +33 -0
- package/docs/components/CollectionItem.md +293 -0
- package/docs/components/GridProvider.md +38 -0
- package/docs/components/Root.md +50 -0
- package/docs/components/actions/Action.md +47 -0
- package/docs/components/actions/Banner.md +195 -0
- package/docs/components/actions/Button.md +209 -0
- package/docs/components/actions/ButtonGroup.md +46 -0
- package/docs/components/actions/ButtonSplit.md +199 -0
- package/docs/components/actions/CommandMenu.md +422 -0
- package/docs/components/actions/ItemAction.md +60 -0
- package/docs/components/actions/ItemButton.md +316 -0
- package/docs/components/actions/Link.md +325 -0
- package/docs/components/actions/Menu.md +485 -0
- package/docs/components/actions/MenuTrigger.md +47 -0
- package/docs/components/actions/SubMenuTrigger.md +38 -0
- package/docs/components/actions/use-anchored-menu.md +209 -0
- package/docs/components/actions/use-context-menu.md +218 -0
- package/docs/components/content/ActiveZone.md +37 -0
- package/docs/components/content/Alert.md +40 -0
- package/docs/components/content/Avatar.md +37 -0
- package/docs/components/content/Badge.md +194 -0
- package/docs/components/content/Card.md +40 -0
- package/docs/components/content/Content.md +44 -0
- package/docs/components/content/CopyPasteBlock.md +36 -0
- package/docs/components/content/CopySnippet.md +43 -0
- package/docs/components/content/Disclosure.md +181 -0
- package/docs/components/content/Divider.md +39 -0
- package/docs/components/content/Footer.md +35 -0
- package/docs/components/content/Header.md +35 -0
- package/docs/components/content/HotKeys.md +352 -0
- package/docs/components/content/Item.md +499 -0
- package/docs/components/content/ItemBadge.md +31 -0
- package/docs/components/content/ItemCard.md +131 -0
- package/docs/components/content/Layout.md +843 -0
- package/docs/components/content/Paragraph.md +32 -0
- package/docs/components/content/Placeholder.md +37 -0
- package/docs/components/content/PrismCode.md +36 -0
- package/docs/components/content/PrismDiffCode.md +29 -0
- package/docs/components/content/Result.md +46 -0
- package/docs/components/content/Skeleton.md +35 -0
- package/docs/components/content/Tag.md +165 -0
- package/docs/components/content/Text.md +54 -0
- package/docs/components/content/TextItem.md +217 -0
- package/docs/components/content/Title.md +45 -0
- package/docs/components/fields/Checkbox.md +176 -0
- package/docs/components/fields/ComboBox.md +651 -0
- package/docs/components/fields/DatePicker.md +227 -0
- package/docs/components/fields/FileInput.md +194 -0
- package/docs/components/fields/FilterListBox.md +726 -0
- package/docs/components/fields/FilterPicker.md +776 -0
- package/docs/components/fields/HueSlider.md +175 -0
- package/docs/components/fields/ListBox.md +714 -0
- package/docs/components/fields/NumberInput.md +180 -0
- package/docs/components/fields/PasswordInput.md +214 -0
- package/docs/components/fields/Picker.md +906 -0
- package/docs/components/fields/RadioGroup.md +310 -0
- package/docs/components/fields/SearchInput.md +224 -0
- package/docs/components/fields/Select.md +576 -0
- package/docs/components/fields/Slider.md +53 -0
- package/docs/components/fields/Switch.md +169 -0
- package/docs/components/fields/TextArea.md +61 -0
- package/docs/components/fields/TextInput.md +205 -0
- package/docs/components/fields/TextInputMapper.md +34 -0
- package/docs/components/form/Field.md +333 -0
- package/docs/components/form/Form.md +644 -0
- package/docs/components/form/FormInstance.md +307 -0
- package/docs/components/helpers/DisplayTransition.md +268 -0
- package/docs/components/helpers/IconSwitch.md +160 -0
- package/docs/components/layout/Flex.md +51 -0
- package/docs/components/layout/Flow.md +32 -0
- package/docs/components/layout/Grid.md +46 -0
- package/docs/components/layout/Panel.md +65 -0
- package/docs/components/layout/Prefix.md +37 -0
- package/docs/components/layout/ResizablePanel.md +69 -0
- package/docs/components/layout/Space.md +44 -0
- package/docs/components/layout/Suffix.md +39 -0
- package/docs/components/navigation/Tabs.md +726 -0
- package/docs/components/organisms/FileTabs.md +39 -0
- package/docs/components/organisms/StatsCard.md +40 -0
- package/docs/components/other/CloudLogo.md +33 -0
- package/docs/components/overlays/AlertDialog.md +51 -0
- package/docs/components/overlays/Dialog.md +200 -0
- package/docs/components/overlays/DialogContainer.md +201 -0
- package/docs/components/overlays/DialogForm.md +295 -0
- package/docs/components/overlays/DialogTrigger.md +191 -0
- package/docs/components/overlays/Notifications.md +402 -0
- package/docs/components/overlays/Toast.md +289 -0
- package/docs/components/overlays/Tooltip.md +400 -0
- package/docs/components/overlays/TooltipProvider.md +42 -0
- package/docs/components/overlays/TooltipTrigger.md +42 -0
- package/docs/components/overlays/UseDialogContainer.md +597 -0
- package/docs/components/portal/Portal.md +29 -0
- package/docs/components/status/LoadingAnimation.md +27 -0
- package/docs/components/status/Spin.md +35 -0
- package/docs/tasty/configuration.md +211 -0
- package/docs/tasty/debug.md +505 -0
- package/docs/tasty/injector.md +528 -0
- package/docs/tasty/styles.md +567 -0
- package/docs/tasty/tasty-static.md +376 -0
- package/docs/tasty/usage.md +643 -0
- package/package.json +5 -9
|
@@ -0,0 +1,194 @@
|
|
|
1
|
+
# Badge
|
|
2
|
+
|
|
3
|
+
Badges are small, circular indicators that display numerical counts or short status text. They are typically used to draw attention to new, updated, or important information.
|
|
4
|
+
|
|
5
|
+
## When to Use
|
|
6
|
+
|
|
7
|
+
- **Notification counts**: Show unread messages, notifications, or pending items
|
|
8
|
+
- **Status indicators**: Display simple status like "NEW", "HOT", or error counts
|
|
9
|
+
- **Numerical data**: Show counts, quantities, or metrics at a glance
|
|
10
|
+
- **Activity indicators**: Highlight areas with recent activity or updates
|
|
11
|
+
- **Completion tracking**: Display progress counts (e.g., "3/10")
|
|
12
|
+
|
|
13
|
+
## When Not to Use
|
|
14
|
+
|
|
15
|
+
- **Long text**: Use `Tag` for longer labels or categorization
|
|
16
|
+
- **Interactive elements**: Use `Button` for clickable actions
|
|
17
|
+
- **Detailed information**: Use `Tooltip` or expanded content for complex details
|
|
18
|
+
- **Navigation**: Use `Button` or `Link` for navigation purposes
|
|
19
|
+
|
|
20
|
+
## Component
|
|
21
|
+
|
|
22
|
+
---
|
|
23
|
+
|
|
24
|
+
### Properties
|
|
25
|
+
|
|
26
|
+
- **`children`** `ReactNode` — Badge content (typically a number or short text)
|
|
27
|
+
- **`icon`** `ReactNode` — Icon to display before the badge content
|
|
28
|
+
- **`rightIcon`** `ReactNode` — Icon to display after the badge content
|
|
29
|
+
- **`theme`** `'special' | 'danger' | 'success' | 'warning' | 'note' | 'disabled'` (default: `special`) — Visual theme of the badge
|
|
30
|
+
- **`type`** `string` — Deprecated: Use theme instead
|
|
31
|
+
- **`size`** `string` (default: `inline`) — Size of the badge
|
|
32
|
+
|
|
33
|
+
### Base Properties
|
|
34
|
+
|
|
35
|
+
Badge extends from `Item` component and supports all base design system properties including:
|
|
36
|
+
- Layout props: `width`, `height`, `margin`, `padding`
|
|
37
|
+
- Color props: `fill`, `color`, `border`
|
|
38
|
+
- Typography props: `preset`, `fontSize`, `fontWeight`
|
|
39
|
+
- Other Item props: `tooltip`, `isDisabled`, `qa`
|
|
40
|
+
|
|
41
|
+
## Examples
|
|
42
|
+
|
|
43
|
+
### Themes
|
|
44
|
+
|
|
45
|
+
Badges support multiple themes for different semantic meanings:
|
|
46
|
+
|
|
47
|
+
Available themes:
|
|
48
|
+
- **Special** (default): Purple background, highlighted features
|
|
49
|
+
- **Warning**: Yellow/amber background, caution or attention needed
|
|
50
|
+
- **Note**: Violet background, informational content
|
|
51
|
+
- **Success**: Green background, positive states
|
|
52
|
+
- **Danger**: Red background, errors or urgent items
|
|
53
|
+
- **Disabled**: Gray background, inactive items
|
|
54
|
+
|
|
55
|
+
### Numbers
|
|
56
|
+
|
|
57
|
+
Badges commonly display numerical counts:
|
|
58
|
+
|
|
59
|
+
Best practices for numbers:
|
|
60
|
+
- Use single digits for small counts (1-9)
|
|
61
|
+
- Show exact numbers up to 99
|
|
62
|
+
- Consider "99+" format for counts over 99
|
|
63
|
+
- Keep numerical badges concise and scannable
|
|
64
|
+
|
|
65
|
+
```jsx
|
|
66
|
+
<Badge>5</Badge>
|
|
67
|
+
<Badge>99</Badge>
|
|
68
|
+
<Badge theme="danger">12</Badge>
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
### Text Content
|
|
72
|
+
|
|
73
|
+
Short text labels work well in badges:
|
|
74
|
+
|
|
75
|
+
Guidelines for text badges:
|
|
76
|
+
- Keep text to 2-4 characters maximum
|
|
77
|
+
- Use uppercase for better readability
|
|
78
|
+
- Common patterns: "NEW", "HOT", "BETA", "PRO"
|
|
79
|
+
|
|
80
|
+
```jsx
|
|
81
|
+
<Badge>NEW</Badge>
|
|
82
|
+
<Badge theme="success">OK</Badge>
|
|
83
|
+
<Badge theme="danger">ERR</Badge>
|
|
84
|
+
```
|
|
85
|
+
|
|
86
|
+
### Sizes
|
|
87
|
+
|
|
88
|
+
Badges support multiple sizes inherited from the Item component:
|
|
89
|
+
|
|
90
|
+
- **inline** (default): Compact, inline badge optimized for text flow
|
|
91
|
+
- **xsmall**: Extra small size
|
|
92
|
+
- **small**: Small size
|
|
93
|
+
- **medium**: Medium size
|
|
94
|
+
- **large**: Large size
|
|
95
|
+
- **xlarge**: Extra large size
|
|
96
|
+
|
|
97
|
+
### With Icons
|
|
98
|
+
|
|
99
|
+
Badges can include icons for additional visual context:
|
|
100
|
+
|
|
101
|
+
Add an icon before the badge content using the `icon` prop:
|
|
102
|
+
|
|
103
|
+
```jsx
|
|
104
|
+
import { IconCoin } from '@tabler/icons-react';
|
|
105
|
+
|
|
106
|
+
<Badge icon={<IconCoin />} theme="success">
|
|
107
|
+
12
|
|
108
|
+
</Badge>
|
|
109
|
+
```
|
|
110
|
+
|
|
111
|
+
### With Right Icon
|
|
112
|
+
|
|
113
|
+
Place icons after the content using the `rightIcon` prop:
|
|
114
|
+
|
|
115
|
+
```jsx
|
|
116
|
+
<Badge rightIcon={<IconCoin />} theme="danger">
|
|
117
|
+
ERR
|
|
118
|
+
</Badge>
|
|
119
|
+
```
|
|
120
|
+
|
|
121
|
+
### With Both Icons
|
|
122
|
+
|
|
123
|
+
Combine both `icon` and `rightIcon` for complex layouts:
|
|
124
|
+
|
|
125
|
+
```jsx
|
|
126
|
+
<Badge icon={<IconCoin />} rightIcon={<IconCoin />} theme="success">
|
|
127
|
+
NEW
|
|
128
|
+
</Badge>
|
|
129
|
+
```
|
|
130
|
+
|
|
131
|
+
## Best Practices
|
|
132
|
+
|
|
133
|
+
### Content
|
|
134
|
+
|
|
135
|
+
- Keep badge content concise and scannable
|
|
136
|
+
- Use numbers for counts ("3" not "three")
|
|
137
|
+
- Use uppercase for text badges for better readability
|
|
138
|
+
- Consider "99+" format for very large counts
|
|
139
|
+
|
|
140
|
+
### Placement
|
|
141
|
+
|
|
142
|
+
- Position badges near related content without obscuring it
|
|
143
|
+
- Maintain consistent positioning across similar contexts
|
|
144
|
+
|
|
145
|
+
### Visual Design
|
|
146
|
+
|
|
147
|
+
- Use theme colors consistently for semantic meaning
|
|
148
|
+
- Ensure adequate spacing from surrounding content
|
|
149
|
+
|
|
150
|
+
### Accessibility
|
|
151
|
+
|
|
152
|
+
- Provide context for counts via tooltips when needed
|
|
153
|
+
- Don't rely solely on color to convey meaning
|
|
154
|
+
- All themes maintain sufficient color contrast
|
|
155
|
+
|
|
156
|
+
## Use Cases
|
|
157
|
+
|
|
158
|
+
### Navigation Badges
|
|
159
|
+
|
|
160
|
+
Display notification counts on menu items:
|
|
161
|
+
|
|
162
|
+
```jsx
|
|
163
|
+
<Item icon={<IconBell />}>
|
|
164
|
+
Notifications
|
|
165
|
+
<Badge theme="danger">5</Badge>
|
|
166
|
+
</Item>
|
|
167
|
+
```
|
|
168
|
+
|
|
169
|
+
### Status Indicators
|
|
170
|
+
|
|
171
|
+
Show item status or state:
|
|
172
|
+
|
|
173
|
+
```jsx
|
|
174
|
+
<Item>
|
|
175
|
+
Beta Feature <Badge theme="special">BETA</Badge>
|
|
176
|
+
</Item>
|
|
177
|
+
```
|
|
178
|
+
|
|
179
|
+
### Inline Counts
|
|
180
|
+
|
|
181
|
+
Display counts within text:
|
|
182
|
+
|
|
183
|
+
```jsx
|
|
184
|
+
<Text>
|
|
185
|
+
Unread Messages <Badge>12</Badge>
|
|
186
|
+
</Text>
|
|
187
|
+
```
|
|
188
|
+
|
|
189
|
+
## Related Components
|
|
190
|
+
|
|
191
|
+
- **Tag**: For longer labels, categorization, or closable elements
|
|
192
|
+
- **Chip**: For interactive selection chips
|
|
193
|
+
- **Item**: Base component that Badge extends from
|
|
194
|
+
- **Text**: For displaying badge content inline with text
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
# Card
|
|
2
|
+
|
|
3
|
+
A container with rounded corners, border, and padding. Renders as a `<div role="region">`.
|
|
4
|
+
|
|
5
|
+
## When to Use
|
|
6
|
+
|
|
7
|
+
- Grouping related information
|
|
8
|
+
- Content containers in dashboards
|
|
9
|
+
- Highlighting standalone content blocks
|
|
10
|
+
|
|
11
|
+
## Properties
|
|
12
|
+
|
|
13
|
+
No component-specific props. Use style props directly.
|
|
14
|
+
|
|
15
|
+
### Style Defaults
|
|
16
|
+
|
|
17
|
+
- `display` — `block`
|
|
18
|
+
- `flow` — `column`
|
|
19
|
+
- `radius` — `(1cr + 1bw)`
|
|
20
|
+
- `fill` — `#white`
|
|
21
|
+
- `border` — `#border`
|
|
22
|
+
- `padding` — `1.5x`
|
|
23
|
+
- `preset` — `t3`
|
|
24
|
+
|
|
25
|
+
### Base Properties
|
|
26
|
+
|
|
27
|
+
Supports [Base properties](../../BaseProperties.md).
|
|
28
|
+
|
|
29
|
+
## Examples
|
|
30
|
+
|
|
31
|
+
```jsx
|
|
32
|
+
<Card>
|
|
33
|
+
<Title level={3}>Card Title</Title>
|
|
34
|
+
<Paragraph>Card content goes here.</Paragraph>
|
|
35
|
+
</Card>
|
|
36
|
+
|
|
37
|
+
<Card padding="2x" fill="#surface">
|
|
38
|
+
Styled card with custom padding and background
|
|
39
|
+
</Card>
|
|
40
|
+
```
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
# Content
|
|
2
|
+
|
|
3
|
+
A scrollable content section for page layouts. Renders as `<section>` and is designed to work with `Layout`.
|
|
4
|
+
|
|
5
|
+
## When to Use
|
|
6
|
+
|
|
7
|
+
- Main content area in app layouts
|
|
8
|
+
- Scrollable body sections
|
|
9
|
+
- Content that flows with `Layout` header/footer
|
|
10
|
+
|
|
11
|
+
## Properties
|
|
12
|
+
|
|
13
|
+
No component-specific props. Use style props directly.
|
|
14
|
+
|
|
15
|
+
### Style Defaults
|
|
16
|
+
|
|
17
|
+
- `display` — `block`
|
|
18
|
+
- `flow` — `column`
|
|
19
|
+
- `gap` — `2x`
|
|
20
|
+
- `preset` — `p3`
|
|
21
|
+
- `color` — `#dark-02`
|
|
22
|
+
- `overflow` — `auto`
|
|
23
|
+
- `scrollbar` — `styled`
|
|
24
|
+
- `gridArea` — `content`
|
|
25
|
+
|
|
26
|
+
### Base Properties
|
|
27
|
+
|
|
28
|
+
Supports [Base properties](../../BaseProperties.md).
|
|
29
|
+
|
|
30
|
+
## Examples
|
|
31
|
+
|
|
32
|
+
```jsx
|
|
33
|
+
<Layout>
|
|
34
|
+
<Layout.Header>
|
|
35
|
+
<Title level={3}>Page Title</Title>
|
|
36
|
+
</Layout.Header>
|
|
37
|
+
<Layout.Content>
|
|
38
|
+
<Paragraph>Main page content goes here.</Paragraph>
|
|
39
|
+
</Layout.Content>
|
|
40
|
+
<Layout.Footer>
|
|
41
|
+
<Text>Footer</Text>
|
|
42
|
+
</Layout.Footer>
|
|
43
|
+
</Layout>
|
|
44
|
+
```
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
# CopyPasteBlock
|
|
2
|
+
|
|
3
|
+
A block that displays a value with copy-to-clipboard functionality. Supports paste via click/focus.
|
|
4
|
+
|
|
5
|
+
## When to Use
|
|
6
|
+
|
|
7
|
+
- API keys or tokens display
|
|
8
|
+
- One-time codes or passwords
|
|
9
|
+
- Values users need to copy or paste
|
|
10
|
+
|
|
11
|
+
## Properties
|
|
12
|
+
|
|
13
|
+
- **`title`** `string` — Label for the block
|
|
14
|
+
- **`value`** `string` (default: `''`) — The value to display and copy
|
|
15
|
+
- **`placeholder`** `ReactNode` — Placeholder when value is empty
|
|
16
|
+
- **`size`** `'small' | 'medium' | 'large'` (default: `'medium'`) — Block size
|
|
17
|
+
|
|
18
|
+
### Style Defaults
|
|
19
|
+
|
|
20
|
+
- `fill` — `#dark-bg`
|
|
21
|
+
- `radius` — `1r`
|
|
22
|
+
- `cursor` — pointer
|
|
23
|
+
- `preset` — `t3` (switches to `t2` when `size="large"`)
|
|
24
|
+
- `height` — `5x` (`4x` for small, `6x` for large)
|
|
25
|
+
|
|
26
|
+
### Base Properties
|
|
27
|
+
|
|
28
|
+
Supports [Base properties](../../BaseProperties.md).
|
|
29
|
+
|
|
30
|
+
## Examples
|
|
31
|
+
|
|
32
|
+
```jsx
|
|
33
|
+
<CopyPasteBlock title="API Key" value={apiKey} />
|
|
34
|
+
|
|
35
|
+
<CopyPasteBlock title="Token" value={token} size="small" />
|
|
36
|
+
```
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
# CopySnippet
|
|
2
|
+
|
|
3
|
+
A code block with copy-to-clipboard functionality and syntax highlighting. Extends `Card`.
|
|
4
|
+
|
|
5
|
+
## When to Use
|
|
6
|
+
|
|
7
|
+
- Documentation code examples
|
|
8
|
+
- API response displays
|
|
9
|
+
- Sharing code snippets with copy functionality
|
|
10
|
+
|
|
11
|
+
## Properties
|
|
12
|
+
|
|
13
|
+
- **`code`** `string` (default: `''`) — The code to display
|
|
14
|
+
- **`language`** `string` (default: `'javascript'`) — Syntax highlighting language
|
|
15
|
+
- **`title`** `string` (default: `'Code example'`) — Accessible title
|
|
16
|
+
- **`prefix`** `string` (default: `''`) — Prefix text (e.g. `$`)
|
|
17
|
+
- **`multiline`** `boolean` — Allow multiline display
|
|
18
|
+
- **`nowrap`** `boolean` — Prevent line wrapping
|
|
19
|
+
- **`showTooltip`** `boolean` (default: `false`) — Show tooltip on hover
|
|
20
|
+
|
|
21
|
+
### Style Defaults
|
|
22
|
+
|
|
23
|
+
- `fill` — `#dark-bg`
|
|
24
|
+
- `border` — `0`
|
|
25
|
+
- `radius` — `1r`
|
|
26
|
+
- `padding` — `0`
|
|
27
|
+
- `preset` — `default`
|
|
28
|
+
|
|
29
|
+
### Base Properties
|
|
30
|
+
|
|
31
|
+
Supports [Base properties](../../BaseProperties.md).
|
|
32
|
+
|
|
33
|
+
## Examples
|
|
34
|
+
|
|
35
|
+
```jsx
|
|
36
|
+
<CopySnippet code="const x = 1;" language="javascript" />
|
|
37
|
+
|
|
38
|
+
<CopySnippet
|
|
39
|
+
code={'{\n "key": "value"\n}'}
|
|
40
|
+
language="json"
|
|
41
|
+
multiline
|
|
42
|
+
/>
|
|
43
|
+
```
|
|
@@ -0,0 +1,181 @@
|
|
|
1
|
+
# Disclosure
|
|
2
|
+
|
|
3
|
+
An accessible collapsible container that reveals or hides additional content. Built on React Aria's `useDisclosure` hook, it provides keyboard navigation, screen reader support, and smooth height animations. Supports both standalone usage and grouped accordion behavior.
|
|
4
|
+
|
|
5
|
+
## When to Use
|
|
6
|
+
|
|
7
|
+
- For FAQ sections where users can expand answers to questions
|
|
8
|
+
- To hide supplementary information that shouldn't overwhelm the main content
|
|
9
|
+
- For accordion-style navigation or settings panels
|
|
10
|
+
- When you need collapsible sections with consistent accessibility patterns
|
|
11
|
+
- To progressively disclose complex information
|
|
12
|
+
|
|
13
|
+
## Component
|
|
14
|
+
|
|
15
|
+
---
|
|
16
|
+
|
|
17
|
+
### Properties
|
|
18
|
+
|
|
19
|
+
- **`isExpanded`** `boolean` — Controls expanded state in controlled mode
|
|
20
|
+
- **`defaultExpanded`** `boolean` (default: `false`) — Initial expanded state in uncontrolled mode
|
|
21
|
+
- **`onExpandedChange`** `(isExpanded: boolean) => void` — Callback fired when expanded state changes
|
|
22
|
+
- **`isDisabled`** `boolean` (default: `false`) — Disables trigger interactions and force-closes the content
|
|
23
|
+
- **`shape`** `'default' | 'card' | 'sharp'` (default: `default`) — Visual shape variant: default (no styling), card (border/radius), sharp (radius 0)
|
|
24
|
+
- **`transitionDuration`** `number` — Duration for DisplayTransition animation in milliseconds. When undefined, uses default CSS transition timing
|
|
25
|
+
- **`children`** `ReactNode | ((state: DisclosureStateContext) => ReactNode)` — Disclosure.Trigger and Disclosure.Content components
|
|
26
|
+
|
|
27
|
+
### Base Properties
|
|
28
|
+
|
|
29
|
+
Supports [Base properties](../../BaseProperties.md)
|
|
30
|
+
|
|
31
|
+
## Compound Components
|
|
32
|
+
|
|
33
|
+
### Disclosure.Trigger
|
|
34
|
+
|
|
35
|
+
The clickable button that toggles the disclosure. Built on `ItemButton` and accepts all ItemButton props including `icon`, `type`, `theme`, `size`, and more.
|
|
36
|
+
|
|
37
|
+
### Disclosure.Content
|
|
38
|
+
|
|
39
|
+
The collapsible panel containing the hidden content. Animates smoothly using CSS `interpolate-size: allow-keywords` for height transitions.
|
|
40
|
+
|
|
41
|
+
### Disclosure.Group
|
|
42
|
+
|
|
43
|
+
Container for multiple disclosure items that coordinates their expanded states. By default, only one item can be expanded at a time (accordion behavior).
|
|
44
|
+
|
|
45
|
+
### Disclosure.Item
|
|
46
|
+
|
|
47
|
+
Individual disclosure within a group. Must have a unique `id` prop when used inside `Disclosure.Group`.
|
|
48
|
+
|
|
49
|
+
## Styling
|
|
50
|
+
|
|
51
|
+
### styles
|
|
52
|
+
|
|
53
|
+
Customizes the root element of the Disclosure component.
|
|
54
|
+
|
|
55
|
+
### triggerStyles
|
|
56
|
+
|
|
57
|
+
When using `Disclosure.Trigger`, you can pass `styles` prop to customize the trigger button.
|
|
58
|
+
|
|
59
|
+
### contentStyles
|
|
60
|
+
|
|
61
|
+
When using `Disclosure.Content`, you can pass `styles` prop to customize the content panel.
|
|
62
|
+
|
|
63
|
+
### Group-level Styling
|
|
64
|
+
|
|
65
|
+
`Disclosure.Group` accepts `triggerProps` to apply consistent props to all triggers, and `contentStyles` to style all content panels uniformly.
|
|
66
|
+
|
|
67
|
+
### Style Properties
|
|
68
|
+
|
|
69
|
+
Direct style application without using the `styles` prop: `width`, `height`, `padding`, `margin`, `gap`.
|
|
70
|
+
|
|
71
|
+
### Modifiers
|
|
72
|
+
|
|
73
|
+
The `mods` property accepts the following modifiers:
|
|
74
|
+
|
|
75
|
+
- **`expanded`** `boolean` — True when the disclosure content is visible
|
|
76
|
+
- **`disabled`** `boolean` — True when interactions are disabled
|
|
77
|
+
- **`shape`** `string` — The current shape variant (`default`, `card`, `sharp`)
|
|
78
|
+
|
|
79
|
+
For `Disclosure.Content`, additional modifiers are available:
|
|
80
|
+
|
|
81
|
+
- **`shown`** `boolean` — True when content is visible (controls height animation)
|
|
82
|
+
- **`phase`** `string` — Transition phase (`enter`, `entered`, `exit`, `unmounted`)
|
|
83
|
+
|
|
84
|
+
## Variants
|
|
85
|
+
|
|
86
|
+
### Shapes
|
|
87
|
+
|
|
88
|
+
#### Card
|
|
89
|
+
|
|
90
|
+
Bordered container with rounded corners.
|
|
91
|
+
|
|
92
|
+
#### Sharp
|
|
93
|
+
|
|
94
|
+
Sharp edges with no border radius.
|
|
95
|
+
|
|
96
|
+
## Examples
|
|
97
|
+
|
|
98
|
+
### Default Expanded
|
|
99
|
+
|
|
100
|
+
Disclosure that starts in expanded state using `defaultExpanded` prop.
|
|
101
|
+
|
|
102
|
+
### Disabled
|
|
103
|
+
|
|
104
|
+
Disabled disclosure that cannot be toggled.
|
|
105
|
+
|
|
106
|
+
### Controlled State
|
|
107
|
+
|
|
108
|
+
Control the disclosure state externally with `isExpanded` and `onExpandedChange`.
|
|
109
|
+
|
|
110
|
+
### Multiple Expanded Items
|
|
111
|
+
|
|
112
|
+
Group with `allowsMultipleExpanded` where multiple items can be open simultaneously.
|
|
113
|
+
|
|
114
|
+
### Default Expanded Keys
|
|
115
|
+
|
|
116
|
+
Group with specific items pre-expanded via `defaultExpandedKeys`.
|
|
117
|
+
|
|
118
|
+
### Custom Trigger with Render Prop
|
|
119
|
+
|
|
120
|
+
Use render prop pattern to create custom triggers with access to `isExpanded` and `toggle`.
|
|
121
|
+
|
|
122
|
+
### Disabled Group
|
|
123
|
+
|
|
124
|
+
Group-level `isDisabled` that disables all items at once.
|
|
125
|
+
|
|
126
|
+
### Nested Disclosures
|
|
127
|
+
|
|
128
|
+
Disclosures can be nested, each maintaining independent state.
|
|
129
|
+
|
|
130
|
+
## Accessibility
|
|
131
|
+
|
|
132
|
+
### Keyboard Navigation
|
|
133
|
+
|
|
134
|
+
- `Tab` - Moves focus to the disclosure trigger
|
|
135
|
+
- `Space` / `Enter` - Toggles the disclosure open/closed
|
|
136
|
+
- `Tab` (when expanded) - Moves focus into the content panel
|
|
137
|
+
|
|
138
|
+
### Screen Reader Support
|
|
139
|
+
|
|
140
|
+
- Trigger announces as a button with expanded/collapsed state
|
|
141
|
+
- `aria-expanded` is automatically managed by React Aria
|
|
142
|
+
- `aria-controls` links trigger to content panel automatically
|
|
143
|
+
- State changes are announced when toggling
|
|
144
|
+
|
|
145
|
+
### ARIA Properties
|
|
146
|
+
|
|
147
|
+
- `aria-expanded` - Indicates whether content is visible (managed automatically)
|
|
148
|
+
- `aria-controls` - Links trigger to panel (managed automatically)
|
|
149
|
+
- `aria-disabled` - Applied when `isDisabled` is true
|
|
150
|
+
|
|
151
|
+
## Best Practices
|
|
152
|
+
|
|
153
|
+
1. **Do**: Provide clear, descriptive trigger labels
|
|
154
|
+
|
|
155
|
+
```jsx
|
|
156
|
+
<Disclosure.Trigger>View shipping details</Disclosure.Trigger>
|
|
157
|
+
```
|
|
158
|
+
|
|
159
|
+
2. **Don't**: Use vague or icon-only triggers without labels
|
|
160
|
+
|
|
161
|
+
```jsx
|
|
162
|
+
<Disclosure.Trigger>+</Disclosure.Trigger>
|
|
163
|
+
```
|
|
164
|
+
|
|
165
|
+
3. **Do**: Use groups for related collapsible sections
|
|
166
|
+
|
|
167
|
+
```jsx
|
|
168
|
+
<Disclosure.Group>
|
|
169
|
+
<Disclosure.Item id="billing">...</Disclosure.Item>
|
|
170
|
+
<Disclosure.Item id="shipping">...</Disclosure.Item>
|
|
171
|
+
</Disclosure.Group>
|
|
172
|
+
```
|
|
173
|
+
|
|
174
|
+
4. **Accessibility**: Always ensure trigger text clearly indicates what will be revealed
|
|
175
|
+
|
|
176
|
+
5. **Performance**: Content remains mounted during transitions for smooth animations and accessibility
|
|
177
|
+
|
|
178
|
+
## Related Components
|
|
179
|
+
|
|
180
|
+
- [ItemButton](../actions/ItemButton.md) - The base component used for triggers
|
|
181
|
+
- [DisplayTransition](../helpers/DisplayTransition.md) - Manages animation phases
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
# Divider
|
|
2
|
+
|
|
3
|
+
A horizontal separator. Can be a simple line or include centered text with lines on both sides.
|
|
4
|
+
|
|
5
|
+
## When to Use
|
|
6
|
+
|
|
7
|
+
- Separating sections of content
|
|
8
|
+
- Dividing list items or form sections
|
|
9
|
+
- "Or" or other labels between content blocks
|
|
10
|
+
|
|
11
|
+
## Properties
|
|
12
|
+
|
|
13
|
+
- **`children`** `ReactNode` — Optional text to display centered between two lines
|
|
14
|
+
|
|
15
|
+
### Style Defaults
|
|
16
|
+
|
|
17
|
+
- `display` — `block` (switches to `grid` when text is present)
|
|
18
|
+
- `height` — `1bw` (switches to `auto` when text is present)
|
|
19
|
+
- `fill` — `#border` (switches to `none` when text is present)
|
|
20
|
+
- `preset` — `c1`
|
|
21
|
+
- `gridArea` — `divider`
|
|
22
|
+
|
|
23
|
+
### Base Properties
|
|
24
|
+
|
|
25
|
+
Supports [Base properties](../../BaseProperties.md).
|
|
26
|
+
|
|
27
|
+
## Examples
|
|
28
|
+
|
|
29
|
+
```jsx
|
|
30
|
+
<Divider />
|
|
31
|
+
|
|
32
|
+
<Divider>or</Divider>
|
|
33
|
+
|
|
34
|
+
<Flow gap="1x">
|
|
35
|
+
<Paragraph>Section 1</Paragraph>
|
|
36
|
+
<Divider />
|
|
37
|
+
<Paragraph>Section 2</Paragraph>
|
|
38
|
+
</Flow>
|
|
39
|
+
```
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
# Footer
|
|
2
|
+
|
|
3
|
+
A footer section for page layouts. Designed to work with `Layout`.
|
|
4
|
+
|
|
5
|
+
## When to Use
|
|
6
|
+
|
|
7
|
+
- Page footers with links or copyright
|
|
8
|
+
- Bottom bar of application layouts
|
|
9
|
+
- Action bars at the bottom of modals or panels
|
|
10
|
+
|
|
11
|
+
## Properties
|
|
12
|
+
|
|
13
|
+
No component-specific props. Use style props directly.
|
|
14
|
+
|
|
15
|
+
### Style Defaults
|
|
16
|
+
|
|
17
|
+
- `display` — `block`
|
|
18
|
+
- `flow` — `column`
|
|
19
|
+
- `gridArea` — `footer`
|
|
20
|
+
|
|
21
|
+
### Base Properties
|
|
22
|
+
|
|
23
|
+
Supports [Base properties](../../BaseProperties.md).
|
|
24
|
+
|
|
25
|
+
## Examples
|
|
26
|
+
|
|
27
|
+
```jsx
|
|
28
|
+
<Layout>
|
|
29
|
+
<Layout.Header>...</Layout.Header>
|
|
30
|
+
<Layout.Content>...</Layout.Content>
|
|
31
|
+
<Layout.Footer>
|
|
32
|
+
<Text.Minor>© 2024 Company</Text.Minor>
|
|
33
|
+
</Layout.Footer>
|
|
34
|
+
</Layout>
|
|
35
|
+
```
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
# Header
|
|
2
|
+
|
|
3
|
+
A header section for page layouts. Renders as `<header>` and is designed to work with `Layout`.
|
|
4
|
+
|
|
5
|
+
## When to Use
|
|
6
|
+
|
|
7
|
+
- Page headers with title and actions
|
|
8
|
+
- Section headers in layouts
|
|
9
|
+
- Top bar of application layouts
|
|
10
|
+
|
|
11
|
+
## Properties
|
|
12
|
+
|
|
13
|
+
No component-specific props. Use style props directly.
|
|
14
|
+
|
|
15
|
+
### Style Defaults
|
|
16
|
+
|
|
17
|
+
- `display` — `block`
|
|
18
|
+
- `flow` — `column`
|
|
19
|
+
- `gridArea` — `header`
|
|
20
|
+
|
|
21
|
+
### Base Properties
|
|
22
|
+
|
|
23
|
+
Supports [Base properties](../../BaseProperties.md).
|
|
24
|
+
|
|
25
|
+
## Examples
|
|
26
|
+
|
|
27
|
+
```jsx
|
|
28
|
+
<Layout>
|
|
29
|
+
<Layout.Header>
|
|
30
|
+
<Title level={3}>Dashboard</Title>
|
|
31
|
+
<Button>Settings</Button>
|
|
32
|
+
</Layout.Header>
|
|
33
|
+
<Layout.Content>...</Layout.Content>
|
|
34
|
+
</Layout>
|
|
35
|
+
```
|