pi-web-ui 0.109.0 → 0.110.0
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/CHANGELOG.md +31 -0
- package/README.md +21 -1
- package/README.zh-CN.md +21 -1
- package/README.zh-TW.md +201 -677
- package/dist/server/agent-service-daemon.js +2 -2
- package/dist/server/agent-service.js +20 -30
- package/dist/server/attachments.js +26 -6
- package/dist/server/dispatch-domain-handlers.js +2 -0
- package/dist/server/dispatch-plugin-handlers.js +1 -0
- package/dist/server/durable/durable-driver.js +1 -1
- package/dist/server/durable/durable-tools.js +4 -1
- package/dist/server/files-service.js +23 -4
- package/dist/server/goal-service.js +12 -3
- package/dist/server/index.js +39 -10
- package/dist/server/locales.js +33 -0
- package/dist/server/marker-service.js +7 -13
- package/dist/server/markers/builtins/action.js +5 -6
- package/dist/server/markers/builtins/notify.js +2 -2
- package/dist/server/markers/builtins/rename.js +2 -2
- package/dist/server/markers/registry.js +5 -1
- package/dist/server/message-window.js +190 -0
- package/dist/server/model-admin.js +0 -4
- package/dist/server/plugin-catalog-sync.js +10 -2
- package/dist/server/plugin-catalog.js +63 -10
- package/dist/server/plugins.js +47 -6
- package/dist/server/preset-share.js +2 -3
- package/dist/server/process-utils.js +58 -24
- package/dist/server/protocol-version.js +1 -1
- package/dist/server/settings-service.js +5 -0
- package/dist/server/slash-commands.js +16 -4
- package/dist/server/text-sniff.js +10 -7
- package/dist/server/themes.js +36 -1
- package/dist/server/universal/drivers/dsh-driver.js +1 -1
- package/dist/server/universal/universal-session.js +10 -3
- package/dist/server/worktree-service.js +1 -1
- package/package.json +7 -2
- package/plugin-sdk/index.d.ts +20 -0
- package/plugin-sdk/index.mjs +14 -0
- package/plugins/catalog.json +22 -2
- package/themes/aetheris.css +149 -118
- package/themes/bases/flow-base.css +1363 -0
- package/themes/bases/obsidian-base.css +679 -0
- package/themes/bases/zhujian-base.css +687 -0
- package/themes/bases/zhupi-base.css +659 -0
- package/themes/flow-light.css +2 -925
- package/themes/flow.css +1 -936
- package/themes/wallpaper-flow.css +71 -1031
- package/themes/wallpaper-obsidian.css +1 -673
- package/themes/zhujian-dark.css +1 -605
- package/themes/zhujian.css +1 -654
- package/themes/zhupi-dark.css +1 -576
- package/themes/zhupi.css +1 -626
- package/web/dist/assets/{TerminalPanel-BD3a9o-a.js → TerminalPanel-BHjM6pzY.js} +1 -1
- package/web/dist/assets/index-DwInT7-a.css +1 -0
- package/web/dist/assets/index-GfVFIgIL.js +693 -0
- package/web/dist/index.html +2 -2
- package/web/dist/sw.js +1 -1
- package/web/dist/assets/index-AccytlpP.css +0 -1
- package/web/dist/assets/index-B3dar1BK.js +0 -690
package/themes/zhupi.css
CHANGED
|
@@ -111,629 +111,4 @@
|
|
|
111
111
|
--menu-bg: #fffdf7;
|
|
112
112
|
}
|
|
113
113
|
|
|
114
|
-
|
|
115
|
-
朱批 · Vermilion Manuscript
|
|
116
|
-
整个界面从「聊天气泡」重构成「一张被 AI 做批注的稿纸」:
|
|
117
|
-
· 无气泡、无头像 —— 人机内容同处一条全宽文档流
|
|
118
|
-
· 工具调用 = 台账行(等宽小字 + 点线引导符)
|
|
119
|
-
· 思考流 = 脚注体(※ 起手)
|
|
120
|
-
· 输入框 = 命令栏,左缘一抹朱笔
|
|
121
|
-
· 色彩只有语义:墨、淡墨、朱(唯一强调)、印绿
|
|
122
|
-
========================================================================= */
|
|
123
|
-
|
|
124
|
-
/* ---- 0. 稿纸底色:旧纸的暗角与天头微光,纯渐变无图 ---- */
|
|
125
|
-
body,
|
|
126
|
-
.app-root {
|
|
127
|
-
background-color: var(--bg);
|
|
128
|
-
background-image:
|
|
129
|
-
radial-gradient(ellipse 90% 55% at 50% -8%, rgba(255, 253, 247, 0.85) 0%, rgba(255, 253, 247, 0) 70%),
|
|
130
|
-
radial-gradient(ellipse 100% 70% at 108% 112%, rgba(166, 140, 100, 0.1) 0%, rgba(166, 140, 100, 0) 70%);
|
|
131
|
-
background-attachment: fixed;
|
|
132
|
-
}
|
|
133
|
-
|
|
134
|
-
::selection {
|
|
135
|
-
background: rgba(191, 59, 31, 0.18);
|
|
136
|
-
}
|
|
137
|
-
|
|
138
|
-
/* ---- 1. 顶栏隐形化:无底色层次,只一条 hairline,印章品牌 ---- */
|
|
139
|
-
.topbar {
|
|
140
|
-
background: var(--topbar-bg) !important;
|
|
141
|
-
border-bottom: 1px solid var(--border-soft) !important;
|
|
142
|
-
box-shadow: none !important;
|
|
143
|
-
}
|
|
144
|
-
|
|
145
|
-
.brand-name {
|
|
146
|
-
font-family: var(--serif);
|
|
147
|
-
font-weight: 700;
|
|
148
|
-
letter-spacing: 0.06em;
|
|
149
|
-
}
|
|
150
|
-
|
|
151
|
-
/* 顶栏控件全部素色化:无底无框,hover 才现 hairline。兜底所有 button /
|
|
152
|
-
* [role=button]——不管类名是谁(基线 chip / 插件注入 / capsule 等),顶栏里
|
|
153
|
-
* 一律裸图标,dropdown 触发器不许再带盒子。 */
|
|
154
|
-
.topbar button,
|
|
155
|
-
.topbar [role="button"],
|
|
156
|
-
.topbar a.chip,
|
|
157
|
-
.topbar .chip {
|
|
158
|
-
background: transparent !important;
|
|
159
|
-
border: 1px solid transparent !important;
|
|
160
|
-
border-radius: 3px !important;
|
|
161
|
-
box-shadow: none !important;
|
|
162
|
-
transition:
|
|
163
|
-
border-color 0.15s ease,
|
|
164
|
-
color 0.15s ease !important;
|
|
165
|
-
}
|
|
166
|
-
|
|
167
|
-
.topbar button:hover,
|
|
168
|
-
.topbar [role="button"]:hover,
|
|
169
|
-
.topbar a.chip:hover,
|
|
170
|
-
.topbar .chip:hover {
|
|
171
|
-
border-color: var(--border) !important;
|
|
172
|
-
background: transparent !important;
|
|
173
|
-
}
|
|
174
|
-
|
|
175
|
-
.topbar .dropdown {
|
|
176
|
-
background: transparent !important;
|
|
177
|
-
border: none !important;
|
|
178
|
-
box-shadow: none !important;
|
|
179
|
-
}
|
|
180
|
-
|
|
181
|
-
/* ---- 2. 消息区:文档化排版 ----
|
|
182
|
-
* 消息区左右边缘与输入框/快捷短语行保持一致严丝合缝对齐(继承基线列几何)。 */
|
|
183
|
-
|
|
184
|
-
.msg {
|
|
185
|
-
position: relative;
|
|
186
|
-
padding: 2px 0 10px;
|
|
187
|
-
}
|
|
188
|
-
|
|
189
|
-
.msg-user {
|
|
190
|
-
padding-bottom: 2px !important;
|
|
191
|
-
}
|
|
192
|
-
|
|
193
|
-
.msg-user .msg-actions {
|
|
194
|
-
margin-top: 2px !important;
|
|
195
|
-
}
|
|
196
|
-
|
|
197
|
-
.msg-user + .msg-assistant {
|
|
198
|
-
padding-top: 2px !important;
|
|
199
|
-
}
|
|
200
|
-
|
|
201
|
-
.msg-user + .msg-assistant .msg-body > :first-child {
|
|
202
|
-
margin-top: 2px !important;
|
|
203
|
-
}
|
|
204
|
-
|
|
205
|
-
/* 操作按钮:卡头只有自己的复制键(.chead-copy),消息级按钮(复制三件套 /
|
|
206
|
-
分叉 / 回滚 / 朗读)统一在底部 .msg-actions 行,流内排在消息气泡/正文下边,
|
|
207
|
-
桌面端与手机端保持一致。 */
|
|
208
|
-
|
|
209
|
-
/* 角色行:书目式小标 */
|
|
210
|
-
.msg-meta {
|
|
211
|
-
margin-bottom: 4px;
|
|
212
|
-
}
|
|
213
|
-
|
|
214
|
-
/* head 行左右内边距归零:折叠三角贴齐列左缘(文字同一条线),右侧复制
|
|
215
|
-
* 按钮贴右缘——head 无边框后,钮与缘之间不能悬空。三角形 28px 盒内 16px
|
|
216
|
-
* 图标居中内缩 6px,用负外边距做光学对齐。 */
|
|
217
|
-
.chead {
|
|
218
|
-
padding-left: 0;
|
|
219
|
-
padding-right: 0;
|
|
220
|
-
}
|
|
221
|
-
|
|
222
|
-
.chead-toggle {
|
|
223
|
-
margin-left: -6px;
|
|
224
|
-
}
|
|
225
|
-
|
|
226
|
-
/* 正文块上的单一复制键去重:卡头现在只有自己的复制键,消息级复制
|
|
227
|
-
(纯文本 / Markdown / 长图三件套)统一在底部 .msg-actions 行里。 */
|
|
228
|
-
.msg-text-copy {
|
|
229
|
-
display: none !important;
|
|
230
|
-
}
|
|
231
|
-
|
|
232
|
-
/* head 悬浮不再出现底色块:纸面保持完全平整(键盘 focus 的 outline 保留,
|
|
233
|
-
* 只服务键盘导航) */
|
|
234
|
-
div.chead[role="button"]:hover,
|
|
235
|
-
.chead-toggle:hover {
|
|
236
|
-
background: transparent !important;
|
|
237
|
-
}
|
|
238
|
-
|
|
239
|
-
.msg-role {
|
|
240
|
-
font-size: 10.5px;
|
|
241
|
-
font-weight: 600;
|
|
242
|
-
letter-spacing: 0.18em;
|
|
243
|
-
color: var(--text-faint);
|
|
244
|
-
}
|
|
245
|
-
|
|
246
|
-
.msg-time {
|
|
247
|
-
font-family: var(--mono);
|
|
248
|
-
font-size: 10.5px;
|
|
249
|
-
}
|
|
250
|
-
|
|
251
|
-
/* ---- 3. 用户输入:去气泡,「起手式,稿纸批注体 ---- */
|
|
252
|
-
.msg-user .msg-body {
|
|
253
|
-
position: relative;
|
|
254
|
-
background: transparent !important;
|
|
255
|
-
border: none !important;
|
|
256
|
-
border-radius: 0 !important;
|
|
257
|
-
padding: 0 0 0 1.5em !important;
|
|
258
|
-
font-family: var(--serif);
|
|
259
|
-
font-size: 15.5px;
|
|
260
|
-
font-weight: 600;
|
|
261
|
-
line-height: 1.8;
|
|
262
|
-
color: var(--text);
|
|
263
|
-
}
|
|
264
|
-
|
|
265
|
-
.msg-user .msg-body::before {
|
|
266
|
-
content: "「";
|
|
267
|
-
position: absolute;
|
|
268
|
-
left: 0;
|
|
269
|
-
top: -0.12em;
|
|
270
|
-
font-family: var(--serif);
|
|
271
|
-
font-size: 1.3em;
|
|
272
|
-
font-weight: 700;
|
|
273
|
-
color: var(--accent);
|
|
274
|
-
line-height: 1;
|
|
275
|
-
}
|
|
276
|
-
|
|
277
|
-
/* ---- 4. 助手正文:衬线文档体,直接是书页 ---- */
|
|
278
|
-
.msg-assistant .msg-text {
|
|
279
|
-
font-family: var(--serif);
|
|
280
|
-
font-size: 15px;
|
|
281
|
-
line-height: 1.85;
|
|
282
|
-
color: var(--text);
|
|
283
|
-
}
|
|
284
|
-
|
|
285
|
-
.msg-assistant .msg-text p:first-child {
|
|
286
|
-
margin-top: 0;
|
|
287
|
-
}
|
|
288
|
-
|
|
289
|
-
.msg-assistant .msg-text h1,
|
|
290
|
-
.msg-assistant .msg-text h2,
|
|
291
|
-
.msg-assistant .msg-text h3,
|
|
292
|
-
.msg-assistant .msg-text h4 {
|
|
293
|
-
font-family: var(--serif);
|
|
294
|
-
font-weight: 700;
|
|
295
|
-
color: var(--md-strong);
|
|
296
|
-
letter-spacing: 0.02em;
|
|
297
|
-
}
|
|
298
|
-
|
|
299
|
-
.msg-assistant .msg-text blockquote {
|
|
300
|
-
border-left: 2px solid var(--accent-soft);
|
|
301
|
-
font-style: normal;
|
|
302
|
-
color: var(--text-dim);
|
|
303
|
-
}
|
|
304
|
-
|
|
305
|
-
.msg-assistant .msg-text a {
|
|
306
|
-
color: var(--link);
|
|
307
|
-
text-decoration: underline dotted;
|
|
308
|
-
text-decoration-color: rgba(191, 59, 31, 0.45);
|
|
309
|
-
text-underline-offset: 3px;
|
|
310
|
-
}
|
|
311
|
-
|
|
312
|
-
.msg-assistant .msg-text hr {
|
|
313
|
-
border: none;
|
|
314
|
-
border-top: 1px dotted var(--border);
|
|
315
|
-
}
|
|
316
|
-
|
|
317
|
-
.msg-assistant .msg-text code {
|
|
318
|
-
background: #ece4d0;
|
|
319
|
-
color: #6b3a1f;
|
|
320
|
-
border-radius: 2px;
|
|
321
|
-
padding: 1px 5px;
|
|
322
|
-
}
|
|
323
|
-
|
|
324
|
-
/* ---- 5. 工具调用 = 台账行:无框无底,点线引导符填空 ---- */
|
|
325
|
-
.toolcall {
|
|
326
|
-
margin: 1px 0 !important;
|
|
327
|
-
border: none !important;
|
|
328
|
-
border-radius: 0 !important;
|
|
329
|
-
background: transparent !important;
|
|
330
|
-
box-shadow: none !important;
|
|
331
|
-
overflow: visible !important;
|
|
332
|
-
}
|
|
333
|
-
|
|
334
|
-
.toolcall-head {
|
|
335
|
-
display: flex;
|
|
336
|
-
align-items: center;
|
|
337
|
-
min-height: 24px;
|
|
338
|
-
padding: 2px 0;
|
|
339
|
-
font-family: var(--mono);
|
|
340
|
-
font-size: 12px;
|
|
341
|
-
}
|
|
342
|
-
|
|
343
|
-
.toolcall-name {
|
|
344
|
-
font-family: var(--mono) !important;
|
|
345
|
-
font-weight: 500 !important;
|
|
346
|
-
font-size: 12px !important;
|
|
347
|
-
letter-spacing: 0.02em;
|
|
348
|
-
color: var(--text-dim) !important;
|
|
349
|
-
}
|
|
350
|
-
|
|
351
|
-
/* 点线引导符:账本目录式填空,落在名字与状态之间 */
|
|
352
|
-
.toolcall .toolcall-spacer {
|
|
353
|
-
border-bottom: 1px dotted #c9bfa8;
|
|
354
|
-
height: 0.7em;
|
|
355
|
-
margin: 0 10px;
|
|
356
|
-
}
|
|
357
|
-
|
|
358
|
-
.toolcall-status {
|
|
359
|
-
color: var(--text-faint) !important;
|
|
360
|
-
}
|
|
361
|
-
|
|
362
|
-
.toolcall.run .toolcall-name {
|
|
363
|
-
color: var(--accent) !important;
|
|
364
|
-
}
|
|
365
|
-
|
|
366
|
-
.toolcall.run .toolcall-status {
|
|
367
|
-
color: var(--accent) !important;
|
|
368
|
-
}
|
|
369
|
-
|
|
370
|
-
.toolcall.run .toolcall-head {
|
|
371
|
-
background: transparent;
|
|
372
|
-
border-left: none;
|
|
373
|
-
}
|
|
374
|
-
|
|
375
|
-
.toolcall.ok .toolcall-status {
|
|
376
|
-
color: var(--green) !important;
|
|
377
|
-
}
|
|
378
|
-
|
|
379
|
-
.toolcall.err .toolcall-status {
|
|
380
|
-
color: var(--red) !important;
|
|
381
|
-
}
|
|
382
|
-
|
|
383
|
-
.toolcall.err .toolcall-name {
|
|
384
|
-
color: var(--red) !important;
|
|
385
|
-
}
|
|
386
|
-
|
|
387
|
-
/* 展开的参数/输出:并入台账,无框零内边距平面文本(--code-border/--code-pad
|
|
388
|
-
已按全透明主题机制置 transparent/0,连带 .termline 一并生效) */
|
|
389
|
-
.toolcall-args pre,
|
|
390
|
-
.toolcall-output pre {
|
|
391
|
-
background: transparent !important;
|
|
392
|
-
border: none !important;
|
|
393
|
-
border-radius: 0 !important;
|
|
394
|
-
padding: 0 !important;
|
|
395
|
-
}
|
|
396
|
-
|
|
397
|
-
/* 工具卡体:去掉分隔线与内边距,参数/输出与卡头同距平铺 */
|
|
398
|
-
.toolcall-body {
|
|
399
|
-
border-top: none !important;
|
|
400
|
-
padding: 0 0 6px !important;
|
|
401
|
-
}
|
|
402
|
-
|
|
403
|
-
/* 卡内重复的终端图标只剩噪音(卡头已有工具图标),参照全透明主题隐藏 */
|
|
404
|
-
.termline-icon {
|
|
405
|
-
display: none;
|
|
406
|
-
}
|
|
407
|
-
|
|
408
|
-
.toolcall-output-label {
|
|
409
|
-
margin-top: 6px;
|
|
410
|
-
}
|
|
411
|
-
|
|
412
|
-
.toolcall-kill {
|
|
413
|
-
border-radius: 3px;
|
|
414
|
-
}
|
|
415
|
-
|
|
416
|
-
/* ---- 6. 思考流 = 脚注:※ 起手,淡墨小字 ---- */
|
|
417
|
-
.thinking {
|
|
418
|
-
margin: 4px 0 !important;
|
|
419
|
-
border: none !important;
|
|
420
|
-
border-radius: 0 !important;
|
|
421
|
-
background: transparent !important;
|
|
422
|
-
box-shadow: none !important;
|
|
423
|
-
}
|
|
424
|
-
|
|
425
|
-
.thinking-head {
|
|
426
|
-
font-size: 12px;
|
|
427
|
-
color: var(--text-faint);
|
|
428
|
-
}
|
|
429
|
-
|
|
430
|
-
.thinking-body {
|
|
431
|
-
border-top: none !important;
|
|
432
|
-
font-style: normal !important;
|
|
433
|
-
font-size: 12.5px !important;
|
|
434
|
-
color: var(--text-dim) !important;
|
|
435
|
-
background: transparent;
|
|
436
|
-
position: relative;
|
|
437
|
-
padding: 2px 14px 2px 1.6em !important;
|
|
438
|
-
}
|
|
439
|
-
|
|
440
|
-
.thinking-body::before {
|
|
441
|
-
content: "※";
|
|
442
|
-
position: absolute;
|
|
443
|
-
left: 0;
|
|
444
|
-
top: 2px;
|
|
445
|
-
color: var(--text-faint);
|
|
446
|
-
}
|
|
447
|
-
|
|
448
|
-
.thinking-live .thinking-toggle,
|
|
449
|
-
.thinking-live-label {
|
|
450
|
-
color: var(--accent) !important;
|
|
451
|
-
}
|
|
452
|
-
|
|
453
|
-
/* ---- 7. 折叠摘要行 / 排队提示:并入台账体系 ---- */
|
|
454
|
-
.msg-collapsed {
|
|
455
|
-
background: transparent !important;
|
|
456
|
-
border: none !important;
|
|
457
|
-
border-bottom: 1px dotted var(--border-soft) !important;
|
|
458
|
-
border-radius: 0 !important;
|
|
459
|
-
box-shadow: none !important;
|
|
460
|
-
padding-left: 0 !important;
|
|
461
|
-
padding-right: 0 !important;
|
|
462
|
-
}
|
|
463
|
-
|
|
464
|
-
.msg-collapsed-action::before {
|
|
465
|
-
margin-left: 0 !important;
|
|
466
|
-
}
|
|
467
|
-
|
|
468
|
-
.msg-error {
|
|
469
|
-
background: var(--red-soft) !important;
|
|
470
|
-
border: none !important;
|
|
471
|
-
border-left: 3px solid var(--red) !important;
|
|
472
|
-
border-radius: 0 !important;
|
|
473
|
-
font-family: var(--serif);
|
|
474
|
-
}
|
|
475
|
-
|
|
476
|
-
/* ---- 8. 输入区 = 命令栏:与其他主题同构——只动颜色不动几何,
|
|
477
|
-
朱笔以 inset 阴影画在边框内侧,外缘与消息列/chips 恒对齐 ---- */
|
|
478
|
-
.inputbar {
|
|
479
|
-
background: transparent !important;
|
|
480
|
-
}
|
|
481
|
-
|
|
482
|
-
.inputbox {
|
|
483
|
-
background: var(--inputbox-bg) !important;
|
|
484
|
-
border: none !important;
|
|
485
|
-
border-radius: 3px !important;
|
|
486
|
-
box-shadow: inset 3px 0 0 0 rgba(191, 59, 31, 0.35) !important;
|
|
487
|
-
transition:
|
|
488
|
-
border-color 0.2s ease,
|
|
489
|
-
box-shadow 0.2s ease !important;
|
|
490
|
-
}
|
|
491
|
-
|
|
492
|
-
.inputbox:focus-within {
|
|
493
|
-
border: none !important;
|
|
494
|
-
box-shadow: inset 3px 0 0 0 var(--accent) !important;
|
|
495
|
-
}
|
|
496
|
-
|
|
497
|
-
.btn.send {
|
|
498
|
-
background: var(--send-blue) !important;
|
|
499
|
-
color: #f6f2e9 !important;
|
|
500
|
-
border-radius: 50% !important;
|
|
501
|
-
box-shadow: none !important;
|
|
502
|
-
font-weight: 600;
|
|
503
|
-
}
|
|
504
|
-
|
|
505
|
-
.btn.send:hover {
|
|
506
|
-
background: var(--send-blue-hover) !important;
|
|
507
|
-
}
|
|
508
|
-
|
|
509
|
-
.btn.stop {
|
|
510
|
-
background: var(--stop-red) !important;
|
|
511
|
-
color: #f6f2e9 !important;
|
|
512
|
-
border-radius: 50% !important;
|
|
513
|
-
}
|
|
514
|
-
|
|
515
|
-
/* 输入框底部模型选择、思考强度、预设等按钮:去边框、透明底,hover 现 hairline */
|
|
516
|
-
.composer-tools {
|
|
517
|
-
border-top: none !important;
|
|
518
|
-
}
|
|
519
|
-
|
|
520
|
-
.composer-tools .chip,
|
|
521
|
-
.composer-tools .capsule-segment {
|
|
522
|
-
font-size: 13px !important;
|
|
523
|
-
padding: 4px 10px !important;
|
|
524
|
-
gap: 6px !important;
|
|
525
|
-
background: transparent !important;
|
|
526
|
-
border: 1px solid transparent !important;
|
|
527
|
-
box-shadow: none !important;
|
|
528
|
-
border-radius: 3px !important;
|
|
529
|
-
transition:
|
|
530
|
-
border-color 0.15s ease,
|
|
531
|
-
background 0.15s ease !important;
|
|
532
|
-
}
|
|
533
|
-
|
|
534
|
-
.composer-tools .model-thinking-capsule {
|
|
535
|
-
background: transparent !important;
|
|
536
|
-
border: none !important;
|
|
537
|
-
box-shadow: none !important;
|
|
538
|
-
padding: 0 !important;
|
|
539
|
-
}
|
|
540
|
-
|
|
541
|
-
.composer-tools .model-thinking-capsule .capsule-divider {
|
|
542
|
-
display: none !important;
|
|
543
|
-
}
|
|
544
|
-
|
|
545
|
-
.composer-tools .chip:hover,
|
|
546
|
-
.composer-tools .capsule-segment:hover {
|
|
547
|
-
border-color: var(--border) !important;
|
|
548
|
-
background: transparent !important;
|
|
549
|
-
}
|
|
550
|
-
|
|
551
|
-
.composer-tools-left {
|
|
552
|
-
gap: 6px !important;
|
|
553
|
-
}
|
|
554
|
-
|
|
555
|
-
.composer-tools .chip-model,
|
|
556
|
-
.composer-tools .chip-sub,
|
|
557
|
-
.composer-tools .capsule-model-name,
|
|
558
|
-
.composer-tools .capsule-thinking-text {
|
|
559
|
-
font-size: 12.5px !important;
|
|
560
|
-
}
|
|
561
|
-
|
|
562
|
-
/* ---- 9. 底栏 / 状态栏:hairline 收边 ---- */
|
|
563
|
-
.statusbar {
|
|
564
|
-
background: var(--statusbar-bg) !important;
|
|
565
|
-
border-top: 1px solid var(--border-soft) !important;
|
|
566
|
-
box-shadow: none !important;
|
|
567
|
-
}
|
|
568
|
-
|
|
569
|
-
.goalbar {
|
|
570
|
-
background: transparent !important;
|
|
571
|
-
border-top: 1px solid var(--border-soft) !important;
|
|
572
|
-
box-shadow: none !important;
|
|
573
|
-
}
|
|
574
|
-
|
|
575
|
-
/* ---- 10. 左右面板:素纸文件栏 ----
|
|
576
|
-
* 激活态不做红洗(accent-soft 洗在纸上是一块脏粉),改为中性墨面 5% +
|
|
577
|
-
* 左缘 2px 朱标;圆角统一 8px。 */
|
|
578
|
-
.panel {
|
|
579
|
-
background: var(--panel-bg) !important;
|
|
580
|
-
border-color: var(--border-soft) !important;
|
|
581
|
-
}
|
|
582
|
-
|
|
583
|
-
.session-item,
|
|
584
|
-
.project-item,
|
|
585
|
-
.file-item,
|
|
586
|
-
.scm-file {
|
|
587
|
-
border-radius: 8px;
|
|
588
|
-
}
|
|
589
|
-
|
|
590
|
-
.session-item.active,
|
|
591
|
-
.project-item.active {
|
|
592
|
-
background: rgba(38, 34, 24, 0.05);
|
|
593
|
-
border: none;
|
|
594
|
-
box-shadow: inset 2px 0 0 var(--accent);
|
|
595
|
-
}
|
|
596
|
-
|
|
597
|
-
.session-item.active {
|
|
598
|
-
padding: 8px 10px;
|
|
599
|
-
}
|
|
600
|
-
|
|
601
|
-
.project-item.active {
|
|
602
|
-
padding: 7px 10px;
|
|
603
|
-
}
|
|
604
|
-
|
|
605
|
-
/* ---- 11. 代码块与终端:纸凹版 + 暖墨终端 ---- */
|
|
606
|
-
.codeblock {
|
|
607
|
-
background: var(--code-bg) !important;
|
|
608
|
-
border: 1px solid var(--border-soft) !important;
|
|
609
|
-
border-radius: 3px !important;
|
|
610
|
-
box-shadow: none !important;
|
|
611
|
-
}
|
|
612
|
-
|
|
613
|
-
.codeblock pre,
|
|
614
|
-
.msg-text pre {
|
|
615
|
-
background: var(--code-bg) !important;
|
|
616
|
-
color: var(--code-text) !important;
|
|
617
|
-
}
|
|
618
|
-
|
|
619
|
-
/* ---- 11b. 语法高亮适配纸面(全局捆绑的是 github-dark,必须整套覆盖)---- */
|
|
620
|
-
.hljs {
|
|
621
|
-
color: #33301f;
|
|
622
|
-
background: transparent !important;
|
|
623
|
-
}
|
|
624
|
-
|
|
625
|
-
.hljs-comment,
|
|
626
|
-
.hljs-quote {
|
|
627
|
-
color: #948b78;
|
|
628
|
-
}
|
|
629
|
-
|
|
630
|
-
.hljs-keyword,
|
|
631
|
-
.hljs-selector-tag,
|
|
632
|
-
.hljs-doctag,
|
|
633
|
-
.hljs-formula {
|
|
634
|
-
color: #a03618;
|
|
635
|
-
}
|
|
636
|
-
|
|
637
|
-
.hljs-string,
|
|
638
|
-
.hljs-regexp {
|
|
639
|
-
color: #3f6c4f;
|
|
640
|
-
}
|
|
641
|
-
|
|
642
|
-
.hljs-number,
|
|
643
|
-
.hljs-literal {
|
|
644
|
-
color: #8a5c1e;
|
|
645
|
-
}
|
|
646
|
-
|
|
647
|
-
.hljs-title,
|
|
648
|
-
.hljs-title.function_,
|
|
649
|
-
.hljs-section {
|
|
650
|
-
color: #6b3fa0;
|
|
651
|
-
}
|
|
652
|
-
|
|
653
|
-
.hljs-attr,
|
|
654
|
-
.hljs-attribute,
|
|
655
|
-
.hljs-variable,
|
|
656
|
-
.hljs-template-variable,
|
|
657
|
-
.hljs-type,
|
|
658
|
-
.hljs-name {
|
|
659
|
-
color: #8a4a2e;
|
|
660
|
-
}
|
|
661
|
-
|
|
662
|
-
.hljs-built_in {
|
|
663
|
-
color: #2f5f8a;
|
|
664
|
-
}
|
|
665
|
-
|
|
666
|
-
.hljs-deletion {
|
|
667
|
-
color: #7a2718;
|
|
668
|
-
background: rgba(194, 64, 42, 0.12);
|
|
669
|
-
}
|
|
670
|
-
|
|
671
|
-
.hljs-addition {
|
|
672
|
-
color: #2f6b4f;
|
|
673
|
-
background: rgba(61, 122, 85, 0.14);
|
|
674
|
-
}
|
|
675
|
-
|
|
676
|
-
/* ---- 12. 弹层与菜单:纸面实底 + hairline,方角家族 ---- */
|
|
677
|
-
.modal,
|
|
678
|
-
.tool-info-modal,
|
|
679
|
-
.settings-modal,
|
|
680
|
-
.model-modal,
|
|
681
|
-
.tpl-modal,
|
|
682
|
-
.dd-menu,
|
|
683
|
-
.dialog-inline {
|
|
684
|
-
border-radius: 4px !important;
|
|
685
|
-
border: 1px solid var(--border) !important;
|
|
686
|
-
box-shadow:
|
|
687
|
-
0 1px 2px rgba(38, 34, 24, 0.06),
|
|
688
|
-
0 16px 40px -12px rgba(38, 34, 24, 0.25) !important;
|
|
689
|
-
}
|
|
690
|
-
|
|
691
|
-
.dd-menu {
|
|
692
|
-
background: var(--menu-bg) !important;
|
|
693
|
-
border: 1px solid var(--border) !important;
|
|
694
|
-
border-radius: 4px !important;
|
|
695
|
-
box-shadow: 0 12px 32px -8px rgba(38, 34, 24, 0.28) !important;
|
|
696
|
-
}
|
|
697
|
-
|
|
698
|
-
.dd-item:hover,
|
|
699
|
-
.dd-all-item:hover {
|
|
700
|
-
background: var(--accent-soft) !important;
|
|
701
|
-
}
|
|
702
|
-
|
|
703
|
-
/* ---- 13. chips / 徽标:账目标签体 ---- */
|
|
704
|
-
.chip {
|
|
705
|
-
background: var(--chip-bg) !important;
|
|
706
|
-
border: 1px solid var(--border-soft) !important;
|
|
707
|
-
border-radius: 2px !important;
|
|
708
|
-
box-shadow: none !important;
|
|
709
|
-
font-family: var(--mono);
|
|
710
|
-
font-size: 11px;
|
|
711
|
-
}
|
|
712
|
-
|
|
713
|
-
/* ---- 14. 滚动条:细墨线 ---- */
|
|
714
|
-
::-webkit-scrollbar {
|
|
715
|
-
width: 6px;
|
|
716
|
-
height: 6px;
|
|
717
|
-
}
|
|
718
|
-
|
|
719
|
-
::-webkit-scrollbar-track {
|
|
720
|
-
background: transparent;
|
|
721
|
-
}
|
|
722
|
-
|
|
723
|
-
::-webkit-scrollbar-thumb {
|
|
724
|
-
background: var(--scroll-thumb);
|
|
725
|
-
border-radius: 0;
|
|
726
|
-
}
|
|
727
|
-
|
|
728
|
-
::-webkit-scrollbar-thumb:hover {
|
|
729
|
-
background: var(--scroll-thumb-hover);
|
|
730
|
-
}
|
|
731
|
-
|
|
732
|
-
/* ---- 15. 通知条:hairline 左线式 ---- */
|
|
733
|
-
.notice-err,
|
|
734
|
-
.notice-warn,
|
|
735
|
-
.notice-info {
|
|
736
|
-
border-radius: 0 !important;
|
|
737
|
-
border-width: 1px !important;
|
|
738
|
-
border-left-width: 3px !important;
|
|
739
|
-
}
|
|
114
|
+
@import "./bases/zhupi-base.css";
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import{r as e}from"./rolldown-runtime-hePW80VL.js";import{i as t,t as n}from"./react-CR5VJ85Q.js";import{n as r,t as i}from"./xterm-Cf5xxe4g.js";import{a,c as o,d as s,f as c,g as l,h as u,i as d,l as f,m as p,o as m,p as h,r as g,s as _,t as v,u as y}from"./index-
|
|
1
|
+
import{r as e}from"./rolldown-runtime-hePW80VL.js";import{i as t,t as n}from"./react-CR5VJ85Q.js";import{n as r,t as i}from"./xterm-Cf5xxe4g.js";import{a,c as o,d as s,f as c,g as l,h as u,i as d,l as f,m as p,o as m,p as h,r as g,s as _,t as v,u as y}from"./index-GfVFIgIL.js";var b=e(t(),1);function x(e,t){return Math.abs(t)>10&&Math.abs(t)>Math.abs(e)*1.2}function S(e,t){return e-t}var C=n();function w(e){let t=null;return{clean:e.replace(/\r?\n?\[pi-term-exit:(-?\d+)\]\r?\n?/g,(e,n)=>(t=Number(n),`\r
|
|
2
2
|
`)).replace(/\r?\n?\x1b\[90m\[(?:进程已退出,退出码 |Process exited with code )-?\d+\]\x1b\[0m\r?\n?/g,`\r
|
|
3
3
|
`),exitCode:t}}function T({conversationId:e,terminalId:t,command:n,cwd:a,title:o,agentBash:s,active:c,running:l,exitCode:u,register:f}){let p=(0,b.useRef)(null),h=(0,b.useRef)(null),{locale:v}=d(),y=(0,b.useRef)(v);y.current=v;let T=n?JSON.stringify(n):``,E=(0,b.useRef)(l===!1);(0,b.useEffect)(()=>{let l=p.current;if(!l)return;let u=new r({theme:_(),fontFamily:`"SF Mono", "JetBrains Mono", ui-monospace, Menlo, Consolas, monospace`,fontSize:13,cursorBlink:!0,scrollback:8e3}),d=new i;u.loadAddon(d),u.open(l),h.current={term:u,fit:d},c&&u.focus();let v=()=>{u.options.theme=_()};window.addEventListener(m,v),u.attachCustomKeyEventHandler(e=>{if(e.type!==`keydown`)return!0;let t=e.key?.toLowerCase();if((e.ctrlKey||e.metaKey)&&t===`v`)return!1;if(e.ctrlKey&&!e.shiftKey&&!e.altKey&&t===`c`&&u.hasSelection()){let e=u.textarea;return e&&(e.value=u.getSelection(),e.select()),!1}return!0});let b=f(e,t,{write:e=>u.write(w(e).clean),dispose:()=>u.dispose()}),C=()=>{try{d.fit(),g({type:`terminal_resize`,terminalId:t,conversationId:e,cols:u.cols,rows:u.rows})}catch{}},T=requestAnimationFrame(()=>{try{d.fit()}catch{}E.current||g(n?{type:`run_command`,terminalId:t,conversationId:e,command:n,cols:u.cols,rows:u.rows}:{type:`terminal_create`,terminalId:t,title:o,locale:y.current,agentBash:s,conversationId:e,cwd:a,cols:u.cols,rows:u.rows})}),D=u.onData(n=>{g({type:`terminal_input`,terminalId:t,conversationId:e,data:n})}),O=u.element,k=null,A=0,j=0,M=0,N=!1,P=e=>{if(e.touches.length!==1){k=null,N=!1;return}let t=e.touches[0];k=t.identifier,A=t.clientX,j=t.clientY,M=t.clientY,N=!1},F=e=>{if(k===null||e.touches.length!==1)return;let t=e.touches[0];if(t.identifier!==k)return;if(!N){if(!x(t.clientX-A,t.clientY-j))return;N=!0}e.preventDefault();let n=S(M,t.clientY);M=t.clientY,n!==0&&typeof WheelEvent<`u`&&(l.querySelector(`.xterm-viewport`)??O)?.dispatchEvent(new WheelEvent(`wheel`,{bubbles:!0,cancelable:!0,deltaY:n,deltaMode:0,clientX:t.clientX,clientY:t.clientY}))},I=e=>{if(k!==null){if(e.touches.length>0){k=null,N=!1;return}k=null,N=!1}};O?.addEventListener(`touchstart`,P,{passive:!0}),O?.addEventListener(`touchmove`,F,{passive:!1}),O?.addEventListener(`touchend`,I),O?.addEventListener(`touchcancel`,I);let L=null;return typeof ResizeObserver<`u`&&(L=new ResizeObserver(()=>{l.offsetWidth>0&&l.offsetHeight>0&&C()}),L.observe(l)),()=>{cancelAnimationFrame(T),D.dispose(),O?.removeEventListener(`touchstart`,P),O?.removeEventListener(`touchmove`,F),O?.removeEventListener(`touchend`,I),O?.removeEventListener(`touchcancel`,I),window.removeEventListener(m,v),L?.disconnect(),b(),u.dispose(),h.current=null}},[e,t,T,f]),(0,b.useEffect)(()=>{if(!c)return;let n=requestAnimationFrame(()=>{let n=h.current;if(n){try{n.fit.fit(),g({type:`terminal_resize`,terminalId:t,conversationId:e,cols:n.term.cols,rows:n.term.rows})}catch{}n.term.focus()}});return()=>cancelAnimationFrame(n)},[c]);let{t:D}=d(),O=(0,b.useRef)(void 0);return(0,b.useEffect)(()=>{if(l===O.current||(O.current=l,l!==!1))return;let e=h.current;e&&e.term.write(`\r\n\x1b[90m${D(`exitBanner`,{code:u??``})}\x1b[0m\r\n`)},[l,t,u]),(0,C.jsx)(`div`,{ref:p,className:`term-xterm ${c?``:`hidden`}`})}var E={name:``,command:``,cwd:"${pwd}"};function D({chat:e,terminal:t,uiTerminalToolbar:n,onUiAction:r}){let i=a(),[d,m]=(0,b.useState)(null),[_,x]=(0,b.useState)(!1),[S,w]=(0,b.useState)(!1),[D,O]=(0,b.useState)(null),[k,A]=(0,b.useState)(E),[j,M]=(0,b.useState)(null),N=(0,b.useRef)(null),[P,F]=(0,b.useState)(!0),[I,L]=(0,b.useState)(null),[R,z]=(0,b.useState)(``);(0,b.useEffect)(()=>{e.terminals.length===0?m(null):e.terminals.some(e=>e.id===d)||m(e.terminals[e.terminals.length-1].id)},[e.terminals,d]),(0,b.useEffect)(()=>{e.terminalActiveId&&(m(e.terminalActiveId),x(!1))},[e.terminalActiveId]),(0,b.useEffect)(()=>()=>{N.current&&clearTimeout(N.current)},[]);let B=e.terminals.filter(e=>!e.agentBash),V=e.terminals.filter(e=>e.agentBash),H=n=>{if(!e.ready)return;let r=o(),i=e.activeConversationId||e.state?.conversationId||``;t.create({...n,id:r,conversationId:i,cols:n.cols??80,rows:n.rows??24,running:!0,exitCode:null}),m(r),x(!1)},U=()=>H({title:i(`terminalTitle`,{n:B.length+1}),cwd:e.state?.cwd??``}),W=n=>{let r=n.name||n.command,i=e.terminals.find(e=>e.title===r);if(i){t.restart(i.id),m(i.id),g({type:`run_command`,terminalId:i.id,conversationId:i.conversationId,command:n,cols:80,rows:24});return}H({title:r,cwd:e.state?.cwd??``,command:n})},G=n=>{let r=e.terminals.find(e=>e.id===n);if(r&&g({type:`terminal_kill`,terminalId:n,conversationId:r.conversationId}),t.close(n),d===n){let t=e.terminals.filter(e=>e.id!==n);m(t.length>0?t[t.length-1].id:null)}},K=e=>(0,C.jsxs)(`div`,{className:`term-tab ${e.id===d?`active`:``}`,children:[(0,C.jsxs)(`button`,{type:`button`,className:`term-tab-main`,title:`${e.cwd}${e.command?`\n> ${e.command.command}`:``}`,onClick:()=>{I||(m(e.id),x(!1))},children:[(0,C.jsx)(`span`,{className:`term-tab-dot ${e.running?`run`:`exit`}`}),(0,C.jsxs)(`span`,{className:`term-tab-title`,children:[I===e.id?(0,C.jsx)(`input`,{autoFocus:!0,className:`term-tab-rename-input`,value:R,placeholder:e.title,onClick:e=>e.stopPropagation(),onChange:e=>z(e.target.value),onKeyDown:t=>{if(t.stopPropagation(),t.key===`Enter`&&!t.nativeEvent.isComposing){let t=R.trim();t&&g({type:`rename_terminal`,terminalId:e.id,conversationId:e.conversationId,title:t}),L(null)}else t.key===`Escape`&&L(null)},onBlur:()=>L(null)}):e.title,!e.running&&(0,C.jsx)(`span`,{className:`term-tab-exit`,children:i(`exited`,{code:e.exitCode===null?``:` ${e.exitCode}`})})]})]}),(0,C.jsx)(`button`,{type:`button`,className:`term-tab-close term-tab-rename`,title:i(`renameTerminal`),onClick:t=>{t.stopPropagation(),z(e.title),L(e.id)},children:(0,C.jsx)(f,{})}),(0,C.jsx)(`button`,{type:`button`,className:`term-tab-close`,title:i(`closeTerminal`),onClick:()=>G(e.id),children:(0,C.jsx)(l,{})})]},e.id),q=()=>{w(!0),O(null),A(E)},ee=t=>{let n=e.commands[t];n&&(w(!1),O(t),A({name:n.name,command:n.command,cwd:n.cwd??``}))},J=()=>{w(!1),O(null)},Y=()=>{let t=k.name.trim(),n=k.command.trim();if(!t||!n)return;let r={name:t,command:n,cwd:k.cwd.trim()||void 0},i=S?[...e.commands,r]:D===null?e.commands:e.commands.map((e,t)=>t===D?r:e);g({type:`save_commands`,commands:i}),J()},te=t=>{if(j===t){let n=e.commands.filter((e,n)=>n!==t);g({type:`save_commands`,commands:n}),M(null),N.current&&clearTimeout(N.current)}else M(t),N.current&&clearTimeout(N.current),N.current=setTimeout(()=>M(null),2500)},ne=S||D!==null,X=n===void 0?[`host:term-cmd-refresh`,`host:term-cmd-new`,`host:term-tab-new`].map(e=>({id:e,source:`host`})):n.filter(e=>!e.hidden),Z=(e,t)=>{let n=new Set(e);return X.filter(e=>n.has(e.id)||t&&e.source!==`host`)},Q=(e,t)=>{let n=X.find(t=>t.id===e);return n?.labelExplicit?n.label:t},$={"host:term-cmd-refresh":(0,C.jsx)(`button`,{type:`button`,className:`panel-refresh`,title:Q(`host:term-cmd-refresh`,i(`rerun`)),onClick:()=>g({type:`list_commands`}),children:(0,C.jsx)(h,{})}),"host:term-cmd-new":(0,C.jsx)(`button`,{type:`button`,className:`panel-new`,title:Q(`host:term-cmd-new`,i(`newCommand`)),onClick:q,children:(0,C.jsx)(c,{})}),"host:term-tab-new":(0,C.jsx)(`button`,{type:`button`,className:`panel-new`,title:Q(`host:term-tab-new`,i(`newTerminal`)),onClick:U,children:(0,C.jsx)(c,{})})};return(0,C.jsxs)(`div`,{className:`terminal-view`,children:[(0,C.jsxs)(`aside`,{className:`term-side term-commands ${_?`open`:``}`,children:[(0,C.jsxs)(`div`,{className:`panel-header`,children:[(0,C.jsx)(`span`,{className:`panel-title`,children:i(`commands`)}),(0,C.jsx)(`div`,{className:`panel-header-actions`,children:v(Z([`host:term-cmd-refresh`,`host:term-cmd-new`],!1),$,r)})]}),(0,C.jsx)(`div`,{className:`panel-body`,children:ne?(0,C.jsxs)(`div`,{className:`cmd-form`,children:[(0,C.jsx)(`label`,{htmlFor:`cmd-name`,children:i(`name`)}),(0,C.jsx)(`input`,{id:`cmd-name`,className:`cmd-input`,value:k.name,placeholder:i(`exampleName`),autoFocus:!0,onChange:e=>A({...k,name:e.target.value})}),(0,C.jsx)(`label`,{htmlFor:`cmd-command`,children:i(`command`)}),(0,C.jsx)(`input`,{id:`cmd-command`,className:`cmd-input`,value:k.command,placeholder:i(`exampleCommand`),onChange:e=>A({...k,command:e.target.value}),onKeyDown:e=>{e.key===`Enter`&&!e.nativeEvent.isComposing&&Y()}}),(0,C.jsxs)(`label`,{htmlFor:`cmd-cwd`,children:[i(`directory`),` `,(0,C.jsx)(`span`,{className:`cmd-hint`,children:i(`cwdHint`)})]}),(0,C.jsx)(`input`,{id:`cmd-cwd`,className:`cmd-input`,value:k.cwd,placeholder:"${pwd}",onChange:e=>A({...k,cwd:e.target.value}),onKeyDown:e=>{e.key===`Enter`&&!e.nativeEvent.isComposing&&Y()}}),(0,C.jsxs)(`div`,{className:`cmd-form-actions`,children:[(0,C.jsx)(`button`,{type:`button`,className:`btn`,onClick:J,children:i(`cancel`)}),(0,C.jsx)(`button`,{type:`button`,className:`btn primary`,disabled:!k.name.trim()||!k.command.trim(),onClick:Y,children:i(`save`)})]})]}):(0,C.jsxs)(C.Fragment,{children:[e.commands.length===0&&(0,C.jsx)(`div`,{className:`panel-empty`,children:i(`noCommands`)}),e.commands.map((e,t)=>(0,C.jsxs)(`div`,{className:`cmd-item`,children:[(0,C.jsx)(`button`,{type:`button`,className:`cmd-run`,title:i(`clickToRun`),onClick:()=>W(e),children:(0,C.jsx)(s,{})}),(0,C.jsxs)(`button`,{type:`button`,className:`cmd-main`,title:i(`clickToRun`),onClick:()=>W(e),children:[(0,C.jsx)(`span`,{className:`cmd-name`,children:e.name}),(0,C.jsx)(`span`,{className:`cmd-command`,children:e.command}),e.cwd&&(0,C.jsx)(`span`,{className:`cmd-cwd`,children:e.cwd})]}),(0,C.jsx)(`button`,{type:`button`,className:`cmd-act`,title:i(`edit`),onClick:()=>ee(t),children:(0,C.jsx)(f,{})}),(0,C.jsx)(`button`,{type:`button`,className:`cmd-act del ${j===t?`confirm`:``}`,title:i(`delete`),onClick:()=>te(t),children:j===t?i(`confirmQ`):(0,C.jsx)(u,{})})]},t))]})}),(0,C.jsxs)(`div`,{className:`term-tabs-block`,children:[(0,C.jsxs)(`div`,{className:`panel-header`,children:[(0,C.jsx)(`span`,{className:`panel-title`,children:i(`terminal`)}),v(Z([`host:term-tab-new`],!0),$,r)]}),(0,C.jsxs)(`div`,{className:`panel-body`,children:[e.terminals.length===0&&(0,C.jsx)(`div`,{className:`panel-empty`,children:i(`noTerminal`)}),B.map(K),V.length>0&&(0,C.jsxs)(`div`,{className:`term-folder`,children:[(0,C.jsxs)(`button`,{type:`button`,className:`term-folder-header ${P?`open`:``}`,title:i(`aiBashGroup`),onClick:()=>F(e=>!e),children:[(0,C.jsx)(`span`,{className:`term-folder-caret`,children:P?`▾`:`▸`}),(0,C.jsx)(`span`,{className:`term-folder-title`,children:i(`aiBashGroup`)}),(0,C.jsx)(`span`,{className:`term-folder-count`,children:V.length})]}),P&&(0,C.jsx)(`div`,{className:`term-folder-body`,children:V.map(K)})]})]})]})]}),(0,C.jsxs)(`div`,{className:`term-main`,children:[_&&(0,C.jsx)(`div`,{className:`drawer-backdrop`,onClick:()=>x(!1)}),(0,C.jsx)(`button`,{type:`button`,className:`term-side-toggle`,title:i(`commands`),onClick:()=>x(e=>!e),children:(0,C.jsx)(y,{})}),e.terminals.length===0?(0,C.jsxs)(`div`,{className:`term-empty`,children:[(0,C.jsx)(p,{className:`term-empty-icon`}),(0,C.jsx)(`div`,{className:`term-empty-title`,children:i(`builtinTerminal`)}),(0,C.jsx)(`div`,{className:`term-empty-sub`,children:i(`termEmptySub`)})]}):e.terminals.map(e=>(0,C.jsx)(T,{conversationId:e.conversationId,terminalId:e.id,command:e.command,cwd:e.cwd,title:e.title,agentBash:e.agentBash,active:e.id===d,running:e.running,exitCode:e.exitCode,register:t.register},`${e.conversationId}:${e.id}`))]})]})}export{D as TerminalPanel};
|