@realiizlabs/admin 0.7.2 → 0.8.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.
@@ -0,0 +1,583 @@
1
+ "use client";
2
+ import { useState, useEffect, useRef } from 'react';
3
+ import { jsxs, jsx } from 'react/jsx-runtime';
4
+
5
+ // src/shell/Sidebar.tsx
6
+ var base = {
7
+ width: 18,
8
+ height: 18,
9
+ viewBox: "0 0 24 24",
10
+ fill: "none",
11
+ stroke: "currentColor",
12
+ strokeWidth: 1.7,
13
+ strokeLinecap: "round",
14
+ strokeLinejoin: "round",
15
+ "aria-hidden": true,
16
+ style: { flexShrink: 0 }
17
+ };
18
+ function Icon({ name }) {
19
+ switch (name) {
20
+ case "home":
21
+ return /* @__PURE__ */ jsxs("svg", { ...base, children: [
22
+ /* @__PURE__ */ jsx("rect", { x: "3", y: "3", width: "7", height: "9", rx: "1" }),
23
+ /* @__PURE__ */ jsx("rect", { x: "14", y: "3", width: "7", height: "5", rx: "1" }),
24
+ /* @__PURE__ */ jsx("rect", { x: "14", y: "12", width: "7", height: "9", rx: "1" }),
25
+ /* @__PURE__ */ jsx("rect", { x: "3", y: "16", width: "7", height: "5", rx: "1" })
26
+ ] });
27
+ case "posts":
28
+ return /* @__PURE__ */ jsxs("svg", { ...base, children: [
29
+ /* @__PURE__ */ jsx("path", { d: "M6 3h9l4 4v14H6z" }),
30
+ /* @__PURE__ */ jsx("path", { d: "M15 3v4h4" }),
31
+ /* @__PURE__ */ jsx("path", { d: "M9 12h7M9 16h7M9 8h3" })
32
+ ] });
33
+ case "events":
34
+ return /* @__PURE__ */ jsxs("svg", { ...base, children: [
35
+ /* @__PURE__ */ jsx("rect", { x: "3", y: "5", width: "18", height: "16", rx: "2" }),
36
+ /* @__PURE__ */ jsx("path", { d: "M8 3v4M16 3v4M3 10h18" })
37
+ ] });
38
+ case "venues":
39
+ return /* @__PURE__ */ jsxs("svg", { ...base, children: [
40
+ /* @__PURE__ */ jsx("path", { d: "M12 21s7-6.2 7-11.5A7 7 0 0 0 5 9.5C5 14.8 12 21 12 21z" }),
41
+ /* @__PURE__ */ jsx("circle", { cx: "12", cy: "9.5", r: "2.5" })
42
+ ] });
43
+ case "users":
44
+ return /* @__PURE__ */ jsxs("svg", { ...base, children: [
45
+ /* @__PURE__ */ jsx("circle", { cx: "9", cy: "8", r: "3.5" }),
46
+ /* @__PURE__ */ jsx("path", { d: "M2.5 20a6.5 6.5 0 0 1 13 0" }),
47
+ /* @__PURE__ */ jsx("circle", { cx: "17", cy: "9", r: "2.5" }),
48
+ /* @__PURE__ */ jsx("path", { d: "M15.5 14.5a5 5 0 0 1 6 5" })
49
+ ] });
50
+ case "settings":
51
+ return /* @__PURE__ */ jsxs("svg", { ...base, children: [
52
+ /* @__PURE__ */ jsx("circle", { cx: "12", cy: "12", r: "3" }),
53
+ /* @__PURE__ */ jsx("path", { d: "M19.4 15a1.7 1.7 0 0 0 .3 1.8l.1.1a2 2 0 1 1-2.8 2.8l-.1-.1a1.7 1.7 0 0 0-1.8-.3 1.7 1.7 0 0 0-1 1.5V21a2 2 0 1 1-4 0v-.1a1.7 1.7 0 0 0-1.1-1.5 1.7 1.7 0 0 0-1.8.3l-.1.1a2 2 0 1 1-2.8-2.8l.1-.1a1.7 1.7 0 0 0 .3-1.8 1.7 1.7 0 0 0-1.5-1H3a2 2 0 1 1 0-4h.1a1.7 1.7 0 0 0 1.5-1.1 1.7 1.7 0 0 0-.3-1.8l-.1-.1a2 2 0 1 1 2.8-2.8l.1.1a1.7 1.7 0 0 0 1.8.3H9a1.7 1.7 0 0 0 1-1.5V3a2 2 0 1 1 4 0v.1a1.7 1.7 0 0 0 1 1.5 1.7 1.7 0 0 0 1.8-.3l.1-.1a2 2 0 1 1 2.8 2.8l-.1.1a1.7 1.7 0 0 0-.3 1.8V9a1.7 1.7 0 0 0 1.5 1H21a2 2 0 1 1 0 4h-.1a1.7 1.7 0 0 0-1.5 1z" })
54
+ ] });
55
+ default:
56
+ return /* @__PURE__ */ jsxs("svg", { ...base, children: [
57
+ /* @__PURE__ */ jsx("path", { d: "M6 3h9l4 4v14H6z" }),
58
+ /* @__PURE__ */ jsx("path", { d: "M15 3v4h4" })
59
+ ] });
60
+ }
61
+ }
62
+ function iconFor(id) {
63
+ const known = ["home", "posts", "events", "venues", "users", "settings"];
64
+ return known.includes(id) ? id : "doc";
65
+ }
66
+ var SIDEBAR_KEY = "rz-admin-sidebar";
67
+ function isActive(item, activeHref, basePath) {
68
+ if (item.href === basePath) return activeHref === basePath || activeHref === `${basePath}/`;
69
+ return activeHref === item.href || activeHref.startsWith(`${item.href}/`);
70
+ }
71
+ function Sidebar({ items, activeHref, basePath }) {
72
+ const [collapsed, setCollapsed] = useState(false);
73
+ useEffect(() => {
74
+ try {
75
+ if (window.localStorage.getItem(SIDEBAR_KEY) === "collapsed") setCollapsed(true);
76
+ } catch {
77
+ }
78
+ }, []);
79
+ const toggle = () => {
80
+ const next = !collapsed;
81
+ setCollapsed(next);
82
+ try {
83
+ window.localStorage.setItem(SIDEBAR_KEY, next ? "collapsed" : "open");
84
+ } catch {
85
+ }
86
+ };
87
+ return /* @__PURE__ */ jsxs("aside", { className: ["rz-sidebar", collapsed && "rz-sidebar--collapsed"].filter(Boolean).join(" "), "aria-label": "Admin navigation", children: [
88
+ /* @__PURE__ */ jsx("nav", { className: "rz-sidebar__nav", children: items.map((item) => {
89
+ const active = !item.disabled && isActive(item, activeHref, basePath);
90
+ if (item.disabled) {
91
+ return /* @__PURE__ */ jsxs("span", { className: "rz-sidebar__item rz-sidebar__item--disabled", "aria-disabled": "true", title: collapsed ? `${item.label} \u2014 coming soon` : "Coming soon", children: [
92
+ /* @__PURE__ */ jsx(Icon, { name: iconFor(item.icon ?? item.id) }),
93
+ /* @__PURE__ */ jsx("span", { className: "rz-sidebar__label", children: item.label })
94
+ ] }, item.id);
95
+ }
96
+ return /* @__PURE__ */ jsxs(
97
+ "a",
98
+ {
99
+ href: item.href,
100
+ className: ["rz-sidebar__item", active && "rz-sidebar__item--active"].filter(Boolean).join(" "),
101
+ "aria-current": active ? "page" : void 0,
102
+ title: collapsed ? item.label : void 0,
103
+ children: [
104
+ /* @__PURE__ */ jsx(Icon, { name: iconFor(item.icon ?? item.id) }),
105
+ /* @__PURE__ */ jsx("span", { className: "rz-sidebar__label", children: item.label })
106
+ ]
107
+ },
108
+ item.id
109
+ );
110
+ }) }),
111
+ /* @__PURE__ */ jsxs(
112
+ "button",
113
+ {
114
+ type: "button",
115
+ className: "rz-sidebar__collapse",
116
+ onClick: toggle,
117
+ "aria-label": collapsed ? "Expand navigation" : "Collapse navigation",
118
+ title: collapsed ? "Expand" : "Collapse",
119
+ children: [
120
+ /* @__PURE__ */ jsx("svg", { width: "18", height: "18", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "1.7", strokeLinecap: "round", strokeLinejoin: "round", "aria-hidden": "true", style: { transform: collapsed ? "rotate(180deg)" : void 0 }, children: /* @__PURE__ */ jsx("path", { d: "M15 6l-6 6 6 6" }) }),
121
+ /* @__PURE__ */ jsx("span", { className: "rz-sidebar__label", children: "Collapse" })
122
+ ]
123
+ }
124
+ )
125
+ ] });
126
+ }
127
+ var THEME_KEY = "rz-admin-theme";
128
+ function useTheme(defaultTheme = "light") {
129
+ const [theme, setTheme] = useState(defaultTheme);
130
+ useEffect(() => {
131
+ try {
132
+ const stored = window.localStorage.getItem(THEME_KEY);
133
+ if (stored === "light" || stored === "dark") setTheme(stored);
134
+ } catch {
135
+ }
136
+ }, []);
137
+ const set = (t) => {
138
+ setTheme(t);
139
+ try {
140
+ window.localStorage.setItem(THEME_KEY, t);
141
+ } catch {
142
+ }
143
+ };
144
+ return [theme, set];
145
+ }
146
+ function ThemeToggle({ theme, onChange }) {
147
+ return /* @__PURE__ */ jsxs("span", { className: "rz-seg", role: "group", "aria-label": "Theme", children: [
148
+ /* @__PURE__ */ jsx("button", { type: "button", "aria-pressed": theme === "light", onClick: () => onChange("light"), children: "Light" }),
149
+ /* @__PURE__ */ jsx("button", { type: "button", "aria-pressed": theme === "dark", onClick: () => onChange("dark"), children: "Dark" })
150
+ ] });
151
+ }
152
+ function firstNameOf(user) {
153
+ const fromName = user.name?.trim().split(/\s+/)[0];
154
+ if (fromName) return fromName;
155
+ const local = user.email.split("@")[0] ?? "";
156
+ return local ? local.charAt(0).toUpperCase() + local.slice(1) : "there";
157
+ }
158
+ function initialsOf(user) {
159
+ const parts = user.name?.trim().split(/\s+/).filter(Boolean) ?? [];
160
+ if (parts.length >= 2) return (parts[0][0] + parts[parts.length - 1][0]).toUpperCase();
161
+ if (parts.length === 1) return parts[0].slice(0, 2).toUpperCase();
162
+ return (user.email[0] ?? "?").toUpperCase();
163
+ }
164
+ var ico = { width: 14, height: 14, viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: 2, strokeLinecap: "round", strokeLinejoin: "round", "aria-hidden": true };
165
+ var ShieldIcon = () => /* @__PURE__ */ jsx("svg", { ...ico, children: /* @__PURE__ */ jsx("path", { d: "M12 3l7 3v5c0 5-3.5 8.5-7 10-3.5-1.5-7-5-7-10V6z" }) });
166
+ var SunIcon = () => /* @__PURE__ */ jsxs("svg", { ...ico, children: [
167
+ /* @__PURE__ */ jsx("circle", { cx: "12", cy: "12", r: "4" }),
168
+ /* @__PURE__ */ jsx("path", { d: "M12 2v2M12 20v2M4.9 4.9l1.4 1.4M17.7 17.7l1.4 1.4M2 12h2M20 12h2M4.9 19.1l1.4-1.4M17.7 6.3l1.4-1.4" })
169
+ ] });
170
+ var OutIcon = () => /* @__PURE__ */ jsxs("svg", { ...ico, children: [
171
+ /* @__PURE__ */ jsx("path", { d: "M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4" }),
172
+ /* @__PURE__ */ jsx("path", { d: "M16 17l5-5-5-5" }),
173
+ /* @__PURE__ */ jsx("path", { d: "M21 12H9" })
174
+ ] });
175
+ function AccountMenu({ user, role, theme, onTheme, signOutPath }) {
176
+ const [open, setOpen] = useState(false);
177
+ const wrap = useRef(null);
178
+ useEffect(() => {
179
+ if (!open) return;
180
+ const onClick = (e) => {
181
+ if (!wrap.current?.contains(e.target)) setOpen(false);
182
+ };
183
+ const onKey = (e) => {
184
+ if (e.key === "Escape") setOpen(false);
185
+ };
186
+ document.addEventListener("mousedown", onClick);
187
+ document.addEventListener("keydown", onKey);
188
+ return () => {
189
+ document.removeEventListener("mousedown", onClick);
190
+ document.removeEventListener("keydown", onKey);
191
+ };
192
+ }, [open]);
193
+ return /* @__PURE__ */ jsxs("div", { ref: wrap, style: { position: "relative" }, children: [
194
+ /* @__PURE__ */ jsx("button", { type: "button", className: "rz-avatar", "aria-haspopup": "menu", "aria-expanded": open, "aria-label": "Account menu", onClick: () => setOpen((v) => !v), children: initialsOf(user) }),
195
+ open && /* @__PURE__ */ jsxs("div", { className: "rz-menu", role: "menu", children: [
196
+ /* @__PURE__ */ jsxs("div", { className: "rz-menu__who", children: [
197
+ /* @__PURE__ */ jsx("div", { className: "rz-menu__name", children: user.name?.trim() || user.email }),
198
+ user.name?.trim() && /* @__PURE__ */ jsx("div", { className: "rz-menu__email", children: user.email })
199
+ ] }),
200
+ /* @__PURE__ */ jsxs("div", { className: "rz-menu__item rz-menu__item--static", role: "menuitem", "aria-disabled": "true", children: [
201
+ /* @__PURE__ */ jsx(ShieldIcon, {}),
202
+ /* @__PURE__ */ jsx("span", { children: "Role" }),
203
+ /* @__PURE__ */ jsx("span", { className: "rz-menu__end rz-pill rz-pill--plain", children: role })
204
+ ] }),
205
+ /* @__PURE__ */ jsxs("div", { className: "rz-menu__item rz-menu__item--static", role: "menuitem", "aria-disabled": "true", children: [
206
+ /* @__PURE__ */ jsx(SunIcon, {}),
207
+ /* @__PURE__ */ jsx("span", { children: "Theme" }),
208
+ /* @__PURE__ */ jsx("span", { className: "rz-menu__end", children: /* @__PURE__ */ jsx(ThemeToggle, { theme, onChange: onTheme }) })
209
+ ] }),
210
+ /* @__PURE__ */ jsx("div", { className: "rz-menu__sep" }),
211
+ /* @__PURE__ */ jsx("form", { method: "post", action: signOutPath, className: "rz-menu__signout", children: /* @__PURE__ */ jsxs("button", { type: "submit", role: "menuitem", className: "rz-menu__item", children: [
212
+ /* @__PURE__ */ jsx(OutIcon, {}),
213
+ "Sign out"
214
+ ] }) })
215
+ ] })
216
+ ] });
217
+ }
218
+ function TopBar({ siteName, productName, logoUrl, homeHref, user, role, theme, onTheme, signOutPath }) {
219
+ return /* @__PURE__ */ jsxs("header", { className: "rz-topbar", children: [
220
+ /* @__PURE__ */ jsxs("a", { href: homeHref, className: "rz-topbar__brand", children: [
221
+ logoUrl && /* @__PURE__ */ jsx("img", { src: logoUrl, alt: "", className: "rz-topbar__logo" }),
222
+ /* @__PURE__ */ jsx("span", { children: siteName }),
223
+ /* @__PURE__ */ jsx("span", { className: "rz-topbar__product", children: productName })
224
+ ] }),
225
+ user && role && /* @__PURE__ */ jsxs("div", { className: "rz-topbar__right", children: [
226
+ /* @__PURE__ */ jsxs("span", { className: "rz-topbar__greeting", "data-testid": "rz-greeting", children: [
227
+ "Welcome back, ",
228
+ firstNameOf(user)
229
+ ] }),
230
+ /* @__PURE__ */ jsx(AccountMenu, { user, role, theme, onTheme, signOutPath })
231
+ ] })
232
+ ] });
233
+ }
234
+
235
+ // src/shell/tokens.ts
236
+ var SHELL_CSS = `
237
+ .rz-admin, .rz-admin[data-theme="light"] {
238
+ /* realiiz.com palette (src/app/globals.css): ink, bone, paper, signal blue, slate, line, amber */
239
+ --ink: #0e1726; --bone: #f7f5f0; --signal: #1f6feb;
240
+ --surface-0: #f7f5f0; --surface-1: #ffffff; --surface-2: #f1eee7; --surface-3: #e8e4da;
241
+ --text-primary: #0e1726; --text-secondary: #5b6678; --text-muted: #8a93a5;
242
+ --signal-dim: #1a63d8; --signal-glow: #5b9bff; --signal-warn: #e0a03b; --series-blue: #1f6feb;
243
+ --border: #d9d4c8; --separator: #e9e5dc;
244
+ --status-up: #15803d; --status-down: #dc2626; --status-neutral: var(--text-muted); --status-blocked: var(--border);
245
+ --signal-fg: #ffffff;
246
+ }
247
+ .rz-admin[data-theme="dark"] { color-scheme: dark; }
248
+ .rz-admin[data-theme="dark"] {
249
+ --ink: #eef0f5; --bone: #1b2334; --signal: #3b82f6;
250
+ --surface-0: #1b2334; --surface-1: #222c42; --surface-2: #29344a; --surface-3: #36415c;
251
+ --text-primary: #eef0f5; --text-secondary: #a2abbf; --text-muted: #77819a;
252
+ --signal-dim: #8db4ff; --signal-glow: #aec9ff; --signal-warn: #eab058; --series-blue: #3b82f6;
253
+ --border: #36415c; --separator: #2c3750;
254
+ --status-up: #4ade80; --status-down: #f87171; --status-neutral: var(--text-muted); --status-blocked: var(--border);
255
+ --signal-fg: #ffffff;
256
+ }
257
+ .rz-admin {
258
+ --rz-font: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
259
+ --rz-font-display: var(--rz-font);
260
+ --rz-font-mono: ui-monospace, SFMono-Regular, Menlo, monospace;
261
+ --rz-radius: 6px;
262
+ --rz-sidebar: 220px; --rz-sidebar-collapsed: 58px; --rz-topbar: 52px;
263
+
264
+ /* forms-ui speaks these; map them once so both packages agree */
265
+ --realiiz-form-fg: var(--text-primary); --realiiz-form-muted: var(--text-muted);
266
+ --realiiz-form-border: var(--border); --realiiz-form-accent: var(--signal);
267
+ --realiiz-form-accent-fg: var(--signal-fg); --realiiz-form-danger: var(--status-down);
268
+ --realiiz-form-radius: var(--rz-radius); --realiiz-form-font: var(--rz-font);
269
+ --realiiz-form-focus-ring: 0 0 0 3px color-mix(in srgb, var(--signal) 25%, transparent);
270
+
271
+ box-sizing: border-box; min-height: 100vh; display: flex; flex-direction: column;
272
+ background: var(--surface-0); color: var(--text-primary);
273
+ font-family: var(--rz-font); font-size: 14px; line-height: 1.45;
274
+ }
275
+ .rz-admin *, .rz-admin *::before, .rz-admin *::after { box-sizing: inherit; }
276
+ .rz-admin a { color: inherit; }
277
+ .rz-admin h1, .rz-admin h2, .rz-admin h3 { font-family: var(--rz-font-display); color: var(--text-primary); margin: 0; }
278
+ .rz-admin .realiiz-form__control { background: var(--surface-0); }
279
+ .rz-admin[data-theme="dark"] .realiiz-form__control::-webkit-calendar-picker-indicator { filter: invert(1) opacity(.7); }
280
+ .rz-admin .realiiz-form__button { background: var(--surface-1); color: var(--text-primary); }
281
+ .rz-admin .realiiz-form__button--primary { background: var(--signal); color: var(--signal-fg); }
282
+
283
+ /* ---- frame ---------------------------------------------------------- */
284
+ .rz-topbar { height: var(--rz-topbar); display: flex; align-items: center; gap: 1rem; padding: 0 1.25rem; border-bottom: 1px solid var(--border); background: var(--surface-1); flex-shrink: 0; }
285
+ .rz-topbar__brand { display: flex; align-items: center; gap: .6rem; font-weight: 600; font-size: .9375rem; text-decoration: none; }
286
+ .rz-topbar__logo { height: 22px; width: auto; display: block; }
287
+ .rz-topbar__product { font-weight: 400; color: var(--text-secondary); }
288
+ .rz-topbar__right { margin-left: auto; display: flex; align-items: center; gap: 1rem; }
289
+ .rz-topbar__greeting { color: var(--text-secondary); font-size: .8rem; }
290
+ .rz-body { display: flex; flex: 1; min-height: 0; }
291
+ /* Top bar and sidebar stay put while the content scrolls, so Collapse is always at the bottom-left. */
292
+ .rz-topbar { position: sticky; top: 0; z-index: 20; }
293
+ .rz-sidebar { position: sticky; top: var(--rz-topbar); height: calc(100vh - var(--rz-topbar)); width: var(--rz-sidebar); flex-shrink: 0; border-right: 1px solid var(--border); background: var(--surface-1); display: flex; flex-direction: column; transition: width .15s ease; overflow: hidden; }
294
+ .rz-sidebar--collapsed { width: var(--rz-sidebar-collapsed); }
295
+ .rz-sidebar__nav { padding: .75rem 0; flex: 1; overflow-y: auto; }
296
+ .rz-sidebar__item { display: flex; align-items: center; gap: .65rem; padding: .55rem 1rem; color: var(--text-secondary); text-decoration: none; font-size: .875rem; font-weight: 400; white-space: nowrap; overflow: hidden; }
297
+ .rz-sidebar__item:hover { background: var(--surface-2); color: var(--text-primary); }
298
+ .rz-sidebar__item--active { background: var(--surface-2); color: var(--signal); font-weight: 500; }
299
+ .rz-sidebar__item--disabled, .rz-sidebar__item--disabled:hover { color: var(--text-muted); opacity: .55; background: transparent; cursor: default; }
300
+ .rz-sidebar--collapsed .rz-sidebar__item { justify-content: center; padding: .55rem 0; }
301
+ .rz-sidebar--collapsed .rz-sidebar__label { display: none; }
302
+ .rz-sidebar__collapse { display: flex; align-items: center; gap: .7rem; padding: .6rem 1rem; border: 0; border-top: 1px solid var(--separator); background: transparent; color: var(--text-muted); cursor: pointer; font: inherit; font-size: .8rem; text-align: left; }
303
+ .rz-sidebar__collapse:hover { color: var(--text-primary); }
304
+ .rz-sidebar__collapse svg { flex-shrink: 0; }
305
+ .rz-sidebar--collapsed .rz-sidebar__collapse { justify-content: center; padding: .6rem 0; }
306
+ .rz-main { flex: 1; min-width: 0; }
307
+ .rz-content { max-width: 1400px; margin: 0; padding: 28px 32px 80px; }
308
+ .rz-content .realiiz-form { max-width: none; }
309
+ .rz-content .realiiz-form fieldset, .rz-content .realiiz-form__alert, .rz-content .realiiz-form__actions { max-width: 920px; }
310
+ /* The form's save bar pins to the bottom of the content column: bleed out over .rz-content's padding, then pad back in. */
311
+ .rz-content .realiiz-form__bar { position: sticky; bottom: 0; z-index: 10; margin: 24px -32px -80px; padding: 12px 32px; background: var(--surface-1); border-top: 1px solid var(--border); box-shadow: 0 -6px 16px rgba(14,23,38,.05); }
312
+ .rz-content .realiiz-form__status { color: var(--text-muted); }
313
+ .rz-content .realiiz-form__bar[data-dirty] .realiiz-form__status { color: var(--text-primary); font-weight: 500; }
314
+
315
+ /* ---- primitives ----------------------------------------------------- */
316
+ /* Same metrics as the form's Save button (.realiiz-form__button) so every button in the admin matches. */
317
+ .rz-btn { font-family: inherit; font-weight: 600; border-radius: var(--rz-radius); cursor: pointer; text-decoration: none; display: inline-flex; align-items: center; justify-content: center; gap: .4rem; white-space: nowrap; line-height: 1.2; }
318
+ .rz-btn--md { padding: 10px 16px; font-size: 15px; min-height: 40px; }
319
+ .rz-btn--sm { padding: 6px 12px; font-size: 13px; min-height: 32px; }
320
+ .rz-admin .rz-btn--primary, .rz-admin a.rz-btn--primary { background: var(--signal); color: var(--signal-fg); border: 1px solid var(--signal); }
321
+ .rz-admin .rz-btn--secondary, .rz-admin a.rz-btn--secondary { background: var(--surface-1); color: var(--text-primary); border: 1px solid var(--border); }
322
+ .rz-admin .rz-btn--danger, .rz-admin a.rz-btn--danger { background: transparent; color: var(--status-down); border: 1px solid var(--status-down); }
323
+ .rz-admin .rz-btn--ghost, .rz-admin a.rz-btn--ghost { background: var(--surface-1); color: var(--text-primary); border: 1px solid var(--border); }
324
+ .rz-admin .rz-btn:disabled { opacity: .55; cursor: default; }
325
+ .rz-arrow { width: 1.1em; height: 1.1em; flex-shrink: 0; transition: transform .15s ease-out; }
326
+ @media (prefers-reduced-motion: no-preference) {
327
+ .rz-btn:hover .rz-arrow, a:hover .rz-arrow { transform: translate(2px, -2px); }
328
+ .rz-btn:hover .rz-arrow--fwd, a:hover .rz-arrow--fwd { transform: translateX(4px); }
329
+ }
330
+ .rz-card { background: var(--surface-1); border: 1px solid var(--border); border-radius: 8px; padding: 18px 20px; }
331
+ .rz-card--narrow { max-width: 760px; }
332
+ .rz-card__title { font-size: .9375rem; font-weight: 600; margin-bottom: .35rem; }
333
+ .rz-card__meta { color: var(--text-muted); font-size: .8rem; }
334
+ .rz-card__actions { display: flex; gap: .5rem; margin-top: .9rem; flex-wrap: wrap; }
335
+ .rz-grid { display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }
336
+ .rz-pagehead { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 20px; flex-wrap: wrap; }
337
+ .rz-pagehead__eyebrow { font-family: var(--rz-font-mono); font-size: .6875rem; text-transform: uppercase; letter-spacing: .08em; color: var(--text-muted); margin-bottom: .3rem; }
338
+ .rz-pagehead h1 { font-size: 1.375rem; font-weight: 600; }
339
+ .rz-pagehead__sub { color: var(--text-secondary); font-size: .85rem; margin-top: .25rem; }
340
+ .rz-pill { display: inline-flex; align-items: center; gap: .4rem; white-space: nowrap; font-family: var(--rz-font-mono); font-size: .6875rem; text-transform: uppercase; letter-spacing: .06em; padding: .15rem .5rem; border: 1px solid var(--border); border-radius: 999px; color: var(--text-secondary); }
341
+ .rz-pill::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--status-neutral); }
342
+ .rz-pill--up::before { background: var(--status-up); } .rz-pill--warn::before { background: var(--signal-warn); } .rz-pill--down::before { background: var(--status-down); }
343
+ .rz-pill--plain::before { display: none; }
344
+ /* ---- steps tracker ------------------------------------------------- */
345
+ /* Dots on one rail, connectors dot-to-dot, label under each dot; left-aligned like the rest of the page. */
346
+ .rz-steps { list-style: none; margin: 4px 0 22px; padding: 0 0 22px; display: flex; border-bottom: 1px solid var(--separator); }
347
+ .rz-step { flex: 1; position: relative; display: flex; flex-direction: column; align-items: flex-start; text-align: left; gap: 8px; min-width: 0; }
348
+ .rz-step:last-child { flex: 0 0 auto; }
349
+ .rz-step:not(:last-child)::after { content: ""; position: absolute; top: 12px; left: 26px; right: 0; height: 2px; background: var(--border); }
350
+ .rz-step--done:not(:last-child)::after { background: var(--status-up); }
351
+ .rz-step__dot { width: 26px; height: 26px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-size: .75rem; font-weight: 600; flex-shrink: 0; border: 2px solid var(--border); color: var(--text-muted); background: var(--surface-1); }
352
+ .rz-step--done .rz-step__dot { background: var(--status-up); border-color: var(--status-up); color: #fff; }
353
+ .rz-step--active .rz-step__dot { position: relative; border-color: color-mix(in srgb, var(--signal) 30%, transparent); color: var(--signal); }
354
+ /* A spinning arc over the ring: the step is working, not waiting on you. */
355
+ .rz-step--active .rz-step__dot::after { content: ""; position: absolute; inset: -2px; border-radius: 50%; border: 2px solid transparent; border-top-color: var(--signal); animation: rz-spin .9s linear infinite; }
356
+ @media (prefers-reduced-motion: reduce) { .rz-step--active .rz-step__dot::after { animation: none; border-color: var(--signal); } }
357
+ @keyframes rz-spin { to { transform: rotate(360deg); } }
358
+ .rz-step--failed .rz-step__dot { background: var(--status-down); border-color: var(--status-down); color: #fff; }
359
+ .rz-step__text { display: flex; flex-direction: column; gap: 1px; padding-right: 16px; }
360
+ .rz-step__label { font-size: .875rem; font-weight: 500; color: var(--text-secondary); }
361
+ .rz-step--active .rz-step__label, .rz-step--done .rz-step__label { color: var(--text-primary); }
362
+ .rz-step--failed .rz-step__label { color: var(--status-down); }
363
+ .rz-step__note { font-size: .75rem; color: var(--text-muted); }
364
+ @keyframes rz-pulse { 0%, 100% { box-shadow: 0 0 0 3px color-mix(in srgb, var(--signal) 18%, transparent); } 50% { box-shadow: 0 0 0 6px color-mix(in srgb, var(--signal) 8%, transparent); } }
365
+ .rz-actions { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 20px; }
366
+ .rz-actions__hint { font-size: .8rem; color: var(--text-muted); }
367
+ .rz-notice { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 12px 16px; border: 1px solid var(--border); border-radius: 8px; background: var(--surface-1); margin-bottom: 18px; font-size: .9rem; }
368
+ .rz-notice__text { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
369
+ .rz-status-link { text-decoration: none; }
370
+ .rz-discard { margin-top: 22px; padding-top: 14px; border-top: 1px solid var(--separator); display: flex; align-items: center; gap: 10px; flex-wrap: wrap; font-size: .85rem; color: var(--text-secondary); }
371
+ .rz-discard__link { background: none; border: 0; padding: 0; font: inherit; font-size: .85rem; color: var(--text-muted); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
372
+ .rz-discard__link:hover { color: var(--status-down); }
373
+ .rz-nowrap { white-space: nowrap; }
374
+ .rz-table td.rz-fit, .rz-table th.rz-fit { width: 1%; white-space: nowrap; }
375
+ .rz-empty { border: 1px dashed var(--border); border-radius: 8px; padding: 32px; text-align: center; color: var(--text-secondary); }
376
+ .rz-empty h3 { font-size: 1rem; margin-bottom: .4rem; }
377
+ .rz-table-wrap { width: 100%; }
378
+ .rz-table { width: 100%; border-collapse: collapse; background: var(--surface-1); border: 1px solid var(--border); border-radius: 8px; overflow: hidden; }
379
+ .rz-table th, .rz-table td { text-align: left; padding: 10px 14px; border-bottom: 1px solid var(--separator); font-size: .875rem; vertical-align: top; }
380
+ .rz-table th { font-family: var(--rz-font-mono); font-size: .6875rem; text-transform: uppercase; letter-spacing: .06em; color: var(--text-muted); background: var(--surface-2); }
381
+ .rz-table tr:last-child td { border-bottom: 0; }
382
+ .rz-muted { color: var(--text-muted); }
383
+ .rz-alert { border: 1px solid var(--status-down); color: var(--status-down); border-radius: var(--rz-radius); padding: 12px 14px; margin: 0 0 16px; }
384
+ .rz-ok { border: 1px solid var(--status-up); color: var(--signal-dim); border-radius: var(--rz-radius); padding: 12px 14px; margin: 0 0 16px; }
385
+
386
+ /* ---- account menu --------------------------------------------------- */
387
+ .rz-avatar { width: 2rem; height: 2rem; border-radius: 50%; background: var(--surface-3); border: 1px solid var(--border); color: var(--text-primary); font-size: .6875rem; font-weight: 600; letter-spacing: .04em; display: flex; align-items: center; justify-content: center; cursor: pointer; font-family: inherit; padding: 0; }
388
+ .rz-menu { position: absolute; right: 0; top: calc(100% + 8px); min-width: 15rem; background: var(--surface-1); border: 1px solid var(--border); border-radius: 8px; box-shadow: 0 8px 24px rgba(14,23,38,.14); overflow: hidden; z-index: 50; }
389
+ .rz-menu__who { padding: .75rem .9rem; border-bottom: 1px solid var(--border); margin-bottom: .3rem; }
390
+ .rz-menu__name { font-weight: 600; font-size: .875rem; }
391
+ .rz-menu__email { color: var(--text-muted); font-size: .75rem; word-break: break-all; }
392
+ .rz-menu__sep { height: 1px; background: var(--border); margin: .3rem 0; }
393
+ .rz-menu__item { display: flex; align-items: center; gap: .55rem; width: 100%; padding: .45rem .9rem; font: inherit; font-size: .8125rem; color: var(--text-secondary); background: none; border: 0; text-align: left; cursor: pointer; text-decoration: none; }
394
+ .rz-menu__item:hover { background: var(--surface-2); color: var(--text-primary); }
395
+ .rz-menu__item svg { flex-shrink: 0; }
396
+ .rz-menu__item--static { cursor: default; }
397
+ .rz-menu__item--static:hover { background: none; color: var(--text-secondary); }
398
+ .rz-menu__item .rz-menu__end { margin-left: auto; }
399
+ .rz-menu__signout { margin: 0 0 .3rem; }
400
+ .rz-seg { display: inline-flex; border: 1px solid var(--border); border-radius: var(--rz-radius); overflow: hidden; }
401
+ .rz-seg button { font: inherit; font-size: .75rem; padding: .15rem .55rem; line-height: 1.3; background: transparent; color: var(--text-secondary); border: 0; cursor: pointer; }
402
+ .rz-seg button[aria-pressed="true"] { background: var(--surface-3); color: var(--text-primary); }
403
+
404
+ /* ---- mobile: sidebar becomes a strip under the top bar --------------- */
405
+ @media (max-width: 720px) {
406
+ .rz-body { flex-direction: column; }
407
+ .rz-sidebar, .rz-sidebar--collapsed { width: 100%; border-right: 0; border-bottom: 1px solid var(--border); flex-direction: row; }
408
+ .rz-sidebar__nav { display: flex; padding: .35rem .25rem; overflow-x: auto; }
409
+ .rz-sidebar__item { flex-direction: column; gap: .2rem; font-size: .6875rem; padding: .4rem .6rem; border-radius: 6px; }
410
+ .rz-sidebar--collapsed .rz-sidebar__label { display: block; }
411
+ .rz-sidebar__collapse { display: none; }
412
+ .rz-topbar__greeting { display: none; }
413
+ .rz-content { padding: 18px 14px 60px; }
414
+ /* The sidebar is a top strip now, so it must not be sticky-height; the topbar stays pinned. */
415
+ .rz-sidebar, .rz-sidebar--collapsed { position: static; height: auto; }
416
+ .rz-sidebar__item--disabled { display: none; }
417
+ /* Save bar: bleed matches the narrower content padding; stack status above the buttons. */
418
+ .rz-content .realiiz-form__bar { margin: 18px -14px -60px; padding: 10px 14px; flex-wrap: wrap; }
419
+ .rz-content .realiiz-form__status { flex-basis: 100%; margin-right: 0; font-size: .8rem; }
420
+ /* Editor toolbar wraps; the Insert group drops its label and left rule to save width. */
421
+ .rz-admin .realiiz-md__head { padding: 5px; }
422
+ .rz-admin .realiiz-md__insert { border-left: 0; padding-left: 0; margin-left: 0; }
423
+ .rz-admin .realiiz-md__lab { display: none; }
424
+ .rz-admin .realiiz-md--fs { padding: 8px; }
425
+ /* Tracker: notes hide, labels shrink, so three steps fit a phone. */
426
+ .rz-step__note { display: none; }
427
+ .rz-step__label { font-size: .8rem; }
428
+ .rz-step:not(:last-child)::after { right: 6px; }
429
+ /* Tables scroll sideways inside their own box instead of stretching the page. */
430
+ .rz-table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
431
+ .rz-pagehead { align-items: flex-start; flex-direction: column; }
432
+ .rz-notice { flex-direction: column; align-items: flex-start; }
433
+ .rz-card--narrow { max-width: none; }
434
+ }
435
+
436
+ /* ---- forms extras: markdown editor, chips, gauges, preview prose --------- */
437
+ .rz-admin .realiiz-md { --_md-head: var(--surface-2); --_md-hover: var(--surface-2); --_md-hover-line: var(--signal-glow); --_md-on: color-mix(in srgb, var(--signal) 12%, var(--surface-1)); --_md-tip: var(--ink); }
438
+ .rz-admin .realiiz-md__mode { background: var(--surface-2); }
439
+ .rz-admin .realiiz-md__mode button { color: var(--text-secondary); }
440
+ .rz-admin .realiiz-md__mode button[aria-selected="true"] { background: var(--surface-1); color: var(--text-primary); box-shadow: 0 1px 2px rgba(14,23,38,.12); }
441
+ .rz-admin .realiiz-md__panel, .rz-admin .realiiz-md__tgrid, .rz-admin .realiiz-md--fs, .rz-admin .realiiz-md .realiiz-md__ta, .rz-admin .realiiz-md__preview, .rz-admin .realiiz-md__head button { background: var(--surface-1); }
442
+ .rz-admin .realiiz-md__head { background: var(--surface-2); }
443
+ .rz-admin .realiiz-md__head button { color: var(--text-primary); }
444
+ .rz-admin .realiiz-md__insert button { background: var(--surface-2); color: var(--text-secondary); }
445
+ .rz-admin .realiiz-md__tgcells i { background: var(--surface-1); }
446
+ .rz-admin .realiiz-md__tgcells i.hot { background: color-mix(in srgb, var(--signal) 18%, var(--surface-1)); }
447
+ .rz-admin .realiiz-md__loading { color: var(--text-muted); font-size: .8rem; }
448
+ .rz-admin .realiiz-prose { max-width: 68ch; font-size: 1rem; line-height: 1.65; color: var(--text-primary); }
449
+ .rz-admin .realiiz-prose h1, .rz-admin .realiiz-prose h2, .rz-admin .realiiz-prose h3 { font-family: var(--rz-font-display); line-height: 1.25; margin: 1.4em 0 .5em; }
450
+ .rz-admin .realiiz-prose h2 { font-size: 1.35rem; } .rz-admin .realiiz-prose h3 { font-size: 1.1rem; }
451
+ .rz-admin .realiiz-prose p, .rz-admin .realiiz-prose ul, .rz-admin .realiiz-prose ol, .rz-admin .realiiz-prose blockquote { margin: 0 0 1em; }
452
+ .rz-admin .realiiz-prose a { color: var(--signal); }
453
+ /* The site's prose class picks a slate body colour for a light page; on the dark surface that reads as disabled. */
454
+ .rz-admin[data-theme="dark"] .realiiz-prose, .rz-admin[data-theme="dark"] .realiiz-prose :is(p, li, td, th, dd, dt, figcaption, strong, b, em, i, h1, h2, h3, h4, h5, h6) { color: var(--text-primary); }
455
+ .rz-admin[data-theme="dark"] .realiiz-prose :is(code, kbd) { color: var(--text-primary); background: var(--surface-3); }
456
+ .rz-admin[data-theme="dark"] .realiiz-prose a { color: var(--signal-dim); }
457
+ .rz-admin[data-theme="dark"] .realiiz-prose hr { border-color: var(--border); }
458
+ .rz-admin[data-theme="dark"] .realiiz-prose blockquote { color: var(--text-secondary); }
459
+ .rz-admin .realiiz-prose blockquote { border-left: 3px solid var(--border); padding-left: 1em; color: var(--text-secondary); }
460
+ .rz-admin .realiiz-prose code { background: var(--surface-2); padding: 0 4px; border-radius: 4px; font-family: var(--rz-font-mono); font-size: .9em; }
461
+ .rz-admin .realiiz-prose pre { background: var(--surface-2); padding: 12px 14px; border-radius: 6px; overflow-x: auto; }
462
+ .rz-admin .realiiz-prose img { max-width: 100%; height: auto; border-radius: 6px; }
463
+ .rz-admin .realiiz-chips { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; min-height: 40px; padding: 5px 8px; background: var(--surface-0); border: 1px solid var(--border); border-radius: var(--rz-radius); }
464
+ .rz-admin .realiiz-chips:focus-within { border-color: var(--signal); box-shadow: var(--realiiz-form-focus-ring); }
465
+ .rz-admin .realiiz-chip { display: inline-flex; align-items: center; gap: 4px; padding: 2px 4px 2px 9px; background: var(--surface-3); border: 1px solid var(--border); border-radius: 999px; font-size: .8rem; color: var(--text-primary); }
466
+ .rz-admin .realiiz-chip button { font: inherit; line-height: 1; width: 18px; height: 18px; border-radius: 50%; border: 0; background: transparent; color: var(--text-muted); cursor: pointer; }
467
+ .rz-admin .realiiz-chip button:hover { background: var(--status-down); color: #fff; }
468
+ .rz-admin .realiiz-chips__input { flex: 1; min-width: 120px; border: 0; background: transparent; font: inherit; color: inherit; outline: none; padding: 4px; }
469
+ .rz-admin .realiiz-chips__count { margin-left: auto; color: var(--text-muted); font-size: .75rem; font-variant-numeric: tabular-nums; }
470
+ .rz-admin .realiiz-gauge { color: var(--text-muted); }
471
+ .rz-admin .realiiz-gauge__bar { background: var(--surface-3); }
472
+ .rz-admin .realiiz-gauge__zone { background: color-mix(in srgb, var(--status-up) 28%, transparent); }
473
+ .rz-admin .realiiz-gauge__fill { background: var(--text-muted); }
474
+ .rz-admin .realiiz-gauge--ok .realiiz-gauge__fill { background: var(--status-up); } .rz-admin .realiiz-gauge--ok { color: var(--status-up); }
475
+ .rz-admin .realiiz-gauge--over .realiiz-gauge__fill { background: var(--status-down); } .rz-admin .realiiz-gauge--over { color: var(--status-down); }
476
+ `;
477
+ function AdminShell({
478
+ siteName,
479
+ productName = "Studio",
480
+ logoUrl,
481
+ user,
482
+ role,
483
+ nav,
484
+ activeHref,
485
+ basePath = "/admin",
486
+ signOutPath,
487
+ defaultTheme = "light",
488
+ children
489
+ }) {
490
+ const [theme, setTheme] = useTheme(defaultTheme);
491
+ const showNav = Boolean(user && role);
492
+ return /* @__PURE__ */ jsxs("div", { className: "rz-admin", "data-theme": theme, children: [
493
+ /* @__PURE__ */ jsx("style", { children: SHELL_CSS }),
494
+ /* @__PURE__ */ jsx(
495
+ TopBar,
496
+ {
497
+ siteName,
498
+ productName,
499
+ logoUrl,
500
+ homeHref: basePath,
501
+ user,
502
+ role,
503
+ theme,
504
+ onTheme: setTheme,
505
+ signOutPath: signOutPath ?? `${basePath}/auth/signout`
506
+ }
507
+ ),
508
+ /* @__PURE__ */ jsxs("div", { className: "rz-body", children: [
509
+ showNav && /* @__PURE__ */ jsx(Sidebar, { items: nav, activeHref, basePath }),
510
+ /* @__PURE__ */ jsx("main", { className: "rz-main", children: /* @__PURE__ */ jsx("div", { className: "rz-content", children }) })
511
+ ] })
512
+ ] });
513
+ }
514
+ function buttonClass(variant = "secondary", size = "md", extra) {
515
+ return ["rz-btn", `rz-btn--${variant}`, `rz-btn--${size}`, extra].filter(Boolean).join(" ");
516
+ }
517
+ function buttonStyle(variant = "secondary", size = "md") {
518
+ return { className: buttonClass(variant, size) };
519
+ }
520
+ function Button({ variant = "secondary", size = "md", className, type = "button", ...rest }) {
521
+ return /* @__PURE__ */ jsx("button", { type, className: buttonClass(variant, size, className), ...rest });
522
+ }
523
+ function LinkButton({ variant = "secondary", size = "md", className, external, forward, children, ...rest }) {
524
+ const extra = external ? { target: "_blank", rel: "noreferrer", ...rest } : rest;
525
+ return /* @__PURE__ */ jsxs("a", { className: buttonClass(variant, size, className), ...extra, children: [
526
+ children,
527
+ external && /* @__PURE__ */ jsx(OutboundArrow, {}),
528
+ forward && !external && /* @__PURE__ */ jsx(ForwardArrow, {})
529
+ ] });
530
+ }
531
+ function ForwardArrow() {
532
+ return /* @__PURE__ */ jsxs("svg", { "aria-hidden": "true", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round", className: "rz-arrow rz-arrow--fwd", children: [
533
+ /* @__PURE__ */ jsx("path", { d: "M5 12h14" }),
534
+ /* @__PURE__ */ jsx("path", { d: "m13 6 6 6-6 6" })
535
+ ] });
536
+ }
537
+ function OutboundArrow() {
538
+ return /* @__PURE__ */ jsxs("svg", { "aria-hidden": "true", viewBox: "0 0 24 24", fill: "none", stroke: "currentColor", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round", className: "rz-arrow", children: [
539
+ /* @__PURE__ */ jsx("path", { d: "M7 17 17 7" }),
540
+ /* @__PURE__ */ jsx("path", { d: "M7 7h10v10" })
541
+ ] });
542
+ }
543
+ function Card({ title, meta, children, actions, className }) {
544
+ return /* @__PURE__ */ jsxs("div", { className: ["rz-card", className].filter(Boolean).join(" "), children: [
545
+ title && /* @__PURE__ */ jsx("div", { className: "rz-card__title", children: title }),
546
+ meta && /* @__PURE__ */ jsx("div", { className: "rz-card__meta", children: meta }),
547
+ children,
548
+ actions && /* @__PURE__ */ jsx("div", { className: "rz-card__actions", children: actions })
549
+ ] });
550
+ }
551
+ function PageHeader({ eyebrow, title, subtitle, actions }) {
552
+ return /* @__PURE__ */ jsxs("div", { className: "rz-pagehead", children: [
553
+ /* @__PURE__ */ jsxs("div", { children: [
554
+ eyebrow && /* @__PURE__ */ jsx("div", { className: "rz-pagehead__eyebrow", children: eyebrow }),
555
+ /* @__PURE__ */ jsx("h1", { children: title }),
556
+ subtitle && /* @__PURE__ */ jsx("div", { className: "rz-pagehead__sub", children: subtitle })
557
+ ] }),
558
+ actions && /* @__PURE__ */ jsx("div", { className: "rz-card__actions", style: { marginTop: 0 }, children: actions })
559
+ ] });
560
+ }
561
+ function StatusPill({ tone = "neutral", children, title }) {
562
+ return /* @__PURE__ */ jsx("span", { className: `rz-pill rz-pill--${tone}`, title, children });
563
+ }
564
+ function EmptyState({ title, children, action }) {
565
+ return /* @__PURE__ */ jsxs("div", { className: "rz-empty", children: [
566
+ /* @__PURE__ */ jsx("h3", { children: title }),
567
+ children && /* @__PURE__ */ jsx("div", { children }),
568
+ action && /* @__PURE__ */ jsx("div", { style: { marginTop: 14 }, children: action })
569
+ ] });
570
+ }
571
+ function Steps({ steps }) {
572
+ return /* @__PURE__ */ jsx("ol", { className: "rz-steps", "aria-label": "Progress", children: steps.map((st, i) => /* @__PURE__ */ jsxs("li", { className: `rz-step rz-step--${st.state}`, "aria-current": st.state === "active" ? "step" : void 0, children: [
573
+ /* @__PURE__ */ jsx("span", { className: "rz-step__dot", "aria-hidden": "true", children: st.state === "done" ? "\u2713" : st.state === "failed" ? "!" : i + 1 }),
574
+ /* @__PURE__ */ jsxs("span", { className: "rz-step__text", children: [
575
+ /* @__PURE__ */ jsx("span", { className: "rz-step__label", children: st.label }),
576
+ st.note && /* @__PURE__ */ jsx("span", { className: "rz-step__note", children: st.note })
577
+ ] })
578
+ ] }, i)) });
579
+ }
580
+
581
+ export { AccountMenu, AdminShell, Button, Card, EmptyState, ForwardArrow, Icon, LinkButton, OutboundArrow, PageHeader, SHELL_CSS, Sidebar, StatusPill, Steps, ThemeToggle, TopBar, buttonClass, buttonStyle, firstNameOf, iconFor, initialsOf, isActive, useTheme };
582
+ //# sourceMappingURL=index.js.map
583
+ //# sourceMappingURL=index.js.map