@vertesia/ui 1.5.0-dev.20260807.073259Z → 1.5.0-dev.20260826.064249Z
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -7
- package/lib/core/components/shadcn/filters/comboBox/DateCombobox.js +1 -1
- package/lib/core/components/shadcn/filters/comboBox/DateCombobox.js.map +1 -1
- package/lib/core/components/shadcn/filters/filter/dateFilter.d.ts.map +1 -1
- package/lib/core/components/shadcn/filters/filter/dateFilter.js +1 -1
- package/lib/core/components/shadcn/filters/filter/dateFilter.js.map +1 -1
- package/lib/core/components/shadcn/filters/filters.d.ts.map +1 -1
- package/lib/core/components/shadcn/filters/filters.js +1 -1
- package/lib/core/components/shadcn/filters/filters.js.map +1 -1
- package/lib/core/components/shadcn/index.d.ts +1 -0
- package/lib/core/components/shadcn/index.d.ts.map +1 -1
- package/lib/core/components/shadcn/index.js +1 -0
- package/lib/core/components/shadcn/index.js.map +1 -1
- package/lib/core/components/shadcn/modal/dialog.d.ts.map +1 -1
- package/lib/core/components/shadcn/modal/dialog.js +1 -3
- package/lib/core/components/shadcn/modal/dialog.js.map +1 -1
- package/lib/core/components/shadcn/overflowTabs.d.ts +59 -0
- package/lib/core/components/shadcn/overflowTabs.d.ts.map +1 -0
- package/lib/core/components/shadcn/overflowTabs.js +173 -0
- package/lib/core/components/shadcn/overflowTabs.js.map +1 -0
- package/lib/core/components/shadcn/selectBox.js +2 -2
- package/lib/core/components/shadcn/selectBox.js.map +1 -1
- package/lib/core/components/shadcn/theme/ThemeProvider.d.ts +3 -1
- package/lib/core/components/shadcn/theme/ThemeProvider.d.ts.map +1 -1
- package/lib/core/components/shadcn/theme/ThemeProvider.js +8 -9
- package/lib/core/components/shadcn/theme/ThemeProvider.js.map +1 -1
- package/lib/core/utils/dayjs.d.ts +12 -0
- package/lib/core/utils/dayjs.d.ts.map +1 -0
- package/lib/core/utils/dayjs.js +16 -0
- package/lib/core/utils/dayjs.js.map +1 -0
- package/lib/env/index.d.ts +17 -0
- package/lib/env/index.d.ts.map +1 -1
- package/lib/env/index.js +18 -1
- package/lib/env/index.js.map +1 -1
- package/lib/features/agent/PayloadBuilder.d.ts +1 -0
- package/lib/features/agent/PayloadBuilder.d.ts.map +1 -1
- package/lib/features/agent/PayloadBuilder.js +22 -5
- package/lib/features/agent/PayloadBuilder.js.map +1 -1
- package/lib/features/agent/chat/AgentRightPanel.d.ts.map +1 -1
- package/lib/features/agent/chat/AgentRightPanel.js +3 -135
- package/lib/features/agent/chat/AgentRightPanel.js.map +1 -1
- package/lib/features/agent/chat/ArtifactsTab.d.ts.map +1 -1
- package/lib/features/agent/chat/ArtifactsTab.js +1 -1
- package/lib/features/agent/chat/ArtifactsTab.js.map +1 -1
- package/lib/features/agent/chat/AskUserWidget.d.ts.map +1 -1
- package/lib/features/agent/chat/AskUserWidget.js +19 -4
- package/lib/features/agent/chat/AskUserWidget.js.map +1 -1
- package/lib/features/agent/chat/ModernAgentConversation.d.ts +6 -0
- package/lib/features/agent/chat/ModernAgentConversation.d.ts.map +1 -1
- package/lib/features/agent/chat/ModernAgentConversation.js +99 -29
- package/lib/features/agent/chat/ModernAgentConversation.js.map +1 -1
- package/lib/features/agent/chat/ModernAgentOutput/ActiveWorkstreamsSummary.d.ts.map +1 -1
- package/lib/features/agent/chat/ModernAgentOutput/ActiveWorkstreamsSummary.js +10 -9
- package/lib/features/agent/chat/ModernAgentOutput/ActiveWorkstreamsSummary.js.map +1 -1
- package/lib/features/agent/chat/ModernAgentOutput/AllMessagesMixed.d.ts.map +1 -1
- package/lib/features/agent/chat/ModernAgentOutput/AllMessagesMixed.js +5 -8
- package/lib/features/agent/chat/ModernAgentOutput/AllMessagesMixed.js.map +1 -1
- package/lib/features/agent/chat/ModernAgentOutput/AttachmentPreview.d.ts.map +1 -1
- package/lib/features/agent/chat/ModernAgentOutput/AttachmentPreview.js +45 -4
- package/lib/features/agent/chat/ModernAgentOutput/AttachmentPreview.js.map +1 -1
- package/lib/features/agent/chat/ModernAgentOutput/BatchProgressPanel.js +1 -1
- package/lib/features/agent/chat/ModernAgentOutput/BatchProgressPanel.js.map +1 -1
- package/lib/features/agent/chat/ModernAgentOutput/Header.d.ts.map +1 -1
- package/lib/features/agent/chat/ModernAgentOutput/Header.js +3 -3
- package/lib/features/agent/chat/ModernAgentOutput/Header.js.map +1 -1
- package/lib/features/agent/chat/ModernAgentOutput/MessageItem.d.ts.map +1 -1
- package/lib/features/agent/chat/ModernAgentOutput/MessageItem.js +1 -1
- package/lib/features/agent/chat/ModernAgentOutput/MessageItem.js.map +1 -1
- package/lib/features/agent/chat/ModernAgentOutput/StreamingMessage.d.ts.map +1 -1
- package/lib/features/agent/chat/ModernAgentOutput/StreamingMessage.js +1 -1
- package/lib/features/agent/chat/ModernAgentOutput/StreamingMessage.js.map +1 -1
- package/lib/features/agent/chat/ModernAgentOutput/ToolCallGroup.js +1 -1
- package/lib/features/agent/chat/ModernAgentOutput/ToolCallGroup.js.map +1 -1
- package/lib/features/agent/chat/ModernAgentOutput/WorkstreamTabs.d.ts.map +1 -1
- package/lib/features/agent/chat/ModernAgentOutput/WorkstreamTabs.js +9 -121
- package/lib/features/agent/chat/ModernAgentOutput/WorkstreamTabs.js.map +1 -1
- package/lib/features/agent/chat/ModernAgentOutput/utils.d.ts +6 -0
- package/lib/features/agent/chat/ModernAgentOutput/utils.d.ts.map +1 -1
- package/lib/features/agent/chat/ModernAgentOutput/utils.js +19 -11
- package/lib/features/agent/chat/ModernAgentOutput/utils.js.map +1 -1
- package/lib/features/agent/chat/VegaLiteChart.d.ts.map +1 -1
- package/lib/features/agent/chat/VegaLiteChart.js +11 -3
- package/lib/features/agent/chat/VegaLiteChart.js.map +1 -1
- package/lib/features/agent/chat/hooks/useAgentStream.d.ts.map +1 -1
- package/lib/features/agent/chat/hooks/useAgentStream.js +3 -0
- package/lib/features/agent/chat/hooks/useAgentStream.js.map +1 -1
- package/lib/features/document-viewer/UniversalDocumentViewer.d.ts.map +1 -1
- package/lib/features/document-viewer/UniversalDocumentViewer.js +1 -1
- package/lib/features/document-viewer/UniversalDocumentViewer.js.map +1 -1
- package/lib/features/facets/AgentRunnerFacetsNav.d.ts +14 -2
- package/lib/features/facets/AgentRunnerFacetsNav.d.ts.map +1 -1
- package/lib/features/facets/AgentRunnerFacetsNav.js +20 -2
- package/lib/features/facets/AgentRunnerFacetsNav.js.map +1 -1
- package/lib/features/facets/CollectionsFacetsNav.d.ts +3 -3
- package/lib/features/facets/CollectionsFacetsNav.d.ts.map +1 -1
- package/lib/features/facets/CollectionsFacetsNav.js +6 -1
- package/lib/features/facets/CollectionsFacetsNav.js.map +1 -1
- package/lib/features/facets/DocumentsFacetsNav.d.ts +3 -3
- package/lib/features/facets/DocumentsFacetsNav.d.ts.map +1 -1
- package/lib/features/facets/DocumentsFacetsNav.js +20 -8
- package/lib/features/facets/DocumentsFacetsNav.js.map +1 -1
- package/lib/features/facets/InteractionsFacetsNav.d.ts +3 -3
- package/lib/features/facets/InteractionsFacetsNav.d.ts.map +1 -1
- package/lib/features/facets/InteractionsFacetsNav.js +11 -1
- package/lib/features/facets/InteractionsFacetsNav.js.map +1 -1
- package/lib/features/facets/PromptsFacetsNav.d.ts +3 -3
- package/lib/features/facets/PromptsFacetsNav.d.ts.map +1 -1
- package/lib/features/facets/PromptsFacetsNav.js +6 -1
- package/lib/features/facets/PromptsFacetsNav.js.map +1 -1
- package/lib/features/facets/RunsFacetsNav.d.ts +4 -14
- package/lib/features/facets/RunsFacetsNav.d.ts.map +1 -1
- package/lib/features/facets/RunsFacetsNav.js +26 -15
- package/lib/features/facets/RunsFacetsNav.js.map +1 -1
- package/lib/features/facets/WorkflowExecutionsFacetsNav.d.ts +4 -3
- package/lib/features/facets/WorkflowExecutionsFacetsNav.d.ts.map +1 -1
- package/lib/features/facets/WorkflowExecutionsFacetsNav.js +18 -10
- package/lib/features/facets/WorkflowExecutionsFacetsNav.js.map +1 -1
- package/lib/features/facets/index.d.ts +1 -1
- package/lib/features/facets/index.d.ts.map +1 -1
- package/lib/features/facets/index.js.map +1 -1
- package/lib/features/facets/utils/SearchInterface.d.ts +4 -3
- package/lib/features/facets/utils/SearchInterface.d.ts.map +1 -1
- package/lib/features/facets/utils/SearchInterface.js +4 -0
- package/lib/features/facets/utils/SearchInterface.js.map +1 -1
- package/lib/features/layout/GenericPageNavHeader.d.ts +8 -1
- package/lib/features/layout/GenericPageNavHeader.d.ts.map +1 -1
- package/lib/features/layout/GenericPageNavHeader.js +9 -1
- package/lib/features/layout/GenericPageNavHeader.js.map +1 -1
- package/lib/features/magic-pdf/DownloadPopover.d.ts +3 -2
- package/lib/features/magic-pdf/DownloadPopover.d.ts.map +1 -1
- package/lib/features/magic-pdf/DownloadPopover.js.map +1 -1
- package/lib/features/magic-pdf/GroundedExtractionView.d.ts.map +1 -1
- package/lib/features/magic-pdf/GroundedExtractionView.js +51 -64
- package/lib/features/magic-pdf/GroundedExtractionView.js.map +1 -1
- package/lib/features/oauth/McpConnectionsButton.d.ts +1 -1
- package/lib/features/oauth/McpConnectionsButton.d.ts.map +1 -1
- package/lib/features/oauth/McpConnectionsButton.js +2 -2
- package/lib/features/oauth/McpConnectionsButton.js.map +1 -1
- package/lib/features/oauth/McpConnectionsDialog.d.ts +1 -1
- package/lib/features/oauth/McpConnectionsDialog.js +2 -2
- package/lib/features/oauth/McpConnectionsDialog.js.map +1 -1
- package/lib/features/oauth/useMcpConnections.d.ts +4 -5
- package/lib/features/oauth/useMcpConnections.d.ts.map +1 -1
- package/lib/features/oauth/useMcpConnections.js +20 -4
- package/lib/features/oauth/useMcpConnections.js.map +1 -1
- package/lib/features/pdf-viewer/PdfPageRenderer.d.ts.map +1 -1
- package/lib/features/pdf-viewer/PdfPageRenderer.js +9 -11
- package/lib/features/pdf-viewer/PdfPageRenderer.js.map +1 -1
- package/lib/features/pdf-viewer/lazyReactPdf.d.ts +10 -0
- package/lib/features/pdf-viewer/lazyReactPdf.d.ts.map +1 -0
- package/lib/features/pdf-viewer/lazyReactPdf.js +25 -0
- package/lib/features/pdf-viewer/lazyReactPdf.js.map +1 -0
- package/lib/features/store/collections/CollectionsTable.d.ts.map +1 -1
- package/lib/features/store/collections/CollectionsTable.js +1 -3
- package/lib/features/store/collections/CollectionsTable.js.map +1 -1
- package/lib/features/store/collections/EditCollectionView.js +1 -1
- package/lib/features/store/collections/EditCollectionView.js.map +1 -1
- package/lib/features/store/objects/ExportPropertiesModal.d.ts +3 -1
- package/lib/features/store/objects/ExportPropertiesModal.d.ts.map +1 -1
- package/lib/features/store/objects/ExportPropertiesModal.js +5 -5
- package/lib/features/store/objects/ExportPropertiesModal.js.map +1 -1
- package/lib/features/store/objects/components/ContentOverview.d.ts.map +1 -1
- package/lib/features/store/objects/components/ContentOverview.js +4 -10
- package/lib/features/store/objects/components/ContentOverview.js.map +1 -1
- package/lib/features/store/objects/components/TextEditorPanel.d.ts.map +1 -1
- package/lib/features/store/objects/components/TextEditorPanel.js +8 -3
- package/lib/features/store/objects/components/TextEditorPanel.js.map +1 -1
- package/lib/features/store/objects/layout/renderers.d.ts.map +1 -1
- package/lib/features/store/objects/layout/renderers.js +1 -5
- package/lib/features/store/objects/layout/renderers.js.map +1 -1
- package/lib/features/store/objects/search/DocumentSearchContext.d.ts +29 -62
- package/lib/features/store/objects/search/DocumentSearchContext.d.ts.map +1 -1
- package/lib/features/store/objects/search/DocumentSearchContext.js +2 -0
- package/lib/features/store/objects/search/DocumentSearchContext.js.map +1 -1
- package/lib/features/store/objects/upload/DocumentUploadModal.d.ts +6 -1
- package/lib/features/store/objects/upload/DocumentUploadModal.d.ts.map +1 -1
- package/lib/features/store/objects/upload/DocumentUploadModal.js +4 -3
- package/lib/features/store/objects/upload/DocumentUploadModal.js.map +1 -1
- package/lib/features/store/objects/upload/useSmartFileUploadProcessing.d.ts.map +1 -1
- package/lib/features/store/objects/upload/useSmartFileUploadProcessing.js +2 -2
- package/lib/features/store/objects/upload/useSmartFileUploadProcessing.js.map +1 -1
- package/lib/features/store/types/ContentObjectTypesTable.d.ts.map +1 -1
- package/lib/features/store/types/ContentObjectTypesTable.js +1 -3
- package/lib/features/store/types/ContentObjectTypesTable.js.map +1 -1
- package/lib/features/store/types/IntakePolicyEditor.d.ts.map +1 -1
- package/lib/features/store/types/IntakePolicyEditor.js +11 -1
- package/lib/features/store/types/IntakePolicyEditor.js.map +1 -1
- package/lib/features/store/types/ObjectSchemaEditor.d.ts.map +1 -1
- package/lib/features/store/types/ObjectSchemaEditor.js +6 -2
- package/lib/features/store/types/ObjectSchemaEditor.js.map +1 -1
- package/lib/features/store/types/TableLayoutEditor.d.ts.map +1 -1
- package/lib/features/store/types/TableLayoutEditor.js +2 -0
- package/lib/features/store/types/TableLayoutEditor.js.map +1 -1
- package/lib/features/store/types/TypeRegistry.d.ts +272 -0
- package/lib/features/store/types/TypeRegistry.d.ts.map +1 -1
- package/lib/features/store/types/search/ObjectTypeSearchContext.d.ts +271 -0
- package/lib/features/store/types/search/ObjectTypeSearchContext.d.ts.map +1 -1
- package/lib/features/user/UserInfo.d.ts.map +1 -1
- package/lib/features/user/UserInfo.js +2 -4
- package/lib/features/user/UserInfo.js.map +1 -1
- package/lib/features/views/ViewActions.d.ts +32 -0
- package/lib/features/views/ViewActions.d.ts.map +1 -0
- package/lib/features/views/ViewActions.js +186 -0
- package/lib/features/views/ViewActions.js.map +1 -0
- package/lib/features/views/ViewDropTarget.d.ts +15 -0
- package/lib/features/views/ViewDropTarget.d.ts.map +1 -0
- package/lib/features/views/ViewDropTarget.js +79 -0
- package/lib/features/views/ViewDropTarget.js.map +1 -0
- package/lib/features/views/ViewExperience.d.ts +3 -2
- package/lib/features/views/ViewExperience.d.ts.map +1 -1
- package/lib/features/views/ViewExperience.js +103 -12
- package/lib/features/views/ViewExperience.js.map +1 -1
- package/lib/features/views/ViewNavigation.d.ts +1 -1
- package/lib/features/views/ViewNavigation.d.ts.map +1 -1
- package/lib/features/views/ViewNavigation.js +14 -5
- package/lib/features/views/ViewNavigation.js.map +1 -1
- package/lib/features/views/ViewResults.d.ts +1 -1
- package/lib/features/views/ViewResults.d.ts.map +1 -1
- package/lib/features/views/ViewResults.js +124 -34
- package/lib/features/views/ViewResults.js.map +1 -1
- package/lib/features/views/index.d.ts +1 -0
- package/lib/features/views/index.d.ts.map +1 -1
- package/lib/features/views/index.js +1 -0
- package/lib/features/views/index.js.map +1 -1
- package/lib/features/views/types.d.ts +46 -1
- package/lib/features/views/types.d.ts.map +1 -1
- package/lib/features/views/viewState.d.ts.map +1 -1
- package/lib/features/views/viewState.js +34 -0
- package/lib/features/views/viewState.js.map +1 -1
- package/lib/i18n/LanguageProvider.d.ts +3 -1
- package/lib/i18n/LanguageProvider.d.ts.map +1 -1
- package/lib/i18n/LanguageProvider.js +9 -7
- package/lib/i18n/LanguageProvider.js.map +1 -1
- package/lib/i18n/instance.d.ts +2 -0
- package/lib/i18n/instance.d.ts.map +1 -1
- package/lib/i18n/instance.js +45 -26
- package/lib/i18n/instance.js.map +1 -1
- package/lib/i18n/locales/ar.json +261 -15
- package/lib/i18n/locales/de.json +259 -13
- package/lib/i18n/locales/en.json +30 -4
- package/lib/i18n/locales/es.json +260 -14
- package/lib/i18n/locales/fr.json +259 -13
- package/lib/i18n/locales/it.json +259 -13
- package/lib/i18n/locales/ja.json +257 -10
- package/lib/i18n/locales/ko.json +257 -10
- package/lib/i18n/locales/pt.json +259 -13
- package/lib/i18n/locales/ru.json +256 -10
- package/lib/i18n/locales/tr.json +256 -10
- package/lib/i18n/locales/zh-TW.json +257 -10
- package/lib/i18n/locales/zh.json +257 -10
- package/lib/session/UserSessionProvider.d.ts.map +1 -1
- package/lib/session/UserSessionProvider.js +8 -16
- package/lib/session/UserSessionProvider.js.map +1 -1
- package/lib/session/auth/composable.d.ts.map +1 -1
- package/lib/session/auth/composable.js +25 -19
- package/lib/session/auth/composable.js.map +1 -1
- package/lib/session/auth/firebase.js +1 -1
- package/lib/session/auth/firebase.js.map +1 -1
- package/lib/shell/VertesiaShell.d.ts.map +1 -1
- package/lib/shell/VertesiaShell.js +2 -1
- package/lib/shell/VertesiaShell.js.map +1 -1
- package/lib/shell/apps/AppInstallationProvider.d.ts +4 -2
- package/lib/shell/apps/AppInstallationProvider.d.ts.map +1 -1
- package/lib/shell/apps/IframeAppContextSync.d.ts +3 -0
- package/lib/shell/apps/IframeAppContextSync.d.ts.map +1 -0
- package/lib/shell/apps/IframeAppContextSync.js +95 -0
- package/lib/shell/apps/IframeAppContextSync.js.map +1 -0
- package/lib/shell/apps/iframe-auth.d.ts +55 -0
- package/lib/shell/apps/iframe-auth.d.ts.map +1 -0
- package/lib/shell/apps/iframe-auth.js +154 -0
- package/lib/shell/apps/iframe-auth.js.map +1 -0
- package/lib/shell/apps/index.d.ts +2 -0
- package/lib/shell/apps/index.d.ts.map +1 -1
- package/lib/shell/apps/index.js +2 -0
- package/lib/shell/apps/index.js.map +1 -1
- package/lib/vertesia-ui-core.js +4 -4
- package/lib/vertesia-ui-core.js.map +1 -1
- package/lib/vertesia-ui-env.js +1 -1
- package/lib/vertesia-ui-env.js.map +1 -1
- package/lib/vertesia-ui-features.js +32 -34
- package/lib/vertesia-ui-features.js.map +1 -1
- package/lib/vertesia-ui-i18n.js +16 -16
- package/lib/vertesia-ui-i18n.js.map +1 -1
- package/lib/vertesia-ui-rich-text.js +4 -4
- package/lib/vertesia-ui-rich-text.js.map +1 -1
- package/lib/vertesia-ui-router.js +1 -1
- package/lib/vertesia-ui-router.js.map +1 -1
- package/lib/vertesia-ui-session.js +1 -1
- package/lib/vertesia-ui-session.js.map +1 -1
- package/lib/vertesia-ui-shell.js +1 -1
- package/lib/vertesia-ui-shell.js.map +1 -1
- package/lib/vertesia-ui-widgets.js +20 -20
- package/lib/vertesia-ui-widgets.js.map +1 -1
- package/lib/widgets/markdown/MarkdownRenderer.d.ts.map +1 -1
- package/lib/widgets/markdown/MarkdownRenderer.js +43 -2
- package/lib/widgets/markdown/MarkdownRenderer.js.map +1 -1
- package/lib/widgets/markdown/MermaidDiagram.d.ts.map +1 -1
- package/lib/widgets/markdown/MermaidDiagram.js +35 -22
- package/lib/widgets/markdown/MermaidDiagram.js.map +1 -1
- package/lib/widgets/monacoEditor/MonacoEditor.d.ts.map +1 -1
- package/lib/widgets/monacoEditor/MonacoEditor.js +14 -10
- package/lib/widgets/monacoEditor/MonacoEditor.js.map +1 -1
- package/lib/widgets/xml-viewer/hooks/useCollapsible.d.ts +1 -1
- package/package.json +24 -29
- package/src/core/components/shadcn/filters/comboBox/DateCombobox.tsx +1 -1
- package/src/core/components/shadcn/filters/filter/dateFilter.tsx +1 -1
- package/src/core/components/shadcn/filters/filters.tsx +1 -1
- package/src/core/components/shadcn/index.ts +1 -0
- package/src/core/components/shadcn/modal/dialog.test.tsx +35 -0
- package/src/core/components/shadcn/modal/dialog.tsx +0 -4
- package/src/core/components/shadcn/overflowTabs.tsx +320 -0
- package/src/core/components/shadcn/selectBox.tsx +2 -2
- package/src/core/components/shadcn/theme/ThemeProvider.tsx +10 -9
- package/src/core/utils/dayjs.ts +17 -0
- package/src/css/base.css +78 -0
- package/src/env/index.test.ts +94 -0
- package/src/env/index.ts +36 -1
- package/src/features/agent/PayloadBuilder.test.ts +68 -0
- package/src/features/agent/PayloadBuilder.tsx +28 -4
- package/src/features/agent/chat/AgentRightPanel.tsx +2 -252
- package/src/features/agent/chat/ArtifactsTab.tsx +1 -0
- package/src/features/agent/chat/AskUserWidget.test.tsx +20 -1
- package/src/features/agent/chat/AskUserWidget.tsx +22 -6
- package/src/features/agent/chat/ModernAgentConversation.test.tsx +160 -0
- package/src/features/agent/chat/ModernAgentConversation.tsx +111 -31
- package/src/features/agent/chat/ModernAgentOutput/ActiveWorkstreamsSummary.tsx +86 -67
- package/src/features/agent/chat/ModernAgentOutput/AllMessagesMixed.test.tsx +90 -7
- package/src/features/agent/chat/ModernAgentOutput/AllMessagesMixed.tsx +4 -6
- package/src/features/agent/chat/ModernAgentOutput/AttachmentPreview.test.ts +103 -1
- package/src/features/agent/chat/ModernAgentOutput/AttachmentPreview.tsx +50 -4
- package/src/features/agent/chat/ModernAgentOutput/BatchProgressPanel.tsx +1 -1
- package/src/features/agent/chat/ModernAgentOutput/Header.tsx +18 -1
- package/src/features/agent/chat/ModernAgentOutput/MessageItem.tsx +1 -1
- package/src/features/agent/chat/ModernAgentOutput/StreamingMessage.tsx +1 -1
- package/src/features/agent/chat/ModernAgentOutput/ToolCallGroup.tsx +1 -1
- package/src/features/agent/chat/ModernAgentOutput/WorkstreamTabs.tsx +37 -167
- package/src/features/agent/chat/ModernAgentOutput/utils.test.ts +94 -0
- package/src/features/agent/chat/ModernAgentOutput/utils.ts +19 -10
- package/src/features/agent/chat/VegaLiteChart.tsx +32 -14
- package/src/features/agent/chat/hooks/useAgentStream.test.tsx +18 -0
- package/src/features/agent/chat/hooks/useAgentStream.ts +3 -0
- package/src/features/document-viewer/UniversalDocumentViewer.tsx +1 -1
- package/src/features/facets/AgentRunnerFacetsNav.tsx +44 -4
- package/src/features/facets/CollectionsFacetsNav.tsx +15 -4
- package/src/features/facets/DocumentsFacetsNav.tsx +25 -8
- package/src/features/facets/FacetQueryHandlers.test.ts +84 -0
- package/src/features/facets/InteractionsFacetsNav.tsx +20 -4
- package/src/features/facets/PromptsFacetsNav.tsx +15 -4
- package/src/features/facets/RunsFacetsNav.test.ts +59 -0
- package/src/features/facets/RunsFacetsNav.tsx +40 -30
- package/src/features/facets/WorkflowExecutionsFacetsNav.test.ts +57 -0
- package/src/features/facets/WorkflowExecutionsFacetsNav.tsx +36 -16
- package/src/features/facets/index.ts +1 -0
- package/src/features/facets/utils/SearchInterface.tsx +12 -3
- package/src/features/layout/GenericPageNavHeader.tsx +16 -0
- package/src/features/magic-pdf/DownloadPopover.tsx +1 -2
- package/src/features/magic-pdf/GroundedExtractionView.test.tsx +7 -1
- package/src/features/magic-pdf/GroundedExtractionView.tsx +162 -242
- package/src/features/oauth/McpConnectionsButton.test.tsx +18 -1
- package/src/features/oauth/McpConnectionsButton.tsx +6 -2
- package/src/features/oauth/McpConnectionsDialog.tsx +3 -3
- package/src/features/oauth/useMcpConnections.test.ts +1 -0
- package/src/features/oauth/useMcpConnections.ts +24 -7
- package/src/features/pdf-viewer/PdfPageRenderer.tsx +76 -71
- package/src/features/pdf-viewer/lazyReactPdf.ts +33 -0
- package/src/features/store/collections/CollectionsTable.tsx +1 -4
- package/src/features/store/collections/EditCollectionView.tsx +1 -1
- package/src/features/store/objects/ExportPropertiesModal.tsx +25 -16
- package/src/features/store/objects/components/ContentOverview.tsx +2 -28
- package/src/features/store/objects/components/TextEditorPanel.tsx +13 -3
- package/src/features/store/objects/layout/renderers.tsx +1 -6
- package/src/features/store/objects/search/DocumentSearchContext.ts +4 -2
- package/src/features/store/objects/upload/DocumentUploadModal.tsx +10 -3
- package/src/features/store/objects/upload/useSmartFileUploadProcessing.ts +15 -6
- package/src/features/store/types/ContentObjectTypesTable.tsx +1 -4
- package/src/features/store/types/IntakePolicyEditor.tsx +11 -1
- package/src/features/store/types/ObjectSchemaEditor.tsx +6 -2
- package/src/features/store/types/TableLayoutEditor.tsx +2 -0
- package/src/features/user/UserInfo.test.tsx +10 -0
- package/src/features/user/UserInfo.tsx +2 -7
- package/src/features/views/ViewActions.test.tsx +80 -0
- package/src/features/views/ViewActions.tsx +352 -0
- package/src/features/views/ViewDropTarget.test.tsx +150 -0
- package/src/features/views/ViewDropTarget.tsx +140 -0
- package/src/features/views/ViewExperience.test.tsx +72 -0
- package/src/features/views/ViewExperience.tsx +189 -22
- package/src/features/views/ViewMedia.test.tsx +180 -0
- package/src/features/views/ViewNavigation.test.tsx +42 -0
- package/src/features/views/ViewNavigation.tsx +43 -5
- package/src/features/views/ViewResults.tsx +243 -26
- package/src/features/views/index.ts +1 -0
- package/src/features/views/types.ts +50 -0
- package/src/features/views/viewState.test.ts +7 -1
- package/src/features/views/viewState.ts +32 -0
- package/src/i18n/LanguageProvider.tsx +15 -8
- package/src/i18n/instance.test.ts +30 -0
- package/src/i18n/instance.ts +67 -40
- package/src/i18n/locales/ar.json +1157 -911
- package/src/i18n/locales/de.json +1113 -867
- package/src/i18n/locales/en.json +30 -4
- package/src/i18n/locales/es.json +1124 -878
- package/src/i18n/locales/fr.json +1124 -878
- package/src/i18n/locales/it.json +1124 -878
- package/src/i18n/locales/ja.json +1113 -866
- package/src/i18n/locales/ko.json +1113 -866
- package/src/i18n/locales/pt.json +1124 -878
- package/src/i18n/locales/ru.json +1135 -889
- package/src/i18n/locales/tr.json +1113 -867
- package/src/i18n/locales/zh-TW.json +1113 -866
- package/src/i18n/locales/zh.json +1113 -866
- package/src/i18n/rtl.test.ts +16 -7
- package/src/rich-text/VertesiaRichTextEditor.test.tsx +33 -1
- package/src/session/UserSessionProvider.tsx +8 -20
- package/src/session/auth/composable.scope.test.ts +1 -1
- package/src/session/auth/composable.test.ts +61 -1
- package/src/session/auth/composable.ts +29 -23
- package/src/session/auth/firebase.ts +1 -1
- package/src/shell/VertesiaShell.tsx +2 -0
- package/src/shell/apps/IframeAppContextSync.test.tsx +196 -0
- package/src/shell/apps/IframeAppContextSync.tsx +101 -0
- package/src/shell/apps/iframe-auth.test.ts +118 -0
- package/src/shell/apps/iframe-auth.ts +193 -0
- package/src/shell/apps/index.ts +2 -0
- package/src/widgets/markdown/ArtifactEditingSurface.test.tsx +12 -3
- package/src/widgets/markdown/MarkdownRenderer.tsx +50 -2
- package/src/widgets/markdown/MermaidDiagram.tsx +38 -22
- package/src/widgets/monacoEditor/MonacoEditor.tsx +27 -20
- package/lib/features/magic-pdf/GroundedExtractionAssistantPanel.d.ts +0 -25
- package/lib/features/magic-pdf/GroundedExtractionAssistantPanel.d.ts.map +0 -1
- package/lib/features/magic-pdf/GroundedExtractionAssistantPanel.js +0 -42
- package/lib/features/magic-pdf/GroundedExtractionAssistantPanel.js.map +0 -1
- package/src/features/magic-pdf/GroundedExtractionAssistantPanel.tsx +0 -86
|
@@ -2,8 +2,10 @@ import {
|
|
|
2
2
|
Badge,
|
|
3
3
|
Button,
|
|
4
4
|
cn,
|
|
5
|
+
Dropdown,
|
|
5
6
|
ErrorBox,
|
|
6
7
|
errorMessage,
|
|
8
|
+
MenuItem,
|
|
7
9
|
ResizableHandle,
|
|
8
10
|
ResizablePanel,
|
|
9
11
|
ResizablePanelGroup,
|
|
@@ -13,21 +15,23 @@ import {
|
|
|
13
15
|
} from '@vertesia/ui/core';
|
|
14
16
|
import { useUITranslation } from '@vertesia/ui/i18n';
|
|
15
17
|
import { useUserSession } from '@vertesia/ui/session';
|
|
18
|
+
import { computeTitleFromName } from '@vertesia/ui/widgets';
|
|
16
19
|
import {
|
|
17
20
|
CheckCircle2,
|
|
18
21
|
ChevronLeft,
|
|
19
22
|
ChevronRight,
|
|
23
|
+
Download,
|
|
20
24
|
Eye,
|
|
21
25
|
FileDown,
|
|
22
26
|
FileJson2,
|
|
23
27
|
FileText,
|
|
24
28
|
Grid3X3,
|
|
25
29
|
Image as ImageIcon,
|
|
30
|
+
Info,
|
|
26
31
|
Sparkles,
|
|
27
32
|
X,
|
|
28
33
|
} from 'lucide-react';
|
|
29
|
-
import { useEffect, useMemo, useState } from 'react';
|
|
30
|
-
import { GroundedExtractionAssistantPanel } from './GroundedExtractionAssistantPanel';
|
|
34
|
+
import { Fragment, useEffect, useMemo, useState } from 'react';
|
|
31
35
|
|
|
32
36
|
const ADVANCED_PROCESSING_PREFIX = 'magic-pdf';
|
|
33
37
|
|
|
@@ -173,7 +177,6 @@ export function GroundedExtractionPanel({ objectId, onClose }: GroundedExtractio
|
|
|
173
177
|
data: extraction,
|
|
174
178
|
error,
|
|
175
179
|
isLoading,
|
|
176
|
-
refetch,
|
|
177
180
|
} = useFetch<GroundedExtractionFile>(async () => {
|
|
178
181
|
const response = await client.files.getDownloadUrl(
|
|
179
182
|
`${ADVANCED_PROCESSING_PREFIX}/${objectId}/grounded-extraction.json`,
|
|
@@ -210,12 +213,7 @@ export function GroundedExtractionPanel({ objectId, onClose }: GroundedExtractio
|
|
|
210
213
|
|
|
211
214
|
return (
|
|
212
215
|
<div className="relative h-full">
|
|
213
|
-
<GroundedExtractionViewImpl
|
|
214
|
-
extraction={extraction}
|
|
215
|
-
objectId={objectId}
|
|
216
|
-
onClose={onClose}
|
|
217
|
-
onExtractionChanged={refetch}
|
|
218
|
-
/>
|
|
216
|
+
<GroundedExtractionViewImpl extraction={extraction} objectId={objectId} onClose={onClose} />
|
|
219
217
|
</div>
|
|
220
218
|
);
|
|
221
219
|
}
|
|
@@ -235,12 +233,10 @@ function GroundedExtractionViewImpl({
|
|
|
235
233
|
extraction,
|
|
236
234
|
objectId,
|
|
237
235
|
onClose,
|
|
238
|
-
onExtractionChanged,
|
|
239
236
|
}: {
|
|
240
237
|
extraction: GroundedExtractionFile;
|
|
241
238
|
objectId: string;
|
|
242
239
|
onClose?: () => void;
|
|
243
|
-
onExtractionChanged?: () => void;
|
|
244
240
|
}) {
|
|
245
241
|
const { t } = useUITranslation();
|
|
246
242
|
const { client } = useUserSession();
|
|
@@ -262,10 +258,8 @@ function GroundedExtractionViewImpl({
|
|
|
262
258
|
};
|
|
263
259
|
const [page, setPage] = useState(pageNumbers[0] ?? 1);
|
|
264
260
|
const [selectedPath, setSelectedPath] = useState<string | undefined>(undefined);
|
|
265
|
-
const [
|
|
266
|
-
const [showVerdict, setShowVerdict] = useState(false);
|
|
261
|
+
const [showDetails, setShowDetails] = useState(false);
|
|
267
262
|
const [pageImageMode, setPageImageMode] = useState<PageImageMode>('original');
|
|
268
|
-
const [assistantOpen, setAssistantOpen] = useState(false);
|
|
269
263
|
|
|
270
264
|
const breakdown = useMemo(() => {
|
|
271
265
|
const groups = { digital: 0, ocr: 0, reviewerConfirmed: 0, snapped: 0, imageRead: 0 };
|
|
@@ -314,6 +308,7 @@ function GroundedExtractionViewImpl({
|
|
|
314
308
|
}, [extraction.citations]);
|
|
315
309
|
|
|
316
310
|
const totalCitations = extraction.citations.length;
|
|
311
|
+
const allVerified = breakdown.totalVerified === totalCitations;
|
|
317
312
|
|
|
318
313
|
const selectPath = (path: string) => {
|
|
319
314
|
setSelectedPath(path);
|
|
@@ -357,7 +352,7 @@ function GroundedExtractionViewImpl({
|
|
|
357
352
|
>
|
|
358
353
|
<ChevronLeft className="size-4" />
|
|
359
354
|
</Button>
|
|
360
|
-
<span className="text-xs text-muted
|
|
355
|
+
<span className="text-xs text-muted">
|
|
361
356
|
{t('pdf.pageOf', { pageNumber: page, totalPages: pageNumbers.length })}
|
|
362
357
|
</span>
|
|
363
358
|
<Button
|
|
@@ -418,128 +413,48 @@ function GroundedExtractionViewImpl({
|
|
|
418
413
|
<div className="flex h-9 items-center justify-between shrink-0 bg-sidebar px-2 border-b border-sidebar-border">
|
|
419
414
|
<span className="text-sm font-medium">{t('grounded.title')}</span>
|
|
420
415
|
<div className="flex items-center gap-2">
|
|
421
|
-
|
|
422
|
-
<
|
|
423
|
-
|
|
424
|
-
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
<button
|
|
433
|
-
type="button"
|
|
434
|
-
className="cursor-pointer"
|
|
435
|
-
onClick={() => setShowVerdict((v) => !v)}
|
|
436
|
-
aria-expanded={showVerdict}
|
|
437
|
-
aria-label={t('grounded.verdictDetails')}
|
|
438
|
-
>
|
|
439
|
-
<Badge variant={extraction.verdict === 'good_to_go' ? 'success' : 'attention'}>
|
|
440
|
-
{extraction.verdict === 'good_to_go'
|
|
441
|
-
? t('grounded.verdictGoodToGo')
|
|
442
|
-
: t('grounded.verdictNeedsReview')}
|
|
443
|
-
</Badge>
|
|
444
|
-
</button>
|
|
445
|
-
)}
|
|
446
|
-
{typeof extraction.hardness?.score === 'number' && (
|
|
447
|
-
<Badge
|
|
448
|
-
variant={
|
|
449
|
-
extraction.hardness.score >= 0.5
|
|
450
|
-
? 'attention'
|
|
451
|
-
: extraction.hardness.score >= 0.2
|
|
452
|
-
? 'info'
|
|
453
|
-
: 'secondary'
|
|
454
|
-
}
|
|
455
|
-
title={t('grounded.hardnessHint')}
|
|
456
|
-
>
|
|
457
|
-
{t('grounded.hardness', {
|
|
458
|
-
percent: Math.round(extraction.hardness.score * 100),
|
|
459
|
-
})}
|
|
460
|
-
{extraction.hardness.escalated ? ' ↑' : ''}
|
|
461
|
-
</Badge>
|
|
462
|
-
)}
|
|
463
|
-
{extraction.citations.length > 0 &&
|
|
464
|
-
(() => {
|
|
465
|
-
// Real verification: fraction of values actually confirmed —
|
|
466
|
-
// digitally (verbatim/OCR match) OR by the reviewer against the
|
|
467
|
-
// image. NOT mean confidence, which scores image-read values high
|
|
468
|
-
// even when nothing was verified (e.g. 98% "confidence" on 2/64).
|
|
469
|
-
const verifiedPct = Math.round(
|
|
470
|
-
(100 * breakdown.totalVerified) / extraction.citations.length,
|
|
471
|
-
);
|
|
472
|
-
return (
|
|
473
|
-
<Badge
|
|
474
|
-
variant={
|
|
475
|
-
verifiedPct >= 95
|
|
476
|
-
? 'success'
|
|
477
|
-
: verifiedPct >= 50
|
|
478
|
-
? 'attention'
|
|
479
|
-
: 'destructive'
|
|
480
|
-
}
|
|
481
|
-
title={t('grounded.confidenceHint')}
|
|
482
|
-
>
|
|
483
|
-
{t('grounded.confidence', { percent: verifiedPct })}
|
|
484
|
-
</Badge>
|
|
485
|
-
);
|
|
486
|
-
})()}
|
|
487
|
-
<button
|
|
488
|
-
type="button"
|
|
489
|
-
className="flex cursor-pointer items-center gap-1"
|
|
490
|
-
onClick={() => setShowBreakdown((v) => !v)}
|
|
491
|
-
aria-expanded={showBreakdown}
|
|
492
|
-
aria-label={t('grounded.breakdownTitle')}
|
|
493
|
-
>
|
|
494
|
-
{breakdown.digitallyVerified > 0 && (
|
|
495
|
-
<Badge variant="success" title={t('grounded.digitalVerifiedHint')}>
|
|
496
|
-
{t('grounded.digitalVerifiedOf', {
|
|
497
|
-
count: breakdown.digitallyVerified,
|
|
416
|
+
{totalCitations > 0 && (
|
|
417
|
+
<VTooltip description={t('grounded.confidenceHint')} placement="bottom" size="xs" asChild>
|
|
418
|
+
<Badge
|
|
419
|
+
variant={allVerified ? 'success' : 'attention'}
|
|
420
|
+
className="gap-1 text-nowrap cursor-pointer"
|
|
421
|
+
onClick={() => setShowDetails((v) => !v)}
|
|
422
|
+
aria-expanded={showDetails}
|
|
423
|
+
>
|
|
424
|
+
{allVerified ? <CheckCircle2 className="size-3.5" /> : <Eye className="size-3.5" />}
|
|
425
|
+
{t('grounded.verifiedOf', {
|
|
426
|
+
verified: breakdown.totalVerified,
|
|
498
427
|
total: totalCitations,
|
|
499
428
|
})}
|
|
500
429
|
</Badge>
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
</
|
|
514
|
-
|
|
515
|
-
</button>
|
|
516
|
-
<Button
|
|
517
|
-
variant="ghost"
|
|
518
|
-
size="xs"
|
|
519
|
-
aria-label={t('grounded.downloadCitations')}
|
|
520
|
-
title={t('grounded.downloadCitations')}
|
|
521
|
-
onClick={() => downloadArtifact('grounded-extraction.json')}
|
|
522
|
-
>
|
|
523
|
-
<FileJson2 className="size-4" />
|
|
524
|
-
</Button>
|
|
525
|
-
<Button
|
|
526
|
-
variant="ghost"
|
|
527
|
-
size="xs"
|
|
528
|
-
aria-label={t('grounded.downloadBlocks')}
|
|
529
|
-
title={t('grounded.downloadBlocks')}
|
|
530
|
-
onClick={() => downloadArtifact(`pages/page-${page}.json`)}
|
|
531
|
-
>
|
|
532
|
-
<FileText className="size-4" />
|
|
533
|
-
</Button>
|
|
534
|
-
<Button
|
|
535
|
-
variant="ghost"
|
|
536
|
-
size="xs"
|
|
537
|
-
aria-label={t('grounded.downloadAnnotated')}
|
|
538
|
-
title={t('grounded.downloadAnnotated')}
|
|
539
|
-
onClick={() => downloadArtifact('grounded-annotated.pdf')}
|
|
430
|
+
</VTooltip>
|
|
431
|
+
)}
|
|
432
|
+
<Dropdown
|
|
433
|
+
align="right"
|
|
434
|
+
trigger={
|
|
435
|
+
<Button
|
|
436
|
+
variant="ghost"
|
|
437
|
+
size="xs"
|
|
438
|
+
aria-label={t('pdf.download')}
|
|
439
|
+
title={t('pdf.download')}
|
|
440
|
+
>
|
|
441
|
+
<Download className="size-4" />
|
|
442
|
+
</Button>
|
|
443
|
+
}
|
|
540
444
|
>
|
|
541
|
-
<
|
|
542
|
-
|
|
445
|
+
<MenuItem className="text-xs" onClick={() => downloadArtifact('grounded-extraction.json')}>
|
|
446
|
+
<FileJson2 className="size-4" />
|
|
447
|
+
{t('grounded.downloadCitations')}
|
|
448
|
+
</MenuItem>
|
|
449
|
+
<MenuItem className="text-xs" onClick={() => downloadArtifact(`pages/page-${page}.json`)}>
|
|
450
|
+
<FileText className="size-4" />
|
|
451
|
+
{t('grounded.downloadBlocks')}
|
|
452
|
+
</MenuItem>
|
|
453
|
+
<MenuItem className="text-xs" onClick={() => downloadArtifact('grounded-annotated.pdf')}>
|
|
454
|
+
<FileDown className="size-4" />
|
|
455
|
+
{t('grounded.downloadAnnotated')}
|
|
456
|
+
</MenuItem>
|
|
457
|
+
</Dropdown>
|
|
543
458
|
{!!onClose && (
|
|
544
459
|
<Button variant="ghost" size="xs" onClick={onClose} aria-label={t('pdf.close')}>
|
|
545
460
|
<X className="size-4" />
|
|
@@ -547,49 +462,14 @@ function GroundedExtractionViewImpl({
|
|
|
547
462
|
)}
|
|
548
463
|
</div>
|
|
549
464
|
</div>
|
|
550
|
-
{
|
|
551
|
-
<div className="shrink-0 border-b border-border bg-background px-3 py-2 text-sm">
|
|
552
|
-
<div className="flex items-center gap-2">
|
|
553
|
-
<span
|
|
554
|
-
className={cn(
|
|
555
|
-
'font-medium',
|
|
556
|
-
extraction.verdict === 'good_to_go' ? 'text-success' : 'text-attention',
|
|
557
|
-
)}
|
|
558
|
-
>
|
|
559
|
-
{extraction.verdict === 'good_to_go'
|
|
560
|
-
? t('grounded.verdictGoodToGo')
|
|
561
|
-
: t('grounded.verdictNeedsReview')}
|
|
562
|
-
</span>
|
|
563
|
-
<span className="text-xs text-muted-foreground">
|
|
564
|
-
{extraction.review
|
|
565
|
-
? t('grounded.verdictByReviewer')
|
|
566
|
-
: t('grounded.verdictByConfidence')}
|
|
567
|
-
</span>
|
|
568
|
-
</div>
|
|
569
|
-
{(extraction.verdict_reason ?? extraction.review?.verdict_reason) && (
|
|
570
|
-
<p className="mt-1 text-xs">
|
|
571
|
-
{extraction.verdict_reason ?? extraction.review?.verdict_reason}
|
|
572
|
-
</p>
|
|
573
|
-
)}
|
|
574
|
-
{extraction.review?.summary && (
|
|
575
|
-
<p className="mt-2 text-xs text-muted-foreground">
|
|
576
|
-
<span className="font-medium text-foreground">{t('grounded.reviewSummary')}: </span>
|
|
577
|
-
{extraction.review.summary}
|
|
578
|
-
</p>
|
|
579
|
-
)}
|
|
580
|
-
{typeof extraction.review?.corrections_applied === 'number' &&
|
|
581
|
-
extraction.review.corrections_applied > 0 && (
|
|
582
|
-
<p className="mt-1 text-xs text-info">
|
|
583
|
-
{t('grounded.reviewCorrections', {
|
|
584
|
-
count: extraction.review.corrections_applied,
|
|
585
|
-
})}
|
|
586
|
-
</p>
|
|
587
|
-
)}
|
|
588
|
-
</div>
|
|
589
|
-
)}
|
|
590
|
-
{showBreakdown && (
|
|
465
|
+
{showDetails && (
|
|
591
466
|
<div className="shrink-0 border-b border-border bg-background px-3 py-2 text-sm max-h-72 overflow-auto">
|
|
592
|
-
<div className="
|
|
467
|
+
<div className="mb-1 flex items-center gap-1">
|
|
468
|
+
<span className="font-medium">{t('grounded.breakdownTitle')}</span>
|
|
469
|
+
<VTooltip description={t('grounded.breakdownVerificationHelp')} size="xs">
|
|
470
|
+
<Info className="size-3 text-muted" />
|
|
471
|
+
</VTooltip>
|
|
472
|
+
</div>
|
|
593
473
|
<div className="grid grid-cols-2 gap-x-4 text-xs">
|
|
594
474
|
<span className="col-span-2 mt-1 font-medium text-success">
|
|
595
475
|
{t('grounded.digitalVerifiedOf', {
|
|
@@ -597,11 +477,11 @@ function GroundedExtractionViewImpl({
|
|
|
597
477
|
total: totalCitations,
|
|
598
478
|
})}
|
|
599
479
|
</span>
|
|
600
|
-
<span className="ps-2 text-muted
|
|
480
|
+
<span className="ps-2 text-muted">{t('grounded.breakdownDigital')}</span>
|
|
601
481
|
<span className="text-end text-success">{breakdown.groups.digital}</span>
|
|
602
|
-
<span className="ps-2 text-muted
|
|
482
|
+
<span className="ps-2 text-muted">{t('grounded.breakdownOcr')}</span>
|
|
603
483
|
<span className="text-end text-success">{breakdown.groups.ocr}</span>
|
|
604
|
-
<span className="ps-2 text-muted
|
|
484
|
+
<span className="ps-2 text-muted">{t('grounded.breakdownSnapped')}</span>
|
|
605
485
|
<span className="text-end text-success">{breakdown.groups.snapped}</span>
|
|
606
486
|
<span className="col-span-2 mt-2 font-medium text-success">
|
|
607
487
|
{t('grounded.modelVerifiedOf', {
|
|
@@ -609,24 +489,48 @@ function GroundedExtractionViewImpl({
|
|
|
609
489
|
total: totalCitations,
|
|
610
490
|
})}
|
|
611
491
|
</span>
|
|
612
|
-
<span className="ps-2 text-muted
|
|
492
|
+
<span className="ps-2 text-muted">{t('grounded.breakdownReviewer')}</span>
|
|
613
493
|
<span className="text-end text-success">{breakdown.groups.reviewerConfirmed}</span>
|
|
614
494
|
{breakdown.groups.imageRead > 0 && (
|
|
615
495
|
<>
|
|
616
496
|
<span className="col-span-2 mt-2 font-medium text-attention">
|
|
617
497
|
{t('grounded.unverifiedCount', { count: breakdown.groups.imageRead })}
|
|
618
498
|
</span>
|
|
619
|
-
<span className="ps-2 text-muted
|
|
620
|
-
{t('grounded.breakdownImageRead')}
|
|
621
|
-
</span>
|
|
499
|
+
<span className="ps-2 text-muted">{t('grounded.breakdownImageRead')}</span>
|
|
622
500
|
<span className="text-end text-attention">{breakdown.groups.imageRead}</span>
|
|
623
501
|
</>
|
|
624
502
|
)}
|
|
625
503
|
</div>
|
|
626
|
-
|
|
504
|
+
{typeof extraction.hardness?.score === 'number' && (
|
|
505
|
+
<p className="mt-2 text-xs text-muted" title={t('grounded.hardnessHint')}>
|
|
506
|
+
{t('grounded.hardness', {
|
|
507
|
+
percent: Math.round(extraction.hardness.score * 100),
|
|
508
|
+
})}
|
|
509
|
+
{extraction.hardness.escalated ? ' ↑' : ''}
|
|
510
|
+
</p>
|
|
511
|
+
)}
|
|
512
|
+
{(extraction.verdict_reason ?? extraction.review?.verdict_reason) && (
|
|
513
|
+
<p className="mt-2 text-xs">
|
|
514
|
+
{extraction.verdict_reason ?? extraction.review?.verdict_reason}
|
|
515
|
+
</p>
|
|
516
|
+
)}
|
|
517
|
+
{extraction.review?.summary && (
|
|
518
|
+
<p className="mt-2 text-xs text-muted">
|
|
519
|
+
<span className="font-medium text-foreground">{t('grounded.reviewSummary')}: </span>
|
|
520
|
+
{extraction.review.summary}
|
|
521
|
+
</p>
|
|
522
|
+
)}
|
|
523
|
+
{typeof extraction.review?.corrections_applied === 'number' &&
|
|
524
|
+
extraction.review.corrections_applied > 0 && (
|
|
525
|
+
<p className="mt-1 text-xs text-info">
|
|
526
|
+
{t('grounded.reviewCorrections', {
|
|
527
|
+
count: extraction.review.corrections_applied,
|
|
528
|
+
})}
|
|
529
|
+
</p>
|
|
530
|
+
)}
|
|
627
531
|
{breakdown.unverified.length > 0 && (
|
|
628
532
|
<div className="mt-2">
|
|
629
|
-
<div className="text-xs font-medium text-muted
|
|
533
|
+
<div className="text-xs font-medium text-muted mb-1">
|
|
630
534
|
{t('grounded.breakdownUnverifiedList')}
|
|
631
535
|
</div>
|
|
632
536
|
<ul className="space-y-0.5">
|
|
@@ -637,10 +541,10 @@ function GroundedExtractionViewImpl({
|
|
|
637
541
|
className="w-full text-start text-xs rounded px-1 py-0.5 hover:bg-muted cursor-pointer"
|
|
638
542
|
onClick={() => {
|
|
639
543
|
selectPath(c.path);
|
|
640
|
-
|
|
544
|
+
setShowDetails(false);
|
|
641
545
|
}}
|
|
642
546
|
>
|
|
643
|
-
<span className="text-muted
|
|
547
|
+
<span className="text-muted">{c.path}</span>{' '}
|
|
644
548
|
<span>{String(c.value ?? '')}</span>
|
|
645
549
|
</button>
|
|
646
550
|
</li>
|
|
@@ -666,19 +570,6 @@ function GroundedExtractionViewImpl({
|
|
|
666
570
|
)}
|
|
667
571
|
</div>
|
|
668
572
|
</ResizablePanel>
|
|
669
|
-
{assistantOpen && (
|
|
670
|
-
<>
|
|
671
|
-
<ResizableHandle className="w-[4px] bg-border cursor-ew-resize" />
|
|
672
|
-
<ResizablePanel defaultSize={30} minSize={20} className="flex flex-col border-s border-border">
|
|
673
|
-
<GroundedExtractionAssistantPanel
|
|
674
|
-
objectId={objectId}
|
|
675
|
-
onExtractionChanged={onExtractionChanged}
|
|
676
|
-
selectedField={selectedPath}
|
|
677
|
-
onClose={() => setAssistantOpen(false)}
|
|
678
|
-
/>
|
|
679
|
-
</ResizablePanel>
|
|
680
|
-
</>
|
|
681
|
-
)}
|
|
682
573
|
</ResizablePanelGroup>
|
|
683
574
|
);
|
|
684
575
|
}
|
|
@@ -741,35 +632,51 @@ function PageWithOverlay({
|
|
|
741
632
|
: `${citation.cells.start}:${citation.cells.end}`
|
|
742
633
|
: undefined;
|
|
743
634
|
return (
|
|
744
|
-
<
|
|
635
|
+
<VTooltip
|
|
745
636
|
key={`${citation.path}-${i}`}
|
|
746
|
-
|
|
747
|
-
|
|
748
|
-
|
|
749
|
-
|
|
750
|
-
|
|
751
|
-
|
|
752
|
-
|
|
753
|
-
|
|
754
|
-
|
|
755
|
-
|
|
756
|
-
|
|
757
|
-
|
|
758
|
-
|
|
759
|
-
|
|
760
|
-
|
|
761
|
-
|
|
762
|
-
|
|
763
|
-
|
|
764
|
-
|
|
765
|
-
|
|
766
|
-
|
|
767
|
-
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
|
|
637
|
+
description={
|
|
638
|
+
<span className="flex flex-col gap-0.5">
|
|
639
|
+
<span className="flex items-center gap-1 font-medium">
|
|
640
|
+
{citationPathLabels(citation.path).map((label, index) => (
|
|
641
|
+
<Fragment key={`${index}:${label}`}>
|
|
642
|
+
{index > 0 && <ChevronRight className="size-3 shrink-0 cn-rtl-flip" />}
|
|
643
|
+
{label}
|
|
644
|
+
</Fragment>
|
|
645
|
+
))}
|
|
646
|
+
</span>
|
|
647
|
+
{cellRange && <span className="font-mono">{cellRange}</span>}
|
|
648
|
+
{citation.source_text && <span>{citation.source_text}</span>}
|
|
649
|
+
</span>
|
|
650
|
+
}
|
|
651
|
+
size="xs"
|
|
652
|
+
asChild
|
|
653
|
+
>
|
|
654
|
+
<button
|
|
655
|
+
type="button"
|
|
656
|
+
aria-label={citation.path}
|
|
657
|
+
onClick={() => onSelectPath(normalizeCitationPath(citation.path))}
|
|
658
|
+
className={cn(
|
|
659
|
+
'absolute cursor-pointer border rounded-[1px] transition-colors',
|
|
660
|
+
citation.misaligned && 'border-dashed',
|
|
661
|
+
isSelected
|
|
662
|
+
? 'border-2 border-primary bg-primary/20 z-10'
|
|
663
|
+
: citation.verified
|
|
664
|
+
? 'border-success/70 hover:bg-success/20'
|
|
665
|
+
: citation.reviewed
|
|
666
|
+
? 'border-info/70 hover:bg-info/20'
|
|
667
|
+
: 'border-attention/80 hover:bg-attention/20',
|
|
668
|
+
)}
|
|
669
|
+
style={{
|
|
670
|
+
// inline position: the app's button base styles override the
|
|
671
|
+
// `absolute` utility class with position: relative
|
|
672
|
+
position: 'absolute',
|
|
673
|
+
left: `${(box.x / dims.width) * 100}%`,
|
|
674
|
+
top: `${(box.y / dims.height) * 100}%`,
|
|
675
|
+
width: `${(box.w / dims.width) * 100}%`,
|
|
676
|
+
height: `${(box.h / dims.height) * 100}%`,
|
|
677
|
+
}}
|
|
678
|
+
/>
|
|
679
|
+
</VTooltip>
|
|
773
680
|
);
|
|
774
681
|
}),
|
|
775
682
|
);
|
|
@@ -876,11 +783,7 @@ function DataNode({
|
|
|
876
783
|
child.every((item) => item !== null && typeof item === 'object');
|
|
877
784
|
return (
|
|
878
785
|
<div key={childPath} className="pt-1">
|
|
879
|
-
{!rendersOwnLabel && (
|
|
880
|
-
<div className="text-xs font-semibold text-muted-foreground uppercase tracking-wide">
|
|
881
|
-
{key}
|
|
882
|
-
</div>
|
|
883
|
-
)}
|
|
786
|
+
{!rendersOwnLabel && <div className="text-sm font-semibold">{propertyTitle(key)}</div>}
|
|
884
787
|
<DataNode
|
|
885
788
|
value={child}
|
|
886
789
|
path={childPath}
|
|
@@ -921,16 +824,16 @@ function ArrayTable({
|
|
|
921
824
|
|
|
922
825
|
return (
|
|
923
826
|
<div className="pt-1">
|
|
924
|
-
<div className="text-
|
|
925
|
-
{path.split('.').pop()} ({items.length})
|
|
827
|
+
<div className="text-sm font-semibold">
|
|
828
|
+
{propertyTitle(path.split('.').pop())} ({items.length})
|
|
926
829
|
</div>
|
|
927
830
|
<div className="overflow-x-auto">
|
|
928
831
|
<table className="w-full text-xs">
|
|
929
832
|
<thead>
|
|
930
|
-
<tr className="text-start text-muted
|
|
833
|
+
<tr className="text-start text-muted">
|
|
931
834
|
{columns.map((col) => (
|
|
932
835
|
<th key={col} scope="col" className="py-1 pe-2 font-medium">
|
|
933
|
-
{col}
|
|
836
|
+
{propertyTitle(col)}
|
|
934
837
|
</th>
|
|
935
838
|
))}
|
|
936
839
|
</tr>
|
|
@@ -950,10 +853,10 @@ function ArrayTable({
|
|
|
950
853
|
className={cn(
|
|
951
854
|
'text-start rounded px-1 w-full',
|
|
952
855
|
isSelected
|
|
953
|
-
? 'bg-
|
|
856
|
+
? 'bg-primary/15 ring-1 ring-primary'
|
|
954
857
|
: citation
|
|
955
858
|
? 'hover:bg-muted cursor-pointer'
|
|
956
|
-
: 'text-muted
|
|
859
|
+
: 'text-muted cursor-default',
|
|
957
860
|
)}
|
|
958
861
|
>
|
|
959
862
|
{formatValue(item[col])}
|
|
@@ -963,7 +866,7 @@ function ArrayTable({
|
|
|
963
866
|
'ms-1 text-[10px]',
|
|
964
867
|
scoreColor(citation.confidence),
|
|
965
868
|
)}
|
|
966
|
-
title={t('grounded.
|
|
869
|
+
title={t('grounded.scoreHint')}
|
|
967
870
|
>
|
|
968
871
|
{formatScore(citation.confidence)}
|
|
969
872
|
</span>
|
|
@@ -1006,16 +909,16 @@ function LeafRow({
|
|
|
1006
909
|
onClick={() => citation && onSelect(path)}
|
|
1007
910
|
className={cn(
|
|
1008
911
|
'flex items-center gap-2 w-full text-start text-sm rounded px-1.5 py-0.5',
|
|
1009
|
-
isSelected ? 'bg-
|
|
912
|
+
isSelected ? 'bg-primary/15 ring-1 ring-primary' : citation ? 'hover:bg-muted' : '',
|
|
1010
913
|
!citation && 'cursor-default',
|
|
1011
914
|
)}
|
|
1012
915
|
>
|
|
1013
|
-
<span className="
|
|
916
|
+
<span className="min-w-28 shrink-0 font-semibold">{propertyTitle(label)}:</span>
|
|
1014
917
|
<span className="flex-1 wrap-break-word">{formatValue(value)}</span>
|
|
1015
918
|
{citation && typeof citation.confidence === 'number' && (
|
|
1016
919
|
<span
|
|
1017
920
|
className={cn('text-xs shrink-0', scoreColor(citation.confidence))}
|
|
1018
|
-
title={t('grounded.
|
|
921
|
+
title={t('grounded.scoreHint')}
|
|
1019
922
|
>
|
|
1020
923
|
{formatScore(citation.confidence)}
|
|
1021
924
|
</span>
|
|
@@ -1032,6 +935,23 @@ function LeafRow({
|
|
|
1032
935
|
);
|
|
1033
936
|
}
|
|
1034
937
|
|
|
938
|
+
/**
|
|
939
|
+
* Friendly trail for a citation path, matching the labels in the data panel:
|
|
940
|
+
* "line_items[1].unit_price" -> ["Line items", "Unit price"]. The array index is
|
|
941
|
+
* dropped — the highlighted box already says which row it is.
|
|
942
|
+
*/
|
|
943
|
+
function citationPathLabels(path: string): string[] {
|
|
944
|
+
return normalizeCitationPath(path)
|
|
945
|
+
.split('.')
|
|
946
|
+
.map((segment) => propertyTitle(segment.replace(/\[\d+\]/g, '')))
|
|
947
|
+
.filter(Boolean);
|
|
948
|
+
}
|
|
949
|
+
|
|
950
|
+
/** Friendly label for a property key, matching the standard properties view. */
|
|
951
|
+
function propertyTitle(name: string | undefined): string {
|
|
952
|
+
return name ? computeTitleFromName(name) : '';
|
|
953
|
+
}
|
|
954
|
+
|
|
1035
955
|
/**
|
|
1036
956
|
* Tier scores (1.0, 0.99, 0.5...) are policy values and display as integers;
|
|
1037
957
|
* OCR-measured scores carry real decimals from tesseract and keep two.
|
|
@@ -77,6 +77,14 @@ describe('MCP connection controls', () => {
|
|
|
77
77
|
namespace: 'github',
|
|
78
78
|
url: 'https://github-mcp.example.com',
|
|
79
79
|
},
|
|
80
|
+
{
|
|
81
|
+
type: 'mcp',
|
|
82
|
+
id: 'api-key-tools',
|
|
83
|
+
name: 'API Key Tools',
|
|
84
|
+
namespace: 'api_key_tools',
|
|
85
|
+
url: 'https://api-key-mcp.example.com',
|
|
86
|
+
auth: 'api_key',
|
|
87
|
+
},
|
|
80
88
|
],
|
|
81
89
|
},
|
|
82
90
|
oauth_collection_ids: ['jira', 'miro', 'linear', 'github'],
|
|
@@ -107,6 +115,12 @@ describe('MCP connection controls', () => {
|
|
|
107
115
|
collection_name: 'GitHub',
|
|
108
116
|
mcp_server_url: 'https://github-mcp.example.com',
|
|
109
117
|
},
|
|
118
|
+
{
|
|
119
|
+
authenticated: true,
|
|
120
|
+
collection_id: 'api-key-tools',
|
|
121
|
+
collection_name: 'API Key Tools',
|
|
122
|
+
mcp_server_url: 'https://api-key-mcp.example.com',
|
|
123
|
+
},
|
|
110
124
|
]);
|
|
111
125
|
const onChange = vi.fn();
|
|
112
126
|
|
|
@@ -118,13 +132,16 @@ describe('MCP connection controls', () => {
|
|
|
118
132
|
expect(screen.getByText('Miro')).not.toBeNull();
|
|
119
133
|
expect(screen.getByText('Linear')).not.toBeNull();
|
|
120
134
|
expect(screen.getByText('GitHub')).not.toBeNull();
|
|
135
|
+
expect(screen.getByText('API Key Tools')).not.toBeNull();
|
|
136
|
+
const apiKeyBadge = screen.getByText('API key');
|
|
137
|
+
expect(apiKeyBadge.className).toContain('w-32');
|
|
121
138
|
expect(screen.queryByText('Connected')).toBeNull();
|
|
122
139
|
expect(screen.getAllByRole('button', { name: 'Disconnect' })).toHaveLength(3);
|
|
123
140
|
const connectButton = screen.getByRole('button', { name: 'Connect' });
|
|
124
141
|
const disconnectButton = screen.getAllByRole('button', { name: 'Disconnect' })[0];
|
|
125
142
|
expect(connectButton.className).toContain('w-32');
|
|
126
143
|
expect(disconnectButton.className).toContain('w-32');
|
|
127
|
-
expect(screen.getAllByText('Enabled')).toHaveLength(
|
|
144
|
+
expect(screen.getAllByText('Enabled')).toHaveLength(4);
|
|
128
145
|
expect(screen.getByText('Disabled')).not.toBeNull();
|
|
129
146
|
});
|
|
130
147
|
|