@burdenoff/microfe-workspaces 2026.1113.1 → 2026.1114.1
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/dist/WorkspacesRoot.js +31 -25
- package/dist/components/CreateProjectDialog.js +81 -78
- package/dist/components/CreateWorkspaceDialog.js +41 -41
- package/dist/components/InviteMemberDialog.js +54 -54
- package/dist/components/MemberListItem.js +53 -53
- package/dist/components/ProjectCard.js +82 -82
- package/dist/components/ProjectMemberPickerDialog.js +46 -46
- package/dist/components/RenameProjectDialog.js +16 -16
- package/dist/components/WorkspaceCard.js +18 -18
- package/dist/components/WorkspacesErrorBoundary.js +25 -25
- package/dist/components/tags/ProjectTagsWidget.js +50 -50
- package/dist/components/tags/WorkspaceTagsEditor.js +9 -9
- package/dist/index.d.ts +2 -2
- package/dist/index.js +15 -14
- package/dist/pages/ActivityListPage.js +30 -30
- package/dist/pages/CreateWorkspacePage.js +205 -173
- package/dist/pages/InviteAcceptancePage.js +201 -201
- package/dist/pages/MembersListPage.js +165 -164
- package/dist/pages/PendingInvitesPage.js +67 -67
- package/dist/pages/ProjectDetailPage.js +297 -272
- package/dist/pages/ProjectMembersPage.js +59 -59
- package/dist/pages/ProjectsListPage.js +275 -244
- package/dist/pages/WorkspaceDetailPage.js +175 -172
- package/dist/pages/WorkspaceInvitePage.js +298 -298
- package/dist/pages/WorkspaceSettingsPage.js +48 -48
- package/dist/pages/WorkspacesListPage.js +55 -55
- package/dist/pages/dashboard/DashboardCustomizer.js +27 -27
- package/dist/pages/dashboard/DashboardPage.js +35 -35
- package/dist/pages/dashboard/WidgetWrapper.js +21 -21
- package/dist/pages/dashboard/widgets/AgentsWidget.js +25 -25
- package/dist/pages/dashboard/widgets/GroupsWidget.js +14 -14
- package/dist/pages/dashboard/widgets/MembersWidget.js +15 -15
- package/dist/pages/dashboard/widgets/ProjectsWidget.js +20 -20
- package/dist/pages/dashboard/widgets/QuickActionsWidget.js +7 -7
- package/dist/pages/dashboard/widgets/RecentActivityWidget.js +16 -16
- package/dist/pages/dashboard/widgets/SessionsWidget.js +15 -15
- package/dist/pages/dashboard/widgets/TagCloudWidget.js +11 -11
- package/dist/pages/dashboard/widgets/UpcomingEventsWidget.js +16 -16
- package/dist/pages/dashboard/widgets/VibesWidget.js +13 -13
- package/dist/pages/dashboard/widgets/WelcomeWidget.js +23 -23
- package/dist/pages/dashboard/widgets/WorkflowRunsWidget.js +26 -26
- package/dist/pages/dashboard/widgets/WorkflowStatsWidget.js +21 -21
- package/dist/pages/dashboard/widgets/WorkflowsOverviewWidget.js +22 -22
- package/dist/pages/dashboard/widgets/WorkspacesWidget.js +16 -16
- package/dist/providers/WorkspacesProvider.d.ts +5 -0
- package/dist/providers/WorkspacesProvider.js +2 -2
- package/dist/types/index.d.ts +11 -1
- package/dist/utils/createForms.d.ts +21 -0
- package/dist/utils/createForms.js +20 -0
- package/dist/utils/index.d.ts +1 -0
- package/package.json +2 -2
|
@@ -2,12 +2,12 @@ import { getWorkspaceStatusClasses as e } from "../utils/tokenHelpers.js";
|
|
|
2
2
|
import { useOpenWorkspace as t } from "../hooks/useOpenWorkspace.js";
|
|
3
3
|
import { useTr as n } from "../hooks/useTr.js";
|
|
4
4
|
import { Building2 as r, FolderKanban as i, Users as a } from "lucide-react";
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
5
|
+
import { Badge as o, CardContent as s, CardHeader as c, CardTitle as l, GlassCard as u } from "@burdenoff/fe-libs/ui";
|
|
6
|
+
import { jsx as d, jsxs as f } from "react/jsx-runtime";
|
|
7
7
|
// src/components/WorkspaceCard.tsx
|
|
8
8
|
function p({ workspace: p }) {
|
|
9
9
|
let m = n(), h = t(), g = () => h(p);
|
|
10
|
-
return /* @__PURE__ */
|
|
10
|
+
return /* @__PURE__ */ f(u, {
|
|
11
11
|
treatment: "insight",
|
|
12
12
|
className: "cursor-pointer focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-action-primary-bg/50",
|
|
13
13
|
onClick: g,
|
|
@@ -18,49 +18,49 @@ function p({ workspace: p }) {
|
|
|
18
18
|
tabIndex: 0,
|
|
19
19
|
"aria-label": m("workspaceCard.openWorkspaceAriaLabel", "Open workspace {{name}}", { name: p.name }),
|
|
20
20
|
"data-tour": "workspaces-card",
|
|
21
|
-
children: [/* @__PURE__ */
|
|
21
|
+
children: [/* @__PURE__ */ d(c, { children: /* @__PURE__ */ f("div", {
|
|
22
22
|
className: "flex items-center gap-3",
|
|
23
|
-
children: [/* @__PURE__ */
|
|
23
|
+
children: [/* @__PURE__ */ d("div", {
|
|
24
24
|
className: "p-3 rounded-lg bg-action-primary-bg/10 transition-colors",
|
|
25
|
-
children: /* @__PURE__ */
|
|
25
|
+
children: /* @__PURE__ */ d(r, {
|
|
26
26
|
className: "text-primary",
|
|
27
27
|
size: 24
|
|
28
28
|
})
|
|
29
|
-
}), /* @__PURE__ */
|
|
29
|
+
}), /* @__PURE__ */ f("div", {
|
|
30
30
|
className: "flex-1 min-w-0",
|
|
31
|
-
children: [/* @__PURE__ */
|
|
31
|
+
children: [/* @__PURE__ */ d(l, {
|
|
32
32
|
className: "text-lg truncate",
|
|
33
33
|
children: p.name
|
|
34
|
-
}), /* @__PURE__ */
|
|
34
|
+
}), /* @__PURE__ */ d("div", {
|
|
35
35
|
className: "flex items-center gap-2 mt-1",
|
|
36
|
-
children: /* @__PURE__ */ o
|
|
36
|
+
children: /* @__PURE__ */ d(o, {
|
|
37
37
|
className: `text-xs border ${e(p.status)}`,
|
|
38
38
|
children: p.status
|
|
39
39
|
})
|
|
40
40
|
})]
|
|
41
41
|
})]
|
|
42
|
-
}) }), /* @__PURE__ */ s
|
|
42
|
+
}) }), /* @__PURE__ */ f(s, { children: [/* @__PURE__ */ f("div", {
|
|
43
43
|
className: "flex flex-wrap gap-4 text-sm text-text-secondary",
|
|
44
|
-
children: [typeof p.memberCount == "number" && p.memberCount > 0 && /* @__PURE__ */
|
|
44
|
+
children: [typeof p.memberCount == "number" && p.memberCount > 0 && /* @__PURE__ */ f("div", {
|
|
45
45
|
className: "flex items-center gap-1",
|
|
46
|
-
children: [/* @__PURE__ */
|
|
46
|
+
children: [/* @__PURE__ */ d(a, {
|
|
47
47
|
size: 16,
|
|
48
48
|
"aria-hidden": "true"
|
|
49
|
-
}), /* @__PURE__ */
|
|
49
|
+
}), /* @__PURE__ */ d("span", { children: m("workspaceCard.memberCount", "{{count}} member{{suffix}}", {
|
|
50
50
|
count: p.memberCount,
|
|
51
51
|
suffix: p.memberCount === 1 ? "" : "s"
|
|
52
52
|
}) })]
|
|
53
|
-
}), typeof p.projectCount == "number" && p.projectCount > 0 && /* @__PURE__ */
|
|
53
|
+
}), typeof p.projectCount == "number" && p.projectCount > 0 && /* @__PURE__ */ f("div", {
|
|
54
54
|
className: "flex items-center gap-1",
|
|
55
|
-
children: [/* @__PURE__ */
|
|
55
|
+
children: [/* @__PURE__ */ d(i, {
|
|
56
56
|
size: 16,
|
|
57
57
|
"aria-hidden": "true"
|
|
58
|
-
}), /* @__PURE__ */
|
|
58
|
+
}), /* @__PURE__ */ d("span", { children: m("workspaceCard.projectCount", "{{count}} project{{suffix}}", {
|
|
59
59
|
count: p.projectCount,
|
|
60
60
|
suffix: p.projectCount === 1 ? "" : "s"
|
|
61
61
|
}) })]
|
|
62
62
|
})]
|
|
63
|
-
}), p.domain && /* @__PURE__ */
|
|
63
|
+
}), p.domain && /* @__PURE__ */ d("p", {
|
|
64
64
|
className: "mt-2 truncate text-xs text-text-muted",
|
|
65
65
|
children: p.domain
|
|
66
66
|
})] })]
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { useTr as e } from "../hooks/useTr.js";
|
|
2
2
|
import { Component as t } from "react";
|
|
3
3
|
import { AlertCircle as n, Home as r, RefreshCw as i } from "lucide-react";
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
4
|
+
import { Button as a } from "@burdenoff/fe-libs/ui";
|
|
5
|
+
import { jsx as o, jsxs as s } from "react/jsx-runtime";
|
|
6
6
|
// src/components/WorkspacesErrorBoundary.tsx
|
|
7
7
|
var c = class extends t {
|
|
8
8
|
constructor(e) {
|
|
@@ -54,77 +54,77 @@ var c = class extends t {
|
|
|
54
54
|
};
|
|
55
55
|
render() {
|
|
56
56
|
let { tr: e } = this.props;
|
|
57
|
-
return this.state.hasError ? this.props.fallback ? this.props.fallback : /* @__PURE__ */
|
|
57
|
+
return this.state.hasError ? this.props.fallback ? this.props.fallback : /* @__PURE__ */ o("div", {
|
|
58
58
|
className: "flex items-center justify-center min-h-[400px] p-6",
|
|
59
|
-
children: /* @__PURE__ */
|
|
59
|
+
children: /* @__PURE__ */ s("div", {
|
|
60
60
|
className: "max-w-md w-full text-center space-y-6",
|
|
61
61
|
children: [
|
|
62
|
-
/* @__PURE__ */
|
|
62
|
+
/* @__PURE__ */ o("div", {
|
|
63
63
|
className: "flex justify-center",
|
|
64
|
-
children: /* @__PURE__ */
|
|
64
|
+
children: /* @__PURE__ */ o("div", {
|
|
65
65
|
className: "rounded-full bg-status-error-bg/10 p-6",
|
|
66
|
-
children: /* @__PURE__ */
|
|
66
|
+
children: /* @__PURE__ */ o(n, { className: "size-12 text-status-error-text" })
|
|
67
67
|
})
|
|
68
68
|
}),
|
|
69
|
-
/* @__PURE__ */
|
|
69
|
+
/* @__PURE__ */ s("div", {
|
|
70
70
|
className: "space-y-2",
|
|
71
|
-
children: [/* @__PURE__ */
|
|
71
|
+
children: [/* @__PURE__ */ o("h2", {
|
|
72
72
|
className: "text-2xl font-bold",
|
|
73
73
|
children: e("errorBoundary.title", "Something went wrong")
|
|
74
|
-
}), /* @__PURE__ */
|
|
74
|
+
}), /* @__PURE__ */ o("p", {
|
|
75
75
|
className: "text-text-secondary",
|
|
76
76
|
children: e("errorBoundary.description", "We encountered an unexpected error. Please try refreshing the page or contact support if the problem persists.")
|
|
77
77
|
})]
|
|
78
78
|
}),
|
|
79
|
-
process.env.NODE_ENV === "development" && this.state.error && /* @__PURE__ */
|
|
79
|
+
process.env.NODE_ENV === "development" && this.state.error && /* @__PURE__ */ s("details", {
|
|
80
80
|
className: "text-left",
|
|
81
|
-
children: [/* @__PURE__ */
|
|
81
|
+
children: [/* @__PURE__ */ o("summary", {
|
|
82
82
|
className: "cursor-pointer text-sm font-medium text-text-secondary hover:text-text-primary transition-colors duration-200",
|
|
83
83
|
children: e("errorBoundary.errorDetails", "Error Details")
|
|
84
|
-
}), /* @__PURE__ */
|
|
84
|
+
}), /* @__PURE__ */ s("div", {
|
|
85
85
|
className: "mt-2 p-4 bg-bg-sunken rounded-lg text-xs font-mono overflow-auto max-h-40",
|
|
86
86
|
children: [
|
|
87
|
-
/* @__PURE__ */
|
|
87
|
+
/* @__PURE__ */ s("p", {
|
|
88
88
|
className: "font-semibold text-status-error-text",
|
|
89
89
|
children: [this.state.error.name, ":"]
|
|
90
90
|
}),
|
|
91
|
-
/* @__PURE__ */
|
|
91
|
+
/* @__PURE__ */ o("p", {
|
|
92
92
|
className: "text-text-primary",
|
|
93
93
|
children: this.state.error.message
|
|
94
94
|
}),
|
|
95
|
-
this.state.error.stack && /* @__PURE__ */
|
|
95
|
+
this.state.error.stack && /* @__PURE__ */ o("pre", {
|
|
96
96
|
className: "mt-2 text-text-secondary text-xs overflow-x-auto",
|
|
97
97
|
children: this.state.error.stack
|
|
98
98
|
})
|
|
99
99
|
]
|
|
100
100
|
})]
|
|
101
101
|
}),
|
|
102
|
-
/* @__PURE__ */
|
|
102
|
+
/* @__PURE__ */ s("div", {
|
|
103
103
|
className: "flex flex-col sm:flex-row gap-3 justify-center",
|
|
104
104
|
children: [
|
|
105
|
-
/* @__PURE__ */
|
|
105
|
+
/* @__PURE__ */ s(a, {
|
|
106
106
|
onClick: this.handleReset,
|
|
107
107
|
variant: "default",
|
|
108
|
-
children: [/* @__PURE__ */
|
|
108
|
+
children: [/* @__PURE__ */ o(i, { className: "mr-2 size-4" }), e("errorBoundary.tryAgain", "Try Again")]
|
|
109
109
|
}),
|
|
110
|
-
/* @__PURE__ */ a
|
|
110
|
+
/* @__PURE__ */ o(a, {
|
|
111
111
|
onClick: this.handleReload,
|
|
112
112
|
variant: "outline",
|
|
113
113
|
children: e("errorBoundary.reloadPage", "Reload Page")
|
|
114
114
|
}),
|
|
115
|
-
/* @__PURE__ */
|
|
115
|
+
/* @__PURE__ */ s(a, {
|
|
116
116
|
onClick: this.handleGoHome,
|
|
117
117
|
variant: "ghost",
|
|
118
|
-
children: [/* @__PURE__ */
|
|
118
|
+
children: [/* @__PURE__ */ o(r, { className: "mr-2 size-4" }), e("errorBoundary.goHome", "Go Home")]
|
|
119
119
|
})
|
|
120
120
|
]
|
|
121
121
|
}),
|
|
122
|
-
/* @__PURE__ */
|
|
122
|
+
/* @__PURE__ */ s("p", {
|
|
123
123
|
className: "text-sm text-text-secondary",
|
|
124
124
|
children: [
|
|
125
125
|
e("errorBoundary.needHelp", "Need help?"),
|
|
126
126
|
" ",
|
|
127
|
-
/* @__PURE__ */
|
|
127
|
+
/* @__PURE__ */ o("a", {
|
|
128
128
|
href: `mailto:${this.props.supportEmail ?? "support@burdenoff.com"}`,
|
|
129
129
|
className: "text-primary hover:underline transition-colors duration-200",
|
|
130
130
|
children: e("errorBoundary.contactSupport", "Contact Support")
|
|
@@ -138,7 +138,7 @@ var c = class extends t {
|
|
|
138
138
|
};
|
|
139
139
|
function l(t) {
|
|
140
140
|
let n = e();
|
|
141
|
-
return /* @__PURE__ */
|
|
141
|
+
return /* @__PURE__ */ o(c, {
|
|
142
142
|
...t,
|
|
143
143
|
tr: n
|
|
144
144
|
});
|
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import { useTr as e } from "../../hooks/useTr.js";
|
|
2
2
|
import { useCallback as t, useEffect as n, useRef as r, useState as i } from "react";
|
|
3
3
|
import { Loader2 as a, Plus as ee, Tag as te, X as ne } from "lucide-react";
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import { cn as
|
|
7
|
-
import { useGatewayClient as
|
|
8
|
-
import { TagBadge as
|
|
9
|
-
import { gql as
|
|
10
|
-
import { useLazyQuery as
|
|
4
|
+
import { Command as o, CommandEmpty as s, CommandGroup as c, CommandInput as re, CommandItem as l, CommandList as u, Popover as d, PopoverContent as f, PopoverTrigger as p } from "@burdenoff/fe-libs/ui";
|
|
5
|
+
import { jsx as m, jsxs as h } from "react/jsx-runtime";
|
|
6
|
+
import { cn as g } from "@burdenoff/fe-libs/shared/utils";
|
|
7
|
+
import { useGatewayClient as ie } from "@burdenoff/fe-libs/shared/graphql";
|
|
8
|
+
import { TagBadge as ae } from "@burdenoff/fe-libs/tag";
|
|
9
|
+
import { gql as _ } from "@apollo/client";
|
|
10
|
+
import { useLazyQuery as v, useMutation as y } from "@apollo/client/react";
|
|
11
11
|
// src/components/tags/ProjectTagsWidget.tsx
|
|
12
|
-
var
|
|
12
|
+
var b = _`
|
|
13
13
|
query ProjectTagsWidget_SearchTags($query: String!, $vocabularyId: ID, $limit: Int) {
|
|
14
14
|
searchTags(query: $query, vocabularyId: $vocabularyId, limit: $limit) {
|
|
15
15
|
id
|
|
@@ -27,7 +27,7 @@ var v = h`
|
|
|
27
27
|
}
|
|
28
28
|
}
|
|
29
29
|
}
|
|
30
|
-
`,
|
|
30
|
+
`, x = _`
|
|
31
31
|
query ProjectTagsWidget_GetVocabularyByKey($key: String!) {
|
|
32
32
|
getVocabularyByKey(key: $key) {
|
|
33
33
|
id
|
|
@@ -35,7 +35,7 @@ var v = h`
|
|
|
35
35
|
name
|
|
36
36
|
}
|
|
37
37
|
}
|
|
38
|
-
`,
|
|
38
|
+
`, oe = _`
|
|
39
39
|
mutation ProjectTagsWidget_CreateVocabulary($input: CreateVocabularyInput!) {
|
|
40
40
|
createVocabulary(input: $input) {
|
|
41
41
|
id
|
|
@@ -43,7 +43,7 @@ var v = h`
|
|
|
43
43
|
name
|
|
44
44
|
}
|
|
45
45
|
}
|
|
46
|
-
`,
|
|
46
|
+
`, se = _`
|
|
47
47
|
mutation ProjectTagsWidget_CreateTag($input: CreateTagInput!) {
|
|
48
48
|
createTag(input: $input) {
|
|
49
49
|
id
|
|
@@ -60,19 +60,19 @@ var v = h`
|
|
|
60
60
|
}
|
|
61
61
|
}
|
|
62
62
|
}
|
|
63
|
-
`,
|
|
64
|
-
function
|
|
63
|
+
`, S = "general";
|
|
64
|
+
function C(e) {
|
|
65
65
|
if (!e || typeof e != "object") return !1;
|
|
66
66
|
let t = e;
|
|
67
67
|
return typeof t.id == "string" && typeof t.key == "string" && typeof t.label == "string";
|
|
68
68
|
}
|
|
69
|
-
function
|
|
70
|
-
let A = e(), [ue, j] = i(!1), [M, N] = i(""), [P, F] = i(null), [I, L] = i(!1), [R, z] = i(), B = r(null), V =
|
|
69
|
+
function w({ entityType: _, entityId: w, workspaceId: ce, tags: T, onAdd: E, onRemove: D, allowCreate: O = !0, maxTags: k = 20, className: le }) {
|
|
70
|
+
let A = e(), [ue, j] = i(!1), [M, N] = i(""), [P, F] = i(null), [I, L] = i(!1), [R, z] = i(), B = r(null), V = ie("workspace"), H = !ce || !w, de = new Set(T.map((e) => e.id)), U = T.length < k, [W, { data: fe, loading: G }] = v(b, { client: V }), K = (fe?.searchTags ?? []).filter((e) => C(e) && !de.has(e.id)), [q, { loading: J }] = y(se, { client: V }), [Y] = v(x, { client: V }), [X] = y(oe, { client: V }), Z = t(async () => {
|
|
71
71
|
if (R) return R;
|
|
72
|
-
let e = (await Y({ variables: { key:
|
|
72
|
+
let e = (await Y({ variables: { key: S } })).data?.getVocabularyByKey;
|
|
73
73
|
if (e) return z(e.id), e.id;
|
|
74
74
|
let t = (await X({ variables: { input: {
|
|
75
|
-
key:
|
|
75
|
+
key: S,
|
|
76
76
|
name: "General",
|
|
77
77
|
description: "Default vocabulary for general-purpose tags",
|
|
78
78
|
scope: "WORKSPACE",
|
|
@@ -105,7 +105,7 @@ function C({ entityType: h, entityId: C, workspaceId: le, tags: w, onAdd: T, onR
|
|
|
105
105
|
if (U && !I) {
|
|
106
106
|
L(!0);
|
|
107
107
|
try {
|
|
108
|
-
await
|
|
108
|
+
await E({
|
|
109
109
|
...e,
|
|
110
110
|
vocabularyKey: e.vocabularyKey ?? e.vocabulary?.key ?? null
|
|
111
111
|
}), N(""), j(!1);
|
|
@@ -114,11 +114,11 @@ function C({ entityType: h, entityId: C, workspaceId: le, tags: w, onAdd: T, onR
|
|
|
114
114
|
}
|
|
115
115
|
}
|
|
116
116
|
}, [
|
|
117
|
-
|
|
117
|
+
E,
|
|
118
118
|
U,
|
|
119
119
|
I
|
|
120
120
|
]), me = t(async () => {
|
|
121
|
-
if (
|
|
121
|
+
if (O && M.trim() && !J) {
|
|
122
122
|
F(null);
|
|
123
123
|
try {
|
|
124
124
|
let e = M.trim(), t = e.toLowerCase().replace(/[^a-z0-9]+/g, "-").replace(/^-|-$/g, "");
|
|
@@ -131,14 +131,14 @@ function C({ entityType: h, entityId: C, workspaceId: le, tags: w, onAdd: T, onR
|
|
|
131
131
|
label: e,
|
|
132
132
|
vocabularyId: n
|
|
133
133
|
} } })).data?.createTag;
|
|
134
|
-
if (!
|
|
134
|
+
if (!C(r)) throw Error("No data returned");
|
|
135
135
|
await Q(r);
|
|
136
136
|
} catch (e) {
|
|
137
137
|
F(e instanceof Error ? e.message : A("projectTagsWidget.createGenericError", "Failed to create tag"));
|
|
138
138
|
}
|
|
139
139
|
}
|
|
140
140
|
}, [
|
|
141
|
-
|
|
141
|
+
O,
|
|
142
142
|
M,
|
|
143
143
|
J,
|
|
144
144
|
Z,
|
|
@@ -146,13 +146,13 @@ function C({ entityType: h, entityId: C, workspaceId: le, tags: w, onAdd: T, onR
|
|
|
146
146
|
Q,
|
|
147
147
|
A
|
|
148
148
|
]), he = t(async (e) => {
|
|
149
|
-
await
|
|
150
|
-
}, [
|
|
149
|
+
await D(e);
|
|
150
|
+
}, [D]);
|
|
151
151
|
if (H) return null;
|
|
152
|
-
let $ = !!(
|
|
153
|
-
return /* @__PURE__ */
|
|
154
|
-
className:
|
|
155
|
-
children: [
|
|
152
|
+
let $ = !!(O && M.trim() && !G && K.length === 0);
|
|
153
|
+
return /* @__PURE__ */ h("div", {
|
|
154
|
+
className: g("flex flex-wrap items-center gap-1.5", le),
|
|
155
|
+
children: [T.map((e) => /* @__PURE__ */ m(ae, {
|
|
156
156
|
id: e.id,
|
|
157
157
|
label: e.label,
|
|
158
158
|
color: e.color ?? void 0,
|
|
@@ -161,79 +161,79 @@ function C({ entityType: h, entityId: C, workspaceId: le, tags: w, onAdd: T, onR
|
|
|
161
161
|
removable: !0,
|
|
162
162
|
onRemove: () => void he(e.id),
|
|
163
163
|
size: "sm"
|
|
164
|
-
}, e.id)), U && /* @__PURE__ */
|
|
164
|
+
}, e.id)), U && /* @__PURE__ */ h(d, {
|
|
165
165
|
open: ue,
|
|
166
166
|
onOpenChange: j,
|
|
167
|
-
children: [/* @__PURE__ */
|
|
167
|
+
children: [/* @__PURE__ */ h(p, {
|
|
168
168
|
type: "button",
|
|
169
169
|
"aria-label": A("projectTagsWidget.addTagAriaLabel", "Add tag"),
|
|
170
|
-
className:
|
|
171
|
-
children: [/* @__PURE__ */
|
|
172
|
-
}), /* @__PURE__ */
|
|
170
|
+
className: g("inline-flex items-center gap-1 px-2 py-0.5 rounded-full border border-dashed", "border-border-subtle text-text-secondary text-xs", "hover:border-foreground hover:text-text-primary transition-colors", "focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-[var(--color-focus-ring)]"),
|
|
171
|
+
children: [/* @__PURE__ */ m(te, { className: "size-3" }), /* @__PURE__ */ m("span", { children: T.length > 0 ? A("projectTagsWidget.add", "Add") : A("projectTagsWidget.addTags", "Add tags") })]
|
|
172
|
+
}), /* @__PURE__ */ m(f, {
|
|
173
173
|
className: "z-50 w-72 max-w-[calc(100vw-2rem)] border-border-subtle/80 bg-popover p-0 shadow-xl",
|
|
174
174
|
align: "start",
|
|
175
175
|
side: "bottom",
|
|
176
176
|
sideOffset: 8,
|
|
177
|
-
children: /* @__PURE__ */
|
|
177
|
+
children: /* @__PURE__ */ h(o, {
|
|
178
178
|
shouldFilter: !1,
|
|
179
179
|
children: [
|
|
180
|
-
/* @__PURE__ */
|
|
180
|
+
/* @__PURE__ */ h("div", {
|
|
181
181
|
className: "relative",
|
|
182
|
-
children: [/* @__PURE__ */
|
|
182
|
+
children: [/* @__PURE__ */ m(re, {
|
|
183
183
|
placeholder: A("projectTagsWidget.searchPlaceholder", "Search or create a tag..."),
|
|
184
184
|
value: M,
|
|
185
185
|
onValueChange: pe,
|
|
186
186
|
className: "h-10 border-0 bg-transparent pr-9 text-sm outline-none placeholder:text-text-secondary"
|
|
187
|
-
}), G && /* @__PURE__ */
|
|
187
|
+
}), G && /* @__PURE__ */ m(a, { className: "absolute right-3 top-1/2 size-3.5 -translate-y-1/2 animate-spin text-text-secondary" })]
|
|
188
188
|
}),
|
|
189
|
-
/* @__PURE__ */
|
|
189
|
+
/* @__PURE__ */ h(u, {
|
|
190
190
|
className: "max-h-48 overflow-y-auto",
|
|
191
191
|
children: [
|
|
192
|
-
M.trim() === "" && /* @__PURE__ */
|
|
192
|
+
M.trim() === "" && /* @__PURE__ */ m(s, {
|
|
193
193
|
className: "py-4 text-center text-xs text-text-secondary",
|
|
194
194
|
children: A("projectTagsWidget.typeToSearch", "Type to search or create a tag")
|
|
195
195
|
}),
|
|
196
|
-
K.length > 0 && /* @__PURE__ */
|
|
196
|
+
K.length > 0 && /* @__PURE__ */ m(c, { children: K.map((e) => /* @__PURE__ */ h(l, {
|
|
197
197
|
value: e.id,
|
|
198
198
|
onSelect: () => void Q(e),
|
|
199
199
|
className: "flex items-center gap-2 px-3 py-2 cursor-pointer",
|
|
200
200
|
disabled: I,
|
|
201
201
|
children: [
|
|
202
|
-
e.icon && /* @__PURE__ */
|
|
202
|
+
e.icon && /* @__PURE__ */ m("span", {
|
|
203
203
|
className: "text-sm",
|
|
204
204
|
children: e.icon
|
|
205
205
|
}),
|
|
206
|
-
/* @__PURE__ */
|
|
206
|
+
/* @__PURE__ */ m("span", {
|
|
207
207
|
className: "truncate text-sm",
|
|
208
208
|
style: e.color ? { color: e.color } : void 0,
|
|
209
209
|
children: e.label
|
|
210
210
|
}),
|
|
211
|
-
I && /* @__PURE__ */
|
|
211
|
+
I && /* @__PURE__ */ m(a, { className: "ml-auto size-3 animate-spin" })
|
|
212
212
|
]
|
|
213
213
|
}, e.id)) }),
|
|
214
|
-
$ && /* @__PURE__ */
|
|
214
|
+
$ && /* @__PURE__ */ m(c, { children: /* @__PURE__ */ h(l, {
|
|
215
215
|
value: `__create__${M}`,
|
|
216
216
|
onSelect: () => void me(),
|
|
217
217
|
className: "flex items-center gap-2 px-3 py-2 cursor-pointer text-primary",
|
|
218
218
|
disabled: J,
|
|
219
|
-
children: [J ? /* @__PURE__ */
|
|
219
|
+
children: [J ? /* @__PURE__ */ m(a, { className: "size-3.5 animate-spin" }) : /* @__PURE__ */ m(ee, { className: "size-3.5" }), /* @__PURE__ */ m("span", {
|
|
220
220
|
className: "text-sm truncate",
|
|
221
221
|
children: J ? A("projectTagsWidget.creating", "Creating...") : A("projectTagsWidget.create", "Create \"{{label}}\"", { label: M })
|
|
222
222
|
})]
|
|
223
223
|
}) }),
|
|
224
|
-
M.trim() !== "" && !G && K.length === 0 && !$ && /* @__PURE__ */
|
|
224
|
+
M.trim() !== "" && !G && K.length === 0 && !$ && /* @__PURE__ */ m(s, {
|
|
225
225
|
className: "py-4 text-center text-xs text-text-secondary",
|
|
226
226
|
children: A("projectTagsWidget.noTagsFound", "No tags found")
|
|
227
227
|
}),
|
|
228
|
-
P && /* @__PURE__ */
|
|
228
|
+
P && /* @__PURE__ */ m("div", {
|
|
229
229
|
className: "px-3 py-2 text-xs text-status-error-text border-t border-border-subtle",
|
|
230
230
|
children: P
|
|
231
231
|
})
|
|
232
232
|
]
|
|
233
233
|
}),
|
|
234
|
-
!U && /* @__PURE__ */
|
|
234
|
+
!U && /* @__PURE__ */ h("div", {
|
|
235
235
|
className: "border-t border-border-subtle px-3 py-2 text-xs text-text-secondary flex items-center gap-1",
|
|
236
|
-
children: [/* @__PURE__ */
|
|
236
|
+
children: [/* @__PURE__ */ m(ne, { className: "size-3" }), A("projectTagsWidget.maxTagsReached", "Maximum {{maxTags}} tags reached", { maxTags: k })]
|
|
237
237
|
})
|
|
238
238
|
]
|
|
239
239
|
})
|
|
@@ -241,4 +241,4 @@ function C({ entityType: h, entityId: C, workspaceId: le, tags: w, onAdd: T, onR
|
|
|
241
241
|
})]
|
|
242
242
|
});
|
|
243
243
|
}
|
|
244
|
-
export {
|
|
244
|
+
export { w as ProjectTagsWidget };
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { useTr as e } from "../../hooks/useTr.js";
|
|
2
2
|
import { GetWorkspaceTagsDocument as t, ReplaceWorkspaceTagsDocument as n } from "../../generated/wspace-operations.js";
|
|
3
3
|
import { useLayoutEffect as r, useMemo as i, useRef as a, useState as o } from "react";
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
4
|
+
import { Button as s } from "@burdenoff/fe-libs/ui";
|
|
5
|
+
import { jsx as c, jsxs as l } from "react/jsx-runtime";
|
|
6
6
|
import { TagsWidget as u } from "@burdenoff/fe-libs/tag";
|
|
7
7
|
import { NetworkStatus as d } from "@apollo/client";
|
|
8
8
|
import { useMutation as f, useQuery as p } from "@apollo/client/react";
|
|
@@ -91,15 +91,15 @@ function g({ workspaceId: g }) {
|
|
|
91
91
|
}
|
|
92
92
|
}
|
|
93
93
|
}
|
|
94
|
-
return /* @__PURE__ */
|
|
94
|
+
return /* @__PURE__ */ l("div", {
|
|
95
95
|
className: "space-y-3",
|
|
96
|
-
children: [!A && /* @__PURE__ */
|
|
96
|
+
children: [!A && /* @__PURE__ */ l("div", {
|
|
97
97
|
role: "status",
|
|
98
98
|
className: "space-y-2 text-sm text-text-muted",
|
|
99
99
|
children: [
|
|
100
|
-
/* @__PURE__ */
|
|
101
|
-
D && !k && /* @__PURE__ */
|
|
102
|
-
/* @__PURE__ */ s
|
|
100
|
+
/* @__PURE__ */ c("p", { children: b ? _("workspaceSettings.tagsUncertain", "The tag update could not be verified. Read again before making changes.") : v.loading || S ? _("workspaceSettings.tagsVerifying", "Verifying workspace tags. Editing is unavailable.") : _("workspaceSettings.tagsUnverified", "Some workspace tags could not be verified. Known tags are shown; editing is unavailable.") }),
|
|
101
|
+
D && !k && /* @__PURE__ */ c("p", { children: _("workspaceSettings.tagsUnavailableCount", "{{count}} known assignment(s) have unavailable tag details.", { count: E.length - O.length }) }),
|
|
102
|
+
/* @__PURE__ */ c(s, {
|
|
103
103
|
type: "button",
|
|
104
104
|
variant: "outline",
|
|
105
105
|
disabled: v.loading || S,
|
|
@@ -107,12 +107,12 @@ function g({ workspaceId: g }) {
|
|
|
107
107
|
children: _("workspaceSettings.tagsRetryRead", "Retry read")
|
|
108
108
|
})
|
|
109
109
|
]
|
|
110
|
-
}), /* @__PURE__ */
|
|
110
|
+
}), /* @__PURE__ */ c("fieldset", {
|
|
111
111
|
disabled: !A,
|
|
112
112
|
inert: !A,
|
|
113
113
|
"aria-label": _("workspaceSettings.tagsFieldset", "Workspace tags"),
|
|
114
114
|
className: "min-w-0",
|
|
115
|
-
children: /* @__PURE__ */
|
|
115
|
+
children: /* @__PURE__ */ c(u, {
|
|
116
116
|
entityType: "Workspace",
|
|
117
117
|
entityId: g,
|
|
118
118
|
workspaceId: g,
|
package/dist/index.d.ts
CHANGED
|
@@ -26,10 +26,10 @@ export { DashboardPage } from './pages/dashboard/DashboardPage';
|
|
|
26
26
|
export { InviteAcceptancePage } from './pages/InviteAcceptancePage';
|
|
27
27
|
export { PendingInvitesPage } from './pages/PendingInvitesPage';
|
|
28
28
|
export { WorkspaceInvitePage } from './pages/WorkspaceInvitePage';
|
|
29
|
-
export { WorkspacesProvider, useWorkspacesContext } from './providers/WorkspacesProvider';
|
|
29
|
+
export { WorkspacesProvider, useWorkspacesContext, useIsFluidGridsVariant, } from './providers/WorkspacesProvider';
|
|
30
30
|
export { useWorkspacesStore } from './store/workspacesStore';
|
|
31
31
|
export * from './hooks';
|
|
32
32
|
export * from './components';
|
|
33
33
|
export * from './utils';
|
|
34
34
|
export { enTranslations } from './translations/en';
|
|
35
|
-
export type { WorkspacesRootProps, Workspace, WorkspaceType, WorkspaceStatus, WorkspaceMember, WorkspaceRole, WorkspaceSettings, WorkspaceFeature, WorkspaceIntegration, Project, ProjectStatus, Activity, ActivityType, WorkspaceFilters, ProjectFilters, ViewMode, SortBy, SortDirection, CreateWorkspaceInput, UpdateWorkspaceInput, CreateProjectInput, UpdateProjectInput, NavItem, FooterItem, } from './types';
|
|
35
|
+
export type { WorkspacesRootProps, WorkspacesVariant, Workspace, WorkspaceType, WorkspaceStatus, WorkspaceMember, WorkspaceRole, WorkspaceSettings, WorkspaceFeature, WorkspaceIntegration, Project, ProjectStatus, Activity, ActivityType, WorkspaceFilters, ProjectFilters, ViewMode, SortBy, SortDirection, CreateWorkspaceInput, UpdateWorkspaceInput, CreateProjectInput, UpdateProjectInput, NavItem, FooterItem, } from './types';
|
package/dist/index.js
CHANGED
|
@@ -10,19 +10,20 @@ import { PendingInvitesPage as v } from "./pages/PendingInvitesPage.js";
|
|
|
10
10
|
import { useInfiniteWorkspaceMembers as y, useInvitation as b, useUserWorkspaces as x, useWorkspaceInvitations as S, useWorkspaceMember as C, useWorkspaceMembers as w } from "./hooks/useWorkspaceMembers.js";
|
|
11
11
|
import { useAcceptInvitation as T, useAddWorkspaceMember as E, useBulkCreateInvitations as D, useCancelInvitation as O, useCreateInvitation as k, useDeleteInvitation as A, useRejectInvitation as j, useRemoveUserFromWorkspace as M, useRemoveWorkspaceMember as N, useResendInvitation as P, useUpdateInvitation as F } from "./hooks/useMemberMutations.js";
|
|
12
12
|
import { WorkspaceInvitePage as I } from "./pages/WorkspaceInvitePage.js";
|
|
13
|
-
import { WorkspacesProvider as L,
|
|
14
|
-
import { useMyProjects as
|
|
15
|
-
import { useWorkspacesStore as
|
|
16
|
-
import { useArchiveWorkspace as
|
|
17
|
-
import { useArchiveProject as
|
|
18
|
-
import { useMyOrganizations as
|
|
13
|
+
import { WorkspacesProvider as L, useIsFluidGridsVariant as R, useWorkspacesContext as z } from "./providers/WorkspacesProvider.js";
|
|
14
|
+
import { useMyProjects as B, useProject as V, useProjectMembersCount as H, useProjects as U } from "./hooks/useProjects.js";
|
|
15
|
+
import { useWorkspacesStore as W } from "./store/workspacesStore.js";
|
|
16
|
+
import { useArchiveWorkspace as G, useCreateWorkspace as K, useDeleteWorkspace as q, useReactivateWorkspace as J, useUpdateWorkspace as Y } from "./hooks/useWorkspaceMutations.js";
|
|
17
|
+
import { useArchiveProject as X, useCreateProject as Z, useDeleteProject as Q, useTagProject as $, useUnarchiveProject as ee, useUntagProject as te, useUpdateProject as ne } from "./hooks/useProjectMutations.js";
|
|
18
|
+
import { useMyOrganizations as re, useMyTenants as ie } from "./hooks/useTenants.js";
|
|
19
19
|
import "./hooks/index.js";
|
|
20
|
-
import { CreateWorkspaceDialog as
|
|
21
|
-
import { formatDate as
|
|
22
|
-
import { ProjectCard as
|
|
23
|
-
import {
|
|
24
|
-
import {
|
|
25
|
-
import {
|
|
20
|
+
import { CreateWorkspaceDialog as ae } from "./components/CreateWorkspaceDialog.js";
|
|
21
|
+
import { formatDate as oe, formatDateTime as se, formatFileSize as ce, formatProjectStatus as le, formatRelativeTime as ue, formatWorkspaceStatus as de, getInitials as fe, toTitleCase as pe, truncate as me } from "./utils/formatters.js";
|
|
22
|
+
import { ProjectCard as he } from "./components/ProjectCard.js";
|
|
23
|
+
import { buildCreateProjectInput as ge, buildCreateWorkspaceInput as _e, generateProjectKey as ve } from "./utils/createForms.js";
|
|
24
|
+
import { CreateProjectDialog as ye } from "./components/CreateProjectDialog.js";
|
|
25
|
+
import { MemberListItem as be } from "./components/MemberListItem.js";
|
|
26
|
+
import { InviteMemberDialog as xe } from "./components/InviteMemberDialog.js";
|
|
26
27
|
import "./components/index.js";
|
|
27
|
-
import { enTranslations as
|
|
28
|
-
export {
|
|
28
|
+
import { enTranslations as Se } from "./translations/en.js";
|
|
29
|
+
export { ye as CreateProjectDialog, ae as CreateWorkspaceDialog, n as DashboardPage, _ as InviteAcceptancePage, xe as InviteMemberDialog, be as MemberListItem, v as PendingInvitesPage, he as ProjectCard, g as WorkspaceCard, I as WorkspaceInvitePage, t as WorkspacesErrorBoundary, L as WorkspacesProvider, e as WorkspacesRoot, ge as buildCreateProjectInput, _e as buildCreateWorkspaceInput, Se as enTranslations, oe as formatDate, se as formatDateTime, ce as formatFileSize, le as formatProjectStatus, ue as formatRelativeTime, de as formatWorkspaceStatus, ve as generateProjectKey, fe as getInitials, s as getMemberRoleClasses, c as getMemberRoleLabel, l as getProjectStatusClasses, u as getProjectStatusIconClass, d as getProjectStatusLabel, f as getWorkspaceStatusBgClass, p as getWorkspaceStatusClasses, m as getWorkspaceStatusIconClass, h as getWorkspaceStatusLabel, pe as toTitleCase, me as truncate, T as useAcceptInvitation, E as useAddWorkspaceMember, X as useArchiveProject, G as useArchiveWorkspace, D as useBulkCreateInvitations, O as useCancelInvitation, k as useCreateInvitation, Z as useCreateProject, K as useCreateWorkspace, A as useDeleteInvitation, Q as useDeleteProject, q as useDeleteWorkspace, y as useInfiniteWorkspaceMembers, b as useInvitation, R as useIsFluidGridsVariant, re as useMyOrganizations, o as useMyPendingInvitations, B as useMyProjects, ie as useMyTenants, r as useMyWorkspaces, V as useProject, H as useProjectMembersCount, U as useProjects, J as useReactivateWorkspace, j as useRejectInvitation, M as useRemoveUserFromWorkspace, N as useRemoveWorkspaceMember, P as useResendInvitation, $ as useTagProject, ee as useUnarchiveProject, te as useUntagProject, F as useUpdateInvitation, ne as useUpdateProject, Y as useUpdateWorkspace, x as useUserWorkspaces, i as useWorkspace, S as useWorkspaceInvitations, C as useWorkspaceMember, w as useWorkspaceMembers, a as useWorkspaces, z as useWorkspacesContext, W as useWorkspacesStore };
|