@agent-native/core 0.117.1 → 0.118.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 +3 -3
- package/corpus/core/CHANGELOG.md +40 -0
- package/corpus/core/docs/content/custom-design-system.mdx +445 -0
- package/corpus/core/docs/content/toolkit-ui.mdx +16 -0
- package/corpus/core/package.json +2 -1
- package/corpus/core/src/a2a/types.ts +1 -0
- package/corpus/core/src/agent/types.ts +1 -1
- package/corpus/core/src/cli/context-xray-local.ts +1 -1
- package/corpus/core/src/client/AgentPanel.tsx +90 -107
- package/corpus/core/src/client/AssistantChat.tsx +30 -13
- package/corpus/core/src/client/CommandMenu.tsx +68 -178
- package/corpus/core/src/client/agent-chat-adapter.ts +3 -1
- package/corpus/core/src/client/app-providers.tsx +1 -1
- package/corpus/core/src/client/chat/message-components.tsx +116 -10
- package/corpus/core/src/client/chat/tool-call-display.tsx +26 -5
- package/corpus/core/src/client/chat/widgets/InlineExtensionWidget.tsx +14 -40
- package/corpus/core/src/client/components/ui/message-scroller.tsx +15 -1
- package/corpus/core/src/client/extensions/ExtensionViewer.tsx +4 -4
- package/corpus/core/src/client/extensions/ExtensionsSidebarSection.tsx +11 -11
- package/corpus/core/src/client/extensions/agent-native-extension-runtime.ts +1 -1
- package/corpus/core/src/client/extensions/delete-extension.ts +2 -2
- package/corpus/core/src/client/i18n.tsx +22 -0
- package/corpus/core/src/client/index.ts +17 -0
- package/corpus/core/src/client/org/OrgSwitcher.tsx +25 -1
- package/corpus/core/src/client/org/TeamPage.tsx +257 -153
- package/corpus/core/src/client/progress/RunsTray.tsx +89 -88
- package/corpus/core/src/client/resources/McpConnectionSuggestion.tsx +5 -2
- package/corpus/core/src/client/resources/McpIntegrationDialog.tsx +34 -13
- package/corpus/core/src/client/resources/mcp-integration-catalog.ts +13 -0
- package/corpus/core/src/client/settings/DemoModeSection.tsx +6 -18
- package/corpus/core/src/client/settings/SecretsSection.tsx +97 -52
- package/corpus/core/src/client/settings/SettingsPanel.tsx +302 -254
- package/corpus/core/src/client/settings/SettingsTabsPage.tsx +23 -2
- package/corpus/core/src/client/settings/VoiceTranscriptionSection.tsx +7 -18
- package/corpus/core/src/client/settings/index.ts +7 -0
- package/corpus/core/src/client/settings/useSettingsPanelController.ts +155 -0
- package/corpus/core/src/client/setup-connections/BuilderConnectCard.tsx +116 -51
- package/corpus/core/src/client/setup-connections/index.ts +10 -0
- package/corpus/core/src/client/setup-connections/useBuilderConnectCardController.ts +82 -0
- package/corpus/core/src/client/sharing/ShareButton.tsx +71 -592
- package/corpus/core/src/client/sharing/ShareDialog.tsx +299 -633
- package/corpus/core/src/client/sharing/index.ts +42 -0
- package/corpus/core/src/client/sharing/share-controller-helpers.ts +318 -0
- package/corpus/core/src/client/sharing/useShareButtonController.ts +600 -0
- package/corpus/core/src/client/sharing/useShareDialogController.ts +559 -0
- package/corpus/core/src/client/sse-event-processor.ts +23 -0
- package/corpus/core/src/client/tool-display.ts +71 -0
- package/corpus/core/src/client/use-agent-engine-configured.ts +12 -19
- package/corpus/core/src/client/use-chat-threads.ts +33 -12
- package/corpus/core/src/db/client.ts +13 -10
- package/corpus/core/src/extensions/actions.ts +13 -5
- package/corpus/core/src/extensions/local.ts +1 -0
- package/corpus/core/src/extensions/routes.ts +10 -5
- package/corpus/core/src/extensions/schema.ts +5 -0
- package/corpus/core/src/extensions/slots/store.ts +14 -4
- package/corpus/core/src/extensions/store.ts +55 -19
- package/corpus/core/src/extensions/theme.ts +1 -1
- package/corpus/core/src/file-upload/registry.ts +9 -0
- package/corpus/core/src/index.browser.ts +5 -0
- package/corpus/core/src/index.ts +1 -0
- package/corpus/core/src/localization/default-messages.ts +28 -6
- package/corpus/core/src/mcp-client/oauth-routes.ts +16 -2
- package/corpus/core/src/scripts/call-agent.ts +5 -1
- package/corpus/core/src/server/action-discovery.ts +8 -0
- package/corpus/core/src/server/better-auth-instance.ts +7 -2
- package/corpus/core/src/server/email-template.ts +18 -0
- package/corpus/core/src/server/email-templates.ts +3 -0
- package/corpus/core/src/server/email.ts +40 -4
- package/corpus/core/src/server/realtime-voice.ts +1 -1
- package/corpus/core/src/sharing/actions/share-resource.ts +1 -0
- package/corpus/core/src/styles/agent-native.css +0 -24
- package/corpus/core/src/templates/default/.agents/skills/agent-native-toolkit/SKILL.md +43 -2
- package/corpus/core/src/templates/default/.agents/skills/customizing-agent-native/SKILL.md +86 -11
- package/corpus/core/src/templates/default/.agents/skills/frontend-design/SKILL.md +22 -2
- package/corpus/core/src/templates/default/.agents/skills/shadcn-ui/SKILL.md +28 -4
- package/corpus/core/src/templates/default/app/components/ui/toolkit-provider.tsx +10 -0
- package/corpus/core/src/templates/default/app/design-system.ts +3 -0
- package/corpus/core/src/templates/default/app/global.css +1 -1
- package/corpus/core/src/templates/default/app/i18n/ar-SA.ts +6 -6
- package/corpus/core/src/templates/default/app/i18n/de-DE.ts +6 -6
- package/corpus/core/src/templates/default/app/i18n/en-US.ts +6 -6
- package/corpus/core/src/templates/default/app/i18n/es-ES.ts +6 -6
- package/corpus/core/src/templates/default/app/i18n/fr-FR.ts +6 -6
- package/corpus/core/src/templates/default/app/i18n/hi-IN.ts +6 -6
- package/corpus/core/src/templates/default/app/i18n/ja-JP.ts +6 -6
- package/corpus/core/src/templates/default/app/i18n/ko-KR.ts +6 -6
- package/corpus/core/src/templates/default/app/i18n/pt-BR.ts +6 -6
- package/corpus/core/src/templates/default/app/i18n/zh-CN.ts +7 -7
- package/corpus/core/src/templates/default/app/i18n/zh-TW.ts +7 -7
- package/corpus/core/src/templates/default/app/root.tsx +5 -2
- package/corpus/core/src/templates/default/package.json +1 -0
- package/corpus/core/src/templates/headless/.agents/skills/agent-native-toolkit/SKILL.md +43 -2
- package/corpus/core/src/templates/headless/.agents/skills/customizing-agent-native/SKILL.md +86 -11
- package/corpus/core/src/templates/workspace-core/.agents/skills/agent-native-toolkit/SKILL.md +43 -2
- package/corpus/core/src/templates/workspace-core/.agents/skills/customizing-agent-native/SKILL.md +86 -11
- package/corpus/core/src/templates/workspace-core/.agents/skills/frontend-design/SKILL.md +22 -2
- package/corpus/core/src/templates/workspace-core/.agents/skills/shadcn-ui/SKILL.md +28 -4
- package/corpus/core/src/user-profile/actions/get-user-profile.ts +16 -0
- package/corpus/core/src/user-profile/actions/update-user-profile.ts +24 -0
- package/corpus/core/src/user-profile/index.ts +5 -0
- package/corpus/core/src/user-profile/shared.ts +14 -0
- package/corpus/core/src/user-profile/store.ts +50 -0
- package/corpus/core/src/vite/client.ts +39 -0
- package/corpus/templates/analytics/.agents/skills/agent-native-toolkit/SKILL.md +43 -2
- package/corpus/templates/analytics/.agents/skills/customizing-agent-native/SKILL.md +86 -11
- package/corpus/templates/analytics/.agents/skills/frontend-design/SKILL.md +22 -2
- package/corpus/templates/analytics/.agents/skills/shadcn-ui/SKILL.md +28 -4
- package/corpus/templates/analytics/app/components/ui/toolkit-provider.tsx +6 -1
- package/corpus/templates/analytics/app/design-system.ts +3 -0
- package/corpus/templates/assets/.agents/skills/agent-native-toolkit/SKILL.md +43 -2
- package/corpus/templates/assets/.agents/skills/customizing-agent-native/SKILL.md +86 -11
- package/corpus/templates/assets/.agents/skills/frontend-design/SKILL.md +22 -2
- package/corpus/templates/assets/.agents/skills/shadcn-ui/SKILL.md +28 -4
- package/corpus/templates/assets/app/components/layout/Sidebar.tsx +2 -2
- package/corpus/templates/assets/app/components/ui/alert.tsx +1 -0
- package/corpus/templates/assets/app/components/ui/toolkit-provider.tsx +6 -1
- package/corpus/templates/assets/app/design-system.ts +3 -0
- package/corpus/templates/assets/app/global.css +1 -1
- package/corpus/templates/assets/app/routes/brand-kits.$id_.presets.$presetId.tsx +26 -30
- package/corpus/templates/assets/changelog/2026-07-22-manage-agent-navigation-now-uses-the-connected-nodes-icon.md +6 -0
- package/corpus/templates/brain/.agents/skills/agent-native-toolkit/SKILL.md +43 -2
- package/corpus/templates/brain/.agents/skills/customizing-agent-native/SKILL.md +86 -11
- package/corpus/templates/brain/.agents/skills/frontend-design/SKILL.md +22 -2
- package/corpus/templates/brain/.agents/skills/shadcn-ui/SKILL.md +28 -4
- package/corpus/templates/brain/app/components/ui/dialog.tsx +1 -0
- package/corpus/templates/brain/app/components/ui/toolkit-provider.tsx +6 -1
- package/corpus/templates/brain/app/design-system.ts +3 -0
- package/corpus/templates/brain/app/global.css +2 -2
- package/corpus/templates/brain/app/lib/brain.ts +2 -2
- package/corpus/templates/brain/app/root.tsx +2 -2
- package/corpus/templates/brain/app/routes/sources.tsx +8 -8
- package/corpus/templates/brain/changelog/2026-07-22-manage-agent-navigation-now-uses-the-connected-nodes-icon.md +6 -0
- package/corpus/templates/calendar/.agents/skills/agent-native-toolkit/SKILL.md +43 -2
- package/corpus/templates/calendar/.agents/skills/customizing-agent-native/SKILL.md +86 -11
- package/corpus/templates/calendar/.agents/skills/frontend-design/SKILL.md +22 -2
- package/corpus/templates/calendar/.agents/skills/shadcn-ui/SKILL.md +28 -4
- package/corpus/templates/calendar/app/components/layout/Sidebar.tsx +6 -2
- package/corpus/templates/calendar/app/components/ui/toolkit-provider.tsx +6 -1
- package/corpus/templates/calendar/app/design-system.ts +3 -0
- package/corpus/templates/calendar/app/global.css +1 -1
- package/corpus/templates/calendar/app/root.tsx +2 -2
- package/corpus/templates/calendar/changelog/2026-07-22-manage-agent-navigation-now-uses-the-connected-nodes-icon.md +6 -0
- package/corpus/templates/chat/.agents/skills/agent-native-toolkit/SKILL.md +43 -2
- package/corpus/templates/chat/.agents/skills/customizing-agent-native/SKILL.md +86 -11
- package/corpus/templates/chat/.agents/skills/frontend-design/SKILL.md +22 -2
- package/corpus/templates/chat/.agents/skills/shadcn-ui/SKILL.md +28 -4
- package/corpus/templates/chat/app/components/layout/Sidebar.tsx +2 -2
- package/corpus/templates/chat/app/components/ui/toolkit-provider.tsx +6 -1
- package/corpus/templates/chat/app/design-system.ts +3 -0
- package/corpus/templates/chat/app/global.css +1 -1
- package/corpus/templates/chat/app/root.tsx +2 -2
- package/corpus/templates/chat/changelog/2026-07-22-manage-agent-navigation-now-uses-the-connected-nodes-icon.md +6 -0
- package/corpus/templates/clips/.agents/skills/agent-native-toolkit/SKILL.md +43 -2
- package/corpus/templates/clips/.agents/skills/customizing-agent-native/SKILL.md +86 -11
- package/corpus/templates/clips/.agents/skills/frontend-design/SKILL.md +22 -2
- package/corpus/templates/clips/.agents/skills/shadcn-ui/SKILL.md +28 -4
- package/corpus/templates/clips/actions/export-to-brain.ts +1 -1
- package/corpus/templates/clips/actions/invite-member.ts +1 -0
- package/corpus/templates/clips/app/components/library/library-layout.tsx +2 -2
- package/corpus/templates/clips/app/components/recorder/recorder-engine.ts +20 -11
- package/corpus/templates/clips/app/components/ui/toolkit-provider.tsx +6 -1
- package/corpus/templates/clips/app/design-system.ts +3 -0
- package/corpus/templates/clips/app/global.css +1 -1
- package/corpus/templates/clips/app/root.tsx +7 -2
- package/corpus/templates/clips/app/routes/_app.library._index.tsx +1 -1
- package/corpus/templates/clips/app/routes/record.tsx +2 -88
- package/corpus/templates/clips/changelog/2026-07-22-builder-connected-recordings-start-resumable-upload-sessions.md +6 -0
- package/corpus/templates/clips/changelog/2026-07-22-clip-thumbnails-now-come-from-the-recording-instead-of-the-p.md +6 -0
- package/corpus/templates/clips/changelog/2026-07-22-clips-emails-now-render-the-agent-native-logo-in-gmail-and-o.md +6 -0
- package/corpus/templates/clips/changelog/2026-07-22-dismissed-zoom-and-teams-meeting-note-prompts-now-stay-dismi.md +6 -0
- package/corpus/templates/clips/changelog/2026-07-22-fixed-windows-recordings-aborting-during-the-countdown.md +6 -0
- package/corpus/templates/clips/changelog/2026-07-22-manage-agent-navigation-now-uses-the-connected-nodes-icon.md +6 -0
- package/corpus/templates/clips/changelog/2026-07-22-permissions-and-rewind-controls-are-now-grouped-with-clearer.md +6 -0
- package/corpus/templates/clips/changelog/2026-07-22-quieter-permissions-and-rewind-controls.md +6 -0
- package/corpus/templates/clips/changelog/2026-07-22-the-desktop-popover-opens-centered-under-the-menu-bar-icon-o.md +6 -0
- package/corpus/templates/clips/desktop/src/app.tsx +100 -62
- package/corpus/templates/clips/desktop/src/lib/meeting-notification-dismissal.ts +31 -0
- package/corpus/templates/clips/desktop/src/lib/recorder.ts +4 -167
- package/corpus/templates/clips/desktop/src/overlays/meeting-notification.tsx +10 -1
- package/corpus/templates/clips/desktop/src/styles.css +111 -36
- package/corpus/templates/clips/desktop/src-tauri/src/adhoc_meetings_watcher.rs +67 -4
- package/corpus/templates/clips/desktop/src-tauri/src/lib.rs +11 -2
- package/corpus/templates/clips/desktop/src-tauri/src/meetings_watcher.rs +51 -0
- package/corpus/templates/clips/desktop/src-tauri/src/native_screen/custom_capture.rs +5 -1
- package/corpus/templates/clips/desktop/src-tauri/src/native_screen.rs +0 -189
- package/corpus/templates/clips/desktop/src-tauri/src/notifications.rs +62 -0
- package/corpus/templates/clips/desktop/src-tauri/src/shortcuts.rs +37 -2
- package/corpus/templates/clips/desktop/src-tauri/src/tray.rs +18 -0
- package/corpus/templates/clips/server/plugins/db.ts +6 -2
- package/corpus/templates/content/.agents/skills/agent-native-toolkit/SKILL.md +43 -2
- package/corpus/templates/content/.agents/skills/customizing-agent-native/SKILL.md +86 -11
- package/corpus/templates/content/.agents/skills/frontend-design/SKILL.md +22 -2
- package/corpus/templates/content/.agents/skills/shadcn-ui/SKILL.md +28 -4
- package/corpus/templates/content/app/components/editor/DocumentToolbar.tsx +41 -59
- package/corpus/templates/content/app/components/editor/database/DatabaseView.tsx +41 -41
- package/corpus/templates/content/app/components/editor/database/GalleryView.tsx +2 -1
- package/corpus/templates/content/app/components/editor/database/ListView.tsx +2 -1
- package/corpus/templates/content/app/components/editor/database/TimelineView.tsx +9 -9
- package/corpus/templates/content/app/components/editor/database/sidebar.tsx +7 -7
- package/corpus/templates/content/app/components/editor/database-sources/BuilderSourceReviewDialog.tsx +11 -11
- package/corpus/templates/content/app/components/sidebar/DocumentSidebar.tsx +3 -3
- package/corpus/templates/content/app/components/ui/checkbox.tsx +1 -0
- package/corpus/templates/content/app/components/ui/collapsible.tsx +1 -0
- package/corpus/templates/content/app/components/ui/toolkit-provider.tsx +6 -1
- package/corpus/templates/content/app/design-system.ts +3 -0
- package/corpus/templates/content/app/global.css +30 -4
- package/corpus/templates/content/app/root.tsx +2 -2
- package/corpus/templates/content/changelog/2026-07-22-manage-agent-navigation-now-uses-the-connected-nodes-icon.md +6 -0
- package/corpus/templates/content/changelog/2026-07-22-page-actions-are-grouped-into-the-three-dots-menu-for-a-clea.md +6 -0
- package/corpus/templates/crm/.agents/skills/agent-native-toolkit/SKILL.md +43 -2
- package/corpus/templates/crm/.agents/skills/customizing-agent-native/SKILL.md +86 -11
- package/corpus/templates/crm/app/components/crm/CreateCrmRecordDialog.tsx +10 -10
- package/corpus/templates/crm/app/components/crm/CrmDashboardPanel.tsx +1 -6
- package/corpus/templates/crm/app/components/crm/CrmSignalsPanel.tsx +3 -2
- package/corpus/templates/crm/app/components/crm/IntelligenceSettings.tsx +13 -12
- package/corpus/templates/crm/app/components/crm/RecordActions.tsx +17 -17
- package/corpus/templates/crm/app/components/crm/RecordGrid.tsx +8 -8
- package/corpus/templates/crm/app/components/crm/RecordWorkspace.tsx +3 -8
- package/corpus/templates/crm/app/components/crm/SavedViewDataProgram.tsx +2 -1
- package/corpus/templates/crm/app/components/crm/Surface.tsx +3 -2
- package/corpus/templates/crm/app/components/crm/WorkOverview.tsx +2 -2
- package/corpus/templates/crm/app/components/layout/CrmLayout.tsx +7 -7
- package/corpus/templates/crm/app/components/layout/CrmSidebar.tsx +1 -1
- package/corpus/templates/crm/app/components/ui/alert-dialog.tsx +1 -0
- package/corpus/templates/crm/app/components/ui/badge.tsx +1 -0
- package/corpus/templates/crm/app/components/ui/button.tsx +1 -0
- package/corpus/templates/crm/app/components/ui/card.tsx +1 -0
- package/corpus/templates/crm/app/components/ui/dialog.tsx +1 -0
- package/corpus/templates/crm/app/components/ui/input.tsx +1 -0
- package/corpus/templates/crm/app/components/ui/label.tsx +1 -0
- package/corpus/templates/crm/app/components/ui/select.tsx +1 -0
- package/corpus/templates/crm/app/components/ui/sheet.tsx +1 -0
- package/corpus/templates/crm/app/components/ui/skeleton.tsx +1 -0
- package/corpus/templates/crm/app/components/ui/switch.tsx +1 -0
- package/corpus/templates/crm/app/components/ui/table.tsx +1 -0
- package/corpus/templates/crm/app/components/ui/tabs.tsx +1 -0
- package/corpus/templates/crm/app/components/ui/textarea.tsx +1 -0
- package/corpus/templates/crm/app/components/ui/toolkit-provider.tsx +17 -0
- package/corpus/templates/crm/app/design-system.ts +3 -0
- package/corpus/templates/crm/app/global.css +1 -1
- package/corpus/templates/crm/app/root.tsx +9 -6
- package/corpus/templates/crm/app/routes/dashboard.tsx +1 -1
- package/corpus/templates/crm/app/routes/proposals.tsx +13 -13
- package/corpus/templates/crm/app/routes/setup.tsx +9 -9
- package/corpus/templates/crm/app/routes/tasks.tsx +14 -14
- package/corpus/templates/crm/app/routes/views.tsx +16 -16
- package/corpus/templates/design/.agents/skills/agent-native-toolkit/SKILL.md +43 -2
- package/corpus/templates/design/.agents/skills/customizing-agent-native/SKILL.md +86 -11
- package/corpus/templates/design/.agents/skills/frontend-design/SKILL.md +22 -2
- package/corpus/templates/design/.agents/skills/shadcn-ui/SKILL.md +28 -4
- package/corpus/templates/design/app/components/design/CanvasContextMenu.tsx +19 -1
- package/corpus/templates/design/app/components/design/DesignCanvas.tsx +12 -1
- package/corpus/templates/design/app/components/design/EditPanel.tsx +177 -52
- package/corpus/templates/design/app/components/design/MultiScreenCanvas.tsx +179 -59
- package/corpus/templates/design/app/components/design/bridge/editor-chrome.bridge.ts +74 -27
- package/corpus/templates/design/app/components/design/multi-screen/types.ts +2 -0
- package/corpus/templates/design/app/components/editor/PromptDialog.tsx +8 -8
- package/corpus/templates/design/app/components/layout/Sidebar.tsx +2 -2
- package/corpus/templates/design/app/components/ui/command.tsx +1 -0
- package/corpus/templates/design/app/components/ui/toolkit-provider.tsx +6 -1
- package/corpus/templates/design/app/design-system.ts +3 -0
- package/corpus/templates/design/app/global.css +1 -1
- package/corpus/templates/design/app/hooks/use-navigation-state.ts +6 -5
- package/corpus/templates/design/app/root.tsx +2 -2
- package/corpus/templates/design/changelog/2026-07-22-design-owners-can-keep-editing-their-designs-after-switching.md +6 -0
- package/corpus/templates/design/changelog/2026-07-22-inspector-tabs-keep-their-text-labels-at-narrow-widths.md +6 -0
- package/corpus/templates/design/changelog/2026-07-22-manage-agent-navigation-now-uses-the-connected-nodes-icon.md +6 -0
- package/corpus/templates/design/changelog/2026-07-22-narrow-breakpoint-previews-keep-their-device-labels-readable.md +6 -0
- package/corpus/templates/design/changelog/2026-07-22-removed-the-draft-status-chip-from-the-design-editor.md +6 -0
- package/corpus/templates/design/changelog/2026-07-22-responsive-breakpoint-controls-stay-within-narrow-sidebars.md +6 -0
- package/corpus/templates/design/changelog/2026-07-22-responsive-peers-now-use-a-softer-selection-highlight-withou.md +6 -0
- package/corpus/templates/design/changelog/2026-07-22-rotate-from-context-menu.md +6 -0
- package/corpus/templates/design/changelog/2026-07-22-the-selection-outline-now-stays-attached-while-moving-screen.md +6 -0
- package/corpus/templates/design/changelog/2026-07-22-view-only-designs-now-support-figma-style-layer-inspection-w.md +6 -0
- package/corpus/templates/design/server/db/index.ts +4 -0
- package/corpus/templates/dispatch/.agents/skills/agent-native-toolkit/SKILL.md +43 -2
- package/corpus/templates/dispatch/.agents/skills/customizing-agent-native/SKILL.md +86 -11
- package/corpus/templates/dispatch/.agents/skills/frontend-design/SKILL.md +22 -2
- package/corpus/templates/dispatch/.agents/skills/shadcn-ui/SKILL.md +28 -4
- package/corpus/templates/dispatch/app/components/ui/button.tsx +1 -0
- package/corpus/templates/dispatch/app/components/ui/toolkit-provider.tsx +17 -0
- package/corpus/templates/dispatch/app/design-system.ts +3 -0
- package/corpus/templates/dispatch/app/dispatch-extensions.tsx +2 -2
- package/corpus/templates/dispatch/app/global.css +1 -1
- package/corpus/templates/dispatch/app/root.tsx +12 -9
- package/corpus/templates/dispatch/changelog/2026-07-22-manage-agent-navigation-now-uses-the-connected-nodes-icon.md +6 -0
- package/corpus/templates/dispatch/package.json +1 -0
- package/corpus/templates/forms/.agents/skills/agent-native-toolkit/SKILL.md +43 -2
- package/corpus/templates/forms/.agents/skills/customizing-agent-native/SKILL.md +86 -11
- package/corpus/templates/forms/.agents/skills/frontend-design/SKILL.md +22 -2
- package/corpus/templates/forms/.agents/skills/shadcn-ui/SKILL.md +28 -4
- package/corpus/templates/forms/app/components/layout/Layout.tsx +1 -1
- package/corpus/templates/forms/app/components/layout/Sidebar.tsx +3 -3
- package/corpus/templates/forms/app/components/ui/toolkit-provider.tsx +6 -1
- package/corpus/templates/forms/app/design-system.ts +3 -0
- package/corpus/templates/forms/app/global.css +1 -1
- package/corpus/templates/forms/app/hooks/use-forms.ts +55 -2
- package/corpus/templates/forms/app/i18n/en-US.ts +2 -0
- package/corpus/templates/forms/app/pages/FormBuilderPage.tsx +3 -3
- package/corpus/templates/forms/app/pages/FormsListPage.tsx +23 -6
- package/corpus/templates/forms/app/root.tsx +2 -2
- package/corpus/templates/forms/changelog/2026-07-22-forms-now-archive-with-optimistic-feedback.md +6 -0
- package/corpus/templates/forms/changelog/2026-07-22-manage-agent-navigation-now-uses-the-connected-nodes-icon.md +6 -0
- package/corpus/templates/forms/server/plugins/agent-chat.ts +1 -1
- package/corpus/templates/macros/.agents/skills/agent-native-toolkit/SKILL.md +43 -2
- package/corpus/templates/macros/.agents/skills/customizing-agent-native/SKILL.md +86 -11
- package/corpus/templates/macros/.agents/skills/frontend-design/SKILL.md +22 -2
- package/corpus/templates/macros/.agents/skills/shadcn-ui/SKILL.md +28 -4
- package/corpus/templates/macros/app/components/layout/AppLayout.tsx +2 -2
- package/corpus/templates/macros/app/components/ui/toolkit-provider.tsx +6 -1
- package/corpus/templates/macros/app/design-system.ts +3 -0
- package/corpus/templates/macros/app/root.tsx +2 -2
- package/corpus/templates/macros/changelog/2026-07-22-manage-agent-navigation-now-uses-the-connected-nodes-icon.md +6 -0
- package/corpus/templates/mail/.agents/skills/agent-native-toolkit/SKILL.md +43 -2
- package/corpus/templates/mail/.agents/skills/customizing-agent-native/SKILL.md +86 -11
- package/corpus/templates/mail/.agents/skills/frontend-design/SKILL.md +22 -2
- package/corpus/templates/mail/.agents/skills/shadcn-ui/SKILL.md +28 -4
- package/corpus/templates/mail/app/components/email/EmailThread.tsx +134 -93
- package/corpus/templates/mail/app/components/email/email-iframe-document.ts +8 -2
- package/corpus/templates/mail/app/components/layout/AppLayout.tsx +3 -3
- package/corpus/templates/mail/app/components/layout/CommandPalette.tsx +2 -2
- package/corpus/templates/mail/app/components/ui/textarea.tsx +1 -21
- package/corpus/templates/mail/app/components/ui/toolkit-provider.tsx +6 -1
- package/corpus/templates/mail/app/design-system.ts +3 -0
- package/corpus/templates/mail/app/global.css +1 -1
- package/corpus/templates/mail/changelog/2026-07-22-email-messages-no-longer-flash-with-an-unstyled-page-while-l.md +6 -0
- package/corpus/templates/mail/changelog/2026-07-22-manage-agent-navigation-now-uses-the-connected-nodes-icon.md +6 -0
- package/corpus/templates/plan/.agents/skills/agent-native-toolkit/SKILL.md +43 -2
- package/corpus/templates/plan/.agents/skills/customizing-agent-native/SKILL.md +86 -11
- package/corpus/templates/plan/.agents/skills/frontend-design/SKILL.md +22 -2
- package/corpus/templates/plan/.agents/skills/shadcn-ui/SKILL.md +28 -4
- package/corpus/templates/plan/app/components/layout/Sidebar.tsx +2 -2
- package/corpus/templates/plan/app/components/plan/PlanContentRenderer.tsx +1 -1
- package/corpus/templates/plan/app/components/ui/toolkit-provider.tsx +6 -1
- package/corpus/templates/plan/app/design-system.ts +3 -0
- package/corpus/templates/plan/app/global.css +1 -1
- package/corpus/templates/plan/app/root.tsx +2 -2
- package/corpus/templates/plan/changelog/2026-07-22-manage-agent-navigation-now-uses-the-connected-nodes-icon.md +6 -0
- package/corpus/templates/slides/.agents/skills/agent-native-toolkit/SKILL.md +43 -2
- package/corpus/templates/slides/.agents/skills/customizing-agent-native/SKILL.md +86 -11
- package/corpus/templates/slides/.agents/skills/frontend-design/SKILL.md +22 -2
- package/corpus/templates/slides/.agents/skills/shadcn-ui/SKILL.md +28 -4
- package/corpus/templates/slides/app/components/layout/Sidebar.tsx +2 -2
- package/corpus/templates/slides/app/components/ui/toolkit-provider.tsx +6 -1
- package/corpus/templates/slides/app/design-system.ts +3 -0
- package/corpus/templates/slides/app/root.tsx +2 -2
- package/corpus/templates/slides/changelog/2026-07-22-manage-agent-navigation-now-uses-the-connected-nodes-icon.md +6 -0
- package/corpus/templates/slides/changelog/2026-07-22-slides-no-longer-fail-intermittently-on-fresh-server-instances.md +6 -0
- package/corpus/templates/slides/changelog/2026-07-22-uploaded-screenshots-can-now-be-analyzed-and-recreated-as-ed.md +6 -0
- package/corpus/templates/slides/server/lib/chat-attachments.ts +7 -3
- package/corpus/templates/slides/server/plugins/db.ts +44 -17
- package/corpus/templates/tasks/.agents/skills/agent-native-toolkit/SKILL.md +43 -2
- package/corpus/templates/tasks/.agents/skills/customizing-agent-native/SKILL.md +86 -11
- package/corpus/templates/tasks/.agents/skills/frontend-design/SKILL.md +22 -2
- package/corpus/templates/tasks/.agents/skills/shadcn-ui/SKILL.md +28 -4
- package/corpus/templates/tasks/app/components/ui/toolkit-provider.tsx +17 -0
- package/corpus/templates/tasks/app/design-system.ts +3 -0
- package/corpus/templates/tasks/app/global.css +1 -1
- package/corpus/templates/tasks/app/root.tsx +5 -2
- package/corpus/toolkit/CHANGELOG.md +14 -0
- package/corpus/toolkit/agent-native.eject.json +71 -0
- package/corpus/toolkit/package.json +31 -1
- package/corpus/toolkit/src/chat-history/ChatHistoryRail.tsx +100 -39
- package/corpus/toolkit/src/chat-history/index.ts +9 -0
- package/corpus/toolkit/src/chat-history/useChatHistoryRailController.ts +76 -0
- package/corpus/toolkit/src/chat-history.css +2 -0
- package/corpus/toolkit/src/composer/ComposerPlusMenu.tsx +11 -8
- package/corpus/toolkit/src/composer/PromptComposer.tsx +27 -6
- package/corpus/toolkit/src/composer/useRealtimeVoiceMode.tsx +107 -22
- package/corpus/toolkit/src/conformance/__fixtures__/css-in-js-adapter.tsx +401 -0
- package/corpus/toolkit/src/conformance/index.ts +3 -0
- package/corpus/toolkit/src/conformance/runner.tsx +710 -0
- package/corpus/toolkit/src/conformance/types.ts +45 -0
- package/corpus/toolkit/src/conformance/version.ts +22 -0
- package/corpus/toolkit/src/design-system/components.tsx +146 -0
- package/corpus/toolkit/src/design-system/context.tsx +31 -0
- package/corpus/toolkit/src/design-system/default-adapter.tsx +915 -0
- package/corpus/toolkit/src/design-system/definition.ts +14 -0
- package/corpus/toolkit/src/design-system/error-boundary.tsx +37 -0
- package/corpus/toolkit/src/design-system/index.ts +7 -0
- package/corpus/toolkit/src/design-system/theme.ts +145 -0
- package/corpus/toolkit/src/design-system/types.ts +363 -0
- package/corpus/toolkit/src/provider.tsx +98 -5
- package/corpus/toolkit/src/ui/button.tsx +95 -6
- package/corpus/toolkit/src/ui/dialog.tsx +48 -23
- package/corpus/toolkit/src/ui/popover.tsx +16 -2
- package/corpus/toolkit/src/ui/select.tsx +7 -3
- package/corpus/toolkit/src/ui/sidebar.tsx +47 -48
- package/corpus/toolkit/src/ui/tooltip.tsx +7 -3
- package/dist/a2a/types.d.ts +1 -1
- package/dist/a2a/types.d.ts.map +1 -1
- package/dist/a2a/types.js.map +1 -1
- package/dist/agent/types.d.ts +1 -1
- package/dist/agent/types.d.ts.map +1 -1
- package/dist/agent/types.js.map +1 -1
- package/dist/cli/context-xray-local.js +1 -1
- package/dist/cli/context-xray-local.js.map +1 -1
- package/dist/client/AgentPanel.d.ts.map +1 -1
- package/dist/client/AgentPanel.js +14 -14
- package/dist/client/AgentPanel.js.map +1 -1
- package/dist/client/AssistantChat.d.ts.map +1 -1
- package/dist/client/AssistantChat.js +26 -15
- package/dist/client/AssistantChat.js.map +1 -1
- package/dist/client/CommandMenu.d.ts.map +1 -1
- package/dist/client/CommandMenu.js +18 -106
- package/dist/client/CommandMenu.js.map +1 -1
- package/dist/client/agent-chat-adapter.d.ts.map +1 -1
- package/dist/client/agent-chat-adapter.js +2 -1
- package/dist/client/agent-chat-adapter.js.map +1 -1
- package/dist/client/app-providers.d.ts.map +1 -1
- package/dist/client/app-providers.js +1 -1
- package/dist/client/app-providers.js.map +1 -1
- package/dist/client/chat/message-components.d.ts +9 -1
- package/dist/client/chat/message-components.d.ts.map +1 -1
- package/dist/client/chat/message-components.js +62 -7
- package/dist/client/chat/message-components.js.map +1 -1
- package/dist/client/chat/tool-call-display.d.ts.map +1 -1
- package/dist/client/chat/tool-call-display.js +20 -5
- package/dist/client/chat/tool-call-display.js.map +1 -1
- package/dist/client/chat/widgets/InlineExtensionWidget.d.ts.map +1 -1
- package/dist/client/chat/widgets/InlineExtensionWidget.js +9 -12
- package/dist/client/chat/widgets/InlineExtensionWidget.js.map +1 -1
- package/dist/client/components/ui/message-scroller.d.ts +1 -1
- package/dist/client/components/ui/message-scroller.d.ts.map +1 -1
- package/dist/client/components/ui/message-scroller.js +4 -3
- package/dist/client/components/ui/message-scroller.js.map +1 -1
- package/dist/client/extensions/ExtensionViewer.js +2 -2
- package/dist/client/extensions/ExtensionViewer.js.map +1 -1
- package/dist/client/extensions/ExtensionsSidebarSection.js +11 -11
- package/dist/client/extensions/ExtensionsSidebarSection.js.map +1 -1
- package/dist/client/extensions/agent-native-extension-runtime.js +1 -1
- package/dist/client/extensions/agent-native-extension-runtime.js.map +1 -1
- package/dist/client/extensions/delete-extension.d.ts +1 -1
- package/dist/client/extensions/delete-extension.d.ts.map +1 -1
- package/dist/client/extensions/delete-extension.js +1 -1
- package/dist/client/extensions/delete-extension.js.map +1 -1
- package/dist/client/i18n.d.ts.map +1 -1
- package/dist/client/i18n.js +9 -0
- package/dist/client/i18n.js.map +1 -1
- package/dist/client/index.d.ts +2 -2
- package/dist/client/index.d.ts.map +1 -1
- package/dist/client/index.js +2 -2
- package/dist/client/index.js.map +1 -1
- package/dist/client/org/OrgSwitcher.d.ts +3 -1
- package/dist/client/org/OrgSwitcher.d.ts.map +1 -1
- package/dist/client/org/OrgSwitcher.js +12 -4
- package/dist/client/org/OrgSwitcher.js.map +1 -1
- package/dist/client/org/TeamPage.d.ts.map +1 -1
- package/dist/client/org/TeamPage.js +41 -33
- package/dist/client/org/TeamPage.js.map +1 -1
- package/dist/client/progress/RunsTray.d.ts.map +1 -1
- package/dist/client/progress/RunsTray.js +9 -10
- package/dist/client/progress/RunsTray.js.map +1 -1
- package/dist/client/resources/McpConnectionSuggestion.d.ts.map +1 -1
- package/dist/client/resources/McpConnectionSuggestion.js +5 -4
- package/dist/client/resources/McpConnectionSuggestion.js.map +1 -1
- package/dist/client/resources/McpIntegrationDialog.d.ts.map +1 -1
- package/dist/client/resources/McpIntegrationDialog.js +10 -8
- package/dist/client/resources/McpIntegrationDialog.js.map +1 -1
- package/dist/client/resources/mcp-integration-catalog.d.ts +1 -0
- package/dist/client/resources/mcp-integration-catalog.d.ts.map +1 -1
- package/dist/client/resources/mcp-integration-catalog.js +13 -0
- package/dist/client/resources/mcp-integration-catalog.js.map +1 -1
- package/dist/client/settings/DemoModeSection.d.ts.map +1 -1
- package/dist/client/settings/DemoModeSection.js +2 -5
- package/dist/client/settings/DemoModeSection.js.map +1 -1
- package/dist/client/settings/SecretsSection.d.ts.map +1 -1
- package/dist/client/settings/SecretsSection.js +18 -6
- package/dist/client/settings/SecretsSection.js.map +1 -1
- package/dist/client/settings/SettingsPanel.d.ts.map +1 -1
- package/dist/client/settings/SettingsPanel.js +87 -119
- 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 +16 -1
- package/dist/client/settings/SettingsTabsPage.js.map +1 -1
- package/dist/client/settings/VoiceTranscriptionSection.d.ts.map +1 -1
- package/dist/client/settings/VoiceTranscriptionSection.js +2 -5
- package/dist/client/settings/VoiceTranscriptionSection.js.map +1 -1
- package/dist/client/settings/index.d.ts +1 -0
- package/dist/client/settings/index.d.ts.map +1 -1
- package/dist/client/settings/index.js +1 -0
- package/dist/client/settings/index.js.map +1 -1
- package/dist/client/settings/useSettingsPanelController.d.ts +22 -0
- package/dist/client/settings/useSettingsPanelController.d.ts.map +1 -0
- package/dist/client/settings/useSettingsPanelController.js +103 -0
- package/dist/client/settings/useSettingsPanelController.js.map +1 -0
- package/dist/client/setup-connections/BuilderConnectCard.d.ts +14 -6
- package/dist/client/setup-connections/BuilderConnectCard.d.ts.map +1 -1
- package/dist/client/setup-connections/BuilderConnectCard.js +24 -16
- package/dist/client/setup-connections/BuilderConnectCard.js.map +1 -1
- package/dist/client/setup-connections/index.d.ts +2 -1
- package/dist/client/setup-connections/index.d.ts.map +1 -1
- package/dist/client/setup-connections/index.js +2 -1
- package/dist/client/setup-connections/index.js.map +1 -1
- package/dist/client/setup-connections/useBuilderConnectCardController.d.ts +34 -0
- package/dist/client/setup-connections/useBuilderConnectCardController.d.ts.map +1 -0
- package/dist/client/setup-connections/useBuilderConnectCardController.js +39 -0
- package/dist/client/setup-connections/useBuilderConnectCardController.js.map +1 -0
- package/dist/client/sharing/ShareButton.d.ts +5 -5
- package/dist/client/sharing/ShareButton.d.ts.map +1 -1
- package/dist/client/sharing/ShareButton.js +19 -464
- package/dist/client/sharing/ShareButton.js.map +1 -1
- package/dist/client/sharing/ShareDialog.d.ts +6 -6
- package/dist/client/sharing/ShareDialog.d.ts.map +1 -1
- package/dist/client/sharing/ShareDialog.js +69 -283
- package/dist/client/sharing/ShareDialog.js.map +1 -1
- package/dist/client/sharing/index.d.ts +3 -0
- package/dist/client/sharing/index.d.ts.map +1 -1
- package/dist/client/sharing/index.js +3 -0
- package/dist/client/sharing/index.js.map +1 -1
- package/dist/client/sharing/share-controller-helpers.d.ts +70 -0
- package/dist/client/sharing/share-controller-helpers.d.ts.map +1 -0
- package/dist/client/sharing/share-controller-helpers.js +224 -0
- package/dist/client/sharing/share-controller-helpers.js.map +1 -0
- package/dist/client/sharing/useShareButtonController.d.ts +91 -0
- package/dist/client/sharing/useShareButtonController.d.ts.map +1 -0
- package/dist/client/sharing/useShareButtonController.js +397 -0
- package/dist/client/sharing/useShareButtonController.js.map +1 -0
- package/dist/client/sharing/useShareDialogController.d.ts +109 -0
- package/dist/client/sharing/useShareDialogController.d.ts.map +1 -0
- package/dist/client/sharing/useShareDialogController.js +348 -0
- package/dist/client/sharing/useShareDialogController.js.map +1 -0
- package/dist/client/sse-event-processor.d.ts.map +1 -1
- package/dist/client/sse-event-processor.js +21 -0
- package/dist/client/sse-event-processor.js.map +1 -1
- package/dist/client/tool-display.d.ts +16 -0
- package/dist/client/tool-display.d.ts.map +1 -1
- package/dist/client/tool-display.js +52 -0
- package/dist/client/tool-display.js.map +1 -1
- package/dist/client/use-agent-engine-configured.d.ts +3 -2
- package/dist/client/use-agent-engine-configured.d.ts.map +1 -1
- package/dist/client/use-agent-engine-configured.js +7 -19
- package/dist/client/use-agent-engine-configured.js.map +1 -1
- package/dist/client/use-chat-threads.d.ts.map +1 -1
- package/dist/client/use-chat-threads.js +21 -8
- package/dist/client/use-chat-threads.js.map +1 -1
- package/dist/collab/awareness.d.ts +2 -2
- package/dist/collab/awareness.d.ts.map +1 -1
- package/dist/db/client.d.ts +7 -7
- package/dist/db/client.d.ts.map +1 -1
- package/dist/db/client.js +13 -10
- package/dist/db/client.js.map +1 -1
- package/dist/extensions/actions.d.ts.map +1 -1
- package/dist/extensions/actions.js +8 -5
- package/dist/extensions/actions.js.map +1 -1
- package/dist/extensions/local.d.ts.map +1 -1
- package/dist/extensions/local.js +1 -0
- package/dist/extensions/local.js.map +1 -1
- package/dist/extensions/routes.d.ts.map +1 -1
- package/dist/extensions/routes.js +9 -4
- package/dist/extensions/routes.js.map +1 -1
- package/dist/extensions/schema.d.ts +23 -2
- package/dist/extensions/schema.d.ts.map +1 -1
- package/dist/extensions/schema.js +5 -0
- package/dist/extensions/schema.js.map +1 -1
- package/dist/extensions/slots/store.d.ts +1 -1
- package/dist/extensions/slots/store.d.ts.map +1 -1
- package/dist/extensions/slots/store.js +4 -4
- package/dist/extensions/slots/store.js.map +1 -1
- package/dist/extensions/store.d.ts +1 -0
- package/dist/extensions/store.d.ts.map +1 -1
- package/dist/extensions/store.js +38 -21
- package/dist/extensions/store.js.map +1 -1
- package/dist/extensions/theme.js +1 -1
- package/dist/extensions/theme.js.map +1 -1
- package/dist/file-upload/registry.d.ts.map +1 -1
- package/dist/file-upload/registry.js +9 -0
- package/dist/file-upload/registry.js.map +1 -1
- package/dist/index.browser.d.ts +1 -0
- package/dist/index.browser.d.ts.map +1 -1
- package/dist/index.browser.js +1 -0
- package/dist/index.browser.js.map +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -0
- package/dist/index.js.map +1 -1
- package/dist/localization/default-messages.d.ts +20 -0
- package/dist/localization/default-messages.d.ts.map +1 -1
- package/dist/localization/default-messages.js +26 -6
- package/dist/localization/default-messages.js.map +1 -1
- package/dist/mcp-client/oauth-routes.d.ts +2 -0
- package/dist/mcp-client/oauth-routes.d.ts.map +1 -1
- package/dist/mcp-client/oauth-routes.js +12 -2
- package/dist/mcp-client/oauth-routes.js.map +1 -1
- package/dist/observability/routes.d.ts +3 -3
- package/dist/provider-api/actions/custom-provider-registration.d.ts +3 -3
- package/dist/provider-api/actions/provider-api.d.ts +11 -11
- package/dist/provider-api/corpus-jobs.d.ts +2 -2
- package/dist/scripts/call-agent.d.ts.map +1 -1
- package/dist/scripts/call-agent.js +5 -1
- package/dist/scripts/call-agent.js.map +1 -1
- package/dist/secrets/routes.d.ts +6 -6
- package/dist/server/action-discovery.d.ts.map +1 -1
- package/dist/server/action-discovery.js +8 -0
- package/dist/server/action-discovery.js.map +1 -1
- package/dist/server/better-auth-instance.d.ts +7 -2
- package/dist/server/better-auth-instance.d.ts.map +1 -1
- package/dist/server/better-auth-instance.js.map +1 -1
- package/dist/server/email-template.d.ts +3 -0
- package/dist/server/email-template.d.ts.map +1 -1
- package/dist/server/email-template.js +13 -0
- package/dist/server/email-template.js.map +1 -1
- package/dist/server/email-templates.d.ts.map +1 -1
- package/dist/server/email-templates.js +3 -0
- package/dist/server/email-templates.js.map +1 -1
- package/dist/server/email.d.ts.map +1 -1
- package/dist/server/email.js +27 -4
- package/dist/server/email.js.map +1 -1
- package/dist/server/realtime-voice.js +1 -1
- package/dist/server/realtime-voice.js.map +1 -1
- package/dist/server/transcribe-voice.d.ts +1 -1
- package/dist/sharing/actions/share-resource.js +1 -0
- package/dist/sharing/actions/share-resource.js.map +1 -1
- package/dist/styles/agent-native.css +0 -24
- package/dist/templates/chat/.agents/skills/agent-native-toolkit/SKILL.md +43 -2
- package/dist/templates/chat/.agents/skills/customizing-agent-native/SKILL.md +86 -11
- package/dist/templates/chat/.agents/skills/frontend-design/SKILL.md +22 -2
- package/dist/templates/chat/.agents/skills/shadcn-ui/SKILL.md +28 -4
- package/dist/templates/chat/app/components/layout/Sidebar.tsx +2 -2
- package/dist/templates/chat/app/components/ui/toolkit-provider.tsx +6 -1
- package/dist/templates/chat/app/design-system.ts +3 -0
- package/dist/templates/chat/app/global.css +1 -1
- package/dist/templates/chat/app/root.tsx +2 -2
- package/dist/templates/chat/changelog/2026-07-22-manage-agent-navigation-now-uses-the-connected-nodes-icon.md +6 -0
- package/dist/templates/default/.agents/skills/agent-native-toolkit/SKILL.md +43 -2
- package/dist/templates/default/.agents/skills/customizing-agent-native/SKILL.md +86 -11
- package/dist/templates/default/.agents/skills/frontend-design/SKILL.md +22 -2
- package/dist/templates/default/.agents/skills/shadcn-ui/SKILL.md +28 -4
- package/dist/templates/default/app/components/ui/toolkit-provider.tsx +10 -0
- package/dist/templates/default/app/design-system.ts +3 -0
- package/dist/templates/default/app/global.css +1 -1
- package/dist/templates/default/app/i18n/ar-SA.ts +6 -6
- package/dist/templates/default/app/i18n/de-DE.ts +6 -6
- package/dist/templates/default/app/i18n/en-US.ts +6 -6
- package/dist/templates/default/app/i18n/es-ES.ts +6 -6
- package/dist/templates/default/app/i18n/fr-FR.ts +6 -6
- package/dist/templates/default/app/i18n/hi-IN.ts +6 -6
- package/dist/templates/default/app/i18n/ja-JP.ts +6 -6
- package/dist/templates/default/app/i18n/ko-KR.ts +6 -6
- package/dist/templates/default/app/i18n/pt-BR.ts +6 -6
- package/dist/templates/default/app/i18n/zh-CN.ts +7 -7
- package/dist/templates/default/app/i18n/zh-TW.ts +7 -7
- package/dist/templates/default/app/root.tsx +5 -2
- package/dist/templates/default/package.json +1 -0
- package/dist/templates/headless/.agents/skills/agent-native-toolkit/SKILL.md +43 -2
- package/dist/templates/headless/.agents/skills/customizing-agent-native/SKILL.md +86 -11
- package/dist/templates/workspace-core/.agents/skills/agent-native-toolkit/SKILL.md +43 -2
- package/dist/templates/workspace-core/.agents/skills/customizing-agent-native/SKILL.md +86 -11
- package/dist/templates/workspace-core/.agents/skills/frontend-design/SKILL.md +22 -2
- package/dist/templates/workspace-core/.agents/skills/shadcn-ui/SKILL.md +28 -4
- package/dist/user-profile/actions/get-user-profile.d.ts +4 -0
- package/dist/user-profile/actions/get-user-profile.d.ts.map +1 -0
- package/dist/user-profile/actions/get-user-profile.js +14 -0
- package/dist/user-profile/actions/get-user-profile.js.map +1 -0
- package/dist/user-profile/actions/update-user-profile.d.ts +6 -0
- package/dist/user-profile/actions/update-user-profile.d.ts.map +1 -0
- package/dist/user-profile/actions/update-user-profile.js +20 -0
- package/dist/user-profile/actions/update-user-profile.js.map +1 -0
- package/dist/user-profile/index.d.ts +2 -0
- package/dist/user-profile/index.d.ts.map +1 -0
- package/dist/user-profile/index.js +2 -0
- package/dist/user-profile/index.js.map +1 -0
- package/dist/user-profile/shared.d.ts +7 -0
- package/dist/user-profile/shared.d.ts.map +1 -0
- package/dist/user-profile/shared.js +6 -0
- package/dist/user-profile/shared.js.map +1 -0
- package/dist/user-profile/store.d.ts +4 -0
- package/dist/user-profile/store.d.ts.map +1 -0
- package/dist/user-profile/store.js +38 -0
- package/dist/user-profile/store.js.map +1 -0
- package/dist/vite/client.d.ts +3 -0
- package/dist/vite/client.d.ts.map +1 -1
- package/dist/vite/client.js +31 -0
- package/dist/vite/client.js.map +1 -1
- package/docs/content/custom-design-system.mdx +445 -0
- package/docs/content/toolkit-ui.mdx +16 -0
- package/package.json +3 -2
- package/src/a2a/types.ts +1 -0
- package/src/agent/types.ts +1 -1
- package/src/cli/context-xray-local.ts +1 -1
- package/src/client/AgentPanel.tsx +90 -107
- package/src/client/AssistantChat.tsx +30 -13
- package/src/client/CommandMenu.tsx +68 -178
- package/src/client/agent-chat-adapter.ts +3 -1
- package/src/client/app-providers.tsx +1 -1
- package/src/client/chat/message-components.tsx +116 -10
- package/src/client/chat/tool-call-display.tsx +26 -5
- package/src/client/chat/widgets/InlineExtensionWidget.tsx +14 -40
- package/src/client/components/ui/message-scroller.tsx +15 -1
- package/src/client/extensions/ExtensionViewer.tsx +4 -4
- package/src/client/extensions/ExtensionsSidebarSection.tsx +11 -11
- package/src/client/extensions/agent-native-extension-runtime.ts +1 -1
- package/src/client/extensions/delete-extension.ts +2 -2
- package/src/client/i18n.tsx +22 -0
- package/src/client/index.ts +17 -0
- package/src/client/org/OrgSwitcher.tsx +25 -1
- package/src/client/org/TeamPage.tsx +257 -153
- package/src/client/progress/RunsTray.tsx +89 -88
- package/src/client/resources/McpConnectionSuggestion.tsx +5 -2
- package/src/client/resources/McpIntegrationDialog.tsx +34 -13
- package/src/client/resources/mcp-integration-catalog.ts +13 -0
- package/src/client/settings/DemoModeSection.tsx +6 -18
- package/src/client/settings/SecretsSection.tsx +97 -52
- package/src/client/settings/SettingsPanel.tsx +302 -254
- package/src/client/settings/SettingsTabsPage.tsx +23 -2
- package/src/client/settings/VoiceTranscriptionSection.tsx +7 -18
- package/src/client/settings/index.ts +7 -0
- package/src/client/settings/useSettingsPanelController.ts +155 -0
- package/src/client/setup-connections/BuilderConnectCard.tsx +116 -51
- package/src/client/setup-connections/index.ts +10 -0
- package/src/client/setup-connections/useBuilderConnectCardController.ts +82 -0
- package/src/client/sharing/ShareButton.tsx +71 -592
- package/src/client/sharing/ShareDialog.tsx +299 -633
- package/src/client/sharing/index.ts +42 -0
- package/src/client/sharing/share-controller-helpers.ts +318 -0
- package/src/client/sharing/useShareButtonController.ts +600 -0
- package/src/client/sharing/useShareDialogController.ts +559 -0
- package/src/client/sse-event-processor.ts +23 -0
- package/src/client/tool-display.ts +71 -0
- package/src/client/use-agent-engine-configured.ts +12 -19
- package/src/client/use-chat-threads.ts +33 -12
- package/src/db/client.ts +13 -10
- package/src/extensions/actions.ts +13 -5
- package/src/extensions/local.ts +1 -0
- package/src/extensions/routes.ts +10 -5
- package/src/extensions/schema.ts +5 -0
- package/src/extensions/slots/store.ts +14 -4
- package/src/extensions/store.ts +55 -19
- package/src/extensions/theme.ts +1 -1
- package/src/file-upload/registry.ts +9 -0
- package/src/index.browser.ts +5 -0
- package/src/index.ts +1 -0
- package/src/localization/default-messages.ts +28 -6
- package/src/mcp-client/oauth-routes.ts +16 -2
- package/src/scripts/call-agent.ts +5 -1
- package/src/server/action-discovery.ts +8 -0
- package/src/server/better-auth-instance.ts +7 -2
- package/src/server/email-template.ts +18 -0
- package/src/server/email-templates.ts +3 -0
- package/src/server/email.ts +40 -4
- package/src/server/realtime-voice.ts +1 -1
- package/src/sharing/actions/share-resource.ts +1 -0
- package/src/styles/agent-native.css +0 -24
- package/src/templates/chat/.agents/skills/agent-native-toolkit/SKILL.md +43 -2
- package/src/templates/chat/.agents/skills/customizing-agent-native/SKILL.md +86 -11
- package/src/templates/chat/.agents/skills/frontend-design/SKILL.md +22 -2
- package/src/templates/chat/.agents/skills/shadcn-ui/SKILL.md +28 -4
- package/src/templates/chat/app/components/layout/Sidebar.tsx +2 -2
- package/src/templates/chat/app/components/ui/toolkit-provider.tsx +6 -1
- package/src/templates/chat/app/design-system.ts +3 -0
- package/src/templates/chat/app/global.css +1 -1
- package/src/templates/chat/app/root.tsx +2 -2
- package/src/templates/chat/changelog/2026-07-22-manage-agent-navigation-now-uses-the-connected-nodes-icon.md +6 -0
- package/src/templates/default/.agents/skills/agent-native-toolkit/SKILL.md +43 -2
- package/src/templates/default/.agents/skills/customizing-agent-native/SKILL.md +86 -11
- package/src/templates/default/.agents/skills/frontend-design/SKILL.md +22 -2
- package/src/templates/default/.agents/skills/shadcn-ui/SKILL.md +28 -4
- package/src/templates/default/app/components/ui/toolkit-provider.tsx +10 -0
- package/src/templates/default/app/design-system.ts +3 -0
- package/src/templates/default/app/global.css +1 -1
- package/src/templates/default/app/i18n/ar-SA.ts +6 -6
- package/src/templates/default/app/i18n/de-DE.ts +6 -6
- package/src/templates/default/app/i18n/en-US.ts +6 -6
- package/src/templates/default/app/i18n/es-ES.ts +6 -6
- package/src/templates/default/app/i18n/fr-FR.ts +6 -6
- package/src/templates/default/app/i18n/hi-IN.ts +6 -6
- package/src/templates/default/app/i18n/ja-JP.ts +6 -6
- package/src/templates/default/app/i18n/ko-KR.ts +6 -6
- package/src/templates/default/app/i18n/pt-BR.ts +6 -6
- package/src/templates/default/app/i18n/zh-CN.ts +7 -7
- package/src/templates/default/app/i18n/zh-TW.ts +7 -7
- package/src/templates/default/app/root.tsx +5 -2
- package/src/templates/default/package.json +1 -0
- package/src/templates/headless/.agents/skills/agent-native-toolkit/SKILL.md +43 -2
- package/src/templates/headless/.agents/skills/customizing-agent-native/SKILL.md +86 -11
- package/src/templates/workspace-core/.agents/skills/agent-native-toolkit/SKILL.md +43 -2
- package/src/templates/workspace-core/.agents/skills/customizing-agent-native/SKILL.md +86 -11
- package/src/templates/workspace-core/.agents/skills/frontend-design/SKILL.md +22 -2
- package/src/templates/workspace-core/.agents/skills/shadcn-ui/SKILL.md +28 -4
- package/src/user-profile/actions/get-user-profile.ts +16 -0
- package/src/user-profile/actions/update-user-profile.ts +24 -0
- package/src/user-profile/index.ts +5 -0
- package/src/user-profile/shared.ts +14 -0
- package/src/user-profile/store.ts +50 -0
- package/src/vite/client.ts +39 -0
- package/corpus/templates/analytics/app/components/ui/calendar.tsx +0 -70
- package/corpus/templates/analytics/app/components/ui/chart.tsx +0 -386
- package/corpus/templates/calendar/app/components/ui/sonner.tsx +0 -58
- package/corpus/templates/forms/app/components/ui/calendar.tsx +0 -214
- package/corpus/templates/forms/app/components/ui/chart.tsx +0 -379
- package/corpus/templates/forms/app/components/ui/command.tsx +0 -153
- package/corpus/templates/forms/app/components/ui/context-menu.tsx +0 -198
- package/corpus/templates/forms/app/components/ui/menubar.tsx +0 -254
- package/corpus/templates/macros/app/components/ui/menubar.tsx +0 -238
- package/corpus/templates/macros/app/components/ui/progress.tsx +0 -26
- package/corpus/templates/mail/app/components/ui/calendar.tsx +0 -211
- package/corpus/templates/mail/app/components/ui/chart.tsx +0 -379
- package/corpus/templates/mail/app/components/ui/command.tsx +0 -153
- package/corpus/templates/mail/app/components/ui/context-menu.tsx +0 -198
- package/corpus/templates/mail/app/components/ui/menubar.tsx +0 -254
- package/corpus/templates/tasks/app/components/ui/accordion.tsx +0 -56
- package/corpus/templates/tasks/app/components/ui/aspect-ratio.tsx +0 -5
- package/corpus/templates/tasks/app/components/ui/breadcrumb.tsx +0 -115
- package/corpus/templates/tasks/app/components/ui/calendar.tsx +0 -70
- package/corpus/templates/tasks/app/components/ui/carousel.tsx +0 -260
- package/corpus/templates/tasks/app/components/ui/chart.tsx +0 -379
- package/corpus/templates/tasks/app/components/ui/form.tsx +0 -177
- package/corpus/templates/tasks/app/components/ui/hover-card.tsx +0 -27
- package/corpus/templates/tasks/app/components/ui/input-otp.tsx +0 -69
- package/corpus/templates/tasks/app/components/ui/menubar.tsx +0 -254
- package/corpus/templates/tasks/app/components/ui/navigation-menu.tsx +0 -128
- package/corpus/templates/tasks/app/components/ui/pagination.tsx +0 -121
- package/corpus/templates/tasks/app/components/ui/resizable.tsx +0 -43
- package/corpus/templates/tasks/app/components/ui/sidebar.tsx +0 -782
- package/corpus/templates/tasks/app/components/ui/toggle.tsx +0 -43
|
@@ -0,0 +1,710 @@
|
|
|
1
|
+
import {
|
|
2
|
+
createElement,
|
|
3
|
+
useRef,
|
|
4
|
+
useState,
|
|
5
|
+
type ReactElement,
|
|
6
|
+
type ReactNode,
|
|
7
|
+
} from "react";
|
|
8
|
+
import { flushSync } from "react-dom";
|
|
9
|
+
import { createRoot, type Root } from "react-dom/client";
|
|
10
|
+
|
|
11
|
+
import { DESIGN_SYSTEM_CONTRACT_VERSION } from "../design-system/types.js";
|
|
12
|
+
import type { DesignSystemComponents } from "../design-system/types.js";
|
|
13
|
+
import type {
|
|
14
|
+
DesignSystemConformanceCategory,
|
|
15
|
+
DesignSystemConformanceCheckResult,
|
|
16
|
+
DesignSystemConformanceReport,
|
|
17
|
+
RunDesignSystemConformanceOptions,
|
|
18
|
+
} from "./types.js";
|
|
19
|
+
import { assertDesignSystemContractVersion } from "./version.js";
|
|
20
|
+
|
|
21
|
+
interface MountedProbe {
|
|
22
|
+
container: HTMLDivElement;
|
|
23
|
+
root: Root;
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
interface CheckContext {
|
|
27
|
+
components: DesignSystemComponents;
|
|
28
|
+
document: Document;
|
|
29
|
+
mount(element: ReactElement): MountedProbe;
|
|
30
|
+
unmount(probe: MountedProbe): void;
|
|
31
|
+
settle(): Promise<void>;
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
interface ConformanceCheck {
|
|
35
|
+
id: string;
|
|
36
|
+
category: DesignSystemConformanceCategory;
|
|
37
|
+
components: readonly (keyof DesignSystemComponents)[];
|
|
38
|
+
run(context: CheckContext): void | Promise<void>;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
const contractComponentNames = [
|
|
42
|
+
"ActionButton",
|
|
43
|
+
"IconButton",
|
|
44
|
+
"TextField",
|
|
45
|
+
"TextArea",
|
|
46
|
+
"Spinner",
|
|
47
|
+
"Skeleton",
|
|
48
|
+
"Status",
|
|
49
|
+
"Surface",
|
|
50
|
+
"Avatar",
|
|
51
|
+
"Tooltip",
|
|
52
|
+
"Menu",
|
|
53
|
+
"Popover",
|
|
54
|
+
"Dialog",
|
|
55
|
+
"Picker",
|
|
56
|
+
"Checkbox",
|
|
57
|
+
"Switch",
|
|
58
|
+
"Tabs",
|
|
59
|
+
] as const satisfies readonly (keyof DesignSystemComponents)[];
|
|
60
|
+
|
|
61
|
+
function invariant(value: unknown, message: string): asserts value {
|
|
62
|
+
if (!value) throw new Error(message);
|
|
63
|
+
}
|
|
64
|
+
|
|
65
|
+
function dispatch(element: Element, event: Event): void {
|
|
66
|
+
flushSync(() => element.dispatchEvent(event));
|
|
67
|
+
}
|
|
68
|
+
|
|
69
|
+
function click(element: Element, document: Document): void {
|
|
70
|
+
for (const type of ["pointerdown", "mousedown"]) {
|
|
71
|
+
dispatch(
|
|
72
|
+
element,
|
|
73
|
+
new document.defaultView!.MouseEvent(type, {
|
|
74
|
+
bubbles: true,
|
|
75
|
+
cancelable: true,
|
|
76
|
+
button: 0,
|
|
77
|
+
}),
|
|
78
|
+
);
|
|
79
|
+
}
|
|
80
|
+
dispatch(
|
|
81
|
+
element,
|
|
82
|
+
new document.defaultView!.MouseEvent("click", {
|
|
83
|
+
bubbles: true,
|
|
84
|
+
cancelable: true,
|
|
85
|
+
button: 0,
|
|
86
|
+
}),
|
|
87
|
+
);
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
function keydown(element: Element, key: string, document: Document): void {
|
|
91
|
+
dispatch(
|
|
92
|
+
element,
|
|
93
|
+
new document.defaultView!.KeyboardEvent("keydown", {
|
|
94
|
+
key,
|
|
95
|
+
bubbles: true,
|
|
96
|
+
cancelable: true,
|
|
97
|
+
}),
|
|
98
|
+
);
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
function input(element: HTMLInputElement | HTMLTextAreaElement, value: string) {
|
|
102
|
+
const prototype =
|
|
103
|
+
element instanceof element.ownerDocument.defaultView!.HTMLTextAreaElement
|
|
104
|
+
? element.ownerDocument.defaultView!.HTMLTextAreaElement.prototype
|
|
105
|
+
: element.ownerDocument.defaultView!.HTMLInputElement.prototype;
|
|
106
|
+
Object.getOwnPropertyDescriptor(prototype, "value")?.set?.call(
|
|
107
|
+
element,
|
|
108
|
+
value,
|
|
109
|
+
);
|
|
110
|
+
dispatch(
|
|
111
|
+
element,
|
|
112
|
+
new element.ownerDocument.defaultView!.Event("input", {
|
|
113
|
+
bubbles: true,
|
|
114
|
+
cancelable: true,
|
|
115
|
+
}),
|
|
116
|
+
);
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
function elementWithText(document: Document, selector: string, text: string) {
|
|
120
|
+
return [...document.querySelectorAll(selector)].find((element) =>
|
|
121
|
+
element.textContent?.includes(text),
|
|
122
|
+
);
|
|
123
|
+
}
|
|
124
|
+
|
|
125
|
+
const checks: readonly ConformanceCheck[] = [
|
|
126
|
+
{
|
|
127
|
+
id: "contract.components",
|
|
128
|
+
category: "contract",
|
|
129
|
+
components: contractComponentNames,
|
|
130
|
+
run: ({ components }) => {
|
|
131
|
+
for (const name of contractComponentNames) {
|
|
132
|
+
invariant(
|
|
133
|
+
typeof components[name] === "function",
|
|
134
|
+
`${name} must be supplied as a React component.`,
|
|
135
|
+
);
|
|
136
|
+
}
|
|
137
|
+
},
|
|
138
|
+
},
|
|
139
|
+
{
|
|
140
|
+
id: "leaf.action-button",
|
|
141
|
+
category: "leaf",
|
|
142
|
+
components: ["ActionButton"],
|
|
143
|
+
run: ({ components, document, mount, unmount }) => {
|
|
144
|
+
let presses = 0;
|
|
145
|
+
const probe = mount(
|
|
146
|
+
<components.ActionButton
|
|
147
|
+
intent="danger"
|
|
148
|
+
emphasis="outline"
|
|
149
|
+
size="compact"
|
|
150
|
+
onPress={() => presses++}
|
|
151
|
+
>
|
|
152
|
+
Remove
|
|
153
|
+
</components.ActionButton>,
|
|
154
|
+
);
|
|
155
|
+
const button = probe.container.querySelector("button");
|
|
156
|
+
invariant(button, "ActionButton must render an operable button.");
|
|
157
|
+
click(button, document);
|
|
158
|
+
invariant(presses === 1, "ActionButton must call onPress once.");
|
|
159
|
+
unmount(probe);
|
|
160
|
+
},
|
|
161
|
+
},
|
|
162
|
+
{
|
|
163
|
+
id: "leaf.icon-button",
|
|
164
|
+
category: "leaf",
|
|
165
|
+
components: ["IconButton"],
|
|
166
|
+
run: ({ components, document, mount, unmount }) => {
|
|
167
|
+
let presses = 0;
|
|
168
|
+
const probe = mount(
|
|
169
|
+
<components.IconButton
|
|
170
|
+
label="Close panel"
|
|
171
|
+
icon={<span aria-hidden="true">x</span>}
|
|
172
|
+
onPress={() => presses++}
|
|
173
|
+
/>,
|
|
174
|
+
);
|
|
175
|
+
const button = probe.container.querySelector(
|
|
176
|
+
'button[aria-label="Close panel"]',
|
|
177
|
+
);
|
|
178
|
+
invariant(
|
|
179
|
+
button,
|
|
180
|
+
"IconButton must expose its label as an accessible name.",
|
|
181
|
+
);
|
|
182
|
+
click(button, document);
|
|
183
|
+
invariant(presses === 1, "IconButton must call onPress once.");
|
|
184
|
+
unmount(probe);
|
|
185
|
+
},
|
|
186
|
+
},
|
|
187
|
+
{
|
|
188
|
+
id: "leaf.text-field",
|
|
189
|
+
category: "leaf",
|
|
190
|
+
components: ["TextField"],
|
|
191
|
+
run: ({ components, mount, unmount }) => {
|
|
192
|
+
let value = "";
|
|
193
|
+
const probe = mount(
|
|
194
|
+
<components.TextField
|
|
195
|
+
aria-label="Project name"
|
|
196
|
+
value={value}
|
|
197
|
+
onChange={(next) => (value = next)}
|
|
198
|
+
/>,
|
|
199
|
+
);
|
|
200
|
+
const field = probe.container.querySelector("input");
|
|
201
|
+
invariant(field, "TextField must render an input.");
|
|
202
|
+
input(field, "Atlas");
|
|
203
|
+
invariant(value === "Atlas", "TextField must report string values.");
|
|
204
|
+
unmount(probe);
|
|
205
|
+
},
|
|
206
|
+
},
|
|
207
|
+
{
|
|
208
|
+
id: "leaf.text-area",
|
|
209
|
+
category: "leaf",
|
|
210
|
+
components: ["TextArea"],
|
|
211
|
+
run: ({ components, mount, unmount }) => {
|
|
212
|
+
let value = "";
|
|
213
|
+
const probe = mount(
|
|
214
|
+
<components.TextArea
|
|
215
|
+
aria-label="Notes"
|
|
216
|
+
value={value}
|
|
217
|
+
onChange={(next) => (value = next)}
|
|
218
|
+
/>,
|
|
219
|
+
);
|
|
220
|
+
const field = probe.container.querySelector("textarea");
|
|
221
|
+
invariant(field, "TextArea must render a textarea.");
|
|
222
|
+
input(field, "Conformant");
|
|
223
|
+
invariant(value === "Conformant", "TextArea must report string values.");
|
|
224
|
+
unmount(probe);
|
|
225
|
+
},
|
|
226
|
+
},
|
|
227
|
+
{
|
|
228
|
+
id: "leaf.progress-and-placeholder",
|
|
229
|
+
category: "leaf",
|
|
230
|
+
components: ["Spinner", "Skeleton"],
|
|
231
|
+
run: ({ components, mount, unmount }) => {
|
|
232
|
+
const probe = mount(
|
|
233
|
+
<>
|
|
234
|
+
<components.Spinner label="Loading records" size="compact" />
|
|
235
|
+
<components.Skeleton width={48} height={12} shape="line" />
|
|
236
|
+
</>,
|
|
237
|
+
);
|
|
238
|
+
invariant(
|
|
239
|
+
probe.container.querySelector('[role="status"]'),
|
|
240
|
+
"A labeled Spinner must expose status semantics.",
|
|
241
|
+
);
|
|
242
|
+
invariant(
|
|
243
|
+
probe.container.querySelector('[aria-hidden="true"]'),
|
|
244
|
+
"Skeleton must be hidden from assistive technology.",
|
|
245
|
+
);
|
|
246
|
+
unmount(probe);
|
|
247
|
+
},
|
|
248
|
+
},
|
|
249
|
+
{
|
|
250
|
+
id: "leaf.status-surface-avatar",
|
|
251
|
+
category: "leaf",
|
|
252
|
+
components: ["Status", "Surface", "Avatar"],
|
|
253
|
+
run: ({ components, document, mount, unmount }) => {
|
|
254
|
+
let presses = 0;
|
|
255
|
+
const probe = mount(
|
|
256
|
+
<>
|
|
257
|
+
<components.Status tone="success">Connected</components.Status>
|
|
258
|
+
<components.Surface interactive onPress={() => presses++}>
|
|
259
|
+
Open workspace
|
|
260
|
+
</components.Surface>
|
|
261
|
+
<components.Avatar name="Ada Lovelace" fallback="AL" />
|
|
262
|
+
</>,
|
|
263
|
+
);
|
|
264
|
+
invariant(
|
|
265
|
+
probe.container.textContent?.includes("Connected"),
|
|
266
|
+
"Status must render its content.",
|
|
267
|
+
);
|
|
268
|
+
const surface = elementWithText(
|
|
269
|
+
document,
|
|
270
|
+
'[role="button"]',
|
|
271
|
+
"Open workspace",
|
|
272
|
+
);
|
|
273
|
+
invariant(
|
|
274
|
+
surface,
|
|
275
|
+
"An interactive Surface must expose button semantics.",
|
|
276
|
+
);
|
|
277
|
+
keydown(surface, "Enter", document);
|
|
278
|
+
invariant(
|
|
279
|
+
presses === 1,
|
|
280
|
+
"An interactive Surface must support keyboard press.",
|
|
281
|
+
);
|
|
282
|
+
invariant(
|
|
283
|
+
probe.container.textContent?.includes("AL"),
|
|
284
|
+
"Avatar must render a fallback when no image is supplied.",
|
|
285
|
+
);
|
|
286
|
+
unmount(probe);
|
|
287
|
+
},
|
|
288
|
+
},
|
|
289
|
+
{
|
|
290
|
+
id: "behavior.tooltip",
|
|
291
|
+
category: "behavior",
|
|
292
|
+
components: ["Tooltip"],
|
|
293
|
+
run: async ({ components, document, mount, settle, unmount }) => {
|
|
294
|
+
const portal = document.createElement("div");
|
|
295
|
+
portal.dataset.conformancePortal = "true";
|
|
296
|
+
document.body.appendChild(portal);
|
|
297
|
+
const probe = mount(
|
|
298
|
+
<components.Tooltip
|
|
299
|
+
trigger={<button>Help</button>}
|
|
300
|
+
content="Helpful context"
|
|
301
|
+
open
|
|
302
|
+
portalContainer={portal}
|
|
303
|
+
/>,
|
|
304
|
+
);
|
|
305
|
+
await settle();
|
|
306
|
+
invariant(
|
|
307
|
+
portal.textContent?.includes("Helpful context"),
|
|
308
|
+
"Tooltip must honor controlled open and portalContainer.",
|
|
309
|
+
);
|
|
310
|
+
unmount(probe);
|
|
311
|
+
portal.remove();
|
|
312
|
+
},
|
|
313
|
+
},
|
|
314
|
+
{
|
|
315
|
+
id: "behavior.menu",
|
|
316
|
+
category: "behavior",
|
|
317
|
+
components: ["Menu"],
|
|
318
|
+
run: async ({ components, document, mount, settle, unmount }) => {
|
|
319
|
+
let selected: string | number | undefined;
|
|
320
|
+
const probe = mount(
|
|
321
|
+
<components.Menu
|
|
322
|
+
trigger={<button>Actions</button>}
|
|
323
|
+
items={[{ id: "archive", label: "Archive" }]}
|
|
324
|
+
open
|
|
325
|
+
onAction={(id) => (selected = id)}
|
|
326
|
+
/>,
|
|
327
|
+
);
|
|
328
|
+
await settle();
|
|
329
|
+
const item = elementWithText(document, '[role="menuitem"]', "Archive");
|
|
330
|
+
invariant(item, "Menu must render open items with menuitem semantics.");
|
|
331
|
+
click(item, document);
|
|
332
|
+
invariant(selected === "archive", "Menu must report selected item ids.");
|
|
333
|
+
unmount(probe);
|
|
334
|
+
},
|
|
335
|
+
},
|
|
336
|
+
{
|
|
337
|
+
id: "behavior.popover",
|
|
338
|
+
category: "behavior",
|
|
339
|
+
components: ["Popover"],
|
|
340
|
+
run: async ({ components, document, mount, settle, unmount }) => {
|
|
341
|
+
const portal = document.createElement("div");
|
|
342
|
+
portal.dataset.conformancePortal = "true";
|
|
343
|
+
document.body.appendChild(portal);
|
|
344
|
+
const probe = mount(
|
|
345
|
+
<components.Popover
|
|
346
|
+
trigger={<button>Details</button>}
|
|
347
|
+
open
|
|
348
|
+
portalContainer={portal}
|
|
349
|
+
>
|
|
350
|
+
Popover details
|
|
351
|
+
</components.Popover>,
|
|
352
|
+
);
|
|
353
|
+
await settle();
|
|
354
|
+
invariant(
|
|
355
|
+
portal.textContent?.includes("Popover details"),
|
|
356
|
+
"Popover must honor controlled open and portalContainer.",
|
|
357
|
+
);
|
|
358
|
+
unmount(probe);
|
|
359
|
+
portal.remove();
|
|
360
|
+
},
|
|
361
|
+
},
|
|
362
|
+
{
|
|
363
|
+
id: "behavior.dialog",
|
|
364
|
+
category: "behavior",
|
|
365
|
+
components: ["Dialog"],
|
|
366
|
+
run: async ({ components, document, mount, settle, unmount }) => {
|
|
367
|
+
const portal = document.createElement("div");
|
|
368
|
+
portal.dataset.conformancePortal = "true";
|
|
369
|
+
document.body.appendChild(portal);
|
|
370
|
+
const probe = mount(
|
|
371
|
+
<components.Dialog
|
|
372
|
+
open
|
|
373
|
+
onOpenChange={() => {}}
|
|
374
|
+
title="Edit project"
|
|
375
|
+
dismissible={false}
|
|
376
|
+
portalContainer={portal}
|
|
377
|
+
>
|
|
378
|
+
<input aria-label="Project title" />
|
|
379
|
+
</components.Dialog>,
|
|
380
|
+
);
|
|
381
|
+
await settle();
|
|
382
|
+
invariant(
|
|
383
|
+
portal.querySelector('[role="dialog"]'),
|
|
384
|
+
"Dialog must expose dialog semantics.",
|
|
385
|
+
);
|
|
386
|
+
invariant(
|
|
387
|
+
portal.textContent?.includes("Edit project"),
|
|
388
|
+
"Dialog must expose its title and honor portalContainer.",
|
|
389
|
+
);
|
|
390
|
+
invariant(
|
|
391
|
+
portal.querySelector('[role="dialog"]')?.querySelectorAll("button")
|
|
392
|
+
.length === 0,
|
|
393
|
+
"Dialog must not invent actions when footer is omitted.",
|
|
394
|
+
);
|
|
395
|
+
unmount(probe);
|
|
396
|
+
portal.remove();
|
|
397
|
+
},
|
|
398
|
+
},
|
|
399
|
+
{
|
|
400
|
+
id: "behavior.picker",
|
|
401
|
+
category: "behavior",
|
|
402
|
+
components: ["Picker"],
|
|
403
|
+
run: async ({ components, document, mount, settle, unmount }) => {
|
|
404
|
+
let value: string | null = null;
|
|
405
|
+
const probe = mount(
|
|
406
|
+
<components.Picker
|
|
407
|
+
mode="select"
|
|
408
|
+
aria-label="Owner"
|
|
409
|
+
options={[{ value: "ada", label: "Ada" }]}
|
|
410
|
+
value={value}
|
|
411
|
+
onChange={(next) => (value = next)}
|
|
412
|
+
open
|
|
413
|
+
/>,
|
|
414
|
+
);
|
|
415
|
+
await settle();
|
|
416
|
+
const option = elementWithText(document, '[role="option"]', "Ada");
|
|
417
|
+
invariant(option, "An open Picker must expose options.");
|
|
418
|
+
click(option, document);
|
|
419
|
+
invariant(value === "ada", "Picker must report option values.");
|
|
420
|
+
unmount(probe);
|
|
421
|
+
},
|
|
422
|
+
},
|
|
423
|
+
{
|
|
424
|
+
id: "behavior.checkbox-switch",
|
|
425
|
+
category: "behavior",
|
|
426
|
+
components: ["Checkbox", "Switch"],
|
|
427
|
+
run: ({ components, document, mount, unmount }) => {
|
|
428
|
+
let checked = false;
|
|
429
|
+
let switched = false;
|
|
430
|
+
const probe = mount(
|
|
431
|
+
<>
|
|
432
|
+
<components.Checkbox
|
|
433
|
+
aria-label="Include archived"
|
|
434
|
+
checked={checked}
|
|
435
|
+
onChange={(next) => (checked = next)}
|
|
436
|
+
/>
|
|
437
|
+
<components.Switch
|
|
438
|
+
aria-label="Notifications"
|
|
439
|
+
checked={switched}
|
|
440
|
+
onChange={(next) => (switched = next)}
|
|
441
|
+
/>
|
|
442
|
+
</>,
|
|
443
|
+
);
|
|
444
|
+
const checkbox = probe.container.querySelector('[role="checkbox"]');
|
|
445
|
+
const toggle = probe.container.querySelector('[role="switch"]');
|
|
446
|
+
invariant(checkbox, "Checkbox must expose checkbox semantics.");
|
|
447
|
+
invariant(toggle, "Switch must expose switch semantics.");
|
|
448
|
+
click(checkbox, document);
|
|
449
|
+
click(toggle, document);
|
|
450
|
+
invariant(
|
|
451
|
+
checked && switched,
|
|
452
|
+
"Checkbox and Switch must report state changes.",
|
|
453
|
+
);
|
|
454
|
+
unmount(probe);
|
|
455
|
+
},
|
|
456
|
+
},
|
|
457
|
+
{
|
|
458
|
+
id: "behavior.tabs",
|
|
459
|
+
category: "behavior",
|
|
460
|
+
components: ["Tabs"],
|
|
461
|
+
run: ({ components, document, mount, unmount }) => {
|
|
462
|
+
let value = "first";
|
|
463
|
+
const probe = mount(
|
|
464
|
+
<components.Tabs
|
|
465
|
+
value={value}
|
|
466
|
+
orientation="vertical"
|
|
467
|
+
onChange={(next) => (value = next)}
|
|
468
|
+
items={[
|
|
469
|
+
{ value: "first", label: "First", content: "One" },
|
|
470
|
+
{ value: "second", label: "Second", content: "Two" },
|
|
471
|
+
]}
|
|
472
|
+
/>,
|
|
473
|
+
);
|
|
474
|
+
const tabList = probe.container.querySelector('[role="tablist"]');
|
|
475
|
+
invariant(tabList, "Tabs must expose a tablist.");
|
|
476
|
+
invariant(
|
|
477
|
+
tabList.getAttribute("aria-orientation") === "vertical",
|
|
478
|
+
"Tabs must honor vertical orientation in their tablist semantics.",
|
|
479
|
+
);
|
|
480
|
+
const second = elementWithText(document, '[role="tab"]', "Second");
|
|
481
|
+
invariant(second, "Tabs must expose tab semantics.");
|
|
482
|
+
click(second, document);
|
|
483
|
+
invariant(value === "second", "Tabs must report selected values.");
|
|
484
|
+
unmount(probe);
|
|
485
|
+
},
|
|
486
|
+
},
|
|
487
|
+
{
|
|
488
|
+
id: "overlay.portal-and-z-index-stacking",
|
|
489
|
+
category: "overlay-interoperability",
|
|
490
|
+
components: ["Dialog"],
|
|
491
|
+
run: async ({ components, document, mount, settle, unmount }) => {
|
|
492
|
+
const radixHost = document.createElement("div");
|
|
493
|
+
radixHost.dataset.hostedOverlay = "radix";
|
|
494
|
+
radixHost.dataset.conformancePortal = "true";
|
|
495
|
+
radixHost.style.zIndex = "40";
|
|
496
|
+
document.body.appendChild(radixHost);
|
|
497
|
+
const customerOverlayLayer = document.createElement("div");
|
|
498
|
+
customerOverlayLayer.dataset.designSystemOverlayLayer = "true";
|
|
499
|
+
customerOverlayLayer.dataset.conformancePortal = "true";
|
|
500
|
+
customerOverlayLayer.style.position = "relative";
|
|
501
|
+
customerOverlayLayer.style.zIndex = "50";
|
|
502
|
+
document.body.appendChild(customerOverlayLayer);
|
|
503
|
+
const probe = mount(
|
|
504
|
+
<components.Dialog
|
|
505
|
+
open
|
|
506
|
+
onOpenChange={() => {}}
|
|
507
|
+
title="Stacking probe"
|
|
508
|
+
portalContainer={customerOverlayLayer}
|
|
509
|
+
>
|
|
510
|
+
Overlay content
|
|
511
|
+
</components.Dialog>,
|
|
512
|
+
);
|
|
513
|
+
await settle();
|
|
514
|
+
invariant(
|
|
515
|
+
customerOverlayLayer.querySelector('[role="dialog"]'),
|
|
516
|
+
"Behavior adapters must portal into the supplied stacking layer so they can interoperate with Radix-hosted surfaces.",
|
|
517
|
+
);
|
|
518
|
+
invariant(
|
|
519
|
+
Number(customerOverlayLayer.style.zIndex) >
|
|
520
|
+
Number(radixHost.style.zIndex),
|
|
521
|
+
"The supplied design-system portal layer must be able to stack above an existing hosted overlay.",
|
|
522
|
+
);
|
|
523
|
+
unmount(probe);
|
|
524
|
+
customerOverlayLayer.remove();
|
|
525
|
+
radixHost.remove();
|
|
526
|
+
},
|
|
527
|
+
},
|
|
528
|
+
{
|
|
529
|
+
id: "overlay.focus-interoperability",
|
|
530
|
+
category: "overlay-interoperability",
|
|
531
|
+
components: ["Dialog"],
|
|
532
|
+
run: async ({ components, document, mount, settle, unmount }) => {
|
|
533
|
+
function FocusProbe() {
|
|
534
|
+
const [open, setOpen] = useState(true);
|
|
535
|
+
const initialFocusRef = useRef<HTMLInputElement>(null);
|
|
536
|
+
const restoreFocusRef = useRef<HTMLButtonElement>(null);
|
|
537
|
+
return (
|
|
538
|
+
<>
|
|
539
|
+
<button ref={restoreFocusRef}>Hosted trigger</button>
|
|
540
|
+
<components.Dialog
|
|
541
|
+
open={open}
|
|
542
|
+
onOpenChange={setOpen}
|
|
543
|
+
title="Focus probe"
|
|
544
|
+
initialFocusRef={initialFocusRef}
|
|
545
|
+
restoreFocusRef={restoreFocusRef}
|
|
546
|
+
>
|
|
547
|
+
<input ref={initialFocusRef} aria-label="Initial focus" />
|
|
548
|
+
<button onClick={() => setOpen(false)}>Close probe</button>
|
|
549
|
+
</components.Dialog>
|
|
550
|
+
</>
|
|
551
|
+
);
|
|
552
|
+
}
|
|
553
|
+
const probe = mount(<FocusProbe />);
|
|
554
|
+
await settle();
|
|
555
|
+
const initial = document.querySelector<HTMLInputElement>(
|
|
556
|
+
'input[aria-label="Initial focus"]',
|
|
557
|
+
);
|
|
558
|
+
invariant(initial, "Dialog must render its initial focus target.");
|
|
559
|
+
invariant(
|
|
560
|
+
document.activeElement === initial,
|
|
561
|
+
"Dialog must honor initialFocusRef across adapter overlay implementations.",
|
|
562
|
+
);
|
|
563
|
+
const close = elementWithText(document, "button", "Close probe");
|
|
564
|
+
invariant(close, "Focus probe close control did not render.");
|
|
565
|
+
click(close, document);
|
|
566
|
+
await settle();
|
|
567
|
+
invariant(
|
|
568
|
+
document.activeElement?.textContent === "Hosted trigger",
|
|
569
|
+
"Dialog must restore focus to a hosted trigger after its native overlay closes.",
|
|
570
|
+
);
|
|
571
|
+
unmount(probe);
|
|
572
|
+
},
|
|
573
|
+
},
|
|
574
|
+
];
|
|
575
|
+
|
|
576
|
+
export const DESIGN_SYSTEM_CONFORMANCE_CHECKS = checks.map(
|
|
577
|
+
({ id, category, components }) => ({ id, category, components }),
|
|
578
|
+
);
|
|
579
|
+
|
|
580
|
+
export async function runDesignSystemConformance({
|
|
581
|
+
adapterName = "custom adapter",
|
|
582
|
+
components,
|
|
583
|
+
contractVersion,
|
|
584
|
+
document: suppliedDocument,
|
|
585
|
+
}: RunDesignSystemConformanceOptions): Promise<DesignSystemConformanceReport> {
|
|
586
|
+
const document = suppliedDocument ?? globalThis.document;
|
|
587
|
+
if (!document?.body || !document.defaultView) {
|
|
588
|
+
throw new Error(
|
|
589
|
+
"runDesignSystemConformance requires a browser-like document, such as Playwright, jsdom, or happy-dom.",
|
|
590
|
+
);
|
|
591
|
+
}
|
|
592
|
+
|
|
593
|
+
const results: DesignSystemConformanceCheckResult[] = [];
|
|
594
|
+
try {
|
|
595
|
+
assertDesignSystemContractVersion(contractVersion);
|
|
596
|
+
results.push({
|
|
597
|
+
id: "contract.version-policy",
|
|
598
|
+
category: "contract",
|
|
599
|
+
components: [],
|
|
600
|
+
passed: true,
|
|
601
|
+
});
|
|
602
|
+
} catch (error) {
|
|
603
|
+
results.push({
|
|
604
|
+
id: "contract.version-policy",
|
|
605
|
+
category: "contract",
|
|
606
|
+
components: [],
|
|
607
|
+
passed: false,
|
|
608
|
+
message: error instanceof Error ? error.message : String(error),
|
|
609
|
+
});
|
|
610
|
+
}
|
|
611
|
+
|
|
612
|
+
const mounted = new Set<MountedProbe>();
|
|
613
|
+
const exercisedComponents = new Set<keyof DesignSystemComponents>();
|
|
614
|
+
const trackedComponents = new Proxy(components, {
|
|
615
|
+
get(target, property, receiver) {
|
|
616
|
+
if (typeof property === "string" && property in target) {
|
|
617
|
+
exercisedComponents.add(property as keyof DesignSystemComponents);
|
|
618
|
+
}
|
|
619
|
+
return Reflect.get(target, property, receiver);
|
|
620
|
+
},
|
|
621
|
+
});
|
|
622
|
+
const context: CheckContext = {
|
|
623
|
+
components: trackedComponents,
|
|
624
|
+
document,
|
|
625
|
+
mount(element) {
|
|
626
|
+
const container = document.createElement("div");
|
|
627
|
+
container.dataset.conformanceRoot = "true";
|
|
628
|
+
document.body.appendChild(container);
|
|
629
|
+
const root = createRoot(container);
|
|
630
|
+
const probe = { container, root };
|
|
631
|
+
mounted.add(probe);
|
|
632
|
+
flushSync(() => root.render(element));
|
|
633
|
+
return probe;
|
|
634
|
+
},
|
|
635
|
+
unmount(probe) {
|
|
636
|
+
if (!mounted.delete(probe)) return;
|
|
637
|
+
flushSync(() => probe.root.unmount());
|
|
638
|
+
probe.container.remove();
|
|
639
|
+
},
|
|
640
|
+
async settle() {
|
|
641
|
+
await new Promise<void>((resolve) =>
|
|
642
|
+
document.defaultView!.setTimeout(resolve, 0),
|
|
643
|
+
);
|
|
644
|
+
},
|
|
645
|
+
};
|
|
646
|
+
|
|
647
|
+
for (const check of checks) {
|
|
648
|
+
try {
|
|
649
|
+
exercisedComponents.clear();
|
|
650
|
+
await check.run(context);
|
|
651
|
+
const missingComponents = check.components.filter(
|
|
652
|
+
(component) => !exercisedComponents.has(component),
|
|
653
|
+
);
|
|
654
|
+
invariant(
|
|
655
|
+
missingComponents.length === 0,
|
|
656
|
+
`Conformance check ${check.id} declared ${missingComponents.join(", ")} but did not exercise them.`,
|
|
657
|
+
);
|
|
658
|
+
results.push({
|
|
659
|
+
id: check.id,
|
|
660
|
+
category: check.category,
|
|
661
|
+
components: check.components,
|
|
662
|
+
passed: true,
|
|
663
|
+
});
|
|
664
|
+
} catch (error) {
|
|
665
|
+
results.push({
|
|
666
|
+
id: check.id,
|
|
667
|
+
category: check.category,
|
|
668
|
+
components: check.components,
|
|
669
|
+
passed: false,
|
|
670
|
+
message: error instanceof Error ? error.message : String(error),
|
|
671
|
+
});
|
|
672
|
+
} finally {
|
|
673
|
+
for (const probe of [...mounted]) context.unmount(probe);
|
|
674
|
+
document
|
|
675
|
+
.querySelectorAll("[data-radix-popper-content-wrapper]")
|
|
676
|
+
.forEach((element) => element.remove());
|
|
677
|
+
document
|
|
678
|
+
.querySelectorAll('[data-conformance-portal="true"]')
|
|
679
|
+
.forEach((element) => element.remove());
|
|
680
|
+
}
|
|
681
|
+
}
|
|
682
|
+
|
|
683
|
+
const report: DesignSystemConformanceReport = {
|
|
684
|
+
adapterName,
|
|
685
|
+
contractVersion: DESIGN_SYSTEM_CONTRACT_VERSION,
|
|
686
|
+
passed: results.every((result) => result.passed),
|
|
687
|
+
results,
|
|
688
|
+
};
|
|
689
|
+
return report;
|
|
690
|
+
}
|
|
691
|
+
|
|
692
|
+
export async function assertDesignSystemConformance(
|
|
693
|
+
options: RunDesignSystemConformanceOptions,
|
|
694
|
+
): Promise<DesignSystemConformanceReport> {
|
|
695
|
+
const report = await runDesignSystemConformance(options);
|
|
696
|
+
if (!report.passed) {
|
|
697
|
+
const { DesignSystemConformanceError } = await import("./types.js");
|
|
698
|
+
throw new DesignSystemConformanceError(report);
|
|
699
|
+
}
|
|
700
|
+
return report;
|
|
701
|
+
}
|
|
702
|
+
|
|
703
|
+
export function renderDesignSystemConformanceFixture(
|
|
704
|
+
components: DesignSystemComponents,
|
|
705
|
+
): ReactNode {
|
|
706
|
+
return createElement(components.Status, {
|
|
707
|
+
tone: "info",
|
|
708
|
+
children: "Adapter loaded",
|
|
709
|
+
});
|
|
710
|
+
}
|