@parallelworks/tandem-web 0.171.0 → 0.171.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/_virtual/_virtual_i18n/en/common.js +1 -0
- package/_virtual/_virtual_i18n/es/common.js +1 -0
- package/_virtual/_virtual_i18n/ja/common.js +1 -0
- package/_virtual/_virtual_i18n/ko/common.js +1 -0
- package/_virtual/_virtual_i18n/zh/common.js +1 -0
- package/components/AccessGrants.js +6 -6
- package/components/ActivityTimeline.js +57 -57
- package/components/ActorAvatar.js +4 -4
- package/components/AgentWork.js +494 -494
- package/components/AppLauncher.js +7 -7
- package/components/AreaLink.js +13 -13
- package/components/AreaTiles.js +13 -13
- package/components/AreaWork.js +22 -22
- package/components/Attachments.js +29 -29
- package/components/BlockHandle.js +3 -3
- package/components/BugRotation.js +8 -8
- package/components/CodeHostSettings.js +38 -38
- package/components/CollabEditor.js +13 -13
- package/components/CommandPalette.js +206 -206
- package/components/CustomFields.js +95 -95
- package/components/CustomerRequests.js +11 -11
- package/components/DashboardPanel.js +23 -23
- package/components/DateChip.js +21 -21
- package/components/DocHistory.js +14 -14
- package/components/DocIcon.js +4 -4
- package/components/DocIconPicker.js +4 -4
- package/components/DocLinkPicker.js +22 -22
- package/components/DocLook.js +16 -16
- package/components/DocProperties.js +81 -81
- package/components/DocTable.js +53 -53
- package/components/DocsTree.js +179 -179
- package/components/Editor.js +69 -69
- package/components/FavoritesNav.js +78 -78
- package/components/GitHub.js +87 -87
- package/components/Graph.js +14 -14
- package/components/HostActions.js +21 -21
- package/components/HostPanel.js +6 -6
- package/components/HoverCards.js +74 -74
- package/components/IssueBoard.js +13 -10
- package/components/IssueBreakdown.js +31 -31
- package/components/IssueCode.js +19 -19
- package/components/IssueEvent.js +12 -12
- package/components/IssueFilters.js +103 -99
- package/components/IssueGroup.js +16 -16
- package/components/IssueImport.js +13 -13
- package/components/IssueInsights.js +20 -20
- package/components/IssueListBlock.js +81 -81
- package/components/IssueRelations.js +34 -34
- package/components/IssueRow.js +31 -31
- package/components/IssueSentry.js +4 -4
- package/components/IssueTemplates.js +23 -23
- package/components/IssueTypes.js +40 -40
- package/components/MarkdownTransfer.js +10 -10
- package/components/MentionPicker.js +19 -19
- package/components/NewIssueDialog.js +53 -53
- package/components/NewProjectDialog.js +82 -82
- package/components/PersonActivity.js +13 -13
- package/components/PersonHoverCard.js +44 -44
- package/components/Planning.js +16 -16
- package/components/Reports.js +8 -8
- package/components/SettingsNav.js +15 -15
- package/components/ShareDialog.js +8 -8
- package/components/SharedViewer.js +23 -23
- package/components/SlashMenu.js +26 -26
- package/components/SubPages.js +10 -10
- package/components/TeamForm.js +9 -9
- package/components/TeamRepositories.js +21 -21
- package/components/TeamWorkflow.js +6 -6
- package/components/UnlinkedMentions.js +29 -29
- package/components/Updates.js +8 -8
- package/components/Widgets.js +4 -4
- package/components/WorkCounts.js +12 -12
- package/components/cycleCrumb.js +8 -8
- package/components/editorPlugins.js +101 -101
- package/components/settings.js +6 -6
- package/components/video.js +7 -7
- package/hostedApp.js +24 -24
- package/index.js +18 -18
- package/lib/assigneeOrder.js +6 -0
- package/lib/assignees.js +24 -20
- package/lib/attachments.js +12 -12
- package/lib/boardMove.js +27 -27
- package/lib/collab.js +1 -1
- package/lib/docs.js +115 -115
- package/lib/githubLink.js +7 -7
- package/lib/issueList.js +51 -51
- package/lib/issueMenu.js +117 -117
- package/lib/knowledge.js +134 -134
- package/lib/live.js +38 -38
- package/lib/notifications.js +47 -47
- package/lib/views.js +31 -31
- package/package.json +24 -24
- package/pages/area.js +64 -64
- package/pages/areas.js +199 -199
- package/pages/decisions.js +51 -51
- package/pages/issues.js +120 -120
- package/pages/projects.js +238 -238
- package/pages/triage.js +109 -109
- package/routes/_workspace/agents/_slug2.js +127 -127
- package/routes/_workspace/agents/index2.js +22 -22
- package/routes/_workspace/dashboards/_dashboardId2.js +84 -84
- package/routes/_workspace/dashboards/index2.js +34 -34
- package/routes/_workspace/docs/_doc2.js +267 -267
- package/routes/_workspace/docs/space2._space.js +31 -31
- package/routes/_workspace/docs2.js +4 -4
- package/routes/_workspace/graph2.js +11 -11
- package/routes/_workspace/graph3.js +11 -11
- package/routes/_workspace/issues/_identifier2.js +477 -477
- package/routes/_workspace/issues/index.js +13 -13
- package/routes/_workspace/knowledge/_term2.js +175 -175
- package/routes/_workspace/knowledge/_term3.js +4 -4
- package/routes/_workspace/knowledge/index.js +12 -12
- package/routes/_workspace/knowledge/index2.js +117 -117
- package/routes/_workspace/measures2.js +8 -8
- package/routes/_workspace/measures3.js +29 -29
- package/routes/_workspace/notifications2.js +263 -263
- package/routes/_workspace/people/_username.js +10 -10
- package/routes/_workspace/people/_username2.js +41 -41
- package/routes/_workspace/projects/_projectId3.js +303 -303
- package/routes/_workspace/projects/_projectId4.js +4 -4
- package/routes/_workspace/projects/_projectId_3.milestones._milestoneId.js +28 -28
- package/routes/_workspace/projects/_projectId_4.milestones._milestoneId.js +4 -4
- package/routes/_workspace/projects/index.js +8 -8
- package/routes/_workspace/settings/account2.js +8 -8
- package/routes/_workspace/settings/audit-log2.js +8 -8
- package/routes/_workspace/settings/audit-log3.js +155 -155
- package/routes/_workspace/settings/connections2.js +4 -4
- package/routes/_workspace/settings/fields2.js +5 -5
- package/routes/_workspace/settings/github2.js +11 -11
- package/routes/_workspace/settings/gitlab2.js +5 -5
- package/routes/_workspace/settings/groups2.js +52 -52
- package/routes/_workspace/settings/import2.js +39 -39
- package/routes/_workspace/settings/index2.js +5 -5
- package/routes/_workspace/settings/intercom2.js +11 -11
- package/routes/_workspace/settings/labels2.js +33 -33
- package/routes/_workspace/settings/members2.js +81 -81
- package/routes/_workspace/settings/notifications2.js +46 -46
- package/routes/_workspace/settings/parallelworks2.js +20 -20
- package/routes/_workspace/settings/roles2.js +41 -41
- package/routes/_workspace/settings/runners2.js +15 -15
- package/routes/_workspace/settings/sentry2.js +15 -15
- package/routes/_workspace/settings/sessions2.js +9 -9
- package/routes/_workspace/settings/sessions3.js +4 -4
- package/routes/_workspace/settings/slack2.js +12 -12
- package/routes/_workspace/settings/sso2.js +37 -37
- package/routes/_workspace/settings/sso3.js +7 -7
- package/routes/_workspace/settings/teams2.js +29 -29
- package/routes/_workspace/settings/tokens2.js +32 -32
- package/routes/_workspace/settings/tokens3.js +4 -4
- package/routes/_workspace/settings/webhooks2.js +41 -41
- package/routes/_workspace/settings/zendesk2.js +11 -11
- package/routes/_workspace/teams/_key/cycles/_number2.js +33 -33
- package/routes/_workspace/teams/_key/cycles/_number3.js +7 -7
- package/routes/_workspace/teams/_key/cycles/index2.js +37 -37
- package/routes/_workspace/teams/_key/issues.js +10 -10
- package/routes/_workspace/teams/_key/projects.js +6 -6
- package/routes/_workspace/teams/_key/settings2.js +396 -396
- package/routes/_workspace2.js +308 -308
- package/routes/_workspace3.js +8 -8
- package/routes/device2.js +4 -4
- package/routes/device3.js +4 -4
- package/routes/docs/_tag/_endpoint2.js +3 -3
- package/routes/docs/_tag/index2.js +3 -3
- package/routes/docs/route2.js +7 -7
- package/routes/index2.js +5 -5
- package/routes/login2.js +10 -10
- package/routes/new2.js +12 -12
- package/routes/new3.js +5 -5
- package/routes/request2._token.js +6 -6
- package/routes/share2._secret.js +4 -4
package/routes/_workspace2.js
CHANGED
|
@@ -1,40 +1,40 @@
|
|
|
1
1
|
import { api as e } from "../api/client.js";
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import {
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
19
|
-
import {
|
|
20
|
-
import {
|
|
21
|
-
import {
|
|
22
|
-
import {
|
|
23
|
-
import {
|
|
24
|
-
import {
|
|
25
|
-
import {
|
|
26
|
-
import {
|
|
27
|
-
import {
|
|
28
|
-
import {
|
|
29
|
-
import {
|
|
30
|
-
import {
|
|
31
|
-
import {
|
|
32
|
-
import {
|
|
33
|
-
import {
|
|
34
|
-
import {
|
|
35
|
-
import {
|
|
36
|
-
import {
|
|
37
|
-
import {
|
|
2
|
+
import { inboxQuery as t, issuesQuery as n, meQuery as r, myTeamsQuery as i, notificationsQuery as a, workspaceQuery as o } from "../api/queries.js";
|
|
3
|
+
import { AppLauncher as s } from "../components/AppLauncher.js";
|
|
4
|
+
import { CommandPalette as c } from "../components/CommandPalette.js";
|
|
5
|
+
import { DocsTree as l } from "../components/DocsTree.js";
|
|
6
|
+
import { EntityIcon as ee } from "../components/EntityIcon.js";
|
|
7
|
+
import { FavoritesNav as te } from "../components/FavoritesNav.js";
|
|
8
|
+
import { HostActions as u } from "../components/HostActions.js";
|
|
9
|
+
import { HostPanel as d } from "../components/HostPanel.js";
|
|
10
|
+
import { HoverCards as f } from "../components/HoverCards.js";
|
|
11
|
+
import { AddIcon as p, AgentIcon as ne, AreaIcon as re, ChartIcon as ie, ChevronDownIcon as m, CycleIcon as ae, InboxIcon as oe, LibraryIcon as se, ListViewIcon as ce, NotificationIcon as le, ProjectIcon as ue, SearchIcon as h, TriageIcon as de, UserIcon as fe, UsersIcon as g } from "../components/icons.js";
|
|
12
|
+
import { Logo as pe } from "../components/Logo.js";
|
|
13
|
+
import { NewIssueDialog as me } from "../components/NewIssueDialog.js";
|
|
14
|
+
import { PersonHoverCard as _ } from "../components/PersonHoverCard.js";
|
|
15
|
+
import { SettingsNav as he } from "../components/SettingsNav.js";
|
|
16
|
+
import { ShareDialogHost as ge } from "../components/ShareDialog.js";
|
|
17
|
+
import { ShortcutSheet as _e } from "../components/ShortcutSheet.js";
|
|
18
|
+
import { CreateTeamDialog as ve } from "../components/TeamForm.js";
|
|
19
|
+
import { docKey as v } from "../lib/docs.js";
|
|
20
|
+
import { useFavorites as ye } from "../lib/favorites.js";
|
|
21
|
+
import { useHost as be } from "../lib/host.js";
|
|
22
|
+
import { HostPanelProvider as xe, useHostPanel as y } from "../lib/hostPanel.js";
|
|
23
|
+
import { hostSignOut as Se } from "../lib/hostSignOut.js";
|
|
24
|
+
import { useInstall as Ce } from "../lib/install.js";
|
|
25
|
+
import { LiveProvider as we, useLive as b } from "../lib/live.js";
|
|
26
|
+
import { copyItem as Te, useLinkItems as Ee } from "../lib/menus.js";
|
|
27
|
+
import { NewIssueContext as De } from "../lib/newIssue.js";
|
|
28
|
+
import { usePushSync as Oe } from "../lib/notifications.js";
|
|
29
|
+
import { PaletteSelectionContext as ke } from "../lib/palette.js";
|
|
30
|
+
import { usePeople as x } from "../lib/people.js";
|
|
31
|
+
import { isViewAt as Ae } from "../lib/refs.js";
|
|
32
|
+
import { isBuiltIn as je, useCan as Me } from "../lib/roles.js";
|
|
33
|
+
import { useLocation as Ne, useNavigate as Pe } from "../lib/router.js";
|
|
34
|
+
import { useShortcuts as Fe } from "../lib/shortcuts.js";
|
|
35
|
+
import { teamPageOf as S, teamPath as Ie } from "../lib/teamPaths.js";
|
|
36
|
+
import { useSavedViews as C, useViewMenu as w, viewHref as Le } from "../lib/views.js";
|
|
37
|
+
import { Route as Re } from "./_workspace.js";
|
|
38
38
|
import { ActionMenu as ze, Avatar as Be, AvatarGroup as Ve, Combobox as He, CountBadge as T, IconButton as E, Kbd as Ue, PageHeaderBar as We, PageHeaderProvider as Ge, Tooltip as D, menuDivider as O, useOpenMenu as Ke } from "@parallelworks/ui";
|
|
39
39
|
import { Outlet as qe, useParams as Je } from "@tanstack/react-router";
|
|
40
40
|
import { Suspense as Ye, useCallback as Xe, useEffect as k, useMemo as Ze, useState as A } from "react";
|
|
@@ -42,159 +42,159 @@ import { useLocale as Qe, useTranslations as j } from "use-intl";
|
|
|
42
42
|
import { Fragment as M, jsx as N, jsxs as P } from "react/jsx-runtime";
|
|
43
43
|
import { useQuery as F, useQueryClient as $e, useSuspenseQuery as I } from "@tanstack/react-query";
|
|
44
44
|
import { MoreButton as et } from "@parallelworks/ui/list";
|
|
45
|
-
import { AppFrame as tt, AppFrameNavGroup as L, AppFrameNavItem as R, AppFrameToggle as
|
|
46
|
-
import { createPortal as
|
|
45
|
+
import { AppFrame as tt, AppFrameNavGroup as L, AppFrameNavItem as R, AppFrameToggle as nt, useAppFrame as z } from "@parallelworks/ui/app-frame";
|
|
46
|
+
import { createPortal as rt } from "react-dom";
|
|
47
47
|
// src/routes/$workspace.tsx?tsr-split=component
|
|
48
|
-
function
|
|
48
|
+
function it(e, t) {
|
|
49
49
|
let [n, r] = e.slice(`/${t}/docs/`.length).split("/");
|
|
50
|
-
return e.startsWith(`/${t}/docs/`) && n && r === void 0 ?
|
|
50
|
+
return e.startsWith(`/${t}/docs/`) && n && r === void 0 ? v(n) : void 0;
|
|
51
51
|
}
|
|
52
|
-
var
|
|
53
|
-
function
|
|
54
|
-
let { workspace:
|
|
52
|
+
var B = "inline-flex h-8 min-w-8 items-center justify-center rounded-md border border-[color-mix(in_oklab,currentColor_20%,transparent)] bg-[color-mix(in_oklab,currentColor_6%,transparent)] text-sm font-medium hover:bg-[color-mix(in_oklab,currentColor_12%,transparent)]", at = "absolute top-1.5 right-3 size-2 rounded-full bg-primary", V = (...e) => e.filter(Boolean).join(" ");
|
|
53
|
+
function H() {
|
|
54
|
+
let { workspace: d } = Re.useParams(), { data: g } = I(r), { data: _ } = I(o(d)), { data: v } = I(i(d)), y = be(), [b, x] = A(null), [Ae, C] = A(!1), w = Me(d, "manage_teams"), { canInstall: Le, install: Ve } = Ce(), z = Pe(), rt = $e(), H = Ke(), U = ye(d), W = j("workspace"), G = j("common"), K = Qe(), q = j("favorites"), vt = j("roles"), yt = Ee(), bt = (e) => [
|
|
55
55
|
{
|
|
56
|
-
label:
|
|
57
|
-
onClick: () =>
|
|
56
|
+
label: G("open"),
|
|
57
|
+
onClick: () => z({
|
|
58
58
|
to: "/$workspace/teams/$key/issues",
|
|
59
59
|
params: {
|
|
60
|
-
workspace:
|
|
60
|
+
workspace: d,
|
|
61
61
|
key: e.key
|
|
62
62
|
}
|
|
63
63
|
})
|
|
64
64
|
},
|
|
65
65
|
{
|
|
66
|
-
label:
|
|
66
|
+
label: W("newIssueInTeam"),
|
|
67
67
|
shortcut: "C",
|
|
68
68
|
onClick: () => Z({ team: e.key })
|
|
69
69
|
},
|
|
70
70
|
...e.cyclesEnabled ? [{
|
|
71
|
-
label:
|
|
72
|
-
onClick: () =>
|
|
71
|
+
label: W("cycles"),
|
|
72
|
+
onClick: () => z({
|
|
73
73
|
to: "/$workspace/teams/$key/cycles",
|
|
74
74
|
params: {
|
|
75
|
-
workspace:
|
|
75
|
+
workspace: d,
|
|
76
76
|
key: e.key
|
|
77
77
|
}
|
|
78
78
|
})
|
|
79
79
|
}] : [],
|
|
80
80
|
{
|
|
81
|
-
label:
|
|
82
|
-
onClick: () =>
|
|
81
|
+
label: W("teamSettings"),
|
|
82
|
+
onClick: () => z({
|
|
83
83
|
to: "/$workspace/teams/$key/settings",
|
|
84
84
|
params: {
|
|
85
|
-
workspace:
|
|
85
|
+
workspace: d,
|
|
86
86
|
key: e.key
|
|
87
87
|
}
|
|
88
88
|
})
|
|
89
89
|
},
|
|
90
90
|
{
|
|
91
|
-
label:
|
|
92
|
-
onClick: () =>
|
|
91
|
+
label: U.find("team", e.id) ? q("remove") : q("add"),
|
|
92
|
+
onClick: () => U.toggle("team", e.id)
|
|
93
93
|
},
|
|
94
94
|
O,
|
|
95
|
-
...yt(
|
|
96
|
-
|
|
95
|
+
...yt(Ie(d, e.key, "issues")),
|
|
96
|
+
Te(G("copyKey"), e.key)
|
|
97
97
|
], xt = (e) => ({
|
|
98
|
-
label:
|
|
99
|
-
onClick: () =>
|
|
100
|
-
}), J =
|
|
101
|
-
let e =
|
|
98
|
+
label: U.find("page", e) ? q("remove") : q("add"),
|
|
99
|
+
onClick: () => U.toggle("page", e)
|
|
100
|
+
}), J = Ne(), [St, Ct] = A(() => pt().expanded), [wt, Tt] = A(() => pt().width), Et = Ze(() => {
|
|
101
|
+
let e = S(J.pathname, d), t = e?.page === "issues" ? e.team : void 0, n = J.pathname === `/${d}/issues` || t !== void 0, r = J.search, i = n && !r.saved;
|
|
102
102
|
return {
|
|
103
|
-
mine: i && !t && (r.assignee ===
|
|
103
|
+
mine: i && !t && (r.assignee === g?.user.username || r.creator === g?.user.username),
|
|
104
104
|
team: i && !r.assignee ? t : void 0,
|
|
105
105
|
saved: n ? r.saved : void 0
|
|
106
106
|
};
|
|
107
107
|
}, [
|
|
108
108
|
J.pathname,
|
|
109
109
|
J.search,
|
|
110
|
-
|
|
111
|
-
|
|
110
|
+
d,
|
|
111
|
+
g?.user.username
|
|
112
112
|
]), Y = (e, t) => {
|
|
113
|
-
let n =
|
|
113
|
+
let n = S(J.pathname, d);
|
|
114
114
|
return n?.page === e && n.team === t;
|
|
115
|
-
}, [Dt, Ot] = A(() =>
|
|
115
|
+
}, [Dt, Ot] = A(() => ft(d)), kt = (e, t) => Ot((n) => {
|
|
116
116
|
let r = new Set(n);
|
|
117
|
-
return t ? r.delete(e) : r.add(e),
|
|
118
|
-
}), X = J.pathname.startsWith(`/${
|
|
119
|
-
...
|
|
117
|
+
return t ? r.delete(e) : r.add(e), ht(d, r), r;
|
|
118
|
+
}), X = J.pathname.startsWith(`/${d}/settings`), { data: At = [] } = F(t(d)), jt = v.some((e) => e.triageEnabled && !e.archivedAt), { data: Mt } = F({
|
|
119
|
+
...n(d, { triage: "only" }),
|
|
120
120
|
enabled: jt
|
|
121
|
-
}), Nt = (e) => Mt?.issues.filter((t) => t.teamId === e).length ?? 0, { data: Pt } = F(
|
|
122
|
-
|
|
123
|
-
let { key: It } = Je({ strict: !1 }), Z = Xe((e) =>
|
|
121
|
+
}), Nt = (e) => Mt?.issues.filter((t) => t.teamId === e).length ?? 0, { data: Pt } = F(a(d)), Ft = Pt?.unread ?? 0;
|
|
122
|
+
Oe();
|
|
123
|
+
let { key: It } = Je({ strict: !1 }), Z = Xe((e) => x({
|
|
124
124
|
...It && { team: It },
|
|
125
125
|
...e
|
|
126
126
|
}), [It]);
|
|
127
|
-
|
|
127
|
+
Fe({ c: () => Z() }, b === null);
|
|
128
128
|
let [Lt, Rt] = A(!1);
|
|
129
|
-
|
|
129
|
+
Fe({ "?": () => Rt(!0) });
|
|
130
130
|
let [zt, Q] = A(!1), [Bt, Vt] = A([]);
|
|
131
131
|
if (k(() => {
|
|
132
132
|
let e = (e) => {
|
|
133
|
-
!e.metaKey && !e.ctrlKey || e.altKey || e.shiftKey || e.key.toLowerCase() !== "k" || e.defaultPrevented || (e.preventDefault(), Q((e) => !e)), !e.metaKey && !e.ctrlKey || e.altKey || e.shiftKey || e.key.toLowerCase() !== "f" || e.defaultPrevented ||
|
|
133
|
+
!e.metaKey && !e.ctrlKey || e.altKey || e.shiftKey || e.key.toLowerCase() !== "k" || e.defaultPrevented || (e.preventDefault(), Q((e) => !e)), !e.metaKey && !e.ctrlKey || e.altKey || e.shiftKey || e.key.toLowerCase() !== "f" || e.defaultPrevented || gt() || (e.preventDefault(), Q(!0));
|
|
134
134
|
};
|
|
135
135
|
return window.addEventListener("keydown", e), () => window.removeEventListener("keydown", e);
|
|
136
|
-
}, []), !
|
|
137
|
-
let Ht =
|
|
138
|
-
$ === void 0 ? (await e.POST("/api/v1/auth/logout"),
|
|
136
|
+
}, []), !g) return null;
|
|
137
|
+
let Ht = g.mode === "platform", Ut = Le && !Ht, $ = g.signOutUrl, Wt = !y && (!Ht || $ !== void 0), Gt = async () => {
|
|
138
|
+
$ === void 0 ? (await e.POST("/api/v1/auth/logout"), rt.clear(), z({ to: "/login" })) : await Se($);
|
|
139
139
|
}, Kt = X ? void 0 : ({ expanded: e }) => {
|
|
140
140
|
let t = /* @__PURE__ */ N(He, {
|
|
141
|
-
items: [...
|
|
141
|
+
items: [...g.workspaces.map((e) => ({
|
|
142
142
|
value: e.slug,
|
|
143
143
|
label: e.name,
|
|
144
|
-
hint:
|
|
145
|
-
})), ...
|
|
144
|
+
hint: je(e.role) ? vt(`${e.role}.name`) : vt("custom")
|
|
145
|
+
})), ...g.canCreateWorkspace ? [{
|
|
146
146
|
value: "__new",
|
|
147
|
-
label:
|
|
147
|
+
label: W("createWorkspace")
|
|
148
148
|
}] : []],
|
|
149
|
-
value:
|
|
150
|
-
onValueChange: (e) =>
|
|
149
|
+
value: d,
|
|
150
|
+
onValueChange: (e) => z(e === "__new" ? { to: "/new" } : {
|
|
151
151
|
to: "/$workspace/issues",
|
|
152
|
-
params: { workspace: e ??
|
|
152
|
+
params: { workspace: e ?? d }
|
|
153
153
|
}),
|
|
154
|
-
placeholder:
|
|
155
|
-
"aria-label":
|
|
154
|
+
placeholder: W("switchWorkspacePlaceholder"),
|
|
155
|
+
"aria-label": W("switchWorkspace"),
|
|
156
156
|
trigger: /* @__PURE__ */ P("button", {
|
|
157
157
|
type: "button",
|
|
158
|
-
"aria-label": e ? void 0 :
|
|
159
|
-
onContextMenu: (e) =>
|
|
158
|
+
"aria-label": e ? void 0 : _.name,
|
|
159
|
+
onContextMenu: (e) => H(e, [
|
|
160
160
|
{
|
|
161
|
-
label:
|
|
162
|
-
onClick: () =>
|
|
161
|
+
label: W("workspaceSettings"),
|
|
162
|
+
onClick: () => z({
|
|
163
163
|
to: "/$workspace/settings",
|
|
164
|
-
params: { workspace:
|
|
164
|
+
params: { workspace: d }
|
|
165
165
|
})
|
|
166
166
|
},
|
|
167
167
|
{
|
|
168
|
-
label:
|
|
169
|
-
items: [...
|
|
168
|
+
label: W("switchWorkspace"),
|
|
169
|
+
items: [...g.workspaces.map((e) => ({
|
|
170
170
|
label: e.name,
|
|
171
|
-
checked: e.slug ===
|
|
172
|
-
onClick: () =>
|
|
171
|
+
checked: e.slug === d,
|
|
172
|
+
onClick: () => z({
|
|
173
173
|
to: "/$workspace/issues",
|
|
174
174
|
params: { workspace: e.slug }
|
|
175
175
|
})
|
|
176
|
-
})), ...
|
|
177
|
-
label:
|
|
178
|
-
onClick: () =>
|
|
176
|
+
})), ...g.canCreateWorkspace ? [O, {
|
|
177
|
+
label: W("createWorkspace"),
|
|
178
|
+
onClick: () => z({ to: "/new" })
|
|
179
179
|
}] : []]
|
|
180
180
|
},
|
|
181
181
|
O,
|
|
182
|
-
|
|
182
|
+
Te(W("copyWorkspaceSlug"), d),
|
|
183
183
|
...Wt ? [O, {
|
|
184
|
-
label:
|
|
184
|
+
label: W("signOut"),
|
|
185
185
|
onClick: Gt
|
|
186
186
|
}] : []
|
|
187
187
|
]),
|
|
188
|
-
className:
|
|
189
|
-
children: [
|
|
190
|
-
icon:
|
|
191
|
-
color:
|
|
192
|
-
name:
|
|
188
|
+
className: V("flex h-9 items-center gap-2 rounded-md text-left hover:bg-muted", e ? "w-full px-2" : "w-9 justify-center"),
|
|
189
|
+
children: [_.icon ? /* @__PURE__ */ N(ee, {
|
|
190
|
+
icon: _.icon,
|
|
191
|
+
color: _.color,
|
|
192
|
+
name: _.name,
|
|
193
193
|
className: "size-6 text-base"
|
|
194
|
-
}) : /* @__PURE__ */ N(
|
|
194
|
+
}) : /* @__PURE__ */ N(pe, { withName: !1 }), e && /* @__PURE__ */ P(M, { children: [/* @__PURE__ */ N("span", {
|
|
195
195
|
className: "min-w-0 flex-1 truncate text-sm font-semibold",
|
|
196
|
-
children:
|
|
197
|
-
}), /* @__PURE__ */ N(
|
|
196
|
+
children: _.name
|
|
197
|
+
}), /* @__PURE__ */ N(m, { className: "size-3.5 text-muted-foreground" })] })]
|
|
198
198
|
})
|
|
199
199
|
});
|
|
200
200
|
return e ? /* @__PURE__ */ P(M, { children: [/* @__PURE__ */ P("div", {
|
|
@@ -204,9 +204,9 @@ function U() {
|
|
|
204
204
|
className: "min-w-0 flex-1",
|
|
205
205
|
children: t
|
|
206
206
|
}),
|
|
207
|
-
!
|
|
208
|
-
!
|
|
209
|
-
apps:
|
|
207
|
+
!y && /* @__PURE__ */ N(u, { className: "hidden md:flex" }),
|
|
208
|
+
!y && /* @__PURE__ */ N(s, {
|
|
209
|
+
apps: g.apps ?? [],
|
|
210
210
|
className: "hidden md:block"
|
|
211
211
|
})
|
|
212
212
|
]
|
|
@@ -215,12 +215,12 @@ function U() {
|
|
|
215
215
|
children: [/* @__PURE__ */ P("button", {
|
|
216
216
|
type: "button",
|
|
217
217
|
onClick: () => Z(),
|
|
218
|
-
className:
|
|
218
|
+
className: V(B, "min-w-0 flex-1 gap-2 px-2"),
|
|
219
219
|
children: [
|
|
220
|
-
/* @__PURE__ */ N(
|
|
220
|
+
/* @__PURE__ */ N(p, { className: "size-3.5" }),
|
|
221
221
|
/* @__PURE__ */ N("span", {
|
|
222
222
|
className: "flex-1 text-left",
|
|
223
|
-
children:
|
|
223
|
+
children: W("newIssue")
|
|
224
224
|
}),
|
|
225
225
|
/* @__PURE__ */ N(Ue, {
|
|
226
226
|
keys: "C",
|
|
@@ -229,14 +229,14 @@ function U() {
|
|
|
229
229
|
})
|
|
230
230
|
]
|
|
231
231
|
}), /* @__PURE__ */ N(D, {
|
|
232
|
-
content:
|
|
232
|
+
content: W("openPalette"),
|
|
233
233
|
shortcut: "Mod+K",
|
|
234
234
|
children: /* @__PURE__ */ N("button", {
|
|
235
235
|
type: "button",
|
|
236
236
|
onClick: () => Q(!0),
|
|
237
|
-
"aria-label":
|
|
237
|
+
"aria-label": W("openPalette"),
|
|
238
238
|
"aria-keyshortcuts": "Meta+K Control+K",
|
|
239
|
-
className:
|
|
239
|
+
className: B,
|
|
240
240
|
children: /* @__PURE__ */ N(h, { className: "size-3.5" })
|
|
241
241
|
})
|
|
242
242
|
})]
|
|
@@ -244,201 +244,201 @@ function U() {
|
|
|
244
244
|
className: "flex flex-col items-center gap-1.5",
|
|
245
245
|
children: [
|
|
246
246
|
t,
|
|
247
|
-
!
|
|
248
|
-
!
|
|
247
|
+
!y && /* @__PURE__ */ N(s, { apps: g.apps ?? [] }),
|
|
248
|
+
!y && /* @__PURE__ */ N(u, { className: "flex-col" }),
|
|
249
249
|
/* @__PURE__ */ N(D, {
|
|
250
|
-
content:
|
|
250
|
+
content: W("newIssue"),
|
|
251
251
|
shortcut: "C",
|
|
252
252
|
side: "right",
|
|
253
253
|
children: /* @__PURE__ */ N("button", {
|
|
254
254
|
type: "button",
|
|
255
255
|
onClick: () => Z(),
|
|
256
|
-
"aria-label":
|
|
257
|
-
className:
|
|
258
|
-
children: /* @__PURE__ */ N(
|
|
256
|
+
"aria-label": W("newIssue"),
|
|
257
|
+
className: B,
|
|
258
|
+
children: /* @__PURE__ */ N(p, { className: "size-3.5" })
|
|
259
259
|
})
|
|
260
260
|
}),
|
|
261
261
|
/* @__PURE__ */ N(D, {
|
|
262
|
-
content:
|
|
262
|
+
content: W("openPalette"),
|
|
263
263
|
shortcut: "Mod+K",
|
|
264
264
|
side: "right",
|
|
265
265
|
children: /* @__PURE__ */ N("button", {
|
|
266
266
|
type: "button",
|
|
267
267
|
onClick: () => Q(!0),
|
|
268
|
-
"aria-label":
|
|
268
|
+
"aria-label": W("openPalette"),
|
|
269
269
|
"aria-keyshortcuts": "Meta+K Control+K",
|
|
270
|
-
className:
|
|
270
|
+
className: B,
|
|
271
271
|
children: /* @__PURE__ */ N(h, { className: "size-3.5" })
|
|
272
272
|
})
|
|
273
273
|
})
|
|
274
274
|
]
|
|
275
275
|
});
|
|
276
276
|
}, qt = ({ expanded: e, mobileOpen: t }) => {
|
|
277
|
-
if (X) return /* @__PURE__ */ N(
|
|
278
|
-
let n = !e, r = (e) => J.pathname === e || J.pathname.startsWith(`${e}/`), i = (e, t) => (n) =>
|
|
277
|
+
if (X) return /* @__PURE__ */ N(he, { workspace: d });
|
|
278
|
+
let n = !e, r = (e) => J.pathname === e || J.pathname.startsWith(`${e}/`), i = (e, t) => (n) => H(n, [
|
|
279
279
|
xt(e),
|
|
280
280
|
O,
|
|
281
281
|
...yt(t)
|
|
282
|
-
]), a = (e) => (t) =>
|
|
282
|
+
]), a = (e) => (t) => H(t, yt(e)), o = (e, t) => /* @__PURE__ */ P("span", {
|
|
283
283
|
className: "relative flex",
|
|
284
|
-
children: [e, n && t && /* @__PURE__ */ N("span", { className:
|
|
285
|
-
}), s =
|
|
286
|
-
let t = (t) =>
|
|
284
|
+
children: [e, n && t && /* @__PURE__ */ N("span", { className: at })]
|
|
285
|
+
}), s = v.filter((e) => !e.archivedAt), c = new Set(s.map((e) => e.id)), u = (e) => s.filter((t) => (t.parentId && c.has(t.parentId) ? t.parentId : "") === e), f = (e) => {
|
|
286
|
+
let t = (t) => Ie(d, e.key, t), r = At.filter((t) => t.identifier.startsWith(`${e.key}-`)).length;
|
|
287
287
|
return /* @__PURE__ */ P(L, {
|
|
288
288
|
label: e.name,
|
|
289
|
-
icon: o(/* @__PURE__ */ N(
|
|
289
|
+
icon: o(/* @__PURE__ */ N(ee, {
|
|
290
290
|
icon: e.icon,
|
|
291
291
|
color: e.color,
|
|
292
292
|
name: e.name
|
|
293
293
|
}), Nt(e.id) > 0),
|
|
294
|
-
selected:
|
|
294
|
+
selected: S(J.pathname, d)?.team === e.key,
|
|
295
295
|
open: !Dt.has(e.key),
|
|
296
296
|
onOpenChange: (t) => kt(e.key, t),
|
|
297
|
-
onContextMenu: (t) =>
|
|
297
|
+
onContextMenu: (t) => H(t, bt(e)),
|
|
298
298
|
action: /* @__PURE__ */ N(et, {
|
|
299
299
|
items: () => bt(e),
|
|
300
|
-
label:
|
|
300
|
+
label: G("moreActionsFor", { name: e.name })
|
|
301
301
|
}),
|
|
302
302
|
children: [
|
|
303
303
|
e.triageEnabled && /* @__PURE__ */ N(R, {
|
|
304
|
-
label:
|
|
305
|
-
icon: /* @__PURE__ */ N(
|
|
304
|
+
label: W("triage"),
|
|
305
|
+
icon: /* @__PURE__ */ N(de, { className: "size-4" }),
|
|
306
306
|
href: t("triage"),
|
|
307
307
|
selected: Y("triage", e.key),
|
|
308
308
|
onContextMenu: a(t("triage")),
|
|
309
309
|
badge: /* @__PURE__ */ N(T, {
|
|
310
310
|
count: Nt(e.id),
|
|
311
|
-
locale:
|
|
312
|
-
label:
|
|
311
|
+
locale: K,
|
|
312
|
+
label: W("triageCount")
|
|
313
313
|
})
|
|
314
314
|
}),
|
|
315
315
|
/* @__PURE__ */ N(R, {
|
|
316
|
-
label:
|
|
317
|
-
icon: /* @__PURE__ */ N(
|
|
316
|
+
label: W("issues"),
|
|
317
|
+
icon: /* @__PURE__ */ N(ce, { className: "size-4" }),
|
|
318
318
|
href: t("issues"),
|
|
319
319
|
selected: Et.team === e.key,
|
|
320
320
|
onContextMenu: a(t("issues"))
|
|
321
321
|
}),
|
|
322
322
|
/* @__PURE__ */ N(R, {
|
|
323
|
-
label:
|
|
324
|
-
icon: /* @__PURE__ */ N(
|
|
323
|
+
label: W("projects"),
|
|
324
|
+
icon: /* @__PURE__ */ N(ue, { className: "size-4" }),
|
|
325
325
|
href: t("projects"),
|
|
326
326
|
selected: Y("projects", e.key),
|
|
327
327
|
onContextMenu: a(t("projects"))
|
|
328
328
|
}),
|
|
329
329
|
/* @__PURE__ */ N(R, {
|
|
330
|
-
label:
|
|
331
|
-
icon: /* @__PURE__ */ N(
|
|
330
|
+
label: W("areas"),
|
|
331
|
+
icon: /* @__PURE__ */ N(re, { className: "size-4" }),
|
|
332
332
|
href: t("areas"),
|
|
333
333
|
selected: Y("areas", e.key),
|
|
334
334
|
onContextMenu: a(t("areas"))
|
|
335
335
|
}),
|
|
336
336
|
/* @__PURE__ */ N(R, {
|
|
337
|
-
label:
|
|
338
|
-
icon: /* @__PURE__ */ N(
|
|
337
|
+
label: W("decisions"),
|
|
338
|
+
icon: /* @__PURE__ */ N(oe, { className: "size-4" }),
|
|
339
339
|
href: t("decisions"),
|
|
340
340
|
selected: Y("decisions", e.key),
|
|
341
341
|
onContextMenu: a(t("decisions")),
|
|
342
342
|
badge: /* @__PURE__ */ N(T, {
|
|
343
343
|
count: r,
|
|
344
|
-
locale:
|
|
345
|
-
label:
|
|
344
|
+
locale: K,
|
|
345
|
+
label: W("waitingCount"),
|
|
346
346
|
className: "bg-agent! text-agent-foreground!"
|
|
347
347
|
})
|
|
348
348
|
}),
|
|
349
|
-
!n && /* @__PURE__ */ N(
|
|
350
|
-
workspace:
|
|
349
|
+
!n && /* @__PURE__ */ N(l, {
|
|
350
|
+
workspace: d,
|
|
351
351
|
team: e,
|
|
352
|
-
current:
|
|
352
|
+
current: it(J.pathname, d)
|
|
353
353
|
}),
|
|
354
354
|
e.cyclesEnabled && /* @__PURE__ */ N(R, {
|
|
355
|
-
label:
|
|
356
|
-
icon: /* @__PURE__ */ N(
|
|
355
|
+
label: W("cycles"),
|
|
356
|
+
icon: /* @__PURE__ */ N(ae, { className: "size-4" }),
|
|
357
357
|
href: t("cycles"),
|
|
358
358
|
selected: Y("cycles", e.key)
|
|
359
359
|
}),
|
|
360
|
-
|
|
360
|
+
u(e.id).map(f)
|
|
361
361
|
]
|
|
362
362
|
}, e.id);
|
|
363
|
-
},
|
|
363
|
+
}, m = u("").map(f), h = `/${d}/issues?assignee=${encodeURIComponent(g.user.username)}`;
|
|
364
364
|
return /* @__PURE__ */ P(M, { children: [
|
|
365
|
-
t && /* @__PURE__ */ N(
|
|
365
|
+
t && /* @__PURE__ */ N(ot, {}),
|
|
366
366
|
/* @__PURE__ */ N(R, {
|
|
367
|
-
label:
|
|
368
|
-
icon: o(/* @__PURE__ */ N(
|
|
369
|
-
href: `/${
|
|
370
|
-
selected: r(`/${
|
|
371
|
-
onContextMenu: a(`/${
|
|
367
|
+
label: W("notifications"),
|
|
368
|
+
icon: o(/* @__PURE__ */ N(le, { className: "size-4" }), Ft > 0),
|
|
369
|
+
href: `/${d}/notifications`,
|
|
370
|
+
selected: r(`/${d}/notifications`),
|
|
371
|
+
onContextMenu: a(`/${d}/notifications`),
|
|
372
372
|
badge: /* @__PURE__ */ N(T, {
|
|
373
373
|
count: Ft,
|
|
374
|
-
locale:
|
|
375
|
-
label:
|
|
374
|
+
locale: K,
|
|
375
|
+
label: W("unreadCount")
|
|
376
376
|
})
|
|
377
377
|
}),
|
|
378
378
|
/* @__PURE__ */ N(R, {
|
|
379
|
-
label:
|
|
380
|
-
icon: /* @__PURE__ */ N(
|
|
381
|
-
href:
|
|
379
|
+
label: W("myIssues"),
|
|
380
|
+
icon: /* @__PURE__ */ N(fe, { className: "size-4" }),
|
|
381
|
+
href: h,
|
|
382
382
|
selected: Et.mine,
|
|
383
|
-
onContextMenu: i("my-issues",
|
|
383
|
+
onContextMenu: i("my-issues", h)
|
|
384
384
|
}),
|
|
385
385
|
/* @__PURE__ */ N(R, {
|
|
386
|
-
label:
|
|
387
|
-
icon: /* @__PURE__ */ N(
|
|
388
|
-
href: `/${
|
|
389
|
-
selected: r(`/${
|
|
390
|
-
onContextMenu: i("projects", `/${
|
|
386
|
+
label: W("projects"),
|
|
387
|
+
icon: /* @__PURE__ */ N(ue, { className: "size-4" }),
|
|
388
|
+
href: `/${d}/projects`,
|
|
389
|
+
selected: r(`/${d}/projects`),
|
|
390
|
+
onContextMenu: i("projects", `/${d}/projects`)
|
|
391
391
|
}),
|
|
392
392
|
/* @__PURE__ */ N(R, {
|
|
393
|
-
label:
|
|
394
|
-
icon: /* @__PURE__ */ N(
|
|
395
|
-
href: `/${
|
|
396
|
-
selected: r(`/${
|
|
393
|
+
label: W("dashboards"),
|
|
394
|
+
icon: /* @__PURE__ */ N(ie, { className: "size-4" }),
|
|
395
|
+
href: `/${d}/dashboards`,
|
|
396
|
+
selected: r(`/${d}/dashboards`)
|
|
397
397
|
}),
|
|
398
398
|
/* @__PURE__ */ N(R, {
|
|
399
|
-
label:
|
|
400
|
-
icon: /* @__PURE__ */ N(
|
|
401
|
-
href: `/${
|
|
402
|
-
selected: r(`/${
|
|
403
|
-
onContextMenu: i("knowledge", `/${
|
|
399
|
+
label: W("knowledge"),
|
|
400
|
+
icon: /* @__PURE__ */ N(se, { className: "size-4" }),
|
|
401
|
+
href: `/${d}/knowledge`,
|
|
402
|
+
selected: r(`/${d}/knowledge`),
|
|
403
|
+
onContextMenu: i("knowledge", `/${d}/knowledge`)
|
|
404
404
|
}),
|
|
405
405
|
/* @__PURE__ */ N(R, {
|
|
406
|
-
label:
|
|
407
|
-
icon: /* @__PURE__ */ N(
|
|
408
|
-
href: `/${
|
|
409
|
-
selected: r(`/${
|
|
410
|
-
onContextMenu: i("agents", `/${
|
|
406
|
+
label: W("agents"),
|
|
407
|
+
icon: /* @__PURE__ */ N(ne, { className: "size-4" }),
|
|
408
|
+
href: `/${d}/agents`,
|
|
409
|
+
selected: r(`/${d}/agents`),
|
|
410
|
+
onContextMenu: i("agents", `/${d}/agents`)
|
|
411
411
|
}),
|
|
412
412
|
n ? /* @__PURE__ */ N("div", {
|
|
413
413
|
className: "mt-4 border-t border-border pt-4",
|
|
414
|
-
children:
|
|
414
|
+
children: m
|
|
415
415
|
}) : /* @__PURE__ */ P(M, { children: [
|
|
416
|
-
/* @__PURE__ */ N(
|
|
417
|
-
workspace:
|
|
416
|
+
/* @__PURE__ */ N(dt, {
|
|
417
|
+
workspace: d,
|
|
418
418
|
current: Et.saved
|
|
419
419
|
}),
|
|
420
|
-
/* @__PURE__ */ N(
|
|
421
|
-
workspace:
|
|
422
|
-
myUsername:
|
|
420
|
+
/* @__PURE__ */ N(te, {
|
|
421
|
+
workspace: d,
|
|
422
|
+
myUsername: g.user.username,
|
|
423
423
|
currentHref: J.pathname + J.searchStr
|
|
424
424
|
}),
|
|
425
425
|
/* @__PURE__ */ P(L, {
|
|
426
|
-
label:
|
|
426
|
+
label: W("teams"),
|
|
427
427
|
collapsible: !1,
|
|
428
428
|
action: w && /* @__PURE__ */ N(E, {
|
|
429
429
|
variant: "ghost",
|
|
430
430
|
size: "xs",
|
|
431
|
-
icon: /* @__PURE__ */ N(
|
|
432
|
-
label:
|
|
433
|
-
onClick: () =>
|
|
431
|
+
icon: /* @__PURE__ */ N(p, {}),
|
|
432
|
+
label: W("createTeam"),
|
|
433
|
+
onClick: () => C(!0)
|
|
434
434
|
}),
|
|
435
|
-
children: [
|
|
436
|
-
label:
|
|
437
|
-
icon: /* @__PURE__ */ N(
|
|
438
|
-
onClick: () =>
|
|
435
|
+
children: [m, v.length === 0 && (w ? /* @__PURE__ */ N(R, {
|
|
436
|
+
label: W("createFirstTeam"),
|
|
437
|
+
icon: /* @__PURE__ */ N(p, { className: "size-4" }),
|
|
438
|
+
onClick: () => C(!0)
|
|
439
439
|
}) : /* @__PURE__ */ N("p", {
|
|
440
440
|
className: "px-2 text-sm text-muted-foreground",
|
|
441
|
-
children:
|
|
441
|
+
children: W("noTeams")
|
|
442
442
|
}))]
|
|
443
443
|
})
|
|
444
444
|
] })
|
|
@@ -446,40 +446,40 @@ function U() {
|
|
|
446
446
|
}, Jt = X ? void 0 : ({ expanded: e, isMobile: t }) => {
|
|
447
447
|
let n = [
|
|
448
448
|
{
|
|
449
|
-
label:
|
|
450
|
-
onClick: () =>
|
|
449
|
+
label: W("myAccount"),
|
|
450
|
+
onClick: () => z({
|
|
451
451
|
to: "/$workspace/settings/account",
|
|
452
|
-
params: { workspace:
|
|
452
|
+
params: { workspace: d }
|
|
453
453
|
})
|
|
454
454
|
},
|
|
455
455
|
{
|
|
456
|
-
label:
|
|
457
|
-
onClick: () =>
|
|
456
|
+
label: W("settings"),
|
|
457
|
+
onClick: () => z({
|
|
458
458
|
to: "/$workspace/settings",
|
|
459
|
-
params: { workspace:
|
|
459
|
+
params: { workspace: d }
|
|
460
460
|
})
|
|
461
461
|
},
|
|
462
462
|
...Ut ? [{
|
|
463
|
-
label:
|
|
463
|
+
label: W("installApp"),
|
|
464
464
|
onClick: Ve
|
|
465
465
|
}] : [],
|
|
466
466
|
...Wt ? [O, {
|
|
467
|
-
label:
|
|
467
|
+
label: W("signOut"),
|
|
468
468
|
onClick: Gt
|
|
469
469
|
}] : []
|
|
470
470
|
], r = /* @__PURE__ */ N(Be, {
|
|
471
|
-
name:
|
|
472
|
-
src:
|
|
471
|
+
name: g.user.name,
|
|
472
|
+
src: g.user.avatarUrl,
|
|
473
473
|
size: "sm",
|
|
474
474
|
decorative: !0
|
|
475
475
|
});
|
|
476
|
-
return e ? /* @__PURE__ */ P(M, { children: [/* @__PURE__ */ N(
|
|
477
|
-
myUsername:
|
|
478
|
-
workspace:
|
|
476
|
+
return e ? /* @__PURE__ */ P(M, { children: [/* @__PURE__ */ N(ut, {
|
|
477
|
+
myUsername: g.user.username,
|
|
478
|
+
workspace: d
|
|
479
479
|
}), /* @__PURE__ */ P("div", {
|
|
480
480
|
className: "flex items-center gap-1",
|
|
481
481
|
children: [/* @__PURE__ */ N(ze, {
|
|
482
|
-
label:
|
|
482
|
+
label: W("accountMenu", { name: g.user.name }),
|
|
483
483
|
side: "top",
|
|
484
484
|
align: "start",
|
|
485
485
|
matchTriggerWidth: !0,
|
|
@@ -489,14 +489,14 @@ function U() {
|
|
|
489
489
|
className: "flex h-9 min-w-0 flex-1 items-center gap-2 rounded-md px-1.5 text-left hover:bg-muted",
|
|
490
490
|
children: [r, /* @__PURE__ */ N("span", {
|
|
491
491
|
className: "min-w-0 flex-1 truncate text-sm",
|
|
492
|
-
children:
|
|
492
|
+
children: g.user.name
|
|
493
493
|
})]
|
|
494
494
|
})
|
|
495
|
-
}), !t && /* @__PURE__ */ N(
|
|
495
|
+
}), !t && /* @__PURE__ */ N(nt, {})]
|
|
496
496
|
})] }) : /* @__PURE__ */ P("div", {
|
|
497
497
|
className: "flex flex-col items-center gap-2",
|
|
498
|
-
children: [/* @__PURE__ */ N(
|
|
499
|
-
label:
|
|
498
|
+
children: [/* @__PURE__ */ N(nt, {}), /* @__PURE__ */ N(ze, {
|
|
499
|
+
label: W("accountMenu", { name: g.user.name }),
|
|
500
500
|
side: "right",
|
|
501
501
|
align: "end",
|
|
502
502
|
items: n,
|
|
@@ -505,33 +505,33 @@ function U() {
|
|
|
505
505
|
children: r
|
|
506
506
|
})]
|
|
507
507
|
});
|
|
508
|
-
}, Yt = /* @__PURE__ */ N(
|
|
509
|
-
workspace:
|
|
510
|
-
name:
|
|
511
|
-
apps:
|
|
508
|
+
}, Yt = /* @__PURE__ */ N(st, {
|
|
509
|
+
workspace: d,
|
|
510
|
+
name: _.name,
|
|
511
|
+
apps: g.apps ?? [],
|
|
512
512
|
unread: Ft,
|
|
513
513
|
onSearch: () => Q(!0),
|
|
514
514
|
onNewIssue: () => Z()
|
|
515
515
|
});
|
|
516
|
-
return /* @__PURE__ */ N(
|
|
517
|
-
workspace:
|
|
518
|
-
children: /* @__PURE__ */ N(
|
|
519
|
-
actions:
|
|
520
|
-
children: /* @__PURE__ */ N(
|
|
516
|
+
return /* @__PURE__ */ N(we, {
|
|
517
|
+
workspace: d,
|
|
518
|
+
children: /* @__PURE__ */ N(xe, {
|
|
519
|
+
actions: g.actions ?? [],
|
|
520
|
+
children: /* @__PURE__ */ N(De.Provider, {
|
|
521
521
|
value: Z,
|
|
522
|
-
children: /* @__PURE__ */ P(
|
|
522
|
+
children: /* @__PURE__ */ P(ke.Provider, {
|
|
523
523
|
value: Vt,
|
|
524
524
|
children: [
|
|
525
|
-
|
|
526
|
-
sidebar:
|
|
525
|
+
y ? /* @__PURE__ */ N(Ge, { children: /* @__PURE__ */ N(ct, {
|
|
526
|
+
sidebar: y.sidebar,
|
|
527
527
|
brand: Kt,
|
|
528
528
|
navigation: qt,
|
|
529
529
|
header: Yt,
|
|
530
|
-
presence: /* @__PURE__ */ N(
|
|
531
|
-
myUsername:
|
|
532
|
-
workspace:
|
|
530
|
+
presence: /* @__PURE__ */ N(ut, {
|
|
531
|
+
myUsername: g.user.username,
|
|
532
|
+
workspace: d
|
|
533
533
|
}),
|
|
534
|
-
children: /* @__PURE__ */ N(
|
|
534
|
+
children: /* @__PURE__ */ N(lt, { children: /* @__PURE__ */ P("div", {
|
|
535
535
|
className: "flex h-full min-h-0 flex-col",
|
|
536
536
|
children: [/* @__PURE__ */ N(We, {}), /* @__PURE__ */ N("div", {
|
|
537
537
|
className: "min-h-0 flex-1",
|
|
@@ -541,14 +541,14 @@ function U() {
|
|
|
541
541
|
}) }) : /* @__PURE__ */ N(tt, {
|
|
542
542
|
expanded: St || X,
|
|
543
543
|
onExpandedChange: (e) => {
|
|
544
|
-
Ct(e),
|
|
544
|
+
Ct(e), mt({
|
|
545
545
|
expanded: e,
|
|
546
546
|
width: wt
|
|
547
547
|
});
|
|
548
548
|
},
|
|
549
549
|
width: wt,
|
|
550
550
|
onWidthChange: (e) => {
|
|
551
|
-
Tt(e),
|
|
551
|
+
Tt(e), mt({
|
|
552
552
|
expanded: St,
|
|
553
553
|
width: e
|
|
554
554
|
});
|
|
@@ -557,47 +557,47 @@ function U() {
|
|
|
557
557
|
navigationResetKey: X ? "settings" : "workspace",
|
|
558
558
|
mainClassName: "flex flex-col overflow-hidden",
|
|
559
559
|
labels: {
|
|
560
|
-
navigation:
|
|
561
|
-
skipToContent:
|
|
562
|
-
openNavigation:
|
|
563
|
-
closeNavigation:
|
|
564
|
-
expandSidebar:
|
|
565
|
-
collapseSidebar:
|
|
566
|
-
resizeSidebar:
|
|
560
|
+
navigation: W("navigation"),
|
|
561
|
+
skipToContent: W("skipToContent"),
|
|
562
|
+
openNavigation: W("openNav"),
|
|
563
|
+
closeNavigation: W("closeNav"),
|
|
564
|
+
expandSidebar: W("expandSidebar"),
|
|
565
|
+
collapseSidebar: W("collapseSidebar"),
|
|
566
|
+
resizeSidebar: W("resizeSidebar")
|
|
567
567
|
},
|
|
568
568
|
header: Yt,
|
|
569
569
|
brand: Kt,
|
|
570
570
|
navigation: qt,
|
|
571
571
|
footer: Jt,
|
|
572
|
-
children: /* @__PURE__ */ N(
|
|
572
|
+
children: /* @__PURE__ */ N(lt, { children: /* @__PURE__ */ N(qe, {}) })
|
|
573
573
|
}),
|
|
574
|
-
/* @__PURE__ */ N(
|
|
575
|
-
!Ht && /* @__PURE__ */ N(
|
|
576
|
-
/* @__PURE__ */ N(
|
|
577
|
-
workspace:
|
|
574
|
+
/* @__PURE__ */ N(f, { workspace: d }),
|
|
575
|
+
!Ht && /* @__PURE__ */ N(_t, {}),
|
|
576
|
+
/* @__PURE__ */ N(c, {
|
|
577
|
+
workspace: d,
|
|
578
578
|
open: zt,
|
|
579
579
|
onClose: () => Q(!1),
|
|
580
580
|
selection: Bt
|
|
581
581
|
}),
|
|
582
|
-
/* @__PURE__ */ N(
|
|
583
|
-
/* @__PURE__ */ N(
|
|
582
|
+
/* @__PURE__ */ N(ge, { workspace: d }),
|
|
583
|
+
/* @__PURE__ */ N(_e, {
|
|
584
584
|
open: Lt,
|
|
585
585
|
onClose: () => Rt(!1)
|
|
586
586
|
}),
|
|
587
|
-
|
|
588
|
-
workspace:
|
|
589
|
-
onClose: () =>
|
|
587
|
+
Ae && /* @__PURE__ */ N(ve, {
|
|
588
|
+
workspace: d,
|
|
589
|
+
onClose: () => C(!1)
|
|
590
590
|
}),
|
|
591
|
-
|
|
592
|
-
workspace:
|
|
593
|
-
...
|
|
594
|
-
...
|
|
595
|
-
...
|
|
596
|
-
...
|
|
597
|
-
...
|
|
598
|
-
...
|
|
599
|
-
...
|
|
600
|
-
onClose: () =>
|
|
591
|
+
b && /* @__PURE__ */ N(Ye, { children: /* @__PURE__ */ N(me, {
|
|
592
|
+
workspace: d,
|
|
593
|
+
...b.team && { defaultTeam: b.team },
|
|
594
|
+
...b.title && { defaultTitle: b.title },
|
|
595
|
+
...b.body && { defaultBody: b.body },
|
|
596
|
+
...b.area && { defaultArea: b.area },
|
|
597
|
+
...b.origin && { origin: b.origin },
|
|
598
|
+
...b.fields && { defaults: b.fields },
|
|
599
|
+
...b.onCreated && { onCreated: b.onCreated },
|
|
600
|
+
onClose: () => x(null)
|
|
601
601
|
}) })
|
|
602
602
|
]
|
|
603
603
|
})
|
|
@@ -605,51 +605,51 @@ function U() {
|
|
|
605
605
|
})
|
|
606
606
|
});
|
|
607
607
|
}
|
|
608
|
-
function
|
|
608
|
+
function ot() {
|
|
609
609
|
return k(() => {
|
|
610
610
|
document.querySelector(".pw-frame-drawer [aria-current=\"page\"]")?.scrollIntoView({ block: "nearest" });
|
|
611
611
|
}, []), null;
|
|
612
612
|
}
|
|
613
|
-
function
|
|
614
|
-
let { isMobile:
|
|
615
|
-
return
|
|
613
|
+
function st({ workspace: e, name: t, apps: n, unread: r, onSearch: i, onNewIssue: a }) {
|
|
614
|
+
let { isMobile: o } = z(), c = be(), l = j("workspace");
|
|
615
|
+
return o ? /* @__PURE__ */ P("div", {
|
|
616
616
|
className: "flex h-12 items-center gap-1 border-b border-border px-1",
|
|
617
617
|
children: [
|
|
618
|
-
/* @__PURE__ */ N(
|
|
618
|
+
/* @__PURE__ */ N(nt, {}),
|
|
619
619
|
/* @__PURE__ */ N("span", {
|
|
620
620
|
className: "min-w-0 flex-1 truncate text-sm font-semibold",
|
|
621
|
-
children:
|
|
621
|
+
children: t
|
|
622
622
|
}),
|
|
623
|
-
!c && /* @__PURE__ */ N(
|
|
624
|
-
!c && /* @__PURE__ */ N(
|
|
623
|
+
!c && /* @__PURE__ */ N(u, {}),
|
|
624
|
+
!c && /* @__PURE__ */ N(s, { apps: n }),
|
|
625
625
|
/* @__PURE__ */ N(E, {
|
|
626
626
|
variant: "ghost",
|
|
627
627
|
size: "lg",
|
|
628
628
|
icon: /* @__PURE__ */ N(h, {}),
|
|
629
629
|
label: l("openPalette"),
|
|
630
|
-
onClick:
|
|
630
|
+
onClick: i
|
|
631
631
|
}),
|
|
632
632
|
/* @__PURE__ */ N(E, {
|
|
633
633
|
variant: "ghost",
|
|
634
634
|
size: "lg",
|
|
635
|
-
icon: /* @__PURE__ */ N(
|
|
635
|
+
icon: /* @__PURE__ */ N(le, {}),
|
|
636
636
|
label: l("notifications"),
|
|
637
637
|
href: `/${e}/notifications`,
|
|
638
|
-
dot:
|
|
638
|
+
dot: r > 0
|
|
639
639
|
}),
|
|
640
640
|
/* @__PURE__ */ N(E, {
|
|
641
641
|
variant: "ghost",
|
|
642
642
|
size: "lg",
|
|
643
|
-
icon: /* @__PURE__ */ N(
|
|
643
|
+
icon: /* @__PURE__ */ N(p, {}),
|
|
644
644
|
label: l("newIssue"),
|
|
645
|
-
onClick:
|
|
645
|
+
onClick: a
|
|
646
646
|
})
|
|
647
647
|
]
|
|
648
648
|
}) : null;
|
|
649
649
|
}
|
|
650
|
-
function
|
|
651
|
-
let o =
|
|
652
|
-
return /* @__PURE__ */ P(M, { children: [e &&
|
|
650
|
+
function ct({ sidebar: e, brand: t, navigation: n, header: r, presence: i, children: a }) {
|
|
651
|
+
let o = z();
|
|
652
|
+
return /* @__PURE__ */ P(M, { children: [e && rt(/* @__PURE__ */ P("div", {
|
|
653
653
|
className: "tandem-hosted-sidebar flex flex-col gap-3",
|
|
654
654
|
children: [
|
|
655
655
|
t?.(o),
|
|
@@ -661,15 +661,15 @@ function st({ sidebar: e, brand: t, navigation: n, header: r, presence: i, child
|
|
|
661
661
|
children: [r, a]
|
|
662
662
|
})] });
|
|
663
663
|
}
|
|
664
|
-
function
|
|
665
|
-
let { state: t } =
|
|
664
|
+
function lt({ children: e }) {
|
|
665
|
+
let { state: t } = y(), n = t?.open && t.maximized;
|
|
666
666
|
return /* @__PURE__ */ P(M, { children: [/* @__PURE__ */ N("div", {
|
|
667
|
-
className:
|
|
667
|
+
className: V("min-h-0 min-w-0 flex-1 overflow-y-auto bg-card", n && "hidden"),
|
|
668
668
|
children: e
|
|
669
|
-
}), /* @__PURE__ */ N(
|
|
669
|
+
}), /* @__PURE__ */ N(d, {})] });
|
|
670
670
|
}
|
|
671
|
-
function
|
|
672
|
-
let { people: n, page: r } =
|
|
671
|
+
function ut({ myUsername: e, workspace: t }) {
|
|
672
|
+
let { people: n, page: r } = b(), { person: i } = x(t), a = j("workspace"), o = new Set(n.map((e) => e.username).filter((t) => t !== e));
|
|
673
673
|
if (o.size === 0) return null;
|
|
674
674
|
let s = [...new Set(n.filter((t) => t.username !== e && t.page === r).map((e) => e.username))];
|
|
675
675
|
return /* @__PURE__ */ P("div", {
|
|
@@ -680,7 +680,7 @@ function lt({ myUsername: e, workspace: t }) {
|
|
|
680
680
|
showOverflow: !1,
|
|
681
681
|
ringColor: "var(--theme-sidebar-bg, var(--theme-muted-panel-bg))",
|
|
682
682
|
label: a("onThisPage", { count: s.length }),
|
|
683
|
-
children: s.map((e) => /* @__PURE__ */ N(
|
|
683
|
+
children: s.map((e) => /* @__PURE__ */ N(_, {
|
|
684
684
|
workspace: t,
|
|
685
685
|
handle: e,
|
|
686
686
|
children: /* @__PURE__ */ N(Be, {
|
|
@@ -697,16 +697,16 @@ function lt({ myUsername: e, workspace: t }) {
|
|
|
697
697
|
}) : a("online", { count: o.size }) })]
|
|
698
698
|
});
|
|
699
699
|
}
|
|
700
|
-
function
|
|
701
|
-
let n = j("savedViews"), r = j("common"), i = Ke(), { views: a } =
|
|
700
|
+
function dt({ workspace: e, current: t }) {
|
|
701
|
+
let n = j("savedViews"), r = j("common"), i = Ke(), { views: a } = C(e), { menu: o, dialogs: s } = w(e);
|
|
702
702
|
return a.length === 0 ? s : /* @__PURE__ */ P(M, { children: [/* @__PURE__ */ N(L, {
|
|
703
703
|
label: n("title"),
|
|
704
704
|
collapsible: !1,
|
|
705
705
|
children: a.map((a) => /* @__PURE__ */ N(R, {
|
|
706
706
|
label: a.name,
|
|
707
|
-
icon: a.shared ? /* @__PURE__ */ N(g, { className: "size-4" }) : /* @__PURE__ */ N(
|
|
708
|
-
href:
|
|
709
|
-
selected:
|
|
707
|
+
icon: a.shared ? /* @__PURE__ */ N(g, { className: "size-4" }) : /* @__PURE__ */ N(ce, { className: "size-4" }),
|
|
708
|
+
href: Le(e, a),
|
|
709
|
+
selected: Ae(a, t),
|
|
710
710
|
title: a.shared ? n("sharedBy", { owner: a.owner }) : n("onlyYou"),
|
|
711
711
|
onContextMenu: (e) => i(e, o(a)),
|
|
712
712
|
action: /* @__PURE__ */ N(et, {
|
|
@@ -716,19 +716,19 @@ function ut({ workspace: e, current: t }) {
|
|
|
716
716
|
}, a.id))
|
|
717
717
|
}), s] });
|
|
718
718
|
}
|
|
719
|
-
var
|
|
720
|
-
function
|
|
719
|
+
var U = (e) => `tandem:collapsed-teams:${e}`;
|
|
720
|
+
function ft(e) {
|
|
721
721
|
try {
|
|
722
|
-
let t = JSON.parse(localStorage.getItem(
|
|
722
|
+
let t = JSON.parse(localStorage.getItem(U(e)) ?? "[]");
|
|
723
723
|
return new Set(Array.isArray(t) ? t.filter((e) => typeof e == "string") : []);
|
|
724
724
|
} catch {
|
|
725
725
|
return /* @__PURE__ */ new Set();
|
|
726
726
|
}
|
|
727
727
|
}
|
|
728
|
-
var
|
|
729
|
-
function
|
|
728
|
+
var W = "tandem:sidebar";
|
|
729
|
+
function pt() {
|
|
730
730
|
try {
|
|
731
|
-
let e = JSON.parse(localStorage.getItem(
|
|
731
|
+
let e = JSON.parse(localStorage.getItem(W) ?? "{}");
|
|
732
732
|
return {
|
|
733
733
|
expanded: e?.expanded !== !1,
|
|
734
734
|
width: typeof e?.width == "number" ? e.width : 240
|
|
@@ -740,20 +740,20 @@ function ft() {
|
|
|
740
740
|
};
|
|
741
741
|
}
|
|
742
742
|
}
|
|
743
|
-
function
|
|
743
|
+
function mt(e) {
|
|
744
744
|
try {
|
|
745
|
-
localStorage.setItem(
|
|
745
|
+
localStorage.setItem(W, JSON.stringify(e));
|
|
746
746
|
} catch {}
|
|
747
747
|
}
|
|
748
|
-
function
|
|
748
|
+
function ht(e, t) {
|
|
749
749
|
try {
|
|
750
|
-
localStorage.setItem(
|
|
750
|
+
localStorage.setItem(U(e), JSON.stringify([...t]));
|
|
751
751
|
} catch {}
|
|
752
752
|
}
|
|
753
|
-
function
|
|
753
|
+
function gt() {
|
|
754
754
|
return Array.from(document.querySelectorAll("[aria-keyshortcuts]")).some((e) => /\b(Meta|Control)\+F\b/.test(e.getAttribute("aria-keyshortcuts") ?? "") && e.getClientRects().length > 0);
|
|
755
755
|
}
|
|
756
|
-
function
|
|
756
|
+
function _t() {
|
|
757
757
|
return k(() => {
|
|
758
758
|
let t = Intl.DateTimeFormat().resolvedOptions().timeZone;
|
|
759
759
|
try {
|
|
@@ -763,4 +763,4 @@ function gt() {
|
|
|
763
763
|
e.PATCH("/api/v1/me", { body: { timeZone: t } }).catch(() => {});
|
|
764
764
|
}, []), null;
|
|
765
765
|
}
|
|
766
|
-
export {
|
|
766
|
+
export { H as component };
|