zidane-ui 9.1.13 → 9.1.16
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/dist/adapters/index.d.ts +2 -2
- package/dist/adapters/index.js +2 -2
- package/dist/adapters/live.d.ts +29 -3
- package/dist/adapters/live.js +9 -1
- package/dist/adapters/server-composer-host.js +17 -2
- package/dist/adapters/server-extensions-host.d.ts +0 -1
- package/dist/adapters/server-extensions-host.js +4 -15
- package/dist/adapters/server-git-host.js +7 -16
- package/dist/adapters/server-host.js +181 -43
- package/dist/adapters/server-machines-host.d.ts +2 -0
- package/dist/adapters/server-machines-host.js +22 -23
- package/dist/adapters/server-onboarding-host.d.ts +1 -1
- package/dist/adapters/server-onboarding-host.js +3 -4
- package/dist/adapters/server-session-host.js +22 -3
- package/dist/adapters/server-settings-accounts.js +2 -2
- package/dist/adapters/server-settings-host.js +2 -2
- package/dist/adapters/server-settings-performance.js +7 -9
- package/dist/adapters/server-settings-sections.js +13 -14
- package/dist/adapters/server-sidebar-host.js +2 -2
- package/dist/adapters/sse-host.js +68 -3
- package/dist/adapters/sse-protocol.d.ts +12 -2
- package/dist/adapters/sse-protocol.js +4 -2
- package/dist/app/AppHostProvider.js +4 -3
- package/dist/app/ModalProvider.d.ts +13 -3
- package/dist/app/ModalProvider.js +103 -24
- package/dist/app/NoticeStack.d.ts +33 -0
- package/dist/app/NoticeStack.js +90 -0
- package/dist/app/index.d.ts +3 -2
- package/dist/app/index.js +3 -2
- package/dist/chat/SessionFilterMenu.d.ts +1 -1
- package/dist/chat/SessionFilterMenu.js +2 -1
- package/dist/chat/composer/Composer.js +10 -8
- package/dist/chat/composer/ModelChainList.js +17 -8
- package/dist/chat/composer/ModelChainTooltip.js +5 -2
- package/dist/chat/composer/use-draft-target.d.ts +20 -1
- package/dist/chat/composer/use-draft-target.js +121 -5
- package/dist/chat/composer/use-new-session-defaults.d.ts +5 -1
- package/dist/chat/composer/use-new-session-defaults.js +17 -4
- package/dist/chat/headless/chip-labels.d.ts +1 -0
- package/dist/chat/headless/chip-labels.js +1 -0
- package/dist/chat/headless/composer/labels-editor.d.ts +0 -2
- package/dist/chat/headless/composer/labels-editor.js +0 -2
- package/dist/chat/headless/draft-target.d.ts +21 -1
- package/dist/chat/headless/fixture-host.js +17 -2
- package/dist/chat/headless/host.d.ts +3 -3
- package/dist/chat/headless/index.d.ts +9 -9
- package/dist/chat/headless/index.js +2 -2
- package/dist/chat/headless/labels.d.ts +13 -6
- package/dist/chat/headless/labels.js +10 -9
- package/dist/chat/headless/session-list.d.ts +20 -8
- package/dist/chat/headless/session-list.js +1 -0
- package/dist/chat/headless/sidebar/directory.d.ts +56 -14
- package/dist/chat/headless/sidebar/directory.js +149 -70
- package/dist/chat/headless/sidebar/index.d.ts +3 -3
- package/dist/chat/headless/sidebar/index.js +2 -2
- package/dist/chat/headless/sidebar/labels.d.ts +15 -8
- package/dist/chat/headless/sidebar/types.d.ts +3 -1
- package/dist/chat/headless/sidebar/view.d.ts +13 -5
- package/dist/chat/headless/sidebar/view.js +31 -11
- package/dist/chat/headless/streams/actions.d.ts +5 -3
- package/dist/chat/headless/streams/actions.js +3 -2
- package/dist/chat/headless/streams/index.d.ts +3 -3
- package/dist/chat/headless/streams/merge.d.ts +6 -10
- package/dist/chat/headless/streams/merge.js +7 -21
- package/dist/chat/headless/streams/session-streams.d.ts +29 -4
- package/dist/chat/headless/streams/session-streams.js +86 -0
- package/dist/chat/headless/streams/store.d.ts +162 -16
- package/dist/chat/headless/streams/store.js +334 -38
- package/dist/chat/headless/streams/types.d.ts +10 -7
- package/dist/chat/headless/transcript-labels.d.ts +1 -0
- package/dist/chat/interactions/PlanCard.js +10 -3
- package/dist/chat/interactions/QuestionForm.js +7 -3
- package/dist/chat/interactions/card-ui.d.ts +5 -3
- package/dist/chat/interactions/card-ui.js +9 -7
- package/dist/chat/rich-composer/RichComposer.js +1 -7
- package/dist/chat/rich-composer/composer-extensions.d.ts +0 -2
- package/dist/chat/rich-composer/composer-extensions.js +2 -2
- package/dist/chat/rich-composer/use-composer-editor.d.ts +0 -2
- package/dist/chat/rich-composer/use-composer-editor.js +1 -2
- package/dist/chat/sidebar/SessionSidebar.js +5 -5
- package/dist/chat/sidebar/SidebarFilterMenu.js +3 -1
- package/dist/chat/sidebar/SidebarFrame.d.ts +4 -0
- package/dist/chat/sidebar/SidebarFrame.js +27 -9
- package/dist/chat/sidebar/SidebarGroupHeader.js +1 -1
- package/dist/chat/sidebar/SidebarHostProvider.d.ts +8 -5
- package/dist/chat/sidebar/SidebarHostProvider.js +13 -9
- package/dist/chat/sidebar/SidebarToggleButton.js +7 -3
- package/dist/chat/sidebar/index.d.ts +2 -2
- package/dist/chat/sidebar/session-menu.js +4 -4
- package/dist/chat/sidebar/useSaveViewAsSpace.js +2 -2
- package/dist/chat/testing/contract.js +2 -2
- package/dist/chat/transcript/AuthFailureCard.js +11 -8
- package/dist/chat/transcript/BadgeMenu.js +13 -2
- package/dist/chat/transcript/MermaidDiagram.js +7 -3
- package/dist/chat/transcript/fold.d.ts +4 -0
- package/dist/chat/transcript/fold.js +53 -22
- package/dist/chat/transcript/script-input.d.ts +1 -1
- package/dist/chat/transcript/shell-block.js +7 -3
- package/dist/chat/transcript/useStickToBottom.js +12 -0
- package/dist/components/BrowserSignIn.js +23 -21
- package/dist/components/Form.d.ts +6 -4
- package/dist/components/Form.js +16 -8
- package/dist/components/LoadError.d.ts +4 -2
- package/dist/components/LoadError.js +13 -9
- package/dist/components/Notice.d.ts +29 -0
- package/dist/components/Notice.js +63 -0
- package/dist/components/PanelEmpty.d.ts +1 -1
- package/dist/components/PanelEmpty.js +4 -2
- package/dist/components/Restricted.d.ts +1 -1
- package/dist/components/palette/PaletteList.js +8 -1
- package/dist/components/palette/PalettePanel.js +14 -6
- package/dist/core.css +24 -5
- package/dist/dist/{index-Bq87OcGy.d.ts → index-BZM8tu4L.d.ts} +28 -3
- package/dist/dist/index.d.ts +2 -2
- package/dist/dist/{timeout-B5pO5I5a.d.ts → timeout-Cyx3VGPz.d.ts} +1 -1
- package/dist/extensions/ExtensionSettingsPage.js +1 -4
- package/dist/extensions/ExtensionSettingsSection.js +4 -3
- package/dist/extensions/ExtensionSettingsSidebar.js +2 -6
- package/dist/extensions/SettingsWireForm.d.ts +1 -7
- package/dist/extensions/SettingsWireForm.js +7 -5
- package/dist/extensions/headless/fixture-host.d.ts +1 -5
- package/dist/extensions/headless/fixture-host.js +1 -4
- package/dist/extensions/headless/host.d.ts +1 -11
- package/dist/extensions/headless/index.d.ts +3 -3
- package/dist/extensions/headless/index.js +2 -2
- package/dist/extensions/headless/select.d.ts +1 -11
- package/dist/extensions/headless/select.js +1 -18
- package/dist/files/EditorColumn.js +12 -1
- package/dist/files/TreeColumn.js +13 -20
- package/dist/files/useOpenFiles.js +2 -0
- package/dist/git/BranchMenu.js +5 -3
- package/dist/git/ImportRepoDialog.js +18 -9
- package/dist/git/MoveSessionDialog.js +15 -7
- package/dist/git/RemoteFolderPicker.js +34 -16
- package/dist/git/SyncChip.js +17 -17
- package/dist/git/WherePicker.d.ts +16 -1
- package/dist/git/WherePicker.js +80 -36
- package/dist/git/headless/environment.d.ts +33 -3
- package/dist/git/headless/environment.js +33 -5
- package/dist/git/headless/index.d.ts +2 -2
- package/dist/git/headless/index.js +2 -2
- package/dist/git/headless/labels.d.ts +15 -2
- package/dist/git/headless/labels.js +17 -4
- package/dist/git/useEnvironmentChoices.d.ts +3 -1
- package/dist/git/useEnvironmentChoices.js +6 -3
- package/dist/index.d.ts +2 -1
- package/dist/index.js +2 -1
- package/dist/labels.d.ts +5 -0
- package/dist/labels.js +5 -0
- package/dist/machines/AddMachineDialog.d.ts +34 -0
- package/dist/machines/AddMachineDialog.js +464 -0
- package/dist/machines/Banners.d.ts +33 -4
- package/dist/machines/Banners.js +64 -3
- package/dist/machines/DaemonMenu.js +27 -4
- package/dist/machines/HostCapabilities.d.ts +1 -3
- package/dist/machines/HostCapabilities.js +24 -45
- package/dist/machines/HostSyncPanel.js +123 -129
- package/dist/machines/HostsSection.d.ts +4 -1
- package/dist/machines/HostsSection.js +30 -7
- package/dist/machines/MachinesExplainer.d.ts +17 -0
- package/dist/machines/MachinesExplainer.js +71 -0
- package/dist/machines/MachinesProvider.d.ts +14 -2
- package/dist/machines/MachinesProvider.js +35 -1
- package/dist/machines/ServerAddedCard.d.ts +31 -0
- package/dist/machines/ServerAddedCard.js +72 -0
- package/dist/machines/ServerCard.js +91 -215
- package/dist/machines/ServerMachinesPanel.d.ts +2 -2
- package/dist/machines/ServerMachinesPanel.js +184 -323
- package/dist/machines/ServerUpdatePanel.js +51 -40
- package/dist/machines/ShareThisComputerForm.d.ts +19 -0
- package/dist/machines/ShareThisComputerForm.js +133 -0
- package/dist/machines/TokensPanel.d.ts +5 -3
- package/dist/machines/TokensPanel.js +98 -78
- package/dist/machines/headless/fixture-host.d.ts +19 -3
- package/dist/machines/headless/fixture-host.js +42 -5
- package/dist/machines/headless/fixtures.js +4 -6
- package/dist/machines/headless/host.d.ts +40 -19
- package/dist/machines/headless/index.d.ts +3 -3
- package/dist/machines/headless/index.js +2 -2
- package/dist/machines/headless/labels.d.ts +63 -20
- package/dist/machines/headless/labels.js +88 -25
- package/dist/machines/headless/messages.js +8 -0
- package/dist/machines/headless/stores.d.ts +9 -2
- package/dist/machines/headless/stores.js +28 -1
- package/dist/machines/index.d.ts +7 -3
- package/dist/machines/index.js +8 -4
- package/dist/machines/testing/contract.d.ts +15 -3
- package/dist/machines/testing/contract.js +68 -14
- package/dist/motion/grow.d.ts +8 -1
- package/dist/motion/grow.js +10 -4
- package/dist/onboarding/demos/index.js +1 -1
- package/dist/onboarding/headless/labels.d.ts +13 -0
- package/dist/onboarding/headless/labels.js +8 -0
- package/dist/onboarding/index.js +3 -3
- package/dist/onboarding/sources/SourceBrowser.js +11 -7
- package/dist/onboarding/steps/ConnectorsStep.js +1 -1
- package/dist/onboarding/steps/ImportStep.js +4 -1
- package/dist/onboarding/steps/ReadyStep.js +9 -2
- package/dist/onboarding/steps/SkillsStep.js +1 -1
- package/dist/onboarding/steps/connect/KeyForm.js +6 -2
- package/dist/onboarding/steps/connect/ProviderPanel.js +6 -2
- package/dist/onboarding/steps/connect/ProviderReady.js +25 -20
- package/dist/onboarding/steps/tasks.js +17 -14
- package/dist/server/sse-handler.js +141 -19
- package/dist/session/ArtifactsPanel.js +39 -17
- package/dist/session/PlanTracker.js +12 -7
- package/dist/session/ProjectHome.js +13 -11
- package/dist/session/RemindersPanel.js +34 -16
- package/dist/session/RunningWorkDialog.js +6 -2
- package/dist/session/SecretsPanel.js +29 -10
- package/dist/session/SessionDetailsDialog.d.ts +1 -1
- package/dist/session/SessionDetailsDialog.js +18 -10
- package/dist/session/SideChat.js +10 -7
- package/dist/session/TurnDetailsDialog.js +19 -5
- package/dist/session/UsagePanel.js +10 -4
- package/dist/session/headless/host.d.ts +2 -0
- package/dist/session/headless/labels.d.ts +19 -1
- package/dist/session/headless/labels.js +15 -1
- package/dist/session/headless/queue.js +2 -1
- package/dist/session/headless/reminder-labels.d.ts +4 -0
- package/dist/session/headless/reminder-labels.js +4 -0
- package/dist/settings/SettingsRestricted.d.ts +1 -1
- package/dist/settings/SettingsRestricted.js +4 -4
- package/dist/settings/SettingsShell.d.ts +7 -0
- package/dist/settings/SettingsShell.js +6 -1
- package/dist/settings/headless/fixture-performance.d.ts +1 -1
- package/dist/settings/headless/host.d.ts +2 -2
- package/dist/settings/headless/labels.d.ts +3 -3
- package/dist/settings/headless/labels.js +3 -3
- package/dist/settings/headless/performance.d.ts +3 -4
- package/dist/settings/headless/search.d.ts +1 -1
- package/dist/settings/index.d.ts +2 -1
- package/dist/settings/index.js +2 -1
- package/dist/settings/sections/editor/EditorSection.js +7 -4
- package/dist/settings/sections/editor/labels.d.ts +1 -0
- package/dist/settings/sections/editor/labels.js +1 -0
- package/dist/settings/sections/environments/EnvironmentsSection.js +19 -12
- package/dist/settings/sections/environments/labels.d.ts +1 -0
- package/dist/settings/sections/environments/labels.js +2 -1
- package/dist/settings/sections/extensions/ExtensionConfigRows.d.ts +1 -3
- package/dist/settings/sections/extensions/ExtensionConfigRows.js +20 -19
- package/dist/settings/sections/extensions/ExtensionOptionsSection.js +2 -1
- package/dist/settings/sections/extensions/options-labels.d.ts +2 -1
- package/dist/settings/sections/extensions/options-labels.js +2 -1
- package/dist/settings/sections/index.d.ts +2 -1
- package/dist/settings/sections/index.js +2 -1
- package/dist/settings/sections/logs/LogsSection.d.ts +2 -2
- package/dist/settings/sections/logs/LogsSection.js +2 -2
- package/dist/settings/sections/mcp/McpSection.d.ts +1 -1
- package/dist/settings/sections/mcp/McpSection.js +12 -6
- package/dist/settings/sections/mcp/McpServerRow.js +20 -13
- package/dist/settings/sections/mcp/labels.d.ts +8 -2
- package/dist/settings/sections/mcp/labels.js +8 -2
- package/dist/settings/sections/models/ModelRows.js +1 -1
- package/dist/settings/sections/models/NewChatPlaceRow.d.ts +26 -0
- package/dist/settings/sections/models/NewChatPlaceRow.js +78 -0
- package/dist/settings/sections/models/SpacesDefaultsSection.js +15 -3
- package/dist/settings/sections/models/labels.d.ts +7 -0
- package/dist/settings/sections/models/labels.js +7 -0
- package/dist/settings/sections/models/model-test.js +7 -4
- package/dist/settings/sections/performance/PerformanceSection.js +16 -6
- package/dist/settings/sections/performance/labels.d.ts +1 -1
- package/dist/settings/sections/performance/labels.js +1 -1
- package/dist/settings/sections/providers/ProvidersSection.d.ts +1 -1
- package/dist/settings/sections/providers/ProvidersSection.js +14 -7
- package/dist/settings/sections/providers/ServerProvidersSection.d.ts +1 -1
- package/dist/settings/sections/providers/ServerProvidersSection.js +11 -5
- package/dist/settings/sections/providers/labels.d.ts +2 -2
- package/dist/settings/sections/providers/labels.js +2 -2
- package/dist/settings/sections/skills/SkillList.js +1 -1
- package/dist/settings/sections/skills/SkillsSection.js +1 -1
- package/dist/settings/testing/performance.contract.js +8 -12
- package/dist/styles.css +32 -3
- package/dist/terminal/HostTerminalSurface.js +15 -5
- package/dist/terminal/TerminalPanel.js +30 -17
- package/dist/terminal/TerminalSurface.js +11 -4
- package/dist/terminal/headless/labels.d.ts +5 -0
- package/dist/terminal/headless/labels.js +5 -0
- package/dist/terminal/headless/store.d.ts +1 -1
- package/dist/terminal/headless/store.js +6 -3
- package/dist/workspace/LayoutBudget.d.ts +5 -1
- package/dist/workspace/LayoutBudget.js +14 -1
- package/dist/workspace/PanelContentView.d.ts +1 -1
- package/dist/workspace/PanelContentView.js +17 -6
- package/dist/workspace/WorkspaceProvider.js +3 -2
- package/dist/workspace/headless/labels.d.ts +1 -0
- package/dist/workspace/headless/labels.js +1 -0
- package/package.json +3 -3
- package/src/styles/motion.css +8 -0
- package/src/styles/primitives.css +7 -0
package/dist/core.css
CHANGED
|
@@ -28,7 +28,6 @@
|
|
|
28
28
|
.i-ph-text-align-left{--un-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 256 256' height='1em' width='1em' display='inline-block' vertical-align='middle' xmlns='http://www.w3.org/2000/svg' %3E%3Cpath fill='currentColor' d='M32 64a8 8 0 0 1 8-8h176a8 8 0 0 1 0 16H40a8 8 0 0 1-8-8m8 48h128a8 8 0 0 0 0-16H40a8 8 0 0 0 0 16m176 24H40a8 8 0 0 0 0 16h176a8 8 0 0 0 0-16m-48 40H40a8 8 0 0 0 0 16h128a8 8 0 0 0 0-16'/%3E%3C/svg%3E");-webkit-mask:var(--un-icon) no-repeat;mask:var(--un-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;height:1em;width:1em;display:inline-block;vertical-align:middle;}
|
|
29
29
|
.i-ph-warning{--un-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 256 256' height='1em' width='1em' display='inline-block' vertical-align='middle' xmlns='http://www.w3.org/2000/svg' %3E%3Cpath fill='currentColor' d='M236.8 188.09L149.35 36.22a24.76 24.76 0 0 0-42.7 0L19.2 188.09a23.51 23.51 0 0 0 0 23.72A24.35 24.35 0 0 0 40.55 224h174.9a24.35 24.35 0 0 0 21.33-12.19a23.51 23.51 0 0 0 .02-23.72m-13.87 15.71a8.5 8.5 0 0 1-7.48 4.2H40.55a8.5 8.5 0 0 1-7.48-4.2a7.59 7.59 0 0 1 0-7.72l87.45-151.87a8.75 8.75 0 0 1 15 0l87.45 151.87a7.59 7.59 0 0 1-.04 7.72M120 144v-40a8 8 0 0 1 16 0v40a8 8 0 0 1-16 0m20 36a12 12 0 1 1-12-12a12 12 0 0 1 12 12'/%3E%3C/svg%3E");-webkit-mask:var(--un-icon) no-repeat;mask:var(--un-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;height:1em;width:1em;display:inline-block;vertical-align:middle;}
|
|
30
30
|
.i-ph-warning-circle{--un-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 256 256' height='1em' width='1em' display='inline-block' vertical-align='middle' xmlns='http://www.w3.org/2000/svg' %3E%3Cpath fill='currentColor' d='M128 24a104 104 0 1 0 104 104A104.11 104.11 0 0 0 128 24m0 192a88 88 0 1 1 88-88a88.1 88.1 0 0 1-88 88m-8-80V80a8 8 0 0 1 16 0v56a8 8 0 0 1-16 0m20 36a12 12 0 1 1-12-12a12 12 0 0 1 12 12'/%3E%3C/svg%3E");-webkit-mask:var(--un-icon) no-repeat;mask:var(--un-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;height:1em;width:1em;display:inline-block;vertical-align:middle;}
|
|
31
|
-
.i-ph-warning-circle-fill{--un-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 256 256' height='1em' width='1em' display='inline-block' vertical-align='middle' xmlns='http://www.w3.org/2000/svg' %3E%3Cpath fill='currentColor' d='M128 24a104 104 0 1 0 104 104A104.11 104.11 0 0 0 128 24m-8 56a8 8 0 0 1 16 0v56a8 8 0 0 1-16 0Zm8 104a12 12 0 1 1 12-12a12 12 0 0 1-12 12'/%3E%3C/svg%3E");-webkit-mask:var(--un-icon) no-repeat;mask:var(--un-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;height:1em;width:1em;display:inline-block;vertical-align:middle;}
|
|
32
31
|
.i-ph-x{--un-icon:url("data:image/svg+xml;utf8,%3Csvg viewBox='0 0 256 256' height='1em' width='1em' display='inline-block' vertical-align='middle' xmlns='http://www.w3.org/2000/svg' %3E%3Cpath fill='currentColor' d='M205.66 194.34a8 8 0 0 1-11.32 11.32L128 139.31l-66.34 66.35a8 8 0 0 1-11.32-11.32L116.69 128L50.34 61.66a8 8 0 0 1 11.32-11.32L128 116.69l66.34-66.35a8 8 0 0 1 11.32 11.32L139.31 128Z'/%3E%3C/svg%3E");-webkit-mask:var(--un-icon) no-repeat;mask:var(--un-icon) no-repeat;-webkit-mask-size:100% 100%;mask-size:100% 100%;background-color:currentColor;color:inherit;height:1em;width:1em;display:inline-block;vertical-align:middle;}
|
|
33
32
|
/* layer: shortcuts */
|
|
34
33
|
.container{width:100%;}
|
|
@@ -87,6 +86,7 @@
|
|
|
87
86
|
.m4\.7144{margin:1.1786rem;}
|
|
88
87
|
.-mx-1{margin-left:-0.25rem;margin-right:-0.25rem;}
|
|
89
88
|
.-mx-2{margin-left:-0.5rem;margin-right:-0.5rem;}
|
|
89
|
+
.mx-3{margin-left:0.75rem;margin-right:0.75rem;}
|
|
90
90
|
.my-2{margin-top:0.5rem;margin-bottom:0.5rem;}
|
|
91
91
|
.my-auto{margin-top:auto;margin-bottom:auto;}
|
|
92
92
|
.-ml-2{margin-left:-0.5rem;}
|
|
@@ -107,6 +107,7 @@
|
|
|
107
107
|
.ml-auto{margin-left:auto;}
|
|
108
108
|
.ms{margin-inline-start:1rem;}
|
|
109
109
|
.mt-\[13vh\]{margin-top:13vh;}
|
|
110
|
+
.mt-\[2px\]{margin-top:2px;}
|
|
110
111
|
.mt-0\.5{margin-top:0.125rem;}
|
|
111
112
|
.mt-1{margin-top:0.25rem;}
|
|
112
113
|
.mt-1\.5{margin-top:0.375rem;}
|
|
@@ -196,6 +197,7 @@
|
|
|
196
197
|
.cursor-text{cursor:text;}
|
|
197
198
|
.cursor-grabbing{cursor:grabbing;}
|
|
198
199
|
.select-text{-webkit-user-select:text;user-select:text;}
|
|
200
|
+
.select-none{-webkit-user-select:none;user-select:none;}
|
|
199
201
|
.resize-y{resize:vertical;}
|
|
200
202
|
.resize{resize:both;}
|
|
201
203
|
.list-none{list-style-type:none;}
|
|
@@ -220,6 +222,8 @@
|
|
|
220
222
|
.gap-3\.5{gap:0.875rem;}
|
|
221
223
|
.gap-4{gap:1rem;}
|
|
222
224
|
.gap-6{gap:1.5rem;}
|
|
225
|
+
.gap-x-2{column-gap:0.5rem;}
|
|
226
|
+
.gap-y-1{row-gap:0.25rem;}
|
|
223
227
|
.space-y-3>:not([hidden])~:not([hidden]){--un-space-y-reverse:0;margin-top:calc(0.75rem * calc(1 - var(--un-space-y-reverse)));margin-bottom:calc(0.75rem * var(--un-space-y-reverse));}
|
|
224
228
|
.space-y-5>:not([hidden])~:not([hidden]){--un-space-y-reverse:0;margin-top:calc(1.25rem * calc(1 - var(--un-space-y-reverse)));margin-bottom:calc(1.25rem * var(--un-space-y-reverse));}
|
|
225
229
|
.divide-y>:not([hidden])~:not([hidden]){--un-divide-y-reverse:0;border-top-width:calc(1px * calc(1 - var(--un-divide-y-reverse)));border-bottom-width:calc(1px * var(--un-divide-y-reverse));}
|
|
@@ -352,17 +356,15 @@
|
|
|
352
356
|
.text-\[var\(--zg-accent\)\]{color:var(--zg-accent);}
|
|
353
357
|
.text-\[var\(--zg-bg\)\]{color:var(--zg-bg);}
|
|
354
358
|
.text-\[var\(--zg-code-fg\)\]{color:var(--zg-code-fg);}
|
|
355
|
-
.text-\[var\(--zg-danger\)\],
|
|
356
|
-
.text-zg-danger{color:var(--zg-danger);}
|
|
357
359
|
.text-\[var\(--zg-text-muted\)\],
|
|
358
360
|
.text-zg-muted{color:var(--zg-text-muted);}
|
|
359
361
|
.text-\[var\(--zg-text-subtle\)\]{color:var(--zg-text-subtle);}
|
|
360
362
|
.text-\[var\(--zg-text\)\]{color:var(--zg-text);}
|
|
361
|
-
.text-\[var\(--zg-warn\)\],
|
|
362
|
-
.text-zg-warn{color:var(--zg-warn);}
|
|
363
363
|
.text-zg-accent-fill-fg{color:var(--zg-accent-fill-fg);}
|
|
364
|
+
.text-zg-danger{color:var(--zg-danger);}
|
|
364
365
|
.text-zg-info{color:var(--zg-info);}
|
|
365
366
|
.text-zg-success{color:var(--zg-success);}
|
|
367
|
+
.text-zg-warn{color:var(--zg-warn);}
|
|
366
368
|
.hover\:\!text-zg-danger:hover{color:var(--zg-danger) !important;}
|
|
367
369
|
.hover\:text-\[var\(--zg-text\)\]:hover{color:var(--zg-text);}
|
|
368
370
|
.placeholder\:text-\[var\(--zg-text-subtle\)\]::placeholder{color:var(--zg-text-subtle);}
|
|
@@ -427,6 +429,8 @@
|
|
|
427
429
|
.z-zg-overlay{z-index:var(--zg-z-overlay);}
|
|
428
430
|
.z-zg-tooltip{z-index:var(--zg-z-tooltip);}
|
|
429
431
|
.bg-zg-danger\/10{background-color:color-mix(in srgb, var(--zg-danger) 10%, transparent);}
|
|
432
|
+
.bg-zg-info\/10{background-color:color-mix(in srgb, var(--zg-info) 10%, transparent);}
|
|
433
|
+
.bg-zg-warn\/10{background-color:color-mix(in srgb, var(--zg-warn) 10%, transparent);}
|
|
430
434
|
.hover\:before\:bg-zg-danger\/10:hover::before{background-color:color-mix(in srgb, var(--zg-danger) 10%, transparent);}
|
|
431
435
|
@media (min-width: 640px){
|
|
432
436
|
.sm\:grid-cols-2{grid-template-columns:repeat(2,minmax(0,1fr));}
|
|
@@ -1054,6 +1058,13 @@ html[data-motion='off'] {
|
|
|
1054
1058
|
padding: 6px 10px;
|
|
1055
1059
|
align-items: flex-start;
|
|
1056
1060
|
}
|
|
1061
|
+
/* A row that belongs to the row above it (a server's machines): one glyph column in. */
|
|
1062
|
+
.zg-menu-row.zg-menu-row-nested {
|
|
1063
|
+
padding-left: 26px;
|
|
1064
|
+
}
|
|
1065
|
+
.zg-menu-row.zg-menu-row-nested[data-size='lg'] {
|
|
1066
|
+
padding-left: 28px;
|
|
1067
|
+
}
|
|
1057
1068
|
.zg-menu-row:hover:not(:disabled) {
|
|
1058
1069
|
background: var(--zg-row-hover);
|
|
1059
1070
|
}
|
|
@@ -1688,6 +1699,14 @@ html[data-motion='reduced'] .zg-shimmer {
|
|
|
1688
1699
|
opacity var(--zg-motion-fade),
|
|
1689
1700
|
margin-left var(--zg-motion-settle);
|
|
1690
1701
|
}
|
|
1702
|
+
/* `Grow symmetric`: leaving on the curve it arrived on, so a row shrinking out
|
|
1703
|
+
as another grows in mirrors it exactly and the list's height holds. */
|
|
1704
|
+
.zg-grow[data-symmetric]:not([data-shown]) {
|
|
1705
|
+
transition:
|
|
1706
|
+
grid-template-rows var(--zg-motion-settle),
|
|
1707
|
+
opacity var(--zg-motion-fade-out),
|
|
1708
|
+
margin-left var(--zg-motion-settle);
|
|
1709
|
+
}
|
|
1691
1710
|
.zg-grow-clip {
|
|
1692
1711
|
min-height: 0;
|
|
1693
1712
|
overflow-x: visible;
|
|
@@ -6,7 +6,7 @@ import "../node_modules/.bun/@earendil-works_pi-ai@1.3.0_bff1df87cb190f90/node_m
|
|
|
6
6
|
import "../node_modules/.bun/@anthropic-ai_sdk@0.104.2_fff7ddf946fac095/node_modules/@anthropic-ai/sdk/index.js";
|
|
7
7
|
import "../node_modules/.bun/@anthropic-ai_sdk@0.104.2_fff7ddf946fac095/node_modules/@anthropic-ai/sdk/resources2.js";
|
|
8
8
|
import { ReactNode } from "react";
|
|
9
|
-
//#region ../dist/index-
|
|
9
|
+
//#region ../dist/index-BZM8tu4L.d.ts
|
|
10
10
|
//#endregion
|
|
11
11
|
//#region src/thinking-levels.d.ts
|
|
12
12
|
/**
|
|
@@ -51,6 +51,23 @@ interface EnvironmentSettings {
|
|
|
51
51
|
config?: Record<string, Record<string, EnvironmentConfigValue>>;
|
|
52
52
|
}
|
|
53
53
|
//#endregion
|
|
54
|
+
//#region src/chat/places.d.ts
|
|
55
|
+
/** Where new chats start. */
|
|
56
|
+
interface NewChatPlace {
|
|
57
|
+
/** `local` (This computer) or a saved server's id (its own `hostId`). */
|
|
58
|
+
hostId: string;
|
|
59
|
+
/** The server's name when the place was set: shown on a device that has not saved it. */
|
|
60
|
+
hostName?: string;
|
|
61
|
+
/** The server's URL when the place was set: offered to a device that has not saved it. */
|
|
62
|
+
hostUrl?: string;
|
|
63
|
+
/** One of the host's machines, by name. Absent: the host itself. */
|
|
64
|
+
machine?: string;
|
|
65
|
+
/** A folder on the host, or on the machine. Absent: the usual folder (the host's first root, the machine's first folder). */
|
|
66
|
+
folder?: string;
|
|
67
|
+
/** The isolation, without a machine (`local`, `worktree`, `docker`…). Absent: the host's default. */
|
|
68
|
+
isolation?: string;
|
|
69
|
+
}
|
|
70
|
+
//#endregion
|
|
54
71
|
//#region src/chat/ansi.d.ts
|
|
55
72
|
/**
|
|
56
73
|
* Terminal output as styled lines: ANSI SGR codes (colors, bold, dim, italic,
|
|
@@ -179,7 +196,7 @@ type QueryBound = number | string;
|
|
|
179
196
|
* session without an environment. `projectName` is computed: the folder name
|
|
180
197
|
* (last path segment) of `projectRoot`, or of `cwd` without one.
|
|
181
198
|
*/
|
|
182
|
-
type SessionFieldName = 'id' | 'title' | 'projectRoot' | 'projectName' | 'cwd' | 'agentId' | 'status' | 'createdAt' | 'updatedAt' | 'runStartedAt' | 'archived' | 'favorite' | 'isMain' | 'spaceId' | 'scheduleId' | 'providerKey' | 'modelId' | 'account' | 'effort' | 'hostId' | 'repoKey' | 'environment.kind' | 'environment.state' | 'environment.branch' | 'wakes';
|
|
199
|
+
type SessionFieldName = 'id' | 'title' | 'projectRoot' | 'projectName' | 'cwd' | 'agentId' | 'status' | 'createdAt' | 'updatedAt' | 'lastUserMessageAt' | 'runStartedAt' | 'archived' | 'favorite' | 'isMain' | 'spaceId' | 'scheduleId' | 'providerKey' | 'modelId' | 'account' | 'effort' | 'hostId' | 'repoKey' | 'environment.kind' | 'environment.state' | 'environment.branch' | 'wakes';
|
|
183
200
|
/**
|
|
184
201
|
* A facet an extension computes for each session: `facet.<extensionId>.<key>`,
|
|
185
202
|
* optionally followed by `.<property>` steps into an object value (a number
|
|
@@ -296,6 +313,8 @@ interface Space {
|
|
|
296
313
|
modelOptions?: Record<string, boolean>;
|
|
297
314
|
/** Agent new sessions in this space start on (`AgentProfile.id`); absent = the global default (`Settings.defaultAgent`). */
|
|
298
315
|
agentId?: string;
|
|
316
|
+
/** Where new chats in this space start (a host, a machine, a folder, an isolation); absent = the global default (`Settings.defaultPlace`). */
|
|
317
|
+
place?: NewChatPlace;
|
|
299
318
|
/**
|
|
300
319
|
* A query space (an extension's, or a view the user saved): the sessions
|
|
301
320
|
* it lists besides those stamped with its id. Absent: only those.
|
|
@@ -773,6 +792,12 @@ interface Settings {
|
|
|
773
792
|
* Offline) before it stops with a notice. Unset → 15.
|
|
774
793
|
*/
|
|
775
794
|
machineWaitMinutes?: number;
|
|
795
|
+
/**
|
|
796
|
+
* Where new chats start (`places.ts`): This computer, a saved server, one
|
|
797
|
+
* of its machines, a folder and an isolation. A space's own place wins
|
|
798
|
+
* (`Space.place`). Unset → This computer.
|
|
799
|
+
*/
|
|
800
|
+
defaultPlace?: NewChatPlace | null;
|
|
776
801
|
/**
|
|
777
802
|
* Session environments — which kinds are offered at creation, the
|
|
778
803
|
* default, and each kind's options (secrets live in the environment
|
|
@@ -1489,4 +1514,4 @@ interface Settings {
|
|
|
1489
1514
|
activeIcon: string;
|
|
1490
1515
|
}
|
|
1491
1516
|
//#endregion
|
|
1492
|
-
export {
|
|
1517
|
+
export { SessionQueryAll as Ab, AnsiColor as CT, SessionFieldName as Cb, ToolCallDisplay as Cf, SessionGroupOrder as Db, AnsiStyle as ET, SessionGroupBy as Eb, SessionQueryNot as Fb, SessionSort as Lb, Space as Mf, NewChatPlace as NT, SpaceIcon as Nf, ScriptLineProgress as Qw, SessionCondition as Sb, AnsiSpan as TT, ScriptCallStatus as Zw, OutputStream as bT, QueryBound as bb, Settings as bf, ScriptProgress as iT, EditDiffDisplay as if, SessionQueryAny as jb, EnvironmentConfigValue as kD, SessionQuery as kb, InteractionMode as lf, OpenInTarget as pf, DurabilityMode as rO, ScriptOutputLine as rT, ApprovalMode as rf, ThinkingLevel as rz, SecretTtl as tw, EnvironmentSettings as uD, MessageDelivery as uf, SessionFieldPath as wb, TranscriptDensity as wf, QueryValue as xb, OutputLine as yT, FacetPath as yb };
|
package/dist/dist/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { d as AuthFailureKind, u as AuthFailure } from "./timeout-
|
|
1
|
+
import { d as AuthFailureKind, u as AuthFailure } from "./timeout-Cyx3VGPz.js";
|
|
2
2
|
import "./types-2HrgolQz.js";
|
|
3
3
|
import "./oauth-callback-page-DMxIgurj.js";
|
|
4
|
-
import {
|
|
4
|
+
import { Ab as SessionQueryAll, Cb as SessionFieldName, Db as SessionGroupOrder, Eb as SessionGroupBy, Fb as SessionQueryNot, Lb as SessionSort, Sb as SessionCondition, bb as QueryBound, jb as SessionQueryAny, kb as SessionQuery, rz as ThinkingLevel, wb as SessionFieldPath, xb as QueryValue, yb as FacetPath } from "./index-BZM8tu4L.js";
|
|
5
5
|
import "./index-f-XWIoYo.js";
|
|
6
6
|
import "./sandbox-B4OW6oNx.js";
|
|
@@ -17,7 +17,6 @@ import { useCallback, useMemo, useState } from "react";
|
|
|
17
17
|
* `invoke('setting.action')`. Without `settings.set` the rows are read-only.
|
|
18
18
|
*/
|
|
19
19
|
const NO_SETTINGS = constant(null);
|
|
20
|
-
const NOT_LIMITED = constant(null);
|
|
21
20
|
/**
|
|
22
21
|
* Draws one extension settings page. Draws nothing when no extension offers `id`.
|
|
23
22
|
*
|
|
@@ -28,7 +27,6 @@ function ExtensionSettingsPage({ id, className, style }) {
|
|
|
28
27
|
const labels = useExtensionsLabels();
|
|
29
28
|
const entry = useExtensionItems("settings-page").find((e) => e.item.id === id);
|
|
30
29
|
const live = useReadable(host?.settings?.wire ?? NO_SETTINGS);
|
|
31
|
-
const scope = useReadable(host?.scope ?? NOT_LIMITED);
|
|
32
30
|
const [errors, setErrors] = useState({});
|
|
33
31
|
const [actions, setActions] = useState({});
|
|
34
32
|
const schema = entry?.item.schema;
|
|
@@ -98,8 +96,7 @@ function ExtensionSettingsPage({ id, className, style }) {
|
|
|
98
96
|
onChange,
|
|
99
97
|
onRunAction: invoke ? onRunAction : void 0,
|
|
100
98
|
actionStates: actions,
|
|
101
|
-
errors
|
|
102
|
-
scope
|
|
99
|
+
errors
|
|
103
100
|
}) : null;
|
|
104
101
|
return /* @__PURE__ */ jsx("div", {
|
|
105
102
|
className,
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { Notice } from "../components/Notice.js";
|
|
1
2
|
import { useReadable } from "../chat/headless/store.js";
|
|
2
3
|
import { extensionsErrorOf } from "./headless/host.js";
|
|
3
4
|
import { useExtensionsLabels } from "./useExtensionsLabels.js";
|
|
@@ -133,9 +134,9 @@ function IntegrationRow({ integration }) {
|
|
|
133
134
|
onClick: () => run(() => host?.integrations?.connect(integration.id, { methodId: method.id })),
|
|
134
135
|
children: connected ? l.extensionIntegrationAddAccountWith(method.label) : method.label
|
|
135
136
|
}, method.id)),
|
|
136
|
-
error && /* @__PURE__ */ jsx(
|
|
137
|
-
|
|
138
|
-
|
|
137
|
+
error && /* @__PURE__ */ jsx(Notice, {
|
|
138
|
+
tone: "error",
|
|
139
|
+
compact: true,
|
|
139
140
|
children: error
|
|
140
141
|
})
|
|
141
142
|
]
|
|
@@ -41,11 +41,9 @@ import { extensionMark, settingsSearchIndex, settingsSidebar } from "zidane/chat
|
|
|
41
41
|
* <SettingsShell sections={[...builtins, ...ext.entries, ...ext.categories]} extraSearch={ext.search} />
|
|
42
42
|
*
|
|
43
43
|
* Rows write through the host's `settings.set` and actions run through
|
|
44
|
-
* `invoke('setting.action')
|
|
45
|
-
* (`ExtensionsHost.scope`) shows disabled, with why.
|
|
44
|
+
* `invoke('setting.action')`.
|
|
46
45
|
*/
|
|
47
46
|
const EMPTY = constant(null);
|
|
48
|
-
const NOT_LIMITED = constant(null);
|
|
49
47
|
/** A section's glyph: the first icon given, else a letter badge of `monogram`. */
|
|
50
48
|
function glyph(monogram, ...icons) {
|
|
51
49
|
const icon = icons.find((candidate) => candidate?.trim());
|
|
@@ -230,7 +228,6 @@ function SchemaPage({ page, className, style }) {
|
|
|
230
228
|
const host = useExtensionsHost();
|
|
231
229
|
const labels = useExtensionsLabels();
|
|
232
230
|
const wire = useReadable(host?.settings?.wire ?? EMPTY);
|
|
233
|
-
const scope = useReadable(host?.scope ?? NOT_LIMITED);
|
|
234
231
|
const [errors, setErrors] = useState({});
|
|
235
232
|
const [actions, setActions] = useState({});
|
|
236
233
|
const parts = useMemo(() => wire ? pageWires(wire, page) : null, [wire, page]);
|
|
@@ -277,8 +274,7 @@ function SchemaPage({ page, className, style }) {
|
|
|
277
274
|
onChange,
|
|
278
275
|
onRunAction: invoke ? onRunAction : void 0,
|
|
279
276
|
actionStates: actions,
|
|
280
|
-
errors
|
|
281
|
-
scope
|
|
277
|
+
errors
|
|
282
278
|
}, key);
|
|
283
279
|
return /* @__PURE__ */ jsx("div", {
|
|
284
280
|
className: ["space-y-5", className].filter(Boolean).join(" "),
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { WireSettings } from "./headless/wire.js";
|
|
2
|
-
import { ExtensionAccessScope } from "./headless/host.js";
|
|
3
2
|
import { SettingValue } from "./headless/select.js";
|
|
4
3
|
import { CSSProperties } from "react";
|
|
5
4
|
//#region src/extensions/SettingsWireForm.d.ts
|
|
@@ -24,11 +23,6 @@ interface SettingsWireFormProps {
|
|
|
24
23
|
actionStates?: Readonly<Record<string, SettingsWireActionState>>;
|
|
25
24
|
/** A message per row (a refused write), by `extension:key`. */
|
|
26
25
|
errors?: Readonly<Record<string, string>>;
|
|
27
|
-
/**
|
|
28
|
-
* The scope this client's token grants (`ExtensionsHost.scope`): an action needing more shows its
|
|
29
|
-
* button disabled, with why. `null` or absent: never limited (a local or in-process host).
|
|
30
|
-
*/
|
|
31
|
-
scope?: ExtensionAccessScope | null;
|
|
32
26
|
/** Extra classes on the root. */
|
|
33
27
|
className?: string;
|
|
34
28
|
/** Inline styles on the root. */
|
|
@@ -39,6 +33,6 @@ interface SettingsWireFormProps {
|
|
|
39
33
|
*
|
|
40
34
|
* @param props - The rows, their values, the change and action handlers, `className` and `style`.
|
|
41
35
|
*/
|
|
42
|
-
declare function SettingsWireForm({ settings, values, onChange, onRunAction, actionStates, errors,
|
|
36
|
+
declare function SettingsWireForm({ settings, values, onChange, onRunAction, actionStates, errors, className, style }: SettingsWireFormProps): import("react").JSX.Element;
|
|
43
37
|
//#endregion
|
|
44
38
|
export { SettingsWireActionState, SettingsWireForm, SettingsWireFormProps };
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
+
import { Notice } from "../components/Notice.js";
|
|
1
2
|
import { FormSection, MetaChip } from "../components/Form.js";
|
|
2
3
|
import { useExtensionsLabels } from "./useExtensionsLabels.js";
|
|
3
|
-
import { isSettingLocked
|
|
4
|
+
import { isSettingLocked } from "./headless/select.js";
|
|
4
5
|
import { SettingFocus } from "../settings/section.js";
|
|
5
6
|
import { ExtensionActionRow, ExtensionConfigRow } from "../settings/sections/extensions/ExtensionConfigRows.js";
|
|
6
7
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
@@ -30,7 +31,7 @@ function categories(settings) {
|
|
|
30
31
|
*
|
|
31
32
|
* @param props - The rows, their values, the change and action handlers, `className` and `style`.
|
|
32
33
|
*/
|
|
33
|
-
function SettingsWireForm({ settings, values, onChange, onRunAction, actionStates, errors,
|
|
34
|
+
function SettingsWireForm({ settings, values, onChange, onRunAction, actionStates, errors, className, style }) {
|
|
34
35
|
const labels = useExtensionsLabels();
|
|
35
36
|
const cats = categories(settings);
|
|
36
37
|
if (cats.length === 0) return /* @__PURE__ */ jsx("p", {
|
|
@@ -53,8 +54,10 @@ function SettingsWireForm({ settings, values, onChange, onRunAction, actionState
|
|
|
53
54
|
value,
|
|
54
55
|
locked: isSettingLocked(settings, item.extension, item.key),
|
|
55
56
|
onChange
|
|
56
|
-
}), errors?.[id] && /* @__PURE__ */ jsx(
|
|
57
|
-
|
|
57
|
+
}), errors?.[id] && /* @__PURE__ */ jsx(Notice, {
|
|
58
|
+
tone: "error",
|
|
59
|
+
compact: true,
|
|
60
|
+
className: "mx-3 mb-1.5",
|
|
58
61
|
children: errors[id]
|
|
59
62
|
})]
|
|
60
63
|
}, id);
|
|
@@ -71,7 +74,6 @@ function SettingsWireForm({ settings, values, onChange, onRunAction, actionState
|
|
|
71
74
|
error: run.state === "error"
|
|
72
75
|
} } : {},
|
|
73
76
|
busy: run?.state === "busy",
|
|
74
|
-
needsScope: missingScope(scope, action.scope),
|
|
75
77
|
onRun: () => onRunAction(action.extension, action.key)
|
|
76
78
|
})
|
|
77
79
|
}, id);
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { DialogRequestWire, ExtensionItem, ExtensionTokenName, ExtensionWireMap } from "./wire.js";
|
|
2
|
-
import {
|
|
2
|
+
import { ExtensionCallbackId, ExtensionCallbacks, ExtensionCommandWire, ExtensionIntegrationWire, ExtensionLinkRequest, ExtensionPanelChange, ExtensionSettingsWire, ExtensionStoreRef, ExtensionUiEffect, ExtensionsHost } from "./host.js";
|
|
3
3
|
import { DialogQueueShowContext } from "./dialog-queue.js";
|
|
4
4
|
import { ExtensionUiEffectResult } from "./effect-channel.js";
|
|
5
5
|
//#region src/extensions/headless/fixture-host.d.ts
|
|
@@ -44,8 +44,6 @@ interface FixtureExtensionsOptions {
|
|
|
44
44
|
capabilities?: readonly FixtureExtensionsCapability[];
|
|
45
45
|
/** The link handlers: whether one opens a link. Absent: no `openLink` (links open the app's way). */
|
|
46
46
|
openLink?: (request: ExtensionLinkRequest) => boolean | Promise<boolean>;
|
|
47
|
-
/** The scope the client's token grants. Absent: no `scope` (never limited). */
|
|
48
|
-
scope?: ExtensionAccessScope | null;
|
|
49
47
|
}
|
|
50
48
|
/** Drives a fixture host from outside, as the extensions behind it would. */
|
|
51
49
|
interface FixtureExtensionsControl {
|
|
@@ -78,8 +76,6 @@ interface FixtureExtensionsControl {
|
|
|
78
76
|
panelChanged(change: ExtensionPanelChange): void;
|
|
79
77
|
/** The links offered to the link handlers so far. */
|
|
80
78
|
links(): readonly ExtensionLinkRequest[];
|
|
81
|
-
/** Changes the token's scope (with `scope` given). */
|
|
82
|
-
setScope(next: ExtensionAccessScope | null): void;
|
|
83
79
|
}
|
|
84
80
|
/** An in-memory {@link ExtensionsHost} and its control. */
|
|
85
81
|
type FixtureExtensionsHost = ExtensionsHost & {
|
|
@@ -74,14 +74,12 @@ function createFixtureExtensionsHost(options = {}) {
|
|
|
74
74
|
const goodKey = options.goodKey ?? "good-key";
|
|
75
75
|
const panelListeners = /* @__PURE__ */ new Set();
|
|
76
76
|
const links = [];
|
|
77
|
-
const scope = writable(options.scope ?? null);
|
|
78
77
|
const host = { items: lists };
|
|
79
78
|
const openLink = options.openLink;
|
|
80
79
|
if (openLink) host.openLink = async (request) => {
|
|
81
80
|
links.push(request);
|
|
82
81
|
return openLink(request);
|
|
83
82
|
};
|
|
84
|
-
if (options.scope !== void 0) host.scope = scope;
|
|
85
83
|
if (has("invoke")) host.invoke = async (id, args) => {
|
|
86
84
|
invoked.push({
|
|
87
85
|
id,
|
|
@@ -233,8 +231,7 @@ function createFixtureExtensionsHost(options = {}) {
|
|
|
233
231
|
panelChanged: (change) => {
|
|
234
232
|
for (const listener of [...panelListeners]) listener(change);
|
|
235
233
|
},
|
|
236
|
-
links: () => links
|
|
237
|
-
setScope: (next) => scope.set(next)
|
|
234
|
+
links: () => links
|
|
238
235
|
}
|
|
239
236
|
};
|
|
240
237
|
}
|
|
@@ -377,11 +377,6 @@ interface ExtensionLinkRequest {
|
|
|
377
377
|
/** The session it was clicked in. */
|
|
378
378
|
sessionId?: string;
|
|
379
379
|
}
|
|
380
|
-
/**
|
|
381
|
-
* The least client token scope that may run something (`chat` ⊂ `approve` ⊂ `admin`): zidane's
|
|
382
|
-
* `AccessScope`, the scope of an action setting.
|
|
383
|
-
*/
|
|
384
|
-
type ExtensionAccessScope = 'chat' | 'admin';
|
|
385
380
|
/** Options of {@link ExtensionsHost.rpc}. */
|
|
386
381
|
interface ExtensionRpcOptions {
|
|
387
382
|
/** The extension whose UI calls: its own contracts count as local (internal methods allowed). */
|
|
@@ -423,11 +418,6 @@ interface ExtensionsHost {
|
|
|
423
418
|
* skips it while Alt is held (`routeLink`). Absent: links open the app's way.
|
|
424
419
|
*/
|
|
425
420
|
openLink?(request: ExtensionLinkRequest): Promise<boolean>;
|
|
426
|
-
/**
|
|
427
|
-
* The scope this client's token grants (`null`: not limited, as a local or in-process host). Action
|
|
428
|
-
* settings above it show disabled with why. Absent: never limited.
|
|
429
|
-
*/
|
|
430
|
-
scope?: Readable<ExtensionAccessScope | null>;
|
|
431
421
|
}
|
|
432
422
|
//#endregion
|
|
433
|
-
export {
|
|
423
|
+
export { ExtensionCallbackId, ExtensionCallbacks, ExtensionCommandWire, ExtensionCommands, ExtensionComposerFile, ExtensionDialog, ExtensionDialogs, ExtensionIntegrationConnectionWire, ExtensionIntegrationWire, ExtensionIntegrations, ExtensionItemStores, ExtensionLinkRequest, ExtensionLinkSource, ExtensionNavigateTarget, ExtensionPanelChange, ExtensionProvenanceWire, ExtensionRpcOptions, ExtensionSettings, ExtensionSettingsWire, ExtensionStorage, ExtensionStoreRef, ExtensionUiEffect, ExtensionUiEffectRequest, ExtensionUiEffects, ExtensionWebviews, ExtensionsError, ExtensionsHost, ExtensionsHostError, extensionsErrorOf };
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { BadgeActionWire, ComponentWire, ContextSectionWire, DialogKind, DialogRequestWire, EXTENSION_TOKENS, ExtensionItem, ExtensionTokenName, ExtensionWireMap, LinkHandlerWire, PanelWire, RendererTarget, RendererWire, SLOT_NAMES, ScreenWire, SelectOptionWire, SettingsPageWire, SidebarDecorationWire, SidebarFilterWire, SidebarGroupWire, SidebarRowActionWire, SidebarRowWire, SidebarSortWire, SlotName, SlotWire, SpaceWire, WebviewWire, WireSettings, WireSettingsPage } from "./wire.js";
|
|
2
|
-
import {
|
|
2
|
+
import { ExtensionCallbackId, ExtensionCallbacks, ExtensionCommandWire, ExtensionCommands, ExtensionComposerFile, ExtensionDialog, ExtensionDialogs, ExtensionIntegrationConnectionWire, ExtensionIntegrationWire, ExtensionIntegrations, ExtensionItemStores, ExtensionLinkRequest, ExtensionLinkSource, ExtensionNavigateTarget, ExtensionPanelChange, ExtensionProvenanceWire, ExtensionRpcOptions, ExtensionSettings, ExtensionSettingsWire, ExtensionStorage, ExtensionStoreRef, ExtensionUiEffect, ExtensionUiEffectRequest, ExtensionUiEffects, ExtensionWebviews, ExtensionsError, ExtensionsHost, ExtensionsHostError, extensionsErrorOf } from "./host.js";
|
|
3
3
|
import { ExtensionEffectApply, ExtensionEffectOutcome, ExtensionEffectRoute, ExtensionEffectRouter, createEffectRouter } from "./effect-router.js";
|
|
4
4
|
import { DEFAULT_EXTENSIONS_LABELS, ExtensionsLabels } from "./labels.js";
|
|
5
|
-
import { SettingValue, TITLEBAR_ITEMS_PER_EXTENSION, clampSettingNumber, filterSelectOptions, groupSelectOptions, isSettingLocked,
|
|
5
|
+
import { SettingValue, TITLEBAR_ITEMS_PER_EXTENSION, clampSettingNumber, filterSelectOptions, groupSelectOptions, isSettingLocked, qualifyPanelId, rendererMatches, renderersFor, settingValue, settingsValues, slotIsActionable, slotItems, titlebarItems } from "./select.js";
|
|
6
6
|
import { DialogQueue, DialogQueueShowContext, createDialogQueue } from "./dialog-queue.js";
|
|
7
7
|
import { ExtensionUiEffectResult, UiEffectChannel, createUiEffectChannel } from "./effect-channel.js";
|
|
8
8
|
import { LinkRouteOptions, openInNewTab, routeLink } from "./links.js";
|
|
9
9
|
import { WEBVIEW_RPC_NOT_ALLOWED, WEBVIEW_RPC_REQUEST, WEBVIEW_RPC_RESULT, WEBVIEW_RPC_UNAVAILABLE, WebviewRpcBridge, WebviewRpcBridgeOptions, WebviewRpcRequest, WebviewRpcResult, createWebviewRpcBridge, isWebviewRpcRequest } from "./webview-bridge.js";
|
|
10
|
-
export { BadgeActionWire, ComponentWire, ContextSectionWire, DEFAULT_EXTENSIONS_LABELS, DialogKind, DialogQueue, DialogQueueShowContext, DialogRequestWire, EXTENSION_TOKENS,
|
|
10
|
+
export { BadgeActionWire, ComponentWire, ContextSectionWire, DEFAULT_EXTENSIONS_LABELS, DialogKind, DialogQueue, DialogQueueShowContext, DialogRequestWire, EXTENSION_TOKENS, ExtensionCallbackId, ExtensionCallbacks, ExtensionCommandWire, ExtensionCommands, ExtensionComposerFile, ExtensionDialog, ExtensionDialogs, ExtensionEffectApply, ExtensionEffectOutcome, ExtensionEffectRoute, ExtensionEffectRouter, ExtensionIntegrationConnectionWire, ExtensionIntegrationWire, ExtensionIntegrations, ExtensionItem, ExtensionItemStores, ExtensionLinkRequest, ExtensionLinkSource, ExtensionNavigateTarget, ExtensionPanelChange, ExtensionProvenanceWire, ExtensionRpcOptions, ExtensionSettings, ExtensionSettingsWire, ExtensionStorage, ExtensionStoreRef, ExtensionTokenName, ExtensionUiEffect, ExtensionUiEffectRequest, ExtensionUiEffectResult, ExtensionUiEffects, ExtensionWebviews, ExtensionWireMap, ExtensionsError, ExtensionsHost, ExtensionsHostError, ExtensionsLabels, LinkHandlerWire, LinkRouteOptions, PanelWire, RendererTarget, RendererWire, SLOT_NAMES, ScreenWire, SelectOptionWire, SettingValue, SettingsPageWire, SidebarDecorationWire, SidebarFilterWire, SidebarGroupWire, SidebarRowActionWire, SidebarRowWire, SidebarSortWire, SlotName, SlotWire, SpaceWire, TITLEBAR_ITEMS_PER_EXTENSION, UiEffectChannel, WEBVIEW_RPC_NOT_ALLOWED, WEBVIEW_RPC_REQUEST, WEBVIEW_RPC_RESULT, WEBVIEW_RPC_UNAVAILABLE, WebviewRpcBridge, WebviewRpcBridgeOptions, WebviewRpcRequest, WebviewRpcResult, WebviewWire, WireSettings, WireSettingsPage, clampSettingNumber, createDialogQueue, createEffectRouter, createUiEffectChannel, createWebviewRpcBridge, extensionsErrorOf, filterSelectOptions, groupSelectOptions, isSettingLocked, isWebviewRpcRequest, openInNewTab, qualifyPanelId, rendererMatches, renderersFor, routeLink, settingValue, settingsValues, slotIsActionable, slotItems, titlebarItems };
|
|
@@ -6,5 +6,5 @@ import { createEffectRouter } from "./effect-router.js";
|
|
|
6
6
|
import { DEFAULT_EXTENSIONS_LABELS } from "./labels.js";
|
|
7
7
|
import { WEBVIEW_RPC_NOT_ALLOWED, WEBVIEW_RPC_REQUEST, WEBVIEW_RPC_RESULT, WEBVIEW_RPC_UNAVAILABLE, createWebviewRpcBridge, isWebviewRpcRequest } from "./webview-bridge.js";
|
|
8
8
|
import { openInNewTab, routeLink } from "./links.js";
|
|
9
|
-
import { TITLEBAR_ITEMS_PER_EXTENSION, clampSettingNumber, filterSelectOptions, groupSelectOptions, isSettingLocked,
|
|
10
|
-
export { DEFAULT_EXTENSIONS_LABELS, EXTENSION_TOKENS, ExtensionsHostError, SLOT_NAMES, TITLEBAR_ITEMS_PER_EXTENSION, WEBVIEW_RPC_NOT_ALLOWED, WEBVIEW_RPC_REQUEST, WEBVIEW_RPC_RESULT, WEBVIEW_RPC_UNAVAILABLE, clampSettingNumber, createDialogQueue, createEffectRouter, createUiEffectChannel, createWebviewRpcBridge, extensionsErrorOf, filterSelectOptions, groupSelectOptions, isSettingLocked, isWebviewRpcRequest,
|
|
9
|
+
import { TITLEBAR_ITEMS_PER_EXTENSION, clampSettingNumber, filterSelectOptions, groupSelectOptions, isSettingLocked, qualifyPanelId, rendererMatches, renderersFor, settingValue, settingsValues, slotIsActionable, slotItems, titlebarItems } from "./select.js";
|
|
10
|
+
export { DEFAULT_EXTENSIONS_LABELS, EXTENSION_TOKENS, ExtensionsHostError, SLOT_NAMES, TITLEBAR_ITEMS_PER_EXTENSION, WEBVIEW_RPC_NOT_ALLOWED, WEBVIEW_RPC_REQUEST, WEBVIEW_RPC_RESULT, WEBVIEW_RPC_UNAVAILABLE, clampSettingNumber, createDialogQueue, createEffectRouter, createUiEffectChannel, createWebviewRpcBridge, extensionsErrorOf, filterSelectOptions, groupSelectOptions, isSettingLocked, isWebviewRpcRequest, openInNewTab, qualifyPanelId, rendererMatches, renderersFor, routeLink, settingValue, settingsValues, slotIsActionable, slotItems, titlebarItems };
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { ExtensionItem, RendererTarget, RendererWire, SelectOptionWire, SlotName, SlotWire, WireSettings } from "./wire.js";
|
|
2
|
-
import { ExtensionAccessScope } from "./host.js";
|
|
3
2
|
import { ExtensionConfigValue, WireExtensionConfigItem } from "zidane";
|
|
4
3
|
//#region src/extensions/headless/select.d.ts
|
|
5
4
|
/**
|
|
@@ -14,15 +13,6 @@ import { ExtensionConfigValue, WireExtensionConfigItem } from "zidane";
|
|
|
14
13
|
* @param turnId - `transcript.turn-end`: the turn the place follows. Absent: the end of the transcript.
|
|
15
14
|
*/
|
|
16
15
|
declare function slotItems(items: readonly ExtensionItem<'slot'>[], at: SlotName, sessionId?: string, turnId?: string): readonly ExtensionItem<'slot'>[];
|
|
17
|
-
/**
|
|
18
|
-
* The scope an action needs that this client's token lacks, or `null` when it may run it: the token
|
|
19
|
-
* grants `granted` (`null` or absent: not limited, as a local or in-process host), the action needs
|
|
20
|
-
* `required` (default `admin`, as zidane's).
|
|
21
|
-
*
|
|
22
|
-
* @param granted - The token's scope (`ExtensionsHost.scope`).
|
|
23
|
-
* @param required - The action's `scope`.
|
|
24
|
-
*/
|
|
25
|
-
declare function missingScope(granted: ExtensionAccessScope | null | undefined, required: ExtensionAccessScope | undefined): ExtensionAccessScope | null;
|
|
26
16
|
/** How many `app.titlebar` items one extension shows: as many as its composer badges. */
|
|
27
17
|
declare const TITLEBAR_ITEMS_PER_EXTENSION = 8;
|
|
28
18
|
/**
|
|
@@ -117,4 +107,4 @@ declare function clampSettingNumber(item: Extract<WireExtensionConfigItem, {
|
|
|
117
107
|
*/
|
|
118
108
|
declare function slotIsActionable(item: SlotWire): boolean;
|
|
119
109
|
//#endregion
|
|
120
|
-
export { SettingValue, TITLEBAR_ITEMS_PER_EXTENSION, clampSettingNumber, filterSelectOptions, groupSelectOptions, isSettingLocked,
|
|
110
|
+
export { SettingValue, TITLEBAR_ITEMS_PER_EXTENSION, clampSettingNumber, filterSelectOptions, groupSelectOptions, isSettingLocked, qualifyPanelId, rendererMatches, renderersFor, settingValue, settingsValues, slotIsActionable, slotItems, titlebarItems };
|
|
@@ -16,23 +16,6 @@ function slotItems(items, at, sessionId, turnId) {
|
|
|
16
16
|
index
|
|
17
17
|
})).sort((a, b) => a.e.item.order - b.e.item.order || a.index - b.index).map((x) => x.e);
|
|
18
18
|
}
|
|
19
|
-
const SCOPE_RANK = {
|
|
20
|
-
chat: 0,
|
|
21
|
-
admin: 1
|
|
22
|
-
};
|
|
23
|
-
/**
|
|
24
|
-
* The scope an action needs that this client's token lacks, or `null` when it may run it: the token
|
|
25
|
-
* grants `granted` (`null` or absent: not limited, as a local or in-process host), the action needs
|
|
26
|
-
* `required` (default `admin`, as zidane's).
|
|
27
|
-
*
|
|
28
|
-
* @param granted - The token's scope (`ExtensionsHost.scope`).
|
|
29
|
-
* @param required - The action's `scope`.
|
|
30
|
-
*/
|
|
31
|
-
function missingScope(granted, required) {
|
|
32
|
-
if (!granted) return null;
|
|
33
|
-
const need = required ?? "admin";
|
|
34
|
-
return SCOPE_RANK[granted] >= SCOPE_RANK[need] ? null : need;
|
|
35
|
-
}
|
|
36
19
|
/** How many `app.titlebar` items one extension shows: as many as its composer badges. */
|
|
37
20
|
const TITLEBAR_ITEMS_PER_EXTENSION = 8;
|
|
38
21
|
/**
|
|
@@ -187,4 +170,4 @@ function slotIsActionable(item) {
|
|
|
187
170
|
return item.panel !== void 0 || item.command !== void 0;
|
|
188
171
|
}
|
|
189
172
|
//#endregion
|
|
190
|
-
export { TITLEBAR_ITEMS_PER_EXTENSION, clampSettingNumber, filterSelectOptions, groupSelectOptions, isSettingLocked,
|
|
173
|
+
export { TITLEBAR_ITEMS_PER_EXTENSION, clampSettingNumber, filterSelectOptions, groupSelectOptions, isSettingLocked, qualifyPanelId, rendererMatches, renderersFor, settingValue, settingsValues, slotIsActionable, slotItems, titlebarItems };
|
|
@@ -85,6 +85,17 @@ const EditorColumn = memo(function EditorColumn({ cwd, files, treeSide, treeOpen
|
|
|
85
85
|
}, [revealAt, navigate]);
|
|
86
86
|
const changed = active && host.workingTreeDiff && !(active.file && active.file !== "missing" && active.file.media) ? hasChanges(active.path) : false;
|
|
87
87
|
const dirty = useIsDirty(files.drafts, active?.path ?? null);
|
|
88
|
+
if (active && dirty && diffOverride[active.path] !== false) setDiffOverride((o) => ({
|
|
89
|
+
...o,
|
|
90
|
+
[active.path]: false
|
|
91
|
+
}));
|
|
92
|
+
const adoptSaved = useCallback((path, file, reset) => {
|
|
93
|
+
if (!reset) setDiffOverride((o) => o[path] === false ? o : {
|
|
94
|
+
...o,
|
|
95
|
+
[path]: false
|
|
96
|
+
});
|
|
97
|
+
adoptFile(path, file, reset);
|
|
98
|
+
}, [adoptFile]);
|
|
88
99
|
const activeFile = active && active.file !== null && active.file !== "missing" ? active.file : null;
|
|
89
100
|
const isNew = active !== null && isNewFile(active.path);
|
|
90
101
|
const smallEnough = useMemo(() => diffFits(activeFile), [activeFile]);
|
|
@@ -317,7 +328,7 @@ const EditorColumn = memo(function EditorColumn({ cwd, files, treeSide, treeOpen
|
|
|
317
328
|
visible: isActive,
|
|
318
329
|
findAsk,
|
|
319
330
|
onDraft: setDraft,
|
|
320
|
-
onAdopt:
|
|
331
|
+
onAdopt: adoptSaved
|
|
321
332
|
})
|
|
322
333
|
}, f.path);
|
|
323
334
|
})
|
package/dist/files/TreeColumn.js
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { IconButton } from "../components/IconButton.js";
|
|
2
|
+
import { Notice } from "../components/Notice.js";
|
|
2
3
|
import { readPanelMs, usePresence } from "../motion/presence.js";
|
|
3
4
|
import { IconToggle } from "../components/IconToggle.js";
|
|
4
5
|
import { PanelEmpty, PanelLoading } from "../components/PanelEmpty.js";
|
|
@@ -159,26 +160,18 @@ const TreeColumn = memo(function TreeColumn(p) {
|
|
|
159
160
|
title: labels.filesTruncated(p.truncated.shown, p.truncated.total, !!p.truncated.atLeast),
|
|
160
161
|
children: labels.filesTruncated(p.truncated.shown, p.truncated.total, !!p.truncated.atLeast)
|
|
161
162
|
}),
|
|
162
|
-
p.notice && !p.search && /* @__PURE__ */
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
}),
|
|
175
|
-
/* @__PURE__ */ jsx(IconButton, {
|
|
176
|
-
size: "xs",
|
|
177
|
-
icon: "i-ph-x",
|
|
178
|
-
label: labels.filesDismiss,
|
|
179
|
-
onClick: () => p.onDismissNotice?.()
|
|
180
|
-
})
|
|
181
|
-
]
|
|
163
|
+
p.notice && !p.search && /* @__PURE__ */ jsx(Notice, {
|
|
164
|
+
tone: "error",
|
|
165
|
+
compact: true,
|
|
166
|
+
className: "shrink-0 mx-2 mb-1",
|
|
167
|
+
action: /* @__PURE__ */ jsx(IconButton, {
|
|
168
|
+
size: "xs",
|
|
169
|
+
icon: "i-ph-x",
|
|
170
|
+
label: labels.filesDismiss,
|
|
171
|
+
onClick: () => p.onDismissNotice?.(),
|
|
172
|
+
className: "ml-auto"
|
|
173
|
+
}),
|
|
174
|
+
children: p.notice
|
|
182
175
|
}),
|
|
183
176
|
p.entries === null ? !p.search && /* @__PURE__ */ jsx(PanelLoading, {}) : p.entries.length === 0 && !(p.editing && !p.changedOnly) ? !p.search && /* @__PURE__ */ jsx(PanelEmpty, {
|
|
184
177
|
icon: "i-ph-tree-structure",
|
|
@@ -78,6 +78,8 @@ function useOpenFiles(scope, layout, layoutStore, prefs, source) {
|
|
|
78
78
|
}, [buffers, slots]);
|
|
79
79
|
const [savedAt, setSavedAt] = useState(/* @__PURE__ */ new Map());
|
|
80
80
|
const adoptFile = useCallback((path, file, resetEditor = false) => {
|
|
81
|
+
const inFlight = reads.current.get(path);
|
|
82
|
+
if (inFlight !== void 0) reads.current.set(path, inFlight + 1);
|
|
81
83
|
if (resetEditor) resetEditSession(path);
|
|
82
84
|
else setSavedAt((m) => new Map(m).set(path, Date.now()));
|
|
83
85
|
setOpen((current) => current.map((f) => f.path === path && f.file !== file ? {
|
package/dist/git/BranchMenu.js
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { IconButton } from "../components/IconButton.js";
|
|
2
2
|
import { CopyButton } from "../components/CopyButton.js";
|
|
3
|
+
import { Notice } from "../components/Notice.js";
|
|
3
4
|
import { Tooltip } from "../components/Tooltip.js";
|
|
4
5
|
import { MenuNote } from "../components/Menu.js";
|
|
5
6
|
import { FloatingSurface } from "../components/floating/FloatingSurface.js";
|
|
@@ -358,9 +359,10 @@ function BranchMenu({ open, anchorRef, cwd, sessionId, current, onClose, onSwitc
|
|
|
358
359
|
className: "zg-well w-full h-7 px-2.5 text-zg-label placeholder:text-[var(--zg-text-subtle)]"
|
|
359
360
|
})
|
|
360
361
|
}),
|
|
361
|
-
error && /* @__PURE__ */ jsx(
|
|
362
|
-
|
|
363
|
-
|
|
362
|
+
error && /* @__PURE__ */ jsx(Notice, {
|
|
363
|
+
tone: "error",
|
|
364
|
+
compact: true,
|
|
365
|
+
className: "mx-1 mb-1",
|
|
364
366
|
children: error
|
|
365
367
|
}),
|
|
366
368
|
/* @__PURE__ */ jsxs("div", {
|