zidane-gui 9.1.6 → 9.1.11

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.
Files changed (73) hide show
  1. package/out/main/index.js +398 -55
  2. package/out/preload/index.mjs +7 -5
  3. package/out/renderer/assets/{43YPWK3Q-z5jpEo82.js → 43YPWK3Q-BVJpf1u1.js} +6 -6
  4. package/out/renderer/assets/{45MVAN6X-GiMurZcH.js → 45MVAN6X-BWuIeWOc.js} +5 -5
  5. package/out/renderer/assets/{46GJKBLZ-BK9JvL-z.js → 46GJKBLZ-41BAHmt4.js} +10 -10
  6. package/out/renderer/assets/{63WH7YNF-oZNJFk32.js → 63WH7YNF-DuatnhlB.js} +8 -8
  7. package/out/renderer/assets/{6DDU7VKX-Q8ape99y.js → 6DDU7VKX-BAI-vKC1.js} +6 -6
  8. package/out/renderer/assets/{CLQLV5VT-1CokruIk.js → CLQLV5VT-CmHu2HE3.js} +6 -6
  9. package/out/renderer/assets/{CUSPXG5M-CXI47Yx3.js → CUSPXG5M-DE3uzfbs.js} +6 -6
  10. package/out/renderer/assets/{CodeEditor-D8TMSvb4.js → CodeEditor-CIwCP1F_.js} +3 -3
  11. package/out/renderer/assets/{ComposerEditor-MwH3w7kQ.js → ComposerEditor-leA8S_Yk.js} +2 -2
  12. package/out/renderer/assets/{D3L7O4X2-CZlDY3Xj.js → D3L7O4X2-BZ4caDcX.js} +4 -4
  13. package/out/renderer/assets/{D5TW5CPZ-C04jssFu.js → D5TW5CPZ-BXdKc68h.js} +1 -1
  14. package/out/renderer/assets/{DiffsTab-CD4Z6LsX.js → DiffsTab-CyRIVfQk.js} +5 -5
  15. package/out/renderer/assets/{EGADTWYV-C6IiGlh0.js → EGADTWYV-Bf6Kicdv.js} +5 -5
  16. package/out/renderer/assets/{EOJSJZXM-Bw1Qp21K.js → EOJSJZXM-NAa-K4U0.js} +8 -8
  17. package/out/renderer/assets/{EditorWorkers-D0xeQ5Kf.js → EditorWorkers-CY0St-9O.js} +4 -4
  18. package/out/renderer/assets/{FilesTab-Pp8_PSfd.js → FilesTab-CnRw0KCN.js} +111 -17
  19. package/out/renderer/assets/{G2OEIG6X-foim2Z_m.js → G2OEIG6X-BarwxCkp.js} +5 -5
  20. package/out/renderer/assets/{GXJ2T77W-FIOAlHlR.js → GXJ2T77W-CyQVHlsG.js} +6 -6
  21. package/out/renderer/assets/{HX3UMAK7-COan20yP.js → HX3UMAK7-BcoG4mYG.js} +5 -5
  22. package/out/renderer/assets/{IU7WZTP6-DeXscWir.js → IU7WZTP6-kOLrUSwF.js} +1 -1
  23. package/out/renderer/assets/{J5J2NR2G-B7up1iuZ.js → J5J2NR2G-DE-SGCIz.js} +4 -4
  24. package/out/renderer/assets/{JRCWTJEL-M4z7DV1k.js → JRCWTJEL-DZY5HKk0.js} +3 -3
  25. package/out/renderer/assets/{KHUP5TOH-0CDf31VX.js → KHUP5TOH-DevvG2jY.js} +1 -1
  26. package/out/renderer/assets/{L74FQTH5-xlC3E1u8.js → L74FQTH5-CnOj-zIY.js} +4 -4
  27. package/out/renderer/assets/{LAV4ZXOS-CWOm214F.js → LAV4ZXOS-BATWssHi.js} +6 -6
  28. package/out/renderer/assets/{LBIZYCRR-BRMO_zpo.js → LBIZYCRR-BXTsyX1O.js} +7 -7
  29. package/out/renderer/assets/{LFFXNLRS-CQDwxn8S.js → LFFXNLRS-BpnXEoXM.js} +3 -3
  30. package/out/renderer/assets/{LLLWOAQD-NLayfyRk.js → LLLWOAQD-BjLHR3Pk.js} +1 -1
  31. package/out/renderer/assets/{LTYQZ5U5-CfgFK_8S.js → LTYQZ5U5-CDOIyknV.js} +8 -8
  32. package/out/renderer/assets/{NDSCUZ25-CRhHG4rp.js → NDSCUZ25-Bl1idg0d.js} +2 -2
  33. package/out/renderer/assets/{NMN3IKWL-pNFku5nG.js → NMN3IKWL-BYE2yrn3.js} +9 -9
  34. package/out/renderer/assets/{NMUA3R2D-D5EpYecE.js → NMUA3R2D-Xl410xeQ.js} +7 -7
  35. package/out/renderer/assets/{NY5A6PPW-BFqrOF96.js → NY5A6PPW-CkzCXBsB.js} +3 -3
  36. package/out/renderer/assets/{OHJ2EJXK-DUXRo20H.js → OHJ2EJXK-DCVoLmOH.js} +1 -1
  37. package/out/renderer/assets/{OU2GIT2H-RERREQg4.js → OU2GIT2H-DG4LbVmY.js} +4 -4
  38. package/out/renderer/assets/{PDMLSE6I-B6VLJpYF.js → PDMLSE6I-Cr8MjczD.js} +2 -2
  39. package/out/renderer/assets/{PJ7X32S5-CiX4IRfi.js → PJ7X32S5-DFZu5Xsj.js} +5 -5
  40. package/out/renderer/assets/{RLLQ44NJ-DI-w7C3g.js → RLLQ44NJ-D-LvBssh.js} +7 -7
  41. package/out/renderer/assets/{S6DWMCK5-BFYfpKyU.js → S6DWMCK5-BQEAXG2z.js} +8 -8
  42. package/out/renderer/assets/{STIOTUT7-BsXqNDoB.js → STIOTUT7-jszPNHGr.js} +6 -6
  43. package/out/renderer/assets/{SXSLPWUD-DsiZBZ2L.js → SXSLPWUD-CEMEDuKR.js} +2 -2
  44. package/out/renderer/assets/{TR4WJQGX-DdGw5EgP.js → TR4WJQGX-8wGWCKKm.js} +1 -1
  45. package/out/renderer/assets/{UWRPUF3N-B9f5cVuf.js → UWRPUF3N-ONJaPLUk.js} +1 -1
  46. package/out/renderer/assets/{VSWIZJ7B-B67GWWkR.js → VSWIZJ7B-DbkRTlJD.js} +1 -1
  47. package/out/renderer/assets/{WM7NR6YK-BjDcbecJ.js → WM7NR6YK-CFy2rge0.js} +4 -4
  48. package/out/renderer/assets/{WXKV2YEK-DkO54WUi.js → WXKV2YEK-BFHYSpQF.js} +3 -3
  49. package/out/renderer/assets/{XLHPVVFU-CgBgWtsm.js → XLHPVVFU-BJFPh1Rn.js} +1 -1
  50. package/out/renderer/assets/{YNX532HU-GZs01vUI.js → YNX532HU-3QqofRh5.js} +5 -5
  51. package/out/renderer/assets/{YUPSMAUO-3HW0N7cY.js → YUPSMAUO-COLbQro8.js} +1 -1
  52. package/out/renderer/assets/{ZFRCZTLK-Bv3j48XJ.js → ZFRCZTLK-BuPbgRNC.js} +6 -6
  53. package/out/renderer/assets/{ZZDR4CN3-bxop59us.js → ZZDR4CN3-Do4onAxu.js} +4 -4
  54. package/out/renderer/assets/{core-DUTJyMGZ.js → core-T80gwwf3.js} +591 -344
  55. package/out/renderer/assets/{file-tabs-CDruoNmZ.js → file-tabs-DWQZlQfx.js} +5 -5
  56. package/out/renderer/assets/{ghostty-web-CtIJ7i7e.js → ghostty-web-DXNGAB4P.js} +1 -1
  57. package/out/renderer/assets/{highlights-26TXpsMP.js → highlights-B0vcJ7-n.js} +2 -2
  58. package/out/renderer/assets/{highlights-Bmhv1Dz1.js → highlights-Yvd7kpJw.js} +3 -3
  59. package/out/renderer/assets/{index-CpGbxp8B.js → index-BbyDWT39.js} +227 -250
  60. package/out/renderer/assets/{index-B5DcyIyT.css → index-CsOxRbAw.css} +146 -19
  61. package/out/renderer/assets/{kit-u_PHwNWF.js → kit-DgkO1_s6.js} +2354 -1186
  62. package/out/renderer/assets/{langs-DQ-AW7Q8.js → langs-7bXaMxtL.js} +1 -1
  63. package/out/renderer/assets/{lazy-xGoFzwfG.js → lazy-DE7xn_YD.js} +3 -3
  64. package/out/renderer/assets/{loader-BwgXVB75.js → loader-CdKsI-e2.js} +1 -1
  65. package/out/renderer/assets/{pierre-theme-CwuG23St.js → pierre-theme-BouAfjrk.js} +7 -7
  66. package/out/renderer/assets/{shiki-DCldjjSl.js → shiki-CIKuDsHH.js} +3 -3
  67. package/out/renderer/assets/{stream-tokenizer-BJjKxfTj.js → stream-tokenizer-JLLsdqkH.js} +1 -1
  68. package/out/renderer/assets/{themes-Bt8pRd53.js → themes-mM7Qtyxf.js} +2 -2
  69. package/out/renderer/assets/{useDetachCleanup-hiha0T2M.js → useDetachCleanup-1PVBQ1U4.js} +2 -2
  70. package/out/renderer/assets/{useFolderChanges-AOk0dbsA.js → useFolderChanges-_vflCTEj.js} +3 -3
  71. package/out/renderer/index.html +4 -4
  72. package/package.json +2 -2
  73. package/scripts/app-installer.mjs +9 -0
@@ -1,8 +1,8 @@
1
- const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./file-tabs-CDruoNmZ.js","./vendor-react-bPTwWURR.js","./EditorWorkers-D0xeQ5Kf.js","./pierre-theme-CwuG23St.js","./core-DUTJyMGZ.js","./vendor-BpwX-s_O.js","./vendor-D_E2rLzO.css","./kit-u_PHwNWF.js","./vendor-motion-BgQeucLF.js","./vendor-editor-Cx3SvGyZ.js"])))=>i.map(i=>d[i]);
2
- import { cF as LOCAL_HOST_KEY, e4 as sessionKey$1, cx as parseSessionKey$1, e5 as LOCAL_HOST_NAME, n as DEFAULT_SETTINGS, e6 as ARTIFACT_BADGES_MAX, e7 as spacesEnabled, e8 as ARTIFACTS_PANEL_ID, e9 as buildPanelCatalog, ea as MEDIA_BY_EXTENSION, eb as USAGE_BLOCK_ID, bq as CONNECTORS, br as connectorInstalled, b4 as nativeExtensionByName, ec as nativeExtensionSource, dx as connectorById, ed as connectorServerConfig, ee as machineWaiting, ef as SIDE_PANEL_ID, eg as normalizeBrowserUrl, aY as INBOX_PANEL_ID, _ as __vitePreload, eh as BROWSER_PANEL_ID, aX as REMINDERS_PANEL_ID, d5 as SECRETS_PANEL_ID, aV as QUEUE_PANEL_ID, c_ as TERMINAL_PANEL_ID, a1 as FILES_PANEL_ID, a0 as DIFFS_PANEL_ID, aF as resolveSessionSpace, ax as parseMachineKind, cw as accentColor, bI as DEFAULT_MODEL_PICK, ei as decisionsEnabled, ej as countNeighbors, ek as selectableTurnIds, G as GITHUB_PULL_PROVIDER_ID, H as GITHUB_ISSUE_PROVIDER_ID, I as githubRefKey, el as runBlockOnHost, cE as parseRepoInput } from "./core-DUTJyMGZ.js";
1
+ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./file-tabs-DWQZlQfx.js","./vendor-react-bPTwWURR.js","./EditorWorkers-CY0St-9O.js","./pierre-theme-BouAfjrk.js","./core-T80gwwf3.js","./vendor-BpwX-s_O.js","./vendor-D_E2rLzO.css","./kit-DgkO1_s6.js","./vendor-motion-BgQeucLF.js","./vendor-editor-Cx3SvGyZ.js"])))=>i.map(i=>d[i]);
2
+ import { cI as LOCAL_HOST_KEY, e9 as sessionKey$1, cA as parseSessionKey$1, ea as LOCAL_HOST_NAME, n as DEFAULT_SETTINGS, eb as ARTIFACT_BADGES_MAX, ec as spacesEnabled, ed as ARTIFACTS_PANEL_ID, ee as buildPanelCatalog, ef as MEDIA_BY_EXTENSION, eg as USAGE_BLOCK_ID, br as CONNECTORS, bs as connectorInstalled, b5 as nativeExtensionByName, eh as nativeExtensionSource, dB as connectorById, ei as connectorServerConfig, ej as machineWaiting, ek as SIDE_PANEL_ID, el as normalizeBrowserUrl, aZ as INBOX_PANEL_ID, _ as __vitePreload, em as BROWSER_PANEL_ID, aY as REMINDERS_PANEL_ID, d9 as SECRETS_PANEL_ID, aW as QUEUE_PANEL_ID, d2 as TERMINAL_PANEL_ID, a2 as FILES_PANEL_ID, a1 as DIFFS_PANEL_ID, aG as resolveSessionSpace, ay as parseMachineKind, cz as accentColor, bJ as DEFAULT_MODEL_PICK, en as decisionsEnabled, eo as countNeighbors, ep as selectableTurnIds, G as GITHUB_PULL_PROVIDER_ID, H as GITHUB_ISSUE_PROVIDER_ID, I as githubRefKey, eq as runBlockOnHost, cH as parseRepoInput } from "./core-T80gwwf3.js";
3
3
  import { r as reactExports, j as jsxRuntimeExports, e as ReactDomClient, f as ReactDom, h as ReactJsxRuntime, R as React, i as ReactDOM, c as React$1 } from "./vendor-react-bPTwWURR.js";
4
4
  import "./vendor-BpwX-s_O.js";
5
- import { ak as createResourceStore, al as useResource, am as readableResource, an as writable, ao as keyedSettingsResources, ap as createSettingsResource, aq as toSettingsError, ar as settingsMcpServerOf, as as createPresenceStore, at as createOnlineMachines, au as createMachineLists, av as lazyReadable, aw as createHostSyncReads, ax as useSettingsHost, ay as SettingsProvider$1, az as useSettings, aj as useReadable, aA as PathDisplayProvider, aB as MachinesProvider, aC as createLayoutMemory, aD as useScopeLayout$1, aE as createDraftScopeStore, aF as draftScopeOf, aG as createRunMeter, aH as createSessionBadges, aI as createSessionActivity, aJ as createRunEstimates, aK as createCompactionProgress, aL as createTerminalStore, aM as usePeekSessionEvents, aN as useSessionStreamActions, aO as useIsSessionHydrated, aP as useSessionEvents$1, aQ as useSessionEventsSelector$1, aR as createSessionStreams, aS as SessionStreamsProvider, aT as RunEstimatesProvider, aU as useSessionStreams$1, aV as usePeekRunSeq$1, aW as usePeekSessionRunning, aX as useSessionRunning, aY as createSessionHistory, aZ as createSidebarViews, a_ as createSessionDirectory, a$ as useSessionDirectoryView, b0 as useNewSessionDefaults, b1 as writePersisted, b2 as DEFAULT_SIDEBAR_LABELS, b3 as useCaptureRunState, b4 as pinnedSessions, b5 as useCycleAgent$1, b6 as createPanelFocusStore, b7 as pickTab, b8 as useWorkspaceView, b9 as useWorkspaceRequests, ba as useWorkspaceContent, bb as useExtensionPanels, bc as WorkspaceHostProvider, bd as WorkspaceProvider, be as useWorkspaceActions, bf as createSidebarCollapsed, ai as useAppearanceState, bg as LayoutBudgetProvider, bh as LIMITS, bi as useTurnCommands, bj as useTurnMenu$1, bk as createOpenTarget, bl as CommandScopeContext, bm as findCommand, bn as hasInteractionBody, bo as InteractionToolBody, bp as InlineChipText, bq as ProseMarkdown, br as useTranscriptActions, bs as PromptEcho, bt as createModelPickerPrefs, bu as ComposerHostProvider$1, bv as modelNamesOf, bw as useSelectTurn, bx as useTranscriptOptions, by as useSessionRetry, bz as pushComposerPrompt, bA as MarkdownContext, bB as TranscriptRenderersProvider, bC as TranscriptActionsProvider, bD as PathDisplayScope, bE as Transcript, bF as TranscriptSearch$1, bG as useSessionPresence$1, bH as usePresenceMap$1, bI as createSidebarLive, bJ as useSessionApprovalHead, bK as useInteractionHead, bL as useRunElapsedSec, bM as ZidaneUiExtensionsKit, bN as ZidaneUiExtensions, bO as EXTENSION_TOKENS, bP as ExtensionsHostError, bQ as createUiEffectChannel, bR as createDialogQueue, bS as sidebarContributionsOf, bT as ExtensionsProvider, bU as useProjectIcons, bV as useConfirmDeleteSession, bW as useMoveSession, bX as basename, bY as useSessionMenuItems, bZ as SessionListRow, b_ as moveSubject, b$ as useWorkspaceHost, c0 as useLinkRouter, c1 as useStartFromPanel, c2 as PanelSessionRowProvider, c3 as ProjectHome, c4 as ProjectIconGlyph, c5 as WelcomeScreen$1, c6 as modelKnobsOf, c7 as commitModelPick$1, c8 as createStorageBoot, c9 as createStorageAppearancePrefs, ca as codeThemeTypeOf, cb as constant, cc as EFFORT_LEVELS, cd as BUILTIN_THEMES, ce as useModal, cf as useAppearance, cg as OnboardingProvider, ch as OnboardingFlow, ci as createSiteIcons, cj as useEnvironmentChoices, ck as BranchMenu$1, cl as GitBar$1, cm as createKeybindingOverrides, cn as useSessionFallbackModel, co as getMergedKeybindings, K as KeyHint, cp as ComposerStatusPills, cq as ComposerControls, cr as RetryPill, cs as useLayoutBudgetOptional, ct as ConversationBadges$1, cu as hostReachable, cv as useLentServers, cw as ServerOfflineBanner, cx as ArchivedBanner, cy as HostRemovedBanner, cz as ComposerNotice, cA as ConnectProviderCard, cB as ComposerDock, cC as SelectTurnHint, cD as ApprovalDock, cE as ErrorBoundary, cF as RichComposer, cG as codeAttachmentLabel, cH as WherePicker, cI as RemoteFolderPicker, cJ as ServerScopeToggle, cK as ScopeToggle, cL as MachineWaitingBanner, U as Tooltip, V as IconButton, cM as useSidebarHost, cN as useSidebarLabels, cO as useEnvironmentCommands, cP as useEnvironmentActions, cQ as sessionMenuItems, cR as useReferenceMatches, cS as SessionHeader$1, cT as HostStatusDot, cU as ReferenceText, cV as useComposerSearch$1, cW as createSideRequests, cX as DEFAULT_SESSION_LABELS, cY as useSendPrompt$1, cZ as useSessionHost, c_ as useSessionPage, c$ as useTranscriptScroll$1, d0 as useSessionMeters, d1 as useDraftTarget, d2 as useSettledReveal, d3 as LoadEarlierRow, d4 as SearchHighlightStyle, d5 as ArtifactsPanel$1, d6 as BTN_SECONDARY, d7 as BTN_PRIMARY, b as pushComposerAttachment, c as textAttachment, d8 as focusComposer, n as usePanelVisible, d9 as subscribeLayoutAnimating, da as isLayoutAnimating, db as useSiteIcon, dc as useKeybindings, dd as usePaletteSource, de as NavButton, df as AddressBar, dg as Popover, dh as SectionLabel, di as MenuRow, dj as Menu, dk as MenuSection, dl as MenuSeparator, dm as relativeTime, R as RowActionsMenu, dn as useInboxPlans, dp as InboxPanel, dq as RecentPlans, dr as PlanTracker, ds as attachmentLightboxItems, dt as AttachmentRow, du as QueueTab$1, dv as SideChat, dw as HostModelPicker, dx as HostModelOptionsPicker, dy as TerminalPanelTab, dz as RemindersPanel, dA as SecretsPanel, dB as PanelContentView, dC as useLayoutBudget, dD as panelCornerWidth, dE as PanelCorner, dF as countArtifacts, dG as useSessionArtifacts, dH as splitPanelWidth, dI as SidePanel$1, dJ as TAB_REGION_PROPS, dK as panelDragResult, dL as TerminalDrawer, dM as SidebarFooter, dN as SidebarSignInPrompt, dO as DaemonMenu, dP as useProviderUsage, dQ as SidebarUsageIndicator, dR as useCompactionProgress, dS as Presence, dT as SidebarCompactingIndicator, dU as useProjectSessionActions, dV as SpaceSwitcher, dW as SessionSidebar, dX as useSaveViewAsSpace, dY as SidebarFilterMenu, dZ as ExtensionSlot, d_ as CreateExtensionDialog, d$ as useTerminalsEnabled, e0 as useTerminalStore, e1 as useScopeTerminals, e2 as RunningWorkDialog, e3 as renderSessionModalShell, e4 as useAgentProfiles$1, e5 as useConfirm, e6 as useSessionCacheReport, e7 as useColors, e8 as useDisplayPath, e9 as compactPath, ea as SessionDetailsDialog, eb as renderWideSessionModalShell, ec as SessionCacheFacts, ed as deleteSessionPrompt, ee as useExtensionsHost, ef as extensionsErrorOf, eg as BTN_LG_SECONDARY, eh as SettingsTutorial, ei as McpSection, ej as ServerProvidersSection, ek as ProvidersSection, el as ExtensionsSection, em as SkillsSection, en as InstructionsSection, eo as KeybindingsSection, ep as EditorSection, eq as AppearanceSection, er as HostCatalogSection, es as PluginsSection, et as PerformanceSection, eu as LogsSection, ev as EnvironmentsSection, ew as HostsSection, ex as ROW_BUTTON_CLASS, ey as RowText, ez as useSettingsSection, eA as useServerSyncStatus, eB as agentDefaultsOf, eC as SettingsRowsPage, eD as SpacesDefaultsSection, eE as ConversationPresetsRow, eF as CompactionModelRow, eG as DecisionModelRow, eH as TextModelRow, eI as AgentDefaultsRows, eJ as SyncMarker, eK as ApprovalModeRow, eL as agentDefaultsPatch, eM as settingsPageCounts, eN as listLength, eO as KEYBINDING_ROW_COUNT, eP as SegmentSpinner, eQ as SettingsHostSwitcher, eR as ScreenShell, eS as visiblePages, eT as useExtensionSettingsSections, eU as layoutSections, eV as SettingsHeadingText, eW as SettingsShell, eX as UsagePanel, eY as TurnDetailsDialog, eZ as usePanelGroupHandlers$1, e_ as InboxAttention$1, e$ as QueueAttention$1, f0 as SecretsAttention$1, f1 as PerformanceHud, f2 as DEFAULT_EDITOR, f3 as EDITOR_STORAGE_KEY, f4 as parseEditor, f5 as createPaletteRows, f6 as usePaletteHost, f7 as usePaletteLabels, f8 as useSessionRank, f9 as sessionsSource, fa as conversationsSource, fb as useActionsPaletteSource, fc as panelsSource, fd as spacesSource, fe as commandsSource, ff as useImportRepo, fg as repoSource, fh as filesSource, fi as settingsSource, fj as prefsSource, fk as extensionsSource, fl as setupSource, fm as usePaletteModalSlot, fn as panelTabMark, fo as PaletteDialog, fp as pushComposerInsert, fq as useExtensionEffects, fr as ExtensionDialogHost, fs as matchesBinding, ft as registerTabScope, fu as serializeTerminalExcerpt, fv as hasComposerFor, fw as TerminalProvider, fx as ModalProvider, fy as KeyCommandsProvider, fz as useSessionContextStatus, fA as useProviderReadyPoll, fB as useClaudeImportAvailable, fC as AgentPickerDialog, fD as effortPickerTarget, fE as EffortPickerDialog, fF as createSessionActions, fG as useHelpKey, fH as useTranscriptFind, fI as ModelPickerDialog, fJ as usePaletteActions, fK as useWorkspaceKeyCommands, fL as useMainSession, fM as useSelectTurnKeys, fN as zoomKeyCommands, fO as sessionKeyCommands, fP as useKeyCommands, fQ as ClaudeImportDialog, fR as SafelistPanel, fS as ModalShell, fT as SidebarToggleButton, fU as accountsKeyFocusId, fV as accountsFocusId, fW as hostSettingsFocus, fX as createPendingApprovals, fY as createSafelist, fZ as ApprovalsProvider, f_ as createRunningWorkState, f$ as createSchedulesState, g0 as createSecretsState, g1 as createArtifactsState, g2 as createQueueState, g3 as createPlansState, g4 as SessionProvider, g5 as ProviderUsageProvider, g6 as FilesProvider, g7 as createChatBlockRuns, g8 as ChatProvider, g9 as useHasFocusedComposer, ga as hasFocusedComposer, d as pushComposerMention, gb as OpenSessionContext, gc as BadgeMenuProvider, gd as createStorageRecents, ge as PaletteProvider, gf as WorkerWrapper, gg as LabelsProvider, gh as PromptHistoryProvider, gi as SelectTurnProvider, gj as KeybindingsProvider, gk as GitProvider, gl as SidebarHostProvider, gm as useShikiTheme, T as useEditorPrefs, gn as CodeHighlightProvider, go as CodeWrapProvider, gp as createCodeHighlighter, gq as WorkerWrapper$1, gr as AppearanceProvider, gs as EditorEnvironmentRoot, gt as configureErrorReports, gu as installRendererErrorHandlers, gv as watchRuntimeIcons, gw as reportRendererError, G as buttonClass, gx as readMotionMs, gy as crispPhosphor } from "./kit-u_PHwNWF.js";
5
+ import { ak as createResourceStore, al as useResource, am as readableResource, an as writable, ao as keyedSettingsResources, ap as createSettingsResource, aq as toSettingsError, ar as settingsMcpServerOf, as as createPresenceStore, at as createOnlineMachines, au as createMachineLists, av as lazyReadable, aw as createHostSyncReads, ax as useSettingsHost, ay as SettingsProvider$1, az as useSettings, aj as useReadable, aA as PathDisplayProvider, aB as MachinesProvider, aC as createLayoutMemory, aD as useScopeLayout$1, aE as createDraftScopeStore, aF as draftScopeOf, aG as createRunMeter, aH as createSessionBadges, aI as createSessionActivity, aJ as createRunEstimates, aK as createCompactionProgress, aL as createTerminalStore, aM as usePeekSessionEvents, aN as useSessionStreamActions, aO as useIsSessionHydrated, aP as useSessionEvents$1, aQ as useSessionEventsSelector$1, aR as createSessionStreams, aS as SessionStreamsProvider, aT as RunEstimatesProvider, aU as useSessionStreams$1, aV as usePeekRunSeq$1, aW as usePeekSessionRunning, aX as useSessionRunning, aY as createSessionHistory, aZ as createSidebarViews, a_ as createSessionDirectory, a$ as useSessionDirectoryView, b0 as useNewSessionDefaults, b1 as writePersisted, b2 as DEFAULT_SIDEBAR_LABELS, b3 as useCaptureRunState, b4 as pinnedSessions, b5 as useCycleAgent$1, b6 as createPanelFocusStore, b7 as pickTab, b8 as useWorkspaceView, b9 as useWorkspaceRequests, ba as useWorkspaceContent, bb as useExtensionPanels, bc as WorkspaceHostProvider, bd as WorkspaceProvider, be as useWorkspaceActions, bf as createSidebarCollapsed, ai as useAppearanceState, bg as LayoutBudgetProvider, bh as LIMITS, bi as useTurnCommands, bj as useTurnMenu$1, bk as createOpenTarget, bl as CommandScopeContext, bm as findCommand, bn as hasInteractionBody, bo as InteractionToolBody, bp as InlineChipText, bq as ProseMarkdown, br as useTranscriptActions, bs as PromptEcho, bt as createModelPickerPrefs, bu as ComposerHostProvider$1, bv as modelNamesOf, bw as useSelectTurn, bx as useTranscriptOptions, by as useSessionRetry, bz as pushComposerPrompt, bA as MarkdownContext, bB as TranscriptRenderersProvider, bC as TranscriptActionsProvider, bD as PathDisplayScope, bE as Transcript, bF as TranscriptSearch$1, bG as useSessionPresence$1, bH as usePresenceMap$1, bI as createSidebarLive, bJ as useSessionApprovalHead, bK as useInteractionHead, bL as useRunElapsedSec, bM as ZidaneUiExtensionsKit, bN as ZidaneUiExtensions, bO as EXTENSION_TOKENS, bP as ExtensionsHostError, bQ as createUiEffectChannel, bR as createDialogQueue, bS as sidebarContributionsOf, bT as ExtensionsProvider, bU as useProjectIcons, bV as useConfirmDeleteSession, bW as useMoveSession, bX as basename, bY as useSessionMenuItems, bZ as SessionListRow, b_ as moveSubject, b$ as useWorkspaceHost, c0 as useLinkRouter, c1 as useStartFromPanel, c2 as PanelSessionRowProvider, c3 as ProjectHome, c4 as ProjectIconGlyph, c5 as WelcomeScreen$1, c6 as modelKnobsOf, c7 as commitModelPick$1, c8 as createStorageBoot, c9 as createStorageAppearancePrefs, ca as codeThemeTypeOf, cb as constant, cc as EFFORT_LEVELS, cd as BUILTIN_THEMES, ce as useModal, cf as useAppearance, cg as OnboardingProvider, ch as OnboardingFlow, ci as createSiteIcons, cj as useEnvironmentChoices, ck as BranchMenu$1, cl as GitBar$1, cm as createKeybindingOverrides, cn as useSessionFallbackModel, co as getMergedKeybindings, K as KeyHint, cp as ComposerStatusPills, cq as ComposerControls, cr as RetryPill, cs as useLayoutBudgetOptional, ct as ConversationBadges$1, cu as hostReachable, cv as useLentServers, cw as ServerOfflineBanner, cx as ArchivedBanner, cy as HostRemovedBanner, cz as ComposerNotice, cA as ConnectProviderCard, cB as ComposerDock, cC as SelectTurnHint, cD as ApprovalDock, cE as ErrorBoundary, cF as RichComposer, cG as codeAttachmentLabel, cH as WherePicker, cI as RemoteFolderPicker, cJ as ServerScopeToggle, cK as ScopeToggle, cL as MachineWaitingBanner, U as Tooltip, V as IconButton, cM as useSidebarHost, cN as useSidebarLabels, cO as useEnvironmentCommands, cP as useEnvironmentActions, cQ as sessionMenuItems, cR as useReferenceMatches, cS as SessionHeader$1, cT as HostStatusDot, cU as ReferenceText, cV as useComposerSearch$1, cW as createSideRequests, cX as DEFAULT_SESSION_LABELS, cY as useSendPrompt$1, cZ as useSessionHost, c_ as useSessionPage, c$ as useTranscriptScroll$1, d0 as useSessionMeters, d1 as useDraftTarget, d2 as pushComposerDraft, d3 as useSettledReveal, d4 as LoadEarlierRow, d5 as SearchHighlightStyle, d6 as ArtifactsPanel$1, d7 as BTN_SECONDARY, d8 as BTN_PRIMARY, b as pushComposerAttachment, c as textAttachment, d9 as focusComposer, n as usePanelVisible, da as subscribeLayoutAnimating, db as isLayoutAnimating, dc as useSiteIcon, dd as useKeybindings, de as usePaletteSource, df as NavButton, dg as AddressBar, dh as Popover, di as SectionLabel, dj as MenuRow, dk as Menu, dl as MenuSection, dm as MenuSeparator, dn as relativeTime, R as RowActionsMenu, dp as useInboxPlans, dq as InboxPanel, dr as RecentPlans, ds as PlanTracker, dt as attachmentLightboxItems, du as AttachmentRow, dv as QueueTab$1, dw as SideChat, dx as HostModelPicker, dy as HostModelOptionsPicker, dz as TerminalPanelTab, dA as RemindersPanel, dB as SecretsPanel, dC as PanelContentView, dD as useLayoutBudget, dE as panelCornerWidth, dF as PanelCorner, dG as countArtifacts, dH as useSessionArtifacts, dI as splitPanelWidth, dJ as SidePanel$1, dK as TAB_REGION_PROPS, dL as panelDragResult, dM as TerminalDrawer, dN as SidebarFooter, dO as SidebarSignInPrompt, dP as DaemonMenu, dQ as useProviderUsage, dR as SidebarUsageIndicator, dS as useCompactionProgress, dT as Presence, dU as SidebarCompactingIndicator, dV as useProjectSessionActions, dW as focusComposerWhenReady, dX as SpaceSwitcher, dY as SessionSidebar, dZ as useSaveViewAsSpace, d_ as SidebarFilterMenu, d$ as ExtensionSlot, e0 as CreateExtensionDialog, e1 as useTerminalsEnabled, e2 as useTerminalStore, e3 as useScopeTerminals, e4 as RunningWorkDialog, e5 as renderSessionModalShell, e6 as useAgentProfiles$1, e7 as useConfirm, e8 as useSessionCacheReport, e9 as useColors, ea as useDisplayPath, eb as compactPath, ec as SessionDetailsDialog, ed as renderWideSessionModalShell, ee as SessionCacheFacts, ef as deleteSessionPrompt, eg as BTN_LG_SECONDARY, eh as SettingsTutorial, ei as McpSection, ej as ServerProvidersSection, ek as ProvidersSection, el as ExtensionsSection, em as SkillsSection, en as InstructionsSection, eo as KeybindingsSection, ep as EditorSection, eq as AppearanceSection, er as HostCatalogSection, es as ExtensionSettingsSection, et as PluginsSection, eu as PerformanceSection, ev as LogsSection, ew as EnvironmentsSection, ex as HostsSection, ey as ROW_BUTTON_CLASS, ez as RowText, eA as useSettingsSection, eB as useServerSyncStatus, eC as agentDefaultsOf, eD as SettingsRowsPage, eE as SpacesDefaultsSection, eF as ConversationPresetsRow, eG as CompactionModelRow, eH as DecisionModelRow, eI as TextModelRow, eJ as AgentDefaultsRows, eK as SyncMarker, eL as ApprovalModeRow, eM as agentDefaultsPatch, eN as settingsPageCounts, eO as listLength, eP as KEYBINDING_ROW_COUNT, eQ as SegmentSpinner, eR as SettingsHostSwitcher, eS as ScreenShell, eT as visiblePages, eU as useExtensionSettingsSections, eV as layoutSections, eW as SettingsHeadingText, eX as SettingsShell, eY as UsagePanel, eZ as TurnDetailsDialog, e_ as usePanelGroupHandlers$1, e$ as InboxAttention$1, f0 as QueueAttention$1, f1 as SecretsAttention$1, f2 as PerformanceHud, f3 as DEFAULT_EDITOR, f4 as EDITOR_STORAGE_KEY, f5 as parseEditor, f6 as createPaletteRows, f7 as usePaletteHost, f8 as usePaletteLabels, f9 as useSessionRank, fa as sessionsSource, fb as conversationsSource, fc as useActionsPaletteSource, fd as panelsSource, fe as spacesSource, ff as commandsSource, fg as useImportRepo, fh as repoSource, fi as filesSource, fj as settingsSource, fk as prefsSource, fl as extensionsSource, fm as setupSource, fn as usePaletteModalSlot, fo as panelTabMark, fp as PaletteDialog, fq as pushComposerInsert, fr as useExtensionEffects, fs as ExtensionDialogHost, ft as matchesBinding, fu as registerTabScope, fv as serializeTerminalExcerpt, fw as hasComposerFor, fx as TerminalProvider, fy as ModalProvider, fz as KeyCommandsProvider, fA as useSessionContextStatus, fB as useProviderReadyPoll, fC as useClaudeImportAvailable, fD as AgentPickerDialog, fE as effortPickerTarget, fF as EffortPickerDialog, fG as createSessionActions, fH as useHelpKey, fI as useTranscriptFind, fJ as ModelPickerDialog, fK as usePaletteActions, fL as useWorkspaceKeyCommands, fM as useMainSession, fN as useSelectTurnKeys, fO as zoomKeyCommands, fP as sessionKeyCommands, fQ as useKeyCommands, fR as ClaudeImportDialog, fS as SafelistPanel, fT as ModalShell, fU as SidebarToggleButton, fV as accountsKeyFocusId, fW as accountsFocusId, fX as hostSettingsFocus, fY as createPendingApprovals, fZ as createSafelist, f_ as ApprovalsProvider, f$ as createRunningWorkState, g0 as createSchedulesState, g1 as createSecretsState, g2 as createArtifactsState, g3 as createQueueState, g4 as createPlansState, g5 as SessionProvider, g6 as ProviderUsageProvider, g7 as FilesProvider, g8 as createChatBlockRuns, g9 as wireOriginal, ga as ChatProvider, gb as useHasFocusedComposer, gc as hasFocusedComposer, d as pushComposerMention, gd as OpenSessionContext, ge as BadgeMenuProvider, gf as createStorageRecents, gg as PaletteProvider, gh as WorkerWrapper, gi as LabelsProvider, gj as PromptHistoryProvider, gk as SelectTurnProvider, gl as KeybindingsProvider, gm as GitProvider, gn as SidebarHostProvider, go as useShikiTheme, T as useEditorPrefs, gp as CodeHighlightProvider, gq as CodeWrapProvider, gr as createCodeHighlighter, gs as WorkerWrapper$1, gt as AppearanceProvider, gu as EditorEnvironmentRoot, gv as configureErrorReports, gw as installRendererErrorHandlers, gx as watchRuntimeIcons, gy as reportRendererError, G as buttonClass, gz as readMotionMs, gA as crispPhosphor } from "./kit-DgkO1_s6.js";
6
6
  import "./vendor-motion-BgQeucLF.js";
7
7
  import "./vendor-editor-Cx3SvGyZ.js";
8
8
  const LOCAL_SESSION_HOST = LOCAL_HOST_KEY;
@@ -57,13 +57,13 @@ function scopeOfSession(row) {
57
57
  }
58
58
  let health = "disconnected";
59
59
  let wired$1 = false;
60
- const listeners$6 = /* @__PURE__ */ new Set();
60
+ const listeners$7 = /* @__PURE__ */ new Set();
61
61
  function set$2(next) {
62
62
  if (health === next) {
63
63
  return;
64
64
  }
65
65
  health = next;
66
- for (const listener of listeners$6) {
66
+ for (const listener of listeners$7) {
67
67
  listener();
68
68
  }
69
69
  }
@@ -77,9 +77,9 @@ function wire$1() {
77
77
  }
78
78
  function subscribe$5(listener) {
79
79
  wire$1();
80
- listeners$6.add(listener);
80
+ listeners$7.add(listener);
81
81
  return () => {
82
- listeners$6.delete(listener);
82
+ listeners$7.delete(listener);
83
83
  };
84
84
  }
85
85
  function getSnapshot$1() {
@@ -832,6 +832,7 @@ function createElectronMachinesHost(api) {
832
832
  },
833
833
  pickFolder: () => api.folder.pick(),
834
834
  capabilities: (hostId, opts) => api.hosts.capabilities(hostId, opts?.refresh === true).catch(rejected("read")),
835
+ installTool: (hostId, name) => api.hosts.installTool(hostId, name).catch(rejected("install")),
835
836
  updates: {
836
837
  status: (hostId) => api.hosts.selfUpdate(hostId, "status").catch(rejected("update")),
837
838
  check: async (hostId) => await api.hosts.selfUpdate(hostId, "check").catch(rejected("update")),
@@ -872,7 +873,7 @@ function createElectronMachinesHost(api) {
872
873
  }
873
874
  };
874
875
  }
875
- const noop$1 = () => void 0;
876
+ const noop = () => void 0;
876
877
  const windowApi$5 = {
877
878
  hosts: {
878
879
  // A failed backfill keeps the pushed statuses (This computer alone until the next push).
@@ -885,7 +886,8 @@ const windowApi$5 = {
885
886
  remove: (id) => window.api.hosts.remove(id),
886
887
  retry: (id) => window.api.hosts.retry(id),
887
888
  selfUpdate: (hostId, action, enabled) => window.api.hosts.selfUpdate(hostId, action, enabled),
888
- capabilities: (hostId, refresh) => window.api.hosts.capabilities(hostId, refresh)
889
+ capabilities: (hostId, refresh) => window.api.hosts.capabilities(hostId, refresh),
890
+ installTool: (hostId, name) => window.api.hosts.installTool(hostId, name)
889
891
  },
890
892
  machines: {
891
893
  links: () => window.api.machines.links(),
@@ -895,8 +897,8 @@ const windowApi$5 = {
895
897
  shareStart: (hostId, name, roots, token) => window.api.machines.shareStart(hostId, name, roots, token),
896
898
  shareStop: (hostId) => window.api.machines.shareStop(hostId),
897
899
  useServer: (hostId, enabled) => window.api.machines.useServer(hostId, enabled),
898
- onLinks: (cb) => window.api.machines?.onLinks?.(cb) ?? noop$1,
899
- onStatus: (cb) => window.api.machines?.onStatus?.(cb) ?? noop$1
900
+ onLinks: (cb) => window.api.machines?.onLinks?.(cb) ?? noop,
901
+ onStatus: (cb) => window.api.machines?.onStatus?.(cb) ?? noop
900
902
  },
901
903
  folder: { pick: () => window.api.folder.pick() },
902
904
  daemon: {
@@ -1913,11 +1915,11 @@ function parseWindowRole(search) {
1913
1915
  const windowRole = typeof location === "undefined" ? { kind: "main" } : parseWindowRole(location.search);
1914
1916
  const pinnedSession = windowRole.kind === "session" ? windowRole.session : null;
1915
1917
  let list = [];
1916
- const listeners$5 = /* @__PURE__ */ new Set();
1918
+ const listeners$6 = /* @__PURE__ */ new Set();
1917
1919
  let started = false;
1918
1920
  function set$1(next) {
1919
1921
  list = next;
1920
- for (const l of listeners$5) l();
1922
+ for (const l of listeners$6) l();
1921
1923
  }
1922
1924
  function start() {
1923
1925
  if (started || typeof window === "undefined" || !window.api?.windows) return;
@@ -1932,8 +1934,8 @@ const standaloneWindows = {
1932
1934
  },
1933
1935
  subscribe: (l) => {
1934
1936
  start();
1935
- listeners$5.add(l);
1936
- return () => listeners$5.delete(l);
1937
+ listeners$6.add(l);
1938
+ return () => listeners$6.delete(l);
1937
1939
  },
1938
1940
  /** The parts of `sessionKey` held by a standalone window, if any. */
1939
1941
  partsOf: (sessionKey2) => sessionKey2 && list.find((w) => w.sessionKey === sessionKey2)?.parts || null,
@@ -1961,6 +1963,95 @@ function useShowRequests(show, enabled) {
1961
1963
  return off;
1962
1964
  }, [show, enabled]);
1963
1965
  }
1966
+ function createStore(initial) {
1967
+ let value = initial;
1968
+ const listeners2 = /* @__PURE__ */ new Set();
1969
+ return {
1970
+ get: () => value,
1971
+ set(next) {
1972
+ if (next === value) return;
1973
+ value = next;
1974
+ for (const listener of listeners2) listener();
1975
+ },
1976
+ subscribe(listener) {
1977
+ listeners2.add(listener);
1978
+ return () => listeners2.delete(listener);
1979
+ }
1980
+ };
1981
+ }
1982
+ const request = createStore(null);
1983
+ const home = createStore(null);
1984
+ const chatDraft = createStore(false);
1985
+ let seq = 0;
1986
+ function requestDraftOn(hostId, folder, machine) {
1987
+ request.set({ seq: ++seq, hostId, folder, ...machine });
1988
+ }
1989
+ function requestFolderlessDraft() {
1990
+ request.set({ seq: ++seq, hostId: LOCAL_HOST_KEY, folder: null, folderless: true });
1991
+ }
1992
+ function clearDraftRequest() {
1993
+ request.set(null);
1994
+ }
1995
+ function useDraftRequest() {
1996
+ return reactExports.useSyncExternalStore(request.subscribe, request.get, request.get);
1997
+ }
1998
+ function publishHomeProject(project) {
1999
+ const current = home.get();
2000
+ if (current?.path === project?.path && current?.hostId === project?.hostId) return;
2001
+ home.set(project);
2002
+ }
2003
+ function publishChatDraft(open) {
2004
+ chatDraft.set(open);
2005
+ }
2006
+ function useChatDraft() {
2007
+ return reactExports.useSyncExternalStore(chatDraft.subscribe, chatDraft.get, chatDraft.get);
2008
+ }
2009
+ function useHomeProject() {
2010
+ return reactExports.useSyncExternalStore(home.subscribe, home.get, home.get);
2011
+ }
2012
+ let prompt = null;
2013
+ const listeners$5 = /* @__PURE__ */ new Set();
2014
+ const setPrompt = (next) => {
2015
+ prompt = next;
2016
+ for (const listener of listeners$5) listener();
2017
+ };
2018
+ function useDraftPrompt() {
2019
+ return reactExports.useSyncExternalStore(
2020
+ (listener) => {
2021
+ listeners$5.add(listener);
2022
+ return () => listeners$5.delete(listener);
2023
+ },
2024
+ () => prompt,
2025
+ () => prompt
2026
+ );
2027
+ }
2028
+ function clearDraftPrompt() {
2029
+ setPrompt(null);
2030
+ }
2031
+ function applyNewDraftRequest(request2, actions) {
2032
+ const { hostId, cwd, machine, agentId } = request2;
2033
+ if (machine) {
2034
+ requestDraftOn(hostId, null, { environment: `local@${machine.name}`, ...cwd ? { machineFolder: cwd } : {} });
2035
+ } else if (hostId === LOCAL_HOST_KEY) {
2036
+ if (cwd) actions.setDefaultFolder(cwd);
2037
+ requestDraftOn(LOCAL_HOST_KEY, null);
2038
+ } else {
2039
+ requestDraftOn(hostId, cwd ?? null);
2040
+ }
2041
+ if (agentId) actions.setDefaultAgentId(agentId);
2042
+ if (request2.prompt) setPrompt({ text: request2.prompt });
2043
+ actions.showDraft();
2044
+ }
2045
+ function useNewDraftRequests(apply, enabled) {
2046
+ reactExports.useEffect(() => {
2047
+ if (!enabled || !window.api.windows?.onNewDraft) return;
2048
+ const off = window.api.windows.onNewDraft(apply);
2049
+ void window.api.windows.takePendingDraft().then((request2) => {
2050
+ if (request2) apply(request2);
2051
+ });
2052
+ return off;
2053
+ }, [apply, enabled]);
2054
+ }
1964
2055
  function StreamProvider({ children }) {
1965
2056
  const { settings } = useSettings();
1966
2057
  const smoothStreaming = settings.smoothStreaming;
@@ -2146,7 +2237,17 @@ function SessionsProvider({ children }) {
2146
2237
  check();
2147
2238
  return standaloneWindows.subscribe(check);
2148
2239
  }, [directory]);
2149
- useShowRequests(directory.setActive, !pinnedSession);
2240
+ useShowRequests(directory.select, !pinnedSession);
2241
+ const { setDefaultFolder: setDraftFolder, setDefaultAgentId: setDraftAgent } = defaults;
2242
+ const applyDraftRequest = reactExports.useCallback(
2243
+ (request2) => applyNewDraftRequest(request2, {
2244
+ showDraft: () => directory.select(null),
2245
+ setDefaultFolder: setDraftFolder,
2246
+ setDefaultAgentId: setDraftAgent
2247
+ }),
2248
+ [directory, setDraftFolder, setDraftAgent]
2249
+ );
2250
+ useNewDraftRequests(applyDraftRequest, !pinnedSession);
2150
2251
  reactExports.useEffect(() => {
2151
2252
  if (!pageHistory) return void 0;
2152
2253
  const follow = () => pageHistory.visit(directory.state.get().activeSessionId);
@@ -2656,52 +2757,6 @@ function LayoutProvider({
2656
2757
  }
2657
2758
  );
2658
2759
  }
2659
- function createStore(initial) {
2660
- let value = initial;
2661
- const listeners2 = /* @__PURE__ */ new Set();
2662
- return {
2663
- get: () => value,
2664
- set(next) {
2665
- if (next === value) return;
2666
- value = next;
2667
- for (const listener of listeners2) listener();
2668
- },
2669
- subscribe(listener) {
2670
- listeners2.add(listener);
2671
- return () => listeners2.delete(listener);
2672
- }
2673
- };
2674
- }
2675
- const request = createStore(null);
2676
- const home = createStore(null);
2677
- const chatDraft = createStore(false);
2678
- let seq = 0;
2679
- function requestDraftOn(hostId, folder) {
2680
- request.set({ seq: ++seq, hostId, folder });
2681
- }
2682
- function requestFolderlessDraft() {
2683
- request.set({ seq: ++seq, hostId: LOCAL_HOST_KEY, folder: null, folderless: true });
2684
- }
2685
- function clearDraftRequest() {
2686
- request.set(null);
2687
- }
2688
- function useDraftRequest() {
2689
- return reactExports.useSyncExternalStore(request.subscribe, request.get, request.get);
2690
- }
2691
- function publishHomeProject(project) {
2692
- const current = home.get();
2693
- if (current?.path === project?.path && current?.hostId === project?.hostId) return;
2694
- home.set(project);
2695
- }
2696
- function publishChatDraft(open) {
2697
- chatDraft.set(open);
2698
- }
2699
- function useChatDraft() {
2700
- return reactExports.useSyncExternalStore(chatDraft.subscribe, chatDraft.get, chatDraft.get);
2701
- }
2702
- function useHomeProject() {
2703
- return reactExports.useSyncExternalStore(home.subscribe, home.get, home.get);
2704
- }
2705
2760
  function useTurnMenu(sessionId) {
2706
2761
  const { setActiveSessionId, refresh } = useSessionsActions();
2707
2762
  const setEventsPage = useSetEventsPage();
@@ -2733,7 +2788,7 @@ function useTurnMenu(sessionId) {
2733
2788
  return useTurnMenu$1(sessionId, actions);
2734
2789
  }
2735
2790
  const system = {
2736
- openPath: (path) => window.api.system.openPath(path),
2791
+ openPath: (path, at) => window.api.system.openPath(path, at),
2737
2792
  revealPath: (path) => window.api.system.revealPath(path)
2738
2793
  };
2739
2794
  function useOpenTarget() {
@@ -2756,13 +2811,13 @@ function useSessionMarkdownContext(session, hostName) {
2756
2811
  function useChipOpener(cwd) {
2757
2812
  const openTarget = useOpenTarget();
2758
2813
  return reactExports.useMemo(
2759
- () => async (path, kind, event) => {
2814
+ () => async (path, kind, event, at) => {
2760
2815
  if (kind === "dir") return openTarget.folder(path, cwd, event);
2761
2816
  if (openTarget.resolve(event) === "panel") {
2762
- await openTarget.file(path, event);
2817
+ await openTarget.file(path, event, at);
2763
2818
  return;
2764
2819
  }
2765
- return window.api.system.openPath(path).catch(() => false);
2820
+ return window.api.system.openPath(path, at).catch(() => false);
2766
2821
  },
2767
2822
  [openTarget, cwd]
2768
2823
  );
@@ -4841,7 +4896,7 @@ function ConversationComposer({
4841
4896
  scrolled,
4842
4897
  hostId,
4843
4898
  draft: draft2,
4844
- prompt,
4899
+ prompt: prompt2,
4845
4900
  search,
4846
4901
  searchOverlayOpen,
4847
4902
  meters,
@@ -4893,7 +4948,7 @@ function ConversationComposer({
4893
4948
  ) : /* @__PURE__ */ jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment, { children: [
4894
4949
  isNewSession && hostNotice && /* @__PURE__ */ jsxRuntimeExports.jsx(HostRemovedBanner, { notice: hostNotice, onDismiss: dismissHostNotice }),
4895
4950
  isNewSession && draft2.error && /* @__PURE__ */ jsxRuntimeExports.jsx(ComposerNotice, { text: draft2.error, onDismiss: () => draft2.setError(null) }),
4896
- prompt.needsProvider && providerReady === false && /* @__PURE__ */ jsxRuntimeExports.jsx(ConnectProviderCard, { "data-testid": "connect-provider", onConnect: () => openOnboarding("connect") }),
4951
+ prompt2.needsProvider && providerReady === false && /* @__PURE__ */ jsxRuntimeExports.jsx(ConnectProviderCard, { "data-testid": "connect-provider", onConnect: () => openOnboarding("connect") }),
4897
4952
  /* @__PURE__ */ jsxRuntimeExports.jsxs(ComposerDock, { children: [
4898
4953
  /* @__PURE__ */ jsxRuntimeExports.jsx(SelectTurnHint, { sessionId }),
4899
4954
  /* @__PURE__ */ jsxRuntimeExports.jsx(ApprovalDock, { sessionId })
@@ -4907,8 +4962,9 @@ function ConversationComposer({
4907
4962
  activeSessionId: sessionId,
4908
4963
  hostId,
4909
4964
  running: running && Boolean(session),
4910
- onStop: prompt.stop,
4911
- onSend: prompt.send,
4965
+ onStop: prompt2.stop,
4966
+ onSend: prompt2.send,
4967
+ messageDelivery: settings.messageDelivery,
4912
4968
  attachmentsEnabled: settings.attachmentsEnabled !== false,
4913
4969
  inlineAutocomplete: settings.inlineAutocomplete === true,
4914
4970
  promptSuggestions: settings.promptSuggestions === true,
@@ -5319,6 +5375,12 @@ const ConversationPane = reactExports.memo(function ConversationPane2({
5319
5375
  reactExports.useEffect(() => {
5320
5376
  if (!isNewSession) clearDraftRequest();
5321
5377
  }, [isNewSession]);
5378
+ const draftPrompt = useDraftPrompt();
5379
+ reactExports.useEffect(() => {
5380
+ if (!isNewSession || !draftPrompt) return;
5381
+ pushComposerDraft({ text: draftPrompt.text, attachments: [] });
5382
+ clearDraftPrompt();
5383
+ }, [isNewSession, draftPrompt]);
5322
5384
  const chatDraft2 = isNewSession && !draft2.server && draft2.folderPath === "";
5323
5385
  reactExports.useEffect(() => {
5324
5386
  publishChatDraft(chatDraft2);
@@ -5330,7 +5392,7 @@ const ConversationPane = reactExports.memo(function ConversationPane2({
5330
5392
  hydrated
5331
5393
  );
5332
5394
  const search = useComposerSearch(sessionId, scrollRef, actions.closeSearch);
5333
- const prompt = useSendPrompt({ session, running, draft: draft2, hostId, glideToBottom });
5395
+ const prompt2 = useSendPrompt({ session, running, draft: draft2, hostId, glideToBottom });
5334
5396
  const veiled = useSettledReveal(sessionId, hydrated) && !isNewSession;
5335
5397
  const { showRowIcons, projectHome: projectHomeOn } = useSettings().settings;
5336
5398
  const projectHome = isNewSession && projectHomeOn === true;
@@ -5342,7 +5404,7 @@ const ConversationPane = reactExports.memo(function ConversationPane2({
5342
5404
  scrolled: !projectHome && scrolledFromTop && !pinned,
5343
5405
  hostId,
5344
5406
  draft: draft2,
5345
- prompt,
5407
+ prompt: prompt2,
5346
5408
  search,
5347
5409
  searchOverlayOpen: searchOpen,
5348
5410
  meters,
@@ -6897,8 +6959,8 @@ function SideTab({ parentId, cwd }) {
6897
6959
  }
6898
6960
  );
6899
6961
  }
6900
- const DesktopDiffsTab = reactExports.lazy(() => __vitePreload(() => import("./file-tabs-CDruoNmZ.js"), true ? __vite__mapDeps([0,1,2,3,4,5,6,7,8,9]) : void 0, import.meta.url).then((m) => ({ default: m.DesktopDiffsTab })));
6901
- const DesktopFilesTab = reactExports.lazy(() => __vitePreload(() => import("./file-tabs-CDruoNmZ.js"), true ? __vite__mapDeps([0,1,2,3,4,5,6,7,8,9]) : void 0, import.meta.url).then((m) => ({ default: m.DesktopFilesTab })));
6962
+ const DesktopDiffsTab = reactExports.lazy(() => __vitePreload(() => import("./file-tabs-DWQZlQfx.js"), true ? __vite__mapDeps([0,1,2,3,4,5,6,7,8,9]) : void 0, import.meta.url).then((m) => ({ default: m.DesktopDiffsTab })));
6963
+ const DesktopFilesTab = reactExports.lazy(() => __vitePreload(() => import("./file-tabs-DWQZlQfx.js"), true ? __vite__mapDeps([0,1,2,3,4,5,6,7,8,9]) : void 0, import.meta.url).then((m) => ({ default: m.DesktopFilesTab })));
6902
6964
  const KEEP_ALIVE = /* @__PURE__ */ new Set([
6903
6965
  ARTIFACTS_PANEL_ID,
6904
6966
  BROWSER_PANEL_ID,
@@ -7094,6 +7156,8 @@ function ScopedSidePanel({ scope, fill }) {
7094
7156
  const panels = usePanelLayout();
7095
7157
  const budget = useLayoutBudget();
7096
7158
  const registry = useTabRegistry(scope);
7159
+ const artifactCount = countArtifacts(useSessionArtifacts(sessionId));
7160
+ const counts = reactExports.useMemo(() => ({ [ARTIFACTS_PANEL_ID]: artifactCount }), [artifactCount]);
7097
7161
  const overlay = !fill && budget.panelMode === "overlay";
7098
7162
  const hadTabs = reactExports.useRef(false);
7099
7163
  reactExports.useEffect(() => {
@@ -7129,6 +7193,7 @@ function ScopedSidePanel({ scope, fill }) {
7129
7193
  slidAway: budget.panelHidden,
7130
7194
  onReveal: budget.revealPanel,
7131
7195
  fill,
7196
+ counts,
7132
7197
  ...TAB_REGION_PROPS
7133
7198
  }
7134
7199
  );
@@ -7421,20 +7486,26 @@ function Sidebar({ onNewSession, hasAuth, onOpenAuth, onOpenSettings }) {
7421
7486
  });
7422
7487
  const onNewSessionRef = reactExports.useRef(onNewSession);
7423
7488
  onNewSessionRef.current = onNewSession;
7489
+ const [focusRequest, setFocusRequest] = reactExports.useState(0);
7490
+ reactExports.useEffect(() => {
7491
+ if (focusRequest > 0) focusComposerWhenReady();
7492
+ }, [focusRequest]);
7493
+ const requestComposerFocus = reactExports.useCallback(() => setFocusRequest((n) => n + 1), []);
7424
7494
  const onNewSessionIn = reactExports.useCallback(
7425
7495
  (fullPath) => {
7426
7496
  setDefaultFolder(fullPath);
7427
7497
  requestDraftOn(LOCAL_HOST_KEY, null);
7428
7498
  onNewSessionRef.current();
7499
+ requestComposerFocus();
7429
7500
  },
7430
- [setDefaultFolder]
7501
+ [setDefaultFolder, requestComposerFocus]
7431
7502
  );
7432
7503
  const projectHome = settings.projectHome === true;
7433
7504
  const homeProject = useHomeProject();
7434
7505
  const onNewSessionOrFocus = reactExports.useCallback(() => {
7435
- if (homeProject && activeSessionId == null) focusComposer();
7436
- else onNewSessionRef.current();
7437
- }, [homeProject, activeSessionId]);
7506
+ if (!(homeProject && activeSessionId == null)) onNewSessionRef.current();
7507
+ requestComposerFocus();
7508
+ }, [homeProject, activeSessionId, requestComposerFocus]);
7438
7509
  const chatsOpen = useChatDraft();
7439
7510
  const onOpenChats = reactExports.useCallback(() => {
7440
7511
  requestFolderlessDraft();
@@ -7759,159 +7830,6 @@ function usePinnedAccount(session) {
7759
7830
  const found = catalog.find((e) => e.providerKey === providerKey && e.account?.id === account)?.account;
7760
7831
  return found ? { label: found.label } : { label: "", signedOut: true };
7761
7832
  }
7762
- const EMPTY_SETTINGS = {
7763
- schema: { categories: [], items: [] },
7764
- actions: [],
7765
- values: {},
7766
- locked: []
7767
- };
7768
- const NO_INTEGRATIONS = [];
7769
- const noop = { get: () => EMPTY_SETTINGS, subscribe: () => () => {
7770
- } };
7771
- const noIntegrations = { get: () => NO_INTEGRATIONS, subscribe: () => () => {
7772
- } };
7773
- const KIND_LABEL = {
7774
- tools: "tool",
7775
- agents: "agent",
7776
- subagents: "sub-agent",
7777
- models: "model",
7778
- providers: "provider",
7779
- mcp: "MCP server",
7780
- skills: "skill"
7781
- };
7782
- function provenanceLabel(p) {
7783
- if (p.removed) return `hidden by ${p.removedBy ?? p.changedBy.at(-1) ?? "an extension"}`;
7784
- if (p.origin.kind === "extension" && p.changedBy.length <= 1)
7785
- return `added by ${p.origin.id ?? p.changedBy[0] ?? "an extension"}`;
7786
- return `modified by ${p.changedBy.join(", ")}`;
7787
- }
7788
- function errorText$1(err) {
7789
- const error = extensionsErrorOf(err);
7790
- if (error.code === "refused")
7791
- return error.message ?? (error.reason === "locked" ? "Locked by the config file." : "Refused.");
7792
- if (error.code === "unavailable") return "Not available here.";
7793
- return error.message;
7794
- }
7795
- function IntegrationRow({ integration }) {
7796
- const host2 = useExtensionsHost();
7797
- const [keys, setKeys] = reactExports.useState({});
7798
- const [busy, setBusy] = reactExports.useState(false);
7799
- const [error, setError] = reactExports.useState(null);
7800
- const run = (work) => {
7801
- setBusy(true);
7802
- setError(null);
7803
- void Promise.resolve(work()).catch((err) => setError(errorText$1(err))).finally(() => setBusy(false));
7804
- };
7805
- const connections = integration.connections ?? (integration.connection ? [integration.connection] : []);
7806
- const connected = connections.length > 0;
7807
- return /* @__PURE__ */ jsxRuntimeExports.jsxs("li", { className: "flex flex-col gap-1.5 py-2", "data-integration": integration.id, children: [
7808
- /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: "flex items-center gap-2", children: [
7809
- /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-[13px] font-medium", children: integration.name }),
7810
- /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-[12px] text-[var(--zg-text-muted)]", children: !connected ? "Not connected" : connections.length === 1 ? "Connected" : `${connections.length} accounts` })
7811
- ] }),
7812
- integration.description && /* @__PURE__ */ jsxRuntimeExports.jsx("p", { className: "text-[12px] text-[var(--zg-text-muted)]", children: integration.description }),
7813
- connected && /* @__PURE__ */ jsxRuntimeExports.jsx("ul", { "aria-label": `${integration.name} accounts`, className: "flex flex-col gap-1", children: connections.map((c) => /* @__PURE__ */ jsxRuntimeExports.jsxs("li", { className: "flex items-center gap-2 text-[12px]", "data-connection": c.account, children: [
7814
- /* @__PURE__ */ jsxRuntimeExports.jsx("span", { children: c.label ?? c.account }),
7815
- c.isDefault ? /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "zg-meta", children: "Default" }) : /* @__PURE__ */ jsxRuntimeExports.jsx(
7816
- "button",
7817
- {
7818
- type: "button",
7819
- className: "text-[12px] underline",
7820
- disabled: busy,
7821
- "aria-label": `Make ${c.label ?? c.account} the default`,
7822
- onClick: () => run(() => host2?.integrations?.setDefault(integration.id, c.account)),
7823
- children: "Make default"
7824
- }
7825
- ),
7826
- /* @__PURE__ */ jsxRuntimeExports.jsx(
7827
- "button",
7828
- {
7829
- type: "button",
7830
- className: "ml-auto text-[12px] underline",
7831
- disabled: busy,
7832
- "aria-label": `Disconnect ${c.label ?? c.account}`,
7833
- onClick: () => run(() => host2?.integrations?.disconnect(integration.id, { account: c.account })),
7834
- children: "Disconnect"
7835
- }
7836
- )
7837
- ] }, c.account)) }),
7838
- integration.methods.map(
7839
- (method) => method.type === "apiKey" ? /* @__PURE__ */ jsxRuntimeExports.jsxs(
7840
- "form",
7841
- {
7842
- className: "flex items-center gap-2",
7843
- onSubmit: (e) => {
7844
- e.preventDefault();
7845
- run(
7846
- () => host2?.integrations?.connect(integration.id, { methodId: method.id, key: keys[method.id] ?? "" }).then(() => setKeys((k) => ({ ...k, [method.id]: "" })))
7847
- );
7848
- },
7849
- children: [
7850
- /* @__PURE__ */ jsxRuntimeExports.jsx(
7851
- "input",
7852
- {
7853
- type: "password",
7854
- "aria-label": method.label,
7855
- placeholder: method.placeholder ?? method.label,
7856
- value: keys[method.id] ?? "",
7857
- onChange: (e) => setKeys((k) => ({ ...k, [method.id]: e.target.value })),
7858
- className: "zg-well flex-1 min-w-0 rounded px-2 py-1 text-[12px]"
7859
- }
7860
- ),
7861
- /* @__PURE__ */ jsxRuntimeExports.jsx("button", { type: "submit", disabled: busy || !keys[method.id], className: "text-[12px] underline", children: connected ? "Add account" : "Connect" })
7862
- ]
7863
- },
7864
- method.id
7865
- ) : /* @__PURE__ */ jsxRuntimeExports.jsx(
7866
- "button",
7867
- {
7868
- type: "button",
7869
- disabled: busy,
7870
- className: "self-start text-[12px] underline",
7871
- onClick: () => run(() => host2?.integrations?.connect(integration.id, { methodId: method.id })),
7872
- children: connected ? `Add account with ${method.label}` : method.label
7873
- },
7874
- method.id
7875
- )
7876
- ),
7877
- error && /* @__PURE__ */ jsxRuntimeExports.jsx("p", { role: "alert", className: "text-[12px] text-[var(--zg-danger)]", children: error })
7878
- ] });
7879
- }
7880
- function ExtensionSettingsSection() {
7881
- const host2 = useExtensionsHost();
7882
- const wire2 = useReadable(host2?.settings?.wire ?? noop);
7883
- const integrations = useReadable(host2?.integrations?.list ?? noIntegrations);
7884
- if (!host2) return null;
7885
- const locked = wire2.locked;
7886
- const changes = wire2.provenance ?? [];
7887
- if (locked.length === 0 && changes.length === 0 && integrations.length === 0) return null;
7888
- return /* @__PURE__ */ jsxRuntimeExports.jsxs("section", { "aria-label": "Extension settings", className: "flex flex-col gap-4", children: [
7889
- locked.length > 0 && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { children: [
7890
- /* @__PURE__ */ jsxRuntimeExports.jsx("h3", { className: "text-[12px] uppercase tracking-wide text-[var(--zg-text-muted)]", children: "Set by the config file" }),
7891
- /* @__PURE__ */ jsxRuntimeExports.jsx("ul", { className: "text-[12px]", children: locked.map((id) => {
7892
- const [extension = "", key2 = ""] = id.split(":");
7893
- const value = wire2.values[extension]?.[key2];
7894
- return /* @__PURE__ */ jsxRuntimeExports.jsxs("li", { className: "flex gap-2 py-0.5", "data-locked-setting": id, children: [
7895
- /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "font-mono", children: id }),
7896
- value !== void 0 && /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-[var(--zg-text-muted)]", children: String(value) }),
7897
- /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "ml-auto text-[var(--zg-text-muted)]", children: "locked" })
7898
- ] }, id);
7899
- }) })
7900
- ] }),
7901
- changes.length > 0 && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { children: [
7902
- /* @__PURE__ */ jsxRuntimeExports.jsx("h3", { className: "text-[12px] uppercase tracking-wide text-[var(--zg-text-muted)]", children: "Changed by extensions" }),
7903
- /* @__PURE__ */ jsxRuntimeExports.jsx("ul", { className: "text-[12px]", children: changes.map((p) => /* @__PURE__ */ jsxRuntimeExports.jsxs("li", { className: "flex gap-2 py-0.5", "data-catalog-change": `${p.kind}:${p.id}`, children: [
7904
- /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "text-[var(--zg-text-muted)]", children: KIND_LABEL[p.kind] }),
7905
- /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "font-mono", children: p.id }),
7906
- /* @__PURE__ */ jsxRuntimeExports.jsx("span", { className: "ml-auto text-[var(--zg-text-muted)]", children: provenanceLabel(p) })
7907
- ] }, `${p.kind}:${p.id}`)) })
7908
- ] }),
7909
- integrations.length > 0 && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { children: [
7910
- /* @__PURE__ */ jsxRuntimeExports.jsx("h3", { className: "text-[12px] uppercase tracking-wide text-[var(--zg-text-muted)]", children: "Integrations" }),
7911
- /* @__PURE__ */ jsxRuntimeExports.jsx("ul", { className: "divide-y divide-[var(--zg-border)]", children: integrations.map((integration) => /* @__PURE__ */ jsxRuntimeExports.jsx(IntegrationRow, { integration }, integration.id)) })
7912
- ] })
7913
- ] });
7914
- }
7915
7833
  const LABELS = {
7916
7834
  home: "Show the zidane folder in Finder",
7917
7835
  skills: "Show the skills folder in Finder",
@@ -8908,7 +8826,7 @@ function createElectronFilesHost(options) {
8908
8826
  },
8909
8827
  system: {
8910
8828
  isLocal: isOnThisMachine,
8911
- openPath: (path) => system2.openPath(path).catch(swallow),
8829
+ openPath: (path, at) => system2.openPath(path, at).catch(swallow),
8912
8830
  revealPath: (path) => system2.revealPath(path).catch(swallow)
8913
8831
  },
8914
8832
  mediaUrl: (source) => source.kind === "file" ? fileMediaUrl(source.cwd, source.path, source.version) : diffMediaUrl(source.cwd, source.path, source.side, source.version)
@@ -9845,6 +9763,10 @@ function AppShell({ appearanceFirstRun: appearanceFirstRun2 }) {
9845
9763
  ...forkTurn ? { fork: forkTurn } : {},
9846
9764
  blocked: modalOwnsInput
9847
9765
  });
9766
+ const [newSessionFocus, setNewSessionFocus] = reactExports.useState(0);
9767
+ reactExports.useEffect(() => {
9768
+ if (newSessionFocus > 0) focusComposerWhenReady();
9769
+ }, [newSessionFocus]);
9848
9770
  const handlers = reactExports.useMemo(() => {
9849
9771
  const { openTodos, openArtifacts, panelNext, panelPrev, closeTab, tabNext, tabPrev } = workspaceKeys;
9850
9772
  return {
@@ -9852,7 +9774,14 @@ function AppShell({ appearanceFirstRun: appearanceFirstRun2 }) {
9852
9774
  // not be mistaken for an `initialTab`.
9853
9775
  openSettings: () => openSettings(),
9854
9776
  // A standalone window shows one session: no sidebar, no switching from here.
9855
- ...standalone ? {} : { toggleSidebar, openMainSession, newSession: () => setActiveSessionId(null) },
9777
+ ...standalone ? {} : {
9778
+ toggleSidebar,
9779
+ openMainSession,
9780
+ newSession: () => {
9781
+ setActiveSessionId(null);
9782
+ setNewSessionFocus((n) => n + 1);
9783
+ }
9784
+ },
9856
9785
  ...activeSession ? { openSessionDetails } : {},
9857
9786
  ...activeSession ? { cycleAgent } : {},
9858
9787
  ...activeSession ? { openEffortPicker } : {},
@@ -10074,7 +10003,7 @@ function createElectronSessionHost(api, onStreamSignal2, onSettingsWritten) {
10074
10003
  queue: {
10075
10004
  items: queue.items,
10076
10005
  refresh: queue.refresh,
10077
- add: async (sessionId, text, options) => (await api.queue.add(key(sessionId), text, options?.activatedSkills, options?.attachments)).delivered,
10006
+ add: async (sessionId, text, options) => (await api.queue.add(key(sessionId), text, options?.activatedSkills, options?.attachments, options?.delivery)).delivered,
10078
10007
  remove: queue.drop,
10079
10008
  update: queue.edit,
10080
10009
  attachments: (sessionId, id) => api.queue.attachments(key(sessionId), id).catch(() => null),
@@ -10389,9 +10318,14 @@ function toChatModelProviders(entries) {
10389
10318
  function toPromptAttachments(attachments) {
10390
10319
  return attachments.flatMap((att) => {
10391
10320
  const match = /^data:([^;]+);base64,(.+)$/.exec(att.dataUrl ?? "");
10392
- return match ? [{ mediaType: match[1] ?? att.mediaType, data: match[2] ?? "", name: att.name }] : [];
10321
+ if (!match) return [];
10322
+ const original = wireOriginal(att.original);
10323
+ return [
10324
+ { mediaType: match[1] ?? att.mediaType, data: match[2] ?? "", name: att.name, ...original ? { original } : {} }
10325
+ ];
10393
10326
  });
10394
10327
  }
10328
+ const withoutOriginals = (attachments) => attachments.map(({ original: _original, ...att }) => att);
10395
10329
  const errorText = (err) => err?.message ?? String(err);
10396
10330
  function mapped(source, map) {
10397
10331
  let last;
@@ -10523,12 +10457,6 @@ function createElectronChatHost(api, streams, options = {}) {
10523
10457
  if (thinking)
10524
10458
  await api.sessions.setEffort(sessionId, thinking);
10525
10459
  };
10526
- const whileRunning = (deliver) => async (id, message) => {
10527
- const sessionId = id;
10528
- if (!store2.getRunningSnapshot(sessionId)) return false;
10529
- await deliver(sessionId, message);
10530
- return true;
10531
- };
10532
10460
  return {
10533
10461
  sessions: {
10534
10462
  list: mapped(rows2, (all) => all.map(toChatSession)),
@@ -10573,23 +10501,45 @@ function createElectronChatHost(api, streams, options = {}) {
10573
10501
  ...api.sidebar ? { views: electronSidebarViews(api.sidebar) } : {}
10574
10502
  },
10575
10503
  transcript,
10576
- async send({ sessionId: id, prompt, attachments, model, thinking, activatedSkills, refs, echo, keepDraft }) {
10504
+ async send({
10505
+ sessionId: id,
10506
+ prompt: prompt2,
10507
+ attachments,
10508
+ model,
10509
+ thinking,
10510
+ activatedSkills,
10511
+ refs,
10512
+ echo,
10513
+ keepDraft,
10514
+ delivery
10515
+ }) {
10577
10516
  const sessionId = id;
10517
+ if (delivery) {
10518
+ await applyChoice(sessionId, model, thinking);
10519
+ await api.queue.add(
10520
+ sessionId,
10521
+ prompt2,
10522
+ activatedSkills ? [...activatedSkills] : void 0,
10523
+ toPromptAttachments(attachments ?? []),
10524
+ delivery
10525
+ );
10526
+ return;
10527
+ }
10578
10528
  const echoed = echo !== false;
10579
- if (echoed) store2.appendUserPrompt(sessionId, prompt, refs, attachments ?? []);
10529
+ if (echoed) store2.appendUserPrompt(sessionId, prompt2, refs, withoutOriginals(attachments ?? []));
10580
10530
  try {
10581
10531
  await applyChoice(sessionId, model, thinking);
10582
10532
  const uploads = toPromptAttachments(attachments ?? []);
10583
10533
  await api.chat.send({
10584
10534
  sessionId,
10585
- prompt,
10535
+ prompt: prompt2,
10586
10536
  ...activatedSkills ? { activatedSkills: [...activatedSkills] } : {},
10587
10537
  ...uploads.length > 0 ? { attachments: uploads } : {},
10588
10538
  ...keepDraft ? { keepDraft: true } : {}
10589
10539
  });
10590
10540
  } catch (err) {
10591
10541
  store2.appendErrorEvent(sessionId, errorText(err));
10592
- if (echoed) store2.dropPendingEcho(sessionId, prompt);
10542
+ if (echoed) store2.dropPendingEcho(sessionId, prompt2);
10593
10543
  throw err;
10594
10544
  }
10595
10545
  },
@@ -10603,8 +10553,6 @@ function createElectronChatHost(api, streams, options = {}) {
10603
10553
  }
10604
10554
  } : {},
10605
10555
  ...api.auth ? { providerReady: (cwd) => api.auth.hasAny(cwd) } : {},
10606
- steer: whileRunning((sessionId, message) => api.chat.steer(sessionId, message)),
10607
- followUp: whileRunning((sessionId, message) => api.chat.followUp(sessionId, message)),
10608
10556
  interactions: {
10609
10557
  pending,
10610
10558
  all: () => allInteractions,
@@ -10657,10 +10605,39 @@ function BadgeMenu({ children }) {
10657
10605
  }),
10658
10606
  [focused]
10659
10607
  );
10608
+ const browser = useBadgeBrowser();
10660
10609
  const openSession = useOptionalSessionsActions()?.setActiveSessionId ?? null;
10661
10610
  const open = useChipOpener(null);
10662
10611
  const chips = reactExports.useMemo(() => ({ cwd: null, repoWebBase: null, open }), [open]);
10663
- return /* @__PURE__ */ jsxRuntimeExports.jsx(OpenSessionContext.Provider, { value: openSession, children: /* @__PURE__ */ jsxRuntimeExports.jsx(MarkdownContext.Provider, { value: chips, children: /* @__PURE__ */ jsxRuntimeExports.jsx(BadgeMenuProvider, { composer, system: window.api.system, children }) }) });
10612
+ return /* @__PURE__ */ jsxRuntimeExports.jsx(OpenSessionContext.Provider, { value: openSession, children: /* @__PURE__ */ jsxRuntimeExports.jsx(MarkdownContext.Provider, { value: chips, children: /* @__PURE__ */ jsxRuntimeExports.jsx(BadgeMenuProvider, { composer, system: window.api.system, browser, children }) }) });
10613
+ }
10614
+ function useBadgeBrowser() {
10615
+ const [name, setName] = reactExports.useState(null);
10616
+ reactExports.useEffect(() => {
10617
+ const read2 = () => void window.api.system.defaultBrowser().then(setName).catch(() => {
10618
+ });
10619
+ read2();
10620
+ window.addEventListener("focus", read2);
10621
+ return () => window.removeEventListener("focus", read2);
10622
+ }, []);
10623
+ const { sessions, activeSessionId } = useSessions();
10624
+ const panels = usePanelActions();
10625
+ const browserOn = useSettings().settings.browser !== false;
10626
+ const latest = reactExports.useRef({ sessions, panels });
10627
+ latest.current = { sessions, panels };
10628
+ return reactExports.useMemo(() => {
10629
+ if (!browserOn || !activeSessionId) return { name };
10630
+ return {
10631
+ name,
10632
+ openInPane: (url) => {
10633
+ const { sessions: list2, panels: p } = latest.current;
10634
+ const row = list2.find((s) => s.id === activeSessionId);
10635
+ const cwd = browserStore.page(activeSessionId)?.cwd ?? (row?.projectRoot || row?.cwd || "");
10636
+ browserStore.open(activeSessionId, cwd, url);
10637
+ p.requestAttention(BROWSER_PANEL_ID, { open: true });
10638
+ }
10639
+ };
10640
+ }, [name, browserOn, activeSessionId]);
10664
10641
  }
10665
10642
  const RECENTS_KEY = "zg:palette:v1";
10666
10643
  function createElectronPaletteHost(options) {
@@ -10668,7 +10645,7 @@ function createElectronPaletteHost(options) {
10668
10645
  return {
10669
10646
  listCommands: async ({ cwd, hostId }) => api.commands.list(cwd, hostId ?? null),
10670
10647
  listFiles: async ({ root }) => {
10671
- const entries = await api.workspace.list(root, { showIgnored: false });
10648
+ const { entries } = await api.workspace.list(root, { showIgnored: false });
10672
10649
  return entries.map((e) => ({ path: e.path, kind: e.kind }));
10673
10650
  },
10674
10651
  extensions: {
@@ -10991,7 +10968,7 @@ const subscribe = (listener) => {
10991
10968
  listeners.add(listener);
10992
10969
  return () => void listeners.delete(listener);
10993
10970
  };
10994
- const EditorWorkerPool = reactExports.lazy(() => __vitePreload(() => import("./EditorWorkers-D0xeQ5Kf.js"), true ? __vite__mapDeps([2,1,3,4,5,6,7,8,9]) : void 0, import.meta.url).then((m) => ({ default: m.EditorWorkerPool })));
10971
+ const EditorWorkerPool = reactExports.lazy(() => __vitePreload(() => import("./EditorWorkers-CY0St-9O.js"), true ? __vite__mapDeps([2,1,3,4,5,6,7,8,9]) : void 0, import.meta.url).then((m) => ({ default: m.EditorWorkerPool })));
10995
10972
  function EditorWorkersHold() {
10996
10973
  const on2 = reactExports.useSyncExternalStore(
10997
10974
  subscribe,