@tutti-os/workspace-issue-manager 0.0.21 → 0.0.23
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{chunk-GEH4QNB6.js → chunk-DYOOXQA7.js} +1264 -567
- package/dist/chunk-DYOOXQA7.js.map +1 -0
- package/dist/{chunk-7VN33U2R.js → chunk-ETRH7S2A.js} +2 -2
- package/dist/{chunk-PBN62U6U.js → chunk-SKXBZIGI.js} +2 -2
- package/dist/{chunk-OAASJITJ.js → chunk-UR3NVHQY.js} +8 -2
- package/dist/chunk-UR3NVHQY.js.map +1 -0
- package/dist/contracts/index.d.ts +3 -1
- package/dist/core/index.js +2 -2
- package/dist/i18n/index.js +1 -1
- package/dist/index.js +3 -3
- package/dist/services/index.js +3 -3
- package/dist/ui/index.js +4 -4
- package/dist/workbench/index.js +4 -4
- package/openapi/issue-manager.v1.yaml +3 -0
- package/package.json +9 -9
- package/dist/chunk-GEH4QNB6.js.map +0 -1
- package/dist/chunk-OAASJITJ.js.map +0 -1
- /package/dist/{chunk-7VN33U2R.js.map → chunk-ETRH7S2A.js.map} +0 -0
- /package/dist/{chunk-PBN62U6U.js.map → chunk-SKXBZIGI.js.map} +0 -0
|
@@ -24,7 +24,7 @@ import {
|
|
|
24
24
|
resolveIssueManagerTopicDeleteErrorMessage,
|
|
25
25
|
toContextRefInput,
|
|
26
26
|
toIssueManagerWorkspaceFileLinkInput
|
|
27
|
-
} from "./chunk-
|
|
27
|
+
} from "./chunk-SKXBZIGI.js";
|
|
28
28
|
import {
|
|
29
29
|
appendIssueManagerWorkspaceFileLinksToContent,
|
|
30
30
|
appendIssueManagerWorkspaceReferenceMentionsToContent,
|
|
@@ -36,7 +36,7 @@ import {
|
|
|
36
36
|
issueManagerSidebarMinWidth,
|
|
37
37
|
normalizeIssueManagerContent,
|
|
38
38
|
shouldAutoCollapseIssueManagerSidebar
|
|
39
|
-
} from "./chunk-
|
|
39
|
+
} from "./chunk-ETRH7S2A.js";
|
|
40
40
|
|
|
41
41
|
// src/ui/react/internal/shell/IssueManagerNodeState.ts
|
|
42
42
|
import { useEffect, useEffectEvent, useState } from "react";
|
|
@@ -870,6 +870,47 @@ function issueManagerAnalyticsRefType(kind) {
|
|
|
870
870
|
}
|
|
871
871
|
|
|
872
872
|
// src/services/internal/controllerActions.ts
|
|
873
|
+
function resolveIssueManagerTaskStatusBucket(status) {
|
|
874
|
+
return status === "in_progress" ? "running" : status;
|
|
875
|
+
}
|
|
876
|
+
function resolveIssueManagerMovedTaskOrder(input) {
|
|
877
|
+
const normalizedTaskId = input.taskId.trim();
|
|
878
|
+
const targetStatus = resolveIssueManagerTaskStatusBucket(input.targetStatus);
|
|
879
|
+
const sourceTask = input.tasks.find(
|
|
880
|
+
(task) => task.taskId === normalizedTaskId
|
|
881
|
+
);
|
|
882
|
+
if (!sourceTask || !targetStatus) {
|
|
883
|
+
return null;
|
|
884
|
+
}
|
|
885
|
+
const tasksWithoutMoved = input.tasks.filter(
|
|
886
|
+
(task) => task.taskId !== normalizedTaskId
|
|
887
|
+
);
|
|
888
|
+
const targetTasks = tasksWithoutMoved.filter(
|
|
889
|
+
(task) => resolveIssueManagerTaskStatusBucket(task.status) === targetStatus
|
|
890
|
+
);
|
|
891
|
+
const targetIndex = Math.min(
|
|
892
|
+
Math.max(0, Math.trunc(input.targetIndex)),
|
|
893
|
+
targetTasks.length
|
|
894
|
+
);
|
|
895
|
+
const targetTaskAtIndex = targetTasks[targetIndex];
|
|
896
|
+
const previousTargetTask = targetTasks[targetIndex - 1];
|
|
897
|
+
const sourceStatus = resolveIssueManagerTaskStatusBucket(sourceTask.status) === targetStatus ? sourceTask.status : input.targetStatus;
|
|
898
|
+
const nextTask = {
|
|
899
|
+
...sourceTask,
|
|
900
|
+
status: sourceStatus
|
|
901
|
+
};
|
|
902
|
+
const insertIndex = targetTaskAtIndex ? tasksWithoutMoved.findIndex(
|
|
903
|
+
(task) => task.taskId === targetTaskAtIndex.taskId
|
|
904
|
+
) : previousTargetTask ? tasksWithoutMoved.findIndex(
|
|
905
|
+
(task) => task.taskId === previousTargetTask.taskId
|
|
906
|
+
) + 1 : tasksWithoutMoved.length;
|
|
907
|
+
const normalizedInsertIndex = insertIndex < 0 ? tasksWithoutMoved.length : insertIndex;
|
|
908
|
+
return [
|
|
909
|
+
...tasksWithoutMoved.slice(0, normalizedInsertIndex),
|
|
910
|
+
nextTask,
|
|
911
|
+
...tasksWithoutMoved.slice(normalizedInsertIndex)
|
|
912
|
+
];
|
|
913
|
+
}
|
|
873
914
|
function createIssueManagerControllerActions(input) {
|
|
874
915
|
const {
|
|
875
916
|
copy,
|
|
@@ -1091,6 +1132,75 @@ function createIssueManagerControllerActions(input) {
|
|
|
1091
1132
|
createIssueManagerOpenReferencePickerOutcome(insertPlan.target)
|
|
1092
1133
|
);
|
|
1093
1134
|
},
|
|
1135
|
+
async moveTask(move) {
|
|
1136
|
+
const selectedIssueId = nodeState.selectedIssueId;
|
|
1137
|
+
const normalizedTaskId = move.taskId.trim();
|
|
1138
|
+
const allTasks = issueDetail.value?.tasks ?? [];
|
|
1139
|
+
const visibleTaskIds = new Set(
|
|
1140
|
+
move.visibleTaskIds?.map((taskId) => taskId.trim()).filter((taskId) => taskId.length > 0)
|
|
1141
|
+
);
|
|
1142
|
+
const currentTasks = visibleTaskIds.size > 0 ? allTasks.filter((task) => visibleTaskIds.has(task.taskId)) : allTasks;
|
|
1143
|
+
if (!selectedIssueId || !normalizedTaskId || currentTasks.length === 0) {
|
|
1144
|
+
return;
|
|
1145
|
+
}
|
|
1146
|
+
const nextTasks = resolveIssueManagerMovedTaskOrder({
|
|
1147
|
+
targetIndex: move.targetIndex,
|
|
1148
|
+
targetStatus: move.targetStatus,
|
|
1149
|
+
taskId: normalizedTaskId,
|
|
1150
|
+
tasks: currentTasks
|
|
1151
|
+
});
|
|
1152
|
+
if (!nextTasks) {
|
|
1153
|
+
return;
|
|
1154
|
+
}
|
|
1155
|
+
const nextVisibleTasks = [...nextTasks];
|
|
1156
|
+
const orderedTasks = visibleTaskIds.size > 0 ? allTasks.map(
|
|
1157
|
+
(task) => visibleTaskIds.has(task.taskId) ? nextVisibleTasks.shift() ?? task : task
|
|
1158
|
+
) : nextTasks;
|
|
1159
|
+
const previousById = new Map(
|
|
1160
|
+
allTasks.map((task, index) => [
|
|
1161
|
+
task.taskId,
|
|
1162
|
+
{
|
|
1163
|
+
sortIndex: task.sortIndex ?? index + 1,
|
|
1164
|
+
status: task.status
|
|
1165
|
+
}
|
|
1166
|
+
])
|
|
1167
|
+
);
|
|
1168
|
+
const updates = orderedTasks.map((task, index) => {
|
|
1169
|
+
const previous = previousById.get(task.taskId);
|
|
1170
|
+
const sortIndex = index + 1;
|
|
1171
|
+
if (previous && previous.sortIndex === sortIndex && previous.status === task.status) {
|
|
1172
|
+
return null;
|
|
1173
|
+
}
|
|
1174
|
+
return {
|
|
1175
|
+
sortIndex,
|
|
1176
|
+
status: task.status,
|
|
1177
|
+
taskId: task.taskId
|
|
1178
|
+
};
|
|
1179
|
+
}).filter(
|
|
1180
|
+
(update) => update !== null
|
|
1181
|
+
);
|
|
1182
|
+
if (updates.length === 0) {
|
|
1183
|
+
return;
|
|
1184
|
+
}
|
|
1185
|
+
try {
|
|
1186
|
+
await Promise.all(
|
|
1187
|
+
updates.map(
|
|
1188
|
+
(update) => feature.backend.updateTask({
|
|
1189
|
+
issueId: selectedIssueId,
|
|
1190
|
+
sortIndex: update.sortIndex,
|
|
1191
|
+
status: update.status,
|
|
1192
|
+
taskId: update.taskId,
|
|
1193
|
+
workspaceId
|
|
1194
|
+
})
|
|
1195
|
+
)
|
|
1196
|
+
);
|
|
1197
|
+
applyOutcome({
|
|
1198
|
+
refreshAll: true
|
|
1199
|
+
});
|
|
1200
|
+
} catch (error) {
|
|
1201
|
+
notifyError(error, "messages.taskSaveFailed");
|
|
1202
|
+
}
|
|
1203
|
+
},
|
|
1094
1204
|
async uploadReferences(parentKind, mode) {
|
|
1095
1205
|
const fileAdapter = feature.fileAdapter;
|
|
1096
1206
|
if (!canIssueManagerUploadReferences(fileAdapter)) {
|
|
@@ -2164,10 +2274,10 @@ import {
|
|
|
2164
2274
|
|
|
2165
2275
|
// src/ui/IssueManagerNode.tsx
|
|
2166
2276
|
import {
|
|
2167
|
-
useEffect as
|
|
2168
|
-
useRef as
|
|
2277
|
+
useEffect as useEffect10,
|
|
2278
|
+
useRef as useRef8
|
|
2169
2279
|
} from "react";
|
|
2170
|
-
import { Button as Button13, PanelIcon, cn as
|
|
2280
|
+
import { Button as Button13, PanelIcon, cn as cn12 } from "@tutti-os/ui-system";
|
|
2171
2281
|
import {
|
|
2172
2282
|
ReferenceSourcePicker,
|
|
2173
2283
|
WorkspaceFileReferencePicker
|
|
@@ -2175,14 +2285,14 @@ import {
|
|
|
2175
2285
|
|
|
2176
2286
|
// src/ui/internal/shell/IssueManagerShell.tsx
|
|
2177
2287
|
import {
|
|
2178
|
-
useEffect as
|
|
2179
|
-
useRef as
|
|
2180
|
-
useState as
|
|
2288
|
+
useEffect as useEffect8,
|
|
2289
|
+
useRef as useRef7,
|
|
2290
|
+
useState as useState10
|
|
2181
2291
|
} from "react";
|
|
2182
|
-
import { Button as Button11, FileCreateIcon as FileCreateIcon4, cn as
|
|
2292
|
+
import { Button as Button11, FileCreateIcon as FileCreateIcon4, cn as cn10 } from "@tutti-os/ui-system";
|
|
2183
2293
|
|
|
2184
2294
|
// src/ui/internal/shell/IssueManagerPanels.tsx
|
|
2185
|
-
import { useState as
|
|
2295
|
+
import { useState as useState7 } from "react";
|
|
2186
2296
|
import {
|
|
2187
2297
|
Badge as Badge2,
|
|
2188
2298
|
Button as Button5,
|
|
@@ -2210,15 +2320,15 @@ function issueManagerStatusBadgeVariant(status) {
|
|
|
2210
2320
|
}
|
|
2211
2321
|
|
|
2212
2322
|
// src/ui/internal/issue/IssueManagerIssueSections.tsx
|
|
2323
|
+
import { useState as useState4 } from "react";
|
|
2213
2324
|
import {
|
|
2214
2325
|
AgentSessionsIcon,
|
|
2215
|
-
ArrowRightIcon,
|
|
2216
2326
|
Badge,
|
|
2217
2327
|
Button as Button2,
|
|
2218
2328
|
FileCreateIcon as FileCreateIcon2,
|
|
2219
2329
|
FileIcon,
|
|
2220
2330
|
ScrollArea,
|
|
2221
|
-
cn
|
|
2331
|
+
cn as cn2
|
|
2222
2332
|
} from "@tutti-os/ui-system";
|
|
2223
2333
|
|
|
2224
2334
|
// src/ui/internal/content/IssueManagerTitleTooltip.tsx
|
|
@@ -2312,8 +2422,588 @@ function IssueManagerTaskDrawerLoadingState() {
|
|
|
2312
2422
|
] });
|
|
2313
2423
|
}
|
|
2314
2424
|
|
|
2315
|
-
// src/ui/internal/issue/
|
|
2425
|
+
// src/ui/internal/issue/IssueManagerSubtaskBoard.tsx
|
|
2426
|
+
import {
|
|
2427
|
+
useEffect as useEffect4,
|
|
2428
|
+
useLayoutEffect,
|
|
2429
|
+
useRef,
|
|
2430
|
+
useState as useState3
|
|
2431
|
+
} from "react";
|
|
2432
|
+
import { cn } from "@tutti-os/ui-system";
|
|
2316
2433
|
import { jsx as jsx3, jsxs as jsxs3 } from "react/jsx-runtime";
|
|
2434
|
+
var issueManagerSubtaskBoardStatuses = [
|
|
2435
|
+
"not_started",
|
|
2436
|
+
"running",
|
|
2437
|
+
"pending_acceptance",
|
|
2438
|
+
"completed",
|
|
2439
|
+
"failed",
|
|
2440
|
+
"canceled"
|
|
2441
|
+
];
|
|
2442
|
+
var issueManagerTaskStatusDragDataType = "application/x-tutti-issue-manager-task-status-drag";
|
|
2443
|
+
var issueManagerBoardLayoutItemAttribute = "data-issue-manager-board-layout-item";
|
|
2444
|
+
var issueManagerBoardLayoutAnimationDurationMs = 180;
|
|
2445
|
+
var issueManagerBoardLayoutAnimationEasing = "cubic-bezier(0.22,1,0.36,1)";
|
|
2446
|
+
var issueManagerSubtaskDragShadow = "var(--shadow-soft)";
|
|
2447
|
+
var issueManagerSubtaskDragShadowClassName = "shadow-[var(--shadow-soft)]";
|
|
2448
|
+
var issueManagerBoardLayoutAnimations = /* @__PURE__ */ new WeakMap();
|
|
2449
|
+
var issueManagerBoardLayoutInitialScrollSnapshot = {
|
|
2450
|
+
left: 0,
|
|
2451
|
+
top: 0
|
|
2452
|
+
};
|
|
2453
|
+
var issueManagerBoardStatusSet = {
|
|
2454
|
+
canceled: true,
|
|
2455
|
+
completed: true,
|
|
2456
|
+
failed: true,
|
|
2457
|
+
not_started: true,
|
|
2458
|
+
pending_acceptance: true,
|
|
2459
|
+
running: true
|
|
2460
|
+
};
|
|
2461
|
+
function resolveIssueManagerSubtaskBoardStatus(status) {
|
|
2462
|
+
return status === "in_progress" ? "running" : status in issueManagerBoardStatusSet ? status : "not_started";
|
|
2463
|
+
}
|
|
2464
|
+
function isIssueManagerTaskBoardStatus(status) {
|
|
2465
|
+
return status in issueManagerBoardStatusSet;
|
|
2466
|
+
}
|
|
2467
|
+
function canIssueManagerCrossColumnDropTaskStatus(input) {
|
|
2468
|
+
if (input.sourceStatus === "pending_acceptance") {
|
|
2469
|
+
return input.targetStatus === "not_started" || input.targetStatus === "completed";
|
|
2470
|
+
}
|
|
2471
|
+
if (input.sourceStatus === "completed") {
|
|
2472
|
+
return input.targetStatus === "not_started" || input.targetStatus === "pending_acceptance";
|
|
2473
|
+
}
|
|
2474
|
+
return false;
|
|
2475
|
+
}
|
|
2476
|
+
function canIssueManagerDropTaskStatus(input) {
|
|
2477
|
+
if (input.sourceStatus === input.targetStatus) {
|
|
2478
|
+
return true;
|
|
2479
|
+
}
|
|
2480
|
+
return canIssueManagerCrossColumnDropTaskStatus(input);
|
|
2481
|
+
}
|
|
2482
|
+
function groupIssueManagerSubtasksByStatus(tasks, optimisticDrop = null) {
|
|
2483
|
+
const groups = {
|
|
2484
|
+
canceled: [],
|
|
2485
|
+
completed: [],
|
|
2486
|
+
failed: [],
|
|
2487
|
+
not_started: [],
|
|
2488
|
+
pending_acceptance: [],
|
|
2489
|
+
running: []
|
|
2490
|
+
};
|
|
2491
|
+
let optimisticTask = null;
|
|
2492
|
+
for (const task of tasks) {
|
|
2493
|
+
if (optimisticDrop?.taskId === task.taskId) {
|
|
2494
|
+
optimisticTask = {
|
|
2495
|
+
...task,
|
|
2496
|
+
status: optimisticDrop.status
|
|
2497
|
+
};
|
|
2498
|
+
continue;
|
|
2499
|
+
}
|
|
2500
|
+
groups[resolveIssueManagerSubtaskBoardStatus(task.status)].push(task);
|
|
2501
|
+
}
|
|
2502
|
+
if (optimisticTask && optimisticDrop) {
|
|
2503
|
+
const targetGroup = groups[optimisticDrop.status];
|
|
2504
|
+
targetGroup.splice(
|
|
2505
|
+
Math.min(Math.max(0, optimisticDrop.index), targetGroup.length),
|
|
2506
|
+
0,
|
|
2507
|
+
optimisticTask
|
|
2508
|
+
);
|
|
2509
|
+
}
|
|
2510
|
+
return groups;
|
|
2511
|
+
}
|
|
2512
|
+
function isIssueManagerOptimisticDropSettled(tasks, optimisticDrop) {
|
|
2513
|
+
const optimisticTask = tasks.find(
|
|
2514
|
+
(task) => task.taskId === optimisticDrop.taskId
|
|
2515
|
+
);
|
|
2516
|
+
if (!optimisticTask) {
|
|
2517
|
+
return true;
|
|
2518
|
+
}
|
|
2519
|
+
if (resolveIssueManagerSubtaskBoardStatus(optimisticTask.status) !== optimisticDrop.status) {
|
|
2520
|
+
return false;
|
|
2521
|
+
}
|
|
2522
|
+
const targetGroup = tasks.filter(
|
|
2523
|
+
(task) => resolveIssueManagerSubtaskBoardStatus(task.status) === optimisticDrop.status
|
|
2524
|
+
);
|
|
2525
|
+
const taskIndex = targetGroup.findIndex(
|
|
2526
|
+
(task) => task.taskId === optimisticDrop.taskId
|
|
2527
|
+
);
|
|
2528
|
+
if (taskIndex < 0) {
|
|
2529
|
+
return false;
|
|
2530
|
+
}
|
|
2531
|
+
const targetIndex = Math.min(
|
|
2532
|
+
Math.max(0, optimisticDrop.index),
|
|
2533
|
+
Math.max(0, targetGroup.length - 1)
|
|
2534
|
+
);
|
|
2535
|
+
return taskIndex === targetIndex;
|
|
2536
|
+
}
|
|
2537
|
+
function readIssueManagerTaskStatusDragData(dataTransfer) {
|
|
2538
|
+
try {
|
|
2539
|
+
const raw = dataTransfer.getData(issueManagerTaskStatusDragDataType);
|
|
2540
|
+
const payload = JSON.parse(raw);
|
|
2541
|
+
const taskId = typeof payload.taskId === "string" ? payload.taskId.trim() : "";
|
|
2542
|
+
const sourceStatus = payload.sourceStatus ?? "";
|
|
2543
|
+
if (!taskId || !isIssueManagerTaskBoardStatus(sourceStatus)) {
|
|
2544
|
+
return null;
|
|
2545
|
+
}
|
|
2546
|
+
return {
|
|
2547
|
+
sourceStatus,
|
|
2548
|
+
taskId
|
|
2549
|
+
};
|
|
2550
|
+
} catch {
|
|
2551
|
+
return null;
|
|
2552
|
+
}
|
|
2553
|
+
}
|
|
2554
|
+
function writeIssueManagerTaskStatusDragData(event, task, sourceStatus) {
|
|
2555
|
+
event.dataTransfer.effectAllowed = "move";
|
|
2556
|
+
event.dataTransfer.setData(
|
|
2557
|
+
issueManagerTaskStatusDragDataType,
|
|
2558
|
+
JSON.stringify({ sourceStatus, taskId: task.taskId })
|
|
2559
|
+
);
|
|
2560
|
+
event.dataTransfer.setData("text/plain", task.taskId);
|
|
2561
|
+
}
|
|
2562
|
+
function setIssueManagerTaskDragImage(event) {
|
|
2563
|
+
const source = event.currentTarget;
|
|
2564
|
+
const rect = source.getBoundingClientRect();
|
|
2565
|
+
const clone = source.cloneNode(true);
|
|
2566
|
+
clone.style.position = "fixed";
|
|
2567
|
+
clone.style.pointerEvents = "none";
|
|
2568
|
+
clone.style.top = "-10000px";
|
|
2569
|
+
clone.style.left = "-10000px";
|
|
2570
|
+
clone.style.width = `${rect.width}px`;
|
|
2571
|
+
clone.style.borderRadius = "8px";
|
|
2572
|
+
clone.style.boxShadow = issueManagerSubtaskDragShadow;
|
|
2573
|
+
clone.style.background = "var(--background-fronted)";
|
|
2574
|
+
clone.style.opacity = "1";
|
|
2575
|
+
document.body.append(clone);
|
|
2576
|
+
event.dataTransfer.setDragImage(
|
|
2577
|
+
clone,
|
|
2578
|
+
Math.max(0, event.clientX - rect.left),
|
|
2579
|
+
Math.max(0, event.clientY - rect.top)
|
|
2580
|
+
);
|
|
2581
|
+
window.setTimeout(() => clone.remove(), 0);
|
|
2582
|
+
return rect.height;
|
|
2583
|
+
}
|
|
2584
|
+
function resolveIssueManagerDropPreviewIndex(input) {
|
|
2585
|
+
const cards = Array.from(
|
|
2586
|
+
input.event.currentTarget.querySelectorAll(
|
|
2587
|
+
"[data-issue-manager-board-card]"
|
|
2588
|
+
)
|
|
2589
|
+
).filter(
|
|
2590
|
+
(card) => card.dataset.issueManagerBoardCardTaskId !== input.draggingTaskId
|
|
2591
|
+
);
|
|
2592
|
+
for (const [index, card] of cards.entries()) {
|
|
2593
|
+
const rect = card.getBoundingClientRect();
|
|
2594
|
+
if (input.event.clientY < rect.top + rect.height / 2) {
|
|
2595
|
+
return index;
|
|
2596
|
+
}
|
|
2597
|
+
}
|
|
2598
|
+
return cards.length;
|
|
2599
|
+
}
|
|
2600
|
+
function orderIssueManagerTasksForSameColumnDropPreview(input) {
|
|
2601
|
+
if (!input.dragState || input.dragState.sourceStatus !== input.status || input.dropPreview?.status !== input.status) {
|
|
2602
|
+
return input.tasks;
|
|
2603
|
+
}
|
|
2604
|
+
const sourceTaskIndex = input.tasks.findIndex(
|
|
2605
|
+
(task) => task.taskId === input.dragState?.taskId
|
|
2606
|
+
);
|
|
2607
|
+
if (sourceTaskIndex < 0) {
|
|
2608
|
+
return input.tasks;
|
|
2609
|
+
}
|
|
2610
|
+
const movingTask = input.tasks[sourceTaskIndex];
|
|
2611
|
+
if (!movingTask) {
|
|
2612
|
+
return input.tasks;
|
|
2613
|
+
}
|
|
2614
|
+
const nextTasks = input.tasks.filter((_, index) => index !== sourceTaskIndex);
|
|
2615
|
+
const targetIndex = Math.min(
|
|
2616
|
+
Math.max(0, input.dropPreview.index),
|
|
2617
|
+
nextTasks.length
|
|
2618
|
+
);
|
|
2619
|
+
if (targetIndex === sourceTaskIndex) {
|
|
2620
|
+
return input.tasks;
|
|
2621
|
+
}
|
|
2622
|
+
nextTasks.splice(targetIndex, 0, movingTask);
|
|
2623
|
+
return nextTasks;
|
|
2624
|
+
}
|
|
2625
|
+
function isLeavingIssueManagerBoardColumn(event) {
|
|
2626
|
+
const relatedTarget = event.relatedTarget;
|
|
2627
|
+
if (relatedTarget instanceof Node && event.currentTarget.contains(relatedTarget)) {
|
|
2628
|
+
return false;
|
|
2629
|
+
}
|
|
2630
|
+
const rect = event.currentTarget.getBoundingClientRect();
|
|
2631
|
+
return !(event.clientX >= rect.left && event.clientX <= rect.right && event.clientY >= rect.top && event.clientY <= rect.bottom);
|
|
2632
|
+
}
|
|
2633
|
+
function prefersReducedIssueManagerBoardMotion() {
|
|
2634
|
+
return typeof window !== "undefined" && typeof window.matchMedia === "function" && window.matchMedia("(prefers-reduced-motion: reduce)").matches;
|
|
2635
|
+
}
|
|
2636
|
+
function readIssueManagerBoardScrollSnapshot(board) {
|
|
2637
|
+
const scrollContainer = board.parentElement;
|
|
2638
|
+
return {
|
|
2639
|
+
left: scrollContainer?.scrollLeft ?? 0,
|
|
2640
|
+
top: scrollContainer?.scrollTop ?? 0
|
|
2641
|
+
};
|
|
2642
|
+
}
|
|
2643
|
+
function useIssueManagerBoardLayoutAnimation() {
|
|
2644
|
+
const boardRef = useRef(null);
|
|
2645
|
+
const previousRectsRef = useRef(/* @__PURE__ */ new Map());
|
|
2646
|
+
const previousScrollSnapshotRef = useRef(
|
|
2647
|
+
issueManagerBoardLayoutInitialScrollSnapshot
|
|
2648
|
+
);
|
|
2649
|
+
useLayoutEffect(() => {
|
|
2650
|
+
const board = boardRef.current;
|
|
2651
|
+
if (!board) {
|
|
2652
|
+
return;
|
|
2653
|
+
}
|
|
2654
|
+
const elements = Array.from(
|
|
2655
|
+
board.querySelectorAll(
|
|
2656
|
+
`[${issueManagerBoardLayoutItemAttribute}]`
|
|
2657
|
+
)
|
|
2658
|
+
);
|
|
2659
|
+
const nextRects = /* @__PURE__ */ new Map();
|
|
2660
|
+
const nextScrollSnapshot = readIssueManagerBoardScrollSnapshot(board);
|
|
2661
|
+
const previousScrollSnapshot = previousScrollSnapshotRef.current;
|
|
2662
|
+
const didScrollSinceLastLayout = previousScrollSnapshot.left !== nextScrollSnapshot.left || previousScrollSnapshot.top !== nextScrollSnapshot.top;
|
|
2663
|
+
const shouldAnimate = !didScrollSinceLastLayout && !prefersReducedIssueManagerBoardMotion();
|
|
2664
|
+
const activeVisualTopByKey = /* @__PURE__ */ new Map();
|
|
2665
|
+
for (const element of elements) {
|
|
2666
|
+
const key = element.getAttribute(issueManagerBoardLayoutItemAttribute);
|
|
2667
|
+
const animation = issueManagerBoardLayoutAnimations.get(element);
|
|
2668
|
+
if (!key || !animation) {
|
|
2669
|
+
continue;
|
|
2670
|
+
}
|
|
2671
|
+
activeVisualTopByKey.set(key, element.getBoundingClientRect().top);
|
|
2672
|
+
animation.cancel();
|
|
2673
|
+
issueManagerBoardLayoutAnimations.delete(element);
|
|
2674
|
+
}
|
|
2675
|
+
for (const element of elements) {
|
|
2676
|
+
const key = element.getAttribute(issueManagerBoardLayoutItemAttribute);
|
|
2677
|
+
if (!key) {
|
|
2678
|
+
continue;
|
|
2679
|
+
}
|
|
2680
|
+
const rect = element.getBoundingClientRect();
|
|
2681
|
+
nextRects.set(key, rect);
|
|
2682
|
+
const previousRect = previousRectsRef.current.get(key);
|
|
2683
|
+
if (!shouldAnimate || !previousRect) {
|
|
2684
|
+
continue;
|
|
2685
|
+
}
|
|
2686
|
+
const deltaY = (activeVisualTopByKey.get(key) ?? previousRect.top) - rect.top;
|
|
2687
|
+
if (Math.abs(deltaY) < 0.5) {
|
|
2688
|
+
continue;
|
|
2689
|
+
}
|
|
2690
|
+
const animation = element.animate(
|
|
2691
|
+
[
|
|
2692
|
+
{ transform: `translate3d(0, ${deltaY}px, 0)` },
|
|
2693
|
+
{ transform: "translate3d(0, 0, 0)" }
|
|
2694
|
+
],
|
|
2695
|
+
{
|
|
2696
|
+
duration: issueManagerBoardLayoutAnimationDurationMs,
|
|
2697
|
+
easing: issueManagerBoardLayoutAnimationEasing
|
|
2698
|
+
}
|
|
2699
|
+
);
|
|
2700
|
+
issueManagerBoardLayoutAnimations.set(element, animation);
|
|
2701
|
+
animation.onfinish = () => {
|
|
2702
|
+
if (issueManagerBoardLayoutAnimations.get(element) === animation) {
|
|
2703
|
+
issueManagerBoardLayoutAnimations.delete(element);
|
|
2704
|
+
}
|
|
2705
|
+
};
|
|
2706
|
+
animation.oncancel = animation.onfinish;
|
|
2707
|
+
}
|
|
2708
|
+
previousRectsRef.current = nextRects;
|
|
2709
|
+
previousScrollSnapshotRef.current = nextScrollSnapshot;
|
|
2710
|
+
});
|
|
2711
|
+
return boardRef;
|
|
2712
|
+
}
|
|
2713
|
+
function IssueManagerSubtaskBoard({
|
|
2714
|
+
copy,
|
|
2715
|
+
onMoveTask,
|
|
2716
|
+
onSelectTask,
|
|
2717
|
+
tasks
|
|
2718
|
+
}) {
|
|
2719
|
+
const [optimisticDrop, setOptimisticDrop] = useState3(null);
|
|
2720
|
+
const groups = groupIssueManagerSubtasksByStatus(tasks, optimisticDrop);
|
|
2721
|
+
const visibleTaskIds = tasks.map((task) => task.taskId);
|
|
2722
|
+
const [dragState, setDragState] = useState3(null);
|
|
2723
|
+
const [dropPreview, setDropPreview] = useState3(null);
|
|
2724
|
+
const boardLayoutRef = useIssueManagerBoardLayoutAnimation();
|
|
2725
|
+
useEffect4(() => {
|
|
2726
|
+
if (!optimisticDrop) {
|
|
2727
|
+
return;
|
|
2728
|
+
}
|
|
2729
|
+
if (isIssueManagerOptimisticDropSettled(tasks, optimisticDrop)) {
|
|
2730
|
+
setOptimisticDrop(null);
|
|
2731
|
+
}
|
|
2732
|
+
}, [optimisticDrop, tasks]);
|
|
2733
|
+
const handleTaskDragStart = (event, task, sourceStatus) => {
|
|
2734
|
+
const cardHeight = setIssueManagerTaskDragImage(event);
|
|
2735
|
+
writeIssueManagerTaskStatusDragData(event, task, sourceStatus);
|
|
2736
|
+
setDragState({
|
|
2737
|
+
cardHeight,
|
|
2738
|
+
sourceStatus,
|
|
2739
|
+
taskId: task.taskId
|
|
2740
|
+
});
|
|
2741
|
+
setOptimisticDrop(null);
|
|
2742
|
+
setDropPreview(null);
|
|
2743
|
+
};
|
|
2744
|
+
const handleTaskDragEnd = () => {
|
|
2745
|
+
setDragState(null);
|
|
2746
|
+
setDropPreview(null);
|
|
2747
|
+
};
|
|
2748
|
+
return /* @__PURE__ */ jsx3("div", { className: "min-w-0 overflow-x-auto pb-1 [scrollbar-width:thin]", children: /* @__PURE__ */ jsx3(
|
|
2749
|
+
"div",
|
|
2750
|
+
{
|
|
2751
|
+
className: "grid min-w-[1560px] grid-cols-6 gap-3",
|
|
2752
|
+
ref: boardLayoutRef,
|
|
2753
|
+
children: issueManagerSubtaskBoardStatuses.map((status) => /* @__PURE__ */ jsx3(
|
|
2754
|
+
IssueManagerSubtaskBoardColumn,
|
|
2755
|
+
{
|
|
2756
|
+
copy,
|
|
2757
|
+
status,
|
|
2758
|
+
tasks: groups[status],
|
|
2759
|
+
visibleTaskIds,
|
|
2760
|
+
dragState,
|
|
2761
|
+
dropPreview,
|
|
2762
|
+
onDropPreviewChange: setDropPreview,
|
|
2763
|
+
onOptimisticDropChange: setOptimisticDrop,
|
|
2764
|
+
onMoveTask,
|
|
2765
|
+
onSelectTask,
|
|
2766
|
+
onTaskDragEnd: handleTaskDragEnd,
|
|
2767
|
+
onTaskDragStart: handleTaskDragStart
|
|
2768
|
+
},
|
|
2769
|
+
status
|
|
2770
|
+
))
|
|
2771
|
+
}
|
|
2772
|
+
) });
|
|
2773
|
+
}
|
|
2774
|
+
function IssueManagerSubtaskBoardColumn({
|
|
2775
|
+
copy,
|
|
2776
|
+
dragState,
|
|
2777
|
+
dropPreview,
|
|
2778
|
+
onMoveTask,
|
|
2779
|
+
onDropPreviewChange,
|
|
2780
|
+
onOptimisticDropChange,
|
|
2781
|
+
onSelectTask,
|
|
2782
|
+
onTaskDragEnd,
|
|
2783
|
+
onTaskDragStart,
|
|
2784
|
+
status,
|
|
2785
|
+
tasks,
|
|
2786
|
+
visibleTaskIds
|
|
2787
|
+
}) {
|
|
2788
|
+
const canAcceptTaskDrop = Boolean(dragState) && canIssueManagerDropTaskStatus({
|
|
2789
|
+
sourceStatus: dragState?.sourceStatus ?? "completed",
|
|
2790
|
+
targetStatus: status
|
|
2791
|
+
});
|
|
2792
|
+
const handleDragOver = (event) => {
|
|
2793
|
+
if (!canAcceptTaskDrop) {
|
|
2794
|
+
return;
|
|
2795
|
+
}
|
|
2796
|
+
event.preventDefault();
|
|
2797
|
+
event.dataTransfer.dropEffect = "move";
|
|
2798
|
+
const nextPreview = {
|
|
2799
|
+
index: resolveIssueManagerDropPreviewIndex({
|
|
2800
|
+
draggingTaskId: dragState?.taskId ?? null,
|
|
2801
|
+
event
|
|
2802
|
+
}),
|
|
2803
|
+
status
|
|
2804
|
+
};
|
|
2805
|
+
if (dropPreview?.index !== nextPreview.index || dropPreview?.status !== nextPreview.status) {
|
|
2806
|
+
onDropPreviewChange(nextPreview);
|
|
2807
|
+
}
|
|
2808
|
+
};
|
|
2809
|
+
const handleDragLeave = (event) => {
|
|
2810
|
+
if (dropPreview?.status === status && isLeavingIssueManagerBoardColumn(event)) {
|
|
2811
|
+
onDropPreviewChange(null);
|
|
2812
|
+
}
|
|
2813
|
+
};
|
|
2814
|
+
const handleDrop = (event) => {
|
|
2815
|
+
const payload = readIssueManagerTaskStatusDragData(event.dataTransfer);
|
|
2816
|
+
const taskId = payload?.taskId ?? dragState?.taskId;
|
|
2817
|
+
const sourceStatus = payload?.sourceStatus ?? dragState?.sourceStatus;
|
|
2818
|
+
if (!taskId || !sourceStatus || !canIssueManagerDropTaskStatus({
|
|
2819
|
+
sourceStatus,
|
|
2820
|
+
targetStatus: status
|
|
2821
|
+
})) {
|
|
2822
|
+
return;
|
|
2823
|
+
}
|
|
2824
|
+
event.preventDefault();
|
|
2825
|
+
event.stopPropagation();
|
|
2826
|
+
const targetIndex = dropPreview?.status === status ? dropPreview.index : resolveIssueManagerDropPreviewIndex({
|
|
2827
|
+
draggingTaskId: taskId,
|
|
2828
|
+
event
|
|
2829
|
+
});
|
|
2830
|
+
onOptimisticDropChange({
|
|
2831
|
+
index: targetIndex,
|
|
2832
|
+
status,
|
|
2833
|
+
taskId
|
|
2834
|
+
});
|
|
2835
|
+
onDropPreviewChange(null);
|
|
2836
|
+
void onMoveTask({
|
|
2837
|
+
targetIndex,
|
|
2838
|
+
targetStatus: status,
|
|
2839
|
+
taskId,
|
|
2840
|
+
visibleTaskIds
|
|
2841
|
+
}).catch(() => {
|
|
2842
|
+
onOptimisticDropChange(null);
|
|
2843
|
+
});
|
|
2844
|
+
};
|
|
2845
|
+
const renderTasks = orderIssueManagerTasksForSameColumnDropPreview({
|
|
2846
|
+
dragState,
|
|
2847
|
+
dropPreview,
|
|
2848
|
+
status,
|
|
2849
|
+
tasks
|
|
2850
|
+
});
|
|
2851
|
+
const isSameColumnDropPreview = Boolean(dragState) && dragState?.sourceStatus === status && dropPreview?.status === status && tasks.some((task) => task.taskId === dragState?.taskId);
|
|
2852
|
+
const activeDropPreviewDragState = dropPreview?.status === status && dragState && !isSameColumnDropPreview ? dragState : null;
|
|
2853
|
+
const renderDropPreview = (renderIndex) => {
|
|
2854
|
+
if (!activeDropPreviewDragState || dropPreview?.index !== renderIndex) {
|
|
2855
|
+
return null;
|
|
2856
|
+
}
|
|
2857
|
+
return /* @__PURE__ */ jsx3(
|
|
2858
|
+
"div",
|
|
2859
|
+
{
|
|
2860
|
+
"aria-hidden": "true",
|
|
2861
|
+
className: cn(
|
|
2862
|
+
"rounded-[8px] border border-dashed motion-safe:animate-in motion-safe:fade-in-0 motion-safe:zoom-in-[0.98] motion-safe:duration-[160ms] motion-safe:ease-[cubic-bezier(0.22,1,0.36,1)] motion-reduce:animate-none",
|
|
2863
|
+
resolveIssueManagerBoardPlaceholderClassName(status)
|
|
2864
|
+
),
|
|
2865
|
+
"data-issue-manager-board-layout-item": `preview:${status}`,
|
|
2866
|
+
"data-task-status-drop-preview": true,
|
|
2867
|
+
style: {
|
|
2868
|
+
height: `${Math.max(
|
|
2869
|
+
64,
|
|
2870
|
+
Math.min(activeDropPreviewDragState.cardHeight, 160)
|
|
2871
|
+
)}px`
|
|
2872
|
+
}
|
|
2873
|
+
}
|
|
2874
|
+
);
|
|
2875
|
+
};
|
|
2876
|
+
return /* @__PURE__ */ jsxs3(
|
|
2877
|
+
"div",
|
|
2878
|
+
{
|
|
2879
|
+
className: cn(
|
|
2880
|
+
"min-h-[220px] rounded-lg border px-2.5 py-2.5",
|
|
2881
|
+
canAcceptTaskDrop && "transition-shadow duration-[180ms] ease-[cubic-bezier(0.22,1,0.36,1)] motion-reduce:transition-none",
|
|
2882
|
+
resolveIssueManagerBoardColumnClassName(status)
|
|
2883
|
+
),
|
|
2884
|
+
"data-task-status-drop-target": canAcceptTaskDrop || void 0,
|
|
2885
|
+
onDragOver: handleDragOver,
|
|
2886
|
+
onDragLeave: handleDragLeave,
|
|
2887
|
+
onDrop: handleDrop,
|
|
2888
|
+
children: [
|
|
2889
|
+
/* @__PURE__ */ jsxs3("div", { className: "mb-2 flex items-center justify-between gap-2", children: [
|
|
2890
|
+
/* @__PURE__ */ jsxs3("div", { className: "flex min-w-0 items-center gap-1.5", children: [
|
|
2891
|
+
/* @__PURE__ */ jsx3(
|
|
2892
|
+
"span",
|
|
2893
|
+
{
|
|
2894
|
+
"aria-hidden": "true",
|
|
2895
|
+
className: cn(
|
|
2896
|
+
"size-2 rounded-full",
|
|
2897
|
+
resolveIssueManagerBoardDotClassName(status)
|
|
2898
|
+
)
|
|
2899
|
+
}
|
|
2900
|
+
),
|
|
2901
|
+
/* @__PURE__ */ jsx3("span", { className: "truncate text-[12px] font-semibold text-[var(--text-primary)]", children: resolveIssueManagerStatusLabel(copy, status) })
|
|
2902
|
+
] }),
|
|
2903
|
+
/* @__PURE__ */ jsx3("span", { className: "shrink-0 text-[12px] font-semibold text-[var(--text-secondary)]", children: tasks.length })
|
|
2904
|
+
] }),
|
|
2905
|
+
/* @__PURE__ */ jsxs3("div", { className: "grid gap-2", children: [
|
|
2906
|
+
renderDropPreview(0),
|
|
2907
|
+
renderTasks.map((task, index) => {
|
|
2908
|
+
const dragStatus = resolveIssueManagerSubtaskBoardStatus(task.status);
|
|
2909
|
+
const isDraggingTask = dragState?.taskId === task.taskId;
|
|
2910
|
+
return /* @__PURE__ */ jsxs3(
|
|
2911
|
+
"div",
|
|
2912
|
+
{
|
|
2913
|
+
className: "grid gap-2",
|
|
2914
|
+
"data-issue-manager-board-layout-item": `task:${status}:${task.taskId}`,
|
|
2915
|
+
children: [
|
|
2916
|
+
/* @__PURE__ */ jsxs3(
|
|
2917
|
+
"button",
|
|
2918
|
+
{
|
|
2919
|
+
className: cn(
|
|
2920
|
+
"rounded-[8px] bg-[var(--background-fronted)] px-3 py-2.5 text-left transition-shadow duration-150 motion-reduce:transition-none focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-primary/25",
|
|
2921
|
+
"cursor-grab active:cursor-grabbing",
|
|
2922
|
+
isDraggingTask && issueManagerSubtaskDragShadowClassName
|
|
2923
|
+
),
|
|
2924
|
+
"data-issue-manager-board-card": true,
|
|
2925
|
+
"data-issue-manager-board-card-task-id": task.taskId,
|
|
2926
|
+
draggable: true,
|
|
2927
|
+
type: "button",
|
|
2928
|
+
onClick: (event) => onSelectTask(event, task, "detail_subtasks_board"),
|
|
2929
|
+
onDragEnd: onTaskDragEnd,
|
|
2930
|
+
onDragStart: (event) => {
|
|
2931
|
+
if (!dragStatus) {
|
|
2932
|
+
event.preventDefault();
|
|
2933
|
+
return;
|
|
2934
|
+
}
|
|
2935
|
+
onTaskDragStart(event, task, dragStatus);
|
|
2936
|
+
},
|
|
2937
|
+
children: [
|
|
2938
|
+
/* @__PURE__ */ jsx3(IssueManagerTitleTooltip, { title: task.title, children: /* @__PURE__ */ jsx3("span", { className: "line-clamp-2 text-[13px] font-semibold leading-[1.35] text-[var(--text-primary)] [overflow-wrap:anywhere]", children: task.title }) }),
|
|
2939
|
+
/* @__PURE__ */ jsx3("p", { className: "mt-2 line-clamp-3 text-[11px] font-normal leading-[1.5] text-[var(--text-secondary)] [overflow-wrap:anywhere]", children: summarizeIssueManagerContent(
|
|
2940
|
+
task.content,
|
|
2941
|
+
copy.t("messages.taskContentEmpty")
|
|
2942
|
+
) }),
|
|
2943
|
+
/* @__PURE__ */ jsx3("span", { className: "mt-2 block text-[11px] font-normal text-[var(--text-tertiary)]", children: formatIssueManagerTimestamp(
|
|
2944
|
+
task.createdAtUnix ?? task.updatedAtUnix
|
|
2945
|
+
) || "" })
|
|
2946
|
+
]
|
|
2947
|
+
}
|
|
2948
|
+
),
|
|
2949
|
+
renderDropPreview(index + 1)
|
|
2950
|
+
]
|
|
2951
|
+
},
|
|
2952
|
+
task.taskId
|
|
2953
|
+
);
|
|
2954
|
+
})
|
|
2955
|
+
] })
|
|
2956
|
+
]
|
|
2957
|
+
}
|
|
2958
|
+
);
|
|
2959
|
+
}
|
|
2960
|
+
function resolveIssueManagerBoardPlaceholderClassName(status) {
|
|
2961
|
+
switch (status) {
|
|
2962
|
+
case "pending_acceptance":
|
|
2963
|
+
return "border-[color-mix(in_srgb,var(--tutti-purple)_24%,transparent)] bg-[color-mix(in_srgb,var(--tutti-purple)_18%,transparent)]";
|
|
2964
|
+
case "completed":
|
|
2965
|
+
return "border-[color-mix(in_srgb,var(--state-success)_24%,transparent)] bg-[color-mix(in_srgb,var(--state-success)_18%,transparent)]";
|
|
2966
|
+
case "not_started":
|
|
2967
|
+
return "border-[color-mix(in_srgb,var(--text-secondary)_20%,transparent)] bg-[color-mix(in_srgb,var(--text-secondary)_12%,transparent)]";
|
|
2968
|
+
default:
|
|
2969
|
+
return "border-[color-mix(in_srgb,var(--text-secondary)_18%,transparent)] bg-[color-mix(in_srgb,var(--text-secondary)_10%,transparent)]";
|
|
2970
|
+
}
|
|
2971
|
+
}
|
|
2972
|
+
function resolveIssueManagerBoardColumnClassName(status) {
|
|
2973
|
+
switch (status) {
|
|
2974
|
+
case "running":
|
|
2975
|
+
return "border-[color-mix(in_srgb,var(--status-running)_12%,transparent)] bg-[color-mix(in_srgb,var(--status-running)_8%,transparent)]";
|
|
2976
|
+
case "pending_acceptance":
|
|
2977
|
+
return "border-[color-mix(in_srgb,var(--tutti-purple)_12%,transparent)] bg-[color-mix(in_srgb,var(--tutti-purple)_8%,transparent)]";
|
|
2978
|
+
case "completed":
|
|
2979
|
+
return "border-[color-mix(in_srgb,var(--state-success)_12%,transparent)] bg-[color-mix(in_srgb,var(--state-success)_8%,transparent)]";
|
|
2980
|
+
case "failed":
|
|
2981
|
+
return "border-[color-mix(in_srgb,var(--state-danger)_12%,transparent)] bg-[color-mix(in_srgb,var(--state-danger)_8%,transparent)]";
|
|
2982
|
+
case "canceled":
|
|
2983
|
+
return "border-[color-mix(in_srgb,var(--text-secondary)_12%,transparent)] bg-[color-mix(in_srgb,var(--text-secondary)_8%,transparent)]";
|
|
2984
|
+
default:
|
|
2985
|
+
return "border-[color-mix(in_srgb,var(--text-secondary)_12%,transparent)] bg-[color-mix(in_srgb,var(--text-secondary)_8%,transparent)]";
|
|
2986
|
+
}
|
|
2987
|
+
}
|
|
2988
|
+
function resolveIssueManagerBoardDotClassName(status) {
|
|
2989
|
+
switch (status) {
|
|
2990
|
+
case "running":
|
|
2991
|
+
return "bg-[var(--status-running)]";
|
|
2992
|
+
case "pending_acceptance":
|
|
2993
|
+
return "bg-[var(--tutti-purple)]";
|
|
2994
|
+
case "completed":
|
|
2995
|
+
return "bg-[var(--state-success)]";
|
|
2996
|
+
case "failed":
|
|
2997
|
+
return "bg-[var(--state-danger)]";
|
|
2998
|
+
case "canceled":
|
|
2999
|
+
return "bg-[var(--text-tertiary)]";
|
|
3000
|
+
default:
|
|
3001
|
+
return "bg-[var(--text-secondary)]";
|
|
3002
|
+
}
|
|
3003
|
+
}
|
|
3004
|
+
|
|
3005
|
+
// src/ui/internal/issue/IssueManagerIssueSections.tsx
|
|
3006
|
+
import { jsx as jsx4, jsxs as jsxs4 } from "react/jsx-runtime";
|
|
2317
3007
|
function IssueManagerDetailTextSection({
|
|
2318
3008
|
body,
|
|
2319
3009
|
isPlaceholder = false,
|
|
@@ -2323,21 +3013,21 @@ function IssueManagerDetailTextSection({
|
|
|
2323
3013
|
}) {
|
|
2324
3014
|
const bodyText = stripIssueManagerDescriptionTerminalPunctuation(body);
|
|
2325
3015
|
const metaText = meta ? stripIssueManagerDescriptionTerminalPunctuation(meta) : null;
|
|
2326
|
-
const bodyClassName =
|
|
3016
|
+
const bodyClassName = cn2(
|
|
2327
3017
|
"max-w-full whitespace-normal break-words text-[13px] leading-5 [overflow-wrap:anywhere]",
|
|
2328
3018
|
isPlaceholder ? "font-normal text-[var(--text-secondary)]" : tone === "destructive" ? "font-semibold text-[var(--state-danger)]" : "font-semibold text-[var(--text-primary)]"
|
|
2329
3019
|
);
|
|
2330
3020
|
if (isPlaceholder) {
|
|
2331
|
-
return /* @__PURE__ */
|
|
2332
|
-
/* @__PURE__ */
|
|
2333
|
-
/* @__PURE__ */
|
|
3021
|
+
return /* @__PURE__ */ jsxs4("section", { className: "grid gap-2.5", children: [
|
|
3022
|
+
/* @__PURE__ */ jsx4("h3", { className: "text-[13px] font-semibold text-[var(--text-primary)]", children: label }),
|
|
3023
|
+
/* @__PURE__ */ jsx4("p", { className: bodyClassName, children: bodyText })
|
|
2334
3024
|
] });
|
|
2335
3025
|
}
|
|
2336
|
-
return /* @__PURE__ */
|
|
2337
|
-
/* @__PURE__ */
|
|
2338
|
-
/* @__PURE__ */
|
|
2339
|
-
/* @__PURE__ */
|
|
2340
|
-
metaText ? /* @__PURE__ */
|
|
3026
|
+
return /* @__PURE__ */ jsxs4("section", { className: "grid gap-2.5", children: [
|
|
3027
|
+
/* @__PURE__ */ jsx4("h3", { className: "text-[13px] font-semibold text-[var(--text-primary)]", children: label }),
|
|
3028
|
+
/* @__PURE__ */ jsxs4("div", { className: "min-w-0 rounded-[12px] border border-[var(--line-2)] px-4 py-3", children: [
|
|
3029
|
+
/* @__PURE__ */ jsx4("p", { className: bodyClassName, children: bodyText }),
|
|
3030
|
+
metaText ? /* @__PURE__ */ jsx4("p", { className: "mt-1 truncate text-[11px] font-normal text-[var(--text-secondary)]", children: metaText }) : null
|
|
2341
3031
|
] })
|
|
2342
3032
|
] });
|
|
2343
3033
|
}
|
|
@@ -2349,7 +3039,7 @@ function IssueManagerLatestRunStatusSection({
|
|
|
2349
3039
|
title
|
|
2350
3040
|
}) {
|
|
2351
3041
|
if (!latestRun) {
|
|
2352
|
-
return /* @__PURE__ */
|
|
3042
|
+
return /* @__PURE__ */ jsx4(
|
|
2353
3043
|
IssueManagerDetailTextSection,
|
|
2354
3044
|
{
|
|
2355
3045
|
body: copy.t("messages.noExecutionStatus"),
|
|
@@ -2374,50 +3064,50 @@ function IssueManagerLatestRunStatusSection({
|
|
|
2374
3064
|
onOpenAgentSession
|
|
2375
3065
|
}) : null;
|
|
2376
3066
|
if (renderedLatestRunStatus !== null && renderedLatestRunStatus !== void 0) {
|
|
2377
|
-
return /* @__PURE__ */
|
|
2378
|
-
/* @__PURE__ */
|
|
3067
|
+
return /* @__PURE__ */ jsxs4("section", { className: "grid gap-2.5", children: [
|
|
3068
|
+
/* @__PURE__ */ jsx4("h3", { className: "text-[13px] font-semibold text-[var(--text-primary)]", children: copy.t("labels.latestRunStatus") }),
|
|
2379
3069
|
renderedLatestRunStatus
|
|
2380
3070
|
] });
|
|
2381
3071
|
}
|
|
2382
3072
|
const primaryText = agentSessionId || summary || latestRun.runId || statusLabel;
|
|
2383
|
-
const content = /* @__PURE__ */
|
|
2384
|
-
/* @__PURE__ */
|
|
3073
|
+
const content = /* @__PURE__ */ jsxs4("div", { className: "flex min-w-0 items-start gap-3", children: [
|
|
3074
|
+
/* @__PURE__ */ jsx4(
|
|
2385
3075
|
"span",
|
|
2386
3076
|
{
|
|
2387
3077
|
"aria-hidden": "true",
|
|
2388
|
-
className:
|
|
3078
|
+
className: cn2(
|
|
2389
3079
|
"mt-0.5 flex h-7 w-7 shrink-0 items-center justify-center rounded-md border border-[var(--line-2)]",
|
|
2390
3080
|
canOpenAgentSession ? "bg-transparency-actived text-primary" : "bg-transparent text-[var(--text-secondary)]"
|
|
2391
3081
|
),
|
|
2392
|
-
children: /* @__PURE__ */
|
|
3082
|
+
children: /* @__PURE__ */ jsx4(AgentSessionsIcon, { size: 16 })
|
|
2393
3083
|
}
|
|
2394
3084
|
),
|
|
2395
|
-
/* @__PURE__ */
|
|
2396
|
-
/* @__PURE__ */
|
|
2397
|
-
/* @__PURE__ */
|
|
3085
|
+
/* @__PURE__ */ jsxs4("div", { className: "min-w-0 flex-1", children: [
|
|
3086
|
+
/* @__PURE__ */ jsxs4("div", { className: "flex min-w-0 flex-wrap items-center gap-2", children: [
|
|
3087
|
+
/* @__PURE__ */ jsx4(
|
|
2398
3088
|
"p",
|
|
2399
3089
|
{
|
|
2400
|
-
className:
|
|
3090
|
+
className: cn2(
|
|
2401
3091
|
"min-w-0 flex-1 text-[13px] font-semibold leading-5 text-[var(--text-primary)] [overflow-wrap:anywhere]",
|
|
2402
3092
|
agentSessionId ? "font-mono" : ""
|
|
2403
3093
|
),
|
|
2404
3094
|
children: primaryText
|
|
2405
3095
|
}
|
|
2406
3096
|
),
|
|
2407
|
-
/* @__PURE__ */
|
|
3097
|
+
/* @__PURE__ */ jsx4(Badge, { variant: issueManagerStatusBadgeVariant(latestRun.status), children: statusLabel })
|
|
2408
3098
|
] }),
|
|
2409
|
-
summary && agentSessionId ? /* @__PURE__ */
|
|
2410
|
-
timestamp ? /* @__PURE__ */
|
|
2411
|
-
errorMessage ? /* @__PURE__ */
|
|
3099
|
+
summary && agentSessionId ? /* @__PURE__ */ jsx4("p", { className: "mt-1 text-[11px] font-normal leading-5 text-[var(--text-secondary)] [overflow-wrap:anywhere]", children: summary }) : null,
|
|
3100
|
+
timestamp ? /* @__PURE__ */ jsx4("p", { className: "mt-1 truncate text-[11px] font-normal text-[var(--text-secondary)]", children: timestamp }) : null,
|
|
3101
|
+
errorMessage ? /* @__PURE__ */ jsx4("p", { className: "mt-2 text-[11px] font-medium leading-5 text-[var(--state-danger)] [overflow-wrap:anywhere]", children: errorMessage }) : null
|
|
2412
3102
|
] })
|
|
2413
3103
|
] });
|
|
2414
|
-
const cardClassName =
|
|
3104
|
+
const cardClassName = cn2(
|
|
2415
3105
|
"min-w-0 rounded-[12px] border border-[var(--line-2)] px-4 py-3",
|
|
2416
3106
|
canOpenAgentSession ? "w-full bg-transparent text-left transition-colors hover:bg-transparency-hover focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-primary/25 focus-visible:ring-inset" : "bg-transparent"
|
|
2417
3107
|
);
|
|
2418
|
-
return /* @__PURE__ */
|
|
2419
|
-
/* @__PURE__ */
|
|
2420
|
-
canOpenAgentSession ? /* @__PURE__ */
|
|
3108
|
+
return /* @__PURE__ */ jsxs4("section", { className: "grid gap-2.5", children: [
|
|
3109
|
+
/* @__PURE__ */ jsx4("h3", { className: "text-[13px] font-semibold text-[var(--text-primary)]", children: copy.t("labels.latestRunStatus") }),
|
|
3110
|
+
canOpenAgentSession ? /* @__PURE__ */ jsx4(
|
|
2421
3111
|
"button",
|
|
2422
3112
|
{
|
|
2423
3113
|
"aria-label": copy.t("actions.openAgentSession"),
|
|
@@ -2429,7 +3119,7 @@ function IssueManagerLatestRunStatusSection({
|
|
|
2429
3119
|
},
|
|
2430
3120
|
children: content
|
|
2431
3121
|
}
|
|
2432
|
-
) : /* @__PURE__ */
|
|
3122
|
+
) : /* @__PURE__ */ jsx4("div", { className: cardClassName, children: content })
|
|
2433
3123
|
] });
|
|
2434
3124
|
}
|
|
2435
3125
|
function IssueManagerOutputSection({
|
|
@@ -2437,9 +3127,9 @@ function IssueManagerOutputSection({
|
|
|
2437
3127
|
onOpen,
|
|
2438
3128
|
outputs
|
|
2439
3129
|
}) {
|
|
2440
|
-
return /* @__PURE__ */
|
|
2441
|
-
/* @__PURE__ */
|
|
2442
|
-
outputs.length === 0 ? /* @__PURE__ */
|
|
3130
|
+
return /* @__PURE__ */ jsxs4("section", { className: "grid gap-2.5", children: [
|
|
3131
|
+
/* @__PURE__ */ jsx4("h3", { className: "text-[13px] font-semibold text-[var(--text-primary)]", children: copy.t("labels.executionOutputs") }),
|
|
3132
|
+
outputs.length === 0 ? /* @__PURE__ */ jsx4("p", { className: "text-[13px] font-normal leading-6 text-[var(--text-secondary)]", children: copy.t("messages.noExecutionOutputs") }) : /* @__PURE__ */ jsx4("div", { className: "overflow-hidden rounded-[12px] border border-[var(--line-2)] bg-transparent", children: outputs.map((output) => /* @__PURE__ */ jsxs4(
|
|
2443
3133
|
"button",
|
|
2444
3134
|
{
|
|
2445
3135
|
"aria-label": copy.t("actions.openReference"),
|
|
@@ -2454,27 +3144,21 @@ function IssueManagerOutputSection({
|
|
|
2454
3144
|
});
|
|
2455
3145
|
},
|
|
2456
3146
|
children: [
|
|
2457
|
-
/* @__PURE__ */
|
|
2458
|
-
/* @__PURE__ */
|
|
3147
|
+
/* @__PURE__ */ jsxs4("span", { className: "flex min-w-0 flex-1 items-center gap-3", children: [
|
|
3148
|
+
/* @__PURE__ */ jsx4(
|
|
2459
3149
|
"span",
|
|
2460
3150
|
{
|
|
2461
3151
|
"aria-hidden": "true",
|
|
2462
|
-
className: "flex h-8 w-8 shrink-0 items-center justify-center rounded-md
|
|
2463
|
-
children: /* @__PURE__ */
|
|
3152
|
+
className: "flex h-8 w-8 shrink-0 items-center justify-center rounded-md bg-[color-mix(in_srgb,var(--folder)_12%,transparent)] text-[var(--folder)]",
|
|
3153
|
+
children: /* @__PURE__ */ jsx4(FileIcon, { size: 16 })
|
|
2464
3154
|
}
|
|
2465
3155
|
),
|
|
2466
|
-
/* @__PURE__ */
|
|
2467
|
-
/* @__PURE__ */
|
|
2468
|
-
/* @__PURE__ */
|
|
3156
|
+
/* @__PURE__ */ jsxs4("span", { className: "min-w-0 flex-1", children: [
|
|
3157
|
+
/* @__PURE__ */ jsx4("span", { className: "block truncate text-[13px] font-semibold text-[var(--text-primary)]", children: output.displayName }),
|
|
3158
|
+
/* @__PURE__ */ jsx4("span", { className: "mt-1 block truncate text-[11px] font-normal text-[var(--text-secondary)]", children: output.path })
|
|
2469
3159
|
] })
|
|
2470
3160
|
] }),
|
|
2471
|
-
/* @__PURE__ */
|
|
2472
|
-
/* @__PURE__ */ jsx3("span", { className: "text-[11px] font-normal text-[var(--text-secondary)]", children: formatIssueManagerTimestamp(output.createdAtUnix) || "" }),
|
|
2473
|
-
/* @__PURE__ */ jsxs3("span", { className: "inline-flex h-7 items-center gap-1 rounded-md border border-primary/20 bg-transparency-actived px-2 text-[11px] font-semibold text-primary", children: [
|
|
2474
|
-
copy.t("actions.openReference"),
|
|
2475
|
-
/* @__PURE__ */ jsx3(ArrowRightIcon, { size: 13 })
|
|
2476
|
-
] })
|
|
2477
|
-
] })
|
|
3161
|
+
/* @__PURE__ */ jsx4("span", { className: "flex shrink-0 items-center gap-2", children: /* @__PURE__ */ jsx4("span", { className: "text-[11px] font-normal text-[var(--text-secondary)]", children: formatIssueManagerTimestamp(output.createdAtUnix) || "" }) })
|
|
2478
3162
|
]
|
|
2479
3163
|
},
|
|
2480
3164
|
output.outputId
|
|
@@ -2485,55 +3169,148 @@ function IssueManagerSubtaskSection({
|
|
|
2485
3169
|
copy,
|
|
2486
3170
|
diagnostics,
|
|
2487
3171
|
onCreate,
|
|
3172
|
+
onMoveTask,
|
|
2488
3173
|
onSelectTask,
|
|
2489
3174
|
selectedTaskId,
|
|
2490
3175
|
tasks
|
|
2491
3176
|
}) {
|
|
2492
|
-
|
|
2493
|
-
|
|
2494
|
-
|
|
2495
|
-
|
|
2496
|
-
|
|
2497
|
-
|
|
3177
|
+
const [viewMode, setViewMode] = useState4("list");
|
|
3178
|
+
const handleSelectTask = (event, task, surface) => {
|
|
3179
|
+
logIssueManagerDiagnostic(diagnostics, "task_row.click", {
|
|
3180
|
+
clientX: event.clientX,
|
|
3181
|
+
clientY: event.clientY,
|
|
3182
|
+
selectedTaskId,
|
|
3183
|
+
surface,
|
|
3184
|
+
taskId: task.taskId,
|
|
3185
|
+
taskTitle: task.title
|
|
3186
|
+
});
|
|
3187
|
+
onSelectTask(task.taskId);
|
|
3188
|
+
};
|
|
3189
|
+
return /* @__PURE__ */ jsxs4("section", { className: "grid gap-2.5", children: [
|
|
3190
|
+
/* @__PURE__ */ jsxs4("div", { className: "flex flex-wrap items-center justify-between gap-3", children: [
|
|
3191
|
+
/* @__PURE__ */ jsx4("h3", { className: "text-[13px] font-semibold text-[var(--text-primary)]", children: copy.t("labels.subtasks") }),
|
|
3192
|
+
/* @__PURE__ */ jsxs4("div", { className: "flex items-center gap-2", children: [
|
|
3193
|
+
/* @__PURE__ */ jsx4(
|
|
3194
|
+
IssueManagerSubtaskViewModeSwitch,
|
|
3195
|
+
{
|
|
3196
|
+
copy,
|
|
3197
|
+
value: viewMode,
|
|
3198
|
+
onChange: setViewMode
|
|
3199
|
+
}
|
|
3200
|
+
),
|
|
3201
|
+
/* @__PURE__ */ jsxs4(
|
|
3202
|
+
Button2,
|
|
3203
|
+
{
|
|
3204
|
+
size: "dialog",
|
|
3205
|
+
type: "button",
|
|
3206
|
+
variant: "ghost",
|
|
3207
|
+
onClick: onCreate,
|
|
3208
|
+
children: [
|
|
3209
|
+
/* @__PURE__ */ jsx4(FileCreateIcon2, { size: 14 }),
|
|
3210
|
+
copy.t("actions.add")
|
|
3211
|
+
]
|
|
3212
|
+
}
|
|
3213
|
+
)
|
|
2498
3214
|
] })
|
|
2499
3215
|
] }),
|
|
2500
|
-
tasks.length === 0 ? /* @__PURE__ */
|
|
2501
|
-
|
|
3216
|
+
tasks.length === 0 ? /* @__PURE__ */ jsx4("p", { className: "text-[13px] font-normal leading-6 text-[var(--text-secondary)]", children: copy.t("messages.noSubtasksForIssue") }) : viewMode === "board" ? /* @__PURE__ */ jsx4(
|
|
3217
|
+
IssueManagerSubtaskBoard,
|
|
2502
3218
|
{
|
|
2503
|
-
|
|
2504
|
-
|
|
2505
|
-
|
|
3219
|
+
copy,
|
|
3220
|
+
tasks,
|
|
3221
|
+
onMoveTask,
|
|
3222
|
+
onSelectTask: handleSelectTask
|
|
3223
|
+
}
|
|
3224
|
+
) : /* @__PURE__ */ jsx4(
|
|
3225
|
+
IssueManagerSubtaskList,
|
|
3226
|
+
{
|
|
3227
|
+
copy,
|
|
3228
|
+
selectedTaskId,
|
|
3229
|
+
tasks,
|
|
3230
|
+
onSelectTask: handleSelectTask
|
|
3231
|
+
}
|
|
3232
|
+
)
|
|
3233
|
+
] });
|
|
3234
|
+
}
|
|
3235
|
+
function IssueManagerSubtaskViewModeSwitch({
|
|
3236
|
+
copy,
|
|
3237
|
+
onChange,
|
|
3238
|
+
value
|
|
3239
|
+
}) {
|
|
3240
|
+
const modes = ["list", "board"];
|
|
3241
|
+
return /* @__PURE__ */ jsxs4(
|
|
3242
|
+
"div",
|
|
3243
|
+
{
|
|
3244
|
+
"aria-label": copy.t("labels.subtaskViewMode"),
|
|
3245
|
+
className: "relative inline-grid h-8 shrink-0 grid-cols-2 items-center rounded-md bg-[var(--transparency-block)] p-0.5",
|
|
3246
|
+
role: "group",
|
|
3247
|
+
children: [
|
|
3248
|
+
/* @__PURE__ */ jsx4(
|
|
3249
|
+
"span",
|
|
3250
|
+
{
|
|
3251
|
+
"aria-hidden": "true",
|
|
3252
|
+
className: cn2(
|
|
3253
|
+
"absolute top-0.5 bottom-0.5 left-0.5 w-[calc((100%-4px)/2)] rounded-[5px] bg-[var(--background-fronted)] transition-transform duration-150 ease-out",
|
|
3254
|
+
value === "board" && "translate-x-full"
|
|
3255
|
+
)
|
|
3256
|
+
}
|
|
2506
3257
|
),
|
|
2507
|
-
|
|
2508
|
-
|
|
2509
|
-
|
|
2510
|
-
|
|
2511
|
-
|
|
2512
|
-
|
|
2513
|
-
|
|
2514
|
-
|
|
2515
|
-
|
|
2516
|
-
|
|
2517
|
-
|
|
2518
|
-
|
|
2519
|
-
|
|
2520
|
-
|
|
2521
|
-
|
|
2522
|
-
|
|
2523
|
-
|
|
2524
|
-
|
|
2525
|
-
|
|
2526
|
-
|
|
2527
|
-
|
|
2528
|
-
|
|
2529
|
-
|
|
2530
|
-
|
|
2531
|
-
|
|
2532
|
-
|
|
2533
|
-
|
|
2534
|
-
|
|
2535
|
-
|
|
2536
|
-
|
|
3258
|
+
modes.map((mode) => /* @__PURE__ */ jsx4(
|
|
3259
|
+
"button",
|
|
3260
|
+
{
|
|
3261
|
+
"aria-pressed": value === mode,
|
|
3262
|
+
className: cn2(
|
|
3263
|
+
"relative z-[1] inline-flex h-7 w-14 items-center justify-center rounded-[5px] px-2.5 text-[12px] font-semibold leading-none transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-primary/25",
|
|
3264
|
+
value === mode ? "text-[var(--text-primary)]" : "text-[var(--text-secondary)] hover:text-[var(--text-primary)]"
|
|
3265
|
+
),
|
|
3266
|
+
type: "button",
|
|
3267
|
+
onClick: () => onChange(mode),
|
|
3268
|
+
children: copy.t(mode === "list" ? "labels.listView" : "labels.boardView")
|
|
3269
|
+
},
|
|
3270
|
+
mode
|
|
3271
|
+
))
|
|
3272
|
+
]
|
|
3273
|
+
}
|
|
3274
|
+
);
|
|
3275
|
+
}
|
|
3276
|
+
function IssueManagerSubtaskList({
|
|
3277
|
+
copy,
|
|
3278
|
+
onSelectTask,
|
|
3279
|
+
selectedTaskId,
|
|
3280
|
+
tasks
|
|
3281
|
+
}) {
|
|
3282
|
+
return /* @__PURE__ */ jsx4("div", { className: "overflow-hidden rounded-lg border border-[var(--line-2)] bg-transparent", children: tasks.map((task) => /* @__PURE__ */ jsxs4(
|
|
3283
|
+
"button",
|
|
3284
|
+
{
|
|
3285
|
+
className: cn2(
|
|
3286
|
+
"flex w-full items-start justify-between gap-4 border-b border-[var(--line-2)] px-4 py-3 text-left transition-colors last:border-b-0 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-primary/25 focus-visible:ring-inset",
|
|
3287
|
+
selectedTaskId === task.taskId ? "bg-transparency-actived" : "bg-transparent hover:bg-transparency-hover"
|
|
3288
|
+
),
|
|
3289
|
+
type: "button",
|
|
3290
|
+
onClick: (event) => onSelectTask(event, task, "detail_subtasks"),
|
|
3291
|
+
children: [
|
|
3292
|
+
/* @__PURE__ */ jsx4(IssueManagerSubtaskListContent, { copy, task }),
|
|
3293
|
+
/* @__PURE__ */ jsx4("span", { className: "shrink-0 text-[11px] font-normal text-[var(--text-secondary)]", children: formatIssueManagerTimestamp(
|
|
3294
|
+
task.createdAtUnix ?? task.updatedAtUnix
|
|
3295
|
+
) || "" })
|
|
3296
|
+
]
|
|
3297
|
+
},
|
|
3298
|
+
task.taskId
|
|
3299
|
+
)) });
|
|
3300
|
+
}
|
|
3301
|
+
function IssueManagerSubtaskListContent({
|
|
3302
|
+
copy,
|
|
3303
|
+
task
|
|
3304
|
+
}) {
|
|
3305
|
+
return /* @__PURE__ */ jsxs4("div", { className: "min-w-0 flex-1", children: [
|
|
3306
|
+
/* @__PURE__ */ jsxs4("div", { className: "flex min-w-0 items-center gap-2.5", children: [
|
|
3307
|
+
/* @__PURE__ */ jsx4(IssueManagerTitleTooltip, { title: task.title, children: /* @__PURE__ */ jsx4("span", { className: "truncate text-[13px] font-semibold text-[var(--text-primary)]", children: task.title }) }),
|
|
3308
|
+
/* @__PURE__ */ jsx4(Badge, { variant: issueManagerStatusBadgeVariant(task.status), children: resolveIssueManagerStatusLabel(copy, task.status) })
|
|
3309
|
+
] }),
|
|
3310
|
+
/* @__PURE__ */ jsx4("p", { className: "mt-2 line-clamp-2 text-[11px] font-normal leading-[1.5] text-[var(--text-secondary)]", children: summarizeIssueManagerContent(
|
|
3311
|
+
task.content,
|
|
3312
|
+
copy.t("messages.taskContentEmpty")
|
|
3313
|
+
) })
|
|
2537
3314
|
] });
|
|
2538
3315
|
}
|
|
2539
3316
|
|
|
@@ -2575,10 +3352,10 @@ function resolveIssueManagerVisibleSubtasks(input) {
|
|
|
2575
3352
|
}
|
|
2576
3353
|
|
|
2577
3354
|
// src/ui/internal/content/IssueManagerDescriptionSection.tsx
|
|
2578
|
-
import { useEffect as
|
|
3355
|
+
import { useEffect as useEffect5, useRef as useRef2, useState as useState5 } from "react";
|
|
2579
3356
|
import { RichTextReadonlyContent } from "@tutti-os/ui-rich-text/editor";
|
|
2580
|
-
import { cn as
|
|
2581
|
-
import { jsx as
|
|
3357
|
+
import { cn as cn3 } from "@tutti-os/ui-system";
|
|
3358
|
+
import { jsx as jsx5, jsxs as jsxs5 } from "react/jsx-runtime";
|
|
2582
3359
|
function IssueManagerDescriptionSection({
|
|
2583
3360
|
content,
|
|
2584
3361
|
emptyLabel,
|
|
@@ -2588,11 +3365,11 @@ function IssueManagerDescriptionSection({
|
|
|
2588
3365
|
onOpen,
|
|
2589
3366
|
variant = "card"
|
|
2590
3367
|
}) {
|
|
2591
|
-
const contentRef =
|
|
2592
|
-
const [isOverflowing, setIsOverflowing] =
|
|
3368
|
+
const contentRef = useRef2(null);
|
|
3369
|
+
const [isOverflowing, setIsOverflowing] = useState5(false);
|
|
2593
3370
|
const normalizedContent = normalizeIssueManagerContent(content).trim();
|
|
2594
3371
|
const displayContent = stripIssueManagerDescriptionTerminalPunctuation(normalizedContent);
|
|
2595
|
-
|
|
3372
|
+
useEffect5(() => {
|
|
2596
3373
|
if (variant === "plain") {
|
|
2597
3374
|
setIsOverflowing(false);
|
|
2598
3375
|
return;
|
|
@@ -2623,47 +3400,47 @@ function IssueManagerDescriptionSection({
|
|
|
2623
3400
|
};
|
|
2624
3401
|
}, [displayContent, variant]);
|
|
2625
3402
|
if (variant === "plain") {
|
|
2626
|
-
return /* @__PURE__ */
|
|
2627
|
-
/* @__PURE__ */
|
|
2628
|
-
displayContent ? /* @__PURE__ */
|
|
3403
|
+
return /* @__PURE__ */ jsxs5("section", { className: "grid gap-2", children: [
|
|
3404
|
+
/* @__PURE__ */ jsx5("span", { className: "text-[13px] font-semibold leading-5 text-[var(--text-primary)]", children: label }),
|
|
3405
|
+
displayContent ? /* @__PURE__ */ jsx5("div", { className: "min-w-0 max-w-full text-[13px] font-normal leading-5 text-[var(--text-secondary)] sm:max-w-3xl", children: /* @__PURE__ */ jsx5(
|
|
2629
3406
|
IssueManagerDescriptionContent,
|
|
2630
3407
|
{
|
|
2631
3408
|
content: displayContent,
|
|
2632
3409
|
onMentionAction,
|
|
2633
3410
|
onOpen
|
|
2634
3411
|
}
|
|
2635
|
-
) }) : /* @__PURE__ */
|
|
3412
|
+
) }) : /* @__PURE__ */ jsx5("p", { className: "text-[13px] font-normal leading-5 text-[var(--text-secondary)]", children: emptyLabel })
|
|
2636
3413
|
] });
|
|
2637
3414
|
}
|
|
2638
|
-
return /* @__PURE__ */
|
|
2639
|
-
/* @__PURE__ */
|
|
2640
|
-
/* @__PURE__ */
|
|
3415
|
+
return /* @__PURE__ */ jsxs5("section", { className: "grid gap-2", children: [
|
|
3416
|
+
/* @__PURE__ */ jsx5("span", { className: "text-[13px] font-semibold leading-5 text-[var(--text-primary)]", children: label }),
|
|
3417
|
+
/* @__PURE__ */ jsxs5(
|
|
2641
3418
|
"div",
|
|
2642
3419
|
{
|
|
2643
|
-
className:
|
|
3420
|
+
className: cn3(
|
|
2644
3421
|
"relative min-w-0 rounded-lg border border-border-1 bg-transparent px-4 py-3",
|
|
2645
3422
|
minHeightClass
|
|
2646
3423
|
),
|
|
2647
3424
|
children: [
|
|
2648
|
-
/* @__PURE__ */
|
|
3425
|
+
/* @__PURE__ */ jsx5(
|
|
2649
3426
|
"div",
|
|
2650
3427
|
{
|
|
2651
|
-
className:
|
|
3428
|
+
className: cn3(
|
|
2652
3429
|
"min-w-0 max-w-full overflow-x-hidden max-h-[18rem] overflow-y-auto pr-2 text-[13px] font-normal leading-5 text-[var(--text-secondary)]",
|
|
2653
3430
|
isOverflowing && "pb-8"
|
|
2654
3431
|
),
|
|
2655
3432
|
ref: contentRef,
|
|
2656
|
-
children: displayContent ? /* @__PURE__ */
|
|
3433
|
+
children: displayContent ? /* @__PURE__ */ jsx5(
|
|
2657
3434
|
IssueManagerDescriptionContent,
|
|
2658
3435
|
{
|
|
2659
3436
|
content: displayContent,
|
|
2660
3437
|
onMentionAction,
|
|
2661
3438
|
onOpen
|
|
2662
3439
|
}
|
|
2663
|
-
) : /* @__PURE__ */
|
|
3440
|
+
) : /* @__PURE__ */ jsx5("p", { className: "font-normal text-[var(--text-secondary)]", children: emptyLabel })
|
|
2664
3441
|
}
|
|
2665
3442
|
),
|
|
2666
|
-
isOverflowing ? /* @__PURE__ */
|
|
3443
|
+
isOverflowing ? /* @__PURE__ */ jsx5(
|
|
2667
3444
|
"div",
|
|
2668
3445
|
{
|
|
2669
3446
|
className: "pointer-events-none absolute right-0 bottom-1 left-0 h-10",
|
|
@@ -2682,7 +3459,7 @@ function IssueManagerDescriptionContent({
|
|
|
2682
3459
|
onMentionAction,
|
|
2683
3460
|
onOpen
|
|
2684
3461
|
}) {
|
|
2685
|
-
return /* @__PURE__ */
|
|
3462
|
+
return /* @__PURE__ */ jsx5(
|
|
2686
3463
|
RichTextReadonlyContent,
|
|
2687
3464
|
{
|
|
2688
3465
|
className: "min-w-0 max-w-full [overflow-wrap:anywhere]",
|
|
@@ -2699,10 +3476,10 @@ function IssueManagerDescriptionContent({
|
|
|
2699
3476
|
}
|
|
2700
3477
|
|
|
2701
3478
|
// src/ui/internal/content/IssueManagerRichTextTextarea.tsx
|
|
2702
|
-
import { useEffect as
|
|
3479
|
+
import { useEffect as useEffect6, useMemo as useMemo3, useRef as useRef3, useState as useState6 } from "react";
|
|
2703
3480
|
import { RichTextTriggerEditor } from "@tutti-os/ui-rich-text/editor";
|
|
2704
|
-
import { Button as Button3, LinkIcon, cn as
|
|
2705
|
-
import { jsx as
|
|
3481
|
+
import { Button as Button3, LinkIcon, cn as cn4 } from "@tutti-os/ui-system";
|
|
3482
|
+
import { jsx as jsx6, jsxs as jsxs6 } from "react/jsx-runtime";
|
|
2706
3483
|
var issueManagerRichTextTextareaBaseClassName = "min-h-20 w-full rounded-[8px] border border-transparent bg-[var(--transparency-block)] p-3 text-[13px] font-normal leading-[1.3] text-[var(--text-primary)] transition-[background-color,border-color,color] outline-none shadow-none placeholder:text-[var(--text-placeholder)] hover:bg-[var(--transparency-hover)] focus:bg-[var(--transparency-hover)] focus-visible:border-transparent focus-visible:bg-[var(--transparency-hover)] focus-visible:ring-0 disabled:cursor-not-allowed disabled:bg-[var(--transparency-block)] disabled:text-[var(--text-disabled)] disabled:opacity-100 aria-invalid:border-[var(--state-danger)] aria-invalid:bg-[var(--transparency-block)] aria-invalid:hover:bg-[var(--transparency-hover)] aria-invalid:focus:bg-[var(--transparency-hover)] aria-invalid:focus-visible:bg-[var(--transparency-hover)] aria-invalid:ring-0 aria-invalid:shadow-none";
|
|
2707
3484
|
var issueManagerRichTextPlaceholderBaseClassName = "min-h-20 w-full p-3 text-[13px] font-normal leading-[1.3] text-[var(--text-placeholder)]";
|
|
2708
3485
|
function IssueManagerRichTextTextarea({
|
|
@@ -2718,10 +3495,10 @@ function IssueManagerRichTextTextarea({
|
|
|
2718
3495
|
[controller, surface]
|
|
2719
3496
|
);
|
|
2720
3497
|
const showReferenceAction = controller.canReferenceWorkspaceFiles;
|
|
2721
|
-
const [focusSignal, setFocusSignal] =
|
|
2722
|
-
const previousValueRef =
|
|
2723
|
-
const wasAddingReferenceRef =
|
|
2724
|
-
|
|
3498
|
+
const [focusSignal, setFocusSignal] = useState6(0);
|
|
3499
|
+
const previousValueRef = useRef3(value);
|
|
3500
|
+
const wasAddingReferenceRef = useRef3(false);
|
|
3501
|
+
useEffect6(() => {
|
|
2725
3502
|
const isAddingReference = controller.referenceTarget?.mode === "insert" && controller.referenceTarget.parentKind === surface;
|
|
2726
3503
|
if (wasAddingReferenceRef.current && !isAddingReference && value !== previousValueRef.current) {
|
|
2727
3504
|
setFocusSignal((current) => current + 1);
|
|
@@ -2729,7 +3506,7 @@ function IssueManagerRichTextTextarea({
|
|
|
2729
3506
|
wasAddingReferenceRef.current = isAddingReference;
|
|
2730
3507
|
previousValueRef.current = value;
|
|
2731
3508
|
}, [controller.referenceTarget, surface, value]);
|
|
2732
|
-
return /* @__PURE__ */
|
|
3509
|
+
return /* @__PURE__ */ jsx6(
|
|
2733
3510
|
RichTextTriggerEditor,
|
|
2734
3511
|
{
|
|
2735
3512
|
focusSignal,
|
|
@@ -2741,12 +3518,12 @@ function IssueManagerRichTextTextarea({
|
|
|
2741
3518
|
noMatchesLabel: controller.copy.t("richTextAt.noMatches"),
|
|
2742
3519
|
removeReferenceActionLabel: controller.copy.t("actions.removeReference")
|
|
2743
3520
|
},
|
|
2744
|
-
textareaClassName:
|
|
3521
|
+
textareaClassName: cn4(
|
|
2745
3522
|
issueManagerRichTextTextareaBaseClassName,
|
|
2746
3523
|
textareaClassName,
|
|
2747
3524
|
showReferenceAction && "pb-11"
|
|
2748
3525
|
),
|
|
2749
|
-
placeholderClassName:
|
|
3526
|
+
placeholderClassName: cn4(
|
|
2750
3527
|
issueManagerRichTextPlaceholderBaseClassName,
|
|
2751
3528
|
textareaClassName,
|
|
2752
3529
|
showReferenceAction && "pb-11"
|
|
@@ -2754,7 +3531,7 @@ function IssueManagerRichTextTextarea({
|
|
|
2754
3531
|
placeholder,
|
|
2755
3532
|
value,
|
|
2756
3533
|
onChange,
|
|
2757
|
-
overlay: showReferenceAction ? /* @__PURE__ */
|
|
3534
|
+
overlay: showReferenceAction ? /* @__PURE__ */ jsx6("div", { className: "pointer-events-none absolute inset-x-3 bottom-3 z-10 flex", children: /* @__PURE__ */ jsxs6(
|
|
2758
3535
|
Button3,
|
|
2759
3536
|
{
|
|
2760
3537
|
className: "pointer-events-auto",
|
|
@@ -2765,7 +3542,7 @@ function IssueManagerRichTextTextarea({
|
|
|
2765
3542
|
void controller.insertReferences(surface);
|
|
2766
3543
|
},
|
|
2767
3544
|
children: [
|
|
2768
|
-
/* @__PURE__ */
|
|
3545
|
+
/* @__PURE__ */ jsx6(LinkIcon, { size: 14 }),
|
|
2769
3546
|
controller.copy.t("actions.referenceWorkspaceFiles")
|
|
2770
3547
|
]
|
|
2771
3548
|
}
|
|
@@ -2776,7 +3553,7 @@ function IssueManagerRichTextTextarea({
|
|
|
2776
3553
|
|
|
2777
3554
|
// src/ui/internal/task/IssueManagerTaskAcceptanceCard.tsx
|
|
2778
3555
|
import { Button as Button4 } from "@tutti-os/ui-system";
|
|
2779
|
-
import { jsx as
|
|
3556
|
+
import { jsx as jsx7, jsxs as jsxs7 } from "react/jsx-runtime";
|
|
2780
3557
|
function IssueManagerTaskAcceptanceCard({
|
|
2781
3558
|
controller,
|
|
2782
3559
|
taskId
|
|
@@ -2789,14 +3566,14 @@ function IssueManagerTaskAcceptanceCard({
|
|
|
2789
3566
|
}
|
|
2790
3567
|
void controller.setSelectedTaskStatus(status);
|
|
2791
3568
|
};
|
|
2792
|
-
return /* @__PURE__ */
|
|
2793
|
-
/* @__PURE__ */
|
|
2794
|
-
/* @__PURE__ */
|
|
2795
|
-
/* @__PURE__ */
|
|
2796
|
-
/* @__PURE__ */
|
|
3569
|
+
return /* @__PURE__ */ jsxs7("div", { className: "grid gap-2 rounded-md border border-[var(--tutti-purple-border)] bg-[var(--tutti-purple-bg)] px-3 py-2", children: [
|
|
3570
|
+
/* @__PURE__ */ jsxs7("div", { className: "min-w-0 text-[11px] font-normal leading-[1.45] text-[var(--text-secondary)] [overflow-wrap:anywhere]", children: [
|
|
3571
|
+
/* @__PURE__ */ jsx7("span", { className: "font-semibold text-[var(--text-primary)]", children: copy.t("labels.taskAcceptance") }),
|
|
3572
|
+
/* @__PURE__ */ jsx7("span", { className: "mx-1 text-[var(--text-tertiary)]", children: "\xB7" }),
|
|
3573
|
+
/* @__PURE__ */ jsx7("span", { children: copy.t("messages.taskAcceptanceHint") })
|
|
2797
3574
|
] }),
|
|
2798
|
-
/* @__PURE__ */
|
|
2799
|
-
/* @__PURE__ */
|
|
3575
|
+
/* @__PURE__ */ jsxs7("div", { className: "flex items-center justify-end gap-2", children: [
|
|
3576
|
+
/* @__PURE__ */ jsx7(
|
|
2800
3577
|
Button4,
|
|
2801
3578
|
{
|
|
2802
3579
|
className: "h-7 px-2 text-[11px] text-[var(--state-danger)] hover:bg-[var(--on-danger)] hover:text-[var(--state-danger)]",
|
|
@@ -2806,7 +3583,7 @@ function IssueManagerTaskAcceptanceCard({
|
|
|
2806
3583
|
children: copy.t("actions.rejectTask")
|
|
2807
3584
|
}
|
|
2808
3585
|
),
|
|
2809
|
-
/* @__PURE__ */
|
|
3586
|
+
/* @__PURE__ */ jsx7(
|
|
2810
3587
|
Button4,
|
|
2811
3588
|
{
|
|
2812
3589
|
className: "h-7 px-2.5 text-[11px]",
|
|
@@ -2822,18 +3599,18 @@ function IssueManagerTaskAcceptanceCard({
|
|
|
2822
3599
|
|
|
2823
3600
|
// src/ui/internal/shell/IssueManagerDraftTitleInput.tsx
|
|
2824
3601
|
import { useComposedInputValue } from "@tutti-os/ui-react-hooks";
|
|
2825
|
-
import { useLayoutEffect, useRef as
|
|
3602
|
+
import { useLayoutEffect as useLayoutEffect2, useRef as useRef4 } from "react";
|
|
2826
3603
|
import { Input } from "@tutti-os/ui-system";
|
|
2827
|
-
import { jsx as
|
|
3604
|
+
import { jsx as jsx8 } from "react/jsx-runtime";
|
|
2828
3605
|
function IssueManagerDraftTitleInput({
|
|
2829
3606
|
onChange,
|
|
2830
3607
|
placeholder,
|
|
2831
3608
|
value
|
|
2832
3609
|
}) {
|
|
2833
|
-
const inputRef =
|
|
2834
|
-
const pendingSelectionRef =
|
|
3610
|
+
const inputRef = useRef4(null);
|
|
3611
|
+
const pendingSelectionRef = useRef4(null);
|
|
2835
3612
|
const titleInput = useComposedInputValue({ onCommit: onChange, value });
|
|
2836
|
-
|
|
3613
|
+
useLayoutEffect2(() => {
|
|
2837
3614
|
const input = inputRef.current;
|
|
2838
3615
|
const selection = pendingSelectionRef.current;
|
|
2839
3616
|
if (!input || !selection || document.activeElement !== input) {
|
|
@@ -2859,7 +3636,7 @@ function IssueManagerDraftTitleInput({
|
|
|
2859
3636
|
start
|
|
2860
3637
|
};
|
|
2861
3638
|
};
|
|
2862
|
-
return /* @__PURE__ */
|
|
3639
|
+
return /* @__PURE__ */ jsx8(
|
|
2863
3640
|
Input,
|
|
2864
3641
|
{
|
|
2865
3642
|
ref: inputRef,
|
|
@@ -2888,7 +3665,7 @@ var issueManagerEditorRiseInDelay2ClassName = "motion-safe:[animation-delay:110m
|
|
|
2888
3665
|
var issueManagerEditorFooterFadeInClassName = "motion-safe:animate-in motion-safe:fade-in-0 motion-safe:duration-[180ms] motion-safe:ease-[cubic-bezier(0.22,1,0.36,1)] motion-safe:[animation-delay:180ms] motion-safe:[animation-fill-mode:both] motion-reduce:animate-none";
|
|
2889
3666
|
|
|
2890
3667
|
// src/ui/internal/shell/IssueManagerPanels.tsx
|
|
2891
|
-
import { jsx as
|
|
3668
|
+
import { jsx as jsx9, jsxs as jsxs8 } from "react/jsx-runtime";
|
|
2892
3669
|
function IssueManagerIssuePane({
|
|
2893
3670
|
controller,
|
|
2894
3671
|
renderLatestRunStatus,
|
|
@@ -2902,12 +3679,10 @@ function IssueManagerIssuePane({
|
|
|
2902
3679
|
const issueContent = selectedIssue?.content ?? "";
|
|
2903
3680
|
const tasks = controller.issueDetail.value?.tasks ?? [];
|
|
2904
3681
|
const selectedTaskId = controller.nodeState.selectedTaskId;
|
|
2905
|
-
const selectedTask = selectedTaskId ? (controller.taskDetail.value?.task?.taskId === selectedTaskId ? controller.taskDetail.value.task : tasks.find((task) => task.taskId === selectedTaskId)) ?? null : null;
|
|
2906
3682
|
const issueLatestRun = controller.issueDetail.value?.latestRun ?? controller.issueDetail.value?.recentRuns[0] ?? null;
|
|
2907
|
-
const
|
|
2908
|
-
const latestOutputs = selectedTask ? controller.taskDetail.value?.latestOutputs ?? [] : controller.issueDetail.value?.latestOutputs ?? [];
|
|
3683
|
+
const issueLatestOutputs = controller.issueDetail.value?.latestOutputs ?? [];
|
|
2909
3684
|
const issueAcceptanceTaskId = resolveIssueManagerIssueAcceptanceTaskId({
|
|
2910
|
-
latestRun,
|
|
3685
|
+
latestRun: issueLatestRun,
|
|
2911
3686
|
selectedIssue,
|
|
2912
3687
|
selectedTaskId,
|
|
2913
3688
|
tasks
|
|
@@ -2921,31 +3696,31 @@ function IssueManagerIssuePane({
|
|
|
2921
3696
|
hiddenIssueRunTaskId: issueRunTaskId,
|
|
2922
3697
|
tasks
|
|
2923
3698
|
});
|
|
2924
|
-
const [deleteDialogOpen, setDeleteDialogOpen] =
|
|
2925
|
-
const [deleteBusy, setDeleteBusy] =
|
|
3699
|
+
const [deleteDialogOpen, setDeleteDialogOpen] = useState7(false);
|
|
3700
|
+
const [deleteBusy, setDeleteBusy] = useState7(false);
|
|
2926
3701
|
if (isCreatingIssue || isEditingIssue) {
|
|
2927
|
-
return /* @__PURE__ */
|
|
2928
|
-
/* @__PURE__ */
|
|
3702
|
+
return /* @__PURE__ */ jsxs8("div", { className: "flex h-full min-h-0 flex-col overflow-hidden", children: [
|
|
3703
|
+
/* @__PURE__ */ jsx9(
|
|
2929
3704
|
ScrollArea2,
|
|
2930
3705
|
{
|
|
2931
3706
|
scrollbarMode: "native",
|
|
2932
3707
|
className: "min-h-0 flex-1 [&_[data-orientation=vertical][data-slot=scroll-area-scrollbar]]:opacity-100 [&_[data-slot=scroll-area-viewport]]:overscroll-contain",
|
|
2933
|
-
children: /* @__PURE__ */
|
|
2934
|
-
/* @__PURE__ */
|
|
3708
|
+
children: /* @__PURE__ */ jsx9("div", { className: "flex min-h-full flex-col gap-[14px] px-7 py-8", children: /* @__PURE__ */ jsxs8("div", { className: "flex w-full min-w-0 flex-col gap-3", children: [
|
|
3709
|
+
/* @__PURE__ */ jsx9(
|
|
2935
3710
|
"div",
|
|
2936
3711
|
{
|
|
2937
3712
|
className: `${issueManagerEditorRiseInClassName} ${issueManagerEditorRiseInDelay0ClassName}`,
|
|
2938
|
-
children: /* @__PURE__ */
|
|
3713
|
+
children: /* @__PURE__ */ jsx9("h2", { className: "m-0 text-[15px] font-semibold leading-[1.35] text-[var(--text-primary)]", children: isCreatingIssue ? copy.t("actions.createIssue") : copy.t("actions.editIssue") })
|
|
2939
3714
|
}
|
|
2940
3715
|
),
|
|
2941
|
-
/* @__PURE__ */
|
|
2942
|
-
/* @__PURE__ */
|
|
3716
|
+
/* @__PURE__ */ jsxs8("div", { className: "flex w-full min-w-0 flex-col gap-6", children: [
|
|
3717
|
+
/* @__PURE__ */ jsxs8(
|
|
2943
3718
|
"label",
|
|
2944
3719
|
{
|
|
2945
3720
|
className: `flex w-full min-w-0 flex-col gap-2 text-[13px] font-semibold text-[var(--text-secondary)] ${issueManagerEditorRiseInClassName} ${issueManagerEditorRiseInDelay1ClassName}`,
|
|
2946
3721
|
children: [
|
|
2947
|
-
/* @__PURE__ */
|
|
2948
|
-
/* @__PURE__ */
|
|
3722
|
+
/* @__PURE__ */ jsx9("span", { className: "leading-5", children: copy.t("labels.title") }),
|
|
3723
|
+
/* @__PURE__ */ jsx9(
|
|
2949
3724
|
IssueManagerDraftTitleInput,
|
|
2950
3725
|
{
|
|
2951
3726
|
placeholder: copy.t("composer.issueTitlePlaceholder"),
|
|
@@ -2956,13 +3731,13 @@ function IssueManagerIssuePane({
|
|
|
2956
3731
|
]
|
|
2957
3732
|
}
|
|
2958
3733
|
),
|
|
2959
|
-
/* @__PURE__ */
|
|
3734
|
+
/* @__PURE__ */ jsxs8(
|
|
2960
3735
|
"div",
|
|
2961
3736
|
{
|
|
2962
3737
|
className: `flex min-h-0 w-full min-w-0 flex-col gap-2 text-[13px] font-semibold text-[var(--text-secondary)] ${issueManagerEditorRiseInClassName} ${issueManagerEditorRiseInDelay2ClassName}`,
|
|
2963
3738
|
children: [
|
|
2964
|
-
/* @__PURE__ */
|
|
2965
|
-
/* @__PURE__ */
|
|
3739
|
+
/* @__PURE__ */ jsx9("span", { className: "leading-5", children: copy.t("labels.content") }),
|
|
3740
|
+
/* @__PURE__ */ jsx9(
|
|
2966
3741
|
IssueManagerRichTextTextarea,
|
|
2967
3742
|
{
|
|
2968
3743
|
controller,
|
|
@@ -2980,12 +3755,12 @@ function IssueManagerIssuePane({
|
|
|
2980
3755
|
] }) })
|
|
2981
3756
|
}
|
|
2982
3757
|
),
|
|
2983
|
-
/* @__PURE__ */
|
|
3758
|
+
/* @__PURE__ */ jsx9(
|
|
2984
3759
|
"div",
|
|
2985
3760
|
{
|
|
2986
3761
|
className: `shrink-0 border-t border-border-1 px-7 py-4 ${issueManagerEditorFooterFadeInClassName}`,
|
|
2987
|
-
children: /* @__PURE__ */
|
|
2988
|
-
/* @__PURE__ */
|
|
3762
|
+
children: /* @__PURE__ */ jsxs8("div", { className: "flex items-center justify-end gap-3", children: [
|
|
3763
|
+
/* @__PURE__ */ jsx9(
|
|
2989
3764
|
Button5,
|
|
2990
3765
|
{
|
|
2991
3766
|
size: "dialog",
|
|
@@ -2995,7 +3770,7 @@ function IssueManagerIssuePane({
|
|
|
2995
3770
|
children: copy.t("actions.cancel")
|
|
2996
3771
|
}
|
|
2997
3772
|
),
|
|
2998
|
-
/* @__PURE__ */
|
|
3773
|
+
/* @__PURE__ */ jsx9(
|
|
2999
3774
|
Button5,
|
|
3000
3775
|
{
|
|
3001
3776
|
disabled: isIssueTitleMissing,
|
|
@@ -3011,19 +3786,19 @@ function IssueManagerIssuePane({
|
|
|
3011
3786
|
] });
|
|
3012
3787
|
}
|
|
3013
3788
|
if (!selectedIssue) {
|
|
3014
|
-
return /* @__PURE__ */
|
|
3789
|
+
return /* @__PURE__ */ jsx9("div", { className: "h-full min-h-0" });
|
|
3015
3790
|
}
|
|
3016
|
-
return /* @__PURE__ */
|
|
3791
|
+
return /* @__PURE__ */ jsx9("div", { className: "flex h-full min-h-0 flex-col overflow-hidden", children: /* @__PURE__ */ jsx9(
|
|
3017
3792
|
ScrollArea2,
|
|
3018
3793
|
{
|
|
3019
3794
|
scrollbarMode: "native",
|
|
3020
3795
|
className: "min-h-0 flex-1 [&_[data-orientation=vertical][data-slot=scroll-area-scrollbar]]:opacity-100 [&_[data-slot=scroll-area-viewport]]:overscroll-contain",
|
|
3021
|
-
children: /* @__PURE__ */
|
|
3022
|
-
/* @__PURE__ */
|
|
3023
|
-
/* @__PURE__ */
|
|
3024
|
-
/* @__PURE__ */
|
|
3025
|
-
/* @__PURE__ */
|
|
3026
|
-
/* @__PURE__ */
|
|
3796
|
+
children: /* @__PURE__ */ jsx9("div", { className: "px-8 py-7", children: controller.issueDetail.isLoading && controller.issueDetail.value === null ? /* @__PURE__ */ jsx9(IssueManagerPaneLoadingState, {}) : /* @__PURE__ */ jsxs8("div", { className: "flex w-full min-w-0 flex-col gap-9", children: [
|
|
3797
|
+
/* @__PURE__ */ jsxs8("header", { className: "grid gap-3", children: [
|
|
3798
|
+
/* @__PURE__ */ jsxs8("div", { className: "flex items-center justify-between gap-6", children: [
|
|
3799
|
+
/* @__PURE__ */ jsx9(IssueManagerTitleTooltip, { title: selectedIssue.title, children: /* @__PURE__ */ jsx9("h2", { className: "line-clamp-2 min-w-0 flex-1 whitespace-normal text-[15px] font-semibold leading-6 text-[var(--text-primary)] [overflow-wrap:anywhere]", children: selectedIssue.title }) }),
|
|
3800
|
+
/* @__PURE__ */ jsxs8("div", { className: "flex shrink-0 items-center gap-2", children: [
|
|
3801
|
+
/* @__PURE__ */ jsx9(
|
|
3027
3802
|
Button5,
|
|
3028
3803
|
{
|
|
3029
3804
|
type: "button",
|
|
@@ -3032,7 +3807,7 @@ function IssueManagerIssuePane({
|
|
|
3032
3807
|
children: copy.t("actions.edit")
|
|
3033
3808
|
}
|
|
3034
3809
|
),
|
|
3035
|
-
/* @__PURE__ */
|
|
3810
|
+
/* @__PURE__ */ jsx9(
|
|
3036
3811
|
Button5,
|
|
3037
3812
|
{
|
|
3038
3813
|
className: "text-[var(--state-danger)] hover:bg-[var(--on-danger)] hover:text-[var(--state-danger)]",
|
|
@@ -3044,8 +3819,8 @@ function IssueManagerIssuePane({
|
|
|
3044
3819
|
)
|
|
3045
3820
|
] })
|
|
3046
3821
|
] }),
|
|
3047
|
-
/* @__PURE__ */
|
|
3048
|
-
/* @__PURE__ */
|
|
3822
|
+
/* @__PURE__ */ jsxs8("div", { className: "flex flex-wrap items-center gap-x-2 gap-y-2 text-[11px] font-normal leading-[1.3] text-[var(--text-secondary)]", children: [
|
|
3823
|
+
/* @__PURE__ */ jsx9(
|
|
3049
3824
|
Badge2,
|
|
3050
3825
|
{
|
|
3051
3826
|
variant: issueManagerStatusBadgeVariant(
|
|
@@ -3054,32 +3829,32 @@ function IssueManagerIssuePane({
|
|
|
3054
3829
|
children: resolveIssueManagerStatusLabel(copy, selectedIssue.status)
|
|
3055
3830
|
}
|
|
3056
3831
|
),
|
|
3057
|
-
/* @__PURE__ */
|
|
3832
|
+
/* @__PURE__ */ jsx9(
|
|
3058
3833
|
"span",
|
|
3059
3834
|
{
|
|
3060
3835
|
"aria-hidden": "true",
|
|
3061
3836
|
className: "h-4 w-px shrink-0 bg-[var(--line-2)]"
|
|
3062
3837
|
}
|
|
3063
3838
|
),
|
|
3064
|
-
/* @__PURE__ */
|
|
3839
|
+
/* @__PURE__ */ jsxs8("span", { className: "text-[11px] font-normal leading-[1.3]", children: [
|
|
3065
3840
|
copy.t("labels.creator"),
|
|
3066
3841
|
" ",
|
|
3067
3842
|
resolveIssueManagerCreatorLabel(selectedIssue)
|
|
3068
3843
|
] }),
|
|
3069
|
-
/* @__PURE__ */
|
|
3844
|
+
/* @__PURE__ */ jsx9(
|
|
3070
3845
|
"span",
|
|
3071
3846
|
{
|
|
3072
3847
|
"aria-hidden": "true",
|
|
3073
3848
|
className: "h-4 w-px shrink-0 bg-[var(--line-2)]"
|
|
3074
3849
|
}
|
|
3075
3850
|
),
|
|
3076
|
-
/* @__PURE__ */
|
|
3851
|
+
/* @__PURE__ */ jsxs8("span", { className: "text-[11px] font-normal leading-[1.3]", children: [
|
|
3077
3852
|
copy.t("labels.createdAt"),
|
|
3078
3853
|
" ",
|
|
3079
3854
|
formatIssueManagerTimestamp(selectedIssue.createdAtUnix) || "-"
|
|
3080
3855
|
] })
|
|
3081
3856
|
] }),
|
|
3082
|
-
issueAcceptanceTaskId ? /* @__PURE__ */
|
|
3857
|
+
issueAcceptanceTaskId ? /* @__PURE__ */ jsx9(
|
|
3083
3858
|
IssueManagerTaskAcceptanceCard,
|
|
3084
3859
|
{
|
|
3085
3860
|
controller,
|
|
@@ -3087,7 +3862,7 @@ function IssueManagerIssuePane({
|
|
|
3087
3862
|
}
|
|
3088
3863
|
) : null
|
|
3089
3864
|
] }),
|
|
3090
|
-
/* @__PURE__ */
|
|
3865
|
+
/* @__PURE__ */ jsx9(
|
|
3091
3866
|
ConfirmationDialog,
|
|
3092
3867
|
{
|
|
3093
3868
|
cancelLabel: copy.t("actions.cancel"),
|
|
@@ -3107,7 +3882,7 @@ function IssueManagerIssuePane({
|
|
|
3107
3882
|
onOpenChange: setDeleteDialogOpen
|
|
3108
3883
|
}
|
|
3109
3884
|
),
|
|
3110
|
-
/* @__PURE__ */
|
|
3885
|
+
/* @__PURE__ */ jsx9(
|
|
3111
3886
|
IssueManagerDescriptionSection,
|
|
3112
3887
|
{
|
|
3113
3888
|
content: issueContent,
|
|
@@ -3118,32 +3893,33 @@ function IssueManagerIssuePane({
|
|
|
3118
3893
|
variant: "plain"
|
|
3119
3894
|
}
|
|
3120
3895
|
),
|
|
3121
|
-
/* @__PURE__ */
|
|
3896
|
+
/* @__PURE__ */ jsx9(
|
|
3122
3897
|
IssueManagerLatestRunStatusSection,
|
|
3123
3898
|
{
|
|
3124
3899
|
copy,
|
|
3125
|
-
latestRun,
|
|
3900
|
+
latestRun: issueLatestRun,
|
|
3126
3901
|
onOpenAgentSession: controller.canOpenAgentSessions ? controller.openAgentSession : void 0,
|
|
3127
3902
|
renderLatestRunStatus,
|
|
3128
|
-
title:
|
|
3903
|
+
title: selectedIssue.title
|
|
3129
3904
|
}
|
|
3130
3905
|
),
|
|
3131
|
-
/* @__PURE__ */
|
|
3906
|
+
/* @__PURE__ */ jsx9(
|
|
3132
3907
|
IssueManagerOutputSection,
|
|
3133
3908
|
{
|
|
3134
3909
|
copy,
|
|
3135
|
-
outputs:
|
|
3910
|
+
outputs: issueLatestOutputs,
|
|
3136
3911
|
onOpen: controller.openReference
|
|
3137
3912
|
}
|
|
3138
3913
|
),
|
|
3139
|
-
/* @__PURE__ */
|
|
3914
|
+
/* @__PURE__ */ jsx9(
|
|
3140
3915
|
IssueManagerSubtaskSection,
|
|
3141
3916
|
{
|
|
3142
3917
|
copy,
|
|
3143
3918
|
diagnostics: controller.diagnostics,
|
|
3144
3919
|
onCreate: controller.createTaskDraft,
|
|
3920
|
+
onMoveTask: controller.moveTask,
|
|
3145
3921
|
onSelectTask: controller.selectTask,
|
|
3146
|
-
selectedTaskId
|
|
3922
|
+
selectedTaskId,
|
|
3147
3923
|
tasks: visibleTasks
|
|
3148
3924
|
}
|
|
3149
3925
|
)
|
|
@@ -3153,26 +3929,24 @@ function IssueManagerIssuePane({
|
|
|
3153
3929
|
}
|
|
3154
3930
|
|
|
3155
3931
|
// src/ui/internal/shell/IssueManagerBottomBar.tsx
|
|
3156
|
-
import { Button as Button7, cn as
|
|
3932
|
+
import { Button as Button7, cn as cn6 } from "@tutti-os/ui-system";
|
|
3157
3933
|
|
|
3158
3934
|
// src/ui/internal/task/IssueManagerRunSections.tsx
|
|
3159
3935
|
import {
|
|
3160
3936
|
Badge as Badge3,
|
|
3161
3937
|
AgentSessionsIcon as AgentSessionsIcon2,
|
|
3162
3938
|
Button as Button6,
|
|
3163
|
-
CheckIcon,
|
|
3164
3939
|
ChevronDownIcon,
|
|
3165
3940
|
DropdownMenu,
|
|
3166
3941
|
DropdownMenuContent,
|
|
3167
3942
|
DropdownMenuItem,
|
|
3168
3943
|
DropdownMenuTrigger,
|
|
3169
3944
|
IssueIcon,
|
|
3170
|
-
cn as
|
|
3945
|
+
cn as cn5
|
|
3171
3946
|
} from "@tutti-os/ui-system";
|
|
3172
3947
|
import { WorkspaceUserProjectSelect } from "@tutti-os/workspace-user-project/ui";
|
|
3173
|
-
import { Fragment, jsx as
|
|
3174
|
-
var providerMenuItemClassName = "min-h-8 overflow-hidden rounded-md
|
|
3175
|
-
var providerMenuItemCheckClassName = "pointer-events-none absolute right-2 top-1/2 shrink-0 -translate-y-1/2";
|
|
3948
|
+
import { Fragment, jsx as jsx10, jsxs as jsxs9 } from "react/jsx-runtime";
|
|
3949
|
+
var providerMenuItemClassName = "min-h-8 overflow-hidden rounded-md px-2.5 py-1.5 text-[13px] font-normal leading-[1.2] text-[var(--text-primary)]";
|
|
3176
3950
|
var providerActionTriggerClassName = "font-[var(--font-weight-emphasis-cjk)]";
|
|
3177
3951
|
function IssueManagerRunActionTrigger({
|
|
3178
3952
|
controller,
|
|
@@ -3180,12 +3954,12 @@ function IssueManagerRunActionTrigger({
|
|
|
3180
3954
|
triggerClassName,
|
|
3181
3955
|
triggerVariant = "default"
|
|
3182
3956
|
}) {
|
|
3183
|
-
return /* @__PURE__ */
|
|
3957
|
+
return /* @__PURE__ */ jsx10(
|
|
3184
3958
|
IssueManagerProviderActionMenu,
|
|
3185
3959
|
{
|
|
3186
3960
|
controller,
|
|
3187
3961
|
disabled,
|
|
3188
|
-
icon: /* @__PURE__ */
|
|
3962
|
+
icon: /* @__PURE__ */ jsx10(AgentSessionsIcon2, { size: 16 }),
|
|
3189
3963
|
label: controller.copy.t("actions.askAgentToRun"),
|
|
3190
3964
|
triggerClassName,
|
|
3191
3965
|
triggerVariant,
|
|
@@ -3199,12 +3973,12 @@ function IssueManagerBreakdownActionTrigger({
|
|
|
3199
3973
|
triggerClassName,
|
|
3200
3974
|
triggerVariant = "default"
|
|
3201
3975
|
}) {
|
|
3202
|
-
return /* @__PURE__ */
|
|
3976
|
+
return /* @__PURE__ */ jsx10(
|
|
3203
3977
|
IssueManagerProviderActionMenu,
|
|
3204
3978
|
{
|
|
3205
3979
|
controller,
|
|
3206
3980
|
disabled,
|
|
3207
|
-
icon: /* @__PURE__ */
|
|
3981
|
+
icon: /* @__PURE__ */ jsx10(IssueIcon, { size: 16 }),
|
|
3208
3982
|
label: controller.copy.t("actions.askAgentToBreakdown"),
|
|
3209
3983
|
triggerClassName,
|
|
3210
3984
|
triggerVariant,
|
|
@@ -3224,12 +3998,11 @@ function IssueManagerProviderActionMenu({
|
|
|
3224
3998
|
triggerVariant
|
|
3225
3999
|
}) {
|
|
3226
4000
|
const providerOptions = controller.providerOptions;
|
|
3227
|
-
|
|
3228
|
-
|
|
3229
|
-
/* @__PURE__ */ jsx9(DropdownMenuTrigger, { asChild: true, disabled, children: /* @__PURE__ */ jsxs8(
|
|
4001
|
+
return /* @__PURE__ */ jsxs9(DropdownMenu, { children: [
|
|
4002
|
+
/* @__PURE__ */ jsx10(DropdownMenuTrigger, { asChild: true, disabled, children: /* @__PURE__ */ jsxs9(
|
|
3230
4003
|
Button6,
|
|
3231
4004
|
{
|
|
3232
|
-
className:
|
|
4005
|
+
className: cn5(
|
|
3233
4006
|
"min-w-0",
|
|
3234
4007
|
"[&[data-state=open]_[data-issue-manager-provider-chevron=true]]:rotate-180",
|
|
3235
4008
|
providerActionTriggerClassName,
|
|
@@ -3241,8 +4014,8 @@ function IssueManagerProviderActionMenu({
|
|
|
3241
4014
|
variant: triggerButtonVariant,
|
|
3242
4015
|
children: [
|
|
3243
4016
|
icon,
|
|
3244
|
-
/* @__PURE__ */
|
|
3245
|
-
/* @__PURE__ */
|
|
4017
|
+
/* @__PURE__ */ jsx10("span", { className: "truncate", children: label }),
|
|
4018
|
+
/* @__PURE__ */ jsx10(
|
|
3246
4019
|
ChevronDownIcon,
|
|
3247
4020
|
{
|
|
3248
4021
|
className: "shrink-0 transition-transform duration-200",
|
|
@@ -3253,13 +4026,13 @@ function IssueManagerProviderActionMenu({
|
|
|
3253
4026
|
]
|
|
3254
4027
|
}
|
|
3255
4028
|
) }),
|
|
3256
|
-
/* @__PURE__ */
|
|
4029
|
+
/* @__PURE__ */ jsx10(
|
|
3257
4030
|
DropdownMenuContent,
|
|
3258
4031
|
{
|
|
3259
4032
|
align: "end",
|
|
3260
4033
|
className: "w-[220px] min-w-[220px]",
|
|
3261
4034
|
style: { zIndex: "var(--z-panel-popover)" },
|
|
3262
|
-
children: providerOptions.length === 0 ? /* @__PURE__ */
|
|
4035
|
+
children: providerOptions.length === 0 ? /* @__PURE__ */ jsx10(DropdownMenuItem, { className: providerMenuItemClassName, disabled: true, children: controller.copy.t("messages.noAgentProviders") }) : providerOptions.map((option) => /* @__PURE__ */ jsx10(
|
|
3263
4036
|
DropdownMenuItem,
|
|
3264
4037
|
{
|
|
3265
4038
|
className: providerMenuItemClassName,
|
|
@@ -3268,22 +4041,15 @@ function IssueManagerProviderActionMenu({
|
|
|
3268
4041
|
onSelect: () => {
|
|
3269
4042
|
void onSelectProvider(option.provider);
|
|
3270
4043
|
},
|
|
3271
|
-
children: /* @__PURE__ */
|
|
3272
|
-
/* @__PURE__ */
|
|
4044
|
+
children: /* @__PURE__ */ jsxs9("span", { className: "flex min-w-0 flex-1 items-center gap-2 pr-1", children: [
|
|
4045
|
+
/* @__PURE__ */ jsx10(
|
|
3273
4046
|
IssueManagerAgentProviderIcon,
|
|
3274
4047
|
{
|
|
3275
|
-
fallbackIcon: /* @__PURE__ */
|
|
4048
|
+
fallbackIcon: /* @__PURE__ */ jsx10(AgentSessionsIcon2, { "aria-hidden": true, size: 15 }),
|
|
3276
4049
|
iconUrl: option.iconUrl
|
|
3277
4050
|
}
|
|
3278
4051
|
),
|
|
3279
|
-
/* @__PURE__ */
|
|
3280
|
-
option.provider === selectedProvider ? /* @__PURE__ */ jsx9(
|
|
3281
|
-
CheckIcon,
|
|
3282
|
-
{
|
|
3283
|
-
className: providerMenuItemCheckClassName,
|
|
3284
|
-
size: 15
|
|
3285
|
-
}
|
|
3286
|
-
) : null
|
|
4052
|
+
/* @__PURE__ */ jsx10("span", { className: "min-w-0 flex-1 truncate", children: option.label })
|
|
3287
4053
|
] })
|
|
3288
4054
|
},
|
|
3289
4055
|
option.provider
|
|
@@ -3298,9 +4064,9 @@ function IssueManagerAgentProviderIcon({
|
|
|
3298
4064
|
}) {
|
|
3299
4065
|
const normalizedIconUrl = iconUrl?.trim();
|
|
3300
4066
|
if (!normalizedIconUrl) {
|
|
3301
|
-
return /* @__PURE__ */
|
|
4067
|
+
return /* @__PURE__ */ jsx10(Fragment, { children: fallbackIcon });
|
|
3302
4068
|
}
|
|
3303
|
-
return /* @__PURE__ */
|
|
4069
|
+
return /* @__PURE__ */ jsx10(
|
|
3304
4070
|
"img",
|
|
3305
4071
|
{
|
|
3306
4072
|
alt: "",
|
|
@@ -3320,13 +4086,13 @@ function IssueManagerExecutionDirectoryTrigger({
|
|
|
3320
4086
|
if (!controller.canSelectExecutionDirectory) {
|
|
3321
4087
|
return null;
|
|
3322
4088
|
}
|
|
3323
|
-
return /* @__PURE__ */
|
|
4089
|
+
return /* @__PURE__ */ jsx10(
|
|
3324
4090
|
WorkspaceUserProjectSelect,
|
|
3325
4091
|
{
|
|
3326
4092
|
classNames: {
|
|
3327
4093
|
content: "w-[240px] min-w-[240px]",
|
|
3328
4094
|
item: "min-h-7 overflow-hidden rounded-md py-1 pr-7 pl-2.5 text-[13px] font-normal leading-[1.2] text-[var(--text-primary)]",
|
|
3329
|
-
trigger:
|
|
4095
|
+
trigger: cn5(
|
|
3330
4096
|
"group inline-flex min-h-7 max-w-[240px] min-w-0 items-center gap-1.5 overflow-hidden rounded-md border-0 bg-transparent px-0.5 py-0 text-[13px] font-normal leading-[1.2] text-[var(--text-secondary)] shadow-none outline-none hover:bg-transparent hover:text-[var(--text-primary)] focus:bg-transparent focus:text-[var(--text-primary)] focus-visible:bg-transparent focus-visible:ring-0 disabled:bg-transparent disabled:text-[var(--text-disabled)]",
|
|
3331
4097
|
className
|
|
3332
4098
|
)
|
|
@@ -3378,7 +4144,7 @@ function isIssueManagerRunControlDisabled(input) {
|
|
|
3378
4144
|
}
|
|
3379
4145
|
|
|
3380
4146
|
// src/ui/internal/shell/IssueManagerBottomBar.tsx
|
|
3381
|
-
import { jsx as
|
|
4147
|
+
import { jsx as jsx11, jsxs as jsxs10 } from "react/jsx-runtime";
|
|
3382
4148
|
function IssueManagerBottomBar({
|
|
3383
4149
|
controller,
|
|
3384
4150
|
isNarrowLayout,
|
|
@@ -3393,15 +4159,15 @@ function IssueManagerBottomBar({
|
|
|
3393
4159
|
selectedIssueStatus: selectedIssue.status,
|
|
3394
4160
|
selectedTaskStatus: null
|
|
3395
4161
|
});
|
|
3396
|
-
return /* @__PURE__ */
|
|
4162
|
+
return /* @__PURE__ */ jsx11("div", { className: "border-t border-[var(--border-1)] bg-transparent px-6 py-4 backdrop-blur", children: /* @__PURE__ */ jsxs10(
|
|
3397
4163
|
"div",
|
|
3398
4164
|
{
|
|
3399
|
-
className:
|
|
4165
|
+
className: cn6(
|
|
3400
4166
|
"flex gap-3",
|
|
3401
4167
|
isNarrowLayout ? "flex-wrap items-center justify-end" : "items-center justify-end"
|
|
3402
4168
|
),
|
|
3403
4169
|
children: [
|
|
3404
|
-
/* @__PURE__ */
|
|
4170
|
+
/* @__PURE__ */ jsx11(
|
|
3405
4171
|
IssueManagerExecutionDirectoryTrigger,
|
|
3406
4172
|
{
|
|
3407
4173
|
className: "mr-auto min-w-0 max-w-[240px] justify-start overflow-hidden",
|
|
@@ -3409,8 +4175,8 @@ function IssueManagerBottomBar({
|
|
|
3409
4175
|
disabled: runControlsDisabled
|
|
3410
4176
|
}
|
|
3411
4177
|
),
|
|
3412
|
-
/* @__PURE__ */
|
|
3413
|
-
/* @__PURE__ */
|
|
4178
|
+
/* @__PURE__ */ jsxs10("div", { className: "flex shrink-0 flex-nowrap items-center justify-end gap-3", children: [
|
|
4179
|
+
/* @__PURE__ */ jsx11(
|
|
3414
4180
|
IssueManagerBreakdownActionTrigger,
|
|
3415
4181
|
{
|
|
3416
4182
|
controller,
|
|
@@ -3418,7 +4184,7 @@ function IssueManagerBottomBar({
|
|
|
3418
4184
|
triggerVariant: "button"
|
|
3419
4185
|
}
|
|
3420
4186
|
),
|
|
3421
|
-
/* @__PURE__ */
|
|
4187
|
+
/* @__PURE__ */ jsx11(
|
|
3422
4188
|
IssueManagerRunActionTrigger,
|
|
3423
4189
|
{
|
|
3424
4190
|
controller,
|
|
@@ -3426,7 +4192,7 @@ function IssueManagerBottomBar({
|
|
|
3426
4192
|
triggerVariant: "button"
|
|
3427
4193
|
}
|
|
3428
4194
|
),
|
|
3429
|
-
controller.canInviteCollaborators ? /* @__PURE__ */
|
|
4195
|
+
controller.canInviteCollaborators ? /* @__PURE__ */ jsx11(
|
|
3430
4196
|
Button7,
|
|
3431
4197
|
{
|
|
3432
4198
|
className: "px-4",
|
|
@@ -3447,12 +4213,12 @@ function IssueManagerBottomBar({
|
|
|
3447
4213
|
|
|
3448
4214
|
// src/ui/internal/shell/IssueManagerFloatingNotice.tsx
|
|
3449
4215
|
import { ToastProvider, ToastRoot, ToastTitle } from "@tutti-os/ui-system";
|
|
3450
|
-
import { jsx as
|
|
4216
|
+
import { jsx as jsx12 } from "react/jsx-runtime";
|
|
3451
4217
|
function IssueManagerFloatingNotice({
|
|
3452
4218
|
notice
|
|
3453
4219
|
}) {
|
|
3454
4220
|
const variant = notice.tone === "destructive" ? "destructive" : "default";
|
|
3455
|
-
return /* @__PURE__ */
|
|
4221
|
+
return /* @__PURE__ */ jsx12(ToastProvider, { children: /* @__PURE__ */ jsx12(
|
|
3456
4222
|
ToastRoot,
|
|
3457
4223
|
{
|
|
3458
4224
|
open: true,
|
|
@@ -3461,14 +4227,14 @@ function IssueManagerFloatingNotice({
|
|
|
3461
4227
|
className: "z-30 w-fit max-w-[min(72vw,40rem)] px-4 py-3 shadow-lg",
|
|
3462
4228
|
nodeInsetTopPx: 16,
|
|
3463
4229
|
variant,
|
|
3464
|
-
children: /* @__PURE__ */
|
|
4230
|
+
children: /* @__PURE__ */ jsx12(ToastTitle, { className: "whitespace-normal [overflow-wrap:anywhere]", children: notice.title })
|
|
3465
4231
|
},
|
|
3466
4232
|
notice.id
|
|
3467
4233
|
) });
|
|
3468
4234
|
}
|
|
3469
4235
|
|
|
3470
4236
|
// src/ui/internal/shell/IssueManagerSidebar.tsx
|
|
3471
|
-
import { cn as
|
|
4237
|
+
import { cn as cn8 } from "@tutti-os/ui-system";
|
|
3472
4238
|
|
|
3473
4239
|
// src/ui/internal/shell/IssueManagerSidebarSections.tsx
|
|
3474
4240
|
import { useComposedInputValue as useComposedInputValue2 } from "@tutti-os/ui-react-hooks";
|
|
@@ -3480,7 +4246,7 @@ import {
|
|
|
3480
4246
|
Input as Input2,
|
|
3481
4247
|
ScrollArea as ScrollArea3,
|
|
3482
4248
|
UnderlineTabs,
|
|
3483
|
-
cn as
|
|
4249
|
+
cn as cn7
|
|
3484
4250
|
} from "@tutti-os/ui-system";
|
|
3485
4251
|
|
|
3486
4252
|
// src/ui/internal/shell/IssueManagerShellState.ts
|
|
@@ -3602,7 +4368,7 @@ function resolveIssueManagerShellContentViewState(input) {
|
|
|
3602
4368
|
}
|
|
3603
4369
|
|
|
3604
4370
|
// src/ui/internal/shell/IssueManagerSidebarSections.tsx
|
|
3605
|
-
import { jsx as
|
|
4371
|
+
import { jsx as jsx13, jsxs as jsxs11 } from "react/jsx-runtime";
|
|
3606
4372
|
function IssueManagerSidebarHeader({
|
|
3607
4373
|
copy,
|
|
3608
4374
|
issueSearchQuery,
|
|
@@ -3610,8 +4376,8 @@ function IssueManagerSidebarHeader({
|
|
|
3610
4376
|
onIssueSearchUsage,
|
|
3611
4377
|
onIssueSearchQueryChange
|
|
3612
4378
|
}) {
|
|
3613
|
-
return /* @__PURE__ */
|
|
3614
|
-
/* @__PURE__ */
|
|
4379
|
+
return /* @__PURE__ */ jsx13("div", { className: "px-4 py-4", children: /* @__PURE__ */ jsxs11("div", { className: "flex items-center gap-2.5", children: [
|
|
4380
|
+
/* @__PURE__ */ jsx13(
|
|
3615
4381
|
IssueManagerSearchField,
|
|
3616
4382
|
{
|
|
3617
4383
|
clearLabel: copy.t("actions.clearSearch"),
|
|
@@ -3621,7 +4387,7 @@ function IssueManagerSidebarHeader({
|
|
|
3621
4387
|
onSearchUsage: onIssueSearchUsage
|
|
3622
4388
|
}
|
|
3623
4389
|
),
|
|
3624
|
-
/* @__PURE__ */
|
|
4390
|
+
/* @__PURE__ */ jsxs11(
|
|
3625
4391
|
Button8,
|
|
3626
4392
|
{
|
|
3627
4393
|
className: "gap-2 px-3",
|
|
@@ -3630,7 +4396,7 @@ function IssueManagerSidebarHeader({
|
|
|
3630
4396
|
variant: "secondary",
|
|
3631
4397
|
onClick: onCreateIssue,
|
|
3632
4398
|
children: [
|
|
3633
|
-
/* @__PURE__ */
|
|
4399
|
+
/* @__PURE__ */ jsx13(FileCreateIcon3, { size: 16 }),
|
|
3634
4400
|
copy.t("actions.createIssue")
|
|
3635
4401
|
]
|
|
3636
4402
|
}
|
|
@@ -3643,7 +4409,7 @@ function IssueManagerSidebarStatusTabs({
|
|
|
3643
4409
|
statusCounts,
|
|
3644
4410
|
onIssueStatusFilterChange
|
|
3645
4411
|
}) {
|
|
3646
|
-
return /* @__PURE__ */
|
|
4412
|
+
return /* @__PURE__ */ jsx13(
|
|
3647
4413
|
UnderlineTabs,
|
|
3648
4414
|
{
|
|
3649
4415
|
ariaLabel: copy.t("labels.status"),
|
|
@@ -3669,19 +4435,19 @@ function IssueManagerSidebarBody({
|
|
|
3669
4435
|
onRetry,
|
|
3670
4436
|
onSelectIssue
|
|
3671
4437
|
}) {
|
|
3672
|
-
return /* @__PURE__ */
|
|
4438
|
+
return /* @__PURE__ */ jsx13(
|
|
3673
4439
|
ScrollArea3,
|
|
3674
4440
|
{
|
|
3675
4441
|
scrollbarMode: "native",
|
|
3676
|
-
className:
|
|
3677
|
-
children: /* @__PURE__ */
|
|
4442
|
+
className: cn7("min-h-0", isNarrowLayout ? "flex-none" : "h-full flex-1"),
|
|
4443
|
+
children: /* @__PURE__ */ jsx13(
|
|
3678
4444
|
"div",
|
|
3679
4445
|
{
|
|
3680
|
-
className:
|
|
4446
|
+
className: cn7(
|
|
3681
4447
|
"flex min-h-full flex-col gap-2.5 px-4 pt-1.5 pb-4",
|
|
3682
4448
|
isNarrowLayout ? "min-h-0" : "h-full"
|
|
3683
4449
|
),
|
|
3684
|
-
children: sidebarViewState.kind === "loading" ? /* @__PURE__ */
|
|
4450
|
+
children: sidebarViewState.kind === "loading" ? /* @__PURE__ */ jsx13(IssueManagerSidebarLoadingState, { isNarrowLayout }) : sidebarViewState.kind === "error" ? /* @__PURE__ */ jsx13(
|
|
3685
4451
|
IssueManagerSidebarErrorState,
|
|
3686
4452
|
{
|
|
3687
4453
|
isNarrowLayout,
|
|
@@ -3689,14 +4455,14 @@ function IssueManagerSidebarBody({
|
|
|
3689
4455
|
title: sidebarViewState.title,
|
|
3690
4456
|
onRetry
|
|
3691
4457
|
}
|
|
3692
|
-
) : sidebarViewState.kind === "empty" ? /* @__PURE__ */
|
|
4458
|
+
) : sidebarViewState.kind === "empty" ? /* @__PURE__ */ jsx13(
|
|
3693
4459
|
IssueManagerSidebarEmptyState,
|
|
3694
4460
|
{
|
|
3695
4461
|
body: sidebarViewState.body,
|
|
3696
4462
|
isNarrowLayout,
|
|
3697
4463
|
title: sidebarViewState.title
|
|
3698
4464
|
}
|
|
3699
|
-
) : /* @__PURE__ */
|
|
4465
|
+
) : /* @__PURE__ */ jsx13(
|
|
3700
4466
|
IssueManagerSidebarIssueList,
|
|
3701
4467
|
{
|
|
3702
4468
|
copy,
|
|
@@ -3721,7 +4487,7 @@ function IssueManagerSidebarStandalonePane({
|
|
|
3721
4487
|
onRetry
|
|
3722
4488
|
}) {
|
|
3723
4489
|
if (kind === "error" && retryLabel) {
|
|
3724
|
-
return /* @__PURE__ */
|
|
4490
|
+
return /* @__PURE__ */ jsx13(
|
|
3725
4491
|
IssueManagerSidebarErrorState,
|
|
3726
4492
|
{
|
|
3727
4493
|
isNarrowLayout,
|
|
@@ -3731,7 +4497,7 @@ function IssueManagerSidebarStandalonePane({
|
|
|
3731
4497
|
}
|
|
3732
4498
|
);
|
|
3733
4499
|
}
|
|
3734
|
-
return /* @__PURE__ */
|
|
4500
|
+
return /* @__PURE__ */ jsx13(
|
|
3735
4501
|
IssueManagerSidebarEmptyState,
|
|
3736
4502
|
{
|
|
3737
4503
|
body: body ?? "",
|
|
@@ -3748,17 +4514,17 @@ function IssueManagerSearchField({
|
|
|
3748
4514
|
value
|
|
3749
4515
|
}) {
|
|
3750
4516
|
const searchInput = useComposedInputValue2({ onCommit: onChange, value });
|
|
3751
|
-
return /* @__PURE__ */
|
|
4517
|
+
return /* @__PURE__ */ jsxs11(
|
|
3752
4518
|
"div",
|
|
3753
4519
|
{
|
|
3754
4520
|
className: "relative min-w-0 flex-1",
|
|
3755
4521
|
"data-has-value": searchInput.value ? "true" : "false",
|
|
3756
4522
|
children: [
|
|
3757
|
-
/* @__PURE__ */
|
|
4523
|
+
/* @__PURE__ */ jsx13(
|
|
3758
4524
|
Input2,
|
|
3759
4525
|
{
|
|
3760
4526
|
"aria-label": placeholder,
|
|
3761
|
-
className:
|
|
4527
|
+
className: cn7(
|
|
3762
4528
|
"box-border h-8 min-h-8 rounded-md border-0 bg-[var(--transparency-block)] px-3 text-[13px] font-normal leading-normal text-[var(--text-primary)] shadow-none outline-none ring-0 transition-colors placeholder:text-[var(--text-placeholder)] hover:bg-[var(--transparency-hover)] focus:border-0 focus:bg-[var(--transparency-hover)] focus-visible:border-0 focus-visible:bg-[var(--transparency-hover)] focus-visible:ring-0 focus-visible:ring-offset-0 disabled:bg-[var(--transparency-block)] disabled:text-[var(--text-disabled)] disabled:opacity-100",
|
|
3763
4529
|
"[&::-webkit-search-cancel-button]:appearance-none [&::-webkit-search-decoration]:appearance-none",
|
|
3764
4530
|
searchInput.value ? "pr-9" : "pr-3"
|
|
@@ -3775,7 +4541,7 @@ function IssueManagerSearchField({
|
|
|
3775
4541
|
onCompositionStart: searchInput.onCompositionStart
|
|
3776
4542
|
}
|
|
3777
4543
|
),
|
|
3778
|
-
searchInput.value ? /* @__PURE__ */
|
|
4544
|
+
searchInput.value ? /* @__PURE__ */ jsx13(
|
|
3779
4545
|
"button",
|
|
3780
4546
|
{
|
|
3781
4547
|
"aria-label": clearLabel,
|
|
@@ -3783,7 +4549,7 @@ function IssueManagerSearchField({
|
|
|
3783
4549
|
type: "button",
|
|
3784
4550
|
onClick: searchInput.clearValue,
|
|
3785
4551
|
onMouseDown: (event) => event.preventDefault(),
|
|
3786
|
-
children: /* @__PURE__ */
|
|
4552
|
+
children: /* @__PURE__ */ jsx13(CloseIcon, { className: "size-3.5" })
|
|
3787
4553
|
}
|
|
3788
4554
|
) : null
|
|
3789
4555
|
]
|
|
@@ -3798,14 +4564,14 @@ function IssueManagerSidebarIssueList({
|
|
|
3798
4564
|
subtaskProgressByIssueId,
|
|
3799
4565
|
onSelectIssue
|
|
3800
4566
|
}) {
|
|
3801
|
-
return /* @__PURE__ */
|
|
4567
|
+
return /* @__PURE__ */ jsx13(
|
|
3802
4568
|
"div",
|
|
3803
4569
|
{
|
|
3804
|
-
className:
|
|
4570
|
+
className: cn7(
|
|
3805
4571
|
"flex gap-2.5",
|
|
3806
4572
|
isNarrowLayout ? "flex-row flex-nowrap items-start overflow-x-auto overflow-y-hidden [scrollbar-width:none] [&::-webkit-scrollbar]:hidden" : "flex-col"
|
|
3807
4573
|
),
|
|
3808
|
-
children: issues.map((issue) => /* @__PURE__ */
|
|
4574
|
+
children: issues.map((issue) => /* @__PURE__ */ jsx13(
|
|
3809
4575
|
IssueManagerSidebarItem,
|
|
3810
4576
|
{
|
|
3811
4577
|
copy,
|
|
@@ -3829,10 +4595,10 @@ function IssueManagerSidebarItem({
|
|
|
3829
4595
|
subtaskProgress: subtaskProgressOverride
|
|
3830
4596
|
}) {
|
|
3831
4597
|
const subtaskProgress = subtaskProgressOverride === void 0 ? resolveIssueManagerSubtaskProgress(issue) : subtaskProgressOverride;
|
|
3832
|
-
return /* @__PURE__ */
|
|
4598
|
+
return /* @__PURE__ */ jsxs11(
|
|
3833
4599
|
"button",
|
|
3834
4600
|
{
|
|
3835
|
-
className:
|
|
4601
|
+
className: cn7(
|
|
3836
4602
|
"relative rounded-lg border px-3.5 py-3.5 text-left transition-colors",
|
|
3837
4603
|
isNarrowLayout ? "h-24 max-h-24 min-h-24 w-[clamp(220px,58vw,320px)] flex-[0_0_clamp(220px,58vw,320px)] overflow-hidden" : "w-full",
|
|
3838
4604
|
selected ? "border-[var(--border-1)] bg-[var(--background-fronted)]" : "border-[var(--border-1)] bg-transparent hover:bg-[var(--transparency-block)]"
|
|
@@ -3840,7 +4606,7 @@ function IssueManagerSidebarItem({
|
|
|
3840
4606
|
type: "button",
|
|
3841
4607
|
onClick: () => onSelect(issue.issueId),
|
|
3842
4608
|
children: [
|
|
3843
|
-
/* @__PURE__ */
|
|
4609
|
+
/* @__PURE__ */ jsx13(
|
|
3844
4610
|
Badge4,
|
|
3845
4611
|
{
|
|
3846
4612
|
className: "absolute top-3.5 right-3.5",
|
|
@@ -3848,11 +4614,11 @@ function IssueManagerSidebarItem({
|
|
|
3848
4614
|
children: resolveIssueManagerStatusLabel(copy, issue.status)
|
|
3849
4615
|
}
|
|
3850
4616
|
),
|
|
3851
|
-
/* @__PURE__ */
|
|
3852
|
-
/* @__PURE__ */
|
|
3853
|
-
/* @__PURE__ */
|
|
4617
|
+
/* @__PURE__ */ jsxs11("div", { className: "min-w-0 space-y-2", children: [
|
|
4618
|
+
/* @__PURE__ */ jsx13("p", { className: "pr-28 text-[11px] leading-[1.55] text-[var(--text-secondary)]", children: formatIssueManagerDate(issue.updatedAtUnix ?? issue.createdAtUnix) }),
|
|
4619
|
+
/* @__PURE__ */ jsx13("p", { className: "line-clamp-4 text-[13px] font-medium leading-[1.35rem] text-[var(--text-primary)]", children: issue.title })
|
|
3854
4620
|
] }),
|
|
3855
|
-
subtaskProgress ? /* @__PURE__ */
|
|
4621
|
+
subtaskProgress ? /* @__PURE__ */ jsxs11(
|
|
3856
4622
|
"div",
|
|
3857
4623
|
{
|
|
3858
4624
|
"aria-label": `${copy.t("labels.taskCount", {
|
|
@@ -3860,13 +4626,13 @@ function IssueManagerSidebarItem({
|
|
|
3860
4626
|
})}, ${subtaskProgress.completed}/${subtaskProgress.total}`,
|
|
3861
4627
|
className: "mt-3 flex min-w-0 items-center gap-2 text-[11px] font-semibold leading-none text-[var(--text-secondary)]",
|
|
3862
4628
|
children: [
|
|
3863
|
-
/* @__PURE__ */
|
|
3864
|
-
/* @__PURE__ */
|
|
4629
|
+
/* @__PURE__ */ jsx13("span", { className: "shrink-0", children: copy.t("labels.taskCount", { count: subtaskProgress.total }) }),
|
|
4630
|
+
/* @__PURE__ */ jsx13(
|
|
3865
4631
|
"span",
|
|
3866
4632
|
{
|
|
3867
4633
|
"aria-hidden": "true",
|
|
3868
|
-
className: "h-
|
|
3869
|
-
children: /* @__PURE__ */
|
|
4634
|
+
className: "h-1 w-14 shrink-0 overflow-hidden rounded-full bg-[var(--transparency-block)]",
|
|
4635
|
+
children: /* @__PURE__ */ jsx13(
|
|
3870
4636
|
"span",
|
|
3871
4637
|
{
|
|
3872
4638
|
className: "block h-full rounded-full bg-[var(--status-running)]",
|
|
@@ -3875,7 +4641,7 @@ function IssueManagerSidebarItem({
|
|
|
3875
4641
|
)
|
|
3876
4642
|
}
|
|
3877
4643
|
),
|
|
3878
|
-
/* @__PURE__ */
|
|
4644
|
+
/* @__PURE__ */ jsxs11("span", { className: "shrink-0 text-[11px] font-semibold leading-none text-[var(--text-secondary)]", children: [
|
|
3879
4645
|
subtaskProgress.completed,
|
|
3880
4646
|
"/",
|
|
3881
4647
|
subtaskProgress.total
|
|
@@ -3890,25 +4656,25 @@ function IssueManagerSidebarItem({
|
|
|
3890
4656
|
function IssueManagerSidebarLoadingState({
|
|
3891
4657
|
isNarrowLayout
|
|
3892
4658
|
}) {
|
|
3893
|
-
return /* @__PURE__ */
|
|
4659
|
+
return /* @__PURE__ */ jsx13(
|
|
3894
4660
|
"div",
|
|
3895
4661
|
{
|
|
3896
4662
|
"aria-hidden": "true",
|
|
3897
|
-
className:
|
|
4663
|
+
className: cn7(
|
|
3898
4664
|
"gap-2.5",
|
|
3899
4665
|
isNarrowLayout ? "flex flex-row flex-nowrap overflow-x-hidden" : "grid"
|
|
3900
4666
|
),
|
|
3901
|
-
children: Array.from({ length: 4 }, (_, index) => /* @__PURE__ */
|
|
4667
|
+
children: Array.from({ length: 4 }, (_, index) => /* @__PURE__ */ jsxs11(
|
|
3902
4668
|
"div",
|
|
3903
4669
|
{
|
|
3904
|
-
className:
|
|
4670
|
+
className: cn7(
|
|
3905
4671
|
"rounded-lg bg-transparent px-3.5 py-3.5",
|
|
3906
4672
|
isNarrowLayout && "h-24 max-h-24 min-h-24 w-[clamp(220px,58vw,320px)] flex-[0_0_clamp(220px,58vw,320px)]"
|
|
3907
4673
|
),
|
|
3908
4674
|
children: [
|
|
3909
|
-
/* @__PURE__ */
|
|
3910
|
-
/* @__PURE__ */
|
|
3911
|
-
/* @__PURE__ */
|
|
4675
|
+
/* @__PURE__ */ jsx13("div", { className: "h-3.5 w-20 rounded-full bg-[var(--transparency-block)]" }),
|
|
4676
|
+
/* @__PURE__ */ jsx13("div", { className: "mt-3 h-4 w-4/5 rounded-full bg-[var(--transparency-block)]" }),
|
|
4677
|
+
/* @__PURE__ */ jsx13("div", { className: "mt-4 h-3.5 w-24 rounded-full bg-[var(--transparency-block)]" })
|
|
3912
4678
|
]
|
|
3913
4679
|
},
|
|
3914
4680
|
index
|
|
@@ -3921,17 +4687,17 @@ function IssueManagerSidebarEmptyState({
|
|
|
3921
4687
|
title,
|
|
3922
4688
|
tone = "default"
|
|
3923
4689
|
}) {
|
|
3924
|
-
return /* @__PURE__ */
|
|
4690
|
+
return /* @__PURE__ */ jsx13(
|
|
3925
4691
|
"div",
|
|
3926
4692
|
{
|
|
3927
|
-
className:
|
|
4693
|
+
className: cn7(
|
|
3928
4694
|
"relative flex flex-1 flex-col items-center justify-center self-stretch overflow-hidden p-0 text-center",
|
|
3929
4695
|
isNarrowLayout ? "h-24 max-h-24 min-h-24 w-full flex-[0_0_100%]" : "min-h-full"
|
|
3930
4696
|
),
|
|
3931
|
-
children: /* @__PURE__ */
|
|
4697
|
+
children: /* @__PURE__ */ jsx13(
|
|
3932
4698
|
"p",
|
|
3933
4699
|
{
|
|
3934
|
-
className:
|
|
4700
|
+
className: cn7(
|
|
3935
4701
|
"max-w-sm text-[13px] leading-5 text-[var(--text-secondary)]",
|
|
3936
4702
|
tone === "destructive" ? "text-[var(--state-danger)]" : "text-[var(--text-secondary)]"
|
|
3937
4703
|
),
|
|
@@ -3947,16 +4713,16 @@ function IssueManagerSidebarErrorState({
|
|
|
3947
4713
|
title,
|
|
3948
4714
|
onRetry
|
|
3949
4715
|
}) {
|
|
3950
|
-
return /* @__PURE__ */
|
|
4716
|
+
return /* @__PURE__ */ jsxs11(
|
|
3951
4717
|
"div",
|
|
3952
4718
|
{
|
|
3953
|
-
className:
|
|
4719
|
+
className: cn7(
|
|
3954
4720
|
"relative flex flex-1 flex-col items-center justify-center self-stretch overflow-hidden px-4 py-6 text-center",
|
|
3955
4721
|
isNarrowLayout ? "h-24 max-h-24 min-h-24 w-full flex-[0_0_100%]" : "min-h-full"
|
|
3956
4722
|
),
|
|
3957
4723
|
children: [
|
|
3958
|
-
/* @__PURE__ */
|
|
3959
|
-
/* @__PURE__ */
|
|
4724
|
+
/* @__PURE__ */ jsx13("p", { className: "text-[13px] font-semibold leading-5 text-[var(--state-danger)]", children: title }),
|
|
4725
|
+
/* @__PURE__ */ jsx13(
|
|
3960
4726
|
Button8,
|
|
3961
4727
|
{
|
|
3962
4728
|
className: "mt-3",
|
|
@@ -3996,7 +4762,7 @@ function resolveIssueManagerSidebarPresentationState(input) {
|
|
|
3996
4762
|
}
|
|
3997
4763
|
|
|
3998
4764
|
// src/ui/internal/shell/IssueManagerSidebar.tsx
|
|
3999
|
-
import { jsx as
|
|
4765
|
+
import { jsx as jsx14, jsxs as jsxs12 } from "react/jsx-runtime";
|
|
4000
4766
|
function IssueManagerSidebar({
|
|
4001
4767
|
controller,
|
|
4002
4768
|
isCollapsed,
|
|
@@ -4024,18 +4790,18 @@ function IssueManagerSidebar({
|
|
|
4024
4790
|
issueId: currentIssueDetail?.issue.issueId ?? null,
|
|
4025
4791
|
visibleTasks: currentIssueDetail ? visibleTasks : null
|
|
4026
4792
|
});
|
|
4027
|
-
return /* @__PURE__ */
|
|
4793
|
+
return /* @__PURE__ */ jsxs12(
|
|
4028
4794
|
"aside",
|
|
4029
4795
|
{
|
|
4030
4796
|
"aria-hidden": isCollapsed ? "true" : void 0,
|
|
4031
|
-
className:
|
|
4797
|
+
className: cn8(
|
|
4032
4798
|
"relative isolate flex h-full min-h-0 min-w-0 flex-col overflow-hidden bg-transparent opacity-100 transition-[border-color] duration-[140ms] ease-in-out after:pointer-events-none after:absolute after:inset-0 after:z-[1] after:bg-[color-mix(in_srgb,var(--background-panel)_88%,transparent)] after:opacity-0 after:transition-opacity after:duration-[160ms] after:delay-[70ms] motion-reduce:transition-none motion-reduce:after:transition-none [&>*]:transition-[opacity,filter] [&>*]:duration-[160ms] [&>*]:delay-[70ms] [&>*]:ease-in-out motion-reduce:[&>*]:transition-none",
|
|
4033
4799
|
isNarrowLayout ? "border-b border-[var(--border-1)]" : "border-r border-[var(--border-1)]",
|
|
4034
4800
|
isCollapsed && "pointer-events-none border-r-transparent after:opacity-100 after:delay-0 [&>*]:opacity-0 [&>*]:blur-[1px] [&>*]:delay-0 motion-reduce:[&>*]:blur-none"
|
|
4035
4801
|
),
|
|
4036
4802
|
inert: isCollapsed ? true : void 0,
|
|
4037
4803
|
children: [
|
|
4038
|
-
/* @__PURE__ */
|
|
4804
|
+
/* @__PURE__ */ jsx14(
|
|
4039
4805
|
IssueManagerSidebarHeader,
|
|
4040
4806
|
{
|
|
4041
4807
|
copy,
|
|
@@ -4045,7 +4811,7 @@ function IssueManagerSidebar({
|
|
|
4045
4811
|
onIssueSearchQueryChange: controller.setIssueSearchQuery
|
|
4046
4812
|
}
|
|
4047
4813
|
),
|
|
4048
|
-
/* @__PURE__ */
|
|
4814
|
+
/* @__PURE__ */ jsx14(
|
|
4049
4815
|
IssueManagerSidebarStatusTabs,
|
|
4050
4816
|
{
|
|
4051
4817
|
copy,
|
|
@@ -4054,15 +4820,15 @@ function IssueManagerSidebar({
|
|
|
4054
4820
|
onIssueStatusFilterChange: controller.setIssueStatusFilter
|
|
4055
4821
|
}
|
|
4056
4822
|
),
|
|
4057
|
-
/* @__PURE__ */
|
|
4058
|
-
/* @__PURE__ */
|
|
4823
|
+
/* @__PURE__ */ jsx14("div", { "aria-hidden": "true", className: "h-2.5 flex-none" }),
|
|
4824
|
+
/* @__PURE__ */ jsx14(
|
|
4059
4825
|
"div",
|
|
4060
4826
|
{
|
|
4061
|
-
className:
|
|
4827
|
+
className: cn8(
|
|
4062
4828
|
"relative flex min-h-0 flex-col",
|
|
4063
4829
|
isNarrowLayout ? "flex-none" : "flex-1"
|
|
4064
4830
|
),
|
|
4065
|
-
children: presentation.kind !== "none" ? /* @__PURE__ */
|
|
4831
|
+
children: presentation.kind !== "none" ? /* @__PURE__ */ jsx14("div", { className: "flex h-full min-h-0 items-center justify-center px-4 pt-1.5 pb-4", children: /* @__PURE__ */ jsx14(
|
|
4066
4832
|
IssueManagerSidebarStandalonePane,
|
|
4067
4833
|
{
|
|
4068
4834
|
body: presentation.kind === "empty" ? presentation.body : void 0,
|
|
@@ -4072,7 +4838,7 @@ function IssueManagerSidebar({
|
|
|
4072
4838
|
title: presentation.title,
|
|
4073
4839
|
onRetry: () => controller.refreshAll()
|
|
4074
4840
|
}
|
|
4075
|
-
) }) : /* @__PURE__ */
|
|
4841
|
+
) }) : /* @__PURE__ */ jsx14(
|
|
4076
4842
|
IssueManagerSidebarBody,
|
|
4077
4843
|
{
|
|
4078
4844
|
copy,
|
|
@@ -4093,7 +4859,7 @@ function IssueManagerSidebar({
|
|
|
4093
4859
|
|
|
4094
4860
|
// src/ui/internal/shell/IssueManagerTaskComposerPane.tsx
|
|
4095
4861
|
import { Button as Button9 } from "@tutti-os/ui-system";
|
|
4096
|
-
import { jsx as
|
|
4862
|
+
import { jsx as jsx15, jsxs as jsxs13 } from "react/jsx-runtime";
|
|
4097
4863
|
function IssueManagerTaskComposerPane({
|
|
4098
4864
|
controller,
|
|
4099
4865
|
onCancel,
|
|
@@ -4101,23 +4867,23 @@ function IssueManagerTaskComposerPane({
|
|
|
4101
4867
|
}) {
|
|
4102
4868
|
const copy = controller.copy;
|
|
4103
4869
|
const isTaskTitleMissing = controller.taskDraft.title.trim().length === 0;
|
|
4104
|
-
return /* @__PURE__ */
|
|
4105
|
-
/* @__PURE__ */
|
|
4106
|
-
/* @__PURE__ */
|
|
4870
|
+
return /* @__PURE__ */ jsxs13("div", { className: "flex h-full min-h-0 flex-col overflow-hidden", children: [
|
|
4871
|
+
/* @__PURE__ */ jsx15("div", { className: "flex min-h-0 flex-1 flex-col gap-[14px] overflow-y-auto px-7 py-8", children: /* @__PURE__ */ jsxs13("div", { className: "flex w-full min-w-0 flex-col gap-3", children: [
|
|
4872
|
+
/* @__PURE__ */ jsx15(
|
|
4107
4873
|
"div",
|
|
4108
4874
|
{
|
|
4109
4875
|
className: `${issueManagerEditorRiseInClassName} ${issueManagerEditorRiseInDelay0ClassName}`,
|
|
4110
|
-
children: /* @__PURE__ */
|
|
4876
|
+
children: /* @__PURE__ */ jsx15("h2", { className: "m-0 text-[15px] font-semibold leading-[1.35] text-[var(--text-primary)]", children: copy.t("actions.addSubtask") })
|
|
4111
4877
|
}
|
|
4112
4878
|
),
|
|
4113
|
-
/* @__PURE__ */
|
|
4114
|
-
/* @__PURE__ */
|
|
4879
|
+
/* @__PURE__ */ jsxs13("div", { className: "flex w-full min-w-0 flex-col gap-6", children: [
|
|
4880
|
+
/* @__PURE__ */ jsxs13(
|
|
4115
4881
|
"label",
|
|
4116
4882
|
{
|
|
4117
4883
|
className: `flex w-full min-w-0 flex-col gap-2 text-[13px] font-semibold text-[var(--text-secondary)] ${issueManagerEditorRiseInClassName} ${issueManagerEditorRiseInDelay1ClassName}`,
|
|
4118
4884
|
children: [
|
|
4119
|
-
/* @__PURE__ */
|
|
4120
|
-
/* @__PURE__ */
|
|
4885
|
+
/* @__PURE__ */ jsx15("span", { className: "leading-5", children: copy.t("labels.title") }),
|
|
4886
|
+
/* @__PURE__ */ jsx15(
|
|
4121
4887
|
IssueManagerDraftTitleInput,
|
|
4122
4888
|
{
|
|
4123
4889
|
placeholder: copy.t("composer.subtaskTitlePlaceholder"),
|
|
@@ -4128,13 +4894,13 @@ function IssueManagerTaskComposerPane({
|
|
|
4128
4894
|
]
|
|
4129
4895
|
}
|
|
4130
4896
|
),
|
|
4131
|
-
/* @__PURE__ */
|
|
4897
|
+
/* @__PURE__ */ jsxs13(
|
|
4132
4898
|
"div",
|
|
4133
4899
|
{
|
|
4134
4900
|
className: `flex min-h-0 w-full min-w-0 flex-col gap-2 text-[13px] font-semibold text-[var(--text-secondary)] ${issueManagerEditorRiseInClassName} ${issueManagerEditorRiseInDelay2ClassName}`,
|
|
4135
4901
|
children: [
|
|
4136
|
-
/* @__PURE__ */
|
|
4137
|
-
/* @__PURE__ */
|
|
4902
|
+
/* @__PURE__ */ jsx15("span", { className: "leading-5", children: copy.t("labels.requirementDescription") }),
|
|
4903
|
+
/* @__PURE__ */ jsx15(
|
|
4138
4904
|
IssueManagerRichTextTextarea,
|
|
4139
4905
|
{
|
|
4140
4906
|
controller,
|
|
@@ -4150,12 +4916,12 @@ function IssueManagerTaskComposerPane({
|
|
|
4150
4916
|
)
|
|
4151
4917
|
] })
|
|
4152
4918
|
] }) }),
|
|
4153
|
-
/* @__PURE__ */
|
|
4919
|
+
/* @__PURE__ */ jsx15(
|
|
4154
4920
|
"div",
|
|
4155
4921
|
{
|
|
4156
4922
|
className: `shrink-0 border-t border-border-1 px-7 py-4 ${issueManagerEditorFooterFadeInClassName}`,
|
|
4157
|
-
children: /* @__PURE__ */
|
|
4158
|
-
/* @__PURE__ */
|
|
4923
|
+
children: /* @__PURE__ */ jsxs13("div", { className: "flex items-center justify-end gap-3", children: [
|
|
4924
|
+
/* @__PURE__ */ jsx15(
|
|
4159
4925
|
Button9,
|
|
4160
4926
|
{
|
|
4161
4927
|
size: "default",
|
|
@@ -4165,7 +4931,7 @@ function IssueManagerTaskComposerPane({
|
|
|
4165
4931
|
children: copy.t("actions.cancel")
|
|
4166
4932
|
}
|
|
4167
4933
|
),
|
|
4168
|
-
/* @__PURE__ */
|
|
4934
|
+
/* @__PURE__ */ jsx15(
|
|
4169
4935
|
Button9,
|
|
4170
4936
|
{
|
|
4171
4937
|
disabled: !selectedIssue || isTaskTitleMissing,
|
|
@@ -4182,19 +4948,19 @@ function IssueManagerTaskComposerPane({
|
|
|
4182
4948
|
}
|
|
4183
4949
|
|
|
4184
4950
|
// src/ui/internal/shell/IssueManagerTaskDrawer.tsx
|
|
4185
|
-
import { useRef as
|
|
4186
|
-
import { ScrollArea as ScrollArea4, cn as
|
|
4951
|
+
import { useRef as useRef5 } from "react";
|
|
4952
|
+
import { ScrollArea as ScrollArea4, cn as cn9 } from "@tutti-os/ui-system";
|
|
4187
4953
|
|
|
4188
4954
|
// src/ui/internal/shell/IssueManagerTaskDrawerSections.tsx
|
|
4189
|
-
import { useState as
|
|
4955
|
+
import { useState as useState8 } from "react";
|
|
4190
4956
|
import {
|
|
4191
|
-
ArrowLeftIcon,
|
|
4192
4957
|
Badge as Badge5,
|
|
4193
4958
|
BareIconButton,
|
|
4194
4959
|
Button as Button10,
|
|
4960
|
+
CollapseLinedIcon,
|
|
4195
4961
|
ConfirmationDialog as ConfirmationDialog2
|
|
4196
4962
|
} from "@tutti-os/ui-system";
|
|
4197
|
-
import { Fragment as Fragment2, jsx as
|
|
4963
|
+
import { Fragment as Fragment2, jsx as jsx16, jsxs as jsxs14 } from "react/jsx-runtime";
|
|
4198
4964
|
function IssueManagerTaskDrawerHeader({
|
|
4199
4965
|
controller,
|
|
4200
4966
|
onClose,
|
|
@@ -4202,26 +4968,26 @@ function IssueManagerTaskDrawerHeader({
|
|
|
4202
4968
|
view
|
|
4203
4969
|
}) {
|
|
4204
4970
|
const copy = controller.copy;
|
|
4205
|
-
const [deleteDialogOpen, setDeleteDialogOpen] =
|
|
4206
|
-
const [deleteBusy, setDeleteBusy] =
|
|
4207
|
-
return /* @__PURE__ */
|
|
4208
|
-
/* @__PURE__ */
|
|
4209
|
-
/* @__PURE__ */
|
|
4210
|
-
/* @__PURE__ */
|
|
4211
|
-
/* @__PURE__ */
|
|
4971
|
+
const [deleteDialogOpen, setDeleteDialogOpen] = useState8(false);
|
|
4972
|
+
const [deleteBusy, setDeleteBusy] = useState8(false);
|
|
4973
|
+
return /* @__PURE__ */ jsxs14(Fragment2, { children: [
|
|
4974
|
+
/* @__PURE__ */ jsxs14("div", { className: "grid gap-3 px-6 pt-7 pb-3", children: [
|
|
4975
|
+
/* @__PURE__ */ jsxs14("div", { className: "flex items-center justify-between gap-6", children: [
|
|
4976
|
+
/* @__PURE__ */ jsxs14("div", { className: "flex min-w-0 flex-1 items-center gap-2", children: [
|
|
4977
|
+
/* @__PURE__ */ jsx16(
|
|
4212
4978
|
BareIconButton,
|
|
4213
4979
|
{
|
|
4214
4980
|
"aria-label": copy.t("actions.closeTaskDetails"),
|
|
4215
4981
|
size: "md",
|
|
4216
4982
|
title: copy.t("actions.closeTaskDetails"),
|
|
4217
4983
|
onClick: onClose,
|
|
4218
|
-
children: /* @__PURE__ */
|
|
4984
|
+
children: /* @__PURE__ */ jsx16(CollapseLinedIcon, { className: "size-4" })
|
|
4219
4985
|
}
|
|
4220
4986
|
),
|
|
4221
|
-
view.showTaskMetadata && selectedTask ? /* @__PURE__ */
|
|
4987
|
+
view.showTaskMetadata && selectedTask ? /* @__PURE__ */ jsx16(IssueManagerTitleTooltip, { title: view.title, children: /* @__PURE__ */ jsx16("h3", { className: "line-clamp-2 min-w-0 flex-1 whitespace-normal text-[15px] font-semibold leading-6 text-[var(--text-primary)] [overflow-wrap:anywhere]", children: view.title }) }) : /* @__PURE__ */ jsx16(IssueManagerTitleTooltip, { title: view.title, children: /* @__PURE__ */ jsx16("h3", { className: "line-clamp-2 min-w-0 flex-1 whitespace-normal text-[15px] font-semibold leading-[1.35] text-[var(--text-primary)] [overflow-wrap:anywhere]", children: view.title }) })
|
|
4222
4988
|
] }),
|
|
4223
|
-
/* @__PURE__ */
|
|
4224
|
-
/* @__PURE__ */
|
|
4989
|
+
/* @__PURE__ */ jsx16("div", { className: "flex shrink-0 items-center gap-2", children: view.showTaskActions && selectedTask ? /* @__PURE__ */ jsxs14(Fragment2, { children: [
|
|
4990
|
+
/* @__PURE__ */ jsx16(
|
|
4225
4991
|
Button10,
|
|
4226
4992
|
{
|
|
4227
4993
|
type: "button",
|
|
@@ -4230,7 +4996,7 @@ function IssueManagerTaskDrawerHeader({
|
|
|
4230
4996
|
children: copy.t("actions.edit")
|
|
4231
4997
|
}
|
|
4232
4998
|
),
|
|
4233
|
-
/* @__PURE__ */
|
|
4999
|
+
/* @__PURE__ */ jsx16(
|
|
4234
5000
|
Button10,
|
|
4235
5001
|
{
|
|
4236
5002
|
className: "text-[var(--state-danger)] hover:bg-[var(--on-danger)] hover:text-[var(--state-danger)]",
|
|
@@ -4242,24 +5008,24 @@ function IssueManagerTaskDrawerHeader({
|
|
|
4242
5008
|
)
|
|
4243
5009
|
] }) : null })
|
|
4244
5010
|
] }),
|
|
4245
|
-
view.showTaskMetadata && selectedTask ? /* @__PURE__ */
|
|
4246
|
-
/* @__PURE__ */
|
|
5011
|
+
view.showTaskMetadata && selectedTask ? /* @__PURE__ */ jsxs14("div", { className: "grid gap-2", children: [
|
|
5012
|
+
/* @__PURE__ */ jsx16(
|
|
4247
5013
|
IssueManagerTaskMetadataRow,
|
|
4248
5014
|
{
|
|
4249
5015
|
copy,
|
|
4250
5016
|
selectedTask
|
|
4251
5017
|
}
|
|
4252
5018
|
),
|
|
4253
|
-
selectedTask.status === "pending_acceptance" ? /* @__PURE__ */
|
|
5019
|
+
selectedTask.status === "pending_acceptance" ? /* @__PURE__ */ jsx16(IssueManagerTaskAcceptanceCard, { controller }) : null
|
|
4254
5020
|
] }) : null
|
|
4255
5021
|
] }),
|
|
4256
|
-
selectedTask ? /* @__PURE__ */
|
|
5022
|
+
selectedTask ? /* @__PURE__ */ jsx16(
|
|
4257
5023
|
ConfirmationDialog2,
|
|
4258
5024
|
{
|
|
4259
5025
|
cancelLabel: copy.t("actions.cancel"),
|
|
4260
5026
|
confirmBusy: deleteBusy,
|
|
4261
5027
|
confirmLabel: copy.t("actions.delete"),
|
|
4262
|
-
description: /* @__PURE__ */
|
|
5028
|
+
description: /* @__PURE__ */ jsx16("span", { className: "block max-w-full whitespace-normal [overflow-wrap:anywhere]", children: selectedTask.title }),
|
|
4263
5029
|
open: deleteDialogOpen,
|
|
4264
5030
|
title: copy.t("confirmations.deleteTask"),
|
|
4265
5031
|
tone: "destructive",
|
|
@@ -4279,28 +5045,28 @@ function IssueManagerTaskMetadataRow({
|
|
|
4279
5045
|
copy,
|
|
4280
5046
|
selectedTask
|
|
4281
5047
|
}) {
|
|
4282
|
-
return /* @__PURE__ */
|
|
4283
|
-
/* @__PURE__ */
|
|
4284
|
-
/* @__PURE__ */
|
|
5048
|
+
return /* @__PURE__ */ jsxs14("div", { className: "flex flex-wrap items-center gap-x-2 gap-y-2 text-[11px] font-normal leading-[1.3] text-[var(--text-secondary)]", children: [
|
|
5049
|
+
/* @__PURE__ */ jsx16(Badge5, { variant: issueManagerStatusBadgeVariant(selectedTask.status), children: resolveIssueManagerStatusLabel(copy, selectedTask.status) }),
|
|
5050
|
+
/* @__PURE__ */ jsx16(
|
|
4285
5051
|
"span",
|
|
4286
5052
|
{
|
|
4287
5053
|
"aria-hidden": "true",
|
|
4288
5054
|
className: "h-4 w-px shrink-0 bg-[var(--line-2)]"
|
|
4289
5055
|
}
|
|
4290
5056
|
),
|
|
4291
|
-
/* @__PURE__ */
|
|
5057
|
+
/* @__PURE__ */ jsxs14("span", { className: "text-[11px] font-normal leading-[1.3]", children: [
|
|
4292
5058
|
copy.t("labels.creator"),
|
|
4293
5059
|
" ",
|
|
4294
5060
|
resolveTaskCreatorLabel(selectedTask)
|
|
4295
5061
|
] }),
|
|
4296
|
-
/* @__PURE__ */
|
|
5062
|
+
/* @__PURE__ */ jsx16(
|
|
4297
5063
|
"span",
|
|
4298
5064
|
{
|
|
4299
5065
|
"aria-hidden": "true",
|
|
4300
5066
|
className: "h-4 w-px shrink-0 bg-[var(--line-2)]"
|
|
4301
5067
|
}
|
|
4302
5068
|
),
|
|
4303
|
-
/* @__PURE__ */
|
|
5069
|
+
/* @__PURE__ */ jsxs14("span", { className: "text-[11px] font-normal leading-[1.3]", children: [
|
|
4304
5070
|
copy.t("labels.createdAt"),
|
|
4305
5071
|
" ",
|
|
4306
5072
|
formatIssueManagerTimestamp(selectedTask.createdAtUnix) || "-"
|
|
@@ -4308,7 +5074,7 @@ function IssueManagerTaskMetadataRow({
|
|
|
4308
5074
|
] });
|
|
4309
5075
|
}
|
|
4310
5076
|
function IssueManagerTaskDrawerLoadingBody() {
|
|
4311
|
-
return /* @__PURE__ */
|
|
5077
|
+
return /* @__PURE__ */ jsx16(IssueManagerTaskDrawerLoadingState, {});
|
|
4312
5078
|
}
|
|
4313
5079
|
function IssueManagerTaskDrawerBody({
|
|
4314
5080
|
controller,
|
|
@@ -4317,10 +5083,10 @@ function IssueManagerTaskDrawerBody({
|
|
|
4317
5083
|
view
|
|
4318
5084
|
}) {
|
|
4319
5085
|
if (view.bodyKind === "loading") {
|
|
4320
|
-
return /* @__PURE__ */
|
|
5086
|
+
return /* @__PURE__ */ jsx16(IssueManagerTaskDrawerLoadingBody, {});
|
|
4321
5087
|
}
|
|
4322
5088
|
if (view.bodyKind === "edit") {
|
|
4323
|
-
return /* @__PURE__ */
|
|
5089
|
+
return /* @__PURE__ */ jsx16(
|
|
4324
5090
|
IssueManagerTaskDrawerEditBody,
|
|
4325
5091
|
{
|
|
4326
5092
|
controller,
|
|
@@ -4328,7 +5094,7 @@ function IssueManagerTaskDrawerBody({
|
|
|
4328
5094
|
}
|
|
4329
5095
|
);
|
|
4330
5096
|
}
|
|
4331
|
-
return /* @__PURE__ */
|
|
5097
|
+
return /* @__PURE__ */ jsx16(
|
|
4332
5098
|
IssueManagerTaskDrawerReadBody,
|
|
4333
5099
|
{
|
|
4334
5100
|
controller,
|
|
@@ -4343,22 +5109,22 @@ function IssueManagerTaskDrawerEditBody({
|
|
|
4343
5109
|
title
|
|
4344
5110
|
}) {
|
|
4345
5111
|
const copy = controller.copy;
|
|
4346
|
-
return /* @__PURE__ */
|
|
4347
|
-
/* @__PURE__ */
|
|
5112
|
+
return /* @__PURE__ */ jsxs14("div", { className: "flex w-full min-w-0 flex-col gap-3", children: [
|
|
5113
|
+
/* @__PURE__ */ jsx16(
|
|
4348
5114
|
"div",
|
|
4349
5115
|
{
|
|
4350
5116
|
className: `${issueManagerEditorRiseInClassName} ${issueManagerEditorRiseInDelay0ClassName}`,
|
|
4351
|
-
children: /* @__PURE__ */
|
|
5117
|
+
children: /* @__PURE__ */ jsx16("h2", { className: "m-0 text-[15px] font-semibold leading-[1.35] text-[var(--text-primary)]", children: title })
|
|
4352
5118
|
}
|
|
4353
5119
|
),
|
|
4354
|
-
/* @__PURE__ */
|
|
4355
|
-
/* @__PURE__ */
|
|
5120
|
+
/* @__PURE__ */ jsxs14("div", { className: "flex w-full min-w-0 flex-col gap-6", children: [
|
|
5121
|
+
/* @__PURE__ */ jsxs14(
|
|
4356
5122
|
"label",
|
|
4357
5123
|
{
|
|
4358
5124
|
className: `flex w-full min-w-0 flex-col gap-2 text-[13px] font-semibold text-[var(--text-secondary)] ${issueManagerEditorRiseInClassName} ${issueManagerEditorRiseInDelay1ClassName}`,
|
|
4359
5125
|
children: [
|
|
4360
|
-
/* @__PURE__ */
|
|
4361
|
-
/* @__PURE__ */
|
|
5126
|
+
/* @__PURE__ */ jsx16("span", { className: "leading-5", children: copy.t("labels.title") }),
|
|
5127
|
+
/* @__PURE__ */ jsx16(
|
|
4362
5128
|
IssueManagerDraftTitleInput,
|
|
4363
5129
|
{
|
|
4364
5130
|
placeholder: copy.t("composer.taskTitlePlaceholder"),
|
|
@@ -4369,13 +5135,13 @@ function IssueManagerTaskDrawerEditBody({
|
|
|
4369
5135
|
]
|
|
4370
5136
|
}
|
|
4371
5137
|
),
|
|
4372
|
-
/* @__PURE__ */
|
|
5138
|
+
/* @__PURE__ */ jsxs14(
|
|
4373
5139
|
"div",
|
|
4374
5140
|
{
|
|
4375
5141
|
className: `flex min-h-0 w-full min-w-0 flex-col gap-2 text-[13px] font-semibold text-[var(--text-secondary)] ${issueManagerEditorRiseInClassName} ${issueManagerEditorRiseInDelay2ClassName}`,
|
|
4376
5142
|
children: [
|
|
4377
|
-
/* @__PURE__ */
|
|
4378
|
-
/* @__PURE__ */
|
|
5143
|
+
/* @__PURE__ */ jsx16("span", { className: "leading-5", children: copy.t("labels.content") }),
|
|
5144
|
+
/* @__PURE__ */ jsx16(
|
|
4379
5145
|
IssueManagerRichTextTextarea,
|
|
4380
5146
|
{
|
|
4381
5147
|
controller,
|
|
@@ -4401,8 +5167,8 @@ function IssueManagerTaskDrawerReadBody({
|
|
|
4401
5167
|
const copy = controller.copy;
|
|
4402
5168
|
const latestRun = controller.taskDetail.value?.latestRun ?? controller.taskDetail.value?.recentRuns[0] ?? null;
|
|
4403
5169
|
const latestOutputs = controller.taskDetail.value?.latestOutputs ?? [];
|
|
4404
|
-
return /* @__PURE__ */
|
|
4405
|
-
/* @__PURE__ */
|
|
5170
|
+
return /* @__PURE__ */ jsxs14(Fragment2, { children: [
|
|
5171
|
+
/* @__PURE__ */ jsx16(
|
|
4406
5172
|
IssueManagerDescriptionSection,
|
|
4407
5173
|
{
|
|
4408
5174
|
content: taskContent,
|
|
@@ -4413,7 +5179,7 @@ function IssueManagerTaskDrawerReadBody({
|
|
|
4413
5179
|
variant: "plain"
|
|
4414
5180
|
}
|
|
4415
5181
|
),
|
|
4416
|
-
/* @__PURE__ */
|
|
5182
|
+
/* @__PURE__ */ jsx16(
|
|
4417
5183
|
IssueManagerLatestRunStatusSection,
|
|
4418
5184
|
{
|
|
4419
5185
|
copy,
|
|
@@ -4423,7 +5189,7 @@ function IssueManagerTaskDrawerReadBody({
|
|
|
4423
5189
|
title: latestRunTitle
|
|
4424
5190
|
}
|
|
4425
5191
|
),
|
|
4426
|
-
/* @__PURE__ */
|
|
5192
|
+
/* @__PURE__ */ jsx16(
|
|
4427
5193
|
IssueManagerOutputSection,
|
|
4428
5194
|
{
|
|
4429
5195
|
copy,
|
|
@@ -4445,8 +5211,8 @@ function IssueManagerTaskDrawerFooter({
|
|
|
4445
5211
|
selectedTaskStatus: selectedTask?.status
|
|
4446
5212
|
});
|
|
4447
5213
|
if (view.showReadFooter && selectedTask) {
|
|
4448
|
-
return /* @__PURE__ */
|
|
4449
|
-
/* @__PURE__ */
|
|
5214
|
+
return /* @__PURE__ */ jsx16("div", { className: "border-t border-[var(--border-1)] bg-transparent px-6 py-4 backdrop-blur", children: /* @__PURE__ */ jsxs14("div", { className: "flex items-center justify-end gap-3", children: [
|
|
5215
|
+
/* @__PURE__ */ jsx16(
|
|
4450
5216
|
IssueManagerExecutionDirectoryTrigger,
|
|
4451
5217
|
{
|
|
4452
5218
|
className: "mr-auto",
|
|
@@ -4454,7 +5220,7 @@ function IssueManagerTaskDrawerFooter({
|
|
|
4454
5220
|
disabled: runControlsDisabled
|
|
4455
5221
|
}
|
|
4456
5222
|
),
|
|
4457
|
-
/* @__PURE__ */
|
|
5223
|
+
/* @__PURE__ */ jsx16(
|
|
4458
5224
|
IssueManagerRunActionTrigger,
|
|
4459
5225
|
{
|
|
4460
5226
|
controller,
|
|
@@ -4462,7 +5228,7 @@ function IssueManagerTaskDrawerFooter({
|
|
|
4462
5228
|
triggerVariant: "button"
|
|
4463
5229
|
}
|
|
4464
5230
|
),
|
|
4465
|
-
controller.canInviteCollaborators ? /* @__PURE__ */
|
|
5231
|
+
controller.canInviteCollaborators ? /* @__PURE__ */ jsx16(
|
|
4466
5232
|
Button10,
|
|
4467
5233
|
{
|
|
4468
5234
|
disabled: !selectedIssue,
|
|
@@ -4477,12 +5243,12 @@ function IssueManagerTaskDrawerFooter({
|
|
|
4477
5243
|
] }) });
|
|
4478
5244
|
}
|
|
4479
5245
|
if (view.showEditFooter) {
|
|
4480
|
-
return /* @__PURE__ */
|
|
5246
|
+
return /* @__PURE__ */ jsx16(
|
|
4481
5247
|
"div",
|
|
4482
5248
|
{
|
|
4483
5249
|
className: `border-t border-border-1 px-6 py-4 ${issueManagerEditorFooterFadeInClassName}`,
|
|
4484
|
-
children: /* @__PURE__ */
|
|
4485
|
-
/* @__PURE__ */
|
|
5250
|
+
children: /* @__PURE__ */ jsxs14("div", { className: "flex items-center justify-end gap-3", children: [
|
|
5251
|
+
/* @__PURE__ */ jsx16(
|
|
4486
5252
|
Button10,
|
|
4487
5253
|
{
|
|
4488
5254
|
size: "dialog",
|
|
@@ -4492,7 +5258,7 @@ function IssueManagerTaskDrawerFooter({
|
|
|
4492
5258
|
children: copy.t("actions.cancel")
|
|
4493
5259
|
}
|
|
4494
5260
|
),
|
|
4495
|
-
/* @__PURE__ */
|
|
5261
|
+
/* @__PURE__ */ jsx16(
|
|
4496
5262
|
Button10,
|
|
4497
5263
|
{
|
|
4498
5264
|
disabled: canIssueManagerSaveTask({
|
|
@@ -4513,7 +5279,7 @@ function IssueManagerTaskDrawerFooter({
|
|
|
4513
5279
|
}
|
|
4514
5280
|
|
|
4515
5281
|
// src/ui/internal/shell/IssueManagerTaskDrawer.tsx
|
|
4516
|
-
import { jsx as
|
|
5282
|
+
import { jsx as jsx17, jsxs as jsxs15 } from "react/jsx-runtime";
|
|
4517
5283
|
function IssueManagerTaskDrawer({
|
|
4518
5284
|
controller,
|
|
4519
5285
|
isClosing,
|
|
@@ -4528,7 +5294,7 @@ function IssueManagerTaskDrawer({
|
|
|
4528
5294
|
selectedTask
|
|
4529
5295
|
});
|
|
4530
5296
|
const taskContent = selectedTask?.content ?? "";
|
|
4531
|
-
const hasRequestedBackdropCloseRef =
|
|
5297
|
+
const hasRequestedBackdropCloseRef = useRef5(false);
|
|
4532
5298
|
const requestBackdropClose = (event, phase) => {
|
|
4533
5299
|
const target = event.target;
|
|
4534
5300
|
logIssueManagerDiagnostic(
|
|
@@ -4577,10 +5343,10 @@ function IssueManagerTaskDrawer({
|
|
|
4577
5343
|
}
|
|
4578
5344
|
requestBackdropClose(event, "click");
|
|
4579
5345
|
};
|
|
4580
|
-
return /* @__PURE__ */
|
|
5346
|
+
return /* @__PURE__ */ jsx17(
|
|
4581
5347
|
"div",
|
|
4582
5348
|
{
|
|
4583
|
-
className:
|
|
5349
|
+
className: cn9(
|
|
4584
5350
|
"absolute inset-0 z-20 flex justify-end overscroll-contain bg-[var(--backdrop)] backdrop-blur-[1px] motion-reduce:animate-none",
|
|
4585
5351
|
isClosing ? "motion-safe:animate-out motion-safe:fade-out-0 motion-safe:duration-[180ms] motion-safe:ease-[cubic-bezier(0.4,0,0.2,1)]" : "motion-safe:animate-in motion-safe:fade-in-0 motion-safe:duration-[180ms] motion-safe:ease-[cubic-bezier(0.4,0,0.2,1)]"
|
|
4586
5352
|
),
|
|
@@ -4592,10 +5358,10 @@ function IssueManagerTaskDrawer({
|
|
|
4592
5358
|
onWheel: (event) => {
|
|
4593
5359
|
event.preventDefault();
|
|
4594
5360
|
},
|
|
4595
|
-
children: /* @__PURE__ */
|
|
5361
|
+
children: /* @__PURE__ */ jsxs15(
|
|
4596
5362
|
"aside",
|
|
4597
5363
|
{
|
|
4598
|
-
className:
|
|
5364
|
+
className: cn9(
|
|
4599
5365
|
"flex h-full w-[min(360px,92cqw)] flex-col overscroll-contain border-l border-border-1 bg-background-panel text-[var(--text-primary)] shadow-[-20px_0_60px_var(--shadow-elevated)] @min-[960px]/issue-manager-content:w-[480px] motion-reduce:animate-none",
|
|
4600
5366
|
isClosing ? "motion-safe:animate-out motion-safe:slide-out-to-right-full motion-safe:duration-[180ms] motion-safe:ease-[cubic-bezier(0.4,0,0.2,1)]" : "motion-safe:animate-in motion-safe:slide-in-from-right-full motion-safe:duration-[220ms] motion-safe:ease-[cubic-bezier(0.22,1,0.36,1)]"
|
|
4601
5367
|
),
|
|
@@ -4603,7 +5369,7 @@ function IssueManagerTaskDrawer({
|
|
|
4603
5369
|
onTouchMove: (event) => event.stopPropagation(),
|
|
4604
5370
|
onWheel: (event) => event.stopPropagation(),
|
|
4605
5371
|
children: [
|
|
4606
|
-
view.bodyKind === "edit" ? null : /* @__PURE__ */
|
|
5372
|
+
view.bodyKind === "edit" ? null : /* @__PURE__ */ jsx17(
|
|
4607
5373
|
IssueManagerTaskDrawerHeader,
|
|
4608
5374
|
{
|
|
4609
5375
|
controller,
|
|
@@ -4612,19 +5378,19 @@ function IssueManagerTaskDrawer({
|
|
|
4612
5378
|
view
|
|
4613
5379
|
}
|
|
4614
5380
|
),
|
|
4615
|
-
/* @__PURE__ */
|
|
5381
|
+
/* @__PURE__ */ jsx17(
|
|
4616
5382
|
ScrollArea4,
|
|
4617
5383
|
{
|
|
4618
5384
|
scrollbarMode: "native",
|
|
4619
5385
|
className: "min-h-0 flex-1 [&_[data-slot=scroll-area-viewport]]:overscroll-contain",
|
|
4620
|
-
children: /* @__PURE__ */
|
|
5386
|
+
children: /* @__PURE__ */ jsx17(
|
|
4621
5387
|
"div",
|
|
4622
5388
|
{
|
|
4623
|
-
className:
|
|
5389
|
+
className: cn9(
|
|
4624
5390
|
"flex flex-col",
|
|
4625
|
-
view.bodyKind === "edit" ? "gap-[14px] px-6 py-8" : "gap-
|
|
5391
|
+
view.bodyKind === "edit" ? "gap-[14px] px-6 py-8" : "gap-8 px-6 pt-1 pb-7"
|
|
4626
5392
|
),
|
|
4627
|
-
children: /* @__PURE__ */
|
|
5393
|
+
children: /* @__PURE__ */ jsx17(
|
|
4628
5394
|
IssueManagerTaskDrawerBody,
|
|
4629
5395
|
{
|
|
4630
5396
|
controller,
|
|
@@ -4637,7 +5403,7 @@ function IssueManagerTaskDrawer({
|
|
|
4637
5403
|
)
|
|
4638
5404
|
}
|
|
4639
5405
|
),
|
|
4640
|
-
/* @__PURE__ */
|
|
5406
|
+
/* @__PURE__ */ jsx17(
|
|
4641
5407
|
IssueManagerTaskDrawerFooter,
|
|
4642
5408
|
{
|
|
4643
5409
|
controller,
|
|
@@ -4655,28 +5421,28 @@ function IssueManagerTaskDrawer({
|
|
|
4655
5421
|
|
|
4656
5422
|
// src/ui/internal/shell/useIssueManagerShellView.ts
|
|
4657
5423
|
import {
|
|
4658
|
-
useEffect as
|
|
5424
|
+
useEffect as useEffect7,
|
|
4659
5425
|
useEffectEvent as useEffectEvent2,
|
|
4660
|
-
useRef as
|
|
4661
|
-
useState as
|
|
5426
|
+
useRef as useRef6,
|
|
5427
|
+
useState as useState9
|
|
4662
5428
|
} from "react";
|
|
4663
5429
|
function useIssueManagerShellView({
|
|
4664
5430
|
controller,
|
|
4665
5431
|
selectedIssue,
|
|
4666
5432
|
selectedTask
|
|
4667
5433
|
}) {
|
|
4668
|
-
const layoutRef =
|
|
4669
|
-
const resizeRef =
|
|
4670
|
-
const [sidebarWidth, setSidebarWidth] =
|
|
5434
|
+
const layoutRef = useRef6(null);
|
|
5435
|
+
const resizeRef = useRef6(null);
|
|
5436
|
+
const [sidebarWidth, setSidebarWidth] = useState9(
|
|
4671
5437
|
issueManagerSidebarDefaultWidth
|
|
4672
5438
|
);
|
|
4673
|
-
const [isNarrowLayout, setIsNarrowLayout] =
|
|
5439
|
+
const [isNarrowLayout, setIsNarrowLayout] = useState9(false);
|
|
4674
5440
|
const dismissNotification = useEffectEvent2(() => {
|
|
4675
5441
|
controller.dismissNotification();
|
|
4676
5442
|
});
|
|
4677
5443
|
const floatingNotice = controller.floatingNotice;
|
|
4678
|
-
const lastContentDiagnosticRef =
|
|
4679
|
-
|
|
5444
|
+
const lastContentDiagnosticRef = useRef6(null);
|
|
5445
|
+
useEffect7(() => {
|
|
4680
5446
|
const publishLayout = () => {
|
|
4681
5447
|
const width = layoutRef.current?.getBoundingClientRect().width ?? 0;
|
|
4682
5448
|
if (!width) {
|
|
@@ -4699,7 +5465,7 @@ function useIssueManagerShellView({
|
|
|
4699
5465
|
window.removeEventListener("resize", publishLayout);
|
|
4700
5466
|
};
|
|
4701
5467
|
}, []);
|
|
4702
|
-
|
|
5468
|
+
useEffect7(() => {
|
|
4703
5469
|
if (!floatingNotice) {
|
|
4704
5470
|
return void 0;
|
|
4705
5471
|
}
|
|
@@ -4716,7 +5482,7 @@ function useIssueManagerShellView({
|
|
|
4716
5482
|
selectedTaskPresent: selectedTask !== null,
|
|
4717
5483
|
taskEditorMode: controller.taskEditorMode
|
|
4718
5484
|
});
|
|
4719
|
-
|
|
5485
|
+
useEffect7(() => {
|
|
4720
5486
|
const nextDiagnostic = {
|
|
4721
5487
|
isIssueEditing: content.isIssueEditing,
|
|
4722
5488
|
isTaskCreating: content.isTaskCreating,
|
|
@@ -4874,10 +5640,8 @@ function shouldIgnoreIssueManagerTaskDrawerBackdropEcho(input) {
|
|
|
4874
5640
|
}
|
|
4875
5641
|
|
|
4876
5642
|
// src/ui/internal/shell/IssueManagerShell.tsx
|
|
4877
|
-
import { jsx as
|
|
5643
|
+
import { jsx as jsx18, jsxs as jsxs16 } from "react/jsx-runtime";
|
|
4878
5644
|
var issueManagerTaskDrawerExitDurationMs = 180;
|
|
4879
|
-
var issueManagerTaskDrawerCloseBlockerMs = 500;
|
|
4880
|
-
var issueManagerTaskDrawerCloseBlockerUntilMs = 0;
|
|
4881
5645
|
function IssueManagerShell({
|
|
4882
5646
|
controller,
|
|
4883
5647
|
emptyIllustration,
|
|
@@ -4892,56 +5656,18 @@ function IssueManagerShell({
|
|
|
4892
5656
|
selectedIssue,
|
|
4893
5657
|
selectedTask
|
|
4894
5658
|
});
|
|
4895
|
-
const [renderedTaskDrawerTask, setRenderedTaskDrawerTask] =
|
|
4896
|
-
const
|
|
4897
|
-
const lastContentPointerDownRef = useRef6(
|
|
5659
|
+
const [renderedTaskDrawerTask, setRenderedTaskDrawerTask] = useState10(selectedTask);
|
|
5660
|
+
const lastContentPointerDownRef = useRef7(
|
|
4898
5661
|
null
|
|
4899
5662
|
);
|
|
4900
|
-
const taskDrawerOpenPointerRef =
|
|
5663
|
+
const taskDrawerOpenPointerRef = useRef7(
|
|
4901
5664
|
null
|
|
4902
5665
|
);
|
|
4903
|
-
const pendingTaskDrawerCloseRef =
|
|
4904
|
-
const
|
|
4905
|
-
const previousTaskDrawerOpenRef = useRef6({
|
|
5666
|
+
const pendingTaskDrawerCloseRef = useRef7(false);
|
|
5667
|
+
const previousTaskDrawerOpenRef = useRef7({
|
|
4906
5668
|
isOpen: shellView.content.isTaskDrawerOpen,
|
|
4907
5669
|
taskId: selectedTask?.taskId ?? null
|
|
4908
5670
|
});
|
|
4909
|
-
const clearTaskDrawerCloseBlocker = () => {
|
|
4910
|
-
if (taskDrawerCloseBlockerTimeoutRef.current !== null) {
|
|
4911
|
-
window.clearTimeout(taskDrawerCloseBlockerTimeoutRef.current);
|
|
4912
|
-
taskDrawerCloseBlockerTimeoutRef.current = null;
|
|
4913
|
-
}
|
|
4914
|
-
issueManagerTaskDrawerCloseBlockerUntilMs = 0;
|
|
4915
|
-
setTaskDrawerCloseBlockerUntilMs(0);
|
|
4916
|
-
};
|
|
4917
|
-
const startTaskDrawerCloseBlocker = () => {
|
|
4918
|
-
issueManagerTaskDrawerCloseBlockerUntilMs = performance.now() + issueManagerTaskDrawerCloseBlockerMs;
|
|
4919
|
-
setTaskDrawerCloseBlockerUntilMs(issueManagerTaskDrawerCloseBlockerUntilMs);
|
|
4920
|
-
};
|
|
4921
|
-
useEffect7(() => {
|
|
4922
|
-
if (taskDrawerCloseBlockerTimeoutRef.current !== null) {
|
|
4923
|
-
window.clearTimeout(taskDrawerCloseBlockerTimeoutRef.current);
|
|
4924
|
-
taskDrawerCloseBlockerTimeoutRef.current = null;
|
|
4925
|
-
}
|
|
4926
|
-
if (taskDrawerCloseBlockerUntilMs <= performance.now()) {
|
|
4927
|
-
return void 0;
|
|
4928
|
-
}
|
|
4929
|
-
taskDrawerCloseBlockerTimeoutRef.current = window.setTimeout(() => {
|
|
4930
|
-
if (issueManagerTaskDrawerCloseBlockerUntilMs <= performance.now()) {
|
|
4931
|
-
issueManagerTaskDrawerCloseBlockerUntilMs = 0;
|
|
4932
|
-
}
|
|
4933
|
-
taskDrawerCloseBlockerTimeoutRef.current = null;
|
|
4934
|
-
setTaskDrawerCloseBlockerUntilMs(
|
|
4935
|
-
issueManagerTaskDrawerCloseBlockerUntilMs
|
|
4936
|
-
);
|
|
4937
|
-
}, taskDrawerCloseBlockerUntilMs - performance.now());
|
|
4938
|
-
return () => {
|
|
4939
|
-
if (taskDrawerCloseBlockerTimeoutRef.current !== null) {
|
|
4940
|
-
window.clearTimeout(taskDrawerCloseBlockerTimeoutRef.current);
|
|
4941
|
-
taskDrawerCloseBlockerTimeoutRef.current = null;
|
|
4942
|
-
}
|
|
4943
|
-
};
|
|
4944
|
-
}, [taskDrawerCloseBlockerUntilMs]);
|
|
4945
5671
|
const handleCloseTaskDrawer = (source) => {
|
|
4946
5672
|
logIssueManagerDiagnostic(
|
|
4947
5673
|
controller.diagnostics,
|
|
@@ -4956,11 +5682,6 @@ function IssueManagerShell({
|
|
|
4956
5682
|
);
|
|
4957
5683
|
pendingTaskDrawerCloseRef.current = true;
|
|
4958
5684
|
setRenderedTaskDrawerTask(null);
|
|
4959
|
-
if (source === "backdrop") {
|
|
4960
|
-
startTaskDrawerCloseBlocker();
|
|
4961
|
-
} else {
|
|
4962
|
-
clearTaskDrawerCloseBlocker();
|
|
4963
|
-
}
|
|
4964
5685
|
onCloseTaskDrawer();
|
|
4965
5686
|
};
|
|
4966
5687
|
const handleContentPointerDownCapture = (event) => {
|
|
@@ -5002,7 +5723,7 @@ function IssueManagerShell({
|
|
|
5002
5723
|
}
|
|
5003
5724
|
return echo.ignore;
|
|
5004
5725
|
};
|
|
5005
|
-
|
|
5726
|
+
useEffect8(() => {
|
|
5006
5727
|
const selectedTaskId = selectedTask?.taskId ?? null;
|
|
5007
5728
|
const previousOpen = previousTaskDrawerOpenRef.current;
|
|
5008
5729
|
if (shellView.content.isTaskDrawerOpen) {
|
|
@@ -5079,8 +5800,7 @@ function IssueManagerShell({
|
|
|
5079
5800
|
const isTaskDrawerOpenForRender = shellView.content.isTaskDrawerOpen && !pendingTaskDrawerCloseRef.current;
|
|
5080
5801
|
const taskDrawerTask = isTaskDrawerOpenForRender ? selectedTask : renderedTaskDrawerTask;
|
|
5081
5802
|
const isTaskDrawerClosing = !isTaskDrawerOpenForRender && renderedTaskDrawerTask !== null;
|
|
5082
|
-
|
|
5083
|
-
return /* @__PURE__ */ jsxs15(
|
|
5803
|
+
return /* @__PURE__ */ jsxs16(
|
|
5084
5804
|
"div",
|
|
5085
5805
|
{
|
|
5086
5806
|
className: "relative grid min-h-0 flex-1 grid-rows-[minmax(0,1fr)] overflow-hidden bg-transparent transition-[grid-template-columns] duration-[180ms] ease-[cubic-bezier(0.4,0,0.2,1)] motion-reduce:transition-none",
|
|
@@ -5089,8 +5809,8 @@ function IssueManagerShell({
|
|
|
5089
5809
|
ref: shellView.layoutRef,
|
|
5090
5810
|
style: shellView.layoutStyle,
|
|
5091
5811
|
children: [
|
|
5092
|
-
shellView.floatingNotice ? /* @__PURE__ */
|
|
5093
|
-
/* @__PURE__ */
|
|
5812
|
+
shellView.floatingNotice ? /* @__PURE__ */ jsx18(IssueManagerFloatingNotice, { notice: shellView.floatingNotice }) : null,
|
|
5813
|
+
/* @__PURE__ */ jsx18(
|
|
5094
5814
|
IssueManagerSidebar,
|
|
5095
5815
|
{
|
|
5096
5816
|
controller,
|
|
@@ -5101,7 +5821,7 @@ function IssueManagerShell({
|
|
|
5101
5821
|
statusCounts: shellView.sidebar.statusCounts
|
|
5102
5822
|
}
|
|
5103
5823
|
),
|
|
5104
|
-
shellView.sidebar.isAutoCollapsed ? null : /* @__PURE__ */
|
|
5824
|
+
shellView.sidebar.isAutoCollapsed ? null : /* @__PURE__ */ jsx18(
|
|
5105
5825
|
"div",
|
|
5106
5826
|
{
|
|
5107
5827
|
"aria-label": controller.copy.t("labels.resizeIssueList"),
|
|
@@ -5109,7 +5829,7 @@ function IssueManagerShell({
|
|
|
5109
5829
|
"aria-valuemax": shellView.resizeHandle.ariaValueMax,
|
|
5110
5830
|
"aria-valuemin": shellView.resizeHandle.ariaValueMin,
|
|
5111
5831
|
"aria-valuenow": shellView.resizeHandle.ariaValueNow,
|
|
5112
|
-
className:
|
|
5832
|
+
className: cn10(
|
|
5113
5833
|
"group absolute top-0 bottom-0 left-[calc(var(--issue-manager-sidebar-width)-6px)] z-20 w-3 cursor-col-resize touch-none opacity-100 transition-[left,opacity] duration-[180ms,120ms] ease-[cubic-bezier(0.4,0,0.2,1),ease] motion-reduce:transition-none",
|
|
5114
5834
|
shellView.sidebar.isCollapsed && "pointer-events-none left-[-6px] opacity-0"
|
|
5115
5835
|
),
|
|
@@ -5120,17 +5840,17 @@ function IssueManagerShell({
|
|
|
5120
5840
|
onPointerDown: shellView.resizeHandle.onPointerDown,
|
|
5121
5841
|
onPointerMove: shellView.resizeHandle.onPointerMove,
|
|
5122
5842
|
onPointerUp: shellView.resizeHandle.onPointerUp,
|
|
5123
|
-
children: /* @__PURE__ */
|
|
5843
|
+
children: /* @__PURE__ */ jsx18("span", { className: "absolute top-0 bottom-0 left-1/2 w-px -translate-x-1/2 bg-transparent transition-[background-color,width] duration-150 group-hover:w-0.5 group-hover:bg-[color-mix(in_srgb,var(--border-focus)_40%,transparent)] group-focus-visible:w-0.5 group-focus-visible:bg-[color-mix(in_srgb,var(--border-focus)_40%,transparent)]" })
|
|
5124
5844
|
}
|
|
5125
5845
|
),
|
|
5126
|
-
/* @__PURE__ */
|
|
5846
|
+
/* @__PURE__ */ jsxs16(
|
|
5127
5847
|
"div",
|
|
5128
5848
|
{
|
|
5129
5849
|
className: "relative h-full min-h-0 overflow-hidden bg-transparent @container/issue-manager-content",
|
|
5130
5850
|
onPointerDownCapture: handleContentPointerDownCapture,
|
|
5131
5851
|
children: [
|
|
5132
|
-
/* @__PURE__ */
|
|
5133
|
-
/* @__PURE__ */
|
|
5852
|
+
/* @__PURE__ */ jsxs16("div", { className: "flex h-full min-h-0 flex-col", children: [
|
|
5853
|
+
/* @__PURE__ */ jsx18("div", { className: "min-h-0 flex-1 overflow-hidden", children: shellView.content.isIssueEditing ? /* @__PURE__ */ jsx18(
|
|
5134
5854
|
IssueManagerIssuePane,
|
|
5135
5855
|
{
|
|
5136
5856
|
controller,
|
|
@@ -5138,14 +5858,14 @@ function IssueManagerShell({
|
|
|
5138
5858
|
selectedIssue,
|
|
5139
5859
|
onDismissCreate: onDismissIssueCreate
|
|
5140
5860
|
}
|
|
5141
|
-
) : shellView.content.isTaskCreating ? /* @__PURE__ */
|
|
5861
|
+
) : shellView.content.isTaskCreating ? /* @__PURE__ */ jsx18(
|
|
5142
5862
|
IssueManagerTaskComposerPane,
|
|
5143
5863
|
{
|
|
5144
5864
|
controller,
|
|
5145
5865
|
selectedIssue,
|
|
5146
5866
|
onCancel: () => controller.setTaskEditorMode("read")
|
|
5147
5867
|
}
|
|
5148
|
-
) : selectedIssue ? /* @__PURE__ */
|
|
5868
|
+
) : selectedIssue ? /* @__PURE__ */ jsx18(
|
|
5149
5869
|
IssueManagerIssuePane,
|
|
5150
5870
|
{
|
|
5151
5871
|
controller,
|
|
@@ -5153,14 +5873,14 @@ function IssueManagerShell({
|
|
|
5153
5873
|
selectedIssue,
|
|
5154
5874
|
onDismissCreate: onDismissIssueCreate
|
|
5155
5875
|
}
|
|
5156
|
-
) : /* @__PURE__ */
|
|
5876
|
+
) : /* @__PURE__ */ jsx18(
|
|
5157
5877
|
IssueManagerShellEmptyState,
|
|
5158
5878
|
{
|
|
5159
5879
|
controller,
|
|
5160
5880
|
emptyIllustration
|
|
5161
5881
|
}
|
|
5162
5882
|
) }),
|
|
5163
|
-
/* @__PURE__ */
|
|
5883
|
+
/* @__PURE__ */ jsx18(
|
|
5164
5884
|
IssueManagerBottomBar,
|
|
5165
5885
|
{
|
|
5166
5886
|
controller,
|
|
@@ -5170,7 +5890,7 @@ function IssueManagerShell({
|
|
|
5170
5890
|
}
|
|
5171
5891
|
)
|
|
5172
5892
|
] }),
|
|
5173
|
-
taskDrawerTask ? /* @__PURE__ */
|
|
5893
|
+
taskDrawerTask ? /* @__PURE__ */ jsx18(
|
|
5174
5894
|
IssueManagerTaskDrawer,
|
|
5175
5895
|
{
|
|
5176
5896
|
controller,
|
|
@@ -5181,29 +5901,6 @@ function IssueManagerShell({
|
|
|
5181
5901
|
onClose: handleCloseTaskDrawer,
|
|
5182
5902
|
shouldIgnoreBackdropClick: shouldIgnoreTaskDrawerBackdropClick
|
|
5183
5903
|
}
|
|
5184
|
-
) : null,
|
|
5185
|
-
isTaskDrawerCloseBlockerVisible ? /* @__PURE__ */ jsx17(
|
|
5186
|
-
"div",
|
|
5187
|
-
{
|
|
5188
|
-
"aria-hidden": "true",
|
|
5189
|
-
className: "absolute inset-0 z-20 bg-transparent",
|
|
5190
|
-
onClick: (event) => {
|
|
5191
|
-
event.preventDefault();
|
|
5192
|
-
event.stopPropagation();
|
|
5193
|
-
},
|
|
5194
|
-
onDoubleClick: (event) => {
|
|
5195
|
-
event.preventDefault();
|
|
5196
|
-
event.stopPropagation();
|
|
5197
|
-
},
|
|
5198
|
-
onPointerDown: (event) => {
|
|
5199
|
-
event.preventDefault();
|
|
5200
|
-
event.stopPropagation();
|
|
5201
|
-
},
|
|
5202
|
-
onPointerUp: (event) => {
|
|
5203
|
-
event.preventDefault();
|
|
5204
|
-
event.stopPropagation();
|
|
5205
|
-
}
|
|
5206
|
-
}
|
|
5207
5904
|
) : null
|
|
5208
5905
|
]
|
|
5209
5906
|
}
|
|
@@ -5216,18 +5913,18 @@ function IssueManagerShellEmptyState({
|
|
|
5216
5913
|
controller,
|
|
5217
5914
|
emptyIllustration
|
|
5218
5915
|
}) {
|
|
5219
|
-
return /* @__PURE__ */
|
|
5220
|
-
emptyIllustration ? /* @__PURE__ */
|
|
5221
|
-
/* @__PURE__ */
|
|
5222
|
-
/* @__PURE__ */
|
|
5223
|
-
/* @__PURE__ */
|
|
5916
|
+
return /* @__PURE__ */ jsx18("div", { className: "flex h-full min-h-[320px] items-center justify-center px-10 py-10", children: /* @__PURE__ */ jsxs16("div", { className: "grid max-w-[420px] justify-items-center gap-2 text-center", children: [
|
|
5917
|
+
emptyIllustration ? /* @__PURE__ */ jsx18("div", { className: "mb-4", children: emptyIllustration }) : null,
|
|
5918
|
+
/* @__PURE__ */ jsx18("h2", { className: "text-[13px] font-semibold leading-5 text-[var(--text-primary)]", children: controller.copy.t("messages.noIssues") }),
|
|
5919
|
+
/* @__PURE__ */ jsx18("p", { className: "max-w-[420px] text-[13px] leading-5 text-[var(--text-secondary)]", children: controller.copy.t("emptyState") }),
|
|
5920
|
+
/* @__PURE__ */ jsxs16(
|
|
5224
5921
|
Button11,
|
|
5225
5922
|
{
|
|
5226
5923
|
className: "mt-2 gap-2",
|
|
5227
5924
|
type: "button",
|
|
5228
5925
|
onClick: () => controller.setIssueEditorMode("create"),
|
|
5229
5926
|
children: [
|
|
5230
|
-
/* @__PURE__ */
|
|
5927
|
+
/* @__PURE__ */ jsx18(FileCreateIcon4, { size: 16 }),
|
|
5231
5928
|
controller.copy.t("actions.createIssue")
|
|
5232
5929
|
]
|
|
5233
5930
|
}
|
|
@@ -5236,11 +5933,11 @@ function IssueManagerShellEmptyState({
|
|
|
5236
5933
|
}
|
|
5237
5934
|
|
|
5238
5935
|
// src/ui/internal/shell/IssueManagerTopicSelector.tsx
|
|
5239
|
-
import { useEffect as
|
|
5936
|
+
import { useEffect as useEffect9, useState as useState11 } from "react";
|
|
5240
5937
|
import {
|
|
5241
5938
|
BareIconButton as BareIconButton2,
|
|
5242
5939
|
Button as Button12,
|
|
5243
|
-
CheckIcon
|
|
5940
|
+
CheckIcon,
|
|
5244
5941
|
ChevronDownIcon as ChevronDownIcon2,
|
|
5245
5942
|
ConfirmationDialog as ConfirmationDialog3,
|
|
5246
5943
|
Dialog,
|
|
@@ -5261,9 +5958,9 @@ import {
|
|
|
5261
5958
|
PinFilledIcon,
|
|
5262
5959
|
PinIcon,
|
|
5263
5960
|
Textarea,
|
|
5264
|
-
cn as
|
|
5961
|
+
cn as cn11
|
|
5265
5962
|
} from "@tutti-os/ui-system";
|
|
5266
|
-
import { Fragment as Fragment3, jsx as
|
|
5963
|
+
import { Fragment as Fragment3, jsx as jsx19, jsxs as jsxs17 } from "react/jsx-runtime";
|
|
5267
5964
|
var topicSelectorMenuItemClassName = "min-h-7 overflow-hidden rounded-md py-1 text-[13px] font-normal leading-[1.2] text-[var(--text-primary)]";
|
|
5268
5965
|
var topicSelectorRowItemClassName = "min-w-0 flex-1 bg-transparent pr-2 pl-1 hover:bg-transparent focus:bg-transparent data-[highlighted]:bg-transparent";
|
|
5269
5966
|
function IssueManagerTopicSelector({
|
|
@@ -5276,11 +5973,11 @@ function IssueManagerTopicSelector({
|
|
|
5276
5973
|
onUpdateTopic,
|
|
5277
5974
|
topics
|
|
5278
5975
|
}) {
|
|
5279
|
-
const [dialogMode, setDialogMode] =
|
|
5280
|
-
const [deleteTopic, setDeleteTopic] =
|
|
5976
|
+
const [dialogMode, setDialogMode] = useState11(null);
|
|
5977
|
+
const [deleteTopic, setDeleteTopic] = useState11(
|
|
5281
5978
|
null
|
|
5282
5979
|
);
|
|
5283
|
-
const [menuOpen, setMenuOpen] =
|
|
5980
|
+
const [menuOpen, setMenuOpen] = useState11(false);
|
|
5284
5981
|
const activeTopic = topics.find((topic) => topic.topicId === activeTopicId);
|
|
5285
5982
|
const topicLabel = copy.t("labels.topic");
|
|
5286
5983
|
const triggerLabel = formatIssueManagerTopicSelectorTriggerLabel({
|
|
@@ -5291,13 +5988,13 @@ function IssueManagerTopicSelector({
|
|
|
5291
5988
|
setMenuOpen(false);
|
|
5292
5989
|
setDialogMode(mode);
|
|
5293
5990
|
};
|
|
5294
|
-
return /* @__PURE__ */
|
|
5295
|
-
/* @__PURE__ */
|
|
5296
|
-
/* @__PURE__ */
|
|
5991
|
+
return /* @__PURE__ */ jsxs17(Fragment3, { children: [
|
|
5992
|
+
/* @__PURE__ */ jsxs17(DropdownMenu2, { open: menuOpen, onOpenChange: setMenuOpen, children: [
|
|
5993
|
+
/* @__PURE__ */ jsx19(DropdownMenuTrigger2, { asChild: true, children: /* @__PURE__ */ jsxs17(
|
|
5297
5994
|
Button12,
|
|
5298
5995
|
{
|
|
5299
5996
|
"aria-label": topicLabel,
|
|
5300
|
-
className:
|
|
5997
|
+
className: cn11(
|
|
5301
5998
|
"max-w-[220px] gap-1 rounded-md border-0 bg-transparent text-[13px] font-normal shadow-none hover:bg-transparent focus:bg-transparent focus-visible:border-0 focus-visible:bg-transparent focus-visible:ring-0 active:bg-transparent aria-expanded:bg-transparent [&[data-state=open]>svg]:rotate-180",
|
|
5302
5999
|
className
|
|
5303
6000
|
),
|
|
@@ -5305,21 +6002,21 @@ function IssueManagerTopicSelector({
|
|
|
5305
6002
|
type: "button",
|
|
5306
6003
|
variant: "ghost",
|
|
5307
6004
|
children: [
|
|
5308
|
-
/* @__PURE__ */
|
|
5309
|
-
/* @__PURE__ */
|
|
6005
|
+
/* @__PURE__ */ jsx19("span", { className: "min-w-0 truncate", children: triggerLabel }),
|
|
6006
|
+
/* @__PURE__ */ jsx19(ChevronDownIcon2, { className: "size-4 shrink-0 text-[var(--text-tertiary)] transition-transform duration-200" })
|
|
5310
6007
|
]
|
|
5311
6008
|
}
|
|
5312
6009
|
) }),
|
|
5313
|
-
/* @__PURE__ */
|
|
6010
|
+
/* @__PURE__ */ jsxs17(DropdownMenuContent2, { align: "start", className: "w-[200px] px-1", children: [
|
|
5314
6011
|
topics.map((topic) => {
|
|
5315
6012
|
const isPinned = (topic.pinnedAtUnix ?? 0) > 0;
|
|
5316
6013
|
const isActive = topic.topicId === activeTopicId;
|
|
5317
6014
|
const pinLabel = isPinned ? copy.t("actions.unpinTopic") : copy.t("actions.pinTopic");
|
|
5318
|
-
return /* @__PURE__ */
|
|
5319
|
-
/* @__PURE__ */
|
|
6015
|
+
return /* @__PURE__ */ jsx19("div", { className: "min-w-0", children: /* @__PURE__ */ jsxs17("div", { className: "group/topic-row relative flex min-h-7 min-w-0 items-center gap-0.5 rounded-md pr-0.5 pl-0.5 hover:bg-[var(--transparency-block)] focus-within:bg-[var(--transparency-block)]", children: [
|
|
6016
|
+
/* @__PURE__ */ jsxs17(
|
|
5320
6017
|
DropdownMenuItem2,
|
|
5321
6018
|
{
|
|
5322
|
-
className:
|
|
6019
|
+
className: cn11(
|
|
5323
6020
|
topicSelectorMenuItemClassName,
|
|
5324
6021
|
topicSelectorRowItemClassName
|
|
5325
6022
|
),
|
|
@@ -5328,19 +6025,19 @@ function IssueManagerTopicSelector({
|
|
|
5328
6025
|
onSelectTopic(topic.topicId);
|
|
5329
6026
|
},
|
|
5330
6027
|
children: [
|
|
5331
|
-
/* @__PURE__ */
|
|
5332
|
-
/* @__PURE__ */
|
|
5333
|
-
/* @__PURE__ */
|
|
5334
|
-
topic.isDefault ? /* @__PURE__ */
|
|
6028
|
+
/* @__PURE__ */ jsx19("span", { className: "flex size-4 shrink-0 items-center justify-center text-[var(--accent)]", children: isActive ? /* @__PURE__ */ jsx19(CheckIcon, { className: "size-4" }) : null }),
|
|
6029
|
+
/* @__PURE__ */ jsxs17("span", { className: "flex min-w-0 flex-1 items-center gap-2", children: [
|
|
6030
|
+
/* @__PURE__ */ jsx19("span", { className: "truncate", children: topic.title }),
|
|
6031
|
+
topic.isDefault ? /* @__PURE__ */ jsx19("span", { className: "shrink-0 text-[11px] text-[var(--text-tertiary)]", children: copy.t("labels.topicDefault") }) : null
|
|
5335
6032
|
] })
|
|
5336
6033
|
]
|
|
5337
6034
|
}
|
|
5338
6035
|
),
|
|
5339
|
-
/* @__PURE__ */
|
|
6036
|
+
/* @__PURE__ */ jsx19(
|
|
5340
6037
|
BareIconButton2,
|
|
5341
6038
|
{
|
|
5342
6039
|
"aria-label": pinLabel,
|
|
5343
|
-
className:
|
|
6040
|
+
className: cn11(
|
|
5344
6041
|
"pointer-events-none shrink-0 opacity-0 text-[var(--text-tertiary)] transition-opacity duration-150 group-hover/topic-row:pointer-events-auto group-hover/topic-row:opacity-100 group-focus-within/topic-row:pointer-events-auto group-focus-within/topic-row:opacity-100 hover:text-[var(--text-primary)]",
|
|
5345
6042
|
isPinned && "text-[var(--text-primary)]"
|
|
5346
6043
|
),
|
|
@@ -5354,11 +6051,11 @@ function IssueManagerTopicSelector({
|
|
|
5354
6051
|
topicId: topic.topicId
|
|
5355
6052
|
});
|
|
5356
6053
|
},
|
|
5357
|
-
children: isPinned ? /* @__PURE__ */
|
|
6054
|
+
children: isPinned ? /* @__PURE__ */ jsx19(PinFilledIcon, { className: "size-3.5" }) : /* @__PURE__ */ jsx19(PinIcon, { className: "size-3.5" })
|
|
5358
6055
|
}
|
|
5359
6056
|
),
|
|
5360
|
-
/* @__PURE__ */
|
|
5361
|
-
/* @__PURE__ */
|
|
6057
|
+
/* @__PURE__ */ jsxs17(DropdownMenu2, { modal: false, children: [
|
|
6058
|
+
/* @__PURE__ */ jsx19(DropdownMenuTrigger2, { asChild: true, children: /* @__PURE__ */ jsx19(
|
|
5362
6059
|
BareIconButton2,
|
|
5363
6060
|
{
|
|
5364
6061
|
"aria-label": copy.t("actions.moreActions"),
|
|
@@ -5368,17 +6065,17 @@ function IssueManagerTopicSelector({
|
|
|
5368
6065
|
onClick: (event) => {
|
|
5369
6066
|
event.stopPropagation();
|
|
5370
6067
|
},
|
|
5371
|
-
children: /* @__PURE__ */
|
|
6068
|
+
children: /* @__PURE__ */ jsx19(MoreHorizontalIcon, { className: "size-3.5" })
|
|
5372
6069
|
}
|
|
5373
6070
|
) }),
|
|
5374
|
-
/* @__PURE__ */
|
|
6071
|
+
/* @__PURE__ */ jsxs17(
|
|
5375
6072
|
DropdownMenuContent2,
|
|
5376
6073
|
{
|
|
5377
6074
|
align: "end",
|
|
5378
6075
|
className: "w-32",
|
|
5379
6076
|
sideOffset: 6,
|
|
5380
6077
|
children: [
|
|
5381
|
-
/* @__PURE__ */
|
|
6078
|
+
/* @__PURE__ */ jsxs17(
|
|
5382
6079
|
DropdownMenuItem2,
|
|
5383
6080
|
{
|
|
5384
6081
|
onSelect: (event) => {
|
|
@@ -5389,12 +6086,12 @@ function IssueManagerTopicSelector({
|
|
|
5389
6086
|
});
|
|
5390
6087
|
},
|
|
5391
6088
|
children: [
|
|
5392
|
-
/* @__PURE__ */
|
|
5393
|
-
/* @__PURE__ */
|
|
6089
|
+
/* @__PURE__ */ jsx19(EditIcon, { className: "size-3.5" }),
|
|
6090
|
+
/* @__PURE__ */ jsx19("span", { children: copy.t("actions.editTopic") })
|
|
5394
6091
|
]
|
|
5395
6092
|
}
|
|
5396
6093
|
),
|
|
5397
|
-
!topic.isDefault ? /* @__PURE__ */
|
|
6094
|
+
!topic.isDefault ? /* @__PURE__ */ jsxs17(
|
|
5398
6095
|
DropdownMenuItem2,
|
|
5399
6096
|
{
|
|
5400
6097
|
variant: "destructive",
|
|
@@ -5404,8 +6101,8 @@ function IssueManagerTopicSelector({
|
|
|
5404
6101
|
setDeleteTopic(topic);
|
|
5405
6102
|
},
|
|
5406
6103
|
children: [
|
|
5407
|
-
/* @__PURE__ */
|
|
5408
|
-
/* @__PURE__ */
|
|
6104
|
+
/* @__PURE__ */ jsx19(DeleteIcon, { className: "size-3.5" }),
|
|
6105
|
+
/* @__PURE__ */ jsx19("span", { children: copy.t("actions.delete") })
|
|
5409
6106
|
]
|
|
5410
6107
|
}
|
|
5411
6108
|
) : null
|
|
@@ -5415,12 +6112,12 @@ function IssueManagerTopicSelector({
|
|
|
5415
6112
|
] })
|
|
5416
6113
|
] }) }, topic.topicId);
|
|
5417
6114
|
}),
|
|
5418
|
-
topics.length === 0 ? /* @__PURE__ */
|
|
5419
|
-
/* @__PURE__ */
|
|
5420
|
-
/* @__PURE__ */
|
|
6115
|
+
topics.length === 0 ? /* @__PURE__ */ jsx19("div", { className: "px-3 py-2 text-[11px] leading-4 text-[var(--text-tertiary)]", children: copy.t("messages.topicListEmpty") }) : null,
|
|
6116
|
+
/* @__PURE__ */ jsx19(DropdownMenuSeparator, {}),
|
|
6117
|
+
/* @__PURE__ */ jsxs17(
|
|
5421
6118
|
DropdownMenuItem2,
|
|
5422
6119
|
{
|
|
5423
|
-
className:
|
|
6120
|
+
className: cn11(
|
|
5424
6121
|
topicSelectorMenuItemClassName,
|
|
5425
6122
|
"justify-start gap-2 px-2 text-left"
|
|
5426
6123
|
),
|
|
@@ -5432,14 +6129,14 @@ function IssueManagerTopicSelector({
|
|
|
5432
6129
|
});
|
|
5433
6130
|
},
|
|
5434
6131
|
children: [
|
|
5435
|
-
/* @__PURE__ */
|
|
5436
|
-
/* @__PURE__ */
|
|
6132
|
+
/* @__PURE__ */ jsx19(FileCreateIcon5, { className: "size-3.5" }),
|
|
6133
|
+
/* @__PURE__ */ jsx19("span", { className: "truncate", children: copy.t("actions.createTopic") })
|
|
5437
6134
|
]
|
|
5438
6135
|
}
|
|
5439
6136
|
)
|
|
5440
6137
|
] })
|
|
5441
6138
|
] }),
|
|
5442
|
-
/* @__PURE__ */
|
|
6139
|
+
/* @__PURE__ */ jsx19(
|
|
5443
6140
|
IssueManagerTopicDialog,
|
|
5444
6141
|
{
|
|
5445
6142
|
copy,
|
|
@@ -5454,7 +6151,7 @@ function IssueManagerTopicSelector({
|
|
|
5454
6151
|
onUpdateTopic
|
|
5455
6152
|
}
|
|
5456
6153
|
),
|
|
5457
|
-
/* @__PURE__ */
|
|
6154
|
+
/* @__PURE__ */ jsx19(
|
|
5458
6155
|
ConfirmationDialog3,
|
|
5459
6156
|
{
|
|
5460
6157
|
cancelLabel: copy.t("actions.cancel"),
|
|
@@ -5495,9 +6192,9 @@ function IssueManagerTopicDialog({
|
|
|
5495
6192
|
onUpdateTopic,
|
|
5496
6193
|
open
|
|
5497
6194
|
}) {
|
|
5498
|
-
const [summaryDraft, setSummaryDraft] =
|
|
5499
|
-
const [titleDraft, setTitleDraft] =
|
|
5500
|
-
|
|
6195
|
+
const [summaryDraft, setSummaryDraft] = useState11("");
|
|
6196
|
+
const [titleDraft, setTitleDraft] = useState11("");
|
|
6197
|
+
useEffect9(() => {
|
|
5501
6198
|
setTitleDraft(mode?.topic?.title ?? "");
|
|
5502
6199
|
setSummaryDraft(mode?.topic?.summary ?? "");
|
|
5503
6200
|
}, [mode]);
|
|
@@ -5522,12 +6219,12 @@ function IssueManagerTopicDialog({
|
|
|
5522
6219
|
}
|
|
5523
6220
|
onOpenChange(false);
|
|
5524
6221
|
};
|
|
5525
|
-
return /* @__PURE__ */
|
|
5526
|
-
/* @__PURE__ */
|
|
5527
|
-
/* @__PURE__ */
|
|
5528
|
-
/* @__PURE__ */
|
|
5529
|
-
/* @__PURE__ */
|
|
5530
|
-
/* @__PURE__ */
|
|
6222
|
+
return /* @__PURE__ */ jsx19(Dialog, { open, onOpenChange, children: /* @__PURE__ */ jsxs17(DialogContent, { className: "sm:max-w-[480px]", children: [
|
|
6223
|
+
/* @__PURE__ */ jsx19(DialogHeader, { children: /* @__PURE__ */ jsx19(DialogTitle, { children: dialogTitle }) }),
|
|
6224
|
+
/* @__PURE__ */ jsxs17("form", { className: "grid gap-4", onSubmit: submit, children: [
|
|
6225
|
+
/* @__PURE__ */ jsxs17("label", { className: "grid gap-2", children: [
|
|
6226
|
+
/* @__PURE__ */ jsx19("span", { className: "text-[11px] font-medium leading-4 text-[var(--text-secondary)]", children: copy.t("labels.topicTitle") }),
|
|
6227
|
+
/* @__PURE__ */ jsx19(
|
|
5531
6228
|
Input3,
|
|
5532
6229
|
{
|
|
5533
6230
|
autoFocus: true,
|
|
@@ -5537,9 +6234,9 @@ function IssueManagerTopicDialog({
|
|
|
5537
6234
|
}
|
|
5538
6235
|
)
|
|
5539
6236
|
] }),
|
|
5540
|
-
/* @__PURE__ */
|
|
5541
|
-
/* @__PURE__ */
|
|
5542
|
-
/* @__PURE__ */
|
|
6237
|
+
/* @__PURE__ */ jsxs17("label", { className: "grid gap-2", children: [
|
|
6238
|
+
/* @__PURE__ */ jsx19("span", { className: "text-[11px] font-medium leading-4 text-[var(--text-secondary)]", children: copy.t("labels.topicSummary") }),
|
|
6239
|
+
/* @__PURE__ */ jsx19(
|
|
5543
6240
|
Textarea,
|
|
5544
6241
|
{
|
|
5545
6242
|
className: "min-h-24 resize-none",
|
|
@@ -5549,8 +6246,8 @@ function IssueManagerTopicDialog({
|
|
|
5549
6246
|
}
|
|
5550
6247
|
)
|
|
5551
6248
|
] }),
|
|
5552
|
-
/* @__PURE__ */
|
|
5553
|
-
/* @__PURE__ */
|
|
6249
|
+
/* @__PURE__ */ jsxs17(DialogFooter, { className: "pt-2", children: [
|
|
6250
|
+
/* @__PURE__ */ jsx19(
|
|
5554
6251
|
Button12,
|
|
5555
6252
|
{
|
|
5556
6253
|
size: "dialog",
|
|
@@ -5560,14 +6257,14 @@ function IssueManagerTopicDialog({
|
|
|
5560
6257
|
children: copy.t("actions.cancel")
|
|
5561
6258
|
}
|
|
5562
6259
|
),
|
|
5563
|
-
/* @__PURE__ */
|
|
6260
|
+
/* @__PURE__ */ jsx19(Button12, { disabled: !title, size: "dialog", type: "submit", children: copy.t("actions.saveTopic") })
|
|
5564
6261
|
] })
|
|
5565
6262
|
] })
|
|
5566
6263
|
] }) });
|
|
5567
6264
|
}
|
|
5568
6265
|
|
|
5569
6266
|
// src/ui/IssueManagerNode.tsx
|
|
5570
|
-
import { jsx as
|
|
6267
|
+
import { jsx as jsx20, jsxs as jsxs18 } from "react/jsx-runtime";
|
|
5571
6268
|
function IssueManagerNode({
|
|
5572
6269
|
diagnostics,
|
|
5573
6270
|
emptyIllustration,
|
|
@@ -5593,8 +6290,8 @@ function IssueManagerNode({
|
|
|
5593
6290
|
state,
|
|
5594
6291
|
workspaceId
|
|
5595
6292
|
});
|
|
5596
|
-
const lastHandledOpenRequestIdRef =
|
|
5597
|
-
|
|
6293
|
+
const lastHandledOpenRequestIdRef = useRef8(null);
|
|
6294
|
+
useEffect10(() => {
|
|
5598
6295
|
if (!openRequest?.requestId) {
|
|
5599
6296
|
return;
|
|
5600
6297
|
}
|
|
@@ -5630,7 +6327,7 @@ function IssueManagerNode({
|
|
|
5630
6327
|
controller.selectIssue(openRequest.issueId);
|
|
5631
6328
|
controller.selectTask(openRequest.taskId?.trim() || null);
|
|
5632
6329
|
}, [controller, openRequest]);
|
|
5633
|
-
|
|
6330
|
+
useEffect10(() => {
|
|
5634
6331
|
dispatchIssueManagerTopicHeaderState({
|
|
5635
6332
|
activeTopicId: controller.nodeState.activeTopicId ?? null,
|
|
5636
6333
|
nodeId,
|
|
@@ -5657,7 +6354,7 @@ function IssueManagerNode({
|
|
|
5657
6354
|
},
|
|
5658
6355
|
workspaceId
|
|
5659
6356
|
});
|
|
5660
|
-
return /* @__PURE__ */
|
|
6357
|
+
return /* @__PURE__ */ jsxs18(
|
|
5661
6358
|
"section",
|
|
5662
6359
|
{
|
|
5663
6360
|
"aria-label": controller.copy.t("title"),
|
|
@@ -5665,7 +6362,7 @@ function IssueManagerNode({
|
|
|
5665
6362
|
"data-issue-manager-node-id": nodeId,
|
|
5666
6363
|
"data-issue-manager-workspace-id": workspaceId,
|
|
5667
6364
|
children: [
|
|
5668
|
-
/* @__PURE__ */
|
|
6365
|
+
/* @__PURE__ */ jsx20(
|
|
5669
6366
|
IssueManagerShell,
|
|
5670
6367
|
{
|
|
5671
6368
|
controller,
|
|
@@ -5677,7 +6374,7 @@ function IssueManagerNode({
|
|
|
5677
6374
|
selectedTask
|
|
5678
6375
|
}
|
|
5679
6376
|
),
|
|
5680
|
-
feature.referenceSourceAggregator ? /* @__PURE__ */
|
|
6377
|
+
feature.referenceSourceAggregator ? /* @__PURE__ */ jsx20(
|
|
5681
6378
|
ReferenceSourcePicker,
|
|
5682
6379
|
{
|
|
5683
6380
|
aggregator: feature.referenceSourceAggregator,
|
|
@@ -5688,7 +6385,7 @@ function IssueManagerNode({
|
|
|
5688
6385
|
onConfirm: referencePicker.onConfirm,
|
|
5689
6386
|
onConfirmBundles: referencePicker.onConfirmBundles
|
|
5690
6387
|
}
|
|
5691
|
-
) : /* @__PURE__ */
|
|
6388
|
+
) : /* @__PURE__ */ jsx20(
|
|
5692
6389
|
WorkspaceFileReferencePicker,
|
|
5693
6390
|
{
|
|
5694
6391
|
copy: controller.copy,
|
|
@@ -5741,16 +6438,16 @@ function IssueManagerNodeHeader({
|
|
|
5741
6438
|
nodeId,
|
|
5742
6439
|
workspaceId
|
|
5743
6440
|
});
|
|
5744
|
-
return /* @__PURE__ */
|
|
6441
|
+
return /* @__PURE__ */ jsxs18(
|
|
5745
6442
|
"header",
|
|
5746
6443
|
{
|
|
5747
6444
|
...restHeaderProps,
|
|
5748
|
-
className:
|
|
6445
|
+
className: cn12(
|
|
5749
6446
|
"relative flex h-full min-h-0 items-center justify-between gap-3 bg-[var(--background-panel)] px-2 pl-3",
|
|
5750
6447
|
className
|
|
5751
6448
|
),
|
|
5752
6449
|
children: [
|
|
5753
|
-
/* @__PURE__ */
|
|
6450
|
+
/* @__PURE__ */ jsx20(
|
|
5754
6451
|
"div",
|
|
5755
6452
|
{
|
|
5756
6453
|
...dragHandleProps,
|
|
@@ -5758,14 +6455,14 @@ function IssueManagerNodeHeader({
|
|
|
5758
6455
|
className: "absolute inset-0 cursor-grab active:cursor-grabbing"
|
|
5759
6456
|
}
|
|
5760
6457
|
),
|
|
5761
|
-
/* @__PURE__ */
|
|
6458
|
+
/* @__PURE__ */ jsxs18(
|
|
5762
6459
|
"div",
|
|
5763
6460
|
{
|
|
5764
6461
|
...dragHandleProps,
|
|
5765
6462
|
className: "z-10 flex min-w-0 cursor-grab items-center gap-2 active:cursor-grabbing",
|
|
5766
6463
|
children: [
|
|
5767
|
-
/* @__PURE__ */
|
|
5768
|
-
/* @__PURE__ */
|
|
6464
|
+
/* @__PURE__ */ jsx20("span", { className: "min-w-0 truncate text-[13px] font-semibold leading-5 text-[var(--text-primary)]", children: title?.trim() || copy.t("title") }),
|
|
6465
|
+
/* @__PURE__ */ jsx20(
|
|
5769
6466
|
Button13,
|
|
5770
6467
|
{
|
|
5771
6468
|
"aria-label": toggleLabel,
|
|
@@ -5782,19 +6479,19 @@ function IssueManagerNodeHeader({
|
|
|
5782
6479
|
},
|
|
5783
6480
|
onDoubleClick: (event) => event.stopPropagation(),
|
|
5784
6481
|
onPointerDown: (event) => event.stopPropagation(),
|
|
5785
|
-
children: /* @__PURE__ */
|
|
6482
|
+
children: /* @__PURE__ */ jsx20(PanelIcon, { className: "size-[18px]" })
|
|
5786
6483
|
}
|
|
5787
6484
|
)
|
|
5788
6485
|
]
|
|
5789
6486
|
}
|
|
5790
6487
|
),
|
|
5791
|
-
/* @__PURE__ */
|
|
6488
|
+
/* @__PURE__ */ jsx20("div", { className: "pointer-events-none absolute top-1/2 left-1/2 z-20 flex max-w-[220px] -translate-x-1/2 -translate-y-1/2 items-center justify-center", children: /* @__PURE__ */ jsx20(
|
|
5792
6489
|
"div",
|
|
5793
6490
|
{
|
|
5794
6491
|
className: "pointer-events-auto flex min-w-0 flex-none",
|
|
5795
6492
|
onDoubleClick: (event) => event.stopPropagation(),
|
|
5796
6493
|
onPointerDown: (event) => event.stopPropagation(),
|
|
5797
|
-
children: /* @__PURE__ */
|
|
6494
|
+
children: /* @__PURE__ */ jsx20(
|
|
5798
6495
|
IssueManagerTopicSelector,
|
|
5799
6496
|
{
|
|
5800
6497
|
activeTopicId: topicState.activeTopicId,
|
|
@@ -5833,7 +6530,7 @@ function IssueManagerNodeHeader({
|
|
|
5833
6530
|
)
|
|
5834
6531
|
}
|
|
5835
6532
|
) }),
|
|
5836
|
-
/* @__PURE__ */
|
|
6533
|
+
/* @__PURE__ */ jsx20(
|
|
5837
6534
|
"div",
|
|
5838
6535
|
{
|
|
5839
6536
|
className: "z-10 flex flex-none items-center gap-1",
|
|
@@ -5852,4 +6549,4 @@ export {
|
|
|
5852
6549
|
IssueManagerNode,
|
|
5853
6550
|
IssueManagerNodeHeader
|
|
5854
6551
|
};
|
|
5855
|
-
//# sourceMappingURL=chunk-
|
|
6552
|
+
//# sourceMappingURL=chunk-DYOOXQA7.js.map
|