@nxgt/material 3.7.0 → 3.7.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/CHANGELOG.md +6 -0
- package/dist/{button-1Fornjtn.js → button--cF4gY14.js} +1 -1
- package/dist/charts.js +1 -1
- package/dist/{code-editor-DeZYlIO2.js → code-editor-0CdGwKDg.js} +3 -3
- package/dist/code-editor.js +3 -3
- package/dist/{code-language-items-Bb7afEj-.js → code-language-items-CGARRbVm.js} +1 -1
- package/dist/components/animations/scroll.css +1 -1
- package/dist/components/base-content.css +1 -1
- package/dist/components/base.css +1 -1
- package/dist/components/editor-field-expressive.css +5 -0
- package/dist/components/editor-prose.css +1 -1
- package/dist/components/theme-tokens.css +8 -0
- package/dist/components/ui/display/period-cards/period-cards.css +2 -2
- package/dist/components/ui/media/pdf-viewer/pdf-viewer.css +1 -1
- package/dist/{components-BX4icy-g.js → components-bYGPzyKd.js} +33 -33
- package/dist/components.js +9 -9
- package/dist/{dropdown-menu-DiZvX4tG.js → dropdown-menu-DWtgUVW7.js} +1 -1
- package/dist/editor-viewer.js +1 -1
- package/dist/editor.js +13 -13
- package/dist/{empty-state-Cpvsmk0R.js → empty-state-CRWLQ1sM.js} +2 -2
- package/dist/main.js +9 -9
- package/dist/map.js +1 -1
- package/dist/material.css +1 -1
- package/dist/pdf-reader.js +1 -1
- package/dist/{public-CBlV2XuA.js → public-SsiazLEv.js} +5 -5
- package/dist/{render-json-BwJX1jZ2.js → render-json-DyFYFIkZ.js} +1 -1
- package/dist/{rich-code-block-yxMXBuGd.js → rich-code-block-CwNwQs5z.js} +3 -3
- package/dist/{rich-text-viewer-Bq-2vTVm.js → rich-text-viewer-LO1IZCWs.js} +1 -1
- package/dist/{spinner-D-FE_mTW.js → spinner-CtGCPza-.js} +4 -4
- package/dist/styles.css +1 -0
- package/dist/{toolbar-items-DnkS3bDY.js → toolbar-items-DsDDD5AY.js} +1 -1
- package/dist/{use-chat-composer-BhdPNmYm.js → use-chat-composer-DZ01a16D.js} +13 -13
- package/docs/guides/theming.md +1 -0
- package/docs/troubleshooting.md +9 -0
- package/lib/components/animations/scroll.css +1 -1
- package/lib/components/base-content.css +1 -1
- package/lib/components/base.css +1 -1
- package/lib/components/editor-field-expressive.css +5 -0
- package/lib/components/editor-prose.css +1 -1
- package/lib/components/theme-tokens.css +8 -0
- package/lib/components/ui/display/period-cards/period-cards.css +2 -2
- package/lib/components/ui/media/pdf-viewer/pdf-viewer.css +1 -1
- package/lib/styles.css +1 -0
- package/package.json +1 -1
package/dist/pdf-reader.js
CHANGED
|
@@ -2,15 +2,15 @@ import { r as e } from "./rolldown-runtime-BFFgcFxR.js";
|
|
|
2
2
|
import { n as t } from "./ui.utils-CAnKTCw5.js";
|
|
3
3
|
import { t as n } from "./utils-Bcd2Z3ea.js";
|
|
4
4
|
import { A as r, E as i, M as a, O as o, R as s, a as c, k as l, o as u, w as d } from "./tooltip-tmFoTU_d.js";
|
|
5
|
-
import { $ as f, c as p, d as m, f as h, i as g, l as _, n as v, o as y, t as b, u as x } from "./dropdown-menu-
|
|
5
|
+
import { $ as f, c as p, d as m, f as h, i as g, l as _, n as v, o as y, t as b, u as x } from "./dropdown-menu-DWtgUVW7.js";
|
|
6
6
|
import { r as S, t as ee } from "./in-dialog-AiwTD3DK.js";
|
|
7
7
|
import { C, D as w, E as T, O as te, S as E, T as ne, _ as re, f as ie, g as ae, k as oe, r as se, t as ce, u as le, w as ue } from "./dialog-DdJ1C4BR.js";
|
|
8
|
-
import { S as de, a as D, d as O, g as fe, h as pe, i as me, m as he, n as k, r as ge, t as A, u as _e, w as ve } from "./toolbar-items-
|
|
8
|
+
import { S as de, a as D, d as O, g as fe, h as pe, i as me, m as he, n as k, r as ge, t as A, u as _e, w as ve } from "./toolbar-items-DsDDD5AY.js";
|
|
9
9
|
import { t as j } from "./use-material-translation-hLQzOjF0.js";
|
|
10
|
-
import { t as M } from "./button
|
|
10
|
+
import { t as M } from "./button--cF4gY14.js";
|
|
11
11
|
import { n as ye, t as be } from "./icon-button-5A6Mrj6w.js";
|
|
12
12
|
import { t as xe } from "./useEvent-2fKq-6w8.js";
|
|
13
|
-
import { i as Se, n as Ce, r as we, t as Te } from "./empty-state-
|
|
13
|
+
import { i as Se, n as Ce, r as we, t as Te } from "./empty-state-CRWLQ1sM.js";
|
|
14
14
|
import { n as Ee } from "./use-slice-reducer-0r5dXnJe.js";
|
|
15
15
|
import { r as De } from "./use-csp-nonce-ZKs9k-ov.js";
|
|
16
16
|
import { t as Oe } from "./client-only.utils-lQ7GqP8w.js";
|
|
@@ -1526,7 +1526,7 @@ var Zr = mt(function({ pageNumber: e, doc: t, size: r, rotation: i, lit: a, curr
|
|
|
1526
1526
|
className: n("flex cursor-pointer flex-col items-center gap-1 rounded-lg p-1.5 outline-none transition-colors hover:bg-foreground/5 focus-visible:ring-2 focus-visible:ring-ring", a && "bg-primary/10"),
|
|
1527
1527
|
children: [/* @__PURE__ */ V("div", {
|
|
1528
1528
|
ref: d,
|
|
1529
|
-
className: n("overflow-hidden rounded-sm bg-white shadow-sm [&>canvas]:block [&>canvas]:size-full", a && "ring-2 ring-primary"),
|
|
1529
|
+
className: n("overflow-hidden rounded-sm bg-white shadow-sm [&>canvas]:block [&>canvas]:size-full", a && "ring-2 ring-primary-indicator"),
|
|
1530
1530
|
style: f
|
|
1531
1531
|
}), /* @__PURE__ */ V("span", {
|
|
1532
1532
|
"aria-hidden": !0,
|
|
@@ -276,7 +276,7 @@ var U = (e) => typeof e == "string" ? e : typeof e == "number" || typeof e == "b
|
|
|
276
276
|
className: "m-0 flex list-none flex-wrap gap-2 p-0",
|
|
277
277
|
children: t.map((e) => /* @__PURE__ */ h("li", {
|
|
278
278
|
"aria-current": n.has(J(e)) || void 0,
|
|
279
|
-
className: "rounded-full border border-border px-3 py-1 text-sm aria-[current=true]:border-primary aria-[current=true]:bg-primary/10",
|
|
279
|
+
className: "rounded-full border border-border px-3 py-1 text-sm aria-[current=true]:border-primary-indicator aria-[current=true]:bg-primary/10",
|
|
280
280
|
children: q(e)
|
|
281
281
|
}, J(e)))
|
|
282
282
|
})]
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { t as e } from "./tooltip-tmFoTU_d.js";
|
|
2
|
-
import { c as t, n, t as r } from "./dropdown-menu-
|
|
2
|
+
import { c as t, n, t as r } from "./dropdown-menu-DWtgUVW7.js";
|
|
3
3
|
import { t as i } from "./use-material-translation-hLQzOjF0.js";
|
|
4
|
-
import { a, i as o, n as s, o as c, t as l } from "./code-language-items-
|
|
4
|
+
import { a, i as o, n as s, o as c, t as l } from "./code-language-items-CGARRbVm.js";
|
|
5
5
|
import { i as u, n as d, r as f, s as p } from "./dist-C3GR7kJd.js";
|
|
6
6
|
import { t as m } from "./code-block-spec-CGLKRhwD.js";
|
|
7
7
|
import { Check as h, ChevronDown as g, Copy as _, Maximize2 as v, WrapText as y } from "lucide-react";
|
|
@@ -143,7 +143,7 @@ function M({ node: e, editor: t, updateAttributes: n, editable: r, wrap: a, onWr
|
|
|
143
143
|
}
|
|
144
144
|
//#endregion
|
|
145
145
|
//#region lib/components/ui/widgets/editor/extensions/code/code-block-open.tsx
|
|
146
|
-
var N = x(() => import("./code-editor-
|
|
146
|
+
var N = x(() => import("./code-editor-0CdGwKDg.js").then((e) => e.n).then((e) => ({ default: e.CodeEditor })));
|
|
147
147
|
function P() {
|
|
148
148
|
let { t: e } = i();
|
|
149
149
|
return /* @__PURE__ */ T("div", {
|
|
@@ -3,7 +3,7 @@ import { t } from "./utils-Bcd2Z3ea.js";
|
|
|
3
3
|
import { B as n, E as r, I as i, Q as a, U as o, Z as s, c, d as l, m as u } from "./youtube-node-OWSNlYCc.js";
|
|
4
4
|
import { r as d, t as f } from "./lib-CEU1EE-D.js";
|
|
5
5
|
import { a as p, c as ee, i as m, l as h, o as g, s as _, t as v, u as y } from "./headless-extensions-CvmdhANJ.js";
|
|
6
|
-
import { n as b, t as x } from "./render-json-
|
|
6
|
+
import { n as b, t as x } from "./render-json-DyFYFIkZ.js";
|
|
7
7
|
import { t as S } from "./markdown-engine-Do-jxF--.js";
|
|
8
8
|
import { Fragment as C, jsx as w, jsxs as T } from "react/jsx-runtime";
|
|
9
9
|
//#region lib/components/ui/widgets/editor/viewer/parse-markdown.ts
|
|
@@ -30,7 +30,7 @@ var i = t("transition-all duration-500", {
|
|
|
30
30
|
{
|
|
31
31
|
variant: "1",
|
|
32
32
|
color: "primary",
|
|
33
|
-
className: "border-primary/10 border-t-primary"
|
|
33
|
+
className: "border-primary/10 border-t-primary-indicator"
|
|
34
34
|
},
|
|
35
35
|
{
|
|
36
36
|
variant: "1",
|
|
@@ -70,7 +70,7 @@ var i = t("transition-all duration-500", {
|
|
|
70
70
|
{
|
|
71
71
|
variant: "2",
|
|
72
72
|
color: "primary",
|
|
73
|
-
className: "border-primary/10 border-b-primary border-t-primary"
|
|
73
|
+
className: "border-primary/10 border-b-primary-indicator border-t-primary-indicator"
|
|
74
74
|
},
|
|
75
75
|
{
|
|
76
76
|
variant: "2",
|
|
@@ -110,7 +110,7 @@ var i = t("transition-all duration-500", {
|
|
|
110
110
|
{
|
|
111
111
|
variant: "3",
|
|
112
112
|
color: "primary",
|
|
113
|
-
className: "border-primary/10 border-b-primary border-t-primary border-r-primary"
|
|
113
|
+
className: "border-primary/10 border-b-primary-indicator border-t-primary-indicator border-r-primary-indicator"
|
|
114
114
|
},
|
|
115
115
|
{
|
|
116
116
|
variant: "3",
|
|
@@ -150,7 +150,7 @@ var i = t("transition-all duration-500", {
|
|
|
150
150
|
{
|
|
151
151
|
variant: "4",
|
|
152
152
|
color: "primary",
|
|
153
|
-
className: "stroke-primary"
|
|
153
|
+
className: "stroke-primary-indicator"
|
|
154
154
|
},
|
|
155
155
|
{
|
|
156
156
|
variant: "4",
|
package/dist/styles.css
CHANGED
|
@@ -55,6 +55,7 @@
|
|
|
55
55
|
--color-primary: var(--primary);
|
|
56
56
|
--color-primary-foreground: var(--primary-foreground);
|
|
57
57
|
--color-primary-text: var(--primary-text);
|
|
58
|
+
--color-primary-indicator: var(--primary-indicator);
|
|
58
59
|
/* Containers: a tint of the base colour over the surface, from the variant that
|
|
59
60
|
* is lifted in dark (primary-text, error-text) so it shows there too. Accent, a
|
|
60
61
|
* near-grey a tint would hide, is the colour itself. Text on one: `text-foreground`. */
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { t as e } from "./utils-Bcd2Z3ea.js";
|
|
2
2
|
import { A as t, D as n, E as r, I as i, M as a, P as o, R as s, S as c, T as l, c as u, d, f, k as p, l as m, t as h, u as g, x as _ } from "./tooltip-tmFoTU_d.js";
|
|
3
|
-
import { $ as v, A as y, M as b, N as x, Q as S, X as C, Z as w, b as T, d as ee, f as E, i as te, j as ne, l as re, n as ie, o as ae, r as oe, t as se, u as ce, y as le } from "./dropdown-menu-
|
|
3
|
+
import { $ as v, A as y, M as b, N as x, Q as S, X as C, Z as w, b as T, d as ee, f as E, i as te, j as ne, l as re, n as ie, o as ae, r as oe, t as se, u as ce, y as le } from "./dropdown-menu-DWtgUVW7.js";
|
|
4
4
|
import { a as ue, c as de, l as fe, o as pe, r as me, s as he, t as ge } from "./in-dialog-AiwTD3DK.js";
|
|
5
5
|
import { t as _e } from "./use-material-translation-hLQzOjF0.js";
|
|
6
6
|
import { t as ve } from "./warn-once-C_e47JM8.js";
|
|
@@ -3,27 +3,27 @@ import { t } from "./ui.utils-CAnKTCw5.js";
|
|
|
3
3
|
import { t as n } from "./utils-Bcd2Z3ea.js";
|
|
4
4
|
import { n as r } from "./use-shape-morph-BKA_R5P5.js";
|
|
5
5
|
import { A as i, D as a, E as o, F as s, M as c, O as l, R as u, T as d, _ as f, a as p, b as m, g as h, h as g, k as _, m as v, o as y, p as b, t as x, v as S, w as C, y as w } from "./tooltip-tmFoTU_d.js";
|
|
6
|
-
import { $ as T, D as E, E as D, N as O, O as k, Q as A, X as ee, Z as j, c as M, d as N, et as te, f as ne, i as P, k as re, m as ie, n as F, o as ae, p as oe, t as se, u as I } from "./dropdown-menu-
|
|
6
|
+
import { $ as T, D as E, E as D, N as O, O as k, Q as A, X as ee, Z as j, c as M, d as N, et as te, f as ne, i as P, k as re, m as ie, n as F, o as ae, p as oe, t as se, u as I } from "./dropdown-menu-DWtgUVW7.js";
|
|
7
7
|
import { i as ce, n as le, t as ue } from "./in-dialog-AiwTD3DK.js";
|
|
8
8
|
import { A as de, C as fe, D as pe, E as me, O as he, S as ge, T as _e, _ as ve, b as ye, f as be, g as xe, k as Se, l as Ce, m as we, n as Te, o as Ee, r as De, s as Oe, t as ke, u as Ae, v as je, w as Me, x as Ne, y as Pe } from "./dialog-DdJ1C4BR.js";
|
|
9
9
|
import { A as Fe, C as Ie, D as Le, E as Re, O as ze, S as Be, T as Ve, _ as He, a as Ue, b as We, d as Ge, f as Ke, g as qe, h as Je, i as Ye, k as Xe, l as Ze, m as Qe, n as $e, o as et, p as tt, r as nt, s as rt, t as it, u as at, v as ot, w as st, x as ct, y as lt } from "./floating-ui.dom-KkZSW8_E.js";
|
|
10
10
|
import { a as ut, i as dt, n as ft } from "./field-blur-context-Dw9ZAgBr.js";
|
|
11
|
-
import { C as pt, D as mt, S as ht, a as gt, c as _t, d as vt, l as yt, n as bt, o as xt, s as St, u as Ct } from "./toolbar-items-
|
|
11
|
+
import { C as pt, D as mt, S as ht, a as gt, c as _t, d as vt, l as yt, n as bt, o as xt, s as St, u as Ct } from "./toolbar-items-DsDDD5AY.js";
|
|
12
12
|
import "./stored-language-Bb7yX5uE.js";
|
|
13
13
|
import { a as wt } from "./translator-or2y0JJB.js";
|
|
14
14
|
import { h as Tt } from "./get-CTzJAwfc.js";
|
|
15
15
|
import { t as Et } from "./isEmpty-F_g3jLf8.js";
|
|
16
16
|
import { t as L } from "./use-material-translation-hLQzOjF0.js";
|
|
17
|
-
import { t as Dt } from "./spinner-
|
|
17
|
+
import { t as Dt } from "./spinner-CtGCPza-.js";
|
|
18
18
|
import { i as Ot } from "./button-tones-BgZJ1tkD.js";
|
|
19
|
-
import { a as kt, n as At, o as jt, r as Mt, t as Nt } from "./button
|
|
19
|
+
import { a as kt, n as At, o as jt, r as Mt, t as Nt } from "./button--cF4gY14.js";
|
|
20
20
|
import { t as R } from "./icon-button-5A6Mrj6w.js";
|
|
21
21
|
import { t as Pt } from "./use-ssr-media-query-C6M5m8sf.js";
|
|
22
22
|
import { n as Ft, t as It } from "./util-4heV2LPI.js";
|
|
23
23
|
import { t as Lt } from "./useEvent-2fKq-6w8.js";
|
|
24
24
|
import { f as Rt } from "./field-blur-DFUazxsL.js";
|
|
25
25
|
import { c as zt, i as Bt, l as Vt, o as Ht, r as Ut, s as Wt, t as Gt } from "./dist-C3GR7kJd.js";
|
|
26
|
-
import { o as Kt, t as qt } from "./empty-state-
|
|
26
|
+
import { o as Kt, t as qt } from "./empty-state-CRWLQ1sM.js";
|
|
27
27
|
import { t as Jt } from "./warn-once-C_e47JM8.js";
|
|
28
28
|
import { i as Yt, n as Xt } from "./use-slice-reducer-0r5dXnJe.js";
|
|
29
29
|
import { a as Zt, i as Qt } from "./escape-owner-B8k7DvFa.js";
|
|
@@ -9004,7 +9004,7 @@ function qb({ className: e, value: t, disabled: r, ...i }) {
|
|
|
9004
9004
|
disabled: r,
|
|
9005
9005
|
...Hu(/* @__PURE__ */ G(Wl, {
|
|
9006
9006
|
"data-slot": "radio-group-item",
|
|
9007
|
-
className: n("nxgt-radio nxgt-touch-target relative focus-visible:data-[state=unchecked]:border-primary focus-visible:ring-ring/50 aria-invalid:ring-error/20 dark:aria-invalid:ring-error/40 aria-invalid:border-error in-aria-invalid:border-error dark:bg-input/30 aspect-square size-5 shrink-0 shadow-xs outline-none focus-visible:ring-[3px] forced-colors:focus-visible:outline-solid forced-colors:focus-visible:outline-2 forced-colors:focus-visible:outline-offset-2 forced-colors:focus-visible:outline-[Highlight] disabled:cursor-not-allowed disabled:opacity-50", e),
|
|
9007
|
+
className: n("nxgt-radio nxgt-touch-target relative focus-visible:data-[state=unchecked]:border-primary-indicator focus-visible:ring-ring/50 aria-invalid:ring-error/20 dark:aria-invalid:ring-error/40 aria-invalid:border-error in-aria-invalid:border-error dark:bg-input/30 aspect-square size-5 shrink-0 shadow-xs outline-none focus-visible:ring-[3px] forced-colors:focus-visible:outline-solid forced-colors:focus-visible:outline-2 forced-colors:focus-visible:outline-offset-2 forced-colors:focus-visible:outline-[Highlight] disabled:cursor-not-allowed disabled:opacity-50", e),
|
|
9008
9008
|
...i,
|
|
9009
9009
|
children: /* @__PURE__ */ G("span", {
|
|
9010
9010
|
"data-slot": "radio-group-indicator",
|
|
@@ -10973,7 +10973,7 @@ var US = (e = {}) => yn({
|
|
|
10973
10973
|
let [{ default: t }, { lowlight: n }, { richCodeBlock: r }] = await Promise.all([
|
|
10974
10974
|
import("./dist-CRMFGjng.js"),
|
|
10975
10975
|
import("./lowlight-OtcjU2Sa.js"),
|
|
10976
|
-
import("./rich-code-block-
|
|
10976
|
+
import("./rich-code-block-CwNwQs5z.js")
|
|
10977
10977
|
]);
|
|
10978
10978
|
return [r(t, {
|
|
10979
10979
|
lowlight: n,
|
|
@@ -14368,7 +14368,7 @@ function zE({ variant: e = "dots", getLabel: t, className: r, ...i }) {
|
|
|
14368
14368
|
className: n("group/indicator flex h-6 min-w-6 cursor-pointer items-center justify-center rounded-full", NE),
|
|
14369
14369
|
children: /* @__PURE__ */ G("span", {
|
|
14370
14370
|
"data-slot": "carousel-indicator-dot",
|
|
14371
|
-
className: n("block h-2 w-2 rounded-full bg-foreground/30 group-hover/indicator:bg-foreground/50 forced-colors:bg-[ButtonText]", l && "bg-primary group-hover/indicator:bg-primary forced-colors:bg-[Highlight]", l && e === "pill" && "w-6")
|
|
14371
|
+
className: n("block h-2 w-2 rounded-full bg-foreground/30 group-hover/indicator:bg-foreground/50 forced-colors:bg-[ButtonText]", l && "bg-primary-indicator group-hover/indicator:bg-primary-indicator forced-colors:bg-[Highlight]", l && e === "pill" && "w-6")
|
|
14372
14372
|
})
|
|
14373
14373
|
}, i);
|
|
14374
14374
|
})
|
|
@@ -14571,7 +14571,7 @@ function pD() {
|
|
|
14571
14571
|
type: "button",
|
|
14572
14572
|
"aria-label": dD(e),
|
|
14573
14573
|
"aria-current": t.currentIndex === i || void 0,
|
|
14574
|
-
className: n("h-1.5 cursor-pointer rounded-full [transition:width_var(--nxgt-motion-spatial-fast-duration)_var(--nxgt-motion-spatial-fast),background-color_var(--nxgt-motion-effects-default-duration)_var(--nxgt-motion-effects-default)]", WE, t.currentIndex === i ? "w-5 bg-primary" : "w-1.5 bg-foreground/30 hover:bg-foreground/50"),
|
|
14574
|
+
className: n("h-1.5 cursor-pointer rounded-full [transition:width_var(--nxgt-motion-spatial-fast-duration)_var(--nxgt-motion-spatial-fast),background-color_var(--nxgt-motion-effects-default-duration)_var(--nxgt-motion-effects-default)]", WE, t.currentIndex === i ? "w-5 bg-primary-indicator" : "w-1.5 bg-foreground/30 hover:bg-foreground/50"),
|
|
14575
14575
|
onClick: () => r(i)
|
|
14576
14576
|
}, e.id))
|
|
14577
14577
|
});
|
|
@@ -14887,7 +14887,7 @@ function JD({ shape: e, target: t }) {
|
|
|
14887
14887
|
"data-slot": "media-mini-target",
|
|
14888
14888
|
"data-corner": r,
|
|
14889
14889
|
"data-active": r === t || void 0,
|
|
14890
|
-
className: n("pointer-events-none fixed z-40 border-2 border-dashed border-primary/60 bg-primary/5 data-active:border-primary data-active:bg-primary/15 forced-colors:border-[Highlight]", kD[r], AD[e], jD[e])
|
|
14890
|
+
className: n("pointer-events-none fixed z-40 border-2 border-dashed border-primary/60 bg-primary/5 data-active:border-primary-indicator data-active:bg-primary/15 forced-colors:border-[Highlight]", kD[r], AD[e], jD[e])
|
|
14891
14891
|
}, r));
|
|
14892
14892
|
}
|
|
14893
14893
|
//#endregion
|
|
@@ -22891,7 +22891,7 @@ function FL({ entry: e, id: t, selected: r, startsGroup: i, onPick: a }) {
|
|
|
22891
22891
|
tabIndex: -1,
|
|
22892
22892
|
onMouseDown: (e) => e.preventDefault(),
|
|
22893
22893
|
onClick: a,
|
|
22894
|
-
className: n("flex cursor-pointer items-center gap-3 rounded-md px-2 py-1.5 text-sm", "hover:bg-accent aria-selected:bg-primary/10 aria-selected:shadow-[inset_2px_0_0_var(--color-primary)]"),
|
|
22894
|
+
className: n("flex cursor-pointer items-center gap-3 rounded-md px-2 py-1.5 text-sm", "hover:bg-accent aria-selected:bg-primary/10 aria-selected:shadow-[inset_2px_0_0_var(--color-primary-indicator)]"),
|
|
22895
22895
|
children: [
|
|
22896
22896
|
o && /* @__PURE__ */ G("span", {
|
|
22897
22897
|
className: "flex size-8 shrink-0 items-center justify-center rounded-md border bg-muted/30",
|
|
@@ -23093,7 +23093,7 @@ function JL({ className: e, variant: t = "docked", layout: r, dividers: i = !0,
|
|
|
23093
23093
|
//#region lib/components/ui/display/status-indicator/status-indicator.tsx
|
|
23094
23094
|
var YL = {
|
|
23095
23095
|
neutral: "bg-muted-foreground",
|
|
23096
|
-
primary: "bg-primary",
|
|
23096
|
+
primary: "bg-primary-indicator",
|
|
23097
23097
|
success: "bg-success",
|
|
23098
23098
|
info: "bg-info",
|
|
23099
23099
|
warning: "bg-warning",
|
|
@@ -23423,7 +23423,7 @@ function _R({ sendLabel: e, stopLabel: t, isDisabled: r, isEmpty: i, onStop: a,
|
|
|
23423
23423
|
//#endregion
|
|
23424
23424
|
//#region lib/components/ui/widgets/chat/chat-reply-quote.tsx
|
|
23425
23425
|
function vR({ author: e, content: t, onClick: r, tone: i = "default", className: a, ...o }) {
|
|
23426
|
-
let { t: s } = L(), c = n("flex w-full min-w-0 flex-col gap-0.5 rounded-(--nxgt-shape-corner-sm) border-s-[3px] px-2.5 py-1.5 text-start text-xs", i === "inverted" ? "border-primary-foreground/70 bg-primary-foreground/15 text-primary-foreground" : "border-primary bg-primary/8 text-foreground", r && "cursor-pointer outline-none transition-colors duration-(--nxgt-motion-effects-fast-duration) ease-effects-fast hover:bg-primary/15 focus-visible:ring-[3px] focus-visible:ring-ring/50 forced-colors:focus-visible:outline-2 forced-colors:focus-visible:outline-solid forced-colors:focus-visible:outline-[Highlight]", a), l = /* @__PURE__ */ K(Xa, { children: [e != null && /* @__PURE__ */ G("span", {
|
|
23426
|
+
let { t: s } = L(), c = n("flex w-full min-w-0 flex-col gap-0.5 rounded-(--nxgt-shape-corner-sm) border-s-[3px] px-2.5 py-1.5 text-start text-xs", i === "inverted" ? "border-primary-foreground/70 bg-primary-foreground/15 text-primary-foreground" : "border-primary-indicator bg-primary/8 text-foreground", r && "cursor-pointer outline-none transition-colors duration-(--nxgt-motion-effects-fast-duration) ease-effects-fast hover:bg-primary/15 focus-visible:ring-[3px] focus-visible:ring-ring/50 forced-colors:focus-visible:outline-2 forced-colors:focus-visible:outline-solid forced-colors:focus-visible:outline-[Highlight]", a), l = /* @__PURE__ */ K(Xa, { children: [e != null && /* @__PURE__ */ G("span", {
|
|
23427
23427
|
className: n("truncate font-semibold", i === "inverted" ? "" : "text-primary-text"),
|
|
23428
23428
|
children: e
|
|
23429
23429
|
}), /* @__PURE__ */ G("span", {
|
package/docs/guides/theming.md
CHANGED
|
@@ -65,6 +65,7 @@ at the top are needed is in [getting started](../getting-started.md#styles).
|
|
|
65
65
|
| `--nxgt-accent` | `[--nxgt-accent:…]` | the mark colour of the selection controls: the fill, handle, state layer and stop dots of `Slider`, the on state of `Switch`, the box and dot of `Checkbox` and `Radio`. It defaults to `--primary` (`--primary-text` in dark) and is set per control, so override it on the control itself, not on `:root` |
|
|
66
66
|
| `--error`, `--success`, `--info`, `--warning` (+ `-foreground`) | `bg-error`, `text-success`, … | the status colours of `Button`, `Alert`, `Badge`, toasts |
|
|
67
67
|
| `--primary-text` | `text-primary-text` | primary drawn as text or an icon on a page, card or popover surface: `Typography tone="primary"`, links, the `Alert` primary icon, selected labels. Equal to `--primary` in light; in dark, `--primary` mixed 60 % with white (`color-mix(in oklab, var(--primary) 40%, white)`), well over 4.5:1 on `--background` and `--card` |
|
|
68
|
+
| `--primary-indicator` | `bg-primary-indicator`, `border-primary-indicator`, `ring-primary-indicator`, `stroke-primary-indicator` | primary drawn as a non-text mark that carries a state (WCAG 1.4.11, 3:1): an active bar or dot, a selected or focused border, a ring, a spinner arc. Equal to `--primary` in light; in dark, `--primary` mixed 25 % with white (`color-mix(in oklab, var(--primary) 75%, white)`), 4.5:1 on `--background`, 4.1:1 on `--card`, 3.7:1 on `--muted` (`--primary` itself gives 2.5, 2.3 and 2.1:1) |
|
|
68
69
|
| `--error-text` | `text-error-text` | error drawn as text: field messages, `HelperText` in its error state, form and dialog errors, `variant="error"` menu items |
|
|
69
70
|
| `--destructive` | `bg-destructive`, `text-destructive` | deprecated alias of `--error`: the light theme sets it to `var(--error)`, the dark theme keeps its own value; use `--error` |
|
|
70
71
|
| `--card`, `--popover`, `--tooltip` (+ `-foreground`) | `bg-card`, `bg-popover`, `bg-tooltip` | surfaces |
|
package/docs/troubleshooting.md
CHANGED
|
@@ -960,6 +960,15 @@ An app that overrides `--primary` under `:root` and `.dark, [data-theme="dark"]`
|
|
|
960
960
|
gets `--primary-text` for free; set `--primary-text` after it to choose another
|
|
961
961
|
colour. On an element below the root, set `--color-primary-text`.
|
|
962
962
|
|
|
963
|
+
The same goes for a primary mark that is not text: a bar, a dot, a selected or
|
|
964
|
+
focused border, a ring or a spinner arc. In dark, `--primary` is only 2.1 to
|
|
965
|
+
2.5:1 on the surfaces, under the 3:1 of WCAG 1.4.11. Draw it with
|
|
966
|
+
`bg-primary-indicator`, `border-primary-indicator`, `ring-primary-indicator` or
|
|
967
|
+
`stroke-primary-indicator`: `--primary-indicator` is `--primary` in light and
|
|
968
|
+
`--primary` mixed 25 % with white in dark (3.7:1 or more on `--background`,
|
|
969
|
+
`--card` and `--muted`). It follows an app's own `--primary`; set
|
|
970
|
+
`--primary-indicator` after it to choose another dark colour.
|
|
971
|
+
|
|
963
972
|
### `expectTapTargets` reports a checkbox, switch or chip remove button under 44px
|
|
964
973
|
|
|
965
974
|
**When:** a phone project's `expectTapTargets` (`@nxgt/playwright`) lists a
|
package/lib/components/base.css
CHANGED
|
@@ -124,7 +124,7 @@
|
|
|
124
124
|
height: 0.55em;
|
|
125
125
|
transform: scale(0);
|
|
126
126
|
transition: 120ms transform ease-in-out;
|
|
127
|
-
box-shadow: inset 1em 1em var(--color-primary);
|
|
127
|
+
box-shadow: inset 1em 1em var(--color-primary-indicator);
|
|
128
128
|
}
|
|
129
129
|
input[type="checkbox"]:checked::before {
|
|
130
130
|
transform: scale(1);
|
|
@@ -37,6 +37,11 @@
|
|
|
37
37
|
border-color: color-mix(in oklab, var(--primary) 60%, transparent);
|
|
38
38
|
box-shadow: 0 0 0 3px color-mix(in oklab, var(--primary) 50%, transparent);
|
|
39
39
|
}
|
|
40
|
+
/* Dark: the 60 % border is under 3:1 on the card (WCAG 1.4.11). */
|
|
41
|
+
:is(.dark, [data-theme="dark"])
|
|
42
|
+
[data-slot="compact-editor"][data-look="expressive"]:focus-within {
|
|
43
|
+
border-color: var(--primary-indicator);
|
|
44
|
+
}
|
|
40
45
|
[data-slot="editor-field"][data-invalid]
|
|
41
46
|
:is(
|
|
42
47
|
[data-slot="compact-editor"],
|
|
@@ -115,7 +115,7 @@
|
|
|
115
115
|
}
|
|
116
116
|
|
|
117
117
|
blockquote {
|
|
118
|
-
border-inline-start: 3px solid var(--primary);
|
|
118
|
+
border-inline-start: 3px solid var(--primary-indicator);
|
|
119
119
|
padding-inline-start: 1.1em;
|
|
120
120
|
color: var(--muted-foreground);
|
|
121
121
|
font-family: var(--nxgt-prose-heading-font);
|
|
@@ -17,6 +17,11 @@
|
|
|
17
17
|
the violet page (7.9:1 on a Card; the colour itself gives 6.8:1 on the
|
|
18
18
|
page); the dark theme lifts it. */
|
|
19
19
|
--primary-text: color-mix(in oklab, var(--primary) 96%, black);
|
|
20
|
+
/* Primary drawn as a non-text mark (WCAG 1.4.11, 3:1): an indicator bar or dot,
|
|
21
|
+
a selected or focused border, a ring, a spinner arc, a progress fill
|
|
22
|
+
(`bg-primary-indicator`, `border-primary-indicator`...). Light is --primary;
|
|
23
|
+
the dark theme lifts it. */
|
|
24
|
+
--primary-indicator: var(--primary);
|
|
20
25
|
/* --secondary, --success and --info are 0.02 darker than before: on the
|
|
21
26
|
violet page tint (--background, 97.3 %) their own 15 % tonal tint gave the
|
|
22
27
|
text 4.3 to 4.5:1; now 4.7:1 or more on the page and on a Card. */
|
|
@@ -104,6 +109,9 @@
|
|
|
104
109
|
/* Mixed 60 % toward white (the tonal Button labels' recipe): readable as text
|
|
105
110
|
on --background and --card. */
|
|
106
111
|
--primary-text: color-mix(in oklab, var(--primary) 40%, white);
|
|
112
|
+
/* --primary itself is 2.5:1 on --background, 2.3:1 on --card and 2.1:1 on
|
|
113
|
+
--muted. Mixed 25 % toward white: 4.5:1, 4.1:1 and 3.7:1. */
|
|
114
|
+
--primary-indicator: color-mix(in oklab, var(--primary) 75%, white);
|
|
107
115
|
/* Brighter than the light one: it is read as text on the dark surfaces (6.3:1
|
|
108
116
|
on --background, 5.8:1 on --card; 4.6:1 on its own 15 % tonal tint over a
|
|
109
117
|
Card). A filled secondary surface mixes it toward --background (the opaque
|
|
@@ -49,8 +49,8 @@
|
|
|
49
49
|
pointer-events: none;
|
|
50
50
|
}
|
|
51
51
|
[data-slot="period-card"][data-state="current"] {
|
|
52
|
-
--card-bar: var(--primary);
|
|
53
|
-
border-color: var(--primary);
|
|
52
|
+
--card-bar: var(--primary-indicator);
|
|
53
|
+
border-color: var(--primary-indicator);
|
|
54
54
|
background: color-mix(in oklab, var(--primary) 7%, var(--card));
|
|
55
55
|
}
|
|
56
56
|
[data-slot="period-card"][data-state="past"] {
|
package/lib/styles.css
CHANGED
|
@@ -55,6 +55,7 @@
|
|
|
55
55
|
--color-primary: var(--primary);
|
|
56
56
|
--color-primary-foreground: var(--primary-foreground);
|
|
57
57
|
--color-primary-text: var(--primary-text);
|
|
58
|
+
--color-primary-indicator: var(--primary-indicator);
|
|
58
59
|
/* Containers: a tint of the base colour over the surface, from the variant that
|
|
59
60
|
* is lifted in dark (primary-text, error-text) so it shows there too. Accent, a
|
|
60
61
|
* near-grey a tint would hide, is the colour itself. Text on one: `text-foreground`. */
|