@parallelworks/tandem-web 0.150.3 → 0.152.0

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 (110) hide show
  1. package/_virtual/_virtual_i18n/en/common.js +36 -4
  2. package/_virtual/_virtual_i18n/es/common.js +36 -4
  3. package/_virtual/_virtual_i18n/ja/common.js +36 -4
  4. package/_virtual/_virtual_i18n/ko/common.js +36 -4
  5. package/_virtual/_virtual_i18n/zh/common.js +36 -4
  6. package/api/queries.js +88 -77
  7. package/components/AccessGrants.js +6 -6
  8. package/components/ActivityTimeline.js +4 -4
  9. package/components/AgentWork.js +111 -111
  10. package/components/AreaLink.js +32 -0
  11. package/components/AreaTiles.js +10 -13
  12. package/components/AreaWork.js +25 -1
  13. package/components/BugRotation.js +3 -3
  14. package/components/CodeHostSettings.js +30 -30
  15. package/components/CommandPalette.js +53 -53
  16. package/components/CustomFields.js +116 -116
  17. package/components/DateChip.js +11 -11
  18. package/components/DocButton.js +6 -6
  19. package/components/DocHistory.js +4 -4
  20. package/components/DocLinkPicker.js +8 -8
  21. package/components/DocProperties.js +15 -15
  22. package/components/DocTable.js +15 -15
  23. package/components/DocsTree.js +80 -80
  24. package/components/Editor.js +35 -35
  25. package/components/FavoritesNav.js +53 -53
  26. package/components/GitHub.js +18 -18
  27. package/components/Graph.js +15 -15
  28. package/components/HostActions.js +21 -21
  29. package/components/HostPanel.js +6 -6
  30. package/components/HoverCards.js +38 -38
  31. package/components/IssueBoard.js +4 -4
  32. package/components/IssueCode.js +14 -14
  33. package/components/IssueEvent.js +3 -3
  34. package/components/IssueFilters.js +71 -71
  35. package/components/IssueListBlock.js +32 -32
  36. package/components/IssueRow.js +21 -21
  37. package/components/IssueTemplates.js +118 -118
  38. package/components/IssueTypes.js +40 -40
  39. package/components/NewIssueDialog.js +76 -76
  40. package/components/NewProjectDialog.js +145 -145
  41. package/components/PersonActivity.js +4 -4
  42. package/components/SharedViewer.js +5 -5
  43. package/components/SlashMenu.js +29 -29
  44. package/components/TeamRepositories.js +51 -51
  45. package/components/TeamWorkflow.js +6 -6
  46. package/components/UnlinkedMentions.js +20 -20
  47. package/components/Updates.js +3 -3
  48. package/components/Widgets.js +20 -20
  49. package/components/columns.js +17 -17
  50. package/components/editorPlugins.js +80 -80
  51. package/components/mathDiagrams.js +17 -17
  52. package/lib/boardMove.js +5 -5
  53. package/lib/issueList.js +58 -58
  54. package/lib/issueMenu.js +27 -27
  55. package/lib/knowledge.js +106 -106
  56. package/lib/views.js +9 -9
  57. package/package.json +1 -1
  58. package/pages/area.js +291 -0
  59. package/pages/areas.js +258 -287
  60. package/pages/decisions.js +21 -21
  61. package/pages/issues.js +52 -52
  62. package/pages/projects.js +125 -125
  63. package/pages/triage.js +12 -12
  64. package/routeTree.gen.js +186 -180
  65. package/routes/_workspace/agents/_slug2.js +11 -11
  66. package/routes/_workspace/agents/index2.js +10 -10
  67. package/routes/_workspace/areas/_area.js +7 -8
  68. package/routes/_workspace/areas/_area2.js +3 -290
  69. package/routes/_workspace/areas/_area3.js +7 -8
  70. package/routes/_workspace/docs/_doc2.js +230 -230
  71. package/routes/_workspace/docs/space2._space.js +27 -27
  72. package/routes/_workspace/issues/_identifier2.js +222 -224
  73. package/routes/_workspace/knowledge/_term2.js +43 -43
  74. package/routes/_workspace/knowledge/index.js +6 -6
  75. package/routes/_workspace/knowledge/index2.js +15 -15
  76. package/routes/_workspace/measures3.js +70 -72
  77. package/routes/_workspace/notifications2.js +150 -150
  78. package/routes/_workspace/people/_username2.js +10 -10
  79. package/routes/_workspace/projects/_projectId3.js +276 -276
  80. package/routes/_workspace/settings/audit-log3.js +136 -138
  81. package/routes/_workspace/settings/fields2.js +11 -11
  82. package/routes/_workspace/settings/github2.js +6 -6
  83. package/routes/_workspace/settings/groups2.js +26 -26
  84. package/routes/_workspace/settings/import2.js +414 -151
  85. package/routes/_workspace/settings/import3.js +7 -3
  86. package/routes/_workspace/settings/index2.js +6 -6
  87. package/routes/_workspace/settings/labels2.js +21 -21
  88. package/routes/_workspace/settings/members2.js +27 -27
  89. package/routes/_workspace/settings/notifications2.js +8 -8
  90. package/routes/_workspace/settings/parallelworks2.js +32 -32
  91. package/routes/_workspace/settings/roles2.js +24 -24
  92. package/routes/_workspace/settings/runners2.js +15 -15
  93. package/routes/_workspace/settings/sessions2.js +17 -17
  94. package/routes/_workspace/settings/slack2.js +7 -7
  95. package/routes/_workspace/settings/sso2.js +31 -31
  96. package/routes/_workspace/settings/teams2.js +25 -25
  97. package/routes/_workspace/settings/tokens2.js +12 -12
  98. package/routes/_workspace/settings/webhooks2.js +13 -13
  99. package/routes/_workspace/teams/_key/areas/_area.js +8 -0
  100. package/routes/_workspace/teams/_key/areas/_area2.js +4 -0
  101. package/routes/_workspace/teams/_key/areas/_area3.js +9 -0
  102. package/routes/_workspace/teams/_key/areas/index.js +6 -0
  103. package/routes/_workspace/teams/_key/areas/index2.js +4 -0
  104. package/routes/_workspace/teams/_key/{areas3.js → areas/index3.js} +2 -2
  105. package/routes/_workspace/teams/_key/cycles/_number2.js +27 -27
  106. package/routes/_workspace/teams/_key/cycles/index2.js +24 -24
  107. package/routes/_workspace/teams/_key/settings2.js +29 -29
  108. package/routes/_workspace2.js +368 -368
  109. package/routes/_workspace/teams/_key/areas.js +0 -6
  110. package/routes/_workspace/teams/_key/areas2.js +0 -4
@@ -1,7 +1,7 @@
1
1
  import { AddIcon as e } from "./icons.js";
2
2
  import { usePeople as t } from "../lib/people.js";
3
- import { useCan as n } from "../lib/roles.js";
4
- import { docPropertiesQuery as r, propertyKinds as i, spaceScope as a, useDocPropertyActions as o } from "../lib/docProperties.js";
3
+ import { docPropertiesQuery as n, propertyKinds as r, spaceScope as i, useDocPropertyActions as a } from "../lib/docProperties.js";
4
+ import { useCan as o } from "../lib/roles.js";
5
5
  import { Button as s, Checkbox as c, ErrorText as l, IconButton as u, Input as d, Popover as f, Select as p, Textarea as m, menuDivider as h, useOpenMenu as g } from "@parallelworks/ui";
6
6
  import { Link as _ } from "@tanstack/react-router";
7
7
  import { useEffect as v, useState as y } from "react";
@@ -24,8 +24,8 @@ function T(e) {
24
24
  }
25
25
  };
26
26
  }
27
- function E({ workspace: e, doc: t, space: i, editable: s }) {
28
- let c = x("docProperties"), u = b(), { data: d = [] } = w(r(e, i)), f = n(e, "manage_labels", a(i)), p = o(e), m = t.properties ?? {};
27
+ function E({ workspace: e, doc: t, space: r, editable: s }) {
28
+ let c = x("docProperties"), u = b(), { data: d = [] } = w(n(e, r)), f = o(e, "manage_labels", i(r)), p = a(e), m = t.properties ?? {};
29
29
  if (d.length === 0 && !(s && f)) return null;
30
30
  let h = (e, n) => p.setValues.mutate({
31
31
  doc: t.key,
@@ -54,14 +54,14 @@ function E({ workspace: e, doc: t, space: i, editable: s }) {
54
54
  }, t.id)),
55
55
  s && f && /* @__PURE__ */ S(A, {
56
56
  workspace: e,
57
- space: i
57
+ space: r
58
58
  }),
59
59
  p.setValues.error && /* @__PURE__ */ S(l, { children: u(p.setValues.error) })
60
60
  ]
61
61
  });
62
62
  }
63
63
  function D({ workspace: e, property: t, admin: n }) {
64
- let r = x("docProperties"), i = g(), a = o(e), [s, c] = y(!1), l = /* @__PURE__ */ S("span", {
64
+ let r = x("docProperties"), i = g(), o = a(e), [s, c] = y(!1), l = /* @__PURE__ */ S("span", {
65
65
  className: "truncate",
66
66
  children: t.name
67
67
  });
@@ -78,7 +78,7 @@ function D({ workspace: e, property: t, admin: n }) {
78
78
  {
79
79
  label: r("remove"),
80
80
  destructive: !0,
81
- onClick: () => a.remove.mutate(t.id)
81
+ onClick: () => o.remove.mutate(t.id)
82
82
  }
83
83
  ];
84
84
  return /* @__PURE__ */ S(f, {
@@ -99,7 +99,7 @@ function D({ workspace: e, property: t, admin: n }) {
99
99
  property: t,
100
100
  onDone: () => c(!1),
101
101
  onRemove: () => {
102
- a.remove.mutate(t.id), c(!1);
102
+ o.remove.mutate(t.id), c(!1);
103
103
  }
104
104
  })
105
105
  });
@@ -228,8 +228,8 @@ function A({ workspace: t, space: n }) {
228
228
  })
229
229
  });
230
230
  }
231
- function j({ workspace: e, space: t, property: n, onDone: r, onRemove: a }) {
232
- let c = x("docProperties"), f = b(), h = o(e), [g, _] = y(n?.name ?? ""), [v, w] = y(n?.kind ?? "text"), [T, E] = y((n?.options ?? []).map((e) => e.name).join("\n")), D = v === "select" || v === "multi_select", O = () => T.split("\n").map((e) => e.trim()).filter(Boolean).map((e) => {
231
+ function j({ workspace: e, space: t, property: n, onDone: i, onRemove: o }) {
232
+ let c = x("docProperties"), f = b(), h = a(e), [g, _] = y(n?.name ?? ""), [v, w] = y(n?.kind ?? "text"), [T, E] = y((n?.options ?? []).map((e) => e.name).join("\n")), D = v === "select" || v === "multi_select", O = () => T.split("\n").map((e) => e.trim()).filter(Boolean).map((e) => {
233
233
  let t = n?.options.find((t) => t.name === e)?.id;
234
234
  return {
235
235
  name: e,
@@ -242,12 +242,12 @@ function j({ workspace: e, space: t, property: n, onDone: r, onRemove: a }) {
242
242
  id: n.id,
243
243
  name: g,
244
244
  ...D && { options: O() }
245
- }, { onSuccess: r }) : h.create.mutate({
245
+ }, { onSuccess: i }) : h.create.mutate({
246
246
  ...t && { space: t },
247
247
  name: g,
248
248
  kind: v,
249
249
  ...D && { options: O() }
250
- }, { onSuccess: r });
250
+ }, { onSuccess: i });
251
251
  },
252
252
  className: "space-y-3 text-sm",
253
253
  children: [
@@ -267,7 +267,7 @@ function j({ workspace: e, space: t, property: n, onDone: r, onRemove: a }) {
267
267
  className: "mt-1",
268
268
  children: /* @__PURE__ */ S(p, {
269
269
  value: v,
270
- items: i.map((e) => ({
270
+ items: r.map((e) => ({
271
271
  value: e,
272
272
  label: c(`kinds.${e}`)
273
273
  })),
@@ -296,7 +296,7 @@ function j({ workspace: e, space: t, property: n, onDone: r, onRemove: a }) {
296
296
  k.error && /* @__PURE__ */ S(l, { children: f(k.error) }),
297
297
  /* @__PURE__ */ C("div", {
298
298
  className: "flex justify-between gap-2",
299
- children: [a ? /* @__PURE__ */ S(u, {
299
+ children: [o ? /* @__PURE__ */ S(u, {
300
300
  variant: "ghost",
301
301
  size: "sm",
302
302
  label: c("remove"),
@@ -304,7 +304,7 @@ function j({ workspace: e, space: t, property: n, onDone: r, onRemove: a }) {
304
304
  "aria-hidden": !0,
305
305
  children: "×"
306
306
  }),
307
- onClick: a
307
+ onClick: o
308
308
  }) : /* @__PURE__ */ S("span", {}), /* @__PURE__ */ S(s, {
309
309
  type: "submit",
310
310
  size: "sm",
@@ -1,9 +1,9 @@
1
1
  import { docsQuery as e } from "../api/queries.js";
2
2
  import { docRef as t } from "../lib/docs.js";
3
3
  import { usePeople as n } from "../lib/people.js";
4
- import { useCan as r } from "../lib/roles.js";
5
- import { DocIcon as i } from "./DocIcon.js";
6
- import { docPropertiesQuery as a, spaceScope as o, useDocPropertyActions as s } from "../lib/docProperties.js";
4
+ import { DocIcon as r } from "./DocIcon.js";
5
+ import { docPropertiesQuery as i, spaceScope as a, useDocPropertyActions as o } from "../lib/docProperties.js";
6
+ import { useCan as s } from "../lib/roles.js";
7
7
  import { usePropertyText as c } from "./DocProperties.js";
8
8
  import { cx as l } from "@parallelworks/ui";
9
9
  import { Link as u } from "@tanstack/react-router";
@@ -14,13 +14,13 @@ import { keepPreviousData as g, useQuery as _ } from "@tanstack/react-query";
14
14
  // src/components/DocTable.tsx
15
15
  var v = (e) => e.kind === "select" || e.kind === "person";
16
16
  function y(t, n, r) {
17
- let i = Object.entries(r.filters ?? {}).map(([e, t]) => `${e}=${t}`), { data: o = [], isPending: s } = _({
17
+ let a = Object.entries(r.filters ?? {}).map(([e, t]) => `${e}=${t}`), { data: o = [], isPending: s } = _({
18
18
  ...e(t, {
19
19
  ...n === "workspace" ? { workspace: !0 } : { team: n },
20
- ...i.length > 0 && { property: i }
20
+ ...a.length > 0 && { property: a }
21
21
  }),
22
22
  placeholderData: g
23
- }), { data: l = [] } = _(a(t, n)), u = c(t), d = r.sort ?? "title", f = l.find((e) => e.id === d), p = (e) => {
23
+ }), { data: l = [] } = _(i(t, n)), u = c(t), d = r.sort ?? "title", f = l.find((e) => e.id === d), p = (e) => {
24
24
  if (d === "updated") return e.updatedAt;
25
25
  if (!f) return e.title.toLowerCase();
26
26
  let t = e.properties?.[f.id];
@@ -35,13 +35,13 @@ function y(t, n, r) {
35
35
  isPending: s
36
36
  };
37
37
  }
38
- function b({ workspace: e, space: n, layout: r, config: a }) {
38
+ function b({ workspace: e, space: n, layout: i, config: a }) {
39
39
  let o = p("docViews"), s = f(), { docs: l, props: d, isPending: g } = y(e, n, a), _ = c(e), b = (e, t) => e.properties?.[t.id];
40
40
  if (g) return /* @__PURE__ */ m("p", {
41
41
  className: "p-4 text-sm text-muted-foreground",
42
42
  children: o("loading")
43
43
  });
44
- if (r === "board") {
44
+ if (i === "board") {
45
45
  let t = d.find((e) => e.id === a.groupBy && v(e));
46
46
  return t ? /* @__PURE__ */ m(x, {
47
47
  workspace: e,
@@ -83,7 +83,7 @@ function b({ workspace: e, space: n, layout: r, config: a }) {
83
83
  doc: t(n)
84
84
  },
85
85
  className: "flex items-center gap-2 font-medium hover:underline",
86
- children: [/* @__PURE__ */ m(i, { icon: n.icon }), /* @__PURE__ */ m("span", {
86
+ children: [/* @__PURE__ */ m(r, { icon: n.icon }), /* @__PURE__ */ m("span", {
87
87
  className: "truncate",
88
88
  children: n.title
89
89
  })]
@@ -97,8 +97,8 @@ function b({ workspace: e, space: n, layout: r, config: a }) {
97
97
  })
98
98
  });
99
99
  }
100
- function x({ workspace: e, space: a, docs: f, props: g, by: _ }) {
101
- let v = p("docViews"), { members: y } = n(e), b = c(e), x = r(e, "edit_docs", o(a)), S = s(e), [C, w] = d(null), [T, E] = d(null), D = [..._.kind === "select" ? _.options.map((e) => ({
100
+ function x({ workspace: e, space: i, docs: f, props: g, by: _ }) {
101
+ let v = p("docViews"), { members: y } = n(e), b = c(e), x = s(e, "edit_docs", a(i)), S = o(e), [C, w] = d(null), [T, E] = d(null), D = [..._.kind === "select" ? _.options.map((e) => ({
102
102
  key: e.id ?? "",
103
103
  label: e.name
104
104
  })) : y.map((e) => ({
@@ -115,7 +115,7 @@ function x({ workspace: e, space: a, docs: f, props: g, by: _ }) {
115
115
  className: "flex gap-3 overflow-x-auto p-3",
116
116
  "aria-label": v("board"),
117
117
  children: k.map((n) => {
118
- let r = f.filter((e) => O(e) === n.key);
118
+ let i = f.filter((e) => O(e) === n.key);
119
119
  return /* @__PURE__ */ h("li", {
120
120
  "aria-label": n.label,
121
121
  onDragOver: (e) => {
@@ -136,11 +136,11 @@ function x({ workspace: e, space: a, docs: f, props: g, by: _ }) {
136
136
  children: n.label
137
137
  }), /* @__PURE__ */ m("span", {
138
138
  className: "text-muted-foreground tabular-nums",
139
- children: r.length
139
+ children: i.length
140
140
  })]
141
141
  }), /* @__PURE__ */ m("ul", {
142
142
  className: "flex flex-col gap-2 px-2 pb-2",
143
- children: r.map((n) => /* @__PURE__ */ h("li", {
143
+ children: i.map((n) => /* @__PURE__ */ h("li", {
144
144
  draggable: x,
145
145
  onDragStart: () => w(n.key),
146
146
  onDragEnd: () => w(null),
@@ -152,7 +152,7 @@ function x({ workspace: e, space: a, docs: f, props: g, by: _ }) {
152
152
  doc: t(n)
153
153
  },
154
154
  className: "flex items-center gap-2 font-medium hover:underline",
155
- children: [/* @__PURE__ */ m(i, { icon: n.icon }), /* @__PURE__ */ m("span", {
155
+ children: [/* @__PURE__ */ m(r, { icon: n.icon }), /* @__PURE__ */ m("span", {
156
156
  className: "truncate",
157
157
  children: n.title
158
158
  })]
@@ -1,12 +1,12 @@
1
1
  import { Link as e, useNavigate as t } from "../lib/router.js";
2
2
  import { docQuery as n, docTemplatesQuery as r, docsQuery as i, teamsQuery as a, workspaceQuery as o } from "../api/queries.js";
3
- import { AddIcon as s, ChevronRightIcon as c, FileTextIcon as l, SearchIcon as u } from "./icons.js";
4
- import { teamPath as d } from "../lib/teamPaths.js";
5
- import { useLinkItems as f } from "../lib/menus.js";
6
- import { openShare as p } from "../lib/share.js";
7
- import { docRef as m, useDocActions as h, useDocMenu as g } from "../lib/docs.js";
8
- import { EntityIcon as _ } from "./EntityIcon.js";
9
- import { DocIcon as v } from "./DocIcon.js";
3
+ import { useLinkItems as s } from "../lib/menus.js";
4
+ import { openShare as c } from "../lib/share.js";
5
+ import { docRef as l, useDocActions as u, useDocMenu as d } from "../lib/docs.js";
6
+ import { AddIcon as f, ChevronRightIcon as p, FileTextIcon as m, SearchIcon as h } from "./icons.js";
7
+ import { EntityIcon as g } from "./EntityIcon.js";
8
+ import { DocIcon as _ } from "./DocIcon.js";
9
+ import { teamPath as v } from "../lib/teamPaths.js";
10
10
  import { indentLevel as y, revealed as b, saveTree as ee, savedTree as te, spaceOf as x, toggled as S } from "../lib/docTree.js";
11
11
  import { useMarkdownTransfer as C } from "./MarkdownTransfer.js";
12
12
  import { Combobox as ne, IconButton as w, RelativeTime as T, SearchInput as re, Tooltip as E, buttonClasses as ie, menuDivider as D, useOpenMenu as O } from "@parallelworks/ui";
@@ -54,11 +54,11 @@ var K = {
54
54
  after: "relative after:absolute after:inset-x-1 after:-bottom-px after:h-0.5 after:rounded after:bg-primary",
55
55
  inside: "ring-2 ring-primary ring-inset"
56
56
  };
57
- function q({ workspace: r, current: d, page: f = !1, onIndex: p = !1, menu: v, team: y }) {
57
+ function q({ workspace: r, current: s, page: c = !1, onIndex: _ = !1, menu: v, team: y }) {
58
58
  let T = j("docs"), { data: E } = ce(a(r)), { data: D } = ce(o(r)), { data: P = [] } = F(i(r, { top: !0 })), { data: I } = F({
59
- ...n(r, d ?? ""),
60
- enabled: !!d
61
- }), L = I?.key ?? d, le = O(), ue = g(r), fe = t(), z = h(r), V = C(r), [H, U] = A(!1), [G, K] = A(""), [q, me] = A(""), [J, ge] = A(!1), ve = y ? `${r}/${y.id}` : r, [Y, X] = A(() => te(ve)), { doc: Z, over: ye } = oe(W.subscribe, W.get), be = ae(null);
59
+ ...n(r, s ?? ""),
60
+ enabled: !!s
61
+ }), L = I?.key ?? s, le = O(), ue = d(r), fe = t(), z = u(r), V = C(r), [H, U] = A(!1), [G, K] = A(""), [q, me] = A(""), [J, ge] = A(!1), ve = y ? `${r}/${y.id}` : r, [Y, X] = A(() => te(ve)), { doc: Z, over: ye } = oe(W.subscribe, W.get), be = ae(null);
62
62
  k(() => {
63
63
  let e = setTimeout(() => me(G.trim()), 200);
64
64
  return () => clearTimeout(e);
@@ -69,7 +69,7 @@ function q({ workspace: r, current: d, page: f = !1, onIndex: p = !1, menu: v, t
69
69
  k(() => {
70
70
  xe && X((e) => b(e, xe, Se ? Se.split(" ") : []));
71
71
  }, [xe, Se]);
72
- let $ = !f && Y.collapsed && !H, Ce = {
72
+ let $ = !c && Y.collapsed && !H, Ce = {
73
73
  over: ye,
74
74
  start: (e) => W.set({ doc: e }),
75
75
  end: () => W.set({
@@ -118,28 +118,28 @@ function q({ workspace: r, current: d, page: f = !1, onIndex: p = !1, menu: v, t
118
118
  to: "/$workspace/docs/$doc",
119
119
  params: {
120
120
  workspace: r,
121
- doc: m(e)
121
+ doc: l(e)
122
122
  },
123
123
  search: { rename: !0 }
124
124
  }) })
125
125
  }, Te = /* @__PURE__ */ N(se, { children: [/* @__PURE__ */ M(w, {
126
126
  variant: "ghost",
127
127
  size: "xs",
128
- icon: /* @__PURE__ */ M(u, {}),
128
+ icon: /* @__PURE__ */ M(h, {}),
129
129
  label: T("search"),
130
130
  pressed: H,
131
131
  onClick: () => {
132
132
  U((e) => !e), K("");
133
133
  },
134
- className: f ? "" : B
134
+ className: c ? "" : B
135
135
  }), Q.length === 0 ? /* @__PURE__ */ M(w, {
136
136
  variant: "ghost",
137
137
  size: "xs",
138
- icon: /* @__PURE__ */ M(s, {}),
138
+ icon: /* @__PURE__ */ M(f, {}),
139
139
  label: T("new"),
140
140
  onClick: () => z.create.mutate({}),
141
141
  disabled: z.create.isPending,
142
- className: f ? "" : B
142
+ className: c ? "" : B
143
143
  }) : /* @__PURE__ */ M(ne, {
144
144
  items: [{
145
145
  value: "",
@@ -163,8 +163,8 @@ function q({ workspace: r, current: d, page: f = !1, onIndex: p = !1, menu: v, t
163
163
  variant: "ghost",
164
164
  size: "xs",
165
165
  iconOnly: !0
166
- }), !f && B),
167
- children: /* @__PURE__ */ M(s, {})
166
+ }), !c && B),
167
+ children: /* @__PURE__ */ M(f, {})
168
168
  })
169
169
  })] });
170
170
  return y ? /* @__PURE__ */ N("section", {
@@ -175,23 +175,23 @@ function q({ workspace: r, current: d, page: f = !1, onIndex: p = !1, menu: v, t
175
175
  team: y,
176
176
  name: T("title"),
177
177
  row: !0,
178
- icon: /* @__PURE__ */ M(l, { className: "size-4" }),
178
+ icon: /* @__PURE__ */ M(m, { className: "size-4" }),
179
179
  docs: P.filter((e) => e.teamId === y.id),
180
180
  closed: Y.closedSpaces.includes(y.id),
181
181
  onToggle: () => X((e) => S(e, y.id, !0))
182
182
  }), V.dialog]
183
183
  }) : /* @__PURE__ */ N("section", {
184
184
  "aria-label": T("title"),
185
- className: R(f && "flex min-h-0 flex-1 flex-col"),
185
+ className: R(c && "flex min-h-0 flex-1 flex-col"),
186
186
  children: [
187
- f ? /* @__PURE__ */ N("div", {
187
+ c ? /* @__PURE__ */ N("div", {
188
188
  className: "flex h-9 shrink-0 items-center gap-1 px-2",
189
189
  children: [/* @__PURE__ */ M("h1", {
190
190
  className: "flex-1 text-sm font-semibold",
191
191
  children: T("title")
192
192
  }), Te]
193
193
  }) : /* @__PURE__ */ N("div", {
194
- className: R("group flex h-8 items-center gap-0.5 rounded-md pr-1 text-sm text-muted-foreground hover:bg-muted hover:text-foreground", p && de),
194
+ className: R("group flex h-8 items-center gap-0.5 rounded-md pr-1 text-sm text-muted-foreground hover:bg-muted hover:text-foreground", _ && de),
195
195
  children: [
196
196
  /* @__PURE__ */ N(e, {
197
197
  to: "/$workspace/docs",
@@ -199,7 +199,7 @@ function q({ workspace: r, current: d, page: f = !1, onIndex: p = !1, menu: v, t
199
199
  onContextMenu: v ? (e) => le(e, v) : void 0,
200
200
  activeOptions: { exact: !0 },
201
201
  className: "flex h-full min-w-0 flex-1 items-center gap-2.5 pl-2",
202
- children: [/* @__PURE__ */ M(l, { className: "size-4" }), /* @__PURE__ */ M("span", {
202
+ children: [/* @__PURE__ */ M(m, { className: "size-4" }), /* @__PURE__ */ M("span", {
203
203
  className: "truncate",
204
204
  children: T("title")
205
205
  })]
@@ -208,7 +208,7 @@ function q({ workspace: r, current: d, page: f = !1, onIndex: p = !1, menu: v, t
208
208
  /* @__PURE__ */ M(w, {
209
209
  variant: "ghost",
210
210
  size: "xs",
211
- icon: /* @__PURE__ */ M(c, { className: R(!$ && "rotate-90") }),
211
+ icon: /* @__PURE__ */ M(p, { className: R(!$ && "rotate-90") }),
212
212
  label: T($ ? "expand" : "collapse"),
213
213
  "aria-expanded": !$,
214
214
  onClick: () => X((e) => ({
@@ -231,7 +231,7 @@ function q({ workspace: r, current: d, page: f = !1, onIndex: p = !1, menu: v, t
231
231
  })
232
232
  }),
233
233
  !$ && /* @__PURE__ */ M("div", {
234
- className: R("pt-1", f && "min-h-0 flex-1 overflow-y-auto pb-3"),
234
+ className: R("pt-1", c && "min-h-0 flex-1 overflow-y-auto pb-3"),
235
235
  children: q ? /* @__PURE__ */ M(he, {
236
236
  workspace: r,
237
237
  query: q,
@@ -241,7 +241,7 @@ function q({ workspace: r, current: d, page: f = !1, onIndex: p = !1, menu: v, t
241
241
  ctx: we,
242
242
  id: "workspace",
243
243
  name: D.name,
244
- icon: /* @__PURE__ */ M(_, {
244
+ icon: /* @__PURE__ */ M(g, {
245
245
  icon: D.icon,
246
246
  color: D.color,
247
247
  name: D.name
@@ -255,7 +255,7 @@ function q({ workspace: r, current: d, page: f = !1, onIndex: p = !1, menu: v, t
255
255
  id: e.id,
256
256
  team: e,
257
257
  name: e.name,
258
- icon: /* @__PURE__ */ M(_, {
258
+ icon: /* @__PURE__ */ M(g, {
259
259
  icon: e.icon,
260
260
  color: e.color,
261
261
  name: e.name
@@ -271,7 +271,7 @@ function q({ workspace: r, current: d, page: f = !1, onIndex: p = !1, menu: v, t
271
271
  className: "mt-1 flex h-7 w-full items-center gap-0.5 rounded-md pl-1 text-xs font-medium text-muted-foreground hover:bg-muted hover:text-foreground",
272
272
  children: [/* @__PURE__ */ M("span", {
273
273
  className: "flex size-5 items-center justify-center",
274
- children: /* @__PURE__ */ M(c, { className: R("size-3", J && "rotate-90") })
274
+ children: /* @__PURE__ */ M(p, { className: R("size-3", J && "rotate-90") })
275
275
  }), T("archived")]
276
276
  }),
277
277
  J && /* @__PURE__ */ M(_e, {
@@ -284,10 +284,10 @@ function q({ workspace: r, current: d, page: f = !1, onIndex: p = !1, menu: v, t
284
284
  ]
285
285
  });
286
286
  }
287
- function pe({ ctx: e, id: n, team: i, name: a, icon: o, docs: l, closed: u, onToggle: m, row: g = !1 }) {
288
- let _ = j("docs"), v = j("common"), y = O(), b = h(e.workspace), ee = f(), te = t(), x = e.workspace, { data: S = [] } = F(r(x)), C = `docs-space-${n}`, ne = j("docViews"), T = () => [
287
+ function pe({ ctx: e, id: n, team: i, name: a, icon: o, docs: l, closed: d, onToggle: m, row: h = !1 }) {
288
+ let g = j("docs"), _ = j("common"), y = O(), b = u(e.workspace), ee = s(), te = t(), x = e.workspace, { data: S = [] } = F(r(x)), C = `docs-space-${n}`, ne = j("docViews"), T = () => [
289
289
  {
290
- label: _("newInSpace"),
290
+ label: g("newInSpace"),
291
291
  onClick: () => b.create.mutate({ team: i?.key })
292
292
  },
293
293
  {
@@ -301,7 +301,7 @@ function pe({ ctx: e, id: n, team: i, name: a, icon: o, docs: l, closed: u, onTo
301
301
  })
302
302
  },
303
303
  {
304
- label: _("newFromTemplate"),
304
+ label: g("newFromTemplate"),
305
305
  items: S.map((e) => ({
306
306
  label: e.title,
307
307
  onClick: () => b.create.mutate({
@@ -311,27 +311,27 @@ function pe({ ctx: e, id: n, team: i, name: a, icon: o, docs: l, closed: u, onTo
311
311
  }))
312
312
  },
313
313
  {
314
- label: _("importFiles"),
314
+ label: g("importFiles"),
315
315
  onClick: () => e.transfer.pick({ space: i?.key ?? "workspace" })
316
316
  },
317
317
  {
318
- label: _("importFolder"),
318
+ label: g("importFolder"),
319
319
  onClick: () => e.transfer.pick({ space: i?.key ?? "workspace" }, !0)
320
320
  },
321
321
  {
322
- label: _("exportMarkdown"),
322
+ label: g("exportMarkdown"),
323
323
  onClick: () => e.transfer.download({ space: i?.key ?? "workspace" })
324
324
  },
325
325
  {
326
- label: _("shareSpace"),
327
- onClick: () => p({
326
+ label: g("shareSpace"),
327
+ onClick: () => c({
328
328
  space: i?.key ?? "workspace",
329
329
  title: a
330
330
  })
331
331
  },
332
332
  ...i ? [
333
333
  {
334
- label: _("teamIssues"),
334
+ label: g("teamIssues"),
335
335
  onClick: () => te({
336
336
  to: "/$workspace/teams/$key/issues",
337
337
  params: {
@@ -341,7 +341,7 @@ function pe({ ctx: e, id: n, team: i, name: a, icon: o, docs: l, closed: u, onTo
341
341
  })
342
342
  },
343
343
  D,
344
- ...ee(d(x, i.key, "issues"))
344
+ ...ee(v(x, i.key, "issues"))
345
345
  ] : []
346
346
  ], re = (t) => {
347
347
  t.dataTransfer.types.includes(le) && (t.preventDefault(), e.drag.hover(`space-${n}`, "inside"));
@@ -357,24 +357,24 @@ function pe({ ctx: e, id: n, team: i, name: a, icon: o, docs: l, closed: u, onTo
357
357
  label: a
358
358
  }) : /* @__PURE__ */ M("p", {
359
359
  id: C,
360
- className: R("py-1 text-xs text-muted-foreground", g ? "pl-2" : "pl-9"),
361
- children: _("emptyTeam")
360
+ className: R("py-1 text-xs text-muted-foreground", h ? "pl-2" : "pl-9"),
361
+ children: g("emptyTeam")
362
362
  }), ae = /* @__PURE__ */ M(w, {
363
363
  variant: "ghost",
364
364
  size: "xs",
365
- icon: /* @__PURE__ */ M(s, {}),
366
- label: _("newInTeamNamed", { team: i?.name ?? a }),
365
+ icon: /* @__PURE__ */ M(f, {}),
366
+ label: g("newInTeamNamed", { team: i?.name ?? a }),
367
367
  onClick: () => b.create.mutate({ team: i?.key }),
368
- className: g ? void 0 : B
368
+ className: h ? void 0 : B
369
369
  }), A = /* @__PURE__ */ M(I, {
370
370
  items: T,
371
- label: v("moreActionsFor", { name: i?.name ?? a })
371
+ label: _("moreActionsFor", { name: i?.name ?? a })
372
372
  });
373
- return g ? /* @__PURE__ */ M(L, {
373
+ return h ? /* @__PURE__ */ M(L, {
374
374
  label: a,
375
375
  icon: o,
376
- open: !u,
377
- onOpenChange: (e) => e === u && m(),
376
+ open: !d,
377
+ onOpenChange: (e) => e === d && m(),
378
378
  onContextMenu: (e) => y(e, T()),
379
379
  onDragOver: re,
380
380
  onDrop: ie,
@@ -390,17 +390,17 @@ function pe({ ctx: e, id: n, team: i, name: a, icon: o, docs: l, closed: u, onTo
390
390
  onDrop: ie,
391
391
  children: [
392
392
  /* @__PURE__ */ M(E, {
393
- content: _(u ? "expand" : "collapse"),
393
+ content: g(d ? "expand" : "collapse"),
394
394
  children: /* @__PURE__ */ N("button", {
395
395
  type: "button",
396
396
  onClick: m,
397
- "aria-expanded": !u,
398
- "aria-controls": u ? void 0 : C,
397
+ "aria-expanded": !d,
398
+ "aria-controls": d ? void 0 : C,
399
399
  className: "flex h-full min-w-0 flex-1 items-center gap-1.5 text-left text-xs font-medium text-muted-foreground hover:text-foreground",
400
400
  children: [
401
401
  /* @__PURE__ */ M("span", {
402
402
  className: "flex size-5 shrink-0 items-center justify-center",
403
- children: /* @__PURE__ */ M(c, { className: R("size-3", !u && "rotate-90") })
403
+ children: /* @__PURE__ */ M(p, { className: R("size-3", !d && "rotate-90") })
404
404
  }),
405
405
  o,
406
406
  /* @__PURE__ */ M("span", {
@@ -413,7 +413,7 @@ function pe({ ctx: e, id: n, team: i, name: a, icon: o, docs: l, closed: u, onTo
413
413
  A,
414
414
  ae
415
415
  ]
416
- }), !u && k]
416
+ }), !d && k]
417
417
  });
418
418
  }
419
419
  function me({ ctx: e, id: t, docs: n, depth: r, trail: i, parent: a, above: o, label: s }) {
@@ -432,14 +432,14 @@ function me({ ctx: e, id: t, docs: n, depth: r, trail: i, parent: a, above: o, l
432
432
  });
433
433
  }
434
434
  function J({ ctx: t, doc: n, depth: r, trail: a, parent: o, above: s }) {
435
- let l = j("docs"), u = j("common"), d = O(), f = n.children > 0 && t.open.has(n.id), { data: p = [] } = F({
435
+ let c = j("docs"), u = j("common"), d = O(), f = n.children > 0 && t.open.has(n.id), { data: m = [] } = F({
436
436
  ...i(t.workspace, { parent: n.key }),
437
437
  enabled: f
438
438
  }), h = t.current === n.key, g = ae(null);
439
439
  k(() => {
440
440
  h && g.current?.scrollIntoView({ block: "nearest" });
441
441
  }, [h]);
442
- let _ = l("pathStep", {
442
+ let v = c("pathStep", {
443
443
  path: a,
444
444
  title: n.title
445
445
  }), b = `docs-tree-${n.id}`;
@@ -458,31 +458,31 @@ function J({ ctx: t, doc: n, depth: r, trail: a, parent: o, above: s }) {
458
458
  },
459
459
  children: [
460
460
  n.children > 0 ? /* @__PURE__ */ M(E, {
461
- content: l(f ? "collapse" : "expand"),
461
+ content: c(f ? "collapse" : "expand"),
462
462
  children: /* @__PURE__ */ M("button", {
463
463
  type: "button",
464
464
  onClick: () => t.toggle(n.id),
465
465
  "aria-expanded": f,
466
466
  "aria-controls": f ? b : void 0,
467
- "aria-label": l("inside", { title: n.title }),
467
+ "aria-label": c("inside", { title: n.title }),
468
468
  className: V,
469
- children: /* @__PURE__ */ M(c, { className: R("size-3", f && "rotate-90") })
469
+ children: /* @__PURE__ */ M(p, { className: R("size-3", f && "rotate-90") })
470
470
  })
471
471
  }) : /* @__PURE__ */ M("span", { className: "size-5 shrink-0" }),
472
472
  /* @__PURE__ */ M(E, {
473
- content: _,
473
+ content: v,
474
474
  children: /* @__PURE__ */ N(e, {
475
475
  to: "/$workspace/docs/$doc",
476
476
  params: {
477
477
  workspace: t.workspace,
478
- doc: m(n)
478
+ doc: l(n)
479
479
  },
480
480
  ref: g,
481
481
  "aria-current": h ? "page" : void 0,
482
482
  onContextMenu: (e) => d(e, t.menu(n)),
483
483
  className: "line-clamp-2 min-w-0 flex-1 break-words py-1 pr-1",
484
484
  children: [
485
- /* @__PURE__ */ M(v, {
485
+ /* @__PURE__ */ M(_, {
486
486
  icon: n.icon,
487
487
  className: "mr-1.5 inline-flex size-3.5 align-[-2px]",
488
488
  emojiClassName: "text-xs"
@@ -490,7 +490,7 @@ function J({ ctx: t, doc: n, depth: r, trail: a, parent: o, above: s }) {
490
490
  n.title,
491
491
  n.template && /* @__PURE__ */ M("span", {
492
492
  className: "ml-1.5 rounded border border-border px-1 align-middle text-[10px] font-medium text-muted-foreground",
493
- children: l("templateTag")
493
+ children: c("templateTag")
494
494
  })
495
495
  ]
496
496
  })
@@ -501,36 +501,36 @@ function J({ ctx: t, doc: n, depth: r, trail: a, parent: o, above: s }) {
501
501
  className: "mt-0.5 mr-0.5"
502
502
  })
503
503
  ]
504
- }), f && p.length > 0 && /* @__PURE__ */ M(me, {
504
+ }), f && m.length > 0 && /* @__PURE__ */ M(me, {
505
505
  ctx: t,
506
506
  id: b,
507
- docs: p,
507
+ docs: m,
508
508
  depth: r + 1,
509
- trail: _,
509
+ trail: v,
510
510
  parent: n,
511
511
  above: [...s, n.id],
512
- label: l("inside", { title: n.title })
512
+ label: c("inside", { title: n.title })
513
513
  })] });
514
514
  }
515
515
  function he({ workspace: t, query: n, current: r }) {
516
- let o = j("docs"), s = O(), c = g(t), { data: l = [] } = F(a(t)), [u, d] = A(H), { data: f, isPending: p } = F({
516
+ let o = j("docs"), s = O(), c = d(t), { data: u = [] } = F(a(t)), [f, p] = A(H), { data: m, isPending: h } = F({
517
517
  ...i(t, {
518
518
  q: n,
519
- limit: u
519
+ limit: f
520
520
  }),
521
521
  placeholderData: P
522
522
  });
523
- return p ? /* @__PURE__ */ M("p", {
523
+ return h ? /* @__PURE__ */ M("p", {
524
524
  className: "px-2 text-sm text-muted-foreground",
525
525
  children: o("searching")
526
- }) : f?.length ? /* @__PURE__ */ N("ul", {
526
+ }) : m?.length ? /* @__PURE__ */ N("ul", {
527
527
  className: "space-y-1",
528
528
  "aria-label": o("results"),
529
- children: [f.map((n) => /* @__PURE__ */ M("li", { children: /* @__PURE__ */ N(e, {
529
+ children: [m.map((n) => /* @__PURE__ */ M("li", { children: /* @__PURE__ */ N(e, {
530
530
  to: "/$workspace/docs/$doc",
531
531
  params: {
532
532
  workspace: t,
533
- doc: m(n)
533
+ doc: l(n)
534
534
  },
535
535
  onContextMenu: (e) => s(e, c(n)),
536
536
  "aria-current": r === n.key ? "page" : void 0,
@@ -538,7 +538,7 @@ function he({ workspace: t, query: n, current: r }) {
538
538
  children: [/* @__PURE__ */ N("span", {
539
539
  className: "flex items-center gap-2 font-medium",
540
540
  children: [
541
- /* @__PURE__ */ M(v, {
541
+ /* @__PURE__ */ M(_, {
542
542
  icon: n.icon,
543
543
  className: "size-3.5",
544
544
  emojiClassName: "text-xs"
@@ -549,13 +549,13 @@ function he({ workspace: t, query: n, current: r }) {
549
549
  }),
550
550
  /* @__PURE__ */ M("span", {
551
551
  className: "ml-auto shrink-0 text-xs font-normal text-muted-foreground",
552
- children: l.find((e) => e.id === n.teamId)?.key ?? o("workspaceShort")
552
+ children: u.find((e) => e.id === n.teamId)?.key ?? o("workspaceShort")
553
553
  })
554
554
  ]
555
555
  }), n.snippet && /* @__PURE__ */ M(ge, { text: n.snippet })]
556
- }) }, n.id)), f.length === u && u < U && /* @__PURE__ */ M("li", { children: /* @__PURE__ */ M("button", {
556
+ }) }, n.id)), m.length === f && f < U && /* @__PURE__ */ M("li", { children: /* @__PURE__ */ M("button", {
557
557
  type: "button",
558
- onClick: () => d((e) => Math.min(e + H, U)),
558
+ onClick: () => p((e) => Math.min(e + H, U)),
559
559
  className: "w-full rounded-md px-2 py-1.5 text-left text-sm text-muted-foreground hover:bg-muted hover:text-foreground",
560
560
  children: o("moreResults")
561
561
  }) })]
@@ -575,7 +575,7 @@ function ge({ text: e }) {
575
575
  });
576
576
  }
577
577
  function _e({ workspace: t, current: n }) {
578
- let r = j("docs"), a = O(), o = g(t), { data: s, isPending: c } = F(i(t, { archived: !0 }));
578
+ let r = j("docs"), a = O(), o = d(t), { data: s, isPending: c } = F(i(t, { archived: !0 }));
579
579
  return c ? null : s?.length ? /* @__PURE__ */ M("ul", {
580
580
  className: "space-y-px",
581
581
  "aria-label": r("archived"),
@@ -583,13 +583,13 @@ function _e({ workspace: t, current: n }) {
583
583
  to: "/$workspace/docs/$doc",
584
584
  params: {
585
585
  workspace: t,
586
- doc: m(r)
586
+ doc: l(r)
587
587
  },
588
588
  onContextMenu: (e) => a(e, o(r)),
589
589
  "aria-current": n === r.key ? "page" : void 0,
590
590
  className: R(ue, "items-center gap-1.5 py-1 pr-1 pl-2", n === r.key && de),
591
591
  children: [
592
- /* @__PURE__ */ M(v, {
592
+ /* @__PURE__ */ M(_, {
593
593
  icon: r.icon,
594
594
  className: "size-3.5",
595
595
  emojiClassName: "text-xs"