@kortix/ui 0.14.7 → 0.14.9
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 +2 -2
- package/dist/_vendor/kortix-shared.js +64 -4
- package/dist/_vendor/shared/app-config.d.ts +175 -0
- package/dist/_vendor/shared/channel-message.d.ts +34 -5
- package/dist/_vendor/shared/index.d.ts +1 -0
- package/dist/_vendor/shared/runtime-versions.d.ts +4 -0
- package/dist/_vendor/shared/space-slug.d.ts +37 -0
- package/dist/access/access/access-detail-shell.js +1 -1
- package/dist/access/access/access-dialog-share.js +4 -7
- package/dist/access/access/access-dialog.js +2 -1
- package/dist/access/access/principal-picker.d.ts +11 -0
- package/dist/access/access/principal-picker.js +9 -7
- package/dist/apps/app-preview-pool.d.ts +7 -2
- package/dist/apps/app-preview-pool.js +11 -5
- package/dist/apps/app-shared.d.ts +22 -15
- package/dist/apps/app-shared.js +37 -19
- package/dist/apps/index.d.ts +2 -2
- package/dist/apps/index.js +2 -2
- package/dist/artifacts/artifact-frame.d.ts +16 -0
- package/dist/artifacts/artifact-frame.js +51 -0
- package/dist/artifacts/artifact-session.d.ts +18 -0
- package/dist/artifacts/artifact-session.js +101 -0
- package/dist/artifacts/frame-policy.d.ts +30 -0
- package/dist/artifacts/frame-policy.js +61 -0
- package/dist/artifacts/index.d.ts +3 -0
- package/dist/artifacts/index.js +5 -0
- package/dist/browser/sandbox-browser-chrome.d.ts +4 -1
- package/dist/browser/sandbox-browser-chrome.js +2 -2
- package/dist/customize/agents/agent-cover-card.d.ts +17 -0
- package/dist/customize/agents/agent-cover-card.js +13 -0
- package/dist/customize/agents/agent-grant-pages.d.ts +5 -1
- package/dist/customize/agents/agent-grant-pages.js +30 -4
- package/dist/customize/agents/agent-page.js +8 -33
- package/dist/customize/agents/agent-policy-sets.d.ts +43 -0
- package/dist/customize/agents/agent-policy-sets.js +72 -0
- package/dist/customize/agents/agent-triggers-section.js +2 -1
- package/dist/customize/agents/agents-page.js +43 -49
- package/dist/customize/connectors/add-mcp/add-mcp-server-dialog.d.ts +6 -1
- package/dist/customize/connectors/add-mcp/add-mcp-server-dialog.js +10 -4
- package/dist/customize/connectors/agent-access.d.ts +35 -0
- package/dist/customize/connectors/agent-access.js +77 -0
- package/dist/customize/connectors/catalog/browse-sections.d.ts +2 -29
- package/dist/customize/connectors/catalog/browse-sections.js +7 -74
- package/dist/customize/connectors/catalog/catalog-entry.d.ts +18 -37
- package/dist/customize/connectors/catalog/catalog-entry.js +28 -40
- package/dist/customize/connectors/catalog/connector-browse.d.ts +3 -32
- package/dist/customize/connectors/catalog/connector-browse.js +19 -50
- package/dist/customize/connectors/catalog/use-catalog.d.ts +20 -59
- package/dist/customize/connectors/catalog/use-catalog.js +48 -175
- package/dist/customize/connectors/connector-identity.d.ts +9 -11
- package/dist/customize/connectors/connector-identity.js +13 -42
- package/dist/customize/connectors/connector-moves-banner.d.ts +2 -1
- package/dist/customize/connectors/connector-moves-banner.js +4 -6
- package/dist/customize/connectors/connector-routes.d.ts +21 -9
- package/dist/customize/connectors/connector-routes.js +29 -20
- package/dist/customize/connectors/connectors-page.js +53 -82
- package/dist/customize/connectors/detail/app-page.js +226 -98
- package/dist/customize/connectors/detail/computer-app-page.d.ts +16 -0
- package/dist/customize/connectors/detail/computer-app-page.js +39 -0
- package/dist/customize/connectors/detail/connector-accounts.js +3 -1
- package/dist/customize/connectors/detail/connector-advanced-tools.d.ts +4 -1
- package/dist/customize/connectors/detail/connector-advanced-tools.js +2 -2
- package/dist/customize/connectors/detail/connector-agents.d.ts +14 -0
- package/dist/customize/connectors/detail/connector-agents.js +69 -0
- package/dist/customize/connectors/detail/connector-detail-tabs.js +2 -1
- package/dist/customize/connectors/detail/connector-move-row.d.ts +8 -5
- package/dist/customize/connectors/detail/connector-move-row.js +23 -14
- package/dist/customize/connectors/detail/connector-page.d.ts +4 -1
- package/dist/customize/connectors/detail/connector-page.js +14 -10
- package/dist/customize/connectors/detail/connector-policy-sets.d.ts +28 -0
- package/dist/customize/connectors/detail/connector-policy-sets.js +203 -0
- package/dist/customize/connectors/detail/connector-settings.d.ts +4 -1
- package/dist/customize/connectors/detail/connector-settings.js +7 -3
- package/dist/customize/connectors/detail/connector-status.d.ts +19 -6
- package/dist/customize/connectors/detail/connector-status.js +34 -10
- package/dist/customize/connectors/detail/connector-tabs.d.ts +4 -1
- package/dist/customize/connectors/detail/connector-tabs.js +8 -2
- package/dist/customize/connectors/detail/connector-tools.d.ts +3 -3
- package/dist/customize/connectors/detail/connector-tools.js +105 -48
- package/dist/customize/connectors/detail/email-inboxes.d.ts +43 -0
- package/dist/customize/connectors/detail/email-inboxes.js +184 -0
- package/dist/customize/connectors/detail/provider-info.d.ts +1 -1
- package/dist/customize/connectors/detail/provider-info.js +2 -2
- package/dist/customize/connectors/detail/status-badge.d.ts +1 -1
- package/dist/customize/connectors/detail/status-badge.js +4 -5
- package/dist/customize/connectors/detail/use-connector-detail.d.ts +6 -0
- package/dist/customize/connectors/detail/use-connector-detail.js +14 -4
- package/dist/customize/connectors/install/install-dialog.d.ts +23 -0
- package/dist/customize/connectors/install/install-dialog.js +40 -0
- package/dist/customize/connectors/install/install.d.ts +13 -2
- package/dist/customize/connectors/install/install.js +9 -4
- package/dist/customize/connectors/install/use-install.d.ts +19 -2
- package/dist/customize/connectors/install/use-install.js +65 -37
- package/dist/customize/connectors/install/way-kind.d.ts +5 -0
- package/dist/customize/connectors/install/way-kind.js +16 -0
- package/dist/customize/connectors/provider-label.d.ts +2 -1
- package/dist/customize/connectors/provider-label.js +13 -3
- package/dist/customize/connectors/tools/pattern-rule-draft.d.ts +4 -0
- package/dist/customize/connectors/tools/pattern-rule-draft.js +12 -3
- package/dist/customize/connectors/tools/policy-sets.d.ts +27 -0
- package/dist/customize/connectors/tools/policy-sets.js +41 -0
- package/dist/customize/connectors/tools/tool-groups.d.ts +32 -9
- package/dist/customize/connectors/tools/tool-groups.js +78 -16
- package/dist/customize/connectors/tools/tool-policy-control.d.ts +11 -10
- package/dist/customize/connectors/tools/tool-policy-control.js +15 -16
- package/dist/customize/connectors/tools/tool-policy-labels.d.ts +6 -5
- package/dist/customize/connectors/tools/tool-policy-labels.js +17 -16
- package/dist/customize/connectors/tools/tool-policy.d.ts +50 -4
- package/dist/customize/connectors/tools/tool-policy.js +74 -8
- package/dist/customize/connectors/use-agent-access.d.ts +85 -0
- package/dist/customize/connectors/use-agent-access.js +72 -0
- package/dist/customize/migrate-to-v2/index.d.ts +1 -2
- package/dist/customize/migrate-to-v2/index.js +1 -2
- package/dist/customize/migrate-to-v2/migration-prompt.d.ts +12 -24
- package/dist/customize/migrate-to-v2/migration-prompt.js +34 -235
- package/dist/customize/migrate-to-v2/upgrade-defs.d.ts +1 -1
- package/dist/customize/migrate-to-v2/upgrade-defs.js +7 -6
- package/dist/customize/migrate-to-v2/upgrade-view.js +7 -7
- package/dist/customize/migrate-to-v2/use-run-upgrade.d.ts +3 -3
- package/dist/customize/providers/provider-accordion.js +17 -2
- package/dist/customize/sections/component/channel-access-panel.d.ts +16 -0
- package/dist/customize/sections/component/channel-access-panel.js +146 -0
- package/dist/customize/sections/component/channel-connect-hero.d.ts +3 -2
- package/dist/customize/sections/component/channel-connect-hero.js +3 -2
- package/dist/customize/sections/component/channel-hero-frame.d.ts +31 -0
- package/dist/customize/sections/component/channel-hero-frame.js +40 -0
- package/dist/customize/sections/component/channel-mocks.d.ts +6 -0
- package/dist/customize/sections/component/channel-mocks.js +46 -0
- package/dist/customize/sections/component/channel-row.d.ts +13 -3
- package/dist/customize/sections/component/channel-row.js +10 -4
- package/dist/customize/sections/component/email-connect-form.d.ts +27 -0
- package/dist/customize/sections/component/email-connect-form.js +183 -0
- package/dist/customize/sections/component/slack-connect-card.d.ts +7 -0
- package/dist/customize/sections/component/slack-connect-card.js +2 -3
- package/dist/customize/sections/component/teams-connect-card.d.ts +7 -0
- package/dist/customize/sections/component/teams-connect-card.js +2 -3
- package/dist/customize/sections/component/telegram-channel-row.js +16 -25
- package/dist/customize/sections/connectors-view.d.ts +1 -15
- package/dist/customize/sections/connectors-view.js +81 -314
- package/dist/customize/sections/view/agent-editor-catalog.js +5 -0
- package/dist/customize/sections/view/channels-view.d.ts +5 -1
- package/dist/customize/sections/view/channels-view.js +63 -81
- package/dist/customize/sections/view/gateway/gateway-overview.js +10 -2
- package/dist/customize/settings/tabs/experimental-tab.js +35 -16
- package/dist/customize/shared/catalog/catalog-empty-state.d.ts +1 -12
- package/dist/customize/shared/catalog/catalog-empty-state.js +3 -3
- package/dist/customize/shared/channels-switch-dialog.d.ts +18 -0
- package/dist/customize/shared/channels-switch-dialog.js +30 -0
- package/dist/customize/shared/feature-gate-screen.js +27 -9
- package/dist/customize/shared/new-entity-menu.js +4 -1
- package/dist/customize/shared/use-customize-prefetch.d.ts +2 -3
- package/dist/customize/shared/use-customize-prefetch.js +9 -27
- package/dist/customize/skills/skills-page.js +4 -5
- package/dist/customize/triggers/schedule/post-to-field.d.ts +18 -0
- package/dist/customize/triggers/schedule/post-to-field.js +49 -0
- package/dist/customize/triggers/schedule/schedule-copy.d.ts +10 -6
- package/dist/customize/triggers/schedule/schedule-copy.js +42 -11
- package/dist/customize/triggers/schedule/schedule-detail-sheet.js +2 -1
- package/dist/customize/triggers/schedule/then-fields.js +1 -5
- package/dist/customize/triggers/schedule/trigger-composer-logic.d.ts +22 -0
- package/dist/customize/triggers/schedule/trigger-composer-logic.js +25 -0
- package/dist/customize/triggers/schedule/trigger-composer.d.ts +5 -0
- package/dist/customize/triggers/schedule/trigger-composer.js +23 -14
- package/dist/customize/triggers/schedule/trigger-edit-logic.js +3 -0
- package/dist/customize/triggers/schedule/trigger-filter.js +1 -1
- package/dist/customize/triggers/schedule/trigger-runs-logic.d.ts +2 -2
- package/dist/customize/triggers/schedule/trigger-runs-panel.js +1 -0
- package/dist/customize/triggers/schedule/trigger-toast.js +2 -1
- package/dist/customize/triggers/schedule-view.js +9 -4
- package/dist/files/index.d.ts +1 -0
- package/dist/files/index.js +1 -0
- package/dist/files/project/change-request-recovery.d.ts +1 -26
- package/dist/files/project/change-request-recovery.js +1 -59
- package/dist/files/project/components/change-request-detail-dialog.js +13 -3
- package/dist/files/project/components/drive-explorer.js +15 -15
- package/dist/files/project/components/drive-toolbar.d.ts +16 -2
- package/dist/files/project/components/drive-toolbar.js +14 -5
- package/dist/files/project/hooks/use-change-request-recovery.js +3 -19
- package/dist/files/project/hooks/use-change-requests.d.ts +1 -0
- package/dist/files/project/hooks/use-change-requests.js +11 -2
- package/dist/files/renderers/image-frame.d.ts +46 -0
- package/dist/files/renderers/image-frame.js +59 -0
- package/dist/files/renderers/image-renderer.d.ts +11 -1
- package/dist/files/renderers/image-renderer.js +13 -3
- package/dist/files/renderers/pdf/pdf-clipboard.d.ts +2 -0
- package/dist/files/renderers/pdf/pdf-clipboard.js +21 -0
- package/dist/files/renderers/pdf/pdf-viewer.js +4 -2
- package/dist/files/renderers/show-content-renderer.d.ts +9 -1
- package/dist/files/renderers/show-content-renderer.js +56 -14
- package/dist/files/runtime/file-source.js +2 -0
- package/dist/files/runtime/hooks/use-binary-blob.d.ts +10 -1
- package/dist/files/runtime/hooks/use-binary-blob.js +10 -4
- package/dist/files/runtime/hooks/use-shared-image.d.ts +41 -0
- package/dist/files/runtime/hooks/use-shared-image.js +177 -0
- package/dist/files/viewer/file-content-renderer.d.ts +22 -1
- package/dist/files/viewer/file-content-renderer.js +50 -7
- package/dist/files/viewer/file-header.d.ts +7 -3
- package/dist/files/viewer/file-header.js +20 -11
- package/dist/files/viewer/file-preview-modal.d.ts +1 -1
- package/dist/files/viewer/file-preview-modal.js +10 -22
- package/dist/files/viewer/file-source.d.ts +13 -0
- package/dist/files/viewer/use-file-content-state.d.ts +2 -0
- package/dist/files/viewer/use-file-content-state.js +28 -10
- package/dist/files/viewer/viewer-actions.d.ts +3 -1
- package/dist/files/viewer/viewer-actions.js +2 -2
- package/dist/hooks/use-media-query.d.ts +1 -0
- package/dist/hooks/use-mobile.d.ts +5 -0
- package/dist/hooks/use-mobile.js +8 -0
- package/dist/i18n/en.d.ts +906 -70
- package/dist/i18n/en.js +924 -88
- package/dist/i18n/ui-catalog/localize-ui-catalog.js +4 -0
- package/dist/i18n/ui-catalog/remaining-ui-translation-keys.generated.js +15 -3
- package/dist/index.d.ts +2 -2
- package/dist/index.js +2 -2
- package/dist/internal/account-hub/account-settings-sidebar.js +1 -1
- package/dist/internal/account-hub/hub-sheet.d.ts +9 -1
- package/dist/internal/account-hub/hub-sheet.js +21 -5
- package/dist/internal/account-hub/sections.d.ts +1 -1
- package/dist/internal/account-hub/sections.js +2 -1
- package/dist/internal/auth/auth-card-shell.js +3 -3
- package/dist/internal/components/agent-mark.d.ts +38 -0
- package/dist/internal/components/agent-mark.js +41 -0
- package/dist/internal/connector-logo/connector-logo-source.d.ts +63 -0
- package/dist/internal/connector-logo/connector-logo-source.js +48 -0
- package/dist/internal/connector-logo/connector-logo.d.ts +39 -0
- package/dist/internal/connector-logo/connector-logo.js +56 -0
- package/dist/internal/connector-logo/connector-mark-files.d.ts +11 -0
- package/dist/internal/connector-logo/connector-mark-files.js +35 -0
- package/dist/internal/files/file-read-retry.d.ts +13 -0
- package/dist/internal/files/file-read-retry.js +23 -3
- package/dist/internal/files/session-drive-files.d.ts +5 -1
- package/dist/internal/files/session-drive-files.js +7 -2
- package/dist/internal/hooks/channels/use-channels-installations.d.ts +32 -5
- package/dist/internal/hooks/channels/use-channels-installations.js +55 -7
- package/dist/internal/hooks/channels/use-email-inboxes.d.ts +19 -0
- package/dist/internal/hooks/channels/use-email-inboxes.js +48 -0
- package/dist/internal/hooks/connectors/use-add-account.js +1 -1
- package/dist/internal/hooks/index.d.ts +1 -1
- package/dist/internal/hooks/index.js +1 -1
- package/dist/internal/hooks/projects/use-new-project-session.d.ts +9 -0
- package/dist/internal/hooks/projects/use-new-project-session.js +28 -12
- package/dist/internal/hooks/use-auto-scroll.d.ts +8 -1
- package/dist/internal/hooks/use-auto-scroll.js +4 -4
- package/dist/internal/icons/telegram.d.ts +5 -0
- package/dist/internal/icons/telegram.js +6 -1
- package/dist/internal/layout/nav-hover-card.d.ts +35 -0
- package/dist/internal/layout/nav-hover-card.js +84 -0
- package/dist/internal/layout/project-nav-row.d.ts +3 -1
- package/dist/internal/layout/project-nav-row.js +3 -2
- package/dist/internal/layout/project-page-header.d.ts +4 -2
- package/dist/internal/layout/project-page-header.js +4 -3
- package/dist/internal/layout/project-settings-nav.js +59 -2
- package/dist/internal/lib/browser-error-noise.d.ts +1 -1
- package/dist/internal/lib/browser-error-noise.js +1 -1
- package/dist/internal/lib/browser-noise/rules/injected-scripts.d.ts +7 -0
- package/dist/internal/lib/browser-noise/rules/injected-scripts.js +15 -0
- package/dist/internal/lib/manifest-version.d.ts +1 -1
- package/dist/internal/lib/manifest-version.js +2 -2
- package/dist/internal/lib/memory-href.d.ts +16 -0
- package/dist/internal/lib/memory-href.js +46 -0
- package/dist/internal/lib/pixel-mark.d.ts +33 -0
- package/dist/internal/lib/pixel-mark.js +152 -0
- package/dist/internal/lib/use-project-feature-flags.js +11 -11
- package/dist/internal/lib/utils/heic-convert.d.ts +1 -1
- package/dist/internal/lib/utils/heic-convert.js +3 -4
- package/dist/internal/lib/web-notifications.d.ts +20 -0
- package/dist/internal/lib/web-notifications.js +48 -4
- package/dist/internal/notifications/notification-bell.d.ts +4 -1
- package/dist/internal/notifications/notification-bell.js +2 -2
- package/dist/internal/selection/selection-bar.d.ts +2 -1
- package/dist/internal/selection/selection-bar.js +1 -1
- package/dist/internal/stores/file-preview-store.d.ts +29 -2
- package/dist/internal/stores/file-preview-store.js +19 -1
- package/dist/internal/stores/kortix-computer-store.js +3 -0
- package/dist/internal/stores/sidebar-nav-store.d.ts +1 -1
- package/dist/internal/stores/sidebar-nav-store.js +3 -1
- package/dist/lib/routes.d.ts +13 -1
- package/dist/lib/routes.js +13 -0
- package/dist/markdown/genui/components/inline.d.ts +1 -1
- package/dist/markdown/index.d.ts +2 -1
- package/dist/markdown/index.js +2 -1
- package/dist/markdown/setup-links/approval-decision.d.ts +1 -0
- package/dist/markdown/setup-links/approval-decision.js +6 -2
- package/dist/markdown/setup-links/connector-handshake.d.ts +3 -1
- package/dist/markdown/setup-links/connector-handshake.js +12 -10
- package/dist/markdown/setup-links/show-connect-hero.d.ts +28 -0
- package/dist/markdown/setup-links/show-connect-hero.js +91 -0
- package/dist/markdown/unified-markdown.js +5 -5
- package/dist/primitives/badge.d.ts +1 -1
- package/dist/primitives/badge.js +2 -0
- package/dist/primitives/disclosure.js +14 -2
- package/dist/primitives/empty-art.d.ts +12 -0
- package/dist/primitives/empty-art.js +11 -0
- package/dist/primitives/entity-avatar.d.ts +4 -1
- package/dist/primitives/entity-avatar.js +4 -2
- package/dist/primitives/mermaid-renderer.d.ts +2 -0
- package/dist/primitives/mermaid-renderer.js +21 -15
- package/dist/primitives/resizable.js +6 -1
- package/dist/primitives/resize-seam.d.ts +11 -0
- package/dist/primitives/resize-seam.js +12 -0
- package/dist/primitives/sidebar-panel.js +4 -7
- package/dist/primitives/tabs.d.ts +14 -1
- package/dist/primitives/tabs.js +1 -1
- package/dist/primitives/user-avatar.d.ts +3 -1
- package/dist/primitives/user-avatar.js +4 -2
- package/dist/providers/ui-provider.d.ts +10 -1
- package/dist/session/composer/ComposerAboveCard.d.ts +1 -1
- package/dist/session/composer/ComposerAboveCard.js +2 -2
- package/dist/session/composer/ComposerCard.d.ts +1 -1
- package/dist/session/composer/ComposerCard.js +3 -3
- package/dist/session/composer/agent-selector.d.ts +19 -1
- package/dist/session/composer/agent-selector.js +42 -12
- package/dist/session/composer/composer-agent-access.d.ts +15 -0
- package/dist/session/composer/composer-agent-access.js +27 -0
- package/dist/session/composer/composer-chat-input.d.ts +8 -2
- package/dist/session/composer/composer-chat-input.js +8 -6
- package/dist/session/composer/composer-logic.d.ts +16 -0
- package/dist/session/composer/composer-logic.js +12 -0
- package/dist/session/composer/composer-underbar.d.ts +3 -1
- package/dist/session/composer/composer-underbar.js +4 -3
- package/dist/session/composer/composer.d.ts +15 -1
- package/dist/session/composer/composer.js +19 -1
- package/dist/session/composer/context-usage.d.ts +5 -0
- package/dist/session/composer/context-usage.js +6 -1
- package/dist/session/composer/draft/composer-draft.d.ts +6 -2
- package/dist/session/composer/draft/composer-draft.js +5 -1
- package/dist/session/composer/reasoning-effort-selector.js +1 -1
- package/dist/session/composer/token-progress.js +4 -4
- package/dist/session/header/export-transcript-modal.d.ts +3 -2
- package/dist/session/header/export-transcript-modal.js +6 -3
- package/dist/session/models/chatgpt-connection-button.d.ts +11 -0
- package/dist/session/models/chatgpt-connection-button.js +54 -0
- package/dist/session/models/model-selector.d.ts +3 -1
- package/dist/session/models/model-selector.js +7 -3
- package/dist/session/models/use-model-connection-gate.d.ts +5 -5
- package/dist/session/models/use-model-connection-gate.js +5 -5
- package/dist/session/outcomes/jump-to-outcome.d.ts +10 -0
- package/dist/session/outcomes/jump-to-outcome.js +11 -0
- package/dist/session/outcomes/session-outcomes-bridge.d.ts +14 -0
- package/dist/session/outcomes/session-outcomes-bridge.js +12 -0
- package/dist/session/outcomes/session-outcomes-provider.d.ts +3 -1
- package/dist/session/outcomes/session-outcomes-provider.js +33 -3
- package/dist/session/panel/easy/app-preview.d.ts +10 -0
- package/dist/session/panel/easy/app-preview.js +31 -12
- package/dist/session/panel/easy/change-requests-card.d.ts +7 -0
- package/dist/session/panel/easy/change-requests-card.js +17 -0
- package/dist/session/panel/easy/easy-panel-logic.js +7 -1
- package/dist/session/panel/easy/easy-panel.js +5 -2
- package/dist/session/panel/easy/file-preview.js +1 -1
- package/dist/session/panel/easy/outputs-card.d.ts +2 -1
- package/dist/session/panel/easy/outputs-card.js +3 -2
- package/dist/session/panel/easy/plan-card.d.ts +2 -0
- package/dist/session/panel/easy/plan-card.js +2 -0
- package/dist/session/panel/mobile-tool-drawer.js +7 -1
- package/dist/session/panel/session-audit-panel.js +9 -2
- package/dist/session/panel/session-detail-panel.js +9 -3
- package/dist/session/panel/session-files-explorer.d.ts +9 -0
- package/dist/session/panel/session-files-explorer.js +12 -3
- package/dist/session/panel/session-panel-provider.d.ts +15 -1
- package/dist/session/panel/session-panel-provider.js +32 -7
- package/dist/session/panel/shared/derive-panels.d.ts +8 -1
- package/dist/session/panel/shared/derive-panels.js +12 -2
- package/dist/session/panel/shared/output-priority.js +2 -0
- package/dist/session/participants/session-participants.d.ts +5 -1
- package/dist/session/participants/session-participants.js +9 -2
- package/dist/session/prompts/approval-request.d.ts +5 -0
- package/dist/session/prompts/approval-request.js +7 -1
- package/dist/session/prompts/session-approval-review.d.ts +9 -0
- package/dist/session/prompts/session-approval-review.js +18 -0
- package/dist/session/status/session-error-banner.js +2 -49
- package/dist/session/status/session-starting-loader.d.ts +14 -2
- package/dist/session/status/session-starting-loader.js +16 -4
- package/dist/session/thread/after-first-prompt.d.ts +7 -0
- package/dist/session/thread/after-first-prompt.js +8 -0
- package/dist/session/thread/detect-command.d.ts +12 -0
- package/dist/session/thread/detect-command.js +20 -0
- package/dist/session/thread/plan-surface.d.ts +1 -0
- package/dist/session/thread/plan-surface.js +1 -0
- package/dist/session/thread/session-chat.d.ts +3 -1
- package/dist/session/thread/session-chat.js +377 -252
- package/dist/session/thread/session-context-metrics.d.ts +15 -0
- package/dist/session/thread/session-context-metrics.js +10 -1
- package/dist/session/thread/session-context-modal.d.ts +4 -2
- package/dist/session/thread/session-context-modal.js +16 -9
- package/dist/session/thread/session-thread.d.ts +3 -1
- package/dist/session/thread/session-thread.js +9 -2
- package/dist/session/thread/thread-boot-rows.d.ts +36 -0
- package/dist/session/thread/thread-boot-rows.js +89 -0
- package/dist/session/thread/transcript-rows.d.ts +31 -0
- package/dist/session/thread/transcript-rows.js +3 -0
- package/dist/session/thread/transcript.d.ts +4 -9
- package/dist/session/thread/transcript.js +119 -21
- package/dist/session/thread/turn-share.d.ts +16 -0
- package/dist/session/thread/turn-share.js +162 -0
- package/dist/session/tool/shared/infrastructure-contexts.d.ts +28 -0
- package/dist/session/tool/shared/infrastructure-contexts.js +31 -3
- package/dist/session/tool/tool-part-renderer.d.ts +5 -4
- package/dist/session/tool/tool-part-renderer.js +8 -3
- package/dist/session/tool/tools/apply-patch-tool.d.ts +1 -0
- package/dist/session/tool/tools/apply-patch-tool.js +1 -0
- package/dist/session/tool/tools/bash-tool.js +7 -6
- package/dist/session/tool/tools/channel-send-card.d.ts +1 -2
- package/dist/session/tool/tools/channel-send.d.ts +2 -1
- package/dist/session/tool/tools/codemode-tool.js +1 -1
- package/dist/session/tool/tools/connector-tools.js +1 -1
- package/dist/session/tool/tools/image-gen-tool.d.ts +1 -1
- package/dist/session/tool/tools/image-gen-tool.js +240 -53
- package/dist/session/tool/tools/pty-kill-tool.d.ts +1 -0
- package/dist/session/tool/tools/pty-kill-tool.js +1 -0
- package/dist/session/tool/tools/pty-read-tool.d.ts +2 -0
- package/dist/session/tool/tools/pty-read-tool.js +2 -0
- package/dist/session/tool/tools/pty-spawn-tool.d.ts +1 -0
- package/dist/session/tool/tools/pty-spawn-tool.js +1 -0
- package/dist/session/tool/tools/pty-write-tool.d.ts +1 -0
- package/dist/session/tool/tools/pty-write-tool.js +1 -0
- package/dist/session/tool/tools/show-tool.js +19 -8
- package/dist/session/tool/tools/todo-write-tool.d.ts +1 -0
- package/dist/session/tool/tools/todo-write-tool.js +1 -0
- package/dist/session/turn/channel-brand.d.ts +8 -3
- package/dist/session/turn/channel-brand.js +20 -4
- package/dist/session/turn/message-author-label.js +6 -2
- package/dist/session/turn/message-author.d.ts +8 -0
- package/dist/session/turn/message-author.js +24 -0
- package/dist/session/turn/message-row.d.ts +52 -0
- package/dist/session/turn/message-row.js +44 -0
- package/dist/session/turn/plan-anchor.d.ts +4 -1
- package/dist/session/turn/plan-anchor.js +4 -1
- package/dist/session/turn/plan-card.d.ts +7 -0
- package/dist/session/turn/plan-card.js +7 -0
- package/dist/session/turn/user-message.d.ts +7 -1
- package/dist/session/turn/user-message.js +21 -7
- package/dist/styles.css +1 -1
- package/dist/terminal/session-terminal-connect-bar.js +2 -1
- package/dist/workspace/home/access-requests-bell.d.ts +9 -2
- package/dist/workspace/home/access-requests-bell.js +20 -6
- package/dist/workspace/home/first-chat.d.ts +8 -21
- package/dist/workspace/home/first-chat.js +22 -72
- package/dist/workspace/index.d.ts +6 -0
- package/dist/workspace/index.js +6 -0
- package/dist/workspace/layout/project-home.d.ts +14 -2
- package/dist/workspace/layout/project-home.js +60 -21
- package/dist/workspace/layout/use-project-home-send.d.ts +9 -1
- package/dist/workspace/layout/use-project-home-send.js +82 -3
- package/dist/workspace/memory/body-doc.d.ts +17 -0
- package/dist/workspace/memory/body-doc.js +208 -0
- package/dist/workspace/memory/body-extensions.d.ts +38 -0
- package/dist/workspace/memory/body-extensions.js +103 -0
- package/dist/workspace/memory/company-memory-page.d.ts +8 -0
- package/dist/workspace/memory/company-memory-page.js +16 -0
- package/dist/workspace/memory/memory-all.d.ts +20 -0
- package/dist/workspace/memory/memory-all.js +27 -0
- package/dist/workspace/memory/memory-body.d.ts +19 -0
- package/dist/workspace/memory/memory-body.js +139 -0
- package/dist/workspace/memory/memory-empty.d.ts +13 -0
- package/dist/workspace/memory/memory-empty.js +28 -0
- package/dist/workspace/memory/memory-history.d.ts +27 -0
- package/dist/workspace/memory/memory-history.js +108 -0
- package/dist/workspace/memory/memory-labels.d.ts +16 -0
- package/dist/workspace/memory/memory-labels.js +47 -0
- package/dist/workspace/memory/memory-page-list.d.ts +34 -0
- package/dist/workspace/memory/memory-page-list.js +156 -0
- package/dist/workspace/memory/memory-reader.d.ts +58 -0
- package/dist/workspace/memory/memory-reader.js +123 -0
- package/dist/workspace/memory/memory-view.d.ts +21 -0
- package/dist/workspace/memory/memory-view.js +124 -0
- package/dist/workspace/memory/remember-popover.d.ts +19 -0
- package/dist/workspace/memory/remember-popover.js +61 -0
- package/dist/workspace/memory/remember-this.d.ts +12 -0
- package/dist/workspace/memory/remember-this.js +89 -0
- package/dist/workspace/memory/source-mark.d.ts +18 -0
- package/dist/workspace/memory/source-mark.js +79 -0
- package/dist/workspace/memory/used-memory-chip.d.ts +14 -0
- package/dist/workspace/memory/used-memory-chip.js +61 -0
- package/dist/workspace/new/advanced-fields.d.ts +2 -1
- package/dist/workspace/new/advanced-fields.js +2 -2
- package/dist/workspace/new/source-param.d.ts +1 -1
- package/dist/workspace/new/source-param.js +3 -1
- package/dist/workspace/new/use-create-workspace.d.ts +8 -10
- package/dist/workspace/new/use-create-workspace.js +3 -3
- package/dist/workspace/projects/onboarding/app-logo.d.ts +7 -2
- package/dist/workspace/projects/onboarding/app-logo.js +6 -13
- package/dist/workspace/projects/policies-panel.js +5 -3
- package/dist/workspace/review/review-actions.d.ts +4 -2
- package/dist/workspace/review/review-actions.js +8 -2
- package/dist/workspace/review/review-center.js +11 -7
- package/dist/workspace/review/review-detail.d.ts +10 -0
- package/dist/workspace/review/review-detail.js +101 -13
- package/dist/workspace/saved-session-skeleton.d.ts +2 -2
- package/dist/workspace/saved-session-skeleton.js +3 -3
- package/dist/workspace/session-workspace.js +15 -13
- package/dist/workspace/sessions/project-sessions-view.js +3 -2
- package/dist/workspace/sessions/sessions-toolbar.d.ts +3 -1
- package/dist/workspace/sessions/sessions-toolbar.js +2 -2
- package/dist/workspace/sidebar/footer/project-apps-nav.d.ts +5 -0
- package/dist/workspace/sidebar/footer/project-apps-nav.js +41 -2
- package/dist/workspace/sidebar/footer/project-artifacts-nav.d.ts +6 -0
- package/dist/workspace/sidebar/footer/project-artifacts-nav.js +22 -0
- package/dist/workspace/sidebar/footer/project-manifest-upgrade-alert.js +13 -13
- package/dist/workspace/sidebar/footer/project-memory-nav.d.ts +7 -0
- package/dist/workspace/sidebar/footer/project-memory-nav.js +19 -0
- package/dist/workspace/sidebar/nav-row-meta.js +14 -2
- package/dist/workspace/sidebar/project-nav-items.js +3 -0
- package/dist/workspace/sidebar/project-session-list.js +68 -56
- package/dist/workspace/sidebar/project-sidebar.js +9 -2
- package/dist/workspace/sidebar/project-spaces-nav.d.ts +8 -0
- package/dist/workspace/sidebar/project-spaces-nav.js +69 -0
- package/dist/workspace/sidebar/session-brief-hover-card.js +28 -1
- package/dist/workspace/sidebar/session-group-order.d.ts +9 -0
- package/dist/workspace/sidebar/session-group-order.js +25 -0
- package/dist/workspace/sidebar/session-group-sections.d.ts +62 -0
- package/dist/workspace/sidebar/session-group-sections.js +267 -0
- package/dist/workspace/sidebar/session-list-chrome.d.ts +28 -0
- package/dist/workspace/sidebar/session-list-chrome.js +50 -0
- package/dist/workspace/spaces/channel-glyph.d.ts +5 -0
- package/dist/workspace/spaces/channel-glyph.js +6 -0
- package/dist/workspace/spaces/channel-setup.d.ts +16 -0
- package/dist/workspace/spaces/channel-setup.js +105 -0
- package/dist/workspace/spaces/channels-onboarding.d.ts +13 -0
- package/dist/workspace/spaces/channels-onboarding.js +37 -0
- package/dist/workspace/spaces/create-channel-dialog.d.ts +16 -0
- package/dist/workspace/spaces/create-channel-dialog.js +158 -0
- package/dist/workspace/spaces/private-channels-not-in.d.ts +9 -0
- package/dist/workspace/spaces/private-channels-not-in.js +69 -0
- package/dist/workspace/spaces/space-agents.d.ts +10 -0
- package/dist/workspace/spaces/space-agents.js +10 -0
- package/dist/workspace/spaces/space-details-dialog.d.ts +20 -0
- package/dist/workspace/spaces/space-details-dialog.js +176 -0
- package/dist/workspace/spaces/space-link-label.d.ts +49 -0
- package/dist/workspace/spaces/space-link-label.js +73 -0
- package/dist/workspace/spaces/space-links.d.ts +19 -0
- package/dist/workspace/spaces/space-links.js +230 -0
- package/dist/workspace/spaces/space-members.d.ts +46 -0
- package/dist/workspace/spaces/space-members.js +182 -0
- package/dist/workspace/spaces/space-roster.d.ts +15 -0
- package/dist/workspace/spaces/space-roster.js +44 -0
- package/dist/workspace/spaces/space-threads-tab.d.ts +56 -0
- package/dist/workspace/spaces/space-threads-tab.js +156 -0
- package/dist/workspace/spaces/space-timeline-view.d.ts +254 -0
- package/dist/workspace/spaces/space-timeline-view.js +235 -0
- package/dist/workspace/spaces/space-timeline.d.ts +106 -0
- package/dist/workspace/spaces/space-timeline.js +183 -0
- package/dist/workspace/spaces/space-triggers.d.ts +13 -0
- package/dist/workspace/spaces/space-triggers.js +78 -0
- package/dist/workspace/spaces/space-view.d.ts +37 -0
- package/dist/workspace/spaces/space-view.js +436 -0
- package/package.json +31 -32
- package/skills/kortix-ui/SKILL.md +3 -3
- package/skills/kortix-ui/references/custom-dashboard.md +3 -3
- package/skills/kortix-ui/references/modules.md +28 -4
- package/skills/kortix-ui/references/theming.md +1 -1
- package/dist/customize/agents/agent-nav.prototype.d.ts +0 -35
- package/dist/customize/agents/agent-nav.prototype.js +0 -95
- package/dist/customize/connectors/catalog/merge-search.d.ts +0 -10
- package/dist/customize/connectors/catalog/merge-search.js +0 -26
- package/dist/customize/connectors/detail/find-easy-connect-app.d.ts +0 -29
- package/dist/customize/connectors/detail/find-easy-connect-app.js +0 -22
- package/dist/customize/migrate-to-v2/use-migrate-to-v2.d.ts +0 -9
- package/dist/customize/migrate-to-v2/use-migrate-to-v2.js +0 -24
- package/dist/customize/sections/connector-connection-header.d.ts +0 -36
- package/dist/customize/sections/connector-connection-header.js +0 -33
- package/dist/customize/sections/connector-connection-modal.d.ts +0 -34
- package/dist/customize/sections/connector-connection-modal.js +0 -72
- package/dist/customize/sections/discover-catalogue-card.d.ts +0 -19
- package/dist/customize/sections/discover-catalogue-card.js +0 -26
- package/dist/customize/sections/discover-catalogue-detail.d.ts +0 -15
- package/dist/customize/sections/discover-catalogue-detail.js +0 -24
- package/dist/customize/sections/discover-catalogue.d.ts +0 -17
- package/dist/customize/sections/discover-catalogue.js +0 -132
- package/dist/customize/sections/llm-provider/provider-access-menu.d.ts +0 -10
- package/dist/customize/sections/llm-provider/provider-access-menu.js +0 -23
- package/dist/files/project/components/drive-empty-art.d.ts +0 -2
- package/dist/files/project/components/drive-empty-art.js +0 -5
- package/dist/internal/hooks/use-media-query.d.ts +0 -2
- package/dist/internal/share/public-share-link-button.d.ts +0 -14
- package/dist/internal/share/public-share-link-button.js +0 -17
- /package/dist/{internal/hooks → hooks}/use-media-query.js +0 -0
|
@@ -24,6 +24,8 @@ import { SessionAuditPanel } from './session-audit-panel.js';
|
|
|
24
24
|
import { SessionRemindersPanel } from './session-reminders-panel.js';
|
|
25
25
|
import { SessionFilesExplorer } from './session-files-explorer.js';
|
|
26
26
|
import { SessionTerminalPanel } from '../../terminal/session-terminal-panel.js';
|
|
27
|
+
import { SessionBootStatus } from '../status/session-starting-loader.js';
|
|
28
|
+
import { useOptionalSessionPanel } from './session-panel-provider.js';
|
|
27
29
|
import { useLocalizedUiCatalog } from '../../i18n/ui-catalog/use-localized-ui-catalog.js';
|
|
28
30
|
import { useKortixComputerStore } from '../../internal/stores/kortix-computer-store.js';
|
|
29
31
|
import { sessionPreviewTabId } from '../../internal/stores/session-browser-store.js';
|
|
@@ -40,5 +42,9 @@ export function MobileToolDrawer({ sessionId, projectId, projectSessionId, }) {
|
|
|
40
42
|
const closeMobileTool = useKortixComputerStore((s) => s.closeMobileTool);
|
|
41
43
|
const toolMeta = useLocalizedUiCatalog(TOOL_META);
|
|
42
44
|
const meta = view ? toolMeta[view] : null;
|
|
43
|
-
|
|
45
|
+
// Terminal, Browser and Files need the computer: while it boots, the drawer
|
|
46
|
+
// shows the wake status in their place.
|
|
47
|
+
const booting = !!useOptionalSessionPanel()?.booting &&
|
|
48
|
+
(view === 'terminal' || view === 'browser' || view === 'files');
|
|
49
|
+
return (_jsx(Drawer, { open: view !== null, onOpenChange: (next) => !next && closeMobileTool(), children: _jsxs(DrawerContent, { className: "flex h-[95dvh] max-h-[95dvh] min-h-[95dvh] flex-col overflow-hidden p-0", children: [_jsx(DrawerHeader, { className: "shrink-0 px-4 py-3 text-left", children: _jsxs(DrawerTitle, { className: "flex items-center justify-between gap-2 text-base", children: [_jsxs("span", { className: "flex items-center gap-2.5", children: [meta && _jsx(meta.Icon, { className: "text-muted-foreground size-4 shrink-0" }), meta?.label] }), _jsx(CloseButton, { onClose: closeMobileTool, variant: "ghost" })] }) }), _jsxs("div", { className: "min-h-0 flex-1 overflow-hidden", children: [booting && _jsx(SessionBootStatus, { projectId: projectId, sessionId: projectSessionId }), !booting && view === 'terminal' && (_jsx(SessionTerminalPanel, { sessionId: sessionId, projectId: projectId, projectSessionId: projectSessionId })), !booting && view === 'browser' && (_jsx(BrowserPanel, { tabId: sessionPreviewTabId(sessionId), projectId: projectId, projectSessionId: projectSessionId })), !booting && view === 'files' && (_jsx(SessionFilesExplorer, { chatSessionId: sessionId, projectId: projectId, projectSessionId: projectSessionId })), view === 'audit' && (_jsx(SessionAuditPanel, { projectId: projectId, projectSessionId: projectSessionId })), view === 'reminders' && (_jsx("div", { className: "h-full overflow-y-auto p-4", children: _jsx(SessionRemindersPanel, { projectId: projectId, projectSessionId: projectSessionId }) }))] })] }) }));
|
|
44
50
|
}
|
|
@@ -8,15 +8,20 @@ import { Modal, ModalBody, ModalContent, ModalDescription, ModalHeader, ModalTit
|
|
|
8
8
|
import { errorToast, successToast } from '../../primitives/toast.js';
|
|
9
9
|
import { EmptyState } from '../../primitives/empty-state.js';
|
|
10
10
|
import { ErrorState } from '../../primitives/error-state.js';
|
|
11
|
-
import { approvalLauncherName, approvalRequestFromAction, } from '../prompts/session-approval-review.js';
|
|
11
|
+
import { approvalLauncherName, approvalRequestFromAction, auditPolicySet, } from '../prompts/session-approval-review.js';
|
|
12
12
|
import { isPendingAction, relativeTime, riskTone, statusLabel, statusTone, useResolveApproval, useSessionAudit, useSessionAuditTimeline, } from './session-audit-shared.js';
|
|
13
13
|
import { credentialVia } from './audit/audit-credential-label.js';
|
|
14
14
|
import { useTranslations } from '../../i18n/index.js';
|
|
15
15
|
import { useProjectSession } from '@kortix/sdk/react';
|
|
16
16
|
import { CaretRightIcon, ShieldCheckIcon } from '@phosphor-icons/react';
|
|
17
17
|
import { useMemo, useState } from 'react';
|
|
18
|
+
/** The policy set that decided a history row, if one did. */
|
|
19
|
+
function setNameOf(action) {
|
|
20
|
+
return auditPolicySet(action.result_summary)?.name ?? null;
|
|
21
|
+
}
|
|
18
22
|
export function SessionAuditPanel({ projectId, projectSessionId, }) {
|
|
19
23
|
const tI18nComplete = useTranslations('hardcodedUi.i18nComplete');
|
|
24
|
+
const tSets = useTranslations('connectorPolicySets');
|
|
20
25
|
const approvalQuery = useSessionAudit(projectId, projectSessionId);
|
|
21
26
|
const { data } = approvalQuery;
|
|
22
27
|
const timelineQuery = useSessionAuditTimeline(projectId, projectSessionId, {
|
|
@@ -74,7 +79,9 @@ export function SessionAuditPanel({ projectId, projectSessionId, }) {
|
|
|
74
79
|
: 'muted', size: "xs", className: "capitalize", children: event.outcome ?? 'recorded' })] }), _jsxs("p", { className: "text-muted-foreground mt-0.5 truncate text-xs", children: [credentialVia(event, (key) => tI18nComplete.raw(key)) ??
|
|
75
80
|
event.authoritative_source ??
|
|
76
81
|
event.source ??
|
|
77
|
-
'system', ' ', "\u00B7", ' ', relativeTime(event.occurred_at)] })] }), _jsx(CaretRightIcon, { className: "text-muted-foreground size-4 shrink-0" })] }) }, event.event_id))) }), timelineQuery.hasNextPage ? (_jsx("div", { className: "flex justify-center pt-1", children: _jsxs(Button, { size: "sm", variant: "outline", disabled: timelineQuery.isFetchingNextPage, onClick: () => void timelineQuery.fetchNextPage(), children: [timelineQuery.isFetchingNextPage ? _jsx(Loading, { className: "size-3.5" }) : null, tI18nComplete.raw('text96f2482de866')] }) })) : null] })) : null, history.length > 0 ? (_jsxs("section", { className: "space-y-3", children: [_jsx("h3", { className: "text-muted-foreground text-xs font-medium", children: tI18nComplete.raw('text0e7696009337') }), _jsx("ul", { className: "bg-popover overflow-hidden rounded-md border", children: history.map((action) => (_jsx("li", { className: "border-border border-b last:border-b-0", children: _jsxs("button", { type: "button", className: "hover:bg-primary/[0.03] flex min-h-12 w-full items-center gap-3 px-4 py-2 text-left transition-[background-color,transform] active:scale-[0.96]", onClick: () => setSelected(action), children: [_jsxs("div", { className: "min-w-0 flex-1", children: [_jsxs("div", { className: "flex flex-wrap items-center gap-1.5", children: [_jsx("code", { className: "text-foreground truncate font-mono text-sm", children: action.action }), action.risk ? (_jsx(Badge, { variant: riskTone(action.risk), size: "xs", className: "capitalize", children: action.risk })) : null, _jsx(Badge, { variant: statusTone(action.status), size: "xs", children: statusLabel(action.status) })] }), _jsxs("p", { className: "text-muted-foreground mt-0.5 truncate text-xs", children: [action.acted_by_email ?? 'agent', " \u00B7 ", relativeTime(action.at), action
|
|
82
|
+
'system', ' ', "\u00B7", ' ', relativeTime(event.occurred_at)] })] }), _jsx(CaretRightIcon, { className: "text-muted-foreground size-4 shrink-0" })] }) }, event.event_id))) }), timelineQuery.hasNextPage ? (_jsx("div", { className: "flex justify-center pt-1", children: _jsxs(Button, { size: "sm", variant: "outline", disabled: timelineQuery.isFetchingNextPage, onClick: () => void timelineQuery.fetchNextPage(), children: [timelineQuery.isFetchingNextPage ? _jsx(Loading, { className: "size-3.5" }) : null, tI18nComplete.raw('text96f2482de866')] }) })) : null] })) : null, history.length > 0 ? (_jsxs("section", { className: "space-y-3", children: [_jsx("h3", { className: "text-muted-foreground text-xs font-medium", children: tI18nComplete.raw('text0e7696009337') }), _jsx("ul", { className: "bg-popover overflow-hidden rounded-md border", children: history.map((action) => (_jsx("li", { className: "border-border border-b last:border-b-0", children: _jsxs("button", { type: "button", className: "hover:bg-primary/[0.03] flex min-h-12 w-full items-center gap-3 px-4 py-2 text-left transition-[background-color,transform] active:scale-[0.96]", onClick: () => setSelected(action), children: [_jsxs("div", { className: "min-w-0 flex-1", children: [_jsxs("div", { className: "flex flex-wrap items-center gap-1.5", children: [_jsx("code", { className: "text-foreground truncate font-mono text-sm", children: action.action }), action.risk ? (_jsx(Badge, { variant: riskTone(action.risk), size: "xs", className: "capitalize", children: action.risk })) : null, _jsx(Badge, { variant: statusTone(action.status), size: "xs", children: statusLabel(action.status) })] }), _jsxs("p", { className: "text-muted-foreground mt-0.5 truncate text-xs", children: [action.acted_by_email ?? 'agent', " \u00B7 ", relativeTime(action.at), setNameOf(action)
|
|
83
|
+
? ` · ${tSets('auditSet', { set: setNameOf(action) })}`
|
|
84
|
+
: '', action.resolved_by_email
|
|
78
85
|
? tI18nComplete('text0e16f24ee012', {
|
|
79
86
|
value0: action.status === 'denied' ? 'denied' : 'approved',
|
|
80
87
|
value1: action.resolved_by_email,
|
|
@@ -22,6 +22,7 @@ import { useTranslations } from '../../i18n/index.js';
|
|
|
22
22
|
*/
|
|
23
23
|
import { Drawer, DrawerContent, DrawerHeader, DrawerTitle } from '../../primitives/drawer.js';
|
|
24
24
|
import { SessionTerminalPanel } from '../../terminal/session-terminal-panel.js';
|
|
25
|
+
import { SessionBootStatus } from '../status/session-starting-loader.js';
|
|
25
26
|
import { useIsMobile } from '../../internal/hooks/index.js';
|
|
26
27
|
import { TerminalIcon } from '@phosphor-icons/react';
|
|
27
28
|
import { CloseButton, DetailLayer } from './easy/detail-view.js';
|
|
@@ -34,17 +35,22 @@ export function SessionDetailPanel() {
|
|
|
34
35
|
if (!panel)
|
|
35
36
|
return null;
|
|
36
37
|
const { detail, closeDetail, terminalOpen, terminalSwap, closeTerminal, sessionId } = panel;
|
|
37
|
-
const { projectId, projectSessionId } = panel;
|
|
38
|
+
const { projectId, projectSessionId, booting } = panel;
|
|
39
|
+
// While the computer boots, a card wears its real chrome over the wake status,
|
|
40
|
+
// and the panel with no card open shows that status alone, never blank.
|
|
38
41
|
const terminalLayer = {
|
|
39
42
|
open: terminalOpen,
|
|
40
43
|
swap: terminalSwap,
|
|
41
44
|
title: tI18nComplete.raw('texte0926fdac700'),
|
|
42
45
|
icon: _jsx(TerminalIcon, { className: "text-muted-foreground size-4 shrink-0" }),
|
|
43
46
|
onClose: closeTerminal,
|
|
44
|
-
body: (_jsx(SessionTerminalPanel, { sessionId: sessionId, projectId: projectId, projectSessionId: projectSessionId, hidden: !terminalOpen })),
|
|
47
|
+
body: booting ? (_jsx(SessionBootStatus, { projectId: projectId, sessionId: projectSessionId })) : (_jsx(SessionTerminalPanel, { sessionId: sessionId, projectId: projectId, projectSessionId: projectSessionId, hidden: !terminalOpen })),
|
|
45
48
|
};
|
|
49
|
+
if (isMobile && booting) {
|
|
50
|
+
return _jsx(SessionBootStatus, { projectId: projectId, sessionId: projectSessionId });
|
|
51
|
+
}
|
|
46
52
|
if (isMobile) {
|
|
47
53
|
return (_jsxs("div", { className: "relative h-full w-full", children: [_jsx(DetailLayer, { detail: detail, onBack: closeDetail, isMobile: true, children: _jsx("div", { className: "h-full overflow-auto p-3", children: _jsx(EasyPanel, {}) }) }), _jsx(Drawer, { open: terminalOpen, onOpenChange: (next) => !next && closeTerminal(), children: _jsxs(DrawerContent, { className: "flex h-[95dvh] max-h-[95dvh] flex-col overflow-hidden p-0", children: [_jsx(DrawerHeader, { className: "shrink-0 px-4 py-3 text-left", children: _jsxs(DrawerTitle, { className: "flex items-center justify-between gap-2 text-base", children: [_jsxs("span", { className: "flex items-center gap-2.5", children: [_jsx(TerminalIcon, { className: "text-muted-foreground size-4 shrink-0" }), tI18nComplete.raw('texte0926fdac700')] }), _jsx(CloseButton, { onClose: closeTerminal, variant: "ghost" })] }) }), _jsx("div", { className: "min-h-0 flex-1 overflow-hidden", children: _jsx(SessionTerminalPanel, { sessionId: sessionId, projectId: projectId, projectSessionId: projectSessionId }) })] }) })] }));
|
|
48
54
|
}
|
|
49
|
-
return (_jsx("div", { className: "relative h-full w-full", children: _jsx(DetailLayer, { detail: detail, onBack: closeDetail, isMobile: false, persistentLayer: terminalLayer }) }));
|
|
55
|
+
return (_jsx("div", { className: "relative h-full w-full", children: _jsx(DetailLayer, { detail: detail, onBack: closeDetail, isMobile: false, persistentLayer: terminalLayer, children: booting && !detail && !terminalOpen ? (_jsx(SessionBootStatus, { projectId: projectId, sessionId: projectSessionId })) : null }) }));
|
|
50
56
|
}
|
|
@@ -36,3 +36,12 @@ export declare function SessionFilesExplorer({ chatSessionId, projectId, project
|
|
|
36
36
|
*/
|
|
37
37
|
ephemeral?: boolean;
|
|
38
38
|
}): import("react").JSX.Element;
|
|
39
|
+
/**
|
|
40
|
+
* The explorer's chrome while the session's computer boots: the same tab row,
|
|
41
|
+
* New and View buttons, all disabled, over `children` (the boot status). Mounts
|
|
42
|
+
* nothing that reads the sandbox.
|
|
43
|
+
*/
|
|
44
|
+
export declare function SessionFilesBooting({ mode, children, }: {
|
|
45
|
+
mode: SessionPanelMode;
|
|
46
|
+
children: React.ReactNode;
|
|
47
|
+
}): import("react").JSX.Element;
|
|
@@ -7,7 +7,7 @@ import Loading from '../../primitives/loading.js';
|
|
|
7
7
|
import { Tabs, TabsContent, TabsList, TabsTrigger } from '../../primitives/tabs.js';
|
|
8
8
|
import { FilesStoreProvider, useFilesStore } from '../../files/runtime/index.js';
|
|
9
9
|
import { SandboxFileExplorer } from '../../files/runtime/sandbox-file-explorer.js';
|
|
10
|
-
import { DRIVE_ACTION_ROW_CLASS } from '../../files/project/components/drive-toolbar.js';
|
|
10
|
+
import { DRIVE_ACTION_ROW_CLASS, DriveActionRow, DriveNewMenu, DriveViewMenu, } from '../../files/project/components/drive-toolbar.js';
|
|
11
11
|
import { useOpenChangeRequest, useSessionBaseRef, useSessionChanges, } from './session-changes-shared.js';
|
|
12
12
|
import { SessionDiffViewer } from './session-diff-viewer.js';
|
|
13
13
|
import { deriveExplorerMode, explorerViewForMode, initialExplorerNonce, } from './session-files-explorer-logic.js';
|
|
@@ -94,15 +94,24 @@ function SessionFilesExplorerInner({ chatSessionId, projectId, projectSessionId,
|
|
|
94
94
|
? { projectId: routeProjectId, ref: gitSessionId }
|
|
95
95
|
: undefined })) : (_jsxs(_Fragment, { children: [_jsxs("div", { className: DRIVE_ACTION_ROW_CLASS, children: [_jsx(PanelTabs, { changedCount: changedCount }), changedCount > 0 && (_jsxs(Button, { size: "xs", className: "ml-auto shrink-0 gap-1.5 active:scale-[0.96]", onClick: openChangeRequest, disabled: asking, children: [asking ? _jsx(Loading, { className: "size-3.5 shrink-0" }) : null, tI18nComplete.raw('text73eeb5083986')] }))] }), _jsxs(TabsContent, { value: "changes", className: "flex min-h-0 flex-1 flex-col overflow-hidden", children: [_jsxs("div", { className: "flex flex-wrap items-center gap-1.5 px-2 pt-2", children: [versionId && (_jsxs(_Fragment, { children: [_jsx(Badge, { variant: "outline", size: "sm", className: "font-mono", children: versionId }), _jsx(ArrowRightIcon, { "aria-hidden": true, className: "text-muted-foreground/40 size-3 shrink-0" }), _jsx("span", { className: "sr-only", children: tI18nComplete.raw('text6b847a0ed0b2') })] })), _jsx(Badge, { variant: "outline", size: "sm", className: "max-w-32 min-w-0 font-mono", children: _jsx("span", { className: "truncate", children: baseRef }) }), _jsx("span", { className: "text-muted-foreground text-xs", children: tI18nComplete.raw('text4c31974fceb2') })] }), _jsx("div", { className: "min-h-0 flex-1", children: _jsx(SessionDiffViewer, {}) })] })] })) }));
|
|
96
96
|
}
|
|
97
|
+
/**
|
|
98
|
+
* The explorer's chrome while the session's computer boots: the same tab row,
|
|
99
|
+
* New and View buttons, all disabled, over `children` (the boot status). Mounts
|
|
100
|
+
* nothing that reads the sandbox.
|
|
101
|
+
*/
|
|
102
|
+
export function SessionFilesBooting({ mode, children, }) {
|
|
103
|
+
return (_jsxs(Tabs, { value: mode, className: "bg-background flex h-full min-h-0 flex-col gap-0", children: [_jsx(DriveActionRow, { leading: _jsx(PanelTabs, { changedCount: 0, disabled: true }), actions: mode === 'files' ? (_jsxs(_Fragment, { children: [_jsx(DriveNewMenu, { compact: true, disabled: true }), _jsx(DriveViewMenu, { variant: "secondary", disabled: true, onRefresh: noop, onDownloadDir: noop })] })) : null }), _jsx("div", { className: "flex min-h-0 flex-1 flex-col", children: children })] }));
|
|
104
|
+
}
|
|
105
|
+
const noop = () => { };
|
|
97
106
|
/** The tab strip, shared by both branches so it renders identically on each. */
|
|
98
|
-
function PanelTabs({ changedCount }) {
|
|
107
|
+
function PanelTabs({ changedCount, disabled }) {
|
|
99
108
|
const tI18nComplete = useTranslations('hardcodedUi.i18nComplete');
|
|
100
109
|
return (
|
|
101
110
|
// The row draws the rule, so the list keeps only the sliding underline,
|
|
102
111
|
// and fills the row's height so that underline lands on the row's border.
|
|
103
112
|
// Triggers carry no padding, so the first tab's text starts on the row's
|
|
104
113
|
// own left edge.
|
|
105
|
-
_jsxs(TabsList, { type: "underline", className: "h-full gap-5 border-b-0", children: [_jsx(TabsTrigger, { value: "files", className: "w-fit flex-none px-0", children: tI18nComplete.raw('text866956901fd1') }), _jsxs(TabsTrigger, { value: "changes", className: "w-fit flex-none gap-1.5 px-0", children: [tI18nComplete.raw('textbbd4b6a86bc6'), changedCount > 0 && (_jsx(CountBadge, { count: changedCount }))] })] }));
|
|
114
|
+
_jsxs(TabsList, { type: "underline", className: "h-full gap-5 border-b-0", children: [_jsx(TabsTrigger, { value: "files", disabled: disabled, className: "w-fit flex-none px-0", children: tI18nComplete.raw('text866956901fd1') }), _jsxs(TabsTrigger, { value: "changes", disabled: disabled, className: "w-fit flex-none gap-1.5 px-0", children: [tI18nComplete.raw('textbbd4b6a86bc6'), changedCount > 0 && (_jsx(CountBadge, { count: changedCount }))] })] }));
|
|
106
115
|
}
|
|
107
116
|
/**
|
|
108
117
|
* The All files panel — the explorer's listing region, wearing the tab-panel
|
|
@@ -8,6 +8,9 @@ export interface SessionPanelValue {
|
|
|
8
8
|
sessionId: string;
|
|
9
9
|
projectId?: string;
|
|
10
10
|
projectSessionId?: string;
|
|
11
|
+
/** The session's computer is still starting (the boot shell). Tool cards
|
|
12
|
+
* draw their chrome around a status body until it is up. */
|
|
13
|
+
booting?: boolean;
|
|
11
14
|
/** Card data — everything the floating overlay renders. */
|
|
12
15
|
files: OutputItem[];
|
|
13
16
|
context: ReturnType<typeof deriveContext>;
|
|
@@ -46,7 +49,16 @@ export declare const SessionPanelContext: import("react").Context<SessionPanelVa
|
|
|
46
49
|
* than every call site having to know which tree it is in.
|
|
47
50
|
*/
|
|
48
51
|
export declare function useOptionalSessionPanel(): SessionPanelValue | null;
|
|
49
|
-
|
|
52
|
+
/**
|
|
53
|
+
* A tool card's body: `boot` while the session's computer starts, `children`
|
|
54
|
+
* once it is up. Read at render time, not when the card opens, so a card
|
|
55
|
+
* opened during boot turns live in place.
|
|
56
|
+
*/
|
|
57
|
+
export declare function SessionBootGate({ boot, children }: {
|
|
58
|
+
boot: ReactNode;
|
|
59
|
+
children: ReactNode;
|
|
60
|
+
}): ReactNode;
|
|
61
|
+
export declare function SessionPanelProvider({ sessionId, isSessionBusy, projectId, projectSessionId, booting, children, }: {
|
|
50
62
|
/** The runtime session id: the root thread of the session log. */
|
|
51
63
|
sessionId: string;
|
|
52
64
|
/** The session's own busy/retry status — see `deriveIsRunning`. */
|
|
@@ -56,5 +68,7 @@ export declare function SessionPanelProvider({ sessionId, isSessionBusy, project
|
|
|
56
68
|
* case the palette's "Open Audit" consume below becomes a no-op. */
|
|
57
69
|
projectId?: string;
|
|
58
70
|
projectSessionId?: string;
|
|
71
|
+
/** See `SessionPanelValue.booting`. */
|
|
72
|
+
booting?: boolean;
|
|
59
73
|
children: ReactNode;
|
|
60
74
|
}): import("react").JSX.Element;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
'use client';
|
|
2
2
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
3
|
+
import { ArtifactPanelPreview } from '../../artifacts/artifact-session.js';
|
|
3
4
|
import { useTranslations } from '../../i18n/index.js';
|
|
4
5
|
/**
|
|
5
6
|
* `SessionPanelProvider` — the single owner of everything a session's panel
|
|
@@ -28,7 +29,8 @@ import { useTranslations } from '../../i18n/index.js';
|
|
|
28
29
|
*/
|
|
29
30
|
import { SessionAuditPanel } from './session-audit-panel.js';
|
|
30
31
|
import { SessionRemindersPanel } from './session-reminders-panel.js';
|
|
31
|
-
import { SessionFilesExplorer } from './session-files-explorer.js';
|
|
32
|
+
import { SessionFilesBooting, SessionFilesExplorer } from './session-files-explorer.js';
|
|
33
|
+
import { SessionBootStatus } from '../status/session-starting-loader.js';
|
|
32
34
|
import { useSandboxProxy } from '../../internal/hooks/use-sandbox-proxy.js';
|
|
33
35
|
import { OutputPathsContext } from '../../markdown/code/output-paths-context.js';
|
|
34
36
|
import { useIsMobile } from '../../hooks/use-mobile.js';
|
|
@@ -45,7 +47,7 @@ import { qk } from '@kortix/sdk/react';
|
|
|
45
47
|
import { FileTextIcon as FileText } from '@phosphor-icons/react';
|
|
46
48
|
import { useQueryClient } from '@tanstack/react-query';
|
|
47
49
|
import { createContext, useCallback, useContext, useEffect, useMemo, useRef, useState, } from 'react';
|
|
48
|
-
import { AppPreview } from './easy/app-preview.js';
|
|
50
|
+
import { AppPreview, AppPreviewBooting } from './easy/app-preview.js';
|
|
49
51
|
import { isWideDeliverable, neighborOutputs, outputKey, quickBrowserOutput, } from './easy/easy-panel-logic.js';
|
|
50
52
|
import { FilePreview, reportsIntrinsicSize } from './easy/file-preview.js';
|
|
51
53
|
import { usePanelDerivations } from './shared/use-panel-derivations.js';
|
|
@@ -71,7 +73,15 @@ export const SessionPanelContext = createContext(null);
|
|
|
71
73
|
export function useOptionalSessionPanel() {
|
|
72
74
|
return useContext(SessionPanelContext);
|
|
73
75
|
}
|
|
74
|
-
|
|
76
|
+
/**
|
|
77
|
+
* A tool card's body: `boot` while the session's computer starts, `children`
|
|
78
|
+
* once it is up. Read at render time, not when the card opens, so a card
|
|
79
|
+
* opened during boot turns live in place.
|
|
80
|
+
*/
|
|
81
|
+
export function SessionBootGate({ boot, children }) {
|
|
82
|
+
return useOptionalSessionPanel()?.booting ? boot : children;
|
|
83
|
+
}
|
|
84
|
+
export function SessionPanelProvider({ sessionId, isSessionBusy = false, projectId, projectSessionId, booting = false, children, }) {
|
|
75
85
|
const tI18nComplete = useTranslations('hardcodedUi.i18nComplete');
|
|
76
86
|
const tReminders = useTranslations('reminders');
|
|
77
87
|
const { steps, outputs, context, apps, files, isRunning, outcome } = usePanelDerivations({
|
|
@@ -335,9 +345,22 @@ export function SessionPanelProvider({ sessionId, isSessionBusy = false, project
|
|
|
335
345
|
hideHeader: true,
|
|
336
346
|
padded: false,
|
|
337
347
|
nav,
|
|
338
|
-
body: (_jsx(AppPreview, { url: output.url ?? '', name: displayName, projectId: projectId, shareContext: projectId && projectSessionId
|
|
339
|
-
|
|
340
|
-
|
|
348
|
+
body: (_jsx(SessionBootGate, { boot: _jsx(AppPreviewBooting, { onClose: closeDetail, children: _jsx(SessionBootStatus, { projectId: projectId, sessionId: projectSessionId }) }), children: _jsx(AppPreview, { url: output.url ?? '', name: displayName, projectId: projectId, shareContext: projectId && projectSessionId
|
|
349
|
+
? { projectId, sessionId: projectSessionId }
|
|
350
|
+
: undefined, onClose: closeDetail, onSendToAgent: () => sendAppToAgent(output) }) })),
|
|
351
|
+
});
|
|
352
|
+
setPanelSplit(split);
|
|
353
|
+
return;
|
|
354
|
+
}
|
|
355
|
+
if (output.kind === 'artifact') {
|
|
356
|
+
track('deliverable_opened', { kind: output.kind, source });
|
|
357
|
+
openDetail({
|
|
358
|
+
key: `artifact:${output.url}`,
|
|
359
|
+
title: displayName,
|
|
360
|
+
hideHeader: true,
|
|
361
|
+
padded: false,
|
|
362
|
+
nav,
|
|
363
|
+
body: _jsx(ArtifactPanelPreview, { url: output.url, onClose: closeDetail }),
|
|
341
364
|
});
|
|
342
365
|
setPanelSplit(split);
|
|
343
366
|
return;
|
|
@@ -404,7 +427,7 @@ export function SessionPanelProvider({ sessionId, isSessionBusy = false, project
|
|
|
404
427
|
key: changes ? 'files:changes' : 'files',
|
|
405
428
|
title: changes ? 'Changes' : 'Files',
|
|
406
429
|
padded: false,
|
|
407
|
-
body: (_jsx(SessionFilesExplorer, { chatSessionId: sessionId, projectId: projectId, projectSessionId: projectSessionId, ephemeral: true, initialMode: changes ? 'changes' : 'files' })),
|
|
430
|
+
body: (_jsx(SessionBootGate, { boot: _jsx(SessionFilesBooting, { mode: changes ? 'changes' : 'files', children: _jsx(SessionBootStatus, { projectId: projectId, sessionId: projectSessionId }) }), children: _jsx(SessionFilesExplorer, { chatSessionId: sessionId, projectId: projectId, projectSessionId: projectSessionId, ephemeral: true, initialMode: changes ? 'changes' : 'files' }) })),
|
|
408
431
|
});
|
|
409
432
|
}, [openDetail, sessionId, projectId, projectSessionId]);
|
|
410
433
|
/**
|
|
@@ -544,6 +567,7 @@ export function SessionPanelProvider({ sessionId, isSessionBusy = false, project
|
|
|
544
567
|
sessionId,
|
|
545
568
|
projectId,
|
|
546
569
|
projectSessionId,
|
|
570
|
+
booting,
|
|
547
571
|
files,
|
|
548
572
|
context,
|
|
549
573
|
apps,
|
|
@@ -564,6 +588,7 @@ export function SessionPanelProvider({ sessionId, isSessionBusy = false, project
|
|
|
564
588
|
sessionId,
|
|
565
589
|
projectId,
|
|
566
590
|
projectSessionId,
|
|
591
|
+
booting,
|
|
567
592
|
files,
|
|
568
593
|
context,
|
|
569
594
|
apps,
|
|
@@ -51,7 +51,14 @@ type AppOutputItem = OutputItemBase & {
|
|
|
51
51
|
url: string;
|
|
52
52
|
presentationName?: never;
|
|
53
53
|
};
|
|
54
|
-
|
|
54
|
+
/** A Kortix artifact the agent handed over (its app link): opens as the artifact, not as a website. */
|
|
55
|
+
type ArtifactLinkOutputItem = OutputItemBase & {
|
|
56
|
+
kind: 'artifact';
|
|
57
|
+
path?: never;
|
|
58
|
+
url: string;
|
|
59
|
+
presentationName?: never;
|
|
60
|
+
};
|
|
61
|
+
export type OutputItem = ArtifactOutputItem | AppOutputItem | ArtifactLinkOutputItem;
|
|
55
62
|
export interface ContextItem {
|
|
56
63
|
callID: string;
|
|
57
64
|
label: string;
|
|
@@ -12,6 +12,7 @@
|
|
|
12
12
|
* tables, or the two cards could disagree with what Progress just narrated
|
|
13
13
|
* for the same call.
|
|
14
14
|
*/
|
|
15
|
+
import { parseArtifactUrl } from '../../../artifacts/frame-policy.js';
|
|
15
16
|
import { toWorkspaceRelative } from '../../../internal/files/runtime-files.js';
|
|
16
17
|
import { parseImageOutput } from '../../media/image-output-path.js';
|
|
17
18
|
import { parsePresentationOutput } from '@kortix/sdk';
|
|
@@ -20,7 +21,7 @@ import { looksLikeHtml, parseWebSearchOutput, wsDomain, } from '@kortix/sdk';
|
|
|
20
21
|
import { getToolPrimaryArg, normalizeName } from '../../tool/tool-meta.js';
|
|
21
22
|
import { extractReadableHtml } from '../../../_vendor/kortix-shared.js';
|
|
22
23
|
import { contextLabelForTool, createArtifactKind, familyForTool, narrationToolName as humanizeToolName, } from '@kortix/sdk';
|
|
23
|
-
import { toolCallMetadata, toolKind } from '@kortix/sdk';
|
|
24
|
+
import { imageGenView, toolCallMetadata, toolKind } from '@kortix/sdk';
|
|
24
25
|
function filePathOf(call) {
|
|
25
26
|
const input = inputOf(call);
|
|
26
27
|
const p = input.filePath ?? input.file_path ?? input.path;
|
|
@@ -119,7 +120,7 @@ function createArtifactName(call) {
|
|
|
119
120
|
if (name)
|
|
120
121
|
return { name, path: imagePath };
|
|
121
122
|
}
|
|
122
|
-
const prompt =
|
|
123
|
+
const prompt = imageGenView(call).prompts[0] ?? '';
|
|
123
124
|
return { name: prompt ? truncate(prompt) : 'Image' };
|
|
124
125
|
}
|
|
125
126
|
if (t === 'presentation_gen') {
|
|
@@ -214,6 +215,13 @@ export function deriveOutputs(calls, opts) {
|
|
|
214
215
|
const kind = createArtifactKind(call);
|
|
215
216
|
if (!kind)
|
|
216
217
|
continue;
|
|
218
|
+
// One image_gen call makes up to four images: one row per file.
|
|
219
|
+
const images = kind === 'image' ? imageGenView(call).images.flatMap((image) => (image.imagePath ? [image.imagePath] : [])) : [];
|
|
220
|
+
if (images.length) {
|
|
221
|
+
for (const path of images)
|
|
222
|
+
push({ callID: call.call_id, name: basename(path), path, kind });
|
|
223
|
+
continue;
|
|
224
|
+
}
|
|
217
225
|
const { name, path } = createArtifactName(call);
|
|
218
226
|
const presentationName = kind === 'presentation'
|
|
219
227
|
? parsePresentationOutput(rawOutputOf(call))?.presentation_name
|
|
@@ -230,6 +238,8 @@ const DECK_EXT = /\.(pptx?|key)$/i;
|
|
|
230
238
|
function showPayloadToOutput(payload, callID) {
|
|
231
239
|
const url = typeof payload.url === 'string' ? payload.url.trim() : '';
|
|
232
240
|
if (url && /^https?:\/\//i.test(url)) {
|
|
241
|
+
if (parseArtifactUrl(url))
|
|
242
|
+
return { ...appOutput(url, payload.title, payload.description, callID), kind: 'artifact', shown: true };
|
|
233
243
|
return { ...appOutput(url, payload.title, payload.description, callID), shown: true };
|
|
234
244
|
}
|
|
235
245
|
const path = typeof payload.path === 'string' ? payload.path.trim() : '';
|
|
@@ -69,6 +69,8 @@ export function isScaffoldingOutput(output) {
|
|
|
69
69
|
export function deliverableKindLabel(output) {
|
|
70
70
|
if (output.kind === 'app')
|
|
71
71
|
return 'Web app';
|
|
72
|
+
if (output.kind === 'artifact')
|
|
73
|
+
return 'Artifact';
|
|
72
74
|
if (output.kind === 'presentation')
|
|
73
75
|
return 'Slides';
|
|
74
76
|
if (output.kind === 'video')
|
|
@@ -4,7 +4,11 @@ import { type ReactNode } from 'react';
|
|
|
4
4
|
type AvatarPerson = Pick<SessionParticipant, 'name' | 'email'> & {
|
|
5
5
|
avatar_url?: string | null;
|
|
6
6
|
};
|
|
7
|
-
/**
|
|
7
|
+
/**
|
|
8
|
+
* The display name, else the email local part. The viewer too: every row names
|
|
9
|
+
* a person. The API sends the email as the name when the profile has none, so
|
|
10
|
+
* a name that is an email address reads as no name.
|
|
11
|
+
*/
|
|
8
12
|
export declare function participantLabel(person: AvatarPerson): string;
|
|
9
13
|
/**
|
|
10
14
|
* A message in a shared session: its member author's avatar above the
|
|
@@ -9,9 +9,16 @@ import { UserAvatar } from '../../primitives/user-avatar.js';
|
|
|
9
9
|
import { useTranslations } from '../../i18n/index.js';
|
|
10
10
|
/** Faces shown in the header before the rest collapse into a count. */
|
|
11
11
|
const STACK_LIMIT = 3;
|
|
12
|
-
/**
|
|
12
|
+
/**
|
|
13
|
+
* The display name, else the email local part. The viewer too: every row names
|
|
14
|
+
* a person. The API sends the email as the name when the profile has none, so
|
|
15
|
+
* a name that is an email address reads as no name.
|
|
16
|
+
*/
|
|
13
17
|
export function participantLabel(person) {
|
|
14
|
-
|
|
18
|
+
const name = person.name?.trim();
|
|
19
|
+
if (name && !name.includes('@'))
|
|
20
|
+
return name;
|
|
21
|
+
return (person.email ?? name)?.split('@')[0] || '';
|
|
15
22
|
}
|
|
16
23
|
function ParticipantAvatar({ person, size }) {
|
|
17
24
|
return (_jsx(UserAvatar, { size: size, name: person.name, email: person.email ?? '', avatarUrl: person.avatar_url ?? null }));
|
|
@@ -28,6 +28,11 @@ export interface ApprovalRequestData {
|
|
|
28
28
|
resolvedPreview?: Record<string, unknown> | null;
|
|
29
29
|
/** Set when the server could not load that content (`unavailable`). */
|
|
30
30
|
resolvedError?: string | null;
|
|
31
|
+
/** The agent's policy set that decided the call (`auditPolicySet`). */
|
|
32
|
+
policySet?: {
|
|
33
|
+
name: string;
|
|
34
|
+
agent: string | null;
|
|
35
|
+
} | null;
|
|
31
36
|
resolution?: ApprovalDecisionValue | null;
|
|
32
37
|
pending: boolean;
|
|
33
38
|
status?: string | null;
|
|
@@ -496,6 +496,7 @@ export function ApprovalDecisionActions({ onDecision, busyDecision = null, appro
|
|
|
496
496
|
}
|
|
497
497
|
export function ApprovalRequest({ request, onDecision, busyDecision = null, outcome = null, error = null, hideDecision = false, resolverName = null, className, }) {
|
|
498
498
|
const tI18nComplete = useTranslations('hardcodedUi.i18nComplete');
|
|
499
|
+
const tSets = useTranslations('connectorPolicySets');
|
|
499
500
|
const reviewComplete = request.reviewComplete !== false;
|
|
500
501
|
const reviewable = approvalReviewable(request.argsPreview, request.reviewComplete, request.resolvedPreview);
|
|
501
502
|
const waiting = request.pending && outcome === null && request.canResolve === false;
|
|
@@ -510,5 +511,10 @@ export function ApprovalRequest({ request, onDecision, busyDecision = null, outc
|
|
|
510
511
|
: resolutionTone === 'destructive'
|
|
511
512
|
? 'bg-kortix-red/15 text-kortix-red'
|
|
512
513
|
: 'bg-muted text-muted-foreground'
|
|
513
|
-
: 'bg-kortix-orange/15 text-kortix-orange'), children: resolved ? (positiveResolution ? (_jsx(CheckCircleIcon, { weight: "fill", className: "size-5" })) : (_jsx(XCircleIcon, { weight: "fill", className: "size-5" }))) : (_jsx(ShieldWarningIcon, { className: "size-5" })) }), _jsxs("div", { className: "min-w-0 flex-1 space-y-1", children: [_jsxs("div", { className: "flex flex-wrap items-center gap-1.5", children: [_jsx("span", { className: "text-muted-foreground text-xs", children: tI18nComplete.raw('text00d60e31a4e6') }), _jsx("code", { className: "text-foreground font-mono text-sm font-medium break-all", children: request.action }), request.risk ? (_jsx(Badge, { variant: riskTone(request.risk), size: "xs", className: "capitalize", children: request.risk })) : null] }), _jsxs("p", { className: "text-muted-foreground text-xs text-pretty", children: [request.projectName ? `${request.projectName} · ` : '', tI18nComplete.raw('text2d9e28289fac'), ' ', requestedAtFormat.format(new Date(request.requestedAt))] })
|
|
514
|
+
: 'bg-kortix-orange/15 text-kortix-orange'), children: resolved ? (positiveResolution ? (_jsx(CheckCircleIcon, { weight: "fill", className: "size-5" })) : (_jsx(XCircleIcon, { weight: "fill", className: "size-5" }))) : (_jsx(ShieldWarningIcon, { className: "size-5" })) }), _jsxs("div", { className: "min-w-0 flex-1 space-y-1", children: [_jsxs("div", { className: "flex flex-wrap items-center gap-1.5", children: [_jsx("span", { className: "text-muted-foreground text-xs", children: tI18nComplete.raw('text00d60e31a4e6') }), _jsx("code", { className: "text-foreground font-mono text-sm font-medium break-all", children: request.action }), request.risk ? (_jsx(Badge, { variant: riskTone(request.risk), size: "xs", className: "capitalize", children: request.risk })) : null] }), _jsxs("p", { className: "text-muted-foreground text-xs text-pretty", children: [request.projectName ? `${request.projectName} · ` : '', tI18nComplete.raw('text2d9e28289fac'), ' ', requestedAtFormat.format(new Date(request.requestedAt))] }), request.policySet ? (_jsx("p", { className: "text-muted-foreground text-xs text-pretty", children: request.policySet.agent
|
|
515
|
+
? tSets('approvalSetAgent', {
|
|
516
|
+
agent: request.policySet.agent,
|
|
517
|
+
set: request.policySet.name,
|
|
518
|
+
})
|
|
519
|
+
: tSets('approvalSet', { set: request.policySet.name }) })) : null] }), resolved ? (_jsx(Badge, { variant: resolutionTone, size: "sm", children: resolutionLabel })) : null] }), _jsx(ApprovalAgentContext, { context: request.approvalContext }), _jsx(ApprovalParameters, { action: request.action, argsPreview: request.argsPreview, reviewComplete: reviewComplete, resolvedPreview: request.resolvedPreview, resolvedError: request.resolvedError }), error ? (_jsx("p", { className: "text-destructive border-border border-t px-4 py-3 text-xs", children: error })) : null, actionable && !reviewable ? (_jsx(ApprovalUnreviewableNotice, { previewAuthorized: request.previewAuthorized !== false })) : null, actionable && !hideDecision ? (_jsx(ApprovalDecisionActions, { onDecision: actionable, busyDecision: busyDecision, approvable: reviewable })) : null, waiting ? (_jsx(ApprovalWaitingNotice, { resolverName: resolverName, resolvers: request.resolvers })) : null] }));
|
|
514
520
|
}
|
|
@@ -50,6 +50,15 @@ export declare function reviewArgsSummary(resolvedPreview: Record<string, unknow
|
|
|
50
50
|
* POST /approvals/:executionId.
|
|
51
51
|
*/
|
|
52
52
|
export declare function approvalReviewable(argsPreview: Record<string, unknown> | null | undefined, reviewComplete: boolean | undefined, resolvedPreview?: Record<string, unknown> | null): boolean;
|
|
53
|
+
/**
|
|
54
|
+
* The agent's policy set that decided a call, from the audit row
|
|
55
|
+
* (`result_summary.policy_set` / `.agent`, written by the gateway when the
|
|
56
|
+
* set decided). Null when the base or project rules decided.
|
|
57
|
+
*/
|
|
58
|
+
export declare function auditPolicySet(summary: Record<string, unknown> | null | undefined): {
|
|
59
|
+
name: string;
|
|
60
|
+
agent: string | null;
|
|
61
|
+
} | null;
|
|
53
62
|
/** Row → the shape every approval surface renders. */
|
|
54
63
|
export declare function approvalRequestFromAction(action: SessionAuditAction, pending?: boolean): ApprovalRequestData;
|
|
55
64
|
/**
|
|
@@ -96,10 +96,26 @@ export function approvalReviewable(argsPreview, reviewComplete, resolvedPreview)
|
|
|
96
96
|
// withheld — an argument-less call hides nothing.
|
|
97
97
|
return reviewComplete !== false;
|
|
98
98
|
}
|
|
99
|
+
/**
|
|
100
|
+
* The agent's policy set that decided a call, from the audit row
|
|
101
|
+
* (`result_summary.policy_set` / `.agent`, written by the gateway when the
|
|
102
|
+
* set decided). Null when the base or project rules decided.
|
|
103
|
+
*/
|
|
104
|
+
export function auditPolicySet(summary) {
|
|
105
|
+
// The set is named only when it decided, never for a project or base rule.
|
|
106
|
+
if (summary?.policy_source !== 'policy_set')
|
|
107
|
+
return null;
|
|
108
|
+
const name = summary?.policy_set;
|
|
109
|
+
if (typeof name !== 'string' || !name)
|
|
110
|
+
return null;
|
|
111
|
+
const agent = summary?.agent;
|
|
112
|
+
return { name, agent: typeof agent === 'string' && agent ? agent : null };
|
|
113
|
+
}
|
|
99
114
|
/** Row → the shape every approval surface renders. */
|
|
100
115
|
export function approvalRequestFromAction(action, pending = pendingByStatus(action)) {
|
|
101
116
|
const summary = action.result_summary;
|
|
102
117
|
const decision = summary?.decision;
|
|
118
|
+
const policySet = auditPolicySet(summary);
|
|
103
119
|
return {
|
|
104
120
|
action: action.action,
|
|
105
121
|
risk: action.risk,
|
|
@@ -112,6 +128,8 @@ export function approvalRequestFromAction(action, pending = pendingByStatus(acti
|
|
|
112
128
|
? summary.resolved_preview
|
|
113
129
|
: null,
|
|
114
130
|
resolvedError: typeof summary?.resolved_error === 'string' ? summary.resolved_error : null,
|
|
131
|
+
// Present only when the agent's set decided, so a base-rule row is unchanged.
|
|
132
|
+
...(policySet ? { policySet } : {}),
|
|
115
133
|
// `!summary` used to count as complete, so a pending row that recorded
|
|
116
134
|
// NOTHING offered an Approve button the server answers with 409
|
|
117
135
|
// (`APPROVAL_PREVIEW_UNAVAILABLE`) — the client and the gate disagreed. A
|
|
@@ -3,11 +3,8 @@ import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-run
|
|
|
3
3
|
import { HubLink } from '../../internal/account-hub/account-hub-location.js';
|
|
4
4
|
import { useLocale, useTranslations } from '../../i18n/index.js';
|
|
5
5
|
import { formatUsdAsCredits, parseBalanceUsd } from '../../_vendor/kortix-shared.js';
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import { useState } from 'react';
|
|
9
|
-
import { chatGptActionApplies, chatGptConnectionAction, } from '../models/chatgpt-connection-action.js';
|
|
10
|
-
import { sessionPersonalUser } from '../overrides/provider-pool-draft.js';
|
|
6
|
+
import { chatGptConnectionAction } from '../models/chatgpt-connection-action.js';
|
|
7
|
+
import { ChatGptConnectionSlot } from '../models/chatgpt-connection-button.js';
|
|
11
8
|
import { AskOwnerForCreditsButton } from '../models/ask-owner-for-credits-button.js';
|
|
12
9
|
import { Button } from '../../primitives/button.js';
|
|
13
10
|
import { ChainOfThoughtStep } from '../../primitives/chain-of-thought.js';
|
|
@@ -19,7 +16,6 @@ import { accountSettingsTarget } from '../../internal/stores/account-settings-mo
|
|
|
19
16
|
import { useCurrentAccountStore } from '../../internal/stores/current-account-store.js';
|
|
20
17
|
import { useAccountState } from '../../internal/billing/use-account-state.js';
|
|
21
18
|
import { canManageBilling, isAbortError, turnRetryLabel, } from '@kortix/sdk';
|
|
22
|
-
import { useFeatureFlag, useModelAccess, useProjectSession, useSessionProviderSecretPools, } from '@kortix/sdk/react';
|
|
23
19
|
import { CaretRightIcon, CreditCardIcon, LightningIcon, WarningCircleIcon, } from '@phosphor-icons/react';
|
|
24
20
|
const TONE_TILE = {
|
|
25
21
|
error: 'bg-kortix-red/15 text-kortix-red',
|
|
@@ -271,49 +267,6 @@ export function TurnErrorDisplay({ errorText, errorDetails, errorRaw, defaultDet
|
|
|
271
267
|
// Real errors → a checkpoint row in the activity lane, not a boxed alert.
|
|
272
268
|
return (_jsx(TurnErrorCheckpoint, { text: text, gateway: gateway, raw: errorRaw, defaultOpen: defaultDetailsOpen, action: chatGpt ? _jsx(ChatGptConnectionSlot, { action: chatGpt }) : undefined, modelOptions: modelOptions, className: className }));
|
|
273
269
|
}
|
|
274
|
-
/**
|
|
275
|
-
* The ChatGPT fix for a failed turn. It needs the session the turn belongs
|
|
276
|
-
* to, so it renders only on a session route; elsewhere the row stays
|
|
277
|
-
* informational, exactly as before.
|
|
278
|
-
*/
|
|
279
|
-
function ChatGptConnectionSlot({ action }) {
|
|
280
|
-
const ids = useSessionIds();
|
|
281
|
-
const projectId = ids.projectId ?? null;
|
|
282
|
-
const sessionId = ids.sessionId ?? null;
|
|
283
|
-
if (!projectId || !sessionId)
|
|
284
|
-
return null;
|
|
285
|
-
return _jsx(ChatGptConnectionButton, { action: action, projectId: projectId, sessionId: sessionId });
|
|
286
|
-
}
|
|
287
|
-
/**
|
|
288
|
-
* Opens the ChatGPT accounts dialog, which exists only with pooled provider
|
|
289
|
-
* secrets and the LLM gateway on. Shown only where connecting or
|
|
290
|
-
* reconnecting an account can fix this session (`chatGptActionApplies`).
|
|
291
|
-
*/
|
|
292
|
-
function ChatGptConnectionButton({ action, projectId, sessionId, }) {
|
|
293
|
-
const t = useTranslations('pooledSecrets');
|
|
294
|
-
const viewerId = useUiViewerId();
|
|
295
|
-
const pooled = useFeatureFlag(projectId, 'pooled_provider_secrets');
|
|
296
|
-
const enabled = pooled.enabled;
|
|
297
|
-
const access = useModelAccess(enabled ? projectId : null);
|
|
298
|
-
const session = useProjectSession(projectId, sessionId, { enabled });
|
|
299
|
-
const pools = useSessionProviderSecretPools(enabled ? projectId : null, sessionId);
|
|
300
|
-
const [open, setOpen] = useState(false);
|
|
301
|
-
const { ProviderAccountsModal } = useUiComponents();
|
|
302
|
-
const applies = !!ProviderAccountsModal &&
|
|
303
|
-
enabled &&
|
|
304
|
-
!(access.data?.disabledProviders ?? []).includes('codex') &&
|
|
305
|
-
chatGptActionApplies({
|
|
306
|
-
action,
|
|
307
|
-
personalUser: sessionPersonalUser(session.data),
|
|
308
|
-
viewerId: viewerId,
|
|
309
|
-
explicitSelection: pools.isSuccess
|
|
310
|
-
? pools.data.pools.some((pool) => pool.provider_id === 'codex')
|
|
311
|
-
: undefined,
|
|
312
|
-
});
|
|
313
|
-
if (!applies || !ProviderAccountsModal)
|
|
314
|
-
return null;
|
|
315
|
-
return (_jsxs("div", { className: "mt-2 pl-7", children: [_jsx(Button, { size: "sm", className: "active:scale-[0.96]", onClick: () => setOpen(true), children: t(action === 'reconnect' ? 'reconnectChatGpt' : 'connectChatGpt') }), _jsx(ProviderAccountsModal, { projectId: projectId, providerId: "codex", open: open, onOpenChange: setOpen })] }));
|
|
316
|
-
}
|
|
317
270
|
export function SessionRetryDisplay({ message, attempt, secondsLeft, details, className, }) {
|
|
318
271
|
if (!message)
|
|
319
272
|
return null;
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { type SessionStartResult } from '@kortix/sdk';
|
|
2
|
+
import { type ReactNode } from 'react';
|
|
2
3
|
/**
|
|
3
4
|
* What a session shows while its Kortix Computer comes up: nothing, unless the
|
|
4
5
|
* wake needs attention. Opening a session wakes its computer in the background,
|
|
@@ -52,13 +53,24 @@ export declare function RestartFallback({ show, pending, onRestart, className, b
|
|
|
52
53
|
*/
|
|
53
54
|
export declare function SessionStartingLoader({ projectId, sessionId,
|
|
54
55
|
/** Honest one-liner from the SDK wake escalation ladder. */
|
|
55
|
-
note, reason, failure, }: {
|
|
56
|
+
note, reason, failure, fallback, }: {
|
|
56
57
|
projectId?: string;
|
|
57
58
|
sessionId?: string;
|
|
58
59
|
note?: string | null;
|
|
59
60
|
reason?: string | null;
|
|
60
61
|
failure?: StartFailure;
|
|
61
|
-
|
|
62
|
+
/** What a routine wake shows. Default: nothing. */
|
|
63
|
+
fallback?: ReactNode;
|
|
64
|
+
}): string | number | bigint | boolean | Iterable<ReactNode> | Promise<string | number | bigint | boolean | import("react").ReactPortal | import("react").ReactElement<unknown, string | import("react").JSXElementConstructor<any>> | Iterable<ReactNode> | null | undefined> | import("react").JSX.Element | null;
|
|
65
|
+
/**
|
|
66
|
+
* The body of a tool card (Terminal, Browser, Files) opened while the session's
|
|
67
|
+
* computer boots: the wake's status when it needs attention, else a spinner and
|
|
68
|
+
* one line, centered where the live tool will appear.
|
|
69
|
+
*/
|
|
70
|
+
export declare function SessionBootStatus({ projectId, sessionId, }: {
|
|
71
|
+
projectId?: string;
|
|
72
|
+
sessionId?: string;
|
|
73
|
+
}): import("react").JSX.Element;
|
|
62
74
|
/**
|
|
63
75
|
* Compact status above a readable conversation while its runtime wakes, shown
|
|
64
76
|
* only when the wake needs attention: an escalation or retry note, or a stuck
|