nolo-cli 0.33.0-alpha.21 → 0.33.0-alpha.23
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-XKWVTZAY.js → _executeModel-C7G6UGVX.js} +21 -18
- package/{agentDeleteCommand-ZU4H6F6M.js → agentDeleteCommand-7T2AQL7Q.js} +24 -21
- package/{agentEmailCommands-6ULFXW4A.js → agentEmailCommands-M22DG56U.js} +37 -34
- package/{agentListCommands-VN7WCW7Z.js → agentListCommands-HDSQVOTR.js} +23 -20
- package/{agentMachineCommands-5PALVQBD.js → agentMachineCommands-B7HAFERS.js} +22 -19
- package/{agentRecordCommands-XEB66KRX.js → agentRecordCommands-DNEOXRTE.js} +28 -25
- package/{agentRunCommand-OJX27NII.js → agentRunCommand-G55YHYDL.js} +30 -27
- package/{agentRuntimeLocal-UWDOE55A.js → agentRuntimeLocal-YQGVUJ57.js} +10 -7
- package/{agentSlice-SZRRJ3ZX.js → agentSlice-A56VMSUG.js} +1 -1
- package/{appDeleteCommands-R63PZAY7.js → appDeleteCommands-57GIWQQ5.js} +17 -14
- package/{appDeployCommands-VNRT54YO.js → appDeployCommands-7IMZSUMQ.js} +17 -14
- package/{appDeployStatusCommands-6IPTKLEM.js → appDeployStatusCommands-ZNCK7TDT.js} +17 -14
- package/{appGetCommands-JPFVMVAI.js → appGetCommands-AZ4JVCGY.js} +17 -14
- package/{appListCommands-B3SLTPII.js → appListCommands-ABRHLEL7.js} +17 -14
- package/{authCommand-EX5G5PF4.js → authCommand-T5XN3VP2.js} +10 -10
- package/{authCommands-VR6Q6GU2.js → authCommands-W74NRPA6.js} +5 -5
- package/{chatQueueReduxAdapter-IEX32ZVP.js → chatQueueReduxAdapter-7CKSPWO5.js} +5 -5
- package/{chunk-XS543SNR.js → chunk-25MFIHEP.js} +3 -3
- package/{chunk-V4MT7AEN.js → chunk-3CVNNFKF.js} +7 -7
- package/chunk-3Z32AD6X.js +22 -0
- package/{chunk-PU47HKTF.js → chunk-3Z7GNZLS.js} +13 -13
- package/{chunk-XTSVOICC.js → chunk-4LSQNSXE.js} +25 -25
- package/{chunk-IHEC7VBF.js → chunk-4ZPH5WGJ.js} +1 -1
- package/{chunk-6MSSX7FI.js → chunk-AMKT2XOP.js} +2 -2
- package/{chunk-EQ6HOWEJ.js → chunk-EF36FMUE.js} +1 -1
- package/{chunk-SBPGB6TF.js → chunk-G3ONB6Y5.js} +5 -5
- package/{chunk-U2FRXKC7.js → chunk-JSIQQCPR.js} +1 -1
- package/{chunk-46JSKTPF.js → chunk-MIN2TNAM.js} +293 -64
- package/{chunk-LLKHGZME.js → chunk-O3LO3MRU.js} +13 -13
- package/{chunk-LJGEEYGC.js → chunk-OA7LCLY3.js} +1 -1
- package/{chunk-37LDAHQN.js → chunk-OH6MOEZN.js} +10 -10
- package/{chunk-REOW4YJX.js → chunk-OLFLSOUV.js} +5 -5
- package/{chunk-2UDMTJOM.js → chunk-PFJA4C7K.js} +13 -13
- package/{chunk-7BNPRRDS.js → chunk-R7UWXBVG.js} +21 -21
- package/{chunk-YH3FPBG6.js → chunk-SEFDSJK4.js} +321 -4
- package/chunk-TVXJEOU2.js +78 -0
- package/{chunk-GTEHJWXU.js → chunk-TZV6ELNR.js} +1 -1
- package/{chunk-RO3AEN3L.js → chunk-UCUCOZXY.js} +2 -2
- package/chunk-UOLENXLQ.js +1132 -0
- package/{chunk-M2YMQOLC.js → chunk-WHLQYPJZ.js} +12 -12
- package/{chunk-V44VE7R4.js → chunk-XLUTBJYU.js} +4 -4
- package/{chunk-JL2PUYVS.js → chunk-YBWR3WBJ.js} +12 -12
- package/{cliExecutor-DW3PHGEL.js → cliExecutor-BBUVQU4L.js} +2 -2
- package/{createAgentAutomationAction-72NNXELT.js → createAgentAutomationAction-YTMO34HZ.js} +6 -6
- package/{createDialogAction-3CJ2GXNO.js → createDialogAction-3B3FT7Y7.js} +7 -7
- package/{createPageAction-HZHQGQO6.js → createPageAction-WHUA54EI.js} +6 -6
- package/{dialogCommands-2BF4ZSWH.js → dialogCommands-OJYXBAR2.js} +16 -13
- package/{dialogSlice-5R4O4377.js → dialogSlice-S7CBGXUY.js} +5 -5
- package/{docCreateCommands-HMZUBFGL.js → docCreateCommands-LJPAIEMJ.js} +16 -13
- package/{docDeleteCommands-DFR7GCOR.js → docDeleteCommands-I7TIHWFQ.js} +17 -14
- package/{docReadCommands-YM7RDUAZ.js → docReadCommands-7RUZYEAA.js} +16 -13
- package/{docStore-A4SRW2DJ.js → docStore-YZACMKQG.js} +7 -7
- package/{docUpdateCommands-TTQBD7IU.js → docUpdateCommands-HTR5Y737.js} +16 -13
- package/emscripten-module-EDQBMDVK.js +576 -0
- package/emscripten-module-LCBQ7VWY.js +1506 -0
- package/emscripten-module-OFHQ7EL3.js +482 -0
- package/emscripten-module-XM7NDJQA.js +4536 -0
- package/ffi-6ZSX3QJ4.js +80 -0
- package/ffi-742Y76PE.js +92 -0
- package/ffi-AEYWSYLM.js +80 -0
- package/ffi-KQC27OUM.js +92 -0
- package/{handleSendMessageAction-CIFBZCI2.js → handleSendMessageAction-HJUPYPBF.js} +5 -5
- package/index.js +67 -67
- package/{machineCommands-QSW4JKR2.js → machineCommands-IJL73WA5.js} +39 -36
- package/{machineWsRunDispatch-X3ZC7DZJ.js → machineWsRunDispatch-7RE5KJRG.js} +26 -23
- package/module-ES6BEMUI-AFCVSBMS.js +14 -0
- package/module-asyncify-2EFITU5U-DEP2F2QP.js +9 -0
- package/package.json +1 -1
- package/{readlineWorkspace-J2ARMEUC.js → readlineWorkspace-EGSZ26XS.js} +196 -147
- package/{runAgentClientLoop-5I2R74NR.js → runAgentClientLoop-7OD74SBW.js} +12 -12
- package/{spaceCommands-EZYMMJJH.js → spaceCommands-5NCZJOOC.js} +23 -20
- package/{spaceSlice-TL2FR4AF.js → spaceSlice-KD2BB5GS.js} +6 -6
- package/{streamAgentChatTurn-UDYSE2ES.js → streamAgentChatTurn-LDQPG7A3.js} +32 -29
- package/{tools-KWYWDJ77.js → tools-XAC2C4LK.js} +10 -10
- package/{tuiSummaryLlmCaller-WUVAOIYU.js → tuiSummaryLlmCaller-LAOHMDTM.js} +3 -3
- package/{updateDialogTitleAction-NQCOEOLF.js → updateDialogTitleAction-PDIR5IVC.js} +8 -8
- package/{agentGrantCommands-2LEZDADN.js → agentGrantCommands-OPIGFRDO.js} +2 -2
- package/{agentPullCommand-TSWAJPS2.js → agentPullCommand-NYHSK6EW.js} +2 -2
- package/{chunk-YDTYDA5W.js → chunk-BY53PPQ2.js} +3 -3
- package/{chunk-HCOIKLSH.js → chunk-CP4QR2D2.js} +3 -3
- package/{chunk-ZHYK3N56.js → chunk-G7HTVVFL.js} +3 -3
- package/{chunk-SAQQLJZ5.js → chunk-JDSUTNYY.js} +3 -3
- package/{chunk-N2WDGMD5.js → chunk-N543Q3VR.js} +12 -12
- package/{offlineMarxistsAgentCommand-GEH6SNNA.js → offlineMarxistsAgentCommand-HDIQVGKN.js} +3 -3
- package/{runtimeDoctorCommands-KHGQKT3B.js → runtimeDoctorCommands-HT4O2PXL.js} +3 -3
- package/{tableCommands-64FZBAI3.js → tableCommands-5OKD2DKN.js} +8 -8
|
@@ -3,19 +3,7 @@ import {
|
|
|
3
3
|
normalizeDialogRecord,
|
|
4
4
|
readDialogSnapshot,
|
|
5
5
|
sortDialogs
|
|
6
|
-
} from "./chunk-
|
|
7
|
-
import {
|
|
8
|
-
listFavoriteAgentIdsAcrossServers,
|
|
9
|
-
listLocalCachedAgents,
|
|
10
|
-
listRemoteAgents,
|
|
11
|
-
listRemoteAgentsAcrossServers,
|
|
12
|
-
normalizeListedAgent
|
|
13
|
-
} from "./chunk-6MSSX7FI.js";
|
|
14
|
-
import "./chunk-ID4G2MAR.js";
|
|
15
|
-
import {
|
|
16
|
-
listUserRecordsFromServers,
|
|
17
|
-
readLiveDbRecordAfterTombstoneMerge
|
|
18
|
-
} from "./chunk-IHEC7VBF.js";
|
|
6
|
+
} from "./chunk-WHLQYPJZ.js";
|
|
19
7
|
import {
|
|
20
8
|
ANSI_ESCAPE_REGEX,
|
|
21
9
|
COLLAPSED_PASTE_PLACEHOLDER_RE,
|
|
@@ -73,16 +61,17 @@ import {
|
|
|
73
61
|
wrapTextToLines,
|
|
74
62
|
wrapTranscriptLine,
|
|
75
63
|
wrapTranscriptLineWithLayout
|
|
76
|
-
} from "./chunk-
|
|
77
|
-
import "./chunk-
|
|
78
|
-
import {
|
|
79
|
-
getReadableCliDb
|
|
80
|
-
} from "./chunk-UNHKVD2N.js";
|
|
64
|
+
} from "./chunk-MIN2TNAM.js";
|
|
65
|
+
import "./chunk-ESHYE7WU.js";
|
|
81
66
|
import {
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
67
|
+
listFavoriteAgentIdsAcrossServers,
|
|
68
|
+
listLocalCachedAgents,
|
|
69
|
+
listRemoteAgents,
|
|
70
|
+
listRemoteAgentsAcrossServers,
|
|
71
|
+
normalizeListedAgent
|
|
72
|
+
} from "./chunk-AMKT2XOP.js";
|
|
73
|
+
import "./chunk-ID4G2MAR.js";
|
|
74
|
+
import "./chunk-G7HTVVFL.js";
|
|
86
75
|
import {
|
|
87
76
|
createCliLocalRuntimeAdapter,
|
|
88
77
|
initCliLocale,
|
|
@@ -90,8 +79,20 @@ import {
|
|
|
90
79
|
readTimestamp,
|
|
91
80
|
setCliLocale,
|
|
92
81
|
t
|
|
93
|
-
} from "./chunk-
|
|
82
|
+
} from "./chunk-4LSQNSXE.js";
|
|
94
83
|
import "./chunk-IEHZHWN7.js";
|
|
84
|
+
import {
|
|
85
|
+
listUserRecordsFromServers,
|
|
86
|
+
readLiveDbRecordAfterTombstoneMerge
|
|
87
|
+
} from "./chunk-4ZPH5WGJ.js";
|
|
88
|
+
import {
|
|
89
|
+
getReadableCliDb
|
|
90
|
+
} from "./chunk-UNHKVD2N.js";
|
|
91
|
+
import {
|
|
92
|
+
deleteDbRecord,
|
|
93
|
+
queryUserRecords,
|
|
94
|
+
readDbRecord
|
|
95
|
+
} from "./chunk-BY53PPQ2.js";
|
|
95
96
|
import "./chunk-X2DAEZ3X.js";
|
|
96
97
|
import {
|
|
97
98
|
NOLO_DEFAULT_AGENT_KEY,
|
|
@@ -99,42 +100,46 @@ import {
|
|
|
99
100
|
} from "./chunk-EKLRRZIN.js";
|
|
100
101
|
import "./chunk-LTRXGFMS.js";
|
|
101
102
|
import "./chunk-7OGIWPNK.js";
|
|
102
|
-
import "./chunk-ESHYE7WU.js";
|
|
103
103
|
import "./chunk-JEXVIMYZ.js";
|
|
104
104
|
import {
|
|
105
105
|
prepareTools
|
|
106
|
-
} from "./chunk-
|
|
106
|
+
} from "./chunk-OA7LCLY3.js";
|
|
107
107
|
import "./chunk-HS7MLR74.js";
|
|
108
108
|
import "./chunk-LAZTMWIU.js";
|
|
109
|
-
import "./chunk-
|
|
109
|
+
import "./chunk-R7UWXBVG.js";
|
|
110
110
|
import "./chunk-RQSOAMPJ.js";
|
|
111
111
|
import "./chunk-BHILFABL.js";
|
|
112
112
|
import "./chunk-KQHGZWSV.js";
|
|
113
113
|
import "./chunk-KIL7V27H.js";
|
|
114
|
+
import "./chunk-L5XKDBSH.js";
|
|
114
115
|
import "./chunk-INZZJSQF.js";
|
|
115
116
|
import "./chunk-GM6PU7B6.js";
|
|
116
117
|
import "./chunk-63W5N6P3.js";
|
|
117
118
|
import "./chunk-VF4K2QE6.js";
|
|
118
|
-
import "./chunk-
|
|
119
|
-
import "./chunk-
|
|
119
|
+
import "./chunk-G3ONB6Y5.js";
|
|
120
|
+
import "./chunk-UCUCOZXY.js";
|
|
121
|
+
import "./chunk-JDSUTNYY.js";
|
|
122
|
+
import "./chunk-JBTJAPUF.js";
|
|
123
|
+
import "./chunk-ATNTHIZI.js";
|
|
124
|
+
import "./chunk-URMS4XY2.js";
|
|
120
125
|
import "./chunk-N4XRDM26.js";
|
|
126
|
+
import "./chunk-LM6IYQ3F.js";
|
|
121
127
|
import {
|
|
122
128
|
createChatQueueRuntime,
|
|
123
129
|
createTurnRequest,
|
|
124
130
|
normalizeRunCompletionShape
|
|
125
131
|
} from "./chunk-RY57GLGW.js";
|
|
126
|
-
import "./chunk-
|
|
127
|
-
import "./chunk-2UDMTJOM.js";
|
|
132
|
+
import "./chunk-PFJA4C7K.js";
|
|
128
133
|
import "./chunk-M3JEW6N6.js";
|
|
129
134
|
import "./chunk-IDAU4UFS.js";
|
|
130
135
|
import {
|
|
131
136
|
extractReferenceKeysFromMessage
|
|
132
|
-
} from "./chunk-
|
|
137
|
+
} from "./chunk-YBWR3WBJ.js";
|
|
133
138
|
import "./chunk-RCFIB45Q.js";
|
|
134
139
|
import "./chunk-EGRJC4ZN.js";
|
|
135
140
|
import "./chunk-YYLHWIW6.js";
|
|
136
141
|
import "./chunk-CWMSB67P.js";
|
|
137
|
-
import "./chunk-
|
|
142
|
+
import "./chunk-25MFIHEP.js";
|
|
138
143
|
import "./chunk-FH7VUJN5.js";
|
|
139
144
|
import "./chunk-5RGU3J7P.js";
|
|
140
145
|
import "./chunk-M76ECQRD.js";
|
|
@@ -142,15 +147,15 @@ import "./chunk-KSRFVP36.js";
|
|
|
142
147
|
import {
|
|
143
148
|
buildLocalWorkspaceOpenAiTools,
|
|
144
149
|
buildLocalWorkspaceToolset
|
|
145
|
-
} from "./chunk-
|
|
150
|
+
} from "./chunk-OLFLSOUV.js";
|
|
151
|
+
import "./chunk-EF36FMUE.js";
|
|
146
152
|
import "./chunk-ZNFJWEN4.js";
|
|
147
|
-
import "./chunk-EQ6HOWEJ.js";
|
|
148
153
|
import "./chunk-OIQPORYI.js";
|
|
149
154
|
import "./chunk-T27IEBNQ.js";
|
|
150
155
|
import {
|
|
151
156
|
getProcessRegistry,
|
|
152
157
|
readCommandActionGatePayload
|
|
153
|
-
} from "./chunk-
|
|
158
|
+
} from "./chunk-SEFDSJK4.js";
|
|
154
159
|
import "./chunk-N7J63Q6C.js";
|
|
155
160
|
import {
|
|
156
161
|
buildCurrentTimeBlock,
|
|
@@ -178,12 +183,16 @@ import {
|
|
|
178
183
|
formatMessagesForSummaryWithTruncation,
|
|
179
184
|
planCompression,
|
|
180
185
|
serializeMessageContent
|
|
181
|
-
} from "./chunk-
|
|
186
|
+
} from "./chunk-CP4QR2D2.js";
|
|
182
187
|
import "./chunk-VIRTYWWE.js";
|
|
183
188
|
import "./chunk-7SLMYTSF.js";
|
|
184
189
|
import "./chunk-RQFO3CAF.js";
|
|
185
190
|
import "./chunk-QTZD6HBK.js";
|
|
186
191
|
import "./chunk-ZHXJ6M7T.js";
|
|
192
|
+
import {
|
|
193
|
+
toErrorMessage
|
|
194
|
+
} from "./chunk-HNMXYYJR.js";
|
|
195
|
+
import "./chunk-KMMQFY5O.js";
|
|
187
196
|
import {
|
|
188
197
|
buildSkillDiscoveryContextBlock,
|
|
189
198
|
buildSkillDiscoveryContextLayer
|
|
@@ -228,38 +237,6 @@ import {
|
|
|
228
237
|
runShowsLogTail,
|
|
229
238
|
shortRunId
|
|
230
239
|
} from "./chunk-KXKQO4Q6.js";
|
|
231
|
-
import "./chunk-SAQQLJZ5.js";
|
|
232
|
-
import "./chunk-ATNTHIZI.js";
|
|
233
|
-
import "./chunk-JBTJAPUF.js";
|
|
234
|
-
import "./chunk-URMS4XY2.js";
|
|
235
|
-
import "./chunk-LM6IYQ3F.js";
|
|
236
|
-
import {
|
|
237
|
-
toErrorMessage
|
|
238
|
-
} from "./chunk-HNMXYYJR.js";
|
|
239
|
-
import {
|
|
240
|
-
checkForCliUpdate,
|
|
241
|
-
runSelfUpdate
|
|
242
|
-
} from "./chunk-VFVCYIRQ.js";
|
|
243
|
-
import {
|
|
244
|
-
getAgentSelectionAuditPath,
|
|
245
|
-
getDefaultProfileConfigPath,
|
|
246
|
-
readLastAgentSelectionAudit,
|
|
247
|
-
saveProfileAgentSelection,
|
|
248
|
-
saveProfileLocale
|
|
249
|
-
} from "./chunk-UNZDCI3O.js";
|
|
250
|
-
import {
|
|
251
|
-
readPipeText,
|
|
252
|
-
spawnProcess
|
|
253
|
-
} from "./chunk-IDZTNRP2.js";
|
|
254
|
-
import {
|
|
255
|
-
parseUserIdFromAuthToken,
|
|
256
|
-
resolveAuthToken,
|
|
257
|
-
resolveServerCandidates,
|
|
258
|
-
resolveServerUrl
|
|
259
|
-
} from "./chunk-A7GB5UGH.js";
|
|
260
|
-
import {
|
|
261
|
-
DEFAULT_NOLO_SERVER_URL
|
|
262
|
-
} from "./chunk-OLZBQWZU.js";
|
|
263
240
|
import "./chunk-JFUW3UTO.js";
|
|
264
241
|
import "./chunk-7EPNNOL4.js";
|
|
265
242
|
import "./chunk-DDET6246.js";
|
|
@@ -267,7 +244,6 @@ import "./chunk-QKCMP3LU.js";
|
|
|
267
244
|
import "./chunk-Y5GCAMGP.js";
|
|
268
245
|
import "./chunk-KX6YBIHG.js";
|
|
269
246
|
import "./chunk-UZ6XXCVR.js";
|
|
270
|
-
import "./chunk-KMMQFY5O.js";
|
|
271
247
|
import "./chunk-6YH4UR3E.js";
|
|
272
248
|
import "./chunk-KMSZPTM6.js";
|
|
273
249
|
import "./chunk-BQXOGBFN.js";
|
|
@@ -293,12 +269,39 @@ import {
|
|
|
293
269
|
parsePublicAgentId
|
|
294
270
|
} from "./chunk-BJIRLHJR.js";
|
|
295
271
|
import "./chunk-KUG52IAP.js";
|
|
272
|
+
import {
|
|
273
|
+
checkForCliUpdate,
|
|
274
|
+
runSelfUpdate
|
|
275
|
+
} from "./chunk-VFVCYIRQ.js";
|
|
276
|
+
import {
|
|
277
|
+
getAgentSelectionAuditPath,
|
|
278
|
+
getDefaultProfileConfigPath,
|
|
279
|
+
readLastAgentSelectionAudit,
|
|
280
|
+
saveProfileAgentSelection,
|
|
281
|
+
saveProfileLocale
|
|
282
|
+
} from "./chunk-UNZDCI3O.js";
|
|
283
|
+
import {
|
|
284
|
+
readPipeText,
|
|
285
|
+
spawnProcess
|
|
286
|
+
} from "./chunk-IDZTNRP2.js";
|
|
287
|
+
import {
|
|
288
|
+
parseUserIdFromAuthToken,
|
|
289
|
+
resolveAuthToken,
|
|
290
|
+
resolveServerCandidates,
|
|
291
|
+
resolveServerUrl
|
|
292
|
+
} from "./chunk-A7GB5UGH.js";
|
|
293
|
+
import {
|
|
294
|
+
DEFAULT_NOLO_SERVER_URL
|
|
295
|
+
} from "./chunk-OLZBQWZU.js";
|
|
296
296
|
import "./chunk-LCBAMY2M.js";
|
|
297
297
|
import "./chunk-4SN6J65J.js";
|
|
298
298
|
import "./chunk-CF7PE763.js";
|
|
299
299
|
import {
|
|
300
300
|
asOptionalTrimmedString
|
|
301
301
|
} from "./chunk-G3SUCT4W.js";
|
|
302
|
+
import "./chunk-TVXJEOU2.js";
|
|
303
|
+
import "./chunk-UOLENXLQ.js";
|
|
304
|
+
import "./chunk-3Z32AD6X.js";
|
|
302
305
|
import "./chunk-4VNS5WPM.js";
|
|
303
306
|
|
|
304
307
|
// packages/cli/tui/readlineWorkspace.ts
|
|
@@ -1767,22 +1770,15 @@ function areSelectionPointsEqual(a, b) {
|
|
|
1767
1770
|
if (a === null || b === null) return false;
|
|
1768
1771
|
return a.globalRow === b.globalRow && a.col === b.col;
|
|
1769
1772
|
}
|
|
1770
|
-
function highlightLineByColumns(line, selStartCol, selEndCol) {
|
|
1771
|
-
if (selStartCol >= selEndCol) return line;
|
|
1773
|
+
function highlightLineByColumns(line, selStartCol, selEndCol, prefixWidth = 0) {
|
|
1772
1774
|
const tokens = tokenizeAnsiLine(line);
|
|
1773
|
-
|
|
1774
|
-
|
|
1775
|
-
|
|
1776
|
-
|
|
1777
|
-
|
|
1778
|
-
|
|
1779
|
-
|
|
1780
|
-
}
|
|
1781
|
-
colScan += tok.width;
|
|
1782
|
-
}
|
|
1783
|
-
}
|
|
1784
|
-
const effectiveEndCol = Math.min(selEndCol, lastNonSpaceCol);
|
|
1785
|
-
if (selStartCol >= effectiveEndCol) return line;
|
|
1775
|
+
const range = resolveSelectableColumnRange(
|
|
1776
|
+
tokens,
|
|
1777
|
+
selStartCol,
|
|
1778
|
+
selEndCol,
|
|
1779
|
+
prefixWidth
|
|
1780
|
+
);
|
|
1781
|
+
if (!range) return line;
|
|
1786
1782
|
let out = "";
|
|
1787
1783
|
let currentCol = 0;
|
|
1788
1784
|
let isHighlightActive = false;
|
|
@@ -1802,7 +1798,7 @@ function highlightLineByColumns(line, selStartCol, selEndCol) {
|
|
|
1802
1798
|
}
|
|
1803
1799
|
const charStartCol = currentCol;
|
|
1804
1800
|
const charEndCol = currentCol + token.width;
|
|
1805
|
-
const isSelected = charStartCol >=
|
|
1801
|
+
const isSelected = charStartCol >= range.start && charStartCol < range.end;
|
|
1806
1802
|
if (isSelected && !isHighlightActive) {
|
|
1807
1803
|
out += "\x1B[7m";
|
|
1808
1804
|
isHighlightActive = true;
|
|
@@ -1818,56 +1814,71 @@ function highlightLineByColumns(line, selStartCol, selEndCol) {
|
|
|
1818
1814
|
}
|
|
1819
1815
|
return out;
|
|
1820
1816
|
}
|
|
1817
|
+
function resolveSelectableColumnRange(tokens, requestedStart, requestedEnd, prefixWidth) {
|
|
1818
|
+
if (requestedStart >= requestedEnd) return null;
|
|
1819
|
+
let col = 0;
|
|
1820
|
+
let lastNonSpaceCol = 0;
|
|
1821
|
+
for (const token of tokens) {
|
|
1822
|
+
if (token.kind !== "char") continue;
|
|
1823
|
+
if (token.value.trim().length > 0) {
|
|
1824
|
+
lastNonSpaceCol = col + token.width;
|
|
1825
|
+
}
|
|
1826
|
+
col += token.width;
|
|
1827
|
+
}
|
|
1828
|
+
const start = Math.max(prefixWidth, requestedStart);
|
|
1829
|
+
const end = Math.min(requestedEnd, lastNonSpaceCol);
|
|
1830
|
+
if (start >= end) return null;
|
|
1831
|
+
let snappedStart = null;
|
|
1832
|
+
let snappedEnd = null;
|
|
1833
|
+
col = 0;
|
|
1834
|
+
for (const token of tokens) {
|
|
1835
|
+
if (token.kind !== "char") continue;
|
|
1836
|
+
const tokenStart = col;
|
|
1837
|
+
const tokenEnd = col + token.width;
|
|
1838
|
+
if (tokenEnd > start && tokenStart < end) {
|
|
1839
|
+
snappedStart ??= tokenStart;
|
|
1840
|
+
snappedEnd = tokenEnd;
|
|
1841
|
+
}
|
|
1842
|
+
col = tokenEnd;
|
|
1843
|
+
}
|
|
1844
|
+
return snappedStart === null || snappedEnd === null ? null : { start: snappedStart, end: snappedEnd };
|
|
1845
|
+
}
|
|
1821
1846
|
function hitTestHistory(history, screenRow, screenCol, _contentWidth, scrollTop) {
|
|
1822
1847
|
const globalRow = Math.max(0, scrollTop + screenRow);
|
|
1823
1848
|
const col = Math.max(0, screenCol);
|
|
1824
1849
|
return { globalRow, col };
|
|
1825
1850
|
}
|
|
1826
|
-
function extractTextSliceByColumns(
|
|
1827
|
-
|
|
1828
|
-
|
|
1829
|
-
|
|
1830
|
-
|
|
1831
|
-
|
|
1832
|
-
|
|
1833
|
-
|
|
1834
|
-
|
|
1835
|
-
} else if (text.startsWith("\u203A ")) {
|
|
1836
|
-
text = text.slice(2);
|
|
1837
|
-
textStartCol = 2;
|
|
1838
|
-
}
|
|
1839
|
-
const effectiveStart = Math.max(0, startCol - textStartCol);
|
|
1840
|
-
const effectiveEnd = Math.max(0, endCol - textStartCol);
|
|
1841
|
-
if (effectiveStart >= effectiveEnd) return "";
|
|
1842
|
-
let out = "";
|
|
1851
|
+
function extractTextSliceByColumns(line, startCol, endCol, prefixWidth = 0) {
|
|
1852
|
+
const tokens = tokenizeAnsiLine(line);
|
|
1853
|
+
const range = resolveSelectableColumnRange(
|
|
1854
|
+
tokens,
|
|
1855
|
+
startCol,
|
|
1856
|
+
endCol,
|
|
1857
|
+
prefixWidth
|
|
1858
|
+
);
|
|
1859
|
+
if (!range) return "";
|
|
1843
1860
|
let col = 0;
|
|
1844
|
-
|
|
1845
|
-
|
|
1846
|
-
if (
|
|
1847
|
-
|
|
1861
|
+
let text = "";
|
|
1862
|
+
for (const token of tokens) {
|
|
1863
|
+
if (token.kind !== "char") continue;
|
|
1864
|
+
if (col >= range.start && col < range.end) {
|
|
1865
|
+
text += token.value;
|
|
1848
1866
|
}
|
|
1849
|
-
col +=
|
|
1867
|
+
col += token.width;
|
|
1850
1868
|
}
|
|
1851
|
-
return
|
|
1869
|
+
return text;
|
|
1852
1870
|
}
|
|
1853
|
-
function extractSelectedText(history, anchor, head, contentWidth
|
|
1871
|
+
function extractSelectedText(history, anchor, head, contentWidth) {
|
|
1854
1872
|
if (!anchor || !head) return "";
|
|
1855
1873
|
const cmp = compareSelectionPoints(anchor, head);
|
|
1856
1874
|
if (cmp === 0) return "";
|
|
1857
1875
|
const start = cmp < 0 ? anchor : head;
|
|
1858
1876
|
const end = cmp < 0 ? head : anchor;
|
|
1859
|
-
const
|
|
1860
|
-
const
|
|
1877
|
+
const rows = buildHistoryLayoutRows(history, contentWidth);
|
|
1878
|
+
const pieces = [];
|
|
1861
1879
|
for (let r = start.globalRow; r <= end.globalRow; r++) {
|
|
1862
|
-
const
|
|
1863
|
-
if (
|
|
1864
|
-
const plain = stripAnsi(rawLine);
|
|
1865
|
-
if (plain.trim().length === 0) {
|
|
1866
|
-
if (selectedLines.length > 0 && selectedLines[selectedLines.length - 1] !== "") {
|
|
1867
|
-
selectedLines.push("");
|
|
1868
|
-
}
|
|
1869
|
-
continue;
|
|
1870
|
-
}
|
|
1880
|
+
const row = rows[r];
|
|
1881
|
+
if (!row) continue;
|
|
1871
1882
|
let lineStartCol = 0;
|
|
1872
1883
|
let lineEndCol = Infinity;
|
|
1873
1884
|
if (r === start.globalRow) {
|
|
@@ -1876,14 +1887,21 @@ function extractSelectedText(history, anchor, head, contentWidth = 80) {
|
|
|
1876
1887
|
if (r === end.globalRow) {
|
|
1877
1888
|
lineEndCol = end.col;
|
|
1878
1889
|
}
|
|
1879
|
-
|
|
1880
|
-
|
|
1881
|
-
|
|
1890
|
+
pieces.push(
|
|
1891
|
+
extractTextSliceByColumns(
|
|
1892
|
+
row.rendered,
|
|
1893
|
+
lineStartCol,
|
|
1894
|
+
lineEndCol,
|
|
1895
|
+
row.prefixWidth
|
|
1896
|
+
)
|
|
1897
|
+
);
|
|
1898
|
+
if (r < end.globalRow) {
|
|
1899
|
+
pieces.push(row.softWrapped ? row.softWrapJoiner ?? "" : "\n");
|
|
1882
1900
|
}
|
|
1883
1901
|
}
|
|
1884
|
-
return
|
|
1902
|
+
return pieces.join("");
|
|
1885
1903
|
}
|
|
1886
|
-
function applySelectionOverlay(visibleLines,
|
|
1904
|
+
function applySelectionOverlay(visibleLines, history, contentWidth, scrollTop, selection) {
|
|
1887
1905
|
if (!selection.anchor || !selection.head) {
|
|
1888
1906
|
return visibleLines;
|
|
1889
1907
|
}
|
|
@@ -1891,6 +1909,7 @@ function applySelectionOverlay(visibleLines, _history, _contentWidth, scrollTop,
|
|
|
1891
1909
|
if (cmp === 0) return visibleLines;
|
|
1892
1910
|
const start = cmp < 0 ? selection.anchor : selection.head;
|
|
1893
1911
|
const end = cmp < 0 ? selection.head : selection.anchor;
|
|
1912
|
+
const layoutRows = buildHistoryLayoutRows(history, contentWidth);
|
|
1894
1913
|
const result = [...visibleLines];
|
|
1895
1914
|
for (let screenRow = 0; screenRow < visibleLines.length; screenRow++) {
|
|
1896
1915
|
const globalRow = scrollTop + screenRow;
|
|
@@ -1899,6 +1918,7 @@ function applySelectionOverlay(visibleLines, _history, _contentWidth, scrollTop,
|
|
|
1899
1918
|
}
|
|
1900
1919
|
const currentLine = result[screenRow] ?? "";
|
|
1901
1920
|
if (currentLine.length === 0) continue;
|
|
1921
|
+
const layoutRow = layoutRows[globalRow];
|
|
1902
1922
|
let selStartCol = 0;
|
|
1903
1923
|
let selEndCol = Infinity;
|
|
1904
1924
|
if (globalRow === start.globalRow) {
|
|
@@ -1910,7 +1930,8 @@ function applySelectionOverlay(visibleLines, _history, _contentWidth, scrollTop,
|
|
|
1910
1930
|
result[screenRow] = highlightLineByColumns(
|
|
1911
1931
|
currentLine,
|
|
1912
1932
|
selStartCol,
|
|
1913
|
-
selEndCol
|
|
1933
|
+
selEndCol,
|
|
1934
|
+
layoutRow?.prefixWidth ?? 0
|
|
1914
1935
|
);
|
|
1915
1936
|
}
|
|
1916
1937
|
return result;
|
|
@@ -2031,7 +2052,9 @@ function layoutTurnRows(role, content, contentWidth, colorEnabled, command) {
|
|
|
2031
2052
|
sourceStart: r.sourceStart,
|
|
2032
2053
|
sourceEnd: r.sourceEnd,
|
|
2033
2054
|
prefixWidth: r.prefixWidth,
|
|
2034
|
-
sourceMapping: r.sourceMapping
|
|
2055
|
+
sourceMapping: r.sourceMapping,
|
|
2056
|
+
softWrapped: r.softWrapped,
|
|
2057
|
+
softWrapJoiner: r.softWrapJoiner
|
|
2035
2058
|
});
|
|
2036
2059
|
}
|
|
2037
2060
|
lineSourceStart += line.length + 1;
|
|
@@ -2059,7 +2082,9 @@ function layoutTurnRows(role, content, contentWidth, colorEnabled, command) {
|
|
|
2059
2082
|
sourceStart: 0,
|
|
2060
2083
|
sourceEnd: 0,
|
|
2061
2084
|
prefixWidth: 2,
|
|
2062
|
-
sourceMapping: void 0
|
|
2085
|
+
sourceMapping: void 0,
|
|
2086
|
+
softWrapped: r.softWrapped,
|
|
2087
|
+
softWrapJoiner: r.softWrapJoiner
|
|
2063
2088
|
});
|
|
2064
2089
|
}
|
|
2065
2090
|
}
|
|
@@ -2329,35 +2354,39 @@ function buildCopyViewLines(history) {
|
|
|
2329
2354
|
}
|
|
2330
2355
|
return lines;
|
|
2331
2356
|
}
|
|
2332
|
-
function
|
|
2357
|
+
function buildHistoryLayoutRows(history, contentWidth) {
|
|
2333
2358
|
const colorEnabled = resolveCliColorEnabled();
|
|
2334
2359
|
const density = getActiveDensity();
|
|
2335
2360
|
const surface = colorEnabled ? userSurfaceBackgroundSequence() : "";
|
|
2336
|
-
const
|
|
2361
|
+
const rows = [];
|
|
2362
|
+
const separatorRow = () => ({
|
|
2363
|
+
rendered: "",
|
|
2364
|
+
sourceStart: 0,
|
|
2365
|
+
sourceEnd: 0,
|
|
2366
|
+
prefixWidth: 0
|
|
2367
|
+
});
|
|
2337
2368
|
for (let i = 0; i < history.turns.length; i++) {
|
|
2338
2369
|
const turn = history.turns[i];
|
|
2339
2370
|
if (density === "spacious" && (i > 0 || turn.role === "user")) {
|
|
2340
|
-
|
|
2371
|
+
rows.push(separatorRow());
|
|
2341
2372
|
}
|
|
2342
|
-
|
|
2343
|
-
wrapped.push(...layoutRows.map((r) => r.rendered));
|
|
2373
|
+
rows.push(...getTurnLayoutRows(turn, contentWidth, colorEnabled, density, surface));
|
|
2344
2374
|
}
|
|
2345
2375
|
if (history.currentRole !== null && history.currentContent) {
|
|
2346
2376
|
const i = history.turns.length;
|
|
2347
2377
|
if (density === "spacious" && (i > 0 || history.currentRole === "user")) {
|
|
2348
|
-
|
|
2378
|
+
rows.push(separatorRow());
|
|
2349
2379
|
}
|
|
2350
|
-
|
|
2351
|
-
|
|
2352
|
-
|
|
2353
|
-
|
|
2354
|
-
|
|
2355
|
-
|
|
2356
|
-
|
|
2380
|
+
rows.push(
|
|
2381
|
+
...layoutTurnRows(
|
|
2382
|
+
history.currentRole,
|
|
2383
|
+
history.currentContent,
|
|
2384
|
+
contentWidth,
|
|
2385
|
+
colorEnabled
|
|
2386
|
+
)
|
|
2357
2387
|
);
|
|
2358
|
-
wrapped.push(...streamingLines);
|
|
2359
2388
|
}
|
|
2360
|
-
return
|
|
2389
|
+
return rows;
|
|
2361
2390
|
}
|
|
2362
2391
|
var renderCacheMissCount = 0;
|
|
2363
2392
|
function renderHistory(output, history, inputLines, selection) {
|
|
@@ -6392,6 +6421,10 @@ async function startTuiWorkspace(options) {
|
|
|
6392
6421
|
const output = options.output ?? defaultOutput;
|
|
6393
6422
|
const fetchImpl = options.fetchImpl ?? fetch;
|
|
6394
6423
|
const spawnRunner = options.spawnRunner ?? spawnProcess;
|
|
6424
|
+
const writeClipboard = options.clipboardWriter ?? (async (text) => {
|
|
6425
|
+
const { default: clipboard } = await import("./clipboardy-MMBYVRLF.js");
|
|
6426
|
+
await clipboard.write(text);
|
|
6427
|
+
});
|
|
6395
6428
|
const selfUpdater = options.selfUpdater ?? ((target) => runSelfUpdate({ output: target }));
|
|
6396
6429
|
if (output.isTTY) {
|
|
6397
6430
|
enterAltScreen(output);
|
|
@@ -7128,8 +7161,7 @@ async function startTuiWorkspace(options) {
|
|
|
7128
7161
|
emitCommandOutput(t("copyNothing"));
|
|
7129
7162
|
} else {
|
|
7130
7163
|
try {
|
|
7131
|
-
|
|
7132
|
-
await clipboard.write(text);
|
|
7164
|
+
await writeClipboard(text);
|
|
7133
7165
|
emitCommandOutput(t("copiedLastReply"));
|
|
7134
7166
|
} catch (error) {
|
|
7135
7167
|
const message = toErrorMessage(error);
|
|
@@ -7606,8 +7638,10 @@ ${merged}` : merged;
|
|
|
7606
7638
|
selectionState.anchor = hit;
|
|
7607
7639
|
selectionState.head = hit;
|
|
7608
7640
|
selectionState.dragging = false;
|
|
7641
|
+
paintFrame(buffer);
|
|
7609
7642
|
} else {
|
|
7610
7643
|
clearSelection();
|
|
7644
|
+
paintFrame(buffer);
|
|
7611
7645
|
}
|
|
7612
7646
|
return;
|
|
7613
7647
|
}
|
|
@@ -7638,14 +7672,29 @@ ${merged}` : merged;
|
|
|
7638
7672
|
}
|
|
7639
7673
|
if (mouseEvent.kind === "release") {
|
|
7640
7674
|
stopAutoScroll();
|
|
7675
|
+
if (selectionState.dragging && selectionState.anchor) {
|
|
7676
|
+
const clampedRow = Math.max(0, Math.min(visibleHeight - 1, screenRow));
|
|
7677
|
+
const releaseHit = hitTestHistory(
|
|
7678
|
+
history,
|
|
7679
|
+
clampedRow,
|
|
7680
|
+
screenCol,
|
|
7681
|
+
contentWidth,
|
|
7682
|
+
history.scrollTop
|
|
7683
|
+
);
|
|
7684
|
+
if (releaseHit) selectionState.head = releaseHit;
|
|
7685
|
+
}
|
|
7641
7686
|
if (selectionState.dragging && selectionState.anchor && selectionState.head && !areSelectionPointsEqual(selectionState.anchor, selectionState.head)) {
|
|
7642
7687
|
const textToCopy = extractSelectedText(
|
|
7643
7688
|
history,
|
|
7644
7689
|
selectionState.anchor,
|
|
7645
|
-
selectionState.head
|
|
7690
|
+
selectionState.head,
|
|
7691
|
+
contentWidth
|
|
7646
7692
|
);
|
|
7647
7693
|
if (textToCopy.length > 0) {
|
|
7648
|
-
|
|
7694
|
+
writeClipboard(textToCopy).catch((error) => {
|
|
7695
|
+
emitCommandOutput(
|
|
7696
|
+
`[nolo] ${t("copyFailed")}: ${toErrorMessage(error)}`
|
|
7697
|
+
);
|
|
7649
7698
|
});
|
|
7650
7699
|
}
|
|
7651
7700
|
selectionState.dragging = false;
|
|
@@ -1,39 +1,39 @@
|
|
|
1
1
|
import {
|
|
2
2
|
fetchAgentContexts
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-JSIQQCPR.js";
|
|
4
4
|
import {
|
|
5
5
|
generateRequestBody,
|
|
6
6
|
mergeReferences,
|
|
7
7
|
performFetchRequest
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-OH6MOEZN.js";
|
|
9
9
|
import "./chunk-HS7MLR74.js";
|
|
10
10
|
import "./chunk-LAZTMWIU.js";
|
|
11
11
|
import {
|
|
12
12
|
findToolExecutor,
|
|
13
13
|
getToolResultErrorData
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-R7UWXBVG.js";
|
|
15
15
|
import "./chunk-RQSOAMPJ.js";
|
|
16
16
|
import "./chunk-BHILFABL.js";
|
|
17
17
|
import "./chunk-KQHGZWSV.js";
|
|
18
18
|
import "./chunk-KIL7V27H.js";
|
|
19
|
+
import "./chunk-L5XKDBSH.js";
|
|
19
20
|
import "./chunk-INZZJSQF.js";
|
|
20
21
|
import "./chunk-GM6PU7B6.js";
|
|
21
22
|
import "./chunk-63W5N6P3.js";
|
|
22
23
|
import "./chunk-VF4K2QE6.js";
|
|
23
|
-
import "./chunk-
|
|
24
|
-
import "./chunk-
|
|
25
|
-
import "./chunk-
|
|
26
|
-
import "./chunk-2UDMTJOM.js";
|
|
24
|
+
import "./chunk-G3ONB6Y5.js";
|
|
25
|
+
import "./chunk-UCUCOZXY.js";
|
|
26
|
+
import "./chunk-PFJA4C7K.js";
|
|
27
27
|
import "./chunk-M3JEW6N6.js";
|
|
28
28
|
import "./chunk-IDAU4UFS.js";
|
|
29
29
|
import {
|
|
30
30
|
updateTokensAction
|
|
31
|
-
} from "./chunk-
|
|
31
|
+
} from "./chunk-YBWR3WBJ.js";
|
|
32
32
|
import "./chunk-RCFIB45Q.js";
|
|
33
33
|
import "./chunk-EGRJC4ZN.js";
|
|
34
34
|
import "./chunk-YYLHWIW6.js";
|
|
35
35
|
import "./chunk-CWMSB67P.js";
|
|
36
|
-
import "./chunk-
|
|
36
|
+
import "./chunk-25MFIHEP.js";
|
|
37
37
|
import "./chunk-FH7VUJN5.js";
|
|
38
38
|
import "./chunk-5RGU3J7P.js";
|
|
39
39
|
import "./chunk-M76ECQRD.js";
|
|
@@ -43,7 +43,7 @@ import "./chunk-NNWHHCVP.js";
|
|
|
43
43
|
import "./chunk-OQVRTSZ5.js";
|
|
44
44
|
import "./chunk-ADLYMQB6.js";
|
|
45
45
|
import "./chunk-2CNX3CJE.js";
|
|
46
|
-
import "./chunk-
|
|
46
|
+
import "./chunk-CP4QR2D2.js";
|
|
47
47
|
import "./chunk-VIRTYWWE.js";
|
|
48
48
|
import {
|
|
49
49
|
getApiEndpoint
|
|
@@ -51,6 +51,8 @@ import {
|
|
|
51
51
|
import "./chunk-RQFO3CAF.js";
|
|
52
52
|
import "./chunk-QTZD6HBK.js";
|
|
53
53
|
import "./chunk-ZHXJ6M7T.js";
|
|
54
|
+
import "./chunk-HNMXYYJR.js";
|
|
55
|
+
import "./chunk-KMMQFY5O.js";
|
|
54
56
|
import "./chunk-7CH6U3FL.js";
|
|
55
57
|
import "./chunk-42IF53CR.js";
|
|
56
58
|
import "./chunk-YYTTDOWA.js";
|
|
@@ -63,7 +65,6 @@ import "./chunk-BANYWEYY.js";
|
|
|
63
65
|
import "./chunk-MRWGHF56.js";
|
|
64
66
|
import "./chunk-DWLEOOGR.js";
|
|
65
67
|
import "./chunk-KXKQO4Q6.js";
|
|
66
|
-
import "./chunk-HNMXYYJR.js";
|
|
67
68
|
import "./chunk-JFUW3UTO.js";
|
|
68
69
|
import "./chunk-7EPNNOL4.js";
|
|
69
70
|
import "./chunk-DDET6246.js";
|
|
@@ -73,7 +74,6 @@ import {
|
|
|
73
74
|
import "./chunk-Y5GCAMGP.js";
|
|
74
75
|
import "./chunk-KX6YBIHG.js";
|
|
75
76
|
import "./chunk-UZ6XXCVR.js";
|
|
76
|
-
import "./chunk-KMMQFY5O.js";
|
|
77
77
|
import {
|
|
78
78
|
read
|
|
79
79
|
} from "./chunk-6YH4UR3E.js";
|