@agent-native/core 0.109.4 → 0.110.1
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 +1 -1
- package/corpus/core/CHANGELOG.md +17 -0
- package/corpus/core/docs/content/actions.mdx +2 -4
- package/corpus/core/docs/content/agent-surfaces.mdx +2 -4
- package/corpus/core/docs/content/audit-log.mdx +1 -2
- package/corpus/core/docs/content/authentication.mdx +3 -2
- package/corpus/core/docs/content/client.mdx +19 -18
- package/corpus/core/docs/content/components.mdx +1 -1
- package/corpus/core/docs/content/context-awareness.mdx +4 -7
- package/corpus/core/docs/content/creating-templates.mdx +7 -5
- package/corpus/core/docs/content/doctor.mdx +27 -6
- package/corpus/core/docs/content/drop-in-agent.mdx +6 -11
- package/corpus/core/docs/content/embedding-sdk.mdx +8 -10
- package/corpus/core/docs/content/getting-started.mdx +4 -2
- package/corpus/core/docs/content/internationalization.mdx +9 -6
- package/corpus/core/docs/content/key-concepts.mdx +2 -4
- package/corpus/core/docs/content/locales/ar-SA/actions.mdx +2 -4
- package/corpus/core/docs/content/locales/ar-SA/agent-surfaces.mdx +2 -4
- package/corpus/core/docs/content/locales/ar-SA/audit-log.mdx +1 -2
- package/corpus/core/docs/content/locales/ar-SA/authentication.mdx +3 -2
- package/corpus/core/docs/content/locales/ar-SA/client.mdx +19 -18
- package/corpus/core/docs/content/locales/ar-SA/components.mdx +1 -1
- package/corpus/core/docs/content/locales/ar-SA/context-awareness.mdx +4 -7
- package/corpus/core/docs/content/locales/ar-SA/creating-templates.mdx +7 -5
- package/corpus/core/docs/content/locales/ar-SA/doctor.mdx +10 -0
- package/corpus/core/docs/content/locales/ar-SA/drop-in-agent.mdx +6 -11
- package/corpus/core/docs/content/locales/ar-SA/embedding-sdk.mdx +8 -10
- package/corpus/core/docs/content/locales/ar-SA/internationalization.mdx +9 -6
- package/corpus/core/docs/content/locales/ar-SA/key-concepts.mdx +2 -4
- package/corpus/core/docs/content/locales/ar-SA/observability.mdx +1 -2
- package/corpus/core/docs/content/locales/ar-SA/package-lifecycle.mdx +6 -0
- package/corpus/core/docs/content/locales/ar-SA/real-time-collaboration.mdx +4 -7
- package/corpus/core/docs/content/locales/ar-SA/sharing.mdx +1 -2
- package/corpus/core/docs/content/locales/ar-SA/template-chat.mdx +1 -2
- package/corpus/core/docs/content/locales/ar-SA/tracking.mdx +2 -4
- package/corpus/core/docs/content/locales/ar-SA/what-is-agent-native.mdx +1 -2
- package/corpus/core/docs/content/locales/de-DE/actions.mdx +2 -4
- package/corpus/core/docs/content/locales/de-DE/agent-surfaces.mdx +2 -4
- package/corpus/core/docs/content/locales/de-DE/audit-log.mdx +1 -2
- package/corpus/core/docs/content/locales/de-DE/authentication.mdx +3 -2
- package/corpus/core/docs/content/locales/de-DE/client.mdx +19 -18
- package/corpus/core/docs/content/locales/de-DE/components.mdx +1 -1
- package/corpus/core/docs/content/locales/de-DE/context-awareness.mdx +4 -7
- package/corpus/core/docs/content/locales/de-DE/creating-templates.mdx +7 -5
- package/corpus/core/docs/content/locales/de-DE/doctor.mdx +10 -0
- package/corpus/core/docs/content/locales/de-DE/drop-in-agent.mdx +6 -11
- package/corpus/core/docs/content/locales/de-DE/embedding-sdk.mdx +8 -10
- package/corpus/core/docs/content/locales/de-DE/internationalization.mdx +9 -6
- package/corpus/core/docs/content/locales/de-DE/key-concepts.mdx +2 -4
- package/corpus/core/docs/content/locales/de-DE/observability.mdx +1 -2
- package/corpus/core/docs/content/locales/de-DE/package-lifecycle.mdx +6 -0
- package/corpus/core/docs/content/locales/de-DE/real-time-collaboration.mdx +4 -7
- package/corpus/core/docs/content/locales/de-DE/sharing.mdx +1 -2
- package/corpus/core/docs/content/locales/de-DE/template-chat.mdx +1 -2
- package/corpus/core/docs/content/locales/de-DE/tracking.mdx +2 -4
- package/corpus/core/docs/content/locales/de-DE/what-is-agent-native.mdx +1 -2
- package/corpus/core/docs/content/locales/es-ES/actions.mdx +2 -4
- package/corpus/core/docs/content/locales/es-ES/agent-surfaces.mdx +2 -4
- package/corpus/core/docs/content/locales/es-ES/audit-log.mdx +1 -2
- package/corpus/core/docs/content/locales/es-ES/authentication.mdx +3 -2
- package/corpus/core/docs/content/locales/es-ES/client.mdx +19 -18
- package/corpus/core/docs/content/locales/es-ES/components.mdx +1 -1
- package/corpus/core/docs/content/locales/es-ES/context-awareness.mdx +4 -7
- package/corpus/core/docs/content/locales/es-ES/creating-templates.mdx +7 -5
- package/corpus/core/docs/content/locales/es-ES/doctor.mdx +10 -0
- package/corpus/core/docs/content/locales/es-ES/drop-in-agent.mdx +6 -11
- package/corpus/core/docs/content/locales/es-ES/embedding-sdk.mdx +8 -10
- package/corpus/core/docs/content/locales/es-ES/internationalization.mdx +9 -6
- package/corpus/core/docs/content/locales/es-ES/key-concepts.mdx +2 -4
- package/corpus/core/docs/content/locales/es-ES/observability.mdx +1 -2
- package/corpus/core/docs/content/locales/es-ES/package-lifecycle.mdx +6 -0
- package/corpus/core/docs/content/locales/es-ES/real-time-collaboration.mdx +4 -7
- package/corpus/core/docs/content/locales/es-ES/sharing.mdx +1 -2
- package/corpus/core/docs/content/locales/es-ES/template-chat.mdx +1 -2
- package/corpus/core/docs/content/locales/es-ES/tracking.mdx +2 -4
- package/corpus/core/docs/content/locales/es-ES/what-is-agent-native.mdx +1 -2
- package/corpus/core/docs/content/locales/fr-FR/actions.mdx +2 -4
- package/corpus/core/docs/content/locales/fr-FR/agent-surfaces.mdx +2 -4
- package/corpus/core/docs/content/locales/fr-FR/audit-log.mdx +1 -2
- package/corpus/core/docs/content/locales/fr-FR/authentication.mdx +3 -2
- package/corpus/core/docs/content/locales/fr-FR/client.mdx +19 -18
- package/corpus/core/docs/content/locales/fr-FR/components.mdx +1 -1
- package/corpus/core/docs/content/locales/fr-FR/context-awareness.mdx +4 -7
- package/corpus/core/docs/content/locales/fr-FR/creating-templates.mdx +7 -5
- package/corpus/core/docs/content/locales/fr-FR/doctor.mdx +10 -0
- package/corpus/core/docs/content/locales/fr-FR/drop-in-agent.mdx +6 -11
- package/corpus/core/docs/content/locales/fr-FR/embedding-sdk.mdx +8 -10
- package/corpus/core/docs/content/locales/fr-FR/internationalization.mdx +9 -6
- package/corpus/core/docs/content/locales/fr-FR/key-concepts.mdx +2 -4
- package/corpus/core/docs/content/locales/fr-FR/observability.mdx +1 -2
- package/corpus/core/docs/content/locales/fr-FR/package-lifecycle.mdx +6 -0
- package/corpus/core/docs/content/locales/fr-FR/real-time-collaboration.mdx +4 -7
- package/corpus/core/docs/content/locales/fr-FR/sharing.mdx +1 -2
- package/corpus/core/docs/content/locales/fr-FR/template-chat.mdx +1 -2
- package/corpus/core/docs/content/locales/fr-FR/tracking.mdx +2 -4
- package/corpus/core/docs/content/locales/fr-FR/what-is-agent-native.mdx +1 -2
- package/corpus/core/docs/content/locales/hi-IN/actions.mdx +2 -4
- package/corpus/core/docs/content/locales/hi-IN/agent-surfaces.mdx +2 -4
- package/corpus/core/docs/content/locales/hi-IN/audit-log.mdx +1 -2
- package/corpus/core/docs/content/locales/hi-IN/authentication.mdx +3 -2
- package/corpus/core/docs/content/locales/hi-IN/client.mdx +19 -18
- package/corpus/core/docs/content/locales/hi-IN/components.mdx +1 -1
- package/corpus/core/docs/content/locales/hi-IN/context-awareness.mdx +4 -7
- package/corpus/core/docs/content/locales/hi-IN/creating-templates.mdx +7 -5
- package/corpus/core/docs/content/locales/hi-IN/doctor.mdx +10 -0
- package/corpus/core/docs/content/locales/hi-IN/drop-in-agent.mdx +6 -11
- package/corpus/core/docs/content/locales/hi-IN/embedding-sdk.mdx +8 -10
- package/corpus/core/docs/content/locales/hi-IN/internationalization.mdx +9 -6
- package/corpus/core/docs/content/locales/hi-IN/key-concepts.mdx +2 -4
- package/corpus/core/docs/content/locales/hi-IN/observability.mdx +1 -2
- package/corpus/core/docs/content/locales/hi-IN/package-lifecycle.mdx +6 -0
- package/corpus/core/docs/content/locales/hi-IN/real-time-collaboration.mdx +4 -7
- package/corpus/core/docs/content/locales/hi-IN/sharing.mdx +1 -2
- package/corpus/core/docs/content/locales/hi-IN/template-chat.mdx +1 -2
- package/corpus/core/docs/content/locales/hi-IN/tracking.mdx +2 -4
- package/corpus/core/docs/content/locales/hi-IN/what-is-agent-native.mdx +1 -2
- package/corpus/core/docs/content/locales/ja-JP/actions.mdx +2 -4
- package/corpus/core/docs/content/locales/ja-JP/agent-surfaces.mdx +2 -4
- package/corpus/core/docs/content/locales/ja-JP/audit-log.mdx +1 -2
- package/corpus/core/docs/content/locales/ja-JP/authentication.mdx +3 -2
- package/corpus/core/docs/content/locales/ja-JP/client.mdx +19 -18
- package/corpus/core/docs/content/locales/ja-JP/components.mdx +1 -1
- package/corpus/core/docs/content/locales/ja-JP/context-awareness.mdx +4 -7
- package/corpus/core/docs/content/locales/ja-JP/creating-templates.mdx +7 -5
- package/corpus/core/docs/content/locales/ja-JP/doctor.mdx +10 -0
- package/corpus/core/docs/content/locales/ja-JP/drop-in-agent.mdx +6 -11
- package/corpus/core/docs/content/locales/ja-JP/embedding-sdk.mdx +8 -10
- package/corpus/core/docs/content/locales/ja-JP/internationalization.mdx +9 -6
- package/corpus/core/docs/content/locales/ja-JP/key-concepts.mdx +2 -4
- package/corpus/core/docs/content/locales/ja-JP/observability.mdx +1 -2
- package/corpus/core/docs/content/locales/ja-JP/package-lifecycle.mdx +6 -0
- package/corpus/core/docs/content/locales/ja-JP/real-time-collaboration.mdx +4 -7
- package/corpus/core/docs/content/locales/ja-JP/sharing.mdx +1 -2
- package/corpus/core/docs/content/locales/ja-JP/template-chat.mdx +1 -2
- package/corpus/core/docs/content/locales/ja-JP/tracking.mdx +2 -4
- package/corpus/core/docs/content/locales/ja-JP/what-is-agent-native.mdx +1 -2
- package/corpus/core/docs/content/locales/ko-KR/actions.mdx +2 -4
- package/corpus/core/docs/content/locales/ko-KR/agent-surfaces.mdx +2 -4
- package/corpus/core/docs/content/locales/ko-KR/audit-log.mdx +1 -2
- package/corpus/core/docs/content/locales/ko-KR/authentication.mdx +3 -2
- package/corpus/core/docs/content/locales/ko-KR/client.mdx +19 -18
- package/corpus/core/docs/content/locales/ko-KR/components.mdx +1 -1
- package/corpus/core/docs/content/locales/ko-KR/context-awareness.mdx +4 -7
- package/corpus/core/docs/content/locales/ko-KR/creating-templates.mdx +7 -5
- package/corpus/core/docs/content/locales/ko-KR/doctor.mdx +10 -0
- package/corpus/core/docs/content/locales/ko-KR/drop-in-agent.mdx +6 -11
- package/corpus/core/docs/content/locales/ko-KR/embedding-sdk.mdx +8 -10
- package/corpus/core/docs/content/locales/ko-KR/internationalization.mdx +9 -6
- package/corpus/core/docs/content/locales/ko-KR/key-concepts.mdx +2 -4
- package/corpus/core/docs/content/locales/ko-KR/observability.mdx +1 -2
- package/corpus/core/docs/content/locales/ko-KR/package-lifecycle.mdx +6 -0
- package/corpus/core/docs/content/locales/ko-KR/real-time-collaboration.mdx +4 -7
- package/corpus/core/docs/content/locales/ko-KR/sharing.mdx +1 -2
- package/corpus/core/docs/content/locales/ko-KR/template-chat.mdx +1 -2
- package/corpus/core/docs/content/locales/ko-KR/tracking.mdx +2 -4
- package/corpus/core/docs/content/locales/ko-KR/what-is-agent-native.mdx +1 -2
- package/corpus/core/docs/content/locales/pt-BR/actions.mdx +2 -4
- package/corpus/core/docs/content/locales/pt-BR/agent-surfaces.mdx +2 -4
- package/corpus/core/docs/content/locales/pt-BR/audit-log.mdx +1 -2
- package/corpus/core/docs/content/locales/pt-BR/authentication.mdx +3 -2
- package/corpus/core/docs/content/locales/pt-BR/client.mdx +19 -18
- package/corpus/core/docs/content/locales/pt-BR/components.mdx +1 -1
- package/corpus/core/docs/content/locales/pt-BR/context-awareness.mdx +4 -7
- package/corpus/core/docs/content/locales/pt-BR/creating-templates.mdx +7 -5
- package/corpus/core/docs/content/locales/pt-BR/doctor.mdx +10 -0
- package/corpus/core/docs/content/locales/pt-BR/drop-in-agent.mdx +6 -11
- package/corpus/core/docs/content/locales/pt-BR/embedding-sdk.mdx +8 -10
- package/corpus/core/docs/content/locales/pt-BR/internationalization.mdx +9 -6
- package/corpus/core/docs/content/locales/pt-BR/key-concepts.mdx +2 -4
- package/corpus/core/docs/content/locales/pt-BR/observability.mdx +1 -2
- package/corpus/core/docs/content/locales/pt-BR/package-lifecycle.mdx +6 -0
- package/corpus/core/docs/content/locales/pt-BR/real-time-collaboration.mdx +4 -7
- package/corpus/core/docs/content/locales/pt-BR/sharing.mdx +1 -2
- package/corpus/core/docs/content/locales/pt-BR/template-chat.mdx +1 -2
- package/corpus/core/docs/content/locales/pt-BR/tracking.mdx +2 -4
- package/corpus/core/docs/content/locales/pt-BR/what-is-agent-native.mdx +1 -2
- package/corpus/core/docs/content/locales/zh-CN/actions.mdx +2 -4
- package/corpus/core/docs/content/locales/zh-CN/agent-surfaces.mdx +2 -4
- package/corpus/core/docs/content/locales/zh-CN/audit-log.mdx +1 -2
- package/corpus/core/docs/content/locales/zh-CN/authentication.mdx +3 -2
- package/corpus/core/docs/content/locales/zh-CN/client.mdx +19 -18
- package/corpus/core/docs/content/locales/zh-CN/components.mdx +1 -1
- package/corpus/core/docs/content/locales/zh-CN/context-awareness.mdx +4 -7
- package/corpus/core/docs/content/locales/zh-CN/creating-templates.mdx +7 -5
- package/corpus/core/docs/content/locales/zh-CN/doctor.mdx +10 -0
- package/corpus/core/docs/content/locales/zh-CN/drop-in-agent.mdx +6 -11
- package/corpus/core/docs/content/locales/zh-CN/embedding-sdk.mdx +8 -10
- package/corpus/core/docs/content/locales/zh-CN/internationalization.mdx +9 -6
- package/corpus/core/docs/content/locales/zh-CN/key-concepts.mdx +2 -4
- package/corpus/core/docs/content/locales/zh-CN/observability.mdx +1 -2
- package/corpus/core/docs/content/locales/zh-CN/package-lifecycle.mdx +6 -0
- package/corpus/core/docs/content/locales/zh-CN/real-time-collaboration.mdx +4 -7
- package/corpus/core/docs/content/locales/zh-CN/sharing.mdx +1 -2
- package/corpus/core/docs/content/locales/zh-CN/template-chat.mdx +1 -2
- package/corpus/core/docs/content/locales/zh-CN/tracking.mdx +2 -4
- package/corpus/core/docs/content/locales/zh-CN/what-is-agent-native.mdx +1 -2
- package/corpus/core/docs/content/locales/zh-TW/actions.mdx +2 -4
- package/corpus/core/docs/content/locales/zh-TW/agent-surfaces.mdx +2 -4
- package/corpus/core/docs/content/locales/zh-TW/audit-log.mdx +1 -2
- package/corpus/core/docs/content/locales/zh-TW/authentication.mdx +3 -2
- package/corpus/core/docs/content/locales/zh-TW/client.mdx +19 -18
- package/corpus/core/docs/content/locales/zh-TW/components.mdx +1 -1
- package/corpus/core/docs/content/locales/zh-TW/context-awareness.mdx +4 -7
- package/corpus/core/docs/content/locales/zh-TW/creating-templates.mdx +7 -5
- package/corpus/core/docs/content/locales/zh-TW/doctor.mdx +10 -0
- package/corpus/core/docs/content/locales/zh-TW/drop-in-agent.mdx +6 -11
- package/corpus/core/docs/content/locales/zh-TW/embedding-sdk.mdx +8 -10
- package/corpus/core/docs/content/locales/zh-TW/internationalization.mdx +9 -6
- package/corpus/core/docs/content/locales/zh-TW/key-concepts.mdx +2 -4
- package/corpus/core/docs/content/locales/zh-TW/observability.mdx +1 -2
- package/corpus/core/docs/content/locales/zh-TW/package-lifecycle.mdx +6 -0
- package/corpus/core/docs/content/locales/zh-TW/real-time-collaboration.mdx +4 -7
- package/corpus/core/docs/content/locales/zh-TW/sharing.mdx +1 -2
- package/corpus/core/docs/content/locales/zh-TW/template-chat.mdx +1 -2
- package/corpus/core/docs/content/locales/zh-TW/tracking.mdx +2 -4
- package/corpus/core/docs/content/locales/zh-TW/what-is-agent-native.mdx +1 -2
- package/corpus/core/docs/content/observability.mdx +1 -2
- package/corpus/core/docs/content/package-lifecycle.mdx +29 -0
- package/corpus/core/docs/content/real-time-collaboration.mdx +8 -7
- package/corpus/core/docs/content/sharing.mdx +1 -2
- package/corpus/core/docs/content/template-chat.mdx +1 -2
- package/corpus/core/docs/content/toolkit-agent-ux.mdx +3 -2
- package/corpus/core/docs/content/toolkit-observability.mdx +1 -2
- package/corpus/core/docs/content/toolkit-settings.mdx +2 -2
- package/corpus/core/docs/content/toolkit-sharing.mdx +5 -2
- package/corpus/core/docs/content/tracking.mdx +2 -4
- package/corpus/core/docs/content/what-is-agent-native.mdx +1 -2
- package/corpus/core/export-snapshot.json +324 -0
- package/corpus/core/migration-manifest.json +1492 -0
- package/corpus/core/package.json +21 -3
- package/corpus/core/src/cli/doctor.ts +77 -7
- package/corpus/core/src/cli/migration-codemod.ts +569 -0
- package/corpus/core/src/cli/upgrade.ts +63 -7
- package/corpus/core/src/client/agent-chat/index.ts +279 -0
- package/corpus/core/src/client/agent-page/AgentContextTab.tsx +3 -1
- package/corpus/core/src/client/analytics/index.ts +40 -0
- package/corpus/core/src/client/api-path.ts +2 -2
- package/corpus/core/src/client/automation/index.ts +4 -0
- package/corpus/core/src/client/changelog/index.ts +1 -0
- package/corpus/core/src/client/chat/widgets/InlineExtensionWidget.tsx +5 -84
- package/corpus/core/src/client/chat/widgets/builtin-tool-renderers.tsx +52 -14
- package/corpus/core/src/client/chat/widgets/inline-extension-result.ts +86 -0
- package/corpus/core/src/client/client-bootstrap.ts +7 -0
- package/corpus/core/src/client/context-xray/ContextXRayPanel.tsx +1 -1
- package/corpus/core/src/client/hooks/index.ts +46 -0
- package/corpus/core/src/client/host/index.ts +170 -0
- package/corpus/core/src/client/index.ts +20 -664
- package/corpus/core/src/client/navigation/index.ts +54 -0
- package/corpus/core/src/client/resources/ResourcesPanel.tsx +1 -1
- package/corpus/core/src/client/resources/index.ts +2 -1
- package/corpus/core/src/client/resources/use-resources.ts +0 -20
- package/corpus/core/src/client/route-chunk-recovery/index.ts +1 -0
- package/corpus/core/src/client/ui/index.ts +55 -0
- package/corpus/core/src/client/uploads/index.ts +1 -0
- package/corpus/core/src/client/uploads/use-upload-resource.ts +24 -0
- package/corpus/core/src/client/widgets/index.ts +41 -0
- package/corpus/core/src/localization/default-messages.ts +2 -1
- package/corpus/core/src/package-lifecycle/deprecated-imports.ts +179 -0
- package/corpus/core/src/package-lifecycle/index.ts +5 -0
- package/corpus/core/src/package-lifecycle/migration-manifest.ts +159 -0
- package/corpus/core/src/package-lifecycle/migration-message.ts +6 -0
- package/corpus/core/src/package-lifecycle/tombstone.ts +44 -0
- package/corpus/core/src/package-lifecycle/upgrade-error.ts +19 -0
- package/corpus/core/src/templates/default/.agents/skills/actions/SKILL.md +3 -3
- package/corpus/core/src/templates/default/.agents/skills/adding-a-feature/SKILL.md +1 -1
- package/corpus/core/src/templates/default/.agents/skills/delegate-to-agent/SKILL.md +3 -3
- package/corpus/core/src/templates/default/.agents/skills/feature-flags/SKILL.md +1 -1
- package/corpus/core/src/templates/default/.agents/skills/real-time-collab/SKILL.md +4 -4
- package/corpus/core/src/templates/default/.agents/skills/real-time-sync/SKILL.md +4 -4
- package/corpus/core/src/templates/default/.agents/skills/storing-data/SKILL.md +1 -1
- package/corpus/core/src/templates/default/.agents/skills/upgrade-agent-native/SKILL.md +12 -5
- package/corpus/core/src/templates/default/app/hooks/use-navigation-state.ts +2 -5
- package/corpus/core/src/templates/default/app/i18n/index.ts +1 -1
- package/corpus/core/src/templates/default/app/lib/utils.ts +1 -1
- package/corpus/core/src/templates/default/app/root.tsx +8 -6
- package/corpus/core/src/templates/default/app/routes/_index.tsx +2 -1
- package/corpus/core/src/templates/default/app/routes/agent.tsx +2 -1
- package/corpus/core/src/templates/default/app/routes/settings.tsx +2 -3
- package/corpus/core/src/templates/headless/.agents/skills/feature-flags/SKILL.md +1 -1
- package/corpus/core/src/templates/headless/.agents/skills/upgrade-agent-native/SKILL.md +12 -5
- package/corpus/core/src/templates/workspace-core/.agents/skills/actions/SKILL.md +3 -3
- package/corpus/core/src/templates/workspace-core/.agents/skills/adding-a-feature/SKILL.md +1 -1
- package/corpus/core/src/templates/workspace-core/.agents/skills/authentication/SKILL.md +1 -1
- package/corpus/core/src/templates/workspace-core/.agents/skills/changelog/SKILL.md +1 -1
- package/corpus/core/src/templates/workspace-core/.agents/skills/client-methods/SKILL.md +10 -10
- package/corpus/core/src/templates/workspace-core/.agents/skills/context-awareness/SKILL.md +1 -1
- package/corpus/core/src/templates/workspace-core/.agents/skills/delegate-to-agent/SKILL.md +3 -3
- package/corpus/core/src/templates/workspace-core/.agents/skills/feature-flags/SKILL.md +1 -1
- package/corpus/core/src/templates/workspace-core/.agents/skills/observability/SKILL.md +1 -1
- package/corpus/core/src/templates/workspace-core/.agents/skills/real-time-collab/SKILL.md +4 -4
- package/corpus/core/src/templates/workspace-core/.agents/skills/real-time-sync/SKILL.md +4 -4
- package/corpus/core/src/templates/workspace-core/.agents/skills/sharing/SKILL.md +1 -1
- package/corpus/core/src/templates/workspace-core/.agents/skills/storing-data/SKILL.md +1 -1
- package/corpus/core/src/templates/workspace-core/.agents/skills/upgrade-agent-native/SKILL.md +12 -5
- package/corpus/core/src/vite/action-types-plugin.ts +4 -0
- package/corpus/core/src/vite/client.ts +80 -65
- package/corpus/templates/analytics/.agents/skills/actions/SKILL.md +3 -3
- package/corpus/templates/analytics/.agents/skills/delegate-to-agent/SKILL.md +3 -3
- package/corpus/templates/analytics/.agents/skills/feature-flags/SKILL.md +1 -1
- package/corpus/templates/analytics/.agents/skills/real-time-sync/SKILL.md +4 -4
- package/corpus/templates/analytics/.agents/skills/storing-data/SKILL.md +1 -1
- package/corpus/templates/analytics/.agents/skills/upgrade-agent-native/SKILL.md +12 -5
- package/corpus/templates/analytics/app/components/Markdown.tsx +1 -1
- package/corpus/templates/analytics/app/components/ProviderCorpusJobNotifier.tsx +2 -1
- package/corpus/templates/analytics/app/components/agents/FeatureFlagsFleetPanel.tsx +6 -4
- package/corpus/templates/analytics/app/components/analysis/AnalysisHistoryPanel.tsx +1 -1
- package/corpus/templates/analytics/app/components/auth/AuthProvider.tsx +2 -2
- package/corpus/templates/analytics/app/components/dashboard/CumulativeNetChart.tsx +1 -1
- package/corpus/templates/analytics/app/components/dashboard/DashboardHistoryPanel.tsx +1 -1
- package/corpus/templates/analytics/app/components/dashboard/DataTable.tsx +1 -1
- package/corpus/templates/analytics/app/components/dashboard/RecentActivity.tsx +1 -1
- package/corpus/templates/analytics/app/components/dashboard/RevenueChart.tsx +1 -1
- package/corpus/templates/analytics/app/components/dashboard/RevenueComparisonChart.tsx +1 -1
- package/corpus/templates/analytics/app/components/dashboard/SqlChart.tsx +2 -1
- package/corpus/templates/analytics/app/components/dashboard/TimeSeriesChart.tsx +1 -1
- package/corpus/templates/analytics/app/components/layout/CommandPalette.tsx +4 -6
- package/corpus/templates/analytics/app/components/layout/DashboardHeader.tsx +1 -1
- package/corpus/templates/analytics/app/components/layout/Header.tsx +2 -2
- package/corpus/templates/analytics/app/components/layout/HeaderActions.tsx +1 -1
- package/corpus/templates/analytics/app/components/layout/Layout.tsx +3 -3
- package/corpus/templates/analytics/app/components/layout/MobileNav.tsx +1 -1
- package/corpus/templates/analytics/app/components/layout/NewAnalysisDialog.tsx +4 -6
- package/corpus/templates/analytics/app/components/layout/NewDashboardDialog.tsx +3 -5
- package/corpus/templates/analytics/app/components/layout/Sidebar.tsx +10 -10
- package/corpus/templates/analytics/app/entry.client.tsx +2 -4
- package/corpus/templates/analytics/app/hooks/use-analysis-revisions.ts +4 -1
- package/corpus/templates/analytics/app/hooks/use-dashboard-chat-context.ts +6 -4
- package/corpus/templates/analytics/app/hooks/use-dashboard-revisions.ts +4 -1
- package/corpus/templates/analytics/app/hooks/use-dashboard-views.ts +1 -1
- package/corpus/templates/analytics/app/hooks/use-navigation-state.ts +2 -4
- package/corpus/templates/analytics/app/hooks/use-replay-storage-status.ts +1 -1
- package/corpus/templates/analytics/app/hooks/use-user-pref.ts +1 -1
- package/corpus/templates/analytics/app/i18n/index.ts +1 -1
- package/corpus/templates/analytics/app/i18n-data.ts +1 -1
- package/corpus/templates/analytics/app/lib/api-hooks.ts +1 -1
- package/corpus/templates/analytics/app/lib/item-popularity.ts +1 -1
- package/corpus/templates/analytics/app/lib/query-metrics.ts +1 -1
- package/corpus/templates/analytics/app/lib/sql-query.ts +1 -1
- package/corpus/templates/analytics/app/lib/tab-id.ts +1 -1
- package/corpus/templates/analytics/app/lib/track-metric.ts +1 -1
- package/corpus/templates/analytics/app/lib/user-info.ts +1 -1
- package/corpus/templates/analytics/app/lib/utils.ts +1 -1
- package/corpus/templates/analytics/app/pages/Agents.tsx +5 -6
- package/corpus/templates/analytics/app/pages/Ask.tsx +2 -2
- package/corpus/templates/analytics/app/pages/DataDictionary.tsx +3 -3
- package/corpus/templates/analytics/app/pages/DataSources.tsx +7 -5
- package/corpus/templates/analytics/app/pages/NotFound.tsx +1 -1
- package/corpus/templates/analytics/app/pages/Placeholder.tsx +1 -1
- package/corpus/templates/analytics/app/pages/Settings.tsx +5 -6
- package/corpus/templates/analytics/app/pages/adhoc/BlankDashboard.tsx +1 -1
- package/corpus/templates/analytics/app/pages/adhoc/_shared/KpiChart.tsx +1 -1
- package/corpus/templates/analytics/app/pages/adhoc/explorer/components/EventCombobox.tsx +1 -1
- package/corpus/templates/analytics/app/pages/adhoc/explorer/components/EventPanel.tsx +1 -1
- package/corpus/templates/analytics/app/pages/adhoc/explorer/components/ExplorerChart.tsx +1 -1
- package/corpus/templates/analytics/app/pages/adhoc/explorer/components/FilterBuilder.tsx +1 -1
- package/corpus/templates/analytics/app/pages/adhoc/explorer/components/GroupByPicker.tsx +1 -1
- package/corpus/templates/analytics/app/pages/adhoc/explorer/components/PropertyCombobox.tsx +1 -1
- package/corpus/templates/analytics/app/pages/adhoc/explorer/components/PropertyValueCombobox.tsx +1 -1
- package/corpus/templates/analytics/app/pages/adhoc/explorer/components/SqlPreview.tsx +1 -1
- package/corpus/templates/analytics/app/pages/adhoc/explorer/index.tsx +1 -1
- package/corpus/templates/analytics/app/pages/adhoc/explorer/use-explorer-config.ts +2 -1
- package/corpus/templates/analytics/app/pages/adhoc/explorer-dashboard/ChartCard.tsx +2 -1
- package/corpus/templates/analytics/app/pages/adhoc/explorer-dashboard/index.tsx +8 -6
- package/corpus/templates/analytics/app/pages/adhoc/sql-dashboard/DashboardFilterBar.tsx +1 -1
- package/corpus/templates/analytics/app/pages/adhoc/sql-dashboard/EmailReportDialog.tsx +2 -2
- package/corpus/templates/analytics/app/pages/adhoc/sql-dashboard/PanelEditorDialog.tsx +4 -6
- package/corpus/templates/analytics/app/pages/adhoc/sql-dashboard/SqlChartCard.tsx +1 -1
- package/corpus/templates/analytics/app/pages/adhoc/sql-dashboard/ViewSqlPopover.tsx +2 -1
- package/corpus/templates/analytics/app/pages/adhoc/sql-dashboard/ViewsMenu.tsx +1 -1
- package/corpus/templates/analytics/app/pages/adhoc/sql-dashboard/index.tsx +9 -7
- package/corpus/templates/analytics/app/pages/analyses/AnalysesList.tsx +3 -6
- package/corpus/templates/analytics/app/pages/analyses/AnalysisDetail.tsx +4 -4
- package/corpus/templates/analytics/app/pages/analyses/LegacyFusionAnalysis.tsx +2 -1
- package/corpus/templates/analytics/app/pages/monitoring/ErrorsPanel.tsx +1 -11
- package/corpus/templates/analytics/app/pages/monitoring/MonitoringPage.tsx +2 -1
- package/corpus/templates/analytics/app/pages/monitoring/UptimePanel.tsx +1 -14
- package/corpus/templates/analytics/app/pages/monitoring/errors/IssueDetail.tsx +1 -1
- package/corpus/templates/analytics/app/pages/monitoring/errors/IssueList.tsx +1 -1
- package/corpus/templates/analytics/app/pages/monitoring/errors/i18n.ts +1 -6
- package/corpus/templates/analytics/app/pages/monitoring/uptime/MonitorDetail.tsx +1 -8
- package/corpus/templates/analytics/app/pages/monitoring/uptime/MonitorFormPage.tsx +4 -10
- package/corpus/templates/analytics/app/pages/monitoring/uptime/i18n.ts +1 -6
- package/corpus/templates/analytics/app/pages/monitoring/uptime/status-pages/StatusPageEditor.tsx +4 -8
- package/corpus/templates/analytics/app/pages/monitoring/uptime/status-pages/StatusPagesView.tsx +4 -10
- package/corpus/templates/analytics/app/pages/monitoring/uptime/status-pages/i18n.ts +1 -6
- package/corpus/templates/analytics/app/pages/sessions/SessionDetailPage.tsx +5 -6
- package/corpus/templates/analytics/app/pages/sessions/SessionDevToolsPanel.tsx +1 -1
- package/corpus/templates/analytics/app/pages/sessions/SessionsPage.tsx +5 -5
- package/corpus/templates/analytics/app/pages/settings/AlertRulesSettingsCard.tsx +2 -2
- package/corpus/templates/analytics/app/pages/settings/settings-search.ts +1 -1
- package/corpus/templates/analytics/app/root.tsx +6 -6
- package/corpus/templates/analytics/app/routes/agent.tsx +1 -1
- package/corpus/templates/analytics/app/routes/catalog.tsx +2 -2
- package/corpus/templates/analytics/app/routes/chart.tsx +1 -1
- package/corpus/templates/analytics/app/routes/status.$slug.tsx +1 -13
- package/corpus/templates/assets/.agents/skills/actions/SKILL.md +3 -3
- package/corpus/templates/assets/.agents/skills/delegate-to-agent/SKILL.md +3 -3
- package/corpus/templates/assets/.agents/skills/feature-flags/SKILL.md +1 -1
- package/corpus/templates/assets/.agents/skills/real-time-collab/SKILL.md +4 -4
- package/corpus/templates/assets/.agents/skills/real-time-sync/SKILL.md +4 -4
- package/corpus/templates/assets/.agents/skills/storing-data/SKILL.md +1 -1
- package/corpus/templates/assets/.agents/skills/upgrade-agent-native/SKILL.md +12 -5
- package/corpus/templates/assets/app/components/create/RecentDraftsSection.tsx +2 -1
- package/corpus/templates/assets/app/components/generation/GenerationResults.tsx +3 -3
- package/corpus/templates/assets/app/components/layout/Header.tsx +3 -5
- package/corpus/templates/assets/app/components/layout/Layout.tsx +4 -4
- package/corpus/templates/assets/app/components/layout/Sidebar.tsx +6 -6
- package/corpus/templates/assets/app/components/library/CreateLibraryDialog.tsx +2 -2
- package/corpus/templates/assets/app/components/library/GenerationPresetsPanel.tsx +2 -1
- package/corpus/templates/assets/app/components/library/LibraryCard.tsx +1 -1
- package/corpus/templates/assets/app/components/library/LibraryPresetGrid.tsx +1 -1
- package/corpus/templates/assets/app/hooks/use-image-model-menu.ts +2 -2
- package/corpus/templates/assets/app/hooks/use-navigation-state.ts +3 -3
- package/corpus/templates/assets/app/i18n/index.ts +1 -1
- package/corpus/templates/assets/app/i18n-data.ts +1 -1
- package/corpus/templates/assets/app/lib/asset-urls.ts +1 -1
- package/corpus/templates/assets/app/lib/utils.ts +1 -1
- package/corpus/templates/assets/app/root.tsx +10 -9
- package/corpus/templates/assets/app/routes/_index.tsx +3 -3
- package/corpus/templates/assets/app/routes/agent.tsx +1 -1
- package/corpus/templates/assets/app/routes/asset.$id.tsx +3 -3
- package/corpus/templates/assets/app/routes/asset.$id_.embed.tsx +1 -1
- package/corpus/templates/assets/app/routes/audit.tsx +2 -2
- package/corpus/templates/assets/app/routes/brand-kits.$id.tsx +6 -4
- package/corpus/templates/assets/app/routes/brand-kits.$id_.presets.$presetId.tsx +4 -4
- package/corpus/templates/assets/app/routes/brand-kits.$id_.settings.tsx +3 -3
- package/corpus/templates/assets/app/routes/library.tsx +13 -9
- package/corpus/templates/assets/app/routes/run.$id_.embed.tsx +1 -1
- package/corpus/templates/assets/app/routes/settings.tsx +11 -12
- package/corpus/templates/brain/.agents/skills/actions/SKILL.md +3 -3
- package/corpus/templates/brain/.agents/skills/adding-a-feature/SKILL.md +1 -1
- package/corpus/templates/brain/.agents/skills/delegate-to-agent/SKILL.md +3 -3
- package/corpus/templates/brain/.agents/skills/feature-flags/SKILL.md +1 -1
- package/corpus/templates/brain/.agents/skills/real-time-sync/SKILL.md +4 -4
- package/corpus/templates/brain/.agents/skills/upgrade-agent-native/SKILL.md +12 -5
- package/corpus/templates/brain/app/components/brain/CanonicalPreviewSheet.tsx +1 -1
- package/corpus/templates/brain/app/components/layout/Layout.tsx +2 -2
- package/corpus/templates/brain/app/components/layout/Sidebar.tsx +5 -5
- package/corpus/templates/brain/app/hooks/use-distillation-bridge.ts +3 -6
- package/corpus/templates/brain/app/hooks/use-navigation-state.ts +3 -4
- package/corpus/templates/brain/app/i18n/index.ts +1 -1
- package/corpus/templates/brain/app/i18n-data.ts +1 -1
- package/corpus/templates/brain/app/lib/utils.ts +1 -1
- package/corpus/templates/brain/app/root.tsx +10 -9
- package/corpus/templates/brain/app/routes/_index.tsx +2 -2
- package/corpus/templates/brain/app/routes/agent.tsx +1 -1
- package/corpus/templates/brain/app/routes/knowledge.tsx +2 -2
- package/corpus/templates/brain/app/routes/ops.tsx +2 -2
- package/corpus/templates/brain/app/routes/review.tsx +2 -2
- package/corpus/templates/brain/app/routes/search.tsx +2 -1
- package/corpus/templates/brain/app/routes/settings.tsx +8 -7
- package/corpus/templates/brain/app/routes/sources.tsx +2 -2
- package/corpus/templates/calendar/.agents/skills/actions/SKILL.md +3 -3
- package/corpus/templates/calendar/.agents/skills/delegate-to-agent/SKILL.md +3 -3
- package/corpus/templates/calendar/.agents/skills/feature-flags/SKILL.md +1 -1
- package/corpus/templates/calendar/.agents/skills/real-time-sync/SKILL.md +4 -4
- package/corpus/templates/calendar/.agents/skills/storing-data/SKILL.md +1 -1
- package/corpus/templates/calendar/.agents/skills/upgrade-agent-native/SKILL.md +12 -5
- package/corpus/templates/calendar/app/components/CloudUpgrade.tsx +1 -1
- package/corpus/templates/calendar/app/components/ThemeToggle.tsx +1 -1
- package/corpus/templates/calendar/app/components/TimezoneCombobox.tsx +1 -1
- package/corpus/templates/calendar/app/components/booking/BookingConfirmation.tsx +1 -1
- package/corpus/templates/calendar/app/components/booking/BookingForm.tsx +2 -1
- package/corpus/templates/calendar/app/components/booking/TimeSlotPicker.tsx +1 -1
- package/corpus/templates/calendar/app/components/calendar/AddCalendarDialog.tsx +2 -1
- package/corpus/templates/calendar/app/components/calendar/ApolloPanel.tsx +2 -1
- package/corpus/templates/calendar/app/components/calendar/AttendeeAutocomplete.tsx +1 -1
- package/corpus/templates/calendar/app/components/calendar/CommandPalette.tsx +2 -1
- package/corpus/templates/calendar/app/components/calendar/CreateEventDialog.tsx +3 -5
- package/corpus/templates/calendar/app/components/calendar/DayView.tsx +1 -1
- package/corpus/templates/calendar/app/components/calendar/DeleteEventDialog.tsx +1 -1
- package/corpus/templates/calendar/app/components/calendar/EventAttendeesSection.tsx +1 -1
- package/corpus/templates/calendar/app/components/calendar/EventCard.tsx +1 -1
- package/corpus/templates/calendar/app/components/calendar/EventDescription.tsx +1 -1
- package/corpus/templates/calendar/app/components/calendar/EventDetailPanel.tsx +1 -1
- package/corpus/templates/calendar/app/components/calendar/EventDetailPopover.tsx +2 -1
- package/corpus/templates/calendar/app/components/calendar/EventDialog.tsx +1 -1
- package/corpus/templates/calendar/app/components/calendar/EventOptionControls.tsx +2 -1
- package/corpus/templates/calendar/app/components/calendar/FindTimePanel.tsx +2 -1
- package/corpus/templates/calendar/app/components/calendar/GoogleConnectBanner.tsx +3 -3
- package/corpus/templates/calendar/app/components/calendar/GoogleSetupWizard.tsx +3 -5
- package/corpus/templates/calendar/app/components/calendar/GoogleSyncButton.tsx +1 -1
- package/corpus/templates/calendar/app/components/calendar/GuestNotificationDialog.tsx +1 -1
- package/corpus/templates/calendar/app/components/calendar/IntegrationsSidebar.tsx +2 -1
- package/corpus/templates/calendar/app/components/calendar/KeyboardShortcutsHelp.tsx +1 -1
- package/corpus/templates/calendar/app/components/calendar/PeopleSearchDialog.tsx +2 -1
- package/corpus/templates/calendar/app/components/calendar/WeekView.tsx +1 -1
- package/corpus/templates/calendar/app/components/calendar/WorkingLocationEditor.tsx +1 -1
- package/corpus/templates/calendar/app/components/layout/AppLayout.tsx +3 -3
- package/corpus/templates/calendar/app/components/layout/Sidebar.tsx +4 -6
- package/corpus/templates/calendar/app/hooks/use-apollo.ts +1 -1
- package/corpus/templates/calendar/app/hooks/use-attendee-timezones.ts +4 -1
- package/corpus/templates/calendar/app/hooks/use-availability.ts +4 -1
- package/corpus/templates/calendar/app/hooks/use-booking-links.ts +4 -1
- package/corpus/templates/calendar/app/hooks/use-bookings.ts +1 -1
- package/corpus/templates/calendar/app/hooks/use-db-status.ts +1 -1
- package/corpus/templates/calendar/app/hooks/use-events.ts +1 -1
- package/corpus/templates/calendar/app/hooks/use-external-calendars.ts +1 -1
- package/corpus/templates/calendar/app/hooks/use-google-auth.ts +2 -2
- package/corpus/templates/calendar/app/hooks/use-integrations.ts +1 -1
- package/corpus/templates/calendar/app/hooks/use-navigation-state.ts +3 -2
- package/corpus/templates/calendar/app/hooks/use-overlay-people.ts +1 -1
- package/corpus/templates/calendar/app/hooks/use-people.ts +1 -1
- package/corpus/templates/calendar/app/hooks/use-settings.ts +4 -1
- package/corpus/templates/calendar/app/hooks/use-view-preferences.ts +2 -1
- package/corpus/templates/calendar/app/hooks/use-zoom-auth.ts +2 -1
- package/corpus/templates/calendar/app/i18n/index.ts +1 -1
- package/corpus/templates/calendar/app/i18n-data.ts +1 -1
- package/corpus/templates/calendar/app/lib/api-path.ts +1 -1
- package/corpus/templates/calendar/app/lib/utils.ts +1 -1
- package/corpus/templates/calendar/app/pages/AvailabilitySettings.tsx +1 -1
- package/corpus/templates/calendar/app/pages/BookingLinksPage.tsx +3 -1
- package/corpus/templates/calendar/app/pages/BookingPage.tsx +2 -3
- package/corpus/templates/calendar/app/pages/BookingsList.tsx +1 -1
- package/corpus/templates/calendar/app/pages/CalendarView.tsx +3 -5
- package/corpus/templates/calendar/app/pages/ManageBookingPage.tsx +1 -1
- package/corpus/templates/calendar/app/pages/NotFound.tsx +1 -1
- package/corpus/templates/calendar/app/pages/Settings.tsx +9 -8
- package/corpus/templates/calendar/app/root.tsx +15 -9
- package/corpus/templates/calendar/app/routes/_app.agent.tsx +2 -1
- package/corpus/templates/calendar/app/routes/_app.settings.tsx +1 -1
- package/corpus/templates/calendar/app/routes/event.tsx +3 -3
- package/corpus/templates/chat/.agents/skills/actions/SKILL.md +3 -3
- package/corpus/templates/chat/.agents/skills/adding-a-feature/SKILL.md +1 -1
- package/corpus/templates/chat/.agents/skills/delegate-to-agent/SKILL.md +3 -3
- package/corpus/templates/chat/.agents/skills/feature-flags/SKILL.md +1 -1
- package/corpus/templates/chat/.agents/skills/real-time-sync/SKILL.md +4 -4
- package/corpus/templates/chat/.agents/skills/upgrade-agent-native/SKILL.md +12 -5
- package/corpus/templates/chat/app/components/layout/Header.tsx +2 -1
- package/corpus/templates/chat/app/components/layout/Layout.tsx +2 -2
- package/corpus/templates/chat/app/components/layout/Sidebar.tsx +4 -4
- package/corpus/templates/chat/app/hooks/use-navigation-state.ts +3 -4
- package/corpus/templates/chat/app/i18n/index.ts +1 -1
- package/corpus/templates/chat/app/i18n-data.ts +1 -1
- package/corpus/templates/chat/app/lib/utils.ts +1 -1
- package/corpus/templates/chat/app/root.tsx +10 -9
- package/corpus/templates/chat/app/routes/_index.tsx +2 -2
- package/corpus/templates/chat/app/routes/agent.tsx +10 -3
- package/corpus/templates/chat/app/routes/database.tsx +1 -1
- package/corpus/templates/chat/app/routes/observability.tsx +2 -1
- package/corpus/templates/chat/app/routes/settings.tsx +4 -5
- package/corpus/templates/clips/.agents/skills/actions/SKILL.md +3 -3
- package/corpus/templates/clips/.agents/skills/delegate-to-agent/SKILL.md +3 -3
- package/corpus/templates/clips/.agents/skills/feature-flags/SKILL.md +1 -1
- package/corpus/templates/clips/.agents/skills/upgrade-agent-native/SKILL.md +12 -5
- package/corpus/templates/clips/app/components/capture-install-options.tsx +2 -1
- package/corpus/templates/clips/app/components/dictate/vocabulary-section.tsx +2 -2
- package/corpus/templates/clips/app/components/editable-recording-title.tsx +2 -1
- package/corpus/templates/clips/app/components/editor/chapters-editor.tsx +2 -1
- package/corpus/templates/clips/app/components/editor/editor-layout.tsx +4 -14
- package/corpus/templates/clips/app/components/editor/editor-toolbar.tsx +2 -1
- package/corpus/templates/clips/app/components/editor/split-button.tsx +2 -1
- package/corpus/templates/clips/app/components/editor/stitch-manager.tsx +3 -3
- package/corpus/templates/clips/app/components/editor/thumbnail-picker.tsx +2 -1
- package/corpus/templates/clips/app/components/editor/transcript-editor.tsx +1 -1
- package/corpus/templates/clips/app/components/layout/Header.tsx +2 -1
- package/corpus/templates/clips/app/components/library/bulk-action-toolbar.tsx +1 -1
- package/corpus/templates/clips/app/components/library/create-folder-dialog.tsx +1 -1
- package/corpus/templates/clips/app/components/library/create-space-dialog.tsx +1 -1
- package/corpus/templates/clips/app/components/library/empty-state.tsx +1 -1
- package/corpus/templates/clips/app/components/library/folder-tree.tsx +1 -1
- package/corpus/templates/clips/app/components/library/library-grid.tsx +2 -2
- package/corpus/templates/clips/app/components/library/library-layout.tsx +6 -6
- package/corpus/templates/clips/app/components/library/organization-switcher.tsx +1 -1
- package/corpus/templates/clips/app/components/library/recording-card.tsx +1 -1
- package/corpus/templates/clips/app/components/library/search-bar.tsx +1 -1
- package/corpus/templates/clips/app/components/meetings/auto-record-prompt.tsx +1 -17
- package/corpus/templates/clips/app/components/meetings/canvas-editor.tsx +1 -1
- package/corpus/templates/clips/app/components/meetings/meeting-card.tsx +1 -1
- package/corpus/templates/clips/app/components/meetings/quick-ask-sidebar.tsx +2 -20
- package/corpus/templates/clips/app/components/meetings/share-meeting-dialog.tsx +3 -1
- package/corpus/templates/clips/app/components/meetings/transcript-bubbles.tsx +1 -1
- package/corpus/templates/clips/app/components/player/access-password-prompt.tsx +1 -1
- package/corpus/templates/clips/app/components/player/captions-overlay.tsx +1 -1
- package/corpus/templates/clips/app/components/player/comments-panel.tsx +2 -1
- package/corpus/templates/clips/app/components/player/delete-recording-menu.tsx +2 -1
- package/corpus/templates/clips/app/components/player/insights-panel.tsx +2 -1
- package/corpus/templates/clips/app/components/player/player-controls.tsx +1 -1
- package/corpus/templates/clips/app/components/player/settings-panel.tsx +2 -2
- package/corpus/templates/clips/app/components/player/share-dialog.tsx +3 -3
- package/corpus/templates/clips/app/components/player/sign-in-prompt-dialog.tsx +1 -1
- package/corpus/templates/clips/app/components/player/timestamped-comment-button.tsx +2 -1
- package/corpus/templates/clips/app/components/player/transcript-panel.tsx +3 -6
- package/corpus/templates/clips/app/components/player/video-player.tsx +3 -5
- package/corpus/templates/clips/app/components/recorder/camera-visualizer.tsx +1 -1
- package/corpus/templates/clips/app/components/recorder/countdown-overlay.tsx +1 -1
- package/corpus/templates/clips/app/components/recorder/microphone-visualizer.tsx +1 -1
- package/corpus/templates/clips/app/components/recorder/pre-record-panel.tsx +2 -1
- package/corpus/templates/clips/app/components/recorder/recorder-engine.ts +3 -13
- package/corpus/templates/clips/app/components/recorder/recording-toolbar.tsx +1 -1
- package/corpus/templates/clips/app/components/recorder/storage-setup-card.tsx +3 -6
- package/corpus/templates/clips/app/components/sharing/share-ui.tsx +2 -2
- package/corpus/templates/clips/app/components/sharing/viewed-by-popover.tsx +2 -1
- package/corpus/templates/clips/app/components/workspace/branding-editor.tsx +3 -5
- package/corpus/templates/clips/app/components/workspace/engagement-chart.tsx +1 -1
- package/corpus/templates/clips/app/components/workspace/insights-hub.tsx +3 -1
- package/corpus/templates/clips/app/components/workspace/invite-dialog.tsx +2 -1
- package/corpus/templates/clips/app/components/workspace/members-list.tsx +2 -1
- package/corpus/templates/clips/app/components/workspace/notifications-list.tsx +1 -1
- package/corpus/templates/clips/app/components/workspace/top-creators-table.tsx +1 -1
- package/corpus/templates/clips/app/entry.client.tsx +2 -4
- package/corpus/templates/clips/app/hooks/use-auto-title.ts +3 -17
- package/corpus/templates/clips/app/hooks/use-library.ts +4 -1
- package/corpus/templates/clips/app/hooks/use-navigation-state.ts +2 -1
- package/corpus/templates/clips/app/hooks/use-video-storage-status.ts +1 -1
- package/corpus/templates/clips/app/hooks/use-view-tracking.ts +1 -1
- package/corpus/templates/clips/app/i18n/index.ts +5 -5
- package/corpus/templates/clips/app/lib/camera-blur.ts +1 -1
- package/corpus/templates/clips/app/lib/capture-install-options.ts +1 -1
- package/corpus/templates/clips/app/lib/thumbnail-capture.ts +1 -1
- package/corpus/templates/clips/app/lib/utils.ts +1 -1
- package/corpus/templates/clips/app/root.tsx +13 -9
- package/corpus/templates/clips/app/routes/_app.agent.tsx +2 -1
- package/corpus/templates/clips/app/routes/_app.archive.tsx +1 -1
- package/corpus/templates/clips/app/routes/_app.dictate.tsx +2 -2
- package/corpus/templates/clips/app/routes/_app.extensions.$id.tsx +1 -1
- package/corpus/templates/clips/app/routes/_app.extensions._index.tsx +1 -1
- package/corpus/templates/clips/app/routes/_app.library._index.tsx +1 -1
- package/corpus/templates/clips/app/routes/_app.library.folder.$folderId.tsx +1 -1
- package/corpus/templates/clips/app/routes/_app.meetings.$meetingId.tsx +2 -2
- package/corpus/templates/clips/app/routes/_app.meetings._index.tsx +3 -5
- package/corpus/templates/clips/app/routes/_app.notifications.tsx +2 -2
- package/corpus/templates/clips/app/routes/_app.settings._index.tsx +7 -7
- package/corpus/templates/clips/app/routes/_app.settings.organization.tsx +2 -1
- package/corpus/templates/clips/app/routes/_app.shared.tsx +1 -1
- package/corpus/templates/clips/app/routes/_app.spaces.$spaceId.folder.$folderId.tsx +1 -1
- package/corpus/templates/clips/app/routes/_app.spaces.$spaceId.tsx +1 -1
- package/corpus/templates/clips/app/routes/_app.spaces._index.tsx +1 -1
- package/corpus/templates/clips/app/routes/_app.trash.tsx +2 -1
- package/corpus/templates/clips/app/routes/_index.tsx +1 -1
- package/corpus/templates/clips/app/routes/bug-report.done.tsx +2 -1
- package/corpus/templates/clips/app/routes/bug-report.tsx +2 -1
- package/corpus/templates/clips/app/routes/download.tsx +2 -1
- package/corpus/templates/clips/app/routes/embed.$shareId.tsx +2 -1
- package/corpus/templates/clips/app/routes/invite.$token.tsx +2 -1
- package/corpus/templates/clips/app/routes/r.$recordingId.tsx +4 -5
- package/corpus/templates/clips/app/routes/record.tsx +4 -4
- package/corpus/templates/clips/app/routes/share.$shareId.tsx +5 -6
- package/corpus/templates/clips/app/routes/share.meeting.$meetingId.tsx +3 -1
- package/corpus/templates/content/.agents/skills/actions/SKILL.md +3 -3
- package/corpus/templates/content/.agents/skills/delegate-to-agent/SKILL.md +3 -3
- package/corpus/templates/content/.agents/skills/feature-flags/SKILL.md +1 -1
- package/corpus/templates/content/.agents/skills/real-time-sync/SKILL.md +4 -4
- package/corpus/templates/content/.agents/skills/storing-data/SKILL.md +1 -1
- package/corpus/templates/content/.agents/skills/upgrade-agent-native/SKILL.md +12 -5
- package/corpus/templates/content/app/blocks/SourceComponentBlock.tsx +1 -1
- package/corpus/templates/content/app/blocks/contentBlockRegistry.tsx +1 -1
- package/corpus/templates/content/app/components/EmptyState.tsx +1 -1
- package/corpus/templates/content/app/components/QueryErrorState.tsx +1 -1
- package/corpus/templates/content/app/components/ThemeToggle.tsx +1 -1
- package/corpus/templates/content/app/components/editor/BubbleToolbar.tsx +1 -1
- package/corpus/templates/content/app/components/editor/CommentsSidebar.tsx +3 -1
- package/corpus/templates/content/app/components/editor/ContentReferencePreview.tsx +1 -1
- package/corpus/templates/content/app/components/editor/DocumentBlockFields.tsx +1 -1
- package/corpus/templates/content/app/components/editor/DocumentEditor.tsx +7 -5
- package/corpus/templates/content/app/components/editor/DocumentProperties.tsx +3 -6
- package/corpus/templates/content/app/components/editor/DocumentToolbar.tsx +7 -9
- package/corpus/templates/content/app/components/editor/EmojiPicker.tsx +1 -1
- package/corpus/templates/content/app/components/editor/LinkHoverPreview.tsx +1 -1
- package/corpus/templates/content/app/components/editor/NotionConflictBanner.tsx +1 -1
- package/corpus/templates/content/app/components/editor/NotionSyncBar.tsx +1 -1
- package/corpus/templates/content/app/components/editor/SlashCommandMenu.tsx +2 -1
- package/corpus/templates/content/app/components/editor/TableHoverControls.tsx +1 -1
- package/corpus/templates/content/app/components/editor/VersionHistoryPanel.tsx +2 -1
- package/corpus/templates/content/app/components/editor/VisualEditor.tsx +6 -4
- package/corpus/templates/content/app/components/editor/database/DatabaseView.tsx +5 -6
- package/corpus/templates/content/app/components/editor/database/FormView.tsx +1 -1
- package/corpus/templates/content/app/components/editor/database/settings.tsx +2 -2
- package/corpus/templates/content/app/components/editor/database-sources/BuilderSourceReviewDialog.tsx +1 -1
- package/corpus/templates/content/app/components/editor/extensions/AudioBlock.tsx +2 -1
- package/corpus/templates/content/app/components/editor/extensions/CodeBlockNode.tsx +1 -1
- package/corpus/templates/content/app/components/editor/extensions/ImageBlock.tsx +2 -1
- package/corpus/templates/content/app/components/editor/extensions/LocalMdxComponentNode.tsx +1 -1
- package/corpus/templates/content/app/components/editor/extensions/VideoBlock.tsx +2 -1
- package/corpus/templates/content/app/components/editor/extensions/registryBlocks.ts +1 -1
- package/corpus/templates/content/app/components/editor/image-upload.ts +1 -1
- package/corpus/templates/content/app/components/editor/registrySlashItems.ts +1 -1
- package/corpus/templates/content/app/components/layout/Header.tsx +1 -1
- package/corpus/templates/content/app/components/layout/Layout.tsx +3 -1
- package/corpus/templates/content/app/components/sidebar/DocumentSidebar.tsx +9 -9
- package/corpus/templates/content/app/components/sidebar/DocumentTreeItem.tsx +1 -1
- package/corpus/templates/content/app/components/sidebar/NotionButton.tsx +5 -1
- package/corpus/templates/content/app/entry.client.tsx +2 -4
- package/corpus/templates/content/app/hooks/use-comments.ts +4 -1
- package/corpus/templates/content/app/hooks/use-content-database.ts +4 -1
- package/corpus/templates/content/app/hooks/use-content-spaces.ts +4 -1
- package/corpus/templates/content/app/hooks/use-db-sync.ts +1 -1
- package/corpus/templates/content/app/hooks/use-document-properties.ts +4 -1
- package/corpus/templates/content/app/hooks/use-document-versions.ts +4 -1
- package/corpus/templates/content/app/hooks/use-documents.ts +4 -1
- package/corpus/templates/content/app/hooks/use-mention-members.ts +1 -1
- package/corpus/templates/content/app/hooks/use-navigation-state.ts +2 -1
- package/corpus/templates/content/app/hooks/use-notion.ts +2 -2
- package/corpus/templates/content/app/i18n/index.ts +1 -1
- package/corpus/templates/content/app/i18n-data.ts +1 -1
- package/corpus/templates/content/app/lib/local-control-resources.ts +1 -1
- package/corpus/templates/content/app/lib/utils.ts +1 -1
- package/corpus/templates/content/app/root.tsx +15 -9
- package/corpus/templates/content/app/routes/_app.agent.tsx +2 -1
- package/corpus/templates/content/app/routes/_app.local-files.tsx +2 -1
- package/corpus/templates/content/app/routes/_app.page.$id.tsx +1 -1
- package/corpus/templates/content/app/routes/_app.settings.tsx +4 -5
- package/corpus/templates/content/app/routes/p.$id.tsx +2 -1
- package/corpus/templates/design/.agents/skills/actions/SKILL.md +3 -3
- package/corpus/templates/design/.agents/skills/delegate-to-agent/SKILL.md +3 -3
- package/corpus/templates/design/.agents/skills/feature-flags/SKILL.md +1 -1
- package/corpus/templates/design/.agents/skills/upgrade-agent-native/SKILL.md +12 -5
- package/corpus/templates/design/app/components/QueryErrorState.tsx +1 -1
- package/corpus/templates/design/app/components/ThemeToggle.tsx +1 -1
- package/corpus/templates/design/app/components/design/AutoLayoutSuggestionDialog.tsx +1 -1
- package/corpus/templates/design/app/components/design/BreakpointBar.tsx +1 -30
- package/corpus/templates/design/app/components/design/DesignCanvas.tsx +4 -3
- package/corpus/templates/design/app/components/design/DesignExtensionsPanel.tsx +4 -4
- package/corpus/templates/design/app/components/design/DesignImportPanel.tsx +2 -5
- package/corpus/templates/design/app/components/design/DrawOverlay.tsx +1 -1
- package/corpus/templates/design/app/components/design/EditPanel.tsx +2 -2
- package/corpus/templates/design/app/components/design/FusionAppBanner.tsx +4 -1
- package/corpus/templates/design/app/components/design/KeyboardShortcutsPanel.tsx +1 -1
- package/corpus/templates/design/app/components/design/LayersPanel.tsx +1 -1
- package/corpus/templates/design/app/components/design/LocalhostWriteConsentDialog.tsx +1 -1
- package/corpus/templates/design/app/components/design/MotionDock.tsx +1 -19
- package/corpus/templates/design/app/components/design/MultiScreenCanvas.tsx +2 -2
- package/corpus/templates/design/app/components/design/QuestionFlow.tsx +2 -2
- package/corpus/templates/design/app/components/design/ReadOnlyDesignBanner.tsx +1 -1
- package/corpus/templates/design/app/components/design/ReviewCommentsPanel.tsx +2 -2
- package/corpus/templates/design/app/components/design/ReviewPanel.tsx +1 -22
- package/corpus/templates/design/app/components/design/ReviewStatusControl.tsx +2 -2
- package/corpus/templates/design/app/components/design/StatesPanel.tsx +4 -14
- package/corpus/templates/design/app/components/design/TokensPanel.tsx +2 -17
- package/corpus/templates/design/app/components/design/TweaksPanel.tsx +1 -1
- package/corpus/templates/design/app/components/design/code-workbench/CodeWorkbench.tsx +1 -1
- package/corpus/templates/design/app/components/design/code-workbench/editor/BufferSync.tsx +1 -1
- package/corpus/templates/design/app/components/design/code-workbench/explorer/ExplorerView.tsx +1 -1
- package/corpus/templates/design/app/components/design/code-workbench/workspace/inline-provider.ts +1 -1
- package/corpus/templates/design/app/components/design/code-workbench/workspace/localhost-provider.ts +1 -1
- package/corpus/templates/design/app/components/design/design-canvas/annotation-snapshot.ts +1 -1
- package/corpus/templates/design/app/components/design/edit-panel/appearance-properties.tsx +1 -1
- package/corpus/templates/design/app/components/design/edit-panel/component-section.tsx +2 -2
- package/corpus/templates/design/app/components/design/edit-panel/effects-properties.tsx +1 -1
- package/corpus/templates/design/app/components/design/edit-panel/field-primitives.tsx +1 -1
- package/corpus/templates/design/app/components/design/edit-panel/fill-properties.tsx +1 -1
- package/corpus/templates/design/app/components/design/edit-panel/frame-presets-panel.tsx +1 -1
- package/corpus/templates/design/app/components/design/edit-panel/layout-properties.tsx +1 -1
- package/corpus/templates/design/app/components/design/edit-panel/position-layout-properties.tsx +1 -1
- package/corpus/templates/design/app/components/design/edit-panel/stroke-properties.tsx +1 -1
- package/corpus/templates/design/app/components/design/edit-panel/typography-properties.tsx +1 -1
- package/corpus/templates/design/app/components/design/inspector/BreakpointOverrideIndicator.tsx +1 -16
- package/corpus/templates/design/app/components/design/inspector/GlslShaderPanel.tsx +2 -34
- package/corpus/templates/design/app/components/design/inspector/ImageFillControls.tsx +2 -1
- package/corpus/templates/design/app/components/design/inspector/InteractionStatePanel.tsx +1 -25
- package/corpus/templates/design/app/components/design/inspector/MotionKeyframeDiamond.tsx +1 -30
- package/corpus/templates/design/app/components/design/inspector/ShaderFillsPanel.tsx +1 -1
- package/corpus/templates/design/app/components/design-system/ProductionDesignSystemShowcase.tsx +1 -1
- package/corpus/templates/design/app/components/editor/FigmaLinkComposerBubble.tsx +1 -1
- package/corpus/templates/design/app/components/editor/PromptDialog.tsx +3 -3
- package/corpus/templates/design/app/components/layout/Header.tsx +4 -4
- package/corpus/templates/design/app/components/layout/Layout.tsx +4 -5
- package/corpus/templates/design/app/components/layout/Sidebar.tsx +4 -6
- package/corpus/templates/design/app/components/visual-editor/CanvasCommentPins.tsx +1 -1
- package/corpus/templates/design/app/components/visual-editor/DrawOverlay.tsx +1 -1
- package/corpus/templates/design/app/components/visual-editor/NodeRewriteProposal.tsx +2 -2
- package/corpus/templates/design/app/components/visual-editor/ReviewCanvasPins.tsx +3 -4
- package/corpus/templates/design/app/components/visual-editor/SaveStatusIndicator.tsx +1 -1
- package/corpus/templates/design/app/hooks/use-agent-generating.ts +1 -1
- package/corpus/templates/design/app/hooks/use-design-system.ts +1 -1
- package/corpus/templates/design/app/hooks/use-design-systems.ts +1 -1
- package/corpus/templates/design/app/hooks/use-navigation-state.ts +2 -2
- package/corpus/templates/design/app/hooks/use-question-flow.ts +1 -1
- package/corpus/templates/design/app/i18n/index.ts +1 -1
- package/corpus/templates/design/app/i18n-data.ts +1 -1
- package/corpus/templates/design/app/i18n-keyboard-shortcuts.ts +1 -1
- package/corpus/templates/design/app/lib/agent-chat.ts +1 -1
- package/corpus/templates/design/app/lib/design-save-outbox.ts +1 -1
- package/corpus/templates/design/app/lib/desktop-design-preview.ts +1 -1
- package/corpus/templates/design/app/lib/figma-connection.ts +2 -1
- package/corpus/templates/design/app/lib/figma-svg-copy.ts +1 -1
- package/corpus/templates/design/app/lib/pending-generation.ts +1 -1
- package/corpus/templates/design/app/lib/utils.ts +1 -1
- package/corpus/templates/design/app/pages/DesignSystemSetup.tsx +4 -6
- package/corpus/templates/design/app/pages/DesignSystems.tsx +4 -4
- package/corpus/templates/design/app/pages/Index.tsx +5 -5
- package/corpus/templates/design/app/pages/NotFound.tsx +3 -5
- package/corpus/templates/design/app/pages/Present.tsx +7 -6
- package/corpus/templates/design/app/pages/Templates.tsx +4 -4
- package/corpus/templates/design/app/pages/VisualEdit.tsx +3 -1
- package/corpus/templates/design/app/pages/design-editor/editor-session.ts +1 -1
- package/corpus/templates/design/app/pages/design-editor/generation-prompt-directives.ts +1 -1
- package/corpus/templates/design/app/root.tsx +10 -9
- package/corpus/templates/design/app/routes/agent.tsx +2 -1
- package/corpus/templates/design/app/routes/observability.tsx +1 -1
- package/corpus/templates/design/app/routes/settings.tsx +4 -5
- package/corpus/templates/dispatch/.agents/skills/actions/SKILL.md +3 -3
- package/corpus/templates/dispatch/.agents/skills/delegate-to-agent/SKILL.md +3 -3
- package/corpus/templates/dispatch/.agents/skills/feature-flags/SKILL.md +1 -1
- package/corpus/templates/dispatch/.agents/skills/upgrade-agent-native/SKILL.md +12 -5
- package/corpus/templates/dispatch/app/hooks/use-navigation-state.ts +3 -4
- package/corpus/templates/dispatch/app/i18n/index.ts +1 -1
- package/corpus/templates/dispatch/app/i18n-data.ts +1 -1
- package/corpus/templates/dispatch/app/root.tsx +10 -9
- package/corpus/templates/dispatch/app/routes/agent.tsx +2 -1
- package/corpus/templates/dispatch/app/routes/integrations.tsx +3 -3
- package/corpus/templates/dispatch/app/routes/settings.tsx +4 -5
- package/corpus/templates/forms/.agents/skills/actions/SKILL.md +3 -3
- package/corpus/templates/forms/.agents/skills/delegate-to-agent/SKILL.md +3 -3
- package/corpus/templates/forms/.agents/skills/feature-flags/SKILL.md +1 -1
- package/corpus/templates/forms/.agents/skills/real-time-sync/SKILL.md +4 -4
- package/corpus/templates/forms/.agents/skills/storing-data/SKILL.md +1 -1
- package/corpus/templates/forms/.agents/skills/upgrade-agent-native/SKILL.md +12 -5
- package/corpus/templates/forms/app/components/CloudUpgrade.tsx +1 -1
- package/corpus/templates/forms/app/components/ThemeToggle.tsx +1 -1
- package/corpus/templates/forms/app/components/builder/FieldPropertiesPanel.tsx +1 -1
- package/corpus/templates/forms/app/components/layout/Header.tsx +2 -1
- package/corpus/templates/forms/app/components/layout/Layout.tsx +2 -2
- package/corpus/templates/forms/app/components/layout/Sidebar.tsx +5 -5
- package/corpus/templates/forms/app/hooks/use-db-status.ts +1 -1
- package/corpus/templates/forms/app/hooks/use-forms.ts +2 -2
- package/corpus/templates/forms/app/hooks/use-navigation-state.ts +3 -3
- package/corpus/templates/forms/app/hooks/use-responses.ts +1 -1
- package/corpus/templates/forms/app/i18n/index.ts +1 -1
- package/corpus/templates/forms/app/lib/utils.ts +1 -1
- package/corpus/templates/forms/app/pages/AskPage.tsx +2 -2
- package/corpus/templates/forms/app/pages/FormBuilderPage.tsx +5 -6
- package/corpus/templates/forms/app/pages/FormFillPage.tsx +2 -1
- package/corpus/templates/forms/app/pages/FormsListPage.tsx +3 -6
- package/corpus/templates/forms/app/pages/ResponseInsightsPage.tsx +1 -1
- package/corpus/templates/forms/app/pages/ResponsesPage.tsx +1 -1
- package/corpus/templates/forms/app/root.tsx +15 -12
- package/corpus/templates/forms/app/routes/_app.agent.tsx +2 -1
- package/corpus/templates/forms/app/routes/_app.settings.tsx +4 -5
- package/corpus/templates/forms/app/routes/_index.tsx +1 -1
- package/corpus/templates/forms/app/routes/form-preview.tsx +5 -1
- package/corpus/templates/macros/.agents/skills/feature-flags/SKILL.md +1 -1
- package/corpus/templates/macros/.agents/skills/upgrade-agent-native/SKILL.md +12 -5
- package/corpus/templates/macros/app/components/AddExerciseDialog.tsx +2 -1
- package/corpus/templates/macros/app/components/AddMealDialog.tsx +2 -1
- package/corpus/templates/macros/app/components/AddWeightDialog.tsx +2 -1
- package/corpus/templates/macros/app/components/DailyProgress.tsx +2 -1
- package/corpus/templates/macros/app/components/ExerciseCard.tsx +1 -1
- package/corpus/templates/macros/app/components/MealCard.tsx +1 -1
- package/corpus/templates/macros/app/components/QueryErrorState.tsx +1 -1
- package/corpus/templates/macros/app/components/VoiceDictation.tsx +2 -1
- package/corpus/templates/macros/app/components/WeeklyCaloriesChart.tsx +1 -1
- package/corpus/templates/macros/app/components/WeightCard.tsx +1 -1
- package/corpus/templates/macros/app/components/WeightTracker.tsx +2 -2
- package/corpus/templates/macros/app/components/layout/AppLayout.tsx +5 -8
- package/corpus/templates/macros/app/components/layout/Header.tsx +2 -1
- package/corpus/templates/macros/app/i18n/index.ts +1 -1
- package/corpus/templates/macros/app/lib/api.ts +1 -1
- package/corpus/templates/macros/app/lib/utils.ts +1 -1
- package/corpus/templates/macros/app/root.tsx +10 -9
- package/corpus/templates/macros/app/routes/_index.tsx +2 -2
- package/corpus/templates/macros/app/routes/agent.tsx +2 -1
- package/corpus/templates/macros/app/routes/analytics.tsx +2 -1
- package/corpus/templates/macros/app/routes/settings.tsx +4 -5
- package/corpus/templates/mail/.agents/skills/actions/SKILL.md +3 -3
- package/corpus/templates/mail/.agents/skills/delegate-to-agent/SKILL.md +3 -3
- package/corpus/templates/mail/.agents/skills/feature-flags/SKILL.md +1 -1
- package/corpus/templates/mail/.agents/skills/real-time-sync/SKILL.md +4 -4
- package/corpus/templates/mail/.agents/skills/storing-data/SKILL.md +1 -1
- package/corpus/templates/mail/.agents/skills/upgrade-agent-native/SKILL.md +12 -5
- package/corpus/templates/mail/app/components/GoogleConnectBanner.tsx +3 -3
- package/corpus/templates/mail/app/components/ThemeToggle.tsx +1 -1
- package/corpus/templates/mail/app/components/agent-engine-picker.tsx +2 -1
- package/corpus/templates/mail/app/components/email/AttachmentStrip.tsx +1 -1
- package/corpus/templates/mail/app/components/email/CodeBlockLangPicker.tsx +1 -1
- package/corpus/templates/mail/app/components/email/ComposeBubbleToolbar.tsx +1 -1
- package/corpus/templates/mail/app/components/email/ComposeEditor.tsx +1 -1
- package/corpus/templates/mail/app/components/email/ComposeModal.tsx +2 -1
- package/corpus/templates/mail/app/components/email/ComposeSlashMenu.tsx +1 -1
- package/corpus/templates/mail/app/components/email/EmailList.tsx +1 -1
- package/corpus/templates/mail/app/components/email/EmailListItem.tsx +1 -1
- package/corpus/templates/mail/app/components/email/EmailThread.tsx +2 -1
- package/corpus/templates/mail/app/components/email/InlineReplyComposer.tsx +2 -1
- package/corpus/templates/mail/app/components/email/IntegrationsSidebar.tsx +2 -1
- package/corpus/templates/mail/app/components/email/MobileActionBar.tsx +1 -1
- package/corpus/templates/mail/app/components/email/RecipientInput.tsx +1 -1
- package/corpus/templates/mail/app/components/email/SendLaterButton.tsx +1 -1
- package/corpus/templates/mail/app/components/email/SnoozeModal.tsx +1 -1
- package/corpus/templates/mail/app/components/email/SnoozePopover.tsx +1 -1
- package/corpus/templates/mail/app/components/email/extensions/ComposeImageBlock.tsx +1 -1
- package/corpus/templates/mail/app/components/layout/AppLayout.tsx +6 -6
- package/corpus/templates/mail/app/components/layout/CommandPalette.tsx +2 -1
- package/corpus/templates/mail/app/components/layout/SearchBar.tsx +1 -1
- package/corpus/templates/mail/app/components/settings/GmailFiltersSection.tsx +1 -1
- package/corpus/templates/mail/app/components/settings/SnippetsSection.tsx +1 -1
- package/corpus/templates/mail/app/entry.client.tsx +1 -6
- package/corpus/templates/mail/app/hooks/use-aliases.ts +1 -1
- package/corpus/templates/mail/app/hooks/use-apollo.ts +1 -1
- package/corpus/templates/mail/app/hooks/use-automations.ts +1 -1
- package/corpus/templates/mail/app/hooks/use-compose-state.ts +2 -2
- package/corpus/templates/mail/app/hooks/use-draft-queue.ts +4 -1
- package/corpus/templates/mail/app/hooks/use-emails.ts +3 -1
- package/corpus/templates/mail/app/hooks/use-gmail-filters.ts +1 -1
- package/corpus/templates/mail/app/hooks/use-google-auth.ts +2 -1
- package/corpus/templates/mail/app/hooks/use-integrations.ts +2 -2
- package/corpus/templates/mail/app/hooks/use-navigation-state.ts +1 -1
- package/corpus/templates/mail/app/hooks/use-scheduled-jobs.ts +2 -2
- package/corpus/templates/mail/app/hooks/use-snippets.ts +1 -1
- package/corpus/templates/mail/app/i18n/index.ts +1 -1
- package/corpus/templates/mail/app/lib/agent-generate.ts +1 -1
- package/corpus/templates/mail/app/lib/gmail-mutation-queue.ts +1 -10
- package/corpus/templates/mail/app/lib/mcp-chat-bridge.ts +1 -1
- package/corpus/templates/mail/app/lib/thread-cache.ts +1 -1
- package/corpus/templates/mail/app/lib/upload.ts +1 -1
- package/corpus/templates/mail/app/lib/utils.ts +1 -1
- package/corpus/templates/mail/app/pages/DraftQueuePage.tsx +1 -1
- package/corpus/templates/mail/app/pages/InboxPage.tsx +1 -1
- package/corpus/templates/mail/app/pages/NotFound.tsx +1 -1
- package/corpus/templates/mail/app/pages/SettingsPage.tsx +9 -8
- package/corpus/templates/mail/app/root.tsx +11 -8
- package/corpus/templates/mail/app/routes/agent.tsx +2 -1
- package/corpus/templates/mail/app/routes/email.tsx +5 -1
- package/corpus/templates/plan/.agents/skills/actions/SKILL.md +3 -3
- package/corpus/templates/plan/.agents/skills/adding-a-feature/SKILL.md +1 -1
- package/corpus/templates/plan/.agents/skills/delegate-to-agent/SKILL.md +3 -3
- package/corpus/templates/plan/.agents/skills/feature-flags/SKILL.md +1 -1
- package/corpus/templates/plan/.agents/skills/real-time-sync/SKILL.md +4 -4
- package/corpus/templates/plan/.agents/skills/upgrade-agent-native/SKILL.md +12 -5
- package/corpus/templates/plan/app/components/editor/PlanBlockNode.tsx +2 -2
- package/corpus/templates/plan/app/components/editor/PlanDocumentEditor.tsx +3 -3
- package/corpus/templates/plan/app/components/editor/planSlashCommands.ts +1 -1
- package/corpus/templates/plan/app/components/layout/Header.tsx +2 -1
- package/corpus/templates/plan/app/components/layout/Layout.tsx +2 -2
- package/corpus/templates/plan/app/components/layout/Sidebar.tsx +8 -9
- package/corpus/templates/plan/app/components/plan/CanvasArea.tsx +1 -1
- package/corpus/templates/plan/app/components/plan/DocumentArea.tsx +3 -5
- package/corpus/templates/plan/app/components/plan/GuestModeBanner.tsx +1 -1
- package/corpus/templates/plan/app/components/plan/LocalCodebasePicker.tsx +2 -1
- package/corpus/templates/plan/app/components/plan/PlanContentRenderer.tsx +7 -5
- package/corpus/templates/plan/app/components/plan/PlanImageNode.tsx +2 -1
- package/corpus/templates/plan/app/components/plan/PlanImageViewer.tsx +1 -1
- package/corpus/templates/plan/app/components/plan/PlanMarkdownEditor.tsx +3 -3
- package/corpus/templates/plan/app/components/plan/PlanMarkdownReader.tsx +1 -1
- package/corpus/templates/plan/app/components/plan/PlanTableOfContents.tsx +1 -1
- package/corpus/templates/plan/app/components/plan/PlanVisualSurface.tsx +1 -1
- package/corpus/templates/plan/app/components/plan/PrototypeViewer.tsx +1 -1
- package/corpus/templates/plan/app/components/plan/VisualAnswerInline.tsx +1 -1
- package/corpus/templates/plan/app/components/plan/planBlocks.tsx +3 -5
- package/corpus/templates/plan/app/components/plan/wireframe/LegacyRegionWireframe.tsx +1 -1
- package/corpus/templates/plan/app/components/plan/wireframe/Wireframe.tsx +1 -1
- package/corpus/templates/plan/app/hooks/use-navigation-state.ts +5 -3
- package/corpus/templates/plan/app/hooks/use-plan-presence.ts +2 -2
- package/corpus/templates/plan/app/hooks/use-plans.ts +4 -1
- package/corpus/templates/plan/app/i18n/ar-SA.ts +4 -0
- package/corpus/templates/plan/app/i18n/de-DE.ts +4 -0
- package/corpus/templates/plan/app/i18n/en-US.ts +4 -0
- package/corpus/templates/plan/app/i18n/es-ES.ts +4 -0
- package/corpus/templates/plan/app/i18n/fr-FR.ts +4 -0
- package/corpus/templates/plan/app/i18n/hi-IN.ts +4 -0
- package/corpus/templates/plan/app/i18n/index.ts +1 -1
- package/corpus/templates/plan/app/i18n/ja-JP.ts +4 -0
- package/corpus/templates/plan/app/i18n/ko-KR.ts +4 -0
- package/corpus/templates/plan/app/i18n/pt-BR.ts +4 -0
- package/corpus/templates/plan/app/i18n/zh-CN.ts +4 -0
- package/corpus/templates/plan/app/i18n/zh-TW.ts +4 -0
- package/corpus/templates/plan/app/lib/local-codebase-context.ts +1 -1
- package/corpus/templates/plan/app/lib/local-control-resources.ts +1 -1
- package/corpus/templates/plan/app/lib/plan-comment-editor-helpers.ts +1 -1
- package/corpus/templates/plan/app/lib/plan-local-bridge.ts +1 -1
- package/corpus/templates/plan/app/lib/register-chat-renderers.tsx +1 -1
- package/corpus/templates/plan/app/lib/utils.ts +1 -1
- package/corpus/templates/plan/app/pages/PlanChatPage.tsx +2 -2
- package/corpus/templates/plan/app/pages/PlansPage.tsx +13 -14
- package/corpus/templates/plan/app/root.tsx +11 -10
- package/corpus/templates/plan/app/routes/agent.tsx +2 -1
- package/corpus/templates/plan/app/routes/settings.tsx +4 -5
- package/corpus/templates/plan/shared/plan-doc.ts +2 -47
- package/corpus/templates/slides/.agents/skills/actions/SKILL.md +3 -3
- package/corpus/templates/slides/.agents/skills/delegate-to-agent/SKILL.md +3 -3
- package/corpus/templates/slides/.agents/skills/feature-flags/SKILL.md +1 -1
- package/corpus/templates/slides/.agents/skills/upgrade-agent-native/SKILL.md +12 -5
- package/corpus/templates/slides/app/components/CloudUpgrade.tsx +1 -1
- package/corpus/templates/slides/app/components/ThemeToggle.tsx +1 -1
- package/corpus/templates/slides/app/components/comments/SlideCommentsPanel.tsx +1 -1
- package/corpus/templates/slides/app/components/deck/DeckCard.tsx +2 -1
- package/corpus/templates/slides/app/components/deck/SlideRenderer.tsx +1 -1
- package/corpus/templates/slides/app/components/design-system/DesignSystemCard.tsx +2 -1
- package/corpus/templates/slides/app/components/design-system/DesignSystemPreview.tsx +1 -1
- package/corpus/templates/slides/app/components/design-system/DesignSystemSetup.tsx +5 -5
- package/corpus/templates/slides/app/components/editor/AnimationsPanel.tsx +1 -1
- package/corpus/templates/slides/app/components/editor/AssetLibraryPanel.tsx +2 -1
- package/corpus/templates/slides/app/components/editor/BlockBubbleMenu.tsx +1 -1
- package/corpus/templates/slides/app/components/editor/EditorSidebar.tsx +6 -6
- package/corpus/templates/slides/app/components/editor/EditorToolbar.tsx +6 -8
- package/corpus/templates/slides/app/components/editor/ExportMenu.tsx +2 -1
- package/corpus/templates/slides/app/components/editor/GenerateSlidesDialog.tsx +2 -1
- package/corpus/templates/slides/app/components/editor/GeneratingOverlay.tsx +1 -1
- package/corpus/templates/slides/app/components/editor/GoogleDocImportHint.tsx +3 -5
- package/corpus/templates/slides/app/components/editor/HistoryPanel.tsx +1 -1
- package/corpus/templates/slides/app/components/editor/ImageDropPromptPopover.tsx +3 -1
- package/corpus/templates/slides/app/components/editor/ImageGenPanel.tsx +1 -1
- package/corpus/templates/slides/app/components/editor/ImageOverlay.tsx +1 -1
- package/corpus/templates/slides/app/components/editor/ImageSearchPanel.tsx +2 -1
- package/corpus/templates/slides/app/components/editor/ImportButton.tsx +5 -1
- package/corpus/templates/slides/app/components/editor/LogoSearchPanel.tsx +2 -1
- package/corpus/templates/slides/app/components/editor/MermaidToExcalidrawPanel.tsx +1 -1
- package/corpus/templates/slides/app/components/editor/PromptDialog.tsx +3 -1
- package/corpus/templates/slides/app/components/editor/QuestionFlow.tsx +1 -1
- package/corpus/templates/slides/app/components/editor/ShareDialog.tsx +2 -1
- package/corpus/templates/slides/app/components/editor/SlideBubbleMenu.tsx +1 -1
- package/corpus/templates/slides/app/components/editor/SlideEditor.tsx +12 -8
- package/corpus/templates/slides/app/components/editor/SlideInlineEditor.tsx +2 -1
- package/corpus/templates/slides/app/components/editor/SlideSlashMenu.tsx +1 -1
- package/corpus/templates/slides/app/components/editor/SlideStyleInspector.tsx +1 -1
- package/corpus/templates/slides/app/components/editor/SpeakerNotesPanel.tsx +1 -1
- package/corpus/templates/slides/app/components/editor/TweaksPanel.tsx +1 -1
- package/corpus/templates/slides/app/components/layout/AgentWorkIndicator.tsx +2 -1
- package/corpus/templates/slides/app/components/layout/Header.tsx +2 -1
- package/corpus/templates/slides/app/components/layout/Layout.tsx +2 -1
- package/corpus/templates/slides/app/components/layout/Sidebar.tsx +4 -6
- package/corpus/templates/slides/app/components/presentation/PresentationView.tsx +1 -1
- package/corpus/templates/slides/app/components/visual-editor/CanvasCommentPins.tsx +2 -1
- package/corpus/templates/slides/app/components/visual-editor/DrawOverlay.tsx +1 -1
- package/corpus/templates/slides/app/components/visual-editor/MultiSelectChip.tsx +1 -1
- package/corpus/templates/slides/app/components/visual-editor/SaveStatusIndicator.tsx +1 -1
- package/corpus/templates/slides/app/context/DeckContext.tsx +5 -3
- package/corpus/templates/slides/app/entry.client.tsx +2 -4
- package/corpus/templates/slides/app/hooks/use-agent-generating.ts +1 -1
- package/corpus/templates/slides/app/hooks/use-db-status.ts +1 -1
- package/corpus/templates/slides/app/hooks/use-deck-design-system.ts +1 -1
- package/corpus/templates/slides/app/hooks/use-deck-presence.ts +1 -1
- package/corpus/templates/slides/app/hooks/use-deck-role.ts +1 -1
- package/corpus/templates/slides/app/hooks/use-deck-versions.ts +4 -1
- package/corpus/templates/slides/app/hooks/use-design-systems.ts +1 -1
- package/corpus/templates/slides/app/hooks/use-navigation-state.ts +1 -1
- package/corpus/templates/slides/app/hooks/use-slide-comments.ts +2 -2
- package/corpus/templates/slides/app/i18n/index.ts +1 -1
- package/corpus/templates/slides/app/lib/utils.ts +1 -1
- package/corpus/templates/slides/app/pages/DeckEditor.tsx +5 -6
- package/corpus/templates/slides/app/pages/DesignSystems.tsx +2 -1
- package/corpus/templates/slides/app/pages/Index.tsx +4 -7
- package/corpus/templates/slides/app/pages/NotFound.tsx +1 -1
- package/corpus/templates/slides/app/pages/Presentation.tsx +1 -1
- package/corpus/templates/slides/app/pages/SharedPresentation.tsx +2 -1
- package/corpus/templates/slides/app/root.tsx +13 -11
- package/corpus/templates/slides/app/routes/agent.tsx +2 -1
- package/corpus/templates/slides/app/routes/settings.tsx +4 -5
- package/corpus/templates/slides/app/routes/slide.tsx +3 -3
- package/corpus/templates/tasks/.agents/skills/actions/SKILL.md +3 -3
- package/corpus/templates/tasks/.agents/skills/adding-a-feature/SKILL.md +1 -1
- package/corpus/templates/tasks/.agents/skills/delegate-to-agent/SKILL.md +3 -3
- package/corpus/templates/tasks/.agents/skills/feature-flags/SKILL.md +1 -1
- package/corpus/templates/tasks/.agents/skills/real-time-sync/SKILL.md +4 -4
- package/corpus/templates/tasks/.agents/skills/upgrade-agent-native/SKILL.md +12 -5
- package/corpus/templates/tasks/app/components/custom-fields/FieldsList.tsx +1 -1
- package/corpus/templates/tasks/app/components/layout/Header.tsx +1 -1
- package/corpus/templates/tasks/app/components/layout/Layout.tsx +4 -1
- package/corpus/templates/tasks/app/components/layout/Sidebar.tsx +2 -1
- package/corpus/templates/tasks/app/components/shared/ListViewHeader.tsx +1 -1
- package/corpus/templates/tasks/app/components/tasks/TaskList.tsx +1 -1
- package/corpus/templates/tasks/app/hooks/use-custom-fields.ts +4 -1
- package/corpus/templates/tasks/app/hooks/use-inbox-items.ts +4 -1
- package/corpus/templates/tasks/app/hooks/use-navigation-state.ts +2 -1
- package/corpus/templates/tasks/app/hooks/use-tasks.ts +4 -1
- package/corpus/templates/tasks/app/hooks/use-visible-task-fields.ts +4 -1
- package/corpus/templates/tasks/app/lib/utils.ts +1 -1
- package/corpus/templates/tasks/app/root.tsx +9 -7
- package/dist/cli/doctor.d.ts +4 -1
- package/dist/cli/doctor.d.ts.map +1 -1
- package/dist/cli/doctor.js +57 -5
- package/dist/cli/doctor.js.map +1 -1
- package/dist/cli/migration-codemod.d.ts +21 -0
- package/dist/cli/migration-codemod.d.ts.map +1 -0
- package/dist/cli/migration-codemod.js +363 -0
- package/dist/cli/migration-codemod.js.map +1 -0
- package/dist/cli/upgrade.d.ts +7 -0
- package/dist/cli/upgrade.d.ts.map +1 -1
- package/dist/cli/upgrade.js +52 -7
- package/dist/cli/upgrade.js.map +1 -1
- package/dist/client/agent-chat/index.d.ts +40 -0
- package/dist/client/agent-chat/index.d.ts.map +1 -0
- package/dist/client/agent-chat/index.js +39 -0
- package/dist/client/agent-chat/index.js.map +1 -0
- package/dist/client/agent-page/AgentContextTab.d.ts.map +1 -1
- package/dist/client/agent-page/AgentContextTab.js +3 -1
- package/dist/client/agent-page/AgentContextTab.js.map +1 -1
- package/dist/client/analytics/index.d.ts +3 -0
- package/dist/client/analytics/index.d.ts.map +1 -0
- package/dist/client/analytics/index.js +3 -0
- package/dist/client/analytics/index.js.map +1 -0
- package/dist/client/api-path.js +2 -2
- package/dist/client/api-path.js.map +1 -1
- package/dist/client/automation/index.d.ts +2 -0
- package/dist/client/automation/index.d.ts.map +1 -0
- package/dist/client/automation/index.js +2 -0
- package/dist/client/automation/index.js.map +1 -0
- package/dist/client/changelog/index.d.ts +2 -0
- package/dist/client/changelog/index.d.ts.map +1 -0
- package/dist/client/changelog/index.js +2 -0
- package/dist/client/changelog/index.js.map +1 -0
- package/dist/client/chat/widgets/InlineExtensionWidget.d.ts +1 -12
- package/dist/client/chat/widgets/InlineExtensionWidget.d.ts.map +1 -1
- package/dist/client/chat/widgets/InlineExtensionWidget.js +2 -66
- package/dist/client/chat/widgets/InlineExtensionWidget.js.map +1 -1
- package/dist/client/chat/widgets/builtin-tool-renderers.d.ts.map +1 -1
- package/dist/client/chat/widgets/builtin-tool-renderers.js +21 -8
- package/dist/client/chat/widgets/builtin-tool-renderers.js.map +1 -1
- package/dist/client/chat/widgets/inline-extension-result.d.ts +14 -0
- package/dist/client/chat/widgets/inline-extension-result.d.ts.map +1 -0
- package/dist/client/chat/widgets/inline-extension-result.js +67 -0
- package/dist/client/chat/widgets/inline-extension-result.js.map +1 -0
- package/dist/client/client-bootstrap.d.ts +2 -0
- package/dist/client/client-bootstrap.d.ts.map +1 -0
- package/dist/client/client-bootstrap.js +7 -0
- package/dist/client/client-bootstrap.js.map +1 -0
- package/dist/client/context-xray/ContextXRayPanel.js +1 -1
- package/dist/client/context-xray/ContextXRayPanel.js.map +1 -1
- package/dist/client/hooks/index.d.ts +13 -0
- package/dist/client/hooks/index.d.ts.map +1 -0
- package/dist/client/hooks/index.js +13 -0
- package/dist/client/hooks/index.js.map +1 -0
- package/dist/client/host/index.d.ts +20 -0
- package/dist/client/host/index.d.ts.map +1 -0
- package/dist/client/host/index.js +18 -0
- package/dist/client/host/index.js.map +1 -0
- package/dist/client/index.d.ts +19 -100
- package/dist/client/index.d.ts.map +1 -1
- package/dist/client/index.js +19 -106
- package/dist/client/index.js.map +1 -1
- package/dist/client/navigation/index.d.ts +6 -0
- package/dist/client/navigation/index.d.ts.map +1 -0
- package/dist/client/navigation/index.js +6 -0
- package/dist/client/navigation/index.js.map +1 -0
- package/dist/client/resources/ResourcesPanel.d.ts.map +1 -1
- package/dist/client/resources/ResourcesPanel.js +2 -1
- package/dist/client/resources/ResourcesPanel.js.map +1 -1
- package/dist/client/resources/index.d.ts +2 -1
- package/dist/client/resources/index.d.ts.map +1 -1
- package/dist/client/resources/index.js +1 -0
- package/dist/client/resources/index.js.map +1 -1
- package/dist/client/resources/use-resources.d.ts +0 -1
- package/dist/client/resources/use-resources.d.ts.map +1 -1
- package/dist/client/resources/use-resources.js +0 -17
- package/dist/client/resources/use-resources.js.map +1 -1
- package/dist/client/route-chunk-recovery/index.d.ts +2 -0
- package/dist/client/route-chunk-recovery/index.d.ts.map +1 -0
- package/dist/client/route-chunk-recovery/index.js +2 -0
- package/dist/client/route-chunk-recovery/index.js.map +1 -0
- package/dist/client/ui/index.d.ts +18 -0
- package/dist/client/ui/index.d.ts.map +1 -0
- package/dist/client/ui/index.js +18 -0
- package/dist/client/ui/index.js.map +1 -0
- package/dist/client/uploads/index.d.ts +2 -0
- package/dist/client/uploads/index.d.ts.map +1 -0
- package/dist/client/uploads/index.js +2 -0
- package/dist/client/uploads/index.js.map +1 -0
- package/dist/client/uploads/use-upload-resource.d.ts +3 -0
- package/dist/client/uploads/use-upload-resource.d.ts.map +1 -0
- package/dist/client/uploads/use-upload-resource.js +20 -0
- package/dist/client/uploads/use-upload-resource.js.map +1 -0
- package/dist/client/widgets/index.d.ts +3 -0
- package/dist/client/widgets/index.d.ts.map +1 -0
- package/dist/client/widgets/index.js +3 -0
- package/dist/client/widgets/index.js.map +1 -0
- 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/localization/default-messages.d.ts +2 -1
- package/dist/localization/default-messages.d.ts.map +1 -1
- package/dist/localization/default-messages.js +2 -1
- package/dist/localization/default-messages.js.map +1 -1
- package/dist/notifications/routes.d.ts +3 -3
- package/dist/observability/routes.d.ts +1 -1
- package/dist/package-lifecycle/deprecated-imports.d.ts +15 -0
- package/dist/package-lifecycle/deprecated-imports.d.ts.map +1 -0
- package/dist/package-lifecycle/deprecated-imports.js +141 -0
- package/dist/package-lifecycle/deprecated-imports.js.map +1 -0
- package/dist/package-lifecycle/index.d.ts +5 -0
- package/dist/package-lifecycle/index.d.ts.map +1 -1
- package/dist/package-lifecycle/index.js +5 -0
- package/dist/package-lifecycle/index.js.map +1 -1
- package/dist/package-lifecycle/migration-manifest.d.ts +28 -0
- package/dist/package-lifecycle/migration-manifest.d.ts.map +1 -0
- package/dist/package-lifecycle/migration-manifest.js +102 -0
- package/dist/package-lifecycle/migration-manifest.js.map +1 -0
- package/dist/package-lifecycle/migration-message.d.ts +3 -0
- package/dist/package-lifecycle/migration-message.d.ts.map +1 -0
- package/dist/package-lifecycle/migration-message.js +5 -0
- package/dist/package-lifecycle/migration-message.js.map +1 -0
- package/dist/package-lifecycle/tombstone.d.ts +10 -0
- package/dist/package-lifecycle/tombstone.d.ts.map +1 -0
- package/dist/package-lifecycle/tombstone.js +23 -0
- package/dist/package-lifecycle/tombstone.js.map +1 -0
- package/dist/package-lifecycle/upgrade-error.d.ts +11 -0
- package/dist/package-lifecycle/upgrade-error.d.ts.map +1 -0
- package/dist/package-lifecycle/upgrade-error.js +11 -0
- package/dist/package-lifecycle/upgrade-error.js.map +1 -0
- package/dist/progress/routes.d.ts +1 -1
- package/dist/resources/handlers.d.ts +1 -1
- package/dist/secrets/routes.d.ts +9 -9
- package/dist/server/agent-engine-api-key-route.d.ts +1 -1
- package/dist/server/transcribe-voice.d.ts +1 -1
- package/dist/templates/chat/.agents/skills/actions/SKILL.md +3 -3
- package/dist/templates/chat/.agents/skills/adding-a-feature/SKILL.md +1 -1
- package/dist/templates/chat/.agents/skills/delegate-to-agent/SKILL.md +3 -3
- package/dist/templates/chat/.agents/skills/feature-flags/SKILL.md +1 -1
- package/dist/templates/chat/.agents/skills/real-time-sync/SKILL.md +4 -4
- package/dist/templates/chat/.agents/skills/upgrade-agent-native/SKILL.md +12 -5
- package/dist/templates/chat/app/components/layout/Header.tsx +2 -1
- package/dist/templates/chat/app/components/layout/Layout.tsx +2 -2
- package/dist/templates/chat/app/components/layout/Sidebar.tsx +4 -4
- package/dist/templates/chat/app/hooks/use-navigation-state.ts +3 -4
- package/dist/templates/chat/app/i18n/index.ts +1 -1
- package/dist/templates/chat/app/i18n-data.ts +1 -1
- package/dist/templates/chat/app/lib/utils.ts +1 -1
- package/dist/templates/chat/app/root.tsx +10 -9
- package/dist/templates/chat/app/routes/_index.tsx +2 -2
- package/dist/templates/chat/app/routes/agent.tsx +10 -3
- package/dist/templates/chat/app/routes/database.tsx +1 -1
- package/dist/templates/chat/app/routes/observability.tsx +2 -1
- package/dist/templates/chat/app/routes/settings.tsx +4 -5
- package/dist/templates/default/.agents/skills/actions/SKILL.md +3 -3
- package/dist/templates/default/.agents/skills/adding-a-feature/SKILL.md +1 -1
- package/dist/templates/default/.agents/skills/delegate-to-agent/SKILL.md +3 -3
- package/dist/templates/default/.agents/skills/feature-flags/SKILL.md +1 -1
- package/dist/templates/default/.agents/skills/real-time-collab/SKILL.md +4 -4
- package/dist/templates/default/.agents/skills/real-time-sync/SKILL.md +4 -4
- package/dist/templates/default/.agents/skills/storing-data/SKILL.md +1 -1
- package/dist/templates/default/.agents/skills/upgrade-agent-native/SKILL.md +12 -5
- package/dist/templates/default/app/hooks/use-navigation-state.ts +2 -5
- package/dist/templates/default/app/i18n/index.ts +1 -1
- package/dist/templates/default/app/lib/utils.ts +1 -1
- package/dist/templates/default/app/root.tsx +8 -6
- package/dist/templates/default/app/routes/_index.tsx +2 -1
- package/dist/templates/default/app/routes/agent.tsx +2 -1
- package/dist/templates/default/app/routes/settings.tsx +2 -3
- package/dist/templates/headless/.agents/skills/feature-flags/SKILL.md +1 -1
- package/dist/templates/headless/.agents/skills/upgrade-agent-native/SKILL.md +12 -5
- package/dist/templates/workspace-core/.agents/skills/actions/SKILL.md +3 -3
- package/dist/templates/workspace-core/.agents/skills/adding-a-feature/SKILL.md +1 -1
- package/dist/templates/workspace-core/.agents/skills/authentication/SKILL.md +1 -1
- package/dist/templates/workspace-core/.agents/skills/changelog/SKILL.md +1 -1
- package/dist/templates/workspace-core/.agents/skills/client-methods/SKILL.md +10 -10
- package/dist/templates/workspace-core/.agents/skills/context-awareness/SKILL.md +1 -1
- package/dist/templates/workspace-core/.agents/skills/delegate-to-agent/SKILL.md +3 -3
- package/dist/templates/workspace-core/.agents/skills/feature-flags/SKILL.md +1 -1
- package/dist/templates/workspace-core/.agents/skills/observability/SKILL.md +1 -1
- package/dist/templates/workspace-core/.agents/skills/real-time-collab/SKILL.md +4 -4
- package/dist/templates/workspace-core/.agents/skills/real-time-sync/SKILL.md +4 -4
- package/dist/templates/workspace-core/.agents/skills/sharing/SKILL.md +1 -1
- package/dist/templates/workspace-core/.agents/skills/storing-data/SKILL.md +1 -1
- package/dist/templates/workspace-core/.agents/skills/upgrade-agent-native/SKILL.md +12 -5
- package/dist/vite/action-types-plugin.d.ts.map +1 -1
- package/dist/vite/action-types-plugin.js +4 -0
- package/dist/vite/action-types-plugin.js.map +1 -1
- package/dist/vite/client.d.ts.map +1 -1
- package/dist/vite/client.js +35 -64
- package/dist/vite/client.js.map +1 -1
- package/docs/content/actions.mdx +2 -4
- package/docs/content/agent-surfaces.mdx +2 -4
- package/docs/content/audit-log.mdx +1 -2
- package/docs/content/authentication.mdx +3 -2
- package/docs/content/client.mdx +19 -18
- package/docs/content/components.mdx +1 -1
- package/docs/content/context-awareness.mdx +4 -7
- package/docs/content/creating-templates.mdx +7 -5
- package/docs/content/doctor.mdx +27 -6
- package/docs/content/drop-in-agent.mdx +6 -11
- package/docs/content/embedding-sdk.mdx +8 -10
- package/docs/content/getting-started.mdx +4 -2
- package/docs/content/internationalization.mdx +9 -6
- package/docs/content/key-concepts.mdx +2 -4
- package/docs/content/locales/ar-SA/actions.mdx +2 -4
- package/docs/content/locales/ar-SA/agent-surfaces.mdx +2 -4
- package/docs/content/locales/ar-SA/audit-log.mdx +1 -2
- package/docs/content/locales/ar-SA/authentication.mdx +3 -2
- package/docs/content/locales/ar-SA/client.mdx +19 -18
- package/docs/content/locales/ar-SA/components.mdx +1 -1
- package/docs/content/locales/ar-SA/context-awareness.mdx +4 -7
- package/docs/content/locales/ar-SA/creating-templates.mdx +7 -5
- package/docs/content/locales/ar-SA/doctor.mdx +10 -0
- package/docs/content/locales/ar-SA/drop-in-agent.mdx +6 -11
- package/docs/content/locales/ar-SA/embedding-sdk.mdx +8 -10
- package/docs/content/locales/ar-SA/internationalization.mdx +9 -6
- package/docs/content/locales/ar-SA/key-concepts.mdx +2 -4
- package/docs/content/locales/ar-SA/observability.mdx +1 -2
- package/docs/content/locales/ar-SA/package-lifecycle.mdx +6 -0
- package/docs/content/locales/ar-SA/real-time-collaboration.mdx +4 -7
- package/docs/content/locales/ar-SA/sharing.mdx +1 -2
- package/docs/content/locales/ar-SA/template-chat.mdx +1 -2
- package/docs/content/locales/ar-SA/tracking.mdx +2 -4
- package/docs/content/locales/ar-SA/what-is-agent-native.mdx +1 -2
- package/docs/content/locales/de-DE/actions.mdx +2 -4
- package/docs/content/locales/de-DE/agent-surfaces.mdx +2 -4
- package/docs/content/locales/de-DE/audit-log.mdx +1 -2
- package/docs/content/locales/de-DE/authentication.mdx +3 -2
- package/docs/content/locales/de-DE/client.mdx +19 -18
- package/docs/content/locales/de-DE/components.mdx +1 -1
- package/docs/content/locales/de-DE/context-awareness.mdx +4 -7
- package/docs/content/locales/de-DE/creating-templates.mdx +7 -5
- package/docs/content/locales/de-DE/doctor.mdx +10 -0
- package/docs/content/locales/de-DE/drop-in-agent.mdx +6 -11
- package/docs/content/locales/de-DE/embedding-sdk.mdx +8 -10
- package/docs/content/locales/de-DE/internationalization.mdx +9 -6
- package/docs/content/locales/de-DE/key-concepts.mdx +2 -4
- package/docs/content/locales/de-DE/observability.mdx +1 -2
- package/docs/content/locales/de-DE/package-lifecycle.mdx +6 -0
- package/docs/content/locales/de-DE/real-time-collaboration.mdx +4 -7
- package/docs/content/locales/de-DE/sharing.mdx +1 -2
- package/docs/content/locales/de-DE/template-chat.mdx +1 -2
- package/docs/content/locales/de-DE/tracking.mdx +2 -4
- package/docs/content/locales/de-DE/what-is-agent-native.mdx +1 -2
- package/docs/content/locales/es-ES/actions.mdx +2 -4
- package/docs/content/locales/es-ES/agent-surfaces.mdx +2 -4
- package/docs/content/locales/es-ES/audit-log.mdx +1 -2
- package/docs/content/locales/es-ES/authentication.mdx +3 -2
- package/docs/content/locales/es-ES/client.mdx +19 -18
- package/docs/content/locales/es-ES/components.mdx +1 -1
- package/docs/content/locales/es-ES/context-awareness.mdx +4 -7
- package/docs/content/locales/es-ES/creating-templates.mdx +7 -5
- package/docs/content/locales/es-ES/doctor.mdx +10 -0
- package/docs/content/locales/es-ES/drop-in-agent.mdx +6 -11
- package/docs/content/locales/es-ES/embedding-sdk.mdx +8 -10
- package/docs/content/locales/es-ES/internationalization.mdx +9 -6
- package/docs/content/locales/es-ES/key-concepts.mdx +2 -4
- package/docs/content/locales/es-ES/observability.mdx +1 -2
- package/docs/content/locales/es-ES/package-lifecycle.mdx +6 -0
- package/docs/content/locales/es-ES/real-time-collaboration.mdx +4 -7
- package/docs/content/locales/es-ES/sharing.mdx +1 -2
- package/docs/content/locales/es-ES/template-chat.mdx +1 -2
- package/docs/content/locales/es-ES/tracking.mdx +2 -4
- package/docs/content/locales/es-ES/what-is-agent-native.mdx +1 -2
- package/docs/content/locales/fr-FR/actions.mdx +2 -4
- package/docs/content/locales/fr-FR/agent-surfaces.mdx +2 -4
- package/docs/content/locales/fr-FR/audit-log.mdx +1 -2
- package/docs/content/locales/fr-FR/authentication.mdx +3 -2
- package/docs/content/locales/fr-FR/client.mdx +19 -18
- package/docs/content/locales/fr-FR/components.mdx +1 -1
- package/docs/content/locales/fr-FR/context-awareness.mdx +4 -7
- package/docs/content/locales/fr-FR/creating-templates.mdx +7 -5
- package/docs/content/locales/fr-FR/doctor.mdx +10 -0
- package/docs/content/locales/fr-FR/drop-in-agent.mdx +6 -11
- package/docs/content/locales/fr-FR/embedding-sdk.mdx +8 -10
- package/docs/content/locales/fr-FR/internationalization.mdx +9 -6
- package/docs/content/locales/fr-FR/key-concepts.mdx +2 -4
- package/docs/content/locales/fr-FR/observability.mdx +1 -2
- package/docs/content/locales/fr-FR/package-lifecycle.mdx +6 -0
- package/docs/content/locales/fr-FR/real-time-collaboration.mdx +4 -7
- package/docs/content/locales/fr-FR/sharing.mdx +1 -2
- package/docs/content/locales/fr-FR/template-chat.mdx +1 -2
- package/docs/content/locales/fr-FR/tracking.mdx +2 -4
- package/docs/content/locales/fr-FR/what-is-agent-native.mdx +1 -2
- package/docs/content/locales/hi-IN/actions.mdx +2 -4
- package/docs/content/locales/hi-IN/agent-surfaces.mdx +2 -4
- package/docs/content/locales/hi-IN/audit-log.mdx +1 -2
- package/docs/content/locales/hi-IN/authentication.mdx +3 -2
- package/docs/content/locales/hi-IN/client.mdx +19 -18
- package/docs/content/locales/hi-IN/components.mdx +1 -1
- package/docs/content/locales/hi-IN/context-awareness.mdx +4 -7
- package/docs/content/locales/hi-IN/creating-templates.mdx +7 -5
- package/docs/content/locales/hi-IN/doctor.mdx +10 -0
- package/docs/content/locales/hi-IN/drop-in-agent.mdx +6 -11
- package/docs/content/locales/hi-IN/embedding-sdk.mdx +8 -10
- package/docs/content/locales/hi-IN/internationalization.mdx +9 -6
- package/docs/content/locales/hi-IN/key-concepts.mdx +2 -4
- package/docs/content/locales/hi-IN/observability.mdx +1 -2
- package/docs/content/locales/hi-IN/package-lifecycle.mdx +6 -0
- package/docs/content/locales/hi-IN/real-time-collaboration.mdx +4 -7
- package/docs/content/locales/hi-IN/sharing.mdx +1 -2
- package/docs/content/locales/hi-IN/template-chat.mdx +1 -2
- package/docs/content/locales/hi-IN/tracking.mdx +2 -4
- package/docs/content/locales/hi-IN/what-is-agent-native.mdx +1 -2
- package/docs/content/locales/ja-JP/actions.mdx +2 -4
- package/docs/content/locales/ja-JP/agent-surfaces.mdx +2 -4
- package/docs/content/locales/ja-JP/audit-log.mdx +1 -2
- package/docs/content/locales/ja-JP/authentication.mdx +3 -2
- package/docs/content/locales/ja-JP/client.mdx +19 -18
- package/docs/content/locales/ja-JP/components.mdx +1 -1
- package/docs/content/locales/ja-JP/context-awareness.mdx +4 -7
- package/docs/content/locales/ja-JP/creating-templates.mdx +7 -5
- package/docs/content/locales/ja-JP/doctor.mdx +10 -0
- package/docs/content/locales/ja-JP/drop-in-agent.mdx +6 -11
- package/docs/content/locales/ja-JP/embedding-sdk.mdx +8 -10
- package/docs/content/locales/ja-JP/internationalization.mdx +9 -6
- package/docs/content/locales/ja-JP/key-concepts.mdx +2 -4
- package/docs/content/locales/ja-JP/observability.mdx +1 -2
- package/docs/content/locales/ja-JP/package-lifecycle.mdx +6 -0
- package/docs/content/locales/ja-JP/real-time-collaboration.mdx +4 -7
- package/docs/content/locales/ja-JP/sharing.mdx +1 -2
- package/docs/content/locales/ja-JP/template-chat.mdx +1 -2
- package/docs/content/locales/ja-JP/tracking.mdx +2 -4
- package/docs/content/locales/ja-JP/what-is-agent-native.mdx +1 -2
- package/docs/content/locales/ko-KR/actions.mdx +2 -4
- package/docs/content/locales/ko-KR/agent-surfaces.mdx +2 -4
- package/docs/content/locales/ko-KR/audit-log.mdx +1 -2
- package/docs/content/locales/ko-KR/authentication.mdx +3 -2
- package/docs/content/locales/ko-KR/client.mdx +19 -18
- package/docs/content/locales/ko-KR/components.mdx +1 -1
- package/docs/content/locales/ko-KR/context-awareness.mdx +4 -7
- package/docs/content/locales/ko-KR/creating-templates.mdx +7 -5
- package/docs/content/locales/ko-KR/doctor.mdx +10 -0
- package/docs/content/locales/ko-KR/drop-in-agent.mdx +6 -11
- package/docs/content/locales/ko-KR/embedding-sdk.mdx +8 -10
- package/docs/content/locales/ko-KR/internationalization.mdx +9 -6
- package/docs/content/locales/ko-KR/key-concepts.mdx +2 -4
- package/docs/content/locales/ko-KR/observability.mdx +1 -2
- package/docs/content/locales/ko-KR/package-lifecycle.mdx +6 -0
- package/docs/content/locales/ko-KR/real-time-collaboration.mdx +4 -7
- package/docs/content/locales/ko-KR/sharing.mdx +1 -2
- package/docs/content/locales/ko-KR/template-chat.mdx +1 -2
- package/docs/content/locales/ko-KR/tracking.mdx +2 -4
- package/docs/content/locales/ko-KR/what-is-agent-native.mdx +1 -2
- package/docs/content/locales/pt-BR/actions.mdx +2 -4
- package/docs/content/locales/pt-BR/agent-surfaces.mdx +2 -4
- package/docs/content/locales/pt-BR/audit-log.mdx +1 -2
- package/docs/content/locales/pt-BR/authentication.mdx +3 -2
- package/docs/content/locales/pt-BR/client.mdx +19 -18
- package/docs/content/locales/pt-BR/components.mdx +1 -1
- package/docs/content/locales/pt-BR/context-awareness.mdx +4 -7
- package/docs/content/locales/pt-BR/creating-templates.mdx +7 -5
- package/docs/content/locales/pt-BR/doctor.mdx +10 -0
- package/docs/content/locales/pt-BR/drop-in-agent.mdx +6 -11
- package/docs/content/locales/pt-BR/embedding-sdk.mdx +8 -10
- package/docs/content/locales/pt-BR/internationalization.mdx +9 -6
- package/docs/content/locales/pt-BR/key-concepts.mdx +2 -4
- package/docs/content/locales/pt-BR/observability.mdx +1 -2
- package/docs/content/locales/pt-BR/package-lifecycle.mdx +6 -0
- package/docs/content/locales/pt-BR/real-time-collaboration.mdx +4 -7
- package/docs/content/locales/pt-BR/sharing.mdx +1 -2
- package/docs/content/locales/pt-BR/template-chat.mdx +1 -2
- package/docs/content/locales/pt-BR/tracking.mdx +2 -4
- package/docs/content/locales/pt-BR/what-is-agent-native.mdx +1 -2
- package/docs/content/locales/zh-CN/actions.mdx +2 -4
- package/docs/content/locales/zh-CN/agent-surfaces.mdx +2 -4
- package/docs/content/locales/zh-CN/audit-log.mdx +1 -2
- package/docs/content/locales/zh-CN/authentication.mdx +3 -2
- package/docs/content/locales/zh-CN/client.mdx +19 -18
- package/docs/content/locales/zh-CN/components.mdx +1 -1
- package/docs/content/locales/zh-CN/context-awareness.mdx +4 -7
- package/docs/content/locales/zh-CN/creating-templates.mdx +7 -5
- package/docs/content/locales/zh-CN/doctor.mdx +10 -0
- package/docs/content/locales/zh-CN/drop-in-agent.mdx +6 -11
- package/docs/content/locales/zh-CN/embedding-sdk.mdx +8 -10
- package/docs/content/locales/zh-CN/internationalization.mdx +9 -6
- package/docs/content/locales/zh-CN/key-concepts.mdx +2 -4
- package/docs/content/locales/zh-CN/observability.mdx +1 -2
- package/docs/content/locales/zh-CN/package-lifecycle.mdx +6 -0
- package/docs/content/locales/zh-CN/real-time-collaboration.mdx +4 -7
- package/docs/content/locales/zh-CN/sharing.mdx +1 -2
- package/docs/content/locales/zh-CN/template-chat.mdx +1 -2
- package/docs/content/locales/zh-CN/tracking.mdx +2 -4
- package/docs/content/locales/zh-CN/what-is-agent-native.mdx +1 -2
- package/docs/content/locales/zh-TW/actions.mdx +2 -4
- package/docs/content/locales/zh-TW/agent-surfaces.mdx +2 -4
- package/docs/content/locales/zh-TW/audit-log.mdx +1 -2
- package/docs/content/locales/zh-TW/authentication.mdx +3 -2
- package/docs/content/locales/zh-TW/client.mdx +19 -18
- package/docs/content/locales/zh-TW/components.mdx +1 -1
- package/docs/content/locales/zh-TW/context-awareness.mdx +4 -7
- package/docs/content/locales/zh-TW/creating-templates.mdx +7 -5
- package/docs/content/locales/zh-TW/doctor.mdx +10 -0
- package/docs/content/locales/zh-TW/drop-in-agent.mdx +6 -11
- package/docs/content/locales/zh-TW/embedding-sdk.mdx +8 -10
- package/docs/content/locales/zh-TW/internationalization.mdx +9 -6
- package/docs/content/locales/zh-TW/key-concepts.mdx +2 -4
- package/docs/content/locales/zh-TW/observability.mdx +1 -2
- package/docs/content/locales/zh-TW/package-lifecycle.mdx +6 -0
- package/docs/content/locales/zh-TW/real-time-collaboration.mdx +4 -7
- package/docs/content/locales/zh-TW/sharing.mdx +1 -2
- package/docs/content/locales/zh-TW/template-chat.mdx +1 -2
- package/docs/content/locales/zh-TW/tracking.mdx +2 -4
- package/docs/content/locales/zh-TW/what-is-agent-native.mdx +1 -2
- package/docs/content/observability.mdx +1 -2
- package/docs/content/package-lifecycle.mdx +29 -0
- package/docs/content/real-time-collaboration.mdx +8 -7
- package/docs/content/sharing.mdx +1 -2
- package/docs/content/template-chat.mdx +1 -2
- package/docs/content/toolkit-agent-ux.mdx +3 -2
- package/docs/content/toolkit-observability.mdx +1 -2
- package/docs/content/toolkit-settings.mdx +2 -2
- package/docs/content/toolkit-sharing.mdx +5 -2
- package/docs/content/tracking.mdx +2 -4
- package/docs/content/what-is-agent-native.mdx +1 -2
- package/migration-manifest.json +1492 -0
- package/package.json +23 -5
- package/src/templates/chat/.agents/skills/actions/SKILL.md +3 -3
- package/src/templates/chat/.agents/skills/adding-a-feature/SKILL.md +1 -1
- package/src/templates/chat/.agents/skills/delegate-to-agent/SKILL.md +3 -3
- package/src/templates/chat/.agents/skills/feature-flags/SKILL.md +1 -1
- package/src/templates/chat/.agents/skills/real-time-sync/SKILL.md +4 -4
- package/src/templates/chat/.agents/skills/upgrade-agent-native/SKILL.md +12 -5
- package/src/templates/chat/app/components/layout/Header.tsx +2 -1
- package/src/templates/chat/app/components/layout/Layout.tsx +2 -2
- package/src/templates/chat/app/components/layout/Sidebar.tsx +4 -4
- package/src/templates/chat/app/hooks/use-navigation-state.ts +3 -4
- package/src/templates/chat/app/i18n/index.ts +1 -1
- package/src/templates/chat/app/i18n-data.ts +1 -1
- package/src/templates/chat/app/lib/utils.ts +1 -1
- package/src/templates/chat/app/root.tsx +10 -9
- package/src/templates/chat/app/routes/_index.tsx +2 -2
- package/src/templates/chat/app/routes/agent.tsx +10 -3
- package/src/templates/chat/app/routes/database.tsx +1 -1
- package/src/templates/chat/app/routes/observability.tsx +2 -1
- package/src/templates/chat/app/routes/settings.tsx +4 -5
- package/src/templates/default/.agents/skills/actions/SKILL.md +3 -3
- package/src/templates/default/.agents/skills/adding-a-feature/SKILL.md +1 -1
- package/src/templates/default/.agents/skills/delegate-to-agent/SKILL.md +3 -3
- package/src/templates/default/.agents/skills/feature-flags/SKILL.md +1 -1
- package/src/templates/default/.agents/skills/real-time-collab/SKILL.md +4 -4
- package/src/templates/default/.agents/skills/real-time-sync/SKILL.md +4 -4
- package/src/templates/default/.agents/skills/storing-data/SKILL.md +1 -1
- package/src/templates/default/.agents/skills/upgrade-agent-native/SKILL.md +12 -5
- package/src/templates/default/app/hooks/use-navigation-state.ts +2 -5
- package/src/templates/default/app/i18n/index.ts +1 -1
- package/src/templates/default/app/lib/utils.ts +1 -1
- package/src/templates/default/app/root.tsx +8 -6
- package/src/templates/default/app/routes/_index.tsx +2 -1
- package/src/templates/default/app/routes/agent.tsx +2 -1
- package/src/templates/default/app/routes/settings.tsx +2 -3
- package/src/templates/headless/.agents/skills/feature-flags/SKILL.md +1 -1
- package/src/templates/headless/.agents/skills/upgrade-agent-native/SKILL.md +12 -5
- package/src/templates/workspace-core/.agents/skills/actions/SKILL.md +3 -3
- package/src/templates/workspace-core/.agents/skills/adding-a-feature/SKILL.md +1 -1
- package/src/templates/workspace-core/.agents/skills/authentication/SKILL.md +1 -1
- package/src/templates/workspace-core/.agents/skills/changelog/SKILL.md +1 -1
- package/src/templates/workspace-core/.agents/skills/client-methods/SKILL.md +10 -10
- package/src/templates/workspace-core/.agents/skills/context-awareness/SKILL.md +1 -1
- package/src/templates/workspace-core/.agents/skills/delegate-to-agent/SKILL.md +3 -3
- package/src/templates/workspace-core/.agents/skills/feature-flags/SKILL.md +1 -1
- package/src/templates/workspace-core/.agents/skills/observability/SKILL.md +1 -1
- package/src/templates/workspace-core/.agents/skills/real-time-collab/SKILL.md +4 -4
- package/src/templates/workspace-core/.agents/skills/real-time-sync/SKILL.md +4 -4
- package/src/templates/workspace-core/.agents/skills/sharing/SKILL.md +1 -1
- package/src/templates/workspace-core/.agents/skills/storing-data/SKILL.md +1 -1
- package/src/templates/workspace-core/.agents/skills/upgrade-agent-native/SKILL.md +12 -5
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"migration-codemod.js","sourceRoot":"","sources":["../../src/cli/migration-codemod.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,SAAS,CAAC;AACzB,OAAO,EAAE,aAAa,EAAE,MAAM,aAAa,CAAC;AAC5C,OAAO,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,CAAC,IAAI,EAAE,MAAM,CAAC,IAAI,CAAC,EAAE;QACzC,OAAO,IAAI,CAAC,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC,IAAI,CAAC,EAAE;QACzC,OAAO,MAAM,GAAG,CAAC,KAAK,MAAM,GAAG,CAAC,KAAK;QACrC,GAAG,aAAa,CAAC,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,IAAI,IAAI,EAAE,CAAC;QAC1C,GAAG,YAAY,CAAC,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,IAAI,IAAI,EAAE,CAAC;KAC1C,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;AACf,CAAC;AAED,MAAM,UAAU,0BAA0B,CACxC,MAA8B,EAC9B,IAAY;IAEZ,OAAO,MAAM,CAAC,OAAO;SAClB,GAAG,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,WAAW,CAAC,MAAM,EAAE,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC;SACxD,IAAI,CAAC,IAAI,CAAC,CAAC;AAChB,CAAC","sourcesContent":["import fs from \"node:fs\";\nimport { createRequire } from \"node:module\";\nimport path from \"node:path\";\n\nimport {\n Project,\n QuoteKind,\n type ImportDeclaration,\n type ImportSpecifierStructure,\n type SourceFile,\n} from \"ts-morph\";\n\nimport {\n bundledCorePackageVersion,\n isMigrationManifestActive,\n loadMigrationManifestsForProject,\n migrationMoveStatus,\n resolveMigrationSymbolMove,\n type MigrationManifest,\n type MigrationMove,\n} from \"../package-lifecycle/migration-manifest.js\";\n\nconst SOURCE_EXTENSIONS = new Set([\".ts\", \".tsx\"]);\nconst SKIP_DIRECTORIES = new Set([\n \".git\",\n \".next\",\n \".output\",\n \".turbo\",\n \"build\",\n \"coverage\",\n \"dist\",\n \"node_modules\",\n]);\n\nexport interface MigrationCodemodFileChange {\n file: string;\n before: string;\n after: string;\n}\n\nexport interface MigrationCodemodResult {\n changes: MigrationCodemodFileChange[];\n dependencyFiles: string[];\n warnings: string[];\n}\n\nexport interface RunMigrationCodemodsOptions {\n root: string;\n manifests?: MigrationManifest[];\n apply?: boolean;\n targetExists?: (specifier: string) => boolean;\n}\n\ninterface PendingDependency {\n packageFile: string;\n packageName: string;\n}\n\nfunction collectSourceFiles(root: string): string[] {\n const files: string[] = [];\n const visit = (directory: string): void => {\n for (const entry of fs.readdirSync(directory, { withFileTypes: true })) {\n if (entry.isDirectory() && SKIP_DIRECTORIES.has(entry.name)) continue;\n const entryPath = path.join(directory, entry.name);\n if (entry.isDirectory()) {\n visit(entryPath);\n } else if (\n SOURCE_EXTENSIONS.has(path.extname(entry.name)) &&\n !entry.name.endsWith(\".d.ts\")\n ) {\n files.push(entryPath);\n }\n }\n };\n visit(root);\n return files.sort();\n}\n\nfunction mergeManifestMoves(\n manifests: MigrationManifest[],\n): Record<string, MigrationMove> {\n const moves: Record<string, MigrationMove> = {};\n for (const manifest of manifests) {\n Object.assign(moves, manifest.moves);\n }\n return moves;\n}\n\nexport function loadMigrationManifests(\n projectRoot: string,\n): MigrationManifest[] {\n const packageVersion = bundledCorePackageVersion();\n return loadMigrationManifestsForProject(projectRoot).filter((manifest) =>\n isMigrationManifestActive(manifest, packageVersion),\n );\n}\n\nfunction packageNameFromSpecifier(specifier: string): string | null {\n if (specifier.startsWith(\"@\")) {\n const [scope, name] = specifier.split(\"/\");\n return scope && name ? `${scope}/${name}` : null;\n }\n const [name] = specifier.split(\"/\");\n return name && !name.startsWith(\".\") ? name : null;\n}\n\nfunction nearestPackageFile(file: string, root: string): string | null {\n let directory = path.dirname(file);\n const boundary = path.resolve(root);\n while (directory.startsWith(boundary)) {\n const packageFile = path.join(directory, \"package.json\");\n if (fs.existsSync(packageFile)) return packageFile;\n if (directory === boundary) break;\n directory = path.dirname(directory);\n }\n return null;\n}\n\nfunction recordIntroducedDependency(\n pending: PendingDependency[],\n sourceFile: string,\n root: string,\n from: string,\n to: string,\n): void {\n const fromPackage = packageNameFromSpecifier(from);\n const toPackage = packageNameFromSpecifier(to);\n if (!toPackage || toPackage === fromPackage) return;\n const packageFile = nearestPackageFile(sourceFile, root);\n if (!packageFile) return;\n if (\n !pending.some(\n (entry) =>\n entry.packageFile === packageFile && entry.packageName === toPackage,\n )\n ) {\n pending.push({ packageFile, packageName: toPackage });\n }\n}\n\nfunction importedNameStructure(\n importedName: string,\n localName: string,\n nextName: string,\n typeOnly: boolean,\n): ImportSpecifierStructure {\n return {\n name: nextName,\n alias:\n localName !== nextName\n ? localName\n : importedName !== nextName\n ? importedName\n : undefined,\n isTypeOnly: typeOnly,\n };\n}\n\nfunction warnSkippedTarget(\n warnings: string[],\n sourceFile: string,\n target: string,\n reason: \"planned\" | \"unresolved\",\n): void {\n const message =\n reason === \"planned\"\n ? `${sourceFile}: migration to ${target} is planned but not active; no rewrite was applied`\n : `${sourceFile}: migration target ${target} is not exported by an installed package; no rewrite was applied`;\n if (!warnings.includes(message)) warnings.push(message);\n}\n\nfunction rewriteImportDeclaration(\n declaration: ImportDeclaration,\n move: MigrationMove,\n root: string,\n pendingDependencies: PendingDependency[],\n warnings: string[],\n targetExists: (specifier: string) => boolean,\n): boolean {\n const originalSpecifier = declaration.getModuleSpecifierValue();\n const sourceFile = declaration.getSourceFile();\n const namedImports = declaration.getNamedImports();\n\n if (!move.symbols) {\n if (migrationMoveStatus(move) === \"planned\") {\n warnSkippedTarget(warnings, sourceFile.getFilePath(), move.to, \"planned\");\n return false;\n }\n if (!targetExists(move.to)) {\n warnSkippedTarget(\n warnings,\n sourceFile.getFilePath(),\n move.to,\n \"unresolved\",\n );\n return false;\n }\n declaration.setModuleSpecifier(move.to);\n recordIntroducedDependency(\n pendingDependencies,\n sourceFile.getFilePath(),\n root,\n originalSpecifier,\n move.to,\n );\n return originalSpecifier !== move.to;\n }\n\n if (namedImports.length === 0) {\n warnings.push(\n `${sourceFile.getFilePath()}: cannot split default, namespace, or side-effect import from ${originalSpecifier}`,\n );\n return false;\n }\n\n const groups = new Map<string, ImportSpecifierStructure[]>();\n const movedImports = new Set<(typeof namedImports)[number]>();\n for (const namedImport of namedImports) {\n const importedName = namedImport.getName();\n const resolved = resolveMigrationSymbolMove(move, importedName);\n if (!resolved || resolved.to === originalSpecifier) continue;\n if (resolved.status === \"planned\") {\n warnSkippedTarget(\n warnings,\n sourceFile.getFilePath(),\n resolved.to,\n \"planned\",\n );\n continue;\n }\n if (!targetExists(resolved.to)) {\n warnSkippedTarget(\n warnings,\n sourceFile.getFilePath(),\n resolved.to,\n \"unresolved\",\n );\n continue;\n }\n const localName = namedImport.getAliasNode()?.getText() ?? importedName;\n const group = groups.get(resolved.to) ?? [];\n group.push(\n importedNameStructure(\n importedName,\n localName,\n resolved.name,\n !declaration.isTypeOnly() && namedImport.isTypeOnly(),\n ),\n );\n groups.set(resolved.to, group);\n movedImports.add(namedImport);\n recordIntroducedDependency(\n pendingDependencies,\n sourceFile.getFilePath(),\n root,\n originalSpecifier,\n resolved.to,\n );\n }\n if (groups.size === 0) return false;\n\n const declarationIndex = declaration.getChildIndex();\n for (const namedImport of movedImports) namedImport.remove();\n let offset = 1;\n for (const [target, imports] of groups) {\n sourceFile.insertImportDeclaration(declarationIndex + offset, {\n moduleSpecifier: target,\n isTypeOnly: declaration.isTypeOnly(),\n namedImports: imports,\n });\n offset += 1;\n }\n if (\n declaration.getNamedImports().length === 0 &&\n !declaration.getDefaultImport() &&\n !declaration.getNamespaceImport()\n ) {\n declaration.remove();\n }\n return true;\n}\n\nfunction rewriteExportDeclarations(\n sourceFile: SourceFile,\n moves: Record<string, MigrationMove>,\n root: string,\n pendingDependencies: PendingDependency[],\n warnings: string[],\n targetExists: (specifier: string) => boolean,\n): void {\n for (const declaration of [...sourceFile.getExportDeclarations()]) {\n const originalSpecifier = declaration.getModuleSpecifierValue();\n if (!originalSpecifier) continue;\n const move = moves[originalSpecifier];\n if (!move) continue;\n const namedExports = declaration.getNamedExports();\n\n if (!move.symbols) {\n if (migrationMoveStatus(move) === \"planned\") {\n warnSkippedTarget(\n warnings,\n sourceFile.getFilePath(),\n move.to,\n \"planned\",\n );\n continue;\n }\n if (!targetExists(move.to)) {\n warnSkippedTarget(\n warnings,\n sourceFile.getFilePath(),\n move.to,\n \"unresolved\",\n );\n continue;\n }\n declaration.setModuleSpecifier(move.to);\n recordIntroducedDependency(\n pendingDependencies,\n sourceFile.getFilePath(),\n root,\n originalSpecifier,\n move.to,\n );\n continue;\n }\n if (namedExports.length === 0) {\n warnings.push(\n `${sourceFile.getFilePath()}: cannot split export star from ${originalSpecifier}`,\n );\n continue;\n }\n\n const groups = new Map<\n string,\n Array<{ name: string; alias?: string; isTypeOnly?: boolean }>\n >();\n const movedExports = new Set<(typeof namedExports)[number]>();\n for (const namedExport of namedExports) {\n const exportedFromName = namedExport.getName();\n const resolved = resolveMigrationSymbolMove(move, exportedFromName);\n if (!resolved || resolved.to === originalSpecifier) continue;\n if (resolved.status === \"planned\") {\n warnSkippedTarget(\n warnings,\n sourceFile.getFilePath(),\n resolved.to,\n \"planned\",\n );\n continue;\n }\n if (!targetExists(resolved.to)) {\n warnSkippedTarget(\n warnings,\n sourceFile.getFilePath(),\n resolved.to,\n \"unresolved\",\n );\n continue;\n }\n const publicName =\n namedExport.getAliasNode()?.getText() ?? exportedFromName;\n const group = groups.get(resolved.to) ?? [];\n group.push({\n name: resolved.name,\n alias:\n publicName !== resolved.name\n ? publicName\n : exportedFromName !== resolved.name\n ? exportedFromName\n : undefined,\n isTypeOnly:\n !declaration.isTypeOnly() && namedExport.isTypeOnly()\n ? true\n : undefined,\n });\n groups.set(resolved.to, group);\n movedExports.add(namedExport);\n recordIntroducedDependency(\n pendingDependencies,\n sourceFile.getFilePath(),\n root,\n originalSpecifier,\n resolved.to,\n );\n }\n if (groups.size === 0) continue;\n\n const declarationIndex = declaration.getChildIndex();\n for (const namedExport of movedExports) namedExport.remove();\n let offset = 1;\n for (const [target, exports] of groups) {\n sourceFile.insertExportDeclaration(declarationIndex + offset, {\n moduleSpecifier: target,\n isTypeOnly: declaration.isTypeOnly(),\n namedExports: exports,\n });\n offset += 1;\n }\n if (declaration.getNamedExports().length === 0) declaration.remove();\n }\n}\n\nfunction readPackageJson(packageFile: string): Record<string, unknown> | null {\n try {\n return JSON.parse(fs.readFileSync(packageFile, \"utf-8\")) as Record<\n string,\n unknown\n >;\n } catch {\n return null;\n }\n}\n\nfunction addDependencies(\n pending: PendingDependency[],\n apply: boolean,\n): MigrationCodemodFileChange[] {\n const changes: MigrationCodemodFileChange[] = [];\n const byFile = new Map<string, Set<string>>();\n for (const entry of pending) {\n const packages = byFile.get(entry.packageFile) ?? new Set<string>();\n packages.add(entry.packageName);\n byFile.set(entry.packageFile, packages);\n }\n for (const [packageFile, packageNames] of byFile) {\n const packageJson = readPackageJson(packageFile);\n if (!packageJson) continue;\n const allDependencySections = [\n \"dependencies\",\n \"devDependencies\",\n \"optionalDependencies\",\n \"peerDependencies\",\n ];\n const missing = [...packageNames].filter(\n (packageName) =>\n !allDependencySections.some((section) => {\n const dependencies = packageJson[section];\n return (\n dependencies &&\n typeof dependencies === \"object\" &&\n packageName in dependencies\n );\n }),\n );\n if (missing.length === 0) continue;\n const before = `${JSON.stringify(packageJson, null, 2)}\\n`;\n const dependencies =\n packageJson.dependencies && typeof packageJson.dependencies === \"object\"\n ? (packageJson.dependencies as Record<string, string>)\n : {};\n for (const packageName of missing.sort())\n dependencies[packageName] = \"latest\";\n packageJson.dependencies = Object.fromEntries(\n Object.entries(dependencies).sort(([left], [right]) =>\n left.localeCompare(right),\n ),\n );\n const after = `${JSON.stringify(packageJson, null, 2)}\\n`;\n changes.push({ file: packageFile, before, after });\n if (apply) fs.writeFileSync(packageFile, after);\n }\n return changes;\n}\n\nexport function runMigrationCodemods(\n options: RunMigrationCodemodsOptions,\n): MigrationCodemodResult {\n const root = path.resolve(options.root);\n const manifests = options.manifests ?? loadMigrationManifests(root);\n const moves = mergeManifestMoves(manifests);\n const requireFromProject = createRequire(path.join(root, \"package.json\"));\n const targetExists =\n options.targetExists ??\n ((specifier: string): boolean => {\n try {\n requireFromProject.resolve(specifier);\n return true;\n } catch {\n return false;\n }\n });\n const project = new Project({\n skipAddingFilesFromTsConfig: true,\n manipulationSettings: { quoteKind: QuoteKind.Double },\n });\n const sourceFiles = project.addSourceFilesAtPaths(collectSourceFiles(root));\n const pendingDependencies: PendingDependency[] = [];\n const warnings: string[] = [];\n const changes: MigrationCodemodFileChange[] = [];\n\n for (const sourceFile of sourceFiles) {\n const before = sourceFile.getFullText();\n for (const declaration of [...sourceFile.getImportDeclarations()]) {\n const move = moves[declaration.getModuleSpecifierValue()];\n if (!move) continue;\n rewriteImportDeclaration(\n declaration,\n move,\n root,\n pendingDependencies,\n warnings,\n targetExists,\n );\n }\n rewriteExportDeclarations(\n sourceFile,\n moves,\n root,\n pendingDependencies,\n warnings,\n targetExists,\n );\n const after = sourceFile.getFullText();\n if (before === after) continue;\n changes.push({ file: sourceFile.getFilePath(), before, after });\n if (options.apply) sourceFile.saveSync();\n }\n\n const dependencyChanges = addDependencies(\n pendingDependencies,\n Boolean(options.apply),\n );\n return {\n changes: [...changes, ...dependencyChanges],\n dependencyFiles: dependencyChanges.map((change) => change.file),\n warnings,\n };\n}\n\nfunction focusedDiff(change: MigrationCodemodFileChange, root: string): string {\n const beforeLines = change.before.split(\"\\n\");\n const afterLines = change.after.split(\"\\n\");\n let prefix = 0;\n while (\n prefix < beforeLines.length &&\n prefix < afterLines.length &&\n beforeLines[prefix] === afterLines[prefix]\n ) {\n prefix += 1;\n }\n let suffix = 0;\n while (\n suffix < beforeLines.length - prefix &&\n suffix < afterLines.length - prefix &&\n beforeLines[beforeLines.length - 1 - suffix] ===\n afterLines[afterLines.length - 1 - suffix]\n ) {\n suffix += 1;\n }\n const beforeChanged = beforeLines.slice(prefix, beforeLines.length - suffix);\n const afterChanged = afterLines.slice(prefix, afterLines.length - suffix);\n return [\n `--- ${path.relative(root, change.file)}`,\n `+++ ${path.relative(root, change.file)}`,\n `@@ -${prefix + 1} +${prefix + 1} @@`,\n ...beforeChanged.map((line) => `-${line}`),\n ...afterChanged.map((line) => `+${line}`),\n ].join(\"\\n\");\n}\n\nexport function formatMigrationCodemodDiff(\n result: MigrationCodemodResult,\n root: string,\n): string {\n return result.changes\n .map((change) => focusedDiff(change, path.resolve(root)))\n .join(\"\\n\");\n}\n"]}
|
package/dist/cli/upgrade.d.ts
CHANGED
|
@@ -19,6 +19,8 @@ export interface UpgradeCliOptions {
|
|
|
19
19
|
command: UpgradeCommand;
|
|
20
20
|
cwd?: string;
|
|
21
21
|
dryRun?: boolean;
|
|
22
|
+
codemods?: boolean;
|
|
23
|
+
yes?: boolean;
|
|
22
24
|
skipInstall?: boolean;
|
|
23
25
|
skipVerify?: boolean;
|
|
24
26
|
skipSkills?: boolean;
|
|
@@ -79,6 +81,11 @@ export interface UpgradeRunResult {
|
|
|
79
81
|
}>;
|
|
80
82
|
message: string;
|
|
81
83
|
exitCode: number;
|
|
84
|
+
codemod?: {
|
|
85
|
+
files: string[];
|
|
86
|
+
warnings: string[];
|
|
87
|
+
diff: string;
|
|
88
|
+
};
|
|
82
89
|
}
|
|
83
90
|
export interface UpgradeIo {
|
|
84
91
|
log: (message: string) => void;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"upgrade.d.ts","sourceRoot":"","sources":["../../src/cli/upgrade.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AACH,OAAO,EAAa,KAAK,gBAAgB,EAAE,MAAM,oBAAoB,CAAC;AAQtE,MAAM,MAAM,cAAc,GAAG,KAAK,GAAG,OAAO,GAAG,MAAM,CAAC;AAEtD,MAAM,WAAW,iBAAiB;IAChC,OAAO,EAAE,cAAc,CAAC;IACxB,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,UAAU,CAAC,EAAE,OAAO,CAAC;IACr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AC,EAAE,SAAS,GAAG,MAAM,CAAA;KAAE,KACjD,gBAAgB,CAAC,MAAM,GAAG,MAAM,CAAC,CAAC;IACvC,eAAe,EAAE,CAAC,GAAG,EAAE,MAAM,KAAK,OAAO,CAAC,IAAI,CAAC,CAAC;CACjD;AAwBD,wBAAgB,gBAAgB,CAAC,IAAI,EAAE,MAAM,EAAE,GAAG,iBAAiB,CAkClE;AAED,wBAAgB,gBAAgB,CAAC,EAAE,GAAE,IAAI,CAAC,SAAS,EAAE,KAAK,CAAa,GAAG,IAAI,CAyB7E;AAcD,wBAAgB,wBAAwB,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAE9D;AAED,wBAAgB,sBAAsB,CAAC,OAAO,EAAE,MAAM,GAAG,OAAO,CAY/D;AAED,wBAAgB,4BAA4B,CAAC,OAAO,EAAE,MAAM,GAAG,OAAO,CAGrE;AAmED,wBAAgB,oBAAoB,CAAC,GAAG,EAAE,MAAM,GAAG,cAAc,GAAG,IAAI,CA6BvE;AAyID,wBAAgB,wBAAwB,CACtC,OAAO,EAAE,cAAc,GACtB,mBAAmB,CA0BrB;AAiDD,wBAAsB,UAAU,CAC9B,IAAI,EAAE,MAAM,EAAE,EACd,EAAE,GAAE,SAAqB,GACxB,OAAO,CAAC,MAAM,CAAC,CAwRjB"}
|
package/dist/cli/upgrade.js
CHANGED
|
@@ -54,6 +54,12 @@ export function parseUpgradeArgs(argv) {
|
|
|
54
54
|
else if (arg === "--dry-run") {
|
|
55
55
|
opts.dryRun = true;
|
|
56
56
|
}
|
|
57
|
+
else if (arg === "--codemods") {
|
|
58
|
+
opts.codemods = true;
|
|
59
|
+
}
|
|
60
|
+
else if (arg === "--yes") {
|
|
61
|
+
opts.yes = true;
|
|
62
|
+
}
|
|
57
63
|
else if (arg === "--skip-install") {
|
|
58
64
|
opts.skipInstall = true;
|
|
59
65
|
}
|
|
@@ -87,9 +93,12 @@ export function printUpgradeHelp(io = defaultIo) {
|
|
|
87
93
|
" agent-native upgrade Bring this app/workspace to current @agent-native/*",
|
|
88
94
|
" agent-native upgrade check Doctor only: overrides, patches, pending bumps",
|
|
89
95
|
" agent-native upgrade --dry-run Show the plan without writing or installing",
|
|
96
|
+
" agent-native upgrade --codemods Preview manifest-driven import migrations",
|
|
90
97
|
"",
|
|
91
98
|
"Options:",
|
|
92
99
|
" --skip-install Bump package.json only; do not run the package manager",
|
|
100
|
+
" --codemods Rewrite moved Agent Native imports and exports (preview by default)",
|
|
101
|
+
" --yes Apply codemods; without this flag --codemods is a dry run",
|
|
93
102
|
" --skip-skills Skip `skills update scaffold --project`",
|
|
94
103
|
" --skip-verify Skip typecheck after upgrade",
|
|
95
104
|
" --force Continue even when framework overrides/patches are present",
|
|
@@ -451,9 +460,10 @@ export async function runUpgrade(argv, io = defaultIo) {
|
|
|
451
460
|
}
|
|
452
461
|
return doctor.findings.length > 0 ? 1 : 0;
|
|
453
462
|
}
|
|
463
|
+
const dryRun = Boolean(opts.dryRun || (opts.codemods && !opts.yes));
|
|
454
464
|
const result = {
|
|
455
465
|
ok: true,
|
|
456
|
-
dryRun
|
|
466
|
+
dryRun,
|
|
457
467
|
doctor,
|
|
458
468
|
steps: [],
|
|
459
469
|
message: "",
|
|
@@ -496,7 +506,7 @@ export async function runUpgrade(argv, io = defaultIo) {
|
|
|
496
506
|
detail: "All @agent-native/* deps already use latest or local pins",
|
|
497
507
|
});
|
|
498
508
|
}
|
|
499
|
-
else if (
|
|
509
|
+
else if (dryRun) {
|
|
500
510
|
result.steps.push({
|
|
501
511
|
id: "bump",
|
|
502
512
|
status: "planned",
|
|
@@ -525,6 +535,39 @@ export async function runUpgrade(argv, io = defaultIo) {
|
|
|
525
535
|
detail: `Updated ${doctor.bumps.length} @agent-native/* dependency pin(s)`,
|
|
526
536
|
});
|
|
527
537
|
}
|
|
538
|
+
if (opts.codemods) {
|
|
539
|
+
const { formatMigrationCodemodDiff, runMigrationCodemods } = await import("./migration-codemod.js");
|
|
540
|
+
const codemodResult = runMigrationCodemods({
|
|
541
|
+
root: project.root,
|
|
542
|
+
apply: !dryRun,
|
|
543
|
+
});
|
|
544
|
+
const diff = formatMigrationCodemodDiff(codemodResult, project.root);
|
|
545
|
+
result.codemod = {
|
|
546
|
+
files: codemodResult.changes.map((change) => relativeTo(project.root, change.file)),
|
|
547
|
+
warnings: codemodResult.warnings,
|
|
548
|
+
diff,
|
|
549
|
+
};
|
|
550
|
+
result.steps.push({
|
|
551
|
+
id: "codemods",
|
|
552
|
+
status: codemodResult.changes.length === 0
|
|
553
|
+
? "skipped"
|
|
554
|
+
: dryRun
|
|
555
|
+
? "planned"
|
|
556
|
+
: "ok",
|
|
557
|
+
detail: codemodResult.changes.length === 0
|
|
558
|
+
? "No manifest migrations found"
|
|
559
|
+
: `${dryRun ? "Would update" : "Updated"} ${codemodResult.changes.length} file(s)`,
|
|
560
|
+
});
|
|
561
|
+
if (!opts.json && diff) {
|
|
562
|
+
io.log(diff);
|
|
563
|
+
io.log("");
|
|
564
|
+
}
|
|
565
|
+
if (!opts.json) {
|
|
566
|
+
for (const warning of codemodResult.warnings) {
|
|
567
|
+
io.err(`[codemods] ${warning}`);
|
|
568
|
+
}
|
|
569
|
+
}
|
|
570
|
+
}
|
|
528
571
|
// Install.
|
|
529
572
|
if (opts.skipInstall) {
|
|
530
573
|
result.steps.push({
|
|
@@ -533,7 +576,7 @@ export async function runUpgrade(argv, io = defaultIo) {
|
|
|
533
576
|
detail: "--skip-install",
|
|
534
577
|
});
|
|
535
578
|
}
|
|
536
|
-
else if (
|
|
579
|
+
else if (dryRun) {
|
|
537
580
|
result.steps.push({
|
|
538
581
|
id: "install",
|
|
539
582
|
status: "planned",
|
|
@@ -568,7 +611,7 @@ export async function runUpgrade(argv, io = defaultIo) {
|
|
|
568
611
|
detail: "--skip-skills",
|
|
569
612
|
});
|
|
570
613
|
}
|
|
571
|
-
else if (
|
|
614
|
+
else if (dryRun) {
|
|
572
615
|
result.steps.push({
|
|
573
616
|
id: "skills",
|
|
574
617
|
status: "planned",
|
|
@@ -605,7 +648,7 @@ export async function runUpgrade(argv, io = defaultIo) {
|
|
|
605
648
|
detail: "--skip-verify",
|
|
606
649
|
});
|
|
607
650
|
}
|
|
608
|
-
else if (
|
|
651
|
+
else if (dryRun) {
|
|
609
652
|
result.steps.push({
|
|
610
653
|
id: "verify",
|
|
611
654
|
status: "planned",
|
|
@@ -648,8 +691,10 @@ export async function runUpgrade(argv, io = defaultIo) {
|
|
|
648
691
|
result.steps.push({ id: "verify", status: "ok", detail: "typecheck" });
|
|
649
692
|
}
|
|
650
693
|
}
|
|
651
|
-
result.message =
|
|
652
|
-
?
|
|
694
|
+
result.message = dryRun
|
|
695
|
+
? opts.codemods && !opts.yes
|
|
696
|
+
? "Codemod preview complete. Re-run with --codemods --yes to apply."
|
|
697
|
+
: "Dry run complete. Re-run without --dry-run to apply."
|
|
653
698
|
: "Upgrade complete. If the app still fails to run, fix app-level code — do not patch @agent-native/*.";
|
|
654
699
|
emitResult(io, opts, result);
|
|
655
700
|
return 0;
|
package/dist/cli/upgrade.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"upgrade.js","sourceRoot":"","sources":["../../src/cli/upgrade.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AACH,OAAO,EAAE,SAAS,EAAyB,MAAM,oBAAoB,CAAC;AACtE,OAAO,EAAE,MAAM,SAAS,CAAC;AACzB,OAAO,IAAI,MAAM,WAAW,CAAC;AAC7B,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AAEzC,MAAM,kBAAkB,GAAG,gBAAgB,CAAC;AAC5C,MAAM,gBAAgB,GAAG,QAAQ,CAAC;AAuFlC,MAAM,SAAS,GAAc;IAC3B,GAAG,EAAE,CAAC,OAAO,EAAE,EAAE,CAAC,OAAO,CAAC,GAAG,CAAC,OAAO,CAAC;IACtC,GAAG,EAAE,CAAC,OAAO,EAAE,EAAE,CAAC,OAAO,CAAC,KAAK,CAAC,OAAO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AM,EAAE,CAAC,CAAC,CAAC,EAAE,EAAE,CACvE,CAAC;IACJ,CAAC;IACD,EAAE,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC;IACX,IAAI,MAAM,CAAC,EAAE,EAAE,CAAC;QACd,EAAE,CAAC,GAAG,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC;IACzB,CAAC;SAAM,CAAC;QACN,EAAE,CAAC,GAAG,CAAC,MAAM,CAAC,OAAO,CAAC,CAAC;QACvB,EAAE,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC;QACX,EAAE,CAAC,GAAG,CAAC,gBAAgB,CAAC,CAAC;IAC3B,CAAC;AACH,CAAC","sourcesContent":["/**\n * `agent-native upgrade` — bring an existing Agent Native app/workspace current.\n *\n * Older branches often break after a core bump. Agents then invent\n * `pnpm.overrides` / patches against `@agent-native/*` (especially dispatch),\n * which makes things worse. This command is the supported path:\n *\n * 1. Doctor: refuse or warn on framework overrides/patches\n * 2. Bump `@agent-native/*` deps to `latest` (unless file:/link:/workspace:)\n * 3. Install\n * 4. Refresh scaffold skills (`skills update scaffold --project`)\n * 5. Verify with typecheck when available\n *\n * On failure: print the error and stop. Do not patch framework packages.\n */\nimport { spawnSync, type SpawnSyncReturns } from \"node:child_process\";\nimport fs from \"node:fs\";\nimport path from \"node:path\";\nimport { fileURLToPath } from \"node:url\";\n\nconst AGENT_NATIVE_SCOPE = \"@agent-native/\";\nconst PINNABLE_VERSION = \"latest\";\n\nexport type UpgradeCommand = \"run\" | \"check\" | \"help\";\n\nexport interface UpgradeCliOptions {\n command: UpgradeCommand;\n cwd?: string;\n dryRun?: boolean;\n skipInstall?: boolean;\n skipVerify?: boolean;\n skipSkills?: boolean;\n json?: boolean;\n help?: boolean;\n /** Force past doctor findings that would otherwise block (not recommended). */\n force?: boolean;\n}\n\nexport interface PackageJsonLike {\n name?: string;\n version?: string;\n dependencies?: Record<string, string>;\n devDependencies?: Record<string, string>;\n optionalDependencies?: Record<string, string>;\n peerDependencies?: Record<string, string>;\n pnpm?: {\n overrides?: Record<string, string>;\n patchedDependencies?: Record<string, string>;\n };\n overrides?: Record<string, string>;\n resolutions?: Record<string, string>;\n scripts?: Record<string, string>;\n}\n\nexport interface FrameworkOverrideFinding {\n file: string;\n field: string;\n key: string;\n value: string;\n}\n\nexport interface AgentNativeDepBump {\n file: string;\n section: \"dependencies\" | \"devDependencies\" | \"optionalDependencies\";\n name: string;\n from: string;\n to: string;\n}\n\nexport interface UpgradeProject {\n root: string;\n kind: \"standalone\" | \"workspace\";\n packageFiles: string[];\n}\n\nexport interface UpgradeDoctorReport {\n project: UpgradeProject;\n findings: FrameworkOverrideFinding[];\n bumps: AgentNativeDepBump[];\n installedCoreVersion: string | null;\n cliCoreVersion: string | null;\n scaffoldStaleHint: boolean;\n}\n\nexport interface UpgradeRunResult {\n ok: boolean;\n dryRun: boolean;\n doctor: UpgradeDoctorReport;\n steps: Array<{\n id: string;\n status: \"ok\" | \"skipped\" | \"failed\" | \"planned\";\n detail?: string;\n }>;\n message: string;\n exitCode: number;\n}\n\nexport interface UpgradeIo {\n log: (message: string) => void;\n err: (message: string) => void;\n spawn: (\n command: string,\n args: string[],\n options: { cwd: string; stdio?: \"inherit\" | \"pipe\" },\n ) => SpawnSyncReturns<string | Buffer>;\n runSkillsUpdate: (cwd: string) => Promise<void>;\n}\n\nconst defaultIo: UpgradeIo = {\n log: (message) => console.log(message),\n err: (message) => console.error(message),\n spawn: (command, args, options) =>\n spawnSync(command, args, {\n cwd: options.cwd,\n stdio: options.stdio ?? \"inherit\",\n encoding: \"utf-8\",\n shell: process.platform === \"win32\",\n }),\n runSkillsUpdate: async (cwd) => {\n const { runSkills } = await import(\"./skills.js\");\n const previous = process.cwd();\n process.chdir(cwd);\n try {\n await runSkills([\"update\", \"scaffold\", \"--project\"]);\n } finally {\n process.chdir(previous);\n }\n },\n};\n\nexport function parseUpgradeArgs(argv: string[]): UpgradeCliOptions {\n const opts: UpgradeCliOptions = { command: \"run\" };\n for (let i = 0; i < argv.length; i++) {\n const arg = argv[i];\n if (arg === \"check\" || arg === \"doctor\") {\n opts.command = \"check\";\n } else if (arg === \"help\" || arg === \"--help\" || arg === \"-h\") {\n opts.command = \"help\";\n opts.help = true;\n } else if (arg === \"--dry-run\") {\n opts.dryRun = true;\n } else if (arg === \"--skip-install\") {\n opts.skipInstall = true;\n } else if (arg === \"--skip-verify\") {\n opts.skipVerify = true;\n } else if (arg === \"--skip-skills\") {\n opts.skipSkills = true;\n } else if (arg === \"--json\") {\n opts.json = true;\n } else if (arg === \"--force\") {\n opts.force = true;\n } else if (arg === \"--cwd\" && argv[i + 1]) {\n opts.cwd = argv[++i];\n } else if (arg.startsWith(\"--cwd=\")) {\n opts.cwd = arg.slice(\"--cwd=\".length);\n } else if (!arg.startsWith(\"-\")) {\n // Ignore unknown positional for forward-compat; help covers usage.\n }\n }\n return opts;\n}\n\nexport function printUpgradeHelp(io: Pick<UpgradeIo, \"log\"> = defaultIo): void {\n io.log(\n [\n \"Usage:\",\n \" agent-native upgrade Bring this app/workspace to current @agent-native/*\",\n \" agent-native upgrade check Doctor only: overrides, patches, pending bumps\",\n \" agent-native upgrade --dry-run Show the plan without writing or installing\",\n \"\",\n \"Options:\",\n \" --skip-install Bump package.json only; do not run the package manager\",\n \" --skip-skills Skip `skills update scaffold --project`\",\n \" --skip-verify Skip typecheck after upgrade\",\n \" --force Continue even when framework overrides/patches are present\",\n \" --json Machine-readable report\",\n \" --cwd <dir> Run against a project root other than the current directory\",\n \"\",\n \"On failure: report the error and stop. Do NOT add pnpm.overrides,\",\n \"patchedDependencies, or local patches against @agent-native/* packages.\",\n \"Do NOT edit node_modules/@agent-native/* or invent dispatch/core behavior\",\n \"overrides. Revert those changes and re-run `agent-native upgrade`.\",\n ].join(\"\\n\"),\n );\n}\n\nfunction readJsonFile(filePath: string): PackageJsonLike | null {\n try {\n return JSON.parse(fs.readFileSync(filePath, \"utf-8\")) as PackageJsonLike;\n } catch {\n return null;\n }\n}\n\nfunction writeJsonFile(filePath: string, value: PackageJsonLike): void {\n fs.writeFileSync(filePath, `${JSON.stringify(value, null, 2)}\\n`);\n}\n\nexport function isAgentNativePackageName(name: string): boolean {\n return name === \"@agent-native\" || name.startsWith(AGENT_NATIVE_SCOPE);\n}\n\nexport function isPinnedOrLocalVersion(version: string): boolean {\n const v = version.trim();\n return (\n v.startsWith(\"file:\") ||\n v.startsWith(\"link:\") ||\n v.startsWith(\"workspace:\") ||\n v.startsWith(\"portal:\") ||\n v.startsWith(\"git+\") ||\n v.startsWith(\"github:\") ||\n v.startsWith(\"http:\") ||\n v.startsWith(\"https:\")\n );\n}\n\nexport function shouldBumpAgentNativeVersion(version: string): boolean {\n if (isPinnedOrLocalVersion(version)) return false;\n return version.trim() !== PINNABLE_VERSION;\n}\n\nfunction collectOverrideFindings(\n file: string,\n pkg: PackageJsonLike,\n): FrameworkOverrideFinding[] {\n const findings: FrameworkOverrideFinding[] = [];\n const tables: Array<{\n field: string;\n map: Record<string, string> | undefined;\n }> = [\n { field: \"pnpm.overrides\", map: pkg.pnpm?.overrides },\n { field: \"pnpm.patchedDependencies\", map: pkg.pnpm?.patchedDependencies },\n { field: \"overrides\", map: pkg.overrides },\n { field: \"resolutions\", map: pkg.resolutions },\n ];\n for (const table of tables) {\n if (!table.map) continue;\n for (const [key, value] of Object.entries(table.map)) {\n // Keys may be bare (`@agent-native/core`) or versioned\n // (`@agent-native/core@1.2.3` for patchedDependencies).\n if (key.includes(AGENT_NATIVE_SCOPE) || isAgentNativePackageName(key)) {\n findings.push({ file, field: table.field, key, value: String(value) });\n }\n }\n }\n return findings;\n}\n\nfunction collectBumps(\n file: string,\n pkg: PackageJsonLike,\n): AgentNativeDepBump[] {\n const bumps: AgentNativeDepBump[] = [];\n const sections = [\n \"dependencies\",\n \"devDependencies\",\n \"optionalDependencies\",\n ] as const;\n for (const section of sections) {\n const deps = pkg[section];\n if (!deps) continue;\n for (const [name, version] of Object.entries(deps)) {\n if (!isAgentNativePackageName(name)) continue;\n if (!shouldBumpAgentNativeVersion(version)) continue;\n bumps.push({\n file,\n section,\n name,\n from: version,\n to: PINNABLE_VERSION,\n });\n }\n }\n return bumps;\n}\n\nfunction applyBumps(pkg: PackageJsonLike, bumps: AgentNativeDepBump[]): void {\n for (const bump of bumps) {\n const section = pkg[bump.section];\n if (!section) continue;\n if (section[bump.name] === bump.from) {\n section[bump.name] = bump.to;\n }\n }\n}\n\nexport function detectUpgradeProject(cwd: string): UpgradeProject | null {\n const start = path.resolve(cwd);\n let dir = start;\n while (true) {\n const pkgPath = path.join(dir, \"package.json\");\n if (fs.existsSync(pkgPath)) {\n const pkg = readJsonFile(pkgPath);\n const hasCore =\n Boolean(pkg?.dependencies?.[\"@agent-native/core\"]) ||\n Boolean(pkg?.devDependencies?.[\"@agent-native/core\"]);\n const workspaceYaml = path.join(dir, \"pnpm-workspace.yaml\");\n const isWorkspace = fs.existsSync(workspaceYaml);\n if (hasCore || isWorkspace) {\n const packageFiles = [pkgPath];\n if (isWorkspace) {\n packageFiles.push(...workspacePackageFiles(dir, workspaceYaml));\n }\n return {\n root: dir,\n kind: isWorkspace ? \"workspace\" : \"standalone\",\n packageFiles: Array.from(new Set(packageFiles)),\n };\n }\n }\n const parent = path.dirname(dir);\n if (parent === dir) break;\n dir = parent;\n }\n return null;\n}\n\nfunction workspacePackageFiles(root: string, workspaceYaml: string): string[] {\n const patterns = parseWorkspacePackagePatterns(workspaceYaml);\n const included = new Set<string>();\n const excluded = new Set<string>();\n for (const rawPattern of patterns) {\n const exclude = rawPattern.startsWith(\"!\");\n const pattern = exclude ? rawPattern.slice(1) : rawPattern;\n const files = packageFilesForWorkspacePattern(root, pattern);\n for (const file of files) {\n if (exclude) excluded.add(file);\n else included.add(file);\n }\n }\n return Array.from(included)\n .filter((file) => !excluded.has(file))\n .sort();\n}\n\nfunction parseWorkspacePackagePatterns(workspaceYaml: string): string[] {\n let text = \"\";\n try {\n text = fs.readFileSync(workspaceYaml, \"utf-8\");\n } catch {\n return [\"apps/*\", \"packages/*\"];\n }\n const patterns: string[] = [];\n let inPackages = false;\n for (const line of text.split(/\\r?\\n/)) {\n const trimmed = line.trim();\n if (!trimmed || trimmed.startsWith(\"#\")) continue;\n if (/^[A-Za-z0-9_-]+:/.test(trimmed)) {\n inPackages = trimmed === \"packages:\";\n continue;\n }\n if (!inPackages || !trimmed.startsWith(\"-\")) continue;\n const pattern = trimmed\n .slice(1)\n .trim()\n .replace(/^['\"]|['\"]$/g, \"\");\n if (pattern) patterns.push(pattern);\n }\n return patterns.length ? patterns : [\"apps/*\", \"packages/*\"];\n}\n\nfunction packageFilesForWorkspacePattern(\n root: string,\n pattern: string,\n): string[] {\n const normalized = pattern.replace(/\\\\/g, \"/\").replace(/\\/+$/g, \"\");\n if (!normalized || normalized.includes(\"node_modules\")) return [];\n if (normalized.endsWith(\"/**\")) {\n return collectPackageFilesRecursive(\n path.join(root, normalized.slice(0, -3)),\n );\n }\n if (normalized.endsWith(\"/*\")) {\n const base = path.join(root, normalized.slice(0, -2));\n if (!fs.existsSync(base)) return [];\n return fs\n .readdirSync(base, { withFileTypes: true })\n .filter((entry) => entry.isDirectory())\n .map((entry) => path.join(base, entry.name, \"package.json\"))\n .filter((file) => fs.existsSync(file));\n }\n if (normalized.includes(\"*\")) {\n return collectPackageFilesRecursive(\n path.join(root, normalized.split(\"*\")[0]),\n );\n }\n const file = path.join(root, normalized, \"package.json\");\n return fs.existsSync(file) ? [file] : [];\n}\n\nfunction collectPackageFilesRecursive(dir: string): string[] {\n if (!fs.existsSync(dir)) return [];\n const files: string[] = [];\n for (const entry of fs.readdirSync(dir, { withFileTypes: true })) {\n if (!entry.isDirectory()) continue;\n if (entry.name === \"node_modules\" || entry.name === \".git\") continue;\n const child = path.join(dir, entry.name);\n const pkg = path.join(child, \"package.json\");\n if (fs.existsSync(pkg)) files.push(pkg);\n files.push(...collectPackageFilesRecursive(child));\n }\n return files;\n}\n\nfunction resolveInstalledPackageVersion(\n projectRoot: string,\n packageName: string,\n): string | null {\n let dir = projectRoot;\n while (true) {\n const candidate = path.join(\n dir,\n \"node_modules\",\n ...packageName.split(\"/\"),\n \"package.json\",\n );\n if (fs.existsSync(candidate)) {\n const pkg = readJsonFile(candidate);\n return typeof pkg?.version === \"string\" ? pkg.version : null;\n }\n const parent = path.dirname(dir);\n if (parent === dir) break;\n dir = parent;\n }\n return null;\n}\n\nfunction readCliCoreVersion(): string | null {\n try {\n const here = path.dirname(fileURLToPath(import.meta.url));\n const pkgPath = path.resolve(here, \"../../package.json\");\n const pkg = readJsonFile(pkgPath);\n return typeof pkg?.version === \"string\" ? pkg.version : null;\n } catch {\n return null;\n }\n}\n\nfunction detectPackageManager(projectRoot: string): \"pnpm\" | \"npm\" | \"yarn\" {\n if (fs.existsSync(path.join(projectRoot, \"pnpm-lock.yaml\"))) return \"pnpm\";\n if (fs.existsSync(path.join(projectRoot, \"yarn.lock\"))) return \"yarn\";\n if (fs.existsSync(path.join(projectRoot, \"package-lock.json\"))) return \"npm\";\n // Prefer pnpm for Agent Native scaffolds.\n return \"pnpm\";\n}\n\nfunction installArgs(pm: \"pnpm\" | \"npm\" | \"yarn\"): string[] {\n if (pm === \"npm\") return [\"install\"];\n if (pm === \"yarn\") return [\"install\"];\n return [\"install\"];\n}\n\nexport function buildUpgradeDoctorReport(\n project: UpgradeProject,\n): UpgradeDoctorReport {\n const findings: FrameworkOverrideFinding[] = [];\n const bumps: AgentNativeDepBump[] = [];\n for (const file of project.packageFiles) {\n const pkg = readJsonFile(file);\n if (!pkg) continue;\n findings.push(...collectOverrideFindings(file, pkg));\n bumps.push(...collectBumps(file, pkg));\n }\n const installedCoreVersion = resolveInstalledPackageVersion(\n project.root,\n \"@agent-native/core\",\n );\n const cliCoreVersion = readCliCoreVersion();\n const skillsUpdateScript = project.packageFiles.some((file) => {\n const pkg = readJsonFile(file);\n return Boolean(pkg?.scripts?.[\"skills:update\"]);\n });\n return {\n project,\n findings,\n bumps,\n installedCoreVersion,\n cliCoreVersion,\n scaffoldStaleHint: skillsUpdateScript || bumps.length > 0,\n };\n}\n\nfunction relativeTo(root: string, file: string): string {\n const rel = path.relative(root, file);\n return rel || \".\";\n}\n\nfunction formatDoctorHuman(report: UpgradeDoctorReport): string {\n const lines: string[] = [];\n lines.push(`Project: ${report.project.root} (${report.project.kind})`);\n if (report.installedCoreVersion) {\n lines.push(`Installed @agent-native/core: ${report.installedCoreVersion}`);\n } else {\n lines.push(\"Installed @agent-native/core: (not found in node_modules)\");\n }\n if (report.cliCoreVersion) {\n lines.push(`CLI package version: ${report.cliCoreVersion}`);\n }\n if (report.findings.length === 0) {\n lines.push(\"Framework overrides/patches: none\");\n } else {\n lines.push(\"Framework overrides/patches:\");\n for (const finding of report.findings) {\n lines.push(\n ` - ${relativeTo(report.project.root, finding.file)} ${finding.field}[\"${finding.key}\"] = ${finding.value}`,\n );\n }\n }\n if (report.bumps.length === 0) {\n lines.push(\"Pending @agent-native/* bumps: none\");\n } else {\n lines.push(\"Pending @agent-native/* bumps:\");\n for (const bump of report.bumps) {\n lines.push(\n ` - ${relativeTo(report.project.root, bump.file)} ${bump.name}: ${bump.from} → ${bump.to}`,\n );\n }\n }\n return lines.join(\"\\n\");\n}\n\nconst FAILURE_GUIDANCE = [\n \"Upgrade failed. Do not paper over this with framework patches.\",\n \"Never add pnpm.overrides / patchedDependencies / resolutions for @agent-native/*.\",\n \"Never edit node_modules/@agent-native/* or invent local dispatch/core behavior overrides.\",\n \"Revert those changes if present, fix the app-level compile/runtime error, then re-run:\",\n \" npx @agent-native/core@latest upgrade\",\n].join(\"\\n\");\n\nexport async function runUpgrade(\n argv: string[],\n io: UpgradeIo = defaultIo,\n): Promise<number> {\n const opts = parseUpgradeArgs(argv);\n if (opts.help || opts.command === \"help\") {\n printUpgradeHelp(io);\n return 0;\n }\n\n const cwd = path.resolve(opts.cwd ?? process.cwd());\n const project = detectUpgradeProject(cwd);\n if (!project) {\n const message =\n \"No Agent Native app/workspace found. Run from an app or workspace root that depends on @agent-native/core.\";\n if (opts.json) {\n io.err(JSON.stringify({ ok: false, message }, null, 2));\n } else {\n io.err(message);\n }\n return 1;\n }\n\n const doctor = buildUpgradeDoctorReport(project);\n if (opts.command === \"check\") {\n if (opts.json) {\n io.log(\n JSON.stringify({ ok: doctor.findings.length === 0, doctor }, null, 2),\n );\n } else {\n io.log(formatDoctorHuman(doctor));\n if (doctor.findings.length > 0) {\n io.err(\"\");\n io.err(FAILURE_GUIDANCE);\n }\n }\n return doctor.findings.length > 0 ? 1 : 0;\n }\n\n const result: UpgradeRunResult = {\n ok: true,\n dryRun: Boolean(opts.dryRun),\n doctor,\n steps: [],\n message: \"\",\n exitCode: 0,\n };\n\n if (doctor.findings.length > 0 && !opts.force) {\n result.ok = false;\n result.exitCode = 1;\n result.message =\n \"Blocked: framework overrides/patches for @agent-native/* are present. Remove them, then re-run upgrade (or pass --force to continue unsafely).\";\n result.steps.push({\n id: \"doctor\",\n status: \"failed\",\n detail: result.message,\n });\n if (opts.json) {\n io.err(JSON.stringify(result, null, 2));\n } else {\n io.log(formatDoctorHuman(doctor));\n io.err(\"\");\n io.err(result.message);\n io.err(\"\");\n io.err(FAILURE_GUIDANCE);\n }\n return 1;\n }\n\n result.steps.push({\n id: \"doctor\",\n status: doctor.findings.length > 0 ? \"ok\" : \"ok\",\n detail:\n doctor.findings.length > 0\n ? \"Continuing with --force despite framework overrides/patches\"\n : \"No framework overrides/patches\",\n });\n\n // Apply package.json bumps.\n if (doctor.bumps.length === 0) {\n result.steps.push({\n id: \"bump\",\n status: \"skipped\",\n detail: \"All @agent-native/* deps already use latest or local pins\",\n });\n } else if (opts.dryRun) {\n result.steps.push({\n id: \"bump\",\n status: \"planned\",\n detail: doctor.bumps\n .map(\n (b) =>\n `${relativeTo(project.root, b.file)} ${b.name}: ${b.from} → ${b.to}`,\n )\n .join(\"; \"),\n });\n } else {\n const byFile = new Map<string, AgentNativeDepBump[]>();\n for (const bump of doctor.bumps) {\n const list = byFile.get(bump.file) ?? [];\n list.push(bump);\n byFile.set(bump.file, list);\n }\n for (const [file, bumps] of byFile) {\n const pkg = readJsonFile(file);\n if (!pkg) continue;\n applyBumps(pkg, bumps);\n writeJsonFile(file, pkg);\n }\n result.steps.push({\n id: \"bump\",\n status: \"ok\",\n detail: `Updated ${doctor.bumps.length} @agent-native/* dependency pin(s)`,\n });\n }\n\n // Install.\n if (opts.skipInstall) {\n result.steps.push({\n id: \"install\",\n status: \"skipped\",\n detail: \"--skip-install\",\n });\n } else if (opts.dryRun) {\n result.steps.push({\n id: \"install\",\n status: \"planned\",\n detail: `${detectPackageManager(project.root)} install`,\n });\n } else {\n const pm = detectPackageManager(project.root);\n const spawned = io.spawn(pm, installArgs(pm), {\n cwd: project.root,\n stdio: opts.json ? \"pipe\" : \"inherit\",\n });\n if (spawned.status !== 0) {\n result.ok = false;\n result.exitCode = spawned.status ?? 1;\n result.message = `${pm} install failed`;\n result.steps.push({\n id: \"install\",\n status: \"failed\",\n detail: result.message,\n });\n emitResult(io, opts, result);\n return result.exitCode;\n }\n result.steps.push({ id: \"install\", status: \"ok\", detail: `${pm} install` });\n }\n\n // Skills refresh.\n if (opts.skipSkills) {\n result.steps.push({\n id: \"skills\",\n status: \"skipped\",\n detail: \"--skip-skills\",\n });\n } else if (opts.dryRun) {\n result.steps.push({\n id: \"skills\",\n status: \"planned\",\n detail: \"skills update scaffold --project\",\n });\n } else {\n try {\n await io.runSkillsUpdate(project.root);\n result.steps.push({\n id: \"skills\",\n status: \"ok\",\n detail: \"skills update scaffold --project\",\n });\n } catch (err) {\n result.ok = false;\n result.exitCode = 1;\n result.message = `skills update failed: ${err instanceof Error ? err.message : String(err)}`;\n result.steps.push({\n id: \"skills\",\n status: \"failed\",\n detail: result.message,\n });\n emitResult(io, opts, result);\n return result.exitCode;\n }\n }\n\n // Verify.\n if (opts.skipVerify) {\n result.steps.push({\n id: \"verify\",\n status: \"skipped\",\n detail: \"--skip-verify\",\n });\n } else if (opts.dryRun) {\n result.steps.push({\n id: \"verify\",\n status: \"planned\",\n detail: \"typecheck (when available)\",\n });\n } else {\n const rootPkg = readJsonFile(path.join(project.root, \"package.json\"));\n const hasTypecheck = Boolean(rootPkg?.scripts?.typecheck);\n if (!hasTypecheck) {\n result.steps.push({\n id: \"verify\",\n status: \"skipped\",\n detail: \"no typecheck script\",\n });\n } else {\n const pm = detectPackageManager(project.root);\n const args =\n pm === \"npm\"\n ? [\"run\", \"typecheck\"]\n : pm === \"yarn\"\n ? [\"typecheck\"]\n : [\"typecheck\"];\n const spawned = io.spawn(pm, args, {\n cwd: project.root,\n stdio: opts.json ? \"pipe\" : \"inherit\",\n });\n if (spawned.status !== 0) {\n result.ok = false;\n result.exitCode = spawned.status ?? 1;\n result.message = \"typecheck failed\";\n result.steps.push({\n id: \"verify\",\n status: \"failed\",\n detail: result.message,\n });\n emitResult(io, opts, result);\n return result.exitCode;\n }\n result.steps.push({ id: \"verify\", status: \"ok\", detail: \"typecheck\" });\n }\n }\n\n result.message = opts.dryRun\n ? \"Dry run complete. Re-run without --dry-run to apply.\"\n : \"Upgrade complete. If the app still fails to run, fix app-level code — do not patch @agent-native/*.\";\n emitResult(io, opts, result);\n return 0;\n}\n\nfunction emitResult(\n io: UpgradeIo,\n opts: UpgradeCliOptions,\n result: UpgradeRunResult,\n): void {\n if (opts.json) {\n const sink = result.ok ? io.log : io.err;\n sink(JSON.stringify(result, null, 2));\n return;\n }\n io.log(formatDoctorHuman(result.doctor));\n io.log(\"\");\n for (const step of result.steps) {\n io.log(\n `[${step.status}] ${step.id}${step.detail ? ` — ${step.detail}` : \"\"}`,\n );\n }\n io.log(\"\");\n if (result.ok) {\n io.log(result.message);\n } else {\n io.err(result.message);\n io.err(\"\");\n io.err(FAILURE_GUIDANCE);\n }\n}\n"]}
|
|
1
|
+
{"version":3,"file":"upgrade.js","sourceRoot":"","sources":["../../src/cli/upgrade.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AACH,OAAO,EAAE,SAAS,EAAyB,MAAM,o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AAE,CAAC,GAAG,CAAC,EAAE,CAAC,CAAC;QACX,EAAE,CAAC,GAAG,CAAC,gBAAgB,CAAC,CAAC;IAC3B,CAAC;AACH,CAAC","sourcesContent":["/**\n * `agent-native upgrade` — bring an existing Agent Native app/workspace current.\n *\n * Older branches often break after a core bump. Agents then invent\n * `pnpm.overrides` / patches against `@agent-native/*` (especially dispatch),\n * which makes things worse. This command is the supported path:\n *\n * 1. Doctor: refuse or warn on framework overrides/patches\n * 2. Bump `@agent-native/*` deps to `latest` (unless file:/link:/workspace:)\n * 3. Install\n * 4. Refresh scaffold skills (`skills update scaffold --project`)\n * 5. Verify with typecheck when available\n *\n * On failure: print the error and stop. Do not patch framework packages.\n */\nimport { spawnSync, type SpawnSyncReturns } from \"node:child_process\";\nimport fs from \"node:fs\";\nimport path from \"node:path\";\nimport { fileURLToPath } from \"node:url\";\n\nconst AGENT_NATIVE_SCOPE = \"@agent-native/\";\nconst PINNABLE_VERSION = \"latest\";\n\nexport type UpgradeCommand = \"run\" | \"check\" | \"help\";\n\nexport interface UpgradeCliOptions {\n command: UpgradeCommand;\n cwd?: string;\n dryRun?: boolean;\n codemods?: boolean;\n yes?: boolean;\n skipInstall?: boolean;\n skipVerify?: boolean;\n skipSkills?: boolean;\n json?: boolean;\n help?: boolean;\n /** Force past doctor findings that would otherwise block (not recommended). */\n force?: boolean;\n}\n\nexport interface PackageJsonLike {\n name?: string;\n version?: string;\n dependencies?: Record<string, string>;\n devDependencies?: Record<string, string>;\n optionalDependencies?: Record<string, string>;\n peerDependencies?: Record<string, string>;\n pnpm?: {\n overrides?: Record<string, string>;\n patchedDependencies?: Record<string, string>;\n };\n overrides?: Record<string, string>;\n resolutions?: Record<string, string>;\n scripts?: Record<string, string>;\n}\n\nexport interface FrameworkOverrideFinding {\n file: string;\n field: string;\n key: string;\n value: string;\n}\n\nexport interface AgentNativeDepBump {\n file: string;\n section: \"dependencies\" | \"devDependencies\" | \"optionalDependencies\";\n name: string;\n from: string;\n to: string;\n}\n\nexport interface UpgradeProject {\n root: string;\n kind: \"standalone\" | \"workspace\";\n packageFiles: string[];\n}\n\nexport interface UpgradeDoctorReport {\n project: UpgradeProject;\n findings: FrameworkOverrideFinding[];\n bumps: AgentNativeDepBump[];\n installedCoreVersion: string | null;\n cliCoreVersion: string | null;\n scaffoldStaleHint: boolean;\n}\n\nexport interface UpgradeRunResult {\n ok: boolean;\n dryRun: boolean;\n doctor: UpgradeDoctorReport;\n steps: Array<{\n id: string;\n status: \"ok\" | \"skipped\" | \"failed\" | \"planned\";\n detail?: string;\n }>;\n message: string;\n exitCode: number;\n codemod?: {\n files: string[];\n warnings: string[];\n diff: string;\n };\n}\n\nexport interface UpgradeIo {\n log: (message: string) => void;\n err: (message: string) => void;\n spawn: (\n command: string,\n args: string[],\n options: { cwd: string; stdio?: \"inherit\" | \"pipe\" },\n ) => SpawnSyncReturns<string | Buffer>;\n runSkillsUpdate: (cwd: string) => Promise<void>;\n}\n\nconst defaultIo: UpgradeIo = {\n log: (message) => console.log(message),\n err: (message) => console.error(message),\n spawn: (command, args, options) =>\n spawnSync(command, args, {\n cwd: options.cwd,\n stdio: options.stdio ?? \"inherit\",\n encoding: \"utf-8\",\n shell: process.platform === \"win32\",\n }),\n runSkillsUpdate: async (cwd) => {\n const { runSkills } = await import(\"./skills.js\");\n const previous = process.cwd();\n process.chdir(cwd);\n try {\n await runSkills([\"update\", \"scaffold\", \"--project\"]);\n } finally {\n process.chdir(previous);\n }\n },\n};\n\nexport function parseUpgradeArgs(argv: string[]): UpgradeCliOptions {\n const opts: UpgradeCliOptions = { command: \"run\" };\n for (let i = 0; i < argv.length; i++) {\n const arg = argv[i];\n if (arg === \"check\" || arg === \"doctor\") {\n opts.command = \"check\";\n } else if (arg === \"help\" || arg === \"--help\" || arg === \"-h\") {\n opts.command = \"help\";\n opts.help = true;\n } else if (arg === \"--dry-run\") {\n opts.dryRun = true;\n } else if (arg === \"--codemods\") {\n opts.codemods = true;\n } else if (arg === \"--yes\") {\n opts.yes = true;\n } else if (arg === \"--skip-install\") {\n opts.skipInstall = true;\n } else if (arg === \"--skip-verify\") {\n opts.skipVerify = true;\n } else if (arg === \"--skip-skills\") {\n opts.skipSkills = true;\n } else if (arg === \"--json\") {\n opts.json = true;\n } else if (arg === \"--force\") {\n opts.force = true;\n } else if (arg === \"--cwd\" && argv[i + 1]) {\n opts.cwd = argv[++i];\n } else if (arg.startsWith(\"--cwd=\")) {\n opts.cwd = arg.slice(\"--cwd=\".length);\n } else if (!arg.startsWith(\"-\")) {\n // Ignore unknown positional for forward-compat; help covers usage.\n }\n }\n return opts;\n}\n\nexport function printUpgradeHelp(io: Pick<UpgradeIo, \"log\"> = defaultIo): void {\n io.log(\n [\n \"Usage:\",\n \" agent-native upgrade Bring this app/workspace to current @agent-native/*\",\n \" agent-native upgrade check Doctor only: overrides, patches, pending bumps\",\n \" agent-native upgrade --dry-run Show the plan without writing or installing\",\n \" agent-native upgrade --codemods Preview manifest-driven import migrations\",\n \"\",\n \"Options:\",\n \" --skip-install Bump package.json only; do not run the package manager\",\n \" --codemods Rewrite moved Agent Native imports and exports (preview by default)\",\n \" --yes Apply codemods; without this flag --codemods is a dry run\",\n \" --skip-skills Skip `skills update scaffold --project`\",\n \" --skip-verify Skip typecheck after upgrade\",\n \" --force Continue even when framework overrides/patches are present\",\n \" --json Machine-readable report\",\n \" --cwd <dir> Run against a project root other than the current directory\",\n \"\",\n \"On failure: report the error and stop. Do NOT add pnpm.overrides,\",\n \"patchedDependencies, or local patches against @agent-native/* packages.\",\n \"Do NOT edit node_modules/@agent-native/* or invent dispatch/core behavior\",\n \"overrides. Revert those changes and re-run `agent-native upgrade`.\",\n ].join(\"\\n\"),\n );\n}\n\nfunction readJsonFile(filePath: string): PackageJsonLike | null {\n try {\n return JSON.parse(fs.readFileSync(filePath, \"utf-8\")) as PackageJsonLike;\n } catch {\n return null;\n }\n}\n\nfunction writeJsonFile(filePath: string, value: PackageJsonLike): void {\n fs.writeFileSync(filePath, `${JSON.stringify(value, null, 2)}\\n`);\n}\n\nexport function isAgentNativePackageName(name: string): boolean {\n return name === \"@agent-native\" || name.startsWith(AGENT_NATIVE_SCOPE);\n}\n\nexport function isPinnedOrLocalVersion(version: string): boolean {\n const v = version.trim();\n return (\n v.startsWith(\"file:\") ||\n v.startsWith(\"link:\") ||\n v.startsWith(\"workspace:\") ||\n v.startsWith(\"portal:\") ||\n v.startsWith(\"git+\") ||\n v.startsWith(\"github:\") ||\n v.startsWith(\"http:\") ||\n v.startsWith(\"https:\")\n );\n}\n\nexport function shouldBumpAgentNativeVersion(version: string): boolean {\n if (isPinnedOrLocalVersion(version)) return false;\n return version.trim() !== PINNABLE_VERSION;\n}\n\nfunction collectOverrideFindings(\n file: string,\n pkg: PackageJsonLike,\n): FrameworkOverrideFinding[] {\n const findings: FrameworkOverrideFinding[] = [];\n const tables: Array<{\n field: string;\n map: Record<string, string> | undefined;\n }> = [\n { field: \"pnpm.overrides\", map: pkg.pnpm?.overrides },\n { field: \"pnpm.patchedDependencies\", map: pkg.pnpm?.patchedDependencies },\n { field: \"overrides\", map: pkg.overrides },\n { field: \"resolutions\", map: pkg.resolutions },\n ];\n for (const table of tables) {\n if (!table.map) continue;\n for (const [key, value] of Object.entries(table.map)) {\n // Keys may be bare (`@agent-native/core`) or versioned\n // (`@agent-native/core@1.2.3` for patchedDependencies).\n if (key.includes(AGENT_NATIVE_SCOPE) || isAgentNativePackageName(key)) {\n findings.push({ file, field: table.field, key, value: String(value) });\n }\n }\n }\n return findings;\n}\n\nfunction collectBumps(\n file: string,\n pkg: PackageJsonLike,\n): AgentNativeDepBump[] {\n const bumps: AgentNativeDepBump[] = [];\n const sections = [\n \"dependencies\",\n \"devDependencies\",\n \"optionalDependencies\",\n ] as const;\n for (const section of sections) {\n const deps = pkg[section];\n if (!deps) continue;\n for (const [name, version] of Object.entries(deps)) {\n if (!isAgentNativePackageName(name)) continue;\n if (!shouldBumpAgentNativeVersion(version)) continue;\n bumps.push({\n file,\n section,\n name,\n from: version,\n to: PINNABLE_VERSION,\n });\n }\n }\n return bumps;\n}\n\nfunction applyBumps(pkg: PackageJsonLike, bumps: AgentNativeDepBump[]): void {\n for (const bump of bumps) {\n const section = pkg[bump.section];\n if (!section) continue;\n if (section[bump.name] === bump.from) {\n section[bump.name] = bump.to;\n }\n }\n}\n\nexport function detectUpgradeProject(cwd: string): UpgradeProject | null {\n const start = path.resolve(cwd);\n let dir = start;\n while (true) {\n const pkgPath = path.join(dir, \"package.json\");\n if (fs.existsSync(pkgPath)) {\n const pkg = readJsonFile(pkgPath);\n const hasCore =\n Boolean(pkg?.dependencies?.[\"@agent-native/core\"]) ||\n Boolean(pkg?.devDependencies?.[\"@agent-native/core\"]);\n const workspaceYaml = path.join(dir, \"pnpm-workspace.yaml\");\n const isWorkspace = fs.existsSync(workspaceYaml);\n if (hasCore || isWorkspace) {\n const packageFiles = [pkgPath];\n if (isWorkspace) {\n packageFiles.push(...workspacePackageFiles(dir, workspaceYaml));\n }\n return {\n root: dir,\n kind: isWorkspace ? \"workspace\" : \"standalone\",\n packageFiles: Array.from(new Set(packageFiles)),\n };\n }\n }\n const parent = path.dirname(dir);\n if (parent === dir) break;\n dir = parent;\n }\n return null;\n}\n\nfunction workspacePackageFiles(root: string, workspaceYaml: string): string[] {\n const patterns = parseWorkspacePackagePatterns(workspaceYaml);\n const included = new Set<string>();\n const excluded = new Set<string>();\n for (const rawPattern of patterns) {\n const exclude = rawPattern.startsWith(\"!\");\n const pattern = exclude ? rawPattern.slice(1) : rawPattern;\n const files = packageFilesForWorkspacePattern(root, pattern);\n for (const file of files) {\n if (exclude) excluded.add(file);\n else included.add(file);\n }\n }\n return Array.from(included)\n .filter((file) => !excluded.has(file))\n .sort();\n}\n\nfunction parseWorkspacePackagePatterns(workspaceYaml: string): string[] {\n let text = \"\";\n try {\n text = fs.readFileSync(workspaceYaml, \"utf-8\");\n } catch {\n return [\"apps/*\", \"packages/*\"];\n }\n const patterns: string[] = [];\n let inPackages = false;\n for (const line of text.split(/\\r?\\n/)) {\n const trimmed = line.trim();\n if (!trimmed || trimmed.startsWith(\"#\")) continue;\n if (/^[A-Za-z0-9_-]+:/.test(trimmed)) {\n inPackages = trimmed === \"packages:\";\n continue;\n }\n if (!inPackages || !trimmed.startsWith(\"-\")) continue;\n const pattern = trimmed\n .slice(1)\n .trim()\n .replace(/^['\"]|['\"]$/g, \"\");\n if (pattern) patterns.push(pattern);\n }\n return patterns.length ? patterns : [\"apps/*\", \"packages/*\"];\n}\n\nfunction packageFilesForWorkspacePattern(\n root: string,\n pattern: string,\n): string[] {\n const normalized = pattern.replace(/\\\\/g, \"/\").replace(/\\/+$/g, \"\");\n if (!normalized || normalized.includes(\"node_modules\")) return [];\n if (normalized.endsWith(\"/**\")) {\n return collectPackageFilesRecursive(\n path.join(root, normalized.slice(0, -3)),\n );\n }\n if (normalized.endsWith(\"/*\")) {\n const base = path.join(root, normalized.slice(0, -2));\n if (!fs.existsSync(base)) return [];\n return fs\n .readdirSync(base, { withFileTypes: true })\n .filter((entry) => entry.isDirectory())\n .map((entry) => path.join(base, entry.name, \"package.json\"))\n .filter((file) => fs.existsSync(file));\n }\n if (normalized.includes(\"*\")) {\n return collectPackageFilesRecursive(\n path.join(root, normalized.split(\"*\")[0]),\n );\n }\n const file = path.join(root, normalized, \"package.json\");\n return fs.existsSync(file) ? [file] : [];\n}\n\nfunction collectPackageFilesRecursive(dir: string): string[] {\n if (!fs.existsSync(dir)) return [];\n const files: string[] = [];\n for (const entry of fs.readdirSync(dir, { withFileTypes: true })) {\n if (!entry.isDirectory()) continue;\n if (entry.name === \"node_modules\" || entry.name === \".git\") continue;\n const child = path.join(dir, entry.name);\n const pkg = path.join(child, \"package.json\");\n if (fs.existsSync(pkg)) files.push(pkg);\n files.push(...collectPackageFilesRecursive(child));\n }\n return files;\n}\n\nfunction resolveInstalledPackageVersion(\n projectRoot: string,\n packageName: string,\n): string | null {\n let dir = projectRoot;\n while (true) {\n const candidate = path.join(\n dir,\n \"node_modules\",\n ...packageName.split(\"/\"),\n \"package.json\",\n );\n if (fs.existsSync(candidate)) {\n const pkg = readJsonFile(candidate);\n return typeof pkg?.version === \"string\" ? pkg.version : null;\n }\n const parent = path.dirname(dir);\n if (parent === dir) break;\n dir = parent;\n }\n return null;\n}\n\nfunction readCliCoreVersion(): string | null {\n try {\n const here = path.dirname(fileURLToPath(import.meta.url));\n const pkgPath = path.resolve(here, \"../../package.json\");\n const pkg = readJsonFile(pkgPath);\n return typeof pkg?.version === \"string\" ? pkg.version : null;\n } catch {\n return null;\n }\n}\n\nfunction detectPackageManager(projectRoot: string): \"pnpm\" | \"npm\" | \"yarn\" {\n if (fs.existsSync(path.join(projectRoot, \"pnpm-lock.yaml\"))) return \"pnpm\";\n if (fs.existsSync(path.join(projectRoot, \"yarn.lock\"))) return \"yarn\";\n if (fs.existsSync(path.join(projectRoot, \"package-lock.json\"))) return \"npm\";\n // Prefer pnpm for Agent Native scaffolds.\n return \"pnpm\";\n}\n\nfunction installArgs(pm: \"pnpm\" | \"npm\" | \"yarn\"): string[] {\n if (pm === \"npm\") return [\"install\"];\n if (pm === \"yarn\") return [\"install\"];\n return [\"install\"];\n}\n\nexport function buildUpgradeDoctorReport(\n project: UpgradeProject,\n): UpgradeDoctorReport {\n const findings: FrameworkOverrideFinding[] = [];\n const bumps: AgentNativeDepBump[] = [];\n for (const file of project.packageFiles) {\n const pkg = readJsonFile(file);\n if (!pkg) continue;\n findings.push(...collectOverrideFindings(file, pkg));\n bumps.push(...collectBumps(file, pkg));\n }\n const installedCoreVersion = resolveInstalledPackageVersion(\n project.root,\n \"@agent-native/core\",\n );\n const cliCoreVersion = readCliCoreVersion();\n const skillsUpdateScript = project.packageFiles.some((file) => {\n const pkg = readJsonFile(file);\n return Boolean(pkg?.scripts?.[\"skills:update\"]);\n });\n return {\n project,\n findings,\n bumps,\n installedCoreVersion,\n cliCoreVersion,\n scaffoldStaleHint: skillsUpdateScript || bumps.length > 0,\n };\n}\n\nfunction relativeTo(root: string, file: string): string {\n const rel = path.relative(root, file);\n return rel || \".\";\n}\n\nfunction formatDoctorHuman(report: UpgradeDoctorReport): string {\n const lines: string[] = [];\n lines.push(`Project: ${report.project.root} (${report.project.kind})`);\n if (report.installedCoreVersion) {\n lines.push(`Installed @agent-native/core: ${report.installedCoreVersion}`);\n } else {\n lines.push(\"Installed @agent-native/core: (not found in node_modules)\");\n }\n if (report.cliCoreVersion) {\n lines.push(`CLI package version: ${report.cliCoreVersion}`);\n }\n if (report.findings.length === 0) {\n lines.push(\"Framework overrides/patches: none\");\n } else {\n lines.push(\"Framework overrides/patches:\");\n for (const finding of report.findings) {\n lines.push(\n ` - ${relativeTo(report.project.root, finding.file)} ${finding.field}[\"${finding.key}\"] = ${finding.value}`,\n );\n }\n }\n if (report.bumps.length === 0) {\n lines.push(\"Pending @agent-native/* bumps: none\");\n } else {\n lines.push(\"Pending @agent-native/* bumps:\");\n for (const bump of report.bumps) {\n lines.push(\n ` - ${relativeTo(report.project.root, bump.file)} ${bump.name}: ${bump.from} → ${bump.to}`,\n );\n }\n }\n return lines.join(\"\\n\");\n}\n\nconst FAILURE_GUIDANCE = [\n \"Upgrade failed. Do not paper over this with framework patches.\",\n \"Never add pnpm.overrides / patchedDependencies / resolutions for @agent-native/*.\",\n \"Never edit node_modules/@agent-native/* or invent local dispatch/core behavior overrides.\",\n \"Revert those changes if present, fix the app-level compile/runtime error, then re-run:\",\n \" npx @agent-native/core@latest upgrade\",\n].join(\"\\n\");\n\nexport async function runUpgrade(\n argv: string[],\n io: UpgradeIo = defaultIo,\n): Promise<number> {\n const opts = parseUpgradeArgs(argv);\n if (opts.help || opts.command === \"help\") {\n printUpgradeHelp(io);\n return 0;\n }\n\n const cwd = path.resolve(opts.cwd ?? process.cwd());\n const project = detectUpgradeProject(cwd);\n if (!project) {\n const message =\n \"No Agent Native app/workspace found. Run from an app or workspace root that depends on @agent-native/core.\";\n if (opts.json) {\n io.err(JSON.stringify({ ok: false, message }, null, 2));\n } else {\n io.err(message);\n }\n return 1;\n }\n\n const doctor = buildUpgradeDoctorReport(project);\n if (opts.command === \"check\") {\n if (opts.json) {\n io.log(\n JSON.stringify({ ok: doctor.findings.length === 0, doctor }, null, 2),\n );\n } else {\n io.log(formatDoctorHuman(doctor));\n if (doctor.findings.length > 0) {\n io.err(\"\");\n io.err(FAILURE_GUIDANCE);\n }\n }\n return doctor.findings.length > 0 ? 1 : 0;\n }\n\n const dryRun = Boolean(opts.dryRun || (opts.codemods && !opts.yes));\n const result: UpgradeRunResult = {\n ok: true,\n dryRun,\n doctor,\n steps: [],\n message: \"\",\n exitCode: 0,\n };\n\n if (doctor.findings.length > 0 && !opts.force) {\n result.ok = false;\n result.exitCode = 1;\n result.message =\n \"Blocked: framework overrides/patches for @agent-native/* are present. Remove them, then re-run upgrade (or pass --force to continue unsafely).\";\n result.steps.push({\n id: \"doctor\",\n status: \"failed\",\n detail: result.message,\n });\n if (opts.json) {\n io.err(JSON.stringify(result, null, 2));\n } else {\n io.log(formatDoctorHuman(doctor));\n io.err(\"\");\n io.err(result.message);\n io.err(\"\");\n io.err(FAILURE_GUIDANCE);\n }\n return 1;\n }\n\n result.steps.push({\n id: \"doctor\",\n status: doctor.findings.length > 0 ? \"ok\" : \"ok\",\n detail:\n doctor.findings.length > 0\n ? \"Continuing with --force despite framework overrides/patches\"\n : \"No framework overrides/patches\",\n });\n\n // Apply package.json bumps.\n if (doctor.bumps.length === 0) {\n result.steps.push({\n id: \"bump\",\n status: \"skipped\",\n detail: \"All @agent-native/* deps already use latest or local pins\",\n });\n } else if (dryRun) {\n result.steps.push({\n id: \"bump\",\n status: \"planned\",\n detail: doctor.bumps\n .map(\n (b) =>\n `${relativeTo(project.root, b.file)} ${b.name}: ${b.from} → ${b.to}`,\n )\n .join(\"; \"),\n });\n } else {\n const byFile = new Map<string, AgentNativeDepBump[]>();\n for (const bump of doctor.bumps) {\n const list = byFile.get(bump.file) ?? [];\n list.push(bump);\n byFile.set(bump.file, list);\n }\n for (const [file, bumps] of byFile) {\n const pkg = readJsonFile(file);\n if (!pkg) continue;\n applyBumps(pkg, bumps);\n writeJsonFile(file, pkg);\n }\n result.steps.push({\n id: \"bump\",\n status: \"ok\",\n detail: `Updated ${doctor.bumps.length} @agent-native/* dependency pin(s)`,\n });\n }\n\n if (opts.codemods) {\n const { formatMigrationCodemodDiff, runMigrationCodemods } =\n await import(\"./migration-codemod.js\");\n const codemodResult = runMigrationCodemods({\n root: project.root,\n apply: !dryRun,\n });\n const diff = formatMigrationCodemodDiff(codemodResult, project.root);\n result.codemod = {\n files: codemodResult.changes.map((change) =>\n relativeTo(project.root, change.file),\n ),\n warnings: codemodResult.warnings,\n diff,\n };\n result.steps.push({\n id: \"codemods\",\n status:\n codemodResult.changes.length === 0\n ? \"skipped\"\n : dryRun\n ? \"planned\"\n : \"ok\",\n detail:\n codemodResult.changes.length === 0\n ? \"No manifest migrations found\"\n : `${dryRun ? \"Would update\" : \"Updated\"} ${codemodResult.changes.length} file(s)`,\n });\n if (!opts.json && diff) {\n io.log(diff);\n io.log(\"\");\n }\n if (!opts.json) {\n for (const warning of codemodResult.warnings) {\n io.err(`[codemods] ${warning}`);\n }\n }\n }\n\n // Install.\n if (opts.skipInstall) {\n result.steps.push({\n id: \"install\",\n status: \"skipped\",\n detail: \"--skip-install\",\n });\n } else if (dryRun) {\n result.steps.push({\n id: \"install\",\n status: \"planned\",\n detail: `${detectPackageManager(project.root)} install`,\n });\n } else {\n const pm = detectPackageManager(project.root);\n const spawned = io.spawn(pm, installArgs(pm), {\n cwd: project.root,\n stdio: opts.json ? \"pipe\" : \"inherit\",\n });\n if (spawned.status !== 0) {\n result.ok = false;\n result.exitCode = spawned.status ?? 1;\n result.message = `${pm} install failed`;\n result.steps.push({\n id: \"install\",\n status: \"failed\",\n detail: result.message,\n });\n emitResult(io, opts, result);\n return result.exitCode;\n }\n result.steps.push({ id: \"install\", status: \"ok\", detail: `${pm} install` });\n }\n\n // Skills refresh.\n if (opts.skipSkills) {\n result.steps.push({\n id: \"skills\",\n status: \"skipped\",\n detail: \"--skip-skills\",\n });\n } else if (dryRun) {\n result.steps.push({\n id: \"skills\",\n status: \"planned\",\n detail: \"skills update scaffold --project\",\n });\n } else {\n try {\n await io.runSkillsUpdate(project.root);\n result.steps.push({\n id: \"skills\",\n status: \"ok\",\n detail: \"skills update scaffold --project\",\n });\n } catch (err) {\n result.ok = false;\n result.exitCode = 1;\n result.message = `skills update failed: ${err instanceof Error ? err.message : String(err)}`;\n result.steps.push({\n id: \"skills\",\n status: \"failed\",\n detail: result.message,\n });\n emitResult(io, opts, result);\n return result.exitCode;\n }\n }\n\n // Verify.\n if (opts.skipVerify) {\n result.steps.push({\n id: \"verify\",\n status: \"skipped\",\n detail: \"--skip-verify\",\n });\n } else if (dryRun) {\n result.steps.push({\n id: \"verify\",\n status: \"planned\",\n detail: \"typecheck (when available)\",\n });\n } else {\n const rootPkg = readJsonFile(path.join(project.root, \"package.json\"));\n const hasTypecheck = Boolean(rootPkg?.scripts?.typecheck);\n if (!hasTypecheck) {\n result.steps.push({\n id: \"verify\",\n status: \"skipped\",\n detail: \"no typecheck script\",\n });\n } else {\n const pm = detectPackageManager(project.root);\n const args =\n pm === \"npm\"\n ? [\"run\", \"typecheck\"]\n : pm === \"yarn\"\n ? [\"typecheck\"]\n : [\"typecheck\"];\n const spawned = io.spawn(pm, args, {\n cwd: project.root,\n stdio: opts.json ? \"pipe\" : \"inherit\",\n });\n if (spawned.status !== 0) {\n result.ok = false;\n result.exitCode = spawned.status ?? 1;\n result.message = \"typecheck failed\";\n result.steps.push({\n id: \"verify\",\n status: \"failed\",\n detail: result.message,\n });\n emitResult(io, opts, result);\n return result.exitCode;\n }\n result.steps.push({ id: \"verify\", status: \"ok\", detail: \"typecheck\" });\n }\n }\n\n result.message = dryRun\n ? opts.codemods && !opts.yes\n ? \"Codemod preview complete. Re-run with --codemods --yes to apply.\"\n : \"Dry run complete. Re-run without --dry-run to apply.\"\n : \"Upgrade complete. If the app still fails to run, fix app-level code — do not patch @agent-native/*.\";\n emitResult(io, opts, result);\n return 0;\n}\n\nfunction emitResult(\n io: UpgradeIo,\n opts: UpgradeCliOptions,\n result: UpgradeRunResult,\n): void {\n if (opts.json) {\n const sink = result.ok ? io.log : io.err;\n sink(JSON.stringify(result, null, 2));\n return;\n }\n io.log(formatDoctorHuman(result.doctor));\n io.log(\"\");\n for (const step of result.steps) {\n io.log(\n `[${step.status}] ${step.id}${step.detail ? ` — ${step.detail}` : \"\"}`,\n );\n }\n io.log(\"\");\n if (result.ok) {\n io.log(result.message);\n } else {\n io.err(result.message);\n io.err(\"\");\n io.err(FAILURE_GUIDANCE);\n }\n}\n"]}
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
export { AgentAskPopover, type AgentAskPopoverProps, } from "../AgentAskPopover.js";
|
|
2
|
+
export { addContextToAgentChat, appendAgentChatContextToMessage, clearAgentChatContext, formatAgentChatContextItemsForPrompt, insertAgentComposerReference, listAgentChatContext, normalizeAgentComposerReference, refreshAgentChatContext, removeAgentChatContextItem, requestAgentChatThreadOpen, requestAgentTaskOpen, sendToAgentChat, sendToAgentChatAndConfirm, reportAgentChatSubmitResult, AGENT_CHAT_SUBMIT_RESULT_EVENT, parseSubmitChatMessage, setAgentChatContextItem, setContextToAgentChat, generateTabId, type ParsedSubmitChat, type AgentChatOpenTaskRequest, type AgentChatOpenThreadRequest, type AgentChatContextItem, type AgentChatContextMessage, type AgentChatContextMutationOptions, type AgentChatContextRemoveOptions, type AgentChatContextSetOptions, type AgentChatContextState, type AgentChatMessage, type AgentChatSubmitResult, type SendToAgentChatAndConfirmResult, type AgentComposerReference, type AgentComposerReferenceInsertOptions, type AgentComposerReferenceInsertPayload, } from "../agent-chat.js";
|
|
3
|
+
export { saveAgentEngineApiKey, saveAgentEngineProviderSettings, type AgentEngineProvider, type SaveAgentEngineApiKeyOptions, type SaveAgentEngineProviderSettingsOptions, } from "../agent-engine-key.js";
|
|
4
|
+
export { useAgentChatGenerating } from "../use-agent-chat.js";
|
|
5
|
+
export { useAgentChatContext, type UseAgentChatContextResult, } from "../use-agent-chat-context.js";
|
|
6
|
+
export { useCodeMode, useDevMode } from "../use-dev-mode.js";
|
|
7
|
+
export { codeAgentTranscriptEventsToContent, codeAgentTranscriptHasPendingApproval, createCodeAgentChatAdapter, type CodeAgentChatController, type CodeAgentChatControlResult, type CodeAgentChatFollowUpMode, type CodeAgentChatTranscriptEvent, type CreateCodeAgentChatAdapterOptions, } from "../code-agent-chat-adapter.js";
|
|
8
|
+
export { buildRepositoryFromCodeAgentTranscript, type BuildRepositoryFromCodeAgentTranscriptOptions, type CodeAgentThreadTranscriptEvent, } from "../../agent/thread-data-builder.js";
|
|
9
|
+
export { compareCodeAgentTranscriptEvents, getCodeAgentTranscriptSeq, isCodeAgentRunActive, mergeCodeAgentTranscriptEvents, type CodeAgentRunStateLike, type CodeAgentTranscriptOrderEvent, } from "../../code-agents/transcript-order.js";
|
|
10
|
+
export { CREDENTIAL_GAP_SIGNAL, isCredentialGapCodeAgentEvent, } from "../../code-agents/transcript-normalizer.js";
|
|
11
|
+
export { useSendToAgentChat } from "../use-send-to-agent-chat.js";
|
|
12
|
+
export { useChatModels, type UseChatModelsResult, type EngineModelGroup, } from "../use-chat-models.js";
|
|
13
|
+
export { CodeRequiredDialog, type CodeRequiredDialogProps, } from "../components/CodeRequiredDialog.js";
|
|
14
|
+
export { useAgentEngineConfigured, type AgentEngineConfiguredState, type UseAgentEngineConfiguredResult, } from "../use-agent-engine-configured.js";
|
|
15
|
+
export { BuilderSetupCard } from "../chat/run-recovery.js";
|
|
16
|
+
export { AgentConversation, AgentConversationMessageView, normalizeCodeAgentTranscriptForConversation, useNearBottomAutoscroll, type CodeAgentConversationTranscriptEvent, type CodeAgentConversationTranscriptEventType, type NormalizeCodeAgentTranscriptOptions, type AgentConversationArtifact, type AgentConversationAttachment, type AgentConversationMessage, type AgentConversationMessagePart, type AgentConversationMessageRole, type AgentConversationNotice, type AgentConversationNoticeTone, type AgentConversationToolCall, type AgentConversationToolState, } from "../conversation/index.js";
|
|
17
|
+
export { McpAppRenderer } from "../mcp-apps/McpAppRenderer.js";
|
|
18
|
+
export { AGENT_NATIVE_MCP_APP_HOST_MESSAGE_TYPES, getMcpAppHostContext, openMcpAppHostLink, requestMcpAppDisplayMode, sendMcpAppHostMessage, updateMcpAppModelContext, useMcpAppHostContext, type AgentNativeMcpAppHostMessageType, type McpAppDisplayMode, type McpAppHostChatMessage, type McpAppHostCapabilities, type McpAppHostContext, type McpAppHostContextSnapshot, type McpAppModelContextContentPart, type McpAppModelContextUpdate, } from "../mcp-app-host.js";
|
|
19
|
+
export { CodeAgentIndicator, type CodeAgentIndicatorProps, } from "../components/CodeAgentIndicator.js";
|
|
20
|
+
export { buildDynamicAgentSuggestions, dedupeSuggestions, mergeAgentSuggestions, normalizeAgentDynamicSuggestionsConfig, useAgentDynamicSuggestions, type AgentDynamicSuggestionContext, type AgentDynamicSuggestionsConfig, type AgentDynamicSuggestionsOption, } from "../dynamic-suggestions.js";
|
|
21
|
+
export { AssistantChat, clearChatStorage, type AssistantChatProps, type AssistantChatHandle, type AssistantChatAdapterContext, } from "../AssistantChat.js";
|
|
22
|
+
export { MultiTabAssistantChat, type MultiTabAssistantChatProps, type MultiTabAssistantChatHeaderProps, } from "../MultiTabAssistantChat.js";
|
|
23
|
+
export { RunStuckBanner, type RunStuckBannerProps } from "../RunStuckBanner.js";
|
|
24
|
+
export { KeepTabOpenNotice, type KeepTabOpenNoticeProps, } from "../KeepTabOpenNotice.js";
|
|
25
|
+
export { useRunStuckDetection, useAbortRun, type RunStuckState, type UseRunStuckDetectionOptions, } from "../use-run-stuck-detection.js";
|
|
26
|
+
export { createAgentChatAdapter, type AgentChatSurfaceKind, type CreateAgentChatAdapterOptions, } from "../agent-chat-adapter.js";
|
|
27
|
+
export { GuidedQuestionFlow, useGuidedQuestionFlow, askUserQuestion, formatGuidedAnswerValue, formatGuidedAnswersForAgent, getOtherGuidedAnswerText, hasGuidedAnswer, isOtherGuidedAnswer, makeOtherGuidedAnswer, normalizeGuidedAnswers, type AskUserQuestionInput, type AskUserQuestionOption, type AskUserQuestionResult, type GuidedQuestion, type GuidedQuestionAnswers, type GuidedQuestionFlowProps, type GuidedQuestionOption, type GuidedQuestionPayload, type GuidedQuestionType, type UseGuidedQuestionFlowOptions, } from "../guided-questions.js";
|
|
28
|
+
export { useChatThreads, type ChatThreadScope, type ChatThreadSnapshot, type ChatThreadSummary, type ChatThreadData, type ChatThreadShareLink, type ChatThreadShareState, type UseChatThreadsOptions, } from "../use-chat-threads.js";
|
|
29
|
+
export { ChatHistoryList, type ChatHistoryItem, type ChatHistorySection, type ChatHistoryListProps, } from "../chat/ChatHistoryList.js";
|
|
30
|
+
export { AgentChatHome, type AgentChatHomeProps } from "../AgentChatHome.js";
|
|
31
|
+
export { AgentChatSurface, AgentPanel, AgentSidebar, AgentToggleButton, focusAgentChat, type AgentChatSurfaceMode, type AgentChatSurfaceProps, type AgentPanelProps, type AgentSidebarProps, } from "../AgentPanel.js";
|
|
32
|
+
export { AgentTabsPage, type AgentPageExtraTabContext, type AgentPageExtraTabFactory, type AgentTabsPageProps, } from "../agent-page/AgentTabsPage.js";
|
|
33
|
+
export type { AgentPageScope, AgentPageTabProps } from "../agent-page/types.js";
|
|
34
|
+
export { AGENT_CHAT_HOME_HANDOFF_TTL_MS, AGENT_CHAT_VIEW_TRANSITION_CLASS, AGENT_CHAT_VIEW_TRANSITION_NAME, consumeAgentChatHomeHandoff, getAgentChatViewTransitionStyle, isAgentChatHomeHandoffActive, markAgentChatHomeHandoff, navigateWithAgentChatViewTransition, startAgentChatViewTransition, supportsAgentChatViewTransition, type AgentChatHomeHandoffOptions, type AgentChatViewTransition, type AgentChatViewTransitionOptions, } from "../chat-view-transition.js";
|
|
35
|
+
export { useAgentChatHomeHandoff, useAgentChatHomeHandoffLinks, type UseAgentChatHomeHandoffLinksOptions, type UseAgentChatHomeHandoffOptions, } from "../use-agent-chat-home-handoff.js";
|
|
36
|
+
export { requestAgentSidebarOpen, SIDEBAR_STATE_CHANGE_EVENT, setAgentSidebarOpenPreference, type AgentSidebarStateChangeDetail, type AgentSidebarStateMode, type AgentSidebarStateSource, } from "../agent-sidebar-state.js";
|
|
37
|
+
export { clearReservedToolRenderersForTests, clearToolRenderersForTests, registerActionChatRenderer, registerFallbackToolRenderer, registerReservedActionChatRenderer, registerReservedFallbackToolRenderer, registerReservedToolRenderer, registerToolRenderer, resolveToolRenderer, type ActionChatRendererRegistration, type ToolRendererComponent, type ToolRendererContext, type ToolRendererMatch, type ToolRendererProps, type ToolRendererRegistration, } from "../chat/tool-render-registry.js";
|
|
38
|
+
export * from "../chat/connectors.js";
|
|
39
|
+
export * from "../chat/runtime.js";
|
|
40
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/client/agent-chat/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,eAAe,EACf,KAAK,oBAAoB,GAC1B,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EACL,qBAAqB,EACrB,+BAA+B,EAC/B,qBAAqB,EACrB,oCAAoC,EACpC,4BAA4B,EAC5B,oBAAoB,EACpB,+BAA+B,EAC/B,uBAAuB,EACvB,0BAA0B,EAC1B,0BAA0B,EAC1B,oBAAoB,EACpB,eAAe,EACf,yBAAyB,EACzB,2BAA2B,EAC3B,8BAA8B,EAC9B,sBAAsB,EACtB,uBAAuB,EACvB,qBAAqB,EACrB,aAAa,EACb,KAAK,gBAAgB,EACrB,KAAK,wBAAwB,EAC7B,KAAK,0BAA0B,EAC/B,KAAK,oBAAoB,EACzB,KAAK,uBAAuB,EAC5B,KAAK,+BAA+B,EACpC,KAAK,6BAA6B,EAClC,KAAK,0BAA0B,EAC/B,KAAK,qBAAqB,EAC1B,KAAK,gBAAgB,EACrB,KAAK,qBAAqB,EAC1B,KAAK,+BAA+B,EACpC,KAAK,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AAC;AAC1B,OAAO,EACL,aAAa,EACb,KAAK,wBAAwB,EAC7B,KAAK,wBAAwB,EAC7B,KAAK,kBAAkB,GACxB,MAAM,gCAAgC,CAAC;AACxC,YAAY,EAAE,cAAc,EAAE,iBAAiB,EAAE,MAAM,wBAAwB,CAAC;AAChF,OAAO,EACL,8BAA8B,EAC9B,gCAAgC,EAChC,+BAA+B,EAC/B,2BAA2B,EAC3B,+BAA+B,EAC/B,4BAA4B,EAC5B,wBAAwB,EACxB,mCAAmC,EACnC,4BAA4B,EAC5B,+BAA+B,EAC/B,KAAK,2BAA2B,EAChC,KAAK,uBAAuB,EAC5B,KAAK,8BAA8B,GACpC,MAAM,4BAA4B,CAAC;AACpC,OAAO,EACL,uBAAuB,EACvB,4BAA4B,EAC5B,KAAK,mCAAmC,EACxC,KAAK,8BAA8B,GACpC,MAAM,mCAAmC,CAAC;AAC3C,OAAO,EACL,uBAAuB,EACvB,0BAA0B,EAC1B,6BAA6B,EAC7B,KAAK,6BAA6B,EAClC,KAAK,qBAAqB,EAC1B,KAAK,uBAAuB,GAC7B,MAAM,2BAA2B,CAAC;AACnC,OAAO,EACL,kCAAkC,EAClC,0BAA0B,EAC1B,0BAA0B,EAC1B,4BAA4B,EAC5B,kCAAkC,EAClC,oCAAoC,EACpC,4BAA4B,EAC5B,oBAAoB,EACpB,mBAAmB,EACnB,KAAK,8BAA8B,EACnC,KAAK,qBAAqB,EAC1B,KAAK,mBAAmB,EACxB,KAAK,iBAAiB,EACtB,KAAK,iBAAiB,EACtB,KAAK,wBAAwB,GAC9B,MAAM,iCAAiC,CAAC;AACzC,cAAc,uBAAuB,CAAC;AACtC,cAAc,oBAAoB,CAAC"}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
export { AgentAskPopover, } from "../AgentAskPopover.js";
|
|
2
|
+
export { addContextToAgentChat, appendAgentChatContextToMessage, clearAgentChatContext, formatAgentChatContextItemsForPrompt, insertAgentComposerReference, listAgentChatContext, normalizeAgentComposerReference, refreshAgentChatContext, removeAgentChatContextItem, requestAgentChatThreadOpen, requestAgentTaskOpen, sendToAgentChat, sendToAgentChatAndConfirm, reportAgentChatSubmitResult, AGENT_CHAT_SUBMIT_RESULT_EVENT, parseSubmitChatMessage, setAgentChatContextItem, setContextToAgentChat, generateTabId, } from "../agent-chat.js";
|
|
3
|
+
export { saveAgentEngineApiKey, saveAgentEngineProviderSettings, } from "../agent-engine-key.js";
|
|
4
|
+
export { useAgentChatGenerating } from "../use-agent-chat.js";
|
|
5
|
+
export { useAgentChatContext, } from "../use-agent-chat-context.js";
|
|
6
|
+
export { useCodeMode, useDevMode } from "../use-dev-mode.js";
|
|
7
|
+
export { codeAgentTranscriptEventsToContent, codeAgentTranscriptHasPendingApproval, createCodeAgentChatAdapter, } from "../code-agent-chat-adapter.js";
|
|
8
|
+
export { buildRepositoryFromCodeAgentTranscript, } from "../../agent/thread-data-builder.js";
|
|
9
|
+
export { compareCodeAgentTranscriptEvents, getCodeAgentTranscriptSeq, isCodeAgentRunActive, mergeCodeAgentTranscriptEvents, } from "../../code-agents/transcript-order.js";
|
|
10
|
+
export { CREDENTIAL_GAP_SIGNAL, isCredentialGapCodeAgentEvent, } from "../../code-agents/transcript-normalizer.js";
|
|
11
|
+
export { useSendToAgentChat } from "../use-send-to-agent-chat.js";
|
|
12
|
+
export { useChatModels, } from "../use-chat-models.js";
|
|
13
|
+
export { CodeRequiredDialog, } from "../components/CodeRequiredDialog.js";
|
|
14
|
+
export { useAgentEngineConfigured, } from "../use-agent-engine-configured.js";
|
|
15
|
+
export { BuilderSetupCard } from "../chat/run-recovery.js";
|
|
16
|
+
export { AgentConversation, AgentConversationMessageView, normalizeCodeAgentTranscriptForConversation, useNearBottomAutoscroll, } from "../conversation/index.js";
|
|
17
|
+
export { McpAppRenderer } from "../mcp-apps/McpAppRenderer.js";
|
|
18
|
+
export { AGENT_NATIVE_MCP_APP_HOST_MESSAGE_TYPES, getMcpAppHostContext, openMcpAppHostLink, requestMcpAppDisplayMode, sendMcpAppHostMessage, updateMcpAppModelContext, useMcpAppHostContext, } from "../mcp-app-host.js";
|
|
19
|
+
export { CodeAgentIndicator, } from "../components/CodeAgentIndicator.js";
|
|
20
|
+
export { buildDynamicAgentSuggestions, dedupeSuggestions, mergeAgentSuggestions, normalizeAgentDynamicSuggestionsConfig, useAgentDynamicSuggestions, } from "../dynamic-suggestions.js";
|
|
21
|
+
export { AssistantChat, clearChatStorage, } from "../AssistantChat.js";
|
|
22
|
+
export { MultiTabAssistantChat, } from "../MultiTabAssistantChat.js";
|
|
23
|
+
export { RunStuckBanner } from "../RunStuckBanner.js";
|
|
24
|
+
export { KeepTabOpenNotice, } from "../KeepTabOpenNotice.js";
|
|
25
|
+
export { useRunStuckDetection, useAbortRun, } from "../use-run-stuck-detection.js";
|
|
26
|
+
export { createAgentChatAdapter, } from "../agent-chat-adapter.js";
|
|
27
|
+
export { GuidedQuestionFlow, useGuidedQuestionFlow, askUserQuestion, formatGuidedAnswerValue, formatGuidedAnswersForAgent, getOtherGuidedAnswerText, hasGuidedAnswer, isOtherGuidedAnswer, makeOtherGuidedAnswer, normalizeGuidedAnswers, } from "../guided-questions.js";
|
|
28
|
+
export { useChatThreads, } from "../use-chat-threads.js";
|
|
29
|
+
export { ChatHistoryList, } from "../chat/ChatHistoryList.js";
|
|
30
|
+
export { AgentChatHome } from "../AgentChatHome.js";
|
|
31
|
+
export { AgentChatSurface, AgentPanel, AgentSidebar, AgentToggleButton, focusAgentChat, } from "../AgentPanel.js";
|
|
32
|
+
export { AgentTabsPage, } from "../agent-page/AgentTabsPage.js";
|
|
33
|
+
export { AGENT_CHAT_HOME_HANDOFF_TTL_MS, AGENT_CHAT_VIEW_TRANSITION_CLASS, AGENT_CHAT_VIEW_TRANSITION_NAME, consumeAgentChatHomeHandoff, getAgentChatViewTransitionStyle, isAgentChatHomeHandoffActive, markAgentChatHomeHandoff, navigateWithAgentChatViewTransition, startAgentChatViewTransition, supportsAgentChatViewTransition, } from "../chat-view-transition.js";
|
|
34
|
+
export { useAgentChatHomeHandoff, useAgentChatHomeHandoffLinks, } from "../use-agent-chat-home-handoff.js";
|
|
35
|
+
export { requestAgentSidebarOpen, SIDEBAR_STATE_CHANGE_EVENT, setAgentSidebarOpenPreference, } from "../agent-sidebar-state.js";
|
|
36
|
+
export { clearReservedToolRenderersForTests, clearToolRenderersForTests, registerActionChatRenderer, registerFallbackToolRenderer, registerReservedActionChatRenderer, registerReservedFallbackToolRenderer, registerReservedToolRenderer, registerToolRenderer, resolveToolRenderer, } from "../chat/tool-render-registry.js";
|
|
37
|
+
export * from "../chat/connectors.js";
|
|
38
|
+
export * from "../chat/runtime.js";
|
|
39
|
+
//# sourceMappingURL=index.js.map
|