@agent-native/core 0.97.0 → 0.98.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 +2 -2
- package/corpus/core/CHANGELOG.md +56 -0
- package/corpus/core/docs/content/authentication.mdx +3 -3
- package/corpus/core/docs/content/doctor.mdx +170 -0
- package/corpus/core/docs/content/external-agents.mdx +8 -7
- package/corpus/core/docs/content/locales/ar-SA/authentication.mdx +2 -2
- package/corpus/core/docs/content/locales/ar-SA/external-agents.mdx +8 -7
- package/corpus/core/docs/content/locales/ar-SA/mcp-protocol.mdx +1 -1
- package/corpus/core/docs/content/locales/ar-SA/security.mdx +2 -0
- package/corpus/core/docs/content/locales/de-DE/authentication.mdx +1 -1
- package/corpus/core/docs/content/locales/de-DE/external-agents.mdx +8 -7
- package/corpus/core/docs/content/locales/de-DE/mcp-protocol.mdx +1 -1
- package/corpus/core/docs/content/locales/de-DE/security.mdx +2 -0
- package/corpus/core/docs/content/locales/es-ES/authentication.mdx +2 -2
- package/corpus/core/docs/content/locales/es-ES/external-agents.mdx +8 -7
- package/corpus/core/docs/content/locales/es-ES/mcp-protocol.mdx +1 -1
- package/corpus/core/docs/content/locales/es-ES/security.mdx +2 -0
- package/corpus/core/docs/content/locales/fr-FR/authentication.mdx +1 -1
- package/corpus/core/docs/content/locales/fr-FR/external-agents.mdx +8 -7
- package/corpus/core/docs/content/locales/fr-FR/mcp-protocol.mdx +1 -1
- package/corpus/core/docs/content/locales/fr-FR/security.mdx +2 -0
- package/corpus/core/docs/content/locales/hi-IN/authentication.mdx +2 -2
- package/corpus/core/docs/content/locales/hi-IN/external-agents.mdx +8 -7
- package/corpus/core/docs/content/locales/hi-IN/mcp-protocol.mdx +1 -1
- package/corpus/core/docs/content/locales/hi-IN/security.mdx +2 -0
- package/corpus/core/docs/content/locales/ja-JP/authentication.mdx +2 -2
- package/corpus/core/docs/content/locales/ja-JP/external-agents.mdx +8 -7
- package/corpus/core/docs/content/locales/ja-JP/mcp-protocol.mdx +1 -1
- package/corpus/core/docs/content/locales/ja-JP/security.mdx +2 -0
- package/corpus/core/docs/content/locales/ko-KR/authentication.mdx +2 -2
- package/corpus/core/docs/content/locales/ko-KR/external-agents.mdx +8 -7
- package/corpus/core/docs/content/locales/ko-KR/mcp-protocol.mdx +1 -1
- package/corpus/core/docs/content/locales/ko-KR/security.mdx +2 -0
- package/corpus/core/docs/content/locales/pt-BR/authentication.mdx +2 -2
- package/corpus/core/docs/content/locales/pt-BR/external-agents.mdx +8 -7
- package/corpus/core/docs/content/locales/pt-BR/mcp-protocol.mdx +1 -1
- package/corpus/core/docs/content/locales/pt-BR/security.mdx +2 -0
- package/corpus/core/docs/content/locales/zh-CN/authentication.mdx +2 -2
- package/corpus/core/docs/content/locales/zh-CN/external-agents.mdx +8 -7
- package/corpus/core/docs/content/locales/zh-CN/mcp-protocol.mdx +1 -1
- package/corpus/core/docs/content/locales/zh-CN/security.mdx +2 -0
- package/corpus/core/docs/content/locales/zh-TW/authentication.mdx +2 -2
- package/corpus/core/docs/content/locales/zh-TW/external-agents.mdx +8 -7
- package/corpus/core/docs/content/locales/zh-TW/mcp-protocol.mdx +1 -1
- package/corpus/core/docs/content/locales/zh-TW/security.mdx +2 -0
- package/corpus/core/docs/content/mcp-protocol.mdx +1 -1
- package/corpus/core/docs/content/security.mdx +2 -0
- package/corpus/core/package.json +6 -2
- package/corpus/core/scripts/finalize-build.mjs +63 -3
- package/corpus/core/scripts/materialize-source-corpus.mjs +101 -15
- package/corpus/core/src/action-change-marker.ts +8 -1
- package/corpus/core/src/action.ts +42 -0
- package/corpus/core/src/agent/engine/builder-engine.ts +3 -0
- package/corpus/core/src/agent/engine/context-directives-transform.ts +69 -0
- package/corpus/core/src/agent/engine/continuation-dispatch-retry.ts +168 -0
- package/corpus/core/src/agent/engine/tool-call-journal-seed.ts +85 -0
- package/corpus/core/src/agent/production-agent.ts +129 -244
- package/corpus/core/src/changelog/parse.ts +8 -3
- package/corpus/core/src/cli/doctor.ts +9 -3
- package/corpus/core/src/cli/plan-local.ts +10 -2
- package/corpus/core/src/cli/skills-content/assets-skill.ts +83 -0
- package/corpus/core/src/cli/skills-content/canvas.ts +153 -0
- package/corpus/core/src/cli/skills-content/connection.ts +52 -0
- package/corpus/core/src/cli/skills-content/content-skill.ts +109 -0
- package/corpus/core/src/cli/skills-content/design-exploration-skill.ts +118 -0
- package/corpus/core/src/cli/skills-content/design-visual-edit-skill.ts +228 -0
- package/corpus/core/src/cli/skills-content/document-quality.ts +196 -0
- package/corpus/core/src/cli/skills-content/exemplar.ts +69 -0
- package/corpus/core/src/cli/skills-content/help.ts +77 -0
- package/corpus/core/src/cli/skills-content/index.ts +22 -0
- package/corpus/core/src/cli/skills-content/local-files.ts +95 -0
- package/corpus/core/src/cli/skills-content/plan-setup-auth.ts +80 -0
- package/corpus/core/src/cli/skills-content/visual-plan-skill.ts +470 -0
- package/corpus/core/src/cli/skills-content/visual-recap-skill.ts +547 -0
- package/corpus/core/src/cli/skills-content/visualize-repo-skill.ts +93 -0
- package/corpus/core/src/cli/skills-content/wireframe.ts +349 -0
- package/corpus/core/src/cli/skills.ts +27 -2733
- package/corpus/core/src/client/AgentPanel.tsx +8 -8
- package/corpus/core/src/client/AssistantChat.tsx +83 -39
- package/corpus/core/src/client/CommandMenu.tsx +16 -5
- package/corpus/core/src/client/FeedbackButton.tsx +2 -2
- package/corpus/core/src/client/analytics.ts +29 -0
- package/corpus/core/src/client/app-providers.tsx +18 -5
- package/corpus/core/src/client/blocks/library/wireframe-kit.tsx +16 -2
- package/corpus/core/src/client/chat/tool-call-display.tsx +3 -3
- package/corpus/core/src/client/chat-model-groups.ts +28 -0
- package/corpus/core/src/client/composer/PastedTextChip.tsx +1 -1
- package/corpus/core/src/client/composer/RealtimeVoiceMode.tsx +523 -68
- package/corpus/core/src/client/composer/TiptapComposer.tsx +47 -30
- package/corpus/core/src/client/composer/VoiceButton.tsx +22 -5
- package/corpus/core/src/client/composer/index.ts +5 -0
- package/corpus/core/src/client/composer/useRealtimeVoiceMode.tsx +1271 -35
- package/corpus/core/src/client/context-xray/ContextXRayPanel.tsx +5 -2
- package/corpus/core/src/client/extensions/ExtensionEditor.tsx +37 -4
- package/corpus/core/src/client/extensions/ExtensionQueryErrorState.tsx +47 -0
- package/corpus/core/src/client/extensions/ExtensionSlot.tsx +39 -10
- package/corpus/core/src/client/extensions/ExtensionViewer.tsx +44 -6
- package/corpus/core/src/client/extensions/ExtensionsListPage.tsx +12 -3
- package/corpus/core/src/client/extensions/ExtensionsSidebarSection.tsx +49 -11
- package/corpus/core/src/client/index.ts +5 -13
- package/corpus/core/src/client/progress/RunsTray.tsx +23 -4
- package/corpus/core/src/client/settings/SecretsSection.tsx +387 -266
- package/corpus/core/src/client/settings/SettingsPanel.tsx +117 -38
- package/corpus/core/src/client/settings/SettingsTabsPage.tsx +7 -0
- package/corpus/core/src/client/settings/useBuilderStatus.ts +6 -0
- package/corpus/core/src/client/tool-cells/EditCell.tsx +19 -16
- package/corpus/core/src/client/tool-cells/FilesChangedSummary.tsx +26 -23
- package/corpus/core/src/client/tool-cells/WriteCell.tsx +19 -16
- package/corpus/core/src/client/use-action.ts +12 -0
- package/corpus/core/src/client/use-agent-chat-home-handoff.ts +8 -1
- package/corpus/core/src/client/use-agent-engine-configured.ts +17 -3
- package/corpus/core/src/client/use-db-sync.ts +84 -34
- package/corpus/core/src/client/use-pausing-interval.ts +14 -4
- package/corpus/core/src/client/visual-style-controls.tsx +1 -1
- package/corpus/core/src/deploy/build.ts +36 -14
- package/corpus/core/src/integrations/google-docs-poller.ts +23 -2
- package/corpus/core/src/integrations/plugin.ts +10 -0
- package/corpus/core/src/integrations/scope-store.ts +1 -1
- package/corpus/core/src/integrations/usage-budget-store.ts +1 -1
- package/corpus/core/src/integrations/webhook-handler.ts +27 -2
- package/corpus/core/src/jobs/scheduler.ts +28 -2
- package/corpus/core/src/localization/default-messages.ts +51 -1
- package/corpus/core/src/mcp/oauth-token.ts +6 -1
- package/corpus/core/src/mcp-client/workspace-servers.ts +4 -4
- package/corpus/core/src/observability/routes.ts +36 -0
- package/corpus/core/src/observability/sentiment.ts +261 -0
- package/corpus/core/src/observability/store.ts +23 -0
- package/corpus/core/src/observability/traces.ts +49 -63
- package/corpus/core/src/observability/tracking-identity.ts +55 -0
- package/corpus/core/src/observability/types.ts +13 -0
- package/corpus/core/src/secrets/crypto.ts +28 -8
- package/corpus/core/src/secrets/storage.ts +67 -3
- package/corpus/core/src/server/action-change.ts +5 -1
- package/corpus/core/src/server/action-routes.ts +8 -0
- package/corpus/core/src/server/agent-chat/action-filters-a2a.ts +199 -0
- package/corpus/core/src/server/agent-chat/browser-team-tools.ts +510 -0
- package/corpus/core/src/server/agent-chat/context-tools.ts +595 -0
- package/corpus/core/src/server/agent-chat/framework-prompts.ts +470 -0
- package/corpus/core/src/server/agent-chat/lazy-fs.ts +11 -0
- package/corpus/core/src/server/agent-chat/mcp-glue.ts +91 -0
- package/corpus/core/src/server/agent-chat/plugin-options.ts +350 -0
- package/corpus/core/src/server/agent-chat/process-run-failure.ts +62 -0
- package/corpus/core/src/server/agent-chat/prompt-resources.ts +688 -0
- package/corpus/core/src/server/agent-chat/recurring-jobs-runtime.ts +80 -0
- package/corpus/core/src/server/agent-chat/request-surface.ts +71 -0
- package/corpus/core/src/server/agent-chat/run-code-tools.ts +67 -0
- package/corpus/core/src/server/agent-chat/script-entries.ts +779 -0
- package/corpus/core/src/server/agent-chat/shared-thread.ts +301 -0
- package/corpus/core/src/server/agent-chat/skill-frontmatter.ts +41 -0
- package/corpus/core/src/server/agent-chat-plugin.ts +364 -4182
- package/corpus/core/src/server/agent-teams.ts +26 -3
- package/corpus/core/src/server/auth.ts +55 -57
- package/corpus/core/src/server/credential-provider.ts +22 -25
- package/corpus/core/src/server/edge.ts +1 -0
- package/corpus/core/src/server/onboarding-html.ts +1 -16
- package/corpus/core/src/server/poll.ts +1 -0
- package/corpus/core/src/server/realtime-voice.ts +335 -14
- package/corpus/core/src/server/request-origin.ts +6 -2
- package/corpus/core/src/server/ssr-handler.ts +55 -2
- package/corpus/core/src/sharing/access.ts +155 -11
- package/corpus/core/src/sharing/registry.ts +7 -0
- package/corpus/core/src/styles/agent-native.css +17 -16
- package/corpus/core/src/templates/default/.agents/skills/frontend-design/SKILL.md +1 -1
- package/corpus/core/src/templates/default/.agents/skills/real-time-sync/SKILL.md +2 -2
- package/corpus/core/src/templates/default/app/i18n/ar-SA.ts +6 -0
- package/corpus/core/src/templates/default/app/i18n/de-DE.ts +6 -0
- package/corpus/core/src/templates/default/app/i18n/en-US.ts +6 -0
- package/corpus/core/src/templates/default/app/i18n/es-ES.ts +6 -0
- package/corpus/core/src/templates/default/app/i18n/fr-FR.ts +6 -0
- package/corpus/core/src/templates/default/app/i18n/hi-IN.ts +6 -0
- package/corpus/core/src/templates/default/app/i18n/ja-JP.ts +6 -0
- package/corpus/core/src/templates/default/app/i18n/ko-KR.ts +6 -0
- package/corpus/core/src/templates/default/app/i18n/pt-BR.ts +6 -0
- package/corpus/core/src/templates/default/app/i18n/zh-CN.ts +6 -0
- package/corpus/core/src/templates/default/app/i18n/zh-TW.ts +6 -0
- package/corpus/core/src/templates/workspace-core/.agents/skills/authentication/SKILL.md +27 -29
- package/corpus/core/src/templates/workspace-core/.agents/skills/external-agents/SKILL.md +2 -1
- package/corpus/core/src/templates/workspace-core/.agents/skills/frontend-design/SKILL.md +1 -1
- package/corpus/core/src/templates/workspace-core/.agents/skills/observability/SKILL.md +32 -0
- package/corpus/core/src/templates/workspace-core/.agents/skills/real-time-sync/SKILL.md +2 -2
- package/corpus/core/src/templates/workspace-core/.agents/skills/secrets/SKILL.md +7 -3
- package/corpus/core/src/templates/workspace-core/.agents/skills/voice-transcription/SKILL.md +39 -9
- package/corpus/core/src/templates/workspace-core/.agents/skills/writing-agent-instructions/SKILL.md +25 -0
- package/corpus/core/src/templates/workspace-core/src/server/index.ts +4 -2
- package/corpus/core/src/testing.ts +26 -0
- package/corpus/core/src/triggers/dispatcher.ts +23 -2
- package/corpus/core/src/vite/client.ts +135 -3
- package/corpus/core/tsconfig.cli.json +1 -1
- package/corpus/core/tsconfig.json +5 -1
- package/corpus/templates/analytics/.agents/skills/bigquery/SKILL.md +2 -2
- package/corpus/templates/analytics/.agents/skills/frontend-design/SKILL.md +1 -1
- package/corpus/templates/analytics/.agents/skills/real-time-sync/SKILL.md +2 -2
- package/corpus/templates/analytics/.agents/skills/session-replay/SKILL.md +10 -5
- package/corpus/templates/analytics/AGENTS.md +15 -6
- package/corpus/templates/analytics/actions/install-dashboard-template.ts +79 -43
- package/corpus/templates/analytics/actions/list-explorer-dashboards.ts +3 -3
- package/corpus/templates/analytics/actions/list-sql-dashboards.ts +8 -3
- package/corpus/templates/analytics/actions/navigate.ts +59 -5
- package/corpus/templates/analytics/actions/rename-analysis.ts +8 -2
- package/corpus/templates/analytics/actions/rename-dashboard.ts +8 -7
- package/corpus/templates/analytics/actions/view-screen.ts +7 -29
- package/corpus/templates/analytics/app/components/ProviderCorpusJobNotifier.tsx +20 -3
- package/corpus/templates/analytics/app/components/ResourceLoadError.tsx +42 -0
- package/corpus/templates/analytics/app/components/dashboard/SqlChart.tsx +2 -1
- package/corpus/templates/analytics/app/components/layout/CommandPalette.tsx +85 -70
- package/corpus/templates/analytics/app/components/layout/Header.tsx +1 -1
- package/corpus/templates/analytics/app/components/layout/Sidebar.tsx +128 -95
- package/corpus/templates/analytics/app/components/layout/SidebarLoadError.tsx +24 -0
- package/corpus/templates/analytics/app/global.css +19 -20
- package/corpus/templates/analytics/app/hooks/use-dashboard-views.ts +15 -5
- package/corpus/templates/analytics/app/i18n/zh-TW.ts +4 -0
- package/corpus/templates/analytics/app/i18n-data.ts +40 -0
- package/corpus/templates/analytics/app/lib/provider-corpus-job-sync.ts +26 -0
- package/corpus/templates/analytics/app/pages/Settings.tsx +41 -343
- package/corpus/templates/analytics/app/pages/adhoc/explorer/components/SqlPreview.tsx +36 -20
- package/corpus/templates/analytics/app/pages/adhoc/explorer/index.tsx +34 -20
- package/corpus/templates/analytics/app/pages/adhoc/explorer/use-explorer-config.ts +42 -41
- package/corpus/templates/analytics/app/pages/adhoc/explorer-dashboard/index.tsx +43 -36
- package/corpus/templates/analytics/app/pages/adhoc/sql-dashboard/ViewsMenu.tsx +11 -2
- package/corpus/templates/analytics/app/pages/monitoring/ErrorsPanel.tsx +38 -7
- package/corpus/templates/analytics/app/pages/monitoring/MonitoringPage.tsx +1 -1
- package/corpus/templates/analytics/app/pages/monitoring/errors/i18n.ts +3 -0
- package/corpus/templates/analytics/app/pages/sessions/SessionDetailPage.tsx +333 -272
- package/corpus/templates/analytics/app/pages/sessions/SessionDevToolsPanel.tsx +72 -17
- package/corpus/templates/analytics/app/pages/sessions/SessionsPage.tsx +297 -108
- package/corpus/templates/analytics/app/root.tsx +40 -8
- package/corpus/templates/analytics/app/routes/_index.tsx +14 -2
- package/corpus/templates/analytics/changelog/2026-06-24-first-party-signup-and-pageview-panels-now-honor-dashboard-filters.md +2 -1
- package/corpus/templates/analytics/changelog/2026-06-25-referrer-dashboard-panels-show-external-domains.md +2 -1
- package/corpus/templates/analytics/changelog/2026-07-03-agent-llm-observability-dashboard.md +1 -1
- package/corpus/templates/analytics/changelog/2026-07-06-mobile-chat-header-is-more-compact-and-the-menu-button-opens-navigation.md +1 -0
- package/corpus/templates/analytics/changelog/2026-07-08-dashboard-history-and-chat-context.md +1 -0
- package/corpus/templates/analytics/changelog/2026-07-08-settings-are-cleaner-searchable-and-alerts-have-their-own-tab.md +1 -0
- package/corpus/templates/analytics/changelog/2026-07-08-sidebar-sections-stay-collapsed-until-opened.md +1 -0
- package/corpus/templates/analytics/changelog/2026-07-11-agent-feedback-sentiment-dashboard.md +6 -0
- package/corpus/templates/analytics/changelog/2026-07-11-analytics-chats-now-start-faster-by-loading-metric-definitio.md +6 -0
- package/corpus/templates/analytics/changelog/2026-07-11-analytics-no-longer-repeatedly-restarts-background-requests-.md +6 -0
- package/corpus/templates/analytics/changelog/2026-07-11-analytics-only-asks-for-replay-storage-when-you-enable-sessi.md +6 -0
- package/corpus/templates/analytics/changelog/2026-07-11-charts-now-show-their-loading-skeleton-while-refreshing.md +6 -0
- package/corpus/templates/analytics/changelog/2026-07-11-command-and-sql-previews-now-respond-without-lag.md +6 -0
- package/corpus/templates/analytics/changelog/2026-07-11-command-search-now-reports-loading-failures-and-lets-you-ret.md +6 -0
- package/corpus/templates/analytics/changelog/2026-07-11-dashboard-navigation-now-loads-faster-and-reports-request-fa.md +6 -0
- package/corpus/templates/analytics/changelog/2026-07-11-inferred-message-sentiment-dashboard.md +6 -0
- package/corpus/templates/analytics/changelog/2026-07-11-microphone-settings-from-realtime-voice-mode-now-open-the-vo.md +6 -0
- package/corpus/templates/analytics/changelog/2026-07-11-more-dashboard-edit-paths-are-now-safe-against-simultaneous-.md +6 -0
- package/corpus/templates/analytics/changelog/2026-07-11-realtime-voice-now-shows-a-clear-connection-indicator-comple.md +6 -0
- package/corpus/templates/analytics/changelog/2026-07-11-renaming-a-dashboard-is-now-safe-against-simultaneous-agent-.md +6 -0
- package/corpus/templates/analytics/changelog/2026-07-11-renaming-an-analysis-is-now-safe-against-simultaneous-edits.md +6 -0
- package/corpus/templates/analytics/changelog/2026-07-11-replay-event-counts-stay-hidden-until-recordings-finish-load.md +6 -0
- package/corpus/templates/analytics/changelog/2026-07-11-replay-storage-key-mismatches-show-actionable-setup-guidance.md +6 -0
- package/corpus/templates/analytics/changelog/2026-07-11-replay-timelines-group-continuous-scrolling-and-dev-tools-co.md +6 -0
- package/corpus/templates/analytics/changelog/2026-07-11-session-filters-now-stay-compact-in-a-settings-menu-at-mediu.md +6 -0
- package/corpus/templates/analytics/changelog/2026-07-11-session-replay-console-errors-now-link-to-matching-issues-or.md +6 -0
- package/corpus/templates/analytics/changelog/2026-07-11-session-replays-load-large-recordings-faster-and-surface-fai.md +6 -0
- package/corpus/templates/analytics/changelog/2026-07-11-session-replays-preserve-recorded-styles-and-viewport-layout.md +6 -0
- package/corpus/templates/analytics/changelog/2026-07-11-session-replays-stay-centered-instead-of-clipping-wide-recor.md +6 -0
- package/corpus/templates/analytics/changelog/2026-07-11-workspace-mounted-analytics-now-opens-ask-reliably-and-route.md +6 -0
- package/corpus/templates/analytics/docs/schemas/first-party-analytics.md +37 -3
- package/corpus/templates/analytics/package.json +1 -1
- package/corpus/templates/analytics/seeds/dashboards/agent-native-templates-first-party.json +37 -1
- package/corpus/templates/analytics/server/handlers/session-replay.ts +57 -0
- package/corpus/templates/analytics/server/lib/dashboard-catalog.ts +1 -24
- package/corpus/templates/analytics/server/lib/dashboard-seeds.ts +0 -5
- package/corpus/templates/analytics/server/lib/dashboards-store.ts +289 -20
- package/corpus/templates/analytics/server/lib/data-dictionary-context.ts +106 -34
- package/corpus/templates/analytics/server/lib/demo-dashboards.ts +20 -4
- package/corpus/templates/analytics/server/lib/session-replay-agent-context.ts +12 -0
- package/corpus/templates/analytics/server/lib/session-replay.ts +208 -2
- package/corpus/templates/analytics/server/plugins/agent-chat.ts +11 -39
- package/corpus/templates/analytics/server/plugins/onboarding.ts +7 -79
- package/corpus/templates/analytics/server/routes/api/session-replay/recordings/[recordingId]/chunks.get.ts +1 -0
- package/corpus/templates/assets/.agents/skills/frontend-design/SKILL.md +1 -1
- package/corpus/templates/assets/.agents/skills/real-time-sync/SKILL.md +2 -2
- package/corpus/templates/assets/app/components/create/RecentDraftsSection.tsx +30 -4
- package/corpus/templates/assets/app/global.css +4 -4
- package/corpus/templates/assets/app/routes/brand-kits.$id.tsx +0 -1
- package/corpus/templates/assets/app/routes/library.tsx +49 -6
- package/corpus/templates/assets/changelog/2026-07-11-library-load-failures-now-show-a-retry-action.md +6 -0
- package/corpus/templates/brain/.agents/skills/frontend-design/SKILL.md +1 -1
- package/corpus/templates/brain/.agents/skills/real-time-sync/SKILL.md +2 -2
- package/corpus/templates/brain/app/global.css +5 -5
- package/corpus/templates/brain/app/root.tsx +0 -3
- package/corpus/templates/calendar/.agents/skills/frontend-design/SKILL.md +1 -1
- package/corpus/templates/calendar/.agents/skills/real-time-sync/SKILL.md +2 -2
- package/corpus/templates/calendar/.env.example +5 -0
- package/corpus/templates/calendar/app/components/calendar/EventCard.tsx +2 -2
- package/corpus/templates/calendar/app/i18n/zh-TW.ts +2 -0
- package/corpus/templates/calendar/app/i18n-data.ts +20 -0
- package/corpus/templates/calendar/app/pages/BookingLinksPage.tsx +37 -1
- package/corpus/templates/calendar/app/pages/BookingsList.tsx +20 -3
- package/corpus/templates/calendar/app/root.tsx +1 -0
- package/corpus/templates/calendar/changelog/2026-07-11-booking-load-failures-now-show-a-retry-action.md +6 -0
- package/corpus/templates/calendar/changelog/2026-07-11-event-cards-give-subtle-press-feedback-and-smoother-hover.md +6 -0
- package/corpus/templates/chat/.agents/skills/frontend-design/SKILL.md +1 -1
- package/corpus/templates/chat/.agents/skills/real-time-sync/SKILL.md +2 -2
- package/corpus/templates/clips/.agents/skills/frontend-design/SKILL.md +1 -1
- package/corpus/templates/clips/actions/decline-invite.ts +8 -0
- package/corpus/templates/clips/app/components/library/folder-tree.tsx +209 -187
- package/corpus/templates/clips/app/components/meetings/meeting-card.tsx +2 -2
- package/corpus/templates/clips/app/components/player/reactions-tray.tsx +17 -5
- package/corpus/templates/clips/app/components/player/scrubber.tsx +5 -3
- package/corpus/templates/clips/app/components/recorder/pre-record-panel.tsx +2 -2
- package/corpus/templates/clips/app/components/workspace/insights-hub.tsx +119 -95
- package/corpus/templates/clips/app/global.css +45 -0
- package/corpus/templates/clips/app/hooks/use-auto-title.ts +74 -8
- package/corpus/templates/clips/app/hooks/use-library.ts +12 -25
- package/corpus/templates/clips/app/root.tsx +4 -0
- package/corpus/templates/clips/app/routes/_app.notifications.tsx +23 -2
- package/corpus/templates/clips/app/routes/_app.settings._index.tsx +20 -22
- package/corpus/templates/clips/app/routes/_app.trash.tsx +24 -2
- package/corpus/templates/clips/changelog/2026-07-11-controls-and-folders-now-move-more-smoothly.md +6 -0
- package/corpus/templates/clips/changelog/2026-07-11-declining-an-invitation-now-requires-being-its-recipient.md +6 -0
- package/corpus/templates/clips/changelog/2026-07-11-generated-titles-no-longer-cause-continuous-background-refreshes.md +6 -0
- package/corpus/templates/clips/changelog/2026-07-11-recording-overlays-are-lighter-weight-and-no-longer-cause-pa.md +6 -0
- package/corpus/templates/clips/changelog/2026-07-11-s3-storage-setup-stays-collapsed-until-you-choose-it-as-the-.md +6 -0
- package/corpus/templates/clips/changelog/2026-07-11-workspace-load-failures-now-show-a-retry-action.md +6 -0
- package/corpus/templates/clips/chrome-extension/src/overlay.css +34 -5
- package/corpus/templates/clips/chrome-extension/src/styles.css +2 -2
- package/corpus/templates/clips/desktop/src/styles.css +71 -26
- package/corpus/templates/content/.agents/skills/frontend-design/SKILL.md +1 -1
- package/corpus/templates/content/.agents/skills/real-time-sync/SKILL.md +2 -2
- package/corpus/templates/content/actions/move-document.ts +34 -18
- package/corpus/templates/content/app/components/QueryErrorState.tsx +39 -0
- package/corpus/templates/content/app/components/editor/LinkHoverPreview.tsx +1 -1
- package/corpus/templates/content/app/components/editor/database/DatabaseView.tsx +225 -1435
- package/corpus/templates/content/app/components/editor/database/GalleryView.tsx +368 -0
- package/corpus/templates/content/app/components/editor/database/ListView.tsx +353 -0
- package/corpus/templates/content/app/components/editor/database/TimelineView.tsx +580 -0
- package/corpus/templates/content/app/components/sidebar/DocumentSidebar.tsx +11 -2
- package/corpus/templates/content/app/global.css +19 -19
- package/corpus/templates/content/app/hooks/use-comments.ts +0 -1
- package/corpus/templates/content/app/root.tsx +2 -2
- package/corpus/templates/content/app/routes/_app._index.tsx +11 -1
- package/corpus/templates/content/changelog/2026-07-11-comments-now-update-from-live-collaboration-events-without-c.md +6 -0
- package/corpus/templates/content/changelog/2026-07-11-document-load-failures-now-show-a-retry-action.md +6 -0
- package/corpus/templates/content/changelog/2026-07-11-editor-toggle-feedback-now-feels-more-responsive.md +6 -0
- package/corpus/templates/content/changelog/2026-07-11-moving-documents-at-the-same-time-no-longer-scrambles-their-.md +6 -0
- package/corpus/templates/content/changelog/2026-07-11-public-document-chats-now-start-faster-while-keeping-full-do.md +6 -0
- package/corpus/templates/content/changelog/2026-07-11-reopening-a-comment-now-uses-consistent-permissions-everywhe.md +6 -0
- package/corpus/templates/content/changelog/2026-07-11-sidebar-resizing-now-tracks-your-cursor-instantly-instead-of.md +6 -0
- package/corpus/templates/content/server/lib/public-documents.ts +47 -10
- package/corpus/templates/content/server/routes/api/comments/[id].patch.ts +24 -24
- package/corpus/templates/design/.agents/skills/frontend-design/SKILL.md +1 -1
- package/corpus/templates/design/app/components/QueryErrorState.tsx +24 -0
- package/corpus/templates/design/app/components/design/CanvasContextMenu.tsx +1 -1
- package/corpus/templates/design/app/components/design/DesignImportPanel.tsx +5 -2
- package/corpus/templates/design/app/components/design/EditPanel.tsx +326 -319
- package/corpus/templates/design/app/components/design/LayersPanel.tsx +198 -193
- package/corpus/templates/design/app/components/design/edit-panel/panel-primitives.tsx +11 -4
- package/corpus/templates/design/app/components/design/inspector/DesignColorPicker.tsx +1 -1
- package/corpus/templates/design/app/components/layout/Header.tsx +1 -1
- package/corpus/templates/design/app/components/layout/Layout.tsx +1 -1
- package/corpus/templates/design/app/pages/DesignSystems.tsx +7 -1
- package/corpus/templates/design/app/pages/Index.tsx +14 -2
- package/corpus/templates/design/app/pages/Present.tsx +16 -3
- package/corpus/templates/design/app/pages/Templates.tsx +10 -4
- package/corpus/templates/design/app/pages/design-editor/canvas-primitive-insert.ts +484 -0
- package/corpus/templates/design/app/pages/design-editor/clone-and-pen-edit.ts +378 -0
- package/corpus/templates/design/app/pages/design-editor/design-data-geometry-utils.ts +138 -0
- package/corpus/templates/design/app/pages/design-editor/dom-utils.ts +15 -0
- package/corpus/templates/design/app/pages/design-editor/generation-prompt-directives.ts +180 -0
- package/corpus/templates/design/app/pages/design-editor/html-layer-positioning.ts +226 -0
- package/corpus/templates/design/app/pages/design-editor/png-export-render.ts +348 -0
- package/corpus/templates/design/app/pages/design-editor/screen-command-utils.ts +160 -0
- package/corpus/templates/design/app/pages/design-editor/text-edit-utils.ts +238 -0
- package/corpus/templates/design/app/pages/design-editor/tool-state.ts +23 -1
- package/corpus/templates/design/app/pages/design-editor/types.ts +25 -0
- package/corpus/templates/design/app/root.tsx +10 -1
- package/corpus/templates/design/changelog/2026-07-11-canvas-context-menus-now-open-without-motion-jitter.md +6 -0
- package/corpus/templates/design/changelog/2026-07-11-design-load-failures-now-show-a-retry-action.md +6 -0
- package/corpus/templates/design/changelog/2026-07-11-inspector-tooltips-appear-instantly-as-you-sweep-across-icon.md +6 -0
- package/corpus/templates/dispatch/.agents/skills/frontend-design/SKILL.md +1 -1
- package/corpus/templates/dispatch/app/i18n/zh-TW.ts +10 -0
- package/corpus/templates/dispatch/app/i18n-data.ts +123 -0
- package/corpus/templates/dispatch/app/routes/integrations.tsx +163 -144
- package/corpus/templates/dispatch/changelog/2026-07-11-dispatch-mcp-connections-now-start-with-safer-app-access-and.md +6 -0
- package/corpus/templates/dispatch/changelog/2026-07-11-overview-and-chat-now-share-a-cleaner-more-stable-flow.md +6 -0
- package/corpus/templates/dispatch/changelog/2026-07-11-query-errors-now-show-a-retry-option.md +6 -0
- package/corpus/templates/forms/.agents/skills/frontend-design/SKILL.md +1 -1
- package/corpus/templates/forms/.agents/skills/real-time-sync/SKILL.md +2 -2
- package/corpus/templates/forms/app/components/layout/Sidebar.tsx +3 -3
- package/corpus/templates/forms/app/root.tsx +34 -8
- package/corpus/templates/macros/.agents/skills/frontend-design/SKILL.md +1 -1
- package/corpus/templates/macros/app/components/DailyProgress.tsx +25 -5
- package/corpus/templates/macros/app/components/QueryErrorState.tsx +31 -0
- package/corpus/templates/macros/app/components/WeightTracker.tsx +5 -1
- package/corpus/templates/macros/app/components/layout/AppLayout.tsx +1 -2
- package/corpus/templates/macros/app/components/ui/button.tsx +1 -1
- package/corpus/templates/macros/app/components/ui/progress.tsx +1 -1
- package/corpus/templates/macros/app/components/ui/tabs.tsx +1 -1
- package/corpus/templates/macros/app/i18n/ar-SA.ts +2 -0
- package/corpus/templates/macros/app/i18n/de-DE.ts +2 -0
- package/corpus/templates/macros/app/i18n/en-US.ts +2 -0
- package/corpus/templates/macros/app/i18n/es-ES.ts +2 -0
- package/corpus/templates/macros/app/i18n/fr-FR.ts +2 -0
- package/corpus/templates/macros/app/i18n/hi-IN.ts +2 -0
- package/corpus/templates/macros/app/i18n/ja-JP.ts +2 -0
- package/corpus/templates/macros/app/i18n/ko-KR.ts +2 -0
- package/corpus/templates/macros/app/i18n/pt-BR.ts +2 -0
- package/corpus/templates/macros/app/i18n/zh-CN.ts +2 -0
- package/corpus/templates/macros/app/i18n/zh-TW.ts +2 -0
- package/corpus/templates/macros/app/root.tsx +0 -3
- package/corpus/templates/macros/app/routes/_index.tsx +22 -12
- package/corpus/templates/macros/app/routes/analytics.tsx +31 -10
- package/corpus/templates/macros/changelog/2026-07-11-daily-tracking-now-loads-and-updates-more-quickly.md +6 -0
- package/corpus/templates/macros/changelog/2026-07-11-data-load-failures-now-show-a-clear-error-with-a-retry-actio.md +6 -0
- package/corpus/templates/mail/.agents/skills/frontend-design/SKILL.md +1 -1
- package/corpus/templates/mail/.agents/skills/real-time-sync/SKILL.md +2 -2
- package/corpus/templates/mail/.env.example +16 -11
- package/corpus/templates/mail/actions/list-emails.ts +39 -35
- package/corpus/templates/mail/app/components/email/ComposeModal.tsx +58 -6
- package/corpus/templates/mail/app/components/email/EmailListItem.tsx +35 -2
- package/corpus/templates/mail/app/components/layout/AppLayout.tsx +113 -104
- package/corpus/templates/mail/app/hooks/use-compose-state.ts +1 -0
- package/corpus/templates/mail/app/root.tsx +9 -22
- package/corpus/templates/mail/changelog/2026-07-11-compose-and-navigation-motion-now-feel-faster-and-smoother.md +6 -0
- package/corpus/templates/mail/changelog/2026-07-11-swipe-to-archive-or-snooze-now-responds-to-quick-flicks-not-.md +6 -0
- package/corpus/templates/mail/changelog/2026-07-11-the-assistant-now-sees-the-same-inbox-you-do-snoozed-mail-st.md +6 -0
- package/corpus/templates/mail/server/handlers/emails.ts +25 -69
- package/corpus/templates/mail/server/lib/list-inbox-emails.ts +169 -0
- package/corpus/templates/plan/.agents/skills/frontend-design/SKILL.md +1 -1
- package/corpus/templates/plan/.agents/skills/real-time-sync/SKILL.md +2 -2
- package/corpus/templates/plan/.env.example +4 -0
- package/corpus/templates/plan/actions/create-plan-design.ts +89 -81
- package/corpus/templates/plan/actions/create-prototype-plan.ts +72 -59
- package/corpus/templates/plan/actions/create-ui-plan.ts +70 -55
- package/corpus/templates/plan/actions/create-visual-plan.ts +65 -51
- package/corpus/templates/plan/actions/update-local-plan-folder.ts +43 -30
- package/corpus/templates/plan/actions/update-visual-plan.ts +81 -64
- package/corpus/templates/plan/app/components/layout/Sidebar.tsx +17 -0
- package/corpus/templates/plan/app/components/ui/tabs.tsx +1 -1
- package/corpus/templates/plan/app/hooks/use-navigation-state.ts +5 -2
- package/corpus/templates/plan/app/hooks/use-plans.ts +6 -13
- package/corpus/templates/plan/app/i18n/ar-SA.ts +10 -0
- package/corpus/templates/plan/app/i18n/de-DE.ts +10 -0
- package/corpus/templates/plan/app/i18n/en-US.ts +10 -0
- package/corpus/templates/plan/app/i18n/es-ES.ts +10 -0
- package/corpus/templates/plan/app/i18n/fr-FR.ts +10 -0
- package/corpus/templates/plan/app/i18n/hi-IN.ts +10 -0
- package/corpus/templates/plan/app/i18n/ja-JP.ts +10 -0
- package/corpus/templates/plan/app/i18n/ko-KR.ts +10 -0
- package/corpus/templates/plan/app/i18n/pt-BR.ts +10 -0
- package/corpus/templates/plan/app/i18n/zh-CN.ts +10 -0
- package/corpus/templates/plan/app/i18n/zh-TW.ts +10 -0
- package/corpus/templates/plan/app/lib/plan-local-bridge.ts +80 -1
- package/corpus/templates/plan/app/pages/PlansPage.tsx +157 -31
- package/corpus/templates/plan/app/root.tsx +11 -0
- package/corpus/templates/plan/changelog/2026-07-11-local-plans-now-explain-and-recover-from-browser-permission-.md +6 -0
- package/corpus/templates/plan/changelog/2026-07-11-plan-edits-now-save-atomically-and-can-no-longer-partially-a.md +6 -0
- package/corpus/templates/plan/changelog/2026-07-11-plan-lists-now-show-a-clear-error-with-a-retry-action-when-t.md +6 -0
- package/corpus/templates/plan/changelog/2026-07-11-plan-refreshes-only-when-content-changes.md +6 -0
- package/corpus/templates/plan/shared/plan-content.ts +546 -260
- package/corpus/templates/slides/.agents/skills/frontend-design/SKILL.md +1 -1
- package/corpus/templates/slides/actions/delete-slide-comment.ts +49 -0
- package/corpus/templates/slides/actions/update-slide-comment.ts +93 -0
- package/corpus/templates/slides/actions/view-screen.ts +14 -6
- package/corpus/templates/slides/app/components/comments/SlideCommentsPanel.tsx +37 -11
- package/corpus/templates/slides/app/components/editor/EditorSidebar.tsx +1 -1
- package/corpus/templates/slides/app/components/editor/EditorToolbar.tsx +2 -2
- package/corpus/templates/slides/app/components/editor/GenerateSlidesDialog.tsx +2 -2
- package/corpus/templates/slides/app/components/layout/Header.tsx +1 -1
- package/corpus/templates/slides/app/components/presentation/PresentationView.tsx +4 -2
- package/corpus/templates/slides/app/components/visual-editor/CanvasCommentPins.tsx +4 -3
- package/corpus/templates/slides/app/context/DeckContext.tsx +10 -0
- package/corpus/templates/slides/app/hooks/use-slide-comments.ts +7 -31
- package/corpus/templates/slides/app/i18n/ar-SA.ts +6 -0
- package/corpus/templates/slides/app/i18n/de-DE.ts +6 -0
- package/corpus/templates/slides/app/i18n/en-US.ts +6 -0
- package/corpus/templates/slides/app/i18n/es-ES.ts +6 -0
- package/corpus/templates/slides/app/i18n/fr-FR.ts +6 -0
- package/corpus/templates/slides/app/i18n/hi-IN.ts +6 -0
- package/corpus/templates/slides/app/i18n/ja-JP.ts +6 -0
- package/corpus/templates/slides/app/i18n/ko-KR.ts +6 -0
- package/corpus/templates/slides/app/i18n/pt-BR.ts +6 -0
- package/corpus/templates/slides/app/i18n/zh-CN.ts +5 -0
- package/corpus/templates/slides/app/i18n/zh-TW.ts +5 -0
- package/corpus/templates/slides/app/pages/DesignSystems.tsx +23 -2
- package/corpus/templates/slides/app/pages/Index.tsx +29 -1
- package/corpus/templates/slides/changelog/2026-07-11-comment-load-failures-now-show-a-retry-action-instead-of-say.md +6 -0
- package/corpus/templates/slides/changelog/2026-07-11-comment-pins-now-clear-with-a-faster-smoother-confirmation.md +6 -0
- package/corpus/templates/slides/changelog/2026-07-11-comments-now-update-from-live-collaboration-events-without-c.md +6 -0
- package/corpus/templates/slides/changelog/2026-07-11-deck-and-design-system-load-failures-now-show-a-retry-action.md +6 -0
- package/corpus/templates/slides/changelog/2026-07-11-editor-toggles-and-toolbar-menus-now-animate-smoothly.md +6 -0
- package/corpus/templates/slides/changelog/2026-07-11-the-assistant-can-now-resolve-reopen-and-delete-slide-commen.md +6 -0
- package/corpus/templates/slides/changelog/2026-07-11-viewing-slides-no-longer-loads-every-deck-s-full-contents-in.md +6 -0
- package/corpus/templates/slides/server/routes/api/comments/[id].delete.ts +29 -48
- package/corpus/templates/slides/server/routes/api/comments/[id].patch.ts +29 -65
- package/dist/action-change-marker.d.ts +1 -0
- package/dist/action-change-marker.d.ts.map +1 -1
- package/dist/action-change-marker.js +7 -1
- package/dist/action-change-marker.js.map +1 -1
- package/dist/action.d.ts +23 -0
- package/dist/action.d.ts.map +1 -1
- package/dist/action.js +13 -0
- package/dist/action.js.map +1 -1
- package/dist/agent/engine/builder-engine.d.ts.map +1 -1
- package/dist/agent/engine/builder-engine.js +3 -0
- package/dist/agent/engine/builder-engine.js.map +1 -1
- package/dist/agent/engine/context-directives-transform.d.ts +25 -0
- package/dist/agent/engine/context-directives-transform.d.ts.map +1 -0
- package/dist/agent/engine/context-directives-transform.js +53 -0
- package/dist/agent/engine/context-directives-transform.js.map +1 -0
- package/dist/agent/engine/continuation-dispatch-retry.d.ts +40 -0
- package/dist/agent/engine/continuation-dispatch-retry.d.ts.map +1 -0
- package/dist/agent/engine/continuation-dispatch-retry.js +109 -0
- package/dist/agent/engine/continuation-dispatch-retry.js.map +1 -0
- package/dist/agent/engine/tool-call-journal-seed.d.ts +46 -0
- package/dist/agent/engine/tool-call-journal-seed.d.ts.map +1 -0
- package/dist/agent/engine/tool-call-journal-seed.js +60 -0
- package/dist/agent/engine/tool-call-journal-seed.js.map +1 -0
- package/dist/agent/production-agent.d.ts +7 -0
- package/dist/agent/production-agent.d.ts.map +1 -1
- package/dist/agent/production-agent.js +102 -222
- package/dist/agent/production-agent.js.map +1 -1
- package/dist/changelog/parse.d.ts +4 -2
- package/dist/changelog/parse.d.ts.map +1 -1
- package/dist/changelog/parse.js +5 -3
- package/dist/changelog/parse.js.map +1 -1
- package/dist/cli/doctor.d.ts.map +1 -1
- package/dist/cli/doctor.js +7 -3
- package/dist/cli/doctor.js.map +1 -1
- package/dist/cli/plan-local.d.ts.map +1 -1
- package/dist/cli/plan-local.js +8 -2
- package/dist/cli/plan-local.js.map +1 -1
- package/dist/cli/skills-content/assets-skill.d.ts +2 -0
- package/dist/cli/skills-content/assets-skill.d.ts.map +1 -0
- package/dist/cli/skills-content/assets-skill.js +84 -0
- package/dist/cli/skills-content/assets-skill.js.map +1 -0
- package/dist/cli/skills-content/canvas.d.ts +4 -0
- package/dist/cli/skills-content/canvas.d.ts.map +1 -0
- package/dist/cli/skills-content/canvas.js +152 -0
- package/dist/cli/skills-content/canvas.js.map +1 -0
- package/dist/cli/skills-content/connection.d.ts +2 -0
- package/dist/cli/skills-content/connection.d.ts.map +1 -0
- package/dist/cli/skills-content/connection.js +53 -0
- package/dist/cli/skills-content/connection.js.map +1 -0
- package/dist/cli/skills-content/content-skill.d.ts +2 -0
- package/dist/cli/skills-content/content-skill.d.ts.map +1 -0
- package/dist/cli/skills-content/content-skill.js +110 -0
- package/dist/cli/skills-content/content-skill.js.map +1 -0
- package/dist/cli/skills-content/design-exploration-skill.d.ts +2 -0
- package/dist/cli/skills-content/design-exploration-skill.d.ts.map +1 -0
- package/dist/cli/skills-content/design-exploration-skill.js +119 -0
- package/dist/cli/skills-content/design-exploration-skill.js.map +1 -0
- package/dist/cli/skills-content/design-visual-edit-skill.d.ts +2 -0
- package/dist/cli/skills-content/design-visual-edit-skill.d.ts.map +1 -0
- package/dist/cli/skills-content/design-visual-edit-skill.js +229 -0
- package/dist/cli/skills-content/design-visual-edit-skill.js.map +1 -0
- package/dist/cli/skills-content/document-quality.d.ts +4 -0
- package/dist/cli/skills-content/document-quality.d.ts.map +1 -0
- package/dist/cli/skills-content/document-quality.js +195 -0
- package/dist/cli/skills-content/document-quality.js.map +1 -0
- package/dist/cli/skills-content/exemplar.d.ts +4 -0
- package/dist/cli/skills-content/exemplar.d.ts.map +1 -0
- package/dist/cli/skills-content/exemplar.js +68 -0
- package/dist/cli/skills-content/exemplar.js.map +1 -0
- package/dist/cli/skills-content/help.d.ts +2 -0
- package/dist/cli/skills-content/help.d.ts.map +1 -0
- package/dist/cli/skills-content/help.js +78 -0
- package/dist/cli/skills-content/help.js.map +1 -0
- package/dist/cli/skills-content/index.d.ts +23 -0
- package/dist/cli/skills-content/index.d.ts.map +1 -0
- package/dist/cli/skills-content/index.js +23 -0
- package/dist/cli/skills-content/index.js.map +1 -0
- package/dist/cli/skills-content/local-files.d.ts +2 -0
- package/dist/cli/skills-content/local-files.d.ts.map +1 -0
- package/dist/cli/skills-content/local-files.js +96 -0
- package/dist/cli/skills-content/local-files.js.map +1 -0
- package/dist/cli/skills-content/plan-setup-auth.d.ts +9 -0
- package/dist/cli/skills-content/plan-setup-auth.d.ts.map +1 -0
- package/dist/cli/skills-content/plan-setup-auth.js +81 -0
- package/dist/cli/skills-content/plan-setup-auth.js.map +1 -0
- package/dist/cli/skills-content/visual-plan-skill.d.ts +2 -0
- package/dist/cli/skills-content/visual-plan-skill.d.ts.map +1 -0
- package/dist/cli/skills-content/visual-plan-skill.js +471 -0
- package/dist/cli/skills-content/visual-plan-skill.js.map +1 -0
- package/dist/cli/skills-content/visual-recap-skill.d.ts +2 -0
- package/dist/cli/skills-content/visual-recap-skill.d.ts.map +1 -0
- package/dist/cli/skills-content/visual-recap-skill.js +548 -0
- package/dist/cli/skills-content/visual-recap-skill.js.map +1 -0
- package/dist/cli/skills-content/visualize-repo-skill.d.ts +2 -0
- package/dist/cli/skills-content/visualize-repo-skill.d.ts.map +1 -0
- package/dist/cli/skills-content/visualize-repo-skill.js +94 -0
- package/dist/cli/skills-content/visualize-repo-skill.js.map +1 -0
- package/dist/cli/skills-content/wireframe.d.ts +4 -0
- package/dist/cli/skills-content/wireframe.d.ts.map +1 -0
- package/dist/cli/skills-content/wireframe.js +347 -0
- package/dist/cli/skills-content/wireframe.js.map +1 -0
- package/dist/cli/skills.d.ts +2 -10
- package/dist/cli/skills.d.ts.map +1 -1
- package/dist/cli/skills.js +2 -2710
- package/dist/cli/skills.js.map +1 -1
- package/dist/client/AgentPanel.d.ts.map +1 -1
- package/dist/client/AgentPanel.js +6 -5
- package/dist/client/AgentPanel.js.map +1 -1
- package/dist/client/AssistantChat.d.ts +7 -0
- package/dist/client/AssistantChat.d.ts.map +1 -1
- package/dist/client/AssistantChat.js +62 -40
- package/dist/client/AssistantChat.js.map +1 -1
- package/dist/client/CommandMenu.d.ts.map +1 -1
- package/dist/client/CommandMenu.js +15 -3
- package/dist/client/CommandMenu.js.map +1 -1
- package/dist/client/FeedbackButton.js +2 -2
- package/dist/client/FeedbackButton.js.map +1 -1
- package/dist/client/analytics.d.ts.map +1 -1
- package/dist/client/analytics.js +26 -0
- package/dist/client/analytics.js.map +1 -1
- package/dist/client/app-providers.d.ts +13 -5
- package/dist/client/app-providers.d.ts.map +1 -1
- package/dist/client/app-providers.js +9 -6
- package/dist/client/app-providers.js.map +1 -1
- package/dist/client/blocks/library/wireframe-kit.d.ts +2 -0
- package/dist/client/blocks/library/wireframe-kit.d.ts.map +1 -1
- package/dist/client/blocks/library/wireframe-kit.js +9 -2
- package/dist/client/blocks/library/wireframe-kit.js.map +1 -1
- package/dist/client/chat/tool-call-display.d.ts +4 -0
- package/dist/client/chat/tool-call-display.d.ts.map +1 -1
- package/dist/client/chat/tool-call-display.js +3 -3
- package/dist/client/chat/tool-call-display.js.map +1 -1
- package/dist/client/chat-model-groups.d.ts.map +1 -1
- package/dist/client/chat-model-groups.js +24 -0
- package/dist/client/chat-model-groups.js.map +1 -1
- package/dist/client/composer/PastedTextChip.js +1 -1
- package/dist/client/composer/PastedTextChip.js.map +1 -1
- package/dist/client/composer/RealtimeVoiceMode.d.ts +40 -2
- package/dist/client/composer/RealtimeVoiceMode.d.ts.map +1 -1
- package/dist/client/composer/RealtimeVoiceMode.js +186 -35
- package/dist/client/composer/RealtimeVoiceMode.js.map +1 -1
- package/dist/client/composer/TiptapComposer.d.ts +4 -0
- package/dist/client/composer/TiptapComposer.d.ts.map +1 -1
- package/dist/client/composer/TiptapComposer.js +48 -30
- package/dist/client/composer/TiptapComposer.js.map +1 -1
- package/dist/client/composer/VoiceButton.d.ts +2 -0
- package/dist/client/composer/VoiceButton.d.ts.map +1 -1
- package/dist/client/composer/VoiceButton.js +9 -3
- package/dist/client/composer/VoiceButton.js.map +1 -1
- package/dist/client/composer/index.d.ts +2 -2
- package/dist/client/composer/index.d.ts.map +1 -1
- package/dist/client/composer/index.js +1 -1
- package/dist/client/composer/index.js.map +1 -1
- package/dist/client/composer/useRealtimeVoiceMode.d.ts +104 -2
- package/dist/client/composer/useRealtimeVoiceMode.d.ts.map +1 -1
- package/dist/client/composer/useRealtimeVoiceMode.js +1015 -35
- package/dist/client/composer/useRealtimeVoiceMode.js.map +1 -1
- package/dist/client/context-xray/ContextXRayPanel.d.ts.map +1 -1
- package/dist/client/context-xray/ContextXRayPanel.js +4 -1
- package/dist/client/context-xray/ContextXRayPanel.js.map +1 -1
- package/dist/client/extensions/ExtensionEditor.d.ts.map +1 -1
- package/dist/client/extensions/ExtensionEditor.js +15 -5
- package/dist/client/extensions/ExtensionEditor.js.map +1 -1
- package/dist/client/extensions/ExtensionQueryErrorState.d.ts +8 -0
- package/dist/client/extensions/ExtensionQueryErrorState.d.ts.map +1 -0
- package/dist/client/extensions/ExtensionQueryErrorState.js +11 -0
- package/dist/client/extensions/ExtensionQueryErrorState.js.map +1 -0
- package/dist/client/extensions/ExtensionSlot.d.ts.map +1 -1
- package/dist/client/extensions/ExtensionSlot.js +17 -7
- package/dist/client/extensions/ExtensionSlot.js.map +1 -1
- package/dist/client/extensions/ExtensionViewer.d.ts.map +1 -1
- package/dist/client/extensions/ExtensionViewer.js +17 -7
- package/dist/client/extensions/ExtensionViewer.js.map +1 -1
- package/dist/client/extensions/ExtensionsListPage.d.ts.map +1 -1
- package/dist/client/extensions/ExtensionsListPage.js +5 -3
- package/dist/client/extensions/ExtensionsListPage.js.map +1 -1
- package/dist/client/extensions/ExtensionsSidebarSection.d.ts.map +1 -1
- package/dist/client/extensions/ExtensionsSidebarSection.js +21 -8
- package/dist/client/extensions/ExtensionsSidebarSection.js.map +1 -1
- package/dist/client/index.d.ts +1 -3
- package/dist/client/index.d.ts.map +1 -1
- package/dist/client/index.js +1 -6
- package/dist/client/index.js.map +1 -1
- package/dist/client/progress/RunsTray.d.ts.map +1 -1
- package/dist/client/progress/RunsTray.js +17 -4
- package/dist/client/progress/RunsTray.js.map +1 -1
- package/dist/client/settings/SecretsSection.d.ts +2 -3
- package/dist/client/settings/SecretsSection.d.ts.map +1 -1
- package/dist/client/settings/SecretsSection.js +46 -22
- package/dist/client/settings/SecretsSection.js.map +1 -1
- package/dist/client/settings/SettingsPanel.d.ts +9 -0
- package/dist/client/settings/SettingsPanel.d.ts.map +1 -1
- package/dist/client/settings/SettingsPanel.js +46 -12
- package/dist/client/settings/SettingsPanel.js.map +1 -1
- package/dist/client/settings/SettingsTabsPage.d.ts.map +1 -1
- package/dist/client/settings/SettingsTabsPage.js +4 -0
- package/dist/client/settings/SettingsTabsPage.js.map +1 -1
- package/dist/client/settings/useBuilderStatus.d.ts +2 -0
- package/dist/client/settings/useBuilderStatus.d.ts.map +1 -1
- package/dist/client/settings/useBuilderStatus.js +4 -0
- package/dist/client/settings/useBuilderStatus.js.map +1 -1
- package/dist/client/tool-cells/EditCell.d.ts.map +1 -1
- package/dist/client/tool-cells/EditCell.js +2 -1
- package/dist/client/tool-cells/EditCell.js.map +1 -1
- package/dist/client/tool-cells/FilesChangedSummary.d.ts.map +1 -1
- package/dist/client/tool-cells/FilesChangedSummary.js +2 -1
- package/dist/client/tool-cells/FilesChangedSummary.js.map +1 -1
- package/dist/client/tool-cells/WriteCell.d.ts.map +1 -1
- package/dist/client/tool-cells/WriteCell.js +2 -1
- package/dist/client/tool-cells/WriteCell.js.map +1 -1
- package/dist/client/use-action.d.ts +2 -0
- package/dist/client/use-action.d.ts.map +1 -1
- package/dist/client/use-action.js +10 -0
- package/dist/client/use-action.js.map +1 -1
- package/dist/client/use-agent-chat-home-handoff.d.ts +2 -0
- package/dist/client/use-agent-chat-home-handoff.d.ts.map +1 -1
- package/dist/client/use-agent-chat-home-handoff.js +7 -1
- package/dist/client/use-agent-chat-home-handoff.js.map +1 -1
- package/dist/client/use-agent-engine-configured.d.ts.map +1 -1
- package/dist/client/use-agent-engine-configured.js +17 -3
- package/dist/client/use-agent-engine-configured.js.map +1 -1
- package/dist/client/use-db-sync.d.ts +8 -2
- package/dist/client/use-db-sync.d.ts.map +1 -1
- package/dist/client/use-db-sync.js +57 -32
- package/dist/client/use-db-sync.js.map +1 -1
- package/dist/client/use-pausing-interval.d.ts.map +1 -1
- package/dist/client/use-pausing-interval.js +16 -4
- package/dist/client/use-pausing-interval.js.map +1 -1
- package/dist/client/visual-style-controls.js +1 -1
- package/dist/client/visual-style-controls.js.map +1 -1
- package/dist/collab/routes.d.ts +1 -1
- package/dist/deploy/build.d.ts.map +1 -1
- package/dist/deploy/build.js +36 -14
- package/dist/deploy/build.js.map +1 -1
- package/dist/integrations/google-docs-poller.d.ts +7 -0
- package/dist/integrations/google-docs-poller.d.ts.map +1 -1
- package/dist/integrations/google-docs-poller.js +13 -3
- package/dist/integrations/google-docs-poller.js.map +1 -1
- package/dist/integrations/plugin.d.ts.map +1 -1
- package/dist/integrations/plugin.js +10 -0
- package/dist/integrations/plugin.js.map +1 -1
- package/dist/integrations/scope-store.js +1 -1
- package/dist/integrations/scope-store.js.map +1 -1
- package/dist/integrations/usage-budget-store.js +1 -1
- package/dist/integrations/usage-budget-store.js.map +1 -1
- package/dist/integrations/webhook-handler.d.ts +11 -0
- package/dist/integrations/webhook-handler.d.ts.map +1 -1
- package/dist/integrations/webhook-handler.js +16 -4
- package/dist/integrations/webhook-handler.js.map +1 -1
- package/dist/jobs/scheduler.d.ts +12 -0
- package/dist/jobs/scheduler.d.ts.map +1 -1
- package/dist/jobs/scheduler.js +13 -3
- package/dist/jobs/scheduler.js.map +1 -1
- package/dist/localization/default-messages.d.ts +47 -0
- package/dist/localization/default-messages.d.ts.map +1 -1
- package/dist/localization/default-messages.js +48 -1
- package/dist/localization/default-messages.js.map +1 -1
- package/dist/mcp/oauth-token.d.ts +1 -1
- package/dist/mcp/oauth-token.d.ts.map +1 -1
- package/dist/mcp/oauth-token.js +6 -1
- package/dist/mcp/oauth-token.js.map +1 -1
- package/dist/mcp-client/workspace-servers.js +4 -4
- package/dist/mcp-client/workspace-servers.js.map +1 -1
- package/dist/notifications/routes.d.ts +2 -2
- package/dist/observability/routes.d.ts +5 -5
- package/dist/observability/routes.d.ts.map +1 -1
- package/dist/observability/routes.js +32 -0
- package/dist/observability/routes.js.map +1 -1
- package/dist/observability/sentiment.d.ts +42 -0
- package/dist/observability/sentiment.d.ts.map +1 -0
- package/dist/observability/sentiment.js +196 -0
- package/dist/observability/sentiment.js.map +1 -0
- package/dist/observability/store.d.ts +5 -0
- package/dist/observability/store.d.ts.map +1 -1
- package/dist/observability/store.js +17 -0
- package/dist/observability/store.js.map +1 -1
- package/dist/observability/traces.d.ts +2 -0
- package/dist/observability/traces.d.ts.map +1 -1
- package/dist/observability/traces.js +42 -57
- package/dist/observability/traces.js.map +1 -1
- package/dist/observability/tracking-identity.d.ts +3 -0
- package/dist/observability/tracking-identity.d.ts.map +1 -0
- package/dist/observability/tracking-identity.js +51 -0
- package/dist/observability/tracking-identity.js.map +1 -0
- package/dist/observability/types.d.ts +10 -0
- package/dist/observability/types.d.ts.map +1 -1
- package/dist/observability/types.js +3 -0
- package/dist/observability/types.js.map +1 -1
- package/dist/progress/routes.d.ts +1 -1
- package/dist/resources/handlers.d.ts +1 -1
- package/dist/secrets/crypto.d.ts +7 -6
- package/dist/secrets/crypto.d.ts.map +1 -1
- package/dist/secrets/crypto.js +30 -11
- package/dist/secrets/crypto.js.map +1 -1
- package/dist/secrets/routes.d.ts +9 -9
- package/dist/secrets/storage.d.ts +6 -0
- package/dist/secrets/storage.d.ts.map +1 -1
- package/dist/secrets/storage.js +61 -3
- package/dist/secrets/storage.js.map +1 -1
- package/dist/server/action-change.d.ts +1 -0
- package/dist/server/action-change.d.ts.map +1 -1
- package/dist/server/action-change.js +4 -1
- package/dist/server/action-change.js.map +1 -1
- package/dist/server/action-routes.d.ts.map +1 -1
- package/dist/server/action-routes.js +5 -0
- package/dist/server/action-routes.js.map +1 -1
- package/dist/server/agent-chat/action-filters-a2a.d.ts +50 -0
- package/dist/server/agent-chat/action-filters-a2a.d.ts.map +1 -0
- package/dist/server/agent-chat/action-filters-a2a.js +127 -0
- package/dist/server/agent-chat/action-filters-a2a.js.map +1 -0
- package/dist/server/agent-chat/browser-team-tools.d.ts +21 -0
- package/dist/server/agent-chat/browser-team-tools.d.ts.map +1 -0
- package/dist/server/agent-chat/browser-team-tools.js +417 -0
- package/dist/server/agent-chat/browser-team-tools.js.map +1 -0
- package/dist/server/agent-chat/context-tools.d.ts +33 -0
- package/dist/server/agent-chat/context-tools.d.ts.map +1 -0
- package/dist/server/agent-chat/context-tools.js +520 -0
- package/dist/server/agent-chat/context-tools.js.map +1 -0
- package/dist/server/agent-chat/framework-prompts.d.ts +65 -0
- package/dist/server/agent-chat/framework-prompts.d.ts.map +1 -0
- package/dist/server/agent-chat/framework-prompts.js +403 -0
- package/dist/server/agent-chat/framework-prompts.js.map +1 -0
- package/dist/server/agent-chat/lazy-fs.d.ts +2 -0
- package/dist/server/agent-chat/lazy-fs.d.ts.map +1 -0
- package/dist/server/agent-chat/lazy-fs.js +11 -0
- package/dist/server/agent-chat/lazy-fs.js.map +1 -0
- package/dist/server/agent-chat/mcp-glue.d.ts +9 -0
- package/dist/server/agent-chat/mcp-glue.d.ts.map +1 -0
- package/dist/server/agent-chat/mcp-glue.js +63 -0
- package/dist/server/agent-chat/mcp-glue.js.map +1 -0
- package/dist/server/agent-chat/plugin-options.d.ts +322 -0
- package/dist/server/agent-chat/plugin-options.d.ts.map +1 -0
- package/dist/server/agent-chat/plugin-options.js +2 -0
- package/dist/server/agent-chat/plugin-options.js.map +1 -0
- package/dist/server/agent-chat/process-run-failure.d.ts +12 -0
- package/dist/server/agent-chat/process-run-failure.d.ts.map +1 -0
- package/dist/server/agent-chat/process-run-failure.js +24 -0
- package/dist/server/agent-chat/process-run-failure.js.map +1 -0
- package/dist/server/agent-chat/prompt-resources.d.ts +28 -0
- package/dist/server/agent-chat/prompt-resources.d.ts.map +1 -0
- package/dist/server/agent-chat/prompt-resources.js +514 -0
- package/dist/server/agent-chat/prompt-resources.js.map +1 -0
- package/dist/server/agent-chat/recurring-jobs-runtime.d.ts +5 -0
- package/dist/server/agent-chat/recurring-jobs-runtime.d.ts.map +1 -0
- package/dist/server/agent-chat/recurring-jobs-runtime.js +53 -0
- package/dist/server/agent-chat/recurring-jobs-runtime.js.map +1 -0
- package/dist/server/agent-chat/request-surface.d.ts +8 -0
- package/dist/server/agent-chat/request-surface.d.ts.map +1 -0
- package/dist/server/agent-chat/request-surface.js +56 -0
- package/dist/server/agent-chat/request-surface.js.map +1 -0
- package/dist/server/agent-chat/run-code-tools.d.ts +17 -0
- package/dist/server/agent-chat/run-code-tools.d.ts.map +1 -0
- package/dist/server/agent-chat/run-code-tools.js +55 -0
- package/dist/server/agent-chat/run-code-tools.js.map +1 -0
- package/dist/server/agent-chat/script-entries.d.ts +47 -0
- package/dist/server/agent-chat/script-entries.d.ts.map +1 -0
- package/dist/server/agent-chat/script-entries.js +633 -0
- package/dist/server/agent-chat/script-entries.js.map +1 -0
- package/dist/server/agent-chat/shared-thread.d.ts +33 -0
- package/dist/server/agent-chat/shared-thread.d.ts.map +1 -0
- package/dist/server/agent-chat/shared-thread.js +242 -0
- package/dist/server/agent-chat/shared-thread.js.map +1 -0
- package/dist/server/agent-chat/skill-frontmatter.d.ts +7 -0
- package/dist/server/agent-chat/skill-frontmatter.d.ts.map +1 -0
- package/dist/server/agent-chat/skill-frontmatter.js +26 -0
- package/dist/server/agent-chat/skill-frontmatter.js.map +1 -0
- package/dist/server/agent-chat-plugin.d.ts +45 -486
- package/dist/server/agent-chat-plugin.d.ts.map +1 -1
- package/dist/server/agent-chat-plugin.js +173 -3005
- package/dist/server/agent-chat-plugin.js.map +1 -1
- package/dist/server/agent-teams.d.ts +10 -0
- package/dist/server/agent-teams.d.ts.map +1 -1
- package/dist/server/agent-teams.js +13 -3
- package/dist/server/agent-teams.js.map +1 -1
- package/dist/server/auth.d.ts.map +1 -1
- package/dist/server/auth.js +50 -52
- package/dist/server/auth.js.map +1 -1
- package/dist/server/credential-provider.d.ts.map +1 -1
- package/dist/server/credential-provider.js +22 -21
- package/dist/server/credential-provider.js.map +1 -1
- package/dist/server/edge.d.ts +1 -0
- package/dist/server/edge.d.ts.map +1 -1
- package/dist/server/edge.js +1 -0
- package/dist/server/edge.js.map +1 -1
- package/dist/server/onboarding-html.d.ts.map +1 -1
- package/dist/server/onboarding-html.js +1 -16
- package/dist/server/onboarding-html.js.map +1 -1
- package/dist/server/poll.d.ts.map +1 -1
- package/dist/server/poll.js +1 -0
- package/dist/server/poll.js.map +1 -1
- package/dist/server/realtime-voice.d.ts +10 -0
- package/dist/server/realtime-voice.d.ts.map +1 -1
- package/dist/server/realtime-voice.js +249 -15
- package/dist/server/realtime-voice.js.map +1 -1
- package/dist/server/request-origin.d.ts.map +1 -1
- package/dist/server/request-origin.js +6 -3
- package/dist/server/request-origin.js.map +1 -1
- package/dist/server/ssr-handler.d.ts.map +1 -1
- package/dist/server/ssr-handler.js +47 -2
- package/dist/server/ssr-handler.js.map +1 -1
- package/dist/sharing/access.d.ts +63 -3
- package/dist/sharing/access.d.ts.map +1 -1
- package/dist/sharing/access.js +53 -15
- package/dist/sharing/access.js.map +1 -1
- package/dist/sharing/registry.d.ts +7 -0
- package/dist/sharing/registry.d.ts.map +1 -1
- package/dist/sharing/registry.js.map +1 -1
- package/dist/styles/agent-native.css +17 -16
- package/dist/templates/default/.agents/skills/frontend-design/SKILL.md +1 -1
- package/dist/templates/default/.agents/skills/real-time-sync/SKILL.md +2 -2
- package/dist/templates/default/app/i18n/ar-SA.ts +6 -0
- package/dist/templates/default/app/i18n/de-DE.ts +6 -0
- package/dist/templates/default/app/i18n/en-US.ts +6 -0
- package/dist/templates/default/app/i18n/es-ES.ts +6 -0
- package/dist/templates/default/app/i18n/fr-FR.ts +6 -0
- package/dist/templates/default/app/i18n/hi-IN.ts +6 -0
- package/dist/templates/default/app/i18n/ja-JP.ts +6 -0
- package/dist/templates/default/app/i18n/ko-KR.ts +6 -0
- package/dist/templates/default/app/i18n/pt-BR.ts +6 -0
- package/dist/templates/default/app/i18n/zh-CN.ts +6 -0
- package/dist/templates/default/app/i18n/zh-TW.ts +6 -0
- package/dist/templates/workspace-core/.agents/skills/authentication/SKILL.md +27 -29
- package/dist/templates/workspace-core/.agents/skills/external-agents/SKILL.md +2 -1
- package/dist/templates/workspace-core/.agents/skills/frontend-design/SKILL.md +1 -1
- package/dist/templates/workspace-core/.agents/skills/observability/SKILL.md +32 -0
- package/dist/templates/workspace-core/.agents/skills/real-time-sync/SKILL.md +2 -2
- package/dist/templates/workspace-core/.agents/skills/secrets/SKILL.md +7 -3
- package/dist/templates/workspace-core/.agents/skills/voice-transcription/SKILL.md +39 -9
- package/dist/templates/workspace-core/.agents/skills/writing-agent-instructions/SKILL.md +25 -0
- package/dist/templates/workspace-core/src/server/index.ts +4 -2
- package/dist/testing.d.ts +16 -0
- package/dist/testing.d.ts.map +1 -0
- package/dist/testing.js +16 -0
- package/dist/testing.js.map +1 -0
- package/dist/triggers/dispatcher.d.ts +7 -0
- package/dist/triggers/dispatcher.d.ts.map +1 -1
- package/dist/triggers/dispatcher.js +13 -3
- package/dist/triggers/dispatcher.js.map +1 -1
- package/dist/vite/client.d.ts +16 -1
- package/dist/vite/client.d.ts.map +1 -1
- package/dist/vite/client.js +111 -3
- package/dist/vite/client.js.map +1 -1
- package/docs/content/authentication.mdx +3 -3
- package/docs/content/doctor.mdx +170 -0
- package/docs/content/external-agents.mdx +8 -7
- package/docs/content/locales/ar-SA/authentication.mdx +2 -2
- package/docs/content/locales/ar-SA/external-agents.mdx +8 -7
- package/docs/content/locales/ar-SA/mcp-protocol.mdx +1 -1
- package/docs/content/locales/ar-SA/security.mdx +2 -0
- package/docs/content/locales/de-DE/authentication.mdx +1 -1
- package/docs/content/locales/de-DE/external-agents.mdx +8 -7
- package/docs/content/locales/de-DE/mcp-protocol.mdx +1 -1
- package/docs/content/locales/de-DE/security.mdx +2 -0
- package/docs/content/locales/es-ES/authentication.mdx +2 -2
- package/docs/content/locales/es-ES/external-agents.mdx +8 -7
- package/docs/content/locales/es-ES/mcp-protocol.mdx +1 -1
- package/docs/content/locales/es-ES/security.mdx +2 -0
- package/docs/content/locales/fr-FR/authentication.mdx +1 -1
- package/docs/content/locales/fr-FR/external-agents.mdx +8 -7
- package/docs/content/locales/fr-FR/mcp-protocol.mdx +1 -1
- package/docs/content/locales/fr-FR/security.mdx +2 -0
- package/docs/content/locales/hi-IN/authentication.mdx +2 -2
- package/docs/content/locales/hi-IN/external-agents.mdx +8 -7
- package/docs/content/locales/hi-IN/mcp-protocol.mdx +1 -1
- package/docs/content/locales/hi-IN/security.mdx +2 -0
- package/docs/content/locales/ja-JP/authentication.mdx +2 -2
- package/docs/content/locales/ja-JP/external-agents.mdx +8 -7
- package/docs/content/locales/ja-JP/mcp-protocol.mdx +1 -1
- package/docs/content/locales/ja-JP/security.mdx +2 -0
- package/docs/content/locales/ko-KR/authentication.mdx +2 -2
- package/docs/content/locales/ko-KR/external-agents.mdx +8 -7
- package/docs/content/locales/ko-KR/mcp-protocol.mdx +1 -1
- package/docs/content/locales/ko-KR/security.mdx +2 -0
- package/docs/content/locales/pt-BR/authentication.mdx +2 -2
- package/docs/content/locales/pt-BR/external-agents.mdx +8 -7
- package/docs/content/locales/pt-BR/mcp-protocol.mdx +1 -1
- package/docs/content/locales/pt-BR/security.mdx +2 -0
- package/docs/content/locales/zh-CN/authentication.mdx +2 -2
- package/docs/content/locales/zh-CN/external-agents.mdx +8 -7
- package/docs/content/locales/zh-CN/mcp-protocol.mdx +1 -1
- package/docs/content/locales/zh-CN/security.mdx +2 -0
- package/docs/content/locales/zh-TW/authentication.mdx +2 -2
- package/docs/content/locales/zh-TW/external-agents.mdx +8 -7
- package/docs/content/locales/zh-TW/mcp-protocol.mdx +1 -1
- package/docs/content/locales/zh-TW/security.mdx +2 -0
- package/docs/content/mcp-protocol.mdx +1 -1
- package/docs/content/security.mdx +2 -0
- package/package.json +7 -3
- package/src/templates/default/.agents/skills/frontend-design/SKILL.md +1 -1
- package/src/templates/default/.agents/skills/real-time-sync/SKILL.md +2 -2
- package/src/templates/default/app/i18n/ar-SA.ts +6 -0
- package/src/templates/default/app/i18n/de-DE.ts +6 -0
- package/src/templates/default/app/i18n/en-US.ts +6 -0
- package/src/templates/default/app/i18n/es-ES.ts +6 -0
- package/src/templates/default/app/i18n/fr-FR.ts +6 -0
- package/src/templates/default/app/i18n/hi-IN.ts +6 -0
- package/src/templates/default/app/i18n/ja-JP.ts +6 -0
- package/src/templates/default/app/i18n/ko-KR.ts +6 -0
- package/src/templates/default/app/i18n/pt-BR.ts +6 -0
- package/src/templates/default/app/i18n/zh-CN.ts +6 -0
- package/src/templates/default/app/i18n/zh-TW.ts +6 -0
- package/src/templates/workspace-core/.agents/skills/authentication/SKILL.md +27 -29
- package/src/templates/workspace-core/.agents/skills/external-agents/SKILL.md +2 -1
- package/src/templates/workspace-core/.agents/skills/frontend-design/SKILL.md +1 -1
- package/src/templates/workspace-core/.agents/skills/observability/SKILL.md +32 -0
- package/src/templates/workspace-core/.agents/skills/real-time-sync/SKILL.md +2 -2
- package/src/templates/workspace-core/.agents/skills/secrets/SKILL.md +7 -3
- package/src/templates/workspace-core/.agents/skills/voice-transcription/SKILL.md +39 -9
- package/src/templates/workspace-core/.agents/skills/writing-agent-instructions/SKILL.md +25 -0
- package/src/templates/workspace-core/src/server/index.ts +4 -2
- package/corpus/core/src/client/ProductionAgentPanel.tsx +0 -9
- package/corpus/core/src/client/auth-redirect-url.ts +0 -23
- package/corpus/core/src/client/useProductionAgent.ts +0 -253
- package/corpus/core/src/shared/auth-redirect-url.ts +0 -1
- package/corpus/templates/analytics/app/pages/Index.tsx +0 -16
- package/corpus/templates/analytics/seeds/dashboards/agent-observability-llm.json +0 -173
- package/dist/client/ProductionAgentPanel.d.ts +0 -6
- package/dist/client/ProductionAgentPanel.d.ts.map +0 -1
- package/dist/client/ProductionAgentPanel.js +0 -6
- package/dist/client/ProductionAgentPanel.js.map +0 -1
- package/dist/client/auth-redirect-url.d.ts +0 -2
- package/dist/client/auth-redirect-url.d.ts.map +0 -1
- package/dist/client/auth-redirect-url.js +0 -19
- package/dist/client/auth-redirect-url.js.map +0 -1
- package/dist/client/useProductionAgent.d.ts +0 -24
- package/dist/client/useProductionAgent.d.ts.map +0 -1
- package/dist/client/useProductionAgent.js +0 -179
- package/dist/client/useProductionAgent.js.map +0 -1
- package/dist/shared/auth-redirect-url.d.ts +0 -2
- package/dist/shared/auth-redirect-url.d.ts.map +0 -1
- package/dist/shared/auth-redirect-url.js +0 -2
- package/dist/shared/auth-redirect-url.js.map +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"RealtimeVoiceMode.d.ts","sourceRoot":"","sources":["../../../src/client/composer/RealtimeVoiceMode.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Realtime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@agent-native/toolkit/ui/button";
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
3
|
+
import { Select, SelectContent, SelectGroup, SelectItem, SelectTrigger, } from "@agent-native/toolkit/ui/select";
|
|
4
|
+
import { IconAlertTriangle, IconBrain, IconLanguage, IconLoader2, IconMicrophone, IconPhoneOff, IconSettings, IconVolume, } from "@tabler/icons-react";
|
|
5
|
+
import { useCallback, useEffect, useId, useRef, useState, useSyncExternalStore, } from "react";
|
|
6
|
+
import { Popover, PopoverAnchor, PopoverContent, PopoverTrigger, } from "../components/ui/popover.js";
|
|
6
7
|
import { Tooltip, TooltipContent, TooltipTrigger, } from "../components/ui/tooltip.js";
|
|
7
8
|
import { cn } from "../utils.js";
|
|
8
9
|
import { createRealtimeVoiceAudioLevelStore, } from "./realtime-voice-audio-level.js";
|
|
@@ -11,11 +12,16 @@ import { createRealtimeVoiceAudioLevelStore, } from "./realtime-voice-audio-leve
|
|
|
11
12
|
* The first click offers voice mode without silently changing the existing
|
|
12
13
|
* editable-dictation behavior.
|
|
13
14
|
*/
|
|
14
|
-
export function RealtimeVoiceModeEntry({ copy, disabled, open: controlledOpen, onOpenChange, onStartVoiceMode, onKeepDictating, setupRequired = false, openAiConfigured = false, connectingBuilder = false, onConnectBuilder, onUseOpenAiKey, className, }) {
|
|
15
|
+
export function RealtimeVoiceModeEntry({ copy, disabled, providerStatusPending = false, open: controlledOpen, onOpenChange, onStartVoiceMode, onKeepDictating, setupRequired = false, openAiConfigured = false, connectingBuilder = false, onConnectBuilder, onUseOpenAiKey, className, }) {
|
|
15
16
|
const [uncontrolledOpen, setUncontrolledOpen] = useState(false);
|
|
16
17
|
const open = controlledOpen ?? uncontrolledOpen;
|
|
17
18
|
const titleId = useId();
|
|
18
19
|
const descriptionId = useId();
|
|
20
|
+
const [collisionBoundary, setCollisionBoundary] = useState(null);
|
|
21
|
+
const setTriggerNode = useCallback((node) => {
|
|
22
|
+
const nextBoundary = node?.closest(".agent-panel-root") ?? null;
|
|
23
|
+
setCollisionBoundary((currentBoundary) => currentBoundary === nextBoundary ? currentBoundary : nextBoundary);
|
|
24
|
+
}, []);
|
|
19
25
|
const setOpen = (nextOpen) => {
|
|
20
26
|
if (controlledOpen === undefined)
|
|
21
27
|
setUncontrolledOpen(nextOpen);
|
|
@@ -25,9 +31,11 @@ export function RealtimeVoiceModeEntry({ copy, disabled, open: controlledOpen, o
|
|
|
25
31
|
setOpen(false);
|
|
26
32
|
callback();
|
|
27
33
|
};
|
|
28
|
-
return (_jsxs(Popover, { open: open, onOpenChange: setOpen, children: [_jsxs(Tooltip, { children: [_jsx(TooltipTrigger, { asChild: true, children: _jsx(PopoverTrigger, { asChild: true, children: _jsx(Button, { type: "button", variant: "ghost", size: "icon", disabled: disabled, "aria-label": copy.entryButtonLabel, "aria-expanded": open, className: cn("size-7 shrink-0 text-muted-foreground hover:text-foreground", className), children: _jsx(IconMicrophone, {}) }) }) }), _jsx(TooltipContent, { children: copy.entryButtonLabel })] }), _jsx(PopoverContent, { side: "top", align: "end", sideOffset: 10,
|
|
34
|
+
return (_jsxs(Popover, { open: open, onOpenChange: setOpen, children: [_jsxs(Tooltip, { children: [_jsx(TooltipTrigger, { asChild: true, children: _jsx(PopoverTrigger, { asChild: true, children: _jsx(Button, { ref: setTriggerNode, type: "button", variant: "ghost", size: "icon", disabled: disabled, "aria-label": copy.entryButtonLabel, "aria-expanded": open, className: cn("size-7 shrink-0 text-muted-foreground hover:text-foreground", className), children: _jsx(IconMicrophone, {}) }) }) }), _jsx(TooltipContent, { children: copy.entryButtonLabel })] }), _jsx(PopoverContent, { side: "top", align: "end", sideOffset: 10, collisionBoundary: collisionBoundary ?? undefined, collisionPadding: 16, "data-collision-boundary": collisionBoundary ? "agent-panel" : "viewport", className: cn("p-4", setupRequired
|
|
35
|
+
? "w-[min(calc(100vw-2rem),var(--radix-popover-content-available-width,30rem),30rem)]"
|
|
36
|
+
: "w-[min(calc(100vw-2rem),var(--radix-popover-content-available-width,22rem),22rem)]"), "aria-labelledby": titleId, "aria-describedby": descriptionId, children: _jsxs("div", { className: "grid gap-3", children: [_jsxs("div", { className: "grid gap-1", children: [_jsx("h2", { id: titleId, className: "text-sm font-semibold text-foreground", children: setupRequired ? copy.setupTitle : copy.promptTitle }), _jsx("p", { id: descriptionId, className: "text-sm leading-relaxed text-muted-foreground", children: setupRequired ? copy.setupDescription : copy.promptDescription })] }), _jsxs("div", { className: "flex flex-col-reverse gap-2 sm:flex-row sm:flex-wrap sm:justify-end", children: [_jsx(Button, { type: "button", variant: "ghost", size: "sm", onClick: () => choose(onKeepDictating), children: copy.keepDictating }), setupRequired ? (_jsxs(_Fragment, { children: [_jsx(Button, { type: "button", variant: "outline", size: "sm", onClick: () => choose(onUseOpenAiKey ?? onStartVoiceMode), children: openAiConfigured
|
|
29
37
|
? copy.startWithOpenAiKey
|
|
30
|
-
: copy.useOpenAiKey }), _jsxs(Button, { type: "button", size: "sm", disabled: connectingBuilder, onClick: () => choose(onConnectBuilder ?? onStartVoiceMode), children: [connectingBuilder ? (_jsx(IconLoader2, { className: "animate-spin" })) : null, copy.connectBuilder] })] })) : (_jsxs(Button, { type: "button", size: "sm", onClick: () => choose(onStartVoiceMode), children: [_jsx(IconMicrophone, {}), copy.startVoiceMode] }))] })] }) })] }));
|
|
38
|
+
: copy.useOpenAiKey }), _jsxs(Button, { type: "button", size: "sm", className: "whitespace-nowrap", disabled: connectingBuilder, onClick: () => choose(onConnectBuilder ?? onStartVoiceMode), children: [connectingBuilder ? (_jsx(IconLoader2, { className: "animate-spin" })) : null, copy.connectBuilder] })] })) : (_jsxs(Button, { type: "button", size: "sm", disabled: providerStatusPending, onClick: () => choose(onStartVoiceMode), children: [providerStatusPending ? (_jsx(IconLoader2, { className: "animate-spin" })) : (_jsx(IconMicrophone, {})), copy.startVoiceMode] }))] })] }) })] }));
|
|
31
39
|
}
|
|
32
40
|
const SILENT_AUDIO_LEVELS = createRealtimeVoiceAudioLevelStore();
|
|
33
41
|
const WAVEFORM_WEIGHTS = [0.55, 0.82, 1, 0.82, 0.55];
|
|
@@ -45,50 +53,193 @@ function usePrefersReducedMotion() {
|
|
|
45
53
|
}, []);
|
|
46
54
|
return reduced;
|
|
47
55
|
}
|
|
48
|
-
function VoiceWaveform({ level, reducedMotion, }) {
|
|
56
|
+
function VoiceWaveform({ level, reducedMotion, activity, }) {
|
|
49
57
|
const visibleLevel = reducedMotion ? 0.45 : level;
|
|
50
|
-
return (_jsx("span", { "aria-hidden": "true", className: "flex h-6 items-center justify-center gap-0.5", "data-realtime-voice-waveform": "true", children: WAVEFORM_WEIGHTS.map((weight, index) => (_jsx("span", { className: "w-0.5 rounded-full bg-current transition-
|
|
58
|
+
return (_jsx("span", { "aria-hidden": "true", className: "flex h-6 items-center justify-center gap-0.5", "data-realtime-voice-waveform": "true", "data-realtime-voice-waveform-activity": activity, children: WAVEFORM_WEIGHTS.map((weight, index) => (_jsx("span", { className: "h-5 w-0.5 origin-center rounded-full bg-current transition-transform duration-75 ease-out motion-reduce:transition-none", style: {
|
|
59
|
+
transform: `scaleY(${0.2 + visibleLevel * 0.8 * weight})`,
|
|
60
|
+
} }, index))) }));
|
|
61
|
+
}
|
|
62
|
+
function VoiceConnectingIndicator() {
|
|
63
|
+
return (_jsx(IconLoader2, { "aria-hidden": "true", className: "size-6 animate-spin motion-reduce:animate-none", "data-realtime-voice-connecting-indicator": "true" }));
|
|
51
64
|
}
|
|
52
65
|
const ORB_STATE_CLASSES = {
|
|
53
|
-
connecting: "bg-
|
|
54
|
-
listening: "bg-
|
|
55
|
-
speaking: "bg-
|
|
56
|
-
working: "bg-
|
|
57
|
-
error: "bg-destructive text-destructive
|
|
58
|
-
ending: "bg-
|
|
66
|
+
connecting: "bg-background/65 text-foreground ring-border/60 hover:bg-background/75",
|
|
67
|
+
listening: "bg-background/65 text-foreground ring-border/60 hover:bg-background/75",
|
|
68
|
+
speaking: "bg-background/65 text-foreground ring-border/60 hover:bg-background/75",
|
|
69
|
+
working: "bg-background/65 text-foreground ring-border/60 hover:bg-background/75",
|
|
70
|
+
error: "bg-destructive/20 text-destructive ring-destructive/30 hover:bg-destructive/25",
|
|
71
|
+
ending: "cursor-wait bg-background/65 text-muted-foreground ring-border/60",
|
|
59
72
|
};
|
|
60
|
-
function
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
return
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
73
|
+
function useChatPanelTranslation(chatVisible) {
|
|
74
|
+
const [translation, setTranslation] = useState(0);
|
|
75
|
+
useEffect(() => {
|
|
76
|
+
if (!chatVisible || typeof window === "undefined") {
|
|
77
|
+
setTranslation(0);
|
|
78
|
+
return;
|
|
79
|
+
}
|
|
80
|
+
const direction = window.getComputedStyle(document.documentElement).direction;
|
|
81
|
+
const inlineEnd = direction === "rtl" ? "left" : "right";
|
|
82
|
+
const update = () => {
|
|
83
|
+
const panels = Array.from(document.querySelectorAll(`.agent-sidebar-panel[data-agent-sidebar-position="${inlineEnd}"][data-agent-sidebar-state="open"]`));
|
|
84
|
+
const panel = panels.find((candidate) => {
|
|
85
|
+
const rect = candidate.getBoundingClientRect();
|
|
86
|
+
return rect.width > 0 && rect.height > 0;
|
|
87
|
+
});
|
|
88
|
+
if (!panel) {
|
|
89
|
+
setTranslation(0);
|
|
90
|
+
return;
|
|
91
|
+
}
|
|
92
|
+
// A fullscreen chat has no unobscured side to move into. Keep the dock
|
|
93
|
+
// at its normal edge so it stays reachable instead of pinning it to the
|
|
94
|
+
// opposite side of the same overlay.
|
|
95
|
+
if (panel.dataset.agentSidebarLayout === "fullscreen") {
|
|
96
|
+
setTranslation(0);
|
|
97
|
+
return;
|
|
98
|
+
}
|
|
99
|
+
const rect = panel.getBoundingClientRect();
|
|
100
|
+
const overlap = inlineEnd === "right"
|
|
101
|
+
? Math.max(0, window.innerWidth - rect.left)
|
|
102
|
+
: Math.max(0, rect.right);
|
|
103
|
+
const maximumShift = Math.max(0, window.innerWidth - 96);
|
|
104
|
+
const distance = Math.min(overlap, maximumShift);
|
|
105
|
+
setTranslation(inlineEnd === "right" ? -distance : distance);
|
|
106
|
+
};
|
|
107
|
+
update();
|
|
108
|
+
const frame = window.requestAnimationFrame(update);
|
|
109
|
+
window.addEventListener("resize", update);
|
|
110
|
+
const resizeObserver = typeof ResizeObserver === "undefined" ? null : new ResizeObserver(update);
|
|
111
|
+
const observedPanels = new WeakSet();
|
|
112
|
+
const observePanels = () => {
|
|
113
|
+
document
|
|
114
|
+
.querySelectorAll(".agent-sidebar-panel")
|
|
115
|
+
.forEach((panel) => {
|
|
116
|
+
if (!observedPanels.has(panel)) {
|
|
117
|
+
observedPanels.add(panel);
|
|
118
|
+
resizeObserver?.observe(panel);
|
|
119
|
+
}
|
|
120
|
+
});
|
|
121
|
+
};
|
|
122
|
+
observePanels();
|
|
123
|
+
const mutationObserver = new MutationObserver(() => {
|
|
124
|
+
observePanels();
|
|
125
|
+
update();
|
|
126
|
+
});
|
|
127
|
+
mutationObserver.observe(document.body, {
|
|
128
|
+
attributes: true,
|
|
129
|
+
attributeFilter: [
|
|
130
|
+
"data-agent-sidebar-layout",
|
|
131
|
+
"data-agent-sidebar-state",
|
|
132
|
+
"style",
|
|
133
|
+
],
|
|
134
|
+
childList: true,
|
|
135
|
+
subtree: true,
|
|
136
|
+
});
|
|
137
|
+
return () => {
|
|
138
|
+
window.cancelAnimationFrame(frame);
|
|
139
|
+
window.removeEventListener("resize", update);
|
|
140
|
+
resizeObserver?.disconnect();
|
|
141
|
+
mutationObserver.disconnect();
|
|
142
|
+
};
|
|
143
|
+
}, [chatVisible]);
|
|
144
|
+
return translation;
|
|
145
|
+
}
|
|
146
|
+
function VoiceSettingRow({ icon: Icon, setting, onSelectOpenChange, }) {
|
|
147
|
+
const selected = setting.options.find((option) => option.value === setting.value);
|
|
148
|
+
return (_jsxs(Select, { value: setting.value, onValueChange: setting.onValueChange, onOpenChange: onSelectOpenChange, disabled: setting.disabled, children: [_jsx(SelectTrigger, { "aria-label": `${setting.label}: ${selected?.label ?? setting.value}`, className: "h-11 rounded-none border-0 bg-transparent px-3 shadow-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-inset", children: _jsxs("div", { className: "flex min-w-0 flex-1 items-center gap-2.5", children: [_jsx(Icon, { className: "size-4 shrink-0 text-muted-foreground" }), _jsx("span", { className: "shrink-0 text-sm font-medium text-foreground", children: setting.label }), _jsx("span", { className: "ms-auto min-w-0 truncate text-end text-sm text-muted-foreground", children: selected?.label ?? setting.value })] }) }), _jsx(SelectContent, { align: "end", className: "min-w-56", "data-realtime-voice-setting-options": "true", children: _jsx(SelectGroup, { children: setting.options.map((option) => (_jsx(SelectItem, { value: option.value, children: _jsxs("span", { className: "grid gap-0.5", children: [_jsx("span", { children: option.label }), option.description ? (_jsx("span", { className: "text-xs text-muted-foreground", children: option.description })) : null] }) }, option.value))) }) })] }));
|
|
149
|
+
}
|
|
150
|
+
function VoiceInlineSettings({ settings, disabled, onSelectOpenChange, }) {
|
|
151
|
+
const selectedVoice = settings.voiceStyle.options.find((option) => option.value === settings.voiceStyle.value);
|
|
152
|
+
return (_jsxs("div", { "data-realtime-voice-settings": "true", children: [_jsx("h2", { className: "sr-only", children: settings.dialogLabel }), _jsxs("div", { className: "grid gap-0.5 px-4 pb-3 pt-4 text-center", children: [_jsx("div", { className: "truncate text-base font-semibold text-foreground", children: selectedVoice?.label ?? settings.voiceStyle.value }), selectedVoice?.description ? (_jsx("div", { className: "truncate text-xs text-muted-foreground", children: selectedVoice.description })) : null] }), _jsxs("div", { className: "mx-2 mb-2 overflow-hidden rounded-xl border border-border/70 bg-background/70", children: [_jsx(VoiceSettingRow, { icon: IconMicrophone, setting: {
|
|
153
|
+
...settings.microphone,
|
|
154
|
+
disabled: disabled || settings.microphone.disabled,
|
|
155
|
+
}, onSelectOpenChange: onSelectOpenChange }), _jsx("div", { className: "mx-3 h-px bg-border/70" }), _jsx(VoiceSettingRow, { icon: IconLanguage, setting: {
|
|
156
|
+
...settings.language,
|
|
157
|
+
disabled: disabled || settings.language.disabled,
|
|
158
|
+
}, onSelectOpenChange: onSelectOpenChange }), _jsx("div", { className: "mx-3 h-px bg-border/70" }), _jsx(VoiceSettingRow, { icon: IconBrain, setting: {
|
|
159
|
+
...settings.intelligence,
|
|
160
|
+
disabled: disabled || settings.intelligence.disabled,
|
|
161
|
+
}, onSelectOpenChange: onSelectOpenChange }), _jsx("div", { className: "mx-3 h-px bg-border/70" }), _jsx(VoiceSettingRow, { icon: IconVolume, setting: {
|
|
162
|
+
...settings.voiceStyle,
|
|
163
|
+
disabled: disabled || settings.voiceStyle.disabled,
|
|
164
|
+
}, onSelectOpenChange: onSelectOpenChange })] }), settings.microphoneError ? (_jsx("p", { className: "px-4 pb-3 text-center text-xs text-destructive", children: settings.microphoneError })) : null, settings.appliesNextConversationNote ? (_jsx("p", { className: "px-4 pb-3 text-center text-xs text-muted-foreground", children: settings.appliesNextConversationNote })) : null] }));
|
|
74
165
|
}
|
|
75
166
|
/**
|
|
76
167
|
* Persistent voice-session control. Toggling the main orb only changes chat
|
|
77
168
|
* visibility; ending the realtime session is intentionally a separate action.
|
|
78
169
|
*/
|
|
79
|
-
export function RealtimeVoiceModeDock({ state, copy, chatVisible, audioLevels = SILENT_AUDIO_LEVELS, onToggleChat, onEndVoiceMode, errorMessage, className, }) {
|
|
170
|
+
export function RealtimeVoiceModeDock({ state, copy, chatVisible, audioLevels = SILENT_AUDIO_LEVELS, onToggleChat, onEndVoiceMode, settings, errorMessage, className, }) {
|
|
80
171
|
const statusId = useId();
|
|
172
|
+
const controlsId = useId();
|
|
173
|
+
const [controlsOpen, setControlsOpen] = useState(false);
|
|
174
|
+
const [settingsOpen, setSettingsOpen] = useState(false);
|
|
175
|
+
const selectInteractionRef = useRef(false);
|
|
176
|
+
const selectInteractionFrameRef = useRef(null);
|
|
81
177
|
const levels = useSyncExternalStore(audioLevels.subscribe, audioLevels.getSnapshot, audioLevels.getSnapshot);
|
|
82
178
|
const reducedMotion = usePrefersReducedMotion();
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
179
|
+
// Microphone metering begins while the SDP request is still in flight. Keep
|
|
180
|
+
// the connecting affordance authoritative until WebRTC is established;
|
|
181
|
+
// otherwise speaking into the mic replaces the loader with a waveform and
|
|
182
|
+
// makes a stalled connection look like a live call.
|
|
183
|
+
const connected = state === "listening" || state === "speaking" || state === "working";
|
|
184
|
+
const activity = connected
|
|
185
|
+
? levels.output > AUDIO_ACTIVITY_THRESHOLD
|
|
186
|
+
? "assistant"
|
|
187
|
+
: levels.input > AUDIO_ACTIVITY_THRESHOLD
|
|
188
|
+
? "user"
|
|
189
|
+
: "idle"
|
|
190
|
+
: "idle";
|
|
88
191
|
const activityLevel = activity === "assistant" ? levels.output : levels.input;
|
|
89
192
|
const toggleLabel = chatVisible ? copy.hideChat : copy.showChat;
|
|
90
193
|
const ending = state === "ending";
|
|
91
194
|
const errorDetailVisible = state === "error" && Boolean(errorMessage);
|
|
92
|
-
|
|
195
|
+
const controlsVisible = controlsOpen || settingsOpen;
|
|
196
|
+
const chatPanelTranslation = useChatPanelTranslation(chatVisible);
|
|
197
|
+
const handleSelectOpenChange = useCallback((open) => {
|
|
198
|
+
if (selectInteractionFrameRef.current !== null) {
|
|
199
|
+
window.cancelAnimationFrame(selectInteractionFrameRef.current);
|
|
200
|
+
selectInteractionFrameRef.current = null;
|
|
201
|
+
}
|
|
202
|
+
selectInteractionRef.current = true;
|
|
203
|
+
if (!open) {
|
|
204
|
+
// Radix closes the portalled Select before its focus/outside events have
|
|
205
|
+
// fully settled. Keep the parent protected through the current frame.
|
|
206
|
+
selectInteractionFrameRef.current = window.requestAnimationFrame(() => {
|
|
207
|
+
selectInteractionRef.current = false;
|
|
208
|
+
selectInteractionFrameRef.current = null;
|
|
209
|
+
});
|
|
210
|
+
}
|
|
211
|
+
}, []);
|
|
212
|
+
useEffect(() => () => {
|
|
213
|
+
if (selectInteractionFrameRef.current !== null) {
|
|
214
|
+
window.cancelAnimationFrame(selectInteractionFrameRef.current);
|
|
215
|
+
}
|
|
216
|
+
}, []);
|
|
217
|
+
const closeControlsUnlessFocused = (event) => {
|
|
218
|
+
if (settingsOpen)
|
|
219
|
+
return;
|
|
220
|
+
if (!event.currentTarget.contains(document.activeElement)) {
|
|
221
|
+
setControlsOpen(false);
|
|
222
|
+
}
|
|
223
|
+
};
|
|
224
|
+
return (_jsxs("div", { className: cn("pointer-events-none fixed bottom-4 end-4 flex max-w-[calc(100vw-2rem)] flex-col items-end gap-2 transition-transform duration-200 ease-[var(--ease-collapse)] motion-reduce:transition-none", className), style: {
|
|
225
|
+
zIndex: 270,
|
|
226
|
+
transform: `translateX(${chatPanelTranslation}px)`,
|
|
227
|
+
}, "data-realtime-voice-state": state, "data-realtime-voice-activity": activity, "data-realtime-voice-chat-offset": chatPanelTranslation, children: [errorDetailVisible ? (_jsx("div", { role: "alert", className: "pointer-events-auto max-w-xs rounded-lg border border-destructive/30 bg-background px-3 py-2 text-sm text-destructive shadow-md", children: errorMessage })) : null, _jsxs("div", { className: "group pointer-events-auto flex items-center gap-2", onMouseEnter: () => setControlsOpen(true), onMouseLeave: closeControlsUnlessFocused, onFocusCapture: () => setControlsOpen(true), onBlurCapture: (event) => {
|
|
228
|
+
if (!event.currentTarget.contains(event.relatedTarget)) {
|
|
229
|
+
setControlsOpen(false);
|
|
230
|
+
}
|
|
231
|
+
}, children: [_jsxs("div", { id: controlsId, "data-realtime-voice-controls": controlsVisible ? "open" : "closed", className: cn("flex items-center gap-1 rounded-full border border-border/70 bg-background/95 p-1 shadow-lg backdrop-blur-md transition-[transform,opacity] duration-150 ease-out motion-reduce:transition-none", controlsVisible
|
|
232
|
+
? "pointer-events-auto translate-x-0 opacity-100"
|
|
233
|
+
: "pointer-events-none opacity-0 ltr:translate-x-2 rtl:-translate-x-2 group-hover:pointer-events-auto group-hover:translate-x-0 group-hover:opacity-100 group-focus-within:pointer-events-auto group-focus-within:translate-x-0 group-focus-within:opacity-100"), children: [_jsx("span", { id: statusId, role: state === "error" && !errorDetailVisible ? "alert" : "status", "aria-live": state === "error" && !errorDetailVisible ? "assertive" : "polite", className: "sr-only", children: copy.status[state] }), settings ? (_jsxs(Popover, { open: settingsOpen, onOpenChange: setSettingsOpen, children: [_jsxs(Tooltip, { children: [_jsx(TooltipTrigger, { asChild: true, children: _jsx(PopoverAnchor, { asChild: true, children: _jsx(Button, { type: "button", variant: "ghost", size: "icon", disabled: ending, onClick: () => setSettingsOpen((open) => !open), "aria-label": copy.voiceSettings, "aria-expanded": settingsOpen, className: "size-8 rounded-full text-muted-foreground transition-transform duration-150 ease-out active:scale-[0.97]", children: _jsx(IconSettings, {}) }) }) }), _jsx(TooltipContent, { children: copy.voiceSettings })] }), _jsx(PopoverContent, { side: "top", align: "end", sideOffset: 10, className: "w-[min(20rem,calc(100vw-2rem))] overflow-hidden p-0", onOpenAutoFocus: (event) => event.preventDefault(), onInteractOutside: (event) => {
|
|
234
|
+
const target = event.target;
|
|
235
|
+
if (selectInteractionRef.current ||
|
|
236
|
+
(target instanceof Element &&
|
|
237
|
+
target.closest('[data-realtime-voice-setting-options="true"]'))) {
|
|
238
|
+
event.preventDefault();
|
|
239
|
+
}
|
|
240
|
+
}, children: _jsx(VoiceInlineSettings, { settings: settings, disabled: ending, onSelectOpenChange: handleSelectOpenChange }) })] })) : null, _jsxs(Tooltip, { children: [_jsx(TooltipTrigger, { asChild: true, children: _jsx(Button, { type: "button", variant: "ghost", size: "icon", disabled: ending, onClick: onEndVoiceMode, "aria-label": copy.endVoiceMode, className: "size-8 rounded-full text-destructive transition-transform duration-150 ease-out hover:bg-destructive/10 hover:text-destructive active:scale-[0.97]", children: _jsx(IconPhoneOff, {}) }) }), _jsx(TooltipContent, { children: copy.endVoiceMode })] })] }), _jsxs(Tooltip, { children: [_jsx(TooltipTrigger, { asChild: true, children: _jsx(Button, { type: "button", size: "icon", disabled: ending, onClick: () => {
|
|
241
|
+
setControlsOpen(true);
|
|
242
|
+
onToggleChat();
|
|
243
|
+
}, "aria-label": toggleLabel, "aria-pressed": chatVisible, "data-realtime-voice-chat-toggle": "orb", "aria-describedby": statusId, "aria-controls": controlsId, "aria-expanded": controlsVisible, className: cn("relative isolate size-16 overflow-visible rounded-full ring-1 backdrop-blur-xl transition-transform duration-150 ease-out focus-visible:ring-offset-2 active:scale-[0.97] motion-reduce:transition-none", ORB_STATE_CLASSES[state]), children: _jsx("span", { className: "relative z-10 flex items-center justify-center", children: state === "connecting" ? (_jsx(VoiceConnectingIndicator, {})) : state !== "error" ? (_jsx(VoiceWaveform, { level: activityLevel, reducedMotion: reducedMotion, activity: activity })) : (_jsx(IconAlertTriangle, {})) }) }) }), _jsx(TooltipContent, { children: toggleLabel })] })] })] }));
|
|
93
244
|
}
|
|
94
245
|
//# sourceMappingURL=RealtimeVoiceMode.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"RealtimeVoiceMode.js","sourceRoot":"","sources":["../../../src/client/composer/RealtimeVoiceMode.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,iCAAiC,CAAC;AACzD,OAAO,EACL,iBAAiB,EACjB,WAAW,EACX,cAAc,EACd,YAAY,EACZ,UAAU,GACX,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EAAE,SAAS,EAAE,KAAK,EAAE,QAAQ,EAAE,oBAAoB,EAAE,MAAM,OAAO,CAAC;AAEzE,OAAO,EACL,OAAO,EACP,cAAc,EACd,cAAc,GACf,MAAM,6BAA6B,CAAC;AACrC,OAAO,EACL,OAAO,EACP,cAAc,EACd,cAAc,GACf,MAAM,6BAA6B,CAAC;AACrC,OAAO,EAAE,EAAE,EAAE,MAAM,aAAa,CAAC;AACjC,OAAO,EACL,kCAAkC,GAEnC,MAAM,iCAAiC,CAAC;AAsDzC;;;;GAIG;AACH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G,YAEpH,IAAI,CAAC,MAAM,CAAC,KAAK,CAAC,GACf,EAEN,eAAK,SAAS,EAAC,6CAA6C,aAC1D,MAAC,OAAO,eACN,KAAC,cAAc,IAAC,OAAO,kBACrB,KAAC,MAAM,IACL,IAAI,EAAC,QAAQ,EACb,OAAO,EAAC,SAAS,EACjB,IAAI,EAAC,MAAM,EACX,QAAQ,EAAE,MAAM,EAChB,OAAO,EAAE,cAAc,gBACX,IAAI,CAAC,YAAY,EAC7B,SAAS,EAAC,8CAA8C,YAExD,KAAC,YAAY,KAAG,GACT,GACM,EACjB,KAAC,cAAc,cAAE,IAAI,CAAC,YAAY,GAAkB,IAC5C,EAEV,MAAC,OAAO,eACN,KAAC,cAAc,IAAC,OAAO,kBACrB,KAAC,MAAM,IACL,IAAI,EAAC,QAAQ,EACb,IAAI,EAAC,MAAM,EACX,QAAQ,EAAE,MAAM,EAChB,OAAO,EAAE,YAAY,gBACT,WAAW,kBACT,WAAW,sBACP,QAAQ,EAC1B,SAAS,EAAE,EAAE,CACX,gCAAgC,EAChC,iBAAiB,CAAC,KAAK,CAAC,CACzB,YAEA,QAAQ,KAAK,MAAM,CAAC,CAAC,CAAC,CACrB,KAAC,cAAc,IAAC,KAAK,EAAE,KAAK,GAAI,CACjC,CAAC,CAAC,CAAC,CACF,KAAC,aAAa,IACZ,KAAK,EAAE,aAAa,EACpB,aAAa,EAAE,aAAa,GAC5B,CACH,GACM,GACM,EACjB,KAAC,cAAc,cAAE,WAAW,GAAkB,IACtC,IACN,IACF,CACP,CAAC;AACJ,CAAC","sourcesContent":["import { Button } from \"@agent-native/toolkit/ui/button\";\nimport {\n IconAlertTriangle,\n IconLoader2,\n IconMicrophone,\n IconPhoneOff,\n IconVolume,\n} from \"@tabler/icons-react\";\nimport { useEffect, useId, useState, useSyncExternalStore } from \"react\";\n\nimport {\n Popover,\n PopoverContent,\n PopoverTrigger,\n} from \"../components/ui/popover.js\";\nimport {\n Tooltip,\n TooltipContent,\n TooltipTrigger,\n} from \"../components/ui/tooltip.js\";\nimport { cn } from \"../utils.js\";\nimport {\n createRealtimeVoiceAudioLevelStore,\n type RealtimeVoiceAudioLevelStore,\n} from \"./realtime-voice-audio-level.js\";\n\nexport type RealtimeVoiceModeState =\n | \"connecting\"\n | \"listening\"\n | \"speaking\"\n | \"working\"\n | \"error\"\n | \"ending\";\n\n/**\n * User-visible copy stays outside the shared component so host catalogs remain\n * the source of truth. Callers should provide these values through `useT()`.\n */\nexport interface RealtimeVoiceModeCopy {\n entryButtonLabel: string;\n promptTitle: string;\n promptDescription: string;\n setupTitle: string;\n setupDescription: string;\n connectBuilder: string;\n useOpenAiKey: string;\n startWithOpenAiKey: string;\n startVoiceMode: string;\n keepDictating: string;\n showChat: string;\n hideChat: string;\n endVoiceMode: string;\n status: Record<RealtimeVoiceModeState, string>;\n errors: {\n unsupported: string;\n responseFailed: string;\n sessionFailed: string;\n channelDisconnected: string;\n connectionFailed: string;\n offerFailed: string;\n };\n}\n\nexport interface RealtimeVoiceModeEntryProps {\n copy: RealtimeVoiceModeCopy;\n disabled?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n onStartVoiceMode: () => void;\n onKeepDictating: () => void;\n setupRequired?: boolean;\n openAiConfigured?: boolean;\n connectingBuilder?: boolean;\n onConnectBuilder?: () => void;\n onUseOpenAiKey?: () => void;\n className?: string;\n}\n\n/**\n * Composer mic entry point for apps that support a full-duplex voice session.\n * The first click offers voice mode without silently changing the existing\n * editable-dictation behavior.\n */\nexport function RealtimeVoiceModeEntry({\n copy,\n disabled,\n open: controlledOpen,\n onOpenChange,\n onStartVoiceMode,\n onKeepDictating,\n setupRequired = false,\n openAiConfigured = false,\n connectingBuilder = false,\n onConnectBuilder,\n onUseOpenAiKey,\n className,\n}: RealtimeVoiceModeEntryProps) {\n const [uncontrolledOpen, setUncontrolledOpen] = useState(false);\n const open = controlledOpen ?? uncontrolledOpen;\n const titleId = useId();\n const descriptionId = useId();\n\n const setOpen = (nextOpen: boolean) => {\n if (controlledOpen === undefined) setUncontrolledOpen(nextOpen);\n onOpenChange?.(nextOpen);\n };\n\n const choose = (callback: () => void) => {\n setOpen(false);\n callback();\n };\n\n return (\n <Popover open={open} onOpenChange={setOpen}>\n <Tooltip>\n <TooltipTrigger asChild>\n <PopoverTrigger asChild>\n <Button\n type=\"button\"\n variant=\"ghost\"\n size=\"icon\"\n disabled={disabled}\n aria-label={copy.entryButtonLabel}\n aria-expanded={open}\n className={cn(\n \"size-7 shrink-0 text-muted-foreground hover:text-foreground\",\n className,\n )}\n >\n <IconMicrophone />\n </Button>\n </PopoverTrigger>\n </TooltipTrigger>\n <TooltipContent>{copy.entryButtonLabel}</TooltipContent>\n </Tooltip>\n\n <PopoverContent\n side=\"top\"\n align=\"end\"\n sideOffset={10}\n className=\"w-[min(22rem,calc(100vw-2rem))] p-4\"\n aria-labelledby={titleId}\n aria-describedby={descriptionId}\n >\n <div className=\"grid gap-3\">\n <div className=\"grid gap-1\">\n <h2 id={titleId} className=\"text-sm font-semibold text-foreground\">\n {setupRequired ? copy.setupTitle : copy.promptTitle}\n </h2>\n <p\n id={descriptionId}\n className=\"text-sm leading-relaxed text-muted-foreground\"\n >\n {setupRequired ? copy.setupDescription : copy.promptDescription}\n </p>\n </div>\n\n <div className=\"flex flex-col-reverse gap-2 sm:flex-row sm:flex-wrap sm:justify-end\">\n <Button\n type=\"button\"\n variant=\"ghost\"\n size=\"sm\"\n onClick={() => choose(onKeepDictating)}\n >\n {copy.keepDictating}\n </Button>\n {setupRequired ? (\n <>\n <Button\n type=\"button\"\n variant=\"outline\"\n size=\"sm\"\n onClick={() => choose(onUseOpenAiKey ?? onStartVoiceMode)}\n >\n {openAiConfigured\n ? copy.startWithOpenAiKey\n : copy.useOpenAiKey}\n </Button>\n <Button\n type=\"button\"\n size=\"sm\"\n disabled={connectingBuilder}\n onClick={() => choose(onConnectBuilder ?? onStartVoiceMode)}\n >\n {connectingBuilder ? (\n <IconLoader2 className=\"animate-spin\" />\n ) : null}\n {copy.connectBuilder}\n </Button>\n </>\n ) : (\n <Button\n type=\"button\"\n size=\"sm\"\n onClick={() => choose(onStartVoiceMode)}\n >\n <IconMicrophone />\n {copy.startVoiceMode}\n </Button>\n )}\n </div>\n </div>\n </PopoverContent>\n </Popover>\n );\n}\n\nexport interface RealtimeVoiceModeDockProps {\n state: RealtimeVoiceModeState;\n copy: RealtimeVoiceModeCopy;\n chatVisible: boolean;\n audioLevels?: RealtimeVoiceAudioLevelStore;\n onToggleChat: () => void;\n onEndVoiceMode: () => void;\n errorMessage?: string | null;\n className?: string;\n}\n\nconst SILENT_AUDIO_LEVELS = createRealtimeVoiceAudioLevelStore();\nconst WAVEFORM_WEIGHTS = [0.55, 0.82, 1, 0.82, 0.55];\nconst AUDIO_ACTIVITY_THRESHOLD = 0.035;\n\nfunction usePrefersReducedMotion(): boolean {\n const [reduced, setReduced] = useState(false);\n useEffect(() => {\n if (typeof window === \"undefined\" || !window.matchMedia) return;\n const query = window.matchMedia(\"(prefers-reduced-motion: reduce)\");\n const update = () => setReduced(query.matches);\n update();\n query.addEventListener?.(\"change\", update);\n return () => query.removeEventListener?.(\"change\", update);\n }, []);\n return reduced;\n}\n\nfunction VoiceWaveform({\n level,\n reducedMotion,\n}: {\n level: number;\n reducedMotion: boolean;\n}) {\n const visibleLevel = reducedMotion ? 0.45 : level;\n return (\n <span\n aria-hidden=\"true\"\n className=\"flex h-6 items-center justify-center gap-0.5\"\n data-realtime-voice-waveform=\"true\"\n >\n {WAVEFORM_WEIGHTS.map((weight, index) => (\n <span\n key={index}\n className=\"w-0.5 rounded-full bg-current transition-[height] duration-75 ease-out motion-reduce:transition-none\"\n style={{ height: `${4 + visibleLevel * 16 * weight}px` }}\n />\n ))}\n </span>\n );\n}\n\nconst ORB_STATE_CLASSES: Record<RealtimeVoiceModeState, string> = {\n connecting:\n \"bg-secondary text-secondary-foreground ring-4 ring-secondary/40 hover:bg-secondary/80\",\n listening:\n \"bg-primary text-primary-foreground ring-4 ring-primary/15 hover:bg-primary/90\",\n speaking:\n \"bg-foreground text-background ring-4 ring-foreground/15 hover:bg-foreground/90\",\n working:\n \"bg-secondary text-secondary-foreground ring-4 ring-secondary/40 hover:bg-secondary/80\",\n error:\n \"bg-destructive text-destructive-foreground ring-4 ring-destructive/15 hover:bg-destructive/90\",\n ending: \"bg-muted text-muted-foreground ring-4 ring-muted/40 cursor-wait\",\n};\n\nfunction VoiceStateIcon({ state }: { state: RealtimeVoiceModeState }) {\n switch (state) {\n case \"connecting\":\n return (\n <IconLoader2 className=\"animate-spin motion-reduce:animate-none\" />\n );\n case \"listening\":\n return <IconMicrophone />;\n case \"speaking\":\n return <IconVolume />;\n case \"working\":\n case \"ending\":\n return (\n <IconLoader2 className=\"animate-spin motion-reduce:animate-none\" />\n );\n case \"error\":\n return <IconAlertTriangle />;\n }\n}\n\n/**\n * Persistent voice-session control. Toggling the main orb only changes chat\n * visibility; ending the realtime session is intentionally a separate action.\n */\nexport function RealtimeVoiceModeDock({\n state,\n copy,\n chatVisible,\n audioLevels = SILENT_AUDIO_LEVELS,\n onToggleChat,\n onEndVoiceMode,\n errorMessage,\n className,\n}: RealtimeVoiceModeDockProps) {\n const statusId = useId();\n const levels = useSyncExternalStore(\n audioLevels.subscribe,\n audioLevels.getSnapshot,\n audioLevels.getSnapshot,\n );\n const reducedMotion = usePrefersReducedMotion();\n const activity =\n levels.output > AUDIO_ACTIVITY_THRESHOLD\n ? \"assistant\"\n : levels.input > AUDIO_ACTIVITY_THRESHOLD\n ? \"user\"\n : \"idle\";\n const activityLevel = activity === \"assistant\" ? levels.output : levels.input;\n const toggleLabel = chatVisible ? copy.hideChat : copy.showChat;\n const ending = state === \"ending\";\n const errorDetailVisible = state === \"error\" && Boolean(errorMessage);\n\n return (\n <div\n className={cn(\n \"pointer-events-none fixed bottom-4 end-4 flex max-w-[calc(100vw-2rem)] flex-col items-end gap-2\",\n className,\n )}\n style={{ zIndex: 270 }}\n data-realtime-voice-state={state}\n data-realtime-voice-activity={activity}\n >\n {errorDetailVisible ? (\n <div\n role=\"alert\"\n className=\"pointer-events-auto max-w-xs rounded-lg border border-destructive/30 bg-background px-3 py-2 text-sm text-destructive shadow-md\"\n >\n {errorMessage}\n </div>\n ) : null}\n\n <div\n id={statusId}\n role={state === \"error\" && !errorDetailVisible ? \"alert\" : \"status\"}\n aria-live={\n state === \"error\" && !errorDetailVisible ? \"assertive\" : \"polite\"\n }\n className=\"rounded-full border border-border bg-background px-3 py-1.5 text-xs font-medium text-foreground shadow-sm\"\n >\n {copy.status[state]}\n </div>\n\n <div className=\"pointer-events-auto flex items-center gap-2\">\n <Tooltip>\n <TooltipTrigger asChild>\n <Button\n type=\"button\"\n variant=\"outline\"\n size=\"icon\"\n disabled={ending}\n onClick={onEndVoiceMode}\n aria-label={copy.endVoiceMode}\n className=\"size-10 rounded-full bg-background shadow-md\"\n >\n <IconPhoneOff />\n </Button>\n </TooltipTrigger>\n <TooltipContent>{copy.endVoiceMode}</TooltipContent>\n </Tooltip>\n\n <Tooltip>\n <TooltipTrigger asChild>\n <Button\n type=\"button\"\n size=\"icon\"\n disabled={ending}\n onClick={onToggleChat}\n aria-label={toggleLabel}\n aria-pressed={chatVisible}\n aria-describedby={statusId}\n className={cn(\n \"size-14 rounded-full shadow-lg\",\n ORB_STATE_CLASSES[state],\n )}\n >\n {activity === \"idle\" ? (\n <VoiceStateIcon state={state} />\n ) : (\n <VoiceWaveform\n level={activityLevel}\n reducedMotion={reducedMotion}\n />\n )}\n </Button>\n </TooltipTrigger>\n <TooltipContent>{toggleLabel}</TooltipContent>\n </Tooltip>\n </div>\n </div>\n );\n}\n"]}
|
|
1
|
+
{"version":3,"file":"RealtimeVoiceMode.js","sourceRoot":"","sources":["../../../src/client/composer/RealtimeVoiceMode.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,iCAAiC,CAAC;AACzD,OAAO,EACL,MAAM,EACN,aAAa,EACb,WAAW,EACX,UAAU,EACV,aAAa,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E,IAAI,CAAC,YAAY,GAAkB,IAC5C,IACN,EAEN,MAAC,OAAO,eACN,KAAC,cAAc,IAAC,OAAO,kBACrB,KAAC,MAAM,IACL,IAAI,EAAC,QAAQ,EACb,IAAI,EAAC,MAAM,EACX,QAAQ,EAAE,MAAM,EAChB,OAAO,EAAE,GAAG,EAAE;wCACZ,eAAe,CAAC,IAAI,CAAC,CAAC;wCACtB,YAAY,EAAE,CAAC;oCACjB,CAAC,gBACW,WAAW,kBACT,WAAW,qCACO,KAAK,sBACnB,QAAQ,mBACX,UAAU,mBACV,eAAe,EAC9B,SAAS,EAAE,EAAE,CACX,yMAAyM,EACzM,iBAAiB,CAAC,KAAK,CAAC,CACzB,YAED,eAAM,SAAS,EAAC,gDAAgD,YAC7D,KAAK,KAAK,YAAY,CAAC,CAAC,CAAC,CACxB,KAAC,wBAAwB,KAAG,CAC7B,CAAC,CAAC,CAAC,KAAK,KAAK,OAAO,CAAC,CAAC,CAAC,CACtB,KAAC,aAAa,IACZ,KAAK,EAAE,aAAa,EACpB,aAAa,EAAE,aAAa,EAC5B,QAAQ,EAAE,QAAQ,GAClB,CACH,CAAC,CAAC,CAAC,CACF,KAAC,iBAAiB,KAAG,CACtB,GACI,GACA,GACM,EACjB,KAAC,cAAc,cAAE,WAAW,GAAkB,IACtC,IACN,IACF,CACP,CAAC;AACJ,CAAC","sourcesContent":["import { Button } from \"@agent-native/toolkit/ui/button\";\nimport {\n Select,\n SelectContent,\n SelectGroup,\n SelectItem,\n SelectTrigger,\n} from \"@agent-native/toolkit/ui/select\";\nimport {\n IconAlertTriangle,\n IconBrain,\n IconLanguage,\n IconLoader2,\n IconMicrophone,\n IconPhoneOff,\n IconSettings,\n IconVolume,\n} from \"@tabler/icons-react\";\nimport {\n type MouseEvent,\n useCallback,\n useEffect,\n useId,\n useRef,\n useState,\n useSyncExternalStore,\n} from \"react\";\n\nimport {\n Popover,\n PopoverAnchor,\n PopoverContent,\n PopoverTrigger,\n} from \"../components/ui/popover.js\";\nimport {\n Tooltip,\n TooltipContent,\n TooltipTrigger,\n} from \"../components/ui/tooltip.js\";\nimport { cn } from \"../utils.js\";\nimport {\n createRealtimeVoiceAudioLevelStore,\n type RealtimeVoiceAudioLevelStore,\n} from \"./realtime-voice-audio-level.js\";\n\nexport type RealtimeVoiceModeState =\n | \"connecting\"\n | \"listening\"\n | \"speaking\"\n | \"working\"\n | \"error\"\n | \"ending\";\n\n/**\n * User-visible copy stays outside the shared component so host catalogs remain\n * the source of truth. Callers should provide these values through `useT()`.\n */\nexport interface RealtimeVoiceModeCopy {\n entryButtonLabel: string;\n promptTitle: string;\n promptDescription: string;\n setupTitle: string;\n setupDescription: string;\n connectBuilder: string;\n useOpenAiKey: string;\n startWithOpenAiKey: string;\n startVoiceMode: string;\n keepDictating: string;\n showChat: string;\n hideChat: string;\n endVoiceMode: string;\n voiceSettings: string;\n settings: {\n microphone: string;\n defaultMicrophone: string;\n microphoneSwitchFailed: string;\n language: string;\n autoLanguage: string;\n languages: Record<\n Exclude<\n import(\"./useRealtimeVoiceMode.js\").RealtimeVoiceLanguage,\n \"auto\"\n >,\n string\n >;\n intelligence: string;\n intelligenceLevels: Record<\n import(\"./useRealtimeVoiceMode.js\").RealtimeVoiceIntelligence,\n string\n >;\n voiceStyle: string;\n voiceChangePending: string;\n voiceDescriptions: Record<\n import(\"./useRealtimeVoiceMode.js\").RealtimeVoice,\n string\n >;\n };\n status: Record<RealtimeVoiceModeState, string>;\n errors: {\n unsupported: string;\n responseFailed: string;\n sessionFailed: string;\n channelDisconnected: string;\n connectionTimedOut?: string;\n connectionFailed: string;\n offerFailed: string;\n };\n}\n\nexport interface RealtimeVoiceModeEntryProps {\n copy: RealtimeVoiceModeCopy;\n disabled?: boolean;\n providerStatusPending?: boolean;\n open?: boolean;\n onOpenChange?: (open: boolean) => void;\n onStartVoiceMode: () => void;\n onKeepDictating: () => void;\n setupRequired?: boolean;\n openAiConfigured?: boolean;\n connectingBuilder?: boolean;\n onConnectBuilder?: () => void;\n onUseOpenAiKey?: () => void;\n className?: string;\n}\n\n/**\n * Composer mic entry point for apps that support a full-duplex voice session.\n * The first click offers voice mode without silently changing the existing\n * editable-dictation behavior.\n */\nexport function RealtimeVoiceModeEntry({\n copy,\n disabled,\n providerStatusPending = false,\n open: controlledOpen,\n onOpenChange,\n onStartVoiceMode,\n onKeepDictating,\n setupRequired = false,\n openAiConfigured = false,\n connectingBuilder = false,\n onConnectBuilder,\n onUseOpenAiKey,\n className,\n}: RealtimeVoiceModeEntryProps) {\n const [uncontrolledOpen, setUncontrolledOpen] = useState(false);\n const open = controlledOpen ?? uncontrolledOpen;\n const titleId = useId();\n const descriptionId = useId();\n const [collisionBoundary, setCollisionBoundary] =\n useState<HTMLElement | null>(null);\n\n const setTriggerNode = useCallback((node: HTMLButtonElement | null) => {\n const nextBoundary =\n node?.closest<HTMLElement>(\".agent-panel-root\") ?? null;\n setCollisionBoundary((currentBoundary) =>\n currentBoundary === nextBoundary ? currentBoundary : nextBoundary,\n );\n }, []);\n\n const setOpen = (nextOpen: boolean) => {\n if (controlledOpen === undefined) setUncontrolledOpen(nextOpen);\n onOpenChange?.(nextOpen);\n };\n\n const choose = (callback: () => void) => {\n setOpen(false);\n callback();\n };\n\n return (\n <Popover open={open} onOpenChange={setOpen}>\n <Tooltip>\n <TooltipTrigger asChild>\n <PopoverTrigger asChild>\n <Button\n ref={setTriggerNode}\n type=\"button\"\n variant=\"ghost\"\n size=\"icon\"\n disabled={disabled}\n aria-label={copy.entryButtonLabel}\n aria-expanded={open}\n className={cn(\n \"size-7 shrink-0 text-muted-foreground hover:text-foreground\",\n className,\n )}\n >\n <IconMicrophone />\n </Button>\n </PopoverTrigger>\n </TooltipTrigger>\n <TooltipContent>{copy.entryButtonLabel}</TooltipContent>\n </Tooltip>\n\n <PopoverContent\n side=\"top\"\n align=\"end\"\n sideOffset={10}\n collisionBoundary={collisionBoundary ?? undefined}\n collisionPadding={16}\n data-collision-boundary={collisionBoundary ? \"agent-panel\" : \"viewport\"}\n className={cn(\n \"p-4\",\n setupRequired\n ? \"w-[min(calc(100vw-2rem),var(--radix-popover-content-available-width,30rem),30rem)]\"\n : \"w-[min(calc(100vw-2rem),var(--radix-popover-content-available-width,22rem),22rem)]\",\n )}\n aria-labelledby={titleId}\n aria-describedby={descriptionId}\n >\n <div className=\"grid gap-3\">\n <div className=\"grid gap-1\">\n <h2 id={titleId} className=\"text-sm font-semibold text-foreground\">\n {setupRequired ? copy.setupTitle : copy.promptTitle}\n </h2>\n <p\n id={descriptionId}\n className=\"text-sm leading-relaxed text-muted-foreground\"\n >\n {setupRequired ? copy.setupDescription : copy.promptDescription}\n </p>\n </div>\n\n <div className=\"flex flex-col-reverse gap-2 sm:flex-row sm:flex-wrap sm:justify-end\">\n <Button\n type=\"button\"\n variant=\"ghost\"\n size=\"sm\"\n onClick={() => choose(onKeepDictating)}\n >\n {copy.keepDictating}\n </Button>\n {setupRequired ? (\n <>\n <Button\n type=\"button\"\n variant=\"outline\"\n size=\"sm\"\n onClick={() => choose(onUseOpenAiKey ?? onStartVoiceMode)}\n >\n {openAiConfigured\n ? copy.startWithOpenAiKey\n : copy.useOpenAiKey}\n </Button>\n <Button\n type=\"button\"\n size=\"sm\"\n className=\"whitespace-nowrap\"\n disabled={connectingBuilder}\n onClick={() => choose(onConnectBuilder ?? onStartVoiceMode)}\n >\n {connectingBuilder ? (\n <IconLoader2 className=\"animate-spin\" />\n ) : null}\n {copy.connectBuilder}\n </Button>\n </>\n ) : (\n <Button\n type=\"button\"\n size=\"sm\"\n disabled={providerStatusPending}\n onClick={() => choose(onStartVoiceMode)}\n >\n {providerStatusPending ? (\n <IconLoader2 className=\"animate-spin\" />\n ) : (\n <IconMicrophone />\n )}\n {copy.startVoiceMode}\n </Button>\n )}\n </div>\n </div>\n </PopoverContent>\n </Popover>\n );\n}\n\nexport interface RealtimeVoiceModeDockProps {\n state: RealtimeVoiceModeState;\n copy: RealtimeVoiceModeCopy;\n chatVisible: boolean;\n audioLevels?: RealtimeVoiceAudioLevelStore;\n onToggleChat: () => void;\n onEndVoiceMode: () => void;\n settings?: RealtimeVoiceModeInlineSettings;\n errorMessage?: string | null;\n className?: string;\n}\n\nexport interface RealtimeVoiceModeSettingOption {\n value: string;\n label: string;\n description?: string;\n}\n\nexport interface RealtimeVoiceModeSelectSetting {\n label: string;\n value: string;\n options: readonly RealtimeVoiceModeSettingOption[];\n onValueChange: (value: string) => void;\n disabled?: boolean;\n}\n\nexport interface RealtimeVoiceModeInlineSettings {\n dialogLabel: string;\n appliesNextConversationNote?: string;\n microphoneError?: string;\n microphone: RealtimeVoiceModeSelectSetting;\n language: RealtimeVoiceModeSelectSetting;\n intelligence: RealtimeVoiceModeSelectSetting;\n voiceStyle: RealtimeVoiceModeSelectSetting;\n}\n\nconst SILENT_AUDIO_LEVELS = createRealtimeVoiceAudioLevelStore();\nconst WAVEFORM_WEIGHTS = [0.55, 0.82, 1, 0.82, 0.55];\nconst AUDIO_ACTIVITY_THRESHOLD = 0.035;\n\nfunction usePrefersReducedMotion(): boolean {\n const [reduced, setReduced] = useState(false);\n useEffect(() => {\n if (typeof window === \"undefined\" || !window.matchMedia) return;\n const query = window.matchMedia(\"(prefers-reduced-motion: reduce)\");\n const update = () => setReduced(query.matches);\n update();\n query.addEventListener?.(\"change\", update);\n return () => query.removeEventListener?.(\"change\", update);\n }, []);\n return reduced;\n}\n\nfunction VoiceWaveform({\n level,\n reducedMotion,\n activity,\n}: {\n level: number;\n reducedMotion: boolean;\n activity: \"idle\" | \"user\" | \"assistant\";\n}) {\n const visibleLevel = reducedMotion ? 0.45 : level;\n return (\n <span\n aria-hidden=\"true\"\n className=\"flex h-6 items-center justify-center gap-0.5\"\n data-realtime-voice-waveform=\"true\"\n data-realtime-voice-waveform-activity={activity}\n >\n {WAVEFORM_WEIGHTS.map((weight, index) => (\n <span\n key={index}\n className=\"h-5 w-0.5 origin-center rounded-full bg-current transition-transform duration-75 ease-out motion-reduce:transition-none\"\n style={{\n transform: `scaleY(${0.2 + visibleLevel * 0.8 * weight})`,\n }}\n />\n ))}\n </span>\n );\n}\n\nfunction VoiceConnectingIndicator() {\n return (\n <IconLoader2\n aria-hidden=\"true\"\n className=\"size-6 animate-spin motion-reduce:animate-none\"\n data-realtime-voice-connecting-indicator=\"true\"\n />\n );\n}\n\nconst ORB_STATE_CLASSES: Record<RealtimeVoiceModeState, string> = {\n connecting:\n \"bg-background/65 text-foreground ring-border/60 hover:bg-background/75\",\n listening:\n \"bg-background/65 text-foreground ring-border/60 hover:bg-background/75\",\n speaking:\n \"bg-background/65 text-foreground ring-border/60 hover:bg-background/75\",\n working:\n \"bg-background/65 text-foreground ring-border/60 hover:bg-background/75\",\n error:\n \"bg-destructive/20 text-destructive ring-destructive/30 hover:bg-destructive/25\",\n ending: \"cursor-wait bg-background/65 text-muted-foreground ring-border/60\",\n};\n\nfunction useChatPanelTranslation(chatVisible: boolean): number {\n const [translation, setTranslation] = useState(0);\n\n useEffect(() => {\n if (!chatVisible || typeof window === \"undefined\") {\n setTranslation(0);\n return;\n }\n\n const direction = window.getComputedStyle(\n document.documentElement,\n ).direction;\n const inlineEnd = direction === \"rtl\" ? \"left\" : \"right\";\n\n const update = () => {\n const panels = Array.from(\n document.querySelectorAll<HTMLElement>(\n `.agent-sidebar-panel[data-agent-sidebar-position=\"${inlineEnd}\"][data-agent-sidebar-state=\"open\"]`,\n ),\n );\n const panel = panels.find((candidate) => {\n const rect = candidate.getBoundingClientRect();\n return rect.width > 0 && rect.height > 0;\n });\n\n if (!panel) {\n setTranslation(0);\n return;\n }\n\n // A fullscreen chat has no unobscured side to move into. Keep the dock\n // at its normal edge so it stays reachable instead of pinning it to the\n // opposite side of the same overlay.\n if (panel.dataset.agentSidebarLayout === \"fullscreen\") {\n setTranslation(0);\n return;\n }\n\n const rect = panel.getBoundingClientRect();\n const overlap =\n inlineEnd === \"right\"\n ? Math.max(0, window.innerWidth - rect.left)\n : Math.max(0, rect.right);\n const maximumShift = Math.max(0, window.innerWidth - 96);\n const distance = Math.min(overlap, maximumShift);\n setTranslation(inlineEnd === \"right\" ? -distance : distance);\n };\n\n update();\n const frame = window.requestAnimationFrame(update);\n window.addEventListener(\"resize\", update);\n\n const resizeObserver =\n typeof ResizeObserver === \"undefined\" ? null : new ResizeObserver(update);\n const observedPanels = new WeakSet<HTMLElement>();\n const observePanels = () => {\n document\n .querySelectorAll<HTMLElement>(\".agent-sidebar-panel\")\n .forEach((panel) => {\n if (!observedPanels.has(panel)) {\n observedPanels.add(panel);\n resizeObserver?.observe(panel);\n }\n });\n };\n observePanels();\n\n const mutationObserver = new MutationObserver(() => {\n observePanels();\n update();\n });\n mutationObserver.observe(document.body, {\n attributes: true,\n attributeFilter: [\n \"data-agent-sidebar-layout\",\n \"data-agent-sidebar-state\",\n \"style\",\n ],\n childList: true,\n subtree: true,\n });\n\n return () => {\n window.cancelAnimationFrame(frame);\n window.removeEventListener(\"resize\", update);\n resizeObserver?.disconnect();\n mutationObserver.disconnect();\n };\n }, [chatVisible]);\n\n return translation;\n}\n\nfunction VoiceSettingRow({\n icon: Icon,\n setting,\n onSelectOpenChange,\n}: {\n icon: typeof IconLanguage;\n setting: RealtimeVoiceModeSelectSetting;\n onSelectOpenChange: (open: boolean) => void;\n}) {\n const selected = setting.options.find(\n (option) => option.value === setting.value,\n );\n\n return (\n <Select\n value={setting.value}\n onValueChange={setting.onValueChange}\n onOpenChange={onSelectOpenChange}\n disabled={setting.disabled}\n >\n <SelectTrigger\n aria-label={`${setting.label}: ${selected?.label ?? setting.value}`}\n className=\"h-11 rounded-none border-0 bg-transparent px-3 shadow-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-inset\"\n >\n <div className=\"flex min-w-0 flex-1 items-center gap-2.5\">\n <Icon className=\"size-4 shrink-0 text-muted-foreground\" />\n <span className=\"shrink-0 text-sm font-medium text-foreground\">\n {setting.label}\n </span>\n <span className=\"ms-auto min-w-0 truncate text-end text-sm text-muted-foreground\">\n {selected?.label ?? setting.value}\n </span>\n </div>\n </SelectTrigger>\n <SelectContent\n align=\"end\"\n className=\"min-w-56\"\n data-realtime-voice-setting-options=\"true\"\n >\n <SelectGroup>\n {setting.options.map((option) => (\n <SelectItem key={option.value} value={option.value}>\n <span className=\"grid gap-0.5\">\n <span>{option.label}</span>\n {option.description ? (\n <span className=\"text-xs text-muted-foreground\">\n {option.description}\n </span>\n ) : null}\n </span>\n </SelectItem>\n ))}\n </SelectGroup>\n </SelectContent>\n </Select>\n );\n}\n\nfunction VoiceInlineSettings({\n settings,\n disabled,\n onSelectOpenChange,\n}: {\n settings: RealtimeVoiceModeInlineSettings;\n disabled: boolean;\n onSelectOpenChange: (open: boolean) => void;\n}) {\n const selectedVoice = settings.voiceStyle.options.find(\n (option) => option.value === settings.voiceStyle.value,\n );\n\n return (\n <div data-realtime-voice-settings=\"true\">\n <h2 className=\"sr-only\">{settings.dialogLabel}</h2>\n <div className=\"grid gap-0.5 px-4 pb-3 pt-4 text-center\">\n <div className=\"truncate text-base font-semibold text-foreground\">\n {selectedVoice?.label ?? settings.voiceStyle.value}\n </div>\n {selectedVoice?.description ? (\n <div className=\"truncate text-xs text-muted-foreground\">\n {selectedVoice.description}\n </div>\n ) : null}\n </div>\n <div className=\"mx-2 mb-2 overflow-hidden rounded-xl border border-border/70 bg-background/70\">\n <VoiceSettingRow\n icon={IconMicrophone}\n setting={{\n ...settings.microphone,\n disabled: disabled || settings.microphone.disabled,\n }}\n onSelectOpenChange={onSelectOpenChange}\n />\n <div className=\"mx-3 h-px bg-border/70\" />\n <VoiceSettingRow\n icon={IconLanguage}\n setting={{\n ...settings.language,\n disabled: disabled || settings.language.disabled,\n }}\n onSelectOpenChange={onSelectOpenChange}\n />\n <div className=\"mx-3 h-px bg-border/70\" />\n <VoiceSettingRow\n icon={IconBrain}\n setting={{\n ...settings.intelligence,\n disabled: disabled || settings.intelligence.disabled,\n }}\n onSelectOpenChange={onSelectOpenChange}\n />\n <div className=\"mx-3 h-px bg-border/70\" />\n <VoiceSettingRow\n icon={IconVolume}\n setting={{\n ...settings.voiceStyle,\n disabled: disabled || settings.voiceStyle.disabled,\n }}\n onSelectOpenChange={onSelectOpenChange}\n />\n </div>\n {settings.microphoneError ? (\n <p className=\"px-4 pb-3 text-center text-xs text-destructive\">\n {settings.microphoneError}\n </p>\n ) : null}\n {settings.appliesNextConversationNote ? (\n <p className=\"px-4 pb-3 text-center text-xs text-muted-foreground\">\n {settings.appliesNextConversationNote}\n </p>\n ) : null}\n </div>\n );\n}\n\n/**\n * Persistent voice-session control. Toggling the main orb only changes chat\n * visibility; ending the realtime session is intentionally a separate action.\n */\nexport function RealtimeVoiceModeDock({\n state,\n copy,\n chatVisible,\n audioLevels = SILENT_AUDIO_LEVELS,\n onToggleChat,\n onEndVoiceMode,\n settings,\n errorMessage,\n className,\n}: RealtimeVoiceModeDockProps) {\n const statusId = useId();\n const controlsId = useId();\n const [controlsOpen, setControlsOpen] = useState(false);\n const [settingsOpen, setSettingsOpen] = useState(false);\n const selectInteractionRef = useRef(false);\n const selectInteractionFrameRef = useRef<number | null>(null);\n const levels = useSyncExternalStore(\n audioLevels.subscribe,\n audioLevels.getSnapshot,\n audioLevels.getSnapshot,\n );\n const reducedMotion = usePrefersReducedMotion();\n // Microphone metering begins while the SDP request is still in flight. Keep\n // the connecting affordance authoritative until WebRTC is established;\n // otherwise speaking into the mic replaces the loader with a waveform and\n // makes a stalled connection look like a live call.\n const connected =\n state === \"listening\" || state === \"speaking\" || state === \"working\";\n const activity = connected\n ? levels.output > AUDIO_ACTIVITY_THRESHOLD\n ? \"assistant\"\n : levels.input > AUDIO_ACTIVITY_THRESHOLD\n ? \"user\"\n : \"idle\"\n : \"idle\";\n const activityLevel = activity === \"assistant\" ? levels.output : levels.input;\n const toggleLabel = chatVisible ? copy.hideChat : copy.showChat;\n const ending = state === \"ending\";\n const errorDetailVisible = state === \"error\" && Boolean(errorMessage);\n const controlsVisible = controlsOpen || settingsOpen;\n const chatPanelTranslation = useChatPanelTranslation(chatVisible);\n\n const handleSelectOpenChange = useCallback((open: boolean) => {\n if (selectInteractionFrameRef.current !== null) {\n window.cancelAnimationFrame(selectInteractionFrameRef.current);\n selectInteractionFrameRef.current = null;\n }\n selectInteractionRef.current = true;\n if (!open) {\n // Radix closes the portalled Select before its focus/outside events have\n // fully settled. Keep the parent protected through the current frame.\n selectInteractionFrameRef.current = window.requestAnimationFrame(() => {\n selectInteractionRef.current = false;\n selectInteractionFrameRef.current = null;\n });\n }\n }, []);\n\n useEffect(\n () => () => {\n if (selectInteractionFrameRef.current !== null) {\n window.cancelAnimationFrame(selectInteractionFrameRef.current);\n }\n },\n [],\n );\n\n const closeControlsUnlessFocused = (event: MouseEvent<HTMLDivElement>) => {\n if (settingsOpen) return;\n if (!event.currentTarget.contains(document.activeElement)) {\n setControlsOpen(false);\n }\n };\n\n return (\n <div\n className={cn(\n \"pointer-events-none fixed bottom-4 end-4 flex max-w-[calc(100vw-2rem)] flex-col items-end gap-2 transition-transform duration-200 ease-[var(--ease-collapse)] motion-reduce:transition-none\",\n className,\n )}\n style={{\n zIndex: 270,\n transform: `translateX(${chatPanelTranslation}px)`,\n }}\n data-realtime-voice-state={state}\n data-realtime-voice-activity={activity}\n data-realtime-voice-chat-offset={chatPanelTranslation}\n >\n {errorDetailVisible ? (\n <div\n role=\"alert\"\n className=\"pointer-events-auto max-w-xs rounded-lg border border-destructive/30 bg-background px-3 py-2 text-sm text-destructive shadow-md\"\n >\n {errorMessage}\n </div>\n ) : null}\n\n <div\n className=\"group pointer-events-auto flex items-center gap-2\"\n onMouseEnter={() => setControlsOpen(true)}\n onMouseLeave={closeControlsUnlessFocused}\n onFocusCapture={() => setControlsOpen(true)}\n onBlurCapture={(event) => {\n if (\n !event.currentTarget.contains(event.relatedTarget as Node | null)\n ) {\n setControlsOpen(false);\n }\n }}\n >\n <div\n id={controlsId}\n data-realtime-voice-controls={controlsVisible ? \"open\" : \"closed\"}\n className={cn(\n \"flex items-center gap-1 rounded-full border border-border/70 bg-background/95 p-1 shadow-lg backdrop-blur-md transition-[transform,opacity] duration-150 ease-out motion-reduce:transition-none\",\n controlsVisible\n ? \"pointer-events-auto translate-x-0 opacity-100\"\n : \"pointer-events-none opacity-0 ltr:translate-x-2 rtl:-translate-x-2 group-hover:pointer-events-auto group-hover:translate-x-0 group-hover:opacity-100 group-focus-within:pointer-events-auto group-focus-within:translate-x-0 group-focus-within:opacity-100\",\n )}\n >\n <span\n id={statusId}\n role={state === \"error\" && !errorDetailVisible ? \"alert\" : \"status\"}\n aria-live={\n state === \"error\" && !errorDetailVisible ? \"assertive\" : \"polite\"\n }\n className=\"sr-only\"\n >\n {copy.status[state]}\n </span>\n\n {settings ? (\n <Popover open={settingsOpen} onOpenChange={setSettingsOpen}>\n <Tooltip>\n <TooltipTrigger asChild>\n <PopoverAnchor asChild>\n <Button\n type=\"button\"\n variant=\"ghost\"\n size=\"icon\"\n disabled={ending}\n onClick={() => setSettingsOpen((open) => !open)}\n aria-label={copy.voiceSettings}\n aria-expanded={settingsOpen}\n className=\"size-8 rounded-full text-muted-foreground transition-transform duration-150 ease-out active:scale-[0.97]\"\n >\n <IconSettings />\n </Button>\n </PopoverAnchor>\n </TooltipTrigger>\n <TooltipContent>{copy.voiceSettings}</TooltipContent>\n </Tooltip>\n <PopoverContent\n side=\"top\"\n align=\"end\"\n sideOffset={10}\n className=\"w-[min(20rem,calc(100vw-2rem))] overflow-hidden p-0\"\n onOpenAutoFocus={(event) => event.preventDefault()}\n onInteractOutside={(event) => {\n const target = event.target;\n if (\n selectInteractionRef.current ||\n (target instanceof Element &&\n target.closest(\n '[data-realtime-voice-setting-options=\"true\"]',\n ))\n ) {\n event.preventDefault();\n }\n }}\n >\n <VoiceInlineSettings\n settings={settings}\n disabled={ending}\n onSelectOpenChange={handleSelectOpenChange}\n />\n </PopoverContent>\n </Popover>\n ) : null}\n\n <Tooltip>\n <TooltipTrigger asChild>\n <Button\n type=\"button\"\n variant=\"ghost\"\n size=\"icon\"\n disabled={ending}\n onClick={onEndVoiceMode}\n aria-label={copy.endVoiceMode}\n className=\"size-8 rounded-full text-destructive transition-transform duration-150 ease-out hover:bg-destructive/10 hover:text-destructive active:scale-[0.97]\"\n >\n <IconPhoneOff />\n </Button>\n </TooltipTrigger>\n <TooltipContent>{copy.endVoiceMode}</TooltipContent>\n </Tooltip>\n </div>\n\n <Tooltip>\n <TooltipTrigger asChild>\n <Button\n type=\"button\"\n size=\"icon\"\n disabled={ending}\n onClick={() => {\n setControlsOpen(true);\n onToggleChat();\n }}\n aria-label={toggleLabel}\n aria-pressed={chatVisible}\n data-realtime-voice-chat-toggle=\"orb\"\n aria-describedby={statusId}\n aria-controls={controlsId}\n aria-expanded={controlsVisible}\n className={cn(\n \"relative isolate size-16 overflow-visible rounded-full ring-1 backdrop-blur-xl transition-transform duration-150 ease-out focus-visible:ring-offset-2 active:scale-[0.97] motion-reduce:transition-none\",\n ORB_STATE_CLASSES[state],\n )}\n >\n <span className=\"relative z-10 flex items-center justify-center\">\n {state === \"connecting\" ? (\n <VoiceConnectingIndicator />\n ) : state !== \"error\" ? (\n <VoiceWaveform\n level={activityLevel}\n reducedMotion={reducedMotion}\n activity={activity}\n />\n ) : (\n <IconAlertTriangle />\n )}\n </span>\n </Button>\n </TooltipTrigger>\n <TooltipContent>{toggleLabel}</TooltipContent>\n </Tooltip>\n </div>\n </div>\n );\n}\n"]}
|
|
@@ -173,6 +173,10 @@ export interface TiptapComposerProps {
|
|
|
173
173
|
*/
|
|
174
174
|
onAttachmentError?: (message: string) => void;
|
|
175
175
|
}
|
|
176
|
+
/** Tiptap keeps the Editor object truthy after destroy but clears commandManager. */
|
|
177
|
+
export declare function isComposerEditorUsable<T extends {
|
|
178
|
+
isDestroyed?: boolean;
|
|
179
|
+
}>(editor: T | null | undefined): editor is T;
|
|
176
180
|
export declare function createTiptapComposerExtensions(getPlaceholder: () => string | undefined): (import("@tiptap/core").Extension<import("@tiptap/extension-placeholder").PlaceholderOptions, any> | import("@tiptap/core").Extension<import("@tiptap/starter-kit").StarterKitOptions, any> | import("@tiptap/core").Node<any, any>)[];
|
|
177
181
|
export declare const MODEL_SELECTOR_POPOVER_STYLE: {
|
|
178
182
|
fontSize: number;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TiptapComposer.d.ts","sourceRoot":"","sources":["../../../src/client/composer/TiptapComposer.tsx"],"names":[],"mappings":"AAgBA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAGlD,OAAO,KAON,MAAM,OAAO,CAAC;AAEf,OAAO,EAKL,KAAK,eAAe,EACrB,MAAM,kCAAkC,CAAC;AAE1C,OAAO,EACL,sBAAsB,EAItB,KAAK,oBAAoB,EAI1B,MAAM,kBAAkB,CAAC;AA0B1B,OAAO,KAAK,EAEV,WAAW,EACX,SAAS,EACT,YAAY,EAEZ,0BAA0B,EAC3B,MAAM,YAAY,CAAC;AAMpB,MAAM,WAAW,oBAAoB;IACnC,KAAK,IAAI,IAAI,CAAC;IACd,OAAO,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI,CAAC;IAC5B,eAAe,CAAC,GAAG,EAAE,sBAAsB,GAAG,IAAI,CAAC;CACpD;AAED,MAAM,MAAM,oBAAoB,GAAG,WAAW,GAAG,QAAQ,CAAC;AAE1D,eAAO,MAAM,+BAA+B,QAAQ,CAAC;AAErD,MAAM,WAAW,2BAA2B;IAC1C,MAAM,CAAC,EAAE,oBAAoB,CAAC;CAC/B;AAED,wBAAgB,wBAAwB,CAAC,OAAO,EAAE;IAChD,gBAAgB,EAAE,OAAO,CAAC;IAC1B,eAAe,EAAE,MAAM,CAAC;IACxB,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB,GAAG,OAAO,CAKV;AAED,wBAAgB,4BAA4B,CAAC,OAAO,EAAE;IACpD,SAAS,EAAE,OAAO,CAAC;IACnB,aAAa,EAAE,OAAO,CAAC;CACxB,GAAG,MAAM,GAAG,MAAM,CAElB;AAED,MAAM,MAAM,0BAA0B,G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C,QAAgB,EAChB,QAAQ,EACR,WAAW,EACX,cAAc,EACd,QAAQ,EACR,cAAc,EACd,aAAoB,EACpB,YAAY,EACZ,YAAY,EACZ,iBAAiB,EACjB,UAAU,EACV,YAAY,EACZ,WAAW,EACX,WAAW,EACX,aAAyB,EACzB,aAAkB,EAClB,WAAgB,EAChB,2BAAkC,EAClC,yBAAgC,EAChC,cAAc,EACd,QAAQ,EACR,gBAAgB,EAChB,gBAAwB,EACxB,sBAAsB,EACtB,YAA8C,EAC9C,aAAa,EACb,cAAc,EACd,eAAe,EACf,aAAa,EACb,cAAc,EACd,4BAA4B,EAC5B,iBAAiB,EACjB,cAAc,EACd,UAAU,EACV,YAAiB,EACjB,mBAAmB,EACnB,YAAqB,EACrB,gCAAwC,EACxC,iBAAiB,GAClB,EAAE,mBAAmB,
|
|
1
|
+
{"version":3,"file":"TiptapComposer.d.ts","sourceRoot":"","sources":["../../../src/client/composer/TiptapComposer.tsx"],"names":[],"mappings":"AAgBA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAGlD,OAAO,KAON,MAAM,OAAO,CAAC;AAEf,OAAO,EAKL,KAAK,eAAe,EACrB,MAAM,kCAAkC,CAAC;AAE1C,OAAO,EACL,sBAAsB,EAItB,KAAK,oBAAoB,EAI1B,MAAM,kBAAkB,CAAC;AA0B1B,OAAO,KAAK,EAEV,WAAW,EACX,SAAS,EACT,YAAY,EAEZ,0BAA0B,EAC3B,MAAM,YAAY,CAAC;AAMpB,MAAM,WAAW,oBAAoB;IACnC,KAAK,IAAI,IAAI,CAAC;IACd,OAAO,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI,CAAC;IAC5B,eAAe,CAAC,GAAG,EAAE,sBAAsB,GAAG,IAAI,CAAC;CACpD;AAED,MAAM,MAAM,oBAAoB,GAAG,WAAW,GAAG,QAAQ,CAAC;AAE1D,eAAO,MAAM,+BAA+B,QAAQ,CAAC;AAErD,MAAM,WAAW,2BAA2B;IAC1C,M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