@oxy.so/bloom 4.5.0 → 4.6.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/docs/adoption-matrix.mdx +12 -12
- package/docs/code.mdx +12 -0
- package/docs/context-menu.mdx +2 -0
- package/docs/dropdown-menu.mdx +21 -0
- package/docs/icons.mdx +2 -2
- package/docs/menubar.mdx +6 -2
- package/docs/popover.mdx +4 -2
- package/docs/segmented-control.mdx +12 -0
- package/docs/select.mdx +19 -0
- package/docs/tabs.mdx +12 -0
- package/lib/commonjs/agent-chat/index.web.js.map +1 -1
- package/lib/commonjs/ai-chat/index.web.js.map +1 -1
- package/lib/commonjs/alert-dialog/index.web.js +10 -1
- package/lib/commonjs/alert-dialog/index.web.js.map +1 -1
- package/lib/commonjs/avatar-group/index.web.js.map +1 -1
- package/lib/commonjs/bottom-sheet/index.web.js.map +1 -1
- package/lib/commonjs/code/index.js +13 -0
- package/lib/commonjs/code/index.js.map +1 -1
- package/lib/commonjs/command/index.web.js +5 -0
- package/lib/commonjs/command/index.web.js.map +1 -1
- package/lib/commonjs/composer-loader/ComposerLoader.web.js +9 -0
- package/lib/commonjs/composer-loader/ComposerLoader.web.js.map +1 -1
- package/lib/commonjs/composer-loader/index.web.js.map +1 -1
- package/lib/commonjs/composer-panel/index.web.js.map +1 -1
- package/lib/commonjs/connection-dots/index.web.js.map +1 -1
- package/lib/commonjs/connection-status/index.web.js.map +1 -1
- package/lib/commonjs/content-panel/index.web.js.map +1 -1
- package/lib/commonjs/context-menu/ContextMenu.web.js +22 -4
- package/lib/commonjs/context-menu/ContextMenu.web.js.map +1 -1
- package/lib/commonjs/context-menu/context.js.map +1 -1
- package/lib/commonjs/context-menu/index.web.js.map +1 -1
- package/lib/commonjs/dialog/Dialog.web.js +14 -0
- package/lib/commonjs/dialog/Dialog.web.js.map +1 -1
- package/lib/commonjs/dialog/index.web.js.map +1 -1
- package/lib/commonjs/dropdown-menu/DropdownMenu.web.js +22 -2
- package/lib/commonjs/dropdown-menu/DropdownMenu.web.js.map +1 -1
- package/lib/commonjs/dropdown-menu/index.web.js.map +1 -1
- package/lib/commonjs/floating/FloatingPanel.js +42 -33
- package/lib/commonjs/floating/FloatingPanel.js.map +1 -1
- package/lib/commonjs/floating/escape-stack.js +90 -0
- package/lib/commonjs/floating/escape-stack.js.map +1 -0
- package/lib/commonjs/floating/menu-keyboard.js +238 -0
- package/lib/commonjs/floating/menu-keyboard.js.map +1 -0
- package/lib/commonjs/floating/menu-sub-flyout.js +28 -16
- package/lib/commonjs/floating/menu-sub-flyout.js.map +1 -1
- package/lib/commonjs/fonts/index.web.js.map +1 -1
- package/lib/commonjs/frosted-icon-button/FrostedIconButton.web.js +10 -0
- package/lib/commonjs/frosted-icon-button/FrostedIconButton.web.js.map +1 -1
- package/lib/commonjs/frosted-icon-button/index.web.js.map +1 -1
- package/lib/commonjs/hooks/roving-focus.js +192 -0
- package/lib/commonjs/hooks/roving-focus.js.map +1 -0
- package/lib/commonjs/hover-card/index.web.js.map +1 -1
- package/lib/commonjs/icons/remix/RiBookReadLine.js +12 -0
- package/lib/commonjs/icons/remix/RiBookReadLine.js.map +1 -0
- package/lib/commonjs/icons/remix/RiBugLine.js +12 -0
- package/lib/commonjs/icons/remix/RiBugLine.js.map +1 -0
- package/lib/commonjs/icons/remix/RiChat1Line.js +12 -0
- package/lib/commonjs/icons/remix/RiChat1Line.js.map +1 -0
- package/lib/commonjs/icons/remix/RiCloudLine.js +12 -0
- package/lib/commonjs/icons/remix/RiCloudLine.js.map +1 -0
- package/lib/commonjs/icons/remix/RiCodeLine.js +12 -0
- package/lib/commonjs/icons/remix/RiCodeLine.js.map +1 -0
- package/lib/commonjs/icons/remix/RiCpuLine.js +12 -0
- package/lib/commonjs/icons/remix/RiCpuLine.js.map +1 -0
- package/lib/commonjs/icons/remix/RiFloodLine.js +12 -0
- package/lib/commonjs/icons/remix/RiFloodLine.js.map +1 -0
- package/lib/commonjs/icons/remix/RiLockUnlockLine.js +12 -0
- package/lib/commonjs/icons/remix/RiLockUnlockLine.js.map +1 -0
- package/lib/commonjs/icons/remix/RiMoneyDollarCircleLine.js +12 -0
- package/lib/commonjs/icons/remix/RiMoneyDollarCircleLine.js.map +1 -0
- package/lib/commonjs/icons/remix/RiPlayCircleLine.js +12 -0
- package/lib/commonjs/icons/remix/RiPlayCircleLine.js.map +1 -0
- package/lib/commonjs/icons/remix/RiRocket2Line.js +12 -0
- package/lib/commonjs/icons/remix/RiRocket2Line.js.map +1 -0
- package/lib/commonjs/icons/remix/RiServerLine.js +12 -0
- package/lib/commonjs/icons/remix/RiServerLine.js.map +1 -0
- package/lib/commonjs/icons/remix/RiShareBoxLine.js +12 -0
- package/lib/commonjs/icons/remix/RiShareBoxLine.js.map +1 -0
- package/lib/commonjs/icons/remix/RiTv2Line.js +12 -0
- package/lib/commonjs/icons/remix/RiTv2Line.js.map +1 -0
- package/lib/commonjs/icons/remix/index.js +98 -0
- package/lib/commonjs/icons/remix/index.js.map +1 -1
- package/lib/commonjs/list/index.web.js.map +1 -1
- package/lib/commonjs/loading/Loading.js +21 -157
- package/lib/commonjs/loading/Loading.js.map +1 -1
- package/lib/commonjs/loading/Loading.web.js +23 -157
- package/lib/commonjs/loading/Loading.web.js.map +1 -1
- package/lib/commonjs/loading/LoadingBase.js +202 -0
- package/lib/commonjs/loading/LoadingBase.js.map +1 -0
- package/lib/commonjs/loading/index.web.js.map +1 -1
- package/lib/commonjs/media-flight/index.web.js.map +1 -1
- package/lib/commonjs/menubar/Menubar.js +31 -123
- package/lib/commonjs/menubar/Menubar.js.map +1 -1
- package/lib/commonjs/menubar/Menubar.web.js +33 -114
- package/lib/commonjs/menubar/Menubar.web.js.map +1 -1
- package/lib/commonjs/menubar/MenubarBase.js +154 -0
- package/lib/commonjs/menubar/MenubarBase.js.map +1 -0
- package/lib/commonjs/menubar/index.web.js.map +1 -1
- package/lib/commonjs/popover/index.web.js.map +1 -1
- package/lib/commonjs/popover/parts.js +69 -11
- package/lib/commonjs/popover/parts.js.map +1 -1
- package/lib/commonjs/popover/surface.js +39 -13
- package/lib/commonjs/popover/surface.js.map +1 -1
- package/lib/commonjs/portal/index.web.js.map +1 -1
- package/lib/commonjs/progressive-blur/index.web.js.map +1 -1
- package/lib/commonjs/scroll/index.web.js.map +1 -1
- package/lib/commonjs/segmented-control/SegmentedControl.js +36 -1
- package/lib/commonjs/segmented-control/SegmentedControl.js.map +1 -1
- package/lib/commonjs/select/Select.js +6 -81
- package/lib/commonjs/select/Select.js.map +1 -1
- package/lib/commonjs/select/Select.web.js +147 -85
- package/lib/commonjs/select/Select.web.js.map +1 -1
- package/lib/commonjs/select/index.js +4 -4
- package/lib/commonjs/select/index.js.map +1 -1
- package/lib/commonjs/select/index.web.js +4 -4
- package/lib/commonjs/select/index.web.js.map +1 -1
- package/lib/commonjs/select/shared.js +110 -5
- package/lib/commonjs/select/shared.js.map +1 -1
- package/lib/commonjs/sidebar/SidebarTeamMenu.js +1 -1
- package/lib/commonjs/sidebar/SidebarTeamMenu.js.map +1 -1
- package/lib/commonjs/sidebar/SidebarUserMenu.js +1 -1
- package/lib/commonjs/sidebar/SidebarUserMenu.js.map +1 -1
- package/lib/commonjs/sidebar/parts.js +9 -9
- package/lib/commonjs/sidebar/parts.js.map +1 -1
- package/lib/commonjs/surfaces/SurfaceHost.js +6 -0
- package/lib/commonjs/surfaces/SurfaceHost.js.map +1 -1
- package/lib/commonjs/surfaces/index.web.js +14 -4
- package/lib/commonjs/surfaces/index.web.js.map +1 -1
- package/lib/commonjs/tab-bar/index.web.js +13 -10
- package/lib/commonjs/tab-bar/index.web.js.map +1 -1
- package/lib/commonjs/tabs/Tabs.js +49 -2
- package/lib/commonjs/tabs/Tabs.js.map +1 -1
- package/lib/commonjs/theme/color-scope/index.web.js.map +1 -1
- package/lib/commonjs/theme/persistence.js +12 -1
- package/lib/commonjs/theme/persistence.js.map +1 -1
- package/lib/commonjs/theme/seed-scope/index.web.js.map +1 -1
- package/lib/commonjs/tooltip/index.web.js.map +1 -1
- package/lib/module/agent-chat/index.web.js +5 -3
- package/lib/module/agent-chat/index.web.js.map +1 -1
- package/lib/module/ai-chat/index.web.js +5 -2
- package/lib/module/ai-chat/index.web.js.map +1 -1
- package/lib/module/alert-dialog/index.web.js +10 -1
- package/lib/module/alert-dialog/index.web.js.map +1 -1
- package/lib/module/avatar-group/index.web.js +5 -0
- package/lib/module/avatar-group/index.web.js.map +1 -1
- package/lib/module/bottom-sheet/index.web.js +5 -0
- package/lib/module/bottom-sheet/index.web.js.map +1 -1
- package/lib/module/code/index.js +1 -0
- package/lib/module/code/index.js.map +1 -1
- package/lib/module/command/index.web.js +5 -0
- package/lib/module/command/index.web.js.map +1 -1
- package/lib/module/composer-loader/ComposerLoader.web.js +8 -0
- package/lib/module/composer-loader/ComposerLoader.web.js.map +1 -1
- package/lib/module/composer-loader/index.web.js +5 -2
- package/lib/module/composer-loader/index.web.js.map +1 -1
- package/lib/module/composer-panel/index.web.js +5 -3
- package/lib/module/composer-panel/index.web.js.map +1 -1
- package/lib/module/connection-dots/index.web.js +5 -0
- package/lib/module/connection-dots/index.web.js.map +1 -1
- package/lib/module/connection-status/index.web.js +5 -0
- package/lib/module/connection-status/index.web.js.map +1 -1
- package/lib/module/content-panel/index.web.js +5 -0
- package/lib/module/content-panel/index.web.js.map +1 -1
- package/lib/module/context-menu/ContextMenu.web.js +22 -4
- package/lib/module/context-menu/ContextMenu.web.js.map +1 -1
- package/lib/module/context-menu/context.js.map +1 -1
- package/lib/module/context-menu/index.web.js +5 -0
- package/lib/module/context-menu/index.web.js.map +1 -1
- package/lib/module/dialog/Dialog.web.js +13 -0
- package/lib/module/dialog/Dialog.web.js.map +1 -1
- package/lib/module/dialog/index.web.js +7 -11
- package/lib/module/dialog/index.web.js.map +1 -1
- package/lib/module/dropdown-menu/DropdownMenu.web.js +23 -3
- package/lib/module/dropdown-menu/DropdownMenu.web.js.map +1 -1
- package/lib/module/dropdown-menu/index.web.js +5 -0
- package/lib/module/dropdown-menu/index.web.js.map +1 -1
- package/lib/module/floating/FloatingPanel.js +42 -33
- package/lib/module/floating/FloatingPanel.js.map +1 -1
- package/lib/module/floating/escape-stack.js +85 -0
- package/lib/module/floating/escape-stack.js.map +1 -0
- package/lib/module/floating/menu-keyboard.js +227 -0
- package/lib/module/floating/menu-keyboard.js.map +1 -0
- package/lib/module/floating/menu-sub-flyout.js +28 -16
- package/lib/module/floating/menu-sub-flyout.js.map +1 -1
- package/lib/module/fonts/index.web.js +5 -20
- package/lib/module/fonts/index.web.js.map +1 -1
- package/lib/module/frosted-icon-button/FrostedIconButton.web.js +9 -0
- package/lib/module/frosted-icon-button/FrostedIconButton.web.js.map +1 -1
- package/lib/module/frosted-icon-button/index.web.js +5 -7
- package/lib/module/frosted-icon-button/index.web.js.map +1 -1
- package/lib/module/hooks/roving-focus.js +181 -0
- package/lib/module/hooks/roving-focus.js.map +1 -0
- package/lib/module/hover-card/index.web.js +5 -0
- package/lib/module/hover-card/index.web.js.map +1 -1
- package/lib/module/icons/remix/RiBookReadLine.js +9 -0
- package/lib/module/icons/remix/RiBookReadLine.js.map +1 -0
- package/lib/module/icons/remix/RiBugLine.js +9 -0
- package/lib/module/icons/remix/RiBugLine.js.map +1 -0
- package/lib/module/icons/remix/RiChat1Line.js +9 -0
- package/lib/module/icons/remix/RiChat1Line.js.map +1 -0
- package/lib/module/icons/remix/RiCloudLine.js +9 -0
- package/lib/module/icons/remix/RiCloudLine.js.map +1 -0
- package/lib/module/icons/remix/RiCodeLine.js +9 -0
- package/lib/module/icons/remix/RiCodeLine.js.map +1 -0
- package/lib/module/icons/remix/RiCpuLine.js +9 -0
- package/lib/module/icons/remix/RiCpuLine.js.map +1 -0
- package/lib/module/icons/remix/RiFloodLine.js +9 -0
- package/lib/module/icons/remix/RiFloodLine.js.map +1 -0
- package/lib/module/icons/remix/RiLockUnlockLine.js +9 -0
- package/lib/module/icons/remix/RiLockUnlockLine.js.map +1 -0
- package/lib/module/icons/remix/RiMoneyDollarCircleLine.js +9 -0
- package/lib/module/icons/remix/RiMoneyDollarCircleLine.js.map +1 -0
- package/lib/module/icons/remix/RiPlayCircleLine.js +9 -0
- package/lib/module/icons/remix/RiPlayCircleLine.js.map +1 -0
- package/lib/module/icons/remix/RiRocket2Line.js +9 -0
- package/lib/module/icons/remix/RiRocket2Line.js.map +1 -0
- package/lib/module/icons/remix/RiServerLine.js +9 -0
- package/lib/module/icons/remix/RiServerLine.js.map +1 -0
- package/lib/module/icons/remix/RiShareBoxLine.js +9 -0
- package/lib/module/icons/remix/RiShareBoxLine.js.map +1 -0
- package/lib/module/icons/remix/RiTv2Line.js +9 -0
- package/lib/module/icons/remix/RiTv2Line.js.map +1 -0
- package/lib/module/icons/remix/index.js +14 -0
- package/lib/module/icons/remix/index.js.map +1 -1
- package/lib/module/list/index.web.js +5 -0
- package/lib/module/list/index.web.js.map +1 -1
- package/lib/module/loading/Loading.js +17 -155
- package/lib/module/loading/Loading.js.map +1 -1
- package/lib/module/loading/Loading.web.js +19 -155
- package/lib/module/loading/Loading.web.js.map +1 -1
- package/lib/module/loading/LoadingBase.js +194 -0
- package/lib/module/loading/LoadingBase.js.map +1 -0
- package/lib/module/loading/index.web.js +5 -13
- package/lib/module/loading/index.web.js.map +1 -1
- package/lib/module/media-flight/index.web.js +5 -9
- package/lib/module/media-flight/index.web.js.map +1 -1
- package/lib/module/menubar/Menubar.js +15 -122
- package/lib/module/menubar/Menubar.js.map +1 -1
- package/lib/module/menubar/Menubar.web.js +18 -114
- package/lib/module/menubar/Menubar.web.js.map +1 -1
- package/lib/module/menubar/MenubarBase.js +146 -0
- package/lib/module/menubar/MenubarBase.js.map +1 -0
- package/lib/module/menubar/index.web.js +5 -0
- package/lib/module/menubar/index.web.js.map +1 -1
- package/lib/module/motion/index.web.js +5 -5
- package/lib/module/motion/index.web.js.map +1 -1
- package/lib/module/popover/index.web.js +5 -0
- package/lib/module/popover/index.web.js.map +1 -1
- package/lib/module/popover/parts.js +70 -12
- package/lib/module/popover/parts.js.map +1 -1
- package/lib/module/popover/surface.js +39 -13
- package/lib/module/popover/surface.js.map +1 -1
- package/lib/module/portal/index.web.js +6 -1
- package/lib/module/portal/index.web.js.map +1 -1
- package/lib/module/progressive-blur/index.web.js +5 -0
- package/lib/module/progressive-blur/index.web.js.map +1 -1
- package/lib/module/scroll/index.web.js +5 -0
- package/lib/module/scroll/index.web.js.map +1 -1
- package/lib/module/segmented-control/SegmentedControl.js +36 -1
- package/lib/module/segmented-control/SegmentedControl.js.map +1 -1
- package/lib/module/select/Select.js +5 -77
- package/lib/module/select/Select.js.map +1 -1
- package/lib/module/select/Select.web.js +147 -82
- package/lib/module/select/Select.web.js.map +1 -1
- package/lib/module/select/index.js +2 -2
- package/lib/module/select/index.js.map +1 -1
- package/lib/module/select/index.web.js +7 -2
- package/lib/module/select/index.web.js.map +1 -1
- package/lib/module/select/shared.js +106 -6
- package/lib/module/select/shared.js.map +1 -1
- package/lib/module/sidebar/SidebarTeamMenu.js +2 -2
- package/lib/module/sidebar/SidebarTeamMenu.js.map +1 -1
- package/lib/module/sidebar/SidebarUserMenu.js +2 -2
- package/lib/module/sidebar/SidebarUserMenu.js.map +1 -1
- package/lib/module/sidebar/parts.js +8 -8
- package/lib/module/sidebar/parts.js.map +1 -1
- package/lib/module/surfaces/SurfaceHost.js +6 -0
- package/lib/module/surfaces/SurfaceHost.js.map +1 -1
- package/lib/module/surfaces/index.web.js +14 -4
- package/lib/module/surfaces/index.web.js.map +1 -1
- package/lib/module/tab-bar/index.web.js +13 -10
- package/lib/module/tab-bar/index.web.js.map +1 -1
- package/lib/module/tabs/Tabs.js +49 -2
- package/lib/module/tabs/Tabs.js.map +1 -1
- package/lib/module/theme/color-scope/index.web.js +5 -0
- package/lib/module/theme/color-scope/index.web.js.map +1 -1
- package/lib/module/theme/persistence.js +12 -1
- package/lib/module/theme/persistence.js.map +1 -1
- package/lib/module/theme/seed-scope/index.web.js +5 -0
- package/lib/module/theme/seed-scope/index.web.js.map +1 -1
- package/lib/module/tooltip/index.web.js +5 -0
- package/lib/module/tooltip/index.web.js.map +1 -1
- package/lib/typescript/commonjs/agent-chat/index.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/ai-chat/index.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/alert-dialog/index.web.d.ts +5 -1
- package/lib/typescript/commonjs/alert-dialog/index.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/avatar-group/index.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/bottom-sheet/index.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/code/index.d.ts +2 -0
- package/lib/typescript/commonjs/code/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/command/index.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/composer-loader/ComposerLoader.web.d.ts +8 -0
- package/lib/typescript/commonjs/composer-loader/ComposerLoader.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/composer-loader/index.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/composer-panel/index.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/connection-dots/index.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/connection-status/index.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/content-panel/index.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/context-menu/ContextMenu.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/context-menu/context.d.ts +3 -0
- package/lib/typescript/commonjs/context-menu/context.d.ts.map +1 -1
- package/lib/typescript/commonjs/context-menu/index.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/dialog/Dialog.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/dialog/index.web.d.ts +2 -1
- package/lib/typescript/commonjs/dialog/index.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/dropdown-menu/DropdownMenu.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/dropdown-menu/index.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/floating/FloatingPanel.d.ts +1 -1
- package/lib/typescript/commonjs/floating/FloatingPanel.d.ts.map +1 -1
- package/lib/typescript/commonjs/floating/escape-stack.d.ts +55 -0
- package/lib/typescript/commonjs/floating/escape-stack.d.ts.map +1 -0
- package/lib/typescript/commonjs/floating/menu-keyboard.d.ts +57 -0
- package/lib/typescript/commonjs/floating/menu-keyboard.d.ts.map +1 -0
- package/lib/typescript/commonjs/floating/menu-sub-flyout.d.ts.map +1 -1
- package/lib/typescript/commonjs/floating/types.d.ts +11 -0
- package/lib/typescript/commonjs/floating/types.d.ts.map +1 -1
- package/lib/typescript/commonjs/fonts/index.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/frosted-icon-button/FrostedIconButton.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/frosted-icon-button/index.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/hooks/roving-focus.d.ts +66 -0
- package/lib/typescript/commonjs/hooks/roving-focus.d.ts.map +1 -0
- package/lib/typescript/commonjs/hover-card/index.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/icons/remix/RiBookReadLine.d.ts +8 -0
- package/lib/typescript/commonjs/icons/remix/RiBookReadLine.d.ts.map +1 -0
- package/lib/typescript/commonjs/icons/remix/RiBugLine.d.ts +8 -0
- package/lib/typescript/commonjs/icons/remix/RiBugLine.d.ts.map +1 -0
- package/lib/typescript/commonjs/icons/remix/RiChat1Line.d.ts +8 -0
- package/lib/typescript/commonjs/icons/remix/RiChat1Line.d.ts.map +1 -0
- package/lib/typescript/commonjs/icons/remix/RiCloudLine.d.ts +8 -0
- package/lib/typescript/commonjs/icons/remix/RiCloudLine.d.ts.map +1 -0
- package/lib/typescript/commonjs/icons/remix/RiCodeLine.d.ts +8 -0
- package/lib/typescript/commonjs/icons/remix/RiCodeLine.d.ts.map +1 -0
- package/lib/typescript/commonjs/icons/remix/RiCpuLine.d.ts +8 -0
- package/lib/typescript/commonjs/icons/remix/RiCpuLine.d.ts.map +1 -0
- package/lib/typescript/commonjs/icons/remix/RiFloodLine.d.ts +8 -0
- package/lib/typescript/commonjs/icons/remix/RiFloodLine.d.ts.map +1 -0
- package/lib/typescript/commonjs/icons/remix/RiLockUnlockLine.d.ts +8 -0
- package/lib/typescript/commonjs/icons/remix/RiLockUnlockLine.d.ts.map +1 -0
- package/lib/typescript/commonjs/icons/remix/RiMoneyDollarCircleLine.d.ts +8 -0
- package/lib/typescript/commonjs/icons/remix/RiMoneyDollarCircleLine.d.ts.map +1 -0
- package/lib/typescript/commonjs/icons/remix/RiPlayCircleLine.d.ts +8 -0
- package/lib/typescript/commonjs/icons/remix/RiPlayCircleLine.d.ts.map +1 -0
- package/lib/typescript/commonjs/icons/remix/RiRocket2Line.d.ts +8 -0
- package/lib/typescript/commonjs/icons/remix/RiRocket2Line.d.ts.map +1 -0
- package/lib/typescript/commonjs/icons/remix/RiServerLine.d.ts +8 -0
- package/lib/typescript/commonjs/icons/remix/RiServerLine.d.ts.map +1 -0
- package/lib/typescript/commonjs/icons/remix/RiShareBoxLine.d.ts +8 -0
- package/lib/typescript/commonjs/icons/remix/RiShareBoxLine.d.ts.map +1 -0
- package/lib/typescript/commonjs/icons/remix/RiTv2Line.d.ts +8 -0
- package/lib/typescript/commonjs/icons/remix/RiTv2Line.d.ts.map +1 -0
- package/lib/typescript/commonjs/icons/remix/index.d.ts +14 -0
- package/lib/typescript/commonjs/icons/remix/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/list/index.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/loading/Loading.d.ts +8 -2
- package/lib/typescript/commonjs/loading/Loading.d.ts.map +1 -1
- package/lib/typescript/commonjs/loading/Loading.web.d.ts +10 -2
- package/lib/typescript/commonjs/loading/Loading.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/loading/LoadingBase.d.ts +64 -0
- package/lib/typescript/commonjs/loading/LoadingBase.d.ts.map +1 -0
- package/lib/typescript/commonjs/loading/index.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/media-flight/index.web.d.ts +0 -9
- package/lib/typescript/commonjs/media-flight/index.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/menubar/Menubar.d.ts +14 -9
- package/lib/typescript/commonjs/menubar/Menubar.d.ts.map +1 -1
- package/lib/typescript/commonjs/menubar/Menubar.web.d.ts +8 -6
- package/lib/typescript/commonjs/menubar/Menubar.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/menubar/MenubarBase.d.ts +5 -0
- package/lib/typescript/commonjs/menubar/MenubarBase.d.ts.map +1 -0
- package/lib/typescript/commonjs/menubar/index.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/motion/index.web.d.ts +0 -5
- package/lib/typescript/commonjs/motion/index.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/popover/index.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/popover/parts.d.ts.map +1 -1
- package/lib/typescript/commonjs/popover/surface.d.ts +15 -5
- package/lib/typescript/commonjs/popover/surface.d.ts.map +1 -1
- package/lib/typescript/commonjs/portal/index.web.d.ts +1 -1
- package/lib/typescript/commonjs/portal/index.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/progressive-blur/index.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/scroll/index.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/segmented-control/SegmentedControl.d.ts.map +1 -1
- package/lib/typescript/commonjs/select/Select.d.ts +2 -4
- package/lib/typescript/commonjs/select/Select.d.ts.map +1 -1
- package/lib/typescript/commonjs/select/Select.web.d.ts +2 -4
- package/lib/typescript/commonjs/select/Select.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/select/index.d.ts +2 -2
- package/lib/typescript/commonjs/select/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/select/index.web.d.ts +2 -2
- package/lib/typescript/commonjs/select/index.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/select/shared.d.ts +52 -5
- package/lib/typescript/commonjs/select/shared.d.ts.map +1 -1
- package/lib/typescript/commonjs/select/types.d.ts +6 -0
- package/lib/typescript/commonjs/select/types.d.ts.map +1 -1
- package/lib/typescript/commonjs/sidebar/parts.d.ts +8 -2
- package/lib/typescript/commonjs/sidebar/parts.d.ts.map +1 -1
- package/lib/typescript/commonjs/surfaces/SurfaceHost.d.ts.map +1 -1
- package/lib/typescript/commonjs/surfaces/index.web.d.ts +9 -4
- package/lib/typescript/commonjs/surfaces/index.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/tab-bar/index.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/tabs/Tabs.d.ts.map +1 -1
- package/lib/typescript/commonjs/tabs/types.d.ts +6 -0
- package/lib/typescript/commonjs/tabs/types.d.ts.map +1 -1
- package/lib/typescript/commonjs/theme/color-scope/index.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/theme/persistence.d.ts.map +1 -1
- package/lib/typescript/commonjs/theme/seed-scope/index.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/tooltip/index.web.d.ts.map +1 -1
- package/lib/typescript/module/agent-chat/index.web.d.ts.map +1 -1
- package/lib/typescript/module/ai-chat/index.web.d.ts.map +1 -1
- package/lib/typescript/module/alert-dialog/index.web.d.ts +5 -1
- package/lib/typescript/module/alert-dialog/index.web.d.ts.map +1 -1
- package/lib/typescript/module/avatar-group/index.web.d.ts.map +1 -1
- package/lib/typescript/module/bottom-sheet/index.web.d.ts.map +1 -1
- package/lib/typescript/module/code/index.d.ts +2 -0
- package/lib/typescript/module/code/index.d.ts.map +1 -1
- package/lib/typescript/module/command/index.web.d.ts.map +1 -1
- package/lib/typescript/module/composer-loader/ComposerLoader.web.d.ts +8 -0
- package/lib/typescript/module/composer-loader/ComposerLoader.web.d.ts.map +1 -1
- package/lib/typescript/module/composer-loader/index.web.d.ts.map +1 -1
- package/lib/typescript/module/composer-panel/index.web.d.ts.map +1 -1
- package/lib/typescript/module/connection-dots/index.web.d.ts.map +1 -1
- package/lib/typescript/module/connection-status/index.web.d.ts.map +1 -1
- package/lib/typescript/module/content-panel/index.web.d.ts.map +1 -1
- package/lib/typescript/module/context-menu/ContextMenu.web.d.ts.map +1 -1
- package/lib/typescript/module/context-menu/context.d.ts +3 -0
- package/lib/typescript/module/context-menu/context.d.ts.map +1 -1
- package/lib/typescript/module/context-menu/index.web.d.ts.map +1 -1
- package/lib/typescript/module/dialog/Dialog.web.d.ts.map +1 -1
- package/lib/typescript/module/dialog/index.web.d.ts +2 -1
- package/lib/typescript/module/dialog/index.web.d.ts.map +1 -1
- package/lib/typescript/module/dropdown-menu/DropdownMenu.web.d.ts.map +1 -1
- package/lib/typescript/module/dropdown-menu/index.web.d.ts.map +1 -1
- package/lib/typescript/module/floating/FloatingPanel.d.ts +1 -1
- package/lib/typescript/module/floating/FloatingPanel.d.ts.map +1 -1
- package/lib/typescript/module/floating/escape-stack.d.ts +55 -0
- package/lib/typescript/module/floating/escape-stack.d.ts.map +1 -0
- package/lib/typescript/module/floating/menu-keyboard.d.ts +57 -0
- package/lib/typescript/module/floating/menu-keyboard.d.ts.map +1 -0
- package/lib/typescript/module/floating/menu-sub-flyout.d.ts.map +1 -1
- package/lib/typescript/module/floating/types.d.ts +11 -0
- package/lib/typescript/module/floating/types.d.ts.map +1 -1
- package/lib/typescript/module/fonts/index.web.d.ts.map +1 -1
- package/lib/typescript/module/frosted-icon-button/FrostedIconButton.web.d.ts.map +1 -1
- package/lib/typescript/module/frosted-icon-button/index.web.d.ts.map +1 -1
- package/lib/typescript/module/hooks/roving-focus.d.ts +66 -0
- package/lib/typescript/module/hooks/roving-focus.d.ts.map +1 -0
- package/lib/typescript/module/hover-card/index.web.d.ts.map +1 -1
- package/lib/typescript/module/icons/remix/RiBookReadLine.d.ts +8 -0
- package/lib/typescript/module/icons/remix/RiBookReadLine.d.ts.map +1 -0
- package/lib/typescript/module/icons/remix/RiBugLine.d.ts +8 -0
- package/lib/typescript/module/icons/remix/RiBugLine.d.ts.map +1 -0
- package/lib/typescript/module/icons/remix/RiChat1Line.d.ts +8 -0
- package/lib/typescript/module/icons/remix/RiChat1Line.d.ts.map +1 -0
- package/lib/typescript/module/icons/remix/RiCloudLine.d.ts +8 -0
- package/lib/typescript/module/icons/remix/RiCloudLine.d.ts.map +1 -0
- package/lib/typescript/module/icons/remix/RiCodeLine.d.ts +8 -0
- package/lib/typescript/module/icons/remix/RiCodeLine.d.ts.map +1 -0
- package/lib/typescript/module/icons/remix/RiCpuLine.d.ts +8 -0
- package/lib/typescript/module/icons/remix/RiCpuLine.d.ts.map +1 -0
- package/lib/typescript/module/icons/remix/RiFloodLine.d.ts +8 -0
- package/lib/typescript/module/icons/remix/RiFloodLine.d.ts.map +1 -0
- package/lib/typescript/module/icons/remix/RiLockUnlockLine.d.ts +8 -0
- package/lib/typescript/module/icons/remix/RiLockUnlockLine.d.ts.map +1 -0
- package/lib/typescript/module/icons/remix/RiMoneyDollarCircleLine.d.ts +8 -0
- package/lib/typescript/module/icons/remix/RiMoneyDollarCircleLine.d.ts.map +1 -0
- package/lib/typescript/module/icons/remix/RiPlayCircleLine.d.ts +8 -0
- package/lib/typescript/module/icons/remix/RiPlayCircleLine.d.ts.map +1 -0
- package/lib/typescript/module/icons/remix/RiRocket2Line.d.ts +8 -0
- package/lib/typescript/module/icons/remix/RiRocket2Line.d.ts.map +1 -0
- package/lib/typescript/module/icons/remix/RiServerLine.d.ts +8 -0
- package/lib/typescript/module/icons/remix/RiServerLine.d.ts.map +1 -0
- package/lib/typescript/module/icons/remix/RiShareBoxLine.d.ts +8 -0
- package/lib/typescript/module/icons/remix/RiShareBoxLine.d.ts.map +1 -0
- package/lib/typescript/module/icons/remix/RiTv2Line.d.ts +8 -0
- package/lib/typescript/module/icons/remix/RiTv2Line.d.ts.map +1 -0
- package/lib/typescript/module/icons/remix/index.d.ts +14 -0
- package/lib/typescript/module/icons/remix/index.d.ts.map +1 -1
- package/lib/typescript/module/list/index.web.d.ts.map +1 -1
- package/lib/typescript/module/loading/Loading.d.ts +8 -2
- package/lib/typescript/module/loading/Loading.d.ts.map +1 -1
- package/lib/typescript/module/loading/Loading.web.d.ts +10 -2
- package/lib/typescript/module/loading/Loading.web.d.ts.map +1 -1
- package/lib/typescript/module/loading/LoadingBase.d.ts +64 -0
- package/lib/typescript/module/loading/LoadingBase.d.ts.map +1 -0
- package/lib/typescript/module/loading/index.web.d.ts.map +1 -1
- package/lib/typescript/module/media-flight/index.web.d.ts +0 -9
- package/lib/typescript/module/media-flight/index.web.d.ts.map +1 -1
- package/lib/typescript/module/menubar/Menubar.d.ts +14 -9
- package/lib/typescript/module/menubar/Menubar.d.ts.map +1 -1
- package/lib/typescript/module/menubar/Menubar.web.d.ts +8 -6
- package/lib/typescript/module/menubar/Menubar.web.d.ts.map +1 -1
- package/lib/typescript/module/menubar/MenubarBase.d.ts +5 -0
- package/lib/typescript/module/menubar/MenubarBase.d.ts.map +1 -0
- package/lib/typescript/module/menubar/index.web.d.ts.map +1 -1
- package/lib/typescript/module/motion/index.web.d.ts +0 -5
- package/lib/typescript/module/motion/index.web.d.ts.map +1 -1
- package/lib/typescript/module/popover/index.web.d.ts.map +1 -1
- package/lib/typescript/module/popover/parts.d.ts.map +1 -1
- package/lib/typescript/module/popover/surface.d.ts +15 -5
- package/lib/typescript/module/popover/surface.d.ts.map +1 -1
- package/lib/typescript/module/portal/index.web.d.ts +1 -1
- package/lib/typescript/module/portal/index.web.d.ts.map +1 -1
- package/lib/typescript/module/progressive-blur/index.web.d.ts.map +1 -1
- package/lib/typescript/module/scroll/index.web.d.ts.map +1 -1
- package/lib/typescript/module/segmented-control/SegmentedControl.d.ts.map +1 -1
- package/lib/typescript/module/select/Select.d.ts +2 -4
- package/lib/typescript/module/select/Select.d.ts.map +1 -1
- package/lib/typescript/module/select/Select.web.d.ts +2 -4
- package/lib/typescript/module/select/Select.web.d.ts.map +1 -1
- package/lib/typescript/module/select/index.d.ts +2 -2
- package/lib/typescript/module/select/index.d.ts.map +1 -1
- package/lib/typescript/module/select/index.web.d.ts +2 -2
- package/lib/typescript/module/select/index.web.d.ts.map +1 -1
- package/lib/typescript/module/select/shared.d.ts +52 -5
- package/lib/typescript/module/select/shared.d.ts.map +1 -1
- package/lib/typescript/module/select/types.d.ts +6 -0
- package/lib/typescript/module/select/types.d.ts.map +1 -1
- package/lib/typescript/module/sidebar/parts.d.ts +8 -2
- package/lib/typescript/module/sidebar/parts.d.ts.map +1 -1
- package/lib/typescript/module/surfaces/SurfaceHost.d.ts.map +1 -1
- package/lib/typescript/module/surfaces/index.web.d.ts +9 -4
- package/lib/typescript/module/surfaces/index.web.d.ts.map +1 -1
- package/lib/typescript/module/tab-bar/index.web.d.ts.map +1 -1
- package/lib/typescript/module/tabs/Tabs.d.ts.map +1 -1
- package/lib/typescript/module/tabs/types.d.ts +6 -0
- package/lib/typescript/module/tabs/types.d.ts.map +1 -1
- package/lib/typescript/module/theme/color-scope/index.web.d.ts.map +1 -1
- package/lib/typescript/module/theme/persistence.d.ts.map +1 -1
- package/lib/typescript/module/theme/seed-scope/index.web.d.ts.map +1 -1
- package/lib/typescript/module/tooltip/index.web.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/agent-chat/index.web.ts +5 -3
- package/src/ai-chat/index.web.ts +5 -2
- package/src/alert-dialog/index.web.ts +10 -1
- package/src/avatar-group/index.web.ts +5 -0
- package/src/bottom-sheet/index.web.ts +5 -0
- package/src/code/index.ts +2 -0
- package/src/command/index.web.ts +5 -0
- package/src/composer-loader/ComposerLoader.web.tsx +8 -0
- package/src/composer-loader/index.web.ts +5 -2
- package/src/composer-panel/index.web.ts +5 -3
- package/src/connection-dots/index.web.ts +5 -0
- package/src/connection-status/index.web.ts +5 -0
- package/src/content-panel/index.web.ts +5 -0
- package/src/context-menu/ContextMenu.web.tsx +26 -3
- package/src/context-menu/context.ts +3 -0
- package/src/context-menu/index.web.ts +5 -0
- package/src/dialog/Dialog.web.tsx +13 -0
- package/src/dialog/index.web.ts +7 -11
- package/src/dropdown-menu/DropdownMenu.web.tsx +25 -2
- package/src/dropdown-menu/index.web.ts +5 -0
- package/src/floating/FloatingPanel.tsx +37 -38
- package/src/floating/escape-stack.ts +92 -0
- package/src/floating/menu-keyboard.ts +242 -0
- package/src/floating/menu-sub-flyout.tsx +22 -17
- package/src/floating/types.ts +11 -0
- package/src/fonts/index.web.ts +5 -20
- package/src/frosted-icon-button/FrostedIconButton.web.tsx +9 -0
- package/src/frosted-icon-button/index.web.ts +5 -7
- package/src/hooks/roving-focus.ts +204 -0
- package/src/hover-card/index.web.ts +5 -0
- package/src/icons/remix/RiBookReadLine.tsx +6 -0
- package/src/icons/remix/RiBugLine.tsx +6 -0
- package/src/icons/remix/RiChat1Line.tsx +6 -0
- package/src/icons/remix/RiCloudLine.tsx +6 -0
- package/src/icons/remix/RiCodeLine.tsx +6 -0
- package/src/icons/remix/RiCpuLine.tsx +6 -0
- package/src/icons/remix/RiFloodLine.tsx +6 -0
- package/src/icons/remix/RiLockUnlockLine.tsx +6 -0
- package/src/icons/remix/RiMoneyDollarCircleLine.tsx +6 -0
- package/src/icons/remix/RiPlayCircleLine.tsx +6 -0
- package/src/icons/remix/RiRocket2Line.tsx +6 -0
- package/src/icons/remix/RiServerLine.tsx +6 -0
- package/src/icons/remix/RiShareBoxLine.tsx +6 -0
- package/src/icons/remix/RiTv2Line.tsx +6 -0
- package/src/icons/remix/index.ts +14 -0
- package/src/list/index.web.ts +5 -0
- package/src/loading/Loading.tsx +15 -135
- package/src/loading/Loading.web.tsx +16 -134
- package/src/loading/LoadingBase.tsx +170 -0
- package/src/loading/index.web.ts +5 -13
- package/src/media-flight/index.web.ts +5 -9
- package/src/menubar/Menubar.tsx +16 -147
- package/src/menubar/Menubar.web.tsx +15 -138
- package/src/menubar/MenubarBase.tsx +170 -0
- package/src/menubar/index.web.ts +5 -0
- package/src/motion/index.web.ts +5 -5
- package/src/popover/index.web.ts +5 -0
- package/src/popover/parts.tsx +76 -12
- package/src/popover/surface.ts +68 -15
- package/src/portal/index.web.ts +6 -1
- package/src/progressive-blur/index.web.ts +5 -0
- package/src/scroll/index.web.ts +5 -0
- package/src/segmented-control/SegmentedControl.tsx +45 -1
- package/src/select/Select.tsx +4 -67
- package/src/select/Select.web.tsx +133 -69
- package/src/select/index.ts +3 -3
- package/src/select/index.web.ts +8 -3
- package/src/select/shared.tsx +107 -5
- package/src/select/types.ts +6 -0
- package/src/sidebar/SidebarTeamMenu.tsx +2 -2
- package/src/sidebar/SidebarUserMenu.tsx +2 -2
- package/src/sidebar/parts.tsx +8 -9
- package/src/surfaces/SurfaceHost.tsx +6 -0
- package/src/surfaces/index.web.ts +14 -4
- package/src/tab-bar/index.web.ts +13 -10
- package/src/tabs/Tabs.tsx +65 -1
- package/src/tabs/types.ts +6 -0
- package/src/theme/color-scope/index.web.ts +5 -0
- package/src/theme/persistence.ts +11 -1
- package/src/theme/seed-scope/index.web.ts +5 -0
- package/src/tooltip/index.web.ts +5 -0
|
@@ -0,0 +1,204 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The keyboard half of the WAI-ARIA composite widgets — tabs, radio groups and
|
|
3
|
+
* listboxes — on WEB, where react-native-web supplies none of it.
|
|
4
|
+
*
|
|
5
|
+
* Three gaps, all measured in a browser against `Tabs`, `SegmentedControl` and
|
|
6
|
+
* `Select`, and all silent: the markup carries the right `role` and state, so
|
|
7
|
+
* nothing in a DOM snapshot says the widget cannot be operated.
|
|
8
|
+
*
|
|
9
|
+
* - EVERY option was its own tab stop. react-native-web gives each `Pressable`
|
|
10
|
+
* `tabIndex=0`, so a five-tab strip cost five Tab presses to walk past.
|
|
11
|
+
* - ARROW KEYS did nothing. A composite widget is ONE tab stop whose options
|
|
12
|
+
* are reached with the arrows; without them the only route is Tab.
|
|
13
|
+
* - SPACE did nothing on a `tab`, `radio` or `option`. react-native-web's
|
|
14
|
+
* press responder (`PressResponder.isValidKeyPress`) activates on Space only
|
|
15
|
+
* for `role="button"` or a real `<button>`; any other role answers Enter
|
|
16
|
+
* alone.
|
|
17
|
+
*
|
|
18
|
+
* WHY THE DOM, NOT PROPS. The group has to know which of its options is
|
|
19
|
+
* selected, which are disabled, and in which ORDER they sit on screen — and it
|
|
20
|
+
* receives its options as `children` it did not create. The DOM already holds
|
|
21
|
+
* all three (`aria-selected` / `aria-checked`, `aria-disabled`, document order),
|
|
22
|
+
* so this module reads them there instead of growing a second registry that
|
|
23
|
+
* could disagree with what is rendered. Every function is a no-op without a
|
|
24
|
+
* DOM, and every caller gates on `Platform.OS === 'web'`, so native is
|
|
25
|
+
* untouched.
|
|
26
|
+
*
|
|
27
|
+
* Activation goes through `element.click()`: that is the press the option's own
|
|
28
|
+
* `onPress` already hears (react-native-web routes `click` to `onPress`), so a
|
|
29
|
+
* key and a pointer select through exactly one code path.
|
|
30
|
+
*/
|
|
31
|
+
import { useLayoutEffect } from 'react';
|
|
32
|
+
import { Platform } from 'react-native';
|
|
33
|
+
|
|
34
|
+
const IS_WEB = Platform.OS === 'web';
|
|
35
|
+
|
|
36
|
+
/** Which arrow pair moves between the options. */
|
|
37
|
+
export type RovingOrientation = 'horizontal' | 'vertical' | 'both';
|
|
38
|
+
|
|
39
|
+
/** Where a key asks focus to go. */
|
|
40
|
+
export type RovingMove = 'next' | 'prev' | 'first' | 'last';
|
|
41
|
+
|
|
42
|
+
export interface RovingKeyOptions {
|
|
43
|
+
orientation: RovingOrientation;
|
|
44
|
+
/** Home/End jump to the ends (tabs and listboxes; a radio group has none). */
|
|
45
|
+
homeEnd?: boolean;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
/** The move a key asks for, or `null` for a key this widget does not own. */
|
|
49
|
+
export function rovingMove(key: string, { orientation, homeEnd = true }: RovingKeyOptions): RovingMove | null {
|
|
50
|
+
const horizontal = orientation !== 'vertical';
|
|
51
|
+
const vertical = orientation !== 'horizontal';
|
|
52
|
+
switch (key) {
|
|
53
|
+
case 'ArrowRight':
|
|
54
|
+
return horizontal ? 'next' : null;
|
|
55
|
+
case 'ArrowLeft':
|
|
56
|
+
return horizontal ? 'prev' : null;
|
|
57
|
+
case 'ArrowDown':
|
|
58
|
+
return vertical ? 'next' : null;
|
|
59
|
+
case 'ArrowUp':
|
|
60
|
+
return vertical ? 'prev' : null;
|
|
61
|
+
case 'Home':
|
|
62
|
+
return homeEnd ? 'first' : null;
|
|
63
|
+
case 'End':
|
|
64
|
+
return homeEnd ? 'last' : null;
|
|
65
|
+
default:
|
|
66
|
+
return null;
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
export function isSpaceKey(key: string): boolean {
|
|
71
|
+
return key === ' ' || key === 'Spacebar';
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
function isDisabled(element: HTMLElement): boolean {
|
|
75
|
+
return (
|
|
76
|
+
element.getAttribute('aria-disabled') === 'true' ||
|
|
77
|
+
(element as HTMLElement & { disabled?: boolean }).disabled === true
|
|
78
|
+
);
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
/**
|
|
82
|
+
* The options that belong to `container`, in document order.
|
|
83
|
+
*
|
|
84
|
+
* `owner`, when given, is the selector of the group itself: an option whose
|
|
85
|
+
* nearest such ancestor is NOT `container` belongs to a nested group and is
|
|
86
|
+
* skipped, so a radio group inside a tab panel inside a tab strip never
|
|
87
|
+
* mistakes the inner options for its own.
|
|
88
|
+
*/
|
|
89
|
+
export function rovingItems(
|
|
90
|
+
container: Element | null,
|
|
91
|
+
selector: string,
|
|
92
|
+
{ owner, includeDisabled = false }: { owner?: string; includeDisabled?: boolean } = {},
|
|
93
|
+
): HTMLElement[] {
|
|
94
|
+
if (!container) return [];
|
|
95
|
+
return Array.from(container.querySelectorAll<HTMLElement>(selector)).filter(
|
|
96
|
+
(element) =>
|
|
97
|
+
(includeDisabled || !isDisabled(element)) &&
|
|
98
|
+
(owner === undefined || element.parentElement?.closest(owner) === container),
|
|
99
|
+
);
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
/**
|
|
103
|
+
* The option a move lands on. `wrap` carries the last option round to the first
|
|
104
|
+
* (tabs, radio groups); a listbox stops at its ends.
|
|
105
|
+
*/
|
|
106
|
+
export function rovingTarget(
|
|
107
|
+
items: readonly HTMLElement[],
|
|
108
|
+
current: Element | null,
|
|
109
|
+
move: RovingMove,
|
|
110
|
+
wrap: boolean,
|
|
111
|
+
): HTMLElement | null {
|
|
112
|
+
const count = items.length;
|
|
113
|
+
if (count === 0) return null;
|
|
114
|
+
if (move === 'first') return items[0] ?? null;
|
|
115
|
+
if (move === 'last') return items[count - 1] ?? null;
|
|
116
|
+
const index = current ? items.indexOf(current as HTMLElement) : -1;
|
|
117
|
+
if (index < 0) return (move === 'next' ? items[0] : items[count - 1]) ?? null;
|
|
118
|
+
const step = move === 'next' ? 1 : -1;
|
|
119
|
+
const next = index + step;
|
|
120
|
+
if (next >= 0 && next < count) return items[next] ?? null;
|
|
121
|
+
return wrap ? (items[(next + count) % count] ?? null) : (items[index] ?? null);
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
/**
|
|
125
|
+
* Exactly ONE tab stop: the selected option, or — when nothing is selected, or
|
|
126
|
+
* the selected option is disabled — the first enabled one, so the group stays
|
|
127
|
+
* reachable. Every other option takes `tabIndex=-1`: still focusable by the
|
|
128
|
+
* arrows, skipped by Tab.
|
|
129
|
+
*/
|
|
130
|
+
export function applyRovingTabIndex(
|
|
131
|
+
container: Element | null,
|
|
132
|
+
selector: string,
|
|
133
|
+
isSelected: (element: HTMLElement) => boolean,
|
|
134
|
+
owner?: string,
|
|
135
|
+
): void {
|
|
136
|
+
const all = rovingItems(container, selector, { owner, includeDisabled: true });
|
|
137
|
+
const enabled = all.filter((element) => !isDisabled(element));
|
|
138
|
+
const stop = enabled.find(isSelected) ?? enabled[0];
|
|
139
|
+
for (const element of all) {
|
|
140
|
+
const wanted = element === stop ? 0 : -1;
|
|
141
|
+
if (element.tabIndex !== wanted) element.tabIndex = wanted;
|
|
142
|
+
}
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
/**
|
|
146
|
+
* Keep the group's roving tab stop in step with its selection.
|
|
147
|
+
*
|
|
148
|
+
* Runs after EVERY render of the group, without deps, because the group
|
|
149
|
+
* re-renders whenever an option's selection or `disabled` changes (both arrive
|
|
150
|
+
* through the group's own props or its children), and a layout effect runs
|
|
151
|
+
* after the children have committed the attributes it reads. It writes the DOM
|
|
152
|
+
* only where a value differs, so an idle re-render costs one query.
|
|
153
|
+
*/
|
|
154
|
+
export function useRovingTabIndex(
|
|
155
|
+
getContainer: () => Element | null,
|
|
156
|
+
selector: string,
|
|
157
|
+
isSelected: (element: HTMLElement) => boolean,
|
|
158
|
+
owner?: string,
|
|
159
|
+
): void {
|
|
160
|
+
useLayoutEffect(() => {
|
|
161
|
+
if (!IS_WEB) return;
|
|
162
|
+
applyRovingTabIndex(getContainer(), selector, isSelected, owner);
|
|
163
|
+
});
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
/**
|
|
167
|
+
* The shared keydown for a tab strip or radio group option. Returns whether it
|
|
168
|
+
* handled the key (and so prevented its default).
|
|
169
|
+
*
|
|
170
|
+
* - Arrows (per `orientation`), and Home/End where `homeEnd`, move focus with
|
|
171
|
+
* wrap-around. With `activate: 'follow'` (automatic activation) the option
|
|
172
|
+
* focused is also selected; with `'manual'` only focus moves and Enter or
|
|
173
|
+
* Space selects.
|
|
174
|
+
* - Space selects the focused option — the key react-native-web drops.
|
|
175
|
+
*/
|
|
176
|
+
export function handleRovingKeyDown(
|
|
177
|
+
event: { key: string; currentTarget: unknown; preventDefault: () => void },
|
|
178
|
+
{
|
|
179
|
+
selector,
|
|
180
|
+
owner,
|
|
181
|
+
orientation,
|
|
182
|
+
homeEnd,
|
|
183
|
+
activate,
|
|
184
|
+
}: RovingKeyOptions & { selector: string; owner: string; activate: 'follow' | 'manual' },
|
|
185
|
+
): boolean {
|
|
186
|
+
const current = event.currentTarget as HTMLElement | null;
|
|
187
|
+
if (!current || typeof current.closest !== 'function') return false;
|
|
188
|
+
if (isSpaceKey(event.key)) {
|
|
189
|
+
if (isDisabled(current)) return false;
|
|
190
|
+
// Space scrolls the page by default; the option answers it instead.
|
|
191
|
+
event.preventDefault();
|
|
192
|
+
current.click();
|
|
193
|
+
return true;
|
|
194
|
+
}
|
|
195
|
+
const move = rovingMove(event.key, { orientation, homeEnd });
|
|
196
|
+
if (move === null) return false;
|
|
197
|
+
const container = current.closest(owner);
|
|
198
|
+
const target = rovingTarget(rovingItems(container, selector, { owner }), current, move, true);
|
|
199
|
+
if (!target) return false;
|
|
200
|
+
event.preventDefault();
|
|
201
|
+
target.focus();
|
|
202
|
+
if (activate === 'follow' && target !== current) target.click();
|
|
203
|
+
return true;
|
|
204
|
+
}
|
|
@@ -1,3 +1,8 @@
|
|
|
1
|
+
// AUTO-GENERATED by scripts/generate-platform-exports.mjs — DO NOT EDIT.
|
|
2
|
+
// Source of truth: src/hover-card/index.ts.
|
|
3
|
+
// Re-run `bun run generate:exports` (or any `bun run build`) after
|
|
4
|
+
// changing that barrel or the set of web-forked subpaths.
|
|
5
|
+
|
|
1
6
|
export { HoverCard, HoverCardTrigger, HoverCardContent } from './HoverCard.web';
|
|
2
7
|
export {
|
|
3
8
|
HOVER_CARD_CLOSE_DELAY,
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { createSinglePathSVG } from '../TEMPLATE';
|
|
2
|
+
|
|
3
|
+
/** Remix Icon `book-read-line` (Document). */
|
|
4
|
+
export const RiBookReadLine = createSinglePathSVG({
|
|
5
|
+
path: 'M2 3.9934C2 3.44476 2.45531 3 2.9918 3H21.0082C21.556 3 22 3.44495 22 3.9934V20.0066C22 20.5552 21.5447 21 21.0082 21H2.9918C2.44405 21 2 20.5551 2 20.0066V3.9934ZM11 5H4V19H11V5ZM13 5V19H20V5H13ZM14 7H19V9H14V7ZM14 10H19V12H14V10Z',
|
|
6
|
+
});
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { createSinglePathSVG } from '../TEMPLATE';
|
|
2
|
+
|
|
3
|
+
/** Remix Icon `bug-line` (Development). */
|
|
4
|
+
export const RiBugLine = createSinglePathSVG({
|
|
5
|
+
path: 'M13 19.9C15.2822 19.4367 17 17.419 17 15V12C17 11.299 16.8564 10.6219 16.5846 10H7.41538C7.14358 10.6219 7 11.299 7 12V15C7 17.419 8.71776 19.4367 11 19.9V14H13V19.9ZM5.5358 17.6907C5.19061 16.8623 5 15.9534 5 15H2V13H5V12C5 11.3573 5.08661 10.7348 5.2488 10.1436L3.0359 8.86602L4.0359 7.13397L6.05636 8.30049C6.11995 8.19854 6.18609 8.09835 6.25469 8H17.7453C17.8139 8.09835 17.88 8.19854 17.9436 8.30049L19.9641 7.13397L20.9641 8.86602L18.7512 10.1436C18.9134 10.7348 19 11.3573 19 12V13H22V15H19C19 15.9534 18.8094 16.8623 18.4642 17.6907L20.9641 19.134L19.9641 20.866L17.4383 19.4077C16.1549 20.9893 14.1955 22 12 22C9.80453 22 7.84512 20.9893 6.56171 19.4077L4.0359 20.866L3.0359 19.134L5.5358 17.6907ZM8 6C8 3.79086 9.79086 2 12 2C14.2091 2 16 3.79086 16 6H8Z',
|
|
6
|
+
});
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { createSinglePathSVG } from '../TEMPLATE';
|
|
2
|
+
|
|
3
|
+
/** Remix Icon `chat-1-line` (Communication). */
|
|
4
|
+
export const RiChat1Line = createSinglePathSVG({
|
|
5
|
+
path: 'M10 3H14C18.4183 3 22 6.58172 22 11C22 15.4183 18.4183 19 14 19V22.5C9 20.5 2 17.5 2 11C2 6.58172 5.58172 3 10 3ZM12 17H14C17.3137 17 20 14.3137 20 11C20 7.68629 17.3137 5 14 5H10C6.68629 5 4 7.68629 4 11C4 14.61 6.46208 16.9656 12 19.4798V17Z',
|
|
6
|
+
});
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { createSinglePathSVG } from '../TEMPLATE';
|
|
2
|
+
|
|
3
|
+
/** Remix Icon `cloud-line` (Business). */
|
|
4
|
+
export const RiCloudLine = createSinglePathSVG({
|
|
5
|
+
path: 'M12 2C15.866 2 19 5.13401 19 9C19 9.11351 18.9973 9.22639 18.992 9.33857C21.3265 10.16 23 12.3846 23 15C23 18.3137 20.3137 21 17 21H7C3.68629 21 1 18.3137 1 15C1 12.3846 2.67346 10.16 5.00804 9.33857C5.0027 9.22639 5 9.11351 5 9C5 5.13401 8.13401 2 12 2ZM12 4C9.23858 4 7 6.23858 7 9C7 9.08147 7.00193 9.16263 7.00578 9.24344L7.07662 10.7309L5.67183 11.2252C4.0844 11.7837 3 13.2889 3 15C3 17.2091 4.79086 19 7 19H17C19.2091 19 21 17.2091 21 15C21 12.79 19.21 11 17 11C15.233 11 13.7337 12.1457 13.2042 13.7347L11.3064 13.1021C12.1005 10.7185 14.35 9 17 9C17 6.23858 14.7614 4 12 4Z',
|
|
6
|
+
});
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { createSinglePathSVG } from '../TEMPLATE';
|
|
2
|
+
|
|
3
|
+
/** Remix Icon `code-line` (Development). */
|
|
4
|
+
export const RiCodeLine = createSinglePathSVG({
|
|
5
|
+
path: 'M23 12L15.9289 19.0711L14.5147 17.6569L20.1716 12L14.5147 6.34317L15.9289 4.92896L23 12ZM3.82843 12L9.48528 17.6569L8.07107 19.0711L1 12L8.07107 4.92896L9.48528 6.34317L3.82843 12Z',
|
|
6
|
+
});
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { createSinglePathSVG } from '../TEMPLATE';
|
|
2
|
+
|
|
3
|
+
/** Remix Icon `cpu-line` (Device). */
|
|
4
|
+
export const RiCpuLine = createSinglePathSVG({
|
|
5
|
+
path: 'M6 18H18V6H6V18ZM14 20H10V22H8V20H5C4.44772 20 4 19.5523 4 19V16H2V14H4V10H2V8H4V5C4 4.44772 4.44772 4 5 4H8V2H10V4H14V2H16V4H19C19.5523 4 20 4.44772 20 5V8H22V10H20V14H22V16H20V19C20 19.5523 19.5523 20 19 20H16V22H14V20ZM8 8H16V16H8V8Z',
|
|
6
|
+
});
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { createSinglePathSVG } from '../TEMPLATE';
|
|
2
|
+
|
|
3
|
+
/** Remix Icon `flood-line` (Weather). */
|
|
4
|
+
export const RiFloodLine = createSinglePathSVG({
|
|
5
|
+
path: 'M16.0001 17.4723C17.0616 18.4223 18.4634 19 20 19H22V21H20C18.5428 21 17.1766 20.6104 15.9998 19.9296C14.8242 20.6101 13.4576 21 12 21C10.5428 21 9.17657 20.6104 7.99984 19.9296C6.8242 20.6101 5.45763 21 4 21H2V19H4C5.53713 19 6.93925 18.422 8.00013 17.4723C9.06163 18.4223 10.4634 19 12 19C13.5371 19 14.9393 18.422 16.0001 17.4723ZM12.5734 1.53204L12.6727 1.6115L23 11H20V17C19.2988 17 18.6258 16.8797 18.0003 16.6587L18 9.15698L12 3.70198L6 9.15598L6.00125 16.6582C5.4648 16.8479 4.89325 16.9635 4.29898 16.9927L4 17V11H1L11.3273 1.6115C11.677 1.29365 12.1956 1.26716 12.5734 1.53204Z',
|
|
6
|
+
});
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { createSinglePathSVG } from '../TEMPLATE';
|
|
2
|
+
|
|
3
|
+
/** Remix Icon `lock-unlock-line` (System). */
|
|
4
|
+
export const RiLockUnlockLine = createSinglePathSVG({
|
|
5
|
+
path: 'M7 10H20C20.5523 10 21 10.4477 21 11V21C21 21.5523 20.5523 22 20 22H4C3.44772 22 3 21.5523 3 21V11C3 10.4477 3.44772 10 4 10H5V9C5 5.13401 8.13401 2 12 2C14.7405 2 17.1131 3.5748 18.2624 5.86882L16.4731 6.76344C15.6522 5.12486 13.9575 4 12 4C9.23858 4 7 6.23858 7 9V10ZM5 12V20H19V12H5ZM10 15H14V17H10V15Z',
|
|
6
|
+
});
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { createSinglePathSVG } from '../TEMPLATE';
|
|
2
|
+
|
|
3
|
+
/** Remix Icon `money-dollar-circle-line` (Finance). */
|
|
4
|
+
export const RiMoneyDollarCircleLine = createSinglePathSVG({
|
|
5
|
+
path: 'M12.0049 22.0027C6.48204 22.0027 2.00488 17.5256 2.00488 12.0027C2.00488 6.4799 6.48204 2.00275 12.0049 2.00275C17.5277 2.00275 22.0049 6.4799 22.0049 12.0027C22.0049 17.5256 17.5277 22.0027 12.0049 22.0027ZM12.0049 20.0027C16.4232 20.0027 20.0049 16.421 20.0049 12.0027C20.0049 7.58447 16.4232 4.00275 12.0049 4.00275C7.5866 4.00275 4.00488 7.58447 4.00488 12.0027C4.00488 16.421 7.5866 20.0027 12.0049 20.0027ZM8.50488 14.0027H14.0049C14.281 14.0027 14.5049 13.7789 14.5049 13.5027C14.5049 13.2266 14.281 13.0027 14.0049 13.0027H10.0049C8.62417 13.0027 7.50488 11.8835 7.50488 10.5027C7.50488 9.12203 8.62417 8.00275 10.0049 8.00275H11.0049V6.00275H13.0049V8.00275H15.5049V10.0027H10.0049C9.72874 10.0027 9.50488 10.2266 9.50488 10.5027C9.50488 10.7789 9.72874 11.0027 10.0049 11.0027H14.0049C15.3856 11.0027 16.5049 12.122 16.5049 13.5027C16.5049 14.8835 15.3856 16.0027 14.0049 16.0027H13.0049V18.0027H11.0049V16.0027H8.50488V14.0027Z',
|
|
6
|
+
});
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { createSinglePathSVG } from '../TEMPLATE';
|
|
2
|
+
|
|
3
|
+
/** Remix Icon `play-circle-line` (Media). */
|
|
4
|
+
export const RiPlayCircleLine = createSinglePathSVG({
|
|
5
|
+
path: 'M12 22C6.47715 22 2 17.5228 2 12C2 6.47715 6.47715 2 12 2C17.5228 2 22 6.47715 22 12C22 17.5228 17.5228 22 12 22ZM12 20C16.4183 20 20 16.4183 20 12C20 7.58172 16.4183 4 12 4C7.58172 4 4 7.58172 4 12C4 16.4183 7.58172 20 12 20ZM10.6219 8.41459L15.5008 11.6672C15.6846 11.7897 15.7343 12.0381 15.6117 12.2219C15.5824 12.2658 15.5447 12.3035 15.5008 12.3328L10.6219 15.5854C10.4381 15.708 10.1897 15.6583 10.0672 15.4745C10.0234 15.4088 10 15.3316 10 15.2526V8.74741C10 8.52649 10.1791 8.34741 10.4 8.34741C10.479 8.34741 10.5562 8.37078 10.6219 8.41459Z',
|
|
6
|
+
});
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { createSinglePathSVG } from '../TEMPLATE';
|
|
2
|
+
|
|
3
|
+
/** Remix Icon `rocket-2-line` (Map). */
|
|
4
|
+
export const RiRocket2Line = createSinglePathSVG({
|
|
5
|
+
path: 'M15.5018 20.0048C14.8432 21.5841 13.5794 22.848 12 23.5066C10.4206 22.848 9.15679 21.5841 8.49816 20.0048H10.7575C11.0838 20.4934 11.5051 20.9171 12 21.248C12.4949 20.9171 12.9162 20.4934 13.2425 20.0048H15.5018ZM18 14.8095L20 17.0777V19.0048H4V17.0777L6 14.8095V9.00478C6 5.52153 8.50442 2.55822 12 1.45999C15.4956 2.55822 18 5.52153 18 9.00478V14.8095ZM17.2692 17.0048L16 15.5653V9.00478C16 6.68694 14.4292 4.57431 12 3.58384C9.57078 4.57431 8 6.68694 8 9.00478V15.5653L6.73076 17.0048H17.2692ZM12 11.0048C10.8954 11.0048 10 10.1093 10 9.00478C10 7.90021 10.8954 7.00478 12 7.00478C13.1046 7.00478 14 7.90021 14 9.00478C14 10.1093 13.1046 11.0048 12 11.0048Z',
|
|
6
|
+
});
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { createSinglePathSVG } from '../TEMPLATE';
|
|
2
|
+
|
|
3
|
+
/** Remix Icon `server-line` (Device). */
|
|
4
|
+
export const RiServerLine = createSinglePathSVG({
|
|
5
|
+
path: 'M5 11H19V5H5V11ZM21 4V20C21 20.5523 20.5523 21 20 21H4C3.44772 21 3 20.5523 3 20V4C3 3.44772 3.44772 3 4 3H20C20.5523 3 21 3.44772 21 4ZM19 13H5V19H19V13ZM7 15H10V17H7V15ZM7 7H10V9H7V7Z',
|
|
6
|
+
});
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { createSinglePathSVG } from '../TEMPLATE';
|
|
2
|
+
|
|
3
|
+
/** Remix Icon `share-box-line` (System). */
|
|
4
|
+
export const RiShareBoxLine = createSinglePathSVG({
|
|
5
|
+
path: 'M10 3V5H5V19H19V14H21V20C21 20.5523 20.5523 21 20 21H4C3.44772 21 3 20.5523 3 20V4C3 3.44772 3.44772 3 4 3H10ZM17.5858 5H13V3H21V11H19V6.41421L12 13.4142L10.5858 12L17.5858 5Z',
|
|
6
|
+
});
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { createSinglePathSVG } from '../TEMPLATE';
|
|
2
|
+
|
|
3
|
+
/** Remix Icon `tv-2-line` (Device). */
|
|
4
|
+
export const RiTv2Line = createSinglePathSVG({
|
|
5
|
+
path: 'M2 4.00087C2 3.44811 2.45531 3 2.9918 3H21.0082C21.556 3 22 3.44463 22 4.00087V17.9991C22 18.5519 21.5447 19 21.0082 19H2.9918C2.44405 19 2 18.5554 2 17.9991V4.00087ZM4 5V17H20V5H4ZM5 20H19V22H5V20Z',
|
|
6
|
+
});
|
package/src/icons/remix/index.ts
CHANGED
|
@@ -55,6 +55,7 @@ export { RiBlueskyFill } from './RiBlueskyFill';
|
|
|
55
55
|
export { RiBold } from './RiBold';
|
|
56
56
|
export { RiBookOpenFill } from './RiBookOpenFill';
|
|
57
57
|
export { RiBookOpenLine } from './RiBookOpenLine';
|
|
58
|
+
export { RiBookReadLine } from './RiBookReadLine';
|
|
58
59
|
export { RiBookShelfLine } from './RiBookShelfLine';
|
|
59
60
|
export { RiBookmark3Line } from './RiBookmark3Line';
|
|
60
61
|
export { RiBookmarkFill } from './RiBookmarkFill';
|
|
@@ -63,6 +64,7 @@ export { RiBox3Line } from './RiBox3Line';
|
|
|
63
64
|
export { RiBriefcase4Line } from './RiBriefcase4Line';
|
|
64
65
|
export { RiBroadcastLine } from './RiBroadcastLine';
|
|
65
66
|
export { RiBrushAiLine } from './RiBrushAiLine';
|
|
67
|
+
export { RiBugLine } from './RiBugLine';
|
|
66
68
|
export { RiBuilding2Line } from './RiBuilding2Line';
|
|
67
69
|
export { RiBuilding4Line } from './RiBuilding4Line';
|
|
68
70
|
export { RiBuildingLine } from './RiBuildingLine';
|
|
@@ -81,6 +83,7 @@ export { RiCameraSwitchLine } from './RiCameraSwitchLine';
|
|
|
81
83
|
export { RiCapsuleFill } from './RiCapsuleFill';
|
|
82
84
|
export { RiCarLine } from './RiCarLine';
|
|
83
85
|
export { RiCastLine } from './RiCastLine';
|
|
86
|
+
export { RiChat1Line } from './RiChat1Line';
|
|
84
87
|
export { RiChat3Fill } from './RiChat3Fill';
|
|
85
88
|
export { RiChat3Line } from './RiChat3Line';
|
|
86
89
|
export { RiChat4Fill } from './RiChat4Fill';
|
|
@@ -101,7 +104,9 @@ export { RiCloseCircleLine } from './RiCloseCircleLine';
|
|
|
101
104
|
export { RiCloseLine } from './RiCloseLine';
|
|
102
105
|
export { RiClosedCaptioningFill } from './RiClosedCaptioningFill';
|
|
103
106
|
export { RiClosedCaptioningLine } from './RiClosedCaptioningLine';
|
|
107
|
+
export { RiCloudLine } from './RiCloudLine';
|
|
104
108
|
export { RiCodeBlock } from './RiCodeBlock';
|
|
109
|
+
export { RiCodeLine } from './RiCodeLine';
|
|
105
110
|
export { RiCodeSLine } from './RiCodeSLine';
|
|
106
111
|
export { RiCodeSSlashLine } from './RiCodeSSlashLine';
|
|
107
112
|
export { RiCoinsFill } from './RiCoinsFill';
|
|
@@ -116,6 +121,7 @@ export { RiContractLeftRightLine } from './RiContractLeftRightLine';
|
|
|
116
121
|
export { RiCornerDownLeftLine } from './RiCornerDownLeftLine';
|
|
117
122
|
export { RiCornerDownRightLine } from './RiCornerDownRightLine';
|
|
118
123
|
export { RiCornerUpLeftLine } from './RiCornerUpLeftLine';
|
|
124
|
+
export { RiCpuLine } from './RiCpuLine';
|
|
119
125
|
export { RiCropLine } from './RiCropLine';
|
|
120
126
|
export { RiCursorLine } from './RiCursorLine';
|
|
121
127
|
export { RiCustomerService2Line } from './RiCustomerService2Line';
|
|
@@ -180,6 +186,7 @@ export { RiFlaskLine } from './RiFlaskLine';
|
|
|
180
186
|
export { RiFlightTakeoffLine } from './RiFlightTakeoffLine';
|
|
181
187
|
export { RiFlipHorizontalLine } from './RiFlipHorizontalLine';
|
|
182
188
|
export { RiFlipVerticalLine } from './RiFlipVerticalLine';
|
|
189
|
+
export { RiFloodLine } from './RiFloodLine';
|
|
183
190
|
export { RiFlowerLine } from './RiFlowerLine';
|
|
184
191
|
export { RiFocus3Line } from './RiFocus3Line';
|
|
185
192
|
export { RiFolder2Line } from './RiFolder2Line';
|
|
@@ -257,6 +264,7 @@ export { RiLiveLine } from './RiLiveLine';
|
|
|
257
264
|
export { RiLoader4Line } from './RiLoader4Line';
|
|
258
265
|
export { RiLock2Line } from './RiLock2Line';
|
|
259
266
|
export { RiLockLine } from './RiLockLine';
|
|
267
|
+
export { RiLockUnlockLine } from './RiLockUnlockLine';
|
|
260
268
|
export { RiLoginBoxLine } from './RiLoginBoxLine';
|
|
261
269
|
export { RiLogoutBoxRLine } from './RiLogoutBoxRLine';
|
|
262
270
|
export { RiLogoutCircleLine } from './RiLogoutCircleLine';
|
|
@@ -284,6 +292,7 @@ export { RiMic2Line } from './RiMic2Line';
|
|
|
284
292
|
export { RiMicLine } from './RiMicLine';
|
|
285
293
|
export { RiMicOffFill } from './RiMicOffFill';
|
|
286
294
|
export { RiMicOffLine } from './RiMicOffLine';
|
|
295
|
+
export { RiMoneyDollarCircleLine } from './RiMoneyDollarCircleLine';
|
|
287
296
|
export { RiMoneyEuroBoxLine } from './RiMoneyEuroBoxLine';
|
|
288
297
|
export { RiMoonClearFill } from './RiMoonClearFill';
|
|
289
298
|
export { RiMoonLine } from './RiMoonLine';
|
|
@@ -313,6 +322,7 @@ export { RiPencilLine } from './RiPencilLine';
|
|
|
313
322
|
export { RiPhoneFill } from './RiPhoneFill';
|
|
314
323
|
export { RiPhoneLine } from './RiPhoneLine';
|
|
315
324
|
export { RiPlantLine } from './RiPlantLine';
|
|
325
|
+
export { RiPlayCircleLine } from './RiPlayCircleLine';
|
|
316
326
|
export { RiPlayFill } from './RiPlayFill';
|
|
317
327
|
export { RiPlayLine } from './RiPlayLine';
|
|
318
328
|
export { RiPlayList2Line } from './RiPlayList2Line';
|
|
@@ -343,6 +353,7 @@ export { RiResetRightLine } from './RiResetRightLine';
|
|
|
343
353
|
export { RiRestaurantLine } from './RiRestaurantLine';
|
|
344
354
|
export { RiRobot2Fill } from './RiRobot2Fill';
|
|
345
355
|
export { RiRobot2Line } from './RiRobot2Line';
|
|
356
|
+
export { RiRocket2Line } from './RiRocket2Line';
|
|
346
357
|
export { RiRouteLine } from './RiRouteLine';
|
|
347
358
|
export { RiRssFill } from './RiRssFill';
|
|
348
359
|
export { RiRulerLine } from './RiRulerLine';
|
|
@@ -353,6 +364,7 @@ export { RiSearchFill } from './RiSearchFill';
|
|
|
353
364
|
export { RiSearchLine } from './RiSearchLine';
|
|
354
365
|
export { RiSeedlingLine } from './RiSeedlingLine';
|
|
355
366
|
export { RiSendPlaneLine } from './RiSendPlaneLine';
|
|
367
|
+
export { RiServerLine } from './RiServerLine';
|
|
356
368
|
export { RiSettings3Fill } from './RiSettings3Fill';
|
|
357
369
|
export { RiSettings3Line } from './RiSettings3Line';
|
|
358
370
|
export { RiSettings4Line } from './RiSettings4Line';
|
|
@@ -361,6 +373,7 @@ export { RiSettingsLine } from './RiSettingsLine';
|
|
|
361
373
|
export { RiShakeHandsLine } from './RiShakeHandsLine';
|
|
362
374
|
export { RiShapesLine } from './RiShapesLine';
|
|
363
375
|
export { RiShare2Line } from './RiShare2Line';
|
|
376
|
+
export { RiShareBoxLine } from './RiShareBoxLine';
|
|
364
377
|
export { RiShareForwardLine } from './RiShareForwardLine';
|
|
365
378
|
export { RiShareLine } from './RiShareLine';
|
|
366
379
|
export { RiShieldCheckFill } from './RiShieldCheckFill';
|
|
@@ -426,6 +439,7 @@ export { RiToolsLine } from './RiToolsLine';
|
|
|
426
439
|
export { RiTrainLine } from './RiTrainLine';
|
|
427
440
|
export { RiTranslate2 } from './RiTranslate2';
|
|
428
441
|
export { RiTreeLine } from './RiTreeLine';
|
|
442
|
+
export { RiTv2Line } from './RiTv2Line';
|
|
429
443
|
export { RiTvLine } from './RiTvLine';
|
|
430
444
|
export { RiTwitterXFill } from './RiTwitterXFill';
|
|
431
445
|
export { RiUnpinLine } from './RiUnpinLine';
|
package/src/list/index.web.ts
CHANGED
|
@@ -1,3 +1,8 @@
|
|
|
1
|
+
// AUTO-GENERATED by scripts/generate-platform-exports.mjs — DO NOT EDIT.
|
|
2
|
+
// Source of truth: src/list/index.ts.
|
|
3
|
+
// Re-run `bun run generate:exports` (or any `bun run build`) after
|
|
4
|
+
// changing that barrel or the set of web-forked subpaths.
|
|
5
|
+
|
|
1
6
|
export type {
|
|
2
7
|
VirtualListHandle,
|
|
3
8
|
VirtualListProps,
|
package/src/loading/Loading.tsx
CHANGED
|
@@ -1,8 +1,11 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
1
|
+
/**
|
|
2
|
+
* `Loading` — NATIVE: the `top` variant's motion on react-native-reanimated.
|
|
3
|
+
*
|
|
4
|
+
* Everything else about the family is shared (`LoadingBase`); this file holds
|
|
5
|
+
* only what forks, and binds it. The `spinner` and `inline` variants, the size
|
|
6
|
+
* table and the stylesheet are identical on both platforms.
|
|
7
|
+
*/
|
|
8
|
+
import React, { useEffect } from 'react';
|
|
6
9
|
import Animated, {
|
|
7
10
|
Easing,
|
|
8
11
|
useAnimatedStyle,
|
|
@@ -10,60 +13,14 @@ import Animated, {
|
|
|
10
13
|
withTiming,
|
|
11
14
|
} from 'react-native-reanimated';
|
|
12
15
|
|
|
13
|
-
import {
|
|
16
|
+
import { normalizeBloomSize } from '../appearance/legacy';
|
|
17
|
+
import { resolveBloomColors } from '../appearance/colors';
|
|
18
|
+
import { useBloomAppearance } from '../appearance';
|
|
14
19
|
import { animation } from '../styles/tokens';
|
|
20
|
+
import { useTheme } from '../theme/use-theme';
|
|
21
|
+
import { bindLoading, SIZE_CONFIG, styles } from './LoadingBase';
|
|
15
22
|
import { SpinnerIcon } from './SpinnerIcon';
|
|
16
|
-
import type {
|
|
17
|
-
LoadingProps,
|
|
18
|
-
SpinnerLoadingProps,
|
|
19
|
-
TopLoadingProps,
|
|
20
|
-
InlineLoadingProps,
|
|
21
|
-
} from './types';
|
|
22
|
-
|
|
23
|
-
const SIZE_CONFIG = {
|
|
24
|
-
xs: { spinner: 16, text: 12 },
|
|
25
|
-
sm: { spinner: 20, text: 13 },
|
|
26
|
-
md: { spinner: 24, text: 15 },
|
|
27
|
-
lg: { spinner: 44, text: 16 },
|
|
28
|
-
} as const;
|
|
29
|
-
|
|
30
|
-
const SpinnerLoading: React.FC<SpinnerLoadingProps> = ({
|
|
31
|
-
size: sizeProp,
|
|
32
|
-
color,
|
|
33
|
-
tone: toneProp,
|
|
34
|
-
className,
|
|
35
|
-
text,
|
|
36
|
-
textStyle,
|
|
37
|
-
style,
|
|
38
|
-
showText = true,
|
|
39
|
-
iconSize,
|
|
40
|
-
spinnerIcon,
|
|
41
|
-
testID,
|
|
42
|
-
}) => {
|
|
43
|
-
const theme = useTheme();
|
|
44
|
-
const {size, tone} = useBloomAppearance({size: normalizeBloomSize(sizeProp), tone: toneProp}, {size: 'md', tone: 'accent'});
|
|
45
|
-
const sizeConfig = SIZE_CONFIG[size];
|
|
46
|
-
const effectiveIconSize = iconSize ?? sizeConfig.spinner;
|
|
47
|
-
const spinnerColor = className ? 'currentColor' : (color ?? resolveBloomColors(theme.colors, tone, 'solid').background);
|
|
48
|
-
const textColor = color ?? theme.colors.textSecondary;
|
|
49
|
-
|
|
50
|
-
return (
|
|
51
|
-
<View style={[styles.container, style]} testID={testID}>
|
|
52
|
-
{spinnerIcon ?? <SpinnerIcon size={effectiveIconSize} color={spinnerColor} className={className} />}
|
|
53
|
-
{showText && text && (
|
|
54
|
-
<Text
|
|
55
|
-
style={[
|
|
56
|
-
styles.text,
|
|
57
|
-
{ color: textColor, fontSize: sizeConfig.text, marginTop: 8 },
|
|
58
|
-
textStyle,
|
|
59
|
-
]}
|
|
60
|
-
>
|
|
61
|
-
{text}
|
|
62
|
-
</Text>
|
|
63
|
-
)}
|
|
64
|
-
</View>
|
|
65
|
-
);
|
|
66
|
-
};
|
|
23
|
+
import type { TopLoadingProps } from './types';
|
|
67
24
|
|
|
68
25
|
const TopLoading: React.FC<TopLoadingProps> = ({
|
|
69
26
|
size: sizeProp,
|
|
@@ -118,81 +75,4 @@ const TopLoading: React.FC<TopLoadingProps> = ({
|
|
|
118
75
|
);
|
|
119
76
|
};
|
|
120
77
|
|
|
121
|
-
const
|
|
122
|
-
size: sizeProp,
|
|
123
|
-
color,
|
|
124
|
-
tone: toneProp,
|
|
125
|
-
text,
|
|
126
|
-
style,
|
|
127
|
-
textStyle,
|
|
128
|
-
spinnerIcon,
|
|
129
|
-
testID,
|
|
130
|
-
}) => {
|
|
131
|
-
const theme = useTheme();
|
|
132
|
-
const {size, tone} = useBloomAppearance({size: normalizeBloomSize(sizeProp), tone: toneProp}, {size: 'md', tone: 'accent'});
|
|
133
|
-
const sizeConfig = SIZE_CONFIG[size];
|
|
134
|
-
const spinnerColor = color ?? resolveBloomColors(theme.colors, tone, 'solid').background;
|
|
135
|
-
const textColor = theme.colors.textSecondary;
|
|
136
|
-
|
|
137
|
-
return (
|
|
138
|
-
<View style={[styles.inlineContainer, style]} testID={testID}>
|
|
139
|
-
{spinnerIcon ?? <SpinnerIcon size={sizeConfig.spinner} color={spinnerColor} />}
|
|
140
|
-
{text && (
|
|
141
|
-
<Text
|
|
142
|
-
style={[
|
|
143
|
-
{ color: textColor, fontSize: sizeConfig.text, marginLeft: 8 },
|
|
144
|
-
textStyle,
|
|
145
|
-
]}
|
|
146
|
-
>
|
|
147
|
-
{text}
|
|
148
|
-
</Text>
|
|
149
|
-
)}
|
|
150
|
-
</View>
|
|
151
|
-
);
|
|
152
|
-
};
|
|
153
|
-
|
|
154
|
-
const LoadingComponent: React.FC<LoadingProps> = (props) => {
|
|
155
|
-
const variant = props.variant ?? 'spinner';
|
|
156
|
-
|
|
157
|
-
switch (variant) {
|
|
158
|
-
case 'top':
|
|
159
|
-
return <TopLoading {...(props as TopLoadingProps)} />;
|
|
160
|
-
case 'inline':
|
|
161
|
-
return <InlineLoading {...(props as InlineLoadingProps)} />;
|
|
162
|
-
case 'spinner':
|
|
163
|
-
default:
|
|
164
|
-
return <SpinnerLoading {...(props as SpinnerLoadingProps)} />;
|
|
165
|
-
}
|
|
166
|
-
};
|
|
167
|
-
|
|
168
|
-
export const Loading = memo(LoadingComponent);
|
|
169
|
-
Loading.displayName = 'Loading';
|
|
170
|
-
|
|
171
|
-
const styles = StyleSheet.create({
|
|
172
|
-
container: {
|
|
173
|
-
alignItems: 'center',
|
|
174
|
-
justifyContent: 'center',
|
|
175
|
-
padding: 16,
|
|
176
|
-
},
|
|
177
|
-
text: {
|
|
178
|
-
textAlign: 'center',
|
|
179
|
-
},
|
|
180
|
-
topContainer: {
|
|
181
|
-
width: '100%',
|
|
182
|
-
position: 'relative',
|
|
183
|
-
overflow: 'hidden',
|
|
184
|
-
},
|
|
185
|
-
topLoadingView: {
|
|
186
|
-
width: '100%',
|
|
187
|
-
alignItems: 'center',
|
|
188
|
-
justifyContent: 'center',
|
|
189
|
-
position: 'absolute',
|
|
190
|
-
top: 0,
|
|
191
|
-
left: 0,
|
|
192
|
-
},
|
|
193
|
-
inlineContainer: {
|
|
194
|
-
flexDirection: 'row',
|
|
195
|
-
alignItems: 'center',
|
|
196
|
-
justifyContent: 'center',
|
|
197
|
-
},
|
|
198
|
-
});
|
|
78
|
+
export const { Loading } = bindLoading({ SpinnerIcon, TopLoading });
|