@kortix/ui 0.15.2 → 0.15.3
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/dist/_vendor/kortix-shared.js +157 -2
- package/dist/_vendor/shared/channel-descriptors.d.ts +1 -1
- package/dist/_vendor/shared/index.d.ts +1 -0
- package/dist/_vendor/shared/workspace-actions.d.ts +155 -0
- package/dist/_vendor/shared/workspace-settings.d.ts +62 -0
- package/dist/access/access/access-dialog-share.js +6 -6
- package/dist/access/access/access-dialog.d.ts +44 -1
- package/dist/access/access/access-dialog.js +8 -8
- package/dist/access/access/agent-principals.d.ts +3 -3
- package/dist/access/access/agent-principals.js +5 -4
- package/dist/access/access/invite-people-dialog.d.ts +37 -0
- package/dist/access/access/invite-people-dialog.js +140 -0
- package/dist/access/access/principal-picker.js +3 -2
- package/dist/access/access/project-select.js +2 -2
- package/dist/access/access/role-select.d.ts +9 -8
- package/dist/access/access/role-select.js +22 -25
- package/dist/access/access/workspace-role-dialog.d.ts +27 -0
- package/dist/access/access/workspace-role-dialog.js +48 -0
- package/dist/access/iam/add-github-account-dialog.d.ts +1 -1
- package/dist/access/iam/add-github-account-dialog.js +1 -1
- package/dist/access/iam/api-key-expiry.d.ts +18 -0
- package/dist/access/iam/api-key-expiry.js +47 -0
- package/dist/access/iam/api-key-rows.d.ts +6 -0
- package/dist/access/iam/api-key-rows.js +3 -0
- package/dist/access/iam/workspace-key-acts-as.d.ts +41 -0
- package/dist/access/iam/workspace-key-acts-as.js +48 -0
- package/dist/access/sharing-intent.js +1 -1
- package/dist/access/sharing-picker.js +1 -1
- package/dist/animated-copy-icon.d.ts +2 -2
- package/dist/animated-copy-icon.js +7 -4
- package/dist/apps/app-shared.js +2 -2
- package/dist/artifacts/artifact-session.js +1 -1
- package/dist/customize/agents/agent-drives-section.js +2 -2
- package/dist/customize/agents/agent-page-chrome.js +1 -1
- package/dist/customize/agents/agent-page.js +4 -5
- package/dist/customize/agents/agents-page.js +2 -3
- package/dist/customize/connectors/connector-identity.d.ts +1 -1
- package/dist/customize/connectors/connector-identity.js +1 -1
- package/dist/customize/connectors/connector-moves-banner.js +2 -2
- package/dist/customize/connectors/connectors-page.d.ts +2 -2
- package/dist/customize/connectors/connectors-page.js +4 -4
- package/dist/customize/connectors/detail/app-page.js +1 -1
- package/dist/customize/connectors/detail/connector-page.d.ts +1 -1
- package/dist/customize/connectors/detail/connector-page.js +1 -1
- package/dist/customize/connectors/detail/connector-policy-sets.js +2 -2
- package/dist/customize/connectors/detail/connector-tools.js +7 -7
- package/dist/customize/connectors/detail/connector-triggers.js +2 -3
- package/dist/customize/connectors/detail/email-inboxes.js +2 -2
- package/dist/customize/models/models-page.d.ts +1 -1
- package/dist/customize/models/models-page.js +1 -1
- package/dist/customize/project-settings/project-admin-sections.d.ts +53 -17
- package/dist/customize/project-settings/project-admin-sections.js +80 -31
- package/dist/customize/project-settings/project-settings-page.d.ts +2 -2
- package/dist/customize/project-settings/project-settings-page.js +6 -4
- package/dist/customize/project-settings/project-settings-sections.d.ts +2 -3
- package/dist/customize/project-settings/project-settings-sections.js +9 -4
- package/dist/customize/providers/provider-accordion.d.ts +3 -1
- package/dist/customize/providers/provider-accordion.js +2 -2
- package/dist/customize/secrets/secrets-page.d.ts +1 -1
- package/dist/customize/secrets/secrets-page.js +1 -1
- package/dist/customize/sections/component/email-connect-form.js +2 -2
- package/dist/customize/sections/component/slack-byo-wizard.js +3 -3
- package/dist/customize/sections/connectors-view.js +17 -17
- package/dist/customize/sections/gateway-view.d.ts +7 -5
- package/dist/customize/sections/gateway-view.js +28 -17
- package/dist/customize/sections/llm-provider/chatgpt-subscription-connect.js +2 -2
- package/dist/customize/sections/llm-provider/custom-provider-form.js +2 -2
- package/dist/customize/sections/llm-provider/llm-provider-modal.d.ts +1 -1
- package/dist/customize/sections/llm-provider/llm-provider-modal.js +4 -4
- package/dist/customize/sections/llm-provider/models-tab-row.js +5 -3
- package/dist/customize/sections/llm-provider/types.d.ts +2 -0
- package/dist/customize/sections/view/agent-editor-catalog.d.ts +5 -6
- package/dist/customize/sections/view/agent-editor-catalog.js +33 -14
- package/dist/customize/sections/view/agent-editor.js +1 -1
- package/dist/customize/sections/view/channels-view.js +13 -13
- package/dist/customize/sections/view/gateway/gateway-budgets.js +12 -10
- package/dist/customize/sections/view/gateway/gateway-logs.d.ts +1 -1
- package/dist/customize/sections/view/gateway/gateway-logs.js +3 -3
- package/dist/customize/sections/view/gateway/gateway-overview.js +1 -1
- package/dist/customize/sections/view/gateway/gateway-routing.js +1 -1
- package/dist/customize/sections/view/git-view.js +3 -3
- package/dist/customize/sections/view/grant-mode-field.js +2 -2
- package/dist/customize/sections/view/review-center-connected.js +1 -1
- package/dist/customize/sections/view/review-view.d.ts +0 -15
- package/dist/customize/sections/view/review-view.js +1 -23
- package/dist/customize/sections/view/secret-delivery.js +2 -2
- package/dist/customize/sections/view/secrets-view.js +16 -16
- package/dist/customize/sections/view/subscription-usage-tab.d.ts +12 -1
- package/dist/customize/sections/view/subscription-usage-tab.js +71 -72
- package/dist/customize/settings/rail-copy-context.js +1 -1
- package/dist/customize/settings/rail.d.ts +1 -1
- package/dist/customize/settings/rail.js +11 -18
- package/dist/customize/settings/settings-tab-header.d.ts +1 -1
- package/dist/customize/settings/settings-tab-header.js +1 -1
- package/dist/customize/settings/settings-tabs.d.ts +5 -12
- package/dist/customize/settings/settings-tabs.js +31 -44
- package/dist/customize/settings/tabs/experimental-tab.js +4 -4
- package/dist/customize/settings/tabs/general-tab.d.ts +29 -11
- package/dist/customize/settings/tabs/general-tab.js +55 -25
- package/dist/customize/settings/tabs/project-edit-patch.d.ts +0 -13
- package/dist/customize/settings/tabs/project-edit-patch.js +0 -28
- package/dist/customize/settings/tabs/sandbox-tab.js +2 -2
- package/dist/customize/settings/tabs/tokens-tab.d.ts +32 -2
- package/dist/customize/settings/tabs/tokens-tab.js +157 -32
- package/dist/customize/settings/tabs/workspace-keys.d.ts +6 -0
- package/dist/customize/settings/tabs/workspace-keys.js +240 -0
- package/dist/customize/shared/capability-library.js +3 -1
- package/dist/customize/shared/catalog/catalog-space-tabs.js +2 -2
- package/dist/customize/shared/customize-tab-bar.d.ts +6 -2
- package/dist/customize/shared/customize-tab-bar.js +36 -35
- package/dist/customize/shared/standalone-settings-nav.js +2 -2
- package/dist/customize/triggers/schedule/schedule-copy.d.ts +1 -1
- package/dist/customize/triggers/schedule/trigger-composer.js +5 -6
- package/dist/customize/triggers/schedule/trigger-list.js +2 -2
- package/dist/customize/triggers/schedule/trigger-session-access-copy.d.ts +6 -6
- package/dist/customize/triggers/schedule/trigger-session-access-copy.js +3 -3
- package/dist/customize/triggers/schedule/when-event.js +4 -4
- package/dist/customize/triggers/schedule/when-webhook-address.js +2 -2
- package/dist/customize/triggers/schedule/when-webhook.js +2 -2
- package/dist/customize/triggers/schedule-view.js +4 -5
- package/dist/customize/triggers/triggers-page.d.ts +1 -1
- package/dist/customize/triggers/triggers-page.js +1 -1
- package/dist/files/drives/drive-storage.d.ts +2 -2
- package/dist/files/drives/drive-storage.js +13 -6
- package/dist/files/project/components/change-request-detail-dialog.js +6 -6
- package/dist/files/project/components/change-requests-panel.js +2 -2
- package/dist/files/project/components/diff-preview-banner.d.ts +1 -1
- package/dist/files/project/components/diff-preview-banner.js +1 -1
- package/dist/files/project/components/drive-grid-view.js +1 -1
- package/dist/files/project/components/drive-list-view.js +1 -1
- package/dist/files/project/context.d.ts +1 -1
- package/dist/files/project/context.js +1 -1
- package/dist/files/renderers/image-renderer.js +1 -1
- package/dist/files/runtime/hooks/use-binary-blob.js +12 -2
- package/dist/files/runtime/hooks/use-file-content.js +18 -2
- package/dist/files/viewer/file-content-renderer.js +2 -2
- package/dist/files/viewer/preview-fit.d.ts +1 -1
- package/dist/files/viewer/preview-fit.js +1 -1
- package/dist/i18n/en.d.ts +304 -25
- package/dist/i18n/en.js +867 -588
- package/dist/i18n/ui-catalog/account-hub-translation-keys.generated.js +9 -9
- package/dist/i18n/ui-catalog/app-registry-translation-keys.generated.js +12 -6
- package/dist/i18n/ui-catalog/product-catalog-translation-keys.generated.js +5 -5
- package/dist/i18n/ui-catalog/remaining-ui-translation-keys.generated.js +67 -60
- package/dist/icons/index.d.ts +1 -0
- package/dist/icons/index.js +1 -0
- package/dist/icons/solid-right-arrow.d.ts +8 -0
- package/dist/icons/solid-right-arrow.js +11 -0
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/dist/internal/account-hub/account-hub-entry.js +9 -8
- package/dist/internal/account-hub/account-hub-location.d.ts +20 -3
- package/dist/internal/account-hub/account-hub-location.js +16 -7
- package/dist/internal/account-hub/hub-sheet.d.ts +1 -1
- package/dist/internal/account-hub/hub-sheet.js +1 -1
- package/dist/internal/account-hub/sections.d.ts +2 -2
- package/dist/internal/account-hub/sections.js +10 -10
- package/dist/internal/account-hub/use-account-hub-access.d.ts +2 -0
- package/dist/internal/account-hub/use-account-hub-access.js +13 -5
- package/dist/internal/account-hub/workspace-settings-route.d.ts +27 -0
- package/dist/internal/account-hub/workspace-settings-route.js +51 -0
- package/dist/internal/components/nav-rail.d.ts +3 -1
- package/dist/internal/components/nav-rail.js +2 -0
- package/dist/internal/components/repository-disconnected.js +2 -2
- package/dist/internal/desktop/desktop-back-button.d.ts +1 -1
- package/dist/internal/files/file-read-retry.d.ts +13 -0
- package/dist/internal/files/file-read-retry.js +53 -1
- package/dist/internal/goals/goal-meta.d.ts +2 -1
- package/dist/internal/goals/goal-meta.js +4 -2
- package/dist/internal/hooks/account/use-accounts-list.d.ts +2 -12
- package/dist/internal/hooks/account/use-accounts-list.js +1 -14
- package/dist/internal/hooks/account/use-my-invites.d.ts +1 -1
- package/dist/internal/hooks/account/use-my-invites.js +1 -1
- package/dist/internal/hooks/use-review-session-summary.d.ts +7 -0
- package/dist/internal/hooks/use-review-session-summary.js +12 -1
- package/dist/internal/layout/project-capability-nav.d.ts +6 -17
- package/dist/internal/layout/project-capability-nav.js +7 -79
- package/dist/internal/layout/project-settings-nav.d.ts +2 -2
- package/dist/internal/layout/project-settings-nav.js +3 -3
- package/dist/internal/lib/billing/billing-gate-state.d.ts +11 -0
- package/dist/internal/lib/billing/billing-gate-state.js +18 -0
- package/dist/internal/lib/browser-noise/rules/expected-states.js +2 -3
- package/dist/internal/lib/browser-noise/rules/extensions.js +18 -0
- package/dist/internal/lib/browser-noise/rules/injected-scripts.js +55 -5
- package/dist/internal/lib/capability-tab-routes.d.ts +16 -40
- package/dist/internal/lib/capability-tab-routes.js +25 -54
- package/dist/internal/lib/desktop.d.ts +1 -1
- package/dist/internal/lib/desktop.js +1 -1
- package/dist/internal/lib/github-installations.d.ts +1 -1
- package/dist/internal/lib/github-installations.js +1 -1
- package/dist/internal/lib/model-pricing.js +1 -1
- package/dist/internal/lib/navigation/session-href.d.ts +1 -1
- package/dist/internal/lib/navigation/session-href.js +1 -1
- package/dist/internal/lib/onboarding/landing-destination.d.ts +12 -4
- package/dist/internal/lib/onboarding/landing-destination.js +17 -5
- package/dist/internal/lib/onboarding/last-project-cookie.d.ts +1 -1
- package/dist/internal/lib/onboarding/last-project-cookie.js +1 -1
- package/dist/internal/lib/project-actions.d.ts +1 -4
- package/dist/internal/lib/project-actions.js +2 -5
- package/dist/internal/lib/provider-branding.js +11 -3
- package/dist/internal/lib/use-project-can.d.ts +1 -3
- package/dist/internal/lib/use-project-can.js +0 -5
- package/dist/internal/lib/web-notifications.js +5 -5
- package/dist/internal/notifications/notification-inbox.d.ts +8 -2
- package/dist/internal/notifications/notification-inbox.js +8 -5
- package/dist/internal/notifications/use-inbox-summary.d.ts +8 -4
- package/dist/internal/notifications/use-inbox-summary.js +12 -6
- package/dist/internal/reminders/use-refetch-after-fire.d.ts +0 -2
- package/dist/internal/reminders/use-refetch-after-fire.js +1 -10
- package/dist/internal/stores/account-panel-store.d.ts +17 -1
- package/dist/internal/stores/account-panel-store.js +19 -2
- package/dist/internal/stores/project-switch-store.d.ts +2 -2
- package/dist/internal/stores/project-switch-store.js +4 -4
- package/dist/internal/stores/settings-panel-store.d.ts +6 -0
- package/dist/internal/stores/settings-panel-store.js +4 -1
- package/dist/internal/stores/workspace-settings-rail-store.d.ts +67 -0
- package/dist/internal/stores/workspace-settings-rail-store.js +11 -0
- package/dist/lib/routes.js +19 -18
- package/dist/lib/z-stack.d.ts +7 -0
- package/dist/lib/z-stack.js +13 -0
- package/dist/markdown/copy-button.d.ts +2 -2
- package/dist/markdown/copy-button.js +22 -20
- package/dist/markdown/setup-links/setup-link-button.js +1 -1
- package/dist/primitives/emoji-tint.d.ts +1 -1
- package/dist/primitives/emoji-tint.js +1 -1
- package/dist/primitives/error-state.js +8 -1
- package/dist/primitives/inline-meta.d.ts +12 -1
- package/dist/primitives/inline-meta.js +38 -5
- package/dist/primitives/page-search-bar.js +6 -6
- package/dist/primitives/section.d.ts +3 -3
- package/dist/primitives/section.js +9 -9
- package/dist/primitives/status.d.ts +5 -5
- package/dist/primitives/status.js +33 -33
- package/dist/primitives/tabs.d.ts +14 -26
- package/dist/primitives/tabs.js +103 -105
- package/dist/primitives/tag.d.ts +1 -1
- package/dist/primitives/toast.d.ts +6 -6
- package/dist/primitives/toast.js +55 -48
- package/dist/providers/session-ids.d.ts +1 -1
- package/dist/providers/ui-provider.d.ts +2 -0
- package/dist/session/agents/agent-strip.js +6 -6
- package/dist/session/agents/subagent-dialog-content.js +3 -4
- package/dist/session/agents/workflow-run-controls.d.ts +0 -2
- package/dist/session/agents/workflow-run-controls.js +1 -12
- package/dist/session/composer/ComposerCard.js +1 -1
- package/dist/session/composer/animated-placeholder.js +1 -1
- package/dist/session/composer/chat-input/chat-input-control.js +1 -8
- package/dist/session/composer/composer-toolbar.d.ts +18 -16
- package/dist/session/composer/composer-toolbar.js +10 -1
- package/dist/session/composer/composer.js +5 -13
- package/dist/session/composer/reasoning-effort-selector.d.ts +21 -0
- package/dist/session/composer/reasoning-effort-selector.js +46 -1
- package/dist/session/header/session-goal-indicator.js +2 -3
- package/dist/session/header/session-reminders-indicator.js +3 -3
- package/dist/session/header/session-site-header.js +1 -1
- package/dist/session/index.d.ts +1 -1
- package/dist/session/models/model-availability.d.ts +11 -0
- package/dist/session/models/model-availability.js +12 -0
- package/dist/session/models/model-connection-gate.d.ts +11 -26
- package/dist/session/models/model-connection-gate.js +22 -35
- package/dist/session/models/model-grouping.d.ts +30 -0
- package/dist/session/models/model-grouping.js +46 -0
- package/dist/session/models/model-picker-panel.d.ts +62 -0
- package/dist/session/models/model-picker-panel.js +181 -0
- package/dist/session/models/model-selector.d.ts +28 -4
- package/dist/session/models/model-selector.js +59 -15
- package/dist/session/models/model-tags.d.ts +4 -8
- package/dist/session/models/model-tags.js +20 -13
- package/dist/session/models/subscription-offer.d.ts +35 -0
- package/dist/session/models/subscription-offer.js +91 -0
- package/dist/session/models/use-model-connection-gate.d.ts +3 -3
- package/dist/session/models/use-model-connection-gate.js +8 -6
- package/dist/session/overrides/session-overrides-toolbar.js +8 -5
- package/dist/session/panel/open-session-quick-view.js +1 -1
- package/dist/session/panel/session-detail-panel.js +5 -1
- package/dist/session/panel/session-panel-provider.js +2 -2
- package/dist/session/panel/session-reminders-panel.js +2 -2
- package/dist/session/panel/shared/use-panel-derivations.d.ts +1 -0
- package/dist/session/panel/shared/use-panel-derivations.js +1 -1
- package/dist/session/panel/shared/use-panel-handoffs.d.ts +2 -2
- package/dist/session/panel/shared/use-panel-handoffs.js +22 -3
- package/dist/session/panel/use-session-panel-state.js +1 -1
- package/dist/session/prompts/ask-deck.d.ts +5 -3
- package/dist/session/prompts/ask-deck.js +30 -10
- package/dist/session/prompts/session-access-prompt.d.ts +61 -0
- package/dist/session/prompts/session-access-prompt.js +88 -0
- package/dist/session/prompts/session-permission-prompt.js +1 -1
- package/dist/session/scope/session-scope-control.js +2 -2
- package/dist/session/status/session-notice-banner.js +3 -3
- package/dist/session/status/session-route-prefetch.d.ts +2 -2
- package/dist/session/thread/optimistic-turn.js +1 -1
- package/dist/session/thread/session-chat.js +40 -18
- package/dist/session/thread/session-context-message-explorer.js +2 -2
- package/dist/session/thread/session-history.js +3 -3
- package/dist/session/tool/render-static.d.ts +11 -0
- package/dist/session/tool/render-static.js +16 -0
- package/dist/session/tool/shared/session-helpers.js +2 -2
- package/dist/session/tool/tool-part-renderer.d.ts +6 -1
- package/dist/session/tool/tool-part-renderer.js +9 -5
- package/dist/session/tool/tools/kortix-action-tool.js +4 -25
- package/dist/session/tool/tools/task-tool.js +9 -2
- package/dist/session/tool/tools/workflow-run-card.js +5 -1
- package/dist/session/tool/tools/workflow-tool.js +3 -14
- package/dist/session/turn/user-message.js +1 -1
- package/dist/styles.css +1 -1
- package/dist/test-utils/intl.d.ts +10096 -0
- package/dist/test-utils/intl.js +27 -0
- package/dist/test-utils/strip-tags.d.ts +24 -0
- package/dist/test-utils/strip-tags.js +32 -0
- package/dist/workspace/admin/project-admin-dashboard.d.ts +51 -33
- package/dist/workspace/admin/project-admin-dashboard.js +269 -81
- package/dist/workspace/admin/settings-search-landing.d.ts +11 -0
- package/dist/workspace/admin/settings-search-landing.js +103 -0
- package/dist/workspace/admin/settings-search.d.ts +69 -0
- package/dist/workspace/admin/settings-search.js +393 -0
- package/dist/workspace/home/existing-repo-setup-prompt.d.ts +22 -0
- package/dist/workspace/home/existing-repo-setup-prompt.js +58 -0
- package/dist/workspace/home/no-agent-home.d.ts +25 -0
- package/dist/workspace/home/no-agent-home.js +44 -0
- package/dist/workspace/home/welcome-body.js +2 -1
- package/dist/workspace/inbox/workspace-inbox.d.ts +21 -0
- package/dist/workspace/inbox/workspace-inbox.js +52 -0
- package/dist/workspace/layout/project-files-view.js +1 -1
- package/dist/workspace/layout/project-home.js +60 -9
- package/dist/workspace/memory/memory-body.js +2 -2
- package/dist/workspace/new/account-param.d.ts +1 -1
- package/dist/workspace/new/account-param.js +4 -4
- package/dist/workspace/new/advanced-fields.js +3 -3
- package/dist/workspace/new/clone-param.d.ts +1 -1
- package/dist/workspace/new/clone-param.js +1 -1
- package/dist/workspace/new/create-workspace-key.js +1 -1
- package/dist/workspace/new/github-source.d.ts +6 -6
- package/dist/workspace/new/github-source.js +6 -6
- package/dist/workspace/new/new-workspace-form.d.ts +11 -141
- package/dist/workspace/new/new-workspace-form.js +9 -195
- package/dist/workspace/new/provision-new-workspace.d.ts +14 -0
- package/dist/workspace/new/provision-new-workspace.js +14 -0
- package/dist/workspace/new/repository-options.d.ts +2 -2
- package/dist/workspace/new/repository-options.js +2 -2
- package/dist/workspace/new/source-param.d.ts +2 -2
- package/dist/workspace/new/source-param.js +2 -2
- package/dist/workspace/new/use-create-workspace.d.ts +43 -102
- package/dist/workspace/new/use-create-workspace.js +77 -136
- package/dist/workspace/new/use-project-quota.d.ts +1 -1
- package/dist/workspace/new/use-project-quota.js +1 -1
- package/dist/workspace/new/workspace-handoff.d.ts +2 -2
- package/dist/workspace/new/workspace-handoff.js +2 -2
- package/dist/workspace/new/workspace-name.d.ts +1 -1
- package/dist/workspace/new/workspace-name.js +1 -1
- package/dist/workspace/project-selector/project-selector-model.d.ts +115 -57
- package/dist/workspace/project-selector/project-selector-model.js +157 -111
- package/dist/workspace/projects/modal/project-icon-field.d.ts +5 -5
- package/dist/workspace/projects/modal/project-icon-field.js +4 -4
- package/dist/workspace/projects/policies-panel.js +3 -3
- package/dist/workspace/sessions/board-grouping.js +1 -1
- package/dist/workspace/sessions/project-sessions-view.js +2 -2
- package/dist/workspace/sessions/session-detail.js +2 -2
- package/dist/workspace/sessions/sessions-board.d.ts +1 -1
- package/dist/workspace/sessions/sessions-board.js +1 -1
- package/dist/workspace/settings/split-notice-banner.d.ts +13 -0
- package/dist/workspace/settings/split-notice-banner.js +59 -0
- package/dist/workspace/settings/use-leave-workspace.d.ts +16 -0
- package/dist/workspace/settings/use-leave-workspace.js +60 -0
- package/dist/workspace/sidebar/footer/project-files-nav.js +2 -2
- package/dist/workspace/sidebar/footer/sandbox-health.js +1 -1
- package/dist/workspace/sidebar/invitations-menu-group.d.ts +2 -2
- package/dist/workspace/sidebar/invitations-menu-group.js +4 -4
- package/dist/workspace/sidebar/modal/session-embed-section.js +1 -1
- package/dist/workspace/sidebar/modal/share-session-access.js +1 -1
- package/dist/workspace/sidebar/modal/share-session-modal.js +3 -3
- package/dist/workspace/sidebar/project-nav-items.js +14 -25
- package/dist/workspace/sidebar/project-sidebar.js +17 -2
- package/dist/workspace/sidebar/project-spaces-nav.js +6 -15
- package/dist/workspace/sidebar/sidebar-drill.d.ts +37 -0
- package/dist/workspace/sidebar/sidebar-drill.js +110 -0
- package/dist/workspace/sidebar/use-workspace-directory.d.ts +24 -0
- package/dist/workspace/sidebar/use-workspace-directory.js +24 -0
- package/dist/workspace/sidebar/use-workspace-list.d.ts +37 -0
- package/dist/workspace/sidebar/use-workspace-list.js +71 -0
- package/dist/workspace/sidebar/workspace-grouping.d.ts +6 -67
- package/dist/workspace/sidebar/workspace-grouping.js +4 -107
- package/dist/workspace/sidebar/workspace-menu-model.d.ts +30 -12
- package/dist/workspace/sidebar/workspace-menu-model.js +13 -107
- package/dist/workspace/sidebar/workspace-menu-section.d.ts +7 -1
- package/dist/workspace/sidebar/workspace-menu-section.js +65 -100
- package/dist/workspace/sidebar/workspace-settings-sidebar-nav.d.ts +34 -0
- package/dist/workspace/sidebar/workspace-settings-sidebar-nav.js +282 -0
- package/dist/workspace/space/space-filter-tabs.js +2 -2
- package/dist/workspace/space/space-page.d.ts +1 -1
- package/dist/workspace/space/space-page.js +1 -1
- package/package.json +51 -47
- package/skills/kortix-ui/SKILL.md +66 -66
- package/skills/kortix-ui/references/custom-dashboard.md +15 -15
- package/skills/kortix-ui/references/modules.md +15 -15
- package/dist/customize/agents/agent-pin-button.d.ts +0 -10
- package/dist/customize/agents/agent-pin-button.js +0 -20
- package/dist/customize/settings/tabs/transfer-workspace-dialog.d.ts +0 -4
- package/dist/customize/settings/tabs/transfer-workspace-dialog.js +0 -82
- package/dist/internal/account-hub/account-settings-shell.d.ts +0 -7
- package/dist/internal/account-hub/account-settings-shell.js +0 -87
- package/dist/internal/account-hub/account-settings-sidebar.d.ts +0 -2
- package/dist/internal/account-hub/account-settings-sidebar.js +0 -169
- package/dist/internal/lib/use-project-feature-flags.d.ts +0 -28
- package/dist/internal/lib/use-project-feature-flags.js +0 -76
- package/dist/internal/stores/pinned-agents-store.d.ts +0 -26
- package/dist/internal/stores/pinned-agents-store.js +0 -20
- package/dist/primitives/info-banner.d.ts +0 -14
- package/dist/primitives/info-banner.js +0 -72
- package/dist/workspace/new/account-picker.d.ts +0 -71
- package/dist/workspace/new/account-picker.js +0 -92
- package/dist/workspace/new/use-creatable-accounts.d.ts +0 -8
- package/dist/workspace/new/use-creatable-accounts.js +0 -33
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type { ReactNode } from
|
|
2
|
-
export declare function AnimatedCopyIcon({ copied, children }: {
|
|
1
|
+
import type { ReactNode } from "react";
|
|
2
|
+
export declare function AnimatedCopyIcon({ copied, children, }: {
|
|
3
3
|
copied: boolean;
|
|
4
4
|
children: ReactNode;
|
|
5
5
|
}): import("react").JSX.Element;
|
|
@@ -1,6 +1,9 @@
|
|
|
1
|
-
|
|
1
|
+
"use client";
|
|
2
2
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
3
|
-
import { AnimatePresence, m } from
|
|
4
|
-
export function AnimatedCopyIcon({ copied, children }) {
|
|
5
|
-
|
|
3
|
+
import { AnimatePresence, m, useReducedMotion } from "motion/react";
|
|
4
|
+
export function AnimatedCopyIcon({ copied, children, }) {
|
|
5
|
+
const reducedMotion = useReducedMotion();
|
|
6
|
+
if (reducedMotion)
|
|
7
|
+
return (_jsx("span", { className: "absolute inset-0 inline-flex items-center justify-center", children: children }));
|
|
8
|
+
return (_jsx(AnimatePresence, { initial: false, mode: "popLayout", children: _jsx(m.span, { initial: { scale: 0.25, opacity: 0, filter: "blur(4px)" }, animate: { scale: 1, opacity: 1, filter: "blur(0px)" }, exit: { scale: 0.25, opacity: 0, filter: "blur(4px)" }, transition: { type: "spring", duration: 0.3, bounce: 0 }, className: "absolute inset-0 inline-flex items-center justify-center", children: children }, copied ? "check" : "copy") }));
|
|
6
9
|
}
|
package/dist/apps/app-shared.js
CHANGED
|
@@ -178,8 +178,8 @@ export const ACCESS_COPY = {
|
|
|
178
178
|
// private App does not become unmanageable the moment its creator leaves the
|
|
179
179
|
// account. A false promise about access, in the one dialog where people
|
|
180
180
|
// reason about access, is worse than a longer label.
|
|
181
|
-
private: { label: 'Just you', desc: 'You, and anyone who can manage this
|
|
182
|
-
project: { label: 'Whole team', desc: 'Every member of this
|
|
181
|
+
private: { label: 'Just you', desc: 'You, and anyone who can manage this workspace' },
|
|
182
|
+
project: { label: 'Whole team', desc: 'Every member of this workspace' },
|
|
183
183
|
restricted: { label: 'Select members', desc: 'Chosen members and groups' },
|
|
184
184
|
// These two describe PUBLIC traffic only. Both are still team-visible: a
|
|
185
185
|
// password protects the App's hostname from the internet, it never hides the
|
|
@@ -59,7 +59,7 @@ function useShownArtifact(url) {
|
|
|
59
59
|
type: detail.type,
|
|
60
60
|
src: detail.version.view_url,
|
|
61
61
|
frameKey: artifactFrameKey(detail),
|
|
62
|
-
href: `/
|
|
62
|
+
href: `/workspaces/${detail.project_id}/artifacts/${detail.artifact_id}`,
|
|
63
63
|
},
|
|
64
64
|
failed: false,
|
|
65
65
|
};
|
|
@@ -57,10 +57,10 @@ export function AgentDrivesSection({ projectId, agentName, repositoryAccess = tr
|
|
|
57
57
|
body = (_jsx(EditorList, { children: [0, 1].map((i) => (_jsx("li", { className: "flex min-h-12 items-center gap-3 px-4 py-2", children: _jsx(Skeleton, { className: "h-4 w-48 rounded-sm" }) }, i))) }));
|
|
58
58
|
}
|
|
59
59
|
else if (drive.isError || plan.isError || !driveId || !plan.data) {
|
|
60
|
-
body = (_jsx(ErrorState, { size: "sm", title: t('loadError'), action: _jsx(Button, { variant: "outline", size: "sm", onClick: () => void plan.refetch(), children: t('retry') }) }));
|
|
60
|
+
body = (_jsx(ErrorState, { size: "sm", title: agentName ? t('loadError') : t('projectLoadError'), action: _jsx(Button, { variant: "outline", size: "sm", onClick: () => void plan.refetch(), children: t('retry') }) }));
|
|
61
61
|
}
|
|
62
62
|
else if (plan.data.mounts.length === 0 && !showRepository) {
|
|
63
|
-
body = (_jsx(EmptyState, { media: _jsx(EmptyArt, { icon: HardDrivesIcon }), title: t('emptyTitle'), description: t('emptyDescription') }));
|
|
63
|
+
body = (_jsx(EmptyState, { media: _jsx(EmptyArt, { icon: HardDrivesIcon }), title: t('emptyTitle'), description: agentName ? t('emptyDescription') : t('projectEmptyDescription') }));
|
|
64
64
|
}
|
|
65
65
|
else {
|
|
66
66
|
body = (_jsxs("div", { className: "space-y-3", children: [_jsxs(EditorList, { children: [showRepository ? (_jsxs("li", { className: "flex min-h-12 items-center gap-3 px-4 py-2", children: [_jsxs("span", { className: "min-w-0 flex-1", children: [_jsx("code", { className: "text-foreground block truncate font-mono text-sm", children: "/workspace" }), _jsx("span", { className: "text-muted-foreground block truncate text-xs", children: t('repository') })] }), _jsx("span", { className: "text-muted-foreground shrink-0 text-xs", children: t('readWrite') })] })) : null, plan.data.mounts.map((mount) => (_jsx(MountRow, { driveId: driveId, agentName: agentName, mount: mount }, mount.path)))] }), plan.data.skipped.length > 0 ? (_jsx("p", { className: "text-muted-foreground text-xs text-pretty", children: t('skipped', { slots: plan.data.slots, list: plan.data.skipped.join(', ') }) })) : null] }));
|
|
@@ -23,7 +23,7 @@ import { useCallback } from 'react';
|
|
|
23
23
|
import { useTranslations as useI18nTranslations } from '../../i18n/index.js';
|
|
24
24
|
import { AgentMark, agentDisplayName } from '../../internal/components/agent-mark.js';
|
|
25
25
|
import { SidebarToggle } from '../../internal/layout/sidebar-toggle.js';
|
|
26
|
-
import { SETTINGS_SIDEBAR_WIDTH_PX } from '../../internal/
|
|
26
|
+
import { SETTINGS_SIDEBAR_WIDTH_PX } from '../../internal/components/nav-rail.js';
|
|
27
27
|
import { CaretRightIcon } from '@phosphor-icons/react';
|
|
28
28
|
import { useInCustomizeFrame } from '../shared/customize-tab-bar.js';
|
|
29
29
|
import { cn } from '../../internal/lib/utils.js';
|
|
@@ -3,7 +3,7 @@ import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-run
|
|
|
3
3
|
import { MY_KORTIX_AGENT_NAME } from '../../_vendor/kortix-shared.js';
|
|
4
4
|
import { adminPath } from '../../lib/routes.js';
|
|
5
5
|
/**
|
|
6
|
-
* /
|
|
6
|
+
* /workspaces/[id]/admin/agents/[name]: one agent, as a page with a rail, in the Workspace settings pane.
|
|
7
7
|
*
|
|
8
8
|
* Customize is agent-first. My Kortix is the one agent a person talks to; every
|
|
9
9
|
* other agent is a work product with only the access its work needs. So the
|
|
@@ -64,7 +64,7 @@ import { DropdownMenu, DropdownMenuContent, DropdownMenuItem, DropdownMenuSepara
|
|
|
64
64
|
import { EmptyState } from '../../primitives/empty-state.js';
|
|
65
65
|
import { ErrorState } from '../../primitives/error-state.js';
|
|
66
66
|
import Hint from '../../primitives/hint.js';
|
|
67
|
-
import {
|
|
67
|
+
import { Alert as BannerAlert, AlertTitle as BannerAlertTitle, AlertDescription as BannerAlertDescription, AlertMedia as BannerAlertMedia } from '../../primitives/alert.js';
|
|
68
68
|
import { errorToast, successToast } from '../../primitives/toast.js';
|
|
69
69
|
import { UiLink as Link, useUiPathname, useUiRouter, useUiSearchParams } from '../../providers/ui-provider.js';
|
|
70
70
|
import { configEntitySourcePath } from '../sections/component/config-entity-source-path.js';
|
|
@@ -88,7 +88,6 @@ import { AgentOverview } from './agent-overview.js';
|
|
|
88
88
|
import { AgentBreadcrumbHeader, AgentPageSkeleton, AgentRail, AgentStatePage, AgentTabBody, LeaveDialog, SaveBar, } from './agent-page-chrome.js';
|
|
89
89
|
import { AgentModelView } from './agent-model-view.js';
|
|
90
90
|
import { AgentApprovalRules } from './agent-approval-rules.js';
|
|
91
|
-
import { AgentPinButton } from './agent-pin-button.js';
|
|
92
91
|
import { AgentShareControl } from './agent-share-control.js';
|
|
93
92
|
import { ACCESS_VIEWS, AGENT_TABS, agentLocationHref, changedItems, closestAgentName, resolveAgentLocation, railKeyOf, sectionLocationHref, } from './agent-tabs.js';
|
|
94
93
|
import { useSpacesEnabled } from '../../internal/lib/space-scope.js';
|
|
@@ -353,7 +352,7 @@ function AgentActions({ projectId, agent, config, canWrite, share, }) {
|
|
|
353
352
|
: null;
|
|
354
353
|
const startLabel = tI18nComplete.raw('textb1c52ee3677d');
|
|
355
354
|
const start = (_jsxs(_Fragment, { children: [_jsxs(Button, { size: "sm", disabled: startBlocked !== null, onClick: () => startSession({ create: { agent_name: agent.name } }), className: "hidden sm:inline-flex", children: [_jsx(PlayIcon, { weight: "fill", className: "size-3.5 shrink-0" }), startLabel] }), _jsx(Button, { size: "icon-base", "aria-label": startLabel, disabled: startBlocked !== null, onClick: () => startSession({ create: { agent_name: agent.name } }), className: "sm:hidden", children: _jsx(PlayIcon, { weight: "fill", className: "size-3.5" }) })] }));
|
|
356
|
-
return (_jsxs(_Fragment, { children: [_jsx(
|
|
355
|
+
return (_jsxs(_Fragment, { children: [_jsx(AgentShareControl, { projectId: projectId, agentName: agent.name, open: share.open, onOpenChange: share.setOpen }), startBlocked ? null : _jsx(AgentCallButton, { projectId: projectId, agentName: agent.name }), startBlocked ? (_jsx(Hint, { label: startBlocked, children: _jsx("span", { className: "inline-flex", children: start }) })) : (start), canWrite ? (_jsxs(DropdownMenu, { children: [_jsx(DropdownMenuTrigger, { asChild: true, children: _jsx(Button, { variant: "ghost", size: "icon-base", "aria-label": tI18nComplete.raw('textf8d46c2570e7'), children: _jsx(DotsThreeIcon, { className: "size-4" }) }) }), _jsxs(DropdownMenuContent, { align: "end", children: [_jsxs(DropdownMenuItem, { disabled: isDefault || agent.enabled === false || makeDefault.isPending, onSelect: () => makeDefault.mutate(agent.name), children: [_jsx(StarIcon, { className: "size-4" }), isDefault ? tI18nComplete.raw('texte8cb80e5c5cb') : tI18nComplete.raw('texte8f43f910a4e')] }), _jsxs(DropdownMenuItem, { disabled: configure.pending, onSelect: () => setConfirm('edit'), children: [_jsx(AgentMark, { slug: MY_KORTIX_AGENT_NAME }), t('askToEditAgent')] }), _jsx(DropdownMenuSeparator, {}), _jsxs(DropdownMenuItem, { variant: "destructive", disabled: configure.pending, onSelect: () => setConfirm('delete'), children: [_jsx(TrashIcon, { className: "size-4" }), t('deleteAgent', { name: agentDisplayName(agent.name) })] })] })] })) : null, _jsx(ConfirmDialog, { open: confirm !== null, onOpenChange: (open) => (open ? undefined : setConfirm(null)), title: confirm === 'delete' ? t('deleteTitle', { name: agentDisplayName(agent.name) }) : tI18nComplete.raw('text24ba36a8ec86'), description: confirm === 'delete'
|
|
357
356
|
? t('deleteBody')
|
|
358
357
|
: tI18nComplete('text13324ae62b23', { value0: agent.name }), confirmLabel: tI18nComplete.raw('text0bce1a892dec'), cancelLabel: tI18nComplete.raw('text19766ed6ccb2'), confirmVariant: confirm === 'delete' ? 'destructive' : 'default', onConfirm: () => {
|
|
359
358
|
const kind = confirm;
|
|
@@ -527,7 +526,7 @@ function ReadOnlyAgentPage({ projectId, agent, config, block, canWrite, }) {
|
|
|
527
526
|
const name = agentDisplayName(agent.name);
|
|
528
527
|
// A reader has a page for Kortix permissions and Model only. Every other
|
|
529
528
|
// Access row shows its grant by name on the Overview and links nowhere.
|
|
530
|
-
const banner = (
|
|
529
|
+
const banner = (_jsxs(BannerAlert, { variant: "default", children: [_jsx(BannerAlertMedia, { children: _jsx(LockSimpleIcon, {}) }), _jsx(BannerAlertTitle, { children: t('readOnlyTitle') }), _jsx(BannerAlertDescription, { children: t.rich('readOnlyBody', { code: (chunks) => _jsx("span", { className: "font-mono", children: chunks }) }) })] }));
|
|
531
530
|
const body = (() => {
|
|
532
531
|
switch (location.tab) {
|
|
533
532
|
case 'basics':
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use client';
|
|
2
2
|
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
3
3
|
/**
|
|
4
|
-
* /
|
|
4
|
+
* /workspaces/[id]/admin/agents (Workspace settings › Agents): the Agents index, where the sidebar's
|
|
5
5
|
* Customize row lands.
|
|
6
6
|
*
|
|
7
7
|
* Customize is agent-first. My Kortix is not listed: the project home starts
|
|
@@ -54,7 +54,6 @@ import { AgentCoverCard } from './agent-cover-card.js';
|
|
|
54
54
|
import { agentInMode, filterAgents } from './agent-filter.js';
|
|
55
55
|
import { CapabilityPageShell } from '../shared/capability-page-shell.js';
|
|
56
56
|
import { CreateAgentModal } from './create-agent-modal.js';
|
|
57
|
-
import { AgentPinButton } from './agent-pin-button.js';
|
|
58
57
|
export function AgentsPage({ projectId }) {
|
|
59
58
|
const tI18nComplete = useI18nTranslations('hardcodedUi.i18nComplete');
|
|
60
59
|
const t = useI18nTranslations('agentEditor.tabs');
|
|
@@ -137,7 +136,7 @@ export function AgentsPage({ projectId }) {
|
|
|
137
136
|
// sit in their own section. `all` is usable both ways and stays with the first.
|
|
138
137
|
const primaryAgents = shown.filter((agent) => agentInMode(agent, 'primary'));
|
|
139
138
|
const subagents = shown.filter((agent) => !agentInMode(agent, 'primary'));
|
|
140
|
-
const card = (agent, cover) => (_jsx(AgentCoverCard, { slug: agent.name, href: agentHref(projectId, agent.name), onIntent: () => prefetchAgentConfig(queryClient, projectId, agent.name), title: agentDisplayName(agent.name), description: agent.description, badges: _jsx(AgentCardBadges, { agent: agent }), coverLabel: cover,
|
|
139
|
+
const card = (agent, cover) => (_jsx(AgentCoverCard, { slug: agent.name, href: agentHref(projectId, agent.name), onIntent: () => prefetchAgentConfig(queryClient, projectId, agent.name), title: agentDisplayName(agent.name), description: agent.description, badges: _jsx(AgentCardBadges, { agent: agent }), coverLabel: cover, meta: _jsx(AgentCardFacts, { agent: agent, triggerCount: triggerCounts.get(agent.name) ?? 0, grantCount: grantCounts.get(agent.name) ?? 0 }) }, agent.name));
|
|
141
140
|
const newButton = canWrite ? (_jsxs(Button, { size: "sm", onClick: () => setCreating(true), className: "gap-1.5", children: [_jsx(PlusIcon, { className: "size-4" }), t('newAgent')] })) : null;
|
|
142
141
|
const body = (() => {
|
|
143
142
|
if (detailQuery.isLoading)
|
|
@@ -6,7 +6,7 @@ import type { ConnectorLogoSource } from '../../internal/connector-logo/connecto
|
|
|
6
6
|
* connector surface.
|
|
7
7
|
*
|
|
8
8
|
* These two render once per card in the connectors grid, so they sit on the
|
|
9
|
-
* hottest path of `/
|
|
9
|
+
* hottest path of `/workspaces/[id]/connectors`. They used to live in
|
|
10
10
|
* `customize/sections/connectors-view.tsx`, which is ~5,100 lines across 50
|
|
11
11
|
* components and pulls `HighlightedCode` and `PoliciesPanel`. Importing
|
|
12
12
|
* two small components from there put that entire graph in this route's client
|
|
@@ -12,7 +12,7 @@ import { cn } from '../../internal/lib/utils.js';
|
|
|
12
12
|
* connector surface.
|
|
13
13
|
*
|
|
14
14
|
* These two render once per card in the connectors grid, so they sit on the
|
|
15
|
-
* hottest path of `/
|
|
15
|
+
* hottest path of `/workspaces/[id]/connectors`. They used to live in
|
|
16
16
|
* `customize/sections/connectors-view.tsx`, which is ~5,100 lines across 50
|
|
17
17
|
* components and pulls `HighlightedCode` and `PoliciesPanel`. Importing
|
|
18
18
|
* two small components from there put that entire graph in this route's client
|
|
@@ -4,7 +4,7 @@ import { listConnectorMoves } from '@kortix/sdk';
|
|
|
4
4
|
import { useQuery } from '@tanstack/react-query';
|
|
5
5
|
import { UiLink as Link } from '../../providers/ui-provider.js';
|
|
6
6
|
import { Fragment } from 'react';
|
|
7
|
-
import {
|
|
7
|
+
import { Alert as BannerAlert, AlertTitle as BannerAlertTitle, AlertDescription as BannerAlertDescription } from '../../primitives/alert.js';
|
|
8
8
|
import { useTranslations } from '../../i18n/index.js';
|
|
9
9
|
import { connectorHref } from './connector-routes.js';
|
|
10
10
|
import { connectorMovesQueryKey } from './detail/connector-move-row.js';
|
|
@@ -19,5 +19,5 @@ export function ConnectorMovesBanner({ projectId }) {
|
|
|
19
19
|
const movable = (moves.data ?? []).filter((move) => move.to && move.provider === 'pipedream');
|
|
20
20
|
if (movable.length === 0)
|
|
21
21
|
return null;
|
|
22
|
-
return (
|
|
22
|
+
return (_jsxs(BannerAlert, { variant: "default", children: [_jsx(BannerAlertTitle, { children: t('movesBannerTitle', { count: movable.length }) }), _jsx(BannerAlertDescription, { children: _jsxs("p", { className: "text-muted-foreground text-xs text-pretty", children: [t('movesBannerBody'), ' ', movable.map((move, index) => (_jsxs(Fragment, { children: [index > 0 ? ', ' : null, _jsx(Link, { href: connectorHref(projectId, move.slug), className: "text-foreground underline-offset-2 hover:underline", children: move.name })] }, move.slug)))] }) })] }));
|
|
23
23
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { type ReactNode } from 'react';
|
|
2
2
|
import { type AgentGrant, type ResourceScope } from '../shared/agent-resource-scope.js';
|
|
3
3
|
/**
|
|
4
|
-
* /
|
|
4
|
+
* /workspaces/[id]/connectors — the standalone Connectors catalogue.
|
|
5
5
|
*
|
|
6
6
|
* Reads the project's own connectors off `qk.project.connectors(projectId)`,
|
|
7
7
|
* the same key `ConnectorsMasterDetail` uses, so the two surfaces cannot
|
|
@@ -22,7 +22,7 @@ import { type AgentGrant, type ResourceScope } from '../shared/agent-resource-sc
|
|
|
22
22
|
* custom-connector Add button off the header while it is up.
|
|
23
23
|
*
|
|
24
24
|
* `?scope=` is the tab, so every scope is linkable — which is what lets the
|
|
25
|
-
* retired `/
|
|
25
|
+
* retired `/workspaces/<id>/channels` route redirect to a real destination
|
|
26
26
|
* instead of a page that lands on All and hides what was asked for.
|
|
27
27
|
*
|
|
28
28
|
* **What Add opens.** Only the custom-connector form (OpenAPI / Postman /
|
|
@@ -142,7 +142,7 @@ function parseScope(value) {
|
|
|
142
142
|
return SCOPES.find((scope) => scope === value) ?? null;
|
|
143
143
|
}
|
|
144
144
|
/**
|
|
145
|
-
* /
|
|
145
|
+
* /workspaces/[id]/connectors — the standalone Connectors catalogue.
|
|
146
146
|
*
|
|
147
147
|
* Reads the project's own connectors off `qk.project.connectors(projectId)`,
|
|
148
148
|
* the same key `ConnectorsMasterDetail` uses, so the two surfaces cannot
|
|
@@ -163,7 +163,7 @@ function parseScope(value) {
|
|
|
163
163
|
* custom-connector Add button off the header while it is up.
|
|
164
164
|
*
|
|
165
165
|
* `?scope=` is the tab, so every scope is linkable — which is what lets the
|
|
166
|
-
* retired `/
|
|
166
|
+
* retired `/workspaces/<id>/channels` route redirect to a real destination
|
|
167
167
|
* instead of a page that lands on All and hides what was asked for.
|
|
168
168
|
*
|
|
169
169
|
* **What Add opens.** Only the custom-connector form (OpenAPI / Postman /
|
|
@@ -400,7 +400,7 @@ export function ConnectorsPage({ projectId, surface = { kind: 'global' }, grant,
|
|
|
400
400
|
connectors, one switch each, then every app), then the agent's
|
|
401
401
|
rule sets. One library, two modes (Marko, 2026-10-28). */
|
|
402
402
|
_jsxs("div", { className: "space-y-6", children: [settled && !isError ? catalogSection : listBody(ownMatches), agentPanel, railLayout ? (_jsxs("div", { className: "bg-popover flex items-center gap-3 rounded-lg px-4 py-3", children: [_jsx(ShieldIcon, { className: "text-muted-foreground size-4 shrink-0" }), _jsx("p", { className: "text-muted-foreground min-w-0 flex-1 text-xs text-pretty", children: tTabs.rich('policySetsNote', { file: () => _jsx("code", { className: "text-foreground font-mono", children: "kortix.yaml" }) }) }), addMenu] })) : null] })) : channelsActive ? (
|
|
403
|
-
/* The whole of what used to be `/
|
|
403
|
+
/* The whole of what used to be `/workspaces/<id>/channels`, minus the
|
|
404
404
|
shell it used to bring — this page's `CapabilityPageShell` is the
|
|
405
405
|
one column, the one heading and the one scroll container now. */
|
|
406
406
|
_jsx(ChannelsSection, { projectId: projectId })) : catalogActive ? (catalogSection) : (_jsxs(_Fragment, { children: [_jsx(ConnectorMovesBanner, { projectId: projectId }), listBody(filtered)] })), _jsx(AddMcpServerDialog, { projectId: projectId, app: mcpApp, open: panel === 'mcp', onOpenChange: (open) => setPanel(open ? 'mcp' : null), takenSlugs: connectors.map((connector) => connector.slug), onAdded: invalidate }, mcpApp?.url ?? 'paste'), installRequest ? (_jsx(InstallDialog, { appName: installRequest.target.appName, way: installRequest.way, open: true, pending: false, onOpenChange: (open) => !open && setInstallRequest(null), onConfirm: confirmInstall }, installRequest.target.appName)) : null, _jsx(Modal, { open: panel === 'custom', onOpenChange: (open) => !open && setPanel(null), children: _jsxs(ModalContent, { className: "lg:max-w-3xl", children: [_jsxs(ModalHeader, { children: [_jsx(ModalTitle, { children: tI18nComplete.raw('text90ccaee30bdc') }), _jsx(ModalDescription, { children: tI18nComplete.raw('textd2f3be0047c4') })] }), _jsx(ModalBody, { className: "max-h-[75vh] overflow-y-auto", children: _jsx(CustomConnectorForm, { projectId: projectId, onAdded: (slug, { addAccount }) => {
|
|
@@ -443,7 +443,7 @@ function useConnectorNavigation(projectId) {
|
|
|
443
443
|
}, [pathname, router, search]);
|
|
444
444
|
// Which scope the strip is on, held in the URL rather than in state.
|
|
445
445
|
//
|
|
446
|
-
// It has to be addressable: `/
|
|
446
|
+
// It has to be addressable: `/workspaces/<id>/channels` was a real route until
|
|
447
447
|
// Channels folded into this page, and every bookmark and every legacy nav id
|
|
448
448
|
// pointing at it now redirects to `?scope=channels`. A tab that only local
|
|
449
449
|
// state can reach is a tab nothing can link to.
|
|
@@ -47,7 +47,7 @@ const surfaceLabel = (kind) => wayKindLabel(kind);
|
|
|
47
47
|
/** Tools shown before "Show all". */
|
|
48
48
|
const TOOLS_PREVIEW = 40;
|
|
49
49
|
/**
|
|
50
|
-
* `/
|
|
50
|
+
* `/workspaces/<id>/admin/connectors/<app>` — one catalogue app: what it is,
|
|
51
51
|
* the one Install button, the connectors this project already has for it, and
|
|
52
52
|
* the other ways to connect it.
|
|
53
53
|
*
|
|
@@ -3,7 +3,7 @@ import { type ReactNode } from 'react';
|
|
|
3
3
|
import { type AppRef } from '../connector-routes.js';
|
|
4
4
|
/** The column `CapabilityPageShell` gives the list page beside this one. */
|
|
5
5
|
/**
|
|
6
|
-
* `/
|
|
6
|
+
* `/workspaces/<id>/admin/connectors/<app>/<connector>` — one connector, as
|
|
7
7
|
* a page: its accounts, its tools, its settings.
|
|
8
8
|
*
|
|
9
9
|
* `appSegment` is navigation context only. It decides where Back goes: the
|
|
@@ -43,7 +43,7 @@ import { ConnectorStatusBadge } from './status-badge.js';
|
|
|
43
43
|
import { useConnectorDetail } from './use-connector-detail.js';
|
|
44
44
|
/** The column `CapabilityPageShell` gives the list page beside this one. */
|
|
45
45
|
/**
|
|
46
|
-
* `/
|
|
46
|
+
* `/workspaces/<id>/admin/connectors/<app>/<connector>` — one connector, as
|
|
47
47
|
* a page: its accounts, its tools, its settings.
|
|
48
48
|
*
|
|
49
49
|
* `appSegment` is navigation context only. It decides where Back goes: the
|
|
@@ -17,7 +17,7 @@ import { Input } from '../../../primitives/input.js';
|
|
|
17
17
|
import Loading from '../../../primitives/loading.js';
|
|
18
18
|
import { Modal, ModalBody, ModalContent, ModalDescription, ModalFooter, ModalHeader, ModalTitle, } from '../../../primitives/modal.js';
|
|
19
19
|
import { Skeleton } from '../../../primitives/skeleton.js';
|
|
20
|
-
import { Tabs,
|
|
20
|
+
import { Tabs, TabsList, TabsTrigger } from '../../../primitives/tabs.js';
|
|
21
21
|
import { errorToast, successToast } from '../../../primitives/toast.js';
|
|
22
22
|
import { agentHref, capabilityTabHref } from '../../../internal/lib/capability-tab-routes.js';
|
|
23
23
|
import { UiLink as Link } from '../../../providers/ui-provider.js';
|
|
@@ -118,7 +118,7 @@ export function ConnectorPolicySetBar({ projectId, slug, canWrite, value, onChan
|
|
|
118
118
|
const ruleTotal = selected ? selected.policies.length : (baseQuery.data?.policies.length ?? 0);
|
|
119
119
|
// Agents that can take this set: every agent not on it yet.
|
|
120
120
|
const giveTo = selected ? access.agents.filter((agent) => !agents.includes(agent)) : [];
|
|
121
|
-
return (_jsxs("div", { className: "space-y-2", children: [_jsxs("div", { className: "flex min-w-0 items-center gap-2", children: [_jsx("div", { className: "min-w-0 overflow-x-auto", children: _jsx(Tabs, { value: value ?? BASE_VALUE, onValueChange: (next) => onChange(next === BASE_VALUE ? null : next), children: _jsxs(
|
|
121
|
+
return (_jsxs("div", { className: "space-y-2", children: [_jsxs("div", { className: "flex min-w-0 items-center gap-2", children: [_jsx("div", { className: "min-w-0 overflow-x-auto", children: _jsx(Tabs, { value: value ?? BASE_VALUE, onValueChange: (next) => onChange(next === BASE_VALUE ? null : next), children: _jsxs(TabsList, { size: "xs", "aria-label": t('rulesFor'), children: [_jsx(TabsTrigger, { value: BASE_VALUE, children: t('baseRules') }), sets.map((set) => (_jsxs(TabsTrigger, { value: set.name, title: set.name, children: [policySetLabel(set.name), _jsxs("span", { className: "text-muted-foreground", children: [' · ', t('agentCount', { count: set.agents.length })] })] }, set.name)))] }) }) }), _jsxs(Button, { variant: "ghost", size: "sm", className: "shrink-0", onClick: () => setEditor({ mode: 'create' }), children: [_jsx(PlusIcon, { className: "size-3.5 shrink-0" }), t('createTitle')] })] }), _jsxs("div", { className: "flex flex-wrap items-center justify-between gap-x-4 gap-y-1", children: [_jsxs("p", { className: "text-muted-foreground min-w-0 text-xs text-pretty", children: [selected ? (_jsxs(_Fragment, { children: [selected.description ? `${selected.description} · ` : null, agents.length > 0 ? (_jsxs(_Fragment, { children: [t('usedByLead'), ' ', agents.map((agent, index) => (_jsxs(Fragment, { children: [index > 0 ? ', ' : null, _jsx(Link, { href: `${agentHref(projectId, agent)}?section=connectors`, className: "text-foreground underline-offset-4 hover:underline", children: agent })] }, agent)))] })) : (_jsxs(_Fragment, { children: [t('unusedLead'), ' ', _jsx(Link, { href: capabilityTabHref(projectId, 'agent'), className: "text-foreground underline-offset-4 hover:underline", children: t('unusedLink') })] }))] })) : (t('baseContext')), ' · ', t('ruleCount', { count: ruleTotal })] }), selected ? (_jsxs("div", { className: "flex shrink-0 items-center gap-1", children: [access.canEdit && giveTo.length > 0 ? (_jsxs(DropdownMenu, { children: [_jsx(DropdownMenuTrigger, { asChild: true, children: _jsxs(Button, { variant: "ghost", size: "xs", disabled: access.pending !== null, children: [t('giveToAgent'), _jsx(CaretDownIcon, { className: "size-3 shrink-0" })] }) }), _jsxs(DropdownMenuContent, { align: "end", className: "min-w-48", children: [_jsx(DropdownMenuLabel, { children: t('giveToAgentLabel', { name: policySetLabel(selected.name) }) }), giveTo.map((agent) => {
|
|
122
122
|
const current = agentConnectorAccess(access.grantsOf(agent), slug);
|
|
123
123
|
return (_jsxs(DropdownMenuItem, { onSelect: () => void access
|
|
124
124
|
.setPolicySet(agent, slug, selected.name, allSlugs)
|
|
@@ -13,7 +13,7 @@ import { ConfirmDialog } from '../../../primitives/confirm-dialog.js';
|
|
|
13
13
|
import { CountBadge } from '../../../primitives/count-badge.js';
|
|
14
14
|
import { Disclosure, DisclosureContent, DisclosureTrigger } from '../../../primitives/disclosure.js';
|
|
15
15
|
import { DropdownMenu, DropdownMenuContent, DropdownMenuItem, DropdownMenuTrigger, } from '../../../primitives/dropdown-menu.js';
|
|
16
|
-
import {
|
|
16
|
+
import { Alert as BannerAlert, AlertTitle as BannerAlertTitle, AlertDescription as BannerAlertDescription, AlertMedia as BannerAlertMedia } from '../../../primitives/alert.js';
|
|
17
17
|
import { InputGroupSearch, InputGroupSearchClear, InputGroupSearchIcon, InputGroupSearchInput, } from '../../../primitives/input-group.js';
|
|
18
18
|
import { Skeleton } from '../../../primitives/skeleton.js';
|
|
19
19
|
import { cn } from '../../../internal/lib/utils.js';
|
|
@@ -214,12 +214,12 @@ export function ConnectorTools({ projectId, connector, displayName, canWrite, on
|
|
|
214
214
|
summary.ask > 0 ? t('toolsSummaryAsk', { count: summary.ask }) : null,
|
|
215
215
|
summary.run > 0 ? t('toolsSummaryRun', { count: summary.run }) : null,
|
|
216
216
|
].filter(Boolean);
|
|
217
|
-
return (_jsxs("div", { className: "space-y-5", children: [showSets ? (_jsx(ConnectorPolicySetBar, { projectId: projectId, slug: slug, canWrite: canWrite, value: policySet, onChange: onPolicySet })) : null, hasTools && policiesQuery.data ? (_jsxs("div", { className: "flex flex-wrap items-center justify-between gap-3", children: [_jsx("p", { className: "text-muted-foreground min-w-0 text-sm tabular-nums", children: summaryParts.join(' · ') }), _jsxs("div", { className: "flex w-full flex-wrap items-center gap-3 sm:w-auto", children: [connector.actions.length > SEARCH_THRESHOLD ? (_jsxs(InputGroupSearch, { className: "w-full sm:w-56", children: [_jsx(InputGroupSearchIcon, { children: _jsx(MagnifyingGlassIcon, {}) }), _jsx(InputGroupSearchInput, { placeholder: tI18nComplete.raw('textfbd165231fa1'), value: query, onChange: (event) => setQuery(event.target.value), size: "sm" }), _jsx(InputGroupSearchClear, { onClick: () => setQuery('') })] })) : null, _jsx(Switch, { label: t('toolsOnlyChanged'), checked: onlyChanged, onCheckedChange: setOnlyChanged, className: "px-0 py-0" })] })] })) : null, projectLockedCount > 0 ? (_jsxs(
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
217
|
+
return (_jsxs("div", { className: "space-y-5", children: [showSets ? (_jsx(ConnectorPolicySetBar, { projectId: projectId, slug: slug, canWrite: canWrite, value: policySet, onChange: onPolicySet })) : null, hasTools && policiesQuery.data ? (_jsxs("div", { className: "flex flex-wrap items-center justify-between gap-3", children: [_jsx("p", { className: "text-muted-foreground min-w-0 text-sm tabular-nums", children: summaryParts.join(' · ') }), _jsxs("div", { className: "flex w-full flex-wrap items-center gap-3 sm:w-auto", children: [connector.actions.length > SEARCH_THRESHOLD ? (_jsxs(InputGroupSearch, { className: "w-full sm:w-56", children: [_jsx(InputGroupSearchIcon, { children: _jsx(MagnifyingGlassIcon, {}) }), _jsx(InputGroupSearchInput, { placeholder: tI18nComplete.raw('textfbd165231fa1'), value: query, onChange: (event) => setQuery(event.target.value), size: "sm" }), _jsx(InputGroupSearchClear, { onClick: () => setQuery('') })] })) : null, _jsx(Switch, { label: t('toolsOnlyChanged'), checked: onlyChanged, onCheckedChange: setOnlyChanged, className: "px-0 py-0" })] })] })) : null, projectLockedCount > 0 ? (_jsxs(BannerAlert, { variant: "warning", children: [_jsx(BannerAlertMedia, { children: _jsx(LockIcon, {}) }), _jsx(BannerAlertTitle, { children: tI18nComplete('textd3d900c89bd0', {
|
|
218
|
+
value0: projectLockedCount,
|
|
219
|
+
value1: projectLockedCount === 1
|
|
220
|
+
? tI18nComplete.raw('text86ca67d2851a')
|
|
221
|
+
: tI18nComplete.raw('textd50ab26e1621'),
|
|
222
|
+
}) }), _jsxs(BannerAlertDescription, { children: [t('toolsProjectLockedBody'), ' ', _jsx(Link, { href: rulesHref(projectId), className: "text-foreground underline underline-offset-4", children: t('toolsOpenRules') })] })] })) : null, policiesQuery.isPending ? (_jsx("div", { className: "space-y-2", children: [0, 1, 2].map((row) => (_jsx(Skeleton, { className: "h-14 rounded-md" }, row))) })) : policiesQuery.isError ? (_jsx(ErrorState, { size: "sm", title: tI18nComplete.raw('textff6065190563'), description: policiesQuery.error instanceof Error
|
|
223
223
|
? policiesQuery.error.message
|
|
224
224
|
: tI18nComplete.raw('texta47c08d35337'), action: _jsx(Button, { variant: "outline", size: "sm", onClick: () => void policiesQuery.refetch(), children: tI18nComplete.raw('text942087cc2d41') }) })) : !hasTools ? (
|
|
225
225
|
// The connector exists but has reported no tools — a failed or pending
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use client';
|
|
2
2
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
3
3
|
import { adminPath } from '../../../lib/routes.js';
|
|
4
|
-
import { useProjectTriggerEventApps, useProjectTriggers } from '@kortix/sdk/react';
|
|
4
|
+
import { useFeatureFlags, useProjectTriggerEventApps, useProjectTriggers } from '@kortix/sdk/react';
|
|
5
5
|
import { PlusIcon } from '@phosphor-icons/react';
|
|
6
6
|
import { UiLink as Link } from '../../../providers/ui-provider.js';
|
|
7
7
|
import { useState } from 'react';
|
|
@@ -16,14 +16,13 @@ import { Button } from '../../../primitives/button.js';
|
|
|
16
16
|
import { Label } from '../../../primitives/label.js';
|
|
17
17
|
import { Skeleton } from '../../../primitives/skeleton.js';
|
|
18
18
|
import { useTranslations } from '../../../i18n/index.js';
|
|
19
|
-
import { useProjectFeatureFlags } from '../../../internal/lib/use-project-feature-flags.js';
|
|
20
19
|
/**
|
|
21
20
|
* Whether the connector's app has events, and the project's event triggers on it.
|
|
22
21
|
* Shared by the tab and its count. With the project flag `event_triggers` off,
|
|
23
22
|
* the connector has no events: the tab is absent and no event data is requested.
|
|
24
23
|
*/
|
|
25
24
|
export function useConnectorEventTriggers(projectId, connector) {
|
|
26
|
-
const eventsOn =
|
|
25
|
+
const eventsOn = useFeatureFlags(projectId).flags.event_triggers === true;
|
|
27
26
|
const apps = useProjectTriggerEventApps(eventsOn ? projectId : null);
|
|
28
27
|
const triggers = useProjectTriggers(projectId);
|
|
29
28
|
const hasEvents = eventsOn &&
|
|
@@ -21,7 +21,7 @@ import { useProjectCan } from '../../../internal/lib/use-project-can.js';
|
|
|
21
21
|
import { Button } from '../../../primitives/button.js';
|
|
22
22
|
import { Checkbox } from '../../../primitives/checkbox.js';
|
|
23
23
|
import { Field } from '../../../primitives/field.js';
|
|
24
|
-
import {
|
|
24
|
+
import { Alert as BannerAlert, AlertDescription as BannerAlertDescription } from '../../../primitives/alert.js';
|
|
25
25
|
import { Input } from '../../../primitives/input.js';
|
|
26
26
|
import { Label } from '../../../primitives/label.js';
|
|
27
27
|
import Loading from '../../../primitives/loading.js';
|
|
@@ -164,7 +164,7 @@ export function EmailSenderPolicyDialog({ projectId, inbox, open, onOpenChange,
|
|
|
164
164
|
onError: (e) => setError(e.message),
|
|
165
165
|
});
|
|
166
166
|
};
|
|
167
|
-
return (_jsx(Modal, { open: open, onOpenChange: (next) => !update.isPending && onOpenChange(next), children: _jsxs(ModalContent, { className: "lg:max-w-lg", children: [_jsxs(ModalHeader, { children: [_jsx(ModalTitle, { children: t('policyTitle', { address: inbox?.email ?? '' }) }), _jsx(ModalDescription, { children: t('policyDescription') })] }), _jsx(ModalBody, { className: "space-y-3", children: _jsxs("div", { className: "flex items-start gap-3", children: [_jsx(Checkbox, { id: "email-inbox-restricted", checked: restricted, onCheckedChange: (checked) => setRestricted(Boolean(checked)), className: "mt-0.5" }), _jsxs("div", { className: "min-w-0 flex-1 space-y-3", children: [_jsxs("div", { children: [_jsx(Label, { htmlFor: "email-inbox-restricted", children: tI18nComplete.raw('texta48c89f63885') }), _jsx("p", { className: "text-muted-foreground mt-1 text-xs", children: tI18nComplete.raw('text8c67b476d59b') })] }), restricted ? (_jsxs("div", { className: "grid gap-3", children: [_jsx(Field, { children: _jsx(Input, { value: emails, onChange: (e) => setEmails(e.target.value), placeholder: tI18nComplete.raw('text542d24012988') }) }), _jsx(Field, { children: _jsx(Input, { value: domains, onChange: (e) => setDomains(e.target.value), placeholder: tI18nComplete.raw('texta379a6f6eeaf') }) }), _jsx(Field, { children: _jsx(Input, { value: regex, onChange: (e) => setRegex(e.target.value), placeholder: tI18nComplete.raw('text8b21058f3253'), spellCheck: false }) })] })) : null, error ? _jsx(
|
|
167
|
+
return (_jsx(Modal, { open: open, onOpenChange: (next) => !update.isPending && onOpenChange(next), children: _jsxs(ModalContent, { className: "lg:max-w-lg", children: [_jsxs(ModalHeader, { children: [_jsx(ModalTitle, { children: t('policyTitle', { address: inbox?.email ?? '' }) }), _jsx(ModalDescription, { children: t('policyDescription') })] }), _jsx(ModalBody, { className: "space-y-3", children: _jsxs("div", { className: "flex items-start gap-3", children: [_jsx(Checkbox, { id: "email-inbox-restricted", checked: restricted, onCheckedChange: (checked) => setRestricted(Boolean(checked)), className: "mt-0.5" }), _jsxs("div", { className: "min-w-0 flex-1 space-y-3", children: [_jsxs("div", { children: [_jsx(Label, { htmlFor: "email-inbox-restricted", children: tI18nComplete.raw('texta48c89f63885') }), _jsx("p", { className: "text-muted-foreground mt-1 text-xs", children: tI18nComplete.raw('text8c67b476d59b') })] }), restricted ? (_jsxs("div", { className: "grid gap-3", children: [_jsx(Field, { children: _jsx(Input, { value: emails, onChange: (e) => setEmails(e.target.value), placeholder: tI18nComplete.raw('text542d24012988') }) }), _jsx(Field, { children: _jsx(Input, { value: domains, onChange: (e) => setDomains(e.target.value), placeholder: tI18nComplete.raw('texta379a6f6eeaf') }) }), _jsx(Field, { children: _jsx(Input, { value: regex, onChange: (e) => setRegex(e.target.value), placeholder: tI18nComplete.raw('text8b21058f3253'), spellCheck: false }) })] })) : null, error ? _jsx(BannerAlert, { variant: "destructive", children: _jsx(BannerAlertDescription, { children: error }) }) : null] })] }) }), _jsxs(ModalFooter, { className: "sm:justify-between", children: [_jsx(Button, { variant: "outline-ghost", onClick: () => onOpenChange(false), disabled: update.isPending, children: tI18nComplete.raw('text19766ed6ccb2') }), _jsxs(Button, { onClick: save, disabled: update.isPending, children: [update.isPending ? _jsx(Loading, { className: "size-4 shrink-0" }) : null, tI18nComplete.raw('text1509f561f241')] })] })] }) }));
|
|
168
168
|
}
|
|
169
169
|
/**
|
|
170
170
|
* The Email hero (Channels tab, the Email page): the pitch until a first inbox
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import type { ResourceScope } from '../shared/agent-resource-scope.js';
|
|
2
2
|
import type { ReactNode } from 'react';
|
|
3
3
|
/**
|
|
4
|
-
* The page body for /
|
|
4
|
+
* The page body for /workspaces/[id]/models — Models graduated out of the
|
|
5
5
|
* project Settings sub-nav into its own top-level Customize tab, alongside
|
|
6
6
|
* Connectors / Agents / Skills / Triggers. Picking a model is not
|
|
7
7
|
* "configuration" the way Secrets or Channels are; it is a first-class
|
|
@@ -5,7 +5,7 @@ import { LlmManagementView } from '../sections/gateway-view.js';
|
|
|
5
5
|
import { SettingsNavProvider } from '../../internal/layout/settings-nav-context.js';
|
|
6
6
|
import { AppReturnBar } from './app-return-bar.js';
|
|
7
7
|
/**
|
|
8
|
-
* The page body for /
|
|
8
|
+
* The page body for /workspaces/[id]/models — Models graduated out of the
|
|
9
9
|
* project Settings sub-nav into its own top-level Customize tab, alongside
|
|
10
10
|
* Connectors / Agents / Skills / Triggers. Picking a model is not
|
|
11
11
|
* "configuration" the way Secrets or Channels are; it is a first-class
|
|
@@ -1,29 +1,60 @@
|
|
|
1
1
|
import { type Icon } from '@phosphor-icons/react';
|
|
2
|
+
import { type WorkspaceSettingsGroup, type WorkspaceSettingsSection } from '../../_vendor/shared/workspace-settings.js';
|
|
3
|
+
import type { AccountSection } from '../../internal/account-hub/sections.js';
|
|
2
4
|
import type { CapabilityTab } from '../../internal/lib/capability-tab-routes.js';
|
|
3
5
|
import { type ProjectSettingsSectionKey } from './project-settings-sections.js';
|
|
4
6
|
/**
|
|
5
|
-
* The sections of
|
|
7
|
+
* The sections of Workspace settings (`/workspaces/<id>/admin/<section>`), the
|
|
8
|
+
* one Settings panel per workspace (design.md §3.2 C7). The order, the groups,
|
|
9
|
+
* the old ids and the English labels come from one registry,
|
|
10
|
+
* `@kortix/shared/workspace-settings`, which the CLI, the API emails and the
|
|
11
|
+
* My Kortix prompt read too. This file adds what only the web panel needs:
|
|
12
|
+
* which pane renders a section, and the library rows' capability gates.
|
|
6
13
|
*
|
|
7
|
-
*
|
|
8
|
-
*
|
|
9
|
-
*
|
|
14
|
+
* 1. **Workspace** — General (name, icon, workspace id, Danger zone),
|
|
15
|
+
* Security (MFA, session policy, key policy, oversight), Branding, Git,
|
|
16
|
+
* Sandbox, Feature flags, API keys, Capture (while Capture is on).
|
|
17
|
+
* 2. **Library** — the global variant of each library page.
|
|
18
|
+
* 3. **People** — Members (one roster, one role per person), Groups, Roles,
|
|
19
|
+
* Identity, Audit log.
|
|
20
|
+
* 4. **Billing** — Plan, Usage.
|
|
21
|
+
* 5. **Support** — Help.
|
|
10
22
|
*
|
|
11
|
-
*
|
|
12
|
-
*
|
|
13
|
-
* on the agent's own page, and a project-wide list changed nothing.
|
|
14
|
-
* 2. **Settings** — the sections of `project-settings-sections.ts`, unchanged.
|
|
15
|
-
*
|
|
16
|
-
* A key IS its URL segment (`/admin/<key>`), so renaming one breaks live links. The
|
|
17
|
-
* settings keys are the Settings page's own keys, so `?section=git` means the
|
|
18
|
-
* same section on both surfaces.
|
|
23
|
+
* A key IS its URL segment (`/admin/<key>`), so renaming one breaks live links:
|
|
24
|
+
* rename it in the registry, which keeps the old id as an alias.
|
|
19
25
|
*/
|
|
20
|
-
export type
|
|
26
|
+
export type ProjectAdminSectionKey = WorkspaceSettingsSection;
|
|
27
|
+
export type ProjectAdminResourceKey = Extract<WorkspaceSettingsSection, 'agents' | 'connectors' | 'skills' | 'triggers' | 'models' | 'secrets' | 'apps' | 'drives' | 'repo'>;
|
|
21
28
|
/**
|
|
22
29
|
* The Settings sections this page lists. Review is not one: it is its own
|
|
23
30
|
* standalone surface, and `projectSettingsSections` never lists it.
|
|
24
31
|
*/
|
|
25
32
|
export type ProjectAdminSettingsKey = Exclude<ProjectSettingsSectionKey, 'review'>;
|
|
26
|
-
|
|
33
|
+
/** The sections whose pane is a host pane of the workspace's account (`apps/web`). */
|
|
34
|
+
export type WorkspaceAccountSectionKey = Extract<WorkspaceSettingsSection, 'security' | 'branding' | 'api-keys' | 'members' | 'groups' | 'roles' | 'identity' | 'audit' | 'help' | 'plan' | 'usage'>;
|
|
35
|
+
export type WorkspaceSettingsGroupId = WorkspaceSettingsGroup;
|
|
36
|
+
/** The rail, in order. Each row still follows its own visibility rule. */
|
|
37
|
+
export declare const WORKSPACE_SETTINGS_GROUPS: readonly {
|
|
38
|
+
id: WorkspaceSettingsGroupId;
|
|
39
|
+
sections: readonly ProjectAdminSectionKey[];
|
|
40
|
+
}[];
|
|
41
|
+
/**
|
|
42
|
+
* The account pane each workspace section shows. Git is a project section
|
|
43
|
+
* that ALSO carries an account pane (the account's GitHub connections).
|
|
44
|
+
*/
|
|
45
|
+
export declare const ACCOUNT_TAB_FOR_SECTION: Partial<Record<ProjectAdminSectionKey, AccountSection>>;
|
|
46
|
+
/**
|
|
47
|
+
* Old account hub link (`?accountTab=`) → the workspace section that took it
|
|
48
|
+
* over. Access merged into Members; the account Settings pane is Security.
|
|
49
|
+
*/
|
|
50
|
+
export declare const SECTION_FOR_ACCOUNT_TAB: Record<AccountSection, ProjectAdminSectionKey>;
|
|
51
|
+
export declare function isWorkspaceAccountSection(key: ProjectAdminSectionKey): key is WorkspaceAccountSectionKey;
|
|
52
|
+
/**
|
|
53
|
+
* The catalog key of a section's rail label: `workspaces.settings.sections.<key>`.
|
|
54
|
+
* The en catalog holds the registry's English label (`WORKSPACE_SETTINGS_LABELS`);
|
|
55
|
+
* a web test keeps them equal.
|
|
56
|
+
*/
|
|
57
|
+
export declare function sectionLabelKey(section: ProjectAdminSectionKey): string;
|
|
27
58
|
export interface ProjectAdminResource {
|
|
28
59
|
key: ProjectAdminResourceKey;
|
|
29
60
|
icon: Icon;
|
|
@@ -42,17 +73,23 @@ export interface ProjectAdminResource {
|
|
|
42
73
|
* off, the sidebar's Files row is the repo browser (`projectNavRows`).
|
|
43
74
|
*/
|
|
44
75
|
flag?: 'drives';
|
|
76
|
+
/**
|
|
77
|
+
* The row opens on its capability alone, without Settings access. Agents:
|
|
78
|
+
* a member who may read the agents browsed them under Customize before
|
|
79
|
+
* Customize became this panel (2026-11-08), and still does.
|
|
80
|
+
*/
|
|
81
|
+
memberOpen?: true;
|
|
45
82
|
}
|
|
46
83
|
/** Rail order. Icons match the agent editor's tabs (`agent-page.tsx`). */
|
|
47
84
|
export declare const PROJECT_ADMIN_RESOURCES: readonly ProjectAdminResource[];
|
|
48
85
|
/** Sections that no longer exist here: their links open the Agents list. */
|
|
49
86
|
export declare const RETIRED_SECTIONS: readonly string[];
|
|
50
|
-
/** `/
|
|
87
|
+
/** `/workspaces/<id>/admin` with no section opens General, else the first row the caller may open. */
|
|
51
88
|
export declare const DEFAULT_PROJECT_ADMIN_SECTION: ProjectAdminSectionKey;
|
|
52
89
|
export declare function isProjectAdminResource(key: ProjectAdminSectionKey): key is ProjectAdminResourceKey;
|
|
53
90
|
export declare function parseProjectAdminSection(raw: string | null | undefined): ProjectAdminSectionKey | null;
|
|
54
91
|
/**
|
|
55
|
-
* The link to one section: `/
|
|
92
|
+
* The link to one section: `/workspaces/<id>/admin/<section>`. `extra` adds page
|
|
56
93
|
* params (`scope=channels` for the Connectors page's Channels scope).
|
|
57
94
|
*/
|
|
58
95
|
export declare function projectAdminHref(projectId: string, key?: ProjectAdminSectionKey, extra?: Record<string, string>): string;
|
|
@@ -64,4 +101,3 @@ export declare function projectAdminHref(projectId: string, key?: ProjectAdminSe
|
|
|
64
101
|
* section here (`members`, `review`, a personal overlay tab).
|
|
65
102
|
*/
|
|
66
103
|
export declare function projectAdminNavTarget(tab: string): ProjectAdminSectionKey | null;
|
|
67
|
-
export declare const RESOURCE_LABEL_KEYS: Partial<Record<ProjectAdminResourceKey, string>>;
|