@readmagic/workmate 0.0.5 → 0.0.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/chunks/{AddWorkspaceDirectory-DJRkEz7o.js → AddWorkspaceDirectory-ClHi-Dr6.js} +1 -1
- package/dist/chunks/{App-iJu5qyiF.js → App-BP06lHmf.js} +1 -1
- package/dist/chunks/{ApproveApiKey-CRejTHUw.js → ApproveApiKey-Bsy8kr2a.js} +1 -1
- package/dist/chunks/ApproveApiKey-a2ZonQ3n.js +1 -0
- package/dist/chunks/{AssistantSessionChooser-CBLQ1v-J.js → AssistantSessionChooser-CcocKoTJ.js} +1 -1
- package/dist/chunks/{BackgroundTasksDialog-CyoLEYWH.js → BackgroundTasksDialog-DNeBhGCf.js} +1 -1
- package/dist/chunks/{BypassPermissionsModeDialog-D1FCKVOi.js → BypassPermissionsModeDialog-BKj_3Idm.js} +1 -1
- package/dist/chunks/{ClaudeMdExternalIncludesDialog-CI0yF6sZ.js → ClaudeMdExternalIncludesDialog-BD-7yAZh.js} +1 -1
- package/dist/chunks/ClaudeMdExternalIncludesDialog-DFivNFuo.js +1 -0
- package/dist/chunks/ConsoleOAuthFlow-CS3zjEPF.js +1 -0
- package/dist/chunks/{DesktopHandoff-D1rrMxeP.js → DesktopHandoff-BmPmCfT3.js} +1 -1
- package/dist/chunks/{DiffDialog-BKcfKx7O.js → DiffDialog-C4XSSjvV.js} +1 -1
- package/dist/chunks/Doctor-BhD-ZzZm.js +1 -0
- package/dist/chunks/{Doctor-Yco1McrL.js → Doctor-DEQe2q16.js} +1 -1
- package/dist/chunks/{ExitFlow-D3csukbB.js → ExitFlow-BttnAv-O.js} +1 -1
- package/dist/chunks/{Feedback-bEUtrHia.js → Feedback-BaYA8-SU.js} +1 -1
- package/dist/chunks/Grove-BJziCbZH.js +11 -0
- package/dist/chunks/Grove-sWm-oLBf.js +1 -0
- package/dist/chunks/{HybridTransport-9fTBC2Pv.js → HybridTransport-B8V6O6rM.js} +1 -1
- package/dist/chunks/{InvalidConfigDialog-9M-1nfZ6.js → InvalidConfigDialog-CHzBSJDf.js} +1 -1
- package/dist/chunks/{InvalidSettingsDialog-B2F6pryH.js → InvalidSettingsDialog-BKenH3bD.js} +1 -1
- package/dist/chunks/{MCPConnectionManager-MWpKjeZT.js → MCPConnectionManager-CNh9dNlk.js} +1 -1
- package/dist/chunks/{McpParsingWarnings-BPBb7Npe.js → McpParsingWarnings-Bj2-YL8o.js} +1 -1
- package/dist/chunks/{MessageSelector-DsQmqFt2.js → MessageSelector-DdR6wJhh.js} +1 -1
- package/dist/chunks/{Messages-B3sGRx5A.js → Messages-Ch6cboMV.js} +2 -2
- package/dist/chunks/{Onboarding-cHcnsBGp.js → Onboarding-BrAJp0aL.js} +1 -1
- package/dist/chunks/{OverageCreditUpsell-CWCD_RpM.js → OverageCreditUpsell-Ds1cB7RC.js} +1 -1
- package/dist/chunks/PluginSettings-CGqEzejq.js +17 -0
- package/dist/chunks/{PromptInputFooterSuggestions-D5sAO6y-.js → PromptInputFooterSuggestions-egs9VvUs.js} +1 -1
- package/dist/chunks/{PromptInputHelpMenu-n6hAdsto.js → PromptInputHelpMenu-SieM5NoY.js} +1 -1
- package/dist/chunks/{QueryEngine-cwdsr4dr.js → QueryEngine-CZZMl3PB.js} +1 -1
- package/dist/chunks/{REPL-CJzScgbZ.js → REPL-CG2N7E4Q.js} +6 -6
- package/dist/chunks/REPL-DvA910N_.js +1 -0
- package/dist/chunks/{RemoteCallout-CiA4rCEs.js → RemoteCallout-Cs-ro8_i.js} +1 -1
- package/dist/chunks/{RemoteSessionManager-zdHfmvfj.js → RemoteSessionManager-B740Dp6m.js} +1 -1
- package/dist/chunks/{ResumeConversation-Rxwd6HAJ.js → ResumeConversation-DzV2zmuX.js} +1 -1
- package/dist/chunks/{SSETransport-BPbhCa2f.js → SSETransport-DtpMDekF.js} +1 -1
- package/dist/chunks/SearchExtraToolsTool-C4uO-Zx3.js +1 -0
- package/dist/chunks/{Settings-CxI_KHUj.js → Settings-XKw6FI_m.js} +2 -2
- package/dist/chunks/{TeleportProgress-DrulEQ7z.js → TeleportProgress-rYaHIEfe.js} +1 -1
- package/dist/chunks/{TeleportRepoMismatchDialog-D3FOLr0P.js → TeleportRepoMismatchDialog-DY97YZMB.js} +1 -1
- package/dist/chunks/{TeleportResumeWrapper-DI5iRFND.js → TeleportResumeWrapper-jaQzyTCh.js} +1 -1
- package/dist/chunks/{ThemePicker-CQ7dfFtv.js → ThemePicker-BViWzLp3.js} +1 -1
- package/dist/chunks/{TrustDialog-CnVKrdxQ.js → TrustDialog-DGJ_BisZ.js} +1 -1
- package/dist/chunks/{ValidationErrorsList-CPYeuppg.js → ValidationErrorsList-B8pRiGuy.js} +1 -1
- package/dist/chunks/{WelcomeV2-C-UXdIng.js → WelcomeV2-DqnbSdIu.js} +1 -1
- package/dist/chunks/{add-dir-xTz4COgn.js → add-dir-C2Hu3oE4.js} +1 -1
- package/dist/chunks/{agentDisplay-BuSReYxu.js → agentDisplay-XoDJhr03.js} +1 -1
- package/dist/chunks/{agents-Du9KYHqN.js → agents-BIHTGDYh.js} +1 -1
- package/dist/chunks/{agents-CiLlKN2I.js → agents-C4QXeHIJ.js} +1 -1
- package/dist/chunks/{allErrors-P3utlEeA.js → allErrors-1896uQA1.js} +1 -1
- package/dist/chunks/{ant-CBIfqmAb.js → ant-B6k6cBts.js} +1 -1
- package/dist/chunks/api-BsFW57_Q.js +1 -0
- package/dist/chunks/{api-B-5jqiMg.js → api-gqTA-D7n.js} +1 -1
- package/dist/chunks/{assistant-XOnU01yl.js → assistant-DJ9hd4uC.js} +1 -1
- package/dist/chunks/auth-8Vd3_U8t.js +1 -0
- package/dist/chunks/{auth-DT2yxy94.js → auth-BnSrKyJe.js} +1 -1
- package/dist/chunks/auth-DRTjfnGy.js +1 -0
- package/dist/chunks/{autoMode-CEMflt3g.js → autoMode-BNukrVAB.js} +1 -1
- package/dist/chunks/{autonomy-_N8aDaA8.js → autonomy-BEmI7WVW.js} +1 -1
- package/dist/chunks/{autonomy-Cg5zweUa.js → autonomy-DGcy5Rml.js} +1 -1
- package/dist/chunks/{autonomyPanel-I4yCy3Fr.js → autonomyPanel-fhge09AG.js} +1 -1
- package/dist/chunks/backgroundHousekeeping-3i_d_WW5.js +1 -0
- package/dist/chunks/{backgroundHousekeeping-DhF2lrQ9.js → backgroundHousekeeping-BVMf_Tjn.js} +2 -2
- package/dist/chunks/{branch-BIX-pyHp.js → branch-Bpe-gocq.js} +1 -1
- package/dist/chunks/{break-cache-BQfgkNAo.js → break-cache-C_p7Kmx2.js} +3 -3
- package/dist/chunks/{bridge-CYskzVt8.js → bridge-D12Shbkj.js} +2 -2
- package/dist/chunks/{bridgeConfig-5p_w4s5r.js → bridgeConfig-BhxRF2vm.js} +1 -1
- package/dist/chunks/bridgeConfig-CqIQ_rvD.js +1 -0
- package/dist/chunks/bridgeEnabled-D0XC5kNh.js +1 -0
- package/dist/chunks/{bridgeEnabled-DhFrLTbG.js → bridgeEnabled-SbB-6zdY.js} +1 -1
- package/dist/chunks/{bridgeMain-BX2AkLPs.js → bridgeMain-DHUpZFgL.js} +6 -6
- package/dist/chunks/bridgeMain-DUbQjgCp.js +1 -0
- package/dist/chunks/{bridgeMessaging-B5Lbzr8e.js → bridgeMessaging-DHc5dOhB.js} +1 -1
- package/dist/chunks/{btw-CWWFO7u8.js → btw-D9hMM5d2.js} +1 -1
- package/dist/chunks/caches-CWzT7e6Y.js +1 -0
- package/dist/chunks/{caches-DPqPIogk.js → caches-UeVVM3T0.js} +2 -2
- package/dist/chunks/{ccrClient-CTLnU9Y1.js → ccrClient-Iza0L8Zw.js} +1 -1
- package/dist/chunks/{clear-DCAgZwc4.js → clear-B4d38ssF.js} +1 -1
- package/dist/chunks/client-BzKQTXzF.js +1 -0
- package/dist/chunks/{color-CmJGInHL.js → color-D8VOyoYl.js} +1 -1
- package/dist/chunks/commands-DDamMmo4.js +1 -0
- package/dist/chunks/commitAttribution-CgohL8vD.js +1 -0
- package/dist/chunks/{commitAttribution-CGZr7XNO.js → commitAttribution-ChAgixdj.js} +1 -1
- package/dist/chunks/{compact-C6-lMHgn.js → compact-IFHwxjZ9.js} +1 -1
- package/dist/chunks/config-DY5-_kk_.js +1 -0
- package/dist/chunks/{config-3m_9zSrj.js → config-DmomySWC.js} +1 -1
- package/dist/chunks/config-WxgxrQoP.js +1 -0
- package/dist/chunks/{context-C9V4GF0n.js → context-Cl6BJ2vm.js} +1 -1
- package/dist/chunks/{context-noninteractive-BmC4o5xo.js → context-noninteractive-9hELVC29.js} +1 -1
- package/dist/chunks/context-noninteractive-Beij5MfU.js +1 -0
- package/dist/chunks/conversation-BBB91hEw.js +1 -0
- package/dist/chunks/{conversation-CYqqk0o7.js → conversation-BWVTM40Y.js} +1 -1
- package/dist/chunks/{createSSHSession-BL6j0AU5.js → createSSHSession-BM-5pbv6.js} +1 -1
- package/dist/chunks/createSession-CoQtL5Rj.js +1 -0
- package/dist/chunks/{createSession-D_sgO1Xy.js → createSession-Cvl1Q50F.js} +1 -1
- package/dist/chunks/{crossProjectResume-D5hTOfnE.js → crossProjectResume-BasMLl2n.js} +1 -1
- package/dist/chunks/{datadog-UkGdjL8-.js → datadog-CpqEQbHa.js} +1 -1
- package/dist/chunks/{desktop-HbYKh-VK.js → desktop-B_L6T6jI.js} +1 -1
- package/dist/chunks/{diff-nTV17iWX.js → diff-CVzOodeg.js} +1 -1
- package/dist/chunks/doctor-1L0TFuGw.js +1 -0
- package/dist/chunks/{entry-CCFI6-gM.js → entry-DHVYCR26.js} +1 -1
- package/dist/chunks/envLessBridgeConfig-CN0_44-p.js +1 -0
- package/dist/chunks/{envLessBridgeConfig-DXd10GXD.js → envLessBridgeConfig-Ck2-KMq0.js} +1 -1
- package/dist/chunks/{esm-CGoYrggU.js → esm-D5q6s4l8.js} +1 -1
- package/dist/chunks/{exit-ropaQiOr.js → exit-Bm1S_f3i.js} +1 -1
- package/dist/chunks/extra-usage-UHAWtypK.js +1 -0
- package/dist/chunks/{extra-usage-core-DLYHAInT.js → extra-usage-core-BFOolqoi.js} +1 -1
- package/dist/chunks/{extra-usage-noninteractive-D8iszH3c.js → extra-usage-noninteractive-cUGZy0en.js} +1 -1
- package/dist/chunks/{extra-usage-g2Pw4zt_.js → extra-usage-zDHVtWKZ.js} +1 -1
- package/dist/chunks/{extraUsage-C2Ylufhj.js → extraUsage-Dq66zzqR.js} +1 -1
- package/dist/chunks/extractMemories-BcaklA33.js +1 -0
- package/dist/chunks/fast-DALAHO3d.js +1 -0
- package/dist/chunks/{fast-Dx2fTmWr.js → fast-MS7WZpD8.js} +1 -1
- package/dist/chunks/{feedback-DCQ4pJ3v.js → feedback-Fw4m28ZC.js} +1 -1
- package/dist/chunks/firstPartyEventLogger-CS9jVz6D.js +1 -0
- package/dist/chunks/{firstPartyEventLogger-BNGPPBNP.js → firstPartyEventLogger-CoSUd0a1.js} +2 -2
- package/dist/chunks/{flushGate-XaheIZZT.js → flushGate-De-yppeo.js} +1 -1
- package/dist/chunks/{gemini-BCCLHK3K.js → gemini-BPziscyN.js} +1 -1
- package/dist/chunks/{generateRecap-BhvbixY2.js → generateRecap-jGDLI_wU.js} +1 -1
- package/dist/chunks/{generateSessionName-CN1oh7Fa.js → generateSessionName-hDJ6HBJ1.js} +1 -1
- package/dist/chunks/{githubRepoPathMapping-B4AM8luI.js → githubRepoPathMapping-qAoiyj6P.js} +1 -1
- package/dist/chunks/{goal-Bp6fyGqo.js → goal-CFx4eRkf.js} +1 -1
- package/dist/chunks/{grok-ax26ju8y.js → grok-Byblph7F.js} +1 -1
- package/dist/chunks/{grove-DrBVaZSN.js → grove-CpqjcGCb.js} +1 -1
- package/dist/chunks/{heapdump-JseysNDr.js → heapdump-C4kPlqGt.js} +1 -1
- package/dist/chunks/{help-DR9hKneR.js → help-B1h-faJ3.js} +1 -1
- package/dist/chunks/hooks-DPLIIpAD.js +1 -0
- package/dist/chunks/{hooks-C5n23H1E.js → hooks-X6J03MnA.js} +1 -1
- package/dist/chunks/hostGuard-BHI6Q8Mt.js +1 -0
- package/dist/chunks/inboundAttachments-BekVc0W-.js +1 -0
- package/dist/chunks/{inboundAttachments-Cp8XvLMZ.js → inboundAttachments-CUJE3KaU.js} +1 -1
- package/dist/chunks/{initReplBridge-DJs28ZkI.js → initReplBridge-JQ-afRx9.js} +1 -1
- package/dist/chunks/{install-C7qTB0V5.js → install-D5YORIJL.js} +1 -1
- package/dist/chunks/{instrumentation-CLZttr_u.js → instrumentation-Bw3CxPQf.js} +3 -3
- package/dist/chunks/{job-BhiazwPH.js → job-DOWtcltx.js} +1 -1
- package/dist/chunks/{keybindings-CkL8BzUt.js → keybindings-BLw5J-Zj.js} +1 -1
- package/dist/chunks/{language-DIw2871r.js → language-C6Fq-XOZ.js} +1 -1
- package/dist/chunks/language-Cqw5gYJR.js +1 -0
- package/dist/chunks/{launchAgentsPlatform-j-mWpwW1.js → launchAgentsPlatform-jWWf-Lk9.js} +1 -1
- package/dist/chunks/{launchLocalMemory-DmoXp0Xo.js → launchLocalMemory-kHeD0I0y.js} +1 -1
- package/dist/chunks/{launchLocalVault-1uKe0HjA.js → launchLocalVault-DLqkOjmb.js} +1 -1
- package/dist/chunks/{launchMemoryStores-SxDKjHJ3.js → launchMemoryStores-Ct7AVXrO.js} +1 -1
- package/dist/chunks/{launchOnboarding-CTtpnXcs.js → launchOnboarding-Cc6WwPX9.js} +1 -1
- package/dist/chunks/{launchSchedule-BDVnGhaL.js → launchSchedule-ZyvuvjgU.js} +1 -1
- package/dist/chunks/{launchSkillStore-SmMLxp4K.js → launchSkillStore-BejQnLog.js} +1 -1
- package/dist/chunks/{launchTeleport-B472ZSGz.js → launchTeleport-8CuYUfIR.js} +1 -1
- package/dist/chunks/{launchVault-CsyBgxle.js → launchVault-DIvIOuPh.js} +1 -1
- package/dist/chunks/{loadAgentsDir-Clu7Uk6a.js → loadAgentsDir-D206qwP3.js} +47 -47
- package/dist/chunks/loadAgentsDir-TZjwTqdr.js +1 -0
- package/dist/chunks/{loadPluginHooks-Cvd5VdjQ.js → loadPluginHooks-Ddhsyn0_.js} +1 -1
- package/dist/chunks/{localSearch-iA6JTk19.js → localSearch-CzrbOklu.js} +1 -1
- package/dist/chunks/localSearch-DrOAL6f4.js +1 -0
- package/dist/chunks/{logoV2Utils-YHBJLIrC.js → logoV2Utils-8M56V7oN.js} +1 -1
- package/dist/chunks/{magicDocs-Bf1fqnHN.js → magicDocs-DWjL2k7P.js} +1 -1
- package/dist/chunks/{main-gtV_TqXP.js → main-BohPzJFF.js} +16 -16
- package/dist/chunks/{mappers-C8lYERPX.js → mappers-BDMZFgKx.js} +1 -1
- package/dist/chunks/{mcp-Ci0OPVrR.js → mcp-Bt1ITh-Z.js} +1 -1
- package/dist/chunks/{mcp-CNuhEGP6.js → mcp-CwJ-AIpt.js} +2 -2
- package/dist/chunks/{mcp-CwIYauZl.js → mcp-W0LFoyFR.js} +1 -1
- package/dist/chunks/{memory-DCGqfQ1U.js → memory-3wV7m7UU.js} +1 -1
- package/dist/chunks/{mode-DO6g7nkX.js → mode-CUkHFkju.js} +1 -1
- package/dist/chunks/{model-DLXL0CNu.js → model-BY3auM2c.js} +1 -1
- package/dist/chunks/model-CKkOnnnx.js +1 -0
- package/dist/chunks/model-DRXcJyU9.js +1 -0
- package/dist/chunks/{nativeInstaller-OPuO2sm_.js → nativeInstaller-CA5d6_G7.js} +1 -1
- package/dist/chunks/{onChangeAppState-CHhRDkM7.js → onChangeAppState-DBmy2Ow_.js} +1 -1
- package/dist/chunks/{openai-HOebt-8k.js → openai-Cbomn0Ws.js} +1 -1
- package/dist/chunks/{overageCreditGrant-Bi1CTBAx.js → overageCreditGrant-DsUrmeBh.js} +1 -1
- package/dist/chunks/{panel-CrTPqXCv.js → panel-BSZGX6jN.js} +1 -1
- package/dist/chunks/{panelCall-D0eURklm.js → panelCall-BsVoL1uF.js} +1 -1
- package/dist/chunks/{partition-C8RSL3SQ.js → partition-BAakXjvj.js} +1 -1
- package/dist/chunks/{passes-BJci5SM_.js → passes-CLRt7Cvm.js} +1 -1
- package/dist/chunks/{permissions-JU9CGHgI.js → permissions-BVSFuwNP.js} +1 -1
- package/dist/chunks/{pidLock-Bd2e6xuT.js → pidLock-D5rUnDB-.js} +2 -2
- package/dist/chunks/{plan-D4gMsK7i.js → plan-SYZ4DXR8.js} +1 -1
- package/dist/chunks/{plugin-CwCo5Kik.js → plugin-Bfjzhmrk.js} +1 -1
- package/dist/chunks/{pluginAutoupdate-CO-n9bqe.js → pluginAutoupdate-reO2PgtQ.js} +1 -1
- package/dist/chunks/{pluginBlocklist-5qbaTRbV.js → pluginBlocklist-C3H2afWG.js} +1 -1
- package/dist/chunks/{pluginCliCommands-I-lsw_us.js → pluginCliCommands-lqdxdkQp.js} +1 -1
- package/dist/chunks/{pluginFlagging-DNPBbJZo.js → pluginFlagging-D9HKAGBC.js} +1 -1
- package/dist/chunks/{pluginOperations-Cz6eQ0Vu.js → pluginOperations-EN3EKLux.js} +1 -1
- package/dist/chunks/{pluginStartupCheck-DJ9fslCK.js → pluginStartupCheck-BY73BMT2.js} +1 -1
- package/dist/chunks/pluginStartupCheck-CwWOlveD.js +1 -0
- package/dist/chunks/{plugins-CzJIuPfb.js → plugins-Dn6ceWrT.js} +1 -1
- package/dist/chunks/policyLimits-CkTI5KEt.js +1 -0
- package/dist/chunks/{poor-Dha9p9RF.js → poor-j-y-bv8o.js} +1 -1
- package/dist/chunks/{poorMode-1NLYiS3Y.js → poorMode-DhzFKpPl.js} +1 -1
- package/dist/chunks/poorMode-V11s-3cf.js +1 -0
- package/dist/chunks/{print-BL4EUT5Z.js → print-Db_VXmfO.js} +4 -4
- package/dist/chunks/{privacy-settings-6ZWxR4Qt.js → privacy-settings-DHMJREbb.js} +1 -1
- package/dist/chunks/{processBashCommand-BZs9wggV.js → processBashCommand-BcM_fhV9.js} +1 -1
- package/dist/chunks/{processSlashCommand-D8lKLNzM.js → processSlashCommand-DEVo3GPX.js} +1 -1
- package/dist/chunks/{prompt-Bg_1U0gO.js → prompt-BNHtszmZ.js} +1 -1
- package/dist/chunks/prompt-CrX31AGm.js +1 -0
- package/dist/chunks/prompt-IAvMxKDl.js +1 -0
- package/dist/chunks/{promptEditor-BhYDmwdS.js → promptEditor-DeMrXUir.js} +1 -1
- package/dist/chunks/{protocolHandler-Dnb7lITm.js → protocolHandler-BHxBy84Z.js} +1 -1
- package/dist/chunks/{rate-limit-options-DVzT3eWH.js → rate-limit-options-DIudL9fb.js} +1 -1
- package/dist/chunks/{rcDebugLog-VKwMl0yg.js → rcDebugLog-CUy1_F23.js} +1 -1
- package/dist/chunks/{reconciler-BdRXZTJf.js → reconciler-BXpPyfSY.js} +1 -1
- package/dist/chunks/{referral-BlrMpBAV.js → referral-CUaIo_vT.js} +1 -1
- package/dist/chunks/{refresh-jwqnoK2h.js → refresh-CuaVBIQ0.js} +1 -1
- package/dist/chunks/{registerProtocol-CuKZAiCc.js → registerProtocol-B7Fzdofu.js} +1 -1
- package/dist/chunks/{release-notes-BgP8u7NE.js → release-notes-fbfv2DC0.js} +1 -1
- package/dist/chunks/{releaseNotes-CunqVlbU.js → releaseNotes-CxAHFLPl.js} +2 -2
- package/dist/chunks/{reload-plugins-CD9TzvFm.js → reload-plugins-B9IT9CFA.js} +1 -1
- package/dist/chunks/{remote-env-QaP_W_sv.js → remote-env-BOklGlll.js} +1 -1
- package/dist/chunks/{remoteBridgeCore-9-HVMo63.js → remoteBridgeCore-j0bG1zjv.js} +1 -1
- package/dist/chunks/{remoteManagedSettings-jZ6u8ZBT.js → remoteManagedSettings-Cq994lyc.js} +1 -1
- package/dist/chunks/{rename-29qxHf8W.js → rename-Iev7wQsI.js} +1 -1
- package/dist/chunks/{resume-D-SpOy_1.js → resume-y7MCTZHJ.js} +1 -1
- package/dist/chunks/{runtimeObserver-DOEcrylu.js → runtimeObserver-BZcJ1FbH.js} +1 -1
- package/dist/chunks/{runtimeObserver-Dm3LIUMp.js → runtimeObserver-CyzLASla.js} +2 -2
- package/dist/chunks/sandbox-adapter-Cu1FYrkh.js +1 -0
- package/dist/chunks/{sandbox-toggle-B61AeBor.js → sandbox-toggle-CWpBO228.js} +1 -1
- package/dist/chunks/searchExtraTools-BUOUds7p.js +1 -0
- package/dist/chunks/{session-RwJCIIcs.js → session-DL4cA_8l.js} +1 -1
- package/dist/chunks/{sessionDiscovery-dkFeWcA3.js → sessionDiscovery-DAfNKqp1.js} +1 -1
- package/dist/chunks/sessionFileAccessHooks-2cgIIxPk.js +1 -0
- package/dist/chunks/{sessionMemory-btARBn8H.js → sessionMemory-BS8_TbKj.js} +1 -1
- package/dist/chunks/sessionMemory-D5fSHXvZ.js +1 -0
- package/dist/chunks/sessionMemoryUtils-BWUztNh6.js +1 -0
- package/dist/chunks/sessionObserver-ChfQtK2m.js +1 -0
- package/dist/chunks/{sessionObserver-CSOYgsvH.js → sessionObserver-ShbCwJ8x.js} +1 -1
- package/dist/chunks/sessionStorage-Cf5wmnyB.js +1 -0
- package/dist/chunks/{sessionTitle-CLOlPZ_M.js → sessionTitle-coed9IuJ.js} +1 -1
- package/dist/chunks/{sessionTracing-D8wr9j4X.js → sessionTracing-D9rUyiq0.js} +1 -1
- package/dist/chunks/{settings-Dlp5JTa_.js → settings-BovzmwMP.js} +2 -2
- package/dist/chunks/{settingsSync-QWA0VZSu.js → settingsSync-PqU9XGJq.js} +1 -1
- package/dist/chunks/{setup-UI9uv2-K.js → setup-B_FOvNpp.js} +2 -2
- package/dist/chunks/{shadowedRuleDetection-CXsmUY2o.js → shadowedRuleDetection-D1wsAdpp.js} +1 -1
- package/dist/chunks/{sideQuestion-CHpOVzY5.js → sideQuestion-wSi38p81.js} +1 -1
- package/dist/chunks/sinks-BpcRrN_T.js +1 -0
- package/dist/chunks/{sinks-1hFrW9HK.js → sinks-C_Dl1p4K.js} +2 -2
- package/dist/chunks/{skill-learning-Ck17rwH8.js → skill-learning-B5tmc7EX.js} +1 -1
- package/dist/chunks/{skillChangeDetector-s0F9Yf9a.js → skillChangeDetector-DNqohXxz.js} +1 -1
- package/dist/chunks/{skillGapStore-BJ1h2LVr.js → skillGapStore-D-kQKVDZ.js} +1 -1
- package/dist/chunks/{skillGapStore-DyqNKuNy.js → skillGapStore-Df5BWAk5.js} +2 -2
- package/dist/chunks/{skillGenerator-BT8NGzXT.js → skillGenerator-DbcdpAkw.js} +2 -2
- package/dist/chunks/skillLearning-C5cXZE6_.js +1 -0
- package/dist/chunks/{skillLearning-Cn9Uw0Kd.js → skillLearning-ClRiDcJH.js} +1 -1
- package/dist/chunks/{skillPanel-N0GoWjIi.js → skillPanel-LBd4E-MM.js} +3 -3
- package/dist/chunks/{skillSearchPanel-CTwtgTzy.js → skillSearchPanel-CErRnUwo.js} +2 -2
- package/dist/chunks/{skills-Bv3lH-aA.js → skills-CBKhfg_a.js} +1 -1
- package/dist/chunks/{stats-C1Ff6w4i.js → stats-BY4dskVg.js} +1 -1
- package/dist/chunks/{status-DyXiBa0m.js → status-BnJIXtKl.js} +2 -2
- package/dist/chunks/{status-FD7HVYS7.js → status-DU-B4SMW.js} +1 -1
- package/dist/chunks/{statusNoticeHelpers-kTp9Rdk6.js → statusNoticeHelpers-CzTuGNuC.js} +1 -1
- package/dist/chunks/{tag-RzOSA5T0.js → tag-B-wVW9Aj.js} +1 -1
- package/dist/chunks/{tasks-eJrOcdhB.js → tasks-CBVL005y.js} +1 -1
- package/dist/chunks/{teleport-ABA-hdmP.js → teleport-dtqQXM4x.js} +1 -1
- package/dist/chunks/{templateJobs-BnOBSFtq.js → templateJobs-D6998LcG.js} +1 -1
- package/dist/chunks/{terminalSetup-BfvmoJaK.js → terminalSetup-0SBdyKF5.js} +1 -1
- package/dist/chunks/{terminalSetup-D_P5iZmq.js → terminalSetup-CuV-qU6v.js} +1 -1
- package/dist/chunks/{theme-S0kVMVt4.js → theme-p0AooruD.js} +1 -1
- package/dist/chunks/thinkback-Catprqs_.js +1 -0
- package/dist/chunks/{thinkback-HyW_R_88.js → thinkback-DI2NpvG-.js} +1 -1
- package/dist/chunks/{thinkback-play-H6md4czq.js → thinkback-play-CqrIRx2o.js} +1 -1
- package/dist/chunks/{toolEventObserver-BAFzvePj.js → toolEventObserver-DTccwC3c.js} +1 -1
- package/dist/chunks/{toolEventObserver--Z6jENks.js → toolEventObserver-DlH73w-S.js} +1 -1
- package/dist/chunks/{toolPool-CR61XXm3.js → toolPool-B64V-jmK.js} +1 -1
- package/dist/chunks/{trustedDevice-Dn4rXbxT.js → trustedDevice-BTYoQCkC.js} +1 -1
- package/dist/chunks/trustedDevice-CiwjT_Y6.js +1 -0
- package/dist/chunks/{ultrareviewCommand-mYDTBCFD.js → ultrareviewCommand-BDFUS3hf.js} +1 -1
- package/dist/chunks/undercover-XYapZ_SS.js +1 -0
- package/dist/chunks/{undercover-CdapzvNH.js → undercover-vuTpCnQJ.js} +2 -2
- package/dist/chunks/{updateCCB-DPShheOr.js → updateCCB-DFL5Wt_I.js} +1 -1
- package/dist/chunks/{upgrade-BOeakAP6.js → upgrade-D5qwcaWQ.js} +1 -1
- package/dist/chunks/upgrade-DIg3j929.js +1 -0
- package/dist/chunks/{upload-BXQsDtLW.js → upload-B_yADHX9.js} +1 -1
- package/dist/chunks/{usage-iNQzY960.js → usage-C0SnnC-i.js} +1 -1
- package/dist/chunks/usage-CYJKE8N6.js +1 -0
- package/dist/chunks/{useExitOnCtrlCDWithKeybindings-CntByfTQ.js → useExitOnCtrlCDWithKeybindings-DKIqRraH.js} +1 -1
- package/dist/chunks/useMainLoopModel-XetDUXd-.js +1 -0
- package/dist/chunks/{useManagePlugins-B8HD0RUh.js → useManagePlugins-B2KhKiu5.js} +1 -1
- package/dist/chunks/{useMergedTools-DfchLQZC.js → useMergedTools-CKvwz_Zt.js} +1 -1
- package/dist/chunks/{useSearchInput-H-8hJeFD.js → useSearchInput-D1Vr2Js1.js} +1 -1
- package/dist/chunks/{useSettingsErrors-BF5i5Xju.js → useSettingsErrors-B7BXHchG.js} +1 -1
- package/dist/chunks/{util-CoicMvOv.js → util-BaDs-wL5.js} +1 -1
- package/dist/chunks/{validatePlugin-z2fcngf8.js → validatePlugin-DtiYlXby.js} +1 -1
- package/dist/chunks/{vim-DdvQlLDm.js → vim-C-icQDz1.js} +1 -1
- package/dist/chunks/{workerRegistry-CzqQwCHC.js → workerRegistry-ChqPPIaO.js} +1 -1
- package/dist/chunks/worktree-DAn8ooa1.js +1 -0
- package/dist/cli.js +1 -1
- package/package.json +1 -1
- package/dist/chunks/ApproveApiKey-CKfn7U1R.js +0 -1
- package/dist/chunks/ClaudeMdExternalIncludesDialog-TypH-X8e.js +0 -1
- package/dist/chunks/ConsoleOAuthFlow-wGQuFt41.js +0 -1
- package/dist/chunks/Doctor-CcJUwSQn.js +0 -1
- package/dist/chunks/Grove-DPkIjqg8.js +0 -1
- package/dist/chunks/Grove-Dsd7F39b.js +0 -11
- package/dist/chunks/PluginSettings-B0jbwB2M.js +0 -17
- package/dist/chunks/REPL-DlBJIPCw.js +0 -1
- package/dist/chunks/SearchExtraToolsTool-VP87ErGx.js +0 -1
- package/dist/chunks/api-BiwZmmsh.js +0 -1
- package/dist/chunks/auth-BQa4kzQo.js +0 -1
- package/dist/chunks/auth-UAJhZNmZ.js +0 -1
- package/dist/chunks/backgroundHousekeeping-BUUZ7Csq.js +0 -1
- package/dist/chunks/bridgeConfig-DWEqKbXk.js +0 -1
- package/dist/chunks/bridgeEnabled-CjVCMwnq.js +0 -1
- package/dist/chunks/bridgeMain-6lollTtZ.js +0 -1
- package/dist/chunks/caches-C46fa77L.js +0 -1
- package/dist/chunks/client-Bup0Sgcn.js +0 -1
- package/dist/chunks/commands-BdB1eFvP.js +0 -1
- package/dist/chunks/commitAttribution-D6J3NuhB.js +0 -1
- package/dist/chunks/config-Bxt1UH1T.js +0 -1
- package/dist/chunks/config-CjjXZfNi.js +0 -1
- package/dist/chunks/context-noninteractive-DvGo1l7b.js +0 -1
- package/dist/chunks/conversation-CH9ouFai.js +0 -1
- package/dist/chunks/createSession-DUfOAeyE.js +0 -1
- package/dist/chunks/doctor-7fgVhEKL.js +0 -1
- package/dist/chunks/envLessBridgeConfig-B2HYnEKo.js +0 -1
- package/dist/chunks/extra-usage-CLhv1Z4g.js +0 -1
- package/dist/chunks/extractMemories-B2IAvbXM.js +0 -1
- package/dist/chunks/fast-_G6zcFye.js +0 -1
- package/dist/chunks/firstPartyEventLogger-C9LzVy6y.js +0 -1
- package/dist/chunks/hooks-BUJLxdFJ.js +0 -1
- package/dist/chunks/hostGuard-C5xydXZI.js +0 -1
- package/dist/chunks/inboundAttachments-C0nMTtCi.js +0 -1
- package/dist/chunks/language-DfOAuDFc.js +0 -1
- package/dist/chunks/loadAgentsDir-DTbJJff-.js +0 -1
- package/dist/chunks/localSearch-DKv8PRLD.js +0 -1
- package/dist/chunks/model-BQF64tZx.js +0 -1
- package/dist/chunks/model-DvrvG6BB.js +0 -1
- package/dist/chunks/pluginStartupCheck-CoW7073W.js +0 -1
- package/dist/chunks/policyLimits-BkjgMQD0.js +0 -1
- package/dist/chunks/poorMode-qlxqU8Hm.js +0 -1
- package/dist/chunks/prompt-CN7gBNKS.js +0 -1
- package/dist/chunks/prompt-D-zHhqp8.js +0 -1
- package/dist/chunks/sandbox-adapter-LzTcKwBp.js +0 -1
- package/dist/chunks/searchExtraTools-CbJJQqzH.js +0 -1
- package/dist/chunks/sessionFileAccessHooks-B_nNW0zE.js +0 -1
- package/dist/chunks/sessionMemory-C4JAUZ6V.js +0 -1
- package/dist/chunks/sessionMemoryUtils-BlqAy8oR.js +0 -1
- package/dist/chunks/sessionObserver-DMvWci8-.js +0 -1
- package/dist/chunks/sessionStorage-Diyuvt20.js +0 -1
- package/dist/chunks/sinks-CXq8-7Qn.js +0 -1
- package/dist/chunks/skillLearning-1ZfYIzfL.js +0 -1
- package/dist/chunks/thinkback-C6gV2LpU.js +0 -1
- package/dist/chunks/trustedDevice-DUrFWupL.js +0 -1
- package/dist/chunks/undercover-k3JoOKAb.js +0 -1
- package/dist/chunks/upgrade-D7iGU0PQ.js +0 -1
- package/dist/chunks/usage-DbRdMJog.js +0 -1
- package/dist/chunks/useMainLoopModel-DHkRIgNs.js +0 -1
- package/dist/chunks/worktree-DMhP5T0p.js +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{t as e}from"./REPL-CG2N7E4Q.js";export{e as REPL};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{n as e,o as t}from"./rolldown-runtime-DaDcL9Zw.js";import{I as n,P as r,fi as i,t as a}from"./src-CDCSSo0U2.js";import{t as o}from"./jsx-runtime-Bb4Xn-E0.js";import{mx as s,px as c}from"./loadAgentsDir-
|
|
1
|
+
import{n as e,o as t}from"./rolldown-runtime-DaDcL9Zw.js";import{I as n,P as r,fi as i,t as a}from"./src-CDCSSo0U2.js";import{t as o}from"./jsx-runtime-Bb4Xn-E0.js";import{mx as s,px as c}from"./loadAgentsDir-D206qwP3.js";import{b as l,c as u,g as d}from"./config-DmomySWC.js";import{Bt as f,Ot as p}from"./model-CKkOnnnx.js";import{i as m,r as h}from"./bridgeEnabled-SbB-6zdY.js";import{n as g,t as _}from"./PermissionDialog-0ya1CU5k.js";function v({onDone:e}){let t=(0,b.useRef)(e);t.current=e;let i=(0,b.useCallback)(()=>{t.current(`dismiss`)},[]);(0,b.useEffect)(()=>{l(e=>e.remoteDialogSeen?e:{...e,remoteDialogSeen:!0})},[]);let a=(0,b.useCallback)(e=>{t.current(e)},[]);return(0,x.jsx)(_,{title:`Remote Control`,children:(0,x.jsxs)(n,{flexDirection:`column`,paddingX:2,paddingY:1,children:[(0,x.jsxs)(n,{marginBottom:1,flexDirection:`column`,children:[(0,x.jsx)(r,{children:`Remote Control lets you access this CLI session from the web (claude.ai/code) or the Claude app, so you can pick up where you left off on any device.`}),(0,x.jsx)(r,{children:` `}),(0,x.jsx)(r,{children:`You can disconnect remote access anytime by running /remote-control again.`})]}),(0,x.jsx)(n,{children:(0,x.jsx)(c,{options:[{label:`Enable Remote Control for this session`,description:`Opens a secure connection to claude.ai.`,value:`enable`},{label:`Never mind`,description:`You can always enable it later with /remote-control.`,value:`dismiss`}],onChange:a,onCancel:i})})]})})}function y(){return!(u().remoteDialogSeen||!m()||!p()?.accessToken)}var b,x,S=e((()=>{b=t(i(),1),h(),a(),f(),d(),s(),g(),x=o()}));export{S as n,y as r,v as t};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{o as e}from"./rolldown-runtime-DaDcL9Zw.js";import{n as t,t as n}from"./memoize-BK3gG5ob.js";import{n as r,t as i}from"./defineProperty-C-QyHrDq.js";import{I as a,P as o,di as s,fi as c,j as l,t as u,ui as ee}from"./src-CDCSSo0U2.js";import{t as d}from"./jsx-runtime-Bb4Xn-E0.js";import{$D as f,As as p,DS as m,Dg as te,ES as h,Es as ne,FD as re,Fl as ie,ID as g,Il as ae,Mg as oe,Ng as se,Nr as ce,Pg as le,Tb as ue,Tg as de,Us as _,Vs as v,fr as y,jg as b,jr as x,kg as fe,mx as pe,px as me,tO as he,xg as ge,yb as S}from"./loadAgentsDir-
|
|
1
|
+
import{o as e}from"./rolldown-runtime-DaDcL9Zw.js";import{n as t,t as n}from"./memoize-BK3gG5ob.js";import{n as r,t as i}from"./defineProperty-C-QyHrDq.js";import{I as a,P as o,di as s,fi as c,j as l,t as u,ui as ee}from"./src-CDCSSo0U2.js";import{t as d}from"./jsx-runtime-Bb4Xn-E0.js";import{$D as f,As as p,DS as m,Dg as te,ES as h,Es as ne,FD as re,Fl as ie,ID as g,Il as ae,Mg as oe,Ng as se,Nr as ce,Pg as le,Tb as ue,Tg as de,Us as _,Vs as v,fr as y,jg as b,jr as x,kg as fe,mx as pe,px as me,tO as he,xg as ge,yb as S}from"./loadAgentsDir-D206qwP3.js";import{n as _e,t as C}from"./cwd-CYmmnQVS.js";import{C as ve,F as ye,S as w,a as T,l as E,w as D,z as O}from"./debug-BrXObCdR.js";import{Jt as k,Zt as A,f as j,g as M,n as N}from"./settings-BovzmwMP.js";import{b as P,c as F,g as I,o as L,y as be}from"./config-DmomySWC.js";import{_ as R,d as xe,g as Se,h as Ce}from"./git-Do0wJvux.js";import{n as z,r as we}from"./execFileNoThrow-D244NytW.js";import{o as B,s as V}from"./log-BMCygSzM.js";import{i as H,o as Te}from"./platform-BrYefG_2.js";import{n as Ee,r as De}from"./analytics-BotDBGh0.js";import{l as Oe,u as ke}from"./oauth-BqJqV-2M.js";import{Bt as Ae,Si as je,Vt as Me,_ as Ne,g as Pe,wi as Fe}from"./model-CKkOnnnx.js";import{c as Ie,h as Le,l as Re,m as U,s as ze}from"./proxy-CRN7jYIi.js";import{n as Be,o as W}from"./fileStateCache-DDW5toIs.js";import{d as Ve,o as He}from"./api-gqTA-D7n.js";import{c as Ue,u as We}from"./firstPartyEventLogger-CoSUd0a1.js";import{a as Ge,r as Ke,s as qe,t as Je}from"./referral-CUaIo_vT.js";import{c as Ye,i as Xe}from"./terminalSetup-CuV-qU6v.js";import{n as Ze,t as Qe}from"./PermissionDialog-0ya1CU5k.js";import{n as $e,r as et,t as tt}from"./overageCreditGrant-DsUrmeBh.js";import{i as nt,o as rt}from"./OverageCreditUpsell-Ds1cB7RC.js";import{n as it,t as at}from"./DesktopHandoff-BmPmCfT3.js";import{randomUUID as ot}from"crypto";n(),re(),_e(),I(),A(),we(),R(),B(),We();var st=[/(?:^|\/)(?:package-lock\.json|yarn\.lock|bun\.lock|bun\.lockb|pnpm-lock\.yaml|Pipfile\.lock|poetry\.lock|Cargo\.lock|Gemfile\.lock|go\.sum|composer\.lock|uv\.lock)$/,/\.generated\./,/(?:^|\/)(?:dist|build|out|target|node_modules|\.next|__pycache__)\//,/\.(?:min\.js|min\.css|map|pyc|pyo)$/,/\.(?:json|ya?ml|toml|xml|ini|cfg|conf|env|lock|txt|md|mdx|rst|csv|log|svg)$/i,/(?:^|\/)\.?(?:eslintrc|prettierrc|babelrc|editorconfig|gitignore|gitattributes|dockerignore|npmrc)/,/(?:^|\/)(?:tsconfig|jsconfig|biome|vitest\.config|jest\.config|webpack\.config|vite\.config|rollup\.config)\.[a-z]+$/,/(?:^|\/)\.(?:github|vscode|idea|claude)\//,/(?:^|\/)(?:CHANGELOG|LICENSE|CONTRIBUTING|CODEOWNERS|README)(?:\.[a-z]+)?$/i];function ct(e){return!st.some(t=>t.test(e))}function lt(e,t){let n=[],r=new Set,i=new Map;for(let a=1;n.length<t&&a<=t;a++)for(let o of e){if(n.length>=t)break;if(!ct(o))continue;let e=Math.max(o.lastIndexOf(`/`),o.lastIndexOf(`\\`)),s=e>=0?o.slice(e+1):o;if(!s||r.has(s))continue;let c=e>=0?o.slice(0,e):`.`;(i.get(c)??0)>=a||(n.push(s),r.add(s),i.set(c,(i.get(c)??0)+1))}return n.length>=t?n:[]}async function ut(){if(k.platform===`win32`||!await xe())return[];try{let e=await Ue(),t=[`log`,`-n`,`1000`,`--pretty=format:`,`--name-only`,`--diff-filter=M`],n=new Map,r=e=>{for(let t of e.split(`
|
|
2
2
|
`)){let e=t.trim();e&&n.set(e,(n.get(e)??0)+1)}};if(e){let{stdout:n}=await z(`git`,[...t,`--author=${e}`],{cwd:C()});r(n)}if(n.size<10){let{stdout:e}=await z(Se(),t,{cwd:C()});r(e)}return lt(Array.from(n.entries()).sort((e,t)=>t[1]-e[1]).map(([e])=>e),5)}catch(e){return V(e),[]}}var dt=10080*60*1e3,ft=t(()=>{let e=L(),t=e.exampleFiles?.length?g(e.exampleFiles):`<filepath>`;return`Try "${g([`fix lint errors`,`fix typecheck errors`,`how does ${t} work?`,`refactor ${t}`,`how do I log an error?`,`edit ${t} to...`,`write a test for ${t}`,`create a util logging.py that...`])}"`}),pt=t(async()=>{let e=L();Date.now()-(e.exampleFilesGeneratedAt??0)>dt&&(e.exampleFiles=[]),e.exampleFiles?.length||ut().then(e=>{e.length&&be(t=>({...t,exampleFiles:e,exampleFilesGeneratedAt:Date.now()}))})});Fe();var mt={"claude-3-opus":{modelName:`Claude 3 Opus`,retirementDates:{firstParty:`January 5, 2026`,bedrock:`January 15, 2026`,vertex:`January 5, 2026`,foundry:`January 5, 2026`}},"claude-3-7-sonnet":{modelName:`Claude 3.7 Sonnet`,retirementDates:{firstParty:`February 19, 2026`,bedrock:`April 28, 2026`,vertex:`May 11, 2026`,foundry:`February 19, 2026`}},"claude-3-5-haiku":{modelName:`Claude 3.5 Haiku`,retirementDates:{firstParty:`February 19, 2026`,bedrock:null,vertex:null,foundry:null}}};function ht(e){let t=e.toLowerCase(),n=je();for(let[e,r]of Object.entries(mt)){let i=r.retirementDates[n];if(!(!t.includes(e)||!i))return{isDeprecated:!0,modelName:r.modelName,retirementDate:i}}return{isDeprecated:!1}}function gt(e){if(!e)return null;let t=ht(e);return t.isDeprecated?`⚠ ${t.modelName} will be retired on ${t.retirementDate}. Consider switching to a newer model.`:null}r(),s(),O(),w(),T(),Te(),ke(),M(),Ae(),Xe(),ue(),ae(),x();var G=e(c(),1);u(),Ee(),I(),pe(),it(),Ze();var K=d(),_t={enable_shortcut_tip:!1,enable_startup_dialog:!1};function q(){return _t}function vt(){return process.platform===`darwin`||process.platform===`win32`&&process.arch===`x64`}function yt(){if(!vt()||!q().enable_startup_dialog)return!1;let e=F();return!(e.desktopUpsellDismissed||(e.desktopUpsellSeenCount??0)>=3)}function bt({onDone:e}){let[t,n]=(0,G.useState)(!1);if((0,G.useEffect)(()=>{let e=(F().desktopUpsellSeenCount??0)+1;P(t=>(t.desktopUpsellSeenCount??0)>=e?t:{...t,desktopUpsellSeenCount:e}),De(`tengu_desktop_upsell_shown`,{seen_count:e})},[]),t)return(0,K.jsx)(at,{onDone:()=>e()});function r(t){switch(t){case`try`:n(!0);return;case`never`:P(e=>e.desktopUpsellDismissed?e:{...e,desktopUpsellDismissed:!0}),e();return;case`not-now`:e();return}}return(0,K.jsx)(Qe,{title:`Try Claude Code Desktop`,children:(0,K.jsxs)(a,{flexDirection:`column`,paddingX:2,paddingY:1,children:[(0,K.jsx)(a,{marginBottom:1,children:(0,K.jsx)(o,{children:`Same Claude Code with visual diffs, live app preview, parallel sessions, and more.`})}),(0,K.jsx)(me,{options:[{label:`Open in Claude Code Desktop`,value:`try`},{label:`Not now`,value:`not-now`},{label:`Don't ask again`,value:`never`}],onChange:r,onCancel:()=>r(`not-now`)})]})})}Ne(),he(),W(),He(),m(),te(),v(),ne(),qe(),et(),nt(),I();function xt(e){let t=F().numStartups;P(n=>{let r=n.tipsHistory??{};return r[e]===t?n:{...n,tipsHistory:{...r,[e]:t}}})}function J(e){let t=F(),n=t.tipsHistory?.[e];return n?t.numStartups-n:1/0}u(),I(),A(),R();var Y;async function St(){return Y===void 0&&(Y=f in await _()),Y}async function X(e,t,n){if(!await St()||p(`${e}@claude-plugins-official`))return!1;let{bashTools:r}=t??{};return!!(n.cli&&r?.size&&n.cli.some(e=>r.has(e))||n.filePath&&t?.readFileState&&Be(t.readFileState).some(e=>n.filePath.test(e)))}var Ct=[{id:`new-user-warmup`,content:async()=>`Start with small features or bug fixes, tell Claude to propose a plan, and verify its suggested edits`,cooldownSessions:3,async isRelevant(){return F().numStartups<10}},{id:`plan-mode-for-complex-tasks`,content:async()=>`Use Plan Mode to prepare for a complex request before making changes. Press ${h(`chat:cycleMode`,`Chat`,`shift+tab`)} twice to enable.`,cooldownSessions:5,isRelevant:async()=>{let e=F();return(e.lastPlanModeUse?(Date.now()-e.lastPlanModeUse)/(1e3*60*60*24):1/0)>7}},{id:`default-permission-mode-config`,content:async()=>`Use /config to change your default permission mode (including Plan Mode)`,cooldownSessions:10,isRelevant:async()=>{try{let e=F(),t=j(),n=!!e.lastPlanModeUse,r=!!t?.permissions?.defaultMode;return n&&!r}catch(e){return E(`Failed to check default-permission-mode-config tip relevance: ${e}`,{level:`warn`}),!1}}},{id:`git-worktrees`,content:async()=>`Use git worktrees to run multiple Claude sessions in parallel.`,cooldownSessions:10,isRelevant:async()=>{try{let e=F();return await Ce()<=1&&e.numStartups>50}catch{return!1}}},{id:`color-when-multi-clauding`,content:async()=>`Running multiple Claude sessions? Use /color and /rename to tell them apart at a glance.`,cooldownSessions:10,isRelevant:async()=>!y()&&await ie()>=2},{id:`terminal-setup`,content:async()=>k.terminal===`Apple_Terminal`?`Run /terminal-setup to enable convenient terminal integration like Option + Enter for new line and more`:`Run /terminal-setup to enable convenient terminal integration like Shift + Enter for new line and more`,cooldownSessions:10,async isRelevant(){let e=F();return k.terminal===`Apple_Terminal`?!e.optionAsMetaKeyInstalled:!e.shiftEnterKeyBindingInstalled}},{id:`shift-enter`,content:async()=>k.terminal===`Apple_Terminal`?`Press Option+Enter to send a multi-line message`:`Press Shift+Enter to send a multi-line message`,cooldownSessions:10,async isRelevant(){let e=F();return!!((k.terminal===`Apple_Terminal`?e.optionAsMetaKeyInstalled:e.shiftEnterKeyBindingInstalled)&&e.numStartups>3)}},{id:`shift-enter-setup`,content:async()=>k.terminal===`Apple_Terminal`?`Run /terminal-setup to enable Option+Enter for new lines`:`Run /terminal-setup to enable Shift+Enter for new lines`,cooldownSessions:10,async isRelevant(){if(!Ye())return!1;let e=F();return!(k.terminal===`Apple_Terminal`?e.optionAsMetaKeyInstalled:e.shiftEnterKeyBindingInstalled)}},{id:`memory-command`,content:async()=>`Use /memory to view and manage Claude memory`,cooldownSessions:15,async isRelevant(){return F().memoryUsageCount<=0}},{id:`theme-command`,content:async()=>`Use /theme to change the color theme`,cooldownSessions:20,isRelevant:async()=>!0},{id:`colorterm-truecolor`,content:async()=>`Try setting environment variable COLORTERM=truecolor for richer colors`,cooldownSessions:30,isRelevant:async()=>!process.env.COLORTERM&&ee.level<3},{id:`powershell-tool-env`,content:async()=>`Set CLAUDE_CODE_USE_POWERSHELL_TOOL=1 to enable the PowerShell tool (preview)`,cooldownSessions:10,isRelevant:async()=>H()===`windows`&&process.env.CLAUDE_CODE_USE_POWERSHELL_TOOL===void 0},{id:`status-line`,content:async()=>`Use /statusline to set up a custom status line that will display beneath the input box`,cooldownSessions:25,isRelevant:async()=>j().statusLine===void 0},{id:`prompt-queue`,content:async()=>`Hit Enter to queue up additional messages while Claude is working.`,cooldownSessions:5,async isRelevant(){return F().promptQueueUseCount<=3}},{id:`enter-to-steer-in-relatime`,content:async()=>`Send messages to Claude while it works to steer Claude in real-time`,cooldownSessions:20,isRelevant:async()=>!0},{id:`todo-list`,content:async()=>`Ask Claude to create a todo list when working on complex tasks to track progress and remain on track`,cooldownSessions:20,isRelevant:async()=>!0},{id:`vscode-command-install`,content:async()=>`Open the Command Palette (Cmd+Shift+P) and run "Shell Command: Install '${k.terminal===`vscode`?`code`:k.terminal}' command in PATH" to enable IDE integration`,cooldownSessions:0,async isRelevant(){if(!oe()||H()!==`macos`)return!1;switch(k.terminal){case`vscode`:return!await se();case`cursor`:return!await fe();case`windsurf`:return!await le();default:return!1}}},{id:`ide-upsell-external-terminal`,content:async()=>`Connect Claude to your IDE · /ide`,cooldownSessions:4,async isRelevant(){return b()||(await de()).length!==0?!1:(await ge()).length>0}},{id:`permissions`,content:async()=>`Use /permissions to pre-approve and pre-deny bash, edit, and MCP tools`,cooldownSessions:10,async isRelevant(){return F().numStartups>10}},{id:`drag-and-drop-images`,content:async()=>`Did you know you can drag and drop image files into your terminal?`,cooldownSessions:10,isRelevant:async()=>!k.isSSH()},{id:`paste-images-mac`,content:async()=>`Paste images into Work Mate using control+v (not cmd+v!)`,cooldownSessions:10,isRelevant:async()=>H()===`macos`},{id:`double-esc`,content:async()=>`Double-tap esc to rewind the conversation to a previous point in time`,cooldownSessions:10,isRelevant:async()=>!S()},{id:`double-esc-code-restore`,content:async()=>`Double-tap esc to rewind the code and/or conversation to a previous point in time`,cooldownSessions:10,isRelevant:async()=>S()},{id:`continue`,content:async()=>`Run claude --continue or claude --resume to resume a conversation`,cooldownSessions:10,isRelevant:async()=>!0},{id:`rename-conversation`,content:async()=>`Name your conversations with /rename to find them easily in /resume later`,cooldownSessions:15,isRelevant:async()=>ce()&&F().numStartups>10},{id:`custom-commands`,content:async()=>`Create skills by adding .md files to .claude/skills/ in your project or ~/.claude/skills/ for skills that work in any project`,cooldownSessions:15,async isRelevant(){return F().numStartups>10}},{id:`shift-tab`,content:async()=>`Hit ${h(`chat:cycleMode`,`Chat`,`shift+tab`)} to cycle between default, accept edits, plan, auto, and bypass modes`,cooldownSessions:10,isRelevant:async()=>!0},{id:`image-paste`,content:async()=>`Use ${h(`chat:imagePaste`,`Chat`,`ctrl+v`)} to paste images from your clipboard`,cooldownSessions:20,isRelevant:async()=>!0},{id:`custom-agents`,content:async()=>`Use /agents to optimize specific tasks. Eg. Software Architect, Code Writer, Code Reviewer`,cooldownSessions:15,async isRelevant(){return F().numStartups>5}},{id:`agent-flag`,content:async()=>`Use --agent <agent_name> to directly start a conversation with a subagent`,cooldownSessions:15,async isRelevant(){return F().numStartups>5}},{id:`desktop-app`,content:async()=>`Run Work Mate locally or remotely using the Claude desktop app: clau.de/desktop`,cooldownSessions:15,isRelevant:async()=>H()!==`linux`},{id:`desktop-shortcut`,content:async e=>`Continue your session in Work Mate Desktop with ${l(`suggestion`,e?.theme??`dark`)(`/desktop`)}`,cooldownSessions:15,isRelevant:async()=>q().enable_shortcut_tip?process.platform===`darwin`||process.platform===`win32`&&process.arch===`x64`:!1},{id:`web-app`,content:async()=>`Run tasks in the cloud while you keep coding locally · clau.de/web`,cooldownSessions:15,isRelevant:async()=>!0},{id:`opusplan-mode-reminder`,content:async()=>`Your default model setting is Opus Plan Mode. Press ${h(`chat:cycleMode`,`Chat`,`shift+tab`)} twice to activate Plan Mode and plan with Claude Opus.`,cooldownSessions:2,async isRelevant(){if(process.env.USER_TYPE===`ant`)return!1;let e=F(),t=Pe()===`opusplan`,n=e.lastPlanModeUse?(Date.now()-e.lastPlanModeUse)/(1e3*60*60*24):1/0;return t&&n>3}},{id:`frontend-design-plugin`,content:async e=>`Working with HTML/CSS? Install the frontend-design plugin:\n${l(`suggestion`,e?.theme??`dark`)(`/plugin install frontend-design@${f}`)}`,cooldownSessions:3,isRelevant:async e=>X(`frontend-design`,e,{filePath:/\.(html|css|htm)$/i})},{id:`vercel-plugin`,content:async e=>`Working with Vercel? Install the vercel plugin:\n${l(`suggestion`,e?.theme??`dark`)(`/plugin install vercel@${f}`)}`,cooldownSessions:3,isRelevant:async e=>X(`vercel`,e,{filePath:/(?:^|[/\\])vercel\.json$/i,cli:[`vercel`]})},{id:`subagent-fanout-nudge`,content:async e=>`Say ${l(`suggestion`,e?.theme??`dark`)(`"fan out subagents"`)} and Claude sends a team. Each one digs deep so nothing gets missed.`,cooldownSessions:3,isRelevant:async()=>(Me(),!1)},{id:`guest-passes`,content:async e=>{let t=l(`claude`,e?.theme??`dark`),n=Ge();return n?`Share Work Mate and earn ${t(Ke(n))} of extra usage · ${t(`/passes`)}`:`You have free guest passes to share · ${t(`/passes`)}`},cooldownSessions:3,isRelevant:async()=>{if(F().hasVisitedPasses)return!1;let{eligible:e}=Je();return e}},{id:`overage-credit`,content:async e=>{let t=l(`claude`,e?.theme??`dark`),n=$e(),r=n?tt(n):null;return r?`${t(`${r} in extra usage, on us`)} · third-party apps · ${t(`/extra-usage`)}`:``},cooldownSessions:3,isRelevant:async()=>rt()},{id:`feedback-command`,content:async()=>`Use /feedback to help us improve!`,cooldownSessions:15,async isRelevant(){return process.env.USER_TYPE!==`ant`&&F().numStartups>5}}],wt=process.env.USER_TYPE===`ant`?[{id:`important-claudemd`,content:async()=>`[ANT-ONLY] Use "IMPORTANT:" prefix for must-follow CLAUDE.md rules`,cooldownSessions:30,isRelevant:async()=>!0},{id:`skillify`,content:async()=>`[ANT-ONLY] Use /skillify at the end of a workflow to turn it into a reusable skill`,cooldownSessions:15,isRelevant:async()=>!0}]:[];function Tt(){let e=N().spinnerTipsOverride;return e?.tips?.length?e.tips.map((e,t)=>({id:`custom-tip-${t}`,content:async()=>e,cooldownSessions:0,isRelevant:async()=>!0})):[]}async function Et(e){let t=N().spinnerTipsOverride,n=Tt();if(t?.excludeDefault&&n.length>0)return n;let r=[...Ct,...wt],i=await Promise.all(r.map(t=>t.isRelevant?.(e)??Promise.resolve(!0)));return[...r.filter((e,t)=>i[t]).filter(e=>J(e.id)>=e.cooldownSessions),...n]}T(),B(),Le(),Re();var Z=2e3,Q=5,Dt=3e4,$=3,Ot=new Set([4003]);function kt(e){return typeof e!=`object`||!e||!(`type`in e)?!1:typeof e.type==`string`}var At=class{constructor(e,t,n,r){i(this,`sessionId`,void 0),i(this,`orgUuid`,void 0),i(this,`getAccessToken`,void 0),i(this,`callbacks`,void 0),i(this,`ws`,null),i(this,`state`,`closed`),i(this,`reconnectAttempts`,0),i(this,`sessionNotFoundRetries`,0),i(this,`pingInterval`,null),i(this,`reconnectTimer`,null),this.sessionId=e,this.orgUuid=t,this.getAccessToken=n,this.callbacks=r}async connect(){if(this.state===`connecting`){E(`[SessionsWebSocket] Already connecting`);return}this.state=`connecting`;let e=`${Oe().BASE_API_URL.replace(`http`,`ws`)}/v1/sessions/ws/${this.sessionId}/subscribe?organization_uuid=${this.orgUuid}`;E(`[SessionsWebSocket] Connecting to ${e}`);let t={Authorization:`Bearer ${this.getAccessToken()}`,"anthropic-version":`2023-06-01`};if(typeof Bun<`u`){let n=new globalThis.WebSocket(e,{headers:t,proxy:Ie(e),tls:U()||void 0});this.ws=n,n.addEventListener(`open`,()=>{E(`[SessionsWebSocket] Connection opened, authenticated via headers`),this.state=`connected`,this.reconnectAttempts=0,this.sessionNotFoundRetries=0,this.startPingInterval(),this.callbacks.onConnected?.()}),n.addEventListener(`message`,e=>{let t=typeof e.data==`string`?e.data:String(e.data);this.handleMessage(t)}),n.addEventListener(`error`,()=>{let e=Error(`[SessionsWebSocket] WebSocket error`);V(e),this.callbacks.onError?.(e)}),n.addEventListener(`close`,e=>{E(`[SessionsWebSocket] Closed: code=${e.code} reason=${e.reason}`),this.handleClose(e.code)}),n.addEventListener(`pong`,()=>{E(`[SessionsWebSocket] Pong received`)})}else{let{default:n}=await import(`./wrapper-K8ZapJVu.js`),r=new n(e,{headers:t,agent:ze(e),...U()});this.ws=r,r.on(`open`,()=>{E(`[SessionsWebSocket] Connection opened, authenticated via headers`),this.state=`connected`,this.reconnectAttempts=0,this.sessionNotFoundRetries=0,this.startPingInterval(),this.callbacks.onConnected?.()}),r.on(`message`,e=>{this.handleMessage(e.toString())}),r.on(`error`,e=>{V(Error(`[SessionsWebSocket] Error: ${e.message}`)),this.callbacks.onError?.(e)}),r.on(`close`,(e,t)=>{E(`[SessionsWebSocket] Closed: code=${e} reason=${t.toString()}`),this.handleClose(e)}),r.on(`pong`,()=>{E(`[SessionsWebSocket] Pong received`)})}}handleMessage(e){try{let t=ve(e);kt(t)?this.callbacks.onMessage(t):E(`[SessionsWebSocket] Ignoring message type: ${typeof t==`object`&&t&&`type`in t?String(t.type):`unknown`}`)}catch(e){V(Error(`[SessionsWebSocket] Failed to parse message: ${ye(e)}`))}}handleClose(e){if(this.stopPingInterval(),this.state===`closed`)return;this.ws=null;let t=this.state;if(this.state=`closed`,Ot.has(e)){E(`[SessionsWebSocket] Permanent close code ${e}, not reconnecting`),this.callbacks.onClose?.();return}if(e===4001){if(this.sessionNotFoundRetries++,this.sessionNotFoundRetries>$){E(`[SessionsWebSocket] 4001 retry budget exhausted (${$}), not reconnecting`),this.callbacks.onClose?.();return}this.scheduleReconnect(Z*this.sessionNotFoundRetries,`4001 attempt ${this.sessionNotFoundRetries}/${$}`);return}t===`connected`&&this.reconnectAttempts<Q?(this.reconnectAttempts++,this.scheduleReconnect(Z,`attempt ${this.reconnectAttempts}/${Q}`)):(E(`[SessionsWebSocket] Not reconnecting`),this.callbacks.onClose?.())}scheduleReconnect(e,t){this.callbacks.onReconnecting?.(),E(`[SessionsWebSocket] Scheduling reconnect (${t}) in ${e}ms`),this.reconnectTimer=setTimeout(()=>{this.reconnectTimer=null,this.connect()},e)}startPingInterval(){this.stopPingInterval(),this.pingInterval=setInterval(()=>{if(this.ws&&this.state===`connected`)try{this.ws.ping?.()}catch{}},Dt)}stopPingInterval(){this.pingInterval&&(clearInterval(this.pingInterval),this.pingInterval=null)}sendControlResponse(e){if(!this.ws||this.state!==`connected`){V(Error(`[SessionsWebSocket] Cannot send: not connected`));return}E(`[SessionsWebSocket] Sending control response`),this.ws.send(D(e))}sendControlRequest(e){if(!this.ws||this.state!==`connected`){V(Error(`[SessionsWebSocket] Cannot send: not connected`));return}let t={type:`control_request`,request_id:ot(),request:e};E(`[SessionsWebSocket] Sending control request: ${e.subtype}`),this.ws.send(D(t))}isConnected(){return this.state===`connected`}close(){E(`[SessionsWebSocket] Closing connection`),this.state=`closed`,this.stopPingInterval(),this.reconnectTimer&&(clearTimeout(this.reconnectTimer),this.reconnectTimer=null),this.ws&&(this.ws.close(),this.ws=null)}reconnect(){E(`[SessionsWebSocket] Force reconnecting`),this.reconnectAttempts=0,this.sessionNotFoundRetries=0,this.close(),this.reconnectTimer=setTimeout(()=>{this.reconnectTimer=null,this.connect()},500)}};T(),B(),r();function jt(e){return e.type!==`control_request`&&e.type!==`control_response`&&e.type!==`control_cancel_request`}var Mt=class{constructor(e,t){i(this,`config`,void 0),i(this,`callbacks`,void 0),i(this,`websocket`,null),i(this,`pendingPermissionRequests`,new Map),this.config=e,this.callbacks=t}connect(){E(`[RemoteSessionManager] Connecting to session ${this.config.sessionId}`);let e={onMessage:e=>this.handleMessage(e),onConnected:()=>{E(`[RemoteSessionManager] Connected`),this.callbacks.onConnected?.()},onClose:()=>{E(`[RemoteSessionManager] Disconnected`),this.callbacks.onDisconnected?.()},onReconnecting:()=>{E(`[RemoteSessionManager] Reconnecting`),this.callbacks.onReconnecting?.()},onError:e=>{V(e),this.callbacks.onError?.(e)}};this.websocket=new At(this.config.sessionId,this.config.orgUuid,this.config.getAccessToken,e),this.websocket.connect()}handleMessage(e){if(e.type===`control_request`){this.handleControlRequest(e);return}if(e.type===`control_cancel_request`){let{request_id:t}=e,n=this.pendingPermissionRequests.get(t);E(`[RemoteSessionManager] Permission request cancelled: ${t}`),this.pendingPermissionRequests.delete(t),this.callbacks.onPermissionCancelled?.(t,n?.tool_use_id);return}if(e.type===`control_response`){E(`[RemoteSessionManager] Received control response`);return}jt(e)&&this.callbacks.onMessage(e)}handleControlRequest(e){let t=e.request_id,n=e.request;if(n.subtype===`can_use_tool`)E(`[RemoteSessionManager] Permission request for tool: ${n.tool_name}`),this.pendingPermissionRequests.set(t,n),this.callbacks.onPermissionRequest(n,t);else{E(`[RemoteSessionManager] Unsupported control request subtype: ${n.subtype}`);let e={type:`control_response`,response:{subtype:`error`,request_id:t,error:`Unsupported control request subtype: ${n.subtype}`}};this.websocket?.sendControlResponse(e)}}async sendMessage(e,t){E(`[RemoteSessionManager] Sending message to session ${this.config.sessionId}`);let n=await Ve(this.config.sessionId,e,t);return n||V(Error(`[RemoteSessionManager] Failed to send message to session ${this.config.sessionId}`)),n}respondToPermissionRequest(e,t){if(!this.pendingPermissionRequests.get(e)){V(Error(`[RemoteSessionManager] No pending permission request with ID: ${e}`));return}this.pendingPermissionRequests.delete(e);let n={type:`control_response`,response:{subtype:`success`,request_id:e,response:{behavior:t.behavior,...t.behavior===`allow`?{updatedInput:t.updatedInput}:{message:t.message}}}};E(`[RemoteSessionManager] Sending permission response: ${t.behavior}`),this.websocket?.sendControlResponse(n)}isConnected(){return this.websocket?.isConnected()??!1}cancelSession(){E(`[RemoteSessionManager] Sending interrupt signal`),this.websocket?.sendControlRequest({subtype:`interrupt`})}getSessionId(){return this.config.sessionId}disconnect(){E(`[RemoteSessionManager] Disconnecting`),this.websocket?.close(),this.websocket=null,this.pendingPermissionRequests.clear()}reconnect(){E(`[RemoteSessionManager] Reconnecting WebSocket`),this.websocket?.reconnect()}};function Nt(e,t,n,r=!1,i=!1){return{sessionId:e,getAccessToken:t,orgUuid:n,hasInitialPrompt:r,viewerOnly:i}}export{xt as a,gt as c,J as i,ft as l,Nt as n,bt as o,Et as r,yt as s,Mt as t,pt as u};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as e,o as t}from"./rolldown-runtime-DaDcL9Zw.js";import{I as n,P as r,Wt as i,dr as a,fi as o,ot as ee,t as s}from"./src-CDCSSo0U2.js";import{t as c}from"./jsx-runtime-Bb4Xn-E0.js";import{en as l,vr as te}from"./state-ix0xIunV.js";import{Fb as u,Hr as ne,Hy as d,Il as f,Jn as re,KS as ie,Nb as p,Nr as ae,RC as oe,US as m,Uy as h,Vl as se,WS as ce,aC as g,ar as le,fi as ue,jr as _,nd as de,op as v,pi as y,qr as b,rd as x,sp as S,ti as fe,zC as C}from"./loadAgentsDir-
|
|
1
|
+
import{a as e,o as t}from"./rolldown-runtime-DaDcL9Zw.js";import{I as n,P as r,Wt as i,dr as a,fi as o,ot as ee,t as s}from"./src-CDCSSo0U2.js";import{t as c}from"./jsx-runtime-Bb4Xn-E0.js";import{en as l,vr as te}from"./state-ix0xIunV.js";import{Fb as u,Hr as ne,Hy as d,Il as f,Jn as re,KS as ie,Nb as p,Nr as ae,RC as oe,US as m,Uy as h,Vl as se,WS as ce,aC as g,ar as le,fi as ue,jr as _,nd as de,op as v,pi as y,qr as b,rd as x,sp as S,ti as fe,zC as C}from"./loadAgentsDir-D206qwP3.js";import{o as w,s as T}from"./log-BMCygSzM.js";import{n as E,r as D}from"./analytics-BotDBGh0.js";import{u as O}from"./referral-CUaIo_vT.js";import{r as pe}from"./asciicast-CbAjUHT_.js";import{a as me,n as k,s as A}from"./skillChangeDetector-DNqohXxz.js";import{a as j,i as M,n as N,o as P,r as F,t as I}from"./crossProjectResume-BasMLl2n.js";import{t as L}from"./REPL-CG2N7E4Q.js";import{dirname as R}from"path";var z=t(o(),1);g(),l(),P(),u(),v(),s(),O(),E(),m(),C(),M(),f(),d(),N(),w(),_();var B=c();function he(e){let t=parseInt(e,10);if(!isNaN(t)&&t>0)return t;let n=e.match(/github\.com\/[^/]+\/[^/]+\/pull\/(\d+)/);return n?.[1]?parseInt(n[1],10):null}function V({commands:t,worktreePaths:i,initialTools:o,mcpClients:s,dynamicMcpConfig:c,debug:l,mainThreadAgentDefinition:u,autoConnectIdeFlag:d,strictMcpConfig:f=!1,systemPrompt:m,appendSystemPrompt:g,initialSearchQuery:_,disableSlashCommands:v=!1,forkSession:C,taskListId:w,filterByPr:E,thinkingConfig:O,onTurnComplete:M}){let{rows:N}=ee(),P=ce(e=>e.agentDefinitions),V=ie(),[H,U]=z.useState([]),[ve,W]=z.useState(!0),[ye,be]=z.useState(!1),[G,xe]=z.useState(!1),[K,q]=z.useState(null),[J,Se]=z.useState(null),Y=z.useRef(null),X=z.useRef(0),Z=z.useMemo(()=>{let e=H.filter(e=>!e.isSidechain);if(E!==void 0){if(E===!0)e=e.filter(e=>e.prNumber!==void 0);else if(typeof E==`number`)e=e.filter(e=>e.prNumber===E);else if(typeof E==`string`){let t=he(E);t!==null&&(e=e.filter(e=>e.prNumber===t))}}return e},[H,E]),Ce=ae();z.useEffect(()=>{b(i).then(e=>{Y.current=e,X.current=e.logs.length,U(e.logs),W(!1)}).catch(e=>{T(e),W(!1)})},[i]);let Q=z.useCallback(e=>{let t=Y.current;!t||t.nextIndex>=t.allStatLogs.length||le(t.allStatLogs,t.nextIndex,e).then(n=>{if(t.nextIndex=n.nextIndex,n.logs.length>0){let e=X.current;n.logs.forEach((t,n)=>{t.value=e+n}),U(e=>e.concat(n.logs)),X.current+=n.logs.length}else t.nextIndex<t.allStatLogs.length&&Q(e)})},[]),$=z.useCallback(e=>{W(!0),(e?ne():b(i)).then(e=>{Y.current=e,X.current=e.logs.length,U(e.logs)}).catch(e=>{T(e)}).finally(()=>{W(!1)})},[i]),we=z.useCallback(()=>{let e=!G;xe(e),$(e)},[G,$]);function Te(){process.exit(1)}async function Ee(t){be(!0);let n=performance.now(),r=I(t,G,i);if(r.isCrossProject&&!r.isSameRepoWorktree){let e=r.command,t=await a(e);t&&process.stdout.write(t),Se(e);return}try{let r=await h(t,void 0);if(!r)throw Error(`Failed to load conversation`);r.sessionId&&!C?(te(oe(r.sessionId),t.fullPath?R(t.fullPath):null),await pe(),await ue(),S(r.sessionId)):C&&r.contentReplacements?.length&&await fe(r.contentReplacements);let{agentDefinition:i}=me(r.agentSetting,u,P);V(e=>({...e,agent:i?.agentType}));let a=k(r.agentName,r.agentColor);if(a&&V(e=>({...e,standaloneAgentContext:a})),se(r.agentName),y(C?{...r,worktreeSession:void 0}:r),C||(A(r.worktreeSession),r.sessionId&&re()),r.goal&&r.sessionId){let{hydrateGoalFromTranscript:t}=(x(),e(de)),n=new Map;n.set(r.sessionId,r.goal),t(n,r.sessionId)}D(`tengu_session_resumed`,{entrypoint:`picker`,success:!0,resume_duration_ms:Math.round(performance.now()-n)}),U([]),q({messages:r.messages,fileHistorySnapshots:r.fileHistorySnapshots,contentReplacements:r.contentReplacements,agentName:r.agentName,agentColor:r.agentColor==="default"?void 0:r.agentColor,mainThreadAgentDefinition:i})}catch(e){throw D(`tengu_session_resumed`,{entrypoint:`picker`,success:!1}),T(e),e}}return J?(0,B.jsx)(_e,{command:J}):K?(0,B.jsx)(L,{debug:l,commands:t,initialTools:o,initialMessages:K.messages,initialFileHistorySnapshots:K.fileHistorySnapshots,initialContentReplacements:K.contentReplacements,initialAgentName:K.agentName,initialAgentColor:K.agentColor,mcpClients:s,dynamicMcpConfig:c,strictMcpConfig:f,systemPrompt:m,appendSystemPrompt:g,mainThreadAgentDefinition:K.mainThreadAgentDefinition,autoConnectIdeFlag:d,disableSlashCommands:v,taskListId:w,thinkingConfig:O,onTurnComplete:M}):ve?(0,B.jsxs)(n,{children:[(0,B.jsx)(p,{}),(0,B.jsx)(r,{children:` Loading conversations…`})]}):ye?(0,B.jsxs)(n,{children:[(0,B.jsx)(p,{}),(0,B.jsx)(r,{children:` Resuming conversation…`})]}):Z.length===0?(0,B.jsx)(ge,{}):(0,B.jsx)(j,{logs:Z,maxHeight:N,onCancel:Te,onSelect:Ee,onLogsChanged:Ce?()=>$(G):void 0,onLoadMore:Q,initialSearchQuery:_,showAllProjects:G,onToggleAllProjects:we,onAgenticSearch:F})}function ge(){return i(`app:interrupt`,()=>{process.exit(1)},{context:`Global`}),(0,B.jsxs)(n,{flexDirection:`column`,children:[(0,B.jsx)(r,{children:`No conversations found to resume.`}),(0,B.jsx)(r,{dimColor:!0,children:`Press Ctrl+C to exit and start a new conversation.`})]})}function _e({command:e}){return z.useEffect(()=>{let e=setTimeout(()=>{process.exit(0)},100);return()=>clearTimeout(e)},[]),(0,B.jsxs)(n,{flexDirection:`column`,gap:1,children:[(0,B.jsx)(r,{children:`This conversation is from a different directory.`}),(0,B.jsxs)(n,{flexDirection:`column`,children:[(0,B.jsx)(r,{children:`To resume, run:`}),(0,B.jsxs)(r,{children:[` `,e]})]}),(0,B.jsx)(r,{dimColor:!0,children:`(Command copied to clipboard)`})]})}export{V as ResumeConversation};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{n as e}from"./rolldown-runtime-DaDcL9Zw.js";import{n as t,t as n}from"./defineProperty-C-QyHrDq.js";import{n as r,t as i}from"./axios-DaWTGg7G.js";import{C as a,F as o,S as s,a as c,l,w as u,z as d}from"./debug-BrXObCdR.js";import{M as f,j as p}from"./git-Do0wJvux.js";import{_n as m,ar as h,or as g,vn as _}from"./model-
|
|
1
|
+
import{n as e}from"./rolldown-runtime-DaDcL9Zw.js";import{n as t,t as n}from"./defineProperty-C-QyHrDq.js";import{n as r,t as i}from"./axios-DaWTGg7G.js";import{C as a,F as o,S as s,a as c,l,w as u,z as d}from"./debug-BrXObCdR.js";import{M as f,j as p}from"./git-Do0wJvux.js";import{_n as m,ar as h,or as g,vn as _}from"./model-CKkOnnnx.js";import{E as v,O as y,n as b,t as x}from"./rcDebugLog-CUy1_F23.js";function S(){return!0}function C(e){let t=[],n=0,r=/\r?\n\r?\n/g;r.lastIndex=n;let i;for(;(i=r.exec(e))!==null;){let r=i.index,a=e.slice(n,r);if(n=r+i[0].length,!a.trim())continue;let o={},s=!1;for(let e of a.split(`
|
|
2
2
|
`)){let t=e[e.length-1]===`\r`?e.slice(0,-1):e;if(t.startsWith(`:`)){s=!0;continue}let n=t.indexOf(`:`);if(n===-1)continue;let r=t.slice(0,n),i=t[n+1]===` `?t.slice(n+2):t.slice(n+1);switch(r){case`event`:o.event=i;break;case`id`:o.id=i;break;case`data`:o.data=o.data?o.data+`
|
|
3
3
|
`+i:i;break}}(o.data||s)&&t.push(o)}return{frames:t,remaining:e.slice(n)}}function w(e){let t=e.pathname;return t.endsWith(`/stream`)&&(t=t.slice(0,-7)),`${e.protocol}//${e.host}${t}`}var T,E,D,O,k,A,j,M,N,P,F=e((()=>{i(),c(),x(),p(),d(),y(),m(),s(),g(),t(),T=1e3,E=3e4,D=6e5,O=45e3,k=new Set([401,403,404]),A=10,j=500,M=8e3,N={stream:!0},P=class{constructor(e,t={},r,i,a,o){n(this,`url`,void 0),n(this,`state`,`idle`),n(this,`onData`,void 0),n(this,`onCloseCallback`,void 0),n(this,`onEventCallback`,void 0),n(this,`headers`,void 0),n(this,`sessionId`,void 0),n(this,`refreshHeaders`,void 0),n(this,`getAuthHeaders`,void 0),n(this,`abortController`,null),n(this,`lastSequenceNum`,0),n(this,`seenSequenceNums`,new Set),n(this,`reconnectAttempts`,0),n(this,`reconnectStartTime`,null),n(this,`reconnectTimer`,null),n(this,`livenessTimer`,null),n(this,`lastActivityTime`,0),n(this,`postUrl`,void 0),n(this,`onLivenessTimeout`,()=>{this.livenessTimer=null,b(`SSE liveness timeout (${O}ms) lastSeqNum=${this.getLastSequenceNum()} state=${this.state}`),l(`SSETransport: Liveness timeout, reconnecting`,{level:`error`}),f(`error`,`cli_sse_liveness_timeout`),this.abortController?.abort(),this.handleConnectionError()}),this.url=e,this.headers=t,this.sessionId=r,this.refreshHeaders=i,this.getAuthHeaders=o??v,this.postUrl=w(e),a!==void 0&&a>0&&(this.lastSequenceNum=a),l(`SSETransport: SSE URL = ${e.href}`),l(`SSETransport: POST URL = ${this.postUrl}`),f(`info`,`cli_sse_transport_initialized`)}getLastSequenceNum(){return this.lastSequenceNum}async connect(){if(this.state!==`idle`&&this.state!==`reconnecting`){l(`SSETransport: Cannot connect, current state is ${this.state}`,{level:`error`}),f(`error`,`cli_sse_connect_failed`);return}this.state=`reconnecting`;let e=Date.now(),t=new URL(this.url.href);this.lastSequenceNum>0&&t.searchParams.set(`from_sequence_num`,String(this.lastSequenceNum));let n=this.getAuthHeaders(),r={...this.headers,...n,Accept:`text/event-stream`,"anthropic-version":`2023-06-01`,"User-Agent":h()};n.Cookie&&delete r.Authorization,this.lastSequenceNum>0&&(r[`Last-Event-ID`]=String(this.lastSequenceNum)),l(`SSETransport: Opening ${t.href}`),f(`info`,`cli_sse_connect_opening`),this.abortController=new AbortController;try{let n=await fetch(t.href,{headers:r,signal:this.abortController.signal});if(!n.ok){let e=k.has(n.status);if(l(`SSETransport: HTTP ${n.status}${e?` (permanent)`:``}`,{level:`error`}),f(`error`,`cli_sse_connect_http_error`,{status:n.status}),e){this.state=`closed`,this.onCloseCallback?.(n.status);return}this.handleConnectionError();return}if(!n.body){l(`SSETransport: No response body`),this.handleConnectionError();return}let i=Date.now()-e;l(`SSETransport: Connected`),f(`info`,`cli_sse_connect_connected`,{duration_ms:i}),this.state=`connected`,this.reconnectAttempts=0,this.reconnectStartTime=null,this.resetLivenessTimer(),await this.readStream(n.body)}catch(e){if(this.abortController?.signal.aborted)return;l(`SSETransport: Connection error: ${o(e)}`,{level:`error`}),f(`error`,`cli_sse_connect_error`),this.handleConnectionError()}}async readStream(e){let t=e.getReader(),n=new TextDecoder,r=``,i=1024*1024;try{for(;;){let{done:e,value:a}=await t.read();if(e)break;if(r+=n.decode(a,N),r.length>i){l(`SSETransport: Buffer exceeded ${i} bytes — dropping connection`,{level:`error`}),f(`error`,`cli_sse_buffer_overflow`);break}let{frames:o,remaining:s}=C(r);r=s;for(let e of o){if(this.resetLivenessTimer(),e.id){let t=parseInt(e.id,10);if(!isNaN(t)){if(this.seenSequenceNums.has(t))l(`SSETransport: DUPLICATE frame seq=${t} (lastSequenceNum=${this.lastSequenceNum}, seenCount=${this.seenSequenceNums.size})`,{level:`warn`}),f(`warn`,`cli_sse_duplicate_sequence`);else if(this.seenSequenceNums.add(t),this.seenSequenceNums.size>1e3){let e=this.lastSequenceNum-200;for(let t of this.seenSequenceNums)t<e&&this.seenSequenceNums.delete(t)}t>this.lastSequenceNum&&(this.lastSequenceNum=t)}}e.event&&e.data?this.handleSSEFrame(e.event,e.data):e.data&&(l(`SSETransport: Frame has data: but no event: field — dropped`,{level:`warn`}),f(`warn`,`cli_sse_frame_missing_event_field`))}}}catch(e){if(this.abortController?.signal.aborted)return;l(`SSETransport: Stream read error: ${o(e)}`,{level:`error`}),f(`error`,`cli_sse_stream_read_error`)}finally{t.releaseLock()}this.state!==`closing`&&this.state!==`closed`&&(l(`SSETransport: Stream ended, reconnecting`),this.handleConnectionError())}handleSSEFrame(e,t){if(e!==`client_event`){l(`SSETransport: Unexpected SSE event type '${e}' on worker stream`,{level:`warn`}),f(`warn`,`cli_sse_unexpected_event_type`,{event_type:e});return}let n;try{n=a(t)}catch(e){l(`SSETransport: Failed to parse client_event data: ${o(e)}`,{level:`error`});return}let r=n.payload;if(r&&typeof r==`object`&&`type`in r){let e=this.sessionId?` session=${this.sessionId}`:``;l(`SSETransport: Event seq=${n.sequence_num} event_id=${n.event_id} event_type=${n.event_type} payload_type=${String(r.type)}${e}`),f(`info`,`cli_sse_message_received`),this.onData?.(u(r)+`
|
|
4
4
|
`)}else l(`SSETransport: Ignoring client_event with no type in payload: event_id=${n.event_id}`);this.onEventCallback?.(n)}handleConnectionError(){if(b(`SSE handleConnectionError: state=${this.state} lastSeqNum=${this.getLastSequenceNum()} reconnectAttempts=${this.reconnectAttempts} msSinceLastActivity=${this.lastActivityTime>0?Date.now()-this.lastActivityTime:-1}`),this.clearLivenessTimer(),this.state===`closing`||this.state===`closed`)return;this.abortController?.abort(),this.abortController=null;let e=Date.now();this.reconnectStartTime||(this.reconnectStartTime=e);let t=e-this.reconnectStartTime;if(t<D){if(this.reconnectTimer&&(clearTimeout(this.reconnectTimer),this.reconnectTimer=null),this.refreshHeaders){let e=this.refreshHeaders();Object.assign(this.headers,e),l(`SSETransport: Refreshed headers for reconnect`)}this.state=`reconnecting`,this.reconnectAttempts++;let e=Math.min(T*2**(this.reconnectAttempts-1),E),n=Math.max(0,e+e*.25*(2*Math.random()-1));l(`SSETransport: Reconnecting in ${Math.round(n)}ms (attempt ${this.reconnectAttempts}, ${Math.round(t/1e3)}s elapsed)`),f(`error`,`cli_sse_reconnect_attempt`,{reconnectAttempts:this.reconnectAttempts}),this.reconnectTimer=setTimeout(()=>{this.reconnectTimer=null,this.connect()},n)}else l(`SSETransport: Reconnection time budget exhausted after ${Math.round(t/1e3)}s`,{level:`error`}),f(`error`,`cli_sse_reconnect_exhausted`,{reconnectAttempts:this.reconnectAttempts,elapsedMs:t}),this.state=`closed`,this.onCloseCallback?.()}resetLivenessTimer(){this.clearLivenessTimer(),this.livenessTimer=setTimeout(this.onLivenessTimeout,O)}clearLivenessTimer(){this.livenessTimer&&(clearTimeout(this.livenessTimer),this.livenessTimer=null)}async write(e){let t=this.getAuthHeaders();if(Object.keys(t).length===0){l(`SSETransport: No session token available for POST`),f(`warn`,`cli_sse_post_no_token`);return}let n={...t,"Content-Type":`application/json`,"anthropic-version":`2023-06-01`,"User-Agent":h()};l(`SSETransport: POST body keys=${Object.keys(e).join(`,`)}`);for(let t=1;t<=A;t++){try{let i=await r.post(this.postUrl,e,{headers:n,validateStatus:S});if(i.status===200||i.status===201){l(`SSETransport: POST success type=${e.type}`);return}if(l(`SSETransport: POST ${i.status} body=${u(i.data).slice(0,200)}`),i.status>=400&&i.status<500&&i.status!==429){l(`SSETransport: POST returned ${i.status} (client error), not retrying`),f(`warn`,`cli_sse_post_client_error`,{status:i.status});return}l(`SSETransport: POST returned ${i.status}, attempt ${t}/${A}`),f(`warn`,`cli_sse_post_retryable_error`,{status:i.status,attempt:t})}catch(e){l(`SSETransport: POST error: ${e.message}, attempt ${t}/${A}`),f(`warn`,`cli_sse_post_network_error`,{attempt:t})}if(t===A){l(`SSETransport: POST failed after ${A} attempts, continuing`),f(`warn`,`cli_sse_post_retries_exhausted`);return}await _(Math.min(j*2**(t-1),M))}}isConnectedStatus(){return this.state===`connected`}isClosedStatus(){return this.state===`closed`}setOnData(e){this.onData=e}setOnClose(e){this.onCloseCallback=e}setOnEvent(e){this.onEventCallback=e}close(){this.reconnectTimer&&(clearTimeout(this.reconnectTimer),this.reconnectTimer=null),this.clearLivenessTimer(),this.state=`closing`,this.abortController?.abort(),this.abortController=null}}}));export{F as n,C as r,P as t};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{iE as e,rE as t}from"./loadAgentsDir-D206qwP3.js";e();export{t as clearSearchExtraToolsDescriptionCache};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{a as e,n as t,o as n}from"./rolldown-runtime-DaDcL9Zw.js";import{d as r,l as i,o as a}from"./envUtils-DSxRz_kt.js";import{n as o,t as s}from"./figures-5ThXQEtq.js";import{D as c,Gt as l,H as u,I as d,P as f,T as p,U as ee,Wt as te,Xn as ne,a as re,d as ie,di as m,fi as h,k as ae,n as oe,ot as se,r as ce,t as g,ui as _,x as v,y as le}from"./src-CDCSSo0U2.js";import{t as y}from"./jsx-runtime-Bb4Xn-E0.js";import{en as b,gr as ue,ht as x,qt as de}from"./state-ix0xIunV.js";import{BE as fe,C as S,Dg as pe,Eg as me,F as he,Fx as C,GS as ge,Hx as _e,KS as ve,LE as ye,Px as be,S as xe,Sx as w,US as Se,Ux as Ce,VE as we,WS as T,aC as E,af as Te,ah as Ee,as as D,fx as O,if as De,is as k,jg as Oe,jr as A,mr as ke,mx as Ae,oh as je,op as j,os as M,px as Me,rp as Ne,v as Pe,xx as N,zE as Fe}from"./loadAgentsDir-Clu7Uk6a.js";import{n as Ie,t as Le}from"./cwd-CYmmnQVS.js";import{S as Re,w as ze}from"./debug-BrXObCdR.js";import{Ft as Be,Ht as Ve,Lt as He,Rt as Ue,c as We,g as P,n as Ge,y as F,zt as Ke}from"./settings-Dlp5JTa_.js";import{a as qe,b as I,c as L,g as Je,i as Ye,m as Xe,o as Ze}from"./config-3m_9zSrj.js";import{o as R,s as Qe}from"./log-BMCygSzM.js";import{n as $e,r as z}from"./analytics-BotDBGh0.js";import{b as et,g as tt}from"./startupProfiler-xa3NmN7Z.js";import{r as nt}from"./permissions-Cn_6f8CB.js";import{Bt as rt,Ft as it,G as at,K as ot,Tr as st,_ as ct,b as lt,et as ut,it as dt,q as ft,rt as pt,tt as mt,wr as B,x as ht}from"./model-BQF64tZx.js";import{r as gt,t as _t}from"./poorMode-1NLYiS3Y.js";import{u as vt}from"./referral-BlrMpBAV.js";import{i as yt,r as bt}from"./bridgeEnabled-DhFrLTbG.js";import{a as V,c as H,d as U,i as xt,l as St,n as Ct,o as wt,r as Tt,s as Et,t as Dt,u as W}from"./status-DyXiBa0m.js";import{n as Ot,t as kt}from"./useExitOnCtrlCDWithKeybindings-CntByfTQ.js";import{i as At,n as G,r as jt}from"./modalContext-DFjKLCB6.js";import{n as Mt,t as Nt}from"./ThemePicker-CQ7dfFtv.js";import{i as Pt,n as Ft,r as It,t as Lt}from"./extraUsage-C2Ylufhj.js";import{n as Rt,t as zt}from"./ClaudeMdExternalIncludesDialog-CI0yF6sZ.js";import{t as Bt}from"./SearchBox-vfLXEPed.js";import{n as Vt,t as Ht}from"./useSearchInput-H-8hJeFD.js";import{n as Ut,t as Wt}from"./usage-iNQzY960.js";import{a as Gt,i as Kt,t as qt}from"./OverageCreditUpsell-CWCD_RpM.js";function Jt(){let e=x();return[{label:`Version`,value:`0.0.5`},{label:`Session name`,value:ke(e)??(0,K.jsx)(f,{dimColor:!0,children:`/rename to add a name`})},{label:`Session ID`,value:e},{label:`cwd`,value:Le()},...Ct(),...Dt()]}function Yt({mainLoopModel:e,mcp:t,theme:n,context:r}){return[{label:`Model`,value:W(e)},...Tt(t.clients,r.options.ideInstallationStatus,n),...wt(t.clients,n),...H(),...St()]}async function Xt(){return[...await xt(),...await V(),...await Et()]}function Zt({value:e}){return Array.isArray(e)?(0,K.jsx)(d,{flexWrap:`wrap`,columnGap:1,flexShrink:99,children:e.map((t,n)=>(0,K.jsxs)(f,{children:[t,n<e.length-1?`,`:``]},n))}):typeof e==`string`?(0,K.jsx)(f,{children:e}):e}function Qt({context:e,diagnosticsPromise:t}){let n=T(e=>e.mainLoopModel),r=T(e=>e.mcp),[i]=u(),a=en.useMemo(()=>[Jt(),Yt({mainLoopModel:n,mcp:r,theme:i,context:e})],[n,r,i,e]),o=jt()?1:void 0;return(0,K.jsxs)(d,{flexDirection:`column`,flexGrow:o,children:[(0,K.jsxs)(d,{flexDirection:`column`,gap:1,flexGrow:o,children:[a.map((e,t)=>e.length>0&&(0,K.jsx)(d,{flexDirection:`column`,children:e.map(({label:e,value:t},n)=>(0,K.jsxs)(d,{flexDirection:`row`,gap:1,flexShrink:0,children:[e!==void 0&&(0,K.jsxs)(f,{bold:!0,children:[e,`:`]}),(0,K.jsx)(Zt,{value:t})]},n))},t)),(0,K.jsx)(tn.Suspense,{fallback:null,children:(0,K.jsx)($t,{promise:t})})]}),(0,K.jsx)(f,{dimColor:!0,children:(0,K.jsx)(N,{action:`confirm:no`,context:`Settings`,fallback:`Esc`,description:`cancel`})})]})}function $t({promise:e}){let t=(0,tn.use)(e);return t.length===0?null:(0,K.jsxs)(d,{flexDirection:`column`,paddingBottom:1,children:[(0,K.jsx)(f,{bold:!0,children:`System Diagnostics`}),t.map((e,t)=>(0,K.jsxs)(d,{flexDirection:`row`,gap:1,paddingX:1,children:[(0,K.jsx)(f,{color:`error`,children:s.warning}),typeof e==`string`?(0,K.jsx)(f,{wrap:`wrap`,children:e}):e]},t))]})}var en,tn,K,nn=t((()=>{o(),en=n(h(),1),tn=n(h(),1),b(),G(),g(),Se(),Ie(),A(),U(),w(),K=y()}));function rn({currentVersion:e,onChoice:t}){function n(e){t(e)}function r(){t(`cancel`)}return(0,an.jsxs)(le,{title:`Switch to Stable Channel`,onCancel:r,color:`permission`,hideBorder:!0,hideInputGuide:!0,children:[(0,an.jsxs)(f,{children:[`The stable channel may have an older version than what you're currently running (`,e,`).`]}),(0,an.jsx)(f,{dimColor:!0,children:`How would you like to handle this?`}),(0,an.jsx)(Me,{options:[{label:`Allow possible downgrade to stable version`,value:`downgrade`},{label:`Stay on current version (${e}) until stable catches up`,value:`stay`}],onChange:n})]})}var an,on=t((()=>{h(),g(),O(),an=y()}));function sn(e){return Object.entries(e).map(([e,t])=>({label:t?.name??un,value:e,description:t?.description??dn}))}function cn({initialStyle:e,onComplete:t,onCancel:n,isStandaloneCommand:r}){let[i,a]=(0,ln.useState)([]),[o,s]=(0,ln.useState)(!0);(0,ln.useEffect)(()=>{D(Le()).then(e=>{let t=sn(e);a(t),s(!1)}).catch(()=>{let e=sn(k);a(e),s(!1)})},[]);let c=(0,ln.useCallback)(e=>{t(e)},[t]);return(0,q.jsx)(le,{title:`Preferred output style`,onCancel:n,hideInputGuide:!r,hideBorder:!r,children:(0,q.jsxs)(d,{flexDirection:`column`,gap:1,children:[(0,q.jsx)(d,{marginTop:1,children:(0,q.jsx)(f,{dimColor:!0,children:`This changes how Claude Code communicates with you`})}),o?(0,q.jsx)(f,{dimColor:!0,children:`Loading output styles…`}):(0,q.jsx)(Me,{options:i,onChange:c,visibleOptionCount:10,defaultValue:e})]})})}var ln,q,un,dn,fn=t((()=>{h(),ln=n(h(),1),M(),g(),Ie(),Ae(),q=y(),un=`Default`,dn=`Claude completes coding tasks efficiently and provides concise responses`}));function pn({initialLanguage:e,onComplete:t,onCancel:n}){let[r,i]=(0,mn.useState)(e),[a,o]=(0,mn.useState)((e??``).length);te(`confirm:no`,n,{context:`Settings`});function c(){let e=r?.trim();t(e||void 0)}return(0,J.jsxs)(d,{flexDirection:`column`,gap:1,children:[(0,J.jsx)(f,{children:`Enter your preferred response and voice language:`}),(0,J.jsxs)(d,{flexDirection:`row`,gap:1,children:[(0,J.jsx)(f,{children:s.pointer}),(0,J.jsx)(be,{value:r??``,onChange:i,onSubmit:c,focus:!0,showCursor:!0,placeholder:`e.g., Japanese, 日本語, Español${s.ellipsis}`,columns:60,cursorOffset:a,onChangeCursorOffset:o})]}),(0,J.jsx)(f,{dimColor:!0,children:`Leave empty for default (English)`})]})}var mn,J,hn=t((()=>{o(),mn=n(h(),1),g(),vt(),C(),J=y()}));function gn({onClose:t,context:n,setTabsHidden:a,onIsSearchModeChange:o,contentHeight:ie}){let{headerFocused:m,focusHeader:h}=re(),oe=jt(),[,ce]=u(),g=ee(),[v,y]=(0,X.useState)(L()),b=Y.useRef(L()),[x,S]=(0,X.useState)(Ge()),pe=Y.useRef(Ge()),[C,_e]=(0,X.useState)(x?.outputStyle||`default`),be=Y.useRef(C),[w,Se]=(0,X.useState)(x?.language),we=Y.useRef(w),[E,Ee]=(0,X.useState)(0),[D,O]=(0,X.useState)(0),[k,A]=(0,X.useState)(!1),ke=ne(),{rows:Ae}=se(),je=ie??Math.min(Math.floor(Ae*.8),30),j=Math.max(5,je-10),M=T(e=>e.mainLoopModel),Ne=T(e=>e.verbose),Ie=T(e=>e.thinkingEnabled),Le=T(e=>pt()?e.fastMode:!1);T(e=>e.promptSuggestionEnabled);let Re=Ue(x?.permissions?.defaultMode??`default`),ze=xe()||Pe()===`enabled`,Be=(Te(),e(De)).isBriefEntitled(),P=ve(),[Je,R]=(0,X.useState)({}),$e=Y.useRef(Ie),[et]=(0,X.useState)(()=>We(`localSettings`)),[tt]=(0,X.useState)(()=>We(`userSettings`)),rt=Y.useRef(g),it=ge(),[ct]=(0,X.useState)(()=>{let e=it.getState();return{mainLoopModel:e.mainLoopModel,mainLoopModelForSession:e.mainLoopModelForSession,verbose:e.verbose,thinkingEnabled:e.thinkingEnabled,fastMode:e.fastMode,promptSuggestionEnabled:e.promptSuggestionEnabled,isBriefOnly:e.isBriefOnly,replBridgeEnabled:e.replBridgeEnabled,replBridgeOutboundOnly:e.replBridgeOutboundOnly,settings:e.settings}}),[ut]=(0,X.useState)(()=>de()),B=Y.useRef(!1),[vt,bt]=(0,X.useState)(!1),[V,H]=(0,X.useState)(null),{query:U,setQuery:xt,cursorOffset:St}=Vt({isActive:k&&V===null&&!m,onExit:()=>A(!1),onExitUp:h,passthroughCtrlKeys:[`c`,`d`]}),Ct=k&&!m;Y.useEffect(()=>{o?.(Ct)},[Ct,o]);let wt=me(n.options.mcpClients),Tt=!i(process.env.CLAUDE_CODE_DISABLE_FILE_CHECKPOINTING),Et=Y.use(Fe(!0)),Dt=fe(Et),W=qe();function Ot(e){z(`tengu_config_model_changed`,{from_model:M,to_model:e}),P(t=>({...t,mainLoopModel:e,mainLoopModelForSession:null})),R(t=>{let n=ht(e)+(Ft(e,!1,lt())?` · Billed as extra usage`:``);if(`model`in t){let{model:e,...r}=t;return{...r,model:n}}return{...t,model:n}})}function kt(e){I(t=>({...t,verbose:e})),y({...L(),verbose:e}),P(t=>({...t,verbose:e})),R(t=>{if(`verbose`in t){let{verbose:e,...n}=t;return n}return{...t,verbose:e}})}let At=[{id:`autoCompactEnabled`,label:`Auto-compact`,value:v.autoCompactEnabled,type:`boolean`,onChange(e){I(t=>({...t,autoCompactEnabled:e})),y({...L(),autoCompactEnabled:e}),z(`tengu_auto_compact_setting_changed`,{enabled:e})}},{id:`spinnerTipsEnabled`,label:`Show tips`,value:x?.spinnerTipsEnabled??!0,type:`boolean`,onChange(e){F(`localSettings`,{spinnerTipsEnabled:e}),S(t=>({...t,spinnerTipsEnabled:e})),z(`tengu_tips_setting_changed`,{enabled:e})}},{id:`cacheWarningEnabled`,label:`Cache warnings`,value:x?.cacheWarningEnabled??!0,type:`boolean`,onChange(e){F(`localSettings`,{cacheWarningEnabled:e}),S(t=>({...t,cacheWarningEnabled:e})),z(`tengu_cache_warning_setting_changed`,{enabled:e})}},{id:`prefersReducedMotion`,label:`Reduce motion`,value:x?.prefersReducedMotion??!1,type:`boolean`,onChange(e){F(`localSettings`,{prefersReducedMotion:e}),S(t=>({...t,prefersReducedMotion:e})),P(t=>({...t,settings:{...t.settings,prefersReducedMotion:e}})),z(`tengu_reduce_motion_setting_changed`,{enabled:e})}},{id:`thinkingEnabled`,label:`Thinking mode`,value:Ie??!0,type:`boolean`,onChange(e){P(t=>({...t,thinkingEnabled:e})),F(`userSettings`,{alwaysThinkingEnabled:e?void 0:!1}),z(`tengu_thinking_toggled`,{enabled:e})}},...pt()&&mt()?[{id:`fastMode`,label:`Fast mode (${at} only)`,value:!!Le,type:`boolean`,onChange(e){ot(),F(`userSettings`,{fastMode:e?!0:void 0}),e?(P(e=>({...e,mainLoopModel:ft(),mainLoopModelForSession:null,fastMode:!0})),R(e=>({...e,model:ft(),"Fast mode":`ON`}))):(P(e=>({...e,fastMode:!1})),R(e=>({...e,"Fast mode":`OFF`})))}}]:[],{id:`poorMode`,label:`Poor mode (save tokens)`,value:(_t(),e(gt)).isPoorModeActive(),type:`boolean`,onChange(t){(_t(),e(gt)).setPoorMode(t),P(e=>({...e,promptSuggestionEnabled:!t}))}},...process.env.USER_TYPE===`ant`?[{id:`speculationEnabled`,label:`Speculative execution`,value:v.speculationEnabled??!0,type:`boolean`,onChange(e){I(t=>t.speculationEnabled===e?t:{...t,speculationEnabled:e}),y({...L(),speculationEnabled:e}),z(`tengu_speculation_setting_changed`,{enabled:e})}}]:[],...Tt?[{id:`fileCheckpointingEnabled`,label:`Rewind code (checkpoints)`,value:v.fileCheckpointingEnabled,type:`boolean`,onChange(e){I(t=>({...t,fileCheckpointingEnabled:e})),y({...L(),fileCheckpointingEnabled:e}),z(`tengu_file_history_snapshots_setting_changed`,{enabled:e})}}]:[],{id:`verbose`,label:`Verbose output`,value:Ne,type:`boolean`,onChange:kt},{id:`terminalProgressBarEnabled`,label:`Terminal progress bar`,value:v.terminalProgressBarEnabled,type:`boolean`,onChange(e){I(t=>({...t,terminalProgressBarEnabled:e})),y({...L(),terminalProgressBarEnabled:e}),z(`tengu_terminal_progress_bar_setting_changed`,{enabled:e})}},{id:`showTurnDuration`,label:`Show turn duration`,value:v.showTurnDuration,type:`boolean`,onChange(e){I(t=>({...t,showTurnDuration:e})),y({...L(),showTurnDuration:e}),z(`tengu_show_turn_duration_setting_changed`,{enabled:e})}},{id:`defaultPermissionMode`,label:`Default permission mode`,value:Re,options:(()=>{let e=[`default`,`plan`];return[...e,...nt.filter(t=>!e.includes(t))]})(),type:`enum`,onChange(e){let t=Ue(e),n=t===`auto`?t:He(t)?Ve(t):t,r=F(`userSettings`,{permissions:{...x?.permissions,defaultMode:n}});if(r.error){Qe(r.error);return}S(e=>({...e,permissions:{...e?.permissions,defaultMode:n}})),R(t=>({...t,defaultPermissionMode:e})),z(`tengu_config_changed`,{setting:`defaultPermissionMode`,value:e})}},...ze?[{id:`useAutoModeDuringPlan`,label:`Use auto mode during plan`,value:x?.useAutoModeDuringPlan??!0,type:`boolean`,onChange(e){F(`userSettings`,{useAutoModeDuringPlan:e}),S(t=>({...t,useAutoModeDuringPlan:e})),P(e=>{let t=he(e.toolPermissionContext);return t===e.toolPermissionContext?e:{...e,toolPermissionContext:t}}),R(t=>({...t,"Use auto mode during plan":e}))}}]:[],{id:`respectGitignore`,label:`Respect .gitignore in file picker`,value:v.respectGitignore,type:`boolean`,onChange(e){I(t=>({...t,respectGitignore:e})),y({...L(),respectGitignore:e}),z(`tengu_respect_gitignore_setting_changed`,{enabled:e})}},...Ce()?[{id:`copyOnSelect`,label:`Copy on select`,value:v.copyOnSelect??!0,type:`boolean`,onChange(e){I(t=>({...t,copyOnSelect:e})),y({...L(),copyOnSelect:e}),z(`tengu_config_changed`,{setting:`copyOnSelect`,value:String(e)})}}]:[],W?{id:`autoUpdatesChannel`,label:`Auto-update channel`,value:`disabled`,type:`managedEnum`,onChange(){}}:{id:`autoUpdatesChannel`,label:`Auto-update channel`,value:x?.autoUpdatesChannel??`latest`,type:`managedEnum`,onChange(){}},{id:`theme`,label:`Theme`,value:g,type:`managedEnum`,onChange:ce},{id:`notifChannel`,label:`Local notifications`,value:v.preferredNotifChannel,options:[`auto`,`iterm2`,`terminal_bell`,`iterm2_with_bell`,`kitty`,`ghostty`,`notifications_disabled`],type:`enum`,onChange(e){I(t=>({...t,preferredNotifChannel:e})),y({...L(),preferredNotifChannel:e})}},{id:`taskCompleteNotifEnabled`,label:`Push when idle`,value:v.taskCompleteNotifEnabled??!1,type:`boolean`,onChange(e){I(t=>({...t,taskCompleteNotifEnabled:e})),y({...L(),taskCompleteNotifEnabled:e})}},{id:`inputNeededNotifEnabled`,label:`Push when input needed`,value:v.inputNeededNotifEnabled??!1,type:`boolean`,onChange(e){I(t=>({...t,inputNeededNotifEnabled:e})),y({...L(),inputNeededNotifEnabled:e})}},{id:`agentPushNotifEnabled`,label:`Push when Claude decides`,value:v.agentPushNotifEnabled??!1,type:`boolean`,onChange(e){I(t=>({...t,agentPushNotifEnabled:e})),y({...L(),agentPushNotifEnabled:e})}},{id:`outputStyle`,label:`Output style`,value:C,type:`managedEnum`,onChange:()=>{}},...Be?[{id:`defaultView`,label:`What you see by default`,value:x?.defaultView===void 0?`default`:String(x.defaultView),options:[`transcript`,`chat`,`default`],type:`enum`,onChange(e){let t=e==="default"?void 0:e;F(`localSettings`,{defaultView:t}),S(e=>({...e,defaultView:t}));let n=t===`chat`;P(e=>e.isBriefOnly===n?e:{...e,isBriefOnly:n}),ue(n),R(t=>({...t,"Default view":e})),z(`tengu_default_view_setting_changed`,{value:t??`unset`})}}]:[],{id:`language`,label:`Language`,value:w??`Default (English)`,type:`managedEnum`,onChange:()=>{}},{id:`editorMode`,label:`Editor mode`,value:v.editorMode===`emacs`?`normal`:v.editorMode||`normal`,options:[`normal`,`vim`],type:`enum`,onChange(e){I(t=>({...t,editorMode:e})),y({...L(),editorMode:e}),z(`tengu_editor_mode_changed`,{mode:e,source:`config_panel`})}},{id:`prStatusFooterEnabled`,label:`Show PR status footer`,value:v.prStatusFooterEnabled??!0,type:`boolean`,onChange(e){I(t=>t.prStatusFooterEnabled===e?t:{...t,prStatusFooterEnabled:e}),y({...L(),prStatusFooterEnabled:e}),z(`tengu_pr_status_footer_setting_changed`,{enabled:e})}},{id:`model`,label:`Model`,value:M===null?`Default (recommended)`:M,type:`managedEnum`,onChange:Ot},...wt?[{id:`diffTool`,label:`Diff tool`,value:v.diffTool??`auto`,options:[`terminal`,`auto`],type:`enum`,onChange(e){I(t=>({...t,diffTool:e})),y({...L(),diffTool:e}),z(`tengu_diff_tool_changed`,{tool:e,source:`config_panel`})}}]:[],...Oe()?[]:[{id:`autoConnectIde`,label:`Auto-connect to IDE (external terminal)`,value:v.autoConnectIde??!1,type:`boolean`,onChange(e){I(t=>({...t,autoConnectIde:e})),y({...L(),autoConnectIde:e}),z(`tengu_auto_connect_ide_changed`,{enabled:e,source:`config_panel`})}}],...Oe()?[{id:`autoInstallIdeExtension`,label:`Auto-install IDE extension`,value:v.autoInstallIdeExtension??!0,type:`boolean`,onChange(e){I(t=>({...t,autoInstallIdeExtension:e})),y({...L(),autoInstallIdeExtension:e}),z(`tengu_auto_install_ide_extension_changed`,{enabled:e,source:`config_panel`})}}]:[],...yt()?[{id:`remoteControlAtStartup`,label:`Enable Remote Control for all sessions`,value:v.remoteControlAtStartup===void 0?`default`:String(v.remoteControlAtStartup),options:[`true`,`false`,`default`],type:`enum`,onChange(e){if(e==="default")I(e=>{if(e.remoteControlAtStartup===void 0)return e;let t={...e};return delete t.remoteControlAtStartup,t}),y({...L(),remoteControlAtStartup:void 0});else{let t=e===`true`;I(e=>e.remoteControlAtStartup===t?e:{...e,remoteControlAtStartup:t}),y({...L(),remoteControlAtStartup:t})}let t=Xe();P(e=>e.replBridgeEnabled===t&&!e.replBridgeOutboundOnly?e:{...e,replBridgeEnabled:t,replBridgeOutboundOnly:!1})}}]:[],...Dt?[{id:`showExternalIncludesDialog`,label:`External CLAUDE.md includes`,value:Ze().hasClaudeMdExternalIncludesApproved?`true`:`false`,type:`managedEnum`,onChange(){}}]:[],...process.env.ANTHROPIC_API_KEY&&!r()?[{id:`apiKey`,label:(0,Z.jsxs)(f,{children:[`Use custom API key: `,(0,Z.jsx)(f,{bold:!0,children:st(process.env.ANTHROPIC_API_KEY)})]}),searchText:`Use custom API key`,value:!!(process.env.ANTHROPIC_API_KEY&&v.customApiKeyResponses?.approved?.includes(st(process.env.ANTHROPIC_API_KEY))),type:`boolean`,onChange(e){I(t=>{let n={...t};if(n.customApiKeyResponses||(n.customApiKeyResponses={approved:[],rejected:[]}),n.customApiKeyResponses.approved||(n.customApiKeyResponses={...n.customApiKeyResponses,approved:[]}),n.customApiKeyResponses.rejected||(n.customApiKeyResponses={...n.customApiKeyResponses,rejected:[]}),process.env.ANTHROPIC_API_KEY){let t=st(process.env.ANTHROPIC_API_KEY);e?n.customApiKeyResponses={...n.customApiKeyResponses,approved:[...(n.customApiKeyResponses.approved??[]).filter(e=>e!==t),t],rejected:(n.customApiKeyResponses.rejected??[]).filter(e=>e!==t)}:n.customApiKeyResponses={...n.customApiKeyResponses,approved:(n.customApiKeyResponses.approved??[]).filter(e=>e!==t),rejected:[...(n.customApiKeyResponses.rejected??[]).filter(e=>e!==t),t]}}return n}),y(L())}}]:[]],G=Y.useMemo(()=>{if(!U)return At;let e=U.toLowerCase();return At.filter(t=>t.id.toLowerCase().includes(e)?!0:(`searchText`in t?t.searchText:t.label).toLowerCase().includes(e))},[At,U]);Y.useEffect(()=>{if(E>=G.length){let e=Math.max(0,G.length-1);Ee(e),O(Math.max(0,e-j+1));return}O(e=>E<e?E:E>=e+j?E-j+1:e)},[G.length,E,j]);let Mt=(0,X.useCallback)(e=>{O(t=>e<t?e:e>=t+j?e-j+1:t)},[j]),Pt=(0,X.useCallback)(()=>{if(V!==null)return;let e=Object.entries(Je).map(([e,t])=>(z(`tengu_config_changed`,{key:e,value:t}),`Set ${e} to ${_.bold(t)}`)),n=r()?void 0:process.env.ANTHROPIC_API_KEY,i=!!(n&&b.current.customApiKeyResponses?.approved?.includes(st(n))),a=!!(n&&v.customApiKeyResponses?.approved?.includes(st(n)));if(i!==a&&(e.push(`${a?`Enabled`:`Disabled`} custom API key`),z(`tengu_config_changed`,{key:`env.ANTHROPIC_API_KEY`,value:a})),v.theme!==b.current.theme&&e.push(`Set theme to ${_.bold(v.theme)}`),v.preferredNotifChannel!==b.current.preferredNotifChannel&&e.push(`Set notifications to ${_.bold(v.preferredNotifChannel)}`),C!==be.current&&e.push(`Set output style to ${_.bold(C)}`),w!==we.current&&e.push(`Set response language to ${_.bold(w??`Default (English)`)}`),v.editorMode!==b.current.editorMode&&e.push(`Set editor mode to ${_.bold(v.editorMode||`emacs`)}`),v.diffTool!==b.current.diffTool&&e.push(`Set diff tool to ${_.bold(v.diffTool)}`),v.autoConnectIde!==b.current.autoConnectIde&&e.push(`${v.autoConnectIde?`Enabled`:`Disabled`} auto-connect to IDE`),v.autoInstallIdeExtension!==b.current.autoInstallIdeExtension&&e.push(`${v.autoInstallIdeExtension?`Enabled`:`Disabled`} auto-install IDE extension`),v.autoCompactEnabled!==b.current.autoCompactEnabled&&e.push(`${v.autoCompactEnabled?`Enabled`:`Disabled`} auto-compact`),v.respectGitignore!==b.current.respectGitignore&&e.push(`${v.respectGitignore?`Enabled`:`Disabled`} respect .gitignore in file picker`),v.copyOnSelect!==b.current.copyOnSelect&&e.push(`${v.copyOnSelect?`Enabled`:`Disabled`} copy on select`),v.terminalProgressBarEnabled!==b.current.terminalProgressBarEnabled&&e.push(`${v.terminalProgressBarEnabled?`Enabled`:`Disabled`} terminal progress bar`),v.showStatusInTerminalTab!==b.current.showStatusInTerminalTab&&e.push(`${v.showStatusInTerminalTab?`Enabled`:`Disabled`} terminal tab status`),v.showTurnDuration!==b.current.showTurnDuration&&e.push(`${v.showTurnDuration?`Enabled`:`Disabled`} turn duration`),v.remoteControlAtStartup!==b.current.remoteControlAtStartup){let t=v.remoteControlAtStartup===void 0?`Reset Remote Control to default`:`${v.remoteControlAtStartup?`Enabled`:`Disabled`} Remote Control for all sessions`;e.push(t)}x?.autoUpdatesChannel!==pe.current?.autoUpdatesChannel&&e.push(`Set auto-update channel to ${_.bold(x?.autoUpdatesChannel??`latest`)}`),e.length>0?t(e.join(`
|
|
2
|
-
`)):t(`Config dialog dismissed`,{display:`system`})},[V,Je,v,M,C,w,x?.autoUpdatesChannel,pt()?x?.fastMode:void 0,t]),Lt=(0,X.useCallback)(()=>{g!==rt.current&&ce(rt.current),I(()=>b.current);let e=et;F(`localSettings`,{spinnerTipsEnabled:e?.spinnerTipsEnabled,prefersReducedMotion:e?.prefersReducedMotion,defaultView:e?.defaultView,outputStyle:e?.outputStyle});let t=tt;F(`userSettings`,{alwaysThinkingEnabled:t?.alwaysThinkingEnabled,fastMode:t?.fastMode,promptSuggestionEnabled:t?.promptSuggestionEnabled,autoUpdatesChannel:t?.autoUpdatesChannel,minimumVersion:t?.minimumVersion,language:t?.language,useAutoModeDuringPlan:t?.useAutoModeDuringPlan,syntaxHighlightingDisabled:t?.syntaxHighlightingDisabled,permissions:t?.permissions===void 0?void 0:{...t.permissions,defaultMode:t.permissions.defaultMode}});let n=ct;P(e=>({...e,mainLoopModel:n.mainLoopModel,mainLoopModelForSession:n.mainLoopModelForSession,verbose:n.verbose,thinkingEnabled:n.thinkingEnabled,fastMode:n.fastMode,promptSuggestionEnabled:n.promptSuggestionEnabled,isBriefOnly:n.isBriefOnly,replBridgeEnabled:n.replBridgeEnabled,replBridgeOutboundOnly:n.replBridgeOutboundOnly,settings:n.settings,toolPermissionContext:he(e.toolPermissionContext)})),de()!==ut&&ue(ut)},[g,ce,et,tt,ct,ut,P]);te(`confirm:no`,(0,X.useCallback)(()=>{V===null&&(B.current&&Lt(),t(`Config dialog dismissed`,{display:`system`}))},[V,Lt,t]),{context:`Settings`,isActive:V===null&&!k&&!m}),te(`settings:close`,Pt,{context:`Settings`,isActive:V===null&&!k&&!m});let Rt=(0,X.useCallback)(()=>{let e=G[E];if(!(!e||!e.onChange)){if(e.type===`boolean`){B.current=!0,e.onChange(!e.value),e.id===`thinkingEnabled`&&(!e.value===$e.current?bt(!1):n.messages.some(e=>e.type===`assistant`)&&bt(!0));return}if(e.id===`theme`||e.id===`model`||e.id===`showExternalIncludesDialog`||e.id===`outputStyle`||e.id===`language`)switch(e.id){case`theme`:H(`Theme`),a(!0);return;case`model`:H(`Model`),a(!0);return;case`showExternalIncludesDialog`:H(`ExternalIncludes`),a(!0);return;case`outputStyle`:H(`OutputStyle`),a(!0);return;case`language`:H(`Language`),a(!0);return}if(e.id===`autoUpdatesChannel`){if(W){H(`EnableAutoUpdates`),a(!0);return}(x?.autoUpdatesChannel??`latest`)===`latest`?(H(`ChannelDowngrade`),a(!0)):(B.current=!0,F(`userSettings`,{autoUpdatesChannel:`latest`,minimumVersion:void 0}),S(e=>({...e,autoUpdatesChannel:`latest`,minimumVersion:void 0})),z(`tengu_autoupdate_channel_changed`,{channel:`latest`}));return}if(e.type===`enum`){B.current=!0;let t=(e.options.indexOf(e.value)+1)%e.options.length;e.onChange(e.options[t]);return}}},[W,G,E,x?.autoUpdatesChannel,a]),Bt=e=>{bt(!1);let t=Math.max(0,Math.min(G.length-1,E+e));Ee(t),Mt(t)};return l({"select:previous":()=>{E===0?(bt(!1),A(!0),O(0)):Bt(-1)},"select:next":()=>Bt(1),"scroll:lineUp":()=>Bt(-1),"scroll:lineDown":()=>Bt(1),"select:accept":Rt,"select:previousValue":()=>Rt(),"select:nextValue":()=>Rt(),"settings:search":()=>{A(!0),xt(``)}},{context:`Settings`,isActive:V===null&&!k&&!m}),(0,Z.jsx)(d,{flexDirection:`column`,width:`100%`,tabIndex:0,autoFocus:!0,onKeyDown:(0,X.useCallback)(e=>{if(V===null&&!m){if(k){if(e.key===`escape`){e.preventDefault(),U.length>0?xt(``):A(!1);return}(e.key===`return`||e.key===`down`||e.key===`wheeldown`)&&(e.preventDefault(),A(!1),Ee(0),O(0));return}if(e.key===`left`||e.key===`right`||e.key===`tab`){e.preventDefault(),Rt();return}e.ctrl||e.meta||e.key===`j`||e.key===`k`||e.key===`/`||e.key.length===1&&e.key!==` `&&(e.preventDefault(),A(!0),xt(e.key))}},[V,m,k,U,xt,Rt]),children:V===`Theme`?(0,Z.jsxs)(Z.Fragment,{children:[(0,Z.jsx)(Nt,{onThemeSelect:e=>{B.current=!0,ce(e),H(null),a(!1)},onCancel:()=>{H(null),a(!1)},hideEscToCancel:!0,skipExitHandling:!0}),(0,Z.jsx)(d,{children:(0,Z.jsx)(f,{dimColor:!0,italic:!0,children:(0,Z.jsxs)(p,{children:[(0,Z.jsx)(c,{shortcut:`Enter`,action:`select`}),(0,Z.jsx)(N,{action:`confirm:no`,context:`Confirmation`,fallback:`Esc`,description:`cancel`})]})})})]}):V===`Model`?(0,Z.jsxs)(Z.Fragment,{children:[(0,Z.jsx)(It,{initial:M,onSelect:e=>{B.current=!0,Ot(e),H(null),a(!1)},onCancel:()=>{H(null),a(!1)},showFastModeNotice:pt()?Le&&dt(M)&&mt():!1}),(0,Z.jsx)(f,{dimColor:!0,children:(0,Z.jsxs)(p,{children:[(0,Z.jsx)(c,{shortcut:`Enter`,action:`confirm`}),(0,Z.jsx)(N,{action:`confirm:no`,context:`Confirmation`,fallback:`Esc`,description:`cancel`})]})})]}):V===`ExternalIncludes`?(0,Z.jsxs)(Z.Fragment,{children:[(0,Z.jsx)(zt,{onDone:()=>{H(null),a(!1)},externalIncludes:ye(Et)}),(0,Z.jsx)(f,{dimColor:!0,children:(0,Z.jsxs)(p,{children:[(0,Z.jsx)(c,{shortcut:`Enter`,action:`confirm`}),(0,Z.jsx)(N,{action:`confirm:no`,context:`Confirmation`,fallback:`Esc`,description:`disable external includes`})]})})]}):V===`OutputStyle`?(0,Z.jsxs)(Z.Fragment,{children:[(0,Z.jsx)(cn,{initialStyle:C,onComplete:e=>{B.current=!0,_e(e??`default`),H(null),a(!1),F(`localSettings`,{outputStyle:e}),z(`tengu_output_style_changed`,{style:e??`default`,source:`config_panel`,settings_source:`localSettings`})},onCancel:()=>{H(null),a(!1)}}),(0,Z.jsx)(f,{dimColor:!0,children:(0,Z.jsxs)(p,{children:[(0,Z.jsx)(c,{shortcut:`Enter`,action:`confirm`}),(0,Z.jsx)(N,{action:`confirm:no`,context:`Confirmation`,fallback:`Esc`,description:`cancel`})]})})]}):V===`Language`?(0,Z.jsxs)(Z.Fragment,{children:[(0,Z.jsx)(pn,{initialLanguage:w,onComplete:e=>{B.current=!0,Se(e),H(null),a(!1),F(`userSettings`,{language:e}),z(`tengu_language_changed`,{language:e??`default`,source:`config_panel`})},onCancel:()=>{H(null),a(!1)}}),(0,Z.jsx)(f,{dimColor:!0,children:(0,Z.jsxs)(p,{children:[(0,Z.jsx)(c,{shortcut:`Enter`,action:`confirm`}),(0,Z.jsx)(N,{action:`confirm:no`,context:`Settings`,fallback:`Esc`,description:`cancel`})]})})]}):V===`EnableAutoUpdates`?(0,Z.jsx)(le,{title:`Enable Auto-Updates`,onCancel:()=>{H(null),a(!1)},hideBorder:!0,hideInputGuide:!0,children:W?.type===`config`?(0,Z.jsx)(Me,{options:[{label:`Enable with latest channel`,value:`latest`},{label:`Enable with stable channel`,value:`stable`}],onChange:e=>{B.current=!0,H(null),a(!1),I(e=>({...e,autoUpdates:!0})),y({...L(),autoUpdates:!0}),F(`userSettings`,{autoUpdatesChannel:e,minimumVersion:void 0}),S(t=>({...t,autoUpdatesChannel:e,minimumVersion:void 0})),z(`tengu_autoupdate_enabled`,{channel:e})}}):(0,Z.jsxs)(Z.Fragment,{children:[(0,Z.jsx)(f,{children:W?.type===`env`?`Auto-updates are controlled by an environment variable and cannot be changed here.`:`Auto-updates are disabled in development builds.`}),W?.type===`env`&&(0,Z.jsxs)(f,{dimColor:!0,children:[`Unset `,W.envVar,` to re-enable auto-updates.`]})]})}):V===`ChannelDowngrade`?(0,Z.jsx)(rn,{currentVersion:`0.0.5`,onChoice:e=>{if(H(null),a(!1),e===`cancel`)return;B.current=!0;let t={autoUpdatesChannel:`stable`};e===`stay`&&(t.minimumVersion=`0.0.5`),F(`userSettings`,t),S(e=>({...e,...t})),z(`tengu_autoupdate_channel_changed`,{channel:`stable`,minimum_version_set:e===`stay`})}}):(0,Z.jsxs)(d,{flexDirection:`column`,gap:1,marginY:oe?void 0:1,children:[(0,Z.jsx)(ae,{query:U,isFocused:k&&!m,isTerminalFocused:ke,cursorOffset:St,placeholder:`Search settings…`}),(0,Z.jsx)(d,{flexDirection:`column`,children:G.length===0?(0,Z.jsxs)(f,{dimColor:!0,italic:!0,children:[`No settings match "`,U,`"`]}):(0,Z.jsxs)(Z.Fragment,{children:[D>0&&(0,Z.jsxs)(f,{dimColor:!0,children:[s.arrowUp,` `,D,` more above`]}),G.slice(D,D+j).map((e,t)=>{let n=D+t===E&&!m&&!k;return(0,Z.jsx)(Y.Fragment,{children:(0,Z.jsxs)(d,{width:`100%`,children:[(0,Z.jsx)(d,{width:44,children:(0,Z.jsxs)(f,{color:n?`suggestion`:void 0,children:[n?s.pointer:` `,` `,e.label]})}),(0,Z.jsx)(d,{flexGrow:1,children:e.type===`boolean`?(0,Z.jsxs)(Z.Fragment,{children:[(0,Z.jsx)(f,{color:n?`suggestion`:void 0,children:e.value.toString()}),vt&&e.id===`thinkingEnabled`&&(0,Z.jsxs)(f,{color:`warning`,children:[` `,`Changing thinking mode mid-conversation will increase latency and may reduce quality.`]})]}):e.id===`theme`?(0,Z.jsx)(f,{color:n?`suggestion`:void 0,children:vn[e.value.toString()]??e.value.toString()}):e.id===`notifChannel`?(0,Z.jsx)(f,{color:n?`suggestion`:void 0,children:(0,Z.jsx)(_n,{value:e.value.toString()})}):e.id===`defaultPermissionMode`?(0,Z.jsx)(f,{color:n?`suggestion`:void 0,children:Ke(e.value)}):e.id===`autoUpdatesChannel`&&W?(0,Z.jsxs)(d,{flexDirection:`column`,children:[(0,Z.jsx)(f,{color:n?`suggestion`:void 0,children:`disabled`}),(0,Z.jsxs)(f,{dimColor:!0,children:[`(`,Ye(W),`)`]})]}):(0,Z.jsx)(f,{color:n?`suggestion`:void 0,children:e.value.toString()})})]})},e.id)}),D+j<G.length&&(0,Z.jsxs)(f,{dimColor:!0,children:[s.arrowDown,` `,G.length-D-j,` more below`]})]})}),m?(0,Z.jsx)(f,{dimColor:!0,children:(0,Z.jsxs)(p,{children:[(0,Z.jsx)(c,{shortcut:`←/→ tab`,action:`switch`}),(0,Z.jsx)(c,{shortcut:`↓`,action:`return`}),(0,Z.jsx)(N,{action:`confirm:no`,context:`Settings`,fallback:`Esc`,description:`close`})]})}):k?(0,Z.jsx)(f,{dimColor:!0,children:(0,Z.jsxs)(p,{children:[(0,Z.jsx)(f,{children:`Type to filter`}),(0,Z.jsx)(c,{shortcut:`Enter/↓`,action:`select`}),(0,Z.jsx)(c,{shortcut:`↑`,action:`tabs`}),(0,Z.jsx)(N,{action:`confirm:no`,context:`Settings`,fallback:`Esc`,description:`clear`})]})}):(0,Z.jsx)(f,{dimColor:!0,children:(0,Z.jsxs)(p,{children:[(0,Z.jsx)(N,{action:`select:accept`,context:`Settings`,fallback:`Space`,description:`change`}),(0,Z.jsx)(N,{action:`settings:close`,context:`Settings`,fallback:`Enter`,description:`save`}),(0,Z.jsx)(N,{action:`settings:search`,context:`Settings`,fallback:`/`,description:`search`}),(0,Z.jsx)(N,{action:`confirm:no`,context:`Settings`,fallback:`Esc`,description:`cancel`})]})})]})})}function _n({value:e}){switch(e){case`auto`:return`Auto`;case`iterm2`:return(0,Z.jsxs)(f,{children:[`iTerm2 `,(0,Z.jsx)(f,{dimColor:!0,children:`(OSC 9)`})]});case`terminal_bell`:return(0,Z.jsxs)(f,{children:[`Terminal Bell `,(0,Z.jsx)(f,{dimColor:!0,children:`(\\a)`})]});case`kitty`:return(0,Z.jsxs)(f,{children:[`Kitty `,(0,Z.jsx)(f,{dimColor:!0,children:`(OSC 99)`})]});case`ghostty`:return(0,Z.jsxs)(f,{children:[`Ghostty `,(0,Z.jsx)(f,{dimColor:!0,children:`(OSC 777)`})]});case`iterm2_with_bell`:return`iTerm2 w/ Bell`;case`notifications_disabled`:return`Disabled`;default:return e}}var Y,X,Z,vn,yn=t((()=>{g(),Y=n(h(),1),X=n(h(),1),vt(),o(),Je(),B(),m(),Be(),S(),R(),$e(),bt(),Mt(),Se(),Pt(),ct(),Lt(),Rt(),on(),O(),fn(),hn(),we(),w(),G(),Bt(),pe(),P(),b(),M(),a(),Ht(),E(),ut(),_e(),Z=y(),vn={auto:`Auto (match terminal)`,dark:`Dark mode`,light:`Light mode`,"dark-daltonized":`Dark mode (colorblind-friendly)`,"light-daltonized":`Light mode (colorblind-friendly)`,"dark-ansi":`Dark mode (ANSI colors only)`,"light-ansi":`Light mode (ANSI colors only)`}}));function bn({title:e,limit:t,maxWidth:n,showTimeInReset:r=!0,extraSubtext:i}){let{utilization:a,resets_at:o}=t;if(a===null)return null;let s=`${Math.floor(a)}% used`,c;return o&&(c=`Resets ${tt(o,!0,r)}`),i&&(c=c?`${i} · ${c}`:i),n>=62?(0,Q.jsxs)(d,{flexDirection:`column`,children:[(0,Q.jsx)(f,{bold:!0,children:e}),(0,Q.jsxs)(d,{flexDirection:`row`,gap:1,children:[(0,Q.jsx)(ie,{ratio:a/100,width:50,fillColor:`rate_limit_fill`,emptyColor:`rate_limit_empty`}),(0,Q.jsx)(f,{children:s})]}),c&&(0,Q.jsx)(f,{dimColor:!0,children:c})]}):(0,Q.jsxs)(d,{flexDirection:`column`,children:[(0,Q.jsxs)(f,{children:[(0,Q.jsx)(f,{bold:!0,children:e}),c&&(0,Q.jsxs)(Q.Fragment,{children:[(0,Q.jsx)(f,{children:` `}),(0,Q.jsxs)(f,{dimColor:!0,children:[`· `,c]})]})]}),(0,Q.jsx)(ie,{ratio:a/100,width:n,fillColor:`rate_limit_fill`,emptyColor:`rate_limit_empty`}),(0,Q.jsx)(f,{children:s})]})}function xn(){let[e,t]=(0,wn.useState)(null),[n,r]=(0,wn.useState)(null),[i,a]=(0,wn.useState)(!0),{columns:o}=se(),s=o-2,c=Math.min(s,80),l=Cn.useCallback(async()=>{a(!0),r(null);try{let e=await Wt();t(e)}catch(e){Qe(e);let t=e,n=t.response?.data?ze(t.response.data):void 0;r(n?`Failed to load usage data: ${n}`:`Failed to load usage data`)}finally{a(!1)}},[]);if((0,wn.useEffect)(()=>{l()},[l]),te(`settings:retry`,()=>{l()},{context:`Settings`,isActive:!!n&&!i}),n)return(0,Q.jsxs)(d,{flexDirection:`column`,gap:1,children:[(0,Q.jsxs)(f,{color:`error`,children:[`Error: `,n]}),(0,Q.jsx)(f,{dimColor:!0,children:(0,Q.jsxs)(p,{children:[(0,Q.jsx)(N,{action:`settings:retry`,context:`Settings`,fallback:`r`,description:`retry`}),(0,Q.jsx)(N,{action:`confirm:no`,context:`Settings`,fallback:`Esc`,description:`cancel`})]})})]});if(!e)return(0,Q.jsxs)(d,{flexDirection:`column`,gap:1,children:[(0,Q.jsx)(f,{dimColor:!0,children:`Loading usage data…`}),(0,Q.jsx)(f,{dimColor:!0,children:(0,Q.jsx)(N,{action:`confirm:no`,context:`Settings`,fallback:`Esc`,description:`cancel`})})]});let u=it(),ee=u===`max`||u===`team`||u===null,ne=[{title:`Current session`,limit:e.five_hour},{title:`Current week (all models)`,limit:e.seven_day},...ee?[{title:`Current week (Sonnet only)`,limit:e.seven_day_sonnet}]:[]];return(0,Q.jsxs)(d,{flexDirection:`column`,gap:1,width:`100%`,children:[ne.some(({limit:e})=>e)||(0,Q.jsx)(f,{dimColor:!0,children:`/usage is only available for subscription plans.`}),ne.map(({title:e,limit:t})=>t&&(0,Q.jsx)(bn,{title:e,limit:t,maxWidth:c},e)),e.extra_usage&&(0,Q.jsx)(Sn,{extraUsage:e.extra_usage,maxWidth:c}),Gt()&&(0,Q.jsx)(qt,{maxWidth:c}),(0,Q.jsx)(f,{dimColor:!0,children:(0,Q.jsx)(N,{action:`confirm:no`,context:`Settings`,fallback:`Esc`,description:`cancel`})})]})}function Sn({extraUsage:e,maxWidth:t}){let n=it();if(!(n===`pro`||n===`max`))return!1;if(!e.is_enabled)return Ee.isEnabled()?(0,Q.jsxs)(d,{flexDirection:`column`,children:[(0,Q.jsx)(f,{bold:!0,children:Tn}),(0,Q.jsx)(f,{dimColor:!0,children:`Extra usage not enabled · /extra-usage to enable`})]}):null;if(e.monthly_limit===null)return(0,Q.jsxs)(d,{flexDirection:`column`,children:[(0,Q.jsx)(f,{bold:!0,children:Tn}),(0,Q.jsx)(f,{dimColor:!0,children:`Unlimited`})]});if(typeof e.used_credits!=`number`||typeof e.utilization!=`number`)return null;let r=Ne(e.used_credits/100,2),i=Ne(e.monthly_limit/100,2),a=new Date,o=new Date(a.getFullYear(),a.getMonth()+1,1);return(0,Q.jsx)(bn,{title:Tn,limit:{utilization:e.utilization,resets_at:o.toISOString()},showTimeInReset:!1,extraSubtext:`${r} / ${i} spent`,maxWidth:t})}var Cn,wn,Q,Tn,En=t((()=>{Cn=n(h(),1),wn=n(h(),1),je(),j(),rt(),E(),g(),vt(),Ut(),et(),R(),Re(),w(),Kt(),Q=y(),Tn=`Extra usage`}));function Dn({onClose:e,context:t,defaultTab:n}){let[r,i]=(0,On.useState)(n),[a,o]=(0,On.useState)(!1),[s,c]=(0,On.useState)(!1),l=jt(),{rows:u}=At(se()),d=l?u+1:Math.max(15,Math.min(Math.floor(u*.8),30)),[f]=(0,On.useState)(()=>Xt().catch(()=>[]));return Ot(),te(`confirm:no`,()=>{a||e(`Status dialog dismissed`,{display:`system`})},{context:`Settings`,isActive:!a&&!(r===`Config`&&s)}),(0,$.jsx)(v,{color:`permission`,children:(0,$.jsx)(ce,{color:`permission`,selectedTab:r,onTabChange:i,hidden:a,initialHeaderFocused:n!==`Config`,contentHeight:a||l?void 0:d,children:[(0,$.jsx)(oe,{title:`Status`,children:(0,$.jsx)(Qt,{context:t,diagnosticsPromise:f})},`status`),(0,$.jsx)(oe,{title:`Config`,children:(0,$.jsx)(On.Suspense,{fallback:null,children:(0,$.jsx)(gn,{context:t,onClose:e,setTabsHidden:o,onIsSearchModeChange:c,contentHeight:d})})},`config`),(0,$.jsx)(oe,{title:`Usage`,children:(0,$.jsx)(xn,{})},`usage`)]})})}var On,$,kn=t((()=>{h(),On=n(h(),1),vt(),kt(),E(),G(),g(),nn(),yn(),En(),$=y()}));export{kn as n,Dn as t};
|
|
1
|
+
import{a as e,n as t,o as n}from"./rolldown-runtime-DaDcL9Zw.js";import{d as r,l as i,o as a}from"./envUtils-DSxRz_kt.js";import{n as o,t as s}from"./figures-5ThXQEtq.js";import{D as c,Gt as l,H as u,I as d,P as f,T as p,U as ee,Wt as te,Xn as ne,a as re,d as ie,di as m,fi as h,k as ae,n as oe,ot as se,r as ce,t as g,ui as _,x as v,y as le}from"./src-CDCSSo0U2.js";import{t as y}from"./jsx-runtime-Bb4Xn-E0.js";import{en as b,gr as ue,ht as x,qt as de}from"./state-ix0xIunV.js";import{BE as fe,C as S,Dg as pe,Eg as me,F as he,Fx as C,GS as ge,Hx as _e,KS as ve,LE as ye,Px as be,S as xe,Sx as w,US as Se,Ux as Ce,VE as we,WS as T,aC as E,af as Te,ah as Ee,as as D,fx as O,if as De,is as k,jg as Oe,jr as A,mr as ke,mx as Ae,oh as je,op as j,os as M,px as Me,rp as Ne,v as Pe,xx as N,zE as Fe}from"./loadAgentsDir-D206qwP3.js";import{n as Ie,t as Le}from"./cwd-CYmmnQVS.js";import{S as Re,w as ze}from"./debug-BrXObCdR.js";import{Ft as Be,Ht as Ve,Lt as He,Rt as Ue,c as We,g as P,n as Ge,y as F,zt as Ke}from"./settings-BovzmwMP.js";import{a as qe,b as I,c as L,g as Je,i as Ye,m as Xe,o as Ze}from"./config-DmomySWC.js";import{o as R,s as Qe}from"./log-BMCygSzM.js";import{n as $e,r as z}from"./analytics-BotDBGh0.js";import{b as et,g as tt}from"./startupProfiler-xa3NmN7Z.js";import{r as nt}from"./permissions-Cn_6f8CB.js";import{Bt as rt,Ft as it,G as at,K as ot,Tr as st,_ as ct,b as lt,et as ut,it as dt,q as ft,rt as pt,tt as mt,wr as B,x as ht}from"./model-CKkOnnnx.js";import{r as gt,t as _t}from"./poorMode-DhzFKpPl.js";import{u as vt}from"./referral-CUaIo_vT.js";import{i as yt,r as bt}from"./bridgeEnabled-SbB-6zdY.js";import{a as V,c as H,d as U,i as xt,l as St,n as Ct,o as wt,r as Tt,s as Et,t as Dt,u as W}from"./status-BnJIXtKl.js";import{n as Ot,t as kt}from"./useExitOnCtrlCDWithKeybindings-DKIqRraH.js";import{i as At,n as G,r as jt}from"./modalContext-DFjKLCB6.js";import{n as Mt,t as Nt}from"./ThemePicker-BViWzLp3.js";import{i as Pt,n as Ft,r as It,t as Lt}from"./extraUsage-Dq66zzqR.js";import{n as Rt,t as zt}from"./ClaudeMdExternalIncludesDialog-BD-7yAZh.js";import{t as Bt}from"./SearchBox-vfLXEPed.js";import{n as Vt,t as Ht}from"./useSearchInput-D1Vr2Js1.js";import{n as Ut,t as Wt}from"./usage-C0SnnC-i.js";import{a as Gt,i as Kt,t as qt}from"./OverageCreditUpsell-Ds1cB7RC.js";function Jt(){let e=x();return[{label:`Version`,value:`0.0.6`},{label:`Session name`,value:ke(e)??(0,K.jsx)(f,{dimColor:!0,children:`/rename to add a name`})},{label:`Session ID`,value:e},{label:`cwd`,value:Le()},...Ct(),...Dt()]}function Yt({mainLoopModel:e,mcp:t,theme:n,context:r}){return[{label:`Model`,value:W(e)},...Tt(t.clients,r.options.ideInstallationStatus,n),...wt(t.clients,n),...H(),...St()]}async function Xt(){return[...await xt(),...await V(),...await Et()]}function Zt({value:e}){return Array.isArray(e)?(0,K.jsx)(d,{flexWrap:`wrap`,columnGap:1,flexShrink:99,children:e.map((t,n)=>(0,K.jsxs)(f,{children:[t,n<e.length-1?`,`:``]},n))}):typeof e==`string`?(0,K.jsx)(f,{children:e}):e}function Qt({context:e,diagnosticsPromise:t}){let n=T(e=>e.mainLoopModel),r=T(e=>e.mcp),[i]=u(),a=en.useMemo(()=>[Jt(),Yt({mainLoopModel:n,mcp:r,theme:i,context:e})],[n,r,i,e]),o=jt()?1:void 0;return(0,K.jsxs)(d,{flexDirection:`column`,flexGrow:o,children:[(0,K.jsxs)(d,{flexDirection:`column`,gap:1,flexGrow:o,children:[a.map((e,t)=>e.length>0&&(0,K.jsx)(d,{flexDirection:`column`,children:e.map(({label:e,value:t},n)=>(0,K.jsxs)(d,{flexDirection:`row`,gap:1,flexShrink:0,children:[e!==void 0&&(0,K.jsxs)(f,{bold:!0,children:[e,`:`]}),(0,K.jsx)(Zt,{value:t})]},n))},t)),(0,K.jsx)(tn.Suspense,{fallback:null,children:(0,K.jsx)($t,{promise:t})})]}),(0,K.jsx)(f,{dimColor:!0,children:(0,K.jsx)(N,{action:`confirm:no`,context:`Settings`,fallback:`Esc`,description:`cancel`})})]})}function $t({promise:e}){let t=(0,tn.use)(e);return t.length===0?null:(0,K.jsxs)(d,{flexDirection:`column`,paddingBottom:1,children:[(0,K.jsx)(f,{bold:!0,children:`System Diagnostics`}),t.map((e,t)=>(0,K.jsxs)(d,{flexDirection:`row`,gap:1,paddingX:1,children:[(0,K.jsx)(f,{color:`error`,children:s.warning}),typeof e==`string`?(0,K.jsx)(f,{wrap:`wrap`,children:e}):e]},t))]})}var en,tn,K,nn=t((()=>{o(),en=n(h(),1),tn=n(h(),1),b(),G(),g(),Se(),Ie(),A(),U(),w(),K=y()}));function rn({currentVersion:e,onChoice:t}){function n(e){t(e)}function r(){t(`cancel`)}return(0,an.jsxs)(le,{title:`Switch to Stable Channel`,onCancel:r,color:`permission`,hideBorder:!0,hideInputGuide:!0,children:[(0,an.jsxs)(f,{children:[`The stable channel may have an older version than what you're currently running (`,e,`).`]}),(0,an.jsx)(f,{dimColor:!0,children:`How would you like to handle this?`}),(0,an.jsx)(Me,{options:[{label:`Allow possible downgrade to stable version`,value:`downgrade`},{label:`Stay on current version (${e}) until stable catches up`,value:`stay`}],onChange:n})]})}var an,on=t((()=>{h(),g(),O(),an=y()}));function sn(e){return Object.entries(e).map(([e,t])=>({label:t?.name??un,value:e,description:t?.description??dn}))}function cn({initialStyle:e,onComplete:t,onCancel:n,isStandaloneCommand:r}){let[i,a]=(0,ln.useState)([]),[o,s]=(0,ln.useState)(!0);(0,ln.useEffect)(()=>{D(Le()).then(e=>{let t=sn(e);a(t),s(!1)}).catch(()=>{let e=sn(k);a(e),s(!1)})},[]);let c=(0,ln.useCallback)(e=>{t(e)},[t]);return(0,q.jsx)(le,{title:`Preferred output style`,onCancel:n,hideInputGuide:!r,hideBorder:!r,children:(0,q.jsxs)(d,{flexDirection:`column`,gap:1,children:[(0,q.jsx)(d,{marginTop:1,children:(0,q.jsx)(f,{dimColor:!0,children:`This changes how Claude Code communicates with you`})}),o?(0,q.jsx)(f,{dimColor:!0,children:`Loading output styles…`}):(0,q.jsx)(Me,{options:i,onChange:c,visibleOptionCount:10,defaultValue:e})]})})}var ln,q,un,dn,fn=t((()=>{h(),ln=n(h(),1),M(),g(),Ie(),Ae(),q=y(),un=`Default`,dn=`Claude completes coding tasks efficiently and provides concise responses`}));function pn({initialLanguage:e,onComplete:t,onCancel:n}){let[r,i]=(0,mn.useState)(e),[a,o]=(0,mn.useState)((e??``).length);te(`confirm:no`,n,{context:`Settings`});function c(){let e=r?.trim();t(e||void 0)}return(0,J.jsxs)(d,{flexDirection:`column`,gap:1,children:[(0,J.jsx)(f,{children:`Enter your preferred response and voice language:`}),(0,J.jsxs)(d,{flexDirection:`row`,gap:1,children:[(0,J.jsx)(f,{children:s.pointer}),(0,J.jsx)(be,{value:r??``,onChange:i,onSubmit:c,focus:!0,showCursor:!0,placeholder:`e.g., Japanese, 日本語, Español${s.ellipsis}`,columns:60,cursorOffset:a,onChangeCursorOffset:o})]}),(0,J.jsx)(f,{dimColor:!0,children:`Leave empty for default (English)`})]})}var mn,J,hn=t((()=>{o(),mn=n(h(),1),g(),vt(),C(),J=y()}));function gn({onClose:t,context:n,setTabsHidden:a,onIsSearchModeChange:o,contentHeight:ie}){let{headerFocused:m,focusHeader:h}=re(),oe=jt(),[,ce]=u(),g=ee(),[v,y]=(0,X.useState)(L()),b=Y.useRef(L()),[x,S]=(0,X.useState)(Ge()),pe=Y.useRef(Ge()),[C,_e]=(0,X.useState)(x?.outputStyle||`default`),be=Y.useRef(C),[w,Se]=(0,X.useState)(x?.language),we=Y.useRef(w),[E,Ee]=(0,X.useState)(0),[D,O]=(0,X.useState)(0),[k,A]=(0,X.useState)(!1),ke=ne(),{rows:Ae}=se(),je=ie??Math.min(Math.floor(Ae*.8),30),j=Math.max(5,je-10),M=T(e=>e.mainLoopModel),Ne=T(e=>e.verbose),Ie=T(e=>e.thinkingEnabled),Le=T(e=>pt()?e.fastMode:!1);T(e=>e.promptSuggestionEnabled);let Re=Ue(x?.permissions?.defaultMode??`default`),ze=xe()||Pe()===`enabled`,Be=(Te(),e(De)).isBriefEntitled(),P=ve(),[Je,R]=(0,X.useState)({}),$e=Y.useRef(Ie),[et]=(0,X.useState)(()=>We(`localSettings`)),[tt]=(0,X.useState)(()=>We(`userSettings`)),rt=Y.useRef(g),it=ge(),[ct]=(0,X.useState)(()=>{let e=it.getState();return{mainLoopModel:e.mainLoopModel,mainLoopModelForSession:e.mainLoopModelForSession,verbose:e.verbose,thinkingEnabled:e.thinkingEnabled,fastMode:e.fastMode,promptSuggestionEnabled:e.promptSuggestionEnabled,isBriefOnly:e.isBriefOnly,replBridgeEnabled:e.replBridgeEnabled,replBridgeOutboundOnly:e.replBridgeOutboundOnly,settings:e.settings}}),[ut]=(0,X.useState)(()=>de()),B=Y.useRef(!1),[vt,bt]=(0,X.useState)(!1),[V,H]=(0,X.useState)(null),{query:U,setQuery:xt,cursorOffset:St}=Vt({isActive:k&&V===null&&!m,onExit:()=>A(!1),onExitUp:h,passthroughCtrlKeys:[`c`,`d`]}),Ct=k&&!m;Y.useEffect(()=>{o?.(Ct)},[Ct,o]);let wt=me(n.options.mcpClients),Tt=!i(process.env.CLAUDE_CODE_DISABLE_FILE_CHECKPOINTING),Et=Y.use(Fe(!0)),Dt=fe(Et),W=qe();function Ot(e){z(`tengu_config_model_changed`,{from_model:M,to_model:e}),P(t=>({...t,mainLoopModel:e,mainLoopModelForSession:null})),R(t=>{let n=ht(e)+(Ft(e,!1,lt())?` · Billed as extra usage`:``);if(`model`in t){let{model:e,...r}=t;return{...r,model:n}}return{...t,model:n}})}function kt(e){I(t=>({...t,verbose:e})),y({...L(),verbose:e}),P(t=>({...t,verbose:e})),R(t=>{if(`verbose`in t){let{verbose:e,...n}=t;return n}return{...t,verbose:e}})}let At=[{id:`autoCompactEnabled`,label:`Auto-compact`,value:v.autoCompactEnabled,type:`boolean`,onChange(e){I(t=>({...t,autoCompactEnabled:e})),y({...L(),autoCompactEnabled:e}),z(`tengu_auto_compact_setting_changed`,{enabled:e})}},{id:`spinnerTipsEnabled`,label:`Show tips`,value:x?.spinnerTipsEnabled??!0,type:`boolean`,onChange(e){F(`localSettings`,{spinnerTipsEnabled:e}),S(t=>({...t,spinnerTipsEnabled:e})),z(`tengu_tips_setting_changed`,{enabled:e})}},{id:`cacheWarningEnabled`,label:`Cache warnings`,value:x?.cacheWarningEnabled??!0,type:`boolean`,onChange(e){F(`localSettings`,{cacheWarningEnabled:e}),S(t=>({...t,cacheWarningEnabled:e})),z(`tengu_cache_warning_setting_changed`,{enabled:e})}},{id:`prefersReducedMotion`,label:`Reduce motion`,value:x?.prefersReducedMotion??!1,type:`boolean`,onChange(e){F(`localSettings`,{prefersReducedMotion:e}),S(t=>({...t,prefersReducedMotion:e})),P(t=>({...t,settings:{...t.settings,prefersReducedMotion:e}})),z(`tengu_reduce_motion_setting_changed`,{enabled:e})}},{id:`thinkingEnabled`,label:`Thinking mode`,value:Ie??!0,type:`boolean`,onChange(e){P(t=>({...t,thinkingEnabled:e})),F(`userSettings`,{alwaysThinkingEnabled:e?void 0:!1}),z(`tengu_thinking_toggled`,{enabled:e})}},...pt()&&mt()?[{id:`fastMode`,label:`Fast mode (${at} only)`,value:!!Le,type:`boolean`,onChange(e){ot(),F(`userSettings`,{fastMode:e?!0:void 0}),e?(P(e=>({...e,mainLoopModel:ft(),mainLoopModelForSession:null,fastMode:!0})),R(e=>({...e,model:ft(),"Fast mode":`ON`}))):(P(e=>({...e,fastMode:!1})),R(e=>({...e,"Fast mode":`OFF`})))}}]:[],{id:`poorMode`,label:`Poor mode (save tokens)`,value:(_t(),e(gt)).isPoorModeActive(),type:`boolean`,onChange(t){(_t(),e(gt)).setPoorMode(t),P(e=>({...e,promptSuggestionEnabled:!t}))}},...process.env.USER_TYPE===`ant`?[{id:`speculationEnabled`,label:`Speculative execution`,value:v.speculationEnabled??!0,type:`boolean`,onChange(e){I(t=>t.speculationEnabled===e?t:{...t,speculationEnabled:e}),y({...L(),speculationEnabled:e}),z(`tengu_speculation_setting_changed`,{enabled:e})}}]:[],...Tt?[{id:`fileCheckpointingEnabled`,label:`Rewind code (checkpoints)`,value:v.fileCheckpointingEnabled,type:`boolean`,onChange(e){I(t=>({...t,fileCheckpointingEnabled:e})),y({...L(),fileCheckpointingEnabled:e}),z(`tengu_file_history_snapshots_setting_changed`,{enabled:e})}}]:[],{id:`verbose`,label:`Verbose output`,value:Ne,type:`boolean`,onChange:kt},{id:`terminalProgressBarEnabled`,label:`Terminal progress bar`,value:v.terminalProgressBarEnabled,type:`boolean`,onChange(e){I(t=>({...t,terminalProgressBarEnabled:e})),y({...L(),terminalProgressBarEnabled:e}),z(`tengu_terminal_progress_bar_setting_changed`,{enabled:e})}},{id:`showTurnDuration`,label:`Show turn duration`,value:v.showTurnDuration,type:`boolean`,onChange(e){I(t=>({...t,showTurnDuration:e})),y({...L(),showTurnDuration:e}),z(`tengu_show_turn_duration_setting_changed`,{enabled:e})}},{id:`defaultPermissionMode`,label:`Default permission mode`,value:Re,options:(()=>{let e=[`default`,`plan`];return[...e,...nt.filter(t=>!e.includes(t))]})(),type:`enum`,onChange(e){let t=Ue(e),n=t===`auto`?t:He(t)?Ve(t):t,r=F(`userSettings`,{permissions:{...x?.permissions,defaultMode:n}});if(r.error){Qe(r.error);return}S(e=>({...e,permissions:{...e?.permissions,defaultMode:n}})),R(t=>({...t,defaultPermissionMode:e})),z(`tengu_config_changed`,{setting:`defaultPermissionMode`,value:e})}},...ze?[{id:`useAutoModeDuringPlan`,label:`Use auto mode during plan`,value:x?.useAutoModeDuringPlan??!0,type:`boolean`,onChange(e){F(`userSettings`,{useAutoModeDuringPlan:e}),S(t=>({...t,useAutoModeDuringPlan:e})),P(e=>{let t=he(e.toolPermissionContext);return t===e.toolPermissionContext?e:{...e,toolPermissionContext:t}}),R(t=>({...t,"Use auto mode during plan":e}))}}]:[],{id:`respectGitignore`,label:`Respect .gitignore in file picker`,value:v.respectGitignore,type:`boolean`,onChange(e){I(t=>({...t,respectGitignore:e})),y({...L(),respectGitignore:e}),z(`tengu_respect_gitignore_setting_changed`,{enabled:e})}},...Ce()?[{id:`copyOnSelect`,label:`Copy on select`,value:v.copyOnSelect??!0,type:`boolean`,onChange(e){I(t=>({...t,copyOnSelect:e})),y({...L(),copyOnSelect:e}),z(`tengu_config_changed`,{setting:`copyOnSelect`,value:String(e)})}}]:[],W?{id:`autoUpdatesChannel`,label:`Auto-update channel`,value:`disabled`,type:`managedEnum`,onChange(){}}:{id:`autoUpdatesChannel`,label:`Auto-update channel`,value:x?.autoUpdatesChannel??`latest`,type:`managedEnum`,onChange(){}},{id:`theme`,label:`Theme`,value:g,type:`managedEnum`,onChange:ce},{id:`notifChannel`,label:`Local notifications`,value:v.preferredNotifChannel,options:[`auto`,`iterm2`,`terminal_bell`,`iterm2_with_bell`,`kitty`,`ghostty`,`notifications_disabled`],type:`enum`,onChange(e){I(t=>({...t,preferredNotifChannel:e})),y({...L(),preferredNotifChannel:e})}},{id:`taskCompleteNotifEnabled`,label:`Push when idle`,value:v.taskCompleteNotifEnabled??!1,type:`boolean`,onChange(e){I(t=>({...t,taskCompleteNotifEnabled:e})),y({...L(),taskCompleteNotifEnabled:e})}},{id:`inputNeededNotifEnabled`,label:`Push when input needed`,value:v.inputNeededNotifEnabled??!1,type:`boolean`,onChange(e){I(t=>({...t,inputNeededNotifEnabled:e})),y({...L(),inputNeededNotifEnabled:e})}},{id:`agentPushNotifEnabled`,label:`Push when Claude decides`,value:v.agentPushNotifEnabled??!1,type:`boolean`,onChange(e){I(t=>({...t,agentPushNotifEnabled:e})),y({...L(),agentPushNotifEnabled:e})}},{id:`outputStyle`,label:`Output style`,value:C,type:`managedEnum`,onChange:()=>{}},...Be?[{id:`defaultView`,label:`What you see by default`,value:x?.defaultView===void 0?`default`:String(x.defaultView),options:[`transcript`,`chat`,`default`],type:`enum`,onChange(e){let t=e==="default"?void 0:e;F(`localSettings`,{defaultView:t}),S(e=>({...e,defaultView:t}));let n=t===`chat`;P(e=>e.isBriefOnly===n?e:{...e,isBriefOnly:n}),ue(n),R(t=>({...t,"Default view":e})),z(`tengu_default_view_setting_changed`,{value:t??`unset`})}}]:[],{id:`language`,label:`Language`,value:w??`Default (English)`,type:`managedEnum`,onChange:()=>{}},{id:`editorMode`,label:`Editor mode`,value:v.editorMode===`emacs`?`normal`:v.editorMode||`normal`,options:[`normal`,`vim`],type:`enum`,onChange(e){I(t=>({...t,editorMode:e})),y({...L(),editorMode:e}),z(`tengu_editor_mode_changed`,{mode:e,source:`config_panel`})}},{id:`prStatusFooterEnabled`,label:`Show PR status footer`,value:v.prStatusFooterEnabled??!0,type:`boolean`,onChange(e){I(t=>t.prStatusFooterEnabled===e?t:{...t,prStatusFooterEnabled:e}),y({...L(),prStatusFooterEnabled:e}),z(`tengu_pr_status_footer_setting_changed`,{enabled:e})}},{id:`model`,label:`Model`,value:M===null?`Default (recommended)`:M,type:`managedEnum`,onChange:Ot},...wt?[{id:`diffTool`,label:`Diff tool`,value:v.diffTool??`auto`,options:[`terminal`,`auto`],type:`enum`,onChange(e){I(t=>({...t,diffTool:e})),y({...L(),diffTool:e}),z(`tengu_diff_tool_changed`,{tool:e,source:`config_panel`})}}]:[],...Oe()?[]:[{id:`autoConnectIde`,label:`Auto-connect to IDE (external terminal)`,value:v.autoConnectIde??!1,type:`boolean`,onChange(e){I(t=>({...t,autoConnectIde:e})),y({...L(),autoConnectIde:e}),z(`tengu_auto_connect_ide_changed`,{enabled:e,source:`config_panel`})}}],...Oe()?[{id:`autoInstallIdeExtension`,label:`Auto-install IDE extension`,value:v.autoInstallIdeExtension??!0,type:`boolean`,onChange(e){I(t=>({...t,autoInstallIdeExtension:e})),y({...L(),autoInstallIdeExtension:e}),z(`tengu_auto_install_ide_extension_changed`,{enabled:e,source:`config_panel`})}}]:[],...yt()?[{id:`remoteControlAtStartup`,label:`Enable Remote Control for all sessions`,value:v.remoteControlAtStartup===void 0?`default`:String(v.remoteControlAtStartup),options:[`true`,`false`,`default`],type:`enum`,onChange(e){if(e==="default")I(e=>{if(e.remoteControlAtStartup===void 0)return e;let t={...e};return delete t.remoteControlAtStartup,t}),y({...L(),remoteControlAtStartup:void 0});else{let t=e===`true`;I(e=>e.remoteControlAtStartup===t?e:{...e,remoteControlAtStartup:t}),y({...L(),remoteControlAtStartup:t})}let t=Xe();P(e=>e.replBridgeEnabled===t&&!e.replBridgeOutboundOnly?e:{...e,replBridgeEnabled:t,replBridgeOutboundOnly:!1})}}]:[],...Dt?[{id:`showExternalIncludesDialog`,label:`External CLAUDE.md includes`,value:Ze().hasClaudeMdExternalIncludesApproved?`true`:`false`,type:`managedEnum`,onChange(){}}]:[],...process.env.ANTHROPIC_API_KEY&&!r()?[{id:`apiKey`,label:(0,Z.jsxs)(f,{children:[`Use custom API key: `,(0,Z.jsx)(f,{bold:!0,children:st(process.env.ANTHROPIC_API_KEY)})]}),searchText:`Use custom API key`,value:!!(process.env.ANTHROPIC_API_KEY&&v.customApiKeyResponses?.approved?.includes(st(process.env.ANTHROPIC_API_KEY))),type:`boolean`,onChange(e){I(t=>{let n={...t};if(n.customApiKeyResponses||(n.customApiKeyResponses={approved:[],rejected:[]}),n.customApiKeyResponses.approved||(n.customApiKeyResponses={...n.customApiKeyResponses,approved:[]}),n.customApiKeyResponses.rejected||(n.customApiKeyResponses={...n.customApiKeyResponses,rejected:[]}),process.env.ANTHROPIC_API_KEY){let t=st(process.env.ANTHROPIC_API_KEY);e?n.customApiKeyResponses={...n.customApiKeyResponses,approved:[...(n.customApiKeyResponses.approved??[]).filter(e=>e!==t),t],rejected:(n.customApiKeyResponses.rejected??[]).filter(e=>e!==t)}:n.customApiKeyResponses={...n.customApiKeyResponses,approved:(n.customApiKeyResponses.approved??[]).filter(e=>e!==t),rejected:[...(n.customApiKeyResponses.rejected??[]).filter(e=>e!==t),t]}}return n}),y(L())}}]:[]],G=Y.useMemo(()=>{if(!U)return At;let e=U.toLowerCase();return At.filter(t=>t.id.toLowerCase().includes(e)?!0:(`searchText`in t?t.searchText:t.label).toLowerCase().includes(e))},[At,U]);Y.useEffect(()=>{if(E>=G.length){let e=Math.max(0,G.length-1);Ee(e),O(Math.max(0,e-j+1));return}O(e=>E<e?E:E>=e+j?E-j+1:e)},[G.length,E,j]);let Mt=(0,X.useCallback)(e=>{O(t=>e<t?e:e>=t+j?e-j+1:t)},[j]),Pt=(0,X.useCallback)(()=>{if(V!==null)return;let e=Object.entries(Je).map(([e,t])=>(z(`tengu_config_changed`,{key:e,value:t}),`Set ${e} to ${_.bold(t)}`)),n=r()?void 0:process.env.ANTHROPIC_API_KEY,i=!!(n&&b.current.customApiKeyResponses?.approved?.includes(st(n))),a=!!(n&&v.customApiKeyResponses?.approved?.includes(st(n)));if(i!==a&&(e.push(`${a?`Enabled`:`Disabled`} custom API key`),z(`tengu_config_changed`,{key:`env.ANTHROPIC_API_KEY`,value:a})),v.theme!==b.current.theme&&e.push(`Set theme to ${_.bold(v.theme)}`),v.preferredNotifChannel!==b.current.preferredNotifChannel&&e.push(`Set notifications to ${_.bold(v.preferredNotifChannel)}`),C!==be.current&&e.push(`Set output style to ${_.bold(C)}`),w!==we.current&&e.push(`Set response language to ${_.bold(w??`Default (English)`)}`),v.editorMode!==b.current.editorMode&&e.push(`Set editor mode to ${_.bold(v.editorMode||`emacs`)}`),v.diffTool!==b.current.diffTool&&e.push(`Set diff tool to ${_.bold(v.diffTool)}`),v.autoConnectIde!==b.current.autoConnectIde&&e.push(`${v.autoConnectIde?`Enabled`:`Disabled`} auto-connect to IDE`),v.autoInstallIdeExtension!==b.current.autoInstallIdeExtension&&e.push(`${v.autoInstallIdeExtension?`Enabled`:`Disabled`} auto-install IDE extension`),v.autoCompactEnabled!==b.current.autoCompactEnabled&&e.push(`${v.autoCompactEnabled?`Enabled`:`Disabled`} auto-compact`),v.respectGitignore!==b.current.respectGitignore&&e.push(`${v.respectGitignore?`Enabled`:`Disabled`} respect .gitignore in file picker`),v.copyOnSelect!==b.current.copyOnSelect&&e.push(`${v.copyOnSelect?`Enabled`:`Disabled`} copy on select`),v.terminalProgressBarEnabled!==b.current.terminalProgressBarEnabled&&e.push(`${v.terminalProgressBarEnabled?`Enabled`:`Disabled`} terminal progress bar`),v.showStatusInTerminalTab!==b.current.showStatusInTerminalTab&&e.push(`${v.showStatusInTerminalTab?`Enabled`:`Disabled`} terminal tab status`),v.showTurnDuration!==b.current.showTurnDuration&&e.push(`${v.showTurnDuration?`Enabled`:`Disabled`} turn duration`),v.remoteControlAtStartup!==b.current.remoteControlAtStartup){let t=v.remoteControlAtStartup===void 0?`Reset Remote Control to default`:`${v.remoteControlAtStartup?`Enabled`:`Disabled`} Remote Control for all sessions`;e.push(t)}x?.autoUpdatesChannel!==pe.current?.autoUpdatesChannel&&e.push(`Set auto-update channel to ${_.bold(x?.autoUpdatesChannel??`latest`)}`),e.length>0?t(e.join(`
|
|
2
|
+
`)):t(`Config dialog dismissed`,{display:`system`})},[V,Je,v,M,C,w,x?.autoUpdatesChannel,pt()?x?.fastMode:void 0,t]),Lt=(0,X.useCallback)(()=>{g!==rt.current&&ce(rt.current),I(()=>b.current);let e=et;F(`localSettings`,{spinnerTipsEnabled:e?.spinnerTipsEnabled,prefersReducedMotion:e?.prefersReducedMotion,defaultView:e?.defaultView,outputStyle:e?.outputStyle});let t=tt;F(`userSettings`,{alwaysThinkingEnabled:t?.alwaysThinkingEnabled,fastMode:t?.fastMode,promptSuggestionEnabled:t?.promptSuggestionEnabled,autoUpdatesChannel:t?.autoUpdatesChannel,minimumVersion:t?.minimumVersion,language:t?.language,useAutoModeDuringPlan:t?.useAutoModeDuringPlan,syntaxHighlightingDisabled:t?.syntaxHighlightingDisabled,permissions:t?.permissions===void 0?void 0:{...t.permissions,defaultMode:t.permissions.defaultMode}});let n=ct;P(e=>({...e,mainLoopModel:n.mainLoopModel,mainLoopModelForSession:n.mainLoopModelForSession,verbose:n.verbose,thinkingEnabled:n.thinkingEnabled,fastMode:n.fastMode,promptSuggestionEnabled:n.promptSuggestionEnabled,isBriefOnly:n.isBriefOnly,replBridgeEnabled:n.replBridgeEnabled,replBridgeOutboundOnly:n.replBridgeOutboundOnly,settings:n.settings,toolPermissionContext:he(e.toolPermissionContext)})),de()!==ut&&ue(ut)},[g,ce,et,tt,ct,ut,P]);te(`confirm:no`,(0,X.useCallback)(()=>{V===null&&(B.current&&Lt(),t(`Config dialog dismissed`,{display:`system`}))},[V,Lt,t]),{context:`Settings`,isActive:V===null&&!k&&!m}),te(`settings:close`,Pt,{context:`Settings`,isActive:V===null&&!k&&!m});let Rt=(0,X.useCallback)(()=>{let e=G[E];if(!(!e||!e.onChange)){if(e.type===`boolean`){B.current=!0,e.onChange(!e.value),e.id===`thinkingEnabled`&&(!e.value===$e.current?bt(!1):n.messages.some(e=>e.type===`assistant`)&&bt(!0));return}if(e.id===`theme`||e.id===`model`||e.id===`showExternalIncludesDialog`||e.id===`outputStyle`||e.id===`language`)switch(e.id){case`theme`:H(`Theme`),a(!0);return;case`model`:H(`Model`),a(!0);return;case`showExternalIncludesDialog`:H(`ExternalIncludes`),a(!0);return;case`outputStyle`:H(`OutputStyle`),a(!0);return;case`language`:H(`Language`),a(!0);return}if(e.id===`autoUpdatesChannel`){if(W){H(`EnableAutoUpdates`),a(!0);return}(x?.autoUpdatesChannel??`latest`)===`latest`?(H(`ChannelDowngrade`),a(!0)):(B.current=!0,F(`userSettings`,{autoUpdatesChannel:`latest`,minimumVersion:void 0}),S(e=>({...e,autoUpdatesChannel:`latest`,minimumVersion:void 0})),z(`tengu_autoupdate_channel_changed`,{channel:`latest`}));return}if(e.type===`enum`){B.current=!0;let t=(e.options.indexOf(e.value)+1)%e.options.length;e.onChange(e.options[t]);return}}},[W,G,E,x?.autoUpdatesChannel,a]),Bt=e=>{bt(!1);let t=Math.max(0,Math.min(G.length-1,E+e));Ee(t),Mt(t)};return l({"select:previous":()=>{E===0?(bt(!1),A(!0),O(0)):Bt(-1)},"select:next":()=>Bt(1),"scroll:lineUp":()=>Bt(-1),"scroll:lineDown":()=>Bt(1),"select:accept":Rt,"select:previousValue":()=>Rt(),"select:nextValue":()=>Rt(),"settings:search":()=>{A(!0),xt(``)}},{context:`Settings`,isActive:V===null&&!k&&!m}),(0,Z.jsx)(d,{flexDirection:`column`,width:`100%`,tabIndex:0,autoFocus:!0,onKeyDown:(0,X.useCallback)(e=>{if(V===null&&!m){if(k){if(e.key===`escape`){e.preventDefault(),U.length>0?xt(``):A(!1);return}(e.key===`return`||e.key===`down`||e.key===`wheeldown`)&&(e.preventDefault(),A(!1),Ee(0),O(0));return}if(e.key===`left`||e.key===`right`||e.key===`tab`){e.preventDefault(),Rt();return}e.ctrl||e.meta||e.key===`j`||e.key===`k`||e.key===`/`||e.key.length===1&&e.key!==` `&&(e.preventDefault(),A(!0),xt(e.key))}},[V,m,k,U,xt,Rt]),children:V===`Theme`?(0,Z.jsxs)(Z.Fragment,{children:[(0,Z.jsx)(Nt,{onThemeSelect:e=>{B.current=!0,ce(e),H(null),a(!1)},onCancel:()=>{H(null),a(!1)},hideEscToCancel:!0,skipExitHandling:!0}),(0,Z.jsx)(d,{children:(0,Z.jsx)(f,{dimColor:!0,italic:!0,children:(0,Z.jsxs)(p,{children:[(0,Z.jsx)(c,{shortcut:`Enter`,action:`select`}),(0,Z.jsx)(N,{action:`confirm:no`,context:`Confirmation`,fallback:`Esc`,description:`cancel`})]})})})]}):V===`Model`?(0,Z.jsxs)(Z.Fragment,{children:[(0,Z.jsx)(It,{initial:M,onSelect:e=>{B.current=!0,Ot(e),H(null),a(!1)},onCancel:()=>{H(null),a(!1)},showFastModeNotice:pt()?Le&&dt(M)&&mt():!1}),(0,Z.jsx)(f,{dimColor:!0,children:(0,Z.jsxs)(p,{children:[(0,Z.jsx)(c,{shortcut:`Enter`,action:`confirm`}),(0,Z.jsx)(N,{action:`confirm:no`,context:`Confirmation`,fallback:`Esc`,description:`cancel`})]})})]}):V===`ExternalIncludes`?(0,Z.jsxs)(Z.Fragment,{children:[(0,Z.jsx)(zt,{onDone:()=>{H(null),a(!1)},externalIncludes:ye(Et)}),(0,Z.jsx)(f,{dimColor:!0,children:(0,Z.jsxs)(p,{children:[(0,Z.jsx)(c,{shortcut:`Enter`,action:`confirm`}),(0,Z.jsx)(N,{action:`confirm:no`,context:`Confirmation`,fallback:`Esc`,description:`disable external includes`})]})})]}):V===`OutputStyle`?(0,Z.jsxs)(Z.Fragment,{children:[(0,Z.jsx)(cn,{initialStyle:C,onComplete:e=>{B.current=!0,_e(e??`default`),H(null),a(!1),F(`localSettings`,{outputStyle:e}),z(`tengu_output_style_changed`,{style:e??`default`,source:`config_panel`,settings_source:`localSettings`})},onCancel:()=>{H(null),a(!1)}}),(0,Z.jsx)(f,{dimColor:!0,children:(0,Z.jsxs)(p,{children:[(0,Z.jsx)(c,{shortcut:`Enter`,action:`confirm`}),(0,Z.jsx)(N,{action:`confirm:no`,context:`Confirmation`,fallback:`Esc`,description:`cancel`})]})})]}):V===`Language`?(0,Z.jsxs)(Z.Fragment,{children:[(0,Z.jsx)(pn,{initialLanguage:w,onComplete:e=>{B.current=!0,Se(e),H(null),a(!1),F(`userSettings`,{language:e}),z(`tengu_language_changed`,{language:e??`default`,source:`config_panel`})},onCancel:()=>{H(null),a(!1)}}),(0,Z.jsx)(f,{dimColor:!0,children:(0,Z.jsxs)(p,{children:[(0,Z.jsx)(c,{shortcut:`Enter`,action:`confirm`}),(0,Z.jsx)(N,{action:`confirm:no`,context:`Settings`,fallback:`Esc`,description:`cancel`})]})})]}):V===`EnableAutoUpdates`?(0,Z.jsx)(le,{title:`Enable Auto-Updates`,onCancel:()=>{H(null),a(!1)},hideBorder:!0,hideInputGuide:!0,children:W?.type===`config`?(0,Z.jsx)(Me,{options:[{label:`Enable with latest channel`,value:`latest`},{label:`Enable with stable channel`,value:`stable`}],onChange:e=>{B.current=!0,H(null),a(!1),I(e=>({...e,autoUpdates:!0})),y({...L(),autoUpdates:!0}),F(`userSettings`,{autoUpdatesChannel:e,minimumVersion:void 0}),S(t=>({...t,autoUpdatesChannel:e,minimumVersion:void 0})),z(`tengu_autoupdate_enabled`,{channel:e})}}):(0,Z.jsxs)(Z.Fragment,{children:[(0,Z.jsx)(f,{children:W?.type===`env`?`Auto-updates are controlled by an environment variable and cannot be changed here.`:`Auto-updates are disabled in development builds.`}),W?.type===`env`&&(0,Z.jsxs)(f,{dimColor:!0,children:[`Unset `,W.envVar,` to re-enable auto-updates.`]})]})}):V===`ChannelDowngrade`?(0,Z.jsx)(rn,{currentVersion:`0.0.6`,onChoice:e=>{if(H(null),a(!1),e===`cancel`)return;B.current=!0;let t={autoUpdatesChannel:`stable`};e===`stay`&&(t.minimumVersion=`0.0.6`),F(`userSettings`,t),S(e=>({...e,...t})),z(`tengu_autoupdate_channel_changed`,{channel:`stable`,minimum_version_set:e===`stay`})}}):(0,Z.jsxs)(d,{flexDirection:`column`,gap:1,marginY:oe?void 0:1,children:[(0,Z.jsx)(ae,{query:U,isFocused:k&&!m,isTerminalFocused:ke,cursorOffset:St,placeholder:`Search settings…`}),(0,Z.jsx)(d,{flexDirection:`column`,children:G.length===0?(0,Z.jsxs)(f,{dimColor:!0,italic:!0,children:[`No settings match "`,U,`"`]}):(0,Z.jsxs)(Z.Fragment,{children:[D>0&&(0,Z.jsxs)(f,{dimColor:!0,children:[s.arrowUp,` `,D,` more above`]}),G.slice(D,D+j).map((e,t)=>{let n=D+t===E&&!m&&!k;return(0,Z.jsx)(Y.Fragment,{children:(0,Z.jsxs)(d,{width:`100%`,children:[(0,Z.jsx)(d,{width:44,children:(0,Z.jsxs)(f,{color:n?`suggestion`:void 0,children:[n?s.pointer:` `,` `,e.label]})}),(0,Z.jsx)(d,{flexGrow:1,children:e.type===`boolean`?(0,Z.jsxs)(Z.Fragment,{children:[(0,Z.jsx)(f,{color:n?`suggestion`:void 0,children:e.value.toString()}),vt&&e.id===`thinkingEnabled`&&(0,Z.jsxs)(f,{color:`warning`,children:[` `,`Changing thinking mode mid-conversation will increase latency and may reduce quality.`]})]}):e.id===`theme`?(0,Z.jsx)(f,{color:n?`suggestion`:void 0,children:vn[e.value.toString()]??e.value.toString()}):e.id===`notifChannel`?(0,Z.jsx)(f,{color:n?`suggestion`:void 0,children:(0,Z.jsx)(_n,{value:e.value.toString()})}):e.id===`defaultPermissionMode`?(0,Z.jsx)(f,{color:n?`suggestion`:void 0,children:Ke(e.value)}):e.id===`autoUpdatesChannel`&&W?(0,Z.jsxs)(d,{flexDirection:`column`,children:[(0,Z.jsx)(f,{color:n?`suggestion`:void 0,children:`disabled`}),(0,Z.jsxs)(f,{dimColor:!0,children:[`(`,Ye(W),`)`]})]}):(0,Z.jsx)(f,{color:n?`suggestion`:void 0,children:e.value.toString()})})]})},e.id)}),D+j<G.length&&(0,Z.jsxs)(f,{dimColor:!0,children:[s.arrowDown,` `,G.length-D-j,` more below`]})]})}),m?(0,Z.jsx)(f,{dimColor:!0,children:(0,Z.jsxs)(p,{children:[(0,Z.jsx)(c,{shortcut:`←/→ tab`,action:`switch`}),(0,Z.jsx)(c,{shortcut:`↓`,action:`return`}),(0,Z.jsx)(N,{action:`confirm:no`,context:`Settings`,fallback:`Esc`,description:`close`})]})}):k?(0,Z.jsx)(f,{dimColor:!0,children:(0,Z.jsxs)(p,{children:[(0,Z.jsx)(f,{children:`Type to filter`}),(0,Z.jsx)(c,{shortcut:`Enter/↓`,action:`select`}),(0,Z.jsx)(c,{shortcut:`↑`,action:`tabs`}),(0,Z.jsx)(N,{action:`confirm:no`,context:`Settings`,fallback:`Esc`,description:`clear`})]})}):(0,Z.jsx)(f,{dimColor:!0,children:(0,Z.jsxs)(p,{children:[(0,Z.jsx)(N,{action:`select:accept`,context:`Settings`,fallback:`Space`,description:`change`}),(0,Z.jsx)(N,{action:`settings:close`,context:`Settings`,fallback:`Enter`,description:`save`}),(0,Z.jsx)(N,{action:`settings:search`,context:`Settings`,fallback:`/`,description:`search`}),(0,Z.jsx)(N,{action:`confirm:no`,context:`Settings`,fallback:`Esc`,description:`cancel`})]})})]})})}function _n({value:e}){switch(e){case`auto`:return`Auto`;case`iterm2`:return(0,Z.jsxs)(f,{children:[`iTerm2 `,(0,Z.jsx)(f,{dimColor:!0,children:`(OSC 9)`})]});case`terminal_bell`:return(0,Z.jsxs)(f,{children:[`Terminal Bell `,(0,Z.jsx)(f,{dimColor:!0,children:`(\\a)`})]});case`kitty`:return(0,Z.jsxs)(f,{children:[`Kitty `,(0,Z.jsx)(f,{dimColor:!0,children:`(OSC 99)`})]});case`ghostty`:return(0,Z.jsxs)(f,{children:[`Ghostty `,(0,Z.jsx)(f,{dimColor:!0,children:`(OSC 777)`})]});case`iterm2_with_bell`:return`iTerm2 w/ Bell`;case`notifications_disabled`:return`Disabled`;default:return e}}var Y,X,Z,vn,yn=t((()=>{g(),Y=n(h(),1),X=n(h(),1),vt(),o(),Je(),B(),m(),Be(),S(),R(),$e(),bt(),Mt(),Se(),Pt(),ct(),Lt(),Rt(),on(),O(),fn(),hn(),we(),w(),G(),Bt(),pe(),P(),b(),M(),a(),Ht(),E(),ut(),_e(),Z=y(),vn={auto:`Auto (match terminal)`,dark:`Dark mode`,light:`Light mode`,"dark-daltonized":`Dark mode (colorblind-friendly)`,"light-daltonized":`Light mode (colorblind-friendly)`,"dark-ansi":`Dark mode (ANSI colors only)`,"light-ansi":`Light mode (ANSI colors only)`}}));function bn({title:e,limit:t,maxWidth:n,showTimeInReset:r=!0,extraSubtext:i}){let{utilization:a,resets_at:o}=t;if(a===null)return null;let s=`${Math.floor(a)}% used`,c;return o&&(c=`Resets ${tt(o,!0,r)}`),i&&(c=c?`${i} · ${c}`:i),n>=62?(0,Q.jsxs)(d,{flexDirection:`column`,children:[(0,Q.jsx)(f,{bold:!0,children:e}),(0,Q.jsxs)(d,{flexDirection:`row`,gap:1,children:[(0,Q.jsx)(ie,{ratio:a/100,width:50,fillColor:`rate_limit_fill`,emptyColor:`rate_limit_empty`}),(0,Q.jsx)(f,{children:s})]}),c&&(0,Q.jsx)(f,{dimColor:!0,children:c})]}):(0,Q.jsxs)(d,{flexDirection:`column`,children:[(0,Q.jsxs)(f,{children:[(0,Q.jsx)(f,{bold:!0,children:e}),c&&(0,Q.jsxs)(Q.Fragment,{children:[(0,Q.jsx)(f,{children:` `}),(0,Q.jsxs)(f,{dimColor:!0,children:[`· `,c]})]})]}),(0,Q.jsx)(ie,{ratio:a/100,width:n,fillColor:`rate_limit_fill`,emptyColor:`rate_limit_empty`}),(0,Q.jsx)(f,{children:s})]})}function xn(){let[e,t]=(0,wn.useState)(null),[n,r]=(0,wn.useState)(null),[i,a]=(0,wn.useState)(!0),{columns:o}=se(),s=o-2,c=Math.min(s,80),l=Cn.useCallback(async()=>{a(!0),r(null);try{let e=await Wt();t(e)}catch(e){Qe(e);let t=e,n=t.response?.data?ze(t.response.data):void 0;r(n?`Failed to load usage data: ${n}`:`Failed to load usage data`)}finally{a(!1)}},[]);if((0,wn.useEffect)(()=>{l()},[l]),te(`settings:retry`,()=>{l()},{context:`Settings`,isActive:!!n&&!i}),n)return(0,Q.jsxs)(d,{flexDirection:`column`,gap:1,children:[(0,Q.jsxs)(f,{color:`error`,children:[`Error: `,n]}),(0,Q.jsx)(f,{dimColor:!0,children:(0,Q.jsxs)(p,{children:[(0,Q.jsx)(N,{action:`settings:retry`,context:`Settings`,fallback:`r`,description:`retry`}),(0,Q.jsx)(N,{action:`confirm:no`,context:`Settings`,fallback:`Esc`,description:`cancel`})]})})]});if(!e)return(0,Q.jsxs)(d,{flexDirection:`column`,gap:1,children:[(0,Q.jsx)(f,{dimColor:!0,children:`Loading usage data…`}),(0,Q.jsx)(f,{dimColor:!0,children:(0,Q.jsx)(N,{action:`confirm:no`,context:`Settings`,fallback:`Esc`,description:`cancel`})})]});let u=it(),ee=u===`max`||u===`team`||u===null,ne=[{title:`Current session`,limit:e.five_hour},{title:`Current week (all models)`,limit:e.seven_day},...ee?[{title:`Current week (Sonnet only)`,limit:e.seven_day_sonnet}]:[]];return(0,Q.jsxs)(d,{flexDirection:`column`,gap:1,width:`100%`,children:[ne.some(({limit:e})=>e)||(0,Q.jsx)(f,{dimColor:!0,children:`/usage is only available for subscription plans.`}),ne.map(({title:e,limit:t})=>t&&(0,Q.jsx)(bn,{title:e,limit:t,maxWidth:c},e)),e.extra_usage&&(0,Q.jsx)(Sn,{extraUsage:e.extra_usage,maxWidth:c}),Gt()&&(0,Q.jsx)(qt,{maxWidth:c}),(0,Q.jsx)(f,{dimColor:!0,children:(0,Q.jsx)(N,{action:`confirm:no`,context:`Settings`,fallback:`Esc`,description:`cancel`})})]})}function Sn({extraUsage:e,maxWidth:t}){let n=it();if(!(n===`pro`||n===`max`))return!1;if(!e.is_enabled)return Ee.isEnabled()?(0,Q.jsxs)(d,{flexDirection:`column`,children:[(0,Q.jsx)(f,{bold:!0,children:Tn}),(0,Q.jsx)(f,{dimColor:!0,children:`Extra usage not enabled · /extra-usage to enable`})]}):null;if(e.monthly_limit===null)return(0,Q.jsxs)(d,{flexDirection:`column`,children:[(0,Q.jsx)(f,{bold:!0,children:Tn}),(0,Q.jsx)(f,{dimColor:!0,children:`Unlimited`})]});if(typeof e.used_credits!=`number`||typeof e.utilization!=`number`)return null;let r=Ne(e.used_credits/100,2),i=Ne(e.monthly_limit/100,2),a=new Date,o=new Date(a.getFullYear(),a.getMonth()+1,1);return(0,Q.jsx)(bn,{title:Tn,limit:{utilization:e.utilization,resets_at:o.toISOString()},showTimeInReset:!1,extraSubtext:`${r} / ${i} spent`,maxWidth:t})}var Cn,wn,Q,Tn,En=t((()=>{Cn=n(h(),1),wn=n(h(),1),je(),j(),rt(),E(),g(),vt(),Ut(),et(),R(),Re(),w(),Kt(),Q=y(),Tn=`Extra usage`}));function Dn({onClose:e,context:t,defaultTab:n}){let[r,i]=(0,On.useState)(n),[a,o]=(0,On.useState)(!1),[s,c]=(0,On.useState)(!1),l=jt(),{rows:u}=At(se()),d=l?u+1:Math.max(15,Math.min(Math.floor(u*.8),30)),[f]=(0,On.useState)(()=>Xt().catch(()=>[]));return Ot(),te(`confirm:no`,()=>{a||e(`Status dialog dismissed`,{display:`system`})},{context:`Settings`,isActive:!a&&!(r===`Config`&&s)}),(0,$.jsx)(v,{color:`permission`,children:(0,$.jsx)(ce,{color:`permission`,selectedTab:r,onTabChange:i,hidden:a,initialHeaderFocused:n!==`Config`,contentHeight:a||l?void 0:d,children:[(0,$.jsx)(oe,{title:`Status`,children:(0,$.jsx)(Qt,{context:t,diagnosticsPromise:f})},`status`),(0,$.jsx)(oe,{title:`Config`,children:(0,$.jsx)(On.Suspense,{fallback:null,children:(0,$.jsx)(gn,{context:t,onClose:e,setTabsHidden:o,onIsSearchModeChange:c,contentHeight:d})})},`config`),(0,$.jsx)(oe,{title:`Usage`,children:(0,$.jsx)(xn,{})},`usage`)]})})}var On,$,kn=t((()=>{h(),On=n(h(),1),vt(),kt(),E(),G(),g(),nn(),yn(),En(),$=y()}));export{kn as n,Dn as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{o as e}from"./rolldown-runtime-DaDcL9Zw.js";import{n as t,t as n}from"./figures-5ThXQEtq.js";import{I as r,P as i,fi as a,mt as o,t as s}from"./src-CDCSSo0U2.js";import{t as c}from"./jsx-runtime-Bb4Xn-E0.js";import{Dy as l,Ey as u,HS as d,US as f,jy as p,ky as m}from"./loadAgentsDir-
|
|
1
|
+
import{o as e}from"./rolldown-runtime-DaDcL9Zw.js";import{n as t,t as n}from"./figures-5ThXQEtq.js";import{I as r,P as i,fi as a,mt as o,t as s}from"./src-CDCSSo0U2.js";import{t as c}from"./jsx-runtime-Bb4Xn-E0.js";import{Dy as l,Ey as u,HS as d,US as f,jy as p,ky as m}from"./loadAgentsDir-D206qwP3.js";t();var h=e(a(),1);s(),f(),l();var g=c(),_=[`◐`,`◓`,`◑`,`◒`],v=[{key:`validating`,label:`Validating session`},{key:`fetching_logs`,label:`Fetching session logs`},{key:`fetching_branch`,label:`Getting branch info`},{key:`checking_out`,label:`Checking out branch`}];function y({currentStep:e,sessionId:t}){let[a,s]=o(100),c=Math.floor(s/100)%_.length,l=v.findIndex(t=>t.key===e);return(0,g.jsxs)(r,{ref:a,flexDirection:`column`,paddingX:1,paddingY:1,children:[(0,g.jsx)(r,{marginBottom:1,children:(0,g.jsxs)(i,{bold:!0,color:`claude`,children:[_[c],` Teleporting session…`]})}),t&&(0,g.jsx)(r,{marginBottom:1,children:(0,g.jsx)(i,{dimColor:!0,children:t})}),(0,g.jsx)(r,{flexDirection:`column`,marginLeft:2,children:v.map((e,t)=>{let a=t<l,o=t===l,s=t>l,u,d;return a?(u=n.tick,d=`green`):o?(u=_[c],d=`claude`):(u=n.circle,d=void 0),(0,g.jsxs)(r,{flexDirection:`row`,children:[(0,g.jsx)(r,{width:2,children:(0,g.jsx)(i,{color:d,dimColor:s,children:u})}),(0,g.jsx)(i,{dimColor:s,bold:o,children:e.label})]},e.key)})})]})}async function b(e,t){let n=()=>{};function r(){let[e,r]=(0,h.useState)(`validating`);return n=r,(0,g.jsx)(y,{currentStep:e,sessionId:t})}e.render((0,g.jsx)(d,{children:(0,g.jsx)(r,{})}));let i=await p(t,n);n(`checking_out`);let{branchName:a,branchError:o}=await u(i.branch);return{messages:m(i.log,o),branchName:a}}export{b as teleportWithProgress};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{o as e}from"./rolldown-runtime-DaDcL9Zw.js";import{I as t,P as n,fi as r,t as i,y as a}from"./src-CDCSSo0U2.js";import{t as o}from"./jsx-runtime-Bb4Xn-E0.js";import{Fb as s,Nb as c,fx as l,px as u}from"./loadAgentsDir-
|
|
1
|
+
import{o as e}from"./rolldown-runtime-DaDcL9Zw.js";import{I as t,P as n,fi as r,t as i,y as a}from"./src-CDCSSo0U2.js";import{t as o}from"./jsx-runtime-Bb4Xn-E0.js";import{Fb as s,Nb as c,fx as l,px as u}from"./loadAgentsDir-D206qwP3.js";import{f as d,l as f}from"./file-DcZWPH2V.js";import{a as p,r as m}from"./githubRepoPathMapping-qAoiyj6P.js";var h=e(r(),1);i(),d(),l(),s();var g=o();function _({targetRepo:e,initialPaths:r,onSelectPath:i,onCancel:o}){let[s,l]=(0,h.useState)(r),[d,_]=(0,h.useState)(null),[v,y]=(0,h.useState)(!1),b=(0,h.useCallback)(async t=>{if(t===`cancel`){o();return}if(y(!0),_(null),await p(t,e)){i(t);return}m(e,t);let n=s.filter(e=>e!==t);l(n),y(!1),_(`${f(t)} no longer contains the correct repository. Select another path.`)},[e,s,i,o]),x=[...s.map(e=>({label:(0,g.jsxs)(n,{children:[`Use `,(0,g.jsx)(n,{bold:!0,children:f(e)})]}),value:e})),{label:`Cancel`,value:`cancel`}];return(0,g.jsx)(a,{title:`Teleport to Repo`,onCancel:o,color:`background`,children:s.length>0?(0,g.jsxs)(g.Fragment,{children:[(0,g.jsxs)(t,{flexDirection:`column`,gap:1,children:[d&&(0,g.jsx)(n,{color:`error`,children:d}),(0,g.jsxs)(n,{children:[`Open Claude Code in `,(0,g.jsx)(n,{bold:!0,children:e}),`:`]})]}),v?(0,g.jsxs)(t,{children:[(0,g.jsx)(c,{}),(0,g.jsx)(n,{children:` Validating repository…`})]}):(0,g.jsx)(u,{options:x,onChange:e=>void b(e)})]}):(0,g.jsxs)(t,{flexDirection:`column`,gap:1,children:[d&&(0,g.jsx)(n,{color:`error`,children:d}),(0,g.jsxs)(n,{dimColor:!0,children:[`Run claude --teleport from a checkout of `,e]})]})})}export{_ as TeleportRepoMismatchDialog};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{o as e}from"./rolldown-runtime-DaDcL9Zw.js";import{D as t,I as n,P as r,T as i,Wt as a,fi as o,hn as s,ot as c,t as l}from"./src-CDCSSo0U2.js";import{t as u}from"./jsx-runtime-Bb4Xn-E0.js";import{en as d,pr as f}from"./state-ix0xIunV.js";import{Ab as p,Cx as m,Dy as h,Fb as g,Nb as _,Sx as v,aC as y,fx as b,jb as x,jy as S,px as C,wx as w,xx as T}from"./loadAgentsDir-
|
|
1
|
+
import{o as e}from"./rolldown-runtime-DaDcL9Zw.js";import{D as t,I as n,P as r,T as i,Wt as a,fi as o,hn as s,ot as c,t as l}from"./src-CDCSSo0U2.js";import{t as u}from"./jsx-runtime-Bb4Xn-E0.js";import{en as d,pr as f}from"./state-ix0xIunV.js";import{Ab as p,Cx as m,Dy as h,Fb as g,Nb as _,Sx as v,aC as y,fx as b,jb as x,jy as S,px as C,wx as w,xx as T}from"./loadAgentsDir-D206qwP3.js";import{F as E,N as D,a as O,l as k,z as A}from"./debug-BrXObCdR.js";import{n as j,r as M}from"./analytics-BotDBGh0.js";import{b as N,m as P}from"./startupProfiler-xa3NmN7Z.js";import{i as F,n as I}from"./detectRepository-BPr0VWNO.js";import{n as L,o as R}from"./api-gqTA-D7n.js";import{u as z}from"./referral-CUaIo_vT.js";var B=e(o(),1);d(),j(),A(),h();function V(e){let[t,n]=(0,B.useState)(!1),[r,i]=(0,B.useState)(null),[a,o]=(0,B.useState)(null);return{resumeSession:(0,B.useCallback)(async t=>{n(!0),i(null),o(t),M(`tengu_teleport_resume_session`,{source:e,session_id:t.id});try{let e=await S(t.id);return f({sessionId:t.id}),n(!1),e}catch(e){let t={message:e instanceof D?e.message:E(e),formattedMessage:e instanceof D?e.formattedMessage:void 0,isOperationError:e instanceof D};return i(t),n(!1),null}},[e]),isResuming:t,error:r,selectedSession:a,clearError:(0,B.useCallback)(()=>{i(null)},[])}}y(),R(),l(),z(),m(),O(),F(),N(),v(),b(),g(),x();var H=u(),U=`Updated`,W=` `;function G({onSelect:e,onCancel:o,isEmbedded:l=!1}){let{rows:u}=c(),[d,f]=(0,B.useState)([]),[m,h]=(0,B.useState)(null),[g,v]=(0,B.useState)(!0),[y,b]=(0,B.useState)(null),[x,S]=(0,B.useState)(!1),[E,D]=(0,B.useState)(!1),[O,A]=(0,B.useState)(1),j=w(`confirm:no`,`Confirmation`,`Esc`),M=(0,B.useCallback)(async()=>{try{v(!0),b(null);let e=await I();h(e),k(`Current repository: ${e||`not detected`}`);let t=await L(),n=t;e&&(n=t.filter(t=>t.repo?`${t.repo.owner.login}/${t.repo.name}`===e:!1),k(`Filtered ${n.length} sessions for repo ${e} from ${t.length} total`));let r=[...n].sort((e,t)=>{let n=new Date(e.updated_at);return new Date(t.updated_at).getTime()-n.getTime()});f(r)}catch(e){let t=e instanceof Error?e.message:String(e);k(`Error loading code sessions: ${t}`),b(K(t))}finally{v(!1),S(!1)}},[]),N=()=>{S(!0),M()};a(`confirm:no`,o,{context:`Confirmation`}),s((e,t)=>{if(t.ctrl&&e===`c`){o();return}if(t.ctrl&&e===`r`&&y){N();return}if(y!==null&&t.return){o();return}});let F=(0,B.useCallback)(()=>{D(!0),M()},[D,M]);if(!E)return(0,H.jsx)(p,{onComplete:F});if(g)return(0,H.jsxs)(n,{flexDirection:`column`,padding:1,children:[(0,H.jsxs)(n,{flexDirection:`row`,children:[(0,H.jsx)(_,{}),(0,H.jsx)(r,{bold:!0,children:`Loading Claude Code sessions…`})]}),(0,H.jsx)(r,{dimColor:!0,children:x?`Retrying…`:`Fetching your Claude Code sessions…`})]});if(y)return(0,H.jsxs)(n,{flexDirection:`column`,padding:1,children:[(0,H.jsx)(r,{bold:!0,color:`error`,children:`Error loading Claude Code sessions`}),q(y),(0,H.jsxs)(r,{dimColor:!0,children:[`Press `,(0,H.jsx)(r,{bold:!0,children:`Ctrl+R`}),` to retry · Press `,(0,H.jsx)(r,{bold:!0,children:j}),` to cancel`]})]});if(d.length===0)return(0,H.jsxs)(n,{flexDirection:`column`,padding:1,children:[(0,H.jsxs)(r,{bold:!0,children:[`No Claude Code sessions found`,m&&(0,H.jsxs)(r,{children:[` for `,m]})]}),(0,H.jsx)(n,{marginTop:1,children:(0,H.jsxs)(r,{dimColor:!0,children:[`Press `,(0,H.jsx)(r,{bold:!0,children:j}),` to cancel`]})})]});let R=d.map(e=>({...e,timeString:P(new Date(e.updated_at))})),z=Math.max(7,...R.map(e=>e.timeString.length)),V=R.map(({timeString:e,title:t,id:n})=>({label:`${e.padEnd(z,` `)} ${t}`,value:n})),G=Math.max(1,l?Math.min(d.length,5,u-6-7):Math.min(d.length,u-1-7));return(0,H.jsxs)(n,{flexDirection:`column`,padding:1,height:G+7,children:[(0,H.jsxs)(r,{bold:!0,children:[`Select a session to resume`,d.length>G&&(0,H.jsxs)(r,{dimColor:!0,children:[` `,`(`,O,` of `,d.length,`)`]}),m&&(0,H.jsxs)(r,{dimColor:!0,children:[` (`,m,`)`]}),`:`]}),(0,H.jsxs)(n,{flexDirection:`column`,marginTop:1,flexGrow:1,children:[(0,H.jsx)(n,{marginLeft:2,children:(0,H.jsxs)(r,{bold:!0,children:[U.padEnd(z,` `),W,`Session Title`]})}),(0,H.jsx)(C,{visibleOptionCount:G,options:V,onChange:t=>{let n=d.find(e=>e.id===t);n&&e(n)},onFocus:e=>{let t=V.findIndex(t=>t.value===e);t>=0&&A(t+1)}})]}),(0,H.jsx)(n,{flexDirection:`row`,children:(0,H.jsx)(r,{dimColor:!0,children:(0,H.jsxs)(i,{children:[(0,H.jsx)(t,{shortcut:`↑/↓`,action:`select`}),(0,H.jsx)(t,{shortcut:`Enter`,action:`confirm`}),(0,H.jsx)(T,{action:`confirm:no`,context:`Confirmation`,fallback:`Esc`,description:`cancel`})]})})})]})}function K(e){let t=e.toLowerCase();return t.includes(`fetch`)||t.includes(`network`)||t.includes(`timeout`)?`network`:t.includes(`auth`)||t.includes(`token`)||t.includes(`permission`)||t.includes(`oauth`)||t.includes(`not authenticated`)||t.includes(`/login`)||t.includes(`console account`)||t.includes(`403`)?`auth`:t.includes(`api`)||t.includes(`rate limit`)||t.includes(`500`)||t.includes(`529`)?`api`:`other`}function q(e){switch(e){case`network`:return(0,H.jsx)(n,{marginY:1,flexDirection:`column`,children:(0,H.jsx)(r,{dimColor:!0,children:`Check your internet connection`})});case`auth`:return(0,H.jsx)(n,{marginY:1,flexDirection:`column`,children:(0,H.jsx)(r,{dimColor:!0,children:`Teleport requires a Claude account`})});case`api`:return(0,H.jsx)(n,{marginY:1,flexDirection:`column`,children:(0,H.jsx)(r,{dimColor:!0,children:`Sorry, Claude encountered an error`})});case`other`:return(0,H.jsx)(n,{marginY:1,flexDirection:`row`,children:(0,H.jsx)(r,{dimColor:!0,children:`Sorry, Claude Code encountered an error`})})}}j(),l(),z(),g();function J({onComplete:e,onCancel:t,onError:i,isEmbedded:o=!1,source:s}){let{resumeSession:c,isResuming:l,error:u,selectedSession:d}=V(s);(0,B.useEffect)(()=>{M(`tengu_teleport_started`,{source:s})},[s]);let f=async t=>{let n=await c(t);n?e(n):u&&i&&i(u.message,u.formattedMessage)},p=()=>{M(`tengu_teleport_cancelled`,{}),t()};return a(`app:interrupt`,p,{context:`Global`,isActive:!!u&&!i}),l&&d?(0,H.jsxs)(n,{flexDirection:`column`,padding:1,children:[(0,H.jsxs)(n,{flexDirection:`row`,children:[(0,H.jsx)(_,{}),(0,H.jsx)(r,{bold:!0,children:`Resuming session…`})]}),(0,H.jsxs)(r,{dimColor:!0,children:[`Loading "`,d.title,`"…`]})]}):u&&!i?(0,H.jsxs)(n,{flexDirection:`column`,padding:1,children:[(0,H.jsx)(r,{bold:!0,color:`error`,children:`Failed to resume session`}),(0,H.jsx)(r,{dimColor:!0,children:u.message}),(0,H.jsx)(n,{marginTop:1,children:(0,H.jsxs)(r,{dimColor:!0,children:[`Press `,(0,H.jsx)(r,{bold:!0,children:`Esc`}),` to cancel`]})})]}):(0,H.jsx)(G,{onSelect:f,onCancel:p,isEmbedded:o})}export{J as TeleportResumeWrapper};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{n as e}from"./rolldown-runtime-DaDcL9Zw.js";import{D as t,H as n,I as r,P as i,T as a,U as o,V as s,Wt as c,Xt as l,fi as u,ot as d,t as f}from"./src-CDCSSo0U2.js";import{t as p}from"./jsx-runtime-Bb4Xn-E0.js";import{Cx as m,Gf as h,KS as g,Kf as _,Tx as v,US as y,WS as b,Xf as x,Yf as S,Zf as C,aC as w,cC as T,fx as E,oC as D,px as O,wx as k}from"./loadAgentsDir-
|
|
1
|
+
import{n as e}from"./rolldown-runtime-DaDcL9Zw.js";import{D as t,H as n,I as r,P as i,T as a,U as o,V as s,Wt as c,Xt as l,fi as u,ot as d,t as f}from"./src-CDCSSo0U2.js";import{t as p}from"./jsx-runtime-Bb4Xn-E0.js";import{Cx as m,Gf as h,KS as g,Kf as _,Tx as v,US as y,WS as b,Xf as x,Yf as S,Zf as C,aC as w,cC as T,fx as E,oC as D,px as O,wx as k}from"./loadAgentsDir-D206qwP3.js";import{g as A,y as j}from"./settings-BovzmwMP.js";import{u as M}from"./referral-CUaIo_vT.js";import{n as N,t as P}from"./useExitOnCtrlCDWithKeybindings-DKIqRraH.js";function F({onThemeSelect:e,showIntroText:u=!1,helpText:f=``,showHelpTextBelow:p=!1,hideEscToCancel:m=!1,skipExitHandling:_=!1,onCancel:v}){let[y]=n(),C=o(),{columns:w}=d(),T=S(),E=T===null?x(y):null,{setPreviewTheme:A,savePreview:M,cancelPreview:P}=s(),F=b(e=>e.settings.syntaxHighlightingDisabled)??!1,L=g();l(`ThemePicker`);let R=k(`theme:toggleSyntaxHighlighting`,`ThemePicker`,`ctrl+t`);c(`theme:toggleSyntaxHighlighting`,()=>{if(T===null){let e=!F;j(`userSettings`,{syntaxHighlightingDisabled:e}),L(t=>({...t,settings:{...t.settings,syntaxHighlightingDisabled:e}}))}},{context:`ThemePicker`});let z=N(_?()=>{}:void 0),B=[{label:`Dark mode`,value:`dark`},{label:`Light mode`,value:`light`},{label:`Dark mode (colorblind-friendly)`,value:`dark-daltonized`},{label:`Light mode (colorblind-friendly)`,value:`light-daltonized`},{label:`Dark mode (ANSI colors only)`,value:`dark-ansi`},{label:`Light mode (ANSI colors only)`,value:`light-ansi`}],V=(0,I.jsxs)(r,{flexDirection:`column`,gap:1,children:[(0,I.jsxs)(r,{flexDirection:`column`,gap:1,children:[u?(0,I.jsx)(i,{children:`Let's get started.`}):(0,I.jsx)(i,{bold:!0,color:`permission`,children:`Theme`}),(0,I.jsxs)(r,{flexDirection:`column`,children:[(0,I.jsx)(i,{bold:!0,children:`Choose the text style that looks best with your terminal`}),f&&!p&&(0,I.jsx)(i,{dimColor:!0,children:f})]}),(0,I.jsx)(O,{options:B,onFocus:e=>{A(e)},onChange:t=>{M(),e(t)},onCancel:_?()=>{P(),v?.()}:async()=>{P(),await D(0)},visibleOptionCount:B.length,defaultValue:C,defaultFocusValue:C})]}),(0,I.jsxs)(r,{flexDirection:`column`,width:`100%`,children:[(0,I.jsx)(r,{flexDirection:`column`,borderTop:!0,borderBottom:!0,borderLeft:!1,borderRight:!1,borderStyle:`dashed`,borderColor:`subtle`,children:(0,I.jsx)(h,{patch:{oldStart:1,newStart:1,oldLines:3,newLines:3,lines:[` function greet() {`,`- console.log("Hello, World!");`,`+ console.log("Hello, Claude!");`,` }`]},dim:!1,filePath:`demo.js`,firstLine:null,width:w})}),(0,I.jsxs)(i,{dimColor:!0,children:[` `,T===`env`?`Syntax highlighting disabled (via CLAUDE_CODE_SYNTAX_HIGHLIGHT=${process.env.CLAUDE_CODE_SYNTAX_HIGHLIGHT})`:F?`Syntax highlighting disabled (${R} to enable)`:E?`Syntax theme: ${E.theme}${E.source?` (from ${E.source})`:``} (${R} to disable)`:`Syntax highlighting enabled (${R} to disable)`]})]})]});return u?V:(0,I.jsxs)(I.Fragment,{children:[(0,I.jsx)(r,{flexDirection:`column`,children:V}),(0,I.jsxs)(r,{marginTop:1,children:[p&&f&&(0,I.jsx)(r,{marginLeft:3,children:(0,I.jsx)(i,{dimColor:!0,children:f})}),!m&&(0,I.jsx)(r,{children:(0,I.jsx)(i,{dimColor:!0,italic:!0,children:z.pending?(0,I.jsxs)(I.Fragment,{children:[`Press `,z.keyName,` again to exit`]}):(0,I.jsxs)(a,{children:[(0,I.jsx)(t,{shortcut:`Enter`,action:`select`}),(0,I.jsx)(t,{shortcut:`Esc`,action:`cancel`})]})})})]})]})}var I,L=e((()=>{u(),P(),w(),f(),v(),M(),m(),y(),T(),A(),E(),C(),_(),I=p()}));export{L as n,F as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{o as e}from"./rolldown-runtime-DaDcL9Zw.js";import{I as t,P as n,Wt as r,fi as i,t as a}from"./src-CDCSSo0U2.js";import{t as o}from"./jsx-runtime-Bb4Xn-E0.js";import{en as s,ur as c}from"./state-ix0xIunV.js";import{Aw as l,V_ as u,ba as d,cC as f,fx as p,jw as m,px as h,sC as g,xa as _,z_ as v}from"./loadAgentsDir-
|
|
1
|
+
import{o as e}from"./rolldown-runtime-DaDcL9Zw.js";import{I as t,P as n,Wt as r,fi as i,t as a}from"./src-CDCSSo0U2.js";import{t as o}from"./jsx-runtime-Bb4Xn-E0.js";import{en as s,ur as c}from"./state-ix0xIunV.js";import{Aw as l,V_ as u,ba as d,cC as f,fx as p,jw as m,px as h,sC as g,xa as _,z_ as v}from"./loadAgentsDir-D206qwP3.js";import{n as y,t as b}from"./cwd-CYmmnQVS.js";import{d as x,p as S}from"./debug-BrXObCdR.js";import{c as C,g as w}from"./settings-BovzmwMP.js";import{g as T,n as E,y as D}from"./config-DmomySWC.js";import{n as O,r as k}from"./analytics-BotDBGh0.js";import{bn as A}from"./prompt-BNHtszmZ.js";import{u as j}from"./referral-CUaIo_vT.js";import{n as M,t as N}from"./useExitOnCtrlCDWithKeybindings-DKIqRraH.js";import{n as P,t as F}from"./PermissionDialog-0ya1CU5k.js";import{homedir as I}from"os";var L=e(i(),1),R=o();a(),s(),y(),S(),O(),T(),f(),j(),p(),u(),N(),P(),w(),A(),_(),m();function z(e){if(e===null||e.disableAllHooks)return!1;if(e.statusLine||e.fileSuggestion)return!0;if(!e.hooks)return!1;for(let t of Object.values(e.hooks))if(t.length>0)return!0;return!1}function B(){let e=[];return z(C(`projectSettings`))&&e.push(`.claude/settings.json`),z(C(`localSettings`))&&e.push(`.claude/settings.local.json`),e}function V(e){return e.some(e=>e.ruleBehavior===`allow`&&(e.ruleValue.toolName===`Bash`||e.ruleValue.toolName.startsWith(`Bash(`)))}function H(){let e=[];return V(l(`projectSettings`))&&e.push(`.claude/settings.json`),V(l(`localSettings`))&&e.push(`.claude/settings.local.json`),e}function U(e){return!!e?.otelHeadersHelper}function W(){let e=[];return U(C(`projectSettings`))&&e.push(`.claude/settings.json`),U(C(`localSettings`))&&e.push(`.claude/settings.local.json`),e}function G(e){return!!e?.apiKeyHelper}function K(){let e=[];return G(C(`projectSettings`))&&e.push(`.claude/settings.json`),G(C(`localSettings`))&&e.push(`.claude/settings.local.json`),e}function q(e){return!!(e?.awsAuthRefresh||e?.awsCredentialExport)}function J(){let e=[];return q(C(`projectSettings`))&&e.push(`.claude/settings.json`),q(C(`localSettings`))&&e.push(`.claude/settings.local.json`),e}function Y(e){return!!e?.gcpAuthRefresh}function X(){let e=[];return Y(C(`projectSettings`))&&e.push(`.claude/settings.json`),Y(C(`localSettings`))&&e.push(`.claude/settings.local.json`),e}function Z(e){return e?.env?Object.keys(e.env).some(e=>!d.has(e.toUpperCase())):!1}function Q(){let e=[];return Z(C(`projectSettings`))&&e.push(`.claude/settings.json`),Z(C(`localSettings`))&&e.push(`.claude/settings.local.json`),e}A();function $({onDone:e,commands:i}){let{servers:a}=v(`project`),o=Object.keys(a).length>0,s=B().length>0,l=H(),u=K().length>0,d=J().length>0,f=X().length>0,p=W().length>0,m=Q().length>0,_=i?.some(e=>e.type===`prompt`&&e.loadedFrom===`commands_DEPRECATED`&&(e.source===`projectSettings`||e.source===`localSettings`)&&e.allowedTools?.some(e=>e===`Bash`||e.startsWith(`Bash(`)))??!1,y=i?.some(e=>e.type===`prompt`&&(e.loadedFrom===`skills`||e.loadedFrom===`plugin`)&&(e.source===`projectSettings`||e.source===`localSettings`||e.source===`plugin`)&&e.allowedTools?.some(e=>e===`Bash`||e.startsWith(`Bash(`)))??!1,S=l.length>0||_||y,C=E(),[w,T]=L.useState(null);L.useEffect(()=>{if(w!==null){let e=w,t=setTimeout(()=>g(e));return()=>clearTimeout(t)}},[w]),L.useEffect(()=>{k(`tengu_trust_dialog_shown`,{isHomeDir:I()===b(),hasMcpServers:o,hasHooks:s,hasBashExecution:S,hasApiKeyHelper:u,hasAwsCommands:d,hasGcpCommands:f,hasOtelHeadersHelper:p,hasDangerousEnvVars:m})},[o,s,S,u,d,f,p,m]);function O(t){if(t===`exit`){T(1);return}let n=I()===b();k(`tengu_trust_dialog_accept`,{isHomeDir:n,hasMcpServers:o,hasHooks:s,hasBashExecution:S,hasApiKeyHelper:u,hasAwsCommands:d,hasGcpCommands:f,hasOtelHeadersHelper:p,hasDangerousEnvVars:m}),n?c(!0):D(e=>({...e,hasTrustDialogAccepted:!0})),e()}let A=M(()=>T(1));return r(`confirm:no`,()=>{T(0)},{context:`Confirmation`}),w===null?C?(setTimeout(e),null):(0,R.jsx)(F,{color:`warning`,titleColor:`warning`,title:`Accessing workspace:`,children:(0,R.jsxs)(t,{flexDirection:`column`,gap:1,paddingTop:1,children:[(0,R.jsx)(n,{bold:!0,children:x().cwd()}),(0,R.jsx)(n,{children:`Is this a project you trust? (Your own code, a well-known open source project, or work from your team).`}),(0,R.jsx)(n,{children:`Once trusted, Work Mate can read, edit, and run commands in this folder.`}),(0,R.jsx)(h,{options:[{label:`Yes, I trust this folder`,value:`enable_all`},{label:`No, exit`,value:`exit`}],onChange:e=>O(e),onCancel:()=>O(`exit`)}),(0,R.jsx)(n,{dimColor:!0,children:A.pending?(0,R.jsxs)(R.Fragment,{children:[`Press `,A.keyName,` again to exit`]}):(0,R.jsx)(R.Fragment,{children:`Enter to confirm · Esc to cancel`})})]})}):null}export{$ as TrustDialog};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{n as e}from"./rolldown-runtime-DaDcL9Zw.js";import{n as t,t as n}from"./figures-5ThXQEtq.js";import{H as r,I as i,P as a,fi as o,j as s,t as c}from"./src-CDCSSo0U2.js";import{t as l}from"./jsx-runtime-Bb4Xn-E0.js";import{O as u,k as d}from"./config-
|
|
1
|
+
import{n as e}from"./rolldown-runtime-DaDcL9Zw.js";import{n as t,t as n}from"./figures-5ThXQEtq.js";import{H as r,I as i,P as a,fi as o,j as s,t as c}from"./src-CDCSSo0U2.js";import{t as l}from"./jsx-runtime-Bb4Xn-E0.js";import{O as u,k as d}from"./config-DmomySWC.js";function f(e,t,n,r){return r=typeof r==`function`?r:void 0,e==null?e:u(e,t,n,r)}var p=e((()=>{d()}));function m(e,t={}){let{showValues:n=!0,hideFunctions:r=!1,themeName:i=`dark`,treeCharColors:a={}}=t,o=[],c=new WeakSet;function l(e,t){return t?s(t,i)(e):e}function u(e,t,i,s=0){if(typeof e==`string`){o.push(t+l(e,a.value));return}if(typeof e!=`object`||!e){if(n){let n=String(e);o.push(t+l(n,a.value))}return}if(c.has(e)){o.push(t+l(`[Circular]`,a.value));return}c.add(e);let d=Object.keys(e).filter(t=>{let n=e[t];return!(r&&typeof n==`function`)});d.forEach((r,i)=>{let f=e[r],p=i===d.length-1,m=s===0&&i===0?``:t,g=l(p?h.lastBranch:h.branch,a.treeChar),_=r.trim()===``?``:l(r,a.key),v=m+g+(_?` `+_:``),y=r.trim()!==``;if(f&&typeof f==`object`&&c.has(f)){let e=l(`[Circular]`,a.value);o.push(v+(y?`: `:v?` `:``)+e)}else if(f&&typeof f==`object`&&!Array.isArray(f))o.push(v),u(f,m+l(p?h.empty:h.line,a.treeChar)+` `,p,s+1);else if(Array.isArray(f))o.push(v+(y?`: `:v?` `:``)+`[Array(`+f.length+`)]`);else if(n){let e=l(typeof f==`function`?`[Function]`:String(f),a.value);v+=(y?`: `:v?` `:``)+e,o.push(v)}else o.push(v)})}let d=Object.keys(e);if(d.length===0)return l(`(empty)`,a.value);if(d.length===1&&d[0]!==void 0&&d[0].trim()===``&&typeof e[d[0]]==`string`){let t=d[0],n=l(h.lastBranch,a.treeChar),r=l(e[t],a.value);return n+` `+r}return u(e,``,!0),o.join(`
|
|
2
2
|
`)}var h,g=e((()=>{t(),c(),h={branch:n.lineUpDownRight,lastBranch:n.lineUpRight,line:n.lineVertical,empty:` `}}));function _(e){let t={};return e.forEach(e=>{if(!e.path){t[``]=e.message;return}let n=e.path.split(`.`),r=e.path;if(e.invalidValue!==null&&e.invalidValue!==void 0&&n.length>0){let t=[];for(let r=0;r<n.length;r++){let i=n[r];if(i)if(!isNaN(parseInt(i,10))&&r===n.length-1){let n;n=typeof e.invalidValue==`string`?`"${e.invalidValue}"`:e.invalidValue===null?`null`:e.invalidValue===void 0?`undefined`:String(e.invalidValue),t.push(n)}else t.push(i)}r=t.join(`.`)}f(t,r,e.message,Object)}),t}function v({errors:e}){let[t]=r();if(e.length===0)return null;let n=e.reduce((e,t)=>{let n=t.file||`(file not specified)`;return e[n]||(e[n]=[]),e[n].push(t),e},{});return(0,y.jsx)(i,{flexDirection:`column`,children:Object.keys(n).sort().map(e=>{let r=n[e]||[];r.sort((e,t)=>!e.path&&t.path?-1:e.path&&!t.path?1:(e.path||``).localeCompare(t.path||``));let o=_(r),s=new Map;r.forEach(e=>{if(e.suggestion||e.docLink){let t=`${e.suggestion||``}|${e.docLink||``}`;s.has(t)||s.set(t,{suggestion:e.suggestion,docLink:e.docLink})}});let c=m(o,{showValues:!0,themeName:t,treeCharColors:{treeChar:`inactive`,key:`text`,value:`inactive`}});return(0,y.jsxs)(i,{flexDirection:`column`,children:[(0,y.jsx)(a,{children:e}),(0,y.jsx)(i,{marginLeft:1,children:(0,y.jsx)(a,{dimColor:!0,children:c})}),s.size>0&&(0,y.jsx)(i,{flexDirection:`column`,marginTop:1,children:Array.from(s.values()).map((e,t)=>(0,y.jsxs)(i,{flexDirection:`column`,marginBottom:1,children:[e.suggestion&&(0,y.jsx)(a,{dimColor:!0,wrap:`wrap`,children:e.suggestion}),e.docLink&&(0,y.jsxs)(a,{dimColor:!0,wrap:`wrap`,children:[`Learn more: `,e.docLink]})]},`suggestion-pair-${t}`))})]},e)})})}var y,b=e((()=>{p(),o(),c(),g(),y=l()}));export{b as n,v as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import"./rolldown-runtime-DaDcL9Zw.js";import{H as e,I as t,P as n,fi as r,t as i}from"./src-CDCSSo0U2.js";import{t as a}from"./jsx-runtime-Bb4Xn-E0.js";import{Jt as o,Zt as s}from"./settings-
|
|
1
|
+
import"./rolldown-runtime-DaDcL9Zw.js";import{H as e,I as t,P as n,fi as r,t as i}from"./src-CDCSSo0U2.js";import{t as a}from"./jsx-runtime-Bb4Xn-E0.js";import{Jt as o,Zt as s}from"./settings-BovzmwMP.js";r(),i(),s();var c=a(),l=58;function u(){let[r]=e(),i=`Welcome to Work Mate`;return o.terminal===`Apple_Terminal`?(0,c.jsx)(d,{theme:r,welcomeMessage:i}):[`light`,`light-daltonized`,`light-ansi`].includes(r)?(0,c.jsxs)(t,{width:l,flexDirection:`column`,children:[(0,c.jsxs)(n,{children:[(0,c.jsxs)(n,{color:`claudeBlue_FOR_SYSTEM_SPINNER`,children:[i,` `]}),(0,c.jsxs)(n,{dimColor:!0,children:[`v`,`0.0.6`,` `]})]}),(0,c.jsx)(n,{children:`…………………………………………………………………………………………………………………………………………………………`}),(0,c.jsx)(n,{children:` ░░░░░░ `}),(0,c.jsx)(n,{children:` ░░░ ░░░░░░░░░░ `}),(0,c.jsx)(n,{children:` ░░░░░░░░░░░░░░░░░░░ `}),(0,c.jsx)(n,{children:` `})]}):(0,c.jsxs)(t,{width:l,flexDirection:`column`,children:[(0,c.jsxs)(n,{children:[(0,c.jsxs)(n,{color:`claudeBlue_FOR_SYSTEM_SPINNER`,children:[i,` `]}),(0,c.jsxs)(n,{dimColor:!0,children:[`v`,`0.0.6`,` `]})]}),(0,c.jsx)(n,{children:`…………………………………………………………………………………………………………………………………………………………`}),(0,c.jsx)(n,{children:` * █████▓▓░ `}),(0,c.jsx)(n,{children:` * ███▓░ ░░ `}),(0,c.jsx)(n,{children:` ░░░░░░ ███▓░ `}),(0,c.jsx)(n,{children:` ░░░ ░░░░░░░░░░ ███▓░ `}),(0,c.jsxs)(n,{children:[(0,c.jsx)(n,{children:` ░░░░░░░░░░░░░░░░░░░ `}),(0,c.jsx)(n,{bold:!0,children:`*`}),(0,c.jsx)(n,{children:` ██▓░░ ▓ `})]}),(0,c.jsx)(n,{children:` ░▓▓███▓▓░ `}),(0,c.jsx)(n,{dimColor:!0,children:` * ░░░░ `}),(0,c.jsx)(n,{dimColor:!0,children:` ░░░░░░░░ `}),(0,c.jsx)(n,{dimColor:!0,children:` * ░░░░░░░░░░░░░░░░ `}),(0,c.jsx)(n,{dimColor:!0,children:` * `})]})}function d({theme:e,welcomeMessage:r}){return[`light`,`light-daltonized`,`light-ansi`].includes(e)?(0,c.jsxs)(t,{width:l,flexDirection:`column`,children:[(0,c.jsxs)(n,{children:[(0,c.jsxs)(n,{color:`claudeBlue_FOR_SYSTEM_SPINNER`,children:[r,` `]}),(0,c.jsxs)(n,{dimColor:!0,children:[`v`,`0.0.6`,` `]})]}),(0,c.jsx)(n,{children:`…………………………………………………………………………………………………………………………………………………………`}),(0,c.jsx)(n,{children:` ░░░░░░ `}),(0,c.jsx)(n,{children:` ░░░ ░░░░░░░░░░ `}),(0,c.jsx)(n,{children:` ░░░░░░░░░░░░░░░░░░░ `}),(0,c.jsx)(n,{children:` `})]}):(0,c.jsxs)(t,{width:l,flexDirection:`column`,children:[(0,c.jsxs)(n,{children:[(0,c.jsxs)(n,{color:`claudeBlue_FOR_SYSTEM_SPINNER`,children:[r,` `]}),(0,c.jsxs)(n,{dimColor:!0,children:[`v`,`0.0.6`,` `]})]}),(0,c.jsx)(n,{children:`…………………………………………………………………………………………………………………………………………………………`}),(0,c.jsx)(n,{children:` * █████▓▓░ `}),(0,c.jsx)(n,{children:` * ███▓░ ░░ `}),(0,c.jsx)(n,{children:` ░░░░░░ ███▓░ `}),(0,c.jsx)(n,{children:` ░░░ ░░░░░░░░░░ ███▓░ `}),(0,c.jsxs)(n,{children:[(0,c.jsx)(n,{children:` ░░░░░░░░░░░░░░░░░░░ `}),(0,c.jsx)(n,{bold:!0,children:`*`}),(0,c.jsx)(n,{children:` ██▓░░ ▓ `})]}),(0,c.jsx)(n,{children:` ░▓▓███▓▓░ `}),(0,c.jsx)(n,{dimColor:!0,children:` * ░░░░ `}),(0,c.jsx)(n,{dimColor:!0,children:` ░░░░░░░░ `}),(0,c.jsx)(n,{dimColor:!0,children:` ░░░░░░░░░░░░░░░░ `})]})}export{u as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{n as e,o as t}from"./rolldown-runtime-DaDcL9Zw.js";import{n,t as r}from"./figures-5ThXQEtq.js";import{I as i,P as a,di as o,fi as s,t as c,ui as l}from"./src-CDCSSo0U2.js";import{t as u}from"./jsx-runtime-Bb4Xn-E0.js";import{en as d,h as f,mn as p}from"./state-ix0xIunV.js";import{$b as m,Dw as h,Ew as g,L as _,Qb as v,R as y,SD as b,Sw as x,yD as S,z as C}from"./loadAgentsDir-
|
|
1
|
+
import{n as e,o as t}from"./rolldown-runtime-DaDcL9Zw.js";import{n,t as r}from"./figures-5ThXQEtq.js";import{I as i,P as a,di as o,fi as s,t as c,ui as l}from"./src-CDCSSo0U2.js";import{t as u}from"./jsx-runtime-Bb4Xn-E0.js";import{en as d,h as f,mn as p}from"./state-ix0xIunV.js";import{$b as m,Dw as h,Ew as g,L as _,Qb as v,R as y,SD as b,Sw as x,yD as S,z as C}from"./loadAgentsDir-D206qwP3.js";import{n as w,t as T}from"./AddWorkspaceDirectory-ClHi-Dr6.js";function E({message:e,args:t,onDone:n}){return(0,O.useEffect)(()=>{let e=setTimeout(n,0);return()=>clearTimeout(e)},[n]),(0,k.jsxs)(i,{flexDirection:`column`,children:[(0,k.jsxs)(a,{dimColor:!0,children:[r.pointer,` /add-dir `,t]}),(0,k.jsx)(v,{children:(0,k.jsx)(a,{children:e})})]})}async function D(e,t,n){let r=(n??``).trim(),i=t.getAppState(),a=async(n,r=!1)=>{let i={type:`addDirectories`,directories:[n],destination:r?`localSettings`:`session`},a=x(t.getAppState().toolPermissionContext,i);t.setAppState(e=>({...e,toolPermissionContext:a}));let o=f();o.includes(n)||p([...o,n]),S.refreshConfig();let s;if(r)try{h(i),s=`Added ${l.bold(n)} as a working directory and saved to local settings`}catch(e){s=`Added ${l.bold(n)} as a working directory. Failed to save to local settings: ${e instanceof Error?e.message:`Unknown error`}`}else s=`Added ${l.bold(n)} as a working directory for this session`;e(`${s} ${l.dim(`· /permissions to manage`)}`)};if(!r)return(0,k.jsx)(T,{permissionContext:i.toolPermissionContext,onAddDirectory:a,onCancel:()=>{e(`Did not add a working directory.`)}});let o=await C(r,i.toolPermissionContext);if(o.resultType!==`success`){let t=_(o);return(0,k.jsx)(E,{message:t,args:n??``,onDone:()=>e(t)})}return(0,k.jsx)(T,{directoryPath:o.absolutePath,permissionContext:i.toolPermissionContext,onAddDirectory:a,onCancel:()=>{e(`Did not add ${l.bold(o.absolutePath)} as a working directory.`)}})}var O,k;e((()=>{o(),n(),O=t(s(),1),d(),m(),w(),c(),g(),b(),y(),k=u()}))();export{D as call};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{n as e}from"./rolldown-runtime-DaDcL9Zw.js";import{Hh as t,Uh as n}from"./loadAgentsDir-
|
|
1
|
+
import{n as e}from"./rolldown-runtime-DaDcL9Zw.js";import{Hh as t,Uh as n}from"./loadAgentsDir-D206qwP3.js";import{dn as r,un as i}from"./settings-BovzmwMP.js";function a(e,t){let n=new Map;for(let e of t)n.set(e.agentType,e);let r=new Set,i=[];for(let t of e){let e=`${t.agentType}:${t.source}`;if(r.has(e))continue;r.add(e);let a=n.get(t.agentType),o=a&&a.source!==t.source?a.source:void 0;i.push({...t,overriddenBy:o})}return i}function o(e){let n=e.model||t();if(n)return n===`inherit`?`inherit`:n}function s(e){return i(e).toLowerCase()}function c(e,t){return e.agentType.localeCompare(t.agentType,void 0,{sensitivity:`base`})}var l,u=e((()=>{n(),r(),l=[{label:`User agents`,source:`userSettings`},{label:`Project agents`,source:`projectSettings`},{label:`Local agents`,source:`localSettings`},{label:`Managed agents`,source:`policySettings`},{label:`Plugin agents`,source:`plugin`},{label:`CLI arg agents`,source:`flagSettings`},{label:`Built-in agents`,source:`built-in`}]}));export{o as a,u as i,c as n,a as o,s as r,l as t};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{n as e,o as t}from"./rolldown-runtime-DaDcL9Zw.js";import{n,o as r}from"./envUtils-DSxRz_kt.js";import{n as i,t as a}from"./figures-5ThXQEtq.js";import{C as o,D as s,I as c,P as l,T as u,Wt as d,di as f,fi as p,t as m,ui as h,y as g}from"./src-CDCSSo0U2.js";import{t as _}from"./jsx-runtime-Bb4Xn-E0.js";import{$d as v,Af as y,Ah as b,Bc as x,Bg as S,Bh as ee,Cf as C,Ef as te,Fb as ne,Fx as re,Gw as ie,Hd as ae,Hn as oe,Jo as se,KS as ce,Kd as le,ME as ue,Mf as de,NE as fe,Nb as pe,Nf as me,O_ as he,Oh as ge,Px as _e,Qd as ve,So as ye,Sx as w,Tf as be,UD as xe,US as Se,Ud as Ce,Uh as we,Un as Te,Vc as Ee,Vg as De,Vh as Oe,WD as ke,WS as Ae,Wn as je,Ww as Me,Xd as Ne,Xu as Pe,Yu as Fe,ZT as Ie,Zd as Le,_C as Re,_u as ze,at as Be,bf as Ve,c as He,dv as Ue,ef as We,et as Ge,gC as Ke,jf as qe,k_ as Je,kh as Ye,l as Xe,lh as Ze,mx as Qe,nt as $e,o as et,of as tt,px as nt,qd as rt,r as it,s as at,sf as ot,sh as st,st as ct,t as lt,uv as ut,vu as dt,wf as ft,xx as T,yf as pt,zo as mt}from"./loadAgentsDir-
|
|
1
|
+
import{n as e,o as t}from"./rolldown-runtime-DaDcL9Zw.js";import{n,o as r}from"./envUtils-DSxRz_kt.js";import{n as i,t as a}from"./figures-5ThXQEtq.js";import{C as o,D as s,I as c,P as l,T as u,Wt as d,di as f,fi as p,t as m,ui as h,y as g}from"./src-CDCSSo0U2.js";import{t as _}from"./jsx-runtime-Bb4Xn-E0.js";import{$d as v,Af as y,Ah as b,Bc as x,Bg as S,Bh as ee,Cf as C,Ef as te,Fb as ne,Fx as re,Gw as ie,Hd as ae,Hn as oe,Jo as se,KS as ce,Kd as le,ME as ue,Mf as de,NE as fe,Nb as pe,Nf as me,O_ as he,Oh as ge,Px as _e,Qd as ve,So as ye,Sx as w,Tf as be,UD as xe,US as Se,Ud as Ce,Uh as we,Un as Te,Vc as Ee,Vg as De,Vh as Oe,WD as ke,WS as Ae,Wn as je,Ww as Me,Xd as Ne,Xu as Pe,Yu as Fe,ZT as Ie,Zd as Le,_C as Re,_u as ze,at as Be,bf as Ve,c as He,dv as Ue,ef as We,et as Ge,gC as Ke,jf as qe,k_ as Je,kh as Ye,l as Xe,lh as Ze,mx as Qe,nt as $e,o as et,of as tt,px as nt,qd as rt,r as it,s as at,sf as ot,sh as st,st as ct,t as lt,uv as ut,vu as dt,wf as ft,xx as T,yf as pt,zo as mt}from"./loadAgentsDir-D206qwP3.js";import{n as ht,t as gt}from"./cwd-CYmmnQVS.js";import{C as _t,G as vt,I as yt,Q as bt,S as xt,W as St,z as Ct}from"./debug-BrXObCdR.js";import{Q as wt,Qt as Tt,_n as Et,ct as Dt,dn as Ot,en as kt,gn as At,ln as jt,lt as Mt,nt as Nt}from"./settings-BovzmwMP.js";import{I as Pt,P as Ft}from"./config-DmomySWC.js";import{o as It,s as Lt}from"./log-BMCygSzM.js";import{n as Rt,r as zt}from"./analytics-BotDBGh0.js";import{T as Bt,b as Vt}from"./startupProfiler-xa3NmN7Z.js";import{l as Ht,n as Ut,o as Wt}from"./stringUtils-DGLPkqJ4.js";import{Tn as Gt,wn as Kt}from"./prompt-BNHtszmZ.js";import{st as qt}from"./rcDebugLog-CUy1_F23.js";import{u as E}from"./referral-CUaIo_vT.js";import{r as Jt,t as Yt}from"./TungstenTool-CxMQVCuF.js";import{a as Xt,i as Zt,n as Qt,o as $t,r as en,t as tn}from"./agentDisplay-XoDJhr03.js";import{n as nn,t as rn}from"./useExitOnCtrlCDWithKeybindings-DKIqRraH.js";import{n as an,t as on}from"./useMergedTools-CKvwz_Zt.js";import{n as sn,r as cn,t as ln}from"./promptEditor-DeMrXUir.js";import{n as un,t as dn}from"./useMainLoopModel-XetDUXd-.js";import{join as D}from"path";import{mkdir as fn,open as pn,unlink as mn}from"fs/promises";var O,hn=e((()=>{O={FOLDER_NAME:`.claude`,AGENTS_DIR:`agents`}}));function gn(e,t,n,r,i,a,o){return`---
|
|
2
2
|
name: ${e}
|
|
3
3
|
description: "${t.replace(/\\/g,`\\\\`).replace(/"/g,`\\"`).replace(/\n/g,`\\\\n`)}"${n===void 0||n.length===1&&n[0]===`*`?``:`\ntools: ${n.join(`, `)}`}${a?`\nmodel: ${a}`:``}${i?`\ncolor: ${i}`:``}${o?`\nmemory: ${o}`:``}
|
|
4
4
|
---
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{i as e,o as t,r as n}from"./loadAgentsDir-
|
|
1
|
+
import{i as e,o as t,r as n}from"./loadAgentsDir-D206qwP3.js";import{n as r,t as i}from"./cwd-CYmmnQVS.js";import{a,i as o,n as s,o as c,r as l,t as u}from"./agentDisplay-XoDJhr03.js";o(),t(),r();function d(e){let t=a(e),n=[e.agentType];return t&&n.push(t),e.memory&&n.push(`${e.memory} memory`),n.join(` · `)}async function f(){let{allAgents:t}=await e(i()),r=c(t,n(t)),a=[],o=0;for(let{label:e,source:t}of u){let n=r.filter(e=>e.source===t).sort(s);if(n.length!==0){a.push(`${e}:`);for(let e of n)if(e.overriddenBy){let t=l(e.overriddenBy);a.push(` (shadowed by ${t}) ${d(e)}`)}else a.push(` ${d(e)}`),o++;a.push(``)}}a.length===0?console.log(`No agents found.`):(console.log(`${o} active agents\n`),console.log(a.join(`
|
|
2
2
|
`).trimEnd()))}export{f as agentsHandler};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{n as e}from"./rolldown-runtime-DaDcL9Zw.js";import{V_ as t,z_ as n}from"./loadAgentsDir-
|
|
1
|
+
import{n as e}from"./rolldown-runtime-DaDcL9Zw.js";import{V_ as t,z_ as n}from"./loadAgentsDir-D206qwP3.js";import{g as r,u as i}from"./settings-BovzmwMP.js";function a(){let e=i(),t=[`user`,`project`,`local`].flatMap(e=>n(e).errors);return{settings:e.settings,errors:[...e.errors,...t]}}var o=e((()=>{t(),r()}));export{o as n,a as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{AC as e,CC as t,DC as n,MC as r,OC as i,TC as a}from"./loadAgentsDir-
|
|
1
|
+
import{AC as e,CC as t,DC as n,MC as r,OC as i,TC as a}from"./loadAgentsDir-D206qwP3.js";import{s as o,u as s}from"./logoV2Utils-8M56V7oN.js";i(),s();var c=`default`;async function l(e,n){let r=await t(n.list||c,{subject:e,description:n.description||``,status:`pending`,blocks:[],blockedBy:[]});console.log(`Created task ${r}: ${e}`)}async function u(t){let n=await e(t.list||c);if(t.pending&&(n=n.filter(e=>e.status===`pending`)),t.json){console.log(JSON.stringify(n,null,2));return}if(n.length===0){console.log(`No tasks found.`);return}for(let e of n)console.log(` [${e.status}] ${e.id}: ${e.subject}`),e.description&&console.log(` ${e.description}`),e.owner&&console.log(` owner: ${e.owner}`)}async function d(e,t){let n=await a(t.list||c,e);if(!n){console.error(`Task not found: ${e}`),process.exitCode=1;return}console.log(JSON.stringify(n,null,2))}async function f(e,t){let n=t.list||c,i={};t.status&&(i.status=t.status),t.subject&&(i.subject=t.subject),t.description&&(i.description=t.description),t.owner&&(i.owner=t.owner),t.clearOwner&&(i.owner=void 0);let a=await r(n,e,i);if(!a){console.error(`Task not found: ${e}`),process.exitCode=1;return}console.log(`Updated task ${e}: [${a.status}] ${a.subject}`)}async function p(e){let t=e.list||c;console.log(n(t))}async function m(e){let t=await o();if(e===void 0){if(t.length===0){console.log(`No recent sessions.`);return}for(let e=0;e<Math.min(t.length,20);e++){let n=t[e],r=n.modified?new Date(n.modified).toLocaleString():`unknown`,i=n.title||n.sessionId||`untitled`;console.log(` ${e}: ${i} (${r})`)}return}let n=typeof e==`string`?parseInt(e,10):e,r=Number.isFinite(n)&&n>=0&&n<t.length?t[n]:t.find(t=>t.sessionId===String(e));if(!r){console.error(`Session not found: ${e}`),process.exitCode=1;return}console.log(JSON.stringify(r,null,2))}async function h(e){let t=await o(),n=e??5;console.log(`Last ${n} sessions:`);for(let e=0;e<Math.min(n,t.length);e++){let n=t[e],r=n.modified?new Date(n.modified).toLocaleString():`unknown`;console.log(` ${e}: ${n.sessionId} (${r})`)}}async function g(e,t,n){let{regenerateCompletionCache:r}=await import(`./completionCache-c4aiyZ_f.js`);t.output,await r(),console.log(`Completion cache regenerated for ${e}.`)}export{g as completionHandler,h as errorHandler,m as logHandler,l as taskCreateHandler,p as taskDirHandler,d as taskGetHandler,u as taskListHandler,f as taskUpdateHandler};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as e,n as t,o as n}from"./api-gqTA-D7n.js";n();export{t as fetchCodeSessionsFromSessionsAPI,e as getOAuthHeaders};
|