nolo-cli 0.14.0 → 0.16.0-alpha.1
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/{_executeModel-TURRLTZ2.js → _executeModel-QAUS6B7J.js} +24 -24
- package/{action-N3KXFO5V.js → action-GUOZYYGN.js} +4 -4
- package/{addContentAction-4Z762DMR.js → addContentAction-QDGHGUBH.js} +3 -3
- package/{addDialogAgentAction-FALLEKPR.js → addDialogAgentAction-Z4YCYZIV.js} +2 -2
- package/{agentDeleteCommand-AZDVM4HQ.js → agentDeleteCommand-365DMKHW.js} +20 -20
- package/{agentEmailCommands-M4AHOEZ3.js → agentEmailCommands-TQMXL36I.js} +38 -38
- package/{agentGrantCommands-B4MB23VQ.js → agentGrantCommands-JNDE4RWR.js} +2 -2
- package/{agentListCommands-OJLOXSKL.js → agentListCommands-6B5X4RC6.js} +22 -22
- package/{agentMachineCommands-NPMM4Z53.js → agentMachineCommands-LOEARB6V.js} +20 -20
- package/{agentPullCommand-KRBRIFIY.js → agentPullCommand-6HWUT3SW.js} +2 -2
- package/{agentRecordCommands-RVUH7XLZ.js → agentRecordCommands-DCH2WBL2.js} +33 -33
- package/{agentRunCommand-F6W2WKKZ.js → agentRunCommand-SGMH67WT.js} +35 -35
- package/{agentRunControl-IX4F5W2C.js → agentRunControl-6ADXVYMR.js} +2 -2
- package/{agentRuntimeLocal-DSUBT77I.js → agentRuntimeLocal-YSYZ33ER.js} +11 -11
- package/{agentSlice-PCEL26Z7.js → agentSlice-IVE735EV.js} +3 -3
- package/appDeleteCommands-6QYOO3JB.js +124 -0
- package/appDeployCommands-WTCT6XO6.js +163 -0
- package/appDeployStatusCommands-CGWGZJKB.js +144 -0
- package/appGetCommands-O4OCAMRW.js +119 -0
- package/appListCommands-UENFP4XY.js +122 -0
- package/{authCommand-66ME4KZX.js → authCommand-YFTR3347.js} +5 -5
- package/{authCommands-GH5T6RYV.js → authCommands-YXGOXNBZ.js} +3 -3
- package/{chunk-3B2LFO6R.js → browser-image-compression-MFDTD7K6.js} +4 -518
- package/{chunk-5R73BS7Y.js → chunk-4NLUNENX.js} +5 -5
- package/chunk-4QQFLN5C.js +552 -0
- package/{chunk-LNSRTNH7.js → chunk-6565R2TI.js} +20 -16
- package/{chunk-VQFY3VXW.js → chunk-6MHDWKOT.js} +3 -2
- package/{chunk-5NBHQD4D.js → chunk-A7GB5UGH.js} +1 -1
- package/{chunk-MYE5X27Y.js → chunk-BFRVXJJJ.js} +43 -16
- package/{chunk-XIDYAII4.js → chunk-E237VE6U.js} +7 -140
- package/{chunk-IYGQF62W.js → chunk-EMXI3N3Z.js} +3 -3
- package/{chunk-PYAJ6ZSK.js → chunk-G2MKOQCB.js} +1 -1
- package/chunk-GFUIQ4RY.js +136 -0
- package/{chunk-RZALKBP4.js → chunk-GRTFNYLR.js} +2 -2
- package/{chunk-KTFJUPDW.js → chunk-HRQCKQA5.js} +31 -31
- package/chunk-I66RU7P7.js +107 -0
- package/{chunk-OIMX7MM4.js → chunk-ISYE6GZB.js} +1 -1
- package/{chunk-4UUJFFMK.js → chunk-J55UHASN.js} +1 -1
- package/{chunk-V6VXDXGY.js → chunk-JS33TCQ3.js} +2 -2
- package/{chunk-7JJCGV7N.js → chunk-K6EUAOW3.js} +1 -1
- package/{chunk-OHEKYYJF.js → chunk-KMQPSTMJ.js} +6 -6
- package/{chunk-3WGLLTK4.js → chunk-LSFAWXKC.js} +100 -3
- package/{chunk-4ON5AV72.js → chunk-MYMMNKYL.js} +1 -1
- package/{chunk-BHK5ZAW7.js → chunk-N5424GSW.js} +1 -1
- package/{chunk-7LAIOHOL.js → chunk-O53CP2QR.js} +3 -3
- package/{chunk-IMZ7AFIJ.js → chunk-OQMPU2ML.js} +4 -4
- package/{chunk-NZFWHBW5.js → chunk-QLFCNUVQ.js} +496 -442
- package/{chunk-TQCONXQ3.js → chunk-QZVGMD5F.js} +1 -1
- package/{chunk-UW3WOIWJ.js → chunk-RKM3K52F.js} +1 -1
- package/{chunk-TLNEQI2R.js → chunk-RSYUDGGZ.js} +9 -9
- package/{chunk-A5V7UEZJ.js → chunk-SFXYKGK2.js} +3 -3
- package/{chunk-S5UACFUP.js → chunk-TTGAVETO.js} +10 -2
- package/{chunk-BOJVWKNA.js → chunk-U7LEGLEB.js} +1 -1
- package/{chunk-R5AOLZZV.js → chunk-VE6XMVKG.js} +203 -45
- package/{chunk-NJVPXLRY.js → chunk-VPTJB4HM.js} +1 -1
- package/{chunk-PB2DHBEQ.js → chunk-WA6KZL5V.js} +25 -6
- package/{chunk-T3X232L6.js → chunk-WNLPAOIT.js} +1 -1
- package/{chunk-E6KIDMTW.js → chunk-WPN6RMDF.js} +9 -9
- package/{chunk-NFPO7274.js → chunk-WRN5EQT7.js} +1 -1
- package/{chunk-3FCSMQAC.js → chunk-XVP3C2KY.js} +1 -1
- package/{chunk-33K5FKRL.js → chunk-YC3DJILJ.js} +111 -40
- package/{chunk-TYRTLSGX.js → chunk-YNHQIXX5.js} +833 -5746
- package/{chunk-4F4FJPFM.js → chunk-YYIRR6QC.js} +98 -209
- package/{chunk-7TN6V43T.js → chunk-Z24FGIU2.js} +2 -2
- package/{cliEnvHelpers-VYC2OPTB.js → cliEnvHelpers-ZXNMX7VV.js} +1 -1
- package/{createAgentAutomationAction-VLNDOHSP.js → createAgentAutomationAction-TS6NNZ4X.js} +9 -9
- package/{createDialogAction-6WYTS62Z.js → createDialogAction-5HVQ33EX.js} +10 -10
- package/{createPageAction-YKHOC3LW.js → createPageAction-4F3ZGQJD.js} +9 -9
- package/{dbSlice-7Q23HSWH.js → dbSlice-OP6UPXKA.js} +2 -2
- package/{dialogCommands-BQDGLVMO.js → dialogCommands-ZL6L24BS.js} +16 -16
- package/{dialogSlice-2A2JOFZW.js → dialogSlice-FAWUQDJW.js} +9 -9
- package/{docCreateCommands-K2MPMXYF.js → docCreateCommands-LYROQTFH.js} +22 -20
- package/{docDeleteCommands-NBAARB77.js → docDeleteCommands-6TWGTZNR.js} +21 -19
- package/{docReadCommands-S3MO5RPS.js → docReadCommands-PRULNF26.js} +20 -18
- package/{docStore-JJP5PUR7.js → docStore-2UHVWLTV.js} +10 -10
- package/{docUpdateCommands-EHEI7FCE.js → docUpdateCommands-NNYYWJBI.js} +21 -19
- package/{handleSendMessageAction-UAXTF73I.js → handleSendMessageAction-LJPUYNOH.js} +15 -11
- package/index.js +109 -78
- package/{machineCommands-BQ46IS5M.js → machineCommands-JQPEQFSE.js} +36 -36
- package/{machineWsRunDispatch-R33NXNNI.js → machineWsRunDispatch-FFFNWVEW.js} +32 -32
- package/{memoryCommands-AFMES3LN.js → memoryCommands-EBMICQR6.js} +1 -1
- package/package.json +1 -1
- package/{read-SIWMJRHC.js → read-HXHAZBKH.js} +1 -1
- package/{readDocTool-TCYJY4PP.js → readDocTool-VPBDTO4G.js} +1 -1
- package/{readlineWorkspace-KBG4DKLX.js → readlineWorkspace-QSXHSBHA.js} +211 -105
- package/{removeDialogAgentAction-WKHZT6VJ.js → removeDialogAgentAction-HUFVN35S.js} +4 -4
- package/{runAgentClientLoop-MUV5YIRK.js → runAgentClientLoop-A75BUU6D.js} +19 -19
- package/{runtimeDoctorCommands-QNF3J3UV.js → runtimeDoctorCommands-THIHX2SY.js} +1 -1
- package/{setDialogExtraReferencesAction-GCI5QU6E.js → setDialogExtraReferencesAction-2VLGWQKG.js} +2 -2
- package/{setPrimaryDialogAgentAction-NRO57AS6.js → setPrimaryDialogAgentAction-VB4UV2CC.js} +4 -4
- package/{settingSlice-FTWZ5ZHT.js → settingSlice-7JYPQNAC.js} +3 -3
- package/{spaceCommands-4R63UST3.js → spaceCommands-4LE45GB7.js} +21 -21
- package/{spaceSlice-VTC3QXP3.js → spaceSlice-444MFUP6.js} +11 -9
- package/{streamAgentChatTurn-43N7BNV2.js → streamAgentChatTurn-DJAE7USZ.js} +42 -39
- package/{tableCommands-E4SQWDOX.js → tableCommands-3P7MJ3PF.js} +4 -4
- package/{tools-PX6PEJLE.js → tools-YB6LXSVN.js} +14 -14
- package/{tuiSummaryLlmCaller-2D65LKWM.js → tuiSummaryLlmCaller-QQL3JA5I.js} +3 -3
- package/{updateCommands-XZDOOYFH.js → updateCommands-XTW55TOT.js} +2 -2
- package/{updateDialogTitleAction-NPQZWAKG.js → updateDialogTitleAction-6HGFBM64.js} +9 -9
- package/{chunk-3QAF2LTL.js → chunk-DZ3XJVET.js} +3 -3
|
@@ -3,7 +3,7 @@ import {
|
|
|
3
3
|
normalizeDialogRecord,
|
|
4
4
|
readDialogSnapshot,
|
|
5
5
|
sortDialogs
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-RSYUDGGZ.js";
|
|
7
7
|
import {
|
|
8
8
|
ANSI_ESCAPE_REGEX,
|
|
9
9
|
CLI_AUTO_TIER_AGENT_KEYS,
|
|
@@ -12,6 +12,7 @@ import {
|
|
|
12
12
|
COLLAPSED_PASTE_PLACEHOLDER_RE,
|
|
13
13
|
THEME_PALETTES,
|
|
14
14
|
allocateCollapsedPaste,
|
|
15
|
+
applyDetectedBackground,
|
|
15
16
|
applyTerminalOutputToText,
|
|
16
17
|
buildSkillContextBlocks,
|
|
17
18
|
classifyCliAutoRoute,
|
|
@@ -30,7 +31,6 @@ import {
|
|
|
30
31
|
getActiveThemeName,
|
|
31
32
|
isBalanceExhaustedError,
|
|
32
33
|
isQuotaExhaustedError,
|
|
33
|
-
normalizeThinkingDisplayMode,
|
|
34
34
|
normalizeToolDisplayMode,
|
|
35
35
|
padOrTruncateToWidth,
|
|
36
36
|
releaseCollapsedPaste,
|
|
@@ -57,29 +57,27 @@ import {
|
|
|
57
57
|
visibleWidth,
|
|
58
58
|
wrapTextToLines,
|
|
59
59
|
wrapTranscriptLine
|
|
60
|
-
} from "./chunk-
|
|
60
|
+
} from "./chunk-YYIRR6QC.js";
|
|
61
|
+
import "./chunk-DZ3XJVET.js";
|
|
61
62
|
import "./chunk-6HYVJV7B.js";
|
|
62
63
|
import {
|
|
63
64
|
listFavoriteAgentIdsAcrossServers,
|
|
64
65
|
listLocalCachedAgents,
|
|
65
66
|
listRemoteAgents,
|
|
66
67
|
listRemoteAgentsAcrossServers
|
|
67
|
-
} from "./chunk-
|
|
68
|
+
} from "./chunk-GRTFNYLR.js";
|
|
68
69
|
import "./chunk-ID4G2MAR.js";
|
|
69
70
|
import {
|
|
70
71
|
listUserRecordsFromServers
|
|
71
|
-
} from "./chunk-
|
|
72
|
-
import "./chunk-3QAF2LTL.js";
|
|
72
|
+
} from "./chunk-J55UHASN.js";
|
|
73
73
|
import {
|
|
74
74
|
createCliLocalRuntimeAdapter,
|
|
75
75
|
initCliLocale,
|
|
76
76
|
parseCliLocale,
|
|
77
77
|
setCliLocale,
|
|
78
78
|
t
|
|
79
|
-
} from "./chunk-
|
|
79
|
+
} from "./chunk-QLFCNUVQ.js";
|
|
80
80
|
import "./chunk-EHLHSX7R.js";
|
|
81
|
-
import "./chunk-CMKUBIGW.js";
|
|
82
|
-
import "./chunk-JBTJAPUF.js";
|
|
83
81
|
import {
|
|
84
82
|
getReadableCliDb
|
|
85
83
|
} from "./chunk-W4NVOSFF.js";
|
|
@@ -87,45 +85,45 @@ import {
|
|
|
87
85
|
deleteDbRecord,
|
|
88
86
|
queryUserRecords,
|
|
89
87
|
readDbRecord
|
|
90
|
-
} from "./chunk-
|
|
91
|
-
import "./chunk-
|
|
88
|
+
} from "./chunk-4NLUNENX.js";
|
|
89
|
+
import "./chunk-QZVGMD5F.js";
|
|
92
90
|
import {
|
|
93
91
|
resolveCliAgentKeyInput
|
|
94
92
|
} from "./chunk-VHBWHNVT.js";
|
|
95
93
|
import "./chunk-LTRXGFMS.js";
|
|
96
|
-
import "./chunk-
|
|
97
|
-
import "./chunk-ATNTHIZI.js";
|
|
94
|
+
import "./chunk-WNLPAOIT.js";
|
|
98
95
|
import "./chunk-JEXVIMYZ.js";
|
|
99
96
|
import {
|
|
100
97
|
prepareTools
|
|
101
|
-
} from "./chunk-
|
|
102
|
-
import "./chunk-
|
|
98
|
+
} from "./chunk-WRN5EQT7.js";
|
|
99
|
+
import "./chunk-ISYE6GZB.js";
|
|
103
100
|
import {
|
|
104
101
|
expandEnabledPacks
|
|
105
|
-
} from "./chunk-
|
|
102
|
+
} from "./chunk-VE6XMVKG.js";
|
|
106
103
|
import "./chunk-RQSOAMPJ.js";
|
|
107
104
|
import "./chunk-OOIN7HSO.js";
|
|
108
105
|
import "./chunk-KQHGZWSV.js";
|
|
109
|
-
import "./chunk-
|
|
106
|
+
import "./chunk-O53CP2QR.js";
|
|
107
|
+
import "./chunk-U7LEGLEB.js";
|
|
110
108
|
import "./chunk-3LY4F7SV.js";
|
|
111
109
|
import "./chunk-VP4WJWKW.js";
|
|
112
110
|
import "./chunk-63W5N6P3.js";
|
|
113
111
|
import "./chunk-VF4K2QE6.js";
|
|
114
|
-
import "./chunk-
|
|
115
|
-
import "./chunk-7TN6V43T.js";
|
|
112
|
+
import "./chunk-Z24FGIU2.js";
|
|
116
113
|
import "./chunk-VC6OZXO5.js";
|
|
117
114
|
import "./chunk-OWOHNGCN.js";
|
|
118
115
|
import {
|
|
119
116
|
extractReferenceKeysFromMessage
|
|
120
|
-
} from "./chunk-
|
|
117
|
+
} from "./chunk-YNHQIXX5.js";
|
|
121
118
|
import {
|
|
122
119
|
buildBuiltinSummaryContent
|
|
123
120
|
} from "./chunk-V2J635L5.js";
|
|
124
121
|
import "./chunk-MRC4Q34M.js";
|
|
125
122
|
import "./chunk-MTU75CZ2.js";
|
|
126
123
|
import "./chunk-CWMSB67P.js";
|
|
127
|
-
import "./chunk-
|
|
128
|
-
import "./chunk-
|
|
124
|
+
import "./chunk-OQMPU2ML.js";
|
|
125
|
+
import "./chunk-JS33TCQ3.js";
|
|
126
|
+
import "./chunk-SOTZ6RDN.js";
|
|
129
127
|
import "./chunk-Z4NR32XR.js";
|
|
130
128
|
import "./chunk-M76ECQRD.js";
|
|
131
129
|
import {
|
|
@@ -136,21 +134,23 @@ import {
|
|
|
136
134
|
buildLocalWorkspaceOpenAiTools,
|
|
137
135
|
buildLocalWorkspaceToolset,
|
|
138
136
|
getProcessRegistry
|
|
139
|
-
} from "./chunk-
|
|
137
|
+
} from "./chunk-YC3DJILJ.js";
|
|
138
|
+
import "./chunk-WA6KZL5V.js";
|
|
140
139
|
import "./chunk-ZNFJWEN4.js";
|
|
141
|
-
import "./chunk-PB2DHBEQ.js";
|
|
142
140
|
import "./chunk-OIQPORYI.js";
|
|
143
141
|
import {
|
|
144
142
|
readCommandActionGatePayload,
|
|
145
143
|
resolveAgentImageInputSupport
|
|
146
|
-
} from "./chunk-
|
|
147
|
-
import "./chunk-
|
|
144
|
+
} from "./chunk-6MHDWKOT.js";
|
|
145
|
+
import "./chunk-LSFAWXKC.js";
|
|
148
146
|
import {
|
|
149
147
|
buildCurrentTimeBlock,
|
|
150
148
|
buildIdentityBlock,
|
|
151
149
|
buildRuntimeGuidanceBlocks
|
|
152
|
-
} from "./chunk-
|
|
153
|
-
import
|
|
150
|
+
} from "./chunk-RKM3K52F.js";
|
|
151
|
+
import {
|
|
152
|
+
resolvePlatformAuthToken
|
|
153
|
+
} from "./chunk-HRQCKQA5.js";
|
|
154
154
|
import {
|
|
155
155
|
canonicalizeToolNames
|
|
156
156
|
} from "./chunk-B4KT7RN2.js";
|
|
@@ -160,7 +160,7 @@ import {
|
|
|
160
160
|
getModelContextWindow,
|
|
161
161
|
planCompression,
|
|
162
162
|
serializeMessageContent
|
|
163
|
-
} from "./chunk-
|
|
163
|
+
} from "./chunk-4QQFLN5C.js";
|
|
164
164
|
import {
|
|
165
165
|
clipCompactText
|
|
166
166
|
} from "./chunk-5MMAK75Q.js";
|
|
@@ -178,16 +178,18 @@ import "./chunk-3ASDTTEI.js";
|
|
|
178
178
|
import {
|
|
179
179
|
compactWhitespace
|
|
180
180
|
} from "./chunk-DWLEOOGR.js";
|
|
181
|
-
import "./chunk-
|
|
181
|
+
import "./chunk-MYMMNKYL.js";
|
|
182
|
+
import "./chunk-CMKUBIGW.js";
|
|
183
|
+
import "./chunk-JBTJAPUF.js";
|
|
184
|
+
import "./chunk-ATNTHIZI.js";
|
|
182
185
|
import {
|
|
183
186
|
toErrorMessage
|
|
184
187
|
} from "./chunk-HNMXYYJR.js";
|
|
185
188
|
import "./chunk-H33743XH.js";
|
|
186
189
|
import "./chunk-LM6IYQ3F.js";
|
|
187
|
-
import "./chunk-SOTZ6RDN.js";
|
|
188
190
|
import {
|
|
189
191
|
runSelfUpdate
|
|
190
|
-
} from "./chunk-
|
|
192
|
+
} from "./chunk-K6EUAOW3.js";
|
|
191
193
|
import {
|
|
192
194
|
saveProfileAgentSelection,
|
|
193
195
|
saveProfileLocale
|
|
@@ -196,14 +198,23 @@ import {
|
|
|
196
198
|
readPipeText,
|
|
197
199
|
spawnProcess
|
|
198
200
|
} from "./chunk-IDZTNRP2.js";
|
|
201
|
+
import {
|
|
202
|
+
parseUserIdFromAuthToken,
|
|
203
|
+
resolveAuthToken,
|
|
204
|
+
resolveServerCandidates,
|
|
205
|
+
resolveServerUrl
|
|
206
|
+
} from "./chunk-A7GB5UGH.js";
|
|
207
|
+
import {
|
|
208
|
+
DEFAULT_NOLO_SERVER_URL
|
|
209
|
+
} from "./chunk-OLZBQWZU.js";
|
|
199
210
|
import "./chunk-IKXL2HZ3.js";
|
|
200
211
|
import "./chunk-524BDL33.js";
|
|
201
|
-
import "./chunk-
|
|
202
|
-
import "./chunk-
|
|
212
|
+
import "./chunk-N5424GSW.js";
|
|
213
|
+
import "./chunk-TTGAVETO.js";
|
|
203
214
|
import "./chunk-Y5GCAMGP.js";
|
|
204
215
|
import "./chunk-KX6YBIHG.js";
|
|
205
|
-
import "./chunk-
|
|
206
|
-
import "./chunk-
|
|
216
|
+
import "./chunk-XVP3C2KY.js";
|
|
217
|
+
import "./chunk-SFXYKGK2.js";
|
|
207
218
|
import "./chunk-O4BU24WZ.js";
|
|
208
219
|
import "./chunk-I42VC5KR.js";
|
|
209
220
|
import "./chunk-WWC7I6TA.js";
|
|
@@ -211,22 +222,13 @@ import "./chunk-JTINRTBT.js";
|
|
|
211
222
|
import {
|
|
212
223
|
asTrimmedLowercaseString
|
|
213
224
|
} from "./chunk-QSJ3HFEF.js";
|
|
214
|
-
import "./chunk-
|
|
225
|
+
import "./chunk-VPTJB4HM.js";
|
|
215
226
|
import "./chunk-DVRHHFEA.js";
|
|
216
227
|
import "./chunk-OOSFSFMA.js";
|
|
217
228
|
import "./chunk-GBRG75BQ.js";
|
|
218
229
|
import "./chunk-3EUW3WEO.js";
|
|
219
230
|
import "./chunk-U6VC4MU4.js";
|
|
220
231
|
import "./chunk-KUG52IAP.js";
|
|
221
|
-
import {
|
|
222
|
-
parseUserIdFromAuthToken,
|
|
223
|
-
resolveAuthToken,
|
|
224
|
-
resolveServerCandidates,
|
|
225
|
-
resolveServerUrl
|
|
226
|
-
} from "./chunk-5NBHQD4D.js";
|
|
227
|
-
import {
|
|
228
|
-
DEFAULT_NOLO_SERVER_URL
|
|
229
|
-
} from "./chunk-OLZBQWZU.js";
|
|
230
232
|
import "./chunk-LCBAMY2M.js";
|
|
231
233
|
import "./chunk-4SN6J65J.js";
|
|
232
234
|
import "./chunk-CF7PE763.js";
|
|
@@ -1928,6 +1930,7 @@ function mergeCatalogEntries(currentKey, platformAgents, privateAgents, favorite
|
|
|
1928
1930
|
}
|
|
1929
1931
|
var agentCatalogCache = null;
|
|
1930
1932
|
var agentCatalogRefreshInFlight = null;
|
|
1933
|
+
var agentCatalogRawLoadInFlight = null;
|
|
1931
1934
|
var AGENT_CATALOG_FRESH_MS = 15e3;
|
|
1932
1935
|
async function loadAgentCatalog(args) {
|
|
1933
1936
|
const env = args.env ?? process.env;
|
|
@@ -1941,13 +1944,38 @@ async function loadAgentCatalog(args) {
|
|
|
1941
1944
|
}
|
|
1942
1945
|
return cached.entries;
|
|
1943
1946
|
}
|
|
1944
|
-
|
|
1947
|
+
let rawData;
|
|
1948
|
+
if (agentCatalogRawLoadInFlight) {
|
|
1949
|
+
rawData = await agentCatalogRawLoadInFlight;
|
|
1950
|
+
} else {
|
|
1951
|
+
const promise = fetchRawCatalogData(args, env);
|
|
1952
|
+
agentCatalogRawLoadInFlight = promise;
|
|
1953
|
+
try {
|
|
1954
|
+
rawData = await promise;
|
|
1955
|
+
} catch (error) {
|
|
1956
|
+
agentCatalogRawLoadInFlight = null;
|
|
1957
|
+
throw error;
|
|
1958
|
+
}
|
|
1959
|
+
agentCatalogRawLoadInFlight = null;
|
|
1960
|
+
}
|
|
1961
|
+
const entries = mergeCatalogEntries(
|
|
1962
|
+
args.currentKey,
|
|
1963
|
+
resolveCatalogPlatformAgents(env),
|
|
1964
|
+
rawData.privateAgents,
|
|
1965
|
+
rawData.favoritedAtByKey
|
|
1966
|
+
);
|
|
1945
1967
|
agentCatalogCache = { cacheKey, at: Date.now(), entries };
|
|
1946
1968
|
return entries;
|
|
1947
1969
|
}
|
|
1948
1970
|
function refreshAgentCatalogInBackground(args, env, cacheKey) {
|
|
1949
1971
|
if (agentCatalogRefreshInFlight) return;
|
|
1950
|
-
agentCatalogRefreshInFlight =
|
|
1972
|
+
agentCatalogRefreshInFlight = fetchRawCatalogData(args, env).then((rawData) => {
|
|
1973
|
+
const entries = mergeCatalogEntries(
|
|
1974
|
+
args.currentKey,
|
|
1975
|
+
resolveCatalogPlatformAgents(env),
|
|
1976
|
+
rawData.privateAgents,
|
|
1977
|
+
rawData.favoritedAtByKey
|
|
1978
|
+
);
|
|
1951
1979
|
agentCatalogCache = { cacheKey, at: Date.now(), entries };
|
|
1952
1980
|
}).catch(() => {
|
|
1953
1981
|
}).finally(() => {
|
|
@@ -1958,17 +1986,13 @@ function prefetchAgentCatalog(args) {
|
|
|
1958
1986
|
void loadAgentCatalog({ ...args, currentKey: "" }).catch(() => {
|
|
1959
1987
|
});
|
|
1960
1988
|
}
|
|
1961
|
-
async function
|
|
1989
|
+
async function fetchRawCatalogData(args, env) {
|
|
1962
1990
|
const fetchImpl = args.fetchImpl ?? fetch;
|
|
1963
1991
|
const fallbackFetchImpl = args.fallbackFetchImpl;
|
|
1964
1992
|
const authToken = resolveAuthToken([], env);
|
|
1965
1993
|
const userId = authToken ? parseUserIdFromAuthToken(authToken) : null;
|
|
1966
1994
|
if (!authToken || !userId) {
|
|
1967
|
-
return
|
|
1968
|
-
args.currentKey,
|
|
1969
|
-
resolveCatalogPlatformAgents(env),
|
|
1970
|
-
[]
|
|
1971
|
-
);
|
|
1995
|
+
return { privateAgents: [], favoritedAtByKey: {} };
|
|
1972
1996
|
}
|
|
1973
1997
|
const serverUrl = resolveServerUrl(env);
|
|
1974
1998
|
const serverUrls = resolveServerCandidates([], env, serverUrl);
|
|
@@ -2006,12 +2030,7 @@ async function fetchAgentCatalog(args, env) {
|
|
|
2006
2030
|
}
|
|
2007
2031
|
}
|
|
2008
2032
|
const favoritedAtByKey = await favoritesPromise;
|
|
2009
|
-
return
|
|
2010
|
-
args.currentKey,
|
|
2011
|
-
resolveCatalogPlatformAgents(env),
|
|
2012
|
-
privateAgents,
|
|
2013
|
-
favoritedAtByKey
|
|
2014
|
-
);
|
|
2033
|
+
return { privateAgents, favoritedAtByKey };
|
|
2015
2034
|
}
|
|
2016
2035
|
function renderAgentCatalogList(entries, currentKey) {
|
|
2017
2036
|
const lines = ["Agents:"];
|
|
@@ -2073,12 +2092,23 @@ async function runAgentPicker(args) {
|
|
|
2073
2092
|
const output = args.output ?? process.stdout;
|
|
2074
2093
|
const input = args.input ?? process.stdin;
|
|
2075
2094
|
const interactive = args.interactive ?? ("isTTY" in input && Boolean(input.isTTY) && "isTTY" in output && Boolean(output.isTTY));
|
|
2076
|
-
const
|
|
2077
|
-
|
|
2078
|
-
|
|
2079
|
-
|
|
2080
|
-
|
|
2081
|
-
|
|
2095
|
+
const isTty = outputIsTty(output);
|
|
2096
|
+
if (isTty) {
|
|
2097
|
+
output.write(t("agentPickerLoading"));
|
|
2098
|
+
}
|
|
2099
|
+
let entries;
|
|
2100
|
+
try {
|
|
2101
|
+
entries = await loadAgentCatalog({
|
|
2102
|
+
env: args.env,
|
|
2103
|
+
currentKey: args.currentKey,
|
|
2104
|
+
fetchImpl: args.fetchImpl,
|
|
2105
|
+
fallbackFetchImpl: args.fallbackFetchImpl
|
|
2106
|
+
});
|
|
2107
|
+
} finally {
|
|
2108
|
+
if (isTty) {
|
|
2109
|
+
output.write("\r\x1B[2K");
|
|
2110
|
+
}
|
|
2111
|
+
}
|
|
2082
2112
|
if (!interactive) {
|
|
2083
2113
|
return {
|
|
2084
2114
|
kind: "list",
|
|
@@ -2706,7 +2736,6 @@ function renderContextPanel(state, colorEnabled = resolveCliColorEnabled()) {
|
|
|
2706
2736
|
t("contextFieldProfile"),
|
|
2707
2737
|
t("contextFieldRuntime"),
|
|
2708
2738
|
t("contextFieldTools"),
|
|
2709
|
-
t("contextFieldThinking"),
|
|
2710
2739
|
t("contextFieldServer")
|
|
2711
2740
|
];
|
|
2712
2741
|
let maxW = 0;
|
|
@@ -2737,8 +2766,7 @@ function renderContextPanel(state, colorEnabled = resolveCliColorEnabled()) {
|
|
|
2737
2766
|
field(labels[5], state.profileName),
|
|
2738
2767
|
field(labels[6], state.runtimeMode),
|
|
2739
2768
|
field(labels[7], state.toolDisplay),
|
|
2740
|
-
field(labels[8], state.
|
|
2741
|
-
field(labels[9], state.serverUrl),
|
|
2769
|
+
field(labels[8], state.serverUrl),
|
|
2742
2770
|
"",
|
|
2743
2771
|
themeText(t("contextNext"), "chrome", colorEnabled),
|
|
2744
2772
|
next("/agents ", ` ${t("contextNextAgents")}`),
|
|
@@ -3076,10 +3104,6 @@ function createInitialTuiState(env = process.env) {
|
|
|
3076
3104
|
runtimeMode,
|
|
3077
3105
|
modeLabel: asOptionalTrimmedString(env.NOLO_CLI_STATUS_MODE) ?? runtimeMode,
|
|
3078
3106
|
gitStatus: void 0,
|
|
3079
|
-
thinkingDisplay: normalizeThinkingDisplayMode(
|
|
3080
|
-
env.NOLO_CLI_THINKING ?? env.NOLO_THINKING,
|
|
3081
|
-
"hide"
|
|
3082
|
-
),
|
|
3083
3107
|
toolDisplay: normalizeToolDisplayMode(env.NOLO_CLI_TOOLS ?? env.NOLO_TOOLS, "compact"),
|
|
3084
3108
|
contextWindow: resolveAgentContextWindow({
|
|
3085
3109
|
agentKey,
|
|
@@ -3183,6 +3207,9 @@ function handleTuiInput(input, state) {
|
|
|
3183
3207
|
].join("\n")
|
|
3184
3208
|
};
|
|
3185
3209
|
}
|
|
3210
|
+
if (sub === "refresh") {
|
|
3211
|
+
return { nextState: state, action: { type: "theme-refresh" }, output: "" };
|
|
3212
|
+
}
|
|
3186
3213
|
if (sub === "light" || sub === "dark") {
|
|
3187
3214
|
setActiveBrightness(sub);
|
|
3188
3215
|
return { nextState: state, output: t("themeBrightnessSwitched", sub) };
|
|
@@ -3263,26 +3290,6 @@ function handleTuiInput(input, state) {
|
|
|
3263
3290
|
output: t("toolsSet", nextMode)
|
|
3264
3291
|
};
|
|
3265
3292
|
}
|
|
3266
|
-
case "/thinking": {
|
|
3267
|
-
if (!argText) {
|
|
3268
|
-
return {
|
|
3269
|
-
nextState: state,
|
|
3270
|
-
output: t("thinkingCurrent", state.thinkingDisplay)
|
|
3271
|
-
};
|
|
3272
|
-
}
|
|
3273
|
-
const normalizedArg = asTrimmedLowercaseString(argText);
|
|
3274
|
-
if (!["hide", "marker", "show", "on", "off"].includes(normalizedArg)) {
|
|
3275
|
-
return {
|
|
3276
|
-
nextState: state,
|
|
3277
|
-
output: t("thinkingUsage")
|
|
3278
|
-
};
|
|
3279
|
-
}
|
|
3280
|
-
const nextMode = normalizeThinkingDisplayMode(normalizedArg, state.thinkingDisplay);
|
|
3281
|
-
return {
|
|
3282
|
-
nextState: { ...state, thinkingDisplay: nextMode },
|
|
3283
|
-
output: t("thinkingSet", nextMode)
|
|
3284
|
-
};
|
|
3285
|
-
}
|
|
3286
3293
|
case "/tasks":
|
|
3287
3294
|
case "/jobs":
|
|
3288
3295
|
case "/procs": {
|
|
@@ -4282,6 +4289,10 @@ function createFixedInput(output, config) {
|
|
|
4282
4289
|
}
|
|
4283
4290
|
const rule = colorEnabled ? `\x1B[2m${themeColorSequence("chrome")}${"\u2500".repeat(cols)}\x1B[0m` : "\u2500".repeat(cols);
|
|
4284
4291
|
sections.push(rule);
|
|
4292
|
+
const titleLine = config.getTitleLine?.();
|
|
4293
|
+
if (titleLine) {
|
|
4294
|
+
sections.push(fitAnsiLine(titleLine.replace(/\r?\n/g, " "), cols));
|
|
4295
|
+
}
|
|
4285
4296
|
sections.push(fitAnsiLine(config.getStatusLine(), cols));
|
|
4286
4297
|
const queueLines = config.getQueueLines?.() ?? [];
|
|
4287
4298
|
for (const line of queueLines) {
|
|
@@ -4336,7 +4347,7 @@ function createFixedInput(output, config) {
|
|
|
4336
4347
|
}
|
|
4337
4348
|
const text = sections.join("\n");
|
|
4338
4349
|
const lines = sections.length;
|
|
4339
|
-
const headerRows = (completions.length > 0 ? 1 : 0) + 2 + activityLines.length + queueLines.length;
|
|
4350
|
+
const headerRows = (completions.length > 0 ? 1 : 0) + 2 + (titleLine ? 1 : 0) + activityLines.length + queueLines.length;
|
|
4340
4351
|
return { text, lines, cursorCol, cursorRow: headerRows + cursorRow };
|
|
4341
4352
|
};
|
|
4342
4353
|
const repaintAt = (buffer, cursorPos) => {
|
|
@@ -4439,6 +4450,22 @@ function readCsiSequence(input, start) {
|
|
|
4439
4450
|
}
|
|
4440
4451
|
return null;
|
|
4441
4452
|
}
|
|
4453
|
+
function parseOscEnd(input, start) {
|
|
4454
|
+
if (!input.startsWith("\x1B]", start)) return null;
|
|
4455
|
+
const bodyStart = start + 2;
|
|
4456
|
+
const bel = input.indexOf("\x07", bodyStart);
|
|
4457
|
+
const st = input.indexOf("\x1B\\", bodyStart);
|
|
4458
|
+
let end = -1;
|
|
4459
|
+
if (bel !== -1) end = bel + 1;
|
|
4460
|
+
if (st !== -1) {
|
|
4461
|
+
const stEnd = st + 2;
|
|
4462
|
+
if (end === -1 || stEnd < end) end = stEnd;
|
|
4463
|
+
}
|
|
4464
|
+
return end === -1 ? null : end;
|
|
4465
|
+
}
|
|
4466
|
+
function isIncompleteOsc(input) {
|
|
4467
|
+
return input.startsWith("\x1B]") && parseOscEnd(input, 0) === null;
|
|
4468
|
+
}
|
|
4442
4469
|
function isIncompleteTail(input, start) {
|
|
4443
4470
|
if (start >= input.length) return false;
|
|
4444
4471
|
const rem = input.slice(start);
|
|
@@ -4459,6 +4486,9 @@ function isIncompleteTail(input, start) {
|
|
|
4459
4486
|
}
|
|
4460
4487
|
return true;
|
|
4461
4488
|
}
|
|
4489
|
+
if (parseOscEnd(input, start) === null && input.startsWith("\x1B]", start)) {
|
|
4490
|
+
return true;
|
|
4491
|
+
}
|
|
4462
4492
|
if (rem.startsWith("\x1BO") && rem.length < 3) {
|
|
4463
4493
|
return true;
|
|
4464
4494
|
}
|
|
@@ -4490,6 +4520,11 @@ function splitRawInputWithTail(input, options) {
|
|
|
4490
4520
|
if (isIncompleteTail(input, index)) {
|
|
4491
4521
|
return { tokens, tail: input.slice(index) };
|
|
4492
4522
|
}
|
|
4523
|
+
const oscEnd = parseOscEnd(input, index);
|
|
4524
|
+
if (oscEnd !== null) {
|
|
4525
|
+
index = oscEnd;
|
|
4526
|
+
continue;
|
|
4527
|
+
}
|
|
4493
4528
|
if (input.startsWith(PASTE_START, index)) {
|
|
4494
4529
|
const contentStart = index + PASTE_START.length;
|
|
4495
4530
|
const endPos = findBracketedPasteEnd(input, contentStart);
|
|
@@ -4593,7 +4628,9 @@ function createRawInputDecoder(onToken, options) {
|
|
|
4593
4628
|
}
|
|
4594
4629
|
if (!tail) return;
|
|
4595
4630
|
if (forceCompleteOpenPaste) {
|
|
4596
|
-
if (consumeSgrMouseSequence(tail) === void 0)
|
|
4631
|
+
if (consumeSgrMouseSequence(tail) === void 0 || isIncompleteOsc(tail)) {
|
|
4632
|
+
return;
|
|
4633
|
+
}
|
|
4597
4634
|
emitCodePoints(tail);
|
|
4598
4635
|
return;
|
|
4599
4636
|
}
|
|
@@ -4621,7 +4658,9 @@ function createRawInputDecoder(onToken, options) {
|
|
|
4621
4658
|
for (const token of tokens) onToken(token);
|
|
4622
4659
|
if (pendingBuffer.startsWith(PASTE_START)) return;
|
|
4623
4660
|
if (pendingBuffer.length > 0) {
|
|
4624
|
-
if (consumeSgrMouseSequence(pendingBuffer) === void 0)
|
|
4661
|
+
if (consumeSgrMouseSequence(pendingBuffer) === void 0 || isIncompleteOsc(pendingBuffer)) {
|
|
4662
|
+
return;
|
|
4663
|
+
}
|
|
4625
4664
|
timer = setTimeout(() => flushEscPending(true), timeoutMs);
|
|
4626
4665
|
}
|
|
4627
4666
|
return;
|
|
@@ -4736,7 +4775,7 @@ async function runAgentChat(scriptDir, state, message, env, output, agentRunner
|
|
|
4736
4775
|
effectiveAgentKey = cachedRoute.agentKey;
|
|
4737
4776
|
effectiveAgentName = cachedRoute.agentName;
|
|
4738
4777
|
} else if (!continueId && env.NOLO_AUTO_ROUTE !== "0" && state.agentKey === DEFAULT_TUI_AGENT_KEY) {
|
|
4739
|
-
const authToken = env
|
|
4778
|
+
const authToken = resolvePlatformAuthToken(env);
|
|
4740
4779
|
const route = authToken ? await classifyCliAutoRoute(message, {
|
|
4741
4780
|
serverUrl: state.serverUrl,
|
|
4742
4781
|
authToken
|
|
@@ -4763,7 +4802,7 @@ async function runAgentChat(scriptDir, state, message, env, output, agentRunner
|
|
|
4763
4802
|
if (CLI_AUTO_TIER_AGENT_KEY_TABLE[visionProbeKey]) {
|
|
4764
4803
|
needsVisionSwitch = true;
|
|
4765
4804
|
} else {
|
|
4766
|
-
const authToken = env
|
|
4805
|
+
const authToken = resolvePlatformAuthToken(env);
|
|
4767
4806
|
const record = await readDbRecord({
|
|
4768
4807
|
dbKey: visionProbeKey,
|
|
4769
4808
|
authToken,
|
|
@@ -4788,7 +4827,7 @@ async function runAgentChat(scriptDir, state, message, env, output, agentRunner
|
|
|
4788
4827
|
let skillAllowedTools;
|
|
4789
4828
|
let skillContextBlocks;
|
|
4790
4829
|
if (state.attachedSkills.length > 0) {
|
|
4791
|
-
const authToken = env
|
|
4830
|
+
const authToken = resolvePlatformAuthToken(env);
|
|
4792
4831
|
const resolvedSkills = [];
|
|
4793
4832
|
for (const ref of state.attachedSkills) {
|
|
4794
4833
|
try {
|
|
@@ -4855,7 +4894,6 @@ async function runAgentChat(scriptDir, state, message, env, output, agentRunner
|
|
|
4855
4894
|
scriptDir,
|
|
4856
4895
|
env: {
|
|
4857
4896
|
...env,
|
|
4858
|
-
NOLO_CLI_THINKING: state.thinkingDisplay,
|
|
4859
4897
|
NOLO_CLI_TOOLS: state.toolDisplay
|
|
4860
4898
|
},
|
|
4861
4899
|
output,
|
|
@@ -5269,6 +5307,43 @@ async function startTuiWorkspace(options) {
|
|
|
5269
5307
|
};
|
|
5270
5308
|
let modalOwnsKeyboard = false;
|
|
5271
5309
|
let rawActionGateTokenHandler = null;
|
|
5310
|
+
const AUTO_THEME_POLL_MS = 3e4;
|
|
5311
|
+
let autoThemeTimer = null;
|
|
5312
|
+
const maybeAutoRefreshTheme = async () => {
|
|
5313
|
+
if (sessionEnded) return;
|
|
5314
|
+
if (fixedInput.isPaused()) return;
|
|
5315
|
+
if (modalOwnsKeyboard) return;
|
|
5316
|
+
if (getActiveBrightness() !== null) return;
|
|
5317
|
+
if (!isInteractiveInput(input)) return;
|
|
5318
|
+
const detected2 = await detectTerminalBackground({
|
|
5319
|
+
stdin: input,
|
|
5320
|
+
stdout: output
|
|
5321
|
+
});
|
|
5322
|
+
if (sessionEnded) return;
|
|
5323
|
+
if (!detected2) {
|
|
5324
|
+
if (autoThemeTimer !== null) {
|
|
5325
|
+
clearInterval(autoThemeTimer);
|
|
5326
|
+
autoThemeTimer = null;
|
|
5327
|
+
}
|
|
5328
|
+
return;
|
|
5329
|
+
}
|
|
5330
|
+
if (applyDetectedBackground(detected2)) {
|
|
5331
|
+
if (fixedInput.active && !fixedInput.isPaused() && !modalOwnsKeyboard) {
|
|
5332
|
+
output.write("\x1B[?2026h\x1B[?25l");
|
|
5333
|
+
try {
|
|
5334
|
+
renderHistoryToOutput();
|
|
5335
|
+
fixedInput.repaint(buffer, cursorPos);
|
|
5336
|
+
} finally {
|
|
5337
|
+
output.write("\x1B[?25h\x1B[?2026l");
|
|
5338
|
+
}
|
|
5339
|
+
}
|
|
5340
|
+
}
|
|
5341
|
+
};
|
|
5342
|
+
if (detected && isInteractiveInput(input) && (options.env ?? process.env).NOLO_TUI_AUTO_THEME !== "0") {
|
|
5343
|
+
autoThemeTimer = setInterval(() => {
|
|
5344
|
+
void maybeAutoRefreshTheme();
|
|
5345
|
+
}, AUTO_THEME_POLL_MS);
|
|
5346
|
+
}
|
|
5272
5347
|
const runOneAgentTurn = async (message, imageUrls, actionGateHandler, confirmDestructiveAction) => {
|
|
5273
5348
|
forcedStop = false;
|
|
5274
5349
|
turnEpoch += 1;
|
|
@@ -5337,7 +5412,7 @@ async function startTuiWorkspace(options) {
|
|
|
5337
5412
|
...runResult.dialogId ? {
|
|
5338
5413
|
dialogId: runResult.dialogId,
|
|
5339
5414
|
dialogKey: nextDialogKey,
|
|
5340
|
-
dialogLabel: runResult.dialogId
|
|
5415
|
+
dialogLabel: runResult.title || runResult.dialogId
|
|
5341
5416
|
} : {},
|
|
5342
5417
|
...runResult.turnTokens ? { turnTokens: runResult.turnTokens } : {}
|
|
5343
5418
|
};
|
|
@@ -5367,7 +5442,7 @@ async function startTuiWorkspace(options) {
|
|
|
5367
5442
|
...runResult.dialogId ? {
|
|
5368
5443
|
dialogId: runResult.dialogId,
|
|
5369
5444
|
dialogKey: nextDialogKey,
|
|
5370
|
-
dialogLabel: runResult.dialogId
|
|
5445
|
+
dialogLabel: runResult.title || runResult.dialogId
|
|
5371
5446
|
} : {},
|
|
5372
5447
|
...runResult.turnTokens ? { turnTokens: runResult.turnTokens } : {},
|
|
5373
5448
|
...runResult.contextWindow ? { contextWindow: runResult.contextWindow } : {}
|
|
@@ -5443,7 +5518,7 @@ async function startTuiWorkspace(options) {
|
|
|
5443
5518
|
if (result.action?.type === "exit") return true;
|
|
5444
5519
|
if (result.action?.type === "clear") {
|
|
5445
5520
|
if (result.action.dialogId) {
|
|
5446
|
-
const authToken = options.env
|
|
5521
|
+
const authToken = resolvePlatformAuthToken(options.env ?? {});
|
|
5447
5522
|
try {
|
|
5448
5523
|
await deleteDbRecord({
|
|
5449
5524
|
// The messages delete endpoint expects the bare dialogId; dialogKey
|
|
@@ -5462,6 +5537,16 @@ async function startTuiWorkspace(options) {
|
|
|
5462
5537
|
}
|
|
5463
5538
|
}
|
|
5464
5539
|
clearCollapsedPasteStore(pasteStore);
|
|
5540
|
+
state = {
|
|
5541
|
+
...state,
|
|
5542
|
+
turnTokens: void 0,
|
|
5543
|
+
estimatedContextTokens: estimateDefaultCliContextTokens({
|
|
5544
|
+
cwd: state.cwd,
|
|
5545
|
+
agentKey: state.agentKey,
|
|
5546
|
+
agentName: state.agentKey === DEFAULT_TUI_AGENT_KEY && (options.env ?? process.env).NOLO_AUTO_ROUTE !== "0" ? "DeepSeek V4 Flash" : state.agentName,
|
|
5547
|
+
model: state.agentKey === DEFAULT_TUI_AGENT_KEY && (options.env ?? process.env).NOLO_AUTO_ROUTE !== "0" ? "deepseek-v4-flash" : void 0
|
|
5548
|
+
})
|
|
5549
|
+
};
|
|
5465
5550
|
history.turns.length = 0;
|
|
5466
5551
|
history.currentRole = null;
|
|
5467
5552
|
history.currentContent = "";
|
|
@@ -5478,7 +5563,7 @@ async function startTuiWorkspace(options) {
|
|
|
5478
5563
|
}
|
|
5479
5564
|
if (result.action?.type === "compact") {
|
|
5480
5565
|
const runner = options.compactRunner ?? compactDialog;
|
|
5481
|
-
const authToken = options.env
|
|
5566
|
+
const authToken = resolvePlatformAuthToken(options.env ?? {});
|
|
5482
5567
|
try {
|
|
5483
5568
|
const compactResult = await runner({
|
|
5484
5569
|
serverUrl: state.serverUrl,
|
|
@@ -5521,6 +5606,19 @@ async function startTuiWorkspace(options) {
|
|
|
5521
5606
|
output.write("Update failed. Check the error above, then run /update again or use nolo update.\n");
|
|
5522
5607
|
}
|
|
5523
5608
|
}
|
|
5609
|
+
if (result.action?.type === "theme-refresh") {
|
|
5610
|
+
const detected2 = await detectTerminalBackground({
|
|
5611
|
+
stdin: input,
|
|
5612
|
+
stdout: output
|
|
5613
|
+
});
|
|
5614
|
+
if (detected2 && applyDetectedBackground(detected2)) {
|
|
5615
|
+
emitCommandOutput(t("themeRefreshed", detected2.brightness));
|
|
5616
|
+
} else if (detected2) {
|
|
5617
|
+
emitCommandOutput(t("themeRefreshed", detected2.brightness));
|
|
5618
|
+
} else {
|
|
5619
|
+
emitCommandOutput(t("themeRefreshFailed"));
|
|
5620
|
+
}
|
|
5621
|
+
}
|
|
5524
5622
|
if (result.action?.type === "pick-agent") {
|
|
5525
5623
|
try {
|
|
5526
5624
|
const pickResult = await dialogHost.run(
|
|
@@ -5648,7 +5746,7 @@ async function startTuiWorkspace(options) {
|
|
|
5648
5746
|
...state,
|
|
5649
5747
|
dialogId: pickResult.dialog.id,
|
|
5650
5748
|
dialogKey: pickResult.dialog.dbKey,
|
|
5651
|
-
dialogLabel: pickResult.dialog.id,
|
|
5749
|
+
dialogLabel: pickResult.dialog.title || pickResult.dialog.id,
|
|
5652
5750
|
turnTokens: void 0
|
|
5653
5751
|
};
|
|
5654
5752
|
clearCollapsedPasteStore(pasteStore);
|
|
@@ -5777,6 +5875,10 @@ ${err.message}` : ""}`
|
|
|
5777
5875
|
let done = false;
|
|
5778
5876
|
let resolveDone = null;
|
|
5779
5877
|
fixedInput = createFixedInput(output, {
|
|
5878
|
+
getTitleLine: () => {
|
|
5879
|
+
const title = state.dialogLabel?.trim();
|
|
5880
|
+
return title ? themeText(`\u{1F4AC} ${title}`, "accent", resolveCliColorEnabled()) : null;
|
|
5881
|
+
},
|
|
5780
5882
|
getStatusLine: () => {
|
|
5781
5883
|
let base = renderStatusLine(state);
|
|
5782
5884
|
if (chatQueueBinding && chatQueueBinding.queueLength() > 0) {
|
|
@@ -5831,6 +5933,10 @@ ${err.message}` : ""}`
|
|
|
5831
5933
|
if (done) return;
|
|
5832
5934
|
done = true;
|
|
5833
5935
|
sessionEnded = true;
|
|
5936
|
+
if (autoThemeTimer !== null) {
|
|
5937
|
+
clearInterval(autoThemeTimer);
|
|
5938
|
+
autoThemeTimer = null;
|
|
5939
|
+
}
|
|
5834
5940
|
resolveDone?.();
|
|
5835
5941
|
clearCollapsedPasteStore(pasteStore);
|
|
5836
5942
|
resizeTarget.off?.("resize", onResize);
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import {
|
|
2
2
|
cleanupCliSessionForDialog
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-JS33TCQ3.js";
|
|
4
4
|
import {
|
|
5
5
|
getPrimaryDialogAgentId,
|
|
6
6
|
removeDialogAgentId
|
|
@@ -12,19 +12,19 @@ import "./chunk-BYXBJQAS.js";
|
|
|
12
12
|
import {
|
|
13
13
|
getActiveDialogKey
|
|
14
14
|
} from "./chunk-3ASDTTEI.js";
|
|
15
|
-
import "./chunk-
|
|
15
|
+
import "./chunk-TTGAVETO.js";
|
|
16
16
|
import "./chunk-Y5GCAMGP.js";
|
|
17
17
|
import "./chunk-KX6YBIHG.js";
|
|
18
18
|
import {
|
|
19
19
|
patch,
|
|
20
20
|
selectById
|
|
21
|
-
} from "./chunk-
|
|
21
|
+
} from "./chunk-SFXYKGK2.js";
|
|
22
22
|
import "./chunk-O4BU24WZ.js";
|
|
23
23
|
import "./chunk-I42VC5KR.js";
|
|
24
24
|
import "./chunk-WWC7I6TA.js";
|
|
25
25
|
import "./chunk-JTINRTBT.js";
|
|
26
26
|
import "./chunk-QSJ3HFEF.js";
|
|
27
|
-
import "./chunk-
|
|
27
|
+
import "./chunk-VPTJB4HM.js";
|
|
28
28
|
import "./chunk-DVRHHFEA.js";
|
|
29
29
|
import "./chunk-OOSFSFMA.js";
|
|
30
30
|
import "./chunk-GBRG75BQ.js";
|