@stealthscale/component-navigation 0.3.0 → 0.3.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.
@@ -0,0 +1,698 @@
1
+ import { t as __exportAll } from "../../rolldown-runtime-D7D4PA-g.js";
2
+ import { a as recipe } from "../../recipes-BN0p1O6u.js";
3
+ import { A as Link, D as Trigger, F as Badge, I as Action, M as Indicator, N as Content, O as Root, P as Branch, j as Item, k as Mark } from "../../shared-Cz6A-cF-.js";
4
+ import { c } from "react/compiler-runtime";
5
+ import { jsx, jsxs } from "react/jsx-runtime";
6
+ import { Room, scenesOf, specimen, useWords } from "@stealthscale/specimen";
7
+ import { ChevronRightIcon, CreditCardIcon, FileTextIcon, LayoutDashboardIcon, PencilIcon, SettingsIcon, UsersIcon } from "lucide-react";
8
+ import { Avatar } from "@stealthscale/component-media";
9
+ //#region src/nav-list/examples/destinations.example.tsx
10
+ var destinations_example_exports = /* @__PURE__ */ __exportAll({
11
+ Destinations: () => Destinations,
12
+ source: () => source$2
13
+ });
14
+ function Destinations(props) {
15
+ const $ = c(26);
16
+ const { t } = useWords("nav-list");
17
+ let t0;
18
+ if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
19
+ t0 = /* @__PURE__ */ jsx(LayoutDashboardIcon, { "aria-hidden": true });
20
+ $[0] = t0;
21
+ } else t0 = $[0];
22
+ let t1;
23
+ if ($[1] !== t) {
24
+ t1 = t("overview");
25
+ $[1] = t;
26
+ $[2] = t1;
27
+ } else t1 = $[2];
28
+ let t2;
29
+ if ($[3] !== t1) {
30
+ t2 = /* @__PURE__ */ jsx(Item, { children: /* @__PURE__ */ jsxs(Link, {
31
+ "aria-current": "page",
32
+ href: "#overview",
33
+ children: [t0, /* @__PURE__ */ jsx("span", { children: t1 })]
34
+ }) });
35
+ $[3] = t1;
36
+ $[4] = t2;
37
+ } else t2 = $[4];
38
+ let t3;
39
+ if ($[5] === Symbol.for("react.memo_cache_sentinel")) {
40
+ t3 = /* @__PURE__ */ jsx(FileTextIcon, { "aria-hidden": true });
41
+ $[5] = t3;
42
+ } else t3 = $[5];
43
+ let t4;
44
+ if ($[6] !== t) {
45
+ t4 = t("invoices");
46
+ $[6] = t;
47
+ $[7] = t4;
48
+ } else t4 = $[7];
49
+ let t5;
50
+ if ($[8] !== t4) {
51
+ t5 = /* @__PURE__ */ jsx(Item, { children: /* @__PURE__ */ jsxs(Link, {
52
+ href: "#invoices",
53
+ children: [t3, /* @__PURE__ */ jsx("span", { children: t4 })]
54
+ }) });
55
+ $[8] = t4;
56
+ $[9] = t5;
57
+ } else t5 = $[9];
58
+ let t6;
59
+ if ($[10] === Symbol.for("react.memo_cache_sentinel")) {
60
+ t6 = /* @__PURE__ */ jsx(UsersIcon, { "aria-hidden": true });
61
+ $[10] = t6;
62
+ } else t6 = $[10];
63
+ let t7;
64
+ if ($[11] !== t) {
65
+ t7 = t("team");
66
+ $[11] = t;
67
+ $[12] = t7;
68
+ } else t7 = $[12];
69
+ let t8;
70
+ if ($[13] !== t7) {
71
+ t8 = /* @__PURE__ */ jsx(Item, { children: /* @__PURE__ */ jsxs(Link, {
72
+ href: "#team",
73
+ children: [t6, /* @__PURE__ */ jsx("span", { children: t7 })]
74
+ }) });
75
+ $[13] = t7;
76
+ $[14] = t8;
77
+ } else t8 = $[14];
78
+ let t9;
79
+ if ($[15] === Symbol.for("react.memo_cache_sentinel")) {
80
+ t9 = /* @__PURE__ */ jsx(CreditCardIcon, { "aria-hidden": true });
81
+ $[15] = t9;
82
+ } else t9 = $[15];
83
+ let t10;
84
+ if ($[16] !== t) {
85
+ t10 = t("billing");
86
+ $[16] = t;
87
+ $[17] = t10;
88
+ } else t10 = $[17];
89
+ let t11;
90
+ if ($[18] !== t10) {
91
+ t11 = /* @__PURE__ */ jsx(Item, { children: /* @__PURE__ */ jsxs(Link, {
92
+ href: "#billing",
93
+ children: [t9, /* @__PURE__ */ jsx("span", { children: t10 })]
94
+ }) });
95
+ $[18] = t10;
96
+ $[19] = t11;
97
+ } else t11 = $[19];
98
+ let t12;
99
+ if ($[20] !== props || $[21] !== t11 || $[22] !== t2 || $[23] !== t5 || $[24] !== t8) {
100
+ t12 = /* @__PURE__ */ jsxs(Root, {
101
+ ...props,
102
+ children: [
103
+ t2,
104
+ t5,
105
+ t8,
106
+ t11
107
+ ]
108
+ });
109
+ $[20] = props;
110
+ $[21] = t11;
111
+ $[22] = t2;
112
+ $[23] = t5;
113
+ $[24] = t8;
114
+ $[25] = t12;
115
+ } else t12 = $[25];
116
+ return t12;
117
+ }
118
+ const source$2 = "import { type ReactElement } from \"react\";\n\nimport { CreditCardIcon, FileTextIcon, LayoutDashboardIcon, UsersIcon } from \"lucide-react\";\n\nimport { useWords } from \"@stealthscale/specimen\";\n\nimport { NavList } from \"@stealthscale/component-navigation\";\n\nexport function Destinations(props: NavList.RootProps): ReactElement {\n const { t } = useWords(\"nav-list\");\n\n return (\n <NavList.Root {...props}>\n <NavList.Item>\n <NavList.Link aria-current=\"page\" href=\"#overview\">\n <LayoutDashboardIcon aria-hidden />\n <span>{t(\"overview\")}</span>\n </NavList.Link>\n </NavList.Item>\n <NavList.Item>\n <NavList.Link href=\"#invoices\">\n <FileTextIcon aria-hidden />\n <span>{t(\"invoices\")}</span>\n </NavList.Link>\n </NavList.Item>\n <NavList.Item>\n <NavList.Link href=\"#team\">\n <UsersIcon aria-hidden />\n <span>{t(\"team\")}</span>\n </NavList.Link>\n </NavList.Item>\n <NavList.Item>\n <NavList.Link href=\"#billing\">\n <CreditCardIcon aria-hidden />\n <span>{t(\"billing\")}</span>\n </NavList.Link>\n </NavList.Item>\n </NavList.Root>\n );\n}\n";
119
+ //#endregion
120
+ //#region src/nav-list/examples/renames.example.tsx
121
+ var renames_example_exports = /* @__PURE__ */ __exportAll({
122
+ Renames: () => Renames,
123
+ source: () => source$1
124
+ });
125
+ function Renames(props) {
126
+ const $ = c(58);
127
+ const { t } = useWords("nav-list");
128
+ let t0;
129
+ if ($[0] === Symbol.for("react.memo_cache_sentinel")) {
130
+ t0 = /* @__PURE__ */ jsx(LayoutDashboardIcon, { "aria-hidden": true });
131
+ $[0] = t0;
132
+ } else t0 = $[0];
133
+ let t1;
134
+ if ($[1] !== t) {
135
+ t1 = t("overview");
136
+ $[1] = t;
137
+ $[2] = t1;
138
+ } else t1 = $[2];
139
+ let t2;
140
+ if ($[3] !== t1) {
141
+ t2 = /* @__PURE__ */ jsxs(Link, {
142
+ "aria-current": "page",
143
+ href: "#overview",
144
+ children: [t0, /* @__PURE__ */ jsx("span", { children: t1 })]
145
+ });
146
+ $[3] = t1;
147
+ $[4] = t2;
148
+ } else t2 = $[4];
149
+ let t3;
150
+ if ($[5] !== t) {
151
+ t3 = t("rename", { name: t("overview") });
152
+ $[5] = t;
153
+ $[6] = t3;
154
+ } else t3 = $[6];
155
+ let t4;
156
+ if ($[7] === Symbol.for("react.memo_cache_sentinel")) {
157
+ t4 = /* @__PURE__ */ jsx(PencilIcon, {
158
+ "aria-hidden": true,
159
+ size: "1em"
160
+ });
161
+ $[7] = t4;
162
+ } else t4 = $[7];
163
+ let t5;
164
+ if ($[8] !== t3) {
165
+ t5 = /* @__PURE__ */ jsx(Action, {
166
+ "aria-label": t3,
167
+ children: t4
168
+ });
169
+ $[8] = t3;
170
+ $[9] = t5;
171
+ } else t5 = $[9];
172
+ let t6;
173
+ if ($[10] !== t2 || $[11] !== t5) {
174
+ t6 = /* @__PURE__ */ jsxs(Item, { children: [t2, t5] });
175
+ $[10] = t2;
176
+ $[11] = t5;
177
+ $[12] = t6;
178
+ } else t6 = $[12];
179
+ let t7;
180
+ if ($[13] === Symbol.for("react.memo_cache_sentinel")) {
181
+ t7 = /* @__PURE__ */ jsx(FileTextIcon, { "aria-hidden": true });
182
+ $[13] = t7;
183
+ } else t7 = $[13];
184
+ let t8;
185
+ if ($[14] !== t) {
186
+ t8 = t("invoices");
187
+ $[14] = t;
188
+ $[15] = t8;
189
+ } else t8 = $[15];
190
+ let t9;
191
+ if ($[16] !== t8) {
192
+ t9 = /* @__PURE__ */ jsxs(Link, {
193
+ href: "#invoices",
194
+ children: [t7, /* @__PURE__ */ jsx("span", { children: t8 })]
195
+ });
196
+ $[16] = t8;
197
+ $[17] = t9;
198
+ } else t9 = $[17];
199
+ let t10;
200
+ if ($[18] !== t) {
201
+ t10 = t("rename", { name: t("invoices") });
202
+ $[18] = t;
203
+ $[19] = t10;
204
+ } else t10 = $[19];
205
+ let t11;
206
+ if ($[20] === Symbol.for("react.memo_cache_sentinel")) {
207
+ t11 = /* @__PURE__ */ jsx(PencilIcon, {
208
+ "aria-hidden": true,
209
+ size: "1em"
210
+ });
211
+ $[20] = t11;
212
+ } else t11 = $[20];
213
+ let t12;
214
+ if ($[21] !== t10) {
215
+ t12 = /* @__PURE__ */ jsx(Action, {
216
+ "aria-label": t10,
217
+ children: t11
218
+ });
219
+ $[21] = t10;
220
+ $[22] = t12;
221
+ } else t12 = $[22];
222
+ let t13;
223
+ if ($[23] !== t12 || $[24] !== t9) {
224
+ t13 = /* @__PURE__ */ jsxs(Item, { children: [t9, t12] });
225
+ $[23] = t12;
226
+ $[24] = t9;
227
+ $[25] = t13;
228
+ } else t13 = $[25];
229
+ let t14;
230
+ if ($[26] === Symbol.for("react.memo_cache_sentinel")) {
231
+ t14 = /* @__PURE__ */ jsx(UsersIcon, { "aria-hidden": true });
232
+ $[26] = t14;
233
+ } else t14 = $[26];
234
+ let t15;
235
+ if ($[27] !== t) {
236
+ t15 = t("team");
237
+ $[27] = t;
238
+ $[28] = t15;
239
+ } else t15 = $[28];
240
+ let t16;
241
+ if ($[29] !== t15) {
242
+ t16 = /* @__PURE__ */ jsxs(Link, {
243
+ href: "#team",
244
+ children: [t14, /* @__PURE__ */ jsx("span", { children: t15 })]
245
+ });
246
+ $[29] = t15;
247
+ $[30] = t16;
248
+ } else t16 = $[30];
249
+ let t17;
250
+ if ($[31] !== t) {
251
+ t17 = t("rename", { name: t("team") });
252
+ $[31] = t;
253
+ $[32] = t17;
254
+ } else t17 = $[32];
255
+ let t18;
256
+ if ($[33] === Symbol.for("react.memo_cache_sentinel")) {
257
+ t18 = /* @__PURE__ */ jsx(PencilIcon, {
258
+ "aria-hidden": true,
259
+ size: "1em"
260
+ });
261
+ $[33] = t18;
262
+ } else t18 = $[33];
263
+ let t19;
264
+ if ($[34] !== t17) {
265
+ t19 = /* @__PURE__ */ jsx(Action, {
266
+ "aria-label": t17,
267
+ children: t18
268
+ });
269
+ $[34] = t17;
270
+ $[35] = t19;
271
+ } else t19 = $[35];
272
+ let t20;
273
+ if ($[36] !== t16 || $[37] !== t19) {
274
+ t20 = /* @__PURE__ */ jsxs(Item, { children: [t16, t19] });
275
+ $[36] = t16;
276
+ $[37] = t19;
277
+ $[38] = t20;
278
+ } else t20 = $[38];
279
+ let t21;
280
+ if ($[39] === Symbol.for("react.memo_cache_sentinel")) {
281
+ t21 = /* @__PURE__ */ jsx(CreditCardIcon, { "aria-hidden": true });
282
+ $[39] = t21;
283
+ } else t21 = $[39];
284
+ let t22;
285
+ if ($[40] !== t) {
286
+ t22 = t("billing");
287
+ $[40] = t;
288
+ $[41] = t22;
289
+ } else t22 = $[41];
290
+ let t23;
291
+ if ($[42] !== t22) {
292
+ t23 = /* @__PURE__ */ jsxs(Link, {
293
+ href: "#billing",
294
+ children: [t21, /* @__PURE__ */ jsx("span", { children: t22 })]
295
+ });
296
+ $[42] = t22;
297
+ $[43] = t23;
298
+ } else t23 = $[43];
299
+ let t24;
300
+ if ($[44] !== t) {
301
+ t24 = t("rename", { name: t("billing") });
302
+ $[44] = t;
303
+ $[45] = t24;
304
+ } else t24 = $[45];
305
+ let t25;
306
+ if ($[46] === Symbol.for("react.memo_cache_sentinel")) {
307
+ t25 = /* @__PURE__ */ jsx(PencilIcon, {
308
+ "aria-hidden": true,
309
+ size: "1em"
310
+ });
311
+ $[46] = t25;
312
+ } else t25 = $[46];
313
+ let t26;
314
+ if ($[47] !== t24) {
315
+ t26 = /* @__PURE__ */ jsx(Action, {
316
+ "aria-label": t24,
317
+ children: t25
318
+ });
319
+ $[47] = t24;
320
+ $[48] = t26;
321
+ } else t26 = $[48];
322
+ let t27;
323
+ if ($[49] !== t23 || $[50] !== t26) {
324
+ t27 = /* @__PURE__ */ jsxs(Item, { children: [t23, t26] });
325
+ $[49] = t23;
326
+ $[50] = t26;
327
+ $[51] = t27;
328
+ } else t27 = $[51];
329
+ let t28;
330
+ if ($[52] !== props || $[53] !== t13 || $[54] !== t20 || $[55] !== t27 || $[56] !== t6) {
331
+ t28 = /* @__PURE__ */ jsxs(Root, {
332
+ ...props,
333
+ children: [
334
+ t6,
335
+ t13,
336
+ t20,
337
+ t27
338
+ ]
339
+ });
340
+ $[52] = props;
341
+ $[53] = t13;
342
+ $[54] = t20;
343
+ $[55] = t27;
344
+ $[56] = t6;
345
+ $[57] = t28;
346
+ } else t28 = $[57];
347
+ return t28;
348
+ }
349
+ const source$1 = "import { type ReactElement } from \"react\";\n\nimport {\n CreditCardIcon,\n FileTextIcon,\n LayoutDashboardIcon,\n PencilIcon,\n UsersIcon,\n} from \"lucide-react\";\n\nimport { useWords } from \"@stealthscale/specimen\";\n\nimport { NavList } from \"@stealthscale/component-navigation\";\n\nexport function Renames(props: NavList.RootProps): ReactElement {\n const { t } = useWords(\"nav-list\");\n\n return (\n <NavList.Root {...props}>\n <NavList.Item>\n <NavList.Link aria-current=\"page\" href=\"#overview\">\n <LayoutDashboardIcon aria-hidden />\n <span>{t(\"overview\")}</span>\n </NavList.Link>\n <NavList.Action aria-label={t(\"rename\", { name: t(\"overview\") })}>\n <PencilIcon aria-hidden size=\"1em\" />\n </NavList.Action>\n </NavList.Item>\n <NavList.Item>\n <NavList.Link href=\"#invoices\">\n <FileTextIcon aria-hidden />\n <span>{t(\"invoices\")}</span>\n </NavList.Link>\n <NavList.Action aria-label={t(\"rename\", { name: t(\"invoices\") })}>\n <PencilIcon aria-hidden size=\"1em\" />\n </NavList.Action>\n </NavList.Item>\n <NavList.Item>\n <NavList.Link href=\"#team\">\n <UsersIcon aria-hidden />\n <span>{t(\"team\")}</span>\n </NavList.Link>\n <NavList.Action aria-label={t(\"rename\", { name: t(\"team\") })}>\n <PencilIcon aria-hidden size=\"1em\" />\n </NavList.Action>\n </NavList.Item>\n <NavList.Item>\n <NavList.Link href=\"#billing\">\n <CreditCardIcon aria-hidden />\n <span>{t(\"billing\")}</span>\n </NavList.Link>\n <NavList.Action aria-label={t(\"rename\", { name: t(\"billing\") })}>\n <PencilIcon aria-hidden size=\"1em\" />\n </NavList.Action>\n </NavList.Item>\n </NavList.Root>\n );\n}\n";
350
+ //#endregion
351
+ //#region src/nav-list/examples/workspace.example.tsx
352
+ var workspace_example_exports = /* @__PURE__ */ __exportAll({
353
+ Workspace: () => Workspace,
354
+ source: () => source
355
+ });
356
+ function Workspace(props) {
357
+ const $ = c(76);
358
+ const { t } = useWords("nav-list");
359
+ let t0;
360
+ if ($[0] !== t) {
361
+ t0 = t("acme");
362
+ $[0] = t;
363
+ $[1] = t0;
364
+ } else t0 = $[1];
365
+ let t1;
366
+ if ($[2] !== t) {
367
+ t1 = t("acme");
368
+ $[2] = t;
369
+ $[3] = t1;
370
+ } else t1 = $[3];
371
+ let t2;
372
+ if ($[4] === Symbol.for("react.memo_cache_sentinel")) {
373
+ t2 = /* @__PURE__ */ jsx(Avatar.Fallback, {});
374
+ $[4] = t2;
375
+ } else t2 = $[4];
376
+ let t3;
377
+ if ($[5] !== t1) {
378
+ t3 = /* @__PURE__ */ jsx(Mark, { children: /* @__PURE__ */ jsx(Avatar.Root, {
379
+ name: t1,
380
+ size: "2xs",
381
+ children: t2
382
+ }) });
383
+ $[5] = t1;
384
+ $[6] = t3;
385
+ } else t3 = $[6];
386
+ let t4;
387
+ if ($[7] !== t) {
388
+ t4 = t("acme");
389
+ $[7] = t;
390
+ $[8] = t4;
391
+ } else t4 = $[8];
392
+ let t5;
393
+ if ($[9] !== t4) {
394
+ t5 = /* @__PURE__ */ jsx("span", { children: t4 });
395
+ $[9] = t4;
396
+ $[10] = t5;
397
+ } else t5 = $[10];
398
+ let t6;
399
+ if ($[11] !== t0 || $[12] !== t3 || $[13] !== t5) {
400
+ t6 = /* @__PURE__ */ jsx(Item, { children: /* @__PURE__ */ jsxs(Link, {
401
+ href: "#acme",
402
+ tooltip: t0,
403
+ children: [t3, t5]
404
+ }) });
405
+ $[11] = t0;
406
+ $[12] = t3;
407
+ $[13] = t5;
408
+ $[14] = t6;
409
+ } else t6 = $[14];
410
+ let t7;
411
+ if ($[15] !== t) {
412
+ t7 = t("overview");
413
+ $[15] = t;
414
+ $[16] = t7;
415
+ } else t7 = $[16];
416
+ let t8;
417
+ if ($[17] === Symbol.for("react.memo_cache_sentinel")) {
418
+ t8 = /* @__PURE__ */ jsx(LayoutDashboardIcon, { "aria-hidden": true });
419
+ $[17] = t8;
420
+ } else t8 = $[17];
421
+ let t9;
422
+ if ($[18] !== t) {
423
+ t9 = t("overview");
424
+ $[18] = t;
425
+ $[19] = t9;
426
+ } else t9 = $[19];
427
+ let t10;
428
+ if ($[20] !== t9) {
429
+ t10 = /* @__PURE__ */ jsx("span", { children: t9 });
430
+ $[20] = t9;
431
+ $[21] = t10;
432
+ } else t10 = $[21];
433
+ let t11;
434
+ if ($[22] !== t10 || $[23] !== t7) {
435
+ t11 = /* @__PURE__ */ jsxs(Link, {
436
+ "aria-current": "page",
437
+ href: "#overview",
438
+ tooltip: t7,
439
+ children: [t8, t10]
440
+ });
441
+ $[22] = t10;
442
+ $[23] = t7;
443
+ $[24] = t11;
444
+ } else t11 = $[24];
445
+ let t12;
446
+ if ($[25] === Symbol.for("react.memo_cache_sentinel")) {
447
+ t12 = /* @__PURE__ */ jsx(Badge, { children: "3" });
448
+ $[25] = t12;
449
+ } else t12 = $[25];
450
+ let t13;
451
+ if ($[26] !== t11) {
452
+ t13 = /* @__PURE__ */ jsxs(Item, { children: [t11, t12] });
453
+ $[26] = t11;
454
+ $[27] = t13;
455
+ } else t13 = $[27];
456
+ let t14;
457
+ if ($[28] !== t) {
458
+ t14 = t("invoices");
459
+ $[28] = t;
460
+ $[29] = t14;
461
+ } else t14 = $[29];
462
+ let t15;
463
+ if ($[30] === Symbol.for("react.memo_cache_sentinel")) {
464
+ t15 = /* @__PURE__ */ jsx(FileTextIcon, { "aria-hidden": true });
465
+ $[30] = t15;
466
+ } else t15 = $[30];
467
+ let t16;
468
+ if ($[31] !== t) {
469
+ t16 = t("invoices");
470
+ $[31] = t;
471
+ $[32] = t16;
472
+ } else t16 = $[32];
473
+ let t17;
474
+ if ($[33] !== t16) {
475
+ t17 = /* @__PURE__ */ jsx("span", { children: t16 });
476
+ $[33] = t16;
477
+ $[34] = t17;
478
+ } else t17 = $[34];
479
+ let t18;
480
+ if ($[35] !== t14 || $[36] !== t17) {
481
+ t18 = /* @__PURE__ */ jsxs(Link, {
482
+ href: "#invoices",
483
+ tooltip: t14,
484
+ children: [t15, t17]
485
+ });
486
+ $[35] = t14;
487
+ $[36] = t17;
488
+ $[37] = t18;
489
+ } else t18 = $[37];
490
+ let t19;
491
+ if ($[38] !== t) {
492
+ t19 = t("rename", { name: t("invoices") });
493
+ $[38] = t;
494
+ $[39] = t19;
495
+ } else t19 = $[39];
496
+ let t20;
497
+ if ($[40] === Symbol.for("react.memo_cache_sentinel")) {
498
+ t20 = /* @__PURE__ */ jsx(PencilIcon, {
499
+ "aria-hidden": true,
500
+ size: "1em"
501
+ });
502
+ $[40] = t20;
503
+ } else t20 = $[40];
504
+ let t21;
505
+ if ($[41] !== t19) {
506
+ t21 = /* @__PURE__ */ jsx(Action, {
507
+ "aria-label": t19,
508
+ children: t20
509
+ });
510
+ $[41] = t19;
511
+ $[42] = t21;
512
+ } else t21 = $[42];
513
+ let t22;
514
+ if ($[43] !== t18 || $[44] !== t21) {
515
+ t22 = /* @__PURE__ */ jsxs(Item, { children: [t18, t21] });
516
+ $[43] = t18;
517
+ $[44] = t21;
518
+ $[45] = t22;
519
+ } else t22 = $[45];
520
+ let t23;
521
+ if ($[46] === Symbol.for("react.memo_cache_sentinel")) {
522
+ t23 = /* @__PURE__ */ jsx(SettingsIcon, { "aria-hidden": true });
523
+ $[46] = t23;
524
+ } else t23 = $[46];
525
+ let t24;
526
+ if ($[47] !== t) {
527
+ t24 = t("settings");
528
+ $[47] = t;
529
+ $[48] = t24;
530
+ } else t24 = $[48];
531
+ let t25;
532
+ if ($[49] !== t24) {
533
+ t25 = /* @__PURE__ */ jsx("span", { children: t24 });
534
+ $[49] = t24;
535
+ $[50] = t25;
536
+ } else t25 = $[50];
537
+ let t26;
538
+ if ($[51] === Symbol.for("react.memo_cache_sentinel")) {
539
+ t26 = /* @__PURE__ */ jsx(Indicator, { children: /* @__PURE__ */ jsx(ChevronRightIcon, {
540
+ "aria-hidden": true,
541
+ size: "1em"
542
+ }) });
543
+ $[51] = t26;
544
+ } else t26 = $[51];
545
+ let t27;
546
+ if ($[52] !== t25) {
547
+ t27 = /* @__PURE__ */ jsxs(Trigger, { children: [
548
+ t23,
549
+ t25,
550
+ t26
551
+ ] });
552
+ $[52] = t25;
553
+ $[53] = t27;
554
+ } else t27 = $[53];
555
+ let t28;
556
+ if ($[54] === Symbol.for("react.memo_cache_sentinel")) {
557
+ t28 = /* @__PURE__ */ jsx(UsersIcon, { "aria-hidden": true });
558
+ $[54] = t28;
559
+ } else t28 = $[54];
560
+ let t29;
561
+ if ($[55] !== t) {
562
+ t29 = t("team");
563
+ $[55] = t;
564
+ $[56] = t29;
565
+ } else t29 = $[56];
566
+ let t30;
567
+ if ($[57] !== t29) {
568
+ t30 = /* @__PURE__ */ jsx(Item, { children: /* @__PURE__ */ jsxs(Link, {
569
+ href: "#team",
570
+ children: [t28, /* @__PURE__ */ jsx("span", { children: t29 })]
571
+ }) });
572
+ $[57] = t29;
573
+ $[58] = t30;
574
+ } else t30 = $[58];
575
+ let t31;
576
+ if ($[59] === Symbol.for("react.memo_cache_sentinel")) {
577
+ t31 = /* @__PURE__ */ jsx(CreditCardIcon, { "aria-hidden": true });
578
+ $[59] = t31;
579
+ } else t31 = $[59];
580
+ let t32;
581
+ if ($[60] !== t) {
582
+ t32 = t("billing");
583
+ $[60] = t;
584
+ $[61] = t32;
585
+ } else t32 = $[61];
586
+ let t33;
587
+ if ($[62] !== t32) {
588
+ t33 = /* @__PURE__ */ jsx(Item, { children: /* @__PURE__ */ jsxs(Link, {
589
+ href: "#billing",
590
+ children: [t31, /* @__PURE__ */ jsx("span", { children: t32 })]
591
+ }) });
592
+ $[62] = t32;
593
+ $[63] = t33;
594
+ } else t33 = $[63];
595
+ let t34;
596
+ if ($[64] !== t30 || $[65] !== t33) {
597
+ t34 = /* @__PURE__ */ jsxs(Content, { children: [t30, t33] });
598
+ $[64] = t30;
599
+ $[65] = t33;
600
+ $[66] = t34;
601
+ } else t34 = $[66];
602
+ let t35;
603
+ if ($[67] !== t27 || $[68] !== t34) {
604
+ t35 = /* @__PURE__ */ jsxs(Branch, {
605
+ defaultOpen: true,
606
+ children: [t27, t34]
607
+ });
608
+ $[67] = t27;
609
+ $[68] = t34;
610
+ $[69] = t35;
611
+ } else t35 = $[69];
612
+ let t36;
613
+ if ($[70] !== props || $[71] !== t13 || $[72] !== t22 || $[73] !== t35 || $[74] !== t6) {
614
+ t36 = /* @__PURE__ */ jsxs(Root, {
615
+ ...props,
616
+ children: [
617
+ t6,
618
+ t13,
619
+ t22,
620
+ t35
621
+ ]
622
+ });
623
+ $[70] = props;
624
+ $[71] = t13;
625
+ $[72] = t22;
626
+ $[73] = t35;
627
+ $[74] = t6;
628
+ $[75] = t36;
629
+ } else t36 = $[75];
630
+ return t36;
631
+ }
632
+ const source = "import { type ReactElement } from \"react\";\n\nimport {\n ChevronRightIcon,\n CreditCardIcon,\n FileTextIcon,\n LayoutDashboardIcon,\n PencilIcon,\n SettingsIcon,\n UsersIcon,\n} from \"lucide-react\";\n\nimport { Avatar } from \"@stealthscale/component-media\";\nimport { useWords } from \"@stealthscale/specimen\";\n\nimport { NavList } from \"@stealthscale/component-navigation\";\n\nexport function Workspace(props: NavList.RootProps): ReactElement {\n const { t } = useWords(\"nav-list\");\n\n return (\n <NavList.Root {...props}>\n <NavList.Item>\n <NavList.Link href=\"#acme\" tooltip={t(\"acme\")}>\n <NavList.Mark>\n <Avatar.Root name={t(\"acme\")} size=\"2xs\">\n <Avatar.Fallback />\n </Avatar.Root>\n </NavList.Mark>\n <span>{t(\"acme\")}</span>\n </NavList.Link>\n </NavList.Item>\n <NavList.Item>\n <NavList.Link aria-current=\"page\" href=\"#overview\" tooltip={t(\"overview\")}>\n <LayoutDashboardIcon aria-hidden />\n <span>{t(\"overview\")}</span>\n </NavList.Link>\n <NavList.Badge>3</NavList.Badge>\n </NavList.Item>\n <NavList.Item>\n <NavList.Link href=\"#invoices\" tooltip={t(\"invoices\")}>\n <FileTextIcon aria-hidden />\n <span>{t(\"invoices\")}</span>\n </NavList.Link>\n <NavList.Action aria-label={t(\"rename\", { name: t(\"invoices\") })}>\n <PencilIcon aria-hidden size=\"1em\" />\n </NavList.Action>\n </NavList.Item>\n <NavList.Branch defaultOpen>\n <NavList.Trigger>\n <SettingsIcon aria-hidden />\n <span>{t(\"settings\")}</span>\n <NavList.Indicator>\n <ChevronRightIcon aria-hidden size=\"1em\" />\n </NavList.Indicator>\n </NavList.Trigger>\n <NavList.Content>\n <NavList.Item>\n <NavList.Link href=\"#team\">\n <UsersIcon aria-hidden />\n <span>{t(\"team\")}</span>\n </NavList.Link>\n </NavList.Item>\n <NavList.Item>\n <NavList.Link href=\"#billing\">\n <CreditCardIcon aria-hidden />\n <span>{t(\"billing\")}</span>\n </NavList.Link>\n </NavList.Item>\n </NavList.Content>\n </NavList.Branch>\n </NavList.Root>\n );\n}\n";
633
+ //#endregion
634
+ //#region src/nav-list/nav-list.specimen.tsx
635
+ /**
636
+ * Catalogue page for the navigation list.
637
+ *
638
+ * @remarks
639
+ * Every scene renders a component from `examples/` and shows that file as its source. A list
640
+ * renders in a `Room` at a sidebar's width, and the dock at a phone's width. A list sized to its
641
+ * longest row puts the counts and the controls at different distances from the row's end. The
642
+ * rail renders without a room, because it centres its squares across its own width. The palette,
643
+ * corner and effect scenes set the fill highlight, because the bar highlight renders no box. The
644
+ * looks scene renders four links and no branch, because a dock has no room to open one. The
645
+ * examples render no `nav`, because one `nav` per cell puts dozens of landmarks with one name on
646
+ * the page. The words are keys under `nav-list` in `locales/en/specimen/nav-list.json`.
647
+ */
648
+ var nav_list_specimen_default = specimen({
649
+ about: "nav-list.about",
650
+ id: "components/navigation/nav-list",
651
+ imports: "import { NavList } from \"@stealthscale/component-navigation\";",
652
+ scenes: scenesOf(recipe, {
653
+ axes: {
654
+ effect: { with: { highlight: "fill" } },
655
+ highlight: { across: "size" },
656
+ iconic: { draw: (props) => props.iconic === true ? /* @__PURE__ */ jsx(Workspace, { ...props }) : /* @__PURE__ */ jsx(Room, {
657
+ size: "xs",
658
+ children: /* @__PURE__ */ jsx(Workspace, { ...props })
659
+ }) },
660
+ palette: { with: { highlight: "fill" } },
661
+ radius: { with: { highlight: "fill" } },
662
+ reveal: {
663
+ draw: (props) => /* @__PURE__ */ jsx(Room, {
664
+ size: "xs",
665
+ children: /* @__PURE__ */ jsx(Renames, { ...props })
666
+ }),
667
+ example: renames_example_exports
668
+ },
669
+ variant: {
670
+ direction: "column",
671
+ draw: (props) => /* @__PURE__ */ jsx(Room, {
672
+ size: props.variant === "dock" ? "sm" : "xs",
673
+ children: /* @__PURE__ */ jsx(Destinations, { ...props })
674
+ }),
675
+ example: destinations_example_exports
676
+ }
677
+ },
678
+ draw: (props) => /* @__PURE__ */ jsx(Room, {
679
+ size: "xs",
680
+ children: /* @__PURE__ */ jsx(Workspace, { ...props })
681
+ }),
682
+ example: workspace_example_exports,
683
+ namespace: "nav-list",
684
+ order: [
685
+ "variant",
686
+ "highlight",
687
+ "palette",
688
+ "radius",
689
+ "guide",
690
+ "iconic",
691
+ "reveal",
692
+ "effect"
693
+ ]
694
+ }),
695
+ title: "nav-list.title"
696
+ });
697
+ //#endregion
698
+ export { nav_list_specimen_default as default };