@agent-native/core 0.79.27 → 0.80.0
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 +26 -0
- package/corpus/core/docs/content/locales/ar-SA/template-design.mdx +41 -0
- package/corpus/core/docs/content/locales/de-DE/template-design.mdx +51 -0
- package/corpus/core/docs/content/locales/es-ES/template-design.mdx +50 -0
- package/corpus/core/docs/content/locales/fr-FR/template-design.mdx +49 -0
- package/corpus/core/docs/content/locales/hi-IN/template-design.mdx +44 -0
- package/corpus/core/docs/content/locales/ja-JP/template-design.mdx +46 -0
- package/corpus/core/docs/content/locales/ko-KR/template-design.mdx +44 -0
- package/corpus/core/docs/content/locales/pt-BR/template-design.mdx +48 -0
- package/corpus/core/docs/content/locales/zh-CN/template-design.mdx +36 -0
- package/corpus/core/docs/content/locales/zh-TW/template-design.mdx +38 -0
- package/corpus/core/docs/content/template-design.mdx +45 -0
- package/corpus/core/package.json +2 -1
- package/corpus/core/src/agent/engine/index.ts +1 -0
- package/corpus/core/src/agent/engine/registry.ts +40 -0
- package/corpus/core/src/agent/production-agent.ts +6 -2
- package/corpus/core/src/cli/design-connect.ts +490 -0
- package/corpus/core/src/cli/index.ts +16 -0
- package/corpus/core/src/cli/skills.ts +126 -3
- package/corpus/core/src/client/AssistantChat.tsx +43 -7
- package/corpus/core/src/client/agent-chat.ts +27 -3
- package/corpus/core/src/client/blocks/library/MermaidBlock.tsx +1 -1
- package/corpus/core/src/client/blocks/library/diagram.tsx +2 -2
- package/corpus/core/src/client/blocks/library/wireframe.tsx +1 -1
- package/corpus/core/src/client/chat/message-components.tsx +1 -1
- package/corpus/core/src/client/chat-model-groups.ts +1 -2
- package/corpus/core/src/client/components/LiveCursorOverlay.tsx +33 -66
- package/corpus/core/src/client/composer/TiptapComposer.tsx +99 -24
- package/corpus/core/src/client/composer/useVoiceDictation.ts +429 -260
- package/corpus/core/src/client/frame-protocol.ts +17 -2
- package/corpus/core/src/client/rich-markdown-editor/RegistryBlockNode.tsx +2 -2
- package/corpus/core/src/client/sharing/ShareButton.tsx +20 -15
- package/corpus/core/src/client/use-agent-engine-configured.ts +80 -28
- package/corpus/core/src/server/transcribe-voice.ts +57 -22
- package/corpus/core/src/shared/mcp-embed-headers.ts +23 -1
- package/corpus/core/src/styles/agent-native.css +56 -7
- package/corpus/core/src/templates/workspace-core/.agents/skills/voice-transcription/SKILL.md +10 -0
- package/corpus/core/src/vite/client.ts +2 -0
- package/corpus/core/src/voice/index.ts +18 -0
- package/corpus/core/src/voice/voice-cleanup-prompt.ts +38 -0
- package/corpus/core/src/voice/voice-context.ts +217 -0
- package/corpus/core/src/voice/voice-replacements.ts +75 -0
- package/corpus/templates/analytics/AGENTS.md +4 -3
- package/corpus/templates/analytics/actions/list-session-recordings.ts +6 -1
- package/corpus/templates/analytics/app/components/layout/Sidebar.tsx +557 -400
- package/corpus/templates/analytics/app/global.css +0 -4
- package/corpus/templates/analytics/app/i18n/zh-TW.ts +2 -0
- package/corpus/templates/analytics/app/i18n-data.ts +20 -0
- package/corpus/templates/analytics/app/pages/adhoc/sql-dashboard/index.tsx +33 -8
- package/corpus/templates/analytics/app/pages/sessions/SessionDetailPage.tsx +7 -0
- package/corpus/templates/analytics/app/pages/sessions/SessionsPage.tsx +7 -0
- package/corpus/templates/analytics/changelog/2026-06-28-ask-tab-now-matches-the-darker-app-background.md +6 -0
- package/corpus/templates/analytics/changelog/2026-06-28-dashboard-email-reports-now-use-cleaner-light-mode-snapshots.md +6 -0
- package/corpus/templates/analytics/changelog/2026-06-28-left-sidebar-collapses-into-an-animated-icon-rail.md +6 -0
- package/corpus/templates/analytics/changelog/2026-06-28-sessions-now-show-only-signed-in-recordings-with-playable-re.md +6 -0
- package/corpus/templates/analytics/seeds/dashboards/agent-native-templates-first-party.json +3 -3
- package/corpus/templates/analytics/server/lib/dashboard-report.ts +29 -7
- package/corpus/templates/analytics/server/lib/first-party-metric-catalog.ts +5 -2
- package/corpus/templates/analytics/server/lib/session-replay.ts +24 -4
- package/corpus/templates/assets/app/components/layout/Sidebar.tsx +4 -4
- package/corpus/templates/assets/changelog/2026-06-28-left-sidebar-collapse-motion-and-footer-chrome-are-quieter.md +6 -0
- package/corpus/templates/brain/app/components/layout/Layout.tsx +29 -2
- package/corpus/templates/brain/app/components/layout/Sidebar.tsx +131 -42
- package/corpus/templates/brain/app/i18n/zh-TW.ts +2 -0
- package/corpus/templates/brain/app/i18n-data.ts +20 -0
- package/corpus/templates/brain/changelog/2026-06-28-left-sidebar-collapses-into-an-animated-icon-rail.md +6 -0
- package/corpus/templates/calendar/app/components/layout/AppLayout.tsx +29 -1
- package/corpus/templates/calendar/app/components/layout/Sidebar.tsx +417 -299
- 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/changelog/2026-06-28-left-sidebar-collapses-into-an-animated-icon-rail.md +6 -0
- package/corpus/templates/chat/app/components/layout/Sidebar.tsx +6 -19
- package/corpus/templates/chat/changelog/2026-06-28-left-sidebar-collapse-motion-and-footer-chrome-are-quieter.md +6 -0
- package/corpus/templates/clips/AGENTS.md +4 -0
- package/corpus/templates/clips/actions/cleanup-transcript.ts +39 -9
- package/corpus/templates/clips/actions/finalize-meeting.ts +81 -12
- package/corpus/templates/clips/actions/lib/agents-md-context.ts +4 -1
- package/corpus/templates/clips/app/components/library/library-layout.tsx +3 -3
- package/corpus/templates/clips/app/components/meetings/share-meeting-dialog.tsx +1 -1
- package/corpus/templates/clips/app/components/player/share-dialog.tsx +2 -2
- package/corpus/templates/clips/changelog/2026-06-28-left-sidebar-footer-controls-use-less-divider-chrome.md +6 -0
- package/corpus/templates/clips/desktop/src/lib/personal-vocabulary.ts +13 -8
- package/corpus/templates/clips/desktop/src/lib/voice-dictation.ts +60 -1
- package/corpus/templates/content/app/components/editor/DocumentDatabase.tsx +1 -1
- package/corpus/templates/content/app/components/editor/database/DatabaseView.tsx +1 -1
- package/corpus/templates/content/app/components/sidebar/DocumentSidebar.tsx +5 -5
- package/corpus/templates/content/changelog/2026-06-28-left-sidebar-collapse-motion-and-footer-chrome-are-quieter.md +6 -0
- package/corpus/templates/design/.agents/skills/visual-edit/SKILL.md +137 -0
- package/corpus/templates/design/AGENTS.md +95 -5
- package/corpus/templates/design/DESIGN.md +82 -0
- package/corpus/templates/design/DEVELOPING.md +43 -0
- package/corpus/templates/design/actions/add-localhost-screens.ts +426 -0
- package/corpus/templates/design/actions/apply-shader.ts +277 -0
- package/corpus/templates/design/actions/apply-visual-edit.ts +303 -0
- package/corpus/templates/design/actions/connect-localhost.ts +183 -0
- package/corpus/templates/design/actions/edit-design.ts +195 -42
- package/corpus/templates/design/actions/generate-design.ts +71 -1
- package/corpus/templates/design/actions/generate-screens.ts +193 -0
- package/corpus/templates/design/actions/get-code-layer-projection.ts +191 -0
- package/corpus/templates/design/actions/get-shader.ts +119 -0
- package/corpus/templates/design/actions/list-localhost-connections.ts +95 -0
- package/corpus/templates/design/actions/navigate.ts +55 -2
- package/corpus/templates/design/actions/view-screen.ts +68 -1
- package/corpus/templates/design/agent-native.app-skill.json +10 -0
- package/corpus/templates/design/app/components/design/CanvasContextMenu.tsx +761 -0
- package/corpus/templates/design/app/components/design/DesignCanvas.tsx +2057 -103
- package/corpus/templates/design/app/components/design/DesignEditorSkeleton.tsx +74 -38
- package/corpus/templates/design/app/components/design/DesignExtensionsPanel.tsx +399 -0
- package/corpus/templates/design/app/components/design/EditPanel.tsx +3185 -439
- package/corpus/templates/design/app/components/design/LayersPanel.tsx +1124 -0
- package/corpus/templates/design/app/components/design/MultiScreenCanvas.tsx +3116 -147
- package/corpus/templates/design/app/components/design/QuestionFlow.tsx +700 -13
- package/corpus/templates/design/app/components/design/TweaksPanel.tsx +107 -63
- package/corpus/templates/design/app/components/design/index.ts +0 -5
- package/corpus/templates/design/app/components/design/inspector/AlignmentMatrix.tsx +286 -0
- package/corpus/templates/design/app/components/design/inspector/AutoLayoutMatrix.tsx +699 -0
- package/corpus/templates/design/app/components/design/inspector/ConstraintsWidget.tsx +461 -0
- package/corpus/templates/design/app/components/design/inspector/ExportSettingsPanel.tsx +166 -0
- package/corpus/templates/design/app/components/design/inspector/FigmaColorPicker.tsx +1420 -0
- package/corpus/templates/design/app/components/design/inspector/SHADER_INTEGRATION.md +420 -0
- package/corpus/templates/design/app/components/design/inspector/ScrubInput.tsx +215 -0
- package/corpus/templates/design/app/components/design/inspector/ShaderControls.stories.tsx +71 -0
- package/corpus/templates/design/app/components/design/inspector/ShaderControls.tsx +518 -0
- package/corpus/templates/design/app/components/design/inspector/ShaderEffectRow.tsx +106 -0
- package/corpus/templates/design/app/components/design/inspector/figma-icons.tsx +361 -0
- package/corpus/templates/design/app/components/design/inspector/index.ts +60 -0
- package/corpus/templates/design/app/components/design/inspector/scrub-input-utils.ts +201 -0
- package/corpus/templates/design/app/components/design/types.ts +23 -0
- package/corpus/templates/design/app/components/layout/Layout.tsx +24 -13
- package/corpus/templates/design/app/components/layout/Sidebar.tsx +4 -4
- package/corpus/templates/design/app/components/visual-editor/CanvasCommentPins.tsx +474 -36
- package/corpus/templates/design/app/components/visual-editor/DrawOverlay.tsx +22 -5
- package/corpus/templates/design/app/components/visual-editor/SaveStatusIndicator.tsx +24 -11
- package/corpus/templates/design/app/global.css +121 -3
- package/corpus/templates/design/app/hooks/use-agent-generating.ts +4 -0
- package/corpus/templates/design/app/hooks/use-navigation-state.ts +130 -8
- package/corpus/templates/design/app/hooks/useDesignHotkeys.ts +329 -0
- package/corpus/templates/design/app/i18n/zh-TW.ts +264 -0
- package/corpus/templates/design/app/i18n-data.ts +2790 -1
- package/corpus/templates/design/app/pages/DesignEditor.tsx +5108 -851
- package/corpus/templates/design/changelog/2026-06-28-annotate-mode-now-combines-drawing-and-comment-pins-in-one-c.md +6 -0
- package/corpus/templates/design/changelog/2026-06-28-design-editor-panel-borders-are-cleaner-so-the-canvas-edge-s.md +6 -0
- package/corpus/templates/design/changelog/2026-06-28-drawing-prompts-now-reliably-open-and-submit-to-the-design-a.md +6 -0
- package/corpus/templates/design/changelog/2026-06-28-editor-app-menus-now-use-an-outline-agent-native-mark-with-b.md +6 -0
- package/corpus/templates/design/changelog/2026-06-28-figma-style-code-design-mode.md +6 -0
- package/corpus/templates/design/changelog/2026-06-28-layer-selection-now-updates-chat-context-without-opening-the.md +6 -0
- package/corpus/templates/design/changelog/2026-06-28-layer-selections-now-preserve-hidden-and-locked-canvas-state.md +6 -0
- package/corpus/templates/design/changelog/2026-06-28-left-sidebar-collapse-motion-and-footer-chrome-are-quieter.md +6 -0
- package/corpus/templates/design/changelog/2026-06-28-live-cursors-now-keep-names-beside-a-cleaner-pointer-marker.md +6 -0
- package/corpus/templates/design/changelog/2026-06-28-mode-switching-now-lives-in-a-compact-bottom-right-icon-dock.md +6 -0
- package/corpus/templates/design/changelog/2026-06-28-screen-overview-now-handles-zooming-drawing-opening-and-dele.md +6 -0
- package/corpus/templates/design/changelog/2026-06-28-screen-overview-now-selects-screens-on-click-and-opens-them-.md +6 -0
- package/corpus/templates/design/changelog/2026-06-28-screen-overview-zooms-into-the-active-screen-with-smoother-e.md +6 -0
- package/corpus/templates/design/changelog/2026-06-28-selected-element-chips-in-chat-are-shorter-and-easier-to-sca.md +6 -0
- package/corpus/templates/design/changelog/2026-06-28-the-design-editor-toolbar-is-more-compact-and-the-app-menu-m.md +6 -0
- package/corpus/templates/design/changelog/2026-06-28-tweaks-now-live-at-the-top-of-the-design-sidebar-instead-of-.md +6 -0
- package/corpus/templates/design/changelog/2026-06-28-tweaks-now-live-in-the-right-inspector-beside-the-design-tab.md +6 -0
- package/corpus/templates/design/changelog/2026-06-29-active-sidebar-rows-use-soft-highlights.md +6 -0
- package/corpus/templates/design/changelog/2026-06-29-agents-can-now-open-screen-overview-focus-screens-and-add.md +6 -0
- package/corpus/templates/design/changelog/2026-06-29-design-agents-now-edit-broad-copy-changes-more-reliably.md +6 -0
- package/corpus/templates/design/changelog/2026-06-29-design-editor-extensions-now-run-inline-beside-the-artboard.md +6 -0
- package/corpus/templates/design/changelog/2026-06-29-sidebars-use-darker-chrome-and-chat-warns-immediately.md +6 -0
- package/corpus/templates/design/changelog/2026-06-29-visual-edit-can-open-localhost-routes-as-url-backed-screens.md +6 -0
- package/corpus/templates/design/package.json +1 -0
- package/corpus/templates/design/server/db/schema.ts +26 -0
- package/corpus/templates/design/server/lib/design-snapshot.ts +1 -1
- package/corpus/templates/design/server/plugins/agent-chat.ts +3 -0
- package/corpus/templates/design/shared/api.ts +27 -0
- package/corpus/templates/design/shared/canvas-frames.ts +103 -0
- package/corpus/templates/design/shared/canvas-math.ts +1058 -0
- package/corpus/templates/design/shared/code-layer.ts +2212 -0
- package/corpus/templates/design/shared/color-utils.ts +180 -0
- package/corpus/templates/design/shared/generation-session.ts +61 -0
- package/corpus/templates/design/shared/shader-presets.ts +782 -0
- package/corpus/templates/design/shared/shader-safety.ts +137 -0
- package/corpus/templates/design/shared/source-mode.ts +237 -0
- package/corpus/templates/forms/app/components/layout/Sidebar.tsx +149 -6
- package/corpus/templates/forms/app/i18n/ar-SA.ts +2 -0
- package/corpus/templates/forms/app/i18n/de-DE.ts +2 -0
- package/corpus/templates/forms/app/i18n/en-US.ts +2 -0
- package/corpus/templates/forms/app/i18n/es-ES.ts +2 -0
- package/corpus/templates/forms/app/i18n/fr-FR.ts +2 -0
- package/corpus/templates/forms/app/i18n/hi-IN.ts +2 -0
- package/corpus/templates/forms/app/i18n/ja-JP.ts +2 -0
- package/corpus/templates/forms/app/i18n/ko-KR.ts +2 -0
- package/corpus/templates/forms/app/i18n/pt-BR.ts +2 -0
- package/corpus/templates/forms/app/i18n/zh-CN.ts +2 -0
- package/corpus/templates/forms/app/i18n/zh-TW.ts +2 -0
- package/corpus/templates/forms/changelog/2026-06-28-left-sidebar-collapses-into-an-animated-icon-rail.md +6 -0
- package/corpus/templates/macros/app/components/layout/AppLayout.tsx +2 -2
- package/corpus/templates/macros/changelog/2026-06-28-left-sidebar-footer-controls-use-less-divider-chrome.md +6 -0
- package/corpus/templates/mail/app/components/layout/AppLayout.tsx +408 -247
- package/corpus/templates/mail/app/i18n/ar-SA.ts +4 -0
- package/corpus/templates/mail/app/i18n/de-DE.ts +4 -0
- package/corpus/templates/mail/app/i18n/en-US.ts +4 -0
- package/corpus/templates/mail/app/i18n/es-ES.ts +4 -0
- package/corpus/templates/mail/app/i18n/fr-FR.ts +4 -0
- package/corpus/templates/mail/app/i18n/hi-IN.ts +4 -0
- package/corpus/templates/mail/app/i18n/ja-JP.ts +4 -0
- package/corpus/templates/mail/app/i18n/ko-KR.ts +4 -0
- package/corpus/templates/mail/app/i18n/pt-BR.ts +4 -0
- package/corpus/templates/mail/app/i18n/zh-CN.ts +4 -0
- package/corpus/templates/mail/app/i18n/zh-TW.ts +4 -0
- package/corpus/templates/mail/changelog/2026-06-28-pinned-sidebar-collapses-into-an-animated-icon-rail.md +6 -0
- package/corpus/templates/plan/app/components/layout/Sidebar.tsx +6 -8
- package/corpus/templates/plan/app/components/plan/wireframe/Wireframe.tsx +1 -1
- package/corpus/templates/plan/app/global.css +61 -78
- package/corpus/templates/plan/app/pages/PlansPage.tsx +8 -0
- package/corpus/templates/plan/changelog/2026-06-28-left-sidebar-collapse-motion-and-footer-chrome-are-quieter.md +6 -0
- package/corpus/templates/plan/changelog/2026-06-28-plans-use-the-shared-neutral-light-and-dark-theme.md +6 -0
- package/corpus/templates/plan/changelog/2026-06-28-sending-open-feedback-from-a-plan-now-opens-the-inline-plan-.md +6 -0
- package/corpus/templates/slides/app/components/layout/Sidebar.tsx +5 -5
- package/corpus/templates/slides/changelog/2026-06-28-left-sidebar-collapse-motion-and-footer-chrome-are-quieter.md +6 -0
- package/corpus/templates/videos/app/components/Sidebar.tsx +2 -2
- package/corpus/templates/videos/app/components/layout/Layout.tsx +29 -2
- package/corpus/templates/videos/app/components/layout/NavSidebar.tsx +113 -30
- package/corpus/templates/videos/app/i18n/ar-SA.ts +2 -0
- package/corpus/templates/videos/app/i18n/de-DE.ts +2 -0
- package/corpus/templates/videos/app/i18n/en-US.ts +2 -0
- package/corpus/templates/videos/app/i18n/es-ES.ts +2 -0
- package/corpus/templates/videos/app/i18n/fr-FR.ts +2 -0
- package/corpus/templates/videos/app/i18n/hi-IN.ts +2 -0
- package/corpus/templates/videos/app/i18n/ja-JP.ts +2 -0
- package/corpus/templates/videos/app/i18n/ko-KR.ts +2 -0
- package/corpus/templates/videos/app/i18n/pt-BR.ts +2 -0
- package/corpus/templates/videos/app/i18n/zh-CN.ts +2 -0
- package/corpus/templates/videos/app/i18n/zh-TW.ts +2 -0
- package/corpus/templates/videos/changelog/2026-06-28-left-sidebar-collapses-into-an-animated-icon-rail.md +6 -0
- package/dist/agent/engine/index.d.ts +1 -1
- package/dist/agent/engine/index.d.ts.map +1 -1
- package/dist/agent/engine/index.js +1 -1
- package/dist/agent/engine/index.js.map +1 -1
- package/dist/agent/engine/registry.d.ts +9 -0
- package/dist/agent/engine/registry.d.ts.map +1 -1
- package/dist/agent/engine/registry.js +37 -0
- package/dist/agent/engine/registry.js.map +1 -1
- package/dist/agent/production-agent.d.ts.map +1 -1
- package/dist/agent/production-agent.js +4 -3
- package/dist/agent/production-agent.js.map +1 -1
- package/dist/cli/design-connect.d.ts +52 -0
- package/dist/cli/design-connect.d.ts.map +1 -0
- package/dist/cli/design-connect.js +409 -0
- package/dist/cli/design-connect.js.map +1 -0
- package/dist/cli/index.js +15 -0
- package/dist/cli/index.js.map +1 -1
- package/dist/cli/skills.d.ts +3 -0
- package/dist/cli/skills.d.ts.map +1 -1
- package/dist/cli/skills.js +121 -3
- package/dist/cli/skills.js.map +1 -1
- package/dist/client/AssistantChat.d.ts.map +1 -1
- package/dist/client/AssistantChat.js +38 -8
- package/dist/client/AssistantChat.js.map +1 -1
- package/dist/client/agent-chat.d.ts +6 -0
- package/dist/client/agent-chat.d.ts.map +1 -1
- package/dist/client/agent-chat.js +17 -3
- package/dist/client/agent-chat.js.map +1 -1
- package/dist/client/blocks/library/MermaidBlock.js +1 -1
- package/dist/client/blocks/library/MermaidBlock.js.map +1 -1
- package/dist/client/blocks/library/diagram.js +1 -1
- package/dist/client/blocks/library/diagram.js.map +1 -1
- package/dist/client/blocks/library/wireframe.js +1 -1
- package/dist/client/blocks/library/wireframe.js.map +1 -1
- package/dist/client/chat/message-components.js +1 -1
- package/dist/client/chat/message-components.js.map +1 -1
- package/dist/client/chat-model-groups.d.ts.map +1 -1
- package/dist/client/chat-model-groups.js +1 -2
- package/dist/client/chat-model-groups.js.map +1 -1
- package/dist/client/components/LiveCursorOverlay.d.ts +1 -2
- package/dist/client/components/LiveCursorOverlay.d.ts.map +1 -1
- package/dist/client/components/LiveCursorOverlay.js +19 -40
- package/dist/client/components/LiveCursorOverlay.js.map +1 -1
- package/dist/client/composer/TiptapComposer.d.ts +3 -1
- package/dist/client/composer/TiptapComposer.d.ts.map +1 -1
- package/dist/client/composer/TiptapComposer.js +86 -24
- package/dist/client/composer/TiptapComposer.js.map +1 -1
- package/dist/client/composer/useVoiceDictation.d.ts +9 -0
- package/dist/client/composer/useVoiceDictation.d.ts.map +1 -1
- package/dist/client/composer/useVoiceDictation.js +154 -32
- package/dist/client/composer/useVoiceDictation.js.map +1 -1
- package/dist/client/frame-protocol.d.ts +17 -2
- package/dist/client/frame-protocol.d.ts.map +1 -1
- package/dist/client/frame-protocol.js.map +1 -1
- package/dist/client/rich-markdown-editor/RegistryBlockNode.js +2 -2
- package/dist/client/rich-markdown-editor/RegistryBlockNode.js.map +1 -1
- package/dist/client/sharing/ShareButton.d.ts +2 -0
- package/dist/client/sharing/ShareButton.d.ts.map +1 -1
- package/dist/client/sharing/ShareButton.js +7 -6
- package/dist/client/sharing/ShareButton.js.map +1 -1
- package/dist/client/use-agent-engine-configured.d.ts +5 -0
- package/dist/client/use-agent-engine-configured.d.ts.map +1 -1
- package/dist/client/use-agent-engine-configured.js +51 -25
- package/dist/client/use-agent-engine-configured.js.map +1 -1
- package/dist/collab/awareness.d.ts +2 -2
- package/dist/collab/awareness.d.ts.map +1 -1
- package/dist/collab/routes.d.ts +1 -1
- package/dist/file-upload/actions/upload-image.d.ts +2 -2
- package/dist/notifications/routes.d.ts +3 -3
- package/dist/observability/routes.d.ts +8 -8
- package/dist/progress/routes.d.ts +1 -1
- package/dist/server/agent-engine-api-key-route.d.ts +1 -1
- package/dist/server/transcribe-voice.d.ts.map +1 -1
- package/dist/server/transcribe-voice.js +40 -24
- package/dist/server/transcribe-voice.js.map +1 -1
- package/dist/shared/mcp-embed-headers.d.ts +1 -0
- package/dist/shared/mcp-embed-headers.d.ts.map +1 -1
- package/dist/shared/mcp-embed-headers.js +20 -1
- package/dist/shared/mcp-embed-headers.js.map +1 -1
- package/dist/styles/agent-native.css +56 -7
- package/dist/templates/workspace-core/.agents/skills/voice-transcription/SKILL.md +10 -0
- package/dist/vite/client.d.ts.map +1 -1
- package/dist/vite/client.js +2 -0
- package/dist/vite/client.js.map +1 -1
- package/dist/voice/index.d.ts +5 -0
- package/dist/voice/index.d.ts.map +1 -0
- package/dist/voice/index.js +4 -0
- package/dist/voice/index.js.map +1 -0
- package/dist/voice/voice-cleanup-prompt.d.ts +6 -0
- package/dist/voice/voice-cleanup-prompt.d.ts.map +1 -0
- package/dist/voice/voice-cleanup-prompt.js +26 -0
- package/dist/voice/voice-cleanup-prompt.js.map +1 -0
- package/dist/voice/voice-context.d.ts +25 -0
- package/dist/voice/voice-context.d.ts.map +1 -0
- package/dist/voice/voice-context.js +156 -0
- package/dist/voice/voice-context.js.map +1 -0
- package/dist/voice/voice-replacements.d.ts +4 -0
- package/dist/voice/voice-replacements.d.ts.map +1 -0
- package/dist/voice/voice-replacements.js +52 -0
- package/dist/voice/voice-replacements.js.map +1 -0
- package/docs/content/locales/ar-SA/template-design.mdx +41 -0
- package/docs/content/locales/de-DE/template-design.mdx +51 -0
- package/docs/content/locales/es-ES/template-design.mdx +50 -0
- package/docs/content/locales/fr-FR/template-design.mdx +49 -0
- package/docs/content/locales/hi-IN/template-design.mdx +44 -0
- package/docs/content/locales/ja-JP/template-design.mdx +46 -0
- package/docs/content/locales/ko-KR/template-design.mdx +44 -0
- package/docs/content/locales/pt-BR/template-design.mdx +48 -0
- package/docs/content/locales/zh-CN/template-design.mdx +36 -0
- package/docs/content/locales/zh-TW/template-design.mdx +38 -0
- package/docs/content/template-design.mdx +45 -0
- package/package.json +2 -1
- package/src/templates/workspace-core/.agents/skills/voice-transcription/SKILL.md +10 -0
- package/corpus/templates/design/app/components/design/DesignToolbar.tsx +0 -339
- package/corpus/templates/design/app/components/design/PresentMode.tsx +0 -68
- package/corpus/templates/design/app/components/design/ViewportTabs.tsx +0 -149
- package/corpus/templates/design/app/components/design/ZoomControls.tsx +0 -157
|
@@ -17,19 +17,26 @@
|
|
|
17
17
|
* The hook exposes amplitude (0..1) and duration (ms) so the composer can
|
|
18
18
|
* render the Lovable-style live waveform + MM:SS timer.
|
|
19
19
|
*/
|
|
20
|
+
import { type VoiceContextPack } from "../../voice/index.js";
|
|
20
21
|
export type VoiceProvider = "auto" | "openai" | "browser" | "google-realtime" | "builder-gemini" | "builder" | "gemini" | "groq";
|
|
21
22
|
export type TranscriptionMode = "mac-native" | "google-realtime" | "batch";
|
|
22
23
|
export interface VoicePrefs {
|
|
23
24
|
provider: VoiceProvider;
|
|
24
25
|
transcriptionMode?: TranscriptionMode;
|
|
25
26
|
instructions?: string;
|
|
27
|
+
cleanupEnabled?: boolean;
|
|
26
28
|
}
|
|
29
|
+
export interface VoiceCleanupPrefs {
|
|
30
|
+
enabled?: boolean;
|
|
31
|
+
}
|
|
32
|
+
type VoiceContextPackSource = VoiceContextPack | (() => VoiceContextPack | undefined | Promise<VoiceContextPack | undefined>) | undefined;
|
|
27
33
|
export type VoiceState = "idle" | "starting" | "recording" | "transcribing" | "error";
|
|
28
34
|
export interface UseVoiceDictationOptions {
|
|
29
35
|
onTranscript: (text: string) => void;
|
|
30
36
|
onError?: (message: string) => void;
|
|
31
37
|
/** Called with (accumulatedFinalText, currentInterimText) as speech is recognized in real time. */
|
|
32
38
|
onLiveUpdate?: (finalText: string, interimText: string) => void;
|
|
39
|
+
contextPack?: VoiceContextPackSource;
|
|
33
40
|
}
|
|
34
41
|
export interface VoiceDictationApi {
|
|
35
42
|
state: VoiceState;
|
|
@@ -43,6 +50,8 @@ export interface VoiceDictationApi {
|
|
|
43
50
|
cancel: () => void;
|
|
44
51
|
dismissError: () => void;
|
|
45
52
|
}
|
|
53
|
+
export declare function providerForTextCleanup(provider: VoiceProvider): VoiceProvider;
|
|
46
54
|
export declare function voiceDictationStartErrorMessage(error: unknown): string;
|
|
47
55
|
export declare function useVoiceDictation(options: UseVoiceDictationOptions): VoiceDictationApi;
|
|
56
|
+
export {};
|
|
48
57
|
//# sourceMappingURL=useVoiceDictation.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useVoiceDictation.d.ts","sourceRoot":"","sources":["../../../src/client/composer/useVoiceDictation.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;
|
|
1
|
+
{"version":3,"file":"useVoiceDictation.d.ts","sourceRoot":"","sources":["../../../src/client/composer/useVoiceDictation.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAIH,OAAO,EAEL,KAAK,gBAAgB,EACtB,MAAM,sBAAsB,CAAC;AAG9B,MAAM,MAAM,aAAa,GACrB,MAAM,GACN,QAAQ,GACR,SAAS,GACT,iBAAiB,GACjB,gBAAgB,GAChB,SAAS,GACT,QAAQ,GACR,MAAM,CAAC;AAEX,MAAM,MAAM,iBAAiB,GAAG,YAAY,GAAG,iBAAiB,GAAG,OAAO,CAAC;AAE3E,MAAM,WAAW,UAAU;IACzB,QAAQ,EAAE,aAAa,CAAC;IACxB,iBAAiB,CAAC,EAAE,iBAAiB,CAAC;IACtC,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,cAAc,CAAC,EAAE,OAAO,CAAC;CAC1B;AAED,MAAM,WAAW,iBAAiB;IAChC,OAAO,CAAC,EAAE,OAAO,CAAC;CACnB;AAED,KAAK,sBAAsB,GACvB,gBAAgB,GAChB,CAAC,MAAM,gBAAgB,GAAG,SAAS,GAAG,OAAO,CAAC,gBAAgB,GAAG,SAAS,CAAC,CAAC,GAC5E,SAAS,CAAC;AAoDd,MAAM,MAAM,UAAU,GAClB,MAAM,GACN,UAAU,GACV,WAAW,GACX,cAAc,GACd,OAAO,CAAC;AAEZ,MAAM,WAAW,wBAAwB;IACvC,YAAY,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;IACrC,OAAO,CAAC,EAAE,CAAC,OAAO,EAAE,MAAM,KAAK,IAAI,CAAC;IACpC,mGAAmG;IACnG,YAAY,CAAC,EAAE,CAAC,SAAS,EAAE,MAAM,EAAE,WAAW,EAAE,MAAM,KAAK,IAAI,CAAC;IAChE,WAAW,CAAC,EAAE,sBAAsB,CAAC;CACtC;AAED,MAAM,WAAW,iBAAiB;IAChC,KAAK,EAAE,UAAU,CAAC;IAClB,SAAS,EAAE,MAAM,CAAC;IAClB,UAAU,EAAE,MAAM,CAAC;IACnB,YAAY,EAAE,MAAM,GAAG,IAAI,CAAC;IAC5B,QAAQ,EAAE,aAAa,CAAC;IACxB,SAAS,EAAE,OAAO,CAAC;IACnB,KAAK,EAAE,MAAM,OAAO,CAAC,IAAI,CAAC,CAAC;IAC3B,IAAI,EAAE,MAAM,IAAI,CAAC;IACjB,MAAM,EAAE,MAAM,IAAI,CAAC;IACnB,YAAY,EAAE,MAAM,IAAI,CAAC;CAC1B;AAqHD,wBAAgB,sBAAsB,CAAC,QAAQ,EAAE,aAAa,GAAG,aAAa,CAE7E;AA0DD,wBAAgB,+BAA+B,CAAC,KAAK,EAAE,OAAO,GAAG,MAAM,CAkCtE;AAeD,wBAAgB,iBAAiB,CAC/B,OAAO,EAAE,wBAAwB,GAChC,iBAAiB,CA0xBnB"}
|
|
@@ -18,9 +18,12 @@
|
|
|
18
18
|
* render the Lovable-style live waveform + MM:SS timer.
|
|
19
19
|
*/
|
|
20
20
|
import { useCallback, useEffect, useRef, useState } from "react";
|
|
21
|
+
import { applyVoiceContextReplacements, } from "../../voice/index.js";
|
|
21
22
|
import { agentNativePath } from "../api-path.js";
|
|
22
23
|
const PREFS_KEY = "voice-transcription-prefs";
|
|
24
|
+
const CLEANUP_PREFS_KEY = "voice-cleanup-prefs";
|
|
23
25
|
const PREFS_URL = agentNativePath(`/_agent-native/application-state/${PREFS_KEY}`);
|
|
26
|
+
const CLEANUP_PREFS_URL = agentNativePath(`/_agent-native/application-state/${CLEANUP_PREFS_KEY}`);
|
|
24
27
|
const TRANSCRIBE_URL = agentNativePath("/_agent-native/transcribe-voice");
|
|
25
28
|
const GOOGLE_REALTIME_SESSION_URL = agentNativePath("/_agent-native/transcribe-stream/session");
|
|
26
29
|
const GOOGLE_REALTIME_WS_PROTOCOL = "google-realtime.v1";
|
|
@@ -55,10 +58,15 @@ function normalizeProviderForMode(mode, provider) {
|
|
|
55
58
|
return provider === "builder" ? "builder-gemini" : provider;
|
|
56
59
|
}
|
|
57
60
|
async function readVoicePrefs() {
|
|
61
|
+
const cleanupPrefs = await readVoiceCleanupPrefs();
|
|
58
62
|
try {
|
|
59
63
|
const res = await fetch(PREFS_URL);
|
|
60
|
-
if (!res.ok)
|
|
61
|
-
return {
|
|
64
|
+
if (!res.ok) {
|
|
65
|
+
return {
|
|
66
|
+
provider: await defaultProvider(),
|
|
67
|
+
cleanupEnabled: cleanupPrefs.enabled,
|
|
68
|
+
};
|
|
69
|
+
}
|
|
62
70
|
const body = (await res.json());
|
|
63
71
|
const value = body?.value ??
|
|
64
72
|
body;
|
|
@@ -74,6 +82,7 @@ async function readVoicePrefs() {
|
|
|
74
82
|
return {
|
|
75
83
|
transcriptionMode: mode,
|
|
76
84
|
provider,
|
|
85
|
+
cleanupEnabled: cleanupPrefs.enabled,
|
|
77
86
|
instructions: typeof instructions === "string" ? instructions.trim() : undefined,
|
|
78
87
|
};
|
|
79
88
|
}
|
|
@@ -81,7 +90,24 @@ async function readVoicePrefs() {
|
|
|
81
90
|
catch {
|
|
82
91
|
/* fall through */
|
|
83
92
|
}
|
|
84
|
-
return {
|
|
93
|
+
return {
|
|
94
|
+
provider: await defaultProvider(),
|
|
95
|
+
cleanupEnabled: cleanupPrefs.enabled,
|
|
96
|
+
};
|
|
97
|
+
}
|
|
98
|
+
async function readVoiceCleanupPrefs() {
|
|
99
|
+
try {
|
|
100
|
+
const res = await fetch(CLEANUP_PREFS_URL);
|
|
101
|
+
if (!res.ok)
|
|
102
|
+
return {};
|
|
103
|
+
const body = (await res.json());
|
|
104
|
+
const value = body?.value ??
|
|
105
|
+
body;
|
|
106
|
+
return { enabled: value?.enabled === true };
|
|
107
|
+
}
|
|
108
|
+
catch {
|
|
109
|
+
return {};
|
|
110
|
+
}
|
|
85
111
|
}
|
|
86
112
|
function getSpeechRecognitionCtor() {
|
|
87
113
|
if (typeof window === "undefined")
|
|
@@ -110,6 +136,52 @@ function pickMimeType() {
|
|
|
110
136
|
}
|
|
111
137
|
return "audio/webm";
|
|
112
138
|
}
|
|
139
|
+
async function resolveVoiceContextPack(source) {
|
|
140
|
+
try {
|
|
141
|
+
const value = typeof source === "function" ? await source() : source;
|
|
142
|
+
return value && typeof value === "object" ? value : undefined;
|
|
143
|
+
}
|
|
144
|
+
catch {
|
|
145
|
+
return undefined;
|
|
146
|
+
}
|
|
147
|
+
}
|
|
148
|
+
function appendVoiceContext(form, contextPack) {
|
|
149
|
+
if (!contextPack)
|
|
150
|
+
return;
|
|
151
|
+
try {
|
|
152
|
+
form.append("voiceContext", JSON.stringify(contextPack));
|
|
153
|
+
}
|
|
154
|
+
catch {
|
|
155
|
+
/* best effort */
|
|
156
|
+
}
|
|
157
|
+
}
|
|
158
|
+
export function providerForTextCleanup(provider) {
|
|
159
|
+
return provider === "google-realtime" ? "auto" : provider;
|
|
160
|
+
}
|
|
161
|
+
async function cleanupRecognizedText({ text, provider, instructions, contextPack, }) {
|
|
162
|
+
if (provider === "browser") {
|
|
163
|
+
return applyVoiceContextReplacements(text, contextPack);
|
|
164
|
+
}
|
|
165
|
+
const form = new FormData();
|
|
166
|
+
form.append("text", text);
|
|
167
|
+
form.append("provider", providerForTextCleanup(provider));
|
|
168
|
+
if (instructions?.trim()) {
|
|
169
|
+
form.append("instructions", instructions.trim());
|
|
170
|
+
}
|
|
171
|
+
appendVoiceContext(form, contextPack);
|
|
172
|
+
const res = await fetch(TRANSCRIBE_URL, {
|
|
173
|
+
method: "POST",
|
|
174
|
+
body: form,
|
|
175
|
+
});
|
|
176
|
+
if (!res.ok) {
|
|
177
|
+
const body = await res
|
|
178
|
+
.json()
|
|
179
|
+
.catch(() => ({ error: `HTTP ${res.status}` }));
|
|
180
|
+
throw new Error(body.error || `Transcript cleanup failed (${res.status})`);
|
|
181
|
+
}
|
|
182
|
+
const data = (await res.json());
|
|
183
|
+
return (data.text ?? "").trim() || text;
|
|
184
|
+
}
|
|
113
185
|
function microphoneBlockedByPermissionsPolicy() {
|
|
114
186
|
if (typeof document === "undefined")
|
|
115
187
|
return false;
|
|
@@ -161,13 +233,15 @@ function voiceDictationSpeechErrorMessage(error) {
|
|
|
161
233
|
return `Speech recognition error: ${error ?? "unknown"}`;
|
|
162
234
|
}
|
|
163
235
|
export function useVoiceDictation(options) {
|
|
164
|
-
const { onTranscript, onError, onLiveUpdate } = options;
|
|
236
|
+
const { onTranscript, onError, onLiveUpdate, contextPack } = options;
|
|
165
237
|
const onTranscriptRef = useRef(onTranscript);
|
|
166
238
|
const onErrorRef = useRef(onError);
|
|
167
239
|
const onLiveUpdateRef = useRef(onLiveUpdate);
|
|
240
|
+
const contextPackRef = useRef(contextPack);
|
|
168
241
|
onTranscriptRef.current = onTranscript;
|
|
169
242
|
onErrorRef.current = onError;
|
|
170
243
|
onLiveUpdateRef.current = onLiveUpdate;
|
|
244
|
+
contextPackRef.current = contextPack;
|
|
171
245
|
const [state, setState] = useState("idle");
|
|
172
246
|
const [amplitude, setAmplitude] = useState(0);
|
|
173
247
|
const [durationMs, setDurationMs] = useState(0);
|
|
@@ -270,6 +344,7 @@ export function useVoiceDictation(options) {
|
|
|
270
344
|
onErrorRef.current?.(message);
|
|
271
345
|
teardown();
|
|
272
346
|
}, [teardown]);
|
|
347
|
+
const getVoiceContextPack = useCallback(() => resolveVoiceContextPack(contextPackRef.current), []);
|
|
273
348
|
const startMeter = useCallback((stream) => {
|
|
274
349
|
try {
|
|
275
350
|
const AudioCtor = typeof window !== "undefined"
|
|
@@ -356,6 +431,7 @@ export function useVoiceDictation(options) {
|
|
|
356
431
|
if (instructions?.trim()) {
|
|
357
432
|
form.append("instructions", instructions.trim());
|
|
358
433
|
}
|
|
434
|
+
appendVoiceContext(form, await getVoiceContextPack());
|
|
359
435
|
const res = await fetch(TRANSCRIBE_URL, {
|
|
360
436
|
method: "POST",
|
|
361
437
|
body: form,
|
|
@@ -445,8 +521,8 @@ export function useVoiceDictation(options) {
|
|
|
445
521
|
/* best effort — live preview just won't appear */
|
|
446
522
|
}
|
|
447
523
|
}
|
|
448
|
-
}, [startMeter, startTimer, teardown, failWith]);
|
|
449
|
-
const startBrowser = useCallback(async () => {
|
|
524
|
+
}, [startMeter, startTimer, teardown, failWith, getVoiceContextPack]);
|
|
525
|
+
const startBrowser = useCallback(async (prefs) => {
|
|
450
526
|
const Ctor = getSpeechRecognitionCtor();
|
|
451
527
|
if (!Ctor) {
|
|
452
528
|
throw new Error("Your browser doesn't support speech recognition. Add an OpenAI API key in settings for Whisper transcription.");
|
|
@@ -503,15 +579,38 @@ export function useVoiceDictation(options) {
|
|
|
503
579
|
const wasCancelled = cancelledRef.current;
|
|
504
580
|
cancelledRef.current = false;
|
|
505
581
|
teardown();
|
|
506
|
-
if (
|
|
507
|
-
|
|
508
|
-
|
|
582
|
+
if (wasCancelled || !text) {
|
|
583
|
+
setState("idle");
|
|
584
|
+
return;
|
|
585
|
+
}
|
|
586
|
+
void (async () => {
|
|
587
|
+
let finalText = text;
|
|
588
|
+
if (prefs.cleanupEnabled) {
|
|
589
|
+
setState("transcribing");
|
|
590
|
+
try {
|
|
591
|
+
finalText = await cleanupRecognizedText({
|
|
592
|
+
text,
|
|
593
|
+
provider: prefs.provider,
|
|
594
|
+
instructions: prefs.instructions,
|
|
595
|
+
contextPack: await getVoiceContextPack(),
|
|
596
|
+
});
|
|
597
|
+
}
|
|
598
|
+
catch {
|
|
599
|
+
finalText = text;
|
|
600
|
+
}
|
|
601
|
+
}
|
|
602
|
+
if (!cancelledRef.current && finalText) {
|
|
603
|
+
onTranscriptRef.current?.(finalText);
|
|
604
|
+
}
|
|
605
|
+
cancelledRef.current = false;
|
|
606
|
+
setState("idle");
|
|
607
|
+
})();
|
|
509
608
|
};
|
|
510
609
|
startTimer();
|
|
511
610
|
setState("recording");
|
|
512
611
|
recognition.start();
|
|
513
|
-
}, [startMeter, startTimer, teardown, failWith]);
|
|
514
|
-
const startGoogleRealtime = useCallback(async () => {
|
|
612
|
+
}, [startMeter, startTimer, teardown, failWith, getVoiceContextPack]);
|
|
613
|
+
const startGoogleRealtime = useCallback(async (prefs) => {
|
|
515
614
|
const stream = await navigator.mediaDevices.getUserMedia({ audio: true });
|
|
516
615
|
if (cancelledRef.current) {
|
|
517
616
|
for (const track of stream.getTracks())
|
|
@@ -557,25 +656,48 @@ export function useVoiceDictation(options) {
|
|
|
557
656
|
if (finalized)
|
|
558
657
|
return;
|
|
559
658
|
finalized = true;
|
|
560
|
-
|
|
561
|
-
|
|
562
|
-
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
659
|
+
void (async () => {
|
|
660
|
+
const finalText = realtimeFinalRef.current.trim();
|
|
661
|
+
const interimText = realtimeInterimRef.current.trim();
|
|
662
|
+
const text = [finalText, interimText]
|
|
663
|
+
.filter(Boolean)
|
|
664
|
+
.join(" ")
|
|
665
|
+
.trim();
|
|
666
|
+
teardown();
|
|
667
|
+
if (cancelledRef.current) {
|
|
668
|
+
cancelledRef.current = false;
|
|
669
|
+
setState("idle");
|
|
670
|
+
return;
|
|
671
|
+
}
|
|
672
|
+
if (text) {
|
|
673
|
+
let cleanedText = text;
|
|
674
|
+
if (prefs.cleanupEnabled) {
|
|
675
|
+
setState("transcribing");
|
|
676
|
+
try {
|
|
677
|
+
cleanedText = await cleanupRecognizedText({
|
|
678
|
+
text,
|
|
679
|
+
provider: prefs.provider,
|
|
680
|
+
instructions: prefs.instructions,
|
|
681
|
+
contextPack: await getVoiceContextPack(),
|
|
682
|
+
});
|
|
683
|
+
}
|
|
684
|
+
catch {
|
|
685
|
+
cleanedText = text;
|
|
686
|
+
}
|
|
687
|
+
}
|
|
688
|
+
if (!cancelledRef.current && cleanedText) {
|
|
689
|
+
onTranscriptRef.current?.(cleanedText);
|
|
690
|
+
}
|
|
691
|
+
cancelledRef.current = false;
|
|
692
|
+
setState("idle");
|
|
693
|
+
return;
|
|
694
|
+
}
|
|
695
|
+
if (errorMessage) {
|
|
696
|
+
failWith(errorMessage);
|
|
697
|
+
return;
|
|
698
|
+
}
|
|
571
699
|
setState("idle");
|
|
572
|
-
|
|
573
|
-
}
|
|
574
|
-
if (errorMessage) {
|
|
575
|
-
failWith(errorMessage);
|
|
576
|
-
return;
|
|
577
|
-
}
|
|
578
|
-
setState("idle");
|
|
700
|
+
})();
|
|
579
701
|
};
|
|
580
702
|
recorder.ondataavailable = async (event) => {
|
|
581
703
|
if (!event.data || event.data.size === 0)
|
|
@@ -703,7 +825,7 @@ export function useVoiceDictation(options) {
|
|
|
703
825
|
finish(err?.message ?? "Could not start realtime stream");
|
|
704
826
|
}
|
|
705
827
|
};
|
|
706
|
-
}, [startMeter, startTimer, teardown, failWith]);
|
|
828
|
+
}, [startMeter, startTimer, teardown, failWith, getVoiceContextPack]);
|
|
707
829
|
const start = useCallback(async () => {
|
|
708
830
|
if (state === "recording" || state === "starting")
|
|
709
831
|
return;
|
|
@@ -740,10 +862,10 @@ export function useVoiceDictation(options) {
|
|
|
740
862
|
if (!mediaRecorderSupported) {
|
|
741
863
|
throw new Error("Your browser doesn't support audio recording, so Google realtime transcription can't start.");
|
|
742
864
|
}
|
|
743
|
-
await startGoogleRealtime();
|
|
865
|
+
await startGoogleRealtime(prefs);
|
|
744
866
|
}
|
|
745
867
|
else {
|
|
746
|
-
await startBrowser();
|
|
868
|
+
await startBrowser(prefs);
|
|
747
869
|
}
|
|
748
870
|
}
|
|
749
871
|
catch (err) {
|