@slotted/react 0.1.0-beta.17 → 0.1.0-beta.18

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.
Files changed (40) hide show
  1. package/dist/{app-shell-CJwXBvE5.js → app-shell-CXlO6z0w.js} +90 -73
  2. package/dist/app-shell.js +1 -1
  3. package/dist/{description-list-KjUs1muC.js → description-list-BbWLehw0.js} +18 -16
  4. package/dist/description-list.js +1 -1
  5. package/dist/docs/alert.json +1 -1
  6. package/dist/docs/alert.md +1 -1
  7. package/dist/docs/app-shell.json +19 -2
  8. package/dist/docs/app-shell.md +3 -1
  9. package/dist/docs/description-list.json +10 -2
  10. package/dist/docs/description-list.md +2 -1
  11. package/dist/docs/guidelines/composition.md +12 -0
  12. package/dist/docs/guidelines/errors-and-conflicts.md +7 -6
  13. package/dist/docs/guidelines/index.md +1 -0
  14. package/dist/docs/guidelines/reading-permissions.md +2 -2
  15. package/dist/docs/guidelines/reports.md +1 -1
  16. package/dist/docs/index.md +2 -2
  17. package/dist/docs/inline-message.json +5 -4
  18. package/dist/docs/inline-message.md +6 -5
  19. package/dist/index.js +4 -4
  20. package/dist/{side-navigation-DRLWTlJ4.js → side-navigation-CvIGfGjZ.js} +1 -1
  21. package/dist/side-navigation.js +1 -1
  22. package/dist/styles/app-shell.css +1 -1
  23. package/dist/styles/description-list.css +1 -1
  24. package/dist/styles/index.css +2 -2
  25. package/dist/styles/side-navigation.css +1 -1
  26. package/dist/styles/top-navigation.css +1 -1
  27. package/dist/styles.css +1 -1
  28. package/dist/{top-navigation-B_oQgy56.js → top-navigation-D_Jt0jNw.js} +1 -1
  29. package/dist/top-navigation.js +1 -1
  30. package/dist/types/app-shell/app-shell-parts.d.ts.map +1 -1
  31. package/dist/types/description-list/description-list-defaults.d.ts.map +1 -1
  32. package/dist/types/description-list/description-list.d.ts +1 -1
  33. package/dist/types/description-list/description-list.d.ts.map +1 -1
  34. package/dist/types/description-list/description-list.types.d.ts +7 -0
  35. package/dist/types/description-list/description-list.types.d.ts.map +1 -1
  36. package/dist/types/description-list/index.d.ts +1 -1
  37. package/dist/types/description-list/index.d.ts.map +1 -1
  38. package/dist/types/inline-message/inline-message.d.ts +2 -2
  39. package/dist/types/inline-message/inline-message.types.d.ts +2 -2
  40. package/package.json +6 -6
@@ -8,12 +8,12 @@ import { createContext as u, isValidElement as d, useCallback as f, useContext a
8
8
  import { Fragment as ee, jsx as x, jsxs as te } from "react/jsx-runtime";
9
9
  import { createPresence as ne } from "@slotted/core/presence";
10
10
  import { appShellMessages as re } from "@slotted/core/i18n";
11
- import { setPortalContainer as ie } from "@slotted/core/portal";
12
- import { createDismissableLayer as ae } from "@slotted/core/dismissable-layer";
13
- import { EXTENT_LARGE_STEP_PX as oe, EXTENT_STEP_PX as se, anchorsAtStart as ce, extentAtPoint as le, holdResizeGesture as ue, stepAmountFromPixels as de, stepExtent as fe } from "@slotted/core/extent";
14
- import { COMPACT_BELOW as pe, clamp as S, createWidthGate as me } from "@slotted/core/measure";
11
+ import { setPortalContainer as S } from "@slotted/core/portal";
12
+ import { createDismissableLayer as ie } from "@slotted/core/dismissable-layer";
13
+ import { EXTENT_LARGE_STEP_PX as ae, EXTENT_STEP_PX as oe, anchorsAtStart as se, extentAtPoint as ce, holdResizeGesture as le, stepAmountFromPixels as ue, stepExtent as de } from "@slotted/core/extent";
14
+ import { COMPACT_BELOW as fe, clamp as C, createWidthGate as pe } from "@slotted/core/measure";
15
15
  //#region src/app-shell/app-shell-defaults.tsx
16
- var he = u({
16
+ var me = u({
17
17
  asideMode: "auto",
18
18
  asideSize: "md",
19
19
  canvas: "inset",
@@ -30,12 +30,12 @@ var he = u({
30
30
  scroll: "content",
31
31
  separation: "rule"
32
32
  });
33
- function C() {
34
- return p(he);
33
+ function w() {
34
+ return p(me);
35
35
  }
36
- function ge({ children: e, ...t }) {
37
- let n = C();
38
- return /* @__PURE__ */ x(he.Provider, {
36
+ function he({ children: e, ...t }) {
37
+ let n = w();
38
+ return /* @__PURE__ */ x(me.Provider, {
39
39
  value: {
40
40
  asideMode: t.asideMode ?? n.asideMode,
41
41
  asideSize: t.asideSize ?? n.asideSize,
@@ -58,7 +58,7 @@ function ge({ children: e, ...t }) {
58
58
  }
59
59
  //#endregion
60
60
  //#region src/app-shell/app-shell-parts.tsx
61
- function w(e, t) {
61
+ function T(e, t) {
62
62
  let n = L();
63
63
  return f((r) => {
64
64
  n.nodes[e] = r, typeof t == "function" ? t(r) : t != null && (t.current = r);
@@ -68,12 +68,12 @@ function w(e, t) {
68
68
  e
69
69
  ]);
70
70
  }
71
- function T(e) {
71
+ function E(e) {
72
72
  return f((t) => {
73
73
  typeof e == "function" ? e(t) : e != null && (e.current = t);
74
74
  }, [e]);
75
75
  }
76
- function E(e) {
76
+ function ge(e) {
77
77
  let t = L();
78
78
  m(() => t.register(e), [e, t]);
79
79
  }
@@ -81,7 +81,7 @@ function D(e, t) {
81
81
  return t === void 0 ? null : t(e);
82
82
  }
83
83
  function _e({ children: e, className: t, ref: n, render: r, style: i, ...a }) {
84
- let s = w("banner", n), c = o({
84
+ let s = T("banner", n), c = o({
85
85
  ...a,
86
86
  children: e,
87
87
  className: t,
@@ -103,7 +103,7 @@ function ve({ children: e, className: t, ref: n, render: r, style: i, ...a }) {
103
103
  className: t,
104
104
  "data-part": "brand",
105
105
  style: i
106
- }), c = T(n);
106
+ }), c = E(n);
107
107
  return D({
108
108
  ...s,
109
109
  ref: c
@@ -119,7 +119,7 @@ function ye({ children: e, className: t, ref: n, render: r, style: i, ...a }) {
119
119
  className: t,
120
120
  "data-part": "centre",
121
121
  style: i
122
- }), c = T(n);
122
+ }), c = E(n);
123
123
  return D({
124
124
  ...s,
125
125
  ref: c
@@ -135,7 +135,7 @@ function be({ children: e, className: t, ref: n, render: r, style: i, ...a }) {
135
135
  className: t,
136
136
  "data-part": "actions",
137
137
  style: i
138
- }), c = T(n);
138
+ }), c = E(n);
139
139
  return D({
140
140
  ...s,
141
141
  ref: c
@@ -145,8 +145,8 @@ function be({ children: e, className: t, ref: n, render: r, style: i, ...a }) {
145
145
  });
146
146
  }
147
147
  function xe({ "aria-label": e, children: t, className: n, id: r, ref: i, render: a, style: s, ...c }) {
148
- let l = L(), u = w("nav", i);
149
- E("nav");
148
+ let l = L(), u = T("nav", i);
149
+ ge("nav");
150
150
  let d = o({
151
151
  ...c,
152
152
  "aria-label": e ?? l.t("nav"),
@@ -171,7 +171,7 @@ function Se({ children: e, className: t, ref: n, render: r, style: i, ...a }) {
171
171
  className: t,
172
172
  "data-part": "nav-rail",
173
173
  style: i
174
- }), c = T(n);
174
+ }), c = E(n);
175
175
  return D({
176
176
  ...s,
177
177
  ref: c
@@ -187,7 +187,7 @@ function Ce({ children: e, className: t, ref: n, render: r, style: i, ...a }) {
187
187
  className: t,
188
188
  "data-part": "nav-header",
189
189
  style: i
190
- }), c = T(n);
190
+ }), c = E(n);
191
191
  return D({
192
192
  ...s,
193
193
  ref: c
@@ -203,7 +203,7 @@ function we({ children: e, className: t, ref: n, render: r, style: i, ...a }) {
203
203
  className: t,
204
204
  "data-part": "nav-body",
205
205
  style: i
206
- }), c = T(n);
206
+ }), c = E(n);
207
207
  return D({
208
208
  ...s,
209
209
  ref: c
@@ -219,7 +219,7 @@ function Te({ children: e, className: t, ref: n, render: r, style: i, ...a }) {
219
219
  className: t,
220
220
  "data-part": "nav-footer",
221
221
  style: i
222
- }), c = T(n);
222
+ }), c = E(n);
223
223
  return D({
224
224
  ...s,
225
225
  ref: c
@@ -229,8 +229,8 @@ function Te({ children: e, className: t, ref: n, render: r, style: i, ...a }) {
229
229
  });
230
230
  }
231
231
  function O({ children: e, className: t, id: n, ref: r, render: i, style: a, ...s }) {
232
- let c = L(), l = w("main", r);
233
- E("main");
232
+ let c = L(), l = T("main", r);
233
+ ge("main");
234
234
  let u = o({
235
235
  ...c.busy ? { "aria-busy": !0 } : {},
236
236
  ...s,
@@ -272,8 +272,8 @@ function k({ delay: e, label: t, loading: n = !0, minDuration: o, onWithdraw: s,
272
272
  });
273
273
  }
274
274
  function A({ "aria-label": e, children: t, className: n, id: r, ref: i, render: a, style: s, ...c }) {
275
- let l = L(), u = w("aside", i);
276
- E("aside");
275
+ let l = L(), u = T("aside", i);
276
+ ge("aside");
277
277
  let d = l.asideExtent, f = o({
278
278
  ...c,
279
279
  "aria-label": e ?? l.t("aside"),
@@ -302,7 +302,7 @@ function Ee({ children: e, className: t, ref: n, render: r, style: i, ...a }) {
302
302
  className: t,
303
303
  "data-part": "aside-header",
304
304
  style: i
305
- }), c = T(n);
305
+ }), c = E(n);
306
306
  return D({
307
307
  ...s,
308
308
  ref: c
@@ -319,7 +319,7 @@ function De({ children: e, className: t, inset: n, ref: r, render: i, style: a,
319
319
  ...n === void 0 ? {} : { "data-inset": n },
320
320
  "data-part": "aside-body",
321
321
  style: a
322
- }), l = T(r);
322
+ }), l = E(r);
323
323
  return D({
324
324
  ...c,
325
325
  ref: l
@@ -344,12 +344,12 @@ function M(e) {
344
344
  }
345
345
  var N = 3;
346
346
  function ke({ "aria-label": e, className: t, onKeyDown: n, onPointerDown: r, ref: i, render: a, style: s, ...c }) {
347
- let l = L(), u = y(null), d = y(null), f = y(null), [p, h] = b(void 0), g = l.navSide === "end" ? "start" : "end", _ = l.asideMode === "inline" && l.asideOpen, { asideExtent: v, nodes: ee, root: te } = l;
347
+ let l = L(), u = y(null), d = y(null), f = y(null), [p, h] = b(void 0), g = l.navSide === "end" ? "start" : "end", _ = l.asideMode === "inline" && l.asideOpen, { asideExtent: v, nodes: ne, root: re } = l;
348
348
  if (j(() => {
349
- let e = ee.aside;
349
+ let e = ne.aside;
350
350
  if (!_ || v !== void 0 || e === null) return;
351
351
  let t = () => {
352
- let t = M(te);
352
+ let t = M(re);
353
353
  if (t === null || t.width <= 0) return h(void 0);
354
354
  h(e.getBoundingClientRect().width / t.width);
355
355
  };
@@ -358,11 +358,11 @@ function ke({ "aria-label": e, className: t, onKeyDown: n, onPointerDown: r, ref
358
358
  return n.observe(e), () => n.disconnect();
359
359
  }, [
360
360
  v,
361
- ee,
362
- te,
361
+ ne,
362
+ re,
363
363
  _
364
364
  ]), m(() => () => f.current?.(), []), !_) return null;
365
- let ne = S(l.asideExtent ?? p ?? l.minAsideExtent, l.minAsideExtent, l.maxAsideExtent), re = (e) => Math.round(S(e, 0, 1) * 100), ie = (e, t) => le({
365
+ let S = C(l.asideExtent ?? p ?? l.minAsideExtent, l.minAsideExtent, l.maxAsideExtent), ie = (e) => Math.round(C(e, 0, 1) * 100), fe = (e, t) => ce({
366
366
  point: {
367
367
  x: e.clientX,
368
368
  y: e.clientY
@@ -370,41 +370,41 @@ function ke({ "aria-label": e, className: t, onKeyDown: n, onPointerDown: r, ref
370
370
  rect: t,
371
371
  rtl: Oe(u.current),
372
372
  side: g
373
- }), ae = (e) => {
373
+ }), pe = (e) => {
374
374
  if (r?.(e), e.defaultPrevented || e.button !== 0) return;
375
375
  let t = M(l.root);
376
376
  t === null || t.width <= 0 || (e.preventDefault(), e.currentTarget.setPointerCapture(e.pointerId), e.currentTarget.focus(), d.current = {
377
377
  moved: !1,
378
- offset: ne - ie(e, t),
378
+ offset: S - fe(e, t),
379
379
  x: e.clientX
380
380
  });
381
- }, pe = (e) => {
381
+ }, me = (e) => {
382
382
  let t = d.current;
383
383
  if (t === null) return;
384
384
  let n = M(l.root);
385
385
  if (!(n === null || n.width <= 0)) {
386
386
  if (!t.moved) {
387
387
  if (Math.abs(e.clientX - t.x) < N) return;
388
- t.moved = !0, f.current?.(), f.current = ue(u.current?.ownerDocument, "col-resize"), l.setAsideDragging(!0);
388
+ t.moved = !0, f.current?.(), f.current = le(u.current?.ownerDocument, "col-resize"), l.setAsideDragging(!0);
389
389
  }
390
- l.setAsideExtent(ie(e, n) + t.offset, "pointer", e);
390
+ l.setAsideExtent(fe(e, n) + t.offset, "pointer", e);
391
391
  }
392
- }, me = (e) => {
392
+ }, w = (e) => {
393
393
  let t = d.current;
394
394
  t !== null && (d.current = null, e.currentTarget.hasPointerCapture(e.pointerId) && e.currentTarget.releasePointerCapture(e.pointerId), t.moved && (f.current?.(), f.current = null, l.setAsideDragging(!1)));
395
395
  }, he = (e) => {
396
396
  if (n?.(e), e.defaultPrevented) return;
397
- let t = ce(g, Oe(u.current)), r = (t) => {
397
+ let t = se(g, Oe(u.current)), r = (t) => {
398
398
  e.preventDefault();
399
- let n = M(l.root), r = n === null ? 0 : de({
400
- pixels: e.shiftKey ? oe : se,
399
+ let n = M(l.root), r = n === null ? 0 : ue({
400
+ pixels: e.shiftKey ? ae : oe,
401
401
  rect: n,
402
402
  side: g
403
403
  });
404
- l.setAsideExtent(fe({
404
+ l.setAsideExtent(de({
405
405
  amount: r,
406
406
  direction: t,
407
- fraction: ne,
407
+ fraction: S,
408
408
  max: l.maxAsideExtent,
409
409
  min: l.minAsideExtent
410
410
  }), "keyboard", e);
@@ -416,33 +416,50 @@ function ke({ "aria-label": e, className: t, onKeyDown: n, onPointerDown: r, ref
416
416
  case "End": return e.preventDefault(), l.setAsideExtent(l.maxAsideExtent, "keyboard", e);
417
417
  default: return;
418
418
  }
419
- }, C = (e) => {
419
+ }, T = (e) => {
420
420
  u.current = e, typeof i == "function" ? i(e) : i && (i.current = e);
421
- }, ge = o({
421
+ }, E = o({
422
422
  ...c,
423
423
  "aria-controls": l.asideId,
424
424
  "aria-label": e ?? l.t("resizeAside"),
425
425
  "aria-orientation": "vertical",
426
- "aria-valuemax": re(l.maxAsideExtent),
427
- "aria-valuemin": re(l.minAsideExtent),
428
- "aria-valuenow": re(ne),
426
+ "aria-valuemax": ie(l.maxAsideExtent),
427
+ "aria-valuemin": ie(l.minAsideExtent),
428
+ "aria-valuenow": ie(S),
429
+ children: /* @__PURE__ */ te(ee, { children: [
430
+ /* @__PURE__ */ x("span", {
431
+ "aria-hidden": "true",
432
+ "data-part": "line",
433
+ "data-part-line": ""
434
+ }),
435
+ /* @__PURE__ */ x("span", {
436
+ "aria-hidden": "true",
437
+ "data-part": "grip",
438
+ "data-part-grip": ""
439
+ }),
440
+ /* @__PURE__ */ x("span", {
441
+ "aria-hidden": "true",
442
+ "data-part": "line",
443
+ "data-part-line": ""
444
+ })
445
+ ] }),
429
446
  className: t,
430
447
  "data-part": "aside-resizer",
431
448
  onKeyDown: he,
432
- onLostPointerCapture: me,
433
- onPointerDown: ae,
434
- onPointerMove: pe,
435
- onPointerUp: me,
449
+ onLostPointerCapture: w,
450
+ onPointerDown: pe,
451
+ onPointerMove: me,
452
+ onPointerUp: w,
436
453
  role: "separator",
437
454
  style: s,
438
455
  tabIndex: 0
439
456
  });
440
457
  return a === void 0 ? /* @__PURE__ */ x("div", {
441
- ...ge,
442
- ref: C
458
+ ...E,
459
+ ref: T
443
460
  }) : a({
444
- ...ge,
445
- ref: C
461
+ ...E,
462
+ ref: T
446
463
  });
447
464
  }
448
465
  function Ae({ children: e, className: t, ref: n, render: r, style: i, ...a }) {
@@ -452,7 +469,7 @@ function Ae({ children: e, className: t, ref: n, render: r, style: i, ...a }) {
452
469
  className: t,
453
470
  "data-part": "aside-footer",
454
471
  style: i
455
- }), c = T(n);
472
+ }), c = E(n);
456
473
  return D({
457
474
  ...s,
458
475
  ref: c
@@ -462,7 +479,7 @@ function Ae({ children: e, className: t, ref: n, render: r, style: i, ...a }) {
462
479
  });
463
480
  }
464
481
  function P({ children: e, className: t, ref: n, render: r, style: i, ...a }) {
465
- let s = w("footer", n), c = o({
482
+ let s = T("footer", n), c = o({
466
483
  ...a,
467
484
  children: e,
468
485
  className: t,
@@ -478,7 +495,7 @@ function P({ children: e, className: t, ref: n, render: r, style: i, ...a }) {
478
495
  });
479
496
  }
480
497
  function F({ "aria-controls": e, "aria-label": r, children: i, className: a, id: s, onClick: c, ref: l, render: u, style: d, type: p, ...m }) {
481
- let h = L(), g = w("toggle", l), _ = f((e) => {
498
+ let h = L(), g = T("toggle", l), _ = f((e) => {
482
499
  if (c?.(e), e.defaultPrevented) return;
483
500
  let t = e.detail === 0 ? "keyboard" : "pointer";
484
501
  h.setOpen(!h.open, t, e.nativeEvent);
@@ -504,7 +521,7 @@ function F({ "aria-controls": e, "aria-label": r, children: i, className: a, id:
504
521
  });
505
522
  }
506
523
  function I({ "aria-controls": e, "aria-label": r, children: i, className: a, id: s, onClick: c, ref: l, render: u, style: d, type: p, ...m }) {
507
- let h = L(), g = w("asideToggle", l), _ = f((e) => {
524
+ let h = L(), g = T("asideToggle", l), _ = f((e) => {
508
525
  if (c?.(e), e.defaultPrevented) return;
509
526
  let t = e.detail === 0 ? "keyboard" : "pointer";
510
527
  h.setAsideOpen(!h.asideOpen, t, e.nativeEvent);
@@ -531,7 +548,7 @@ function I({ "aria-controls": e, "aria-label": r, children: i, className: a, id:
531
548
  }
532
549
  //#endregion
533
550
  //#region src/app-shell/app-shell.tsx
534
- var je = pe, Me = u(void 0);
551
+ var je = fe, Me = u(void 0);
535
552
  function Ne(e, t) {
536
553
  if (Array.isArray(e)) {
537
554
  for (let n of e) Ne(n, t);
@@ -547,8 +564,8 @@ function L() {
547
564
  function Pe() {
548
565
  return p(Me);
549
566
  }
550
- function R({ asideExtent: t, asideMode: n, asideOpen: r, asideSize: i, canvas: a, children: u, className: d, closeOnNavigate: p, collapsedTo: _, defaultAsideExtent: oe, defaultAsideOpen: se, defaultNavOpen: ce, escape: le, back: ue, maxAsideExtent: de, messages: fe, minAsideExtent: pe, modal: he, navMode: ge, navOpen: w, navSide: T, navSize: E, onAsideExtentChange: D, onAsideOpenChange: _e, onNavOpenChange: ve, outsidePress: ye, primary: be, ref: xe, render: Se, scroll: Ce, separation: we, style: Te, ...O }) {
551
- let k = C(), A = h(), [Ee, De] = b(ce ?? !0), j = w ?? Ee, [Oe, M] = b(se ?? !0), N = r ?? Oe, [ke, Ae] = b(oe), P = t ?? ke, F = S(pe ?? .16, 0, 1), I = S(de ?? .6, F, 1), [L, Pe] = b(!1), R = i ?? k.asideSize, Fe = n ?? k.asideMode, Ie = a ?? k.canvas, z = p ?? k.closeOnNavigate, Le = _ ?? k.collapsedTo, Re = we ?? k.separation, ze = le ?? k.escape, Be = ue ?? k.back, B = he ?? k.modal, Ve = T ?? k.navSide, He = E ?? k.navSize, V = ye ?? k.outsidePress, Ue = be ?? k.primary, We = Ce ?? k.scroll, Ge = ge ?? k.navMode, H = e(re, fe), [U, Ke] = b(null), [W, qe] = b(void 0), G = Ge === "auto" ? W === void 0 ? void 0 : W ? "overlay" : "inline" : Ge, K = Fe === "auto" ? W === void 0 ? void 0 : W ? "overlay" : "inline" : Fe, q = y({
567
+ function R({ asideExtent: t, asideMode: n, asideOpen: r, asideSize: i, canvas: a, children: u, className: d, closeOnNavigate: p, collapsedTo: _, defaultAsideExtent: ae, defaultAsideOpen: oe, defaultNavOpen: se, escape: ce, back: le, maxAsideExtent: ue, messages: de, minAsideExtent: fe, modal: me, navMode: he, navOpen: T, navSide: E, navSize: ge, onAsideExtentChange: D, onAsideOpenChange: _e, onNavOpenChange: ve, outsidePress: ye, primary: be, ref: xe, render: Se, scroll: Ce, separation: we, style: Te, ...O }) {
568
+ let k = w(), A = h(), [Ee, De] = b(se ?? !0), j = T ?? Ee, [Oe, M] = b(oe ?? !0), N = r ?? Oe, [ke, Ae] = b(ae), P = t ?? ke, F = C(fe ?? .16, 0, 1), I = C(ue ?? .6, F, 1), [L, Pe] = b(!1), R = i ?? k.asideSize, Fe = n ?? k.asideMode, Ie = a ?? k.canvas, z = p ?? k.closeOnNavigate, Le = _ ?? k.collapsedTo, Re = we ?? k.separation, ze = ce ?? k.escape, Be = le ?? k.back, B = me ?? k.modal, Ve = E ?? k.navSide, He = ge ?? k.navSize, V = ye ?? k.outsidePress, Ue = be ?? k.primary, We = Ce ?? k.scroll, Ge = he ?? k.navMode, H = e(re, de), [U, Ke] = b(null), [W, qe] = b(void 0), G = Ge === "auto" ? W === void 0 ? void 0 : W ? "overlay" : "inline" : Ge, K = Fe === "auto" ? W === void 0 ? void 0 : W ? "overlay" : "inline" : Fe, q = y({
552
569
  aside: null,
553
570
  asideToggle: null,
554
571
  banner: null,
@@ -575,7 +592,7 @@ function R({ asideExtent: t, asideMode: n, asideOpen: r, asideSize: i, canvas: a
575
592
  }))), []), Y = f((e, t, n) => {
576
593
  if (e === j) return;
577
594
  let r = !1, i = l({
578
- controlled: w,
595
+ controlled: T,
579
596
  initial: j,
580
597
  onRequest: (e) => {
581
598
  r = e.cancelled, ve?.(e.value, {
@@ -593,7 +610,7 @@ function R({ asideExtent: t, asideMode: n, asideOpen: r, asideSize: i, canvas: a
593
610
  r || i && De(e);
594
611
  }, [
595
612
  j,
596
- w,
613
+ T,
597
614
  ve
598
615
  ]), X = f((e, t, n) => {
599
616
  if (e === N) return;
@@ -619,7 +636,7 @@ function R({ asideExtent: t, asideMode: n, asideOpen: r, asideSize: i, canvas: a
619
636
  N,
620
637
  _e
621
638
  ]), tt = f((e, n, r) => {
622
- let i = e === void 0 ? void 0 : S(e, F, I);
639
+ let i = e === void 0 ? void 0 : C(e, F, I);
623
640
  if (i === P) return;
624
641
  let a = !1, o = l({
625
642
  controlled: t,
@@ -650,7 +667,7 @@ function R({ asideExtent: t, asideMode: n, asideOpen: r, asideSize: i, canvas: a
650
667
  nt || qe(void 0);
651
668
  return;
652
669
  }
653
- let e = me(U, {
670
+ let e = pe(U, {
654
671
  at: je,
655
672
  onChange: qe
656
673
  });
@@ -679,7 +696,7 @@ function R({ asideExtent: t, asideMode: n, asideOpen: r, asideSize: i, canvas: a
679
696
  let ft = f((e) => {
680
697
  Q.current?.setNode(e);
681
698
  }, []), pt = f((e, t, n, r) => {
682
- let i = ae(e, {
699
+ let i = ie(e, {
683
700
  ...t === null ? {} : { branches: [t] },
684
701
  back: B && Be === "close",
685
702
  content: e,
@@ -749,7 +766,7 @@ function R({ asideExtent: t, asideMode: n, asideOpen: r, asideSize: i, canvas: a
749
766
  Y
750
767
  ]), [ht, gt] = b(null);
751
768
  m(() => {
752
- if (ht !== null) return ie(ht), () => ie(null, ht.ownerDocument);
769
+ if (ht !== null) return S(ht), () => S(null, ht.ownerDocument);
753
770
  }, [ht]), g(xe, () => ({
754
771
  openNav: () => Y(!0, "programmatic"),
755
772
  closeNav: () => Y(!1, "programmatic"),
@@ -901,4 +918,4 @@ function R({ asideExtent: t, asideMode: n, asideOpen: r, asideSize: i, canvas: a
901
918
  });
902
919
  }
903
920
  //#endregion
904
- export { k as C, F as S, C as T, xe as _, be as a, Ce as b, Ae as c, I as d, _e as f, O as g, P as h, Pe as i, Ee as l, ye as m, R as n, A as o, ve as p, L as r, De as s, je as t, ke as u, we as v, ge as w, Se as x, Te as y };
921
+ export { k as C, F as S, w as T, xe as _, be as a, Ce as b, Ae as c, I as d, _e as f, O as g, P as h, Pe as i, Ee as l, ye as m, R as n, A as o, ve as p, L as r, De as s, je as t, ke as u, we as v, he as w, Se as x, Te as y };
package/dist/app-shell.js CHANGED
@@ -1,2 +1,2 @@
1
- import { C as e, S as t, T as n, _ as r, a as i, b as a, c as o, d as s, f as c, g as l, h as u, i as d, l as f, m as p, n as m, o as h, p as g, r as _, s as v, t as y, u as b, v as x, w as S, x as C, y as w } from "./app-shell-CJwXBvE5.js";
1
+ import { C as e, S as t, T as n, _ as r, a as i, b as a, c as o, d as s, f as c, g as l, h as u, i as d, l as f, m as p, n as m, o as h, p as g, r as _, s as v, t as y, u as b, v as x, w as S, x as C, y as w } from "./app-shell-CXlO6z0w.js";
2
2
  export { y as APP_SHELL_OVERLAY_AT, m as AppShell, i as AppShellActions, h as AppShellAside, v as AppShellAsideBody, o as AppShellAsideFooter, f as AppShellAsideHeader, b as AppShellAsideResizer, s as AppShellAsideToggle, c as AppShellBanner, g as AppShellBrand, p as AppShellCentre, S as AppShellDefaultsProvider, u as AppShellFooter, l as AppShellMain, r as AppShellNav, x as AppShellNavBody, w as AppShellNavFooter, a as AppShellNavHeader, C as AppShellNavRail, t as AppShellNavToggle, e as AppShellProgress, _ as useAppShell, n as useAppShellDefaults, d as useAppShellIfPresent };
@@ -19,6 +19,7 @@ function y({ children: e, ...t }) {
19
19
  value: {
20
20
  columns: t.columns ?? n.columns,
21
21
  layout: t.layout ?? n.layout,
22
+ minColumnWidth: t.minColumnWidth ?? n.minColumnWidth,
22
23
  termWidth: t.termWidth ?? n.termWidth,
23
24
  variant: t.variant ?? n.variant
24
25
  },
@@ -37,32 +38,33 @@ function C() {
37
38
  return o(x);
38
39
  }
39
40
  var w = x.Provider;
40
- function T({ children: t, columns: n, layout: i, messages: a, render: o, style: s, termWidth: c, variant: l, ...u }) {
41
- let d = v(), p = e(m, a), h = {
42
- columns: n ?? d.columns ?? 1,
43
- layout: i ?? d.layout ?? "row",
44
- t: p,
45
- variant: l ?? d.variant ?? "plain"
46
- }, g = c ?? d.termWidth, _ = r({
47
- ...u,
41
+ function T({ children: t, columns: n, layout: i, messages: a, minColumnWidth: o, render: s, style: c, termWidth: l, variant: u, ...d }) {
42
+ let p = v(), h = e(m, a), g = {
43
+ columns: n ?? p.columns ?? 1,
44
+ layout: i ?? p.layout ?? "row",
45
+ t: h,
46
+ variant: u ?? p.variant ?? "plain"
47
+ }, _ = l ?? p.termWidth, y = r({
48
+ ...d,
48
49
  children: /* @__PURE__ */ f("dl", {
49
50
  "data-part": "list",
50
51
  "data-part-list": "",
51
52
  children: t
52
53
  }),
53
- "data-columns": String(h.columns),
54
- "data-layout": h.layout,
54
+ "data-columns": String(g.columns),
55
+ "data-layout": g.layout,
56
+ "data-min-column-width": o ?? p.minColumnWidth ?? "md",
55
57
  "data-part": "root",
56
58
  "data-ui": "description-list",
57
- "data-variant": h.variant,
58
- style: g === void 0 ? s : {
59
- ...s,
60
- "--slotted-description-list-term-width": g
59
+ "data-variant": g.variant,
60
+ style: _ === void 0 ? c : {
61
+ ...c,
62
+ "--slotted-description-list-term-width": _
61
63
  }
62
64
  });
63
65
  return /* @__PURE__ */ f(b.Provider, {
64
- value: h,
65
- children: o === void 0 ? /* @__PURE__ */ f("div", { ..._ }) : o(_)
66
+ value: g,
67
+ children: s === void 0 ? /* @__PURE__ */ f("div", { ...y }) : s(y)
66
68
  });
67
69
  }
68
70
  //#endregion
@@ -1,2 +1,2 @@
1
- import { a as e, c as t, d as n, f as r, h as i, i as a, l as o, m as s, n as c, o as l, p as u, r as d, s as f, t as p, u as m } from "./description-list-KjUs1muC.js";
1
+ import { a as e, c as t, d as n, f as r, h as i, i as a, l as o, m as s, n as c, o as l, p as u, r as d, s as f, t as p, u as m } from "./description-list-BbWLehw0.js";
2
2
  export { p as COPIED_FOR, n as DescriptionList, c as DescriptionListAction, s as DescriptionListDefaultsProvider, d as DescriptionListDescription, a as DescriptionListHint, e as DescriptionListItem, l as DescriptionListTerm, m as copyToClipboard, f as overflowsClamp, t as selectValue, o as spanWithin, r as useDescriptionList, i as useDescriptionListDefaults, u as useDescriptionListItem };
@@ -4,7 +4,7 @@
4
4
  "binding": "react",
5
5
  "catalog": {
6
6
  "group": "Feedback",
7
- "summary": "Static message with a tone, icon and actions."
7
+ "summary": "Framed notice heading a section, a form or a page."
8
8
  },
9
9
  "axes": {
10
10
  "tone": [
@@ -1,7 +1,7 @@
1
1
  <!-- index: ./index.md -->
2
2
  # alert
3
3
 
4
- `data-ui="alert"` · Static message with a tone, icon and actions.
4
+ `data-ui="alert"` · Framed notice heading a section, a form or a page.
5
5
 
6
6
  ## Import
7
7
 
@@ -132,6 +132,8 @@
132
132
  "progress",
133
133
  "aside",
134
134
  "aside-resizer",
135
+ "line",
136
+ "grip",
135
137
  "aside-header",
136
138
  "aside-body",
137
139
  "aside-footer",
@@ -250,6 +252,18 @@
250
252
  "required": false,
251
253
  "purpose": "The pane’s inner edge, from the WAI-ARIA Window Splitter pattern: focusable, aria-controls the pane, its three values the extent as whole percentages of the shell. Placed inside AppShellAside; rendering it is the capability. Drawn on the column alone — under asideMode=\"overlay\" or a closed pane it renders nothing, and a row under the content hides it."
252
254
  },
255
+ {
256
+ "part": "line",
257
+ "element": "span inside the aside-resizer, aria-hidden",
258
+ "required": false,
259
+ "purpose": "One of the splitter family’s two hairlines on the pane’s edge, drawn from the splitter tokens: fading away from the grip at rest, running the strip under the hand, the drag and the keyboard."
260
+ },
261
+ {
262
+ "part": "grip",
263
+ "element": "span inside the aside-resizer, aria-hidden",
264
+ "required": false,
265
+ "purpose": "The dot matrix between the two lines, two columns by three rows, in the line’s step."
266
+ },
253
267
  {
254
268
  "part": "aside-header",
255
269
  "element": "div",
@@ -609,7 +623,6 @@
609
623
  "--slotted-app-shell-nav-surface",
610
624
  "--slotted-app-shell-radius",
611
625
  "--slotted-app-shell-rail-size",
612
- "--slotted-app-shell-resizer-color",
613
626
  "--slotted-app-shell-row-inset-size",
614
627
  "--slotted-app-shell-row-mark-size",
615
628
  "--slotted-app-shell-row-text-line-height",
@@ -620,7 +633,6 @@
620
633
  "--slotted-app-shell-tone-surface",
621
634
  "--slotted-border-strong",
622
635
  "--slotted-border-subtle",
623
- "--slotted-border-width-thick",
624
636
  "--slotted-border-width-thin",
625
637
  "--slotted-control-font-size-md",
626
638
  "--slotted-control-font-size-sm",
@@ -646,16 +658,21 @@
646
658
  "--slotted-font-weight-semibold",
647
659
  "--slotted-line-height-sm",
648
660
  "--slotted-radius-lg",
661
+ "--slotted-radius-sm",
649
662
  "--slotted-scrim",
650
663
  "--slotted-shadow-lg",
651
664
  "--slotted-shadow-md",
652
665
  "--slotted-shadow-xs",
653
666
  "--slotted-space-1",
667
+ "--slotted-space-12",
654
668
  "--slotted-space-2",
655
669
  "--slotted-space-3",
656
670
  "--slotted-space-4",
657
671
  "--slotted-space-5",
658
672
  "--slotted-space-6",
673
+ "--slotted-space-9",
674
+ "--slotted-splitter-line-active-color",
675
+ "--slotted-splitter-line-color",
659
676
  "--slotted-surface",
660
677
  "--slotted-surface-sunken",
661
678
  "--slotted-target-min",
@@ -104,6 +104,8 @@ export default function AppShellBasic() {
104
104
  | `progress` | div, holding one ProgressBar at placement="edge-start" | no |
105
105
  | `aside` | aside, or the element render returns | no |
106
106
  | `aside-resizer` | div with role="separator", or the element render returns | no |
107
+ | `line` | span inside the aside-resizer, aria-hidden | no |
108
+ | `grip` | span inside the aside-resizer, aria-hidden | no |
107
109
  | `aside-header` | div | no |
108
110
  | `aside-body` | div | no |
109
111
  | `aside-footer` | div | no |
@@ -193,7 +195,7 @@ export default function AppShellBasic() {
193
195
 
194
196
  ## Tokens
195
197
 
196
- `--slotted-app-shell-aside-color`, `--slotted-app-shell-aside-extent`, `--slotted-app-shell-aside-size-lg`, `--slotted-app-shell-aside-size-md`, `--slotted-app-shell-aside-size-sm`, `--slotted-app-shell-aside-surface`, `--slotted-app-shell-banner-block-size`, `--slotted-app-shell-banner-color`, `--slotted-app-shell-banner-surface`, `--slotted-app-shell-border-color`, `--slotted-app-shell-brand-overflow`, `--slotted-app-shell-brand-wrap`, `--slotted-app-shell-canvas`, `--slotted-app-shell-color`, `--slotted-app-shell-elevation`, `--slotted-app-shell-footer-color`, `--slotted-app-shell-footer-surface`, `--slotted-app-shell-frame`, `--slotted-app-shell-frame-image`, `--slotted-app-shell-gutter`, `--slotted-app-shell-main-color`, `--slotted-app-shell-main-surface`, `--slotted-app-shell-nav-color`, `--slotted-app-shell-nav-overlay-size`, `--slotted-app-shell-nav-size-lg`, `--slotted-app-shell-nav-size-md`, `--slotted-app-shell-nav-size-sm`, `--slotted-app-shell-nav-surface`, `--slotted-app-shell-radius`, `--slotted-app-shell-rail-size`, `--slotted-app-shell-resizer-color`, `--slotted-app-shell-row-inset-size`, `--slotted-app-shell-row-mark-size`, `--slotted-app-shell-row-text-line-height`, `--slotted-app-shell-row-text-size`, `--slotted-app-shell-scrim`, `--slotted-app-shell-scrollbar-thumb-color`, `--slotted-app-shell-scrollbar-track-color`, `--slotted-app-shell-tone-surface`, `--slotted-border-strong`, `--slotted-border-subtle`, `--slotted-border-width-thick`, `--slotted-border-width-thin`, `--slotted-control-font-size-md`, `--slotted-control-font-size-sm`, `--slotted-control-gap-lg`, `--slotted-control-gap-md`, `--slotted-control-gap-sm`, `--slotted-control-height-lg`, `--slotted-control-height-md`, `--slotted-control-icon-size-md`, `--slotted-control-radius`, `--slotted-control-transition-duration`, `--slotted-control-transition-easing`, `--slotted-duration-medium`, `--slotted-easing-enter`, `--slotted-easing-exit`, `--slotted-easing-standard`, `--slotted-focus-ring-color`, `--slotted-focus-ring-offset`, `--slotted-focus-ring-width`, `--slotted-font-family-sans`, `--slotted-font-size-sm`, `--slotted-font-weight-medium`, `--slotted-font-weight-semibold`, `--slotted-line-height-sm`, `--slotted-radius-lg`, `--slotted-scrim`, `--slotted-shadow-lg`, `--slotted-shadow-md`, `--slotted-shadow-xs`, `--slotted-space-1`, `--slotted-space-2`, `--slotted-space-3`, `--slotted-space-4`, `--slotted-space-5`, `--slotted-space-6`, `--slotted-surface`, `--slotted-surface-sunken`, `--slotted-target-min`, `--slotted-text`, `--slotted-text-muted`, `--slotted-tone-secondary-subtle-active`, `--slotted-tone-secondary-subtle-hover`, `--slotted-z-index-overlay`, `--slotted-z-index-popover`
198
+ `--slotted-app-shell-aside-color`, `--slotted-app-shell-aside-extent`, `--slotted-app-shell-aside-size-lg`, `--slotted-app-shell-aside-size-md`, `--slotted-app-shell-aside-size-sm`, `--slotted-app-shell-aside-surface`, `--slotted-app-shell-banner-block-size`, `--slotted-app-shell-banner-color`, `--slotted-app-shell-banner-surface`, `--slotted-app-shell-border-color`, `--slotted-app-shell-brand-overflow`, `--slotted-app-shell-brand-wrap`, `--slotted-app-shell-canvas`, `--slotted-app-shell-color`, `--slotted-app-shell-elevation`, `--slotted-app-shell-footer-color`, `--slotted-app-shell-footer-surface`, `--slotted-app-shell-frame`, `--slotted-app-shell-frame-image`, `--slotted-app-shell-gutter`, `--slotted-app-shell-main-color`, `--slotted-app-shell-main-surface`, `--slotted-app-shell-nav-color`, `--slotted-app-shell-nav-overlay-size`, `--slotted-app-shell-nav-size-lg`, `--slotted-app-shell-nav-size-md`, `--slotted-app-shell-nav-size-sm`, `--slotted-app-shell-nav-surface`, `--slotted-app-shell-radius`, `--slotted-app-shell-rail-size`, `--slotted-app-shell-row-inset-size`, `--slotted-app-shell-row-mark-size`, `--slotted-app-shell-row-text-line-height`, `--slotted-app-shell-row-text-size`, `--slotted-app-shell-scrim`, `--slotted-app-shell-scrollbar-thumb-color`, `--slotted-app-shell-scrollbar-track-color`, `--slotted-app-shell-tone-surface`, `--slotted-border-strong`, `--slotted-border-subtle`, `--slotted-border-width-thin`, `--slotted-control-font-size-md`, `--slotted-control-font-size-sm`, `--slotted-control-gap-lg`, `--slotted-control-gap-md`, `--slotted-control-gap-sm`, `--slotted-control-height-lg`, `--slotted-control-height-md`, `--slotted-control-icon-size-md`, `--slotted-control-radius`, `--slotted-control-transition-duration`, `--slotted-control-transition-easing`, `--slotted-duration-medium`, `--slotted-easing-enter`, `--slotted-easing-exit`, `--slotted-easing-standard`, `--slotted-focus-ring-color`, `--slotted-focus-ring-offset`, `--slotted-focus-ring-width`, `--slotted-font-family-sans`, `--slotted-font-size-sm`, `--slotted-font-weight-medium`, `--slotted-font-weight-semibold`, `--slotted-line-height-sm`, `--slotted-radius-lg`, `--slotted-radius-sm`, `--slotted-scrim`, `--slotted-shadow-lg`, `--slotted-shadow-md`, `--slotted-shadow-xs`, `--slotted-space-1`, `--slotted-space-12`, `--slotted-space-2`, `--slotted-space-3`, `--slotted-space-4`, `--slotted-space-5`, `--slotted-space-6`, `--slotted-space-9`, `--slotted-splitter-line-active-color`, `--slotted-splitter-line-color`, `--slotted-surface`, `--slotted-surface-sunken`, `--slotted-target-min`, `--slotted-text`, `--slotted-text-muted`, `--slotted-tone-secondary-subtle-active`, `--slotted-tone-secondary-subtle-hover`, `--slotted-z-index-overlay`, `--slotted-z-index-popover`
197
199
 
198
200
  ## Examples
199
201
 
@@ -30,6 +30,7 @@
30
30
  "columns": "1",
31
31
  "variant": "plain",
32
32
  "termWidth": "14rem",
33
+ "minColumnWidth": "md",
33
34
  "span": 1,
34
35
  "clamp": 0,
35
36
  "copy": false,
@@ -161,6 +162,13 @@
161
162
  "appliesTo": "DescriptionList",
162
163
  "description": "Nothing between pairs, a rule between them, or a framed table"
163
164
  },
165
+ {
166
+ "name": "minColumnWidth",
167
+ "type": "'sm' | 'md'",
168
+ "defaultValue": "md",
169
+ "appliesTo": "DescriptionList",
170
+ "description": "The narrowest column before the count folds: md holds two columns to 34rem of the list and three to 48rem; sm holds two to 25rem and three to 37.5rem"
171
+ },
164
172
  {
165
173
  "name": "termWidth",
166
174
  "type": "string",
@@ -256,10 +264,10 @@
256
264
  },
257
265
  {
258
266
  "name": "DescriptionListDefaultsProvider",
259
- "type": "layout | columns | variant | termWidth",
267
+ "type": "layout | columns | variant | termWidth | minColumnWidth",
260
268
  "defaultValue": "—",
261
269
  "appliesTo": "Application",
262
- "description": "Sets those four once for everything below it; a prop on the list still wins"
270
+ "description": "Sets those five once for everything below it; a prop on the list still wins"
263
271
  },
264
272
  {
265
273
  "name": "children",