energy-components 1.14.1 → 1.15.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 (113) hide show
  1. package/dist/components/accordion.es.js +30 -27
  2. package/dist/components/actionButton.es.js +56 -11
  3. package/dist/components/avatar.es.js +24 -16
  4. package/dist/components/breadcrumbs.es.js +37 -29
  5. package/dist/components/button.es.js +31 -22
  6. package/dist/components/card.es.js +17 -9
  7. package/dist/components/checkbox.es.js +67 -56
  8. package/dist/components/collapsable.es.js +1 -1
  9. package/dist/components/{collapsable.scss_vue_type_style_index_0_src_true_lang-DfOWp1XD.js → collapsable.scss_vue_type_style_index_0_src_true_lang-Bi5q6Y3n.js} +1 -1
  10. package/dist/components/directAccess.es.js +26 -18
  11. package/dist/components/dragAndDrop.es.js +1 -1
  12. package/dist/components/dropdown.es.js +27 -27
  13. package/dist/components/fileUploadItem.es.js +23 -21
  14. package/dist/components/filterChip.es.js +22 -14
  15. package/dist/components/filterTag.es.js +27 -19
  16. package/dist/components/floating-ui.vue-7LKzPqHI.js +1148 -0
  17. package/dist/components/floatingActionButton.es.js +19 -11
  18. package/dist/components/{icon-svg-DuzOdbk1.js → icon-svg-BU0OQFKH.js} +990 -742
  19. package/dist/components/iconList.es.js +1 -1
  20. package/dist/components/iconSvg.es.js +1 -1
  21. package/dist/components/index.es.js +83 -77
  22. package/dist/components/indicator.es.js +37 -29
  23. package/dist/components/infoBox.es.js +47 -39
  24. package/dist/components/link.es.js +22 -13
  25. package/dist/components/loader.es.js +22 -21
  26. package/dist/components/modal.es.js +37 -28
  27. package/dist/components/overlay.es.js +21 -11
  28. package/dist/components/pagination.es.js +164 -109
  29. package/dist/components/persistentToast.es.js +32 -24
  30. package/dist/components/popover.es.js +166 -0
  31. package/dist/components/progressBar.es.js +30 -22
  32. package/dist/components/quantitySelector.es.js +60 -48
  33. package/dist/components/radioButton.es.js +1 -1
  34. package/dist/components/selectionChip.es.js +15 -7
  35. package/dist/components/sidedrawer.es.js +1 -1
  36. package/dist/components/snackBar.es.js +131 -0
  37. package/dist/components/style/accordion.css +1 -1
  38. package/dist/components/style/actionButton.css +1 -1
  39. package/dist/components/style/avatar.css +1 -1
  40. package/dist/components/style/breadcrumbs.css +1 -1
  41. package/dist/components/style/button.css +1 -1
  42. package/dist/components/style/card.css +1 -1
  43. package/dist/components/style/checkbox.css +1 -1
  44. package/dist/components/style/directAccess.css +1 -1
  45. package/dist/components/style/fileUploadItem.css +1 -1
  46. package/dist/components/style/filterChip.css +1 -1
  47. package/dist/components/style/filterTag.css +1 -1
  48. package/dist/components/style/floatingActionButton.css +1 -1
  49. package/dist/components/style/icon-svg.css +1 -1
  50. package/dist/components/style/indicator.css +1 -1
  51. package/dist/components/style/infoBox.css +1 -1
  52. package/dist/components/style/link.css +1 -1
  53. package/dist/components/style/loader.css +1 -1
  54. package/dist/components/style/modal.css +1 -1
  55. package/dist/components/style/overlay.css +1 -1
  56. package/dist/components/style/pagination.css +1 -1
  57. package/dist/components/style/persistentToast.css +1 -1
  58. package/dist/components/style/popover.css +1 -0
  59. package/dist/components/style/progressBar.css +1 -1
  60. package/dist/components/style/quantitySelector.css +1 -1
  61. package/dist/components/style/selectionChip.css +1 -1
  62. package/dist/components/style/snackBar.css +1 -0
  63. package/dist/components/style/tabBar.css +1 -1
  64. package/dist/components/style/tag.css +1 -1
  65. package/dist/components/style/textArea.css +1 -1
  66. package/dist/components/style/toggle.css +1 -1
  67. package/dist/components/style/tooltip.css +1 -1
  68. package/dist/components/switch.es.js +1 -1
  69. package/dist/components/tabBar.es.js +23 -15
  70. package/dist/components/tableslotedcomponent.es.js +1 -1
  71. package/dist/components/tag.es.js +31 -23
  72. package/dist/components/textArea.es.js +57 -57
  73. package/dist/components/textField.es.js +1 -1
  74. package/dist/components/toggle.es.js +20 -16
  75. package/dist/components/tooltip.es.js +71 -1019
  76. package/dist/energy-components.es.js +6825 -5824
  77. package/dist/energy-components.umd.js +2 -2
  78. package/dist/style.css +1 -1
  79. package/dist/types/src/components/buttons/action-button/action-button.vue.d.ts +47 -0
  80. package/dist/types/src/components/buttons/button/button.vue.d.ts +15 -0
  81. package/dist/types/src/components/buttons/floating-action-button/floating-action-button.vue.d.ts +15 -0
  82. package/dist/types/src/components/content/avatar/avatar.vue.d.ts +15 -0
  83. package/dist/types/src/components/content/card/card.vue.d.ts +15 -0
  84. package/dist/types/src/components/content/collapsable/collapsable.vue.d.ts +1 -1
  85. package/dist/types/src/components/content/tag/tag.vue.d.ts +15 -0
  86. package/dist/types/src/components/feedback/indicator/indicator.vue.d.ts +15 -0
  87. package/dist/types/src/components/feedback/info-box/info-box.vue.d.ts +15 -0
  88. package/dist/types/src/components/feedback/loader/loader.vue.d.ts +1 -1
  89. package/dist/types/src/components/feedback/persistent-toast/persistent-toast.vue.d.ts +15 -0
  90. package/dist/types/src/components/feedback/progress-bar/progress-bar.vue.d.ts +15 -0
  91. package/dist/types/src/components/feedback/snack-bar/snack-bar.vue.d.ts +180 -0
  92. package/dist/types/src/components/icon-svg/icon-svg.vue.d.ts +15 -0
  93. package/dist/types/src/components/index.d.ts +2 -0
  94. package/dist/types/src/components/input/checkbox/checkbox.vue.d.ts +24 -7
  95. package/dist/types/src/components/input/drag-and-drop/drag-and-drop.vue.d.ts +1 -1
  96. package/dist/types/src/components/input/file-upload-item/file-upload-item.vue.d.ts +1 -1
  97. package/dist/types/src/components/input/filter-chip/filter-chip.vue.d.ts +15 -0
  98. package/dist/types/src/components/input/filter-tag/filter-tag.vue.d.ts +15 -0
  99. package/dist/types/src/components/input/quantity-selector/quantity-selector.vue.d.ts +15 -0
  100. package/dist/types/src/components/input/selection-chip/selection-chip.vue.d.ts +15 -0
  101. package/dist/types/src/components/input/switch/switch.vue.d.ts +1 -1
  102. package/dist/types/src/components/input/toggle/toggle.vue.d.ts +4 -0
  103. package/dist/types/src/components/navigation/breadcrumbs/breadcrumbs.vue.d.ts +15 -0
  104. package/dist/types/src/components/navigation/direct-access/direct-access.vue.d.ts +15 -0
  105. package/dist/types/src/components/navigation/link/link.vue.d.ts +15 -0
  106. package/dist/types/src/components/navigation/pagination/pagination.vue.d.ts +47 -0
  107. package/dist/types/src/components/navigation/tab-bar/tab-bar.vue.d.ts +15 -0
  108. package/dist/types/src/components/overlay/modal/modal.vue.d.ts +15 -0
  109. package/dist/types/src/components/overlay/overlay/overlay.vue.d.ts +15 -0
  110. package/dist/types/src/components/overlay/popover/popover.vue.d.ts +35 -0
  111. package/dist/types/src/components/overlay/tooltip/tooltip.vue.d.ts +15 -0
  112. package/dist/types/tsconfig.tsbuildinfo +1 -1
  113. package/package.json +2 -2
@@ -1,7 +1,7 @@
1
- import { defineComponent as y, toRefs as $, computed as u, createElementBlock as x, openBlock as o, normalizeClass as l, createBlock as p, createCommentVNode as d, createElementVNode as S, unref as t, toDisplayString as b } from "vue";
2
- import { R as f } from "./icon-svg-DuzOdbk1.js";
3
- import { _ as B } from "./_plugin-vue_export-helper-CHgC5LLL.js";
4
- import './style/tag.css';const k = { class: "rds-caption-tag" }, C = /* @__PURE__ */ y({
1
+ import { defineComponent as y, toRefs as S, computed as u, createElementBlock as $, openBlock as o, normalizeClass as l, createBlock as d, createCommentVNode as p, createElementVNode as x, unref as s, toDisplayString as B } from "vue";
2
+ import { R as f } from "./icon-svg-BU0OQFKH.js";
3
+ import { _ as b } from "./_plugin-vue_export-helper-CHgC5LLL.js";
4
+ import './style/tag.css';const k = ["id"], C = { class: "rds-caption-tag" }, N = /* @__PURE__ */ y({
5
5
  __name: "tag",
6
6
  props: {
7
7
  /**
@@ -26,7 +26,7 @@ import './style/tag.css';const k = { class: "rds-caption-tag" }, C = /* @__PURE_
26
26
  type: {
27
27
  type: String,
28
28
  default: "default",
29
- validator: (s) => ["default", "information", "success", "error", "warning", "promo"].includes(s)
29
+ validator: (t) => ["default", "information", "success", "error", "warning", "promo"].includes(t)
30
30
  },
31
31
  /**
32
32
  * Define si el tag tiene una acción asociada.
@@ -50,42 +50,50 @@ import './style/tag.css';const k = { class: "rds-caption-tag" }, C = /* @__PURE_
50
50
  small: {
51
51
  type: Boolean,
52
52
  default: !1
53
+ },
54
+ /**
55
+ * ID del tag para testing
56
+ */
57
+ id: {
58
+ type: String,
59
+ default: void 0
53
60
  }
54
61
  },
55
- setup(s) {
56
- const m = s, {
62
+ setup(t) {
63
+ const m = t, {
57
64
  type: r,
58
- actionable: c,
65
+ actionable: i,
59
66
  icon: n,
60
67
  text: _,
61
68
  inverse: g,
62
69
  small: v
63
- } = $(m), h = u(() => {
70
+ } = S(m), h = u(() => {
64
71
  const a = "rds-e-tag", e = [];
65
- return g.value && e.push(`${a}--inverse`), c.value && e.push(`${a}--actionable`), n.value && e.push(`${a}--icon`), v.value && e.push(`${a}--small`), e.push(`${a}--${r.value}`), e.join(" ");
66
- }), i = u(() => {
72
+ return g.value && e.push(`${a}--inverse`), i.value && e.push(`${a}--actionable`), n.value && e.push(`${a}--icon`), v.value && e.push(`${a}--small`), e.push(`${a}--${r.value}`), e.join(" ");
73
+ }), c = u(() => {
67
74
  const a = "rds-e-tag_icon", e = [];
68
75
  return e.push(`${a}--${r.value}`), e.join(" ");
69
76
  });
70
- return (a, e) => (o(), x("div", {
77
+ return (a, e) => (o(), $("div", {
78
+ id: t.id,
71
79
  class: l(["rds-e-tag rds-e-caption-tag", h.value])
72
80
  }, [
73
- t(n) ? (o(), p(f, {
81
+ s(n) ? (o(), d(f, {
74
82
  key: 0,
75
- name: t(n),
76
- class: l(["rds-e-tag__icon", i.value]),
83
+ name: s(n),
84
+ class: l(["rds-e-tag__icon", c.value]),
77
85
  "aria-hidden": "true"
78
- }, null, 8, ["name", "class"])) : d("", !0),
79
- S("span", k, b(t(_)), 1),
80
- t(c) ? (o(), p(f, {
86
+ }, null, 8, ["name", "class"])) : p("", !0),
87
+ x("span", C, B(s(_)), 1),
88
+ s(i) ? (o(), d(f, {
81
89
  key: 1,
82
90
  name: "arrow_right",
83
- class: l(["rds-e-tag__icon-actionable", i.value]),
91
+ class: l(["rds-e-tag__icon-actionable", c.value]),
84
92
  "aria-hidden": "true"
85
- }, null, 8, ["class"])) : d("", !0)
86
- ], 2));
93
+ }, null, 8, ["class"])) : p("", !0)
94
+ ], 10, k));
87
95
  }
88
- }), j = /* @__PURE__ */ B(C, [["__scopeId", "data-v-5e8bf5cb"]]);
96
+ }), w = /* @__PURE__ */ b(N, [["__scopeId", "data-v-ac2ecb64"]]);
89
97
  export {
90
- j as default
98
+ w as default
91
99
  };
@@ -1,10 +1,10 @@
1
- import { defineComponent as Q, mergeModels as W, useModel as X, toRefs as Y, ref as k, computed as o, createElementBlock as h, openBlock as s, normalizeClass as u, createElementVNode as r, withDirectives as Z, unref as e, vModelText as ee, renderSlot as S, createTextVNode as te, createBlock as T, createCommentVNode as i, mergeProps as $, toHandlers as A, toDisplayString as d } from "vue";
2
- import { R as F } from "./icon-svg-DuzOdbk1.js";
1
+ import { defineComponent as Q, mergeModels as W, useModel as X, toRefs as Y, ref as k, computed as s, createElementBlock as f, openBlock as o, normalizeClass as u, createElementVNode as r, withDirectives as Z, unref as e, vModelText as ee, renderSlot as S, createTextVNode as te, createBlock as z, createCommentVNode as i, mergeProps as F, toHandlers as T, toDisplayString as _ } from "vue";
2
+ import { R as A } from "./icon-svg-BU0OQFKH.js";
3
3
  import { _ as ae } from "./_plugin-vue_export-helper-CHgC5LLL.js";
4
- import './style/textArea.css';function V(t, g = !0, c = !0) {
5
- return g && !t.trim() ? (console.warn("Advertencia: El valor no puede estar vacío"), !1) : c && !/^[\w\-:]+$/.test(t) ? (console.warn("Advertencia: El valor contiene caracteres inválidos"), !1) : !0;
4
+ import './style/textArea.css';function V(t, p = !0, d = !0) {
5
+ return p && !t.trim() ? (console.warn("Advertencia: El valor no puede estar vacío"), !1) : d && !/^[\w\s\u00C0-\u017F\-:.,;()¿?¡!%"'$€]+$/.test(t) ? (console.warn("Advertencia: El valor contiene caracteres inválidos"), !1) : !0;
6
6
  }
7
- const re = { class: "rds-e-textarea__input-container" }, le = ["id", "name", "maxlength", "minlength", "rows", "disabled"], ne = ["for"], se = { key: 0 }, oe = { key: 0 }, ue = { key: 1 }, ie = { key: 0 }, de = /* @__PURE__ */ Q({
7
+ const re = { class: "rds-e-textarea__input-container" }, le = ["id", "name", "maxlength", "minlength", "rows", "disabled"], ne = ["for"], oe = { key: 0 }, se = { key: 0 }, ue = { key: 1 }, ie = { key: 0 }, de = /* @__PURE__ */ Q({
8
8
  __name: "text-area",
9
9
  props: /* @__PURE__ */ W({
10
10
  /**
@@ -136,34 +136,34 @@ const re = { class: "rds-e-textarea__input-container" }, le = ["id", "name", "ma
136
136
  }),
137
137
  emits: ["update:modelValue"],
138
138
  setup(t) {
139
- const g = t, c = X(t, "modelValue"), {
139
+ const p = t, d = X(t, "modelValue"), {
140
140
  label: B,
141
- id: M,
142
- disabled: x,
143
- maxlength: m,
144
- minlength: y,
145
- modelValue: v,
146
- icon: R,
147
- rightIcon: E,
148
- helper: z,
149
- error: b,
141
+ id: E,
142
+ disabled: g,
143
+ maxlength: x,
144
+ minlength: C,
145
+ modelValue: c,
146
+ icon: H,
147
+ rightIcon: M,
148
+ helper: R,
149
+ error: y,
150
150
  helperText: P,
151
- clearable: w,
152
- lengthError: j
153
- } = Y(g), f = k(!1), _ = k(!1), p = k(!1), H = () => {
154
- p.value = !0;
151
+ clearable: b,
152
+ lengthError: w
153
+ } = Y(p), v = k(!1), m = k(!1), h = k(!1), j = () => {
154
+ h.value = !0;
155
155
  }, K = () => {
156
- f.value = !1, _.value = !1, p.value = !1;
156
+ v.value = !1, m.value = !1, h.value = !1;
157
157
  }, U = () => {
158
- f.value = !0, _.value = !p.value, p.value = !1;
159
- }, N = o(() => v.value.length === m.value), C = o(() => v.value.length === 0 ? !1 : v.value.length < y.value), I = o(() => j.value && (N.value || C.value)), G = o(() => {
158
+ v.value = !0, m.value = !h.value, h.value = !1;
159
+ }, N = s(() => c.value.length === x.value), I = s(() => c.value.length === 0 ? !1 : c.value.length < C.value), D = s(() => w.value && (N.value || I.value)), G = s(() => {
160
160
  const a = [];
161
- return v.value && a.push("rds-e-textarea--filled"), b.value && a.push("rds-e-textarea--error"), x.value && a.push("rds-e-textarea--disabled"), I.value && a.push("rds-e-textarea--error"), a.join(" ");
161
+ return c.value && a.push("rds-e-textarea--filled"), y.value && a.push("rds-e-textarea--error"), g.value && a.push("rds-e-textarea--disabled"), D.value && a.push("rds-e-textarea--error"), a.join(" ");
162
162
  }), J = () => {
163
- c.value = "";
164
- }, l = o(() => {
163
+ d.value = "";
164
+ }, l = s(() => {
165
165
  const a = {
166
- name: R.value,
166
+ name: H.value,
167
167
  class: "",
168
168
  events: {
169
169
  click: () => {
@@ -171,9 +171,9 @@ const re = { class: "rds-e-textarea__input-container" }, le = ["id", "name", "ma
171
171
  }
172
172
  }, n = {
173
173
  left: { ...a },
174
- right: { ...a, name: E.value }
174
+ right: { ...a, name: M.value }
175
175
  };
176
- return w.value && (n.right = {
176
+ return b.value && (n.right = {
177
177
  ...a,
178
178
  name: "close",
179
179
  class: "rds-e-textfield__icon--clear",
@@ -181,34 +181,34 @@ const re = { class: "rds-e-textarea__input-container" }, le = ["id", "name", "ma
181
181
  click: () => J()
182
182
  }
183
183
  }), n;
184
- }), L = o(() => v.value.length);
184
+ }), L = s(() => c.value.length);
185
185
  return (a, n) => {
186
- var D, q;
187
- return s(), h("div", {
186
+ var $, q;
187
+ return o(), f("div", {
188
188
  class: u(["rds-e-textarea", G.value])
189
189
  }, [
190
190
  r("div", {
191
191
  class: u(["rds-e-textarea__container", {
192
- "rds-e-textarea__container--keyboard-focus": _.value,
193
- "rds-e-textarea__container--active": f.value && !_.value
192
+ "rds-e-textarea__container--keyboard-focus": m.value,
193
+ "rds-e-textarea__container--active": v.value && !m.value
194
194
  }]),
195
- onMousedown: H
195
+ onMousedown: j
196
196
  }, [
197
197
  r("div", re, [
198
198
  Z(r("textarea", {
199
- id: (D = e(M)) == null ? void 0 : D.toString(),
200
- "onUpdate:modelValue": n[0] || (n[0] = (O) => c.value = O),
199
+ id: ($ = e(E)) == null ? void 0 : $.toString(),
200
+ "onUpdate:modelValue": n[0] || (n[0] = (O) => d.value = O),
201
201
  type: "text",
202
- class: u(["rds-e-textarea__input", { "rds-e-textarea__input--active": f.value }]),
202
+ class: u(["rds-e-textarea__input", { "rds-e-textarea__input--active": v.value }]),
203
203
  name: t.name,
204
- maxlength: e(m),
205
- minlength: e(y),
204
+ maxlength: e(x),
205
+ minlength: e(C),
206
206
  rows: t.rows,
207
- disabled: e(x),
207
+ disabled: e(g),
208
208
  onBlur: K,
209
209
  onFocus: U
210
210
  }, null, 42, le), [
211
- [ee, c.value]
211
+ [ee, d.value]
212
212
  ]),
213
213
  n[1] || (n[1] = r("div", { class: "rds-e-textarea__resize-handle" }, [
214
214
  r("svg", {
@@ -226,53 +226,53 @@ const re = { class: "rds-e-textarea__input-container" }, le = ["id", "name", "ma
226
226
  ])
227
227
  ], -1)),
228
228
  r("label", {
229
- for: (q = e(M)) == null ? void 0 : q.toString(),
229
+ for: (q = e(E)) == null ? void 0 : q.toString(),
230
230
  class: u(["rds-e-textarea__label", {
231
231
  "rds-e-textarea__label--with-icon": l.value.left.name,
232
- "rds-e-textarea__label--active": f.value
232
+ "rds-e-textarea__label--active": v.value
233
233
  }])
234
234
  }, [
235
235
  S(a.$slots, "left-icon", {}, () => [
236
- l.value.left.name ? (s(), T(F, $({
236
+ l.value.left.name ? (o(), z(A, F({
237
237
  key: 0,
238
238
  class: "rds-e-textarea__icon rds-e-textarea__icon--left",
239
239
  "aria-hidden": "true"
240
- }, l.value.left, A(l.value.left.events)), null, 16)) : i("", !0)
240
+ }, l.value.left, T(l.value.left.events)), null, 16)) : i("", !0)
241
241
  ], !0),
242
- te(" " + d(e(B)), 1)
242
+ te(" " + _(e(B)), 1)
243
243
  ], 10, ne),
244
244
  r("div", {
245
245
  class: u(["rds-e-textarea__counter", {
246
- "rds-e-textarea__counter--disabled": e(x),
247
- "rds-e-textarea__counter--clearable": e(w)
246
+ "rds-e-textarea__counter--disabled": e(g),
247
+ "rds-e-textarea__counter--clearable": e(b)
248
248
  }])
249
249
  }, [
250
- t.counter && !e(E) && !e(w) ? (s(), h("p", se, d(L.value) + "/" + d(e(m)), 1)) : i("", !0),
250
+ t.counter && !e(M) && !e(b) ? (o(), f("p", oe, _(L.value) + "/" + _(e(x)), 1)) : i("", !0),
251
251
  S(a.$slots, "right-icon", {}, () => [
252
- l.value.right.name ? (s(), T(F, $({
252
+ l.value.right.name ? (o(), z(A, F({
253
253
  key: 0,
254
254
  class: "rds-e-textarea__icon rds-e-textarea__icon--right",
255
255
  "aria-hidden": "true"
256
- }, l.value.right, A(l.value.right.events)), null, 16)) : i("", !0)
256
+ }, l.value.right, T(l.value.right.events)), null, 16)) : i("", !0)
257
257
  ], !0)
258
258
  ], 2)
259
259
  ])
260
260
  ], 34),
261
261
  r("ul", {
262
- class: u(["rds-e-textarea__helper", e(b) || I.value ? "rds-e-textarea__helper--error" : ""])
262
+ class: u(["rds-e-textarea__helper", e(y) || D.value ? "rds-e-textarea__helper--error" : ""])
263
263
  }, [
264
- N.value ? (s(), h("li", oe, " Max text length is " + d(e(m)), 1)) : i("", !0),
265
- C.value ? (s(), h("li", ue, " Min text length is " + d(e(y)), 1)) : i("", !0),
264
+ N.value && e(w) ? (o(), f("li", se, " Ha alcanzado el número máximo de carácteres ")) : i("", !0),
265
+ I.value && e(w) ? (o(), f("li", ue, " Ha alcanzado el número mínimo de carácteres ")) : i("", !0),
266
266
  r("li", null, [
267
267
  S(a.$slots, "helper-text", {}, () => [
268
- e(z) || e(b) ? (s(), h("span", ie, d(e(P)), 1)) : i("", !0)
268
+ e(R) || e(y) ? (o(), f("span", ie, _(e(P)), 1)) : i("", !0)
269
269
  ], !0)
270
270
  ])
271
271
  ], 2)
272
272
  ], 2);
273
273
  };
274
274
  }
275
- }), he = /* @__PURE__ */ ae(de, [["__scopeId", "data-v-cdbbf388"]]);
275
+ }), me = /* @__PURE__ */ ae(de, [["__scopeId", "data-v-b6c3c9f8"]]);
276
276
  export {
277
- he as default
277
+ me as default
278
278
  };
@@ -1,6 +1,6 @@
1
1
  import { defineComponent as re, toRefs as ie, ref as f, computed as v, watch as F, onMounted as ue, onBeforeUnmount as de, createElementBlock as V, openBlock as h, normalizeClass as k, createElementVNode as g, createCommentVNode as S, renderSlot as E, createBlock as R, mergeProps as A, toHandlers as ce, unref as d, toDisplayString as M, withModifiers as fe } from "vue";
2
2
  import { g as ve } from "./getInstance-GhoEcxLF.js";
3
- import { R as K, s as pe } from "./icon-svg-DuzOdbk1.js";
3
+ import { R as K, s as pe } from "./icon-svg-BU0OQFKH.js";
4
4
  import { _ as me } from "./_plugin-vue_export-helper-CHgC5LLL.js";
5
5
  import './style/textField.css';const he = { class: "rds-e-textfield__input-container" }, ge = ["id", "type", "maxlength", "minlength", "disabled", "value", "autocomplete", "readonly"], _e = ["for"], ye = {
6
6
  key: 0,
@@ -1,6 +1,6 @@
1
- import { defineComponent as c, toRefs as E, ref as L, onMounted as h, createElementBlock as y, openBlock as B, normalizeClass as r, createElementVNode as p, unref as i, toDisplayString as f } from "vue";
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
2
  import { _ as F } from "./_plugin-vue_export-helper-CHgC5LLL.js";
3
- import './style/toggle.css';const I = /* @__PURE__ */ c({
3
+ import './style/toggle.css';const I = ["id"], R = ["id"], _ = ["id"], G = /* @__PURE__ */ T({
4
4
  __name: "toggle",
5
5
  props: {
6
6
  small: { type: Boolean },
@@ -10,19 +10,21 @@ import './style/toggle.css';const I = /* @__PURE__ */ c({
10
10
  valueLeft: {},
11
11
  valueRight: {},
12
12
  labelLeft: {},
13
- labelRight: {}
13
+ labelRight: {},
14
+ id: {}
14
15
  },
15
16
  emits: ["update:modelValue"],
16
17
  setup(m, { emit: v }) {
17
- const b = m, u = v, { modelValue: l, switchType: s, valueLeft: n, valueRight: o } = E(b), t = {
18
+ const b = m, i = v, { modelValue: l, switchType: s, valueLeft: d, valueRight: o } = c(b), t = {
18
19
  LEFT: "left",
19
20
  RIGHT: "right"
20
- }, a = L(t.LEFT), g = (e) => {
21
- u("update:modelValue", e);
21
+ }, a = E(t.LEFT), g = (e) => {
22
+ i("update:modelValue", e);
22
23
  };
23
- return h(() => {
24
- s != null && s.value ? (u("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) ? (u("update:modelValue", o == null ? void 0 : o.value), a.value = t.RIGHT) : (u("update:modelValue", n == null ? void 0 : n.value), a.value = t.LEFT);
25
- }), (e, d) => (B(), y("div", {
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", {
27
+ id: e.id,
26
28
  class: r(["rds-e-toggle", [
27
29
  {
28
30
  "rds-e-toggle--small-full-width": e.small && e.fullWidth,
@@ -33,22 +35,24 @@ import './style/toggle.css';const I = /* @__PURE__ */ c({
33
35
  ]])
34
36
  }, [
35
37
  p("button", {
38
+ id: e.id ? `${e.id}-left` : void 0,
36
39
  class: r(["rds-e-toggle__tab", {
37
40
  "rds-e-toggle__tab--active": a.value === t.LEFT
38
41
  }]),
39
42
  type: "button",
40
- onClick: d[0] || (d[0] = (T) => (g(i(s) ? !0 : i(n)), a.value = t.LEFT))
41
- }, f(e.labelLeft), 3),
43
+ onClick: n[0] || (n[0] = (h) => (g(u(s) ? !0 : u(d)), a.value = t.LEFT))
44
+ }, f(e.labelLeft), 11, R),
42
45
  p("button", {
46
+ id: e.id ? `${e.id}-right` : void 0,
43
47
  class: r(["rds-e-toggle__tab", {
44
48
  "rds-e-toggle__tab--active": a.value === t.RIGHT
45
49
  }]),
46
50
  type: "button",
47
- onClick: d[1] || (d[1] = (T) => (g(i(s) ? !1 : i(o)), a.value = t.RIGHT))
48
- }, f(e.labelRight), 3)
49
- ], 2));
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));
50
54
  }
51
- }), H = /* @__PURE__ */ F(I, [["__scopeId", "data-v-30b07e72"]]);
55
+ }), k = /* @__PURE__ */ F(G, [["__scopeId", "data-v-be1c5818"]]);
52
56
  export {
53
- H as default
57
+ k as default
54
58
  };