@nonsuch/component-library 0.5.0 → 0.6.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 (45) hide show
  1. package/dist/components/NsAvatar/NsAvatar.vue.d.ts +40 -0
  2. package/dist/components/NsAvatar/index.d.ts +1 -0
  3. package/dist/components/NsBanner/NsBanner.vue.d.ts +30 -0
  4. package/dist/components/NsBanner/index.d.ts +1 -0
  5. package/dist/components/NsButton/NsButton.vue.d.ts +42 -0
  6. package/dist/components/NsButton/index.d.ts +1 -0
  7. package/dist/components/NsCard/NsCard.vue.d.ts +35 -0
  8. package/dist/components/NsCard/index.d.ts +1 -0
  9. package/dist/components/NsCheckbox/NsCheckbox.vue.d.ts +30 -0
  10. package/dist/components/NsCheckbox/index.d.ts +1 -0
  11. package/dist/components/NsChip/NsChip.vue.d.ts +44 -0
  12. package/dist/components/NsChip/index.d.ts +1 -0
  13. package/dist/components/NsDialog/NsDialog.vue.d.ts +42 -0
  14. package/dist/components/NsDialog/index.d.ts +1 -0
  15. package/dist/components/NsForm/NsForm.vue.d.ts +34 -0
  16. package/dist/components/NsForm/index.d.ts +1 -0
  17. package/dist/components/NsInput/NsInput.vue.d.ts +42 -0
  18. package/dist/components/NsInput/index.d.ts +1 -0
  19. package/dist/components/NsList/NsList.vue.d.ts +34 -0
  20. package/dist/components/NsList/index.d.ts +1 -0
  21. package/dist/components/NsSelect/NsSelect.vue.d.ts +59 -0
  22. package/dist/components/NsSelect/index.d.ts +1 -0
  23. package/dist/components/NsSkeleton/NsSkeleton.vue.d.ts +33 -0
  24. package/dist/components/NsSkeleton/index.d.ts +2 -0
  25. package/dist/components/NsThemeProvider/NsThemeProvider.vue.d.ts +36 -0
  26. package/dist/components/NsThemeProvider/index.d.ts +1 -0
  27. package/dist/components/NsToggle/NsToggle.vue.d.ts +30 -0
  28. package/dist/components/NsToggle/index.d.ts +1 -0
  29. package/dist/components/NsTooltip/NsTooltip.vue.d.ts +35 -0
  30. package/dist/components/NsTooltip/index.d.ts +1 -0
  31. package/dist/composables/index.d.ts +4 -0
  32. package/dist/composables/useNsDarkMode.d.ts +37 -0
  33. package/dist/composables/useNsDefaults.d.ts +25 -0
  34. package/dist/composables/useNsLocale.d.ts +28 -0
  35. package/dist/index.d.ts +43 -0
  36. package/dist/locale/NsLocaleMessages.d.ts +58 -0
  37. package/dist/locale/en-CA.d.ts +8 -0
  38. package/dist/locale/fr-CA.d.ts +5 -0
  39. package/dist/locale/index.d.ts +3 -0
  40. package/dist/nonsuch-components.css +1 -1
  41. package/dist/nonsuch-components.js +251 -215
  42. package/dist/plugin.d.ts +42 -0
  43. package/dist/quasarConfig.d.ts +41 -0
  44. package/dist/tokens/index.d.ts +20 -0
  45. package/package.json +5 -3
@@ -1,22 +1,22 @@
1
- import M from "quasar/src/components/btn/QBtn.js";
2
- import { defineComponent as u, openBlock as n, createBlock as d, mergeProps as i, withCtx as l, renderSlot as r, createVNode as g, unref as F, provide as U, inject as j, createSlots as k, renderList as Q, normalizeProps as E, guardReactiveProps as z, createElementVNode as L, toDisplayString as $, createElementBlock as K, createCommentVNode as p, computed as T, ref as I, onMounted as Z, onUnmounted as G, readonly as w } from "vue";
3
- import H from "quasar/src/components/spinner/QSpinnerDots.js";
4
- import Y from "quasar/src/components/skeleton/QSkeleton.js";
5
- import J from "quasar/src/components/input/QInput.js";
6
- import b from "quasar/src/components/card/QCardSection.js";
7
- import A from "quasar/src/components/card/QCardActions.js";
8
- import q from "quasar/src/components/card/QCard.js";
9
- import W from "quasar/src/components/select/QSelect.js";
10
- import X from "quasar/src/components/checkbox/QCheckbox.js";
11
- import x from "quasar/src/components/toggle/QToggle.js";
12
- import _ from "quasar/src/components/form/QForm.js";
13
- import ee from "quasar/src/components/dialog/QDialog.js";
14
- import te from "quasar/src/components/banner/QBanner.js";
1
+ import F from "quasar/src/components/btn/QBtn.js";
2
+ import { defineComponent as i, openBlock as n, createBlock as d, mergeProps as c, withCtx as s, renderSlot as r, createVNode as y, unref as U, provide as j, inject as K, createSlots as N, renderList as E, normalizeProps as z, guardReactiveProps as T, useId as k, createElementVNode as A, toDisplayString as B, createElementBlock as Z, createCommentVNode as v, computed as g, ref as L, onMounted as G, onUnmounted as H, readonly as Q } from "vue";
3
+ import Y from "quasar/src/components/spinner/QSpinnerDots.js";
4
+ import J from "quasar/src/components/skeleton/QSkeleton.js";
5
+ import W from "quasar/src/components/input/QInput.js";
6
+ import h from "quasar/src/components/card/QCardSection.js";
7
+ import q from "quasar/src/components/card/QCardActions.js";
8
+ import D from "quasar/src/components/card/QCard.js";
9
+ import X from "quasar/src/components/select/QSelect.js";
10
+ import x from "quasar/src/components/checkbox/QCheckbox.js";
11
+ import _ from "quasar/src/components/toggle/QToggle.js";
12
+ import ee from "quasar/src/components/form/QForm.js";
13
+ import te from "quasar/src/components/dialog/QDialog.js";
14
+ import ae from "quasar/src/components/banner/QBanner.js";
15
15
  import oe from "quasar/src/components/avatar/QAvatar.js";
16
- import ae from "quasar/src/components/chip/QChip.js";
17
- import le from "quasar/src/components/item/QList.js";
18
- import se from "quasar/src/components/tooltip/QTooltip.js";
19
- const ne = /* @__PURE__ */ u({
16
+ import le from "quasar/src/components/chip/QChip.js";
17
+ import se from "quasar/src/components/item/QList.js";
18
+ import ne from "quasar/src/components/tooltip/QTooltip.js";
19
+ const re = /* @__PURE__ */ i({
20
20
  __name: "NsButton",
21
21
  props: {
22
22
  color: { default: "primary" },
@@ -27,32 +27,33 @@ const ne = /* @__PURE__ */ u({
27
27
  loading: { type: Boolean, default: !1 }
28
28
  },
29
29
  setup(e) {
30
- return (t, o) => (n(), d(M, i(t.$attrs, {
30
+ return (t, a) => (n(), d(F, c(t.$attrs, {
31
31
  color: e.color,
32
32
  size: e.size,
33
33
  unelevated: e.unelevated,
34
34
  "no-caps": e.noCaps,
35
35
  rounded: e.rounded,
36
36
  loading: e.loading,
37
+ "aria-busy": e.loading,
37
38
  class: "ns-button"
38
39
  }), {
39
- loading: l(() => [
40
+ loading: s(() => [
40
41
  r(t.$slots, "loading", {}, () => [
41
- g(F(H), { color: "white" })
42
+ y(U(Y), { color: "white" })
42
43
  ], !0)
43
44
  ]),
44
- default: l(() => [
45
+ default: s(() => [
45
46
  r(t.$slots, "default", {}, void 0, !0)
46
47
  ]),
47
48
  _: 3
48
- }, 16, ["color", "size", "unelevated", "no-caps", "rounded", "loading"]));
49
+ }, 16, ["color", "size", "unelevated", "no-caps", "rounded", "loading", "aria-busy"]));
49
50
  }
50
51
  }), f = (e, t) => {
51
- const o = e.__vccOpts || e;
52
- for (const [a, s] of t)
53
- o[a] = s;
54
- return o;
55
- }, Ke = /* @__PURE__ */ f(ne, [["__scopeId", "data-v-7f6c2760"]]), re = /* @__PURE__ */ u({
52
+ const a = e.__vccOpts || e;
53
+ for (const [o, l] of t)
54
+ a[o] = l;
55
+ return a;
56
+ }, Ze = /* @__PURE__ */ f(re, [["__scopeId", "data-v-59b40e5f"]]), de = /* @__PURE__ */ i({
56
57
  __name: "NsSkeleton",
57
58
  props: {
58
59
  type: { default: "rect" },
@@ -63,17 +64,18 @@ const ne = /* @__PURE__ */ u({
63
64
  height: { default: void 0 }
64
65
  },
65
66
  setup(e) {
66
- return (t, o) => (n(), d(Y, i(t.$attrs, {
67
+ return (t, a) => (n(), d(J, c(t.$attrs, {
67
68
  type: e.type,
68
69
  animation: e.animation,
69
70
  square: e.square,
70
71
  bordered: e.bordered,
71
72
  width: e.width,
72
73
  height: e.height,
74
+ "aria-hidden": "true",
73
75
  class: "ns-skeleton"
74
76
  }), null, 16, ["type", "animation", "square", "bordered", "width", "height"]));
75
77
  }
76
- }), Ze = /* @__PURE__ */ f(re, [["__scopeId", "data-v-62627927"]]), B = {
78
+ }), Ge = /* @__PURE__ */ f(de, [["__scopeId", "data-v-dfd40b8a"]]), S = {
77
79
  common: {
78
80
  loading: "Loading…",
79
81
  retry: "Retry",
@@ -109,22 +111,22 @@ const ne = /* @__PURE__ */ u({
109
111
  tooShort: "Too short",
110
112
  tooLong: "Too long"
111
113
  }
112
- }, N = /* @__PURE__ */ Symbol("ns-locale");
113
- function de(e) {
114
- U(N, e);
114
+ }, V = /* @__PURE__ */ Symbol("ns-locale");
115
+ function ie(e) {
116
+ j(V, e);
115
117
  }
116
118
  function ue() {
117
- return j(N, B);
119
+ return K(V, S);
118
120
  }
119
- const Ge = /* @__PURE__ */ u({
121
+ const He = /* @__PURE__ */ i({
120
122
  __name: "NsThemeProvider",
121
123
  props: {
122
- locale: { default: () => B }
124
+ locale: { default: () => S }
123
125
  },
124
126
  setup(e) {
125
- return de(e.locale), (o, a) => r(o.$slots, "default");
127
+ return ie(e.locale), (a, o) => r(a.$slots, "default");
126
128
  }
127
- }), ie = /* @__PURE__ */ u({
129
+ }), ce = /* @__PURE__ */ i({
128
130
  __name: "NsInput",
129
131
  props: {
130
132
  label: { default: void 0 },
@@ -135,27 +137,27 @@ const Ge = /* @__PURE__ */ u({
135
137
  },
136
138
  emits: ["update:modelValue"],
137
139
  setup(e) {
138
- return (t, o) => (n(), d(J, i(t.$attrs, {
140
+ return (t, a) => (n(), d(W, c(t.$attrs, {
139
141
  "model-value": e.modelValue,
140
142
  label: e.label,
141
143
  outlined: e.outlined,
142
144
  dense: e.dense,
143
145
  rules: e.rules,
144
146
  class: "ns-input",
145
- "onUpdate:modelValue": o[0] || (o[0] = (a) => t.$emit("update:modelValue", a))
146
- }), k({ _: 2 }, [
147
- Q(t.$slots, (a, s) => ({
148
- name: s,
149
- fn: l((c) => [
150
- r(t.$slots, s, E(z(c ?? {})), void 0, !0)
147
+ "onUpdate:modelValue": a[0] || (a[0] = (o) => t.$emit("update:modelValue", o))
148
+ }), N({ _: 2 }, [
149
+ E(t.$slots, (o, l) => ({
150
+ name: l,
151
+ fn: s((u) => [
152
+ r(t.$slots, l, z(T(u ?? {})), void 0, !0)
151
153
  ])
152
154
  }))
153
155
  ]), 1040, ["model-value", "label", "outlined", "dense", "rules"]));
154
156
  }
155
- }), He = /* @__PURE__ */ f(ie, [["__scopeId", "data-v-7ebf3284"]]), fe = { class: "text-h6" }, ce = {
157
+ }), Ye = /* @__PURE__ */ f(ce, [["__scopeId", "data-v-7ebf3284"]]), fe = { class: "text-h6" }, me = {
156
158
  key: 0,
157
159
  class: "text-subtitle2 text-grey"
158
- }, me = /* @__PURE__ */ u({
160
+ }, ve = /* @__PURE__ */ i({
159
161
  __name: "NsCard",
160
162
  props: {
161
163
  title: { default: void 0 },
@@ -163,42 +165,46 @@ const Ge = /* @__PURE__ */ u({
163
165
  flat: { type: Boolean, default: !1 }
164
166
  },
165
167
  setup(e) {
166
- return (t, o) => (n(), d(q, i(t.$attrs, {
167
- class: ["ns-card", { "ns-card--flat": e.flat }]
168
+ const t = `ns-card-header-${k()}`;
169
+ return (a, o) => (n(), d(D, c(a.$attrs, {
170
+ class: ["ns-card", { "ns-card--flat": e.flat }],
171
+ role: e.title || a.$slots.header ? "region" : void 0,
172
+ "aria-labelledby": e.title || a.$slots.header ? t : void 0
168
173
  }), {
169
- default: l(() => [
170
- e.title || t.$slots.header ? (n(), d(b, {
174
+ default: s(() => [
175
+ e.title || a.$slots.header ? (n(), d(h, {
171
176
  key: 0,
177
+ id: t,
172
178
  class: "ns-card__header"
173
179
  }, {
174
- default: l(() => [
175
- r(t.$slots, "header", {}, () => [
176
- L("div", fe, $(e.title), 1),
177
- e.subtitle ? (n(), K("div", ce, $(e.subtitle), 1)) : p("", !0)
180
+ default: s(() => [
181
+ r(a.$slots, "header", {}, () => [
182
+ A("div", fe, B(e.title), 1),
183
+ e.subtitle ? (n(), Z("div", me, B(e.subtitle), 1)) : v("", !0)
178
184
  ], !0)
179
185
  ]),
180
186
  _: 3
181
- })) : p("", !0),
182
- g(b, null, {
183
- default: l(() => [
184
- r(t.$slots, "default", {}, void 0, !0)
187
+ })) : v("", !0),
188
+ y(h, null, {
189
+ default: s(() => [
190
+ r(a.$slots, "default", {}, void 0, !0)
185
191
  ]),
186
192
  _: 3
187
193
  }),
188
- t.$slots.actions ? (n(), d(A, {
194
+ a.$slots.actions ? (n(), d(q, {
189
195
  key: 1,
190
196
  align: "right"
191
197
  }, {
192
- default: l(() => [
193
- r(t.$slots, "actions", {}, void 0, !0)
198
+ default: s(() => [
199
+ r(a.$slots, "actions", {}, void 0, !0)
194
200
  ]),
195
201
  _: 3
196
- })) : p("", !0)
202
+ })) : v("", !0)
197
203
  ]),
198
204
  _: 3
199
- }, 16, ["class"]));
205
+ }, 16, ["class", "role", "aria-labelledby"]));
200
206
  }
201
- }), Ye = /* @__PURE__ */ f(me, [["__scopeId", "data-v-41ecea50"]]), pe = /* @__PURE__ */ u({
207
+ }), Je = /* @__PURE__ */ f(ve, [["__scopeId", "data-v-7769879a"]]), pe = /* @__PURE__ */ i({
202
208
  __name: "NsSelect",
203
209
  props: {
204
210
  label: { default: void 0 },
@@ -213,7 +219,7 @@ const Ge = /* @__PURE__ */ u({
213
219
  },
214
220
  emits: ["update:modelValue"],
215
221
  setup(e) {
216
- return (t, o) => (n(), d(W, i(t.$attrs, {
222
+ return (t, a) => (n(), d(X, c(t.$attrs, {
217
223
  "model-value": e.modelValue,
218
224
  label: e.label,
219
225
  options: e.options,
@@ -224,17 +230,17 @@ const Ge = /* @__PURE__ */ u({
224
230
  "emit-value": e.emitValue,
225
231
  "map-options": e.mapOptions,
226
232
  class: "ns-select",
227
- "onUpdate:modelValue": o[0] || (o[0] = (a) => t.$emit("update:modelValue", a))
228
- }), k({ _: 2 }, [
229
- Q(t.$slots, (a, s) => ({
230
- name: s,
231
- fn: l((c) => [
232
- r(t.$slots, s, E(z(c ?? {})), void 0, !0)
233
+ "onUpdate:modelValue": a[0] || (a[0] = (o) => t.$emit("update:modelValue", o))
234
+ }), N({ _: 2 }, [
235
+ E(t.$slots, (o, l) => ({
236
+ name: l,
237
+ fn: s((u) => [
238
+ r(t.$slots, l, z(T(u ?? {})), void 0, !0)
233
239
  ])
234
240
  }))
235
241
  ]), 1040, ["model-value", "label", "options", "outlined", "dense", "rules", "multiple", "emit-value", "map-options"]));
236
242
  }
237
- }), Je = /* @__PURE__ */ f(pe, [["__scopeId", "data-v-081cebe3"]]), ve = /* @__PURE__ */ u({
243
+ }), We = /* @__PURE__ */ f(pe, [["__scopeId", "data-v-081cebe3"]]), be = /* @__PURE__ */ i({
238
244
  __name: "NsCheckbox",
239
245
  props: {
240
246
  label: { default: void 0 },
@@ -245,17 +251,17 @@ const Ge = /* @__PURE__ */ u({
245
251
  },
246
252
  emits: ["update:modelValue"],
247
253
  setup(e) {
248
- return (t, o) => (n(), d(X, i(t.$attrs, {
254
+ return (t, a) => (n(), d(x, c(t.$attrs, {
249
255
  "model-value": e.modelValue,
250
256
  label: e.label,
251
257
  color: e.color,
252
258
  dense: e.dense,
253
259
  disable: e.disable,
254
260
  class: "ns-checkbox",
255
- "onUpdate:modelValue": o[0] || (o[0] = (a) => t.$emit("update:modelValue", a))
261
+ "onUpdate:modelValue": a[0] || (a[0] = (o) => t.$emit("update:modelValue", o))
256
262
  }), null, 16, ["model-value", "label", "color", "dense", "disable"]));
257
263
  }
258
- }), We = /* @__PURE__ */ f(ve, [["__scopeId", "data-v-2e481f8b"]]), ye = /* @__PURE__ */ u({
264
+ }), Xe = /* @__PURE__ */ f(be, [["__scopeId", "data-v-2e481f8b"]]), ye = /* @__PURE__ */ i({
259
265
  __name: "NsToggle",
260
266
  props: {
261
267
  label: { default: void 0 },
@@ -266,36 +272,40 @@ const Ge = /* @__PURE__ */ u({
266
272
  },
267
273
  emits: ["update:modelValue"],
268
274
  setup(e) {
269
- return (t, o) => (n(), d(x, i(t.$attrs, {
275
+ return (t, a) => (n(), d(_, c(t.$attrs, {
270
276
  "model-value": e.modelValue,
271
277
  label: e.label,
272
278
  color: e.color,
273
279
  dense: e.dense,
274
280
  disable: e.disable,
281
+ role: "switch",
282
+ "aria-checked": e.modelValue,
275
283
  class: "ns-toggle",
276
- "onUpdate:modelValue": o[0] || (o[0] = (a) => t.$emit("update:modelValue", a))
277
- }), null, 16, ["model-value", "label", "color", "dense", "disable"]));
284
+ "onUpdate:modelValue": a[0] || (a[0] = (o) => t.$emit("update:modelValue", o))
285
+ }), null, 16, ["model-value", "label", "color", "dense", "disable", "aria-checked"]));
278
286
  }
279
- }), Xe = /* @__PURE__ */ f(ye, [["__scopeId", "data-v-beb96bf2"]]), ge = /* @__PURE__ */ u({
287
+ }), xe = /* @__PURE__ */ f(ye, [["__scopeId", "data-v-f8c90530"]]), ge = /* @__PURE__ */ i({
280
288
  __name: "NsForm",
281
289
  props: {
282
- greedy: { type: Boolean, default: !0 }
290
+ greedy: { type: Boolean, default: !0 },
291
+ ariaLabel: { default: void 0 }
283
292
  },
284
293
  emits: ["submit", "validationError"],
285
294
  setup(e) {
286
- return (t, o) => (n(), d(_, i(t.$attrs, {
295
+ return (t, a) => (n(), d(ee, c(t.$attrs, {
287
296
  class: "ns-form",
288
297
  greedy: e.greedy,
289
- onSubmit: o[0] || (o[0] = (a) => t.$emit("submit", a)),
290
- onValidationError: o[1] || (o[1] = (a) => t.$emit("validationError", a))
298
+ "aria-label": e.ariaLabel,
299
+ onSubmit: a[0] || (a[0] = (o) => t.$emit("submit", o)),
300
+ onValidationError: a[1] || (a[1] = (o) => t.$emit("validationError", o))
291
301
  }), {
292
- default: l(() => [
302
+ default: s(() => [
293
303
  r(t.$slots, "default", {}, void 0, !0)
294
304
  ]),
295
305
  _: 3
296
- }, 16, ["greedy"]));
306
+ }, 16, ["greedy", "aria-label"]));
297
307
  }
298
- }), xe = /* @__PURE__ */ f(ge, [["__scopeId", "data-v-0fd74bb1"]]), be = { class: "text-h6" }, he = /* @__PURE__ */ u({
308
+ }), _e = /* @__PURE__ */ f(ge, [["__scopeId", "data-v-e20d14ce"]]), he = { class: "text-h6" }, $e = /* @__PURE__ */ i({
299
309
  __name: "NsDialog",
300
310
  props: {
301
311
  modelValue: { type: Boolean, default: !1 },
@@ -305,51 +315,62 @@ const Ge = /* @__PURE__ */ u({
305
315
  },
306
316
  emits: ["update:modelValue"],
307
317
  setup(e) {
308
- return (t, o) => (n(), d(ee, i(t.$attrs, {
318
+ const t = `ns-dialog-title-${k()}`, a = `ns-dialog-body-${k()}`;
319
+ return (o, l) => (n(), d(te, c(o.$attrs, {
309
320
  "model-value": e.modelValue,
310
321
  persistent: e.persistent,
311
322
  "no-backdrop-dismiss": e.noBackdropDismiss,
323
+ "aria-labelledby": e.title || o.$slots.header ? t : void 0,
324
+ "aria-describedby": a,
312
325
  class: "ns-dialog",
313
- "onUpdate:modelValue": o[0] || (o[0] = (a) => t.$emit("update:modelValue", a))
326
+ "onUpdate:modelValue": l[0] || (l[0] = (u) => o.$emit("update:modelValue", u))
314
327
  }), {
315
- default: l(() => [
316
- g(q, { class: "ns-dialog__card" }, {
317
- default: l(() => [
318
- e.title || t.$slots.header ? (n(), d(b, {
328
+ default: s(() => [
329
+ y(D, {
330
+ class: "ns-dialog__card",
331
+ role: "dialog",
332
+ "aria-modal": !0
333
+ }, {
334
+ default: s(() => [
335
+ e.title || o.$slots.header ? (n(), d(h, {
319
336
  key: 0,
337
+ id: t,
320
338
  class: "ns-dialog__header"
321
339
  }, {
322
- default: l(() => [
323
- r(t.$slots, "header", {}, () => [
324
- L("div", be, $(e.title), 1)
340
+ default: s(() => [
341
+ r(o.$slots, "header", {}, () => [
342
+ A("div", he, B(e.title), 1)
325
343
  ], !0)
326
344
  ]),
327
345
  _: 3
328
- })) : p("", !0),
329
- g(b, { class: "ns-dialog__body" }, {
330
- default: l(() => [
331
- r(t.$slots, "default", {}, void 0, !0)
346
+ })) : v("", !0),
347
+ y(h, {
348
+ id: a,
349
+ class: "ns-dialog__body"
350
+ }, {
351
+ default: s(() => [
352
+ r(o.$slots, "default", {}, void 0, !0)
332
353
  ]),
333
354
  _: 3
334
355
  }),
335
- t.$slots.actions ? (n(), d(A, {
356
+ o.$slots.actions ? (n(), d(q, {
336
357
  key: 1,
337
358
  align: "right",
338
359
  class: "ns-dialog__actions"
339
360
  }, {
340
- default: l(() => [
341
- r(t.$slots, "actions", {}, void 0, !0)
361
+ default: s(() => [
362
+ r(o.$slots, "actions", {}, void 0, !0)
342
363
  ]),
343
364
  _: 3
344
- })) : p("", !0)
365
+ })) : v("", !0)
345
366
  ]),
346
367
  _: 3
347
368
  })
348
369
  ]),
349
370
  _: 3
350
- }, 16, ["model-value", "persistent", "no-backdrop-dismiss"]));
371
+ }, 16, ["model-value", "persistent", "no-backdrop-dismiss", "aria-labelledby"]));
351
372
  }
352
- }), _e = /* @__PURE__ */ f(he, [["__scopeId", "data-v-9bff0f12"]]), $e = /* @__PURE__ */ u({
373
+ }), et = /* @__PURE__ */ f($e, [["__scopeId", "data-v-4fca48ca"]]), ke = /* @__PURE__ */ i({
353
374
  __name: "NsBanner",
354
375
  props: {
355
376
  type: { default: "info" },
@@ -357,40 +378,48 @@ const Ge = /* @__PURE__ */ u({
357
378
  rounded: { type: Boolean, default: !0 }
358
379
  },
359
380
  setup(e) {
360
- return (t, o) => (n(), d(te, i(t.$attrs, {
381
+ const t = e, a = g(
382
+ () => t.type === "error" || t.type === "warning" ? "alert" : "status"
383
+ ), o = g(
384
+ () => t.type === "error" || t.type === "warning" ? "assertive" : "polite"
385
+ );
386
+ return (l, u) => (n(), d(ae, c(l.$attrs, {
361
387
  class: ["ns-banner", `ns-banner--${e.type}`],
362
388
  dense: e.dense,
363
- rounded: e.rounded
364
- }), k({
365
- default: l(() => [
366
- r(t.$slots, "default", {}, void 0, !0)
389
+ rounded: e.rounded,
390
+ role: a.value,
391
+ "aria-live": o.value
392
+ }), N({
393
+ default: s(() => [
394
+ r(l.$slots, "default", {}, void 0, !0)
367
395
  ]),
368
396
  _: 2
369
397
  }, [
370
- t.$slots.avatar ? {
398
+ l.$slots.avatar ? {
371
399
  name: "avatar",
372
- fn: l(() => [
373
- r(t.$slots, "avatar", {}, void 0, !0)
400
+ fn: s(() => [
401
+ r(l.$slots, "avatar", {}, void 0, !0)
374
402
  ]),
375
403
  key: "0"
376
404
  } : void 0,
377
- t.$slots.action ? {
405
+ l.$slots.action ? {
378
406
  name: "action",
379
- fn: l(() => [
380
- r(t.$slots, "action", {}, void 0, !0)
407
+ fn: s(() => [
408
+ r(l.$slots, "action", {}, void 0, !0)
381
409
  ]),
382
410
  key: "1"
383
411
  } : void 0
384
- ]), 1040, ["class", "dense", "rounded"]));
412
+ ]), 1040, ["class", "dense", "rounded", "role", "aria-live"]));
385
413
  }
386
- }), et = /* @__PURE__ */ f($e, [["__scopeId", "data-v-35ed7ae7"]]), ke = /* @__PURE__ */ u({
414
+ }), tt = /* @__PURE__ */ f(ke, [["__scopeId", "data-v-18ebd6f5"]]), Be = /* @__PURE__ */ i({
387
415
  __name: "NsAvatar",
388
416
  props: {
389
417
  size: { default: "md" },
390
418
  color: { default: "primary" },
391
419
  textColor: { default: "white" },
392
420
  rounded: { type: Boolean, default: !1 },
393
- square: { type: Boolean, default: !1 }
421
+ square: { type: Boolean, default: !1 },
422
+ ariaLabel: { default: void 0 }
394
423
  },
395
424
  setup(e) {
396
425
  const t = {
@@ -398,22 +427,25 @@ const Ge = /* @__PURE__ */ u({
398
427
  md: "48px",
399
428
  lg: "64px",
400
429
  xl: "96px"
401
- }, o = e, a = T(() => t[o.size] ?? o.size);
402
- return (s, c) => (n(), d(oe, i(s.$attrs, {
403
- size: a.value,
430
+ }, a = e, o = g(() => t[a.size] ?? a.size);
431
+ return (l, u) => (n(), d(oe, c(l.$attrs, {
432
+ size: o.value,
404
433
  color: e.color,
405
434
  "text-color": e.textColor,
406
435
  rounded: e.rounded,
407
436
  square: e.square,
437
+ "aria-label": e.ariaLabel,
438
+ "aria-hidden": e.ariaLabel ? void 0 : "true",
439
+ role: e.ariaLabel ? "img" : void 0,
408
440
  class: "ns-avatar"
409
441
  }), {
410
- default: l(() => [
411
- r(s.$slots, "default", {}, void 0, !0)
442
+ default: s(() => [
443
+ r(l.$slots, "default", {}, void 0, !0)
412
444
  ]),
413
445
  _: 3
414
- }, 16, ["size", "color", "text-color", "rounded", "square"]));
446
+ }, 16, ["size", "color", "text-color", "rounded", "square", "aria-label", "aria-hidden", "role"]));
415
447
  }
416
- }), tt = /* @__PURE__ */ f(ke, [["__scopeId", "data-v-e4df869f"]]), Be = /* @__PURE__ */ u({
448
+ }), at = /* @__PURE__ */ f(Be, [["__scopeId", "data-v-6a1b44b8"]]), Ne = /* @__PURE__ */ i({
417
449
  __name: "NsChip",
418
450
  props: {
419
451
  color: { default: "primary" },
@@ -425,7 +457,7 @@ const Ge = /* @__PURE__ */ u({
425
457
  },
426
458
  emits: ["remove"],
427
459
  setup(e) {
428
- return (t, o) => (n(), d(ae, i(t.$attrs, {
460
+ return (t, a) => (n(), d(le, c(t.$attrs, {
429
461
  color: e.color,
430
462
  "text-color": e.textColor,
431
463
  outline: e.outline,
@@ -433,35 +465,38 @@ const Ge = /* @__PURE__ */ u({
433
465
  removable: e.removable,
434
466
  clickable: e.clickable,
435
467
  class: "ns-chip",
436
- onRemove: o[0] || (o[0] = (a) => t.$emit("remove"))
468
+ onRemove: a[0] || (a[0] = (o) => t.$emit("remove"))
437
469
  }), {
438
- default: l(() => [
470
+ default: s(() => [
439
471
  r(t.$slots, "default", {}, void 0, !0)
440
472
  ]),
441
473
  _: 3
442
474
  }, 16, ["color", "text-color", "outline", "dense", "removable", "clickable"]));
443
475
  }
444
- }), ot = /* @__PURE__ */ f(Be, [["__scopeId", "data-v-1a2191f1"]]), Ne = /* @__PURE__ */ u({
476
+ }), ot = /* @__PURE__ */ f(Ne, [["__scopeId", "data-v-1a2191f1"]]), Se = /* @__PURE__ */ i({
445
477
  __name: "NsList",
446
478
  props: {
447
479
  bordered: { type: Boolean, default: !1 },
448
480
  separator: { type: Boolean, default: !0 },
449
- dense: { type: Boolean, default: !1 }
481
+ dense: { type: Boolean, default: !1 },
482
+ ariaLabel: { default: void 0 }
450
483
  },
451
484
  setup(e) {
452
- return (t, o) => (n(), d(le, i(t.$attrs, {
485
+ return (t, a) => (n(), d(se, c(t.$attrs, {
453
486
  bordered: e.bordered,
454
487
  separator: e.separator,
455
488
  dense: e.dense,
489
+ "aria-label": e.ariaLabel,
490
+ role: "list",
456
491
  class: "ns-list"
457
492
  }), {
458
- default: l(() => [
493
+ default: s(() => [
459
494
  r(t.$slots, "default", {}, void 0, !0)
460
495
  ]),
461
496
  _: 3
462
- }, 16, ["bordered", "separator", "dense"]));
497
+ }, 16, ["bordered", "separator", "dense", "aria-label"]));
463
498
  }
464
- }), at = /* @__PURE__ */ f(Ne, [["__scopeId", "data-v-b778ff3f"]]), Se = /* @__PURE__ */ u({
499
+ }), lt = /* @__PURE__ */ f(Se, [["__scopeId", "data-v-65aec20e"]]), Ve = /* @__PURE__ */ i({
465
500
  __name: "NsTooltip",
466
501
  props: {
467
502
  delay: { default: 300 },
@@ -470,29 +505,29 @@ const Ge = /* @__PURE__ */ u({
470
505
  self: { default: "top middle" }
471
506
  },
472
507
  setup(e) {
473
- return (t, o) => (n(), d(se, i(t.$attrs, {
508
+ return (t, a) => (n(), d(ne, c(t.$attrs, {
474
509
  delay: e.delay,
475
510
  offset: e.offset,
476
511
  anchor: e.anchor,
477
512
  self: e.self,
478
513
  class: "ns-tooltip"
479
514
  }), {
480
- default: l(() => [
515
+ default: s(() => [
481
516
  r(t.$slots, "default", {}, void 0, !0)
482
517
  ]),
483
518
  _: 3
484
519
  }, 16, ["delay", "offset", "anchor", "self"]));
485
520
  }
486
- }), lt = /* @__PURE__ */ f(Se, [["__scopeId", "data-v-9cb6af8f"]]);
487
- function st(e = {}) {
488
- const { locale: t = B } = e;
521
+ }), st = /* @__PURE__ */ f(Ve, [["__scopeId", "data-v-9cb6af8f"]]);
522
+ function nt(e = {}) {
523
+ const { locale: t = S } = e;
489
524
  return {
490
- install(o) {
491
- o.provide(N, t);
525
+ install(a) {
526
+ a.provide(V, t);
492
527
  }
493
528
  };
494
529
  }
495
- const Ve = {
530
+ const Ie = {
496
531
  primary: "#3b82f6",
497
532
  // PLACEHOLDER — matches --ns-color-primary
498
533
  secondary: "#8b5cf6",
@@ -512,20 +547,20 @@ const Ve = {
512
547
  warning: "#f59e0b"
513
548
  // PLACEHOLDER — matches --ns-color-warning
514
549
  };
515
- function nt(e = {}) {
516
- const { brand: t = {}, plugins: o = {}, ...a } = e;
550
+ function rt(e = {}) {
551
+ const { brand: t = {}, plugins: a = {}, ...o } = e;
517
552
  return {
518
553
  config: {
519
554
  brand: {
520
- ...Ve,
555
+ ...Ie,
521
556
  ...t
522
557
  }
523
558
  },
524
- plugins: o,
525
- ...a
559
+ plugins: a,
560
+ ...o
526
561
  };
527
562
  }
528
- const rt = {
563
+ const dt = {
529
564
  common: {
530
565
  loading: "Chargement…",
531
566
  retry: "Réessayer",
@@ -562,98 +597,99 @@ const rt = {
562
597
  tooLong: "Trop long"
563
598
  }
564
599
  };
565
- function dt(e, t) {
566
- const o = ue();
567
- return T(() => {
568
- const a = e();
569
- if (a != null) return a;
570
- const s = t.split(".");
571
- let c = o;
572
- for (const v of s)
573
- c = c[v];
574
- return c;
600
+ function it(e, t) {
601
+ const a = ue();
602
+ return g(() => {
603
+ const o = e();
604
+ if (o != null) return o;
605
+ const l = t.split(".");
606
+ let u = a;
607
+ for (const p of l)
608
+ u = u[p];
609
+ return u;
575
610
  });
576
611
  }
577
- const h = "ns-dark-mode";
612
+ const $ = "ns-dark-mode";
578
613
  function ut() {
579
- const e = I(!1), t = I("system");
580
- let o = null, a = null;
581
- function s(m) {
614
+ const e = L(!1), t = L("system");
615
+ let a = null, o = () => {
616
+ };
617
+ function l(m) {
582
618
  if (e.value = m, typeof document < "u") {
583
- const y = document.documentElement;
584
- y.classList.toggle("dark", m), y.setAttribute("data-theme", m ? "dark" : "light");
619
+ const b = document.documentElement;
620
+ b.classList.toggle("dark", m), b.setAttribute("data-theme", m ? "dark" : "light");
585
621
  }
586
622
  }
587
- function c() {
623
+ function u() {
588
624
  return typeof window > "u" ? !1 : window.matchMedia("(prefers-color-scheme: dark)").matches;
589
625
  }
590
- function v() {
626
+ function p() {
591
627
  if (typeof localStorage > "u") return null;
592
- const m = localStorage.getItem(h);
628
+ const m = localStorage.getItem($);
593
629
  return m === "true" ? !0 : m === "false" ? !1 : null;
594
630
  }
595
- function S(m) {
596
- typeof localStorage < "u" && localStorage.setItem(h, String(m));
597
- }
598
- function D() {
599
- typeof localStorage < "u" && localStorage.removeItem(h);
631
+ function I(m) {
632
+ typeof localStorage < "u" && localStorage.setItem($, String(m));
600
633
  }
601
- function V() {
602
- t.value = "user", S(!0), s(!0);
634
+ function P() {
635
+ typeof localStorage < "u" && localStorage.removeItem($);
603
636
  }
604
637
  function C() {
605
- t.value = "user", S(!1), s(!1);
638
+ t.value = "user", I(!0), l(!0);
606
639
  }
607
- function P() {
608
- e.value ? C() : V();
640
+ function w() {
641
+ t.value = "user", I(!1), l(!1);
609
642
  }
610
643
  function R() {
611
- D(), t.value = "system", s(c());
644
+ e.value ? w() : C();
612
645
  }
613
646
  function O() {
614
- const m = v();
615
- m !== null ? (t.value = "storage", s(m)) : (t.value = "system", s(c())), typeof window < "u" && (o = window.matchMedia("(prefers-color-scheme: dark)"), a = (y) => {
616
- v() === null && (t.value = "system", s(y.matches));
617
- }, o.addEventListener("change", a));
647
+ P(), t.value = "system", l(u());
648
+ }
649
+ function M() {
650
+ const m = p();
651
+ m !== null ? (t.value = "storage", l(m)) : (t.value = "system", l(u())), typeof window < "u" && (a = window.matchMedia("(prefers-color-scheme: dark)"), o = (b) => {
652
+ p() === null && (t.value = "system", l(b.matches));
653
+ }, a.addEventListener("change", o));
618
654
  }
619
- return Z(O), G(() => {
620
- o && a && o.removeEventListener("change", a);
655
+ return G(M), H(() => {
656
+ a?.removeEventListener("change", o);
621
657
  }), {
622
- isDark: w(e),
623
- source: w(t),
624
- enable: V,
625
- disable: C,
626
- toggle: P,
627
- useSystem: R
658
+ isDark: Q(e),
659
+ source: Q(t),
660
+ enable: C,
661
+ disable: w,
662
+ toggle: R,
663
+ useSystem: O
628
664
  };
629
665
  }
630
- function it(e, t = document.documentElement) {
666
+ function ct(e, t = document.documentElement) {
631
667
  return getComputedStyle(t).getPropertyValue(e).trim();
632
668
  }
633
669
  export {
634
- tt as NsAvatar,
635
- et as NsBanner,
636
- Ke as NsButton,
637
- Ye as NsCard,
638
- We as NsCheckbox,
670
+ at as NsAvatar,
671
+ tt as NsBanner,
672
+ Ze as NsButton,
673
+ Je as NsCard,
674
+ Xe as NsCheckbox,
639
675
  ot as NsChip,
640
- _e as NsDialog,
641
- xe as NsForm,
642
- He as NsInput,
643
- at as NsList,
644
- N as NsLocaleKey,
645
- Je as NsSelect,
646
- Ze as NsSkeleton,
647
- Ge as NsThemeProvider,
648
- Xe as NsToggle,
649
- lt as NsTooltip,
650
- st as createNonsuch,
651
- nt as createQuasarConfig,
652
- it as getToken,
653
- B as nsLocaleEnCA,
654
- rt as nsLocaleFrCA,
655
- de as provideNsLocale,
676
+ et as NsDialog,
677
+ _e as NsForm,
678
+ Ye as NsInput,
679
+ lt as NsList,
680
+ V as NsLocaleKey,
681
+ We as NsSelect,
682
+ Ge as NsSkeleton,
683
+ He as NsThemeProvider,
684
+ xe as NsToggle,
685
+ st as NsTooltip,
686
+ nt as createNonsuch,
687
+ rt as createQuasarConfig,
688
+ ct as getToken,
689
+ S as nsLocaleEnCA,
690
+ dt as nsLocaleFrCA,
691
+ ie as provideNsLocale,
656
692
  ut as useNsDarkMode,
657
- dt as useNsDefault,
693
+ it as useNsDefault,
658
694
  ue as useNsLocale
659
695
  };