cc-viewer 1.9.37 → 1.9.39
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/README.md +4 -0
- package/cli.js +4 -0
- package/dist/assets/App-CpjhCyrl.js +2 -0
- package/dist/assets/App-DwLJPKiz.css +1 -0
- package/dist/assets/{ArchivePreview-BBXuZnGC.js → ArchivePreview-BHhhDCbz.js} +1 -1
- package/dist/assets/{AudioPreview-BmqzQZGt.js → AudioPreview-B0A6FVQc.js} +1 -1
- package/dist/assets/{MdxEditorPanel-BLcS9OVC.js → MdxEditorPanel-CEZPc4wd.js} +1 -1
- package/dist/assets/{Mobile-4mZy680Y.js → Mobile-B6az-Lrt.js} +1 -1
- package/dist/assets/{ProxyStatsModal-BDLwkqxD.js → ProxyStatsModal-B2PEO1Bm.js} +1 -1
- package/dist/assets/{SubtitlePreview-ei5OtiKq.js → SubtitlePreview-Ca7FKVpv.js} +1 -1
- package/dist/assets/index-DMmTEKEL.js +2 -0
- package/dist/assets/seqResourceLoaders-BJEa97Uq.js +2 -0
- package/dist/assets/seqResourceLoaders-BdxjrasH.css +41 -0
- package/dist/index.html +1 -1
- package/node_modules/@ccv/core/src/sdk-task-label.js +70 -0
- package/package.json +1 -1
- package/server/lib/chat-queue.js +159 -31
- package/server/lib/compact-inject-guard.js +100 -0
- package/server/lib/project-prefs.js +3 -2
- package/server/lib/sdk-manager.js +113 -2
- package/server/lib/task-state.js +11 -0
- package/server/routes/preferences.js +9 -2
- package/server/routes/project-prefs.js +6 -0
- package/server/server.js +207 -0
- package/dist/assets/App-BJIeZQK0.css +0 -1
- package/dist/assets/App-C_AI6A4g.js +0 -2
- package/dist/assets/index-CVnJzK-y.js +0 -2
- package/dist/assets/seqResourceLoaders-BT5ki0J4.js +0 -2
- package/dist/assets/seqResourceLoaders-CXgVOdgW.css +0 -41
package/server/lib/task-state.js
CHANGED
|
@@ -14,6 +14,17 @@
|
|
|
14
14
|
* the single-workspace behavior is byte-identical.
|
|
15
15
|
*
|
|
16
16
|
* L1-lib: pure module, Node builtins only, no imports.
|
|
17
|
+
*
|
|
18
|
+
* PTY-vs-SDK label policy: this module deliberately does NOT filter stub
|
|
19
|
+
* entries whose subject/description are both null. A PTY stub is the intended
|
|
20
|
+
* placeholder for a task whose TaskCreated hook was lost (or fired before
|
|
21
|
+
* cc-viewer started watching) — the HUD shows `#id` for a beat until the next
|
|
22
|
+
* TaskUpdate(subject) / TaskCompleted(subject) lands. That is a live,
|
|
23
|
+
* in-flight row, NOT an SDK-mode "label-less ghost" (a terminal residue with
|
|
24
|
+
* neither description nor summary on the wire). The SDK-side label-less filter
|
|
25
|
+
* is scoped to TERMINAL entries only and lives in sdk-manager.js /
|
|
26
|
+
* sdkTaskTracker.js / @ccv/core/sdk-task-label; PTY snapshot semantics stay
|
|
27
|
+
* byte-identical here.
|
|
17
28
|
*/
|
|
18
29
|
|
|
19
30
|
/** @type {Map<string, {sessionId: string|null, tasks: Map<string, object>, lastUsedAt: number}>} */
|
|
@@ -150,9 +150,16 @@ function preferencesPost(req, res, parsedUrl, isLocal, deps) {
|
|
|
150
150
|
// prefsByProject(项目独立配置 fork)只能经 admin-only 的 /api/project-prefs/* 修改;元字段
|
|
151
151
|
// (_isLocal/_projectScoped/…)仅 GET 回包,绝不让它们经 /api/preferences 落盘污染。
|
|
152
152
|
delete incoming.prefsByProject;
|
|
153
|
-
//
|
|
154
|
-
//
|
|
153
|
+
// Scheduled tasks are writable only via /api/scheduled-tasks (admin+same-origin) — no client
|
|
154
|
+
// (admin included) may inject/clear/overwrite tasks through a prefs POST (claim CAS and schedule
|
|
155
|
+
// state validation live only in the store layer).
|
|
155
156
|
delete incoming.scheduledTasks;
|
|
157
|
+
// contextCompaction is a rule list; a non-array value would be persisted verbatim and the web
|
|
158
|
+
// normalizer would silently collapse it to the built-in default rule. Drop malformed values,
|
|
159
|
+
// mirroring the fork-side cleanPatch guard (routes/project-prefs.js).
|
|
160
|
+
if (Object.prototype.hasOwnProperty.call(incoming, 'contextCompaction') && !Array.isArray(incoming.contextCompaction)) {
|
|
161
|
+
delete incoming.contextCompaction;
|
|
162
|
+
}
|
|
156
163
|
for (const k of Object.keys(incoming)) if (k[0] === '_') delete incoming[k];
|
|
157
164
|
// IM bridge configs 同理:只能经 admin-only 的 /api/dingtalk/config、/api/im/* 修改,禁止借
|
|
158
165
|
// /api/preferences 植入凭据。
|
|
@@ -39,6 +39,12 @@ function cleanPatch(patch) {
|
|
|
39
39
|
const out = { ...patch };
|
|
40
40
|
for (const k of Object.keys(out)) if (k[0] === '_') delete out[k];
|
|
41
41
|
stripSensitive(out); // 含 auth/IM + logDir/claudeConfigDir + prefsByProject(单一来源)
|
|
42
|
+
// contextCompaction is a rule list; a non-array value would otherwise be persisted as-is and
|
|
43
|
+
// break older consumers. Drop malformed values rather than storing them (frontend normalizer
|
|
44
|
+
// already degrades a missing key to the built-in default rule).
|
|
45
|
+
if (Object.prototype.hasOwnProperty.call(out, 'contextCompaction') && !Array.isArray(out.contextCompaction)) {
|
|
46
|
+
delete out.contextCompaction;
|
|
47
|
+
}
|
|
42
48
|
return out;
|
|
43
49
|
}
|
|
44
50
|
|
package/server/server.js
CHANGED
|
@@ -54,6 +54,7 @@ import { setProxyStatsListener, setSlowUpstreamListener } from './lib/proxy/prox
|
|
|
54
54
|
import * as imCore from './lib/im/im-bridge-core.js';
|
|
55
55
|
import * as imProcMgr from './lib/im/im-process-manager.js';
|
|
56
56
|
import * as chatQueue from './lib/chat-queue.js';
|
|
57
|
+
import { createCompactInjectGuard } from './lib/compact-inject-guard.js';
|
|
57
58
|
import { reportSwallowed } from './lib/error-report.js';
|
|
58
59
|
import { takeInheritedAccessToken } from './lib/access-token.js';
|
|
59
60
|
import { cancelAutoApproveState } from './lib/auto-approve.js';
|
|
@@ -1950,6 +1951,42 @@ async function setupTerminalWebSocket(httpServer) {
|
|
|
1950
1951
|
writeToPtySequentialFor,
|
|
1951
1952
|
getPtyKind,
|
|
1952
1953
|
isStreaming: () => streamingState.active,
|
|
1954
|
+
// Target-scoped busy probes for injectCommand (context compaction): scope the idle check
|
|
1955
|
+
// to the ANCHOR's workspace, not the globally-bound one. The scope key MUST be normalized
|
|
1956
|
+
// with normalizeProducerScope first — producers fold the BOUND project to the '' bucket
|
|
1957
|
+
// (scopeKeyForEntry / _resolveScopeForHookPayload), so a raw `scopeKeyOf(boundName, …)`
|
|
1958
|
+
// would read a never-written bucket and report a streaming bound TUI as idle (review P0).
|
|
1959
|
+
isStreamingFor: (anchor) => {
|
|
1960
|
+
if (!anchor || typeof anchor !== 'object') return streamingState.active;
|
|
1961
|
+
const p = anchor.project || (anchor.cwd ? projectKeyForCwd(anchor.cwd) : null) || null;
|
|
1962
|
+
const inst = (typeof anchor.instanceKey === 'string' && anchor.instanceKey) || null;
|
|
1963
|
+
const sc = normalizeProducerScope({ project: p, instance: inst }, _projectName || '');
|
|
1964
|
+
const direct = scopeKeyOf(sc.project, sc.instance);
|
|
1965
|
+
if (streamingStateFor(direct).active === true) return true;
|
|
1966
|
+
// Anchor without an instance key (a project-only view of parallel workspaces): the producer
|
|
1967
|
+
// writes buckets keyed `project\0instance`, so a project-level direct lookup misses — also scan
|
|
1968
|
+
// every active instance bucket under this project.
|
|
1969
|
+
if (!sc.instance && sc.project) {
|
|
1970
|
+
const prefix = `${sc.project}\0`;
|
|
1971
|
+
for (const k of activeStreamingScopes()) { if (k.startsWith(prefix)) return true; }
|
|
1972
|
+
}
|
|
1973
|
+
return false;
|
|
1974
|
+
},
|
|
1975
|
+
isTurnActiveFor: (anchor) => {
|
|
1976
|
+
if (!anchor || typeof anchor !== 'object') return turnActive.active === true;
|
|
1977
|
+
const p = anchor.project || (anchor.cwd ? projectKeyForCwd(anchor.cwd) : null) || null;
|
|
1978
|
+
const inst = (typeof anchor.instanceKey === 'string' && anchor.instanceKey) || null;
|
|
1979
|
+
const sc = normalizeProducerScope({ project: p, instance: inst }, _projectName || '');
|
|
1980
|
+
const direct = scopeKeyOf(sc.project, sc.instance);
|
|
1981
|
+
if (turnStateFor(direct).active === true) return true;
|
|
1982
|
+
if (!sc.instance && sc.project) {
|
|
1983
|
+
const prefix = `${sc.project}\0`;
|
|
1984
|
+
for (const k of activeTurnScopes()) { if (k.startsWith(prefix)) return true; }
|
|
1985
|
+
}
|
|
1986
|
+
return false;
|
|
1987
|
+
},
|
|
1988
|
+
getPtyKindFor: (anchor) => getPtyKindFor(anchor),
|
|
1989
|
+
getQueueSnapshot: (anchor) => chatQueue.getSnapshot(anchor),
|
|
1953
1990
|
hasPendingApproval: () => pendingAskHooks.size > 0 || pendingPermHooks.size > 0,
|
|
1954
1991
|
hasExternalInjection: () => imCore.anyActiveInjection(),
|
|
1955
1992
|
hasLivePtyFor: (anchor) => {
|
|
@@ -3167,6 +3204,147 @@ async function setupTerminalWebSocket(httpServer) {
|
|
|
3167
3204
|
catch (e2) { reportSwallowed('server.sdk-send-failed-send', e2); }
|
|
3168
3205
|
});
|
|
3169
3206
|
}
|
|
3207
|
+
} else if (msg.type === 'compact-inject') {
|
|
3208
|
+
// Context compaction: after the user agrees via the frontend confirm bar, request injection of `/compact <script>`.
|
|
3209
|
+
// Trigger decisions live in the frontend; the server does authoritative idle validation + anchor routing + multi-tab dedup.
|
|
3210
|
+
// The compact-inject-done ack goes only to the initiating ws (directed); on success broadcast
|
|
3211
|
+
// context-compaction-injected so other tabs close the bar + enter cooldown.
|
|
3212
|
+
const reply = (payload) => {
|
|
3213
|
+
try { if (ws.readyState === 1) ws.send(JSON.stringify({ type: 'compact-inject-done', reqId: payload.reqId, ...payload })); }
|
|
3214
|
+
catch (e) { reportSwallowed('server.compact-inject.reply', e); }
|
|
3215
|
+
};
|
|
3216
|
+
const reqId = (typeof msg.reqId === 'string' && /^[A-Za-z0-9_-]{1,64}$/.test(msg.reqId)) ? msg.reqId : null;
|
|
3217
|
+
const text = typeof msg.text === 'string' ? msg.text.trim() : '';
|
|
3218
|
+
const project = (typeof msg.project === 'string' && msg.project) ? msg.project : null;
|
|
3219
|
+
const instanceKey = (typeof msg.instanceKey === 'string' && msg.instanceKey) ? msg.instanceKey : null;
|
|
3220
|
+
const anchor = (project || instanceKey) ? { project: project || undefined, instanceKey: instanceKey || undefined } : null;
|
|
3221
|
+
// 960K forced compaction: the only path allowed to inject mid-stream (interrupts the current session). Other sources never inject mid-stream.
|
|
3222
|
+
const isForce = msg.force === true;
|
|
3223
|
+
if (!reqId || !/^\/compact(\s|$)/.test(text) || text.length > 20000) { reply({ reqId, ok: false, reason: 'bad-text' }); return; }
|
|
3224
|
+
if (!anchor) { reply({ reqId, ok: false, reason: 'no-anchor' }); return; }
|
|
3225
|
+
|
|
3226
|
+
// Resolve the target's real identity (broadcast/dedup keys use the resolved value; never echo the raw project — a raw basename
|
|
3227
|
+
// for projects containing spaces/CJK would be silently dropped).
|
|
3228
|
+
let resolvedProject = project;
|
|
3229
|
+
let resolvedInstance = instanceKey;
|
|
3230
|
+
|
|
3231
|
+
if (isSdkMode) {
|
|
3232
|
+
const gate = _sdkGetTurnGate ? _sdkGetTurnGate(anchor) : null;
|
|
3233
|
+
if (!gate) { reply({ reqId, ok: false, reason: 'session-inactive' }); return; }
|
|
3234
|
+
resolvedInstance = gate.instanceKey || instanceKey;
|
|
3235
|
+
// Atomic gate: idle + no turn in flight + no pending approval + empty queue; otherwise reply busy so the frontend retries next turn.
|
|
3236
|
+
// 960K forced compaction skips the idle gate (it exists precisely to interrupt a busy current turn).
|
|
3237
|
+
if (!isForce && !gate.idle) { reply({ reqId, ok: false, reason: 'busy' }); return; }
|
|
3238
|
+
} else {
|
|
3239
|
+
// PTY mode: target liveness precheck (a dead target is rejected immediately, no polling). Use the module-level
|
|
3240
|
+
// _ptyGetKindFor/_ptyListLive (pty-manager is wired at init); the WS handler scope
|
|
3241
|
+
// has no local destructuring from await import.
|
|
3242
|
+
const live = (() => {
|
|
3243
|
+
try {
|
|
3244
|
+
if (instanceKey) return _ptyGetKindFor ? _ptyGetKindFor({ instanceKey }) === 'claude' : undefined;
|
|
3245
|
+
if (project) return _ptyListLive ? _ptyListLive().some((pty) => pty.ptyKind === 'claude' && projectKeyForCwd(pty.cwd) === project) : undefined;
|
|
3246
|
+
} catch (e) { reportSwallowed('server.compact-inject.liveness', e); }
|
|
3247
|
+
return undefined;
|
|
3248
|
+
})();
|
|
3249
|
+
if (live === false) { reply({ reqId, ok: false, reason: 'target-gone' }); return; }
|
|
3250
|
+
}
|
|
3251
|
+
|
|
3252
|
+
// Dedup key: the resolved target identity (project + instanceKey). When project is missing, degrade to the instance key
|
|
3253
|
+
// (scopeKeyOf(null, inst) collapses to the BOUND_SCOPE ''); never treat an empty-key badScope as a
|
|
3254
|
+
// fake duplicate success (that would make the frontend markInjected + cooldown while nothing was injected).
|
|
3255
|
+
const scopeKey = resolvedProject
|
|
3256
|
+
? scopeKeyOf(resolvedProject, resolvedInstance)
|
|
3257
|
+
: (resolvedInstance ? `inst:${resolvedInstance}` : null);
|
|
3258
|
+
if (!scopeKey) { reply({ reqId, ok: false, reason: 'no-anchor' }); return; }
|
|
3259
|
+
const g = compactInjectGuard.tryBegin(scopeKey);
|
|
3260
|
+
// In-flight ≠ succeeded: the lock holder may still be polling for idle; if it eventually fails, treating it as duplicate would let
|
|
3261
|
+
// this end fake success (nothing injected). In-flight replies busy (retryable); only the success window replies duplicate (review P2-3).
|
|
3262
|
+
if (!g.allowed) {
|
|
3263
|
+
if (g.inFlight) { reply({ reqId, ok: false, reason: 'busy' }); return; }
|
|
3264
|
+
reply({ reqId, ok: true, duplicate: true }); return;
|
|
3265
|
+
}
|
|
3266
|
+
|
|
3267
|
+
const finishOk = () => {
|
|
3268
|
+
compactInjectGuard.commit(scopeKey);
|
|
3269
|
+
reply({ reqId, ok: true });
|
|
3270
|
+
// Broadcast so other tabs in the same scope close the bar + enter cooldown (converged by resolved identity).
|
|
3271
|
+
try { broadcastWsMessage({ type: 'context-compaction-injected', project: resolvedProject || undefined, instanceKey: resolvedInstance || undefined, ts: Date.now() }); }
|
|
3272
|
+
catch (e) { reportSwallowed('server.compact-inject.broadcast', e); }
|
|
3273
|
+
};
|
|
3274
|
+
const finishFail = (reason) => {
|
|
3275
|
+
// busy / failure both release immediately, not occupying the window, allowing genuine retries.
|
|
3276
|
+
compactInjectGuard.release(scopeKey);
|
|
3277
|
+
reply({ reqId, ok: false, reason });
|
|
3278
|
+
};
|
|
3279
|
+
|
|
3280
|
+
if (isSdkMode) {
|
|
3281
|
+
// 960K forced compaction: enqueue + immediate send-now (once the current turn is interrupted, drain pushes out /compact).
|
|
3282
|
+
if (isForce) {
|
|
3283
|
+
if (!_sdkForceSendUserMessage) { finishFail('no-deps'); return; }
|
|
3284
|
+
try {
|
|
3285
|
+
const result = _sdkForceSendUserMessage(text, { project: resolvedProject || undefined, instanceKey: resolvedInstance || undefined });
|
|
3286
|
+
// force interrupt calls _cancelAllApprovals: broadcast close signals for the cancelled approval popups,
|
|
3287
|
+
// otherwise the popups hang forever (a deleted pending cannot recover via reconnect replay).
|
|
3288
|
+
const cancelled = (result && Array.isArray(result.cancelled)) ? result.cancelled : [];
|
|
3289
|
+
try { _broadcastApprovalCloses(cancelled, 'Force compaction'); } catch (e) { reportSwallowed('server.compact-inject.approval-close', e); }
|
|
3290
|
+
finishOk();
|
|
3291
|
+
} catch (err) {
|
|
3292
|
+
reportSwallowed('server.compact-inject.sdk-force', err);
|
|
3293
|
+
if (err && err.code === 'not-delivered') { compactInjectGuard.rollback(scopeKey); finishFail('not-delivered'); }
|
|
3294
|
+
else if (err && err.code === 'busy') { finishFail('busy'); } // dispatch slot occupied: retryable, no fake success
|
|
3295
|
+
else finishFail('error');
|
|
3296
|
+
}
|
|
3297
|
+
return;
|
|
3298
|
+
}
|
|
3299
|
+
if (!_sdkSendUserMessage) { finishFail('no-deps'); return; }
|
|
3300
|
+
// Ack on ACCEPTANCE — sendUserMessage's promise resolves only when the turn SETTLES
|
|
3301
|
+
// (cli.js:987: never await it), so the ack must fire synchronously, not behind it.
|
|
3302
|
+
// But an early ROUTING failure surfaces as an immediate rejection (`not-delivered`
|
|
3303
|
+
// on a teardown-raced/closed query, thrown at the first await inside the async fn) —
|
|
3304
|
+
// map that to a directed failure ack so the client doesn't fake-success + cooldown
|
|
3305
|
+
// for a `/compact` that never landed. The guard's success window is likewise rolled
|
|
3306
|
+
// back via release() so a real retry isn't deduped for 60s.
|
|
3307
|
+
let p;
|
|
3308
|
+
try {
|
|
3309
|
+
p = _sdkSendUserMessage(text, { project: resolvedProject || undefined, instanceKey: resolvedInstance || undefined });
|
|
3310
|
+
} catch (err) {
|
|
3311
|
+
reportSwallowed('server.compact-inject.sdk', err);
|
|
3312
|
+
finishFail('error');
|
|
3313
|
+
return;
|
|
3314
|
+
}
|
|
3315
|
+
if (p && typeof p.catch === 'function') {
|
|
3316
|
+
p.catch((err) => {
|
|
3317
|
+
reportSwallowed('server.compact-inject.sdk', err);
|
|
3318
|
+
if (err && err.code === 'not-delivered') {
|
|
3319
|
+
// Early routing failure: revoke the optimistic ack from just now (close the bar with a failure hint + roll back the dedup window).
|
|
3320
|
+
compactInjectGuard.rollback(scopeKey);
|
|
3321
|
+
reply({ reqId, ok: false, reason: 'not-delivered' });
|
|
3322
|
+
}
|
|
3323
|
+
});
|
|
3324
|
+
}
|
|
3325
|
+
finishOk();
|
|
3326
|
+
} else {
|
|
3327
|
+
// 960K forced compaction (PTY): enqueue + sendNow — write focus-in+ESC to interrupt the current generation,
|
|
3328
|
+
// poll for idle, then bracketed-paste /compact. Never a blind write (on failure requeue; frontend ack failure is retryable).
|
|
3329
|
+
if (isForce) {
|
|
3330
|
+
try {
|
|
3331
|
+
const ptyAnchor = { project: resolvedProject || undefined, instanceKey: resolvedInstance || undefined };
|
|
3332
|
+
const item = chatQueue.enqueue(text, ptyAnchor);
|
|
3333
|
+
if (!item) { finishFail('error'); return; }
|
|
3334
|
+
const started = chatQueue.sendNow(item.id, ptyAnchor);
|
|
3335
|
+
if (started) { finishOk(); return; }
|
|
3336
|
+
// sendNow did not start (slot occupied/external injection): remove the just-enqueued /compact from the queue — otherwise it would be
|
|
3337
|
+
// auto-injected as an ordinary message during a later rescue/drain, chaining duplicate compactions with the frontend's busy retry (ghost item).
|
|
3338
|
+
try { chatQueue.remove(item.id, ptyAnchor); } catch (e) { reportSwallowed('server.compact-inject.pty-force.remove', e); }
|
|
3339
|
+
finishFail('busy'); // retryable, the frontend forces again next turn
|
|
3340
|
+
} catch (err) { reportSwallowed('server.compact-inject.pty-force', err); finishFail('error'); }
|
|
3341
|
+
return;
|
|
3342
|
+
}
|
|
3343
|
+
chatQueue.injectCommand(text, { project: resolvedProject || undefined, instanceKey: resolvedInstance || undefined })
|
|
3344
|
+
.then((r) => { if (r && r.ok) finishOk(); else finishFail((r && r.reason) || 'error'); })
|
|
3345
|
+
.catch((err) => { reportSwallowed('server.compact-inject.pty', err); finishFail('error'); });
|
|
3346
|
+
}
|
|
3347
|
+
return;
|
|
3170
3348
|
} else if (msg.type === 'sdk-interrupt') {
|
|
3171
3349
|
// Stop button in SDK mode — interrupt current turn, keep session alive.
|
|
3172
3350
|
// Streaming-state reconciliation comes from the wire path (proxy →
|
|
@@ -3522,6 +3700,15 @@ function _emitTurnEnd(sessionId, ts, transcriptPath = null, scope = null) {
|
|
|
3522
3700
|
// _scheduleTurnEndBroadcast entry. chatQueue no-ops internally when uninitialized
|
|
3523
3701
|
// (SDK mode / tests that never ran startViewer).
|
|
3524
3702
|
try { chatQueue.onTurnEnd(sid, t); } catch { /* best-effort */ }
|
|
3703
|
+
// Compaction dedup window: after a turn ends, the dedup window of the last successful injection can be released (allowing the next confirmation).
|
|
3704
|
+
// This covers PTY; the SDK side is cleared separately by the sdk-compact broadcast. The production-side scope is already normalized (instances folded),
|
|
3705
|
+
// while the injecting guard's key carries the instance stamp, so clear all instance keys by project (clearProject) rather than a single clearSuccess (review P2-2).
|
|
3706
|
+
try {
|
|
3707
|
+
const proj = sc.project || (_projectName || '');
|
|
3708
|
+
// minAgeMs=success window: a window younger than 60s since the last successful injection is kept — it belongs to the interrupted round's result;
|
|
3709
|
+
// clearing immediately would let multiple tabs chain forced compactions through the gap while compaction is still running (review P1-3). Old windows (≥60s) release normally.
|
|
3710
|
+
if (proj) compactInjectGuard.clearProject(proj, { minAgeMs: 60000 });
|
|
3711
|
+
} catch (e) { reportSwallowed('server.compact-inject.guard-clear', e); }
|
|
3525
3712
|
if (typeof _onTurnEndBroadcastForTests === 'function') {
|
|
3526
3713
|
try { _onTurnEndBroadcastForTests({ sessionId: sid, ts: t }); }
|
|
3527
3714
|
catch (e) { if (process.env.NODE_ENV === 'test') throw e; /* prod 不让测试桩污染 */ }
|
|
@@ -4115,6 +4302,15 @@ function isIdAddressedApprovalClear(msg) {
|
|
|
4115
4302
|
}
|
|
4116
4303
|
|
|
4117
4304
|
export function broadcastWsMessage(msg) { if (terminalWss) {
|
|
4305
|
+
// A real SDK compaction happened (compact_boundary) → release that scope's injection dedup window (allowing the next confirmation).
|
|
4306
|
+
// Clear it on the way before broadcasting; frame dispatch is unaffected; sdk-compact carries its own cwd + instanceKey.
|
|
4307
|
+
if (msg && typeof msg === 'object' && msg.type === 'sdk-compact') {
|
|
4308
|
+
try {
|
|
4309
|
+
const cp = msg.cwd ? projectKeyForCwd(msg.cwd) : null;
|
|
4310
|
+
const gk = scopeKeyOf(cp || (_projectName || ''), msg.instanceKey || null);
|
|
4311
|
+
if (gk) compactInjectGuard.clearSuccess(gk);
|
|
4312
|
+
} catch (e) { reportSwallowed('server.compact-inject.guard-clear-sdk', e); }
|
|
4313
|
+
}
|
|
4118
4314
|
// SDK multi-session (2026-10-12): a cwd-tagged frame belongs to one workspace's session.
|
|
4119
4315
|
// Route it only to clients viewing that workspace (or the bound view with no ?project=),
|
|
4120
4316
|
// so a background workspace's approval/queue/spinner never bleeds into the foreground.
|
|
@@ -4218,6 +4414,10 @@ export function setSdkCancelApproval(fn) { _sdkCancelApproval = fn; }
|
|
|
4218
4414
|
let _sdkSendUserMessage = null;
|
|
4219
4415
|
export function setSdkSendUserMessage(fn) { _sdkSendUserMessage = fn; }
|
|
4220
4416
|
|
|
4417
|
+
/** Reference to sdk-manager's forceSendUserMessage (set by cli.js after import) — 960K forced compaction. */
|
|
4418
|
+
let _sdkForceSendUserMessage = null;
|
|
4419
|
+
export function setSdkForceSendUserMessage(fn) { _sdkForceSendUserMessage = fn; }
|
|
4420
|
+
|
|
4221
4421
|
/** Reference to sdk-manager's interruptTurn (set by cli.js after import). */
|
|
4222
4422
|
let _sdkInterruptTurn = null;
|
|
4223
4423
|
export function setSdkInterruptTurn(fn) { _sdkInterruptTurn = fn; }
|
|
@@ -4248,6 +4448,13 @@ export function setSdkGetMcpStatusSnapshot(fn) { _sdkGetMcpStatusSnapshot = fn;
|
|
|
4248
4448
|
let _sdkGetSessionStateSnapshot = null;
|
|
4249
4449
|
export function setSdkGetSessionStateSnapshot(fn) { _sdkGetSessionStateSnapshot = fn; }
|
|
4250
4450
|
|
|
4451
|
+
/** sdk-manager's getTurnGate (atomic can-start-turn gate) for context-compaction inject. */
|
|
4452
|
+
let _sdkGetTurnGate = null;
|
|
4453
|
+
export function setSdkGetTurnGate(fn) { _sdkGetTurnGate = fn; }
|
|
4454
|
+
|
|
4455
|
+
/** Per-scope dedupe for context-compaction injects (one confirm → one `/compact`). */
|
|
4456
|
+
const compactInjectGuard = createCompactInjectGuard();
|
|
4457
|
+
|
|
4251
4458
|
/** Reference to sdk-manager's getSdkTaskSnapshot (set by cli.js after import). */
|
|
4252
4459
|
let _sdkGetSdkTaskSnapshot = null;
|
|
4253
4460
|
export function setSdkGetSdkTaskSnapshot(fn) { _sdkGetSdkTaskSnapshot = fn; }
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
._liveTag_8g4c3_3{position:relative;display:inline-flex;align-items:center;justify-content:flex-start;border-radius:999px;border:1px solid;border-color:var(--ctx-color);color:var(--ctx-color);padding:0 10px;height:100%;font-size:12px;line-height:1;overflow:hidden;transition:border-color .3s,color .3s;white-space:nowrap;background:var(--bg-base-pure)}._liveTagFill_8g4c3_23{position:absolute;left:0;top:0;bottom:0;width:var(--ctx-percent, 0);background-color:var(--ctx-color);background-image:repeating-linear-gradient(135deg,rgba(255,255,255,.25) 0,rgba(255,255,255,.25) 2px,transparent 2px,transparent 7px);opacity:.35;transition:width .5s ease,background-color .3s;pointer-events:none}._liveTagContent_8g4c3_44{position:relative;z-index:1;display:inline-flex;align-items:center}._liveTagHistory_8g4c3_52{background:var(--bg-surface);border-color:var(--border-light);color:var(--text-primary)}._liveTagText_8g4c3_59{margin-left:4px;font-variant-numeric:tabular-nums}._cachePopoverPlaceholder_8g4c3_65{min-width:300px}._modeRow_fpcoi_1{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-top:10px}._modeLeft_fpcoi_9{display:flex;align-items:center;gap:10px}._modeRight_fpcoi_15{display:flex;align-items:center;gap:8px}._overrideWarn_fpcoi_22{font-size:12px;color:var(--color-warning, #d4810a)}._previewLabel_fpcoi_27{font-size:13px;color:var(--text-secondary, #888)}._previewBox_fpcoi_36{border:1px solid var(--border-primary);border-radius:8px;background:transparent;padding:12px 14px;min-height:320px;max-height:60vh;overflow:auto}._previewEmpty_fpcoi_46{font-size:13px;color:var(--text-secondary, #888)}._hint_fpcoi_51{margin-top:10px;font-size:12px;color:var(--text-secondary, #888);line-height:1.6}._dirLine_fpcoi_58{word-break:break-all}._warn_fpcoi_62{margin-top:10px;font-size:12px;color:var(--color-warning, #d4810a)}._tabRow_fpcoi_71{display:flex;align-items:flex-end;gap:8px;padding:0 4px;flex-wrap:nowrap;overflow-x:auto;overflow-y:hidden;scrollbar-width:none;-ms-overflow-style:none}._tabRow_fpcoi_71::-webkit-scrollbar{display:none}._tabBtn_fpcoi_90{display:inline-flex;align-items:center;gap:5px;padding:9px 14px;font-size:12px;line-height:1.6;border:1px solid transparent;border-radius:14px;background:transparent;color:var(--text-secondary);cursor:pointer;transition:all .2s;-webkit-user-select:none;user-select:none;white-space:nowrap;flex-shrink:0}._tabBtn_fpcoi_90:hover{color:var(--color-primary)}._tabBtn_fpcoi_90:focus-visible{outline:2px solid var(--color-primary);outline-offset:1px}._tabBtn_fpcoi_90._tabActive_fpcoi_118{background:var(--bg-container);color:var(--color-primary);border-color:var(--border-primary);border-bottom-color:var(--bg-container);border-radius:10px 10px 0 0;font-weight:500;margin-bottom:-1px;position:relative;z-index:1}._tabRow_fpcoi_71>._tabBtn_fpcoi_90._tabActive_fpcoi_118,._tabWrap_fpcoi_132:has(>._tabBtn_fpcoi_90._tabActive_fpcoi_118){position:sticky;left:0;right:0;z-index:2}[data-theme=light] ._tabBtn_fpcoi_90._tabActive_fpcoi_118{box-shadow:0 -3px 8px #0000000f}._editorBox_fpcoi_33{background:var(--bg-container);border-radius:8px;overflow:hidden;padding:4px;position:relative}[data-theme=light] ._editorBox_fpcoi_33{box-shadow:0 3px 8px #00000014}._editorBox_fpcoi_33 .ant-input{background:transparent;border:1px solid var(--border-primary);border-radius:8px;box-shadow:none;padding:12px 14px;font-size:12px;line-height:1.5;color:var(--text-primary)}._editorBox_fpcoi_33 .ant-input:hover{border-color:var(--border-primary);background:transparent}._editorBox_fpcoi_33 .ant-input:focus{border-color:var(--color-primary-pale);box-shadow:none}._editorBox_fpcoi_33 .ant-input[disabled]{color:var(--text-muted);background:transparent}._tabWrap_fpcoi_132{position:relative;display:inline-flex;align-items:center;flex-shrink:0}._tabTitle_fpcoi_199{white-space:nowrap}._tabDelete_fpcoi_204{position:absolute;top:2px;inset-inline-end:4px;width:14px;height:14px;border-radius:50%;background:var(--bg-elevated);border:1px solid var(--border-primary);color:var(--text-secondary);font-size:10px;line-height:1;display:flex;align-items:center;justify-content:center;cursor:pointer;opacity:0;transition:opacity .15s;z-index:2}._tabWrap_fpcoi_132:hover ._tabDelete_fpcoi_204{opacity:1}._tabDelete_fpcoi_204:hover{color:var(--color-error, #d4380d);border-color:var(--color-error, #d4380d)}@media(max-width:768px){._tabDelete_fpcoi_204{opacity:1}}._addBtn_fpcoi_237{display:inline-flex;align-items:center;align-self:center;gap:5px;padding:6px 14px;font-size:12px;line-height:1.6;margin-left:4px;margin-bottom:2px;border:none;border-radius:14px;background:transparent;color:var(--text-muted);cursor:pointer;transition:background .15s,color .15s;-webkit-user-select:none;user-select:none;white-space:nowrap;flex-shrink:0}._addBtn_fpcoi_237:hover{color:var(--color-primary);background:var(--bg-surface)}._addBtn_fpcoi_237:disabled{cursor:not-allowed;opacity:.5}[data-theme=light] ._addBtn_fpcoi_237{color:var(--text-secondary)}._scopeBadge_fpcoi_270{font-size:10px;line-height:1.4;padding:0 4px;border-radius:6px;background:var(--bg-surface);color:var(--text-muted)}._scopeBadgeDisabled_fpcoi_280{color:var(--color-warning, #d48806)}._tabBtn_fpcoi_90._tabDisabled_fpcoi_285{opacity:.55}._builtinScopeRow_fpcoi_290{display:inline-flex;align-items:center;gap:6px;margin-left:12px}._dirtyDot_fpcoi_298{width:6px;height:6px;border-radius:50%;background:var(--color-primary);flex-shrink:0}._titleRow_fpcoi_307{display:inline-flex;align-items:center;gap:8px}._helpBtn_fpcoi_315{align-self:center;width:16px;height:16px;border-radius:50%;border:1px solid var(--border-primary);background:var(--bg-elevated);color:var(--text-secondary);font-size:11px;line-height:1;display:inline-flex;align-items:center;justify-content:center;cursor:help;flex-shrink:0;-webkit-user-select:none;user-select:none}._helpBtn_fpcoi_315:hover{color:var(--color-primary);border-color:var(--color-primary)}._paramDocBtn_fpcoi_338{align-self:center;height:18px;padding:0 8px;border-radius:999px;border:1px solid var(--border-primary);background:var(--bg-elevated);color:var(--text-secondary);font-size:11px;font-weight:400;line-height:1;display:inline-flex;align-items:center;justify-content:center;cursor:pointer;flex-shrink:0;-webkit-user-select:none;user-select:none;white-space:nowrap;max-width:40vw;overflow:hidden;text-overflow:ellipsis}._paramDocBtn_fpcoi_338:hover{color:var(--color-primary);border-color:var(--color-primary)}._paramDocBtn_fpcoi_338:focus-visible{outline:2px solid var(--color-primary);outline-offset:1px}._docBox_fpcoi_370{max-height:65vh;overflow:auto;font-size:13px;line-height:1.6}._docIntro_fpcoi_379{color:var(--text-secondary);font-size:12px;line-height:1.6;margin:0 0 12px;padding-bottom:10px;border-bottom:1px solid var(--border-primary)}._addModalBody_fpcoi_389{display:flex;flex-direction:column;gap:14px;margin-top:4px}._addModalField_fpcoi_395{display:flex;flex-direction:column;gap:6px}._fieldLabelRow_fpcoi_400{display:inline-flex;align-items:center;gap:6px;font-size:13px;color:var(--text-secondary, #888)}._addError_fpcoi_408{font-size:12px;color:var(--color-error, #d4380d)}._presetSelect_fpcoi_412,._addNameAutoComplete_fpcoi_416{width:100%}._presetMatched_fpcoi_419{font-size:11px;color:var(--color-text-secondary, #888)}._panel_1nxl3_1{display:flex;flex-direction:column;gap:14px}._required_1nxl3_7{margin-left:2px;color:var(--color-error-light, #ff7b7b)}._optional_1nxl3_12{margin-left:6px;font-size:12px;font-weight:400;color:var(--text-secondary)}._row_1nxl3_19{display:flex;align-items:center;justify-content:space-between;gap:12px}._label_1nxl3_26{font-size:14px;font-weight:500}._control_1nxl3_31{display:inline-flex;align-items:center;gap:10px}._field_1nxl3_37{display:flex;flex-direction:column;gap:6px}._fieldLabel_1nxl3_43{font-size:13px;color:var(--text-secondary)}._help_1nxl3_48{font-size:12px;color:var(--text-secondary);line-height:1.4}._warn_1nxl3_54{font-size:12px;line-height:1.5;color:var(--color-error-light, #ff7b7b)}._hint_1nxl3_60{font-size:12px;line-height:1.5;color:var(--text-secondary)}._helpIcon_1nxl3_67{margin-left:6px;color:var(--text-tertiary, #999);cursor:help;font-size:13px}._detailsToggle_1nxl3_74{display:inline-flex;align-items:center;gap:5px;align-self:flex-start;padding:0;border:none;background:none;cursor:pointer;font-size:12px;color:var(--text-secondary)}._detailsToggle_1nxl3_74:hover{color:var(--text-primary, var(--text-secondary))}._details_1nxl3_74{display:flex;flex-direction:column;gap:10px}._actions_1nxl3_98{display:flex;justify-content:flex-end;gap:10px;margin-top:16px;padding-top:16px;border-top:1px solid var(--border-secondary)}._testBtn_1nxl3_108{margin-right:auto}._tabRow_1q32a_4{display:flex;align-items:flex-end;gap:6px;padding:0 8px;flex-wrap:nowrap;overflow-x:auto;overflow-y:hidden;scrollbar-width:none;-ms-overflow-style:none}._tabRow_1q32a_4::-webkit-scrollbar{display:none}._tabBtn_1q32a_24{display:inline-flex;align-items:center;gap:7px;padding:8px 16px;font-size:14px;line-height:1.5;border:1px solid transparent;border-radius:10px;background:transparent;color:var(--text-secondary);cursor:pointer;transition:color .18s,border-color .18s,background .18s;white-space:nowrap;flex-shrink:0;-webkit-user-select:none;user-select:none}._tabBtn_1q32a_24:hover{color:var(--color-primary)}._tabBtn_1q32a_24._tabBtnActive_1q32a_52,._tabBtn_1q32a_24._tabBtnActive_1q32a_52:hover{background:var(--bg-container);color:var(--color-primary);border-color:var(--border-primary);border-bottom:2px solid var(--bg-container);border-radius:10px 10px 0 0;font-weight:500;margin-bottom:-1px;position:relative;z-index:2}._toolBody_1q32a_8{border:1px solid var(--border-primary);border-top:none;border-radius:8px;background:var(--bg-container);padding:18px 20px;min-width:0}[data-theme=light] ._toolBody_1q32a_8{box-shadow:0 3px 8px #00000014}[data-theme=light] ._tabBtnActive_1q32a_52{box-shadow:0 -3px 8px #0000000f}[data-theme=dark] ._toolBody_1q32a_8 .ant-input,[data-theme=dark] ._toolBody_1q32a_8 .ant-input-affix-wrapper,[data-theme=dark] ._toolBody_1q32a_8 .ant-select-selector{background-color:var(--bg-elevated)}._scrollBody_mzpnt_1{height:100%;box-sizing:border-box;overflow-y:auto;overflow-x:hidden;scrollbar-gutter:stable;padding:4px 2px;background:var(--bg-container)}._headerBar_mzpnt_15{display:flex;align-items:center;gap:8px}._refreshBtn_mzpnt_21{flex:0 0 auto}._statusTag_mzpnt_27{display:inline-flex;align-items:center;gap:8px;margin-left:auto}._statusTag_mzpnt_27 .ant-tag{margin-inline-end:0}._center_mzpnt_38{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:10px;padding:40px 0;color:var(--text-secondary)}._hint_mzpnt_48{color:var(--text-secondary);font-size:13px}._chip_dnl8s_4{position:relative;line-height:0;cursor:pointer;-webkit-user-select:none;user-select:none;transition:opacity .15s}._chip_dnl8s_4:hover{opacity:.75}._logo_dnl8s_16{display:block;transition:color .15s}._connecting_dnl8s_22{opacity:.5}._dotError_dnl8s_27{position:absolute;right:-2px;top:-2px;width:6px;height:6px;border-radius:50%;background:var(--color-error, #ff4d4f);pointer-events:none}._dotReconnecting_dnl8s_39{position:absolute;right:-2px;top:-2px;width:6px;height:6px;border-radius:50%;background:var(--color-warning, #f59e0b);pointer-events:none;animation:_imDotPulse_dnl8s_1 1.2s ease-in-out infinite}@keyframes _imDotPulse_dnl8s_1{0%,to{opacity:1}50%{opacity:.3}}@media(prefers-reduced-motion:reduce){._dotReconnecting_dnl8s_39{animation:none}}._helpIcon_1k64j_6{margin-left:6px;font-size:13px;color:var(--text-tertiary, var(--text-muted, #999));cursor:help;vertical-align:middle}._helpIconBtn_1k64j_14{background:none;border:none;padding:0;margin:0 0 0 6px;cursor:pointer;color:var(--text-tertiary, var(--text-muted, #999));font-size:13px;vertical-align:middle;display:inline-flex;align-items:center}._helpIconBtn_1k64j_14:hover{color:var(--color-primary)}._modelCard_1k64j_30{border:1px solid var(--border-secondary);border-radius:6px;padding:8px 10px;background:var(--bg-container)}._modelName_1k64j_36{font-size:13px;font-weight:600;color:var(--text-primary);margin-bottom:8px;padding-bottom:4px;border-bottom:1px solid var(--border-secondary)}._statsTable_1k64j_44{width:100%;border-collapse:collapse}._th_1k64j_48{padding:2px 12px;font-size:12px;font-family:var(--font-mono);white-space:nowrap;color:var(--text-tertiary);font-weight:400;text-align:right}._td_1k64j_57{padding:2px 12px;font-size:12px;font-family:var(--font-mono);white-space:nowrap;color:var(--text-primary);text-align:right}._label_1k64j_65{padding:2px 12px;font-size:12px;font-family:var(--font-mono);white-space:nowrap;color:var(--text-light);font-weight:400;text-align:left}._rowBorder_1k64j_74{border-bottom:1px solid var(--border-primary)}._rebuildTotalRow_1k64j_77{border-top:1px solid var(--border-light)}._rebuildTotalRow_1k64j_77 td{font-weight:600}._cachePopoverEmpty_1k64j_83{padding:8px 4px;color:var(--text-tertiary);font-size:13px}._memoryDetailTitle_1k64j_88{display:flex;align-items:center;gap:8px;min-width:0}._memoryDetailTitleText_1k64j_94{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}._toolChipGrid_1k64j_100{display:flex;flex-wrap:wrap;gap:4px;padding:2px 0 6px 2px}._cacheToolChip_1k64j_106{font-size:11px;padding:0 6px;border-radius:3px;background:var(--bg-surface);color:var(--text-secondary);line-height:18px;max-width:280px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;border:1px solid var(--border-primary);cursor:help}._titleIcon_1k64j_120{margin-right:8px}._detailMarkdownCard_1k64j_125{border:1px solid var(--border-secondary);border-radius:6px;padding:8px 10px;background:var(--bg-container)}._memoryMarkdown_1k64j_132{font-size:12.5px;line-height:1.55;color:var(--text-primary);word-break:break-word}._memoryMarkdown_1k64j_132 p{margin:0 0 6px}._memoryMarkdown_1k64j_132 ul,._memoryMarkdown_1k64j_132 ol{margin:4px 0 6px;padding-left:20px}._memoryMarkdown_1k64j_132 li{margin:2px 0}._memoryMarkdown_1k64j_132 h1,._memoryMarkdown_1k64j_132 h2,._memoryMarkdown_1k64j_132 h3,._memoryMarkdown_1k64j_132 h4{font-size:13px;font-weight:600;margin:8px 0 4px;color:var(--text-primary)}._memoryMarkdown_1k64j_132 h1{font-size:14px}._memoryMarkdown_1k64j_132 a{color:var(--primary-color, #1677ff);text-decoration:none;cursor:pointer}._memoryMarkdown_1k64j_132 a:hover{text-decoration:underline}._memoryMarkdown_1k64j_132 code{font-family:var(--font-mono);font-size:12px;padding:1px 4px;border-radius:3px;background:var(--bg-surface);color:var(--text-primary)}._memoryMarkdown_1k64j_132 pre{margin:6px 0;padding:8px 10px;border-radius:4px;background:var(--bg-surface);overflow-x:auto}._memoryMarkdown_1k64j_132 pre code{padding:0;background:transparent;font-size:12px}._memoryMarkdown_1k64j_132 blockquote{margin:4px 0;padding:2px 8px;border-left:3px solid var(--border-hover);color:var(--text-secondary)}._memoryMarkdown_1k64j_132 hr{margin:8px 0;border:none;border-top:1px solid var(--border-secondary)}._quickMenuGroup_1k64j_203{position:relative}._quickMenuRow_1k64j_207{display:flex;align-items:center;gap:6px;width:100%;background:none;border:none;color:var(--text-primary);font-size:13px;padding:6px 12px;text-align:left;cursor:pointer;border-radius:4px;white-space:nowrap}._quickMenuGroup_1k64j_203:hover ._quickMenuRow_1k64j_207,._quickMenuGroupOpen_1k64j_224 ._quickMenuRow_1k64j_207,button._quickMenuRow_1k64j_207:hover{background:var(--border-secondary)}._quickMenuRowIcon_1k64j_229{display:flex;align-items:center;color:var(--text-tertiary)}._quickMenuRowIcon_1k64j_229 svg{width:14px;height:14px}._quickMenuLabel_1k64j_240{flex:1}._quickMenuValue_1k64j_245{color:var(--text-tertiary);font-size:12px}._quickMenuCaret_1k64j_250{color:var(--text-tertiary);font-size:10px}._quickMenuSubWrap_1k64j_258{display:none;position:absolute;left:100%;bottom:-5px;padding-left:6px;z-index:1}._quickMenuGroupOpen_1k64j_224 ._quickMenuSubWrap_1k64j_258{display:block}._quickMenuSub_1k64j_258{display:flex;flex-direction:column;background:var(--bg-elevated);border:1px solid var(--border-hover);border-radius:8px;padding:4px;min-width:76px;max-height:60vh;overflow-y:auto;box-shadow:0 6px 16px #0000002e}._memoryDetailTokens_1k64j_288{margin-bottom:8px;padding-bottom:6px;border-bottom:1px solid var(--border-secondary);color:var(--text-secondary);font-size:12px;font-variant-numeric:tabular-nums}._quickMenuOption_1k64j_297{background:none;border:none;color:var(--text-primary);font-size:13px;padding:5px 12px;text-align:left;cursor:pointer;border-radius:4px;white-space:nowrap}._quickMenuOption_1k64j_297:hover{background:var(--border-secondary)}._quickMenuOption_1k64j_297._quickMenuOptionActive_1k64j_313{color:var(--color-primary);font-weight:500}._quickMenuOption_1k64j_297._quickMenuOptionDanger_1k64j_320{color:var(--color-error)}._quickMenuOption_1k64j_297._quickMenuOptionDanger_1k64j_320:hover{background:var(--color-error-bg-light)}._quickMenuOptionActive_1k64j_313._quickMenuOptionDanger_1k64j_320,._quickMenuValueDanger_1k64j_332{color:var(--color-error)}._headerBar_l0ba4_2{display:flex;align-items:center;justify-content:space-between;width:100%;height:100%}._logoWrap_l0ba4_10{display:inline-flex;align-items:center;position:relative;margin-top:14px}._logoWrapActive_l0ba4_17:after{content:"";position:absolute;top:-10px;bottom:-10px;left:0;right:-200px}._logoImage_l0ba4_26{height:24px;width:24px;border-radius:3px;vertical-align:middle;opacity:.75;transition:opacity .2s;cursor:pointer}._logoImageActive_l0ba4_36{opacity:1}._compactBtn_l0ba4_43{font-size:12px;height:30px;display:inline-flex;align-items:center;justify-content:center}._compactBtnNoBorder_l0ba4_52{width:30px;height:30px;min-width:30px;padding:0;border:none;font-size:18px;line-height:1;display:inline-flex;align-items:center;justify-content:center}._compactBtnNoBorder_l0ba4_52 .anticon{display:inline-flex;align-items:center;justify-content:center;line-height:0}._headerProjectName_l0ba4_79{font-size:12px;color:inherit;white-space:nowrap}._newProjectPlusBtn_l0ba4_88{display:inline-flex;align-items:center;justify-content:center;width:16px;height:16px;margin-inline-start:4px;padding:0;background:transparent;border:1px dashed var(--text-muted);border-radius:4px;color:var(--text-muted);font-size:10px;line-height:1;cursor:pointer;transition:color .2s,border-color .2s}._newProjectPlusBtn_l0ba4_88:hover{color:var(--text-primary);border-color:var(--text-primary)}._newProjectPlusBtn_l0ba4_88:focus,._newProjectPlusBtn_l0ba4_88:focus-visible{outline:none}._countdownStrong_l0ba4_117{font-variant-numeric:tabular-nums}._qrcodePopover_l0ba4_122{display:flex;flex-direction:column;align-items:center;padding:8px}._qrcodeSection_l0ba4_129{display:flex;flex-direction:column;align-items:center;padding:16px;margin-bottom:12px;border:1px solid var(--border-secondary);border-radius:8px;background:var(--bg-container)}._qrcodeTitle_l0ba4_140{font-size:14px;font-weight:600;color:var(--text-primary);margin-bottom:12px}._qrcodeUrlInput_l0ba4_147{margin-top:12px;font-size:12px;font-family:var(--font-mono)}._qrcodeUrlCopy_l0ba4_153{cursor:pointer;color:var(--text-tertiary);transition:color .2s}._qrcodeUrlCopy_l0ba4_153:hover{color:var(--color-primary-light)}._authSection_l0ba4_164{display:flex;flex-direction:column;align-items:stretch;box-sizing:border-box;width:100%;margin-top:12px;padding:12px;border:1px solid var(--border-secondary);border-radius:8px;background:var(--bg-container);gap:8px}._authHeaderRow_l0ba4_178{display:flex;align-items:center;justify-content:space-between}._authTitle_l0ba4_184{font-size:13px;font-weight:600;color:var(--text-primary)}._authPasswordLabel_l0ba4_190{font-size:12px;color:var(--text-secondary)}._authPasswordInput_l0ba4_195{font-size:12px;font-family:var(--font-mono)}._authSaveBtn_l0ba4_200{align-self:flex-end}._authEmptyWarn_l0ba4_204{font-size:12px;color:var(--color-error-light);line-height:1.4}._settingsGroupBox_l0ba4_212{border:1px solid var(--border-secondary);border-radius:8px;background:var(--bg-container);padding:4px 16px;margin-bottom:12px}._settingsGroupTitle_l0ba4_220{font-size:14px;font-weight:600;color:var(--text-primary);padding:12px 0 4px;border-bottom:1px solid var(--border-secondary)}._settingsItem_l0ba4_229{display:flex;justify-content:space-between;align-items:center;padding:12px 0}._settingsLabel_l0ba4_236{font-size:14px}._settingsHelpIcon_l0ba4_241{font-size:16px;color:var(--text-disabled);cursor:help;margin-left:4px}._settingsDivider_l0ba4_248{border-top:1px solid var(--border-primary);margin:12px 0}._logDirInput_l0ba4_253{margin-top:8px;background:var(--bg-base-alt);border-color:var(--border-light);color:var(--text-primary);font-family:var(--font-mono);font-size:13px}._claudeExecutableInput_l0ba4_262{width:100%;margin-top:8px;font-family:var(--font-mono);font-size:12px}._claudeExecutableHint_l0ba4_269{margin-top:6px;color:var(--text-tertiary);font-size:12px;line-height:1.5;overflow-wrap:anywhere}._tokenStatsEmpty_l0ba4_278{padding:8px 4px;color:var(--text-tertiary);font-size:13px}._tokenStatsContainer_l0ba4_285{display:flex;gap:12px;align-items:flex-start}._tokenStatsColumn_l0ba4_291{min-width:240px}._toolStatsColumn_l0ba4_295{min-width:180px}._modelCardSpaced_l0ba4_301{margin-bottom:10px}._rebuildCard_l0ba4_310{border:1px solid var(--border-secondary);border-radius:6px;padding:8px 10px;margin-top:10px;background:var(--bg-container)}._projectStatsCenter_l0ba4_319{display:flex;justify-content:center;padding:40px 0}._projectStatsEmpty_l0ba4_325{color:var(--text-tertiary);padding:40px 0;text-align:center;font-size:13px}._projectStatsContent_l0ba4_332{display:flex;flex-direction:column;gap:16px}._projectStatsUpdated_l0ba4_338{color:var(--text-muted);font-size:12px;text-align:right}._projectStatsSummary_l0ba4_344{display:grid;grid-template-columns:1fr 1fr;gap:10px}._projectStatCard_l0ba4_350{background:var(--bg-container);border:1px solid var(--border-secondary);border-radius:8px;padding:14px 12px;text-align:center}._projectStatValue_l0ba4_358{font-size:22px;font-weight:700;color:var(--text-primary);font-family:var(--font-mono);font-variant-numeric:tabular-nums}._projectStatLabel_l0ba4_366{font-size:12px;color:var(--text-tertiary);margin-top:4px}._projectStatsSection_l0ba4_372{display:flex;flex-direction:column;gap:10px}._projectStatsSectionTitle_l0ba4_378{font-size:14px;font-weight:600;color:var(--text-secondary);padding-bottom:4px;border-bottom:1px solid var(--border-secondary)}._projectStatsModelCard_l0ba4_386{background:var(--bg-container);border:1px solid var(--border-secondary);border-radius:6px;padding:10px 12px}._projectStatsModelHeader_l0ba4_393{display:flex;justify-content:space-between;align-items:center;margin-bottom:8px;padding-bottom:4px;border-bottom:1px solid var(--border-secondary)}._projectStatsModelName_l0ba4_402{font-size:13px;font-weight:600;color:var(--text-primary)}._projectStatsModelCount_l0ba4_408{font-size:12px;color:var(--text-tertiary);font-family:var(--font-mono)}._cacheCopyBtn_l0ba4_416{font-size:14px;color:var(--text-tertiary);cursor:pointer;transition:color .2s;margin-left:8px}._cacheCopyBtn_l0ba4_416:hover{color:var(--text-primary)}._cacheTokenInfo_l0ba4_428{display:flex;align-items:center;font-size:12px;font-family:var(--font-mono);color:var(--text-light);margin-bottom:8px}._cacheCodeBlock_l0ba4_441{white-space:pre-wrap;word-break:break-word;font-size:12px;line-height:1.5;color:var(--text-secondary);background:var(--bg-container);border:1px solid var(--border-primary);border-radius:4px;padding:8px;margin:4px 0;font-family:var(--font-mono)}._cacheCodeBlockSystem_l0ba4_455{white-space:pre-wrap;word-break:break-word;font-size:12px;line-height:1.5;color:var(--text-secondary);background:var(--bg-code-system);border:1px solid var(--border-code-system);border-radius:4px;padding:8px;margin:4px 0;font-family:var(--font-mono)}._cacheNavBtn_l0ba4_469{margin-left:auto;font-size:11px;color:var(--color-primary);cursor:pointer;border:1px solid var(--color-primary);border-radius:3px;padding:1px 6px;white-space:nowrap}._cacheNavBtn_l0ba4_469:hover{background:var(--color-primary-bg-light)}._cacheNavList_l0ba4_484{width:600px;max-height:300px;overflow-y:auto}._cacheNavItem_l0ba4_490{padding:4px 8px;font-size:12px;color:var(--text-secondary);cursor:pointer;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;border-radius:3px}._cacheNavItem_l0ba4_490:hover{background:var(--color-primary-bg-lighter);color:var(--text-white)}._cacheBlockHighlight_l0ba4_506{box-shadow:0 0 10px var(--color-primary-shadow);transition:box-shadow .2s ease-in}._cacheBlockHighlightFading_l0ba4_511{box-shadow:0 0 10px transparent;transition:box-shadow 3s ease-out}._cacheBorderSvg_l0ba4_516{position:absolute;top:0;right:0;bottom:0;left:0;width:100%;height:100%;pointer-events:none;overflow:visible}._cacheBorderSvgFading_l0ba4_525{opacity:0;transition:opacity 3s ease-out}._cacheBorderRect_l0ba4_530{animation:_cacheDashRotate_l0ba4_1 4s linear infinite}@keyframes _cacheDashRotate_l0ba4_1{0%{stroke-dashoffset:0}to{stroke-dashoffset:-100}}._thLeft_l0ba4_540{text-align:left}._cacheWriteToken_l0ba4_555{color:var(--color-code-orange)}._cacheReadToken_l0ba4_559{color:var(--color-success)}._cacheCtxPercent_l0ba4_563{color:var(--text-tertiary);margin-left:6px}._qrcodeIcon_l0ba4_583{width:30px;height:30px;padding:6px;box-sizing:border-box;color:var(--text-secondary);cursor:pointer;border-radius:6px;transition:color .15s ease,background-color .15s ease;display:inline-flex;align-items:center;justify-content:center;vertical-align:middle;background:none;border:none}._qrcodeIcon_l0ba4_583:hover{color:var(--text-primary);background:var(--bg-hover, rgba(0, 0, 0, .04))}._qrcodeIcon_l0ba4_583:focus-visible{outline:2px solid var(--primary-color, #1677ff);outline-offset:1px}._approvalBell_l0ba4_609{position:relative;width:30px;height:30px;padding:6px;box-sizing:border-box;color:var(--color-warning, #faad14);cursor:pointer;border-radius:6px;transition:color .15s ease,background-color .15s ease;display:inline-flex;align-items:center;justify-content:center;vertical-align:middle;background:none;border:none}._approvalBell_l0ba4_609:hover{color:var(--text-primary);background:var(--bg-hover, rgba(0, 0, 0, .04))}._approvalBell_l0ba4_609:focus-visible{outline:2px solid var(--primary-color, #1677ff);outline-offset:1px}._approvalBellBadge_l0ba4_634{position:absolute;top:0;right:0;min-width:14px;height:14px;padding:0 3px;box-sizing:border-box;background:var(--color-error, #ff4d4f);color:#fff;font-size:9px;line-height:14px;border-radius:7px;text-align:center;font-weight:600}._proxySwapIcon_l0ba4_651{margin-right:4px;font-size:11px}._proxyProfileTag_l0ba4_657{border-radius:12px;background:var(--border-secondary);border:1px solid var(--border-light);color:var(--text-tertiary);font-size:12px;cursor:pointer;transition:color .2s,border-color .2s}._proxyProfileTag_l0ba4_657:hover{color:var(--text-secondary);border-color:var(--text-disabled)}._sdkModelTag_l0ba4_673{border-radius:12px;background:var(--border-secondary);border:1px solid var(--border-light);color:var(--text-tertiary);font-size:12px;cursor:default}._activeProcessChip_l0ba4_685{margin-inline-start:4px}._projectTabsStrip_l0ba4_693{display:inline-flex;align-items:center;gap:4px;min-width:0;max-width:44vw;overflow-x:auto;scrollbar-width:none}._projectTabsStrip_l0ba4_693::-webkit-scrollbar{display:none}._projectTab_l0ba4_693{display:inline-flex;align-items:center;gap:6px;height:28px;padding:0 10px;min-width:60px;max-width:180px;border-radius:12px;background:var(--border-secondary);border:1px solid var(--border-light);color:var(--text-tertiary);font-size:12px;line-height:1;white-space:nowrap;cursor:pointer;user-select:none;-webkit-user-select:none;transition:color .2s,border-color .2s,box-shadow .2s;flex-shrink:0;box-sizing:border-box}._projectTab_l0ba4_693:hover{color:var(--text-secondary);border-color:var(--text-disabled)}._projectTabActive_l0ba4_734,._projectTabActive_l0ba4_734:hover{color:var(--color-primary);font-weight:600;background:var(--color-primary-bg-light);border-color:var(--color-primary);box-shadow:inset 0 0 0 1px var(--color-primary)}._projectTabDot_l0ba4_743{width:8px;height:8px;border-radius:50%;background:var(--color-primary);flex-shrink:0}._projectTabRing_l0ba4_753,._projectTabRingActive_l0ba4_754{width:8px;height:8px;border-radius:50%;border:1.6px solid var(--text-muted);border-top-color:transparent;flex-shrink:0;box-sizing:border-box}._projectTabRingActive_l0ba4_754{border-color:var(--color-primary);border-top-color:transparent}._projectTabRingSpin_l0ba4_767{animation:_ccvProjectTabRingSpin_l0ba4_1 .7s linear infinite}._projectTabsStripSpinner_l0ba4_771{align-self:center;margin-right:2px}@keyframes _ccvProjectTabRingSpin_l0ba4_1{to{transform:rotate(360deg)}}._projectTabName_l0ba4_778{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;flex:1;min-width:0}._projectTabIdx_l0ba4_787{flex-shrink:0;white-space:nowrap}._projectTabClose_l0ba4_791{width:16px;height:16px;padding:0;border:none;border-radius:3px;background:none;color:inherit;font-size:12px;line-height:1;cursor:pointer;display:inline-flex;align-items:center;justify-content:center;opacity:0;transition:opacity .15s,background .15s,color .15s;flex-shrink:0}._projectTabActive_l0ba4_734 ._projectTabClose_l0ba4_791,._projectTab_l0ba4_693:hover ._projectTabClose_l0ba4_791,._projectTab_l0ba4_693:focus-within ._projectTabClose_l0ba4_791{opacity:1}._projectTabClose_l0ba4_791:hover{background:var(--border-light);color:var(--text-primary)}._pinnedShortcut_l0ba4_823{height:24px;margin-top:11px;display:inline-flex;align-items:center;justify-content:center;font-size:16px;line-height:1;color:var(--text-tertiary);opacity:.75;cursor:pointer;transition:opacity .2s,color .2s}._pinnedShortcut_l0ba4_823:hover{opacity:1;color:var(--text-secondary)}._pinnedShortcut_l0ba4_823 .anticon{display:inline-flex;align-items:center;justify-content:center;line-height:0}._themeToggle_l0ba4_852{box-sizing:border-box;display:inline-flex;align-items:center;justify-content:center;vertical-align:middle;width:30px;height:30px;padding:0;border:none;border-radius:6px;background:transparent;color:var(--text-secondary);cursor:pointer;transition:background-color .2s ease,color .2s ease;flex-shrink:0;outline:none}._themeToggle_l0ba4_852:hover{background:var(--color-bg-hover, rgba(127, 127, 127, .12));color:var(--text-primary)}._themeToggle_l0ba4_852:focus-visible{box-shadow:0 0 0 2px var(--primary-color, #1677ff)}._themeToggleIcon_l0ba4_878{display:block}._headerRightRow_l0ba4_883 .ant-space-item{display:inline-flex;align-items:center}._headerCountdownTag_l0ba4_889{height:30px;margin:0;padding:0 10px;display:inline-flex;align-items:center;background:var(--bg-surface);border:1px solid var(--border-hover);border-radius:6px;line-height:1}._centerEmpty_1ivpu_1{display:flex;align-items:center;justify-content:center;height:100%}._scrollContainer_1ivpu_8{overflow:auto;height:100%;-webkit-overflow-scrolling:touch;will-change:scroll-position}._listItem_1ivpu_15{cursor:pointer;padding:8px 12px;border-left:6px solid transparent;border-right:1px solid var(--border-primary);border-top:1px solid transparent;border-bottom:1px solid var(--border-primary);transition:background .15s}._listItem_1ivpu_15:hover{border-left-color:var(--border-hover)}._listItemActive_1ivpu_29{background:var(--color-primary-bg-faint);border-left-color:var(--color-primary-light);border-right:1px solid var(--color-primary-light);border-top:1px solid var(--color-primary-light);border-bottom:1px solid var(--color-primary-light)}._listItemActive_1ivpu_29,._listItemActive_1ivpu_29:hover{background:var(--color-primary-bg-faint);border-left-color:var(--color-primary-light);border-right-color:var(--color-primary-light);border-top-color:var(--color-primary-light);border-bottom-color:var(--color-primary-light)}._itemContent_1ivpu_46{width:100%;min-width:0}._itemHeader_1ivpu_51{display:flex;align-items:center;gap:6px;margin-bottom:4px;font-size:12px}._tagNoMargin_1ivpu_59{margin:0;font-size:12px}._modelName_1ivpu_64{font-size:12px;color:var(--text-tertiary)}._modelNameMain_1ivpu_69{color:var(--color-code-orange)}._time_1ivpu_73{font-size:12px;color:var(--text-gray);margin-left:auto}._detailRow_1ivpu_79{display:flex;gap:8px;font-size:12px;align-items:center}._urlText_1ivpu_86{color:var(--text-disabled);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;flex:1;min-width:0}._duration_1ivpu_95{color:var(--text-gray);flex-shrink:0}._statusOk_1ivpu_100{color:var(--color-success);opacity:.5;flex-shrink:0}._statusErr_1ivpu_106{color:var(--color-error);flex-shrink:0}._statusDefault_1ivpu_111{color:var(--text-tertiary);flex-shrink:0}._usageBox_1ivpu_116{background:var(--bg-container);border-radius:4px;padding:3px 6px;margin-top:4px;font-size:12px;color:var(--text-gray);line-height:1.6}._cacheDot_1ivpu_126{display:inline-block;width:6px;height:6px;border-radius:50%;margin:0 3px;vertical-align:middle}._cacheDotLoss_1ivpu_135{background-color:var(--color-red-dark-bg);cursor:help}._cacheDotNormal_1ivpu_140{background-color:var(--border-hover)}._cacheDotTools_1ivpu_145{background-color:var(--color-code-purple);box-shadow:0 0 0 1.5px var(--color-purple-border)}._tagMainAgent_1ivpu_150{color:var(--color-code-orange);border-color:var(--color-code-orange-border);background:var(--color-code-orange-bg)}._tagPlan_1ivpu_156{color:var(--color-error-muted);border-color:var(--color-error-muted);background-color:var(--bg-base-pure)}._tagMuted_1ivpu_162{color:var(--text-muted);border-color:var(--border-light);background-color:var(--bg-base-pure)}._tooltipPreLine_1ivpu_168{white-space:pre-line}._GzYRV{line-height:1.2;white-space:pre-wrap;white-space:-moz-pre-wrap;white-space:-pre-wrap;white-space:-o-pre-wrap;word-wrap:break-word}._3eOF8{margin-right:5px;font-weight:700}._3eOF8+._3eOF8{margin-left:-5px}._1MFti{cursor:pointer}._f10Tu{font-size:1.2em;margin-right:5px;-webkit-user-select:none;-moz-user-select:none;user-select:none}._1UmXx:after{content:"▸"}._1LId0:after{content:"▾"}._1pNG9{margin-right:5px}._1pNG9:after{content:"...";font-size:.8em}._2IvMF{background:#eee}._2bkNM{margin:0;padding:0 10px}._1BXBN{margin:0;padding:0}._1MGIk{font-weight:600;margin-right:5px;color:#000}._3uHL6{color:#000}._2T6PJ,._1Gho6{color:#df113a}._vGjyY{color:#2a3f3c}._1bQdo{color:#0b75f5}._3zQKs{color:#469038}._1xvuR{color:#43413d}._oLqym,._2AXVT,._2KJWg{color:#000}._11RoI{background:#002b36}._17H2C,._3QHg2,._3fDAz{color:#fdf6e3}._2bSDX{font-weight:bolder;margin-right:5px;color:#fdf6e3}._gsbQL{color:#fdf6e3}._LaAZe,._GTKgm{color:#81b5ac}._Chy1W{color:#cb4b16}._2bveF{color:#d33682}._2vRm-{color:#ae81ff}._1prJR{color:#268bd2}._container_b5r6a_1{background:var(--bg-container);border-radius:6px;border:1px solid var(--border-primary);padding:12px;font-size:13px;font-family:var(--font-mono);overflow:auto}._root_5oh1m_1{display:flex;height:100%;min-height:0;gap:0}._sidebar_5oh1m_9{width:220px;flex-shrink:0;border-right:1px solid var(--border-primary);overflow-y:auto;padding:4px 0;-webkit-overflow-scrolling:touch}._section_5oh1m_18{-webkit-user-select:none;user-select:none}._sectionHeader_5oh1m_22{display:flex;align-items:center;gap:6px;width:100%;padding:6px 10px;cursor:pointer;color:var(--text-primary);font-size:12px;font-weight:600;transition:background .15s;background:none;border:0;text-align:left;font:inherit}._sectionHeader_5oh1m_22:hover{background:var(--overlay-light-faint)}._sectionHeader_5oh1m_22:focus-visible{outline:1px solid var(--color-primary-outline);outline-offset:-1px}._arrow_5oh1m_48{font-size:10px;color:var(--text-tertiary);flex-shrink:0}._sectionTitle_5oh1m_54{flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}._sectionCount_5oh1m_62{font-size:11px;color:var(--text-muted);background:var(--bg-elevated);border-radius:10px;padding:0 6px;line-height:18px}._sectionBody_5oh1m_71{padding:2px 0}._historyToggle_5oh1m_76{display:flex;align-items:center;gap:6px;width:100%;padding:4px 10px 4px 14px;cursor:pointer;color:var(--text-muted);font-size:11px;transition:color .15s,background .15s;background:none;border:0;text-align:left;font:inherit}._historyToggle_5oh1m_76:hover{color:var(--text-tertiary);background:var(--overlay-light-faint)}._historyToggle_5oh1m_76:focus-visible{outline:1px solid var(--color-primary-outline);outline-offset:-1px}._historyToggleLabel_5oh1m_102{flex:1}._item_5oh1m_107{display:flex;align-items:center;justify-content:space-between;width:100%;padding:4px 9px 4px 23px;font-size:12px;color:var(--text-tertiary);cursor:pointer;transition:background .15s,color .15s;background:none;border:1px solid transparent;border-radius:4px;box-sizing:border-box;text-align:left;font:inherit}._item_5oh1m_107:hover{background:var(--overlay-light-faint);color:var(--text-primary)}._item_5oh1m_107:focus-visible{outline:1px solid var(--color-primary-outline);outline-offset:-1px}._itemActive_5oh1m_135,._itemActive_5oh1m_135:hover{background:var(--color-primary-bg-faint);color:var(--color-primary);border-color:var(--color-primary-light)}._itemContent_5oh1m_142{flex:1;min-width:0;overflow:hidden}._itemLabel_5oh1m_148{font-family:var(--font-mono);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;display:block}._itemSublabel_5oh1m_156{font-size:10px;color:var(--text-disabled);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;margin-top:1px}._itemTime_5oh1m_165{font-size:9px;color:var(--text-disabled);flex-shrink:0;margin-left:4px;font-family:var(--font-mono)}._contentWrap_5oh1m_176{flex:1;min-width:0;display:flex;flex-direction:column}._content_5oh1m_174{flex:1;min-width:0;min-height:0;overflow:auto;padding:12px 16px;-webkit-overflow-scrolling:touch}._contentEmpty_5oh1m_192{height:100%;display:flex;align-items:center;justify-content:center}._contentInner_5oh1m_199{padding-bottom:20px}._emptyWrap_5oh1m_203{display:flex;align-items:center;justify-content:center;height:200px}._roleHeader_5oh1m_211{display:flex;align-items:center;gap:8px;margin-bottom:8px;flex-wrap:nowrap}._roleBadge_5oh1m_219{font-size:10px;font-weight:600;letter-spacing:.04em;padding:2px 7px;border-radius:4px;flex-shrink:0}._role_user_5oh1m_228{background:var(--color-primary-bg-lighter);color:var(--color-primary-lighter);border:1px solid var(--color-primary-bg-medium)}._role_assistant_5oh1m_234{background:var(--color-purple-bg);color:var(--color-code-purple);border:1px solid var(--color-purple-border)}._role_system_5oh1m_240{background:var(--color-warning-bg-faint);color:var(--color-warning);border:1px solid var(--color-warning-border-light)}._roleLabel_5oh1m_246{font-size:11px;color:var(--text-muted);flex:1;min-width:0}._contentTime_5oh1m_253{margin-left:auto;font-size:10px;color:var(--text-disabled);font-family:var(--font-mono);flex-shrink:0}._stepDivider_5oh1m_261{border:none;border-top:1px solid var(--border-primary);margin:14px 0}._textBlock_5oh1m_268{margin-bottom:8px;border:1px solid var(--border-primary);border-radius:6px;overflow:hidden}._textBlockBar_5oh1m_275{display:flex;align-items:center;gap:6px;padding:4px 10px;background:var(--bg-container);border-bottom:1px solid var(--border-primary)}._textBlockBody_5oh1m_284{padding:10px 12px;font-size:13px;line-height:1.7;color:var(--text-primary);word-break:break-word}._textBlockCompact_5oh1m_292{position:relative;padding:8px 10px;font-size:12px;color:var(--text-light)}._textBlockCompactFloat_5oh1m_299{float:right;margin-left:6px;margin-bottom:2px}._thinkingBlock_5oh1m_306{margin-bottom:8px;border:1px solid var(--color-thinking-border);border-radius:6px;overflow:hidden;background:var(--color-thinking-bg)}._thinkingHeader_5oh1m_314{display:flex;align-items:center;gap:6px;padding:5px 10px;cursor:pointer;font-size:12px;color:var(--text-tertiary);transition:background .15s}._thinkingHeader_5oh1m_314:hover{background:var(--overlay-light-faint)}._thinkingPreview_5oh1m_329{flex:1;min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;color:var(--text-muted);font-size:11px}._thinkingBody_5oh1m_339{padding:8px 12px;border-top:1px solid var(--color-thinking-border)}._toolBlock_5oh1m_345{margin-bottom:8px;border:1px solid var(--border-primary);border-radius:6px;overflow:hidden}._toolBlockResult_5oh1m_352{border-color:var(--color-green-border)}._toolBlockError_5oh1m_356{border-color:var(--color-red-dark-border)}._toolBlockHeader_5oh1m_360{display:flex;align-items:center;gap:8px;padding:5px 10px;background:var(--bg-container);border-bottom:1px solid var(--border-primary);font-size:12px;flex-wrap:wrap}._toolBlockBody_5oh1m_371{padding:8px 10px;font-size:12px}._toolName_5oh1m_376{color:var(--text-primary);font-weight:500;font-family:var(--font-mono)}._toolId_5oh1m_382{color:var(--text-disabled);font-size:10px;font-family:var(--font-mono);margin-left:auto}._errorLabel_5oh1m_389{font-size:10px;color:var(--color-error-light);background:var(--color-error-bg-light);border:1px solid var(--color-error-border);border-radius:3px;padding:1px 5px}._blockTag_5oh1m_399{font-size:9px;font-weight:600;letter-spacing:.05em;text-transform:uppercase;padding:1px 5px;border-radius:3px;background:var(--bg-elevated);color:var(--text-muted);border:1px solid var(--border-primary);flex-shrink:0}._blockTagText_5oh1m_412{background:var(--color-primary-bg-faint);color:var(--color-primary-lighter);border-color:var(--color-primary-bg-lighter)}._blockTagThinking_5oh1m_418{background:var(--color-warning-bg-faint);color:var(--color-warning);border-color:var(--color-warning-border-light)}._blockTagResult_5oh1m_424{background:var(--color-green-dark-bg);color:var(--color-success);border-color:var(--color-green-dark-border)}._blockTagError_5oh1m_430{background:var(--color-error-bg-faint);color:var(--color-error-light);border-color:var(--color-error-border-light)}._jsonBlock_5oh1m_437{margin-bottom:8px;border:1px solid var(--border-primary);border-radius:6px;overflow:hidden}._jsonBlockLabel_5oh1m_444{font-size:10px;color:var(--text-muted);padding:3px 10px;background:var(--bg-container);border-bottom:1px solid var(--border-primary);font-family:var(--font-mono)}._blockSeparator_5oh1m_454{border:none;border-top:1px solid var(--border-primary);margin:16px 0}._markdownBody_5oh1m_461{font-size:13px;line-height:1.7;color:var(--text-primary);word-break:break-word}._contentToolbar_5oh1m_469{display:flex;justify-content:flex-end;align-items:center;gap:8px;padding:8px 16px 0;flex-shrink:0}._contentToolbarLabel_5oh1m_478{font-size:11px;color:var(--text-muted)}._rawPre_5oh1m_484{background:var(--bg-code-dark);border:1px solid var(--border-primary);border-radius:6px;padding:12px;font-size:12px;color:var(--text-primary);white-space:pre-wrap;word-break:break-all;margin:0}._toolAdded_5oh1m_497{color:var(--color-success)}._toolRemoved_5oh1m_501{color:var(--color-error);text-decoration:line-through}._toolDiffTag_5oh1m_506{margin-left:6px;font-size:9px;font-family:var(--font-ui);text-decoration:none;opacity:.85}._toolDiffSummary_5oh1m_514{margin-left:6px;font-size:11px;font-family:var(--font-mono);display:inline-flex;gap:4px;flex-shrink:0}._toolDiffSummaryAdd_5oh1m_523{color:var(--color-success)}._toolDiffSummaryRemove_5oh1m_527{color:var(--color-error)}._root_1w105_3{box-sizing:border-box;height:100%;min-height:0;overflow-y:auto;-webkit-overflow-scrolling:touch;display:flex;flex-direction:column;gap:12px;padding:4px 0}._root_1w105_3>*{flex-shrink:0}._center_1w105_19{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:8px;padding:32px 0}._headerRow_1w105_28{display:flex;align-items:center;flex-wrap:wrap;gap:8px}._headerRow_1w105_28>:first-child,._headerRow_1w105_28>._modelTag_1w105_36,._updatedAt_1w105_37{min-width:0;overflow-wrap:anywhere}._modelTag_1w105_36{margin-inline-start:0}._headerSpacer_1w105_46{flex:1}._updatedAt_1w105_37{font-size:12px}._gridSection_1w105_54{display:flex;flex-direction:column;gap:4px}._gridLabel_1w105_60{font-size:12px}._grid_1w105_54{display:flex;flex-direction:column;gap:2px;max-width:100%;overflow-x:auto}._gridRow_1w105_72{display:flex;gap:2px;width:max-content}._gridCell_1w105_78{flex:0 0 10px;box-sizing:border-box;width:10px;height:10px;border-radius:2px;border:1px solid transparent;display:inline-block}._gridCellFull_1w105_88{background:var(--cell-color);border-color:var(--cell-color)}._gridCellPartial_1w105_93{background:var(--cell-color);background:color-mix(in srgb,var(--cell-color) 45%,transparent);border-color:var(--cell-color)}._gridCellEmpty_1w105_99{background:transparent;border-color:var(--context-category-free-space)}._gridCellBuffer_1w105_104{background:var(--context-category-buffer);border-color:var(--context-category-buffer)}._truncatedNote_1w105_109{font-size:12px}._sections_1w105_113{border-top:1px solid var(--border-secondary, rgba(0, 0, 0, .06))}._sectionBody_1w105_117{display:flex;flex-direction:column;gap:4px}._sectionSummary_1w105_123{display:flex;flex-wrap:wrap;gap:10px;font-size:12px;color:var(--text-secondary)}._sectionRow_1w105_131{display:flex;justify-content:space-between;font-size:12px;font-variant-numeric:tabular-nums}._sectionRowName_1w105_138{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;margin-right:12px}._sectionRowTokens_1w105_145{flex-shrink:0;color:var(--text-secondary)}._footer_1w105_150{display:flex;flex-wrap:wrap;align-items:baseline;gap:10px;font-size:12px;border-top:1px solid var(--border-secondary, rgba(0, 0, 0, .06));padding-top:8px}._apiUsageLabel_1w105_160{margin-right:4px}._summaryItem_1w105_164{font-variant-numeric:tabular-nums}._root_3h69u_3{display:flex;flex-direction:column;gap:12px;padding:4px 0}._center_3h69u_10{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:8px;padding:32px 0}._headerRow_3h69u_19{display:flex;align-items:center;gap:8px}._headerSpacer_3h69u_25{flex:1}._updatedAt_3h69u_29{font-size:12px}._list_3h69u_33{display:flex;flex-direction:column;gap:2px}._listRow_3h69u_39{display:flex;align-items:center;gap:8px;padding:6px 0;border-bottom:1px solid var(--border-secondary, rgba(0, 0, 0, .06))}._serverName_3h69u_47{overflow:hidden;text-overflow:ellipsis;white-space:nowrap;font-weight:500}._version_3h69u_54{font-size:12px;flex-shrink:0}._toolCount_3h69u_59{font-size:12px;flex-shrink:0;font-variant-numeric:tabular-nums}._statusTag_3h69u_65{margin-inline-end:0;flex-shrink:0}._errorBlock_3h69u_70{display:flex;flex-direction:column;gap:4px;margin-top:8px;padding-top:8px;border-top:1px solid var(--border-secondary, rgba(0, 0, 0, .06))}._errorRow_3h69u_79{display:flex;align-items:baseline;gap:6px;font-size:12px}._errorLabel_3h69u_86{flex-shrink:0}._errorText_3h69u_90{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}._container_1958y_1{height:100%;overflow:hidden;padding:0 16px;display:flex;flex-direction:column;background:var(--bg-base)}._emptyState_1958y_10{display:flex;align-items:center;justify-content:center;height:100%}._urlSection_1958y_17{padding:12px 0;border-bottom:1px solid var(--border-primary);display:flex;align-items:flex-start;flex-shrink:0}._urlLeft_1958y_25{flex:1;min-width:0}._tokenStatsBox_1958y_30{flex-shrink:0;padding-left:12px;display:flex;align-items:center}._tokenGrid_1958y_37{display:flex;border:1px solid var(--border-secondary);border-radius:6px;overflow:hidden;min-width:360px;font-size:11px;line-height:1.6}._tokenRows_1958y_47{flex:1}._tokenRow_1958y_47{display:flex}._tokenRowBorder_1958y_55{border-top:1px solid var(--border-secondary)}._tokenLabel_1958y_59{color:var(--text-tertiary);padding:4px 8px;white-space:nowrap;font-weight:600}._tokenTd_1958y_66{flex:1;color:var(--text-primary);text-align:right;padding:4px 8px;font-family:var(--font-mono);white-space:nowrap}._tokenHitRate_1958y_75{display:flex;flex-direction:column;align-items:center;justify-content:center;color:var(--text-primary);padding:4px 8px;font-family:var(--font-mono);white-space:nowrap;border-left:1px solid var(--border-secondary);min-width:100px}._tokenHitRateLabel_1958y_88{color:var(--text-tertiary);font-size:10px;font-family:var(--font-ui)}._tokenRowBorder_1958y_55 td{border-top:1px solid var(--border-secondary)}._urlText_1958y_98{color:var(--text-primary);font-size:13px;margin-bottom:8px;word-break:break-all}._metaText_1958y_105,._headersContainer_1958y_109{font-size:12px}._headerRow_1958y_113{display:flex;padding:4px 0;border-bottom:1px solid var(--border-primary)}._headerKey_1958y_119{min-width:200px;flex-shrink:0}._headerValue_1958y_124{word-break:break-all;margin-left:8px}._streamingBox_1958y_129{padding:20px;background:var(--bg-elevated);border-radius:6px;border:1px solid var(--border-primary)}._bodyToolbar_1958y_136{display:flex;gap:8px;margin-bottom:8px}._rawTextPre_1958y_142{background:var(--bg-code-dark);border:1px solid var(--border-primary);border-radius:6px;padding:12px;font-size:12px;color:var(--text-primary);overflow:auto;max-height:600px;white-space:pre-wrap;word-break:break-all}._tabContent_1958y_155{padding:16px 0 0;height:100%;overflow-y:auto;-webkit-overflow-scrolling:touch}._collapseSpacing_1958y_163{margin-bottom:16px}._bodyLabel_1958y_167{margin:0}._bodyHeader_1958y_171{display:flex;align-items:center;justify-content:space-between;margin-bottom:8px}._diffSection_1958y_178{margin-bottom:16px}._diffToggle_1958y_182{display:inline-block;margin-bottom:8px;cursor:pointer}._diffIcon_1958y_188{font-size:12px;margin-left:4px}._viewInChatBtn_1958y_193{display:inline-flex;align-items:center;height:26px;border-radius:13px;border:1px solid var(--border-light);background:#0000;color:var(--text-tertiary);cursor:pointer;font-size:12px;transition:all .2s;padding:0 10px;white-space:nowrap}._viewInChatBtn_1958y_193:hover{border-color:var(--text-muted);color:var(--text-primary);background:var(--overlay-light-faint)}._reminderSelect_1958y_214{min-width:140px;font-size:12px}._reminderSelect_1958y_214 .ant-select-selector.ant-select-selector{border-radius:2px;border-color:var(--border-light);background:#0000;min-height:26px;height:auto;padding:0 8px;font-family:var(--font-mono)}._reminderSelect_1958y_214 .ant-select-selection-placeholder{font-size:11px}._diffHeaderRow_1958y_233{display:flex;align-items:center;gap:8px}._diffSpaceRight_1958y_239{margin-left:auto}._reminderFilterWrapper_1958y_243{display:inline-flex;align-items:center;gap:4px}._reminderLabel_1958y_249{color:var(--text-tertiary);font-size:12px;font-family:var(--font-mono)}._cacheTabContent_1958y_255{padding-top:0;overflow:hidden}._userPromptList_1958y_260{width:600px;max-height:300px;overflow-y:auto}._userPromptItem_1958y_266{padding:4px 8px;font-size:12px;color:var(--text-secondary);cursor:pointer;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;border-radius:3px}._userPromptNavBtn_1958y_277{margin-left:auto;font-size:11px;color:var(--color-primary);cursor:pointer;border:1px solid var(--color-primary);border-radius:3px;padding:1px 6px;white-space:nowrap}._cacheContent_1958y_288{padding:8px 0;height:100%;display:flex;flex-direction:column}._cacheTokenBar_1958y_295{display:flex;align-items:center;font-size:12px;font-family:var(--font-mono);color:var(--text-light);margin-bottom:12px;flex-shrink:0}._cacheTokenWrite_1958y_305{color:var(--color-code-orange)}._cacheTokenRead_1958y_309{color:var(--color-success)}._cacheCopyIcon_1958y_313{margin-left:8px;cursor:pointer;color:var(--text-tertiary);transition:color .2s}._cacheScrollArea_1958y_320{flex:1;overflow-y:auto;min-height:0}._cacheSectionBlock_1958y_326{margin-bottom:12px}._cacheSectionHeader_1958y_330{font-size:13px;font-weight:600;color:var(--text-primary);margin-bottom:6px;cursor:pointer;-webkit-user-select:none;user-select:none;display:flex;align-items:center;gap:4px}._cacheCollapseArrow_1958y_342{display:inline-block;transition:transform .2s;font-size:10px}._cachePre_1958y_348{white-space:pre-wrap;word-break:break-word;font-size:12px;line-height:1.5;color:var(--text-secondary);background:var(--bg-container);border:1px solid var(--border-primary);border-radius:4px;padding:8px;margin:4px 0;font-family:var(--font-mono)}._cacheHighlightSvg_1958y_362{position:absolute;top:0;right:0;bottom:0;left:0;width:100%;height:100%;pointer-events:none;overflow:visible}._cachePreSystem_1958y_371{white-space:pre-wrap;word-break:break-word;font-size:12px;line-height:1.5;color:var(--text-secondary);background:var(--bg-code-system);border:1px solid var(--border-code-system);border-radius:4px;padding:8px;margin:4px 0;font-family:var(--font-mono)}._container_1958y_1 .ant-tabs>.ant-tabs-nav{margin-bottom:0}._container_1958y_1 .ant-tabs{flex:1;min-height:0;display:flex;flex-direction:column}._container_1958y_1 .ant-tabs>.ant-tabs-content-holder{flex:1;min-height:0}._container_1958y_1 .ant-tabs-content,._container_1958y_1 .ant-tabs-tabpane-active{height:100%}._resizer_pzn4b_1{width:6px;cursor:col-resize;background:var(--bg-elevated);flex-shrink:0;transition:background .2s}._resizer_pzn4b_1:hover{background:var(--color-primary-light)}._flag_1q4ri_3{display:inline-flex;align-items:center;justify-content:center;font-size:13px;line-height:1;cursor:help;-webkit-user-select:none;user-select:none;height:14px;background:none;border:none;padding:0;color:inherit;font-family:inherit}._flag_1q4ri_3:focus-visible{outline:2px solid var(--primary-color, #1677ff);outline-offset:2px;border-radius:2px}._popover_1q4ri_27{color:var(--text-secondary);font-size:13px;line-height:22px}._meta_1q4ri_33{color:var(--text-tertiary);font-size:12px}._usagePill_4carx_4{position:relative;display:inline-flex;align-items:center;justify-content:flex-start;border-radius:999px;border:1px solid;border-color:var(--text-disabled);color:var(--text-disabled);padding:0 7px;height:15px;font-size:11px;line-height:1;overflow:hidden;white-space:nowrap;cursor:default;background:var(--bg-base-pure)}._usageFill_4carx_12{position:absolute;left:0;top:0;bottom:0;width:var(--usage-percent, 0);background-color:#999;opacity:.2;transition:width .5s ease;pointer-events:none}._usageContent_4carx_38{position:relative;z-index:1;display:inline-flex;align-items:center}._usageText_4carx_45{font-variant-numeric:tabular-nums}._pop_4carx_50{min-width:220px;font-size:12px;color:var(--text-primary)}._popTitle_4carx_56{font-weight:600;margin-bottom:6px}._popTable_4carx_62{border-collapse:collapse}._popTable_4carx_62 td{padding-top:3px;padding-bottom:3px;vertical-align:middle}._tdName_4carx_67{color:var(--text-secondary);padding-right:5px;white-space:nowrap}._tdBar_4carx_67{padding-right:5px;white-space:nowrap}._tdReset_4carx_85{color:var(--text-secondary);font-variant-numeric:tabular-nums;white-space:nowrap}._bar_4carx_94{position:relative;display:inline-flex;align-items:center;justify-content:center;width:100px;height:14px;border-radius:999px;border:1px solid var(--text-disabled);overflow:hidden;background:var(--bg-base-pure);vertical-align:middle}._barFill_4carx_108{position:absolute;left:0;top:0;bottom:0;background-color:var(--text-secondary);opacity:.15;pointer-events:none}._barText_4carx_118{position:relative;z-index:1;font-size:11px;line-height:1;font-variant-numeric:tabular-nums;color:var(--text-primary)}._content_31jwg_1{line-height:1.8}._muted_31jwg_2{color:var(--text-tertiary);font-size:13px}._actions_31jwg_3{display:flex;flex-wrap:wrap;justify-content:flex-end;gap:8px;margin-top:16px}._overlay_obmwg_7{position:fixed;top:0;right:0;bottom:0;left:0;overflow:auto;background:var(--overlay-dark-strong);-webkit-backdrop-filter:blur(2px);backdrop-filter:blur(2px);z-index:2100;display:flex;align-items:center;justify-content:center;padding:32px 16px}._card_obmwg_21{max-width:420px;display:flex;flex-direction:column;align-items:center;gap:16px;padding:32px;border-radius:12px;background:var(--bg-code);border:1px solid var(--border-primary);text-align:center}._title_obmwg_34{color:var(--text-primary);font-size:16px;font-weight:600}._hint_obmwg_35{color:var(--text-tertiary);font-size:13px;line-height:1.8}
|