@wrongstack/webui 1.0.17 → 1.0.19
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/assets/{AgentRosterView-CV9MW-4M.js → AgentRosterView-D4TuVXe8.js} +1 -1
- package/dist/assets/{AnalyticsDashboard-30brLbuz.js → AnalyticsDashboard-DmQd0E0V.js} +1 -1
- package/dist/assets/{AudienceMemoryPanel-bKVydKg8.js → AudienceMemoryPanel-DHJM4rf1.js} +1 -1
- package/dist/assets/{ChangesView-Cv6svx-V.js → ChangesView-CZ-nCe26.js} +1 -1
- package/dist/assets/{ChimeraReviewsView-DLTrEJDS.js → ChimeraReviewsView-CNeRLesP.js} +1 -1
- package/dist/assets/{ChronicleDashboard-DhgWbaXj.js → ChronicleDashboard-CYELq7EO.js} +1 -1
- package/dist/assets/{CodeEditor-JlvMbECd.js → CodeEditor-CLscjkIR.js} +1 -1
- package/dist/assets/{CodeMap-4swT3FIw.js → CodeMap-CdVy9Q7V.js} +1 -1
- package/dist/assets/{CronJobsPanel-LSpFBceD.js → CronJobsPanel-TcZy_W2t.js} +1 -1
- package/dist/assets/{DeadCodeScanPanel-ZRNNV02b.js → DeadCodeScanPanel-BOD2JEyf.js} +1 -1
- package/dist/assets/{DebugDashboard-DlH0QNPX.js → DebugDashboard-DFPNPzQ_.js} +1 -1
- package/dist/assets/{DesignGalleryView-yZgVVEg9.js → DesignGalleryView-BXABwAji.js} +1 -1
- package/dist/assets/{GoalView-D1gxZre2.js → GoalView-Cepqrg9l.js} +1 -1
- package/dist/assets/KanbanView-FSePkLch.js +3 -0
- package/dist/assets/{MailboxDetailView-C4lEW3f8.js → MailboxDetailView-QyNmt1Gv.js} +1 -1
- package/dist/assets/{MemoryDrawer-arujfDSW.js → MemoryDrawer-BZsyD1dh.js} +1 -1
- package/dist/assets/{MemoryManager-BmQYIRhD.js → MemoryManager-IHmhWn4P.js} +1 -1
- package/dist/assets/{ProcessMonitor-ByW-VKsX.js → ProcessMonitor-Bz0jZvHJ.js} +1 -1
- package/dist/assets/{PromptJournalView-0cHPeYXa.js → PromptJournalView-Ct8cLcGU.js} +1 -1
- package/dist/assets/{ProviderTestView-CQlwC6HG.js → ProviderTestView-Dy3k2bVu.js} +1 -1
- package/dist/assets/{QueuePanel-DJeK7xCh.js → QueuePanel-oVkTB68Q.js} +1 -1
- package/dist/assets/{RefreshDebugView-BfOjHodq.js → RefreshDebugView-_XPrBDq3.js} +1 -1
- package/dist/assets/{RepositoryHistoryView-BYPPu5uv.js → RepositoryHistoryView-Wlnvi5r1.js} +1 -1
- package/dist/assets/RequirementIntakeView-Cj5arGFF.js +1 -0
- package/dist/assets/{SageTabs-Bt2kzPNB.js → SageTabs-qrBn3VQr.js} +2 -2
- package/dist/assets/{SddFlowGraph-CZSwcAtS.js → SddFlowGraph-DS8R2zEj.js} +1 -1
- package/dist/assets/{SddHub-Cc79Ob7A.js → SddHub-C8pHQYSM.js} +1 -1
- package/dist/assets/{SessionInspectView-BasxJ_5x.js → SessionInspectView-CuRk2DS0.js} +1 -1
- package/dist/assets/{SessionList-C9MRSj_-.js → SessionList-BgRb1Mp4.js} +1 -1
- package/dist/assets/{SessionsDashboard-BK95Zp6f.js → SessionsDashboard-CSkm28Bx.js} +1 -1
- package/dist/assets/{SetupScreen-rPKsBa9Z.js → SetupScreen-CNcJ_9O9.js} +1 -1
- package/dist/assets/{SkillDetailView-LkJyIBPb.js → SkillDetailView-Bc9owpaX.js} +1 -1
- package/dist/assets/{TechStackView-xVR5dsSn.js → TechStackView-BHiGCRBT.js} +1 -1
- package/dist/assets/{TerminalPanel-CBEZTuvV.js → TerminalPanel-7VeXK8LB.js} +1 -1
- package/dist/assets/{activity-E8vCWdG2.js → activity-1wlPY6yi.js} +1 -1
- package/dist/assets/{activity-CInOo57V.js → activity-BVbAv0x7.js} +1 -1
- package/dist/assets/{activity-e8OIpNGJ.js → activity-BmJTU8kX.js} +1 -1
- package/dist/assets/{activity-oTJsNfZu.js → activity-By_aWEsY.js} +1 -1
- package/dist/assets/{activity-DapbBEf6.js → activity-Cps_29WN.js} +1 -1
- package/dist/assets/{activity-D6XfckyA.js → activity-Du_fOnvF.js} +1 -1
- package/dist/assets/{activity-CDHIWIPJ.js → activity-p_2o4eC6.js} +1 -1
- package/dist/assets/{chat-store-BDVZSmod.js → chat-store-C-PKlsCR.js} +1 -1
- package/dist/assets/config-store-xSv1mChc.js +21 -0
- package/dist/assets/{i18n-CvJB4U4z.js → i18n--QdD6NCn.js} +1 -1
- package/dist/assets/{index-DLjaZSCH.js → index-FWwLmwjx.js} +35 -35
- package/dist/assets/{roster-ws-BRANim2Y.js → roster-ws-CxKDc-ET.js} +1 -1
- package/dist/assets/{stores-D5loyGLL.js → stores-2kakt8j9.js} +1 -1
- package/dist/components/KanbanColumnView.d.ts +13 -0
- package/dist/index.html +5 -5
- package/dist/index.js +195 -133
- package/dist/lib/kanban-cleaner.d.ts +1 -1
- package/dist/lib/ws-client-domain-methods.d.ts +1 -1
- package/dist/lib/ws-client-echo.d.ts +1 -1
- package/package.json +9 -9
- package/dist/assets/KanbanView-Bh0T3p3J.js +0 -3
- package/dist/assets/RequirementIntakeView-CEwUB7VD.js +0 -1
- package/dist/assets/config-store-mWuYCild.js +0 -22
package/dist/index.js
CHANGED
|
@@ -3441,6 +3441,9 @@ var require_activity = __commonJS({
|
|
|
3441
3441
|
createBoard: "Board erstellen",
|
|
3442
3442
|
deleteTask: "Task l\xF6schen",
|
|
3443
3443
|
runFailed: "Ausf\xFChrung fehlgeschlagen",
|
|
3444
|
+
parked: "geparkt",
|
|
3445
|
+
parkedTasks: "Die Verifizierung hat ihr Ablehnungsbudget hierf\xFCr aufgebraucht \u2014 sie l\xF6sen sich nicht von selbst",
|
|
3446
|
+
parkedReason: "Nach {{attempts}} abgelehnten Abschl\xFCssen geparkt: {{reason}} Ein unver\xE4nderter erneuter Versuch wird wieder abgelehnt.",
|
|
3444
3447
|
splitPendingApproval: "Aufteilung wartet auf Genehmigung",
|
|
3445
3448
|
newTask: "Neuer Task",
|
|
3446
3449
|
addTask: "Task hinzuf\xFCgen",
|
|
@@ -8911,6 +8914,9 @@ var require_activity2 = __commonJS({
|
|
|
8911
8914
|
createBoard: "Create board",
|
|
8912
8915
|
deleteTask: "Delete task",
|
|
8913
8916
|
runFailed: "run failed",
|
|
8917
|
+
parked: "parked",
|
|
8918
|
+
parkedTasks: "Verification spent its refusal budget on these \u2014 they will not clear on their own",
|
|
8919
|
+
parkedReason: "Parked after {{attempts}} refused completion(s): {{reason}} Retrying it unchanged will refuse again.",
|
|
8914
8920
|
splitPendingApproval: "split pending approval",
|
|
8915
8921
|
newTask: "New task",
|
|
8916
8922
|
addTask: "Add task",
|
|
@@ -13742,6 +13748,9 @@ var require_activity3 = __commonJS({
|
|
|
13742
13748
|
createBoard: "Crear tablero",
|
|
13743
13749
|
deleteTask: "Eliminar tarea",
|
|
13744
13750
|
runFailed: "ejecuci\xF3n fallida",
|
|
13751
|
+
parked: "aparcada",
|
|
13752
|
+
parkedTasks: "La verificaci\xF3n agot\xF3 su presupuesto de rechazos en estas \u2014 no se resolver\xE1n solas",
|
|
13753
|
+
parkedReason: "Aparcada tras {{attempts}} finalizaci\xF3n(es) rechazada(s): {{reason}} Reintentarla sin cambios volver\xE1 a rechazarla.",
|
|
13745
13754
|
splitPendingApproval: "divisi\xF3n pendiente de aprobaci\xF3n",
|
|
13746
13755
|
newTask: "Nueva tarea",
|
|
13747
13756
|
addTask: "Agregar tarea",
|
|
@@ -19152,6 +19161,9 @@ D\xE9clencheurs : l'utilisateur dit "mot-cl\xE9", "autre".`,
|
|
|
19152
19161
|
createBoard: "Cr\xE9er un tableau",
|
|
19153
19162
|
deleteTask: "Supprimer la t\xE2che",
|
|
19154
19163
|
runFailed: "ex\xE9cution \xE9chou\xE9e",
|
|
19164
|
+
parked: "en pause",
|
|
19165
|
+
parkedTasks: "La v\xE9rification a \xE9puis\xE9 son budget de refus sur celles-ci \u2014 elles ne se d\xE9bloqueront pas seules",
|
|
19166
|
+
parkedReason: "Mise en pause apr\xE8s {{attempts}} ach\xE8vement(s) refus\xE9(s) : {{reason}} La r\xE9essayer sans modification sera refus\xE9 \xE0 nouveau.",
|
|
19155
19167
|
splitPendingApproval: "division en attente d'approbation",
|
|
19156
19168
|
newTask: "Nouvelle t\xE2che",
|
|
19157
19169
|
addTask: "Ajouter une t\xE2che",
|
|
@@ -24562,6 +24574,9 @@ Trigger: l'utente dice "parola chiave", "altra".`,
|
|
|
24562
24574
|
createBoard: "Crea board",
|
|
24563
24575
|
deleteTask: "Elimina task",
|
|
24564
24576
|
runFailed: "esecuzione fallita",
|
|
24577
|
+
parked: "in pausa",
|
|
24578
|
+
parkedTasks: "La verifica ha esaurito il suo budget di rifiuti su queste \u2014 non si sbloccheranno da sole",
|
|
24579
|
+
parkedReason: "In pausa dopo {{attempts}} completamento/i rifiutato/i: {{reason}} Riprovarla invariata verr\xE0 rifiutata di nuovo.",
|
|
24565
24580
|
splitPendingApproval: "split in attesa di approvazione",
|
|
24566
24581
|
newTask: "Nuovo task",
|
|
24567
24582
|
addTask: "Aggiungi task",
|
|
@@ -29971,6 +29986,9 @@ var require_activity6 = __commonJS({
|
|
|
29971
29986
|
createBoard: "Criar quadro",
|
|
29972
29987
|
deleteTask: "Excluir tarefa",
|
|
29973
29988
|
runFailed: "execu\xE7\xE3o falhou",
|
|
29989
|
+
parked: "estacionada",
|
|
29990
|
+
parkedTasks: "A verifica\xE7\xE3o esgotou seu or\xE7amento de recusas nestas \u2014 elas n\xE3o se resolvem sozinhas",
|
|
29991
|
+
parkedReason: "Estacionada ap\xF3s {{attempts}} conclus\xE3o(\xF5es) recusada(s): {{reason}} Tentar de novo sem altera\xE7\xF5es ser\xE1 recusado outra vez.",
|
|
29974
29992
|
splitPendingApproval: "divis\xE3o pendente de aprova\xE7\xE3o",
|
|
29975
29993
|
newTask: "Nova tarefa",
|
|
29976
29994
|
addTask: "Adicionar tarefa",
|
|
@@ -35441,6 +35459,9 @@ var require_activity7 = __commonJS({
|
|
|
35441
35459
|
createBoard: "Pano olu\u015Ftur",
|
|
35442
35460
|
deleteTask: "G\xF6revi sil",
|
|
35443
35461
|
runFailed: "\xE7al\u0131\u015Ft\u0131rma ba\u015Far\u0131s\u0131z",
|
|
35462
|
+
parked: "park edildi",
|
|
35463
|
+
parkedTasks: "Do\u011Frulama ret b\xFCt\xE7esini bu kartlarda t\xFCketti \u2014 kendili\u011Finden temizlenmezler",
|
|
35464
|
+
parkedReason: "{{attempts}} reddedilen tamamlamadan sonra park edildi: {{reason}} De\u011Fi\u015Ftirmeden yeniden denemek yine reddedilir.",
|
|
35444
35465
|
splitPendingApproval: "b\xF6lme onay bekliyor",
|
|
35445
35466
|
newTask: "Yeni g\xF6rev",
|
|
35446
35467
|
addTask: "G\xF6rev ekle",
|
|
@@ -44056,7 +44077,10 @@ var init_ws_client_echo = __esm({
|
|
|
44056
44077
|
* matches the audit's instruction that suppression must be correlated
|
|
44057
44078
|
* end-to-end, never type-keyed.
|
|
44058
44079
|
*/
|
|
44059
|
-
|
|
44080
|
+
// `_responseType` is unused ON PURPOSE — see above: suppression is correlated
|
|
44081
|
+
// by requestId end-to-end, never keyed by message type. It stays in the
|
|
44082
|
+
// signature because every caller passes it positionally.
|
|
44083
|
+
consumeSuppressedChatEcho(_responseType, msg) {
|
|
44060
44084
|
if (!msg) return false;
|
|
44061
44085
|
const requestId = msg.payload?.requestId;
|
|
44062
44086
|
if (typeof requestId !== "string" || requestId.length === 0) return false;
|
|
@@ -46283,7 +46307,10 @@ var init_tool_stats_store = __esm({
|
|
|
46283
46307
|
};
|
|
46284
46308
|
return { sessions: { ...withSession, [sessionId]: nextSession } };
|
|
46285
46309
|
}),
|
|
46286
|
-
|
|
46310
|
+
// Starting a delegation only bumps the counter; the payload matters on
|
|
46311
|
+
// completion (see recordDelegateCompleted, which reads ok/toolCalls). The
|
|
46312
|
+
// parameter stays for signature symmetry with the rest of the recorders.
|
|
46313
|
+
recordDelegateStarted: (sessionId, _delegation) => set((state) => {
|
|
46287
46314
|
const { sessions: withSession, session } = upsertSession(state.sessions, sessionId);
|
|
46288
46315
|
const nextSession = {
|
|
46289
46316
|
...session,
|
|
@@ -76669,6 +76696,7 @@ function auditKanbanBoard(board, options) {
|
|
|
76669
76696
|
for (const task of board.tasks) {
|
|
76670
76697
|
if (TERMINAL_STATUSES2.has(task.status)) continue;
|
|
76671
76698
|
addRequiredDetailIssues(issues, task, options.requireDueDate === true, managed);
|
|
76699
|
+
addParkedIssue(issues, task);
|
|
76672
76700
|
addRunningIssue(issues, task, now);
|
|
76673
76701
|
addReviewIssue(issues, task, now, reviewStaleAfterMs);
|
|
76674
76702
|
if (lifecycleOrder.length > 1) addLifecycleIssue(issues, task, lifecycleOrder);
|
|
@@ -76738,6 +76766,17 @@ function boardByteSize(board) {
|
|
|
76738
76766
|
return 0;
|
|
76739
76767
|
}
|
|
76740
76768
|
}
|
|
76769
|
+
function addParkedIssue(issues, task) {
|
|
76770
|
+
const park = task.park;
|
|
76771
|
+
if (!park) return;
|
|
76772
|
+
pushIssue(
|
|
76773
|
+
issues,
|
|
76774
|
+
task,
|
|
76775
|
+
"parked-card",
|
|
76776
|
+
"warning",
|
|
76777
|
+
`Verification gave up after ${park.attempts} refusal${park.attempts === 1 ? "" : "s"}: ${park.reason}`
|
|
76778
|
+
);
|
|
76779
|
+
}
|
|
76741
76780
|
function addRunningIssue(issues, task, now) {
|
|
76742
76781
|
const assignment = task.assignment;
|
|
76743
76782
|
const running = task.status === "in_progress" || assignment?.status === "running";
|
|
@@ -78557,7 +78596,8 @@ function deriveTaskCardIntelligence(board, task, verificationActivity) {
|
|
|
78557
78596
|
})(),
|
|
78558
78597
|
atomicityVerdict: task.atomicityAssessment?.verdict ?? null,
|
|
78559
78598
|
evidenceCount: task.verificationReport?.attachments.length ?? 0,
|
|
78560
|
-
pendingDecomposition: task.decomposition?.status === "proposed"
|
|
78599
|
+
pendingDecomposition: task.decomposition?.status === "proposed",
|
|
78600
|
+
parked: task.park && task.status !== "completed" && task.status !== "archived" ? { reason: task.park.reason, attempts: task.park.attempts } : null
|
|
78561
78601
|
};
|
|
78562
78602
|
}
|
|
78563
78603
|
function boardIntelligenceSignature(board) {
|
|
@@ -78579,6 +78619,7 @@ function taskIntelligenceKey(task) {
|
|
|
78579
78619
|
task.atomicityAssessment?.verdict ?? "",
|
|
78580
78620
|
task.verificationReport?.attachments.length ?? 0,
|
|
78581
78621
|
task.decomposition?.status ?? "",
|
|
78622
|
+
task.park ? `${task.park.attempts}:${task.park.reason}` : "",
|
|
78582
78623
|
assignment ? JSON.stringify({
|
|
78583
78624
|
provider: assignment.provider,
|
|
78584
78625
|
model: assignment.model,
|
|
@@ -78804,6 +78845,17 @@ function KanbanColumnView({
|
|
|
78804
78845
|
intelligence.activeUsers,
|
|
78805
78846
|
" active"
|
|
78806
78847
|
] }),
|
|
78848
|
+
intelligence.parked && /* @__PURE__ */ jsx179(
|
|
78849
|
+
"span",
|
|
78850
|
+
{
|
|
78851
|
+
className: "rounded bg-destructive/10 px-1.5 py-0.5 font-medium text-destructive",
|
|
78852
|
+
title: t("activity:kanban.parkedReason", {
|
|
78853
|
+
attempts: intelligence.parked.attempts,
|
|
78854
|
+
reason: intelligence.parked.reason
|
|
78855
|
+
}),
|
|
78856
|
+
children: t("activity:kanban.parked")
|
|
78857
|
+
}
|
|
78858
|
+
),
|
|
78807
78859
|
intelligence.failed && /* @__PURE__ */ jsx179("span", { className: "rounded bg-destructive/10 px-1.5 py-0.5 text-destructive", children: t("activity:kanban.runFailed") }),
|
|
78808
78860
|
intelligence.criticalRisks > 0 && /* @__PURE__ */ jsxs169("span", { className: "rounded bg-destructive/10 px-1.5 py-0.5 text-destructive", children: [
|
|
78809
78861
|
intelligence.criticalRisks,
|
|
@@ -80307,6 +80359,18 @@ function KanbanQueueHealthBar({ queueHealth, runningCostTotal }) {
|
|
|
80307
80359
|
]
|
|
80308
80360
|
}
|
|
80309
80361
|
),
|
|
80362
|
+
(queueHealth.parked?.count ?? 0) > 0 && /* @__PURE__ */ jsxs174(
|
|
80363
|
+
"span",
|
|
80364
|
+
{
|
|
80365
|
+
title: t("activity:kanban.parkedTasks"),
|
|
80366
|
+
className: "inline-flex items-center gap-1 rounded bg-destructive/10 px-1.5 py-0.5 font-medium text-destructive",
|
|
80367
|
+
children: [
|
|
80368
|
+
queueHealth.parked?.count,
|
|
80369
|
+
" ",
|
|
80370
|
+
t("activity:kanban.parked")
|
|
80371
|
+
]
|
|
80372
|
+
}
|
|
80373
|
+
),
|
|
80310
80374
|
!hasKanbanQueueAnomalies(queueHealth) && /* @__PURE__ */ jsx184("span", { className: "text-success", children: t("activity:kanban.healthy") }),
|
|
80311
80375
|
runningCostTotal > 0 && /* @__PURE__ */ jsx184(
|
|
80312
80376
|
"span",
|
|
@@ -84571,25 +84635,21 @@ function KanbanView({ onClose }) {
|
|
|
84571
84635
|
}, [activeBoardId, fetchBoardHistory]);
|
|
84572
84636
|
useEffect93(() => {
|
|
84573
84637
|
if (!activeBoardId) return;
|
|
84574
|
-
|
|
84575
|
-
|
|
84576
|
-
ws.send({ type: "kanban.health", payload: { boardId: activeBoardId } });
|
|
84577
|
-
}, 5e3);
|
|
84578
|
-
return () => clearInterval(interval);
|
|
84579
|
-
}, [activeBoardId, ws]);
|
|
84638
|
+
ws.send({ type: "kanban.health", payload: { boardId: activeBoardId } });
|
|
84639
|
+
}, [activeBoardId, activeBoard?.updatedAt, ws]);
|
|
84580
84640
|
useEffect93(() => {
|
|
84581
84641
|
const interval = setInterval(() => {
|
|
84582
84642
|
ws.send({
|
|
84583
84643
|
type: "kanban.list",
|
|
84584
84644
|
payload: { page: boardPage, pageSize: BOARD_PAGE_SIZE, activeSessionIds }
|
|
84585
84645
|
});
|
|
84586
|
-
},
|
|
84646
|
+
}, 3e4);
|
|
84587
84647
|
return () => clearInterval(interval);
|
|
84588
84648
|
}, [activeSessionIds, boardPage, ws]);
|
|
84589
84649
|
useEffect93(() => {
|
|
84590
84650
|
const interval = setInterval(() => {
|
|
84591
84651
|
ws.send({ type: "kanban.workbench", payload: { limitPerLane: 8, alertLimit: 8 } });
|
|
84592
|
-
},
|
|
84652
|
+
}, 6e4);
|
|
84593
84653
|
return () => clearInterval(interval);
|
|
84594
84654
|
}, [ws]);
|
|
84595
84655
|
const changeBoardPage = (page) => {
|
|
@@ -84641,19 +84701,7 @@ function KanbanView({ onClose }) {
|
|
|
84641
84701
|
const title = newBoardTitle.trim();
|
|
84642
84702
|
if (!title) return;
|
|
84643
84703
|
setNewBoardTitle("");
|
|
84644
|
-
sendKanban("kanban.create", {
|
|
84645
|
-
title,
|
|
84646
|
-
lifecycle: {
|
|
84647
|
-
mode: "managed",
|
|
84648
|
-
columns: {
|
|
84649
|
-
backlog: "backlog",
|
|
84650
|
-
todo: "todo",
|
|
84651
|
-
running: "in-progress",
|
|
84652
|
-
review: "review",
|
|
84653
|
-
done: "done"
|
|
84654
|
-
}
|
|
84655
|
-
}
|
|
84656
|
-
});
|
|
84704
|
+
sendKanban("kanban.create", { title });
|
|
84657
84705
|
};
|
|
84658
84706
|
const createTask = () => {
|
|
84659
84707
|
if (!activeBoard) return;
|
|
@@ -89669,7 +89717,7 @@ __export(RequirementIntakeView_exports, {
|
|
|
89669
89717
|
RequirementIntakeView: () => RequirementIntakeView
|
|
89670
89718
|
});
|
|
89671
89719
|
import { Check as Check36, ChevronDown as ChevronDown25, ChevronRight as ChevronRight19, Copy as Copy10, Wand2 as Wand22 } from "lucide-react";
|
|
89672
|
-
import { useCallback as useCallback61, useEffect as useEffect101, useState as useState113 } from "react";
|
|
89720
|
+
import { useCallback as useCallback61, useEffect as useEffect101, useRef as useRef52, useState as useState113 } from "react";
|
|
89673
89721
|
import { jsx as jsx221, jsxs as jsxs210 } from "react/jsx-runtime";
|
|
89674
89722
|
function relativeTime4(timestamp2) {
|
|
89675
89723
|
const elapsedMs2 = Date.now() - timestamp2;
|
|
@@ -89698,10 +89746,20 @@ function RequirementIntakeView({
|
|
|
89698
89746
|
const [formNotice, setFormNotice] = useState113(null);
|
|
89699
89747
|
const [expandedId, setExpandedId] = useState113(null);
|
|
89700
89748
|
const [copiedId, setCopiedId] = useState113(null);
|
|
89749
|
+
const copiedTimerRef = useRef52(null);
|
|
89701
89750
|
const copyRequest = useCallback61((id, text5) => {
|
|
89702
89751
|
void navigator.clipboard?.writeText(text5);
|
|
89703
89752
|
setCopiedId(id);
|
|
89704
|
-
|
|
89753
|
+
if (copiedTimerRef.current !== null) clearTimeout(copiedTimerRef.current);
|
|
89754
|
+
copiedTimerRef.current = setTimeout(() => {
|
|
89755
|
+
copiedTimerRef.current = null;
|
|
89756
|
+
setCopiedId(null);
|
|
89757
|
+
}, 1500);
|
|
89758
|
+
}, []);
|
|
89759
|
+
useEffect101(() => {
|
|
89760
|
+
return () => {
|
|
89761
|
+
if (copiedTimerRef.current !== null) clearTimeout(copiedTimerRef.current);
|
|
89762
|
+
};
|
|
89705
89763
|
}, []);
|
|
89706
89764
|
const load = useCallback61(async () => {
|
|
89707
89765
|
setLoading(true);
|
|
@@ -91087,7 +91145,7 @@ import {
|
|
|
91087
91145
|
XCircle as XCircle8,
|
|
91088
91146
|
Zap as Zap21
|
|
91089
91147
|
} from "lucide-react";
|
|
91090
|
-
import { useCallback as useCallback62, useEffect as useEffect103, useMemo as useMemo72, useRef as
|
|
91148
|
+
import { useCallback as useCallback62, useEffect as useEffect103, useMemo as useMemo72, useRef as useRef53, useState as useState116 } from "react";
|
|
91091
91149
|
import { Fragment as Fragment56, jsx as jsx226, jsxs as jsxs215 } from "react/jsx-runtime";
|
|
91092
91150
|
function SddBoardView({ onClose }) {
|
|
91093
91151
|
const { t } = useTranslation();
|
|
@@ -91116,7 +91174,7 @@ function SddBoardView({ onClose }) {
|
|
|
91116
91174
|
(msg) => client2?.send?.(msg),
|
|
91117
91175
|
[client2]
|
|
91118
91176
|
);
|
|
91119
|
-
const pendingDestroy =
|
|
91177
|
+
const pendingDestroy = useRef53(null);
|
|
91120
91178
|
const fireDestroy = useCallback62(
|
|
91121
91179
|
(revertMerged) => {
|
|
91122
91180
|
pendingDestroy.current = null;
|
|
@@ -91659,7 +91717,7 @@ import {
|
|
|
91659
91717
|
X as X50,
|
|
91660
91718
|
Zap as Zap22
|
|
91661
91719
|
} from "lucide-react";
|
|
91662
|
-
import { useCallback as useCallback63, useEffect as useEffect104, useMemo as useMemo73, useRef as
|
|
91720
|
+
import { useCallback as useCallback63, useEffect as useEffect104, useMemo as useMemo73, useRef as useRef54, useState as useState117 } from "react";
|
|
91663
91721
|
import { Fragment as Fragment57, jsx as jsx227, jsxs as jsxs216 } from "react/jsx-runtime";
|
|
91664
91722
|
function SddWizard({
|
|
91665
91723
|
onClose,
|
|
@@ -91697,7 +91755,7 @@ function SddWizard({
|
|
|
91697
91755
|
(msg) => client2?.send?.(msg),
|
|
91698
91756
|
[client2]
|
|
91699
91757
|
);
|
|
91700
|
-
const bottomRef =
|
|
91758
|
+
const bottomRef = useRef54(null);
|
|
91701
91759
|
useEffect104(() => {
|
|
91702
91760
|
send({ type: "sdd.spec.get" });
|
|
91703
91761
|
}, [send]);
|
|
@@ -92950,7 +93008,7 @@ import {
|
|
|
92950
93008
|
Wrench as Wrench11,
|
|
92951
93009
|
X as X52
|
|
92952
93010
|
} from "lucide-react";
|
|
92953
|
-
import { useCallback as useCallback66, useEffect as useEffect107, useMemo as useMemo74, useRef as
|
|
93011
|
+
import { useCallback as useCallback66, useEffect as useEffect107, useMemo as useMemo74, useRef as useRef55, useState as useState119 } from "react";
|
|
92954
93012
|
import { jsx as jsx231, jsxs as jsxs220 } from "react/jsx-runtime";
|
|
92955
93013
|
function formatSessionDuration(entry) {
|
|
92956
93014
|
const start = timestamp(entry.startedAt);
|
|
@@ -93174,8 +93232,8 @@ function SessionList({
|
|
|
93174
93232
|
const [renameDraft, setRenameDraft] = useState119("");
|
|
93175
93233
|
const [resumingId, setResumingId] = useState119(null);
|
|
93176
93234
|
const [page, setPage] = useState119(1);
|
|
93177
|
-
const resumeTimer =
|
|
93178
|
-
const renameInput =
|
|
93235
|
+
const resumeTimer = useRef55(null);
|
|
93236
|
+
const renameInput = useRef55(null);
|
|
93179
93237
|
const workspace = variant === "workspace";
|
|
93180
93238
|
const displayName2 = useCallback66(
|
|
93181
93239
|
(entry) => entry.name || sessionNicknames[entry.id] || entry.title || t("activity:sessions.empty"),
|
|
@@ -94694,7 +94752,7 @@ import {
|
|
|
94694
94752
|
Trash2 as Trash224,
|
|
94695
94753
|
X as X53
|
|
94696
94754
|
} from "lucide-react";
|
|
94697
|
-
import { lazy as lazy3, Suspense as Suspense3, useCallback as useCallback69, useEffect as useEffect110, useMemo as useMemo76, useRef as
|
|
94755
|
+
import { lazy as lazy3, Suspense as Suspense3, useCallback as useCallback69, useEffect as useEffect110, useMemo as useMemo76, useRef as useRef56, useState as useState122 } from "react";
|
|
94698
94756
|
import rehypeHighlight2 from "rehype-highlight";
|
|
94699
94757
|
import { jsx as jsx234, jsxs as jsxs223 } from "react/jsx-runtime";
|
|
94700
94758
|
function isWritableSkillSource(source) {
|
|
@@ -94744,16 +94802,16 @@ function SkillDetailView({ className }) {
|
|
|
94744
94802
|
const [splitPreview, setSplitPreview] = useState122(false);
|
|
94745
94803
|
const [draftSavedAt, setDraftSavedAt] = useState122(null);
|
|
94746
94804
|
const [draftRestored, setDraftRestored] = useState122(false);
|
|
94747
|
-
const lastSavedDraftRef =
|
|
94805
|
+
const lastSavedDraftRef = useRef56("");
|
|
94748
94806
|
const [checkingForUpdates, setCheckingForUpdates] = useState122(false);
|
|
94749
94807
|
const [updateResult, setUpdateResult] = useState122(null);
|
|
94750
94808
|
const [copiedSourceUrl, setCopiedSourceUrl] = useState122(false);
|
|
94751
94809
|
const [uninstallConfirmSkill, setUninstallConfirmSkill] = useState122(null);
|
|
94752
94810
|
const [uninstalling, setUninstalling] = useState122(false);
|
|
94753
94811
|
const [skills, setSkills] = useState122([]);
|
|
94754
|
-
const skillsStateRef =
|
|
94812
|
+
const skillsStateRef = useRef56(skillsState);
|
|
94755
94813
|
skillsStateRef.current = skillsState;
|
|
94756
|
-
const isNavigatingBack =
|
|
94814
|
+
const isNavigatingBack = useRef56(false);
|
|
94757
94815
|
const editStats = useMemo76(() => {
|
|
94758
94816
|
if (!editContent) return { lines: 0, words: 0, chars: 0 };
|
|
94759
94817
|
const lines = editContent.split("\n").length;
|
|
@@ -99248,7 +99306,7 @@ import {
|
|
|
99248
99306
|
Sparkles as Sparkles23,
|
|
99249
99307
|
Shield as Shield5
|
|
99250
99308
|
} from "lucide-react";
|
|
99251
|
-
import { useCallback as useCallback73, useEffect as useEffect114, useRef as
|
|
99309
|
+
import { useCallback as useCallback73, useEffect as useEffect114, useRef as useRef57, useState as useState128 } from "react";
|
|
99252
99310
|
import { useShallow as useShallow13 } from "zustand/react/shallow";
|
|
99253
99311
|
import { Fragment as Fragment62, jsx as jsx245, jsxs as jsxs234 } from "react/jsx-runtime";
|
|
99254
99312
|
function SetupScreen() {
|
|
@@ -99276,7 +99334,7 @@ function SetupScreen() {
|
|
|
99276
99334
|
const [popularRefreshNonce, setPopularRefreshNonce] = useState128(0);
|
|
99277
99335
|
const [previousProviderCount, setPreviousProviderCount] = useState128(0);
|
|
99278
99336
|
const [lastUpdatedAt, setLastUpdatedAt] = useState128(null);
|
|
99279
|
-
const isInitialLoadRef =
|
|
99337
|
+
const isInitialLoadRef = useRef57(true);
|
|
99280
99338
|
useEffect114(() => {
|
|
99281
99339
|
const controller = new AbortController();
|
|
99282
99340
|
const localUrl = `${window.location.origin}/providers.json`;
|
|
@@ -100375,7 +100433,7 @@ __export(ProcessMonitor_exports, {
|
|
|
100375
100433
|
ProcessMonitor: () => ProcessMonitor
|
|
100376
100434
|
});
|
|
100377
100435
|
import { Shield as Shield7, Square as Square9, Terminal as Terminal15 } from "lucide-react";
|
|
100378
|
-
import { useCallback as useCallback86, useEffect as useEffect144, useRef as
|
|
100436
|
+
import { useCallback as useCallback86, useEffect as useEffect144, useRef as useRef78, useState as useState160 } from "react";
|
|
100379
100437
|
import { jsx as jsx294, jsxs as jsxs282 } from "react/jsx-runtime";
|
|
100380
100438
|
function ProcessMonitor({
|
|
100381
100439
|
open,
|
|
@@ -100387,8 +100445,8 @@ function ProcessMonitor({
|
|
|
100387
100445
|
const sessionId = useActiveSessionId();
|
|
100388
100446
|
const ws = useWebSocket();
|
|
100389
100447
|
const wsConnected = useConfigStore((s) => s.wsConnected);
|
|
100390
|
-
const offRef =
|
|
100391
|
-
const pollRef =
|
|
100448
|
+
const offRef = useRef78(null);
|
|
100449
|
+
const pollRef = useRef78(null);
|
|
100392
100450
|
useEffect144(() => {
|
|
100393
100451
|
if (!open || !wsConnected || !ws.client?.isConnected) return;
|
|
100394
100452
|
setProcesses([]);
|
|
@@ -100608,7 +100666,7 @@ import { FitAddon } from "@xterm/addon-fit";
|
|
|
100608
100666
|
import { Terminal as Terminal16 } from "@xterm/xterm";
|
|
100609
100667
|
import "@xterm/xterm/css/xterm.css";
|
|
100610
100668
|
import { Plus as Plus30, RotateCcw as RotateCcw23, TerminalSquare as TerminalSquare7, Trash2 as Trash229, X as X65 } from "lucide-react";
|
|
100611
|
-
import { useEffect as useEffect153, useRef as
|
|
100669
|
+
import { useEffect as useEffect153, useRef as useRef84, useState as useState168 } from "react";
|
|
100612
100670
|
import { jsx as jsx304, jsxs as jsxs292 } from "react/jsx-runtime";
|
|
100613
100671
|
function defaultTerminalHeight(compact = false) {
|
|
100614
100672
|
if (typeof window === "undefined") return 300;
|
|
@@ -100644,14 +100702,14 @@ function TerminalPanel({
|
|
|
100644
100702
|
desktopShell = false,
|
|
100645
100703
|
onClose
|
|
100646
100704
|
}) {
|
|
100647
|
-
const resizeCleanupRef =
|
|
100705
|
+
const resizeCleanupRef = useRef84(null);
|
|
100648
100706
|
const { t } = useTranslation();
|
|
100649
|
-
const terminalCounterRef =
|
|
100707
|
+
const terminalCounterRef = useRef84(1);
|
|
100650
100708
|
const [height, setHeight] = useState168(() => readStoredTerminalHeight(desktopShell));
|
|
100651
100709
|
const [tabs, setTabs] = useState168(() => [createTerminalTab(1)]);
|
|
100652
100710
|
const [activeId, setActiveId] = useState168(() => tabs[0]?.id ?? "");
|
|
100653
100711
|
const terminalCreateNonce = useUIStore((s) => s.terminalCreateNonce);
|
|
100654
|
-
const lastTerminalCreateNonceRef =
|
|
100712
|
+
const lastTerminalCreateNonceRef = useRef84(terminalCreateNonce);
|
|
100655
100713
|
const projectName = useSessionStore((s) => s.projectName);
|
|
100656
100714
|
const cwd = useSessionStore((s) => s.cwd);
|
|
100657
100715
|
useEffect153(() => {
|
|
@@ -100908,11 +100966,11 @@ function TerminalSession({
|
|
|
100908
100966
|
onRunning,
|
|
100909
100967
|
onExit
|
|
100910
100968
|
}) {
|
|
100911
|
-
const containerRef =
|
|
100912
|
-
const termRef =
|
|
100913
|
-
const fitRef =
|
|
100914
|
-
const onRunningRef =
|
|
100915
|
-
const onExitRef =
|
|
100969
|
+
const containerRef = useRef84(null);
|
|
100970
|
+
const termRef = useRef84(null);
|
|
100971
|
+
const fitRef = useRef84(null);
|
|
100972
|
+
const onRunningRef = useRef84(onRunning);
|
|
100973
|
+
const onExitRef = useRef84(onExit);
|
|
100916
100974
|
const wsConnected = useConfigStore((s) => s.wsConnected);
|
|
100917
100975
|
const { terminal: terminalFont } = useFontSettings();
|
|
100918
100976
|
useEffect153(() => {
|
|
@@ -101235,7 +101293,7 @@ __export(QueuePanel_exports, {
|
|
|
101235
101293
|
QueuePanel: () => QueuePanel
|
|
101236
101294
|
});
|
|
101237
101295
|
import { ArrowDownAZ as ArrowDownAZ2, ArrowUpAZ as ArrowUpAZ2, Check as Check56, ListOrdered, Trash2 as Trash231, X as X67 } from "lucide-react";
|
|
101238
|
-
import { useCallback as useCallback95, useLayoutEffect as useLayoutEffect9, useMemo as useMemo94, useRef as
|
|
101296
|
+
import { useCallback as useCallback95, useLayoutEffect as useLayoutEffect9, useMemo as useMemo94, useRef as useRef85, useState as useState172 } from "react";
|
|
101239
101297
|
import { jsx as jsx310, jsxs as jsxs298 } from "react/jsx-runtime";
|
|
101240
101298
|
function QueuePanel({
|
|
101241
101299
|
open,
|
|
@@ -101248,7 +101306,7 @@ function QueuePanel({
|
|
|
101248
101306
|
const clearQueue = useChatStore((s) => s.clearQueue);
|
|
101249
101307
|
const [sortDir, setSortDir] = useState172("oldest");
|
|
101250
101308
|
const sessionId = useActiveSessionId();
|
|
101251
|
-
const sortSessionRef =
|
|
101309
|
+
const sortSessionRef = useRef85(sessionId ?? QUEUE_PANEL_NO_SESSION);
|
|
101252
101310
|
useLayoutEffect9(() => {
|
|
101253
101311
|
if (!disposedQueuePanelSessions.has(sortSessionRef.current)) {
|
|
101254
101312
|
queueSortBySession.set(sortSessionRef.current, sortDir);
|
|
@@ -101685,7 +101743,7 @@ function ActivityBar({ desktopShell = false }) {
|
|
|
101685
101743
|
setDragOverId(null);
|
|
101686
101744
|
e.dataTransfer.effectAllowed = "move";
|
|
101687
101745
|
};
|
|
101688
|
-
const onDragOver = (
|
|
101746
|
+
const onDragOver = (_group, id) => (e) => {
|
|
101689
101747
|
if (!reorderMode || dragId == null || dragId === id) return;
|
|
101690
101748
|
if (isLockedId(id)) return;
|
|
101691
101749
|
e.preventDefault();
|
|
@@ -102057,6 +102115,7 @@ function ActivityIcon({
|
|
|
102057
102115
|
locked && reorderMode && /* @__PURE__ */ jsx3(
|
|
102058
102116
|
"span",
|
|
102059
102117
|
{
|
|
102118
|
+
role: "img",
|
|
102060
102119
|
"aria-label": "locked",
|
|
102061
102120
|
className: "absolute -top-1 -left-1 h-3.5 w-3.5 flex items-center justify-center rounded-full bg-background text-muted-foreground ring-1 ring-border",
|
|
102062
102121
|
children: /* @__PURE__ */ jsx3(Lock, { size: 9 })
|
|
@@ -126752,7 +126811,7 @@ init_i18n();
|
|
|
126752
126811
|
init_utils();
|
|
126753
126812
|
init_stores();
|
|
126754
126813
|
init_local_prefs();
|
|
126755
|
-
import { useCallback as useCallback79, useEffect as useEffect129, useRef as
|
|
126814
|
+
import { useCallback as useCallback79, useEffect as useEffect129, useRef as useRef67, useState as useState139 } from "react";
|
|
126756
126815
|
import { useShallow as useShallow14 } from "zustand/react/shallow";
|
|
126757
126816
|
|
|
126758
126817
|
// src/components/ChatInput/chat-input-bars.tsx
|
|
@@ -126871,7 +126930,7 @@ init_utils();
|
|
|
126871
126930
|
init_local_prefs();
|
|
126872
126931
|
init_session_store();
|
|
126873
126932
|
import { Split as Split4, X as X57 } from "lucide-react";
|
|
126874
|
-
import { useEffect as useEffect117, useRef as
|
|
126933
|
+
import { useEffect as useEffect117, useRef as useRef58, useState as useState130 } from "react";
|
|
126875
126934
|
import { jsx as jsx251, jsxs as jsxs239 } from "react/jsx-runtime";
|
|
126876
126935
|
var MAX_LANES3 = 16;
|
|
126877
126936
|
var DEFAULT_LANES2 = 8;
|
|
@@ -126888,7 +126947,7 @@ function SubagentModelsButton() {
|
|
|
126888
126947
|
const { updatePrefs } = useWebSocket();
|
|
126889
126948
|
const [open, setOpen] = useState130(false);
|
|
126890
126949
|
const [pickerLane, setPickerLane] = useState130(null);
|
|
126891
|
-
const wrapRef =
|
|
126950
|
+
const wrapRef = useRef58(null);
|
|
126892
126951
|
const plan = useLocalPrefs((s) => s.subagentModelPlan);
|
|
126893
126952
|
const sessionProvider = useSessionStore((s) => s.session?.provider);
|
|
126894
126953
|
const sessionModel = useSessionStore((s) => s.session?.model);
|
|
@@ -127578,7 +127637,7 @@ init_i18n();
|
|
|
127578
127637
|
init_stores();
|
|
127579
127638
|
import { expectDefined as expectDefined8 } from "@wrongstack/core/utils/expect-defined";
|
|
127580
127639
|
import { FileText as FileText22, Folder as Folder3 } from "lucide-react";
|
|
127581
|
-
import { useEffect as useEffect118, useRef as
|
|
127640
|
+
import { useEffect as useEffect118, useRef as useRef59, useState as useState131 } from "react";
|
|
127582
127641
|
import { jsx as jsx256, jsxs as jsxs245 } from "react/jsx-runtime";
|
|
127583
127642
|
function FilePicker({ query, onPick, onClose }) {
|
|
127584
127643
|
const { t } = useTranslation();
|
|
@@ -127586,8 +127645,8 @@ function FilePicker({ query, onPick, onClose }) {
|
|
|
127586
127645
|
const wsUrl = useConfigStore((s) => s.wsUrl);
|
|
127587
127646
|
const [files, setFiles] = useState131([]);
|
|
127588
127647
|
const [index, setIndex] = useState131(0);
|
|
127589
|
-
const debounceRef =
|
|
127590
|
-
const wantHandle =
|
|
127648
|
+
const debounceRef = useRef59(null);
|
|
127649
|
+
const wantHandle = useRef59(null);
|
|
127591
127650
|
useEffect118(() => {
|
|
127592
127651
|
const client2 = getWSClient(wsUrl);
|
|
127593
127652
|
const off = client2.on("files.list", (msg) => {
|
|
@@ -127705,7 +127764,7 @@ import {
|
|
|
127705
127764
|
stripNextStepsBlock as stripNextStepsBlock2
|
|
127706
127765
|
} from "@wrongstack/tools/next-steps";
|
|
127707
127766
|
import { ArrowRight as ArrowRight5, Check as Check44, Lightbulb as Lightbulb2, MousePointerClick, Timer as Timer2 } from "lucide-react";
|
|
127708
|
-
import { useCallback as useCallback74, useEffect as useEffect119, useMemo as useMemo80, useRef as
|
|
127767
|
+
import { useCallback as useCallback74, useEffect as useEffect119, useMemo as useMemo80, useRef as useRef60, useState as useState132 } from "react";
|
|
127709
127768
|
import { jsx as jsx258, jsxs as jsxs246 } from "react/jsx-runtime";
|
|
127710
127769
|
function fillInput(text5) {
|
|
127711
127770
|
const ta = document.querySelector("[data-chat-textarea]") ?? document.querySelector("textarea");
|
|
@@ -127723,7 +127782,7 @@ function AutoCountdown({
|
|
|
127723
127782
|
onComplete
|
|
127724
127783
|
}) {
|
|
127725
127784
|
const [remaining2, setRemaining] = useState132(Math.ceil(delayMs / 1e3));
|
|
127726
|
-
const onCompleteRef =
|
|
127785
|
+
const onCompleteRef = useRef60(onComplete);
|
|
127727
127786
|
onCompleteRef.current = onComplete;
|
|
127728
127787
|
useEffect119(() => {
|
|
127729
127788
|
if (remaining2 <= 0) {
|
|
@@ -127745,7 +127804,7 @@ function SessionEndFillCountdown({
|
|
|
127745
127804
|
onComplete
|
|
127746
127805
|
}) {
|
|
127747
127806
|
const [remaining2, setRemaining] = useState132(seconds);
|
|
127748
|
-
const onCompleteRef =
|
|
127807
|
+
const onCompleteRef = useRef60(onComplete);
|
|
127749
127808
|
onCompleteRef.current = onComplete;
|
|
127750
127809
|
useEffect119(() => {
|
|
127751
127810
|
if (remaining2 <= 0) {
|
|
@@ -127791,7 +127850,7 @@ function NextStepsBar({
|
|
|
127791
127850
|
[steps, selectedIndices]
|
|
127792
127851
|
);
|
|
127793
127852
|
const [autoFillActive, setAutoFillActive] = useState132(false);
|
|
127794
|
-
const autoFillFired =
|
|
127853
|
+
const autoFillFired = useRef60(false);
|
|
127795
127854
|
useEffect119(() => {
|
|
127796
127855
|
if (!isLatest || !sessionEndAutoFill) return;
|
|
127797
127856
|
if (autoFillActive || autoFillFired.current) return;
|
|
@@ -127804,7 +127863,7 @@ function NextStepsBar({
|
|
|
127804
127863
|
document.addEventListener("chat:next-step-countdown", handler);
|
|
127805
127864
|
return () => document.removeEventListener("chat:next-step-countdown", handler);
|
|
127806
127865
|
}, [steps.length, autoFillActive, isLatest, sessionEndAutoFill]);
|
|
127807
|
-
const prevGateRef =
|
|
127866
|
+
const prevGateRef = useRef60(yoloMode && autoMode && canAutoSubmitProp);
|
|
127808
127867
|
useEffect119(() => {
|
|
127809
127868
|
const gateOpen2 = yoloMode && autoMode && canAutoSubmitProp;
|
|
127810
127869
|
const wasOpen = prevGateRef.current;
|
|
@@ -128147,7 +128206,7 @@ init_i18n();
|
|
|
128147
128206
|
init_utils();
|
|
128148
128207
|
init_dialog();
|
|
128149
128208
|
import { Search as Search29, Star as Star8 } from "lucide-react";
|
|
128150
|
-
import { useEffect as useEffect120, useMemo as useMemo82, useRef as
|
|
128209
|
+
import { useEffect as useEffect120, useMemo as useMemo82, useRef as useRef61, useState as useState134 } from "react";
|
|
128151
128210
|
import { jsx as jsx260, jsxs as jsxs248 } from "react/jsx-runtime";
|
|
128152
128211
|
function ModelPickDialog({
|
|
128153
128212
|
open,
|
|
@@ -128160,7 +128219,7 @@ function ModelPickDialog({
|
|
|
128160
128219
|
const candidates = useProviderModels(open);
|
|
128161
128220
|
const [query, setQuery] = useState134("");
|
|
128162
128221
|
const [cursor, setCursor] = useState134(0);
|
|
128163
|
-
const listRef =
|
|
128222
|
+
const listRef = useRef61(null);
|
|
128164
128223
|
useEffect120(() => {
|
|
128165
128224
|
if (open) {
|
|
128166
128225
|
setQuery("");
|
|
@@ -128250,7 +128309,7 @@ init_local_prefs();
|
|
|
128250
128309
|
init_utils();
|
|
128251
128310
|
init_useWebSocket();
|
|
128252
128311
|
init_button();
|
|
128253
|
-
import { useCallback as useCallback75, useEffect as useEffect121, useRef as
|
|
128312
|
+
import { useCallback as useCallback75, useEffect as useEffect121, useRef as useRef62, useState as useState135 } from "react";
|
|
128254
128313
|
import {
|
|
128255
128314
|
AlertTriangle as AlertTriangle35,
|
|
128256
128315
|
Check as Check46,
|
|
@@ -128304,14 +128363,14 @@ function RefinePanel({
|
|
|
128304
128363
|
);
|
|
128305
128364
|
const [editText, setEditText] = useState135(refined);
|
|
128306
128365
|
const [isEditing, setIsEditing] = useState135(false);
|
|
128307
|
-
const countdownRef =
|
|
128308
|
-
const panelRef =
|
|
128309
|
-
const onStartRefineRef =
|
|
128366
|
+
const countdownRef = useRef62(null);
|
|
128367
|
+
const panelRef = useRef62(null);
|
|
128368
|
+
const onStartRefineRef = useRef62(onStartRefine);
|
|
128310
128369
|
onStartRefineRef.current = onStartRefine;
|
|
128311
128370
|
const [preRefineCountdown, setPreRefineCountdown] = useState135(
|
|
128312
128371
|
Math.max(0, Math.ceil(enhanceCountdownMs / 1e3))
|
|
128313
128372
|
);
|
|
128314
|
-
const preRefineTimerRef =
|
|
128373
|
+
const preRefineTimerRef = useRef62(null);
|
|
128315
128374
|
useEffect121(() => {
|
|
128316
128375
|
if (status !== "countdown") return;
|
|
128317
128376
|
const seconds = Math.max(0, Math.ceil(enhanceCountdownMs / 1e3));
|
|
@@ -129035,7 +129094,7 @@ function ChatInputRefinePanelHost({
|
|
|
129035
129094
|
init_stores();
|
|
129036
129095
|
init_chat_lanes();
|
|
129037
129096
|
init_ConfirmModal();
|
|
129038
|
-
import { useEffect as useEffect122, useRef as
|
|
129097
|
+
import { useEffect as useEffect122, useRef as useRef63 } from "react";
|
|
129039
129098
|
function resolveCancelInput(prev, original) {
|
|
129040
129099
|
return prev.trim() ? prev : original;
|
|
129041
129100
|
}
|
|
@@ -129069,7 +129128,7 @@ function useSessionDraft({
|
|
|
129069
129128
|
refineBackstopTimerRef,
|
|
129070
129129
|
textareaRef
|
|
129071
129130
|
}) {
|
|
129072
|
-
const prevSessionIdRef =
|
|
129131
|
+
const prevSessionIdRef = useRef63(sessionId);
|
|
129073
129132
|
useEffect122(() => {
|
|
129074
129133
|
if (prevSessionIdRef.current === sessionId) return;
|
|
129075
129134
|
const oldId = prevSessionIdRef.current;
|
|
@@ -129256,7 +129315,7 @@ function useChatInputMcp({ client: client2, sendMessage }) {
|
|
|
129256
129315
|
}
|
|
129257
129316
|
|
|
129258
129317
|
// src/components/ChatInput/use-chat-keydown.ts
|
|
129259
|
-
import { useCallback as useCallback76, useEffect as useEffect124, useRef as
|
|
129318
|
+
import { useCallback as useCallback76, useEffect as useEffect124, useRef as useRef64, useState as useState136 } from "react";
|
|
129260
129319
|
function useChatKeyDown({
|
|
129261
129320
|
input,
|
|
129262
129321
|
setInput,
|
|
@@ -129268,7 +129327,7 @@ function useChatKeyDown({
|
|
|
129268
129327
|
}) {
|
|
129269
129328
|
const [slashIndex, setSlashIndex] = useState136(0);
|
|
129270
129329
|
const [historyIdx, setHistoryIdx] = useState136(-1);
|
|
129271
|
-
const stickyDraftRef =
|
|
129330
|
+
const stickyDraftRef = useRef64(null);
|
|
129272
129331
|
const slashSuggestions = input.startsWith("/") && !input.includes(" ") ? matchSlash(input) : [];
|
|
129273
129332
|
useEffect124(() => {
|
|
129274
129333
|
if (slashIndex >= slashSuggestions.length) setSlashIndex(0);
|
|
@@ -129793,7 +129852,7 @@ function useChatSubmit({
|
|
|
129793
129852
|
// src/components/ChatInput/use-paste-drop.ts
|
|
129794
129853
|
init_stores();
|
|
129795
129854
|
init_Toaster();
|
|
129796
|
-
import { useEffect as useEffect126, useRef as
|
|
129855
|
+
import { useEffect as useEffect126, useRef as useRef65, useState as useState137 } from "react";
|
|
129797
129856
|
|
|
129798
129857
|
// src/components/ChatInput/code-detect.ts
|
|
129799
129858
|
var LANG_PATTERNS = [
|
|
@@ -129993,7 +130052,7 @@ init_image_attachments();
|
|
|
129993
130052
|
function usePasteDrop({ input, textareaRef, setInput, errorText }) {
|
|
129994
130053
|
const [pasteHint, setPasteHint] = useState137(null);
|
|
129995
130054
|
const [draggingOver, setDraggingOver] = useState137(false);
|
|
129996
|
-
const pendingImagesRef =
|
|
130055
|
+
const pendingImagesRef = useRef65(useUIStore.getState().draftImages);
|
|
129997
130056
|
const [pendingImages, setPendingImagesState] = useState137(
|
|
129998
130057
|
() => useUIStore.getState().draftImages
|
|
129999
130058
|
);
|
|
@@ -130002,7 +130061,7 @@ function usePasteDrop({ input, textareaRef, setInput, errorText }) {
|
|
|
130002
130061
|
setPendingImagesState(next);
|
|
130003
130062
|
useUIStore.getState().setDraftImages(next);
|
|
130004
130063
|
};
|
|
130005
|
-
const errorTextRef =
|
|
130064
|
+
const errorTextRef = useRef65(errorText);
|
|
130006
130065
|
errorTextRef.current = errorText;
|
|
130007
130066
|
const addImageFiles = async (files) => {
|
|
130008
130067
|
const err = errorTextRef.current;
|
|
@@ -130197,19 +130256,21 @@ function useRefineTimeout({
|
|
|
130197
130256
|
}
|
|
130198
130257
|
|
|
130199
130258
|
// src/components/ChatInput/use-speech-recognition.ts
|
|
130200
|
-
import { useCallback as useCallback78, useEffect as useEffect128, useRef as
|
|
130259
|
+
import { useCallback as useCallback78, useEffect as useEffect128, useRef as useRef66, useState as useState138 } from "react";
|
|
130260
|
+
function speechRecognitionCtor() {
|
|
130261
|
+
if (typeof window === "undefined") return void 0;
|
|
130262
|
+
const w = window;
|
|
130263
|
+
return w.SpeechRecognition ?? w.webkitSpeechRecognition;
|
|
130264
|
+
}
|
|
130201
130265
|
function useSpeechRecognition({ onTranscript }) {
|
|
130202
130266
|
const [isListening, setIsListening] = useState138(false);
|
|
130203
130267
|
const [isSupported, setIsSupported] = useState138(false);
|
|
130204
|
-
const recognitionRef =
|
|
130268
|
+
const recognitionRef = useRef66(null);
|
|
130205
130269
|
useEffect128(() => {
|
|
130206
|
-
|
|
130207
|
-
const SpeechRecognition = window.SpeechRecognition || window.webkitSpeechRecognition;
|
|
130208
|
-
setIsSupported(Boolean(SpeechRecognition));
|
|
130270
|
+
setIsSupported(Boolean(speechRecognitionCtor()));
|
|
130209
130271
|
}, []);
|
|
130210
130272
|
const toggleListening = useCallback78(() => {
|
|
130211
|
-
|
|
130212
|
-
const SpeechRecognition = window.SpeechRecognition || window.webkitSpeechRecognition;
|
|
130273
|
+
const SpeechRecognition = speechRecognitionCtor();
|
|
130213
130274
|
if (!SpeechRecognition) return;
|
|
130214
130275
|
if (isListening) {
|
|
130215
130276
|
recognitionRef.current?.stop();
|
|
@@ -130297,7 +130358,7 @@ function ChatInput({
|
|
|
130297
130358
|
const fallbackProvider = useConfigStore((s) => s.provider);
|
|
130298
130359
|
const fallbackModel = useConfigStore((s) => s.model);
|
|
130299
130360
|
const [input, setInput] = useState139(() => useUIStore.getState().draftInput ?? "");
|
|
130300
|
-
const refineBackstopTimerRef =
|
|
130361
|
+
const refineBackstopTimerRef = useRef67(null);
|
|
130301
130362
|
const {
|
|
130302
130363
|
isListening,
|
|
130303
130364
|
isSupported: isSpeechSupported,
|
|
@@ -130320,9 +130381,9 @@ function ChatInput({
|
|
|
130320
130381
|
const [atMention, setAtMention] = useState139(null);
|
|
130321
130382
|
const [refinePickOpen, setRefinePickOpen] = useState139(false);
|
|
130322
130383
|
const [topicCheckBusy, setTopicCheckBusy] = useState139(false);
|
|
130323
|
-
const topicCheckBusyRef =
|
|
130324
|
-
const topicCheckAbortRef =
|
|
130325
|
-
const textareaRef =
|
|
130384
|
+
const topicCheckBusyRef = useRef67(false);
|
|
130385
|
+
const topicCheckAbortRef = useRef67(null);
|
|
130386
|
+
const textareaRef = useRef67(null);
|
|
130326
130387
|
const fileRefs = useFileReferenceStore((s) => s.refs);
|
|
130327
130388
|
const { removeRef, clearRefs } = useFileReferenceStore.getState();
|
|
130328
130389
|
const {
|
|
@@ -130350,7 +130411,7 @@ function ChatInput({
|
|
|
130350
130411
|
imageTooLarge: (name) => t("chat:input.imageTooLarge", { name })
|
|
130351
130412
|
}
|
|
130352
130413
|
});
|
|
130353
|
-
const imagePickerRef =
|
|
130414
|
+
const imagePickerRef = useRef67(null);
|
|
130354
130415
|
useEffect129(() => {
|
|
130355
130416
|
useUIStore.getState().setDraftInput(input);
|
|
130356
130417
|
}, [input]);
|
|
@@ -130378,7 +130439,7 @@ function ChatInput({
|
|
|
130378
130439
|
useLocalPrefs.getState().set({ enhanceEnabled: next });
|
|
130379
130440
|
updatePrefs({ enhanceEnabled: next });
|
|
130380
130441
|
}, [enhanceEnabled, updatePrefs]);
|
|
130381
|
-
const runSlashCommandRef =
|
|
130442
|
+
const runSlashCommandRef = useRef67(() => false);
|
|
130382
130443
|
const {
|
|
130383
130444
|
sendMsg,
|
|
130384
130445
|
handleSubmit,
|
|
@@ -130675,7 +130736,7 @@ init_utils();
|
|
|
130675
130736
|
init_stores();
|
|
130676
130737
|
init_dialog();
|
|
130677
130738
|
import { Clock as Clock15, History as History11, Rewind } from "lucide-react";
|
|
130678
|
-
import { useCallback as useCallback80, useEffect as useEffect130, useRef as
|
|
130739
|
+
import { useCallback as useCallback80, useEffect as useEffect130, useRef as useRef68, useState as useState140 } from "react";
|
|
130679
130740
|
import { jsx as jsx265, jsxs as jsxs253 } from "react/jsx-runtime";
|
|
130680
130741
|
function mapCheckpoint(cp) {
|
|
130681
130742
|
return {
|
|
@@ -130698,7 +130759,7 @@ function CheckpointTimeline({
|
|
|
130698
130759
|
const [rewinding, setRewinding] = useState140(false);
|
|
130699
130760
|
const ws = useWebSocket();
|
|
130700
130761
|
const wsConnected = useConfigStore((s) => s.wsConnected);
|
|
130701
|
-
const offRef =
|
|
130762
|
+
const offRef = useRef68(null);
|
|
130702
130763
|
const sessionId = useActiveSessionId();
|
|
130703
130764
|
useEffect130(() => {
|
|
130704
130765
|
if (!open || !wsConnected || !ws.client?.isConnected) return;
|
|
@@ -130833,7 +130894,7 @@ function CheckpointTimeline({
|
|
|
130833
130894
|
// src/components/context-editor/ContextWindowEditor.tsx
|
|
130834
130895
|
init_ws_client();
|
|
130835
130896
|
init_ws_client_utils();
|
|
130836
|
-
import { useCallback as useCallback81, useEffect as useEffect131, useRef as
|
|
130897
|
+
import { useCallback as useCallback81, useEffect as useEffect131, useRef as useRef69, useState as useState141 } from "react";
|
|
130837
130898
|
|
|
130838
130899
|
// src/stores/context-editor-store.ts
|
|
130839
130900
|
init_session_scoped_store();
|
|
@@ -131101,7 +131162,7 @@ function SelectableContent({
|
|
|
131101
131162
|
onMarkRange
|
|
131102
131163
|
}) {
|
|
131103
131164
|
const [selection, setSelection] = useState141(null);
|
|
131104
|
-
const contentRef =
|
|
131165
|
+
const contentRef = useRef69(null);
|
|
131105
131166
|
const captureSelection = useCallback81(() => {
|
|
131106
131167
|
if (disabled) return;
|
|
131107
131168
|
const element = contentRef.current;
|
|
@@ -131272,7 +131333,7 @@ function ContextWindowEditor({
|
|
|
131272
131333
|
const isLoading = useChatStore((s) => s.isLoading);
|
|
131273
131334
|
const contextLimitWarning = useSessionStore((s) => s.contextLimitWarning);
|
|
131274
131335
|
const activeSessionId = useActiveSessionId();
|
|
131275
|
-
const restoreFocusRef =
|
|
131336
|
+
const restoreFocusRef = useRef69(null);
|
|
131276
131337
|
const askedFor = getWSClient()?.withSession?.({})?.sessionId ?? activeSessionId ?? foregroundSessionId() ?? void 0;
|
|
131277
131338
|
useServerMessage(
|
|
131278
131339
|
"context.editor.snapshot",
|
|
@@ -131899,7 +131960,7 @@ init_utils();
|
|
|
131899
131960
|
init_i18n();
|
|
131900
131961
|
init_stores();
|
|
131901
131962
|
import { ArrowDown as ArrowDown4, ArrowUp as ArrowUp3, Search as Search30, X as X60 } from "lucide-react";
|
|
131902
|
-
import { useEffect as useEffect133, useMemo as useMemo84, useRef as
|
|
131963
|
+
import { useEffect as useEffect133, useMemo as useMemo84, useRef as useRef70, useState as useState143 } from "react";
|
|
131903
131964
|
import { jsx as jsx268, jsxs as jsxs256 } from "react/jsx-runtime";
|
|
131904
131965
|
var HIGHLIGHT_STYLES = `
|
|
131905
131966
|
::highlight(chat-search) { background-color: hsl(var(--primary) / 0.3); color: inherit; }
|
|
@@ -131923,7 +131984,7 @@ function SearchOverlay() {
|
|
|
131923
131984
|
const messages = useChatStore((s) => s.messages);
|
|
131924
131985
|
const requestScrollToMessage = useUIStore((s) => s.requestScrollToMessage);
|
|
131925
131986
|
const setSearchActiveMessageId = useUIStore((s) => s.setSearchActiveMessageId);
|
|
131926
|
-
const inputRef =
|
|
131987
|
+
const inputRef = useRef70(null);
|
|
131927
131988
|
const [activeHit, setActiveHit] = useState143(0);
|
|
131928
131989
|
const [repaintNonce, setRepaintNonce] = useState143(0);
|
|
131929
131990
|
useEffect133(() => {
|
|
@@ -133446,7 +133507,7 @@ import {
|
|
|
133446
133507
|
init_utils();
|
|
133447
133508
|
init_i18n();
|
|
133448
133509
|
import { Activity as Activity30, ArrowRightLeft, ChevronDown as ChevronDown32, Pause as Pause7, Play as Play11 } from "lucide-react";
|
|
133449
|
-
import { useState as useState146, useRef as
|
|
133510
|
+
import { useState as useState146, useRef as useRef71, useEffect as useEffect136 } from "react";
|
|
133450
133511
|
import { jsx as jsx274, jsxs as jsxs262 } from "react/jsx-runtime";
|
|
133451
133512
|
var AUTONOMY_OPTIONS = [
|
|
133452
133513
|
{
|
|
@@ -133488,7 +133549,7 @@ function AutonomyPicker({
|
|
|
133488
133549
|
}) {
|
|
133489
133550
|
const { t } = useTranslation();
|
|
133490
133551
|
const [open, setOpen] = useState146(false);
|
|
133491
|
-
const ref =
|
|
133552
|
+
const ref = useRef71(null);
|
|
133492
133553
|
useEffect136(() => {
|
|
133493
133554
|
if (!open) return;
|
|
133494
133555
|
const handler = (e) => {
|
|
@@ -133564,7 +133625,7 @@ init_i18n();
|
|
|
133564
133625
|
init_stores();
|
|
133565
133626
|
import { expectDefined as expectDefined10 } from "@wrongstack/core/utils/expect-defined";
|
|
133566
133627
|
import { Check as Check48, ChevronDown as ChevronDown33, Gauge as Gauge5, Wrench as Wrench15, Zap as Zap27, FileSearch } from "lucide-react";
|
|
133567
|
-
import { useCallback as useCallback84, useEffect as useEffect137, useRef as
|
|
133628
|
+
import { useCallback as useCallback84, useEffect as useEffect137, useRef as useRef72, useState as useState147 } from "react";
|
|
133568
133629
|
import { jsx as jsx275, jsxs as jsxs263 } from "react/jsx-runtime";
|
|
133569
133630
|
function ContextModePicker() {
|
|
133570
133631
|
const { t } = useTranslation();
|
|
@@ -133573,8 +133634,8 @@ function ContextModePicker() {
|
|
|
133573
133634
|
const { listContextModes, switchContextMode, client: client2 } = useWebSocket();
|
|
133574
133635
|
const [open, setOpen] = useState147(false);
|
|
133575
133636
|
const [opsOpen, setOpsOpen] = useState147(false);
|
|
133576
|
-
const rootRef =
|
|
133577
|
-
const opsRef =
|
|
133637
|
+
const rootRef = useRef72(null);
|
|
133638
|
+
const opsRef = useRef72(null);
|
|
133578
133639
|
useEffect137(() => {
|
|
133579
133640
|
if (open) listContextModes();
|
|
133580
133641
|
}, [open, listContextModes]);
|
|
@@ -133784,7 +133845,7 @@ function ContextModePicker() {
|
|
|
133784
133845
|
init_utils();
|
|
133785
133846
|
init_i18n();
|
|
133786
133847
|
init_stores();
|
|
133787
|
-
import { useEffect as useEffect138, useRef as
|
|
133848
|
+
import { useEffect as useEffect138, useRef as useRef73, useState as useState148 } from "react";
|
|
133788
133849
|
import { Fragment as Fragment73, jsx as jsx276, jsxs as jsxs264 } from "react/jsx-runtime";
|
|
133789
133850
|
function CostChip() {
|
|
133790
133851
|
const { t } = useTranslation();
|
|
@@ -133794,7 +133855,7 @@ function CostChip() {
|
|
|
133794
133855
|
const cacheReadCost = useSessionStore((s) => s.cacheReadCost);
|
|
133795
133856
|
const messages = useChatStore((s) => s.messages);
|
|
133796
133857
|
const [open, setOpen] = useState148(false);
|
|
133797
|
-
const rootRef =
|
|
133858
|
+
const rootRef = useRef73(null);
|
|
133798
133859
|
useEffect138(() => {
|
|
133799
133860
|
if (!open) return;
|
|
133800
133861
|
const onClick = (e) => {
|
|
@@ -133910,7 +133971,7 @@ init_utils();
|
|
|
133910
133971
|
init_i18n();
|
|
133911
133972
|
init_stores();
|
|
133912
133973
|
import { Check as Check49, ChevronDown as ChevronDown34 } from "lucide-react";
|
|
133913
|
-
import { useEffect as useEffect139, useRef as
|
|
133974
|
+
import { useEffect as useEffect139, useRef as useRef74, useState as useState149 } from "react";
|
|
133914
133975
|
import { jsx as jsx277, jsxs as jsxs265 } from "react/jsx-runtime";
|
|
133915
133976
|
function ModePicker() {
|
|
133916
133977
|
const { t } = useTranslation();
|
|
@@ -133918,7 +133979,7 @@ function ModePicker() {
|
|
|
133918
133979
|
const modes = useSessionStore((s) => s.modes);
|
|
133919
133980
|
const { listModes, switchMode } = useWebSocket();
|
|
133920
133981
|
const [open, setOpen] = useState149(false);
|
|
133921
|
-
const rootRef =
|
|
133982
|
+
const rootRef = useRef74(null);
|
|
133922
133983
|
useEffect139(() => {
|
|
133923
133984
|
if (open) listModes();
|
|
133924
133985
|
}, [open, listModes]);
|
|
@@ -135442,7 +135503,7 @@ init_i18n();
|
|
|
135442
135503
|
init_ws_client();
|
|
135443
135504
|
init_stores();
|
|
135444
135505
|
init_auto_submit_streak();
|
|
135445
|
-
import { useEffect as useEffect140, useRef as
|
|
135506
|
+
import { useEffect as useEffect140, useRef as useRef75, useState as useState153 } from "react";
|
|
135446
135507
|
import { jsx as jsx283, jsxs as jsxs271 } from "react/jsx-runtime";
|
|
135447
135508
|
var CHIMERA_PATTERN = /chimera/i;
|
|
135448
135509
|
var FRESH_FAILURE_WINDOW_MS = 6e4;
|
|
@@ -135463,7 +135524,7 @@ function FailedRunContinue({ text: text5, timestamp: timestamp2 }) {
|
|
|
135463
135524
|
if (timestamp2 === void 0 || Date.now() - timestamp2 >= FRESH_FAILURE_WINDOW_MS) return null;
|
|
135464
135525
|
return autoTriggerMsFor(text5);
|
|
135465
135526
|
});
|
|
135466
|
-
const firedRef =
|
|
135527
|
+
const firedRef = useRef75(false);
|
|
135467
135528
|
const [gone, setGone] = useState153(false);
|
|
135468
135529
|
const fire = () => {
|
|
135469
135530
|
if (firedRef.current) return;
|
|
@@ -137404,7 +137465,7 @@ import {
|
|
|
137404
137465
|
Wrench as Wrench19,
|
|
137405
137466
|
X as X63
|
|
137406
137467
|
} from "lucide-react";
|
|
137407
|
-
import { memo as memo15, useEffect as useEffect142, useRef as
|
|
137468
|
+
import { memo as memo15, useEffect as useEffect142, useRef as useRef76, useState as useState158 } from "react";
|
|
137408
137469
|
import { Fragment as Fragment78, jsx as jsx292, jsxs as jsxs280 } from "react/jsx-runtime";
|
|
137409
137470
|
var STATUS_CHIP = {
|
|
137410
137471
|
running: "bg-success/10 text-success",
|
|
@@ -137508,8 +137569,8 @@ function SubagentTranscriptView({ agentId }) {
|
|
|
137508
137569
|
const entries = useFleetStore((s) => s.agentTranscripts.get(agentId) ?? EMPTY_AGENT_TRANSCRIPT);
|
|
137509
137570
|
const setSubagentChatFocus = useUIStore((s) => s.setSubagentChatFocus);
|
|
137510
137571
|
const [taskOpen, setTaskOpen] = useState158(false);
|
|
137511
|
-
const scrollRef =
|
|
137512
|
-
const pinnedRef =
|
|
137572
|
+
const scrollRef = useRef76(null);
|
|
137573
|
+
const pinnedRef = useRef76(true);
|
|
137513
137574
|
const last = entries[entries.length - 1];
|
|
137514
137575
|
const lastContentLen = last?.content.length ?? 0;
|
|
137515
137576
|
useEffect142(() => {
|
|
@@ -137684,7 +137745,7 @@ init_ws_client();
|
|
|
137684
137745
|
init_stores();
|
|
137685
137746
|
init_local_prefs();
|
|
137686
137747
|
init_memory_injector_store();
|
|
137687
|
-
import { useCallback as useCallback85, useEffect as useEffect143, useMemo as useMemo90, useRef as
|
|
137748
|
+
import { useCallback as useCallback85, useEffect as useEffect143, useMemo as useMemo90, useRef as useRef77, useState as useState159 } from "react";
|
|
137688
137749
|
import { useShallow as useShallow17 } from "zustand/react/shallow";
|
|
137689
137750
|
|
|
137690
137751
|
// src/components/ChatView/auto-collapse.ts
|
|
@@ -137739,7 +137800,7 @@ function useChatViewState() {
|
|
|
137739
137800
|
},
|
|
137740
137801
|
[setChatSwitcherOpen]
|
|
137741
137802
|
);
|
|
137742
|
-
const switcherRef =
|
|
137803
|
+
const switcherRef = useRef77(null);
|
|
137743
137804
|
useEffect143(() => {
|
|
137744
137805
|
if (!switcherOpen) return;
|
|
137745
137806
|
const onClick = (e) => {
|
|
@@ -137760,9 +137821,9 @@ function useChatViewState() {
|
|
|
137760
137821
|
);
|
|
137761
137822
|
const provider = session?.provider || configProvider;
|
|
137762
137823
|
const model = session?.model || configModel;
|
|
137763
|
-
const vlistRef =
|
|
137824
|
+
const vlistRef = useRef77(null);
|
|
137764
137825
|
const rows = useMemo90(() => buildChatRows(messages), [messages]);
|
|
137765
|
-
const childCountRef =
|
|
137826
|
+
const childCountRef = useRef77(0);
|
|
137766
137827
|
childCountRef.current = rows.length + 1;
|
|
137767
137828
|
const rowIndexById = useMemo90(() => {
|
|
137768
137829
|
const map = /* @__PURE__ */ new Map();
|
|
@@ -137824,10 +137885,10 @@ function useChatViewState() {
|
|
|
137824
137885
|
},
|
|
137825
137886
|
[setChatInputCollapsed]
|
|
137826
137887
|
);
|
|
137827
|
-
const prevLoading =
|
|
137828
|
-
const prevHadMessages =
|
|
137829
|
-
const prevSessionId =
|
|
137830
|
-
const prevAutoCollapse =
|
|
137888
|
+
const prevLoading = useRef77(isLoading);
|
|
137889
|
+
const prevHadMessages = useRef77(messages.length > 0);
|
|
137890
|
+
const prevSessionId = useRef77(sessionId);
|
|
137891
|
+
const prevAutoCollapse = useRef77(autoCollapseInput);
|
|
137831
137892
|
const breakdownOpen = useUIStore((s) => s.chatContextBreakdownOpen);
|
|
137832
137893
|
const setBreakdownOpen = useUIStore((s) => s.setChatContextBreakdownOpen);
|
|
137833
137894
|
const toolStatsOpen = useUIStore((s) => s.chatToolStatsOpen);
|
|
@@ -137898,7 +137959,7 @@ function useChatViewState() {
|
|
|
137898
137959
|
const [pinnedToBottom, setPinnedToBottom] = useState159(true);
|
|
137899
137960
|
const [unreadCount, setUnreadCount] = useState159(0);
|
|
137900
137961
|
const [scrolledDeep, setScrolledDeep] = useState159(false);
|
|
137901
|
-
const lastSeenCount =
|
|
137962
|
+
const lastSeenCount = useRef77(messages.length);
|
|
137902
137963
|
const handleScroll = useCallback85(() => {
|
|
137903
137964
|
const h = vlistRef.current;
|
|
137904
137965
|
if (!h) return;
|
|
@@ -137956,7 +138017,7 @@ function useChatViewState() {
|
|
|
137956
138017
|
}, []);
|
|
137957
138018
|
const [runStartedAt, setRunStartedAt] = useState159(null);
|
|
137958
138019
|
const [nowTick, setNowTick] = useState159(() => Date.now());
|
|
137959
|
-
const streamAnchor =
|
|
138020
|
+
const streamAnchor = useRef77(null);
|
|
137960
138021
|
const lastMessage = messages[messages.length - 1];
|
|
137961
138022
|
const streamingBubble = lastMessage?.role === "assistant" && lastMessage.streaming && lastMessage.content ? lastMessage : null;
|
|
137962
138023
|
useEffect143(() => {
|
|
@@ -138469,11 +138530,11 @@ import { useEffect as useEffect152, useMemo as useMemo92, useState as useState16
|
|
|
138469
138530
|
// src/hooks/useGitInfo.ts
|
|
138470
138531
|
init_stores();
|
|
138471
138532
|
init_useWebSocket();
|
|
138472
|
-
import { useCallback as useCallback87, useEffect as useEffect146, useRef as
|
|
138533
|
+
import { useCallback as useCallback87, useEffect as useEffect146, useRef as useRef79 } from "react";
|
|
138473
138534
|
function useGitInfo() {
|
|
138474
138535
|
const info = useGitInfoStore((s) => s.info);
|
|
138475
138536
|
const { client: client2 } = useWebSocket();
|
|
138476
|
-
const intervalRef =
|
|
138537
|
+
const intervalRef = useRef79(null);
|
|
138477
138538
|
const fetch2 = useCallback87(() => {
|
|
138478
138539
|
client2?.getGitInfo?.();
|
|
138479
138540
|
}, [client2]);
|
|
@@ -138511,7 +138572,7 @@ import {
|
|
|
138511
138572
|
UserPlus as UserPlus3,
|
|
138512
138573
|
Users as Users10
|
|
138513
138574
|
} from "lucide-react";
|
|
138514
|
-
import { useEffect as useEffect147, useLayoutEffect as useLayoutEffect5, useRef as
|
|
138575
|
+
import { useEffect as useEffect147, useLayoutEffect as useLayoutEffect5, useRef as useRef80, useState as useState161 } from "react";
|
|
138515
138576
|
import { jsx as jsx296, jsxs as jsxs284 } from "react/jsx-runtime";
|
|
138516
138577
|
var collabPanelChromeBySession = /* @__PURE__ */ new Map();
|
|
138517
138578
|
var disposedCollabPanelSessions = /* @__PURE__ */ new Set();
|
|
@@ -138534,7 +138595,7 @@ function CollabPanel({ sessionId, className }) {
|
|
|
138534
138595
|
const [injectContent, setInjectContent] = useState161("");
|
|
138535
138596
|
const [injectIsError, setInjectIsError] = useState161(false);
|
|
138536
138597
|
const [injectReason, setInjectReason] = useState161("");
|
|
138537
|
-
const chromeSessionRef =
|
|
138598
|
+
const chromeSessionRef = useRef80(sessionId);
|
|
138538
138599
|
const wsUrl = useConfigStore((s) => s.wsUrl);
|
|
138539
138600
|
const client2 = getWSClient(wsUrl);
|
|
138540
138601
|
const pendingTools = useChatStore((s) => s.messages).filter(
|
|
@@ -139356,7 +139417,7 @@ init_ws_client();
|
|
|
139356
139417
|
init_stores();
|
|
139357
139418
|
init_chat_lanes();
|
|
139358
139419
|
import { CheckCircle2 as CheckCircle236, Circle as Circle9, Clock as Clock22, Trash2 as Trash228 } from "lucide-react";
|
|
139359
|
-
import { useCallback as useCallback89, useEffect as useEffect149, useLayoutEffect as useLayoutEffect6, useRef as
|
|
139420
|
+
import { useCallback as useCallback89, useEffect as useEffect149, useLayoutEffect as useLayoutEffect6, useRef as useRef81, useState as useState164 } from "react";
|
|
139360
139421
|
import { jsx as jsx299, jsxs as jsxs287 } from "react/jsx-runtime";
|
|
139361
139422
|
var STATUS_ORDER = {
|
|
139362
139423
|
in_progress: 0,
|
|
@@ -139376,7 +139437,7 @@ function TodosPanel() {
|
|
|
139376
139437
|
const sessionId = useActiveSessionId();
|
|
139377
139438
|
const [collapsedSections, setCollapsedSections] = useState164(/* @__PURE__ */ new Set());
|
|
139378
139439
|
const ws = getWSClient();
|
|
139379
|
-
const collapsedSessionRef =
|
|
139440
|
+
const collapsedSessionRef = useRef81(sessionId ?? TODOS_PANEL_NO_SESSION);
|
|
139380
139441
|
useLayoutEffect6(() => {
|
|
139381
139442
|
if (!disposedTodosPanelSessions.has(collapsedSessionRef.current)) {
|
|
139382
139443
|
todosCollapsedBySession.set(collapsedSessionRef.current, new Set(collapsedSections));
|
|
@@ -139520,7 +139581,7 @@ init_ws_client();
|
|
|
139520
139581
|
init_stores();
|
|
139521
139582
|
init_chat_lanes();
|
|
139522
139583
|
import { CheckCircle2 as CheckCircle237, Circle as Circle10, Clock as Clock23, Pause as Pause9, RotateCcw as RotateCcw22, XCircle as XCircle16 } from "lucide-react";
|
|
139523
|
-
import { useCallback as useCallback90, useEffect as useEffect150, useLayoutEffect as useLayoutEffect7, useRef as
|
|
139584
|
+
import { useCallback as useCallback90, useEffect as useEffect150, useLayoutEffect as useLayoutEffect7, useRef as useRef82, useState as useState165 } from "react";
|
|
139524
139585
|
import { jsx as jsx300, jsxs as jsxs288 } from "react/jsx-runtime";
|
|
139525
139586
|
var STATUS_CONFIG2 = {
|
|
139526
139587
|
pending: {
|
|
@@ -139581,7 +139642,7 @@ function TasksPanel() {
|
|
|
139581
139642
|
const [collapsed, setCollapsed] = useState165(/* @__PURE__ */ new Set());
|
|
139582
139643
|
const ws = getWSClient();
|
|
139583
139644
|
const sessionId = useActiveSessionId();
|
|
139584
|
-
const collapsedSessionRef =
|
|
139645
|
+
const collapsedSessionRef = useRef82(sessionId ?? TASKS_PANEL_NO_SESSION);
|
|
139585
139646
|
useLayoutEffect7(() => {
|
|
139586
139647
|
if (!disposedTasksPanelSessions.has(collapsedSessionRef.current)) {
|
|
139587
139648
|
tasksCollapsedBySession.set(collapsedSessionRef.current, new Set(collapsed));
|
|
@@ -139757,7 +139818,7 @@ init_ws_client();
|
|
|
139757
139818
|
init_stores();
|
|
139758
139819
|
init_chat_lanes();
|
|
139759
139820
|
import { CheckCircle2 as CheckCircle238, Circle as Circle11, Clock as Clock24 } from "lucide-react";
|
|
139760
|
-
import { useCallback as useCallback91, useEffect as useEffect151, useLayoutEffect as useLayoutEffect8, useRef as
|
|
139821
|
+
import { useCallback as useCallback91, useEffect as useEffect151, useLayoutEffect as useLayoutEffect8, useRef as useRef83, useState as useState166 } from "react";
|
|
139761
139822
|
import { jsx as jsx301, jsxs as jsxs289 } from "react/jsx-runtime";
|
|
139762
139823
|
var STATUS_CONFIG3 = {
|
|
139763
139824
|
open: {
|
|
@@ -139789,7 +139850,7 @@ function PlanPanel() {
|
|
|
139789
139850
|
const [collapsed, setCollapsed] = useState166(/* @__PURE__ */ new Set());
|
|
139790
139851
|
const ws = getWSClient();
|
|
139791
139852
|
const sessionId = useActiveSessionId();
|
|
139792
|
-
const collapsedSessionRef =
|
|
139853
|
+
const collapsedSessionRef = useRef83(sessionId ?? PLAN_PANEL_NO_SESSION);
|
|
139793
139854
|
useLayoutEffect8(() => {
|
|
139794
139855
|
if (!disposedPlanPanelSessions.has(collapsedSessionRef.current)) {
|
|
139795
139856
|
planCollapsedBySession.set(collapsedSessionRef.current, new Set(collapsed));
|
|
@@ -140758,6 +140819,7 @@ function NotificationItem({
|
|
|
140758
140819
|
!item.read && /* @__PURE__ */ jsx307(
|
|
140759
140820
|
"span",
|
|
140760
140821
|
{
|
|
140822
|
+
role: "img",
|
|
140761
140823
|
className: "h-1.5 w-1.5 rounded-full bg-primary shrink-0",
|
|
140762
140824
|
"aria-label": "Unread indicator"
|
|
140763
140825
|
}
|