@burdenoff/microfe-planmagnet 2026.930.12 → 2026.930.14

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.
Files changed (104) hide show
  1. package/dist/planmagnet/PlanMagnetRoot.d.ts.map +1 -1
  2. package/dist/planmagnet/PlanMagnetRoot.js +144 -128
  3. package/dist/planmagnet/PlanMagnetRoot.js.map +1 -1
  4. package/dist/planmagnet/PlanMagnetRoutes.d.ts.map +1 -1
  5. package/dist/planmagnet/PlanMagnetRoutes.js +231 -223
  6. package/dist/planmagnet/PlanMagnetRoutes.js.map +1 -1
  7. package/dist/planmagnet/activity/activityDescribe.d.ts +38 -0
  8. package/dist/planmagnet/activity/activityDescribe.d.ts.map +1 -0
  9. package/dist/planmagnet/activity/activityDescribe.js +123 -0
  10. package/dist/planmagnet/activity/activityDescribe.js.map +1 -0
  11. package/dist/planmagnet/activity/relativeTime.d.ts +8 -0
  12. package/dist/planmagnet/activity/relativeTime.d.ts.map +1 -0
  13. package/dist/planmagnet/activity/relativeTime.js +38 -0
  14. package/dist/planmagnet/activity/relativeTime.js.map +1 -0
  15. package/dist/planmagnet/admin/PlanMagnetAdminRoot.js +37 -37
  16. package/dist/planmagnet/automation/AutomationRuleFields.js +41 -41
  17. package/dist/planmagnet/board/BulkActions.js +6 -6
  18. package/dist/planmagnet/board/ProjectBoard.js +24 -24
  19. package/dist/planmagnet/budgets/BudgetControls.js +18 -18
  20. package/dist/planmagnet/comments/WorkItemActivity.d.ts.map +1 -1
  21. package/dist/planmagnet/comments/WorkItemActivity.js +35 -38
  22. package/dist/planmagnet/comments/WorkItemActivity.js.map +1 -1
  23. package/dist/planmagnet/controls/FeatureControls.js +46 -46
  24. package/dist/planmagnet/controls/ObjectiveControls.js +11 -11
  25. package/dist/planmagnet/controls/ProgramControls.js +9 -9
  26. package/dist/planmagnet/controls/ProjectControls.d.ts.map +1 -1
  27. package/dist/planmagnet/controls/ProjectControls.js +53 -46
  28. package/dist/planmagnet/controls/ProjectControls.js.map +1 -1
  29. package/dist/planmagnet/controls/WorkItemControls.js +27 -27
  30. package/dist/planmagnet/dependency/DependencyPanel.js +7 -7
  31. package/dist/planmagnet/pages/ActivityActivityPagePage.d.ts +2 -0
  32. package/dist/planmagnet/pages/ActivityActivityPagePage.d.ts.map +1 -0
  33. package/dist/planmagnet/pages/ActivityActivityPagePage.js +291 -0
  34. package/dist/planmagnet/pages/ActivityActivityPagePage.js.map +1 -0
  35. package/dist/planmagnet/pages/AiPlanPagePage.js +6 -6
  36. package/dist/planmagnet/pages/AnalyticsAnalyticsPagePage.d.ts.map +1 -1
  37. package/dist/planmagnet/pages/AnalyticsAnalyticsPagePage.js +370 -221
  38. package/dist/planmagnet/pages/AnalyticsAnalyticsPagePage.js.map +1 -1
  39. package/dist/planmagnet/pages/AutomationAutomationRulesPagePage.js +15 -15
  40. package/dist/planmagnet/pages/AutomationCreateAutomationRulePagePage.js +9 -9
  41. package/dist/planmagnet/pages/DashboardDashboardPagePage.d.ts.map +1 -1
  42. package/dist/planmagnet/pages/DashboardDashboardPagePage.js +140 -135
  43. package/dist/planmagnet/pages/DashboardDashboardPagePage.js.map +1 -1
  44. package/dist/planmagnet/pages/ProductsEditProductPagePage.js +4 -4
  45. package/dist/planmagnet/pages/ProductsEditRoadmapPagePage.js +4 -4
  46. package/dist/planmagnet/pages/ProductsProductDetailPagePage.js +4 -4
  47. package/dist/planmagnet/pages/ProductsRoadmapDetailPagePage.d.ts.map +1 -1
  48. package/dist/planmagnet/pages/ProductsRoadmapDetailPagePage.js +118 -109
  49. package/dist/planmagnet/pages/ProductsRoadmapDetailPagePage.js.map +1 -1
  50. package/dist/planmagnet/pages/ProgramsEditProgramPagePage.js +4 -4
  51. package/dist/planmagnet/pages/ProjectsBudgetDetailPagePage.d.ts.map +1 -1
  52. package/dist/planmagnet/pages/ProjectsBudgetDetailPagePage.js +160 -108
  53. package/dist/planmagnet/pages/ProjectsBudgetDetailPagePage.js.map +1 -1
  54. package/dist/planmagnet/pages/ProjectsBudgetsPagePage.js +10 -10
  55. package/dist/planmagnet/pages/ProjectsEditProjectPagePage.js +11 -11
  56. package/dist/planmagnet/pages/ProjectsMilestoneDetailPagePage.js +4 -4
  57. package/dist/planmagnet/pages/ProjectsPlanningDetailPagePage.js +4 -4
  58. package/dist/planmagnet/pages/ProjectsPlanningEditPagePage.js +6 -6
  59. package/dist/planmagnet/pages/ProjectsProjectDetailPagePage.js +13 -13
  60. package/dist/planmagnet/pages/ProjectsQualityGatesPagePage.js +4 -4
  61. package/dist/planmagnet/pages/ProjectsWorkflowPagePage.js +30 -30
  62. package/dist/planmagnet/pages/RisksRiskDetailPagePage.js +4 -4
  63. package/dist/planmagnet/pages/TasksMyDashboardPagePage.d.ts +2 -0
  64. package/dist/planmagnet/pages/TasksMyDashboardPagePage.d.ts.map +1 -0
  65. package/dist/planmagnet/pages/TasksMyDashboardPagePage.js +329 -0
  66. package/dist/planmagnet/pages/TasksMyDashboardPagePage.js.map +1 -0
  67. package/dist/planmagnet/pages/TasksTaskDetailPagePage.js +26 -26
  68. package/dist/planmagnet/pages/TeamCreateTeamPagePage.js +4 -4
  69. package/dist/planmagnet/pages/TeamTeamDetailPagePage.js +6 -6
  70. package/dist/planmagnet/pages/TeamTeamEditPagePage.js +6 -6
  71. package/dist/planmagnet/pages/analytics/DeliveryHealthCards.d.ts +14 -2
  72. package/dist/planmagnet/pages/analytics/DeliveryHealthCards.d.ts.map +1 -1
  73. package/dist/planmagnet/pages/analytics/DeliveryHealthCards.js +173 -113
  74. package/dist/planmagnet/pages/analytics/DeliveryHealthCards.js.map +1 -1
  75. package/dist/planmagnet/pages/analytics/DeliveryKpisCard.d.ts +8 -0
  76. package/dist/planmagnet/pages/analytics/DeliveryKpisCard.d.ts.map +1 -0
  77. package/dist/planmagnet/pages/analytics/DeliveryKpisCard.js +211 -0
  78. package/dist/planmagnet/pages/analytics/DeliveryKpisCard.js.map +1 -0
  79. package/dist/planmagnet/pages/analytics/QualityMetricsCard.d.ts +8 -0
  80. package/dist/planmagnet/pages/analytics/QualityMetricsCard.d.ts.map +1 -0
  81. package/dist/planmagnet/pages/analytics/QualityMetricsCard.js +177 -0
  82. package/dist/planmagnet/pages/analytics/QualityMetricsCard.js.map +1 -0
  83. package/dist/planmagnet/pages/analytics/ThroughputCard.d.ts +7 -0
  84. package/dist/planmagnet/pages/analytics/ThroughputCard.d.ts.map +1 -0
  85. package/dist/planmagnet/pages/analytics/ThroughputCard.js +137 -0
  86. package/dist/planmagnet/pages/analytics/ThroughputCard.js.map +1 -0
  87. package/dist/planmagnet/pages/analytics/analyticsRange.d.ts +42 -0
  88. package/dist/planmagnet/pages/analytics/analyticsRange.d.ts.map +1 -0
  89. package/dist/planmagnet/pages/analytics/analyticsRange.js +47 -0
  90. package/dist/planmagnet/pages/analytics/analyticsRange.js.map +1 -0
  91. package/dist/planmagnet/roadmaps/RoadmapControls.js +21 -21
  92. package/dist/planmagnet/roadmaps/RoadmapNowNextLater.d.ts +29 -0
  93. package/dist/planmagnet/roadmaps/RoadmapNowNextLater.d.ts.map +1 -1
  94. package/dist/planmagnet/roadmaps/RoadmapNowNextLater.js +1 -1
  95. package/dist/planmagnet/roadmaps/RoadmapNowNextLater.js.map +1 -1
  96. package/dist/planmagnet/roadmaps/RoadmapPresentation.d.ts +37 -0
  97. package/dist/planmagnet/roadmaps/RoadmapPresentation.d.ts.map +1 -0
  98. package/dist/planmagnet/roadmaps/RoadmapPresentation.js +210 -0
  99. package/dist/planmagnet/roadmaps/RoadmapPresentation.js.map +1 -0
  100. package/dist/planmagnet/team/TeamControls.d.ts.map +1 -1
  101. package/dist/planmagnet/team/TeamControls.js +134 -124
  102. package/dist/planmagnet/team/TeamControls.js.map +1 -1
  103. package/dist/planmagnet/time/TimeEntryControls.js +12 -12
  104. package/package.json +1 -1
@@ -2,8 +2,8 @@ import { usePlanMagnet as e, usePlanMagnetNavigate as t } from "../providers/Pla
2
2
  import { PersonName as n } from "../people/People.js";
3
3
  import { workProgress as r } from "../hooks/useCounts.js";
4
4
  import { enumLabel as i } from "../controls/WorkItemControls.js";
5
- import { useEntityId as a } from "../hooks/useEntityId.js";
6
- import { ROW_LINK_CLASS as o, detailPath as s, rowLinkProps as c } from "../utils/rowNavigation.js";
5
+ import { ROW_LINK_CLASS as a, detailPath as o, rowLinkProps as s } from "../utils/rowNavigation.js";
6
+ import { useEntityId as c } from "../hooks/useEntityId.js";
7
7
  import { NewRiskDialog as l, NewTemplateFromProjectDialog as u } from "../create/CreateDialogs.js";
8
8
  import { ProjectHeaderActions as d } from "../controls/ProjectControls.js";
9
9
  import { ProjectBudgetsSummary as f } from "../budgets/ProjectBudgetsSummary.js";
@@ -106,7 +106,7 @@ var N = C`
106
106
  "ACCEPTED"
107
107
  ]);
108
108
  function I() {
109
- let C = a("projectId"), I = t(), { workspaceId: L } = e(), { data: R, loading: z, error: B } = w(N, {
109
+ let C = c("projectId"), I = t(), { workspaceId: L } = e(), { data: R, loading: z, error: B } = w(N, {
110
110
  variables: { id: C },
111
111
  skip: !C
112
112
  });
@@ -194,7 +194,7 @@ function I() {
194
194
  /* @__PURE__ */ T(u, {
195
195
  projectId: V.id,
196
196
  projectName: V.name,
197
- onCreated: (e) => I(s("/templates/edit-template-page", e)),
197
+ onCreated: (e) => I(o("/templates/edit-template-page", e)),
198
198
  trigger: /* @__PURE__ */ E(O, {
199
199
  size: "sm",
200
200
  variant: "outline",
@@ -212,7 +212,7 @@ function I() {
212
212
  /* @__PURE__ */ E(O, {
213
213
  size: "sm",
214
214
  variant: "outline",
215
- onClick: () => I(s("/projects/critical-path-page", V.id)),
215
+ onClick: () => I(o("/projects/critical-path-page", V.id)),
216
216
  children: [/* @__PURE__ */ T(v, { className: "mr-1 h-4 w-4" }), "Critical path"]
217
217
  })
218
218
  ]
@@ -356,8 +356,8 @@ function I() {
356
356
  ] }) }), /* @__PURE__ */ E(A, {
357
357
  className: "space-y-2",
358
358
  children: [te.map((e) => /* @__PURE__ */ E("div", {
359
- ...c(() => I(`/tasks/task-detail-page?taskId=${encodeURIComponent(e.id)}`), e.key),
360
- className: `flex items-center justify-between border rounded-md p-2.5 ${o}`,
359
+ ...s(() => I(`/tasks/task-detail-page?taskId=${encodeURIComponent(e.id)}`), e.key),
360
+ className: `flex items-center justify-between border rounded-md p-2.5 ${a}`,
361
361
  children: [/* @__PURE__ */ E("div", { children: [/* @__PURE__ */ E("p", {
362
362
  className: "text-sm font-medium",
363
363
  children: [
@@ -437,12 +437,12 @@ function I() {
437
437
  children: [/* @__PURE__ */ T("button", {
438
438
  type: "button",
439
439
  className: "text-sm font-medium hover:underline text-left",
440
- onClick: () => I(s("/projects/planning-detail-page", e.sprint.id)),
440
+ onClick: () => I(o("/projects/planning-detail-page", e.sprint.id)),
441
441
  children: e.sprint.name
442
442
  }), /* @__PURE__ */ E("button", {
443
443
  type: "button",
444
444
  className: "block text-xs text-muted-foreground hover:underline",
445
- onClick: () => I(s("/team/team-detail-page", e.sprint.team.id)),
445
+ onClick: () => I(o("/team/team-detail-page", e.sprint.team.id)),
446
446
  children: [
447
447
  e.items.length,
448
448
  " item",
@@ -467,14 +467,14 @@ function I() {
467
467
  ]
468
468
  }), /* @__PURE__ */ T(l, {
469
469
  projectId: V.id,
470
- onCreated: (e) => I(s("/risks/risk-detail-page", e))
470
+ onCreated: (e) => I(o("/risks/risk-detail-page", e))
471
471
  })]
472
472
  }), /* @__PURE__ */ E(A, {
473
473
  className: "space-y-3",
474
474
  children: [
475
475
  q.map((e) => /* @__PURE__ */ E("div", {
476
- ...c(() => I(s("/risks/risk-detail-page", e.id)), e.title),
477
- className: `border-b pb-2 last:border-0 ${o}`,
476
+ ...s(() => I(o("/risks/risk-detail-page", e.id)), e.title),
477
+ className: `border-b pb-2 last:border-0 ${a}`,
478
478
  children: [/* @__PURE__ */ E("div", {
479
479
  className: "flex justify-between gap-2",
480
480
  children: [/* @__PURE__ */ T("span", {
@@ -548,7 +548,7 @@ function I() {
548
548
  }), V.program ? /* @__PURE__ */ T("button", {
549
549
  type: "button",
550
550
  className: "text-primary hover:underline underline-offset-2",
551
- onClick: () => I(s("/products/program-detail-page", V.program.id)),
551
+ onClick: () => I(o("/products/program-detail-page", V.program.id)),
552
552
  children: V.program.name
553
553
  }) : /* @__PURE__ */ T("span", {
554
554
  className: "text-muted-foreground",
@@ -1,7 +1,7 @@
1
1
  import { usePlanMagnet as e } from "../providers/PlanMagnetProvider.js";
2
2
  import { PersonName as t } from "../people/People.js";
3
- import { ProjectSelect as n } from "../controls/Pickers.js";
4
- import { enumLabel as r } from "../controls/WorkItemControls.js";
3
+ import { enumLabel as n } from "../controls/WorkItemControls.js";
4
+ import { ProjectSelect as r } from "../controls/Pickers.js";
5
5
  import { useReleaseOptions as i } from "../releases/useReleaseOptions.js";
6
6
  import { summarizeCriteria as a } from "../utils/qualityGateCriteria.js";
7
7
  import { EditQualityGateDialog as o, QUALITY_GATE_STATUSES as s, QualityGateDeleteButton as c, QualityGateStatusBadge as l, ReviewQualityGateDialog as u } from "../controls/QualityGateControls.js";
@@ -113,7 +113,7 @@ function j() {
113
113
  }), /* @__PURE__ */ x("div", {
114
114
  className: "w-48",
115
115
  "data-testid": "quality-gates-project-filter",
116
- children: /* @__PURE__ */ x(n, {
116
+ children: /* @__PURE__ */ x(r, {
117
117
  id: "quality-gates-filter-project",
118
118
  value: M,
119
119
  onChange: N,
@@ -131,7 +131,7 @@ function j() {
131
131
  "data-testid": `quality-gates-status-${e}`,
132
132
  onClick: () => F(e),
133
133
  className: `px-3 py-1.5 text-sm rounded-md ${P === e ? "bg-primary text-primary-foreground" : "text-muted-foreground hover:bg-muted"}`,
134
- children: e === "ALL" ? "All" : r(e)
134
+ children: e === "ALL" ? "All" : n(e)
135
135
  }, e))
136
136
  }),
137
137
  H && /* @__PURE__ */ S("p", {
@@ -1,7 +1,7 @@
1
1
  import { usePlanMagnetNavigate as e } from "../providers/PlanMagnetProvider.js";
2
- import { throwOnError as t } from "../utils/mutationResult.js";
3
- import { ErrorLine as n } from "../controls/ConfirmButton.js";
4
- import { PROJECT_WORKFLOW as r, canonicalLabel as i } from "../hooks/useProjectWorkflow.js";
2
+ import { PROJECT_WORKFLOW as t, canonicalLabel as n } from "../hooks/useProjectWorkflow.js";
3
+ import { throwOnError as r } from "../utils/mutationResult.js";
4
+ import { ErrorLine as i } from "../controls/ConfirmButton.js";
5
5
  import { useState as a } from "react";
6
6
  import { ArrowLeft as o, Loader2 as s } from "lucide-react";
7
7
  import { useParams as c } from "react-router";
@@ -42,17 +42,17 @@ var b = l`
42
42
  "CANCELLED"
43
43
  ], C = new Set(["DONE", "CANCELLED"]);
44
44
  function w() {
45
- let t = e(), i = c().id ?? "", { data: a, loading: l, error: u } = d(r, {
46
- variables: { projectId: i },
47
- skip: !i
45
+ let n = e(), r = c().id ?? "", { data: a, loading: l, error: u } = d(t, {
46
+ variables: { projectId: r },
47
+ skip: !r
48
48
  }), { data: h } = d(x, {
49
- variables: { id: i },
50
- skip: !i
49
+ variables: { id: r },
50
+ skip: !r
51
51
  });
52
52
  return l && !a ? /* @__PURE__ */ f("div", {
53
53
  className: "flex items-center justify-center p-12",
54
54
  children: /* @__PURE__ */ f(s, { className: "h-8 w-8 animate-spin text-muted-foreground" })
55
- }) : u || !a ? /* @__PURE__ */ f(n, { message: u?.message ?? "This project was not found." }) : /* @__PURE__ */ p("div", {
55
+ }) : u || !a ? /* @__PURE__ */ f(i, { message: u?.message ?? "This project was not found." }) : /* @__PURE__ */ p("div", {
56
56
  className: "space-y-6 p-6",
57
57
  children: [/* @__PURE__ */ p("div", {
58
58
  className: "flex items-start gap-3",
@@ -60,7 +60,7 @@ function w() {
60
60
  variant: "ghost",
61
61
  size: "icon",
62
62
  "aria-label": "Back to the project",
63
- onClick: () => t(`/projects/project-detail-page/${i}`),
63
+ onClick: () => n(`/projects/project-detail-page/${r}`),
64
64
  children: /* @__PURE__ */ f(o, { className: "h-4 w-4" })
65
65
  }), /* @__PURE__ */ p("div", { children: [/* @__PURE__ */ p("h1", {
66
66
  className: "text-2xl font-semibold",
@@ -73,23 +73,23 @@ function w() {
73
73
  });
74
74
  }
75
75
  function T({ workflow: e }) {
76
- let [r, o] = a(e.statuses), [s, c] = a(e.enforceTransitions), [l, d] = a(new Set(e.transitions.map((e) => `${e.from}>${e.to}`))), [x, w] = a(null), [T, E] = a(!1), [D, O] = u(b, {
76
+ let [t, o] = a(e.statuses), [s, c] = a(e.enforceTransitions), [l, d] = a(new Set(e.transitions.map((e) => `${e.from}>${e.to}`))), [x, w] = a(null), [T, E] = a(!1), [D, O] = u(b, {
77
77
  refetchQueries: [
78
78
  "ProjectWorkflow",
79
79
  "ProjectBoard",
80
80
  "GetWorkItemDetail"
81
81
  ],
82
82
  awaitRefetchQueries: !0
83
- }), k = r.filter((e) => !e.hidden), A = (e, t) => {
84
- E(!1), o(r.map((n) => n.status === e ? {
85
- ...n,
86
- ...t
87
- } : n));
83
+ }), k = t.filter((e) => !e.hidden), A = (e, n) => {
84
+ E(!1), o(t.map((t) => t.status === e ? {
85
+ ...t,
86
+ ...n
87
+ } : t));
88
88
  }, j = (e, t) => {
89
89
  E(!1);
90
90
  let n = `${e}>${t}`, r = new Set(l);
91
91
  r.has(n) ? r.delete(n) : r.add(n), d(r);
92
- }, M = r.map((e) => e.label.trim().toLowerCase()), N = M.some((e, t) => e !== "" && M.indexOf(e) !== t), P = r.some((e) => e.label.trim() === ""), F = new Set(r.filter((e) => e.hidden).map((e) => e.status)), I = [...l].map((e) => {
92
+ }, M = t.map((e) => e.label.trim().toLowerCase()), N = M.some((e, t) => e !== "" && M.indexOf(e) !== t), P = t.some((e) => e.label.trim() === ""), F = new Set(t.filter((e) => e.hidden).map((e) => e.status)), I = [...l].map((e) => {
93
93
  let [t, n] = e.split(">");
94
94
  return {
95
95
  from: t,
@@ -98,11 +98,11 @@ function T({ workflow: e }) {
98
98
  }).filter((e) => !F.has(e.to)), L = N || P || s && I.length === 0, R = async () => {
99
99
  w(null), E(!1);
100
100
  try {
101
- await t(D({ variables: {
101
+ await r(D({ variables: {
102
102
  projectId: e.projectId,
103
103
  input: {
104
104
  enforceTransitions: s,
105
- statuses: r.map((e) => ({
105
+ statuses: t.map((e) => ({
106
106
  status: e.status,
107
107
  label: e.label.trim(),
108
108
  hidden: e.hidden,
@@ -142,17 +142,17 @@ function T({ workflow: e }) {
142
142
  children: "Hidden"
143
143
  })
144
144
  ]
145
- }) }), /* @__PURE__ */ f("tbody", { children: r.map((e) => /* @__PURE__ */ p("tr", {
145
+ }) }), /* @__PURE__ */ f("tbody", { children: t.map((e) => /* @__PURE__ */ p("tr", {
146
146
  className: "border-t",
147
147
  children: [
148
148
  /* @__PURE__ */ f("td", {
149
149
  className: "py-2 pr-3 text-muted-foreground",
150
- children: i(e.status)
150
+ children: n(e.status)
151
151
  }),
152
152
  /* @__PURE__ */ f("td", {
153
153
  className: "py-2 pr-3",
154
154
  children: /* @__PURE__ */ f(y, {
155
- "aria-label": `Name for ${i(e.status)}`,
155
+ "aria-label": `Name for ${n(e.status)}`,
156
156
  maxLength: 40,
157
157
  value: e.label,
158
158
  onChange: (t) => A(e.status, { label: t.target.value })
@@ -161,7 +161,7 @@ function T({ workflow: e }) {
161
161
  /* @__PURE__ */ f("td", {
162
162
  className: "py-2 pr-3",
163
163
  children: /* @__PURE__ */ f("select", {
164
- "aria-label": `Category for ${i(e.status)}`,
164
+ "aria-label": `Category for ${n(e.status)}`,
165
165
  className: "rounded-md border border-input bg-background px-2 py-1 text-sm disabled:opacity-60",
166
166
  value: e.category,
167
167
  disabled: C.has(e.status),
@@ -169,7 +169,7 @@ function T({ workflow: e }) {
169
169
  onChange: (t) => A(e.status, { category: t.target.value }),
170
170
  children: S.filter((t) => C.has(e.status) || !C.has(t)).map((e) => /* @__PURE__ */ f("option", {
171
171
  value: e,
172
- children: i(e)
172
+ children: n(e)
173
173
  }, e))
174
174
  })
175
175
  }),
@@ -177,7 +177,7 @@ function T({ workflow: e }) {
177
177
  className: "py-2",
178
178
  children: /* @__PURE__ */ f("input", {
179
179
  type: "checkbox",
180
- "aria-label": `Hide ${i(e.status)}`,
180
+ "aria-label": `Hide ${n(e.status)}`,
181
181
  checked: e.hidden,
182
182
  disabled: e.status === "DONE",
183
183
  title: e.status === "DONE" ? "Done cannot be hidden" : void 0,
@@ -191,8 +191,8 @@ function T({ workflow: e }) {
191
191
  className: "mt-2 text-xs text-muted-foreground",
192
192
  children: "A hidden status cannot be chosen for new work; items already in it stay visible until they move."
193
193
  }),
194
- P && /* @__PURE__ */ f(n, { message: "Every status needs a name." }),
195
- N && /* @__PURE__ */ f(n, { message: "Two statuses cannot share a name." })
194
+ P && /* @__PURE__ */ f(i, { message: "Every status needs a name." }),
195
+ N && /* @__PURE__ */ f(i, { message: "Two statuses cannot share a name." })
196
196
  ] })] }),
197
197
  /* @__PURE__ */ p(h, { children: [/* @__PURE__ */ f(_, { children: /* @__PURE__ */ f(v, { children: "Allowed moves" }) }), /* @__PURE__ */ p(g, {
198
198
  className: "space-y-3",
@@ -217,7 +217,7 @@ function T({ workflow: e }) {
217
217
  }), k.map((e) => /* @__PURE__ */ f("th", {
218
218
  className: "px-2 py-1 font-medium",
219
219
  children: e.label
220
- }, e.status))] }) }), /* @__PURE__ */ f("tbody", { children: r.map((e) => /* @__PURE__ */ p("tr", {
220
+ }, e.status))] }) }), /* @__PURE__ */ f("tbody", { children: t.map((e) => /* @__PURE__ */ p("tr", {
221
221
  className: "border-t",
222
222
  children: [/* @__PURE__ */ f("td", {
223
223
  className: "py-1 pr-3",
@@ -235,7 +235,7 @@ function T({ workflow: e }) {
235
235
  })
236
236
  }, t.status))]
237
237
  }, e.status)) })]
238
- }), I.length === 0 && /* @__PURE__ */ f(n, { message: "Tick at least one move, or stop enforcing." })]
238
+ }), I.length === 0 && /* @__PURE__ */ f(i, { message: "Tick at least one move, or stop enforcing." })]
239
239
  })]
240
240
  })] }),
241
241
  /* @__PURE__ */ p("div", {
@@ -251,7 +251,7 @@ function T({ workflow: e }) {
251
251
  children: "Saved."
252
252
  })]
253
253
  }),
254
- x && /* @__PURE__ */ f(n, { message: x })
254
+ x && /* @__PURE__ */ f(i, { message: x })
255
255
  ]
256
256
  });
257
257
  }
@@ -1,8 +1,8 @@
1
1
  import { usePlanMagnetNavigate as e } from "../providers/PlanMagnetProvider.js";
2
2
  import { PersonName as t } from "../people/People.js";
3
3
  import { enumLabel as n } from "../controls/WorkItemControls.js";
4
- import { useEntityId as r } from "../hooks/useEntityId.js";
5
- import { detailPath as i } from "../utils/rowNavigation.js";
4
+ import { detailPath as r } from "../utils/rowNavigation.js";
5
+ import { useEntityId as i } from "../hooks/useEntityId.js";
6
6
  import { RiskHeaderActions as a } from "../controls/RiskControls.js";
7
7
  import { Calendar as o, FolderKanban as s, Gauge as c, ShieldAlert as l, User as u } from "lucide-react";
8
8
  import { gql as d } from "@apollo/client";
@@ -45,7 +45,7 @@ var b = d`
45
45
  NEGLIGIBLE: "bg-gray-100 text-gray-800"
46
46
  }, S = 12;
47
47
  function C() {
48
- let d = r(), C = e(), { data: w, loading: T, error: E } = f(b, {
48
+ let d = i(), C = e(), { data: w, loading: T, error: E } = f(b, {
49
49
  variables: { id: d },
50
50
  skip: !d
51
51
  });
@@ -186,7 +186,7 @@ function C() {
186
186
  D.project ? /* @__PURE__ */ p("button", {
187
187
  type: "button",
188
188
  className: "font-medium text-primary hover:underline",
189
- onClick: () => C(i("/projects/project-detail-page", D.project?.id)),
189
+ onClick: () => C(r("/projects/project-detail-page", D.project?.id)),
190
190
  children: D.project.name
191
191
  }) : /* @__PURE__ */ p("span", {
192
192
  className: "text-muted-foreground",
@@ -0,0 +1,2 @@
1
+ export declare function TasksMyDashboardPagePage(): import("react/jsx-runtime").JSX.Element;
2
+ //# sourceMappingURL=TasksMyDashboardPagePage.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"TasksMyDashboardPagePage.d.ts","sourceRoot":"","sources":["../../../src/planmagnet/pages/TasksMyDashboardPagePage.tsx"],"names":[],"mappings":"AAsbA,wBAAgB,wBAAwB,4CAuCvC"}
@@ -0,0 +1,329 @@
1
+ import { CombinedGraphQLErrors as e } from "../../node_modules/@apollo/client/errors/CombinedGraphQLErrors.js";
2
+ import { ServerError as t } from "../../node_modules/@apollo/client/errors/ServerError.js";
3
+ import { usePlanMagnet as n, usePlanMagnetNavigate as r } from "../providers/PlanMagnetProvider.js";
4
+ import { Legend as i } from "../../node_modules/recharts/es6/component/Legend.js";
5
+ import { Tooltip as a } from "../../node_modules/recharts/es6/component/Tooltip.js";
6
+ import { ResponsiveContainer as o } from "../../node_modules/recharts/es6/component/ResponsiveContainer.js";
7
+ import { Bar as s } from "../../node_modules/recharts/es6/cartesian/Bar.js";
8
+ import { CartesianGrid as c } from "../../node_modules/recharts/es6/cartesian/CartesianGrid.js";
9
+ import { XAxis as l } from "../../node_modules/recharts/es6/cartesian/XAxis.js";
10
+ import { YAxis as u } from "../../node_modules/recharts/es6/cartesian/YAxis.js";
11
+ import { BarChart as d } from "../../node_modules/recharts/es6/chart/BarChart.js";
12
+ import { StatTile as f } from "./analytics/DeliveryHealthCards.js";
13
+ import { enumLabel as p } from "../controls/WorkItemControls.js";
14
+ import { RANGE_PRESETS as m, activePreset as h, presetRange as g, toRangeVariables as _ } from "./analytics/analyticsRange.js";
15
+ import { useState as v } from "react";
16
+ import { ArrowRight as y, Clock as b, Flag as x, LayoutDashboard as S, TrendingUp as C } from "lucide-react";
17
+ import { gql as w } from "@apollo/client";
18
+ import { useQuery as T } from "@apollo/client/react";
19
+ import { Fragment as E, jsx as D, jsxs as O } from "react/jsx-runtime";
20
+ import { useI18n as k } from "@burdenoff/fe-libs/shared/providers/shell/I18nProvider";
21
+ import { Badge as A, Button as j, Card as M, CardContent as N, CardHeader as P, CardTitle as F } from "@burdenoff/fe-libs/ui";
22
+ //#region src/planmagnet/pages/TasksMyDashboardPagePage.tsx
23
+ var I = w`
24
+ query GetMyTimeAllocation($workspaceId: ID!, $startDate: DateTime, $endDate: DateTime) {
25
+ planmagnetMyTimeAllocation(
26
+ workspaceId: $workspaceId
27
+ startDate: $startDate
28
+ endDate: $endDate
29
+ ) {
30
+ totalHours
31
+ byProject {
32
+ projectId
33
+ projectName
34
+ hours
35
+ }
36
+ byWorkItemType {
37
+ type
38
+ hours
39
+ }
40
+ }
41
+ }
42
+ `, L = w`
43
+ query GetMyDeliveryTrend($workspaceId: ID!, $weeks: Int) {
44
+ planmagnetMyDeliveryTrend(workspaceId: $workspaceId, weeks: $weeks) {
45
+ weekStart
46
+ itemsCompleted
47
+ pointsCompleted
48
+ }
49
+ }
50
+ `, R = w`
51
+ query GetMyObjectives($workspaceId: ID!, $filter: PlanmagnetObjectiveFilter) {
52
+ planmagnetObjectives(workspaceId: $workspaceId, filter: $filter, pagination: { first: 50 }) {
53
+ items {
54
+ id
55
+ title
56
+ status
57
+ progress
58
+ periodLabel
59
+ }
60
+ totalCount
61
+ }
62
+ }
63
+ `, z = 8;
64
+ function B(n) {
65
+ return e.is(n) ? n.errors.some((e) => e.extensions?.code === "FORBIDDEN") : t.is(n) ? n.statusCode === 403 || /"code"\s*:\s*"FORBIDDEN"/.test(n.bodyText) : !1;
66
+ }
67
+ function V(e) {
68
+ let t = new Date(e);
69
+ return `${t.getUTCMonth() + 1}/${t.getUTCDate()}`;
70
+ }
71
+ function H({ progress: e }) {
72
+ return /* @__PURE__ */ D("div", {
73
+ className: "h-1.5 w-full rounded-full bg-muted overflow-hidden",
74
+ children: /* @__PURE__ */ D("div", {
75
+ className: "h-full rounded-full bg-primary",
76
+ style: { width: `${Math.max(0, Math.min(100, Math.round(e)))}%` }
77
+ })
78
+ });
79
+ }
80
+ function U({ workspaceId: e, range: t, onRangeChange: n }) {
81
+ let { t: r } = k(), { startDate: i, endDate: a } = _(t), { data: o, loading: s, error: c } = T(I, {
82
+ variables: {
83
+ workspaceId: e,
84
+ startDate: i,
85
+ endDate: a
86
+ },
87
+ skip: !e
88
+ }), l = o?.planmagnetMyTimeAllocation, u = h(t);
89
+ return /* @__PURE__ */ O(M, {
90
+ "data-testid": "my-time-allocation",
91
+ children: [/* @__PURE__ */ D(P, { children: /* @__PURE__ */ O("div", {
92
+ className: "flex flex-wrap items-center justify-between gap-2",
93
+ children: [/* @__PURE__ */ O(F, {
94
+ className: "flex items-center gap-2",
95
+ children: [/* @__PURE__ */ D(b, { className: "h-4 w-4" }), r("planmagnet.myDashboard.timeAllocation.title", "My time allocation")]
96
+ }), /* @__PURE__ */ D("div", {
97
+ className: "flex items-center gap-1 rounded-md border p-0.5",
98
+ role: "group",
99
+ "aria-label": r("planmagnet.myDashboard.timeAllocation.rangeLabel", "Date range"),
100
+ children: m.map((e) => /* @__PURE__ */ D("button", {
101
+ type: "button",
102
+ "aria-pressed": u === e,
103
+ onClick: () => n(e),
104
+ className: `px-2 py-1 text-xs rounded ${u === e ? "bg-primary text-primary-foreground" : "text-muted-foreground hover:bg-muted"}`,
105
+ children: r("planmagnet.myDashboard.timeAllocation.last", "Last {{days}}d", { days: e })
106
+ }, e))
107
+ })]
108
+ }) }), /* @__PURE__ */ D(N, { children: s ? /* @__PURE__ */ D("p", {
109
+ className: "text-sm text-muted-foreground",
110
+ children: r("planmagnet.myDashboard.loading", "Loading…")
111
+ }) : c ? /* @__PURE__ */ D("p", {
112
+ className: "text-sm text-muted-foreground",
113
+ children: B(c) ? r("planmagnet.myDashboard.timeAllocation.forbidden", "You don't have access to time-tracking data in this workspace.") : r("planmagnet.myDashboard.timeAllocation.error", "Time allocation could not be loaded: {{message}}", { message: c.message })
114
+ }) : !l || l.totalHours === 0 ? /* @__PURE__ */ D("p", {
115
+ className: "text-sm text-muted-foreground",
116
+ children: r("planmagnet.myDashboard.timeAllocation.empty", "No time logged against a project or task in this range.")
117
+ }) : /* @__PURE__ */ O("div", {
118
+ className: "grid grid-cols-1 gap-4 sm:grid-cols-2",
119
+ children: [/* @__PURE__ */ O("div", { children: [
120
+ /* @__PURE__ */ D(f, {
121
+ label: r("planmagnet.myDashboard.timeAllocation.total", "Total logged"),
122
+ value: `${l.totalHours.toFixed(1)} h`
123
+ }),
124
+ /* @__PURE__ */ D("h4", {
125
+ className: "mt-3 text-xs font-medium text-muted-foreground",
126
+ children: r("planmagnet.myDashboard.timeAllocation.byProject", "By project")
127
+ }),
128
+ /* @__PURE__ */ D("ul", {
129
+ className: "mt-1 space-y-1",
130
+ children: [...l.byProject].sort((e, t) => t.hours - e.hours).map((e) => /* @__PURE__ */ O("li", {
131
+ className: "flex items-center justify-between text-sm",
132
+ children: [/* @__PURE__ */ D("span", {
133
+ className: "truncate",
134
+ children: e.projectName
135
+ }), /* @__PURE__ */ O("span", {
136
+ className: "tabular-nums text-muted-foreground",
137
+ children: [e.hours.toFixed(1), " h"]
138
+ })]
139
+ }, e.projectId))
140
+ })
141
+ ] }), /* @__PURE__ */ O("div", { children: [/* @__PURE__ */ D("h4", {
142
+ className: "text-xs font-medium text-muted-foreground",
143
+ children: r("planmagnet.myDashboard.timeAllocation.byType", "By work item type")
144
+ }), /* @__PURE__ */ D("ul", {
145
+ className: "mt-1 space-y-1",
146
+ children: [...l.byWorkItemType].sort((e, t) => t.hours - e.hours).map((e) => /* @__PURE__ */ O("li", {
147
+ className: "flex items-center justify-between text-sm",
148
+ children: [/* @__PURE__ */ D("span", { children: e.type ? p(e.type) : r("planmagnet.myDashboard.timeAllocation.noWorkItem", "No work item") }), /* @__PURE__ */ O("span", {
149
+ className: "tabular-nums text-muted-foreground",
150
+ children: [e.hours.toFixed(1), " h"]
151
+ })]
152
+ }, e.type ?? "none"))
153
+ })] })]
154
+ }) })]
155
+ });
156
+ }
157
+ function W({ workspaceId: e }) {
158
+ let { t } = k(), { data: n, loading: r, error: f } = T(L, {
159
+ variables: {
160
+ workspaceId: e,
161
+ weeks: z
162
+ },
163
+ skip: !e
164
+ }), p = n?.planmagnetMyDeliveryTrend ?? [], m = p.map((e) => ({
165
+ week: V(e.weekStart),
166
+ items: e.itemsCompleted,
167
+ points: e.pointsCompleted
168
+ })), h = p.reduce((e, t) => e + t.itemsCompleted, 0), g = p.reduce((e, t) => e + t.pointsCompleted, 0);
169
+ return /* @__PURE__ */ O(M, {
170
+ "data-testid": "my-delivery-trend",
171
+ children: [/* @__PURE__ */ O(P, { children: [/* @__PURE__ */ O(F, {
172
+ className: "flex items-center gap-2",
173
+ children: [/* @__PURE__ */ D(C, { className: "h-4 w-4" }), t("planmagnet.myDashboard.deliveryTrend.title", "My delivery trend")]
174
+ }), /* @__PURE__ */ D("p", {
175
+ className: "text-xs text-muted-foreground",
176
+ children: t("planmagnet.myDashboard.deliveryTrend.subtitle", "Items and points assigned to you that reached Done, last {{weeks}} weeks.", { weeks: z })
177
+ })] }), /* @__PURE__ */ D(N, { children: r ? /* @__PURE__ */ D("p", {
178
+ className: "text-sm text-muted-foreground",
179
+ children: t("planmagnet.myDashboard.loading", "Loading…")
180
+ }) : f ? /* @__PURE__ */ D("p", {
181
+ className: "text-sm text-muted-foreground",
182
+ children: t("planmagnet.myDashboard.deliveryTrend.error", "Delivery trend could not be loaded: {{message}}", { message: f.message })
183
+ }) : h === 0 ? /* @__PURE__ */ D("p", {
184
+ className: "text-sm text-muted-foreground",
185
+ children: t("planmagnet.myDashboard.deliveryTrend.empty", "Nothing assigned to you reached Done in the last {{weeks}} weeks.", { weeks: z })
186
+ }) : /* @__PURE__ */ O(E, { children: [/* @__PURE__ */ D("p", {
187
+ className: "text-xs text-muted-foreground mb-2",
188
+ children: t("planmagnet.myDashboard.deliveryTrend.summary", "{{items}} item(s), {{points}} point(s) completed across {{weeks}} week(s).", {
189
+ items: h,
190
+ points: g,
191
+ weeks: m.length
192
+ })
193
+ }), /* @__PURE__ */ D(o, {
194
+ width: "100%",
195
+ height: 200,
196
+ children: /* @__PURE__ */ O(d, {
197
+ data: m,
198
+ children: [
199
+ /* @__PURE__ */ D(c, {
200
+ strokeDasharray: "3 3",
201
+ opacity: .2
202
+ }),
203
+ /* @__PURE__ */ D(l, {
204
+ dataKey: "week",
205
+ tick: { fontSize: 11 }
206
+ }),
207
+ /* @__PURE__ */ D(u, {
208
+ tick: { fontSize: 11 },
209
+ allowDecimals: !1
210
+ }),
211
+ /* @__PURE__ */ D(a, {}),
212
+ /* @__PURE__ */ D(i, { wrapperStyle: { fontSize: 12 } }),
213
+ /* @__PURE__ */ D(s, {
214
+ dataKey: "items",
215
+ name: t("planmagnet.myDashboard.deliveryTrend.items", "Items"),
216
+ fill: "var(--color-chart-1)"
217
+ }),
218
+ /* @__PURE__ */ D(s, {
219
+ dataKey: "points",
220
+ name: t("planmagnet.myDashboard.deliveryTrend.points", "Points"),
221
+ fill: "var(--color-chart-3)"
222
+ })
223
+ ]
224
+ })
225
+ })] }) })]
226
+ });
227
+ }
228
+ function G({ workspaceId: e, ownerId: t }) {
229
+ let { t: n } = k(), i = r(), { data: a, loading: o, error: s } = T(R, {
230
+ variables: {
231
+ workspaceId: e,
232
+ filter: t ? { ownerId: t } : void 0
233
+ },
234
+ skip: !e || !t
235
+ }), c = a?.planmagnetObjectives.items ?? [];
236
+ return /* @__PURE__ */ O(M, {
237
+ "data-testid": "my-goals",
238
+ children: [/* @__PURE__ */ O(P, { children: [/* @__PURE__ */ O(F, {
239
+ className: "flex items-center gap-2",
240
+ children: [/* @__PURE__ */ D(x, { className: "h-4 w-4" }), n("planmagnet.myDashboard.goals.title", "My goals")]
241
+ }), /* @__PURE__ */ D("p", {
242
+ className: "text-xs text-muted-foreground",
243
+ children: n("planmagnet.myDashboard.goals.subtitle", "Objectives you own, with their progress.")
244
+ })] }), /* @__PURE__ */ D(N, { children: t ? o ? /* @__PURE__ */ D("p", {
245
+ className: "text-sm text-muted-foreground",
246
+ children: n("planmagnet.myDashboard.loading", "Loading…")
247
+ }) : s ? /* @__PURE__ */ D("p", {
248
+ className: "text-sm text-muted-foreground",
249
+ children: n("planmagnet.myDashboard.goals.error", "Goals could not be loaded: {{message}}", { message: s.message })
250
+ }) : c.length === 0 ? /* @__PURE__ */ D("p", {
251
+ className: "text-sm text-muted-foreground",
252
+ children: n("planmagnet.myDashboard.goals.empty", "You do not own any objective yet.")
253
+ }) : /* @__PURE__ */ D("ul", {
254
+ className: "space-y-3",
255
+ children: c.map((e) => /* @__PURE__ */ D("li", { children: /* @__PURE__ */ O("button", {
256
+ type: "button",
257
+ className: "w-full text-left rounded-md border p-2 hover:border-primary transition-colors",
258
+ onClick: () => i(`/goals/objective-detail-page?objectiveId=${encodeURIComponent(e.id)}`),
259
+ children: [
260
+ /* @__PURE__ */ O("div", {
261
+ className: "flex items-center justify-between gap-2",
262
+ children: [/* @__PURE__ */ D("span", {
263
+ className: "text-sm font-medium truncate",
264
+ children: e.title
265
+ }), /* @__PURE__ */ D(A, {
266
+ variant: "outline",
267
+ className: "text-xs capitalize shrink-0",
268
+ children: e.status.toLowerCase()
269
+ })]
270
+ }),
271
+ /* @__PURE__ */ D("p", {
272
+ className: "text-xs text-muted-foreground mt-0.5",
273
+ children: e.periodLabel
274
+ }),
275
+ /* @__PURE__ */ O("div", {
276
+ className: "mt-1.5 flex items-center gap-2",
277
+ children: [/* @__PURE__ */ D(H, { progress: e.progress }), /* @__PURE__ */ O("span", {
278
+ className: "text-xs tabular-nums text-muted-foreground shrink-0",
279
+ children: [Math.round(e.progress), "%"]
280
+ })]
281
+ })
282
+ ]
283
+ }) }, e.id))
284
+ }) : /* @__PURE__ */ D("p", {
285
+ className: "text-sm text-muted-foreground",
286
+ children: n("planmagnet.myDashboard.goals.noIdentity", "Sign in to see your goals.")
287
+ }) })]
288
+ });
289
+ }
290
+ function K() {
291
+ let { workspaceId: e, currentUser: t } = n(), i = r(), { t: a } = k(), [o, s] = v(() => g("30"));
292
+ return /* @__PURE__ */ O("div", {
293
+ className: "space-y-6 p-6",
294
+ "data-testid": "my-dashboard-page",
295
+ children: [
296
+ /* @__PURE__ */ O("div", {
297
+ className: "flex flex-wrap items-center justify-between gap-3",
298
+ children: [/* @__PURE__ */ O("div", { children: [/* @__PURE__ */ O("h1", {
299
+ className: "text-2xl font-semibold flex items-center gap-2",
300
+ children: [/* @__PURE__ */ D(S, { className: "h-6 w-6" }), a("planmagnet.myDashboard.title", "My dashboard")]
301
+ }), /* @__PURE__ */ D("p", {
302
+ className: "text-sm text-muted-foreground",
303
+ children: a("planmagnet.myDashboard.subtitle", "Your own time, delivery, and goals across every project.")
304
+ })] }), /* @__PURE__ */ O(j, {
305
+ variant: "outline",
306
+ size: "sm",
307
+ onClick: () => i("/tasks/my-work-page"),
308
+ children: [a("planmagnet.myDashboard.myWorkLink", "Go to My Work"), /* @__PURE__ */ D(y, { className: "ml-1 h-4 w-4" })]
309
+ })]
310
+ }),
311
+ /* @__PURE__ */ D(U, {
312
+ workspaceId: e,
313
+ range: o,
314
+ onRangeChange: (e) => s(g(e))
315
+ }),
316
+ /* @__PURE__ */ O("div", {
317
+ className: "grid grid-cols-1 gap-6 lg:grid-cols-2",
318
+ children: [/* @__PURE__ */ D(W, { workspaceId: e }), /* @__PURE__ */ D(G, {
319
+ workspaceId: e,
320
+ ownerId: t?.id
321
+ })]
322
+ })
323
+ ]
324
+ });
325
+ }
326
+ //#endregion
327
+ export { K as TasksMyDashboardPagePage };
328
+
329
+ //# sourceMappingURL=TasksMyDashboardPagePage.js.map