@agent-native/core 0.117.0 → 0.117.2
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/corpus/README.md +2 -2
- package/corpus/core/CHANGELOG.md +16 -0
- package/corpus/core/package.json +2 -1
- package/corpus/core/src/cli/context-xray-local.ts +1 -1
- package/corpus/core/src/client/extensions/ExtensionViewer.tsx +4 -4
- package/corpus/core/src/client/extensions/ExtensionsSidebarSection.tsx +11 -11
- package/corpus/core/src/client/extensions/agent-native-extension-runtime.ts +1 -1
- package/corpus/core/src/client/extensions/delete-extension.ts +2 -2
- package/corpus/core/src/client/org/OrgSwitcher.tsx +25 -1
- package/corpus/core/src/client/settings/SettingsPanel.tsx +102 -10
- package/corpus/core/src/client/sharing/ShareButton.tsx +7 -6
- package/corpus/core/src/db/client.ts +13 -10
- package/corpus/core/src/deploy/workspace-deploy.ts +14 -4
- package/corpus/core/src/extensions/actions.ts +13 -5
- package/corpus/core/src/extensions/local.ts +1 -0
- package/corpus/core/src/extensions/routes.ts +10 -5
- package/corpus/core/src/extensions/schema.ts +5 -0
- package/corpus/core/src/extensions/slots/store.ts +14 -4
- package/corpus/core/src/extensions/store.ts +55 -19
- package/corpus/core/src/extensions/theme.ts +1 -1
- package/corpus/core/src/file-upload/registry.ts +9 -0
- package/corpus/core/src/index.browser.ts +5 -0
- package/corpus/core/src/index.ts +1 -0
- package/corpus/core/src/localization/default-messages.ts +23 -6
- package/corpus/core/src/server/action-discovery.ts +8 -0
- package/corpus/core/src/server/better-auth-instance.ts +7 -2
- package/corpus/core/src/server/email-template.ts +18 -0
- package/corpus/core/src/server/email-templates.ts +3 -0
- package/corpus/core/src/server/email.ts +40 -4
- package/corpus/core/src/sharing/actions/share-resource.ts +1 -0
- package/corpus/core/src/templates/default/.agents/skills/agent-native-toolkit/SKILL.md +6 -0
- package/corpus/core/src/templates/default/app/global.css +1 -1
- package/corpus/core/src/templates/default/app/i18n/ar-SA.ts +6 -6
- package/corpus/core/src/templates/default/app/i18n/de-DE.ts +6 -6
- package/corpus/core/src/templates/default/app/i18n/en-US.ts +6 -6
- package/corpus/core/src/templates/default/app/i18n/es-ES.ts +6 -6
- package/corpus/core/src/templates/default/app/i18n/fr-FR.ts +6 -6
- package/corpus/core/src/templates/default/app/i18n/hi-IN.ts +6 -6
- package/corpus/core/src/templates/default/app/i18n/ja-JP.ts +6 -6
- package/corpus/core/src/templates/default/app/i18n/ko-KR.ts +6 -6
- package/corpus/core/src/templates/default/app/i18n/pt-BR.ts +6 -6
- package/corpus/core/src/templates/default/app/i18n/zh-CN.ts +7 -7
- package/corpus/core/src/templates/default/app/i18n/zh-TW.ts +7 -7
- package/corpus/core/src/templates/headless/.agents/skills/agent-native-toolkit/SKILL.md +6 -0
- package/corpus/core/src/templates/workspace-core/.agents/skills/agent-native-toolkit/SKILL.md +6 -0
- package/corpus/core/src/user-profile/actions/get-user-profile.ts +16 -0
- package/corpus/core/src/user-profile/actions/update-user-profile.ts +24 -0
- package/corpus/core/src/user-profile/index.ts +5 -0
- package/corpus/core/src/user-profile/shared.ts +14 -0
- package/corpus/core/src/user-profile/store.ts +50 -0
- package/corpus/templates/analytics/.agents/skills/agent-native-toolkit/SKILL.md +6 -0
- package/corpus/templates/assets/.agents/skills/agent-native-toolkit/SKILL.md +6 -0
- package/corpus/templates/assets/app/components/layout/Sidebar.tsx +2 -2
- package/corpus/templates/assets/app/global.css +1 -1
- package/corpus/templates/assets/changelog/2026-07-22-manage-agent-navigation-now-uses-the-connected-nodes-icon.md +6 -0
- package/corpus/templates/brain/.agents/skills/agent-native-toolkit/SKILL.md +6 -0
- package/corpus/templates/brain/app/global.css +2 -2
- package/corpus/templates/brain/app/lib/brain.ts +2 -2
- package/corpus/templates/brain/app/root.tsx +2 -2
- package/corpus/templates/brain/changelog/2026-07-22-manage-agent-navigation-now-uses-the-connected-nodes-icon.md +6 -0
- package/corpus/templates/calendar/.agents/skills/agent-native-toolkit/SKILL.md +6 -0
- package/corpus/templates/calendar/app/components/layout/Sidebar.tsx +6 -2
- package/corpus/templates/calendar/app/global.css +1 -1
- package/corpus/templates/calendar/app/root.tsx +2 -2
- package/corpus/templates/calendar/changelog/2026-07-22-manage-agent-navigation-now-uses-the-connected-nodes-icon.md +6 -0
- package/corpus/templates/chat/.agents/skills/agent-native-toolkit/SKILL.md +6 -0
- package/corpus/templates/chat/app/components/layout/Sidebar.tsx +2 -2
- package/corpus/templates/chat/app/global.css +1 -1
- package/corpus/templates/chat/app/root.tsx +2 -2
- package/corpus/templates/chat/changelog/2026-07-22-manage-agent-navigation-now-uses-the-connected-nodes-icon.md +6 -0
- package/corpus/templates/clips/.agents/skills/agent-native-toolkit/SKILL.md +6 -0
- package/corpus/templates/clips/actions/export-to-brain.ts +1 -1
- package/corpus/templates/clips/actions/invite-member.ts +1 -0
- package/corpus/templates/clips/app/components/library/library-layout.tsx +2 -2
- package/corpus/templates/clips/app/components/recorder/recorder-engine.ts +20 -11
- package/corpus/templates/clips/app/global.css +1 -1
- package/corpus/templates/clips/app/root.tsx +7 -2
- package/corpus/templates/clips/app/routes/record.tsx +2 -88
- package/corpus/templates/clips/changelog/2026-07-22-builder-connected-recordings-start-resumable-upload-sessions.md +6 -0
- package/corpus/templates/clips/changelog/2026-07-22-clip-thumbnails-now-come-from-the-recording-instead-of-the-p.md +6 -0
- package/corpus/templates/clips/changelog/2026-07-22-clips-emails-now-render-the-agent-native-logo-in-gmail-and-o.md +6 -0
- package/corpus/templates/clips/changelog/2026-07-22-dismissed-zoom-and-teams-meeting-note-prompts-now-stay-dismi.md +6 -0
- package/corpus/templates/clips/changelog/2026-07-22-manage-agent-navigation-now-uses-the-connected-nodes-icon.md +6 -0
- package/corpus/templates/clips/changelog/2026-07-22-quieter-permissions-and-rewind-controls.md +6 -0
- package/corpus/templates/clips/desktop/src/app.tsx +86 -52
- package/corpus/templates/clips/desktop/src/lib/meeting-notification-dismissal.ts +31 -0
- package/corpus/templates/clips/desktop/src/lib/recorder.ts +4 -167
- package/corpus/templates/clips/desktop/src/overlays/meeting-notification.tsx +10 -1
- package/corpus/templates/clips/desktop/src/styles.css +98 -36
- package/corpus/templates/clips/desktop/src-tauri/src/adhoc_meetings_watcher.rs +67 -4
- package/corpus/templates/clips/desktop/src-tauri/src/lib.rs +1 -1
- package/corpus/templates/clips/desktop/src-tauri/src/meetings_watcher.rs +51 -0
- package/corpus/templates/clips/desktop/src-tauri/src/native_screen/custom_capture.rs +5 -1
- package/corpus/templates/clips/desktop/src-tauri/src/native_screen.rs +0 -189
- package/corpus/templates/clips/desktop/src-tauri/src/notifications.rs +62 -0
- package/corpus/templates/clips/server/plugins/db.ts +6 -2
- package/corpus/templates/content/.agents/skills/agent-native-toolkit/SKILL.md +6 -0
- package/corpus/templates/content/app/components/sidebar/DocumentSidebar.tsx +3 -3
- package/corpus/templates/content/app/global.css +1 -1
- package/corpus/templates/content/app/root.tsx +2 -2
- package/corpus/templates/content/changelog/2026-07-22-manage-agent-navigation-now-uses-the-connected-nodes-icon.md +6 -0
- package/corpus/templates/crm/.agents/skills/agent-native-toolkit/SKILL.md +6 -0
- package/corpus/templates/crm/app/global.css +1 -1
- package/corpus/templates/design/.agents/skills/agent-native-toolkit/SKILL.md +6 -0
- package/corpus/templates/design/app/components/design/CanvasContextMenu.tsx +19 -1
- package/corpus/templates/design/app/components/design/DesignCanvas.tsx +12 -1
- package/corpus/templates/design/app/components/design/EditPanel.tsx +177 -52
- package/corpus/templates/design/app/components/design/MultiScreenCanvas.tsx +179 -59
- package/corpus/templates/design/app/components/design/bridge/editor-chrome.bridge.ts +74 -27
- package/corpus/templates/design/app/components/design/multi-screen/types.ts +2 -0
- package/corpus/templates/design/app/components/layout/Sidebar.tsx +2 -2
- package/corpus/templates/design/app/global.css +1 -1
- package/corpus/templates/design/app/hooks/use-navigation-state.ts +6 -5
- package/corpus/templates/design/app/root.tsx +2 -2
- package/corpus/templates/design/changelog/2026-07-22-design-owners-can-keep-editing-their-designs-after-switching.md +6 -0
- package/corpus/templates/design/changelog/2026-07-22-inspector-tabs-keep-their-text-labels-at-narrow-widths.md +6 -0
- package/corpus/templates/design/changelog/2026-07-22-manage-agent-navigation-now-uses-the-connected-nodes-icon.md +6 -0
- package/corpus/templates/design/changelog/2026-07-22-narrow-breakpoint-previews-keep-their-device-labels-readable.md +6 -0
- package/corpus/templates/design/changelog/2026-07-22-removed-the-draft-status-chip-from-the-design-editor.md +6 -0
- package/corpus/templates/design/changelog/2026-07-22-responsive-breakpoint-controls-stay-within-narrow-sidebars.md +6 -0
- package/corpus/templates/design/changelog/2026-07-22-responsive-peers-now-use-a-softer-selection-highlight-withou.md +6 -0
- package/corpus/templates/design/changelog/2026-07-22-rotate-from-context-menu.md +6 -0
- package/corpus/templates/design/changelog/2026-07-22-the-selection-outline-now-stays-attached-while-moving-screen.md +6 -0
- package/corpus/templates/design/changelog/2026-07-22-view-only-designs-now-support-figma-style-layer-inspection-w.md +6 -0
- package/corpus/templates/design/server/db/index.ts +4 -0
- package/corpus/templates/dispatch/.agents/skills/agent-native-toolkit/SKILL.md +6 -0
- package/corpus/templates/dispatch/app/dispatch-extensions.tsx +2 -2
- package/corpus/templates/dispatch/app/global.css +1 -1
- package/corpus/templates/dispatch/app/root.tsx +2 -2
- package/corpus/templates/dispatch/changelog/2026-07-22-manage-agent-navigation-now-uses-the-connected-nodes-icon.md +6 -0
- package/corpus/templates/forms/.agents/skills/agent-native-toolkit/SKILL.md +6 -0
- package/corpus/templates/forms/app/components/layout/Layout.tsx +1 -1
- package/corpus/templates/forms/app/components/layout/Sidebar.tsx +3 -3
- package/corpus/templates/forms/app/global.css +1 -1
- package/corpus/templates/forms/app/hooks/use-forms.ts +55 -2
- package/corpus/templates/forms/app/i18n/en-US.ts +2 -0
- package/corpus/templates/forms/app/pages/FormBuilderPage.tsx +3 -3
- package/corpus/templates/forms/app/pages/FormsListPage.tsx +23 -6
- package/corpus/templates/forms/app/root.tsx +2 -2
- package/corpus/templates/forms/changelog/2026-07-22-forms-now-archive-with-optimistic-feedback.md +6 -0
- package/corpus/templates/forms/changelog/2026-07-22-manage-agent-navigation-now-uses-the-connected-nodes-icon.md +6 -0
- package/corpus/templates/forms/server/plugins/agent-chat.ts +1 -1
- package/corpus/templates/macros/.agents/skills/agent-native-toolkit/SKILL.md +6 -0
- package/corpus/templates/macros/app/components/layout/AppLayout.tsx +2 -2
- package/corpus/templates/macros/app/root.tsx +2 -2
- package/corpus/templates/macros/changelog/2026-07-22-manage-agent-navigation-now-uses-the-connected-nodes-icon.md +6 -0
- package/corpus/templates/mail/.agents/skills/agent-native-toolkit/SKILL.md +6 -0
- package/corpus/templates/mail/app/components/layout/AppLayout.tsx +3 -3
- package/corpus/templates/mail/app/components/layout/CommandPalette.tsx +2 -2
- package/corpus/templates/mail/app/global.css +1 -1
- package/corpus/templates/mail/changelog/2026-07-22-manage-agent-navigation-now-uses-the-connected-nodes-icon.md +6 -0
- package/corpus/templates/plan/.agents/skills/agent-native-toolkit/SKILL.md +6 -0
- package/corpus/templates/plan/app/components/layout/Sidebar.tsx +2 -2
- package/corpus/templates/plan/app/global.css +1 -1
- package/corpus/templates/plan/app/root.tsx +2 -2
- package/corpus/templates/plan/changelog/2026-07-22-manage-agent-navigation-now-uses-the-connected-nodes-icon.md +6 -0
- package/corpus/templates/slides/.agents/skills/agent-native-toolkit/SKILL.md +6 -0
- package/corpus/templates/slides/app/components/layout/Sidebar.tsx +2 -2
- package/corpus/templates/slides/app/root.tsx +2 -2
- package/corpus/templates/slides/changelog/2026-07-22-manage-agent-navigation-now-uses-the-connected-nodes-icon.md +6 -0
- package/corpus/templates/slides/changelog/2026-07-22-slides-no-longer-fail-intermittently-on-fresh-server-instances.md +6 -0
- package/corpus/templates/slides/changelog/2026-07-22-uploaded-screenshots-can-now-be-analyzed-and-recreated-as-ed.md +6 -0
- package/corpus/templates/slides/server/lib/chat-attachments.ts +7 -3
- package/corpus/templates/slides/server/plugins/db.ts +44 -17
- package/corpus/templates/tasks/.agents/skills/agent-native-toolkit/SKILL.md +6 -0
- package/corpus/templates/tasks/app/global.css +1 -1
- package/dist/cli/context-xray-local.js +1 -1
- package/dist/cli/context-xray-local.js.map +1 -1
- package/dist/client/extensions/ExtensionViewer.js +2 -2
- package/dist/client/extensions/ExtensionViewer.js.map +1 -1
- package/dist/client/extensions/ExtensionsSidebarSection.js +11 -11
- package/dist/client/extensions/ExtensionsSidebarSection.js.map +1 -1
- package/dist/client/extensions/agent-native-extension-runtime.js +1 -1
- package/dist/client/extensions/agent-native-extension-runtime.js.map +1 -1
- package/dist/client/extensions/delete-extension.d.ts +1 -1
- package/dist/client/extensions/delete-extension.d.ts.map +1 -1
- package/dist/client/extensions/delete-extension.js +1 -1
- package/dist/client/extensions/delete-extension.js.map +1 -1
- package/dist/client/org/OrgSwitcher.d.ts +3 -1
- package/dist/client/org/OrgSwitcher.d.ts.map +1 -1
- package/dist/client/org/OrgSwitcher.js +12 -4
- package/dist/client/org/OrgSwitcher.js.map +1 -1
- package/dist/client/settings/SettingsPanel.d.ts.map +1 -1
- package/dist/client/settings/SettingsPanel.js +37 -4
- package/dist/client/settings/SettingsPanel.js.map +1 -1
- package/dist/client/sharing/ShareButton.d.ts +3 -4
- package/dist/client/sharing/ShareButton.d.ts.map +1 -1
- package/dist/client/sharing/ShareButton.js +3 -2
- package/dist/client/sharing/ShareButton.js.map +1 -1
- package/dist/collab/awareness.d.ts +2 -2
- package/dist/collab/awareness.d.ts.map +1 -1
- package/dist/collab/routes.d.ts +1 -1
- package/dist/collab/struct-routes.d.ts +1 -1
- package/dist/db/client.d.ts +7 -7
- package/dist/db/client.d.ts.map +1 -1
- package/dist/db/client.js +13 -10
- package/dist/db/client.js.map +1 -1
- package/dist/deploy/workspace-deploy.js +14 -4
- package/dist/deploy/workspace-deploy.js.map +1 -1
- package/dist/extensions/actions.d.ts.map +1 -1
- package/dist/extensions/actions.js +8 -5
- package/dist/extensions/actions.js.map +1 -1
- package/dist/extensions/local.d.ts.map +1 -1
- package/dist/extensions/local.js +1 -0
- package/dist/extensions/local.js.map +1 -1
- package/dist/extensions/routes.d.ts.map +1 -1
- package/dist/extensions/routes.js +9 -4
- package/dist/extensions/routes.js.map +1 -1
- package/dist/extensions/schema.d.ts +23 -2
- package/dist/extensions/schema.d.ts.map +1 -1
- package/dist/extensions/schema.js +5 -0
- package/dist/extensions/schema.js.map +1 -1
- package/dist/extensions/slots/store.d.ts +1 -1
- package/dist/extensions/slots/store.d.ts.map +1 -1
- package/dist/extensions/slots/store.js +4 -4
- package/dist/extensions/slots/store.js.map +1 -1
- package/dist/extensions/store.d.ts +1 -0
- package/dist/extensions/store.d.ts.map +1 -1
- package/dist/extensions/store.js +38 -21
- package/dist/extensions/store.js.map +1 -1
- package/dist/extensions/theme.js +1 -1
- package/dist/extensions/theme.js.map +1 -1
- package/dist/file-upload/registry.d.ts.map +1 -1
- package/dist/file-upload/registry.js +9 -0
- package/dist/file-upload/registry.js.map +1 -1
- package/dist/index.browser.d.ts +1 -0
- package/dist/index.browser.d.ts.map +1 -1
- package/dist/index.browser.js +1 -0
- package/dist/index.browser.js.map +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -0
- package/dist/index.js.map +1 -1
- package/dist/localization/default-messages.d.ts +16 -0
- package/dist/localization/default-messages.d.ts.map +1 -1
- package/dist/localization/default-messages.js +22 -6
- package/dist/localization/default-messages.js.map +1 -1
- package/dist/notifications/routes.d.ts +2 -2
- package/dist/observability/routes.d.ts +5 -5
- package/dist/progress/routes.d.ts +1 -1
- package/dist/provider-api/actions/custom-provider-registration.d.ts +7 -7
- package/dist/provider-api/actions/provider-api.d.ts +11 -11
- package/dist/provider-api/corpus-jobs.d.ts +2 -2
- package/dist/secrets/routes.d.ts +6 -6
- package/dist/server/action-discovery.d.ts.map +1 -1
- package/dist/server/action-discovery.js +8 -0
- package/dist/server/action-discovery.js.map +1 -1
- package/dist/server/agent-engine-api-key-route.d.ts +1 -1
- package/dist/server/better-auth-instance.d.ts +7 -2
- package/dist/server/better-auth-instance.d.ts.map +1 -1
- package/dist/server/better-auth-instance.js.map +1 -1
- package/dist/server/email-template.d.ts +3 -0
- package/dist/server/email-template.d.ts.map +1 -1
- package/dist/server/email-template.js +13 -0
- package/dist/server/email-template.js.map +1 -1
- package/dist/server/email-templates.d.ts.map +1 -1
- package/dist/server/email-templates.js +3 -0
- package/dist/server/email-templates.js.map +1 -1
- package/dist/server/email.d.ts.map +1 -1
- package/dist/server/email.js +27 -4
- package/dist/server/email.js.map +1 -1
- package/dist/server/transcribe-voice.d.ts +1 -1
- package/dist/sharing/actions/share-resource.js +1 -0
- package/dist/sharing/actions/share-resource.js.map +1 -1
- package/dist/templates/chat/.agents/skills/agent-native-toolkit/SKILL.md +6 -0
- package/dist/templates/chat/app/components/layout/Sidebar.tsx +2 -2
- package/dist/templates/chat/app/global.css +1 -1
- package/dist/templates/chat/app/root.tsx +2 -2
- package/dist/templates/chat/changelog/2026-07-22-manage-agent-navigation-now-uses-the-connected-nodes-icon.md +6 -0
- package/dist/templates/default/.agents/skills/agent-native-toolkit/SKILL.md +6 -0
- package/dist/templates/default/app/global.css +1 -1
- package/dist/templates/default/app/i18n/ar-SA.ts +6 -6
- package/dist/templates/default/app/i18n/de-DE.ts +6 -6
- package/dist/templates/default/app/i18n/en-US.ts +6 -6
- package/dist/templates/default/app/i18n/es-ES.ts +6 -6
- package/dist/templates/default/app/i18n/fr-FR.ts +6 -6
- package/dist/templates/default/app/i18n/hi-IN.ts +6 -6
- package/dist/templates/default/app/i18n/ja-JP.ts +6 -6
- package/dist/templates/default/app/i18n/ko-KR.ts +6 -6
- package/dist/templates/default/app/i18n/pt-BR.ts +6 -6
- package/dist/templates/default/app/i18n/zh-CN.ts +7 -7
- package/dist/templates/default/app/i18n/zh-TW.ts +7 -7
- package/dist/templates/headless/.agents/skills/agent-native-toolkit/SKILL.md +6 -0
- package/dist/templates/workspace-core/.agents/skills/agent-native-toolkit/SKILL.md +6 -0
- package/dist/user-profile/actions/get-user-profile.d.ts +4 -0
- package/dist/user-profile/actions/get-user-profile.d.ts.map +1 -0
- package/dist/user-profile/actions/get-user-profile.js +14 -0
- package/dist/user-profile/actions/get-user-profile.js.map +1 -0
- package/dist/user-profile/actions/update-user-profile.d.ts +6 -0
- package/dist/user-profile/actions/update-user-profile.d.ts.map +1 -0
- package/dist/user-profile/actions/update-user-profile.js +20 -0
- package/dist/user-profile/actions/update-user-profile.js.map +1 -0
- package/dist/user-profile/index.d.ts +2 -0
- package/dist/user-profile/index.d.ts.map +1 -0
- package/dist/user-profile/index.js +2 -0
- package/dist/user-profile/index.js.map +1 -0
- package/dist/user-profile/shared.d.ts +7 -0
- package/dist/user-profile/shared.d.ts.map +1 -0
- package/dist/user-profile/shared.js +6 -0
- package/dist/user-profile/shared.js.map +1 -0
- package/dist/user-profile/store.d.ts +4 -0
- package/dist/user-profile/store.d.ts.map +1 -0
- package/dist/user-profile/store.js +38 -0
- package/dist/user-profile/store.js.map +1 -0
- package/package.json +2 -1
- package/src/cli/context-xray-local.ts +1 -1
- package/src/client/extensions/ExtensionViewer.tsx +4 -4
- package/src/client/extensions/ExtensionsSidebarSection.tsx +11 -11
- package/src/client/extensions/agent-native-extension-runtime.ts +1 -1
- package/src/client/extensions/delete-extension.ts +2 -2
- package/src/client/org/OrgSwitcher.tsx +25 -1
- package/src/client/settings/SettingsPanel.tsx +102 -10
- package/src/client/sharing/ShareButton.tsx +7 -6
- package/src/db/client.ts +13 -10
- package/src/deploy/workspace-deploy.ts +14 -4
- package/src/extensions/actions.ts +13 -5
- package/src/extensions/local.ts +1 -0
- package/src/extensions/routes.ts +10 -5
- package/src/extensions/schema.ts +5 -0
- package/src/extensions/slots/store.ts +14 -4
- package/src/extensions/store.ts +55 -19
- package/src/extensions/theme.ts +1 -1
- package/src/file-upload/registry.ts +9 -0
- package/src/index.browser.ts +5 -0
- package/src/index.ts +1 -0
- package/src/localization/default-messages.ts +23 -6
- package/src/server/action-discovery.ts +8 -0
- package/src/server/better-auth-instance.ts +7 -2
- package/src/server/email-template.ts +18 -0
- package/src/server/email-templates.ts +3 -0
- package/src/server/email.ts +40 -4
- package/src/sharing/actions/share-resource.ts +1 -0
- package/src/templates/chat/.agents/skills/agent-native-toolkit/SKILL.md +6 -0
- package/src/templates/chat/app/components/layout/Sidebar.tsx +2 -2
- package/src/templates/chat/app/global.css +1 -1
- package/src/templates/chat/app/root.tsx +2 -2
- package/src/templates/chat/changelog/2026-07-22-manage-agent-navigation-now-uses-the-connected-nodes-icon.md +6 -0
- package/src/templates/default/.agents/skills/agent-native-toolkit/SKILL.md +6 -0
- package/src/templates/default/app/global.css +1 -1
- package/src/templates/default/app/i18n/ar-SA.ts +6 -6
- package/src/templates/default/app/i18n/de-DE.ts +6 -6
- package/src/templates/default/app/i18n/en-US.ts +6 -6
- package/src/templates/default/app/i18n/es-ES.ts +6 -6
- package/src/templates/default/app/i18n/fr-FR.ts +6 -6
- package/src/templates/default/app/i18n/hi-IN.ts +6 -6
- package/src/templates/default/app/i18n/ja-JP.ts +6 -6
- package/src/templates/default/app/i18n/ko-KR.ts +6 -6
- package/src/templates/default/app/i18n/pt-BR.ts +6 -6
- package/src/templates/default/app/i18n/zh-CN.ts +7 -7
- package/src/templates/default/app/i18n/zh-TW.ts +7 -7
- package/src/templates/headless/.agents/skills/agent-native-toolkit/SKILL.md +6 -0
- package/src/templates/workspace-core/.agents/skills/agent-native-toolkit/SKILL.md +6 -0
- package/src/user-profile/actions/get-user-profile.ts +16 -0
- package/src/user-profile/actions/update-user-profile.ts +24 -0
- package/src/user-profile/index.ts +5 -0
- package/src/user-profile/shared.ts +14 -0
- package/src/user-profile/store.ts +50 -0
|
@@ -1926,16 +1926,6 @@ declare var __LIVE_REFLOW_ENABLED__: boolean;
|
|
|
1926
1926
|
if (pos.indexOf("e") !== -1) handle.style.right = "-34px";
|
|
1927
1927
|
selectionOverlay.appendChild(handle);
|
|
1928
1928
|
});
|
|
1929
|
-
var button = document.createElement("span");
|
|
1930
|
-
button.setAttribute("data-agent-native-rotate-handle", "top-center");
|
|
1931
|
-
button.style.cssText =
|
|
1932
|
-
"position:absolute;left:50%;transform:translateX(-50%);top:-22px;" +
|
|
1933
|
-
"width:16px;height:16px;pointer-events:auto;" +
|
|
1934
|
-
"display:flex;align-items:center;justify-content:center;" +
|
|
1935
|
-
"border-radius:999px;background:white;box-shadow:0 1px 3px rgba(0,0,0,0.3);" +
|
|
1936
|
-
"cursor:grab;user-select:none;font-size:10px;line-height:1;color:#333;";
|
|
1937
|
-
button.textContent = "↻";
|
|
1938
|
-
selectionOverlay.appendChild(button);
|
|
1939
1929
|
})();
|
|
1940
1930
|
var spacingOverlay = document.createElement("div");
|
|
1941
1931
|
spacingOverlay.setAttribute("data-agent-native-spacing-overlay", "");
|
|
@@ -1943,6 +1933,7 @@ declare var __LIVE_REFLOW_ENABLED__: boolean;
|
|
|
1943
1933
|
"position:absolute;inset:0;display:none;pointer-events:none;";
|
|
1944
1934
|
selectionOverlay.appendChild(spacingOverlay);
|
|
1945
1935
|
document.body.appendChild(selectionOverlay);
|
|
1936
|
+
if (readOnly) setSelectionOverlayResizeChromeVisible(false);
|
|
1946
1937
|
|
|
1947
1938
|
// ── Gradient edit overlay (in-iframe parity for MultiScreenCanvas's
|
|
1948
1939
|
// GradientEditOverlay) ──────────────────────────────────────────────────
|
|
@@ -2179,7 +2170,21 @@ declare var __LIVE_REFLOW_ENABLED__: boolean;
|
|
|
2179
2170
|
): void {
|
|
2180
2171
|
var color = chromeColorForElement(el);
|
|
2181
2172
|
var contrast = chromeContrastColorForElement(el);
|
|
2182
|
-
|
|
2173
|
+
var softChrome =
|
|
2174
|
+
overlay.getAttribute("data-agent-native-soft-chrome") === "true";
|
|
2175
|
+
overlay.style.borderColor = softChrome
|
|
2176
|
+
? "color-mix(in srgb," + color + " 64%,transparent)"
|
|
2177
|
+
: color;
|
|
2178
|
+
if (softChrome) {
|
|
2179
|
+
overlay.style.background =
|
|
2180
|
+
"color-mix(in srgb," + color + " 5%,transparent)";
|
|
2181
|
+
} else if (
|
|
2182
|
+
overlay === highlightOverlay ||
|
|
2183
|
+
overlay.getAttribute("data-agent-native-edit-overlay") ===
|
|
2184
|
+
"multi-selection"
|
|
2185
|
+
) {
|
|
2186
|
+
overlay.style.background = "transparent";
|
|
2187
|
+
}
|
|
2183
2188
|
overlay
|
|
2184
2189
|
.querySelectorAll(
|
|
2185
2190
|
"[data-agent-native-edit-handle],[data-agent-native-edit-overlay='multi-selection-handle']",
|
|
@@ -2191,6 +2196,19 @@ declare var __LIVE_REFLOW_ENABLED__: boolean;
|
|
|
2191
2196
|
});
|
|
2192
2197
|
}
|
|
2193
2198
|
|
|
2199
|
+
function setHighlightOverlayStyle(style: "default" | "soft"): void {
|
|
2200
|
+
highlightOverlayStyle = style;
|
|
2201
|
+
if (style === "soft") {
|
|
2202
|
+
highlightOverlay.setAttribute("data-agent-native-soft-chrome", "true");
|
|
2203
|
+
} else {
|
|
2204
|
+
highlightOverlay.removeAttribute("data-agent-native-soft-chrome");
|
|
2205
|
+
}
|
|
2206
|
+
if (hoveredEl && hoveredEl !== selectedEl) {
|
|
2207
|
+
applyElementOverlayChrome(highlightOverlay, hoveredEl);
|
|
2208
|
+
}
|
|
2209
|
+
applyEditorChromeScale();
|
|
2210
|
+
}
|
|
2211
|
+
|
|
2194
2212
|
function applySelectionChrome(el: Element | null): void {
|
|
2195
2213
|
applyElementOverlayChrome(selectionOverlay, el);
|
|
2196
2214
|
}
|
|
@@ -2231,6 +2249,7 @@ declare var __LIVE_REFLOW_ENABLED__: boolean;
|
|
|
2231
2249
|
|
|
2232
2250
|
var selectedEl: Element | null = null;
|
|
2233
2251
|
var hoveredEl: Element | null = null;
|
|
2252
|
+
var highlightOverlayStyle: "default" | "soft" = "default";
|
|
2234
2253
|
type NodeHtmlPreviewSession = {
|
|
2235
2254
|
proposalId: string;
|
|
2236
2255
|
originalElement: Element;
|
|
@@ -2526,12 +2545,17 @@ declare var __LIVE_REFLOW_ENABLED__: boolean;
|
|
|
2526
2545
|
scalePassiveSelectionOverlay(overlay);
|
|
2527
2546
|
}
|
|
2528
2547
|
|
|
2529
|
-
function makePassiveSelectionOverlay(): HTMLElement {
|
|
2548
|
+
function makePassiveSelectionOverlay(style: "default" | "soft"): HTMLElement {
|
|
2530
2549
|
var overlay = document.createElement("div");
|
|
2531
2550
|
overlay.setAttribute("data-agent-native-edit-overlay", "multi-selection");
|
|
2551
|
+
if (style === "soft") {
|
|
2552
|
+
overlay.setAttribute("data-agent-native-soft-chrome", "true");
|
|
2553
|
+
}
|
|
2532
2554
|
overlay.style.cssText =
|
|
2533
|
-
|
|
2534
|
-
|
|
2555
|
+
style === "soft"
|
|
2556
|
+
? "position:fixed;pointer-events:none;z-index:99996;border:1px solid color-mix(in srgb,var(--design-editor-accent-color) 64%,transparent);background:color-mix(in srgb,var(--design-editor-accent-color) 5%,transparent);display:none;box-sizing:border-box;"
|
|
2557
|
+
: "position:fixed;pointer-events:none;z-index:99996;border:1.5px solid var(--design-editor-accent-color);background:transparent;display:none;box-sizing:border-box;";
|
|
2558
|
+
if (style !== "soft") appendPassiveSelectionHandles(overlay);
|
|
2535
2559
|
document.body.appendChild(overlay);
|
|
2536
2560
|
return overlay;
|
|
2537
2561
|
}
|
|
@@ -2540,7 +2564,9 @@ declare var __LIVE_REFLOW_ENABLED__: boolean;
|
|
|
2540
2564
|
var sx = chromeScaleX();
|
|
2541
2565
|
var sy = chromeScaleY();
|
|
2542
2566
|
var line = chromeLineScale();
|
|
2543
|
-
|
|
2567
|
+
var softChrome =
|
|
2568
|
+
overlay.getAttribute("data-agent-native-soft-chrome") === "true";
|
|
2569
|
+
overlay.style.borderWidth = (softChrome ? 1 : 1.5) * line + "px";
|
|
2544
2570
|
overlay
|
|
2545
2571
|
.querySelectorAll(
|
|
2546
2572
|
"[data-agent-native-edit-overlay='multi-selection-handle']",
|
|
@@ -2557,7 +2583,10 @@ declare var __LIVE_REFLOW_ENABLED__: boolean;
|
|
|
2557
2583
|
});
|
|
2558
2584
|
}
|
|
2559
2585
|
|
|
2560
|
-
function setPassiveSelectionElements(
|
|
2586
|
+
function setPassiveSelectionElements(
|
|
2587
|
+
elements: Element[],
|
|
2588
|
+
style: "default" | "soft" = "default",
|
|
2589
|
+
): void {
|
|
2561
2590
|
passiveSelectionEls = elements.filter(function (el, index, all) {
|
|
2562
2591
|
return (
|
|
2563
2592
|
el &&
|
|
@@ -2568,7 +2597,7 @@ declare var __LIVE_REFLOW_ENABLED__: boolean;
|
|
|
2568
2597
|
});
|
|
2569
2598
|
removePassiveSelectionOverlays();
|
|
2570
2599
|
passiveSelectionEls.forEach(function (el) {
|
|
2571
|
-
var overlay = makePassiveSelectionOverlay();
|
|
2600
|
+
var overlay = makePassiveSelectionOverlay(style);
|
|
2572
2601
|
passiveSelectionOverlays.push(overlay);
|
|
2573
2602
|
positionOverlay(overlay, el);
|
|
2574
2603
|
});
|
|
@@ -3939,11 +3968,10 @@ declare var __LIVE_REFLOW_ENABLED__: boolean;
|
|
|
3939
3968
|
var sx = chromeScaleX();
|
|
3940
3969
|
var sy = chromeScaleY();
|
|
3941
3970
|
var line = chromeLineScale();
|
|
3942
|
-
//
|
|
3943
|
-
//
|
|
3944
|
-
|
|
3945
|
-
|
|
3946
|
-
highlightOverlay.style.borderWidth = 1 * line + "px";
|
|
3971
|
+
// Keep hover and the corresponding selection outline visually identical.
|
|
3972
|
+
// Soft responsive peers intentionally use the lighter outline treatment.
|
|
3973
|
+
highlightOverlay.style.borderWidth =
|
|
3974
|
+
(highlightOverlayStyle === "soft" ? 1 : 1.5) * line + "px";
|
|
3947
3975
|
parentAutoLayoutOverlay.style.borderWidth = 1 * line + "px";
|
|
3948
3976
|
selectionOverlay.style.borderWidth = 1.5 * line + "px";
|
|
3949
3977
|
marqueeSelectionOverlay.style.borderWidth = 1 * line + "px";
|
|
@@ -6046,6 +6074,7 @@ declare var __LIVE_REFLOW_ENABLED__: boolean;
|
|
|
6046
6074
|
}
|
|
6047
6075
|
|
|
6048
6076
|
function startSpacingDrag(key, e) {
|
|
6077
|
+
if (readOnly) return;
|
|
6049
6078
|
if (spacingDrag) {
|
|
6050
6079
|
stopNativeInteraction(e);
|
|
6051
6080
|
return;
|
|
@@ -8374,6 +8403,7 @@ declare var __LIVE_REFLOW_ENABLED__: boolean;
|
|
|
8374
8403
|
gestureElParam?: Element,
|
|
8375
8404
|
pointerStartParam?: { clientX: number; clientY: number },
|
|
8376
8405
|
) {
|
|
8406
|
+
if (readOnly) return;
|
|
8377
8407
|
var gestureEl = gestureElParam || selectedEl;
|
|
8378
8408
|
if (!gestureEl) return;
|
|
8379
8409
|
if (isLayerInteractionBlocked(gestureEl)) return;
|
|
@@ -9546,6 +9576,7 @@ declare var __LIVE_REFLOW_ENABLED__: boolean;
|
|
|
9546
9576
|
}
|
|
9547
9577
|
|
|
9548
9578
|
function startResize(handle, e) {
|
|
9579
|
+
if (readOnly) return;
|
|
9549
9580
|
if (!selectedEl) return;
|
|
9550
9581
|
if (isLayerInteractionBlocked(selectedEl)) return;
|
|
9551
9582
|
e.preventDefault();
|
|
@@ -9834,6 +9865,7 @@ declare var __LIVE_REFLOW_ENABLED__: boolean;
|
|
|
9834
9865
|
}
|
|
9835
9866
|
|
|
9836
9867
|
function startRotate(e) {
|
|
9868
|
+
if (readOnly) return;
|
|
9837
9869
|
if (!selectedEl) return;
|
|
9838
9870
|
if (isLayerInteractionBlocked(selectedEl)) return;
|
|
9839
9871
|
e.preventDefault();
|
|
@@ -9980,7 +10012,7 @@ declare var __LIVE_REFLOW_ENABLED__: boolean;
|
|
|
9980
10012
|
shieldOverlay.setPointerCapture(e.pointerId);
|
|
9981
10013
|
} catch (_err) {}
|
|
9982
10014
|
}
|
|
9983
|
-
if (!e.altKey) {
|
|
10015
|
+
if (!readOnly && !e.altKey) {
|
|
9984
10016
|
postCrossScreenDrag("start", dragTarget, e);
|
|
9985
10017
|
}
|
|
9986
10018
|
var startX = e.clientX;
|
|
@@ -10006,6 +10038,7 @@ declare var __LIVE_REFLOW_ENABLED__: boolean;
|
|
|
10006
10038
|
postElementSelect(selectedEl, ev);
|
|
10007
10039
|
}
|
|
10008
10040
|
function onMove(ev) {
|
|
10041
|
+
if (readOnly) return;
|
|
10009
10042
|
if (Math.hypot(ev.clientX - startX, ev.clientY - startY) <= 3) return;
|
|
10010
10043
|
clearPendingShieldDrag();
|
|
10011
10044
|
didStartDrag = true;
|
|
@@ -10036,7 +10069,7 @@ declare var __LIVE_REFLOW_ENABLED__: boolean;
|
|
|
10036
10069
|
function onUp(ev) {
|
|
10037
10070
|
clearPendingShieldDrag();
|
|
10038
10071
|
if (didStartDrag) return;
|
|
10039
|
-
if (!e.altKey) {
|
|
10072
|
+
if (!readOnly && !e.altKey) {
|
|
10040
10073
|
postCrossScreenDrag("cancel");
|
|
10041
10074
|
}
|
|
10042
10075
|
if (ev) stopNativeInteraction(ev);
|
|
@@ -10058,6 +10091,7 @@ declare var __LIVE_REFLOW_ENABLED__: boolean;
|
|
|
10058
10091
|
selectionOverlay.addEventListener(
|
|
10059
10092
|
"mousedown",
|
|
10060
10093
|
function (e) {
|
|
10094
|
+
if (readOnly) return;
|
|
10061
10095
|
var spacingKey =
|
|
10062
10096
|
e.target &&
|
|
10063
10097
|
e.target.getAttribute &&
|
|
@@ -11164,9 +11198,13 @@ declare var __LIVE_REFLOW_ENABLED__: boolean;
|
|
|
11164
11198
|
if (activeTextEditEl) {
|
|
11165
11199
|
activeTextEditEl.blur();
|
|
11166
11200
|
}
|
|
11167
|
-
|
|
11168
|
-
|
|
11201
|
+
clearPendingShieldDrag();
|
|
11202
|
+
cancelActiveBridgeDrag();
|
|
11203
|
+
setSelectionOverlayResizeChromeVisible(false);
|
|
11204
|
+
// Keep the shield active so the viewer can select and inspect layers.
|
|
11205
|
+
shieldOverlay.style.pointerEvents = "auto";
|
|
11169
11206
|
} else {
|
|
11207
|
+
setSelectionOverlayResizeChromeVisible(true);
|
|
11170
11208
|
shieldOverlay.style.pointerEvents = "auto";
|
|
11171
11209
|
}
|
|
11172
11210
|
return;
|
|
@@ -11504,7 +11542,13 @@ declare var __LIVE_REFLOW_ENABLED__: boolean;
|
|
|
11504
11542
|
} catch (_err) {}
|
|
11505
11543
|
}
|
|
11506
11544
|
});
|
|
11507
|
-
setPassiveSelectionElements(
|
|
11545
|
+
setPassiveSelectionElements(
|
|
11546
|
+
passiveTargets,
|
|
11547
|
+
e.data.passiveSelectionStyle === "soft" ? "soft" : "default",
|
|
11548
|
+
);
|
|
11549
|
+
setHighlightOverlayStyle(
|
|
11550
|
+
e.data.passiveSelectionStyle === "soft" ? "soft" : "default",
|
|
11551
|
+
);
|
|
11508
11552
|
return;
|
|
11509
11553
|
}
|
|
11510
11554
|
if (e.data.type === "select-element") {
|
|
@@ -11579,6 +11623,9 @@ declare var __LIVE_REFLOW_ENABLED__: boolean;
|
|
|
11579
11623
|
return;
|
|
11580
11624
|
}
|
|
11581
11625
|
if (e.data.type === "hover-element") {
|
|
11626
|
+
if (e.data.hoverStyle === "soft" || e.data.hoverStyle === "default") {
|
|
11627
|
+
setHighlightOverlayStyle(e.data.hoverStyle);
|
|
11628
|
+
}
|
|
11582
11629
|
var hoverCandidates: string[] = [];
|
|
11583
11630
|
if (Array.isArray(e.data.selectorCandidates)) {
|
|
11584
11631
|
e.data.selectorCandidates.forEach(function (selector) {
|
|
@@ -137,6 +137,8 @@ export interface MultiScreenCanvasProps {
|
|
|
137
137
|
/** Lets every live frame receive native pointer interaction while the
|
|
138
138
|
* overview camera and frame chrome remain available. */
|
|
139
139
|
interactMode?: boolean;
|
|
140
|
+
/** Viewer mode keeps selection/inspection available without edit chrome. */
|
|
141
|
+
readOnly?: boolean;
|
|
140
142
|
activeScreenHasHoveredChild?: boolean;
|
|
141
143
|
hoveredChildScreenId?: string | null;
|
|
142
144
|
directlyHoveredScreenId?: string | null;
|
|
@@ -8,7 +8,7 @@ import {
|
|
|
8
8
|
IconPencil,
|
|
9
9
|
IconTemplate,
|
|
10
10
|
IconPalette,
|
|
11
|
-
|
|
11
|
+
IconHierarchy2,
|
|
12
12
|
IconSettings,
|
|
13
13
|
IconLayoutSidebarLeftCollapse,
|
|
14
14
|
IconLayoutSidebarLeftExpand,
|
|
@@ -32,7 +32,7 @@ const navItems = [
|
|
|
32
32
|
labelKey: "navigation.designSystems",
|
|
33
33
|
href: "/design-systems",
|
|
34
34
|
},
|
|
35
|
-
{ icon:
|
|
35
|
+
{ icon: IconHierarchy2, labelKey: "navigation.agent", href: "/agent" },
|
|
36
36
|
{ icon: IconSettings, labelKey: "navigation.settings", href: "/settings" },
|
|
37
37
|
];
|
|
38
38
|
|
|
@@ -12,8 +12,8 @@ export interface NavigationState {
|
|
|
12
12
|
designSystemId?: string;
|
|
13
13
|
templateId?: string;
|
|
14
14
|
editorView?: "single" | "overview";
|
|
15
|
-
inspectorTab?: "design" | "comments" | "tweaks" | "extensions";
|
|
16
|
-
inspector?: "design" | "comments" | "tweaks" | "extensions";
|
|
15
|
+
inspectorTab?: "design" | "comments" | "tweaks" | "code" | "extensions";
|
|
16
|
+
inspector?: "design" | "comments" | "tweaks" | "code" | "extensions";
|
|
17
17
|
leftPanel?:
|
|
18
18
|
| "file"
|
|
19
19
|
| "agent"
|
|
@@ -54,8 +54,8 @@ export interface DesignEditorCommand {
|
|
|
54
54
|
designId: string;
|
|
55
55
|
editorView?: "single" | "overview";
|
|
56
56
|
viewMode?: "single" | "overview";
|
|
57
|
-
inspectorTab?: "design" | "comments" | "tweaks" | "extensions";
|
|
58
|
-
inspector?: "design" | "comments" | "tweaks" | "extensions";
|
|
57
|
+
inspectorTab?: "design" | "comments" | "tweaks" | "code" | "extensions";
|
|
58
|
+
inspector?: "design" | "comments" | "tweaks" | "code" | "extensions";
|
|
59
59
|
leftPanel?:
|
|
60
60
|
| "file"
|
|
61
61
|
| "agent"
|
|
@@ -118,10 +118,11 @@ function normalizeEditorView(
|
|
|
118
118
|
|
|
119
119
|
function normalizeInspectorTab(
|
|
120
120
|
value: unknown,
|
|
121
|
-
): "design" | "comments" | "tweaks" | "extensions" | undefined {
|
|
121
|
+
): "design" | "comments" | "tweaks" | "code" | "extensions" | undefined {
|
|
122
122
|
return value === "design" ||
|
|
123
123
|
value === "comments" ||
|
|
124
124
|
value === "tweaks" ||
|
|
125
|
+
value === "code" ||
|
|
125
126
|
value === "extensions"
|
|
126
127
|
? value
|
|
127
128
|
: undefined;
|
|
@@ -13,7 +13,7 @@ import {
|
|
|
13
13
|
useCommandMenuShortcut,
|
|
14
14
|
} from "@agent-native/core/client/navigation";
|
|
15
15
|
import { getThemeInitScript } from "@agent-native/core/client/ui";
|
|
16
|
-
import {
|
|
16
|
+
import { IconHierarchy2, IconSun, IconMoon } from "@tabler/icons-react";
|
|
17
17
|
import { useQueryClient } from "@tanstack/react-query";
|
|
18
18
|
import { useTheme } from "next-themes";
|
|
19
19
|
import { useCallback, useState } from "react";
|
|
@@ -138,7 +138,7 @@ function DesignCommandMenu({
|
|
|
138
138
|
>
|
|
139
139
|
<CommandMenu.Group heading={t("root.commandActions")}>
|
|
140
140
|
<CommandMenu.Item onSelect={() => navigate("/agent")}>
|
|
141
|
-
<
|
|
141
|
+
<IconHierarchy2 size={16} />
|
|
142
142
|
{t("root.openAgent")}
|
|
143
143
|
</CommandMenu.Item>
|
|
144
144
|
<CommandMenu.Item onSelect={() => {}}>
|
|
@@ -24,6 +24,10 @@ registerShareableResource({
|
|
|
24
24
|
},
|
|
25
25
|
getDb,
|
|
26
26
|
publicAccessRole: publicDesignAccessRole,
|
|
27
|
+
// A design remains owned by its creator when they switch active orgs. The
|
|
28
|
+
// design URL and owner identity are the authority for this resource; org
|
|
29
|
+
// membership still scopes org visibility and explicit shares.
|
|
30
|
+
ownerAccessIgnoresOrg: true,
|
|
27
31
|
});
|
|
28
32
|
|
|
29
33
|
registerShareableResource({
|
|
@@ -59,6 +59,12 @@ quick controls and deep links such as:
|
|
|
59
59
|
- `/settings/usage`
|
|
60
60
|
- `/settings/apps/:appId`
|
|
61
61
|
|
|
62
|
+
The shared Account section is the canonical profile surface at
|
|
63
|
+
`/settings#account`. It owns the editable display name and existing avatar
|
|
64
|
+
control through the authenticated `get-user-profile` and `update-user-profile`
|
|
65
|
+
actions. Shared workspace chrome such as `OrgSwitcher` should link to this
|
|
66
|
+
surface rather than creating an app-local profile page.
|
|
67
|
+
|
|
62
68
|
When adding a new API key, OAuth grant, provider connection, model selector, app
|
|
63
69
|
preference, notification preference, or usage/billing surface, register it as a
|
|
64
70
|
settings tab or app settings panel first. Only add sidebar UI when it is needed
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { DispatchExtensionConfig } from "@agent-native/dispatch/components";
|
|
2
|
-
import {
|
|
2
|
+
import { IconHierarchy2 } from "@tabler/icons-react";
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* Local Dispatch extensions for this generated workspace.
|
|
@@ -31,7 +31,7 @@ export const dispatchExtensions = {
|
|
|
31
31
|
id: "agent",
|
|
32
32
|
to: "/agent",
|
|
33
33
|
label: "Agent",
|
|
34
|
-
icon:
|
|
34
|
+
icon: IconHierarchy2,
|
|
35
35
|
section: "operations",
|
|
36
36
|
},
|
|
37
37
|
],
|
|
@@ -12,7 +12,7 @@ import {
|
|
|
12
12
|
} from "@agent-native/core/client/navigation";
|
|
13
13
|
import { getThemeInitScript } from "@agent-native/core/client/ui";
|
|
14
14
|
import { Layout as AppLayout } from "@agent-native/dispatch/components";
|
|
15
|
-
import {
|
|
15
|
+
import { IconHierarchy2, IconSun, IconMoon } from "@tabler/icons-react";
|
|
16
16
|
import { useQueryClient } from "@tanstack/react-query";
|
|
17
17
|
import { useTheme } from "next-themes";
|
|
18
18
|
import { useCallback, useEffect, useRef, useState } from "react";
|
|
@@ -191,7 +191,7 @@ function AppContent() {
|
|
|
191
191
|
>
|
|
192
192
|
<CommandMenu.Group heading={t("root.commandActions")}>
|
|
193
193
|
<CommandMenu.Item onSelect={() => navigate("/agent")}>
|
|
194
|
-
<
|
|
194
|
+
<IconHierarchy2 size={16} />
|
|
195
195
|
{t("root.openAgent")}
|
|
196
196
|
</CommandMenu.Item>
|
|
197
197
|
<CommandMenu.Item onSelect={() => {}}>
|
|
@@ -59,6 +59,12 @@ quick controls and deep links such as:
|
|
|
59
59
|
- `/settings/usage`
|
|
60
60
|
- `/settings/apps/:appId`
|
|
61
61
|
|
|
62
|
+
The shared Account section is the canonical profile surface at
|
|
63
|
+
`/settings#account`. It owns the editable display name and existing avatar
|
|
64
|
+
control through the authenticated `get-user-profile` and `update-user-profile`
|
|
65
|
+
actions. Shared workspace chrome such as `OrgSwitcher` should link to this
|
|
66
|
+
surface rather than creating an app-local profile page.
|
|
67
|
+
|
|
62
68
|
When adding a new API key, OAuth grant, provider connection, model selector, app
|
|
63
69
|
preference, notification preference, or usage/billing surface, register it as a
|
|
64
70
|
settings tab or app settings panel first. Only add sidebar UI when it is needed
|
|
@@ -40,7 +40,7 @@ export function Layout({ children }: LayoutProps) {
|
|
|
40
40
|
useAgentChatHomeHandoffLinks({
|
|
41
41
|
storageKey: "forms",
|
|
42
42
|
chatPath: "/ask",
|
|
43
|
-
requireActiveHandoff:
|
|
43
|
+
requireActiveHandoff: true,
|
|
44
44
|
});
|
|
45
45
|
|
|
46
46
|
// Bind chat to the currently-open form. The `/forms/:id` URL covers
|
|
@@ -16,7 +16,7 @@ import {
|
|
|
16
16
|
IconMenu2,
|
|
17
17
|
IconX,
|
|
18
18
|
IconMessageCircle,
|
|
19
|
-
|
|
19
|
+
IconHierarchy2,
|
|
20
20
|
IconSettings,
|
|
21
21
|
IconForms,
|
|
22
22
|
IconLayoutSidebarLeftCollapse,
|
|
@@ -289,7 +289,7 @@ export function Sidebar() {
|
|
|
289
289
|
: "text-muted-foreground hover:bg-accent/50 hover:text-foreground",
|
|
290
290
|
)}
|
|
291
291
|
>
|
|
292
|
-
<
|
|
292
|
+
<IconHierarchy2 className="h-4 w-4" />
|
|
293
293
|
</Link>
|
|
294
294
|
</TooltipTrigger>
|
|
295
295
|
<TooltipContent side="right">
|
|
@@ -445,7 +445,7 @@ export function Sidebar() {
|
|
|
445
445
|
: "text-muted-foreground hover:bg-accent/50 hover:text-foreground",
|
|
446
446
|
)}
|
|
447
447
|
>
|
|
448
|
-
<
|
|
448
|
+
<IconHierarchy2 size={14} className="shrink-0" />
|
|
449
449
|
<span>{t("navigation.agent")}</span>
|
|
450
450
|
</Link>
|
|
451
451
|
|
|
@@ -3,9 +3,19 @@ import {
|
|
|
3
3
|
useActionQuery,
|
|
4
4
|
useActionMutation,
|
|
5
5
|
} from "@agent-native/core/client/hooks";
|
|
6
|
+
import { useT } from "@agent-native/core/client/i18n";
|
|
6
7
|
import { useQuery, useMutation, useQueryClient } from "@tanstack/react-query";
|
|
7
8
|
import { toast } from "sonner";
|
|
8
9
|
|
|
10
|
+
type FormListItem = { id: string; [key: string]: unknown };
|
|
11
|
+
type FormListMutationContext = {
|
|
12
|
+
removed: Array<{
|
|
13
|
+
queryKey: readonly unknown[];
|
|
14
|
+
form: FormListItem;
|
|
15
|
+
index: number;
|
|
16
|
+
}>;
|
|
17
|
+
};
|
|
18
|
+
|
|
9
19
|
// ---------------------------------------------------------------------------
|
|
10
20
|
// Admin hooks (authenticated)
|
|
11
21
|
// ---------------------------------------------------------------------------
|
|
@@ -76,13 +86,56 @@ export function usePatchFormFields() {
|
|
|
76
86
|
|
|
77
87
|
export function useDeleteForm() {
|
|
78
88
|
const qc = useQueryClient();
|
|
89
|
+
const t = useT();
|
|
79
90
|
return useActionMutation("delete-form", {
|
|
91
|
+
onMutate: async (variables) => {
|
|
92
|
+
if (variables.purge) return undefined;
|
|
93
|
+
|
|
94
|
+
const activeListFilter = {
|
|
95
|
+
queryKey: ["action", "list-forms"],
|
|
96
|
+
predicate: (query: { queryKey: readonly unknown[] }) => {
|
|
97
|
+
const params = query.queryKey[2];
|
|
98
|
+
return !(
|
|
99
|
+
params &&
|
|
100
|
+
typeof params === "object" &&
|
|
101
|
+
(params as { archived?: boolean }).archived === true
|
|
102
|
+
);
|
|
103
|
+
},
|
|
104
|
+
} as const;
|
|
105
|
+
|
|
106
|
+
await qc.cancelQueries(activeListFilter);
|
|
107
|
+
const previous = qc.getQueriesData<FormListItem[]>(activeListFilter);
|
|
108
|
+
const removed: FormListMutationContext["removed"] = [];
|
|
109
|
+
for (const [queryKey, data] of previous) {
|
|
110
|
+
const index = data?.findIndex((form) => form.id === variables.id) ?? -1;
|
|
111
|
+
const form = index >= 0 ? data?.[index] : undefined;
|
|
112
|
+
if (form) removed.push({ queryKey, form, index });
|
|
113
|
+
qc.setQueryData<FormListItem[]>(queryKey, (old) =>
|
|
114
|
+
old?.filter((form) => form.id !== variables.id),
|
|
115
|
+
);
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
return { removed } satisfies FormListMutationContext;
|
|
119
|
+
},
|
|
80
120
|
onSuccess: () => {
|
|
81
121
|
qc.invalidateQueries({ queryKey: ["action", "list-forms"] });
|
|
82
122
|
qc.invalidateQueries({ queryKey: ["action", "get-form"] });
|
|
83
123
|
},
|
|
84
|
-
onError: () => {
|
|
85
|
-
|
|
124
|
+
onError: (_error, variables, context) => {
|
|
125
|
+
const mutationContext = context as FormListMutationContext | undefined;
|
|
126
|
+
for (const { queryKey, form, index } of mutationContext?.removed ?? []) {
|
|
127
|
+
qc.setQueryData<FormListItem[]>(queryKey, (old) => {
|
|
128
|
+
if (!old || old.some((item) => item.id === form.id)) return old;
|
|
129
|
+
const next = [...old];
|
|
130
|
+
next.splice(Math.min(index, next.length), 0, form);
|
|
131
|
+
return next;
|
|
132
|
+
});
|
|
133
|
+
}
|
|
134
|
+
if (variables.purge) {
|
|
135
|
+
toast.error("Failed to delete form");
|
|
136
|
+
} else if (!mutationContext?.removed.length) {
|
|
137
|
+
toast.error(t("forms.archiveFailed"));
|
|
138
|
+
}
|
|
86
139
|
},
|
|
87
140
|
});
|
|
88
141
|
}
|
|
@@ -259,6 +259,8 @@ const messages = {
|
|
|
259
259
|
duplicated: "Form duplicated",
|
|
260
260
|
duplicateFailed: "Failed to duplicate form",
|
|
261
261
|
movedToArchive: "Form moved to Archive",
|
|
262
|
+
movingToArchive: "Moving form to Archive…",
|
|
263
|
+
archiveFailed: "Failed to move form to Archive",
|
|
262
264
|
restored: "Form restored",
|
|
263
265
|
permanentlyDeleted: "Form permanently deleted",
|
|
264
266
|
bulkPermanentlyDeleted: "{{formattedCount}} forms permanently deleted",
|