@oxy.so/bloom 23.8.1 → 23.9.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/docs/bloom-language-classnames.mdx +11 -11
- package/docs/bloom-language-codemod.mdx +30 -5
- package/docs/bloom-language-for-agents.mdx +1 -1
- package/docs/bloom-language-modifiers.mdx +222 -77
- package/docs/bloom-language-nodes.mdx +43 -21
- package/docs/bloom-language-tokens.mdx +69 -14
- package/docs/bloom-language.mdx +148 -46
- package/docs/design-tokens.mdx +12 -2
- package/docs/no-nativewind.mdx +5 -4
- package/docs/task-catalog.json +1 -1
- package/docs/task-catalog.mdx +1 -1
- package/docs/theme.mdx +22 -6
- package/lib/commonjs/accordion/Accordion.js +12 -12
- package/lib/commonjs/accordion/Accordion.js.map +1 -1
- package/lib/commonjs/accordion/Accordion.web.js +8 -8
- package/lib/commonjs/accordion/Accordion.web.js.map +1 -1
- package/lib/commonjs/agent-creator/AgentCreatorSection.js +8 -10
- package/lib/commonjs/agent-creator/AgentCreatorSection.js.map +1 -1
- package/lib/commonjs/agent-creator/EmotionPicker.js +3 -5
- package/lib/commonjs/agent-creator/EmotionPicker.js.map +1 -1
- package/lib/commonjs/agent-log/AgentLog.js +131 -174
- package/lib/commonjs/agent-log/AgentLog.js.map +1 -1
- package/lib/commonjs/agent-reply/AgentProfile.js +6 -9
- package/lib/commonjs/agent-reply/AgentProfile.js.map +1 -1
- package/lib/commonjs/agent-thinking/AgentThinking.js +8 -7
- package/lib/commonjs/agent-thinking/AgentThinking.js.map +1 -1
- package/lib/commonjs/agent-thinking/ThinkingReasoning.js +8 -8
- package/lib/commonjs/agent-thinking/ThinkingReasoning.js.map +1 -1
- package/lib/commonjs/app-shell/AppShell.js +5 -7
- package/lib/commonjs/app-shell/AppShell.js.map +1 -1
- package/lib/commonjs/app-shell/AppShellEngine.js +72 -28
- package/lib/commonjs/app-shell/AppShellEngine.js.map +1 -1
- package/lib/commonjs/app-shell/AppShellPanelLayout.js +3 -3
- package/lib/commonjs/app-shell/AppShellPanelLayout.js.map +1 -1
- package/lib/commonjs/app-shell/NotificationBell.js +9 -9
- package/lib/commonjs/app-shell/NotificationBell.js.map +1 -1
- package/lib/commonjs/app-shell/PanelReorderHandle.js +4 -6
- package/lib/commonjs/app-shell/PanelReorderHandle.js.map +1 -1
- package/lib/commonjs/avatar-group/AvatarGroupBase.js +7 -7
- package/lib/commonjs/avatar-group/AvatarGroupBase.js.map +1 -1
- package/lib/commonjs/chat-list/ChatSearchResultsBase.js +4 -4
- package/lib/commonjs/chat-list/ChatSearchResultsBase.js.map +1 -1
- package/lib/commonjs/choice-list/ChoiceList.js +5 -5
- package/lib/commonjs/choice-list/ChoiceList.js.map +1 -1
- package/lib/commonjs/color-swatch-picker/ColorSwatchPicker.js +7 -7
- package/lib/commonjs/color-swatch-picker/ColorSwatchPicker.js.map +1 -1
- package/lib/commonjs/connection-dots/ConnectionDots.js +4 -4
- package/lib/commonjs/connection-dots/ConnectionDots.js.map +1 -1
- package/lib/commonjs/connection-dots/ConnectionDots.web.js +4 -4
- package/lib/commonjs/connection-dots/ConnectionDots.web.js.map +1 -1
- package/lib/commonjs/cover-header/CoverHeader.js +3 -3
- package/lib/commonjs/cover-header/CoverHeader.js.map +1 -1
- package/lib/commonjs/data-table/DataTableSelect.js +8 -8
- package/lib/commonjs/data-table/DataTableSelect.js.map +1 -1
- package/lib/commonjs/design-tokens/theme.css +1 -0
- package/lib/commonjs/design-tokens/tokens.json +390 -0
- package/lib/commonjs/dialog/DialogContent.js +5 -4
- package/lib/commonjs/dialog/DialogContent.js.map +1 -1
- package/lib/commonjs/dialog/DialogHeader.js +6 -5
- package/lib/commonjs/dialog/DialogHeader.js.map +1 -1
- package/lib/commonjs/dialog/SheetShell.js +5 -4
- package/lib/commonjs/dialog/SheetShell.js.map +1 -1
- package/lib/commonjs/expandable-text/ExpandableText.js +3 -3
- package/lib/commonjs/expandable-text/ExpandableText.js.map +1 -1
- package/lib/commonjs/floating/lens/lens-cover.js +56 -0
- package/lib/commonjs/floating/lens/lens-cover.js.map +1 -0
- package/lib/commonjs/floating/lens/native-lens.js.map +1 -1
- package/lib/commonjs/grouped-section/GroupedSection.js +16 -15
- package/lib/commonjs/grouped-section/GroupedSection.js.map +1 -1
- package/lib/commonjs/home-search/BudgetPicker.js +8 -8
- package/lib/commonjs/home-search/BudgetPicker.js.map +1 -1
- package/lib/commonjs/home-search/MoveInPicker.js +7 -7
- package/lib/commonjs/home-search/MoveInPicker.js.map +1 -1
- package/lib/commonjs/icon-circle/IconCircle.js +14 -16
- package/lib/commonjs/icon-circle/IconCircle.js.map +1 -1
- package/lib/commonjs/icons/shared.js +3 -5
- package/lib/commonjs/icons/shared.js.map +1 -1
- package/lib/commonjs/kbd/Kbd.js +8 -8
- package/lib/commonjs/kbd/Kbd.js.map +1 -1
- package/lib/commonjs/layout/ResizeHandle.js +6 -5
- package/lib/commonjs/layout/ResizeHandle.js.map +1 -1
- package/lib/commonjs/link-preview/LinkPreviewCard.js +24 -26
- package/lib/commonjs/link-preview/LinkPreviewCard.js.map +1 -1
- package/lib/commonjs/list/ListBase.js +3 -3
- package/lib/commonjs/list/ListBase.js.map +1 -1
- package/lib/commonjs/list/ListPerson.js +3 -3
- package/lib/commonjs/list/ListPerson.js.map +1 -1
- package/lib/commonjs/listing-editor/ListingPreviewPane.js +30 -30
- package/lib/commonjs/listing-editor/ListingPreviewPane.js.map +1 -1
- package/lib/commonjs/markdown/InlineMarkdown.js +9 -11
- package/lib/commonjs/markdown/InlineMarkdown.js.map +1 -1
- package/lib/commonjs/markdown/MarkdownBlocks.js +35 -43
- package/lib/commonjs/markdown/MarkdownBlocks.js.map +1 -1
- package/lib/commonjs/multi-agent-chat/MultiAgentChatBase.js +5 -8
- package/lib/commonjs/multi-agent-chat/MultiAgentChatBase.js.map +1 -1
- package/lib/commonjs/multi-agent-chat/SelectedAgentPreview.js +9 -11
- package/lib/commonjs/multi-agent-chat/SelectedAgentPreview.js.map +1 -1
- package/lib/commonjs/notifications/NotificationPermissionSheet.js +3 -5
- package/lib/commonjs/notifications/NotificationPermissionSheet.js.map +1 -1
- package/lib/commonjs/notifications/NotificationsScreen.js +21 -27
- package/lib/commonjs/notifications/NotificationsScreen.js.map +1 -1
- package/lib/commonjs/overlay/OverlayInertBoundary.js +33 -12
- package/lib/commonjs/overlay/OverlayInertBoundary.js.map +1 -1
- package/lib/commonjs/page-header/PageHeaderTitleInput.js +20 -20
- package/lib/commonjs/page-header/PageHeaderTitleInput.js.map +1 -1
- package/lib/commonjs/panel-routing/expo-router/StackScene.js +42 -24
- package/lib/commonjs/panel-routing/expo-router/StackScene.js.map +1 -1
- package/lib/commonjs/phone-input/CountryCodeSelect.js +4 -4
- package/lib/commonjs/phone-input/CountryCodeSelect.js.map +1 -1
- package/lib/commonjs/project-board/MemberAvatars.js +7 -9
- package/lib/commonjs/project-board/MemberAvatars.js.map +1 -1
- package/lib/commonjs/project-board/ProjectBoardBase.js +3 -6
- package/lib/commonjs/project-board/ProjectBoardBase.js.map +1 -1
- package/lib/commonjs/project-board/ProjectBoardCanvas.js +2 -2
- package/lib/commonjs/project-board/ProjectBoardCanvas.js.map +1 -1
- package/lib/commonjs/project-board/styles.js +2 -5
- package/lib/commonjs/project-board/styles.js.map +1 -1
- package/lib/commonjs/radio/RadioSwatch.js +5 -5
- package/lib/commonjs/radio/RadioSwatch.js.map +1 -1
- package/lib/commonjs/rating/Rating.js +7 -7
- package/lib/commonjs/rating/Rating.js.map +1 -1
- package/lib/commonjs/rating/RatingBar.js +8 -8
- package/lib/commonjs/rating/RatingBar.js.map +1 -1
- package/lib/commonjs/rating/RatingBar.web.js +5 -5
- package/lib/commonjs/rating/RatingBar.web.js.map +1 -1
- package/lib/commonjs/rating/RatingInput.js +9 -9
- package/lib/commonjs/rating/RatingInput.js.map +1 -1
- package/lib/commonjs/rating/RatingSummary.js +6 -6
- package/lib/commonjs/rating/RatingSummary.js.map +1 -1
- package/lib/commonjs/row-actions/RowActions.js +5 -5
- package/lib/commonjs/row-actions/RowActions.js.map +1 -1
- package/lib/commonjs/select/Select.js +5 -5
- package/lib/commonjs/select/Select.js.map +1 -1
- package/lib/commonjs/skeleton/Skeleton.js +22 -30
- package/lib/commonjs/skeleton/Skeleton.js.map +1 -1
- package/lib/commonjs/stay-filters/AvailabilityFilter.js +3 -3
- package/lib/commonjs/stay-filters/AvailabilityFilter.js.map +1 -1
- package/lib/commonjs/stay-filters/CountFilter.js +3 -3
- package/lib/commonjs/stay-filters/CountFilter.js.map +1 -1
- package/lib/commonjs/stay-filters/FilterFooter.js +7 -7
- package/lib/commonjs/stay-filters/FilterFooter.js.map +1 -1
- package/lib/commonjs/stay-filters/FilterSection.js +12 -12
- package/lib/commonjs/stay-filters/FilterSection.js.map +1 -1
- package/lib/commonjs/stay-filters/SwitchFilterRow.js +9 -9
- package/lib/commonjs/stay-filters/SwitchFilterRow.js.map +1 -1
- package/lib/commonjs/stay-search/GuestPicker.js +5 -5
- package/lib/commonjs/stay-search/GuestPicker.js.map +1 -1
- package/lib/commonjs/stepper/Stepper.js +11 -10
- package/lib/commonjs/stepper/Stepper.js.map +1 -1
- package/lib/commonjs/stepper/StepperRow.js +12 -12
- package/lib/commonjs/stepper/StepperRow.js.map +1 -1
- package/lib/commonjs/subscription-plans/SubscriptionPlans.js +10 -10
- package/lib/commonjs/subscription-plans/SubscriptionPlans.js.map +1 -1
- package/lib/commonjs/subscription-plans/SubscriptionPrice.js +5 -5
- package/lib/commonjs/subscription-plans/SubscriptionPrice.js.map +1 -1
- package/lib/commonjs/task-list/TaskList.js +14 -15
- package/lib/commonjs/task-list/TaskList.js.map +1 -1
- package/lib/commonjs/theme/BloomThemeProvider.js +207 -223
- package/lib/commonjs/theme/BloomThemeProvider.js.map +1 -1
- package/lib/commonjs/theme/build-theme-from-seed.js +1 -1
- package/lib/commonjs/theme/build-theme.js +39 -9
- package/lib/commonjs/theme/build-theme.js.map +1 -1
- package/lib/commonjs/theme/canonical-tokens.js +40 -0
- package/lib/commonjs/theme/canonical-tokens.js.map +1 -0
- package/lib/commonjs/theme/color-policy.js +3 -0
- package/lib/commonjs/theme/color-policy.js.map +1 -1
- package/lib/commonjs/theme/color-scope/resolve-scope.js +48 -5
- package/lib/commonjs/theme/color-scope/resolve-scope.js.map +1 -1
- package/lib/commonjs/theme/color-scope/use-scope.js +1 -5
- package/lib/commonjs/theme/color-scope/use-scope.js.map +1 -1
- package/lib/commonjs/theme/color-tokens.js +32 -10
- package/lib/commonjs/theme/color-tokens.js.map +1 -1
- package/lib/commonjs/theme/color-utils.js +4 -0
- package/lib/commonjs/theme/color-utils.js.map +1 -1
- package/lib/commonjs/theme/default-token-vars.js +92 -0
- package/lib/commonjs/theme/default-token-vars.js.map +1 -0
- package/lib/commonjs/theme/index.js +6 -0
- package/lib/commonjs/theme/index.js.map +1 -1
- package/lib/commonjs/theme/index.web.js +6 -0
- package/lib/commonjs/theme/index.web.js.map +1 -1
- package/lib/commonjs/theme/prepaint-palettes.js +1 -5
- package/lib/commonjs/theme/prepaint-palettes.js.map +1 -1
- package/lib/commonjs/theme/token-registry.js +7 -28
- package/lib/commonjs/theme/token-registry.js.map +1 -1
- package/lib/commonjs/theme/use-theme-paint.js +28 -0
- package/lib/commonjs/theme/use-theme-paint.js.map +1 -1
- package/lib/commonjs/typography/Typography.js +27 -27
- package/lib/commonjs/typography/Typography.js.map +1 -1
- package/lib/commonjs/web-search/WebSearch.js +18 -19
- package/lib/commonjs/web-search/WebSearch.js.map +1 -1
- package/lib/commonjs/wizard/WizardFooterBase.js +10 -10
- package/lib/commonjs/wizard/WizardFooterBase.js.map +1 -1
- package/lib/commonjs/wizard/WizardProgress.js +5 -5
- package/lib/commonjs/wizard/WizardProgress.js.map +1 -1
- package/lib/module/accordion/Accordion.js +12 -12
- package/lib/module/accordion/Accordion.js.map +1 -1
- package/lib/module/accordion/Accordion.web.js +8 -8
- package/lib/module/accordion/Accordion.web.js.map +1 -1
- package/lib/module/agent-creator/AgentCreatorSection.js +8 -10
- package/lib/module/agent-creator/AgentCreatorSection.js.map +1 -1
- package/lib/module/agent-creator/EmotionPicker.js +3 -5
- package/lib/module/agent-creator/EmotionPicker.js.map +1 -1
- package/lib/module/agent-log/AgentLog.js +131 -174
- package/lib/module/agent-log/AgentLog.js.map +1 -1
- package/lib/module/agent-reply/AgentProfile.js +7 -10
- package/lib/module/agent-reply/AgentProfile.js.map +1 -1
- package/lib/module/agent-thinking/AgentThinking.js +8 -7
- package/lib/module/agent-thinking/AgentThinking.js.map +1 -1
- package/lib/module/agent-thinking/ThinkingReasoning.js +8 -8
- package/lib/module/agent-thinking/ThinkingReasoning.js.map +1 -1
- package/lib/module/app-shell/AppShell.js +5 -7
- package/lib/module/app-shell/AppShell.js.map +1 -1
- package/lib/module/app-shell/AppShellEngine.js +73 -29
- package/lib/module/app-shell/AppShellEngine.js.map +1 -1
- package/lib/module/app-shell/AppShellPanelLayout.js +3 -3
- package/lib/module/app-shell/AppShellPanelLayout.js.map +1 -1
- package/lib/module/app-shell/NotificationBell.js +9 -9
- package/lib/module/app-shell/NotificationBell.js.map +1 -1
- package/lib/module/app-shell/PanelReorderHandle.js +4 -6
- package/lib/module/app-shell/PanelReorderHandle.js.map +1 -1
- package/lib/module/avatar-group/AvatarGroupBase.js +7 -7
- package/lib/module/avatar-group/AvatarGroupBase.js.map +1 -1
- package/lib/module/chat-list/ChatSearchResultsBase.js +4 -4
- package/lib/module/chat-list/ChatSearchResultsBase.js.map +1 -1
- package/lib/module/choice-list/ChoiceList.js +5 -5
- package/lib/module/choice-list/ChoiceList.js.map +1 -1
- package/lib/module/color-swatch-picker/ColorSwatchPicker.js +7 -7
- package/lib/module/color-swatch-picker/ColorSwatchPicker.js.map +1 -1
- package/lib/module/connection-dots/ConnectionDots.js +4 -4
- package/lib/module/connection-dots/ConnectionDots.js.map +1 -1
- package/lib/module/connection-dots/ConnectionDots.web.js +4 -4
- package/lib/module/connection-dots/ConnectionDots.web.js.map +1 -1
- package/lib/module/cover-header/CoverHeader.js +3 -3
- package/lib/module/cover-header/CoverHeader.js.map +1 -1
- package/lib/module/data-table/DataTableSelect.js +8 -8
- package/lib/module/data-table/DataTableSelect.js.map +1 -1
- package/lib/module/design-tokens/theme.css +1 -0
- package/lib/module/design-tokens/tokens.json +390 -0
- package/lib/module/dialog/DialogContent.js +5 -4
- package/lib/module/dialog/DialogContent.js.map +1 -1
- package/lib/module/dialog/DialogHeader.js +6 -5
- package/lib/module/dialog/DialogHeader.js.map +1 -1
- package/lib/module/dialog/SheetShell.js +5 -4
- package/lib/module/dialog/SheetShell.js.map +1 -1
- package/lib/module/expandable-text/ExpandableText.js +3 -3
- package/lib/module/expandable-text/ExpandableText.js.map +1 -1
- package/lib/module/floating/lens/lens-cover.js +51 -0
- package/lib/module/floating/lens/lens-cover.js.map +1 -0
- package/lib/module/floating/lens/native-lens.js.map +1 -1
- package/lib/module/grouped-section/GroupedSection.js +16 -15
- package/lib/module/grouped-section/GroupedSection.js.map +1 -1
- package/lib/module/home-search/BudgetPicker.js +8 -8
- package/lib/module/home-search/BudgetPicker.js.map +1 -1
- package/lib/module/home-search/MoveInPicker.js +7 -7
- package/lib/module/home-search/MoveInPicker.js.map +1 -1
- package/lib/module/icon-circle/IconCircle.js +14 -16
- package/lib/module/icon-circle/IconCircle.js.map +1 -1
- package/lib/module/icons/shared.js +3 -5
- package/lib/module/icons/shared.js.map +1 -1
- package/lib/module/kbd/Kbd.js +8 -8
- package/lib/module/kbd/Kbd.js.map +1 -1
- package/lib/module/layout/ResizeHandle.js +6 -5
- package/lib/module/layout/ResizeHandle.js.map +1 -1
- package/lib/module/link-preview/LinkPreviewCard.js +24 -26
- package/lib/module/link-preview/LinkPreviewCard.js.map +1 -1
- package/lib/module/list/ListBase.js +3 -3
- package/lib/module/list/ListBase.js.map +1 -1
- package/lib/module/list/ListPerson.js +3 -3
- package/lib/module/list/ListPerson.js.map +1 -1
- package/lib/module/listing-editor/ListingPreviewPane.js +30 -30
- package/lib/module/listing-editor/ListingPreviewPane.js.map +1 -1
- package/lib/module/markdown/InlineMarkdown.js +9 -11
- package/lib/module/markdown/InlineMarkdown.js.map +1 -1
- package/lib/module/markdown/MarkdownBlocks.js +35 -43
- package/lib/module/markdown/MarkdownBlocks.js.map +1 -1
- package/lib/module/multi-agent-chat/MultiAgentChatBase.js +6 -9
- package/lib/module/multi-agent-chat/MultiAgentChatBase.js.map +1 -1
- package/lib/module/multi-agent-chat/SelectedAgentPreview.js +9 -11
- package/lib/module/multi-agent-chat/SelectedAgentPreview.js.map +1 -1
- package/lib/module/notifications/NotificationPermissionSheet.js +3 -5
- package/lib/module/notifications/NotificationPermissionSheet.js.map +1 -1
- package/lib/module/notifications/NotificationsScreen.js +21 -27
- package/lib/module/notifications/NotificationsScreen.js.map +1 -1
- package/lib/module/overlay/OverlayInertBoundary.js +33 -12
- package/lib/module/overlay/OverlayInertBoundary.js.map +1 -1
- package/lib/module/page-header/PageHeaderTitleInput.js +20 -20
- package/lib/module/page-header/PageHeaderTitleInput.js.map +1 -1
- package/lib/module/panel-routing/expo-router/StackScene.js +42 -24
- package/lib/module/panel-routing/expo-router/StackScene.js.map +1 -1
- package/lib/module/phone-input/CountryCodeSelect.js +4 -4
- package/lib/module/phone-input/CountryCodeSelect.js.map +1 -1
- package/lib/module/project-board/MemberAvatars.js +7 -9
- package/lib/module/project-board/MemberAvatars.js.map +1 -1
- package/lib/module/project-board/ProjectBoardBase.js +4 -7
- package/lib/module/project-board/ProjectBoardBase.js.map +1 -1
- package/lib/module/project-board/ProjectBoardCanvas.js +2 -2
- package/lib/module/project-board/ProjectBoardCanvas.js.map +1 -1
- package/lib/module/project-board/styles.js +3 -6
- package/lib/module/project-board/styles.js.map +1 -1
- package/lib/module/radio/RadioSwatch.js +5 -5
- package/lib/module/radio/RadioSwatch.js.map +1 -1
- package/lib/module/rating/Rating.js +7 -7
- package/lib/module/rating/Rating.js.map +1 -1
- package/lib/module/rating/RatingBar.js +8 -8
- package/lib/module/rating/RatingBar.js.map +1 -1
- package/lib/module/rating/RatingBar.web.js +5 -5
- package/lib/module/rating/RatingBar.web.js.map +1 -1
- package/lib/module/rating/RatingInput.js +9 -9
- package/lib/module/rating/RatingInput.js.map +1 -1
- package/lib/module/rating/RatingSummary.js +6 -6
- package/lib/module/rating/RatingSummary.js.map +1 -1
- package/lib/module/row-actions/RowActions.js +5 -5
- package/lib/module/row-actions/RowActions.js.map +1 -1
- package/lib/module/select/Select.js +5 -5
- package/lib/module/select/Select.js.map +1 -1
- package/lib/module/skeleton/Skeleton.js +22 -30
- package/lib/module/skeleton/Skeleton.js.map +1 -1
- package/lib/module/stay-filters/AvailabilityFilter.js +3 -3
- package/lib/module/stay-filters/AvailabilityFilter.js.map +1 -1
- package/lib/module/stay-filters/CountFilter.js +3 -3
- package/lib/module/stay-filters/CountFilter.js.map +1 -1
- package/lib/module/stay-filters/FilterFooter.js +7 -7
- package/lib/module/stay-filters/FilterFooter.js.map +1 -1
- package/lib/module/stay-filters/FilterSection.js +12 -12
- package/lib/module/stay-filters/FilterSection.js.map +1 -1
- package/lib/module/stay-filters/SwitchFilterRow.js +9 -9
- package/lib/module/stay-filters/SwitchFilterRow.js.map +1 -1
- package/lib/module/stay-search/GuestPicker.js +5 -5
- package/lib/module/stay-search/GuestPicker.js.map +1 -1
- package/lib/module/stepper/Stepper.js +11 -10
- package/lib/module/stepper/Stepper.js.map +1 -1
- package/lib/module/stepper/StepperRow.js +12 -12
- package/lib/module/stepper/StepperRow.js.map +1 -1
- package/lib/module/subscription-plans/SubscriptionPlans.js +10 -10
- package/lib/module/subscription-plans/SubscriptionPlans.js.map +1 -1
- package/lib/module/subscription-plans/SubscriptionPrice.js +5 -5
- package/lib/module/subscription-plans/SubscriptionPrice.js.map +1 -1
- package/lib/module/task-list/TaskList.js +14 -15
- package/lib/module/task-list/TaskList.js.map +1 -1
- package/lib/module/theme/BloomThemeProvider.js +208 -224
- package/lib/module/theme/BloomThemeProvider.js.map +1 -1
- package/lib/module/theme/build-theme-from-seed.js +1 -1
- package/lib/module/theme/build-theme.js +38 -9
- package/lib/module/theme/build-theme.js.map +1 -1
- package/lib/module/theme/canonical-tokens.js +36 -0
- package/lib/module/theme/canonical-tokens.js.map +1 -0
- package/lib/module/theme/color-policy.js +3 -0
- package/lib/module/theme/color-policy.js.map +1 -1
- package/lib/module/theme/color-scope/resolve-scope.js +46 -5
- package/lib/module/theme/color-scope/resolve-scope.js.map +1 -1
- package/lib/module/theme/color-scope/use-scope.js +2 -6
- package/lib/module/theme/color-scope/use-scope.js.map +1 -1
- package/lib/module/theme/color-tokens.js +30 -8
- package/lib/module/theme/color-tokens.js.map +1 -1
- package/lib/module/theme/color-utils.js +4 -0
- package/lib/module/theme/color-utils.js.map +1 -1
- package/lib/module/theme/default-token-vars.js +88 -0
- package/lib/module/theme/default-token-vars.js.map +1 -0
- package/lib/module/theme/index.js +1 -1
- package/lib/module/theme/index.js.map +1 -1
- package/lib/module/theme/index.web.js +1 -1
- package/lib/module/theme/index.web.js.map +1 -1
- package/lib/module/theme/prepaint-palettes.js +2 -6
- package/lib/module/theme/prepaint-palettes.js.map +1 -1
- package/lib/module/theme/token-registry.js +1 -27
- package/lib/module/theme/token-registry.js.map +1 -1
- package/lib/module/theme/use-theme-paint.js +30 -3
- package/lib/module/theme/use-theme-paint.js.map +1 -1
- package/lib/module/typography/Typography.js +27 -27
- package/lib/module/typography/Typography.js.map +1 -1
- package/lib/module/web-search/WebSearch.js +18 -19
- package/lib/module/web-search/WebSearch.js.map +1 -1
- package/lib/module/wizard/WizardFooterBase.js +10 -10
- package/lib/module/wizard/WizardFooterBase.js.map +1 -1
- package/lib/module/wizard/WizardProgress.js +5 -5
- package/lib/module/wizard/WizardProgress.js.map +1 -1
- package/lib/typescript/commonjs/agent-creator/AgentCreatorSection.d.ts.map +1 -1
- package/lib/typescript/commonjs/agent-log/AgentLog.d.ts.map +1 -1
- package/lib/typescript/commonjs/agent-reply/AgentProfile.d.ts.map +1 -1
- package/lib/typescript/commonjs/agent-thinking/AgentThinking.d.ts.map +1 -1
- package/lib/typescript/commonjs/app-shell/AppShellEngine.d.ts.map +1 -1
- package/lib/typescript/commonjs/dialog/DialogContent.d.ts.map +1 -1
- package/lib/typescript/commonjs/dialog/DialogHeader.d.ts.map +1 -1
- package/lib/typescript/commonjs/dialog/SheetShell.d.ts.map +1 -1
- package/lib/typescript/commonjs/floating/lens/lens-cover.d.ts +15 -0
- package/lib/typescript/commonjs/floating/lens/lens-cover.d.ts.map +1 -0
- package/lib/typescript/commonjs/floating/lens/native-lens.d.ts +6 -0
- package/lib/typescript/commonjs/floating/lens/native-lens.d.ts.map +1 -1
- package/lib/typescript/commonjs/grouped-section/GroupedSection.d.ts.map +1 -1
- package/lib/typescript/commonjs/layout/ResizeHandle.d.ts.map +1 -1
- package/lib/typescript/commonjs/list/ListBase.d.ts.map +1 -1
- package/lib/typescript/commonjs/multi-agent-chat/MultiAgentChatBase.d.ts.map +1 -1
- package/lib/typescript/commonjs/overlay/OverlayInertBoundary.d.ts.map +1 -1
- package/lib/typescript/commonjs/panel-routing/expo-router/StackScene.d.ts +3 -1
- package/lib/typescript/commonjs/panel-routing/expo-router/StackScene.d.ts.map +1 -1
- package/lib/typescript/commonjs/project-board/ProjectBoardBase.d.ts.map +1 -1
- package/lib/typescript/commonjs/project-board/styles.d.ts.map +1 -1
- package/lib/typescript/commonjs/stay-search/GuestPicker.d.ts.map +1 -1
- package/lib/typescript/commonjs/stepper/Stepper.d.ts.map +1 -1
- package/lib/typescript/commonjs/task-list/TaskList.d.ts +3 -3
- package/lib/typescript/commonjs/task-list/TaskList.d.ts.map +1 -1
- package/lib/typescript/commonjs/theme/BloomThemeProvider.d.ts.map +1 -1
- package/lib/typescript/commonjs/theme/build-theme.d.ts +9 -0
- package/lib/typescript/commonjs/theme/build-theme.d.ts.map +1 -1
- package/lib/typescript/commonjs/theme/canonical-tokens.d.ts +20 -0
- package/lib/typescript/commonjs/theme/canonical-tokens.d.ts.map +1 -0
- package/lib/typescript/commonjs/theme/color-policy.d.ts.map +1 -1
- package/lib/typescript/commonjs/theme/color-scope/resolve-scope.d.ts +58 -0
- package/lib/typescript/commonjs/theme/color-scope/resolve-scope.d.ts.map +1 -1
- package/lib/typescript/commonjs/theme/color-scope/use-scope.d.ts.map +1 -1
- package/lib/typescript/commonjs/theme/color-tokens.d.ts +5 -2
- package/lib/typescript/commonjs/theme/color-tokens.d.ts.map +1 -1
- package/lib/typescript/commonjs/theme/color-utils.d.ts +3 -0
- package/lib/typescript/commonjs/theme/color-utils.d.ts.map +1 -1
- package/lib/typescript/commonjs/theme/default-token-vars.d.ts +11 -0
- package/lib/typescript/commonjs/theme/default-token-vars.d.ts.map +1 -0
- package/lib/typescript/commonjs/theme/index.d.ts +1 -1
- package/lib/typescript/commonjs/theme/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/theme/index.web.d.ts +1 -1
- package/lib/typescript/commonjs/theme/index.web.d.ts.map +1 -1
- package/lib/typescript/commonjs/theme/prepaint-palettes.d.ts.map +1 -1
- package/lib/typescript/commonjs/theme/token-registry.d.ts +1 -16
- package/lib/typescript/commonjs/theme/token-registry.d.ts.map +1 -1
- package/lib/typescript/commonjs/theme/use-theme-paint.d.ts +11 -0
- package/lib/typescript/commonjs/theme/use-theme-paint.d.ts.map +1 -1
- package/lib/typescript/commonjs/web-search/WebSearch.d.ts +3 -3
- package/lib/typescript/commonjs/web-search/WebSearch.d.ts.map +1 -1
- package/lib/typescript/module/agent-creator/AgentCreatorSection.d.ts.map +1 -1
- package/lib/typescript/module/agent-log/AgentLog.d.ts.map +1 -1
- package/lib/typescript/module/agent-reply/AgentProfile.d.ts.map +1 -1
- package/lib/typescript/module/agent-thinking/AgentThinking.d.ts.map +1 -1
- package/lib/typescript/module/app-shell/AppShellEngine.d.ts.map +1 -1
- package/lib/typescript/module/dialog/DialogContent.d.ts.map +1 -1
- package/lib/typescript/module/dialog/DialogHeader.d.ts.map +1 -1
- package/lib/typescript/module/dialog/SheetShell.d.ts.map +1 -1
- package/lib/typescript/module/floating/lens/lens-cover.d.ts +15 -0
- package/lib/typescript/module/floating/lens/lens-cover.d.ts.map +1 -0
- package/lib/typescript/module/floating/lens/native-lens.d.ts +6 -0
- package/lib/typescript/module/floating/lens/native-lens.d.ts.map +1 -1
- package/lib/typescript/module/grouped-section/GroupedSection.d.ts.map +1 -1
- package/lib/typescript/module/layout/ResizeHandle.d.ts.map +1 -1
- package/lib/typescript/module/list/ListBase.d.ts.map +1 -1
- package/lib/typescript/module/multi-agent-chat/MultiAgentChatBase.d.ts.map +1 -1
- package/lib/typescript/module/overlay/OverlayInertBoundary.d.ts.map +1 -1
- package/lib/typescript/module/panel-routing/expo-router/StackScene.d.ts +3 -1
- package/lib/typescript/module/panel-routing/expo-router/StackScene.d.ts.map +1 -1
- package/lib/typescript/module/project-board/ProjectBoardBase.d.ts.map +1 -1
- package/lib/typescript/module/project-board/styles.d.ts.map +1 -1
- package/lib/typescript/module/stay-search/GuestPicker.d.ts.map +1 -1
- package/lib/typescript/module/stepper/Stepper.d.ts.map +1 -1
- package/lib/typescript/module/task-list/TaskList.d.ts +3 -3
- package/lib/typescript/module/task-list/TaskList.d.ts.map +1 -1
- package/lib/typescript/module/theme/BloomThemeProvider.d.ts.map +1 -1
- package/lib/typescript/module/theme/build-theme.d.ts +9 -0
- package/lib/typescript/module/theme/build-theme.d.ts.map +1 -1
- package/lib/typescript/module/theme/canonical-tokens.d.ts +20 -0
- package/lib/typescript/module/theme/canonical-tokens.d.ts.map +1 -0
- package/lib/typescript/module/theme/color-policy.d.ts.map +1 -1
- package/lib/typescript/module/theme/color-scope/resolve-scope.d.ts +58 -0
- package/lib/typescript/module/theme/color-scope/resolve-scope.d.ts.map +1 -1
- package/lib/typescript/module/theme/color-scope/use-scope.d.ts.map +1 -1
- package/lib/typescript/module/theme/color-tokens.d.ts +5 -2
- package/lib/typescript/module/theme/color-tokens.d.ts.map +1 -1
- package/lib/typescript/module/theme/color-utils.d.ts +3 -0
- package/lib/typescript/module/theme/color-utils.d.ts.map +1 -1
- package/lib/typescript/module/theme/default-token-vars.d.ts +11 -0
- package/lib/typescript/module/theme/default-token-vars.d.ts.map +1 -0
- package/lib/typescript/module/theme/index.d.ts +1 -1
- package/lib/typescript/module/theme/index.d.ts.map +1 -1
- package/lib/typescript/module/theme/index.web.d.ts +1 -1
- package/lib/typescript/module/theme/index.web.d.ts.map +1 -1
- package/lib/typescript/module/theme/prepaint-palettes.d.ts.map +1 -1
- package/lib/typescript/module/theme/token-registry.d.ts +1 -16
- package/lib/typescript/module/theme/token-registry.d.ts.map +1 -1
- package/lib/typescript/module/theme/use-theme-paint.d.ts +11 -0
- package/lib/typescript/module/theme/use-theme-paint.d.ts.map +1 -1
- package/lib/typescript/module/web-search/WebSearch.d.ts +3 -3
- package/lib/typescript/module/web-search/WebSearch.d.ts.map +1 -1
- package/package.json +2 -1
- package/src/accordion/Accordion.tsx +6 -6
- package/src/accordion/Accordion.web.tsx +6 -6
- package/src/agent-creator/AgentCreatorSection.tsx +4 -6
- package/src/agent-creator/EmotionPicker.tsx +3 -3
- package/src/agent-log/AgentLog.tsx +8 -21
- package/src/agent-reply/AgentProfile.tsx +4 -5
- package/src/agent-thinking/AgentThinking.tsx +4 -3
- package/src/agent-thinking/ThinkingReasoning.tsx +4 -4
- package/src/app-shell/AppShell.tsx +3 -3
- package/src/app-shell/AppShellEngine.tsx +67 -19
- package/src/app-shell/AppShellPanelLayout.tsx +3 -3
- package/src/app-shell/NotificationBell.tsx +6 -6
- package/src/app-shell/PanelReorderHandle.tsx +4 -4
- package/src/avatar-group/AvatarGroupBase.tsx +6 -6
- package/src/chat-list/ChatSearchResultsBase.tsx +4 -4
- package/src/choice-list/ChoiceList.tsx +3 -3
- package/src/color-swatch-picker/ColorSwatchPicker.tsx +4 -4
- package/src/connection-dots/ConnectionDots.tsx +4 -4
- package/src/connection-dots/ConnectionDots.web.tsx +4 -4
- package/src/cover-header/CoverHeader.tsx +3 -3
- package/src/data-table/DataTableSelect.tsx +4 -4
- package/src/design-tokens/theme.css +1 -0
- package/src/design-tokens/tokens.json +390 -0
- package/src/dialog/DialogContent.tsx +3 -2
- package/src/dialog/DialogHeader.tsx +6 -5
- package/src/dialog/SheetShell.tsx +3 -2
- package/src/expandable-text/ExpandableText.tsx +3 -3
- package/src/floating/lens/lens-cover.tsx +29 -0
- package/src/floating/lens/native-lens.ts +2 -0
- package/src/grouped-section/GroupedSection.tsx +7 -6
- package/src/home-search/BudgetPicker.tsx +4 -4
- package/src/home-search/MoveInPicker.tsx +3 -3
- package/src/icon-circle/IconCircle.tsx +5 -5
- package/src/icons/shared.tsx +3 -3
- package/src/kbd/Kbd.tsx +4 -4
- package/src/layout/ResizeHandle.tsx +7 -5
- package/src/link-preview/LinkPreviewCard.tsx +7 -7
- package/src/list/ListBase.tsx +3 -6
- package/src/list/ListPerson.tsx +3 -3
- package/src/listing-editor/ListingPreviewPane.tsx +13 -13
- package/src/markdown/InlineMarkdown.tsx +3 -3
- package/src/markdown/MarkdownBlocks.tsx +14 -14
- package/src/multi-agent-chat/MultiAgentChatBase.tsx +6 -9
- package/src/multi-agent-chat/SelectedAgentPreview.tsx +4 -4
- package/src/notifications/NotificationPermissionSheet.tsx +3 -3
- package/src/notifications/NotificationsScreen.tsx +9 -9
- package/src/overlay/OverlayInertBoundary.tsx +10 -1
- package/src/page-header/PageHeaderTitleInput.tsx +4 -4
- package/src/panel-routing/expo-router/StackScene.tsx +7 -2
- package/src/phone-input/CountryCodeSelect.tsx +4 -4
- package/src/project-board/MemberAvatars.tsx +3 -3
- package/src/project-board/ProjectBoardBase.tsx +4 -5
- package/src/project-board/ProjectBoardCanvas.tsx +2 -2
- package/src/project-board/styles.ts +3 -4
- package/src/radio/RadioSwatch.tsx +3 -3
- package/src/rating/Rating.tsx +5 -5
- package/src/rating/RatingBar.tsx +4 -4
- package/src/rating/RatingBar.web.tsx +3 -3
- package/src/rating/RatingInput.tsx +5 -5
- package/src/rating/RatingSummary.tsx +4 -4
- package/src/row-actions/RowActions.tsx +3 -3
- package/src/select/Select.tsx +3 -3
- package/src/skeleton/Skeleton.tsx +9 -9
- package/src/stay-filters/AvailabilityFilter.tsx +3 -3
- package/src/stay-filters/CountFilter.tsx +3 -3
- package/src/stay-filters/FilterFooter.tsx +4 -4
- package/src/stay-filters/FilterSection.tsx +5 -5
- package/src/stay-filters/SwitchFilterRow.tsx +4 -4
- package/src/stay-search/GuestPicker.tsx +3 -6
- package/src/stepper/Stepper.tsx +6 -5
- package/src/stepper/StepperRow.tsx +5 -5
- package/src/subscription-plans/SubscriptionPlans.tsx +6 -6
- package/src/subscription-plans/SubscriptionPrice.tsx +3 -3
- package/src/task-list/TaskList.tsx +14 -16
- package/src/theme/BloomThemeProvider.tsx +33 -33
- package/src/theme/__tests__/__fixtures__/golden-resolved-tokens.json +134 -0
- package/src/theme/build-theme-from-seed.ts +1 -1
- package/src/theme/build-theme.ts +52 -11
- package/src/theme/canonical-tokens.ts +108 -0
- package/src/theme/color-policy.ts +3 -0
- package/src/theme/color-scope/resolve-scope.ts +47 -8
- package/src/theme/color-scope/use-scope.ts +2 -6
- package/src/theme/color-tokens.ts +7 -7
- package/src/theme/color-utils.ts +4 -0
- package/src/theme/default-token-vars.ts +86 -0
- package/src/theme/index.ts +1 -1
- package/src/theme/index.web.ts +1 -1
- package/src/theme/prepaint-palettes.ts +2 -3
- package/src/theme/token-registry.ts +1 -101
- package/src/theme/use-theme-paint.ts +26 -3
- package/src/typography/Typography.tsx +12 -12
- package/src/web-search/WebSearch.tsx +16 -18
- package/src/wizard/WizardFooterBase.tsx +5 -5
- package/src/wizard/WizardProgress.tsx +5 -5
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import type
|
|
2
|
+
import { type ColorTokens } from '../theme/color-tokens.js';
|
|
3
3
|
import type { WebSearchProps } from './types.js';
|
|
4
4
|
/**
|
|
5
5
|
* Web Search: what the agent looked at, as it looks.
|
|
@@ -42,8 +42,8 @@ export interface WebSearchPalette {
|
|
|
42
42
|
ring: string;
|
|
43
43
|
accent: string;
|
|
44
44
|
}
|
|
45
|
-
/**
|
|
46
|
-
export declare function resolveWebSearchPalette(
|
|
45
|
+
/** The colour tokens it paints: surfaces, foregrounds and focus roles. */
|
|
46
|
+
export declare function resolveWebSearchPalette(t: ColorTokens): WebSearchPalette;
|
|
47
47
|
declare function WebSearchComponent({ steps, run, stepInterval, startDelay, revealed: controlledRevealed, working: workingProp, onComplete, reduce: reduceProp, labels, style, testID, }: WebSearchProps): React.JSX.Element;
|
|
48
48
|
export declare const WebSearch: React.MemoExoticComponent<typeof WebSearchComponent>;
|
|
49
49
|
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"WebSearch.d.ts","sourceRoot":"","sources":["../../../../src/web-search/WebSearch.tsx"],"names":[],"mappings":"AAAA,OAAO,KAUN,MAAM,OAAO,CAAC;AAwCf,OAAO,
|
|
1
|
+
{"version":3,"file":"WebSearch.d.ts","sourceRoot":"","sources":["../../../../src/web-search/WebSearch.tsx"],"names":[],"mappings":"AAAA,OAAO,KAUN,MAAM,OAAO,CAAC;AAwCf,OAAO,EAAE,KAAK,WAAW,EAAkB,MAAM,0BAAuB,CAAC;AAIzE,OAAO,KAAK,EAAkB,cAAc,EAAkC,MAAM,YAAS,CAAC;AAI9F;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2BG;AAMH,MAAM,WAAW,gBAAgB;IAC/B,WAAW,EAAE,MAAM,CAAC;IACpB,aAAa,EAAE,MAAM,CAAC;IACtB,YAAY,EAAE,MAAM,CAAC;IACrB,aAAa,EAAE,MAAM,CAAC;IACtB,cAAc,EAAE,MAAM,CAAC;IACvB,UAAU,EAAE,MAAM,CAAC;IACnB,WAAW,EAAE,MAAM,CAAC;IACpB,OAAO,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,MAAM,CAAC;IACjB,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,MAAM,CAAC;CAChB;AAED,0EAA0E;AAC1E,wBAAgB,uBAAuB,CAAC,CAAC,EAAE,WAAW,GAAG,gBAAgB,CAcxE;AA2zBD,iBAAS,kBAAkB,CAAC,EAC1B,KAAK,EACL,GAAU,EACV,YAAkB,EAClB,UAAgB,EAChB,QAAQ,EAAE,kBAAkB,EAC5B,OAAO,EAAE,WAAW,EACpB,UAAU,EACV,MAAM,EAAE,UAAU,EAClB,MAAM,EACN,KAAK,EACL,MAAM,GACP,EAAE,cAAc,qBAuIhB;AAED,eAAO,MAAM,SAAS,sDAA2B,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@oxy.so/bloom",
|
|
3
|
-
"version": "23.
|
|
3
|
+
"version": "23.9.0",
|
|
4
4
|
"packageManager": "bun@1.4.3",
|
|
5
5
|
"description": "Bloom UI — Oxy ecosystem component library for React Native + Expo + Web",
|
|
6
6
|
"main": "lib/commonjs/index.js",
|
|
@@ -4196,6 +4196,7 @@
|
|
|
4196
4196
|
"generate:theme-css": "bun scripts/generate-theme-css.ts",
|
|
4197
4197
|
"generate:theme-golden": "bun scripts/generate-theme-golden.ts",
|
|
4198
4198
|
"generate:preset-accent-hues": "bun scripts/generate-preset-accent-hues.ts",
|
|
4199
|
+
"generate:default-token-vars": "bun scripts/generate-default-token-vars.ts",
|
|
4199
4200
|
"generate:tokens-json": "bun scripts/generate-design-tokens-json.ts",
|
|
4200
4201
|
"generate:adoption-matrix": "bun scripts/generate-adoption-matrix.ts",
|
|
4201
4202
|
"prebuild": "node scripts/generate-platform-exports.mjs && bun scripts/generate-theme-css.ts && bun scripts/generate-design-tokens-json.ts && node scripts/generate-task-catalog.mjs",
|
|
@@ -6,7 +6,7 @@ import { memo, useCallback, useContext } from 'react';
|
|
|
6
6
|
import { View, Pressable, Animated, StyleSheet, type TextStyle } from 'react-native';
|
|
7
7
|
|
|
8
8
|
import { RiArrowDownSLine as ChevronBottomIcon } from '../icons/remix/RiArrowDownSLine';
|
|
9
|
-
import {
|
|
9
|
+
import { useColorTokens } from '../theme/color-tokens';
|
|
10
10
|
import { useInteractionState } from '../hooks/use-interaction-state';
|
|
11
11
|
import { useTouchInput } from '../styles/pointer';
|
|
12
12
|
import { DISABLED_OPACITY, space } from '../styles/tokens';
|
|
@@ -56,7 +56,7 @@ const AccordionItemComponent: React.FC<AccordionItemProps> = ({
|
|
|
56
56
|
style,
|
|
57
57
|
}) => {
|
|
58
58
|
const itemContext = useAccordionItem(value, disabled);
|
|
59
|
-
const
|
|
59
|
+
const tokens = useColorTokens();
|
|
60
60
|
|
|
61
61
|
return (
|
|
62
62
|
<AccordionItemContext.Provider value={itemContext}>
|
|
@@ -64,7 +64,7 @@ const AccordionItemComponent: React.FC<AccordionItemProps> = ({
|
|
|
64
64
|
style={[
|
|
65
65
|
{
|
|
66
66
|
borderBottomWidth: 1,
|
|
67
|
-
borderBottomColor:
|
|
67
|
+
borderBottomColor: tokens.input,
|
|
68
68
|
},
|
|
69
69
|
style,
|
|
70
70
|
]}
|
|
@@ -91,7 +91,7 @@ const AccordionTriggerComponent: React.FC<AccordionTriggerProps> = ({
|
|
|
91
91
|
const { size } = useBloomAppearance({}, { size: 'md', tone: 'neutral' });
|
|
92
92
|
const geometry = resolveAccordionGeometry(size);
|
|
93
93
|
const touch = useTouchInput();
|
|
94
|
-
const
|
|
94
|
+
const tokens = useColorTokens();
|
|
95
95
|
const { toggle } = useContext(AccordionContext);
|
|
96
96
|
const { value, isExpanded, disabled, triggerId, contentId } = useContext(AccordionItemContext);
|
|
97
97
|
const rotateAnim = useAccordionMotion(isExpanded, 'trigger', SUPPORTS_NATIVE_DRIVER);
|
|
@@ -161,7 +161,7 @@ const AccordionTriggerComponent: React.FC<AccordionTriggerProps> = ({
|
|
|
161
161
|
<Text
|
|
162
162
|
style={[
|
|
163
163
|
TRIGGER_TEXT,
|
|
164
|
-
{ fontSize: geometry.fontSize, color:
|
|
164
|
+
{ fontSize: geometry.fontSize, color: tokens.foreground },
|
|
165
165
|
callerText,
|
|
166
166
|
textStyle,
|
|
167
167
|
]}
|
|
@@ -173,7 +173,7 @@ const AccordionTriggerComponent: React.FC<AccordionTriggerProps> = ({
|
|
|
173
173
|
)}
|
|
174
174
|
</View>
|
|
175
175
|
<Animated.View style={{ transform: [{ rotate: rotation }] }}>
|
|
176
|
-
<ChevronBottomIcon size={geometry.chevronSize} fill={
|
|
176
|
+
<ChevronBottomIcon size={geometry.chevronSize} fill={tokens.mutedForeground} />
|
|
177
177
|
</Animated.View>
|
|
178
178
|
</Pressable>
|
|
179
179
|
);
|
|
@@ -8,7 +8,7 @@ import { RiArrowDownSLine } from '../icons/remix/RiArrowDownSLine';
|
|
|
8
8
|
import { resolveNativeWebStyle } from '../styles/resolve-native-web-style';
|
|
9
9
|
import { useInteractiveWebCss } from '../styles/interactive-web-css';
|
|
10
10
|
import { useTouchInput } from '../styles/pointer';
|
|
11
|
-
import {
|
|
11
|
+
import { useColorTokens } from '../theme/color-tokens';
|
|
12
12
|
import { DISABLED_OPACITY, space } from '../styles/tokens';
|
|
13
13
|
import { useSurfacePresence } from '../surface/use-surface-presence';
|
|
14
14
|
import { AccordionContext, AccordionItemContext } from './context';
|
|
@@ -58,8 +58,8 @@ export const AccordionItem = memo(function AccordionItem({
|
|
|
58
58
|
}: AccordionItemProps) {
|
|
59
59
|
useStyles();
|
|
60
60
|
const state = useAccordionItem(value, disabled);
|
|
61
|
-
const
|
|
62
|
-
const vars = { '--bloom-accordion-border':
|
|
61
|
+
const tokens = useColorTokens();
|
|
62
|
+
const vars = { '--bloom-accordion-border': tokens.input } as React.CSSProperties;
|
|
63
63
|
return (
|
|
64
64
|
<AccordionItemContext.Provider value={state}>
|
|
65
65
|
<div className="bloom-accordion-item" style={{ ...vars, ...resolveNativeWebStyle(style) }}>
|
|
@@ -79,13 +79,13 @@ export const AccordionTrigger = memo(function AccordionTrigger({
|
|
|
79
79
|
const { size } = useBloomAppearance({}, { size: 'md', tone: 'neutral' });
|
|
80
80
|
const geometry = resolveAccordionGeometry(size);
|
|
81
81
|
const touch = useTouchInput();
|
|
82
|
-
const
|
|
82
|
+
const tokens = useColorTokens();
|
|
83
83
|
const { toggle } = useContext(AccordionContext);
|
|
84
84
|
const { value, isExpanded, disabled, triggerId, contentId } = useContext(AccordionItemContext);
|
|
85
85
|
const progress = useAccordionMotion(isExpanded, 'trigger', false);
|
|
86
86
|
const rotation = progress.interpolate({ inputRange: [0, 1], outputRange: ['0deg', '180deg'] });
|
|
87
87
|
const vars = {
|
|
88
|
-
'--bloom-accordion-text':
|
|
88
|
+
'--bloom-accordion-text': tokens.foreground,
|
|
89
89
|
'--bloom-accordion-font-size': `${geometry.fontSize}px`,
|
|
90
90
|
'--bloom-accordion-padding-y': `${geometry.paddingVertical}px`,
|
|
91
91
|
'--bloom-accordion-gap': `${geometry.gap}px`,
|
|
@@ -121,7 +121,7 @@ export const AccordionTrigger = memo(function AccordionTrigger({
|
|
|
121
121
|
{children}
|
|
122
122
|
</span>
|
|
123
123
|
<Animated.View aria-hidden style={{ transform: [{ rotate: rotation }] }}>
|
|
124
|
-
<RiArrowDownSLine size={geometry.chevronSize} fill={
|
|
124
|
+
<RiArrowDownSLine size={geometry.chevronSize} fill={tokens.mutedForeground} />
|
|
125
125
|
</Animated.View>
|
|
126
126
|
</button>
|
|
127
127
|
);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { ReactNode } from 'react';
|
|
2
2
|
import { StyleSheet, View } from 'react-native';
|
|
3
|
-
import {
|
|
3
|
+
import { useColorTokens } from '../theme/color-tokens';
|
|
4
4
|
import { Text } from '../typography';
|
|
5
5
|
import { AGENT_CREATOR_CARD } from './shared';
|
|
6
6
|
|
|
@@ -18,15 +18,13 @@ export interface AgentCreatorSectionProps {
|
|
|
18
18
|
* as `sections`.
|
|
19
19
|
*/
|
|
20
20
|
export function AgentCreatorSection({ title, children }: AgentCreatorSectionProps) {
|
|
21
|
-
const
|
|
21
|
+
const tokens = useColorTokens();
|
|
22
22
|
return (
|
|
23
23
|
<View style={styles.section}>
|
|
24
|
-
<Text variant="body-2-medium" style={[styles.title, { color:
|
|
24
|
+
<Text variant="body-2-medium" style={[styles.title, { color: tokens.mutedForeground }]}>
|
|
25
25
|
{title}
|
|
26
26
|
</Text>
|
|
27
|
-
<View style={[AGENT_CREATOR_CARD, { backgroundColor:
|
|
28
|
-
{children}
|
|
29
|
-
</View>
|
|
27
|
+
<View style={[AGENT_CREATOR_CARD, { backgroundColor: tokens.surface }]}>{children}</View>
|
|
30
28
|
</View>
|
|
31
29
|
);
|
|
32
30
|
}
|
|
@@ -15,7 +15,7 @@ import { CharacterAvatar } from '../agent-avatar/CharacterAvatar';
|
|
|
15
15
|
import { updateAvatarCharacter } from '../agent-avatar/character';
|
|
16
16
|
import { pointerEventsStyles } from '../styles/pointer-events';
|
|
17
17
|
import { ROUNDED_FULL } from '../styles/rounded-full';
|
|
18
|
-
import {
|
|
18
|
+
import { useColorTokens } from '../theme/color-tokens';
|
|
19
19
|
import { useAgentCreatorMessages } from './context';
|
|
20
20
|
import { AGENT_CREATOR_HOOKS, useAgentCreatorWebCss } from './web-css';
|
|
21
21
|
import { useTrackEvents } from './use-track-events';
|
|
@@ -59,7 +59,7 @@ function Emotion({
|
|
|
59
59
|
rotation: SharedValue<number>;
|
|
60
60
|
onChange: (id: string) => void;
|
|
61
61
|
}) {
|
|
62
|
-
const
|
|
62
|
+
const tokens = useColorTokens();
|
|
63
63
|
// The eyes alone, on a plain circle: the chip shows the eyes, not the body they sit in.
|
|
64
64
|
const eyeCharacter = useMemo(
|
|
65
65
|
() =>
|
|
@@ -105,7 +105,7 @@ function Emotion({
|
|
|
105
105
|
style={[
|
|
106
106
|
styles.chip,
|
|
107
107
|
CHIP_MOTION,
|
|
108
|
-
{ backgroundColor, borderColor: active ?
|
|
108
|
+
{ backgroundColor, borderColor: active ? tokens.mutedForeground : 'transparent' },
|
|
109
109
|
]}
|
|
110
110
|
>
|
|
111
111
|
<CharacterAvatar
|
|
@@ -20,8 +20,7 @@ import Animated, {
|
|
|
20
20
|
import { AgentThinking } from '../agent-thinking';
|
|
21
21
|
import { adoptStyleSheet } from '../styles/adopt-style-sheet';
|
|
22
22
|
import type { WebCssStyle } from '../styles/web-view-style';
|
|
23
|
-
import
|
|
24
|
-
import { useTheme } from '../theme/use-theme';
|
|
23
|
+
import { useColorTokens } from '../theme/color-tokens';
|
|
25
24
|
import {
|
|
26
25
|
AGENT_LOG_BRANCH,
|
|
27
26
|
AGENT_LOG_ROW_INDENT,
|
|
@@ -57,19 +56,6 @@ import { IS_WEB } from '../styles/platform';
|
|
|
57
56
|
* native shows the flat text-secondary it rests on under reduced motion.
|
|
58
57
|
*/
|
|
59
58
|
|
|
60
|
-
// ---------------------------------------------------------------------------
|
|
61
|
-
// Palette
|
|
62
|
-
// ---------------------------------------------------------------------------
|
|
63
|
-
|
|
64
|
-
/** Canonical theme surfaces, foregrounds and focus roles. */
|
|
65
|
-
function resolveLogPalette(theme: Theme) {
|
|
66
|
-
return {
|
|
67
|
-
guide: theme.colors.border,
|
|
68
|
-
textSecondary: theme.colors.textSecondary,
|
|
69
|
-
textPrimary: theme.colors.text,
|
|
70
|
-
};
|
|
71
|
-
}
|
|
72
|
-
|
|
73
59
|
// ---------------------------------------------------------------------------
|
|
74
60
|
// Reveal
|
|
75
61
|
// ---------------------------------------------------------------------------
|
|
@@ -211,10 +197,10 @@ function AgentLogRowConnectorComponent({
|
|
|
211
197
|
last,
|
|
212
198
|
reduce: reduceProp,
|
|
213
199
|
}: AgentLogRowConnectorProps) {
|
|
214
|
-
const
|
|
200
|
+
const tokens = useColorTokens();
|
|
215
201
|
const systemReduce = useAgentLogMotion();
|
|
216
202
|
const reduce = reduceProp ?? systemReduce;
|
|
217
|
-
const
|
|
203
|
+
const guide = tokens.border;
|
|
218
204
|
|
|
219
205
|
const [animate] = useState(!reduce);
|
|
220
206
|
const draw = useSharedValue(animate ? 0 : 1);
|
|
@@ -298,10 +284,10 @@ function AgentLogGuideBridgeComponent({
|
|
|
298
284
|
offset = 8,
|
|
299
285
|
reduce: reduceProp,
|
|
300
286
|
}: AgentLogGuideBridgeProps) {
|
|
301
|
-
const
|
|
287
|
+
const tokens = useColorTokens();
|
|
302
288
|
const systemReduce = useAgentLogMotion();
|
|
303
289
|
const reduce = reduceProp ?? systemReduce;
|
|
304
|
-
const
|
|
290
|
+
const guide = tokens.border;
|
|
305
291
|
|
|
306
292
|
const [animate] = useState(!reduce);
|
|
307
293
|
const scale = useSharedValue(animate ? 0 : 1);
|
|
@@ -431,8 +417,9 @@ type ShimmerStyle = TextStyle & {
|
|
|
431
417
|
* `<span>` inherits its paragraph's `text-body-regular`.
|
|
432
418
|
*/
|
|
433
419
|
function AgentLogShimmerTextComponent({ children, style }: AgentLogShimmerTextProps) {
|
|
434
|
-
const
|
|
435
|
-
const
|
|
420
|
+
const tokens = useColorTokens();
|
|
421
|
+
const textSecondary = tokens.mutedForeground;
|
|
422
|
+
const textPrimary = tokens.foreground;
|
|
436
423
|
|
|
437
424
|
useEffect(() => {
|
|
438
425
|
if (Platform.OS === 'web') adoptStyleSheet(STYLE_ID, WEB_CSS);
|
|
@@ -2,8 +2,7 @@ import { useState } from 'react';
|
|
|
2
2
|
import { Platform, Pressable, StyleSheet, View } from 'react-native';
|
|
3
3
|
import { AgentAvatar } from '../agent-avatar';
|
|
4
4
|
import { webDataSet } from '../styles/web-data';
|
|
5
|
-
import { createTokenStyles } from '../theme/color-tokens';
|
|
6
|
-
import { useTheme } from '../theme/use-theme';
|
|
5
|
+
import { createTokenStyles, useColorTokens } from '../theme/color-tokens';
|
|
7
6
|
import { Text } from '../typography';
|
|
8
7
|
import type { AgentProfileProps } from './types';
|
|
9
8
|
import { useAgentReplyWebCss } from './web-css';
|
|
@@ -60,7 +59,7 @@ export function AgentProfile({
|
|
|
60
59
|
avatarRef,
|
|
61
60
|
avatarHidden = false,
|
|
62
61
|
}: AgentProfileProps) {
|
|
63
|
-
const
|
|
62
|
+
const tokens = useColorTokens();
|
|
64
63
|
const themed = useStyles();
|
|
65
64
|
useAgentReplyWebCss();
|
|
66
65
|
const reduced = usePrefersReducedMotion();
|
|
@@ -130,9 +129,9 @@ export function AgentProfile({
|
|
|
130
129
|
style={[
|
|
131
130
|
styles.ring,
|
|
132
131
|
{
|
|
133
|
-
backgroundColor: hovered ?
|
|
132
|
+
backgroundColor: hovered ? tokens.popover : tokens.surface,
|
|
134
133
|
borderWidth: StyleSheet.hairlineWidth,
|
|
135
|
-
borderColor:
|
|
134
|
+
borderColor: tokens.border,
|
|
136
135
|
},
|
|
137
136
|
]}
|
|
138
137
|
/>
|
|
@@ -22,6 +22,7 @@ import { interactiveWebCss, useInteractiveWebCss } from '../styles/interactive-w
|
|
|
22
22
|
import { useRingOffsetStyle } from '../styles/surface-levels';
|
|
23
23
|
import { space } from '../styles/tokens';
|
|
24
24
|
import type { WebCssStyle } from '../styles/web-view-style';
|
|
25
|
+
import { useColorTokens } from '../theme/color-tokens';
|
|
25
26
|
import { withAlpha } from '../theme/color-utils';
|
|
26
27
|
import type { Theme } from '../theme/types';
|
|
27
28
|
import { useTheme } from '../theme/use-theme';
|
|
@@ -504,7 +505,7 @@ function ThinkingDisclosure({
|
|
|
504
505
|
testID,
|
|
505
506
|
...row
|
|
506
507
|
}: AgentThinkingProps) {
|
|
507
|
-
const
|
|
508
|
+
const tokens = useColorTokens();
|
|
508
509
|
const direction = useDirectionProps();
|
|
509
510
|
const ringOffset = useRingOffsetStyle();
|
|
510
511
|
useInteractiveWebCss(TOGGLE_STYLE_ID, TOGGLE_CSS);
|
|
@@ -539,7 +540,7 @@ function ThinkingDisclosure({
|
|
|
539
540
|
gap: 6,
|
|
540
541
|
alignSelf: 'flex-start',
|
|
541
542
|
borderRadius: 6,
|
|
542
|
-
'--bloom-agent-thinking-ring':
|
|
543
|
+
'--bloom-agent-thinking-ring': tokens.primary,
|
|
543
544
|
...ringOffset,
|
|
544
545
|
};
|
|
545
546
|
|
|
@@ -565,7 +566,7 @@ function ThinkingDisclosure({
|
|
|
565
566
|
<RiArrowDownSLine
|
|
566
567
|
width={16}
|
|
567
568
|
height={16}
|
|
568
|
-
fill={
|
|
569
|
+
fill={tokens.faintForeground}
|
|
569
570
|
style={{ transform: [{ rotate: open ? '180deg' : '0deg' }] }}
|
|
570
571
|
/>
|
|
571
572
|
</Pressable>
|
|
@@ -3,7 +3,7 @@ import { View } from 'react-native';
|
|
|
3
3
|
|
|
4
4
|
import { Collapsible } from '../collapsible';
|
|
5
5
|
import { space } from '../styles/tokens';
|
|
6
|
-
import {
|
|
6
|
+
import { useColorTokens } from '../theme/color-tokens';
|
|
7
7
|
import { Text } from '../typography';
|
|
8
8
|
|
|
9
9
|
const RULE_WIDTH = 2;
|
|
@@ -23,7 +23,7 @@ export function ThinkingReasoning({
|
|
|
23
23
|
children: ReactNode;
|
|
24
24
|
testID?: string;
|
|
25
25
|
}) {
|
|
26
|
-
const
|
|
26
|
+
const tokens = useColorTokens();
|
|
27
27
|
return (
|
|
28
28
|
<Collapsible open={open} testID={testID}>
|
|
29
29
|
<View
|
|
@@ -31,12 +31,12 @@ export function ThinkingReasoning({
|
|
|
31
31
|
marginStart: space.md,
|
|
32
32
|
paddingStart: space.md,
|
|
33
33
|
paddingVertical: space.xs,
|
|
34
|
-
borderStartColor:
|
|
34
|
+
borderStartColor: tokens.border,
|
|
35
35
|
borderStartWidth: RULE_WIDTH,
|
|
36
36
|
}}
|
|
37
37
|
>
|
|
38
38
|
{typeof children === 'string' ? (
|
|
39
|
-
<Text variant="body-2-regular" style={{ color:
|
|
39
|
+
<Text variant="body-2-regular" style={{ color: tokens.mutedForeground }}>
|
|
40
40
|
{children}
|
|
41
41
|
</Text>
|
|
42
42
|
) : (
|
|
@@ -9,7 +9,7 @@ import type { ScreenComponents } from '../screen/types';
|
|
|
9
9
|
import { SidebarSlot } from './SidebarSlot';
|
|
10
10
|
import { useAppShellSidebarMetrics } from './use-sidebar-metrics';
|
|
11
11
|
import { APP_SHELL_DEFAULTS } from './constants';
|
|
12
|
-
import {
|
|
12
|
+
import { useColorTokens } from '../theme/color-tokens';
|
|
13
13
|
import { PageHeader } from '../page-header/PageHeader';
|
|
14
14
|
import type { BottomBarProps } from '../bottom-bar/types';
|
|
15
15
|
import type { FabProps } from '../fab/types';
|
|
@@ -126,7 +126,7 @@ export function createAppShell(
|
|
|
126
126
|
const platformWindow = useWindow();
|
|
127
127
|
const appWindow = useWindowCornerTaken() ? null : platformWindow;
|
|
128
128
|
const actionClaimed = useScreenActionClaimed();
|
|
129
|
-
const
|
|
129
|
+
const tokens = useColorTokens();
|
|
130
130
|
const sidebarMetrics = useAppShellSidebarMetrics(sidebar);
|
|
131
131
|
const [userCollapsed, setUserCollapsed] = useState(sidebar?.defaultCollapsed ?? false);
|
|
132
132
|
const navigationPadding = APP_SHELL_DEFAULTS.dashboardGutter;
|
|
@@ -206,7 +206,7 @@ export function createAppShell(
|
|
|
206
206
|
onLayout={onRootLayout}
|
|
207
207
|
testID={testID}
|
|
208
208
|
style={[
|
|
209
|
-
{ flex: 1, minHeight: 0, flexDirection: 'row', backgroundColor:
|
|
209
|
+
{ flex: 1, minHeight: 0, flexDirection: 'row', backgroundColor: tokens.background },
|
|
210
210
|
style,
|
|
211
211
|
]}
|
|
212
212
|
>
|
|
@@ -15,6 +15,7 @@ import {
|
|
|
15
15
|
type ViewStyle,
|
|
16
16
|
} from 'react-native';
|
|
17
17
|
import Animated, {
|
|
18
|
+
executeOnUIRuntimeSync,
|
|
18
19
|
runOnJS,
|
|
19
20
|
useAnimatedStyle,
|
|
20
21
|
useDerivedValue,
|
|
@@ -552,12 +553,49 @@ export function createAppShellEngine() {
|
|
|
552
553
|
defaultValue: false,
|
|
553
554
|
onChange: onDrawerOpenChange,
|
|
554
555
|
});
|
|
556
|
+
const drawerAvailable = hasNav && !wide;
|
|
557
|
+
const isOpen = open && drawerAvailable;
|
|
558
|
+
// The drawer's open amount: `reveal` always animates it; the `overlay`
|
|
559
|
+
// drawer only under `drawerSwipe` (see "the drawer's open amount" below).
|
|
560
|
+
const reveal = useSharedValue(isOpen ? 1 : 0);
|
|
561
|
+
// A request to open or close a native `reveal` drawer moves it before React
|
|
562
|
+
// renders anything: the open amount starts toward its end on the UI thread
|
|
563
|
+
// in this call, and the state (the shell's re-render, the hit-testing and
|
|
564
|
+
// accessibility that follow it, the menu icon) follows while it moves. The
|
|
565
|
+
// effect that drives the open amount finds that motion already under way.
|
|
566
|
+
const revealRequested = useRef<number | null>(null);
|
|
567
|
+
// Bumped by every request a press moved and every settled swipe, so the
|
|
568
|
+
// effect re-reads the state asked for, and slides back when a controlled
|
|
569
|
+
// parent declined it.
|
|
570
|
+
const [openRequests, setOpenRequests] = useState(0);
|
|
571
|
+
const requestOpen = useCallback(
|
|
572
|
+
(next: boolean) => {
|
|
573
|
+
if (
|
|
574
|
+
drawerStyle === 'reveal' &&
|
|
575
|
+
drawerAvailable &&
|
|
576
|
+
Platform.OS !== 'web' &&
|
|
577
|
+
!reducedMotion &&
|
|
578
|
+
next !== isOpen
|
|
579
|
+
) {
|
|
580
|
+
const target = next ? 1 : 0;
|
|
581
|
+
revealRequested.current = target;
|
|
582
|
+
// Synchronously, so the motion is under way on the UI thread before
|
|
583
|
+
// the state's render can start: React may flush that render before
|
|
584
|
+
// an assignment's own trip to the UI thread (a microtask) leaves.
|
|
585
|
+
executeOnUIRuntimeSync((to: number) => {
|
|
586
|
+
'worklet';
|
|
587
|
+
reveal.value = withTiming(to, { duration: REVEAL_MS, easing: REVEAL_EASE });
|
|
588
|
+
})(target);
|
|
589
|
+
setOpenRequests((count) => count + 1);
|
|
590
|
+
}
|
|
591
|
+
setOpen(next);
|
|
592
|
+
},
|
|
593
|
+
[drawerStyle, drawerAvailable, reducedMotion, isOpen, reveal, setOpen],
|
|
594
|
+
);
|
|
555
595
|
// The drawer always opens the full panel, whatever the in-flow variant.
|
|
556
596
|
const drawerSidebar = sidebar
|
|
557
|
-
? { ...closingOnChoice(sidebar, () =>
|
|
597
|
+
? { ...closingOnChoice(sidebar, () => requestOpen(false)), variant: 'panel' as const }
|
|
558
598
|
: undefined;
|
|
559
|
-
const drawerAvailable = hasNav && !wide;
|
|
560
|
-
const isOpen = open && drawerAvailable;
|
|
561
599
|
// `drawerSwipe` is a native gesture: the web keeps its press-only drawer.
|
|
562
600
|
const swipeEnabled = drawerSwipe && hasNav && Platform.OS !== 'web';
|
|
563
601
|
const swipeOverlay = swipeEnabled && drawerStyle === 'overlay';
|
|
@@ -576,7 +614,7 @@ export function createAppShellEngine() {
|
|
|
576
614
|
|
|
577
615
|
const revealInteractionOpen = isOpen && drawerStyle === 'reveal';
|
|
578
616
|
const revealDrawerRef = usePanelInteraction(revealInteractionOpen, revealInteractionOpen, () =>
|
|
579
|
-
|
|
617
|
+
requestOpen(false),
|
|
580
618
|
);
|
|
581
619
|
|
|
582
620
|
const revealAvailable = drawerStyle === 'reveal' && drawerAvailable;
|
|
@@ -588,13 +626,13 @@ export function createAppShellEngine() {
|
|
|
588
626
|
drawerAvailable,
|
|
589
627
|
drawerDisplay: cssScope && hasNav ? 'var(--bloom-drawer-trigger-display, none)' : undefined,
|
|
590
628
|
drawerOpen: isOpen,
|
|
591
|
-
openDrawer: () =>
|
|
592
|
-
closeDrawer: () =>
|
|
593
|
-
toggleDrawer: () =>
|
|
629
|
+
openDrawer: () => requestOpen(true),
|
|
630
|
+
closeDrawer: () => requestOpen(false),
|
|
631
|
+
toggleDrawer: () => requestOpen(!isOpen),
|
|
594
632
|
navigationDock: navDock.state,
|
|
595
633
|
topBarDock: topDock.state,
|
|
596
634
|
}),
|
|
597
|
-
[drawerAvailable, isOpen,
|
|
635
|
+
[drawerAvailable, isOpen, requestOpen, cssScope, hasNav, navDock.state, topDock.state],
|
|
598
636
|
);
|
|
599
637
|
|
|
600
638
|
/**
|
|
@@ -1316,7 +1354,6 @@ export function createAppShellEngine() {
|
|
|
1316
1354
|
// `reveal` always animates it; the `overlay` drawer only under
|
|
1317
1355
|
// `drawerSwipe`, where a finger drives the same value (below) — without the
|
|
1318
1356
|
// swipe it mounts open and unmounts closed, exactly as it always has.
|
|
1319
|
-
const reveal = useSharedValue(isOpen ? 1 : 0);
|
|
1320
1357
|
// The `overlay` drawer's travel is its whole box sliding in from
|
|
1321
1358
|
// off-screen: the panel, 12 either side, and the device's side insets when
|
|
1322
1359
|
// the shell owns the safe area.
|
|
@@ -1338,11 +1375,12 @@ export function createAppShellEngine() {
|
|
|
1338
1375
|
setWasOpen(isOpen);
|
|
1339
1376
|
if (!isOpen) setOverlayHeld(true);
|
|
1340
1377
|
}
|
|
1341
|
-
// Bumped by every settled swipe, so the effect below re-reads the state the
|
|
1342
|
-
// swipe asked for — and slides back when a controlled parent declined it.
|
|
1343
|
-
const [swipeSettles, setSwipeSettles] = useState(0);
|
|
1344
1378
|
useEffect(() => {
|
|
1345
1379
|
const target = isOpen && (drawerStyle === 'reveal' || swipeOverlay) ? 1 : 0;
|
|
1380
|
+
// A request already moving the drawer there (`requestOpen`) is left to run.
|
|
1381
|
+
const requested = revealRequested.current;
|
|
1382
|
+
revealRequested.current = null;
|
|
1383
|
+
if (requested === target) return;
|
|
1346
1384
|
// The browser interpolates web frames; native keeps its UI-thread timing.
|
|
1347
1385
|
if (Platform.OS === 'web' || reducedMotion || (swipeOverlay && reveal.value === target)) {
|
|
1348
1386
|
reveal.value = target;
|
|
@@ -1359,11 +1397,11 @@ export function createAppShellEngine() {
|
|
|
1359
1397
|
}
|
|
1360
1398
|
: undefined,
|
|
1361
1399
|
);
|
|
1362
|
-
}, [isOpen, drawerStyle, swipeOverlay, reducedMotion, reveal,
|
|
1400
|
+
}, [isOpen, drawerStyle, swipeOverlay, reducedMotion, reveal, openRequests]);
|
|
1363
1401
|
const settleSwipe = useCallback(
|
|
1364
1402
|
(next: boolean) => {
|
|
1365
1403
|
if (next !== isOpen) setOpen(next);
|
|
1366
|
-
|
|
1404
|
+
setOpenRequests((count) => count + 1);
|
|
1367
1405
|
},
|
|
1368
1406
|
[isOpen, setOpen],
|
|
1369
1407
|
);
|
|
@@ -1793,7 +1831,7 @@ export function createAppShellEngine() {
|
|
|
1793
1831
|
};
|
|
1794
1832
|
const overlayPanel = drawerSidebar ? (
|
|
1795
1833
|
<View pointerEvents={isOpen ? 'auto' : 'none'} style={{ height: '100%' }}>
|
|
1796
|
-
<SidebarSlot {...drawerSidebar} mobile onClose={() =>
|
|
1834
|
+
<SidebarSlot {...drawerSidebar} mobile onClose={() => requestOpen(false)} />
|
|
1797
1835
|
</View>
|
|
1798
1836
|
) : null;
|
|
1799
1837
|
const overlayFrameProps = {
|
|
@@ -1803,7 +1841,7 @@ export function createAppShellEngine() {
|
|
|
1803
1841
|
const overlayDrawer = (
|
|
1804
1842
|
<>
|
|
1805
1843
|
<Backdrop
|
|
1806
|
-
onPress={() =>
|
|
1844
|
+
onPress={() => requestOpen(false)}
|
|
1807
1845
|
disabled={!isOpen}
|
|
1808
1846
|
progress={swipeOverlay ? reveal : undefined}
|
|
1809
1847
|
blurIntensity={0}
|
|
@@ -1929,15 +1967,20 @@ export function createAppShellEngine() {
|
|
|
1929
1967
|
]}
|
|
1930
1968
|
>
|
|
1931
1969
|
{drawerAvailable && drawerSidebar ? (
|
|
1970
|
+
// Laid out while closed, so opening changes no layout: the rail's
|
|
1971
|
+
// opacity is 0 at rest (nothing is drawn), and the open amount
|
|
1972
|
+
// moves only opacity and transforms. The host never flattens, so
|
|
1973
|
+
// its accessibility toggling moves no children.
|
|
1932
1974
|
<View
|
|
1933
1975
|
ref={revealDrawerRef}
|
|
1976
|
+
collapsable={false}
|
|
1934
1977
|
tabIndex={-1}
|
|
1935
1978
|
testID={testID ? `${testID}-navigation-drawer` : undefined}
|
|
1936
1979
|
aria-hidden={!isOpen}
|
|
1937
1980
|
accessibilityViewIsModal={isOpen}
|
|
1938
1981
|
// The page and its veil are hidden from VoiceOver while this is
|
|
1939
1982
|
// modal, so its escape gesture is the way out.
|
|
1940
|
-
onAccessibilityEscape={() =>
|
|
1983
|
+
onAccessibilityEscape={() => requestOpen(false)}
|
|
1941
1984
|
accessibilityElementsHidden={!isOpen}
|
|
1942
1985
|
importantForAccessibility={isOpen ? 'auto' : 'no-hide-descendants'}
|
|
1943
1986
|
{...(Platform.OS === 'web' && !isOpen ? { inert: true } : {})}
|
|
@@ -1958,6 +2001,7 @@ export function createAppShellEngine() {
|
|
|
1958
2001
|
}}
|
|
1959
2002
|
>
|
|
1960
2003
|
<Animated.View
|
|
2004
|
+
collapsable={false}
|
|
1961
2005
|
style={[
|
|
1962
2006
|
{
|
|
1963
2007
|
height: '100%',
|
|
@@ -1973,13 +2017,14 @@ export function createAppShellEngine() {
|
|
|
1973
2017
|
{...drawerSidebar}
|
|
1974
2018
|
mobile
|
|
1975
2019
|
surface="plain"
|
|
1976
|
-
onClose={() =>
|
|
2020
|
+
onClose={() => requestOpen(false)}
|
|
1977
2021
|
/>
|
|
1978
2022
|
)}
|
|
1979
2023
|
</Animated.View>
|
|
1980
2024
|
</View>
|
|
1981
2025
|
) : null}
|
|
1982
2026
|
<Animated.View
|
|
2027
|
+
collapsable={false}
|
|
1983
2028
|
testID={testID ? `${testID}-reveal-page` : undefined}
|
|
1984
2029
|
style={[
|
|
1985
2030
|
{
|
|
@@ -1999,6 +2044,7 @@ export function createAppShellEngine() {
|
|
|
1999
2044
|
]}
|
|
2000
2045
|
>
|
|
2001
2046
|
<View
|
|
2047
|
+
collapsable={false}
|
|
2002
2048
|
aria-hidden={isOpen}
|
|
2003
2049
|
accessibilityElementsHidden={isOpen}
|
|
2004
2050
|
importantForAccessibility={isOpen ? 'no-hide-descendants' : 'auto'}
|
|
@@ -2020,6 +2066,7 @@ export function createAppShellEngine() {
|
|
|
2020
2066
|
</View>
|
|
2021
2067
|
</View>
|
|
2022
2068
|
<Animated.View
|
|
2069
|
+
collapsable={false}
|
|
2023
2070
|
pointerEvents={isOpen ? 'auto' : 'none'}
|
|
2024
2071
|
style={[
|
|
2025
2072
|
{
|
|
@@ -2039,7 +2086,7 @@ export function createAppShellEngine() {
|
|
|
2039
2086
|
focusable={isOpen}
|
|
2040
2087
|
tabIndex={isOpen ? 0 : -1}
|
|
2041
2088
|
aria-hidden={!isOpen}
|
|
2042
|
-
onPress={() =>
|
|
2089
|
+
onPress={() => requestOpen(false)}
|
|
2043
2090
|
testID={testID ? `${testID}-veil` : undefined}
|
|
2044
2091
|
style={{
|
|
2045
2092
|
flex: 1,
|
|
@@ -2051,6 +2098,7 @@ export function createAppShellEngine() {
|
|
|
2051
2098
|
</Animated.View>
|
|
2052
2099
|
</Animated.View>
|
|
2053
2100
|
<Animated.View
|
|
2101
|
+
collapsable={false}
|
|
2054
2102
|
pointerEvents={isOpen ? 'none' : 'box-none'}
|
|
2055
2103
|
testID={testID ? `${testID}-reveal-bars` : undefined}
|
|
2056
2104
|
aria-hidden={isOpen}
|
|
@@ -52,7 +52,7 @@ import { useMeasuredSizeClass, useWindowSizeWhile } from '../hooks/use-width-cla
|
|
|
52
52
|
import { IS_WEB } from '../styles/platform';
|
|
53
53
|
import { surfacePresenceStyle, useSurfacePresenceContent } from '../surface/use-surface-presence';
|
|
54
54
|
import { useIsRtl } from '../hooks/use-is-rtl';
|
|
55
|
-
import {
|
|
55
|
+
import { useColorTokens } from '../theme/color-tokens';
|
|
56
56
|
import type { WebCssStyle } from '../styles/web-view-style';
|
|
57
57
|
import { webViewportHeightMinus, WEB_POSITION_STICKY } from '../styles/web-view-style';
|
|
58
58
|
import { useShellLayoutReady } from './use-shell-viewport';
|
|
@@ -483,7 +483,7 @@ export function createPanelLayoutView(
|
|
|
483
483
|
};
|
|
484
484
|
}, [dragLayer, dragOffset, vertical, restingZIndex]);
|
|
485
485
|
const region = useAppShellRegion();
|
|
486
|
-
const
|
|
486
|
+
const tokens = useColorTokens();
|
|
487
487
|
const rtl = useIsRtl();
|
|
488
488
|
// Only the web places a sticky panel from the viewport's height.
|
|
489
489
|
const viewportHeight = useWindowSizeWhile(
|
|
@@ -1008,7 +1008,7 @@ export function createPanelLayoutView(
|
|
|
1008
1008
|
: vertical
|
|
1009
1009
|
? { left: 0, right: 0, top: -track.gap, height: track.gap }
|
|
1010
1010
|
: { top: 0, bottom: 0, insetInlineStart: -track.gap, width: track.gap }),
|
|
1011
|
-
backgroundColor:
|
|
1011
|
+
backgroundColor: tokens.border,
|
|
1012
1012
|
} as WebCssStyle
|
|
1013
1013
|
}
|
|
1014
1014
|
/>
|