@jonmilner/ui 0.23.9 → 0.24.0

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.
@@ -1,2 +1,2 @@
1
1
  @layer tokens, reset, atoms.base, atoms.sm, atoms.med, atoms.lg, atoms.xl, components.box, components.checkbox, components.clickable, components.clickable-box, components.flex, components.icon, components.icon-button, components.inline, components.sidebar, components.sidebar-layout, components.stack, components.text, components.alert, components.avatar, components.badge, components.body, components.button, components.caption, components.chip, components.code, components.field, components.color-field, components.combobox, components.heading, components.dialog, components.alert-dialog, components.label, components.menu, components.multiselect, components.number-field, components.popover, components.radio-group, components.search-field, components.select, components.switch, components.tabs, components.tag, components.text-field, components.textarea, components.toast, components.tooltip, components.visually-hidden, components.nav-list, components.table, components.markdown;
2
- @layer components.menu{._393eil0{border:var(--space-1) solid var(--color-border);max-inline-size:var(--available-width);transform-origin:var(--transform-origin);transition:opacity var(--duration-fast) var(--easing-standard), scale var(--duration-fast) var(--easing-enter)}._393eil0:focus-visible{outline:var(--space-2) solid var(--color-focus);outline-offset:var(--space-2)}._393eil0[data-starting-style],._393eil0[data-ending-style]{opacity:0;scale:calc(1 - var(--scale-med))}._393eil1{cursor:pointer;touch-action:manipulation;-webkit-tap-highlight-color:transparent;-webkit-user-select:none;user-select:none}._393eil1:focus-visible{outline:var(--space-2) solid var(--color-focus);outline-offset:calc(-1 * var(--space-2))}._393eil1[data-highlighted],._393eil1[data-popup-open]{background-color:light-dark(var(--color-bg-muted),color-mix(in srgb, var(--color-fg) 10%, var(--color-bg-raised)))}._393eil1[aria-disabled=true]{color:var(--color-fg-muted);cursor:not-allowed}._393eil3{margin-block:calc(-1 * var(--font-size-sm))}._393eil4{scale:var(--dir) 1}._393eil5{text-decoration:none}._393eil6{border-block-start-color:var(--color-border)}._393eil6:before{content:"";border-block-start:var(--space-1) solid;border-block-start-color:inherit;display:block}@media (forced-colors:active){._393eil1[data-highlighted]:not([aria-disabled=true]),._393eil1[data-popup-open]:not([aria-disabled=true]){forced-color-adjust:none;color:highlighttext;background-color:highlight}._393eil1[data-highlighted]:not([aria-disabled=true]):focus-visible{color:canvastext;background-color:canvas}._393eil1[aria-disabled=true]{color:graytext}._393eil2{color:inherit}}}
2
+ @layer components.menu{._393eil0{border:var(--space-1) solid var(--color-border);max-inline-size:var(--available-width);transform-origin:var(--transform-origin);transition:opacity var(--duration-fast) var(--easing-standard), scale var(--duration-fast) var(--easing-enter)}._393eil0:focus-visible{outline:var(--space-2) solid var(--color-focus);outline-offset:var(--space-2)}._393eil0[data-starting-style],._393eil0[data-ending-style]{opacity:0;scale:calc(1 - var(--scale-med))}._393eil1{cursor:pointer;touch-action:manipulation;-webkit-tap-highlight-color:transparent;-webkit-user-select:none;user-select:none}._393eil1:focus-visible{outline:var(--space-2) solid var(--color-focus);outline-offset:calc(-1 * var(--space-2))}._393eil1[data-highlighted],._393eil1[data-popup-open]{background-color:light-dark(var(--color-bg-muted),color-mix(in srgb, var(--color-fg) 10%, var(--color-bg-raised)))}._393eil1[aria-disabled=true]{color:var(--color-fg-muted);cursor:not-allowed}._393eil3{margin-block:calc(-1 * var(--font-size-sm))}._393eil4{scale:var(--dir) 1}._393eil5{text-decoration:none}._393eil6{border-block-start:var(--space-1) solid var(--color-border)}@media (forced-colors:active){._393eil1[data-highlighted]:not([aria-disabled=true]),._393eil1[data-popup-open]:not([aria-disabled=true]){forced-color-adjust:none;color:highlighttext;background-color:highlight}._393eil1[data-highlighted]:not([aria-disabled=true]):focus-visible{color:canvastext;background-color:canvas}._393eil1[aria-disabled=true]{color:graytext}._393eil2{color:inherit}}}@layer reset{._393eil7{gap:inherit}}
@@ -3,5 +3,5 @@ import "./Menu.css";
3
3
  /* empty css */
4
4
  /* empty css */
5
5
  // src/Menu/Menu.css.ts
6
- var e = "_393eil0", t = "_393eil1", n = "_393eil2", r = "_393eil3", i = "_393eil4", a = "_393eil5", o = "_393eil6";
7
- export { n as description, r as icon, t as item, a as linkItem, e as popup, o as separator, i as submenuChevron };
6
+ var e = "_393eil0", t = "_393eil1", n = "_393eil2", r = "_393eil3", i = "_393eil4", a = "_393eil5", o = "_393eil6", s = "_393eil7";
7
+ export { n as description, s as group, r as icon, t as item, a as linkItem, e as popup, o as separator, i as submenuChevron };
@@ -30,13 +30,13 @@ export type MenuSubmenuRootProps = Pick<Menu$1.SubmenuRoot.Props, "open" | "defa
30
30
  };
31
31
  export type MenuSubmenuTriggerProps = Omit<PartProps<Menu$1.SubmenuTrigger.Props>, "nativeButton" | "disabled"> & Pick<IconSlotProps, "iconStart"> & ItemDescription;
32
32
  declare function MenuRoot(props: MenuProps): import("react").JSX.Element;
33
- declare function MenuPopup({ side, align, backgroundColor, borderRadius, boxShadow, padding, className, style, ...props }: MenuPopupProps): import("react").JSX.Element;
33
+ declare function MenuPopup({ side, align, backgroundColor, borderRadius, boxShadow, padding, display, flexDirection, gap, className, style, ...props }: MenuPopupProps): import("react").JSX.Element;
34
34
  declare function MenuItem({ variant, description, iconStart, iconEnd, display, minBlockSize, paddingInline, borderRadius, color, className, style, children, ...props }: MenuItemProps): import("react").JSX.Element;
35
35
  declare function MenuLinkItem({ href, disabled, closeOnClick, onClick, description, iconStart, iconEnd, display, minBlockSize, paddingInline, borderRadius, color, className, style, children, ...props }: MenuLinkItemProps): import("react").JSX.Element;
36
36
  declare function MenuSubmenuRoot(props: MenuSubmenuRootProps): import("react").JSX.Element;
37
37
  declare function MenuSubmenuTrigger({ description, iconStart, display, minBlockSize, paddingInline, borderRadius, color, className, style, ref, children, ...props }: MenuSubmenuTriggerProps): import("react").JSX.Element;
38
- declare function MenuSeparator({ paddingBlock, paddingInline, className, style, ...props }: MenuSeparatorProps): import("react").JSX.Element;
39
- declare function MenuGroup({ label, className, style, children, ...props }: MenuGroupProps): import("react").JSX.Element;
38
+ declare function MenuSeparator({ alignSelf, className, style, ...props }: MenuSeparatorProps): import("react").JSX.Element;
39
+ declare function MenuGroup({ label, display, flexDirection, className, style, children, ...props }: MenuGroupProps): import("react").JSX.Element;
40
40
  export declare const Menu: typeof MenuRoot & {
41
41
  Trigger: typeof MenuTrigger;
42
42
  Popup: typeof MenuPopup;
@@ -6,41 +6,44 @@ import { splitStyleProps as i } from "../styles/split-style-props.mjs";
6
6
  import { Text as a } from "../Text/index.mjs";
7
7
  import { MenuItemPart as o, MenuLinkItemPart as s, MenuPortal as c, MenuPositioner as l, MenuRootScope as u, MenuSubmenuRootScope as d, MenuSubmenuTriggerPart as f, MenuTrigger as p } from "./client.mjs";
8
8
  import { itemChildren as m, itemLayout as h } from "./item-row.mjs";
9
- import { item as g, linkItem as _, popup as v, separator as y, submenuChevron as b } from "./Menu.css.mjs";
10
- import { jsx as x, jsxs as S } from "react/jsx-runtime";
11
- import { Menu as C } from "@base-ui/react/menu";
9
+ import { group as g, item as _, linkItem as v, popup as y, separator as b, submenuChevron as x } from "./Menu.css.mjs";
10
+ import { jsx as S, jsxs as C } from "react/jsx-runtime";
11
+ import { Menu as w } from "@base-ui/react/menu";
12
12
  // src/Menu/index.tsx
13
- function w(e) {
14
- return /* @__PURE__ */ x(u, { ...e });
13
+ function T(e) {
14
+ return /* @__PURE__ */ S(u, { ...e });
15
15
  }
16
- function T({ side: t, align: n = "start", backgroundColor: a = "bgRaised", borderRadius: o = "med", boxShadow: s = "med", padding: u = "4", className: d, style: f, ...p }) {
17
- let [m, h] = i(p);
18
- return /* @__PURE__ */ x(c, { children: /* @__PURE__ */ x(l, {
16
+ function E({ side: t, align: n = "start", backgroundColor: a = "bgRaised", borderRadius: o = "med", boxShadow: s = "med", padding: u = "4", display: d = "flex", flexDirection: f = "column", gap: p = "4", className: m, style: h, ...g }) {
17
+ let [_, v] = i(g);
18
+ return /* @__PURE__ */ S(c, { children: /* @__PURE__ */ S(l, {
19
19
  align: n,
20
- finalFocus: h.finalFocus !== void 0 && h.finalFocus !== !0,
20
+ finalFocus: v.finalFocus !== void 0 && v.finalFocus !== !0,
21
21
  side: t,
22
- children: /* @__PURE__ */ x(C.Popup, {
23
- ...h,
24
- render: /* @__PURE__ */ x(e, {
22
+ children: /* @__PURE__ */ S(w.Popup, {
23
+ ...v,
24
+ render: /* @__PURE__ */ S(e, {
25
25
  backgroundColor: a,
26
26
  borderRadius: o,
27
27
  boxShadow: s,
28
28
  padding: u,
29
- ...m,
30
- className: r(v, d),
31
- style: f
29
+ display: d,
30
+ flexDirection: f,
31
+ gap: p,
32
+ ..._,
33
+ className: r(y, m),
34
+ style: h
32
35
  })
33
36
  })
34
37
  }) });
35
38
  }
36
- var E = (e) => e == null || e === !1 || e === "" ? void 0 : e, D = (e, t) => t !== void 0 && (typeof e == "string" || typeof e == "number") ? String(e) : void 0;
37
- function O({ variant: t = "neutral", description: n, iconStart: a, iconEnd: s, display: c = "flex", minBlockSize: l = "sm", paddingInline: u = "12", borderRadius: d = "xs", color: f = t === "danger" ? "danger" : "fg", className: p, style: _, children: v, ...y }) {
38
- let [b, S] = i(y), C = E(n);
39
- return /* @__PURE__ */ x(o, {
40
- label: D(v, C),
41
- ...S,
39
+ var D = (e) => e == null || e === !1 || e === "" ? void 0 : e, O = (e, t) => t !== void 0 && (typeof e == "string" || typeof e == "number") ? String(e) : void 0;
40
+ function k({ variant: t = "neutral", description: n, iconStart: a, iconEnd: s, display: c = "flex", minBlockSize: l = "sm", paddingInline: u = "12", borderRadius: d = "xs", color: f = t === "danger" ? "danger" : "fg", className: p, style: g, children: v, ...y }) {
41
+ let [b, x] = i(y), C = D(n);
42
+ return /* @__PURE__ */ S(o, {
43
+ label: O(v, C),
44
+ ...x,
42
45
  description: C,
43
- render: /* @__PURE__ */ x(e, {
46
+ render: /* @__PURE__ */ S(e, {
44
47
  ...h(C !== void 0),
45
48
  display: c,
46
49
  minBlockSize: l,
@@ -48,8 +51,8 @@ function O({ variant: t = "neutral", description: n, iconStart: a, iconEnd: s, d
48
51
  borderRadius: d,
49
52
  color: f,
50
53
  ...b,
51
- className: r(g, p),
52
- style: _
54
+ className: r(_, p),
55
+ style: g
53
56
  }),
54
57
  children: m(v, {
55
58
  iconStart: a,
@@ -57,27 +60,27 @@ function O({ variant: t = "neutral", description: n, iconStart: a, iconEnd: s, d
57
60
  })
58
61
  });
59
62
  }
60
- function k({ href: t, disabled: n = !1, closeOnClick: a = !0, onClick: o, description: c, iconStart: l, iconEnd: u, display: d = "flex", minBlockSize: f = "sm", paddingInline: p = "12", borderRadius: v = "xs", color: y = "fg", className: b, style: S, children: C, ...w }) {
61
- let [T, O] = i(w), k = E(c);
62
- return /* @__PURE__ */ x(s, {
63
- label: D(C, k),
64
- ...O,
63
+ function A({ href: t, disabled: n = !1, closeOnClick: a = !0, onClick: o, description: c, iconStart: l, iconEnd: u, display: d = "flex", minBlockSize: f = "sm", paddingInline: p = "12", borderRadius: g = "xs", color: y = "fg", className: b, style: x, children: C, ...w }) {
64
+ let [T, E] = i(w), k = D(c);
65
+ return /* @__PURE__ */ S(s, {
66
+ label: O(C, k),
67
+ ...E,
65
68
  "aria-disabled": n || void 0,
66
69
  closeOnClick: !n && a,
67
70
  description: k,
68
71
  href: n ? void 0 : t,
69
72
  onClick: n ? void 0 : o,
70
- render: /* @__PURE__ */ x(e, {
73
+ render: /* @__PURE__ */ S(e, {
71
74
  as: "a",
72
75
  ...h(k !== void 0),
73
76
  display: d,
74
77
  minBlockSize: f,
75
78
  paddingInline: p,
76
- borderRadius: v,
79
+ borderRadius: g,
77
80
  color: y,
78
81
  ...T,
79
- className: r(g, _, b),
80
- style: S
82
+ className: r(_, v, b),
83
+ style: x
81
84
  }),
82
85
  children: m(C, {
83
86
  iconStart: l,
@@ -85,64 +88,65 @@ function k({ href: t, disabled: n = !1, closeOnClick: a = !0, onClick: o, descri
85
88
  })
86
89
  });
87
90
  }
88
- function A(e) {
89
- return /* @__PURE__ */ x(d, { ...e });
91
+ function j(e) {
92
+ return /* @__PURE__ */ S(d, { ...e });
90
93
  }
91
- var j = n({ marginInlineStart: "auto" });
92
- function M({ className: e, ...n }) {
93
- return /* @__PURE__ */ x(t, {
94
+ var M = n({ marginInlineStart: "auto" });
95
+ function N({ className: e, ...n }) {
96
+ return /* @__PURE__ */ S(t, {
94
97
  ...n,
95
- className: r(b, j, e)
98
+ className: r(x, M, e)
96
99
  });
97
100
  }
98
- function N({ description: t, iconStart: n, display: a = "flex", minBlockSize: o = "sm", paddingInline: s = "12", borderRadius: c = "xs", color: l = "fg", className: u, style: d, ref: p, children: _, ...v }) {
99
- let [y, b] = i(v), S = E(t);
100
- return /* @__PURE__ */ x(f, {
101
- label: D(_, S),
101
+ function P({ description: t, iconStart: n, display: a = "flex", minBlockSize: o = "sm", paddingInline: s = "12", borderRadius: c = "xs", color: l = "fg", className: u, style: d, ref: p, children: g, ...v }) {
102
+ let [y, b] = i(v), x = D(t);
103
+ return /* @__PURE__ */ S(f, {
104
+ label: O(g, x),
102
105
  ...b,
103
- description: S,
104
- render: /* @__PURE__ */ x(e, {
105
- ...h(S !== void 0),
106
+ description: x,
107
+ render: /* @__PURE__ */ S(e, {
108
+ ...h(x !== void 0),
106
109
  display: a,
107
110
  minBlockSize: o,
108
111
  paddingInline: s,
109
112
  borderRadius: c,
110
113
  color: l,
111
114
  ...y,
112
- className: r(g, u),
115
+ className: r(_, u),
113
116
  ref: p,
114
117
  style: d
115
118
  }),
116
- children: m(_, {
119
+ children: m(g, {
117
120
  iconStart: n,
118
- iconEnd: M
121
+ iconEnd: N
119
122
  })
120
123
  });
121
124
  }
122
- function P({ paddingBlock: t = "4", paddingInline: n = "8", className: a, style: o, ...s }) {
123
- let [c, l] = i(s);
124
- return /* @__PURE__ */ x(C.Separator, {
125
- ...l,
126
- render: /* @__PURE__ */ x(e, {
127
- paddingBlock: t,
128
- paddingInline: n,
129
- ...c,
130
- className: r(y, a),
131
- style: o
125
+ function F({ alignSelf: t = "stretch", className: n, style: a, ...o }) {
126
+ let [s, c] = i(o);
127
+ return /* @__PURE__ */ S(w.Separator, {
128
+ ...c,
129
+ render: /* @__PURE__ */ S(e, {
130
+ alignSelf: t,
131
+ ...s,
132
+ className: r(b, n),
133
+ style: a
132
134
  })
133
135
  });
134
136
  }
135
- function F({ label: t, className: n, style: r, children: o, ...s }) {
136
- let [c, l] = i(s);
137
- return /* @__PURE__ */ S(C.Group, {
138
- ...l,
139
- render: /* @__PURE__ */ x(e, {
140
- ...c,
141
- className: n,
142
- style: r
137
+ function I({ label: t, display: n = "flex", flexDirection: o = "column", className: s, style: c, children: l, ...u }) {
138
+ let [d, f] = i(u);
139
+ return /* @__PURE__ */ C(w.Group, {
140
+ ...f,
141
+ render: /* @__PURE__ */ S(e, {
142
+ display: n,
143
+ flexDirection: o,
144
+ ...d,
145
+ className: r(g, s),
146
+ style: c
143
147
  }),
144
- children: [/* @__PURE__ */ x(C.GroupLabel, {
145
- render: /* @__PURE__ */ x(a, {
148
+ children: [/* @__PURE__ */ S(w.GroupLabel, {
149
+ render: /* @__PURE__ */ S(a, {
146
150
  as: "div",
147
151
  color: "fgMuted",
148
152
  font: "label",
@@ -151,17 +155,17 @@ function F({ label: t, className: n, style: r, children: o, ...s }) {
151
155
  size: "xs"
152
156
  }),
153
157
  children: t
154
- }), o]
158
+ }), l]
155
159
  });
156
160
  }
157
- var I = Object.assign(w, {
161
+ var L = Object.assign(T, {
158
162
  Trigger: p,
159
- Popup: T,
160
- Item: O,
161
- LinkItem: k,
162
- Separator: P,
163
- Group: F,
164
- SubmenuRoot: A,
165
- SubmenuTrigger: N
163
+ Popup: E,
164
+ Item: k,
165
+ LinkItem: A,
166
+ Separator: F,
167
+ Group: I,
168
+ SubmenuRoot: j,
169
+ SubmenuTrigger: P
166
170
  });
167
- export { I as Menu };
171
+ export { L as Menu };
package/dist/docs/Menu.md CHANGED
@@ -29,7 +29,7 @@ A list of actions that opens from a button: a row's "Edit, Duplicate, Delete", a
29
29
  - `disabled` on an item renders `aria-disabled`: it stays announced and reachable with the arrow keys, and does nothing. A disabled `Menu.LinkItem` also drops its `href`, so no click or context menu reaches the URL. On the trigger it keeps the button focusable and stops it opening.
30
30
  - `description` on `Menu.Item` or `Menu.LinkItem` puts a short line of muted text below the label, such as why a disabled item cannot act ("Already running"). The item grows to fit both lines. Put secondary text there, never as a second line in the children, which overlaps the label and joins its name.
31
31
  - `Menu.Group` takes a `label` that is shown and names the group. Separate groups with `Menu.Separator`.
32
- - `Menu.Separator` draws a line inside its own padding (`paddingBlock="4"`, `paddingInline="8"`) and sets no margin. Change its spacing with `paddingBlock` and `paddingInline` (the `padding` shorthand loses to these defaults, decision 0065); a `margin*` prop adds space outside the padding. `style={{ borderBlockStartColor }}` recolours the line.
32
+ - `Menu.Popup` lays its parts out in a column with `gap="4"`, and each `Menu.Group` lays out its label and items the same way with the popup's gap. These are default style props, so `gap` and `display` restyle them, and a `gap` on the popup spaces its groups' items too. `Menu.Separator` is its 1px line and nothing else: no margin or padding (decision 0198), as wide as the items, with the gap above and below it. `style={{ borderBlockStartColor }}` recolours the line.
33
33
  - The popup portals into the trigger's nearest `ThemeProvider`, so it keeps the brand and mode. That provider must not clip or stack its content: wrap the app root, and keep a nested provider off elements with `overflow: hidden`, a `transform` or their own `z-index`, or the popup is clipped or drawn under siblings. It sits on `zIndex` `popover`. A menu opened only through `open`, with no `Menu.Trigger`, has no provider to find and portals to `<body>`.
34
34
  - Item and link item text is wrapped in `Text` (`label`, `sm`) for you. `iconStart` and `iconEnd` take an icon component (`iconStart={PencilIcon}`), rendered at the label's size, 4px from it and centred on its cap height, as on Button, Badge and Tag (ADR 0152); the item is as tall as without them. With a `description` they stay on the label's line. Never put an icon in the children: they are the label only.
35
35
  - `side` (`bottom` by default, `inline-end` for a submenu's popup) and `align` (`start`) place the popup against the trigger; it flips when it would overflow the viewport.
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "$schema": "./manifest.schema.json",
3
3
  "package": "@jonmilner/ui",
4
- "version": "0.23.9",
4
+ "version": "0.24.0",
5
5
  "components": [
6
6
  {
7
7
  "name": "Alert",
@@ -0,0 +1,38 @@
1
+ # 0.24.0
2
+
3
+ `Menu.Separator` drops its default `paddingBlock="4"` and `paddingInline="8"`, because a component owns no whitespace outside its visible edge (decision 0198). The separator is now just its 1px line: a block-start border on an empty box. `Menu.Popup` now lays out its parts in a column with `gap="4"`, and each `Menu.Group` lays out its label and items the same way with the popup's gap, so the separator keeps 4px above and below. Three things look different: the line now runs the items' full width instead of stopping 8px short of each side, items sit 4px apart, and a group's label gains 4px more space below it. A separator that passed spacing props, or a `className` or `style` that restyled it, needs a change.
4
+
5
+ ## Find
6
+
7
+ In the app's source (`*.tsx`), every `Menu.Separator` that passes any prop: regex `<Menu\.Separator\s+[^/>\s]` searched multiline (`rg -U`), since a long tag's props sit on their own lines. A bare `<Menu.Separator />` needs nothing. Check each match for `padding*` and `margin*` props and for a `className` or `style` that sets padding, margin, or the line's border or `::before`. A match with props spread from elsewhere (`<Menu.Separator {...props} />`) needs a read of where they come from.
8
+
9
+ In the app's styles (`*.css.ts`, `*.css`), any rule for a separator's `::before`: regex `::before` near `separator`. From 0.5.0 to 0.23.x the line was the separator's `::before`.
10
+
11
+ In the app's source, every `Menu.Popup` or `Menu.Group` that holds something other than items, groups and separators (a custom header, footer or wrapper), or items given their own `margin*` or `padding*` to space them: regex `<Menu\.(Popup|Group)\b` searched multiline, then read each match's children. Each child now gets 4px between it and the next.
12
+
13
+ In the app's visual tests, every baseline that shows an open menu.
14
+
15
+ ## Replace
16
+
17
+ Drop `padding*` and `margin*` props from the separator. The space around it is now the popup's or group's `gap`. For more space around a separator, split the menu into `Menu.Group`s, or pass a larger `gap` to the `Menu.Popup`. Its groups take the same gap, so it spaces every item too. A `gap` on one `Menu.Group` spaces only that group. Drop the `margin*` or `padding*` that a custom child or item used to space itself: the gap spaces it now.
18
+
19
+ ```tsx
20
+ // before: 8px above and below
21
+ <Menu.Separator paddingBlock="8" />
22
+ // after: the popup spaces every part 8px apart
23
+ <Menu.Popup gap="8">
24
+ …
25
+ <Menu.Separator />
26
+ </Menu.Popup>
27
+
28
+ // before: a full-width line
29
+ <Menu.Separator paddingInline="0" />
30
+ // after: the line is full width by default
31
+ <Menu.Separator />
32
+ ```
33
+
34
+ A `className` that restyled the line through `::before` (`.myDivider::before { border-block-start-width: 2px }`) now targets the separator itself (`.myDivider { border-block-start-width: 2px }`). Its colour still comes from `borderBlockStartColor` on the separator. Update the visual baselines for open menus.
35
+
36
+ ## Verify
37
+
38
+ Run `rg -U '<Menu\.Separator\s+[^/>\s]' --glob '*.tsx'` again: no match passes a `padding*` or `margin*` prop, and no style targets a separator's `::before`. Then open a menu with a separator: the line has 4px above and below and runs the items' width.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@jonmilner/ui",
3
- "version": "0.23.9",
3
+ "version": "0.24.0",
4
4
  "bin": {
5
5
  "ui-doctor": "./dist/cli/ui-doctor.mjs"
6
6
  },