@wrongstack/webui 0.301.0 → 0.302.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/assets/{AgentRosterView-BV6ysoGs.js → AgentRosterView-PafACoYi.js} +1 -1
- package/dist/assets/{AnalyticsDashboard-UWNP8zjE.js → AnalyticsDashboard-D5lvkaiF.js} +1 -1
- package/dist/assets/{AudienceMemoryPanel-DwDKbvSA.js → AudienceMemoryPanel-DUXllPor.js} +1 -1
- package/dist/assets/{ChangesView-DuVlGWkD.js → ChangesView-CKLN6MLR.js} +1 -1
- package/dist/assets/{ChronicleDashboard-cs16n708.js → ChronicleDashboard-B8OyHq18.js} +1 -1
- package/dist/assets/{CodeEditor-sr50ljZN.js → CodeEditor-BtAkdKFs.js} +1 -1
- package/dist/assets/{CodeMap-CtK-C8gK.js → CodeMap-6L-z-L7d.js} +1 -1
- package/dist/assets/{ConfirmModal-ndS17YwF.js → ConfirmModal-B0BCqW4j.js} +1 -1
- package/dist/assets/{CronJobsPanel-Dovomns5.js → CronJobsPanel-B-rRYNgE.js} +1 -1
- package/dist/assets/{DeadCodeScanPanel-DjR4LLMs.js → DeadCodeScanPanel-CDbBO9Ic.js} +1 -1
- package/dist/assets/{DebugDashboard-jK1yp3qS.js → DebugDashboard-RAxaJDNV.js} +1 -1
- package/dist/assets/{DesignGalleryView-CqXlEUzE.js → DesignGalleryView-4kdGN1D5.js} +1 -1
- package/dist/assets/{GoalView-CGNLrnA4.js → GoalView-By18NfaK.js} +1 -1
- package/dist/assets/KanbanView-dyfUjpC5.js +3 -0
- package/dist/assets/{MailboxDetailView-0TBzZTdN.js → MailboxDetailView-BNyJNz-3.js} +1 -1
- package/dist/assets/{MemoryManager-CDK_MO8A.js → MemoryManager-BbZ-1pfr.js} +1 -1
- package/dist/assets/{ModelPicker-BbBZuQwR.js → ModelPicker-DwNrO_jw.js} +1 -1
- package/dist/assets/{OfficeMapPanel-68sVzHRD.js → OfficeMapPanel-Bo-cCLV7.js} +1 -1
- package/dist/assets/{ProcessMonitor-gFwiF8gX.js → ProcessMonitor-DPEMjjVq.js} +1 -1
- package/dist/assets/{QueuePanel-Cx-isRGl.js → QueuePanel-Dx9n4NZB.js} +1 -1
- package/dist/assets/{RefreshDebugView-C9tdu6Ld.js → RefreshDebugView-On6-vb92.js} +1 -1
- package/dist/assets/{RequirementIntakeView-cPEw-RpV.js → RequirementIntakeView-DpnZRVDz.js} +1 -1
- package/dist/assets/{SageTabs-BbK6VFO0.js → SageTabs-D5CzIKGe.js} +2 -2
- package/dist/assets/{SddHub-NKvDRECi.js → SddHub-BMedBDDs.js} +1 -1
- package/dist/assets/{SessionInspectView-DPG5qWhj.js → SessionInspectView-Crs1g_xM.js} +1 -1
- package/dist/assets/{SessionList-ncl-20X_.js → SessionList-SsEjoeJF.js} +1 -1
- package/dist/assets/{SessionsDashboard-D23UVLr4.js → SessionsDashboard-DYw9vuIv.js} +1 -1
- package/dist/assets/{SetupScreen-D3XQ8MGk.js → SetupScreen-Mr604Nx3.js} +1 -1
- package/dist/assets/{SkillDetailView-DDPhVFet.js → SkillDetailView-gt-Nm_ZI.js} +1 -1
- package/dist/assets/{SpecsView-afIS0QpX.js → SpecsView-CVVQSIZZ.js} +1 -1
- package/dist/assets/{TechStackView-kQ2OGxxw.js → TechStackView-BNen0ZpH.js} +1 -1
- package/dist/assets/{TerminalPanel-GcJWeldW.js → TerminalPanel-BByD75cu.js} +1 -1
- package/dist/assets/{Toaster-CgQA9256.js → Toaster-Cz-_rtgo.js} +1 -1
- package/dist/assets/{activity-DxDRJ8kN.js → activity-B0cam54R.js} +1 -1
- package/dist/assets/{activity-Ba3aMzvo.js → activity-B3FDXYFE.js} +1 -1
- package/dist/assets/{activity-DsSuflRW.js → activity-D7dMY0Jm.js} +1 -1
- package/dist/assets/{activity-VI776bUZ.js → activity-DXNwLcwn.js} +1 -1
- package/dist/assets/{activity-CRTVZ5A4.js → activity-DmdoxMAj.js} +1 -1
- package/dist/assets/{activity-B-cvKIfT.js → activity-IZoezahu.js} +1 -1
- package/dist/assets/{activity-nVmsmqAI.js → activity-jOHsoosT.js} +1 -1
- package/dist/assets/{i18n-COgumVF5.js → i18n-ags7mYPP.js} +2 -2
- package/dist/assets/index-Cw20Xg0d.css +1 -0
- package/dist/assets/{index-CtpViiZy.js → index-Doa2aJ1A.js} +4 -4
- package/dist/assets/{progress-ring-D_48qsBl.js → progress-ring-BxJsZCnD.js} +1 -1
- package/dist/assets/{stores-ChEnUmic.js → stores-Bz5nhi7q.js} +1 -1
- package/dist/assets/{useWebSocket-_gk4MRJz.js → useWebSocket-BHzEXXna.js} +1 -1
- package/dist/components/KanbanBoardState.d.ts +0 -1
- package/dist/components/KanbanTaskInspector.d.ts +1 -2
- package/dist/index.html +9 -9
- package/dist/index.js +646 -480
- package/dist/lib/kanban-cleaner.d.ts +7 -1
- package/package.json +8 -8
- package/dist/assets/KanbanView--tAf_K7N.js +0 -3
- package/dist/assets/index-fIsq43fR.css +0 -1
package/dist/index.js
CHANGED
|
@@ -2630,6 +2630,8 @@ var require_activity = __commonJS({
|
|
|
2630
2630
|
newColumn: "New column",
|
|
2631
2631
|
addColumn: "Add column",
|
|
2632
2632
|
duplicateBoard: "Duplicate board",
|
|
2633
|
+
confirmDelete: "Confirm?",
|
|
2634
|
+
confirmDeleteBoard: "Click again to confirm board deletion",
|
|
2633
2635
|
deleteBoard: "Delete board",
|
|
2634
2636
|
boardBoundary: "Board boundary",
|
|
2635
2637
|
noBoardSelected: "No kanban board selected.",
|
|
@@ -2656,6 +2658,9 @@ var require_activity = __commonJS({
|
|
|
2656
2658
|
actionReassign: "Reassign",
|
|
2657
2659
|
actionRunNow: "Run now",
|
|
2658
2660
|
deleteTaskAria: "Delete task: {{title}}",
|
|
2661
|
+
confirmDeleteTask: "Click again to confirm task deletion",
|
|
2662
|
+
confirmDeleteTaskAria: "Confirm delete: {{title}}",
|
|
2663
|
+
moveTaskToColumn: "Move {{title}} to column",
|
|
2659
2664
|
activityNoteTemplate: "{{action}} from WebUI to {{target}}."
|
|
2660
2665
|
},
|
|
2661
2666
|
cronJobs: {
|
|
@@ -7403,6 +7408,8 @@ var require_activity2 = __commonJS({
|
|
|
7403
7408
|
newColumn: "Neue Spalte",
|
|
7404
7409
|
addColumn: "Spalte hinzuf\xFCgen",
|
|
7405
7410
|
duplicateBoard: "Board duplizieren",
|
|
7411
|
+
confirmDelete: "Best\xE4tigen?",
|
|
7412
|
+
confirmDeleteBoard: "Erneut klicken, um das L\xF6schen des Boards zu best\xE4tigen",
|
|
7406
7413
|
deleteBoard: "Board l\xF6schen",
|
|
7407
7414
|
boardBoundary: "Board-Grenze",
|
|
7408
7415
|
noBoardSelected: "Kein Kanban-Board ausgew\xE4hlt.",
|
|
@@ -7429,6 +7436,9 @@ var require_activity2 = __commonJS({
|
|
|
7429
7436
|
actionReassign: "Neu zuweisen",
|
|
7430
7437
|
actionRunNow: "Jetzt ausf\xFChren",
|
|
7431
7438
|
deleteTaskAria: "Task l\xF6schen: {{title}}",
|
|
7439
|
+
confirmDeleteTask: "Erneut klicken, um das L\xF6schen der Aufgabe zu best\xE4tigen",
|
|
7440
|
+
confirmDeleteTaskAria: "L\xF6schen best\xE4tigen: {{title}}",
|
|
7441
|
+
moveTaskToColumn: "{{title}} in Spalte verschieben",
|
|
7432
7442
|
activityNoteTemplate: "{{action}} von WebUI an {{target}}."
|
|
7433
7443
|
},
|
|
7434
7444
|
cronJobs: {
|
|
@@ -12176,6 +12186,8 @@ var require_activity3 = __commonJS({
|
|
|
12176
12186
|
newColumn: "Nueva columna",
|
|
12177
12187
|
addColumn: "Agregar columna",
|
|
12178
12188
|
duplicateBoard: "Duplicar tablero",
|
|
12189
|
+
confirmDelete: "\xBFConfirmar?",
|
|
12190
|
+
confirmDeleteBoard: "Haz clic de nuevo para confirmar la eliminaci\xF3n del tablero",
|
|
12179
12191
|
deleteBoard: "Eliminar tablero",
|
|
12180
12192
|
boardBoundary: "L\xEDmite del tablero",
|
|
12181
12193
|
noBoardSelected: "No hay ning\xFAn tablero Kanban seleccionado.",
|
|
@@ -12202,6 +12214,9 @@ var require_activity3 = __commonJS({
|
|
|
12202
12214
|
actionReassign: "Reasignar",
|
|
12203
12215
|
actionRunNow: "Ejecutar ahora",
|
|
12204
12216
|
deleteTaskAria: "Eliminar tarea: {{title}}",
|
|
12217
|
+
confirmDeleteTask: "Haz clic de nuevo para confirmar la eliminaci\xF3n de la tarea",
|
|
12218
|
+
confirmDeleteTaskAria: "Confirmar eliminaci\xF3n: {{title}}",
|
|
12219
|
+
moveTaskToColumn: "Mover {{title}} a la columna",
|
|
12205
12220
|
activityNoteTemplate: "{{action}} de WebUI a {{target}}."
|
|
12206
12221
|
},
|
|
12207
12222
|
cronJobs: {
|
|
@@ -16950,6 +16965,8 @@ D\xE9clencheurs : l'utilisateur dit "mot-cl\xE9", "autre".`,
|
|
|
16950
16965
|
newColumn: "Nouvelle colonne",
|
|
16951
16966
|
addColumn: "Ajouter une colonne",
|
|
16952
16967
|
duplicateBoard: "Dupliquer le tableau",
|
|
16968
|
+
confirmDelete: "Confirmer ?",
|
|
16969
|
+
confirmDeleteBoard: "Cliquez \xE0 nouveau pour confirmer la suppression du tableau",
|
|
16953
16970
|
deleteBoard: "Supprimer le tableau",
|
|
16954
16971
|
boardBoundary: "Limite du tableau",
|
|
16955
16972
|
noBoardSelected: "Aucun tableau Kanban s\xE9lectionn\xE9.",
|
|
@@ -16976,6 +16993,9 @@ D\xE9clencheurs : l'utilisateur dit "mot-cl\xE9", "autre".`,
|
|
|
16976
16993
|
actionReassign: "R\xE9affecter",
|
|
16977
16994
|
actionRunNow: "Ex\xE9cuter maintenant",
|
|
16978
16995
|
deleteTaskAria: "Supprimer la t\xE2che : {{title}}",
|
|
16996
|
+
confirmDeleteTask: "Cliquez \xE0 nouveau pour confirmer la suppression de la t\xE2che",
|
|
16997
|
+
confirmDeleteTaskAria: "Confirmer la suppression : {{title}}",
|
|
16998
|
+
moveTaskToColumn: "D\xE9placer {{title}} vers la colonne",
|
|
16979
16999
|
activityNoteTemplate: "{{action}} de WebUI vers {{target}}."
|
|
16980
17000
|
},
|
|
16981
17001
|
cronJobs: {
|
|
@@ -21724,6 +21744,8 @@ Trigger: l'utente dice "parola chiave", "altra".`,
|
|
|
21724
21744
|
newColumn: "Nuova colonna",
|
|
21725
21745
|
addColumn: "Aggiungi colonna",
|
|
21726
21746
|
duplicateBoard: "Duplica board",
|
|
21747
|
+
confirmDelete: "Confermare?",
|
|
21748
|
+
confirmDeleteBoard: "Clicca di nuovo per confermare l'eliminazione della board",
|
|
21727
21749
|
deleteBoard: "Elimina board",
|
|
21728
21750
|
boardBoundary: "Board boundary",
|
|
21729
21751
|
noBoardSelected: "Nessuna board kanban selezionata.",
|
|
@@ -21750,6 +21772,9 @@ Trigger: l'utente dice "parola chiave", "altra".`,
|
|
|
21750
21772
|
actionReassign: "Riassegna",
|
|
21751
21773
|
actionRunNow: "Esegui ora",
|
|
21752
21774
|
deleteTaskAria: "Elimina task: {{title}}",
|
|
21775
|
+
confirmDeleteTask: "Clicca di nuovo per confermare l'eliminazione del task",
|
|
21776
|
+
confirmDeleteTaskAria: "Conferma eliminazione: {{title}}",
|
|
21777
|
+
moveTaskToColumn: "Sposta {{title}} nella colonna",
|
|
21753
21778
|
activityNoteTemplate: "{{action}} da WebUI a {{target}}."
|
|
21754
21779
|
},
|
|
21755
21780
|
cronJobs: {
|
|
@@ -26497,6 +26522,8 @@ var require_activity6 = __commonJS({
|
|
|
26497
26522
|
newColumn: "Nova coluna",
|
|
26498
26523
|
addColumn: "Adicionar coluna",
|
|
26499
26524
|
duplicateBoard: "Duplicar quadro",
|
|
26525
|
+
confirmDelete: "Confirmar?",
|
|
26526
|
+
confirmDeleteBoard: "Clique novamente para confirmar a exclus\xE3o do quadro",
|
|
26500
26527
|
deleteBoard: "Excluir quadro",
|
|
26501
26528
|
boardBoundary: "Limite do quadro",
|
|
26502
26529
|
noBoardSelected: "Nenhum quadro kanban selecionado.",
|
|
@@ -26523,6 +26550,9 @@ var require_activity6 = __commonJS({
|
|
|
26523
26550
|
actionReassign: "Reatribuir",
|
|
26524
26551
|
actionRunNow: "Executar agora",
|
|
26525
26552
|
deleteTaskAria: "Excluir tarefa: {{title}}",
|
|
26553
|
+
confirmDeleteTask: "Clique novamente para confirmar a exclus\xE3o da tarefa",
|
|
26554
|
+
confirmDeleteTaskAria: "Confirmar exclus\xE3o: {{title}}",
|
|
26555
|
+
moveTaskToColumn: "Mover {{title}} para a coluna",
|
|
26526
26556
|
activityNoteTemplate: "{{action}} do WebUI para {{target}}."
|
|
26527
26557
|
},
|
|
26528
26558
|
cronJobs: {
|
|
@@ -31270,6 +31300,8 @@ var require_activity7 = __commonJS({
|
|
|
31270
31300
|
newColumn: "Yeni s\xFCtun",
|
|
31271
31301
|
addColumn: "S\xFCtun ekle",
|
|
31272
31302
|
duplicateBoard: "Panoyu \xE7o\u011Falt",
|
|
31303
|
+
confirmDelete: "Emin misiniz?",
|
|
31304
|
+
confirmDeleteBoard: "Panoyu silmeyi onaylamak i\xE7in tekrar t\u0131klay\u0131n",
|
|
31273
31305
|
deleteBoard: "Panoyu sil",
|
|
31274
31306
|
boardBoundary: "Pano s\u0131n\u0131r\u0131",
|
|
31275
31307
|
noBoardSelected: "Kanban panosu se\xE7ilmedi.",
|
|
@@ -31296,6 +31328,9 @@ var require_activity7 = __commonJS({
|
|
|
31296
31328
|
actionReassign: "Yeniden ata",
|
|
31297
31329
|
actionRunNow: "\u015Eimdi \xE7al\u0131\u015Ft\u0131r",
|
|
31298
31330
|
deleteTaskAria: "G\xF6revi sil: {{title}}",
|
|
31331
|
+
confirmDeleteTask: "G\xF6revi silmeyi onaylamak i\xE7in tekrar t\u0131klay\u0131n",
|
|
31332
|
+
confirmDeleteTaskAria: "Silmeyi onayla: {{title}}",
|
|
31333
|
+
moveTaskToColumn: "{{title}} s\xFCtununa ta\u015F\u0131",
|
|
31299
31334
|
activityNoteTemplate: "{{action}} WebUI'dan {{target}} adresine."
|
|
31300
31335
|
},
|
|
31301
31336
|
cronJobs: {
|
|
@@ -57301,7 +57336,6 @@ var init_useHorizontalScroll = __esm({
|
|
|
57301
57336
|
function auditKanbanBoard(board, options) {
|
|
57302
57337
|
const now = toEpoch(options.now);
|
|
57303
57338
|
if (now === null) throw new TypeError("Kanban audit requires a valid current time");
|
|
57304
|
-
const liveIdentities = normalizeIdentities(options.liveAgentIdentities);
|
|
57305
57339
|
const reviewStaleAfterMs = resolveReviewStaleAfterMs(
|
|
57306
57340
|
board,
|
|
57307
57341
|
options.defaultReviewStaleAfterMs ?? DEFAULT_REVIEW_STALE_AFTER_MS
|
|
@@ -57311,7 +57345,7 @@ function auditKanbanBoard(board, options) {
|
|
|
57311
57345
|
for (const task of board.tasks) {
|
|
57312
57346
|
if (TERMINAL_STATUSES.has(task.status)) continue;
|
|
57313
57347
|
addRequiredDetailIssues(issues, task, options.requireDueDate === true);
|
|
57314
|
-
addRunningIssue(issues, task, now
|
|
57348
|
+
addRunningIssue(issues, task, now);
|
|
57315
57349
|
addReviewIssue(issues, task, now, reviewStaleAfterMs);
|
|
57316
57350
|
if (lifecycleOrder.length > 1) addLifecycleIssue(issues, task, lifecycleOrder);
|
|
57317
57351
|
}
|
|
@@ -57332,7 +57366,7 @@ function addRequiredDetailIssues(issues, task, requireDueDate) {
|
|
|
57332
57366
|
if (assignmentIdentities(task).length === 0) {
|
|
57333
57367
|
pushIssue(issues, task, "missing-assignee", "warning", "Assign an owner");
|
|
57334
57368
|
}
|
|
57335
|
-
if (requireDueDate &&
|
|
57369
|
+
if (requireDueDate && toEpoch(task.dueDate) === null) {
|
|
57336
57370
|
pushIssue(issues, task, "missing-due-date", "warning", "Set a due date");
|
|
57337
57371
|
}
|
|
57338
57372
|
if (!hasItems(task.labels) && !hasItems(task.tags)) {
|
|
@@ -57345,7 +57379,7 @@ function addRequiredDetailIssues(issues, task, requireDueDate) {
|
|
|
57345
57379
|
pushIssue(issues, task, "missing-success-criteria", "warning", "Add success criteria");
|
|
57346
57380
|
}
|
|
57347
57381
|
}
|
|
57348
|
-
function addRunningIssue(issues, task, now
|
|
57382
|
+
function addRunningIssue(issues, task, now) {
|
|
57349
57383
|
const assignment = task.assignment;
|
|
57350
57384
|
const running = task.status === "in_progress" || assignment?.status === "running";
|
|
57351
57385
|
if (!running) return;
|
|
@@ -57365,9 +57399,6 @@ function addRunningIssue(issues, task, now, liveIdentities) {
|
|
|
57365
57399
|
pushIssue(issues, task, "stale-running-task", "error", "Assignment lease is expired");
|
|
57366
57400
|
return;
|
|
57367
57401
|
}
|
|
57368
|
-
if (!identities.some((identity) => liveIdentities.has(normalizeIdentity(identity)))) {
|
|
57369
|
-
pushIssue(issues, task, "abandoned-running-task", "error", "Assigned agent is not live");
|
|
57370
|
-
}
|
|
57371
57402
|
}
|
|
57372
57403
|
function addReviewIssue(issues, task, now, staleAfterMs) {
|
|
57373
57404
|
if (task.status !== "review") return;
|
|
@@ -57479,16 +57510,8 @@ function readStringList(value) {
|
|
|
57479
57510
|
}
|
|
57480
57511
|
return result;
|
|
57481
57512
|
}
|
|
57482
|
-
function
|
|
57483
|
-
|
|
57484
|
-
if (!values) return normalized;
|
|
57485
|
-
for (const value of values) {
|
|
57486
|
-
if (hasText(value)) normalized.add(normalizeIdentity(value));
|
|
57487
|
-
}
|
|
57488
|
-
return normalized;
|
|
57489
|
-
}
|
|
57490
|
-
function normalizeIdentity(value) {
|
|
57491
|
-
return value.trim().toLocaleLowerCase();
|
|
57513
|
+
function normalizeIdentity(identity) {
|
|
57514
|
+
return identity.trim().toLowerCase();
|
|
57492
57515
|
}
|
|
57493
57516
|
function firstText(...values) {
|
|
57494
57517
|
for (const value of values) {
|
|
@@ -58019,15 +58042,6 @@ var init_KanbanBoardChrome = __esm({
|
|
|
58019
58042
|
});
|
|
58020
58043
|
|
|
58021
58044
|
// src/components/KanbanBoardState.ts
|
|
58022
|
-
function collectLiveAgentIdentities(agents) {
|
|
58023
|
-
const identities = /* @__PURE__ */ new Set();
|
|
58024
|
-
for (const agent of agents) {
|
|
58025
|
-
if (agent.status !== "running") continue;
|
|
58026
|
-
identities.add(agent.id);
|
|
58027
|
-
identities.add(agent.name);
|
|
58028
|
-
}
|
|
58029
|
-
return identities;
|
|
58030
|
-
}
|
|
58031
58045
|
function collectActiveSessionIds(input) {
|
|
58032
58046
|
const ids = /* @__PURE__ */ new Set();
|
|
58033
58047
|
if (input.sessionId) ids.add(input.sessionId);
|
|
@@ -58402,7 +58416,7 @@ var init_KanbanBoundaryEditor = __esm({
|
|
|
58402
58416
|
|
|
58403
58417
|
// src/components/KanbanCleanerAlert.tsx
|
|
58404
58418
|
import { AlertTriangle as AlertTriangle19, ChevronDown as ChevronDown25, CircleAlert, Sparkles as Sparkles13 } from "lucide-react";
|
|
58405
|
-
import { useEffect as useEffect99, useId as useId3, useState as useState105 } from "react";
|
|
58419
|
+
import { useEffect as useEffect99, useId as useId3, useRef as useRef49, useState as useState105 } from "react";
|
|
58406
58420
|
import { jsx as jsx172, jsxs as jsxs163 } from "react/jsx-runtime";
|
|
58407
58421
|
function KanbanCleanerAlert({
|
|
58408
58422
|
audit,
|
|
@@ -58410,9 +58424,14 @@ function KanbanCleanerAlert({
|
|
|
58410
58424
|
}) {
|
|
58411
58425
|
const [expanded, setExpanded] = useState105(true);
|
|
58412
58426
|
const contentId = useId3();
|
|
58427
|
+
const seenIssueIdsRef = useRef49(null);
|
|
58413
58428
|
useEffect99(() => {
|
|
58414
|
-
|
|
58415
|
-
|
|
58429
|
+
const ids = new Set(audit.issues.map((issue) => issue.id));
|
|
58430
|
+
const previous = seenIssueIdsRef.current;
|
|
58431
|
+
seenIssueIdsRef.current = ids;
|
|
58432
|
+
if (previous === null) return;
|
|
58433
|
+
if ([...ids].some((id) => !previous.has(id))) setExpanded(true);
|
|
58434
|
+
}, [audit.issues]);
|
|
58416
58435
|
if (audit.issues.length === 0) return null;
|
|
58417
58436
|
const grouped = groupByTask(audit.issues);
|
|
58418
58437
|
return /* @__PURE__ */ jsxs163(
|
|
@@ -59728,6 +59747,7 @@ var init_TaskRiskPanel = __esm({
|
|
|
59728
59747
|
|
|
59729
59748
|
// src/components/KanbanColumnView.tsx
|
|
59730
59749
|
import { Trash2 as Trash216 } from "lucide-react";
|
|
59750
|
+
import { useEffect as useEffect101, useRef as useRef50, useState as useState107 } from "react";
|
|
59731
59751
|
import { jsx as jsx177, jsxs as jsxs168 } from "react/jsx-runtime";
|
|
59732
59752
|
function deriveTaskCardIntelligence(board, task, verificationActivity) {
|
|
59733
59753
|
const assignment = task.assignment;
|
|
@@ -59765,6 +59785,47 @@ function deriveTaskCardIntelligence(board, task, verificationActivity) {
|
|
|
59765
59785
|
pendingDecomposition: task.decomposition?.status === "proposed"
|
|
59766
59786
|
};
|
|
59767
59787
|
}
|
|
59788
|
+
function boardIntelligenceSignature(board) {
|
|
59789
|
+
const tasks = board.tasks.map((candidate) => `${candidate.id}:${candidate.status}`).sort().join("|");
|
|
59790
|
+
const presence = (board.presence ?? []).filter((entry) => entry.active).map((entry) => entry.taskId).sort().join("|");
|
|
59791
|
+
return `${board.id}|${tasks}|${presence}`;
|
|
59792
|
+
}
|
|
59793
|
+
function taskIntelligenceKey(task) {
|
|
59794
|
+
const assignment = task.assignment;
|
|
59795
|
+
return [
|
|
59796
|
+
task.id,
|
|
59797
|
+
task.status,
|
|
59798
|
+
task.dueDate ?? "",
|
|
59799
|
+
task.assignee ?? "",
|
|
59800
|
+
task.assignedAgent ?? "",
|
|
59801
|
+
JSON.stringify(task.dependsOn ?? null),
|
|
59802
|
+
JSON.stringify(task.childTaskIds ?? null),
|
|
59803
|
+
JSON.stringify(
|
|
59804
|
+
(task.successCriteria ?? []).map((check) => `${check.id}:${check.status}`)
|
|
59805
|
+
),
|
|
59806
|
+
task.atomicityAssessment?.verdict ?? "",
|
|
59807
|
+
task.verificationReport?.attachments.length ?? 0,
|
|
59808
|
+
task.decomposition?.status ?? "",
|
|
59809
|
+
assignment ? JSON.stringify({
|
|
59810
|
+
provider: assignment.provider,
|
|
59811
|
+
model: assignment.model,
|
|
59812
|
+
name: assignment.name,
|
|
59813
|
+
agentId: assignment.agentId,
|
|
59814
|
+
role: assignment.role,
|
|
59815
|
+
attempt: assignment.attempt,
|
|
59816
|
+
maxAttempts: assignment.maxAttempts,
|
|
59817
|
+
fallbackProfile: assignment.fallbackProfile,
|
|
59818
|
+
fallbackModels: assignment.fallbackModels,
|
|
59819
|
+
status: assignment.status,
|
|
59820
|
+
error: assignment.error,
|
|
59821
|
+
lastFailureKind: assignment.lastFailureKind,
|
|
59822
|
+
lastResult: assignment.lastResult,
|
|
59823
|
+
leaseExpiresAt: assignment.leaseExpiresAt,
|
|
59824
|
+
heartbeatAt: assignment.heartbeatAt,
|
|
59825
|
+
modelRouting: assignment.modelRouting
|
|
59826
|
+
}) : ""
|
|
59827
|
+
].join(":");
|
|
59828
|
+
}
|
|
59768
59829
|
function KanbanColumnView({
|
|
59769
59830
|
board,
|
|
59770
59831
|
column,
|
|
@@ -59777,13 +59838,50 @@ function KanbanColumnView({
|
|
|
59777
59838
|
}) {
|
|
59778
59839
|
const { t } = useTranslation();
|
|
59779
59840
|
const verificationActivity = useKanbanStore((state) => state.verificationActivity);
|
|
59841
|
+
const [dragOver, setDragOver] = useState107(false);
|
|
59842
|
+
const dragDepthRef = useRef50(0);
|
|
59843
|
+
const [pendingDeleteTaskId, setPendingDeleteTaskId] = useState107(null);
|
|
59844
|
+
useEffect101(() => {
|
|
59845
|
+
if (dragTaskId === null) {
|
|
59846
|
+
dragDepthRef.current = 0;
|
|
59847
|
+
setDragOver(false);
|
|
59848
|
+
}
|
|
59849
|
+
}, [dragTaskId]);
|
|
59850
|
+
useEffect101(() => {
|
|
59851
|
+
if (pendingDeleteTaskId === null) return;
|
|
59852
|
+
const timer = window.setTimeout(() => setPendingDeleteTaskId(null), 4e3);
|
|
59853
|
+
return () => window.clearTimeout(timer);
|
|
59854
|
+
}, [pendingDeleteTaskId]);
|
|
59855
|
+
const intelligenceCacheRef = useRef50(/* @__PURE__ */ new Map());
|
|
59856
|
+
const boardSignature = boardIntelligenceSignature(board);
|
|
59857
|
+
const timeBucket = Math.floor(Date.now() / 6e4);
|
|
59858
|
+
useEffect101(() => {
|
|
59859
|
+
intelligenceCacheRef.current.clear();
|
|
59860
|
+
}, [boardSignature, timeBucket]);
|
|
59780
59861
|
const tasks = board.tasks.filter((task) => task.columnId === column.id).sort((a, b) => a.order - b.order);
|
|
59781
59862
|
const empty = tasks.length === 0;
|
|
59863
|
+
const cachedCardIntelligence = (task) => {
|
|
59864
|
+
const cache = intelligenceCacheRef.current;
|
|
59865
|
+
const key = `${boardSignature}|${timeBucket}|${taskIntelligenceKey(task)}`;
|
|
59866
|
+
const cached = cache.get(key);
|
|
59867
|
+
if (cached) {
|
|
59868
|
+
const activity = verificationActivity?.[`${board.id}:${task.id}`];
|
|
59869
|
+
const freshVerification = verificationStateOf(task, activity);
|
|
59870
|
+
if (freshVerification === cached.verification) return cached;
|
|
59871
|
+
const merged = { ...cached, verification: freshVerification };
|
|
59872
|
+
cache.set(key, merged);
|
|
59873
|
+
return merged;
|
|
59874
|
+
}
|
|
59875
|
+
const intelligence = deriveTaskCardIntelligence(board, task, verificationActivity);
|
|
59876
|
+
cache.set(key, intelligence);
|
|
59877
|
+
return intelligence;
|
|
59878
|
+
};
|
|
59782
59879
|
return /* @__PURE__ */ jsxs168(
|
|
59783
59880
|
"section",
|
|
59784
59881
|
{
|
|
59785
59882
|
className: cn(
|
|
59786
59883
|
"flex h-full shrink-0 flex-col rounded-md border bg-muted/25 transition-[width] duration-200",
|
|
59884
|
+
dragOver && "border-primary/70 bg-primary/5",
|
|
59787
59885
|
empty ? "w-[180px]" : "w-[310px]"
|
|
59788
59886
|
),
|
|
59789
59887
|
children: [
|
|
@@ -59802,22 +59900,44 @@ function KanbanColumnView({
|
|
|
59802
59900
|
"ul",
|
|
59803
59901
|
{
|
|
59804
59902
|
className: "min-h-0 flex-1 space-y-2 overflow-y-auto p-2 [scrollbar-gutter:stable]",
|
|
59805
|
-
|
|
59903
|
+
onDragEnter: (event) => {
|
|
59904
|
+
event.preventDefault();
|
|
59905
|
+
dragDepthRef.current += 1;
|
|
59906
|
+
setDragOver(true);
|
|
59907
|
+
},
|
|
59908
|
+
onDragLeave: () => {
|
|
59909
|
+
dragDepthRef.current = Math.max(0, dragDepthRef.current - 1);
|
|
59910
|
+
if (dragDepthRef.current === 0) setDragOver(false);
|
|
59911
|
+
},
|
|
59912
|
+
onDragOver: (event) => {
|
|
59913
|
+
event.preventDefault();
|
|
59914
|
+
if (!dragOver) setDragOver(true);
|
|
59915
|
+
},
|
|
59806
59916
|
onDrop: (event) => {
|
|
59807
59917
|
event.preventDefault();
|
|
59808
|
-
|
|
59809
|
-
|
|
59918
|
+
dragDepthRef.current = 0;
|
|
59919
|
+
setDragOver(false);
|
|
59920
|
+
if (board.lifecycle?.mode === "managed") {
|
|
59921
|
+
setDragTaskId(null);
|
|
59922
|
+
return;
|
|
59923
|
+
}
|
|
59924
|
+
const droppedTaskId = event.dataTransfer.getData("text/plain") || dragTaskId;
|
|
59925
|
+
if (droppedTaskId && board.tasks.some((candidate) => candidate.id === droppedTaskId)) {
|
|
59926
|
+
onMoveTask(droppedTaskId, column.id);
|
|
59810
59927
|
}
|
|
59811
59928
|
setDragTaskId(null);
|
|
59812
59929
|
},
|
|
59813
59930
|
children: tasks.map((task) => {
|
|
59814
|
-
const intelligence =
|
|
59931
|
+
const intelligence = cachedCardIntelligence(task);
|
|
59815
59932
|
return /* @__PURE__ */ jsxs168(
|
|
59816
59933
|
"li",
|
|
59817
59934
|
{
|
|
59818
59935
|
draggable: board.lifecycle?.mode !== "managed",
|
|
59819
|
-
onDragStart: () => {
|
|
59820
|
-
if (board.lifecycle?.mode
|
|
59936
|
+
onDragStart: (event) => {
|
|
59937
|
+
if (board.lifecycle?.mode === "managed") return;
|
|
59938
|
+
setDragTaskId(task.id);
|
|
59939
|
+
event.dataTransfer.effectAllowed = "move";
|
|
59940
|
+
event.dataTransfer.setData("text/plain", task.id);
|
|
59821
59941
|
},
|
|
59822
59942
|
onDragEnd: () => setDragTaskId(null),
|
|
59823
59943
|
className: cn(
|
|
@@ -59856,15 +59976,40 @@ function KanbanColumnView({
|
|
|
59856
59976
|
"button",
|
|
59857
59977
|
{
|
|
59858
59978
|
type: "button",
|
|
59859
|
-
title: t("activity:kanban.deleteTask"),
|
|
59860
|
-
"aria-label": t("activity:kanban.deleteTaskAria", { title: task.title }),
|
|
59861
|
-
onClick: () =>
|
|
59862
|
-
|
|
59979
|
+
title: pendingDeleteTaskId === task.id ? t("activity:kanban.confirmDeleteTask") : t("activity:kanban.deleteTask"),
|
|
59980
|
+
"aria-label": pendingDeleteTaskId === task.id ? t("activity:kanban.confirmDeleteTaskAria", { title: task.title }) : t("activity:kanban.deleteTaskAria", { title: task.title }),
|
|
59981
|
+
onClick: () => {
|
|
59982
|
+
if (pendingDeleteTaskId === task.id) {
|
|
59983
|
+
setPendingDeleteTaskId(null);
|
|
59984
|
+
onDeleteTask(task);
|
|
59985
|
+
} else {
|
|
59986
|
+
setPendingDeleteTaskId(task.id);
|
|
59987
|
+
}
|
|
59988
|
+
},
|
|
59989
|
+
onBlur: () => setPendingDeleteTaskId((value) => value === task.id ? null : value),
|
|
59990
|
+
className: cn(
|
|
59991
|
+
"pointer-events-auto relative flex h-7 w-7 shrink-0 items-center justify-center rounded-md transition-colors",
|
|
59992
|
+
pendingDeleteTaskId === task.id ? "bg-destructive/15 text-destructive ring-1 ring-destructive/40" : "text-muted-foreground hover:bg-destructive/10 hover:text-destructive"
|
|
59993
|
+
),
|
|
59863
59994
|
children: /* @__PURE__ */ jsx177(Trash216, { size: 14 })
|
|
59864
59995
|
}
|
|
59865
59996
|
)
|
|
59866
59997
|
] }),
|
|
59867
59998
|
/* @__PURE__ */ jsxs168("div", { className: "pointer-events-none relative mt-2 flex flex-wrap items-center gap-1.5 text-[11px]", children: [
|
|
59999
|
+
board.lifecycle?.mode !== "managed" && /* @__PURE__ */ jsx177(
|
|
60000
|
+
"select",
|
|
60001
|
+
{
|
|
60002
|
+
"aria-label": t("activity:kanban.moveTaskToColumn", { title: task.title }),
|
|
60003
|
+
value: task.columnId,
|
|
60004
|
+
draggable: false,
|
|
60005
|
+
onDragStart: (event) => event.stopPropagation(),
|
|
60006
|
+
onChange: (event) => {
|
|
60007
|
+
if (event.target.value !== task.columnId) onMoveTask(task.id, event.target.value);
|
|
60008
|
+
},
|
|
60009
|
+
className: "pointer-events-auto relative max-w-28 cursor-pointer rounded bg-muted px-1.5 py-0.5 text-[11px] text-muted-foreground outline-none hover:text-foreground focus-visible:ring-2 focus-visible:ring-primary",
|
|
60010
|
+
children: board.columns.map((columnOption) => /* @__PURE__ */ jsx177("option", { value: columnOption.id, children: columnOption.title }, columnOption.id))
|
|
60011
|
+
}
|
|
60012
|
+
),
|
|
59868
60013
|
/* @__PURE__ */ jsx177("span", { className: priorityClass(task.priority), children: task.priority }),
|
|
59869
60014
|
/* @__PURE__ */ jsx177("span", { className: "rounded bg-muted px-1.5 py-0.5 text-muted-foreground", children: task.status }),
|
|
59870
60015
|
intelligence.owner !== "Unassigned" && /* @__PURE__ */ jsx177("span", { className: "rounded bg-primary/10 px-1.5 py-0.5 text-primary", children: intelligence.owner }),
|
|
@@ -60026,7 +60171,7 @@ var init_KanbanQueueHealthBar = __esm({
|
|
|
60026
60171
|
|
|
60027
60172
|
// src/components/KanbanRunControls.tsx
|
|
60028
60173
|
import { Check as Check26, Pause as Pause8, Play as Play7, Rocket as Rocket5, RotateCcw as RotateCcw13, Square as Square6, UserPlus as UserPlus2, X as X36 } from "lucide-react";
|
|
60029
|
-
import { useState as
|
|
60174
|
+
import { useState as useState108 } from "react";
|
|
60030
60175
|
import { jsx as jsx179, jsxs as jsxs170 } from "react/jsx-runtime";
|
|
60031
60176
|
function RunControlBar({
|
|
60032
60177
|
runLink,
|
|
@@ -60138,8 +60283,8 @@ function RunTaskControls({
|
|
|
60138
60283
|
}) {
|
|
60139
60284
|
const { t } = useTranslation();
|
|
60140
60285
|
const isSdd = runLink.engine === "sdd";
|
|
60141
|
-
const [reassigning, setReassigning] =
|
|
60142
|
-
const [reassignName, setReassignName] =
|
|
60286
|
+
const [reassigning, setReassigning] = useState108(false);
|
|
60287
|
+
const [reassignName, setReassignName] = useState108("");
|
|
60143
60288
|
const sendRun = (type, payload = {}) => sendRaw(type, runLink.runId ? { runId: runLink.runId, ...payload } : payload);
|
|
60144
60289
|
const btn = "inline-flex flex-1 items-center justify-center gap-1 rounded-md border py-1.5 text-xs font-medium hover:bg-muted";
|
|
60145
60290
|
const submitReassign = () => {
|
|
@@ -60282,7 +60427,7 @@ function KanbanTaskTree({
|
|
|
60282
60427
|
}) {
|
|
60283
60428
|
const { t } = useTranslation();
|
|
60284
60429
|
const verificationActivity = useKanbanStore((state) => state.verificationActivity);
|
|
60285
|
-
const rows = useMemo54(() => flattenTaskTree(buildTaskTree(board)), [board]);
|
|
60430
|
+
const rows = useMemo54(() => flattenTaskTree(buildTaskTree(board)), [board.id, board.revision]);
|
|
60286
60431
|
if (!rows.length) {
|
|
60287
60432
|
return /* @__PURE__ */ jsx180("div", { className: "flex h-full items-center justify-center text-sm text-muted-foreground", children: t("activity:kanbanTree.noTasksOnThisBoardYet") });
|
|
60288
60433
|
}
|
|
@@ -60471,7 +60616,7 @@ function KanbanVerificationDashboard({
|
|
|
60471
60616
|
onSelectTask
|
|
60472
60617
|
}) {
|
|
60473
60618
|
const { t } = useTranslation();
|
|
60474
|
-
const summary = useMemo55(() => selectVerificationSummary(board), [board]);
|
|
60619
|
+
const summary = useMemo55(() => selectVerificationSummary(board), [board.id, board.revision]);
|
|
60475
60620
|
const verifiedPct = summary.gradedTasks ? summary.passed / summary.gradedTasks * 100 : 0;
|
|
60476
60621
|
return /* @__PURE__ */ jsxs173("div", { className: "h-full space-y-4 overflow-y-auto p-4", children: [
|
|
60477
60622
|
/* @__PURE__ */ jsxs173("div", { className: "flex items-center gap-4 rounded-md border bg-background p-4", children: [
|
|
@@ -60882,7 +61027,7 @@ var init_KanbanTaskOptions = __esm({
|
|
|
60882
61027
|
|
|
60883
61028
|
// src/components/TaskActivityTimeline.tsx
|
|
60884
61029
|
import { Activity as Activity17, Check as Check29, Copy as Copy6, Download as Download7, RefreshCw as RefreshCw20, Search as Search18, X as X38 } from "lucide-react";
|
|
60885
|
-
import { useMemo as useMemo56, useState as
|
|
61030
|
+
import { useMemo as useMemo56, useState as useState109 } from "react";
|
|
60886
61031
|
import { Fragment as Fragment43, jsx as jsx186, jsxs as jsxs177 } from "react/jsx-runtime";
|
|
60887
61032
|
function buildTaskActivityExport(task, events, scope, exportedAt = (/* @__PURE__ */ new Date()).toISOString()) {
|
|
60888
61033
|
return {
|
|
@@ -61192,9 +61337,9 @@ function TaskActivityTimeline({
|
|
|
61192
61337
|
onRefresh
|
|
61193
61338
|
}) {
|
|
61194
61339
|
const { t } = useTranslation();
|
|
61195
|
-
const [filter, setFilter] =
|
|
61196
|
-
const [query, setQuery] =
|
|
61197
|
-
const [copied, setCopied] =
|
|
61340
|
+
const [filter, setFilter] = useState109("all");
|
|
61341
|
+
const [query, setQuery] = useState109("");
|
|
61342
|
+
const [copied, setCopied] = useState109(false);
|
|
61198
61343
|
const activity = useMemo56(
|
|
61199
61344
|
() => buildTaskActivity(task, events, sessionId),
|
|
61200
61345
|
[task, events, sessionId]
|
|
@@ -62083,7 +62228,7 @@ import {
|
|
|
62083
62228
|
ShieldAlert as ShieldAlert6,
|
|
62084
62229
|
XCircle as XCircle9
|
|
62085
62230
|
} from "lucide-react";
|
|
62086
|
-
import { useState as
|
|
62231
|
+
import { useState as useState110 } from "react";
|
|
62087
62232
|
import { jsx as jsx189, jsxs as jsxs180 } from "react/jsx-runtime";
|
|
62088
62233
|
function formatDuration4(start, end) {
|
|
62089
62234
|
const ms = Date.parse(end) - Date.parse(start);
|
|
@@ -62107,7 +62252,7 @@ function CollapsibleSection({
|
|
|
62107
62252
|
defaultOpen = false,
|
|
62108
62253
|
children
|
|
62109
62254
|
}) {
|
|
62110
|
-
const [open, setOpen] =
|
|
62255
|
+
const [open, setOpen] = useState110(defaultOpen);
|
|
62111
62256
|
return /* @__PURE__ */ jsxs180("div", { className: "rounded-md border bg-background", children: [
|
|
62112
62257
|
/* @__PURE__ */ jsxs180(
|
|
62113
62258
|
"button",
|
|
@@ -62128,7 +62273,7 @@ function CollapsibleSection({
|
|
|
62128
62273
|
function CheckResultRow({ check }) {
|
|
62129
62274
|
const cfg = CHECK_STATUS_CONFIG[check.status];
|
|
62130
62275
|
const { t } = useTranslation();
|
|
62131
|
-
const [expanded, setExpanded] =
|
|
62276
|
+
const [expanded, setExpanded] = useState110(false);
|
|
62132
62277
|
const hasDetail = check.error || check.backingRefs?.length;
|
|
62133
62278
|
return /* @__PURE__ */ jsxs180("div", { className: "rounded border bg-muted/30 px-2.5 py-2 text-xs", children: [
|
|
62134
62279
|
/* @__PURE__ */ jsxs180("div", { className: "flex items-start justify-between gap-2", children: [
|
|
@@ -62371,7 +62516,7 @@ import {
|
|
|
62371
62516
|
UserPlus as UserPlus3,
|
|
62372
62517
|
X as X39
|
|
62373
62518
|
} from "lucide-react";
|
|
62374
|
-
import { useEffect as
|
|
62519
|
+
import { useEffect as useEffect102, useState as useState111 } from "react";
|
|
62375
62520
|
import { Fragment as Fragment44, jsx as jsx191, jsxs as jsxs182 } from "react/jsx-runtime";
|
|
62376
62521
|
function KanbanTaskInspector({
|
|
62377
62522
|
boards,
|
|
@@ -62382,7 +62527,6 @@ function KanbanTaskInspector({
|
|
|
62382
62527
|
onSelectTask,
|
|
62383
62528
|
sendKanban,
|
|
62384
62529
|
sendRaw,
|
|
62385
|
-
refreshBoard,
|
|
62386
62530
|
activityEvents,
|
|
62387
62531
|
activityPresence,
|
|
62388
62532
|
activityLoading,
|
|
@@ -62391,18 +62535,18 @@ function KanbanTaskInspector({
|
|
|
62391
62535
|
refreshActivity
|
|
62392
62536
|
}) {
|
|
62393
62537
|
const { t } = useTranslation();
|
|
62394
|
-
const [agentId, setAgentId] =
|
|
62395
|
-
const [name, setName] =
|
|
62396
|
-
const [role, setRole] =
|
|
62397
|
-
const [provider, setProvider] =
|
|
62398
|
-
const [model, setModel] =
|
|
62399
|
-
const [routingMode, setRoutingMode] =
|
|
62400
|
-
const [fallbackProfile, setFallbackProfile] =
|
|
62401
|
-
const [fallbackModels, setFallbackModels] =
|
|
62402
|
-
const [skills, setSkills] =
|
|
62403
|
-
const [tools, setTools] =
|
|
62404
|
-
const [allowedCapabilities, setAllowedCapabilities] =
|
|
62405
|
-
const [targetBoardId, setTargetBoardId] =
|
|
62538
|
+
const [agentId, setAgentId] = useState111("");
|
|
62539
|
+
const [name, setName] = useState111("");
|
|
62540
|
+
const [role, setRole] = useState111("");
|
|
62541
|
+
const [provider, setProvider] = useState111("");
|
|
62542
|
+
const [model, setModel] = useState111("");
|
|
62543
|
+
const [routingMode, setRoutingMode] = useState111("session");
|
|
62544
|
+
const [fallbackProfile, setFallbackProfile] = useState111("");
|
|
62545
|
+
const [fallbackModels, setFallbackModels] = useState111([]);
|
|
62546
|
+
const [skills, setSkills] = useState111([]);
|
|
62547
|
+
const [tools, setTools] = useState111([]);
|
|
62548
|
+
const [allowedCapabilities, setAllowedCapabilities] = useState111([]);
|
|
62549
|
+
const [targetBoardId, setTargetBoardId] = useState111("");
|
|
62406
62550
|
const modelCandidates = useProviderModels(Boolean(task));
|
|
62407
62551
|
const meta2 = useKanbanMeta(Boolean(task));
|
|
62408
62552
|
const sessionProvider = kanbanMetadataText(meta2.sessionProvider);
|
|
@@ -62411,33 +62555,33 @@ function KanbanTaskInspector({
|
|
|
62411
62555
|
"kanban-task-inspector",
|
|
62412
62556
|
Boolean(task)
|
|
62413
62557
|
);
|
|
62414
|
-
const [showAdvanced, setShowAdvanced] =
|
|
62415
|
-
const [expanded, setExpanded] =
|
|
62416
|
-
const [title, setTitle] =
|
|
62417
|
-
const [description, setDescription] =
|
|
62418
|
-
const [dueDate, setDueDate] =
|
|
62419
|
-
const [status, setStatus] =
|
|
62420
|
-
const [transitionComment, setTransitionComment] =
|
|
62421
|
-
const [transitionAction, setTransitionAction] =
|
|
62422
|
-
const [transitionAttachmentUrl, setTransitionAttachmentUrl] =
|
|
62423
|
-
const [priority, setPriority] =
|
|
62424
|
-
const [taskType, setTaskType] =
|
|
62425
|
-
const [labelsText, setLabelsText] =
|
|
62426
|
-
const [dependsOn, setDependsOn] =
|
|
62427
|
-
const [chainMembers, setChainMembers] =
|
|
62428
|
-
const [enforceChainDependencies, setEnforceChainDependencies] =
|
|
62429
|
-
const [estimatedHours, setEstimatedHours] =
|
|
62430
|
-
const [actualHours, setActualHours] =
|
|
62431
|
-
const [retryPolicy, setRetryPolicy] =
|
|
62432
|
-
const [costCeilingUsd, setCostCeilingUsd] =
|
|
62433
|
-
const [maxAttempts, setMaxAttempts] =
|
|
62434
|
-
const [newCheck, setNewCheck] =
|
|
62435
|
-
const [newNote, setNewNote] =
|
|
62436
|
-
const [newActivityDetails, setNewActivityDetails] =
|
|
62437
|
-
const [newActivityKind, setNewActivityKind] =
|
|
62438
|
-
const [newActivityOutcome, setNewActivityOutcome] =
|
|
62439
|
-
const [changeReason, setChangeReason] =
|
|
62440
|
-
|
|
62558
|
+
const [showAdvanced, setShowAdvanced] = useState111(false);
|
|
62559
|
+
const [expanded, setExpanded] = useState111(false);
|
|
62560
|
+
const [title, setTitle] = useState111("");
|
|
62561
|
+
const [description, setDescription] = useState111("");
|
|
62562
|
+
const [dueDate, setDueDate] = useState111("");
|
|
62563
|
+
const [status, setStatus] = useState111("pending");
|
|
62564
|
+
const [transitionComment, setTransitionComment] = useState111("");
|
|
62565
|
+
const [transitionAction, setTransitionAction] = useState111("");
|
|
62566
|
+
const [transitionAttachmentUrl, setTransitionAttachmentUrl] = useState111("");
|
|
62567
|
+
const [priority, setPriority] = useState111("medium");
|
|
62568
|
+
const [taskType, setTaskType] = useState111("chore");
|
|
62569
|
+
const [labelsText, setLabelsText] = useState111("");
|
|
62570
|
+
const [dependsOn, setDependsOn] = useState111([]);
|
|
62571
|
+
const [chainMembers, setChainMembers] = useState111([]);
|
|
62572
|
+
const [enforceChainDependencies, setEnforceChainDependencies] = useState111(false);
|
|
62573
|
+
const [estimatedHours, setEstimatedHours] = useState111("");
|
|
62574
|
+
const [actualHours, setActualHours] = useState111("");
|
|
62575
|
+
const [retryPolicy, setRetryPolicy] = useState111("off");
|
|
62576
|
+
const [costCeilingUsd, setCostCeilingUsd] = useState111("");
|
|
62577
|
+
const [maxAttempts, setMaxAttempts] = useState111("");
|
|
62578
|
+
const [newCheck, setNewCheck] = useState111("");
|
|
62579
|
+
const [newNote, setNewNote] = useState111("");
|
|
62580
|
+
const [newActivityDetails, setNewActivityDetails] = useState111("");
|
|
62581
|
+
const [newActivityKind, setNewActivityKind] = useState111("observation");
|
|
62582
|
+
const [newActivityOutcome, setNewActivityOutcome] = useState111("unknown");
|
|
62583
|
+
const [changeReason, setChangeReason] = useState111("");
|
|
62584
|
+
useEffect102(() => {
|
|
62441
62585
|
const assignmentProvider = kanbanMetadataText(task?.assignment?.provider);
|
|
62442
62586
|
const assignmentModel = kanbanMetadataText(task?.assignment?.model);
|
|
62443
62587
|
setAgentId(
|
|
@@ -62532,7 +62676,6 @@ function KanbanTaskInspector({
|
|
|
62532
62676
|
enforceDependencies: enforceChainDependencies
|
|
62533
62677
|
});
|
|
62534
62678
|
}
|
|
62535
|
-
window.setTimeout(() => refreshBoard(board.id), 180);
|
|
62536
62679
|
setChangeReason("");
|
|
62537
62680
|
};
|
|
62538
62681
|
const managedStageOrder = ["backlog", "todo", "running", "review", "done"];
|
|
@@ -62556,7 +62699,6 @@ function KanbanTaskInspector({
|
|
|
62556
62699
|
}
|
|
62557
62700
|
} : {}
|
|
62558
62701
|
});
|
|
62559
|
-
window.setTimeout(() => refreshBoard(board.id), 180);
|
|
62560
62702
|
};
|
|
62561
62703
|
const addCheck = () => {
|
|
62562
62704
|
if (!board || !task || !newCheck.trim()) return;
|
|
@@ -62587,13 +62729,11 @@ function KanbanTaskInspector({
|
|
|
62587
62729
|
if (!board || !task) return;
|
|
62588
62730
|
sendKanban("kanban.task.assign", payload("assign"));
|
|
62589
62731
|
setChangeReason("");
|
|
62590
|
-
window.setTimeout(() => refreshBoard(board.id), 150);
|
|
62591
62732
|
};
|
|
62592
62733
|
const dispatch = () => {
|
|
62593
62734
|
if (!board || !task) return;
|
|
62594
62735
|
sendKanban("kanban.task.dispatch", payload("dispatch"));
|
|
62595
62736
|
setChangeReason("");
|
|
62596
|
-
window.setTimeout(() => refreshBoard(board.id), 200);
|
|
62597
62737
|
};
|
|
62598
62738
|
const copyTask = () => {
|
|
62599
62739
|
if (!board || !task || !targetBoardId) return;
|
|
@@ -62669,7 +62809,6 @@ function KanbanTaskInspector({
|
|
|
62669
62809
|
boundary,
|
|
62670
62810
|
activityNote: "Task boundary edited in WebUI."
|
|
62671
62811
|
});
|
|
62672
|
-
window.setTimeout(() => refreshBoard(board.id), 150);
|
|
62673
62812
|
}
|
|
62674
62813
|
}
|
|
62675
62814
|
),
|
|
@@ -63253,10 +63392,10 @@ var init_KanbanViewModeTabs = __esm({
|
|
|
63253
63392
|
});
|
|
63254
63393
|
|
|
63255
63394
|
// src/components/useKanbanRegistrySessionIds.ts
|
|
63256
|
-
import { useEffect as
|
|
63395
|
+
import { useEffect as useEffect103, useState as useState112 } from "react";
|
|
63257
63396
|
function useKanbanRegistrySessionIds() {
|
|
63258
|
-
const [registrySessionIds, setRegistrySessionIds] =
|
|
63259
|
-
|
|
63397
|
+
const [registrySessionIds, setRegistrySessionIds] = useState112([]);
|
|
63398
|
+
useEffect103(() => {
|
|
63260
63399
|
let cancelled = false;
|
|
63261
63400
|
const refreshRegistry = async () => {
|
|
63262
63401
|
try {
|
|
@@ -63296,7 +63435,7 @@ __export(KanbanView_exports, {
|
|
|
63296
63435
|
deriveTaskCardIntelligence: () => deriveTaskCardIntelligence
|
|
63297
63436
|
});
|
|
63298
63437
|
import { Columns3 as Columns34, Copy as Copy8, Plus as Plus17, Trash2 as Trash217, X as X40 } from "lucide-react";
|
|
63299
|
-
import { useEffect as
|
|
63438
|
+
import { useEffect as useEffect104, useMemo as useMemo57, useRef as useRef51, useState as useState113 } from "react";
|
|
63300
63439
|
import { Fragment as Fragment45, jsx as jsx193, jsxs as jsxs183 } from "react/jsx-runtime";
|
|
63301
63440
|
function KanbanView({ onClose }) {
|
|
63302
63441
|
const { t } = useTranslation();
|
|
@@ -63315,31 +63454,43 @@ function KanbanView({ onClose }) {
|
|
|
63315
63454
|
queueHealth,
|
|
63316
63455
|
supervisorSnapshot,
|
|
63317
63456
|
setLoading,
|
|
63318
|
-
setActiveBoardId
|
|
63457
|
+
setActiveBoardId,
|
|
63458
|
+
setError
|
|
63319
63459
|
} = useKanbanStore();
|
|
63320
|
-
const [newBoardTitle, setNewBoardTitle] =
|
|
63321
|
-
const [boardPage, setBoardPage] =
|
|
63460
|
+
const [newBoardTitle, setNewBoardTitle] = useState113("");
|
|
63461
|
+
const [boardPage, setBoardPage] = useState113(1);
|
|
63322
63462
|
const registrySessionIds = useKanbanRegistrySessionIds();
|
|
63323
|
-
const [newTaskTitle, setNewTaskTitle] =
|
|
63324
|
-
const boardScrollRef =
|
|
63463
|
+
const [newTaskTitle, setNewTaskTitle] = useState113("");
|
|
63464
|
+
const boardScrollRef = useRef51(null);
|
|
63325
63465
|
useHorizontalScroll(boardScrollRef);
|
|
63326
|
-
const [newColumnTitle, setNewColumnTitle] =
|
|
63327
|
-
const [selectedTaskId, setSelectedTaskId] =
|
|
63328
|
-
const [taskActivity, setTaskActivity] =
|
|
63329
|
-
const [taskActivityPresence, setTaskActivityPresence] =
|
|
63330
|
-
const [taskActivityLoading, setTaskActivityLoading] =
|
|
63331
|
-
const [taskActivityError, setTaskActivityError] =
|
|
63332
|
-
const [taskActivityRefresh, setTaskActivityRefresh] =
|
|
63333
|
-
const [dragTaskId, setDragTaskId] =
|
|
63334
|
-
const [viewMode, setViewMode] =
|
|
63335
|
-
const
|
|
63466
|
+
const [newColumnTitle, setNewColumnTitle] = useState113("");
|
|
63467
|
+
const [selectedTaskId, setSelectedTaskId] = useState113(null);
|
|
63468
|
+
const [taskActivity, setTaskActivity] = useState113([]);
|
|
63469
|
+
const [taskActivityPresence, setTaskActivityPresence] = useState113();
|
|
63470
|
+
const [taskActivityLoading, setTaskActivityLoading] = useState113(false);
|
|
63471
|
+
const [taskActivityError, setTaskActivityError] = useState113(null);
|
|
63472
|
+
const [taskActivityRefresh, setTaskActivityRefresh] = useState113(0);
|
|
63473
|
+
const [dragTaskId, setDragTaskId] = useState113(null);
|
|
63474
|
+
const [viewMode, setViewMode] = useState113("board");
|
|
63475
|
+
const [confirmDeleteBoard, setConfirmDeleteBoard] = useState113(false);
|
|
63476
|
+
const armedDeleteBoardIdRef = useRef51(null);
|
|
63477
|
+
const autoSelectedSessionRef = useRef51(null);
|
|
63478
|
+
const skipBoardAutoSelectRef = useRef51(false);
|
|
63479
|
+
useEffect104(() => {
|
|
63480
|
+
if (!confirmDeleteBoard) return;
|
|
63481
|
+
const timer = window.setTimeout(() => {
|
|
63482
|
+
setConfirmDeleteBoard(false);
|
|
63483
|
+
armedDeleteBoardIdRef.current = null;
|
|
63484
|
+
}, 4e3);
|
|
63485
|
+
return () => window.clearTimeout(timer);
|
|
63486
|
+
}, [confirmDeleteBoard]);
|
|
63487
|
+
useEffect104(() => {
|
|
63488
|
+
setConfirmDeleteBoard(false);
|
|
63489
|
+
armedDeleteBoardIdRef.current = null;
|
|
63490
|
+
}, [activeBoardId]);
|
|
63336
63491
|
const ws = useMemo57(() => getWSClient(wsUrl), [wsUrl]);
|
|
63337
63492
|
const selectedTask = activeBoard?.tasks.find((task) => task.id === selectedTaskId) ?? null;
|
|
63338
|
-
const
|
|
63339
|
-
() => collectLiveAgentIdentities(fleetAgents.values()),
|
|
63340
|
-
[fleetAgents]
|
|
63341
|
-
);
|
|
63342
|
-
const activeSessionIdsRef = useRef49([]);
|
|
63493
|
+
const activeSessionIdsRef = useRef51([]);
|
|
63343
63494
|
const activeSessionIds = useMemo57(() => {
|
|
63344
63495
|
const next = collectActiveSessionIds({
|
|
63345
63496
|
sessionId,
|
|
@@ -63358,10 +63509,9 @@ function KanbanView({ onClose }) {
|
|
|
63358
63509
|
const boardAudit = useMemo57(
|
|
63359
63510
|
() => activeBoard ? auditKanbanBoard(activeBoard, {
|
|
63360
63511
|
now: Date.now(),
|
|
63361
|
-
liveAgentIdentities,
|
|
63362
63512
|
requireDueDate: activeBoard.lifecycle?.mode === "managed"
|
|
63363
63513
|
}) : null,
|
|
63364
|
-
[activeBoard
|
|
63514
|
+
[activeBoard]
|
|
63365
63515
|
);
|
|
63366
63516
|
const runningCostTotal = useMemo57(() => runningBoardCostTotal(activeBoard), [activeBoard]);
|
|
63367
63517
|
const sendKanban = (type, payload = {}) => {
|
|
@@ -63377,13 +63527,11 @@ function KanbanView({ onClose }) {
|
|
|
63377
63527
|
pageSize: BOARD_PAGE_SIZE,
|
|
63378
63528
|
activeSessionIds
|
|
63379
63529
|
});
|
|
63380
|
-
|
|
63381
|
-
if (boardId) sendKanban("kanban.get", { boardId });
|
|
63382
|
-
};
|
|
63383
|
-
useEffect103(() => {
|
|
63530
|
+
useEffect104(() => {
|
|
63384
63531
|
refreshBoards();
|
|
63385
63532
|
}, []);
|
|
63386
|
-
|
|
63533
|
+
useEffect104(() => {
|
|
63534
|
+
if (skipBoardAutoSelectRef.current) return;
|
|
63387
63535
|
const sessionBoard = sessionId ? boards.find((candidate) => candidate.tags?.includes(`session:${sessionId}`)) : void 0;
|
|
63388
63536
|
const shouldSelectSession = Boolean(sessionId && sessionBoard) && autoSelectedSessionRef.current !== sessionId;
|
|
63389
63537
|
const target = shouldSelectSession ? sessionBoard : !activeBoardId ? boards[0] : void 0;
|
|
@@ -63393,18 +63541,18 @@ function KanbanView({ onClose }) {
|
|
|
63393
63541
|
sendKanban("kanban.get", { boardId: target.id });
|
|
63394
63542
|
}
|
|
63395
63543
|
}, [boards, activeBoardId, sessionId, setActiveBoardId]);
|
|
63396
|
-
|
|
63544
|
+
useEffect104(() => {
|
|
63397
63545
|
if (activeBoard && selectedTaskId && !activeBoard.tasks.some((task) => task.id === selectedTaskId)) {
|
|
63398
63546
|
setSelectedTaskId(null);
|
|
63399
63547
|
}
|
|
63400
63548
|
}, [activeBoard, selectedTaskId]);
|
|
63401
|
-
|
|
63549
|
+
useEffect104(() => {
|
|
63402
63550
|
if (activeBoardId) {
|
|
63403
63551
|
sendKanban("kanban.health", { boardId: activeBoardId });
|
|
63404
63552
|
sendKanban("kanban.supervisor.status", { boardId: activeBoardId });
|
|
63405
63553
|
}
|
|
63406
63554
|
}, [activeBoardId]);
|
|
63407
|
-
|
|
63555
|
+
useEffect104(() => {
|
|
63408
63556
|
if (!activeBoardId) return;
|
|
63409
63557
|
const interval = setInterval(() => {
|
|
63410
63558
|
ws.send({ type: "kanban.get", payload: { boardId: activeBoardId } });
|
|
@@ -63412,7 +63560,7 @@ function KanbanView({ onClose }) {
|
|
|
63412
63560
|
}, 5e3);
|
|
63413
63561
|
return () => clearInterval(interval);
|
|
63414
63562
|
}, [activeBoardId, ws]);
|
|
63415
|
-
|
|
63563
|
+
useEffect104(() => {
|
|
63416
63564
|
const interval = setInterval(() => {
|
|
63417
63565
|
ws.send({
|
|
63418
63566
|
type: "kanban.list",
|
|
@@ -63424,12 +63572,13 @@ function KanbanView({ onClose }) {
|
|
|
63424
63572
|
const changeBoardPage = (page) => {
|
|
63425
63573
|
setBoardPage(page);
|
|
63426
63574
|
setActiveBoardId(null);
|
|
63575
|
+
skipBoardAutoSelectRef.current = true;
|
|
63427
63576
|
refreshBoards(page);
|
|
63428
63577
|
};
|
|
63429
|
-
|
|
63578
|
+
useEffect104(() => {
|
|
63430
63579
|
setTaskActivityPresence(void 0);
|
|
63431
63580
|
}, [activeBoardId, selectedTaskId]);
|
|
63432
|
-
|
|
63581
|
+
useEffect104(() => {
|
|
63433
63582
|
if (!activeBoardId || !selectedTaskId) {
|
|
63434
63583
|
return;
|
|
63435
63584
|
}
|
|
@@ -63455,7 +63604,7 @@ function KanbanView({ onClose }) {
|
|
|
63455
63604
|
});
|
|
63456
63605
|
return off;
|
|
63457
63606
|
}, [activeBoardId, selectedTaskId, selectedTask?.updatedAt, taskActivityRefresh, ws]);
|
|
63458
|
-
|
|
63607
|
+
useEffect104(() => {
|
|
63459
63608
|
if (!activeBoardId || !selectedTaskId) return;
|
|
63460
63609
|
const onMessage = ws.on.bind(ws);
|
|
63461
63610
|
return onMessage("kanban.task.activity.changed", (message) => {
|
|
@@ -63494,7 +63643,6 @@ function KanbanView({ onClose }) {
|
|
|
63494
63643
|
columnId: activeBoard.columns[0]?.id ?? "backlog",
|
|
63495
63644
|
activityNote: "Task created manually in WebUI."
|
|
63496
63645
|
});
|
|
63497
|
-
window.setTimeout(() => refreshBoard(activeBoard.id), 150);
|
|
63498
63646
|
};
|
|
63499
63647
|
const createColumn = () => {
|
|
63500
63648
|
if (!activeBoard) return;
|
|
@@ -63502,12 +63650,10 @@ function KanbanView({ onClose }) {
|
|
|
63502
63650
|
if (!title) return;
|
|
63503
63651
|
setNewColumnTitle("");
|
|
63504
63652
|
sendKanban("kanban.column.add", { boardId: activeBoard.id, title });
|
|
63505
|
-
window.setTimeout(() => refreshBoard(activeBoard.id), 150);
|
|
63506
63653
|
};
|
|
63507
63654
|
const deleteBoard = () => {
|
|
63508
63655
|
if (!activeBoard) return;
|
|
63509
63656
|
sendKanban("kanban.delete", { boardId: activeBoard.id });
|
|
63510
|
-
window.setTimeout(refreshBoards, 150);
|
|
63511
63657
|
};
|
|
63512
63658
|
const duplicateBoard = () => {
|
|
63513
63659
|
if (!activeBoard) return;
|
|
@@ -63515,12 +63661,10 @@ function KanbanView({ onClose }) {
|
|
|
63515
63661
|
boardId: activeBoard.id,
|
|
63516
63662
|
title: `${activeBoard.title} Copy`
|
|
63517
63663
|
});
|
|
63518
|
-
window.setTimeout(refreshBoards, 150);
|
|
63519
63664
|
};
|
|
63520
63665
|
const deleteTask = (task) => {
|
|
63521
63666
|
if (!activeBoard) return;
|
|
63522
63667
|
sendKanban("kanban.task.remove", { boardId: activeBoard.id, taskId: task.id });
|
|
63523
|
-
window.setTimeout(() => refreshBoard(activeBoard.id), 150);
|
|
63524
63668
|
};
|
|
63525
63669
|
const moveTask = (taskId, columnId) => {
|
|
63526
63670
|
if (!activeBoard) return;
|
|
@@ -63533,7 +63677,6 @@ function KanbanView({ onClose }) {
|
|
|
63533
63677
|
columnId,
|
|
63534
63678
|
activityNote: `Moved in WebUI${from ? ` from ${from}` : ""} to ${to}.`
|
|
63535
63679
|
});
|
|
63536
|
-
window.setTimeout(() => refreshBoard(activeBoard.id), 150);
|
|
63537
63680
|
};
|
|
63538
63681
|
return /* @__PURE__ */ jsxs183("div", { className: "flex h-full min-h-0 min-w-0 flex-col bg-background text-foreground md:flex-row", children: [
|
|
63539
63682
|
/* @__PURE__ */ jsx193(
|
|
@@ -63554,6 +63697,7 @@ function KanbanView({ onClose }) {
|
|
|
63554
63697
|
onNewBoardTitleChange: setNewBoardTitle,
|
|
63555
63698
|
onCreateBoard: createBoard,
|
|
63556
63699
|
onBoardSelect: (boardId) => {
|
|
63700
|
+
skipBoardAutoSelectRef.current = false;
|
|
63557
63701
|
setActiveBoardId(boardId);
|
|
63558
63702
|
sendKanban("kanban.get", { boardId });
|
|
63559
63703
|
},
|
|
@@ -63563,7 +63707,7 @@ function KanbanView({ onClose }) {
|
|
|
63563
63707
|
/* @__PURE__ */ jsxs183("main", { className: "flex min-h-0 min-w-0 flex-1 flex-col", children: [
|
|
63564
63708
|
/* @__PURE__ */ jsxs183("header", { className: "flex min-h-12 shrink-0 flex-wrap items-center gap-2 border-b px-3 py-2 sm:px-4", children: [
|
|
63565
63709
|
/* @__PURE__ */ jsxs183("div", { className: "w-full min-w-0 sm:w-auto sm:flex-1", children: [
|
|
63566
|
-
/* @__PURE__ */ jsx193("
|
|
63710
|
+
/* @__PURE__ */ jsx193("h1", { className: "truncate text-sm font-semibold", children: activeBoard?.title ?? "No board selected" }),
|
|
63567
63711
|
/* @__PURE__ */ jsx193("div", { className: "truncate text-[11px] text-muted-foreground", children: activeBoard ? `${activeBoard.columns.length} columns / ${activeBoard.tasks.length} tasks` : "Create or select a board" })
|
|
63568
63712
|
] }),
|
|
63569
63713
|
activeBoard && /* @__PURE__ */ jsxs183(Fragment45, { children: [
|
|
@@ -63607,7 +63751,7 @@ function KanbanView({ onClose }) {
|
|
|
63607
63751
|
type: "button",
|
|
63608
63752
|
title: t("activity:kanban.addColumn"),
|
|
63609
63753
|
onClick: createColumn,
|
|
63610
|
-
className: "
|
|
63754
|
+
className: "flex h-8 w-8 items-center justify-center rounded-md border text-muted-foreground hover:bg-muted hover:text-foreground",
|
|
63611
63755
|
children: /* @__PURE__ */ jsx193(Columns34, { size: 16 })
|
|
63612
63756
|
}
|
|
63613
63757
|
),
|
|
@@ -63625,10 +63769,23 @@ function KanbanView({ onClose }) {
|
|
|
63625
63769
|
"button",
|
|
63626
63770
|
{
|
|
63627
63771
|
type: "button",
|
|
63628
|
-
|
|
63629
|
-
|
|
63630
|
-
|
|
63631
|
-
|
|
63772
|
+
"aria-pressed": confirmDeleteBoard,
|
|
63773
|
+
title: confirmDeleteBoard ? t("activity:kanban.confirmDeleteBoard") : t("activity:kanban.deleteBoard"),
|
|
63774
|
+
onClick: () => {
|
|
63775
|
+
if (confirmDeleteBoard && armedDeleteBoardIdRef.current === activeBoard?.id) {
|
|
63776
|
+
setConfirmDeleteBoard(false);
|
|
63777
|
+
armedDeleteBoardIdRef.current = null;
|
|
63778
|
+
deleteBoard();
|
|
63779
|
+
} else {
|
|
63780
|
+
armedDeleteBoardIdRef.current = activeBoard?.id ?? null;
|
|
63781
|
+
setConfirmDeleteBoard(true);
|
|
63782
|
+
}
|
|
63783
|
+
},
|
|
63784
|
+
className: cn(
|
|
63785
|
+
"hidden h-8 items-center justify-center rounded-md border transition-colors sm:flex",
|
|
63786
|
+
confirmDeleteBoard ? "w-16 gap-1 border-destructive/40 bg-destructive/15 text-[11px] font-semibold text-destructive" : "w-16 text-muted-foreground hover:bg-destructive/10 hover:text-destructive"
|
|
63787
|
+
),
|
|
63788
|
+
children: confirmDeleteBoard ? t("activity:kanban.confirmDelete") : /* @__PURE__ */ jsx193(Trash217, { size: 16 })
|
|
63632
63789
|
}
|
|
63633
63790
|
)
|
|
63634
63791
|
] })
|
|
@@ -63641,7 +63798,6 @@ function KanbanView({ onClose }) {
|
|
|
63641
63798
|
value: activeBoard.boundary,
|
|
63642
63799
|
onSave: (boundary) => {
|
|
63643
63800
|
sendKanban("kanban.update", { boardId: activeBoard.id, boundary });
|
|
63644
|
-
window.setTimeout(() => refreshBoard(activeBoard.id), 150);
|
|
63645
63801
|
}
|
|
63646
63802
|
}
|
|
63647
63803
|
) }),
|
|
@@ -63667,7 +63823,17 @@ function KanbanView({ onClose }) {
|
|
|
63667
63823
|
activeBoard && /* @__PURE__ */ jsx193(KanbanViewModeTabs, { viewMode, onViewModeChange: setViewMode }),
|
|
63668
63824
|
error && /* @__PURE__ */ jsxs183("div", { className: "flex h-9 shrink-0 items-center gap-2 border-b border-destructive/30 bg-destructive/10 px-4 text-sm text-destructive", children: [
|
|
63669
63825
|
/* @__PURE__ */ jsx193(X40, { size: 15 }),
|
|
63670
|
-
/* @__PURE__ */ jsx193("span", { className: "truncate", children: error })
|
|
63826
|
+
/* @__PURE__ */ jsx193("span", { className: "min-w-0 flex-1 truncate", children: error }),
|
|
63827
|
+
/* @__PURE__ */ jsx193(
|
|
63828
|
+
"button",
|
|
63829
|
+
{
|
|
63830
|
+
type: "button",
|
|
63831
|
+
"aria-label": t("common:action.close"),
|
|
63832
|
+
onClick: () => setError(null),
|
|
63833
|
+
className: "flex h-6 w-6 shrink-0 items-center justify-center rounded hover:bg-destructive/20",
|
|
63834
|
+
children: /* @__PURE__ */ jsx193(X40, { size: 15 })
|
|
63835
|
+
}
|
|
63836
|
+
)
|
|
63671
63837
|
] }),
|
|
63672
63838
|
/* @__PURE__ */ jsx193(
|
|
63673
63839
|
"div",
|
|
@@ -63718,7 +63884,6 @@ function KanbanView({ onClose }) {
|
|
|
63718
63884
|
onSelectTask: setSelectedTaskId,
|
|
63719
63885
|
sendKanban,
|
|
63720
63886
|
sendRaw,
|
|
63721
|
-
refreshBoard,
|
|
63722
63887
|
activityEvents: taskActivity,
|
|
63723
63888
|
activityPresence: taskActivityPresence,
|
|
63724
63889
|
activityLoading: taskActivityLoading,
|
|
@@ -63737,6 +63902,7 @@ var init_KanbanView = __esm({
|
|
|
63737
63902
|
init_i18n();
|
|
63738
63903
|
init_useHorizontalScroll();
|
|
63739
63904
|
init_kanban_cleaner();
|
|
63905
|
+
init_utils();
|
|
63740
63906
|
init_ws_client();
|
|
63741
63907
|
init_stores();
|
|
63742
63908
|
init_KanbanBoardChrome();
|
|
@@ -63785,7 +63951,7 @@ import {
|
|
|
63785
63951
|
Lock as Lock2,
|
|
63786
63952
|
Globe as Globe8
|
|
63787
63953
|
} from "lucide-react";
|
|
63788
|
-
import { useEffect as
|
|
63954
|
+
import { useEffect as useEffect105 } from "react";
|
|
63789
63955
|
import { jsx as jsx194, jsxs as jsxs184 } from "react/jsx-runtime";
|
|
63790
63956
|
function fmtTime3(iso) {
|
|
63791
63957
|
const d = new Date(iso);
|
|
@@ -63824,7 +63990,7 @@ function MailboxDetailView({ className }) {
|
|
|
63824
63990
|
const { t } = useTranslation();
|
|
63825
63991
|
const msg = useUIStore((s) => s.selectedMailMessage);
|
|
63826
63992
|
const setSelectedMailMessage = useUIStore((s) => s.setSelectedMailMessage);
|
|
63827
|
-
|
|
63993
|
+
useEffect105(() => {
|
|
63828
63994
|
return () => {
|
|
63829
63995
|
setSelectedMailMessage(null);
|
|
63830
63996
|
};
|
|
@@ -64983,9 +65149,9 @@ var init_resolve = __esm({
|
|
|
64983
65149
|
});
|
|
64984
65150
|
|
|
64985
65151
|
// src/components/OfficeMapCanvas/use-recently-finished.ts
|
|
64986
|
-
import { useMemo as useMemo58, useRef as
|
|
65152
|
+
import { useMemo as useMemo58, useRef as useRef52 } from "react";
|
|
64987
65153
|
function useRecentlyFinishedFleetAgents(fleetAgents) {
|
|
64988
|
-
const retained =
|
|
65154
|
+
const retained = useRef52(/* @__PURE__ */ new Map()).current;
|
|
64989
65155
|
return useMemo58(() => {
|
|
64990
65156
|
const now = Date.now();
|
|
64991
65157
|
const seen = /* @__PURE__ */ new Set();
|
|
@@ -65244,7 +65410,7 @@ import {
|
|
|
65244
65410
|
X as X43,
|
|
65245
65411
|
Zap as Zap19
|
|
65246
65412
|
} from "lucide-react";
|
|
65247
|
-
import { useMemo as useMemo59, useState as
|
|
65413
|
+
import { useMemo as useMemo59, useState as useState114 } from "react";
|
|
65248
65414
|
import { Fragment as Fragment46, jsx as jsx196, jsxs as jsxs186 } from "react/jsx-runtime";
|
|
65249
65415
|
function ToolGlyph({ kind, active }) {
|
|
65250
65416
|
const Icon2 = TOOL_ICONS[kind];
|
|
@@ -65854,7 +66020,7 @@ function AgentOfficeView() {
|
|
|
65854
66020
|
const toolEvents = useVizStore((state) => state.toolEvents);
|
|
65855
66021
|
const projectNameFromSession = useSessionStore((state) => state.projectName);
|
|
65856
66022
|
const recentlyFinished = useRecentlyFinishedFleetAgents(fleetAgents);
|
|
65857
|
-
const [selected, setSelected] =
|
|
66023
|
+
const [selected, setSelected] = useState114(null);
|
|
65858
66024
|
const clients = useMemo59(
|
|
65859
66025
|
() => resolveClients(
|
|
65860
66026
|
liveSessions,
|
|
@@ -66216,26 +66382,26 @@ var init_WatchMessageBubble = __esm({
|
|
|
66216
66382
|
});
|
|
66217
66383
|
|
|
66218
66384
|
// src/components/SessionWatchPanel.tsx
|
|
66219
|
-
import { useCallback as useCallback62, useEffect as
|
|
66385
|
+
import { useCallback as useCallback62, useEffect as useEffect106, useMemo as useMemo60, useRef as useRef53, useState as useState115 } from "react";
|
|
66220
66386
|
import { Bot as Bot21 } from "lucide-react";
|
|
66221
66387
|
import { jsx as jsx198, jsxs as jsxs188 } from "react/jsx-runtime";
|
|
66222
66388
|
function SessionWatchPanel({
|
|
66223
66389
|
sessionId,
|
|
66224
66390
|
limit = 200
|
|
66225
66391
|
}) {
|
|
66226
|
-
const [data, setData] =
|
|
66392
|
+
const [data, setData] = useState115(null);
|
|
66227
66393
|
const { t } = useTranslation();
|
|
66228
|
-
const [error, setError] =
|
|
66229
|
-
const [draft, setDraft] =
|
|
66230
|
-
const [sending, setSending] =
|
|
66231
|
-
const [sent, setSent] =
|
|
66232
|
-
const [msgType, setMsgType] =
|
|
66233
|
-
const [priority, setPriority] =
|
|
66234
|
-
const [thread, setThread] =
|
|
66235
|
-
const [interrupting, setInterrupting] =
|
|
66236
|
-
const scrollRef =
|
|
66237
|
-
const stickRef =
|
|
66238
|
-
const aliveRef =
|
|
66394
|
+
const [error, setError] = useState115(null);
|
|
66395
|
+
const [draft, setDraft] = useState115("");
|
|
66396
|
+
const [sending, setSending] = useState115(false);
|
|
66397
|
+
const [sent, setSent] = useState115(null);
|
|
66398
|
+
const [msgType, setMsgType] = useState115("steer");
|
|
66399
|
+
const [priority, setPriority] = useState115("high");
|
|
66400
|
+
const [thread, setThread] = useState115([]);
|
|
66401
|
+
const [interrupting, setInterrupting] = useState115(false);
|
|
66402
|
+
const scrollRef = useRef53(null);
|
|
66403
|
+
const stickRef = useRef53(true);
|
|
66404
|
+
const aliveRef = useRef53(true);
|
|
66239
66405
|
const liveSessions = useMonitorStore((s) => s.liveSessions);
|
|
66240
66406
|
const targetSession = useMemo60(
|
|
66241
66407
|
() => liveSessions.find((x) => x.sessionId === sessionId),
|
|
@@ -66291,7 +66457,7 @@ function SessionWatchPanel({
|
|
|
66291
66457
|
} catch {
|
|
66292
66458
|
}
|
|
66293
66459
|
}, [sessionId]);
|
|
66294
|
-
|
|
66460
|
+
useEffect106(() => {
|
|
66295
66461
|
aliveRef.current = true;
|
|
66296
66462
|
setData(null);
|
|
66297
66463
|
setError(null);
|
|
@@ -66308,10 +66474,10 @@ function SessionWatchPanel({
|
|
|
66308
66474
|
clearInterval(iv);
|
|
66309
66475
|
};
|
|
66310
66476
|
}, [load, loadThread]);
|
|
66311
|
-
|
|
66477
|
+
useEffect106(() => {
|
|
66312
66478
|
if (activitySig) void load();
|
|
66313
66479
|
}, [activitySig, load]);
|
|
66314
|
-
|
|
66480
|
+
useEffect106(() => {
|
|
66315
66481
|
if (stickRef.current && scrollRef.current) {
|
|
66316
66482
|
scrollRef.current.scrollTop = scrollRef.current.scrollHeight;
|
|
66317
66483
|
}
|
|
@@ -67705,14 +67871,14 @@ import {
|
|
|
67705
67871
|
} from "@xyflow/react";
|
|
67706
67872
|
import "@xyflow/react/dist/style.css";
|
|
67707
67873
|
import { Building2 as Building24 } from "lucide-react";
|
|
67708
|
-
import { useCallback as useCallback63, useEffect as
|
|
67874
|
+
import { useCallback as useCallback63, useEffect as useEffect107, useMemo as useMemo61, useRef as useRef54, useState as useState116 } from "react";
|
|
67709
67875
|
import { jsx as jsx205, jsxs as jsxs195 } from "react/jsx-runtime";
|
|
67710
67876
|
function OfficeMapCanvas() {
|
|
67711
67877
|
const { t } = useTranslation();
|
|
67712
67878
|
const { fitView } = useReactFlow3();
|
|
67713
|
-
const canvasRef =
|
|
67714
|
-
const [canvasSize, setCanvasSize] =
|
|
67715
|
-
|
|
67879
|
+
const canvasRef = useRef54(null);
|
|
67880
|
+
const [canvasSize, setCanvasSize] = useState116({ width: 1280, height: 720 });
|
|
67881
|
+
useEffect107(() => {
|
|
67716
67882
|
const canvas = canvasRef.current;
|
|
67717
67883
|
if (!canvas) return;
|
|
67718
67884
|
const syncSize = () => {
|
|
@@ -67755,12 +67921,12 @@ function OfficeMapCanvas() {
|
|
|
67755
67921
|
const background = useOfficeMapStore((s) => s.background);
|
|
67756
67922
|
const [nodes, setNodes, onNodesChange] = useNodesState2([]);
|
|
67757
67923
|
const [edges, setEdges, onEdgesChange] = useEdgesState2([]);
|
|
67758
|
-
const [selectedNode, setSelectedNode] =
|
|
67759
|
-
const [watch, setWatch] =
|
|
67760
|
-
const [broadcastOpen, setBroadcastOpen] =
|
|
67761
|
-
const [broadcastDraft, setBroadcastDraft] =
|
|
67762
|
-
const [broadcasting, setBroadcasting] =
|
|
67763
|
-
const [broadcastResult, setBroadcastResult] =
|
|
67924
|
+
const [selectedNode, setSelectedNode] = useState116(null);
|
|
67925
|
+
const [watch, setWatch] = useState116(null);
|
|
67926
|
+
const [broadcastOpen, setBroadcastOpen] = useState116(false);
|
|
67927
|
+
const [broadcastDraft, setBroadcastDraft] = useState116("");
|
|
67928
|
+
const [broadcasting, setBroadcasting] = useState116(false);
|
|
67929
|
+
const [broadcastResult, setBroadcastResult] = useState116(null);
|
|
67764
67930
|
const selectedAgentTranscript = useMemo61(() => {
|
|
67765
67931
|
if (selectedNode?.data.kind !== "agent") return EMPTY_AGENT_TRANSCRIPT;
|
|
67766
67932
|
const serverId = selectedNode.data.serverId ?? (selectedNode.id.includes("__agent-") ? selectedNode.id.split("__agent-").pop() : selectedNode.id.replace(/^agent-/, ""));
|
|
@@ -67787,16 +67953,16 @@ function OfficeMapCanvas() {
|
|
|
67787
67953
|
setBroadcasting(false);
|
|
67788
67954
|
}
|
|
67789
67955
|
}, [broadcastDraft, broadcasting]);
|
|
67790
|
-
const activeNodesRef =
|
|
67956
|
+
const activeNodesRef = useRef54(/* @__PURE__ */ new Map());
|
|
67791
67957
|
const ACTIVE_MS = 4e3;
|
|
67792
|
-
const edgeIntensitiesRef =
|
|
67793
|
-
const vizActivityRef =
|
|
67794
|
-
const layoutPosRef =
|
|
67795
|
-
const prevAgentStatsRef =
|
|
67958
|
+
const edgeIntensitiesRef = useRef54(/* @__PURE__ */ new Map());
|
|
67959
|
+
const vizActivityRef = useRef54(/* @__PURE__ */ new Map());
|
|
67960
|
+
const layoutPosRef = useRef54(/* @__PURE__ */ new Map());
|
|
67961
|
+
const prevAgentStatsRef = useRef54(
|
|
67796
67962
|
/* @__PURE__ */ new Map()
|
|
67797
67963
|
);
|
|
67798
|
-
const prevNodeSigRef =
|
|
67799
|
-
|
|
67964
|
+
const prevNodeSigRef = useRef54("");
|
|
67965
|
+
useEffect107(() => {
|
|
67800
67966
|
const rfNodes = [];
|
|
67801
67967
|
const rfEdges = [];
|
|
67802
67968
|
const now = Date.now();
|
|
@@ -68171,7 +68337,7 @@ function OfficeMapCanvas() {
|
|
|
68171
68337
|
return { nodes: [], edges: [], status: "idle" };
|
|
68172
68338
|
}
|
|
68173
68339
|
}
|
|
68174
|
-
|
|
68340
|
+
useEffect107(() => {
|
|
68175
68341
|
if (vizEvents.length === 0) return;
|
|
68176
68342
|
const latestEvent = vizEvents[0];
|
|
68177
68343
|
if (!latestEvent) return;
|
|
@@ -68219,7 +68385,7 @@ function OfficeMapCanvas() {
|
|
|
68219
68385
|
);
|
|
68220
68386
|
}
|
|
68221
68387
|
}, [vizEvents, setNodes, setEdges, ACTIVE_MS, fleetAgents]);
|
|
68222
|
-
|
|
68388
|
+
useEffect107(() => {
|
|
68223
68389
|
const interval = setInterval(() => {
|
|
68224
68390
|
const edgeUpdates = /* @__PURE__ */ new Map();
|
|
68225
68391
|
let edgesChanged = false;
|
|
@@ -68282,7 +68448,7 @@ function OfficeMapCanvas() {
|
|
|
68282
68448
|
const onPaneClick = useCallback63(() => {
|
|
68283
68449
|
setSelectedNode(null);
|
|
68284
68450
|
}, []);
|
|
68285
|
-
|
|
68451
|
+
useEffect107(() => {
|
|
68286
68452
|
if (!watch) return;
|
|
68287
68453
|
const onKey = (e) => {
|
|
68288
68454
|
if (e.key === "Escape") setWatch(null);
|
|
@@ -68299,8 +68465,8 @@ function OfficeMapCanvas() {
|
|
|
68299
68465
|
);
|
|
68300
68466
|
setTimeout(() => fitView({ padding: FIT_VIEW_PADDING, duration: 300 }), 50);
|
|
68301
68467
|
}, [setNodes, fitView]);
|
|
68302
|
-
const [, setTick] =
|
|
68303
|
-
|
|
68468
|
+
const [, setTick] = useState116(0);
|
|
68469
|
+
useEffect107(() => {
|
|
68304
68470
|
const interval = setInterval(() => {
|
|
68305
68471
|
if (!document.hidden) setTick((t2) => t2 + 1);
|
|
68306
68472
|
}, 2e3);
|
|
@@ -68579,7 +68745,7 @@ import {
|
|
|
68579
68745
|
RotateCw as RotateCw6,
|
|
68580
68746
|
Server as Server6
|
|
68581
68747
|
} from "lucide-react";
|
|
68582
|
-
import { useMemo as useMemo62, useState as
|
|
68748
|
+
import { useMemo as useMemo62, useState as useState117 } from "react";
|
|
68583
68749
|
import { jsx as jsx207, jsxs as jsxs197 } from "react/jsx-runtime";
|
|
68584
68750
|
function RefreshDebugView() {
|
|
68585
68751
|
const session = useSessionStore((s) => s.session);
|
|
@@ -68595,7 +68761,7 @@ function RefreshDebugView() {
|
|
|
68595
68761
|
const boundSessionId = useChatStore((s) => s.boundSessionId);
|
|
68596
68762
|
const currentView = useUIStore((s) => s.currentView);
|
|
68597
68763
|
const dockSection = useUIStore((s) => s.dockSection);
|
|
68598
|
-
const [probeLog, setProbeLog] =
|
|
68764
|
+
const [probeLog, setProbeLog] = useState117([]);
|
|
68599
68765
|
const localStorageSize = useMemo62(() => {
|
|
68600
68766
|
if (typeof window === "undefined") return 0;
|
|
68601
68767
|
let total = 0;
|
|
@@ -68794,7 +68960,7 @@ import {
|
|
|
68794
68960
|
} from "@xyflow/react";
|
|
68795
68961
|
import "@xyflow/react/dist/style.css";
|
|
68796
68962
|
import { Expand } from "lucide-react";
|
|
68797
|
-
import { useMemo as useMemo63, useState as
|
|
68963
|
+
import { useMemo as useMemo63, useState as useState118 } from "react";
|
|
68798
68964
|
import { jsx as jsx208, jsxs as jsxs198 } from "react/jsx-runtime";
|
|
68799
68965
|
function compactId2(id) {
|
|
68800
68966
|
return id.length > 14 ? `${id.slice(0, 11)}\u2026` : id;
|
|
@@ -68926,7 +69092,7 @@ function MemoryGraph({
|
|
|
68926
69092
|
error = null
|
|
68927
69093
|
}) {
|
|
68928
69094
|
const { t } = useTranslation();
|
|
68929
|
-
const [fullscreenOpen, setFullscreenOpen] =
|
|
69095
|
+
const [fullscreenOpen, setFullscreenOpen] = useState118(false);
|
|
68930
69096
|
const centerNode = `mem:${centerMemory.id}`;
|
|
68931
69097
|
const directMemoryEdges = useMemo63(
|
|
68932
69098
|
() => graphEdges.filter(
|
|
@@ -69703,7 +69869,7 @@ var init_MemoryDetail = __esm({
|
|
|
69703
69869
|
});
|
|
69704
69870
|
|
|
69705
69871
|
// src/hooks/useMemoryForFile.ts
|
|
69706
|
-
import { useCallback as useCallback64, useEffect as
|
|
69872
|
+
import { useCallback as useCallback64, useEffect as useEffect108, useRef as useRef55, useState as useState119 } from "react";
|
|
69707
69873
|
function useMemoryForFile(options) {
|
|
69708
69874
|
const {
|
|
69709
69875
|
filePath,
|
|
@@ -69721,12 +69887,12 @@ function useMemoryForFile(options) {
|
|
|
69721
69887
|
sendOptions
|
|
69722
69888
|
} = options;
|
|
69723
69889
|
const sendOptionsKey = sendOptions ? JSON.stringify(sendOptions) : "";
|
|
69724
|
-
const [data, setData] =
|
|
69725
|
-
const [loading, setLoading] =
|
|
69726
|
-
const [error, setError] =
|
|
69727
|
-
const requestSeq =
|
|
69728
|
-
const unsubscribeRef =
|
|
69729
|
-
const sendOptionsRef =
|
|
69890
|
+
const [data, setData] = useState119(null);
|
|
69891
|
+
const [loading, setLoading] = useState119(false);
|
|
69892
|
+
const [error, setError] = useState119(null);
|
|
69893
|
+
const requestSeq = useRef55(0);
|
|
69894
|
+
const unsubscribeRef = useRef55(null);
|
|
69895
|
+
const sendOptionsRef = useRef55(sendOptions);
|
|
69730
69896
|
sendOptionsRef.current = sendOptions;
|
|
69731
69897
|
const fetchNow = useCallback64(() => {
|
|
69732
69898
|
if (!filePath) {
|
|
@@ -69780,7 +69946,7 @@ function useMemoryForFile(options) {
|
|
|
69780
69946
|
}
|
|
69781
69947
|
}
|
|
69782
69948
|
}, [filePath, lineStart, lineEnd, limit, showSuperseded, showDeleted]);
|
|
69783
|
-
|
|
69949
|
+
useEffect108(() => {
|
|
69784
69950
|
if (!autoFetch) return;
|
|
69785
69951
|
fetchNow();
|
|
69786
69952
|
return () => {
|
|
@@ -69792,7 +69958,7 @@ function useMemoryForFile(options) {
|
|
|
69792
69958
|
const refetch = useCallback64(() => {
|
|
69793
69959
|
fetchNow();
|
|
69794
69960
|
}, [fetchNow]);
|
|
69795
|
-
|
|
69961
|
+
useEffect108(() => {
|
|
69796
69962
|
return () => {
|
|
69797
69963
|
unsubscribeRef.current?.();
|
|
69798
69964
|
unsubscribeRef.current = null;
|
|
@@ -69819,7 +69985,7 @@ var init_useMemoryForFile = __esm({
|
|
|
69819
69985
|
});
|
|
69820
69986
|
|
|
69821
69987
|
// src/components/MemoryManager/MemoryDrawer.tsx
|
|
69822
|
-
import { useCallback as useCallback65, useEffect as
|
|
69988
|
+
import { useCallback as useCallback65, useEffect as useEffect109, useState as useState120 } from "react";
|
|
69823
69989
|
import {
|
|
69824
69990
|
AlertTriangle as AlertTriangle26,
|
|
69825
69991
|
Check as Check32,
|
|
@@ -70122,8 +70288,8 @@ function MemoryDrawer({
|
|
|
70122
70288
|
onRecover
|
|
70123
70289
|
}) {
|
|
70124
70290
|
const { t } = useTranslation();
|
|
70125
|
-
const [showDeleted, setShowDeleted] =
|
|
70126
|
-
const [pendingActionById, setPendingAction] =
|
|
70291
|
+
const [showDeleted, setShowDeleted] = useState120(false);
|
|
70292
|
+
const [pendingActionById, setPendingAction] = useState120(/* @__PURE__ */ new Map());
|
|
70127
70293
|
const pendingLabels = {
|
|
70128
70294
|
accepting: t("activity:memoryManager.pendingAccepting"),
|
|
70129
70295
|
keeping: t("activity:memoryManager.pendingKeeping"),
|
|
@@ -70155,7 +70321,7 @@ function MemoryDrawer({
|
|
|
70155
70321
|
},
|
|
70156
70322
|
[]
|
|
70157
70323
|
);
|
|
70158
|
-
|
|
70324
|
+
useEffect109(() => {
|
|
70159
70325
|
setShowDeleted(false);
|
|
70160
70326
|
}, [filePath]);
|
|
70161
70327
|
if (!open) return null;
|
|
@@ -70334,7 +70500,7 @@ import {
|
|
|
70334
70500
|
Trash2 as Trash219,
|
|
70335
70501
|
X as X45
|
|
70336
70502
|
} from "lucide-react";
|
|
70337
|
-
import { useEffect as
|
|
70503
|
+
import { useEffect as useEffect110, useRef as useRef56, useState as useState121 } from "react";
|
|
70338
70504
|
import { Fragment as Fragment53, jsx as jsx212, jsxs as jsxs202 } from "react/jsx-runtime";
|
|
70339
70505
|
function MemoryEditor({
|
|
70340
70506
|
mode,
|
|
@@ -70346,9 +70512,9 @@ function MemoryEditor({
|
|
|
70346
70512
|
onSubmit
|
|
70347
70513
|
}) {
|
|
70348
70514
|
const { t } = useTranslation();
|
|
70349
|
-
const textRef =
|
|
70350
|
-
const [agentRoles, setAgentRoles] =
|
|
70351
|
-
|
|
70515
|
+
const textRef = useRef56(null);
|
|
70516
|
+
const [agentRoles, setAgentRoles] = useState121([]);
|
|
70517
|
+
useEffect110(() => {
|
|
70352
70518
|
textRef.current?.focus();
|
|
70353
70519
|
const controller = new AbortController();
|
|
70354
70520
|
void sendRosterMessage("agent-roster.list", {}, controller.signal).then((value) => {
|
|
@@ -70794,7 +70960,7 @@ var init_MemoryEditor = __esm({
|
|
|
70794
70960
|
|
|
70795
70961
|
// src/components/MemoryManager/MemoryFilters.tsx
|
|
70796
70962
|
import { BrainCircuit as BrainCircuit7, ChevronDown as ChevronDown32, FilterX, Search as Search23, Tag as Tag4, X as X46 } from "lucide-react";
|
|
70797
|
-
import { useState as
|
|
70963
|
+
import { useState as useState122 } from "react";
|
|
70798
70964
|
import { jsx as jsx213, jsxs as jsxs203 } from "react/jsx-runtime";
|
|
70799
70965
|
function MemoryFilters({
|
|
70800
70966
|
searchQuery,
|
|
@@ -70813,7 +70979,7 @@ function MemoryFilters({
|
|
|
70813
70979
|
onClearFilters
|
|
70814
70980
|
}) {
|
|
70815
70981
|
const { t } = useTranslation();
|
|
70816
|
-
const [tagsExpanded, setTagsExpanded] =
|
|
70982
|
+
const [tagsExpanded, setTagsExpanded] = useState122(Boolean(tagFilter));
|
|
70817
70983
|
const tagsVisible = tagsExpanded || Boolean(tagFilter);
|
|
70818
70984
|
const hasTags = allTags.length > 0;
|
|
70819
70985
|
return /* @__PURE__ */ jsxs203("div", { className: "shrink-0 space-y-2 overflow-hidden border-b border-border/70 bg-card/45 p-3", children: [
|
|
@@ -71323,7 +71489,7 @@ import {
|
|
|
71323
71489
|
Plus as Plus21,
|
|
71324
71490
|
RefreshCw as RefreshCw23
|
|
71325
71491
|
} from "lucide-react";
|
|
71326
|
-
import { useCallback as useCallback66, useEffect as
|
|
71492
|
+
import { useCallback as useCallback66, useEffect as useEffect111, useMemo as useMemo64, useRef as useRef57, useState as useState123 } from "react";
|
|
71327
71493
|
import { jsx as jsx217, jsxs as jsxs207 } from "react/jsx-runtime";
|
|
71328
71494
|
function MemoryManager() {
|
|
71329
71495
|
const { t } = useTranslation();
|
|
@@ -71340,43 +71506,43 @@ function MemoryManager() {
|
|
|
71340
71506
|
const wsConnected = useConfigStore((state) => state.wsConnected);
|
|
71341
71507
|
const setCurrentView = useUIStore((state) => state.setCurrentView);
|
|
71342
71508
|
const memoryListRef = useScrollPosition("memory");
|
|
71343
|
-
const [memories, setMemories] =
|
|
71344
|
-
const [stats, setStats] =
|
|
71345
|
-
const [initialLoading, setInitialLoading] =
|
|
71346
|
-
const [refreshing, setRefreshing] =
|
|
71347
|
-
const [loadError, setLoadError] =
|
|
71348
|
-
const [mutationError, setMutationError] =
|
|
71349
|
-
const [notice, setNotice] =
|
|
71350
|
-
const [selectedId, setSelectedId] =
|
|
71351
|
-
const [graphEdges, setGraphEdges] =
|
|
71352
|
-
const [graphMemories, setGraphMemories] =
|
|
71353
|
-
const [graphError, setGraphError] =
|
|
71354
|
-
const [graphLoading, setGraphLoading] =
|
|
71355
|
-
const [editing, setEditing] =
|
|
71356
|
-
const [creating, setCreating] =
|
|
71357
|
-
const [draft, setDraft] =
|
|
71358
|
-
const [baselineDraft, setBaselineDraft] =
|
|
71359
|
-
const [busyAction, setBusyAction] =
|
|
71360
|
-
const [deletingId, setDeletingId] =
|
|
71361
|
-
const [searchQuery, setSearchQuery] =
|
|
71362
|
-
const [statusFilter, setStatusFilter] =
|
|
71363
|
-
const [kindFilter, setKindFilter] =
|
|
71364
|
-
const [audienceOnly, setAudienceOnly] =
|
|
71365
|
-
const [tagFilter, setTagFilter] =
|
|
71366
|
-
const [showDeleted, setShowDeleted] =
|
|
71367
|
-
const [pageCursor, setPageCursor] =
|
|
71368
|
-
const [hasMore, setHasMore] =
|
|
71369
|
-
const [loadingMore, setLoadingMore] =
|
|
71370
|
-
const [statusCounts, setStatusCounts] =
|
|
71509
|
+
const [memories, setMemories] = useState123([]);
|
|
71510
|
+
const [stats, setStats] = useState123(null);
|
|
71511
|
+
const [initialLoading, setInitialLoading] = useState123(true);
|
|
71512
|
+
const [refreshing, setRefreshing] = useState123(false);
|
|
71513
|
+
const [loadError, setLoadError] = useState123(null);
|
|
71514
|
+
const [mutationError, setMutationError] = useState123(null);
|
|
71515
|
+
const [notice, setNotice] = useState123(null);
|
|
71516
|
+
const [selectedId, setSelectedId] = useState123(null);
|
|
71517
|
+
const [graphEdges, setGraphEdges] = useState123([]);
|
|
71518
|
+
const [graphMemories, setGraphMemories] = useState123([]);
|
|
71519
|
+
const [graphError, setGraphError] = useState123(null);
|
|
71520
|
+
const [graphLoading, setGraphLoading] = useState123(false);
|
|
71521
|
+
const [editing, setEditing] = useState123(false);
|
|
71522
|
+
const [creating, setCreating] = useState123(false);
|
|
71523
|
+
const [draft, setDraft] = useState123(emptyDraft2);
|
|
71524
|
+
const [baselineDraft, setBaselineDraft] = useState123(emptyDraft2);
|
|
71525
|
+
const [busyAction, setBusyAction] = useState123(null);
|
|
71526
|
+
const [deletingId, setDeletingId] = useState123(null);
|
|
71527
|
+
const [searchQuery, setSearchQuery] = useState123("");
|
|
71528
|
+
const [statusFilter, setStatusFilter] = useState123("all");
|
|
71529
|
+
const [kindFilter, setKindFilter] = useState123("all");
|
|
71530
|
+
const [audienceOnly, setAudienceOnly] = useState123(false);
|
|
71531
|
+
const [tagFilter, setTagFilter] = useState123(null);
|
|
71532
|
+
const [showDeleted, setShowDeleted] = useState123(false);
|
|
71533
|
+
const [pageCursor, setPageCursor] = useState123(null);
|
|
71534
|
+
const [hasMore, setHasMore] = useState123(false);
|
|
71535
|
+
const [loadingMore, setLoadingMore] = useState123(false);
|
|
71536
|
+
const [statusCounts, setStatusCounts] = useState123({});
|
|
71371
71537
|
const PAGE_SIZE = 100;
|
|
71372
|
-
const [drawerOpen, setDrawerOpen] =
|
|
71373
|
-
const [currentFilePath, setCurrentFilePath] =
|
|
71374
|
-
const hasLoadedRef =
|
|
71375
|
-
const mountedRef =
|
|
71376
|
-
const listGenerationRef =
|
|
71377
|
-
const mutationGenerationRef =
|
|
71378
|
-
const listCleanupRef =
|
|
71379
|
-
const mutationCleanupRef =
|
|
71538
|
+
const [drawerOpen, setDrawerOpen] = useState123(false);
|
|
71539
|
+
const [currentFilePath, setCurrentFilePath] = useState123(null);
|
|
71540
|
+
const hasLoadedRef = useRef57(false);
|
|
71541
|
+
const mountedRef = useRef57(true);
|
|
71542
|
+
const listGenerationRef = useRef57(0);
|
|
71543
|
+
const mutationGenerationRef = useRef57(0);
|
|
71544
|
+
const listCleanupRef = useRef57(null);
|
|
71545
|
+
const mutationCleanupRef = useRef57(null);
|
|
71380
71546
|
const dirty = useMemo64(
|
|
71381
71547
|
() => JSON.stringify(draft) !== JSON.stringify(baselineDraft),
|
|
71382
71548
|
[baselineDraft, draft]
|
|
@@ -71476,7 +71642,7 @@ function MemoryManager() {
|
|
|
71476
71642
|
if (loadingMore || !pageCursor) return;
|
|
71477
71643
|
loadPage(pageCursor);
|
|
71478
71644
|
}, [loadPage, loadingMore, pageCursor]);
|
|
71479
|
-
|
|
71645
|
+
useEffect111(() => {
|
|
71480
71646
|
mountedRef.current = true;
|
|
71481
71647
|
loadMemories();
|
|
71482
71648
|
return () => {
|
|
@@ -71487,7 +71653,7 @@ function MemoryManager() {
|
|
|
71487
71653
|
mutationCleanupRef.current?.();
|
|
71488
71654
|
};
|
|
71489
71655
|
}, [loadMemories]);
|
|
71490
|
-
|
|
71656
|
+
useEffect111(() => {
|
|
71491
71657
|
setGraphEdges([]);
|
|
71492
71658
|
setGraphMemories([]);
|
|
71493
71659
|
setGraphError(null);
|
|
@@ -71516,12 +71682,12 @@ function MemoryManager() {
|
|
|
71516
71682
|
off();
|
|
71517
71683
|
};
|
|
71518
71684
|
}, [client2, getSageGraph, selectedId]);
|
|
71519
|
-
const wasConnectedRef =
|
|
71520
|
-
|
|
71685
|
+
const wasConnectedRef = useRef57(wsConnected);
|
|
71686
|
+
useEffect111(() => {
|
|
71521
71687
|
if (wsConnected && !wasConnectedRef.current && hasLoadedRef.current) loadMemories();
|
|
71522
71688
|
wasConnectedRef.current = wsConnected;
|
|
71523
71689
|
}, [loadMemories, wsConnected]);
|
|
71524
|
-
|
|
71690
|
+
useEffect111(() => {
|
|
71525
71691
|
if (!notice) return;
|
|
71526
71692
|
const timer = setTimeout(() => setNotice(null), 4e3);
|
|
71527
71693
|
return () => clearTimeout(timer);
|
|
@@ -72308,7 +72474,7 @@ import {
|
|
|
72308
72474
|
Upload,
|
|
72309
72475
|
X as X47
|
|
72310
72476
|
} from "lucide-react";
|
|
72311
|
-
import { useCallback as useCallback67, useEffect as
|
|
72477
|
+
import { useCallback as useCallback67, useEffect as useEffect112, useMemo as useMemo65, useRef as useRef58, useState as useState124 } from "react";
|
|
72312
72478
|
import { Fragment as Fragment55, jsx as jsx218, jsxs as jsxs208 } from "react/jsx-runtime";
|
|
72313
72479
|
function cleanStringArray(value) {
|
|
72314
72480
|
if (!Array.isArray(value)) return void 0;
|
|
@@ -72382,22 +72548,22 @@ function uniqueAudienceValues(memories, key) {
|
|
|
72382
72548
|
function AudienceMemoryPanel() {
|
|
72383
72549
|
const { t } = useTranslation();
|
|
72384
72550
|
const ws = useWebSocket();
|
|
72385
|
-
const [memories, setMemories] =
|
|
72386
|
-
const [loading, setLoading] =
|
|
72387
|
-
const [feedback, setFeedback] =
|
|
72388
|
-
const [query, setQuery] =
|
|
72389
|
-
const [showCreate, setShowCreate] =
|
|
72390
|
-
const [showImport, setShowImport] =
|
|
72391
|
-
const [deletingId, setDeletingId] =
|
|
72392
|
-
const [creating, setCreating] =
|
|
72393
|
-
const [deleting, setDeleting] =
|
|
72394
|
-
const deletingIdRef =
|
|
72551
|
+
const [memories, setMemories] = useState124([]);
|
|
72552
|
+
const [loading, setLoading] = useState124(true);
|
|
72553
|
+
const [feedback, setFeedback] = useState124(null);
|
|
72554
|
+
const [query, setQuery] = useState124("");
|
|
72555
|
+
const [showCreate, setShowCreate] = useState124(false);
|
|
72556
|
+
const [showImport, setShowImport] = useState124(false);
|
|
72557
|
+
const [deletingId, setDeletingId] = useState124(null);
|
|
72558
|
+
const [creating, setCreating] = useState124(false);
|
|
72559
|
+
const [deleting, setDeleting] = useState124(false);
|
|
72560
|
+
const deletingIdRef = useRef58(null);
|
|
72395
72561
|
const refresh = useCallback67(() => {
|
|
72396
72562
|
setLoading(true);
|
|
72397
72563
|
setFeedback(null);
|
|
72398
72564
|
ws.listSageMemories({ echoToChat: false });
|
|
72399
72565
|
}, [ws.listSageMemories]);
|
|
72400
|
-
|
|
72566
|
+
useEffect112(() => {
|
|
72401
72567
|
const client2 = ws.client;
|
|
72402
72568
|
const unsubList = client2.on("memory.sage.list", (msg) => {
|
|
72403
72569
|
const payload = msg.payload;
|
|
@@ -72884,12 +73050,12 @@ function CreateAudienceMemoryDialog({
|
|
|
72884
73050
|
onCreate
|
|
72885
73051
|
}) {
|
|
72886
73052
|
const { t } = useTranslation();
|
|
72887
|
-
const [text4, setText] =
|
|
72888
|
-
const [kind, setKind] =
|
|
72889
|
-
const [roles, setRoles] =
|
|
72890
|
-
const [taskTypes, setTaskTypes] =
|
|
72891
|
-
const [modes, setModes] =
|
|
72892
|
-
|
|
73053
|
+
const [text4, setText] = useState124("");
|
|
73054
|
+
const [kind, setKind] = useState124("workflow");
|
|
73055
|
+
const [roles, setRoles] = useState124("");
|
|
73056
|
+
const [taskTypes, setTaskTypes] = useState124("");
|
|
73057
|
+
const [modes, setModes] = useState124("");
|
|
73058
|
+
useEffect112(() => {
|
|
72893
73059
|
if (open) return;
|
|
72894
73060
|
setText("");
|
|
72895
73061
|
setKind("workflow");
|
|
@@ -73016,8 +73182,8 @@ function ImportAudienceMemoryDialog({
|
|
|
73016
73182
|
onImport
|
|
73017
73183
|
}) {
|
|
73018
73184
|
const { t } = useTranslation();
|
|
73019
|
-
const [raw, setRaw] =
|
|
73020
|
-
|
|
73185
|
+
const [raw, setRaw] = useState124("");
|
|
73186
|
+
useEffect112(() => {
|
|
73021
73187
|
if (!open) setRaw("");
|
|
73022
73188
|
}, [open]);
|
|
73023
73189
|
return /* @__PURE__ */ jsx218(Dialog, { open, onOpenChange, children: /* @__PURE__ */ jsxs208(DialogContent, { className: "max-w-xl", children: [
|
|
@@ -73179,7 +73345,7 @@ var RequirementIntakeView_exports = {};
|
|
|
73179
73345
|
__export(RequirementIntakeView_exports, {
|
|
73180
73346
|
RequirementIntakeView: () => RequirementIntakeView
|
|
73181
73347
|
});
|
|
73182
|
-
import { useCallback as useCallback68, useEffect as
|
|
73348
|
+
import { useCallback as useCallback68, useEffect as useEffect113, useState as useState125 } from "react";
|
|
73183
73349
|
import { jsx as jsx220, jsxs as jsxs210 } from "react/jsx-runtime";
|
|
73184
73350
|
function relativeTime2(timestamp2) {
|
|
73185
73351
|
const elapsedMs2 = Date.now() - timestamp2;
|
|
@@ -73193,17 +73359,17 @@ function relativeTime2(timestamp2) {
|
|
|
73193
73359
|
}
|
|
73194
73360
|
function RequirementIntakeView() {
|
|
73195
73361
|
const { t } = useTranslation();
|
|
73196
|
-
const [projectId, setProjectId] =
|
|
73197
|
-
const [intakes, setIntakes] =
|
|
73198
|
-
const [loading, setLoading] =
|
|
73199
|
-
const [error, setError] =
|
|
73200
|
-
const [request, setRequest] =
|
|
73201
|
-
const [title, setTitle] =
|
|
73202
|
-
const [requestType, setRequestType] =
|
|
73203
|
-
const [priority, setPriority] =
|
|
73204
|
-
const [submitting, setSubmitting] =
|
|
73205
|
-
const [formError, setFormError] =
|
|
73206
|
-
const [formNotice, setFormNotice] =
|
|
73362
|
+
const [projectId, setProjectId] = useState125(null);
|
|
73363
|
+
const [intakes, setIntakes] = useState125([]);
|
|
73364
|
+
const [loading, setLoading] = useState125(true);
|
|
73365
|
+
const [error, setError] = useState125(null);
|
|
73366
|
+
const [request, setRequest] = useState125("");
|
|
73367
|
+
const [title, setTitle] = useState125("");
|
|
73368
|
+
const [requestType, setRequestType] = useState125("unspecified");
|
|
73369
|
+
const [priority, setPriority] = useState125("unspecified");
|
|
73370
|
+
const [submitting, setSubmitting] = useState125(false);
|
|
73371
|
+
const [formError, setFormError] = useState125(null);
|
|
73372
|
+
const [formNotice, setFormNotice] = useState125(null);
|
|
73207
73373
|
const load = useCallback68(async () => {
|
|
73208
73374
|
setLoading(true);
|
|
73209
73375
|
setError(null);
|
|
@@ -73222,7 +73388,7 @@ function RequirementIntakeView() {
|
|
|
73222
73388
|
setLoading(false);
|
|
73223
73389
|
}
|
|
73224
73390
|
}, []);
|
|
73225
|
-
|
|
73391
|
+
useEffect113(() => {
|
|
73226
73392
|
void load();
|
|
73227
73393
|
}, [load]);
|
|
73228
73394
|
const submit = useCallback68(async () => {
|
|
@@ -73550,7 +73716,7 @@ var init_SddActivityFeed = __esm({
|
|
|
73550
73716
|
|
|
73551
73717
|
// src/components/SddDestroyDialog.tsx
|
|
73552
73718
|
import { AlertTriangle as AlertTriangle29, Loader2 as Loader239, Trash2 as Trash222 } from "lucide-react";
|
|
73553
|
-
import { useEffect as
|
|
73719
|
+
import { useEffect as useEffect114, useMemo as useMemo66, useState as useState126 } from "react";
|
|
73554
73720
|
import { Fragment as Fragment56, jsx as jsx222, jsxs as jsxs212 } from "react/jsx-runtime";
|
|
73555
73721
|
function SddDestroyDialog({
|
|
73556
73722
|
open,
|
|
@@ -73562,8 +73728,8 @@ function SddDestroyDialog({
|
|
|
73562
73728
|
const { t } = useTranslation();
|
|
73563
73729
|
const mergedCount = snapshot?.mergedCommits?.length ?? 0;
|
|
73564
73730
|
const baseBranch = snapshot?.baseBranch;
|
|
73565
|
-
const [revertMerged, setRevertMerged] =
|
|
73566
|
-
|
|
73731
|
+
const [revertMerged, setRevertMerged] = useState126(false);
|
|
73732
|
+
useEffect114(() => {
|
|
73567
73733
|
if (open) setRevertMerged(false);
|
|
73568
73734
|
}, [open]);
|
|
73569
73735
|
const isActive = snapshot?.status === "running" || snapshot?.status === "paused";
|
|
@@ -73821,7 +73987,7 @@ import {
|
|
|
73821
73987
|
UserCog as UserCog2,
|
|
73822
73988
|
X as X49
|
|
73823
73989
|
} from "lucide-react";
|
|
73824
|
-
import { useMemo as useMemo68, useState as
|
|
73990
|
+
import { useMemo as useMemo68, useState as useState127 } from "react";
|
|
73825
73991
|
import { jsx as jsx224, jsxs as jsxs214 } from "react/jsx-runtime";
|
|
73826
73992
|
function SddTaskDrawer({
|
|
73827
73993
|
task,
|
|
@@ -73847,13 +74013,13 @@ function SddTaskDrawer({
|
|
|
73847
74013
|
const StatusIcon2 = s.icon;
|
|
73848
74014
|
const running = task.displayStatus === "in_progress";
|
|
73849
74015
|
const deletable = task.displayStatus === "pending" || task.displayStatus === "blocked" || task.displayStatus === "queued";
|
|
73850
|
-
const [reassigning, setReassigning] =
|
|
73851
|
-
const [reassignName, setReassignName] =
|
|
73852
|
-
const [confirm, setConfirm] =
|
|
73853
|
-
const [splitting, setSplitting] =
|
|
73854
|
-
const [splitText, setSplitText] =
|
|
73855
|
-
const [verifyEditing, setVerifyEditing] =
|
|
73856
|
-
const [verifyText, setVerifyText] =
|
|
74016
|
+
const [reassigning, setReassigning] = useState127(false);
|
|
74017
|
+
const [reassignName, setReassignName] = useState127("");
|
|
74018
|
+
const [confirm, setConfirm] = useState127(null);
|
|
74019
|
+
const [splitting, setSplitting] = useState127(false);
|
|
74020
|
+
const [splitText, setSplitText] = useState127("");
|
|
74021
|
+
const [verifyEditing, setVerifyEditing] = useState127(false);
|
|
74022
|
+
const [verifyText, setVerifyText] = useState127(task.verificationCommand ?? "");
|
|
73857
74023
|
const submitReassign = () => {
|
|
73858
74024
|
if (reassignName.trim()) {
|
|
73859
74025
|
onReassign(task.id, reassignName.trim());
|
|
@@ -74438,7 +74604,7 @@ import {
|
|
|
74438
74604
|
XCircle as XCircle10,
|
|
74439
74605
|
Zap as Zap21
|
|
74440
74606
|
} from "lucide-react";
|
|
74441
|
-
import { useCallback as useCallback69, useEffect as
|
|
74607
|
+
import { useCallback as useCallback69, useEffect as useEffect115, useMemo as useMemo69, useRef as useRef59, useState as useState128 } from "react";
|
|
74442
74608
|
import { Fragment as Fragment57, jsx as jsx225, jsxs as jsxs215 } from "react/jsx-runtime";
|
|
74443
74609
|
function SddBoardView({ onClose }) {
|
|
74444
74610
|
const { t } = useTranslation();
|
|
@@ -74448,16 +74614,16 @@ function SddBoardView({ onClose }) {
|
|
|
74448
74614
|
const destroying = useSddBoardStore((s) => s.destroying);
|
|
74449
74615
|
const setDestroying = useSddBoardStore((s) => s.setDestroying);
|
|
74450
74616
|
const setLifecycleResult = useSddBoardStore((s) => s.setLifecycleResult);
|
|
74451
|
-
const [now, setNow] =
|
|
74452
|
-
const [selectedTaskId, setSelectedTaskId] =
|
|
74453
|
-
const [taskDetailExpanded, setTaskDetailExpanded] =
|
|
74454
|
-
const [viewMode, setViewMode] =
|
|
74455
|
-
const [destroyOpen, setDestroyOpen] =
|
|
74456
|
-
|
|
74617
|
+
const [now, setNow] = useState128(() => Date.now());
|
|
74618
|
+
const [selectedTaskId, setSelectedTaskId] = useState128(null);
|
|
74619
|
+
const [taskDetailExpanded, setTaskDetailExpanded] = useState128(false);
|
|
74620
|
+
const [viewMode, setViewMode] = useState128("graph");
|
|
74621
|
+
const [destroyOpen, setDestroyOpen] = useState128(false);
|
|
74622
|
+
useEffect115(() => {
|
|
74457
74623
|
client2?.send?.({ type: "sdd.board.get" });
|
|
74458
74624
|
}, [client2]);
|
|
74459
74625
|
const active = snapshot && (snapshot.status === "running" || snapshot.status === "paused");
|
|
74460
|
-
|
|
74626
|
+
useEffect115(() => {
|
|
74461
74627
|
if (!active) return;
|
|
74462
74628
|
const id = setInterval(() => setNow(Date.now()), 1e3);
|
|
74463
74629
|
setNow(Date.now());
|
|
@@ -74467,7 +74633,7 @@ function SddBoardView({ onClose }) {
|
|
|
74467
74633
|
(msg) => client2?.send?.(msg),
|
|
74468
74634
|
[client2]
|
|
74469
74635
|
);
|
|
74470
|
-
const pendingDestroy =
|
|
74636
|
+
const pendingDestroy = useRef59(null);
|
|
74471
74637
|
const fireDestroy = useCallback69(
|
|
74472
74638
|
(revertMerged) => {
|
|
74473
74639
|
pendingDestroy.current = null;
|
|
@@ -74489,7 +74655,7 @@ function SddBoardView({ onClose }) {
|
|
|
74489
74655
|
},
|
|
74490
74656
|
[active, send, fireDestroy, setDestroying, setLifecycleResult]
|
|
74491
74657
|
);
|
|
74492
|
-
|
|
74658
|
+
useEffect115(() => {
|
|
74493
74659
|
const pending = pendingDestroy.current;
|
|
74494
74660
|
if (!pending) return;
|
|
74495
74661
|
if (!active || Date.now() >= pending.deadline) {
|
|
@@ -75005,7 +75171,7 @@ import {
|
|
|
75005
75171
|
User as User5,
|
|
75006
75172
|
X as X51
|
|
75007
75173
|
} from "lucide-react";
|
|
75008
|
-
import { useCallback as useCallback70, useEffect as
|
|
75174
|
+
import { useCallback as useCallback70, useEffect as useEffect116, useMemo as useMemo70, useRef as useRef60, useState as useState129 } from "react";
|
|
75009
75175
|
import { Fragment as Fragment58, jsx as jsx226, jsxs as jsxs216 } from "react/jsx-runtime";
|
|
75010
75176
|
function SddWizard({
|
|
75011
75177
|
onClose,
|
|
@@ -75018,32 +75184,32 @@ function SddWizard({
|
|
|
75018
75184
|
const error = useSddWizardStore((s) => s.error);
|
|
75019
75185
|
const startedRunId = useSddWizardStore((s) => s.startedRunId);
|
|
75020
75186
|
const setStartedRunId = useSddWizardStore((s) => s.setStartedRunId);
|
|
75021
|
-
const [goal, setGoal] =
|
|
75022
|
-
const [reply, setReply] =
|
|
75023
|
-
const [submitting, setSubmitting] =
|
|
75024
|
-
const [graphOpen, setGraphOpen] =
|
|
75025
|
-
const [planOpen, setPlanOpen] =
|
|
75026
|
-
const [runCfgOpen, setRunCfgOpen] =
|
|
75027
|
-
const [runModel, setRunModel] =
|
|
75028
|
-
const [runProvider, setRunProvider] =
|
|
75029
|
-
const [runFallbacks, setRunFallbacks] =
|
|
75030
|
-
const [runSlots, setRunSlots] =
|
|
75031
|
-
const [runWorktrees, setRunWorktrees] =
|
|
75032
|
-
const [runPlanDecompose, setRunPlanDecompose] =
|
|
75187
|
+
const [goal, setGoal] = useState129("");
|
|
75188
|
+
const [reply, setReply] = useState129("");
|
|
75189
|
+
const [submitting, setSubmitting] = useState129(false);
|
|
75190
|
+
const [graphOpen, setGraphOpen] = useState129(true);
|
|
75191
|
+
const [planOpen, setPlanOpen] = useState129(true);
|
|
75192
|
+
const [runCfgOpen, setRunCfgOpen] = useState129(false);
|
|
75193
|
+
const [runModel, setRunModel] = useState129(void 0);
|
|
75194
|
+
const [runProvider, setRunProvider] = useState129(void 0);
|
|
75195
|
+
const [runFallbacks, setRunFallbacks] = useState129([]);
|
|
75196
|
+
const [runSlots, setRunSlots] = useState129(4);
|
|
75197
|
+
const [runWorktrees, setRunWorktrees] = useState129(true);
|
|
75198
|
+
const [runPlanDecompose, setRunPlanDecompose] = useState129(false);
|
|
75033
75199
|
const modelCandidates = useProviderModels(runCfgOpen);
|
|
75034
75200
|
const send = useCallback70(
|
|
75035
75201
|
(msg) => client2?.send?.(msg),
|
|
75036
75202
|
[client2]
|
|
75037
75203
|
);
|
|
75038
|
-
const bottomRef =
|
|
75039
|
-
|
|
75204
|
+
const bottomRef = useRef60(null);
|
|
75205
|
+
useEffect116(() => {
|
|
75040
75206
|
send({ type: "sdd.spec.get" });
|
|
75041
75207
|
}, [send]);
|
|
75042
75208
|
const answerCount = snapshot?.answers.length ?? 0;
|
|
75043
|
-
|
|
75209
|
+
useEffect116(() => {
|
|
75044
75210
|
bottomRef.current?.scrollIntoView({ behavior: "smooth", block: "end" });
|
|
75045
75211
|
}, [answerCount, agentText]);
|
|
75046
|
-
|
|
75212
|
+
useEffect116(() => {
|
|
75047
75213
|
if (!startedRunId) return;
|
|
75048
75214
|
setStartedRunId(null);
|
|
75049
75215
|
onRunStarted?.();
|
|
@@ -75053,7 +75219,7 @@ function SddWizard({
|
|
|
75053
75219
|
const started = Boolean(snapshot?.sessionId);
|
|
75054
75220
|
const resumed = Boolean(snapshot?.resumed);
|
|
75055
75221
|
const priorRunId = snapshot?.lastRunId;
|
|
75056
|
-
|
|
75222
|
+
useEffect116(() => {
|
|
75057
75223
|
if (started) setSubmitting(false);
|
|
75058
75224
|
}, [started]);
|
|
75059
75225
|
const lastQuestion = snapshot?.answers[snapshot.answers.length - 1]?.question ?? "";
|
|
@@ -75587,7 +75753,7 @@ var SpecsView_exports = {};
|
|
|
75587
75753
|
__export(SpecsView_exports, {
|
|
75588
75754
|
SpecsView: () => SpecsView
|
|
75589
75755
|
});
|
|
75590
|
-
import { useCallback as useCallback71, useEffect as
|
|
75756
|
+
import { useCallback as useCallback71, useEffect as useEffect117, useState as useState130 } from "react";
|
|
75591
75757
|
import { ChevronDown as ChevronDown34, ChevronRight as ChevronRight24, FileText as FileText17, LayoutList, Network as Network8, Play as Play9, X as X52 } from "lucide-react";
|
|
75592
75758
|
import { jsx as jsx228, jsxs as jsxs218 } from "react/jsx-runtime";
|
|
75593
75759
|
function detailToPhases(detail) {
|
|
@@ -75616,7 +75782,7 @@ function SpecsView({
|
|
|
75616
75782
|
const detail = useSpecsStore((s) => s.detail);
|
|
75617
75783
|
const expandedSpecId = useSpecsStore((s) => s.expandedSpecId);
|
|
75618
75784
|
const setExpanded = useSpecsStore((s) => s.setExpanded);
|
|
75619
|
-
const [mode, setMode] =
|
|
75785
|
+
const [mode, setMode] = useState130("graph");
|
|
75620
75786
|
const runSpecAsGoal = useCallback71(
|
|
75621
75787
|
(spec) => {
|
|
75622
75788
|
if (!detail || detail.specId !== spec.id) return;
|
|
@@ -75647,7 +75813,7 @@ function SpecsView({
|
|
|
75647
75813
|
},
|
|
75648
75814
|
[detail, client2, onRunStarted]
|
|
75649
75815
|
);
|
|
75650
|
-
|
|
75816
|
+
useEffect117(() => {
|
|
75651
75817
|
client2?.send?.({ type: "specs.list" });
|
|
75652
75818
|
}, [client2]);
|
|
75653
75819
|
const toggle = useCallback71(
|
|
@@ -75828,16 +75994,16 @@ var SddHub_exports = {};
|
|
|
75828
75994
|
__export(SddHub_exports, {
|
|
75829
75995
|
SddHub: () => SddHub
|
|
75830
75996
|
});
|
|
75831
|
-
import { useCallback as useCallback72, useEffect as
|
|
75997
|
+
import { useCallback as useCallback72, useEffect as useEffect118, useState as useState131 } from "react";
|
|
75832
75998
|
import { jsx as jsx229, jsxs as jsxs219 } from "react/jsx-runtime";
|
|
75833
75999
|
function SddHub() {
|
|
75834
76000
|
const { t } = useTranslation();
|
|
75835
|
-
const [activeTab, setActiveTab] =
|
|
76001
|
+
const [activeTab, setActiveTab] = useState131("project");
|
|
75836
76002
|
const startedRunId = useSddWizardStore((s) => s.startedRunId);
|
|
75837
76003
|
const setStartedRunId = useSddWizardStore((s) => s.setStartedRunId);
|
|
75838
76004
|
const onClose = () => showPanel("chat");
|
|
75839
76005
|
const showBoard = useCallback72(() => setActiveTab("board"), []);
|
|
75840
|
-
|
|
76006
|
+
useEffect118(() => {
|
|
75841
76007
|
if (!startedRunId) return;
|
|
75842
76008
|
setActiveTab("board");
|
|
75843
76009
|
setStartedRunId(null);
|
|
@@ -75965,7 +76131,7 @@ import {
|
|
|
75965
76131
|
Wrench as Wrench14,
|
|
75966
76132
|
X as X53
|
|
75967
76133
|
} from "lucide-react";
|
|
75968
|
-
import { useCallback as useCallback73, useEffect as
|
|
76134
|
+
import { useCallback as useCallback73, useEffect as useEffect119, useMemo as useMemo71, useRef as useRef61, useState as useState132 } from "react";
|
|
75969
76135
|
import { jsx as jsx230, jsxs as jsxs220 } from "react/jsx-runtime";
|
|
75970
76136
|
function formatSessionDuration(entry) {
|
|
75971
76137
|
const start = timestamp(entry.startedAt);
|
|
@@ -76182,14 +76348,14 @@ function SessionList({
|
|
|
76182
76348
|
const sessionNicknames = useUIStore((state) => state.sessionNicknames);
|
|
76183
76349
|
const setSessionNickname = useUIStore((state) => state.setSessionNickname);
|
|
76184
76350
|
const setInspectSession = useUIStore((state) => state.setInspectSession);
|
|
76185
|
-
const [filter, setFilter] =
|
|
76186
|
-
const [sort, setSort] =
|
|
76187
|
-
const [renamingId, setRenamingId] =
|
|
76188
|
-
const [renameDraft, setRenameDraft] =
|
|
76189
|
-
const [resumingId, setResumingId] =
|
|
76190
|
-
const [page, setPage] =
|
|
76191
|
-
const resumeTimer =
|
|
76192
|
-
const renameInput =
|
|
76351
|
+
const [filter, setFilter] = useState132("all");
|
|
76352
|
+
const [sort, setSort] = useState132("recent");
|
|
76353
|
+
const [renamingId, setRenamingId] = useState132(null);
|
|
76354
|
+
const [renameDraft, setRenameDraft] = useState132("");
|
|
76355
|
+
const [resumingId, setResumingId] = useState132(null);
|
|
76356
|
+
const [page, setPage] = useState132(1);
|
|
76357
|
+
const resumeTimer = useRef61(null);
|
|
76358
|
+
const renameInput = useRef61(null);
|
|
76193
76359
|
const workspace = variant === "workspace";
|
|
76194
76360
|
const displayName2 = useCallback73(
|
|
76195
76361
|
(entry) => entry.name || sessionNicknames[entry.id] || entry.title || t("activity:sessions.empty"),
|
|
@@ -76210,18 +76376,18 @@ function SessionList({
|
|
|
76210
76376
|
},
|
|
76211
76377
|
[renameDraft, renameSession, setSessionNickname]
|
|
76212
76378
|
);
|
|
76213
|
-
|
|
76379
|
+
useEffect119(() => {
|
|
76214
76380
|
if (resumingId && historyEntries.some((entry) => entry.id === resumingId && entry.isCurrent)) {
|
|
76215
76381
|
setResumingId(null);
|
|
76216
76382
|
if (resumeTimer.current) clearTimeout(resumeTimer.current);
|
|
76217
76383
|
}
|
|
76218
76384
|
}, [historyEntries, resumingId]);
|
|
76219
|
-
|
|
76385
|
+
useEffect119(() => {
|
|
76220
76386
|
if (!renamingId) return;
|
|
76221
76387
|
renameInput.current?.focus();
|
|
76222
76388
|
renameInput.current?.select();
|
|
76223
76389
|
}, [renamingId]);
|
|
76224
|
-
|
|
76390
|
+
useEffect119(
|
|
76225
76391
|
() => () => {
|
|
76226
76392
|
if (resumeTimer.current) clearTimeout(resumeTimer.current);
|
|
76227
76393
|
},
|
|
@@ -76256,10 +76422,10 @@ function SessionList({
|
|
|
76256
76422
|
[favoriteSessionIds, pagedEntries]
|
|
76257
76423
|
);
|
|
76258
76424
|
const stats = useMemo71(() => getSessionHistoryStats(historyEntries), [historyEntries]);
|
|
76259
|
-
|
|
76425
|
+
useEffect119(() => {
|
|
76260
76426
|
setPage(1);
|
|
76261
76427
|
}, [filter, historyQuery, sort]);
|
|
76262
|
-
|
|
76428
|
+
useEffect119(() => {
|
|
76263
76429
|
const totalPages = Math.max(1, Math.ceil(visibleEntries.length / pageSize));
|
|
76264
76430
|
if (page > totalPages) setPage(totalPages);
|
|
76265
76431
|
}, [page, pageSize, visibleEntries.length]);
|
|
@@ -76713,7 +76879,7 @@ import {
|
|
|
76713
76879
|
Wifi as Wifi5,
|
|
76714
76880
|
WifiOff as WifiOff4
|
|
76715
76881
|
} from "lucide-react";
|
|
76716
|
-
import { useCallback as useCallback74, useEffect as
|
|
76882
|
+
import { useCallback as useCallback74, useEffect as useEffect120, useState as useState133 } from "react";
|
|
76717
76883
|
import { useShallow as useShallow15 } from "zustand/react/shallow";
|
|
76718
76884
|
import { jsx as jsx231, jsxs as jsxs221 } from "react/jsx-runtime";
|
|
76719
76885
|
async function sessionApiError(res) {
|
|
@@ -76827,8 +76993,8 @@ function HistoryWorkspace() {
|
|
|
76827
76993
|
}))
|
|
76828
76994
|
);
|
|
76829
76995
|
const { listSessions, resumeSession, deleteSession, renameSession } = useWebSocket();
|
|
76830
|
-
const [query, setQuery] =
|
|
76831
|
-
|
|
76996
|
+
const [query, setQuery] = useState133("");
|
|
76997
|
+
useEffect120(() => {
|
|
76832
76998
|
void activeSessionId;
|
|
76833
76999
|
if (wsConnected) listSessions(200);
|
|
76834
77000
|
}, [activeSessionId, listSessions, wsConnected]);
|
|
@@ -76896,10 +77062,10 @@ function SessionsDashboard() {
|
|
|
76896
77062
|
}
|
|
76897
77063
|
function LiveSessionsDashboard() {
|
|
76898
77064
|
const { t } = useTranslation();
|
|
76899
|
-
const [sessions, setSessions] =
|
|
76900
|
-
const [loading, setLoading] =
|
|
76901
|
-
const [error, setError] =
|
|
76902
|
-
const [page, setPage] =
|
|
77065
|
+
const [sessions, setSessions] = useState133([]);
|
|
77066
|
+
const [loading, setLoading] = useState133(true);
|
|
77067
|
+
const [error, setError] = useState133(null);
|
|
77068
|
+
const [page, setPage] = useState133(1);
|
|
76903
77069
|
const scrollRef = useScrollPosition(
|
|
76904
77070
|
"sessions",
|
|
76905
77071
|
!loading && !error && sessions.length > 0
|
|
@@ -76955,7 +77121,7 @@ function LiveSessionsDashboard() {
|
|
|
76955
77121
|
setLoading(false);
|
|
76956
77122
|
}
|
|
76957
77123
|
}, []);
|
|
76958
|
-
|
|
77124
|
+
useEffect120(() => {
|
|
76959
77125
|
void fetchSessions();
|
|
76960
77126
|
const t2 = setInterval(fetchSessions, 5e3);
|
|
76961
77127
|
return () => clearInterval(t2);
|
|
@@ -76966,7 +77132,7 @@ function LiveSessionsDashboard() {
|
|
|
76966
77132
|
(page - 1) * LIVE_SESSION_PAGE_SIZE,
|
|
76967
77133
|
page * LIVE_SESSION_PAGE_SIZE
|
|
76968
77134
|
);
|
|
76969
|
-
|
|
77135
|
+
useEffect120(() => {
|
|
76970
77136
|
const totalPages = Math.max(1, Math.ceil(sessions.length / LIVE_SESSION_PAGE_SIZE));
|
|
76971
77137
|
if (page > totalPages) setPage(totalPages);
|
|
76972
77138
|
}, [page, sessions.length]);
|
|
@@ -77180,7 +77346,7 @@ import {
|
|
|
77180
77346
|
Wrench as Wrench15,
|
|
77181
77347
|
XCircle as XCircle12
|
|
77182
77348
|
} from "lucide-react";
|
|
77183
|
-
import { useCallback as useCallback75, useEffect as
|
|
77349
|
+
import { useCallback as useCallback75, useEffect as useEffect121, useMemo as useMemo72, useState as useState134 } from "react";
|
|
77184
77350
|
import { jsx as jsx232, jsxs as jsxs222 } from "react/jsx-runtime";
|
|
77185
77351
|
function eventColor2(type) {
|
|
77186
77352
|
switch (type) {
|
|
@@ -77223,17 +77389,17 @@ function SessionInspectView() {
|
|
|
77223
77389
|
const { inspectSession } = useWebSocket();
|
|
77224
77390
|
const wsConnected = useConfigStore((s) => s.wsConnected);
|
|
77225
77391
|
const { payload, loading, error, clear: clearPayload } = useSessionInspectStore();
|
|
77226
|
-
const [eventFilter, setEventFilter] =
|
|
77227
|
-
const [timelineCollapsed, setTimelineCollapsed] =
|
|
77228
|
-
|
|
77392
|
+
const [eventFilter, setEventFilter] = useState134("");
|
|
77393
|
+
const [timelineCollapsed, setTimelineCollapsed] = useState134(false);
|
|
77394
|
+
useEffect121(() => {
|
|
77229
77395
|
ensureInspectHandlerInstalled();
|
|
77230
77396
|
}, []);
|
|
77231
|
-
|
|
77397
|
+
useEffect121(() => {
|
|
77232
77398
|
if (!inspectSessionId) return;
|
|
77233
77399
|
useSessionInspectStore.getState().setLoading(true);
|
|
77234
77400
|
inspectSession(inspectSessionId);
|
|
77235
77401
|
}, [inspectSessionId, inspectSession]);
|
|
77236
|
-
|
|
77402
|
+
useEffect121(() => {
|
|
77237
77403
|
return () => clearPayload();
|
|
77238
77404
|
}, [clearPayload]);
|
|
77239
77405
|
const handleBack = useCallback75(() => {
|
|
@@ -77637,7 +77803,7 @@ import {
|
|
|
77637
77803
|
PanelRight as PanelRight2,
|
|
77638
77804
|
BookOpen as BookOpen4
|
|
77639
77805
|
} from "lucide-react";
|
|
77640
|
-
import { lazy as lazy4, Suspense as Suspense4, useCallback as useCallback76, useEffect as
|
|
77806
|
+
import { lazy as lazy4, Suspense as Suspense4, useCallback as useCallback76, useEffect as useEffect122, useMemo as useMemo73, useRef as useRef62, useState as useState135 } from "react";
|
|
77641
77807
|
import rehypeHighlight2 from "rehype-highlight";
|
|
77642
77808
|
import { jsx as jsx233, jsxs as jsxs223 } from "react/jsx-runtime";
|
|
77643
77809
|
function isWritableSkillSource(source) {
|
|
@@ -77672,27 +77838,27 @@ function SkillDetailView({ className }) {
|
|
|
77672
77838
|
const selectedSkill = skillsState.selectedSkill;
|
|
77673
77839
|
const navHistory = skillsState.navHistory;
|
|
77674
77840
|
const historyIndex = skillsState.historyIndex;
|
|
77675
|
-
const [skillContent, setSkillContent] =
|
|
77676
|
-
const [contentLoading, setContentLoading] =
|
|
77677
|
-
const [contentError, setContentError] =
|
|
77841
|
+
const [skillContent, setSkillContent] = useState135(null);
|
|
77842
|
+
const [contentLoading, setContentLoading] = useState135(false);
|
|
77843
|
+
const [contentError, setContentError] = useState135(null);
|
|
77678
77844
|
const skillScrollRef = useScrollPosition("skill-detail", Boolean(skillContent));
|
|
77679
|
-
const [editMode, setEditMode] =
|
|
77680
|
-
const [editContent, setEditContent] =
|
|
77681
|
-
const [editSaving, setEditSaving] =
|
|
77682
|
-
const [editError, setEditError] =
|
|
77683
|
-
const [splitPreview, setSplitPreview] =
|
|
77684
|
-
const [draftSavedAt, setDraftSavedAt] =
|
|
77685
|
-
const [draftRestored, setDraftRestored] =
|
|
77686
|
-
const lastSavedDraftRef =
|
|
77687
|
-
const [checkingForUpdates, setCheckingForUpdates] =
|
|
77688
|
-
const [updateResult, setUpdateResult] =
|
|
77689
|
-
const [copiedSourceUrl, setCopiedSourceUrl] =
|
|
77690
|
-
const [uninstallConfirmSkill, setUninstallConfirmSkill] =
|
|
77691
|
-
const [uninstalling, setUninstalling] =
|
|
77692
|
-
const [skills, setSkills] =
|
|
77693
|
-
const skillsStateRef =
|
|
77845
|
+
const [editMode, setEditMode] = useState135(false);
|
|
77846
|
+
const [editContent, setEditContent] = useState135("");
|
|
77847
|
+
const [editSaving, setEditSaving] = useState135(false);
|
|
77848
|
+
const [editError, setEditError] = useState135(null);
|
|
77849
|
+
const [splitPreview, setSplitPreview] = useState135(false);
|
|
77850
|
+
const [draftSavedAt, setDraftSavedAt] = useState135(null);
|
|
77851
|
+
const [draftRestored, setDraftRestored] = useState135(false);
|
|
77852
|
+
const lastSavedDraftRef = useRef62("");
|
|
77853
|
+
const [checkingForUpdates, setCheckingForUpdates] = useState135(false);
|
|
77854
|
+
const [updateResult, setUpdateResult] = useState135(null);
|
|
77855
|
+
const [copiedSourceUrl, setCopiedSourceUrl] = useState135(false);
|
|
77856
|
+
const [uninstallConfirmSkill, setUninstallConfirmSkill] = useState135(null);
|
|
77857
|
+
const [uninstalling, setUninstalling] = useState135(false);
|
|
77858
|
+
const [skills, setSkills] = useState135([]);
|
|
77859
|
+
const skillsStateRef = useRef62(skillsState);
|
|
77694
77860
|
skillsStateRef.current = skillsState;
|
|
77695
|
-
const isNavigatingBack =
|
|
77861
|
+
const isNavigatingBack = useRef62(false);
|
|
77696
77862
|
const editStats = useMemo73(() => {
|
|
77697
77863
|
if (!editContent) return { lines: 0, words: 0, chars: 0 };
|
|
77698
77864
|
const lines = editContent.split("\n").length;
|
|
@@ -77709,12 +77875,12 @@ function SkillDetailView({ className }) {
|
|
|
77709
77875
|
if (sizeBytes >= SOFT_LIMIT) return { level: "warn", used: sizeBytes, limit: LOCALSTORAGE_LIMIT };
|
|
77710
77876
|
return null;
|
|
77711
77877
|
}, [editContent]);
|
|
77712
|
-
|
|
77878
|
+
useEffect122(() => {
|
|
77713
77879
|
if (!draftSavedAt) return;
|
|
77714
77880
|
const t2 = setTimeout(() => setDraftSavedAt(null), 2e3);
|
|
77715
77881
|
return () => clearTimeout(t2);
|
|
77716
77882
|
}, [draftSavedAt]);
|
|
77717
|
-
|
|
77883
|
+
useEffect122(() => {
|
|
77718
77884
|
if (!editMode || !selectedSkill) return;
|
|
77719
77885
|
const interval = setInterval(() => {
|
|
77720
77886
|
if (editContent && editContent !== lastSavedDraftRef.current) {
|
|
@@ -77728,7 +77894,7 @@ function SkillDetailView({ className }) {
|
|
|
77728
77894
|
}, 5e3);
|
|
77729
77895
|
return () => clearInterval(interval);
|
|
77730
77896
|
}, [editMode, editContent, selectedSkill]);
|
|
77731
|
-
|
|
77897
|
+
useEffect122(() => {
|
|
77732
77898
|
if (!selectedSkill || !editMode) return;
|
|
77733
77899
|
const raw = localStorage.getItem(`skills_draft_${selectedSkill.name}`);
|
|
77734
77900
|
if (raw) {
|
|
@@ -77743,7 +77909,7 @@ function SkillDetailView({ className }) {
|
|
|
77743
77909
|
}
|
|
77744
77910
|
}
|
|
77745
77911
|
}, [selectedSkill?.name, editMode]);
|
|
77746
|
-
|
|
77912
|
+
useEffect122(() => {
|
|
77747
77913
|
if (!client2 || !selectedSkill) return;
|
|
77748
77914
|
setContentLoading(true);
|
|
77749
77915
|
setSkillContent(null);
|
|
@@ -77801,7 +77967,7 @@ function SkillDetailView({ className }) {
|
|
|
77801
77967
|
client2.off("skills.list", handleSkillsList2);
|
|
77802
77968
|
};
|
|
77803
77969
|
}, [client2, selectedSkill?.name, selectedSkill?.source]);
|
|
77804
|
-
|
|
77970
|
+
useEffect122(() => {
|
|
77805
77971
|
if (editMode) {
|
|
77806
77972
|
setEditMode(false);
|
|
77807
77973
|
setEditContent("");
|
|
@@ -79112,7 +79278,7 @@ __export(TechStackView_exports, {
|
|
|
79112
79278
|
TechStackView: () => TechStackView
|
|
79113
79279
|
});
|
|
79114
79280
|
import { Boxes as Boxes2, Download as Download10, Loader2 as Loader248, RefreshCw as RefreshCw27, Sparkles as Sparkles20, X as X56 } from "lucide-react";
|
|
79115
|
-
import { useCallback as useCallback77, useEffect as
|
|
79281
|
+
import { useCallback as useCallback77, useEffect as useEffect123, useMemo as useMemo74, useState as useState136 } from "react";
|
|
79116
79282
|
import { Fragment as Fragment61, jsx as jsx239, jsxs as jsxs229 } from "react/jsx-runtime";
|
|
79117
79283
|
function TechStackView() {
|
|
79118
79284
|
const { t } = useTranslation();
|
|
@@ -79121,19 +79287,19 @@ function TechStackView() {
|
|
|
79121
79287
|
const loading = useTechStackStore((state) => state.loading);
|
|
79122
79288
|
const error = useTechStackStore((state) => state.error);
|
|
79123
79289
|
const activeJob = useTechStackStore((state) => state.activeJob);
|
|
79124
|
-
const [tab, setTab] =
|
|
79125
|
-
const [searchQuery, setSearchQuery] =
|
|
79126
|
-
const [ecosystemFilter, setEcosystemFilter] =
|
|
79127
|
-
const [statusFilter, setStatusFilter] =
|
|
79128
|
-
const [directOnly, setDirectOnly] =
|
|
79129
|
-
const [sort, setSort] =
|
|
79130
|
-
const [selectedId, setSelectedId] =
|
|
79131
|
-
const [deepDiveFindings, setDeepDiveFindings] =
|
|
79132
|
-
const [deepDive, setDeepDive] =
|
|
79133
|
-
const [trend, setTrend] =
|
|
79134
|
-
const [remediation, setRemediation] =
|
|
79135
|
-
const [approvedDependencies, setApprovedDependencies] =
|
|
79136
|
-
const [applying, setApplying] =
|
|
79290
|
+
const [tab, setTab] = useState136("dependencies");
|
|
79291
|
+
const [searchQuery, setSearchQuery] = useState136("");
|
|
79292
|
+
const [ecosystemFilter, setEcosystemFilter] = useState136("all");
|
|
79293
|
+
const [statusFilter, setStatusFilter] = useState136("all");
|
|
79294
|
+
const [directOnly, setDirectOnly] = useState136(false);
|
|
79295
|
+
const [sort, setSort] = useState136("attention");
|
|
79296
|
+
const [selectedId, setSelectedId] = useState136(null);
|
|
79297
|
+
const [deepDiveFindings, setDeepDiveFindings] = useState136([]);
|
|
79298
|
+
const [deepDive, setDeepDive] = useState136({ status: "idle", error: null });
|
|
79299
|
+
const [trend, setTrend] = useState136(null);
|
|
79300
|
+
const [remediation, setRemediation] = useState136(null);
|
|
79301
|
+
const [approvedDependencies, setApprovedDependencies] = useState136(/* @__PURE__ */ new Set());
|
|
79302
|
+
const [applying, setApplying] = useState136(false);
|
|
79137
79303
|
const fetchSnapshot = useCallback77(async () => {
|
|
79138
79304
|
const store = useTechStackStore.getState();
|
|
79139
79305
|
store.setLoading(true);
|
|
@@ -79197,10 +79363,10 @@ function TechStackView() {
|
|
|
79197
79363
|
});
|
|
79198
79364
|
}
|
|
79199
79365
|
}, []);
|
|
79200
|
-
|
|
79366
|
+
useEffect123(() => {
|
|
79201
79367
|
void fetchSnapshot();
|
|
79202
79368
|
}, [fetchSnapshot]);
|
|
79203
|
-
|
|
79369
|
+
useEffect123(() => {
|
|
79204
79370
|
if (tab !== "trends" && tab !== "remediation") return;
|
|
79205
79371
|
const endpoint = tab === "trends" ? "trends" : "remediation";
|
|
79206
79372
|
void fetch(`/api/techstack/${endpoint}`).then(async (response) => {
|
|
@@ -79231,7 +79397,7 @@ function TechStackView() {
|
|
|
79231
79397
|
setApplying(false);
|
|
79232
79398
|
}
|
|
79233
79399
|
}, [approvedDependencies, startJob]);
|
|
79234
|
-
|
|
79400
|
+
useEffect123(() => {
|
|
79235
79401
|
setDeepDiveFindings([]);
|
|
79236
79402
|
setDeepDive({ status: "idle", error: null });
|
|
79237
79403
|
}, [snapshot?.id]);
|
|
@@ -79743,7 +79909,7 @@ var DeadCodeScanPanel_exports = {};
|
|
|
79743
79909
|
__export(DeadCodeScanPanel_exports, {
|
|
79744
79910
|
DeadCodeScanPanel: () => DeadCodeScanPanel
|
|
79745
79911
|
});
|
|
79746
|
-
import { useCallback as useCallback78, useState as
|
|
79912
|
+
import { useCallback as useCallback78, useState as useState137 } from "react";
|
|
79747
79913
|
import { jsx as jsx240, jsxs as jsxs230 } from "react/jsx-runtime";
|
|
79748
79914
|
async function safeJsonParse(res) {
|
|
79749
79915
|
const raw = await res.text();
|
|
@@ -79759,11 +79925,11 @@ async function safeJsonParse(res) {
|
|
|
79759
79925
|
}
|
|
79760
79926
|
function DeadCodeScanPanel() {
|
|
79761
79927
|
const { t } = useTranslation();
|
|
79762
|
-
const [scanPhase, setScanPhase] =
|
|
79763
|
-
const [planPhase, setPlanPhase] =
|
|
79764
|
-
const [scanResult, setScanResult] =
|
|
79765
|
-
const [actionPlan, setActionPlan] =
|
|
79766
|
-
const [error, setError] =
|
|
79928
|
+
const [scanPhase, setScanPhase] = useState137("idle");
|
|
79929
|
+
const [planPhase, setPlanPhase] = useState137("idle");
|
|
79930
|
+
const [scanResult, setScanResult] = useState137(null);
|
|
79931
|
+
const [actionPlan, setActionPlan] = useState137(null);
|
|
79932
|
+
const [error, setError] = useState137(null);
|
|
79767
79933
|
const handleScan = useCallback78(async () => {
|
|
79768
79934
|
setScanPhase("scanning");
|
|
79769
79935
|
setError(null);
|
|
@@ -80222,17 +80388,17 @@ var init_key_operation = __esm({
|
|
|
80222
80388
|
|
|
80223
80389
|
// src/components/SetupScreen/CustomProviderSection.tsx
|
|
80224
80390
|
import { ChevronRight as ChevronRight26, Loader2 as Loader249, Plus as Plus23 } from "lucide-react";
|
|
80225
|
-
import { useState as
|
|
80391
|
+
import { useState as useState138 } from "react";
|
|
80226
80392
|
import { jsx as jsx241, jsxs as jsxs231 } from "react/jsx-runtime";
|
|
80227
80393
|
function CustomProviderSection({ onKeySaved }) {
|
|
80228
80394
|
const { t } = useTranslation();
|
|
80229
|
-
const [expanded, setExpanded] =
|
|
80230
|
-
const [providerId, setProviderId] =
|
|
80231
|
-
const [family, setFamily] =
|
|
80232
|
-
const [baseUrl, setBaseUrl] =
|
|
80233
|
-
const [key, setKey] =
|
|
80234
|
-
const [isSaving, setIsSaving] =
|
|
80235
|
-
const [models, setModels] =
|
|
80395
|
+
const [expanded, setExpanded] = useState138(false);
|
|
80396
|
+
const [providerId, setProviderId] = useState138("");
|
|
80397
|
+
const [family, setFamily] = useState138("openai-compatible");
|
|
80398
|
+
const [baseUrl, setBaseUrl] = useState138("");
|
|
80399
|
+
const [key, setKey] = useState138("");
|
|
80400
|
+
const [isSaving, setIsSaving] = useState138(false);
|
|
80401
|
+
const [models, setModels] = useState138([]);
|
|
80236
80402
|
const { setFieldRef, handleKeyDown } = useFieldKeyboardNav();
|
|
80237
80403
|
const handleSave = async () => {
|
|
80238
80404
|
if (!providerId.trim()) return;
|
|
@@ -80485,7 +80651,7 @@ import {
|
|
|
80485
80651
|
Loader2 as Loader250,
|
|
80486
80652
|
Share2
|
|
80487
80653
|
} from "lucide-react";
|
|
80488
|
-
import { useEffect as
|
|
80654
|
+
import { useEffect as useEffect124, useState as useState139 } from "react";
|
|
80489
80655
|
import QRCode from "qrcode";
|
|
80490
80656
|
import { Fragment as Fragment62, jsx as jsx242, jsxs as jsxs232 } from "react/jsx-runtime";
|
|
80491
80657
|
function ProviderKeyCard({
|
|
@@ -80496,14 +80662,14 @@ function ProviderKeyCard({
|
|
|
80496
80662
|
probeResult
|
|
80497
80663
|
}) {
|
|
80498
80664
|
const { t } = useTranslation();
|
|
80499
|
-
const [key, setKey] =
|
|
80500
|
-
const [isSaving, setIsSaving] =
|
|
80501
|
-
const [saved, setSaved] =
|
|
80502
|
-
const [showModels, setShowModels] =
|
|
80503
|
-
const [copied, setCopied] =
|
|
80504
|
-
const [shareModalOpen, setShareModalOpen] =
|
|
80505
|
-
const [qrDataUrl, setQrDataUrl] =
|
|
80506
|
-
|
|
80665
|
+
const [key, setKey] = useState139("");
|
|
80666
|
+
const [isSaving, setIsSaving] = useState139(false);
|
|
80667
|
+
const [saved, setSaved] = useState139(!!savedProvider?.apiKeys.some((k) => k.isActive));
|
|
80668
|
+
const [showModels, setShowModels] = useState139(false);
|
|
80669
|
+
const [copied, setCopied] = useState139(false);
|
|
80670
|
+
const [shareModalOpen, setShareModalOpen] = useState139(false);
|
|
80671
|
+
const [qrDataUrl, setQrDataUrl] = useState139(null);
|
|
80672
|
+
useEffect124(() => {
|
|
80507
80673
|
if (shareModalOpen && popular.referral) {
|
|
80508
80674
|
QRCode.toDataURL(popular.referral.url, {
|
|
80509
80675
|
width: 200,
|
|
@@ -80965,7 +81131,7 @@ import {
|
|
|
80965
81131
|
Sparkles as Sparkles21,
|
|
80966
81132
|
Shield as Shield4
|
|
80967
81133
|
} from "lucide-react";
|
|
80968
|
-
import { useCallback as useCallback79, useEffect as
|
|
81134
|
+
import { useCallback as useCallback79, useEffect as useEffect125, useRef as useRef63, useState as useState140 } from "react";
|
|
80969
81135
|
import { useShallow as useShallow16 } from "zustand/react/shallow";
|
|
80970
81136
|
import { Fragment as Fragment63, jsx as jsx243, jsxs as jsxs233 } from "react/jsx-runtime";
|
|
80971
81137
|
function SetupScreen() {
|
|
@@ -80980,21 +81146,21 @@ function SetupScreen() {
|
|
|
80980
81146
|
}))
|
|
80981
81147
|
);
|
|
80982
81148
|
useWebSocket();
|
|
80983
|
-
const [catalogProviders, setCatalogProviders] =
|
|
80984
|
-
const [catalogModels, setCatalogModels] =
|
|
80985
|
-
const [savedProviders, setSavedProviders] =
|
|
80986
|
-
const [isLoadingCatalog, setIsLoadingCatalog] =
|
|
80987
|
-
const [catalogError, setCatalogError] =
|
|
80988
|
-
const [reloadNonce, setReloadNonce] =
|
|
80989
|
-
const [savedProviderIds, setSavedProviderIds] =
|
|
80990
|
-
const [probeResults, setProbeResults] =
|
|
80991
|
-
const [popularProviders, setPopularProviders] =
|
|
80992
|
-
const [isLoadingPopular, setIsLoadingPopular] =
|
|
80993
|
-
const [popularRefreshNonce, setPopularRefreshNonce] =
|
|
80994
|
-
const [previousProviderCount, setPreviousProviderCount] =
|
|
80995
|
-
const [lastUpdatedAt, setLastUpdatedAt] =
|
|
80996
|
-
const isInitialLoadRef =
|
|
80997
|
-
|
|
81149
|
+
const [catalogProviders, setCatalogProviders] = useState140([]);
|
|
81150
|
+
const [catalogModels, setCatalogModels] = useState140({});
|
|
81151
|
+
const [savedProviders, setSavedProviders] = useState140([]);
|
|
81152
|
+
const [isLoadingCatalog, setIsLoadingCatalog] = useState140(false);
|
|
81153
|
+
const [catalogError, setCatalogError] = useState140(null);
|
|
81154
|
+
const [reloadNonce, setReloadNonce] = useState140(0);
|
|
81155
|
+
const [savedProviderIds, setSavedProviderIds] = useState140(/* @__PURE__ */ new Set());
|
|
81156
|
+
const [probeResults, setProbeResults] = useState140({});
|
|
81157
|
+
const [popularProviders, setPopularProviders] = useState140(DEFAULT_POPULAR_PROVIDERS);
|
|
81158
|
+
const [isLoadingPopular, setIsLoadingPopular] = useState140(false);
|
|
81159
|
+
const [popularRefreshNonce, setPopularRefreshNonce] = useState140(0);
|
|
81160
|
+
const [previousProviderCount, setPreviousProviderCount] = useState140(0);
|
|
81161
|
+
const [lastUpdatedAt, setLastUpdatedAt] = useState140(null);
|
|
81162
|
+
const isInitialLoadRef = useRef63(true);
|
|
81163
|
+
useEffect125(() => {
|
|
80998
81164
|
const controller = new AbortController();
|
|
80999
81165
|
const localUrl = `${window.location.origin}/providers.json`;
|
|
81000
81166
|
const githubUrl = "https://raw.githubusercontent.com/WrongStack/WrongStack/main/packages/webui/public/providers.json";
|
|
@@ -81062,10 +81228,10 @@ function SetupScreen() {
|
|
|
81062
81228
|
});
|
|
81063
81229
|
return () => controller.abort();
|
|
81064
81230
|
}, [popularRefreshNonce]);
|
|
81065
|
-
const [selectedProvider, setSelectedProvider] =
|
|
81066
|
-
const [selectedModel, setSelectedModel] =
|
|
81067
|
-
const [isLoadingModels, setIsLoadingModels] =
|
|
81068
|
-
|
|
81231
|
+
const [selectedProvider, setSelectedProvider] = useState140(null);
|
|
81232
|
+
const [selectedModel, setSelectedModel] = useState140(null);
|
|
81233
|
+
const [isLoadingModels, setIsLoadingModels] = useState140(false);
|
|
81234
|
+
useEffect125(() => {
|
|
81069
81235
|
if (!wsConnected) return;
|
|
81070
81236
|
const wsClient = getWSClient(wsUrl);
|
|
81071
81237
|
let catalogTimeout = setTimeout(() => {
|
|
@@ -81146,7 +81312,7 @@ function SetupScreen() {
|
|
|
81146
81312
|
setSelectedModel(null);
|
|
81147
81313
|
}, []);
|
|
81148
81314
|
const hasAnyKey = savedProviderIds.size > 0;
|
|
81149
|
-
|
|
81315
|
+
useEffect125(() => {
|
|
81150
81316
|
if (!selectedProvider || !wsConnected) return;
|
|
81151
81317
|
const wsClient = getWSClient(wsUrl);
|
|
81152
81318
|
if (!catalogModels[selectedProvider]) {
|
|
@@ -81498,9 +81664,9 @@ import { Terminal as Terminal15 } from "@xterm/xterm";
|
|
|
81498
81664
|
import "@xterm/xterm/css/xterm.css";
|
|
81499
81665
|
import { Plus as Plus24, RotateCcw as RotateCcw18, TerminalSquare as TerminalSquare7, Trash2 as Trash227, X as X57 } from "lucide-react";
|
|
81500
81666
|
import {
|
|
81501
|
-
useEffect as
|
|
81502
|
-
useRef as
|
|
81503
|
-
useState as
|
|
81667
|
+
useEffect as useEffect126,
|
|
81668
|
+
useRef as useRef64,
|
|
81669
|
+
useState as useState141
|
|
81504
81670
|
} from "react";
|
|
81505
81671
|
import { jsx as jsx244, jsxs as jsxs234 } from "react/jsx-runtime";
|
|
81506
81672
|
function defaultTerminalHeight(compact = false) {
|
|
@@ -81537,17 +81703,17 @@ function TerminalPanel({
|
|
|
81537
81703
|
desktopShell = false,
|
|
81538
81704
|
onClose
|
|
81539
81705
|
}) {
|
|
81540
|
-
const resizeCleanupRef =
|
|
81706
|
+
const resizeCleanupRef = useRef64(null);
|
|
81541
81707
|
const { t } = useTranslation();
|
|
81542
|
-
const terminalCounterRef =
|
|
81543
|
-
const [height, setHeight] =
|
|
81544
|
-
const [tabs, setTabs] =
|
|
81545
|
-
const [activeId, setActiveId] =
|
|
81708
|
+
const terminalCounterRef = useRef64(1);
|
|
81709
|
+
const [height, setHeight] = useState141(() => readStoredTerminalHeight(desktopShell));
|
|
81710
|
+
const [tabs, setTabs] = useState141(() => [createTerminalTab(1)]);
|
|
81711
|
+
const [activeId, setActiveId] = useState141(() => tabs[0]?.id ?? "");
|
|
81546
81712
|
const terminalCreateNonce = useUIStore((s) => s.terminalCreateNonce);
|
|
81547
|
-
const lastTerminalCreateNonceRef =
|
|
81713
|
+
const lastTerminalCreateNonceRef = useRef64(terminalCreateNonce);
|
|
81548
81714
|
const projectName = useSessionStore((s) => s.projectName);
|
|
81549
81715
|
const cwd = useSessionStore((s) => s.cwd);
|
|
81550
|
-
|
|
81716
|
+
useEffect126(() => {
|
|
81551
81717
|
const onResize = () => {
|
|
81552
81718
|
setHeight((current) => {
|
|
81553
81719
|
const next = clampTerminalHeight(current);
|
|
@@ -81587,7 +81753,7 @@ function TerminalPanel({
|
|
|
81587
81753
|
window.addEventListener("pointerup", cleanup, { once: true });
|
|
81588
81754
|
window.addEventListener("pointercancel", cleanup, { once: true });
|
|
81589
81755
|
};
|
|
81590
|
-
|
|
81756
|
+
useEffect126(() => () => resizeCleanupRef.current?.(), []);
|
|
81591
81757
|
const addTerminal = () => {
|
|
81592
81758
|
setTabs((current) => {
|
|
81593
81759
|
if (current.length >= MAX_TERMINALS) return current;
|
|
@@ -81597,7 +81763,7 @@ function TerminalPanel({
|
|
|
81597
81763
|
return [...current, next];
|
|
81598
81764
|
});
|
|
81599
81765
|
};
|
|
81600
|
-
|
|
81766
|
+
useEffect126(() => {
|
|
81601
81767
|
if (terminalCreateNonce === lastTerminalCreateNonceRef.current) return;
|
|
81602
81768
|
lastTerminalCreateNonceRef.current = terminalCreateNonce;
|
|
81603
81769
|
addTerminal();
|
|
@@ -81810,17 +81976,17 @@ function TerminalSession({
|
|
|
81810
81976
|
onRunning,
|
|
81811
81977
|
onExit
|
|
81812
81978
|
}) {
|
|
81813
|
-
const containerRef =
|
|
81814
|
-
const termRef =
|
|
81815
|
-
const fitRef =
|
|
81816
|
-
const onRunningRef =
|
|
81817
|
-
const onExitRef =
|
|
81979
|
+
const containerRef = useRef64(null);
|
|
81980
|
+
const termRef = useRef64(null);
|
|
81981
|
+
const fitRef = useRef64(null);
|
|
81982
|
+
const onRunningRef = useRef64(onRunning);
|
|
81983
|
+
const onExitRef = useRef64(onExit);
|
|
81818
81984
|
const wsConnected = useConfigStore((s) => s.wsConnected);
|
|
81819
|
-
|
|
81985
|
+
useEffect126(() => {
|
|
81820
81986
|
onRunningRef.current = onRunning;
|
|
81821
81987
|
onExitRef.current = onExit;
|
|
81822
81988
|
}, [onExit, onRunning]);
|
|
81823
|
-
|
|
81989
|
+
useEffect126(() => {
|
|
81824
81990
|
const container = containerRef.current;
|
|
81825
81991
|
if (!container) return;
|
|
81826
81992
|
const term = new Terminal15({
|
|
@@ -81883,7 +82049,7 @@ function TerminalSession({
|
|
|
81883
82049
|
fitRef.current = null;
|
|
81884
82050
|
};
|
|
81885
82051
|
}, [id, wsConnected]);
|
|
81886
|
-
|
|
82052
|
+
useEffect126(() => {
|
|
81887
82053
|
if (!active) return;
|
|
81888
82054
|
window.requestAnimationFrame(() => {
|
|
81889
82055
|
try {
|
|
@@ -82094,7 +82260,7 @@ __export(QueuePanel_exports, {
|
|
|
82094
82260
|
QueuePanel: () => QueuePanel
|
|
82095
82261
|
});
|
|
82096
82262
|
import { ArrowDownAZ as ArrowDownAZ2, ArrowUpAZ as ArrowUpAZ2, Check as Check41, ListOrdered, Trash2 as Trash228, X as X58 } from "lucide-react";
|
|
82097
|
-
import { useCallback as useCallback81, useMemo as useMemo75, useState as
|
|
82263
|
+
import { useCallback as useCallback81, useMemo as useMemo75, useState as useState142 } from "react";
|
|
82098
82264
|
import { jsx as jsx247, jsxs as jsxs237 } from "react/jsx-runtime";
|
|
82099
82265
|
function QueuePanel({
|
|
82100
82266
|
open,
|
|
@@ -82105,7 +82271,7 @@ function QueuePanel({
|
|
|
82105
82271
|
const queue = useChatStore((s) => s.queue);
|
|
82106
82272
|
const removeQueued = useChatStore((s) => s.removeQueued);
|
|
82107
82273
|
const clearQueue = useChatStore((s) => s.clearQueue);
|
|
82108
|
-
const [sortDir, setSortDir] =
|
|
82274
|
+
const [sortDir, setSortDir] = useState142("oldest");
|
|
82109
82275
|
const handleRemove = useCallback81(
|
|
82110
82276
|
(index) => {
|
|
82111
82277
|
removeQueued(index);
|
|
@@ -82283,7 +82449,7 @@ import "@fontsource/ibm-plex-mono/500.css";
|
|
|
82283
82449
|
import "@fontsource/ibm-plex-mono/600.css";
|
|
82284
82450
|
|
|
82285
82451
|
// src/App.tsx
|
|
82286
|
-
import { lazy as lazy6, Suspense as Suspense6, useEffect as
|
|
82452
|
+
import { lazy as lazy6, Suspense as Suspense6, useEffect as useEffect127 } from "react";
|
|
82287
82453
|
import { useShallow as useShallow18 } from "zustand/react/shallow";
|
|
82288
82454
|
|
|
82289
82455
|
// src/hooks/useDesktopBridge.ts
|
|
@@ -111136,7 +111302,7 @@ function AppInner() {
|
|
|
111136
111302
|
setCronJobsOpen,
|
|
111137
111303
|
setTerminalOpen
|
|
111138
111304
|
});
|
|
111139
|
-
|
|
111305
|
+
useEffect127(() => {
|
|
111140
111306
|
if (typeof window === "undefined") return;
|
|
111141
111307
|
if (window.location.pathname === "/debug") {
|
|
111142
111308
|
navigateToView("debug");
|
|
@@ -111146,7 +111312,7 @@ function AppInner() {
|
|
|
111146
111312
|
navigateToView("refresh-debug");
|
|
111147
111313
|
}
|
|
111148
111314
|
}, []);
|
|
111149
|
-
|
|
111315
|
+
useEffect127(() => {
|
|
111150
111316
|
const onOpenFile = (e) => {
|
|
111151
111317
|
const { filePath } = e.detail;
|
|
111152
111318
|
const ws = getWSClient(useConfigStore.getState().wsUrl);
|
|
@@ -111157,7 +111323,7 @@ function AppInner() {
|
|
|
111157
111323
|
window.addEventListener("wrongstack:open-file", onOpenFile);
|
|
111158
111324
|
return () => window.removeEventListener("wrongstack:open-file", onOpenFile);
|
|
111159
111325
|
}, []);
|
|
111160
|
-
|
|
111326
|
+
useEffect127(() => {
|
|
111161
111327
|
const onSaveFile = (e) => {
|
|
111162
111328
|
const { filePath } = e.detail;
|
|
111163
111329
|
const file = useFileStore.getState().openFiles.find((f) => f.path === filePath);
|
|
@@ -111174,7 +111340,7 @@ function AppInner() {
|
|
|
111174
111340
|
return () => window.removeEventListener("wrongstack:save-file", onSaveFile);
|
|
111175
111341
|
}, []);
|
|
111176
111342
|
const { isMobile } = useViewport();
|
|
111177
|
-
|
|
111343
|
+
useEffect127(() => {
|
|
111178
111344
|
if (isMobile) {
|
|
111179
111345
|
const open = useUIStore.getState().sidebarOpen;
|
|
111180
111346
|
if (open) setSidebarOpen(false);
|
|
@@ -111183,7 +111349,7 @@ function AppInner() {
|
|
|
111183
111349
|
const mobileSidebarModal = isMobile && sidebarOpen;
|
|
111184
111350
|
useWebSocketBootstrap();
|
|
111185
111351
|
useF5Resilience();
|
|
111186
|
-
|
|
111352
|
+
useEffect127(() => {
|
|
111187
111353
|
const parts = [];
|
|
111188
111354
|
if (isLoading) {
|
|
111189
111355
|
const it = iteration ? ` iter ${iteration.index}${iteration.max ? `/${iteration.max}` : ""}` : "";
|