@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
@@ -1,158 +1,159 @@
1
1
  import { api as e, unwrap as t } from "../../../api/client.js";
2
- import { branchName as n } from "../../../lib/branch.js";
3
- import { usePageTitle as r } from "../../../lib/pageTitle.js";
4
- import { Link as i, useNavigate as a } from "../../../lib/router.js";
5
- import { areasQuery as o, attachmentsQuery as s, commentsQuery as c, cyclesQuery as l, eventsQuery as u, issueDocsQuery as d, issueLinksQuery as f, issueQuery as p, labelsQuery as m, meQuery as h, projectsQuery as g, reactionsQuery as _, statusesQuery as v, teamsQuery as y } from "../../../api/queries.js";
6
- import { invalidateIssueViews as b, useUpdateIssue as x } from "../../../api/mutations.js";
7
- import { copyItem as S } from "../../../lib/menus.js";
8
- import { docRef as C, useDocMenu as w } from "../../../lib/docs.js";
9
- import { AreaIcon as T, BranchIcon as E, CalendarIcon as D, CloseIcon as O, CycleIcon as k, EstimateIcon as A, FileTextIcon as j, InboxIcon as M, PriorityIcon as N, ProjectIcon as P, StatusIcon as F, TriageIcon as I, usePriorityNames as ee } from "../../../components/icons.js";
10
- import { connectorActor as L, usePeople as te } from "../../../lib/people.js";
11
- import { useTime as ne } from "../../../lib/time.js";
12
- import { AgentPage as re } from "../../../components/AgentPage.js";
13
- import { DueDate as ie, ProjectStatusIcon as ae, SlaBadge as oe, scalePoints as se, useEstimateLabel as ce } from "../../../components/Planning.js";
14
- import { PickManyBox as le, usePickMany as ue } from "../../../lib/pickMany.js";
15
- import { assigneeKey as de, parseAssigneeKey as fe, useAssigneeOptions as pe } from "../../../lib/assignees.js";
16
- import { issueURL as me, useIssueMenu as he } from "../../../lib/issueMenu.js";
17
- import { useLinkedIssues as ge } from "../../../lib/linkedIssues.js";
18
- import { issueScope as _e, useCan as ve, useCanTriage as ye } from "../../../lib/roles.js";
19
- import { IssueDesigns as be } from "../../../components/Figma.js";
20
- import { customFieldsQuery as xe, hasValue as Se } from "../../../lib/customFields.js";
21
- import { useConfirm as Ce } from "../../../lib/confirm.js";
22
- import { issueTypesQuery as we, typeShows as Te, typesFor as Ee } from "../../../lib/issueTypes.js";
23
- import { TypeIcon as De } from "../../../components/IssueTypes.js";
24
- import { actorAvatar as Oe } from "../../../lib/avatar.js";
25
- import { IssueFields as ke } from "../../../components/CustomFields.js";
26
- import { PersonHoverCard as Ae } from "../../../components/PersonHoverCard.js";
27
- import { AttachButton as je, IssueAttachments as Me, UploadStatus as Ne, useAttachmentUpload as Pe } from "../../../components/Attachments.js";
28
- import { Editor as R } from "../../../components/Editor.js";
29
- import { IssueCode as Fe } from "../../../components/IssueCode.js";
30
- import { AgentWork as Ie } from "../../../components/AgentWork.js";
31
- import { AreaLink as Le } from "../../../components/AreaLink.js";
32
- import { useShortcuts as Re } from "../../../lib/shortcuts.js";
33
- import { Route as ze } from "./_identifier.js";
34
- import { rememberPage as Be } from "../../../lib/recent.js";
35
- import { useOthersOn as Ve, useReportLocation as He } from "../../../lib/live.js";
36
- import { useReadIssueNotifications as Ue } from "../../../lib/notifications.js";
37
- import { FavoriteStar as We } from "../../../components/FavoriteStar.js";
38
- import { caretColor as Ge, useCollabSession as Ke } from "../../../lib/collab.js";
39
- import { CollabEditor as qe } from "../../../components/CollabEditor.js";
40
- import { FieldNote as Je, Viewers as Ye } from "../../../components/Presence.js";
41
- import { Timeline as Xe } from "../../../components/ActivityTimeline.js";
42
- import { CustomerRequests as Ze } from "../../../components/CustomerRequests.js";
43
- import { IssueLinkChips as Qe, IssueLinks as $e, SharedThreadHeader as et } from "../../../components/GitHub.js";
44
- import { EventLine as tt } from "../../../components/IssueEvent.js";
45
- import { IssueIntercom as nt } from "../../../components/IssueIntercom.js";
46
- import { ParentProperty as rt, SubIssuesAndRelations as it } from "../../../components/IssueRelations.js";
47
- import { IssueSentry as at } from "../../../components/IssueSentry.js";
48
- import { IssueZendesk as ot } from "../../../components/IssueZendesk.js";
49
- import { Reactions as st } from "../../../components/Reactions.js";
50
- import { TimeInStatus as ct } from "../../../components/Reports.js";
51
- import { SubscribeButton as lt } from "../../../components/SubscribeButton.js";
52
- import { Widgets as ut } from "../../../components/Widgets.js";
53
- import { Avatar as dt, Button as z, Callout as ft, Card as pt, Combobox as B, CopyButton as mt, DatePicker as ht, ErrorText as gt, IconButton as _t, Kbd as vt, RelativeTime as yt, Select as V, TitleInput as bt, Tooltip as xt, buttonClasses as St, menuDivider as Ct, toast as wt, useOpenMenu as H } from "@parallelworks/ui";
54
- import { createContext as Tt, useCallback as Et, useContext as Dt, useEffect as Ot, useMemo as kt, useRef as U, useState as W } from "react";
55
- import { useErrorMessage as At } from "@parallelworks/problem/react";
56
- import { useFormatter as jt, useTranslations as G } from "use-intl";
2
+ import { invalidateIssueViews as n, useUpdateIssue as r } from "../../../api/mutations.js";
3
+ import { areasQuery as i, attachmentsQuery as a, commentsQuery as o, cyclesQuery as s, eventsQuery as c, issueDocsQuery as l, issueLinksQuery as u, issueQuery as d, labelsQuery as f, meQuery as p, projectsQuery as m, reactionsQuery as h, statusesQuery as g, teamsQuery as _ } from "../../../api/queries.js";
4
+ import { Timeline as v } from "../../../components/ActivityTimeline.js";
5
+ import { ActorLink as y } from "../../../components/ActorLink.js";
6
+ import { AgentPage as b } from "../../../components/AgentPage.js";
7
+ import { AgentWork as x } from "../../../components/AgentWork.js";
8
+ import { AreaLink as S } from "../../../components/AreaLink.js";
9
+ import { AttachButton as C, IssueAttachments as w, UploadStatus as T, useAttachmentUpload as E } from "../../../components/Attachments.js";
10
+ import { CollabEditor as D } from "../../../components/CollabEditor.js";
11
+ import { CustomerRequests as O } from "../../../components/CustomerRequests.js";
12
+ import { IssueFields as k } from "../../../components/CustomFields.js";
13
+ import { Editor as A } from "../../../components/Editor.js";
14
+ import { FavoriteStar as j } from "../../../components/FavoriteStar.js";
15
+ import { IssueDesigns as ee } from "../../../components/Figma.js";
16
+ import { IssueLinkChips as M, IssueLinks as te, SharedThreadHeader as N } from "../../../components/GitHub.js";
17
+ import { IssueCode as ne } from "../../../components/IssueCode.js";
18
+ import { EventLine as P } from "../../../components/IssueEvent.js";
19
+ import { IssueIntercom as re } from "../../../components/IssueIntercom.js";
20
+ import { ParentProperty as F, SubIssuesAndRelations as ie } from "../../../components/IssueRelations.js";
21
+ import { IssueSentry as ae } from "../../../components/IssueSentry.js";
22
+ import { TypeIcon as I } from "../../../components/IssueTypes.js";
23
+ import { IssueZendesk as oe } from "../../../components/IssueZendesk.js";
24
+ import { AreaIcon as L, BranchIcon as se, CalendarIcon as ce, CloseIcon as le, CycleIcon as ue, EstimateIcon as de, FileTextIcon as fe, InboxIcon as pe, PriorityIcon as me, ProjectIcon as he, StatusIcon as ge, TriageIcon as _e, usePriorityNames as ve } from "../../../components/icons.js";
25
+ import { PersonHoverCard as ye } from "../../../components/PersonHoverCard.js";
26
+ import { DueDate as be, ProjectStatusIcon as xe, SlaBadge as Se, scalePoints as Ce, useEstimateLabel as we } from "../../../components/Planning.js";
27
+ import { FieldNote as Te, Viewers as Ee } from "../../../components/Presence.js";
28
+ import { Reactions as De } from "../../../components/Reactions.js";
29
+ import { TimeInStatus as Oe } from "../../../components/Reports.js";
30
+ import { SubscribeButton as ke } from "../../../components/SubscribeButton.js";
31
+ import { Widgets as Ae } from "../../../components/Widgets.js";
32
+ import { assigneeKey as je, parseAssigneeKey as Me, useAssigneeOptions as Ne } from "../../../lib/assignees.js";
33
+ import { actorAvatar as Pe } from "../../../lib/avatar.js";
34
+ import { branchName as Fe } from "../../../lib/branch.js";
35
+ import { caretColor as Ie, useCollabSession as Le } from "../../../lib/collab.js";
36
+ import { useConfirm as Re } from "../../../lib/confirm.js";
37
+ import { customFieldsQuery as ze, hasValue as Be } from "../../../lib/customFields.js";
38
+ import { docRef as Ve, useDocMenu as He } from "../../../lib/docs.js";
39
+ import { issueURL as Ue, useIssueMenu as We } from "../../../lib/issueMenu.js";
40
+ import { issueTypesQuery as Ge, typeShows as Ke, typesFor as qe } from "../../../lib/issueTypes.js";
41
+ import { useLinkedIssues as Je } from "../../../lib/linkedIssues.js";
42
+ import { useOthersOn as Ye, useReportLocation as Xe } from "../../../lib/live.js";
43
+ import { copyItem as Ze } from "../../../lib/menus.js";
44
+ import { useReadIssueNotifications as Qe } from "../../../lib/notifications.js";
45
+ import { usePageTitle as $e } from "../../../lib/pageTitle.js";
46
+ import { connectorActor as et, usePeople as tt } from "../../../lib/people.js";
47
+ import { PickManyBox as nt, usePickMany as rt } from "../../../lib/pickMany.js";
48
+ import { rememberPage as it } from "../../../lib/recent.js";
49
+ import { issueScope as at, useCan as ot, useCanTriage as st } from "../../../lib/roles.js";
50
+ import { Link as R, useNavigate as ct } from "../../../lib/router.js";
51
+ import { useShortcuts as lt } from "../../../lib/shortcuts.js";
52
+ import { useTime as ut } from "../../../lib/time.js";
53
+ import { Route as dt } from "./_identifier.js";
54
+ import { Avatar as ft, Button as z, Callout as pt, Card as mt, Combobox as B, CopyButton as ht, DatePicker as gt, ErrorText as _t, IconButton as vt, Kbd as yt, RelativeTime as bt, Select as V, TitleInput as xt, Tooltip as St, buttonClasses as Ct, menuDivider as wt, toast as Tt, useOpenMenu as H } from "@parallelworks/ui";
55
+ import { createContext as Et, useCallback as Dt, useContext as Ot, useEffect as kt, useMemo as At, useRef as U, useState as W } from "react";
56
+ import { useErrorMessage as jt } from "@parallelworks/problem/react";
57
+ import { useFormatter as Mt, useTranslations as G } from "use-intl";
57
58
  import { Fragment as K, jsx as q, jsxs as J } from "react/jsx-runtime";
58
59
  import { useMutation as Y, useQuery as X, useQueryClient as Z, useSuspenseQuery as Q } from "@tanstack/react-query";
59
- import { MoreButton as Mt } from "@parallelworks/ui/list";
60
- import { ArchiveIcon as Nt } from "@parallelworks/ui/icons";
60
+ import { MoreButton as Nt } from "@parallelworks/ui/list";
61
+ import { ArchiveIcon as Pt } from "@parallelworks/ui/icons";
61
62
  // src/routes/$workspace/issues/$identifier.tsx?tsr-split=component
62
- function Pt() {
63
- let o = G("issue"), s = ne(), c = At(), l = G("common"), { workspace: u, identifier: d } = ze.useParams(), { data: m } = Q(p(u, d)), { data: g } = Q(y(u)), { data: _ } = Q(h), { data: v = [] } = X(f(u, d)), [S, C] = W();
64
- He({
65
- identifier: m.identifier,
66
- ...S && { field: S }
67
- }), r(`${m.identifier} ${m.title}`), Ue(u, m.identifier);
68
- let w = a(), T = n(m.identifier, m.title);
69
- Ot(() => {
70
- window.location.pathname.endsWith(`/issues/${T}`) || w({
63
+ function Ft() {
64
+ let i = G("issue"), a = ut(), o = jt(), s = G("common"), { workspace: c, identifier: l } = dt.useParams(), { data: f } = Q(d(c, l)), { data: m } = Q(_(c)), { data: h } = Q(p), { data: g = [] } = X(u(c, l)), [v, y] = W();
65
+ Xe({
66
+ identifier: f.identifier,
67
+ ...v && { field: v }
68
+ }), $e(`${f.identifier} ${f.title}`), Qe(c, f.identifier);
69
+ let b = ct(), S = Fe(f.identifier, f.title);
70
+ kt(() => {
71
+ window.location.pathname.endsWith(`/issues/${S}`) || b({
71
72
  to: "/$workspace/issues/$identifier",
72
73
  params: {
73
- workspace: u,
74
- identifier: m.identifier
74
+ workspace: c,
75
+ identifier: f.identifier
75
76
  },
76
77
  search: !0,
77
78
  hash: !0,
78
79
  replace: !0
79
80
  });
80
81
  }, [
81
- T,
82
- w,
83
- u,
84
- m.identifier
82
+ S,
83
+ b,
84
+ c,
85
+ f.identifier
85
86
  ]);
86
- let D = ve(u, "delete_issues", _e(m)), O = Z(), { confirm: k, dialog: A } = Ce(), j = Y({
87
+ let C = ot(c, "delete_issues", at(f)), T = Z(), { confirm: E, dialog: D } = Re(), k = Y({
87
88
  mutationFn: async () => t(await e.POST("/api/v1/workspaces/{workspace}/issues/{identifier}/restore", { params: { path: {
88
- workspace: u,
89
- identifier: m.identifier
89
+ workspace: c,
90
+ identifier: f.identifier
90
91
  } } })),
91
92
  onSuccess: (e) => {
92
- O.setQueryData(p(u, m.identifier).queryKey, e), b(O, u, m.identifier);
93
+ T.setQueryData(d(c, f.identifier).queryKey, e), n(T, c, f.identifier);
93
94
  }
94
- }), M = Y({
95
+ }), A = Y({
95
96
  mutationFn: async () => t(await e.DELETE("/api/v1/workspaces/{workspace}/issues/{identifier}", { params: { path: {
96
- workspace: u,
97
- identifier: m.identifier
97
+ workspace: c,
98
+ identifier: f.identifier
98
99
  } } })),
99
100
  onSuccess: () => {
100
- wt.success(o("deleted", { identifier: m.identifier })), b(O, u);
101
- let e = g.find((e) => e.id === m.teamId)?.key;
102
- w(e ? {
101
+ Tt.success(i("deleted", { identifier: f.identifier })), n(T, c);
102
+ let e = m.find((e) => e.id === f.teamId)?.key;
103
+ b(e ? {
103
104
  to: "/$workspace/teams/$key/issues",
104
105
  params: {
105
- workspace: u,
106
+ workspace: c,
106
107
  key: e
107
108
  }
108
109
  } : {
109
110
  to: "/$workspace/issues",
110
- params: { workspace: u }
111
+ params: { workspace: c }
111
112
  });
112
113
  }
113
- }), N = Et((e) => w({
114
+ }), te = Dt((e) => b({
114
115
  to: "/$workspace/issues/$identifier",
115
116
  params: {
116
- workspace: u,
117
+ workspace: c,
117
118
  identifier: e
118
119
  }
119
- }), [w, u]);
120
- ge(u, m.body, N), Ot(() => {
121
- Be(u, {
120
+ }), [b, c]);
121
+ Je(c, f.body, te), kt(() => {
122
+ it(c, {
122
123
  kind: "issue",
123
- href: `/${u}/issues/${m.identifier}`,
124
- label: `${m.identifier} ${m.title}`
124
+ href: `/${c}/issues/${f.identifier}`,
125
+ label: `${f.identifier} ${f.title}`
125
126
  });
126
127
  }, [
127
- u,
128
- m.identifier,
129
- m.title
128
+ c,
129
+ f.identifier,
130
+ f.title
130
131
  ]);
131
- let P = Ve({ issue: m.identifier }, _?.user.username), F = g.find((e) => e.id === m.teamId), I = x(u, d), [ee, L] = W(null), te = H(), re = he(u);
132
- return Re({
132
+ let N = Ye({ issue: f.identifier }, h?.user.username), P = m.find((e) => e.id === f.teamId), F = r(c, l), [I, L] = W(null), ce = H(), le = We(c);
133
+ return lt({
133
134
  s: () => L("status"),
134
135
  p: () => L("priority"),
135
136
  a: () => L("assignees"),
136
137
  l: () => L("labels"),
137
- Escape: () => w({
138
+ Escape: () => b({
138
139
  to: "/$workspace/issues",
139
- params: { workspace: u }
140
+ params: { workspace: c }
140
141
  })
141
- }, ee === null), /* @__PURE__ */ J("div", {
142
+ }, I === null), /* @__PURE__ */ J("div", {
142
143
  className: "flex h-full flex-col",
143
144
  children: [
144
145
  /* @__PURE__ */ J("header", {
145
146
  className: "flex h-12 shrink-0 items-center gap-2 border-b border-border px-4 text-sm md:px-5",
146
- onContextMenu: (e) => te(e, re([m])),
147
+ onContextMenu: (e) => ce(e, le([f])),
147
148
  children: [
148
- /* @__PURE__ */ q(i, {
149
- to: F ? "/$workspace/teams/$key/issues" : "/$workspace/issues",
149
+ /* @__PURE__ */ q(R, {
150
+ to: P ? "/$workspace/teams/$key/issues" : "/$workspace/issues",
150
151
  params: {
151
- workspace: u,
152
- key: F?.key ?? ""
152
+ workspace: c,
153
+ key: P?.key ?? ""
153
154
  },
154
155
  className: "text-muted-foreground hover:text-foreground",
155
- children: F?.name ?? o("issues")
156
+ children: P?.name ?? i("issues")
156
157
  }),
157
158
  /* @__PURE__ */ q("span", {
158
159
  className: "text-muted-foreground",
@@ -161,63 +162,63 @@ function Pt() {
161
162
  }),
162
163
  /* @__PURE__ */ q("span", {
163
164
  className: "shrink-0 font-medium whitespace-nowrap",
164
- children: m.identifier
165
+ children: f.identifier
165
166
  }),
166
- /* @__PURE__ */ q(We, {
167
- workspace: u,
167
+ /* @__PURE__ */ q(j, {
168
+ workspace: c,
168
169
  kind: "issue",
169
- target: m.id
170
+ target: f.id
170
171
  }),
171
- /* @__PURE__ */ q(lt, {
172
- workspace: u,
173
- identifier: m.identifier
172
+ /* @__PURE__ */ q(ke, {
173
+ workspace: c,
174
+ identifier: f.identifier
174
175
  }),
175
- /* @__PURE__ */ q(mt, {
176
- text: n(m.identifier, m.title),
177
- label: o("copyBranchName"),
178
- icon: /* @__PURE__ */ q(E, {}),
176
+ /* @__PURE__ */ q(ht, {
177
+ text: Fe(f.identifier, f.title),
178
+ label: i("copyBranchName"),
179
+ icon: /* @__PURE__ */ q(se, {}),
179
180
  size: "sm",
180
181
  variant: "ghost",
181
- success: o("copiedBranchName", { name: n(m.identifier, m.title) }),
182
- failure: o("copyFailed"),
182
+ success: i("copiedBranchName", { name: Fe(f.identifier, f.title) }),
183
+ failure: i("copyFailed"),
183
184
  className: "max-sm:hidden"
184
185
  }),
185
- /* @__PURE__ */ q(Qe, { links: v }),
186
+ /* @__PURE__ */ q(M, { links: g }),
186
187
  /* @__PURE__ */ J("span", {
187
188
  className: "ml-auto flex items-center gap-3",
188
189
  children: [
189
- I.isPending && /* @__PURE__ */ q("span", {
190
+ F.isPending && /* @__PURE__ */ q("span", {
190
191
  className: "text-xs text-muted-foreground",
191
- children: l("saving")
192
+ children: s("saving")
192
193
  }),
193
- /* @__PURE__ */ q(Ye, {
194
- workspace: u,
195
- others: P
194
+ /* @__PURE__ */ q(Ee, {
195
+ workspace: c,
196
+ others: N
196
197
  }),
197
- /* @__PURE__ */ q(Mt, {
198
- items: () => [...re([m]), ...D ? [{
199
- label: o("deleteIssue"),
198
+ /* @__PURE__ */ q(Nt, {
199
+ items: () => [...le([f]), ...C ? [{
200
+ label: i("deleteIssue"),
200
201
  destructive: !0,
201
- onClick: () => k({
202
- title: o("deleteTitle", { identifier: m.identifier }),
203
- description: o("deleteDescription"),
204
- confirmLabel: o("deleteIssue"),
205
- onConfirm: () => M.mutateAsync()
202
+ onClick: () => E({
203
+ title: i("deleteTitle", { identifier: f.identifier }),
204
+ description: i("deleteDescription"),
205
+ confirmLabel: i("deleteIssue"),
206
+ onConfirm: () => A.mutateAsync()
206
207
  })
207
208
  }] : []],
208
- label: l("moreActionsFor", { name: m.identifier }),
209
+ label: s("moreActionsFor", { name: f.identifier }),
209
210
  visible: !0
210
211
  })
211
212
  ]
212
213
  }),
213
- I.isError && /* @__PURE__ */ q(gt, {
214
+ F.isError && /* @__PURE__ */ q(_t, {
214
215
  inline: !0,
215
216
  className: "ml-auto text-xs",
216
- children: c(I.error)
217
+ children: o(F.error)
217
218
  })
218
219
  ]
219
220
  }),
220
- A,
221
+ D,
221
222
  /* @__PURE__ */ J("div", {
222
223
  className: "flex min-h-0 flex-1 flex-col overflow-y-auto md:flex-row md:overflow-hidden",
223
224
  children: [/* @__PURE__ */ q("div", {
@@ -225,115 +226,115 @@ function Pt() {
225
226
  children: /* @__PURE__ */ J("article", {
226
227
  className: "w-full px-4 pt-6 pb-24 md:px-8 md:pt-8",
227
228
  children: [
228
- /* @__PURE__ */ J(Zt.Provider, {
229
- value: C,
229
+ /* @__PURE__ */ J(Qt.Provider, {
230
+ value: y,
230
231
  children: [
231
- m.triage && /* @__PURE__ */ q(Ft, {
232
- workspace: u,
233
- issue: m
232
+ f.triage && /* @__PURE__ */ q(It, {
233
+ workspace: c,
234
+ issue: f
234
235
  }),
235
- m.archivedAt && /* @__PURE__ */ q(ft, {
236
+ f.archivedAt && /* @__PURE__ */ q(pt, {
236
237
  tone: "muted",
237
- icon: /* @__PURE__ */ q(Nt, {}),
238
+ icon: /* @__PURE__ */ q(Pt, {}),
238
239
  className: "mb-5",
239
240
  children: /* @__PURE__ */ J("span", {
240
241
  className: "flex flex-wrap items-center gap-x-3 gap-y-1",
241
- children: [o("archivedNote", { when: s.day(m.archivedAt.slice(0, 10)) }), /* @__PURE__ */ q(z, {
242
+ children: [i("archivedNote", { when: a.day(f.archivedAt.slice(0, 10)) }), /* @__PURE__ */ q(z, {
242
243
  type: "button",
243
244
  size: "sm",
244
- onClick: () => j.mutate(),
245
- loading: j.isPending,
246
- children: o("restore")
245
+ onClick: () => k.mutate(),
246
+ loading: k.isPending,
247
+ children: i("restore")
247
248
  })]
248
249
  })
249
250
  }),
250
- /* @__PURE__ */ q(It, {
251
- issue: m,
252
- onSave: (e) => I.mutate({ title: e })
251
+ /* @__PURE__ */ q(Lt, {
252
+ issue: f,
253
+ onSave: (e) => F.mutate({ title: e })
253
254
  }),
254
- /* @__PURE__ */ q(Je, {
255
- workspace: u,
256
- others: P,
255
+ /* @__PURE__ */ q(Te, {
256
+ workspace: c,
257
+ others: N,
257
258
  field: "title"
258
259
  }),
259
- /* @__PURE__ */ q(Lt, {
260
- workspace: u,
261
- issue: m
260
+ /* @__PURE__ */ q(Rt, {
261
+ workspace: c,
262
+ issue: f
262
263
  }),
263
- /* @__PURE__ */ q(Je, {
264
- workspace: u,
265
- others: P,
264
+ /* @__PURE__ */ q(Te, {
265
+ workspace: c,
266
+ others: N,
266
267
  field: "body"
267
268
  }),
268
- /* @__PURE__ */ q(it, {
269
- workspace: u,
270
- issue: m
269
+ /* @__PURE__ */ q(ie, {
270
+ workspace: c,
271
+ issue: f
271
272
  }),
272
- /* @__PURE__ */ q(Ze, {
273
- workspace: u,
274
- identifier: m.identifier,
275
- enabled: !!F?.customerRequestsEnabled
273
+ /* @__PURE__ */ q(O, {
274
+ workspace: c,
275
+ identifier: f.identifier,
276
+ enabled: !!P?.customerRequestsEnabled
276
277
  }),
277
- /* @__PURE__ */ q(Rt, {
278
- workspace: u,
279
- identifier: d
278
+ /* @__PURE__ */ q(zt, {
279
+ workspace: c,
280
+ identifier: l
280
281
  }),
281
- /* @__PURE__ */ q(be, {
282
- workspace: u,
283
- identifier: d
282
+ /* @__PURE__ */ q(ee, {
283
+ workspace: c,
284
+ identifier: l
284
285
  }),
285
- /* @__PURE__ */ q(Fe, {
286
- workspace: u,
287
- identifier: d,
288
- title: m.title
286
+ /* @__PURE__ */ q(ne, {
287
+ workspace: c,
288
+ identifier: l,
289
+ title: f.title
289
290
  }),
290
- /* @__PURE__ */ q(ot, {
291
- workspace: u,
292
- identifier: d
291
+ /* @__PURE__ */ q(oe, {
292
+ workspace: c,
293
+ identifier: l
293
294
  }),
294
- /* @__PURE__ */ q(at, {
295
- workspace: u,
296
- identifier: d
295
+ /* @__PURE__ */ q(ae, {
296
+ workspace: c,
297
+ identifier: l
297
298
  }),
298
- /* @__PURE__ */ q(nt, {
299
- workspace: u,
300
- identifier: d
299
+ /* @__PURE__ */ q(re, {
300
+ workspace: c,
301
+ identifier: l
301
302
  }),
302
- /* @__PURE__ */ q(Ie, {
303
- workspace: u,
304
- identifier: d
303
+ /* @__PURE__ */ q(x, {
304
+ workspace: c,
305
+ identifier: l
305
306
  }),
306
- /* @__PURE__ */ q(Gt, {
307
- workspace: u,
308
- identifier: d,
309
- others: P
307
+ /* @__PURE__ */ q(Kt, {
308
+ workspace: c,
309
+ identifier: l,
310
+ others: N
310
311
  })
311
312
  ]
312
313
  }),
313
- /* @__PURE__ */ q(Wt, {
314
- workspace: u,
315
- identifier: d
314
+ /* @__PURE__ */ q(Gt, {
315
+ workspace: c,
316
+ identifier: l
316
317
  }),
317
- /* @__PURE__ */ q(Me, {
318
- workspace: u,
319
- identifier: d
318
+ /* @__PURE__ */ q(w, {
319
+ workspace: c,
320
+ identifier: l
320
321
  })
321
322
  ]
322
323
  })
323
- }), /* @__PURE__ */ q(zt, {
324
- workspace: u,
325
- issue: m,
326
- team: F,
327
- open: ee,
324
+ }), /* @__PURE__ */ q(Bt, {
325
+ workspace: c,
326
+ issue: f,
327
+ team: P,
328
+ open: I,
328
329
  setOpen: L,
329
- update: (e) => I.mutate(e)
330
+ update: (e) => F.mutate(e)
330
331
  })]
331
332
  })
332
333
  ]
333
334
  });
334
335
  }
335
- function Ft({ workspace: n, issue: r }) {
336
- let i = G("triage"), a = At(), o = Z(), s = ye(n, r.teamId), c = Y({
336
+ function It({ workspace: n, issue: r }) {
337
+ let i = G("triage"), a = jt(), o = Z(), s = st(n, r.teamId), c = Y({
337
338
  mutationFn: async (i) => t(await e.POST("/api/v1/workspaces/{workspace}/issues/{identifier}/triage", {
338
339
  params: { path: {
339
340
  workspace: n,
@@ -350,7 +351,7 @@ function Ft({ workspace: n, issue: r }) {
350
351
  return /* @__PURE__ */ J("div", {
351
352
  className: "mb-5 flex flex-wrap items-center gap-3 rounded-xl border border-border bg-muted/40 px-4 py-3",
352
353
  children: [
353
- /* @__PURE__ */ q(I, { className: "size-4 shrink-0 text-muted-foreground" }),
354
+ /* @__PURE__ */ q(_e, { className: "size-4 shrink-0 text-muted-foreground" }),
354
355
  /* @__PURE__ */ q("p", {
355
356
  className: "min-w-0 flex-1 text-sm",
356
357
  children: i("waiting")
@@ -378,12 +379,12 @@ function Ft({ workspace: n, issue: r }) {
378
379
  ]
379
380
  });
380
381
  }
381
- function It({ issue: e, onSave: t }) {
382
- let n = G("issue"), r = Dt(Zt);
382
+ function Lt({ issue: e, onSave: t }) {
383
+ let n = G("issue"), r = Ot(Qt);
383
384
  return /* @__PURE__ */ J(K, { children: [/* @__PURE__ */ q("h1", {
384
385
  className: "sr-only",
385
386
  children: e.title
386
- }), /* @__PURE__ */ q(bt, {
387
+ }), /* @__PURE__ */ q(xt, {
387
388
  value: e.title,
388
389
  onCommit: t,
389
390
  onFocus: () => r("title"),
@@ -391,24 +392,24 @@ function It({ issue: e, onSave: t }) {
391
392
  "aria-label": n("title")
392
393
  })] });
393
394
  }
394
- function Lt({ workspace: e, issue: t }) {
395
- let n = G("issue"), r = G("common"), i = Dt(Zt), { data: a } = Q(h), o = U(null), s = kt(() => ({
395
+ function Rt({ workspace: e, issue: t }) {
396
+ let n = G("issue"), r = G("common"), i = Ot(Qt), { data: a } = Q(p), o = U(null), s = At(() => ({
396
397
  name: a?.user.name ?? n("someone"),
397
- color: Ge(a?.user.username ?? "")
398
+ color: Ie(a?.user.username ?? "")
398
399
  }), [
399
400
  a?.user.name,
400
401
  a?.user.username,
401
402
  n
402
- ]), { session: c, error: l } = Ke({
403
+ ]), { session: c, error: l } = Le({
403
404
  workspace: e,
404
405
  target: { issue: t.identifier },
405
406
  user: s,
406
407
  getMarkdown: o
407
- }), u = U(null), d = Pe(e, t.identifier), { data: f = [] } = X(_(e, t.identifier)), p = ve(e, "comment", _e(t));
408
+ }), u = U(null), d = E(e, t.identifier), { data: f = [] } = X(h(e, t.identifier)), m = ot(e, "comment", at(t));
408
409
  return /* @__PURE__ */ J("div", {
409
410
  className: "group mt-4 min-h-32",
410
411
  children: [
411
- c ? /* @__PURE__ */ q(qe, {
412
+ c ? /* @__PURE__ */ q(D, {
412
413
  session: c,
413
414
  user: s,
414
415
  getMarkdown: o,
@@ -421,34 +422,34 @@ function Lt({ workspace: e, issue: t }) {
421
422
  placeholder: n("addDescription"),
422
423
  label: r("description"),
423
424
  className: "min-h-32"
424
- }, `${c.generation}:${c.doc.guid}`) : /* @__PURE__ */ q(R, {
425
+ }, `${c.generation}:${c.doc.guid}`) : /* @__PURE__ */ q(A, {
425
426
  value: t.body,
426
427
  editable: !1,
427
428
  className: "min-h-32"
428
429
  }),
429
- /* @__PURE__ */ q(gt, {
430
+ /* @__PURE__ */ q(_t, {
430
431
  className: "mt-1",
431
432
  children: l
432
433
  }),
433
434
  c && /* @__PURE__ */ J("div", {
434
435
  className: "mt-1 flex items-center justify-end gap-2",
435
- children: [/* @__PURE__ */ q(Ne, {
436
+ children: [/* @__PURE__ */ q(T, {
436
437
  pending: d.pending,
437
438
  error: d.error
438
- }), /* @__PURE__ */ q(je, { onFiles: (e) => d.upload(u.current, e) })]
439
+ }), /* @__PURE__ */ q(C, { onFiles: (e) => d.upload(u.current, e) })]
439
440
  }),
440
- /* @__PURE__ */ q(st, {
441
+ /* @__PURE__ */ q(De, {
441
442
  workspace: e,
442
443
  identifier: t.identifier,
443
444
  reactions: f,
444
445
  me: a?.user.username,
445
- disabled: !p
446
+ disabled: !m
446
447
  })
447
448
  ]
448
449
  });
449
450
  }
450
- function Rt({ workspace: e, identifier: t }) {
451
- let n = G("issue"), { data: r } = Q(d(e, t)), a = H(), o = w(e);
451
+ function zt({ workspace: e, identifier: t }) {
452
+ let n = G("issue"), { data: r } = Q(l(e, t)), i = H(), a = He(e);
452
453
  return r.length === 0 ? null : /* @__PURE__ */ J("section", {
453
454
  className: "mt-6",
454
455
  "aria-label": n("docs"),
@@ -457,15 +458,15 @@ function Rt({ workspace: e, identifier: t }) {
457
458
  children: n("docs")
458
459
  }), /* @__PURE__ */ q("ul", {
459
460
  className: "mt-1 flex flex-wrap gap-1.5",
460
- children: r.map((t) => /* @__PURE__ */ q("li", { children: /* @__PURE__ */ J(i, {
461
+ children: r.map((t) => /* @__PURE__ */ q("li", { children: /* @__PURE__ */ J(R, {
461
462
  to: "/$workspace/docs/$doc",
462
463
  params: {
463
464
  workspace: e,
464
- doc: C(t)
465
+ doc: Ve(t)
465
466
  },
466
- onContextMenu: (e) => a(e, o(t)),
467
- className: `${St({ size: "sm" })} max-w-72`,
468
- children: [/* @__PURE__ */ q(j, { className: "size-3.5 text-muted-foreground" }), /* @__PURE__ */ q("span", {
467
+ onContextMenu: (e) => i(e, a(t)),
468
+ className: `${Ct({ size: "sm" })} max-w-72`,
469
+ children: [/* @__PURE__ */ q(fe, { className: "size-3.5 text-muted-foreground" }), /* @__PURE__ */ q("span", {
469
470
  className: "truncate",
470
471
  children: t.title
471
472
  })]
@@ -473,61 +474,61 @@ function Rt({ workspace: e, identifier: t }) {
473
474
  })]
474
475
  });
475
476
  }
476
- function zt({ workspace: n, issue: r, team: i, open: o, setOpen: s, update: c }) {
477
- let l = G("relations"), u = i?.key, d = G("issue.properties"), p = G("common"), h = ee(), { data: g = [] } = X({
478
- ...v(n, u ?? ""),
479
- enabled: !!u
480
- }), { data: _ = [] } = X(m(n)), { data: y = [] } = X(f(n, r.identifier)), { nameOf: b, actorName: x, avatarOf: S } = te(n), C = Z(), w = Y({
477
+ function Bt({ workspace: n, issue: r, team: i, open: a, setOpen: o, update: s }) {
478
+ let c = G("relations"), l = i?.key, d = G("issue.properties"), p = G("common"), m = ve(), { data: h = [] } = X({
479
+ ...g(n, l ?? ""),
480
+ enabled: !!l
481
+ }), { data: _ = [] } = X(f(n)), { data: v = [] } = X(u(n, r.identifier)), { nameOf: y, actorName: b, avatarOf: x } = tt(n), S = Z(), C = Y({
481
482
  mutationFn: async (r) => t(await e.POST("/api/v1/workspaces/{workspace}/labels", {
482
483
  params: { path: { workspace: n } },
483
484
  body: {
484
485
  name: r,
485
- color: Bt[_.length % Bt.length] ?? "#d73a4a"
486
+ color: Vt[_.length % Vt.length] ?? "#d73a4a"
486
487
  }
487
488
  })),
488
489
  onSuccess: (e) => {
489
- C.invalidateQueries({ queryKey: m(n).queryKey }), c({ addLabels: [e.id] });
490
+ S.invalidateQueries({ queryKey: f(n).queryKey }), s({ addLabels: [e.id] });
490
491
  }
491
- }), T = r.assignees.map(de), E = pe(n, !0), D = (e) => (t) => s(t ? e : null), O = ue(o === "assignees", () => s(null)), k = ue(o === "labels", () => s(null)), A = "flex h-8 w-full items-center gap-2 rounded-md px-2 text-sm hover:bg-muted", j = H(), M = he(n), P = a(), I = (e, t) => {
492
+ }), w = r.assignees.map(je), T = Ne(n, !0), E = (e) => (t) => o(t ? e : null), D = rt(a === "assignees", () => o(null)), O = rt(a === "labels", () => o(null)), A = "flex h-8 w-full items-center gap-2 rounded-md px-2 text-sm hover:bg-muted", j = H(), ee = We(n), M = ct(), N = (e, t) => {
492
493
  e.stopPropagation(), j(e, t);
493
494
  };
494
495
  return /* @__PURE__ */ J("aside", {
495
496
  className: "order-first grid shrink-0 grid-cols-2 gap-4 border-b border-border px-4 py-4 md:order-none md:block md:w-72 md:space-y-5 md:overflow-y-auto md:border-b-0 md:border-l md:py-6",
496
497
  "aria-label": d("title"),
497
- onContextMenu: (e) => j(e, M([r])),
498
+ onContextMenu: (e) => j(e, ee([r])),
498
499
  children: [
499
500
  /* @__PURE__ */ q($, {
500
501
  label: p("status"),
501
502
  shortcut: "S",
502
503
  children: /* @__PURE__ */ q(B, {
503
504
  "aria-label": p("status"),
504
- open: o === "status",
505
- onOpenChange: D("status"),
506
- items: g.map((e) => ({
505
+ open: a === "status",
506
+ onOpenChange: E("status"),
507
+ items: h.map((e) => ({
507
508
  value: e.id,
508
509
  label: e.name,
509
- icon: /* @__PURE__ */ q(F, {
510
+ icon: /* @__PURE__ */ q(ge, {
510
511
  category: e.category,
511
512
  step: e.step
512
513
  })
513
514
  })),
514
515
  value: r.status.id,
515
- onValueChange: (e) => e !== null && e !== r.status.id && c({ statusId: e }),
516
+ onValueChange: (e) => e !== null && e !== r.status.id && s({ statusId: e }),
516
517
  placeholder: d("changeStatus"),
517
518
  trigger: /* @__PURE__ */ J("button", {
518
519
  type: "button",
519
520
  className: A,
520
- children: [/* @__PURE__ */ q(F, {
521
+ children: [/* @__PURE__ */ q(ge, {
521
522
  category: r.status.category,
522
523
  step: r.status.step
523
524
  }), r.status.name]
524
525
  })
525
526
  })
526
527
  }),
527
- /* @__PURE__ */ q(Ut, {
528
+ /* @__PURE__ */ q(Wt, {
528
529
  workspace: n,
529
530
  issue: r,
530
- update: c,
531
+ update: s,
531
532
  row: A
532
533
  }),
533
534
  /* @__PURE__ */ q($, {
@@ -535,8 +536,8 @@ function zt({ workspace: n, issue: r, team: i, open: o, setOpen: s, update: c })
535
536
  shortcut: "P",
536
537
  children: /* @__PURE__ */ q(B, {
537
538
  "aria-label": p("priority"),
538
- open: o === "priority",
539
- onOpenChange: D("priority"),
539
+ open: a === "priority",
540
+ onOpenChange: E("priority"),
540
541
  items: [
541
542
  1,
542
543
  2,
@@ -545,16 +546,16 @@ function zt({ workspace: n, issue: r, team: i, open: o, setOpen: s, update: c })
545
546
  0
546
547
  ].map((e) => ({
547
548
  value: String(e),
548
- label: h[e] ?? "",
549
- icon: /* @__PURE__ */ q(N, { priority: e })
549
+ label: m[e] ?? "",
550
+ icon: /* @__PURE__ */ q(me, { priority: e })
550
551
  })),
551
552
  value: String(r.priority),
552
- onValueChange: (e) => e !== null && c({ priority: Number(e) }),
553
+ onValueChange: (e) => e !== null && s({ priority: Number(e) }),
553
554
  placeholder: d("setPriority"),
554
555
  trigger: /* @__PURE__ */ J("button", {
555
556
  type: "button",
556
557
  className: A,
557
- children: [/* @__PURE__ */ q(N, { priority: r.priority }), h[r.priority]]
558
+ children: [/* @__PURE__ */ q(me, { priority: r.priority }), m[r.priority]]
558
559
  })
559
560
  })
560
561
  }),
@@ -564,16 +565,16 @@ function zt({ workspace: n, issue: r, team: i, open: o, setOpen: s, update: c })
564
565
  children: /* @__PURE__ */ q(B, {
565
566
  "aria-label": d("assignees"),
566
567
  multiple: !0,
567
- open: o === "assignees",
568
- onOpenChange: D("assignees"),
569
- items: E,
570
- value: T,
568
+ open: a === "assignees",
569
+ onOpenChange: E("assignees"),
570
+ items: T,
571
+ value: w,
571
572
  onValueChange: (e) => {
572
- let t = e.filter((e) => !T.includes(e)), n = T.filter((t) => !e.includes(t));
573
- c({
574
- ...t.length > 0 && { addAssignees: t.map(fe) },
575
- ...n.length > 0 && { removeAssignees: n.map(fe) }
576
- }), O();
573
+ let t = e.filter((e) => !w.includes(e)), n = w.filter((t) => !e.includes(t));
574
+ s({
575
+ ...t.length > 0 && { addAssignees: t.map(Me) },
576
+ ...n.length > 0 && { removeAssignees: n.map(Me) }
577
+ }), D();
577
578
  },
578
579
  placeholder: d("assignTo"),
579
580
  trigger: /* @__PURE__ */ J("button", {
@@ -583,17 +584,17 @@ function zt({ workspace: n, issue: r, team: i, open: o, setOpen: s, update: c })
583
584
  className: "text-muted-foreground",
584
585
  children: d("unassigned")
585
586
  }), r.assignees.map((e) => {
586
- let t = b(e.kind, e.handle);
587
+ let t = y(e.kind, e.handle);
587
588
  return /* @__PURE__ */ q("span", {
588
- onContextMenu: (r) => I(r, [{
589
+ onContextMenu: (r) => N(r, [{
589
590
  label: d("unassign", { name: t }),
590
- onClick: () => c({ removeAssignees: [{
591
+ onClick: () => s({ removeAssignees: [{
591
592
  kind: e.kind,
592
593
  handle: e.handle
593
594
  }] })
594
595
  }, {
595
596
  label: d("viewTheirIssues"),
596
- onClick: () => P({
597
+ onClick: () => M({
597
598
  to: "/$workspace/issues",
598
599
  params: { workspace: n },
599
600
  search: {
@@ -603,15 +604,15 @@ function zt({ workspace: n, issue: r, team: i, open: o, setOpen: s, update: c })
603
604
  })
604
605
  }]),
605
606
  className: "flex items-center gap-1.5",
606
- children: /* @__PURE__ */ J(Ae, {
607
+ children: /* @__PURE__ */ J(ye, {
607
608
  workspace: n,
608
609
  kind: e.kind,
609
610
  handle: e.handle,
610
611
  className: "flex items-center gap-1.5",
611
- children: [/* @__PURE__ */ q(dt, {
612
- ...Oe(e.kind),
612
+ children: [/* @__PURE__ */ q(ft, {
613
+ ...Pe(e.kind),
613
614
  name: t,
614
- src: S(e.kind, e.handle),
615
+ src: x(e.kind, e.handle),
615
616
  size: "xs",
616
617
  decorative: !0
617
618
  }), t]
@@ -627,14 +628,14 @@ function zt({ workspace: n, issue: r, team: i, open: o, setOpen: s, update: c })
627
628
  children: /* @__PURE__ */ q(B, {
628
629
  "aria-label": p("labels"),
629
630
  multiple: !0,
630
- open: o === "labels",
631
- onOpenChange: D("labels"),
631
+ open: a === "labels",
632
+ onOpenChange: E("labels"),
632
633
  items: _.map((e) => ({
633
634
  value: e.id,
634
635
  label: e.name,
635
636
  icon: /* @__PURE__ */ J("span", {
636
637
  className: "flex items-center gap-2",
637
- children: [/* @__PURE__ */ q(le, {}), /* @__PURE__ */ q("span", {
638
+ children: [/* @__PURE__ */ q(nt, {}), /* @__PURE__ */ q("span", {
638
639
  className: "size-2.5 rounded-full",
639
640
  style: { background: e.color }
640
641
  })]
@@ -642,14 +643,14 @@ function zt({ workspace: n, issue: r, team: i, open: o, setOpen: s, update: c })
642
643
  })),
643
644
  value: r.labels.map((e) => e.id),
644
645
  onValueChange: (e) => {
645
- k();
646
+ O();
646
647
  let t = r.labels.map((e) => e.id), n = e.filter((e) => !t.includes(e)), i = t.filter((t) => !e.includes(t));
647
- c({
648
+ s({
648
649
  ...n.length > 0 && { addLabels: n },
649
650
  ...i.length > 0 && { removeLabels: i }
650
651
  });
651
652
  },
652
- onCreate: (e) => w.mutate(e),
653
+ onCreate: (e) => C.mutate(e),
653
654
  placeholder: d("addLabels"),
654
655
  trigger: /* @__PURE__ */ J("button", {
655
656
  type: "button",
@@ -658,12 +659,12 @@ function zt({ workspace: n, issue: r, team: i, open: o, setOpen: s, update: c })
658
659
  className: "text-muted-foreground",
659
660
  children: d("noLabels")
660
661
  }), r.labels.map((e) => /* @__PURE__ */ J("span", {
661
- onContextMenu: (t) => I(t, [{
662
+ onContextMenu: (t) => N(t, [{
662
663
  label: d("removeLabel", { name: e.name }),
663
- onClick: () => c({ removeLabels: [e.id] })
664
+ onClick: () => s({ removeLabels: [e.id] })
664
665
  }, {
665
666
  label: d("viewLabelIssues"),
666
- onClick: () => P({
667
+ onClick: () => M({
667
668
  to: "/$workspace/issues",
668
669
  params: { workspace: n },
669
670
  search: { label: e.name }
@@ -683,36 +684,36 @@ function zt({ workspace: n, issue: r, team: i, open: o, setOpen: s, update: c })
683
684
  })
684
685
  }),
685
686
  /* @__PURE__ */ q($, {
686
- label: l("parent"),
687
- children: /* @__PURE__ */ q(rt, {
687
+ label: c("parent"),
688
+ children: /* @__PURE__ */ q(F, {
688
689
  workspace: n,
689
690
  issue: r,
690
691
  row: A
691
692
  })
692
693
  }),
693
- /* @__PURE__ */ q(Ht, {
694
+ /* @__PURE__ */ q(Ut, {
694
695
  workspace: n,
695
696
  issue: r,
696
697
  team: i,
697
- update: c,
698
+ update: s,
698
699
  row: A
699
700
  }),
700
701
  /* @__PURE__ */ q($, {
701
702
  label: d("created"),
702
703
  children: /* @__PURE__ */ J("p", {
703
704
  className: "flex items-center gap-2 px-2 text-sm",
704
- children: [/* @__PURE__ */ q(Ae, {
705
+ children: [/* @__PURE__ */ q(ye, {
705
706
  workspace: n,
706
707
  kind: r.creator.kind,
707
708
  handle: r.creator.handle,
708
- children: /* @__PURE__ */ q(dt, {
709
- ...Oe(r.creator.kind),
710
- name: x(r.creator),
711
- src: S(r.creator.kind, r.creator.handle),
709
+ children: /* @__PURE__ */ q(ft, {
710
+ ...Pe(r.creator.kind),
711
+ name: b(r.creator),
712
+ src: x(r.creator.kind, r.creator.handle),
712
713
  size: "xs",
713
714
  tooltip: r.creator.kind !== "user"
714
715
  })
715
- }), /* @__PURE__ */ q(yt, {
716
+ }), /* @__PURE__ */ q(bt, {
716
717
  value: r.createdAt,
717
718
  exact: "medium"
718
719
  })]
@@ -720,12 +721,12 @@ function zt({ workspace: n, issue: r, team: i, open: o, setOpen: s, update: c })
720
721
  }),
721
722
  /* @__PURE__ */ q($, {
722
723
  label: d("timeInStatus"),
723
- children: /* @__PURE__ */ q(ct, {
724
+ children: /* @__PURE__ */ q(Oe, {
724
725
  workspace: n,
725
726
  identifier: r.identifier
726
727
  })
727
728
  }),
728
- /* @__PURE__ */ q(ke, {
729
+ /* @__PURE__ */ q(k, {
729
730
  workspace: n,
730
731
  issue: r,
731
732
  label: (e, t, n) => /* @__PURE__ */ q($, {
@@ -733,14 +734,14 @@ function zt({ workspace: n, issue: r, team: i, open: o, setOpen: s, update: c })
733
734
  children: t
734
735
  }, n)
735
736
  }),
736
- y.length > 0 && /* @__PURE__ */ q($, {
737
+ v.length > 0 && /* @__PURE__ */ q($, {
737
738
  label: d("syncedWith"),
738
- children: /* @__PURE__ */ q($e, { links: y })
739
+ children: /* @__PURE__ */ q(te, { links: v })
739
740
  })
740
741
  ]
741
742
  });
742
743
  }
743
- var Bt = [
744
+ var Vt = [
744
745
  "#d73a4a",
745
746
  "#2f8a57",
746
747
  "#8250df",
@@ -749,258 +750,258 @@ var Bt = [
749
750
  "#57606a",
750
751
  "#1a7f37"
751
752
  ];
752
- function Vt({ workspace: e, origin: t, className: n }) {
753
- let r = "size-3.5 shrink-0 text-muted-foreground", a = t.title.replace(/[*_`#>[\]]/g, "").replace(/\s+/g, " ").trim();
753
+ function Ht({ workspace: e, origin: t, className: n }) {
754
+ let r = "size-3.5 shrink-0 text-muted-foreground", i = t.title.replace(/[*_`#>[\]]/g, "").replace(/\s+/g, " ").trim();
754
755
  switch (t.kind) {
755
- case "decision": return /* @__PURE__ */ J(i, {
756
+ case "decision": return /* @__PURE__ */ J(R, {
756
757
  to: "/$workspace/issues/$identifier",
757
758
  params: {
758
759
  workspace: e,
759
760
  identifier: t.key
760
761
  },
761
762
  className: n,
762
- children: [/* @__PURE__ */ q(M, { className: r }), /* @__PURE__ */ q(xt, {
763
- content: a,
763
+ children: [/* @__PURE__ */ q(pe, { className: r }), /* @__PURE__ */ q(St, {
764
+ content: i,
764
765
  overflowOnly: !0,
765
766
  children: /* @__PURE__ */ q("span", {
766
767
  className: "truncate",
767
- children: a
768
+ children: i
768
769
  })
769
770
  })]
770
771
  });
771
- case "area": return /* @__PURE__ */ J(Le, {
772
+ case "area": return /* @__PURE__ */ J(S, {
772
773
  workspace: e,
773
774
  area: { key: t.key },
774
775
  className: n,
775
- children: [/* @__PURE__ */ q(T, { className: r }), /* @__PURE__ */ q("span", {
776
+ children: [/* @__PURE__ */ q(L, { className: r }), /* @__PURE__ */ q("span", {
776
777
  className: "truncate",
777
- children: a
778
+ children: i
778
779
  })]
779
780
  });
780
- default: return /* @__PURE__ */ J(i, {
781
+ default: return /* @__PURE__ */ J(R, {
781
782
  to: "/$workspace/docs/$doc",
782
783
  params: {
783
784
  workspace: e,
784
785
  doc: t.key
785
786
  },
786
787
  className: n,
787
- children: [/* @__PURE__ */ q(j, { className: r }), /* @__PURE__ */ q("span", {
788
+ children: [/* @__PURE__ */ q(fe, { className: r }), /* @__PURE__ */ q("span", {
788
789
  className: "truncate",
789
- children: a
790
+ children: i
790
791
  })]
791
792
  });
792
793
  }
793
794
  }
794
- function Ht({ workspace: e, issue: t, team: n, update: r, row: i }) {
795
- let a = G("planning"), s = G("flow"), c = ne(), u = ce(), { data: d = [] } = X(g(e)), f = d.find((e) => e.id === t.project?.id), { data: p = [] } = X({
796
- ...l(e, n?.key ?? ""),
795
+ function Ut({ workspace: e, issue: t, team: n, update: r, row: a }) {
796
+ let o = G("planning"), c = G("flow"), l = ut(), u = we(), { data: d = [] } = X(m(e)), f = d.find((e) => e.id === t.project?.id), { data: p = [] } = X({
797
+ ...s(e, n?.key ?? ""),
797
798
  enabled: !!n?.cyclesEnabled
798
- }), m = n?.estimateScale ?? "none", h = t.status.category === "completed" || t.status.category === "canceled", _ = (e) => e.name ? a("cycleNamed", {
799
+ }), h = n?.estimateScale ?? "none", g = t.status.category === "completed" || t.status.category === "canceled", _ = (e) => e.name ? o("cycleNamed", {
799
800
  number: e.number,
800
801
  name: e.name
801
- }) : a("cycle", { number: e.number }), v = p.filter((e) => e.state !== "past" || e.id === t.cycle?.id), { data: y = [] } = X(o(e)), b = y.filter((e) => !e.teamId || e.teamId === t.teamId);
802
+ }) : o("cycle", { number: e.number }), v = p.filter((e) => e.state !== "past" || e.id === t.cycle?.id), { data: y = [] } = X(i(e)), b = y.filter((e) => !e.teamId || e.teamId === t.teamId);
802
803
  return /* @__PURE__ */ J(K, { children: [
803
804
  n && n.flow.length > 0 && /* @__PURE__ */ q($, {
804
- label: s("stage"),
805
+ label: c("stage"),
805
806
  children: /* @__PURE__ */ q(V, {
806
- "aria-label": s("stage"),
807
+ "aria-label": c("stage"),
807
808
  value: t.stage ?? "",
808
809
  onValueChange: (e) => r({ stage: e ?? "" }),
809
810
  items: [{
810
811
  value: "",
811
- label: s("notInFlow")
812
+ label: c("notInFlow")
812
813
  }, ...n.flow.map((e) => ({
813
814
  value: e.stage,
814
- label: s(`stages.${e.stage}`)
815
+ label: c(`stages.${e.stage}`)
815
816
  }))],
816
817
  trigger: /* @__PURE__ */ J("button", {
817
818
  type: "button",
818
- className: i,
819
- children: [/* @__PURE__ */ q(k, { className: "size-3.5 shrink-0 text-muted-foreground" }), t.stage ? /* @__PURE__ */ q("span", {
819
+ className: a,
820
+ children: [/* @__PURE__ */ q(ue, { className: "size-3.5 shrink-0 text-muted-foreground" }), t.stage ? /* @__PURE__ */ q("span", {
820
821
  className: "truncate",
821
- children: s(`stages.${t.stage}`)
822
+ children: c(`stages.${t.stage}`)
822
823
  }) : /* @__PURE__ */ q("span", {
823
824
  className: "text-muted-foreground",
824
- children: s("notInFlow")
825
+ children: c("notInFlow")
825
826
  })]
826
827
  })
827
828
  })
828
829
  }),
829
830
  /* @__PURE__ */ q($, {
830
- label: a("area"),
831
+ label: o("area"),
831
832
  children: /* @__PURE__ */ q(V, {
832
- "aria-label": a("area"),
833
+ "aria-label": o("area"),
833
834
  value: t.area?.key ?? "",
834
835
  onValueChange: (e) => r({ area: e ?? "" }),
835
836
  items: [{
836
837
  value: "",
837
- label: a("noArea")
838
+ label: o("noArea")
838
839
  }, ...b.map((e) => ({
839
840
  value: e.key,
840
841
  label: e.title,
841
- ...e.status === "proposed" && { description: a("proposedArea") }
842
+ ...e.status === "proposed" && { description: o("proposedArea") }
842
843
  }))],
843
844
  trigger: /* @__PURE__ */ J("button", {
844
845
  type: "button",
845
- className: i,
846
- children: [/* @__PURE__ */ q(T, { className: "size-3.5 shrink-0 text-muted-foreground" }), t.area ? /* @__PURE__ */ q("span", {
846
+ className: a,
847
+ children: [/* @__PURE__ */ q(L, { className: "size-3.5 shrink-0 text-muted-foreground" }), t.area ? /* @__PURE__ */ q("span", {
847
848
  className: "truncate",
848
849
  children: t.area.title
849
850
  }) : /* @__PURE__ */ q("span", {
850
851
  className: "text-muted-foreground",
851
- children: a("noArea")
852
+ children: o("noArea")
852
853
  })]
853
854
  })
854
855
  })
855
856
  }),
856
857
  t.origin && /* @__PURE__ */ q($, {
857
- label: a("startedFrom"),
858
- children: /* @__PURE__ */ q(Vt, {
858
+ label: o("startedFrom"),
859
+ children: /* @__PURE__ */ q(Ht, {
859
860
  workspace: e,
860
861
  origin: t.origin,
861
- className: i
862
+ className: a
862
863
  })
863
864
  }),
864
865
  /* @__PURE__ */ q($, {
865
- label: a("project"),
866
+ label: o("project"),
866
867
  children: /* @__PURE__ */ q(V, {
867
- "aria-label": a("project"),
868
+ "aria-label": o("project"),
868
869
  value: t.project?.id ?? "",
869
870
  onValueChange: (e) => r({ projectId: e ?? "" }),
870
871
  items: [{
871
872
  value: "",
872
- label: a("noProject")
873
+ label: o("noProject")
873
874
  }, ...d.map((e) => ({
874
875
  value: e.id,
875
876
  label: e.name,
876
- icon: /* @__PURE__ */ q(ae, { status: e.status })
877
+ icon: /* @__PURE__ */ q(xe, { status: e.status })
877
878
  }))],
878
879
  trigger: /* @__PURE__ */ J("button", {
879
880
  type: "button",
880
- className: i,
881
- children: [/* @__PURE__ */ q(P, { className: "size-3.5 shrink-0 text-muted-foreground" }), t.project ? /* @__PURE__ */ q("span", {
881
+ className: a,
882
+ children: [/* @__PURE__ */ q(he, { className: "size-3.5 shrink-0 text-muted-foreground" }), t.project ? /* @__PURE__ */ q("span", {
882
883
  className: "truncate",
883
884
  children: t.project.name
884
885
  }) : /* @__PURE__ */ q("span", {
885
886
  className: "text-muted-foreground",
886
- children: a("noProject")
887
+ children: o("noProject")
887
888
  })]
888
889
  })
889
890
  })
890
891
  }),
891
892
  t.project && /* @__PURE__ */ q($, {
892
- label: a("milestone"),
893
+ label: o("milestone"),
893
894
  children: /* @__PURE__ */ q(V, {
894
- "aria-label": a("milestone"),
895
+ "aria-label": o("milestone"),
895
896
  value: t.milestone?.id ?? "",
896
897
  onValueChange: (e) => r({ milestoneId: e ?? "" }),
897
898
  items: [{
898
899
  value: "",
899
- label: a("noMilestone")
900
+ label: o("noMilestone")
900
901
  }, ...(f?.milestones ?? []).map((e) => ({
901
902
  value: e.id,
902
903
  label: e.name,
903
- ...e.targetDate && { description: c.day(e.targetDate) }
904
+ ...e.targetDate && { description: l.day(e.targetDate) }
904
905
  }))],
905
906
  trigger: /* @__PURE__ */ q("button", {
906
907
  type: "button",
907
- className: i,
908
+ className: a,
908
909
  children: t.milestone ? /* @__PURE__ */ q("span", {
909
910
  className: "truncate",
910
911
  children: t.milestone.name
911
912
  }) : /* @__PURE__ */ q("span", {
912
913
  className: "text-muted-foreground",
913
- children: a("noMilestone")
914
+ children: o("noMilestone")
914
915
  })
915
916
  })
916
917
  })
917
918
  }),
918
919
  n?.cyclesEnabled && /* @__PURE__ */ q($, {
919
- label: a("cycleLabel"),
920
+ label: o("cycleLabel"),
920
921
  children: /* @__PURE__ */ q(V, {
921
- "aria-label": a("cycleLabel"),
922
+ "aria-label": o("cycleLabel"),
922
923
  value: t.cycle?.id ?? "",
923
924
  onValueChange: (e) => r({ cycleId: e ?? "" }),
924
925
  items: [{
925
926
  value: "",
926
- label: a("noCycle")
927
+ label: o("noCycle")
927
928
  }, ...v.map((e) => ({
928
929
  value: e.id,
929
930
  label: _(e),
930
- description: a("stateAndDates", {
931
- state: a(`states.${e.state}`),
932
- dates: c.dayRange(e.startsOn, e.endsOn)
931
+ description: o("stateAndDates", {
932
+ state: o(`states.${e.state}`),
933
+ dates: l.dayRange(e.startsOn, e.endsOn)
933
934
  })
934
935
  }))],
935
936
  trigger: /* @__PURE__ */ J("button", {
936
937
  type: "button",
937
- className: i,
938
- children: [/* @__PURE__ */ q(k, { className: "size-3.5 shrink-0 text-muted-foreground" }), t.cycle ? /* @__PURE__ */ q("span", {
938
+ className: a,
939
+ children: [/* @__PURE__ */ q(ue, { className: "size-3.5 shrink-0 text-muted-foreground" }), t.cycle ? /* @__PURE__ */ q("span", {
939
940
  className: "truncate",
940
941
  children: _(t.cycle)
941
942
  }) : /* @__PURE__ */ q("span", {
942
943
  className: "text-muted-foreground",
943
- children: a("noCycle")
944
+ children: o("noCycle")
944
945
  })]
945
946
  })
946
947
  })
947
948
  }),
948
- (m !== "none" || !!t.estimate) && /* @__PURE__ */ q($, {
949
- label: a("estimate"),
949
+ (h !== "none" || !!t.estimate) && /* @__PURE__ */ q($, {
950
+ label: o("estimate"),
950
951
  children: /* @__PURE__ */ q(V, {
951
- "aria-label": a("estimate"),
952
+ "aria-label": o("estimate"),
952
953
  value: t.estimate ?? 0,
953
954
  onValueChange: (e) => r({ estimate: e ?? 0 }),
954
955
  items: [{
955
956
  value: 0,
956
- label: a("noEstimate")
957
- }, ...se(m).map((e) => ({
957
+ label: o("noEstimate")
958
+ }, ...Ce(h).map((e) => ({
958
959
  value: e,
959
- label: u(e, m)
960
+ label: u(e, h)
960
961
  }))],
961
962
  trigger: /* @__PURE__ */ J("button", {
962
963
  type: "button",
963
- className: i,
964
- children: [/* @__PURE__ */ q(A, { className: "size-3.5 shrink-0 text-muted-foreground" }), t.estimate ? u(t.estimate, m) : /* @__PURE__ */ q("span", {
964
+ className: a,
965
+ children: [/* @__PURE__ */ q(de, { className: "size-3.5 shrink-0 text-muted-foreground" }), t.estimate ? u(t.estimate, h) : /* @__PURE__ */ q("span", {
965
966
  className: "text-muted-foreground",
966
- children: a("noEstimate")
967
+ children: o("noEstimate")
967
968
  })]
968
969
  })
969
970
  })
970
971
  }),
971
972
  /* @__PURE__ */ q($, {
972
- label: a("dueDate"),
973
+ label: o("dueDate"),
973
974
  children: /* @__PURE__ */ J("div", {
974
975
  className: "flex items-center",
975
- children: [/* @__PURE__ */ q(ht, {
976
+ children: [/* @__PURE__ */ q(gt, {
976
977
  value: t.dueDate ?? "",
977
978
  onValueChange: (e) => r({ dueDate: e }),
978
- "aria-label": a("dueDate"),
979
+ "aria-label": o("dueDate"),
979
980
  required: !0,
980
981
  trigger: /* @__PURE__ */ q("button", {
981
982
  type: "button",
982
- className: i,
983
- children: t.dueDate ? /* @__PURE__ */ q(ie, {
983
+ className: a,
984
+ children: t.dueDate ? /* @__PURE__ */ q(be, {
984
985
  date: t.dueDate,
985
- closed: h
986
- }) : /* @__PURE__ */ J(K, { children: [/* @__PURE__ */ q(D, { className: "size-3.5 shrink-0 text-muted-foreground" }), /* @__PURE__ */ q("span", {
986
+ closed: g
987
+ }) : /* @__PURE__ */ J(K, { children: [/* @__PURE__ */ q(ce, { className: "size-3.5 shrink-0 text-muted-foreground" }), /* @__PURE__ */ q("span", {
987
988
  className: "text-muted-foreground",
988
- children: a("noDueDate")
989
+ children: o("noDueDate")
989
990
  })] })
990
991
  })
991
- }), t.dueDate && /* @__PURE__ */ q(_t, {
992
+ }), t.dueDate && /* @__PURE__ */ q(vt, {
992
993
  variant: "ghost",
993
- icon: /* @__PURE__ */ q(O, { className: "size-3.5" }),
994
- label: a("clearDueDate"),
994
+ icon: /* @__PURE__ */ q(le, { className: "size-3.5" }),
995
+ label: o("clearDueDate"),
995
996
  onClick: () => r({ dueDate: "" })
996
997
  })]
997
998
  })
998
999
  }),
999
- t.slaDueAt && !h && /* @__PURE__ */ q($, {
1000
- label: a("sla.label"),
1000
+ t.slaDueAt && !g && /* @__PURE__ */ q($, {
1001
+ label: o("sla.label"),
1001
1002
  children: /* @__PURE__ */ q("span", {
1002
1003
  className: "flex h-7 items-center px-2",
1003
- children: /* @__PURE__ */ q(oe, {
1004
+ children: /* @__PURE__ */ q(Se, {
1004
1005
  issue: t,
1005
1006
  team: n
1006
1007
  })
@@ -1008,11 +1009,11 @@ function Ht({ workspace: e, issue: t, team: n, update: r, row: i }) {
1008
1009
  })
1009
1010
  ] });
1010
1011
  }
1011
- function Ut({ workspace: e, issue: t, update: n, row: r }) {
1012
- let i = G("issueTypes"), a = jt(), { data: o } = X(we(e)), { data: s } = X(xe(e)), { confirm: c, dialog: l } = Ce(), [u, d] = W(!1), f = Ee(o, t.teamId);
1012
+ function Wt({ workspace: e, issue: t, update: n, row: r }) {
1013
+ let i = G("issueTypes"), a = Mt(), { data: o } = X(Ge(e)), { data: s } = X(ze(e)), { confirm: c, dialog: l } = Re(), [u, d] = W(!1), f = qe(o, t.teamId);
1013
1014
  if (f.length === 0 && !t.type) return null;
1014
1015
  let p = (e) => {
1015
- let r = f.find((t) => t.id === e), o = (s ?? []).filter((e) => Se(t.fields[e.id]) && !Te(r, e.id));
1016
+ let r = f.find((t) => t.id === e), o = (s ?? []).filter((e) => Be(t.fields[e.id]) && !Ke(r, e.id));
1016
1017
  if (!r || o.length === 0) return n({ typeId: e });
1017
1018
  c({
1018
1019
  title: i("hiddenTitle"),
@@ -1037,7 +1038,7 @@ function Ut({ workspace: e, issue: t, update: n, row: r }) {
1037
1038
  }, ...f.map((e) => ({
1038
1039
  value: e.id,
1039
1040
  label: e.name,
1040
- icon: /* @__PURE__ */ q(De, { type: e })
1041
+ icon: /* @__PURE__ */ q(I, { type: e })
1041
1042
  }))],
1042
1043
  value: t.type?.id ?? "",
1043
1044
  onValueChange: (e) => e !== null && e !== (t.type?.id ?? "") && p(e),
@@ -1045,7 +1046,7 @@ function Ut({ workspace: e, issue: t, update: n, row: r }) {
1045
1046
  trigger: /* @__PURE__ */ q("button", {
1046
1047
  type: "button",
1047
1048
  className: r,
1048
- children: t.type ? /* @__PURE__ */ J(K, { children: [/* @__PURE__ */ q(De, { type: t.type }), t.type.name] }) : /* @__PURE__ */ q("span", {
1049
+ children: t.type ? /* @__PURE__ */ J(K, { children: [/* @__PURE__ */ q(I, { type: t.type }), t.type.name] }) : /* @__PURE__ */ q("span", {
1049
1050
  className: "text-muted-foreground",
1050
1051
  children: i("noType")
1051
1052
  })
@@ -1056,15 +1057,15 @@ function Ut({ workspace: e, issue: t, update: n, row: r }) {
1056
1057
  function $({ label: e, shortcut: t, children: n }) {
1057
1058
  return /* @__PURE__ */ J("div", { children: [/* @__PURE__ */ J("p", {
1058
1059
  className: "mb-1 flex items-center justify-between px-2 text-xs text-muted-foreground",
1059
- children: [e, t && /* @__PURE__ */ q(vt, {
1060
+ children: [e, t && /* @__PURE__ */ q(yt, {
1060
1061
  keys: t,
1061
1062
  size: "xs",
1062
1063
  className: "hidden md:inline-flex"
1063
1064
  })]
1064
1065
  }), n] });
1065
1066
  }
1066
- function Wt({ workspace: e, identifier: t }) {
1067
- let n = G("issue.activity"), { data: r } = Q(u(e, t)), [i, a] = W(!1), o = kt(() => {
1067
+ function Gt({ workspace: e, identifier: t }) {
1068
+ let n = G("issue.activity"), { data: r } = Q(c(e, t)), [i, a] = W(!1), o = At(() => {
1068
1069
  let e = [];
1069
1070
  for (let t of r) {
1070
1071
  if (t.type.startsWith("comment.") || t.type.startsWith("issue.reaction_")) continue;
@@ -1087,9 +1088,9 @@ function Wt({ workspace: e, identifier: t }) {
1087
1088
  className: "mt-3 text-xs text-muted-foreground hover:text-foreground",
1088
1089
  children: n("showEarlier", { count: s })
1089
1090
  }),
1090
- /* @__PURE__ */ q(Xe, {
1091
+ /* @__PURE__ */ q(v, {
1091
1092
  className: "mt-3",
1092
- children: o.slice(s).map((t) => /* @__PURE__ */ q(tt, {
1093
+ children: o.slice(s).map((t) => /* @__PURE__ */ q(P, {
1093
1094
  workspace: e,
1094
1095
  event: t
1095
1096
  }, t.id))
@@ -1097,14 +1098,14 @@ function Wt({ workspace: e, identifier: t }) {
1097
1098
  ]
1098
1099
  });
1099
1100
  }
1100
- function Gt({ workspace: e, identifier: t, others: n }) {
1101
- let r = G("issue.comments"), { data: i } = Q(c(e, t)), { data: a = [] } = X(f(e, t)), o = kt(() => {
1101
+ function Kt({ workspace: e, identifier: t, others: n }) {
1102
+ let r = G("issue.comments"), { data: i } = Q(o(e, t)), { data: a = [] } = X(u(e, t)), s = At(() => {
1102
1103
  let e = i.filter((e) => !e.parentId);
1103
- return e.sort((e, t) => Number(Kt(t)) - Number(Kt(e))), e.map((e) => ({
1104
+ return e.sort((e, t) => Number(qt(t)) - Number(qt(e))), e.map((e) => ({
1104
1105
  root: e,
1105
1106
  replies: i.filter((t) => t.parentId === e.id)
1106
1107
  }));
1107
- }, [i]), [s, l] = W(null), u = i.filter((e) => !e.deletedAt && !Kt(e)).length;
1108
+ }, [i]), [c, l] = W(null), d = i.filter((e) => !e.deletedAt && !qt(e)).length;
1108
1109
  return /* @__PURE__ */ J("section", {
1109
1110
  className: "mt-12 border-t border-border pt-6",
1110
1111
  "aria-label": r("title"),
@@ -1114,29 +1115,29 @@ function Gt({ workspace: e, identifier: t, others: n }) {
1114
1115
  children: [
1115
1116
  r("title"),
1116
1117
  " ",
1117
- u > 0 && /* @__PURE__ */ q("span", {
1118
+ d > 0 && /* @__PURE__ */ q("span", {
1118
1119
  className: "font-normal text-muted-foreground",
1119
- children: u
1120
+ children: d
1120
1121
  })
1121
1122
  ]
1122
1123
  }),
1123
1124
  /* @__PURE__ */ q("div", {
1124
1125
  className: "mt-4 space-y-3",
1125
- children: o.map(({ root: n, replies: i }) => {
1126
- let o = Kt(n) ? n.sharedWith : void 0, c = o ? L(o).source : void 0;
1127
- return /* @__PURE__ */ J(pt, {
1126
+ children: s.map(({ root: n, replies: i }) => {
1127
+ let o = qt(n) ? n.sharedWith : void 0, s = o ? et(o).source : void 0;
1128
+ return /* @__PURE__ */ J(mt, {
1128
1129
  size: "fill",
1129
1130
  padding: "none",
1130
1131
  highlight: !!o,
1131
1132
  render: /* @__PURE__ */ q("article", {
1132
1133
  id: `comment-${n.id}`,
1133
- "aria-label": c && r("sharedThreadLabel", { source: c })
1134
+ "aria-label": s && r("sharedThreadLabel", { source: s })
1134
1135
  }),
1135
1136
  children: [
1136
- o && c ? /* @__PURE__ */ q(et, {
1137
- source: c,
1137
+ o && s ? /* @__PURE__ */ q(N, {
1138
+ source: s,
1138
1139
  link: a.find((e) => e.connector === o)
1139
- }) : /* @__PURE__ */ q(Jt, {
1140
+ }) : /* @__PURE__ */ q(Yt, {
1140
1141
  workspace: e,
1141
1142
  identifier: t,
1142
1143
  comment: n,
@@ -1147,7 +1148,7 @@ function Gt({ workspace: e, identifier: t, others: n }) {
1147
1148
  children: i.map((r) => /* @__PURE__ */ q("li", {
1148
1149
  id: `comment-${r.id}`,
1149
1150
  className: "border-b border-border/50 last:border-b-0",
1150
- children: /* @__PURE__ */ q(Jt, {
1151
+ children: /* @__PURE__ */ q(Yt, {
1151
1152
  workspace: e,
1152
1153
  identifier: t,
1153
1154
  comment: r,
@@ -1157,37 +1158,37 @@ function Gt({ workspace: e, identifier: t, others: n }) {
1157
1158
  }),
1158
1159
  /* @__PURE__ */ q("div", {
1159
1160
  className: "border-t border-border/70 px-3 py-2",
1160
- children: s === n.id ? /* @__PURE__ */ q(Xt, {
1161
+ children: c === n.id ? /* @__PURE__ */ q(Zt, {
1161
1162
  workspace: e,
1162
1163
  identifier: t,
1163
1164
  parentId: n.id,
1164
- publicOn: c,
1165
+ publicOn: s,
1165
1166
  autofocus: !0,
1166
1167
  onDone: () => l(null)
1167
1168
  }) : /* @__PURE__ */ q("button", {
1168
1169
  type: "button",
1169
1170
  onClick: () => l(n.id),
1170
1171
  className: "w-full text-left text-xs text-muted-foreground hover:text-foreground",
1171
- children: c ? r("replyPublic", { source: c }) : r("replyPlaceholder")
1172
+ children: s ? r("replyPublic", { source: s }) : r("replyPlaceholder")
1172
1173
  })
1173
1174
  })
1174
1175
  ]
1175
1176
  }, n.id);
1176
1177
  })
1177
1178
  }),
1178
- /* @__PURE__ */ q(pt, {
1179
+ /* @__PURE__ */ q(mt, {
1179
1180
  size: "fill",
1180
1181
  padding: "sm",
1181
1182
  focusWithin: !0,
1182
1183
  className: "mt-4",
1183
- children: /* @__PURE__ */ q(Xt, {
1184
+ children: /* @__PURE__ */ q(Zt, {
1184
1185
  workspace: e,
1185
1186
  identifier: t
1186
1187
  })
1187
1188
  }),
1188
1189
  /* @__PURE__ */ q("div", {
1189
1190
  className: "mt-2",
1190
- children: /* @__PURE__ */ q(Je, {
1191
+ children: /* @__PURE__ */ q(Te, {
1191
1192
  workspace: e,
1192
1193
  others: n,
1193
1194
  field: "comment"
@@ -1196,52 +1197,52 @@ function Gt({ workspace: e, identifier: t, others: n }) {
1196
1197
  ]
1197
1198
  });
1198
1199
  }
1199
- var Kt = (e) => !!e.sharedWith && !e.parentId;
1200
- function qt({ comment: e }) {
1200
+ var qt = (e) => !!e.sharedWith && !e.parentId;
1201
+ function Jt({ comment: e }) {
1201
1202
  let t = G("issue.comments");
1202
1203
  return e.author.kind === "connector" ? /* @__PURE__ */ q("span", {
1203
1204
  className: "rounded border border-border px-1.5 py-px text-[10px] text-muted-foreground",
1204
- children: t("via", { source: L(e.author.handle).source })
1205
+ children: t("via", { source: et(e.author.handle).source })
1205
1206
  }) : null;
1206
1207
  }
1207
- function Jt({ workspace: n, identifier: r, comment: i, onReply: a }) {
1208
- let o = G("issue.comments"), s = G("common"), { actorName: c, avatarOf: l } = te(n), { data: u } = Q(h), { data: d = [] } = X(_(n, r)), f = ve(n, "comment", { team: r.slice(0, r.lastIndexOf("-")) }), p = Z(), m = H(), [g, v] = W(!1), [y, x] = W(i.body), [C, w] = W(!1), T = U(null), E = Pe(n, r), D = i.author.kind === "user" && i.author.handle === u?.user.username, O = { path: {
1209
- workspace: n,
1210
- identifier: r,
1211
- commentId: i.id
1212
- } }, k = () => b(p, n, r), A = Y({
1208
+ function Yt({ workspace: r, identifier: i, comment: a, onReply: o }) {
1209
+ let s = G("issue.comments"), c = G("common"), { actorName: l, avatarOf: u } = tt(r), { data: d } = Q(p), { data: f = [] } = X(h(r, i)), m = ot(r, "comment", { team: i.slice(0, i.lastIndexOf("-")) }), g = Z(), _ = H(), [v, b] = W(!1), [x, S] = W(a.body), [C, w] = W(!1), D = U(null), O = E(r, i), k = a.author.kind === "user" && a.author.handle === d?.user.username, j = { path: {
1210
+ workspace: r,
1211
+ identifier: i,
1212
+ commentId: a.id
1213
+ } }, ee = () => n(g, r, i), M = Y({
1213
1214
  mutationFn: async () => t(await e.PATCH("/api/v1/workspaces/{workspace}/issues/{identifier}/comments/{commentId}", {
1214
- params: O,
1215
- body: { body: y }
1215
+ params: j,
1216
+ body: { body: x }
1216
1217
  })),
1217
1218
  onSuccess: () => {
1218
- v(!1), k();
1219
+ b(!1), ee();
1219
1220
  }
1220
- }), j = Y({
1221
- mutationFn: async () => t(await e.DELETE("/api/v1/workspaces/{workspace}/issues/{identifier}/comments/{commentId}", { params: O })),
1222
- onSuccess: k
1221
+ }), te = Y({
1222
+ mutationFn: async () => t(await e.DELETE("/api/v1/workspaces/{workspace}/issues/{identifier}/comments/{commentId}", { params: j })),
1223
+ onSuccess: ee
1223
1224
  });
1224
- if (i.deletedAt) return /* @__PURE__ */ q("p", {
1225
+ if (a.deletedAt) return /* @__PURE__ */ q("p", {
1225
1226
  className: "px-3 py-2.5 text-xs text-muted-foreground italic",
1226
- children: o("deleted")
1227
+ children: s("deleted")
1227
1228
  });
1228
- let M = `${me(n, r)}#comment-${i.id}`, N = [
1229
+ let N = `${Ue(r, i)}#comment-${a.id}`, ne = [
1229
1230
  {
1230
- label: o("reply"),
1231
- onClick: a
1231
+ label: s("reply"),
1232
+ onClick: o
1232
1233
  },
1233
- S(s("copyLink"), M),
1234
- S(o("copyText"), i.body),
1235
- ...D ? [
1236
- Ct,
1234
+ Ze(c("copyLink"), N),
1235
+ Ze(s("copyText"), a.body),
1236
+ ...k ? [
1237
+ wt,
1237
1238
  {
1238
- label: o("edit"),
1239
+ label: s("edit"),
1239
1240
  onClick: () => {
1240
- x(i.body), v(!0);
1241
+ S(a.body), b(!0);
1241
1242
  }
1242
1243
  },
1243
1244
  {
1244
- label: s("delete"),
1245
+ label: c("delete"),
1245
1246
  destructive: !0,
1246
1247
  onClick: () => w(!0)
1247
1248
  }
@@ -1249,74 +1250,70 @@ function Jt({ workspace: n, identifier: r, comment: i, onReply: a }) {
1249
1250
  ];
1250
1251
  return /* @__PURE__ */ J("div", {
1251
1252
  className: "group px-3 py-2.5",
1252
- onContextMenu: (e) => !g && m(e, N),
1253
+ onContextMenu: (e) => !v && _(e, ne),
1253
1254
  children: [/* @__PURE__ */ J("div", {
1254
1255
  className: "flex items-center gap-2 text-xs",
1255
1256
  children: [
1256
- /* @__PURE__ */ J(Ae, {
1257
- workspace: n,
1258
- kind: i.author.kind,
1259
- handle: i.author.handle,
1260
- className: "flex items-center gap-2",
1261
- children: [/* @__PURE__ */ q(dt, {
1262
- ...Oe(i.author.kind),
1263
- name: c(i.author),
1264
- src: l(i.author.kind, i.author.handle),
1257
+ /* @__PURE__ */ J(y, {
1258
+ workspace: r,
1259
+ actor: a.author,
1260
+ className: "flex items-center gap-2 font-medium hover:underline",
1261
+ children: [/* @__PURE__ */ q(ft, {
1262
+ ...Pe(a.author.kind),
1263
+ name: l(a.author),
1264
+ src: u(a.author.kind, a.author.handle),
1265
1265
  size: "xs",
1266
1266
  decorative: !0
1267
- }), /* @__PURE__ */ q("span", {
1268
- className: "font-medium",
1269
- children: c(i.author)
1270
- })]
1267
+ }), l(a.author)]
1271
1268
  }),
1272
- /* @__PURE__ */ q(qt, { comment: i }),
1269
+ /* @__PURE__ */ q(Jt, { comment: a }),
1273
1270
  /* @__PURE__ */ J("span", {
1274
1271
  className: "text-muted-foreground",
1275
- children: [/* @__PURE__ */ q(yt, {
1276
- value: i.createdAt,
1272
+ children: [/* @__PURE__ */ q(bt, {
1273
+ value: a.createdAt,
1277
1274
  exact: "medium"
1278
- }), i.updatedAt !== i.createdAt && /* @__PURE__ */ J(K, { children: [" ", o("edited")] })]
1275
+ }), a.updatedAt !== a.createdAt && /* @__PURE__ */ J(K, { children: [" ", s("edited")] })]
1279
1276
  }),
1280
- !C && !g && /* @__PURE__ */ q(Mt, {
1281
- items: N,
1277
+ !C && !v && /* @__PURE__ */ q(Nt, {
1278
+ items: ne,
1282
1279
  className: "ml-auto"
1283
1280
  }),
1284
1281
  C && /* @__PURE__ */ J("span", {
1285
1282
  className: "ml-auto flex gap-2 text-muted-foreground",
1286
1283
  children: [
1287
- /* @__PURE__ */ q("span", { children: o("confirmDelete") }),
1284
+ /* @__PURE__ */ q("span", { children: s("confirmDelete") }),
1288
1285
  /* @__PURE__ */ q("button", {
1289
1286
  type: "button",
1290
1287
  className: "text-danger hover:underline",
1291
- onClick: () => j.mutate(),
1292
- children: s("delete")
1288
+ onClick: () => te.mutate(),
1289
+ children: c("delete")
1293
1290
  }),
1294
1291
  /* @__PURE__ */ q("button", {
1295
1292
  type: "button",
1296
1293
  className: "hover:underline",
1297
1294
  onClick: () => w(!1),
1298
- children: o("keep")
1295
+ children: s("keep")
1299
1296
  })
1300
1297
  ]
1301
1298
  })
1302
1299
  ]
1303
1300
  }), /* @__PURE__ */ q("div", {
1304
1301
  className: "mt-1",
1305
- children: g ? /* @__PURE__ */ J(K, { children: [
1306
- /* @__PURE__ */ q(R, {
1307
- value: y,
1308
- onChange: x,
1309
- onSubmit: () => A.mutate(),
1302
+ children: v ? /* @__PURE__ */ J(K, { children: [
1303
+ /* @__PURE__ */ q(A, {
1304
+ value: x,
1305
+ onChange: S,
1306
+ onSubmit: () => M.mutate(),
1310
1307
  autofocus: !0,
1311
- label: o("editLabel"),
1308
+ label: s("editLabel"),
1312
1309
  onEditor: (e) => {
1313
- T.current = e;
1310
+ D.current = e;
1314
1311
  },
1315
- onFiles: (e, t) => E.upload(T.current, e, t)
1312
+ onFiles: (e, t) => O.upload(D.current, e, t)
1316
1313
  }),
1317
- /* @__PURE__ */ q(Ne, {
1318
- pending: E.pending,
1319
- error: E.error
1314
+ /* @__PURE__ */ q(T, {
1315
+ pending: O.pending,
1316
+ error: O.error
1320
1317
  }),
1321
1318
  /* @__PURE__ */ J("div", {
1322
1319
  className: "mt-2 flex justify-end gap-2",
@@ -1324,117 +1321,117 @@ function Jt({ workspace: n, identifier: r, comment: i, onReply: a }) {
1324
1321
  type: "button",
1325
1322
  variant: "ghost",
1326
1323
  size: "sm",
1327
- onClick: () => v(!1),
1328
- children: s("cancel")
1324
+ onClick: () => b(!1),
1325
+ children: c("cancel")
1329
1326
  }), /* @__PURE__ */ q(z, {
1330
1327
  type: "button",
1331
1328
  variant: "primary",
1332
1329
  size: "sm",
1333
- onClick: () => A.mutate(),
1334
- disabled: !y.trim() || E.pending > 0,
1335
- children: s("save")
1330
+ onClick: () => M.mutate(),
1331
+ disabled: !x.trim() || O.pending > 0,
1332
+ children: c("save")
1336
1333
  })]
1337
1334
  })
1338
1335
  ] }) : /* @__PURE__ */ J(K, { children: [
1339
- /* @__PURE__ */ q(R, {
1340
- value: i.body,
1336
+ /* @__PURE__ */ q(A, {
1337
+ value: a.body,
1341
1338
  editable: !1
1342
1339
  }),
1343
- /* @__PURE__ */ q(ut, {
1344
- workspace: n,
1345
- widgets: i.widgets
1340
+ /* @__PURE__ */ q(Ae, {
1341
+ workspace: r,
1342
+ widgets: a.widgets
1346
1343
  }),
1347
- /* @__PURE__ */ q(Yt, {
1348
- workspace: n,
1349
- identifier: r,
1350
- comment: i
1344
+ /* @__PURE__ */ q(Xt, {
1345
+ workspace: r,
1346
+ identifier: i,
1347
+ comment: a
1351
1348
  }),
1352
- /* @__PURE__ */ q(st, {
1353
- workspace: n,
1354
- identifier: r,
1355
- commentId: i.id,
1356
- reactions: d,
1357
- me: u?.user.username,
1358
- disabled: !f
1349
+ /* @__PURE__ */ q(De, {
1350
+ workspace: r,
1351
+ identifier: i,
1352
+ commentId: a.id,
1353
+ reactions: f,
1354
+ me: d?.user.username,
1355
+ disabled: !m
1359
1356
  })
1360
1357
  ] })
1361
1358
  })]
1362
1359
  });
1363
1360
  }
1364
- function Yt({ workspace: e, identifier: t, comment: n }) {
1365
- let { data: r = [] } = X(s(e, t)), { actorName: i } = te(e), a = r.filter((e) => e.page && e.commentId === n.id);
1366
- return a.length === 0 ? null : /* @__PURE__ */ q("div", {
1361
+ function Xt({ workspace: e, identifier: t, comment: n }) {
1362
+ let { data: r = [] } = X(a(e, t)), { actorName: i } = tt(e), o = r.filter((e) => e.page && e.commentId === n.id);
1363
+ return o.length === 0 ? null : /* @__PURE__ */ q("div", {
1367
1364
  className: "mt-2 space-y-2",
1368
- children: a.map((e) => /* @__PURE__ */ q(re, {
1365
+ children: o.map((e) => /* @__PURE__ */ q(b, {
1369
1366
  attachmentId: e.id,
1370
1367
  name: e.name,
1371
1368
  agent: i(n.author)
1372
1369
  }, e.id))
1373
1370
  });
1374
1371
  }
1375
- function Xt({ workspace: n, identifier: r, parentId: i, publicOn: a, autofocus: o = !1, onDone: s }) {
1376
- let c = G("issue.comments"), l = At(), u = G("common"), d = Dt(Zt), f = Z(), [p, m] = W(""), [h, g] = W(0), _ = U(null), v = Pe(n, r), y = Y({
1372
+ function Zt({ workspace: r, identifier: i, parentId: a, publicOn: o, autofocus: s = !1, onDone: c }) {
1373
+ let l = G("issue.comments"), u = jt(), d = G("common"), f = Ot(Qt), p = Z(), [m, h] = W(""), [g, _] = W(0), v = U(null), y = E(r, i), b = Y({
1377
1374
  mutationFn: async () => t(await e.POST("/api/v1/workspaces/{workspace}/issues/{identifier}/comments", {
1378
1375
  params: { path: {
1379
- workspace: n,
1380
- identifier: r
1376
+ workspace: r,
1377
+ identifier: i
1381
1378
  } },
1382
1379
  body: {
1383
- body: p,
1384
- ...i && { parentId: i }
1380
+ body: m,
1381
+ ...a && { parentId: a }
1385
1382
  }
1386
1383
  })),
1387
1384
  onSuccess: () => {
1388
- m(""), g((e) => e + 1), b(f, n, r), s?.();
1385
+ h(""), _((e) => e + 1), n(p, r, i), c?.();
1389
1386
  }
1390
- }), x = () => p.trim() && !y.isPending && v.pending === 0 && y.mutate();
1391
- return /* @__PURE__ */ J("div", { children: [/* @__PURE__ */ q(R, {
1387
+ }), x = () => m.trim() && !b.isPending && y.pending === 0 && b.mutate();
1388
+ return /* @__PURE__ */ J("div", { children: [/* @__PURE__ */ q(A, {
1392
1389
  value: "",
1393
- onChange: m,
1390
+ onChange: h,
1394
1391
  onSubmit: x,
1395
- onFocus: () => d("comment"),
1396
- onBlur: () => d(void 0),
1397
- autofocus: o,
1392
+ onFocus: () => f("comment"),
1393
+ onBlur: () => f(void 0),
1394
+ autofocus: s,
1398
1395
  onEditor: (e) => {
1399
- _.current = e;
1396
+ v.current = e;
1400
1397
  },
1401
- onFiles: (e, t) => v.upload(_.current, e, t),
1402
- placeholder: a ? c("replyPublic", { source: a }) : c(i ? "replyPlaceholder" : "placeholder"),
1403
- label: a ? c("replyPublicButton", { source: a }) : c(i ? "reply" : "newComment"),
1404
- className: i ? "min-h-8" : "min-h-12"
1405
- }, h), /* @__PURE__ */ J("div", {
1398
+ onFiles: (e, t) => y.upload(v.current, e, t),
1399
+ placeholder: o ? l("replyPublic", { source: o }) : l(a ? "replyPlaceholder" : "placeholder"),
1400
+ label: o ? l("replyPublicButton", { source: o }) : l(a ? "reply" : "newComment"),
1401
+ className: a ? "min-h-8" : "min-h-12"
1402
+ }, g), /* @__PURE__ */ J("div", {
1406
1403
  className: "mt-1 flex items-center justify-end gap-3",
1407
1404
  children: [
1408
1405
  /* @__PURE__ */ J("span", {
1409
1406
  className: "mr-auto flex min-w-0 items-center gap-2",
1410
- children: [/* @__PURE__ */ q(je, { onFiles: (e) => v.upload(_.current, e) }), /* @__PURE__ */ q(Ne, {
1411
- pending: v.pending,
1412
- error: v.error
1407
+ children: [/* @__PURE__ */ q(C, { onFiles: (e) => y.upload(v.current, e) }), /* @__PURE__ */ q(T, {
1408
+ pending: y.pending,
1409
+ error: y.error
1413
1410
  })]
1414
1411
  }),
1415
- y.isError && /* @__PURE__ */ q(gt, {
1412
+ b.isError && /* @__PURE__ */ q(_t, {
1416
1413
  inline: !0,
1417
1414
  className: "text-xs",
1418
- children: l(y.error)
1415
+ children: u(b.error)
1419
1416
  }),
1420
- s && /* @__PURE__ */ q(z, {
1417
+ c && /* @__PURE__ */ q(z, {
1421
1418
  type: "button",
1422
1419
  variant: "ghost",
1423
1420
  size: "sm",
1424
- onClick: s,
1425
- children: u("cancel")
1421
+ onClick: c,
1422
+ children: d("cancel")
1426
1423
  }),
1427
1424
  /* @__PURE__ */ q(z, {
1428
1425
  type: "button",
1429
1426
  variant: "primary",
1430
1427
  size: "sm",
1431
1428
  onClick: x,
1432
- disabled: !p.trim() || v.pending > 0,
1433
- loading: y.isPending,
1434
- children: a ? c("replyPublicButton", { source: a }) : c(i ? "reply" : "submit")
1429
+ disabled: !m.trim() || y.pending > 0,
1430
+ loading: b.isPending,
1431
+ children: o ? l("replyPublicButton", { source: o }) : l(a ? "reply" : "submit")
1435
1432
  })
1436
1433
  ]
1437
1434
  })] });
1438
1435
  }
1439
- var Zt = Tt(() => {});
1440
- export { Pt as component };
1436
+ var Qt = Et(() => {});
1437
+ export { Ft as component };