@burdenoff/microfe-workspaces 2026.1201.1 → 2026.1202.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.
|
@@ -13,13 +13,8 @@ var p = {
|
|
|
13
13
|
ARCHIVED: "bg-text-tertiary"
|
|
14
14
|
};
|
|
15
15
|
function m({ workspaceData: m, isLoading: h, navigate: g }) {
|
|
16
|
-
let { t: _ } = f(), v = m?.workspaces.items ?? [], y = m?.workspaces.total ?? 0, {
|
|
17
|
-
n({
|
|
18
|
-
setOrganization: b,
|
|
19
|
-
setWorkspace: x,
|
|
20
|
-
setProject: S,
|
|
21
|
-
setTenant: C
|
|
22
|
-
}, e), g(`/workspaces/${e.id}`);
|
|
16
|
+
let { t: _ } = f(), v = m?.workspaces.items ?? [], y = m?.workspaces.total ?? 0, { setContext: b } = l(), x = (e) => {
|
|
17
|
+
n({ setContext: b }, e), g(`/workspaces/${e.id}`);
|
|
23
18
|
};
|
|
24
19
|
return /* @__PURE__ */ u(e, {
|
|
25
20
|
title: t(_, "dashboard.workspaces.title", "Workspaces"),
|
|
@@ -55,7 +50,7 @@ function m({ workspaceData: m, isLoading: h, navigate: g }) {
|
|
|
55
50
|
children: [v.slice(0, 5).map((e) => /* @__PURE__ */ d("button", {
|
|
56
51
|
type: "button",
|
|
57
52
|
className: "w-full flex items-center justify-between p-2 rounded-md hover:bg-accent/5 cursor-pointer transition-colors text-left",
|
|
58
|
-
onClick: () =>
|
|
53
|
+
onClick: () => x(e),
|
|
59
54
|
children: [/* @__PURE__ */ d("div", {
|
|
60
55
|
className: "flex items-center gap-2 min-w-0",
|
|
61
56
|
children: [/* @__PURE__ */ u(a, { className: `size-2 ${p[e.status] || "bg-text-tertiary"} fill-current ${e.status === "ACTIVE" ? "motion-safe:animate-vc-glow-pulse" : ""}` }), /* @__PURE__ */ u("span", {
|
|
@@ -137,45 +137,35 @@ function Y({ onCreate: e, only: t = !1 }) {
|
|
|
137
137
|
});
|
|
138
138
|
}
|
|
139
139
|
function X({ onCreate: t, canCreate: n }) {
|
|
140
|
-
let a = c(), o = B(), { basePath: l = "/workspaces", workspaceId: u } = e(), { withCurrentSearch: f } = s(), m = i(), {
|
|
141
|
-
setOrganization: h,
|
|
142
|
-
setWorkspace: g,
|
|
143
|
-
setProject: _,
|
|
144
|
-
setTenant: v
|
|
145
|
-
}, e), [
|
|
146
|
-
h,
|
|
147
|
-
_,
|
|
148
|
-
v,
|
|
149
|
-
g
|
|
150
|
-
]);
|
|
140
|
+
let a = c(), o = B(), { basePath: l = "/workspaces", workspaceId: u } = e(), { withCurrentSearch: f } = s(), m = i(), { setContext: h } = F(), { permissions: g } = I(), [_] = p(() => /* @__PURE__ */ new Date()), { list: v, searching: y, source: b, count: x, items: S } = J(), C = n ? t : void 0, D = d((e) => r({ setContext: h }, e), [h]);
|
|
151
141
|
return /* @__PURE__ */ R(E, {
|
|
152
|
-
list:
|
|
153
|
-
count:
|
|
154
|
-
loading:
|
|
155
|
-
error:
|
|
156
|
-
onRetry: () => void
|
|
142
|
+
list: v,
|
|
143
|
+
count: x,
|
|
144
|
+
loading: b.isPending && !b.data,
|
|
145
|
+
error: b.error,
|
|
146
|
+
onRetry: () => void b.refetch(),
|
|
157
147
|
errorTitle: a("workspacePagesV2.workspaces.loadFailed", "Couldn’t load your workspaces"),
|
|
158
|
-
errorDetails:
|
|
159
|
-
summary:
|
|
148
|
+
errorDetails: b.error?.message,
|
|
149
|
+
summary: x === 1 ? a("workspacePagesV2.workspaces.countOne", "1 workspace") : a("workspacePagesV2.workspaces.count", "{{count}} workspaces", { count: x }),
|
|
160
150
|
toolbar: /* @__PURE__ */ L(T, {
|
|
161
|
-
list:
|
|
151
|
+
list: v,
|
|
162
152
|
searchPlaceholder: a("workspacePagesV2.workspaces.search", "Search workspaces")
|
|
163
153
|
}),
|
|
164
154
|
pager: /* @__PURE__ */ L(w, {
|
|
165
|
-
list:
|
|
166
|
-
total:
|
|
155
|
+
list: v,
|
|
156
|
+
total: x
|
|
167
157
|
}),
|
|
168
|
-
empty: /* @__PURE__ */ L(Y, { onCreate:
|
|
169
|
-
children: [/* @__PURE__ */ L(k, { children:
|
|
158
|
+
empty: /* @__PURE__ */ L(Y, { onCreate: C }),
|
|
159
|
+
children: [/* @__PURE__ */ L(k, { children: S.map((e) => /* @__PURE__ */ L(q, {
|
|
170
160
|
workspace: e,
|
|
171
161
|
current: e.id === u,
|
|
172
|
-
yourRole:
|
|
173
|
-
now:
|
|
162
|
+
yourRole: g?.roles?.[0] ?? null,
|
|
163
|
+
now: _,
|
|
174
164
|
onOpen: () => m(e),
|
|
175
|
-
onSwitch: () =>
|
|
165
|
+
onSwitch: () => D(e),
|
|
176
166
|
onSettings: () => o(f(`${l}/${e.id}/settings`))
|
|
177
|
-
}, e.id)) }),
|
|
178
|
-
onCreate:
|
|
167
|
+
}, e.id)) }), x === 1 && !y ? /* @__PURE__ */ L(Y, {
|
|
168
|
+
onCreate: C,
|
|
179
169
|
only: !0
|
|
180
170
|
}) : null]
|
|
181
171
|
});
|