@trinityui/design-system 2.11.0 → 2.13.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/CHANGELOG.md +2209 -0
- package/CONTRIBUTING.md +180 -69
- package/LICENSE +21 -0
- package/MIGRATION.md +523 -21
- package/README.md +281 -120
- package/dist/IllustratedMessage.js +546 -1341
- package/dist/accessibility.d.ts +596 -18
- package/dist/accessibility.d.ts.map +1 -1
- package/dist/accessibility.js +458 -0
- package/dist/app-shell.js +17230 -9097
- package/dist/assets/index.d.ts +1 -1
- package/dist/charts.js +8507 -6059
- package/dist/color-contrast.d.ts +35 -0
- package/dist/color-contrast.d.ts.map +1 -0
- package/dist/commonjs-helpers.js +8 -0
- package/dist/component-color-references.d.ts +175 -0
- package/dist/component-color-references.d.ts.map +1 -0
- package/dist/components/AI/AIActions.d.ts +72 -12
- package/dist/components/AI/AIActions.d.ts.map +1 -1
- package/dist/components/AI/AIAvatar.d.ts +31 -3
- package/dist/components/AI/AIAvatar.d.ts.map +1 -1
- package/dist/components/AI/AIChainOfThought.d.ts +192 -72
- package/dist/components/AI/AIChainOfThought.d.ts.map +1 -1
- package/dist/components/AI/AIChainOfThought.types.d.ts +296 -34
- package/dist/components/AI/AIChainOfThought.types.d.ts.map +1 -1
- package/dist/components/AI/AIChainOfThought.utils.d.ts +25 -7
- package/dist/components/AI/AIChainOfThought.utils.d.ts.map +1 -1
- package/dist/components/AI/AIChat.d.ts +12 -0
- package/dist/components/AI/AIChat.d.ts.map +1 -1
- package/dist/components/AI/AIChatWelcome.d.ts +254 -0
- package/dist/components/AI/AIChatWelcome.d.ts.map +1 -0
- package/dist/components/AI/AIClarificationPrompt.d.ts +134 -0
- package/dist/components/AI/AIClarificationPrompt.d.ts.map +1 -0
- package/dist/components/AI/AIConfidenceBadge.d.ts +117 -0
- package/dist/components/AI/AIConfidenceBadge.d.ts.map +1 -0
- package/dist/components/AI/AIConfigContext.d.ts +100 -0
- package/dist/components/AI/AIConfigContext.d.ts.map +1 -0
- package/dist/components/AI/AIConfigProvider.d.ts +66 -0
- package/dist/components/AI/AIConfigProvider.d.ts.map +1 -0
- package/dist/components/AI/AIContainer.d.ts +80 -11
- package/dist/components/AI/AIContainer.d.ts.map +1 -1
- package/dist/components/AI/AIExplainability.d.ts +39 -5
- package/dist/components/AI/AIExplainability.d.ts.map +1 -1
- package/dist/components/AI/AIFeedbackControl.d.ts +113 -0
- package/dist/components/AI/AIFeedbackControl.d.ts.map +1 -0
- package/dist/components/AI/AIFeedbackForm.d.ts +117 -0
- package/dist/components/AI/AIFeedbackForm.d.ts.map +1 -0
- package/dist/components/AI/AIFeedbackHostContext.d.ts +16 -0
- package/dist/components/AI/AIFeedbackHostContext.d.ts.map +1 -0
- package/dist/components/AI/AILabel.d.ts +39 -6
- package/dist/components/AI/AILabel.d.ts.map +1 -1
- package/dist/components/AI/AIMessage.d.ts +337 -42
- package/dist/components/AI/AIMessage.d.ts.map +1 -1
- package/dist/components/AI/AIPlanReview.d.ts +194 -0
- package/dist/components/AI/AIPlanReview.d.ts.map +1 -0
- package/dist/components/AI/AIQueryDisclosure.d.ts +119 -0
- package/dist/components/AI/AIQueryDisclosure.d.ts.map +1 -0
- package/dist/components/AI/AIRelatedQuestions.d.ts +50 -11
- package/dist/components/AI/AIRelatedQuestions.d.ts.map +1 -1
- package/dist/components/AI/AIResponseRenderer.d.ts +133 -21
- package/dist/components/AI/AIResponseRenderer.d.ts.map +1 -1
- package/dist/components/AI/AIResponseSourcesContext.d.ts +83 -0
- package/dist/components/AI/AIResponseSourcesContext.d.ts.map +1 -0
- package/dist/components/AI/AIReviewItem.d.ts +142 -0
- package/dist/components/AI/AIReviewItem.d.ts.map +1 -0
- package/dist/components/AI/AISourceChip.d.ts +135 -0
- package/dist/components/AI/AISourceChip.d.ts.map +1 -0
- package/dist/components/AI/AISources.d.ts +91 -13
- package/dist/components/AI/AISources.d.ts.map +1 -1
- package/dist/components/AI/AISourcesPanel.d.ts +43 -7
- package/dist/components/AI/AISourcesPanel.d.ts.map +1 -1
- package/dist/components/AI/AITextBlock.d.ts +107 -17
- package/dist/components/AI/AITextBlock.d.ts.map +1 -1
- package/dist/components/AI/AITextBlock.parser.d.ts +153 -0
- package/dist/components/AI/AITextBlock.parser.d.ts.map +1 -0
- package/dist/components/AI/AIVerificationBadge.d.ts +94 -0
- package/dist/components/AI/AIVerificationBadge.d.ts.map +1 -0
- package/dist/components/AI/AIVisuals.d.ts +92 -23
- package/dist/components/AI/AIVisuals.d.ts.map +1 -1
- package/dist/components/AI/AIVoiceInput.d.ts +42 -11
- package/dist/components/AI/AIVoiceInput.d.ts.map +1 -1
- package/dist/components/AI/AIVoiceMode.d.ts +16 -2
- package/dist/components/AI/AIVoiceMode.d.ts.map +1 -1
- package/dist/components/AI/BlockErrorBoundary.d.ts +77 -0
- package/dist/components/AI/BlockErrorBoundary.d.ts.map +1 -0
- package/dist/components/AI/ChatHeader.d.ts +41 -4
- package/dist/components/AI/ChatHeader.d.ts.map +1 -1
- package/dist/components/AI/ChatHistoryList.d.ts +25 -12
- package/dist/components/AI/ChatHistoryList.d.ts.map +1 -1
- package/dist/components/AI/ChatThread.d.ts +263 -13
- package/dist/components/AI/ChatThread.d.ts.map +1 -1
- package/dist/components/AI/InThreadContext.d.ts +14 -0
- package/dist/components/AI/InThreadContext.d.ts.map +1 -0
- package/dist/components/AI/InsightEngine.d.ts +270 -46
- package/dist/components/AI/InsightEngine.d.ts.map +1 -1
- package/dist/components/AI/InsightEngineInput.d.ts +52 -5
- package/dist/components/AI/InsightEngineInput.d.ts.map +1 -1
- package/dist/components/AI/MessageActionButton.d.ts +72 -0
- package/dist/components/AI/MessageActionButton.d.ts.map +1 -0
- package/dist/components/AI/QueryInput.d.ts.map +1 -1
- package/dist/components/AI/UserAvatar.d.ts +50 -4
- package/dist/components/AI/UserAvatar.d.ts.map +1 -1
- package/dist/components/AI/UserMessage.d.ts +32 -3
- package/dist/components/AI/UserMessage.d.ts.map +1 -1
- package/dist/components/AI/blockRendererContext.d.ts +64 -0
- package/dist/components/AI/blockRendererContext.d.ts.map +1 -0
- package/dist/components/AI/hitlBlockRenderers.d.ts +48 -0
- package/dist/components/AI/hitlBlockRenderers.d.ts.map +1 -0
- package/dist/components/AI/index.d.ts +23 -6
- package/dist/components/AI/index.d.ts.map +1 -1
- package/dist/components/AI/moleculeBlockRenderers.d.ts +15 -0
- package/dist/components/AI/moleculeBlockRenderers.d.ts.map +1 -0
- package/dist/components/AI/planReviewBlockRenderer.d.ts +8 -0
- package/dist/components/AI/planReviewBlockRenderer.d.ts.map +1 -0
- package/dist/components/AI/strings/defaults.d.ts +31 -0
- package/dist/components/AI/strings/defaults.d.ts.map +1 -0
- package/dist/components/AI/tokens.d.ts +185 -20
- package/dist/components/AI/tokens.d.ts.map +1 -1
- package/dist/components/AI/types/hitl.d.ts +2294 -0
- package/dist/components/AI/types/hitl.d.ts.map +1 -0
- package/dist/components/AI/types/index.d.ts +2 -1
- package/dist/components/AI/types/index.d.ts.map +1 -1
- package/dist/components/AI/types/response.d.ts +428 -40
- package/dist/components/AI/types/response.d.ts.map +1 -1
- package/dist/components/AI/useBlockSources.d.ts +67 -0
- package/dist/components/AI/useBlockSources.d.ts.map +1 -0
- package/dist/components/AI/useBrowserVoiceMode.d.ts +31 -2
- package/dist/components/AI/useBrowserVoiceMode.d.ts.map +1 -1
- package/dist/components/AI/useWelcomeComposerHandoff.d.ts +30 -0
- package/dist/components/AI/useWelcomeComposerHandoff.d.ts.map +1 -0
- package/dist/components/AI/utils/alphaIndex.d.ts +19 -0
- package/dist/components/AI/utils/alphaIndex.d.ts.map +1 -0
- package/dist/components/AI/utils/blockReady.d.ts +54 -0
- package/dist/components/AI/utils/blockReady.d.ts.map +1 -0
- package/dist/components/AI/utils/blocks.d.ts +28 -0
- package/dist/components/AI/utils/blocks.d.ts.map +1 -0
- package/dist/components/AI/utils/confidence.d.ts +182 -0
- package/dist/components/AI/utils/confidence.d.ts.map +1 -0
- package/dist/components/AI/utils/filters.d.ts +31 -0
- package/dist/components/AI/utils/filters.d.ts.map +1 -0
- package/dist/components/AI/utils/responseText.d.ts +8 -0
- package/dist/components/AI/utils/responseText.d.ts.map +1 -0
- package/dist/components/AI/utils/sources.d.ts +110 -0
- package/dist/components/AI/utils/sources.d.ts.map +1 -0
- package/dist/components/AIDigestCard/AIDigestCard.d.ts.map +1 -1
- package/dist/components/AIDigestCard/types.d.ts +42 -5
- package/dist/components/AIDigestCard/types.d.ts.map +1 -1
- package/dist/components/AppLayout/AIFab.d.ts +33 -6
- package/dist/components/AppLayout/AIFab.d.ts.map +1 -1
- package/dist/components/AppLayout/AIFabLayout.deprecated.d.ts.map +1 -1
- package/dist/components/AppLayout/AppLayout.d.ts +135 -7
- package/dist/components/AppLayout/AppLayout.d.ts.map +1 -1
- package/dist/components/AppLayout/InsightEnginePanel.d.ts +315 -21
- package/dist/components/AppLayout/InsightEnginePanel.d.ts.map +1 -1
- package/dist/components/AppLayout/ResizablePanel.d.ts +145 -8
- package/dist/components/AppLayout/ResizablePanel.d.ts.map +1 -1
- package/dist/components/AppLayout/ThreadHistorySidebar.d.ts +6 -0
- package/dist/components/AppLayout/ThreadHistorySidebar.d.ts.map +1 -1
- package/dist/components/AppLayout/index.d.ts +3 -3
- package/dist/components/AppLayout/index.d.ts.map +1 -1
- package/dist/components/AppLayout/insightEnginePanel.demo.d.ts +32 -0
- package/dist/components/AppLayout/insightEnginePanel.demo.d.ts.map +1 -0
- package/dist/components/AppLayout/panelPropsPath.d.ts +26 -0
- package/dist/components/AppLayout/panelPropsPath.d.ts.map +1 -0
- package/dist/components/AppLayout/panelResizeTransition.d.ts +49 -0
- package/dist/components/AppLayout/panelResizeTransition.d.ts.map +1 -0
- package/dist/components/AppLayout/toChatThreadMessage.d.ts +40 -0
- package/dist/components/AppLayout/toChatThreadMessage.d.ts.map +1 -0
- package/dist/components/AssessmentDrawer/AssessmentDrawer.d.ts +5 -1
- package/dist/components/AssessmentDrawer/AssessmentDrawer.d.ts.map +1 -1
- package/dist/components/AuditDrawer/AuditDrawer.d.ts +4 -3
- package/dist/components/AuditDrawer/AuditDrawer.d.ts.map +1 -1
- package/dist/components/AuditDrawer/index.d.ts +1 -1
- package/dist/components/AuditDrawer/index.d.ts.map +1 -1
- package/dist/components/AuditDrawer/types.d.ts +39 -5
- package/dist/components/AuditDrawer/types.d.ts.map +1 -1
- package/dist/components/Autocomplete/Autocomplete.d.ts +6 -1
- package/dist/components/Autocomplete/Autocomplete.d.ts.map +1 -1
- package/dist/components/BulkActionDock/BulkActionDock.d.ts.map +1 -1
- package/dist/components/Carousel/Carousel.d.ts +10 -2
- package/dist/components/Carousel/Carousel.d.ts.map +1 -1
- package/dist/components/Charts/AreaChart.d.ts.map +1 -1
- package/dist/components/Charts/BarChart.d.ts.map +1 -1
- package/dist/components/Charts/ChartWrapper.d.ts.map +1 -1
- package/dist/components/Charts/ComposedChart.d.ts.map +1 -1
- package/dist/components/Charts/CustomLegend.d.ts +11 -2
- package/dist/components/Charts/CustomLegend.d.ts.map +1 -1
- package/dist/components/Charts/LineChart.d.ts.map +1 -1
- package/dist/components/Charts/PieChart.d.ts.map +1 -1
- package/dist/components/Charts/RadialChart.d.ts.map +1 -1
- package/dist/components/Charts/ScatterChart.d.ts.map +1 -1
- package/dist/components/Charts/Sparkline.d.ts.map +1 -1
- package/dist/components/Charts/gaugeGeometry.d.ts +35 -0
- package/dist/components/Charts/gaugeGeometry.d.ts.map +1 -0
- package/dist/components/Charts/highcharts.d.ts +23 -0
- package/dist/components/Charts/highcharts.d.ts.map +1 -0
- package/dist/components/Charts/highchartsUtils.d.ts +101 -6
- package/dist/components/Charts/highchartsUtils.d.ts.map +1 -1
- package/dist/components/Charts/index.d.ts +1 -1
- package/dist/components/Charts/index.d.ts.map +1 -1
- package/dist/components/Charts/tokens.d.ts +21 -0
- package/dist/components/Charts/tokens.d.ts.map +1 -1
- package/dist/components/Charts/types.d.ts +7 -7
- package/dist/components/Charts/types.d.ts.map +1 -1
- package/dist/components/ChipsInput/ChipsInput.d.ts.map +1 -1
- package/dist/components/ChoiceChips/ChoiceChips.d.ts +106 -0
- package/dist/components/ChoiceChips/ChoiceChips.d.ts.map +1 -0
- package/dist/components/ClearableTextField/ClearableTextField.d.ts +23 -2
- package/dist/components/ClearableTextField/ClearableTextField.d.ts.map +1 -1
- package/dist/components/CodeBlock/CodeBlock.d.ts +80 -0
- package/dist/components/CodeBlock/CodeBlock.d.ts.map +1 -0
- package/dist/components/Combobox/Combobox.d.ts +3 -2
- package/dist/components/Combobox/Combobox.d.ts.map +1 -1
- package/dist/components/CommandPalette/CommandPalette.d.ts +54 -3
- package/dist/components/CommandPalette/CommandPalette.d.ts.map +1 -1
- package/dist/components/CommandPalette/index.d.ts +1 -1
- package/dist/components/CommandPalette/index.d.ts.map +1 -1
- package/dist/components/CopyButton/CopyButton.d.ts +80 -0
- package/dist/components/CopyButton/CopyButton.d.ts.map +1 -0
- package/dist/components/DataCard/DataCard.d.ts +11 -1
- package/dist/components/DataCard/DataCard.d.ts.map +1 -1
- package/dist/components/DataTable/CellRenderers.d.ts +8 -11
- package/dist/components/DataTable/CellRenderers.d.ts.map +1 -1
- package/dist/components/DataTable/DataTable.d.ts +1 -1
- package/dist/components/DataTable/DataTable.d.ts.map +1 -1
- package/dist/components/DataTable/InlineAddRow.d.ts.map +1 -1
- package/dist/components/DataTable/columnContext.d.ts +8 -0
- package/dist/components/DataTable/columnContext.d.ts.map +1 -0
- package/dist/components/DataTable/index.d.ts +2 -2
- package/dist/components/DataTable/index.d.ts.map +1 -1
- package/dist/components/DataTable/labels.d.ts +13 -0
- package/dist/components/DataTable/labels.d.ts.map +1 -0
- package/dist/components/DataTable/types.d.ts +34 -0
- package/dist/components/DataTable/types.d.ts.map +1 -1
- package/dist/components/DateRangePicker/DateRangePicker.d.ts.map +1 -1
- package/dist/components/DetailsPopover/DetailsPopover.d.ts +185 -0
- package/dist/components/DetailsPopover/DetailsPopover.d.ts.map +1 -0
- package/dist/components/DiffViewer/DiffViewer.d.ts +3 -2
- package/dist/components/DiffViewer/DiffViewer.d.ts.map +1 -1
- package/dist/components/Disclosure/Disclosure.d.ts +83 -0
- package/dist/components/Disclosure/Disclosure.d.ts.map +1 -0
- package/dist/components/DockLayout/DockLayout.d.ts +58 -0
- package/dist/components/DockLayout/DockLayout.d.ts.map +1 -1
- package/dist/components/DockLayout/index.d.ts +1 -1
- package/dist/components/DockLayout/index.d.ts.map +1 -1
- package/dist/components/DocumentCard/DocumentCard.d.ts +5 -1
- package/dist/components/DocumentCard/DocumentCard.d.ts.map +1 -1
- package/dist/components/EntityDetailPanel/EntityDetailPanel.d.ts +6 -2
- package/dist/components/EntityDetailPanel/EntityDetailPanel.d.ts.map +1 -1
- package/dist/components/FileUpload/FileUpload.d.ts +141 -6
- package/dist/components/FileUpload/FileUpload.d.ts.map +1 -1
- package/dist/components/FileUpload/index.d.ts +1 -1
- package/dist/components/FileUpload/index.d.ts.map +1 -1
- package/dist/components/FilterBar/FilterBar.d.ts +27 -1
- package/dist/components/FilterBar/FilterBar.d.ts.map +1 -1
- package/dist/components/FilterBar/index.d.ts +1 -1
- package/dist/components/FilterBar/index.d.ts.map +1 -1
- package/dist/components/FlowAutoLayout/useFlowAutoLayout.d.ts.map +1 -1
- package/dist/components/GanttView/GanttView.d.ts +24 -0
- package/dist/components/GanttView/GanttView.d.ts.map +1 -1
- package/dist/components/GanttView/types.d.ts +33 -7
- package/dist/components/GanttView/types.d.ts.map +1 -1
- package/dist/components/GaugeCard/GaugeCard.d.ts +4 -3
- package/dist/components/GaugeCard/GaugeCard.d.ts.map +1 -1
- package/dist/components/GaugeCard/geometry.d.ts +59 -0
- package/dist/components/GaugeCard/geometry.d.ts.map +1 -0
- package/dist/components/GeoStatusMap/GeoStatusMap.d.ts.map +1 -1
- package/dist/components/GeoStatusMap/types.d.ts +8 -5
- package/dist/components/GeoStatusMap/types.d.ts.map +1 -1
- package/dist/components/GoToTop/GoToTop.d.ts +1 -1
- package/dist/components/GoToTop/GoToTop.d.ts.map +1 -1
- package/dist/components/HierarchicalDrillDown/HierarchicalDrillDown.d.ts.map +1 -1
- package/dist/components/HistoricalDataIndicator/HistoricalDataIndicator.d.ts.map +1 -1
- package/dist/components/HtmlToMui/HtmlToMui.d.ts +32 -2
- package/dist/components/HtmlToMui/HtmlToMui.d.ts.map +1 -1
- package/dist/components/Icon.d.ts +567 -10
- package/dist/components/Icon.d.ts.map +1 -1
- package/dist/components/IllustratedMessage.d.ts +52 -3
- package/dist/components/IllustratedMessage.d.ts.map +1 -1
- package/dist/components/InlineEditableText/InlineEditableText.d.ts +117 -0
- package/dist/components/InlineEditableText/InlineEditableText.d.ts.map +1 -0
- package/dist/components/InsightCard/InsightCard.d.ts.map +1 -1
- package/dist/components/InsightCard/types.d.ts +10 -3
- package/dist/components/InsightCard/types.d.ts.map +1 -1
- package/dist/components/KeyValueList/KeyValueList.d.ts +94 -0
- package/dist/components/KeyValueList/KeyValueList.d.ts.map +1 -0
- package/dist/components/LandingPage/FeatureCard.d.ts +4 -0
- package/dist/components/LandingPage/FeatureCard.d.ts.map +1 -1
- package/dist/components/LandingPage/LandingPage.d.ts +43 -4
- package/dist/components/LandingPage/LandingPage.d.ts.map +1 -1
- package/dist/components/LandingPage/heroTone.d.ts +54 -0
- package/dist/components/LandingPage/heroTone.d.ts.map +1 -0
- package/dist/components/MentionsInput/MentionsInput.d.ts.map +1 -1
- package/dist/components/MetaChip/MetaChip.d.ts +113 -0
- package/dist/components/MetaChip/MetaChip.d.ts.map +1 -0
- package/dist/components/Modal/Modal.d.ts +222 -20
- package/dist/components/Modal/Modal.d.ts.map +1 -1
- package/dist/components/Modal/index.d.ts +1 -1
- package/dist/components/Modal/index.d.ts.map +1 -1
- package/dist/components/NotificationCenter/NotificationCenter.d.ts.map +1 -1
- package/dist/components/OrgChart/OrgChart.d.ts +5 -0
- package/dist/components/OrgChart/OrgChart.d.ts.map +1 -1
- package/dist/components/OrgChart/types.d.ts +31 -7
- package/dist/components/OrgChart/types.d.ts.map +1 -1
- package/dist/components/OverflowTooltip/OverflowTooltip.d.ts +1 -1
- package/dist/components/OverflowTooltip/OverflowTooltip.d.ts.map +1 -1
- package/dist/components/PageHeader/PageHeader.d.ts.map +1 -1
- package/dist/components/PageTOC/PageTOC.d.ts +2 -1
- package/dist/components/PageTOC/PageTOC.d.ts.map +1 -1
- package/dist/components/Popper/Popper.d.ts +80 -9
- package/dist/components/Popper/Popper.d.ts.map +1 -1
- package/dist/components/Popper/index.d.ts +1 -1
- package/dist/components/Popper/index.d.ts.map +1 -1
- package/dist/components/PredictiveTextInput/PredictiveTextInput.d.ts +5 -1
- package/dist/components/PredictiveTextInput/PredictiveTextInput.d.ts.map +1 -1
- package/dist/components/SandboxedIframeRenderer/SandboxedIframeRenderer.d.ts +48 -4
- package/dist/components/SandboxedIframeRenderer/SandboxedIframeRenderer.d.ts.map +1 -1
- package/dist/components/SearchInput/SearchInput.d.ts +49 -0
- package/dist/components/SearchInput/SearchInput.d.ts.map +1 -1
- package/dist/components/SearchInput/index.d.ts +1 -1
- package/dist/components/SearchInput/index.d.ts.map +1 -1
- package/dist/components/SimpleTable/SimpleTable.d.ts +11 -2
- package/dist/components/SimpleTable/SimpleTable.d.ts.map +1 -1
- package/dist/components/SplitPane/SplitPane.d.ts +2 -1
- package/dist/components/SplitPane/SplitPane.d.ts.map +1 -1
- package/dist/components/StatusHero/StatusHero.d.ts.map +1 -1
- package/dist/components/StatusIndicator/Badge.d.ts +6 -1
- package/dist/components/StatusIndicator/Badge.d.ts.map +1 -1
- package/dist/components/StatusIndicator/Chip.d.ts +3 -1
- package/dist/components/StatusIndicator/Chip.d.ts.map +1 -1
- package/dist/components/StatusIndicator/Indicators.d.ts +5 -1
- package/dist/components/StatusIndicator/Indicators.d.ts.map +1 -1
- package/dist/components/StatusIndicator/Legend.d.ts.map +1 -1
- package/dist/components/StatusIndicator/StatusIndicator.d.ts +98 -4
- package/dist/components/StatusIndicator/StatusIndicator.d.ts.map +1 -1
- package/dist/components/StatusIndicator/index.d.ts +2 -2
- package/dist/components/StatusIndicator/index.d.ts.map +1 -1
- package/dist/components/StatusIndicator/types.d.ts +48 -1
- package/dist/components/StatusIndicator/types.d.ts.map +1 -1
- package/dist/components/StepList/StepList.d.ts +80 -0
- package/dist/components/StepList/StepList.d.ts.map +1 -0
- package/dist/components/StepList/StepStatusMarker.d.ts +39 -0
- package/dist/components/StepList/StepStatusMarker.d.ts.map +1 -0
- package/dist/components/StepList/stepStatus.d.ts +30 -0
- package/dist/components/StepList/stepStatus.d.ts.map +1 -0
- package/dist/components/SystemBanner/SystemBanner.d.ts.map +1 -1
- package/dist/components/Timeline/Timeline.d.ts +57 -3
- package/dist/components/Timeline/Timeline.d.ts.map +1 -1
- package/dist/components/Timeline/index.d.ts +1 -1
- package/dist/components/Timeline/index.d.ts.map +1 -1
- package/dist/components/Timeline/timelineLabels.d.ts +70 -0
- package/dist/components/Timeline/timelineLabels.d.ts.map +1 -0
- package/dist/components/Toast/Toast.d.ts.map +1 -1
- package/dist/components/TopNavHeader.d.ts +6 -0
- package/dist/components/TopNavHeader.d.ts.map +1 -1
- package/dist/components/TopNavWithSidebar.d.ts +49 -1
- package/dist/components/TopNavWithSidebar.d.ts.map +1 -1
- package/dist/components/Tour/Tour.d.ts +18 -1
- package/dist/components/Tour/Tour.d.ts.map +1 -1
- package/dist/components/TransferList/TransferList.d.ts +123 -4
- package/dist/components/TransferList/TransferList.d.ts.map +1 -1
- package/dist/components/TransferList/index.d.ts +1 -1
- package/dist/components/TransferList/index.d.ts.map +1 -1
- package/dist/components/TreeView/TreeView.d.ts +97 -8
- package/dist/components/TreeView/TreeView.d.ts.map +1 -1
- package/dist/components/TreeView/index.d.ts +1 -1
- package/dist/components/TreeView/index.d.ts.map +1 -1
- package/dist/components/TrinityLoader.d.ts.map +1 -1
- package/dist/components/icons/featherExtensions.d.ts +55 -0
- package/dist/components/icons/featherExtensions.d.ts.map +1 -0
- package/dist/components/icons/materialExtensions.d.ts +20 -0
- package/dist/components/icons/materialExtensions.d.ts.map +1 -0
- package/dist/components/internal/index.d.ts +87 -0
- package/dist/components/internal/index.d.ts.map +1 -1
- package/dist/components/navigation/MenuListWithHeading.d.ts +33 -0
- package/dist/components/navigation/MenuListWithHeading.d.ts.map +1 -0
- package/dist/components/navigation/clientSelectorLabels.d.ts +13 -0
- package/dist/components/navigation/clientSelectorLabels.d.ts.map +1 -0
- package/dist/components/navigation/components.d.ts +6 -0
- package/dist/components/navigation/components.d.ts.map +1 -1
- package/dist/components/shared/AsyncOutcomeAlert.d.ts +91 -0
- package/dist/components/shared/AsyncOutcomeAlert.d.ts.map +1 -0
- package/dist/components/shared/TrinityIconSvg.d.ts.map +1 -1
- package/dist/components/shared/TrinityLogoSvg.d.ts.map +1 -1
- package/dist/components/shared/bidi.d.ts +44 -0
- package/dist/components/shared/bidi.d.ts.map +1 -0
- package/dist/components/shared/bidiText.d.ts +25 -0
- package/dist/components/shared/bidiText.d.ts.map +1 -0
- package/dist/components/shared/containerQueries.d.ts +73 -0
- package/dist/components/shared/containerQueries.d.ts.map +1 -0
- package/dist/components/shared/createStringsContext.d.ts +69 -0
- package/dist/components/shared/createStringsContext.d.ts.map +1 -0
- package/dist/components/shared/direction.d.ts +46 -0
- package/dist/components/shared/direction.d.ts.map +1 -0
- package/dist/components/shared/focusTrap.d.ts +36 -0
- package/dist/components/shared/focusTrap.d.ts.map +1 -0
- package/dist/components/shared/getInitials.d.ts +29 -0
- package/dist/components/shared/getInitials.d.ts.map +1 -0
- package/dist/components/shared/headingLevel.d.ts +69 -0
- package/dist/components/shared/headingLevel.d.ts.map +1 -0
- package/dist/components/shared/mergeSlotProps.d.ts +50 -0
- package/dist/components/shared/mergeSlotProps.d.ts.map +1 -0
- package/dist/components/shared/mergeSx.d.ts +26 -0
- package/dist/components/shared/mergeSx.d.ts.map +1 -0
- package/dist/components/shared/motion.d.ts +110 -0
- package/dist/components/shared/motion.d.ts.map +1 -0
- package/dist/components/shared/occurrenceKeys.d.ts +23 -0
- package/dist/components/shared/occurrenceKeys.d.ts.map +1 -0
- package/dist/components/shared/primaryAction.d.ts +89 -0
- package/dist/components/shared/primaryAction.d.ts.map +1 -0
- package/dist/components/shared/resizeKeyboard.d.ts +68 -0
- package/dist/components/shared/resizeKeyboard.d.ts.map +1 -0
- package/dist/components/shared/rootProps.d.ts +117 -0
- package/dist/components/shared/rootProps.d.ts.map +1 -0
- package/dist/components/shared/safeContent.d.ts +136 -0
- package/dist/components/shared/safeContent.d.ts.map +1 -0
- package/dist/components/shared/targetSize.d.ts +64 -0
- package/dist/components/shared/targetSize.d.ts.map +1 -0
- package/dist/components/shared/useContainerInlineSize.d.ts +43 -0
- package/dist/components/shared/useContainerInlineSize.d.ts.map +1 -0
- package/dist/components/shared/useCopyAction.d.ts +35 -0
- package/dist/components/shared/useCopyAction.d.ts.map +1 -0
- package/dist/components/shared/useOverflow.d.ts +44 -0
- package/dist/components/shared/useOverflow.d.ts.map +1 -0
- package/dist/components/shared/useResizable.d.ts +106 -7
- package/dist/components/shared/useResizable.d.ts.map +1 -1
- package/dist/components/shared/warnDeprecated.d.ts +89 -15
- package/dist/components/shared/warnDeprecated.d.ts.map +1 -1
- package/dist/components/shared/zIndexRoles.d.ts +62 -0
- package/dist/components/shared/zIndexRoles.d.ts.map +1 -0
- package/dist/components/templates/AIReviewQueue/AIReviewQueueTemplate.d.ts +213 -0
- package/dist/components/templates/AIReviewQueue/AIReviewQueueTemplate.d.ts.map +1 -0
- package/dist/components/templates/AIReviewQueue/index.d.ts +2 -0
- package/dist/components/templates/AIReviewQueue/index.d.ts.map +1 -0
- package/dist/components/templates/Auth/AuthTemplate.d.ts.map +1 -1
- package/dist/components/templates/Auth/types.d.ts +4 -1
- package/dist/components/templates/Auth/types.d.ts.map +1 -1
- package/dist/components/templates/Catalog/CatalogTemplate.d.ts.map +1 -1
- package/dist/components/templates/ConnectorWizard/ConnectorWizardTemplate.d.ts.map +1 -1
- package/dist/components/templates/InsightsCenter/InsightsCenterTemplate.d.ts.map +1 -1
- package/dist/components/templates/IntegrationDetail/IntegrationDetailTemplate.d.ts.map +1 -1
- package/dist/components/templates/ListDetail/ListDetailTemplate.d.ts +168 -10
- package/dist/components/templates/ListDetail/ListDetailTemplate.d.ts.map +1 -1
- package/dist/components/templates/ListDetail/index.d.ts +1 -1
- package/dist/components/templates/ListDetail/index.d.ts.map +1 -1
- package/dist/components/templates/ListDetail/listDetailLabels.d.ts +106 -0
- package/dist/components/templates/ListDetail/listDetailLabels.d.ts.map +1 -0
- package/dist/components/templates/Onboarding/OnboardingTemplate.d.ts.map +1 -1
- package/dist/components/templates/Settings/SettingsTemplate.d.ts +0 -3
- package/dist/components/templates/Settings/SettingsTemplate.d.ts.map +1 -1
- package/dist/components/templates/Wizard/WizardTemplate.d.ts +4 -1
- package/dist/components/templates/Wizard/WizardTemplate.d.ts.map +1 -1
- package/dist/components/templates/index.d.ts +2 -1
- package/dist/components/templates/index.d.ts.map +1 -1
- package/dist/data-table.d.ts +1 -1
- package/dist/data-table.d.ts.map +1 -1
- package/dist/data-table.js +1 -0
- package/dist/data-table2.js +13522 -13465
- package/dist/data.js +213 -194
- package/dist/elk.bundled.js +47371 -0
- package/dist/essentials.d.ts +3 -3
- package/dist/essentials.d.ts.map +1 -1
- package/dist/essentials.js +179 -147
- package/dist/focus-on-replace.js +49 -0
- package/dist/form.d.ts +26 -4
- package/dist/form.d.ts.map +1 -1
- package/dist/forms.js +575 -483
- package/dist/foundation.js +3704 -0
- package/dist/hooks/storageStore.d.ts +51 -0
- package/dist/hooks/storageStore.d.ts.map +1 -0
- package/dist/hooks/useAsyncAction.d.ts +65 -0
- package/dist/hooks/useAsyncAction.d.ts.map +1 -0
- package/dist/hooks/useDisclosure.d.ts +190 -0
- package/dist/hooks/useDisclosure.d.ts.map +1 -0
- package/dist/hooks/useFocusOnReplace.d.ts +95 -0
- package/dist/hooks/useFocusOnReplace.d.ts.map +1 -0
- package/dist/hooks/useTrinityPalette.d.ts +38 -40
- package/dist/hooks/useTrinityPalette.d.ts.map +1 -1
- package/dist/hooks.d.ts +44 -6
- package/dist/hooks.d.ts.map +1 -1
- package/dist/hooks.js +301 -0
- package/dist/index.d.ts +71 -26
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +13923 -60619
- package/dist/patterns/AICopilotPattern/AICopilotPattern.d.ts +203 -0
- package/dist/patterns/AICopilotPattern/AICopilotPattern.d.ts.map +1 -0
- package/dist/patterns/AICopilotPattern/index.d.ts +3 -0
- package/dist/patterns/AICopilotPattern/index.d.ts.map +1 -0
- package/dist/patterns/index.d.ts +15 -0
- package/dist/patterns/index.d.ts.map +1 -0
- package/dist/presets/analytics.d.ts +8 -1
- package/dist/presets/analytics.d.ts.map +1 -1
- package/dist/presets/crm.d.ts +8 -1
- package/dist/presets/crm.d.ts.map +1 -1
- package/dist/presets/index.d.ts +1 -1
- package/dist/presets/portal.d.ts +8 -1
- package/dist/presets/portal.d.ts.map +1 -1
- package/dist/safe-content.js +792 -0
- package/dist/theme-augmentation.d.ts +388 -0
- package/dist/theme-augmentation.d.ts.map +1 -0
- package/dist/theme.d.ts +116 -30
- package/dist/theme.d.ts.map +1 -1
- package/dist/theme.js +891 -436
- package/dist/token-color.d.ts +14 -0
- package/dist/token-color.d.ts.map +1 -0
- package/dist/token-merge.d.ts +56 -0
- package/dist/token-merge.d.ts.map +1 -0
- package/dist/token-serialization.d.ts +65 -0
- package/dist/token-serialization.d.ts.map +1 -0
- package/dist/tokens.d.ts +882 -13
- package/dist/tokens.d.ts.map +1 -1
- package/dist/tokens.js +21 -19
- package/dist/trinity.css +1077 -414
- package/package.json +111 -90
- package/dist/components/index.d.ts +0 -145
- package/dist/components/index.d.ts.map +0 -1
- package/dist/components/shared.d.ts +0 -92
- package/dist/components/shared.d.ts.map +0 -1
package/dist/theme.js
CHANGED
|
@@ -1,95 +1,258 @@
|
|
|
1
|
-
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
|
|
6
|
-
|
|
1
|
+
'use client';
|
|
2
|
+
import { createTheme as X, useTheme as ir } from "@mui/material/styles";
|
|
3
|
+
import { i as f, Z as T, _ as W, n as cr, $ as D, a0 as K, r as F, j as H, s as z, m as N, a1 as l, a2 as lr, a3 as nr, a4 as Q, a5 as tr, a6 as dr, a7 as br, a8 as ur, a9 as gr, aa as J, z as $, ab as pr, ac as hr, g as j, ad as yr, ae as vr, af as fr } from "./foundation.js";
|
|
4
|
+
import { ag as _r, ah as Ur, ai as Zr, aj as qr, ak as Xr, al as Kr, am as Qr, an as Jr, ao as Yr, ap as Sr, aq as ro } from "./foundation.js";
|
|
5
|
+
import { c as Y } from "./accessibility.js";
|
|
6
|
+
import { useMemo as mr } from "react";
|
|
7
|
+
function xr(...r) {
|
|
8
|
+
return yr(r);
|
|
7
9
|
}
|
|
8
|
-
function
|
|
9
|
-
const
|
|
10
|
-
for (const [
|
|
11
|
-
const g = [...a,
|
|
12
|
-
if (
|
|
13
|
-
if (typeof
|
|
14
|
-
|
|
10
|
+
function d(r, o, s, a = []) {
|
|
11
|
+
const e = [];
|
|
12
|
+
for (const [c, i] of Object.entries(r)) {
|
|
13
|
+
const g = [...o, c], y = [...a, c];
|
|
14
|
+
if (i != null)
|
|
15
|
+
if (typeof i == "object" && !Array.isArray(i))
|
|
16
|
+
e.push(
|
|
17
|
+
...d(
|
|
18
|
+
i,
|
|
19
|
+
g,
|
|
20
|
+
s,
|
|
21
|
+
y
|
|
22
|
+
)
|
|
23
|
+
);
|
|
15
24
|
else {
|
|
16
|
-
const
|
|
17
|
-
|
|
25
|
+
const p = typeof s == "function" ? s(y, i) : s, n = hr(
|
|
26
|
+
i,
|
|
27
|
+
p,
|
|
28
|
+
y.join(".")
|
|
29
|
+
);
|
|
30
|
+
e.push({ name: xr(...g), value: n });
|
|
18
31
|
}
|
|
19
32
|
}
|
|
20
|
-
return
|
|
33
|
+
return e;
|
|
21
34
|
}
|
|
22
|
-
function
|
|
23
|
-
|
|
24
|
-
return a.push(...l(r.base.colors, ["color"])), a.push(...l(r.base.spacing, ["spacing"])), a.push(...l(r.base.fontSize, ["font-size"])), a.push(...l(r.base.fontWeight, ["font-weight"])), a.push(...l(r.base.lineHeight, ["line-height"])), a.push(...l(r.base.letterSpacing, ["letter-spacing"])), a.push(...l(r.base.borderRadius, ["radius"])), a.push(...l(r.base.borderWidth, ["border-width"])), a.push(...l(r.base.shadows, ["shadow"])), a.push(...l(r.base.zIndex, ["z-index"])), a.push(...l(r.base.duration, ["duration"])), a.push(...l(r.base.easing, ["easing"])), a.push(...l(r.base.opacity, ["opacity"])), a.push(...l(r.base.breakpoints, ["breakpoint"])), a.push(...l(r.semantic.colors, ["semantic"])), a.push(...l(r.semantic.spacing, ["semantic-spacing"])), a.push(...l(r.semantic.borders, ["semantic-border"])), a.push(...l(r.semantic.shadows, ["semantic-shadow"])), a.push(...l(r.semantic.motion, ["motion"])), a.push(...l(r.component, ["component"])), a.map((o) => ` ${o.name}: ${o.value};`).join(`
|
|
25
|
-
`);
|
|
35
|
+
function Mr(r = T) {
|
|
36
|
+
return A(S(W(r)));
|
|
26
37
|
}
|
|
27
|
-
function
|
|
28
|
-
|
|
29
|
-
return a.push(...l(r.darkMode.colors.text, ["semantic", "text"])), a.push(...l(r.darkMode.colors.background, ["semantic", "background"])), a.push(...l(r.darkMode.colors.border, ["semantic", "border"])), r.darkMode.colors.interactive && a.push(...l(r.darkMode.colors.interactive, ["semantic", "interactive"])), r.darkMode.colors.status && a.push(...l(r.darkMode.colors.status, ["semantic", "status"])), a.map((o) => ` ${o.name}: ${o.value};`).join(`
|
|
38
|
+
function A(r) {
|
|
39
|
+
return r.map(([o, s]) => ` ${o}: ${s};`).join(`
|
|
30
40
|
`);
|
|
31
41
|
}
|
|
32
|
-
function
|
|
42
|
+
function S(r) {
|
|
43
|
+
const o = [];
|
|
44
|
+
o.push(...d(r.base.colors, ["color"], "raw")), o.push(...d(r.base.spacing, ["spacing"], "dimension")), o.push(...d(r.base.fontSize, ["font-size"], "dimension")), o.push(...d(r.base.fontWeight, ["font-weight"], "fontWeight")), o.push(...d(r.base.lineHeight, ["line-height"], "lineHeight")), o.push(...d(r.base.letterSpacing, ["letter-spacing"], "dimension")), o.push(...d(r.base.borderRadius, ["radius"], "dimension")), o.push(...d(r.base.borderWidth, ["border-width"], "dimension")), o.push(...d(r.base.shadows, ["shadow"], "raw")), r.darkMode.shadows?.glow && o.push(
|
|
45
|
+
...d(r.darkMode.shadows.glow, ["shadow", "glow"], "raw")
|
|
46
|
+
), o.push(...d(r.base.zIndex, ["z-index"], "zIndex")), o.push(...d(r.base.duration, ["duration"], "duration")), o.push(...d(r.base.easing, ["easing"], "raw")), o.push(...d(r.base.opacity, ["opacity"], "opacity")), o.push(...d(r.base.breakpoints, ["breakpoint"], "dimension")), o.push(...d(r.semantic.colors, ["semantic"], "raw")), o.push(...d(nr(r.semantic.spacing), ["semantic-spacing"], "dimension")), o.push(...d(r.semantic.borders, ["semantic-border"], "dimension")), o.push(...d(r.semantic.shadows, ["semantic-shadow"], "raw")), o.push(
|
|
47
|
+
...d(r.semantic.effects, ["semantic-effect"], "raw")
|
|
48
|
+
), o.push(...d(r.semantic.motion, ["motion"], vr)), o.push(...d(r.component, ["component"], fr));
|
|
49
|
+
const s = new Map(o.map(({ name: c, value: i }) => [c, i]));
|
|
50
|
+
Q(s, tr(), {
|
|
51
|
+
onMismatch: "literal",
|
|
52
|
+
onMissing: "skip",
|
|
53
|
+
context: ""
|
|
54
|
+
});
|
|
55
|
+
const a = dr(
|
|
56
|
+
s,
|
|
57
|
+
br(r.semantic.colors),
|
|
58
|
+
{ onMismatch: "literal", context: "" }
|
|
59
|
+
), e = ur();
|
|
60
|
+
for (const [c, i] of e) s.set(c, i);
|
|
61
|
+
return [...o.map(({ name: c }) => c), ...a, ...e.map(([c]) => c)].map(
|
|
62
|
+
(c) => [c, s.get(c)]
|
|
63
|
+
);
|
|
64
|
+
}
|
|
65
|
+
function Wr(r = T) {
|
|
66
|
+
return A(E(W(r)).block);
|
|
67
|
+
}
|
|
68
|
+
function E(r) {
|
|
69
|
+
const o = [], s = r.darkMode.colors, a = /* @__PURE__ */ new Set(["button", "switch"]);
|
|
70
|
+
for (const [n, b] of Object.entries(s)) {
|
|
71
|
+
if (typeof b == "string") {
|
|
72
|
+
o.push(...d({ [n]: b }, ["semantic"], "raw"));
|
|
73
|
+
continue;
|
|
74
|
+
}
|
|
75
|
+
if (!b || typeof b != "object") continue;
|
|
76
|
+
const t = a.has(n) ? ["component", n] : ["semantic", n];
|
|
77
|
+
o.push(...d(b, t, "raw"));
|
|
78
|
+
}
|
|
79
|
+
const e = r.darkMode.shadows;
|
|
80
|
+
e && (o.push(...d(e.scale, ["shadow"], "raw")), o.push(
|
|
81
|
+
...d(e.semantic, ["semantic-shadow"], "raw")
|
|
82
|
+
), o.push(
|
|
83
|
+
{ name: "--trinity-component-card-shadow", value: e.semantic.card },
|
|
84
|
+
{ name: "--trinity-component-modal-shadow", value: e.semantic.modal }
|
|
85
|
+
)), r.darkMode.effects && o.push(
|
|
86
|
+
...d(r.darkMode.effects, ["semantic-effect"], "raw")
|
|
87
|
+
);
|
|
88
|
+
const c = new Map(o.map(({ name: n, value: b }) => [n, b]));
|
|
89
|
+
Q(c, gr(), {
|
|
90
|
+
onMismatch: "literal",
|
|
91
|
+
onMissing: "skip",
|
|
92
|
+
context: ""
|
|
93
|
+
});
|
|
94
|
+
for (const n of o) n.value = c.get(n.name);
|
|
95
|
+
const i = new Set(o.map(({ name: n }) => n)), g = S(r), y = new Map(g), p = o.map(({ name: n, value: b }) => [n, b]);
|
|
96
|
+
for (const n of J(g.map(([b]) => b), y, i))
|
|
97
|
+
i.has(n) || p.push([n, y.get(n)]);
|
|
98
|
+
return { block: p, overridden: i, light: g };
|
|
99
|
+
}
|
|
100
|
+
function wr(r) {
|
|
101
|
+
const { overridden: o, light: s } = E(r), a = new Map(s), e = [...o].map(
|
|
102
|
+
(c) => [c, a.get(c) ?? "initial"]
|
|
103
|
+
);
|
|
104
|
+
for (const c of J(s.map(([i]) => i), a, o))
|
|
105
|
+
o.has(c) || e.push([c, a.get(c)]);
|
|
106
|
+
return e;
|
|
107
|
+
}
|
|
108
|
+
function Ir(r = T) {
|
|
33
109
|
if (typeof window > "u") return;
|
|
34
|
-
const
|
|
35
|
-
|
|
36
|
-
${
|
|
110
|
+
const o = Mr(r), s = document.createElement("style");
|
|
111
|
+
s.id = "trinity-css-variables", s.textContent = `:root {
|
|
112
|
+
${o}
|
|
37
113
|
}`;
|
|
38
|
-
const
|
|
39
|
-
|
|
114
|
+
const a = document.getElementById("trinity-css-variables");
|
|
115
|
+
a && a.remove(), document.head.appendChild(s);
|
|
40
116
|
}
|
|
41
|
-
function
|
|
117
|
+
function Dr(r = T) {
|
|
42
118
|
if (typeof window > "u") return;
|
|
43
|
-
const
|
|
44
|
-
|
|
119
|
+
const o = W(r), s = A(E(o).block), a = A(wr(o)), e = document.createElement("style");
|
|
120
|
+
e.id = "trinity-dark-mode-variables", e.textContent = `
|
|
45
121
|
[data-theme="dark"],
|
|
46
122
|
.dark-mode,
|
|
47
123
|
:root.dark {
|
|
124
|
+
${s}
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
[data-theme="light"] {
|
|
48
128
|
${a}
|
|
49
129
|
}
|
|
50
130
|
|
|
51
131
|
@media (prefers-color-scheme: dark) {
|
|
52
132
|
:root:not([data-theme="light"]) {
|
|
53
|
-
${
|
|
133
|
+
${s}
|
|
54
134
|
}
|
|
55
135
|
}`;
|
|
56
|
-
const
|
|
57
|
-
|
|
136
|
+
const c = document.getElementById("trinity-dark-mode-variables");
|
|
137
|
+
c && c.remove(), document.head.appendChild(e);
|
|
58
138
|
}
|
|
59
|
-
function
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
}
|
|
66
|
-
function s([u, n, t]) {
|
|
67
|
-
const c = [u, n, t].map((b) => (b /= 255, b <= 0.03928 ? b / 12.92 : Math.pow((b + 0.055) / 1.055, 2.4)));
|
|
68
|
-
return 0.2126 * c[0] + 0.7152 * c[1] + 0.0722 * c[2];
|
|
69
|
-
}
|
|
70
|
-
const e = s(o(r)), g = s(o(a));
|
|
71
|
-
return (Math.max(e, g) + 0.05) / (Math.min(e, g) + 0.05);
|
|
139
|
+
function Cr(r, o, s) {
|
|
140
|
+
return cr(r, o, s);
|
|
141
|
+
}
|
|
142
|
+
function Pr(r, o, s = 4.5, a) {
|
|
143
|
+
const e = Cr(r, o, a);
|
|
144
|
+
return Number.isNaN(e) ? !1 : (e < s && typeof window < "u" && console.warn(`[Trinity] Low contrast ratio ${e.toFixed(2)} for ${r} on ${o}`), e >= s);
|
|
72
145
|
}
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
146
|
+
const C = '[aria-disabled="true"]', B = `&.Mui-disabled, &${C}, &${C}:hover, &${C}:active`, Rr = `:not(.Mui-disabled):not(${C}):not([aria-pressed="true"])`, O = (r) => r.map((o) => `&:where(.MuiButton-color${o}${Rr})`).join(", "), P = ["Error", "Warning", "Success", "Info"], G = `&:where(${P.map((r) => `:not(.MuiButton-color${r})`).join("")}, .Mui-disabled, ${C}, [aria-pressed="true"])`, _ = ({ variant: r }) => r === void 0 || r === "indeterminate" || r === "query", I = (r) => typeof r == "object" && r !== null;
|
|
147
|
+
function Or(r, o) {
|
|
148
|
+
if (o == null || o === "") return { color: "inherit" };
|
|
149
|
+
if (typeof o != "string") return null;
|
|
150
|
+
const s = (r.vars ?? r).palette, a = s[o];
|
|
151
|
+
if (I(a) && typeof a.main == "string") return null;
|
|
152
|
+
const e = /^text[A-Z]/.test(o) ? o.charAt(4).toLowerCase() + o.slice(5) : void 0;
|
|
153
|
+
if (e && I(s.text) && typeof s.text[e] == "string") return null;
|
|
154
|
+
const c = o.split(".").reduce((i, g) => I(i) ? i[g] : void 0, s);
|
|
155
|
+
return { color: typeof c == "string" ? c : o };
|
|
76
156
|
}
|
|
77
|
-
function
|
|
78
|
-
const o =
|
|
157
|
+
function rr(r) {
|
|
158
|
+
const o = { ...j.button.onBrand, ...r.component.button.onBrand }, s = { ...j.button.onBrandOutlined, ...r.component.button.onBrandOutlined };
|
|
79
159
|
return {
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
160
|
+
filled: { border: o.background, borderHover: o.backgroundHover, borderActive: o.backgroundActive, borderDisabled: o.backgroundDisabled, ...o },
|
|
161
|
+
outlined: { ...s }
|
|
162
|
+
};
|
|
163
|
+
}
|
|
164
|
+
function U(r) {
|
|
165
|
+
const { filled: o } = rr(r);
|
|
166
|
+
return {
|
|
167
|
+
main: o.background,
|
|
168
|
+
light: o.background,
|
|
169
|
+
dark: o.backgroundActive,
|
|
170
|
+
contrastText: o.text
|
|
171
|
+
};
|
|
172
|
+
}
|
|
173
|
+
function $r(r) {
|
|
174
|
+
const { filled: o, outlined: s } = rr(r), a = "&:where(.MuiButton-colorOnBrand)", e = (i) => ({
|
|
175
|
+
"&:focus-visible, &.Mui-focusVisible": {
|
|
176
|
+
outline: `${r.semantic.borders.width.focus}px solid ${i}`,
|
|
177
|
+
outlineOffset: r.base.spacing[0.5]
|
|
178
|
+
}
|
|
179
|
+
}), c = (i) => ({
|
|
180
|
+
'&[aria-pressed="true"]': {
|
|
181
|
+
backgroundColor: i.backgroundActive,
|
|
182
|
+
borderColor: i.borderActive,
|
|
183
|
+
color: i.textActive,
|
|
184
|
+
boxShadow: `inset 0 0 0 ${r.semantic.borders.width.focus}px ${i.textActive}`,
|
|
185
|
+
"&:hover": { backgroundColor: i.backgroundActive }
|
|
186
|
+
}
|
|
187
|
+
});
|
|
188
|
+
return {
|
|
189
|
+
contained: {
|
|
190
|
+
[O(["OnBrand"])]: {
|
|
191
|
+
"--variant-containedBg": o.background,
|
|
192
|
+
"--variant-containedColor": o.text,
|
|
193
|
+
"&:hover": { backgroundColor: o.backgroundHover, color: o.textHover },
|
|
194
|
+
"&:active": { backgroundColor: o.backgroundActive, color: o.textActive }
|
|
195
|
+
},
|
|
196
|
+
[a]: {
|
|
197
|
+
...e(o.focusOutline),
|
|
198
|
+
...c(o),
|
|
199
|
+
[B]: { backgroundColor: o.backgroundDisabled, color: o.textDisabled }
|
|
200
|
+
}
|
|
201
|
+
},
|
|
202
|
+
outlined: {
|
|
203
|
+
[O(["OnBrand"])]: {
|
|
204
|
+
"--variant-outlinedBorder": s.border,
|
|
205
|
+
"--variant-outlinedColor": s.text,
|
|
206
|
+
"&:hover": { backgroundColor: s.backgroundHover, borderColor: s.borderHover, color: s.textHover },
|
|
207
|
+
"&:active": { backgroundColor: s.backgroundActive, borderColor: s.borderActive, color: s.textActive }
|
|
208
|
+
},
|
|
209
|
+
[a]: {
|
|
210
|
+
...e(s.focusOutline),
|
|
211
|
+
...c(s),
|
|
212
|
+
[B]: {
|
|
213
|
+
backgroundColor: s.backgroundDisabled,
|
|
214
|
+
borderColor: s.borderDisabled,
|
|
215
|
+
color: s.textDisabled
|
|
85
216
|
}
|
|
86
217
|
}
|
|
218
|
+
}
|
|
219
|
+
};
|
|
220
|
+
}
|
|
221
|
+
function Br(r, o, s) {
|
|
222
|
+
const a = $r(r), e = o === "dark" ? "rgba(255, 255, 255, 0.12)" : r.base.colors.gray[200], c = o === "dark" ? "rgba(255, 255, 255, 0.2)" : r.base.colors.gray[300], i = (u) => o === "dark" ? r.darkMode.shadows?.scale[u] ?? D[u] : r.base.shadows[u], g = o === "dark" ? r.darkMode.colors.border.subtle : r.semantic.colors.border.subtle, y = o === "dark" ? r.base.colors.coral[400] : r.base.colors.navy[900], p = {
|
|
223
|
+
outlineStyle: "solid",
|
|
224
|
+
outlineWidth: r.semantic.borders.width.focus,
|
|
225
|
+
outlineColor: y,
|
|
226
|
+
outlineOffset: r.base.spacing[0.5]
|
|
227
|
+
}, n = "@media (forced-colors: active)", b = { outlineColor: "Highlight" }, t = {
|
|
228
|
+
backgroundColor: s.selected,
|
|
229
|
+
color: s.textBrand,
|
|
230
|
+
boxShadow: `inset 0 0 0 ${r.semantic.borders.width.focus}px ${s.interactive}`,
|
|
231
|
+
"&:hover": {
|
|
232
|
+
backgroundColor: s.selected
|
|
233
|
+
}
|
|
234
|
+
}, h = {
|
|
235
|
+
[n]: {
|
|
236
|
+
"&:not(:focus-visible):not(.Mui-focusVisible)": {
|
|
237
|
+
outline: `${r.semantic.borders.width.focus}px solid Highlight`,
|
|
238
|
+
outlineOffset: -r.semantic.borders.width.focus
|
|
239
|
+
}
|
|
240
|
+
}
|
|
241
|
+
};
|
|
242
|
+
return {
|
|
243
|
+
// No MuiCssBaseline body override: MUI's CssBaseline paints the body with
|
|
244
|
+
// palette.background.default and palette.text.primary, so the dark page, presets and palette
|
|
245
|
+
// overrides all reach it. (An override here used to paint gray[800] in dark mode.)
|
|
246
|
+
// The only CssBaseline rule is the reduced-motion backstop (E-44+, OD-B14 (a)): under
|
|
247
|
+
// prefers-reduced-motion every transition and animation collapses to 0.01ms, except on
|
|
248
|
+
// elements with ESSENTIAL_MOTION_CLASS. Components still guard their own motion.
|
|
249
|
+
MuiCssBaseline: {
|
|
250
|
+
styleOverrides: pr()
|
|
87
251
|
},
|
|
252
|
+
// E-52+: inherit only without a colour prop, so a colour prop reaches the text.
|
|
88
253
|
MuiTypography: {
|
|
89
254
|
styleOverrides: {
|
|
90
|
-
root: {
|
|
91
|
-
color: "inherit"
|
|
92
|
-
}
|
|
255
|
+
root: ({ ownerState: u, theme: m }) => Or(m, u.color)
|
|
93
256
|
}
|
|
94
257
|
},
|
|
95
258
|
MuiButton: {
|
|
@@ -101,116 +264,198 @@ function T(r = p, a = "light") {
|
|
|
101
264
|
padding: `${r.base.spacing[2]}px ${r.base.spacing[5]}px`,
|
|
102
265
|
borderRadius: r.base.borderRadius.full,
|
|
103
266
|
fontWeight: r.base.fontWeight.semibold,
|
|
104
|
-
// Disabled state (all variants)
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
267
|
+
// Disabled state (all variants); a pending control (aria-disabled) looks the same and
|
|
268
|
+
// keeps its pointer events, so a tooltip can say why (C-20 (4)).
|
|
269
|
+
[B]: {
|
|
270
|
+
backgroundColor: o === "dark" ? r.base.colors.gray[700] : r.base.colors.gray[200],
|
|
271
|
+
color: o === "dark" ? r.base.colors.gray[500] : r.base.colors.gray[400]
|
|
272
|
+
},
|
|
273
|
+
[`&${C}`]: {
|
|
274
|
+
cursor: "not-allowed"
|
|
275
|
+
},
|
|
276
|
+
// C-27: a toggle Button's pressed state (every variant); C-20 (5): it survives forced colors.
|
|
277
|
+
'&[aria-pressed="true"]': { ...t, ...h }
|
|
109
278
|
},
|
|
110
279
|
// ── Text buttons ──
|
|
111
280
|
text: {
|
|
112
|
-
|
|
281
|
+
// MUI's text variant reads --variant-textColor; this restates it after MUI's colorInherit
|
|
282
|
+
// `color: inherit`, and the rule below sets it, so a plain `sx` colour still wins.
|
|
283
|
+
color: "var(--variant-textColor)",
|
|
113
284
|
"&:hover": {
|
|
114
|
-
backgroundColor:
|
|
285
|
+
backgroundColor: o === "dark" ? r.semantic.effects.onDark.subtle : r.semantic.effects.overlay.hover
|
|
115
286
|
},
|
|
116
287
|
"&:active": {
|
|
117
|
-
backgroundColor:
|
|
288
|
+
backgroundColor: o === "dark" ? r.semantic.effects.onDark.tint : r.semantic.effects.overlay.pressed
|
|
118
289
|
},
|
|
119
|
-
|
|
290
|
+
[B]: {
|
|
120
291
|
backgroundColor: "transparent"
|
|
292
|
+
},
|
|
293
|
+
// Primary, secondary and inherit text is navy (grey in dark mode). C-15: an enabled
|
|
294
|
+
// status colour keeps MUI's own --variant-textColor and MUI's tint of it on hover.
|
|
295
|
+
[G]: {
|
|
296
|
+
"--variant-textColor": o === "dark" ? r.base.colors.gray[100] : r.base.colors.navy[900]
|
|
297
|
+
},
|
|
298
|
+
[O(P)]: {
|
|
299
|
+
"&:hover, &:active": {
|
|
300
|
+
backgroundColor: "var(--variant-textBg)"
|
|
301
|
+
}
|
|
121
302
|
}
|
|
122
303
|
},
|
|
123
304
|
textPrimary: {
|
|
124
|
-
color:
|
|
305
|
+
color: o === "dark" ? r.base.colors.coral[400] : r.base.colors.navy[900],
|
|
125
306
|
"&:hover": {
|
|
126
|
-
backgroundColor:
|
|
307
|
+
backgroundColor: o === "dark" ? "rgba(255, 97, 80, 0.12)" : r.semantic.effects.overlay.hover
|
|
127
308
|
},
|
|
128
309
|
"&:active": {
|
|
129
|
-
backgroundColor:
|
|
310
|
+
backgroundColor: o === "dark" ? "rgba(255, 97, 80, 0.20)" : r.semantic.effects.overlay.pressed
|
|
130
311
|
}
|
|
131
312
|
},
|
|
132
313
|
textSecondary: {
|
|
133
|
-
color:
|
|
314
|
+
color: o === "dark" ? r.base.colors.purple[400] : r.base.colors.coral[800],
|
|
134
315
|
"&:hover": {
|
|
135
|
-
backgroundColor:
|
|
316
|
+
backgroundColor: o === "dark" ? "rgba(120, 65, 201, 0.12)" : r.semantic.effects.overlay.hover
|
|
136
317
|
},
|
|
137
318
|
"&:active": {
|
|
138
|
-
backgroundColor:
|
|
319
|
+
backgroundColor: o === "dark" ? "rgba(120, 65, 201, 0.20)" : r.semantic.effects.overlay.pressed
|
|
139
320
|
}
|
|
140
321
|
},
|
|
141
322
|
// ── Contained buttons ──
|
|
142
323
|
contained: {
|
|
143
|
-
|
|
324
|
+
// Status colors take their palette pair (ADR-03-R7): MUI sets --variant-containedColor
|
|
325
|
+
// to palette.<status>.contrastText, the on-fill color of the status role, and its
|
|
326
|
+
// contained variant reads it. This restates that read after MUI's colorInherit
|
|
327
|
+
// `color: inherit`, so the inherit rule below can set the label through the property.
|
|
328
|
+
// Disabled buttons keep the root's disabled colors.
|
|
329
|
+
color: "var(--variant-containedColor)",
|
|
330
|
+
// C-15: primary and secondary take the component button tokens in both modes, the
|
|
331
|
+
// values the CSS package ships as --trinity-button-<primary|secondary>-*; the dead
|
|
332
|
+
// containedPrimary and containedSecondary keys below meant the same. Without them the
|
|
333
|
+
// white label sat on palette.primary (dark coral, 2.69:1) and palette.secondary (light
|
|
334
|
+
// coral, 2.97:1). A contained inherit button sits on the theme's grey fill (grey[300]
|
|
335
|
+
// light, grey[800] dark), so its label is the theme's text.primary, not the parent's
|
|
336
|
+
// colour (the white label was 1.3:1 on the light grey).
|
|
337
|
+
[O(["Primary"])]: {
|
|
338
|
+
"--variant-containedBg": o === "dark" ? r.darkMode.colors.button?.primary?.background ?? r.base.colors.indigo[400] : r.component.button.primary.background,
|
|
339
|
+
"--variant-containedColor": r.component.button.primary.text,
|
|
340
|
+
"&:hover": {
|
|
341
|
+
backgroundColor: r.component.button.primary.backgroundHover,
|
|
342
|
+
color: r.component.button.primary.textHover
|
|
343
|
+
},
|
|
344
|
+
"&:active": {
|
|
345
|
+
backgroundColor: r.component.button.primary.backgroundActive,
|
|
346
|
+
color: r.component.button.primary.textActive
|
|
347
|
+
}
|
|
348
|
+
},
|
|
349
|
+
[O(["Inherit"])]: {
|
|
350
|
+
"--variant-containedColor": s.textPrimary
|
|
351
|
+
},
|
|
352
|
+
[O(["Secondary"])]: {
|
|
353
|
+
"--variant-containedBg": o === "dark" ? r.darkMode.colors.button?.secondary?.background ?? r.base.colors.purple[600] : r.component.button.secondary.background,
|
|
354
|
+
"--variant-containedColor": r.component.button.secondary.text,
|
|
355
|
+
"&:hover": {
|
|
356
|
+
backgroundColor: r.component.button.secondary.backgroundHover,
|
|
357
|
+
color: r.component.button.secondary.textHover
|
|
358
|
+
},
|
|
359
|
+
"&:active": {
|
|
360
|
+
backgroundColor: r.component.button.secondary.backgroundActive,
|
|
361
|
+
color: r.component.button.secondary.textActive
|
|
362
|
+
}
|
|
363
|
+
},
|
|
364
|
+
// On-brand buttons for navy surfaces (color="onBrand"), last: see onBrandButtonRules.
|
|
365
|
+
...a.contained
|
|
144
366
|
},
|
|
145
367
|
containedPrimary: {
|
|
146
|
-
backgroundColor:
|
|
147
|
-
color: r.
|
|
368
|
+
backgroundColor: o === "dark" ? r.darkMode.colors.button?.primary?.background ?? r.base.colors.indigo[400] : r.component.button.primary.background,
|
|
369
|
+
color: r.component.button.primary.text,
|
|
148
370
|
"&:hover": {
|
|
149
|
-
backgroundColor:
|
|
371
|
+
backgroundColor: r.component.button.primary.backgroundHover,
|
|
372
|
+
color: r.component.button.primary.textHover
|
|
150
373
|
},
|
|
151
374
|
"&:active": {
|
|
152
|
-
backgroundColor:
|
|
375
|
+
backgroundColor: r.component.button.primary.backgroundActive,
|
|
376
|
+
color: r.component.button.primary.textActive
|
|
153
377
|
}
|
|
154
378
|
},
|
|
155
379
|
containedSecondary: {
|
|
156
|
-
backgroundColor:
|
|
157
|
-
color: r.
|
|
380
|
+
backgroundColor: o === "dark" ? r.darkMode.colors.button?.secondary?.background ?? r.base.colors.purple[600] : r.component.button.secondary.background,
|
|
381
|
+
color: r.component.button.secondary.text,
|
|
158
382
|
"&:hover": {
|
|
159
|
-
backgroundColor:
|
|
383
|
+
backgroundColor: r.component.button.secondary.backgroundHover,
|
|
384
|
+
color: r.component.button.secondary.textHover
|
|
160
385
|
},
|
|
161
386
|
"&:active": {
|
|
162
|
-
backgroundColor:
|
|
387
|
+
backgroundColor: r.component.button.secondary.backgroundActive,
|
|
388
|
+
color: r.component.button.secondary.textActive
|
|
163
389
|
}
|
|
164
390
|
},
|
|
165
391
|
// ── Outlined buttons ──
|
|
166
392
|
outlined: {
|
|
167
393
|
borderWidth: 2,
|
|
168
|
-
|
|
169
|
-
|
|
394
|
+
// MUI's outlined variant reads these two properties; they are restated after MUI's
|
|
395
|
+
// colorInherit rule, and the rules below set them, so a plain `sx` colour still wins.
|
|
396
|
+
borderColor: "var(--variant-outlinedBorder)",
|
|
397
|
+
color: "var(--variant-outlinedColor)",
|
|
170
398
|
"&:hover": {
|
|
171
399
|
borderWidth: 2,
|
|
172
|
-
backgroundColor:
|
|
173
|
-
borderColor:
|
|
174
|
-
color: r.
|
|
400
|
+
backgroundColor: r.component.button.outlined.backgroundHover,
|
|
401
|
+
borderColor: r.component.button.outlined.backgroundHover,
|
|
402
|
+
color: r.component.button.outlined.textHover
|
|
175
403
|
},
|
|
176
404
|
"&:active": {
|
|
177
405
|
borderWidth: 2,
|
|
178
|
-
backgroundColor:
|
|
179
|
-
borderColor:
|
|
180
|
-
color: r.
|
|
406
|
+
backgroundColor: r.component.button.outlined.backgroundActive,
|
|
407
|
+
borderColor: r.component.button.outlined.backgroundActive,
|
|
408
|
+
color: r.component.button.outlined.textActive
|
|
181
409
|
},
|
|
182
|
-
|
|
410
|
+
[B]: {
|
|
183
411
|
borderWidth: 2,
|
|
184
|
-
borderColor:
|
|
412
|
+
borderColor: o === "dark" ? r.base.colors.gray[600] : r.base.colors.gray[300],
|
|
185
413
|
backgroundColor: "transparent",
|
|
186
|
-
color:
|
|
187
|
-
}
|
|
414
|
+
color: o === "dark" ? r.base.colors.gray[500] : r.base.colors.gray[400]
|
|
415
|
+
},
|
|
416
|
+
// Primary, secondary and inherit take the outlined button tokens.
|
|
417
|
+
[G]: {
|
|
418
|
+
"--variant-outlinedBorder": o === "dark" ? r.darkMode.colors.button?.outlined?.border ?? r.base.colors.purple[400] : r.component.button.outlined.border,
|
|
419
|
+
"--variant-outlinedColor": o === "dark" ? r.darkMode.colors.button?.outlined?.text ?? r.base.colors.purple[400] : r.component.button.outlined.text
|
|
420
|
+
},
|
|
421
|
+
// C-15: a status colour draws its label and its 2px border in its own colour, with
|
|
422
|
+
// MUI's tint of it on hover, instead of the navy/purple fill above.
|
|
423
|
+
[O(P)]: {
|
|
424
|
+
"--variant-outlinedBorder": "var(--variant-outlinedColor)",
|
|
425
|
+
"&:hover, &:active": {
|
|
426
|
+
color: "var(--variant-outlinedColor)",
|
|
427
|
+
borderColor: "var(--variant-outlinedColor)",
|
|
428
|
+
backgroundColor: "var(--variant-outlinedBg)"
|
|
429
|
+
}
|
|
430
|
+
},
|
|
431
|
+
// On-brand buttons for navy surfaces (color="onBrand"), last: see onBrandButtonRules.
|
|
432
|
+
...a.outlined
|
|
188
433
|
},
|
|
189
434
|
outlinedPrimary: {
|
|
190
|
-
borderColor:
|
|
191
|
-
color:
|
|
435
|
+
borderColor: o === "dark" ? r.darkMode.colors.button?.outlined?.border ?? r.base.colors.purple[400] : r.component.button.outlined.border,
|
|
436
|
+
color: o === "dark" ? r.darkMode.colors.button?.outlined?.text ?? r.base.colors.purple[400] : r.component.button.outlined.text,
|
|
192
437
|
"&:hover": {
|
|
193
|
-
backgroundColor:
|
|
194
|
-
borderColor:
|
|
195
|
-
color: r.
|
|
438
|
+
backgroundColor: r.component.button.outlined.backgroundHover,
|
|
439
|
+
borderColor: r.component.button.outlined.backgroundHover,
|
|
440
|
+
color: r.component.button.outlined.textHover
|
|
196
441
|
},
|
|
197
442
|
"&:active": {
|
|
198
|
-
backgroundColor:
|
|
199
|
-
borderColor:
|
|
200
|
-
color: r.
|
|
443
|
+
backgroundColor: r.component.button.outlined.backgroundActive,
|
|
444
|
+
borderColor: r.component.button.outlined.backgroundActive,
|
|
445
|
+
color: r.component.button.outlined.textActive
|
|
201
446
|
}
|
|
202
447
|
},
|
|
203
448
|
outlinedSecondary: {
|
|
204
|
-
borderColor:
|
|
205
|
-
color:
|
|
449
|
+
borderColor: o === "dark" ? r.base.colors.purple[400] : r.base.colors.indigo[900],
|
|
450
|
+
color: o === "dark" ? r.base.colors.purple[400] : r.base.colors.indigo[900],
|
|
206
451
|
"&:hover": {
|
|
207
|
-
backgroundColor:
|
|
208
|
-
borderColor:
|
|
452
|
+
backgroundColor: o === "dark" ? r.base.colors.purple[500] : r.base.colors.indigo[800],
|
|
453
|
+
borderColor: o === "dark" ? r.base.colors.purple[500] : r.base.colors.indigo[800],
|
|
209
454
|
color: r.base.colors.gray[0]
|
|
210
455
|
},
|
|
211
456
|
"&:active": {
|
|
212
|
-
backgroundColor:
|
|
213
|
-
borderColor:
|
|
457
|
+
backgroundColor: o === "dark" ? r.base.colors.purple[600] : r.base.colors.indigo[700],
|
|
458
|
+
borderColor: o === "dark" ? r.base.colors.purple[600] : r.base.colors.indigo[700],
|
|
214
459
|
color: r.base.colors.gray[0]
|
|
215
460
|
}
|
|
216
461
|
},
|
|
@@ -233,12 +478,12 @@ function T(r = p, a = "light") {
|
|
|
233
478
|
root: {
|
|
234
479
|
borderRadius: r.base.borderRadius.lg,
|
|
235
480
|
// 12px — matches component tokens
|
|
236
|
-
backgroundColor:
|
|
237
|
-
border: `1px solid ${
|
|
238
|
-
boxShadow:
|
|
481
|
+
backgroundColor: o === "dark" ? r.base.colors.gray[700] : r.base.colors.gray[0],
|
|
482
|
+
border: `1px solid ${e}`,
|
|
483
|
+
boxShadow: i("base"),
|
|
239
484
|
transition: "box-shadow 0.2s ease-in-out, border-color 0.2s ease-in-out",
|
|
240
485
|
"&:hover": {
|
|
241
|
-
boxShadow:
|
|
486
|
+
boxShadow: i("md")
|
|
242
487
|
}
|
|
243
488
|
}
|
|
244
489
|
}
|
|
@@ -251,31 +496,31 @@ function T(r = p, a = "light") {
|
|
|
251
496
|
root: {
|
|
252
497
|
borderRadius: r.base.borderRadius.lg,
|
|
253
498
|
// 12px — consistent with cards
|
|
254
|
-
backgroundColor:
|
|
255
|
-
border: `1px solid ${
|
|
256
|
-
boxShadow:
|
|
499
|
+
backgroundColor: o === "dark" ? r.base.colors.gray[700] : r.base.colors.gray[0],
|
|
500
|
+
border: `1px solid ${e}`,
|
|
501
|
+
boxShadow: i("sm")
|
|
257
502
|
},
|
|
258
503
|
rounded: {
|
|
259
504
|
borderRadius: r.base.borderRadius.lg
|
|
260
505
|
},
|
|
261
506
|
elevation0: {
|
|
262
|
-
border: `1px solid ${
|
|
263
|
-
boxShadow:
|
|
507
|
+
border: `1px solid ${e}`,
|
|
508
|
+
boxShadow: i("sm")
|
|
264
509
|
},
|
|
265
510
|
elevation1: {
|
|
266
|
-
border: `1px solid ${
|
|
267
|
-
boxShadow:
|
|
511
|
+
border: `1px solid ${e}`,
|
|
512
|
+
boxShadow: i("base")
|
|
268
513
|
},
|
|
269
514
|
elevation2: {
|
|
270
|
-
border: `1px solid ${
|
|
271
|
-
boxShadow:
|
|
515
|
+
border: `1px solid ${e}`,
|
|
516
|
+
boxShadow: i("md")
|
|
272
517
|
},
|
|
273
518
|
elevation3: {
|
|
274
|
-
border: `1px solid ${
|
|
275
|
-
boxShadow:
|
|
519
|
+
border: `1px solid ${e}`,
|
|
520
|
+
boxShadow: i("lg")
|
|
276
521
|
},
|
|
277
522
|
outlined: {
|
|
278
|
-
border: `1px solid ${
|
|
523
|
+
border: `1px solid ${c}`,
|
|
279
524
|
boxShadow: "none"
|
|
280
525
|
}
|
|
281
526
|
}
|
|
@@ -283,25 +528,34 @@ function T(r = p, a = "light") {
|
|
|
283
528
|
MuiIconButton: {
|
|
284
529
|
styleOverrides: {
|
|
285
530
|
root: {
|
|
286
|
-
color:
|
|
531
|
+
color: o === "dark" ? r.base.colors.gray[300] : r.base.colors.gray[600],
|
|
287
532
|
"&:hover": {
|
|
288
|
-
backgroundColor:
|
|
533
|
+
backgroundColor: o === "dark" ? r.semantic.effects.onDark.subtle : r.semantic.effects.overlay.hoverSubtle
|
|
289
534
|
// 4% black
|
|
290
535
|
},
|
|
291
536
|
"&:active": {
|
|
292
|
-
backgroundColor:
|
|
293
|
-
}
|
|
537
|
+
backgroundColor: o === "dark" ? r.semantic.effects.onDark.tint : r.semantic.effects.overlay.pressed
|
|
538
|
+
},
|
|
539
|
+
// A pending icon button (aria-disabled) looks like MUI's .Mui-disabled one and keeps its
|
|
540
|
+
// pointer events (C-20 (4)).
|
|
541
|
+
[`&${C}, &${C}:hover, &${C}:active`]: {
|
|
542
|
+
backgroundColor: "transparent",
|
|
543
|
+
color: o === "dark" ? r.base.colors.gray[600] : r.base.colors.gray[400],
|
|
544
|
+
cursor: "not-allowed"
|
|
545
|
+
},
|
|
546
|
+
// C-27: a toggle icon button's pressed state; C-20 (5): it survives forced colors.
|
|
547
|
+
'&[aria-pressed="true"]': { ...t, ...h }
|
|
294
548
|
},
|
|
295
549
|
colorPrimary: {
|
|
296
|
-
color:
|
|
550
|
+
color: o === "dark" ? r.base.colors.coral[400] : r.base.colors.navy[900],
|
|
297
551
|
"&:hover": {
|
|
298
|
-
backgroundColor:
|
|
552
|
+
backgroundColor: o === "dark" ? "rgba(255, 97, 80, 0.12)" : r.semantic.effects.overlay.hover
|
|
299
553
|
}
|
|
300
554
|
},
|
|
301
555
|
colorSecondary: {
|
|
302
|
-
color:
|
|
556
|
+
color: o === "dark" ? r.base.colors.purple[400] : r.base.colors.coral[800],
|
|
303
557
|
"&:hover": {
|
|
304
|
-
backgroundColor:
|
|
558
|
+
backgroundColor: o === "dark" ? "rgba(120, 65, 201, 0.12)" : r.semantic.effects.overlay.hover
|
|
305
559
|
}
|
|
306
560
|
}
|
|
307
561
|
}
|
|
@@ -320,9 +574,9 @@ function T(r = p, a = "light") {
|
|
|
320
574
|
paper: {
|
|
321
575
|
borderRadius: r.base.borderRadius.xl,
|
|
322
576
|
// 16px — allows nested cards with lg:12px
|
|
323
|
-
backgroundColor:
|
|
324
|
-
border: `1px solid ${
|
|
325
|
-
boxShadow:
|
|
577
|
+
backgroundColor: o === "dark" ? r.base.colors.gray[700] : r.base.colors.gray[0],
|
|
578
|
+
border: `1px solid ${e}`,
|
|
579
|
+
boxShadow: i("2xl")
|
|
326
580
|
}
|
|
327
581
|
}
|
|
328
582
|
},
|
|
@@ -333,7 +587,7 @@ function T(r = p, a = "light") {
|
|
|
333
587
|
fontWeight: r.base.fontWeight.semibold,
|
|
334
588
|
padding: `${r.base.spacing[5]}px ${r.base.spacing[6]}px`,
|
|
335
589
|
paddingBottom: r.base.spacing[3],
|
|
336
|
-
color:
|
|
590
|
+
color: o === "dark" ? r.base.colors.gray[50] : r.base.colors.gray[900]
|
|
337
591
|
}
|
|
338
592
|
}
|
|
339
593
|
},
|
|
@@ -341,7 +595,7 @@ function T(r = p, a = "light") {
|
|
|
341
595
|
styleOverrides: {
|
|
342
596
|
root: {
|
|
343
597
|
padding: `${r.base.spacing[3]}px ${r.base.spacing[6]}px`,
|
|
344
|
-
color:
|
|
598
|
+
color: o === "dark" ? r.base.colors.gray[300] : r.base.colors.gray[600]
|
|
345
599
|
}
|
|
346
600
|
}
|
|
347
601
|
},
|
|
@@ -364,11 +618,11 @@ function T(r = p, a = "light") {
|
|
|
364
618
|
MuiLink: {
|
|
365
619
|
styleOverrides: {
|
|
366
620
|
root: {
|
|
367
|
-
color:
|
|
368
|
-
textDecorationColor:
|
|
621
|
+
color: o === "dark" ? r.base.colors.coral[400] : r.base.colors.navy[900],
|
|
622
|
+
textDecorationColor: o === "dark" ? r.base.colors.coral[400] : r.base.colors.navy[900],
|
|
369
623
|
"&:hover": {
|
|
370
|
-
color:
|
|
371
|
-
textDecorationColor:
|
|
624
|
+
color: o === "dark" ? r.base.colors.coral[300] : r.base.colors.coral[800],
|
|
625
|
+
textDecorationColor: o === "dark" ? r.base.colors.coral[300] : r.base.colors.coral[800]
|
|
372
626
|
}
|
|
373
627
|
}
|
|
374
628
|
}
|
|
@@ -376,17 +630,28 @@ function T(r = p, a = "light") {
|
|
|
376
630
|
MuiChip: {
|
|
377
631
|
styleOverrides: {
|
|
378
632
|
root: {
|
|
379
|
-
borderRadius: r.base.borderRadius.sm
|
|
633
|
+
borderRadius: r.base.borderRadius.sm,
|
|
380
634
|
// 6px for chip elements
|
|
635
|
+
// C-20 (5): a pressed or checked chip keeps its state in forced colors.
|
|
636
|
+
'&[aria-pressed="true"], &[aria-checked="true"]': h
|
|
637
|
+
}
|
|
638
|
+
}
|
|
639
|
+
},
|
|
640
|
+
// C-27: ToggleButton's selected state takes the pressed recipe (MUI's own is a 0.16 or
|
|
641
|
+
// 0.08 tint of text.primary with no other indicator); C-20 (5): it survives forced colors.
|
|
642
|
+
MuiToggleButton: {
|
|
643
|
+
styleOverrides: {
|
|
644
|
+
root: {
|
|
645
|
+
"&.Mui-selected": { ...t, ...h }
|
|
381
646
|
}
|
|
382
647
|
}
|
|
383
648
|
},
|
|
384
649
|
MuiInputLabel: {
|
|
385
650
|
styleOverrides: {
|
|
386
651
|
root: {
|
|
387
|
-
color:
|
|
652
|
+
color: o === "dark" ? r.base.colors.gray[400] : r.base.colors.gray[600],
|
|
388
653
|
"&.Mui-focused": {
|
|
389
|
-
color:
|
|
654
|
+
color: o === "dark" ? r.base.colors.coral[400] : r.base.colors.navy[900]
|
|
390
655
|
}
|
|
391
656
|
}
|
|
392
657
|
}
|
|
@@ -403,10 +668,10 @@ function T(r = p, a = "light") {
|
|
|
403
668
|
// 6px for small inputs
|
|
404
669
|
},
|
|
405
670
|
"& .MuiInputBase-input": {
|
|
406
|
-
color:
|
|
671
|
+
color: o === "dark" ? r.base.colors.gray[50] : r.base.colors.gray[900]
|
|
407
672
|
},
|
|
408
673
|
"& .MuiInputBase-input::placeholder": {
|
|
409
|
-
color:
|
|
674
|
+
color: o === "dark" ? r.base.colors.gray[500] : r.base.colors.gray[400],
|
|
410
675
|
opacity: 1
|
|
411
676
|
}
|
|
412
677
|
}
|
|
@@ -422,45 +687,53 @@ function T(r = p, a = "light") {
|
|
|
422
687
|
// 6px for small inputs
|
|
423
688
|
},
|
|
424
689
|
"& .MuiOutlinedInput-notchedOutline": {
|
|
425
|
-
borderColor:
|
|
690
|
+
borderColor: o === "dark" ? "rgba(255, 255, 255, 0.23)" : r.base.colors.gray[300]
|
|
426
691
|
// @intentional-color: MUI standard border
|
|
427
692
|
},
|
|
428
693
|
"&:hover .MuiOutlinedInput-notchedOutline": {
|
|
429
|
-
borderColor:
|
|
694
|
+
borderColor: o === "dark" ? r.semantic.effects.onDark.tertiary : r.base.colors.gray[400]
|
|
430
695
|
// 50% white
|
|
431
696
|
},
|
|
432
697
|
"&.Mui-focused .MuiOutlinedInput-notchedOutline": {
|
|
433
|
-
borderColor:
|
|
698
|
+
borderColor: o === "dark" ? r.base.colors.coral[400] : r.base.colors.navy[900]
|
|
699
|
+
},
|
|
700
|
+
// C-15: an input in error keeps the border.error outline at rest, on hover and while
|
|
701
|
+
// focused (the two rules above used to replace it), the value the CSS package ships as
|
|
702
|
+
// --trinity-border-error (dark #F87171; palette.error.main #FCA5A5 stays the text colour).
|
|
703
|
+
// MUI's own error rule has this shape and weight; it beats the hover and focus rules
|
|
704
|
+
// above by coming after them, so an `sx` or app override of the same shape still wins.
|
|
705
|
+
"&.Mui-error .MuiOutlinedInput-notchedOutline": {
|
|
706
|
+
borderColor: o === "dark" ? r.darkMode.colors.border.error ?? (r.darkMode.colors.status ?? r.semantic.colors.status).error.text : r.semantic.colors.border.error
|
|
434
707
|
}
|
|
435
708
|
},
|
|
436
709
|
input: {
|
|
437
|
-
color:
|
|
710
|
+
color: o === "dark" ? r.base.colors.gray[50] : r.base.colors.gray[900]
|
|
438
711
|
}
|
|
439
712
|
}
|
|
440
713
|
},
|
|
441
714
|
MuiFilledInput: {
|
|
442
715
|
styleOverrides: {
|
|
443
716
|
root: {
|
|
444
|
-
backgroundColor:
|
|
717
|
+
backgroundColor: o === "dark" ? "rgba(255, 255, 255, 0.09)" : r.semantic.effects.overlay.hover,
|
|
445
718
|
// 8%
|
|
446
719
|
"&:hover": {
|
|
447
|
-
backgroundColor:
|
|
720
|
+
backgroundColor: o === "dark" ? "rgba(255, 255, 255, 0.13)" : r.semantic.effects.overlay.pressed
|
|
448
721
|
// 12%
|
|
449
722
|
},
|
|
450
723
|
"&.Mui-focused": {
|
|
451
|
-
backgroundColor:
|
|
724
|
+
backgroundColor: o === "dark" ? "rgba(255, 255, 255, 0.09)" : r.semantic.effects.overlay.hover
|
|
452
725
|
// 8%
|
|
453
726
|
}
|
|
454
727
|
},
|
|
455
728
|
input: {
|
|
456
|
-
color:
|
|
729
|
+
color: o === "dark" ? r.base.colors.gray[50] : r.base.colors.gray[900]
|
|
457
730
|
}
|
|
458
731
|
}
|
|
459
732
|
},
|
|
460
733
|
MuiFormHelperText: {
|
|
461
734
|
styleOverrides: {
|
|
462
735
|
root: {
|
|
463
|
-
color:
|
|
736
|
+
color: o === "dark" ? r.base.colors.gray[400] : r.base.colors.gray[600]
|
|
464
737
|
}
|
|
465
738
|
}
|
|
466
739
|
},
|
|
@@ -531,7 +804,7 @@ function T(r = p, a = "light") {
|
|
|
531
804
|
borderRadius: r.semantic.borders.radius.badge,
|
|
532
805
|
// 12px for day cells
|
|
533
806
|
"&.Mui-selected": {
|
|
534
|
-
backgroundColor:
|
|
807
|
+
backgroundColor: o === "dark" ? r.base.colors.coral[400] : r.base.colors.navy[900]
|
|
535
808
|
}
|
|
536
809
|
}
|
|
537
810
|
}
|
|
@@ -566,7 +839,7 @@ function T(r = p, a = "light") {
|
|
|
566
839
|
paper: {
|
|
567
840
|
borderRadius: r.base.borderRadius.lg,
|
|
568
841
|
// 12px for popup
|
|
569
|
-
boxShadow:
|
|
842
|
+
boxShadow: i("lg")
|
|
570
843
|
}
|
|
571
844
|
}
|
|
572
845
|
},
|
|
@@ -592,6 +865,8 @@ function T(r = p, a = "light") {
|
|
|
592
865
|
width: 52,
|
|
593
866
|
height: 32,
|
|
594
867
|
padding: 0,
|
|
868
|
+
// The track fills the root, so the root must not clip the focus ring drawn around it.
|
|
869
|
+
overflow: "visible",
|
|
595
870
|
"& .MuiSwitch-switchBase": {
|
|
596
871
|
padding: 0,
|
|
597
872
|
margin: 4,
|
|
@@ -600,7 +875,7 @@ function T(r = p, a = "light") {
|
|
|
600
875
|
transform: "translateX(20px)",
|
|
601
876
|
color: r.base.colors.gray[0],
|
|
602
877
|
"& + .MuiSwitch-track": {
|
|
603
|
-
backgroundColor:
|
|
878
|
+
backgroundColor: o === "dark" ? r.darkMode.colors.switch?.track.on ?? r.base.colors.indigo[400] : r.base.colors.navy[900],
|
|
604
879
|
opacity: 1,
|
|
605
880
|
border: 0
|
|
606
881
|
},
|
|
@@ -617,7 +892,7 @@ function T(r = p, a = "light") {
|
|
|
617
892
|
top: 0,
|
|
618
893
|
backgroundRepeat: "no-repeat",
|
|
619
894
|
backgroundPosition: "center",
|
|
620
|
-
backgroundImage: `url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" height="16" width="16" viewBox="0 0 24 24"><path fill="${encodeURIComponent(
|
|
895
|
+
backgroundImage: `url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" height="16" width="16" viewBox="0 0 24 24"><path fill="${encodeURIComponent(o === "dark" ? r.darkMode.colors.switch?.track.on ?? r.base.colors.indigo[400] : r.base.colors.navy[900])}" d="M9 16.17 4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41z"/></svg>')`
|
|
621
896
|
}
|
|
622
897
|
},
|
|
623
898
|
"&.Mui-disabled + .MuiSwitch-track": {
|
|
@@ -625,14 +900,20 @@ function T(r = p, a = "light") {
|
|
|
625
900
|
}
|
|
626
901
|
},
|
|
627
902
|
"&.Mui-focusVisible .MuiSwitch-thumb": {
|
|
628
|
-
color:
|
|
903
|
+
color: o === "dark" ? r.darkMode.colors.switch?.track.on ?? r.base.colors.indigo[400] : r.base.colors.navy[900],
|
|
629
904
|
border: `6px solid ${r.base.colors.gray[0]}`
|
|
630
905
|
},
|
|
906
|
+
// The ring goes on the track: MUI 9 sets .Mui-focusVisible on the switchBase when its
|
|
907
|
+
// inner input has keyboard focus, and the track is the visible control.
|
|
908
|
+
"&.Mui-focusVisible + .MuiSwitch-track": {
|
|
909
|
+
...p,
|
|
910
|
+
[n]: b
|
|
911
|
+
},
|
|
631
912
|
"&.Mui-disabled .MuiSwitch-thumb": {
|
|
632
|
-
color:
|
|
913
|
+
color: o === "dark" ? r.base.colors.gray[600] : r.base.colors.gray[300]
|
|
633
914
|
},
|
|
634
915
|
"&.Mui-disabled + .MuiSwitch-track": {
|
|
635
|
-
opacity:
|
|
916
|
+
opacity: o === "dark" ? 0.3 : 0.5
|
|
636
917
|
}
|
|
637
918
|
},
|
|
638
919
|
"& .MuiSwitch-thumb": {
|
|
@@ -641,13 +922,13 @@ function T(r = p, a = "light") {
|
|
|
641
922
|
height: 16,
|
|
642
923
|
margin: 4,
|
|
643
924
|
position: "relative",
|
|
644
|
-
boxShadow:
|
|
925
|
+
boxShadow: i("sm"),
|
|
645
926
|
transition: "all 200ms ease-in-out"
|
|
646
927
|
},
|
|
647
928
|
"& .MuiSwitch-track": {
|
|
648
929
|
borderRadius: 32 / 2,
|
|
649
|
-
backgroundColor:
|
|
650
|
-
border: `2px solid ${
|
|
930
|
+
backgroundColor: o === "dark" ? r.darkMode.colors.switch?.track.off ?? r.base.colors.gray[500] : r.base.colors.gray[200],
|
|
931
|
+
border: `2px solid ${o === "dark" ? r.darkMode.colors.switch?.track.border ?? r.base.colors.gray[500] : r.component.switch.track.border ?? r.base.colors.gray[300]}`,
|
|
651
932
|
opacity: 1,
|
|
652
933
|
transition: "background-color 300ms, border-color 300ms",
|
|
653
934
|
boxSizing: "border-box"
|
|
@@ -674,7 +955,7 @@ function T(r = p, a = "light") {
|
|
|
674
955
|
top: 0,
|
|
675
956
|
backgroundRepeat: "no-repeat",
|
|
676
957
|
backgroundPosition: "center",
|
|
677
|
-
backgroundImage: `url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" height="12" width="12" viewBox="0 0 24 24"><path fill="${encodeURIComponent(
|
|
958
|
+
backgroundImage: `url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" height="12" width="12" viewBox="0 0 24 24"><path fill="${encodeURIComponent(o === "dark" ? r.darkMode.colors.switch?.track.on ?? r.base.colors.indigo[400] : r.base.colors.navy[900])}" d="M9 16.17 4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41z"/></svg>')`
|
|
678
959
|
}
|
|
679
960
|
}
|
|
680
961
|
}
|
|
@@ -690,6 +971,34 @@ function T(r = p, a = "light") {
|
|
|
690
971
|
}
|
|
691
972
|
}
|
|
692
973
|
},
|
|
974
|
+
// ============================================
|
|
975
|
+
// CHECKBOX AND RADIO FOCUS
|
|
976
|
+
// ============================================
|
|
977
|
+
// MUI 9 focuses the hidden input inside the ButtonBase root, so the root's :focus-visible
|
|
978
|
+
// (MuiButtonBase below) never matches. MUI marks the root .Mui-focusVisible instead; the
|
|
979
|
+
// ring goes on the icon, as MUI's own theme.focusVisible option places it.
|
|
980
|
+
MuiCheckbox: {
|
|
981
|
+
styleOverrides: {
|
|
982
|
+
root: {
|
|
983
|
+
"&.Mui-focusVisible svg:first-of-type": {
|
|
984
|
+
...p,
|
|
985
|
+
borderRadius: r.base.borderRadius.xs,
|
|
986
|
+
[n]: b
|
|
987
|
+
}
|
|
988
|
+
}
|
|
989
|
+
}
|
|
990
|
+
},
|
|
991
|
+
MuiRadio: {
|
|
992
|
+
styleOverrides: {
|
|
993
|
+
root: {
|
|
994
|
+
"&.Mui-focusVisible svg:first-of-type": {
|
|
995
|
+
...p,
|
|
996
|
+
borderRadius: r.base.borderRadius.full,
|
|
997
|
+
[n]: b
|
|
998
|
+
}
|
|
999
|
+
}
|
|
1000
|
+
}
|
|
1001
|
+
},
|
|
693
1002
|
MuiFormControlLabel: {
|
|
694
1003
|
styleOverrides: {
|
|
695
1004
|
root: {
|
|
@@ -727,7 +1036,7 @@ function T(r = p, a = "light") {
|
|
|
727
1036
|
styleOverrides: {
|
|
728
1037
|
root: {
|
|
729
1038
|
minHeight: 48,
|
|
730
|
-
borderBottom:
|
|
1039
|
+
borderBottom: `${r.base.borderWidth[1]}px solid ${g}`,
|
|
731
1040
|
"&.Mui-expanded": {
|
|
732
1041
|
minHeight: 48
|
|
733
1042
|
}
|
|
@@ -754,7 +1063,7 @@ function T(r = p, a = "light") {
|
|
|
754
1063
|
MuiTableHead: {
|
|
755
1064
|
styleOverrides: {
|
|
756
1065
|
root: {
|
|
757
|
-
backgroundColor:
|
|
1066
|
+
backgroundColor: o === "dark" ? "rgba(255, 255, 255, 0.05)" : r.base.colors.gray[50]
|
|
758
1067
|
}
|
|
759
1068
|
}
|
|
760
1069
|
},
|
|
@@ -765,17 +1074,17 @@ function T(r = p, a = "light") {
|
|
|
765
1074
|
borderBottom: 0
|
|
766
1075
|
},
|
|
767
1076
|
"&.Mui-selected": {
|
|
768
|
-
backgroundColor:
|
|
1077
|
+
backgroundColor: o === "dark" ? "rgba(255, 97, 80, 0.08)" : r.semantic.effects.overlay.hoverSubtle
|
|
769
1078
|
// 4%
|
|
770
1079
|
},
|
|
771
1080
|
"&.Mui-selected:hover": {
|
|
772
|
-
backgroundColor:
|
|
1081
|
+
backgroundColor: o === "dark" ? "rgba(255, 97, 80, 0.12)" : r.semantic.effects.overlay.hover
|
|
773
1082
|
// 8%
|
|
774
1083
|
}
|
|
775
1084
|
},
|
|
776
1085
|
hover: {
|
|
777
1086
|
"&:hover": {
|
|
778
|
-
backgroundColor:
|
|
1087
|
+
backgroundColor: o === "dark" ? r.semantic.effects.overlay.hoverSubtle : "rgba(0, 0, 0, 0.02)"
|
|
779
1088
|
// @intentional-color: subtle table row hover
|
|
780
1089
|
}
|
|
781
1090
|
}
|
|
@@ -784,18 +1093,18 @@ function T(r = p, a = "light") {
|
|
|
784
1093
|
MuiTableCell: {
|
|
785
1094
|
styleOverrides: {
|
|
786
1095
|
root: {
|
|
787
|
-
borderBottom: `1px solid ${
|
|
1096
|
+
borderBottom: `1px solid ${e}`,
|
|
788
1097
|
padding: `${r.base.spacing[3]}px ${r.base.spacing[4]}px`
|
|
789
1098
|
},
|
|
790
1099
|
head: {
|
|
791
1100
|
fontWeight: r.base.fontWeight.semibold,
|
|
792
|
-
color:
|
|
1101
|
+
color: o === "dark" ? r.base.colors.gray[300] : r.base.colors.gray[700],
|
|
793
1102
|
fontSize: r.base.fontSize.sm,
|
|
794
1103
|
textTransform: "uppercase",
|
|
795
1104
|
letterSpacing: "0.05em"
|
|
796
1105
|
},
|
|
797
1106
|
body: {
|
|
798
|
-
color:
|
|
1107
|
+
color: o === "dark" ? r.base.colors.gray[100] : r.base.colors.gray[900]
|
|
799
1108
|
},
|
|
800
1109
|
sizeSmall: {
|
|
801
1110
|
padding: `${r.base.spacing[2]}px ${r.base.spacing[3]}px`
|
|
@@ -805,12 +1114,12 @@ function T(r = p, a = "light") {
|
|
|
805
1114
|
MuiTableSortLabel: {
|
|
806
1115
|
styleOverrides: {
|
|
807
1116
|
root: {
|
|
808
|
-
color:
|
|
1117
|
+
color: o === "dark" ? r.base.colors.gray[300] : r.base.colors.gray[700],
|
|
809
1118
|
"&:hover": {
|
|
810
|
-
color:
|
|
1119
|
+
color: o === "dark" ? r.base.colors.gray[100] : r.base.colors.gray[900]
|
|
811
1120
|
},
|
|
812
1121
|
"&.Mui-active": {
|
|
813
|
-
color:
|
|
1122
|
+
color: o === "dark" ? r.base.colors.coral[400] : r.base.colors.navy[900]
|
|
814
1123
|
}
|
|
815
1124
|
},
|
|
816
1125
|
icon: {
|
|
@@ -825,8 +1134,8 @@ function T(r = p, a = "light") {
|
|
|
825
1134
|
styleOverrides: {
|
|
826
1135
|
paper: {
|
|
827
1136
|
borderRadius: r.base.borderRadius.md,
|
|
828
|
-
boxShadow:
|
|
829
|
-
border: `1px solid ${
|
|
1137
|
+
boxShadow: i("lg"),
|
|
1138
|
+
border: `1px solid ${e}`,
|
|
830
1139
|
marginTop: r.base.spacing[1]
|
|
831
1140
|
},
|
|
832
1141
|
list: {
|
|
@@ -842,12 +1151,12 @@ function T(r = p, a = "light") {
|
|
|
842
1151
|
padding: `${r.base.spacing[2]}px ${r.base.spacing[3]}px`,
|
|
843
1152
|
fontSize: r.base.fontSize.sm,
|
|
844
1153
|
"&:hover": {
|
|
845
|
-
backgroundColor:
|
|
1154
|
+
backgroundColor: o === "dark" ? "rgba(255, 255, 255, 0.08)" : "rgba(0, 0, 0, 0.04)"
|
|
846
1155
|
},
|
|
847
1156
|
"&.Mui-selected": {
|
|
848
|
-
backgroundColor:
|
|
1157
|
+
backgroundColor: o === "dark" ? "rgba(255, 97, 80, 0.12)" : "rgba(5, 7, 66, 0.08)",
|
|
849
1158
|
"&:hover": {
|
|
850
|
-
backgroundColor:
|
|
1159
|
+
backgroundColor: o === "dark" ? "rgba(255, 97, 80, 0.16)" : "rgba(5, 7, 66, 0.12)"
|
|
851
1160
|
}
|
|
852
1161
|
}
|
|
853
1162
|
}
|
|
@@ -857,8 +1166,8 @@ function T(r = p, a = "light") {
|
|
|
857
1166
|
styleOverrides: {
|
|
858
1167
|
paper: {
|
|
859
1168
|
borderRadius: r.base.borderRadius.md,
|
|
860
|
-
boxShadow:
|
|
861
|
-
border: `1px solid ${
|
|
1169
|
+
boxShadow: i("lg"),
|
|
1170
|
+
border: `1px solid ${e}`
|
|
862
1171
|
}
|
|
863
1172
|
}
|
|
864
1173
|
},
|
|
@@ -888,12 +1197,12 @@ function T(r = p, a = "light") {
|
|
|
888
1197
|
root: {
|
|
889
1198
|
borderRadius: r.base.borderRadius.sm,
|
|
890
1199
|
"&:hover": {
|
|
891
|
-
backgroundColor:
|
|
1200
|
+
backgroundColor: o === "dark" ? "rgba(255, 255, 255, 0.08)" : "rgba(0, 0, 0, 0.04)"
|
|
892
1201
|
},
|
|
893
1202
|
"&.Mui-selected": {
|
|
894
|
-
backgroundColor:
|
|
1203
|
+
backgroundColor: o === "dark" ? "rgba(255, 97, 80, 0.12)" : "rgba(5, 7, 66, 0.08)",
|
|
895
1204
|
"&:hover": {
|
|
896
|
-
backgroundColor:
|
|
1205
|
+
backgroundColor: o === "dark" ? "rgba(255, 97, 80, 0.16)" : "rgba(5, 7, 66, 0.12)"
|
|
897
1206
|
}
|
|
898
1207
|
}
|
|
899
1208
|
}
|
|
@@ -902,7 +1211,7 @@ function T(r = p, a = "light") {
|
|
|
902
1211
|
MuiListItemIcon: {
|
|
903
1212
|
styleOverrides: {
|
|
904
1213
|
root: {
|
|
905
|
-
color:
|
|
1214
|
+
color: o === "dark" ? r.base.colors.gray[400] : r.base.colors.gray[600],
|
|
906
1215
|
minWidth: 40
|
|
907
1216
|
}
|
|
908
1217
|
}
|
|
@@ -923,8 +1232,8 @@ function T(r = p, a = "light") {
|
|
|
923
1232
|
MuiDrawer: {
|
|
924
1233
|
styleOverrides: {
|
|
925
1234
|
paper: {
|
|
926
|
-
backgroundColor:
|
|
927
|
-
borderRight: `1px solid ${
|
|
1235
|
+
backgroundColor: o === "dark" ? r.base.colors.gray[800] : r.base.colors.gray[0],
|
|
1236
|
+
borderRight: `1px solid ${e}`
|
|
928
1237
|
}
|
|
929
1238
|
}
|
|
930
1239
|
},
|
|
@@ -937,7 +1246,7 @@ function T(r = p, a = "light") {
|
|
|
937
1246
|
minHeight: 40
|
|
938
1247
|
},
|
|
939
1248
|
indicator: {
|
|
940
|
-
backgroundColor:
|
|
1249
|
+
backgroundColor: o === "dark" ? r.base.colors.coral[400] : r.base.colors.navy[900],
|
|
941
1250
|
height: 3,
|
|
942
1251
|
borderRadius: 2
|
|
943
1252
|
}
|
|
@@ -952,18 +1261,18 @@ function T(r = p, a = "light") {
|
|
|
952
1261
|
minHeight: 40,
|
|
953
1262
|
padding: `${r.base.spacing[2]}px ${r.base.spacing[4]}px`,
|
|
954
1263
|
borderRadius: r.base.borderRadius.xs,
|
|
955
|
-
color:
|
|
1264
|
+
color: o === "dark" ? r.base.colors.gray[400] : r.base.colors.gray[600],
|
|
956
1265
|
transition: "color 0.2s ease, background-color 0.2s ease",
|
|
957
1266
|
"&:hover": {
|
|
958
|
-
color:
|
|
959
|
-
backgroundColor:
|
|
1267
|
+
color: o === "dark" ? r.base.colors.gray[200] : r.base.colors.gray[900],
|
|
1268
|
+
backgroundColor: o === "dark" ? r.semantic.effects.onDark.subtle : r.semantic.effects.overlay.hoverSubtle
|
|
960
1269
|
},
|
|
961
1270
|
"&.Mui-selected": {
|
|
962
|
-
color:
|
|
1271
|
+
color: o === "dark" ? r.base.colors.coral[400] : r.base.colors.navy[900],
|
|
963
1272
|
fontWeight: r.base.fontWeight.semibold
|
|
964
1273
|
},
|
|
965
1274
|
"&:focus-visible": {
|
|
966
|
-
outline: `2px solid ${
|
|
1275
|
+
outline: `2px solid ${o === "dark" ? r.base.colors.coral[400] : r.base.colors.navy[900]}`,
|
|
967
1276
|
outlineOffset: -2
|
|
968
1277
|
}
|
|
969
1278
|
}
|
|
@@ -982,17 +1291,16 @@ function T(r = p, a = "light") {
|
|
|
982
1291
|
padding: "0 4px"
|
|
983
1292
|
},
|
|
984
1293
|
colorPrimary: {
|
|
985
|
-
backgroundColor:
|
|
1294
|
+
backgroundColor: o === "dark" ? r.base.colors.coral[500] : r.base.colors.navy[900]
|
|
986
1295
|
},
|
|
987
|
-
|
|
1296
|
+
// C-15: light keeps the coral fill (its palette label, gray 900, is 7:1 or more); dark
|
|
1297
|
+
// takes palette.secondary and its white label (white on coral[500] was 2.55:1).
|
|
1298
|
+
colorSecondary: o === "dark" ? {} : {
|
|
988
1299
|
backgroundColor: r.base.colors.coral[500]
|
|
989
|
-
},
|
|
990
|
-
colorError: {
|
|
991
|
-
backgroundColor: r.base.colors.coral[600]
|
|
992
|
-
},
|
|
993
|
-
colorSuccess: {
|
|
994
|
-
backgroundColor: r.semantic.colors.status.success.text
|
|
995
1300
|
}
|
|
1301
|
+
// C-15: error and success badges draw MUI's status pair (palette.<status>.main and
|
|
1302
|
+
// contrastText, ADR-03-R7), so no override: coral[600] with white was 2.69:1, and the
|
|
1303
|
+
// fixed light success fill took the dark label in dark mode.
|
|
996
1304
|
}
|
|
997
1305
|
},
|
|
998
1306
|
// ============================================
|
|
@@ -1007,8 +1315,8 @@ function T(r = p, a = "light") {
|
|
|
1007
1315
|
colorDefault: {
|
|
1008
1316
|
// Use navy background in light mode, gray in dark mode
|
|
1009
1317
|
// Always ensure accessible text contrast
|
|
1010
|
-
backgroundColor:
|
|
1011
|
-
color:
|
|
1318
|
+
backgroundColor: o === "dark" ? r.base.colors.gray[600] : r.base.colors.navy[900],
|
|
1319
|
+
color: o === "dark" ? r.base.colors.gray[100] : r.base.colors.gray[0]
|
|
1012
1320
|
// White text on navy for accessibility
|
|
1013
1321
|
}
|
|
1014
1322
|
}
|
|
@@ -1017,7 +1325,7 @@ function T(r = p, a = "light") {
|
|
|
1017
1325
|
styleOverrides: {
|
|
1018
1326
|
root: {
|
|
1019
1327
|
"& .MuiAvatar-root": {
|
|
1020
|
-
borderColor:
|
|
1328
|
+
borderColor: o === "dark" ? r.base.colors.gray[800] : r.base.colors.gray[0],
|
|
1021
1329
|
borderWidth: 2
|
|
1022
1330
|
}
|
|
1023
1331
|
}
|
|
@@ -1049,9 +1357,9 @@ function T(r = p, a = "light") {
|
|
|
1049
1357
|
MuiStepIcon: {
|
|
1050
1358
|
styleOverrides: {
|
|
1051
1359
|
root: {
|
|
1052
|
-
color:
|
|
1360
|
+
color: o === "dark" ? r.base.colors.gray[600] : r.base.colors.gray[300],
|
|
1053
1361
|
"&.Mui-active": {
|
|
1054
|
-
color:
|
|
1362
|
+
color: o === "dark" ? r.base.colors.coral[400] : r.base.colors.navy[900]
|
|
1055
1363
|
},
|
|
1056
1364
|
"&.Mui-completed": {
|
|
1057
1365
|
color: r.semantic.colors.status.success.text
|
|
@@ -1076,10 +1384,10 @@ function T(r = p, a = "light") {
|
|
|
1076
1384
|
root: {
|
|
1077
1385
|
fontWeight: r.base.fontWeight.medium,
|
|
1078
1386
|
"&.Mui-selected": {
|
|
1079
|
-
backgroundColor:
|
|
1387
|
+
backgroundColor: o === "dark" ? r.base.colors.coral[500] : r.base.colors.navy[900],
|
|
1080
1388
|
color: r.base.colors.gray[0],
|
|
1081
1389
|
"&:hover": {
|
|
1082
|
-
backgroundColor:
|
|
1390
|
+
backgroundColor: o === "dark" ? r.base.colors.coral[400] : r.base.colors.coral[800]
|
|
1083
1391
|
}
|
|
1084
1392
|
}
|
|
1085
1393
|
}
|
|
@@ -1095,17 +1403,47 @@ function T(r = p, a = "light") {
|
|
|
1095
1403
|
// @intentional-color: rating star gold — no token equivalent
|
|
1096
1404
|
},
|
|
1097
1405
|
iconEmpty: {
|
|
1098
|
-
color:
|
|
1406
|
+
color: o === "dark" ? r.base.colors.gray[600] : r.base.colors.gray[300]
|
|
1099
1407
|
}
|
|
1100
1408
|
}
|
|
1101
1409
|
},
|
|
1102
1410
|
// ============================================
|
|
1411
|
+
// PROGRESS (C-20 (1), (2))
|
|
1412
|
+
// ============================================
|
|
1413
|
+
// The LinearProgress track is the neutral border.default role for every palette colour, so a
|
|
1414
|
+
// bar meets 3:1 against it (MUI tints the track from the bar colour, which left the light
|
|
1415
|
+
// error, warning and success bars at 2.62-2.89:1). `inherit` keeps MUI's currentColor track
|
|
1416
|
+
// and `buffer` its dashes. Under reduced motion the indeterminate bar stands still at the
|
|
1417
|
+
// inline start, the second bar hides and value changes jump; the circular spinner shows a
|
|
1418
|
+
// static arc. The CssBaseline backstop (E-44+) would only shorten these loops to their last
|
|
1419
|
+
// frame, which for both progress loops is an empty track.
|
|
1420
|
+
MuiLinearProgress: {
|
|
1421
|
+
styleOverrides: {
|
|
1422
|
+
root: ({ ownerState: u, theme: m }) => u.color === "inherit" || u.variant === "buffer" ? null : { backgroundColor: m.palette.trinity?.border.default ?? m.palette.divider },
|
|
1423
|
+
bar1: ({ ownerState: u }) => $(
|
|
1424
|
+
_(u) ? { animation: "none", left: 0, right: "auto", width: "40%" } : { transition: "none" }
|
|
1425
|
+
),
|
|
1426
|
+
bar2: ({ ownerState: u }) => $(_(u) ? { animation: "none", display: "none" } : { transition: "none" }),
|
|
1427
|
+
dashed: $({ animation: "none" })
|
|
1428
|
+
}
|
|
1429
|
+
},
|
|
1430
|
+
MuiCircularProgress: {
|
|
1431
|
+
styleOverrides: {
|
|
1432
|
+
root: $({ animation: "none", transition: "none" }),
|
|
1433
|
+
circle: ({ ownerState: u }) => $(
|
|
1434
|
+
u.variant === "determinate" ? { transition: "none" } : { animation: "none", strokeDasharray: "80px, 200px", strokeDashoffset: 0 }
|
|
1435
|
+
)
|
|
1436
|
+
}
|
|
1437
|
+
},
|
|
1438
|
+
// ============================================
|
|
1103
1439
|
// SKELETON
|
|
1104
1440
|
// ============================================
|
|
1105
1441
|
MuiSkeleton: {
|
|
1106
1442
|
styleOverrides: {
|
|
1107
1443
|
root: {
|
|
1108
|
-
backgroundColor:
|
|
1444
|
+
backgroundColor: o === "dark" ? "rgba(255, 255, 255, 0.11)" : "rgba(0, 0, 0, 0.08)",
|
|
1445
|
+
// C-20 (3): under reduced motion the pulse and the wave stop; the placeholder stays.
|
|
1446
|
+
...$({ animation: "none", "&::after": { animation: "none", display: "none" } })
|
|
1109
1447
|
},
|
|
1110
1448
|
rounded: {
|
|
1111
1449
|
borderRadius: r.base.borderRadius.md
|
|
@@ -1127,7 +1465,7 @@ function T(r = p, a = "light") {
|
|
|
1127
1465
|
MuiSnackbarContent: {
|
|
1128
1466
|
styleOverrides: {
|
|
1129
1467
|
root: {
|
|
1130
|
-
backgroundColor:
|
|
1468
|
+
backgroundColor: o === "dark" ? r.base.colors.gray[700] : r.base.colors.gray[900],
|
|
1131
1469
|
color: r.base.colors.gray[0],
|
|
1132
1470
|
borderRadius: r.base.borderRadius.md,
|
|
1133
1471
|
boxShadow: "0 10px 15px -3px rgb(0 0 0 / 0.2), 0 4px 6px -4px rgb(0 0 0 / 0.2)"
|
|
@@ -1140,17 +1478,17 @@ function T(r = p, a = "light") {
|
|
|
1140
1478
|
MuiBreadcrumbs: {
|
|
1141
1479
|
styleOverrides: {
|
|
1142
1480
|
separator: {
|
|
1143
|
-
color:
|
|
1481
|
+
color: o === "dark" ? r.base.colors.gray[500] : r.base.colors.gray[400]
|
|
1144
1482
|
},
|
|
1145
1483
|
li: {
|
|
1146
1484
|
"& .MuiLink-root": {
|
|
1147
|
-
color:
|
|
1485
|
+
color: o === "dark" ? r.base.colors.gray[400] : r.base.colors.gray[600],
|
|
1148
1486
|
"&:hover": {
|
|
1149
|
-
color:
|
|
1487
|
+
color: o === "dark" ? r.base.colors.coral[400] : r.base.colors.navy[900]
|
|
1150
1488
|
}
|
|
1151
1489
|
},
|
|
1152
1490
|
"& .MuiTypography-root": {
|
|
1153
|
-
color:
|
|
1491
|
+
color: o === "dark" ? r.base.colors.gray[200] : r.base.colors.gray[900]
|
|
1154
1492
|
}
|
|
1155
1493
|
}
|
|
1156
1494
|
}
|
|
@@ -1161,7 +1499,7 @@ function T(r = p, a = "light") {
|
|
|
1161
1499
|
MuiTooltip: {
|
|
1162
1500
|
styleOverrides: {
|
|
1163
1501
|
tooltip: {
|
|
1164
|
-
backgroundColor:
|
|
1502
|
+
backgroundColor: o === "dark" ? r.base.colors.gray[700] : r.base.colors.gray[900],
|
|
1165
1503
|
color: r.base.colors.gray[0],
|
|
1166
1504
|
fontSize: r.base.fontSize.xs,
|
|
1167
1505
|
fontWeight: r.base.fontWeight.medium,
|
|
@@ -1169,7 +1507,7 @@ function T(r = p, a = "light") {
|
|
|
1169
1507
|
borderRadius: r.base.borderRadius.sm
|
|
1170
1508
|
},
|
|
1171
1509
|
arrow: {
|
|
1172
|
-
color:
|
|
1510
|
+
color: o === "dark" ? r.base.colors.gray[700] : r.base.colors.gray[900]
|
|
1173
1511
|
}
|
|
1174
1512
|
}
|
|
1175
1513
|
},
|
|
@@ -1180,70 +1518,112 @@ function T(r = p, a = "light") {
|
|
|
1180
1518
|
styleOverrides: {
|
|
1181
1519
|
root: {
|
|
1182
1520
|
"&:focus-visible": {
|
|
1183
|
-
outline:
|
|
1184
|
-
outlineOffset:
|
|
1521
|
+
outline: `${p.outlineWidth}px ${p.outlineStyle} ${p.outlineColor}`,
|
|
1522
|
+
outlineOffset: p.outlineOffset
|
|
1185
1523
|
}
|
|
1186
1524
|
}
|
|
1187
1525
|
}
|
|
1188
1526
|
}
|
|
1189
1527
|
};
|
|
1190
1528
|
}
|
|
1191
|
-
function
|
|
1529
|
+
function Er(r) {
|
|
1192
1530
|
const {
|
|
1193
|
-
mode:
|
|
1194
|
-
direction:
|
|
1195
|
-
name:
|
|
1531
|
+
mode: o,
|
|
1532
|
+
direction: s = "ltr",
|
|
1533
|
+
name: a = "custom",
|
|
1196
1534
|
tokens: e,
|
|
1197
|
-
palette:
|
|
1198
|
-
components:
|
|
1199
|
-
typography:
|
|
1200
|
-
shape:
|
|
1201
|
-
config:
|
|
1202
|
-
} = r,
|
|
1535
|
+
palette: c,
|
|
1536
|
+
components: i,
|
|
1537
|
+
typography: g,
|
|
1538
|
+
shape: y,
|
|
1539
|
+
config: p = {}
|
|
1540
|
+
} = r, n = ar(o, e, s), b = X(n, {
|
|
1541
|
+
...c && { palette: c },
|
|
1542
|
+
...i && {
|
|
1543
|
+
components: i
|
|
1544
|
+
},
|
|
1545
|
+
...g && { typography: g },
|
|
1546
|
+
...y && { shape: y }
|
|
1547
|
+
});
|
|
1203
1548
|
return {
|
|
1204
|
-
theme:
|
|
1205
|
-
|
|
1206
|
-
|
|
1207
|
-
|
|
1208
|
-
typography: n,
|
|
1209
|
-
shape: t
|
|
1210
|
-
}),
|
|
1211
|
-
name: s,
|
|
1212
|
-
mode: a,
|
|
1213
|
-
config: c
|
|
1549
|
+
theme: Y(b),
|
|
1550
|
+
name: a,
|
|
1551
|
+
mode: o,
|
|
1552
|
+
config: p
|
|
1214
1553
|
};
|
|
1215
1554
|
}
|
|
1216
|
-
function
|
|
1217
|
-
|
|
1555
|
+
function or(r, o, s = "ltr") {
|
|
1556
|
+
return Y(X(ar(r, o, s)));
|
|
1557
|
+
}
|
|
1558
|
+
function ar(r, o, s = "ltr") {
|
|
1559
|
+
const a = W(o), e = a.darkMode.colors.status ?? a.semantic.colors.status, c = a.semantic.colors.surface, i = a.darkMode.effects ?? K, g = a.darkMode.colors.interactive ?? {
|
|
1560
|
+
default: a.base.colors.purple[400],
|
|
1561
|
+
hover: a.base.colors.coral[400],
|
|
1562
|
+
active: a.base.colors.indigo[400],
|
|
1563
|
+
disabled: a.base.colors.gray[600],
|
|
1564
|
+
focus: a.base.colors.purple[400]
|
|
1565
|
+
}, y = F(a.semantic.colors), p = H.colors.ai, n = (x, M) => {
|
|
1566
|
+
const R = x ?? M;
|
|
1567
|
+
return {
|
|
1568
|
+
...R,
|
|
1569
|
+
presence: { ...R.presence ?? M.presence },
|
|
1570
|
+
avatarFill: { ...R.avatarFill ?? M.avatarFill },
|
|
1571
|
+
progress: R.progress ?? M.progress,
|
|
1572
|
+
canvasFill: { ...R.canvasFill ?? M.canvasFill }
|
|
1573
|
+
};
|
|
1574
|
+
}, b = F({ status: e }), t = (x, M) => ({
|
|
1575
|
+
error: { main: x.error.text, contrastText: M.error },
|
|
1576
|
+
warning: { main: x.warning.text, contrastText: M.warning },
|
|
1577
|
+
success: { main: x.success.text, contrastText: M.success },
|
|
1578
|
+
info: { main: x.info.text, contrastText: M.info }
|
|
1579
|
+
}), h = (x) => ({
|
|
1580
|
+
hover: x.hover,
|
|
1581
|
+
hoverSubtle: x.hoverSubtle,
|
|
1582
|
+
pressed: x.pressed,
|
|
1583
|
+
selected: x.selected
|
|
1584
|
+
}), u = a.semantic.colors.indicator ?? z.colors.indicator, m = r === "dark" ? N(u, a.darkMode.colors.indicator ?? H.colors.indicator, {
|
|
1585
|
+
error: e.error.text,
|
|
1586
|
+
warning: e.warning.text,
|
|
1587
|
+
success: e.success.text,
|
|
1588
|
+
info: e.info.text,
|
|
1589
|
+
neutral: a.darkMode.colors.text.secondary,
|
|
1590
|
+
progress: a.darkMode.colors.text.brand ?? a.base.colors.navy[100],
|
|
1591
|
+
beta: a.base.colors.indigo[200]
|
|
1592
|
+
}) : N(u), w = (x, M) => {
|
|
1593
|
+
const [R, L] = x.split("."), V = a.semantic.colors[R][L], er = z.colors[R][L];
|
|
1594
|
+
return V !== er ? V : M;
|
|
1595
|
+
}, k = r === "dark" ? {
|
|
1218
1596
|
mode: "dark",
|
|
1219
|
-
primary: { main:
|
|
1220
|
-
secondary: { main:
|
|
1597
|
+
primary: { main: a.base.colors.coral[600], ...a.base.colors.coral },
|
|
1598
|
+
secondary: { main: a.base.colors.purple[500], ...a.base.colors.purple },
|
|
1599
|
+
// Buttons on navy brand surfaces (color="onBrand"): the same values as light mode.
|
|
1600
|
+
onBrand: U(a),
|
|
1601
|
+
...t(
|
|
1602
|
+
e,
|
|
1603
|
+
a.darkMode.colors.onStatus ?? H.colors.onStatus
|
|
1604
|
+
),
|
|
1221
1605
|
background: {
|
|
1222
|
-
default:
|
|
1223
|
-
paper:
|
|
1606
|
+
default: a.darkMode.colors.background.primary,
|
|
1607
|
+
paper: a.darkMode.colors.surface?.elevated ?? a.darkMode.colors.background.secondary
|
|
1224
1608
|
},
|
|
1225
1609
|
text: {
|
|
1226
|
-
primary:
|
|
1227
|
-
secondary:
|
|
1228
|
-
disabled:
|
|
1610
|
+
primary: a.darkMode.colors.text.primary,
|
|
1611
|
+
secondary: a.darkMode.colors.text.secondary,
|
|
1612
|
+
disabled: a.darkMode.colors.text.disabled
|
|
1229
1613
|
},
|
|
1230
1614
|
divider: "rgba(255, 255, 255, 0.12)",
|
|
1231
1615
|
action: {
|
|
1232
|
-
active:
|
|
1616
|
+
active: a.base.colors.gray[100],
|
|
1233
1617
|
hover: "rgba(255, 255, 255, 0.08)",
|
|
1234
|
-
selected
|
|
1235
|
-
|
|
1618
|
+
// The overlay.selected token (C-27, M5 decision 15 (a)): React and the CSS package
|
|
1619
|
+
// (--trinity-overlay-selected) draw the same selected background; was a 0.16 literal.
|
|
1620
|
+
selected: i.overlay.selected,
|
|
1621
|
+
disabled: a.base.colors.gray[600],
|
|
1236
1622
|
disabledBackground: "rgba(255, 255, 255, 0.12)"
|
|
1237
1623
|
},
|
|
1238
1624
|
// Trinity-specific semantic colors (dark mode)
|
|
1239
1625
|
trinity: {
|
|
1240
|
-
interactive:
|
|
1241
|
-
default: s.base.colors.coral[400],
|
|
1242
|
-
hover: s.base.colors.coral[300],
|
|
1243
|
-
active: s.base.colors.coral[500],
|
|
1244
|
-
disabled: s.base.colors.gray[600],
|
|
1245
|
-
focus: s.base.colors.purple[400]
|
|
1246
|
-
},
|
|
1626
|
+
interactive: g,
|
|
1247
1627
|
status: {
|
|
1248
1628
|
success: { text: e.success.text, background: e.success.background, border: e.success.border },
|
|
1249
1629
|
warning: { text: e.warning.text, background: e.warning.background, border: e.warning.border },
|
|
@@ -1251,245 +1631,320 @@ function v(r, a, o = "ltr") {
|
|
|
1251
1631
|
info: { text: e.info.text, background: e.info.background, border: e.info.border }
|
|
1252
1632
|
},
|
|
1253
1633
|
border: {
|
|
1254
|
-
default:
|
|
1255
|
-
subtle:
|
|
1256
|
-
strong:
|
|
1257
|
-
|
|
1634
|
+
default: a.darkMode.colors.border.default,
|
|
1635
|
+
subtle: a.darkMode.colors.border.subtle,
|
|
1636
|
+
strong: a.darkMode.colors.border.strong,
|
|
1637
|
+
focus: a.darkMode.colors.border.focus ?? g.focus
|
|
1638
|
+
},
|
|
1639
|
+
surface: {
|
|
1640
|
+
elevated: a.darkMode.colors.surface?.elevated ?? a.darkMode.colors.background.secondary,
|
|
1641
|
+
sunken: a.darkMode.colors.surface?.sunken ?? a.darkMode.colors.background.primary,
|
|
1642
|
+
subtle: a.darkMode.colors.background.secondary,
|
|
1643
|
+
neutralFill: a.darkMode.colors.surface?.neutralFill ?? H.colors.surface?.neutralFill ?? a.base.colors.gray[600]
|
|
1644
|
+
},
|
|
1645
|
+
overlay: h(i.overlay),
|
|
1646
|
+
state: { ...i.state },
|
|
1647
|
+
confidence: b.confidence,
|
|
1648
|
+
verification: b.verification,
|
|
1649
|
+
ai: n(a.darkMode.colors.ai, p),
|
|
1650
|
+
indicator: m,
|
|
1651
|
+
// ADR-03-R10: resolveTrinityTokens keeps the dark favorite equal to the dark
|
|
1652
|
+
// status.warning.text unless it is overridden.
|
|
1653
|
+
favorite: a.darkMode.colors.favorite ?? e.warning.text
|
|
1258
1654
|
}
|
|
1259
1655
|
} : {
|
|
1260
1656
|
mode: "light",
|
|
1261
|
-
primary: { main:
|
|
1262
|
-
secondary: { main:
|
|
1657
|
+
primary: { main: a.base.colors.navy[900], ...a.base.colors.navy },
|
|
1658
|
+
secondary: { main: a.base.colors.coral[800], ...a.base.colors.coral },
|
|
1659
|
+
// Buttons on navy brand surfaces (color="onBrand"): the same values as dark mode.
|
|
1660
|
+
onBrand: U(a),
|
|
1661
|
+
...t(
|
|
1662
|
+
a.semantic.colors.status,
|
|
1663
|
+
a.semantic.colors.onStatus ?? z.colors.onStatus
|
|
1664
|
+
),
|
|
1263
1665
|
background: {
|
|
1264
|
-
default:
|
|
1265
|
-
paper:
|
|
1666
|
+
default: a.base.colors.gray[50],
|
|
1667
|
+
paper: a.base.colors.gray[0]
|
|
1266
1668
|
},
|
|
1267
1669
|
text: {
|
|
1268
|
-
primary:
|
|
1269
|
-
secondary:
|
|
1270
|
-
disabled:
|
|
1670
|
+
primary: a.base.colors.gray[900],
|
|
1671
|
+
secondary: a.base.colors.gray[600],
|
|
1672
|
+
disabled: a.base.colors.gray[400]
|
|
1271
1673
|
},
|
|
1272
|
-
divider:
|
|
1674
|
+
divider: a.base.colors.gray[200],
|
|
1273
1675
|
action: {
|
|
1274
|
-
active:
|
|
1676
|
+
active: a.base.colors.gray[700],
|
|
1275
1677
|
hover: "rgba(0, 0, 0, 0.04)",
|
|
1276
|
-
selected:
|
|
1277
|
-
|
|
1278
|
-
|
|
1678
|
+
selected: a.semantic.effects.overlay.selected,
|
|
1679
|
+
// C-27: the token (same value)
|
|
1680
|
+
disabled: a.base.colors.gray[400],
|
|
1681
|
+
disabledBackground: a.base.colors.gray[200]
|
|
1279
1682
|
},
|
|
1280
1683
|
// Trinity-specific semantic colors (light mode)
|
|
1281
1684
|
trinity: {
|
|
1685
|
+
// The semantic interactive and border roles (E-43+, M4 lane-1 finding 3): a semantic
|
|
1686
|
+
// override wins, and a role left at its default reads its base source, so a base
|
|
1687
|
+
// override still reaches it. Interactive is value-neutral; the borders move from gray
|
|
1688
|
+
// 200/100/400 to the semantic 300/200/500, the values the CSS package already ships.
|
|
1282
1689
|
interactive: {
|
|
1283
|
-
default:
|
|
1284
|
-
hover:
|
|
1285
|
-
active:
|
|
1286
|
-
disabled:
|
|
1287
|
-
focus:
|
|
1690
|
+
default: w("interactive.default", a.base.colors.navy[900]),
|
|
1691
|
+
hover: w("interactive.hover", a.base.colors.coral[800]),
|
|
1692
|
+
active: w("interactive.active", a.base.colors.indigo[900]),
|
|
1693
|
+
disabled: w("interactive.disabled", a.base.colors.gray[300]),
|
|
1694
|
+
focus: w("interactive.focus", a.base.colors.purple[700])
|
|
1288
1695
|
},
|
|
1289
1696
|
status: {
|
|
1290
|
-
success: { text:
|
|
1291
|
-
warning: { text:
|
|
1292
|
-
error: { text:
|
|
1293
|
-
info: { text:
|
|
1697
|
+
success: { text: a.semantic.colors.status.success.text, background: a.semantic.colors.status.success.background, border: a.semantic.colors.status.success.border },
|
|
1698
|
+
warning: { text: a.semantic.colors.status.warning.text, background: a.semantic.colors.status.warning.background, border: a.semantic.colors.status.warning.border },
|
|
1699
|
+
error: { text: a.semantic.colors.status.error.text, background: a.semantic.colors.status.error.background, border: a.semantic.colors.status.error.border },
|
|
1700
|
+
info: { text: a.semantic.colors.status.info.text, background: a.semantic.colors.status.info.background, border: a.semantic.colors.status.info.border }
|
|
1294
1701
|
},
|
|
1295
1702
|
border: {
|
|
1296
|
-
default:
|
|
1297
|
-
subtle:
|
|
1298
|
-
strong:
|
|
1299
|
-
|
|
1703
|
+
default: w("border.default", a.base.colors.gray[300]),
|
|
1704
|
+
subtle: w("border.subtle", a.base.colors.gray[200]),
|
|
1705
|
+
strong: w("border.strong", a.base.colors.gray[500]),
|
|
1706
|
+
focus: a.semantic.colors.border.focus
|
|
1707
|
+
},
|
|
1708
|
+
surface: {
|
|
1709
|
+
elevated: c.elevated,
|
|
1710
|
+
sunken: c.sunken,
|
|
1711
|
+
subtle: a.semantic.colors.background.secondary,
|
|
1712
|
+
neutralFill: c.neutralFill
|
|
1713
|
+
},
|
|
1714
|
+
overlay: h(a.semantic.effects.overlay),
|
|
1715
|
+
state: { ...a.semantic.effects.state },
|
|
1716
|
+
confidence: y.confidence,
|
|
1717
|
+
verification: y.verification,
|
|
1718
|
+
ai: n(a.semantic.colors.ai, z.colors.ai),
|
|
1719
|
+
indicator: m,
|
|
1720
|
+
// ADR-03-R10: resolveTrinityTokens keeps it equal to status.warning.text unless it is
|
|
1721
|
+
// overridden; a token set without it falls back to that role.
|
|
1722
|
+
favorite: a.semantic.colors.favorite ?? a.semantic.colors.status.warning.text
|
|
1300
1723
|
}
|
|
1301
|
-
},
|
|
1724
|
+
}, sr = {
|
|
1302
1725
|
fontFamily: '"Montserrat", sans-serif',
|
|
1303
1726
|
// Button text style
|
|
1304
1727
|
button: {
|
|
1305
1728
|
textTransform: "none",
|
|
1306
|
-
fontWeight:
|
|
1729
|
+
fontWeight: a.base.fontWeight.semibold
|
|
1307
1730
|
},
|
|
1308
1731
|
// Hierarchy-based typography variants
|
|
1309
1732
|
// Display variants (Level 1 - Hero/Marketing)
|
|
1310
1733
|
h1: {
|
|
1311
|
-
fontSize:
|
|
1312
|
-
fontWeight:
|
|
1313
|
-
lineHeight:
|
|
1314
|
-
color: r === "dark" ?
|
|
1734
|
+
fontSize: l.heading.scale.h1.size,
|
|
1735
|
+
fontWeight: l.heading.scale.h1.weight,
|
|
1736
|
+
lineHeight: l.heading.scale.h1.lineHeight,
|
|
1737
|
+
color: r === "dark" ? a.darkMode.colors.text.primary : a.semantic.colors.text.primary
|
|
1315
1738
|
},
|
|
1316
1739
|
h2: {
|
|
1317
|
-
fontSize:
|
|
1318
|
-
fontWeight:
|
|
1319
|
-
lineHeight:
|
|
1320
|
-
color: r === "dark" ?
|
|
1740
|
+
fontSize: l.heading.scale.h2.size,
|
|
1741
|
+
fontWeight: l.heading.scale.h2.weight,
|
|
1742
|
+
lineHeight: l.heading.scale.h2.lineHeight,
|
|
1743
|
+
color: r === "dark" ? a.darkMode.colors.text.primary : a.semantic.colors.text.primary
|
|
1321
1744
|
},
|
|
1322
1745
|
h3: {
|
|
1323
|
-
fontSize:
|
|
1324
|
-
fontWeight:
|
|
1325
|
-
lineHeight:
|
|
1326
|
-
color: r === "dark" ?
|
|
1746
|
+
fontSize: l.heading.scale.h3.size,
|
|
1747
|
+
fontWeight: l.heading.scale.h3.weight,
|
|
1748
|
+
lineHeight: l.heading.scale.h3.lineHeight,
|
|
1749
|
+
color: r === "dark" ? a.darkMode.colors.text.primary : a.semantic.colors.text.primary
|
|
1327
1750
|
},
|
|
1328
1751
|
h4: {
|
|
1329
|
-
fontSize:
|
|
1330
|
-
fontWeight:
|
|
1331
|
-
lineHeight:
|
|
1332
|
-
color: r === "dark" ?
|
|
1752
|
+
fontSize: l.heading.scale.h4.size,
|
|
1753
|
+
fontWeight: l.heading.scale.h4.weight,
|
|
1754
|
+
lineHeight: l.heading.scale.h4.lineHeight,
|
|
1755
|
+
color: r === "dark" ? a.darkMode.colors.text.primary : a.semantic.colors.text.secondary
|
|
1333
1756
|
},
|
|
1334
1757
|
h5: {
|
|
1335
|
-
fontSize:
|
|
1336
|
-
fontWeight:
|
|
1337
|
-
lineHeight:
|
|
1338
|
-
color: r === "dark" ?
|
|
1758
|
+
fontSize: l.heading.scale.h5.size,
|
|
1759
|
+
fontWeight: l.heading.scale.h5.weight,
|
|
1760
|
+
lineHeight: l.heading.scale.h5.lineHeight,
|
|
1761
|
+
color: r === "dark" ? a.darkMode.colors.text.secondary : a.semantic.colors.text.secondary
|
|
1339
1762
|
},
|
|
1340
1763
|
h6: {
|
|
1341
|
-
fontSize:
|
|
1342
|
-
fontWeight:
|
|
1343
|
-
lineHeight:
|
|
1344
|
-
color: r === "dark" ?
|
|
1764
|
+
fontSize: l.heading.scale.h6.size,
|
|
1765
|
+
fontWeight: l.heading.scale.h6.weight,
|
|
1766
|
+
lineHeight: l.heading.scale.h6.lineHeight,
|
|
1767
|
+
color: r === "dark" ? a.darkMode.colors.text.secondary : a.semantic.colors.text.secondary
|
|
1345
1768
|
},
|
|
1346
1769
|
// Body variants (Level 3 - Content)
|
|
1347
1770
|
body1: {
|
|
1348
|
-
fontSize:
|
|
1349
|
-
fontWeight:
|
|
1350
|
-
lineHeight:
|
|
1351
|
-
color: r === "dark" ?
|
|
1771
|
+
fontSize: l.body.scale.medium.size,
|
|
1772
|
+
fontWeight: l.body.scale.medium.weight,
|
|
1773
|
+
lineHeight: l.body.scale.medium.lineHeight,
|
|
1774
|
+
color: r === "dark" ? a.darkMode.colors.text.primary : a.semantic.colors.text.primary
|
|
1352
1775
|
},
|
|
1353
1776
|
body2: {
|
|
1354
|
-
fontSize:
|
|
1355
|
-
fontWeight:
|
|
1356
|
-
lineHeight:
|
|
1357
|
-
color: r === "dark" ?
|
|
1777
|
+
fontSize: l.body.scale.small.size,
|
|
1778
|
+
fontWeight: l.body.scale.small.weight,
|
|
1779
|
+
lineHeight: l.body.scale.small.lineHeight,
|
|
1780
|
+
color: r === "dark" ? a.darkMode.colors.text.secondary : a.semantic.colors.text.secondary
|
|
1358
1781
|
},
|
|
1359
1782
|
// Supporting text variants
|
|
1360
1783
|
subtitle1: {
|
|
1361
|
-
fontSize:
|
|
1362
|
-
fontWeight:
|
|
1363
|
-
lineHeight:
|
|
1364
|
-
color: r === "dark" ?
|
|
1784
|
+
fontSize: l.label.scale.large.size,
|
|
1785
|
+
fontWeight: l.label.scale.large.weight,
|
|
1786
|
+
lineHeight: l.label.scale.large.lineHeight,
|
|
1787
|
+
color: r === "dark" ? a.darkMode.colors.text.primary : a.semantic.colors.text.primary
|
|
1365
1788
|
},
|
|
1366
1789
|
subtitle2: {
|
|
1367
|
-
fontSize:
|
|
1368
|
-
fontWeight:
|
|
1369
|
-
lineHeight:
|
|
1370
|
-
color: r === "dark" ?
|
|
1790
|
+
fontSize: l.label.scale.medium.size,
|
|
1791
|
+
fontWeight: l.label.scale.medium.weight,
|
|
1792
|
+
lineHeight: l.label.scale.medium.lineHeight,
|
|
1793
|
+
color: r === "dark" ? a.darkMode.colors.text.secondary : a.semantic.colors.text.secondary
|
|
1371
1794
|
},
|
|
1372
1795
|
caption: {
|
|
1373
|
-
fontSize:
|
|
1374
|
-
fontWeight:
|
|
1375
|
-
lineHeight:
|
|
1376
|
-
|
|
1796
|
+
fontSize: l.caption.scale.default.size,
|
|
1797
|
+
fontWeight: l.caption.scale.default.weight,
|
|
1798
|
+
lineHeight: l.caption.scale.default.lineHeight,
|
|
1799
|
+
// Light reads text.secondary, not text.tertiary (2.54:1 on white): E-35, OD-E12 option A.
|
|
1800
|
+
// text.tertiary stays a disabled or decorative role until Step 7 re-derives it (L-01).
|
|
1801
|
+
color: r === "dark" ? a.darkMode.colors.text.tertiary : a.semantic.colors.text.secondary
|
|
1377
1802
|
},
|
|
1378
1803
|
overline: {
|
|
1379
|
-
fontSize:
|
|
1380
|
-
fontWeight:
|
|
1381
|
-
lineHeight:
|
|
1382
|
-
letterSpacing:
|
|
1804
|
+
fontSize: l.overline.scale.default.size,
|
|
1805
|
+
fontWeight: l.overline.scale.default.weight,
|
|
1806
|
+
lineHeight: l.overline.scale.default.lineHeight,
|
|
1807
|
+
letterSpacing: l.overline.scale.default.tracking,
|
|
1383
1808
|
textTransform: "uppercase",
|
|
1384
|
-
|
|
1809
|
+
// As caption (E-35).
|
|
1810
|
+
color: r === "dark" ? a.darkMode.colors.text.tertiary : a.semantic.colors.text.secondary
|
|
1385
1811
|
}
|
|
1386
1812
|
};
|
|
1387
|
-
return
|
|
1388
|
-
direction:
|
|
1389
|
-
palette:
|
|
1390
|
-
typography:
|
|
1813
|
+
return {
|
|
1814
|
+
direction: s,
|
|
1815
|
+
palette: k,
|
|
1816
|
+
typography: sr,
|
|
1391
1817
|
shape: {
|
|
1392
|
-
borderRadius:
|
|
1818
|
+
borderRadius: a.base.borderRadius.md
|
|
1393
1819
|
// 8px base - components override as needed
|
|
1394
1820
|
},
|
|
1395
|
-
|
|
1396
|
-
|
|
1821
|
+
// theme.transitions read the motion tokens where MUI's default equals one (E-44+); the
|
|
1822
|
+
// other MUI values stay (themeTransitions in src/components/shared/motion.ts lists them).
|
|
1823
|
+
transitions: lr(a.semantic.motion),
|
|
1824
|
+
components: Br(a, r, {
|
|
1825
|
+
interactive: k.trinity.interactive.default,
|
|
1826
|
+
selected: k.action.selected,
|
|
1827
|
+
textBrand: r === "dark" ? a.darkMode.colors.text.brand ?? a.base.colors.navy[100] : a.semantic.colors.text.brand,
|
|
1828
|
+
textPrimary: k.text.primary
|
|
1829
|
+
}),
|
|
1830
|
+
// The resolved token set, kept on the theme as theme.trinityTokens (OD-E16): the token hook
|
|
1831
|
+
// and the runtime CSS functions read the same values as the palette.
|
|
1832
|
+
trinityTokens: a
|
|
1833
|
+
};
|
|
1397
1834
|
}
|
|
1398
|
-
const
|
|
1835
|
+
const v = {
|
|
1399
1836
|
primary: {
|
|
1400
|
-
main:
|
|
1401
|
-
|
|
1402
|
-
|
|
1403
|
-
// Light Violet/Purple
|
|
1404
|
-
dark: "#3816A0"
|
|
1405
|
-
// Deep Indigo
|
|
1837
|
+
main: f.colors.navy[900],
|
|
1838
|
+
light: f.colors.purple[700],
|
|
1839
|
+
dark: f.colors.indigo[900]
|
|
1406
1840
|
},
|
|
1407
1841
|
secondary: {
|
|
1408
|
-
main:
|
|
1409
|
-
|
|
1410
|
-
|
|
1411
|
-
// Azure
|
|
1412
|
-
dark: "#6B12ED"
|
|
1413
|
-
// Electric Indigo
|
|
1842
|
+
main: f.colors.coral[800],
|
|
1843
|
+
light: f.colors.azure[500],
|
|
1844
|
+
dark: f.colors.indigo.electric
|
|
1414
1845
|
},
|
|
1415
1846
|
neutral: {
|
|
1416
|
-
white:
|
|
1417
|
-
lightGray:
|
|
1418
|
-
gray100:
|
|
1419
|
-
gray400:
|
|
1420
|
-
gray500:
|
|
1421
|
-
gray600:
|
|
1422
|
-
darkBg:
|
|
1423
|
-
darkPaper:
|
|
1847
|
+
white: f.colors.gray[0],
|
|
1848
|
+
lightGray: f.colors.gray[50],
|
|
1849
|
+
gray100: f.colors.gray[200],
|
|
1850
|
+
gray400: f.colors.gray[400],
|
|
1851
|
+
gray500: f.colors.gray[500],
|
|
1852
|
+
gray600: f.colors.gray[600],
|
|
1853
|
+
darkBg: f.colors.gray[800],
|
|
1854
|
+
darkPaper: f.colors.gray[700]
|
|
1424
1855
|
}
|
|
1425
|
-
},
|
|
1856
|
+
}, Lr = {
|
|
1426
1857
|
// White text on colored backgrounds
|
|
1427
|
-
whiteOnNavy: { text:
|
|
1428
|
-
whiteOnPurple: { text:
|
|
1858
|
+
whiteOnNavy: { text: v.neutral.white, bg: v.primary.main },
|
|
1859
|
+
whiteOnPurple: { text: v.neutral.white, bg: v.primary.light },
|
|
1429
1860
|
// Navy text on light backgrounds
|
|
1430
|
-
navyOnWhite: { text:
|
|
1431
|
-
navyOnCoral: { text:
|
|
1432
|
-
navyOnAzure: { text:
|
|
1861
|
+
navyOnWhite: { text: v.primary.main, bg: v.neutral.white },
|
|
1862
|
+
navyOnCoral: { text: v.primary.main, bg: v.secondary.main },
|
|
1863
|
+
navyOnAzure: { text: v.primary.main, bg: v.secondary.light },
|
|
1433
1864
|
// Purple text on white background
|
|
1434
|
-
purpleOnWhite: { text:
|
|
1865
|
+
purpleOnWhite: { text: v.primary.light, bg: v.neutral.white },
|
|
1435
1866
|
// Accent colors on navy background
|
|
1436
|
-
coralOnNavy: { text:
|
|
1437
|
-
azureOnNavy: { text:
|
|
1438
|
-
},
|
|
1439
|
-
function
|
|
1440
|
-
|
|
1441
|
-
|
|
1442
|
-
|
|
1443
|
-
|
|
1444
|
-
|
|
1445
|
-
|
|
1446
|
-
|
|
1447
|
-
|
|
1448
|
-
|
|
1449
|
-
|
|
1450
|
-
|
|
1451
|
-
|
|
1452
|
-
|
|
1453
|
-
|
|
1454
|
-
|
|
1455
|
-
|
|
1456
|
-
|
|
1457
|
-
|
|
1458
|
-
|
|
1459
|
-
|
|
1460
|
-
|
|
1461
|
-
|
|
1462
|
-
|
|
1867
|
+
coralOnNavy: { text: v.secondary.main, bg: v.primary.main },
|
|
1868
|
+
azureOnNavy: { text: v.secondary.light, bg: v.primary.main }
|
|
1869
|
+
}, Vr = /* @__PURE__ */ or("light"), Fr = /* @__PURE__ */ or("dark"), Z = /* @__PURE__ */ new Set();
|
|
1870
|
+
function Tr(r) {
|
|
1871
|
+
process.env.NODE_ENV !== "production" && (Z.has(r) || (Z.add(r), console.warn(`[Trinity] useTrinityTokens().getSemanticColor: no semantic color at "${r}".`)));
|
|
1872
|
+
}
|
|
1873
|
+
function q(r, o, s) {
|
|
1874
|
+
return [o, ...s].reduce(
|
|
1875
|
+
(a, e) => a && typeof a == "object" ? a[e] : void 0,
|
|
1876
|
+
r
|
|
1877
|
+
);
|
|
1878
|
+
}
|
|
1879
|
+
function Nr() {
|
|
1880
|
+
const r = ir(), o = r.palette.mode, s = o === "dark", a = r.trinityTokens ?? T;
|
|
1881
|
+
return mr(() => {
|
|
1882
|
+
const e = (t, h) => s && h ? h : t, c = (t, h) => {
|
|
1883
|
+
const u = h.split(".");
|
|
1884
|
+
if (s) {
|
|
1885
|
+
const w = q(a.darkMode.colors, t, u);
|
|
1886
|
+
if (typeof w == "string") return w;
|
|
1887
|
+
}
|
|
1888
|
+
const m = q(a.semantic.colors, t, u);
|
|
1889
|
+
return typeof m == "string" ? m : (Tr(`${t}.${h}`), "");
|
|
1890
|
+
}, i = (t) => a.base.spacing[t], g = (t) => `${a.base.spacing[t]}px`, y = (t) => a.base.borderRadius[t], p = (t) => s ? (a.darkMode.shadows?.scale ?? D)[t] : a.base.shadows[t], n = (t) => (a.darkMode.shadows?.glow ?? D.glow)[t], b = (t, h) => {
|
|
1891
|
+
if (s) {
|
|
1892
|
+
const m = (a.darkMode.effects ?? K)[t];
|
|
1893
|
+
if (m[h] !== void 0) return m[h];
|
|
1894
|
+
}
|
|
1895
|
+
return a.semantic.effects[t][h] ?? "";
|
|
1896
|
+
};
|
|
1897
|
+
return {
|
|
1898
|
+
tokens: a,
|
|
1899
|
+
base: a.base,
|
|
1900
|
+
semantic: a.semantic,
|
|
1901
|
+
component: a.component,
|
|
1902
|
+
darkMode: a.darkMode,
|
|
1903
|
+
mode: o,
|
|
1904
|
+
isDarkMode: s,
|
|
1905
|
+
getColor: e,
|
|
1906
|
+
getSemanticColor: c,
|
|
1907
|
+
spacing: i,
|
|
1908
|
+
spacingCss: g,
|
|
1909
|
+
radius: y,
|
|
1910
|
+
shadow: p,
|
|
1911
|
+
glow: n,
|
|
1912
|
+
effect: b
|
|
1913
|
+
};
|
|
1914
|
+
}, [s, o, a]);
|
|
1463
1915
|
}
|
|
1464
1916
|
export {
|
|
1465
|
-
|
|
1466
|
-
|
|
1467
|
-
|
|
1468
|
-
|
|
1469
|
-
|
|
1470
|
-
|
|
1471
|
-
|
|
1472
|
-
|
|
1473
|
-
|
|
1474
|
-
|
|
1475
|
-
|
|
1476
|
-
|
|
1477
|
-
|
|
1478
|
-
|
|
1479
|
-
|
|
1480
|
-
|
|
1481
|
-
|
|
1482
|
-
|
|
1483
|
-
|
|
1484
|
-
|
|
1485
|
-
|
|
1486
|
-
|
|
1487
|
-
|
|
1488
|
-
|
|
1489
|
-
|
|
1490
|
-
|
|
1491
|
-
|
|
1492
|
-
|
|
1493
|
-
|
|
1494
|
-
|
|
1917
|
+
Lr as accessibleCombinations,
|
|
1918
|
+
_r as attentionHierarchy,
|
|
1919
|
+
f as baseTokens,
|
|
1920
|
+
v as brandColors,
|
|
1921
|
+
j as componentTokens,
|
|
1922
|
+
Ur as contrastHierarchy,
|
|
1923
|
+
or as createTrinityTheme,
|
|
1924
|
+
Er as createTrinityThemePreset,
|
|
1925
|
+
K as darkModeEffects,
|
|
1926
|
+
D as darkModeShadows,
|
|
1927
|
+
H as darkModeTokens,
|
|
1928
|
+
Fr as darkTheme,
|
|
1929
|
+
Zr as elevationHierarchy,
|
|
1930
|
+
Mr as generateCssVariables,
|
|
1931
|
+
Wr as generateDarkModeCssVariables,
|
|
1932
|
+
qr as getAttentionColor,
|
|
1933
|
+
Cr as getContrastRatio,
|
|
1934
|
+
Xr as getElevation,
|
|
1935
|
+
Kr as getHierarchySpacing,
|
|
1936
|
+
Qr as getTypography,
|
|
1937
|
+
Jr as hierarchy,
|
|
1938
|
+
Dr as injectDarkModeCssVariables,
|
|
1939
|
+
Ir as injectTrinityCssVariables,
|
|
1940
|
+
Yr as interactiveHierarchy,
|
|
1941
|
+
Vr as lightTheme,
|
|
1942
|
+
W as resolveTrinityTokens,
|
|
1943
|
+
Sr as scaleHierarchy,
|
|
1944
|
+
z as semanticTokens,
|
|
1945
|
+
ro as spacingHierarchy,
|
|
1946
|
+
T as tokens,
|
|
1947
|
+
l as typographicHierarchy,
|
|
1948
|
+
Nr as useTrinityTokens,
|
|
1949
|
+
Pr as validateAccessibility
|
|
1495
1950
|
};
|