@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
|
@@ -1,50 +1,50 @@
|
|
|
1
1
|
import { api as e, unwrap as t } from "../../../api/client.js";
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
2
|
+
import { notificationSettingsQuery as n, pushSettingsQuery as r } from "../../../api/queries.js";
|
|
3
|
+
import { ChevronRightIcon as i } from "../../../components/icons.js";
|
|
4
|
+
import { SettingsPage as a, useFormError as o } from "../../../components/settings.js";
|
|
5
|
+
import { usePush as s } from "../../../lib/notifications.js";
|
|
6
|
+
import { Link as c, useNavigate as l } from "../../../lib/router.js";
|
|
7
|
+
import { Route as u } from "./notifications.js";
|
|
8
8
|
import { SettingRow as d, SettingsCard as f, Switch as p } from "@parallelworks/ui";
|
|
9
9
|
import { useTranslations as m } from "use-intl";
|
|
10
10
|
import { Fragment as h, jsx as g, jsxs as _ } from "react/jsx-runtime";
|
|
11
11
|
import { useMutation as v, useQuery as y, useQueryClient as b, useSuspenseQuery as x } from "@tanstack/react-query";
|
|
12
12
|
// src/routes/$workspace/settings/notifications.tsx?tsr-split=component
|
|
13
13
|
function S() {
|
|
14
|
-
let { channel: e } =
|
|
15
|
-
return e && (e !== "push" || t?.enabled) &&
|
|
14
|
+
let { channel: e } = u.useSearch(), { data: t } = y(r), { data: i } = x(n);
|
|
15
|
+
return e && (e !== "push" || t?.enabled) && i.channels.some((t) => t.channel === e) ? /* @__PURE__ */ g(w, { channel: e }) : /* @__PURE__ */ g(C, {});
|
|
16
16
|
}
|
|
17
17
|
function C() {
|
|
18
|
-
let { workspace: e } =
|
|
19
|
-
return /* @__PURE__ */ g(
|
|
20
|
-
title:
|
|
18
|
+
let { workspace: e } = u.useParams(), t = m("notificationSettings"), o = m("settingsNav"), p = l(), { data: v } = x(n), { data: b } = y(r), S = s(), C = v.channels.filter((e) => e.channel !== "push" || b?.enabled);
|
|
19
|
+
return /* @__PURE__ */ g(a, {
|
|
20
|
+
title: o("notifications"),
|
|
21
21
|
description: t("description"),
|
|
22
|
-
children: /* @__PURE__ */ _(f, { children: [C.map((
|
|
23
|
-
let
|
|
24
|
-
return !
|
|
25
|
-
on:
|
|
26
|
-
total:
|
|
22
|
+
children: /* @__PURE__ */ _(f, { children: [C.map((n) => {
|
|
23
|
+
let r = n.events.filter((e) => e.enabled).length, a = t("allOn");
|
|
24
|
+
return !n.enabled || r === 0 ? a = t("off") : r < n.events.length && (a = t("someOn", {
|
|
25
|
+
on: r,
|
|
26
|
+
total: n.events.length
|
|
27
27
|
})), /* @__PURE__ */ g(d, {
|
|
28
|
-
label: t(`channel.${
|
|
28
|
+
label: t(`channel.${n.channel}`),
|
|
29
29
|
onClick: () => p({
|
|
30
30
|
to: "/$workspace/settings/notifications",
|
|
31
31
|
params: { workspace: e },
|
|
32
|
-
search: { channel:
|
|
32
|
+
search: { channel: n.channel }
|
|
33
33
|
}),
|
|
34
|
-
helpText: /* @__PURE__ */ _(h, { children: [a,
|
|
34
|
+
helpText: /* @__PURE__ */ _(h, { children: [a, n.channel === "push" && n.enabled && S.state !== "on" && /* @__PURE__ */ g("span", {
|
|
35
35
|
className: "block",
|
|
36
36
|
children: t("notInThisBrowser")
|
|
37
37
|
})] }),
|
|
38
|
-
children: /* @__PURE__ */ g(
|
|
38
|
+
children: /* @__PURE__ */ g(c, {
|
|
39
39
|
to: "/$workspace/settings/notifications",
|
|
40
40
|
params: { workspace: e },
|
|
41
|
-
search: { channel:
|
|
42
|
-
"aria-label": t("open", { channel: t(`channel.${
|
|
41
|
+
search: { channel: n.channel },
|
|
42
|
+
"aria-label": t("open", { channel: t(`channel.${n.channel}`) }),
|
|
43
43
|
onClick: (e) => e.stopPropagation(),
|
|
44
44
|
className: "flex size-8 items-center justify-center rounded-md text-muted-foreground hover:bg-muted hover:text-foreground",
|
|
45
|
-
children: /* @__PURE__ */ g(
|
|
45
|
+
children: /* @__PURE__ */ g(i, { className: "size-4" })
|
|
46
46
|
})
|
|
47
|
-
},
|
|
47
|
+
}, n.channel);
|
|
48
48
|
}), b && !b.enabled && /* @__PURE__ */ g(d, {
|
|
49
49
|
label: t("channel.push"),
|
|
50
50
|
helpText: t("pushNotSetUp"),
|
|
@@ -55,39 +55,39 @@ function C() {
|
|
|
55
55
|
function w({ channel: e }) {
|
|
56
56
|
return /* @__PURE__ */ g(T, { channel: e });
|
|
57
57
|
}
|
|
58
|
-
function T({ channel:
|
|
59
|
-
let
|
|
60
|
-
mutationFn: async (
|
|
61
|
-
channel:
|
|
62
|
-
...
|
|
58
|
+
function T({ channel: r }) {
|
|
59
|
+
let i = m("notificationSettings"), s = b(), c = o(), { data: l } = x(n), u = l.channels.find((e) => e.channel === r), h = v({
|
|
60
|
+
mutationFn: async (n) => t(await e.PATCH("/api/v1/me/notification-settings", { body: {
|
|
61
|
+
channel: r,
|
|
62
|
+
...n
|
|
63
63
|
} })),
|
|
64
|
-
onMutate:
|
|
65
|
-
onSuccess: (e) =>
|
|
66
|
-
onError:
|
|
67
|
-
}), y =
|
|
68
|
-
return /* @__PURE__ */ _(
|
|
64
|
+
onMutate: c.clear,
|
|
65
|
+
onSuccess: (e) => s.setQueryData(n.queryKey, e),
|
|
66
|
+
onError: c.set
|
|
67
|
+
}), y = i(`channel.${r}`);
|
|
68
|
+
return /* @__PURE__ */ _(a, {
|
|
69
69
|
title: y,
|
|
70
|
-
description:
|
|
70
|
+
description: i(`channelDescription.${r}`),
|
|
71
71
|
children: [/* @__PURE__ */ _(f, { children: [/* @__PURE__ */ g(d, {
|
|
72
|
-
label:
|
|
73
|
-
helpText:
|
|
74
|
-
error: h.variables?.enabled === void 0 ? null :
|
|
72
|
+
label: i("enabled", { channel: y }),
|
|
73
|
+
helpText: i(`enabledHelp.${r}`),
|
|
74
|
+
error: h.variables?.enabled === void 0 ? null : c.error,
|
|
75
75
|
children: /* @__PURE__ */ g(p, {
|
|
76
|
-
"aria-label":
|
|
76
|
+
"aria-label": i("enabled", { channel: y }),
|
|
77
77
|
checked: u.enabled,
|
|
78
78
|
disabled: h.isPending,
|
|
79
79
|
onCheckedChange: (e) => h.mutate({ enabled: e })
|
|
80
80
|
})
|
|
81
|
-
}),
|
|
81
|
+
}), r === "push" && /* @__PURE__ */ g(E, {})] }), /* @__PURE__ */ g("div", {
|
|
82
82
|
className: "mt-12",
|
|
83
83
|
children: /* @__PURE__ */ g(f, {
|
|
84
|
-
title:
|
|
84
|
+
title: i("events"),
|
|
85
85
|
children: u.events.map((e) => /* @__PURE__ */ g(d, {
|
|
86
|
-
label:
|
|
87
|
-
helpText:
|
|
88
|
-
error: h.variables?.events?.[0]?.reason === e.reason ?
|
|
86
|
+
label: i(`event.${e.reason}`),
|
|
87
|
+
helpText: i(`eventHelp.${e.reason}`),
|
|
88
|
+
error: h.variables?.events?.[0]?.reason === e.reason ? c.error : null,
|
|
89
89
|
children: /* @__PURE__ */ g(p, {
|
|
90
|
-
"aria-label":
|
|
90
|
+
"aria-label": i(`event.${e.reason}`),
|
|
91
91
|
checked: u.enabled && e.enabled,
|
|
92
92
|
disabled: !u.enabled || h.isPending,
|
|
93
93
|
onCheckedChange: (t) => h.mutate({ events: [{
|
|
@@ -101,7 +101,7 @@ function T({ channel: n }) {
|
|
|
101
101
|
});
|
|
102
102
|
}
|
|
103
103
|
function E() {
|
|
104
|
-
let e = m("notificationSettings"), { state: t, pending: n, enable: r, disable: i } =
|
|
104
|
+
let e = m("notificationSettings"), { state: t, pending: n, enable: r, disable: i } = s(), a = {
|
|
105
105
|
unsupported: e("pushUnsupported"),
|
|
106
106
|
unavailable: e("pushUnsupported"),
|
|
107
107
|
denied: e("pushDenied"),
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { api as e, unwrap as t } from "../../../api/client.js";
|
|
2
2
|
import { meQuery as n, parallelWorksBucketsQuery as r, parallelWorksQuery as i } from "../../../api/queries.js";
|
|
3
3
|
import { BucketIcon as a } from "../../../components/icons.js";
|
|
4
|
-
import {
|
|
5
|
-
import { useConfirm as
|
|
6
|
-
import {
|
|
4
|
+
import { AdminOnly as o, SettingsPage as s, useFormError as c } from "../../../components/settings.js";
|
|
5
|
+
import { useConfirm as l } from "../../../lib/confirm.js";
|
|
6
|
+
import { useCan as u } from "../../../lib/roles.js";
|
|
7
7
|
import { Route as d } from "./parallelworks.js";
|
|
8
8
|
import { Button as f, Callout as p, Input as m, Select as h, SettingRow as g, SettingsCard as _ } from "@parallelworks/ui";
|
|
9
9
|
import { useState as v } from "react";
|
|
@@ -12,11 +12,11 @@ import { jsx as x, jsxs as S } from "react/jsx-runtime";
|
|
|
12
12
|
import { useMutation as C, useQuery as w, useQueryClient as T, useSuspenseQuery as E } from "@tanstack/react-query";
|
|
13
13
|
// src/routes/$workspace/settings/parallelworks.tsx?tsr-split=component
|
|
14
14
|
function D() {
|
|
15
|
-
let { workspace: e } = d.useParams(), t = b("parallelWorks"), n =
|
|
16
|
-
return /* @__PURE__ */ S(
|
|
15
|
+
let { workspace: e } = d.useParams(), t = b("parallelWorks"), n = u(e, "manage_workspace");
|
|
16
|
+
return /* @__PURE__ */ S(s, {
|
|
17
17
|
title: t("title"),
|
|
18
18
|
description: t("description"),
|
|
19
|
-
children: [/* @__PURE__ */ x(
|
|
19
|
+
children: [/* @__PURE__ */ x(o, { workspace: e }), n && /* @__PURE__ */ x(O, { workspace: e })]
|
|
20
20
|
});
|
|
21
21
|
}
|
|
22
22
|
function O({ workspace: e }) {
|
|
@@ -36,7 +36,7 @@ function O({ workspace: e }) {
|
|
|
36
36
|
});
|
|
37
37
|
}
|
|
38
38
|
function k({ workspace: r, conn: a }) {
|
|
39
|
-
let o = b("parallelWorks"), s = T(),
|
|
39
|
+
let o = b("parallelWorks"), s = T(), l = c(), { data: u } = w(n), [d, h] = v(a.url ?? (u?.mode === "platform" ? window.location.origin : "https://cloud.parallel.works")), [y, E] = v(""), D = C({
|
|
40
40
|
mutationFn: async () => t(await e.PUT("/api/v1/workspaces/{workspace}/parallelworks", {
|
|
41
41
|
params: { path: { workspace: r } },
|
|
42
42
|
body: {
|
|
@@ -44,8 +44,8 @@ function k({ workspace: r, conn: a }) {
|
|
|
44
44
|
apiKey: y.trim()
|
|
45
45
|
}
|
|
46
46
|
})),
|
|
47
|
-
onMutate:
|
|
48
|
-
onError:
|
|
47
|
+
onMutate: l.clear,
|
|
48
|
+
onError: l.set,
|
|
49
49
|
onSuccess: (e) => s.setQueryData(i(r).queryKey, e)
|
|
50
50
|
});
|
|
51
51
|
return /* @__PURE__ */ S("form", {
|
|
@@ -67,7 +67,7 @@ function k({ workspace: r, conn: a }) {
|
|
|
67
67
|
children: o("connectButton")
|
|
68
68
|
}),
|
|
69
69
|
actionAlign: "end",
|
|
70
|
-
error:
|
|
70
|
+
error: l.error,
|
|
71
71
|
children: [/* @__PURE__ */ x(g, {
|
|
72
72
|
label: o("url"),
|
|
73
73
|
htmlFor: "pw-url",
|
|
@@ -101,15 +101,15 @@ function k({ workspace: r, conn: a }) {
|
|
|
101
101
|
});
|
|
102
102
|
}
|
|
103
103
|
function A({ workspace: n, conn: r }) {
|
|
104
|
-
let a = b("parallelWorks"), o = y(),
|
|
104
|
+
let a = b("parallelWorks"), o = y(), s = T(), { confirm: c, dialog: u } = l(), d = C({
|
|
105
105
|
mutationFn: async () => t(await e.DELETE("/api/v1/workspaces/{workspace}/parallelworks", { params: { path: { workspace: n } } })),
|
|
106
|
-
onSettled: () =>
|
|
106
|
+
onSettled: () => s.invalidateQueries({ queryKey: i(n).queryKey })
|
|
107
107
|
});
|
|
108
108
|
return /* @__PURE__ */ S(_, {
|
|
109
109
|
title: a("account"),
|
|
110
110
|
action: /* @__PURE__ */ x(f, {
|
|
111
111
|
variant: "danger",
|
|
112
|
-
onClick: () =>
|
|
112
|
+
onClick: () => c({
|
|
113
113
|
title: a("disconnectTitle"),
|
|
114
114
|
description: a("disconnectDescription"),
|
|
115
115
|
confirmLabel: a("disconnect"),
|
|
@@ -147,8 +147,8 @@ function A({ workspace: n, conn: r }) {
|
|
|
147
147
|
}
|
|
148
148
|
var j = (e) => `${e.user}/${e.name}`;
|
|
149
149
|
function M({ workspace: n, conn: o }) {
|
|
150
|
-
let s = b("parallelWorks"),
|
|
151
|
-
e ?
|
|
150
|
+
let s = b("parallelWorks"), l = T(), u = c(), d = w(r(n)), [p, m] = v(o.bucket ? j(o.bucket) : null), y = (e) => {
|
|
151
|
+
e ? l.setQueryData(i(n).queryKey, e) : l.invalidateQueries({ queryKey: i(n).queryKey });
|
|
152
152
|
}, E = C({
|
|
153
153
|
mutationFn: async (r) => t(await e.PUT("/api/v1/workspaces/{workspace}/parallelworks/bucket", {
|
|
154
154
|
params: { path: { workspace: n } },
|
|
@@ -157,13 +157,13 @@ function M({ workspace: n, conn: o }) {
|
|
|
157
157
|
name: r.name
|
|
158
158
|
}
|
|
159
159
|
})),
|
|
160
|
-
onMutate:
|
|
161
|
-
onError:
|
|
160
|
+
onMutate: u.clear,
|
|
161
|
+
onError: u.set,
|
|
162
162
|
onSuccess: y
|
|
163
163
|
}), D = C({
|
|
164
164
|
mutationFn: async () => t(await e.DELETE("/api/v1/workspaces/{workspace}/parallelworks/bucket", { params: { path: { workspace: n } } })),
|
|
165
|
-
onMutate:
|
|
166
|
-
onError:
|
|
165
|
+
onMutate: u.clear,
|
|
166
|
+
onError: u.set,
|
|
167
167
|
onSuccess: () => {
|
|
168
168
|
m(null), y();
|
|
169
169
|
}
|
|
@@ -171,7 +171,7 @@ function M({ workspace: n, conn: o }) {
|
|
|
171
171
|
return /* @__PURE__ */ S(_, {
|
|
172
172
|
title: s("storage"),
|
|
173
173
|
description: s("storageDescription"),
|
|
174
|
-
error:
|
|
174
|
+
error: u.error ?? (d.error && s("bucketsFailed")),
|
|
175
175
|
children: [
|
|
176
176
|
/* @__PURE__ */ x(g, {
|
|
177
177
|
label: s("filesGoTo"),
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { api as e, unwrap as t } from "../../../api/client.js";
|
|
2
2
|
import { meQuery as n, rolesQuery as r, workspaceAccessQuery as i } from "../../../api/queries.js";
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
3
|
+
import { AccessGrants as a } from "../../../components/AccessGrants.js";
|
|
4
|
+
import { ShieldIcon as o } from "../../../components/icons.js";
|
|
5
|
+
import { AdminOnly as s, SettingsPage as c } from "../../../components/settings.js";
|
|
5
6
|
import { useConfirm as l } from "../../../lib/confirm.js";
|
|
6
|
-
import {
|
|
7
|
-
import { Route as
|
|
8
|
-
import { AccessGrants as p } from "../../../components/AccessGrants.js";
|
|
7
|
+
import { isBuiltIn as u, permissionGroups as d, useCan as f } from "../../../lib/roles.js";
|
|
8
|
+
import { Route as p } from "./roles.js";
|
|
9
9
|
import { Button as m, Callout as h, Checkbox as g, ErrorText as _, Input as v, Modal as y, PageHeaderAddButton as b, StatusBadge as x, Table as S, Textarea as C, useOpenMenu as w } from "@parallelworks/ui";
|
|
10
10
|
import { useMemo as T, useState as E } from "react";
|
|
11
11
|
import { useErrorMessage as D } from "@parallelworks/problem/react";
|
|
@@ -15,7 +15,7 @@ import { useMutation as M, useQueryClient as N, useSuspenseQuery as P } from "@t
|
|
|
15
15
|
import { ListCellText as F, ListColumns as I, ListPage as L, ListRow as R, NameCell as z, listTableProps as B, useListNavigate as V, useListView as H } from "@parallelworks/ui/list";
|
|
16
16
|
// src/routes/$workspace/settings/roles.tsx?tsr-split=component
|
|
17
17
|
function U() {
|
|
18
|
-
let { workspace: i } =
|
|
18
|
+
let { workspace: i } = p.useParams(), { data: a } = P(n), { data: d } = P(r(i)), m = f(i, "manage_members") && a?.mode !== "platform", h = O("roleSettings"), g = O("roles"), v = O("common"), y = w(), C = V(), { confirm: k, dialog: U } = l(), ee = D(), te = N(), [q, J] = E(null), [Y, X] = E(null), ne = M({
|
|
19
19
|
mutationFn: async (n) => t(await e.DELETE("/api/v1/workspaces/{workspace}/roles/{role}", { params: { path: {
|
|
20
20
|
workspace: i,
|
|
21
21
|
role: n
|
|
@@ -46,7 +46,7 @@ function U() {
|
|
|
46
46
|
columns: re,
|
|
47
47
|
orderBys: [],
|
|
48
48
|
facets: []
|
|
49
|
-
}), Q = (e) =>
|
|
49
|
+
}), Q = (e) => u(e.id) ? g(`${e.id}.name`) : e.name, ie = (e) => u(e.id) ? g(`${e.id}.description`) : e.description, $ = (e) => k({
|
|
50
50
|
title: h("deleteTitle", { name: e.name }),
|
|
51
51
|
description: h("deleteDescription", { name: e.name }),
|
|
52
52
|
confirmLabel: v("delete"),
|
|
@@ -59,7 +59,7 @@ function U() {
|
|
|
59
59
|
destructive: !0,
|
|
60
60
|
onClick: () => $(e)
|
|
61
61
|
}] : []];
|
|
62
|
-
return /* @__PURE__ */ j(
|
|
62
|
+
return /* @__PURE__ */ j(c, {
|
|
63
63
|
wide: !0,
|
|
64
64
|
title: h("title"),
|
|
65
65
|
description: h("description"),
|
|
@@ -73,7 +73,7 @@ function U() {
|
|
|
73
73
|
className: "px-4",
|
|
74
74
|
children: [
|
|
75
75
|
/* @__PURE__ */ A(W, { workspace: i }),
|
|
76
|
-
/* @__PURE__ */ A(
|
|
76
|
+
/* @__PURE__ */ A(s, {
|
|
77
77
|
workspace: i,
|
|
78
78
|
permission: "manage_members"
|
|
79
79
|
}),
|
|
@@ -88,11 +88,11 @@ function U() {
|
|
|
88
88
|
className: "border-t border-border",
|
|
89
89
|
children: /* @__PURE__ */ A(L, {
|
|
90
90
|
view: Z,
|
|
91
|
-
total:
|
|
92
|
-
matches:
|
|
91
|
+
total: d.length,
|
|
92
|
+
matches: d.length,
|
|
93
93
|
children: /* @__PURE__ */ j(S, {
|
|
94
94
|
...B,
|
|
95
|
-
children: [/* @__PURE__ */ A(I, { view: Z }),
|
|
95
|
+
children: [/* @__PURE__ */ A(I, { view: Z }), d.map((e) => /* @__PURE__ */ j(R, {
|
|
96
96
|
href: null,
|
|
97
97
|
onActivate: () => J(e),
|
|
98
98
|
items: ae(e),
|
|
@@ -100,7 +100,7 @@ function U() {
|
|
|
100
100
|
openMenu: y,
|
|
101
101
|
children: [
|
|
102
102
|
/* @__PURE__ */ A(z, {
|
|
103
|
-
icon: /* @__PURE__ */ A(
|
|
103
|
+
icon: /* @__PURE__ */ A(o, {}),
|
|
104
104
|
iconTile: !0,
|
|
105
105
|
name: Q(e),
|
|
106
106
|
subtitle: ie(e) || void 0,
|
|
@@ -131,7 +131,7 @@ function U() {
|
|
|
131
131
|
})
|
|
132
132
|
})
|
|
133
133
|
}),
|
|
134
|
-
|
|
134
|
+
a?.mode !== "platform" && /* @__PURE__ */ A(G, {
|
|
135
135
|
workspace: i,
|
|
136
136
|
readOnly: !m
|
|
137
137
|
}),
|
|
@@ -161,24 +161,24 @@ function W({ workspace: e }) {
|
|
|
161
161
|
})] })]
|
|
162
162
|
}) : null;
|
|
163
163
|
}
|
|
164
|
-
function G({ workspace: r, readOnly:
|
|
165
|
-
let
|
|
164
|
+
function G({ workspace: r, readOnly: o }) {
|
|
165
|
+
let s = O("roleSettings"), c = N(), { data: l } = P(i(r)), { data: u } = P(n), d = u?.workspaces.find((e) => e.slug === r)?.name ?? r;
|
|
166
166
|
return /* @__PURE__ */ j("section", {
|
|
167
167
|
className: "mt-10 px-4",
|
|
168
168
|
children: [
|
|
169
169
|
/* @__PURE__ */ A("h2", {
|
|
170
170
|
className: "text-sm font-semibold",
|
|
171
|
-
children:
|
|
171
|
+
children: s("acrossTitle")
|
|
172
172
|
}),
|
|
173
173
|
/* @__PURE__ */ A("p", {
|
|
174
174
|
className: "mt-1 mb-4 text-sm text-muted-foreground",
|
|
175
|
-
children:
|
|
175
|
+
children: s("acrossDescription")
|
|
176
176
|
}),
|
|
177
|
-
/* @__PURE__ */ A(
|
|
177
|
+
/* @__PURE__ */ A(a, {
|
|
178
178
|
workspace: r,
|
|
179
|
-
resourceName:
|
|
180
|
-
access:
|
|
181
|
-
readOnly:
|
|
179
|
+
resourceName: d,
|
|
180
|
+
access: l,
|
|
181
|
+
readOnly: o,
|
|
182
182
|
save: async (n) => {
|
|
183
183
|
await t(await e.PUT("/api/v1/workspaces/{workspace}/access", {
|
|
184
184
|
params: { path: { workspace: r } },
|
|
@@ -186,24 +186,24 @@ function G({ workspace: r, readOnly: a }) {
|
|
|
186
186
|
restricted: !1,
|
|
187
187
|
grants: n.grants
|
|
188
188
|
}
|
|
189
|
-
})), await
|
|
189
|
+
})), await c.invalidateQueries({ queryKey: i(r).queryKey });
|
|
190
190
|
}
|
|
191
191
|
})
|
|
192
192
|
]
|
|
193
193
|
});
|
|
194
194
|
}
|
|
195
|
-
function K({ workspace: i, role:
|
|
196
|
-
let f = O("roleSettings"), p = O("permissions"), h = O("common"), b = D(), x = N(), [S, w] = E(
|
|
195
|
+
function K({ workspace: i, role: a, name: s, readOnly: c, onDelete: l, onClose: u }) {
|
|
196
|
+
let f = O("roleSettings"), p = O("permissions"), h = O("common"), b = D(), x = N(), [S, w] = E(s), [T, P] = E(a?.description ?? ""), [F, I] = E(new Set(a?.permissions ?? ["read", "comment"])), L = M({
|
|
197
197
|
mutationFn: async () => {
|
|
198
198
|
let n = {
|
|
199
199
|
name: S.trim(),
|
|
200
200
|
description: T.trim(),
|
|
201
201
|
permissions: [...F]
|
|
202
202
|
};
|
|
203
|
-
return t(
|
|
203
|
+
return t(a ? await e.PATCH("/api/v1/workspaces/{workspace}/roles/{role}", {
|
|
204
204
|
params: { path: {
|
|
205
205
|
workspace: i,
|
|
206
|
-
role:
|
|
206
|
+
role: a.id
|
|
207
207
|
} },
|
|
208
208
|
body: n
|
|
209
209
|
}) : await e.POST("/api/v1/workspaces/{workspace}/roles", {
|
|
@@ -212,7 +212,7 @@ function K({ workspace: i, role: o, name: c, readOnly: l, onDelete: u, onClose:
|
|
|
212
212
|
}));
|
|
213
213
|
},
|
|
214
214
|
onSuccess: async () => {
|
|
215
|
-
await x.invalidateQueries({ queryKey: r(i).queryKey }), await x.invalidateQueries({ queryKey: n.queryKey }),
|
|
215
|
+
await x.invalidateQueries({ queryKey: r(i).queryKey }), await x.invalidateQueries({ queryKey: n.queryKey }), u();
|
|
216
216
|
}
|
|
217
217
|
}), R = (e, t) => {
|
|
218
218
|
let n = new Set(F);
|
|
@@ -220,42 +220,42 @@ function K({ workspace: i, role: o, name: c, readOnly: l, onDelete: u, onClose:
|
|
|
220
220
|
};
|
|
221
221
|
return /* @__PURE__ */ j(y, {
|
|
222
222
|
open: !0,
|
|
223
|
-
onClose:
|
|
223
|
+
onClose: u,
|
|
224
224
|
size: "lg",
|
|
225
225
|
title: /* @__PURE__ */ j("span", {
|
|
226
226
|
className: "flex items-center gap-2",
|
|
227
|
-
children: [/* @__PURE__ */ A(
|
|
227
|
+
children: [/* @__PURE__ */ A(o, { className: "size-4 text-muted-foreground" }), a ? s : f("new")]
|
|
228
228
|
}),
|
|
229
|
-
...
|
|
229
|
+
...c && a?.description && { description: a.description },
|
|
230
230
|
onSubmit: () => L.mutate(),
|
|
231
231
|
footer: /* @__PURE__ */ j(k, { children: [
|
|
232
|
-
|
|
232
|
+
l && /* @__PURE__ */ A("button", {
|
|
233
233
|
type: "button",
|
|
234
|
-
onClick:
|
|
234
|
+
onClick: l,
|
|
235
235
|
className: "mr-auto text-sm text-danger hover:underline",
|
|
236
236
|
children: f("delete")
|
|
237
237
|
}),
|
|
238
238
|
/* @__PURE__ */ A(m, {
|
|
239
239
|
type: "button",
|
|
240
|
-
onClick:
|
|
241
|
-
children: h(
|
|
240
|
+
onClick: u,
|
|
241
|
+
children: h(c ? "close" : "cancel")
|
|
242
242
|
}),
|
|
243
|
-
!
|
|
243
|
+
!c && /* @__PURE__ */ A(m, {
|
|
244
244
|
type: "submit",
|
|
245
245
|
variant: "primary",
|
|
246
246
|
disabled: !S.trim(),
|
|
247
247
|
loading: L.isPending,
|
|
248
|
-
children:
|
|
248
|
+
children: a ? h("save") : f("create")
|
|
249
249
|
})
|
|
250
250
|
] }),
|
|
251
251
|
children: [
|
|
252
|
-
!
|
|
252
|
+
!c && /* @__PURE__ */ j("div", {
|
|
253
253
|
className: "mb-5 space-y-3",
|
|
254
254
|
children: [/* @__PURE__ */ j("label", {
|
|
255
255
|
className: "block text-xs text-muted-foreground",
|
|
256
256
|
children: [f("name"), /* @__PURE__ */ A(v, {
|
|
257
257
|
required: !0,
|
|
258
|
-
autoFocus: !
|
|
258
|
+
autoFocus: !a,
|
|
259
259
|
maxLength: 60,
|
|
260
260
|
value: S,
|
|
261
261
|
onChange: (e) => w(e.target.value),
|
|
@@ -276,7 +276,7 @@ function K({ workspace: i, role: o, name: c, readOnly: l, onDelete: u, onClose:
|
|
|
276
276
|
}),
|
|
277
277
|
/* @__PURE__ */ A("div", {
|
|
278
278
|
className: "space-y-5",
|
|
279
|
-
children:
|
|
279
|
+
children: d.map((e) => /* @__PURE__ */ j("fieldset", { children: [/* @__PURE__ */ A("legend", {
|
|
280
280
|
className: "mb-2 text-xs font-medium text-muted-foreground",
|
|
281
281
|
children: f(`groups.${e.id}`)
|
|
282
282
|
}), /* @__PURE__ */ A("div", {
|
|
@@ -286,7 +286,7 @@ function K({ workspace: i, role: o, name: c, readOnly: l, onDelete: u, onClose:
|
|
|
286
286
|
children: [/* @__PURE__ */ A(g, {
|
|
287
287
|
className: "mt-0.5",
|
|
288
288
|
checked: F.has(e),
|
|
289
|
-
disabled:
|
|
289
|
+
disabled: c || e === "read",
|
|
290
290
|
onCheckedChange: (t) => R(e, t)
|
|
291
291
|
}), /* @__PURE__ */ j("span", {
|
|
292
292
|
className: "min-w-0",
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { api as e, unwrap as t } from "../../../api/client.js";
|
|
2
2
|
import { runnersQuery as n } from "../../../api/queries.js";
|
|
3
|
-
import {
|
|
3
|
+
import { ComputeTargets as r } from "../../../components/ComputeTargets.js";
|
|
4
4
|
import { WorkerIcon as i } from "../../../components/icons.js";
|
|
5
|
-
import {
|
|
5
|
+
import { SettingsPage as a } from "../../../components/settings.js";
|
|
6
6
|
import { useConfirm as o } from "../../../lib/confirm.js";
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
7
|
+
import { copyItem as s } from "../../../lib/menus.js";
|
|
8
|
+
import { useTime as c } from "../../../lib/time.js";
|
|
9
|
+
import { Route as l } from "./runners.js";
|
|
10
10
|
import { Callout as u, StatusDot as d, Table as f, menuDivider as p, useOpenMenu as m } from "@parallelworks/ui";
|
|
11
11
|
import { useMemo as h } from "react";
|
|
12
12
|
import { useFormatter as g, useTranslations as _ } from "use-intl";
|
|
@@ -21,16 +21,16 @@ var N = {
|
|
|
21
21
|
bypass: "runnerModeBypass"
|
|
22
22
|
};
|
|
23
23
|
function P() {
|
|
24
|
-
let { workspace: e } =
|
|
24
|
+
let { workspace: e } = l.useParams();
|
|
25
25
|
return /* @__PURE__ */ v(F, { workspace: e });
|
|
26
26
|
}
|
|
27
|
-
function F({ workspace:
|
|
28
|
-
let { data: P } = S(n(
|
|
27
|
+
function F({ workspace: l }) {
|
|
28
|
+
let { data: P } = S(n(l)), F = _("account"), I = g(), L = _("common"), R = c(), z = x(), B = j(), V = A(), H = m(), U = b({
|
|
29
29
|
mutationFn: async (n) => t(await e.DELETE("/api/v1/workspaces/{workspace}/runners/{runnerId}", { params: { path: {
|
|
30
|
-
workspace:
|
|
30
|
+
workspace: l,
|
|
31
31
|
runnerId: n
|
|
32
32
|
} } })),
|
|
33
|
-
onSettled: () => z.invalidateQueries({ queryKey: n(
|
|
33
|
+
onSettled: () => z.invalidateQueries({ queryKey: n(l).queryKey })
|
|
34
34
|
}), { confirm: W, dialog: G } = o(), K = (e) => W({
|
|
35
35
|
title: F("revokeRunnerTitle"),
|
|
36
36
|
description: F("revokeRunnerDescription", { name: e.name }),
|
|
@@ -55,7 +55,7 @@ function F({ workspace: c }) {
|
|
|
55
55
|
label: F("runnerColSeen"),
|
|
56
56
|
compare: (e, t) => (t.lastSeenAt ?? "").localeCompare(e.lastSeenAt ?? "")
|
|
57
57
|
}], [F, L]), Y = M({
|
|
58
|
-
storageKey: `tandem-runners-${
|
|
58
|
+
storageKey: `tandem-runners-${l}`,
|
|
59
59
|
defaultShowColumnHeaders: !1,
|
|
60
60
|
columns: q,
|
|
61
61
|
orderBys: J,
|
|
@@ -67,7 +67,7 @@ function F({ workspace: c }) {
|
|
|
67
67
|
...e.harnesses,
|
|
68
68
|
...e.labels
|
|
69
69
|
].some((e) => e.toLowerCase().includes(X))), Q = P.filter((e) => e.sharingRefused), $ = P.filter((e) => e.sharingUnchecked);
|
|
70
|
-
return /* @__PURE__ */ y(
|
|
70
|
+
return /* @__PURE__ */ y(a, {
|
|
71
71
|
wide: !0,
|
|
72
72
|
title: F("runners"),
|
|
73
73
|
description: F.rich("runnersDescription", { code: (e) => /* @__PURE__ */ v("code", {
|
|
@@ -120,8 +120,8 @@ function F({ workspace: c }) {
|
|
|
120
120
|
goTo: V,
|
|
121
121
|
openMenu: H,
|
|
122
122
|
items: [
|
|
123
|
-
|
|
124
|
-
|
|
123
|
+
s(F("copyRunnerId"), e.id),
|
|
124
|
+
s(L("copyName"), e.name),
|
|
125
125
|
p,
|
|
126
126
|
{
|
|
127
127
|
label: F("revoke"),
|
|
@@ -157,7 +157,7 @@ function F({ workspace: c }) {
|
|
|
157
157
|
})
|
|
158
158
|
})
|
|
159
159
|
}),
|
|
160
|
-
/* @__PURE__ */ v(
|
|
160
|
+
/* @__PURE__ */ v(r, { workspace: l }),
|
|
161
161
|
G
|
|
162
162
|
]
|
|
163
163
|
});
|
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
import { api as e, unwrap as t } from "../../../api/client.js";
|
|
2
2
|
import { sentryProjectsQuery as n, sentryQuery as r, teamsQuery as i } from "../../../api/queries.js";
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
3
|
+
import { ConnectionCard as a } from "../../../components/ConnectionCard.js";
|
|
4
|
+
import { AlertIcon as o } from "../../../components/icons.js";
|
|
5
|
+
import { AdminOnly as s, SettingsPage as c, useFormError as l } from "../../../components/settings.js";
|
|
6
|
+
import { usePeople as u } from "../../../lib/people.js";
|
|
7
|
+
import { useCan as d } from "../../../lib/roles.js";
|
|
8
|
+
import { Route as f } from "./sentry.js";
|
|
9
9
|
import { Combobox as p, SettingRow as m, SettingsCard as h, StatusLabel as g, Switch as _, Tag as v, buttonClasses as y } from "@parallelworks/ui";
|
|
10
10
|
import { useFormatter as b, useTranslations as x } from "use-intl";
|
|
11
11
|
import { Fragment as S, jsx as C, jsxs as w } from "react/jsx-runtime";
|
|
12
12
|
import { useMutation as T, useQuery as E, useQueryClient as D, useSuspenseQuery as O } from "@tanstack/react-query";
|
|
13
13
|
// src/routes/$workspace/settings/sentry.tsx?tsr-split=component
|
|
14
14
|
function k() {
|
|
15
|
-
let { workspace: n } =
|
|
15
|
+
let { workspace: n } = f.useParams(), { data: p } = O(r(n)), { data: v } = O(i(n)), E = d(n, "manage_workspace"), k = x("settingsNav"), j = x("sentry"), M = b(), { person: N } = u(n), P = D(), F = l(), I = T({
|
|
16
16
|
mutationFn: async ({ teamId: r, on: i }) => t(await e.PUT("/api/v1/workspaces/{workspace}/sentry/teams/{teamId}", {
|
|
17
17
|
params: { path: {
|
|
18
18
|
workspace: n,
|
|
@@ -24,18 +24,18 @@ function k() {
|
|
|
24
24
|
onSuccess: () => P.invalidateQueries({ queryKey: r(n).queryKey }),
|
|
25
25
|
onError: F.set
|
|
26
26
|
}), L = new Set(p.teams.filter((e) => e.resolve).map((e) => e.teamId));
|
|
27
|
-
return /* @__PURE__ */ w(
|
|
27
|
+
return /* @__PURE__ */ w(c, {
|
|
28
28
|
title: k("sentry"),
|
|
29
29
|
description: j("pageDescription"),
|
|
30
|
-
children: [/* @__PURE__ */ C(
|
|
30
|
+
children: [/* @__PURE__ */ C(s, { workspace: n }), p.enabled ? /* @__PURE__ */ w("div", {
|
|
31
31
|
className: "space-y-6",
|
|
32
32
|
children: [
|
|
33
33
|
/* @__PURE__ */ C("p", {
|
|
34
34
|
className: "text-sm text-muted-foreground",
|
|
35
35
|
children: j("managedByHost")
|
|
36
36
|
}),
|
|
37
|
-
/* @__PURE__ */ C(
|
|
38
|
-
icon: /* @__PURE__ */ C(
|
|
37
|
+
/* @__PURE__ */ C(a, {
|
|
38
|
+
icon: /* @__PURE__ */ C(o, { className: "size-6" }),
|
|
39
39
|
name: k("sentry"),
|
|
40
40
|
status: p.connected ? j("connectedTo", {
|
|
41
41
|
organization: p.organizationName || p.organization || "",
|
|
@@ -95,7 +95,7 @@ function k() {
|
|
|
95
95
|
});
|
|
96
96
|
}
|
|
97
97
|
function A({ workspace: r }) {
|
|
98
|
-
let i = x("sentry"), a = D(), o =
|
|
98
|
+
let i = x("sentry"), a = D(), o = l(), { data: s, isError: c } = E(n(r)), u = T({
|
|
99
99
|
mutationFn: async ({ projectId: n, ids: i }) => t(await e.PUT("/api/v1/workspaces/{workspace}/sentry/projects/{projectId}/repositories", {
|
|
100
100
|
params: { path: {
|
|
101
101
|
workspace: r,
|
|
@@ -130,15 +130,15 @@ function A({ workspace: r }) {
|
|
|
130
130
|
children: e.platform || i("unknownPlatform")
|
|
131
131
|
})]
|
|
132
132
|
}),
|
|
133
|
-
error:
|
|
133
|
+
error: u.variables?.projectId === e.id ? o.error : null,
|
|
134
134
|
children: /* @__PURE__ */ C(p, {
|
|
135
135
|
multiple: !0,
|
|
136
136
|
"aria-label": i("projectRepositories", { project: e.name }),
|
|
137
137
|
placeholder: d.length ? i("chooseRepositories") : i("noRepositories"),
|
|
138
138
|
disabled: d.length === 0,
|
|
139
139
|
items: d,
|
|
140
|
-
value:
|
|
141
|
-
onValueChange: (t) =>
|
|
140
|
+
value: u.isPending && u.variables?.projectId === e.id ? u.variables.ids : e.repositories.map((e) => e.id),
|
|
141
|
+
onValueChange: (t) => u.mutate({
|
|
142
142
|
projectId: e.id,
|
|
143
143
|
ids: t
|
|
144
144
|
})
|