@cube-dev/ui-kit 0.0.0-canary-d8e2a5f → 0.0.0-canary-d03ae24
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/dist/CHANGELOG.md +19 -0
- package/dist/README.md +1 -1
- 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.js +1 -1
- package/dist/components/actions/ButtonGroup/ButtonGroup.js +1 -1
- package/dist/components/actions/ButtonSplit/ButtonSplit.js +1 -1
- package/dist/components/actions/ButtonSplit/context.js +1 -1
- 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.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.js +1 -1
- package/dist/components/actions/use-action.js +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 +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 +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/InlineInput/InlineInput.js +1 -1
- package/dist/components/content/Item/Item.js +1 -1
- package/dist/components/content/ItemBadge/ItemBadge.js +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 +1 -1
- package/dist/components/content/Text.d.ts +7 -7
- 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/Tree/Tree.js +1 -1
- package/dist/components/content/Tree/TreeNode.js +1 -1
- package/dist/components/content/Tree/styled.js +1 -1
- package/dist/components/content/Tree/tree-index.js +1 -1
- package/dist/components/content/Tree/use-checkbox-tree.js +1 -1
- package/dist/components/content/Tree/use-load-data.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/CommandTextArea/CommandTextArea.js +1 -1
- package/dist/components/fields/CommandTextArea/caretPosition.js +1 -1
- package/dist/components/fields/CommandTextArea/useCaretAnchor.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 +1 -1
- package/dist/components/fields/Input/Input.js +1 -1
- package/dist/components/fields/ListBox/DraggableListBox.js +1 -1
- package/dist/components/fields/ListBox/ListBox.js +1 -1
- package/dist/components/fields/ListBoxPopover/ListBoxPopover.js +1 -1
- package/dist/components/fields/ListBoxPopover/listNavigation.js +1 -1
- package/dist/components/fields/ListBoxPopover/useCompositeFocus.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 +1 -1
- package/dist/components/fields/RadioGroup/Radio.js +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.js +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/Board/Board.js +1 -1
- package/dist/components/layout/Board/BoardProvider.js +1 -1
- package/dist/components/layout/Board/BoardResponsive.js +1 -1
- package/dist/components/layout/Board/Widget.js +1 -1
- package/dist/components/layout/Board/WidgetHost.js +1 -1
- package/dist/components/layout/Board/board-context.js +1 -1
- package/dist/components/layout/Board/board-store.js +1 -1
- package/dist/components/layout/Board/grid-core/calculate.js +1 -1
- package/dist/components/layout/Board/grid-core/collision.js +1 -1
- package/dist/components/layout/Board/grid-core/compactors.js +1 -1
- package/dist/components/layout/Board/grid-core/constraints.js +1 -1
- package/dist/components/layout/Board/grid-core/layout.js +1 -1
- package/dist/components/layout/Board/grid-core/sort.js +1 -1
- package/dist/components/layout/Board/index.js +1 -1
- package/dist/components/layout/Board/responsive-utils.js +1 -1
- package/dist/components/layout/Board/use-board-layout.js +1 -1
- package/dist/components/layout/Board/use-board-registry.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/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 +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/popover-placement.js +1 -1
- package/dist/components/navigation/Tabs/styled.js +1 -1
- package/dist/components/navigation/Tabs/types.js +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 +1 -1
- 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/OpenTransitionContext.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/DraggableCollection.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 +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/GripVerticalIcon.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.js +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 -2
- package/dist/tokens/colors.js.map +1 -1
- package/dist/tokens/index.js +1 -1
- package/dist/tokens/layout.js +1 -1
- package/dist/tokens/palette.js +105 -105
- package/dist/tokens/palette.js.map +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/tokens/typography.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/usePopoverSync.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/selection.js +1 -1
- package/dist/utils/styles.js +1 -1
- package/dist/utils/tree.js +1 -1
- package/dist/utils/warnings.js +1 -1
- package/dist/version.js +3 -3
- package/docs/glaze/api.md +510 -150
- package/docs/glaze/methodology.md +438 -213
- package/docs/glaze/migration.md +152 -14
- package/docs/glaze/okhst.md +308 -0
- package/package.json +4 -4
|
@@ -1,336 +1,561 @@
|
|
|
1
1
|
# Methodology
|
|
2
2
|
|
|
3
|
-
A practical
|
|
3
|
+
A practical way to design a Glaze palette without fighting dark mode. Start from
|
|
4
|
+
tone relationships, add contrast only where a role needs a readable floor, and
|
|
5
|
+
let `extend()` carry the same decisions across status hues.
|
|
4
6
|
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
A Glaze palette is a **default neutral theme** plus a small fan of **colored sibling themes** (`success`, `danger`, `warning`, `note`, …) created via `extend()`. Most colors live in the default theme as neutrals; brand-tinted colors come from `extend()` swapping the hue.
|
|
8
|
-
|
|
9
|
-
The default theme is what most components consume — its tokens are emitted unprefixed (`#surface`, `#border`). Colored themes are scoped to status surfaces and accent variants, emitted with a theme-name prefix (`#success-surface`, `#danger-accent-surface`).
|
|
10
|
-
|
|
11
|
-
You design the default theme once, and `extend()` propagates that design across every status hue.
|
|
12
|
-
|
|
13
|
-
Every color definition has an **`inherit`** flag (default: `true`) controlling whether it flows into child themes via `extend()`. Set `inherit: false` to scope a color to its parent theme only — this is how sibling themes stay lean, carrying only the tokens they actually need.
|
|
7
|
+
For the full API surface, see [api.md](api.md). For the color model details, see
|
|
8
|
+
[okhst.md](okhst.md).
|
|
14
9
|
|
|
15
|
-
##
|
|
10
|
+
## The mental model
|
|
16
11
|
|
|
17
|
-
|
|
12
|
+
Glaze palettes work best as one default neutral theme plus a few colored sibling
|
|
13
|
+
themes:
|
|
14
|
+
|
|
15
|
+
- `default` owns the neutral system most components consume: `#surface`,
|
|
16
|
+
`#surface-text`, `#border`, `#disabled-surface`, and so on.
|
|
17
|
+
- Status themes (`success`, `danger`, `warning`, `note`, ...) are created with
|
|
18
|
+
`extend()`. They swap the hue and keep only the inherited tokens that should
|
|
19
|
+
become status-aware.
|
|
20
|
+
- `inherit: false` keeps a token local to the parent theme. Use it for neutral
|
|
21
|
+
ladders, shadows, code colors, overlays, and anything that should not be
|
|
22
|
+
repeated for every status hue.
|
|
23
|
+
|
|
24
|
+
The main simplification is OKHST tone. Dark mode is now a single inversion
|
|
25
|
+
(`100 - t`) plus a scheme window, so relative tone shifts stay consistent between
|
|
26
|
+
light and dark. A token that is `-4` tone from its base is the same kind of step
|
|
27
|
+
in both schemes.
|
|
28
|
+
|
|
29
|
+
## Authoring Rules
|
|
30
|
+
|
|
31
|
+
Use this order when defining a token:
|
|
32
|
+
|
|
33
|
+
1. Pick the base it visually belongs to.
|
|
34
|
+
2. Use `tone` for visual distance: surface ladders, soft chips, disabled states,
|
|
35
|
+
hover ramps, and other low-stakes relationships.
|
|
36
|
+
3. Add `contrast` only when readability or recognizability needs a measured
|
|
37
|
+
floor.
|
|
38
|
+
4. Use APCA presets for content-like colors:
|
|
39
|
+
`contrast: { apca: 'content' }` or
|
|
40
|
+
`contrast: { apca: ['content', 'body'] }`.
|
|
41
|
+
5. Use WCAG numbers or presets when you specifically need a ratio target:
|
|
42
|
+
`contrast: 4.5`, `contrast: 'AAA'`, or `contrast: { wcag: [4.5, 7] }`.
|
|
43
|
+
6. Let token names infer APCA roles. Names ending in `text`, `label`, `border`,
|
|
44
|
+
`surface`, `fill`, `bg`, and similar aliases already tell Glaze which side is
|
|
45
|
+
foreground or background. Set `role` only when a name is ambiguous.
|
|
46
|
+
7. Add high-contrast pairs only where HC should intentionally tighten:
|
|
47
|
+
text/content contrast, border tone, shadow intensity, mix value, or similar.
|
|
48
|
+
|
|
49
|
+
`mode: 'auto'` is the default and should be the default choice. Use
|
|
50
|
+
`mode: 'fixed'` for brand fills or inverse surfaces that must stay recognizable
|
|
51
|
+
instead of tone-inverting. Use `mode: 'static'` only when the exact authored tone
|
|
52
|
+
must render in every scheme.
|
|
53
|
+
|
|
54
|
+
## Seed and Configure
|
|
55
|
+
|
|
56
|
+
Keep hue decisions named and configure output modes once:
|
|
18
57
|
|
|
19
58
|
```ts
|
|
20
|
-
const PURPLE_HUE
|
|
59
|
+
const PURPLE_HUE = 280.3;
|
|
21
60
|
const SUCCESS_HUE = 156.9;
|
|
22
|
-
const DANGER_HUE
|
|
61
|
+
const DANGER_HUE = 23.1;
|
|
23
62
|
const WARNING_HUE = 84.3;
|
|
24
|
-
const NOTE_HUE
|
|
63
|
+
const NOTE_HUE = 302.3;
|
|
25
64
|
|
|
26
65
|
const SEED_SATURATION = 80;
|
|
27
|
-
```
|
|
28
|
-
|
|
29
|
-
Hues are design tokens too — keeping them named in one place beats burying numbers in `extend()` calls. The shared `SEED_SATURATION` keeps every status theme on the same saturation budget; per-color `saturation` factors below are 0–1 *of this seed*, not absolute.
|
|
30
|
-
|
|
31
|
-
## Global `glaze.configure()`
|
|
32
66
|
|
|
33
|
-
Configure state aliases and output modes once at module load:
|
|
34
|
-
|
|
35
|
-
```ts
|
|
36
67
|
glaze.configure({
|
|
37
68
|
states: { dark: '@dark', highContrast: '@hc' },
|
|
38
|
-
modes:
|
|
69
|
+
modes: { dark: true, highContrast: true },
|
|
39
70
|
});
|
|
40
71
|
```
|
|
41
72
|
|
|
42
|
-
|
|
73
|
+
Per-color `saturation` is a factor of the theme seed, not an absolute
|
|
74
|
+
saturation. With `SEED_SATURATION = 80`, `saturation: 0.25` means one quarter of
|
|
75
|
+
that seed.
|
|
43
76
|
|
|
44
|
-
## Naming
|
|
77
|
+
## Naming
|
|
45
78
|
|
|
46
|
-
|
|
79
|
+
Prefer purpose first and variant last:
|
|
47
80
|
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
| Brand-tinted disabled | `accent-disabled-surface`, `accent-disabled-surface-text` |
|
|
59
|
-
| Code syntax highlighting | `code-comment`, `code-keyword`, `code-string`, `code-number`, … |
|
|
60
|
-
| Loading animation | `loading-face-1`, `loading-face-2`, `loading-face-3` |
|
|
61
|
-
| Shadows | `shadow-sm`, `shadow-md`, `shadow-lg` |
|
|
62
|
-
| Backdrop | `overlay` |
|
|
81
|
+
- Surfaces: `surface`, `surface-2`, `surface-3`.
|
|
82
|
+
- Foregrounds: `surface-text`, `surface-text-soft`, `surface-text-soft-2`.
|
|
83
|
+
- Structure: `border`, `divider`, `outline`, `placeholder`, `focus`.
|
|
84
|
+
- Fills: `accent-surface`, `accent-surface-2`,
|
|
85
|
+
`accent-surface-hover`.
|
|
86
|
+
- Foregrounds on neutral surfaces: `accent-text`, `accent-text-soft`,
|
|
87
|
+
`accent-icon`.
|
|
88
|
+
- Disabled states: `disabled-surface`, `disabled-surface-text`,
|
|
89
|
+
`accent-disabled-surface`, `accent-disabled-surface-text`.
|
|
90
|
+
- Effects: `shadow-sm`, `shadow-md`, `shadow-lg`, `overlay`, `hover`, `tint`.
|
|
63
91
|
|
|
64
|
-
|
|
92
|
+
These names are not only readable. They also help APCA role inference pick the
|
|
93
|
+
right polarity. For example, `button-text` is foreground, `input-bg` is a
|
|
94
|
+
surface, and `card-outline` is a border.
|
|
65
95
|
|
|
66
|
-
##
|
|
96
|
+
## Build the Default Theme
|
|
67
97
|
|
|
68
|
-
|
|
98
|
+
Start with the surface family. It is mostly tone, with small saturation changes
|
|
99
|
+
to keep the ladder visually coherent:
|
|
69
100
|
|
|
70
101
|
```ts
|
|
102
|
+
const defaultTheme = glaze(PURPLE_HUE, SEED_SATURATION);
|
|
103
|
+
|
|
71
104
|
defaultTheme.colors({
|
|
72
|
-
surface:
|
|
73
|
-
'surface-2': {
|
|
74
|
-
|
|
105
|
+
surface: { tone: 100, saturation: 0.11 },
|
|
106
|
+
'surface-2': {
|
|
107
|
+
base: 'surface',
|
|
108
|
+
tone: '-2',
|
|
109
|
+
saturation: 0.15,
|
|
110
|
+
inherit: false,
|
|
111
|
+
},
|
|
112
|
+
'surface-3': {
|
|
113
|
+
base: 'surface',
|
|
114
|
+
tone: '-4',
|
|
115
|
+
saturation: 0.19,
|
|
116
|
+
inherit: false,
|
|
117
|
+
},
|
|
75
118
|
});
|
|
76
119
|
```
|
|
77
120
|
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
`mode: 'auto'` (the default) feeds these through Glaze's Möbius dark inversion, so an `L=100` light-mode surface lands near `L≈15` in dark mode with proportional deltas across the ladder preserved. `inherit: false` on `-2` / `-3` keeps colored sibling themes lean — they only need a single tinted `surface`, not the whole ladder.
|
|
121
|
+
Because tone shifts are consistent across schemes, these small relative offsets
|
|
122
|
+
are enough. There is no separate dark-mode curve to tune.
|
|
81
123
|
|
|
82
|
-
|
|
124
|
+
### Text and Borders
|
|
83
125
|
|
|
84
|
-
|
|
126
|
+
Use a hard edge tone for maximum-prominence text, and APCA floors for softer
|
|
127
|
+
content:
|
|
85
128
|
|
|
86
129
|
```ts
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
'surface
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
},
|
|
130
|
+
defaultTheme.colors({
|
|
131
|
+
'surface-text': {
|
|
132
|
+
base: 'surface',
|
|
133
|
+
tone: 2,
|
|
134
|
+
saturation: 0.475,
|
|
135
|
+
},
|
|
136
|
+
'surface-text-soft': {
|
|
137
|
+
base: 'surface',
|
|
138
|
+
tone: '-1',
|
|
139
|
+
saturation: 0.375,
|
|
140
|
+
contrast: { apca: ['content', 'body'] },
|
|
141
|
+
inherit: false,
|
|
142
|
+
},
|
|
143
|
+
'surface-text-soft-2': {
|
|
144
|
+
base: 'surface',
|
|
145
|
+
tone: '-1',
|
|
146
|
+
saturation: 0.24,
|
|
147
|
+
contrast: { apca: ['large', 'content'] },
|
|
148
|
+
inherit: false,
|
|
149
|
+
},
|
|
150
|
+
border: {
|
|
151
|
+
base: 'surface',
|
|
152
|
+
tone: ['-10', '-20'],
|
|
153
|
+
saturation: 0.175,
|
|
154
|
+
inherit: false,
|
|
155
|
+
},
|
|
156
|
+
});
|
|
98
157
|
```
|
|
99
158
|
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
The soft variants use `lightness: '-1'` only as a *directional hint* — the real positioning comes from the numeric `contrast`. Numeric ratios give designers precise perceived weight where presets would only guarantee the AA/AAA floor.
|
|
159
|
+
`surface-text` does not need a contrast floor because it is intentionally pinned
|
|
160
|
+
near the edge. The soft variants use `tone: '-1'` as the direction and APCA as
|
|
161
|
+
the readable floor. `border` uses an HC tone pair because borders usually need a
|
|
162
|
+
larger visible step in high contrast.
|
|
105
163
|
|
|
106
|
-
|
|
164
|
+
Repeat the same pattern for `surface-2` and `surface-3` only if components need
|
|
165
|
+
text directly on those surfaces.
|
|
107
166
|
|
|
108
|
-
|
|
167
|
+
### Neutral Utility Tokens
|
|
109
168
|
|
|
110
|
-
|
|
169
|
+
Keep neutral-only primitives local to the default theme:
|
|
111
170
|
|
|
112
171
|
```ts
|
|
113
|
-
|
|
114
|
-
placeholder: {
|
|
115
|
-
|
|
116
|
-
|
|
172
|
+
defaultTheme.colors({
|
|
173
|
+
placeholder: {
|
|
174
|
+
base: 'surface',
|
|
175
|
+
tone: 67,
|
|
176
|
+
saturation: 0.175,
|
|
177
|
+
inherit: false,
|
|
178
|
+
},
|
|
179
|
+
focus: {
|
|
180
|
+
base: 'surface',
|
|
181
|
+
tone: 71,
|
|
182
|
+
saturation: 0.8625,
|
|
183
|
+
inherit: false,
|
|
184
|
+
},
|
|
185
|
+
disabled: {
|
|
186
|
+
tone: 80.8,
|
|
187
|
+
saturation: 0.4,
|
|
188
|
+
inherit: false,
|
|
189
|
+
},
|
|
190
|
+
});
|
|
117
191
|
```
|
|
118
192
|
|
|
119
|
-
|
|
193
|
+
Absolute tones are fine for primitives whose job is visual placement rather than
|
|
194
|
+
a strict relationship to a specific surface.
|
|
120
195
|
|
|
121
|
-
##
|
|
196
|
+
## Chips and Disabled States
|
|
122
197
|
|
|
123
|
-
|
|
198
|
+
For subtle fills, tone is usually clearer than contrast:
|
|
124
199
|
|
|
125
200
|
```ts
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
201
|
+
defaultTheme.colors({
|
|
202
|
+
'disabled-surface': {
|
|
203
|
+
base: 'surface',
|
|
204
|
+
tone: '-3',
|
|
205
|
+
saturation: 0.2,
|
|
206
|
+
inherit: false,
|
|
207
|
+
},
|
|
208
|
+
'disabled-surface-text': {
|
|
209
|
+
base: 'disabled-surface',
|
|
210
|
+
tone: '+18',
|
|
211
|
+
saturation: 0.3,
|
|
212
|
+
autoFlip: false,
|
|
213
|
+
inherit: false,
|
|
214
|
+
},
|
|
215
|
+
});
|
|
134
216
|
```
|
|
135
217
|
|
|
136
|
-
|
|
218
|
+
This says exactly what the pair should do: the chip sits a few tone steps off
|
|
219
|
+
the page, and the label sits a muted distance from the chip. `autoFlip: false` keeps
|
|
220
|
+
the relative label offset on the authored side when it reaches the edge.
|
|
137
221
|
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
## `surface-inverse` (the fixed-mode escape hatch)
|
|
222
|
+
Use contrast instead when the chip must hit an explicit accessibility floor:
|
|
141
223
|
|
|
142
224
|
```ts
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
225
|
+
defaultTheme.colors({
|
|
226
|
+
'disabled-surface-text': {
|
|
227
|
+
base: 'disabled-surface',
|
|
228
|
+
tone: '+1',
|
|
229
|
+
saturation: 0.3,
|
|
230
|
+
contrast: { apca: 'non-text' },
|
|
231
|
+
inherit: false,
|
|
232
|
+
},
|
|
233
|
+
});
|
|
146
234
|
```
|
|
147
235
|
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
236
|
+
When a token needs the scheme extreme, use `tone: 'min'` or `tone: 'max'`
|
|
237
|
+
directly. Avoid large magic numbers or fake contrast floors just to push a color
|
|
238
|
+
to the edge.
|
|
151
239
|
|
|
152
|
-
|
|
240
|
+
## Fixed Surfaces and Accent Fills
|
|
153
241
|
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
The load-bearing trick. Define a single fixed white anchor `accent-surface-text`, then derive every accent surface from it with a small relative lightness offset and a numeric contrast under `mode: 'fixed'`:
|
|
242
|
+
Use `mode: 'fixed'` when the authored color should stay recognizable across
|
|
243
|
+
schemes.
|
|
157
244
|
|
|
158
245
|
```ts
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
246
|
+
defaultTheme.colors({
|
|
247
|
+
'surface-inverse': {
|
|
248
|
+
tone: 12,
|
|
249
|
+
saturation: 0.475,
|
|
250
|
+
mode: 'fixed',
|
|
251
|
+
inherit: false,
|
|
252
|
+
},
|
|
253
|
+
|
|
254
|
+
'accent-surface-text': {
|
|
255
|
+
tone: 100,
|
|
256
|
+
mode: 'fixed',
|
|
257
|
+
},
|
|
258
|
+
'accent-surface': {
|
|
259
|
+
base: 'accent-surface-text',
|
|
260
|
+
tone: '-1',
|
|
261
|
+
contrast: { apca: ['content', 'body'] },
|
|
262
|
+
mode: 'fixed',
|
|
263
|
+
},
|
|
264
|
+
'accent-surface-2': {
|
|
265
|
+
base: 'accent-surface-text',
|
|
266
|
+
tone: '-1',
|
|
267
|
+
contrast: { apca: [65, 80] },
|
|
268
|
+
mode: 'fixed',
|
|
269
|
+
},
|
|
270
|
+
'accent-surface-hover': {
|
|
271
|
+
base: 'accent-surface-text',
|
|
272
|
+
tone: '-1',
|
|
273
|
+
contrast: { apca: ['body', 'preferred'] },
|
|
274
|
+
mode: 'fixed',
|
|
275
|
+
},
|
|
276
|
+
});
|
|
165
277
|
```
|
|
166
278
|
|
|
167
|
-
|
|
279
|
+
The accent fill family is a fixed chain against a fixed text anchor. The names
|
|
280
|
+
infer `surface` and `text` roles, so APCA gets the right polarity without extra
|
|
281
|
+
fields.
|
|
168
282
|
|
|
169
|
-
|
|
170
|
-
- **`mode: 'fixed'` keeps the brand recognizable.** Without it, the dark-scheme Möbius inversion would turn the brand fill into a lightness-inverted counterpart that may no longer read as the intended brand surface. Fixed maps lightness linearly into the dark window, so a `L=52` brand color resolves to ~L=51.6 in dark mode — still recognizably the same color.
|
|
171
|
-
- **Numeric contrasts, not presets.** `'AA'` / `'AAA'` would let the solver push the color far away from its anchor in dark schemes, breaking the relationship between `accent-surface` and its neighbors. Numeric ratios make the darkening between `accent-surface` (4.5/7), `-2` (4.8/7.5), `-3` (5.2/8), and `-hover` (6/8.5) a tight, designed sequence — a stepped gradient rather than four solver-generated outliers.
|
|
283
|
+
## Adaptive Accent Foregrounds
|
|
172
284
|
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
## Adaptive accent foregrounds
|
|
176
|
-
|
|
177
|
-
The opposite of the fills. Brand-colored *foregrounds* are anchored to **`surface`, not `accent-surface`**, with `mode: 'auto'` (default) and full saturation:
|
|
285
|
+
Brand foregrounds that sit on neutral surfaces should stay adaptive:
|
|
178
286
|
|
|
179
287
|
```ts
|
|
180
|
-
|
|
181
|
-
'accent-text
|
|
182
|
-
|
|
288
|
+
defaultTheme.colors({
|
|
289
|
+
'accent-text': {
|
|
290
|
+
base: 'surface',
|
|
291
|
+
tone: '-1',
|
|
292
|
+
saturation: 1,
|
|
293
|
+
contrast: { apca: ['content', 'body'] },
|
|
294
|
+
},
|
|
295
|
+
'accent-text-soft': {
|
|
296
|
+
base: 'surface',
|
|
297
|
+
tone: '-1',
|
|
298
|
+
saturation: 1,
|
|
299
|
+
contrast: { apca: ['large', 'content'] },
|
|
300
|
+
},
|
|
301
|
+
'accent-icon': {
|
|
302
|
+
base: 'surface',
|
|
303
|
+
tone: '-1',
|
|
304
|
+
saturation: 0.9375,
|
|
305
|
+
contrast: { apca: ['non-text', 'large'] },
|
|
306
|
+
},
|
|
307
|
+
});
|
|
183
308
|
```
|
|
184
309
|
|
|
185
|
-
|
|
310
|
+
Anchor these to `surface`, not to `accent-surface`. Their real job is to remain
|
|
311
|
+
readable on neutral UI, so `mode: 'auto'` and a surface base are the right
|
|
312
|
+
defaults.
|
|
186
313
|
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
## Brand-tinted disabled
|
|
190
|
-
|
|
191
|
-
Mirrors the neutral disabled pair from above but with higher saturation so the chip reads as a *muted brand color* rather than fully neutral grey:
|
|
314
|
+
Brand-tinted disabled states can usually be pure tone:
|
|
192
315
|
|
|
193
316
|
```ts
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
317
|
+
defaultTheme.colors({
|
|
318
|
+
'accent-disabled-surface': {
|
|
319
|
+
base: 'surface',
|
|
320
|
+
tone: '+3',
|
|
321
|
+
saturation: 0.5,
|
|
322
|
+
},
|
|
323
|
+
'accent-disabled-surface-text': {
|
|
324
|
+
base: 'accent-disabled-surface',
|
|
325
|
+
tone: '+18',
|
|
326
|
+
saturation: 0.4,
|
|
327
|
+
autoFlip: false,
|
|
328
|
+
},
|
|
329
|
+
});
|
|
202
330
|
```
|
|
203
331
|
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
332
|
+
These are inherited, so status themes automatically get
|
|
333
|
+
`success-accent-disabled-surface`, `danger-accent-disabled-surface`, and the
|
|
334
|
+
matching text tokens.
|
|
207
335
|
|
|
208
|
-
##
|
|
336
|
+
## Special Purpose Colors
|
|
209
337
|
|
|
210
|
-
|
|
338
|
+
Use absolute `hue` overrides for tokens that should come from another hue family
|
|
339
|
+
but keep the same adaptation behavior:
|
|
211
340
|
|
|
212
341
|
```ts
|
|
213
|
-
|
|
214
|
-
'code-
|
|
215
|
-
|
|
216
|
-
|
|
342
|
+
defaultTheme.colors({
|
|
343
|
+
'code-comment': {
|
|
344
|
+
base: 'surface',
|
|
345
|
+
hue: 280,
|
|
346
|
+
saturation: 0.1,
|
|
347
|
+
tone: '-1',
|
|
348
|
+
contrast: { apca: ['large', 'content'] },
|
|
349
|
+
inherit: false,
|
|
350
|
+
},
|
|
351
|
+
'code-keyword': {
|
|
352
|
+
base: 'surface',
|
|
353
|
+
hue: 348,
|
|
354
|
+
saturation: 1,
|
|
355
|
+
tone: '-1',
|
|
356
|
+
contrast: { apca: ['content', 'body'] },
|
|
357
|
+
inherit: false,
|
|
358
|
+
},
|
|
359
|
+
'code-string': {
|
|
360
|
+
base: 'surface',
|
|
361
|
+
hue: SUCCESS_HUE,
|
|
362
|
+
saturation: 1,
|
|
363
|
+
tone: '-1',
|
|
364
|
+
contrast: { apca: ['large', 'content'] },
|
|
365
|
+
inherit: false,
|
|
366
|
+
},
|
|
367
|
+
});
|
|
217
368
|
```
|
|
218
369
|
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
## Loading-animation faces
|
|
222
|
-
|
|
223
|
-
A 3-step ramp using *absolute* lightnesses with high saturation factors and tight numeric contrasts:
|
|
370
|
+
Use small tone ramps for decorative motion:
|
|
224
371
|
|
|
225
372
|
```ts
|
|
226
|
-
|
|
227
|
-
'loading-face-
|
|
228
|
-
|
|
373
|
+
defaultTheme.colors({
|
|
374
|
+
'loading-face-1': {
|
|
375
|
+
base: 'surface',
|
|
376
|
+
tone: 98,
|
|
377
|
+
saturation: 0.3,
|
|
378
|
+
inherit: false,
|
|
379
|
+
},
|
|
380
|
+
'loading-face-2': {
|
|
381
|
+
base: 'surface',
|
|
382
|
+
tone: 91,
|
|
383
|
+
saturation: 0.62,
|
|
384
|
+
inherit: false,
|
|
385
|
+
},
|
|
386
|
+
'loading-face-3': {
|
|
387
|
+
base: 'surface',
|
|
388
|
+
tone: 79,
|
|
389
|
+
saturation: 0.66,
|
|
390
|
+
inherit: false,
|
|
391
|
+
},
|
|
392
|
+
});
|
|
229
393
|
```
|
|
230
394
|
|
|
231
|
-
|
|
395
|
+
Since tone steps now invert consistently across schemes, the same ramp keeps its
|
|
396
|
+
spacing in light and dark without involving the contrast solver. Use an HC tone
|
|
397
|
+
pair only when the animation should become more pronounced in high contrast.
|
|
232
398
|
|
|
233
|
-
##
|
|
399
|
+
## Effects
|
|
234
400
|
|
|
235
|
-
|
|
401
|
+
Define one neutral shadow system:
|
|
236
402
|
|
|
237
403
|
```ts
|
|
238
|
-
|
|
239
|
-
'shadow-
|
|
240
|
-
|
|
404
|
+
defaultTheme.colors({
|
|
405
|
+
'shadow-sm': {
|
|
406
|
+
type: 'shadow',
|
|
407
|
+
bg: 'surface',
|
|
408
|
+
fg: 'surface-text',
|
|
409
|
+
intensity: 5,
|
|
410
|
+
inherit: false,
|
|
411
|
+
},
|
|
412
|
+
'shadow-md': {
|
|
413
|
+
type: 'shadow',
|
|
414
|
+
bg: 'surface',
|
|
415
|
+
fg: 'surface-text',
|
|
416
|
+
intensity: [10, 20],
|
|
417
|
+
inherit: false,
|
|
418
|
+
},
|
|
419
|
+
'shadow-lg': {
|
|
420
|
+
type: 'shadow',
|
|
421
|
+
bg: 'surface',
|
|
422
|
+
fg: 'surface-text',
|
|
423
|
+
intensity: [15, 30],
|
|
424
|
+
inherit: false,
|
|
425
|
+
},
|
|
426
|
+
});
|
|
241
427
|
```
|
|
242
428
|
|
|
243
|
-
Including `fg`
|
|
429
|
+
Including `fg` lets shadow strength follow the resolved foreground/background
|
|
430
|
+
gap. Use an HC pair for shadows that should deepen in high contrast.
|
|
244
431
|
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
## Overlay (fixed opacity)
|
|
432
|
+
Use `opacity` for one fixed-alpha color:
|
|
248
433
|
|
|
249
434
|
```ts
|
|
250
|
-
|
|
435
|
+
defaultTheme.colors({
|
|
436
|
+
overlay: { tone: 10, opacity: 0.5, inherit: false },
|
|
437
|
+
});
|
|
251
438
|
```
|
|
252
439
|
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
## Mixes for hover / tint
|
|
256
|
-
|
|
257
|
-
Reach for mix tokens when you want one color to "tint through" another:
|
|
440
|
+
Use mixes when one color should tint through another:
|
|
258
441
|
|
|
259
442
|
```ts
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
443
|
+
defaultTheme.colors({
|
|
444
|
+
hover: {
|
|
445
|
+
type: 'mix',
|
|
446
|
+
base: 'surface',
|
|
447
|
+
target: 'accent-surface',
|
|
448
|
+
value: 8,
|
|
449
|
+
blend: 'transparent',
|
|
450
|
+
},
|
|
451
|
+
tint: {
|
|
452
|
+
type: 'mix',
|
|
453
|
+
base: 'surface',
|
|
454
|
+
target: 'accent-surface',
|
|
455
|
+
value: 20,
|
|
456
|
+
},
|
|
457
|
+
});
|
|
270
458
|
```
|
|
271
459
|
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
Choose `space: 'okhsl'` (default) for design tokens — perceptually uniform, consistent with the rest of Glaze. Choose `space: 'srgb'` to match what the browser would render with a plain CSS overlay. Mix colors support the same `contrast` prop as regular colors; the solver adjusts the mix ratio (opaque) or opacity (transparent) to meet the target.
|
|
460
|
+
Transparent mixes are good for hover overlays. Opaque mixes are good for solid
|
|
461
|
+
tints. Mix colors can also use `contrast`; the solver adjusts the value or
|
|
462
|
+
opacity to hit the floor.
|
|
276
463
|
|
|
277
|
-
##
|
|
464
|
+
## Extend into Status Themes
|
|
278
465
|
|
|
279
|
-
|
|
466
|
+
Once the default theme is shaped, create colored siblings by replacing hue and
|
|
467
|
+
overriding only the root surface that should become visibly tinted:
|
|
280
468
|
|
|
281
469
|
```ts
|
|
282
|
-
const TINTED_SURFACE_OVERRIDE
|
|
283
|
-
surface: {
|
|
470
|
+
const TINTED_SURFACE_OVERRIDE = {
|
|
471
|
+
surface: { tone: 96, saturation: 0.8 },
|
|
284
472
|
};
|
|
285
473
|
|
|
286
|
-
const primaryTheme = defaultTheme.extend({
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
const
|
|
290
|
-
|
|
474
|
+
const primaryTheme = defaultTheme.extend({
|
|
475
|
+
colors: TINTED_SURFACE_OVERRIDE,
|
|
476
|
+
});
|
|
477
|
+
const successTheme = defaultTheme.extend({
|
|
478
|
+
hue: SUCCESS_HUE,
|
|
479
|
+
colors: TINTED_SURFACE_OVERRIDE,
|
|
480
|
+
});
|
|
481
|
+
const dangerTheme = defaultTheme.extend({
|
|
482
|
+
hue: DANGER_HUE,
|
|
483
|
+
colors: TINTED_SURFACE_OVERRIDE,
|
|
484
|
+
});
|
|
485
|
+
const warningTheme = defaultTheme.extend({
|
|
486
|
+
hue: WARNING_HUE,
|
|
487
|
+
colors: TINTED_SURFACE_OVERRIDE,
|
|
488
|
+
});
|
|
489
|
+
const noteTheme = defaultTheme.extend({
|
|
490
|
+
hue: NOTE_HUE,
|
|
491
|
+
colors: TINTED_SURFACE_OVERRIDE,
|
|
492
|
+
});
|
|
291
493
|
```
|
|
292
494
|
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
`primaryTheme` keeps the default hue but gets the tinted surface — useful for places that want a brand-tinted banner without semantic status meaning.
|
|
495
|
+
The inherited accent and disabled tokens now resolve in each status hue. Tokens
|
|
496
|
+
marked `inherit: false` stay default-only, so sibling themes remain small.
|
|
296
497
|
|
|
297
|
-
## Palette
|
|
498
|
+
## Export the Palette
|
|
298
499
|
|
|
299
|
-
Compose
|
|
500
|
+
Compose the themes once:
|
|
300
501
|
|
|
301
502
|
```ts
|
|
302
503
|
const palette = glaze.palette({
|
|
303
504
|
default: defaultTheme,
|
|
304
505
|
primary: primaryTheme,
|
|
305
506
|
success: successTheme,
|
|
306
|
-
danger:
|
|
507
|
+
danger: dangerTheme,
|
|
307
508
|
warning: warningTheme,
|
|
308
|
-
note:
|
|
509
|
+
note: noteTheme,
|
|
510
|
+
});
|
|
511
|
+
```
|
|
512
|
+
|
|
513
|
+
The usual export shape is default unprefixed and status themes prefixed:
|
|
514
|
+
|
|
515
|
+
```ts
|
|
516
|
+
palette.tasty({
|
|
517
|
+
prefix: {
|
|
518
|
+
default: '',
|
|
519
|
+
primary: 'primary-',
|
|
520
|
+
success: 'success-',
|
|
521
|
+
danger: 'danger-',
|
|
522
|
+
warning: 'warning-',
|
|
523
|
+
note: 'note-',
|
|
524
|
+
},
|
|
309
525
|
});
|
|
310
526
|
```
|
|
311
527
|
|
|
312
|
-
|
|
528
|
+
See [migration.md](migration.md) for export shapes, prefix maps, Tasty wiring,
|
|
529
|
+
CSS variables, and JSON integration.
|
|
530
|
+
|
|
531
|
+
## High Contrast
|
|
313
532
|
|
|
314
|
-
|
|
533
|
+
High contrast is not a separate palette. Any value that accepts an HC pair can
|
|
534
|
+
tighten the HC variant: `tone`, `contrast`, shadow `intensity`, and mix `value`.
|
|
315
535
|
|
|
316
|
-
|
|
536
|
+
Use HC pairs where users should actually get more separation:
|
|
317
537
|
|
|
318
|
-
- Text
|
|
319
|
-
-
|
|
320
|
-
-
|
|
321
|
-
-
|
|
322
|
-
-
|
|
538
|
+
- Text/content contrast: `{ apca: ['content', 'body'] }`.
|
|
539
|
+
- Accent fills: `{ apca: ['content', 'body'] }` or stronger.
|
|
540
|
+
- Borders: `tone: ['-10', '-20']`.
|
|
541
|
+
- Shadows: `intensity: [10, 20]`.
|
|
542
|
+
- Decorative ramps that must stay perceivable.
|
|
323
543
|
|
|
324
|
-
In HC
|
|
544
|
+
In HC variants, Glaze bypasses the normal tone window and uses the full
|
|
545
|
+
`[0, 100]` range. Edge tones can reach the edge; contrast floors have more room
|
|
546
|
+
to solve.
|
|
325
547
|
|
|
326
|
-
##
|
|
548
|
+
## Checklist
|
|
327
549
|
|
|
328
550
|
Before shipping a palette, verify:
|
|
329
551
|
|
|
330
|
-
-
|
|
331
|
-
-
|
|
332
|
-
-
|
|
333
|
-
|
|
334
|
-
-
|
|
335
|
-
-
|
|
336
|
-
|
|
552
|
+
- Text, icon, and content tokens either have APCA/WCAG contrast or are
|
|
553
|
+
deliberately edge-anchored.
|
|
554
|
+
- Accent fills use `mode: 'fixed'`; accent foregrounds on neutral UI stay
|
|
555
|
+
`mode: 'auto'` and are based on `surface`.
|
|
556
|
+
- Ambiguous APCA tokens have an explicit `role`; obvious names rely on inference.
|
|
557
|
+
- Low-stakes visual relationships use relative `tone` instead of fake contrast
|
|
558
|
+
floors.
|
|
559
|
+
- `inherit: false` is set on default-only tokens so status themes stay focused.
|
|
560
|
+
- HC pairs exist where high contrast should visibly tighten.
|
|
561
|
+
- `glaze.configure({ states, modes })` matches the states registered in the app.
|