@nxgt/material 3.48.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 (120) hide show
  1. package/CHANGELOG.md +32 -0
  2. package/README.md +3 -3
  3. package/dist/{async-slice-DlvKCKAa.js → async-slice-3loEtzUY.js} +2 -2
  4. package/dist/{button-yaltbQmC.js → button-BRUaHD8z.js} +81 -112
  5. package/dist/charts.js +144 -144
  6. package/dist/{chip-BqWbbr1b.js → chip-DneTrtNj.js} +56 -56
  7. package/dist/{code-editor-C9qBNoYb.js → code-editor-R_nPN_-d.js} +308 -308
  8. package/dist/code-editor.js +47 -47
  9. package/dist/{code-language-items-DAHtfQ7W.js → code-language-items-BKEUhQlF.js} +2 -2
  10. package/dist/components/components.css +1 -0
  11. package/dist/components/ui/actions/action-card/action-card-indicator.css +48 -0
  12. package/dist/components/ui/actions/action-card/action-card-modes.css +4 -1
  13. package/dist/components/ui/actions/action-card/action-card-tile.css +141 -0
  14. package/dist/components/ui/actions/action-card/action-card.css +33 -3
  15. package/dist/{components-Ox6FHmpx.js → components-D6xFLcoE.js} +17646 -17567
  16. package/dist/components.js +26 -27
  17. package/dist/{dialog-CCCcnTIx.js → dialog-S7dLsYRZ.js} +16 -16
  18. package/dist/dnd.js +1 -1
  19. package/dist/{dropdown-menu-Df8785nt.js → dropdown-menu-XLlxfDgq.js} +271 -272
  20. package/dist/editor.js +1028 -1028
  21. package/dist/{empty-state-DcF4TBzi.js → empty-state-Dsf6R-Zo.js} +37 -37
  22. package/dist/{escape-owner-C4W_sOAU.js → escape-owner-B9eCwjLw.js} +1 -1
  23. package/dist/{field-blur-CJHzVSh9.js → field-blur-5uRDFHvB.js} +1 -1
  24. package/dist/{field-blur-context-Cft9s7Hg.js → field-blur-context-Cwt4TuBq.js} +1 -1
  25. package/dist/hooks.js +4 -4
  26. package/dist/{hover-card-C0fw2kLK.js → hover-card-PHUgRSjJ.js} +24 -24
  27. package/dist/{i18n-provider-C0fB0sEL.js → i18n-provider-DPM_ALQ4.js} +1 -1
  28. package/dist/i18n.js +5 -5
  29. package/dist/{icon-badge-aJ22mKGh.js → icon-badge-Dh6-FNOF.js} +3 -3
  30. package/dist/{icon-button-CN9r5TNE.js → icon-button-DSC2-IAG.js} +118 -86
  31. package/dist/lib/components/ui/actions/action-card/action-card-semantics.d.ts +25 -2
  32. package/dist/lib/components/ui/actions/action-card/action-card.d.ts +18 -2
  33. package/dist/lib/components/ui/actions/action-card/partials/action-card-icon.d.ts +6 -0
  34. package/dist/lib/components/ui/actions/action-card/partials/action-card-meta.d.ts +15 -0
  35. package/dist/lib/components/ui/actions/action-card/partials/action-card-status.d.ts +6 -0
  36. package/dist/lib/components/ui/actions/action-card/partials/action-card-text.d.ts +20 -0
  37. package/dist/lib/components/ui/actions/action-card/partials/action-card-title-button.d.ts +14 -0
  38. package/dist/lib/components/ui/actions/action-card/partials/action-card-trail.d.ts +6 -0
  39. package/dist/lib/components/ui/actions/action-card/use-action-card-names.d.ts +22 -0
  40. package/dist/lib/components/ui/actions/action-card/use-reveal.d.ts +23 -0
  41. package/dist/lib/components/ui/actions/button/button.variants.d.ts +1 -1
  42. package/dist/lib/components/ui/actions/icon-button/icon-button-busy.d.ts +22 -0
  43. package/dist/lib/components/ui/actions/icon-button/icon-button-shape.d.ts +2 -0
  44. package/dist/lib/components/ui/actions/icon-button/icon-button.d.ts +7 -0
  45. package/dist/lib/components/ui/actions/icon-button/icon-button.variants.d.ts +1 -1
  46. package/dist/lib/components/ui/collections/filter/bar/partials/filter-quick-toggle.d.ts +3 -2
  47. package/dist/lib/components/ui/collections/filter/sections/filter-sections-classes.d.ts +7 -1
  48. package/dist/lib/components/ui/collections/page-footer/page-footer.d.ts +6 -1
  49. package/dist/lib/components/ui/collections/row-menu/row-menu-trigger.d.ts +5 -2
  50. package/dist/lib/components/ui/collections/row-menu/row-menu.d.ts +1 -1
  51. package/dist/lib/components/ui/collections/server-table/index.d.ts +1 -1
  52. package/dist/lib/components/ui/collections/server-table/partials/server-table-empty-chips.d.ts +5 -3
  53. package/dist/lib/components/ui/collections/server-table/types-paging.d.ts +17 -0
  54. package/dist/lib/components/ui/collections/server-table/types.d.ts +3 -10
  55. package/dist/lib/components/ui/dates/duration-field/partials/use-duration-box.d.ts +1 -1
  56. package/dist/lib/components/ui/display/badge/badge.d.ts +1 -1
  57. package/dist/lib/components/ui/display/day-separator/day-separator.d.ts +1 -1
  58. package/dist/lib/components/ui/feedback/step-up-dialog/partials/step-up-body.d.ts +5 -3
  59. package/dist/lib/components/ui/feedback/step-up-dialog/partials/step-up-request-error.d.ts +15 -0
  60. package/dist/lib/components/ui/feedback/step-up-dialog/step-up-dialog.d.ts +6 -3
  61. package/dist/lib/components/ui/feedback/step-up-dialog/types.d.ts +12 -1
  62. package/dist/lib/components/ui/feedback/step-up-dialog/use-retry-focus.d.ts +27 -0
  63. package/dist/lib/components/ui/feedback/step-up-dialog/use-retry.d.ts +11 -0
  64. package/dist/lib/components/ui/fields/contacts/placeholders.d.ts +1 -1
  65. package/dist/lib/components/ui/fields/slider/split-slider-props.d.ts +20 -20
  66. package/dist/lib/components/ui/fields/slider/use-slider-control.d.ts +20 -20
  67. package/dist/lib/components/ui/fields/verification-code/use-settled-focus.d.ts +10 -0
  68. package/dist/lib/components/ui/layout/app-shell/route-transition.d.ts +1 -1
  69. package/dist/lib/components/ui/media/carousel/use-carousel-engine.d.ts +1 -1
  70. package/dist/lib/components/ui/media/media-player/engine/use-queue-actions.d.ts +1 -1
  71. package/dist/lib/components/ui/media/pdf-reader/pdf-reader.slice.d.ts +1 -1
  72. package/dist/lib/components/ui/selection/choice-group/use-choice-group-field.d.ts +34 -34
  73. package/dist/lib/components/ui/widgets/chat/chat-message.variants.d.ts +2 -2
  74. package/dist/lib/components/ui/widgets/event-calendar/use-event-calendar.d.ts +1 -1
  75. package/dist/lib/i18n/resources/en/en.d.ts +1 -0
  76. package/dist/lib/i18n/resources/en/material.json.d.ts +2 -1
  77. package/dist/lib/i18n/resources/fr/fr.d.ts +1 -0
  78. package/dist/lib/i18n/resources/fr/material.json.d.ts +2 -1
  79. package/dist/lib/i18n/resources/resources.d.ts +2 -0
  80. package/dist/lib/i18n/translator.d.ts +1 -1
  81. package/dist/lib.js +1 -1
  82. package/dist/main.js +43 -44
  83. package/dist/map.js +79 -79
  84. package/dist/material.css +1 -1
  85. package/dist/nxgt-theme-ivgNca3z.js +37 -0
  86. package/dist/pdf-reader.js +1 -1
  87. package/dist/print.js +2 -2
  88. package/dist/{public-zVb_Nq_D.js → public-vxiijIJF.js} +82 -82
  89. package/dist/{rich-code-block-DMWZZJma.js → rich-code-block-BwvCXPqq.js} +52 -52
  90. package/dist/{sortable-provider-DstbgMVf.js → sortable-provider-D2pAFWQB.js} +218 -218
  91. package/dist/{tooltip-CkttDIab.js → spinner-BpVwI1ps.js} +503 -278
  92. package/dist/{stored-language-IaL1Ftn_.js → stored-language-Beyj2ult.js} +4 -2
  93. package/dist/theme-picker.js +45 -45
  94. package/dist/{theme-store-CSl51uNH.js → theme-store-BdPp43cV.js} +13 -13
  95. package/dist/{theme-toggle-CGW2_K54.js → theme-toggle-BTYRPkP4.js} +16 -16
  96. package/dist/themes.js +17 -17
  97. package/dist/{toggle-group-BMJNcFAC.js → toggle-group-BkH23Jk4.js} +11 -11
  98. package/dist/{toolbar-items-CsLGJMEJ.js → toolbar-items-CIMo4F9q.js} +421 -421
  99. package/dist/{translate-material-v9u-e7Kd.js → translate-material-DEUlaL_1.js} +2 -2
  100. package/dist/{translator-Dk4_qE6U.js → translator-CBgIb3zP.js} +1 -1
  101. package/dist/{use-chat-composer-Brcb5f7r.js → use-chat-composer-D8UAsX0f.js} +6228 -5999
  102. package/dist/{button-tones-BwuVvAmd.js → use-click-lock-BZYtTmVt.js} +37 -7
  103. package/dist/{use-heading-spy-DjKixjLm.js → use-heading-spy-C5LXtA8Z.js} +1 -1
  104. package/dist/{use-material-translation-DOkTaWK_.js → use-material-translation-DWWeeg-B.js} +2 -2
  105. package/dist/{use-theme-DMcyJ52N.js → use-theme-BCLireTd.js} +1 -1
  106. package/docs/components/buttons-and-actions.md +64 -5
  107. package/docs/components/data-table-filter-and-lists.md +30 -10
  108. package/docs/components/feedback-and-status.md +22 -3
  109. package/docs/components/form-fields.md +7 -0
  110. package/docs/guides/cards-and-tiles.md +60 -0
  111. package/docs/guides/server-lists-url.md +3 -2
  112. package/docs/roadmap.md +11 -0
  113. package/lib/components/components.css +1 -0
  114. package/lib/components/ui/actions/action-card/action-card-indicator.css +48 -0
  115. package/lib/components/ui/actions/action-card/action-card-modes.css +4 -1
  116. package/lib/components/ui/actions/action-card/action-card-tile.css +141 -0
  117. package/lib/components/ui/actions/action-card/action-card.css +33 -3
  118. package/package.json +1 -1
  119. package/dist/nxgt-theme-ZS945iMP.js +0 -37
  120. package/dist/spinner-C4CgDEYm.js +0 -229
@@ -0,0 +1,141 @@
1
+ /* biome-ignore-all lint/style/noDescendingSpecificity: states are grouped by meaning, not by specificity */
2
+ /* ActionCard status, meta, action and the tile variant. Loaded after
3
+ * action-card.css and the indicator. With an `action` the title is the card's
4
+ * one button: its ::after covers the card, and the action sits above it. */
5
+ @layer components {
6
+ .nxgt-action-card-status {
7
+ display: flex;
8
+ margin-top: 4px;
9
+ min-width: 0;
10
+ }
11
+ .nxgt-action-card-meta {
12
+ display: block;
13
+ margin-top: 2px;
14
+ min-width: 0;
15
+ overflow: hidden;
16
+ white-space: nowrap;
17
+ text-overflow: ellipsis;
18
+ font-size: 0.8125rem;
19
+ line-height: 1.4;
20
+ color: color-mix(in oklab, var(--card-foreground) 70%, var(--card));
21
+ }
22
+
23
+ /* The title button: the card's press surface. */
24
+ .nxgt-action-card-button {
25
+ display: inline;
26
+ margin: 0;
27
+ padding: 0;
28
+ border: 0;
29
+ background: none;
30
+ color: inherit;
31
+ font: inherit;
32
+ letter-spacing: inherit;
33
+ text-align: start;
34
+ cursor: pointer;
35
+ outline: none;
36
+ }
37
+ .nxgt-action-card-button::after {
38
+ content: "";
39
+ position: absolute;
40
+ inset: 0;
41
+ border-radius: inherit;
42
+ z-index: 0;
43
+ }
44
+ .nxgt-action-card-button:disabled {
45
+ cursor: not-allowed;
46
+ }
47
+ .nxgt-action-card:has(.nxgt-action-card-button:focus-visible) {
48
+ outline: 3px solid var(--ac-ring);
49
+ outline-offset: -3px;
50
+ }
51
+
52
+ /* The action: its own grid area, above the stretched button. */
53
+ .nxgt-action-card-action {
54
+ grid-area: act;
55
+ position: relative;
56
+ z-index: 1;
57
+ justify-self: end;
58
+ display: inline-flex;
59
+ margin-inline-end: -8px;
60
+ }
61
+ .nxgt-action-card[data-has-action] {
62
+ grid-template-columns: auto minmax(0, 1fr) auto auto;
63
+ grid-template-areas: "icon text act ind";
64
+ }
65
+ .nxgt-action-card[data-has-action][data-size="md"] {
66
+ grid-template-columns: auto minmax(0, 1fr) auto;
67
+ grid-template-areas: "icon act ind" "text text text";
68
+ }
69
+ .nxgt-action-card[data-has-action][data-size="md"]:not([data-icon]) {
70
+ grid-template-columns: minmax(0, 1fr) auto auto;
71
+ grid-template-areas: "text act ind";
72
+ }
73
+
74
+ /* Tile: a compact grid cell, title and action on the first row, then the
75
+ * status, the description and the meta line, each full width. The text
76
+ * wrapper dissolves so its children take the areas. */
77
+ .nxgt-action-card[data-size="tile"] {
78
+ grid-template-columns: minmax(0, 1fr) auto;
79
+ grid-template-areas: "title act" "status status" "desc desc" "meta meta";
80
+ align-items: start;
81
+ /* A taller neighbour stretches the card: keep the rows at the top. */
82
+ align-content: start;
83
+ row-gap: 0;
84
+ column-gap: 8px;
85
+ min-height: 0;
86
+ min-width: 0;
87
+ padding-block: 12px;
88
+ padding-inline: 16px 12px;
89
+ }
90
+ .nxgt-action-card[data-size="tile"][data-icon] {
91
+ grid-template-columns: auto minmax(0, 1fr) auto;
92
+ grid-template-areas:
93
+ "icon title act"
94
+ ". status status"
95
+ ". desc desc"
96
+ ". meta meta";
97
+ }
98
+ .nxgt-action-card[data-size="tile"] .nxgt-action-card-icon {
99
+ width: 36px;
100
+ height: 36px;
101
+ }
102
+ .nxgt-action-card[data-size="tile"] .nxgt-action-card-text {
103
+ display: contents;
104
+ }
105
+ .nxgt-action-card[data-size="tile"] .nxgt-action-card-title {
106
+ grid-area: title;
107
+ align-self: center;
108
+ min-height: 36px;
109
+ display: flex;
110
+ align-items: center;
111
+ }
112
+ .nxgt-action-card[data-size="tile"] .nxgt-action-card-description {
113
+ grid-area: desc;
114
+ margin-top: 2px;
115
+ }
116
+ .nxgt-action-card[data-size="tile"] .nxgt-action-card-status {
117
+ grid-area: status;
118
+ }
119
+ .nxgt-action-card[data-size="tile"] .nxgt-action-card-meta {
120
+ grid-area: meta;
121
+ }
122
+ .nxgt-action-card[data-size="tile"][data-has-action]
123
+ .nxgt-action-card-action {
124
+ align-self: start;
125
+ }
126
+
127
+ @media (forced-colors: active) {
128
+ .nxgt-action-card:has(.nxgt-action-card-button:focus-visible) {
129
+ outline: 3px solid CanvasText;
130
+ outline-offset: -5px;
131
+ }
132
+ .nxgt-action-card-meta {
133
+ color: CanvasText;
134
+ }
135
+ /* a chosen tile's border is 2px here: the content keeps its place */
136
+ .nxgt-action-card[data-size="tile"][data-active] {
137
+ padding-block: 11px;
138
+ padding-inline: 15px 11px;
139
+ }
140
+ }
141
+ }
@@ -125,13 +125,43 @@
125
125
  .nxgt-action-card[data-interactive]:not([data-disabled]) {
126
126
  cursor: pointer;
127
127
  }
128
- .nxgt-action-card[data-interactive]:not([data-disabled]):hover {
128
+ .nxgt-action-card[data-interactive]:not(
129
+ [data-has-action],
130
+ [data-disabled]
131
+ ):hover {
129
132
  --ac-tint: 11%;
130
133
  }
131
- .nxgt-action-card[data-interactive][data-active]:not([data-disabled]):hover {
134
+ .nxgt-action-card[data-interactive][data-active]:not(
135
+ [data-has-action],
136
+ [data-disabled]
137
+ ):hover {
132
138
  --ac-tint: 21%;
133
139
  }
134
- .nxgt-action-card[data-interactive]:not([data-disabled]):active {
140
+ .nxgt-action-card[data-interactive]:not(
141
+ [data-has-action],
142
+ [data-disabled]
143
+ ):active {
144
+ --ac-tint: 15%;
145
+ --ac-r: 16px;
146
+ scale: 0.97;
147
+ }
148
+
149
+ /* With an action, only the title button answers hover and press (its
150
+ * stretched ::after covers the card, padding included); the action does
151
+ * not. The rules above leave these cards to the ones below. */
152
+ .nxgt-action-card[data-has-action][data-interactive]:not([data-disabled]):has(
153
+ .nxgt-action-card-button:hover
154
+ ) {
155
+ --ac-tint: 11%;
156
+ }
157
+ .nxgt-action-card[data-has-action][data-interactive][data-active]:not(
158
+ [data-disabled]
159
+ ):has(.nxgt-action-card-button:hover) {
160
+ --ac-tint: 21%;
161
+ }
162
+ .nxgt-action-card[data-has-action][data-interactive]:not([data-disabled]):has(
163
+ .nxgt-action-card-button:active
164
+ ) {
135
165
  --ac-tint: 15%;
136
166
  --ac-r: 16px;
137
167
  scale: 0.97;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nxgt/material",
3
- "version": "3.48.0",
3
+ "version": "3.50.0",
4
4
  "license": "MIT",
5
5
  "bugs": {
6
6
  "email": "stevegires@gmail.com"
@@ -1,37 +0,0 @@
1
- import { t as e } from "./dist-DVRQkaTK.js";
2
- import { t } from "./is-production-GLw59WU8.js";
3
- import { n, r, t as i } from "./theme-context-Cofk6vgs.js";
4
- import { t as a } from "./warn-once-C_e47JM8.js";
5
- import { useContext as o, useMemo as s } from "react";
6
- import { jsx as c } from "react/jsx-runtime";
7
- //#region lib/themes/theme-value.ts
8
- function l(e, t, n) {
9
- return {
10
- name: e,
11
- theme: t,
12
- background: t?.background === !1 ? !1 : t?.background ?? i,
13
- defaultMode: n
14
- };
15
- }
16
- //#endregion
17
- //#region lib/themes/nxgt-theme.tsx
18
- function u({ theme: i, mode: u, asChild: d = !1, children: f, ...p }) {
19
- let m = o(r), h = typeof i == "string" ? m?.find((e) => e.name === i) : i, g = typeof i == "string" ? i : i.name;
20
- !t() && m && !h && a(`theme "${g}" is not in the provider's themes; its background is the default.`, "NxgtTheme");
21
- let _ = o(n)?.defaultMode, v = s(() => l(g, h, _), [
22
- g,
23
- h,
24
- _
25
- ]), y = d ? e : "div";
26
- return /* @__PURE__ */ c(n.Provider, {
27
- value: v,
28
- children: /* @__PURE__ */ c(y, {
29
- ...p,
30
- "data-nxgt-theme": g,
31
- ...u ? { "data-theme": u } : {},
32
- children: f
33
- })
34
- });
35
- }
36
- //#endregion
37
- export { l as n, u as t };
@@ -1,229 +0,0 @@
1
- import { t as e } from "./utils-BLfntITJ.js";
2
- import { o as t } from "./tooltip-CkttDIab.js";
3
- import { t as n } from "./use-material-translation-DOkTaWK_.js";
4
- import { jsx as r } from "react/jsx-runtime";
5
- //#region lib/components/ui/feedback/spinner/spinner.tsx
6
- var i = t("transition-all duration-500", {
7
- variants: {
8
- variant: {
9
- 1: "",
10
- 2: "",
11
- 3: "",
12
- 4: ""
13
- },
14
- color: {
15
- primary: null,
16
- secondary: null,
17
- info: null,
18
- warning: null,
19
- default: null,
20
- error: null,
21
- success: null,
22
- light: null
23
- }
24
- },
25
- defaultVariants: {
26
- variant: "1",
27
- color: "primary"
28
- },
29
- compoundVariants: [
30
- {
31
- variant: "1",
32
- color: "primary",
33
- className: "border-primary/10 border-t-primary-indicator"
34
- },
35
- {
36
- variant: "1",
37
- color: "secondary",
38
- className: "border-secondary/10 border-t-secondary"
39
- },
40
- {
41
- variant: "1",
42
- color: "success",
43
- className: "border-success/10 border-t-success"
44
- },
45
- {
46
- variant: "1",
47
- color: "info",
48
- className: "border-info/10 border-t-info"
49
- },
50
- {
51
- variant: "1",
52
- color: "warning",
53
- className: "border-warning/10 border-t-warning"
54
- },
55
- {
56
- variant: "1",
57
- color: "error",
58
- className: "border-error/10 border-t-error"
59
- },
60
- {
61
- variant: "1",
62
- color: "default",
63
- className: "border-foreground/10 border-t-foreground"
64
- },
65
- {
66
- variant: "1",
67
- color: "light",
68
- className: "border-white/10 border-t-white"
69
- },
70
- {
71
- variant: "2",
72
- color: "primary",
73
- className: "border-primary/10 border-b-primary-indicator border-t-primary-indicator"
74
- },
75
- {
76
- variant: "2",
77
- color: "secondary",
78
- className: "border-secondary/10 border-b-secondary border-t-secondary"
79
- },
80
- {
81
- variant: "2",
82
- color: "success",
83
- className: "border-success/10 border-b-success border-t-success"
84
- },
85
- {
86
- variant: "2",
87
- color: "info",
88
- className: "border-info/10 border-b-info border-t-info"
89
- },
90
- {
91
- variant: "2",
92
- color: "warning",
93
- className: "border-warning/10 border-b-warning border-t-warning"
94
- },
95
- {
96
- variant: "2",
97
- color: "error",
98
- className: "border-error/10 border-b-error border-t-error"
99
- },
100
- {
101
- variant: "2",
102
- color: "default",
103
- className: "border-foreground/10 border-b-foreground border-t-foreground"
104
- },
105
- {
106
- variant: "2",
107
- color: "light",
108
- className: "border-white/10 border-b-white border-t-white"
109
- },
110
- {
111
- variant: "3",
112
- color: "primary",
113
- className: "border-primary/10 border-b-primary-indicator border-t-primary-indicator border-r-primary-indicator"
114
- },
115
- {
116
- variant: "3",
117
- color: "secondary",
118
- className: "border-secondary/10 border-b-secondary border-t-secondary border-r-secondary"
119
- },
120
- {
121
- variant: "3",
122
- color: "success",
123
- className: "border-success/10 border-b-success border-t-success border-r-success"
124
- },
125
- {
126
- variant: "3",
127
- color: "info",
128
- className: "border-info/10 border-b-info border-t-info border-r-info"
129
- },
130
- {
131
- variant: "3",
132
- color: "warning",
133
- className: "border-warning/10 border-b-warning border-t-warning border-r-warning"
134
- },
135
- {
136
- variant: "3",
137
- color: "error",
138
- className: "border-error/10 border-b-error border-t-error border-r-error"
139
- },
140
- {
141
- variant: "3",
142
- color: "default",
143
- className: "border-foreground/10 border-b-foreground border-t-foreground border-r-foreground"
144
- },
145
- {
146
- variant: "3",
147
- color: "light",
148
- className: "border-white/10 border-b-white border-t-white border-r-white"
149
- },
150
- {
151
- variant: "4",
152
- color: "primary",
153
- className: "stroke-primary-indicator"
154
- },
155
- {
156
- variant: "4",
157
- color: "secondary",
158
- className: "stroke-secondary"
159
- },
160
- {
161
- variant: "4",
162
- color: "success",
163
- className: "stroke-success"
164
- },
165
- {
166
- variant: "4",
167
- color: "info",
168
- className: "stroke-info"
169
- },
170
- {
171
- variant: "4",
172
- color: "warning",
173
- className: "stroke-warning"
174
- },
175
- {
176
- variant: "4",
177
- color: "error",
178
- className: "stroke-error"
179
- },
180
- {
181
- variant: "4",
182
- color: "default",
183
- className: "stroke-foreground"
184
- },
185
- {
186
- variant: "4",
187
- color: "light",
188
- className: "stroke-white"
189
- }
190
- ]
191
- });
192
- function a({ variant: t = "1", color: a, className: o, ...s }) {
193
- let { t: c } = n();
194
- return t === "4" ? /* @__PURE__ */ r("svg", {
195
- viewBox: "0 0 800 800",
196
- "data-slot": "spinner",
197
- "data-variant": t,
198
- "data-color": a,
199
- className: e("size-14", o),
200
- xmlns: "http://www.w3.org/2000/svg",
201
- role: "img",
202
- "aria-label": s["aria-label"] ?? c("material.spinner.loading", "Loading..."),
203
- children: /* @__PURE__ */ r("circle", {
204
- className: e("spin2", i({
205
- variant: t,
206
- color: a
207
- })),
208
- cx: "400",
209
- cy: "400",
210
- fill: "none",
211
- r: "200",
212
- strokeWidth: "50",
213
- strokeDasharray: "700 1400",
214
- strokeLinecap: "round"
215
- })
216
- }) : /* @__PURE__ */ r("div", {
217
- "data-slot": "spinner",
218
- "data-variant": t,
219
- "data-color": a,
220
- className: e("size-12 border-[2px] rounded-full animate-spin", i({
221
- variant: t,
222
- color: a,
223
- className: o
224
- })),
225
- ...s
226
- });
227
- }
228
- //#endregion
229
- export { a as t };