@parallelworks/tandem-web 0.171.1 → 0.171.3

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 (171) hide show
  1. package/_virtual/_virtual_i18n/en/common.js +5 -2
  2. package/_virtual/_virtual_i18n/es/common.js +5 -2
  3. package/_virtual/_virtual_i18n/ja/common.js +5 -2
  4. package/_virtual/_virtual_i18n/ko/common.js +5 -2
  5. package/_virtual/_virtual_i18n/zh/common.js +5 -2
  6. package/components/AccessGrants.js +6 -6
  7. package/components/ActivityTimeline.js +60 -60
  8. package/components/ActorAvatar.js +4 -4
  9. package/components/ActorLink.js +34 -0
  10. package/components/AgentWork.js +494 -494
  11. package/components/AppLauncher.js +7 -7
  12. package/components/AreaLink.js +13 -13
  13. package/components/AreaTiles.js +13 -13
  14. package/components/AreaWork.js +22 -22
  15. package/components/Attachments.js +73 -69
  16. package/components/BlockHandle.js +3 -3
  17. package/components/BugRotation.js +8 -8
  18. package/components/CodeHostSettings.js +121 -87
  19. package/components/CollabEditor.js +13 -13
  20. package/components/CommandPalette.js +206 -206
  21. package/components/CustomFields.js +95 -95
  22. package/components/CustomerRequests.js +11 -11
  23. package/components/DashboardPanel.js +201 -164
  24. package/components/DateChip.js +21 -21
  25. package/components/DocHistory.js +14 -14
  26. package/components/DocIcon.js +4 -4
  27. package/components/DocIconPicker.js +4 -4
  28. package/components/DocLinkPicker.js +22 -22
  29. package/components/DocLook.js +16 -16
  30. package/components/DocProperties.js +81 -81
  31. package/components/DocTable.js +53 -53
  32. package/components/DocsTree.js +179 -179
  33. package/components/Editor.js +69 -69
  34. package/components/FavoritesNav.js +78 -78
  35. package/components/GitHub.js +87 -87
  36. package/components/Graph.js +14 -14
  37. package/components/HostActions.js +21 -21
  38. package/components/HostPanel.js +6 -6
  39. package/components/HoverCards.js +74 -74
  40. package/components/IssueBoard.js +13 -10
  41. package/components/IssueBreakdown.js +31 -31
  42. package/components/IssueCode.js +19 -19
  43. package/components/IssueEvent.js +97 -92
  44. package/components/IssueFilters.js +39 -39
  45. package/components/IssueGroup.js +16 -16
  46. package/components/IssueImport.js +13 -13
  47. package/components/IssueInsights.js +20 -20
  48. package/components/IssueListBlock.js +81 -81
  49. package/components/IssueRelations.js +34 -34
  50. package/components/IssueRow.js +31 -31
  51. package/components/IssueSentry.js +36 -34
  52. package/components/IssueTemplates.js +23 -23
  53. package/components/IssueTypes.js +40 -40
  54. package/components/MarkdownTransfer.js +10 -10
  55. package/components/MentionPicker.js +19 -19
  56. package/components/NewIssueDialog.js +53 -53
  57. package/components/NewProjectDialog.js +82 -82
  58. package/components/PersonActivity.js +13 -13
  59. package/components/PersonHoverCard.js +44 -44
  60. package/components/Planning.js +16 -16
  61. package/components/Reports.js +8 -8
  62. package/components/SettingsNav.js +15 -15
  63. package/components/ShareDialog.js +8 -8
  64. package/components/SharedViewer.js +23 -23
  65. package/components/SlashMenu.js +26 -26
  66. package/components/SubPages.js +10 -10
  67. package/components/TeamForm.js +9 -9
  68. package/components/TeamRepositories.js +21 -21
  69. package/components/TeamWorkflow.js +6 -6
  70. package/components/UnlinkedMentions.js +29 -29
  71. package/components/Updates.js +8 -8
  72. package/components/Widgets.js +99 -97
  73. package/components/WorkCounts.js +12 -12
  74. package/components/cycleCrumb.js +8 -8
  75. package/components/editorPlugins.js +101 -101
  76. package/components/settings.js +6 -6
  77. package/components/video.js +7 -7
  78. package/hostedApp.js +24 -24
  79. package/index.js +18 -18
  80. package/lib/assignees.js +3 -3
  81. package/lib/attachments.js +12 -12
  82. package/lib/boardMove.js +27 -27
  83. package/lib/collab.js +1 -1
  84. package/lib/docs.js +115 -115
  85. package/lib/githubLink.js +7 -7
  86. package/lib/issueList.js +51 -51
  87. package/lib/issueMenu.js +117 -117
  88. package/lib/knowledge.js +134 -134
  89. package/lib/live.js +38 -38
  90. package/lib/notifications.js +47 -47
  91. package/lib/triageSeen.js +2 -2
  92. package/lib/views.js +31 -31
  93. package/package.json +24 -24
  94. package/pages/area.js +64 -64
  95. package/pages/areas.js +199 -199
  96. package/pages/decisions.js +51 -51
  97. package/pages/issues.js +120 -120
  98. package/pages/projects.js +238 -238
  99. package/pages/triage.js +202 -212
  100. package/routes/_workspace/agents/_slug2.js +127 -127
  101. package/routes/_workspace/agents/index2.js +22 -22
  102. package/routes/_workspace/dashboards/_dashboardId2.js +84 -84
  103. package/routes/_workspace/dashboards/index2.js +34 -34
  104. package/routes/_workspace/docs/_doc2.js +267 -267
  105. package/routes/_workspace/docs/space2._space.js +31 -31
  106. package/routes/_workspace/docs2.js +4 -4
  107. package/routes/_workspace/graph2.js +11 -11
  108. package/routes/_workspace/graph3.js +11 -11
  109. package/routes/_workspace/issues/_identifier2.js +519 -522
  110. package/routes/_workspace/issues/index.js +13 -13
  111. package/routes/_workspace/knowledge/_term2.js +148 -146
  112. package/routes/_workspace/knowledge/_term3.js +4 -4
  113. package/routes/_workspace/knowledge/index.js +12 -12
  114. package/routes/_workspace/knowledge/index2.js +117 -115
  115. package/routes/_workspace/measures2.js +8 -8
  116. package/routes/_workspace/measures3.js +29 -29
  117. package/routes/_workspace/notifications2.js +263 -263
  118. package/routes/_workspace/people/_username.js +10 -10
  119. package/routes/_workspace/people/_username2.js +41 -41
  120. package/routes/_workspace/projects/_projectId3.js +303 -303
  121. package/routes/_workspace/projects/_projectId4.js +4 -4
  122. package/routes/_workspace/projects/_projectId_3.milestones._milestoneId.js +28 -28
  123. package/routes/_workspace/projects/_projectId_4.milestones._milestoneId.js +4 -4
  124. package/routes/_workspace/projects/index.js +8 -8
  125. package/routes/_workspace/settings/account2.js +8 -8
  126. package/routes/_workspace/settings/audit-log2.js +8 -8
  127. package/routes/_workspace/settings/audit-log3.js +155 -155
  128. package/routes/_workspace/settings/connections2.js +4 -4
  129. package/routes/_workspace/settings/fields2.js +5 -5
  130. package/routes/_workspace/settings/github2.js +11 -11
  131. package/routes/_workspace/settings/gitlab2.js +5 -5
  132. package/routes/_workspace/settings/groups2.js +52 -52
  133. package/routes/_workspace/settings/import2.js +39 -39
  134. package/routes/_workspace/settings/index2.js +5 -5
  135. package/routes/_workspace/settings/intercom2.js +11 -11
  136. package/routes/_workspace/settings/labels2.js +33 -33
  137. package/routes/_workspace/settings/members2.js +81 -81
  138. package/routes/_workspace/settings/notifications2.js +46 -46
  139. package/routes/_workspace/settings/parallelworks2.js +20 -20
  140. package/routes/_workspace/settings/roles2.js +41 -41
  141. package/routes/_workspace/settings/runners2.js +15 -15
  142. package/routes/_workspace/settings/sentry2.js +15 -15
  143. package/routes/_workspace/settings/sessions2.js +9 -9
  144. package/routes/_workspace/settings/sessions3.js +4 -4
  145. package/routes/_workspace/settings/slack2.js +12 -12
  146. package/routes/_workspace/settings/sso2.js +37 -37
  147. package/routes/_workspace/settings/sso3.js +7 -7
  148. package/routes/_workspace/settings/teams2.js +29 -29
  149. package/routes/_workspace/settings/tokens2.js +32 -32
  150. package/routes/_workspace/settings/tokens3.js +4 -4
  151. package/routes/_workspace/settings/webhooks2.js +41 -41
  152. package/routes/_workspace/settings/zendesk2.js +11 -11
  153. package/routes/_workspace/teams/_key/cycles/_number2.js +33 -33
  154. package/routes/_workspace/teams/_key/cycles/_number3.js +7 -7
  155. package/routes/_workspace/teams/_key/cycles/index2.js +37 -37
  156. package/routes/_workspace/teams/_key/issues.js +10 -10
  157. package/routes/_workspace/teams/_key/projects.js +6 -6
  158. package/routes/_workspace/teams/_key/settings2.js +396 -396
  159. package/routes/_workspace2.js +308 -308
  160. package/routes/_workspace3.js +8 -8
  161. package/routes/device2.js +4 -4
  162. package/routes/device3.js +4 -4
  163. package/routes/docs/_tag/_endpoint2.js +3 -3
  164. package/routes/docs/_tag/index2.js +3 -3
  165. package/routes/docs/route2.js +7 -7
  166. package/routes/index2.js +5 -5
  167. package/routes/login2.js +10 -10
  168. package/routes/new2.js +12 -12
  169. package/routes/new3.js +5 -5
  170. package/routes/request2._token.js +6 -6
  171. package/routes/share2._secret.js +4 -4
package/pages/projects.js CHANGED
@@ -1,71 +1,71 @@
1
- import { usePageTitle as e } from "../lib/pageTitle.js";
2
- import { Link as t, useNavigate as n } from "../lib/router.js";
3
- import { projectsQuery as r, teamsQuery as i } from "../api/queries.js";
4
- import { useFavorites as a } from "../lib/favorites.js";
5
- import { copyItem as o, useLinkItems as s } from "../lib/menus.js";
6
- import { ChevronDownIcon as c, ListViewIcon as l, PriorityIcon as u, ProjectIcon as d, TimelineIcon as f, usePriorityNames as p } from "../components/icons.js";
7
- import { usePeople as m } from "../lib/people.js";
8
- import { useTime as h } from "../lib/time.js";
9
- import { HealthIcon as g, ProgressBar as _, ProjectStatusIcon as v, healthOf as y } from "../components/Planning.js";
10
- import { projectRef as b, projectTree as x, projectsUnder as S } from "../lib/projects.js";
11
- import { EntityIcon as C } from "../components/EntityIcon.js";
12
- import { useCan as w } from "../lib/roles.js";
13
- import { healthStates as T, projectStatuses as ee, shownStatus as te } from "../lib/projectStates.js";
14
- import { storeLayout as ne, storedLayout as E } from "../lib/projectList.js";
15
- import { FavoriteStar as re } from "../components/FavoriteStar.js";
16
- import { DisplayMenu as ie } from "../components/DisplayMenu.js";
17
- import { NewProjectDialog as ae } from "../components/NewProjectDialog.js";
18
- import { Avatar as D, Button as O, Combobox as oe, EmptyState as se, PageHeaderAddButton as ce, Switch as le, Tabs as k, ToggleGroup as ue, Tooltip as A, menuDivider as de, useOpenMenu as fe } from "@parallelworks/ui";
19
- import { useParams as j, useSearch as M } from "@tanstack/react-router";
20
- import { useEffect as N, useId as P, useRef as F, useState as I } from "react";
1
+ import { projectsQuery as e, teamsQuery as t } from "../api/queries.js";
2
+ import { DisplayMenu as n } from "../components/DisplayMenu.js";
3
+ import { EntityIcon as r } from "../components/EntityIcon.js";
4
+ import { FavoriteStar as i } from "../components/FavoriteStar.js";
5
+ import { ChevronDownIcon as a, ListViewIcon as o, PriorityIcon as s, ProjectIcon as c, TimelineIcon as l, usePriorityNames as u } from "../components/icons.js";
6
+ import { NewProjectDialog as d } from "../components/NewProjectDialog.js";
7
+ import { HealthIcon as f, ProgressBar as p, ProjectStatusIcon as m, healthOf as h } from "../components/Planning.js";
8
+ import { useFavorites as g } from "../lib/favorites.js";
9
+ import { copyItem as _, useLinkItems as v } from "../lib/menus.js";
10
+ import { usePageTitle as y } from "../lib/pageTitle.js";
11
+ import { usePeople as b } from "../lib/people.js";
12
+ import { storeLayout as x, storedLayout as S } from "../lib/projectList.js";
13
+ import { healthStates as C, projectStatuses as ee, shownStatus as te } from "../lib/projectStates.js";
14
+ import { projectRef as w, projectTree as T, projectsUnder as E } from "../lib/projects.js";
15
+ import { useCan as ne } from "../lib/roles.js";
16
+ import { Link as D, useNavigate as re } from "../lib/router.js";
17
+ import { useTime as O } from "../lib/time.js";
18
+ import { Avatar as k, Button as A, Combobox as ie, EmptyState as ae, PageHeaderAddButton as oe, Switch as se, Tabs as j, ToggleGroup as ce, Tooltip as M, menuDivider as le, useOpenMenu as ue } from "@parallelworks/ui";
19
+ import { useParams as N, useSearch as de } from "@tanstack/react-router";
20
+ import { useEffect as P, useId as fe, useRef as F, useState as I } from "react";
21
21
  import { useFormatter as L, useTranslations as R } from "use-intl";
22
22
  import { jsx as z, jsxs as B } from "react/jsx-runtime";
23
23
  import { useSuspenseQuery as V } from "@tanstack/react-query";
24
24
  import { MoreButton as H } from "@parallelworks/ui/list";
25
25
  // src/pages/projects.tsx
26
26
  function U() {
27
- let { workspace: t, key: c } = j({ strict: !1 }), u = M({ strict: !1 }), p = c ? {
28
- ...u,
29
- team: c
30
- } : u, m = R("planning"), h = R("common"), { data: g } = V(r(t)), { data: _ } = V(i(t)), v = _.find((e) => e.key === p.team);
31
- e(v ? m("teamProjects", { team: v.name }) : m("projects"));
32
- let x = c ? "list" : "timeline", C = p.view ?? E(!!c) ?? x, T = g.filter((e) => (!v || e.teamIds.includes(v.id)) && !!e.template == (C === "templates")), D = w(t, "manage_projects"), [k, A] = I(!1), N = P(), F = n(), L = fe(), H = s(), U = p.parent ? g.find((e) => e.id === p.parent) : void 0, W = U && new Set(S(g, U.id).map((e) => e.id)), G = te(p.status, C === "templates"), K = T.filter((e) => (!G || e.status === G) && (!p.health || y(e) === p.health) && (!W || W.has(e.id))), q = T.length > 0 && (!!G || !!p.health), J = (e) => {
33
- let { team: n, ...r } = Object.fromEntries(Object.entries({
34
- ...p,
27
+ let { workspace: r, key: a } = N({ strict: !1 }), s = de({ strict: !1 }), u = a ? {
28
+ ...s,
29
+ team: a
30
+ } : s, f = R("planning"), p = R("common"), { data: m } = V(e(r)), { data: b } = V(t(r)), C = b.find((e) => e.key === u.team);
31
+ y(C ? f("teamProjects", { team: C.name }) : f("projects"));
32
+ let T = a ? "list" : "timeline", D = u.view ?? S(!!a) ?? T, O = m.filter((e) => (!C || e.teamIds.includes(C.id)) && !!e.template == (D === "templates")), k = ne(r, "manage_projects"), [j, M] = I(!1), P = fe(), F = re(), L = ue(), H = v(), U = u.parent ? m.find((e) => e.id === u.parent) : void 0, W = U && new Set(E(m, U.id).map((e) => e.id)), G = te(u.status, D === "templates"), K = O.filter((e) => (!G || e.status === G) && (!u.health || h(e) === u.health) && (!W || W.has(e.id))), q = O.length > 0 && (!!G || !!u.health), J = (e) => {
33
+ let { team: t, ...n } = Object.fromEntries(Object.entries({
34
+ ...u,
35
35
  ...e
36
36
  }).filter(([, e]) => e !== void 0));
37
- return F(c ? {
37
+ return F(a ? {
38
38
  to: "/$workspace/teams/$key/projects",
39
39
  params: {
40
- workspace: t,
41
- key: c
40
+ workspace: r,
41
+ key: a
42
42
  },
43
- search: r,
43
+ search: n,
44
44
  replace: !0
45
45
  } : {
46
46
  to: "/$workspace/projects",
47
- params: { workspace: t },
48
- search: r,
47
+ params: { workspace: r },
48
+ search: n,
49
49
  replace: !0
50
50
  });
51
- }, Y = a(t), X = R("favorites"), Z = (e) => [
51
+ }, Y = g(r), X = R("favorites"), Z = (e) => [
52
52
  {
53
- label: h("open"),
53
+ label: p("open"),
54
54
  onClick: () => F({
55
55
  to: "/$workspace/projects/$projectId",
56
56
  params: {
57
- workspace: t,
58
- projectId: b(e)
57
+ workspace: r,
58
+ projectId: w(e)
59
59
  }
60
60
  })
61
61
  },
62
62
  {
63
- label: m("viewIssues"),
63
+ label: f("viewIssues"),
64
64
  onClick: () => F({
65
65
  to: "/$workspace/projects/$projectId",
66
66
  params: {
67
- workspace: t,
68
- projectId: b(e)
67
+ workspace: r,
68
+ projectId: w(e)
69
69
  },
70
70
  search: { tab: "issues" }
71
71
  })
@@ -74,11 +74,11 @@ function U() {
74
74
  label: Y.find("project", e.id) ? X("remove") : X("add"),
75
75
  onClick: () => Y.toggle("project", e.id)
76
76
  },
77
- de,
78
- ...H(`/${t}/projects/${b(e)}`),
79
- o(h("copyName"), e.name)
77
+ le,
78
+ ...H(`/${r}/projects/${w(e)}`),
79
+ _(p("copyName"), e.name)
80
80
  ], Q = (e) => ({
81
- workspace: t,
81
+ workspace: r,
82
82
  project: e,
83
83
  onContextMenu: (t) => L(t, Z(e)),
84
84
  menu: () => Z(e)
@@ -91,92 +91,92 @@ function U() {
91
91
  children: [
92
92
  /* @__PURE__ */ z("h1", {
93
93
  className: "min-w-0 truncate text-sm font-semibold",
94
- children: v ? m("teamProjects", { team: v.name }) : m("projects")
94
+ children: C ? f("teamProjects", { team: C.name }) : f("projects")
95
95
  }),
96
- !v && /* @__PURE__ */ z(re, {
97
- workspace: t,
96
+ !C && /* @__PURE__ */ z(i, {
97
+ workspace: r,
98
98
  kind: "page",
99
99
  target: "projects"
100
100
  }),
101
101
  /* @__PURE__ */ z("span", {
102
102
  className: "ml-auto flex items-center gap-1",
103
- children: /* @__PURE__ */ z(ie, {
104
- ...C !== "templates" && {
103
+ children: /* @__PURE__ */ z(n, {
104
+ ...D !== "templates" && {
105
105
  layouts: [{
106
106
  value: "list",
107
- label: m("views.list"),
108
- icon: /* @__PURE__ */ z(l, {})
107
+ label: f("views.list"),
108
+ icon: /* @__PURE__ */ z(o, {})
109
109
  }, {
110
110
  value: "timeline",
111
- label: m("views.timeline"),
112
- icon: /* @__PURE__ */ z(f, {})
111
+ label: f("views.timeline"),
112
+ icon: /* @__PURE__ */ z(l, {})
113
113
  }],
114
- layout: C,
114
+ layout: D,
115
115
  onLayoutChange: (e) => {
116
- ne(!!c, e), J({ view: e });
116
+ x(!!a, e), J({ view: e });
117
117
  }
118
118
  },
119
- changed: C !== x,
119
+ changed: D !== T,
120
120
  children: /* @__PURE__ */ B("div", {
121
121
  className: "flex items-center justify-between gap-3",
122
122
  children: [/* @__PURE__ */ z("span", {
123
- id: N,
123
+ id: P,
124
124
  className: "text-sm",
125
- children: m("showTemplates")
126
- }), /* @__PURE__ */ z(le, {
125
+ children: f("showTemplates")
126
+ }), /* @__PURE__ */ z(se, {
127
127
  size: "sm",
128
- checked: C === "templates",
128
+ checked: D === "templates",
129
129
  onCheckedChange: (e) => J({ view: e ? "templates" : void 0 }),
130
- "aria-labelledby": N
130
+ "aria-labelledby": P
131
131
  })]
132
132
  })
133
133
  })
134
134
  }),
135
- D && /* @__PURE__ */ z(ce, {
136
- label: m("newProject"),
137
- onClick: () => A(!0)
135
+ k && /* @__PURE__ */ z(oe, {
136
+ label: f("newProject"),
137
+ onClick: () => M(!0)
138
138
  })
139
139
  ]
140
140
  }),
141
141
  /* @__PURE__ */ B("div", {
142
142
  className: "flex shrink-0 flex-wrap items-center gap-1 border-b border-border px-4 py-2 md:px-5",
143
143
  children: [
144
- /* @__PURE__ */ z(ue, {
145
- label: m("filterStatus"),
144
+ /* @__PURE__ */ z(ce, {
145
+ label: f("filterStatus"),
146
146
  multiple: !1,
147
- all: { count: T.length },
147
+ all: { count: O.length },
148
148
  options: ee.map((e) => ({
149
149
  value: e,
150
- label: m(`status.${e}`),
151
- count: T.filter((t) => t.status === e).length
150
+ label: f(`status.${e}`),
151
+ count: O.filter((t) => t.status === e).length
152
152
  })),
153
153
  value: G ? [G] : [],
154
154
  onValueChange: ([e]) => J({ status: e ?? "all" })
155
155
  }),
156
- p.health && /* @__PURE__ */ z(O, {
156
+ u.health && /* @__PURE__ */ z(A, {
157
157
  variant: "outline",
158
158
  size: "sm",
159
159
  "aria-pressed": !0,
160
160
  onClick: () => J({ health: void 0 }),
161
- children: m("healthFilter", { health: m(`health.${p.health}`) })
161
+ children: f("healthFilter", { health: f(`health.${u.health}`) })
162
162
  }),
163
- T.some((e) => e.parentId) && /* @__PURE__ */ z(oe, {
163
+ O.some((e) => e.parentId) && /* @__PURE__ */ z(ie, {
164
164
  items: [{
165
165
  value: "",
166
- label: m("anyParent")
167
- }, ...g.filter((e) => g.some((t) => t.parentId === e.id)).map((e) => ({
166
+ label: f("anyParent")
167
+ }, ...m.filter((e) => m.some((t) => t.parentId === e.id)).map((e) => ({
168
168
  value: e.id,
169
169
  label: e.name
170
170
  }))],
171
- value: p.parent ?? "",
171
+ value: u.parent ?? "",
172
172
  onValueChange: (e) => J({ parent: e || void 0 }),
173
- placeholder: m("parentProject"),
174
- "aria-label": m("parentProject"),
175
- trigger: /* @__PURE__ */ z(O, {
173
+ placeholder: f("parentProject"),
174
+ "aria-label": f("parentProject"),
175
+ trigger: /* @__PURE__ */ z(A, {
176
176
  variant: "outline",
177
177
  size: "sm",
178
178
  className: U ? "border-(--theme-link) text-(--theme-app)" : void 0,
179
- children: U ? m("underProject", { name: U.name }) : m("parentProject")
179
+ children: U ? f("underProject", { name: U.name }) : f("parentProject")
180
180
  })
181
181
  })
182
182
  ]
@@ -187,19 +187,19 @@ function U() {
187
187
  className: "min-h-0 min-w-0 flex-1 overflow-auto",
188
188
  children: K.length === 0 ? /* @__PURE__ */ z("div", {
189
189
  className: "p-6",
190
- children: /* @__PURE__ */ z(se, {
191
- icon: /* @__PURE__ */ z(d, {}),
192
- title: m(q ? "noProjectsWithStatus" : C === "templates" ? "noTemplates" : "noProjects"),
193
- ...!q && { description: m(C === "templates" ? "noTemplatesDescription" : "noProjectsDescription") },
194
- ...D && !q && C !== "templates" && { action: /* @__PURE__ */ z(O, {
190
+ children: /* @__PURE__ */ z(ae, {
191
+ icon: /* @__PURE__ */ z(c, {}),
192
+ title: f(q ? "noProjectsWithStatus" : D === "templates" ? "noTemplates" : "noProjects"),
193
+ ...!q && { description: f(D === "templates" ? "noTemplatesDescription" : "noProjectsDescription") },
194
+ ...k && !q && D !== "templates" && { action: /* @__PURE__ */ z(A, {
195
195
  type: "button",
196
196
  variant: "primary",
197
- onClick: () => A(!0),
198
- children: m("newProject")
197
+ onClick: () => M(!0),
198
+ children: f("newProject")
199
199
  }) }
200
200
  })
201
- }) : C === "timeline" ? /* @__PURE__ */ z(ge, {
202
- workspace: t,
201
+ }) : D === "timeline" ? /* @__PURE__ */ z(ge, {
202
+ workspace: r,
203
203
  projects: K,
204
204
  rowProps: Q
205
205
  }) : /* @__PURE__ */ z(pe, {
@@ -207,23 +207,23 @@ function U() {
207
207
  rowProps: Q
208
208
  })
209
209
  }), /* @__PURE__ */ z(ve, {
210
- workspace: t,
211
- projects: T,
212
- health: p.health,
213
- onHealth: (e) => J({ health: e === p.health ? void 0 : e })
210
+ workspace: r,
211
+ projects: O,
212
+ health: u.health,
213
+ onHealth: (e) => J({ health: e === u.health ? void 0 : e })
214
214
  })]
215
215
  }),
216
- k && /* @__PURE__ */ z(ae, {
217
- workspace: t,
218
- teamId: v?.id,
219
- onClose: () => A(!1)
216
+ j && /* @__PURE__ */ z(d, {
217
+ workspace: r,
218
+ teamId: C?.id,
219
+ onClose: () => M(!1)
220
220
  })
221
221
  ]
222
222
  });
223
223
  }
224
224
  var W = "@4xl:grid @4xl:grid-cols-[minmax(0,1fr)_10rem_2rem_2rem_6rem_8rem_2rem]";
225
225
  function pe({ projects: e, rowProps: t }) {
226
- let n = R("planning"), [r, i] = I(/* @__PURE__ */ new Set()), a = new Set([...r].flatMap((t) => S(e, t).map((e) => e.id))), o = (e) => i((t) => {
226
+ let n = R("planning"), [r, i] = I(/* @__PURE__ */ new Set()), a = new Set([...r].flatMap((t) => E(e, t).map((e) => e.id))), o = (e) => i((t) => {
227
227
  let n = new Set(t);
228
228
  return n.delete(e) || n.add(e), n;
229
229
  });
@@ -234,14 +234,14 @@ function pe({ projects: e, rowProps: t }) {
234
234
  children: [
235
235
  /* @__PURE__ */ z("span", { children: n("name") }),
236
236
  /* @__PURE__ */ z("span", { children: n("healthLabel") }),
237
- /* @__PURE__ */ z(A, {
237
+ /* @__PURE__ */ z(M, {
238
238
  content: n("priority"),
239
239
  children: /* @__PURE__ */ z("span", { children: /* @__PURE__ */ z("span", {
240
240
  className: "sr-only",
241
241
  children: n("priority")
242
242
  }) })
243
243
  }),
244
- /* @__PURE__ */ z(A, {
244
+ /* @__PURE__ */ z(M, {
245
245
  content: n("lead"),
246
246
  children: /* @__PURE__ */ z("span", { children: /* @__PURE__ */ z("span", {
247
247
  className: "sr-only",
@@ -252,7 +252,7 @@ function pe({ projects: e, rowProps: t }) {
252
252
  /* @__PURE__ */ z("span", { children: n("progressTitle") }),
253
253
  /* @__PURE__ */ z("span", {})
254
254
  ]
255
- }), /* @__PURE__ */ z("ul", { children: x(e).filter((e) => !a.has(e.project.id)).map((e) => /* @__PURE__ */ z(K, {
255
+ }), /* @__PURE__ */ z("ul", { children: T(e).filter((e) => !a.has(e.project.id)).map((e) => /* @__PURE__ */ z(K, {
256
256
  ...t(e.project),
257
257
  depth: e.depth,
258
258
  childCount: e.children,
@@ -262,97 +262,97 @@ function pe({ projects: e, rowProps: t }) {
262
262
  });
263
263
  }
264
264
  function G({ project: e }) {
265
- return e.icon || e.color ? /* @__PURE__ */ z(C, {
265
+ return e.icon || e.color ? /* @__PURE__ */ z(r, {
266
266
  icon: e.icon ?? "",
267
267
  color: e.color ?? "",
268
268
  name: e.name
269
- }) : /* @__PURE__ */ z(d, { className: "size-4 text-muted-foreground" });
269
+ }) : /* @__PURE__ */ z(c, { className: "size-4 text-muted-foreground" });
270
270
  }
271
- function K({ workspace: e, project: n, onContextMenu: r, menu: i, depth: a = 0, childCount: o = 0, folded: s = !1, onFold: l }) {
272
- let d = R("planning"), f = R("common"), x = h(), S = p(), { person: C } = m(e), w = n.lead ? C(n.lead) : void 0, T = y(n);
271
+ function K({ workspace: e, project: t, onContextMenu: n, menu: r, depth: i = 0, childCount: o = 0, folded: c = !1, onFold: l }) {
272
+ let d = R("planning"), g = R("common"), _ = O(), v = u(), { person: y } = b(e), x = t.lead ? y(t.lead) : void 0, S = h(t);
273
273
  return /* @__PURE__ */ B("li", {
274
274
  className: "group flex items-center border-b border-border pr-2 hover:bg-muted/60",
275
275
  children: [
276
276
  /* @__PURE__ */ z("span", {
277
277
  className: "flex shrink-0 justify-end pl-2 md:pl-3",
278
- style: { width: `${a * 1.25 + 2}rem` },
278
+ style: { width: `${i * 1.25 + 2}rem` },
279
279
  children: o > 0 && /* @__PURE__ */ z("button", {
280
280
  type: "button",
281
281
  onClick: l,
282
- "aria-expanded": !s,
283
- "aria-label": d(s ? "showSubProjects" : "hideSubProjects", { name: n.name }),
282
+ "aria-expanded": !c,
283
+ "aria-label": d(c ? "showSubProjects" : "hideSubProjects", { name: t.name }),
284
284
  className: "rounded p-1 text-muted-foreground hover:bg-muted hover:text-foreground",
285
- children: /* @__PURE__ */ z(c, { className: `size-3.5 transition-transform ${s ? "-rotate-90" : ""}` })
285
+ children: /* @__PURE__ */ z(a, { className: `size-3.5 transition-transform ${c ? "-rotate-90" : ""}` })
286
286
  })
287
287
  }),
288
- /* @__PURE__ */ B(t, {
288
+ /* @__PURE__ */ B(D, {
289
289
  to: "/$workspace/projects/$projectId",
290
290
  params: {
291
291
  workspace: e,
292
- projectId: b(n)
292
+ projectId: w(t)
293
293
  },
294
- onContextMenu: r,
294
+ onContextMenu: n,
295
295
  className: `flex min-w-0 flex-1 flex-wrap items-center gap-x-3 gap-y-1 py-2.5 pl-1 ${W}`,
296
296
  children: [
297
297
  /* @__PURE__ */ B("span", {
298
298
  className: "flex min-w-0 basis-full items-center gap-2.5 @4xl:basis-auto",
299
- children: [/* @__PURE__ */ z(G, { project: n }), /* @__PURE__ */ B("span", {
299
+ children: [/* @__PURE__ */ z(G, { project: t }), /* @__PURE__ */ B("span", {
300
300
  className: "min-w-0",
301
301
  children: [/* @__PURE__ */ z("span", {
302
302
  className: "block truncate text-sm font-medium",
303
- children: n.name
304
- }), n.summary && /* @__PURE__ */ z("span", {
303
+ children: t.name
304
+ }), t.summary && /* @__PURE__ */ z("span", {
305
305
  className: "block truncate text-xs text-muted-foreground",
306
- children: n.summary
306
+ children: t.summary
307
307
  })]
308
308
  })]
309
309
  }),
310
310
  /* @__PURE__ */ B("span", {
311
311
  className: "flex items-center gap-1.5 whitespace-nowrap text-xs text-muted-foreground",
312
- children: [/* @__PURE__ */ z(g, { state: T }), d(`health.${T}`)]
312
+ children: [/* @__PURE__ */ z(f, { state: S }), d(`health.${S}`)]
313
313
  }),
314
- /* @__PURE__ */ z(A, {
315
- content: S[n.priority],
314
+ /* @__PURE__ */ z(M, {
315
+ content: v[t.priority],
316
316
  children: /* @__PURE__ */ z("span", {
317
317
  role: "img",
318
- "aria-label": S[n.priority],
318
+ "aria-label": v[t.priority],
319
319
  className: "flex",
320
- children: /* @__PURE__ */ z(u, { priority: n.priority })
320
+ children: /* @__PURE__ */ z(s, { priority: t.priority })
321
321
  })
322
322
  }),
323
323
  /* @__PURE__ */ z("span", {
324
324
  className: "flex",
325
- children: w && /* @__PURE__ */ z(A, {
326
- content: d("leadIs", { name: w.name }),
327
- children: /* @__PURE__ */ z("span", { children: /* @__PURE__ */ z(D, {
328
- name: w.name,
329
- src: w.avatarUrl,
325
+ children: x && /* @__PURE__ */ z(M, {
326
+ content: d("leadIs", { name: x.name }),
327
+ children: /* @__PURE__ */ z("span", { children: /* @__PURE__ */ z(k, {
328
+ name: x.name,
329
+ src: x.avatarUrl,
330
330
  size: "sm"
331
331
  }) })
332
332
  })
333
333
  }),
334
334
  /* @__PURE__ */ z("span", {
335
335
  className: "text-xs text-muted-foreground tabular-nums",
336
- children: n.targetDate ? x.day(n.targetDate) : ""
336
+ children: t.targetDate ? _.day(t.targetDate) : ""
337
337
  }),
338
- /* @__PURE__ */ z("span", { children: /* @__PURE__ */ z(_, {
339
- progress: o > 0 ? n.treeProgress : n.progress,
338
+ /* @__PURE__ */ z("span", { children: /* @__PURE__ */ z(p, {
339
+ progress: o > 0 ? t.treeProgress : t.progress,
340
340
  compact: !0
341
341
  }) }),
342
- /* @__PURE__ */ z(A, {
343
- content: d(`status.${n.status}`),
342
+ /* @__PURE__ */ z(M, {
343
+ content: d(`status.${t.status}`),
344
344
  children: /* @__PURE__ */ z("span", {
345
345
  role: "img",
346
- "aria-label": d(`status.${n.status}`),
346
+ "aria-label": d(`status.${t.status}`),
347
347
  className: "flex",
348
- children: /* @__PURE__ */ z(v, { status: n.status })
348
+ children: /* @__PURE__ */ z(m, { status: t.status })
349
349
  })
350
350
  })
351
351
  ]
352
352
  }),
353
353
  /* @__PURE__ */ z(H, {
354
- items: i,
355
- label: f("moreActionsFor", { name: n.name })
354
+ items: r,
355
+ label: g("moreActionsFor", { name: t.name })
356
356
  })
357
357
  ]
358
358
  });
@@ -364,51 +364,51 @@ var q = 864e5, J = 5, Y = 64, X = 256, Z = 56, Q = (e) => Date.parse(`${e}T00:00
364
364
  let e = /* @__PURE__ */ new Date();
365
365
  return Date.UTC(e.getFullYear(), e.getMonth(), e.getDate());
366
366
  }, he = (e) => e - (new Date(e).getUTCDay() + 6) % 7 * q;
367
- function ge({ workspace: e, projects: n, rowProps: r }) {
368
- let i = R("planning"), a = L(), o = F(null), [s, c] = I({
367
+ function ge({ workspace: e, projects: t, rowProps: n }) {
368
+ let r = R("planning"), i = L(), a = F(null), [o, s] = I({
369
369
  left: 0,
370
370
  width: 0
371
- }), l = me(), u = n.map((e) => {
371
+ }), c = me(), l = t.map((e) => {
372
372
  let t = e.targetDate ? Q(e.targetDate) : void 0;
373
373
  return {
374
374
  p: e,
375
375
  start: e.startDate ? Q(e.startDate) : t === void 0 ? void 0 : Math.min(Date.parse(e.createdAt), t),
376
376
  end: t
377
377
  };
378
- }), d = u.flatMap((e) => [e.start, e.end].filter((e) => e !== void 0)), f = $(Math.min(l - 90 * q, ...d)), p = $(Math.max(l + 300 * q, ...d) + 40 * q), m = (e) => (e - f) / q * J, h = m(p), g = [];
379
- for (let e = f; e < p; e = $(e + 32 * q)) g.push(e);
380
- let _ = [];
381
- for (let e = he(f) + 7 * q; e < p; e += 7 * q) _.push(e);
382
- let v = (e, t) => a.dateTime(new Date(e), {
378
+ }), u = l.flatMap((e) => [e.start, e.end].filter((e) => e !== void 0)), d = $(Math.min(c - 90 * q, ...u)), f = $(Math.max(c + 300 * q, ...u) + 40 * q), p = (e) => (e - d) / q * J, m = p(f), h = [];
379
+ for (let e = d; e < f; e = $(e + 32 * q)) h.push(e);
380
+ let g = [];
381
+ for (let e = he(d) + 7 * q; e < f; e += 7 * q) g.push(e);
382
+ let _ = (e, t) => i.dateTime(new Date(e), {
383
383
  ...t,
384
384
  timeZone: "UTC"
385
- }), y = (e, t) => `${v(e, {
385
+ }), v = (e, t) => `${_(e, {
386
386
  month: "short",
387
387
  year: "numeric"
388
- })} – ${v(t, {
388
+ })} – ${_(t, {
389
389
  month: "short",
390
390
  year: "numeric"
391
- })}`, x = () => {
392
- let e = o.current;
393
- e && c({
391
+ })}`, y = () => {
392
+ let e = a.current;
393
+ e && s({
394
394
  left: e.scrollLeft,
395
395
  width: e.clientWidth - X
396
396
  });
397
- }, S = (e = "smooth") => {
398
- let t = o.current;
397
+ }, b = (e = "smooth") => {
398
+ let t = a.current;
399
399
  t && t.scrollTo({
400
- left: m(l) - (t.clientWidth - X) / 2,
400
+ left: p(c) - (t.clientWidth - X) / 2,
401
401
  behavior: e
402
402
  });
403
403
  };
404
- return N(() => (S("instant"), x(), window.addEventListener("resize", x), () => window.removeEventListener("resize", x)), []), /* @__PURE__ */ z("div", {
405
- ref: o,
406
- onScroll: x,
404
+ return P(() => (b("instant"), y(), window.addEventListener("resize", y), () => window.removeEventListener("resize", y)), []), /* @__PURE__ */ z("div", {
405
+ ref: a,
406
+ onScroll: y,
407
407
  className: "relative h-full min-h-0 overflow-auto",
408
408
  children: /* @__PURE__ */ B("div", {
409
409
  className: "relative",
410
410
  style: {
411
- width: h + X,
411
+ width: m + X,
412
412
  minHeight: "100%"
413
413
  },
414
414
  children: [
@@ -423,33 +423,33 @@ function ge({ workspace: e, projects: n, rowProps: r }) {
423
423
  children: [/* @__PURE__ */ z("div", {
424
424
  className: "sticky left-0 z-[3] flex shrink-0 items-end border-r border-border bg-background px-4 pb-2",
425
425
  style: { width: X },
426
- children: /* @__PURE__ */ z(O, {
426
+ children: /* @__PURE__ */ z(A, {
427
427
  type: "button",
428
428
  size: "xs",
429
- onClick: () => S(),
430
- children: i("today")
429
+ onClick: () => b(),
430
+ children: r("today")
431
431
  })
432
432
  }), /* @__PURE__ */ B("div", {
433
433
  className: "relative",
434
- style: { width: h },
434
+ style: { width: m },
435
435
  children: [
436
- g.map((e) => /* @__PURE__ */ z("span", {
436
+ h.map((e) => /* @__PURE__ */ z("span", {
437
437
  className: "absolute top-2 pl-1.5 text-[11px] font-medium text-muted-foreground uppercase",
438
- style: { left: m(e) },
439
- children: v(e, {
438
+ style: { left: p(e) },
439
+ children: _(e, {
440
440
  month: "short",
441
441
  ...new Date(e).getUTCMonth() === 0 && { year: "numeric" }
442
442
  })
443
443
  }, e)),
444
- _.filter((e) => Math.abs(m(e) - m(l)) > 36).map((e) => /* @__PURE__ */ z("span", {
444
+ g.filter((e) => Math.abs(p(e) - p(c)) > 36).map((e) => /* @__PURE__ */ z("span", {
445
445
  className: "absolute bottom-2 -translate-x-1/2 text-[11px] text-muted-foreground tabular-nums",
446
- style: { left: m(e) },
447
- children: v(e, { day: "numeric" })
446
+ style: { left: p(e) },
447
+ children: _(e, { day: "numeric" })
448
448
  }, e)),
449
449
  /* @__PURE__ */ z("span", {
450
450
  className: "absolute bottom-1.5 z-[1] -translate-x-1/2 rounded-full bg-primary px-2 py-px text-[11px] font-medium text-primary-foreground uppercase tabular-nums",
451
- style: { left: m(l) },
452
- children: v(l, {
451
+ style: { left: p(c) },
452
+ children: _(c, {
453
453
  month: "short",
454
454
  day: "numeric"
455
455
  })
@@ -457,19 +457,19 @@ function ge({ workspace: e, projects: n, rowProps: r }) {
457
457
  ]
458
458
  })]
459
459
  }),
460
- _.map((e) => /* @__PURE__ */ z("div", {
460
+ g.map((e) => /* @__PURE__ */ z("div", {
461
461
  "aria-hidden": "true",
462
462
  className: "pointer-events-none absolute bottom-0 border-l border-dashed border-border/40",
463
463
  style: {
464
- left: X + m(e),
464
+ left: X + p(e),
465
465
  top: Z
466
466
  }
467
467
  }, e)),
468
- g.map((e) => /* @__PURE__ */ z("div", {
468
+ h.map((e) => /* @__PURE__ */ z("div", {
469
469
  "aria-hidden": "true",
470
470
  className: "pointer-events-none absolute bottom-0 w-px bg-border/70",
471
471
  style: {
472
- left: X + m(e),
472
+ left: X + p(e),
473
473
  top: Z
474
474
  }
475
475
  }, e)),
@@ -477,160 +477,160 @@ function ge({ workspace: e, projects: n, rowProps: r }) {
477
477
  "aria-hidden": "true",
478
478
  className: "pointer-events-none absolute bottom-0 z-[1] w-px bg-primary",
479
479
  style: {
480
- left: X + m(l),
480
+ left: X + p(c),
481
481
  top: Z
482
482
  }
483
483
  }),
484
484
  /* @__PURE__ */ z("ul", {
485
485
  className: "relative",
486
- children: u.map(({ p: n, start: i, end: a }) => {
487
- let o = i !== void 0 && a !== void 0, c = o ? m(i) : 0, u = o ? Math.max(m(a + q), c + 24) : 0, d = o && u < s.left, f = o && c > s.left + s.width, p = o ? Math.min(Math.max(m(l) - c, 0), u - c) : 0, g = Math.min(Math.max(s.left + 8 - c, 0), Math.max(u - c - 80, 0));
486
+ children: l.map(({ p: t, start: r, end: i }) => {
487
+ let a = r !== void 0 && i !== void 0, s = a ? p(r) : 0, l = a ? Math.max(p(i + q), s + 24) : 0, u = a && l < o.left, d = a && s > o.left + o.width, f = a ? Math.min(Math.max(p(c) - s, 0), l - s) : 0, h = Math.min(Math.max(o.left + 8 - s, 0), Math.max(l - s - 80, 0));
488
488
  return /* @__PURE__ */ B("li", {
489
489
  className: "group flex hover:bg-muted/40",
490
490
  style: { height: Y },
491
- children: [/* @__PURE__ */ z(_e, { ...r(n) }), /* @__PURE__ */ B("div", {
491
+ children: [/* @__PURE__ */ z(_e, { ...n(t) }), /* @__PURE__ */ B("div", {
492
492
  className: "relative",
493
- style: { width: h },
494
- children: [o && !d && !f && /* @__PURE__ */ z(A, {
495
- content: `${n.name}, ${y(i, a)}`,
496
- children: /* @__PURE__ */ B(t, {
493
+ style: { width: m },
494
+ children: [a && !u && !d && /* @__PURE__ */ z(M, {
495
+ content: `${t.name}, ${v(r, i)}`,
496
+ children: /* @__PURE__ */ B(D, {
497
497
  to: "/$workspace/projects/$projectId",
498
498
  params: {
499
499
  workspace: e,
500
- projectId: b(n)
500
+ projectId: w(t)
501
501
  },
502
502
  className: "absolute top-2 bottom-2 flex flex-col justify-end gap-1",
503
503
  style: {
504
- left: c,
505
- width: u - c
504
+ left: s,
505
+ width: l - s
506
506
  },
507
507
  children: [/* @__PURE__ */ z("span", {
508
508
  className: "block self-start truncate px-0.5 text-xs font-medium",
509
509
  style: {
510
- marginLeft: g,
511
- maxWidth: Math.max(h - c - g, u - c - g)
510
+ marginLeft: h,
511
+ maxWidth: Math.max(m - s - h, l - s - h)
512
512
  },
513
- children: n.name
513
+ children: t.name
514
514
  }), /* @__PURE__ */ B("span", {
515
515
  className: "relative block h-6 overflow-hidden rounded-md border border-border",
516
516
  children: [/* @__PURE__ */ z("span", {
517
517
  className: "absolute inset-y-0 left-0 bg-muted-foreground/20",
518
- style: { width: p }
518
+ style: { width: f }
519
519
  }), /* @__PURE__ */ z("span", {
520
520
  className: "absolute inset-y-0 right-0 border-l border-dashed border-primary/50 bg-primary/10",
521
- style: { left: p }
521
+ style: { left: f }
522
522
  })]
523
523
  })]
524
524
  })
525
- }), (d || f) && /* @__PURE__ */ B(t, {
525
+ }), (u || d) && /* @__PURE__ */ B(D, {
526
526
  to: "/$workspace/projects/$projectId",
527
527
  params: {
528
528
  workspace: e,
529
- projectId: b(n)
529
+ projectId: w(t)
530
530
  },
531
531
  className: "absolute top-1/2 flex -translate-y-1/2 items-center gap-1.5 whitespace-nowrap text-xs text-muted-foreground hover:text-foreground",
532
- style: d ? { left: s.left + 12 } : {
533
- left: s.left + s.width - 12,
532
+ style: u ? { left: o.left + 12 } : {
533
+ left: o.left + o.width - 12,
534
534
  transform: "translate(-100%, -50%)"
535
535
  },
536
536
  children: [
537
- d && /* @__PURE__ */ z("span", {
537
+ u && /* @__PURE__ */ z("span", {
538
538
  "aria-hidden": "true",
539
539
  children: "←"
540
540
  }),
541
- y(i, a),
542
- f && /* @__PURE__ */ z("span", {
541
+ v(r, i),
542
+ d && /* @__PURE__ */ z("span", {
543
543
  "aria-hidden": "true",
544
544
  children: "→"
545
545
  })
546
546
  ]
547
547
  })]
548
548
  })]
549
- }, n.id);
549
+ }, t.id);
550
550
  })
551
551
  })
552
552
  ]
553
553
  })
554
554
  });
555
555
  }
556
- function _e({ workspace: e, project: n, onContextMenu: r }) {
557
- let i = R("planning"), { person: a } = m(e), o = n.lead ? a(n.lead) : void 0, s = y(n);
558
- return /* @__PURE__ */ B(t, {
556
+ function _e({ workspace: e, project: t, onContextMenu: n }) {
557
+ let r = R("planning"), { person: i } = b(e), a = t.lead ? i(t.lead) : void 0, o = h(t);
558
+ return /* @__PURE__ */ B(D, {
559
559
  to: "/$workspace/projects/$projectId",
560
560
  params: {
561
561
  workspace: e,
562
- projectId: b(n)
562
+ projectId: w(t)
563
563
  },
564
- onContextMenu: r,
564
+ onContextMenu: n,
565
565
  className: "sticky left-0 z-[2] flex shrink-0 items-center gap-2 border-r border-border bg-background px-4 group-hover:bg-muted",
566
566
  style: { width: X },
567
567
  children: [
568
- /* @__PURE__ */ z(G, { project: n }),
568
+ /* @__PURE__ */ z(G, { project: t }),
569
569
  /* @__PURE__ */ z("span", {
570
570
  className: "min-w-0 flex-1 truncate text-sm",
571
- children: n.name
571
+ children: t.name
572
572
  }),
573
- /* @__PURE__ */ z(A, {
574
- content: i(`status.${n.status}`),
573
+ /* @__PURE__ */ z(M, {
574
+ content: r(`status.${t.status}`),
575
575
  children: /* @__PURE__ */ z("span", {
576
576
  role: "img",
577
- "aria-label": i(`status.${n.status}`),
577
+ "aria-label": r(`status.${t.status}`),
578
578
  className: "flex",
579
- children: /* @__PURE__ */ z(v, { status: n.status })
579
+ children: /* @__PURE__ */ z(m, { status: t.status })
580
580
  })
581
581
  }),
582
- /* @__PURE__ */ z(A, {
583
- content: i(`health.${s}`),
582
+ /* @__PURE__ */ z(M, {
583
+ content: r(`health.${o}`),
584
584
  children: /* @__PURE__ */ z("span", {
585
585
  role: "img",
586
- "aria-label": i(`health.${s}`),
587
- children: /* @__PURE__ */ z(g, { state: s })
586
+ "aria-label": r(`health.${o}`),
587
+ children: /* @__PURE__ */ z(f, { state: o })
588
588
  })
589
589
  }),
590
- o && /* @__PURE__ */ z(D, {
591
- name: o.name,
592
- src: o.avatarUrl,
590
+ a && /* @__PURE__ */ z(k, {
591
+ name: a.name,
592
+ src: a.avatarUrl,
593
593
  size: "xs",
594
594
  tooltip: !0
595
595
  })
596
596
  ]
597
597
  });
598
598
  }
599
- function ve({ workspace: e, projects: t, health: n, onHealth: r }) {
600
- let a = R("planning"), { data: o } = V(i(e)), { person: s } = m(e), [c, l] = I("health"), u = (e) => t.filter(e).length, d = "flex h-9 w-full items-center gap-2.5 rounded-md px-2 text-sm", f = [...new Set(t.map((e) => e.lead ?? ""))];
599
+ function ve({ workspace: e, projects: n, health: i, onHealth: a }) {
600
+ let o = R("planning"), { data: s } = V(t(e)), { person: c } = b(e), [l, u] = I("health"), d = (e) => n.filter(e).length, p = "flex h-9 w-full items-center gap-2.5 rounded-md px-2 text-sm", m = [...new Set(n.map((e) => e.lead ?? ""))];
601
601
  return /* @__PURE__ */ B("aside", {
602
- "aria-label": a("breakdown"),
602
+ "aria-label": o("breakdown"),
603
603
  className: "hidden w-72 shrink-0 overflow-y-auto border-l border-border p-3 xl:block",
604
- children: [/* @__PURE__ */ z(k, {
604
+ children: [/* @__PURE__ */ z(j, {
605
605
  variant: "segmented",
606
606
  size: "sm",
607
- label: a("breakdown"),
607
+ label: o("breakdown"),
608
608
  items: [
609
609
  "health",
610
610
  "teams",
611
611
  "leads"
612
612
  ].map((e) => ({
613
613
  value: e,
614
- label: a(`summaryTabs.${e}`)
614
+ label: o(`summaryTabs.${e}`)
615
615
  })),
616
- value: c,
617
- onValueChange: l
616
+ value: l,
617
+ onValueChange: u
618
618
  }), /* @__PURE__ */ B("ul", {
619
619
  className: "mt-2",
620
620
  children: [
621
- c === "health" && T.map((e) => ({
621
+ l === "health" && C.map((e) => ({
622
622
  h: e,
623
- n: u((t) => y(t) === e)
623
+ n: d((t) => h(t) === e)
624
624
  })).filter(({ n: e }) => e > 0).map(({ h: e, n: t }) => /* @__PURE__ */ z("li", { children: /* @__PURE__ */ B("button", {
625
625
  type: "button",
626
- "aria-pressed": n === e,
627
- onClick: () => r(e),
628
- className: `${d} hover:bg-muted aria-pressed:bg-muted`,
626
+ "aria-pressed": i === e,
627
+ onClick: () => a(e),
628
+ className: `${p} hover:bg-muted aria-pressed:bg-muted`,
629
629
  children: [
630
- /* @__PURE__ */ z(g, { state: e }),
630
+ /* @__PURE__ */ z(f, { state: e }),
631
631
  /* @__PURE__ */ z("span", {
632
632
  className: "flex-1 text-left",
633
- children: a(`health.${e}`)
633
+ children: o(`health.${e}`)
634
634
  }),
635
635
  /* @__PURE__ */ z("span", {
636
636
  className: "text-muted-foreground tabular-nums",
@@ -638,13 +638,13 @@ function ve({ workspace: e, projects: t, health: n, onHealth: r }) {
638
638
  })
639
639
  ]
640
640
  }) }, e)),
641
- c === "teams" && o.filter((e) => !e.archivedAt).map((e) => ({
641
+ l === "teams" && s.filter((e) => !e.archivedAt).map((e) => ({
642
642
  team: e,
643
- n: u((t) => t.teamIds.includes(e.id))
643
+ n: d((t) => t.teamIds.includes(e.id))
644
644
  })).filter(({ n: e }) => e > 0).map(({ team: e, n: t }) => /* @__PURE__ */ B("li", {
645
- className: d,
645
+ className: p,
646
646
  children: [
647
- /* @__PURE__ */ z(C, {
647
+ /* @__PURE__ */ z(r, {
648
648
  icon: e.icon,
649
649
  color: e.color,
650
650
  name: e.name
@@ -659,12 +659,12 @@ function ve({ workspace: e, projects: t, health: n, onHealth: r }) {
659
659
  })
660
660
  ]
661
661
  }, e.id)),
662
- c === "leads" && f.map((e) => {
663
- let t = e ? s(e) : void 0;
662
+ l === "leads" && m.map((e) => {
663
+ let t = e ? c(e) : void 0;
664
664
  return /* @__PURE__ */ B("li", {
665
- className: d,
665
+ className: p,
666
666
  children: [
667
- t ? /* @__PURE__ */ z(D, {
667
+ t ? /* @__PURE__ */ z(k, {
668
668
  name: t.name,
669
669
  src: t.avatarUrl,
670
670
  size: "xs",
@@ -672,11 +672,11 @@ function ve({ workspace: e, projects: t, health: n, onHealth: r }) {
672
672
  }) : /* @__PURE__ */ z("span", { className: "size-4" }),
673
673
  /* @__PURE__ */ z("span", {
674
674
  className: "flex-1 truncate",
675
- children: t ? t.name : a("noLead")
675
+ children: t ? t.name : o("noLead")
676
676
  }),
677
677
  /* @__PURE__ */ z("span", {
678
678
  className: "text-muted-foreground tabular-nums",
679
- children: u((t) => (t.lead ?? "") === e)
679
+ children: d((t) => (t.lead ?? "") === e)
680
680
  })
681
681
  ]
682
682
  }, e || "none");