@halcyonlabs/app 0.47.0-halcyon.21 → 0.47.0-halcyon.22
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/app/dist/assets/{AddMachineDialog-4BQFC118.js → AddMachineDialog-BlVfh9PM.js} +1 -1
- package/app/dist/assets/AddMachineDialog-BlVfh9PM.js.br +0 -0
- package/app/dist/assets/AddMachineDialog-BlVfh9PM.js.gz +0 -0
- package/app/dist/assets/{AppCommandShortcutHint-BlXOfa_n.js → AppCommandShortcutHint-C1mIupNX.js} +1 -1
- package/app/dist/assets/{AppFileExternalNavigationDispatcher-fGD_vTns.js → AppFileExternalNavigationDispatcher-zdrgMBvF.js} +1 -1
- package/app/dist/assets/AppFileExternalNavigationDispatcher-zdrgMBvF.js.br +0 -0
- package/app/dist/assets/AppFileExternalNavigationDispatcher-zdrgMBvF.js.gz +0 -0
- package/app/dist/assets/{AppToasterView-DzbjTKdn.js → AppToasterView-C6IQDk4H.js} +1 -1
- package/app/dist/assets/{BbDiff-BkqgAZD9.js → BbDiff-CORXfK92.js} +1 -1
- package/app/dist/assets/BbDiff-CORXfK92.js.br +0 -0
- package/app/dist/assets/BbDiff-CORXfK92.js.gz +0 -0
- package/app/dist/assets/{BbDiffSplit-DTvWaW-n.js → BbDiffSplit-By8A1QN-.js} +2 -2
- package/app/dist/assets/BbDiffSplit-By8A1QN-.js.br +0 -0
- package/app/dist/assets/BbDiffSplit-By8A1QN-.js.gz +0 -0
- package/app/dist/assets/{BbSourceCode-Dqw4VrLu.js → BbSourceCode-C3we2GZp.js} +1 -1
- package/app/dist/assets/BbSourceCode-C3we2GZp.js.br +0 -0
- package/app/dist/assets/BbSourceCode-C3we2GZp.js.gz +0 -0
- package/app/dist/assets/{BrowserTabDeck-CuHEyZd6.js → BrowserTabDeck-BtVycavD.js} +1 -1
- package/app/dist/assets/BrowserTabDeck-BtVycavD.js.br +0 -0
- package/app/dist/assets/BrowserTabDeck-BtVycavD.js.gz +0 -0
- package/app/dist/assets/{CommandPaletteBody-DynxiDg6.js → CommandPaletteBody-JfQwJqGn.js} +1 -1
- package/app/dist/assets/CommandPaletteBody-JfQwJqGn.js.br +0 -0
- package/app/dist/assets/CommandPaletteBody-JfQwJqGn.js.gz +0 -0
- package/app/dist/assets/{DiffHost-3UTZIJNs.js → DiffHost-DEYVmsVa.js} +1 -1
- package/app/dist/assets/DiffHost-DEYVmsVa.js.br +0 -0
- package/app/dist/assets/DiffHost-DEYVmsVa.js.gz +0 -0
- package/app/dist/assets/{ExperimentalFileLinkMenu-C0RXVabs.js → ExperimentalFileLinkMenu-B-B8GXE8.js} +1 -1
- package/app/dist/assets/ExperimentalFileLinkMenu-B-B8GXE8.js.br +0 -0
- package/app/dist/assets/ExperimentalFileLinkMenu-B-B8GXE8.js.gz +0 -0
- package/app/dist/assets/{FilePreview-BxgJ2jjI.js → FilePreview-BHoPmg-c.js} +1 -1
- package/app/dist/assets/FilePreview-BHoPmg-c.js.br +0 -0
- package/app/dist/assets/FilePreview-BHoPmg-c.js.gz +0 -0
- package/app/dist/assets/{GitDiffCardHeader-Ce736y-m.js → GitDiffCardHeader-6LP_7oWh.js} +1 -1
- package/app/dist/assets/GitDiffCardHeader-6LP_7oWh.js.br +0 -0
- package/app/dist/assets/GitDiffCardHeader-6LP_7oWh.js.gz +0 -0
- package/app/dist/assets/{InlineMessageEditorFrame-Dud8h1It.js → InlineMessageEditorFrame-DyVCSKBJ.js} +1 -1
- package/app/dist/assets/InlineMessageEditorFrame-DyVCSKBJ.js.br +0 -0
- package/app/dist/assets/InlineMessageEditorFrame-DyVCSKBJ.js.gz +0 -0
- package/app/dist/assets/{MachineRenameDialog-C_ZV5gEB.js → MachineRenameDialog-HGiXO0UG.js} +1 -1
- package/app/dist/assets/MachineRenameDialog-HGiXO0UG.js.br +0 -0
- package/app/dist/assets/MachineRenameDialog-HGiXO0UG.js.gz +0 -0
- package/app/dist/assets/{MachineSettingsView-BWSIpenw.js → MachineSettingsView-C4q9cbRr.js} +1 -1
- package/app/dist/assets/MachineSettingsView-C4q9cbRr.js.br +0 -0
- package/app/dist/assets/MachineSettingsView-C4q9cbRr.js.gz +0 -0
- package/app/dist/assets/{MicrophonePreferences-CNEhQgAS.js → MicrophonePreferences-qaOpiph1.js} +1 -1
- package/app/dist/assets/MicrophonePreferences-qaOpiph1.js.br +0 -0
- package/app/dist/assets/MicrophonePreferences-qaOpiph1.js.gz +0 -0
- package/app/dist/assets/{ModelReasoningMenu-BeNCpeQf.js → ModelReasoningMenu-CVmIvyBC.js} +1 -1
- package/app/dist/assets/ModelReasoningMenu-CVmIvyBC.js.br +0 -0
- package/app/dist/assets/ModelReasoningMenu-CVmIvyBC.js.gz +0 -0
- package/app/dist/assets/{NewTabPage-CsPDV6iC.js → NewTabPage-BD3LFok4.js} +1 -1
- package/app/dist/assets/NewTabPage-BD3LFok4.js.br +0 -0
- package/app/dist/assets/NewTabPage-BD3LFok4.js.gz +0 -0
- package/app/dist/assets/{NewThreadComposer-BY0jUSbs.js → NewThreadComposer-C2ZKRVh2.js} +1 -1
- package/app/dist/assets/NewThreadComposer-C2ZKRVh2.js.br +0 -0
- package/app/dist/assets/NewThreadComposer-C2ZKRVh2.js.gz +0 -0
- package/app/dist/assets/{OnboardingFlow-BQdrTtHC.js → OnboardingFlow-D7-YF2ZM.js} +1 -1
- package/app/dist/assets/OnboardingFlow-D7-YF2ZM.js.br +0 -0
- package/app/dist/assets/OnboardingFlow-D7-YF2ZM.js.gz +0 -0
- package/app/dist/assets/{OptionPicker-sql35hd_.js → OptionPicker-DzY4ri8R.js} +1 -1
- package/app/dist/assets/OptionPicker-DzY4ri8R.js.br +0 -0
- package/app/dist/assets/OptionPicker-DzY4ri8R.js.gz +0 -0
- package/app/dist/assets/{PaletteShell-B9KeWKsT.js → PaletteShell-4enjLs-M.js} +1 -1
- package/app/dist/assets/PaletteShell-4enjLs-M.js.br +0 -0
- package/app/dist/assets/PaletteShell-4enjLs-M.js.gz +0 -0
- package/app/dist/assets/{PaneMaximizeButton-CGBzyikf.js → PaneMaximizeButton-40ZGXf3w.js} +1 -1
- package/app/dist/assets/PaneMaximizeButton-40ZGXf3w.js.br +0 -0
- package/app/dist/assets/PaneMaximizeButton-40ZGXf3w.js.gz +0 -0
- package/app/dist/assets/{PierreLineSelectionActions-BYL6I0xE.js → PierreLineSelectionActions-DrQj-N__.js} +1 -1
- package/app/dist/assets/PierreLineSelectionActions-DrQj-N__.js.br +0 -0
- package/app/dist/assets/PierreLineSelectionActions-DrQj-N__.js.gz +0 -0
- package/app/dist/assets/{PluginPanelRightPanelHost-Dj-wS_Ki.js → PluginPanelRightPanelHost-Ha0PrCa9.js} +1 -1
- package/app/dist/assets/PluginPanelRightPanelHost-Ha0PrCa9.js.br +0 -0
- package/app/dist/assets/PluginPanelRightPanelHost-Ha0PrCa9.js.gz +0 -0
- package/app/dist/assets/{PluginThreadChat-Dh-No9s-.js → PluginThreadChat-D_tbXHEo.js} +1 -1
- package/app/dist/assets/PluginThreadChat-D_tbXHEo.js.br +0 -0
- package/app/dist/assets/PluginThreadChat-D_tbXHEo.js.gz +0 -0
- package/app/dist/assets/ProjectDetailSettingsView-Ckp-m-c0.js +1 -0
- package/app/dist/assets/ProjectDetailSettingsView-Ckp-m-c0.js.br +0 -0
- package/app/dist/assets/ProjectDetailSettingsView-Ckp-m-c0.js.gz +0 -0
- package/app/dist/assets/{ProjectMachineSetupDialog-BW4gUYj0.js → ProjectMachineSetupDialog-Bn43xkw-.js} +1 -1
- package/app/dist/assets/ProjectMachineSetupDialog-Bn43xkw-.js.br +0 -0
- package/app/dist/assets/ProjectMachineSetupDialog-Bn43xkw-.js.gz +0 -0
- package/app/dist/assets/{ProjectsSettingsSection-BI_xhcA2.js → ProjectsSettingsSection-DXHostGl.js} +1 -1
- package/app/dist/assets/ProjectsSettingsSection-DXHostGl.js.br +0 -0
- package/app/dist/assets/ProjectsSettingsSection-DXHostGl.js.gz +0 -0
- package/app/dist/assets/{QueuedMessagesList-BEyivVSE.js → QueuedMessagesList-C53i8_rz.js} +1 -1
- package/app/dist/assets/QueuedMessagesList-C53i8_rz.js.br +0 -0
- package/app/dist/assets/QueuedMessagesList-C53i8_rz.js.gz +0 -0
- package/app/dist/assets/{RemotePathBrowser-DVW5AwBs.js → RemotePathBrowser-CsCxZdUk.js} +1 -1
- package/app/dist/assets/RemotePathBrowser-CsCxZdUk.js.br +0 -0
- package/app/dist/assets/RemotePathBrowser-CsCxZdUk.js.gz +0 -0
- package/app/dist/assets/{RootComposeView-Cbnwq7j_.js → RootComposeView-CsV3Ut7E.js} +1 -1
- package/app/dist/assets/RootComposeView-CsV3Ut7E.js.br +0 -0
- package/app/dist/assets/RootComposeView-CsV3Ut7E.js.gz +0 -0
- package/app/dist/assets/{SecondaryPanelLayout-fG8BuYv-.js → SecondaryPanelLayout-BPTIpQ2F.js} +1 -1
- package/app/dist/assets/SecondaryPanelLayout-BPTIpQ2F.js.br +0 -0
- package/app/dist/assets/SecondaryPanelLayout-BPTIpQ2F.js.gz +0 -0
- package/app/dist/assets/{ServerMoveOverlayView-CPWZimVv.js → ServerMoveOverlayView-DxwZdF-Z.js} +1 -1
- package/app/dist/assets/ServerMoveOverlayView-DxwZdF-Z.js.br +0 -0
- package/app/dist/assets/ServerMoveOverlayView-DxwZdF-Z.js.gz +0 -0
- package/app/dist/assets/{SettingsSidebar-DxfoXXKW.js → SettingsSidebar-CYEXglCo.js} +1 -1
- package/app/dist/assets/SettingsSidebar-CYEXglCo.js.br +0 -0
- package/app/dist/assets/SettingsSidebar-CYEXglCo.js.gz +0 -0
- package/app/dist/assets/{SettingsView-D_DkKpuv.js → SettingsView-B3HpJfUo.js} +1 -1
- package/app/dist/assets/SettingsView-B3HpJfUo.js.br +0 -0
- package/app/dist/assets/SettingsView-B3HpJfUo.js.gz +0 -0
- package/app/dist/assets/{SidebarFooterCustomize-VQoenr5y.js → SidebarFooterCustomize-BGXeu0og.js} +1 -1
- package/app/dist/assets/SidebarFooterCustomize-BGXeu0og.js.br +0 -0
- package/app/dist/assets/SidebarFooterCustomize-BGXeu0og.js.gz +0 -0
- package/app/dist/assets/{SidebarVisibilityCustomize-DUKnlz9Y.js → SidebarVisibilityCustomize-Qy7hHO5j.js} +1 -1
- package/app/dist/assets/SidebarVisibilityCustomize-Qy7hHO5j.js.br +0 -0
- package/app/dist/assets/SidebarVisibilityCustomize-Qy7hHO5j.js.gz +0 -0
- package/app/dist/assets/{SourceCodeHost-BlXLvWv2.js → SourceCodeHost-CJpVOgCd.js} +2 -2
- package/app/dist/assets/SourceCodeHost-CJpVOgCd.js.br +0 -0
- package/app/dist/assets/SourceCodeHost-CJpVOgCd.js.gz +0 -0
- package/app/dist/assets/{SplitWorkspaceRoute-6w4G23kc.js → SplitWorkspaceRoute-CWPCkdjo.js} +2 -2
- package/app/dist/assets/SplitWorkspaceRoute-CWPCkdjo.js.br +0 -0
- package/app/dist/assets/SplitWorkspaceRoute-CWPCkdjo.js.gz +0 -0
- package/app/dist/assets/{TerminalOutputBlock-BxBSWJr_.js → TerminalOutputBlock-BzxpJ5H3.js} +1 -1
- package/app/dist/assets/TerminalOutputBlock-BzxpJ5H3.js.br +0 -0
- package/app/dist/assets/TerminalOutputBlock-BzxpJ5H3.js.gz +0 -0
- package/app/dist/assets/{ThreadActionsMenu-ChpSKv80.js → ThreadActionsMenu-DfUIyx3e.js} +1 -1
- package/app/dist/assets/ThreadActionsMenu-DfUIyx3e.js.br +0 -0
- package/app/dist/assets/ThreadActionsMenu-DfUIyx3e.js.gz +0 -0
- package/app/dist/assets/{ThreadDetailView-CfH3uWo-.js → ThreadDetailView-BqzwklQd.js} +3 -3
- package/app/dist/assets/ThreadDetailView-BqzwklQd.js.br +0 -0
- package/app/dist/assets/ThreadDetailView-BqzwklQd.js.gz +0 -0
- package/app/dist/assets/{ThreadSearchPaletteMode-B72v3f5V.js → ThreadSearchPaletteMode-Dni8lJt2.js} +1 -1
- package/app/dist/assets/ThreadSearchPaletteMode-Dni8lJt2.js.br +0 -0
- package/app/dist/assets/ThreadSearchPaletteMode-Dni8lJt2.js.gz +0 -0
- package/app/dist/assets/{ThreadSecondaryPanel-4nIZy4h9.js → ThreadSecondaryPanel-Cfah9-yR.js} +1 -1
- package/app/dist/assets/ThreadSecondaryPanel-Cfah9-yR.js.br +0 -0
- package/app/dist/assets/ThreadSecondaryPanel-Cfah9-yR.js.gz +0 -0
- package/app/dist/assets/{ThreadSecondaryPanelTabContent-8-e35_Me.js → ThreadSecondaryPanelTabContent-ByMkWr4B.js} +1 -1
- package/app/dist/assets/ThreadSecondaryPanelTabContent-ByMkWr4B.js.br +0 -0
- package/app/dist/assets/ThreadSecondaryPanelTabContent-ByMkWr4B.js.gz +0 -0
- package/app/dist/assets/{ThreadStatusGlyph-C9tzRtlV.js → ThreadStatusGlyph-MjAgpNtv.js} +1 -1
- package/app/dist/assets/ThreadStatusGlyph-MjAgpNtv.js.br +0 -0
- package/app/dist/assets/ThreadStatusGlyph-MjAgpNtv.js.gz +0 -0
- package/app/dist/assets/{ThreadTerminalPanel-CqTk9L2y.js → ThreadTerminalPanel-2UtGqd1Z.js} +1 -1
- package/app/dist/assets/ThreadTerminalPanel-2UtGqd1Z.js.br +0 -0
- package/app/dist/assets/ThreadTerminalPanel-2UtGqd1Z.js.gz +0 -0
- package/app/dist/assets/{ThreadTerminalView-B6XNBrJ9.js → ThreadTerminalView-BqsCrU1_.js} +1 -1
- package/app/dist/assets/ThreadTerminalView-BqsCrU1_.js.br +0 -0
- package/app/dist/assets/ThreadTerminalView-BqsCrU1_.js.gz +0 -0
- package/app/dist/assets/{ThreadTimelineNavigationContext-DbZHHZfY.js → ThreadTimelineNavigationContext-B_vg4bPl.js} +2 -2
- package/app/dist/assets/ThreadTimelineNavigationContext-B_vg4bPl.js.br +0 -0
- package/app/dist/assets/ThreadTimelineNavigationContext-B_vg4bPl.js.gz +0 -0
- package/app/dist/assets/{ThreadUnarchiveButton-CtjS9UkR.js → ThreadUnarchiveButton-CnlHu7Dv.js} +1 -1
- package/app/dist/assets/{TimelineDetailScroll-CpFZhWhU.js → TimelineDetailScroll-CIXDGLcx.js} +1 -1
- package/app/dist/assets/TimelineDetailScroll-CIXDGLcx.js.br +0 -0
- package/app/dist/assets/TimelineDetailScroll-CIXDGLcx.js.gz +0 -0
- package/app/dist/assets/{TimelineFileDiffBlock-JiOlR3O8.js → TimelineFileDiffBlock-Cy_6X6XY.js} +1 -1
- package/app/dist/assets/TimelineFileDiffBlock-Cy_6X6XY.js.br +0 -0
- package/app/dist/assets/TimelineFileDiffBlock-Cy_6X6XY.js.gz +0 -0
- package/app/dist/assets/{TimelineSelectionMenu-DT4qwoFI.js → TimelineSelectionMenu-DzrSCC7e.js} +1 -1
- package/app/dist/assets/TimelineSelectionMenu-DzrSCC7e.js.br +0 -0
- package/app/dist/assets/TimelineSelectionMenu-DzrSCC7e.js.gz +0 -0
- package/app/dist/assets/{ToolsView-nAAic88Z.js → ToolsView-B8oDS6Ek.js} +1 -1
- package/app/dist/assets/ToolsView-B8oDS6Ek.js.br +0 -0
- package/app/dist/assets/ToolsView-B8oDS6Ek.js.gz +0 -0
- package/app/dist/assets/{ToolsViewSplits-Blo3GJMQ.js → ToolsViewSplits-JK-JmYIg.js} +2 -2
- package/app/dist/assets/ToolsViewSplits-JK-JmYIg.js.br +0 -0
- package/app/dist/assets/ToolsViewSplits-JK-JmYIg.js.gz +0 -0
- package/app/dist/assets/{WaveformVisualizer-BrH_nwc4.js → WaveformVisualizer-GDJ4mJRx.js} +1 -1
- package/app/dist/assets/WaveformVisualizer-GDJ4mJRx.js.br +0 -0
- package/app/dist/assets/WaveformVisualizer-GDJ4mJRx.js.gz +0 -0
- package/app/dist/assets/{absolute-file-path-W_eh4kPq.js → absolute-file-path-B-cUOroV.js} +1 -1
- package/app/dist/assets/{app-fixed-tab-navigation-DX9s-gCj.js → app-fixed-tab-navigation-BpDuGNDS.js} +1 -1
- package/app/dist/assets/app-fixed-tab-navigation-BpDuGNDS.js.br +0 -0
- package/app/dist/assets/app-fixed-tab-navigation-BpDuGNDS.js.gz +0 -0
- package/app/dist/assets/{audio-input-device-preference-DsU6GGNE.js → audio-input-device-preference-BeKjzmnK.js} +1 -1
- package/app/dist/assets/audio-input-device-preference-BeKjzmnK.js.br +0 -0
- package/app/dist/assets/audio-input-device-preference-BeKjzmnK.js.gz +0 -0
- package/app/dist/assets/{bottom-anchored-scroll-body-C8n22V_o.js → bottom-anchored-scroll-body-DaHi9M7W.js} +1 -1
- package/app/dist/assets/bottom-anchored-scroll-body-DaHi9M7W.js.br +0 -0
- package/app/dist/assets/bottom-anchored-scroll-body-DaHi9M7W.js.gz +0 -0
- package/app/dist/assets/{browser-url-B0SjaYti.js → browser-url-BdtGkCbj.js} +1 -1
- package/app/dist/assets/browser-url-BdtGkCbj.js.br +0 -0
- package/app/dist/assets/browser-url-BdtGkCbj.js.gz +0 -0
- package/app/dist/assets/{checkbox-Ct38DhHB.js → checkbox-5zZ_V1_F.js} +1 -1
- package/app/dist/assets/checkbox-5zZ_V1_F.js.br +0 -0
- package/app/dist/assets/checkbox-5zZ_V1_F.js.gz +0 -0
- package/app/dist/assets/{code-loading-skeletons-C_099GEq.js → code-loading-skeletons-DzoCzgll.js} +1 -1
- package/app/dist/assets/code-loading-skeletons-DzoCzgll.js.br +0 -0
- package/app/dist/assets/code-loading-skeletons-DzoCzgll.js.gz +0 -0
- package/app/dist/assets/{code-rendering-OxBy5zPr.js → code-rendering-A15j47Uy.js} +1 -1
- package/app/dist/assets/{code-theme-registration-BokyXo30.js → code-theme-registration-q5iRcekZ.js} +1 -1
- package/app/dist/assets/{detail-card-Cj628JNK.js → detail-card-BvFcq0Ru.js} +1 -1
- package/app/dist/assets/detail-card-BvFcq0Ru.js.br +0 -0
- package/app/dist/assets/detail-card-BvFcq0Ru.js.gz +0 -0
- package/app/dist/assets/{diff-stats-tally-MtORWItG.js → diff-stats-tally-DA41wrwM.js} +1 -1
- package/app/dist/assets/diff-stats-tally-DA41wrwM.js.br +0 -0
- package/app/dist/assets/diff-stats-tally-DA41wrwM.js.gz +0 -0
- package/app/dist/assets/{environment-mutations-rP4eROm2.js → environment-mutations-Bl2PK8kR.js} +1 -1
- package/app/dist/assets/environment-mutations-Bl2PK8kR.js.br +0 -0
- package/app/dist/assets/environment-mutations-Bl2PK8kR.js.gz +0 -0
- package/app/dist/assets/{environment-workspace-display-O1JRHfbV.js → environment-workspace-display-DdMsNL4x.js} +3 -3
- package/app/dist/assets/environment-workspace-display-DdMsNL4x.js.br +0 -0
- package/app/dist/assets/environment-workspace-display-DdMsNL4x.js.gz +0 -0
- package/app/dist/assets/{event-code-block-DqUZCAii.js → event-code-block-DT4pyQ5R.js} +1 -1
- package/app/dist/assets/event-code-block-DT4pyQ5R.js.br +0 -0
- package/app/dist/assets/event-code-block-DT4pyQ5R.js.gz +0 -0
- package/app/dist/assets/{expandable-text-herJC70e.js → expandable-text-CtGFLpBX.js} +1 -1
- package/app/dist/assets/expandable-text-CtGFLpBX.js.br +0 -0
- package/app/dist/assets/expandable-text-CtGFLpBX.js.gz +0 -0
- package/app/dist/assets/{file-opener-preference-BEeek6dm.js → file-opener-preference-B5sOAhVM.js} +1 -1
- package/app/dist/assets/{file-path-link-Cni9Azi2.js → file-path-link-xsn9GiAq.js} +1 -1
- package/app/dist/assets/file-path-link-xsn9GiAq.js.br +0 -0
- package/app/dist/assets/file-path-link-xsn9GiAq.js.gz +0 -0
- package/app/dist/assets/{host-mutations-Ckc-eVys.js → host-mutations-Bf4idS3m.js} +1 -1
- package/app/dist/assets/host-mutations-Bf4idS3m.js.br +0 -0
- package/app/dist/assets/host-mutations-Bf4idS3m.js.gz +0 -0
- package/app/dist/assets/{icon-extended-DDFkslJU.js → icon-extended-C7x9E4W9.js} +1 -1
- package/app/dist/assets/icon-extended-C7x9E4W9.js.br +0 -0
- package/app/dist/assets/icon-extended-C7x9E4W9.js.gz +0 -0
- package/app/dist/assets/{image-lightbox-BW1bqQJM.js → image-lightbox-CzY6y14n.js} +1 -1
- package/app/dist/assets/image-lightbox-CzY6y14n.js.br +0 -0
- package/app/dist/assets/image-lightbox-CzY6y14n.js.gz +0 -0
- package/app/dist/assets/index-B-RDC4LU.js +395 -0
- package/app/dist/assets/index-B-RDC4LU.js.br +0 -0
- package/app/dist/assets/index-B-RDC4LU.js.gz +0 -0
- package/app/dist/assets/{inline-rename-editor-wjwfk7v2.js → inline-rename-editor-DUVacR_R.js} +1 -1
- package/app/dist/assets/inline-rename-editor-DUVacR_R.js.br +0 -0
- package/app/dist/assets/inline-rename-editor-DUVacR_R.js.gz +0 -0
- package/app/dist/assets/{launcherRow-rIW7Z6Xm.js → launcherRow-C9Htfook.js} +1 -1
- package/app/dist/assets/launcherRow-C9Htfook.js.br +0 -0
- package/app/dist/assets/launcherRow-C9Htfook.js.gz +0 -0
- package/app/dist/assets/{localhost-link-rewrite-description-Bovg3W--.js → localhost-link-rewrite-description-DfPXtfPs.js} +1 -1
- package/app/dist/assets/localhost-link-rewrite-description-DfPXtfPs.js.br +0 -0
- package/app/dist/assets/localhost-link-rewrite-description-DfPXtfPs.js.gz +0 -0
- package/app/dist/assets/{machine-provider-queries-CRlWTEz7.js → machine-provider-queries-By9Ipha4.js} +1 -1
- package/app/dist/assets/machine-provider-queries-By9Ipha4.js.br +0 -0
- package/app/dist/assets/machine-provider-queries-By9Ipha4.js.gz +0 -0
- package/app/dist/assets/{machine-server-access-D3hixOIC.js → machine-server-access-6584jQ7-.js} +1 -1
- package/app/dist/assets/{markdown-file-image-routing-DAIVjxLg.js → markdown-file-image-routing-0_tf5d6g.js} +1 -1
- package/app/dist/assets/{markdown-html-B-Kyh3zI.js → markdown-html-JK4Gnuli.js} +1 -1
- package/app/dist/assets/markdown-html-JK4Gnuli.js.br +0 -0
- package/app/dist/assets/markdown-html-JK4Gnuli.js.gz +0 -0
- package/app/dist/assets/{markdown-local-file-link-C89PR8d5.js → markdown-local-file-link-DXjnoCIE.js} +1 -1
- package/app/dist/assets/markdown-local-file-link-DXjnoCIE.js.br +0 -0
- package/app/dist/assets/markdown-local-file-link-DXjnoCIE.js.gz +0 -0
- package/app/dist/assets/{markdown-preview-B7BmqIlu.js → markdown-preview-Bfwf40CC.js} +2 -2
- package/app/dist/assets/markdown-preview-Bfwf40CC.js.br +0 -0
- package/app/dist/assets/markdown-preview-Bfwf40CC.js.gz +0 -0
- package/app/dist/assets/{markdown-prompt-mentions-B0JRhgrI.js → markdown-prompt-mentions-BuHEkhJs.js} +1 -1
- package/app/dist/assets/markdown-prompt-mentions-BuHEkhJs.js.br +0 -0
- package/app/dist/assets/markdown-prompt-mentions-BuHEkhJs.js.gz +0 -0
- package/app/dist/assets/{model-load-error-message-B-HKqgUD.js → model-load-error-message-CnA6byT0.js} +1 -1
- package/app/dist/assets/model-load-error-message-CnA6byT0.js.br +0 -0
- package/app/dist/assets/model-load-error-message-CnA6byT0.js.gz +0 -0
- package/app/dist/assets/onboarding-telemetry-D6SXoh98.js +1 -0
- package/app/dist/assets/{open-in-editor-button-CQGreiCk.js → open-in-editor-button-jScMiuob.js} +1 -1
- package/app/dist/assets/open-in-editor-button-jScMiuob.js.br +0 -0
- package/app/dist/assets/open-in-editor-button-jScMiuob.js.gz +0 -0
- package/app/dist/assets/{page-shell-BHTOdeQn.js → page-shell-ClYdhKtX.js} +1 -1
- package/app/dist/assets/page-shell-ClYdhKtX.js.br +0 -0
- package/app/dist/assets/page-shell-ClYdhKtX.js.gz +0 -0
- package/app/dist/assets/{pierre-worker-pool-Bm9cLA-c.js → pierre-worker-pool-D1nZ9Lcz.js} +1 -1
- package/app/dist/assets/pierre-worker-pool-D1nZ9Lcz.js.br +0 -0
- package/app/dist/assets/pierre-worker-pool-D1nZ9Lcz.js.gz +0 -0
- package/app/dist/assets/{plugin-detail-navigation-CmSGTNyL.js → plugin-detail-navigation-BD4jDXuP.js} +1 -1
- package/app/dist/assets/plugin-detail-navigation-BD4jDXuP.js.br +0 -0
- package/app/dist/assets/plugin-detail-navigation-BD4jDXuP.js.gz +0 -0
- package/app/dist/assets/{plugin-frontend-BdQdYbWd.js → plugin-frontend-qfGFykt-.js} +3 -3
- package/app/dist/assets/plugin-frontend-qfGFykt-.js.br +0 -0
- package/app/dist/assets/plugin-frontend-qfGFykt-.js.gz +0 -0
- package/app/dist/assets/{plugin-ui-DyNDyPD9.js → plugin-ui-DfbeKd73.js} +1 -1
- package/app/dist/assets/plugin-ui-DfbeKd73.js.br +0 -0
- package/app/dist/assets/plugin-ui-DfbeKd73.js.gz +0 -0
- package/app/dist/assets/{project-default-execution-options-query-h6eTG6_Q.js → project-default-execution-options-query-DQKDDkRo.js} +1 -1
- package/app/dist/assets/{queued-editor-typeahead-layout-BKui5z7C.js → queued-editor-typeahead-layout-DKGYsvQ-.js} +1 -1
- package/app/dist/assets/queued-editor-typeahead-layout-DKGYsvQ-.js.br +0 -0
- package/app/dist/assets/queued-editor-typeahead-layout-DKGYsvQ-.js.gz +0 -0
- package/app/dist/assets/{queued-messages-layout-BuEilXwP.js → queued-messages-layout-ClZkWHAV.js} +1 -1
- package/app/dist/assets/queued-messages-layout-ClZkWHAV.js.br +0 -0
- package/app/dist/assets/queued-messages-layout-ClZkWHAV.js.gz +0 -0
- package/app/dist/assets/{resource-list-B6MkAu8v.js → resource-list-CC7zN47b.js} +1 -1
- package/app/dist/assets/resource-list-CC7zN47b.js.br +0 -0
- package/app/dist/assets/resource-list-CC7zN47b.js.gz +0 -0
- package/app/dist/assets/root-compose-create-preference-z0-Xe1ss.js +1 -0
- package/app/dist/assets/{save-file-DYAtq7A9.js → save-file-Cs9LWQ4E.js} +1 -1
- package/app/dist/assets/{settings-nav-DbICcozy.js → settings-nav-BKMVpc5b.js} +1 -1
- package/app/dist/assets/settings-nav-BKMVpc5b.js.br +0 -0
- package/app/dist/assets/settings-nav-BKMVpc5b.js.gz +0 -0
- package/app/dist/assets/{settings-sections-Cq0VX9E8.js → settings-sections-LqqPm8q3.js} +1 -1
- package/app/dist/assets/settings-sections-LqqPm8q3.js.br +0 -0
- package/app/dist/assets/settings-sections-LqqPm8q3.js.gz +0 -0
- package/app/dist/assets/{shortcut-pill-DldxrKgx.js → shortcut-pill-DOMeVrnR.js} +1 -1
- package/app/dist/assets/{sidebarTouchSensor-D7jKXrfM.js → sidebarTouchSensor-PP8-SQld.js} +1 -1
- package/app/dist/assets/sidebarTouchSensor-PP8-SQld.js.br +0 -0
- package/app/dist/assets/sidebarTouchSensor-PP8-SQld.js.gz +0 -0
- package/app/dist/assets/{switch-CzvlSesf.js → switch-B9nrFpZc.js} +1 -1
- package/app/dist/assets/switch-B9nrFpZc.js.br +0 -0
- package/app/dist/assets/switch-B9nrFpZc.js.gz +0 -0
- package/app/dist/assets/{textarea-9yaIMD7J.js → textarea-2fJEsqsi.js} +1 -1
- package/app/dist/assets/{thread-event-parser-BqVpKC6z.js → thread-event-parser-DedSEtmp.js} +1 -1
- package/app/dist/assets/thread-event-parser-DedSEtmp.js.br +0 -0
- package/app/dist/assets/thread-event-parser-DedSEtmp.js.gz +0 -0
- package/app/dist/assets/{thread-panel-queries-C3MI4mdc.js → thread-panel-queries-5N40syTx.js} +1 -1
- package/app/dist/assets/thread-panel-queries-5N40syTx.js.br +0 -0
- package/app/dist/assets/thread-panel-queries-5N40syTx.js.gz +0 -0
- package/app/dist/assets/{thread-runtime-mutations-Cr1H7KSz.js → thread-runtime-mutations-BY5xzme0.js} +1 -1
- package/app/dist/assets/thread-runtime-mutations-BY5xzme0.js.br +0 -0
- package/app/dist/assets/thread-runtime-mutations-BY5xzme0.js.gz +0 -0
- package/app/dist/assets/{thread-terminal-queries-B4JkOWS2.js → thread-terminal-queries-BF7AB7qh.js} +1 -1
- package/app/dist/assets/thread-terminal-queries-BF7AB7qh.js.br +0 -0
- package/app/dist/assets/thread-terminal-queries-BF7AB7qh.js.gz +0 -0
- package/app/dist/assets/{threadRecentItems-DI2mgj7S.js → threadRecentItems-CYYbbS1r.js} +1 -1
- package/app/dist/assets/threadRecentItems-CYYbbS1r.js.br +0 -0
- package/app/dist/assets/threadRecentItems-CYYbbS1r.js.gz +0 -0
- package/app/dist/assets/{threadWorkspaceOpenPath-BQgtUYL5.js → threadWorkspaceOpenPath-B5anoH2-.js} +1 -1
- package/app/dist/assets/threadWorkspaceOpenPath-B5anoH2-.js.br +0 -0
- package/app/dist/assets/threadWorkspaceOpenPath-B5anoH2-.js.gz +0 -0
- package/app/dist/assets/{title-bar-scroll-fade-CxbgbTcm.js → title-bar-scroll-fade-BfqL4WEJ.js} +1 -1
- package/app/dist/assets/title-bar-scroll-fade-BfqL4WEJ.js.br +0 -0
- package/app/dist/assets/title-bar-scroll-fade-BfqL4WEJ.js.gz +0 -0
- package/app/dist/assets/{truncate-start-CaCnKnh9.js → truncate-start-D-P3rLti.js} +1 -1
- package/app/dist/assets/{use-hover-popover-CyIdak3c.js → use-hover-popover-Bb8PuVyu.js} +1 -1
- package/app/dist/assets/use-hover-popover-Bb8PuVyu.js.br +0 -0
- package/app/dist/assets/use-hover-popover-Bb8PuVyu.js.gz +0 -0
- package/app/dist/assets/{useElementWidth-CL3Nb-eq.js → useElementWidth-vSwGqg9a.js} +1 -1
- package/app/dist/assets/useElementWidth-vSwGqg9a.js.br +0 -0
- package/app/dist/assets/useElementWidth-vSwGqg9a.js.gz +0 -0
- package/app/dist/assets/{useLocalOpenTargets-yzd9-Ceh.js → useLocalOpenTargets-DqjYzi0b.js} +1 -1
- package/app/dist/assets/useLocalOpenTargets-DqjYzi0b.js.br +0 -0
- package/app/dist/assets/useLocalOpenTargets-DqjYzi0b.js.gz +0 -0
- package/app/dist/assets/{usePanelResizeSnap-dys9IwEk.js → usePanelResizeSnap-Dvi7sa3e.js} +1 -1
- package/app/dist/assets/usePanelResizeSnap-Dvi7sa3e.js.br +0 -0
- package/app/dist/assets/usePanelResizeSnap-Dvi7sa3e.js.gz +0 -0
- package/app/dist/assets/{usePanelTerminals-BN8UCJFO.js → usePanelTerminals-B9MNSur4.js} +1 -1
- package/app/dist/assets/usePanelTerminals-B9MNSur4.js.br +0 -0
- package/app/dist/assets/usePanelTerminals-B9MNSur4.js.gz +0 -0
- package/app/dist/assets/{usePathSuggestions-DkeFAE7l.js → usePathSuggestions-zhZ-4fh8.js} +1 -1
- package/app/dist/assets/usePathSuggestions-zhZ-4fh8.js.br +0 -0
- package/app/dist/assets/usePathSuggestions-zhZ-4fh8.js.gz +0 -0
- package/app/dist/assets/{useResolvedLiveFileTarget-43fAKgDx.js → useResolvedLiveFileTarget-CZZwqw4L.js} +1 -1
- package/app/dist/assets/useResolvedLiveFileTarget-CZZwqw4L.js.br +0 -0
- package/app/dist/assets/useResolvedLiveFileTarget-CZZwqw4L.js.gz +0 -0
- package/app/dist/assets/{useThreadTerminalController-DcWLbe8W.js → useThreadTerminalController-CvXy-5HP.js} +1 -1
- package/app/dist/assets/useThreadTerminalController-CvXy-5HP.js.br +0 -0
- package/app/dist/assets/useThreadTerminalController-CvXy-5HP.js.gz +0 -0
- package/app/dist/assets/{workspace-change-summary-Bd3p-LXz.js → workspace-change-summary-CY01JLmJ.js} +1 -1
- package/app/dist/assets/workspace-change-summary-CY01JLmJ.js.br +0 -0
- package/app/dist/assets/workspace-change-summary-CY01JLmJ.js.gz +0 -0
- package/app/dist/assets/{workspace-checkout-display-DMp28yCr.js → workspace-checkout-display-C9B0QPLi.js} +4 -4
- package/app/dist/assets/workspace-checkout-display-C9B0QPLi.js.br +0 -0
- package/app/dist/assets/workspace-checkout-display-C9B0QPLi.js.gz +0 -0
- package/app/dist/index.html +17 -17
- package/app/dist/index.html.br +0 -0
- package/app/dist/index.html.gz +0 -0
- package/dist/index.d.ts +35 -6
- package/dist/index.js +9 -5
- package/host-daemon/dist/bb +2 -2
- package/host-daemon/dist/bb-chunks/{browser-DVIVPPSL.js → browser-3RYUCU4H.js} +1 -1
- package/host-daemon/dist/bb-chunks/{chunk-ATDR5E2C.js → chunk-CZ4K4Z4T.js} +1 -1
- package/host-daemon/dist/bb-chunks/{chunk-ZWBRH7R6.js → chunk-DCRUVPRR.js} +1 -1
- package/host-daemon/dist/bb-chunks/{chunk-7EOZF4HA.js → chunk-F7XCHQA3.js} +1 -1
- package/host-daemon/dist/bb-chunks/{chunk-JWA6VJYL.js → chunk-FYCUA6H6.js} +1 -1
- package/host-daemon/dist/bb-chunks/{chunk-5ZMA4MIX.js → chunk-FZ76WJJG.js} +1 -1
- package/host-daemon/dist/bb-chunks/{chunk-UXSJP3YM.js → chunk-GVXLVAX4.js} +1 -1
- package/host-daemon/dist/bb-chunks/chunk-HDUE2YKX.js +2199 -0
- package/host-daemon/dist/bb-chunks/{chunk-REEBSQ75.js → chunk-L5UJ4QUD.js} +1 -1
- package/host-daemon/dist/bb-chunks/{chunk-QE47NRKX.js → chunk-NZY63D4X.js} +1 -1
- package/host-daemon/dist/bb-chunks/{chunk-MLYXPSJC.js → chunk-UCNQXYXP.js} +1 -1
- package/host-daemon/dist/bb-chunks/chunk-WMCZMPZ4.js +2 -0
- package/host-daemon/dist/bb-chunks/{client-YJBBA4JS.js → client-NLWJKXJ2.js} +1 -1
- package/host-daemon/dist/bb-chunks/{commander-errors-P6LP2OHL.js → commander-errors-GDOJDU37.js} +1 -1
- package/host-daemon/dist/bb-chunks/{context-env-LJ5IITUO.js → context-env-VLEFLYWD.js} +1 -1
- package/host-daemon/dist/bb-chunks/{context-hints-MUUUMT2P.js → context-hints-FXEXGMFT.js} +1 -1
- package/host-daemon/dist/bb-chunks/{diagnostics-5EMHJNW7.js → diagnostics-ZKJGPJUH.js} +1 -1
- package/host-daemon/dist/bb-chunks/{environment-ZRSQFVHG.js → environment-CY5JUFSR.js} +1 -1
- package/host-daemon/dist/bb-chunks/{file-AEVJYJAY.js → file-KGZLZ36T.js} +1 -1
- package/host-daemon/dist/bb-chunks/{guide-GLY5UY4M.js → guide-MXAVSGKZ.js} +1 -1
- package/host-daemon/dist/bb-chunks/{machine-Z5QSPWEE.js → machine-Y7XFS7EJ.js} +1 -1
- package/host-daemon/dist/bb-chunks/{marketplace-4CGZ3NTM.js → marketplace-QLPRDZTC.js} +1 -1
- package/host-daemon/dist/bb-chunks/{plugin-VO7RP4JU.js → plugin-K276UYTK.js} +1 -1
- package/host-daemon/dist/bb-chunks/{plugin-cli-proxy-6Y6TTP7A.js → plugin-cli-proxy-QE7C6YLF.js} +1 -1
- package/host-daemon/dist/bb-chunks/project-QD44GO6S.js +2 -0
- package/host-daemon/dist/bb-chunks/{prompt-history-ZNIBNYER.js → prompt-history-YGK557NG.js} +1 -1
- package/host-daemon/dist/bb-chunks/{provider-TJ4DGKBX.js → provider-FAAY2EKV.js} +1 -1
- package/host-daemon/dist/bb-chunks/{server-YMSYCILC.js → server-Y7FRWA4U.js} +1 -1
- package/host-daemon/dist/bb-chunks/{settings-5CKNFTFZ.js → settings-76RZ35GN.js} +1 -1
- package/host-daemon/dist/bb-chunks/{skill-BMQPIFAD.js → skill-HMSLPSPW.js} +1 -1
- package/host-daemon/dist/bb-chunks/{status-2DJ3O6QU.js → status-GJFZ5YDD.js} +1 -1
- package/host-daemon/dist/bb-chunks/{terminal-NWC5PO4A.js → terminal-LSZHPIET.js} +1 -1
- package/host-daemon/dist/bb-chunks/{theme-OEOGYFXJ.js → theme-BMV5THCU.js} +1 -1
- package/host-daemon/dist/bb-chunks/{thread-AI6SXNXK.js → thread-UZ44ZBA2.js} +1 -1
- package/host-daemon/dist/bb-chunks/thread-event-parser-SIFYMDOV.js +2 -0
- package/host-daemon/dist/bb-chunks/{updates-DFLJJDO4.js → updates-IDCLXRIV.js} +1 -1
- package/host-daemon/dist/bb-chunks/{voice-ZSACREC3.js → voice-EXZARJ2J.js} +1 -1
- package/host-daemon/dist/daemon-bundle.mjs +102 -102
- package/package.json +1 -1
- package/server/dist/builtin-plugins/orbit/dist/assets/orbit/revision +1 -1
- package/server/dist/builtin-plugins/orbit/dist/server.js +52 -52
- package/server/dist/drizzle/0147_project_permission_escalation.sql +1 -0
- package/server/dist/drizzle/meta/0147_snapshot.json +5295 -0
- package/server/dist/drizzle/meta/_journal.json +7 -0
- package/server/dist/start-server.js +26 -7
- package/app/dist/assets/AddMachineDialog-4BQFC118.js.br +0 -0
- package/app/dist/assets/AddMachineDialog-4BQFC118.js.gz +0 -0
- package/app/dist/assets/AppFileExternalNavigationDispatcher-fGD_vTns.js.br +0 -0
- package/app/dist/assets/AppFileExternalNavigationDispatcher-fGD_vTns.js.gz +0 -0
- package/app/dist/assets/BbDiff-BkqgAZD9.js.br +0 -0
- package/app/dist/assets/BbDiff-BkqgAZD9.js.gz +0 -0
- package/app/dist/assets/BbDiffSplit-DTvWaW-n.js.br +0 -0
- package/app/dist/assets/BbDiffSplit-DTvWaW-n.js.gz +0 -0
- package/app/dist/assets/BbSourceCode-Dqw4VrLu.js.br +0 -0
- package/app/dist/assets/BbSourceCode-Dqw4VrLu.js.gz +0 -0
- package/app/dist/assets/BrowserTabDeck-CuHEyZd6.js.br +0 -0
- package/app/dist/assets/BrowserTabDeck-CuHEyZd6.js.gz +0 -0
- package/app/dist/assets/CommandPaletteBody-DynxiDg6.js.br +0 -0
- package/app/dist/assets/CommandPaletteBody-DynxiDg6.js.gz +0 -0
- package/app/dist/assets/DiffHost-3UTZIJNs.js.br +0 -0
- package/app/dist/assets/DiffHost-3UTZIJNs.js.gz +0 -0
- package/app/dist/assets/ExperimentalFileLinkMenu-C0RXVabs.js.br +0 -0
- package/app/dist/assets/ExperimentalFileLinkMenu-C0RXVabs.js.gz +0 -0
- package/app/dist/assets/FilePreview-BxgJ2jjI.js.br +0 -0
- package/app/dist/assets/FilePreview-BxgJ2jjI.js.gz +0 -0
- package/app/dist/assets/GitDiffCardHeader-Ce736y-m.js.br +0 -0
- package/app/dist/assets/GitDiffCardHeader-Ce736y-m.js.gz +0 -0
- package/app/dist/assets/InlineMessageEditorFrame-Dud8h1It.js.br +0 -0
- package/app/dist/assets/InlineMessageEditorFrame-Dud8h1It.js.gz +0 -0
- package/app/dist/assets/MachineRenameDialog-C_ZV5gEB.js.br +0 -0
- package/app/dist/assets/MachineRenameDialog-C_ZV5gEB.js.gz +0 -0
- package/app/dist/assets/MachineSettingsView-BWSIpenw.js.br +0 -0
- package/app/dist/assets/MachineSettingsView-BWSIpenw.js.gz +0 -0
- package/app/dist/assets/MicrophonePreferences-CNEhQgAS.js.br +0 -0
- package/app/dist/assets/MicrophonePreferences-CNEhQgAS.js.gz +0 -0
- package/app/dist/assets/ModelReasoningMenu-BeNCpeQf.js.br +0 -0
- package/app/dist/assets/ModelReasoningMenu-BeNCpeQf.js.gz +0 -0
- package/app/dist/assets/NewTabPage-CsPDV6iC.js.br +0 -0
- package/app/dist/assets/NewTabPage-CsPDV6iC.js.gz +0 -0
- package/app/dist/assets/NewThreadComposer-BY0jUSbs.js.br +0 -0
- package/app/dist/assets/NewThreadComposer-BY0jUSbs.js.gz +0 -0
- package/app/dist/assets/OnboardingFlow-BQdrTtHC.js.br +0 -0
- package/app/dist/assets/OnboardingFlow-BQdrTtHC.js.gz +0 -0
- package/app/dist/assets/OptionPicker-sql35hd_.js.br +0 -0
- package/app/dist/assets/OptionPicker-sql35hd_.js.gz +0 -0
- package/app/dist/assets/PaletteShell-B9KeWKsT.js.br +0 -0
- package/app/dist/assets/PaletteShell-B9KeWKsT.js.gz +0 -0
- package/app/dist/assets/PaneMaximizeButton-CGBzyikf.js.br +0 -0
- package/app/dist/assets/PaneMaximizeButton-CGBzyikf.js.gz +0 -0
- package/app/dist/assets/PierreLineSelectionActions-BYL6I0xE.js.br +0 -0
- package/app/dist/assets/PierreLineSelectionActions-BYL6I0xE.js.gz +0 -0
- package/app/dist/assets/PluginPanelRightPanelHost-Dj-wS_Ki.js.br +0 -0
- package/app/dist/assets/PluginPanelRightPanelHost-Dj-wS_Ki.js.gz +0 -0
- package/app/dist/assets/PluginThreadChat-Dh-No9s-.js.br +0 -0
- package/app/dist/assets/PluginThreadChat-Dh-No9s-.js.gz +0 -0
- package/app/dist/assets/ProjectDetailSettingsView-BOV7URzQ.js +0 -1
- package/app/dist/assets/ProjectDetailSettingsView-BOV7URzQ.js.br +0 -0
- package/app/dist/assets/ProjectDetailSettingsView-BOV7URzQ.js.gz +0 -0
- package/app/dist/assets/ProjectMachineSetupDialog-BW4gUYj0.js.br +0 -0
- package/app/dist/assets/ProjectMachineSetupDialog-BW4gUYj0.js.gz +0 -0
- package/app/dist/assets/ProjectsSettingsSection-BI_xhcA2.js.br +0 -0
- package/app/dist/assets/ProjectsSettingsSection-BI_xhcA2.js.gz +0 -0
- package/app/dist/assets/QueuedMessagesList-BEyivVSE.js.br +0 -0
- package/app/dist/assets/QueuedMessagesList-BEyivVSE.js.gz +0 -0
- package/app/dist/assets/RemotePathBrowser-DVW5AwBs.js.br +0 -0
- package/app/dist/assets/RemotePathBrowser-DVW5AwBs.js.gz +0 -0
- package/app/dist/assets/RootComposeView-Cbnwq7j_.js.br +0 -0
- package/app/dist/assets/RootComposeView-Cbnwq7j_.js.gz +0 -0
- package/app/dist/assets/SecondaryPanelLayout-fG8BuYv-.js.br +0 -0
- package/app/dist/assets/SecondaryPanelLayout-fG8BuYv-.js.gz +0 -0
- package/app/dist/assets/ServerMoveOverlayView-CPWZimVv.js.br +0 -0
- package/app/dist/assets/ServerMoveOverlayView-CPWZimVv.js.gz +0 -0
- package/app/dist/assets/SettingsSidebar-DxfoXXKW.js.br +0 -0
- package/app/dist/assets/SettingsSidebar-DxfoXXKW.js.gz +0 -0
- package/app/dist/assets/SettingsView-D_DkKpuv.js.br +0 -0
- package/app/dist/assets/SettingsView-D_DkKpuv.js.gz +0 -0
- package/app/dist/assets/SidebarFooterCustomize-VQoenr5y.js.br +0 -0
- package/app/dist/assets/SidebarFooterCustomize-VQoenr5y.js.gz +0 -0
- package/app/dist/assets/SidebarVisibilityCustomize-DUKnlz9Y.js.br +0 -0
- package/app/dist/assets/SidebarVisibilityCustomize-DUKnlz9Y.js.gz +0 -0
- package/app/dist/assets/SourceCodeHost-BlXLvWv2.js.br +0 -0
- package/app/dist/assets/SourceCodeHost-BlXLvWv2.js.gz +0 -0
- package/app/dist/assets/SplitWorkspaceRoute-6w4G23kc.js.br +0 -0
- package/app/dist/assets/SplitWorkspaceRoute-6w4G23kc.js.gz +0 -0
- package/app/dist/assets/TerminalOutputBlock-BxBSWJr_.js.br +0 -0
- package/app/dist/assets/TerminalOutputBlock-BxBSWJr_.js.gz +0 -0
- package/app/dist/assets/ThreadActionsMenu-ChpSKv80.js.br +0 -0
- package/app/dist/assets/ThreadActionsMenu-ChpSKv80.js.gz +0 -0
- package/app/dist/assets/ThreadDetailView-CfH3uWo-.js.br +0 -0
- package/app/dist/assets/ThreadDetailView-CfH3uWo-.js.gz +0 -0
- package/app/dist/assets/ThreadSearchPaletteMode-B72v3f5V.js.br +0 -0
- package/app/dist/assets/ThreadSearchPaletteMode-B72v3f5V.js.gz +0 -0
- package/app/dist/assets/ThreadSecondaryPanel-4nIZy4h9.js.br +0 -0
- package/app/dist/assets/ThreadSecondaryPanel-4nIZy4h9.js.gz +0 -0
- package/app/dist/assets/ThreadSecondaryPanelTabContent-8-e35_Me.js.br +0 -0
- package/app/dist/assets/ThreadSecondaryPanelTabContent-8-e35_Me.js.gz +0 -0
- package/app/dist/assets/ThreadStatusGlyph-C9tzRtlV.js.br +0 -0
- package/app/dist/assets/ThreadStatusGlyph-C9tzRtlV.js.gz +0 -0
- package/app/dist/assets/ThreadTerminalPanel-CqTk9L2y.js.br +0 -0
- package/app/dist/assets/ThreadTerminalPanel-CqTk9L2y.js.gz +0 -0
- package/app/dist/assets/ThreadTerminalView-B6XNBrJ9.js.br +0 -0
- package/app/dist/assets/ThreadTerminalView-B6XNBrJ9.js.gz +0 -0
- package/app/dist/assets/ThreadTimelineNavigationContext-DbZHHZfY.js.br +0 -0
- package/app/dist/assets/ThreadTimelineNavigationContext-DbZHHZfY.js.gz +0 -0
- package/app/dist/assets/TimelineDetailScroll-CpFZhWhU.js.br +0 -0
- package/app/dist/assets/TimelineDetailScroll-CpFZhWhU.js.gz +0 -0
- package/app/dist/assets/TimelineFileDiffBlock-JiOlR3O8.js.br +0 -0
- package/app/dist/assets/TimelineFileDiffBlock-JiOlR3O8.js.gz +0 -0
- package/app/dist/assets/TimelineSelectionMenu-DT4qwoFI.js.br +0 -0
- package/app/dist/assets/TimelineSelectionMenu-DT4qwoFI.js.gz +0 -0
- package/app/dist/assets/ToolsView-nAAic88Z.js.br +0 -0
- package/app/dist/assets/ToolsView-nAAic88Z.js.gz +0 -0
- package/app/dist/assets/ToolsViewSplits-Blo3GJMQ.js.br +0 -0
- package/app/dist/assets/ToolsViewSplits-Blo3GJMQ.js.gz +0 -0
- package/app/dist/assets/WaveformVisualizer-BrH_nwc4.js.br +0 -0
- package/app/dist/assets/WaveformVisualizer-BrH_nwc4.js.gz +0 -0
- package/app/dist/assets/app-fixed-tab-navigation-DX9s-gCj.js.br +0 -0
- package/app/dist/assets/app-fixed-tab-navigation-DX9s-gCj.js.gz +0 -0
- package/app/dist/assets/audio-input-device-preference-DsU6GGNE.js.br +0 -0
- package/app/dist/assets/audio-input-device-preference-DsU6GGNE.js.gz +0 -0
- package/app/dist/assets/bottom-anchored-scroll-body-C8n22V_o.js.br +0 -0
- package/app/dist/assets/bottom-anchored-scroll-body-C8n22V_o.js.gz +0 -0
- package/app/dist/assets/browser-url-B0SjaYti.js.br +0 -0
- package/app/dist/assets/browser-url-B0SjaYti.js.gz +0 -0
- package/app/dist/assets/checkbox-Ct38DhHB.js.br +0 -0
- package/app/dist/assets/checkbox-Ct38DhHB.js.gz +0 -0
- package/app/dist/assets/code-loading-skeletons-C_099GEq.js.br +0 -5
- package/app/dist/assets/code-loading-skeletons-C_099GEq.js.gz +0 -0
- package/app/dist/assets/detail-card-Cj628JNK.js.br +0 -0
- package/app/dist/assets/detail-card-Cj628JNK.js.gz +0 -0
- package/app/dist/assets/diff-stats-tally-MtORWItG.js.br +0 -0
- package/app/dist/assets/diff-stats-tally-MtORWItG.js.gz +0 -0
- package/app/dist/assets/environment-mutations-rP4eROm2.js.br +0 -0
- package/app/dist/assets/environment-mutations-rP4eROm2.js.gz +0 -0
- package/app/dist/assets/environment-workspace-display-O1JRHfbV.js.br +0 -0
- package/app/dist/assets/environment-workspace-display-O1JRHfbV.js.gz +0 -0
- package/app/dist/assets/event-code-block-DqUZCAii.js.br +0 -0
- package/app/dist/assets/event-code-block-DqUZCAii.js.gz +0 -0
- package/app/dist/assets/expandable-text-herJC70e.js.br +0 -0
- package/app/dist/assets/expandable-text-herJC70e.js.gz +0 -0
- package/app/dist/assets/file-path-link-Cni9Azi2.js.br +0 -0
- package/app/dist/assets/file-path-link-Cni9Azi2.js.gz +0 -0
- package/app/dist/assets/host-mutations-Ckc-eVys.js.br +0 -0
- package/app/dist/assets/host-mutations-Ckc-eVys.js.gz +0 -0
- package/app/dist/assets/icon-extended-DDFkslJU.js.br +0 -0
- package/app/dist/assets/icon-extended-DDFkslJU.js.gz +0 -0
- package/app/dist/assets/image-lightbox-BW1bqQJM.js.br +0 -0
- package/app/dist/assets/image-lightbox-BW1bqQJM.js.gz +0 -0
- package/app/dist/assets/index-BBxUiLNy.js +0 -395
- package/app/dist/assets/index-BBxUiLNy.js.br +0 -0
- package/app/dist/assets/index-BBxUiLNy.js.gz +0 -0
- package/app/dist/assets/inline-rename-editor-wjwfk7v2.js.br +0 -0
- package/app/dist/assets/inline-rename-editor-wjwfk7v2.js.gz +0 -0
- package/app/dist/assets/launcherRow-rIW7Z6Xm.js.br +0 -0
- package/app/dist/assets/launcherRow-rIW7Z6Xm.js.gz +0 -0
- package/app/dist/assets/localhost-link-rewrite-description-Bovg3W--.js.br +0 -0
- package/app/dist/assets/localhost-link-rewrite-description-Bovg3W--.js.gz +0 -0
- package/app/dist/assets/machine-provider-queries-CRlWTEz7.js.br +0 -0
- package/app/dist/assets/machine-provider-queries-CRlWTEz7.js.gz +0 -0
- package/app/dist/assets/markdown-html-B-Kyh3zI.js.br +0 -0
- package/app/dist/assets/markdown-html-B-Kyh3zI.js.gz +0 -0
- package/app/dist/assets/markdown-local-file-link-C89PR8d5.js.br +0 -0
- package/app/dist/assets/markdown-local-file-link-C89PR8d5.js.gz +0 -0
- package/app/dist/assets/markdown-preview-B7BmqIlu.js.br +0 -0
- package/app/dist/assets/markdown-preview-B7BmqIlu.js.gz +0 -0
- package/app/dist/assets/markdown-prompt-mentions-B0JRhgrI.js.br +0 -0
- package/app/dist/assets/markdown-prompt-mentions-B0JRhgrI.js.gz +0 -0
- package/app/dist/assets/model-load-error-message-B-HKqgUD.js.br +0 -0
- package/app/dist/assets/model-load-error-message-B-HKqgUD.js.gz +0 -0
- package/app/dist/assets/onboarding-telemetry-C21cbjI_.js +0 -1
- package/app/dist/assets/open-in-editor-button-CQGreiCk.js.br +0 -0
- package/app/dist/assets/open-in-editor-button-CQGreiCk.js.gz +0 -0
- package/app/dist/assets/page-shell-BHTOdeQn.js.br +0 -0
- package/app/dist/assets/page-shell-BHTOdeQn.js.gz +0 -0
- package/app/dist/assets/pierre-worker-pool-Bm9cLA-c.js.br +0 -0
- package/app/dist/assets/pierre-worker-pool-Bm9cLA-c.js.gz +0 -0
- package/app/dist/assets/plugin-detail-navigation-CmSGTNyL.js.br +0 -0
- package/app/dist/assets/plugin-detail-navigation-CmSGTNyL.js.gz +0 -0
- package/app/dist/assets/plugin-frontend-BdQdYbWd.js.br +0 -0
- package/app/dist/assets/plugin-frontend-BdQdYbWd.js.gz +0 -0
- package/app/dist/assets/plugin-ui-DyNDyPD9.js.br +0 -0
- package/app/dist/assets/plugin-ui-DyNDyPD9.js.gz +0 -0
- package/app/dist/assets/queued-editor-typeahead-layout-BKui5z7C.js.br +0 -0
- package/app/dist/assets/queued-editor-typeahead-layout-BKui5z7C.js.gz +0 -0
- package/app/dist/assets/queued-messages-layout-BuEilXwP.js.br +0 -0
- package/app/dist/assets/queued-messages-layout-BuEilXwP.js.gz +0 -0
- package/app/dist/assets/resource-list-B6MkAu8v.js.br +0 -0
- package/app/dist/assets/resource-list-B6MkAu8v.js.gz +0 -0
- package/app/dist/assets/root-compose-create-preference-DDv947dq.js +0 -1
- package/app/dist/assets/settings-nav-DbICcozy.js.br +0 -0
- package/app/dist/assets/settings-nav-DbICcozy.js.gz +0 -0
- package/app/dist/assets/settings-sections-Cq0VX9E8.js.br +0 -0
- package/app/dist/assets/settings-sections-Cq0VX9E8.js.gz +0 -0
- package/app/dist/assets/sidebarTouchSensor-D7jKXrfM.js.br +0 -0
- package/app/dist/assets/sidebarTouchSensor-D7jKXrfM.js.gz +0 -0
- package/app/dist/assets/switch-CzvlSesf.js.br +0 -0
- package/app/dist/assets/switch-CzvlSesf.js.gz +0 -0
- package/app/dist/assets/thread-event-parser-BqVpKC6z.js.br +0 -0
- package/app/dist/assets/thread-event-parser-BqVpKC6z.js.gz +0 -0
- package/app/dist/assets/thread-panel-queries-C3MI4mdc.js.br +0 -0
- package/app/dist/assets/thread-panel-queries-C3MI4mdc.js.gz +0 -0
- package/app/dist/assets/thread-runtime-mutations-Cr1H7KSz.js.br +0 -0
- package/app/dist/assets/thread-runtime-mutations-Cr1H7KSz.js.gz +0 -0
- package/app/dist/assets/thread-terminal-queries-B4JkOWS2.js.br +0 -0
- package/app/dist/assets/thread-terminal-queries-B4JkOWS2.js.gz +0 -0
- package/app/dist/assets/threadRecentItems-DI2mgj7S.js.br +0 -0
- package/app/dist/assets/threadRecentItems-DI2mgj7S.js.gz +0 -0
- package/app/dist/assets/threadWorkspaceOpenPath-BQgtUYL5.js.br +0 -0
- package/app/dist/assets/threadWorkspaceOpenPath-BQgtUYL5.js.gz +0 -0
- package/app/dist/assets/title-bar-scroll-fade-CxbgbTcm.js.br +0 -0
- package/app/dist/assets/title-bar-scroll-fade-CxbgbTcm.js.gz +0 -0
- package/app/dist/assets/use-hover-popover-CyIdak3c.js.br +0 -0
- package/app/dist/assets/use-hover-popover-CyIdak3c.js.gz +0 -0
- package/app/dist/assets/useElementWidth-CL3Nb-eq.js.br +0 -0
- package/app/dist/assets/useElementWidth-CL3Nb-eq.js.gz +0 -0
- package/app/dist/assets/useLocalOpenTargets-yzd9-Ceh.js.br +0 -0
- package/app/dist/assets/useLocalOpenTargets-yzd9-Ceh.js.gz +0 -0
- package/app/dist/assets/usePanelResizeSnap-dys9IwEk.js.br +0 -0
- package/app/dist/assets/usePanelResizeSnap-dys9IwEk.js.gz +0 -0
- package/app/dist/assets/usePanelTerminals-BN8UCJFO.js.br +0 -0
- package/app/dist/assets/usePanelTerminals-BN8UCJFO.js.gz +0 -0
- package/app/dist/assets/usePathSuggestions-DkeFAE7l.js.br +0 -0
- package/app/dist/assets/usePathSuggestions-DkeFAE7l.js.gz +0 -0
- package/app/dist/assets/useResolvedLiveFileTarget-43fAKgDx.js.br +0 -0
- package/app/dist/assets/useResolvedLiveFileTarget-43fAKgDx.js.gz +0 -0
- package/app/dist/assets/useThreadTerminalController-DcWLbe8W.js.br +0 -0
- package/app/dist/assets/useThreadTerminalController-DcWLbe8W.js.gz +0 -0
- package/app/dist/assets/workspace-change-summary-Bd3p-LXz.js.br +0 -0
- package/app/dist/assets/workspace-change-summary-Bd3p-LXz.js.gz +0 -0
- package/app/dist/assets/workspace-checkout-display-DMp28yCr.js.br +0 -0
- package/app/dist/assets/workspace-checkout-display-DMp28yCr.js.gz +0 -0
- package/host-daemon/dist/bb-chunks/chunk-CLMP7PJ2.js +0 -2
- package/host-daemon/dist/bb-chunks/chunk-SDZLOCRA.js +0 -2186
- package/host-daemon/dist/bb-chunks/project-J3U36Y4U.js +0 -2
- package/host-daemon/dist/bb-chunks/thread-event-parser-VC3WTCLZ.js +0 -2
|
@@ -1 +1 @@
|
|
|
1
|
-
import{o as e}from"./rolldown-runtime-BM3Ffeng.js";import{Or as t,mi as n,ni as r}from"./boot-vendor-BBLG7GwQ.js";import{On as i,Qm as a,Yt as o,nh as s,oh as c,uc as l}from"./index-BBxUiLNy.js";import{t as u}from"./code-loading-skeletons-C_099GEq.js";import{f as d,l as f,o as p,u as m}from"./git-diff-patch-text-Cs-divFw.js";import{t as h}from"./truncate-start-CaCnKnh9.js";import{n as g,r as _,t as v}from"./image-lightbox-BW1bqQJM.js";import{a as y}from"./absolute-file-path-W_eh4kPq.js";import{n as b}from"./diff-stats-tally-MtORWItG.js";import{t as x}from"./open-in-editor-button-CQGreiCk.js";import{n as S,t as C}from"./file-path-link-Cni9Azi2.js";import{t as w}from"./DiffHost-3UTZIJNs.js";var T=t(),E=e(n(),1),D=e(r(),1),O={contain:`layout paint style`,contentVisibility:`auto`,containIntrinsicSize:`0 600px`};function k(e){return e===`modified`||e===`renamed`||e===`copied`}function ee(e){if(typeof window.requestIdleCallback==`function`){let t=window.requestIdleCallback(e,{timeout:2e3});return()=>window.cancelIdleCallback(t)}let t=window.setTimeout(e,200);return()=>window.clearTimeout(t)}function A(e,t,n){let r=d(e.name)??e.name,i=d(e.prevName)??r,a=t===`added`?{kind:`empty`,path:r}:{kind:`request`,path:t===`renamed`?i:r,side:`old`},o=t===`deleted`?{kind:`empty`,path:r}:{kind:`request`,path:r,side:`new`},s=e.hunks.map(e=>`${e.hunkSpecs??``}:${e.additionStart}:${e.additionCount}:${e.deletionStart}:${e.deletionCount}`).join(`|`);return{identity:[t,j(a),j(o),s,n??``,e.deletionLines.join(``),e.additionLines.join(``)].join(`:`),old:a,new:o}}function j(e){return e.kind===`empty`?`empty:${e.path}`:`request:${e.side}:${e.path}`}function te(e,t){return e.kind===`empty`?Promise.resolve({kind:`text`,file:{name:e.path,contents:``}}):t(e.path,e.side)}function M(e,t){return{old:{path:e.name,content:e.contents},new:{path:t.name,content:t.contents}}}function N(e,t){return e.hunks.length===0&&e.type!==`rename-pure`&&t!==void 0&&f(e.name)}function P(e,t){return e.type!==`rename-pure`&&t!==void 0&&m(e)}function F(e){let t=e.trim();return t.length===0?null:`data:image/svg+xml;charset=utf-8,${encodeURIComponent(t)}`}function I(e){let t=(0,T.c)(75),{fileDiff:n,changeKind:r,onRequestFileContents:i,patchText:a,renderBeforeVisible:o}=e,s=r===`deleted`,c;t[0]!==n||t[1]!==i?(c=N(n,i),t[0]=n,t[1]=i,t[2]=c):c=t[2];let u=c,d;t[3]!==n||t[4]!==i?(d=P(n,i),t[3]=n,t[4]=i,t[5]=d):d=t[5];let f=d,m;t[6]===n?m=t[7]:(m=p(n),t[6]=n,t[7]=m);let h=m,g;t[8]!==r||t[9]!==n||t[10]!==a?(g=A(n,r,a),t[8]=r,t[9]=n,t[10]=a,t[11]=g):g=t[11];let _=g,v;t[12]===Symbol.for(`react.memo_cache_sentinel`)?(v={initialIsIntersecting:!1,rootMargin:`200px`},t[12]=v):v=t[12];let{ref:y,isIntersecting:b}=S(v),x=(0,E.useRef)(i),C;t[13]===i?C=t[14]:(C=()=>{x.current=i},t[13]=i,t[14]=C),(0,E.useEffect)(C);let w;t[15]===Symbol.for(`react.memo_cache_sentinel`)?(w={status:`idle`},t[15]=w):w=t[15];let[D,O]=(0,E.useState)(w),j=(0,E.useRef)(`idle`),[I,z]=(0,E.useState)(o),[B,V]=(0,E.useState)(!1),[U,W]=(0,E.useState)(0),[G,re]=(0,E.useState)(!1),K=l(),q;t[16]===Symbol.for(`react.memo_cache_sentinel`)?(q=()=>{j.current=`idle`,O({status:`idle`}),V(!1),W(0),re(!1)},t[16]=q):q=t[16];let J;t[17]!==_.identity||t[18]!==u||t[19]!==f?(J=[_.identity,u,f],t[17]=_.identity,t[18]=u,t[19]=f,t[20]=J):J=t[20],(0,E.useEffect)(q,J);let Y,X;t[21]===b?(Y=t[22],X=t[23]):(Y=()=>{b&&z(!0)},X=[b],t[21]=b,t[22]=Y,t[23]=X),(0,E.useEffect)(Y,X);let ie=s&&!u&&!f&&!B,Z=I&&!ie,ae=u||f,oe;t[24]!==r||t[25]!==n||t[26]!==ae||t[27]!==i||t[28]!==a?(oe=!ae&&i!==void 0&&a!==void 0&&n.hunks.length>0&&k(r),t[24]=r,t[25]=n,t[26]=ae,t[27]=i,t[28]=a,t[29]=oe):oe=t[29];let Q=oe,$=Z&&(ae||Q&&U>0),se,ce;t[30]!==Q||t[31]!==U||t[32]!==K||t[33]!==Z?(se=()=>{if(!(K||!Z||!Q||U>0))return ee(()=>{W(L)})},ce=[Q,U,K,Z],t[30]=Q,t[31]=U,t[32]=K,t[33]=Z,t[34]=se,t[35]=ce):(se=t[34],ce=t[35]),(0,E.useEffect)(se,ce);let le;t[36]!==_.new||t[37]!==_.old||t[38]!==f||t[39]!==$?(le=()=>{if(!$||j.current!==`idle`)return;let e=x.current;if(!e)return;let t=!1;return j.current=`loading`,O({status:`loading`}),Promise.all([te(_.old,e),te(_.new,e)]).then(e=>{let[n,r]=e;if(t)return;let i=n?.kind===`image`?n:null,a=r?.kind===`image`?r:null;if(i!==null||a!==null){j.current=`ready-image`,O({status:`ready-image`,oldImageUrl:i?.dataUrl??null,newImageUrl:a?.dataUrl??null,oldSizeBytes:i?.sizeBytes??null,newSizeBytes:a?.sizeBytes??null});return}if(n?.kind!==`text`||r?.kind!==`text`){j.current=`unavailable`,O({status:`unavailable`});return}let o=M(n.file,r.file);if(f){j.current=`ready-svg`,O({status:`ready-svg`,fullFileContents:o,oldImageUrl:F(n.file.contents),newImageUrl:F(r.file.contents)});return}j.current=`ready`,O({status:`ready`,fullFileContents:o})}).catch(()=>{t||(j.current=`error`,O({status:`error`}))}),()=>{t=!0,j.current===`loading`&&(j.current=`idle`)}},t[36]=_.new,t[37]=_.old,t[38]=f,t[39]=$,t[40]=le):le=t[40];let ue;t[41]!==U||t[42]!==_||t[43]!==n||t[44]!==f||t[45]!==a||t[46]!==$?(ue=[U,_,n,f,a,$],t[41]=U,t[42]=_,t[43]=n,t[44]=f,t[45]=a,t[46]=$,t[47]=ue):ue=t[47],(0,E.useEffect)(le,ue);let de;t[48]===Symbol.for(`react.memo_cache_sentinel`)?(de=()=>{j.current===`error`&&(j.current=`idle`,O({status:`idle`})),re(!0),W(ne)},t[48]=de):de=t[48];let fe=de,pe=U>0,me=!K,he;t[49]!==Q||t[50]!==D.status||t[51]!==G||t[52]!==pe||t[53]!==me?(he=R({canExpandContext:Q,contextRequested:pe,enrichmentStatus:D.status,isPrefetchedAutomatically:me,isRequestedByUser:G}),t[49]=Q,t[50]=D.status,t[51]=G,t[52]=pe,t[53]=me,t[54]=he):he=t[54];let ge=he,_e;t[55]===ge?_e=t[56]:(_e={status:ge,request:fe},t[55]=ge,t[56]=_e);let ve=_e,ye=D.status===`ready`||D.status===`ready-svg`?D.fullFileContents:null,be;t[57]===Symbol.for(`react.memo_cache_sentinel`)?(be=()=>{V(!0),z(!0)},t[57]=be):be=t[57];let xe=be,Se;t[58]!==r||t[59]!==D||t[60]!==u?(Se=u&&D.status===`ready-image`?H(D,r):null,t[58]=r,t[59]=D,t[60]=u,t[61]=Se):Se=t[61];let Ce=Se,we;return t[62]!==y||t[63]!==ve||t[64]!==D||t[65]!==n||t[66]!==h||t[67]!==ye||t[68]!==Ce||t[69]!==u||t[70]!==f||t[71]!==a||t[72]!==ie||t[73]!==Z?(we={bodySentinelRef:y,enrichment:D,fileDiff:n,fileDiffLabel:h,isImageCard:u,isSvgPreviewCard:f,shouldGateDeletedDiff:ie,shouldRenderDiffView:Z,loadDeletedDiff:xe,imageSizeStat:Ce,contextExpansion:ve,fullFileContents:ye,patchText:a},t[62]=y,t[63]=ve,t[64]=D,t[65]=n,t[66]=h,t[67]=ye,t[68]=Ce,t[69]=u,t[70]=f,t[71]=a,t[72]=ie,t[73]=Z,t[74]=we):we=t[74],we}function ne(e){return e+1}function L(e){return e===0?1:e}function R({canExpandContext:e,contextRequested:t,enrichmentStatus:n,isPrefetchedAutomatically:r,isRequestedByUser:i}){if(!e)return`unavailable`;let a=i?`loading`:`prefetching`;switch(n){case`idle`:return t?a:r?`prefetching`:`idle`;case`loading`:return a;case`ready`:return`ready`;case`error`:return`error`;case`ready-image`:case`ready-svg`:case`unavailable`:return`unavailable`;default:return n}}function z(e,t){let n=e!==null&&t!==null,r=[];return e!==null&&r.push({url:e,caption:n?`Old`:null}),t!==null&&r.push({url:t,caption:n?`New`:null}),r}function B(e,t){return t.caption===null?e:`${e} (${t.caption.toLowerCase()})`}function V(e){return e.status!==`ready-image`&&e.status!==`ready-svg`?null:{oldImageUrl:e.oldImageUrl,newImageUrl:e.newImageUrl}}function H(e,t){let n=t===`deleted`?null:e.newSizeBytes,r=t===`added`?null:e.oldSizeBytes;return n===null&&r===null?null:{addedBytes:n,removedBytes:r}}function U(e){let t=(0,T.c)(32),{preview:n,fileDiffLabel:r,fitToFrame:i}=e,a=i===void 0?!1:i,[o,s]=(0,E.useState)(null),c,l,u,d,f,p,m,h;if(t[0]!==o||t[1]!==r||t[2]!==a||t[3]!==n.newImageUrl||t[4]!==n.oldImageUrl){h=Symbol.for(`react.early_return_sentinel`);bb0:{if(l=z(n.oldImageUrl,n.newImageUrl),l.length===0){let e;t[13]===Symbol.for(`react.memo_cache_sentinel`)?(e=(0,D.jsx)(`div`,{className:`px-3 py-3 text-xs text-muted-foreground`,children:`No preview available for this image.`}),t[13]=e):e=t[13],h=e;break bb0}let e=o===null?void 0:l[o];u=e=>{s(t=>t===null?null:_({currentIndex:t,direction:e,itemCount:l.length}))};let i;t[14]!==r||t[15]!==a?(i=(e,t)=>(0,D.jsxs)(`figure`,{className:`min-w-0 max-w-full`,children:[(0,D.jsx)(`button`,{type:`button`,className:a?`flex h-64 w-full cursor-zoom-in items-center justify-center rounded-md border border-border bg-surface-recessed p-3`:`block max-w-full cursor-zoom-in`,onClick:()=>s(t),children:(0,D.jsx)(`img`,{src:e.url,alt:B(r,e),style:v,className:a?`block h-full w-full object-contain`:`block max-h-80 max-w-full rounded-md border border-border object-contain`})}),e.caption===null?null:(0,D.jsx)(`figcaption`,{className:`mt-1 text-xs text-muted-foreground`,children:e.caption})]},e.url),t[14]=r,t[15]=a,t[16]=i):i=t[16],m=(0,D.jsx)(`div`,{className:`@container/diff-preview min-w-0`,children:(0,D.jsx)(`div`,{className:a?l.length>1?`grid grid-cols-1 gap-3 px-3 py-3 @min-[32rem]/diff-preview:grid-cols-2`:`grid grid-cols-1 gap-3 px-3 py-3`:`flex flex-col items-start gap-3 px-3 py-3 @min-[32rem]/diff-preview:flex-row`,children:l.map(i)})}),c=g,d=`${r} image preview`,f=e?.url??null,p=e?B(r,e):r}t[0]=o,t[1]=r,t[2]=a,t[3]=n.newImageUrl,t[4]=n.oldImageUrl,t[5]=c,t[6]=l,t[7]=u,t[8]=d,t[9]=f,t[10]=p,t[11]=m,t[12]=h}else c=t[5],l=t[6],u=t[7],d=t[8],f=t[9],p=t[10],m=t[11],h=t[12];if(h!==Symbol.for(`react.early_return_sentinel`))return h;let y=l.length>1,b,x;t[17]===u?(b=t[18],x=t[19]):(b=()=>u(`previous`),x=()=>u(`next`),t[17]=u,t[18]=b,t[19]=x);let S;t[20]===Symbol.for(`react.memo_cache_sentinel`)?(S=()=>s(null),t[20]=S):S=t[20];let C;t[21]!==c||t[22]!==d||t[23]!==f||t[24]!==p||t[25]!==y||t[26]!==b||t[27]!==x?(C=(0,D.jsx)(c,{title:d,imageSrc:f,imageAlt:p,hasMultipleImages:y,onPrevious:b,onNext:x,onClose:S}),t[21]=c,t[22]=d,t[23]=f,t[24]=p,t[25]=y,t[26]=b,t[27]=x,t[28]=C):C=t[28];let w;return t[29]!==C||t[30]!==m?(w=(0,D.jsxs)(D.Fragment,{children:[m,C]}),t[29]=C,t[30]=m,t[31]=w):w=t[31],w}function W(e){let t=(0,T.c)(8),{enrichment:n,fileDiffLabel:r,fitToFrame:i}=e,a=i===void 0?!1:i;if(n.status===`idle`||n.status===`loading`){let e;return t[0]===Symbol.for(`react.memo_cache_sentinel`)?(e=(0,D.jsx)(u,{}),t[0]=e):e=t[0],e}let o;t[1]===n?o=t[2]:(o=V(n),t[1]=n,t[2]=o);let s=o;if(s===null){let e;return t[3]===Symbol.for(`react.memo_cache_sentinel`)?(e=(0,D.jsx)(`div`,{className:`px-3 py-3 text-xs text-muted-foreground`,children:`No preview available for this image.`}),t[3]=e):e=t[3],e}let c;return t[4]!==r||t[5]!==a||t[6]!==s?(c=(0,D.jsx)(U,{preview:s,fileDiffLabel:r,fitToFrame:a}),t[4]=r,t[5]=a,t[6]=s,t[7]=c):c=t[7],c}function G(e){let t=(0,T.c)(9),{displayMode:n,enrichment:r,fileDiff:i,fileDiffLabel:a,patchText:o,fullFileContents:s,presentation:c,onSelectionAddToChat:l}=e,u;return t[0]!==n||t[1]!==r||t[2]!==i||t[3]!==a||t[4]!==s||t[5]!==l||t[6]!==o||t[7]!==c?(u=n===`preview`?(0,D.jsx)(W,{enrichment:r,fileDiffLabel:a,fitToFrame:!0}):(0,D.jsx)(w,{file:i,patchText:o,fullFileContents:s,...c,onSelectionAddToChat:l}),t[0]=n,t[1]=r,t[2]=i,t[3]=a,t[4]=s,t[5]=l,t[6]=o,t[7]=c,t[8]=u):u=t[8],u}function re(e){let t=(0,T.c)(19),{state:n,presentation:r,svgDisplayMode:i,reservesCollapseGutter:a,onSelectionAddToChat:o}=e,{bodySentinelRef:c,enrichment:l,fileDiff:d,fileDiffLabel:f,isImageCard:p,isSvgPreviewCard:m,shouldGateDeletedDiff:h,shouldRenderDiffView:g,loadDeletedDiff:_,contextExpansion:v,fullFileContents:y,patchText:b}=n,x;t[0]!==v||t[1]!==l||t[2]!==d||t[3]!==f||t[4]!==y||t[5]!==p||t[6]!==m||t[7]!==_||t[8]!==o||t[9]!==b||t[10]!==r||t[11]!==a||t[12]!==h||t[13]!==g||t[14]!==i?(x=h?(0,D.jsxs)(`div`,{className:`flex items-center py-3 pl-2 pr-3 text-xs text-muted-foreground`,children:[a?(0,D.jsx)(`span`,{"aria-hidden":!0,className:`w-8 shrink-0`}):null,(0,D.jsxs)(`span`,{className:`pl-[1ch]`,children:[(0,D.jsx)(`span`,{children:`This file was deleted.`}),` `,(0,D.jsx)(s,{type:`button`,variant:`link`,size:`sm`,className:`h-auto p-0 text-xs underline underline-offset-4 hover:underline`,onClick:_,children:`Load diff`})]})]}):g?p?(0,D.jsx)(W,{enrichment:l,fileDiffLabel:f}):m?(0,D.jsx)(G,{displayMode:i,enrichment:l,fileDiff:d,fileDiffLabel:f,patchText:b,fullFileContents:y,presentation:r,onSelectionAddToChat:o}):(0,D.jsxs)(D.Fragment,{children:[(0,D.jsx)(w,{file:d,patchText:b,fullFileContents:y,...r,onSelectionAddToChat:o}),(0,D.jsx)(K,{contextExpansion:v,reservesCollapseGutter:a})]}):(0,D.jsx)(u,{}),t[0]=v,t[1]=l,t[2]=d,t[3]=f,t[4]=y,t[5]=p,t[6]=m,t[7]=_,t[8]=o,t[9]=b,t[10]=r,t[11]=a,t[12]=h,t[13]=g,t[14]=i,t[15]=x):x=t[15];let S;return t[16]!==c||t[17]!==x?(S=(0,D.jsx)(`div`,{ref:c,className:`overflow-hidden rounded-b-lg bg-background`,style:O,children:x}),t[16]=c,t[17]=x,t[18]=S):S=t[18],S}function K(e){let t=(0,T.c)(8),{contextExpansion:n,reservesCollapseGutter:r}=e,{status:i,request:a}=n;if(i===`unavailable`||i===`ready`||i===`prefetching`)return null;let o;t[0]===r?o=t[1]:(o=r?(0,D.jsx)(`span`,{"aria-hidden":!0,className:`w-8 shrink-0`}):null,t[0]=r,t[1]=o);let c;t[2]!==a||t[3]!==i?(c=(0,D.jsx)(`span`,{className:`pl-[1ch]`,children:i===`loading`?(0,D.jsx)(`span`,{role:`status`,children:`Loading context…`}):(0,D.jsxs)(D.Fragment,{children:[i===`error`?(0,D.jsxs)(D.Fragment,{children:[(0,D.jsx)(`span`,{className:`text-destructive`,children:`Couldn't load surrounding context.`}),` `]}):null,(0,D.jsx)(s,{type:`button`,variant:`link`,size:`sm`,className:`h-auto p-0 text-xs underline underline-offset-4 hover:underline`,onClick:a,children:i===`error`?`Retry`:`Expand context`})]})}),t[2]=a,t[3]=i,t[4]=c):c=t[4];let l;return t[5]!==o||t[6]!==c?(l=(0,D.jsxs)(`div`,{className:`flex items-center py-2 pl-2 pr-3 text-xs text-muted-foreground`,children:[o,c]}),t[5]=o,t[6]=c,t[7]=l):l=t[7],l}function q(e){let t=(0,T.c)(7),{stat:n}=e,r;t[0]===n.addedBytes?r=t[1]:(r=n.addedBytes===null?null:(0,D.jsx)(`span`,{className:`text-diff-added`,children:`+${i(n.addedBytes)}`}),t[0]=n.addedBytes,t[1]=r);let a;t[2]===n.removedBytes?a=t[3]:(a=n.removedBytes===null?null:(0,D.jsx)(`span`,{className:`text-diff-removed`,children:`-${i(n.removedBytes)}`}),t[2]=n.removedBytes,t[3]=a);let o;return t[4]!==r||t[5]!==a?(o=(0,D.jsxs)(`span`,{className:`flex shrink-0 items-center gap-1 whitespace-nowrap text-xs tabular-nums`,children:[r,a]}),t[4]=r,t[5]=a,t[6]=o):o=t[6],o}function J(e){let t=(0,T.c)(5),{fileLabel:n,isRaw:r,onToggle:i}=e,o=r?`Show image preview for ${n}`:`Show raw SVG diff for ${n}`,s;t[0]===Symbol.for(`react.memo_cache_sentinel`)?(s=(0,D.jsx)(a,{name:`Code`,"aria-hidden":!0,className:`size-3.5`}),t[0]=s):s=t[0];let c;return t[1]!==r||t[2]!==o||t[3]!==i?(c=(0,D.jsx)(`button`,{type:`button`,className:`inline-flex size-5 shrink-0 cursor-pointer items-center justify-center rounded-md text-muted-foreground hover:bg-state-hover hover:text-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring aria-pressed:bg-state-active aria-pressed:text-foreground`,onClick:i,"aria-label":o,"aria-pressed":r,children:s}),t[1]=r,t[2]=o,t[3]=i,t[4]=c):c=t[4],c}function Y(e,t){return e.changeKind!==`renamed`&&e.changeKind!==`copied`?null:t&&t!==e.path?{from:t,to:e.path}:null}function X(e){let t=(0,T.c)(53),{model:n,previousPath:r,filePathRoot:i,onOpenFileInEditor:s,onOpenFilePreview:l,isCollapsed:u,onToggleCollapsed:d,hasChanges:f,statSlot:p,actionSlot:m}=e,g=n.changeKind===`added`,_=n.changeKind===`deleted`,v=_?0:n.insertions,S=g?0:n.deletions,w=g||_,E;t[0]!==n||t[1]!==r?(E=Y(n,r),t[0]=n,t[1]=r,t[2]=E):E=t[2];let O=E,k=n.openablePath,ee;t[3]!==i||t[4]!==k?(ee=k?y({path:k,rootPath:i}):null,t[3]=i,t[4]=k,t[5]=ee):ee=t[5];let A=ee,j=!!k,te=u!==void 0&&d!==void 0,M;t[6]!==f||t[7]!==u||t[8]!==n.label||t[9]!==d||t[10]!==te?(M=te?(0,D.jsx)(`button`,{type:`button`,className:c(`inline-flex w-8 shrink-0 items-center justify-center text-muted-foreground transition-colors`,f?`hover:text-foreground`:`cursor-not-allowed opacity-40`),onClick:f?d:void 0,disabled:!f,"aria-label":f?`${u?`Expand`:`Collapse`} ${n.label}`:`${n.label} has no changes to expand`,"aria-expanded":f?!u:void 0,children:(0,D.jsx)(a,{name:`ChevronRight`,className:c(`size-3.5 shrink-0 transition-transform duration-150`,f&&!u&&`rotate-90`)})}):null,t[6]=f,t[7]=u,t[8]=n.label,t[9]=d,t[10]=te,t[11]=M):M=t[11];let N;t[12]===Symbol.for(`react.memo_cache_sentinel`)?(N=c(`flex min-w-0 items-center gap-1.5`,`pl-[1ch]`),t[12]=N):N=t[12];let P;t[13]===O?P=t[14]:(P=O?(0,D.jsx)(h,{className:`min-w-0 font-mono text-xs leading-5 text-muted-foreground`,title:O.from,children:O.from}):null,t[13]=O,t[14]=P);let F;t[15]===O?F=t[16]:(F=O?(0,D.jsx)(a,{name:`ArrowRight`,"aria-hidden":`true`,className:`size-3 shrink-0 text-subtle-foreground`}):null,t[15]=O,t[16]=F);let I=k??n.path,ne=O?O.to:n.label,L;t[17]!==j||t[18]!==l||t[19]!==k?(L=j&&k&&l?()=>l(k):void 0,t[17]=j,t[18]=l,t[19]=k,t[20]=L):L=t[20];let R;t[21]!==I||t[22]!==ne||t[23]!==L?(R=(0,D.jsx)(C,{path:I,displayName:ne,onClick:L,className:`font-mono font-medium text-foreground`}),t[21]=I,t[22]=ne,t[23]=L,t[24]=R):R=t[24];let z;t[25]!==A||t[26]!==n.label?(z=A?(0,D.jsx)(o,{text:A,label:`Copy path for ${n.label}`,className:`rounded-md hover:bg-state-hover`}):null,t[25]=A,t[26]=n.label,t[27]=z):z=t[27];let B;t[28]!==j||t[29]!==n.label||t[30]!==s||t[31]!==k?(B=j&&k&&s?(0,D.jsx)(x,{onClick:()=>s(k),label:`Open ${n.label} in editor`}):null,t[28]=j,t[29]=n.label,t[30]=s,t[31]=k,t[32]=B):B=t[32];let V;t[33]!==R||t[34]!==z||t[35]!==B||t[36]!==P||t[37]!==F?(V=(0,D.jsxs)(`span`,{className:N,children:[P,F,R,z,B]}),t[33]=R,t[34]=z,t[35]=B,t[36]=P,t[37]=F,t[38]=V):V=t[38];let H;t[39]!==V||t[40]!==M?(H=(0,D.jsxs)(`span`,{className:`flex min-w-0 grow basis-48 items-center`,children:[M,V]}),t[39]=V,t[40]=M,t[41]=H):H=t[41];let U;t[42]!==S||t[43]!==v||t[44]!==w||t[45]!==p?(U=p??(0,D.jsx)(b,{insertions:v,deletions:S,hideZero:w,className:`text-xs`}),t[42]=S,t[43]=v,t[44]=w,t[45]=p,t[46]=U):U=t[46];let W;t[47]!==m||t[48]!==U?(W=(0,D.jsxs)(`span`,{className:`ml-auto flex shrink-0 items-center gap-2`,children:[U,m]}),t[47]=m,t[48]=U,t[49]=W):W=t[49];let G;return t[50]!==H||t[51]!==W?(G=(0,D.jsxs)(`div`,{className:`flex w-full min-w-0 flex-wrap items-center justify-between gap-x-2 gap-y-1`,children:[H,W]}),t[50]=H,t[51]=W,t[52]=G):G=t[52],G}var ie=`rounded-lg bg-background py-1.5 pl-2 pr-3 text-xs font-medium text-foreground`;function Z({stickyHeader:e,isBodyHidden:t,isStuck:n,showStuckHeaderEdge:r=!0}){return c(ie,e&&`sticky z-30`,e&&`top-0`,!t&&`rounded-b-none`,n&&`rounded-t-none`,n&&r&&`shadow-[inset_0_1px_0_var(--border)]`)}export{re as a,I as c,Z as i,q as n,U as o,J as r,H as s,X as t};
|
|
1
|
+
import{o as e}from"./rolldown-runtime-BM3Ffeng.js";import{Or as t,mi as n,ni as r}from"./boot-vendor-BBLG7GwQ.js";import{On as i,Qm as a,Yt as o,nh as s,oh as c,uc as l}from"./index-B-RDC4LU.js";import{t as u}from"./code-loading-skeletons-DzoCzgll.js";import{f as d,l as f,o as p,u as m}from"./git-diff-patch-text-Cs-divFw.js";import{t as h}from"./truncate-start-D-P3rLti.js";import{n as g,r as _,t as v}from"./image-lightbox-CzY6y14n.js";import{a as y}from"./absolute-file-path-B-cUOroV.js";import{n as b}from"./diff-stats-tally-DA41wrwM.js";import{t as x}from"./open-in-editor-button-jScMiuob.js";import{n as S,t as C}from"./file-path-link-xsn9GiAq.js";import{t as w}from"./DiffHost-DEYVmsVa.js";var T=t(),E=e(n(),1),D=e(r(),1),O={contain:`layout paint style`,contentVisibility:`auto`,containIntrinsicSize:`0 600px`};function k(e){return e===`modified`||e===`renamed`||e===`copied`}function ee(e){if(typeof window.requestIdleCallback==`function`){let t=window.requestIdleCallback(e,{timeout:2e3});return()=>window.cancelIdleCallback(t)}let t=window.setTimeout(e,200);return()=>window.clearTimeout(t)}function A(e,t,n){let r=d(e.name)??e.name,i=d(e.prevName)??r,a=t===`added`?{kind:`empty`,path:r}:{kind:`request`,path:t===`renamed`?i:r,side:`old`},o=t===`deleted`?{kind:`empty`,path:r}:{kind:`request`,path:r,side:`new`},s=e.hunks.map(e=>`${e.hunkSpecs??``}:${e.additionStart}:${e.additionCount}:${e.deletionStart}:${e.deletionCount}`).join(`|`);return{identity:[t,j(a),j(o),s,n??``,e.deletionLines.join(``),e.additionLines.join(``)].join(`:`),old:a,new:o}}function j(e){return e.kind===`empty`?`empty:${e.path}`:`request:${e.side}:${e.path}`}function te(e,t){return e.kind===`empty`?Promise.resolve({kind:`text`,file:{name:e.path,contents:``}}):t(e.path,e.side)}function M(e,t){return{old:{path:e.name,content:e.contents},new:{path:t.name,content:t.contents}}}function N(e,t){return e.hunks.length===0&&e.type!==`rename-pure`&&t!==void 0&&f(e.name)}function P(e,t){return e.type!==`rename-pure`&&t!==void 0&&m(e)}function F(e){let t=e.trim();return t.length===0?null:`data:image/svg+xml;charset=utf-8,${encodeURIComponent(t)}`}function I(e){let t=(0,T.c)(75),{fileDiff:n,changeKind:r,onRequestFileContents:i,patchText:a,renderBeforeVisible:o}=e,s=r===`deleted`,c;t[0]!==n||t[1]!==i?(c=N(n,i),t[0]=n,t[1]=i,t[2]=c):c=t[2];let u=c,d;t[3]!==n||t[4]!==i?(d=P(n,i),t[3]=n,t[4]=i,t[5]=d):d=t[5];let f=d,m;t[6]===n?m=t[7]:(m=p(n),t[6]=n,t[7]=m);let h=m,g;t[8]!==r||t[9]!==n||t[10]!==a?(g=A(n,r,a),t[8]=r,t[9]=n,t[10]=a,t[11]=g):g=t[11];let _=g,v;t[12]===Symbol.for(`react.memo_cache_sentinel`)?(v={initialIsIntersecting:!1,rootMargin:`200px`},t[12]=v):v=t[12];let{ref:y,isIntersecting:b}=S(v),x=(0,E.useRef)(i),C;t[13]===i?C=t[14]:(C=()=>{x.current=i},t[13]=i,t[14]=C),(0,E.useEffect)(C);let w;t[15]===Symbol.for(`react.memo_cache_sentinel`)?(w={status:`idle`},t[15]=w):w=t[15];let[D,O]=(0,E.useState)(w),j=(0,E.useRef)(`idle`),[I,z]=(0,E.useState)(o),[B,V]=(0,E.useState)(!1),[U,W]=(0,E.useState)(0),[G,re]=(0,E.useState)(!1),K=l(),q;t[16]===Symbol.for(`react.memo_cache_sentinel`)?(q=()=>{j.current=`idle`,O({status:`idle`}),V(!1),W(0),re(!1)},t[16]=q):q=t[16];let J;t[17]!==_.identity||t[18]!==u||t[19]!==f?(J=[_.identity,u,f],t[17]=_.identity,t[18]=u,t[19]=f,t[20]=J):J=t[20],(0,E.useEffect)(q,J);let Y,X;t[21]===b?(Y=t[22],X=t[23]):(Y=()=>{b&&z(!0)},X=[b],t[21]=b,t[22]=Y,t[23]=X),(0,E.useEffect)(Y,X);let ie=s&&!u&&!f&&!B,Z=I&&!ie,ae=u||f,oe;t[24]!==r||t[25]!==n||t[26]!==ae||t[27]!==i||t[28]!==a?(oe=!ae&&i!==void 0&&a!==void 0&&n.hunks.length>0&&k(r),t[24]=r,t[25]=n,t[26]=ae,t[27]=i,t[28]=a,t[29]=oe):oe=t[29];let Q=oe,$=Z&&(ae||Q&&U>0),se,ce;t[30]!==Q||t[31]!==U||t[32]!==K||t[33]!==Z?(se=()=>{if(!(K||!Z||!Q||U>0))return ee(()=>{W(L)})},ce=[Q,U,K,Z],t[30]=Q,t[31]=U,t[32]=K,t[33]=Z,t[34]=se,t[35]=ce):(se=t[34],ce=t[35]),(0,E.useEffect)(se,ce);let le;t[36]!==_.new||t[37]!==_.old||t[38]!==f||t[39]!==$?(le=()=>{if(!$||j.current!==`idle`)return;let e=x.current;if(!e)return;let t=!1;return j.current=`loading`,O({status:`loading`}),Promise.all([te(_.old,e),te(_.new,e)]).then(e=>{let[n,r]=e;if(t)return;let i=n?.kind===`image`?n:null,a=r?.kind===`image`?r:null;if(i!==null||a!==null){j.current=`ready-image`,O({status:`ready-image`,oldImageUrl:i?.dataUrl??null,newImageUrl:a?.dataUrl??null,oldSizeBytes:i?.sizeBytes??null,newSizeBytes:a?.sizeBytes??null});return}if(n?.kind!==`text`||r?.kind!==`text`){j.current=`unavailable`,O({status:`unavailable`});return}let o=M(n.file,r.file);if(f){j.current=`ready-svg`,O({status:`ready-svg`,fullFileContents:o,oldImageUrl:F(n.file.contents),newImageUrl:F(r.file.contents)});return}j.current=`ready`,O({status:`ready`,fullFileContents:o})}).catch(()=>{t||(j.current=`error`,O({status:`error`}))}),()=>{t=!0,j.current===`loading`&&(j.current=`idle`)}},t[36]=_.new,t[37]=_.old,t[38]=f,t[39]=$,t[40]=le):le=t[40];let ue;t[41]!==U||t[42]!==_||t[43]!==n||t[44]!==f||t[45]!==a||t[46]!==$?(ue=[U,_,n,f,a,$],t[41]=U,t[42]=_,t[43]=n,t[44]=f,t[45]=a,t[46]=$,t[47]=ue):ue=t[47],(0,E.useEffect)(le,ue);let de;t[48]===Symbol.for(`react.memo_cache_sentinel`)?(de=()=>{j.current===`error`&&(j.current=`idle`,O({status:`idle`})),re(!0),W(ne)},t[48]=de):de=t[48];let fe=de,pe=U>0,me=!K,he;t[49]!==Q||t[50]!==D.status||t[51]!==G||t[52]!==pe||t[53]!==me?(he=R({canExpandContext:Q,contextRequested:pe,enrichmentStatus:D.status,isPrefetchedAutomatically:me,isRequestedByUser:G}),t[49]=Q,t[50]=D.status,t[51]=G,t[52]=pe,t[53]=me,t[54]=he):he=t[54];let ge=he,_e;t[55]===ge?_e=t[56]:(_e={status:ge,request:fe},t[55]=ge,t[56]=_e);let ve=_e,ye=D.status===`ready`||D.status===`ready-svg`?D.fullFileContents:null,be;t[57]===Symbol.for(`react.memo_cache_sentinel`)?(be=()=>{V(!0),z(!0)},t[57]=be):be=t[57];let xe=be,Se;t[58]!==r||t[59]!==D||t[60]!==u?(Se=u&&D.status===`ready-image`?H(D,r):null,t[58]=r,t[59]=D,t[60]=u,t[61]=Se):Se=t[61];let Ce=Se,we;return t[62]!==y||t[63]!==ve||t[64]!==D||t[65]!==n||t[66]!==h||t[67]!==ye||t[68]!==Ce||t[69]!==u||t[70]!==f||t[71]!==a||t[72]!==ie||t[73]!==Z?(we={bodySentinelRef:y,enrichment:D,fileDiff:n,fileDiffLabel:h,isImageCard:u,isSvgPreviewCard:f,shouldGateDeletedDiff:ie,shouldRenderDiffView:Z,loadDeletedDiff:xe,imageSizeStat:Ce,contextExpansion:ve,fullFileContents:ye,patchText:a},t[62]=y,t[63]=ve,t[64]=D,t[65]=n,t[66]=h,t[67]=ye,t[68]=Ce,t[69]=u,t[70]=f,t[71]=a,t[72]=ie,t[73]=Z,t[74]=we):we=t[74],we}function ne(e){return e+1}function L(e){return e===0?1:e}function R({canExpandContext:e,contextRequested:t,enrichmentStatus:n,isPrefetchedAutomatically:r,isRequestedByUser:i}){if(!e)return`unavailable`;let a=i?`loading`:`prefetching`;switch(n){case`idle`:return t?a:r?`prefetching`:`idle`;case`loading`:return a;case`ready`:return`ready`;case`error`:return`error`;case`ready-image`:case`ready-svg`:case`unavailable`:return`unavailable`;default:return n}}function z(e,t){let n=e!==null&&t!==null,r=[];return e!==null&&r.push({url:e,caption:n?`Old`:null}),t!==null&&r.push({url:t,caption:n?`New`:null}),r}function B(e,t){return t.caption===null?e:`${e} (${t.caption.toLowerCase()})`}function V(e){return e.status!==`ready-image`&&e.status!==`ready-svg`?null:{oldImageUrl:e.oldImageUrl,newImageUrl:e.newImageUrl}}function H(e,t){let n=t===`deleted`?null:e.newSizeBytes,r=t===`added`?null:e.oldSizeBytes;return n===null&&r===null?null:{addedBytes:n,removedBytes:r}}function U(e){let t=(0,T.c)(32),{preview:n,fileDiffLabel:r,fitToFrame:i}=e,a=i===void 0?!1:i,[o,s]=(0,E.useState)(null),c,l,u,d,f,p,m,h;if(t[0]!==o||t[1]!==r||t[2]!==a||t[3]!==n.newImageUrl||t[4]!==n.oldImageUrl){h=Symbol.for(`react.early_return_sentinel`);bb0:{if(l=z(n.oldImageUrl,n.newImageUrl),l.length===0){let e;t[13]===Symbol.for(`react.memo_cache_sentinel`)?(e=(0,D.jsx)(`div`,{className:`px-3 py-3 text-xs text-muted-foreground`,children:`No preview available for this image.`}),t[13]=e):e=t[13],h=e;break bb0}let e=o===null?void 0:l[o];u=e=>{s(t=>t===null?null:_({currentIndex:t,direction:e,itemCount:l.length}))};let i;t[14]!==r||t[15]!==a?(i=(e,t)=>(0,D.jsxs)(`figure`,{className:`min-w-0 max-w-full`,children:[(0,D.jsx)(`button`,{type:`button`,className:a?`flex h-64 w-full cursor-zoom-in items-center justify-center rounded-md border border-border bg-surface-recessed p-3`:`block max-w-full cursor-zoom-in`,onClick:()=>s(t),children:(0,D.jsx)(`img`,{src:e.url,alt:B(r,e),style:v,className:a?`block h-full w-full object-contain`:`block max-h-80 max-w-full rounded-md border border-border object-contain`})}),e.caption===null?null:(0,D.jsx)(`figcaption`,{className:`mt-1 text-xs text-muted-foreground`,children:e.caption})]},e.url),t[14]=r,t[15]=a,t[16]=i):i=t[16],m=(0,D.jsx)(`div`,{className:`@container/diff-preview min-w-0`,children:(0,D.jsx)(`div`,{className:a?l.length>1?`grid grid-cols-1 gap-3 px-3 py-3 @min-[32rem]/diff-preview:grid-cols-2`:`grid grid-cols-1 gap-3 px-3 py-3`:`flex flex-col items-start gap-3 px-3 py-3 @min-[32rem]/diff-preview:flex-row`,children:l.map(i)})}),c=g,d=`${r} image preview`,f=e?.url??null,p=e?B(r,e):r}t[0]=o,t[1]=r,t[2]=a,t[3]=n.newImageUrl,t[4]=n.oldImageUrl,t[5]=c,t[6]=l,t[7]=u,t[8]=d,t[9]=f,t[10]=p,t[11]=m,t[12]=h}else c=t[5],l=t[6],u=t[7],d=t[8],f=t[9],p=t[10],m=t[11],h=t[12];if(h!==Symbol.for(`react.early_return_sentinel`))return h;let y=l.length>1,b,x;t[17]===u?(b=t[18],x=t[19]):(b=()=>u(`previous`),x=()=>u(`next`),t[17]=u,t[18]=b,t[19]=x);let S;t[20]===Symbol.for(`react.memo_cache_sentinel`)?(S=()=>s(null),t[20]=S):S=t[20];let C;t[21]!==c||t[22]!==d||t[23]!==f||t[24]!==p||t[25]!==y||t[26]!==b||t[27]!==x?(C=(0,D.jsx)(c,{title:d,imageSrc:f,imageAlt:p,hasMultipleImages:y,onPrevious:b,onNext:x,onClose:S}),t[21]=c,t[22]=d,t[23]=f,t[24]=p,t[25]=y,t[26]=b,t[27]=x,t[28]=C):C=t[28];let w;return t[29]!==C||t[30]!==m?(w=(0,D.jsxs)(D.Fragment,{children:[m,C]}),t[29]=C,t[30]=m,t[31]=w):w=t[31],w}function W(e){let t=(0,T.c)(8),{enrichment:n,fileDiffLabel:r,fitToFrame:i}=e,a=i===void 0?!1:i;if(n.status===`idle`||n.status===`loading`){let e;return t[0]===Symbol.for(`react.memo_cache_sentinel`)?(e=(0,D.jsx)(u,{}),t[0]=e):e=t[0],e}let o;t[1]===n?o=t[2]:(o=V(n),t[1]=n,t[2]=o);let s=o;if(s===null){let e;return t[3]===Symbol.for(`react.memo_cache_sentinel`)?(e=(0,D.jsx)(`div`,{className:`px-3 py-3 text-xs text-muted-foreground`,children:`No preview available for this image.`}),t[3]=e):e=t[3],e}let c;return t[4]!==r||t[5]!==a||t[6]!==s?(c=(0,D.jsx)(U,{preview:s,fileDiffLabel:r,fitToFrame:a}),t[4]=r,t[5]=a,t[6]=s,t[7]=c):c=t[7],c}function G(e){let t=(0,T.c)(9),{displayMode:n,enrichment:r,fileDiff:i,fileDiffLabel:a,patchText:o,fullFileContents:s,presentation:c,onSelectionAddToChat:l}=e,u;return t[0]!==n||t[1]!==r||t[2]!==i||t[3]!==a||t[4]!==s||t[5]!==l||t[6]!==o||t[7]!==c?(u=n===`preview`?(0,D.jsx)(W,{enrichment:r,fileDiffLabel:a,fitToFrame:!0}):(0,D.jsx)(w,{file:i,patchText:o,fullFileContents:s,...c,onSelectionAddToChat:l}),t[0]=n,t[1]=r,t[2]=i,t[3]=a,t[4]=s,t[5]=l,t[6]=o,t[7]=c,t[8]=u):u=t[8],u}function re(e){let t=(0,T.c)(19),{state:n,presentation:r,svgDisplayMode:i,reservesCollapseGutter:a,onSelectionAddToChat:o}=e,{bodySentinelRef:c,enrichment:l,fileDiff:d,fileDiffLabel:f,isImageCard:p,isSvgPreviewCard:m,shouldGateDeletedDiff:h,shouldRenderDiffView:g,loadDeletedDiff:_,contextExpansion:v,fullFileContents:y,patchText:b}=n,x;t[0]!==v||t[1]!==l||t[2]!==d||t[3]!==f||t[4]!==y||t[5]!==p||t[6]!==m||t[7]!==_||t[8]!==o||t[9]!==b||t[10]!==r||t[11]!==a||t[12]!==h||t[13]!==g||t[14]!==i?(x=h?(0,D.jsxs)(`div`,{className:`flex items-center py-3 pl-2 pr-3 text-xs text-muted-foreground`,children:[a?(0,D.jsx)(`span`,{"aria-hidden":!0,className:`w-8 shrink-0`}):null,(0,D.jsxs)(`span`,{className:`pl-[1ch]`,children:[(0,D.jsx)(`span`,{children:`This file was deleted.`}),` `,(0,D.jsx)(s,{type:`button`,variant:`link`,size:`sm`,className:`h-auto p-0 text-xs underline underline-offset-4 hover:underline`,onClick:_,children:`Load diff`})]})]}):g?p?(0,D.jsx)(W,{enrichment:l,fileDiffLabel:f}):m?(0,D.jsx)(G,{displayMode:i,enrichment:l,fileDiff:d,fileDiffLabel:f,patchText:b,fullFileContents:y,presentation:r,onSelectionAddToChat:o}):(0,D.jsxs)(D.Fragment,{children:[(0,D.jsx)(w,{file:d,patchText:b,fullFileContents:y,...r,onSelectionAddToChat:o}),(0,D.jsx)(K,{contextExpansion:v,reservesCollapseGutter:a})]}):(0,D.jsx)(u,{}),t[0]=v,t[1]=l,t[2]=d,t[3]=f,t[4]=y,t[5]=p,t[6]=m,t[7]=_,t[8]=o,t[9]=b,t[10]=r,t[11]=a,t[12]=h,t[13]=g,t[14]=i,t[15]=x):x=t[15];let S;return t[16]!==c||t[17]!==x?(S=(0,D.jsx)(`div`,{ref:c,className:`overflow-hidden rounded-b-lg bg-background`,style:O,children:x}),t[16]=c,t[17]=x,t[18]=S):S=t[18],S}function K(e){let t=(0,T.c)(8),{contextExpansion:n,reservesCollapseGutter:r}=e,{status:i,request:a}=n;if(i===`unavailable`||i===`ready`||i===`prefetching`)return null;let o;t[0]===r?o=t[1]:(o=r?(0,D.jsx)(`span`,{"aria-hidden":!0,className:`w-8 shrink-0`}):null,t[0]=r,t[1]=o);let c;t[2]!==a||t[3]!==i?(c=(0,D.jsx)(`span`,{className:`pl-[1ch]`,children:i===`loading`?(0,D.jsx)(`span`,{role:`status`,children:`Loading context…`}):(0,D.jsxs)(D.Fragment,{children:[i===`error`?(0,D.jsxs)(D.Fragment,{children:[(0,D.jsx)(`span`,{className:`text-destructive`,children:`Couldn't load surrounding context.`}),` `]}):null,(0,D.jsx)(s,{type:`button`,variant:`link`,size:`sm`,className:`h-auto p-0 text-xs underline underline-offset-4 hover:underline`,onClick:a,children:i===`error`?`Retry`:`Expand context`})]})}),t[2]=a,t[3]=i,t[4]=c):c=t[4];let l;return t[5]!==o||t[6]!==c?(l=(0,D.jsxs)(`div`,{className:`flex items-center py-2 pl-2 pr-3 text-xs text-muted-foreground`,children:[o,c]}),t[5]=o,t[6]=c,t[7]=l):l=t[7],l}function q(e){let t=(0,T.c)(7),{stat:n}=e,r;t[0]===n.addedBytes?r=t[1]:(r=n.addedBytes===null?null:(0,D.jsx)(`span`,{className:`text-diff-added`,children:`+${i(n.addedBytes)}`}),t[0]=n.addedBytes,t[1]=r);let a;t[2]===n.removedBytes?a=t[3]:(a=n.removedBytes===null?null:(0,D.jsx)(`span`,{className:`text-diff-removed`,children:`-${i(n.removedBytes)}`}),t[2]=n.removedBytes,t[3]=a);let o;return t[4]!==r||t[5]!==a?(o=(0,D.jsxs)(`span`,{className:`flex shrink-0 items-center gap-1 whitespace-nowrap text-xs tabular-nums`,children:[r,a]}),t[4]=r,t[5]=a,t[6]=o):o=t[6],o}function J(e){let t=(0,T.c)(5),{fileLabel:n,isRaw:r,onToggle:i}=e,o=r?`Show image preview for ${n}`:`Show raw SVG diff for ${n}`,s;t[0]===Symbol.for(`react.memo_cache_sentinel`)?(s=(0,D.jsx)(a,{name:`Code`,"aria-hidden":!0,className:`size-3.5`}),t[0]=s):s=t[0];let c;return t[1]!==r||t[2]!==o||t[3]!==i?(c=(0,D.jsx)(`button`,{type:`button`,className:`inline-flex size-5 shrink-0 cursor-pointer items-center justify-center rounded-md text-muted-foreground hover:bg-state-hover hover:text-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring aria-pressed:bg-state-active aria-pressed:text-foreground`,onClick:i,"aria-label":o,"aria-pressed":r,children:s}),t[1]=r,t[2]=o,t[3]=i,t[4]=c):c=t[4],c}function Y(e,t){return e.changeKind!==`renamed`&&e.changeKind!==`copied`?null:t&&t!==e.path?{from:t,to:e.path}:null}function X(e){let t=(0,T.c)(53),{model:n,previousPath:r,filePathRoot:i,onOpenFileInEditor:s,onOpenFilePreview:l,isCollapsed:u,onToggleCollapsed:d,hasChanges:f,statSlot:p,actionSlot:m}=e,g=n.changeKind===`added`,_=n.changeKind===`deleted`,v=_?0:n.insertions,S=g?0:n.deletions,w=g||_,E;t[0]!==n||t[1]!==r?(E=Y(n,r),t[0]=n,t[1]=r,t[2]=E):E=t[2];let O=E,k=n.openablePath,ee;t[3]!==i||t[4]!==k?(ee=k?y({path:k,rootPath:i}):null,t[3]=i,t[4]=k,t[5]=ee):ee=t[5];let A=ee,j=!!k,te=u!==void 0&&d!==void 0,M;t[6]!==f||t[7]!==u||t[8]!==n.label||t[9]!==d||t[10]!==te?(M=te?(0,D.jsx)(`button`,{type:`button`,className:c(`inline-flex w-8 shrink-0 items-center justify-center text-muted-foreground transition-colors`,f?`hover:text-foreground`:`cursor-not-allowed opacity-40`),onClick:f?d:void 0,disabled:!f,"aria-label":f?`${u?`Expand`:`Collapse`} ${n.label}`:`${n.label} has no changes to expand`,"aria-expanded":f?!u:void 0,children:(0,D.jsx)(a,{name:`ChevronRight`,className:c(`size-3.5 shrink-0 transition-transform duration-150`,f&&!u&&`rotate-90`)})}):null,t[6]=f,t[7]=u,t[8]=n.label,t[9]=d,t[10]=te,t[11]=M):M=t[11];let N;t[12]===Symbol.for(`react.memo_cache_sentinel`)?(N=c(`flex min-w-0 items-center gap-1.5`,`pl-[1ch]`),t[12]=N):N=t[12];let P;t[13]===O?P=t[14]:(P=O?(0,D.jsx)(h,{className:`min-w-0 font-mono text-xs leading-5 text-muted-foreground`,title:O.from,children:O.from}):null,t[13]=O,t[14]=P);let F;t[15]===O?F=t[16]:(F=O?(0,D.jsx)(a,{name:`ArrowRight`,"aria-hidden":`true`,className:`size-3 shrink-0 text-subtle-foreground`}):null,t[15]=O,t[16]=F);let I=k??n.path,ne=O?O.to:n.label,L;t[17]!==j||t[18]!==l||t[19]!==k?(L=j&&k&&l?()=>l(k):void 0,t[17]=j,t[18]=l,t[19]=k,t[20]=L):L=t[20];let R;t[21]!==I||t[22]!==ne||t[23]!==L?(R=(0,D.jsx)(C,{path:I,displayName:ne,onClick:L,className:`font-mono font-medium text-foreground`}),t[21]=I,t[22]=ne,t[23]=L,t[24]=R):R=t[24];let z;t[25]!==A||t[26]!==n.label?(z=A?(0,D.jsx)(o,{text:A,label:`Copy path for ${n.label}`,className:`rounded-md hover:bg-state-hover`}):null,t[25]=A,t[26]=n.label,t[27]=z):z=t[27];let B;t[28]!==j||t[29]!==n.label||t[30]!==s||t[31]!==k?(B=j&&k&&s?(0,D.jsx)(x,{onClick:()=>s(k),label:`Open ${n.label} in editor`}):null,t[28]=j,t[29]=n.label,t[30]=s,t[31]=k,t[32]=B):B=t[32];let V;t[33]!==R||t[34]!==z||t[35]!==B||t[36]!==P||t[37]!==F?(V=(0,D.jsxs)(`span`,{className:N,children:[P,F,R,z,B]}),t[33]=R,t[34]=z,t[35]=B,t[36]=P,t[37]=F,t[38]=V):V=t[38];let H;t[39]!==V||t[40]!==M?(H=(0,D.jsxs)(`span`,{className:`flex min-w-0 grow basis-48 items-center`,children:[M,V]}),t[39]=V,t[40]=M,t[41]=H):H=t[41];let U;t[42]!==S||t[43]!==v||t[44]!==w||t[45]!==p?(U=p??(0,D.jsx)(b,{insertions:v,deletions:S,hideZero:w,className:`text-xs`}),t[42]=S,t[43]=v,t[44]=w,t[45]=p,t[46]=U):U=t[46];let W;t[47]!==m||t[48]!==U?(W=(0,D.jsxs)(`span`,{className:`ml-auto flex shrink-0 items-center gap-2`,children:[U,m]}),t[47]=m,t[48]=U,t[49]=W):W=t[49];let G;return t[50]!==H||t[51]!==W?(G=(0,D.jsxs)(`div`,{className:`flex w-full min-w-0 flex-wrap items-center justify-between gap-x-2 gap-y-1`,children:[H,W]}),t[50]=H,t[51]=W,t[52]=G):G=t[52],G}var ie=`rounded-lg bg-background py-1.5 pl-2 pr-3 text-xs font-medium text-foreground`;function Z({stickyHeader:e,isBodyHidden:t,isStuck:n,showStuckHeaderEdge:r=!0}){return c(ie,e&&`sticky z-30`,e&&`top-0`,!t&&`rounded-b-none`,n&&`rounded-t-none`,n&&r&&`shadow-[inset_0_1px_0_var(--border)]`)}export{re as a,I as c,Z as i,q as n,U as o,J as r,H as s,X as t};
|
|
Binary file
|
|
Binary file
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{o as e}from"./rolldown-runtime-BM3Ffeng.js";import{Or as t,mi as n,ni as r}from"./boot-vendor-BBLG7GwQ.js";import{Qm as i,nh as a,oh as o}from"./index-
|
|
1
|
+
import{o as e}from"./rolldown-runtime-BM3Ffeng.js";import{Or as t,mi as n,ni as r}from"./boot-vendor-BBLG7GwQ.js";import{Qm as i,nh as a,oh as o}from"./index-B-RDC4LU.js";import{o as s}from"./queued-editor-typeahead-layout-DKGYsvQ-.js";var c=t(),l=e(n(),1),u=e(r(),1),d=`bg-background shadow-xs`,f=`cursor-pointer text-muted-foreground transition-colors hover:bg-state-hover hover:text-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:cursor-not-allowed disabled:opacity-60`,p=o(`inline-flex items-center whitespace-nowrap rounded border border-border px-1.5 py-0.5 text-xs`,d,f);o(`text-xs`,f,`focus-visible:z-10`);var m=(0,l.forwardRef)(function(e,t){let n=(0,c.c)(11),r,i,a;n[0]===e?(r=n[1],i=n[2],a=n[3]):({className:r,type:a,...i}=e,n[0]=e,n[1]=r,n[2]=i,n[3]=a);let s=a===void 0?`button`:a,l;n[4]===r?l=n[5]:(l=o(p,r),n[4]=r,n[5]=l);let d;return n[6]!==i||n[7]!==t||n[8]!==l||n[9]!==s?(d=(0,u.jsx)(`button`,{ref:t,type:s,className:l,...i}),n[6]=i,n[7]=t,n[8]=l,n[9]=s,n[10]=d):d=n[10],d}),h=`relative bg-surface-raised-solid before:pointer-events-none before:absolute before:inset-y-0 before:right-full before:w-4 before:bg-gradient-to-r before:from-transparent before:to-surface-raised-solid before:content-['']`;function g(e){let t=(0,c.c)(4),{children:n,hideInCompact:r,hideInTiny:i}=e,a=r===void 0?!1:r,o=i===void 0?!0:i,s=a?``:void 0,l=o?``:void 0,d;return t[0]!==n||t[1]!==s||t[2]!==l?(d=(0,u.jsx)(`div`,{className:`ml-auto flex shrink-0 items-center gap-1.5 pr-2 text-xs text-muted-foreground`,"data-promptbox-hide-compact":s,"data-promptbox-hide-tiny":l,children:n}),t[0]=n,t[1]=s,t[2]=l,t[3]=d):d=t[3],d}function _(e){let t=(0,c.c)(27),{cancelLabel:n,children:r,label:l,onCancel:d,variant:f}=e,p=f===void 0?`embedded`:f,m=p===`cap`?`h-8 px-3`:`mb-1.5 pl-1`,h;t[0]===m?h=t[1]:(h=o(`flex min-h-7 items-center gap-1.5 text-xs text-subtle-foreground`,m),t[0]=m,t[1]=h);let g;t[2]===Symbol.for(`react.memo_cache_sentinel`)?(g=(0,u.jsx)(i,{name:`Edit`,className:`size-3.5 shrink-0`,"aria-hidden":!0}),t[2]=g):g=t[2];let _=p===`cap`&&`font-medium`,v;t[3]===_?v=t[4]:(v=o(`shrink-0`,_),t[3]=_,t[4]=v);let y;t[5]!==l||t[6]!==v?(y=(0,u.jsx)(`span`,{className:v,children:l}),t[5]=l,t[6]=v,t[7]=y):y=t[7];let b;t[8]===Symbol.for(`react.memo_cache_sentinel`)?(b=(0,u.jsx)(i,{name:`X`,className:`size-3`,"aria-hidden":!0}),t[8]=b):b=t[8];let x;t[9]!==n||t[10]!==d?(x=(0,u.jsx)(a,{type:`button`,size:`icon`,variant:`ghost`,className:`ml-auto size-6 shrink-0 text-subtle-foreground`,onClick:d,"aria-label":n,children:b}),t[9]=n,t[10]=d,t[11]=x):x=t[11];let S;t[12]!==h||t[13]!==y||t[14]!==x?(S=(0,u.jsxs)(`div`,{className:h,children:[g,y,x]}),t[12]=h,t[13]=y,t[14]=x,t[15]=S):S=t[15];let C=S;if(p===`cap`){let e;t[16]!==C||t[17]!==l?(e=(0,u.jsx)(s,{ariaLabel:l,className:`relative z-10 -mb-5 rounded-xl rounded-b-none border-b-0 bg-surface-raised-solid pb-3 shadow-lift`,children:C}),t[16]=C,t[17]=l,t[18]=e):e=t[18];let n;t[19]===r?n=t[20]:(n=(0,u.jsx)(`div`,{className:`relative z-20`,children:r}),t[19]=r,t[20]=n);let i;return t[21]!==e||t[22]!==n?(i=(0,u.jsxs)(`div`,{className:`relative z-20 space-y-2`,"data-inline-message-editor-frame":`cap`,children:[e,n]}),t[21]=e,t[22]=n,t[23]=i):i=t[23],i}let w;return t[24]!==r||t[25]!==C?(w=(0,u.jsxs)(`div`,{className:`relative z-20`,"data-inline-message-editor-frame":`embedded`,children:[C,r]}),t[24]=r,t[25]=C,t[26]=w):w=t[26],w}export{m as i,g as n,h as r,_ as t};
|
|
Binary file
|
|
Binary file
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{o as e}from"./rolldown-runtime-BM3Ffeng.js";import{Or as t,mi as n,ni as r}from"./boot-vendor-BBLG7GwQ.js";import{$s as i,Bo as a,Ct as o,E as s,Fr as c,Hg as l,Lr as u,Qm as d,Sa as f,Ui as p,Ws as m,b as h,do as g,fo as _,g as v,go as y,ho as b,mo as x,nh as S,oh as C,po as w,qi as T,v as E,w as D,y as O}from"./index-BBxUiLNy.js";import{n as k}from"./AddMachineDialog-4BQFC118.js";import{t as A}from"./checkbox-Ct38DhHB.js";import{t as j}from"./update-state-DCxKj9tm.js";import{n as M,t as N}from"./host-mutations-Ckc-eVys.js";var P=t();function F(e){return e.phase===`removing`&&e.teardown?.status===`failed`?`Cleanup failed`:e.phase===`suspending`?`Pausing`:e.phase===`suspended`?`Paused`:e.phase===`resuming`?`Resuming`:e.phase===`removing`?`Removing`:null}function I(e){return F(e.lifecycle)===`Cleanup failed`?`failed`:e.lifecycle.phase===`removing`||e.lifecycle.phase===`suspending`||e.lifecycle.phase===`resuming`?`attention`:e.status===`connected`?`online`:`offline`}function L({host:e,now:t}){let n=[],r=F(e.lifecycle);return n.push(r??(e.status===`connected`?`Online`:`Offline`)),e.lifecycle.message===null?e.status!==`connected`&&e.lastSeenAt!==null&&n.push(`last seen ${f({timestamp:e.lastSeenAt,now:t})}`):n.push(e.lifecycle.message),n.join(` · `)}function R(e){return e.status!==`connected`&&e.lifecycle.phase===`active`}function z(e){return e.status!==`connected`&&e.lifecycle.phase===`removing`&&e.lifecycle.teardown?.status===`failed`}var B=e(r(),1),V=5;function H(e){return e?`The server machine can't be removed. Move the server to another machine first.`:`The server machine can't be removed.`}function U(e){return e.type===`ephemeral`?`The compute and its saved snapshots are deleted. Its environments remain as read-only history.`:e.machineProviderId===null?`Project checkouts stay on its disk, but its environments become read-only history and it cannot run new work until paired again.`:`The provider cleans up resources it owns. Its environments remain as read-only history.`}function W(e){let t=(0,P.c)(14),{hostId:n}=e,r;t[0]===n?r=t[1]:(r={hostId:n,limit:V},t[0]=n,t[1]=r);let a=i(r);if(a.data===void 0||a.data.total===0)return null;let{threads:o,total:s}=a.data,c=s-o.length,l=s===1?`1 unarchived thread on this machine:`:`${s} unarchived threads on this machine:`,u;t[2]===l?u=t[3]:(u=(0,B.jsx)(`p`,{children:l}),t[2]=l,t[3]=u);let d;t[4]===o?d=t[5]:(d=o.map(G),t[4]=o,t[5]=d);let f;t[6]===d?f=t[7]:(f=(0,B.jsx)(`ul`,{className:`list-disc space-y-0.5 pl-5 text-foreground marker:text-subtle-foreground`,children:d}),t[6]=d,t[7]=f);let p;t[8]===c?p=t[9]:(p=c>0?(0,B.jsxs)(`p`,{children:[`and `,c,` more`]}):null,t[8]=c,t[9]=p);let m;return t[10]!==u||t[11]!==f||t[12]!==p?(m=(0,B.jsxs)(`div`,{className:`space-y-1 text-sm text-muted-foreground`,children:[u,f,p]}),t[10]=u,t[11]=f,t[12]=p,t[13]=m):m=t[13],m}function G(e){return(0,B.jsx)(`li`,{children:(0,B.jsx)(`span`,{className:`block truncate`,children:m(e)})},e.id)}function K(e){let t=(0,P.c)(15),{target:n,onOpenChange:r,onRemoved:i}=e,o=M(),s;t[0]===n?s=t[1]:(s=n!==null&&z(n),t[0]=n,t[1]=s);let c=s,l=n!==null,d;t[2]!==r||t[3]!==o?(d=e=>{!e&&!o.isPending&&(o.reset(),r(!1))},t[2]=r,t[3]=o,t[4]=d):d=t[4];let f;t[5]!==c||t[6]!==r||t[7]!==i||t[8]!==o||t[9]!==n?(f=n===null?null:(0,B.jsxs)(B.Fragment,{children:[(0,B.jsxs)(b,{children:[(0,B.jsxs)(y,{children:[`Remove `,n.name,`?`]}),(0,B.jsx)(w,{children:c?(0,B.jsxs)(B.Fragment,{children:[`Cleanup failed and `,n.name,` is not connected. Removing it now skips environment cleanup on the machine: files and worktrees left on its disk are not deleted, and its environments become read-only history. The machine provider's removal still runs. Use this only if the machine is gone or will not come back.`]}):(0,B.jsxs)(B.Fragment,{children:[`This revokes `,n.name,`'s access to this server.`,` `,U(n)]})})]}),(0,B.jsx)(W,{hostId:n.id}),o.isError?(0,B.jsx)(`p`,{className:`text-sm text-destructive`,role:`alert`,children:a({error:o.error,fallbackMessage:`Couldn't remove ${n.name}.`})}):null,(0,B.jsx)(x,{children:(0,B.jsx)(S,{type:`button`,variant:`destructive`,disabled:o.isPending,onClick:()=>o.mutate({hostId:n.id,force:c},{onSuccess:()=>{r(!1),i?.(n)}}),children:c?`Remove anyway`:`Remove machine`})})]}),t[5]=c,t[6]=r,t[7]=i,t[8]=o,t[9]=n,t[10]=f):f=t[10];let p;return t[11]!==l||t[12]!==d||t[13]!==f?(p=(0,B.jsx)(u,{open:l,onOpenChange:d,children:f}),t[11]=l,t[12]=d,t[13]=f,t[14]=p):p=t[14],p}function q(e,t){return t?.supportsSuspend&&e.lifecycle.phase===`active`?{icon:`Pause`,label:`Suspend`,kind:`suspend`}:t?.supportsSuspend&&e.lifecycle.phase===`suspended`?{icon:`Play`,label:`Resume`,kind:`resume`}:e.lifecycle.phase===`removing`&&e.lifecycle.teardown?.status===`failed`?{icon:`RotateCcw`,label:`Retry cleanup`,kind:`retry-cleanup`}:null}function J(e){let t=(0,P.c)(10),{host:n,machineProvider:r,pending:i,onSuspend:a,onResume:o,onRetryCleanup:s}=e,c;t[0]!==n||t[1]!==r?(c=q(n,r),t[0]=n,t[1]=r,t[2]=c):c=t[2];let l=c;if(l===null)return null;let u=l.kind===`suspend`?a:l.kind===`resume`?o:s,f;t[3]===l.icon?f=t[4]:(f=(0,B.jsx)(d,{name:l.icon,className:`size-3.5`,"aria-hidden":!0}),t[3]=l.icon,t[4]=f);let p;return t[5]!==l.label||t[6]!==u||t[7]!==i||t[8]!==f?(p=(0,B.jsxs)(S,{type:`button`,variant:`outline`,size:`sm`,disabled:i,onClick:u,children:[f,l.label]}),t[5]=l.label,t[6]=u,t[7]=i,t[8]=f,t[9]=p):p=t[9],p}function Y(e){let t=[{id:`rename`,label:`Rename`,icon:`Edit`,onSelect:e.onRename}];R(e.host)&&t.push({id:`reconnect`,label:`Reconnect`,icon:`RotateCcw`,onSelect:e.onReconnect});let n=e.onRetryUpdate;n!==void 0&&o(e.host)&&t.push({id:`retry-update`,label:e.retryUpdatePending??!1?`Retrying update…`:`Retry update`,icon:j,disabled:e.retryUpdatePending??!1,onSelect:n});let r=q(e.host,e.machineProvider),i=r===null?void 0:r.kind===`suspend`?e.onSuspend:r.kind===`resume`?e.onResume:e.onRetryCleanup;r!==null&&i!==void 0&&t.push({id:`lifecycle`,label:r.label,icon:r.icon,disabled:e.lifecycleActionPending??!1,onSelect:i}),e.canMoveServerHere&&t.push({id:`move-server`,label:`Move server here`,icon:`MoveTo`,onSelect:e.onMoveServerHere});let a=e.onRemove;return a!==void 0&&t.push({id:`remove`,label:`Remove machine`,icon:`Trash2`,tone:`destructive`,...e.isPrimary?{disabled:!0,disabledReason:H(e.serverMoveEnabled??!1)}:{},onSelect:a}),t}var X=e(n(),1);function Z(e){let t=(0,P.c)(35),{target:n,onOpenChange:r}=e,i=N(),o=n?.id??null,{mutate:s,reset:c}=i,l,u;t[0]!==o||t[1]!==s||t[2]!==c?(l=()=>{if(o===null){c();return}s(o)},u=[o,s,c],t[0]=o,t[1]=s,t[2]=c,t[3]=l,t[4]=u):(l=t[3],u=t[4]),(0,X.useEffect)(l,u);let f=i.data??null,m=n!==null&&n.status===`connected`,h;t[5]!==i.error||t[6]!==i.isError?(h=i.isError?a({error:i.error,fallbackMessage:`Couldn't prepare a reconnect command.`}):null,t[5]=i.error,t[6]=i.isError,t[7]=h):h=t[7];let v=h,x=n!==null,C;t[8]===Symbol.for(`react.memo_cache_sentinel`)?(C=(0,B.jsx)(y,{children:`Reconnect machine`}),t[8]=C):C=t[8];let T=v===null?void 0:`text-destructive-text`,E=v??`Run this command on ${n?.name??`the machine`} to bring it back online. It keeps the machine's projects, environments and history.`,D;t[9]!==T||t[10]!==E?(D=(0,B.jsxs)(b,{children:[C,(0,B.jsx)(w,{className:T,children:E})]}),t[9]=T,t[10]=E,t[11]=D):D=t[11];let O;t[12]!==v||t[13]!==o||t[14]!==s?(O=v===null?null:(0,B.jsx)(`div`,{className:`flex justify-end`,children:(0,B.jsx)(S,{variant:`outline`,size:`sm`,onClick:()=>{o!==null&&s(o)},children:`Try again`})}),t[12]=v,t[13]=o,t[14]=s,t[15]=O):O=t[15];let A;t[16]!==o||t[17]!==s||t[18]!==f?(A=f===null?null:(0,B.jsx)(k,{command:f.command,windowsCommand:f.windowsCommand,expiresAt:f.expiresAt,onRegenerate:()=>{o!==null&&s(o)}},f.command),t[16]=o,t[17]=s,t[18]=f,t[19]=A):A=t[19];let j;t[20]!==v||t[21]!==r||t[22]!==f||t[23]!==m||t[24]!==n?.name?(j=v===null?(0,B.jsx)(`div`,{className:`flex items-center gap-2.5 rounded-md bg-muted/40 px-3 py-2.5`,children:m?(0,B.jsxs)(B.Fragment,{children:[(0,B.jsx)(p,{connected:!0}),(0,B.jsxs)(`span`,{role:`status`,className:`min-w-0 flex-1 truncate text-sm text-foreground`,children:[n?.name,` reconnected`]}),(0,B.jsx)(S,{size:`sm`,variant:`ghost`,className:`h-7 shrink-0 px-2 text-xs`,onClick:()=>r(!1),children:`Done`})]}):(0,B.jsxs)(B.Fragment,{children:[(0,B.jsx)(d,{name:`Spinner`,className:`size-4 shrink-0 animate-spin text-muted-foreground`}),(0,B.jsx)(`span`,{role:`status`,className:`text-sm text-muted-foreground`,children:f===null?`Preparing a reconnect command…`:`Waiting for the machine to reconnect…`})]})}):null,t[20]=v,t[21]=r,t[22]=f,t[23]=m,t[24]=n?.name,t[25]=j):j=t[25];let M;t[26]!==A||t[27]!==j||t[28]!==D||t[29]!==O?(M=(0,B.jsxs)(_,{className:`max-h-[calc(100dvh-2rem)] overflow-y-auto`,onInteractOutside:Q,children:[D,O,A,j]}),t[26]=A,t[27]=j,t[28]=D,t[29]=O,t[30]=M):M=t[30];let F;return t[31]!==r||t[32]!==M||t[33]!==x?(F=(0,B.jsx)(g,{open:x,onOpenChange:r,children:M}),t[31]=r,t[32]=M,t[33]=x,t[34]=F):F=t[34],F}function Q(e){return e.preventDefault()}var $={blocker:{heading:`Fix before moving`,icon:`AlertCircle`,iconClassName:`text-destructive-text`},warning:{heading:`Before you move`,icon:`AlertTriangle`,iconClassName:`text-warning-text`},info:{heading:`Good to know`,icon:`Info`,iconClassName:`text-muted-foreground`}};function ee(e){let t=(0,P.c)(17),{target:n,onOpenChange:r}=e,i=s(),a;t[0]!==r||t[1]!==i?(a=()=>{i.isPending||(i.reset(),r(!1))},t[0]=r,t[1]=i,t[2]=a):a=t[2];let o=a,c=n!==null,l;t[3]===o?l=t[4]:(l=e=>{e||o()},t[3]=o,t[4]=l);let u;t[5]!==o||t[6]!==r||t[7]!==i||t[8]!==n?(u=n===null?null:(0,B.jsx)(te,{target:n,startMove:i,onCancel:o,onStarted:()=>r(!1)},n.id),t[5]=o,t[6]=r,t[7]=i,t[8]=n,t[9]=u):u=t[9];let d;t[10]!==i.isPending||t[11]!==u?(d=(0,B.jsx)(_,{className:`max-h-[calc(100dvh-2rem)] overflow-y-auto`,hideCloseButton:i.isPending,children:u}),t[10]=i.isPending,t[11]=u,t[12]=d):d=t[12];let f;return t[13]!==c||t[14]!==l||t[15]!==d?(f=(0,B.jsx)(g,{open:c,onOpenChange:l,children:d}),t[13]=c,t[14]=l,t[15]=d,t[16]=f):f=t[16],f}function te(e){let t=(0,P.c)(48),{target:n,startMove:r,onCancel:i,onStarted:o}=e,s=D(),[c,l]=(0,X.useState)(null),[u,d]=(0,X.useState)(null),[f,p]=(0,X.useState)(``),[m,g]=(0,X.useState)(!1),_=s.mutate,v=n.id,y,b;t[0]!==_||t[1]!==v?(y=()=>{_({targetHostId:v,serverUrl:null},{onSuccess:e=>{l(e),d(null),e.requiresServerUrl&&e.serverUrl!==null&&p(e.serverUrl)}})},b=[_,v],t[0]=_,t[1]=v,t[2]=y,t[3]=b):(y=t[2],b=t[3]),(0,X.useEffect)(y,b);let x=c?.requiresServerUrl===!0||u!==null,S;t[4]!==f||t[5]!==s||t[6]!==c?.existingTargetServerData?.path||t[7]!==x||t[8]!==r||t[9]!==v?(S=()=>{let e=f.trim(),t=x&&e.length>0?e:null;r.reset(),s.mutate({targetHostId:v,serverUrl:t},{onSuccess:e=>{e.existingTargetServerData?.path!==c?.existingTargetServerData?.path&&g(!1),l(e),d(t)}})},t[4]=f,t[5]=s,t[6]=c?.existingTargetServerData?.path,t[7]=x,t[8]=r,t[9]=v,t[10]=S):S=t[10];let C=S,w;t[11]!==f||t[12]!==m||t[13]!==s.isPending||t[14]!==u||t[15]!==c||t[16]!==x||t[17]!==r.isPending?(w=h({result:c,checking:s.isPending,starting:r.isPending,showAddress:x,addressDraft:f,checkedServerUrl:u,archiveConfirmed:m}),t[11]=f,t[12]=m,t[13]=s.isPending,t[14]=u,t[15]=c,t[16]=x,t[17]=r.isPending,t[18]=w):w=t[18];let T=w,E;t[19]!==m||t[20]!==u||t[21]!==o||t[22]!==c||t[23]!==T||t[24]!==r||t[25]!==v?(E=()=>{c===null||!T||r.mutate({targetHostId:v,serverUrl:u,stopRunningWork:!0,archiveExistingTargetServerData:c.existingTargetServerData!==null&&m},{onSuccess:o,onError:e=>{let t=O(e);t!==null&&l({...c,items:t,canMove:!1})}})},t[19]=m,t[20]=u,t[21]=o,t[22]=c,t[23]=T,t[24]=r,t[25]=v,t[26]=E):E=t[26];let k=E,A;t[27]!==s.error||t[28]!==s.isError||t[29]!==n.name?(A=s.isError?a({error:s.error,fallbackMessage:`Couldn't check ${n.name}.`}):null,t[27]=s.error,t[28]=s.isError,t[29]=n.name,t[30]=A):A=t[30];let j;t[31]!==r.error||t[32]!==r.isError?(j=r.isError?a({error:r.error,fallbackMessage:`Couldn't start the move.`}):null,t[31]=r.error,t[32]=r.isError,t[33]=j):j=t[33];let M;return t[34]!==f||t[35]!==m||t[36]!==C||t[37]!==s.isPending||t[38]!==i||t[39]!==c||t[40]!==x||t[41]!==k||t[42]!==T||t[43]!==r.isPending||t[44]!==A||t[45]!==j||t[46]!==n.name?(M=(0,B.jsx)(ne,{targetName:n.name,result:c,checking:s.isPending,checkError:A,showAddress:x,addressDraft:f,archiveConfirmed:m,startAllowed:T,starting:r.isPending,startError:j,onAddressDraftChange:p,onCheck:C,onArchiveConfirmedChange:g,onStart:k,onCancel:i}),t[34]=f,t[35]=m,t[36]=C,t[37]=s.isPending,t[38]=i,t[39]=c,t[40]=x,t[41]=k,t[42]=T,t[43]=r.isPending,t[44]=A,t[45]=j,t[46]=n.name,t[47]=M):M=t[47],M}function ne(e){let t=(0,P.c)(53),{targetName:n,result:r,checking:i,checkError:a,showAddress:o,addressDraft:s,archiveConfirmed:c,startAllowed:l,starting:u,startError:f,onAddressDraftChange:p,onCheck:m,onArchiveConfirmedChange:h,onStart:g,onCancel:_}=e,v;t[0]===r?.items?v=t[1]:(v=r?.items.some(re)??!1,t[0]=r?.items,t[1]=v);let C=!i&&(a!==null||v)&&!o,T;t[2]===n?T=t[3]:(T=(0,B.jsxs)(b,{children:[(0,B.jsxs)(y,{children:[`Move the server to `,n]}),(0,B.jsxs)(w,{children:[`Your threads, settings and plugin data move to `,n,`. Every machine and app switches over when it's done, and the current server machine keeps running as a regular machine.`]})]}),t[2]=n,t[3]=T);let E;t[4]!==a||t[5]!==r||t[6]!==n?(E=r===null&&a===null?(0,B.jsxs)(`div`,{className:`flex items-center gap-2.5 rounded-md bg-muted/40 px-3 py-2.5`,children:[(0,B.jsx)(d,{name:`Spinner`,className:`size-4 shrink-0 animate-spin text-muted-foreground`}),(0,B.jsxs)(`span`,{role:`status`,className:`text-sm text-muted-foreground`,children:[`Checking `,n,`…`]})]}):null,t[4]=a,t[5]=r,t[6]=n,t[7]=E):E=t[7];let D;t[8]!==s||t[9]!==i||t[10]!==p||t[11]!==m||t[12]!==o||t[13]!==u||t[14]!==n?(D=o?(0,B.jsx)(ie,{targetName:n,value:s,checking:i,disabled:u,onChange:p,onCheck:m}):null,t[8]=s,t[9]=i,t[10]=p,t[11]=m,t[12]=o,t[13]=u,t[14]=n,t[15]=D):D=t[15];let O;t[16]===a?O=t[17]:(O=a===null?null:(0,B.jsx)(`p`,{role:`alert`,className:`text-sm text-destructive-text`,children:a}),t[16]=a,t[17]=O);let k;t[18]!==i||t[19]!==r?(k=r===null?null:(0,B.jsx)(ae,{items:r.items,dimmed:i}),t[18]=i,t[19]=r,t[20]=k):k=t[20];let A;t[21]!==c||t[22]!==h||t[23]!==r||t[24]!==u?(A=r?.existingTargetServerData?(0,B.jsx)(oe,{path:r.existingTargetServerData.path,sizeBytes:r.existingTargetServerData.sizeBytes,checked:c,disabled:u,onCheckedChange:h}):null,t[21]=c,t[22]=h,t[23]=r,t[24]=u,t[25]=A):A=t[25];let j;t[26]===f?j=t[27]:(j=f===null?null:(0,B.jsx)(`p`,{role:`alert`,className:`text-sm text-destructive-text`,children:f}),t[26]=f,t[27]=j);let M;t[28]===Symbol.for(`react.memo_cache_sentinel`)?(M=(0,B.jsx)(`p`,{className:`text-xs text-subtle-foreground`,children:`Moving stops every running turn and pauses scheduled automations.`}),t[28]=M):M=t[28];let N;t[29]!==_||t[30]!==u?(N=(0,B.jsx)(S,{type:`button`,variant:`outline`,disabled:u,onClick:_,children:`Cancel`}),t[29]=_,t[30]=u,t[31]=N):N=t[31];let F;t[32]!==m||t[33]!==C||t[34]!==u?(F=C?(0,B.jsx)(S,{type:`button`,variant:`outline`,disabled:u,onClick:m,children:`Check again`}):null,t[32]=m,t[33]=C,t[34]=u,t[35]=F):F=t[35];let I=!l,L=u?`Starting…`:`Stop all and move`,R;t[36]!==g||t[37]!==I||t[38]!==L?(R=(0,B.jsx)(S,{type:`button`,disabled:I,onClick:g,children:L}),t[36]=g,t[37]=I,t[38]=L,t[39]=R):R=t[39];let z;t[40]!==N||t[41]!==F||t[42]!==R?(z=(0,B.jsxs)(x,{children:[N,F,R]}),t[40]=N,t[41]=F,t[42]=R,t[43]=z):z=t[43];let V;return t[44]!==z||t[45]!==T||t[46]!==E||t[47]!==D||t[48]!==O||t[49]!==k||t[50]!==A||t[51]!==j?(V=(0,B.jsxs)(B.Fragment,{children:[T,E,D,O,k,A,j,M,z]}),t[44]=z,t[45]=T,t[46]=E,t[47]=D,t[48]=O,t[49]=k,t[50]=A,t[51]=j,t[52]=V):V=t[52],V}function re(e){return e.severity===`blocker`}function ie(e){let t=(0,P.c)(32),{targetName:n,value:r,checking:i,disabled:a,onChange:o,onCheck:s}=e,c=(0,X.useId)(),l=(0,X.useId)(),u;t[0]!==i||t[1]!==a||t[2]!==r?(u=!i&&!a&&r.trim().length>0,t[0]=i,t[1]=a,t[2]=r,t[3]=u):u=t[3];let d=u,f;t[4]===c?f=t[5]:(f=(0,B.jsx)(`label`,{htmlFor:c,className:`block text-sm font-medium text-foreground`,children:`New server address`}),t[4]=c,t[5]=f);let p;t[6]!==l||t[7]!==n?(p=(0,B.jsxs)(`p`,{id:l,className:`text-xs text-subtle-foreground`,children:[`Machines and apps use this address to reach the server on `,n,` `,`after the move.`]}),t[6]=l,t[7]=n,t[8]=p):p=t[8];let m;t[9]===o?m=t[10]:(m=e=>o(e.target.value),t[9]=o,t[10]=m);let h;t[11]!==d||t[12]!==s?(h=e=>{e.key===`Enter`&&(e.preventDefault(),d&&s())},t[11]=d,t[12]=s,t[13]=h):h=t[13];let g;t[14]!==a||t[15]!==l||t[16]!==c||t[17]!==m||t[18]!==h||t[19]!==r?(g=(0,B.jsx)(T,{id:c,"aria-describedby":l,className:`min-w-0 flex-1`,value:r,placeholder:`https://bb.example.com`,inputMode:`url`,autoCapitalize:`off`,autoCorrect:`off`,spellCheck:!1,disabled:a,onChange:m,onKeyDown:h}),t[14]=a,t[15]=l,t[16]=c,t[17]=m,t[18]=h,t[19]=r,t[20]=g):g=t[20];let _=!d,v=i?`Checking…`:`Check address`,y;t[21]!==s||t[22]!==_||t[23]!==v?(y=(0,B.jsx)(S,{type:`button`,variant:`outline`,disabled:_,onClick:s,children:v}),t[21]=s,t[22]=_,t[23]=v,t[24]=y):y=t[24];let b;t[25]!==g||t[26]!==y?(b=(0,B.jsxs)(`div`,{className:`flex min-w-0 items-center gap-2`,children:[g,y]}),t[25]=g,t[26]=y,t[27]=b):b=t[27];let x;return t[28]!==b||t[29]!==f||t[30]!==p?(x=(0,B.jsxs)(`div`,{className:`space-y-2`,children:[f,p,b]}),t[28]=b,t[29]=f,t[30]=p,t[31]=x):x=t[31],x}function ae(e){let t=(0,P.c)(11),{items:n,dimmed:r}=e,i,a,o;if(t[0]!==r||t[1]!==n){o=Symbol.for(`react.early_return_sentinel`);bb0:{let e=E(n);if(n.length===0){let e;t[5]===Symbol.for(`react.memo_cache_sentinel`)?(e=(0,B.jsx)(`p`,{className:`text-sm text-muted-foreground`,children:`Nothing needs attention before the move.`}),t[5]=e):e=t[5],o=e;break bb0}let s=r&&`opacity-60`;t[6]===s?i=t[7]:(i=C(`space-y-3 transition-opacity`,s),t[6]=s,t[7]=i),a=v.map(t=>{let n=e[t];if(n.length===0)return null;let r=$[t];return(0,B.jsxs)(`section`,{"aria-label":r.heading,className:`space-y-1.5`,children:[(0,B.jsx)(`h3`,{className:`text-xs font-medium text-muted-foreground`,children:r.heading}),(0,B.jsx)(`ul`,{className:`space-y-2`,children:n.map(e=>(0,B.jsxs)(`li`,{"data-severity":t,className:`flex items-start gap-2.5`,children:[(0,B.jsx)(d,{name:r.icon,"aria-hidden":!0,className:C(`mt-0.5 size-4 shrink-0`,r.iconClassName)}),(0,B.jsxs)(`div`,{className:`min-w-0 flex-1`,children:[(0,B.jsx)(`p`,{className:`text-sm break-words text-foreground`,children:e.title}),e.detail===null?null:(0,B.jsx)(`p`,{className:`text-xs break-words text-subtle-foreground`,children:e.detail})]})]},e.id))})]},t)})}t[0]=r,t[1]=n,t[2]=i,t[3]=a,t[4]=o}else i=t[2],a=t[3],o=t[4];if(o!==Symbol.for(`react.early_return_sentinel`))return o;let s;return t[8]!==i||t[9]!==a?(s=(0,B.jsx)(`div`,{className:i,children:a}),t[8]=i,t[9]=a,t[10]=s):s=t[10],s}function oe(e){let t=(0,P.c)(18),{path:n,sizeBytes:r,checked:i,disabled:a,onCheckedChange:o}=e,s;t[0]===o?s=t[1]:(s=e=>o(e===!0),t[0]=o,t[1]=s);let c;t[2]!==i||t[3]!==a||t[4]!==s?(c=(0,B.jsx)(A,{className:`mt-0.5`,checked:i,disabled:a,onCheckedChange:s}),t[2]=i,t[3]=a,t[4]=s,t[5]=c):c=t[5];let u;t[6]===n?u=t[7]:(u=(0,B.jsxs)(`span`,{className:`block text-sm break-words text-foreground`,children:[`Archive the existing bb data at `,n]}),t[6]=n,t[7]=u);let d;t[8]===r?d=t[9]:(d=l(r),t[8]=r,t[9]=d);let f;t[10]===d?f=t[11]:(f=(0,B.jsxs)(`span`,{className:`block text-xs text-subtle-foreground`,children:[d,`. bb renames it to a backup folder next to it and never merges it.`]}),t[10]=d,t[11]=f);let p;t[12]!==u||t[13]!==f?(p=(0,B.jsxs)(`span`,{className:`min-w-0 flex-1`,children:[u,f]}),t[12]=u,t[13]=f,t[14]=p):p=t[14];let m;return t[15]!==c||t[16]!==p?(m=(0,B.jsxs)(`label`,{className:`flex items-start gap-2.5 rounded-md border border-border px-3 py-2.5`,children:[c,p]}),t[15]=c,t[16]=p,t[17]=m):m=t[17],m}var se=100;function ce(e){let t=(0,P.c)(9),{target:n,pending:r,errorMessage:i,onOpenChange:a,onRename:o}=e,s=n!==null,l;t[0]!==i||t[1]!==o||t[2]!==r||t[3]!==n?(l=e=>n?(0,B.jsx)(le,{target:n,pending:r,errorMessage:i,onRename:o,inputRef:e},n.id):null,t[0]=i,t[1]=o,t[2]=r,t[3]=n,t[4]=l):l=t[4];let u;return t[5]!==a||t[6]!==s||t[7]!==l?(u=(0,B.jsx)(c,{open:s,onOpenChange:a,children:l}),t[5]=a,t[6]=s,t[7]=l,t[8]=u):u=t[8],u}function le(e){let t=(0,P.c)(30),{target:n,pending:r,errorMessage:i,onRename:a,inputRef:o}=e,[s,c]=(0,X.useState)(n.name),l;t[0]!==s||t[1]!==a||t[2]!==r||t[3]!==n?(l=e=>{if(e.preventDefault(),r)return;let t=s.trim();t.length!==0&&a(n,t)},t[0]=s,t[1]=a,t[2]=r,t[3]=n,t[4]=l):l=t[4];let u=l,d;t[5]===Symbol.for(`react.memo_cache_sentinel`)?(d=(0,B.jsx)(y,{children:`Rename machine`}),t[5]=d):d=t[5];let f;t[6]===n.name?f=t[7]:(f=(0,B.jsxs)(b,{children:[d,(0,B.jsxs)(w,{children:[`Choose a new name for `,n.name,`.`]})]}),t[6]=n.name,t[7]=f);let p;t[8]===Symbol.for(`react.memo_cache_sentinel`)?(p=e=>c(e.target.value),t[8]=p):p=t[8];let m;t[9]!==o||t[10]!==s||t[11]!==r?(m=(0,B.jsx)(T,{ref:o,"aria-label":`Machine name`,value:s,maxLength:se,autoCorrect:`off`,spellCheck:!1,disabled:r,onChange:p}),t[9]=o,t[10]=s,t[11]=r,t[12]=m):m=t[12];let h;t[13]===i?h=t[14]:(h=i===null?null:(0,B.jsx)(`p`,{className:`text-sm text-destructive`,children:i}),t[13]=i,t[14]=h);let g;t[15]!==m||t[16]!==h?(g=(0,B.jsxs)(`div`,{className:`space-y-2`,children:[m,h]}),t[15]=m,t[16]=h,t[17]=g):g=t[17];let _;t[18]!==s||t[19]!==r?(_=r||s.trim().length===0,t[18]=s,t[19]=r,t[20]=_):_=t[20];let v;t[21]===_?v=t[22]:(v=(0,B.jsx)(x,{children:(0,B.jsx)(S,{type:`submit`,disabled:_,children:`Rename machine`})}),t[21]=_,t[22]=v);let C;t[23]!==u||t[24]!==g||t[25]!==v?(C=(0,B.jsxs)(`form`,{className:`space-y-4`,onSubmit:u,children:[g,v]}),t[23]=u,t[24]=g,t[25]=v,t[26]=C):C=t[26];let E;return t[27]!==C||t[28]!==f?(E=(0,B.jsxs)(B.Fragment,{children:[f,C]}),t[27]=C,t[28]=f,t[29]=E):E=t[29],E}export{J as a,H as c,Y as i,L as l,ee as n,K as o,Z as r,U as s,ce as t,I as u};
|
|
1
|
+
import{o as e}from"./rolldown-runtime-BM3Ffeng.js";import{Or as t,mi as n,ni as r}from"./boot-vendor-BBLG7GwQ.js";import{$s as i,Bo as a,Ct as o,E as s,Fr as c,Hg as l,Lr as u,Qm as d,Sa as f,Ui as p,Ws as m,b as h,do as g,fo as _,g as v,go as y,ho as b,mo as x,nh as S,oh as C,po as w,qi as T,v as E,w as D,y as O}from"./index-B-RDC4LU.js";import{n as k}from"./AddMachineDialog-BlVfh9PM.js";import{t as A}from"./checkbox-5zZ_V1_F.js";import{t as j}from"./update-state-DCxKj9tm.js";import{n as M,t as N}from"./host-mutations-Bf4idS3m.js";var P=t();function F(e){return e.phase===`removing`&&e.teardown?.status===`failed`?`Cleanup failed`:e.phase===`suspending`?`Pausing`:e.phase===`suspended`?`Paused`:e.phase===`resuming`?`Resuming`:e.phase===`removing`?`Removing`:null}function I(e){return F(e.lifecycle)===`Cleanup failed`?`failed`:e.lifecycle.phase===`removing`||e.lifecycle.phase===`suspending`||e.lifecycle.phase===`resuming`?`attention`:e.status===`connected`?`online`:`offline`}function L({host:e,now:t}){let n=[],r=F(e.lifecycle);return n.push(r??(e.status===`connected`?`Online`:`Offline`)),e.lifecycle.message===null?e.status!==`connected`&&e.lastSeenAt!==null&&n.push(`last seen ${f({timestamp:e.lastSeenAt,now:t})}`):n.push(e.lifecycle.message),n.join(` · `)}function R(e){return e.status!==`connected`&&e.lifecycle.phase===`active`}function z(e){return e.status!==`connected`&&e.lifecycle.phase===`removing`&&e.lifecycle.teardown?.status===`failed`}var B=e(r(),1),V=5;function H(e){return e?`The server machine can't be removed. Move the server to another machine first.`:`The server machine can't be removed.`}function U(e){return e.type===`ephemeral`?`The compute and its saved snapshots are deleted. Its environments remain as read-only history.`:e.machineProviderId===null?`Project checkouts stay on its disk, but its environments become read-only history and it cannot run new work until paired again.`:`The provider cleans up resources it owns. Its environments remain as read-only history.`}function W(e){let t=(0,P.c)(14),{hostId:n}=e,r;t[0]===n?r=t[1]:(r={hostId:n,limit:V},t[0]=n,t[1]=r);let a=i(r);if(a.data===void 0||a.data.total===0)return null;let{threads:o,total:s}=a.data,c=s-o.length,l=s===1?`1 unarchived thread on this machine:`:`${s} unarchived threads on this machine:`,u;t[2]===l?u=t[3]:(u=(0,B.jsx)(`p`,{children:l}),t[2]=l,t[3]=u);let d;t[4]===o?d=t[5]:(d=o.map(G),t[4]=o,t[5]=d);let f;t[6]===d?f=t[7]:(f=(0,B.jsx)(`ul`,{className:`list-disc space-y-0.5 pl-5 text-foreground marker:text-subtle-foreground`,children:d}),t[6]=d,t[7]=f);let p;t[8]===c?p=t[9]:(p=c>0?(0,B.jsxs)(`p`,{children:[`and `,c,` more`]}):null,t[8]=c,t[9]=p);let m;return t[10]!==u||t[11]!==f||t[12]!==p?(m=(0,B.jsxs)(`div`,{className:`space-y-1 text-sm text-muted-foreground`,children:[u,f,p]}),t[10]=u,t[11]=f,t[12]=p,t[13]=m):m=t[13],m}function G(e){return(0,B.jsx)(`li`,{children:(0,B.jsx)(`span`,{className:`block truncate`,children:m(e)})},e.id)}function K(e){let t=(0,P.c)(15),{target:n,onOpenChange:r,onRemoved:i}=e,o=M(),s;t[0]===n?s=t[1]:(s=n!==null&&z(n),t[0]=n,t[1]=s);let c=s,l=n!==null,d;t[2]!==r||t[3]!==o?(d=e=>{!e&&!o.isPending&&(o.reset(),r(!1))},t[2]=r,t[3]=o,t[4]=d):d=t[4];let f;t[5]!==c||t[6]!==r||t[7]!==i||t[8]!==o||t[9]!==n?(f=n===null?null:(0,B.jsxs)(B.Fragment,{children:[(0,B.jsxs)(b,{children:[(0,B.jsxs)(y,{children:[`Remove `,n.name,`?`]}),(0,B.jsx)(w,{children:c?(0,B.jsxs)(B.Fragment,{children:[`Cleanup failed and `,n.name,` is not connected. Removing it now skips environment cleanup on the machine: files and worktrees left on its disk are not deleted, and its environments become read-only history. The machine provider's removal still runs. Use this only if the machine is gone or will not come back.`]}):(0,B.jsxs)(B.Fragment,{children:[`This revokes `,n.name,`'s access to this server.`,` `,U(n)]})})]}),(0,B.jsx)(W,{hostId:n.id}),o.isError?(0,B.jsx)(`p`,{className:`text-sm text-destructive`,role:`alert`,children:a({error:o.error,fallbackMessage:`Couldn't remove ${n.name}.`})}):null,(0,B.jsx)(x,{children:(0,B.jsx)(S,{type:`button`,variant:`destructive`,disabled:o.isPending,onClick:()=>o.mutate({hostId:n.id,force:c},{onSuccess:()=>{r(!1),i?.(n)}}),children:c?`Remove anyway`:`Remove machine`})})]}),t[5]=c,t[6]=r,t[7]=i,t[8]=o,t[9]=n,t[10]=f):f=t[10];let p;return t[11]!==l||t[12]!==d||t[13]!==f?(p=(0,B.jsx)(u,{open:l,onOpenChange:d,children:f}),t[11]=l,t[12]=d,t[13]=f,t[14]=p):p=t[14],p}function q(e,t){return t?.supportsSuspend&&e.lifecycle.phase===`active`?{icon:`Pause`,label:`Suspend`,kind:`suspend`}:t?.supportsSuspend&&e.lifecycle.phase===`suspended`?{icon:`Play`,label:`Resume`,kind:`resume`}:e.lifecycle.phase===`removing`&&e.lifecycle.teardown?.status===`failed`?{icon:`RotateCcw`,label:`Retry cleanup`,kind:`retry-cleanup`}:null}function J(e){let t=(0,P.c)(10),{host:n,machineProvider:r,pending:i,onSuspend:a,onResume:o,onRetryCleanup:s}=e,c;t[0]!==n||t[1]!==r?(c=q(n,r),t[0]=n,t[1]=r,t[2]=c):c=t[2];let l=c;if(l===null)return null;let u=l.kind===`suspend`?a:l.kind===`resume`?o:s,f;t[3]===l.icon?f=t[4]:(f=(0,B.jsx)(d,{name:l.icon,className:`size-3.5`,"aria-hidden":!0}),t[3]=l.icon,t[4]=f);let p;return t[5]!==l.label||t[6]!==u||t[7]!==i||t[8]!==f?(p=(0,B.jsxs)(S,{type:`button`,variant:`outline`,size:`sm`,disabled:i,onClick:u,children:[f,l.label]}),t[5]=l.label,t[6]=u,t[7]=i,t[8]=f,t[9]=p):p=t[9],p}function Y(e){let t=[{id:`rename`,label:`Rename`,icon:`Edit`,onSelect:e.onRename}];R(e.host)&&t.push({id:`reconnect`,label:`Reconnect`,icon:`RotateCcw`,onSelect:e.onReconnect});let n=e.onRetryUpdate;n!==void 0&&o(e.host)&&t.push({id:`retry-update`,label:e.retryUpdatePending??!1?`Retrying update…`:`Retry update`,icon:j,disabled:e.retryUpdatePending??!1,onSelect:n});let r=q(e.host,e.machineProvider),i=r===null?void 0:r.kind===`suspend`?e.onSuspend:r.kind===`resume`?e.onResume:e.onRetryCleanup;r!==null&&i!==void 0&&t.push({id:`lifecycle`,label:r.label,icon:r.icon,disabled:e.lifecycleActionPending??!1,onSelect:i}),e.canMoveServerHere&&t.push({id:`move-server`,label:`Move server here`,icon:`MoveTo`,onSelect:e.onMoveServerHere});let a=e.onRemove;return a!==void 0&&t.push({id:`remove`,label:`Remove machine`,icon:`Trash2`,tone:`destructive`,...e.isPrimary?{disabled:!0,disabledReason:H(e.serverMoveEnabled??!1)}:{},onSelect:a}),t}var X=e(n(),1);function Z(e){let t=(0,P.c)(35),{target:n,onOpenChange:r}=e,i=N(),o=n?.id??null,{mutate:s,reset:c}=i,l,u;t[0]!==o||t[1]!==s||t[2]!==c?(l=()=>{if(o===null){c();return}s(o)},u=[o,s,c],t[0]=o,t[1]=s,t[2]=c,t[3]=l,t[4]=u):(l=t[3],u=t[4]),(0,X.useEffect)(l,u);let f=i.data??null,m=n!==null&&n.status===`connected`,h;t[5]!==i.error||t[6]!==i.isError?(h=i.isError?a({error:i.error,fallbackMessage:`Couldn't prepare a reconnect command.`}):null,t[5]=i.error,t[6]=i.isError,t[7]=h):h=t[7];let v=h,x=n!==null,C;t[8]===Symbol.for(`react.memo_cache_sentinel`)?(C=(0,B.jsx)(y,{children:`Reconnect machine`}),t[8]=C):C=t[8];let T=v===null?void 0:`text-destructive-text`,E=v??`Run this command on ${n?.name??`the machine`} to bring it back online. It keeps the machine's projects, environments and history.`,D;t[9]!==T||t[10]!==E?(D=(0,B.jsxs)(b,{children:[C,(0,B.jsx)(w,{className:T,children:E})]}),t[9]=T,t[10]=E,t[11]=D):D=t[11];let O;t[12]!==v||t[13]!==o||t[14]!==s?(O=v===null?null:(0,B.jsx)(`div`,{className:`flex justify-end`,children:(0,B.jsx)(S,{variant:`outline`,size:`sm`,onClick:()=>{o!==null&&s(o)},children:`Try again`})}),t[12]=v,t[13]=o,t[14]=s,t[15]=O):O=t[15];let A;t[16]!==o||t[17]!==s||t[18]!==f?(A=f===null?null:(0,B.jsx)(k,{command:f.command,windowsCommand:f.windowsCommand,expiresAt:f.expiresAt,onRegenerate:()=>{o!==null&&s(o)}},f.command),t[16]=o,t[17]=s,t[18]=f,t[19]=A):A=t[19];let j;t[20]!==v||t[21]!==r||t[22]!==f||t[23]!==m||t[24]!==n?.name?(j=v===null?(0,B.jsx)(`div`,{className:`flex items-center gap-2.5 rounded-md bg-muted/40 px-3 py-2.5`,children:m?(0,B.jsxs)(B.Fragment,{children:[(0,B.jsx)(p,{connected:!0}),(0,B.jsxs)(`span`,{role:`status`,className:`min-w-0 flex-1 truncate text-sm text-foreground`,children:[n?.name,` reconnected`]}),(0,B.jsx)(S,{size:`sm`,variant:`ghost`,className:`h-7 shrink-0 px-2 text-xs`,onClick:()=>r(!1),children:`Done`})]}):(0,B.jsxs)(B.Fragment,{children:[(0,B.jsx)(d,{name:`Spinner`,className:`size-4 shrink-0 animate-spin text-muted-foreground`}),(0,B.jsx)(`span`,{role:`status`,className:`text-sm text-muted-foreground`,children:f===null?`Preparing a reconnect command…`:`Waiting for the machine to reconnect…`})]})}):null,t[20]=v,t[21]=r,t[22]=f,t[23]=m,t[24]=n?.name,t[25]=j):j=t[25];let M;t[26]!==A||t[27]!==j||t[28]!==D||t[29]!==O?(M=(0,B.jsxs)(_,{className:`max-h-[calc(100dvh-2rem)] overflow-y-auto`,onInteractOutside:Q,children:[D,O,A,j]}),t[26]=A,t[27]=j,t[28]=D,t[29]=O,t[30]=M):M=t[30];let F;return t[31]!==r||t[32]!==M||t[33]!==x?(F=(0,B.jsx)(g,{open:x,onOpenChange:r,children:M}),t[31]=r,t[32]=M,t[33]=x,t[34]=F):F=t[34],F}function Q(e){return e.preventDefault()}var $={blocker:{heading:`Fix before moving`,icon:`AlertCircle`,iconClassName:`text-destructive-text`},warning:{heading:`Before you move`,icon:`AlertTriangle`,iconClassName:`text-warning-text`},info:{heading:`Good to know`,icon:`Info`,iconClassName:`text-muted-foreground`}};function ee(e){let t=(0,P.c)(17),{target:n,onOpenChange:r}=e,i=s(),a;t[0]!==r||t[1]!==i?(a=()=>{i.isPending||(i.reset(),r(!1))},t[0]=r,t[1]=i,t[2]=a):a=t[2];let o=a,c=n!==null,l;t[3]===o?l=t[4]:(l=e=>{e||o()},t[3]=o,t[4]=l);let u;t[5]!==o||t[6]!==r||t[7]!==i||t[8]!==n?(u=n===null?null:(0,B.jsx)(te,{target:n,startMove:i,onCancel:o,onStarted:()=>r(!1)},n.id),t[5]=o,t[6]=r,t[7]=i,t[8]=n,t[9]=u):u=t[9];let d;t[10]!==i.isPending||t[11]!==u?(d=(0,B.jsx)(_,{className:`max-h-[calc(100dvh-2rem)] overflow-y-auto`,hideCloseButton:i.isPending,children:u}),t[10]=i.isPending,t[11]=u,t[12]=d):d=t[12];let f;return t[13]!==c||t[14]!==l||t[15]!==d?(f=(0,B.jsx)(g,{open:c,onOpenChange:l,children:d}),t[13]=c,t[14]=l,t[15]=d,t[16]=f):f=t[16],f}function te(e){let t=(0,P.c)(48),{target:n,startMove:r,onCancel:i,onStarted:o}=e,s=D(),[c,l]=(0,X.useState)(null),[u,d]=(0,X.useState)(null),[f,p]=(0,X.useState)(``),[m,g]=(0,X.useState)(!1),_=s.mutate,v=n.id,y,b;t[0]!==_||t[1]!==v?(y=()=>{_({targetHostId:v,serverUrl:null},{onSuccess:e=>{l(e),d(null),e.requiresServerUrl&&e.serverUrl!==null&&p(e.serverUrl)}})},b=[_,v],t[0]=_,t[1]=v,t[2]=y,t[3]=b):(y=t[2],b=t[3]),(0,X.useEffect)(y,b);let x=c?.requiresServerUrl===!0||u!==null,S;t[4]!==f||t[5]!==s||t[6]!==c?.existingTargetServerData?.path||t[7]!==x||t[8]!==r||t[9]!==v?(S=()=>{let e=f.trim(),t=x&&e.length>0?e:null;r.reset(),s.mutate({targetHostId:v,serverUrl:t},{onSuccess:e=>{e.existingTargetServerData?.path!==c?.existingTargetServerData?.path&&g(!1),l(e),d(t)}})},t[4]=f,t[5]=s,t[6]=c?.existingTargetServerData?.path,t[7]=x,t[8]=r,t[9]=v,t[10]=S):S=t[10];let C=S,w;t[11]!==f||t[12]!==m||t[13]!==s.isPending||t[14]!==u||t[15]!==c||t[16]!==x||t[17]!==r.isPending?(w=h({result:c,checking:s.isPending,starting:r.isPending,showAddress:x,addressDraft:f,checkedServerUrl:u,archiveConfirmed:m}),t[11]=f,t[12]=m,t[13]=s.isPending,t[14]=u,t[15]=c,t[16]=x,t[17]=r.isPending,t[18]=w):w=t[18];let T=w,E;t[19]!==m||t[20]!==u||t[21]!==o||t[22]!==c||t[23]!==T||t[24]!==r||t[25]!==v?(E=()=>{c===null||!T||r.mutate({targetHostId:v,serverUrl:u,stopRunningWork:!0,archiveExistingTargetServerData:c.existingTargetServerData!==null&&m},{onSuccess:o,onError:e=>{let t=O(e);t!==null&&l({...c,items:t,canMove:!1})}})},t[19]=m,t[20]=u,t[21]=o,t[22]=c,t[23]=T,t[24]=r,t[25]=v,t[26]=E):E=t[26];let k=E,A;t[27]!==s.error||t[28]!==s.isError||t[29]!==n.name?(A=s.isError?a({error:s.error,fallbackMessage:`Couldn't check ${n.name}.`}):null,t[27]=s.error,t[28]=s.isError,t[29]=n.name,t[30]=A):A=t[30];let j;t[31]!==r.error||t[32]!==r.isError?(j=r.isError?a({error:r.error,fallbackMessage:`Couldn't start the move.`}):null,t[31]=r.error,t[32]=r.isError,t[33]=j):j=t[33];let M;return t[34]!==f||t[35]!==m||t[36]!==C||t[37]!==s.isPending||t[38]!==i||t[39]!==c||t[40]!==x||t[41]!==k||t[42]!==T||t[43]!==r.isPending||t[44]!==A||t[45]!==j||t[46]!==n.name?(M=(0,B.jsx)(ne,{targetName:n.name,result:c,checking:s.isPending,checkError:A,showAddress:x,addressDraft:f,archiveConfirmed:m,startAllowed:T,starting:r.isPending,startError:j,onAddressDraftChange:p,onCheck:C,onArchiveConfirmedChange:g,onStart:k,onCancel:i}),t[34]=f,t[35]=m,t[36]=C,t[37]=s.isPending,t[38]=i,t[39]=c,t[40]=x,t[41]=k,t[42]=T,t[43]=r.isPending,t[44]=A,t[45]=j,t[46]=n.name,t[47]=M):M=t[47],M}function ne(e){let t=(0,P.c)(53),{targetName:n,result:r,checking:i,checkError:a,showAddress:o,addressDraft:s,archiveConfirmed:c,startAllowed:l,starting:u,startError:f,onAddressDraftChange:p,onCheck:m,onArchiveConfirmedChange:h,onStart:g,onCancel:_}=e,v;t[0]===r?.items?v=t[1]:(v=r?.items.some(re)??!1,t[0]=r?.items,t[1]=v);let C=!i&&(a!==null||v)&&!o,T;t[2]===n?T=t[3]:(T=(0,B.jsxs)(b,{children:[(0,B.jsxs)(y,{children:[`Move the server to `,n]}),(0,B.jsxs)(w,{children:[`Your threads, settings and plugin data move to `,n,`. Every machine and app switches over when it's done, and the current server machine keeps running as a regular machine.`]})]}),t[2]=n,t[3]=T);let E;t[4]!==a||t[5]!==r||t[6]!==n?(E=r===null&&a===null?(0,B.jsxs)(`div`,{className:`flex items-center gap-2.5 rounded-md bg-muted/40 px-3 py-2.5`,children:[(0,B.jsx)(d,{name:`Spinner`,className:`size-4 shrink-0 animate-spin text-muted-foreground`}),(0,B.jsxs)(`span`,{role:`status`,className:`text-sm text-muted-foreground`,children:[`Checking `,n,`…`]})]}):null,t[4]=a,t[5]=r,t[6]=n,t[7]=E):E=t[7];let D;t[8]!==s||t[9]!==i||t[10]!==p||t[11]!==m||t[12]!==o||t[13]!==u||t[14]!==n?(D=o?(0,B.jsx)(ie,{targetName:n,value:s,checking:i,disabled:u,onChange:p,onCheck:m}):null,t[8]=s,t[9]=i,t[10]=p,t[11]=m,t[12]=o,t[13]=u,t[14]=n,t[15]=D):D=t[15];let O;t[16]===a?O=t[17]:(O=a===null?null:(0,B.jsx)(`p`,{role:`alert`,className:`text-sm text-destructive-text`,children:a}),t[16]=a,t[17]=O);let k;t[18]!==i||t[19]!==r?(k=r===null?null:(0,B.jsx)(ae,{items:r.items,dimmed:i}),t[18]=i,t[19]=r,t[20]=k):k=t[20];let A;t[21]!==c||t[22]!==h||t[23]!==r||t[24]!==u?(A=r?.existingTargetServerData?(0,B.jsx)(oe,{path:r.existingTargetServerData.path,sizeBytes:r.existingTargetServerData.sizeBytes,checked:c,disabled:u,onCheckedChange:h}):null,t[21]=c,t[22]=h,t[23]=r,t[24]=u,t[25]=A):A=t[25];let j;t[26]===f?j=t[27]:(j=f===null?null:(0,B.jsx)(`p`,{role:`alert`,className:`text-sm text-destructive-text`,children:f}),t[26]=f,t[27]=j);let M;t[28]===Symbol.for(`react.memo_cache_sentinel`)?(M=(0,B.jsx)(`p`,{className:`text-xs text-subtle-foreground`,children:`Moving stops every running turn and pauses scheduled automations.`}),t[28]=M):M=t[28];let N;t[29]!==_||t[30]!==u?(N=(0,B.jsx)(S,{type:`button`,variant:`outline`,disabled:u,onClick:_,children:`Cancel`}),t[29]=_,t[30]=u,t[31]=N):N=t[31];let F;t[32]!==m||t[33]!==C||t[34]!==u?(F=C?(0,B.jsx)(S,{type:`button`,variant:`outline`,disabled:u,onClick:m,children:`Check again`}):null,t[32]=m,t[33]=C,t[34]=u,t[35]=F):F=t[35];let I=!l,L=u?`Starting…`:`Stop all and move`,R;t[36]!==g||t[37]!==I||t[38]!==L?(R=(0,B.jsx)(S,{type:`button`,disabled:I,onClick:g,children:L}),t[36]=g,t[37]=I,t[38]=L,t[39]=R):R=t[39];let z;t[40]!==N||t[41]!==F||t[42]!==R?(z=(0,B.jsxs)(x,{children:[N,F,R]}),t[40]=N,t[41]=F,t[42]=R,t[43]=z):z=t[43];let V;return t[44]!==z||t[45]!==T||t[46]!==E||t[47]!==D||t[48]!==O||t[49]!==k||t[50]!==A||t[51]!==j?(V=(0,B.jsxs)(B.Fragment,{children:[T,E,D,O,k,A,j,M,z]}),t[44]=z,t[45]=T,t[46]=E,t[47]=D,t[48]=O,t[49]=k,t[50]=A,t[51]=j,t[52]=V):V=t[52],V}function re(e){return e.severity===`blocker`}function ie(e){let t=(0,P.c)(32),{targetName:n,value:r,checking:i,disabled:a,onChange:o,onCheck:s}=e,c=(0,X.useId)(),l=(0,X.useId)(),u;t[0]!==i||t[1]!==a||t[2]!==r?(u=!i&&!a&&r.trim().length>0,t[0]=i,t[1]=a,t[2]=r,t[3]=u):u=t[3];let d=u,f;t[4]===c?f=t[5]:(f=(0,B.jsx)(`label`,{htmlFor:c,className:`block text-sm font-medium text-foreground`,children:`New server address`}),t[4]=c,t[5]=f);let p;t[6]!==l||t[7]!==n?(p=(0,B.jsxs)(`p`,{id:l,className:`text-xs text-subtle-foreground`,children:[`Machines and apps use this address to reach the server on `,n,` `,`after the move.`]}),t[6]=l,t[7]=n,t[8]=p):p=t[8];let m;t[9]===o?m=t[10]:(m=e=>o(e.target.value),t[9]=o,t[10]=m);let h;t[11]!==d||t[12]!==s?(h=e=>{e.key===`Enter`&&(e.preventDefault(),d&&s())},t[11]=d,t[12]=s,t[13]=h):h=t[13];let g;t[14]!==a||t[15]!==l||t[16]!==c||t[17]!==m||t[18]!==h||t[19]!==r?(g=(0,B.jsx)(T,{id:c,"aria-describedby":l,className:`min-w-0 flex-1`,value:r,placeholder:`https://bb.example.com`,inputMode:`url`,autoCapitalize:`off`,autoCorrect:`off`,spellCheck:!1,disabled:a,onChange:m,onKeyDown:h}),t[14]=a,t[15]=l,t[16]=c,t[17]=m,t[18]=h,t[19]=r,t[20]=g):g=t[20];let _=!d,v=i?`Checking…`:`Check address`,y;t[21]!==s||t[22]!==_||t[23]!==v?(y=(0,B.jsx)(S,{type:`button`,variant:`outline`,disabled:_,onClick:s,children:v}),t[21]=s,t[22]=_,t[23]=v,t[24]=y):y=t[24];let b;t[25]!==g||t[26]!==y?(b=(0,B.jsxs)(`div`,{className:`flex min-w-0 items-center gap-2`,children:[g,y]}),t[25]=g,t[26]=y,t[27]=b):b=t[27];let x;return t[28]!==b||t[29]!==f||t[30]!==p?(x=(0,B.jsxs)(`div`,{className:`space-y-2`,children:[f,p,b]}),t[28]=b,t[29]=f,t[30]=p,t[31]=x):x=t[31],x}function ae(e){let t=(0,P.c)(11),{items:n,dimmed:r}=e,i,a,o;if(t[0]!==r||t[1]!==n){o=Symbol.for(`react.early_return_sentinel`);bb0:{let e=E(n);if(n.length===0){let e;t[5]===Symbol.for(`react.memo_cache_sentinel`)?(e=(0,B.jsx)(`p`,{className:`text-sm text-muted-foreground`,children:`Nothing needs attention before the move.`}),t[5]=e):e=t[5],o=e;break bb0}let s=r&&`opacity-60`;t[6]===s?i=t[7]:(i=C(`space-y-3 transition-opacity`,s),t[6]=s,t[7]=i),a=v.map(t=>{let n=e[t];if(n.length===0)return null;let r=$[t];return(0,B.jsxs)(`section`,{"aria-label":r.heading,className:`space-y-1.5`,children:[(0,B.jsx)(`h3`,{className:`text-xs font-medium text-muted-foreground`,children:r.heading}),(0,B.jsx)(`ul`,{className:`space-y-2`,children:n.map(e=>(0,B.jsxs)(`li`,{"data-severity":t,className:`flex items-start gap-2.5`,children:[(0,B.jsx)(d,{name:r.icon,"aria-hidden":!0,className:C(`mt-0.5 size-4 shrink-0`,r.iconClassName)}),(0,B.jsxs)(`div`,{className:`min-w-0 flex-1`,children:[(0,B.jsx)(`p`,{className:`text-sm break-words text-foreground`,children:e.title}),e.detail===null?null:(0,B.jsx)(`p`,{className:`text-xs break-words text-subtle-foreground`,children:e.detail})]})]},e.id))})]},t)})}t[0]=r,t[1]=n,t[2]=i,t[3]=a,t[4]=o}else i=t[2],a=t[3],o=t[4];if(o!==Symbol.for(`react.early_return_sentinel`))return o;let s;return t[8]!==i||t[9]!==a?(s=(0,B.jsx)(`div`,{className:i,children:a}),t[8]=i,t[9]=a,t[10]=s):s=t[10],s}function oe(e){let t=(0,P.c)(18),{path:n,sizeBytes:r,checked:i,disabled:a,onCheckedChange:o}=e,s;t[0]===o?s=t[1]:(s=e=>o(e===!0),t[0]=o,t[1]=s);let c;t[2]!==i||t[3]!==a||t[4]!==s?(c=(0,B.jsx)(A,{className:`mt-0.5`,checked:i,disabled:a,onCheckedChange:s}),t[2]=i,t[3]=a,t[4]=s,t[5]=c):c=t[5];let u;t[6]===n?u=t[7]:(u=(0,B.jsxs)(`span`,{className:`block text-sm break-words text-foreground`,children:[`Archive the existing bb data at `,n]}),t[6]=n,t[7]=u);let d;t[8]===r?d=t[9]:(d=l(r),t[8]=r,t[9]=d);let f;t[10]===d?f=t[11]:(f=(0,B.jsxs)(`span`,{className:`block text-xs text-subtle-foreground`,children:[d,`. bb renames it to a backup folder next to it and never merges it.`]}),t[10]=d,t[11]=f);let p;t[12]!==u||t[13]!==f?(p=(0,B.jsxs)(`span`,{className:`min-w-0 flex-1`,children:[u,f]}),t[12]=u,t[13]=f,t[14]=p):p=t[14];let m;return t[15]!==c||t[16]!==p?(m=(0,B.jsxs)(`label`,{className:`flex items-start gap-2.5 rounded-md border border-border px-3 py-2.5`,children:[c,p]}),t[15]=c,t[16]=p,t[17]=m):m=t[17],m}var se=100;function ce(e){let t=(0,P.c)(9),{target:n,pending:r,errorMessage:i,onOpenChange:a,onRename:o}=e,s=n!==null,l;t[0]!==i||t[1]!==o||t[2]!==r||t[3]!==n?(l=e=>n?(0,B.jsx)(le,{target:n,pending:r,errorMessage:i,onRename:o,inputRef:e},n.id):null,t[0]=i,t[1]=o,t[2]=r,t[3]=n,t[4]=l):l=t[4];let u;return t[5]!==a||t[6]!==s||t[7]!==l?(u=(0,B.jsx)(c,{open:s,onOpenChange:a,children:l}),t[5]=a,t[6]=s,t[7]=l,t[8]=u):u=t[8],u}function le(e){let t=(0,P.c)(30),{target:n,pending:r,errorMessage:i,onRename:a,inputRef:o}=e,[s,c]=(0,X.useState)(n.name),l;t[0]!==s||t[1]!==a||t[2]!==r||t[3]!==n?(l=e=>{if(e.preventDefault(),r)return;let t=s.trim();t.length!==0&&a(n,t)},t[0]=s,t[1]=a,t[2]=r,t[3]=n,t[4]=l):l=t[4];let u=l,d;t[5]===Symbol.for(`react.memo_cache_sentinel`)?(d=(0,B.jsx)(y,{children:`Rename machine`}),t[5]=d):d=t[5];let f;t[6]===n.name?f=t[7]:(f=(0,B.jsxs)(b,{children:[d,(0,B.jsxs)(w,{children:[`Choose a new name for `,n.name,`.`]})]}),t[6]=n.name,t[7]=f);let p;t[8]===Symbol.for(`react.memo_cache_sentinel`)?(p=e=>c(e.target.value),t[8]=p):p=t[8];let m;t[9]!==o||t[10]!==s||t[11]!==r?(m=(0,B.jsx)(T,{ref:o,"aria-label":`Machine name`,value:s,maxLength:se,autoCorrect:`off`,spellCheck:!1,disabled:r,onChange:p}),t[9]=o,t[10]=s,t[11]=r,t[12]=m):m=t[12];let h;t[13]===i?h=t[14]:(h=i===null?null:(0,B.jsx)(`p`,{className:`text-sm text-destructive`,children:i}),t[13]=i,t[14]=h);let g;t[15]!==m||t[16]!==h?(g=(0,B.jsxs)(`div`,{className:`space-y-2`,children:[m,h]}),t[15]=m,t[16]=h,t[17]=g):g=t[17];let _;t[18]!==s||t[19]!==r?(_=r||s.trim().length===0,t[18]=s,t[19]=r,t[20]=_):_=t[20];let v;t[21]===_?v=t[22]:(v=(0,B.jsx)(x,{children:(0,B.jsx)(S,{type:`submit`,disabled:_,children:`Rename machine`})}),t[21]=_,t[22]=v);let C;t[23]!==u||t[24]!==g||t[25]!==v?(C=(0,B.jsxs)(`form`,{className:`space-y-4`,onSubmit:u,children:[g,v]}),t[23]=u,t[24]=g,t[25]=v,t[26]=C):C=t[26];let E;return t[27]!==C||t[28]!==f?(E=(0,B.jsxs)(B.Fragment,{children:[f,C]}),t[27]=C,t[28]=f,t[29]=E):E=t[29],E}export{J as a,H as c,Y as i,L as l,ee as n,K as o,Z as r,U as s,ce as t,I as u};
|
|
Binary file
|
|
Binary file
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{o as e}from"./rolldown-runtime-BM3Ffeng.js";import{Ar as t,Or as n,Vr as r,mi as i,ni as a,zr as o}from"./boot-vendor-BBLG7GwQ.js";import{t as s}from"./permission-mode-options-BrNWKCMS.js";import{Bo as c,C as l,Ct as u,Dr as d,Ft as f,Ho as p,Lr as m,Po as h,Qm as ee,Sa as g,St as _,T as v,Tc as y,Ui as te,Vi as ne,Ym as b,_ as x,_t as S,fi as C,go as w,ho as T,mo as E,nh as D,nm as re,oh as O,po as k,tm as A,vt as j,xt as ie,zo as M}from"./index-BBxUiLNy.js";import{B as N,I as ae,L as P,R as F,b as oe,z as se}from"./resource-list-B6MkAu8v.js";import{r as ce,t as le}from"./machine-provider-queries-CRlWTEz7.js";import{t as ue}from"./page-shell-BHTOdeQn.js";import{a as de,c as fe,i as pe,o as me,r as he,s as ge}from"./host-mutations-Ckc-eVys.js";import{a as _e,c as ve,i as ye,l as be,n as xe,o as Se,r as Ce,s as we,t as Te,u as Ee}from"./MachineRenameDialog-C_ZV5gEB.js";var I=n(),L=e(a(),1);function De(e){let t=(0,I.c)(5),{notice:n}=e;if(n===null||n.message===null)return null;let r=n.phase===`suspending`||n.phase===`resuming`?`text-subtle-foreground`:`text-destructive-text`,i;t[0]===r?i=t[1]:(i=O(`min-w-0 text-xs`,r),t[0]=r,t[1]=i);let a;return t[2]!==n.message||t[3]!==i?(a=(0,L.jsx)(`p`,{role:`status`,"aria-label":`Machine maintenance`,className:i,children:n.message}),t[2]=n.message,t[3]=i,t[4]=a):a=t[4],a}var Oe=e(i(),1);function ke(e,t){return t!==null&&t.fromHostId===e.id&&t.oldCopyDeletedAt===null}function Ae(e,t){let n=`The server moved from ${e.name} to ${t.toHostName}. The old server data is still on ${e.name}, locked so bb won't start a server from it. Keep it as a backup, or delete it once the new server works.`;return e.status===`connected`?n:`${n} ${e.name} has to be online to delete it.`}function je(e){let t=(0,I.c)(33),{host:n,lastMove:r}=e,i=v(),[a,o]=(0,Oe.useState)(!1),s;t[0]===i?s=t[1]:(s=()=>{i.reset(),o(!0)},t[0]=i,t[1]=s);let l;t[2]!==n||t[3]!==r||t[4]!==s?(l=(0,L.jsx)(R,{host:n,lastMove:r,onDelete:s}),t[2]=n,t[3]=r,t[4]=s,t[5]=l):l=t[5];let u;t[6]===i?u=t[7]:(u=e=>{!e&&!i.isPending&&(i.reset(),o(!1))},t[6]=i,t[7]=u);let d;t[8]===Symbol.for(`react.memo_cache_sentinel`)?(d=(0,L.jsx)(w,{children:`Delete the old server copy?`}),t[8]=d):d=t[8];let f;t[9]!==n.name||t[10]!==r.toHostName?(f=(0,L.jsxs)(T,{children:[d,(0,L.jsxs)(k,{children:[`This permanently deletes the database, settings and plugin data`,` `,n.name,` kept when the server moved to `,r.toHostName,`. The server on `,r.toHostName,` is not affected.`]})]}),t[9]=n.name,t[10]=r.toHostName,t[11]=f):f=t[11];let p;t[12]!==i.error||t[13]!==i.isError||t[14]!==n.name?(p=i.isError?(0,L.jsx)(`p`,{className:`text-sm text-destructive-text`,role:`alert`,children:c({error:i.error,fallbackMessage:`Couldn't delete the old server copy on ${n.name}.`})}):null,t[12]=i.error,t[13]=i.isError,t[14]=n.name,t[15]=p):p=t[15];let h;t[16]!==i||t[17]!==n.id||t[18]!==n.name?(h=()=>i.mutate(n.id,{onSuccess:e=>{o(!1),b.success(e.deleted?`Deleted the old server copy on ${n.name}`:`No old server copy was left on ${n.name}`)}}),t[16]=i,t[17]=n.id,t[18]=n.name,t[19]=h):h=t[19];let ee=i.isPending?`Deleting…`:`Delete old copy`,g;t[20]!==i.isPending||t[21]!==h||t[22]!==ee?(g=(0,L.jsx)(E,{children:(0,L.jsx)(D,{type:`button`,variant:`destructive`,disabled:i.isPending,onClick:h,children:ee})}),t[20]=i.isPending,t[21]=h,t[22]=ee,t[23]=g):g=t[23];let _;t[24]!==a||t[25]!==u||t[26]!==f||t[27]!==p||t[28]!==g?(_=(0,L.jsxs)(m,{modal:!1,open:a,onOpenChange:u,children:[f,p,g]}),t[24]=a,t[25]=u,t[26]=f,t[27]=p,t[28]=g,t[29]=_):_=t[29];let y;return t[30]!==_||t[31]!==l?(y=(0,L.jsxs)(L.Fragment,{children:[l,_]}),t[30]=_,t[31]=l,t[32]=y):y=t[32],y}function R(e){let t=(0,I.c)(9),{host:n,lastMove:r,onDelete:i}=e,a;t[0]!==n||t[1]!==r?(a=Ae(n,r),t[0]=n,t[1]=r,t[2]=a):a=t[2];let o=n.status!==`connected`,s;t[3]!==i||t[4]!==o?(s=(0,L.jsx)(se,{children:(0,L.jsx)(F,{children:(0,L.jsx)(D,{type:`button`,variant:`destructive`,size:`sm`,disabled:o,onClick:i,children:`Delete old copy`})})}),t[3]=i,t[4]=o,t[5]=s):s=t[5];let c;return t[6]!==a||t[7]!==s?(c=(0,L.jsx)(N,{title:`Old server copy`,description:a,children:s}),t[6]=a,t[7]=s,t[8]=c):c=t[8],c}var Me=`Highest permission mode any thread on the selected machine may run with. Threads that ask for more resolve down to it, and a provider that supports nothing this low can't run here.`,Ne={darwin:`macOS`,linux:`Linux`,wsl:`WSL`,win32:`Windows`,unknown:null};function z({host:e,platformLabel:t,now:n}){let r=[be({host:e,now:n})];return t!==null&&r.push(t),r.push(`paired ${g({timestamp:e.createdAt,now:n})}`),r.join(` · `)}function Pe(e){let t=(0,I.c)(6),{disabled:n,onSelect:r,value:i}=e,a;t[0]!==n||t[1]!==r||t[2]!==i?(a=s.map(e=>{let t=e.value===i;return(0,L.jsx)(F,{className:`items-start`,children:(0,L.jsxs)(`button`,{type:`button`,role:`radio`,"aria-checked":t,disabled:n,onClick:()=>{t||r(e.value)},className:O(`flex w-full items-start gap-3 rounded-md text-left outline-none focus-visible:ring-2 focus-visible:ring-ring`,n&&`opacity-70`),children:[(0,L.jsx)(`span`,{className:O(`mt-0.5 flex size-4 shrink-0 items-center justify-center rounded-full border`,t?`border-foreground`:`border-input`),children:t?(0,L.jsx)(`span`,{className:`size-2 rounded-full bg-foreground`}):null}),(0,L.jsxs)(`span`,{className:`min-w-0 flex-1`,children:[(0,L.jsx)(`span`,{className:`block text-sm text-foreground`,children:e.label}),e.description?(0,L.jsx)(`span`,{className:`mt-0.5 block text-xs leading-snug text-subtle-foreground/75`,children:e.description}):null]})]})},e.value)}),t[0]=n,t[1]=r,t[2]=i,t[3]=a):a=t[3];let o;return t[4]===a?o=t[5]:(o=(0,L.jsx)(`div`,{role:`radiogroup`,"aria-label":`Permission limit`,children:(0,L.jsx)(se,{children:a})}),t[4]=a,t[5]=o),o}function Fe(e){let n=(0,I.c)(57),{host:r,machineProvider:i,platformLabel:a,now:o,isPrimary:s,isThisMachine:c,showServerBadge:l,lifecycleNotice:u,lifecycleActionPending:d,onSuspend:f,onResume:p,onRetryCleanup:m,onRename:h,onReconnect:g,canMoveServerHere:_,onMoveServerHere:v}=e,y;n[0]===Symbol.for(`react.memo_cache_sentinel`)?(y=re(`machines`),n[0]=y):y=n[0];let ne;n[1]===Symbol.for(`react.memo_cache_sentinel`)?(ne=(0,L.jsxs)(t,{to:y,className:`inline-flex items-center gap-1 text-sm text-muted-foreground hover:text-foreground`,children:[(0,L.jsx)(ee,{name:`ChevronLeft`,className:`size-3.5`}),`Machines`]}),n[1]=ne):ne=n[1];let b;n[2]!==r||n[3]!==i?(b=(0,L.jsx)(`h1`,{className:`min-w-0 text-sm font-semibold text-foreground`,children:(0,L.jsx)(ce,{host:r,machineProvider:i})}),n[2]=r,n[3]=i,n[4]=b):b=n[4];let x;n[5]===c?x=n[6]:(x=c?(0,L.jsx)(ae,{children:`This machine`}):null,n[5]=c,n[6]=x);let S;n[7]===l?S=n[8]:(S=l?(0,L.jsx)(ae,{children:`Server`}):null,n[7]=l,n[8]=S);let C;n[9]!==b||n[10]!==x||n[11]!==S?(C=(0,L.jsxs)(`div`,{className:`flex min-w-0 items-center gap-2`,children:[b,x,S]}),n[9]=b,n[10]=x,n[11]=S,n[12]=C):C=n[12];let w;n[13]===r?w=n[14]:(w=Ee(r),n[13]=r,n[14]=w);let T;n[15]===w?T=n[16]:(T=(0,L.jsx)(te,{tone:w}),n[15]=w,n[16]=T);let E;n[17]!==r||n[18]!==o||n[19]!==a?(E=z({host:r,platformLabel:a,now:o}),n[17]=r,n[18]=o,n[19]=a,n[20]=E):E=n[20];let D;n[21]===E?D=n[22]:(D=(0,L.jsx)(`p`,{className:`min-w-0 text-xs text-subtle-foreground/75`,children:E}),n[21]=E,n[22]=D);let O;n[23]!==D||n[24]!==T?(O=(0,L.jsxs)(`div`,{className:`flex min-w-0 items-center gap-2`,children:[T,D]}),n[23]=D,n[24]=T,n[25]=O):O=n[25];let k;n[26]===u?k=n[27]:(k=(0,L.jsx)(De,{notice:u}),n[26]=u,n[27]=k);let A;n[28]!==O||n[29]!==k||n[30]!==C?(A=(0,L.jsxs)(`div`,{className:`min-w-0 space-y-1`,children:[C,O,k]}),n[28]=O,n[29]=k,n[30]=C,n[31]=A):A=n[31];let j;n[32]!==r||n[33]!==d||n[34]!==i||n[35]!==p||n[36]!==m||n[37]!==f?(j=(0,L.jsx)(_e,{host:r,machineProvider:i,pending:d,onSuspend:f,onResume:p,onRetryCleanup:m}),n[32]=r,n[33]=d,n[34]=i,n[35]=p,n[36]=m,n[37]=f,n[38]=j):j=n[38];let ie=`${r.name} actions`,M;n[39]!==_||n[40]!==r||n[41]!==s||n[42]!==d||n[43]!==i||n[44]!==v||n[45]!==g||n[46]!==h?(M=ye({host:r,machineProvider:i,isPrimary:s,canMoveServerHere:_,lifecycleActionPending:d,onRename:h,onReconnect:g,onMoveServerHere:v}),n[39]=_,n[40]=r,n[41]=s,n[42]=d,n[43]=i,n[44]=v,n[45]=g,n[46]=h,n[47]=M):M=n[47];let N;n[48]!==ie||n[49]!==M?(N=(0,L.jsx)(oe,{label:ie,items:M}),n[48]=ie,n[49]=M,n[50]=N):N=n[50];let P;n[51]!==j||n[52]!==N?(P=(0,L.jsxs)(`div`,{className:`flex shrink-0 items-center gap-2`,children:[j,N]}),n[51]=j,n[52]=N,n[53]=P):P=n[53];let F;return n[54]!==A||n[55]!==P?(F=(0,L.jsxs)(`div`,{className:`space-y-3`,children:[ne,(0,L.jsxs)(`div`,{className:`flex min-w-0 items-start justify-between gap-3`,children:[A,P]})]}),n[54]=A,n[55]=P,n[56]=F):F=n[56],F}function Ie(){let e=(0,I.c)(117),{hostId:n}=r(),i=o(),a=ne(),{providers:s}=le(),m=h(),{localDaemonHostId:g,platform:v}=C(),te=y(),S=ie(),w=he(),T=me(),E=ge(),O=pe(),k=de(),A=fe(),ae=l(),[oe,ce]=(0,Oe.useState)(!1),[_e,ye]=(0,Oe.useState)(!1),[be,Ee]=(0,Oe.useState)(!1),[De,Ae]=(0,Oe.useState)(!1),R=a.data,z=R?.find(e=>e.id===n)??null,Ie=z?.lifecycle.message??null,Ve=z===null?null:{phase:z.lifecycle.phase,message:Ie},He=m.data?.primaryHostId??null,B=m.data?.experiments.serverMove??!1,V=z!==null&&z.id===He,Ue;e[0]===R?Ue=e[1]:(Ue=R?.filter(Be).length??0,e[0]=R,e[1]=Ue);let We=Ue>1&&z!==null&&z.id===g,Ge=z?.machineProviderId===null||z?.machineProviderId===void 0?null:s?.find(e=>e.id===z.machineProviderId)??null,Ke;if(e[2]!==n||e[3]!==te.data?.projects){let t=te.data?.projects??[],r;e[5]===n?r=e[6]:(r=e=>e.sources.some(e=>e.hostId===n),e[5]=n,e[6]=r),Ke=t.filter(r).map(ze),e[2]=n,e[3]=te.data?.projects,e[4]=Ke}else Ke=e[4];let qe=Ke,H,Je;if(e[7]!==n||e[8]!==S.machines){let t;e[11]===n?t=e[12]:(t=e=>e.host.id===n,e[11]=n,e[12]=t),H=S.machines.find(t),Je=(H?.issues??[]).filter(f),e[7]=n,e[8]=S.machines,e[9]=H,e[10]=Je}else H=e[9],Je=e[10];let Ye=Je.length,Xe=M().data;H?.providerStatus;let Ze;bb0:{let t=H?.providerStatus;if(!t){let t;e[13]===Symbol.for(`react.memo_cache_sentinel`)?(t=[],e[13]=t):t=e[13],Ze=t;break bb0}let n;e[14]!==Xe||e[15]!==t?(n=Object.entries(t).flatMap(e=>{let[t,n]=e;if(!n.installed)return[];let r=Xe?.find(e=>e.id===t);return[{...n,providerId:t,provider:r,ProviderIcon:j(`agent`,t,r??null)?.icon}]}),e[14]=Xe,e[15]=t,e[16]=n):n=e[16],Ze=n}let Qe=Ze,$e;e[17]===Symbol.for(`react.memo_cache_sentinel`)?($e=Date.now(),e[17]=$e):$e=e[17];let et=$e,tt=z!==null&&z.id===g&&v!==null?Ne[v]:V&&m.data?.primaryHostPlatform?Ne[m.data.primaryHostPlatform]:null;if(R===void 0){let t;return e[18]===Symbol.for(`react.memo_cache_sentinel`)?(t=(0,L.jsx)(ue,{contentClassName:`pt-4 md:pt-5`,children:(0,L.jsx)(`div`,{className:`mx-auto w-full max-w-3xl`,children:(0,L.jsx)(`p`,{className:`text-sm text-muted-foreground`,children:`Loading…`})})}),e[18]=t):t=e[18],t}if(z===null){let n;e[19]===Symbol.for(`react.memo_cache_sentinel`)?(n=re(`machines`),e[19]=n):n=e[19];let r;return e[20]===Symbol.for(`react.memo_cache_sentinel`)?(r=(0,L.jsx)(ue,{contentClassName:`pt-4 md:pt-5`,children:(0,L.jsxs)(`div`,{className:`mx-auto w-full max-w-3xl space-y-3`,children:[(0,L.jsxs)(t,{to:n,className:`inline-flex items-center gap-1 text-sm text-muted-foreground hover:text-foreground`,children:[(0,L.jsx)(ee,{name:`ChevronLeft`,className:`size-3.5`}),`Machines`]}),(0,L.jsx)(`p`,{className:`text-sm text-muted-foreground`,children:`Machine is no longer paired.`})]})}),e[20]=r):r=e[20],r}let nt=_(z),rt=ae.data?.lastMove??null,it=ue,at=Fe,ot=E.isPending||O.isPending||k.isPending,st=()=>E.mutate(z.id),ct=()=>O.mutate(z.id),lt=()=>k.mutate(z.id),U;e[21]===w?U=e[22]:(U=()=>{w.reset(),ce(!0)},e[21]=w,e[22]=U);let ut=m.data!==void 0&&x({host:z,primaryHostId:He,move:ae.data?.move??null,serverMoveEnabled:B}),dt,ft;e[23]===Symbol.for(`react.memo_cache_sentinel`)?(dt=()=>Ae(!0),ft=()=>Ee(!0),e[23]=dt,e[24]=ft):(dt=e[23],ft=e[24]);let W;e[25]!==at||e[26]!==z||e[27]!==V||e[28]!==We||e[29]!==Ve||e[30]!==Ge||e[31]!==et||e[32]!==tt||e[33]!==lt||e[34]!==U||e[35]!==ut||e[36]!==ot||e[37]!==st||e[38]!==ct?(W=(0,L.jsx)(at,{host:z,machineProvider:Ge,platformLabel:tt,now:et,isPrimary:V,isThisMachine:We,showServerBadge:V,lifecycleNotice:Ve,lifecycleActionPending:ot,onSuspend:st,onResume:ct,onRetryCleanup:lt,onRename:U,canMoveServerHere:ut,onReconnect:dt,onMoveServerHere:ft}),e[25]=at,e[26]=z,e[27]=V,e[28]=We,e[29]=Ve,e[30]=Ge,e[31]=et,e[32]=tt,e[33]=lt,e[34]=U,e[35]=ut,e[36]=ot,e[37]=st,e[38]=ct,e[39]=W):W=e[39];let G;e[40]!==z.id||e[41]!==z.name||e[42]!==A?(G=e=>A.mutate({hostId:z.id,maxPermissionMode:e},{onError:e=>{p({error:e,fallbackMessage:`Couldn't change the permission limit for ${z.name}.`})}}),e[40]=z.id,e[41]=z.name,e[42]=A,e[43]=G):G=e[43];let K;e[44]!==z.maxPermissionMode||e[45]!==G||e[46]!==A.isPending?(K=(0,L.jsx)(N,{title:`Permission limit`,description:Me,children:(0,L.jsx)(Pe,{value:z.maxPermissionMode,disabled:A.isPending,onSelect:G})}),e[44]=z.maxPermissionMode,e[45]=G,e[46]=A.isPending,e[47]=K):K=e[47];let q;e[48]!==z.status||e[49]!==Qe||e[50]!==H?.statusError||e[51]!==H?.statusPending||e[52]!==Ye?(q=(0,L.jsx)(N,{title:`Provider CLIs`,children:(0,L.jsx)(se,{children:(0,L.jsx)(P,{label:`Installed`,children:z.status===`connected`?H?.statusPending?(0,L.jsx)(`span`,{children:`Checking…`}):H?.statusError?(0,L.jsx)(`span`,{children:`Status unavailable`}):(0,L.jsxs)(L.Fragment,{children:[Qe.length>0?(0,L.jsx)(`span`,{className:`flex min-w-0 flex-wrap items-center justify-start gap-x-3 gap-y-1 @min-[36rem]/settings:justify-end`,children:Qe.map(Re)}):(0,L.jsx)(`span`,{children:`None installed`}),Ye>0?(0,L.jsx)(t,{to:re(`updates`),className:`shrink-0 rounded outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2`,children:(0,L.jsxs)(d,{variant:`outline`,size:`sm`,className:`border-attention/50 bg-surface-attention text-warning-text transition-colors hover:border-attention hover:text-foreground`,children:[Ye,` to fix`]})}):null]}):(0,L.jsx)(`span`,{children:`Unavailable while offline`})})})}),e[48]=z.status,e[49]=Qe,e[50]=H?.statusError,e[51]=H?.statusPending,e[52]=Ye,e[53]=q):q=e[53];let J;e[54]===qe?J=e[55]:(J=(0,L.jsx)(P,{label:`Projects`,children:qe.length===0?(0,L.jsx)(`span`,{children:`None`}):(0,L.jsx)(`span`,{className:`min-w-0 truncate`,children:qe.map(Le)})}),e[54]=qe,e[55]=J);let pt=nt??`Up to date`,Y;e[56]===pt?Y=e[57]:(Y=(0,L.jsx)(`span`,{children:pt}),e[56]=pt,e[57]=Y);let X;e[58]!==z||e[59]!==T?(X=u(z)?(0,L.jsx)(D,{type:`button`,variant:`outline`,size:`sm`,className:`h-6 px-2 text-xs`,disabled:T.isPending,onClick:()=>T.mutate(z.id,{onSuccess:()=>{b.success(`Update retry requested for ${z.name}`)}}),children:T.isPending?`Retrying…`:`Retry update`}):null,e[58]=z,e[59]=T,e[60]=X):X=e[60];let Z;e[61]!==Y||e[62]!==X?(Z=(0,L.jsxs)(P,{label:`Updates`,children:[Y,X]}),e[61]=Y,e[62]=X,e[63]=Z):Z=e[63];let Q;e[64]!==J||e[65]!==Z?(Q=(0,L.jsx)(N,{title:`Machine information`,children:(0,L.jsxs)(se,{children:[J,Z]})}),e[64]=J,e[65]=Z,e[66]=Q):Q=e[66];let mt;e[67]!==z||e[68]!==rt||e[69]!==B?(mt=B&&ke(z,rt)?(0,L.jsx)(je,{host:z,lastMove:rt}):null,e[67]=z,e[68]=rt,e[69]=B,e[70]=mt):mt=e[70];let ht;e[71]!==z||e[72]!==V||e[73]!==B?(ht=V?ve(B):`Revokes ${z.name}'s access to this server. ${we(z)}`,e[71]=z,e[72]=V,e[73]=B,e[74]=ht):ht=e[74];let gt;e[75]===Symbol.for(`react.memo_cache_sentinel`)?(gt=()=>ye(!0),e[75]=gt):gt=e[75];let _t;e[76]===V?_t=e[77]:(_t=(0,L.jsx)(se,{children:(0,L.jsx)(F,{children:(0,L.jsx)(D,{type:`button`,variant:`destructive`,size:`sm`,disabled:V,onClick:gt,children:`Remove machine`})})}),e[76]=V,e[77]=_t);let vt;e[78]!==ht||e[79]!==_t?(vt=(0,L.jsx)(N,{title:`Danger zone`,description:ht,children:_t}),e[78]=ht,e[79]=_t,e[80]=vt):vt=e[80];let yt;e[81]!==W||e[82]!==K||e[83]!==q||e[84]!==Q||e[85]!==mt||e[86]!==vt?(yt=(0,L.jsxs)(`div`,{className:`mx-auto w-full max-w-3xl space-y-6 pb-10`,children:[W,K,q,Q,mt,vt]}),e[81]=W,e[82]=K,e[83]=q,e[84]=Q,e[85]=mt,e[86]=vt,e[87]=yt):yt=e[87];let bt=oe?z:null,xt;e[88]!==w.error||e[89]!==w.isError?(xt=w.isError?c({error:w.error,fallbackMessage:`Couldn't rename the machine.`}):null,e[88]=w.error,e[89]=w.isError,e[90]=xt):xt=e[90];let St;e[91]===w.isPending?St=e[92]:(St=e=>{!e&&!w.isPending&&ce(!1)},e[91]=w.isPending,e[92]=St);let Ct;e[93]===w?Ct=e[94]:(Ct=(e,t)=>w.mutate({hostId:e.id,name:t},{onSuccess:()=>ce(!1)}),e[93]=w,e[94]=Ct);let wt;e[95]!==w.isPending||e[96]!==bt||e[97]!==xt||e[98]!==St||e[99]!==Ct?(wt=(0,L.jsx)(Te,{target:bt,pending:w.isPending,errorMessage:xt,onOpenChange:St,onRename:Ct}),e[95]=w.isPending,e[96]=bt,e[97]=xt,e[98]=St,e[99]=Ct,e[100]=wt):wt=e[100];let Tt=_e?z:null,Et;e[101]===i?Et=e[102]:(Et=()=>i(re(`machines`)),e[101]=i,e[102]=Et);let Dt;e[103]!==Tt||e[104]!==Et?(Dt=(0,L.jsx)(Se,{target:Tt,onOpenChange:ye,onRemoved:Et}),e[103]=Tt,e[104]=Et,e[105]=Dt):Dt=e[105];let Ot=De?z:null,kt;e[106]===Ot?kt=e[107]:(kt=(0,L.jsx)(Ce,{target:Ot,onOpenChange:Ae}),e[106]=Ot,e[107]=kt);let At=be?z:null,$;e[108]===At?$=e[109]:($=(0,L.jsx)(xe,{target:At,onOpenChange:Ee}),e[108]=At,e[109]=$);let jt;return e[110]!==it||e[111]!==yt||e[112]!==wt||e[113]!==Dt||e[114]!==kt||e[115]!==$?(jt=(0,L.jsxs)(it,{contentClassName:`pt-4 md:pt-5`,children:[yt,wt,Dt,kt,$]}),e[110]=it,e[111]=yt,e[112]=wt,e[113]=Dt,e[114]=kt,e[115]=$,e[116]=jt):jt=e[116],jt}function Le(e,n){return(0,L.jsxs)(`span`,{children:[n>0?` · `:``,(0,L.jsx)(t,{to:A(e.id),className:`hover:text-foreground`,children:e.name})]},e.id)}function Re(e){return(0,L.jsxs)(`span`,{className:`inline-flex min-w-0 items-center gap-1.5`,children:[e.ProviderIcon?(0,L.jsx)(`span`,{"data-provider-icon":e.providerId,"aria-hidden":!0,className:`flex size-3.5 shrink-0 items-center justify-center`,children:e.provider===void 0?(0,L.jsx)(e.ProviderIcon,{className:`size-3.5`}):(0,L.jsx)(S,{provider:e.provider,icon:e.ProviderIcon,className:`size-3.5`})}):null,(0,L.jsx)(`span`,{children:e.displayName}),e.currentVersion?(0,L.jsx)(`span`,{children:e.currentVersion}):null]},e.providerId)}function ze(e){return{id:e.id,name:e.name}}function Be(e){return e.type===`persistent`}export{Ie as MachineSettingsView};
|
|
1
|
+
import{o as e}from"./rolldown-runtime-BM3Ffeng.js";import{Ar as t,Or as n,Vr as r,mi as i,ni as a,zr as o}from"./boot-vendor-BBLG7GwQ.js";import{t as s}from"./permission-mode-options-BrNWKCMS.js";import{Bo as c,C as l,Ct as u,Dr as d,Ft as f,Ho as p,Lr as m,Po as h,Qm as ee,Sa as g,St as _,T as v,Tc as y,Ui as te,Vi as ne,Ym as b,_ as x,_t as S,fi as C,go as w,ho as T,mo as E,nh as D,nm as re,oh as O,po as k,tm as A,vt as j,xt as ie,zo as M}from"./index-B-RDC4LU.js";import{B as N,I as ae,L as P,R as F,b as oe,z as se}from"./resource-list-CC7zN47b.js";import{r as ce,t as le}from"./machine-provider-queries-By9Ipha4.js";import{t as ue}from"./page-shell-ClYdhKtX.js";import{a as de,c as fe,i as pe,o as me,r as he,s as ge}from"./host-mutations-Bf4idS3m.js";import{a as _e,c as ve,i as ye,l as be,n as xe,o as Se,r as Ce,s as we,t as Te,u as Ee}from"./MachineRenameDialog-HGiXO0UG.js";var I=n(),L=e(a(),1);function De(e){let t=(0,I.c)(5),{notice:n}=e;if(n===null||n.message===null)return null;let r=n.phase===`suspending`||n.phase===`resuming`?`text-subtle-foreground`:`text-destructive-text`,i;t[0]===r?i=t[1]:(i=O(`min-w-0 text-xs`,r),t[0]=r,t[1]=i);let a;return t[2]!==n.message||t[3]!==i?(a=(0,L.jsx)(`p`,{role:`status`,"aria-label":`Machine maintenance`,className:i,children:n.message}),t[2]=n.message,t[3]=i,t[4]=a):a=t[4],a}var Oe=e(i(),1);function ke(e,t){return t!==null&&t.fromHostId===e.id&&t.oldCopyDeletedAt===null}function Ae(e,t){let n=`The server moved from ${e.name} to ${t.toHostName}. The old server data is still on ${e.name}, locked so bb won't start a server from it. Keep it as a backup, or delete it once the new server works.`;return e.status===`connected`?n:`${n} ${e.name} has to be online to delete it.`}function je(e){let t=(0,I.c)(33),{host:n,lastMove:r}=e,i=v(),[a,o]=(0,Oe.useState)(!1),s;t[0]===i?s=t[1]:(s=()=>{i.reset(),o(!0)},t[0]=i,t[1]=s);let l;t[2]!==n||t[3]!==r||t[4]!==s?(l=(0,L.jsx)(R,{host:n,lastMove:r,onDelete:s}),t[2]=n,t[3]=r,t[4]=s,t[5]=l):l=t[5];let u;t[6]===i?u=t[7]:(u=e=>{!e&&!i.isPending&&(i.reset(),o(!1))},t[6]=i,t[7]=u);let d;t[8]===Symbol.for(`react.memo_cache_sentinel`)?(d=(0,L.jsx)(w,{children:`Delete the old server copy?`}),t[8]=d):d=t[8];let f;t[9]!==n.name||t[10]!==r.toHostName?(f=(0,L.jsxs)(T,{children:[d,(0,L.jsxs)(k,{children:[`This permanently deletes the database, settings and plugin data`,` `,n.name,` kept when the server moved to `,r.toHostName,`. The server on `,r.toHostName,` is not affected.`]})]}),t[9]=n.name,t[10]=r.toHostName,t[11]=f):f=t[11];let p;t[12]!==i.error||t[13]!==i.isError||t[14]!==n.name?(p=i.isError?(0,L.jsx)(`p`,{className:`text-sm text-destructive-text`,role:`alert`,children:c({error:i.error,fallbackMessage:`Couldn't delete the old server copy on ${n.name}.`})}):null,t[12]=i.error,t[13]=i.isError,t[14]=n.name,t[15]=p):p=t[15];let h;t[16]!==i||t[17]!==n.id||t[18]!==n.name?(h=()=>i.mutate(n.id,{onSuccess:e=>{o(!1),b.success(e.deleted?`Deleted the old server copy on ${n.name}`:`No old server copy was left on ${n.name}`)}}),t[16]=i,t[17]=n.id,t[18]=n.name,t[19]=h):h=t[19];let ee=i.isPending?`Deleting…`:`Delete old copy`,g;t[20]!==i.isPending||t[21]!==h||t[22]!==ee?(g=(0,L.jsx)(E,{children:(0,L.jsx)(D,{type:`button`,variant:`destructive`,disabled:i.isPending,onClick:h,children:ee})}),t[20]=i.isPending,t[21]=h,t[22]=ee,t[23]=g):g=t[23];let _;t[24]!==a||t[25]!==u||t[26]!==f||t[27]!==p||t[28]!==g?(_=(0,L.jsxs)(m,{modal:!1,open:a,onOpenChange:u,children:[f,p,g]}),t[24]=a,t[25]=u,t[26]=f,t[27]=p,t[28]=g,t[29]=_):_=t[29];let y;return t[30]!==_||t[31]!==l?(y=(0,L.jsxs)(L.Fragment,{children:[l,_]}),t[30]=_,t[31]=l,t[32]=y):y=t[32],y}function R(e){let t=(0,I.c)(9),{host:n,lastMove:r,onDelete:i}=e,a;t[0]!==n||t[1]!==r?(a=Ae(n,r),t[0]=n,t[1]=r,t[2]=a):a=t[2];let o=n.status!==`connected`,s;t[3]!==i||t[4]!==o?(s=(0,L.jsx)(se,{children:(0,L.jsx)(F,{children:(0,L.jsx)(D,{type:`button`,variant:`destructive`,size:`sm`,disabled:o,onClick:i,children:`Delete old copy`})})}),t[3]=i,t[4]=o,t[5]=s):s=t[5];let c;return t[6]!==a||t[7]!==s?(c=(0,L.jsx)(N,{title:`Old server copy`,description:a,children:s}),t[6]=a,t[7]=s,t[8]=c):c=t[8],c}var Me=`Highest permission mode any thread on the selected machine may run with. Threads that ask for more resolve down to it, and a provider that supports nothing this low can't run here.`,Ne={darwin:`macOS`,linux:`Linux`,wsl:`WSL`,win32:`Windows`,unknown:null};function z({host:e,platformLabel:t,now:n}){let r=[be({host:e,now:n})];return t!==null&&r.push(t),r.push(`paired ${g({timestamp:e.createdAt,now:n})}`),r.join(` · `)}function Pe(e){let t=(0,I.c)(6),{disabled:n,onSelect:r,value:i}=e,a;t[0]!==n||t[1]!==r||t[2]!==i?(a=s.map(e=>{let t=e.value===i;return(0,L.jsx)(F,{className:`items-start`,children:(0,L.jsxs)(`button`,{type:`button`,role:`radio`,"aria-checked":t,disabled:n,onClick:()=>{t||r(e.value)},className:O(`flex w-full items-start gap-3 rounded-md text-left outline-none focus-visible:ring-2 focus-visible:ring-ring`,n&&`opacity-70`),children:[(0,L.jsx)(`span`,{className:O(`mt-0.5 flex size-4 shrink-0 items-center justify-center rounded-full border`,t?`border-foreground`:`border-input`),children:t?(0,L.jsx)(`span`,{className:`size-2 rounded-full bg-foreground`}):null}),(0,L.jsxs)(`span`,{className:`min-w-0 flex-1`,children:[(0,L.jsx)(`span`,{className:`block text-sm text-foreground`,children:e.label}),e.description?(0,L.jsx)(`span`,{className:`mt-0.5 block text-xs leading-snug text-subtle-foreground/75`,children:e.description}):null]})]})},e.value)}),t[0]=n,t[1]=r,t[2]=i,t[3]=a):a=t[3];let o;return t[4]===a?o=t[5]:(o=(0,L.jsx)(`div`,{role:`radiogroup`,"aria-label":`Permission limit`,children:(0,L.jsx)(se,{children:a})}),t[4]=a,t[5]=o),o}function Fe(e){let n=(0,I.c)(57),{host:r,machineProvider:i,platformLabel:a,now:o,isPrimary:s,isThisMachine:c,showServerBadge:l,lifecycleNotice:u,lifecycleActionPending:d,onSuspend:f,onResume:p,onRetryCleanup:m,onRename:h,onReconnect:g,canMoveServerHere:_,onMoveServerHere:v}=e,y;n[0]===Symbol.for(`react.memo_cache_sentinel`)?(y=re(`machines`),n[0]=y):y=n[0];let ne;n[1]===Symbol.for(`react.memo_cache_sentinel`)?(ne=(0,L.jsxs)(t,{to:y,className:`inline-flex items-center gap-1 text-sm text-muted-foreground hover:text-foreground`,children:[(0,L.jsx)(ee,{name:`ChevronLeft`,className:`size-3.5`}),`Machines`]}),n[1]=ne):ne=n[1];let b;n[2]!==r||n[3]!==i?(b=(0,L.jsx)(`h1`,{className:`min-w-0 text-sm font-semibold text-foreground`,children:(0,L.jsx)(ce,{host:r,machineProvider:i})}),n[2]=r,n[3]=i,n[4]=b):b=n[4];let x;n[5]===c?x=n[6]:(x=c?(0,L.jsx)(ae,{children:`This machine`}):null,n[5]=c,n[6]=x);let S;n[7]===l?S=n[8]:(S=l?(0,L.jsx)(ae,{children:`Server`}):null,n[7]=l,n[8]=S);let C;n[9]!==b||n[10]!==x||n[11]!==S?(C=(0,L.jsxs)(`div`,{className:`flex min-w-0 items-center gap-2`,children:[b,x,S]}),n[9]=b,n[10]=x,n[11]=S,n[12]=C):C=n[12];let w;n[13]===r?w=n[14]:(w=Ee(r),n[13]=r,n[14]=w);let T;n[15]===w?T=n[16]:(T=(0,L.jsx)(te,{tone:w}),n[15]=w,n[16]=T);let E;n[17]!==r||n[18]!==o||n[19]!==a?(E=z({host:r,platformLabel:a,now:o}),n[17]=r,n[18]=o,n[19]=a,n[20]=E):E=n[20];let D;n[21]===E?D=n[22]:(D=(0,L.jsx)(`p`,{className:`min-w-0 text-xs text-subtle-foreground/75`,children:E}),n[21]=E,n[22]=D);let O;n[23]!==D||n[24]!==T?(O=(0,L.jsxs)(`div`,{className:`flex min-w-0 items-center gap-2`,children:[T,D]}),n[23]=D,n[24]=T,n[25]=O):O=n[25];let k;n[26]===u?k=n[27]:(k=(0,L.jsx)(De,{notice:u}),n[26]=u,n[27]=k);let A;n[28]!==O||n[29]!==k||n[30]!==C?(A=(0,L.jsxs)(`div`,{className:`min-w-0 space-y-1`,children:[C,O,k]}),n[28]=O,n[29]=k,n[30]=C,n[31]=A):A=n[31];let j;n[32]!==r||n[33]!==d||n[34]!==i||n[35]!==p||n[36]!==m||n[37]!==f?(j=(0,L.jsx)(_e,{host:r,machineProvider:i,pending:d,onSuspend:f,onResume:p,onRetryCleanup:m}),n[32]=r,n[33]=d,n[34]=i,n[35]=p,n[36]=m,n[37]=f,n[38]=j):j=n[38];let ie=`${r.name} actions`,M;n[39]!==_||n[40]!==r||n[41]!==s||n[42]!==d||n[43]!==i||n[44]!==v||n[45]!==g||n[46]!==h?(M=ye({host:r,machineProvider:i,isPrimary:s,canMoveServerHere:_,lifecycleActionPending:d,onRename:h,onReconnect:g,onMoveServerHere:v}),n[39]=_,n[40]=r,n[41]=s,n[42]=d,n[43]=i,n[44]=v,n[45]=g,n[46]=h,n[47]=M):M=n[47];let N;n[48]!==ie||n[49]!==M?(N=(0,L.jsx)(oe,{label:ie,items:M}),n[48]=ie,n[49]=M,n[50]=N):N=n[50];let P;n[51]!==j||n[52]!==N?(P=(0,L.jsxs)(`div`,{className:`flex shrink-0 items-center gap-2`,children:[j,N]}),n[51]=j,n[52]=N,n[53]=P):P=n[53];let F;return n[54]!==A||n[55]!==P?(F=(0,L.jsxs)(`div`,{className:`space-y-3`,children:[ne,(0,L.jsxs)(`div`,{className:`flex min-w-0 items-start justify-between gap-3`,children:[A,P]})]}),n[54]=A,n[55]=P,n[56]=F):F=n[56],F}function Ie(){let e=(0,I.c)(117),{hostId:n}=r(),i=o(),a=ne(),{providers:s}=le(),m=h(),{localDaemonHostId:g,platform:v}=C(),te=y(),S=ie(),w=he(),T=me(),E=ge(),O=pe(),k=de(),A=fe(),ae=l(),[oe,ce]=(0,Oe.useState)(!1),[_e,ye]=(0,Oe.useState)(!1),[be,Ee]=(0,Oe.useState)(!1),[De,Ae]=(0,Oe.useState)(!1),R=a.data,z=R?.find(e=>e.id===n)??null,Ie=z?.lifecycle.message??null,Ve=z===null?null:{phase:z.lifecycle.phase,message:Ie},He=m.data?.primaryHostId??null,B=m.data?.experiments.serverMove??!1,V=z!==null&&z.id===He,Ue;e[0]===R?Ue=e[1]:(Ue=R?.filter(Be).length??0,e[0]=R,e[1]=Ue);let We=Ue>1&&z!==null&&z.id===g,Ge=z?.machineProviderId===null||z?.machineProviderId===void 0?null:s?.find(e=>e.id===z.machineProviderId)??null,Ke;if(e[2]!==n||e[3]!==te.data?.projects){let t=te.data?.projects??[],r;e[5]===n?r=e[6]:(r=e=>e.sources.some(e=>e.hostId===n),e[5]=n,e[6]=r),Ke=t.filter(r).map(ze),e[2]=n,e[3]=te.data?.projects,e[4]=Ke}else Ke=e[4];let qe=Ke,H,Je;if(e[7]!==n||e[8]!==S.machines){let t;e[11]===n?t=e[12]:(t=e=>e.host.id===n,e[11]=n,e[12]=t),H=S.machines.find(t),Je=(H?.issues??[]).filter(f),e[7]=n,e[8]=S.machines,e[9]=H,e[10]=Je}else H=e[9],Je=e[10];let Ye=Je.length,Xe=M().data;H?.providerStatus;let Ze;bb0:{let t=H?.providerStatus;if(!t){let t;e[13]===Symbol.for(`react.memo_cache_sentinel`)?(t=[],e[13]=t):t=e[13],Ze=t;break bb0}let n;e[14]!==Xe||e[15]!==t?(n=Object.entries(t).flatMap(e=>{let[t,n]=e;if(!n.installed)return[];let r=Xe?.find(e=>e.id===t);return[{...n,providerId:t,provider:r,ProviderIcon:j(`agent`,t,r??null)?.icon}]}),e[14]=Xe,e[15]=t,e[16]=n):n=e[16],Ze=n}let Qe=Ze,$e;e[17]===Symbol.for(`react.memo_cache_sentinel`)?($e=Date.now(),e[17]=$e):$e=e[17];let et=$e,tt=z!==null&&z.id===g&&v!==null?Ne[v]:V&&m.data?.primaryHostPlatform?Ne[m.data.primaryHostPlatform]:null;if(R===void 0){let t;return e[18]===Symbol.for(`react.memo_cache_sentinel`)?(t=(0,L.jsx)(ue,{contentClassName:`pt-4 md:pt-5`,children:(0,L.jsx)(`div`,{className:`mx-auto w-full max-w-3xl`,children:(0,L.jsx)(`p`,{className:`text-sm text-muted-foreground`,children:`Loading…`})})}),e[18]=t):t=e[18],t}if(z===null){let n;e[19]===Symbol.for(`react.memo_cache_sentinel`)?(n=re(`machines`),e[19]=n):n=e[19];let r;return e[20]===Symbol.for(`react.memo_cache_sentinel`)?(r=(0,L.jsx)(ue,{contentClassName:`pt-4 md:pt-5`,children:(0,L.jsxs)(`div`,{className:`mx-auto w-full max-w-3xl space-y-3`,children:[(0,L.jsxs)(t,{to:n,className:`inline-flex items-center gap-1 text-sm text-muted-foreground hover:text-foreground`,children:[(0,L.jsx)(ee,{name:`ChevronLeft`,className:`size-3.5`}),`Machines`]}),(0,L.jsx)(`p`,{className:`text-sm text-muted-foreground`,children:`Machine is no longer paired.`})]})}),e[20]=r):r=e[20],r}let nt=_(z),rt=ae.data?.lastMove??null,it=ue,at=Fe,ot=E.isPending||O.isPending||k.isPending,st=()=>E.mutate(z.id),ct=()=>O.mutate(z.id),lt=()=>k.mutate(z.id),U;e[21]===w?U=e[22]:(U=()=>{w.reset(),ce(!0)},e[21]=w,e[22]=U);let ut=m.data!==void 0&&x({host:z,primaryHostId:He,move:ae.data?.move??null,serverMoveEnabled:B}),dt,ft;e[23]===Symbol.for(`react.memo_cache_sentinel`)?(dt=()=>Ae(!0),ft=()=>Ee(!0),e[23]=dt,e[24]=ft):(dt=e[23],ft=e[24]);let W;e[25]!==at||e[26]!==z||e[27]!==V||e[28]!==We||e[29]!==Ve||e[30]!==Ge||e[31]!==et||e[32]!==tt||e[33]!==lt||e[34]!==U||e[35]!==ut||e[36]!==ot||e[37]!==st||e[38]!==ct?(W=(0,L.jsx)(at,{host:z,machineProvider:Ge,platformLabel:tt,now:et,isPrimary:V,isThisMachine:We,showServerBadge:V,lifecycleNotice:Ve,lifecycleActionPending:ot,onSuspend:st,onResume:ct,onRetryCleanup:lt,onRename:U,canMoveServerHere:ut,onReconnect:dt,onMoveServerHere:ft}),e[25]=at,e[26]=z,e[27]=V,e[28]=We,e[29]=Ve,e[30]=Ge,e[31]=et,e[32]=tt,e[33]=lt,e[34]=U,e[35]=ut,e[36]=ot,e[37]=st,e[38]=ct,e[39]=W):W=e[39];let G;e[40]!==z.id||e[41]!==z.name||e[42]!==A?(G=e=>A.mutate({hostId:z.id,maxPermissionMode:e},{onError:e=>{p({error:e,fallbackMessage:`Couldn't change the permission limit for ${z.name}.`})}}),e[40]=z.id,e[41]=z.name,e[42]=A,e[43]=G):G=e[43];let K;e[44]!==z.maxPermissionMode||e[45]!==G||e[46]!==A.isPending?(K=(0,L.jsx)(N,{title:`Permission limit`,description:Me,children:(0,L.jsx)(Pe,{value:z.maxPermissionMode,disabled:A.isPending,onSelect:G})}),e[44]=z.maxPermissionMode,e[45]=G,e[46]=A.isPending,e[47]=K):K=e[47];let q;e[48]!==z.status||e[49]!==Qe||e[50]!==H?.statusError||e[51]!==H?.statusPending||e[52]!==Ye?(q=(0,L.jsx)(N,{title:`Provider CLIs`,children:(0,L.jsx)(se,{children:(0,L.jsx)(P,{label:`Installed`,children:z.status===`connected`?H?.statusPending?(0,L.jsx)(`span`,{children:`Checking…`}):H?.statusError?(0,L.jsx)(`span`,{children:`Status unavailable`}):(0,L.jsxs)(L.Fragment,{children:[Qe.length>0?(0,L.jsx)(`span`,{className:`flex min-w-0 flex-wrap items-center justify-start gap-x-3 gap-y-1 @min-[36rem]/settings:justify-end`,children:Qe.map(Re)}):(0,L.jsx)(`span`,{children:`None installed`}),Ye>0?(0,L.jsx)(t,{to:re(`updates`),className:`shrink-0 rounded outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2`,children:(0,L.jsxs)(d,{variant:`outline`,size:`sm`,className:`border-attention/50 bg-surface-attention text-warning-text transition-colors hover:border-attention hover:text-foreground`,children:[Ye,` to fix`]})}):null]}):(0,L.jsx)(`span`,{children:`Unavailable while offline`})})})}),e[48]=z.status,e[49]=Qe,e[50]=H?.statusError,e[51]=H?.statusPending,e[52]=Ye,e[53]=q):q=e[53];let J;e[54]===qe?J=e[55]:(J=(0,L.jsx)(P,{label:`Projects`,children:qe.length===0?(0,L.jsx)(`span`,{children:`None`}):(0,L.jsx)(`span`,{className:`min-w-0 truncate`,children:qe.map(Le)})}),e[54]=qe,e[55]=J);let pt=nt??`Up to date`,Y;e[56]===pt?Y=e[57]:(Y=(0,L.jsx)(`span`,{children:pt}),e[56]=pt,e[57]=Y);let X;e[58]!==z||e[59]!==T?(X=u(z)?(0,L.jsx)(D,{type:`button`,variant:`outline`,size:`sm`,className:`h-6 px-2 text-xs`,disabled:T.isPending,onClick:()=>T.mutate(z.id,{onSuccess:()=>{b.success(`Update retry requested for ${z.name}`)}}),children:T.isPending?`Retrying…`:`Retry update`}):null,e[58]=z,e[59]=T,e[60]=X):X=e[60];let Z;e[61]!==Y||e[62]!==X?(Z=(0,L.jsxs)(P,{label:`Updates`,children:[Y,X]}),e[61]=Y,e[62]=X,e[63]=Z):Z=e[63];let Q;e[64]!==J||e[65]!==Z?(Q=(0,L.jsx)(N,{title:`Machine information`,children:(0,L.jsxs)(se,{children:[J,Z]})}),e[64]=J,e[65]=Z,e[66]=Q):Q=e[66];let mt;e[67]!==z||e[68]!==rt||e[69]!==B?(mt=B&&ke(z,rt)?(0,L.jsx)(je,{host:z,lastMove:rt}):null,e[67]=z,e[68]=rt,e[69]=B,e[70]=mt):mt=e[70];let ht;e[71]!==z||e[72]!==V||e[73]!==B?(ht=V?ve(B):`Revokes ${z.name}'s access to this server. ${we(z)}`,e[71]=z,e[72]=V,e[73]=B,e[74]=ht):ht=e[74];let gt;e[75]===Symbol.for(`react.memo_cache_sentinel`)?(gt=()=>ye(!0),e[75]=gt):gt=e[75];let _t;e[76]===V?_t=e[77]:(_t=(0,L.jsx)(se,{children:(0,L.jsx)(F,{children:(0,L.jsx)(D,{type:`button`,variant:`destructive`,size:`sm`,disabled:V,onClick:gt,children:`Remove machine`})})}),e[76]=V,e[77]=_t);let vt;e[78]!==ht||e[79]!==_t?(vt=(0,L.jsx)(N,{title:`Danger zone`,description:ht,children:_t}),e[78]=ht,e[79]=_t,e[80]=vt):vt=e[80];let yt;e[81]!==W||e[82]!==K||e[83]!==q||e[84]!==Q||e[85]!==mt||e[86]!==vt?(yt=(0,L.jsxs)(`div`,{className:`mx-auto w-full max-w-3xl space-y-6 pb-10`,children:[W,K,q,Q,mt,vt]}),e[81]=W,e[82]=K,e[83]=q,e[84]=Q,e[85]=mt,e[86]=vt,e[87]=yt):yt=e[87];let bt=oe?z:null,xt;e[88]!==w.error||e[89]!==w.isError?(xt=w.isError?c({error:w.error,fallbackMessage:`Couldn't rename the machine.`}):null,e[88]=w.error,e[89]=w.isError,e[90]=xt):xt=e[90];let St;e[91]===w.isPending?St=e[92]:(St=e=>{!e&&!w.isPending&&ce(!1)},e[91]=w.isPending,e[92]=St);let Ct;e[93]===w?Ct=e[94]:(Ct=(e,t)=>w.mutate({hostId:e.id,name:t},{onSuccess:()=>ce(!1)}),e[93]=w,e[94]=Ct);let wt;e[95]!==w.isPending||e[96]!==bt||e[97]!==xt||e[98]!==St||e[99]!==Ct?(wt=(0,L.jsx)(Te,{target:bt,pending:w.isPending,errorMessage:xt,onOpenChange:St,onRename:Ct}),e[95]=w.isPending,e[96]=bt,e[97]=xt,e[98]=St,e[99]=Ct,e[100]=wt):wt=e[100];let Tt=_e?z:null,Et;e[101]===i?Et=e[102]:(Et=()=>i(re(`machines`)),e[101]=i,e[102]=Et);let Dt;e[103]!==Tt||e[104]!==Et?(Dt=(0,L.jsx)(Se,{target:Tt,onOpenChange:ye,onRemoved:Et}),e[103]=Tt,e[104]=Et,e[105]=Dt):Dt=e[105];let Ot=De?z:null,kt;e[106]===Ot?kt=e[107]:(kt=(0,L.jsx)(Ce,{target:Ot,onOpenChange:Ae}),e[106]=Ot,e[107]=kt);let At=be?z:null,$;e[108]===At?$=e[109]:($=(0,L.jsx)(xe,{target:At,onOpenChange:Ee}),e[108]=At,e[109]=$);let jt;return e[110]!==it||e[111]!==yt||e[112]!==wt||e[113]!==Dt||e[114]!==kt||e[115]!==$?(jt=(0,L.jsxs)(it,{contentClassName:`pt-4 md:pt-5`,children:[yt,wt,Dt,kt,$]}),e[110]=it,e[111]=yt,e[112]=wt,e[113]=Dt,e[114]=kt,e[115]=$,e[116]=jt):jt=e[116],jt}function Le(e,n){return(0,L.jsxs)(`span`,{children:[n>0?` · `:``,(0,L.jsx)(t,{to:A(e.id),className:`hover:text-foreground`,children:e.name})]},e.id)}function Re(e){return(0,L.jsxs)(`span`,{className:`inline-flex min-w-0 items-center gap-1.5`,children:[e.ProviderIcon?(0,L.jsx)(`span`,{"data-provider-icon":e.providerId,"aria-hidden":!0,className:`flex size-3.5 shrink-0 items-center justify-center`,children:e.provider===void 0?(0,L.jsx)(e.ProviderIcon,{className:`size-3.5`}):(0,L.jsx)(S,{provider:e.provider,icon:e.ProviderIcon,className:`size-3.5`})}):null,(0,L.jsx)(`span`,{children:e.displayName}),e.currentVersion?(0,L.jsx)(`span`,{children:e.currentVersion}):null]},e.providerId)}function ze(e){return{id:e.id,name:e.name}}function Be(e){return e.type===`persistent`}export{Ie as MachineSettingsView};
|
|
Binary file
|
|
Binary file
|
package/app/dist/assets/{MicrophonePreferences-CNEhQgAS.js → MicrophonePreferences-qaOpiph1.js}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{o as e}from"./rolldown-runtime-BM3Ffeng.js";import{Or as t,mi as n,ni as r}from"./boot-vendor-BBLG7GwQ.js";import{Qm as i,oh as a}from"./index-
|
|
1
|
+
import{o as e}from"./rolldown-runtime-BM3Ffeng.js";import{Or as t,mi as n,ni as r}from"./boot-vendor-BBLG7GwQ.js";import{Qm as i,oh as a}from"./index-B-RDC4LU.js";import{a as o,i as s,n as c,t as l}from"./audio-input-device-preference-BeKjzmnK.js";import{t as u}from"./WaveformVisualizer-GDJ4mJRx.js";var d=t(),f=e(n(),1),p=e(r(),1);function m(e){let t=(0,d.c)(43),{open:n,onCaptureReady:r}=e,[m,_]=c(),{devices:v,refresh:y,isSupported:b,hasDeviceAccess:x}=s(),[S,C]=(0,f.useState)(null),[w,T]=(0,f.useState)(null),E,D;t[0]!==b||t[1]!==n||t[2]!==m||t[3]!==y?(E=()=>{if(!n||!b)return;let e=!1,t=null;return T(null),C(null),l(navigator.mediaDevices,m).then(n=>{if(e){n.getTracks().forEach(g);return}t=n,C(n),y()}).catch(t=>{e||T(t instanceof DOMException&&t.name===`NotAllowedError`?`Allow mic access in your settings.`:`Can't open this mic. Choose another.`)}),()=>{e=!0,t?.getTracks().forEach(h),C(null)}},D=[n,m,y,b],t[0]=b,t[1]=n,t[2]=m,t[3]=y,t[4]=E,t[5]=D):(E=t[4],D=t[5]),(0,f.useEffect)(E,D);let O,k;t[6]!==r||t[7]!==n||t[8]!==S?(O=()=>{n&&S&&r?.()},k=[n,S,r],t[6]=r,t[7]=n,t[8]=S,t[9]=O,t[10]=k):(O=t[9],k=t[10]),(0,f.useEffect)(O,k);let A=n?S:null,{silent:j}=o(A,!1),M;t[11]===A?M=t[12]:(M=A?.getAudioTracks()[0]?.label,t[11]=A,t[12]=M);let N=M,P;t[13]!==v||t[14]!==x||t[15]!==m?(P=x&&m!==null&&v.length>0&&!v.some(e=>e.deviceId===m),t[13]=v,t[14]=x,t[15]=m,t[16]=P):P=t[16];let F=P,I;t[17]!==N||t[18]!==w||t[19]!==b||t[20]!==n||t[21]!==j||t[22]!==A?(I=n?(0,p.jsxs)(`div`,{className:`space-y-2 rounded-lg border bg-muted/30 p-3`,"aria-label":`Live microphone preview`,children:[(0,p.jsxs)(`div`,{className:`flex items-center justify-between gap-2 text-xs text-muted-foreground`,children:[(0,p.jsx)(`span`,{className:`shrink-0 font-medium`,children:`Live preview`}),(0,p.jsx)(`span`,{className:`min-w-0 truncate`,title:N,children:w||!b?`Unavailable`:A?N||`Listening`:`Connecting…`})]}),(0,p.jsx)(u,{stream:A,active:n&&A!==null,className:`h-9 w-full`}),(0,p.jsx)(`p`,{role:`status`,className:`min-h-5 text-sm text-muted-foreground`,children:w??(b?A?j?`No audio detected. Try another mic.`:`Speak to check your microphone.`:`Connecting to microphone…`:`This browser can't use a mic.`)})]}):null,t[17]=N,t[18]=w,t[19]=b,t[20]=n,t[21]=j,t[22]=A,t[23]=I):I=t[23];let L;t[24]===Symbol.for(`react.memo_cache_sentinel`)?(L=(0,p.jsx)(`p`,{className:`px-1 text-xs font-medium text-muted-foreground`,children:`Input device`}),t[24]=L):L=t[24];let R;t[25]===Symbol.for(`react.memo_cache_sentinel`)?(R={deviceId:null,label:`System default`},t[25]=R):R=t[25];let z;t[26]!==m||t[27]!==F?(z=F?[{deviceId:m,label:`Preferred microphone (unavailable)`}]:[],t[26]=m,t[27]=F,t[28]=z):z=t[28];let B;t[29]!==v||t[30]!==z?(B=[R,...z,...v],t[29]=v,t[30]=z,t[31]=B):B=t[31];let V;t[32]!==m||t[33]!==F||t[34]!==_||t[35]!==B?(V=(0,p.jsxs)(`div`,{className:`space-y-2`,children:[L,(0,p.jsx)(`div`,{role:`group`,"aria-label":`Microphone`,className:`max-h-64 space-y-1 overflow-y-auto rounded-lg border p-1`,children:B.map(e=>(0,p.jsxs)(`button`,{type:`button`,"aria-pressed":m===e.deviceId,disabled:F&&e.deviceId===m,onClick:()=>_(e.deviceId),className:a(`flex min-h-11 w-full items-center gap-3 rounded-md px-3 py-2.5 text-left text-sm transition-colors hover:bg-state-hover focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-inset disabled:opacity-50`,m===e.deviceId&&`bg-state-active`),children:[(0,p.jsx)(i,{name:e.deviceId===null?`Laptop`:`Mic`,className:`size-4 shrink-0 text-muted-foreground`}),(0,p.jsx)(`span`,{className:`min-w-0 flex-1 break-words`,children:e.label}),(0,p.jsx)(`span`,{className:`size-4 shrink-0`,"aria-hidden":`true`,children:m===e.deviceId?(0,p.jsx)(i,{name:`Check`,className:`size-4`}):null})]},e.deviceId??`system`))})]}),t[32]=m,t[33]=F,t[34]=_,t[35]=B,t[36]=V):V=t[36];let H;t[37]===F?H=t[38]:(H=F?(0,p.jsx)(`p`,{className:`text-xs text-muted-foreground`,children:`Preferred microphone unavailable. Using another input until it returns.`}):null,t[37]=F,t[38]=H);let U;return t[39]!==V||t[40]!==H||t[41]!==I?(U=(0,p.jsxs)(`div`,{className:`space-y-4`,children:[I,V,H]}),t[39]=V,t[40]=H,t[41]=I,t[42]=U):U=t[42],U}function h(e){return e.stop()}function g(e){return e.stop()}export{m as MicrophonePreferences};
|
|
Binary file
|
|
Binary file
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{o as e}from"./rolldown-runtime-BM3Ffeng.js";import{It as t,J as n,Or as r,Qt as i,X as a,Xn as o,Y as s,Yt as c,Z as l,Zt as u,mi as d,ni as f}from"./boot-vendor-BBLG7GwQ.js";import{Aa as p,Ma as m,Q_ as h,Qm as ee,Xf as g,aa as _,ah as v,ja as y,oa as te,oh as b,sa as x,zf as S}from"./index-BBxUiLNy.js";import{t as C}from"./switch-CzvlSesf.js";import{a as w,i as T,o as E,r as D,s as O,t as k}from"./model-load-error-message-B-HKqgUD.js";var A=r(),j=e(d(),1),M=e(f(),1),N=`Toggle`,P=j.forwardRef((e,n)=>{let{pressed:r,defaultPressed:a,onPressedChange:o,...s}=e,[l,u]=t({prop:r,onChange:o,defaultProp:a??!1,caller:N});return(0,M.jsx)(c.button,{type:`button`,"aria-pressed":l,"data-state":l?`on`:`off`,"data-disabled":e.disabled?``:void 0,...s,ref:n,onClick:i(e.onClick,()=>{e.disabled||u(!l)})})});P.displayName=N;var F=P,I=`ToggleGroup`,[L,R]=u(I,[a]),z=a(),B=j.forwardRef((e,t)=>{let{type:n,...r}=e;if(n===`single`)return(0,M.jsx)(ne,{role:`radiogroup`,...r,ref:t});if(n===`multiple`)return(0,M.jsx)(re,{role:`toolbar`,...r,ref:t});throw Error(`Missing prop \`type\` expected on \`${I}\``)});B.displayName=I;var[V,H]=L(I),ne=j.forwardRef((e,n)=>{let{value:r,defaultValue:i,onValueChange:a=()=>{},...o}=e,[s,c]=t({prop:r,defaultProp:i??``,onChange:a,caller:I});return(0,M.jsx)(V,{scope:e.__scopeToggleGroup,type:`single`,value:j.useMemo(()=>s?[s]:[],[s]),onItemActivate:c,onItemDeactivate:j.useCallback(()=>c(``),[c]),children:(0,M.jsx)(W,{...o,ref:n})})}),re=j.forwardRef((e,n)=>{let{value:r,defaultValue:i,onValueChange:a=()=>{},...o}=e,[s,c]=t({prop:r,defaultProp:i??[],onChange:a,caller:I}),l=j.useCallback(e=>c((t=[])=>[...t,e]),[c]),u=j.useCallback(e=>c((t=[])=>t.filter(t=>t!==e)),[c]);return(0,M.jsx)(V,{scope:e.__scopeToggleGroup,type:`multiple`,value:s,onItemActivate:l,onItemDeactivate:u,children:(0,M.jsx)(W,{...o,ref:n})})});B.displayName=I;var[U,ie]=L(I),W=j.forwardRef((e,t)=>{let{__scopeToggleGroup:n,disabled:r=!1,rovingFocus:i=!0,orientation:a,dir:o,loop:u=!0,...d}=e,f=z(n),p=l(o),m={dir:p,...d};return(0,M.jsx)(U,{scope:n,rovingFocus:i,disabled:r,children:i?(0,M.jsx)(s,{asChild:!0,...f,orientation:a,dir:p,loop:u,children:(0,M.jsx)(c.div,{...m,ref:t})}):(0,M.jsx)(c.div,{...m,ref:t})})}),G=`ToggleGroupItem`,K=j.forwardRef((e,t)=>{let r=H(G,e.__scopeToggleGroup),i=ie(G,e.__scopeToggleGroup),a=z(e.__scopeToggleGroup),o=r.value.includes(e.value),s=i.disabled||e.disabled,c={...e,pressed:o,disabled:s},l=j.useRef(null);return i.rovingFocus?(0,M.jsx)(n,{asChild:!0,...a,focusable:!s,active:o,ref:l,children:(0,M.jsx)(q,{...c,ref:t})}):(0,M.jsx)(q,{...c,ref:t})});K.displayName=G;var q=j.forwardRef((e,t)=>{let{__scopeToggleGroup:n,value:r,...i}=e,a=H(G,n),o={role:`radio`,"aria-checked":e.pressed,"aria-pressed":void 0};return(0,M.jsx)(P,{...a.type===`single`?o:void 0,...i,ref:t,onPressedChange:e=>{e?a.onItemActivate(r):a.onItemDeactivate(r)}})}),J=o(`inline-flex items-center justify-center gap-2 rounded-md text-sm font-medium transition-colors hover:bg-muted hover:text-muted-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:pointer-events-none disabled:opacity-50 data-[state=on]:bg-accent data-[state=on]:text-accent-foreground [&_[data-icon-root]]:pointer-events-none [&_[data-icon-root]]:size-4 [&_[data-icon-root]]:shrink-0`,{variants:{variant:{default:`bg-transparent`,outline:`border border-input bg-transparent shadow-sm hover:bg-accent hover:text-accent-foreground`},size:{default:`h-9 px-2 min-w-9`,sm:`h-8 px-1.5 min-w-8`,lg:`h-10 px-2.5 min-w-10`}},defaultVariants:{variant:`default`,size:`default`}}),ae=j.forwardRef((e,t)=>{let n=(0,A.c)(13),r,i,a,o;n[0]===e?(r=n[1],i=n[2],a=n[3],o=n[4]):({className:r,variant:o,size:a,...i}=e,n[0]=e,n[1]=r,n[2]=i,n[3]=a,n[4]=o);let s;n[5]!==r||n[6]!==a||n[7]!==o?(s=b(J({variant:o,size:a,className:r})),n[5]=r,n[6]=a,n[7]=o,n[8]=s):s=n[8];let c;return n[9]!==i||n[10]!==t||n[11]!==s?(c=(0,M.jsx)(F,{ref:t,className:s,...i}),n[9]=i,n[10]=t,n[11]=s,n[12]=c):c=n[12],c});ae.displayName=F.displayName;var oe=j.createContext({size:`default`,variant:`default`}),se=j.forwardRef((e,t)=>{let n=(0,A.c)(19),r,i,a,o,s;n[0]===e?(r=n[1],i=n[2],a=n[3],o=n[4],s=n[5]):({className:i,variant:s,size:o,children:r,...a}=e,n[0]=e,n[1]=r,n[2]=i,n[3]=a,n[4]=o,n[5]=s);let c;n[6]===i?c=n[7]:(c=b(`flex items-center justify-center gap-1`,i),n[6]=i,n[7]=c);let l;n[8]!==o||n[9]!==s?(l={variant:s,size:o},n[8]=o,n[9]=s,n[10]=l):l=n[10];let u;n[11]!==r||n[12]!==l?(u=(0,M.jsx)(oe.Provider,{value:l,children:r}),n[11]=r,n[12]=l,n[13]=u):u=n[13];let d;return n[14]!==a||n[15]!==t||n[16]!==c||n[17]!==u?(d=(0,M.jsx)(B,{ref:t,className:c,...a,children:u}),n[14]=a,n[15]=t,n[16]=c,n[17]=u,n[18]=d):d=n[18],d});se.displayName=B.displayName;var Y=j.forwardRef((e,t)=>{let n=(0,A.c)(17),r,i,a,o,s;n[0]===e?(r=n[1],i=n[2],a=n[3],o=n[4],s=n[5]):({className:i,children:r,variant:s,size:o,...a}=e,n[0]=e,n[1]=r,n[2]=i,n[3]=a,n[4]=o,n[5]=s);let c=j.useContext(oe),l;n[6]!==i||n[7]!==c.size||n[8]!==c.variant||n[9]!==o||n[10]!==s?(l=b(J({variant:c.variant||s,size:c.size||o}),i),n[6]=i,n[7]=c.size,n[8]=c.variant,n[9]=o,n[10]=s,n[11]=l):l=n[11];let u;return n[12]!==r||n[13]!==a||n[14]!==t||n[15]!==l?(u=(0,M.jsx)(K,{ref:t,className:l,...a,children:r}),n[12]=r,n[13]=a,n[14]=t,n[15]=l,n[16]=u):u=n[16],u});Y.displayName=K.displayName;function ce(e){let t=(0,A.c)(64),{listRef:n,providerId:r,provider:i,providerLabel:a,listboxId:o,optionId:s,modelIsLoading:c,isShowingModelError:l,hasModelOptions:u,modelLoadError:d,modelLoadFailed:f,navRows:p,highlightedIndex:m,isSearching:_,showMoreModels:y,onToggleMoreModels:x,moreModelOptions:S,moreModelsOpen:w,onMoreModelsOpenChange:T,isPreviewing:N,modelValue:P,selectionBlocked:F,onModelSelect:I,showReasoningSection:L,reasoningValue:R,reasoningOptions:z,onReasoningSelect:B,serviceTierOptions:V,serviceTierValue:H,onServiceTierChange:ne,agentSections:re,onAgentOptionChange:U,onStartHandoff:ie}=e,W=g(),G=i?.brandPrefix,K=V.length===1?V[0]:void 0,q=K?`${K.label} mode`:``,J=V.some(e=>e.id===H)?H:h,ae;t[0]===T?ae=t[1]:(ae=()=>{T(!0)},t[0]=T,t[1]=ae);let oe=ae,Y=r||`no-provider`,ce=o?`listbox`:void 0,ye=o?`Models`:void 0,be=!W&&`max-h-64`,X;t[2]===be?X=t[3]:(X=b(`min-h-0 flex-1 overflow-y-auto overscroll-contain px-1 pb-1 pt-0`,be),t[2]=be,t[3]=X);let Z;t[4]===l?Z=t[5]:(Z=l?null:(0,M.jsx)(me,{children:`Model`}),t[4]=l,t[5]=Z);let Q;t[6]!==G||t[7]!==u||t[8]!==m||t[9]!==W||t[10]!==N||t[11]!==_||t[12]!==o||t[13]!==c||t[14]!==d||t[15]!==f||t[16]!==P||t[17]!==S||t[18]!==w||t[19]!==p||t[20]!==I||t[21]!==T||t[22]!==x||t[23]!==oe||t[24]!==s||t[25]!==i||t[26]!==a||t[27]!==F||t[28]!==y?(Q=c?(0,M.jsx)(E,{label:`Loading models`,rowDataAttribute:`data-model-loading-row`}):u?(0,M.jsxs)(M.Fragment,{children:[p.map((e,t)=>{let n=m===t,r=s(t);if(e.kind===`more-toggle`)return(0,M.jsx)(he,{id:r,isActive:n,expanded:y,onToggle:x},`more-toggle`);let i=e.option;return(0,M.jsx)(_e,{id:r,role:o?`option`:void 0,isActive:n,label:O(i.label,G),qualifier:i.routeProviderId,selected:!N&&i.value===P,disabled:F||i.disabled===!0,disabledReason:i.disabledReason,onClick:()=>I(i.value)},i.value)}),!W&&!_&&S.length>0?(0,M.jsx)(ge,{open:w,onOpenChange:T,openSub:oe,activeBrandPrefix:G,isPreviewing:N,modelValue:P,options:S,onSelect:I}):null,_&&p.length===0?(0,M.jsx)(`div`,{className:b(`px-2 text-xs text-muted-foreground`,`py-[0.3125rem] max-md:pointer-coarse:py-2`),children:`No models match your search`}):null]}):(0,M.jsx)(`div`,{className:b(`px-2 text-xs leading-relaxed text-muted-foreground`,`pb-2 pt-1.5 max-md:pointer-coarse:pb-3 max-md:pointer-coarse:pt-2`),title:d?D({error:d,providerLabel:a}):void 0,children:d?(0,M.jsx)(k,{error:d,providerLabel:a,...i?.installUrl===void 0?{}:{installUrl:i.installUrl}}):f?`Could not load models.`:`No models available`}),t[6]=G,t[7]=u,t[8]=m,t[9]=W,t[10]=N,t[11]=_,t[12]=o,t[13]=c,t[14]=d,t[15]=f,t[16]=P,t[17]=S,t[18]=w,t[19]=p,t[20]=I,t[21]=T,t[22]=x,t[23]=oe,t[24]=s,t[25]=i,t[26]=a,t[27]=F,t[28]=y,t[29]=Q):Q=t[29];let xe;t[30]!==n||t[31]!==o||t[32]!==Y||t[33]!==ce||t[34]!==ye||t[35]!==X||t[36]!==Z||t[37]!==Q?(xe=(0,M.jsxs)(`div`,{ref:n,role:ce,id:o,"aria-label":ye,className:X,children:[Z,Q]},Y),t[30]=n,t[31]=o,t[32]=Y,t[33]=ce,t[34]=ye,t[35]=X,t[36]=Z,t[37]=Q,t[38]=xe):xe=t[38];let Se;t[39]!==B||t[40]!==z||t[41]!==R||t[42]!==F||t[43]!==L?(Se=L?(0,M.jsxs)(M.Fragment,{children:[(0,M.jsx)(`div`,{className:`shrink-0 border-t border-border`}),(0,M.jsxs)(`div`,{className:`shrink-0 px-2 py-2.5`,children:[(0,M.jsx)(me,{className:`mb-2 px-1 py-0`,children:`Reasoning`}),(0,M.jsx)(se,{type:`single`,"aria-label":`Reasoning`,value:R,onValueChange:e=>{let t=z.find(t=>t.value===e);t&&B(t.value)},disabled:F,className:`flex gap-1`,children:z.map(pe)})]})]}):null,t[39]=B,t[40]=z,t[41]=R,t[42]=F,t[43]=L,t[44]=Se):Se=t[44];let Ce;t[45]!==ne||t[46]!==J||t[47]!==V||t[48]!==K||t[49]!==q?(Ce=K?(0,M.jsxs)(M.Fragment,{children:[(0,M.jsx)(`div`,{className:`shrink-0 border-t border-border`}),(0,M.jsx)(`div`,{className:`shrink-0 p-1`,children:(0,M.jsxs)(`div`,{className:`flex items-center justify-between gap-3 rounded-sm px-2 py-[0.3125rem] text-xs`,title:K.description,children:[(0,M.jsxs)(`span`,{className:`flex min-w-0 items-center gap-2`,children:[(0,M.jsx)(ee,{name:`Zap`,className:`size-4 fill-current text-muted-foreground`}),(0,M.jsx)(`span`,{children:q})]}),(0,M.jsx)(C,{checked:J===K.id,onCheckedChange:e=>ne(e?K.id:h),"aria-label":q,className:b(v,`[&>span]:size-3.5`)})]})})]}):V.length>1?(0,M.jsxs)(M.Fragment,{children:[(0,M.jsx)(`div`,{className:`shrink-0 border-t border-border`}),(0,M.jsxs)(`div`,{className:`shrink-0 px-2 py-2.5`,children:[(0,M.jsx)(me,{className:`mb-2 px-1 py-0`,children:`Speed`}),(0,M.jsx)(se,{type:`single`,"aria-label":`Speed`,value:J,onValueChange:e=>{(e===`default`||V.some(t=>t.id===e))&&ne(e)},className:`flex flex-wrap gap-1`,children:[{id:h,label:`Default`},...V].map(fe)})]})]}):null,t[45]=ne,t[46]=J,t[47]=V,t[48]=K,t[49]=q,t[50]=Ce):Ce=t[50];let we;if(t[51]!==re||t[52]!==U){let e;t[54]===U?e=t[55]:(e=e=>{let t=e.appliesOnNextTurn?(0,M.jsx)(`span`,{className:`ml-1.5 font-normal text-subtle-foreground`,children:`from the next turn`}):null,n=e.items.find(de);return n===void 0?(0,M.jsxs)(j.Fragment,{children:[(0,M.jsx)(`div`,{className:`shrink-0 border-t border-border`}),(0,M.jsxs)(`div`,{className:`shrink-0 px-2 py-2.5`,children:[(0,M.jsxs)(me,{className:`mb-2 px-1 py-0`,children:[e.label,t]}),(0,M.jsx)(se,{type:`single`,"aria-label":e.label,value:e.items.find(ue)?.key??``,onValueChange:t=>{let n=e.items.find(e=>e.key===t);n!==void 0&&U(e.id,n.value)},className:`flex flex-wrap gap-1`,children:e.items.map(le)})]})]},e.id):(0,M.jsxs)(j.Fragment,{children:[(0,M.jsx)(`div`,{className:`shrink-0 border-t border-border`}),(0,M.jsx)(`div`,{className:`shrink-0 p-1`,children:(0,M.jsxs)(`div`,{className:`flex items-center justify-between gap-3 rounded-sm px-2 py-[0.3125rem] text-xs`,title:e.description??void 0,children:[(0,M.jsxs)(`span`,{className:`min-w-0 truncate`,children:[e.label,t]}),(0,M.jsx)(C,{checked:n.selected,onCheckedChange:t=>U(e.id,t),"aria-label":e.label,className:b(v,`[&>span]:size-3.5`)})]})})]},e.id)},t[54]=U,t[55]=e),we=re.map(e),t[51]=re,t[52]=U,t[53]=we}else we=t[53];let $;t[56]===ie?$=t[57]:($=ie?(0,M.jsxs)(M.Fragment,{children:[(0,M.jsx)(`div`,{className:`shrink-0 border-t border-border`}),(0,M.jsx)(`div`,{className:`shrink-0 p-1`,children:(0,M.jsx)(ve,{label:`Handoff to new thread`,iconName:`MessageSquarePlus`,onClick:ie})})]}):null,t[56]=ie,t[57]=$);let Te;return t[58]!==Se||t[59]!==Ce||t[60]!==we||t[61]!==$||t[62]!==xe?(Te=(0,M.jsx)(te,{children:(0,M.jsxs)(`div`,{className:`flex min-h-0 flex-1 flex-col overflow-hidden`,children:[xe,Se,Ce,we,$]})}),t[58]=Se,t[59]=Ce,t[60]=we,t[61]=$,t[62]=xe,t[63]=Te):Te=t[63],Te}function le(e){return(0,M.jsx)(Y,{value:e.key,title:e.description??void 0,className:b(`h-6 min-w-0 flex-auto shrink-0 whitespace-nowrap rounded-sm px-1 text-xs font-normal shadow-none hover:bg-state-hover hover:text-foreground data-[state=on]:bg-state-active data-[state=on]:text-foreground data-[state=on]:hover:bg-state-active`,`max-md:pointer-coarse:h-9 max-md:pointer-coarse:text-sm`,v),children:e.label},e.key)}function ue(e){return e.selected}function de(e){return e.value===!0}function fe(e){return(0,M.jsx)(Y,{value:e.id,title:e.description,className:b(`h-6 min-w-0 flex-auto shrink-0 whitespace-nowrap rounded-sm px-1 text-xs font-normal shadow-none hover:bg-state-hover hover:text-foreground data-[state=on]:bg-state-active data-[state=on]:text-foreground data-[state=on]:hover:bg-state-active`,`max-md:pointer-coarse:h-9 max-md:pointer-coarse:text-sm`,v),children:e.label},e.id)}function pe(e){return(0,M.jsx)(Y,{value:e.value,"aria-label":e.label,className:b(`h-6 min-w-0 flex-auto shrink-0 whitespace-nowrap rounded-sm px-1 text-xs font-normal shadow-none hover:bg-state-hover hover:text-foreground data-[state=on]:bg-state-active data-[state=on]:text-foreground data-[state=on]:hover:bg-state-active`,`max-md:pointer-coarse:h-9 max-md:pointer-coarse:text-sm`,v),children:e.label===`Medium`||e.label===`Extra High`?(0,M.jsxs)(M.Fragment,{children:[(0,M.jsx)(`span`,{className:`max-[360px]:hidden`,children:e.label}),(0,M.jsx)(`span`,{className:`hidden max-[360px]:inline`,children:e.label===`Medium`?`Med`:`XHigh`})]}):e.label},e.value)}function me(e){let t=(0,A.c)(5),{children:n,className:r}=e,i;t[0]===r?i=t[1]:(i=b(`sticky top-0 z-10 bg-background px-2 text-xs font-medium text-muted-foreground`,`pb-[0.3125rem] pt-2 max-md:pointer-coarse:pb-1.5`,r),t[0]=r,t[1]=i);let a;return t[2]!==n||t[3]!==i?(a=(0,M.jsx)(`div`,{className:i,children:n}),t[2]=n,t[3]=i,t[4]=a):a=t[4],a}function he(e){let t=(0,A.c)(14),{expanded:n,onToggle:r,isActive:i,id:a}=e,{hoverProps:o}=x(),s=i&&`bg-state-active`,c;t[0]===s?c=t[1]:(c=b(`relative flex w-full cursor-default select-none items-center gap-1 rounded-sm px-2 text-xs text-muted-foreground outline-none hover:bg-state-hover hover:text-foreground`,v,_,s,`py-[0.3125rem] max-md:pointer-coarse:py-2`),t[0]=s,t[1]=c);let l=n?`Fewer models`:`More models`,u;t[2]===l?u=t[3]:(u=(0,M.jsx)(`span`,{children:l}),t[2]=l,t[3]=u);let d=n?`ChevronUp`:`ChevronDown`,f;t[4]===d?f=t[5]:(f=(0,M.jsx)(ee,{name:d,className:`size-3.5 shrink-0`}),t[4]=d,t[5]=f);let p;return t[6]!==n||t[7]!==o||t[8]!==a||t[9]!==r||t[10]!==c||t[11]!==u||t[12]!==f?(p=(0,M.jsxs)(`button`,{type:`button`,id:a,onClick:r,"aria-expanded":n,className:c,...o,children:[u,f]}),t[6]=n,t[7]=o,t[8]=a,t[9]=r,t[10]=c,t[11]=u,t[12]=f,t[13]=p):p=t[13],p}function ge(e){let t=(0,A.c)(46),{open:n,onOpenChange:r,openSub:i,activeBrandPrefix:a,isPreviewing:o,modelValue:s,options:c,onSelect:l}=e,{isLastHovered:u,hoverProps:d}=x(),f=(0,j.useRef)(null),h=(0,j.useRef)(null),g;t[0]===Symbol.for(`react.memo_cache_sentinel`)?(g=()=>{window.setTimeout(()=>{h.current?.querySelector(`button`)?.focus()},0)},t[0]=g):g=t[0];let S=g,C,w;t[1]!==u||t[2]!==r||t[3]!==n?(C=()=>{n&&!u&&r(!1)},w=[n,u,r],t[1]=u,t[2]=r,t[3]=n,t[4]=C,t[5]=w):(C=t[4],w=t[5]),(0,j.useEffect)(C,w);let E;t[6]!==d||t[7]!==i?(E=e=>{d.onPointerEnter(e),i()},t[6]=d,t[7]=i,t[8]=E):E=t[8];let D;t[9]!==d||t[10]!==r||t[11]!==i?(D=e=>{if(d.onKeyDown(e),e.key===`Enter`||e.key===` `||e.key===`Spacebar`||e.key===`ArrowRight`){e.preventDefault(),i(),S();return}(e.key===`Escape`||e.key===`ArrowLeft`)&&(e.preventDefault(),r(!1))},t[9]=d,t[10]=r,t[11]=i,t[12]=D):D=t[12];let k;t[13]===Symbol.for(`react.memo_cache_sentinel`)?(k=b(`relative flex w-full cursor-default select-none items-center gap-1 rounded-sm px-2 py-[0.3125rem] text-xs text-muted-foreground outline-none hover:bg-state-hover hover:text-foreground`,v,_),t[13]=k):k=t[13];let N=d[`data-last-hovered`],P,F;t[14]===Symbol.for(`react.memo_cache_sentinel`)?(P=(0,M.jsx)(`span`,{children:`More models`}),F=(0,M.jsx)(ee,{name:`ChevronRight`,className:`size-3.5 shrink-0`}),t[14]=P,t[15]=F):(P=t[14],F=t[15]);let I;t[16]!==n||t[17]!==i||t[18]!==E||t[19]!==D||t[20]!==N?(I=(0,M.jsx)(y,{asChild:!0,children:(0,M.jsxs)(`button`,{ref:f,type:`button`,"aria-haspopup":`menu`,"aria-expanded":n,onClick:i,onPointerEnter:E,onKeyDown:D,className:k,"data-last-hovered":N,children:[P,F]})}),t[16]=n,t[17]=i,t[18]=E,t[19]=D,t[20]=N,t[21]=I):I=t[21];let L;t[22]===Symbol.for(`react.memo_cache_sentinel`)?(L=b(`max-h-[min(20rem,var(--radix-popover-content-available-height),calc(100dvh-0.5rem))] overflow-y-auto overscroll-contain p-1 data-[state=closed]:animate-none`,T),t[22]=L):L=t[22];let R;t[23]===r?R=t[24]:(R=e=>{(e.key===`Escape`||e.key===`ArrowLeft`)&&(e.preventDefault(),r(!1),f.current?.focus())},t[23]=r,t[24]=R);let z;if(t[25]!==a||t[26]!==o||t[27]!==s||t[28]!==l||t[29]!==c){let e;t[31]!==a||t[32]!==o||t[33]!==s||t[34]!==l?(e=e=>(0,M.jsx)(_e,{label:O(e.label,a),qualifier:e.routeProviderId,selected:!o&&e.value===s,onClick:()=>l(e.value)},e.value),t[31]=a,t[32]=o,t[33]=s,t[34]=l,t[35]=e):e=t[35],z=c.map(e),t[25]=a,t[26]=o,t[27]=s,t[28]=l,t[29]=c,t[30]=z}else z=t[30];let B;t[36]===z?B=t[37]:(B=(0,M.jsx)(te,{children:z}),t[36]=z,t[37]=B);let V;t[38]!==R||t[39]!==B?(V=(0,M.jsx)(m,{ref:h,side:`right`,align:`start`,sideOffset:6,className:L,onKeyDown:R,children:B}),t[38]=R,t[39]=B,t[40]=V):V=t[40];let H;return t[41]!==r||t[42]!==n||t[43]!==I||t[44]!==V?(H=(0,M.jsxs)(p,{open:n,onOpenChange:r,children:[I,V]}),t[41]=r,t[42]=n,t[43]=I,t[44]=V,t[45]=H):H=t[45],H}function _e(e){let t=(0,A.c)(28),{label:n,qualifier:r,selected:i,disabled:a,disabledReason:o,onClick:s,isActive:c,id:l,role:u}=e,d=a===void 0?!1:a,{hoverProps:f}=x(),p;t[0]===n?p=t[1]:(p=w(n),t[0]=n,t[1]=p);let{base:m,tag:h}=p,g=u===`option`?!!c:void 0,y=c&&`bg-state-active`,te=d&&`cursor-not-allowed opacity-60`,C;t[2]!==y||t[3]!==te?(C=b(`relative flex w-full cursor-default select-none items-center justify-between gap-3 rounded-sm px-2 text-xs outline-none hover:bg-state-hover hover:text-foreground`,v,_,y,te,`py-[0.3125rem] max-md:pointer-coarse:py-2`),t[2]=y,t[3]=te,t[4]=C):C=t[4];let T=o??(r?`${n} · ${r}`:n),E;t[5]===h?E=t[6]:(E=h?(0,M.jsx)(`span`,{className:`ml-1.5 text-subtle-foreground`,children:h}):null,t[5]=h,t[6]=E);let D;t[7]===r?D=t[8]:(D=r?(0,M.jsx)(`span`,{className:`ml-1.5 text-subtle-foreground`,children:r}):null,t[7]=r,t[8]=D);let O;t[9]!==m||t[10]!==T||t[11]!==E||t[12]!==D?(O=(0,M.jsxs)(`span`,{className:`truncate`,title:T,children:[m,E,D]}),t[9]=m,t[10]=T,t[11]=E,t[12]=D,t[13]=O):O=t[13];let k=i?`opacity-100`:`opacity-0`,j;t[14]===k?j=t[15]:(j=b(S,`text-subtle-foreground`,k),t[14]=k,t[15]=j);let N;t[16]===j?N=t[17]:(N=(0,M.jsx)(`span`,{className:`flex shrink-0 items-center gap-1.5`,children:(0,M.jsx)(ee,{name:`Check`,className:j})}),t[16]=j,t[17]=N);let P;return t[18]!==d||t[19]!==f||t[20]!==l||t[21]!==s||t[22]!==u||t[23]!==O||t[24]!==N||t[25]!==g||t[26]!==C?(P=(0,M.jsxs)(`button`,{type:`button`,id:l,role:u,disabled:d,"aria-selected":g,onClick:s,className:C,...f,children:[O,N]}),t[18]=d,t[19]=f,t[20]=l,t[21]=s,t[22]=u,t[23]=O,t[24]=N,t[25]=g,t[26]=C,t[27]=P):P=t[27],P}function ve(e){let t=(0,A.c)(10),{label:n,iconName:r,onClick:i}=e,{hoverProps:a}=x(),o;t[0]===Symbol.for(`react.memo_cache_sentinel`)?(o=b(`relative flex w-full cursor-default select-none items-center gap-2 rounded-sm px-2 text-xs outline-none hover:bg-state-hover hover:text-foreground`,v,_,`py-[0.3125rem] max-md:pointer-coarse:py-2`),t[0]=o):o=t[0];let s;t[1]===r?s=t[2]:(s=(0,M.jsx)(ee,{name:r,className:`size-3.5 shrink-0`,"aria-hidden":!0}),t[1]=r,t[2]=s);let c;t[3]===n?c=t[4]:(c=(0,M.jsx)(`span`,{className:`min-w-0 truncate`,children:n}),t[3]=n,t[4]=c);let l;return t[5]!==a||t[6]!==i||t[7]!==s||t[8]!==c?(l=(0,M.jsxs)(`button`,{type:`button`,onClick:i,className:o,...a,children:[s,c]}),t[5]=a,t[6]=i,t[7]=s,t[8]=c,t[9]=l):l=t[9],l}export{ce as ModelReasoningMenu};
|
|
1
|
+
import{o as e}from"./rolldown-runtime-BM3Ffeng.js";import{It as t,J as n,Or as r,Qt as i,X as a,Xn as o,Y as s,Yt as c,Z as l,Zt as u,mi as d,ni as f}from"./boot-vendor-BBLG7GwQ.js";import{Aa as p,Ma as m,Q_ as h,Qm as ee,Xf as g,aa as _,ah as v,ja as y,oa as te,oh as b,sa as x,zf as S}from"./index-B-RDC4LU.js";import{t as C}from"./switch-B9nrFpZc.js";import{a as w,i as T,o as E,r as D,s as O,t as k}from"./model-load-error-message-CnA6byT0.js";var A=r(),j=e(d(),1),M=e(f(),1),N=`Toggle`,P=j.forwardRef((e,n)=>{let{pressed:r,defaultPressed:a,onPressedChange:o,...s}=e,[l,u]=t({prop:r,onChange:o,defaultProp:a??!1,caller:N});return(0,M.jsx)(c.button,{type:`button`,"aria-pressed":l,"data-state":l?`on`:`off`,"data-disabled":e.disabled?``:void 0,...s,ref:n,onClick:i(e.onClick,()=>{e.disabled||u(!l)})})});P.displayName=N;var F=P,I=`ToggleGroup`,[L,R]=u(I,[a]),z=a(),B=j.forwardRef((e,t)=>{let{type:n,...r}=e;if(n===`single`)return(0,M.jsx)(ne,{role:`radiogroup`,...r,ref:t});if(n===`multiple`)return(0,M.jsx)(re,{role:`toolbar`,...r,ref:t});throw Error(`Missing prop \`type\` expected on \`${I}\``)});B.displayName=I;var[V,H]=L(I),ne=j.forwardRef((e,n)=>{let{value:r,defaultValue:i,onValueChange:a=()=>{},...o}=e,[s,c]=t({prop:r,defaultProp:i??``,onChange:a,caller:I});return(0,M.jsx)(V,{scope:e.__scopeToggleGroup,type:`single`,value:j.useMemo(()=>s?[s]:[],[s]),onItemActivate:c,onItemDeactivate:j.useCallback(()=>c(``),[c]),children:(0,M.jsx)(W,{...o,ref:n})})}),re=j.forwardRef((e,n)=>{let{value:r,defaultValue:i,onValueChange:a=()=>{},...o}=e,[s,c]=t({prop:r,defaultProp:i??[],onChange:a,caller:I}),l=j.useCallback(e=>c((t=[])=>[...t,e]),[c]),u=j.useCallback(e=>c((t=[])=>t.filter(t=>t!==e)),[c]);return(0,M.jsx)(V,{scope:e.__scopeToggleGroup,type:`multiple`,value:s,onItemActivate:l,onItemDeactivate:u,children:(0,M.jsx)(W,{...o,ref:n})})});B.displayName=I;var[U,ie]=L(I),W=j.forwardRef((e,t)=>{let{__scopeToggleGroup:n,disabled:r=!1,rovingFocus:i=!0,orientation:a,dir:o,loop:u=!0,...d}=e,f=z(n),p=l(o),m={dir:p,...d};return(0,M.jsx)(U,{scope:n,rovingFocus:i,disabled:r,children:i?(0,M.jsx)(s,{asChild:!0,...f,orientation:a,dir:p,loop:u,children:(0,M.jsx)(c.div,{...m,ref:t})}):(0,M.jsx)(c.div,{...m,ref:t})})}),G=`ToggleGroupItem`,K=j.forwardRef((e,t)=>{let r=H(G,e.__scopeToggleGroup),i=ie(G,e.__scopeToggleGroup),a=z(e.__scopeToggleGroup),o=r.value.includes(e.value),s=i.disabled||e.disabled,c={...e,pressed:o,disabled:s},l=j.useRef(null);return i.rovingFocus?(0,M.jsx)(n,{asChild:!0,...a,focusable:!s,active:o,ref:l,children:(0,M.jsx)(q,{...c,ref:t})}):(0,M.jsx)(q,{...c,ref:t})});K.displayName=G;var q=j.forwardRef((e,t)=>{let{__scopeToggleGroup:n,value:r,...i}=e,a=H(G,n),o={role:`radio`,"aria-checked":e.pressed,"aria-pressed":void 0};return(0,M.jsx)(P,{...a.type===`single`?o:void 0,...i,ref:t,onPressedChange:e=>{e?a.onItemActivate(r):a.onItemDeactivate(r)}})}),J=o(`inline-flex items-center justify-center gap-2 rounded-md text-sm font-medium transition-colors hover:bg-muted hover:text-muted-foreground focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:pointer-events-none disabled:opacity-50 data-[state=on]:bg-accent data-[state=on]:text-accent-foreground [&_[data-icon-root]]:pointer-events-none [&_[data-icon-root]]:size-4 [&_[data-icon-root]]:shrink-0`,{variants:{variant:{default:`bg-transparent`,outline:`border border-input bg-transparent shadow-sm hover:bg-accent hover:text-accent-foreground`},size:{default:`h-9 px-2 min-w-9`,sm:`h-8 px-1.5 min-w-8`,lg:`h-10 px-2.5 min-w-10`}},defaultVariants:{variant:`default`,size:`default`}}),ae=j.forwardRef((e,t)=>{let n=(0,A.c)(13),r,i,a,o;n[0]===e?(r=n[1],i=n[2],a=n[3],o=n[4]):({className:r,variant:o,size:a,...i}=e,n[0]=e,n[1]=r,n[2]=i,n[3]=a,n[4]=o);let s;n[5]!==r||n[6]!==a||n[7]!==o?(s=b(J({variant:o,size:a,className:r})),n[5]=r,n[6]=a,n[7]=o,n[8]=s):s=n[8];let c;return n[9]!==i||n[10]!==t||n[11]!==s?(c=(0,M.jsx)(F,{ref:t,className:s,...i}),n[9]=i,n[10]=t,n[11]=s,n[12]=c):c=n[12],c});ae.displayName=F.displayName;var oe=j.createContext({size:`default`,variant:`default`}),se=j.forwardRef((e,t)=>{let n=(0,A.c)(19),r,i,a,o,s;n[0]===e?(r=n[1],i=n[2],a=n[3],o=n[4],s=n[5]):({className:i,variant:s,size:o,children:r,...a}=e,n[0]=e,n[1]=r,n[2]=i,n[3]=a,n[4]=o,n[5]=s);let c;n[6]===i?c=n[7]:(c=b(`flex items-center justify-center gap-1`,i),n[6]=i,n[7]=c);let l;n[8]!==o||n[9]!==s?(l={variant:s,size:o},n[8]=o,n[9]=s,n[10]=l):l=n[10];let u;n[11]!==r||n[12]!==l?(u=(0,M.jsx)(oe.Provider,{value:l,children:r}),n[11]=r,n[12]=l,n[13]=u):u=n[13];let d;return n[14]!==a||n[15]!==t||n[16]!==c||n[17]!==u?(d=(0,M.jsx)(B,{ref:t,className:c,...a,children:u}),n[14]=a,n[15]=t,n[16]=c,n[17]=u,n[18]=d):d=n[18],d});se.displayName=B.displayName;var Y=j.forwardRef((e,t)=>{let n=(0,A.c)(17),r,i,a,o,s;n[0]===e?(r=n[1],i=n[2],a=n[3],o=n[4],s=n[5]):({className:i,children:r,variant:s,size:o,...a}=e,n[0]=e,n[1]=r,n[2]=i,n[3]=a,n[4]=o,n[5]=s);let c=j.useContext(oe),l;n[6]!==i||n[7]!==c.size||n[8]!==c.variant||n[9]!==o||n[10]!==s?(l=b(J({variant:c.variant||s,size:c.size||o}),i),n[6]=i,n[7]=c.size,n[8]=c.variant,n[9]=o,n[10]=s,n[11]=l):l=n[11];let u;return n[12]!==r||n[13]!==a||n[14]!==t||n[15]!==l?(u=(0,M.jsx)(K,{ref:t,className:l,...a,children:r}),n[12]=r,n[13]=a,n[14]=t,n[15]=l,n[16]=u):u=n[16],u});Y.displayName=K.displayName;function ce(e){let t=(0,A.c)(64),{listRef:n,providerId:r,provider:i,providerLabel:a,listboxId:o,optionId:s,modelIsLoading:c,isShowingModelError:l,hasModelOptions:u,modelLoadError:d,modelLoadFailed:f,navRows:p,highlightedIndex:m,isSearching:_,showMoreModels:y,onToggleMoreModels:x,moreModelOptions:S,moreModelsOpen:w,onMoreModelsOpenChange:T,isPreviewing:N,modelValue:P,selectionBlocked:F,onModelSelect:I,showReasoningSection:L,reasoningValue:R,reasoningOptions:z,onReasoningSelect:B,serviceTierOptions:V,serviceTierValue:H,onServiceTierChange:ne,agentSections:re,onAgentOptionChange:U,onStartHandoff:ie}=e,W=g(),G=i?.brandPrefix,K=V.length===1?V[0]:void 0,q=K?`${K.label} mode`:``,J=V.some(e=>e.id===H)?H:h,ae;t[0]===T?ae=t[1]:(ae=()=>{T(!0)},t[0]=T,t[1]=ae);let oe=ae,Y=r||`no-provider`,ce=o?`listbox`:void 0,ye=o?`Models`:void 0,be=!W&&`max-h-64`,X;t[2]===be?X=t[3]:(X=b(`min-h-0 flex-1 overflow-y-auto overscroll-contain px-1 pb-1 pt-0`,be),t[2]=be,t[3]=X);let Z;t[4]===l?Z=t[5]:(Z=l?null:(0,M.jsx)(me,{children:`Model`}),t[4]=l,t[5]=Z);let Q;t[6]!==G||t[7]!==u||t[8]!==m||t[9]!==W||t[10]!==N||t[11]!==_||t[12]!==o||t[13]!==c||t[14]!==d||t[15]!==f||t[16]!==P||t[17]!==S||t[18]!==w||t[19]!==p||t[20]!==I||t[21]!==T||t[22]!==x||t[23]!==oe||t[24]!==s||t[25]!==i||t[26]!==a||t[27]!==F||t[28]!==y?(Q=c?(0,M.jsx)(E,{label:`Loading models`,rowDataAttribute:`data-model-loading-row`}):u?(0,M.jsxs)(M.Fragment,{children:[p.map((e,t)=>{let n=m===t,r=s(t);if(e.kind===`more-toggle`)return(0,M.jsx)(he,{id:r,isActive:n,expanded:y,onToggle:x},`more-toggle`);let i=e.option;return(0,M.jsx)(_e,{id:r,role:o?`option`:void 0,isActive:n,label:O(i.label,G),qualifier:i.routeProviderId,selected:!N&&i.value===P,disabled:F||i.disabled===!0,disabledReason:i.disabledReason,onClick:()=>I(i.value)},i.value)}),!W&&!_&&S.length>0?(0,M.jsx)(ge,{open:w,onOpenChange:T,openSub:oe,activeBrandPrefix:G,isPreviewing:N,modelValue:P,options:S,onSelect:I}):null,_&&p.length===0?(0,M.jsx)(`div`,{className:b(`px-2 text-xs text-muted-foreground`,`py-[0.3125rem] max-md:pointer-coarse:py-2`),children:`No models match your search`}):null]}):(0,M.jsx)(`div`,{className:b(`px-2 text-xs leading-relaxed text-muted-foreground`,`pb-2 pt-1.5 max-md:pointer-coarse:pb-3 max-md:pointer-coarse:pt-2`),title:d?D({error:d,providerLabel:a}):void 0,children:d?(0,M.jsx)(k,{error:d,providerLabel:a,...i?.installUrl===void 0?{}:{installUrl:i.installUrl}}):f?`Could not load models.`:`No models available`}),t[6]=G,t[7]=u,t[8]=m,t[9]=W,t[10]=N,t[11]=_,t[12]=o,t[13]=c,t[14]=d,t[15]=f,t[16]=P,t[17]=S,t[18]=w,t[19]=p,t[20]=I,t[21]=T,t[22]=x,t[23]=oe,t[24]=s,t[25]=i,t[26]=a,t[27]=F,t[28]=y,t[29]=Q):Q=t[29];let xe;t[30]!==n||t[31]!==o||t[32]!==Y||t[33]!==ce||t[34]!==ye||t[35]!==X||t[36]!==Z||t[37]!==Q?(xe=(0,M.jsxs)(`div`,{ref:n,role:ce,id:o,"aria-label":ye,className:X,children:[Z,Q]},Y),t[30]=n,t[31]=o,t[32]=Y,t[33]=ce,t[34]=ye,t[35]=X,t[36]=Z,t[37]=Q,t[38]=xe):xe=t[38];let Se;t[39]!==B||t[40]!==z||t[41]!==R||t[42]!==F||t[43]!==L?(Se=L?(0,M.jsxs)(M.Fragment,{children:[(0,M.jsx)(`div`,{className:`shrink-0 border-t border-border`}),(0,M.jsxs)(`div`,{className:`shrink-0 px-2 py-2.5`,children:[(0,M.jsx)(me,{className:`mb-2 px-1 py-0`,children:`Reasoning`}),(0,M.jsx)(se,{type:`single`,"aria-label":`Reasoning`,value:R,onValueChange:e=>{let t=z.find(t=>t.value===e);t&&B(t.value)},disabled:F,className:`flex gap-1`,children:z.map(pe)})]})]}):null,t[39]=B,t[40]=z,t[41]=R,t[42]=F,t[43]=L,t[44]=Se):Se=t[44];let Ce;t[45]!==ne||t[46]!==J||t[47]!==V||t[48]!==K||t[49]!==q?(Ce=K?(0,M.jsxs)(M.Fragment,{children:[(0,M.jsx)(`div`,{className:`shrink-0 border-t border-border`}),(0,M.jsx)(`div`,{className:`shrink-0 p-1`,children:(0,M.jsxs)(`div`,{className:`flex items-center justify-between gap-3 rounded-sm px-2 py-[0.3125rem] text-xs`,title:K.description,children:[(0,M.jsxs)(`span`,{className:`flex min-w-0 items-center gap-2`,children:[(0,M.jsx)(ee,{name:`Zap`,className:`size-4 fill-current text-muted-foreground`}),(0,M.jsx)(`span`,{children:q})]}),(0,M.jsx)(C,{checked:J===K.id,onCheckedChange:e=>ne(e?K.id:h),"aria-label":q,className:b(v,`[&>span]:size-3.5`)})]})})]}):V.length>1?(0,M.jsxs)(M.Fragment,{children:[(0,M.jsx)(`div`,{className:`shrink-0 border-t border-border`}),(0,M.jsxs)(`div`,{className:`shrink-0 px-2 py-2.5`,children:[(0,M.jsx)(me,{className:`mb-2 px-1 py-0`,children:`Speed`}),(0,M.jsx)(se,{type:`single`,"aria-label":`Speed`,value:J,onValueChange:e=>{(e===`default`||V.some(t=>t.id===e))&&ne(e)},className:`flex flex-wrap gap-1`,children:[{id:h,label:`Default`},...V].map(fe)})]})]}):null,t[45]=ne,t[46]=J,t[47]=V,t[48]=K,t[49]=q,t[50]=Ce):Ce=t[50];let we;if(t[51]!==re||t[52]!==U){let e;t[54]===U?e=t[55]:(e=e=>{let t=e.appliesOnNextTurn?(0,M.jsx)(`span`,{className:`ml-1.5 font-normal text-subtle-foreground`,children:`from the next turn`}):null,n=e.items.find(de);return n===void 0?(0,M.jsxs)(j.Fragment,{children:[(0,M.jsx)(`div`,{className:`shrink-0 border-t border-border`}),(0,M.jsxs)(`div`,{className:`shrink-0 px-2 py-2.5`,children:[(0,M.jsxs)(me,{className:`mb-2 px-1 py-0`,children:[e.label,t]}),(0,M.jsx)(se,{type:`single`,"aria-label":e.label,value:e.items.find(ue)?.key??``,onValueChange:t=>{let n=e.items.find(e=>e.key===t);n!==void 0&&U(e.id,n.value)},className:`flex flex-wrap gap-1`,children:e.items.map(le)})]})]},e.id):(0,M.jsxs)(j.Fragment,{children:[(0,M.jsx)(`div`,{className:`shrink-0 border-t border-border`}),(0,M.jsx)(`div`,{className:`shrink-0 p-1`,children:(0,M.jsxs)(`div`,{className:`flex items-center justify-between gap-3 rounded-sm px-2 py-[0.3125rem] text-xs`,title:e.description??void 0,children:[(0,M.jsxs)(`span`,{className:`min-w-0 truncate`,children:[e.label,t]}),(0,M.jsx)(C,{checked:n.selected,onCheckedChange:t=>U(e.id,t),"aria-label":e.label,className:b(v,`[&>span]:size-3.5`)})]})})]},e.id)},t[54]=U,t[55]=e),we=re.map(e),t[51]=re,t[52]=U,t[53]=we}else we=t[53];let $;t[56]===ie?$=t[57]:($=ie?(0,M.jsxs)(M.Fragment,{children:[(0,M.jsx)(`div`,{className:`shrink-0 border-t border-border`}),(0,M.jsx)(`div`,{className:`shrink-0 p-1`,children:(0,M.jsx)(ve,{label:`Handoff to new thread`,iconName:`MessageSquarePlus`,onClick:ie})})]}):null,t[56]=ie,t[57]=$);let Te;return t[58]!==Se||t[59]!==Ce||t[60]!==we||t[61]!==$||t[62]!==xe?(Te=(0,M.jsx)(te,{children:(0,M.jsxs)(`div`,{className:`flex min-h-0 flex-1 flex-col overflow-hidden`,children:[xe,Se,Ce,we,$]})}),t[58]=Se,t[59]=Ce,t[60]=we,t[61]=$,t[62]=xe,t[63]=Te):Te=t[63],Te}function le(e){return(0,M.jsx)(Y,{value:e.key,title:e.description??void 0,className:b(`h-6 min-w-0 flex-auto shrink-0 whitespace-nowrap rounded-sm px-1 text-xs font-normal shadow-none hover:bg-state-hover hover:text-foreground data-[state=on]:bg-state-active data-[state=on]:text-foreground data-[state=on]:hover:bg-state-active`,`max-md:pointer-coarse:h-9 max-md:pointer-coarse:text-sm`,v),children:e.label},e.key)}function ue(e){return e.selected}function de(e){return e.value===!0}function fe(e){return(0,M.jsx)(Y,{value:e.id,title:e.description,className:b(`h-6 min-w-0 flex-auto shrink-0 whitespace-nowrap rounded-sm px-1 text-xs font-normal shadow-none hover:bg-state-hover hover:text-foreground data-[state=on]:bg-state-active data-[state=on]:text-foreground data-[state=on]:hover:bg-state-active`,`max-md:pointer-coarse:h-9 max-md:pointer-coarse:text-sm`,v),children:e.label},e.id)}function pe(e){return(0,M.jsx)(Y,{value:e.value,"aria-label":e.label,className:b(`h-6 min-w-0 flex-auto shrink-0 whitespace-nowrap rounded-sm px-1 text-xs font-normal shadow-none hover:bg-state-hover hover:text-foreground data-[state=on]:bg-state-active data-[state=on]:text-foreground data-[state=on]:hover:bg-state-active`,`max-md:pointer-coarse:h-9 max-md:pointer-coarse:text-sm`,v),children:e.label===`Medium`||e.label===`Extra High`?(0,M.jsxs)(M.Fragment,{children:[(0,M.jsx)(`span`,{className:`max-[360px]:hidden`,children:e.label}),(0,M.jsx)(`span`,{className:`hidden max-[360px]:inline`,children:e.label===`Medium`?`Med`:`XHigh`})]}):e.label},e.value)}function me(e){let t=(0,A.c)(5),{children:n,className:r}=e,i;t[0]===r?i=t[1]:(i=b(`sticky top-0 z-10 bg-background px-2 text-xs font-medium text-muted-foreground`,`pb-[0.3125rem] pt-2 max-md:pointer-coarse:pb-1.5`,r),t[0]=r,t[1]=i);let a;return t[2]!==n||t[3]!==i?(a=(0,M.jsx)(`div`,{className:i,children:n}),t[2]=n,t[3]=i,t[4]=a):a=t[4],a}function he(e){let t=(0,A.c)(14),{expanded:n,onToggle:r,isActive:i,id:a}=e,{hoverProps:o}=x(),s=i&&`bg-state-active`,c;t[0]===s?c=t[1]:(c=b(`relative flex w-full cursor-default select-none items-center gap-1 rounded-sm px-2 text-xs text-muted-foreground outline-none hover:bg-state-hover hover:text-foreground`,v,_,s,`py-[0.3125rem] max-md:pointer-coarse:py-2`),t[0]=s,t[1]=c);let l=n?`Fewer models`:`More models`,u;t[2]===l?u=t[3]:(u=(0,M.jsx)(`span`,{children:l}),t[2]=l,t[3]=u);let d=n?`ChevronUp`:`ChevronDown`,f;t[4]===d?f=t[5]:(f=(0,M.jsx)(ee,{name:d,className:`size-3.5 shrink-0`}),t[4]=d,t[5]=f);let p;return t[6]!==n||t[7]!==o||t[8]!==a||t[9]!==r||t[10]!==c||t[11]!==u||t[12]!==f?(p=(0,M.jsxs)(`button`,{type:`button`,id:a,onClick:r,"aria-expanded":n,className:c,...o,children:[u,f]}),t[6]=n,t[7]=o,t[8]=a,t[9]=r,t[10]=c,t[11]=u,t[12]=f,t[13]=p):p=t[13],p}function ge(e){let t=(0,A.c)(46),{open:n,onOpenChange:r,openSub:i,activeBrandPrefix:a,isPreviewing:o,modelValue:s,options:c,onSelect:l}=e,{isLastHovered:u,hoverProps:d}=x(),f=(0,j.useRef)(null),h=(0,j.useRef)(null),g;t[0]===Symbol.for(`react.memo_cache_sentinel`)?(g=()=>{window.setTimeout(()=>{h.current?.querySelector(`button`)?.focus()},0)},t[0]=g):g=t[0];let S=g,C,w;t[1]!==u||t[2]!==r||t[3]!==n?(C=()=>{n&&!u&&r(!1)},w=[n,u,r],t[1]=u,t[2]=r,t[3]=n,t[4]=C,t[5]=w):(C=t[4],w=t[5]),(0,j.useEffect)(C,w);let E;t[6]!==d||t[7]!==i?(E=e=>{d.onPointerEnter(e),i()},t[6]=d,t[7]=i,t[8]=E):E=t[8];let D;t[9]!==d||t[10]!==r||t[11]!==i?(D=e=>{if(d.onKeyDown(e),e.key===`Enter`||e.key===` `||e.key===`Spacebar`||e.key===`ArrowRight`){e.preventDefault(),i(),S();return}(e.key===`Escape`||e.key===`ArrowLeft`)&&(e.preventDefault(),r(!1))},t[9]=d,t[10]=r,t[11]=i,t[12]=D):D=t[12];let k;t[13]===Symbol.for(`react.memo_cache_sentinel`)?(k=b(`relative flex w-full cursor-default select-none items-center gap-1 rounded-sm px-2 py-[0.3125rem] text-xs text-muted-foreground outline-none hover:bg-state-hover hover:text-foreground`,v,_),t[13]=k):k=t[13];let N=d[`data-last-hovered`],P,F;t[14]===Symbol.for(`react.memo_cache_sentinel`)?(P=(0,M.jsx)(`span`,{children:`More models`}),F=(0,M.jsx)(ee,{name:`ChevronRight`,className:`size-3.5 shrink-0`}),t[14]=P,t[15]=F):(P=t[14],F=t[15]);let I;t[16]!==n||t[17]!==i||t[18]!==E||t[19]!==D||t[20]!==N?(I=(0,M.jsx)(y,{asChild:!0,children:(0,M.jsxs)(`button`,{ref:f,type:`button`,"aria-haspopup":`menu`,"aria-expanded":n,onClick:i,onPointerEnter:E,onKeyDown:D,className:k,"data-last-hovered":N,children:[P,F]})}),t[16]=n,t[17]=i,t[18]=E,t[19]=D,t[20]=N,t[21]=I):I=t[21];let L;t[22]===Symbol.for(`react.memo_cache_sentinel`)?(L=b(`max-h-[min(20rem,var(--radix-popover-content-available-height),calc(100dvh-0.5rem))] overflow-y-auto overscroll-contain p-1 data-[state=closed]:animate-none`,T),t[22]=L):L=t[22];let R;t[23]===r?R=t[24]:(R=e=>{(e.key===`Escape`||e.key===`ArrowLeft`)&&(e.preventDefault(),r(!1),f.current?.focus())},t[23]=r,t[24]=R);let z;if(t[25]!==a||t[26]!==o||t[27]!==s||t[28]!==l||t[29]!==c){let e;t[31]!==a||t[32]!==o||t[33]!==s||t[34]!==l?(e=e=>(0,M.jsx)(_e,{label:O(e.label,a),qualifier:e.routeProviderId,selected:!o&&e.value===s,onClick:()=>l(e.value)},e.value),t[31]=a,t[32]=o,t[33]=s,t[34]=l,t[35]=e):e=t[35],z=c.map(e),t[25]=a,t[26]=o,t[27]=s,t[28]=l,t[29]=c,t[30]=z}else z=t[30];let B;t[36]===z?B=t[37]:(B=(0,M.jsx)(te,{children:z}),t[36]=z,t[37]=B);let V;t[38]!==R||t[39]!==B?(V=(0,M.jsx)(m,{ref:h,side:`right`,align:`start`,sideOffset:6,className:L,onKeyDown:R,children:B}),t[38]=R,t[39]=B,t[40]=V):V=t[40];let H;return t[41]!==r||t[42]!==n||t[43]!==I||t[44]!==V?(H=(0,M.jsxs)(p,{open:n,onOpenChange:r,children:[I,V]}),t[41]=r,t[42]=n,t[43]=I,t[44]=V,t[45]=H):H=t[45],H}function _e(e){let t=(0,A.c)(28),{label:n,qualifier:r,selected:i,disabled:a,disabledReason:o,onClick:s,isActive:c,id:l,role:u}=e,d=a===void 0?!1:a,{hoverProps:f}=x(),p;t[0]===n?p=t[1]:(p=w(n),t[0]=n,t[1]=p);let{base:m,tag:h}=p,g=u===`option`?!!c:void 0,y=c&&`bg-state-active`,te=d&&`cursor-not-allowed opacity-60`,C;t[2]!==y||t[3]!==te?(C=b(`relative flex w-full cursor-default select-none items-center justify-between gap-3 rounded-sm px-2 text-xs outline-none hover:bg-state-hover hover:text-foreground`,v,_,y,te,`py-[0.3125rem] max-md:pointer-coarse:py-2`),t[2]=y,t[3]=te,t[4]=C):C=t[4];let T=o??(r?`${n} · ${r}`:n),E;t[5]===h?E=t[6]:(E=h?(0,M.jsx)(`span`,{className:`ml-1.5 text-subtle-foreground`,children:h}):null,t[5]=h,t[6]=E);let D;t[7]===r?D=t[8]:(D=r?(0,M.jsx)(`span`,{className:`ml-1.5 text-subtle-foreground`,children:r}):null,t[7]=r,t[8]=D);let O;t[9]!==m||t[10]!==T||t[11]!==E||t[12]!==D?(O=(0,M.jsxs)(`span`,{className:`truncate`,title:T,children:[m,E,D]}),t[9]=m,t[10]=T,t[11]=E,t[12]=D,t[13]=O):O=t[13];let k=i?`opacity-100`:`opacity-0`,j;t[14]===k?j=t[15]:(j=b(S,`text-subtle-foreground`,k),t[14]=k,t[15]=j);let N;t[16]===j?N=t[17]:(N=(0,M.jsx)(`span`,{className:`flex shrink-0 items-center gap-1.5`,children:(0,M.jsx)(ee,{name:`Check`,className:j})}),t[16]=j,t[17]=N);let P;return t[18]!==d||t[19]!==f||t[20]!==l||t[21]!==s||t[22]!==u||t[23]!==O||t[24]!==N||t[25]!==g||t[26]!==C?(P=(0,M.jsxs)(`button`,{type:`button`,id:l,role:u,disabled:d,"aria-selected":g,onClick:s,className:C,...f,children:[O,N]}),t[18]=d,t[19]=f,t[20]=l,t[21]=s,t[22]=u,t[23]=O,t[24]=N,t[25]=g,t[26]=C,t[27]=P):P=t[27],P}function ve(e){let t=(0,A.c)(10),{label:n,iconName:r,onClick:i}=e,{hoverProps:a}=x(),o;t[0]===Symbol.for(`react.memo_cache_sentinel`)?(o=b(`relative flex w-full cursor-default select-none items-center gap-2 rounded-sm px-2 text-xs outline-none hover:bg-state-hover hover:text-foreground`,v,_,`py-[0.3125rem] max-md:pointer-coarse:py-2`),t[0]=o):o=t[0];let s;t[1]===r?s=t[2]:(s=(0,M.jsx)(ee,{name:r,className:`size-3.5 shrink-0`,"aria-hidden":!0}),t[1]=r,t[2]=s);let c;t[3]===n?c=t[4]:(c=(0,M.jsx)(`span`,{className:`min-w-0 truncate`,children:n}),t[3]=n,t[4]=c);let l;return t[5]!==a||t[6]!==i||t[7]!==s||t[8]!==c?(l=(0,M.jsxs)(`button`,{type:`button`,onClick:i,className:o,...a,children:[s,c]}),t[5]=a,t[6]=i,t[7]=s,t[8]=c,t[9]=l):l=t[9],l}export{ce as ModelReasoningMenu};
|
|
Binary file
|
|
Binary file
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{o as e}from"./rolldown-runtime-BM3Ffeng.js";import{Ct as t,Or as n,St as r,bt as i,mi as a,ni as o}from"./boot-vendor-BBLG7GwQ.js";import{t as s}from"./timeline-path-display-DZ8kKRyF.js";import{$a as c,Gl as l,Ki as u,Mu as d,Nf as f,Pf as p,Qm as m,Rf as h,Sa as g,ah as _,ff as v,hn as y,oh as b,pn as x,qf as S,qi as C,uc as w}from"./index-BBxUiLNy.js";import{t as T}from"./truncate-start-CaCnKnh9.js";import{n as E}from"./threadRecentItems-DI2mgj7S.js";import{t as D}from"./usePathSuggestions-DkeFAE7l.js";import{t as O}from"./AppCommandShortcutHint-BlXOfa_n.js";import{o as k,s as ee,t as A}from"./sortable.esm-DrqbbDDw.js";import{a as j,i as M,n as te,r as N,t as ne}from"./launcherRow-rIW7Z6Xm.js";import{n as P,t as re}from"./use-reorder-dnd-B-xEV6w8.js";import{n as F,t as I}from"./rightPanelFileVisuals-bs9QP9_p.js";var L=n(),ie=`bb.newTab.actionOrder`;function ae(e){return Array.isArray(e)&&e.every(e=>typeof e==`string`)}var oe=i(ie,[],d(ae),{getOnInit:!0}),R=e(o(),1),se=`Actions`,ce=`relative cursor-grab touch-none opacity-0 transition-opacity focus-visible:opacity-100 focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring active:cursor-grabbing group-hover:opacity-100 [@media(hover:none)]:opacity-100`,z=`file-search-result-open-browser`,le=`file-search-result-start-terminal`;function ue(e){return(0,R.jsx)(m,{name:e,className:f,"aria-hidden":!0})}function de(e){let n=(0,L.c)(15),{onOpenBrowser:r,onStartTerminal:i,pluginActions:a,startTerminalDisabled:o,startTerminalTrailing:s}=e,u=o===void 0?!1:o,d=t(oe),p=c(`terminal.open`),m;n[0]===r?m=n[1]:(m=r!==void 0&&v(),n[0]=r,n[1]=m);let h=m,g;if(n[2]!==r||n[3]!==i||n[4]!==a||n[5]!==h||n[6]!==u||n[7]!==s||n[8]!==d||n[9]!==p){let e=[];if(h){let t;n[11]===r?t=n[12]:(t=()=>r?.(),n[11]=r,n[12]=t),e.push({id:z,icon:ue(`Globe`),label:`Open browser`,disabled:!1,shortcut:null,trailing:null,onSelect:t})}if(i!==void 0){let t;n[13]===i?t=n[14]:(t=()=>i(),n[13]=i,n[14]=t),e.push({id:le,icon:ue(`Terminal`),label:`Start terminal`,disabled:u,shortcut:p,trailing:s??null,onSelect:t})}for(let t of a??[])e.push({id:t.id,icon:(0,R.jsx)(l,{pluginId:t.pluginId,icon:t.icon,className:f}),label:t.title,tooltip:t.tooltip,disabled:!1,shortcut:null,trailing:null,onSelect:t.onSelect});g=x({items:e,getId:fe,storedOrder:d}),n[2]=r,n[3]=i,n[4]=a,n[5]=h,n[6]=u,n[7]=s,n[8]=d,n[9]=p,n[10]=g}else g=n[10];return g.ordered}function fe(e){return e.id}function B(e){return e.toLowerCase().split(/[^\p{L}\p{N}]+/u).filter(e=>e.length>0)}function pe(e,t){let n=B(t);return n.length===0?[]:e.filter(e=>{let t=B(e.label);return n.every(e=>t.some(t=>t.startsWith(e)))})}function me(e){let t=(0,L.c)(3),{actions:n}=e;if(n.length===0)return null;let r;t[0]===Symbol.for(`react.memo_cache_sentinel`)?(r=(0,R.jsx)(j,{label:se,className:`pb-1`}),t[0]=r):r=t[0];let i;return t[1]===n?i=t[2]:(i=(0,R.jsx)(`div`,{"data-testid":`new-tab-actions`,className:`flex min-w-0 flex-col`,children:(0,R.jsxs)(`section`,{children:[r,(0,R.jsx)(he,{actions:n})]})}),t[1]=n,t[2]=i),i}function he(e){let t=(0,L.c)(11),{actions:n}=e,[i,a]=r(oe),o;t[0]!==n||t[1]!==i?(o=x({items:n,getId:_e,storedOrder:i}),t[0]=n,t[1]=i,t[2]=o):o=t[2];let{normalizedOrder:s}=o;if(n.length<2){let e;t[3]===n?e=t[4]:(e=n.map(ge),t[3]=n,t[4]=e);let r;return t[5]===e?r=t[6]:(r=(0,R.jsx)(`div`,{className:`flex flex-col gap-px`,children:e}),t[5]=e,t[6]=r),r}let c;return t[7]!==n||t[8]!==s||t[9]!==a?(c=(0,R.jsx)(ve,{actions:n,normalizedOrder:s,onOrderChange:a}),t[7]=n,t[8]=s,t[9]=a,t[10]=c):c=t[10],c}function ge(e){return(0,R.jsx)(U,{action:e},e.id)}function _e(e){return e.id}function ve(e){let t=(0,L.c)(19),{actions:n,normalizedOrder:r,onOrderChange:i}=e,a;t[0]===n?a=t[1]:(a=n.map(ye),t[0]=n,t[1]=a);let o=a,s;t[2]!==r||t[3]!==i||t[4]!==o?(s=e=>{if(!e.over||typeof e.active.id!=`string`||typeof e.over.id!=`string`)return;let t=y({activeId:e.active.id,overId:e.over.id,order:r,visibleIds:o});t&&i(t)},t[2]=r,t[3]=i,t[4]=o,t[5]=s):s=t[5];let c=s,l;t[6]===c?l=t[7]:(l={onDragEnd:c},t[6]=c,t[7]=l);let{dndContextProps:u,onClickCapture:d}=re(l),f;t[8]===n?f=t[9]:(f=n.map(V),t[8]=n,t[9]=f);let p;t[10]!==d||t[11]!==f?(p=(0,R.jsx)(`div`,{className:`flex flex-col gap-px`,onClickCapture:d,children:f}),t[10]=d,t[11]=f,t[12]=p):p=t[12];let m;t[13]!==o||t[14]!==p?(m=(0,R.jsx)(A,{items:o,strategy:k,children:p}),t[13]=o,t[14]=p,t[15]=m):m=t[15];let h;return t[16]!==u||t[17]!==m?(h=(0,R.jsx)(ee,{...u,children:m}),t[16]=u,t[17]=m,t[18]=h):h=t[18],h}function V(e){return(0,R.jsx)(H,{action:e},e.id)}function ye(e){return e.id}function H(e){let t=(0,L.c)(16),{action:n}=e,r;t[0]===n.id?r=t[1]:(r={id:n.id,disabled:!1},t[0]=n.id,t[1]=r);let{dragBindings:i,setNodeRef:a,style:o}=P(r),{attributes:s,listeners:c,setActivatorNodeRef:l}=i,u=`Reorder ${n.label}`,d;t[2]===Symbol.for(`react.memo_cache_sentinel`)?(d=b(N,ce),t[2]=d):d=t[2];let p;t[3]===Symbol.for(`react.memo_cache_sentinel`)?(p=(0,R.jsx)(m,{name:`DragDropVertical`,className:f,"aria-hidden":!0}),t[3]=p):p=t[3];let h;t[4]!==s||t[5]!==c||t[6]!==l||t[7]!==u?(h=(0,R.jsx)(`button`,{type:`button`,ref:l,"aria-label":u,className:d,...s,...c,children:p}),t[4]=s,t[5]=c,t[6]=l,t[7]=u,t[8]=h):h=t[8];let g;t[9]!==n||t[10]!==h?(g=(0,R.jsx)(U,{action:n,dragHandle:h}),t[9]=n,t[10]=h,t[11]=g):g=t[11];let _;return t[12]!==a||t[13]!==o||t[14]!==g?(_=(0,R.jsx)(`div`,{ref:a,style:o,children:g}),t[12]=a,t[13]=o,t[14]=g,t[15]=_):_=t[15],_}function U(e){let t=(0,L.c)(24),{action:n,dragHandle:r}=e,i=!n.disabled&&`hover:bg-state-hover`,a;t[0]===i?a=t[1]:(a=b(ne,`relative scroll-mt-7 select-none focus-within:bg-state-hover focus-within:text-foreground`,i),t[0]=i,t[1]=a);let o=n.tooltip??n.label,s=n.shortcut?.ariaKeyshortcuts,c;t[2]===n.icon?c=t[3]:(c=(0,R.jsx)(`span`,{className:N,children:n.icon}),t[2]=n.icon,t[3]=c);let l;t[4]===n.label?l=t[5]:(l=(0,R.jsx)(`span`,{className:`min-w-0 flex-1 truncate text-foreground`,children:n.label}),t[4]=n.label,t[5]=l);let u;t[6]!==n.disabled||t[7]!==n.id||t[8]!==n.onSelect||t[9]!==o||t[10]!==s||t[11]!==c||t[12]!==l?(u=(0,R.jsxs)(`button`,{type:`button`,id:n.id,title:o,"data-panel-new-tab-item":``,"aria-keyshortcuts":s,disabled:n.disabled,onClick:n.onSelect,className:`flex min-w-0 flex-1 items-center gap-1.5 text-left after:absolute after:inset-0 after:rounded after:content-[''] focus-visible:outline-none disabled:cursor-default`,children:[c,l]}),t[6]=n.disabled,t[7]=n.id,t[8]=n.onSelect,t[9]=o,t[10]=s,t[11]=c,t[12]=l,t[13]=u):u=t[13];let d;t[14]===n.shortcut?d=t[15]:(d=(0,R.jsx)(O,{shortcut:n.shortcut}),t[14]=n.shortcut,t[15]=d);let f;t[16]===n.trailing?f=t[17]:(f=n.trailing===null?null:(0,R.jsx)(`div`,{className:`relative flex min-w-0 shrink-0 items-center`,children:n.trailing}),t[16]=n.trailing,t[17]=f);let p;return t[18]!==r||t[19]!==a||t[20]!==u||t[21]!==d||t[22]!==f?(p=(0,R.jsxs)(`div`,{className:a,children:[u,d,r,f]}),t[18]=r,t[19]=a,t[20]=u,t[21]=d,t[22]=f,t[23]=p):p=t[23],p}var W=e(a(),1);function G(e){return e.entryKind===`file`}function K(e){return{source:e.source,entryKind:`file`,path:e.path,name:e.name,score:e.score,positions:e.positions}}function be(e){let t=(0,L.c)(15),n;t[0]!==e.currentThreadId||t[1]!==e.environmentId||t[2]!==e.hostId||t[3]!==e.limit||t[4]!==e.projectId||t[5]!==e.query?(n={projectId:e.projectId,query:e.query,limit:e.limit,environmentId:e.environmentId,hostId:e.hostId,currentThreadId:e.currentThreadId,includeDirectories:!1},t[0]=e.currentThreadId,t[1]=e.environmentId,t[2]=e.hostId,t[3]=e.limit,t[4]=e.projectId,t[5]=e.query,t[6]=n):n=t[6];let r=D(n),i;t[7]===r.suggestions?i=t[8]:(i=r.suggestions.filter(G).map(K),t[7]=r.suggestions,t[8]=i);let a=i,o=!!e.projectId,s=!!e.currentThreadId,c=a.length===0&&r.isLoading,l=!o&&!s,u;return t[9]!==r.isDebouncing||t[10]!==r.isError||t[11]!==a||t[12]!==c||t[13]!==l?(u={suggestions:a,isLoading:c,fileSearchError:r.isError,isDebouncing:r.isDebouncing,isUnavailable:l},t[9]=r.isDebouncing,t[10]=r.isError,t[11]=a,t[12]=c,t[13]=l,t[14]=u):u=t[14],u}var xe=20,Se=[`actions`,`files`,`recent`],q={actions:`Actions`,files:`Files`,recent:`Recent`},Ce={workspace:`Workspace`,"thread-storage":`Thread storage`},we=`file-search-result-recent`;function Te(e){return`file-search-result-${e.source}-${encodeURIComponent(e.path)}`}function Ee(e){return e.kind===`action`?e.action.id:e.kind===`recent`?`${we}-${e.item.source}-${encodeURIComponent(e.item.path)}`:Te(e.suggestion)}function De(e){return`${Ce[e.source]}: ${e.path}`}function Oe(e){return e.kind!==`action`||!e.action.disabled}function ke({actions:e,recentEntries:t,suggestions:n}){let r=new Map,i=e=>{let t=r.get(e);if(t)return t;let n={kind:e,items:[]};return r.set(e,n),n};for(let t of e)i(`actions`).items.push({entry:{kind:`action`,action:t},index:0});for(let e of n)i(`files`).items.push({entry:{kind:`suggestion`,suggestion:e},index:0});for(let e of t)i(`recent`).items.push({entry:e,index:0});let a=0;return Se.flatMap(e=>{let t=r.get(e);return t?[{...t,items:t.items.map(({entry:e})=>{if(!Oe(e))return{entry:e,index:-1};let t=a;return a+=1,{entry:e,index:t}})}]:[]})}function Ae(e){let t=(0,L.c)(10),{iconName:n,iconClassName:r,message:i}=e,a;t[0]===r?a=t[1]:(a=b(h,`shrink-0`,r),t[0]=r,t[1]=a);let o;t[2]!==n||t[3]!==a?(o=(0,R.jsx)(m,{name:n,className:a}),t[2]=n,t[3]=a,t[4]=o):o=t[4];let s;t[5]===i?s=t[6]:(s=(0,R.jsx)(`p`,{className:S,children:i}),t[5]=i,t[6]=s);let c;return t[7]!==o||t[8]!==s?(c=(0,R.jsx)(u,{className:`flex min-h-24 items-center justify-center`,children:(0,R.jsxs)(`div`,{className:`flex max-w-64 items-center justify-center gap-1.5`,children:[o,s]})}),t[7]=o,t[8]=s,t[9]=c):c=t[9],c}function J(e){let t=(0,L.c)(13),{id:n,isActive:r,onActivate:i,onSelect:a,title:o,disabled:s,children:c}=e,l=s===void 0?!1:s,u=l||void 0,d=r&&`bg-state-active`,f=!r&&!l&&`hover:bg-state-hover`,p;t[0]!==d||t[1]!==f?(p=b(te,`relative scroll-mt-7 disabled:cursor-default`,d,f),t[0]=d,t[1]=f,t[2]=p):p=t[2];let m;return t[3]!==c||t[4]!==l||t[5]!==n||t[6]!==r||t[7]!==i||t[8]!==a||t[9]!==u||t[10]!==p||t[11]!==o?(m=(0,R.jsx)(`button`,{type:`button`,id:n,"data-panel-new-tab-item":``,role:`option`,"aria-selected":r,"aria-disabled":u,disabled:l,onClick:a,onMouseEnter:i,onFocus:i,title:o,className:p,children:c}),t[3]=c,t[4]=l,t[5]=n,t[6]=r,t[7]=i,t[8]=a,t[9]=u,t[10]=p,t[11]=o,t[12]=m):m=t[12],m}function je(e){let t=(0,L.c)(30),{id:n,suggestion:r,isActive:i,onActivate:a,onSelect:o}=e,c;t[0]!==o||t[1]!==r?(c=()=>{o(r)},t[0]=o,t[1]=r,t[2]=c):c=t[2];let l=c,u;t[3]===r.path?u=t[4]:(u=s(r.path),t[3]=r.path,t[4]=u);let d=u||null,f;t[5]===r.path?f=t[6]:(f=F(r.path),t[5]=r.path,t[6]=f);let h=f,g;t[7]===r?g=t[8]:(g=De(r),t[7]=r,t[8]=g);let v=i?`bg-state-active`:`hover:bg-state-hover`,y;t[9]===v?y=t[10]:(y=b(`w-full scroll-mt-7 rounded px-2 py-1.5 text-left focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring`,_,S,v),t[9]=v,t[10]=y);let x;t[11]===Symbol.for(`react.memo_cache_sentinel`)?(x=b(p,`text-muted-foreground`),t[11]=x):x=t[11];let C;t[12]===h?C=t[13]:(C=(0,R.jsx)(m,{name:h,className:x,"aria-hidden":!0}),t[12]=h,t[13]=C);let w;t[14]===r.name?w=t[15]:(w=(0,R.jsx)(`span`,{className:`truncate`,children:r.name}),t[14]=r.name,t[15]=w);let E;t[16]===d?E=t[17]:(E=d===null?null:(0,R.jsx)(T,{className:`text-muted-foreground [flex-shrink:9999]`,children:d}),t[16]=d,t[17]=E);let D;t[18]!==E||t[19]!==C||t[20]!==w?(D=(0,R.jsxs)(`div`,{className:`flex min-w-0 items-center gap-1.5`,children:[C,w,E]}),t[18]=E,t[19]=C,t[20]=w,t[21]=D):D=t[21];let O;return t[22]!==l||t[23]!==n||t[24]!==i||t[25]!==a||t[26]!==D||t[27]!==g||t[28]!==y?(O=(0,R.jsx)(`button`,{type:`button`,id:n,"data-panel-new-tab-item":``,role:`option`,"aria-selected":i,onClick:l,onMouseEnter:a,onFocus:a,title:g,className:y,children:D}),t[22]=l,t[23]=n,t[24]=i,t[25]=a,t[26]=D,t[27]=g,t[28]=y,t[29]=O):O=t[29],O}function Y(e){let t=(0,L.c)(15),{action:n,isActive:r,onActivate:i}=e,a;t[0]===n.icon?a=t[1]:(a=(0,R.jsx)(`span`,{className:N,children:n.icon}),t[0]=n.icon,t[1]=a);let o;t[2]===n.label?o=t[3]:(o=(0,R.jsx)(`span`,{className:`min-w-0 flex-1 truncate text-foreground`,children:n.label}),t[2]=n.label,t[3]=o);let s;t[4]===n.shortcut?s=t[5]:(s=(0,R.jsx)(O,{shortcut:n.shortcut}),t[4]=n.shortcut,t[5]=s);let c;return t[6]!==n.disabled||t[7]!==n.id||t[8]!==n.onSelect||t[9]!==r||t[10]!==i||t[11]!==a||t[12]!==o||t[13]!==s?(c=(0,R.jsxs)(J,{id:n.id,isActive:r,onActivate:i,onSelect:n.onSelect,disabled:n.disabled,children:[a,o,s]}),t[6]=n.disabled,t[7]=n.id,t[8]=n.onSelect,t[9]=r,t[10]=i,t[11]=a,t[12]=o,t[13]=s,t[14]=c):c=t[14],c}function Me(e){let t=(0,L.c)(33),{id:n,item:r,isActive:i,nowMs:a,onActivate:o,onSelect:c}=e,l;t[0]!==r||t[1]!==c?(l=()=>{c(r)},t[0]=r,t[1]=c,t[2]=l):l=t[2];let u=l,d;t[3]===r.path?d=t[4]:(d=F(r.path),t[3]=r.path,t[4]=d);let p=d,h;t[5]===r.path?h=t[6]:(h=I({path:r.path}),t[5]=r.path,t[6]=h);let _=h,v;t[7]===r.path?v=t[8]:(v=s(r.path),t[7]=r.path,t[8]=v);let y=v,b;t[9]!==r.openedAt||t[10]!==a?(b=g({timestamp:r.openedAt,now:a}),t[9]=r.openedAt,t[10]=a,t[11]=b):b=t[11];let x=b,S;t[12]===p?S=t[13]:(S=(0,R.jsx)(`span`,{className:N,children:(0,R.jsx)(m,{name:p,className:f,"aria-hidden":!0})}),t[12]=p,t[13]=S);let C;t[14]===_?C=t[15]:(C=(0,R.jsx)(`span`,{className:`truncate text-foreground`,children:_}),t[14]=_,t[15]=C);let w;t[16]===y?w=t[17]:(w=y?(0,R.jsx)(T,{className:`text-muted-foreground [flex-shrink:9999]`,children:y}):null,t[16]=y,t[17]=w);let E;t[18]!==C||t[19]!==w?(E=(0,R.jsxs)(`span`,{className:`flex min-w-0 flex-1 items-center gap-1.5`,children:[C,w]}),t[18]=C,t[19]=w,t[20]=E):E=t[20];let D;t[21]!==i||t[22]!==x?(D=(0,R.jsx)(M,{idle:x,isActive:i}),t[21]=i,t[22]=x,t[23]=D):D=t[23];let O;return t[24]!==u||t[25]!==n||t[26]!==i||t[27]!==r.path||t[28]!==o||t[29]!==D||t[30]!==S||t[31]!==E?(O=(0,R.jsxs)(J,{id:n,isActive:i,onActivate:o,onSelect:u,title:r.path,children:[S,E,D]}),t[24]=u,t[25]=n,t[26]=i,t[27]=r.path,t[28]=o,t[29]=D,t[30]=S,t[31]=E,t[32]=O):O=t[32],O}function Ne(e){let t=(0,L.c)(12),{isExpanded:n,onToggle:r,showMoreCount:i}=e,a;t[0]===Symbol.for(`react.memo_cache_sentinel`)?(a=b(`ml-1.5 mt-0.5 inline-flex items-center gap-1.5 rounded-md px-2 py-1 text-muted-foreground transition-colors hover:bg-state-hover hover:text-foreground`,S),t[0]=a):a=t[0];let o=n&&`rotate-180`,s;t[1]===o?s=t[2]:(s=b(f,`transition-transform`,o),t[1]=o,t[2]=s);let c;t[3]===s?c=t[4]:(c=(0,R.jsx)(m,{name:`ChevronDown`,className:s,"aria-hidden":!0}),t[3]=s,t[4]=c);let l=n?`Show less`:`Show ${i} more`,u;t[5]===l?u=t[6]:(u=(0,R.jsx)(`span`,{children:l}),t[5]=l,t[6]=u);let d;return t[7]!==n||t[8]!==r||t[9]!==c||t[10]!==u?(d=(0,R.jsxs)(`button`,{type:`button`,"data-panel-new-tab-item":``,"aria-expanded":n,onClick:r,className:a,children:[c,u]}),t[7]=n,t[8]=r,t[9]=c,t[10]=u,t[11]=d):d=t[11],d}function Pe(e){let t=(0,L.c)(90),{projectId:n,environmentId:r,hostId:i,currentThreadId:a,autoFocus:o,actions:s,initialQuery:l,onAutoFocusHandled:u,onSelect:d,recentItemsThreadId:p,showFileSearch:g}=e,_=l===void 0?``:l,v=g===void 0?!0:g,y=c(`file.quickOpen`),x=(0,W.useRef)(null),T=(0,W.useRef)(null),D=(0,W.useId)(),O=w(),[k,ee]=(0,W.useState)(_),[A,j]=(0,W.useState)(-1),[M,te]=(0,W.useState)(!1),[N]=(0,W.useState)(ze),ne=a.length>0?a:null,P=E(p===void 0?ne:p),re;t[0]===k?re=t[1]:(re=k.trim(),t[0]=k,t[1]=re);let F=re,I=F.length>0,ie;t[2]!==a||t[3]!==r||t[4]!==i||t[5]!==n||t[6]!==k?(ie={projectId:n,query:k,limit:xe,environmentId:r,hostId:i,currentThreadId:a},t[2]=a,t[3]=r,t[4]=i,t[5]=n,t[6]=k,t[7]=ie):ie=t[7];let{suggestions:ae,isLoading:oe,fileSearchError:se,isDebouncing:ce,isUnavailable:z}=be(ie),le;t[8]!==s||t[9]!==F?(le=pe(s,F),t[8]=s,t[9]=F,t[10]=le):le=t[10];let ue=le,de;t[11]!==I||t[12]!==ae?(de=I?ae:[],t[11]=I,t[12]=ae,t[13]=de):de=t[13];let fe=de,B;t[14]!==M||t[15]!==P?(B=M?P:P.slice(0,6),t[14]=M,t[15]=P,t[16]=B):B=t[16];let he=B,ge;t[17]!==I||t[18]!==he?(ge=I?[]:he.map(Re),t[17]=I,t[18]=he,t[19]=ge):ge=t[19];let _e=ge,ve;t[20]!==ue||t[21]!==_e||t[22]!==fe?(ve=ke({actions:ue,recentEntries:_e,suggestions:fe}),t[20]=ue,t[21]=_e,t[22]=fe,t[23]=ve):ve=t[23];let V=ve,ye;t[24]===V?ye=t[25]:(ye=V.flatMap(Ie),t[24]=V,t[25]=ye);let H=ye,U;t[26]===H?U=t[27]:(U=H.map(Ee).join(`
|
|
1
|
+
import{o as e}from"./rolldown-runtime-BM3Ffeng.js";import{Ct as t,Or as n,St as r,bt as i,mi as a,ni as o}from"./boot-vendor-BBLG7GwQ.js";import{t as s}from"./timeline-path-display-DZ8kKRyF.js";import{$a as c,Gl as l,Ki as u,Mu as d,Nf as f,Pf as p,Qm as m,Rf as h,Sa as g,ah as _,ff as v,hn as y,oh as b,pn as x,qf as S,qi as C,uc as w}from"./index-B-RDC4LU.js";import{t as T}from"./truncate-start-D-P3rLti.js";import{n as E}from"./threadRecentItems-CYYbbS1r.js";import{t as D}from"./usePathSuggestions-zhZ-4fh8.js";import{t as O}from"./AppCommandShortcutHint-C1mIupNX.js";import{o as k,s as ee,t as A}from"./sortable.esm-DrqbbDDw.js";import{a as j,i as M,n as te,r as N,t as ne}from"./launcherRow-C9Htfook.js";import{n as P,t as re}from"./use-reorder-dnd-B-xEV6w8.js";import{n as F,t as I}from"./rightPanelFileVisuals-bs9QP9_p.js";var L=n(),ie=`bb.newTab.actionOrder`;function ae(e){return Array.isArray(e)&&e.every(e=>typeof e==`string`)}var oe=i(ie,[],d(ae),{getOnInit:!0}),R=e(o(),1),se=`Actions`,ce=`relative cursor-grab touch-none opacity-0 transition-opacity focus-visible:opacity-100 focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring active:cursor-grabbing group-hover:opacity-100 [@media(hover:none)]:opacity-100`,z=`file-search-result-open-browser`,le=`file-search-result-start-terminal`;function ue(e){return(0,R.jsx)(m,{name:e,className:f,"aria-hidden":!0})}function de(e){let n=(0,L.c)(15),{onOpenBrowser:r,onStartTerminal:i,pluginActions:a,startTerminalDisabled:o,startTerminalTrailing:s}=e,u=o===void 0?!1:o,d=t(oe),p=c(`terminal.open`),m;n[0]===r?m=n[1]:(m=r!==void 0&&v(),n[0]=r,n[1]=m);let h=m,g;if(n[2]!==r||n[3]!==i||n[4]!==a||n[5]!==h||n[6]!==u||n[7]!==s||n[8]!==d||n[9]!==p){let e=[];if(h){let t;n[11]===r?t=n[12]:(t=()=>r?.(),n[11]=r,n[12]=t),e.push({id:z,icon:ue(`Globe`),label:`Open browser`,disabled:!1,shortcut:null,trailing:null,onSelect:t})}if(i!==void 0){let t;n[13]===i?t=n[14]:(t=()=>i(),n[13]=i,n[14]=t),e.push({id:le,icon:ue(`Terminal`),label:`Start terminal`,disabled:u,shortcut:p,trailing:s??null,onSelect:t})}for(let t of a??[])e.push({id:t.id,icon:(0,R.jsx)(l,{pluginId:t.pluginId,icon:t.icon,className:f}),label:t.title,tooltip:t.tooltip,disabled:!1,shortcut:null,trailing:null,onSelect:t.onSelect});g=x({items:e,getId:fe,storedOrder:d}),n[2]=r,n[3]=i,n[4]=a,n[5]=h,n[6]=u,n[7]=s,n[8]=d,n[9]=p,n[10]=g}else g=n[10];return g.ordered}function fe(e){return e.id}function B(e){return e.toLowerCase().split(/[^\p{L}\p{N}]+/u).filter(e=>e.length>0)}function pe(e,t){let n=B(t);return n.length===0?[]:e.filter(e=>{let t=B(e.label);return n.every(e=>t.some(t=>t.startsWith(e)))})}function me(e){let t=(0,L.c)(3),{actions:n}=e;if(n.length===0)return null;let r;t[0]===Symbol.for(`react.memo_cache_sentinel`)?(r=(0,R.jsx)(j,{label:se,className:`pb-1`}),t[0]=r):r=t[0];let i;return t[1]===n?i=t[2]:(i=(0,R.jsx)(`div`,{"data-testid":`new-tab-actions`,className:`flex min-w-0 flex-col`,children:(0,R.jsxs)(`section`,{children:[r,(0,R.jsx)(he,{actions:n})]})}),t[1]=n,t[2]=i),i}function he(e){let t=(0,L.c)(11),{actions:n}=e,[i,a]=r(oe),o;t[0]!==n||t[1]!==i?(o=x({items:n,getId:_e,storedOrder:i}),t[0]=n,t[1]=i,t[2]=o):o=t[2];let{normalizedOrder:s}=o;if(n.length<2){let e;t[3]===n?e=t[4]:(e=n.map(ge),t[3]=n,t[4]=e);let r;return t[5]===e?r=t[6]:(r=(0,R.jsx)(`div`,{className:`flex flex-col gap-px`,children:e}),t[5]=e,t[6]=r),r}let c;return t[7]!==n||t[8]!==s||t[9]!==a?(c=(0,R.jsx)(ve,{actions:n,normalizedOrder:s,onOrderChange:a}),t[7]=n,t[8]=s,t[9]=a,t[10]=c):c=t[10],c}function ge(e){return(0,R.jsx)(U,{action:e},e.id)}function _e(e){return e.id}function ve(e){let t=(0,L.c)(19),{actions:n,normalizedOrder:r,onOrderChange:i}=e,a;t[0]===n?a=t[1]:(a=n.map(ye),t[0]=n,t[1]=a);let o=a,s;t[2]!==r||t[3]!==i||t[4]!==o?(s=e=>{if(!e.over||typeof e.active.id!=`string`||typeof e.over.id!=`string`)return;let t=y({activeId:e.active.id,overId:e.over.id,order:r,visibleIds:o});t&&i(t)},t[2]=r,t[3]=i,t[4]=o,t[5]=s):s=t[5];let c=s,l;t[6]===c?l=t[7]:(l={onDragEnd:c},t[6]=c,t[7]=l);let{dndContextProps:u,onClickCapture:d}=re(l),f;t[8]===n?f=t[9]:(f=n.map(V),t[8]=n,t[9]=f);let p;t[10]!==d||t[11]!==f?(p=(0,R.jsx)(`div`,{className:`flex flex-col gap-px`,onClickCapture:d,children:f}),t[10]=d,t[11]=f,t[12]=p):p=t[12];let m;t[13]!==o||t[14]!==p?(m=(0,R.jsx)(A,{items:o,strategy:k,children:p}),t[13]=o,t[14]=p,t[15]=m):m=t[15];let h;return t[16]!==u||t[17]!==m?(h=(0,R.jsx)(ee,{...u,children:m}),t[16]=u,t[17]=m,t[18]=h):h=t[18],h}function V(e){return(0,R.jsx)(H,{action:e},e.id)}function ye(e){return e.id}function H(e){let t=(0,L.c)(16),{action:n}=e,r;t[0]===n.id?r=t[1]:(r={id:n.id,disabled:!1},t[0]=n.id,t[1]=r);let{dragBindings:i,setNodeRef:a,style:o}=P(r),{attributes:s,listeners:c,setActivatorNodeRef:l}=i,u=`Reorder ${n.label}`,d;t[2]===Symbol.for(`react.memo_cache_sentinel`)?(d=b(N,ce),t[2]=d):d=t[2];let p;t[3]===Symbol.for(`react.memo_cache_sentinel`)?(p=(0,R.jsx)(m,{name:`DragDropVertical`,className:f,"aria-hidden":!0}),t[3]=p):p=t[3];let h;t[4]!==s||t[5]!==c||t[6]!==l||t[7]!==u?(h=(0,R.jsx)(`button`,{type:`button`,ref:l,"aria-label":u,className:d,...s,...c,children:p}),t[4]=s,t[5]=c,t[6]=l,t[7]=u,t[8]=h):h=t[8];let g;t[9]!==n||t[10]!==h?(g=(0,R.jsx)(U,{action:n,dragHandle:h}),t[9]=n,t[10]=h,t[11]=g):g=t[11];let _;return t[12]!==a||t[13]!==o||t[14]!==g?(_=(0,R.jsx)(`div`,{ref:a,style:o,children:g}),t[12]=a,t[13]=o,t[14]=g,t[15]=_):_=t[15],_}function U(e){let t=(0,L.c)(24),{action:n,dragHandle:r}=e,i=!n.disabled&&`hover:bg-state-hover`,a;t[0]===i?a=t[1]:(a=b(ne,`relative scroll-mt-7 select-none focus-within:bg-state-hover focus-within:text-foreground`,i),t[0]=i,t[1]=a);let o=n.tooltip??n.label,s=n.shortcut?.ariaKeyshortcuts,c;t[2]===n.icon?c=t[3]:(c=(0,R.jsx)(`span`,{className:N,children:n.icon}),t[2]=n.icon,t[3]=c);let l;t[4]===n.label?l=t[5]:(l=(0,R.jsx)(`span`,{className:`min-w-0 flex-1 truncate text-foreground`,children:n.label}),t[4]=n.label,t[5]=l);let u;t[6]!==n.disabled||t[7]!==n.id||t[8]!==n.onSelect||t[9]!==o||t[10]!==s||t[11]!==c||t[12]!==l?(u=(0,R.jsxs)(`button`,{type:`button`,id:n.id,title:o,"data-panel-new-tab-item":``,"aria-keyshortcuts":s,disabled:n.disabled,onClick:n.onSelect,className:`flex min-w-0 flex-1 items-center gap-1.5 text-left after:absolute after:inset-0 after:rounded after:content-[''] focus-visible:outline-none disabled:cursor-default`,children:[c,l]}),t[6]=n.disabled,t[7]=n.id,t[8]=n.onSelect,t[9]=o,t[10]=s,t[11]=c,t[12]=l,t[13]=u):u=t[13];let d;t[14]===n.shortcut?d=t[15]:(d=(0,R.jsx)(O,{shortcut:n.shortcut}),t[14]=n.shortcut,t[15]=d);let f;t[16]===n.trailing?f=t[17]:(f=n.trailing===null?null:(0,R.jsx)(`div`,{className:`relative flex min-w-0 shrink-0 items-center`,children:n.trailing}),t[16]=n.trailing,t[17]=f);let p;return t[18]!==r||t[19]!==a||t[20]!==u||t[21]!==d||t[22]!==f?(p=(0,R.jsxs)(`div`,{className:a,children:[u,d,r,f]}),t[18]=r,t[19]=a,t[20]=u,t[21]=d,t[22]=f,t[23]=p):p=t[23],p}var W=e(a(),1);function G(e){return e.entryKind===`file`}function K(e){return{source:e.source,entryKind:`file`,path:e.path,name:e.name,score:e.score,positions:e.positions}}function be(e){let t=(0,L.c)(15),n;t[0]!==e.currentThreadId||t[1]!==e.environmentId||t[2]!==e.hostId||t[3]!==e.limit||t[4]!==e.projectId||t[5]!==e.query?(n={projectId:e.projectId,query:e.query,limit:e.limit,environmentId:e.environmentId,hostId:e.hostId,currentThreadId:e.currentThreadId,includeDirectories:!1},t[0]=e.currentThreadId,t[1]=e.environmentId,t[2]=e.hostId,t[3]=e.limit,t[4]=e.projectId,t[5]=e.query,t[6]=n):n=t[6];let r=D(n),i;t[7]===r.suggestions?i=t[8]:(i=r.suggestions.filter(G).map(K),t[7]=r.suggestions,t[8]=i);let a=i,o=!!e.projectId,s=!!e.currentThreadId,c=a.length===0&&r.isLoading,l=!o&&!s,u;return t[9]!==r.isDebouncing||t[10]!==r.isError||t[11]!==a||t[12]!==c||t[13]!==l?(u={suggestions:a,isLoading:c,fileSearchError:r.isError,isDebouncing:r.isDebouncing,isUnavailable:l},t[9]=r.isDebouncing,t[10]=r.isError,t[11]=a,t[12]=c,t[13]=l,t[14]=u):u=t[14],u}var xe=20,Se=[`actions`,`files`,`recent`],q={actions:`Actions`,files:`Files`,recent:`Recent`},Ce={workspace:`Workspace`,"thread-storage":`Thread storage`},we=`file-search-result-recent`;function Te(e){return`file-search-result-${e.source}-${encodeURIComponent(e.path)}`}function Ee(e){return e.kind===`action`?e.action.id:e.kind===`recent`?`${we}-${e.item.source}-${encodeURIComponent(e.item.path)}`:Te(e.suggestion)}function De(e){return`${Ce[e.source]}: ${e.path}`}function Oe(e){return e.kind!==`action`||!e.action.disabled}function ke({actions:e,recentEntries:t,suggestions:n}){let r=new Map,i=e=>{let t=r.get(e);if(t)return t;let n={kind:e,items:[]};return r.set(e,n),n};for(let t of e)i(`actions`).items.push({entry:{kind:`action`,action:t},index:0});for(let e of n)i(`files`).items.push({entry:{kind:`suggestion`,suggestion:e},index:0});for(let e of t)i(`recent`).items.push({entry:e,index:0});let a=0;return Se.flatMap(e=>{let t=r.get(e);return t?[{...t,items:t.items.map(({entry:e})=>{if(!Oe(e))return{entry:e,index:-1};let t=a;return a+=1,{entry:e,index:t}})}]:[]})}function Ae(e){let t=(0,L.c)(10),{iconName:n,iconClassName:r,message:i}=e,a;t[0]===r?a=t[1]:(a=b(h,`shrink-0`,r),t[0]=r,t[1]=a);let o;t[2]!==n||t[3]!==a?(o=(0,R.jsx)(m,{name:n,className:a}),t[2]=n,t[3]=a,t[4]=o):o=t[4];let s;t[5]===i?s=t[6]:(s=(0,R.jsx)(`p`,{className:S,children:i}),t[5]=i,t[6]=s);let c;return t[7]!==o||t[8]!==s?(c=(0,R.jsx)(u,{className:`flex min-h-24 items-center justify-center`,children:(0,R.jsxs)(`div`,{className:`flex max-w-64 items-center justify-center gap-1.5`,children:[o,s]})}),t[7]=o,t[8]=s,t[9]=c):c=t[9],c}function J(e){let t=(0,L.c)(13),{id:n,isActive:r,onActivate:i,onSelect:a,title:o,disabled:s,children:c}=e,l=s===void 0?!1:s,u=l||void 0,d=r&&`bg-state-active`,f=!r&&!l&&`hover:bg-state-hover`,p;t[0]!==d||t[1]!==f?(p=b(te,`relative scroll-mt-7 disabled:cursor-default`,d,f),t[0]=d,t[1]=f,t[2]=p):p=t[2];let m;return t[3]!==c||t[4]!==l||t[5]!==n||t[6]!==r||t[7]!==i||t[8]!==a||t[9]!==u||t[10]!==p||t[11]!==o?(m=(0,R.jsx)(`button`,{type:`button`,id:n,"data-panel-new-tab-item":``,role:`option`,"aria-selected":r,"aria-disabled":u,disabled:l,onClick:a,onMouseEnter:i,onFocus:i,title:o,className:p,children:c}),t[3]=c,t[4]=l,t[5]=n,t[6]=r,t[7]=i,t[8]=a,t[9]=u,t[10]=p,t[11]=o,t[12]=m):m=t[12],m}function je(e){let t=(0,L.c)(30),{id:n,suggestion:r,isActive:i,onActivate:a,onSelect:o}=e,c;t[0]!==o||t[1]!==r?(c=()=>{o(r)},t[0]=o,t[1]=r,t[2]=c):c=t[2];let l=c,u;t[3]===r.path?u=t[4]:(u=s(r.path),t[3]=r.path,t[4]=u);let d=u||null,f;t[5]===r.path?f=t[6]:(f=F(r.path),t[5]=r.path,t[6]=f);let h=f,g;t[7]===r?g=t[8]:(g=De(r),t[7]=r,t[8]=g);let v=i?`bg-state-active`:`hover:bg-state-hover`,y;t[9]===v?y=t[10]:(y=b(`w-full scroll-mt-7 rounded px-2 py-1.5 text-left focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring`,_,S,v),t[9]=v,t[10]=y);let x;t[11]===Symbol.for(`react.memo_cache_sentinel`)?(x=b(p,`text-muted-foreground`),t[11]=x):x=t[11];let C;t[12]===h?C=t[13]:(C=(0,R.jsx)(m,{name:h,className:x,"aria-hidden":!0}),t[12]=h,t[13]=C);let w;t[14]===r.name?w=t[15]:(w=(0,R.jsx)(`span`,{className:`truncate`,children:r.name}),t[14]=r.name,t[15]=w);let E;t[16]===d?E=t[17]:(E=d===null?null:(0,R.jsx)(T,{className:`text-muted-foreground [flex-shrink:9999]`,children:d}),t[16]=d,t[17]=E);let D;t[18]!==E||t[19]!==C||t[20]!==w?(D=(0,R.jsxs)(`div`,{className:`flex min-w-0 items-center gap-1.5`,children:[C,w,E]}),t[18]=E,t[19]=C,t[20]=w,t[21]=D):D=t[21];let O;return t[22]!==l||t[23]!==n||t[24]!==i||t[25]!==a||t[26]!==D||t[27]!==g||t[28]!==y?(O=(0,R.jsx)(`button`,{type:`button`,id:n,"data-panel-new-tab-item":``,role:`option`,"aria-selected":i,onClick:l,onMouseEnter:a,onFocus:a,title:g,className:y,children:D}),t[22]=l,t[23]=n,t[24]=i,t[25]=a,t[26]=D,t[27]=g,t[28]=y,t[29]=O):O=t[29],O}function Y(e){let t=(0,L.c)(15),{action:n,isActive:r,onActivate:i}=e,a;t[0]===n.icon?a=t[1]:(a=(0,R.jsx)(`span`,{className:N,children:n.icon}),t[0]=n.icon,t[1]=a);let o;t[2]===n.label?o=t[3]:(o=(0,R.jsx)(`span`,{className:`min-w-0 flex-1 truncate text-foreground`,children:n.label}),t[2]=n.label,t[3]=o);let s;t[4]===n.shortcut?s=t[5]:(s=(0,R.jsx)(O,{shortcut:n.shortcut}),t[4]=n.shortcut,t[5]=s);let c;return t[6]!==n.disabled||t[7]!==n.id||t[8]!==n.onSelect||t[9]!==r||t[10]!==i||t[11]!==a||t[12]!==o||t[13]!==s?(c=(0,R.jsxs)(J,{id:n.id,isActive:r,onActivate:i,onSelect:n.onSelect,disabled:n.disabled,children:[a,o,s]}),t[6]=n.disabled,t[7]=n.id,t[8]=n.onSelect,t[9]=r,t[10]=i,t[11]=a,t[12]=o,t[13]=s,t[14]=c):c=t[14],c}function Me(e){let t=(0,L.c)(33),{id:n,item:r,isActive:i,nowMs:a,onActivate:o,onSelect:c}=e,l;t[0]!==r||t[1]!==c?(l=()=>{c(r)},t[0]=r,t[1]=c,t[2]=l):l=t[2];let u=l,d;t[3]===r.path?d=t[4]:(d=F(r.path),t[3]=r.path,t[4]=d);let p=d,h;t[5]===r.path?h=t[6]:(h=I({path:r.path}),t[5]=r.path,t[6]=h);let _=h,v;t[7]===r.path?v=t[8]:(v=s(r.path),t[7]=r.path,t[8]=v);let y=v,b;t[9]!==r.openedAt||t[10]!==a?(b=g({timestamp:r.openedAt,now:a}),t[9]=r.openedAt,t[10]=a,t[11]=b):b=t[11];let x=b,S;t[12]===p?S=t[13]:(S=(0,R.jsx)(`span`,{className:N,children:(0,R.jsx)(m,{name:p,className:f,"aria-hidden":!0})}),t[12]=p,t[13]=S);let C;t[14]===_?C=t[15]:(C=(0,R.jsx)(`span`,{className:`truncate text-foreground`,children:_}),t[14]=_,t[15]=C);let w;t[16]===y?w=t[17]:(w=y?(0,R.jsx)(T,{className:`text-muted-foreground [flex-shrink:9999]`,children:y}):null,t[16]=y,t[17]=w);let E;t[18]!==C||t[19]!==w?(E=(0,R.jsxs)(`span`,{className:`flex min-w-0 flex-1 items-center gap-1.5`,children:[C,w]}),t[18]=C,t[19]=w,t[20]=E):E=t[20];let D;t[21]!==i||t[22]!==x?(D=(0,R.jsx)(M,{idle:x,isActive:i}),t[21]=i,t[22]=x,t[23]=D):D=t[23];let O;return t[24]!==u||t[25]!==n||t[26]!==i||t[27]!==r.path||t[28]!==o||t[29]!==D||t[30]!==S||t[31]!==E?(O=(0,R.jsxs)(J,{id:n,isActive:i,onActivate:o,onSelect:u,title:r.path,children:[S,E,D]}),t[24]=u,t[25]=n,t[26]=i,t[27]=r.path,t[28]=o,t[29]=D,t[30]=S,t[31]=E,t[32]=O):O=t[32],O}function Ne(e){let t=(0,L.c)(12),{isExpanded:n,onToggle:r,showMoreCount:i}=e,a;t[0]===Symbol.for(`react.memo_cache_sentinel`)?(a=b(`ml-1.5 mt-0.5 inline-flex items-center gap-1.5 rounded-md px-2 py-1 text-muted-foreground transition-colors hover:bg-state-hover hover:text-foreground`,S),t[0]=a):a=t[0];let o=n&&`rotate-180`,s;t[1]===o?s=t[2]:(s=b(f,`transition-transform`,o),t[1]=o,t[2]=s);let c;t[3]===s?c=t[4]:(c=(0,R.jsx)(m,{name:`ChevronDown`,className:s,"aria-hidden":!0}),t[3]=s,t[4]=c);let l=n?`Show less`:`Show ${i} more`,u;t[5]===l?u=t[6]:(u=(0,R.jsx)(`span`,{children:l}),t[5]=l,t[6]=u);let d;return t[7]!==n||t[8]!==r||t[9]!==c||t[10]!==u?(d=(0,R.jsxs)(`button`,{type:`button`,"data-panel-new-tab-item":``,"aria-expanded":n,onClick:r,className:a,children:[c,u]}),t[7]=n,t[8]=r,t[9]=c,t[10]=u,t[11]=d):d=t[11],d}function Pe(e){let t=(0,L.c)(90),{projectId:n,environmentId:r,hostId:i,currentThreadId:a,autoFocus:o,actions:s,initialQuery:l,onAutoFocusHandled:u,onSelect:d,recentItemsThreadId:p,showFileSearch:g}=e,_=l===void 0?``:l,v=g===void 0?!0:g,y=c(`file.quickOpen`),x=(0,W.useRef)(null),T=(0,W.useRef)(null),D=(0,W.useId)(),O=w(),[k,ee]=(0,W.useState)(_),[A,j]=(0,W.useState)(-1),[M,te]=(0,W.useState)(!1),[N]=(0,W.useState)(ze),ne=a.length>0?a:null,P=E(p===void 0?ne:p),re;t[0]===k?re=t[1]:(re=k.trim(),t[0]=k,t[1]=re);let F=re,I=F.length>0,ie;t[2]!==a||t[3]!==r||t[4]!==i||t[5]!==n||t[6]!==k?(ie={projectId:n,query:k,limit:xe,environmentId:r,hostId:i,currentThreadId:a},t[2]=a,t[3]=r,t[4]=i,t[5]=n,t[6]=k,t[7]=ie):ie=t[7];let{suggestions:ae,isLoading:oe,fileSearchError:se,isDebouncing:ce,isUnavailable:z}=be(ie),le;t[8]!==s||t[9]!==F?(le=pe(s,F),t[8]=s,t[9]=F,t[10]=le):le=t[10];let ue=le,de;t[11]!==I||t[12]!==ae?(de=I?ae:[],t[11]=I,t[12]=ae,t[13]=de):de=t[13];let fe=de,B;t[14]!==M||t[15]!==P?(B=M?P:P.slice(0,6),t[14]=M,t[15]=P,t[16]=B):B=t[16];let he=B,ge;t[17]!==I||t[18]!==he?(ge=I?[]:he.map(Re),t[17]=I,t[18]=he,t[19]=ge):ge=t[19];let _e=ge,ve;t[20]!==ue||t[21]!==_e||t[22]!==fe?(ve=ke({actions:ue,recentEntries:_e,suggestions:fe}),t[20]=ue,t[21]=_e,t[22]=fe,t[23]=ve):ve=t[23];let V=ve,ye;t[24]===V?ye=t[25]:(ye=V.flatMap(Ie),t[24]=V,t[25]=ye);let H=ye,U;t[26]===H?U=t[27]:(U=H.map(Ee).join(`
|
|
2
2
|
`),t[26]=H,t[27]=U);let G=U,K=A>=0&&A<H.length?H[A]??null:null,Se,q;t[28]===Symbol.for(`react.memo_cache_sentinel`)?(Se=()=>()=>{T.current!==null&&cancelAnimationFrame(T.current)},q=[],t[28]=Se,t[29]=q):(Se=t[28],q=t[29]),(0,W.useEffect)(Se,q);let Ce,we;t[30]!==o||t[31]!==O||t[32]!==u?(Ce=()=>{if(o){if(T.current!==null&&(cancelAnimationFrame(T.current),T.current=null),O){u();return}x.current?.focus({preventScroll:!0}),T.current=requestAnimationFrame(()=>{T.current=null,x.current?.focus({preventScroll:!0})}),u()}},we=[o,O,u],t[30]=o,t[31]=O,t[32]=u,t[33]=Ce,t[34]=we):(Ce=t[33],we=t[34]),(0,W.useEffect)(Ce,we);let Te;t[35]===G.length?Te=t[36]:(Te=()=>{j(G.length>0?0:-1)},t[35]=G.length,t[36]=Te);let De;t[37]===G?De=t[38]:(De=[G],t[37]=G,t[38]=De),(0,W.useEffect)(Te,De);let Oe;t[39]===d?Oe=t[40]:(Oe=e=>{d({source:e.source,path:e.path})},t[39]=d,t[40]=Oe);let J=Oe,je;t[41]===d?je=t[42]:(je=e=>{d({source:e.source,path:e.path})},t[41]=d,t[42]=je);let Y=je,Me;t[43]===Symbol.for(`react.memo_cache_sentinel`)?(Me=()=>{te(Fe)},t[43]=Me):Me=t[43];let Ne=Me,Pe;t[44]!==K||t[45]!==J||t[46]!==Y||t[47]!==H.length?(Pe=e=>{if(H.length!==0){if(e.key===`ArrowDown`){e.preventDefault(),j(e=>(e+1)%H.length);return}if(e.key===`ArrowUp`){e.preventDefault(),j(e=>e<=0?H.length-1:e-1);return}if(e.key===`Enter`&&K){if(e.preventDefault(),K.kind===`action`){K.action.onSelect();return}if(K.kind===`recent`){Y(K.item);return}K.kind===`suggestion`&&J(K.suggestion)}}},t[44]=K,t[45]=J,t[46]=Y,t[47]=H.length,t[48]=Pe):Pe=t[48];let Le=Pe,Ve;t[49]===K?Ve=t[50]:(Ve=K?Ee(K):void 0,t[49]=K,t[50]=Ve);let He=Ve,Ue=!z&&H.length>0,We=s.length>0?`Search files and actions`:`Search files`,Ge;t[51]===s?Ge=t[52]:(Ge=(0,R.jsx)(me,{actions:s}),t[51]=s,t[52]=Ge);let Ke=Ge;if(!v){let e;return t[53]===Ke?e=t[54]:(e=(0,R.jsx)(`div`,{className:`flex min-w-0 flex-col gap-3`,children:Ke}),t[53]=Ke,t[54]=e),e}let qe;t[55]===Symbol.for(`react.memo_cache_sentinel`)?(qe=(0,R.jsx)(m,{name:`Search`,className:b(`pointer-events-none absolute left-2.5 top-1/2 -translate-y-1/2 text-muted-foreground`,h)}),t[55]=qe):qe=t[55];let Je;t[56]===Symbol.for(`react.memo_cache_sentinel`)?(Je=e=>ee(e.target.value),t[56]=Je):Je=t[56];let Ye=y?`${We} (${y.label})`:We,Xe=y?.ariaKeyshortcuts,Ze=Ue?D:void 0,Qe=Ue?He:void 0,$e=z?`No searchable source`:We,et;t[57]===Symbol.for(`react.memo_cache_sentinel`)?(et=b(`h-8 pl-8 pr-8 focus-visible:ring-0 max-md:pointer-coarse:h-10`,S),t[57]=et):et=t[57];let X;t[58]!==Le||t[59]!==Ue||t[60]!==z||t[61]!==k||t[62]!==Ye||t[63]!==Xe||t[64]!==Ze||t[65]!==Qe||t[66]!==$e?(X=(0,R.jsx)(C,{ref:x,"data-panel-new-tab-item":``,value:k,onChange:Je,onKeyDown:Le,disabled:z,role:`combobox`,"aria-label":Ye,"aria-keyshortcuts":Xe,"aria-autocomplete":`list`,"aria-expanded":Ue,"aria-controls":Ze,"aria-activedescendant":Qe,placeholder:$e,className:et}),t[58]=Le,t[59]=Ue,t[60]=z,t[61]=k,t[62]=Ye,t[63]=Xe,t[64]=Ze,t[65]=Qe,t[66]=$e,t[67]=X):X=t[67];let Z;t[68]===ce?Z=t[69]:(Z=ce?(0,R.jsx)(m,{name:`Spinner`,className:b(`pointer-events-none absolute right-2.5 top-1/2 -translate-y-1/2 animate-spin text-muted-foreground`,f)}):null,t[68]=ce,t[69]=Z);let Q;t[70]!==X||t[71]!==Z?(Q=(0,R.jsxs)(`div`,{className:`relative min-w-0`,children:[qe,X,Z]}),t[70]=X,t[71]=Z,t[72]=Q):Q=t[72];let tt=I?null:Ke,$;t[73]!==A||t[74]!==se||t[75]!==J||t[76]!==Y||t[77]!==I||t[78]!==oe||t[79]!==M||t[80]!==z||t[81]!==D||t[82]!==N||t[83]!==P||t[84]!==V?($=z?(0,R.jsx)(Ae,{iconName:`FileQuestion`,message:`No searchable source is available.`}):(0,R.jsx)(Be,{activeIndex:A,hasQuery:I,searchError:se,isLoading:oe,listboxId:D,nowMs:N,onActivateIndex:j,onSuggestionSelect:J,onRecentSelect:Y,recent:{count:P.length,showMoreCount:Math.max(0,P.length-6),isExpanded:M,toggleVisible:!I&&P.length>6,emptyHintVisible:!I&&P.length===0,onToggleExpanded:Ne},sections:V}),t[73]=A,t[74]=se,t[75]=J,t[76]=Y,t[77]=I,t[78]=oe,t[79]=M,t[80]=z,t[81]=D,t[82]=N,t[83]=P,t[84]=V,t[85]=$):$=t[85];let nt;return t[86]!==Q||t[87]!==tt||t[88]!==$?(nt=(0,R.jsxs)(`div`,{className:`flex min-w-0 flex-col gap-3`,children:[Q,tt,$]}),t[86]=Q,t[87]=tt,t[88]=$,t[89]=nt):nt=t[89],nt}function Fe(e){return!e}function Ie(e){return e.items.flatMap(Le)}function Le(e){let{entry:t,index:n}=e;return n>=0?[t]:[]}function Re(e){return{kind:`recent`,item:e}}function ze(){return Date.now()}function Be(e){let t=(0,L.c)(37),{activeIndex:n,hasQuery:r,searchError:i,isLoading:a,listboxId:o,nowMs:s,onActivateIndex:c,onSuggestionSelect:l,onRecentSelect:d,recent:f,sections:p}=e,m;t[0]===p?m=t[1]:(m=p.some(Ve),t[0]=p,t[1]=m);let h=m,g=a&&!h,_=i&&!h&&!g,v=g||_||r&&!h&&!g&&!_,y=!r&&v;if(p.length===0&&!f.emptyHintVisible&&!g&&!_){let e=r?`FileQuestion`:`File`,n=r?`No results match your search.`:`Type to search files.`,i;return t[2]!==e||t[3]!==n?(i=(0,R.jsx)(Ae,{iconName:e,message:n}),t[2]=e,t[3]=n,t[4]=i):i=t[4],i}let x;t[5]!==_||t[6]!==g||t[7]!==v?(x=v?(0,R.jsx)(Ae,{iconName:_?`AlertCircle`:g?`Spinner`:`FileQuestion`,iconClassName:g?`animate-spin`:void 0,message:_?`Search failed.`:g?`Searching files...`:`No files match your search.`}):null,t[5]=_,t[6]=g,t[7]=v,t[8]=x):x=t[8];let C=x,w=r?null:C,T;t[9]!==n||t[10]!==y||t[11]!==o||t[12]!==s||t[13]!==c||t[14]!==d||t[15]!==l||t[16]!==f.count||t[17]!==p?(T=p.length>0?(0,R.jsx)(`div`,{id:o,role:`listbox`,"aria-label":`Search results`,children:p.map((e,t)=>{let r=t>0||y;return(0,R.jsxs)(`section`,{role:`group`,"aria-label":q[e.kind],className:b(r&&`mt-3`),children:[(0,R.jsx)(j,{label:q[e.kind],count:e.kind===`recent`&&f.count>0?f.count:void 0,sticky:!0,className:r?`pt-2`:void 0}),(0,R.jsx)(`div`,{className:`flex flex-col gap-px`,children:e.items.map(e=>{let{entry:t,index:r}=e,i=Ee(t),a=r>=0&&r===n,o=()=>c(r);return t.kind===`action`?(0,R.jsx)(Y,{action:t.action,isActive:a,onActivate:o},i):t.kind===`suggestion`?(0,R.jsx)(je,{id:i,suggestion:t.suggestion,isActive:a,onActivate:o,onSelect:l},i):(0,R.jsx)(Me,{id:i,item:t.item,isActive:a,nowMs:s,onActivate:o,onSelect:d},i)})})]},e.kind)})}):null,t[9]=n,t[10]=y,t[11]=o,t[12]=s,t[13]=c,t[14]=d,t[15]=l,t[16]=f.count,t[17]=p,t[18]=T):T=t[18];let E;t[19]!==r||t[20]!==C||t[21]!==p.length?(E=r&&C?(0,R.jsx)(`div`,{className:b(p.length>0&&`mt-3`),children:C}):null,t[19]=r,t[20]=C,t[21]=p.length,t[22]=E):E=t[22];let D;t[23]!==y||t[24]!==f.emptyHintVisible?(D=f.emptyHintVisible?(0,R.jsxs)(`section`,{className:b(y&&`mt-3`),children:[(0,R.jsx)(j,{label:q.recent,sticky:!0,className:y?`pt-2`:void 0}),(0,R.jsx)(u,{className:b(`py-4`,S),children:`Plans, mockups, and files you open will show up here.`})]}):null,t[23]=y,t[24]=f.emptyHintVisible,t[25]=D):D=t[25];let O;t[26]!==f.isExpanded||t[27]!==f.onToggleExpanded||t[28]!==f.showMoreCount||t[29]!==f.toggleVisible?(O=f.toggleVisible?(0,R.jsx)(Ne,{isExpanded:f.isExpanded,onToggle:f.onToggleExpanded,showMoreCount:f.showMoreCount}):null,t[26]=f.isExpanded,t[27]=f.onToggleExpanded,t[28]=f.showMoreCount,t[29]=f.toggleVisible,t[30]=O):O=t[30];let k;return t[31]!==w||t[32]!==T||t[33]!==E||t[34]!==D||t[35]!==O?(k=(0,R.jsxs)(`div`,{className:`pb-1`,children:[w,T,E,D,O]}),t[31]=w,t[32]=T,t[33]=E,t[34]=D,t[35]=O,t[36]=k):k=t[36],k}function Ve(e){return e.kind===`files`}function He(e){let t=(0,L.c)(18),{autoFocus:n,currentThreadId:r,environmentId:i,hostId:a,initialQuery:o,onAutoFocusHandled:s,onOpenBrowser:c,onSelect:l,onStartTerminal:u,pluginActions:d,projectId:f,recentItemsThreadId:p,showFileSearch:m,startTerminalDisabled:h,startTerminalTrailing:g}=e,_;t[0]!==c||t[1]!==u||t[2]!==d||t[3]!==h||t[4]!==g?(_={onOpenBrowser:c,onStartTerminal:u,pluginActions:d,startTerminalDisabled:h,startTerminalTrailing:g},t[0]=c,t[1]=u,t[2]=d,t[3]=h,t[4]=g,t[5]=_):_=t[5];let v=de(_),y;return t[6]!==v||t[7]!==n||t[8]!==r||t[9]!==i||t[10]!==a||t[11]!==o||t[12]!==s||t[13]!==l||t[14]!==f||t[15]!==p||t[16]!==m?(y=(0,R.jsx)(`div`,{"data-panel-new-tab-page":``,className:`flex min-h-full flex-col gap-3 bg-sidebar px-4 pb-3 pt-1`,children:(0,R.jsx)(Pe,{projectId:f,environmentId:i,hostId:a,currentThreadId:r,autoFocus:n,actions:v,initialQuery:o,onAutoFocusHandled:s,onSelect:l,recentItemsThreadId:p,showFileSearch:m})}),t[6]=v,t[7]=n,t[8]=r,t[9]=i,t[10]=a,t[11]=o,t[12]=s,t[13]=l,t[14]=f,t[15]=p,t[16]=m,t[17]=y):y=t[17],y}export{He as NewTabPage};
|
|
Binary file
|
|
Binary file
|