@multiplatform.one/components 7.45.1 → 7.47.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/Alert/index.cjs +1 -1
- package/dist/cjs/Alert/index.native.js +1 -1
- package/dist/cjs/Alert/index.native.js.map +1 -1
- package/dist/cjs/Carousel/index.cjs +1 -1
- package/dist/cjs/Carousel/index.native.js +1 -1
- package/dist/cjs/Carousel/index.native.js.map +1 -1
- package/dist/cjs/Chip/index.cjs +18 -7
- package/dist/cjs/Chip/index.native.js +20 -8
- package/dist/cjs/Chip/index.native.js.map +1 -1
- package/dist/cjs/DropdownMenu/index.cjs +5 -1
- package/dist/cjs/DropdownMenu/index.native.js +5 -1
- package/dist/cjs/DropdownMenu/index.native.js.map +1 -1
- package/dist/cjs/ErrorBoundary/index.cjs +2 -2
- package/dist/cjs/ErrorBoundary/index.native.js +2 -2
- package/dist/cjs/ErrorBoundary/index.native.js.map +1 -1
- package/dist/cjs/Heading.cjs +8 -127
- package/dist/cjs/Heading.native.js +7 -133
- package/dist/cjs/Heading.native.js.map +1 -1
- package/dist/cjs/OverflowRow/index.cjs +1 -0
- package/dist/cjs/OverflowRow/index.native.js +1 -0
- package/dist/cjs/OverflowRow/index.native.js.map +1 -1
- package/dist/cjs/Pagination.cjs +4 -1
- package/dist/cjs/Pagination.native.js +4 -1
- package/dist/cjs/Pagination.native.js.map +1 -1
- package/dist/cjs/Popover.cjs +145 -0
- package/dist/cjs/Popover.native.js +174 -0
- package/dist/cjs/Popover.native.js.map +1 -0
- package/dist/cjs/ProgressSteps/index.cjs +1 -1
- package/dist/cjs/ProgressSteps/index.native.js +1 -1
- package/dist/cjs/ProgressSteps/index.native.js.map +1 -1
- package/dist/cjs/Quote/index.cjs +1 -0
- package/dist/cjs/Quote/index.native.js +1 -0
- package/dist/cjs/Quote/index.native.js.map +1 -1
- package/dist/cjs/SkipLink/index.cjs +1 -2
- package/dist/cjs/SkipLink/index.native.js +1 -2
- package/dist/cjs/SkipLink/index.native.js.map +1 -1
- package/dist/cjs/SortableList/index.cjs +2 -1
- package/dist/cjs/SortableList/index.native.js +2 -1
- package/dist/cjs/SortableList/index.native.js.map +1 -1
- package/dist/cjs/SortableList/useSortableRows.cjs +2 -2
- package/dist/cjs/SortableList/useSortableRows.native.js +2 -2
- package/dist/cjs/SortableList/useSortableRows.native.js.map +1 -1
- package/dist/cjs/Text.cjs +5 -116
- package/dist/cjs/Text.native.js +4 -120
- package/dist/cjs/Text.native.js.map +1 -1
- package/dist/cjs/ThemePlayground/index.cjs +3 -2
- package/dist/cjs/ThemePresetPicker/index.cjs +21 -22
- package/dist/cjs/ThemePresetPicker/index.native.js +21 -22
- package/dist/cjs/ThemePresetPicker/index.native.js.map +1 -1
- package/dist/cjs/Tooltip/index.cjs +6 -0
- package/dist/cjs/TreeSelect/index.cjs +2 -1
- package/dist/cjs/TreeSelect/index.native.js +2 -1
- package/dist/cjs/TreeSelect/index.native.js.map +1 -1
- package/dist/cjs/Video/PlayerChrome.cjs +1 -1
- package/dist/cjs/Video/PlayerChrome.native.js +1 -1
- package/dist/cjs/Video/PlayerChrome.native.js.map +1 -1
- package/dist/cjs/Video/VideoFrame.cjs +2 -1
- package/dist/cjs/Video/VideoFrame.native.js +2 -1
- package/dist/cjs/Video/VideoFrame.native.js.map +1 -1
- package/dist/cjs/Video/index.cjs +3 -1
- package/dist/cjs/actions/DestructiveAction.cjs +3 -2
- package/dist/cjs/actions/DestructiveAction.native.js +3 -2
- package/dist/cjs/actions/DestructiveAction.native.js.map +1 -1
- package/dist/cjs/appShell/ScopeMenu.cjs +2 -1
- package/dist/cjs/appShell/ScopeMenu.native.js +2 -1
- package/dist/cjs/appShell/ScopeMenu.native.js.map +1 -1
- package/dist/cjs/appShell/SettingsSplit.cjs +5 -4
- package/dist/cjs/appShell/SettingsSplit.native.js +5 -4
- package/dist/cjs/appShell/SettingsSplit.native.js.map +1 -1
- package/dist/cjs/appShell/Springboard.cjs +2 -1
- package/dist/cjs/appShell/Springboard.native.js +2 -1
- package/dist/cjs/appShell/Springboard.native.js.map +1 -1
- package/dist/cjs/appShell/SystemBar.cjs +2 -1
- package/dist/cjs/appShell/SystemBar.native.js +2 -1
- package/dist/cjs/appShell/SystemBar.native.js.map +1 -1
- package/dist/cjs/feedback/ConfirmDialog.cjs +1 -1
- package/dist/cjs/feedback/ConfirmDialog.native.js +1 -1
- package/dist/cjs/feedback/ConfirmDialog.native.js.map +1 -1
- package/dist/cjs/knobImmuneExports.cjs +0 -1
- package/dist/cjs/knobImmuneExports.native.js +0 -1
- package/dist/cjs/knobImmuneExports.native.js.map +1 -1
- package/dist/cjs/layouts/attachments.cjs +11 -10
- package/dist/cjs/layouts/attachments.native.js +11 -10
- package/dist/cjs/layouts/attachments.native.js.map +1 -1
- package/dist/cjs/layouts/breadcrumbs.cjs +3 -2
- package/dist/cjs/layouts/breadcrumbs.native.js +3 -2
- package/dist/cjs/layouts/breadcrumbs.native.js.map +1 -1
- package/dist/cjs/layouts/page.cjs +80 -8
- package/dist/cjs/layouts/page.native.js +82 -8
- package/dist/cjs/layouts/page.native.js.map +1 -1
- package/dist/cjs/layouts/sidebar.cjs +3 -1
- package/dist/cjs/layouts/sidebar.native.js +3 -1
- package/dist/cjs/layouts/sidebar.native.js.map +1 -1
- package/dist/cjs/layouts/tags.cjs +2 -1
- package/dist/cjs/layouts/tags.native.js +2 -1
- package/dist/cjs/layouts/tags.native.js.map +1 -1
- package/dist/cjs/layouts/timeline.cjs +14 -13
- package/dist/cjs/layouts/timeline.native.js +14 -13
- package/dist/cjs/layouts/timeline.native.js.map +1 -1
- package/dist/cjs/layouts/toolbar.cjs +2 -1
- package/dist/cjs/layouts/toolbar.native.js +2 -1
- package/dist/cjs/layouts/toolbar.native.js.map +1 -1
- package/dist/cjs/linearGradientSetup.cjs +18 -0
- package/dist/cjs/linearGradientSetup.native.js +4 -0
- package/dist/cjs/linearGradientSetup.native.js.map +1 -0
- package/dist/cjs/tamagui.cjs +2 -1
- package/dist/cjs/tamagui.native.js +2 -1
- package/dist/cjs/tamagui.native.js.map +1 -1
- package/dist/cjs/views/Calendar.cjs +14 -13
- package/dist/cjs/views/Calendar.native.js +14 -13
- package/dist/cjs/views/Calendar.native.js.map +1 -1
- package/dist/cjs/views/Gantt.cjs +188 -55
- package/dist/cjs/views/Gantt.native.js +201 -55
- package/dist/cjs/views/Gantt.native.js.map +1 -1
- package/dist/cjs/views/GanttDateGrip.cjs +216 -0
- package/dist/cjs/views/GanttDateGrip.native.js +259 -0
- package/dist/cjs/views/GanttDateGrip.native.js.map +1 -0
- package/dist/cjs/views/Kanban.cjs +3 -2
- package/dist/cjs/views/Kanban.native.js +3 -2
- package/dist/cjs/views/Kanban.native.js.map +1 -1
- package/dist/cjs/views/List.cjs +13 -3
- package/dist/cjs/views/List.native.js +14 -3
- package/dist/cjs/views/List.native.js.map +1 -1
- package/dist/cjs/views/Matrix.cjs +2 -1
- package/dist/cjs/views/Matrix.native.js +2 -1
- package/dist/cjs/views/Matrix.native.js.map +1 -1
- package/dist/cjs/views/TreeView.cjs +3 -2
- package/dist/cjs/views/TreeView.native.js +3 -2
- package/dist/cjs/views/TreeView.native.js.map +1 -1
- package/dist/cjs/views/ganttIntervals.cjs +85 -0
- package/dist/cjs/views/ganttIntervals.native.js +92 -0
- package/dist/cjs/views/ganttIntervals.native.js.map +1 -0
- package/dist/esm/Alert/index.mjs +2 -2
- package/dist/esm/Alert/index.mjs.map +1 -1
- package/dist/esm/Alert/index.native.js +2 -2
- package/dist/esm/Alert/index.native.js.map +1 -1
- package/dist/esm/Carousel/index.mjs +1 -1
- package/dist/esm/Carousel/index.mjs.map +1 -1
- package/dist/esm/Carousel/index.native.js +1 -1
- package/dist/esm/Carousel/index.native.js.map +1 -1
- package/dist/esm/Chip/index.mjs +18 -7
- package/dist/esm/Chip/index.mjs.map +1 -1
- package/dist/esm/Chip/index.native.js +20 -8
- package/dist/esm/Chip/index.native.js.map +1 -1
- package/dist/esm/DropdownMenu/index.mjs +5 -1
- package/dist/esm/DropdownMenu/index.mjs.map +1 -1
- package/dist/esm/DropdownMenu/index.native.js +5 -1
- package/dist/esm/DropdownMenu/index.native.js.map +1 -1
- package/dist/esm/ErrorBoundary/index.mjs +1 -1
- package/dist/esm/ErrorBoundary/index.mjs.map +1 -1
- package/dist/esm/ErrorBoundary/index.native.js +1 -1
- package/dist/esm/ErrorBoundary/index.native.js.map +1 -1
- package/dist/esm/Heading.mjs +1 -120
- package/dist/esm/Heading.mjs.map +1 -1
- package/dist/esm/Heading.native.js +1 -127
- package/dist/esm/Heading.native.js.map +1 -1
- package/dist/esm/OverflowRow/index.mjs.map +1 -1
- package/dist/esm/OverflowRow/index.native.js.map +1 -1
- package/dist/esm/Pagination.mjs +4 -1
- package/dist/esm/Pagination.mjs.map +1 -1
- package/dist/esm/Pagination.native.js +4 -1
- package/dist/esm/Pagination.native.js.map +1 -1
- package/dist/esm/Popover.mjs +120 -0
- package/dist/esm/Popover.mjs.map +1 -0
- package/dist/esm/Popover.native.js +146 -0
- package/dist/esm/Popover.native.js.map +1 -0
- package/dist/esm/ProgressSteps/index.mjs +2 -2
- package/dist/esm/ProgressSteps/index.mjs.map +1 -1
- package/dist/esm/ProgressSteps/index.native.js +2 -2
- package/dist/esm/ProgressSteps/index.native.js.map +1 -1
- package/dist/esm/Quote/index.mjs +2 -1
- package/dist/esm/Quote/index.mjs.map +1 -1
- package/dist/esm/Quote/index.native.js +2 -1
- package/dist/esm/Quote/index.native.js.map +1 -1
- package/dist/esm/SkipLink/index.mjs +1 -2
- package/dist/esm/SkipLink/index.mjs.map +1 -1
- package/dist/esm/SkipLink/index.native.js +1 -2
- package/dist/esm/SkipLink/index.native.js.map +1 -1
- package/dist/esm/SortableList/index.mjs +5 -4
- package/dist/esm/SortableList/index.mjs.map +1 -1
- package/dist/esm/SortableList/index.native.js +5 -4
- package/dist/esm/SortableList/index.native.js.map +1 -1
- package/dist/esm/SortableList/useSortableRows.mjs +2 -2
- package/dist/esm/SortableList/useSortableRows.mjs.map +1 -1
- package/dist/esm/SortableList/useSortableRows.native.js +2 -2
- package/dist/esm/SortableList/useSortableRows.native.js.map +1 -1
- package/dist/esm/Text.mjs +1 -112
- package/dist/esm/Text.mjs.map +1 -1
- package/dist/esm/Text.native.js +1 -117
- package/dist/esm/Text.native.js.map +1 -1
- package/dist/esm/ThemePlayground/index.mjs +2 -1
- package/dist/esm/ThemePlayground/index.mjs.map +1 -1
- package/dist/esm/ThemePresetPicker/index.mjs +21 -22
- package/dist/esm/ThemePresetPicker/index.mjs.map +1 -1
- package/dist/esm/ThemePresetPicker/index.native.js +21 -22
- package/dist/esm/ThemePresetPicker/index.native.js.map +1 -1
- package/dist/esm/Tooltip/index.mjs +6 -0
- package/dist/esm/Tooltip/index.mjs.map +1 -1
- package/dist/esm/TreeSelect/index.mjs +6 -5
- package/dist/esm/TreeSelect/index.mjs.map +1 -1
- package/dist/esm/TreeSelect/index.native.js +6 -5
- package/dist/esm/TreeSelect/index.native.js.map +1 -1
- package/dist/esm/Video/PlayerChrome.mjs +1 -1
- package/dist/esm/Video/PlayerChrome.mjs.map +1 -1
- package/dist/esm/Video/PlayerChrome.native.js +1 -1
- package/dist/esm/Video/PlayerChrome.native.js.map +1 -1
- package/dist/esm/Video/VideoFrame.mjs +3 -2
- package/dist/esm/Video/VideoFrame.mjs.map +1 -1
- package/dist/esm/Video/VideoFrame.native.js +3 -2
- package/dist/esm/Video/VideoFrame.native.js.map +1 -1
- package/dist/esm/Video/index.mjs +3 -1
- package/dist/esm/Video/index.mjs.map +1 -1
- package/dist/esm/actions/DestructiveAction.mjs +2 -1
- package/dist/esm/actions/DestructiveAction.mjs.map +1 -1
- package/dist/esm/actions/DestructiveAction.native.js +2 -1
- package/dist/esm/actions/DestructiveAction.native.js.map +1 -1
- package/dist/esm/appShell/ScopeMenu.mjs +2 -1
- package/dist/esm/appShell/ScopeMenu.mjs.map +1 -1
- package/dist/esm/appShell/ScopeMenu.native.js +2 -1
- package/dist/esm/appShell/ScopeMenu.native.js.map +1 -1
- package/dist/esm/appShell/SettingsSplit.mjs +5 -4
- package/dist/esm/appShell/SettingsSplit.mjs.map +1 -1
- package/dist/esm/appShell/SettingsSplit.native.js +5 -4
- package/dist/esm/appShell/SettingsSplit.native.js.map +1 -1
- package/dist/esm/appShell/Springboard.mjs +3 -2
- package/dist/esm/appShell/Springboard.mjs.map +1 -1
- package/dist/esm/appShell/Springboard.native.js +3 -2
- package/dist/esm/appShell/Springboard.native.js.map +1 -1
- package/dist/esm/appShell/SystemBar.mjs +2 -1
- package/dist/esm/appShell/SystemBar.mjs.map +1 -1
- package/dist/esm/appShell/SystemBar.native.js +2 -1
- package/dist/esm/appShell/SystemBar.native.js.map +1 -1
- package/dist/esm/feedback/ConfirmDialog.mjs +1 -1
- package/dist/esm/feedback/ConfirmDialog.mjs.map +1 -1
- package/dist/esm/feedback/ConfirmDialog.native.js +1 -1
- package/dist/esm/feedback/ConfirmDialog.native.js.map +1 -1
- package/dist/esm/knobImmuneExports.mjs +0 -1
- package/dist/esm/knobImmuneExports.mjs.map +1 -1
- package/dist/esm/knobImmuneExports.native.js +0 -1
- package/dist/esm/knobImmuneExports.native.js.map +1 -1
- package/dist/esm/layouts/attachments.mjs +3 -2
- package/dist/esm/layouts/attachments.mjs.map +1 -1
- package/dist/esm/layouts/attachments.native.js +3 -2
- package/dist/esm/layouts/attachments.native.js.map +1 -1
- package/dist/esm/layouts/breadcrumbs.mjs +3 -2
- package/dist/esm/layouts/breadcrumbs.mjs.map +1 -1
- package/dist/esm/layouts/breadcrumbs.native.js +3 -2
- package/dist/esm/layouts/breadcrumbs.native.js.map +1 -1
- package/dist/esm/layouts/page.mjs +80 -10
- package/dist/esm/layouts/page.mjs.map +1 -1
- package/dist/esm/layouts/page.native.js +82 -10
- package/dist/esm/layouts/page.native.js.map +1 -1
- package/dist/esm/layouts/sidebar.mjs +5 -3
- package/dist/esm/layouts/sidebar.mjs.map +1 -1
- package/dist/esm/layouts/sidebar.native.js +5 -3
- package/dist/esm/layouts/sidebar.native.js.map +1 -1
- package/dist/esm/layouts/tags.mjs +6 -5
- package/dist/esm/layouts/tags.mjs.map +1 -1
- package/dist/esm/layouts/tags.native.js +6 -5
- package/dist/esm/layouts/tags.native.js.map +1 -1
- package/dist/esm/layouts/timeline.mjs +4 -3
- package/dist/esm/layouts/timeline.mjs.map +1 -1
- package/dist/esm/layouts/timeline.native.js +4 -3
- package/dist/esm/layouts/timeline.native.js.map +1 -1
- package/dist/esm/layouts/toolbar.mjs +2 -1
- package/dist/esm/layouts/toolbar.mjs.map +1 -1
- package/dist/esm/layouts/toolbar.native.js +2 -1
- package/dist/esm/layouts/toolbar.native.js.map +1 -1
- package/dist/esm/linearGradientSetup.mjs +2 -0
- package/dist/esm/linearGradientSetup.mjs.map +1 -0
- package/dist/esm/linearGradientSetup.native.js +2 -0
- package/dist/esm/linearGradientSetup.native.js.map +1 -0
- package/dist/esm/tamagui.mjs +2 -1
- package/dist/esm/tamagui.mjs.map +1 -1
- package/dist/esm/tamagui.native.js +2 -1
- package/dist/esm/tamagui.native.js.map +1 -1
- package/dist/esm/views/Calendar.mjs +7 -6
- package/dist/esm/views/Calendar.mjs.map +1 -1
- package/dist/esm/views/Calendar.native.js +7 -6
- package/dist/esm/views/Calendar.native.js.map +1 -1
- package/dist/esm/views/Gantt.mjs +196 -63
- package/dist/esm/views/Gantt.mjs.map +1 -1
- package/dist/esm/views/Gantt.native.js +209 -63
- package/dist/esm/views/Gantt.native.js.map +1 -1
- package/dist/esm/views/GanttDateGrip.mjs +191 -0
- package/dist/esm/views/GanttDateGrip.mjs.map +1 -0
- package/dist/esm/views/GanttDateGrip.native.js +231 -0
- package/dist/esm/views/GanttDateGrip.native.js.map +1 -0
- package/dist/esm/views/Kanban.mjs +5 -4
- package/dist/esm/views/Kanban.mjs.map +1 -1
- package/dist/esm/views/Kanban.native.js +3 -2
- package/dist/esm/views/Kanban.native.js.map +1 -1
- package/dist/esm/views/List.mjs +13 -5
- package/dist/esm/views/List.mjs.map +1 -1
- package/dist/esm/views/List.native.js +14 -5
- package/dist/esm/views/List.native.js.map +1 -1
- package/dist/esm/views/Matrix.mjs +10 -9
- package/dist/esm/views/Matrix.mjs.map +1 -1
- package/dist/esm/views/Matrix.native.js +10 -9
- package/dist/esm/views/Matrix.native.js.map +1 -1
- package/dist/esm/views/TreeView.mjs +5 -4
- package/dist/esm/views/TreeView.mjs.map +1 -1
- package/dist/esm/views/TreeView.native.js +5 -4
- package/dist/esm/views/TreeView.native.js.map +1 -1
- package/dist/esm/views/ganttIntervals.mjs +57 -0
- package/dist/esm/views/ganttIntervals.mjs.map +1 -0
- package/dist/esm/views/ganttIntervals.native.js +61 -0
- package/dist/esm/views/ganttIntervals.native.js.map +1 -0
- package/dist/jsx/Alert/index.mjs +2 -2
- package/dist/jsx/Alert/index.mjs.map +1 -1
- package/dist/jsx/Alert/index.native.js +1 -1
- package/dist/jsx/Alert/index.native.js.map +1 -1
- package/dist/jsx/Carousel/index.mjs +1 -1
- package/dist/jsx/Carousel/index.mjs.map +1 -1
- package/dist/jsx/Carousel/index.native.js +1 -1
- package/dist/jsx/Carousel/index.native.js.map +1 -1
- package/dist/jsx/Chip/index.mjs +18 -7
- package/dist/jsx/Chip/index.mjs.map +1 -1
- package/dist/jsx/Chip/index.native.js +20 -8
- package/dist/jsx/Chip/index.native.js.map +1 -1
- package/dist/jsx/DropdownMenu/index.mjs +5 -1
- package/dist/jsx/DropdownMenu/index.mjs.map +1 -1
- package/dist/jsx/DropdownMenu/index.native.js +5 -1
- package/dist/jsx/DropdownMenu/index.native.js.map +1 -1
- package/dist/jsx/ErrorBoundary/index.mjs +1 -1
- package/dist/jsx/ErrorBoundary/index.mjs.map +1 -1
- package/dist/jsx/ErrorBoundary/index.native.js +2 -2
- package/dist/jsx/ErrorBoundary/index.native.js.map +1 -1
- package/dist/jsx/Heading.mjs +1 -120
- package/dist/jsx/Heading.mjs.map +1 -1
- package/dist/jsx/Heading.native.js +7 -133
- package/dist/jsx/Heading.native.js.map +1 -1
- package/dist/jsx/OverflowRow/index.mjs.map +1 -1
- package/dist/jsx/OverflowRow/index.native.js +1 -0
- package/dist/jsx/OverflowRow/index.native.js.map +1 -1
- package/dist/jsx/Pagination.mjs +4 -1
- package/dist/jsx/Pagination.mjs.map +1 -1
- package/dist/jsx/Pagination.native.js +4 -1
- package/dist/jsx/Pagination.native.js.map +1 -1
- package/dist/jsx/Popover.mjs +120 -0
- package/dist/jsx/Popover.mjs.map +1 -0
- package/dist/jsx/Popover.native.js +174 -0
- package/dist/jsx/Popover.native.js.map +1 -0
- package/dist/jsx/ProgressSteps/index.mjs +2 -2
- package/dist/jsx/ProgressSteps/index.mjs.map +1 -1
- package/dist/jsx/ProgressSteps/index.native.js +1 -1
- package/dist/jsx/ProgressSteps/index.native.js.map +1 -1
- package/dist/jsx/Quote/index.mjs +2 -1
- package/dist/jsx/Quote/index.mjs.map +1 -1
- package/dist/jsx/Quote/index.native.js +1 -0
- package/dist/jsx/Quote/index.native.js.map +1 -1
- package/dist/jsx/SkipLink/index.mjs +1 -2
- package/dist/jsx/SkipLink/index.mjs.map +1 -1
- package/dist/jsx/SkipLink/index.native.js +1 -2
- package/dist/jsx/SkipLink/index.native.js.map +1 -1
- package/dist/jsx/SortableList/index.mjs +5 -4
- package/dist/jsx/SortableList/index.mjs.map +1 -1
- package/dist/jsx/SortableList/index.native.js +2 -1
- package/dist/jsx/SortableList/index.native.js.map +1 -1
- package/dist/jsx/SortableList/useSortableRows.mjs +2 -2
- package/dist/jsx/SortableList/useSortableRows.mjs.map +1 -1
- package/dist/jsx/SortableList/useSortableRows.native.js +2 -2
- package/dist/jsx/SortableList/useSortableRows.native.js.map +1 -1
- package/dist/jsx/Text.mjs +1 -112
- package/dist/jsx/Text.mjs.map +1 -1
- package/dist/jsx/Text.native.js +4 -120
- package/dist/jsx/Text.native.js.map +1 -1
- package/dist/jsx/ThemePlayground/index.mjs +2 -1
- package/dist/jsx/ThemePlayground/index.mjs.map +1 -1
- package/dist/jsx/ThemePresetPicker/index.mjs +21 -22
- package/dist/jsx/ThemePresetPicker/index.mjs.map +1 -1
- package/dist/jsx/ThemePresetPicker/index.native.js +21 -22
- package/dist/jsx/ThemePresetPicker/index.native.js.map +1 -1
- package/dist/jsx/Tooltip/index.mjs +6 -0
- package/dist/jsx/Tooltip/index.mjs.map +1 -1
- package/dist/jsx/TreeSelect/index.mjs +6 -5
- package/dist/jsx/TreeSelect/index.mjs.map +1 -1
- package/dist/jsx/TreeSelect/index.native.js +2 -1
- package/dist/jsx/TreeSelect/index.native.js.map +1 -1
- package/dist/jsx/Video/PlayerChrome.mjs +1 -1
- package/dist/jsx/Video/PlayerChrome.mjs.map +1 -1
- package/dist/jsx/Video/PlayerChrome.native.js +1 -1
- package/dist/jsx/Video/PlayerChrome.native.js.map +1 -1
- package/dist/jsx/Video/VideoFrame.mjs +3 -2
- package/dist/jsx/Video/VideoFrame.mjs.map +1 -1
- package/dist/jsx/Video/VideoFrame.native.js +2 -1
- package/dist/jsx/Video/VideoFrame.native.js.map +1 -1
- package/dist/jsx/Video/index.mjs +3 -1
- package/dist/jsx/Video/index.mjs.map +1 -1
- package/dist/jsx/actions/DestructiveAction.mjs +2 -1
- package/dist/jsx/actions/DestructiveAction.mjs.map +1 -1
- package/dist/jsx/actions/DestructiveAction.native.js +3 -2
- package/dist/jsx/actions/DestructiveAction.native.js.map +1 -1
- package/dist/jsx/appShell/ScopeMenu.mjs +2 -1
- package/dist/jsx/appShell/ScopeMenu.mjs.map +1 -1
- package/dist/jsx/appShell/ScopeMenu.native.js +2 -1
- package/dist/jsx/appShell/ScopeMenu.native.js.map +1 -1
- package/dist/jsx/appShell/SettingsSplit.mjs +5 -4
- package/dist/jsx/appShell/SettingsSplit.mjs.map +1 -1
- package/dist/jsx/appShell/SettingsSplit.native.js +5 -4
- package/dist/jsx/appShell/SettingsSplit.native.js.map +1 -1
- package/dist/jsx/appShell/Springboard.mjs +3 -2
- package/dist/jsx/appShell/Springboard.mjs.map +1 -1
- package/dist/jsx/appShell/Springboard.native.js +2 -1
- package/dist/jsx/appShell/Springboard.native.js.map +1 -1
- package/dist/jsx/appShell/SystemBar.mjs +2 -1
- package/dist/jsx/appShell/SystemBar.mjs.map +1 -1
- package/dist/jsx/appShell/SystemBar.native.js +2 -1
- package/dist/jsx/appShell/SystemBar.native.js.map +1 -1
- package/dist/jsx/feedback/ConfirmDialog.mjs +1 -1
- package/dist/jsx/feedback/ConfirmDialog.mjs.map +1 -1
- package/dist/jsx/feedback/ConfirmDialog.native.js +1 -1
- package/dist/jsx/feedback/ConfirmDialog.native.js.map +1 -1
- package/dist/jsx/knobImmuneExports.mjs +0 -1
- package/dist/jsx/knobImmuneExports.mjs.map +1 -1
- package/dist/jsx/knobImmuneExports.native.js +0 -1
- package/dist/jsx/knobImmuneExports.native.js.map +1 -1
- package/dist/jsx/layouts/attachments.mjs +3 -2
- package/dist/jsx/layouts/attachments.mjs.map +1 -1
- package/dist/jsx/layouts/attachments.native.js +11 -10
- package/dist/jsx/layouts/attachments.native.js.map +1 -1
- package/dist/jsx/layouts/breadcrumbs.mjs +3 -2
- package/dist/jsx/layouts/breadcrumbs.mjs.map +1 -1
- package/dist/jsx/layouts/breadcrumbs.native.js +3 -2
- package/dist/jsx/layouts/breadcrumbs.native.js.map +1 -1
- package/dist/jsx/layouts/page.mjs +80 -10
- package/dist/jsx/layouts/page.mjs.map +1 -1
- package/dist/jsx/layouts/page.native.js +82 -8
- package/dist/jsx/layouts/page.native.js.map +1 -1
- package/dist/jsx/layouts/sidebar.mjs +5 -3
- package/dist/jsx/layouts/sidebar.mjs.map +1 -1
- package/dist/jsx/layouts/sidebar.native.js +3 -1
- package/dist/jsx/layouts/sidebar.native.js.map +1 -1
- package/dist/jsx/layouts/tags.mjs +6 -5
- package/dist/jsx/layouts/tags.mjs.map +1 -1
- package/dist/jsx/layouts/tags.native.js +2 -1
- package/dist/jsx/layouts/tags.native.js.map +1 -1
- package/dist/jsx/layouts/timeline.mjs +4 -3
- package/dist/jsx/layouts/timeline.mjs.map +1 -1
- package/dist/jsx/layouts/timeline.native.js +14 -13
- package/dist/jsx/layouts/timeline.native.js.map +1 -1
- package/dist/jsx/layouts/toolbar.mjs +2 -1
- package/dist/jsx/layouts/toolbar.mjs.map +1 -1
- package/dist/jsx/layouts/toolbar.native.js +2 -1
- package/dist/jsx/layouts/toolbar.native.js.map +1 -1
- package/dist/jsx/linearGradientSetup.mjs +2 -0
- package/dist/jsx/linearGradientSetup.mjs.map +1 -0
- package/dist/jsx/linearGradientSetup.native.js +4 -0
- package/dist/jsx/linearGradientSetup.native.js.map +1 -0
- package/dist/jsx/tamagui.mjs +2 -1
- package/dist/jsx/tamagui.mjs.map +1 -1
- package/dist/jsx/tamagui.native.js +2 -1
- package/dist/jsx/tamagui.native.js.map +1 -1
- package/dist/jsx/views/Calendar.mjs +7 -6
- package/dist/jsx/views/Calendar.mjs.map +1 -1
- package/dist/jsx/views/Calendar.native.js +14 -13
- package/dist/jsx/views/Calendar.native.js.map +1 -1
- package/dist/jsx/views/Gantt.mjs +196 -63
- package/dist/jsx/views/Gantt.mjs.map +1 -1
- package/dist/jsx/views/Gantt.native.js +201 -55
- package/dist/jsx/views/Gantt.native.js.map +1 -1
- package/dist/jsx/views/GanttDateGrip.mjs +191 -0
- package/dist/jsx/views/GanttDateGrip.mjs.map +1 -0
- package/dist/jsx/views/GanttDateGrip.native.js +259 -0
- package/dist/jsx/views/GanttDateGrip.native.js.map +1 -0
- package/dist/jsx/views/Kanban.mjs +5 -4
- package/dist/jsx/views/Kanban.mjs.map +1 -1
- package/dist/jsx/views/Kanban.native.js +3 -2
- package/dist/jsx/views/Kanban.native.js.map +1 -1
- package/dist/jsx/views/List.mjs +13 -5
- package/dist/jsx/views/List.mjs.map +1 -1
- package/dist/jsx/views/List.native.js +14 -3
- package/dist/jsx/views/List.native.js.map +1 -1
- package/dist/jsx/views/Matrix.mjs +10 -9
- package/dist/jsx/views/Matrix.mjs.map +1 -1
- package/dist/jsx/views/Matrix.native.js +2 -1
- package/dist/jsx/views/Matrix.native.js.map +1 -1
- package/dist/jsx/views/TreeView.mjs +5 -4
- package/dist/jsx/views/TreeView.mjs.map +1 -1
- package/dist/jsx/views/TreeView.native.js +3 -2
- package/dist/jsx/views/TreeView.native.js.map +1 -1
- package/dist/jsx/views/ganttIntervals.mjs +57 -0
- package/dist/jsx/views/ganttIntervals.mjs.map +1 -0
- package/dist/jsx/views/ganttIntervals.native.js +92 -0
- package/dist/jsx/views/ganttIntervals.native.js.map +1 -0
- package/package.json +12 -10
- package/src/Accordion/Accordion.stories.tsx +2 -1
- package/src/Alert/Alert.stories.tsx +2 -1
- package/src/Alert/index.tsx +2 -1
- package/src/AnimateHeight/AnimateHeight.stories.tsx +2 -1
- package/src/Avatar/Avatar.stories.tsx +2 -1
- package/src/Badge/Badge.stories.tsx +2 -1
- package/src/Card.stories.tsx +2 -1
- package/src/CardFooter.stories.tsx +2 -1
- package/src/CardHeader.stories.tsx +2 -1
- package/src/Carousel/Carousel.stories.tsx +2 -1
- package/src/Carousel/index.tsx +1 -1
- package/src/Chip/Chip.borderLadder.spec.tsx +3 -3
- package/src/Chip/Chip.ink.spec.tsx +70 -2
- package/src/Chip/Chip.spec.tsx +7 -4
- package/src/Chip/Chip.stories.tsx +2 -1
- package/src/Chip/index.tsx +29 -7
- package/src/ContextMenu/ContextMenu.stories.tsx +2 -1
- package/src/DialogContent.stories.tsx +2 -1
- package/src/DotIndicator/DotIndicator.stories.tsx +2 -1
- package/src/DropdownMenu/DropdownMenu.stories.tsx +21 -1
- package/src/DropdownMenu/index.tsx +6 -0
- package/src/ErrorBoundary/ErrorBoundary.stories.tsx +2 -1
- package/src/ErrorBoundary/index.tsx +1 -1
- package/src/Heading.native.spec.tsx +13 -5
- package/src/Heading.spec.tsx +55 -11
- package/src/Heading.tsx +3 -66
- package/src/Meter/Meter.spec.tsx +4 -4
- package/src/OverflowRow/index.tsx +1 -0
- package/src/Pagination.stories.tsx +2 -1
- package/src/Pagination.tsx +9 -1
- package/src/Panel.stories.tsx +2 -1
- package/src/Popover.coverTrigger.spec.tsx +99 -0
- package/src/Popover.tsx +180 -0
- package/src/PopoverContent.stories.tsx +23 -1
- package/src/ProgressSteps/index.tsx +5 -1
- package/src/Quote/index.tsx +9 -2
- package/src/Separator/Separator.stories.tsx +2 -1
- package/src/SheetFrame.stories.tsx +2 -1
- package/src/SheetModal/SheetModal.stories.tsx +2 -1
- package/src/Skeleton/Skeleton.stories.tsx +2 -1
- package/src/SkipLink/SkipLink.stories.tsx +2 -1
- package/src/SkipLink/index.tsx +1 -2
- package/src/SortableList/index.tsx +14 -6
- package/src/SortableList/useSortableRows.ts +3 -2
- package/src/Tabs/Tabs.stories.tsx +2 -1
- package/src/Text.spec.tsx +22 -0
- package/src/Text.tsx +9 -133
- package/src/ThemePlayground/ExpoThemeColors.stories.tsx +60 -0
- package/src/ThemePlayground/index.tsx +2 -1
- package/src/ThemePresetPicker/ThemePresetPicker.spec.tsx +20 -0
- package/src/ThemePresetPicker/ThemePresetPicker.stories.spec.tsx +34 -12
- package/src/ThemePresetPicker/ThemePresetPicker.stories.tsx +11 -3
- package/src/ThemePresetPicker/index.tsx +35 -29
- package/src/Toast/Toast.stories.tsx +2 -1
- package/src/Tooltip/Tooltip.spec.tsx +14 -1
- package/src/Tooltip/index.tsx +7 -0
- package/src/TreeSelect/index.tsx +10 -9
- package/src/Video/PlayerChrome.tsx +1 -1
- package/src/Video/VideoFrame.tsx +4 -3
- package/src/Video/index.tsx +3 -1
- package/src/Wheel/Wheel.stories.tsx +2 -1
- package/src/actions/ActionBar.stories.tsx +2 -1
- package/src/actions/DestructiveAction.stories.tsx +2 -1
- package/src/actions/DestructiveAction.tsx +2 -1
- package/src/appShell/ScopeMenu.tsx +2 -1
- package/src/appShell/SettingsSplit.stories.tsx +2 -1
- package/src/appShell/SettingsSplit.tsx +6 -5
- package/src/appShell/Springboard.tsx +3 -2
- package/src/appShell/SystemBar.tsx +2 -1
- package/src/charts/Axis.stories.tsx +2 -1
- package/src/charts/ChartSurface.stories.tsx +2 -1
- package/src/charts/Charts.stories.tsx +2 -1
- package/src/code/CodeInline.stories.tsx +3 -1
- package/src/feedback/ConfirmDialog.stories.tsx +2 -1
- package/src/feedback/ConfirmDialog.tsx +1 -1
- package/src/feedback/Notify.stories.tsx +2 -1
- package/src/icons/CheckRegular.stories.tsx +2 -1
- package/src/icons/MinusRegular.stories.tsx +2 -1
- package/src/knobImmuneExports.ts +0 -1
- package/src/layouts/AsyncBoundary.stories.tsx +2 -1
- package/src/layouts/Attachments.stories.tsx +2 -1
- package/src/layouts/Debug/DebugLayout.stories.tsx +2 -1
- package/src/layouts/KeyboardAvoidingWrapper/KeyboardAvoidingWrapper.stories.tsx +2 -2
- package/src/layouts/PageHeader.stories.tsx +2 -1
- package/src/layouts/PageSection.stories.tsx +2 -1
- package/src/layouts/PageTemplates.stories.tsx +64 -2
- package/src/layouts/PaneScaffold.stories.tsx +2 -2
- package/src/layouts/SafeAreaWrapper/SafeAreaWrapper.stories.tsx +2 -2
- package/src/layouts/Screen.stories.tsx +2 -1
- package/src/layouts/Sidebar.stories.tsx +2 -1
- package/src/layouts/Tags.stories.tsx +2 -1
- package/src/layouts/Timeline.stories.tsx +2 -1
- package/src/layouts/Toolbar.stories.tsx +2 -1
- package/src/layouts/ViewSwitcher.stories.tsx +2 -1
- package/src/layouts/attachments.tsx +4 -3
- package/src/layouts/breadcrumbs.tsx +4 -3
- package/src/layouts/page.tsx +98 -9
- package/src/layouts/pageChrome.phone.spec.tsx +58 -0
- package/src/layouts/sidebar.tsx +7 -5
- package/src/layouts/tags-trigger.spec.tsx +3 -3
- package/src/layouts/tags.tsx +14 -9
- package/src/layouts/timeline.tsx +6 -5
- package/src/layouts/toolbar.tsx +2 -1
- package/src/linearGradientSetup.native.spec.ts +19 -0
- package/src/linearGradientSetup.native.ts +3 -0
- package/src/linearGradientSetup.ts +1 -0
- package/src/tamagui.spec.ts +2 -3
- package/src/tamagui.ts +2 -2
- package/src/views/Calendar.tsx +12 -11
- package/src/views/Gantt.intervals.spec.tsx +69 -0
- package/src/views/Gantt.scroll.spec.tsx +42 -0
- package/src/views/Gantt.spec.tsx +4 -5
- package/src/views/Gantt.stories.tsx +19 -0
- package/src/views/Gantt.tsx +230 -106
- package/src/views/GanttDateGrip.native.spec.tsx +118 -0
- package/src/views/GanttDateGrip.tsx +266 -0
- package/src/views/ImageGrid.stories.tsx +2 -1
- package/src/views/Kanban.native.spec.tsx +98 -0
- package/src/views/Kanban.native.tsx +3 -2
- package/src/views/Kanban.stories.tsx +2 -1
- package/src/views/Kanban.tsx +15 -6
- package/src/views/List.spec.tsx +18 -0
- package/src/views/List.tsx +17 -2
- package/src/views/Matrix.tsx +22 -17
- package/src/views/TreeView.reveal.stories.tsx +2 -1
- package/src/views/TreeView.tsx +15 -6
- package/src/views/dataIdentity.spec.tsx +5 -1
- package/src/views/ganttIntervals.spec.ts +84 -0
- package/src/views/ganttIntervals.ts +91 -0
- package/src/views/index.ts +2 -0
- package/types/Alert/index.d.ts.map +1 -1
- package/types/Chip/index.d.ts +5 -3
- package/types/Chip/index.d.ts.map +1 -1
- package/types/Collapsible.d.ts +1 -1
- package/types/DropdownMenu/index.d.ts +3 -1
- package/types/DropdownMenu/index.d.ts.map +1 -1
- package/types/Heading.d.ts +2 -9
- package/types/Heading.d.ts.map +1 -1
- package/types/OverflowRow/index.d.ts +1 -0
- package/types/OverflowRow/index.d.ts.map +1 -1
- package/types/Pagination.d.ts +6 -1
- package/types/Pagination.d.ts.map +1 -1
- package/types/Popover.d.ts +114 -0
- package/types/Popover.d.ts.map +1 -0
- package/types/ProgressSteps/index.d.ts.map +1 -1
- package/types/Quote/index.d.ts.map +1 -1
- package/types/SkipLink/index.d.ts.map +1 -1
- package/types/SortableList/index.d.ts.map +1 -1
- package/types/SortableList/useSortableRows.d.ts.map +1 -1
- package/types/Tabs/index.d.ts +1 -1
- package/types/Text.d.ts +2 -12
- package/types/Text.d.ts.map +1 -1
- package/types/ThemePlayground/index.d.ts.map +1 -1
- package/types/ThemePresetPicker/index.d.ts +3 -1
- package/types/ThemePresetPicker/index.d.ts.map +1 -1
- package/types/Tooltip/index.d.ts.map +1 -1
- package/types/TreeSelect/index.d.ts.map +1 -1
- package/types/Video/VideoFrame.d.ts.map +1 -1
- package/types/Video/index.d.ts.map +1 -1
- package/types/actions/DestructiveAction.d.ts.map +1 -1
- package/types/appShell/ScopeMenu.d.ts.map +1 -1
- package/types/appShell/SettingsSplit.d.ts.map +1 -1
- package/types/appShell/Springboard.d.ts.map +1 -1
- package/types/appShell/SystemBar.d.ts.map +1 -1
- package/types/knobImmuneExports.d.ts.map +1 -1
- package/types/layouts/attachments.d.ts.map +1 -1
- package/types/layouts/breadcrumbs.d.ts.map +1 -1
- package/types/layouts/page.d.ts +21 -3
- package/types/layouts/page.d.ts.map +1 -1
- package/types/layouts/sidebar.d.ts.map +1 -1
- package/types/layouts/tags.d.ts.map +1 -1
- package/types/layouts/timeline.d.ts.map +1 -1
- package/types/layouts/toolbar.d.ts.map +1 -1
- package/types/linearGradientSetup.d.ts +2 -0
- package/types/linearGradientSetup.d.ts.map +1 -0
- package/types/linearGradientSetup.native.d.ts +2 -0
- package/types/linearGradientSetup.native.d.ts.map +1 -0
- package/types/tamagui.d.ts +3 -2
- package/types/tamagui.d.ts.map +1 -1
- package/types/views/Calendar.d.ts.map +1 -1
- package/types/views/Gantt.d.ts +9 -21
- package/types/views/Gantt.d.ts.map +1 -1
- package/types/views/GanttDateGrip.d.ts +22 -0
- package/types/views/GanttDateGrip.d.ts.map +1 -0
- package/types/views/Kanban.d.ts.map +1 -1
- package/types/views/List.d.ts +17 -0
- package/types/views/List.d.ts.map +1 -1
- package/types/views/Matrix.d.ts.map +1 -1
- package/types/views/TreeView.d.ts.map +1 -1
- package/types/views/ganttIntervals.d.ts +11 -0
- package/types/views/ganttIntervals.d.ts.map +1 -0
- package/types/views/index.d.ts +1 -0
- package/types/views/index.d.ts.map +1 -1
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
import { action } from "@multiplatform.one/storybook";
|
|
2
2
|
import type { Meta, StoryObj } from "@storybook/react-native-web-vite";
|
|
3
|
-
import {
|
|
3
|
+
import { View, YStack } from "tamagui";
|
|
4
4
|
import { Image } from "../images/Image";
|
|
5
5
|
import { Card } from "../surfaces";
|
|
6
6
|
import { Carousel } from "./index";
|
|
7
|
+
import { Text } from "../Text";
|
|
7
8
|
|
|
8
9
|
const meta: Meta<typeof Carousel> = {
|
|
9
10
|
title: "Components/Carousel",
|
package/src/Carousel/index.tsx
CHANGED
|
@@ -74,7 +74,7 @@ function ensureCarouselArrowRing() {
|
|
|
74
74
|
}
|
|
75
75
|
|
|
76
76
|
function isTypingTarget(target: EventTarget | null): boolean {
|
|
77
|
-
if (!(target instanceof HTMLElement)) return false;
|
|
77
|
+
if (typeof HTMLElement === "undefined" || !(target instanceof HTMLElement)) return false;
|
|
78
78
|
const tag = target.tagName;
|
|
79
79
|
return tag === "INPUT" || tag === "TEXTAREA" || tag === "SELECT" || target.isContentEditable;
|
|
80
80
|
}
|
|
@@ -37,9 +37,9 @@ function renderAt(stop: (typeof STOPS)[number], outlined = false): string[] {
|
|
|
37
37
|
}
|
|
38
38
|
|
|
39
39
|
describe("Chip borderWidth ladder (MPO-134)", () => {
|
|
40
|
-
it("the frame honours the resolver's edge: 0 /
|
|
40
|
+
it("the frame honours the resolver's edge: 0 / hairline / 1 / 2 (web hairline is 1px, LC-148)", () => {
|
|
41
41
|
expect(renderAt("none")).toEqual(["_btw-0px"]);
|
|
42
|
-
expect(renderAt("small")).toEqual(["_btw-
|
|
42
|
+
expect(renderAt("small")).toEqual(["_btw-1px"]);
|
|
43
43
|
expect(renderAt("medium")).toEqual(["_btw-1px"]);
|
|
44
44
|
expect(renderAt("large")).toEqual(["_btw-2px"]);
|
|
45
45
|
});
|
|
@@ -49,6 +49,6 @@ describe("Chip borderWidth ladder (MPO-134)", () => {
|
|
|
49
49
|
});
|
|
50
50
|
|
|
51
51
|
it("none under fillStyle:outlined is the resolver's hairline, not a local floor", () => {
|
|
52
|
-
expect(renderAt("none", true)).toEqual(["_btw-
|
|
52
|
+
expect(renderAt("none", true)).toEqual(["_btw-1px"]);
|
|
53
53
|
});
|
|
54
54
|
});
|
|
@@ -1,9 +1,77 @@
|
|
|
1
|
-
import { render } from "@testing-library/react";
|
|
1
|
+
import { cleanup, render } from "@testing-library/react";
|
|
2
2
|
import { expect, it } from "vitest";
|
|
3
|
-
import {
|
|
3
|
+
import {
|
|
4
|
+
contrastRatio,
|
|
5
|
+
createDefaultThemeConfig,
|
|
6
|
+
normalizeToHex,
|
|
7
|
+
relativeLuminance,
|
|
8
|
+
} from "@multiplatform.one/theme";
|
|
4
9
|
import { TamaguiProvider, Theme } from "tamagui";
|
|
5
10
|
import { Chip } from "./index";
|
|
6
11
|
|
|
12
|
+
it("draws a selected chip with the theme's selected recipe: its tint, its ink, the same edge", () => {
|
|
13
|
+
const config = createDefaultThemeConfig({});
|
|
14
|
+
const view = render(
|
|
15
|
+
<TamaguiProvider config={config.tamagui} defaultTheme="light">
|
|
16
|
+
<Theme name="purple">
|
|
17
|
+
<Chip selected onPress={() => {}}>
|
|
18
|
+
Chosen
|
|
19
|
+
</Chip>
|
|
20
|
+
<Chip onPress={() => {}}>Other</Chip>
|
|
21
|
+
</Theme>
|
|
22
|
+
</TamaguiProvider>,
|
|
23
|
+
);
|
|
24
|
+
const purple = config.tamagui.themes.light_purple as unknown as Record<string, { val: string }>;
|
|
25
|
+
const frame = (text: string) => view.getByText(text).closest("[data-chip]") as HTMLElement;
|
|
26
|
+
const paint = (text: string) => ({
|
|
27
|
+
fill: normalizeToHex(getComputedStyle(frame(text)).backgroundColor),
|
|
28
|
+
edge: normalizeToHex(getComputedStyle(frame(text)).borderTopColor),
|
|
29
|
+
ink: normalizeToHex(getComputedStyle(view.getByText(text)).color),
|
|
30
|
+
});
|
|
31
|
+
expect(paint("Chosen")).toEqual({
|
|
32
|
+
fill: normalizeToHex(purple.selectedBackground.val),
|
|
33
|
+
edge: paint("Other").edge,
|
|
34
|
+
ink: normalizeToHex(purple.selectedColor.val),
|
|
35
|
+
});
|
|
36
|
+
expect(paint("Other").fill).not.toBe(paint("Chosen").fill);
|
|
37
|
+
expect(paint("Other").ink).not.toBe(paint("Chosen").ink);
|
|
38
|
+
cleanup();
|
|
39
|
+
});
|
|
40
|
+
|
|
41
|
+
it.each(["light", "dark"] as const)(
|
|
42
|
+
"keeps the selected label readable in every %s colour theme",
|
|
43
|
+
(scheme) => {
|
|
44
|
+
const config = createDefaultThemeConfig({});
|
|
45
|
+
for (const hue of ["blue", "gray", "green", "orange", "pink", "purple", "red", "yellow"]) {
|
|
46
|
+
const view = render(
|
|
47
|
+
<TamaguiProvider config={config.tamagui} defaultTheme={scheme}>
|
|
48
|
+
<Theme name={hue}>
|
|
49
|
+
<Chip selected onPress={() => {}}>
|
|
50
|
+
Chosen
|
|
51
|
+
</Chip>
|
|
52
|
+
</Theme>
|
|
53
|
+
</TamaguiProvider>,
|
|
54
|
+
);
|
|
55
|
+
const frame = view.container.querySelector("[data-chip]") as HTMLElement;
|
|
56
|
+
const fill = normalizeToHex(getComputedStyle(frame).backgroundColor)!;
|
|
57
|
+
const ink = normalizeToHex(getComputedStyle(view.getByText("Chosen")).color)!;
|
|
58
|
+
const themes = config.tamagui.themes as unknown as Record<
|
|
59
|
+
string,
|
|
60
|
+
Record<string, { val: string } | undefined>
|
|
61
|
+
>;
|
|
62
|
+
const token = (key: string) =>
|
|
63
|
+
normalizeToHex((themes[`${scheme}_${hue}`]?.[key] ?? themes[scheme]?.[key])!.val);
|
|
64
|
+
expect(fill).toBe(token("selectedBackground"));
|
|
65
|
+
expect(ink).toBe(token("selectedColor"));
|
|
66
|
+
expect(contrastRatio(relativeLuminance(fill), relativeLuminance(ink))).toBeGreaterThanOrEqual(
|
|
67
|
+
4.5,
|
|
68
|
+
);
|
|
69
|
+
expect(normalizeToHex(frame.querySelector("svg")!.getAttribute("fill") ?? "")).toBe(ink);
|
|
70
|
+
cleanup();
|
|
71
|
+
}
|
|
72
|
+
},
|
|
73
|
+
);
|
|
74
|
+
|
|
7
75
|
it("keeps the selected check and label ink matched as the mounted chip changes from Light to Dark", () => {
|
|
8
76
|
const config = createDefaultThemeConfig({});
|
|
9
77
|
function Fixture({ scheme }: { scheme: "light" | "dark" }) {
|
package/src/Chip/Chip.spec.tsx
CHANGED
|
@@ -77,7 +77,7 @@ describe("Chip", () => {
|
|
|
77
77
|
expect(chipTone(undefined)).toBe("ghost");
|
|
78
78
|
});
|
|
79
79
|
|
|
80
|
-
it("selected interactive chip is a pressed toggle
|
|
80
|
+
it("selected interactive chip is a pressed toggle on the selection surface", () => {
|
|
81
81
|
const onPress = vi.fn();
|
|
82
82
|
const result = renderWithProviders(
|
|
83
83
|
<Chip selected onPress={onPress}>
|
|
@@ -87,9 +87,12 @@ describe("Chip", () => {
|
|
|
87
87
|
const frame = result.container.querySelector("[data-chip]") as HTMLElement;
|
|
88
88
|
expect(frame.getAttribute("aria-pressed")).toBe("true");
|
|
89
89
|
expect(frame.getAttribute("data-selected")).toBe("true");
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
expect(
|
|
90
|
+
const plain = renderWithProviders(<Chip onPress={() => {}}>Plain</Chip>);
|
|
91
|
+
const plainFrame = plain.container.querySelector("[data-chip]") as HTMLElement;
|
|
92
|
+
expect(frame.className).toContain("_btc-transparent");
|
|
93
|
+
expect(frame.className).not.toEqual(plainFrame.className);
|
|
94
|
+
expect(frame.className).not.toContain("color8");
|
|
95
|
+
expect(result.getByText("Fire").className).not.toContain("_col-color12");
|
|
93
96
|
expect(frame.getAttribute("role")).toBe("button");
|
|
94
97
|
fireEvent.click(frame);
|
|
95
98
|
expect(onPress).toHaveBeenCalledTimes(1);
|
|
@@ -2,8 +2,9 @@ import { action } from "@multiplatform.one/storybook";
|
|
|
2
2
|
import { CheckIcon, LightningIcon, TagIcon } from "@phosphor-icons/react";
|
|
3
3
|
import type { Meta, StoryObj } from "@storybook/react-native-web-vite";
|
|
4
4
|
import { useState } from "react";
|
|
5
|
-
import {
|
|
5
|
+
import { XStack, YStack } from "tamagui";
|
|
6
6
|
import { Chip, type ChipColor, type ChipSize, type ChipVariant } from "./index";
|
|
7
|
+
import { Text } from "../Text";
|
|
7
8
|
|
|
8
9
|
const meta: Meta<typeof Chip> = {
|
|
9
10
|
title: "Components/Chip",
|
package/src/Chip/index.tsx
CHANGED
|
@@ -45,8 +45,10 @@ export interface ChipProps {
|
|
|
45
45
|
color?: ChipColor;
|
|
46
46
|
/** Leading glyph (assist / input). Sized to the chip; omit to get a check when selected. */
|
|
47
47
|
icon?: ReactNode;
|
|
48
|
-
/** Selected/filter-on. LC-
|
|
48
|
+
/** Selected/filter-on. LC-131: the theme's selected recipe on the neutral selection surface. */
|
|
49
49
|
selected?: boolean;
|
|
50
|
+
/** A colour token shown as a leading square, e.g. `$green9` on a colour choice. */
|
|
51
|
+
swatch?: ColorTokens;
|
|
50
52
|
/** Press the pill (filter / assist). Makes the pill a keyboard stop. */
|
|
51
53
|
onPress?: () => void;
|
|
52
54
|
onDismiss?: () => void;
|
|
@@ -341,13 +343,14 @@ export function Chip({
|
|
|
341
343
|
color = "gray",
|
|
342
344
|
icon,
|
|
343
345
|
selected,
|
|
346
|
+
swatch,
|
|
344
347
|
onPress,
|
|
345
348
|
onDismiss,
|
|
346
349
|
disabled,
|
|
347
350
|
maxWidth,
|
|
348
351
|
}: ChipProps) {
|
|
349
352
|
const { t } = useTranslation();
|
|
350
|
-
const { knobProps, control, disabledState } = useResolvedKnobs({ component: "Chip" });
|
|
353
|
+
const { knobProps, control, disabledState, state } = useResolvedKnobs({ component: "Chip" });
|
|
351
354
|
const colors = colorMap[color] ?? colorMap.gray;
|
|
352
355
|
const tone = chipTone(variant);
|
|
353
356
|
const resolvedSize = size ?? (knobProps.sizeToken as ChipSize);
|
|
@@ -367,14 +370,21 @@ export function Chip({
|
|
|
367
370
|
if (dismissStop === "full") dismissRadius = 1000;
|
|
368
371
|
else if (dismissStop) dismissRadius = resolveRadiusClass("CIRCULAR-AT-FULL", dismissStop);
|
|
369
372
|
|
|
373
|
+
// LC-131: the recipe owns the selected drawing. A surface key it leaves out
|
|
374
|
+
// falls back to the neutral selection surface and a transparent edge.
|
|
375
|
+
const selectedSurface: { backgroundColor?: string; borderColor?: string } =
|
|
376
|
+
state.selected.surfaceKnobProps;
|
|
377
|
+
const selectedBackground =
|
|
378
|
+
selectedSurface.backgroundColor ?? componentColors.selection.background;
|
|
379
|
+
|
|
370
380
|
let backgroundColor: ColorTokens | "transparent" | string = colors.tint;
|
|
371
381
|
let textColor: ColorTokens | string = colors.text;
|
|
372
382
|
let borderColor: ColorTokens | "transparent" = "transparent";
|
|
373
383
|
|
|
374
384
|
if (isSelected) {
|
|
375
|
-
backgroundColor =
|
|
376
|
-
textColor =
|
|
377
|
-
borderColor =
|
|
385
|
+
backgroundColor = selectedBackground;
|
|
386
|
+
textColor = state.selected.textKnobProps.color as ColorTokens;
|
|
387
|
+
borderColor = (selectedSurface.borderColor ?? "transparent") as ColorTokens;
|
|
378
388
|
} else if (tone === "filled") {
|
|
379
389
|
backgroundColor = colors.fill;
|
|
380
390
|
textColor = colors.fillText;
|
|
@@ -385,9 +395,11 @@ export function Chip({
|
|
|
385
395
|
borderColor = colors.border;
|
|
386
396
|
}
|
|
387
397
|
|
|
398
|
+
// A selected chip holds its surface through hover and press: $accentColor is
|
|
399
|
+
// held to 4.5:1 on color1..color4, and the hover step is darker than that.
|
|
388
400
|
const hoverBackground = interactive
|
|
389
401
|
? isSelected
|
|
390
|
-
?
|
|
402
|
+
? selectedBackground
|
|
391
403
|
: tone === "outlined"
|
|
392
404
|
? colors.tint
|
|
393
405
|
: tone === "filled"
|
|
@@ -468,7 +480,7 @@ export function Chip({
|
|
|
468
480
|
? {
|
|
469
481
|
...control.pressKnobProps,
|
|
470
482
|
...(isSelected
|
|
471
|
-
? { backgroundColor:
|
|
483
|
+
? { backgroundColor: selectedBackground }
|
|
472
484
|
: hoverBackground != null
|
|
473
485
|
? { backgroundColor: hoverBackground }
|
|
474
486
|
: undefined),
|
|
@@ -483,6 +495,16 @@ export function Chip({
|
|
|
483
495
|
? { onKeyDown: handleKeyDown as unknown as () => void }
|
|
484
496
|
: undefined)}
|
|
485
497
|
>
|
|
498
|
+
{swatch ? (
|
|
499
|
+
<View
|
|
500
|
+
data-chip-swatch=""
|
|
501
|
+
width={iconSize}
|
|
502
|
+
height={iconSize}
|
|
503
|
+
flexShrink={0}
|
|
504
|
+
backgroundColor={swatch}
|
|
505
|
+
{...knobProps.borderRadius}
|
|
506
|
+
/>
|
|
507
|
+
) : null}
|
|
486
508
|
{leading ? (
|
|
487
509
|
// IconSlot (styled View) has no `color`; Tamagui forwards it to set the
|
|
488
510
|
// icon's inherited color at runtime (house Record cast).
|
|
@@ -7,8 +7,9 @@ import {
|
|
|
7
7
|
TrashIcon,
|
|
8
8
|
} from "@phosphor-icons/react";
|
|
9
9
|
import { Button } from "@multiplatform.one/forms";
|
|
10
|
-
import {
|
|
10
|
+
import { YStack, isWeb } from "tamagui";
|
|
11
11
|
import { ContextMenu, type ContextMenuEntry } from "./index";
|
|
12
|
+
import { Text } from "../Text";
|
|
12
13
|
|
|
13
14
|
const meta: Meta<typeof ContextMenu> = {
|
|
14
15
|
title: "Components/ContextMenu",
|
|
@@ -4,9 +4,10 @@ import { useState } from "react";
|
|
|
4
4
|
// DialogContent so it inherits the compact nested-scale step (LC-73); the
|
|
5
5
|
// dialog frame itself does not ring (LC-71).
|
|
6
6
|
import { Button } from "@multiplatform.one/forms";
|
|
7
|
-
import {
|
|
7
|
+
import { XStack, YStack } from "tamagui";
|
|
8
8
|
import { Dialog } from "./Dialog";
|
|
9
9
|
import { DialogContent, DialogOverlay } from "./surfaces";
|
|
10
|
+
import { Paragraph } from "./Text";
|
|
10
11
|
|
|
11
12
|
function DialogHarness({
|
|
12
13
|
long = false,
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import { action } from "@multiplatform.one/storybook";
|
|
2
2
|
import type { Meta, StoryObj } from "@storybook/react-native-web-vite";
|
|
3
3
|
import { useState } from "react";
|
|
4
|
-
import { XStack, YStack
|
|
4
|
+
import { XStack, YStack } from "tamagui";
|
|
5
5
|
import { DotIndicator, type DotVariant } from "./index";
|
|
6
|
+
import { Text } from "../Text";
|
|
6
7
|
|
|
7
8
|
const meta: Meta<typeof DotIndicator> = {
|
|
8
9
|
title: "Components/DotIndicator",
|
|
@@ -12,8 +12,9 @@ import {
|
|
|
12
12
|
} from "@phosphor-icons/react";
|
|
13
13
|
// Catalog Button (G-15 story honesty / LC-18, UX-P06).
|
|
14
14
|
import { Button } from "@multiplatform.one/forms";
|
|
15
|
-
import {
|
|
15
|
+
import { XStack, YStack } from "tamagui";
|
|
16
16
|
import { DropdownMenu, type DropdownMenuEntry } from "./index";
|
|
17
|
+
import { Text } from "../Text";
|
|
17
18
|
|
|
18
19
|
const meta: Meta<typeof DropdownMenu> = {
|
|
19
20
|
title: "Components/DropdownMenu",
|
|
@@ -62,6 +63,25 @@ export const Default: Story = {
|
|
|
62
63
|
),
|
|
63
64
|
};
|
|
64
65
|
|
|
66
|
+
export const CoverTrigger: Story = {
|
|
67
|
+
render: () => (
|
|
68
|
+
<YStack padding="$4" gap="$4" alignItems="flex-start">
|
|
69
|
+
<DropdownMenu
|
|
70
|
+
anchorMode="cover-trigger"
|
|
71
|
+
items={[{ label: "Assigned to me" }, { label: "All entries" }]}
|
|
72
|
+
>
|
|
73
|
+
<Button icon={CaretDownIcon}>Timeline filters</Button>
|
|
74
|
+
</DropdownMenu>
|
|
75
|
+
<DropdownMenu
|
|
76
|
+
anchorMode="cover-trigger"
|
|
77
|
+
items={[{ label: "Overview" }, { label: "Accounts" }]}
|
|
78
|
+
>
|
|
79
|
+
<Button icon={CaretDownIcon}>WealthFlow navigation</Button>
|
|
80
|
+
</DropdownMenu>
|
|
81
|
+
</YStack>
|
|
82
|
+
),
|
|
83
|
+
};
|
|
84
|
+
|
|
65
85
|
export const IconsAndShortcuts: Story = {
|
|
66
86
|
args: { defaultOpen: true },
|
|
67
87
|
render: (args) => (
|
|
@@ -118,6 +118,8 @@ export interface DropdownMenuItemSpec {
|
|
|
118
118
|
export type DropdownMenuEntry = DropdownMenuItemSpec | { separator: true };
|
|
119
119
|
|
|
120
120
|
export interface DropdownMenuProps {
|
|
121
|
+
anchorMode?: "cover-trigger" | "attach";
|
|
122
|
+
triggerRow?: ReactNode;
|
|
121
123
|
/**
|
|
122
124
|
* Composable children (Trigger + Content), or — when `items` is given —
|
|
123
125
|
* the trigger element itself.
|
|
@@ -305,6 +307,8 @@ function DropdownMenuRoot({
|
|
|
305
307
|
closeOnSelect,
|
|
306
308
|
size,
|
|
307
309
|
triggerSizing = "content",
|
|
310
|
+
anchorMode = "cover-trigger",
|
|
311
|
+
triggerRow,
|
|
308
312
|
}: DropdownMenuProps) {
|
|
309
313
|
const [open, setOpen] = useControllableState({
|
|
310
314
|
prop: openProp,
|
|
@@ -402,6 +406,8 @@ function DropdownMenuRoot({
|
|
|
402
406
|
onOpenChange={setOpen}
|
|
403
407
|
skipReturnFocusRef={skipReturnFocusRef}
|
|
404
408
|
trigger={decorateTrigger(trigger, open, onArrow)}
|
|
409
|
+
anchorMode={anchorMode}
|
|
410
|
+
triggerRow={triggerRow}
|
|
405
411
|
contentPadding="none"
|
|
406
412
|
triggerSizing={triggerSizing}
|
|
407
413
|
{...coverContract}
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
import type { Meta, StoryObj } from "@storybook/react-native-web-vite";
|
|
2
2
|
import { useState } from "react";
|
|
3
3
|
import { Button } from "@multiplatform.one/forms";
|
|
4
|
-
import {
|
|
4
|
+
import { YStack } from "tamagui";
|
|
5
5
|
import { ErrorBoundary } from "./index";
|
|
6
|
+
import { Text } from "../Text";
|
|
6
7
|
|
|
7
8
|
const meta: Meta<typeof ErrorBoundary> = {
|
|
8
9
|
title: "Components/ErrorBoundary",
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import type { ErrorInfo, ReactNode } from "react";
|
|
2
2
|
import { Component } from "react";
|
|
3
|
-
import { Text } from "tamagui";
|
|
4
3
|
import { useTranslation } from "../shared/i18n";
|
|
5
4
|
import { Button } from "../Button";
|
|
6
5
|
import { EmptyState } from "../layouts/EmptyState";
|
|
6
|
+
import { Text } from "../Text";
|
|
7
7
|
|
|
8
8
|
const logger = console;
|
|
9
9
|
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
*/
|
|
6
6
|
import { cleanup, screen } from "@testing-library/react";
|
|
7
7
|
import { renderTypography as renderWithProviders } from "../tests/renderTypography";
|
|
8
|
-
import { Preset } from "@multiplatform.one/theme";
|
|
8
|
+
import { Preset, resolvePageTitleScale } from "@multiplatform.one/theme";
|
|
9
9
|
import { afterEach, describe, expect, it, vi } from "vitest";
|
|
10
10
|
import { H1, H3, Heading } from "./Heading";
|
|
11
11
|
|
|
@@ -94,12 +94,20 @@ describe("house Heading — NATIVE environment (isWeb false)", () => {
|
|
|
94
94
|
["_fos-", "_lh-"],
|
|
95
95
|
"H1",
|
|
96
96
|
);
|
|
97
|
-
const
|
|
98
|
-
|
|
97
|
+
const explicitModerate = renderHeadingClasses(
|
|
98
|
+
<H1 {...resolvePageTitleScale("moderate")}>{TITLE}</H1>,
|
|
99
|
+
["_fos-", "_lh-"],
|
|
100
|
+
"H1",
|
|
101
|
+
);
|
|
102
|
+
const explicitDisplay = renderHeadingClasses(
|
|
103
|
+
<H1 {...resolvePageTitleScale("display")}>{TITLE}</H1>,
|
|
104
|
+
["_fos-", "_lh-"],
|
|
105
|
+
"H1",
|
|
106
|
+
);
|
|
99
107
|
expect(moderate).not.toHaveLength(0);
|
|
100
108
|
expect(moderate).not.toEqual(display);
|
|
101
|
-
expect(moderate).toEqual(
|
|
102
|
-
expect(display).toEqual(
|
|
109
|
+
expect(moderate).toEqual(explicitModerate);
|
|
110
|
+
expect(display).toEqual(explicitDisplay);
|
|
103
111
|
});
|
|
104
112
|
|
|
105
113
|
it("H1 carries the fontWeight flip too — pageTitle does not swallow it", () => {
|
package/src/Heading.spec.tsx
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
*/
|
|
5
5
|
import { cleanup, screen } from "@testing-library/react";
|
|
6
6
|
import { renderTypography as renderWithProviders } from "../tests/renderTypography";
|
|
7
|
-
import { Preset } from "@multiplatform.one/theme";
|
|
7
|
+
import { Preset, resolvePageTitleScale } from "@multiplatform.one/theme";
|
|
8
8
|
import { afterEach, describe, expect, it } from "vitest";
|
|
9
9
|
import { H1, H2, H3, Heading } from "./Heading";
|
|
10
10
|
|
|
@@ -191,12 +191,16 @@ describe("house H1 — pageTitleScale reaches the title text node (LC-17 / D-11)
|
|
|
191
191
|
expect(byDefault).not.toEqual(display);
|
|
192
192
|
});
|
|
193
193
|
|
|
194
|
-
it("resolves through the one D-11 table: the knob equals the explicit
|
|
195
|
-
// moderate → $10, display → $12 on the heading
|
|
196
|
-
// pageTitleSizeMap). Identity against
|
|
197
|
-
// fragment
|
|
194
|
+
it("resolves through the one D-11 table: the knob equals the explicit table step", () => {
|
|
195
|
+
// moderate → $10 ($9 below $sm), display → $12 ($11) on the heading
|
|
196
|
+
// scale (resolveKnobs pageTitleSizeMap). Identity against the table's own
|
|
197
|
+
// fragment pins the knob to it without hardcoding hashed classes or px.
|
|
198
198
|
const moderate = renderHeadingClasses(<H1>{TITLE}</H1>, ["_fos-", "_lh-"], "H1");
|
|
199
|
-
const
|
|
199
|
+
const explicitModerate = renderHeadingClasses(
|
|
200
|
+
<H1 {...resolvePageTitleScale("moderate")}>{TITLE}</H1>,
|
|
201
|
+
["_fos-", "_lh-"],
|
|
202
|
+
"H1",
|
|
203
|
+
);
|
|
200
204
|
const display = renderHeadingClasses(
|
|
201
205
|
<Preset overrides={{ pageTitleScale: "display" }}>
|
|
202
206
|
<H1>{TITLE}</H1>
|
|
@@ -204,9 +208,39 @@ describe("house H1 — pageTitleScale reaches the title text node (LC-17 / D-11)
|
|
|
204
208
|
["_fos-", "_lh-"],
|
|
205
209
|
"H1",
|
|
206
210
|
);
|
|
207
|
-
const
|
|
208
|
-
|
|
209
|
-
|
|
211
|
+
const explicitDisplay = renderHeadingClasses(
|
|
212
|
+
<H1 {...resolvePageTitleScale("display")}>{TITLE}</H1>,
|
|
213
|
+
["_fos-", "_lh-"],
|
|
214
|
+
"H1",
|
|
215
|
+
);
|
|
216
|
+
expect(moderate).toEqual(explicitModerate);
|
|
217
|
+
expect(display).toEqual(explicitDisplay);
|
|
218
|
+
});
|
|
219
|
+
|
|
220
|
+
it("steps down one token below $sm (LC-143)", () => {
|
|
221
|
+
const moderate = renderHeadingClasses(<H1>{TITLE}</H1>, ["_fos-_maxsm", "_lh-_maxsm"], "H1");
|
|
222
|
+
const compact9 = renderHeadingClasses(
|
|
223
|
+
<H1 size="$10" $max-sm={{ fontSize: "$9", lineHeight: "$9", letterSpacing: "$9" }}>
|
|
224
|
+
{TITLE}
|
|
225
|
+
</H1>,
|
|
226
|
+
["_fos-_maxsm", "_lh-_maxsm"],
|
|
227
|
+
"H1",
|
|
228
|
+
);
|
|
229
|
+
expect(moderate).not.toHaveLength(0);
|
|
230
|
+
expect(moderate).toEqual(compact9);
|
|
231
|
+
});
|
|
232
|
+
|
|
233
|
+
it("keeps the preset's weight and the consumer's colour on a phone (LC-143)", () => {
|
|
234
|
+
// A media `size` variant would also write the font table's weight and
|
|
235
|
+
// colour, which outrank base props below $sm.
|
|
236
|
+
const bold = renderHeadingClasses(
|
|
237
|
+
<Preset overrides={{ fontWeight: "bold" }}>
|
|
238
|
+
<H1 color="$red10">{TITLE}</H1>
|
|
239
|
+
</Preset>,
|
|
240
|
+
["_fow-_maxsm", "_col-_maxsm", "_ff-_maxsm"],
|
|
241
|
+
"H1",
|
|
242
|
+
);
|
|
243
|
+
expect(bold).toEqual([]);
|
|
210
244
|
});
|
|
211
245
|
|
|
212
246
|
it("does NOT re-step H2 — the dial is the page title's, not every heading's", () => {
|
|
@@ -228,6 +262,8 @@ describe("house H1 — pageTitleScale reaches the title text node (LC-17 / D-11)
|
|
|
228
262
|
});
|
|
229
263
|
|
|
230
264
|
it("the per-instance eject still wins over the knob (PageHeader contract)", () => {
|
|
265
|
+
// An explicit size takes the whole step, compact entry included: the
|
|
266
|
+
// display knob's `$max-sm` step must not leak through it.
|
|
231
267
|
const ejected = renderHeadingClasses(
|
|
232
268
|
<Preset overrides={{ pageTitleScale: "display" }}>
|
|
233
269
|
<H1 size="$10">{TITLE}</H1>
|
|
@@ -235,8 +271,16 @@ describe("house H1 — pageTitleScale reaches the title text node (LC-17 / D-11)
|
|
|
235
271
|
["_fos-", "_lh-"],
|
|
236
272
|
"H1",
|
|
237
273
|
);
|
|
238
|
-
const
|
|
239
|
-
|
|
274
|
+
const explicit10 = renderHeadingClasses(<H1 size="$10">{TITLE}</H1>, ["_fos-", "_lh-"], "H1");
|
|
275
|
+
const display = renderHeadingClasses(
|
|
276
|
+
<Preset overrides={{ pageTitleScale: "display" }}>
|
|
277
|
+
<H1>{TITLE}</H1>
|
|
278
|
+
</Preset>,
|
|
279
|
+
["_fos-", "_lh-"],
|
|
280
|
+
"H1",
|
|
281
|
+
);
|
|
282
|
+
expect(ejected).toEqual(explicit10);
|
|
283
|
+
expect(ejected).not.toEqual(display);
|
|
240
284
|
});
|
|
241
285
|
});
|
|
242
286
|
|
package/src/Heading.tsx
CHANGED
|
@@ -1,66 +1,3 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
* H1 alone takes pageTitle: moderate $10 (40 px), display $12 (52 px).
|
|
5
|
-
*/
|
|
6
|
-
import { useResolvedKnobs } from "@multiplatform.one/theme";
|
|
7
|
-
import {
|
|
8
|
-
H1 as RawH1,
|
|
9
|
-
H2 as RawH2,
|
|
10
|
-
H3 as RawH3,
|
|
11
|
-
H4 as RawH4,
|
|
12
|
-
H5 as RawH5,
|
|
13
|
-
H6 as RawH6,
|
|
14
|
-
Heading as RawHeading,
|
|
15
|
-
type HeadingProps,
|
|
16
|
-
} from "tamagui";
|
|
17
|
-
|
|
18
|
-
export type { HeadingProps };
|
|
19
|
-
|
|
20
|
-
type Weight = HeadingProps["fontWeight"];
|
|
21
|
-
|
|
22
|
-
function useHeadingVoice(fontWeight: Weight) {
|
|
23
|
-
const { knobProps } = useResolvedKnobs();
|
|
24
|
-
const { fontWeight: knobWeight, ...heading } = knobProps.heading;
|
|
25
|
-
const resolvedWeight = fontWeight ?? (knobWeight as Weight);
|
|
26
|
-
return {
|
|
27
|
-
heading,
|
|
28
|
-
pageTitle: knobProps.pageTitle,
|
|
29
|
-
weight: resolvedWeight === undefined ? {} : { fontWeight: resolvedWeight },
|
|
30
|
-
};
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
export function Heading({ fontWeight, ...props }: HeadingProps) {
|
|
34
|
-
const { heading, weight } = useHeadingVoice(fontWeight);
|
|
35
|
-
return <RawHeading {...heading} {...props} {...weight} />;
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
export function H1({ fontWeight, ...props }: HeadingProps) {
|
|
39
|
-
const { heading, pageTitle, weight } = useHeadingVoice(fontWeight);
|
|
40
|
-
return <RawH1 {...pageTitle} {...heading} {...props} {...weight} />;
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
export function H2({ fontWeight, ...props }: HeadingProps) {
|
|
44
|
-
const { heading, weight } = useHeadingVoice(fontWeight);
|
|
45
|
-
return <RawH2 {...heading} {...props} {...weight} />;
|
|
46
|
-
}
|
|
47
|
-
|
|
48
|
-
export function H3({ fontWeight, ...props }: HeadingProps) {
|
|
49
|
-
const { heading, weight } = useHeadingVoice(fontWeight);
|
|
50
|
-
return <RawH3 {...heading} {...props} {...weight} />;
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
export function H4({ fontWeight, ...props }: HeadingProps) {
|
|
54
|
-
const { heading, weight } = useHeadingVoice(fontWeight);
|
|
55
|
-
return <RawH4 {...heading} {...props} {...weight} />;
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
export function H5({ fontWeight, ...props }: HeadingProps) {
|
|
59
|
-
const { heading, weight } = useHeadingVoice(fontWeight);
|
|
60
|
-
return <RawH5 {...heading} {...props} {...weight} />;
|
|
61
|
-
}
|
|
62
|
-
|
|
63
|
-
export function H6({ fontWeight, ...props }: HeadingProps) {
|
|
64
|
-
const { heading, weight } = useHeadingVoice(fontWeight);
|
|
65
|
-
return <RawH6 {...heading} {...props} {...weight} />;
|
|
66
|
-
}
|
|
1
|
+
// The house heading voices live in @multiplatform.one/theme beside Text (FZ-7739).
|
|
2
|
+
export { H1, H2, H3, H4, H5, H6, Heading } from "@multiplatform.one/theme";
|
|
3
|
+
export type { HeadingProps } from "@multiplatform.one/theme";
|
package/src/Meter/Meter.spec.tsx
CHANGED
|
@@ -222,8 +222,8 @@ describe("Meter a11y and the Progress semantic line", () => {
|
|
|
222
222
|
"light",
|
|
223
223
|
{ fillStyle: "outlined", borderWidth: "none" },
|
|
224
224
|
);
|
|
225
|
-
// LC-86: outlined + none still draws the small hairline, not 0.
|
|
226
|
-
expect(rail(hairline).getAttribute("data-meter-border-width")).toBe("
|
|
225
|
+
// LC-86: outlined + none still draws the small hairline, not 0 (1px on web, LC-148).
|
|
226
|
+
expect(rail(hairline).getAttribute("data-meter-border-width")).toBe("1");
|
|
227
227
|
|
|
228
228
|
cleanup();
|
|
229
229
|
const { container: large } = renderMeter(
|
|
@@ -242,8 +242,8 @@ describe("Meter a11y and the Progress semantic line", () => {
|
|
|
242
242
|
|
|
243
243
|
for (const discrete of [0, 5]) {
|
|
244
244
|
for (const [borderWidth, expected] of [
|
|
245
|
-
["none", "
|
|
246
|
-
["small", "
|
|
245
|
+
["none", "1px"],
|
|
246
|
+
["small", "1px"],
|
|
247
247
|
["large", "2px"],
|
|
248
248
|
] as const) {
|
|
249
249
|
it(`paints ${borderWidth} outline on ${discrete ? "every segment" : "the continuous rail"}`, () => {
|
|
@@ -14,6 +14,7 @@ import { Platform } from "react-native";
|
|
|
14
14
|
import { useDirection } from "../hooks/useDirection";
|
|
15
15
|
import { LinearGradient } from "tamagui/linear-gradient";
|
|
16
16
|
import { ScrollView, type ScrollViewProps } from "../ScrollView";
|
|
17
|
+
import "../linearGradientSetup";
|
|
17
18
|
|
|
18
19
|
export interface OverflowRowProps extends Omit<ScrollViewProps, "horizontal"> {
|
|
19
20
|
fade?: SizeKey | false;
|
|
@@ -2,8 +2,9 @@ import { action } from "@multiplatform.one/storybook";
|
|
|
2
2
|
import { Preset } from "@multiplatform.one/theme";
|
|
3
3
|
import type { Meta, StoryObj } from "@storybook/react-native-web-vite";
|
|
4
4
|
import { useState } from "react";
|
|
5
|
-
import {
|
|
5
|
+
import { YStack } from "tamagui";
|
|
6
6
|
import { Pagination, type PaginationProps } from "./Pagination";
|
|
7
|
+
import { Text } from "./Text";
|
|
7
8
|
|
|
8
9
|
const meta: Meta<typeof Pagination> = {
|
|
9
10
|
title: "Components/Pagination",
|