@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
|
@@ -6,37 +6,58 @@
|
|
|
6
6
|
*
|
|
7
7
|
* ## Supported markdown syntax
|
|
8
8
|
*
|
|
9
|
-
* When `markdown={true}` the built-in lightweight parser handles:
|
|
9
|
+
* When `markdown={true}` the built-in lightweight parser (AITextBlock.parser.ts) handles:
|
|
10
10
|
*
|
|
11
11
|
* | Syntax | Rendered element |
|
|
12
12
|
* |---|---|
|
|
13
13
|
* | `**bold**` | `<strong>` |
|
|
14
|
-
* | `*italic*` or `_italic_` | `<em
|
|
14
|
+
* | `*italic*` or `_italic_` | `<em>`; `_` counts only at a word's start and end, so `snake_case` and `file_name` stay text |
|
|
15
15
|
* | `` `code` `` | `<code>` with monospace styling |
|
|
16
|
-
* | `
|
|
17
|
-
* |
|
|
18
|
-
* |
|
|
16
|
+
* | ` ```lang ` fenced block | CodeBlock: the language as its caption, a copy button, `<pre dir="ltr"><code>`; a fence with no closing line runs to the end of the content |
|
|
17
|
+
* | `[text](url)` | `<a>`, always underlined, for http(s), mailto, tel and relative URLs (new tab, `rel="noopener noreferrer"`); other schemes render as text |
|
|
18
|
+
* | `# Heading 1` through `###### Heading 6` | `<h1>`–`<h6>`, moved down by `headingOffset` (clamped at `<h6>`) |
|
|
19
|
+
* | `- item`, `* item` or `+ item` | `<ul><li>` (unordered list) |
|
|
19
20
|
* | `1. item` | `<ol><li>` (ordered list) |
|
|
20
21
|
* | `> quote` | `<blockquote>` |
|
|
21
|
-
* | `---` on a line | `<hr>` |
|
|
22
|
+
* | `---` or `***` on a line | `<hr>` |
|
|
22
23
|
* | Blank line | Paragraph break |
|
|
24
|
+
* | `[^id]` citation marker | AISourceChip (number variant) when `citations` is true; text otherwise |
|
|
25
|
+
*
|
|
26
|
+
* Inline syntax works on one line at a time and does not nest: the text inside bold, italic and
|
|
27
|
+
* link text is not parsed again, and inline code keeps the delimiters inside it literal. The
|
|
28
|
+
* one exception is citations: markers inside bold and italic text become chips too (a
|
|
29
|
+
* citation-only second pass), while markers inside code and link text stay text.
|
|
30
|
+
*
|
|
31
|
+
* ## Citations (opt-in)
|
|
32
|
+
*
|
|
33
|
+
* With `citations` true, each `[^id]` marker (`id`: 1 to 64 of `A-Z a-z 0-9 . _ : -`) that names
|
|
34
|
+
* a source renders as an AISourceChip with the source's number: its 1-based place in `sources`,
|
|
35
|
+
* or, without that prop, in the AI response the block renders in. The numbers follow the sources'
|
|
36
|
+
* order, the same numbers AISourcesPanel and `useBlockSources` show. A marker that names no
|
|
37
|
+
* source shows as written (`unresolvedCitations: 'literal'`), or not at all (`'hide'`, with a
|
|
38
|
+
* partial marker at the end of streamed text). Without `citations`, `[^1]` is plain text, as it
|
|
39
|
+
* always was: a backend opts in per block with `TextBlock.citations` (OD-F15).
|
|
23
40
|
*
|
|
24
41
|
* ## NOT supported (by design)
|
|
25
42
|
*
|
|
26
43
|
* - Tables → pass a `table` block to `AIResponseRenderer` instead
|
|
27
44
|
* - Images → pass an `image` block to `AIResponseRenderer` instead
|
|
28
45
|
* - HTML passthrough (intentional — prevents XSS on AI-generated content)
|
|
29
|
-
* -
|
|
30
|
-
*
|
|
46
|
+
* - Syntax highlighting: fenced code blocks (` ``` `) render through the internal CodeBlock
|
|
47
|
+
* (D-34) with the fence language as a caption and a copy button, without highlighting
|
|
48
|
+
* - Strikethrough, task lists (GFM extensions); footnotes are supported when `citations` is
|
|
49
|
+
* true, as `[^id]` markers that name a source (see Citations)
|
|
31
50
|
*
|
|
32
|
-
* For richer markdown needs (tables, syntax highlighting
|
|
33
|
-
*
|
|
51
|
+
* For richer markdown needs (tables, syntax highlighting), layer `react-markdown` on top of
|
|
52
|
+
* AITextBlock with `markdown={false}`.
|
|
34
53
|
*
|
|
35
54
|
* ## Safety
|
|
36
55
|
*
|
|
37
56
|
* The parser does NOT execute HTML — incoming content is split and reassembled
|
|
38
57
|
* via React elements, so `<script>`, `<iframe>`, etc. in the source string are
|
|
39
|
-
* rendered as literal text, not parsed.
|
|
58
|
+
* rendered as literal text, not parsed. Link URLs pass the shared link policy
|
|
59
|
+
* (ADR-09): `javascript:`, `data:`, `vbscript:` and other schemes — including
|
|
60
|
+
* obfuscated forms — render as plain text, with a development warning.
|
|
40
61
|
*
|
|
41
62
|
* @example Plain text
|
|
42
63
|
* ```tsx
|
|
@@ -63,25 +84,91 @@
|
|
|
63
84
|
import React from 'react';
|
|
64
85
|
import { SxProps, Theme } from '@mui/material';
|
|
65
86
|
import { type TextBlock } from './types';
|
|
87
|
+
import { type TrinityRootProps } from '../shared/rootProps';
|
|
88
|
+
import type { AIResponseSource } from './types/response';
|
|
66
89
|
/**
|
|
67
|
-
*
|
|
90
|
+
* AITextBlock's own props.
|
|
68
91
|
*/
|
|
69
|
-
export interface
|
|
92
|
+
export interface AITextBlockOwnProps {
|
|
70
93
|
/** Text content to render */
|
|
71
94
|
content: string;
|
|
72
95
|
/**
|
|
73
96
|
* Parse `content` as markdown. Supports bold, italic, inline code, links,
|
|
74
97
|
* headings 1–6, ordered + unordered lists, blockquotes, horizontal rules,
|
|
75
|
-
* and paragraph breaks. See the file-level JSDoc for the
|
|
98
|
+
* fenced code blocks and paragraph breaks. See the file-level JSDoc for the
|
|
99
|
+
* full syntax table.
|
|
76
100
|
*/
|
|
77
101
|
markdown?: boolean;
|
|
78
|
-
/**
|
|
102
|
+
/**
|
|
103
|
+
* Semantic variant for styling, with or without `markdown`: `heading` renders an `<h3>` in the
|
|
104
|
+
* heading style, `caption` the small secondary style, `quote` a `<blockquote>` with a border.
|
|
105
|
+
* In markdown mode it styles the content's paragraphs, list items and quoted lines; headings,
|
|
106
|
+
* code blocks and rules in the content keep their own style.
|
|
107
|
+
*/
|
|
79
108
|
variant?: TextBlock['variant'];
|
|
80
|
-
/**
|
|
109
|
+
/**
|
|
110
|
+
* DOM id of the block's root element, for anchoring. It is rendered verbatim,
|
|
111
|
+
* so it is consumer-controlled: never pass an untrusted value such as a
|
|
112
|
+
* model-chosen block id. An id like `config` clobbers the named
|
|
113
|
+
* `window.config` global, and the same id on two messages breaks every ARIA
|
|
114
|
+
* reference to it. Derive it with `React.useId()` instead (WI-48). Without it,
|
|
115
|
+
* the root gets a generated id that is stable between server and client.
|
|
116
|
+
*/
|
|
81
117
|
id?: string;
|
|
82
|
-
/**
|
|
118
|
+
/**
|
|
119
|
+
* Moves the content's own headings down this many levels, clamped at `h6`: with 2, `#` renders
|
|
120
|
+
* an `<h3>` and `###` an `<h5>`. Use it where the block sits under the page's own headings, as
|
|
121
|
+
* in a chat thread, so authored headings never add an `<h1>`. The look follows the authored
|
|
122
|
+
* level. Markdown mode only (NAMING, "Heading level").
|
|
123
|
+
* @default 0
|
|
124
|
+
* @since 2.13.0
|
|
125
|
+
*/
|
|
126
|
+
headingOffset?: 0 | 1 | 2 | 3 | 4 | 5;
|
|
127
|
+
/**
|
|
128
|
+
* Render `[^id]` citation markers as source chips (AISourceChip, number variant) when the id
|
|
129
|
+
* names a source. Off by default: without it `[^1]` is text, as before (OD-F15). See the file
|
|
130
|
+
* header's Citations section for the syntax and the numbering.
|
|
131
|
+
* @default false
|
|
132
|
+
* @since 2.13.0
|
|
133
|
+
*/
|
|
134
|
+
citations?: boolean;
|
|
135
|
+
/**
|
|
136
|
+
* The sources citation markers name, numbered by their order here. Default: the sources of the
|
|
137
|
+
* AI response the block renders in. Used only with `citations`.
|
|
138
|
+
* @since 2.13.0
|
|
139
|
+
*/
|
|
140
|
+
sources?: AIResponseSource[];
|
|
141
|
+
/**
|
|
142
|
+
* A citation marker that names no source: shown as written (`'literal'`), or not shown
|
|
143
|
+
* (`'hide'`, for streaming, where the source may arrive later; a partial marker at the end of
|
|
144
|
+
* the content is hidden too). Default: the AI response's setting, else `'literal'`.
|
|
145
|
+
* @since 2.13.0
|
|
146
|
+
*/
|
|
147
|
+
unresolvedCitations?: 'literal' | 'hide';
|
|
148
|
+
/**
|
|
149
|
+
* Shows the query behind a cited source; passed to each citation chip ('Show query').
|
|
150
|
+
* @since 2.13.0
|
|
151
|
+
*/
|
|
152
|
+
onShowQuery?: (source: AIResponseSource) => void;
|
|
153
|
+
/**
|
|
154
|
+
* Added to the root's own class names.
|
|
155
|
+
* @since 2.13.0
|
|
156
|
+
*/
|
|
157
|
+
className?: string;
|
|
158
|
+
/**
|
|
159
|
+
* Styles for the root element (the `<div>` or `<blockquote>` in markdown mode, the text
|
|
160
|
+
* element otherwise), applied after the block's own styles. Object, array and function forms
|
|
161
|
+
* all apply.
|
|
162
|
+
*/
|
|
83
163
|
sx?: SxProps<Theme>;
|
|
84
164
|
}
|
|
165
|
+
/**
|
|
166
|
+
* Props for AITextBlock: its own props, plus the HTML attributes of its root element (`data-*`,
|
|
167
|
+
* `aria-*`, event handlers), which reach the root (ADR-04). `role` and the live-region
|
|
168
|
+
* attributes stay the component's.
|
|
169
|
+
*/
|
|
170
|
+
export interface AITextBlockProps extends AITextBlockOwnProps, TrinityRootProps<HTMLElement, AITextBlockOwnProps> {
|
|
171
|
+
}
|
|
85
172
|
/**
|
|
86
173
|
* AITextBlock - Renders text content with optional markdown parsing.
|
|
87
174
|
*
|
|
@@ -90,6 +177,9 @@ export interface AITextBlockProps {
|
|
|
90
177
|
* - heading → <h3>
|
|
91
178
|
* - caption → <p> with caption styling
|
|
92
179
|
* - quote → <blockquote>
|
|
180
|
+
*
|
|
181
|
+
* The ref, `className`, `sx` and the other HTML attributes reach the root element in both
|
|
182
|
+
* modes (ADR-04).
|
|
93
183
|
*/
|
|
94
184
|
export declare const AITextBlock: React.ForwardRefExoticComponent<AITextBlockProps & React.RefAttributes<HTMLElement>>;
|
|
95
185
|
export default AITextBlock;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AITextBlock.d.ts","sourceRoot":"","sources":["../../../src/components/AI/AITextBlock.tsx"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"AITextBlock.d.ts","sourceRoot":"","sources":["../../../src/components/AI/AITextBlock.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAkFG;AAEH,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAyB,OAA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fileoverview The AITextBlock markdown parser (F-06).
|
|
3
|
+
* @module components/AI/AITextBlock.parser
|
|
4
|
+
*
|
|
5
|
+
* @internal — not part of the public API; see ADR-02
|
|
6
|
+
*
|
|
7
|
+
* Pure functions, moved out of AITextBlock.tsx (F-06) so they can be tested and measured on
|
|
8
|
+
* their own: `parseMarkdown` splits content into block elements, and `parseInlineMarkdown`
|
|
9
|
+
* splits one block's text into inline parts in linear time (F-25, which replaced the regex
|
|
10
|
+
* implementation without changing its output). AITextBlock renders both as React elements, so
|
|
11
|
+
* nothing here produces HTML. The supported syntax is the table in AITextBlock.tsx's header.
|
|
12
|
+
* `splitCitations` and `citationsToPlainText` (F-13) read `[^id]` citation markers, which
|
|
13
|
+
* AITextBlock recognizes only when its `citations` prop is true.
|
|
14
|
+
* Exported for AITextBlock and its tests only; src/components/internal/index.ts lists the
|
|
15
|
+
* names, and no public barrel re-exports them.
|
|
16
|
+
*/
|
|
17
|
+
export type MarkdownElementType = 'paragraph' | 'heading' | 'bullet-list' | 'numbered-list' | 'blockquote' | 'hr' | 'code-block';
|
|
18
|
+
export interface ParsedElement {
|
|
19
|
+
type: MarkdownElementType;
|
|
20
|
+
level?: number;
|
|
21
|
+
content: string;
|
|
22
|
+
/** For code blocks: the fence's language (its info string's first word), if any. */
|
|
23
|
+
language?: string;
|
|
24
|
+
items?: string[];
|
|
25
|
+
}
|
|
26
|
+
/**
|
|
27
|
+
* parseMarkdown - Parses markdown content into structured elements.
|
|
28
|
+
*/
|
|
29
|
+
export declare function parseMarkdown(content: string): ParsedElement[];
|
|
30
|
+
/**
|
|
31
|
+
* A markdown link anywhere in the content, as a quick test (WI-56): a markdown block renders its
|
|
32
|
+
* new-tab hint only when this matches. A false positive (a link inside a code span) only renders
|
|
33
|
+
* an unused hidden hint.
|
|
34
|
+
*/
|
|
35
|
+
export declare const MARKDOWN_LINK: RegExp;
|
|
36
|
+
/**
|
|
37
|
+
* One inline run of a block's text: plain text, or one recognized syntax with its content. A
|
|
38
|
+
* `citation` (F-13) keeps the marker's exact text in `content` and the source id in `id`.
|
|
39
|
+
*/
|
|
40
|
+
export interface InlinePart {
|
|
41
|
+
type: 'text' | 'bold' | 'italic' | 'code' | 'link' | 'citation';
|
|
42
|
+
content: string;
|
|
43
|
+
url?: string;
|
|
44
|
+
/** The source id of a `citation` part. */
|
|
45
|
+
id?: string;
|
|
46
|
+
}
|
|
47
|
+
/**
|
|
48
|
+
* An inline syntax the scanner recognizes: one per part type, plus `underscoreItalic` (WI-31a),
|
|
49
|
+
* `_x_`, which gives an `italic` part like `*x*`.
|
|
50
|
+
*/
|
|
51
|
+
export type InlineSyntax = Exclude<InlinePart['type'], 'text'> | 'underscoreItalic';
|
|
52
|
+
/**
|
|
53
|
+
* The four syntaxes of the regex parser F-25 replaced, in tie order: at one start, bold wins
|
|
54
|
+
* over italic, italic over code and code over a link. F-25's differential test passes this as
|
|
55
|
+
* `syntax`, so syntax added later (WI-31a `_italic_`, F-13 `[^id]` citations) stays out of the
|
|
56
|
+
* parity proof against the frozen regex implementation.
|
|
57
|
+
*/
|
|
58
|
+
export declare const LEGACY_INLINE_SYNTAX: readonly InlineSyntax[];
|
|
59
|
+
/**
|
|
60
|
+
* The syntaxes AITextBlock recognizes without `citations`: every syntax but `citation`, which
|
|
61
|
+
* is opt-in (F-13, OD-F15), so `[^1]` stays text unless the consumer asks for citations.
|
|
62
|
+
* `underscoreItalic` (WI-31a) is the documented `_italic_`.
|
|
63
|
+
*/
|
|
64
|
+
export declare const DEFAULT_INLINE_SYNTAX: readonly InlineSyntax[];
|
|
65
|
+
/** {@link DEFAULT_INLINE_SYNTAX} plus `[^id]` citation markers (AITextBlock with `citations`). */
|
|
66
|
+
export declare const CITATION_INLINE_SYNTAX: readonly InlineSyntax[];
|
|
67
|
+
/** Options of {@link parseInlineMarkdown}. */
|
|
68
|
+
export interface InlineScanOptions {
|
|
69
|
+
/**
|
|
70
|
+
* The syntaxes to recognize; a syntax left out stays literal text. Ties at one start are
|
|
71
|
+
* always broken in the same order, whatever the order here: bold, italic, code, citation,
|
|
72
|
+
* link (a citation wins over a link that starts at the same `[`: `[^s1](Q2)`). `_x_` starts at
|
|
73
|
+
* a character no other syntax starts at, so it never ties.
|
|
74
|
+
* @default DEFAULT_INLINE_SYNTAX (every syntax but `citation`)
|
|
75
|
+
*/
|
|
76
|
+
syntax?: readonly InlineSyntax[];
|
|
77
|
+
}
|
|
78
|
+
/**
|
|
79
|
+
* parseInlineMarkdown - Splits one block's text into inline parts, in linear time (F-25).
|
|
80
|
+
*
|
|
81
|
+
* The result is exactly that of the regex implementation it replaced (frozen in
|
|
82
|
+
* __tests__/fixtures/parseInlineMarkdown.legacy.ts, proven by a differential test): each syntax
|
|
83
|
+
* takes its leftmost, shortest, non-overlapping matches on one line (`**x**`, `*x*`, `` `x` ``
|
|
84
|
+
* and `[x](y)`, each with at least one character inside), then the runs are taken in order of
|
|
85
|
+
* start, ties in {@link LEGACY_INLINE_SYNTAX} order, and a run that starts inside an earlier one
|
|
86
|
+
* is skipped. The regexes rescanned the rest of the line from every unmatched `[`, which was
|
|
87
|
+
* quadratic (about 60 ms for 20 KB of `[^`, and cubic for repeated `[a](`). Here one pass moves
|
|
88
|
+
* forward through the text, and each delimiter (`**`, `*`, `` ` ``, `](`, `)` and the line end)
|
|
89
|
+
* is found with a forward lookup that never searches the same text twice, so the whole scan is
|
|
90
|
+
* linear. For a link the first `](` after the text decides: if no `)` follows it on the line,
|
|
91
|
+
* none follows a later one either.
|
|
92
|
+
*
|
|
93
|
+
* With `underscoreItalic` (WI-31a, on by default), `_x_` is italic when the opening `_` starts a
|
|
94
|
+
* word and the closing one ends a word (see isUnderscoreOpener and isUnderscoreCloser), so an
|
|
95
|
+
* underscore inside an identifier never starts or ends one. The closing lookup moves forward like
|
|
96
|
+
* the others.
|
|
97
|
+
*
|
|
98
|
+
* With `citation` in `syntax` (F-13), `[^id]` is a citation part. It is read at its `[` before a
|
|
99
|
+
* link, so `[^s1](Q2)` is a citation followed by text, and a `[` that opens a citation never
|
|
100
|
+
* opens a link. Code spans and link text that start earlier claim their range as for every
|
|
101
|
+
* syntax, so a marker inside them stays text; bold and italic text is not parsed again here
|
|
102
|
+
* (AITextBlock runs {@link splitCitations} on it). The marker check reads at most 66 characters
|
|
103
|
+
* from each `[`, so the scan stays linear.
|
|
104
|
+
*/
|
|
105
|
+
export declare function parseInlineMarkdown(content: string, options?: InlineScanOptions): InlinePart[];
|
|
106
|
+
/** A run of text with citation markers split out: plain text, or one `[^id]` marker. */
|
|
107
|
+
export type CitationRun = {
|
|
108
|
+
type: 'text';
|
|
109
|
+
content: string;
|
|
110
|
+
} | {
|
|
111
|
+
type: 'citation';
|
|
112
|
+
content: string;
|
|
113
|
+
id: string;
|
|
114
|
+
};
|
|
115
|
+
/** Options of {@link splitCitations}. */
|
|
116
|
+
export interface SplitCitationsOptions {
|
|
117
|
+
/**
|
|
118
|
+
* Keep backtick code spans whole, so a marker inside one stays text (bold and italic text,
|
|
119
|
+
* whose code spans AITextBlock shows literally). Plain text has no code spans: false.
|
|
120
|
+
* @default false
|
|
121
|
+
*/
|
|
122
|
+
opaqueCode?: boolean;
|
|
123
|
+
}
|
|
124
|
+
/**
|
|
125
|
+
* Splits text into plain runs and `[^id]` citation markers. AITextBlock's plain path uses it,
|
|
126
|
+
* and its markdown path for the text inside bold and italic (with `opaqueCode`), the
|
|
127
|
+
* "citation-only second pass". Adjacent text is merged.
|
|
128
|
+
*/
|
|
129
|
+
export declare function splitCitations(content: string, options?: SplitCitationsOptions): CitationRun[];
|
|
130
|
+
/**
|
|
131
|
+
* A partial citation marker at the very end of streamed text: `[`, `[^` or `[^id` with no `]`
|
|
132
|
+
* yet. Under `unresolvedCitations: 'hide'` it renders nothing, so it never flashes as text.
|
|
133
|
+
*/
|
|
134
|
+
export declare const TRAILING_PARTIAL_CITATION: RegExp;
|
|
135
|
+
/** Options of {@link citationsToPlainText}. */
|
|
136
|
+
export interface CitationPlainTextOptions {
|
|
137
|
+
/**
|
|
138
|
+
* A marker that names no source: kept as written (`'literal'`), or removed with a trailing
|
|
139
|
+
* partial marker (`'hide'`, while streaming).
|
|
140
|
+
* @default 'literal'
|
|
141
|
+
*/
|
|
142
|
+
unresolved?: 'literal' | 'hide';
|
|
143
|
+
}
|
|
144
|
+
/**
|
|
145
|
+
* Markdown content as copied text (G's `getResponsePlainText`, ADR-13 (2)): each resolved
|
|
146
|
+
* `[^id]` marker becomes `[n]`, the number the chip shows; an unresolved one stays as written,
|
|
147
|
+
* or is removed under `unresolved: 'hide'`. Markers that AITextBlock shows as text stay text:
|
|
148
|
+
* inside a fenced code block, an inline code span or link text. Everything else is unchanged.
|
|
149
|
+
*
|
|
150
|
+
* @param resolveNumber The 1-based number of a source id, `undefined` for an unknown id.
|
|
151
|
+
*/
|
|
152
|
+
export declare function citationsToPlainText(content: string, resolveNumber: (sourceId: string) => number | undefined, options?: CitationPlainTextOptions): string;
|
|
153
|
+
//# sourceMappingURL=AITextBlock.parser.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"AITextBlock.parser.d.ts","sourceRoot":"","sources":["../../../src/components/AI/AITextBlock.parser.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AAMH,MAAM,MAAM,mBAAmB,GAC3B,WAAW,GACX,SAAS,GACT,aAAa,GACb,eAAe,GACf,YAAY,GACZ,IAAI,GACJ,YAAY,CAAC;AAEjB,MAAM,WAAW,aAAa;IAC5B,IAAI,EAAE,mBAAmB,CAAC;IAC1B,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,OAAO,EAAE,MAAM,CAAC;IAChB,oFAAoF;IACpF,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,KAAK,CAAC,EAAE,MAAM,EAAE,CAAC;CAClB;AAED;;GAEG;AACH,wBAAgB,aAAa,CAAC,OAAO,EAAE,MAAM,GAAG,aAAa,EAAE,CA4H9D;AAMD;;;;GAIG;AACH,eAAO,MAAM,aAAa,QAAuB,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,OAAO,GAAE,qBAA0B,GAAG,WAAW,EAAE,CAclG;AAED;;;GAGG;AACH,eAAO,MAAM,yBAAyB,QAA2B,CAAC;AAElE,+CAA+C;AAC/C,MAAM,WAAW,wBAAwB;IACvC;;;;OAIG;IACH,UAAU,CAAC,EAAE,SAAS,GAAG,MAAM,CAAC;CACjC;AAED;;;;;;;GAOG;AACH,wBAAgB,oBAAoB,CAClC,OAAO,EAAE,MAAM,EACf,aAAa,EAAE,CAAC,QAAQ,EAAE,MAAM,KAAK,MAAM,GAAG,SAAS,EACvD,OAAO,GAAE,wBAA6B,GACrC,MAAM,CA6BR"}
|
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @fileoverview AIVerificationBadge: who checked an answer or a plan, as a glyph and a label
|
|
3
|
+
* (master-plan F-11).
|
|
4
|
+
* @module components/AI/AIVerificationBadge
|
|
5
|
+
*
|
|
6
|
+
* - **Composition (OD-F1).** D's MetaChip with its colours from
|
|
7
|
+
* `getTrinityPalette(theme).verification[role]`, C's Icon, and the details in F-09's
|
|
8
|
+
* DetailsPopover. Not a StatusIndicator variant: StatusIndicator's colours are the indicator
|
|
9
|
+
* catalog, not the verification roles, and its statuses are not these (docs/NAMING.md).
|
|
10
|
+
* - **Root.** Always a `<span>` that carries the ref, `className`, the typed rest props and the
|
|
11
|
+
* merged `sx`. With details (`verifiedAt`, `datasetName`, `note` or `details`) the chip is a
|
|
12
|
+
* native `<button type="button">` that opens a details dialog; without, a static chip with no
|
|
13
|
+
* tab stop. `aria-label` and `aria-labelledby` are not set on the role-less root (ADR-04-R2,
|
|
14
|
+
* OD-F19): a development warning points to `label`.
|
|
15
|
+
* - **Statuses (OD-F12).** One table, typed `as const satisfies`, maps each status to its role,
|
|
16
|
+
* its glyph and its label key: verified (`verified`), golden (`award`), confirmed plan (`check`),
|
|
17
|
+
* pending review (`clock`), flagged (`flag`), rejected (`close`). None of these glyphs is a
|
|
18
|
+
* confidence glyph, so the two badges never look alike. Each status has a glyph and words, never
|
|
19
|
+
* colour alone (ADR-33).
|
|
20
|
+
* - **Announcements.** Non-live by default (ADR-32): the badge renders no live region and no
|
|
21
|
+
* `role="status"`, so it is safe inside a chat log (ADR-19). With `live`, a status change after
|
|
22
|
+
* mount is announced once through `useAnnounce` (`ai.verificationBadge.changed({ label })`); the
|
|
23
|
+
* first render never announces.
|
|
24
|
+
* - **Text.** Labels wrap instead of truncating, so the badge reflows at 320px. Logical
|
|
25
|
+
* properties, theme spacing; forced colours keep a `semanticTokens.borders.width.default`
|
|
26
|
+
* CanvasText border.
|
|
27
|
+
*
|
|
28
|
+
* @example
|
|
29
|
+
* ```tsx
|
|
30
|
+
* <AIVerificationBadge status="golden" />
|
|
31
|
+
* <AIVerificationBadge status="verified" verifiedAt="2026-06-30T16:00:00Z" datasetName="Finance warehouse" />
|
|
32
|
+
* ```
|
|
33
|
+
*/
|
|
34
|
+
import * as React from 'react';
|
|
35
|
+
import type { SxProps, Theme } from '@mui/material/styles';
|
|
36
|
+
import { type TrinitySlotProps } from '../shared/rootProps';
|
|
37
|
+
import type { AIVerificationStatus } from './types/hitl';
|
|
38
|
+
/**
|
|
39
|
+
* Props of {@link AIVerificationBadge}. The rest props reach the root span; `aria-label` and
|
|
40
|
+
* `aria-labelledby` do not (use `label`).
|
|
41
|
+
* @since 2.13.0
|
|
42
|
+
*/
|
|
43
|
+
export interface AIVerificationBadgeProps extends Omit<React.HTMLAttributes<HTMLSpanElement>, 'color'> {
|
|
44
|
+
/** The review state of the answer or the plan. */
|
|
45
|
+
status: AIVerificationStatus;
|
|
46
|
+
/**
|
|
47
|
+
* `'chip'` is a tinted chip; `'inline'` is the glyph and the label with no fill.
|
|
48
|
+
* @default 'chip'
|
|
49
|
+
*/
|
|
50
|
+
variant?: 'chip' | 'inline';
|
|
51
|
+
/** @default 'small' */
|
|
52
|
+
size?: 'small' | 'medium';
|
|
53
|
+
/** Replaces the status label (`ai.verificationBadge.status.*`) for this badge. */
|
|
54
|
+
label?: string;
|
|
55
|
+
/** When it was verified: an ISO 8601 date or date-time, shown in the details. */
|
|
56
|
+
verifiedAt?: string;
|
|
57
|
+
/** The verified dataset the answer came from, shown in the details. */
|
|
58
|
+
datasetName?: string;
|
|
59
|
+
/** A reviewer's note, shown in the details. */
|
|
60
|
+
note?: string;
|
|
61
|
+
/** Replaces the details list. Any details make the badge a button that opens them. */
|
|
62
|
+
details?: React.ReactNode;
|
|
63
|
+
/**
|
|
64
|
+
* Announces a status change after mount: `true` or `'polite'` politely, `'assertive'`
|
|
65
|
+
* assertively. The badge never renders a live region itself.
|
|
66
|
+
* @default false
|
|
67
|
+
*/
|
|
68
|
+
live?: boolean | 'polite' | 'assertive';
|
|
69
|
+
className?: string;
|
|
70
|
+
sx?: SxProps<Theme>;
|
|
71
|
+
slotProps?: {
|
|
72
|
+
/** The glyph's wrapper. */
|
|
73
|
+
icon?: TrinitySlotProps<HTMLSpanElement>;
|
|
74
|
+
/** The label. */
|
|
75
|
+
text?: TrinitySlotProps<HTMLSpanElement>;
|
|
76
|
+
/** The chip: a button with details, a span without. */
|
|
77
|
+
trigger?: TrinitySlotProps<HTMLElement>;
|
|
78
|
+
/** The details dialog (the popover's paper). */
|
|
79
|
+
popover?: TrinitySlotProps<HTMLDivElement>;
|
|
80
|
+
};
|
|
81
|
+
}
|
|
82
|
+
/**
|
|
83
|
+
* Shows who checked an answer or a plan: a glyph and a label, with the details on demand. See
|
|
84
|
+
* the module notes.
|
|
85
|
+
*
|
|
86
|
+
* @example
|
|
87
|
+
* ```tsx
|
|
88
|
+
* <AIVerificationBadge status="verified" verifiedAt="2026-06-30" datasetName="Finance warehouse" />
|
|
89
|
+
* ```
|
|
90
|
+
*
|
|
91
|
+
* @since 2.13.0
|
|
92
|
+
*/
|
|
93
|
+
export declare const AIVerificationBadge: React.ForwardRefExoticComponent<AIVerificationBadgeProps & React.RefAttributes<HTMLSpanElement>>;
|
|
94
|
+
//# sourceMappingURL=AIVerificationBadge.d.ts.map
|
|
@@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jB,IAAI,CAAC,EAAE,gBAAgB,CAAC,eAAe,CAAC,CAAC;QACzC,uDAAuD;QACvD,OAAO,CAAC,EAAE,gBAAgB,CAAC,WAAW,CAAC,CAAC;QACxC,gDAAgD;QAChD,OAAO,CAAC,EAAE,gBAAgB,CAAC,cAAc,CAAC,CAAC;KAC5C,CAAC;CACH;AA0BD;;;;;;;;;;GAUG;AACH,eAAO,MAAM,mBAAmB,kGAiK9B,CAAC"}
|
|
@@ -15,33 +15,57 @@
|
|
|
15
15
|
*/
|
|
16
16
|
import React from 'react';
|
|
17
17
|
import { SxProps, Theme } from '@mui/material';
|
|
18
|
+
import { type TrinityRootProps } from '../shared/rootProps';
|
|
18
19
|
/**
|
|
19
|
-
*
|
|
20
|
+
* GradientText's own props.
|
|
20
21
|
*/
|
|
21
|
-
export interface
|
|
22
|
+
export interface GradientTextOwnProps {
|
|
22
23
|
/** Text content */
|
|
23
24
|
children: React.ReactNode;
|
|
24
|
-
/** Gradient start color */
|
|
25
|
+
/** Gradient start color. Default: the theme's `ai.primary` role (resolved at render). */
|
|
25
26
|
startColor?: string;
|
|
26
|
-
/** Gradient end color */
|
|
27
|
+
/** Gradient end color. Default: the theme's `ai.accent` role (resolved at render). */
|
|
27
28
|
endColor?: string;
|
|
28
29
|
/** Gradient direction */
|
|
29
30
|
direction?: string;
|
|
30
31
|
/** Typography variant */
|
|
31
32
|
variant?: 'h1' | 'h2' | 'h3' | 'h4' | 'h5' | 'h6' | 'body1' | 'body2' | 'subtitle1' | 'subtitle2';
|
|
33
|
+
/**
|
|
34
|
+
* The rendered element. By default it follows `variant`, so the default
|
|
35
|
+
* `h6` renders a heading: GradientText is documented for branded AI section
|
|
36
|
+
* headings. Pass `'span'` (or `'p'`) when the text is a value or a phrase,
|
|
37
|
+
* not a heading.
|
|
38
|
+
*
|
|
39
|
+
* @since 2.13.0
|
|
40
|
+
*/
|
|
41
|
+
component?: React.ElementType;
|
|
32
42
|
/** Font weight */
|
|
33
43
|
fontWeight?: number | string;
|
|
34
|
-
/**
|
|
44
|
+
/**
|
|
45
|
+
* Added to the root's own class names.
|
|
46
|
+
* @since 2.13.0
|
|
47
|
+
*/
|
|
48
|
+
className?: string;
|
|
49
|
+
/** Custom sx props, applied after the text's own styles (object, array or function). */
|
|
35
50
|
sx?: SxProps<Theme>;
|
|
36
51
|
}
|
|
52
|
+
/**
|
|
53
|
+
* Props for GradientText: its own props, plus the HTML attributes of its root element (`id`,
|
|
54
|
+
* `data-*`, `aria-*`), which reach the root (ADR-04, WI-40).
|
|
55
|
+
*/
|
|
56
|
+
export interface GradientTextProps extends GradientTextOwnProps, TrinityRootProps<HTMLElement, GradientTextOwnProps> {
|
|
57
|
+
}
|
|
37
58
|
/**
|
|
38
59
|
* Gradient Text - Text with gradient fill effect.
|
|
60
|
+
*
|
|
61
|
+
* In forced-colors mode (Windows contrast themes) the gradient is dropped and
|
|
62
|
+
* the text takes the system text color, so it never turns invisible.
|
|
39
63
|
*/
|
|
40
|
-
export declare const GradientText: React.ForwardRefExoticComponent<GradientTextProps & React.RefAttributes<
|
|
64
|
+
export declare const GradientText: React.ForwardRefExoticComponent<GradientTextProps & React.RefAttributes<HTMLElement>>;
|
|
41
65
|
/**
|
|
42
|
-
*
|
|
66
|
+
* StatCard's own props.
|
|
43
67
|
*/
|
|
44
|
-
export interface
|
|
68
|
+
export interface StatCardOwnProps {
|
|
45
69
|
/** Stat label */
|
|
46
70
|
label: string;
|
|
47
71
|
/** Stat value */
|
|
@@ -56,49 +80,94 @@ export interface StatCardProps {
|
|
|
56
80
|
variant?: 'default' | 'gradient' | 'outlined';
|
|
57
81
|
/** Size */
|
|
58
82
|
size?: 'small' | 'medium' | 'large';
|
|
59
|
-
/**
|
|
83
|
+
/**
|
|
84
|
+
* The element of the value. Default `'p'`: a KPI value is text, not a
|
|
85
|
+
* heading (WCAG F43). The size still follows `size`. Pass a heading element
|
|
86
|
+
* (`'h3'`) only when the value really titles a section.
|
|
87
|
+
*
|
|
88
|
+
* @since 2.13.0
|
|
89
|
+
*/
|
|
90
|
+
valueComponent?: React.ElementType;
|
|
91
|
+
/**
|
|
92
|
+
* Added to the root's own class names.
|
|
93
|
+
* @since 2.13.0
|
|
94
|
+
*/
|
|
95
|
+
className?: string;
|
|
96
|
+
/** Custom sx props, applied after the card's own styles (object, array or function). */
|
|
60
97
|
sx?: SxProps<Theme>;
|
|
61
98
|
}
|
|
99
|
+
/**
|
|
100
|
+
* Props for StatCard: its own props, plus the HTML attributes of its root `div` (`id`,
|
|
101
|
+
* `data-*`, `aria-*`), which reach the root (ADR-04, WI-40).
|
|
102
|
+
*/
|
|
103
|
+
export interface StatCardProps extends StatCardOwnProps, TrinityRootProps<HTMLDivElement, StatCardOwnProps> {
|
|
104
|
+
}
|
|
62
105
|
/**
|
|
63
106
|
* Stat Card - Display statistical metrics with optional trend.
|
|
64
107
|
*/
|
|
65
108
|
export declare const StatCard: React.ForwardRefExoticComponent<StatCardProps & React.RefAttributes<HTMLDivElement>>;
|
|
66
109
|
/**
|
|
67
|
-
*
|
|
110
|
+
* GradientIconBadge's own props.
|
|
68
111
|
*/
|
|
69
|
-
export interface
|
|
112
|
+
export interface GradientIconBadgeOwnProps {
|
|
70
113
|
/** Icon name */
|
|
71
114
|
icon: string;
|
|
72
115
|
/** Size */
|
|
73
116
|
size?: 'small' | 'medium' | 'large';
|
|
74
|
-
/** Gradient start color */
|
|
117
|
+
/** Gradient start color. Default: the theme's `ai.primaryFill` role (resolved at render). */
|
|
75
118
|
startColor?: string;
|
|
76
|
-
/** Gradient end color */
|
|
119
|
+
/** Gradient end color. Default: the theme's `ai.accent` role (resolved at render). */
|
|
77
120
|
endColor?: string;
|
|
78
121
|
/** Badge label */
|
|
79
122
|
label?: string;
|
|
80
|
-
/**
|
|
123
|
+
/**
|
|
124
|
+
* Added to the root's own class names.
|
|
125
|
+
* @since 2.13.0
|
|
126
|
+
*/
|
|
127
|
+
className?: string;
|
|
128
|
+
/** Custom sx props, applied after the badge's own styles (object, array or function). */
|
|
81
129
|
sx?: SxProps<Theme>;
|
|
82
130
|
}
|
|
83
131
|
/**
|
|
84
|
-
*
|
|
132
|
+
* Props for GradientIconBadge: its own props, plus the HTML attributes of its root `div` (`id`,
|
|
133
|
+
* `data-*`, `aria-*`), which reach the root (ADR-04, WI-40).
|
|
85
134
|
*/
|
|
86
|
-
export
|
|
135
|
+
export interface GradientIconBadgeProps extends GradientIconBadgeOwnProps, TrinityRootProps<HTMLDivElement, GradientIconBadgeOwnProps> {
|
|
136
|
+
}
|
|
87
137
|
/**
|
|
88
|
-
*
|
|
138
|
+
* Gradient Icon Badge - Icon with gradient background.
|
|
89
139
|
*/
|
|
90
|
-
export
|
|
140
|
+
export declare const GradientIconBadge: React.ForwardRefExoticComponent<GradientIconBadgeProps & React.RefAttributes<HTMLDivElement>>;
|
|
141
|
+
/** AIShimmer's own props. */
|
|
142
|
+
export interface AIShimmerOwnProps {
|
|
91
143
|
/** Width of shimmer */
|
|
92
144
|
width?: string | number;
|
|
93
145
|
/** Height of shimmer */
|
|
94
146
|
height?: string | number;
|
|
95
|
-
/**
|
|
96
|
-
|
|
97
|
-
|
|
147
|
+
/**
|
|
148
|
+
* Corner radius. A number multiplies the theme's shape radius, as `sx` does (`1` is 8px in
|
|
149
|
+
* Trinity themes); a string is a CSS length (`'6px'`, the default, or `'50%'`).
|
|
150
|
+
* Widened from `number` in 2.13.0, so the default's own type is accepted.
|
|
151
|
+
*/
|
|
152
|
+
borderRadius?: number | string;
|
|
153
|
+
/** Added to the root's own class names. */
|
|
154
|
+
className?: string;
|
|
155
|
+
/** Custom sx props, applied after the shimmer's own styles (object, array or function). */
|
|
98
156
|
sx?: SxProps<Theme>;
|
|
99
157
|
}
|
|
100
158
|
/**
|
|
101
|
-
*
|
|
159
|
+
* Props for AIShimmer component: its own props, plus the HTML attributes of its root `div`
|
|
160
|
+
* (`id`, `data-*`, `aria-*`), which reach the root (ADR-04).
|
|
161
|
+
*/
|
|
162
|
+
export type AIShimmerProps = AIShimmerOwnProps & TrinityRootProps<HTMLDivElement, AIShimmerOwnProps>;
|
|
163
|
+
/**
|
|
164
|
+
* AI Shimmer - Loading placeholder with an AI-tinted highlight sweep.
|
|
165
|
+
*
|
|
166
|
+
* Decorative: the root is `aria-hidden="true"` by default, so a screen reader does not read
|
|
167
|
+
* an empty box. Announce loading where it happens instead: put `aria-busy="true"` on the
|
|
168
|
+
* region that is loading, or announce it with `useAnnounce`. The colours follow the theme
|
|
169
|
+
* (the AI surface roles, light and dark). The sweep uses `aiTokens.motion.shimmer` and stops
|
|
170
|
+
* when the user prefers reduced motion, leaving the placeholder visible.
|
|
102
171
|
*/
|
|
103
|
-
export declare const AIShimmer: React.ForwardRefExoticComponent<
|
|
172
|
+
export declare const AIShimmer: React.ForwardRefExoticComponent<AIShimmerOwnProps & TrinityRootProps<HTMLDivElement, AIShimmerOwnProps> & React.RefAttributes<HTMLDivElement>>;
|
|
104
173
|
//# sourceMappingURL=AIVisuals.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AIVisuals.d.ts","sourceRoot":"","sources":["../../../src/components/AI/AIVisuals.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAKL,OAAO,EACP,KAAK,EACN,MAAM,eAAe,CAAC;
|
|
1
|
+
{"version":3,"file":"AIVisuals.d.ts","sourceRoot":"","sources":["../../../src/components/AI/AIVisuals.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AAEH,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAKL,OAAO,EACP,KAAK,EACN,MAAM,eAAe,CAAC;AASvB,OAAO,EAAgB,KAAK,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AAW1E;;GAEG;AACH,MAAM,WAAW,oBAAoB;IACnC,mBAAmB;IACnB,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;IAC1B,yFAAyF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