@nxgt/material 3.49.0 → 3.50.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (77) hide show
  1. package/CHANGELOG.md +22 -0
  2. package/README.md +1 -1
  3. package/dist/{async-slice-DlvKCKAa.js → async-slice-3loEtzUY.js} +2 -2
  4. package/dist/{button-DJgaQbBD.js → button-BRUaHD8z.js} +45 -76
  5. package/dist/charts.js +3 -3
  6. package/dist/{chip-DN44R1vW.js → chip-DneTrtNj.js} +3 -3
  7. package/dist/{code-editor-BJ9ewxSC.js → code-editor-R_nPN_-d.js} +6 -6
  8. package/dist/code-editor.js +5 -5
  9. package/dist/{code-language-items-BJE3VuQg.js → code-language-items-BKEUhQlF.js} +2 -2
  10. package/dist/{components-AtBccCir.js → components-D6xFLcoE.js} +11464 -11348
  11. package/dist/components.js +26 -27
  12. package/dist/{dialog-ODql4vH7.js → dialog-S7dLsYRZ.js} +7 -7
  13. package/dist/dnd.js +1 -1
  14. package/dist/{dropdown-menu-DRXYP9ta.js → dropdown-menu-XLlxfDgq.js} +25 -26
  15. package/dist/editor.js +9 -9
  16. package/dist/{empty-state-C9QqvBU1.js → empty-state-Dsf6R-Zo.js} +2 -2
  17. package/dist/{escape-owner-DCrlERLM.js → escape-owner-B9eCwjLw.js} +1 -1
  18. package/dist/{field-blur-DYGyIdfD.js → field-blur-5uRDFHvB.js} +1 -1
  19. package/dist/{field-blur-context-B-fSpl1H.js → field-blur-context-Cwt4TuBq.js} +1 -1
  20. package/dist/hooks.js +2 -2
  21. package/dist/{hover-card-EO_CckIx.js → hover-card-PHUgRSjJ.js} +14 -14
  22. package/dist/{i18n-provider-C0fB0sEL.js → i18n-provider-DPM_ALQ4.js} +1 -1
  23. package/dist/i18n.js +5 -5
  24. package/dist/{icon-badge-BQYj_LE6.js → icon-badge-Dh6-FNOF.js} +3 -3
  25. package/dist/{icon-button-B481L2TP.js → icon-button-DSC2-IAG.js} +119 -87
  26. package/dist/lib/components/ui/actions/icon-button/icon-button-busy.d.ts +22 -0
  27. package/dist/lib/components/ui/actions/icon-button/icon-button-shape.d.ts +2 -0
  28. package/dist/lib/components/ui/actions/icon-button/icon-button.d.ts +7 -0
  29. package/dist/lib/components/ui/collections/filter/bar/partials/filter-quick-toggle.d.ts +3 -2
  30. package/dist/lib/components/ui/collections/filter/sections/filter-sections-classes.d.ts +7 -1
  31. package/dist/lib/components/ui/collections/page-footer/page-footer.d.ts +6 -1
  32. package/dist/lib/components/ui/collections/row-menu/row-menu-trigger.d.ts +5 -2
  33. package/dist/lib/components/ui/collections/server-table/index.d.ts +1 -1
  34. package/dist/lib/components/ui/collections/server-table/partials/server-table-empty-chips.d.ts +5 -3
  35. package/dist/lib/components/ui/collections/server-table/types-paging.d.ts +17 -0
  36. package/dist/lib/components/ui/collections/server-table/types.d.ts +3 -10
  37. package/dist/lib/components/ui/feedback/step-up-dialog/partials/step-up-body.d.ts +5 -3
  38. package/dist/lib/components/ui/feedback/step-up-dialog/partials/step-up-request-error.d.ts +15 -0
  39. package/dist/lib/components/ui/feedback/step-up-dialog/step-up-dialog.d.ts +6 -3
  40. package/dist/lib/components/ui/feedback/step-up-dialog/types.d.ts +12 -1
  41. package/dist/lib/components/ui/feedback/step-up-dialog/use-retry-focus.d.ts +27 -0
  42. package/dist/lib/components/ui/feedback/step-up-dialog/use-retry.d.ts +11 -0
  43. package/dist/lib/components/ui/fields/contacts/placeholders.d.ts +1 -1
  44. package/dist/lib/components/ui/fields/verification-code/use-settled-focus.d.ts +10 -0
  45. package/dist/lib/i18n/resources/en/en.d.ts +1 -0
  46. package/dist/lib/i18n/resources/en/material.json.d.ts +2 -1
  47. package/dist/lib/i18n/resources/fr/fr.d.ts +1 -0
  48. package/dist/lib/i18n/resources/fr/material.json.d.ts +2 -1
  49. package/dist/lib/i18n/resources/resources.d.ts +2 -0
  50. package/dist/lib/i18n/translator.d.ts +1 -1
  51. package/dist/lib.js +1 -1
  52. package/dist/main.js +43 -44
  53. package/dist/map.js +8 -8
  54. package/dist/material.css +1 -1
  55. package/dist/pdf-reader.js +1 -1
  56. package/dist/print.js +2 -2
  57. package/dist/{public-CZBz4JVu.js → public-vxiijIJF.js} +20 -20
  58. package/dist/{rich-code-block-597e0_Qm.js → rich-code-block-BwvCXPqq.js} +5 -5
  59. package/dist/{sortable-provider-CK_xAk2H.js → sortable-provider-D2pAFWQB.js} +2 -2
  60. package/dist/{dist-B61_o9Mg.js → spinner-BpVwI1ps.js} +478 -256
  61. package/dist/{stored-language-IaL1Ftn_.js → stored-language-Beyj2ult.js} +4 -2
  62. package/dist/theme-picker.js +2 -2
  63. package/dist/{theme-toggle-Dnjn83TJ.js → theme-toggle-BTYRPkP4.js} +1 -1
  64. package/dist/{toolbar-items-CCwIu7fE.js → toolbar-items-CIMo4F9q.js} +106 -106
  65. package/dist/{translate-material-v9u-e7Kd.js → translate-material-DEUlaL_1.js} +2 -2
  66. package/dist/{translator-Dk4_qE6U.js → translator-CBgIb3zP.js} +1 -1
  67. package/dist/{use-chat-composer-Ot5XUbdn.js → use-chat-composer-D8UAsX0f.js} +4881 -4882
  68. package/dist/{button-tones-BwuVvAmd.js → use-click-lock-BZYtTmVt.js} +37 -7
  69. package/dist/{use-heading-spy-DjKixjLm.js → use-heading-spy-C5LXtA8Z.js} +1 -1
  70. package/dist/{use-material-translation-DOkTaWK_.js → use-material-translation-DWWeeg-B.js} +2 -2
  71. package/docs/components/buttons-and-actions.md +2 -1
  72. package/docs/components/data-table-filter-and-lists.md +29 -9
  73. package/docs/components/feedback-and-status.md +22 -3
  74. package/docs/components/form-fields.md +7 -0
  75. package/docs/guides/server-lists-url.md +3 -2
  76. package/package.json +1 -1
  77. package/dist/spinner-BhuZuHK1.js +0 -229
package/dist/i18n.js CHANGED
@@ -1,10 +1,10 @@
1
1
  import { t as e } from "./is-production-GLw59WU8.js";
2
- import { a as t, i as n, n as r, r as i } from "./stored-language-IaL1Ftn_.js";
3
- import { n as a, r as o, t as s } from "./i18n-provider-C0fB0sEL.js";
4
- import { i as c, n as l, o as u, r as d, t as f } from "./translator-Dk4_qE6U.js";
2
+ import { a as t, i as n, n as r, r as i } from "./stored-language-Beyj2ult.js";
3
+ import { n as a, r as o, t as s } from "./i18n-provider-DPM_ALQ4.js";
4
+ import { i as c, n as l, o as u, r as d, t as f } from "./translator-CBgIb3zP.js";
5
5
  import { o as p, t as m } from "./merge-BCZE6HGq.js";
6
- import { t as h } from "./translate-material-v9u-e7Kd.js";
7
- import { t as g } from "./use-material-translation-DOkTaWK_.js";
6
+ import { t as h } from "./translate-material-DEUlaL_1.js";
7
+ import { t as g } from "./use-material-translation-DWWeeg-B.js";
8
8
  import { useCallback as _ } from "react";
9
9
  //#region lib/i18n/merge-resources.ts
10
10
  function v(e, t, n = "") {
@@ -1,7 +1,7 @@
1
1
  import { t as e } from "./utils-BLfntITJ.js";
2
- import { f as t } from "./dialog-ODql4vH7.js";
3
- import { a as n, i as r, n as i } from "./field-blur-context-B-fSpl1H.js";
4
- import { t as a } from "./icon-button-B481L2TP.js";
2
+ import { f as t } from "./dialog-S7dLsYRZ.js";
3
+ import { a as n, i as r, n as i } from "./field-blur-context-Cwt4TuBq.js";
4
+ import { t as a } from "./icon-button-DSC2-IAG.js";
5
5
  import { isValidElement as o, useId as s } from "react";
6
6
  import { jsx as c, jsxs as l } from "react/jsx-runtime";
7
7
  import { describedBy as u } from "@nxgt/material-core/described-by";
@@ -2,20 +2,20 @@ import { t as e } from "./utils-BLfntITJ.js";
2
2
  import { t } from "./is-production-GLw59WU8.js";
3
3
  import { n } from "./use-shape-morph-BKA_R5P5.js";
4
4
  import { n as r, t as i } from "./dist-DVRQkaTK.js";
5
- import { n as a, t as o } from "./dist-B61_o9Mg.js";
6
- import { a as s, i as c, n as l, r as u, t as d } from "./button-tones-BwuVvAmd.js";
7
- import { t as f } from "./button-group-context-CaP0X5p_.js";
8
- import { shapeOutline as p, toSvgPath as m } from "@nxgt/material-core/shapes";
9
- import { useContext as h, useEffect as g, useRef as _ } from "react";
10
- import { jsx as v, jsxs as y } from "react/jsx-runtime";
5
+ import { n as a, r as o, t as s } from "./spinner-BpVwI1ps.js";
6
+ import { a as c, i as l, n as u, o as d, r as f, s as p, t as m } from "./use-click-lock-BZYtTmVt.js";
7
+ import { t as h } from "./button-group-context-CaP0X5p_.js";
8
+ import { shapeOutline as g, toSvgPath as _ } from "@nxgt/material-core/shapes";
9
+ import { useContext as v, useEffect as y, useRef as b } from "react";
10
+ import { jsx as x, jsxs as S } from "react/jsx-runtime";
11
11
  //#region lib/components/ui/display/count-badge/format-count.ts
12
- function b(e, t = 99) {
12
+ function C(e, t = 99) {
13
13
  let n = Math.max(0, Math.round(e));
14
14
  return n > t ? `${t}+` : String(n);
15
15
  }
16
16
  //#endregion
17
17
  //#region lib/components/ui/actions/icon-button/icon-button.compound-variants.ts
18
- var x = [
18
+ var w = [
19
19
  {
20
20
  variant: "filled",
21
21
  color: "primary",
@@ -54,37 +54,37 @@ var x = [
54
54
  {
55
55
  variant: "tonal",
56
56
  color: "primary",
57
- class: `${u.primary} ${d.primary} ${l.primary} bg-primary/15 hover:bg-primary/10 active:bg-primary/5 focus:bg-primary/10`
57
+ class: `${l.primary} ${u.primary} ${f.primary} bg-primary/15 hover:bg-primary/10 active:bg-primary/5 focus:bg-primary/10`
58
58
  },
59
59
  {
60
60
  variant: "tonal",
61
61
  color: "secondary",
62
- class: `${u.secondary} ${d.secondary} ${l.secondary} bg-secondary/15 hover:bg-secondary/10 active:bg-secondary/5 focus:bg-secondary/10`
62
+ class: `${l.secondary} ${u.secondary} ${f.secondary} bg-secondary/15 hover:bg-secondary/10 active:bg-secondary/5 focus:bg-secondary/10`
63
63
  },
64
64
  {
65
65
  variant: "tonal",
66
66
  color: "success",
67
- class: `${u.success} ${d.success} ${l.success} bg-success/15 hover:bg-success/10 active:bg-success/5 focus:bg-success/10`
67
+ class: `${l.success} ${u.success} ${f.success} bg-success/15 hover:bg-success/10 active:bg-success/5 focus:bg-success/10`
68
68
  },
69
69
  {
70
70
  variant: "tonal",
71
71
  color: "info",
72
- class: `${u.info} ${d.info} ${l.info} bg-info/15 hover:bg-info/10 active:bg-info/5 focus:bg-info/10`
72
+ class: `${l.info} ${u.info} ${f.info} bg-info/15 hover:bg-info/10 active:bg-info/5 focus:bg-info/10`
73
73
  },
74
74
  {
75
75
  variant: "tonal",
76
76
  color: "warning",
77
- class: `${u.warning} ${d.warning} ${l.warning} bg-warning/15 hover:bg-warning/10 active:bg-warning/5 focus:bg-warning/10`
77
+ class: `${l.warning} ${u.warning} ${f.warning} bg-warning/15 hover:bg-warning/10 active:bg-warning/5 focus:bg-warning/10`
78
78
  },
79
79
  {
80
80
  variant: "tonal",
81
81
  color: "error",
82
- class: `${u.error} ${d.error} ${l.error} bg-error/15 hover:bg-error/10 active:bg-error/5 focus:bg-error/10`
82
+ class: `${l.error} ${u.error} ${f.error} bg-error/15 hover:bg-error/10 active:bg-error/5 focus:bg-error/10`
83
83
  },
84
84
  {
85
85
  variant: "tonal",
86
86
  color: "default",
87
- class: `${u.default} ${d.default} ${l.default} bg-foreground/15 hover:bg-foreground/10 active:bg-muted focus:bg-muted`
87
+ class: `${l.default} ${u.default} ${f.default} bg-foreground/15 hover:bg-foreground/10 active:bg-muted focus:bg-muted`
88
88
  },
89
89
  {
90
90
  variant: "ghost",
@@ -99,99 +99,99 @@ var x = [
99
99
  {
100
100
  variant: "ghost",
101
101
  color: "secondary",
102
- class: `${u.secondary} ${d.secondary} ${l.secondary} hover:bg-secondary/10 active:bg-secondary/5 focus:bg-secondary/10`
102
+ class: `${l.secondary} ${u.secondary} ${f.secondary} hover:bg-secondary/10 active:bg-secondary/5 focus:bg-secondary/10`
103
103
  },
104
104
  {
105
105
  variant: "ghost",
106
106
  color: "success",
107
- class: `${u.success} ${d.success} ${l.success} hover:bg-success/10 active:bg-success/5 focus:bg-success/10`
107
+ class: `${l.success} ${u.success} ${f.success} hover:bg-success/10 active:bg-success/5 focus:bg-success/10`
108
108
  },
109
109
  {
110
110
  variant: "ghost",
111
111
  color: "info",
112
- class: `${u.info} ${d.info} ${l.info} hover:bg-info/10 active:bg-info/5 focus:bg-info/10`
112
+ class: `${l.info} ${u.info} ${f.info} hover:bg-info/10 active:bg-info/5 focus:bg-info/10`
113
113
  },
114
114
  {
115
115
  variant: "ghost",
116
116
  color: "warning",
117
- class: `${u.warning} ${d.warning} ${l.warning} hover:bg-warning/10 active:bg-warning/5 focus:bg-warning/10`
117
+ class: `${l.warning} ${u.warning} ${f.warning} hover:bg-warning/10 active:bg-warning/5 focus:bg-warning/10`
118
118
  },
119
119
  {
120
120
  variant: "ghost",
121
121
  color: "error",
122
- class: `${u.error} ${d.error} ${l.error} hover:bg-error/10 active:bg-error/5 focus:bg-error/10`
122
+ class: `${l.error} ${u.error} ${f.error} hover:bg-error/10 active:bg-error/5 focus:bg-error/10`
123
123
  },
124
124
  {
125
125
  variant: "outlined",
126
126
  color: "primary",
127
- class: `${u.primary} ${d.primary} ${l.primary} focus:bg-primary/10 hover:bg-primary/10`
127
+ class: `${l.primary} ${u.primary} ${f.primary} focus:bg-primary/10 hover:bg-primary/10`
128
128
  },
129
129
  {
130
130
  variant: "outlined",
131
131
  color: "secondary",
132
- class: `${u.secondary} ${d.secondary} ${l.secondary} focus:bg-secondary/10 hover:bg-secondary/10`
132
+ class: `${l.secondary} ${u.secondary} ${f.secondary} focus:bg-secondary/10 hover:bg-secondary/10`
133
133
  },
134
134
  {
135
135
  variant: "outlined",
136
136
  color: "success",
137
- class: `${u.success} ${d.success} ${l.success} focus:bg-success/10 hover:bg-success/10`
137
+ class: `${l.success} ${u.success} ${f.success} focus:bg-success/10 hover:bg-success/10`
138
138
  },
139
139
  {
140
140
  variant: "outlined",
141
141
  color: "info",
142
- class: `${u.info} ${d.info} ${l.info} focus:bg-info/10 hover:bg-info/10`
142
+ class: `${l.info} ${u.info} ${f.info} focus:bg-info/10 hover:bg-info/10`
143
143
  },
144
144
  {
145
145
  variant: "outlined",
146
146
  color: "warning",
147
- class: `${u.warning} ${d.warning} ${l.warning} focus:bg-warning/10 hover:bg-warning/10`
147
+ class: `${l.warning} ${u.warning} ${f.warning} focus:bg-warning/10 hover:bg-warning/10`
148
148
  },
149
149
  {
150
150
  variant: "outlined",
151
151
  color: "error",
152
- class: `${u.error} ${d.error} ${l.error} focus:bg-error/10 hover:bg-error/10`
152
+ class: `${l.error} ${u.error} ${f.error} focus:bg-error/10 hover:bg-error/10`
153
153
  },
154
154
  {
155
155
  variant: "outlined",
156
156
  color: "default",
157
- class: `${u.default} ${d.default} ${l.default} focus:bg-foreground/10 hover:bg-foreground/10`
157
+ class: `${l.default} ${u.default} ${f.default} focus:bg-foreground/10 hover:bg-foreground/10`
158
158
  },
159
159
  {
160
160
  variant: "link",
161
161
  color: "primary",
162
- class: `${u.primary} ${d.primary} ${l.primary} underline-offset-4 hover:underline hover:bg-primary/10 active:bg-primary/5 focus:bg-primary/10`
162
+ class: `${l.primary} ${u.primary} ${f.primary} underline-offset-4 hover:underline hover:bg-primary/10 active:bg-primary/5 focus:bg-primary/10`
163
163
  },
164
164
  {
165
165
  variant: "link",
166
166
  color: "secondary",
167
- class: `${u.secondary} ${d.secondary} ${l.secondary} underline-offset-4 hover:underline hover:bg-secondary/10 active:bg-secondary/5 focus:bg-secondary/10`
167
+ class: `${l.secondary} ${u.secondary} ${f.secondary} underline-offset-4 hover:underline hover:bg-secondary/10 active:bg-secondary/5 focus:bg-secondary/10`
168
168
  },
169
169
  {
170
170
  variant: "link",
171
171
  color: "success",
172
- class: `${u.success} ${d.success} ${l.success} underline-offset-4 hover:underline hover:bg-success/10 active:bg-success/5 focus:bg-success/10`
172
+ class: `${l.success} ${u.success} ${f.success} underline-offset-4 hover:underline hover:bg-success/10 active:bg-success/5 focus:bg-success/10`
173
173
  },
174
174
  {
175
175
  variant: "link",
176
176
  color: "info",
177
- class: `${u.info} ${d.info} ${l.info} underline-offset-4 hover:underline hover:bg-info/10 active:bg-info/5 focus:bg-info/10`
177
+ class: `${l.info} ${u.info} ${f.info} underline-offset-4 hover:underline hover:bg-info/10 active:bg-info/5 focus:bg-info/10`
178
178
  },
179
179
  {
180
180
  variant: "link",
181
181
  color: "warning",
182
- class: `${u.warning} ${d.warning} ${l.warning} underline-offset-4 hover:underline hover:bg-warning/10 active:bg-warning/5 focus:bg-warning/10`
182
+ class: `${l.warning} ${u.warning} ${f.warning} underline-offset-4 hover:underline hover:bg-warning/10 active:bg-warning/5 focus:bg-warning/10`
183
183
  },
184
184
  {
185
185
  variant: "link",
186
186
  color: "error",
187
- class: `${u.error} ${d.error} ${l.error} underline-offset-4 hover:underline hover:bg-error/10 active:bg-error/5 focus:bg-error/10`
187
+ class: `${l.error} ${u.error} ${f.error} underline-offset-4 hover:underline hover:bg-error/10 active:bg-error/5 focus:bg-error/10`
188
188
  },
189
189
  {
190
190
  variant: "link",
191
191
  color: "default",
192
- class: `${u.default} ${d.default} ${l.default} underline-offset-4 hover:underline hover:bg-foreground/10 active:bg-muted focus:bg-foreground/10`
192
+ class: `${l.default} ${u.default} ${f.default} underline-offset-4 hover:underline hover:bg-foreground/10 active:bg-muted focus:bg-foreground/10`
193
193
  }
194
- ], S = o("inline-flex center gap-2 cursor-pointer whitespace-nowrap text-sm font-medium disabled:pointer-events-none [&_svg]:bg-transparent [&_svg]:text-foreground [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-(--btn-ic,1rem) shrink-0 [&_svg]:shrink-0", {
194
+ ], T = a("inline-flex center gap-2 cursor-pointer whitespace-nowrap text-sm font-medium disabled:pointer-events-none [&_svg]:bg-transparent [&_svg]:text-foreground [&_svg]:pointer-events-none [&_svg:not([class*='size-'])]:size-(--btn-ic,1rem) shrink-0 [&_svg]:shrink-0", {
195
195
  variants: {
196
196
  look: {
197
197
  btn: "nxgt-btn nxgt-morph-fill aria-invalid:[--btn-focus:var(--color-error)] aria-invalid:[--btn-line:var(--color-error)]",
@@ -226,22 +226,45 @@ var x = [
226
226
  size: "legacy",
227
227
  width: "default"
228
228
  },
229
- compoundVariants: [...x, {
229
+ compoundVariants: [...w, {
230
230
  look: "btn",
231
231
  size: "legacy",
232
232
  width: "default",
233
233
  class: "[--btn-round:50%]"
234
234
  }]
235
235
  });
236
- function C(e) {
237
- return (t) => S({
236
+ function E(e) {
237
+ return (t) => T({
238
238
  ...t,
239
239
  look: e,
240
240
  size: t?.size ?? "legacy",
241
241
  color: t?.variant === "ghost" && t.color == null ? "default" : t?.color
242
242
  });
243
243
  }
244
- var w = C("btn"), T = C("shaped"), E = {
244
+ var D = E("btn"), O = E("shaped");
245
+ //#endregion
246
+ //#region lib/components/ui/actions/icon-button/icon-button-busy.tsx
247
+ function k(e, t) {
248
+ let n = m(!1, e);
249
+ return {
250
+ busyClassName: e ? "relative [&_[data-slot=icon]]:invisible" : void 0,
251
+ hostProps: {
252
+ "aria-disabled": e || t["aria-disabled"],
253
+ "aria-busy": e || t["aria-busy"],
254
+ onClickCapture: d(e, n, t.onClickCapture)
255
+ }
256
+ };
257
+ }
258
+ function A({ variant: e, color: t }) {
259
+ return /* @__PURE__ */ x(s, {
260
+ variant: "2",
261
+ color: e === "filled" ? "light" : t ?? (e === "ghost" ? "default" : "primary"),
262
+ className: "absolute inset-0 m-auto size-(--btn-ic,1rem)"
263
+ });
264
+ }
265
+ //#endregion
266
+ //#region lib/components/ui/actions/icon-button/icon-button-surface.ts
267
+ var j = {
245
268
  filled: {
246
269
  primary: "fill-primary",
247
270
  secondary: "fill-secondary dark:fill-[color-mix(in_oklab,var(--color-secondary)_70%,var(--color-background))]",
@@ -288,87 +311,96 @@ var w = C("btn"), T = C("shaped"), E = {
288
311
  default: "fill-transparent group-hover/icon-button:fill-accent dark:group-hover/icon-button:fill-accent/50"
289
312
  }
290
313
  };
291
- function D({ shape: t, variant: r, color: i }) {
292
- let a = p(t), o = _(null);
293
- return n(o, a, !0), /* @__PURE__ */ v("svg", {
314
+ function M({ shape: t, variant: r, color: i }) {
315
+ let a = g(t), o = b(null);
316
+ return n(o, a, !0), /* @__PURE__ */ x("svg", {
294
317
  "data-slot": "icon-button-shape",
295
318
  viewBox: "0 0 100 100",
296
319
  "aria-hidden": "true",
297
320
  focusable: "false",
298
321
  className: e("-z-10 pointer-events-none absolute inset-0 size-full overflow-visible transition-[filter]", r === "filled" && "group-hover/icon-button:brightness-90 group-active/icon-button:brightness-80"),
299
- children: /* @__PURE__ */ v("path", {
322
+ children: /* @__PURE__ */ x("path", {
300
323
  ref: o,
301
- d: m(a),
324
+ d: _(a),
302
325
  vectorEffect: "non-scaling-stroke",
303
326
  paintOrder: "stroke",
304
- className: e("stroke-transparent stroke-1 transition-[fill]", E[r][i], "group-focus-visible/icon-button:stroke-ring/50 group-focus-visible/icon-button:stroke-[6px]", "forced-colors:fill-none forced-colors:stroke-[ButtonText] forced-colors:group-focus-visible/icon-button:stroke-[Highlight]")
327
+ className: e("stroke-transparent stroke-1 transition-[fill]", j[r][i], "group-focus-visible/icon-button:stroke-ring/50 group-focus-visible/icon-button:stroke-[6px]", "forced-colors:fill-none forced-colors:stroke-[ButtonText] forced-colors:group-focus-visible/icon-button:stroke-[Highlight]")
305
328
  })
306
329
  });
307
330
  }
331
+ function N(e, n) {
332
+ let r = !!e && n != null && n !== "default";
333
+ y(() => {
334
+ r && !t() && console.warn("IconButton: `width` is ignored with `shape`; a shaped button is as wide as it is high.");
335
+ }, [r]);
336
+ }
308
337
  //#endregion
309
338
  //#region lib/components/ui/actions/icon-button/icon-button.tsx
310
- function O(e) {
311
- return e === void 0 || !Number.isFinite(e) || e < .5 ? null : b(e);
339
+ function P(e) {
340
+ return e === void 0 || !Number.isFinite(e) || e < .5 ? null : C(e);
312
341
  }
313
- function k({ variant: n, color: a, size: o, width: c, className: l, asChild: u, type: d = "button", shape: p, morph: m = "pill", badge: _, badgeTone: b = "primary", children: x, ...S }) {
314
- let C = u ? i : "button", E = h(f), k = o ?? E, A = !!(S["aria-label"] || S["aria-labelledby"]), j = !!p && c != null && c !== "default";
315
- g(() => {
316
- j && !t() && console.warn("IconButton: `width` is ignored with `shape`; a shaped button is as wide as it is high.");
317
- }, [j]);
318
- let M = !p && m !== "none" && S["aria-pressed"] !== void 0, N = O(_), P = S["aria-pressed"] === !0 || S["aria-pressed"] === "true";
319
- return /* @__PURE__ */ v(s, {
320
- value: A,
321
- children: /* @__PURE__ */ y(C, {
342
+ function F({ variant: t, color: n, size: a, width: o, className: s, asChild: c, type: l = "button", shape: u, morph: d = "pill", badge: f, badgeTone: m = "primary", loading: g = !1, children: _, ...y }) {
343
+ let b = c ? i : "button", C = v(h), w = a ?? C, T = !!(y["aria-label"] || y["aria-labelledby"]);
344
+ N(u, o);
345
+ let E = !u && d !== "none" && y["aria-pressed"] != null, j = P(f), F = String(y["aria-pressed"]) === "true", I = k(g, y);
346
+ return /* @__PURE__ */ x(p, {
347
+ value: T,
348
+ children: /* @__PURE__ */ S(b, {
322
349
  "data-slot": "icon-button",
323
350
  "data-icon-button": "",
324
- "data-variant": n ?? "filled",
325
- "data-color": a,
326
- type: u ? void 0 : d,
327
- "data-size": k,
328
- "data-shape": p,
329
- "data-morph": M ? m : void 0,
330
- "data-selected": M && P ? "true" : void 0,
331
- className: e(p ? T({
332
- variant: n,
333
- color: a,
334
- size: k
335
- }) : w({
336
- variant: n,
337
- color: a,
338
- size: k,
339
- width: c
340
- }), p && "group/icon-button nxgt-touch-target relative isolate bg-transparent! border-0! shadow-none! ring-0! focus-visible:ring-0! aria-invalid:ring-0! forced-colors:[&_svg]:stroke-[ButtonText] forced-colors:[&_svg]:text-[ButtonText]", l),
341
- ...S,
351
+ "data-variant": t ?? "filled",
352
+ "data-color": n,
353
+ type: c ? void 0 : l,
354
+ "data-size": w,
355
+ "data-shape": u,
356
+ "data-morph": E ? d : void 0,
357
+ "data-selected": E && F ? "true" : void 0,
358
+ className: e(u ? O({
359
+ variant: t,
360
+ color: n,
361
+ size: w
362
+ }) : D({
363
+ variant: t,
364
+ color: n,
365
+ size: w,
366
+ width: o
367
+ }), u && "group/icon-button nxgt-touch-target relative isolate bg-transparent! border-0! shadow-none! ring-0! focus-visible:ring-0! aria-invalid:ring-0! forced-colors:[&_svg]:stroke-[ButtonText] forced-colors:[&_svg]:text-[ButtonText]", I.busyClassName, s),
368
+ ...y,
369
+ ...I.hostProps,
342
370
  children: [
343
- p ? /* @__PURE__ */ v(D, {
344
- shape: p,
345
- variant: n ?? "filled",
346
- color: a ?? (n === "ghost" ? "default" : "primary")
371
+ u ? /* @__PURE__ */ x(M, {
372
+ shape: u,
373
+ variant: t ?? "filled",
374
+ color: n ?? (t === "ghost" ? "default" : "primary")
347
375
  }) : null,
348
- /* @__PURE__ */ v(r, { children: x }),
349
- N === null ? null : /* @__PURE__ */ v("span", {
376
+ /* @__PURE__ */ x(r, { children: _ }),
377
+ g && /* @__PURE__ */ x(A, {
378
+ variant: t ?? "filled",
379
+ color: n
380
+ }),
381
+ j === null ? null : /* @__PURE__ */ x("span", {
350
382
  "data-slot": "icon-button-badge",
351
383
  "aria-hidden": "true",
352
- "data-tone": b,
384
+ "data-tone": m,
353
385
  className: "nxgt-icon-button-badge",
354
- children: N
386
+ children: j
355
387
  })
356
388
  ]
357
389
  })
358
390
  });
359
391
  }
360
- function A({ tooltip: e, "aria-label": t, ...n }) {
392
+ function I({ tooltip: e, "aria-label": t, ...n }) {
361
393
  let r = t ?? (typeof e == "string" ? e : void 0);
362
- return e ? /* @__PURE__ */ v(a, {
394
+ return e ? /* @__PURE__ */ x(o, {
363
395
  content: e,
364
- children: /* @__PURE__ */ v(k, {
396
+ children: /* @__PURE__ */ x(F, {
365
397
  "aria-label": r,
366
398
  ...n
367
399
  })
368
- }) : /* @__PURE__ */ v(k, {
400
+ }) : /* @__PURE__ */ x(F, {
369
401
  "aria-label": r,
370
402
  ...n
371
403
  });
372
404
  }
373
405
  //#endregion
374
- export { w as n, b as r, A as t };
406
+ export { D as n, C as r, I as t };
@@ -0,0 +1,22 @@
1
+ import { ComponentProps } from 'react';
2
+ type Props = ComponentProps<'button'>;
3
+ /**
4
+ * What `loading` adds to an `IconButton`'s host, as `Button`'s: `aria-busy`
5
+ * and `aria-disabled` (which win over the caller's while busy, and stand when
6
+ * idle), every click blocked, and the classes that hide the icon and anchor the
7
+ * spinner. Spread it after the caller's props.
8
+ */
9
+ export declare function useBusyProps(loading: boolean, props: Props): {
10
+ busyClassName: string | undefined;
11
+ hostProps: {
12
+ 'aria-disabled': (boolean | "false" | "true") | undefined;
13
+ 'aria-busy': (boolean | "false" | "true") | undefined;
14
+ onClickCapture: (event: import('react').MouseEvent<HTMLButtonElement>) => void;
15
+ };
16
+ };
17
+ /** The busy spinner, over the icon's place; the icon keeps its room, hidden. */
18
+ export declare function IconButtonSpinner({ variant, color, }: {
19
+ variant: string;
20
+ color: string | null | undefined;
21
+ }): import("react").JSX.Element;
22
+ export {};
@@ -22,3 +22,5 @@ export declare function IconButtonShape({ shape, variant, color, }: {
22
22
  variant: IconButtonVariant;
23
23
  color: IconButtonColor;
24
24
  }): import("react").JSX.Element;
25
+ /** A `width` other than the default is ignored with a `shape`: a warning in development. */
26
+ export declare function useIgnoredWidthWarning(shape: ShapeName | undefined, width: string | null | undefined): void;
@@ -51,6 +51,13 @@ export type IconButtonProps = {
51
51
  * alert), `error` (a notification) or `neutral` (the page's text colour).
52
52
  */
53
53
  badgeTone?: 'primary' | 'error' | 'neutral';
54
+ /**
55
+ * Busy, as `Button`'s `loading`: `aria-busy` and `aria-disabled`, a
56
+ * spinner in place of the icon (the button keeps its size) and every
57
+ * click blocked. It stays focusable (no native `disabled`), so the
58
+ * focus is not lost while the work runs.
59
+ */
60
+ loading?: boolean;
54
61
  };
55
62
  export declare function IconButton({ tooltip, 'aria-label': ariaLabel, ...props }: IconButtonProps): import("react").JSX.Element;
56
63
  export { variants as iconButtonVariants };
@@ -1,8 +1,9 @@
1
1
  import { FilterModelField } from '@nxgt/material-core/filter';
2
2
  /**
3
3
  * A switch or checkbox as a quick filter: a toggle button (`aria-pressed`),
4
- * dashed while off, selected (the Chip's own check) once on ("Yes");
5
- * pressed again, its condition goes.
4
+ * the Chip's toggle look: its label alone while off (no plus, not dashed, so
5
+ * it never reads as the "+ Field" pill that opens an editor), selected with
6
+ * the Chip's own check mark once on ("Yes"); pressed again, its condition goes.
6
7
  * A "No" condition leaves it off, shown as a chip; pressing it then sets
7
8
  * "Yes". The focus stays on it.
8
9
  * A field on by default shows pressed with no condition, marked "Default"
@@ -18,7 +18,13 @@ export declare const FILTER_SHEET_COUNT_CLASS = "rounded-full bg-primary/10 px-1
18
18
  /** The sheet: its header (the title, then Close), the scrolling sections, the footer. */
19
19
  export declare const FILTER_SHEET_CLASS = "motion-reduce:transition-none";
20
20
  export declare const FILTER_SHEET_HEADER_CLASS = "flex-row items-center justify-between gap-2 border-b py-2 pr-2 text-left";
21
- export declare const FILTER_SHEET_CLOSE_CLASS = "static size-11";
21
+ /**
22
+ * In the header's flow, not at the corner. `relative`, never `static`: the
23
+ * button's invisible 44px hit area (`::after`, absolute) is placed against
24
+ * the nearest positioned ancestor, which for a static button is the whole
25
+ * sheet, so it covered the sections and swallowed a tap on their headers (#1733).
26
+ */
27
+ export declare const FILTER_SHEET_CLOSE_CLASS = "relative top-auto right-auto size-11";
22
28
  export declare const FILTER_SHEET_LOCKED_CLASS = "flex flex-wrap items-center gap-2 border-b px-4 py-3";
23
29
  /**
24
30
  * The sections, each a FacetGroup. Every row is a 44px target (WCAG 2.5.5):
@@ -27,6 +27,11 @@ export type PageFooterProps = {
27
27
  live?: boolean;
28
28
  /** Makes Previous and Next inert (a feed that is loading). */
29
29
  disabled?: boolean;
30
+ /** Renders nothing when there is a single page: no previous page and no
31
+ * next page. Default `false` (the footer shows its range, "1–5 of 5").
32
+ * The range is then not on screen: say the count elsewhere (a status
33
+ * line, a heading) or keep the footer. */
34
+ hideOnSinglePage?: boolean;
30
35
  /** Your router's link; it must forward `className` and `ref`. */
31
36
  linkComponent?: DataTableLinkComponent;
32
37
  } & Omit<ComponentProps<'div'>, 'children'>;
@@ -37,4 +42,4 @@ export type PageFooterProps = {
37
42
  * `ServerTable` draws. Renders nothing for an empty result. Without a
38
43
  * `totalCount` (a cursor feed with no total) it is the Previous / Next alone.
39
44
  */
40
- export declare function PageFooter({ pageInfo, totalCount, params, pageSize, count, pageHref, pagingNames, pageControls, live, disabled, linkComponent, className, ...props }: PageFooterProps): import("react").JSX.Element | null;
45
+ export declare function PageFooter({ pageInfo, totalCount, params, pageSize, count, pageHref, pagingNames, pageControls, live, disabled, hideOnSinglePage, linkComponent, className, ...props }: PageFooterProps): import("react").JSX.Element | null;
@@ -11,6 +11,9 @@ export type RowMenuTriggerProps = Omit<IconButtonProps, 'children' | 'tooltip' |
11
11
  * The "..." button of a row: a ghost `IconButton` with an ellipsis, named
12
12
  * after its row. It is 44px on a coarse pointer (and below `md`), 36px with a
13
13
  * fine pointer from `md` up. It forwards its props and its `ref`, so it works
14
- * as the child of a `DropdownMenuTrigger asChild`.
14
+ * as the child of a `DropdownMenuTrigger asChild`. `loading` (as `Button`'s)
15
+ * marks it busy while an action chosen from its menu runs: `aria-busy`, a
16
+ * spinner in place of the dots, the same size, the focus kept, and the menu
17
+ * does not reopen until it is over.
15
18
  */
16
- export declare function RowMenuTrigger({ label, className, 'aria-label': ariaLabel, ...props }: RowMenuTriggerProps): import("react").JSX.Element;
19
+ export declare function RowMenuTrigger({ label, loading, onPointerDown, onKeyDown, className, 'aria-label': ariaLabel, ...props }: RowMenuTriggerProps): import("react").JSX.Element;
@@ -1,3 +1,3 @@
1
- export { defineFilterModel, type FilterCodecOptions, type FilterCondition, type FilterLockedCondition, type FilterModel, type FilterQuery, parseFilterQuery, serializeFilterQuery, } from '@nxgt/material-core/filter';
1
+ export { defineFilterModel, effectiveConditions, type FilterCodecOptions, type FilterCondition, type FilterFieldError, type FilterFieldErrors, type FilterLockedCondition, type FilterModel, type FilterQuery, type FilterSplitErrors, parseFilterQuery, serializeFilterQuery, splitFilterErrors, } from '@nxgt/material-core/filter';
2
2
  export { type CursorConnection, createSorting, FIRST_PAGE, firstPage, isFiltered, isNewQuery, nextPage, type PageCursor, type PagingNames, pagingNames, paramsFromQuery, previousPage, queryFromParams, queryKey, type RouterQuery, readCursor, type ServerPagination, type ServerPaginationOptions, type SortingOptions, serverPagination, type TableFilterBinding, type TableFilterOptions, type TableSort, type TableSorting, tableFilters, withoutFilters, } from '@nxgt/material-core/table-url';
3
3
  export * from './server-table.js';
@@ -1,8 +1,10 @@
1
1
  /**
2
2
  * "Nothing matches": the user's filters that narrow the list, as chips
3
3
  * removed by their ✕ (a kept field, a widening switch such as "Show archived" or a scope such as the period, is not
4
- * one, a locked condition stays in the band), then "Clear all" while two
5
- * or a search remain. A removal focuses the next chip, then "Clear all",
4
+ * one, a locked condition stays in the band), then "Clear all" (worded by
5
+ * `empty.clear`) whenever a chip or a search remains. A removal focuses the next chip, then "Clear all",
6
6
  * then the search (the core's `focusAfterRemove`, from `empty`).
7
7
  */
8
- export declare function ServerTableEmptyChips(): import("react").JSX.Element | null;
8
+ export declare function ServerTableEmptyChips({ clear }: {
9
+ clear?: string;
10
+ }): import("react").JSX.Element | null;
@@ -0,0 +1,17 @@
1
+ import { PagingNames } from '@nxgt/material-core/table-url';
2
+ /** The footer and paging props of `ServerTable`, apart from the page's data. */
3
+ export type ServerTablePagingProps = {
4
+ /** How the footer's Previous and Next are drawn: `'labelled'` (default) or
5
+ * `'icon'`, icon-only buttons with a tooltip and a name that says the page
6
+ * ("Previous page"); a page given as an href stays a link. */
7
+ pageControls?: 'labelled' | 'icon';
8
+ /** Hides the footer's range and Previous / Next when the result is a single
9
+ * page (no previous page, no next page). Default `false`. The count is
10
+ * still announced by the live region, but no longer shown: show it in the
11
+ * `description` or keep the footer. A selection's "N rows selected" stays. */
12
+ hideOnSinglePage?: boolean;
13
+ /** A page's href. Default ``(params) => `?${params}` ``. */
14
+ pageHref?: (params: URLSearchParams) => string;
15
+ /** The cursor's search param names. Default `after` and `trail`. */
16
+ pagingNames?: Partial<PagingNames>;
17
+ };
@@ -1,7 +1,7 @@
1
1
  import { FilterDefaults, FilterFieldErrors, FilterLockedCondition, FilterModel } from '@nxgt/material-core/filter';
2
2
  import { IconStyleInput } from '@nxgt/material-core/icons';
3
3
  import { ErrorStateKind } from '@nxgt/material-core/states';
4
- import { PagingNames, TableFilterBinding, TableSorting } from '@nxgt/material-core/table-url';
4
+ import { TableFilterBinding, TableSorting } from '@nxgt/material-core/table-url';
5
5
  import { RowData } from '@tanstack/react-table';
6
6
  import { ReactNode, Ref } from 'react';
7
7
  import { StateHeadingLevel } from '../../feedback/state-frame/state-frame.js';
@@ -9,6 +9,7 @@ import { DataTableProps } from '../data-table/types.js';
9
9
  import { FilterBarFieldProps, FilterQueryProps } from '../filter/internal.js';
10
10
  import { ListEmptyContent } from '../list-empty/list-empty.js';
11
11
  import { ServerTableBulkAction } from './bulk-action.js';
12
+ import { ServerTablePagingProps } from './types-paging.js';
12
13
  /** What a bulk action can do to the selection once it acted. */
13
14
  export type ServerTableSelection = {
14
15
  /** Empties the selection; the table takes the focus the toolbar had. */
@@ -123,7 +124,7 @@ export type ServerTableFilterHandle = {
123
124
  };
124
125
  /** The `DataTable` props `ServerTable` passes through as they are. */
125
126
  export type PassedThrough<T extends RowData> = Pick<DataTableProps<T>, 'columns' | 'maxHeight' | 'scrollLabel' | 'showViewOptions' | 'renderExpandedRow' | 'options' | 'loading' | 'loadingRows' | 'getRowHref' | 'onRowClick' | 'linkComponent' | 'density' | 'layout' | 'cardDensity' | 'renderCard' | 'renderTile' | 'enableRowSelection' | 'rowSelectionDisabledReason'>;
126
- export type ServerTableProps<T extends RowData> = PassedThrough<T> & {
127
+ export type ServerTableProps<T extends RowData> = PassedThrough<T> & ServerTablePagingProps & {
127
128
  /** The URL's search params, as the router reads them. */
128
129
  params: URLSearchParams;
129
130
  /** The router's setter, called with new search params: React Router's
@@ -172,10 +173,6 @@ export type ServerTableProps<T extends RowData> = PassedThrough<T> & {
172
173
  * half the room above and under it (a list under a sticky app bar). The
173
174
  * controls keep their size (the Filter's `density` is theirs). */
174
175
  bandDensity?: 'comfortable' | 'compact';
175
- /** How the footer's Previous and Next are drawn: `'labelled'` (default) or
176
- * `'icon'`, icon-only buttons with a tooltip and a name that says the page
177
- * ("Previous page"); a page given as an href stays a link. */
178
- pageControls?: 'labelled' | 'icon';
179
176
  /** With `filter`: a handle to focus the Filter's first control, for the
180
177
  * app to move the focus there (after its own action). */
181
178
  filterRef?: Ref<ServerTableFilterHandle>;
@@ -191,10 +188,6 @@ export type ServerTableProps<T extends RowData> = PassedThrough<T> & {
191
188
  * across pages, and a new query empties the selection. Which rows can be
192
189
  * is `enableRowSelection`; why one cannot, `rowSelectionDisabledReason`. */
193
190
  bulkActions?: ((ids: string[], selection: ServerTableSelection) => ReactNode) | readonly ServerTableBulkAction<T>[];
194
- /** A page's href. Default ``(params) => `?${params}` ``. */
195
- pageHref?: (params: URLSearchParams) => string;
196
- /** The cursor's search param names. Default `after` and `trail`. */
197
- pagingNames?: Partial<PagingNames>;
198
191
  /** Without `filter`: what the live region says once a new query is
199
192
  * answered. Default "N results" (`material.server-table.results`). */
200
193
  resultsLabel?: (count: number) => string;