@tutti-os/workspace-issue-manager 0.0.14 → 0.0.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/assets/workspace-dock-task.png +0 -0
- package/dist/{chunk-JOEMRSA4.js → chunk-7KCCNQDW.js} +100 -13
- package/dist/chunk-7KCCNQDW.js.map +1 -0
- package/dist/{chunk-MLBXKQLG.js → chunk-EETI7JRL.js} +29 -5
- package/dist/chunk-EETI7JRL.js.map +1 -0
- package/dist/{chunk-5A25XEF2.js → chunk-QTFOTY4H.js} +4 -4
- package/dist/{chunk-5A25XEF2.js.map → chunk-QTFOTY4H.js.map} +1 -1
- package/dist/{chunk-ABQR5VIJ.js → chunk-U26GIQIJ.js} +127 -127
- package/dist/chunk-U26GIQIJ.js.map +1 -0
- 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 +100 -0
- package/package.json +10 -10
- package/dist/chunk-ABQR5VIJ.js.map +0 -1
- package/dist/chunk-JOEMRSA4.js.map +0 -1
- package/dist/chunk-MLBXKQLG.js.map +0 -1
|
Binary file
|
|
@@ -24,7 +24,7 @@ import {
|
|
|
24
24
|
resolveIssueManagerTopicDeleteErrorMessage,
|
|
25
25
|
toContextRefInput,
|
|
26
26
|
toIssueManagerWorkspaceFileLinkInput
|
|
27
|
-
} from "./chunk-
|
|
27
|
+
} from "./chunk-EETI7JRL.js";
|
|
28
28
|
import {
|
|
29
29
|
appendIssueManagerWorkspaceFileLinksToContent,
|
|
30
30
|
clampIssueManagerSidebarWidth,
|
|
@@ -35,7 +35,7 @@ import {
|
|
|
35
35
|
issueManagerSidebarMinWidth,
|
|
36
36
|
normalizeIssueManagerContent,
|
|
37
37
|
shouldAutoCollapseIssueManagerSidebar
|
|
38
|
-
} from "./chunk-
|
|
38
|
+
} from "./chunk-QTFOTY4H.js";
|
|
39
39
|
|
|
40
40
|
// src/ui/react/internal/shell/IssueManagerNodeState.ts
|
|
41
41
|
import { useEffect, useEffectEvent, useState } from "react";
|
|
@@ -2120,9 +2120,8 @@ import {
|
|
|
2120
2120
|
function issueManagerStatusBadgeVariant(status) {
|
|
2121
2121
|
switch (status) {
|
|
2122
2122
|
case "running":
|
|
2123
|
-
return "accent";
|
|
2124
2123
|
case "in_progress":
|
|
2125
|
-
return "
|
|
2124
|
+
return "accent";
|
|
2126
2125
|
case "pending_acceptance":
|
|
2127
2126
|
return "pending";
|
|
2128
2127
|
case "completed":
|
|
@@ -3415,7 +3414,6 @@ var issueManagerStatusFilters = [
|
|
|
3415
3414
|
"all",
|
|
3416
3415
|
"not_started",
|
|
3417
3416
|
"running",
|
|
3418
|
-
"in_progress",
|
|
3419
3417
|
"pending_acceptance",
|
|
3420
3418
|
"completed",
|
|
3421
3419
|
"failed",
|
|
@@ -3452,14 +3450,14 @@ function buildIssueManagerStatusCounts(issues) {
|
|
|
3452
3450
|
canceled: 0,
|
|
3453
3451
|
completed: 0,
|
|
3454
3452
|
failed: 0,
|
|
3455
|
-
in_progress: 0,
|
|
3456
3453
|
not_started: 0,
|
|
3457
3454
|
pending_acceptance: 0,
|
|
3458
3455
|
running: 0
|
|
3459
3456
|
};
|
|
3460
3457
|
for (const issue of issues) {
|
|
3461
|
-
|
|
3462
|
-
|
|
3458
|
+
const status = issue.status === "in_progress" ? "running" : issue.status;
|
|
3459
|
+
if (status in counts) {
|
|
3460
|
+
counts[status] += 1;
|
|
3463
3461
|
}
|
|
3464
3462
|
}
|
|
3465
3463
|
return counts;
|
|
@@ -3473,10 +3471,48 @@ function mapIssueManagerStatusCounts(counts) {
|
|
|
3473
3471
|
canceled: counts.canceled,
|
|
3474
3472
|
completed: counts.completed,
|
|
3475
3473
|
failed: counts.failed,
|
|
3476
|
-
in_progress: counts.inProgress,
|
|
3477
3474
|
not_started: counts.notStarted,
|
|
3478
3475
|
pending_acceptance: counts.pendingAcceptance,
|
|
3479
|
-
running: counts.running
|
|
3476
|
+
running: counts.running + counts.inProgress
|
|
3477
|
+
};
|
|
3478
|
+
}
|
|
3479
|
+
function resolveIssueManagerSubtaskProgress(issue) {
|
|
3480
|
+
const total = Math.max(0, Math.trunc(issue.taskCount ?? 0));
|
|
3481
|
+
if (total <= 0) {
|
|
3482
|
+
return null;
|
|
3483
|
+
}
|
|
3484
|
+
const completed = Math.min(
|
|
3485
|
+
total,
|
|
3486
|
+
Math.max(0, Math.trunc(issue.completedCount ?? 0))
|
|
3487
|
+
);
|
|
3488
|
+
return {
|
|
3489
|
+
completed,
|
|
3490
|
+
percent: completed / total * 100,
|
|
3491
|
+
total
|
|
3492
|
+
};
|
|
3493
|
+
}
|
|
3494
|
+
function resolveIssueManagerSubtaskProgressFromTasks(tasks) {
|
|
3495
|
+
const total = tasks.length;
|
|
3496
|
+
if (total <= 0) {
|
|
3497
|
+
return null;
|
|
3498
|
+
}
|
|
3499
|
+
const completed = tasks.filter(
|
|
3500
|
+
(task) => task.status === "completed" || task.status === "pending_acceptance"
|
|
3501
|
+
).length;
|
|
3502
|
+
return {
|
|
3503
|
+
completed,
|
|
3504
|
+
percent: completed / total * 100,
|
|
3505
|
+
total
|
|
3506
|
+
};
|
|
3507
|
+
}
|
|
3508
|
+
function resolveIssueManagerSubtaskProgressByIssueId(input) {
|
|
3509
|
+
if (!input.issueId || !input.visibleTasks) {
|
|
3510
|
+
return {};
|
|
3511
|
+
}
|
|
3512
|
+
return {
|
|
3513
|
+
[input.issueId]: resolveIssueManagerSubtaskProgressFromTasks(
|
|
3514
|
+
input.visibleTasks
|
|
3515
|
+
)
|
|
3480
3516
|
};
|
|
3481
3517
|
}
|
|
3482
3518
|
function resolveIssueManagerShellContentViewState(input) {
|
|
@@ -3555,6 +3591,7 @@ function IssueManagerSidebarBody({
|
|
|
3555
3591
|
isNarrowLayout,
|
|
3556
3592
|
selectedIssueId,
|
|
3557
3593
|
sidebarViewState,
|
|
3594
|
+
subtaskProgressByIssueId,
|
|
3558
3595
|
onRetry,
|
|
3559
3596
|
onSelectIssue
|
|
3560
3597
|
}) {
|
|
@@ -3592,6 +3629,7 @@ function IssueManagerSidebarBody({
|
|
|
3592
3629
|
isNarrowLayout,
|
|
3593
3630
|
issues: sidebarViewState.issues,
|
|
3594
3631
|
selectedIssueId,
|
|
3632
|
+
subtaskProgressByIssueId,
|
|
3595
3633
|
onSelectIssue
|
|
3596
3634
|
}
|
|
3597
3635
|
)
|
|
@@ -3683,6 +3721,7 @@ function IssueManagerSidebarIssueList({
|
|
|
3683
3721
|
isNarrowLayout,
|
|
3684
3722
|
issues,
|
|
3685
3723
|
selectedIssueId,
|
|
3724
|
+
subtaskProgressByIssueId,
|
|
3686
3725
|
onSelectIssue
|
|
3687
3726
|
}) {
|
|
3688
3727
|
return /* @__PURE__ */ jsx12(
|
|
@@ -3699,6 +3738,7 @@ function IssueManagerSidebarIssueList({
|
|
|
3699
3738
|
isNarrowLayout,
|
|
3700
3739
|
issue,
|
|
3701
3740
|
selected: selectedIssueId === issue.issueId,
|
|
3741
|
+
subtaskProgress: issue.issueId in subtaskProgressByIssueId ? subtaskProgressByIssueId[issue.issueId] : void 0,
|
|
3702
3742
|
onSelect: onSelectIssue
|
|
3703
3743
|
},
|
|
3704
3744
|
issue.issueId
|
|
@@ -3711,8 +3751,10 @@ function IssueManagerSidebarItem({
|
|
|
3711
3751
|
isNarrowLayout,
|
|
3712
3752
|
issue,
|
|
3713
3753
|
onSelect,
|
|
3714
|
-
selected
|
|
3754
|
+
selected,
|
|
3755
|
+
subtaskProgress: subtaskProgressOverride
|
|
3715
3756
|
}) {
|
|
3757
|
+
const subtaskProgress = subtaskProgressOverride === void 0 ? resolveIssueManagerSubtaskProgress(issue) : subtaskProgressOverride;
|
|
3716
3758
|
return /* @__PURE__ */ jsxs10(
|
|
3717
3759
|
"button",
|
|
3718
3760
|
{
|
|
@@ -3736,7 +3778,37 @@ function IssueManagerSidebarItem({
|
|
|
3736
3778
|
/* @__PURE__ */ jsx12("p", { className: "pr-28 text-[11px] leading-[1.55] text-[var(--text-secondary)]", children: formatIssueManagerDate(issue.updatedAtUnix ?? issue.createdAtUnix) }),
|
|
3737
3779
|
/* @__PURE__ */ jsx12("p", { className: "line-clamp-4 text-[13px] font-medium leading-[1.35rem] text-[var(--text-primary)]", children: issue.title })
|
|
3738
3780
|
] }),
|
|
3739
|
-
/* @__PURE__ */
|
|
3781
|
+
subtaskProgress ? /* @__PURE__ */ jsxs10(
|
|
3782
|
+
"div",
|
|
3783
|
+
{
|
|
3784
|
+
"aria-label": `${copy.t("labels.taskCount", {
|
|
3785
|
+
count: subtaskProgress.total
|
|
3786
|
+
})}, ${subtaskProgress.completed}/${subtaskProgress.total}`,
|
|
3787
|
+
className: "mt-3 flex min-w-0 items-center gap-2 text-[11px] font-semibold leading-none text-[var(--text-secondary)]",
|
|
3788
|
+
children: [
|
|
3789
|
+
/* @__PURE__ */ jsx12("span", { className: "shrink-0", children: copy.t("labels.taskCount", { count: subtaskProgress.total }) }),
|
|
3790
|
+
/* @__PURE__ */ jsx12(
|
|
3791
|
+
"span",
|
|
3792
|
+
{
|
|
3793
|
+
"aria-hidden": "true",
|
|
3794
|
+
className: "h-0.5 w-14 shrink-0 overflow-hidden rounded-full bg-[var(--transparency-block)]",
|
|
3795
|
+
children: /* @__PURE__ */ jsx12(
|
|
3796
|
+
"span",
|
|
3797
|
+
{
|
|
3798
|
+
className: "block h-full rounded-full bg-[var(--status-running)]",
|
|
3799
|
+
style: { width: `${subtaskProgress.percent}%` }
|
|
3800
|
+
}
|
|
3801
|
+
)
|
|
3802
|
+
}
|
|
3803
|
+
),
|
|
3804
|
+
/* @__PURE__ */ jsxs10("span", { className: "shrink-0 text-[var(--text-primary)]", children: [
|
|
3805
|
+
subtaskProgress.completed,
|
|
3806
|
+
"/",
|
|
3807
|
+
subtaskProgress.total
|
|
3808
|
+
] })
|
|
3809
|
+
]
|
|
3810
|
+
}
|
|
3811
|
+
) : null
|
|
3740
3812
|
]
|
|
3741
3813
|
}
|
|
3742
3814
|
);
|
|
@@ -3864,6 +3936,20 @@ function IssueManagerSidebar({
|
|
|
3864
3936
|
showStandaloneState,
|
|
3865
3937
|
sidebarViewState
|
|
3866
3938
|
});
|
|
3939
|
+
const currentIssueDetail = controller.issueDetail.value?.issue.issueId === controller.nodeState.selectedIssueId ? controller.issueDetail.value : null;
|
|
3940
|
+
const issueRunTaskId = currentIssueDetail ? resolveIssueManagerIssueRunTaskId({
|
|
3941
|
+
latestRun: currentIssueDetail.latestRun ?? currentIssueDetail.recentRuns[0] ?? null,
|
|
3942
|
+
selectedIssue: currentIssueDetail.issue,
|
|
3943
|
+
tasks: currentIssueDetail.tasks
|
|
3944
|
+
}) : null;
|
|
3945
|
+
const visibleTasks = currentIssueDetail ? resolveIssueManagerVisibleSubtasks({
|
|
3946
|
+
hiddenIssueRunTaskId: issueRunTaskId,
|
|
3947
|
+
tasks: currentIssueDetail.tasks
|
|
3948
|
+
}) : [];
|
|
3949
|
+
const subtaskProgressByIssueId = resolveIssueManagerSubtaskProgressByIssueId({
|
|
3950
|
+
issueId: currentIssueDetail?.issue.issueId ?? null,
|
|
3951
|
+
visibleTasks: currentIssueDetail ? visibleTasks : null
|
|
3952
|
+
});
|
|
3867
3953
|
return /* @__PURE__ */ jsxs11(
|
|
3868
3954
|
"aside",
|
|
3869
3955
|
{
|
|
@@ -3919,6 +4005,7 @@ function IssueManagerSidebar({
|
|
|
3919
4005
|
isNarrowLayout,
|
|
3920
4006
|
selectedIssueId: controller.nodeState.selectedIssueId,
|
|
3921
4007
|
sidebarViewState,
|
|
4008
|
+
subtaskProgressByIssueId,
|
|
3922
4009
|
onRetry: () => controller.refreshAll(),
|
|
3923
4010
|
onSelectIssue: controller.selectIssue
|
|
3924
4011
|
}
|
|
@@ -5653,4 +5740,4 @@ export {
|
|
|
5653
5740
|
IssueManagerNode,
|
|
5654
5741
|
IssueManagerNodeHeader
|
|
5655
5742
|
};
|
|
5656
|
-
//# sourceMappingURL=chunk-
|
|
5743
|
+
//# sourceMappingURL=chunk-7KCCNQDW.js.map
|