energy-components 1.21.0 → 1.23.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 (98) hide show
  1. package/dist/components/accordion.es.js +71 -53
  2. package/dist/components/avatar.es.js +1 -1
  3. package/dist/components/button.es.js +1 -1
  4. package/dist/components/checkbox.es.js +1 -1
  5. package/dist/components/collapsable.es.js +1 -1
  6. package/dist/components/collapsable.scss_vue_type_style_index_0_src_true_lang-f-OHx-l3.js +86 -0
  7. package/dist/components/datepicker.es.js +1 -1
  8. package/dist/components/directAccess.es.js +1 -1
  9. package/dist/components/dragAndDrop.es.js +1 -1
  10. package/dist/components/dropdown.es.js +1 -1
  11. package/dist/components/fileUploadItem.es.js +1 -1
  12. package/dist/components/filterChip.es.js +1 -1
  13. package/dist/components/filterTag.es.js +1 -1
  14. package/dist/components/{floating-ui.vue-oA1DfKeS.js → floating-ui.vue-DHEoOe5S.js} +305 -303
  15. package/dist/components/{icon-svg-C8XeOnqu.js → icon-svg-K8-vLJgV.js} +1257 -792
  16. package/dist/components/iconList.es.js +1 -1
  17. package/dist/components/iconSvg.es.js +1 -1
  18. package/dist/components/index.es.js +2 -2
  19. package/dist/components/infoBox.es.js +1 -1
  20. package/dist/components/link.es.js +84 -85
  21. package/dist/components/modal.es.js +41 -39
  22. package/dist/components/multiselect.es.js +52 -52
  23. package/dist/components/multiselectcontentwrapper.es.js +2 -2
  24. package/dist/components/persistentToast.es.js +1 -1
  25. package/dist/components/popover.es.js +2 -2
  26. package/dist/components/popoverMenu.es.js +51 -51
  27. package/dist/components/progressBar.es.js +2 -2
  28. package/dist/components/quantitySelector.es.js +1 -1
  29. package/dist/components/radioButton.es.js +1 -1
  30. package/dist/components/selectionChip.es.js +1 -1
  31. package/dist/components/sidedrawer.es.js +1 -1
  32. package/dist/components/style/accordion.css +1 -1
  33. package/dist/components/style/accordionGroup.css +1 -1
  34. package/dist/components/style/actionButton.css +1 -1
  35. package/dist/components/style/avatar.css +1 -1
  36. package/dist/components/style/badge.css +1 -1
  37. package/dist/components/style/breadcrumbs.css +1 -1
  38. package/dist/components/style/button.css +1 -1
  39. package/dist/components/style/card.css +1 -1
  40. package/dist/components/style/checkbox.css +1 -1
  41. package/dist/components/style/collapsable.css +1 -1
  42. package/dist/components/style/datepicker.css +1 -1
  43. package/dist/components/style/directAccess.css +1 -1
  44. package/dist/components/style/divider.css +1 -1
  45. package/dist/components/style/dragAndDrop.css +1 -1
  46. package/dist/components/style/dropdown.css +1 -1
  47. package/dist/components/style/fileUploadItem.css +1 -1
  48. package/dist/components/style/filterChip.css +1 -1
  49. package/dist/components/style/filterTag.css +1 -1
  50. package/dist/components/style/floatingActionButton.css +1 -1
  51. package/dist/components/style/icon-svg.css +1 -1
  52. package/dist/components/style/iconList.css +1 -1
  53. package/dist/components/style/indicator.css +1 -1
  54. package/dist/components/style/infoBox.css +1 -1
  55. package/dist/components/style/link.css +1 -1
  56. package/dist/components/style/loader.css +1 -1
  57. package/dist/components/style/modal.css +1 -1
  58. package/dist/components/style/multiselect.css +1 -1
  59. package/dist/components/style/multiselectcontentwrapper.css +1 -1
  60. package/dist/components/style/overlay.css +1 -1
  61. package/dist/components/style/pagination.css +1 -1
  62. package/dist/components/style/persistentToast.css +1 -1
  63. package/dist/components/style/popover.css +1 -1
  64. package/dist/components/style/popoverMenu.css +1 -1
  65. package/dist/components/style/progressBar.css +1 -1
  66. package/dist/components/style/quantitySelector.css +1 -1
  67. package/dist/components/style/radioButton.css +1 -1
  68. package/dist/components/style/selectionChip.css +1 -1
  69. package/dist/components/style/sidebar.css +1 -1
  70. package/dist/components/style/sidedrawer.css +1 -1
  71. package/dist/components/style/snackBar.css +1 -1
  72. package/dist/components/style/switch.css +1 -1
  73. package/dist/components/style/tabBar.css +1 -1
  74. package/dist/components/style/tablepaginatedcomponent.css +1 -1
  75. package/dist/components/style/tableslotedcomponent.css +1 -1
  76. package/dist/components/style/tag.css +1 -1
  77. package/dist/components/style/textArea.css +1 -1
  78. package/dist/components/style/textField.css +1 -1
  79. package/dist/components/style/toggle.css +1 -1
  80. package/dist/components/style/tooltip.css +1 -1
  81. package/dist/components/switch.es.js +1 -1
  82. package/dist/components/tabBar.es.js +1 -1
  83. package/dist/components/tablepaginatedcomponent.es.js +46 -46
  84. package/dist/components/tableslotedcomponent.es.js +119 -119
  85. package/dist/components/tag.es.js +1 -1
  86. package/dist/components/textArea.es.js +1 -1
  87. package/dist/components/textField.es.js +136 -131
  88. package/dist/components/toggle.es.js +24 -24
  89. package/dist/components/tooltip.es.js +2 -2
  90. package/dist/energy-components.es.js +6329 -5838
  91. package/dist/energy-components.umd.js +2 -2
  92. package/dist/style.css +1 -1
  93. package/dist/types/src/components/content/accordion/accordion.vue.d.ts +19 -0
  94. package/dist/types/src/components/input/datepicker/datepicker.vue.d.ts +1 -1
  95. package/dist/types/src/components/navigation/link/link.vue.d.ts +8 -5
  96. package/dist/types/tsconfig.tsbuildinfo +1 -1
  97. package/package.json +2 -2
  98. package/dist/components/collapsable.scss_vue_type_style_index_0_src_true_lang-6HkNT8L9.js +0 -86
@@ -1,14 +1,14 @@
1
- import { defineComponent as oe, toRefs as se, ref as c, computed as g, watch as q, onMounted as re, onBeforeUnmount as ie, createElementBlock as I, openBlock as p, normalizeClass as V, createElementVNode as _, createCommentVNode as x, renderSlot as L, createBlock as T, mergeProps as A, toHandlers as ue, unref as f, toDisplayString as K, withModifiers as de } from "vue";
2
- import { g as ce } from "./getInstance-GhoEcxLF.js";
3
- import { R as E, s as fe } from "./icon-svg-C8XeOnqu.js";
4
- import { _ as ve } from "./_plugin-vue_export-helper-CHgC5LLL.js";
5
- import './style/textField.css';const pe = { class: "rds-e-textfield__input-container" }, me = ["id", "type", "maxlength", "minlength", "disabled", "value", "autocomplete", "readonly"], he = ["for"], ye = {
1
+ import { defineComponent as ie, toRefs as ue, ref as c, computed as y, watch as P, onMounted as de, onBeforeUnmount as ce, createElementBlock as L, openBlock as m, normalizeClass as V, createElementVNode as g, createCommentVNode as _, renderSlot as T, createBlock as E, mergeProps as j, toHandlers as fe, unref as f, toDisplayString as W, withModifiers as ve } from "vue";
2
+ import { g as me } from "./getInstance-GhoEcxLF.js";
3
+ import { R as F, s as pe } from "./icon-svg-K8-vLJgV.js";
4
+ import { _ as he } from "./_plugin-vue_export-helper-CHgC5LLL.js";
5
+ import './style/textField.css';const ye = { class: "rds-e-textfield__input-container" }, ge = ["id", "type", "maxlength", "minlength", "disabled", "value", "autocomplete", "readonly"], _e = ["for"], xe = {
6
6
  key: 0,
7
7
  class: "rds-e-textfield__icon rds-e-textfield__icon--right"
8
- }, ge = {
8
+ }, be = {
9
9
  key: 0,
10
10
  class: "rds-e-textfield__helper"
11
- }, _e = /* @__PURE__ */ oe({
11
+ }, we = /* @__PURE__ */ ie({
12
12
  __name: "text-field",
13
13
  props: {
14
14
  /**
@@ -62,7 +62,7 @@ import './style/textField.css';const pe = { class: "rds-e-textfield__input-conta
62
62
  maxLength: {
63
63
  type: Number,
64
64
  required: !1,
65
- validator: (t) => t == null ? !0 : typeof t != "number" || Number.isNaN(t) ? (console.info("El valor de maxLength debe ser un número"), !1) : t < 0 ? (console.info("El valor de maxLength no puede ser menor a 0"), !1) : !0
65
+ validator: (l) => l == null ? !0 : typeof l != "number" || Number.isNaN(l) ? (console.info("El valor de maxLength debe ser un número"), !1) : l < 0 ? (console.info("El valor de maxLength no puede ser menor a 0"), !1) : !0
66
66
  },
67
67
  /**
68
68
  * Número mínimo de caracteres permitidos en el campo de entrada.
@@ -71,7 +71,7 @@ import './style/textField.css';const pe = { class: "rds-e-textfield__input-conta
71
71
  minLength: {
72
72
  type: Number,
73
73
  required: !1,
74
- validator: (t) => t == null ? !0 : typeof t != "number" || Number.isNaN(t) ? (console.info("El valor de minLength debe ser un número"), !1) : t < 0 ? (console.info("El valor de minLength no puede ser menor a 0"), !1) : !0
74
+ validator: (l) => l == null ? !0 : typeof l != "number" || Number.isNaN(l) ? (console.info("El valor de minLength debe ser un número"), !1) : l < 0 ? (console.info("El valor de minLength no puede ser menor a 0"), !1) : !0
75
75
  },
76
76
  /**
77
77
  * Tipo del input HTML. Por defecto 'text'.
@@ -80,9 +80,9 @@ import './style/textField.css';const pe = { class: "rds-e-textfield__input-conta
80
80
  type: {
81
81
  type: String,
82
82
  default: "text",
83
- validator: (t) => {
84
- const r = ["text", "number", "password", "email", "tel", "url"], i = r.includes(t);
85
- return i || console.warn(`[RDSTextfield]: El valor de la prop 'type' debe ser uno de: ${r.join(", ")}. Valor recibido: ${t}`), i;
83
+ validator: (l) => {
84
+ const r = ["text", "number", "password", "email", "tel", "url"], i = r.includes(l);
85
+ return i || console.warn(`[RDSTextfield]: El valor de la prop 'type' debe ser uno de: ${r.join(", ")}. Valor recibido: ${l}`), i;
86
86
  }
87
87
  },
88
88
  /**
@@ -150,90 +150,97 @@ import './style/textField.css';const pe = { class: "rds-e-textfield__input-conta
150
150
  autocomplete: {
151
151
  type: String,
152
152
  default: "off",
153
- validator: (t, r) => {
153
+ validator: (l, r) => {
154
154
  const i = ["new-password", "current-password", "off"];
155
- return (r.password || r.type === "password") && !i.includes(t) ? (console.info(`[RDSTextfield]: El valor de autocomplete para un campo de contraseña debe ser uno de los siguientes: ${i.join(", ")}`), !1) : !0;
155
+ return (r.password || r.type === "password") && !i.includes(l) ? (console.info(`[RDSTextfield]: El valor de autocomplete para un campo de contraseña debe ser uno de los siguientes: ${i.join(", ")}`), !1) : !0;
156
156
  }
157
157
  }
158
158
  },
159
159
  emits: ["update:modelValue", "clear", "keydown", "keyup", "keypress", "change"],
160
- setup(t, { expose: r, emit: i }) {
161
- const n = t, u = i, {
162
- type: d,
163
- label: P,
160
+ setup(l, { expose: r, emit: i }) {
161
+ const o = l, u = i, {
162
+ type: v,
163
+ label: O,
164
164
  disabled: B,
165
- modelValue: v,
166
- icon: j,
167
- rightIcon: W,
168
- helper: O,
165
+ modelValue: x,
166
+ icon: U,
167
+ rightIcon: z,
168
+ helper: H,
169
169
  error: C,
170
- helperText: U,
171
- clearable: z,
170
+ helperText: G,
171
+ clearable: J,
172
172
  password: b,
173
- autocomplete: H,
174
- fullWidth: G
175
- } = se(n), l = c(null), m = c(!0), h = c(!1), w = c(!1), S = c(!1), J = ce(), k = c(""), y = c(!1), F = g(() => n.id || `text-field-${J}`), Q = g(() => b.value ? m.value ? "text" : "password" : ["text", "number", "password", "email", "tel", "url"].includes(d.value) ? d.value : "text"), X = g(() => {
176
- if (b.value || d.value === "password")
177
- return H.value;
178
- }), Y = (e) => {
179
- const a = e.target;
180
- let s = a.value;
181
- if (d.value === "number") {
182
- const N = a.value !== "" || a.selectionStart !== null && a.selectionStart > 0 || a.validity.badInput;
183
- y.value = N;
173
+ autocomplete: Q,
174
+ fullWidth: X
175
+ } = ue(o), a = c(null), p = c(!0), d = c(!1), w = c(!1), S = c(!1), Y = me(), h = c(""), n = c(!1), I = () => {
176
+ if (a.value)
177
+ if (v.value === "number") {
178
+ const e = a.value, t = e.value !== "" || e.selectionStart !== null && e.selectionStart > 0 || e.validity.badInput;
179
+ n.value = t;
180
+ } else
181
+ n.value = a.value.value !== "";
182
+ }, $ = y(() => o.id || `text-field-${Y}`), Z = y(() => b.value ? p.value ? "text" : "password" : ["text", "number", "password", "email", "tel", "url"].includes(v.value) ? v.value : "text"), ee = y(() => {
183
+ if (b.value || v.value === "password")
184
+ return Q.value;
185
+ }), te = (e) => {
186
+ const t = e.target, K = t.value.trim();
187
+ let k = t.value;
188
+ if (v.value === "number") {
189
+ const N = t.value !== "" || t.selectionStart !== null && t.selectionStart > 0 || t.validity.badInput;
190
+ n.value = N;
184
191
  } else
185
- y.value = a.value !== "";
186
- if (d.value === "number")
187
- if (a.value.trim() === "")
188
- s = null;
192
+ n.value = t.value !== "";
193
+ if (v.value === "number") {
194
+ if (t.value.trim() === "")
195
+ k = null;
189
196
  else {
190
- const N = Number.parseFloat(a.value);
191
- s = Number.isNaN(N) ? a.value : N;
197
+ const N = Number.parseFloat(t.value);
198
+ k = Number.isNaN(N) ? t.value : N;
192
199
  }
193
- else a.value === "" && v.value === null && (s = null);
194
- u("update:modelValue", s);
195
- }, Z = () => {
200
+ K === "" && !t.validity.badInput && (n.value = !1);
201
+ } else t.value === "" && x.value === null && (k = null);
202
+ u("update:modelValue", k), I();
203
+ }, le = () => {
196
204
  S.value = !0;
197
- }, $ = () => {
198
- if (h.value = !1, w.value = !1, S.value = !1, d.value === "number" && l.value) {
199
- const e = l.value.value !== "" || l.value.selectionStart !== null && l.value.selectionStart > 0 || l.value.validity.badInput;
200
- y.value = e;
201
- }
202
205
  }, D = () => {
203
- h.value = !0, w.value = !S.value, S.value = !1;
204
- }, ee = (e) => {
206
+ var t;
207
+ const e = ((t = a.value) == null ? void 0 : t.value.trim()) || "";
208
+ n.value = e !== "", d.value = !1, w.value = !1, S.value = !1, e === "" && (h.value = ""), I();
209
+ }, R = () => {
210
+ d.value = !0, w.value = !S.value, S.value = !1;
211
+ }, ae = (e) => {
205
212
  u("keydown", e);
206
- }, te = (e) => {
213
+ }, ne = (e) => {
207
214
  u("keyup", e);
208
- }, le = (e) => {
215
+ }, oe = (e) => {
209
216
  u("keypress", e);
210
- }, ae = (e) => {
217
+ }, se = (e) => {
211
218
  u("change", e);
212
- }, ne = g(() => {
219
+ }, re = y(() => {
213
220
  const e = [];
214
- return k.value !== "" && e.push(k.value), (v.value !== null && String(v.value).length > 0 || y.value || h.value) && e.push("rds-e-textfield--filled"), v.value !== null && String(v.value).length > 0 && e.push("rds-e-textfield--filled"), C.value && e.push("rds-e-textfield--error"), B.value && e.push("rds-e-textfield--disabled"), G.value && e.push("rds-e-textfield--full-width"), e.join(" ");
221
+ return h.value && e.push(h.value), (x.value !== null && String(x.value).trim().length > 0 || n.value || d.value) && e.push("rds-e-textfield--filled"), C.value && e.push("rds-e-textfield--error"), B.value && e.push("rds-e-textfield--disabled"), X.value && e.push("rds-e-textfield--full-width"), e.join(" ");
215
222
  });
216
- q(
217
- () => v.value,
223
+ P(
224
+ () => x.value,
218
225
  (e) => {
219
- e !== null && String(e).length > 0 && (k.value = "");
226
+ e !== null && String(e).length > 0 && (h.value = ""), (e === "" || e === null) && !d.value && (n.value = !1);
220
227
  }
221
228
  );
222
- const o = g(() => {
229
+ const s = y(() => {
223
230
  const e = {
224
- name: j.value,
231
+ name: U.value,
225
232
  class: "",
226
233
  events: {
227
234
  click: () => {
228
235
  }
229
236
  }
230
- }, a = {
237
+ }, t = {
231
238
  left: {
232
239
  ...e
233
240
  },
234
241
  right: {
235
242
  ...e,
236
- name: W.value
243
+ name: z.value
237
244
  }
238
245
  };
239
246
  return b.value ? {
@@ -243,13 +250,13 @@ import './style/textField.css';const pe = { class: "rds-e-textfield__input-conta
243
250
  },
244
251
  right: {
245
252
  ...e,
246
- name: m.value ? "eye_open" : "eye_close",
253
+ name: p.value ? "eye_open" : "eye_close",
247
254
  class: "rds-e-textfield__icon--password",
248
255
  events: {
249
- click: () => m.value = !m.value
256
+ click: () => p.value = !p.value
250
257
  }
251
258
  }
252
- } : z.value ? {
259
+ } : J.value ? {
253
260
  left: {
254
261
  ...e
255
262
  },
@@ -259,108 +266,106 @@ import './style/textField.css';const pe = { class: "rds-e-textfield__input-conta
259
266
  class: "rds-e-textfield__icon--clear",
260
267
  events: {
261
268
  click: () => {
262
- u("update:modelValue", ""), u("clear");
269
+ u("update:modelValue", ""), a.value && (a.value.value = ""), d.value = !1, n.value = !1, a.value && a.value.blur(), u("clear");
263
270
  }
264
271
  }
265
272
  }
266
- } : a;
273
+ } : t;
267
274
  });
268
- q(
275
+ P(
269
276
  b,
270
- (e) => m.value = !e,
277
+ (e) => p.value = !e,
271
278
  { immediate: !0 }
272
279
  );
273
- const R = (e) => {
274
- const a = fe.includes(e);
275
- return a || console.warn(`[RDSTextfield]: El icono "${e}" no es un icono válido.`), a;
276
- }, M = (e) => {
277
- var s;
278
- ((s = l.value) == null ? void 0 : s.matches(":-webkit-autofill")) && e.animationName.startsWith("onAutoFillStart") && (k.value = "rds-e-textfield--filled");
280
+ const M = (e) => {
281
+ const t = pe.includes(e);
282
+ return t || console.warn(`[RDSTextfield]: El icono "${e}" no es un icono válido.`), t;
283
+ }, q = (e) => {
284
+ const t = a.value;
285
+ if (!t) return;
286
+ t.matches(":-webkit-autofill") && e.animationName.startsWith("onAutoFillStart") && t.value.trim().length > 0 && (h.value = "rds-e-textfield--filled", n.value = !0);
279
287
  };
280
- return re(() => {
281
- if (l.value && (l.value.addEventListener("animationstart", M), d.value === "number")) {
282
- const e = l.value.value !== "" || l.value.selectionStart !== null && l.value.selectionStart > 0 || l.value.validity.badInput;
283
- y.value = e;
284
- }
285
- }), ie(() => {
286
- l.value && l.value.removeEventListener("animationstart", M);
288
+ return de(() => {
289
+ a.value && (a.value.addEventListener("animationstart", q), I());
290
+ }), ce(() => {
291
+ a.value && a.value.removeEventListener("animationstart", q);
287
292
  }), r({
288
293
  focus: () => {
289
- l.value && (l.value.focus(), D());
294
+ a.value && (a.value.focus(), R());
290
295
  },
291
296
  blur: () => {
292
- l.value && (l.value.blur(), $());
297
+ a.value && (a.value.blur(), D());
293
298
  }
294
- }), (e, a) => (p(), I("div", {
295
- class: V(["rds-e-textfield", ne.value])
299
+ }), (e, t) => (m(), L("div", {
300
+ class: V(["rds-e-textfield", re.value])
296
301
  }, [
297
- _("div", {
302
+ g("div", {
298
303
  class: V(["rds-e-textfield__container", {
299
304
  "rds-e-textfield__container--keyboard-focus": w.value,
300
- "rds-e-textfield__container--active": h.value && !w.value
305
+ "rds-e-textfield__container--active": d.value && !w.value
301
306
  }]),
302
- onMousedown: Z
307
+ onMousedown: le
303
308
  }, [
304
- L(e.$slots, "left-icon", {}, () => [
305
- t.loading ? (p(), T(E, {
309
+ T(e.$slots, "left-icon", {}, () => [
310
+ l.loading ? (m(), E(F, {
306
311
  key: 0,
307
312
  name: "loading",
308
313
  class: "rds-e-textfield__icon--loading"
309
- })) : x("", !0),
310
- o.value.left.name && R(o.value.left.name) && !t.loading ? (p(), T(E, A({
314
+ })) : _("", !0),
315
+ s.value.left.name && M(s.value.left.name) && !l.loading ? (m(), E(F, j({
311
316
  key: 1,
312
- class: ["rds-e-textfield__icon rds-e-textfield__icon--left", { "rds-e-textfield__icon--hidden": h.value }],
317
+ class: ["rds-e-textfield__icon rds-e-textfield__icon--left", { "rds-e-textfield__icon--hidden": d.value }],
313
318
  "aria-hidden": "true"
314
- }, o.value.left, ue(o.value.left.events)), null, 16, ["class"])) : x("", !0)
319
+ }, s.value.left, fe(s.value.left.events)), null, 16, ["class"])) : _("", !0)
315
320
  ], !0),
316
- _("div", pe, [
317
- _("input", {
318
- id: F.value,
321
+ g("div", ye, [
322
+ g("input", {
323
+ id: $.value,
319
324
  ref_key: "input",
320
- ref: l,
321
- type: Q.value,
325
+ ref: a,
326
+ type: Z.value,
322
327
  class: "rds-e-textfield__input",
323
- maxlength: n.type === "number" ? void 0 : n.maxLength,
324
- minlength: n.type === "number" ? void 0 : n.minLength,
328
+ maxlength: o.type === "number" ? void 0 : o.maxLength,
329
+ minlength: o.type === "number" ? void 0 : o.minLength,
325
330
  disabled: f(B),
326
- value: n.modelValue === null ? "" : n.modelValue,
327
- autocomplete: X.value,
328
- readonly: t.readonly,
329
- onInput: Y,
330
- onBlur: $,
331
- onFocus: D,
332
- onKeydown: ee,
333
- onKeyup: te,
334
- onKeypress: le,
335
- onChange: ae
336
- }, null, 40, me),
337
- _("label", {
338
- for: F.value,
331
+ value: o.modelValue === null ? "" : o.modelValue,
332
+ autocomplete: ee.value,
333
+ readonly: l.readonly,
334
+ onInput: te,
335
+ onBlur: D,
336
+ onFocus: R,
337
+ onKeydown: ae,
338
+ onKeyup: ne,
339
+ onKeypress: oe,
340
+ onChange: se
341
+ }, null, 40, ge),
342
+ g("label", {
343
+ for: $.value,
339
344
  class: V(["rds-e-textfield__label", f(B) ? "rds-e-textfield__label--disabled" : ""])
340
- }, K(f(P)), 11, he)
345
+ }, W(f(O)), 11, _e)
341
346
  ]),
342
- o.value.right.name || e.$slots["right-icon"] ? (p(), I("span", ye, [
343
- L(e.$slots, "right-icon", {}, () => [
344
- o.value.right.name && R(o.value.right.name) ? (p(), T(E, A({
347
+ s.value.right.name || e.$slots["right-icon"] ? (m(), L("span", xe, [
348
+ T(e.$slots, "right-icon", {}, () => [
349
+ s.value.right.name && M(s.value.right.name) ? (m(), E(F, j({
345
350
  key: 0,
346
351
  "aria-hidden": "true",
347
352
  class: "rds-e-textfield__icon rds-e-textfield__icon--right"
348
- }, o.value.right, {
349
- onClick: de(o.value.right.events.click, ["stop"])
350
- }), null, 16, ["onClick"])) : x("", !0)
353
+ }, s.value.right, {
354
+ onClick: ve(s.value.right.events.click, ["stop"])
355
+ }), null, 16, ["onClick"])) : _("", !0)
351
356
  ], !0)
352
- ])) : x("", !0)
357
+ ])) : _("", !0)
353
358
  ], 34),
354
- f(O) || f(C) ? (p(), I("div", ge, [
355
- L(e.$slots, "helper-text", {}, () => [
356
- _("span", {
359
+ f(H) || f(C) ? (m(), L("div", be, [
360
+ T(e.$slots, "helper-text", {}, () => [
361
+ g("span", {
357
362
  class: V(f(C) ? "rds-e-textfield__helper--error" : "")
358
- }, K(f(U)), 3)
363
+ }, W(f(G)), 3)
359
364
  ], !0)
360
- ])) : x("", !0)
365
+ ])) : _("", !0)
361
366
  ], 2));
362
367
  }
363
- }), ke = /* @__PURE__ */ ve(_e, [["__scopeId", "data-v-a299198c"]]);
368
+ }), Be = /* @__PURE__ */ he(we, [["__scopeId", "data-v-f6902be3"]]);
364
369
  export {
365
- ke as default
370
+ Be as default
366
371
  };
@@ -1,6 +1,6 @@
1
- import { defineComponent as T, toRefs as c, ref as E, onMounted as L, createElementBlock as y, openBlock as B, normalizeClass as r, createElementVNode as p, unref as u, toDisplayString as f } from "vue";
2
- import { _ as F } from "./_plugin-vue_export-helper-CHgC5LLL.js";
3
- import './style/toggle.css';const I = ["id"], R = ["id"], _ = ["id"], G = /* @__PURE__ */ T({
1
+ import { defineComponent as T, toRefs as E, ref as L, onMounted as y, createElementBlock as B, openBlock as F, normalizeClass as g, createElementVNode as m, unref as u, toDisplayString as v } from "vue";
2
+ import { _ as I } from "./_plugin-vue_export-helper-CHgC5LLL.js";
3
+ import './style/toggle.css';const R = ["id"], G = ["id"], H = ["id"], W = /* @__PURE__ */ T({
4
4
  __name: "toggle",
5
5
  props: {
6
6
  small: { type: Boolean },
@@ -14,18 +14,18 @@ import './style/toggle.css';const I = ["id"], R = ["id"], _ = ["id"], G = /* @__
14
14
  id: {}
15
15
  },
16
16
  emits: ["update:modelValue"],
17
- setup(m, { emit: v }) {
18
- const b = m, i = v, { modelValue: l, switchType: s, valueLeft: d, valueRight: o } = c(b), t = {
17
+ setup(e, { emit: r }) {
18
+ const b = e, d = r, { modelValue: t, switchType: i, valueLeft: n, valueRight: a } = E(b), l = {
19
19
  LEFT: "left",
20
20
  RIGHT: "right"
21
- }, a = E(t.LEFT), g = (e) => {
22
- i("update:modelValue", e);
21
+ }, o = L(l.LEFT), c = (f) => {
22
+ d("update:modelValue", f);
23
23
  };
24
- return L(() => {
25
- s != null && s.value ? (i("update:modelValue", l == null ? void 0 : l.value), a.value = l != null && l.value ? t.RIGHT : t.LEFT) : (l == null ? void 0 : l.value) === (o == null ? void 0 : o.value) ? (i("update:modelValue", o == null ? void 0 : o.value), a.value = t.RIGHT) : (i("update:modelValue", d == null ? void 0 : d.value), a.value = t.LEFT);
26
- }), (e, n) => (B(), y("div", {
24
+ return y(() => {
25
+ i != null && i.value ? (d("update:modelValue", t == null ? void 0 : t.value), o.value = t != null && t.value ? l.RIGHT : l.LEFT) : (t == null ? void 0 : t.value) === (a == null ? void 0 : a.value) ? (d("update:modelValue", a == null ? void 0 : a.value), o.value = l.RIGHT) : (d("update:modelValue", n == null ? void 0 : n.value), o.value = l.LEFT);
26
+ }), (f, s) => (F(), B("div", {
27
27
  id: e.id,
28
- class: r(["rds-e-toggle", [
28
+ class: g(["rds-e-toggle", [
29
29
  {
30
30
  "rds-e-toggle--small-full-width": e.small && e.fullWidth,
31
31
  "rds-e-toggle--full-width": e.fullWidth && !e.small,
@@ -34,25 +34,25 @@ import './style/toggle.css';const I = ["id"], R = ["id"], _ = ["id"], G = /* @__
34
34
  }
35
35
  ]])
36
36
  }, [
37
- p("button", {
37
+ m("button", {
38
38
  id: e.id ? `${e.id}-left` : void 0,
39
- class: r(["rds-e-toggle__tab", {
40
- "rds-e-toggle__tab--active": a.value === t.LEFT
39
+ class: g(["rds-e-toggle__tab", {
40
+ "rds-e-toggle__tab--active": o.value === l.LEFT
41
41
  }]),
42
42
  type: "button",
43
- onClick: n[0] || (n[0] = (h) => (g(u(s) ? !0 : u(d)), a.value = t.LEFT))
44
- }, f(e.labelLeft), 11, R),
45
- p("button", {
43
+ onClick: s[0] || (s[0] = (h) => (c(u(i) ? !0 : u(n)), o.value = l.LEFT))
44
+ }, v(e.labelLeft), 11, G),
45
+ m("button", {
46
46
  id: e.id ? `${e.id}-right` : void 0,
47
- class: r(["rds-e-toggle__tab", {
48
- "rds-e-toggle__tab--active": a.value === t.RIGHT
47
+ class: g(["rds-e-toggle__tab", {
48
+ "rds-e-toggle__tab--active": o.value === l.RIGHT
49
49
  }]),
50
50
  type: "button",
51
- onClick: n[1] || (n[1] = (h) => (g(u(s) ? !1 : u(o)), a.value = t.RIGHT))
52
- }, f(e.labelRight), 11, _)
53
- ], 10, I));
51
+ onClick: s[1] || (s[1] = (h) => (c(u(i) ? !1 : u(a)), o.value = l.RIGHT))
52
+ }, v(e.labelRight), 11, H)
53
+ ], 10, R));
54
54
  }
55
- }), k = /* @__PURE__ */ F(G, [["__scopeId", "data-v-be1c5818"]]);
55
+ }), C = /* @__PURE__ */ I(W, [["__scopeId", "data-v-be1c5818"]]);
56
56
  export {
57
- k as default
57
+ C as default
58
58
  };
@@ -1,6 +1,6 @@
1
1
  import { defineComponent as q, toRefs as G, ref as u, computed as T, onBeforeUnmount as J, createElementBlock as x, openBlock as m, createElementVNode as v, createBlock as K, renderSlot as D, Teleport as Q, normalizeClass as N, createCommentVNode as O, unref as A, createVNode as Z, toDisplayString as E, createTextVNode as ee, nextTick as te } from "vue";
2
- import { a as oe, o as le, f as ae, s as ie, b as se, c as re, d as ne } from "./floating-ui.vue-oA1DfKeS.js";
3
- import { R as ue } from "./icon-svg-C8XeOnqu.js";
2
+ import { a as oe, o as le, f as ae, s as ie, b as se, c as re, d as ne } from "./floating-ui.vue-DHEoOe5S.js";
3
+ import { R as ue } from "./icon-svg-K8-vLJgV.js";
4
4
  import { _ as de } from "./_plugin-vue_export-helper-CHgC5LLL.js";
5
5
  import './style/tooltip.css';const ce = ["id"], fe = {
6
6
  key: 0,