@jonmilner/ui 0.20.0 → 0.21.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.
- package/dist/ColorField/ColorField.css +1 -1
- package/dist/Combobox/Combobox.css +1 -1
- package/dist/NavList/NavList.css +1 -1
- package/dist/NavList/NavList.css.mjs +2 -2
- package/dist/NavList/index.d.mts +2 -1
- package/dist/NavList/index.mjs +72 -64
- package/dist/NumberField/NumberField.css +1 -1
- package/dist/NumberField/index.mjs +2 -0
- package/dist/SearchField/SearchField.css +1 -1
- package/dist/SearchField/client.mjs +1 -0
- package/dist/Tag/Tag.css +1 -1
- package/dist/Tag/Tag.css.mjs +35 -35
- package/dist/Tag/index.mjs +8 -7
- package/dist/Text/Text.css +1 -1
- package/dist/Text/Text.css.mjs +28 -28
- package/dist/Text/index.mjs +5 -5
- package/dist/TextField/TextField.css +1 -1
- package/dist/Textarea/Textarea.css +1 -1
- package/dist/docs/NavList.md +71 -5
- package/dist/docs/Tag.md +1 -1
- package/dist/docs/llms.txt +1 -1
- package/dist/docs/manifest.json +6 -1
- package/dist/docs/migrations/0.21.0.md +42 -0
- package/dist/docs/theming.md +1 -1
- package/dist/popup/listbox-base.mjs +0 -1
- package/package.json +2 -2
|
@@ -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.icon, components.icon-button, components.inline, components.sidebar, components.sidebar-layout, components.stack, components.text, components.avatar, components.badge, components.button, components.chip, components.field, components.color-field, components.combobox, components.heading, components.dialog, components.alert-dialog, components.menu, components.multiselect, components.number-field, 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;
|
|
2
|
-
@layer components.color-field{.nmj5ie0{clip-path:inset(50%);white-space:nowrap;border:0;block-size:1px;inline-size:1px;margin:0;padding:0;position:absolute;overflow:hidden}.nmj5ie1{appearance:none;border-width:var(--space-1);border-style:solid;border-color:var(--color-border-strong);border-radius:var(--radius-
|
|
2
|
+
@layer components.color-field{.nmj5ie0{clip-path:inset(50%);white-space:nowrap;border:0;block-size:1px;inline-size:1px;margin:0;padding:0;position:absolute;overflow:hidden}.nmj5ie1{appearance:none;border-width:var(--space-1);border-style:solid;border-color:var(--color-border-strong);border-radius:var(--radius-sm);background-color:var(--color-bg);inline-size:100%;min-inline-size:0;color:var(--color-fg);grid-area:1/1;padding-block:0}.nmj5ie1::placeholder{color:var(--color-fg-muted);opacity:1}.nmj5ie1:focus-visible{outline:var(--space-2) solid var(--color-focus);outline-offset:var(--space-2)}.nmj5ie1:disabled{background-color:var(--color-bg-muted);color:var(--color-fg-muted);cursor:not-allowed;border-style:dashed}.nmj5ie1[aria-invalid=true]{border-color:var(--color-danger)}.nmj5ie2{block-size:var(--size-xs);padding-inline-start:calc(var(--size-xs) + var(--space-12));padding-inline-end:var(--space-6)}.nmj5ie3{block-size:var(--size-sm);padding-inline-start:calc(var(--size-xs) + var(--space-12));padding-inline-end:var(--space-8)}.nmj5ie4{block-size:var(--size-med);padding-inline-start:calc(var(--size-sm) + var(--space-12));padding-inline-end:var(--space-12)}.nmj5ie5{appearance:none;border-width:var(--space-1);border-style:solid;border-color:var(--color-border-strong);border-radius:var(--radius-xs);cursor:pointer;background-color:#0000;grid-area:1/1;justify-self:start;padding:0;position:relative;inset-inline-start:var(--space-4)}.nmj5ie5::-webkit-color-swatch-wrapper{padding:0}.nmj5ie5::-webkit-color-swatch{border-radius:var(--radius-xs);forced-color-adjust:none;border:none}.nmj5ie5::-moz-color-swatch{border-radius:var(--radius-xs);forced-color-adjust:none;border:none}.nmj5ie5:focus-visible{outline:var(--space-2) solid var(--color-focus);outline-offset:var(--space-2)}.nmj5ie5:disabled{cursor:not-allowed;border-style:dashed}.nmj5ie6,.nmj5ie7{inline-size:var(--size-xs);block-size:var(--size-xs)}.nmj5ie8{inline-size:var(--size-sm);block-size:var(--size-sm)}.nmj5ie9{font-family:var(--font-body);font-size:var(--font-size-xs);line-height:var(--size-xs);color:var(--color-fg-muted);pointer-events:none;grid-area:1/1;justify-self:start;padding-inline-start:calc(var(--size-xs) + var(--space-12))}.nmj5iea{font-family:var(--font-body);font-size:var(--font-size-sm);line-height:var(--size-sm);color:var(--color-fg-muted);pointer-events:none;grid-area:1/1;justify-self:start;padding-inline-start:calc(var(--size-xs) + var(--space-12))}.nmj5ieb{font-family:var(--font-body);font-size:var(--font-size-med);line-height:var(--size-med);color:var(--color-fg-muted);pointer-events:none;grid-area:1/1;justify-self:start;padding-inline-start:calc(var(--size-sm) + var(--space-12))}.nmj5iec{font-family:var(--font-body);font-size:var(--font-size-xs);line-height:var(--size-xs);color:var(--color-fg-muted);pointer-events:none;grid-area:1/1;justify-self:end;padding-inline-end:var(--space-6)}.nmj5ied{font-family:var(--font-body);font-size:var(--font-size-sm);line-height:var(--size-sm);color:var(--color-fg-muted);pointer-events:none;grid-area:1/1;justify-self:end;padding-inline-end:var(--space-8)}.nmj5iee{font-family:var(--font-body);font-size:var(--font-size-med);line-height:var(--size-med);color:var(--color-fg-muted);pointer-events:none;grid-area:1/1;justify-self:end;padding-inline-end:var(--space-12)}.nmj5ief{vertical-align:calc((1cap - var(--font-size-xs)) / 2);display:inline-block}.nmj5ieg{vertical-align:calc((1cap - var(--font-size-sm)) / 2);display:inline-block}.nmj5ieh{vertical-align:calc((1cap - var(--font-size-med)) / 2);display:inline-block}.nmj5iei{padding-inline-start:calc(calc(var(--size-xs) + var(--space-12)) + var(--font-size-xs) + var(--space-4))}.nmj5iej{padding-inline-start:calc(calc(var(--size-xs) + var(--space-12)) + var(--font-size-sm) + var(--space-4))}.nmj5iek{padding-inline-start:calc(calc(var(--size-sm) + var(--space-12)) + var(--font-size-med) + var(--space-8))}.nmj5iel{padding-inline-end:calc(var(--space-6) + var(--font-size-xs) + var(--space-4))}.nmj5iem{padding-inline-end:calc(var(--space-8) + var(--font-size-sm) + var(--space-4))}.nmj5ien{padding-inline-end:calc(var(--space-12) + var(--font-size-med) + var(--space-8))}@media (pointer:coarse){.nmj5ie1,.nmj5ie9,.nmj5iea,.nmj5ieb,.nmj5iec,.nmj5ied,.nmj5iee{font-size:var(--font-size-med)}}@media (forced-colors:active){.nmj5ie1:disabled{color:graytext;border-color:graytext}.nmj5ie5{border-color:canvastext}.nmj5ie5:disabled{border-color:graytext}}}
|
|
@@ -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.icon, components.icon-button, components.inline, components.sidebar, components.sidebar-layout, components.stack, components.text, components.avatar, components.badge, components.button, components.chip, components.field, components.color-field, components.combobox, components.heading, components.dialog, components.alert-dialog, components.menu, components.multiselect, components.number-field, 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;
|
|
2
|
-
@layer components.combobox{.y6b2yi0{clip-path:inset(50%);white-space:nowrap;border:0;block-size:1px;inline-size:1px;margin:0;padding:0;position:absolute;overflow:hidden}.y6b2yi1{text-align:start;border-color:var(--color-border-strong);justify-content:stretch}:where(.y6b2yi1) ._1gwwloa0{flex:auto;justify-items:stretch;min-inline-size:0}:where(.y6b2yi1) ._1gwwloa1{min-inline-size:0}:where(.y6b2yi1) ._1gwwloa2{flex:auto;min-inline-size:0}.y6b2yi2{min-inline-size:0;display:block}.y6b2yi2[data-placeholder]{color:var(--color-fg-muted)}.y6b2yi3{min-inline-size:0;display:grid}.y6b2yi4{grid-area:1/1}.y6b2yi4[aria-hidden=true]{visibility:hidden}.y6b2yi5{grid-area:1/1}.y6b2yi6{border:var(--space-1) solid var(--color-border);min-inline-size:var(--anchor-width);max-block-size:var(--available-height);transform-origin:var(--transform-origin);transition:opacity var(--duration-fast) var(--easing-standard), scale var(--duration-fast) var(--easing-enter);gap:var(--space-4);flex-direction:column;display:flex;overflow:hidden}.y6b2yi6:focus-visible{outline:var(--space-2) solid var(--color-focus);outline-offset:var(--space-2)}.y6b2yi6[data-starting-style],.y6b2yi6[data-ending-style]{opacity:0;scale:calc(1 - var(--scale-med))}.y6b2yi7{appearance:none;border-width:var(--space-1);border-style:solid;border-color:var(--color-border-strong);border-radius:var(--radius-
|
|
2
|
+
@layer components.combobox{.y6b2yi0{clip-path:inset(50%);white-space:nowrap;border:0;block-size:1px;inline-size:1px;margin:0;padding:0;position:absolute;overflow:hidden}.y6b2yi1{text-align:start;border-color:var(--color-border-strong);justify-content:stretch}:where(.y6b2yi1) ._1gwwloa0{flex:auto;justify-items:stretch;min-inline-size:0}:where(.y6b2yi1) ._1gwwloa1{min-inline-size:0}:where(.y6b2yi1) ._1gwwloa2{flex:auto;min-inline-size:0}.y6b2yi2{min-inline-size:0;display:block}.y6b2yi2[data-placeholder]{color:var(--color-fg-muted)}.y6b2yi3{min-inline-size:0;display:grid}.y6b2yi4{grid-area:1/1}.y6b2yi4[aria-hidden=true]{visibility:hidden}.y6b2yi5{grid-area:1/1}.y6b2yi6{border:var(--space-1) solid var(--color-border);min-inline-size:var(--anchor-width);max-block-size:var(--available-height);transform-origin:var(--transform-origin);transition:opacity var(--duration-fast) var(--easing-standard), scale var(--duration-fast) var(--easing-enter);gap:var(--space-4);flex-direction:column;display:flex;overflow:hidden}.y6b2yi6:focus-visible{outline:var(--space-2) solid var(--color-focus);outline-offset:var(--space-2)}.y6b2yi6[data-starting-style],.y6b2yi6[data-ending-style]{opacity:0;scale:calc(1 - var(--scale-med))}.y6b2yi7{appearance:none;border-width:var(--space-1);border-style:solid;border-color:var(--color-border-strong);border-radius:var(--radius-xs);background-color:var(--color-bg);inline-size:100%;min-inline-size:0;color:var(--color-fg);padding-block:0}.y6b2yi7::placeholder{color:var(--color-fg-muted);opacity:1}.y6b2yi7:focus-visible{outline:var(--space-2) solid var(--color-focus);outline-offset:var(--space-2)}.y6b2yi7:disabled{background-color:var(--color-bg-muted);color:var(--color-fg-muted);cursor:not-allowed;border-style:dashed}.y6b2yi7[aria-invalid=true]{border-color:var(--color-danger)}.y6b2yi8{block-size:var(--size-xs);padding-inline:var(--space-6)}.y6b2yi9{block-size:var(--size-sm);padding-inline:var(--space-8)}.y6b2yia{block-size:var(--size-med);padding-inline:var(--space-12)}.y6b2yib:empty{position:absolute}.y6b2yib:not(:empty){padding-block:var(--space-8);padding-inline:var(--space-12)}.y6b2yic{min-block-size:0;overflow-y:auto}.y6b2yid{cursor:pointer;touch-action:manipulation;-webkit-tap-highlight-color:transparent;-webkit-user-select:none;user-select:none}.y6b2yid:focus-visible{outline:var(--space-2) solid var(--color-focus);outline-offset:calc(-1 * var(--space-2))}.y6b2yid[data-highlighted]{background-color:light-dark(var(--color-bg-muted),color-mix(in srgb, var(--color-fg) 10%, var(--color-bg-raised)))}.y6b2yid[aria-disabled=true]{color:var(--color-fg-muted);cursor:not-allowed}.y6b2yie{visibility:hidden;flex-shrink:0}.y6b2yid[aria-selected=true] .y6b2yie{visibility:visible}@media (pointer:coarse){.y6b2yi7{font-size:var(--font-size-med)}}@media (forced-colors:active){.y6b2yi1{--color-fg:CanvasText}.y6b2yi1[aria-disabled=true]{border-color:graytext}.y6b2yi7:disabled{color:graytext;border-color:graytext}.y6b2yid[data-highlighted]{forced-color-adjust:none;color:highlighttext;background-color:highlight}.y6b2yid[data-highlighted]:focus-visible{color:canvastext;background-color:canvas}.y6b2yid[aria-disabled=true]{color:graytext}}@supports (text-box:trim-both cap alphabetic){.y6b2yi4,.y6b2yi5{text-box-trim:trim-both}}}
|
package/dist/NavList/NavList.css
CHANGED
|
@@ -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.icon, components.icon-button, components.inline, components.sidebar, components.sidebar-layout, components.stack, components.text, components.avatar, components.badge, components.button, components.chip, components.field, components.color-field, components.combobox, components.heading, components.dialog, components.alert-dialog, components.menu, components.multiselect, components.number-field, 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;
|
|
2
|
-
@layer components.nav-list{._1kvngp01{padding-inline-start:0;list-style:none}._1kvngp02:not(:first-child),:where(._1kvngp02)+._1kvngp03{padding-block-start:var(--space-16)}.
|
|
2
|
+
@layer components.nav-list{._1kvngp01{padding-inline-start:0;list-style:none}._1kvngp02:not(:first-child),:where(._1kvngp02)+._1kvngp03{padding-block-start:var(--space-16)}._1kvngp04{grid-template-columns:minmax(0, 1fr) auto var(--space-8);display:grid}._1kvngp06{cursor:pointer;touch-action:manipulation;-webkit-tap-highlight-color:transparent;grid-area:1/1/2/-1}._1kvngp06:focus-visible{outline:var(--space-2) solid var(--color-focus);outline-offset:var(--space-2)}._1kvngp07{overflow-wrap:anywhere;min-inline-size:0}._1kvngp04:focus-within ._1kvngp08,._1kvngp04:has([aria-expanded=true]) ._1kvngp08{opacity:0}._1kvngp09{min-inline-size:var(--size-xs);flex-shrink:0;justify-content:flex-end;display:flex}._1kvngp0a{opacity:0;grid-area:1/2;align-self:center;display:flex;position:relative}._1kvngp04:focus-within ._1kvngp0a,._1kvngp04:has([aria-expanded=true]) ._1kvngp0a{opacity:1}._1kvngp0b{position:relative}._1kvngp0c{inline-size:var(--space-6);block-size:var(--space-6);border-radius:var(--radius-full);background-color:var(--color-success);pointer-events:none;box-shadow:0 0 0 calc(var(--space-2) + var(--space-1)) color-mix(in oklch, var(--color-success) 18%, transparent);flex-shrink:0}._1kvngp0d{inline-size:var(--space-6);block-size:var(--space-6);border-radius:var(--radius-full);background-color:var(--color-success);pointer-events:none;box-shadow:0 0 0 var(--space-2) var(--color-bg-panel);flex-shrink:0;display:none;position:absolute;inset-block-start:calc(var(--space-6) / -2);inset-inline-end:calc(var(--space-6) / -2)}@container _1n4s23v1 (inline-size>=0){._1kvngp05{clip-path:inset(50%);white-space:nowrap;border:0;block-size:1px;inline-size:1px;margin:0;padding:0;position:absolute;overflow:hidden}._1kvngp06{--_1kvngp00:1;inline-size:var(--size-med);block-size:var(--size-med);justify-content:center}._1kvngp07,._1kvngp08,._1kvngp09{clip-path:inset(50%);white-space:nowrap;border:0;block-size:1px;inline-size:1px;margin:0;padding:0;position:absolute;overflow:hidden}._1kvngp0a,._1kvngp0c{display:none}._1kvngp0d{display:block}}@media (hover:hover){._1kvngp06:not([aria-current=page]):hover,._1kvngp04:hover>._1kvngp06:not([aria-current=page]){background-image:linear-gradient(color-mix(in srgb, var(--color-fg) 15%, transparent), color-mix(in srgb, var(--color-fg) 15%, transparent))}._1kvngp04:hover ._1kvngp08{opacity:0}._1kvngp04:hover ._1kvngp0a{opacity:1}}@media (forced-colors:active){._1kvngp06:not([aria-current=page]):hover,._1kvngp04:hover>._1kvngp06:not([aria-current=page]){background-image:none}._1kvngp06[aria-current=page]{color:highlighttext;background-color:highlight}._1kvngp0c{forced-color-adjust:none;box-shadow:none;background-color:currentColor}._1kvngp0d{forced-color-adjust:none;box-shadow:0 0 0 var(--space-2) Canvas;background-color:currentColor}}@media (hover:none),(pointer:coarse){._1kvngp04 ._1kvngp08{opacity:0}._1kvngp0a{opacity:1}}}@layer reset{._1kvngp06{color:inherit;text-decoration:none}}
|
|
@@ -5,5 +5,5 @@ import "./NavList.css";
|
|
|
5
5
|
/* empty css */
|
|
6
6
|
/* empty css */
|
|
7
7
|
// src/NavList/NavList.css.ts
|
|
8
|
-
var e = "var(--_1kvngp00)", t = "_1kvngp01", n = "_1kvngp02", r = "_1kvngp03", i = "_1kvngp04", a = "_1kvngp05", o = "_1kvngp06", s = "_1kvngp07", c = "_1kvngp08", l = "_1kvngp09", u = "_1kvngp0a";
|
|
9
|
-
export { u as cornerDot,
|
|
8
|
+
var e = "var(--_1kvngp00)", t = "_1kvngp01", n = "_1kvngp02", r = "_1kvngp03", i = "_1kvngp04", a = "_1kvngp05", o = "_1kvngp06", s = "_1kvngp07", c = "_1kvngp08", l = "_1kvngp09", u = "_1kvngp0a", d = "_1kvngp0b", f = "_1kvngp0c", p = "_1kvngp0d";
|
|
9
|
+
export { u as action, i as actionRow, p as cornerDot, c as count, r as entry, n as group, a as heading, o as item, s as label, d as lead, t as list, f as liveDot, e as railFlag, l as trail };
|
package/dist/NavList/index.d.mts
CHANGED
|
@@ -17,6 +17,7 @@ export type NavListGroupProps = Element<"li", {
|
|
|
17
17
|
label: string;
|
|
18
18
|
}>;
|
|
19
19
|
export type NavListItemOwnProps = {
|
|
20
|
+
action?: ReactNode;
|
|
20
21
|
avatar?: ReactNode;
|
|
21
22
|
count?: ReactNode;
|
|
22
23
|
current?: boolean;
|
|
@@ -32,7 +33,7 @@ type NavListItemLeading = {
|
|
|
32
33
|
export type NavListItemProps<T extends ElementType = "a"> = PolymorphicProps<T, StyleProps & NavListItemOwnProps, "aria-current"> & NavListItemLeading;
|
|
33
34
|
declare function NavListRoot({ children, ...props }: NavListProps): import("react").JSX.Element;
|
|
34
35
|
declare function NavListGroup({ label, headingLevel, display, flexDirection, gap, className, children, ...props }: NavListGroupProps): import("react").JSX.Element;
|
|
35
|
-
declare function NavListItem<T extends ElementType = "a">({ as, current, icon: ItemIcon, avatar, count, live, liveLabel, display, alignItems, gap, position, minBlockSize, paddingBlock, paddingInline, borderRadius, backgroundColor, color, className, children, ...props }: NavListItemProps<T>): import("react").JSX.Element;
|
|
36
|
+
declare function NavListItem<T extends ElementType = "a">({ as, current, icon: ItemIcon, avatar, action, count, live, liveLabel, display, alignItems, gap, position, minBlockSize, paddingBlock, paddingInline, borderRadius, backgroundColor, color, className, children, ...props }: NavListItemProps<T>): import("react").JSX.Element;
|
|
36
37
|
export declare const NavList: typeof NavListRoot & {
|
|
37
38
|
Group: typeof NavListGroup;
|
|
38
39
|
Item: typeof NavListItem;
|
package/dist/NavList/index.mjs
CHANGED
|
@@ -3,127 +3,135 @@ import { Box as t } from "../Box/base.mjs";
|
|
|
3
3
|
import { Text as n } from "../Text/index.mjs";
|
|
4
4
|
import { Badge as r } from "../Badge/index.mjs";
|
|
5
5
|
import { VisuallyHidden as i } from "../VisuallyHidden/index.mjs";
|
|
6
|
-
import {
|
|
7
|
-
import { RailTooltip as
|
|
8
|
-
import { Fragment as
|
|
9
|
-
import { Tooltip as
|
|
6
|
+
import { action as a, cornerDot as o, count as s, entry as c, group as l, heading as u, item as d, label as f, lead as p, list as m, liveDot as h, trail as g } from "./NavList.css.mjs";
|
|
7
|
+
import { RailTooltip as _ } from "./client.mjs";
|
|
8
|
+
import { Fragment as v, jsx as y, jsxs as b } from "react/jsx-runtime";
|
|
9
|
+
import { Tooltip as x } from "@base-ui/react/tooltip";
|
|
10
10
|
// src/NavList/index.tsx
|
|
11
|
-
function
|
|
12
|
-
return /* @__PURE__ */
|
|
11
|
+
function S({ children: e, ...n }) {
|
|
12
|
+
return /* @__PURE__ */ y(t, {
|
|
13
13
|
...n,
|
|
14
14
|
as: "nav",
|
|
15
|
-
children: /* @__PURE__ */
|
|
15
|
+
children: /* @__PURE__ */ y(x.Provider, { children: /* @__PURE__ */ y(C, { children: e }) })
|
|
16
16
|
});
|
|
17
17
|
}
|
|
18
|
-
function
|
|
19
|
-
return /* @__PURE__ */
|
|
18
|
+
function C({ label: e, children: n }) {
|
|
19
|
+
return /* @__PURE__ */ y(t, {
|
|
20
20
|
"aria-label": e,
|
|
21
21
|
as: "ul",
|
|
22
|
-
className:
|
|
22
|
+
className: m,
|
|
23
23
|
display: "flex",
|
|
24
24
|
flexDirection: "column",
|
|
25
25
|
gap: "4",
|
|
26
26
|
children: n
|
|
27
27
|
});
|
|
28
28
|
}
|
|
29
|
-
function
|
|
30
|
-
return /* @__PURE__ */
|
|
29
|
+
function w({ label: r, headingLevel: i = "h2", display: a = "flex", flexDirection: o = "column", gap: s = "4", className: c, children: d, ...f }) {
|
|
30
|
+
return /* @__PURE__ */ b(t, {
|
|
31
31
|
...f,
|
|
32
32
|
as: "li",
|
|
33
|
-
className: e(
|
|
33
|
+
className: e(l, c),
|
|
34
34
|
display: a,
|
|
35
35
|
flexDirection: o,
|
|
36
36
|
gap: s,
|
|
37
|
-
children: [/* @__PURE__ */
|
|
37
|
+
children: [/* @__PURE__ */ y(n, {
|
|
38
38
|
as: i,
|
|
39
|
-
className:
|
|
39
|
+
className: u,
|
|
40
40
|
color: "fgMuted",
|
|
41
41
|
paddingBlock: "4",
|
|
42
42
|
paddingInline: "8",
|
|
43
43
|
size: "xs",
|
|
44
44
|
weight: "semibold",
|
|
45
45
|
children: r
|
|
46
|
-
}), /* @__PURE__ */
|
|
46
|
+
}), /* @__PURE__ */ y(C, {
|
|
47
47
|
label: r,
|
|
48
48
|
children: d
|
|
49
49
|
})]
|
|
50
50
|
});
|
|
51
51
|
}
|
|
52
|
-
function
|
|
53
|
-
let
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
52
|
+
function T({ as: l, current: u = !1, icon: m, avatar: x, action: S, count: C, live: w = !1, liveLabel: T = "live", display: E = "flex", alignItems: D = "center", gap: O = "8", position: k = "relative", minBlockSize: A = "sm", paddingBlock: j = "6", paddingInline: M = "8", borderRadius: N = "xs", backgroundColor: P = u ? "selected" : void 0, color: F = "fg", className: I, children: L, ...R }) {
|
|
53
|
+
let z = l ?? "a", B = S != null && typeof S != "boolean" && S !== "", V = /* @__PURE__ */ y(r, {
|
|
54
|
+
className: s,
|
|
55
|
+
flexShrink: 0,
|
|
56
|
+
size: "xs",
|
|
57
|
+
subtle: !0,
|
|
58
|
+
children: C
|
|
59
|
+
}), H = /* @__PURE__ */ b(t, {
|
|
60
|
+
alignItems: D,
|
|
61
|
+
as: z,
|
|
62
|
+
backgroundColor: P,
|
|
63
|
+
borderRadius: N,
|
|
64
|
+
color: F,
|
|
65
|
+
display: E,
|
|
66
|
+
gap: O,
|
|
67
|
+
minBlockSize: A,
|
|
68
|
+
paddingBlock: j,
|
|
69
|
+
paddingInline: M,
|
|
70
|
+
position: k,
|
|
71
|
+
...R,
|
|
72
|
+
"aria-current": u ? "page" : void 0,
|
|
73
|
+
className: e(d, I),
|
|
68
74
|
children: [
|
|
69
|
-
|
|
75
|
+
m != null || x != null ? /* @__PURE__ */ b(t, {
|
|
70
76
|
"aria-hidden": !0,
|
|
71
77
|
as: "span",
|
|
72
|
-
className:
|
|
78
|
+
className: p,
|
|
73
79
|
display: "flex",
|
|
74
80
|
flexShrink: 0,
|
|
75
|
-
children: [
|
|
81
|
+
children: [m ? /* @__PURE__ */ y(m, { size: "sm" }) : x, w ? /* @__PURE__ */ y(t, {
|
|
76
82
|
as: "span",
|
|
77
|
-
className:
|
|
83
|
+
className: o
|
|
78
84
|
}) : null]
|
|
79
85
|
}) : null,
|
|
80
|
-
/* @__PURE__ */
|
|
86
|
+
/* @__PURE__ */ y(n, {
|
|
81
87
|
as: "span",
|
|
82
|
-
className:
|
|
88
|
+
className: f,
|
|
83
89
|
flexGrow: 1,
|
|
84
90
|
size: "sm",
|
|
85
|
-
weight:
|
|
86
|
-
children:
|
|
91
|
+
weight: u ? "medium" : "regular",
|
|
92
|
+
children: L
|
|
87
93
|
}),
|
|
88
|
-
|
|
94
|
+
w ? /* @__PURE__ */ b(v, { children: [/* @__PURE__ */ y(t, {
|
|
89
95
|
"aria-hidden": !0,
|
|
90
96
|
as: "span",
|
|
91
|
-
className:
|
|
92
|
-
}), /* @__PURE__ */
|
|
93
|
-
/* @__PURE__ */
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
children: b
|
|
99
|
-
})
|
|
97
|
+
className: h
|
|
98
|
+
}), /* @__PURE__ */ y(i, { children: ` ${T}` })] }) : null,
|
|
99
|
+
B ? /* @__PURE__ */ y(t, {
|
|
100
|
+
as: "span",
|
|
101
|
+
className: g,
|
|
102
|
+
children: V
|
|
103
|
+
}) : V
|
|
100
104
|
]
|
|
101
105
|
});
|
|
102
|
-
return /* @__PURE__ */
|
|
103
|
-
className:
|
|
104
|
-
children: /* @__PURE__ */ _
|
|
105
|
-
link:
|
|
106
|
-
children: /* @__PURE__ */
|
|
106
|
+
return /* @__PURE__ */ b("li", {
|
|
107
|
+
className: e(c, B && "_1kvngp04"),
|
|
108
|
+
children: [/* @__PURE__ */ y(_, {
|
|
109
|
+
link: H,
|
|
110
|
+
children: /* @__PURE__ */ b(t, {
|
|
107
111
|
alignItems: "center",
|
|
108
112
|
as: "span",
|
|
109
113
|
display: "flex",
|
|
110
114
|
gap: "8",
|
|
111
|
-
children: [/* @__PURE__ */
|
|
115
|
+
children: [/* @__PURE__ */ y(n, {
|
|
112
116
|
as: "span",
|
|
113
117
|
size: "sm",
|
|
114
|
-
children:
|
|
115
|
-
}), /* @__PURE__ */
|
|
118
|
+
children: L
|
|
119
|
+
}), /* @__PURE__ */ y(r, {
|
|
116
120
|
flexShrink: 0,
|
|
117
121
|
size: "xs",
|
|
118
122
|
subtle: !0,
|
|
119
|
-
children:
|
|
123
|
+
children: C
|
|
120
124
|
})]
|
|
121
125
|
})
|
|
122
|
-
})
|
|
126
|
+
}), B ? /* @__PURE__ */ y(t, {
|
|
127
|
+
as: "span",
|
|
128
|
+
className: a,
|
|
129
|
+
children: S
|
|
130
|
+
}) : null]
|
|
123
131
|
});
|
|
124
132
|
}
|
|
125
|
-
var
|
|
126
|
-
Group:
|
|
127
|
-
Item:
|
|
133
|
+
var E = Object.assign(S, {
|
|
134
|
+
Group: w,
|
|
135
|
+
Item: T
|
|
128
136
|
});
|
|
129
|
-
export {
|
|
137
|
+
export { E as NavList };
|
|
@@ -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.icon, components.icon-button, components.inline, components.sidebar, components.sidebar-layout, components.stack, components.text, components.avatar, components.badge, components.button, components.chip, components.field, components.color-field, components.combobox, components.heading, components.dialog, components.alert-dialog, components.menu, components.multiselect, components.number-field, 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;
|
|
2
|
-
@layer components.number-field{._4ak7w90{clip-path:inset(50%);white-space:nowrap;border:0;block-size:1px;inline-size:1px;margin:0;padding:0;position:absolute;overflow:hidden}._4ak7w91{grid-template-columns:var(--space-4) auto minmax(0, 1fr) auto var(--space-4)}._4ak7w92{appearance:none;border-width:var(--space-1);border-style:solid;border-color:var(--color-border-strong);border-radius:var(--radius-
|
|
2
|
+
@layer components.number-field{._4ak7w90{clip-path:inset(50%);white-space:nowrap;border:0;block-size:1px;inline-size:1px;margin:0;padding:0;position:absolute;overflow:hidden}._4ak7w91{grid-template-columns:var(--space-4) auto minmax(0, 1fr) auto var(--space-4)}._4ak7w92{appearance:none;border-width:var(--space-1);border-style:solid;border-color:var(--color-border-strong);border-radius:var(--radius-sm);background-color:var(--color-bg);inline-size:100%;min-inline-size:0;color:var(--color-fg);text-align:center;grid-area:1/1/auto/-1;padding-block:0}._4ak7w92::placeholder{color:var(--color-fg-muted);opacity:1}._4ak7w92:focus-visible{outline:var(--space-2) solid var(--color-focus);outline-offset:var(--space-2)}._4ak7w92:disabled{background-color:var(--color-bg-muted);color:var(--color-fg-muted);cursor:not-allowed;border-style:dashed}._4ak7w92[aria-invalid=true]{border-color:var(--color-danger)}._4ak7w93{block-size:var(--size-xs);padding-inline:calc(var(--size-xs) + var(--space-4))}._4ak7w94{block-size:var(--size-sm);padding-inline:calc(var(--size-xs) + var(--space-4))}._4ak7w95{block-size:var(--size-med);padding-inline:calc(var(--size-sm) + var(--space-4))}._4ak7w96{background-clip:padding-box;grid-area:1/2}._4ak7w97{background-clip:padding-box;grid-area:1/4}@media (pointer:coarse){._4ak7w92{font-size:var(--font-size-med)}}@media (forced-colors:active){._4ak7w92:disabled{color:graytext;border-color:graytext}._4ak7w96{border-color:#0000}._4ak7w96[aria-disabled=true]{border-color:graytext}._4ak7w97{border-color:#0000}._4ak7w97[aria-disabled=true]{border-color:graytext}}}
|
|
@@ -55,6 +55,7 @@ function _({ label: _, hideLabel: v = !1, value: y, defaultValue: b, onValueChan
|
|
|
55
55
|
})
|
|
56
56
|
}),
|
|
57
57
|
/* @__PURE__ */ p(h.Decrement, { render: /* @__PURE__ */ p(a, {
|
|
58
|
+
borderRadius: "xs",
|
|
58
59
|
className: c,
|
|
59
60
|
icon: o,
|
|
60
61
|
label: M,
|
|
@@ -62,6 +63,7 @@ function _({ label: _, hideLabel: v = !1, value: y, defaultValue: b, onValueChan
|
|
|
62
63
|
variant: "ghost"
|
|
63
64
|
}) }),
|
|
64
65
|
/* @__PURE__ */ p(h.Increment, { render: /* @__PURE__ */ p(a, {
|
|
66
|
+
borderRadius: "xs",
|
|
65
67
|
className: u,
|
|
66
68
|
icon: s,
|
|
67
69
|
label: N,
|
|
@@ -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.icon, components.icon-button, components.inline, components.sidebar, components.sidebar-layout, components.stack, components.text, components.avatar, components.badge, components.button, components.chip, components.field, components.color-field, components.combobox, components.heading, components.dialog, components.alert-dialog, components.menu, components.multiselect, components.number-field, 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;
|
|
2
|
-
@layer components.search-field{._1cj8r6g0{clip-path:inset(50%);white-space:nowrap;border:0;block-size:1px;inline-size:1px;margin:0;padding:0;position:absolute;overflow:hidden}._1cj8r6g1{appearance:none;border-width:var(--space-1);border-style:solid;border-color:var(--color-border-strong);border-radius:var(--radius-
|
|
2
|
+
@layer components.search-field{._1cj8r6g0{clip-path:inset(50%);white-space:nowrap;border:0;block-size:1px;inline-size:1px;margin:0;padding:0;position:absolute;overflow:hidden}._1cj8r6g1{appearance:none;border-width:var(--space-1);border-style:solid;border-color:var(--color-border-strong);border-radius:var(--radius-sm);background-color:var(--color-bg);inline-size:100%;min-inline-size:0;color:var(--color-fg);grid-area:1/1;padding-block:0}._1cj8r6g1::placeholder{color:var(--color-fg-muted);opacity:1}._1cj8r6g1:focus-visible{outline:var(--space-2) solid var(--color-focus);outline-offset:var(--space-2)}._1cj8r6g1:disabled{background-color:var(--color-bg-muted);color:var(--color-fg-muted);cursor:not-allowed;border-style:dashed}._1cj8r6g1[aria-invalid=true]{border-color:var(--color-danger)}._1cj8r6g1::-webkit-search-cancel-button{appearance:none}._1cj8r6g1::-webkit-search-decoration{appearance:none}._1cj8r6g2{block-size:var(--size-xs);padding-inline-start:var(--space-6);padding-inline-end:calc(var(--size-xs) + var(--space-4))}._1cj8r6g3{block-size:var(--size-sm);padding-inline-start:var(--space-8);padding-inline-end:calc(var(--size-xs) + var(--space-4))}._1cj8r6g4{block-size:var(--size-med);padding-inline-start:var(--space-12);padding-inline-end:calc(var(--size-sm) + var(--space-4))}._1cj8r6g5{font-family:var(--font-body);font-size:var(--font-size-xs);line-height:var(--size-xs);color:var(--color-fg-muted);pointer-events:none;grid-area:1/1;justify-self:start;padding-inline-start:var(--space-6)}._1cj8r6g6{font-family:var(--font-body);font-size:var(--font-size-sm);line-height:var(--size-sm);color:var(--color-fg-muted);pointer-events:none;grid-area:1/1;justify-self:start;padding-inline-start:var(--space-8)}._1cj8r6g7{font-family:var(--font-body);font-size:var(--font-size-med);line-height:var(--size-med);color:var(--color-fg-muted);pointer-events:none;grid-area:1/1;justify-self:start;padding-inline-start:var(--space-12)}._1cj8r6g8{font-family:var(--font-body);font-size:var(--font-size-xs);line-height:var(--size-xs);color:var(--color-fg-muted);pointer-events:none;grid-area:1/1;justify-self:end;padding-inline-end:var(--space-6)}._1cj8r6g9{font-family:var(--font-body);font-size:var(--font-size-sm);line-height:var(--size-sm);color:var(--color-fg-muted);pointer-events:none;grid-area:1/1;justify-self:end;padding-inline-end:var(--space-8)}._1cj8r6ga{font-family:var(--font-body);font-size:var(--font-size-med);line-height:var(--size-med);color:var(--color-fg-muted);pointer-events:none;grid-area:1/1;justify-self:end;padding-inline-end:var(--space-12)}._1cj8r6gb{vertical-align:calc((1cap - var(--font-size-xs)) / 2);display:inline-block}._1cj8r6gc{vertical-align:calc((1cap - var(--font-size-sm)) / 2);display:inline-block}._1cj8r6gd{vertical-align:calc((1cap - var(--font-size-med)) / 2);display:inline-block}._1cj8r6ge{padding-inline-start:calc(var(--space-6) + var(--font-size-xs) + var(--space-4))}._1cj8r6gf{padding-inline-start:calc(var(--space-8) + var(--font-size-sm) + var(--space-4))}._1cj8r6gg{padding-inline-start:calc(var(--space-12) + var(--font-size-med) + var(--space-8))}._1cj8r6gh{padding-inline-end:calc(var(--space-6) + var(--font-size-xs) + var(--space-4))}._1cj8r6gi{padding-inline-end:calc(var(--space-8) + var(--font-size-sm) + var(--space-4))}._1cj8r6gj{padding-inline-end:calc(var(--space-12) + var(--font-size-med) + var(--space-8))}._1cj8r6gk{background-clip:padding-box;grid-area:1/1;justify-self:end;position:relative;inset-inline-end:var(--space-4)}@media (pointer:coarse){._1cj8r6g1,._1cj8r6g5,._1cj8r6g6,._1cj8r6g7,._1cj8r6g8,._1cj8r6g9,._1cj8r6ga{font-size:var(--font-size-med)}}@media (forced-colors:active){._1cj8r6g1:disabled{color:graytext;border-color:graytext}._1cj8r6gk{border-color:#0000}}}
|
package/dist/Tag/Tag.css
CHANGED
|
@@ -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.icon, components.icon-button, components.inline, components.sidebar, components.sidebar-layout, components.stack, components.text, components.avatar, components.badge, components.button, components.chip, components.field, components.color-field, components.combobox, components.heading, components.dialog, components.alert-dialog, components.menu, components.multiselect, components.number-field, 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;
|
|
2
|
-
@layer components.tag{._1jsyd8s1
|
|
2
|
+
@layer components.tag{._1jsyd8s2{--_1jsyd8s1:calc(var(--size-xs) - 2 * var(--space-1));border-width:var(--space-1);border-style:solid;border-color:var(--_1jsyd8s0,transparent)}._1jsyd8s3{overflow-wrap:anywhere}._1jsyd8s2:hover ._1jsyd8s3,._1jsyd8s2:focus-within ._1jsyd8s3{padding-block:var(--space-4);margin-block:0}._1jsyd8s4{--_1jsyd8s1:var(--size-xs)}._1jsyd8s5{align-self:start;margin-block-start:calc(calc((var(--_1jsyd8s1) - var(--_1nsw9rp0) * 1em - var(--_1nsw9rp1) - var(--_1nsw9rp2)) / 2) + var(--_1nsw9rp1))}._1jsyd8s2:hover ._1jsyd8s5,._1jsyd8s2:focus-within ._1jsyd8s5{margin-block-start:calc(calc((var(--_1jsyd8s1) - var(--_1nsw9rp0) * 1em - var(--_1nsw9rp1) - var(--_1nsw9rp2)) / 2) + var(--_1nsw9rp1));padding-block-start:calc(-1 * var(--_1nsw9rp1))}._1jsyd8s6{text-decoration:underline}._1jsyd8s8:hover{background-color:var(--color-bg)}._1jsyd8s9:hover{background-color:var(--color-hover)}._1jsyd8sk{--_1jsyd8s0:var(--color-border)}._1jsyd8sm{border-radius:var(--radius-full);background-color:var(--_1jsyd8sl)}._1jsyd8sn{vertical-align:calc((1cap - var(--space-6)) / 2);inline-size:var(--space-6);block-size:var(--space-6);margin-inline-end:var(--space-4);display:inline-block}._1jsyd8so{vertical-align:calc((1cap - var(--space-8)) / 2);inline-size:var(--space-8);block-size:var(--space-8);margin-inline-end:var(--space-8);display:inline-block}._1jsyd8sp{--_1jsyd8sl:var(--color-fg-muted)}._1jsyd8sq{--_1jsyd8sl:var(--color-accent)}._1jsyd8sr{--_1jsyd8sl:var(--color-success)}._1jsyd8ss{--_1jsyd8sl:var(--color-warning)}._1jsyd8st{--_1jsyd8sl:var(--color-danger)}._1jsyd8su{--_1jsyd8sl:var(--color-done)}._1jsyd8sv{vertical-align:calc((1cap - var(--font-size-xs)) / 2);margin-inline-end:var(--space-4);display:inline-block}._1jsyd8sw{vertical-align:calc((1cap - var(--font-size-med)) / 2);margin-inline-end:var(--space-8);display:inline-block}._1jsyd8sx{vertical-align:calc((1cap - var(--font-size-xs)) / 2);margin-inline-start:var(--space-4);display:inline-block}._1jsyd8sy{vertical-align:calc((1cap - var(--font-size-med)) / 2);margin-inline-start:var(--space-8);display:inline-block}._1jsyd8sz{vertical-align:top;max-inline-size:calc(100% - var(--font-size-xs) - var(--space-4));display:inline-block}._1jsyd8s10{vertical-align:top;max-inline-size:calc(100% - var(--font-size-med) - var(--space-8));display:inline-block}:where([data-text-reveal]:hover,[data-text-reveal]:focus-within) ._1jsyd8s11{max-inline-size:none;display:inline}@media (forced-colors:active){._1jsyd8s2{color:canvastext;background-color:canvas;border-color:canvastext}._1jsyd8sm{forced-color-adjust:none;background-color:canvastext}}}
|
package/dist/Tag/Tag.css.mjs
CHANGED
|
@@ -4,67 +4,67 @@ import "./Tag.css";
|
|
|
4
4
|
/* empty css */
|
|
5
5
|
import { createRuntimeFn as e } from "@vanilla-extract/recipes/createRuntimeFn";
|
|
6
6
|
// src/Tag/Tag.css.ts
|
|
7
|
-
var t = "
|
|
8
|
-
defaultClassName: "
|
|
7
|
+
var t = "_1jsyd8s2", n = "_1jsyd8s3", r = "_1jsyd8s4", i = "_1jsyd8s5", a = "_1jsyd8s6", o = e({
|
|
8
|
+
defaultClassName: "_1jsyd8s7",
|
|
9
9
|
variantClassNames: { appearance: {
|
|
10
|
-
subtle: "
|
|
11
|
-
outline: "
|
|
10
|
+
subtle: "_1jsyd8s8",
|
|
11
|
+
outline: "_1jsyd8s9"
|
|
12
12
|
} },
|
|
13
13
|
defaultVariants: {},
|
|
14
14
|
compoundVariants: []
|
|
15
|
-
}),
|
|
16
|
-
defaultClassName: "
|
|
15
|
+
}), s = e({
|
|
16
|
+
defaultClassName: "_1jsyd8sa",
|
|
17
17
|
variantClassNames: {
|
|
18
18
|
variant: {
|
|
19
|
-
neutral: "
|
|
20
|
-
accent: "
|
|
21
|
-
success: "
|
|
22
|
-
warning: "
|
|
23
|
-
danger: "
|
|
24
|
-
done: "
|
|
19
|
+
neutral: "_1jsyd8sb",
|
|
20
|
+
accent: "_1jsyd8sc",
|
|
21
|
+
success: "_1jsyd8sd",
|
|
22
|
+
warning: "_1jsyd8se",
|
|
23
|
+
danger: "_1jsyd8sf",
|
|
24
|
+
done: "_1jsyd8sg"
|
|
25
25
|
},
|
|
26
26
|
size: {
|
|
27
|
-
sm: "
|
|
28
|
-
med: "
|
|
27
|
+
sm: "_1jsyd8sh",
|
|
28
|
+
med: "_1jsyd8si"
|
|
29
29
|
},
|
|
30
30
|
appearance: {
|
|
31
|
-
subtle: "
|
|
32
|
-
outline: "
|
|
31
|
+
subtle: "_1jsyd8sj",
|
|
32
|
+
outline: "_1jsyd8sk"
|
|
33
33
|
}
|
|
34
34
|
},
|
|
35
35
|
defaultVariants: {},
|
|
36
36
|
compoundVariants: []
|
|
37
|
-
}),
|
|
38
|
-
defaultClassName: "
|
|
37
|
+
}), c = e({
|
|
38
|
+
defaultClassName: "_1jsyd8sm",
|
|
39
39
|
variantClassNames: {
|
|
40
40
|
size: {
|
|
41
|
-
sm: "
|
|
42
|
-
med: "
|
|
41
|
+
sm: "_1jsyd8sn",
|
|
42
|
+
med: "_1jsyd8so"
|
|
43
43
|
},
|
|
44
44
|
variant: {
|
|
45
|
-
neutral: "
|
|
46
|
-
accent: "
|
|
47
|
-
success: "
|
|
48
|
-
warning: "
|
|
49
|
-
danger: "
|
|
50
|
-
done: "
|
|
45
|
+
neutral: "_1jsyd8sp",
|
|
46
|
+
accent: "_1jsyd8sq",
|
|
47
|
+
success: "_1jsyd8sr",
|
|
48
|
+
warning: "_1jsyd8ss",
|
|
49
|
+
danger: "_1jsyd8st",
|
|
50
|
+
done: "_1jsyd8su"
|
|
51
51
|
}
|
|
52
52
|
},
|
|
53
53
|
defaultVariants: {},
|
|
54
54
|
compoundVariants: []
|
|
55
|
-
}),
|
|
55
|
+
}), l = {
|
|
56
56
|
start: {
|
|
57
|
-
xs: "
|
|
58
|
-
med: "
|
|
57
|
+
xs: "_1jsyd8sv",
|
|
58
|
+
med: "_1jsyd8sw"
|
|
59
59
|
},
|
|
60
60
|
end: {
|
|
61
|
-
xs: "
|
|
62
|
-
med: "
|
|
61
|
+
xs: "_1jsyd8sx",
|
|
62
|
+
med: "_1jsyd8sy"
|
|
63
63
|
},
|
|
64
64
|
clip: {
|
|
65
|
-
xs: "
|
|
66
|
-
med: "
|
|
65
|
+
xs: "_1jsyd8sz",
|
|
66
|
+
med: "_1jsyd8s10"
|
|
67
67
|
},
|
|
68
|
-
reveal: "
|
|
68
|
+
reveal: "_1jsyd8s11"
|
|
69
69
|
};
|
|
70
|
-
export {
|
|
70
|
+
export { c as dot, r as fullRow, n as label, a as link, i as pinned, o as remove, t as root, l as slot, s as tag };
|
package/dist/Tag/index.mjs
CHANGED
|
@@ -31,9 +31,9 @@ var v = {
|
|
|
31
31
|
};
|
|
32
32
|
function y({ appearance: y = "subtle", variant: b = "neutral", size: x = "med", href: S, iconStart: C, iconEnd: w, onRemove: T, removeLabel: E, display: D = "inline-flex", alignItems: O = "center", gap: k = "2", minBlockSize: A = "xs", paddingInlineStart: j = v[x].paddingInlineStart, paddingInlineEnd: M = T ? "2" : v[x].paddingInlineEnd, borderRadius: N = y === "outline" ? "med" : "xs", backgroundColor: P = y === "outline" ? void 0 : o[b].backgroundColor, color: F = y === "outline" ? "fg" : o[b].color, maxInlineSize: I, className: L, style: R, children: z, ...B }) {
|
|
33
33
|
if (z == null || typeof z == "boolean" || z === "" || _(z) === "") return null;
|
|
34
|
-
let V = a(I, R), H = /* @__PURE__ */ h(r, {
|
|
34
|
+
let V = a(I, R), H = V && A === "xs" && O === "center", U = /* @__PURE__ */ h(r, {
|
|
35
35
|
as: "span",
|
|
36
|
-
className: l,
|
|
36
|
+
className: e(l, H && "_1jsyd8s5"),
|
|
37
37
|
font: "label",
|
|
38
38
|
leading: v[x].leading,
|
|
39
39
|
paddingBlock: V ? void 0 : "4",
|
|
@@ -55,7 +55,7 @@ function y({ appearance: y = "subtle", variant: b = "neutral", size: x = "med",
|
|
|
55
55
|
}),
|
|
56
56
|
children: z
|
|
57
57
|
})
|
|
58
|
-
}),
|
|
58
|
+
}), W = _(z), G = E ?? (W === void 0 ? void 0 : `Remove ${W}`);
|
|
59
59
|
return /* @__PURE__ */ g(t, {
|
|
60
60
|
...B,
|
|
61
61
|
alignItems: O,
|
|
@@ -66,7 +66,7 @@ function y({ appearance: y = "subtle", variant: b = "neutral", size: x = "med",
|
|
|
66
66
|
variant: b,
|
|
67
67
|
size: x,
|
|
68
68
|
appearance: y
|
|
69
|
-
}), L),
|
|
69
|
+
}), (T || S) && "_1jsyd8s4", L),
|
|
70
70
|
color: F,
|
|
71
71
|
"data-text-reveal": "",
|
|
72
72
|
display: D,
|
|
@@ -77,14 +77,15 @@ function y({ appearance: y = "subtle", variant: b = "neutral", size: x = "med",
|
|
|
77
77
|
paddingInlineStart: j,
|
|
78
78
|
style: R,
|
|
79
79
|
children: [S ? /* @__PURE__ */ h(n, {
|
|
80
|
+
alignSelf: H ? "start" : void 0,
|
|
80
81
|
as: "a",
|
|
81
82
|
className: u,
|
|
82
83
|
href: S,
|
|
83
84
|
overflow: "hidden",
|
|
84
|
-
children:
|
|
85
|
-
}) :
|
|
85
|
+
children: U
|
|
86
|
+
}) : U, T && /* @__PURE__ */ h(n, {
|
|
86
87
|
alignSelf: "start",
|
|
87
|
-
"aria-label":
|
|
88
|
+
"aria-label": G ?? "Remove",
|
|
88
89
|
borderRadius: "full",
|
|
89
90
|
className: d({ appearance: y }),
|
|
90
91
|
flexShrink: 0,
|
package/dist/Text/Text.css
CHANGED
|
@@ -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.icon, components.icon-button, components.inline, components.sidebar, components.sidebar-layout, components.stack, components.text, components.avatar, components.badge, components.button, components.chip, components.field, components.color-field, components.combobox, components.heading, components.dialog, components.alert-dialog, components.menu, components.multiselect, components.number-field, 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;
|
|
2
|
-
@layer components.text{.
|
|
2
|
+
@layer components.text{._1mgdisq1{--_1nsw9rp0:var(--line-height-med);--_1mgdisq0:var(--font-tracking-body);--_1nsw9rp1:calc((var(--font-trim-body-cap) - var(--_1nsw9rp0) / 2) * 1em);--_1nsw9rp2:calc((var(--font-trim-body-baseline) - var(--_1nsw9rp0) / 2) * 1em);font-family:var(--font-body);letter-spacing:var(--_1mgdisq0);font-feature-settings:var(--font-features-body);font-size:var(--font-size-med);font-weight:var(--font-weight-regular);line-height:var(--_1nsw9rp0)}:where(li)>._1mgdisq2{display:flow-root}:where(li:has(>._1mgdisq2))::marker{font-family:var(--font-body);line-height:0}:where(._1mgdisq1)>._1mgdisq1:where(a,abbr,b,bdi,bdo,cite,code,data,del,dfn,em,i,ins,kbd,label,mark,output,q,s,samp,small,span,strong,sub,sup,time,u,var){--_1nsw9rp0:inherit;--_1mgdisq0:inherit;--_1nsw9rp1:inherit;--_1nsw9rp2:inherit;font-feature-settings:inherit;font-family:inherit;font-size:inherit;font-weight:inherit;line-height:inherit;display:inline}._1mgdisq4{--_1nsw9rp0:inherit;--_1mgdisq0:inherit;--_1nsw9rp1:inherit;--_1nsw9rp2:inherit;text-overflow:ellipsis;white-space:nowrap;font-feature-settings:inherit;min-block-size:0;min-inline-size:0;font-family:inherit;font-size:inherit;font-weight:inherit;line-height:inherit;overflow-y:visible}:where([data-text-reveal]:hover,[data-text-reveal]:focus-within) ._1mgdisq4{white-space:normal;text-overflow:clip}._1mgdisq5{--_1mgdisq0:var(--font-tracking-body);--_1nsw9rp1:calc((var(--font-trim-body-cap) - var(--_1nsw9rp0) / 2) * 1em);--_1nsw9rp2:calc((var(--font-trim-body-baseline) - var(--_1nsw9rp0) / 2) * 1em);font-family:var(--font-body);letter-spacing:var(--_1mgdisq0);font-feature-settings:var(--font-features-body)}._1mgdisq6{--_1mgdisq0:var(--font-tracking-heading);--_1nsw9rp1:calc((var(--font-trim-heading-cap) - var(--_1nsw9rp0) / 2) * 1em);--_1nsw9rp2:calc((var(--font-trim-heading-baseline) - var(--_1nsw9rp0) / 2) * 1em);font-family:var(--font-heading);letter-spacing:var(--_1mgdisq0);font-feature-settings:var(--font-features-heading)}._1mgdisq7{--_1mgdisq0:var(--font-tracking-display);--_1nsw9rp1:calc((var(--font-trim-display-cap) - var(--_1nsw9rp0) / 2) * 1em);--_1nsw9rp2:calc((var(--font-trim-display-baseline) - var(--_1nsw9rp0) / 2) * 1em);font-family:var(--font-display);letter-spacing:var(--_1mgdisq0);font-feature-settings:var(--font-features-display)}._1mgdisq8{--_1mgdisq0:var(--font-tracking-label);--_1nsw9rp1:calc((var(--font-trim-label-cap) - var(--_1nsw9rp0) / 2) * 1em);--_1nsw9rp2:calc((var(--font-trim-label-baseline) - var(--_1nsw9rp0) / 2) * 1em);font-family:var(--font-label);letter-spacing:var(--_1mgdisq0);font-feature-settings:var(--font-features-label)}._1mgdisq9{--_1mgdisq0:var(--font-tracking-mono);--_1nsw9rp1:calc((var(--font-trim-mono-cap) - var(--_1nsw9rp0) / 2) * 1em);--_1nsw9rp2:calc((var(--font-trim-mono-baseline) - var(--_1nsw9rp0) / 2) * 1em);font-family:var(--font-mono);letter-spacing:var(--_1mgdisq0);font-feature-settings:var(--font-features-mono)}._1mgdisqa{font-size:var(--font-size-xs)}._1mgdisqb{font-size:var(--font-size-sm)}._1mgdisqc{font-size:var(--font-size-med)}._1mgdisqd{font-size:var(--font-size-lg)}._1mgdisqe{font-size:var(--font-size-xl)}._1mgdisqf{font-size:var(--font-size-2xl)}._1mgdisqg{font-size:var(--font-size-3xl)}._1mgdisqh{font-size:var(--font-size-4xl)}._1mgdisqi{font-weight:var(--font-weight-regular)}._1mgdisqj{font-weight:var(--font-weight-medium)}._1mgdisqk{font-weight:var(--font-weight-semibold)}._1mgdisql{font-weight:var(--font-weight-bold)}._1mgdisqm{--_1nsw9rp0:var(--line-height-sm);line-height:var(--_1nsw9rp0)}._1mgdisqn{--_1nsw9rp0:var(--line-height-meta);line-height:var(--_1nsw9rp0)}._1mgdisqo{--_1nsw9rp0:var(--line-height-body);line-height:var(--_1nsw9rp0)}._1mgdisqp{--_1nsw9rp0:var(--line-height-med);line-height:var(--_1nsw9rp0)}._1mgdisqq{--_1nsw9rp0:var(--line-height-lg);line-height:var(--_1nsw9rp0)}._1mgdisqr{font-variant-numeric:tabular-nums}._1mgdisqs{white-space:nowrap}._1mgdisqt{white-space:pre-wrap;overflow-wrap:anywhere}._1mgdisqu{white-space:pre}._1mgdisqv{text-overflow:ellipsis;white-space:nowrap;min-block-size:0;min-inline-size:0;margin-block-start:var(--_1nsw9rp1);margin-block-end:var(--_1nsw9rp2);padding-block-start:calc(-1 * var(--_1nsw9rp1));padding-block-end:calc(-1 * var(--_1nsw9rp2))}:where([data-text-reveal]:hover,[data-text-reveal]:focus-within) ._1mgdisqv{white-space:normal;text-overflow:clip}@supports (text-box:trim-both cap alphabetic){._1mgdisq1{text-box:trim-both cap alphabetic}._1mgdisq3{text-box:normal}._1mgdisq3:before{content:"";margin-block-end:var(--_1nsw9rp1);display:table}._1mgdisq3:after{content:"";margin-block-start:var(--_1nsw9rp2);display:table}:where(li)>._1mgdisq3:before,:where(li)>._1mgdisq3:after{display:block}:where(._1mgdisq1)>._1mgdisq1:where(a,abbr,b,bdi,bdo,cite,code,data,del,dfn,em,i,ins,kbd,label,mark,output,q,s,samp,small,span,strong,sub,sup,time,u,var){text-box-trim:none}:where(._1mgdisq1)>._1mgdisq1:where(a,abbr,b,bdi,bdo,cite,code,data,del,dfn,em,i,ins,kbd,label,mark,output,q,s,samp,small,span,strong,sub,sup,time,u,var):before,:where(._1mgdisq1)>._1mgdisq1:where(a,abbr,b,bdi,bdo,cite,code,data,del,dfn,em,i,ins,kbd,label,mark,output,q,s,samp,small,span,strong,sub,sup,time,u,var):after{content:none}._1mgdisq4{text-box-trim:none}}@supports not (text-box:trim-both cap alphabetic){._1mgdisq1:before{content:"";margin-block-end:var(--_1nsw9rp1);display:table}._1mgdisq1:after{content:"";margin-block-start:var(--_1nsw9rp2);display:table}:where(li)>._1mgdisq2:before,:where(li)>._1mgdisq2:after{display:block}:where(._1mgdisq1)>._1mgdisq1:where(a,abbr,b,bdi,bdo,cite,code,data,del,dfn,em,i,ins,kbd,label,mark,output,q,s,samp,small,span,strong,sub,sup,time,u,var):before,:where(._1mgdisq1)>._1mgdisq1:where(a,abbr,b,bdi,bdo,cite,code,data,del,dfn,em,i,ins,kbd,label,mark,output,q,s,samp,small,span,strong,sub,sup,time,u,var):after,._1mgdisq4:before,._1mgdisq4:after{content:none}}}
|
package/dist/Text/Text.css.mjs
CHANGED
|
@@ -3,35 +3,35 @@ import "./Text.css";
|
|
|
3
3
|
/* empty css */
|
|
4
4
|
/* empty css */
|
|
5
5
|
// src/Text/Text.css.ts
|
|
6
|
-
var e = "
|
|
7
|
-
body: "
|
|
8
|
-
heading: "
|
|
9
|
-
display: "
|
|
10
|
-
label: "
|
|
11
|
-
mono: "
|
|
6
|
+
var e = "_1mgdisq1", t = "_1mgdisq2", n = "_1mgdisq3", r = "_1mgdisq4", i = {
|
|
7
|
+
body: "_1mgdisq5",
|
|
8
|
+
heading: "_1mgdisq6",
|
|
9
|
+
display: "_1mgdisq7",
|
|
10
|
+
label: "_1mgdisq8",
|
|
11
|
+
mono: "_1mgdisq9"
|
|
12
12
|
}, a = {
|
|
13
|
-
xs: "
|
|
14
|
-
sm: "
|
|
15
|
-
med: "
|
|
16
|
-
lg: "
|
|
17
|
-
xl: "
|
|
18
|
-
"2xl": "
|
|
19
|
-
"3xl": "
|
|
20
|
-
"4xl": "
|
|
13
|
+
xs: "_1mgdisqa",
|
|
14
|
+
sm: "_1mgdisqb",
|
|
15
|
+
med: "_1mgdisqc",
|
|
16
|
+
lg: "_1mgdisqd",
|
|
17
|
+
xl: "_1mgdisqe",
|
|
18
|
+
"2xl": "_1mgdisqf",
|
|
19
|
+
"3xl": "_1mgdisqg",
|
|
20
|
+
"4xl": "_1mgdisqh"
|
|
21
21
|
}, o = {
|
|
22
|
-
regular: "
|
|
23
|
-
medium: "
|
|
24
|
-
semibold: "
|
|
25
|
-
bold: "
|
|
22
|
+
regular: "_1mgdisqi",
|
|
23
|
+
medium: "_1mgdisqj",
|
|
24
|
+
semibold: "_1mgdisqk",
|
|
25
|
+
bold: "_1mgdisql"
|
|
26
26
|
}, s = {
|
|
27
|
-
sm: "
|
|
28
|
-
meta: "
|
|
29
|
-
body: "
|
|
30
|
-
med: "
|
|
31
|
-
lg: "
|
|
32
|
-
}, c = "
|
|
33
|
-
nowrap: "
|
|
34
|
-
"pre-wrap": "
|
|
35
|
-
pre: "
|
|
36
|
-
}, u = "
|
|
27
|
+
sm: "_1mgdisqm",
|
|
28
|
+
meta: "_1mgdisqn",
|
|
29
|
+
body: "_1mgdisqo",
|
|
30
|
+
med: "_1mgdisqp",
|
|
31
|
+
lg: "_1mgdisqq"
|
|
32
|
+
}, c = "_1mgdisqr", l = {
|
|
33
|
+
nowrap: "_1mgdisqs",
|
|
34
|
+
"pre-wrap": "_1mgdisqt",
|
|
35
|
+
pre: "_1mgdisqu"
|
|
36
|
+
}, u = "_1mgdisqv";
|
|
37
37
|
export { t as block, i as font, s as leading, e as root, n as scrollContainer, a as size, c as tabularNums, u as truncate, r as truncateBox, o as weight, l as wrap };
|
package/dist/Text/index.mjs
CHANGED
|
@@ -6,16 +6,16 @@ import { jsx as c } from "react/jsx-runtime";
|
|
|
6
6
|
function l({ as: l, size: u, font: d, weight: f, leading: p, tabularNums: m, truncate: h, wrap: g, display: _ = "block", overflow: v = h ? "clip" : void 0, className: y, ...b }) {
|
|
7
7
|
let x = [
|
|
8
8
|
i,
|
|
9
|
-
_ === "block" && "
|
|
10
|
-
h === "box" && "
|
|
11
|
-
h !== "box" && (v === "hidden" || v === "auto") && "
|
|
9
|
+
_ === "block" && "_1mgdisq2",
|
|
10
|
+
h === "box" && "_1mgdisq4",
|
|
11
|
+
h !== "box" && (v === "hidden" || v === "auto") && "_1mgdisq3",
|
|
12
12
|
d && n[d],
|
|
13
13
|
u && a[u],
|
|
14
14
|
f && o[f],
|
|
15
15
|
p && r[p],
|
|
16
|
-
m && "
|
|
16
|
+
m && "_1mgdisqr",
|
|
17
17
|
g && !h && s[g],
|
|
18
|
-
h === !0 && "
|
|
18
|
+
h === !0 && "_1mgdisqv",
|
|
19
19
|
y
|
|
20
20
|
];
|
|
21
21
|
return /* @__PURE__ */ c(t, {
|
|
@@ -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.icon, components.icon-button, components.inline, components.sidebar, components.sidebar-layout, components.stack, components.text, components.avatar, components.badge, components.button, components.chip, components.field, components.color-field, components.combobox, components.heading, components.dialog, components.alert-dialog, components.menu, components.multiselect, components.number-field, 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;
|
|
2
|
-
@layer components.text-field{._20at410{clip-path:inset(50%);white-space:nowrap;border:0;block-size:1px;inline-size:1px;margin:0;padding:0;position:absolute;overflow:hidden}._20at411{appearance:none;border-width:var(--space-1);border-style:solid;border-color:var(--color-border-strong);border-radius:var(--radius-
|
|
2
|
+
@layer components.text-field{._20at410{clip-path:inset(50%);white-space:nowrap;border:0;block-size:1px;inline-size:1px;margin:0;padding:0;position:absolute;overflow:hidden}._20at411{appearance:none;border-width:var(--space-1);border-style:solid;border-color:var(--color-border-strong);border-radius:var(--radius-sm);background-color:var(--color-bg);inline-size:100%;min-inline-size:0;color:var(--color-fg);grid-area:1/1;padding-block:0}._20at411::placeholder{color:var(--color-fg-muted);opacity:1}._20at411:focus-visible{outline:var(--space-2) solid var(--color-focus);outline-offset:var(--space-2)}._20at411:disabled{background-color:var(--color-bg-muted);color:var(--color-fg-muted);cursor:not-allowed;border-style:dashed}._20at411[aria-invalid=true]{border-color:var(--color-danger)}._20at412{block-size:var(--size-xs);padding-inline:var(--space-6)}._20at413{block-size:var(--size-sm);padding-inline:var(--space-8)}._20at414{block-size:var(--size-med);padding-inline:var(--space-12)}._20at415{font-family:var(--font-body);font-size:var(--font-size-xs);line-height:var(--size-xs);color:var(--color-fg-muted);pointer-events:none;grid-area:1/1;justify-self:start;padding-inline-start:var(--space-6)}._20at416{font-family:var(--font-body);font-size:var(--font-size-sm);line-height:var(--size-sm);color:var(--color-fg-muted);pointer-events:none;grid-area:1/1;justify-self:start;padding-inline-start:var(--space-8)}._20at417{font-family:var(--font-body);font-size:var(--font-size-med);line-height:var(--size-med);color:var(--color-fg-muted);pointer-events:none;grid-area:1/1;justify-self:start;padding-inline-start:var(--space-12)}._20at418{font-family:var(--font-body);font-size:var(--font-size-xs);line-height:var(--size-xs);color:var(--color-fg-muted);pointer-events:none;grid-area:1/1;justify-self:end;padding-inline-end:var(--space-6)}._20at419{font-family:var(--font-body);font-size:var(--font-size-sm);line-height:var(--size-sm);color:var(--color-fg-muted);pointer-events:none;grid-area:1/1;justify-self:end;padding-inline-end:var(--space-8)}._20at41a{font-family:var(--font-body);font-size:var(--font-size-med);line-height:var(--size-med);color:var(--color-fg-muted);pointer-events:none;grid-area:1/1;justify-self:end;padding-inline-end:var(--space-12)}._20at41b{vertical-align:calc((1cap - var(--font-size-xs)) / 2);display:inline-block}._20at41c{vertical-align:calc((1cap - var(--font-size-sm)) / 2);display:inline-block}._20at41d{vertical-align:calc((1cap - var(--font-size-med)) / 2);display:inline-block}._20at41e{padding-inline-start:calc(var(--space-6) + var(--font-size-xs) + var(--space-4))}._20at41f{padding-inline-start:calc(var(--space-8) + var(--font-size-sm) + var(--space-4))}._20at41g{padding-inline-start:calc(var(--space-12) + var(--font-size-med) + var(--space-8))}._20at41h{padding-inline-end:calc(var(--space-6) + var(--font-size-xs) + var(--space-4))}._20at41i{padding-inline-end:calc(var(--space-8) + var(--font-size-sm) + var(--space-4))}._20at41j{padding-inline-end:calc(var(--space-12) + var(--font-size-med) + var(--space-8))}@media (pointer:coarse){._20at411,._20at415,._20at416,._20at417,._20at418,._20at419,._20at41a{font-size:var(--font-size-med)}}@media (forced-colors:active){._20at411:disabled{color:graytext;border-color:graytext}}}
|
|
@@ -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.icon, components.icon-button, components.inline, components.sidebar, components.sidebar-layout, components.stack, components.text, components.avatar, components.badge, components.button, components.chip, components.field, components.color-field, components.combobox, components.heading, components.dialog, components.alert-dialog, components.menu, components.multiselect, components.number-field, 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;
|
|
2
|
-
@layer components.textarea{._1kwv2lp0{clip-path:inset(50%);white-space:nowrap;border:0;block-size:1px;inline-size:1px;margin:0;padding:0;position:absolute;overflow:hidden}._1kwv2lp1{appearance:none;border-width:var(--space-1);border-style:solid;border-color:var(--color-border-strong);border-radius:var(--radius-
|
|
2
|
+
@layer components.textarea{._1kwv2lp0{clip-path:inset(50%);white-space:nowrap;border:0;block-size:1px;inline-size:1px;margin:0;padding:0;position:absolute;overflow:hidden}._1kwv2lp1{appearance:none;border-width:var(--space-1);border-style:solid;border-color:var(--color-border-strong);border-radius:var(--radius-sm);background-color:var(--color-bg);inline-size:100%;min-inline-size:0;color:var(--color-fg);resize:block;padding-block:0}._1kwv2lp1::placeholder{color:var(--color-fg-muted);opacity:1}._1kwv2lp1:focus-visible{outline:var(--space-2) solid var(--color-focus);outline-offset:var(--space-2)}._1kwv2lp1:disabled{background-color:var(--color-bg-muted);color:var(--color-fg-muted);cursor:not-allowed;resize:none;border-style:dashed}._1kwv2lp1[aria-invalid=true]{border-color:var(--color-danger)}._1kwv2lp2{min-block-size:var(--size-xs);padding-block:calc((var(--size-xs) - 2 * var(--space-1) - var(--font-size-xs) * var(--line-height-med)) / 2);padding-inline:var(--space-6)}._1kwv2lp3{min-block-size:var(--size-sm);padding-block:calc((var(--size-sm) - 2 * var(--space-1) - var(--font-size-sm) * var(--line-height-med)) / 2);padding-inline:var(--space-8)}._1kwv2lp4{min-block-size:var(--size-med);padding-block:calc((var(--size-med) - 2 * var(--space-1) - var(--font-size-med) * var(--line-height-med)) / 2);padding-inline:var(--space-12)}@media (pointer:coarse){._1kwv2lp1{font-size:var(--font-size-med)}._1kwv2lp2{min-block-size:max(var(--size-xs), calc(2 * var(--space-1) + var(--font-size-med) * var(--line-height-med)));padding-block:max(var(--space-0), calc((var(--size-xs) - 2 * var(--space-1) - var(--font-size-med) * var(--line-height-med)) / 2))}._1kwv2lp3{min-block-size:max(var(--size-sm), calc(2 * var(--space-1) + var(--font-size-med) * var(--line-height-med)));padding-block:max(var(--space-0), calc((var(--size-sm) - 2 * var(--space-1) - var(--font-size-med) * var(--line-height-med)) / 2))}._1kwv2lp4{min-block-size:max(var(--size-med), calc(2 * var(--space-1) + var(--font-size-med) * var(--line-height-med)));padding-block:max(var(--space-0), calc((var(--size-med) - 2 * var(--space-1) - var(--font-size-med) * var(--line-height-med)) / 2))}}@media (forced-colors:active){._1kwv2lp1:disabled{color:graytext;border-color:graytext}}}
|
package/dist/docs/NavList.md
CHANGED
|
@@ -2,18 +2,19 @@
|
|
|
2
2
|
|
|
3
3
|
## Purpose
|
|
4
4
|
|
|
5
|
-
A column of links to an app's pages, with the current page marked: a sidebar's or a settings page's navigation. The parts are `NavList` (a named `nav` around a list), `NavList.Group` (a heading over a run of items) and `NavList.Item` (one link, with an optional leading icon, live dot and trailing count). Items are links, not buttons: an `<a>` by default, or a router's `Link` through `as`, which keeps the router's props typed (ADR 0149). The app says which item is current; NavList reads nothing from the URL.
|
|
5
|
+
A column of links to an app's pages, with the current page marked: a sidebar's or a settings page's navigation. The parts are `NavList` (a named `nav` around a list), `NavList.Group` (a heading over a run of items) and `NavList.Item` (one link, with an optional leading icon, live dot and trailing count, and an optional `action` beside the link: a control for that row, such as its ⋯ menu). Items are links, not buttons: an `<a>` by default, or a router's `Link` through `as`, which keeps the router's props typed (ADR 0149). The app says which item is current; NavList reads nothing from the URL.
|
|
6
6
|
|
|
7
7
|
## When to use
|
|
8
8
|
|
|
9
9
|
- The pages of an app or a section, listed down a sidebar, with the one you are on marked.
|
|
10
10
|
- A settings page's sections, each its own route.
|
|
11
11
|
- Links with a count beside them (unread messages, open issues), or grouped under short headings.
|
|
12
|
+
- Rows with their own actions (a repository's settings, Remove from inbox): a `Menu` behind an icon trigger in each row's `action`, beside its link.
|
|
12
13
|
|
|
13
14
|
## When not to use
|
|
14
15
|
|
|
15
16
|
- Switching views that share one page and keep the URL: use `Tabs`.
|
|
16
|
-
-
|
|
17
|
+
- An item that runs an action or command, such as Sign out or New project: use `Menu` or `Button`. The link itself only navigates. An action that belongs to one row, such as Rename or Delete for that row's page, goes beside the link in `action` (ADR 0169).
|
|
17
18
|
- Links in running text, or one link on its own: use a link (`Clickable as="a"`).
|
|
18
19
|
- A tree of collapsible or nested groups, or a drawer that slides in on a phone: not supported. One level of groups, always open.
|
|
19
20
|
- Working out the current page from the URL: the app's router does that, and passes `current`.
|
|
@@ -22,13 +23,15 @@ A column of links to an app's pages, with the current page marked: a sidebar's o
|
|
|
22
23
|
|
|
23
24
|
- `NavList` needs a name, and its type requires one: `aria-label` ("Main", "Settings") or `aria-labelledby` when a visible heading names it. A page with two navs tells them apart by these names.
|
|
24
25
|
- Children are `NavList.Item` and `NavList.Group`, in any mix. `NavList.Group` takes `label`, a string: its heading's text, and its list's name. The heading is `h2` by default; set `headingLevel` to fit the page's outline. A group after another item or group gets `16` of room above it, and so does an item after a group.
|
|
25
|
-
- `NavList.Item` is an `<a>` by default: pass `href`. With `as={Link}`, it takes the router's props instead (`to`, `prefetch`) and its type checks them. Every other prop, `ref` and the style props included, lands on the link; the `li` around it
|
|
26
|
+
- `NavList.Item` is an `<a>` by default: pass `href`. With `as={Link}`, it takes the router's props instead (`to`, `prefetch`) and its type checks them. Every other prop, `ref` and the style props included, lands on the link; the `li` around it takes none. A custom `as` component must pass its props and `ref` on to the element it renders: the rail tooltip opens from the event handlers and `ref` it adds there. Use the router's plain `Link`, not a `NavLink` that sets `aria-current` itself: NavList draws the current item from `current`, so the two would disagree.
|
|
26
27
|
- `current` marks the link to the page on screen: `aria-current="page"`, the `selected` fill under `fg` text and a medium label, with no bar (ADR 0167). Set it on one item at most. It is the only way to set `aria-current`: the type omits the raw attribute.
|
|
27
28
|
- `icon` takes an icon component (`icon={InboxIcon}`), drawn at `sm` before the label and hidden from assistive tech: the label names the link.
|
|
28
29
|
- `avatar` takes an avatar in place of the icon, for a row that stands for a person, a team or a repository: `avatar={<Avatar initials="UI" label="" size="sm" />}`. It is hidden from assistive tech like the icon, so give the Avatar an empty `label`. An item takes `icon` or `avatar`, never both; the type rejects the pair.
|
|
29
|
-
- Inside a `Sidebar` rail (`collapsed`), group headings, labels and counts are visually hidden and each item is a 40px square around its icon or avatar, centered. Their text stays in the accessible names. Every item in a rail needs an icon or an avatar. In a SidebarLayout stacked below 48em a collapsed Sidebar is no rail: the items show open (ADR 0156). In the rail, hover or keyboard focus on an item shows its label and count in a tooltip past its inline end (right, or left right to left); Esc, blur and pointer leave close it, and the pointer can move onto it. Items in one NavList share the tooltip delay: once one has opened, the next opens at once. Outside a rail no tooltip shows (ADR 0159). The tooltip repeats the item's children, so keep them to text and a count: content with an `id` would repeat it.
|
|
30
|
+
- Inside a `Sidebar` rail (`collapsed`), group headings, labels and counts are visually hidden, an `action` is gone, and each item is a 40px square around its icon or avatar, centered. Their text stays in the accessible names. Every item in a rail needs an icon or an avatar. In a SidebarLayout stacked below 48em a collapsed Sidebar is no rail: the items show open (ADR 0156). In the rail, hover or keyboard focus on an item shows its label and count in a tooltip past its inline end (right, or left right to left); Esc, blur and pointer leave close it, and the pointer can move onto it. Items in one NavList share the tooltip delay: once one has opened, the next opens at once. Outside a rail no tooltip shows (ADR 0159). The tooltip repeats the item's children, so keep them to text and a count: content with an `id` would repeat it.
|
|
30
31
|
- `count` is a trailing subtle `Badge` at `xs`. It is part of the link's accessible name, read after the label, so a bare number says nothing ("Issues 12"). Give it its meaning with `VisuallyHidden`: `count={<>12<VisuallyHidden> open issues</VisuallyHidden></>}`. A nullish or empty count renders nothing.
|
|
31
32
|
- `live` marks a page with something running behind it now (a job, a session, a sync): a 6px `success` dot with a soft halo before the count, or at the end of the row with no count. It is read after the label as `liveLabel`, "live" by default; give it the app's meaning (`liveLabel="session running"`) or its language. In the rail the inline dot hides and a dot sits on the icon's or avatar's top inline-end corner, ringed in `bgPanel`; the rail tooltip shows no dot. `count` is separate and unchanged.
|
|
33
|
+
- `action` takes one control for the row, rendered after the link inside the `li`, never inside it: pass a `Menu` whose `Menu.Trigger` is the icon trigger at `size="sm"` (`icon={EllipsisIcon}`, a 24px target) with its `Menu.Popup`. NavList names nothing, so name each trigger for its row: `label="Actions for jonmilner/ui"`, not a "More actions" repeated down the list. It sits at the row's inline end, `8` in from the edge, in the count's place: at rest it is transparent and the count shows; on hover over the row (where hover is real), focus inside the row, or while its menu is open, the action shows and the count goes transparent. Where there is no hover (`(hover: none), (pointer: coarse)`) it always shows, so on a phone or tablet that row's count is never in sight; the count stays in the link's name, but a count the user must see belongs in the label or on a row without an action. The slot holds one node at the inline end: put several actions in the one menu, never a second control or a leading one. A long label wraps before the action and never runs under it. An item with no action renders as before; `null`, `undefined`, a boolean or `""` is none, so `canEdit && <Menu>…` works; a number is not (`items.length && <Menu>…` renders `0` as the action), so make the condition a boolean.
|
|
34
|
+
- A collapsed `Sidebar`'s rail drops the action: it is `display: none` there, out of sight and the tab order, and the row stays the 40px square. Give the rail those actions another way (a menu on the selected page, the page's own header). In a SidebarLayout stacked below 48em the items show open and the action with them.
|
|
32
35
|
- Labels wrap onto a second line in a narrow column, breaking a long word if they must; they never truncate.
|
|
33
36
|
- Items are `sm` text in `fg`, with `6` block and `8` inline padding, an `xs` radius and at least the `sm` (32px) block size, as default style props; the consumer's win. Hover tints a non-current item where hover is real (`(hover: hover)`).
|
|
34
37
|
- A server component can render the whole list, router `Link` included. `NavList` and `NavList.Group` have no hooks; each `NavList.Item` renders its link inside a client part, the rail tooltip (ADR 0159).
|
|
@@ -58,6 +61,41 @@ A column of links to an app's pages, with the current page marked: a sidebar's o
|
|
|
58
61
|
</NavList>
|
|
59
62
|
```
|
|
60
63
|
|
|
64
|
+
```tsx
|
|
65
|
+
// A row's actions beside its link: an icon Menu.Trigger at sm, named for the row. Its menu items
|
|
66
|
+
// act on that row's page; the link still only navigates.
|
|
67
|
+
<NavList aria-label="Repositories">
|
|
68
|
+
{repos.map((repo) => (
|
|
69
|
+
<NavList.Item
|
|
70
|
+
action={
|
|
71
|
+
<Menu>
|
|
72
|
+
<Menu.Trigger icon={EllipsisIcon} label={`Actions for ${repo.name}`} size="sm" />
|
|
73
|
+
<Menu.Popup>
|
|
74
|
+
<Menu.Item onClick={() => openSettings(repo)}>Repo settings…</Menu.Item>
|
|
75
|
+
<Menu.LinkItem href={repo.url}>Open on GitHub</Menu.LinkItem>
|
|
76
|
+
<Menu.Separator />
|
|
77
|
+
<Menu.Item onClick={() => remove(repo)} variant="danger">
|
|
78
|
+
Remove from inbox…
|
|
79
|
+
</Menu.Item>
|
|
80
|
+
</Menu.Popup>
|
|
81
|
+
</Menu>
|
|
82
|
+
}
|
|
83
|
+
count={
|
|
84
|
+
<>
|
|
85
|
+
{repo.open}
|
|
86
|
+
<VisuallyHidden> open</VisuallyHidden>
|
|
87
|
+
</>
|
|
88
|
+
}
|
|
89
|
+
current={repo.name === current}
|
|
90
|
+
href={`/repos/${repo.name}`}
|
|
91
|
+
key={repo.name}
|
|
92
|
+
>
|
|
93
|
+
{repo.name}
|
|
94
|
+
</NavList.Item>
|
|
95
|
+
))}
|
|
96
|
+
</NavList>
|
|
97
|
+
```
|
|
98
|
+
|
|
61
99
|
```tsx
|
|
62
100
|
// A router's link: its props stay typed. The router says which item is current.
|
|
63
101
|
<NavList aria-label="Settings">
|
|
@@ -88,6 +126,32 @@ A column of links to an app's pages, with the current page marked: a sidebar's o
|
|
|
88
126
|
</NavList.Item>
|
|
89
127
|
```
|
|
90
128
|
|
|
129
|
+
```tsx
|
|
130
|
+
// A control inside the link: a button in an <a> is invalid nested interactive content, and the
|
|
131
|
+
// click would also follow the link. Pass it in `action`, beside the link.
|
|
132
|
+
<NavList.Item href="/repos/ui">
|
|
133
|
+
jonmilner/ui
|
|
134
|
+
<Menu>
|
|
135
|
+
<Menu.Trigger icon={EllipsisIcon} label="Actions for jonmilner/ui" size="sm" />
|
|
136
|
+
</Menu>
|
|
137
|
+
</NavList.Item>
|
|
138
|
+
```
|
|
139
|
+
|
|
140
|
+
```tsx
|
|
141
|
+
// The same name on every row's action: a screen reader's list of buttons says "More actions"
|
|
142
|
+
// over and over, with nothing to tell the rows apart. Name it for its row.
|
|
143
|
+
<NavList.Item
|
|
144
|
+
action={
|
|
145
|
+
<Menu>
|
|
146
|
+
<Menu.Trigger icon={EllipsisIcon} label="More actions" size="sm" />
|
|
147
|
+
</Menu>
|
|
148
|
+
}
|
|
149
|
+
href="/repos/ui"
|
|
150
|
+
>
|
|
151
|
+
jonmilner/ui
|
|
152
|
+
</NavList.Item>
|
|
153
|
+
```
|
|
154
|
+
|
|
91
155
|
```tsx
|
|
92
156
|
// A button that runs an action: a NavList item navigates. Use Menu or Button.
|
|
93
157
|
<NavList.Item as="button" onClick={signOut}>
|
|
@@ -101,8 +165,9 @@ A column of links to an app's pages, with the current page marked: a sidebar's o
|
|
|
101
165
|
- Each group's list is named by its heading's text, and the heading is in the page's outline, so heading navigation reaches it.
|
|
102
166
|
- The current item has `aria-current="page"`, announced as "current page". Its fill and medium label show it without color alone (WCAG 1.4.1). Under forced colors it is a solid `Highlight` fill with `HighlightText`, and a hovered item's tint is dropped, so the two never look alike.
|
|
103
167
|
- The current item's text is `fg` on the `selected` overlay, a checked pair over `bg`, `bgMuted`, `bgRaised` and `bgPanel` (4.5:1, light and dark, ADR 0155). Other items are `fg` on the page's surface; under the hover tint, `fg` over `bg`, `bgMuted` and `bgRaised` is checked in `contrast/mixes.ts` (the ghost Button's tint).
|
|
104
|
-
- Links are in the tab order in reading order and show the shared focus ring. Every item is at least 32px high, 40px square in the rail (WCAG 2.5.8, ADR 0124).
|
|
168
|
+
- Links are in the tab order in reading order and show the shared focus ring. A row with an `action` is two tab stops, the link and then the action, each with its own ring; the action is in the tab order and the accessibility tree even while transparent, and focus shows it. Every item is at least 32px high, 40px square in the rail (WCAG 2.5.8, ADR 0124).
|
|
105
169
|
- The icon or avatar is hidden; the label and the count, with its meaning, make the link's name, with the live label between them when `live` is set, in a Sidebar rail too, where they are only visually hidden. The rail tooltip repeats the label and count for sight only (the live state shows as the corner dot): it is `aria-hidden` and not the link's description, so the name is read once and there is no `aria-describedby`.
|
|
170
|
+
- An `action` is the link's sibling, so no control nests in the link (WAI-ARIA, HTML content model), and the link's name is unchanged by it: the count stays in the name while the action covers it ("Inbox live 12 unread"). The action's name comes from the app; one name per row ("Actions for Inbox") tells the triggers apart in a list of buttons and says what each acts on (WCAG 2.4.6, 4.1.2). Its trigger is a 24px target (WCAG 2.5.8), shown always on touch, where nothing hovers, and there it covers the count for good: sighted touch users lose the count, which assistive tech still reads in the link's name. In the rail it is removed with `display: none`, so it is neither seen nor reached by keyboard or assistive tech there.
|
|
106
171
|
|
|
107
172
|
## Props
|
|
108
173
|
|
|
@@ -130,6 +195,7 @@ Also accepts the style props (see `manifest.json` `styleProps`).
|
|
|
130
195
|
|
|
131
196
|
| Prop | Type | Required | Description |
|
|
132
197
|
| --- | --- | --- | --- |
|
|
198
|
+
| `action` | `ReactNode` | no | |
|
|
133
199
|
| `as` | `ElementType` | no | |
|
|
134
200
|
| `avatar` | `ReactNode` | no | |
|
|
135
201
|
| `count` | `ReactNode` | no | |
|
package/dist/docs/Tag.md
CHANGED
|
@@ -27,7 +27,7 @@ A label that puts content in a category: a topic, a label, a user-made category.
|
|
|
27
27
|
- Read-only is the default. `href` makes the label a link (a `Clickable` `<a>` around the text, underlined). The tag itself stays a `span`, so a remove button never nests in the link.
|
|
28
28
|
- `onRemove` adds a native `<button>` after the label with an `x` icon. Its name is "Remove <label>" from a string or number label; set `removeLabel` for any other label. Enter and Space activate it; the click calls `onRemove`. Tag handles no keys, so Backspace and Delete do nothing (ADR 0003, 0055).
|
|
29
29
|
- Wrapping: an uncapped label wraps to the width it has, so a tag never overflows a narrow container or a 320px viewport at large text sizes. Every line stays inside the fill and its rounded corners, and inside the outline under forced colors.
|
|
30
|
-
- Truncation: set `maxInlineSize` on the Tag, as the style prop or in `style` (the style prop's steps stop at 56px, so most caps are `style={{ maxInlineSize: "min(10rem, 100%)" }}`; the `100%` keeps a rem cap inside a narrow container at large text sizes). `style.maxWidth` counts too, and `style` wins over the prop, as inline styles do. A responsive prop truncates only with a `base` step and a size step (or `full`) at every breakpoint: `{ med: "xl" }` and `{ base: "xl", med: "fit" }` wrap. The prop's `fit`, `min`, `max` and `auto`, and `style` values `none`, `auto` and `*-content`, follow the content and wrap. A cap set only through `className` wraps instead. The label becomes one line with an ellipsis. While the pointer is over the tag, or focus is inside it, the label shows its whole text, wrapped within the same width
|
|
30
|
+
- Truncation: set `maxInlineSize` on the Tag, as the style prop or in `style` (the style prop's steps stop at 56px, so most caps are `style={{ maxInlineSize: "min(10rem, 100%)" }}`; the `100%` keeps a rem cap inside a narrow container at large text sizes). `style.maxWidth` counts too, and `style` wins over the prop, as inline styles do. A responsive prop truncates only with a `base` step and a size step (or `full`) at every breakpoint: `{ med: "xl" }` and `{ base: "xl", med: "fit" }` wrap. The prop's `fit`, `min`, `max` and `auto`, and `style` values `none`, `auto` and `*-content`, follow the content and wrap. A cap set only through `className` wraps instead. The label becomes one line with an ellipsis. While the pointer is over the tag, or focus is inside it, the label shows its whole text, wrapped within the same width, its first line where it was and the rest below, so no line's descenders or link underline are cut off and the tag and its remove button stay put (ADR 0172). There is no tooltip and no `title`; the DOM always holds the full text, so screen readers read all of it and so does the remove button's name. The tag grows in height when it reveals, so leave room for it in a tight row. A read-only tag takes no focus, so a keyboard user cannot reveal it: cap read-only tags only where the full text is also elsewhere, or make them links.
|
|
31
31
|
- With no children it renders nothing. Display, fill, text color, padding, radius and `minBlockSize` (the remove button's 24px target) are default style props; a consumer's win. `className`, `style` and `ref` go to the root, `className` last.
|
|
32
32
|
- The module has no hooks, so a server component can render it.
|
|
33
33
|
|
package/dist/docs/llms.txt
CHANGED
|
@@ -29,7 +29,7 @@
|
|
|
29
29
|
- [Inline](Inline.md): A horizontal row of children that wraps onto new lines, with even space between them on both axes. `Inline` is a `Box` with `display="flex"`, `flexDirection="row"`, `flexWrap="wrap"` and `alignItems="center"` as default style props, spaced by a required `gap`. Children render as they are: no wrapper per child.
|
|
30
30
|
- [Menu](Menu.md): A list of actions that opens from a button: a row's "Edit, Duplicate, Delete", a toolbar's overflow. It may mix in links ("Open invoice", "Download PDF") as `Menu.LinkItem`, real anchors that keep the browser's link behavior. Built on Base UI's Menu, which owns the keyboard and focus: arrow keys, Home and End move through the items, typing jumps to a matching item, Esc and an outside click close it, and focus returns to the trigger. The parts add the look: a raised surface with a border and shadow, a highlighted item, a zoom-and-fade that is a plain fade under reduced motion.
|
|
31
31
|
- [MultiSelect](MultiSelect.md): A form field for picking any number of values from a list too long to show at once. A trigger styled as Button's secondary look opens a listbox of options; each selected option shows a check mark, and the trigger summarises the selection as the joined labels, or a count ("3 selected") once the labels would not fit. Built on Base UI's `Select` in multiple mode (ADR 0003), which owns the keyboard and focus: arrow keys, Home and End move through the options, typing jumps to a match, Esc and an outside click close it, and focus returns to the trigger. It composes `Field` for its label, description and error (ADR 0026).
|
|
32
|
-
- [NavList](NavList.md): A column of links to an app's pages, with the current page marked: a sidebar's or a settings page's navigation. The parts are `NavList` (a named `nav` around a list), `NavList.Group` (a heading over a run of items) and `NavList.Item` (one link, with an optional leading icon, live dot and trailing count). Items are links, not buttons: an `<a>` by default, or a router's `Link` through `as`, which keeps the router's props typed (ADR 0149). The app says which item is current; NavList reads nothing from the URL.
|
|
32
|
+
- [NavList](NavList.md): A column of links to an app's pages, with the current page marked: a sidebar's or a settings page's navigation. The parts are `NavList` (a named `nav` around a list), `NavList.Group` (a heading over a run of items) and `NavList.Item` (one link, with an optional leading icon, live dot and trailing count, and an optional `action` beside the link: a control for that row, such as its ⋯ menu). Items are links, not buttons: an `<a>` by default, or a router's `Link` through `as`, which keeps the router's props typed (ADR 0149). The app says which item is current; NavList reads nothing from the URL.
|
|
33
33
|
- [NumberField](NumberField.md): A form field for a bounded number: a text input between a decrement button (inline start) and an increment button (inline end), with the number centred between them. Built on Base UI's `NumberField` (ADR 0003, 0161); it composes `Field` for its label, description and error (ADR 0026). Three sizes at Button's heights (`sm`, `med`, `lg`: 24, 32 and 40 px, ADR 0124); the input fills the Field's width.
|
|
34
34
|
- [RadioGroup](RadioGroup.md): One choice among a few options, all shown at once. A form field built on Base UI `RadioGroup` and `Radio` (ADR 0003, 0046) inside a `Fieldset`: a `radiogroup` named by its legend, with a `radio` per option. Each option is a 24 by 24 CSS px target (WCAG 2.2) with the shared focus ring; the 16px circle inside shows a dot when checked. It composes `Field` for the group's description and error and for each option's label and description (ADR 0026, 0133).
|
|
35
35
|
- [SearchField](SearchField.md): A form field for a search query: an `<input type="search">` (role `searchbox`) with a search icon at its inline start and, while it holds a value, a clear button at its inline end. Escape empties a field that has a value, and the clear button empties it and puts focus back in the input, so a keyboard user never loses their place (ADR 0087). Built on Base UI's `Input` (ADR 0003); it composes `Field` for its label, description and error (ADR 0026). Three sizes at Button's heights (`sm`, `med`, `lg`: 24, 32 and 40 px, ADR 0124); the clear button is 24px, or 32px in `lg`.
|
package/dist/docs/manifest.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "./manifest.schema.json",
|
|
3
3
|
"package": "@jonmilner/ui",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "0.21.1",
|
|
5
5
|
"components": [
|
|
6
6
|
{
|
|
7
7
|
"name": "AlertDialog",
|
|
@@ -1959,6 +1959,11 @@
|
|
|
1959
1959
|
"name": "NavList.Item",
|
|
1960
1960
|
"styleProps": true,
|
|
1961
1961
|
"props": [
|
|
1962
|
+
{
|
|
1963
|
+
"name": "action",
|
|
1964
|
+
"type": "ReactNode",
|
|
1965
|
+
"required": false
|
|
1966
|
+
},
|
|
1962
1967
|
{
|
|
1963
1968
|
"name": "as",
|
|
1964
1969
|
"type": "ElementType",
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
# 0.21.0
|
|
2
|
+
|
|
3
|
+
Fields and listbox triggers take the control radius (decision 0162): TextField, SearchField, Textarea, NumberField, ColorField's input and the Select, MultiSelect and Combobox triggers have `sm` (6px) corners at every size instead of `med` (8px), the same as Button. NumberField's steppers and SearchField's clear button (were 6px) and Combobox's filter input in its popup (was 8px) take `xs` (4px), concentric with what holds them. Apps still type-check and need no code change; their field corners shrink by 2px, so most only update their visual baselines.
|
|
4
|
+
|
|
5
|
+
## Find
|
|
6
|
+
|
|
7
|
+
In every source and style file the app owns (`*.ts`, `*.tsx`, `*.js`, `*.jsx`, `*.mjs`, `*.cjs`, `*.mdx`, `*.css`, `*.scss`):
|
|
8
|
+
|
|
9
|
+
- A test that reads a field's or trigger's computed radius: regex `borderRadius|border-radius|BorderRadius`, kept where it reads one of the components above.
|
|
10
|
+
- An app style that rounds its own control to match the old fields at 8px: regex `radius(\.med\b|\[\s*["']med["']\s*\])|--radius-med\b|borderRadius\s*[=:]\s*\{?\s*["']med["']`, kept where it sits beside a field (a custom input or a button joined to a field).
|
|
11
|
+
|
|
12
|
+
## Replace
|
|
13
|
+
|
|
14
|
+
Tests that expected `8px` on a field's input or a listbox trigger expect `6px`; on a NumberField stepper, SearchField's clear button or Combobox's filter input, `4px`:
|
|
15
|
+
|
|
16
|
+
```ts
|
|
17
|
+
// before
|
|
18
|
+
expect(getComputedStyle(input).borderTopLeftRadius).toBe("8px");
|
|
19
|
+
// after
|
|
20
|
+
expect(getComputedStyle(input).borderTopLeftRadius).toBe("6px");
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
An app control drawn to match the fields takes the control step:
|
|
24
|
+
|
|
25
|
+
```ts
|
|
26
|
+
// before
|
|
27
|
+
style({ borderRadius: vars.radius.med });
|
|
28
|
+
// after
|
|
29
|
+
style({ borderRadius: vars.radius.sm });
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
## Verify
|
|
33
|
+
|
|
34
|
+
From the app's root, this prints nothing, or only lines that are not a control beside a field:
|
|
35
|
+
|
|
36
|
+
```sh
|
|
37
|
+
grep -rnE --include='*.ts' --include='*.tsx' --include='*.js' --include='*.jsx' --include='*.mjs' --include='*.cjs' --include='*.mdx' --include='*.css' --include='*.scss' \
|
|
38
|
+
-e 'radius(\.med\b|\[\s*["'"'"']med["'"'"']\s*\])' -e '--radius-med\b' -e 'borderRadius\s*[=:]\s*\{?\s*["'"'"']med["'"'"']' \
|
|
39
|
+
--exclude-dir=node_modules --exclude-dir=dist .
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
Then update the app's visual baselines: field and trigger corners change from 8px to 6px, the nested pieces above to 4px, and sizes, borders and popups stay the same.
|
package/dist/docs/theming.md
CHANGED
|
@@ -60,7 +60,7 @@ Three overlay roles lay a tint over whatever surface is under them: `hover` for
|
|
|
60
60
|
|
|
61
61
|
## Radius
|
|
62
62
|
|
|
63
|
-
`vars.radius` (CSS variables `--radius-*`, and the `borderRadius` style prop) has seven steps: `none` 0, `xs` 4px, `sm` 6px, `med` 8px, `lg` 12px, `xl` 16px and `full`. Override a component's radius with its `borderRadius` prop. Each component role
|
|
63
|
+
`vars.radius` (CSS variables `--radius-*`, and the `borderRadius` style prop) has seven steps: `none` 0, `xs` 4px, `sm` 6px, `med` 8px, `lg` 12px, `xl` 16px and `full`. Override a component's radius with its `borderRadius` prop. Each component role takes one step at every size: `xs` for badges, tags, tooltips, rows inside a menu or list and small pieces nested in a control or popup (NumberField's steppers, SearchField's clear button, Combobox's filter input), `sm` for controls (buttons, fields and select triggers), `med` for menus, listboxes and toasts, `lg` for cards and dialogs, `full` for avatars, switches, radios and Chip.
|
|
64
64
|
|
|
65
65
|
## The page canvas
|
|
66
66
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@jonmilner/ui",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.21.1",
|
|
4
4
|
"bin": {
|
|
5
5
|
"ui-doctor": "./dist/cli/ui-doctor.mjs"
|
|
6
6
|
},
|
|
@@ -204,7 +204,7 @@
|
|
|
204
204
|
"@vanilla-extract/vite-plugin": "5.2.6",
|
|
205
205
|
"ajv": "8.20.0",
|
|
206
206
|
"lucide-static": "1.65.0",
|
|
207
|
-
"playwright": "1.
|
|
207
|
+
"playwright": "1.65.0",
|
|
208
208
|
"publint": "0.3.25",
|
|
209
209
|
"react": "19.3.1",
|
|
210
210
|
"react-dom": "19.3.1",
|