@rocketui/vue 0.0.14 → 0.0.16

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.
@@ -1,5 +1,5 @@
1
- import { defineComponent as N, computed as w, openBlock as p, createElementBlock as _, normalizeClass as k, unref as x, normalizeStyle as Ye, toDisplayString as C, createElementVNode as b, createVNode as ge, createBlock as I, renderSlot as O, createCommentVNode as T, mergeProps as We, withModifiers as W, reactive as ee, watch as F, ref as E, Fragment as X, renderList as le, withDirectives as Pe, withKeys as ye, vModelText as Fe, onMounted as Ue, withCtx as Ze, createTextVNode as Qe, useCssVars as Xe, watchEffect as Ke } from "vue";
2
- const B = /* @__PURE__ */ N({
1
+ import { defineComponent as I, computed as $, openBlock as f, createElementBlock as m, normalizeClass as x, unref as w, normalizeStyle as We, toDisplayString as C, reactive as G, Fragment as Q, renderList as q, createElementVNode as v, createVNode as ne, createBlock as L, renderSlot as D, createCommentVNode as R, mergeProps as Pe, withModifiers as V, watch as U, ref as E, withDirectives as Ae, withKeys as ye, vModelText as Fe, vShow as Ue, onMounted as Ze, withCtx as Qe, createTextVNode as Xe, useCssVars as Ke, watchEffect as Ge } from "vue";
2
+ const N = /* @__PURE__ */ I({
3
3
  __name: "RIcon",
4
4
  props: {
5
5
  name: { default: "" },
@@ -9,23 +9,66 @@ const B = /* @__PURE__ */ N({
9
9
  fontWeight: { default: "normal" }
10
10
  },
11
11
  setup(t) {
12
- const n = t, e = w(() => ({
12
+ const n = t, e = $(() => ({
13
13
  fontSize: `${n.fontSize}px`,
14
14
  fontWeight: n.fontWeight,
15
15
  color: n.color,
16
16
  display: "inline-flex",
17
17
  alignItems: "center",
18
18
  justifyContent: "center"
19
- })), l = w(() => n.kind === "filled" ? "material-icons" : `material-icons-${n.kind}`);
20
- return (o, s) => (p(), _("span", {
21
- class: k(x(l)),
22
- style: Ye(x(e))
19
+ })), a = $(() => n.kind === "filled" ? "material-icons" : `material-icons-${n.kind}`);
20
+ return (o, l) => (f(), m("span", {
21
+ class: x(w(a)),
22
+ style: We(w(e))
23
23
  }, C(n.name), 7));
24
24
  }
25
- }), Ge = { class: "icon" }, Je = { class: "texts" }, qe = { class: "texts__title" }, et = { class: "texts__description" }, tt = {
25
+ }), Je = ["onClick"], qe = { class: "accordion__title" }, et = { class: "accordion__icon" }, tt = { class: "accordion__content" }, zn = /* @__PURE__ */ I({
26
+ __name: "RAccordion",
27
+ props: {
28
+ accordions: null
29
+ },
30
+ setup(t) {
31
+ const n = t, e = G(
32
+ n.accordions.map(({ title: o, content: l }, s) => ({
33
+ title: o,
34
+ content: l,
35
+ open: n.accordions[s].open || !1,
36
+ disabled: n.accordions[s].disabled || !1
37
+ }))
38
+ );
39
+ function a(o) {
40
+ e[o].disabled || e.forEach((l, s) => {
41
+ e[s].open = s === o ? !e[s].open : !1;
42
+ });
43
+ }
44
+ return (o, l) => (f(!0), m(Q, null, q(e, (s, i) => (f(), m("div", {
45
+ key: i,
46
+ class: x({
47
+ accordion: !0,
48
+ "accordion--opened": s.open,
49
+ "accordion--disabled": s.disabled
50
+ })
51
+ }, [
52
+ v("div", {
53
+ class: "accordion__header",
54
+ onClick: (r) => a(i)
55
+ }, [
56
+ v("div", qe, C(s.title), 1),
57
+ v("div", et, [
58
+ ne(N, {
59
+ name: s.open ? "expand_less" : "expand_more"
60
+ }, null, 8, ["name"])
61
+ ])
62
+ ], 8, Je),
63
+ v("div", tt, [
64
+ v("span", null, C(s.content), 1)
65
+ ])
66
+ ], 2))), 128));
67
+ }
68
+ }), nt = { class: "icon" }, ot = { class: "texts" }, at = { class: "texts__title" }, lt = { class: "texts__description" }, st = {
26
69
  key: 0,
27
70
  class: "close"
28
- }, hn = /* @__PURE__ */ N({
71
+ }, Cn = /* @__PURE__ */ I({
29
72
  __name: "RAlert",
30
73
  props: {
31
74
  type: { default: "info" },
@@ -36,89 +79,89 @@ const B = /* @__PURE__ */ N({
36
79
  },
37
80
  emits: ["close"],
38
81
  setup(t, { emit: n }) {
39
- const e = t, l = w(() => ({
82
+ const e = t, a = $(() => ({
40
83
  alert: !0,
41
84
  [`alert--${e.type}`]: !0,
42
85
  [`alert--${e.size}`]: !0
43
- })), o = w(() => ({
86
+ })), o = $(() => ({
44
87
  success: "check_circle",
45
88
  error: "error",
46
89
  warning: "warning",
47
90
  info: "info"
48
- })[e.type]), s = w(() => ({
91
+ })[e.type]), l = $(() => ({
49
92
  small: 12,
50
93
  medium: 16,
51
94
  large: 20
52
- })[e.size]), i = () => {
95
+ })[e.size]), s = () => {
53
96
  n("close");
54
97
  };
55
- return (a, c) => (p(), _("div", {
56
- class: k(x(l))
98
+ return (i, r) => (f(), m("div", {
99
+ class: x(w(a))
57
100
  }, [
58
- b("div", Ge, [
59
- ge(B, {
60
- name: x(o),
61
- size: x(s)
101
+ v("div", nt, [
102
+ ne(N, {
103
+ name: w(o),
104
+ size: w(l)
62
105
  }, null, 8, ["name", "size"])
63
106
  ]),
64
- b("div", Je, [
65
- b("p", qe, C(e.title), 1),
66
- b("p", et, C(e.description), 1)
107
+ v("div", ot, [
108
+ v("p", at, C(e.title), 1),
109
+ v("p", lt, C(e.description), 1)
67
110
  ]),
68
- e.closable ? (p(), _("div", tt, [
69
- a.$slots.close ? O(a.$slots, "close", { key: 1 }) : (p(), I(B, {
111
+ e.closable ? (f(), m("div", st, [
112
+ i.$slots.close ? D(i.$slots, "close", { key: 1 }) : (f(), L(N, {
70
113
  key: 0,
71
114
  class: "close__button",
72
115
  name: "close",
73
116
  size: "16",
74
- onClick: i
117
+ onClick: s
75
118
  }))
76
- ])) : T("", !0)
119
+ ])) : R("", !0)
77
120
  ], 2));
78
121
  }
79
- }), xe = "data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjciIGhlaWdodD0iMjgiIHZpZXdCb3g9IjAgMCAyNyAyOCIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPHBhdGggZD0iTTEzLjQ5OTMgMTRDMTcuMTgyNyAxNCAyMC4xNjYgMTEuMDE2NyAyMC4xNjYgNy4zMzMzNEMyMC4xNjYgMy42NSAxNy4xODI3IDAuNjY2NjcyIDEzLjQ5OTMgMC42NjY2NzJDOS44MTYwMiAwLjY2NjY3MiA2LjgzMjY4IDMuNjUgNi44MzI2OCA3LjMzMzM0QzYuODMyNjggMTEuMDE2NyA5LjgxNjAyIDE0IDEzLjQ5OTMgMTRaTTEzLjQ5OTMgMTcuMzMzM0M5LjA0OTM1IDE3LjMzMzMgMC4xNjYwMTYgMTkuNTY2NyAwLjE2NjAxNiAyNFYyNS42NjY3QzAuMTY2MDE2IDI2LjU4MzMgMC45MTYwMTYgMjcuMzMzMyAxLjgzMjY4IDI3LjMzMzNIMjUuMTY2QzI2LjA4MjcgMjcuMzMzMyAyNi44MzI3IDI2LjU4MzMgMjYuODMyNyAyNS42NjY3VjI0QzI2LjgzMjcgMTkuNTY2NyAxNy45NDkzIDE3LjMzMzMgMTMuNDk5MyAxNy4zMzMzWiIgZmlsbD0iIzRDNUJFMSIvPgo8L3N2Zz4K", nt = { class: "avatar__wrapper" }, ot = ["alt", "src"], mn = /* @__PURE__ */ N({
122
+ }), ke = "data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjciIGhlaWdodD0iMjgiIHZpZXdCb3g9IjAgMCAyNyAyOCIgZmlsbD0ibm9uZSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj4KPHBhdGggZD0iTTEzLjQ5OTMgMTRDMTcuMTgyNyAxNCAyMC4xNjYgMTEuMDE2NyAyMC4xNjYgNy4zMzMzNEMyMC4xNjYgMy42NSAxNy4xODI3IDAuNjY2NjcyIDEzLjQ5OTMgMC42NjY2NzJDOS44MTYwMiAwLjY2NjY3MiA2LjgzMjY4IDMuNjUgNi44MzI2OCA3LjMzMzM0QzYuODMyNjggMTEuMDE2NyA5LjgxNjAyIDE0IDEzLjQ5OTMgMTRaTTEzLjQ5OTMgMTcuMzMzM0M5LjA0OTM1IDE3LjMzMzMgMC4xNjYwMTYgMTkuNTY2NyAwLjE2NjAxNiAyNFYyNS42NjY3QzAuMTY2MDE2IDI2LjU4MzMgMC45MTYwMTYgMjcuMzMzMyAxLjgzMjY4IDI3LjMzMzNIMjUuMTY2QzI2LjA4MjcgMjcuMzMzMyAyNi44MzI3IDI2LjU4MzMgMjYuODMyNyAyNS42NjY3VjI0QzI2LjgzMjcgMTkuNTY2NyAxNy45NDkzIDE3LjMzMzMgMTMuNDk5MyAxNy4zMzMzWiIgZmlsbD0iIzRDNUJFMSIvPgo8L3N2Zz4K", it = { class: "avatar__wrapper" }, rt = ["alt", "src"], Rn = /* @__PURE__ */ I({
80
123
  __name: "RAvatar",
81
124
  props: {
82
125
  type: { default: "image" },
83
- src: { default: xe },
126
+ src: { default: ke },
84
127
  alt: { default: "Avatar" },
85
128
  size: { default: "2xl" },
86
129
  online: { type: Boolean, default: !1 },
87
130
  text: { default: "" }
88
131
  },
89
132
  setup(t) {
90
- const n = t, e = w(() => ({
133
+ const n = t, e = $(() => ({
91
134
  avatar: !0,
92
135
  [`avatar--${n.size}`]: !0
93
- })), l = w(() => n.type === "image" && !n.src), o = w(() => l.value ? xe : n.src), s = (i) => {
94
- const a = i.split(" ");
95
- return a.length === 1 ? a[0].substring(0, 2) : `${a[0].charAt(0)}${a[1].charAt(0)}`;
136
+ })), a = $(() => n.type === "image" && !n.src), o = $(() => a.value ? ke : n.src), l = (s) => {
137
+ const i = s.split(" ");
138
+ return i.length === 1 ? i[0].substring(0, 2) : `${i[0].charAt(0)}${i[1].charAt(0)}`;
96
139
  };
97
- return (i, a) => (p(), _("div", nt, [
98
- b("div", {
99
- class: k(x(e))
140
+ return (s, i) => (f(), m("div", it, [
141
+ v("div", {
142
+ class: x(w(e))
100
143
  }, [
101
- n.type === "text" ? (p(), _("p", {
144
+ n.type === "text" ? (f(), m("p", {
102
145
  key: 0,
103
- class: k({ avatar__text: !0, [`avatar__text--${n.size}`]: !0 })
104
- }, C(s(n.text)), 3)) : (p(), _("img", {
146
+ class: x({ avatar__text: !0, [`avatar__text--${n.size}`]: !0 })
147
+ }, C(l(n.text)), 3)) : (f(), m("img", {
105
148
  key: 1,
106
149
  alt: n.alt,
107
- class: k({
150
+ class: x({
108
151
  avatar__image: !0,
109
152
  [`avatar__image--${n.size}`]: !0,
110
- "avatar__image--anonymous": x(l)
153
+ "avatar__image--anonymous": w(a)
111
154
  }),
112
- src: x(o)
113
- }, null, 10, ot))
155
+ src: w(o)
156
+ }, null, 10, rt))
114
157
  ], 2),
115
- n.online ? (p(), _("span", {
158
+ n.online ? (f(), m("span", {
116
159
  key: 0,
117
- class: k({ avatar__online: !0, [`avatar__online--${n.size}`]: !0 })
118
- }, null, 2)) : T("", !0)
160
+ class: x({ avatar__online: !0, [`avatar__online--${n.size}`]: !0 })
161
+ }, null, 2)) : R("", !0)
119
162
  ]));
120
163
  }
121
- }), lt = { class: "badge-wrapper group" }, gn = /* @__PURE__ */ N({
164
+ }), ct = { class: "badge-wrapper group" }, In = /* @__PURE__ */ I({
122
165
  __name: "RBadge",
123
166
  props: {
124
167
  variant: { default: "primary" },
@@ -130,7 +173,7 @@ const B = /* @__PURE__ */ N({
130
173
  },
131
174
  emits: ["click"],
132
175
  setup(t) {
133
- const n = t, e = w(() => ({
176
+ const n = t, e = $(() => ({
134
177
  badge: !0,
135
178
  badge__content: n.content,
136
179
  [`badge--overlap-${n.placement}`]: n.overlap,
@@ -140,15 +183,15 @@ const B = /* @__PURE__ */ N({
140
183
  "badge--no-content": !n.content,
141
184
  [`badge--${n.variant}`]: n.variant
142
185
  }));
143
- return (l, o) => (p(), _("div", lt, [
144
- b("span", {
145
- class: k(x(e)),
146
- onClick: o[0] || (o[0] = (s) => l.$emit("click"))
186
+ return (a, o) => (f(), m("div", ct, [
187
+ v("span", {
188
+ class: x(w(e)),
189
+ onClick: o[0] || (o[0] = (l) => a.$emit("click"))
147
190
  }, C(n.content), 3),
148
- O(l.$slots, "default")
191
+ D(a.$slots, "default")
149
192
  ]));
150
193
  }
151
- }), st = ["disabled"], at = /* @__PURE__ */ N({
194
+ }), dt = ["disabled"], ut = /* @__PURE__ */ I({
152
195
  __name: "RButton",
153
196
  props: {
154
197
  variant: { default: "primary" },
@@ -164,52 +207,52 @@ const B = /* @__PURE__ */ N({
164
207
  },
165
208
  emits: ["click"],
166
209
  setup(t) {
167
- const n = t, e = w(() => ({
210
+ const n = t, e = $(() => ({
168
211
  button: !0,
169
212
  [`button--${n.variant}`]: !0,
170
213
  "button--loading": n.loading,
171
214
  [`button--${n.size || "medium"}`]: !0,
172
215
  "button--only-icon": n.onlyIcon,
173
216
  "button--block": n.block
174
- })), l = w(() => n.size === "large" ? 20 : 16), o = w(() => {
175
- const { backgroundColor: s, height: i } = n;
217
+ })), a = $(() => n.size === "large" ? 20 : 16), o = $(() => {
218
+ const { backgroundColor: l, height: s } = n;
176
219
  return {
177
- backgroundColor: s,
178
- height: i ? `${i}px` : ""
220
+ backgroundColor: l,
221
+ height: s ? `${s}px` : ""
179
222
  };
180
223
  });
181
- return (s, i) => (p(), _("button", We(s.$attrs, {
182
- class: x(e),
224
+ return (l, s) => (f(), m("button", Pe(l.$attrs, {
225
+ class: w(e),
183
226
  disabled: t.disabled || t.loading,
184
- style: x(o),
185
- onClick: i[0] || (i[0] = W((a) => s.$emit("click"), ["stop"]))
227
+ style: w(o),
228
+ onClick: s[0] || (s[0] = V((i) => l.$emit("click"), ["stop"]))
186
229
  }), [
187
- O(s.$slots, "custom-icon"),
188
- s.$slots["custom-icon"] ? T("", !0) : (p(), I(B, {
230
+ D(l.$slots, "custom-icon"),
231
+ l.$slots["custom-icon"] ? R("", !0) : (f(), L(N, {
189
232
  key: 0,
190
- class: k({
233
+ class: x({
191
234
  "button__prepend-icon": !0,
192
235
  "button__prepend-icon--only": n.onlyIcon
193
236
  }),
194
237
  name: n.prependIcon,
195
- size: x(l)
238
+ size: w(a)
196
239
  }, null, 8, ["class", "name", "size"])),
197
- n.onlyIcon ? T("", !0) : O(s.$slots, "default", { key: 1 }),
198
- !s.$slots["custom-icon"] && !n.onlyIcon ? (p(), I(B, {
240
+ n.onlyIcon ? R("", !0) : D(l.$slots, "default", { key: 1 }),
241
+ !l.$slots["custom-icon"] && !n.onlyIcon ? (f(), L(N, {
199
242
  key: 2,
200
243
  class: "button__append-icon",
201
244
  name: n.appendIcon,
202
- size: x(l)
203
- }, null, 8, ["name", "size"])) : T("", !0)
204
- ], 16, st));
245
+ size: w(a)
246
+ }, null, 8, ["name", "size"])) : R("", !0)
247
+ ], 16, dt));
205
248
  }
206
- }), it = { class: "checkbox-wrapper" }, rt = { class: "checkbox-container" }, ct = ["id", "checked", "disabled", "indeterminate"], dt = ["data-disabled"], ut = { class: "checkbox-texts" }, ft = ["data-disabled", "for"], pt = {
249
+ }), ft = { class: "checkbox-wrapper" }, pt = { class: "checkbox-container" }, ht = ["id", "checked", "disabled", "indeterminate"], mt = ["data-disabled"], _t = { class: "checkbox-texts" }, gt = ["data-disabled", "for"], vt = {
207
250
  key: 0,
208
251
  class: "checkbox-texts__error"
209
- }, ht = {
252
+ }, bt = {
210
253
  key: 1,
211
254
  class: "checkbox-texts__hint"
212
- }, _n = /* @__PURE__ */ N({
255
+ }, An = /* @__PURE__ */ I({
213
256
  __name: "RCheckbox",
214
257
  props: {
215
258
  id: { default: "" },
@@ -222,74 +265,74 @@ const B = /* @__PURE__ */ N({
222
265
  },
223
266
  emits: ["update:modelValue"],
224
267
  setup(t, { emit: n }) {
225
- const e = t, l = ee({
268
+ const e = t, a = G({
226
269
  checked: !1,
227
270
  indeterminate: !1
228
271
  }), o = {
229
272
  checked: "check",
230
273
  unchecked: "",
231
274
  indeterminate: "remove"
232
- }, s = w(() => l.indeterminate ? o.indeterminate : l.checked ? o.checked : o.unchecked), i = w(() => ({
275
+ }, l = $(() => a.indeterminate ? o.indeterminate : a.checked ? o.checked : o.unchecked), s = $(() => ({
233
276
  checkbox: !0,
234
- "checkbox--checked": l.checked,
277
+ "checkbox--checked": a.checked,
235
278
  "checkbox--disabled": e.disabled,
236
- "checkbox--indeterminate": l.indeterminate,
279
+ "checkbox--indeterminate": a.indeterminate,
237
280
  "checkbox--error": !!e.errorMsg
238
- })), a = (c) => {
239
- e.disabled || (l.checked = c.target.checked, l.indeterminate = !1, n("update:modelValue", l.checked));
281
+ })), i = (r) => {
282
+ e.disabled || (a.checked = r.target.checked, a.indeterminate = !1, n("update:modelValue", a.checked));
240
283
  };
241
- return F(
284
+ return U(
242
285
  () => e.indeterminate,
243
- (c) => {
244
- l.indeterminate = c, c === !0 && (l.checked = !1, n("update:modelValue", l.checked));
286
+ (r) => {
287
+ a.indeterminate = r, r === !0 && (a.checked = !1, n("update:modelValue", a.checked));
245
288
  },
246
289
  {
247
290
  // need immediate to set the state on first render for storybook
248
291
  // TODO: find a better way to do this
249
292
  immediate: !0
250
293
  }
251
- ), F(
294
+ ), U(
252
295
  () => e.modelValue,
253
- (c) => {
254
- l.checked = c;
296
+ (r) => {
297
+ a.checked = r;
255
298
  },
256
299
  {
257
300
  // need immediate to set the state on first render for storybook
258
301
  // TODO: find a better way to do this
259
302
  immediate: !0
260
303
  }
261
- ), (c, u) => (p(), _("div", it, [
262
- b("div", rt, [
263
- b("input", {
304
+ ), (r, u) => (f(), m("div", ft, [
305
+ v("div", pt, [
306
+ v("input", {
264
307
  id: e.id,
265
- checked: l.checked,
308
+ checked: a.checked,
266
309
  class: "checkbox-container__input",
267
310
  disabled: e.disabled,
268
- indeterminate: l.indeterminate,
311
+ indeterminate: a.indeterminate,
269
312
  type: "checkbox",
270
- onChange: a
271
- }, null, 40, ct),
272
- b("div", {
273
- class: k(x(i)),
313
+ onChange: i
314
+ }, null, 40, ht),
315
+ v("div", {
316
+ class: x(w(s)),
274
317
  "data-disabled": e.disabled
275
318
  }, [
276
- ge(B, {
277
- name: x(s),
319
+ ne(N, {
320
+ name: w(l),
278
321
  size: "16"
279
322
  }, null, 8, ["name"])
280
- ], 10, dt)
323
+ ], 10, mt)
281
324
  ]),
282
- b("div", ut, [
283
- b("label", {
325
+ v("div", _t, [
326
+ v("label", {
284
327
  class: "checkbox-texts__label",
285
328
  "data-disabled": e.disabled,
286
329
  for: e.id
287
- }, C(e.label), 9, ft),
288
- e.errorMsg ? (p(), _("p", pt, C(e.errorMsg), 1)) : (p(), _("p", ht, C(e.hint), 1))
330
+ }, C(e.label), 9, gt),
331
+ e.errorMsg ? (f(), m("p", vt, C(e.errorMsg), 1)) : (f(), m("p", bt, C(e.hint), 1))
289
332
  ])
290
333
  ]));
291
334
  }
292
- }), mt = /* @__PURE__ */ N({
335
+ }), yt = /* @__PURE__ */ I({
293
336
  __name: "RChip",
294
337
  props: {
295
338
  variant: { default: "primary" },
@@ -302,50 +345,50 @@ const B = /* @__PURE__ */ N({
302
345
  },
303
346
  emits: ["click:chip", "click:close"],
304
347
  setup(t, { emit: n }) {
305
- const e = t, l = w(() => ({
348
+ const e = t, a = $(() => ({
306
349
  chip: !0,
307
350
  "chip--disabled": e.disabled,
308
351
  [`chip__${e.variant}`]: e.variant,
309
352
  [`chip--${e.size}`]: e.size,
310
353
  [`chip__${e.variant}--ghost`]: e.ghost
311
- })), o = w(() => e.size === "small" ? "10" : e.size === "large" ? "16" : "12"), s = (a) => {
312
- e.disabled || n("click:chip", a);
313
- }, i = (a) => {
314
- e.disabled || n("click:close", a);
354
+ })), o = $(() => e.size === "small" ? "10" : e.size === "large" ? "16" : "12"), l = (i) => {
355
+ e.disabled || n("click:chip", i);
356
+ }, s = (i) => {
357
+ e.disabled || n("click:close", i);
315
358
  };
316
- return (a, c) => (p(), _("div", {
317
- class: k(x(l))
359
+ return (i, r) => (f(), m("div", {
360
+ class: x(w(a))
318
361
  }, [
319
- b("div", {
362
+ v("div", {
320
363
  class: "chip__content",
321
- onClick: c[0] || (c[0] = W((u) => s(u), ["stop"]))
364
+ onClick: r[0] || (r[0] = V((u) => l(u), ["stop"]))
322
365
  }, [
323
- e.prependIcon ? (p(), I(B, {
366
+ e.prependIcon ? (f(), L(N, {
324
367
  key: 0,
325
368
  "aria-disabled": e.disabled,
326
369
  class: "chip__prepend-icon",
327
370
  name: e.prependIcon,
328
- size: x(o)
329
- }, null, 8, ["aria-disabled", "name", "size"])) : T("", !0),
330
- b("span", null, C(e.label), 1)
371
+ size: w(o)
372
+ }, null, 8, ["aria-disabled", "name", "size"])) : R("", !0),
373
+ v("span", null, C(e.label), 1)
331
374
  ]),
332
- e.appendIcon ? (p(), I(B, {
375
+ e.appendIcon ? (f(), L(N, {
333
376
  key: 0,
334
377
  "aria-disabled": e.disabled,
335
378
  class: "chip__append-icon",
336
379
  name: e.appendIcon,
337
- size: x(o),
338
- onClick: c[1] || (c[1] = W((u) => i(u), ["stop"]))
339
- }, null, 8, ["aria-disabled", "name", "size"])) : T("", !0)
380
+ size: w(o),
381
+ onClick: r[1] || (r[1] = V((u) => s(u), ["stop"]))
382
+ }, null, 8, ["aria-disabled", "name", "size"])) : R("", !0)
340
383
  ], 2));
341
384
  }
342
- }), gt = { class: "dropdown" }, _t = {
385
+ }), kt = { class: "dropdown-wrapper" }, xt = {
343
386
  key: 0,
344
- class: "select__tags"
345
- }, vt = {
387
+ class: "dropdown__tags"
388
+ }, wt = {
346
389
  key: 1,
347
- class: "select__multiple"
348
- }, bt = ["disabled", "placeholder"], yt = ["onClick"], xt = { style: { display: "flex", "align-items": "center" } }, vn = /* @__PURE__ */ N({
390
+ class: "dropdown__multiple"
391
+ }, $t = ["disabled", "placeholder", "readonly"], Mt = ["aria-disabled", "onClick"], Tt = { style: { display: "flex", "align-items": "center" } }, Ln = /* @__PURE__ */ I({
349
392
  __name: "RDropdown",
350
393
  props: {
351
394
  placeholder: { default: "" },
@@ -356,146 +399,159 @@ const B = /* @__PURE__ */ N({
356
399
  loading: { type: Boolean, default: !1 },
357
400
  prependIcon: { default: "" },
358
401
  appendIcon: { default: "expand_less" },
359
- modelValue: { default: "" }
402
+ modelValue: { default: "" },
403
+ searchable: { type: Boolean, default: !1 }
360
404
  },
361
405
  emits: ["update:modelValue"],
362
406
  setup(t, { emit: n }) {
363
- const e = t, l = E(""), o = ee([]), s = E(!1), i = E(""), a = E(null), c = E(null), u = (h) => {
364
- var f, r, v, $, M, L;
407
+ const e = t, a = E(""), o = G([]), l = E(!1), s = E(""), i = E(null), r = E(null), u = (h) => {
408
+ var c, p, k, M, B, A;
365
409
  if (!e.disabled) {
366
- if (h.stopPropagation(), s.value = !s.value, s.value) {
367
- (f = a.value) == null || f.classList.add("select--active"), (r = a.value) == null || r.focus(), (v = c.value) == null || v.focus(), document.addEventListener("click", u);
410
+ if (h.stopPropagation(), l.value = !l.value, l.value) {
411
+ (c = i.value) == null || c.classList.add("dropdown--active"), (p = i.value) == null || p.focus(), e.searchable && ((k = r.value) == null || k.focus()), document.addEventListener("click", u);
368
412
  return;
369
413
  }
370
- ($ = a.value) == null || $.classList.remove("select--active"), (M = a.value) == null || M.blur(), (L = c.value) == null || L.blur(), document.removeEventListener("click", u);
414
+ (M = i.value) == null || M.classList.remove("dropdown--active"), (B = i.value) == null || B.blur(), (A = r.value) == null || A.blur(), document.removeEventListener("click", u);
371
415
  }
372
- }, m = (h, f) => {
373
- var r;
416
+ }, _ = (h, c) => {
417
+ var p;
374
418
  if (e.multiple || e.taggable) {
375
- h.stopPropagation(), o.includes(f) ? o.splice(o.indexOf(f), 1) : o.push(f), i.value = "", (r = c.value) == null || r.focus();
419
+ h.stopPropagation(), o.includes(c) ? o.splice(o.indexOf(c), 1) : o.push(c), s.value = "", e.searchable && ((p = r.value) == null || p.focus());
376
420
  return;
377
- } else
378
- n("update:modelValue", f.value), l.value = f.label, i.value = f.label;
379
- }, d = (h, f) => {
380
- if (h instanceof KeyboardEvent && h.key !== "Backspace" || i.value !== "")
421
+ }
422
+ d(h, c);
423
+ }, d = (h, c) => {
424
+ if (a.value === c.value) {
425
+ a.value = "", s.value = "";
426
+ return;
427
+ }
428
+ s.value = c.label, a.value = c.value, u(h), n("update:modelValue", c);
429
+ }, y = (h, c) => {
430
+ if (h instanceof KeyboardEvent && h.key !== "Backspace" || s.value !== "")
381
431
  return;
382
432
  h.stopPropagation();
383
- const r = o.findIndex((v) => v.value === f.value);
384
- o.splice(r, 1);
385
- }, y = (h) => {
386
- var v;
433
+ const p = o.findIndex((k) => k.value === c.value);
434
+ o.splice(p, 1);
435
+ }, g = (h) => {
436
+ var k;
387
437
  if (!e.taggable)
388
438
  return;
389
439
  h.stopPropagation();
390
- const f = i.value;
391
- if (f === "")
440
+ const c = s.value;
441
+ if (c === "")
392
442
  return;
393
- e.options.find(($) => $.label === f) || (o.push({ value: f, label: f }), i.value = "", (v = c.value) == null || v.focus());
394
- }, g = w(() => e.options.filter((f) => f.label.toLowerCase().includes(i.value.toLowerCase())));
395
- return F(o, (h) => {
443
+ e.options.find((M) => M.label === c) || (o.push({ value: c, label: c }), s.value = "", (k = r.value) == null || k.focus());
444
+ }, b = $(() => e.searchable ? e.options.filter((c) => c.label.toLowerCase().includes(s.value.toLowerCase())) : e.options);
445
+ return U(o, (h) => {
396
446
  n("update:modelValue", h);
397
- }), (h, f) => (p(), _("div", gt, [
398
- b("div", {
399
- ref_key: "select",
400
- ref: a,
401
- class: k({ select: !0, "select--disabled": e.disabled }),
447
+ }), (h, c) => (f(), m("div", kt, [
448
+ v("div", {
449
+ ref_key: "dropdown",
450
+ ref: i,
451
+ class: x({
452
+ dropdown: !0,
453
+ "dropdown--disabled": e.disabled,
454
+ "dropdown--loading": e.loading
455
+ }),
402
456
  onClick: u
403
457
  }, [
404
- b("div", {
405
- class: k({
406
- "select__prepend-icon": !0,
407
- "select__prepend-icon--active": s.value
458
+ v("div", {
459
+ class: x({
460
+ "dropdown__prepend-icon": !0,
461
+ "dropdown__prepend-icon--active": l.value
408
462
  })
409
463
  }, [
410
- O(h.$slots, "prepend-icon"),
411
- h.$slots["prepend-icon"] ? T("", !0) : (p(), I(B, {
412
- key: 0,
464
+ e.prependIcon ? (f(), L(N, {
465
+ key: 1,
413
466
  name: e.prependIcon
414
- }, null, 8, ["name"]))
467
+ }, null, 8, ["name"])) : D(h.$slots, "prepend-icon", { key: 0 })
415
468
  ], 2),
416
- e.taggable ? (p(), _("div", _t, [
417
- (p(!0), _(X, null, le(o, (r, v) => (p(), I(mt, {
418
- key: v,
469
+ e.taggable ? (f(), m("div", xt, [
470
+ (f(!0), m(Q, null, q(o, (p, k) => (f(), L(yt, {
471
+ key: k,
472
+ label: p.label,
419
473
  appendIcon: "close",
420
- class: "select__tags__chip",
421
- label: r.label,
474
+ class: "dropdown__tags__chip",
422
475
  variant: "primary",
423
- onClickIcon: ($) => d($, r)
424
- }, null, 8, ["label", "onClickIcon"]))), 128))
425
- ])) : T("", !0),
426
- e.multiple ? (p(), _("div", vt, [
427
- (p(!0), _(X, null, le(o, (r, v) => (p(), _("p", { key: v }, C(r.label + ","), 1))), 128))
428
- ])) : T("", !0),
429
- Pe(b("input", {
476
+ "onClick:close": (M) => y(M, p)
477
+ }, null, 8, ["label", "onClick:close"]))), 128))
478
+ ])) : R("", !0),
479
+ e.multiple ? (f(), m("div", wt, [
480
+ (f(!0), m(Q, null, q(o, (p, k) => (f(), m("p", { key: k }, C(p.label + ","), 1))), 128))
481
+ ])) : R("", !0),
482
+ Ae(v("input", {
430
483
  id: "select",
431
484
  ref_key: "input",
432
- ref: c,
433
- "onUpdate:modelValue": f[0] || (f[0] = (r) => i.value = r),
434
- class: "select__input",
485
+ ref: r,
486
+ type: "text",
487
+ "onUpdate:modelValue": c[0] || (c[0] = (p) => s.value = p),
488
+ class: x({
489
+ dropdown__input: !0,
490
+ "dropdown__input--loading": e.loading
491
+ }),
435
492
  disabled: e.disabled,
436
493
  placeholder: e.placeholder,
437
- type: "text",
494
+ readonly: !e.searchable,
438
495
  onKeydown: [
439
- f[1] || (f[1] = ye((r) => d(r, o[o.length - 1]), ["backspace"])),
440
- f[2] || (f[2] = ye((r) => y(r), ["enter"]))
496
+ c[1] || (c[1] = ye((p) => y(p, o[o.length - 1]), ["backspace"])),
497
+ c[2] || (c[2] = ye((p) => g(p), ["enter"]))
441
498
  ]
442
- }, null, 40, bt), [
443
- [Fe, i.value]
499
+ }, null, 42, $t), [
500
+ [Fe, s.value]
444
501
  ]),
445
- b("div", {
446
- class: k({
447
- "select__append-icon": !0,
448
- "select__append-icon--active": s.value
502
+ v("div", {
503
+ class: x({
504
+ "dropdown__append-icon": !0,
505
+ "dropdown__append-icon--active": l.value
449
506
  })
450
507
  }, [
451
- O(h.$slots, "append-icon"),
452
- h.$slots["append-icon"] ? T("", !0) : (p(), I(B, {
453
- key: 0,
508
+ e.appendIcon ? (f(), L(N, {
509
+ key: 1,
454
510
  name: e.appendIcon
455
- }, null, 8, ["name"]))
511
+ }, null, 8, ["name"])) : D(h.$slots, "append-icon", { key: 0 })
456
512
  ], 2)
457
513
  ], 2),
458
- b("ul", {
459
- class: k({ "select-options": !0, "select-options--active": s.value })
514
+ v("ul", {
515
+ class: x({ "dropdown-options": !0, "dropdown-options--active": l.value })
460
516
  }, [
461
- (p(!0), _(X, null, le(x(g), (r) => (p(), _("li", {
462
- key: r.value,
463
- class: k({
464
- "select-options__option": !0,
465
- "select-options__option--active": r.label === l.value || (o == null ? void 0 : o.includes(r))
517
+ (f(!0), m(Q, null, q(w(b), (p) => (f(), m("li", {
518
+ key: p.value,
519
+ class: x({
520
+ "dropdown-options__option": !0,
521
+ "dropdown-options__option--active": p.value === a.value || (o == null ? void 0 : o.includes(p))
466
522
  }),
467
- onClick: (v) => m(v, r)
523
+ "aria-disabled": p.disabled,
524
+ onClick: (k) => _(k, p)
468
525
  }, [
469
- b("div", xt, [
470
- O(h.$slots, "option-prepend"),
471
- h.$slots["option-prepend"] ? T("", !0) : (p(), I(B, {
472
- key: 0,
473
- class: k({
474
- "select-options__option__prepend-icon": !0,
475
- "select-options__option__prepend-icon--active": r.label === l.value || (o == null ? void 0 : o.includes(r))
526
+ v("div", Tt, [
527
+ p.prependIcon ? (f(), L(N, {
528
+ key: 1,
529
+ class: x({
530
+ "dropdown-options__option__prepend-icon": !0,
531
+ "dropdown-options__option__prepend-icon--active": p.value === a.value || (o == null ? void 0 : o.includes(p))
476
532
  }),
477
- name: "face"
478
- }, null, 8, ["class"])),
479
- b("p", {
480
- class: k({
481
- "select-options__option__label": !0,
482
- "select-options__option__label--active": r.label === l.value || (o == null ? void 0 : o.includes(r))
533
+ name: p.prependIcon
534
+ }, null, 8, ["class", "name"])) : D(h.$slots, "option-prepend", { key: 0 }),
535
+ v("p", {
536
+ class: x({
537
+ "dropdown-options__option__label": !0,
538
+ "dropdown-options__option__label--active": p.value === a.value || (o == null ? void 0 : o.includes(p))
483
539
  })
484
- }, C(r.label), 3)
540
+ }, C(p.label), 3)
485
541
  ]),
486
- r.label === l.value || o != null && o.includes(r) ? (p(), I(B, {
542
+ p.value === a.value || o != null && o.includes(p) ? (f(), L(N, {
487
543
  key: 0,
488
- class: k({
489
- "select-options__option__append-icon": !0,
490
- "select-options__option__append-icon--active": r.label === l.value || (o == null ? void 0 : o.includes(r))
544
+ class: x({
545
+ "dropdown-options__option__append-icon": !0,
546
+ "dropdown-options__option__append-icon--active": p.value === a.value || (o == null ? void 0 : o.includes(p))
491
547
  }),
492
548
  name: "check"
493
- }, null, 8, ["class"])) : T("", !0)
494
- ], 10, yt))), 128))
549
+ }, null, 8, ["class"])) : R("", !0)
550
+ ], 10, Mt))), 128))
495
551
  ], 2)
496
552
  ]));
497
553
  }
498
- }), kt = ["id", "for"], Le = /* @__PURE__ */ N({
554
+ }), zt = ["id", "for"], Le = /* @__PURE__ */ I({
499
555
  __name: "RLabel",
500
556
  props: {
501
557
  id: { default: "" },
@@ -504,18 +560,76 @@ const B = /* @__PURE__ */ N({
504
560
  },
505
561
  setup(t) {
506
562
  const n = t;
507
- return (e, l) => (p(), _("label", {
563
+ return (e, a) => (f(), m("label", {
508
564
  id: n.id,
509
565
  for: n.for
510
- }, C(n.text), 9, kt));
566
+ }, C(n.text), 9, zt));
567
+ }
568
+ }), Ct = ["onClick"], Rt = ["open"], It = { class: "dialog__header" }, At = {
569
+ key: 0,
570
+ class: "icon"
571
+ }, Lt = {
572
+ key: 1,
573
+ class: "title"
574
+ }, Nt = {
575
+ key: 2,
576
+ class: "description"
577
+ }, Bt = { class: "dialog__body" }, Dt = { class: "dialog__actions" }, Nn = /* @__PURE__ */ I({
578
+ __name: "RModal",
579
+ props: {
580
+ modelValue: { type: Boolean, default: !1 },
581
+ block: { type: Boolean, default: !1 },
582
+ title: { default: "" },
583
+ description: { default: "" },
584
+ icon: null
585
+ },
586
+ emits: ["update:modelValue"],
587
+ setup(t, { emit: n }) {
588
+ const e = t, a = $(() => ({
589
+ dialog: !0,
590
+ "dialog--block": e.block
591
+ })), o = (l) => {
592
+ l.target === l.currentTarget && n("update:modelValue", !1);
593
+ };
594
+ return (l, s) => Ae((f(), m("div", {
595
+ class: "modal",
596
+ onClick: V(o, ["stop"])
597
+ }, [
598
+ v("div", {
599
+ role: "dialog",
600
+ "aria-modal": "true",
601
+ class: x(w(a)),
602
+ open: e.modelValue
603
+ }, [
604
+ v("div", It, [
605
+ D(l.$slots, "header"),
606
+ e.icon ? (f(), m("div", At, [
607
+ ne(N, {
608
+ name: e.icon,
609
+ kind: "outlined"
610
+ }, null, 8, ["name"])
611
+ ])) : R("", !0),
612
+ e.title ? (f(), m("div", Lt, C(e.title), 1)) : R("", !0),
613
+ e.description ? (f(), m("div", Nt, C(e.description), 1)) : R("", !0)
614
+ ]),
615
+ v("div", Bt, [
616
+ D(l.$slots, "default")
617
+ ]),
618
+ v("div", Dt, [
619
+ D(l.$slots, "actions")
620
+ ])
621
+ ], 10, Rt)
622
+ ], 8, Ct)), [
623
+ [Ue, t.modelValue]
624
+ ]);
511
625
  }
512
- }), wt = { class: "snackbar__text" }, $t = {
626
+ }), jt = { class: "snackbar__text" }, Et = {
513
627
  key: 0,
514
628
  class: "snackbar__action"
515
- }, Mt = {
629
+ }, Ot = {
516
630
  key: 1,
517
631
  class: "snackbar__close"
518
- }, bn = /* @__PURE__ */ N({
632
+ }, Bn = /* @__PURE__ */ I({
519
633
  __name: "RSnackbar",
520
634
  props: {
521
635
  text: { default: "" },
@@ -526,63 +640,63 @@ const B = /* @__PURE__ */ N({
526
640
  show: { type: Boolean, default: !1 },
527
641
  timeout: { default: 0 }
528
642
  },
529
- emits: ["click:action", "click:close"],
643
+ emits: ["action", "close"],
530
644
  setup(t, { emit: n }) {
531
- const e = t, l = E(!1), o = () => {
532
- n("click:action");
533
- }, s = () => {
534
- l.value = !1, n("click:close");
645
+ const e = t, a = E(!1), o = () => {
646
+ n("action");
647
+ }, l = () => {
648
+ a.value = !1, n("close");
535
649
  };
536
- return Ue(() => {
650
+ return Ze(() => {
537
651
  e.timeout && setTimeout(() => {
538
- l.value = !1, n("click:close");
652
+ a.value = !1, n("close");
539
653
  }, e.timeout);
540
- }), F(
654
+ }), U(
541
655
  () => e.show,
542
- (i) => {
543
- l.value = i;
656
+ (s) => {
657
+ a.value = s;
544
658
  },
545
659
  { immediate: !0 }
546
- ), (i, a) => (p(), _("div", {
547
- class: k({
660
+ ), (s, i) => (f(), m("div", {
661
+ class: x({
548
662
  snackbar: !0,
549
- "snackbar--closed": !l.value,
663
+ "snackbar--closed": !a.value,
550
664
  [e.left ? "snackbar--left" : "snackbar--right"]: !0
551
665
  })
552
666
  }, [
553
- b("div", wt, C(e.text), 1),
554
- e.showAction ? (p(), _("div", $t, [
555
- O(i.$slots, "action"),
556
- i.$slots.action ? T("", !0) : (p(), I(at, {
667
+ v("div", jt, C(e.text), 1),
668
+ e.showAction ? (f(), m("div", Et, [
669
+ D(s.$slots, "action"),
670
+ s.$slots.action ? R("", !0) : (f(), L(ut, {
557
671
  key: 0,
558
672
  size: "small",
559
673
  variant: "ghost",
560
674
  onClick: o
561
675
  }, {
562
- default: Ze(() => [
563
- Qe(C(e.actionText), 1)
676
+ default: Qe(() => [
677
+ Xe(C(e.actionText), 1)
564
678
  ]),
565
679
  _: 1
566
680
  }))
567
- ])) : T("", !0),
568
- e.showClose ? (p(), _("div", Mt, [
569
- O(i.$slots, "close"),
570
- i.$slots.close ? T("", !0) : (p(), I(B, {
681
+ ])) : R("", !0),
682
+ e.showClose ? (f(), m("div", Ot, [
683
+ D(s.$slots, "close"),
684
+ s.$slots.close ? R("", !0) : (f(), L(N, {
571
685
  key: 0,
572
686
  name: "close",
573
687
  size: "14",
574
- onClick: W(s, ["stop"])
688
+ onClick: V(l, ["stop"])
575
689
  }, null, 8, ["onClick"]))
576
- ])) : T("", !0)
690
+ ])) : R("", !0)
577
691
  ], 2));
578
692
  }
579
- }), zt = { class: "switch-container" }, Tt = ["id", "checked"], Ct = /* @__PURE__ */ b("span", { class: "slider round" }, null, -1), Rt = ["id", "for"], It = {
693
+ }), Vt = { class: "switch-container" }, Ht = ["id", "checked"], St = /* @__PURE__ */ v("span", { class: "slider round" }, null, -1), Yt = ["id", "for"], Wt = {
580
694
  key: 0,
581
695
  class: "switch-texts__error"
582
- }, Lt = {
696
+ }, Pt = {
583
697
  key: 1,
584
698
  class: "switch-texts__hint"
585
- }, yn = /* @__PURE__ */ N({
699
+ }, Dn = /* @__PURE__ */ I({
586
700
  __name: "RSwitch",
587
701
  props: {
588
702
  id: { default: "switch" },
@@ -595,60 +709,60 @@ const B = /* @__PURE__ */ N({
595
709
  },
596
710
  emits: ["update:modelValue"],
597
711
  setup(t, { emit: n }) {
598
- const e = t, l = ee({
712
+ const e = t, a = G({
599
713
  checked: !1
600
- }), o = w(() => ({
714
+ }), o = $(() => ({
601
715
  switch: !0,
602
716
  "switch--disabled": e.disabled,
603
717
  [`switch--${e.size}`]: e.size,
604
718
  "switch--error": e.errorMsg
605
- })), s = (i) => {
606
- e.disabled || (l.checked = i.target.checked, n("update:modelValue", l.checked));
719
+ })), l = (s) => {
720
+ e.disabled || (a.checked = s.target.checked, n("update:modelValue", a.checked));
607
721
  };
608
- return F(
722
+ return U(
609
723
  () => e.modelValue,
610
- (i) => {
611
- l.checked = i;
724
+ (s) => {
725
+ a.checked = s;
612
726
  },
613
727
  {
614
728
  // need immediate to set the state on first render for storybook
615
729
  // TODO: find a better way to do this
616
730
  immediate: !0
617
731
  }
618
- ), (i, a) => (p(), _("div", zt, [
619
- b("div", {
620
- class: k(x(o))
732
+ ), (s, i) => (f(), m("div", Vt, [
733
+ v("div", {
734
+ class: x(w(o))
621
735
  }, [
622
- b("input", {
736
+ v("input", {
623
737
  id: e.id,
624
- checked: l.checked,
738
+ checked: a.checked,
625
739
  class: "switch__input",
626
740
  type: "checkbox",
627
- onChange: s
628
- }, null, 40, Tt),
629
- Ct
741
+ onChange: l
742
+ }, null, 40, Ht),
743
+ St
630
744
  ], 2),
631
- b("div", {
632
- class: k({
745
+ v("div", {
746
+ class: x({
633
747
  "switch-texts": !0,
634
748
  [`switch-texts--${e.size}`]: !0
635
749
  })
636
750
  }, [
637
- b("label", {
751
+ v("label", {
638
752
  id: e.id,
639
753
  class: "switch-texts__label",
640
754
  for: e.id
641
- }, C(e.label), 9, Rt),
642
- e.errorMsg ? (p(), _("p", It, C(e.errorMsg), 1)) : (p(), _("p", Lt, C(e.hint), 1))
755
+ }, C(e.label), 9, Yt),
756
+ e.errorMsg ? (f(), m("p", Wt, C(e.errorMsg), 1)) : (f(), m("p", Pt, C(e.hint), 1))
643
757
  ], 2)
644
758
  ]));
645
759
  }
646
760
  });
647
761
  var se = /* @__PURE__ */ ((t) => (t.DEFAULT = "default", t.TEXT_ONLY = "text-only", t.ICON_ONLY = "icon-only", t))(se || {});
648
- const At = ["aria-disabled", "aria-selected", "disabled"], Nt = {
649
- key: 1,
762
+ const Ft = ["aria-disabled", "aria-selected", "disabled"], Ut = {
763
+ key: 2,
650
764
  class: "tab-item__label"
651
- }, Dt = /* @__PURE__ */ N({
765
+ }, Zt = /* @__PURE__ */ I({
652
766
  __name: "RTabItem",
653
767
  props: {
654
768
  id: null,
@@ -661,70 +775,69 @@ const At = ["aria-disabled", "aria-selected", "disabled"], Nt = {
661
775
  },
662
776
  emits: ["update:modelValue"],
663
777
  setup(t, { emit: n }) {
664
- const e = t, l = w(() => ({
778
+ const e = t, a = $(() => ({
665
779
  "tab-item": !0,
666
780
  [`tab-item--${e.variant}`]: !0
667
781
  }));
668
- function o(s) {
669
- n("update:modelValue", s);
782
+ function o(l) {
783
+ n("update:modelValue", l);
670
784
  }
671
- return (s, i) => (p(), _("button", {
785
+ return (l, s) => (f(), m("button", {
672
786
  "aria-disabled": e.disabled,
673
787
  "aria-selected": e.active,
674
- class: k(x(l)),
788
+ class: x(w(a)),
675
789
  disabled: e.disabled,
676
- onClick: i[0] || (i[0] = (a) => o(e.id))
790
+ onClick: s[0] || (s[0] = (i) => o(e.id))
677
791
  }, [
678
- O(s.$slots, "icon"),
679
- !s.$slots.icon && t.variant !== x(se).TEXT_ONLY ? (p(), I(B, {
792
+ !l.$slots.icon && t.variant !== w(se).TEXT_ONLY ? (f(), L(N, {
680
793
  key: 0,
681
794
  class: "tab-item__icon",
682
795
  name: e.icon,
683
796
  size: "16"
684
- }, null, 8, ["name"])) : T("", !0),
685
- t.variant !== x(se).ICON_ONLY ? (p(), _("span", Nt, C(e.label), 1)) : T("", !0)
686
- ], 10, At));
797
+ }, null, 8, ["name"])) : D(l.$slots, "custom-icon", { key: 1 }),
798
+ t.variant !== w(se).ICON_ONLY ? (f(), m("span", Ut, C(e.label), 1)) : R("", !0)
799
+ ], 10, Ft));
687
800
  }
688
- }), Bt = { class: "tabs-wrapper" }, jt = { class: "tab-content" }, xn = /* @__PURE__ */ N({
801
+ }), Qt = { class: "tabs-wrapper" }, Xt = { class: "tab-content" }, jn = /* @__PURE__ */ I({
689
802
  __name: "RTabs",
690
803
  props: {
691
804
  tabs: { default: () => [] },
692
805
  scrollable: { type: Boolean, default: !1 }
693
806
  },
694
807
  setup(t) {
695
- const n = t, e = E(0), l = w(() => ({
808
+ const n = t, e = E(0), a = $(() => ({
696
809
  tabs: !0,
697
810
  "tabs--scrollable": n.scrollable
698
811
  }));
699
- return (o, s) => (p(), _(X, null, [
700
- b("div", Bt, [
701
- b("div", {
702
- class: k(x(l))
812
+ return (o, l) => (f(), m(Q, null, [
813
+ v("div", Qt, [
814
+ v("div", {
815
+ class: x(w(a))
703
816
  }, [
704
- (p(!0), _(X, null, le(n.tabs, (i, a) => (p(), I(Dt, {
705
- id: i.id,
706
- key: a,
817
+ (f(!0), m(Q, null, q(n.tabs, (s, i) => (f(), L(Zt, {
818
+ id: s.id,
819
+ key: i,
707
820
  modelValue: e.value,
708
- "onUpdate:modelValue": s[0] || (s[0] = (c) => e.value = c),
709
- active: a === e.value,
710
- disabled: i.disabled,
711
- icon: i.icon,
712
- label: i.label
821
+ "onUpdate:modelValue": l[0] || (l[0] = (r) => e.value = r),
822
+ active: i === e.value,
823
+ disabled: s.disabled,
824
+ icon: s.icon,
825
+ label: s.label
713
826
  }, null, 8, ["id", "modelValue", "active", "disabled", "icon", "label"]))), 128))
714
827
  ], 2)
715
828
  ]),
716
- b("div", jt, [
717
- O(o.$slots, "tab", { activeTab: e.value })
829
+ v("div", Xt, [
830
+ D(o.$slots, "tab", { activeTab: e.value })
718
831
  ])
719
832
  ], 64));
720
833
  }
721
- }), Et = { class: "container" }, Ot = ["id", "disabled", "placeholder", "value"], Vt = {
834
+ }), Kt = { class: "container" }, Gt = ["id", "disabled", "placeholder", "value"], Jt = {
722
835
  key: 1,
723
836
  class: "textarea__error"
724
- }, Ht = {
837
+ }, qt = {
725
838
  key: 2,
726
839
  class: "textarea__hint"
727
- }, kn = /* @__PURE__ */ N({
840
+ }, En = /* @__PURE__ */ I({
728
841
  __name: "RTextArea",
729
842
  props: {
730
843
  id: { default: "" },
@@ -737,50 +850,50 @@ const At = ["aria-disabled", "aria-selected", "disabled"], Nt = {
737
850
  },
738
851
  emits: ["update:modelValue"],
739
852
  setup(t, { emit: n }) {
740
- const e = t, l = ee({
853
+ const e = t, a = G({
741
854
  value: ""
742
855
  });
743
- function o(s) {
744
- n("update:modelValue", s.target.value);
856
+ function o(l) {
857
+ n("update:modelValue", l.target.value);
745
858
  }
746
- return F(
859
+ return U(
747
860
  () => e.modelValue,
748
- (s) => {
749
- l.value = s;
861
+ (l) => {
862
+ a.value = l;
750
863
  },
751
864
  {
752
865
  immediate: !0
753
866
  }
754
- ), (s, i) => (p(), _("div", Et, [
755
- e.label ? (p(), I(Le, {
867
+ ), (l, s) => (f(), m("div", Kt, [
868
+ e.label ? (f(), L(Le, {
756
869
  key: 0,
757
870
  id: "textarea",
758
871
  class: "textarea__label",
759
872
  for: "textarea",
760
873
  text: e.label
761
- }, null, 8, ["text"])) : T("", !0),
762
- b("textarea", {
874
+ }, null, 8, ["text"])) : R("", !0),
875
+ v("textarea", {
763
876
  id: e.id,
764
- class: k(["textarea", {
877
+ class: x(["textarea", {
765
878
  "textarea--error": e.errorMsg,
766
879
  "textarea--disabled": e.disabled
767
880
  }]),
768
881
  disabled: e.disabled,
769
882
  placeholder: e.placeholder,
770
- value: l.value,
883
+ value: a.value,
771
884
  onInput: o
772
- }, null, 42, Ot),
773
- e.errorMsg ? (p(), _("p", Vt, C(e.errorMsg), 1)) : (p(), _("p", Ht, C(e.hint), 1))
885
+ }, null, 42, Gt),
886
+ e.errorMsg ? (f(), m("p", Jt, C(e.errorMsg), 1)) : (f(), m("p", qt, C(e.hint), 1))
774
887
  ]));
775
888
  }
776
- }), St = {
777
- class: /* @__PURE__ */ k({
889
+ }), en = {
890
+ class: /* @__PURE__ */ x({
778
891
  textfield__wrapper: !0
779
892
  })
780
- }, Yt = { class: "input-wrapper" }, Wt = ["id", "disabled", "placeholder", "type", "value"], Pt = { class: "textfield__error" }, Ft = {
893
+ }, tn = { class: "input-wrapper" }, nn = ["id", "disabled", "placeholder", "type", "value"], on = { class: "textfield__error" }, an = {
781
894
  key: 0,
782
895
  class: "textfield__hint"
783
- }, wn = /* @__PURE__ */ N({
896
+ }, On = /* @__PURE__ */ I({
784
897
  __name: "RTextfield",
785
898
  props: {
786
899
  id: { default: "" },
@@ -805,252 +918,256 @@ const At = ["aria-disabled", "aria-selected", "disabled"], Nt = {
805
918
  "click:clear"
806
919
  ],
807
920
  setup(t, { emit: n }) {
808
- const e = t, l = E(), o = ee({
921
+ const e = t, a = E(), o = G({
809
922
  value: ""
810
- }), s = E(e.type), i = {
923
+ }), l = E(e.type), s = {
811
924
  password: "lock_outline",
812
925
  email: "mail_outline",
813
926
  tel: "phone",
814
927
  url: "link",
815
928
  number: "123",
816
929
  text: ""
817
- }, a = E(!1), c = w(() => !!o.value), u = w(() => {
818
- const { disabled: z, loading: A, clearable: R, errorMsg: D } = e;
930
+ }, i = E(!1), r = $(() => !!o.value), u = $(() => {
931
+ const { disabled: T, loading: z, clearable: j, errorMsg: O } = e;
819
932
  return {
820
933
  textfield: !0,
821
- "textfield--error": D == null ? void 0 : D.length,
822
- "textfield--loading": A,
823
- "textfield--disabled": z,
824
- "textfield--clearable": R,
825
- "textfield--focus": a.value,
826
- "textfield--filled": c.value
934
+ "textfield--error": O == null ? void 0 : O.length,
935
+ "textfield--loading": z,
936
+ "textfield--disabled": T,
937
+ "textfield--clearable": j,
938
+ "textfield--focus": i.value,
939
+ "textfield--filled": r.value
827
940
  };
828
- }), m = w(() => ({
941
+ }), _ = $(() => ({
829
942
  "textfield__prepend-icon": !0,
830
943
  "textfield__prepend-icon--loading": e.loading,
831
- "textfield__prepend-icon--error": g.value && c.value
832
- })), d = w(() => ({
944
+ "textfield__prepend-icon--error": g.value && r.value
945
+ })), d = $(() => ({
833
946
  "textfield__append-icon": !0,
834
- "textfield__append-icon--clear": h.value,
947
+ "textfield__append-icon--clear": b.value,
835
948
  "textfield__append-icon--error": g.value
836
- })), y = w(() => o.value.length > 0), g = w(() => {
837
- var z;
838
- return (z = e.errorMsg) == null ? void 0 : z.length;
839
- }), h = w(() => e.clearable && y.value), f = w(() => {
840
- const { prependIcon: z, type: A } = e;
841
- return z || i[A];
842
- }), r = w(() => {
843
- const { appendIcon: z, type: A } = e;
844
- return g.value ? "error_outline" : h.value && ["text", "email"].includes(A) ? "clear" : A === "password" && s.value === "password" ? "visibility" : A === "password" && s.value === "text" ? "visibility_off" : z;
845
- }), v = () => {
846
- a.value = !0, n("focus", {
949
+ })), y = $(() => o.value.length > 0), g = $(() => {
950
+ var T;
951
+ return (T = e.errorMsg) == null ? void 0 : T.length;
952
+ }), b = $(() => e.clearable && y.value), h = $(() => {
953
+ const { prependIcon: T, type: z } = e;
954
+ return T || s[z];
955
+ }), c = $(() => {
956
+ const { appendIcon: T, type: z } = e;
957
+ return g.value ? "error_outline" : b.value && ["text", "email"].includes(z) ? "clear" : z === "password" && l.value === "password" ? "visibility" : z === "password" && l.value === "text" ? "visibility_off" : T;
958
+ }), p = () => {
959
+ i.value = !0, n("focus", {
847
960
  value: o.value
848
961
  });
849
- }, $ = () => {
850
- a.value = !1, n("blur", {
962
+ }, k = () => {
963
+ i.value = !1, n("blur", {
851
964
  value: o.value
852
965
  });
853
966
  }, M = () => {
854
- var z;
855
- if (h.value) {
856
- o.value = "", (z = l.value) == null || z.focus(), n("click:clear", {
967
+ var T;
968
+ if (b.value) {
969
+ o.value = "", (T = a.value) == null || T.focus(), n("click:clear", {
857
970
  value: o.value
858
971
  });
859
972
  return;
860
973
  }
861
974
  n("click:icon", {
862
975
  value: o.value
863
- }), L();
864
- }, L = () => {
865
- s.value = s.value === "password" ? "text" : "password";
866
- }, j = (z) => {
867
- const A = z.target;
868
- o.value = A.value;
976
+ }), B();
977
+ }, B = () => {
978
+ l.value = l.value === "password" ? "text" : "password";
979
+ }, A = (T) => {
980
+ const z = T.target;
981
+ o.value = z.value;
982
+ }, W = () => {
983
+ var T;
984
+ (T = a.value) == null || T.focus();
869
985
  };
870
- return F(
986
+ return U(
871
987
  () => e.modelValue,
872
- (z) => {
873
- o.value = z;
988
+ (T) => {
989
+ o.value = T;
874
990
  },
875
991
  {
876
992
  immediate: !0
877
993
  }
878
- ), F(
994
+ ), U(
879
995
  () => o.value,
880
- (z) => {
881
- n("update:modelValue", z);
996
+ (T) => {
997
+ n("update:modelValue", T);
882
998
  }
883
- ), (z, A) => (p(), _("fieldset", null, [
884
- b("div", St, [
885
- ge(Le, {
999
+ ), (T, z) => (f(), m("fieldset", null, [
1000
+ v("div", en, [
1001
+ ne(Le, {
886
1002
  id: e.id,
887
- class: k({
1003
+ class: x({
888
1004
  textfield__label: !0
889
1005
  }),
890
1006
  for: e.id,
891
- text: e.label
1007
+ text: e.label,
1008
+ onClick: W
892
1009
  }, null, 8, ["id", "for", "text"]),
893
- b("div", Yt, [
894
- b("div", {
895
- class: k(x(u))
1010
+ v("div", tn, [
1011
+ v("div", {
1012
+ class: x(w(u))
896
1013
  }, [
897
- x(f) ? (p(), I(B, {
1014
+ w(h) ? (f(), L(N, {
898
1015
  key: 0,
899
- class: k(x(m)),
900
- name: x(f),
1016
+ class: x(w(_)),
1017
+ name: w(h),
901
1018
  size: 16
902
- }, null, 8, ["class", "name"])) : T("", !0),
903
- b("input", {
904
- id: e.id,
1019
+ }, null, 8, ["class", "name"])) : R("", !0),
1020
+ v("input", {
905
1021
  ref_key: "inputRef",
906
- ref: l,
1022
+ ref: a,
1023
+ id: e.id,
907
1024
  disabled: e.disabled,
908
1025
  placeholder: e.placeholder,
909
- type: s.value,
1026
+ type: l.value,
910
1027
  value: o.value,
911
- onBlur: $,
912
- onFocus: v,
913
- onInput: j
914
- }, null, 40, Wt),
915
- x(r) ? (p(), I(B, {
1028
+ onBlur: k,
1029
+ onFocus: p,
1030
+ onInput: A
1031
+ }, null, 40, nn),
1032
+ w(c) ? (f(), L(N, {
916
1033
  key: 1,
917
- class: k(x(d)),
1034
+ class: x(w(d)),
918
1035
  color: e.iconColor,
919
- name: `${x(r)}`,
1036
+ name: `${w(c)}`,
920
1037
  size: 16,
921
1038
  onClick: M
922
- }, null, 8, ["class", "color", "name"])) : T("", !0)
1039
+ }, null, 8, ["class", "color", "name"])) : R("", !0)
923
1040
  ], 2),
924
- b("div", Pt, C(e.errorMsg), 1),
925
- e.errorMsg ? T("", !0) : (p(), _("div", Ft, C(e.hint), 1))
1041
+ v("div", on, C(e.errorMsg), 1),
1042
+ e.errorMsg ? R("", !0) : (f(), m("div", an, C(e.hint), 1))
926
1043
  ])
927
1044
  ])
928
1045
  ]));
929
1046
  }
930
1047
  });
931
- function te(t) {
1048
+ function oe(t) {
932
1049
  return t.split("-")[0];
933
1050
  }
934
- function de(t) {
1051
+ function ue(t) {
935
1052
  return t.split("-")[1];
936
1053
  }
937
- function ne(t) {
938
- return ["top", "bottom"].includes(te(t)) ? "x" : "y";
1054
+ function ae(t) {
1055
+ return ["top", "bottom"].includes(oe(t)) ? "x" : "y";
939
1056
  }
940
- function _e(t) {
1057
+ function ge(t) {
941
1058
  return t === "y" ? "height" : "width";
942
1059
  }
943
- function ke(t, n, e) {
944
- let { reference: l, floating: o } = t;
945
- const s = l.x + l.width / 2 - o.width / 2, i = l.y + l.height / 2 - o.height / 2, a = ne(n), c = _e(a), u = l[c] / 2 - o[c] / 2, m = a === "x";
1060
+ function xe(t, n, e) {
1061
+ let { reference: a, floating: o } = t;
1062
+ const l = a.x + a.width / 2 - o.width / 2, s = a.y + a.height / 2 - o.height / 2, i = ae(n), r = ge(i), u = a[r] / 2 - o[r] / 2, _ = i === "x";
946
1063
  let d;
947
- switch (te(n)) {
1064
+ switch (oe(n)) {
948
1065
  case "top":
949
- d = { x: s, y: l.y - o.height };
1066
+ d = { x: l, y: a.y - o.height };
950
1067
  break;
951
1068
  case "bottom":
952
- d = { x: s, y: l.y + l.height };
1069
+ d = { x: l, y: a.y + a.height };
953
1070
  break;
954
1071
  case "right":
955
- d = { x: l.x + l.width, y: i };
1072
+ d = { x: a.x + a.width, y: s };
956
1073
  break;
957
1074
  case "left":
958
- d = { x: l.x - o.width, y: i };
1075
+ d = { x: a.x - o.width, y: s };
959
1076
  break;
960
1077
  default:
961
- d = { x: l.x, y: l.y };
1078
+ d = { x: a.x, y: a.y };
962
1079
  }
963
- switch (de(n)) {
1080
+ switch (ue(n)) {
964
1081
  case "start":
965
- d[a] -= u * (e && m ? -1 : 1);
1082
+ d[i] -= u * (e && _ ? -1 : 1);
966
1083
  break;
967
1084
  case "end":
968
- d[a] += u * (e && m ? -1 : 1);
1085
+ d[i] += u * (e && _ ? -1 : 1);
969
1086
  }
970
1087
  return d;
971
1088
  }
972
- const Ut = async (t, n, e) => {
973
- const { placement: l = "bottom", strategy: o = "absolute", middleware: s = [], platform: i } = e, a = s.filter(Boolean), c = await (i.isRTL == null ? void 0 : i.isRTL(n));
974
- let u = await i.getElementRects({ reference: t, floating: n, strategy: o }), { x: m, y: d } = ke(u, l, c), y = l, g = {}, h = 0;
975
- for (let f = 0; f < a.length; f++) {
976
- const { name: r, fn: v } = a[f], { x: $, y: M, data: L, reset: j } = await v({ x: m, y: d, initialPlacement: l, placement: y, strategy: o, middlewareData: g, rects: u, platform: i, elements: { reference: t, floating: n } });
977
- m = $ ?? m, d = M ?? d, g = { ...g, [r]: { ...g[r], ...L } }, j && h <= 50 && (h++, typeof j == "object" && (j.placement && (y = j.placement), j.rects && (u = j.rects === !0 ? await i.getElementRects({ reference: t, floating: n, strategy: o }) : j.rects), { x: m, y: d } = ke(u, y, c)), f = -1);
1089
+ const ln = async (t, n, e) => {
1090
+ const { placement: a = "bottom", strategy: o = "absolute", middleware: l = [], platform: s } = e, i = l.filter(Boolean), r = await (s.isRTL == null ? void 0 : s.isRTL(n));
1091
+ let u = await s.getElementRects({ reference: t, floating: n, strategy: o }), { x: _, y: d } = xe(u, a, r), y = a, g = {}, b = 0;
1092
+ for (let h = 0; h < i.length; h++) {
1093
+ const { name: c, fn: p } = i[h], { x: k, y: M, data: B, reset: A } = await p({ x: _, y: d, initialPlacement: a, placement: y, strategy: o, middlewareData: g, rects: u, platform: s, elements: { reference: t, floating: n } });
1094
+ _ = k ?? _, d = M ?? d, g = { ...g, [c]: { ...g[c], ...B } }, A && b <= 50 && (b++, typeof A == "object" && (A.placement && (y = A.placement), A.rects && (u = A.rects === !0 ? await s.getElementRects({ reference: t, floating: n, strategy: o }) : A.rects), { x: _, y: d } = xe(u, y, r)), h = -1);
978
1095
  }
979
- return { x: m, y: d, placement: y, strategy: o, middlewareData: g };
1096
+ return { x: _, y: d, placement: y, strategy: o, middlewareData: g };
980
1097
  };
981
- function Ae(t) {
1098
+ function Ne(t) {
982
1099
  return typeof t != "number" ? function(n) {
983
1100
  return { top: 0, right: 0, bottom: 0, left: 0, ...n };
984
1101
  }(t) : { top: t, right: t, bottom: t, left: t };
985
1102
  }
986
- function ae(t) {
1103
+ function ie(t) {
987
1104
  return { ...t, top: t.y, left: t.x, right: t.x + t.width, bottom: t.y + t.height };
988
1105
  }
989
- async function ie(t, n) {
1106
+ async function re(t, n) {
990
1107
  var e;
991
1108
  n === void 0 && (n = {});
992
- const { x: l, y: o, platform: s, rects: i, elements: a, strategy: c } = t, { boundary: u = "clippingAncestors", rootBoundary: m = "viewport", elementContext: d = "floating", altBoundary: y = !1, padding: g = 0 } = n, h = Ae(g), f = a[y ? d === "floating" ? "reference" : "floating" : d], r = ae(await s.getClippingRect({ element: (e = await (s.isElement == null ? void 0 : s.isElement(f))) == null || e ? f : f.contextElement || await (s.getDocumentElement == null ? void 0 : s.getDocumentElement(a.floating)), boundary: u, rootBoundary: m, strategy: c })), v = ae(s.convertOffsetParentRelativeRectToViewportRelativeRect ? await s.convertOffsetParentRelativeRectToViewportRelativeRect({ rect: d === "floating" ? { ...i.floating, x: l, y: o } : i.reference, offsetParent: await (s.getOffsetParent == null ? void 0 : s.getOffsetParent(a.floating)), strategy: c }) : i[d]);
993
- return { top: r.top - v.top + h.top, bottom: v.bottom - r.bottom + h.bottom, left: r.left - v.left + h.left, right: v.right - r.right + h.right };
1109
+ const { x: a, y: o, platform: l, rects: s, elements: i, strategy: r } = t, { boundary: u = "clippingAncestors", rootBoundary: _ = "viewport", elementContext: d = "floating", altBoundary: y = !1, padding: g = 0 } = n, b = Ne(g), h = i[y ? d === "floating" ? "reference" : "floating" : d], c = ie(await l.getClippingRect({ element: (e = await (l.isElement == null ? void 0 : l.isElement(h))) == null || e ? h : h.contextElement || await (l.getDocumentElement == null ? void 0 : l.getDocumentElement(i.floating)), boundary: u, rootBoundary: _, strategy: r })), p = ie(l.convertOffsetParentRelativeRectToViewportRelativeRect ? await l.convertOffsetParentRelativeRectToViewportRelativeRect({ rect: d === "floating" ? { ...s.floating, x: a, y: o } : s.reference, offsetParent: await (l.getOffsetParent == null ? void 0 : l.getOffsetParent(i.floating)), strategy: r }) : s[d]);
1110
+ return { top: c.top - p.top + b.top, bottom: p.bottom - c.bottom + b.bottom, left: c.left - p.left + b.left, right: p.right - c.right + b.right };
994
1111
  }
995
- const Zt = Math.min, Qt = Math.max;
996
- function he(t, n, e) {
997
- return Qt(t, Zt(n, e));
1112
+ const sn = Math.min, rn = Math.max;
1113
+ function me(t, n, e) {
1114
+ return rn(t, sn(n, e));
998
1115
  }
999
- const Xt = (t) => ({ name: "arrow", options: t, async fn(n) {
1000
- const { element: e, padding: l = 0 } = t ?? {}, { x: o, y: s, placement: i, rects: a, platform: c } = n;
1116
+ const cn = (t) => ({ name: "arrow", options: t, async fn(n) {
1117
+ const { element: e, padding: a = 0 } = t ?? {}, { x: o, y: l, placement: s, rects: i, platform: r } = n;
1001
1118
  if (e == null)
1002
1119
  return {};
1003
- const u = Ae(l), m = { x: o, y: s }, d = ne(i), y = de(i), g = _e(d), h = await c.getDimensions(e), f = d === "y" ? "top" : "left", r = d === "y" ? "bottom" : "right", v = a.reference[g] + a.reference[d] - m[d] - a.floating[g], $ = m[d] - a.reference[d], M = await (c.getOffsetParent == null ? void 0 : c.getOffsetParent(e));
1004
- let L = M ? d === "y" ? M.clientHeight || 0 : M.clientWidth || 0 : 0;
1005
- L === 0 && (L = a.floating[g]);
1006
- const j = v / 2 - $ / 2, z = u[f], A = L - h[g] - u[r], R = L / 2 - h[g] / 2 + j, D = he(z, R, A), Q = (y === "start" ? u[f] : u[r]) > 0 && R !== D && a.reference[g] <= a.floating[g];
1007
- return { [d]: m[d] - (Q ? R < z ? z - R : A - R : 0), data: { [d]: D, centerOffset: R - D } };
1008
- } }), Kt = { left: "right", right: "left", bottom: "top", top: "bottom" };
1009
- function re(t) {
1010
- return t.replace(/left|right|bottom|top/g, (n) => Kt[n]);
1120
+ const u = Ne(a), _ = { x: o, y: l }, d = ae(s), y = ue(s), g = ge(d), b = await r.getDimensions(e), h = d === "y" ? "top" : "left", c = d === "y" ? "bottom" : "right", p = i.reference[g] + i.reference[d] - _[d] - i.floating[g], k = _[d] - i.reference[d], M = await (r.getOffsetParent == null ? void 0 : r.getOffsetParent(e));
1121
+ let B = M ? d === "y" ? M.clientHeight || 0 : M.clientWidth || 0 : 0;
1122
+ B === 0 && (B = i.floating[g]);
1123
+ const A = p / 2 - k / 2, W = u[h], T = B - b[g] - u[c], z = B / 2 - b[g] / 2 + A, j = me(W, z, T), O = (y === "start" ? u[h] : u[c]) > 0 && z !== j && i.reference[g] <= i.floating[g];
1124
+ return { [d]: _[d] - (O ? z < W ? W - z : T - z : 0), data: { [d]: j, centerOffset: z - j } };
1125
+ } }), dn = { left: "right", right: "left", bottom: "top", top: "bottom" };
1126
+ function ce(t) {
1127
+ return t.replace(/left|right|bottom|top/g, (n) => dn[n]);
1011
1128
  }
1012
- function Gt(t, n, e) {
1129
+ function un(t, n, e) {
1013
1130
  e === void 0 && (e = !1);
1014
- const l = de(t), o = ne(t), s = _e(o);
1015
- let i = o === "x" ? l === (e ? "end" : "start") ? "right" : "left" : l === "start" ? "bottom" : "top";
1016
- return n.reference[s] > n.floating[s] && (i = re(i)), { main: i, cross: re(i) };
1131
+ const a = ue(t), o = ae(t), l = ge(o);
1132
+ let s = o === "x" ? a === (e ? "end" : "start") ? "right" : "left" : a === "start" ? "bottom" : "top";
1133
+ return n.reference[l] > n.floating[l] && (s = ce(s)), { main: s, cross: ce(s) };
1017
1134
  }
1018
- const Jt = { start: "end", end: "start" };
1135
+ const fn = { start: "end", end: "start" };
1019
1136
  function we(t) {
1020
- return t.replace(/start|end/g, (n) => Jt[n]);
1137
+ return t.replace(/start|end/g, (n) => fn[n]);
1021
1138
  }
1022
- const Ne = ["top", "right", "bottom", "left"];
1023
- Ne.reduce((t, n) => t.concat(n, n + "-start", n + "-end"), []);
1024
- const qt = function(t) {
1139
+ const Be = ["top", "right", "bottom", "left"];
1140
+ Be.reduce((t, n) => t.concat(n, n + "-start", n + "-end"), []);
1141
+ const pn = function(t) {
1025
1142
  return t === void 0 && (t = {}), { name: "flip", options: t, async fn(n) {
1026
1143
  var e;
1027
- const { placement: l, middlewareData: o, rects: s, initialPlacement: i, platform: a, elements: c } = n, { mainAxis: u = !0, crossAxis: m = !0, fallbackPlacements: d, fallbackStrategy: y = "bestFit", flipAlignment: g = !0, ...h } = t, f = te(l), r = d || (f === i || !g ? [re(i)] : function(R) {
1028
- const D = re(R);
1029
- return [we(R), D, we(D)];
1030
- }(i)), v = [i, ...r], $ = await ie(n, h), M = [];
1031
- let L = ((e = o.flip) == null ? void 0 : e.overflows) || [];
1032
- if (u && M.push($[f]), m) {
1033
- const { main: R, cross: D } = Gt(l, s, await (a.isRTL == null ? void 0 : a.isRTL(c.floating)));
1034
- M.push($[R], $[D]);
1144
+ const { placement: a, middlewareData: o, rects: l, initialPlacement: s, platform: i, elements: r } = n, { mainAxis: u = !0, crossAxis: _ = !0, fallbackPlacements: d, fallbackStrategy: y = "bestFit", flipAlignment: g = !0, ...b } = t, h = oe(a), c = d || (h === s || !g ? [ce(s)] : function(z) {
1145
+ const j = ce(z);
1146
+ return [we(z), j, we(j)];
1147
+ }(s)), p = [s, ...c], k = await re(n, b), M = [];
1148
+ let B = ((e = o.flip) == null ? void 0 : e.overflows) || [];
1149
+ if (u && M.push(k[h]), _) {
1150
+ const { main: z, cross: j } = un(a, l, await (i.isRTL == null ? void 0 : i.isRTL(r.floating)));
1151
+ M.push(k[z], k[j]);
1035
1152
  }
1036
- if (L = [...L, { placement: l, overflows: M }], !M.every((R) => R <= 0)) {
1037
- var j, z;
1038
- const R = ((j = (z = o.flip) == null ? void 0 : z.index) != null ? j : 0) + 1, D = v[R];
1039
- if (D)
1040
- return { data: { index: R, overflows: L }, reset: { placement: D } };
1041
- let Q = "bottom";
1153
+ if (B = [...B, { placement: a, overflows: M }], !M.every((z) => z <= 0)) {
1154
+ var A, W;
1155
+ const z = ((A = (W = o.flip) == null ? void 0 : W.index) != null ? A : 0) + 1, j = p[z];
1156
+ if (j)
1157
+ return { data: { index: z, overflows: B }, reset: { placement: j } };
1158
+ let O = "bottom";
1042
1159
  switch (y) {
1043
1160
  case "bestFit": {
1044
- var A;
1045
- const be = (A = L.map((oe) => [oe, oe.overflows.filter((G) => G > 0).reduce((G, Se) => G + Se, 0)]).sort((oe, G) => oe[1] - G[1])[0]) == null ? void 0 : A[0].placement;
1046
- be && (Q = be);
1161
+ var T;
1162
+ const be = (T = B.map((le) => [le, le.overflows.filter((J) => J > 0).reduce((J, Ye) => J + Ye, 0)]).sort((le, J) => le[1] - J[1])[0]) == null ? void 0 : T[0].placement;
1163
+ be && (O = be);
1047
1164
  break;
1048
1165
  }
1049
1166
  case "initialPlacement":
1050
- Q = i;
1167
+ O = s;
1051
1168
  }
1052
- if (l !== Q)
1053
- return { reset: { placement: Q } };
1169
+ if (a !== O)
1170
+ return { reset: { placement: O } };
1054
1171
  }
1055
1172
  return {};
1056
1173
  } };
@@ -1059,61 +1176,61 @@ function $e(t, n) {
1059
1176
  return { top: t.top - n.height, right: t.right - n.width, bottom: t.bottom - n.height, left: t.left - n.width };
1060
1177
  }
1061
1178
  function Me(t) {
1062
- return Ne.some((n) => t[n] >= 0);
1179
+ return Be.some((n) => t[n] >= 0);
1063
1180
  }
1064
- const en = function(t) {
1181
+ const hn = function(t) {
1065
1182
  let { strategy: n = "referenceHidden", ...e } = t === void 0 ? {} : t;
1066
- return { name: "hide", async fn(l) {
1067
- const { rects: o } = l;
1183
+ return { name: "hide", async fn(a) {
1184
+ const { rects: o } = a;
1068
1185
  switch (n) {
1069
1186
  case "referenceHidden": {
1070
- const s = $e(await ie(l, { ...e, elementContext: "reference" }), o.reference);
1071
- return { data: { referenceHiddenOffsets: s, referenceHidden: Me(s) } };
1187
+ const l = $e(await re(a, { ...e, elementContext: "reference" }), o.reference);
1188
+ return { data: { referenceHiddenOffsets: l, referenceHidden: Me(l) } };
1072
1189
  }
1073
1190
  case "escaped": {
1074
- const s = $e(await ie(l, { ...e, altBoundary: !0 }), o.floating);
1075
- return { data: { escapedOffsets: s, escaped: Me(s) } };
1191
+ const l = $e(await re(a, { ...e, altBoundary: !0 }), o.floating);
1192
+ return { data: { escapedOffsets: l, escaped: Me(l) } };
1076
1193
  }
1077
1194
  default:
1078
1195
  return {};
1079
1196
  }
1080
1197
  } };
1081
- }, tn = function(t) {
1198
+ }, mn = function(t) {
1082
1199
  return t === void 0 && (t = 0), { name: "offset", options: t, async fn(n) {
1083
- const { x: e, y: l } = n, o = await async function(s, i) {
1084
- const { placement: a, platform: c, elements: u } = s, m = await (c.isRTL == null ? void 0 : c.isRTL(u.floating)), d = te(a), y = de(a), g = ne(a) === "x", h = ["left", "top"].includes(d) ? -1 : 1, f = m && g ? -1 : 1, r = typeof i == "function" ? i(s) : i;
1085
- let { mainAxis: v, crossAxis: $, alignmentAxis: M } = typeof r == "number" ? { mainAxis: r, crossAxis: 0, alignmentAxis: null } : { mainAxis: 0, crossAxis: 0, alignmentAxis: null, ...r };
1086
- return y && typeof M == "number" && ($ = y === "end" ? -1 * M : M), g ? { x: $ * f, y: v * h } : { x: v * h, y: $ * f };
1200
+ const { x: e, y: a } = n, o = await async function(l, s) {
1201
+ const { placement: i, platform: r, elements: u } = l, _ = await (r.isRTL == null ? void 0 : r.isRTL(u.floating)), d = oe(i), y = ue(i), g = ae(i) === "x", b = ["left", "top"].includes(d) ? -1 : 1, h = _ && g ? -1 : 1, c = typeof s == "function" ? s(l) : s;
1202
+ let { mainAxis: p, crossAxis: k, alignmentAxis: M } = typeof c == "number" ? { mainAxis: c, crossAxis: 0, alignmentAxis: null } : { mainAxis: 0, crossAxis: 0, alignmentAxis: null, ...c };
1203
+ return y && typeof M == "number" && (k = y === "end" ? -1 * M : M), g ? { x: k * h, y: p * b } : { x: p * b, y: k * h };
1087
1204
  }(n, t);
1088
- return { x: e + o.x, y: l + o.y, data: o };
1205
+ return { x: e + o.x, y: a + o.y, data: o };
1089
1206
  } };
1090
1207
  };
1091
- function nn(t) {
1208
+ function _n(t) {
1092
1209
  return t === "x" ? "y" : "x";
1093
1210
  }
1094
- const on = function(t) {
1211
+ const gn = function(t) {
1095
1212
  return t === void 0 && (t = {}), { name: "shift", options: t, async fn(n) {
1096
- const { x: e, y: l, placement: o } = n, { mainAxis: s = !0, crossAxis: i = !1, limiter: a = { fn: (r) => {
1097
- let { x: v, y: $ } = r;
1098
- return { x: v, y: $ };
1099
- } }, ...c } = t, u = { x: e, y: l }, m = await ie(n, c), d = ne(te(o)), y = nn(d);
1100
- let g = u[d], h = u[y];
1101
- if (s) {
1102
- const r = d === "y" ? "bottom" : "right";
1103
- g = he(g + m[d === "y" ? "top" : "left"], g, g - m[r]);
1213
+ const { x: e, y: a, placement: o } = n, { mainAxis: l = !0, crossAxis: s = !1, limiter: i = { fn: (c) => {
1214
+ let { x: p, y: k } = c;
1215
+ return { x: p, y: k };
1216
+ } }, ...r } = t, u = { x: e, y: a }, _ = await re(n, r), d = ae(oe(o)), y = _n(d);
1217
+ let g = u[d], b = u[y];
1218
+ if (l) {
1219
+ const c = d === "y" ? "bottom" : "right";
1220
+ g = me(g + _[d === "y" ? "top" : "left"], g, g - _[c]);
1104
1221
  }
1105
- if (i) {
1106
- const r = y === "y" ? "bottom" : "right";
1107
- h = he(h + m[y === "y" ? "top" : "left"], h, h - m[r]);
1222
+ if (s) {
1223
+ const c = y === "y" ? "bottom" : "right";
1224
+ b = me(b + _[y === "y" ? "top" : "left"], b, b - _[c]);
1108
1225
  }
1109
- const f = a.fn({ ...n, [d]: g, [y]: h });
1110
- return { ...f, data: { x: f.x - e, y: f.y - l } };
1226
+ const h = i.fn({ ...n, [d]: g, [y]: b });
1227
+ return { ...h, data: { x: h.x - e, y: h.y - a } };
1111
1228
  } };
1112
1229
  };
1113
1230
  function De(t) {
1114
1231
  return t && t.document && t.location && t.alert && t.setInterval;
1115
1232
  }
1116
- function S(t) {
1233
+ function Y(t) {
1117
1234
  if (t == null)
1118
1235
  return window;
1119
1236
  if (!De(t)) {
@@ -1122,198 +1239,198 @@ function S(t) {
1122
1239
  }
1123
1240
  return t;
1124
1241
  }
1125
- function V(t) {
1126
- return S(t).getComputedStyle(t);
1242
+ function H(t) {
1243
+ return Y(t).getComputedStyle(t);
1127
1244
  }
1128
- function U(t) {
1245
+ function Z(t) {
1129
1246
  return De(t) ? "" : t ? (t.nodeName || "").toLowerCase() : "";
1130
1247
  }
1131
- function Be() {
1248
+ function je() {
1132
1249
  const t = navigator.userAgentData;
1133
1250
  return t && Array.isArray(t.brands) ? t.brands.map((n) => n.brand + "/" + n.version).join(" ") : navigator.userAgent;
1134
1251
  }
1135
- function H(t) {
1136
- return t instanceof S(t).HTMLElement;
1252
+ function S(t) {
1253
+ return t instanceof Y(t).HTMLElement;
1137
1254
  }
1138
1255
  function K(t) {
1139
- return t instanceof S(t).Element;
1256
+ return t instanceof Y(t).Element;
1140
1257
  }
1141
- function ze(t) {
1142
- return typeof ShadowRoot > "u" ? !1 : t instanceof S(t).ShadowRoot || t instanceof ShadowRoot;
1258
+ function Te(t) {
1259
+ return typeof ShadowRoot > "u" ? !1 : t instanceof Y(t).ShadowRoot || t instanceof ShadowRoot;
1143
1260
  }
1144
- function ue(t) {
1145
- const { overflow: n, overflowX: e, overflowY: l, display: o } = V(t);
1146
- return /auto|scroll|overlay|hidden/.test(n + l + e) && !["inline", "contents"].includes(o);
1261
+ function fe(t) {
1262
+ const { overflow: n, overflowX: e, overflowY: a, display: o } = H(t);
1263
+ return /auto|scroll|overlay|hidden/.test(n + a + e) && !["inline", "contents"].includes(o);
1147
1264
  }
1148
- function ln(t) {
1149
- return ["table", "td", "th"].includes(U(t));
1265
+ function vn(t) {
1266
+ return ["table", "td", "th"].includes(Z(t));
1150
1267
  }
1151
- function me(t) {
1152
- const n = /firefox/i.test(Be()), e = V(t), l = e.backdropFilter || e.WebkitBackdropFilter;
1153
- return e.transform !== "none" || e.perspective !== "none" || !!l && l !== "none" || n && e.willChange === "filter" || n && !!e.filter && e.filter !== "none" || ["transform", "perspective"].some((o) => e.willChange.includes(o)) || ["paint", "layout", "strict", "content"].some((o) => {
1154
- const s = e.contain;
1155
- return s != null && s.includes(o);
1268
+ function _e(t) {
1269
+ const n = /firefox/i.test(je()), e = H(t), a = e.backdropFilter || e.WebkitBackdropFilter;
1270
+ return e.transform !== "none" || e.perspective !== "none" || !!a && a !== "none" || n && e.willChange === "filter" || n && !!e.filter && e.filter !== "none" || ["transform", "perspective"].some((o) => e.willChange.includes(o)) || ["paint", "layout", "strict", "content"].some((o) => {
1271
+ const l = e.contain;
1272
+ return l != null && l.includes(o);
1156
1273
  });
1157
1274
  }
1158
- function je() {
1159
- return !/^((?!chrome|android).)*safari/i.test(Be());
1275
+ function Ee() {
1276
+ return !/^((?!chrome|android).)*safari/i.test(je());
1160
1277
  }
1161
1278
  function ve(t) {
1162
- return ["html", "body", "#document"].includes(U(t));
1279
+ return ["html", "body", "#document"].includes(Z(t));
1163
1280
  }
1164
- const Te = Math.min, J = Math.max, ce = Math.round;
1165
- function Z(t, n, e) {
1166
- var l, o, s, i;
1281
+ const ze = Math.min, ee = Math.max, de = Math.round;
1282
+ function X(t, n, e) {
1283
+ var a, o, l, s;
1167
1284
  n === void 0 && (n = !1), e === void 0 && (e = !1);
1168
- const a = t.getBoundingClientRect();
1169
- let c = 1, u = 1;
1170
- n && H(t) && (c = t.offsetWidth > 0 && ce(a.width) / t.offsetWidth || 1, u = t.offsetHeight > 0 && ce(a.height) / t.offsetHeight || 1);
1171
- const m = K(t) ? S(t) : window, d = !je() && e, y = (a.left + (d && (l = (o = m.visualViewport) == null ? void 0 : o.offsetLeft) != null ? l : 0)) / c, g = (a.top + (d && (s = (i = m.visualViewport) == null ? void 0 : i.offsetTop) != null ? s : 0)) / u, h = a.width / c, f = a.height / u;
1172
- return { width: h, height: f, top: g, right: y + h, bottom: g + f, left: y, x: y, y: g };
1285
+ const i = t.getBoundingClientRect();
1286
+ let r = 1, u = 1;
1287
+ n && S(t) && (r = t.offsetWidth > 0 && de(i.width) / t.offsetWidth || 1, u = t.offsetHeight > 0 && de(i.height) / t.offsetHeight || 1);
1288
+ const _ = K(t) ? Y(t) : window, d = !Ee() && e, y = (i.left + (d && (a = (o = _.visualViewport) == null ? void 0 : o.offsetLeft) != null ? a : 0)) / r, g = (i.top + (d && (l = (s = _.visualViewport) == null ? void 0 : s.offsetTop) != null ? l : 0)) / u, b = i.width / r, h = i.height / u;
1289
+ return { width: b, height: h, top: g, right: y + b, bottom: g + h, left: y, x: y, y: g };
1173
1290
  }
1174
- function P(t) {
1175
- return (n = t, (n instanceof S(n).Node ? t.ownerDocument : t.document) || window.document).documentElement;
1291
+ function F(t) {
1292
+ return (n = t, (n instanceof Y(n).Node ? t.ownerDocument : t.document) || window.document).documentElement;
1176
1293
  var n;
1177
1294
  }
1178
- function fe(t) {
1295
+ function pe(t) {
1179
1296
  return K(t) ? { scrollLeft: t.scrollLeft, scrollTop: t.scrollTop } : { scrollLeft: t.pageXOffset, scrollTop: t.pageYOffset };
1180
1297
  }
1181
- function Ee(t) {
1182
- return Z(P(t)).left + fe(t).scrollLeft;
1298
+ function Oe(t) {
1299
+ return X(F(t)).left + pe(t).scrollLeft;
1183
1300
  }
1184
- function sn(t, n, e) {
1185
- const l = H(n), o = P(n), s = Z(t, l && function(c) {
1186
- const u = Z(c);
1187
- return ce(u.width) !== c.offsetWidth || ce(u.height) !== c.offsetHeight;
1301
+ function bn(t, n, e) {
1302
+ const a = S(n), o = F(n), l = X(t, a && function(r) {
1303
+ const u = X(r);
1304
+ return de(u.width) !== r.offsetWidth || de(u.height) !== r.offsetHeight;
1188
1305
  }(n), e === "fixed");
1189
- let i = { scrollLeft: 0, scrollTop: 0 };
1190
- const a = { x: 0, y: 0 };
1191
- if (l || !l && e !== "fixed")
1192
- if ((U(n) !== "body" || ue(o)) && (i = fe(n)), H(n)) {
1193
- const c = Z(n, !0);
1194
- a.x = c.x + n.clientLeft, a.y = c.y + n.clientTop;
1306
+ let s = { scrollLeft: 0, scrollTop: 0 };
1307
+ const i = { x: 0, y: 0 };
1308
+ if (a || !a && e !== "fixed")
1309
+ if ((Z(n) !== "body" || fe(o)) && (s = pe(n)), S(n)) {
1310
+ const r = X(n, !0);
1311
+ i.x = r.x + n.clientLeft, i.y = r.y + n.clientTop;
1195
1312
  } else
1196
- o && (a.x = Ee(o));
1197
- return { x: s.left + i.scrollLeft - a.x, y: s.top + i.scrollTop - a.y, width: s.width, height: s.height };
1313
+ o && (i.x = Oe(o));
1314
+ return { x: l.left + s.scrollLeft - i.x, y: l.top + s.scrollTop - i.y, width: l.width, height: l.height };
1198
1315
  }
1199
- function q(t) {
1200
- if (U(t) === "html")
1316
+ function te(t) {
1317
+ if (Z(t) === "html")
1201
1318
  return t;
1202
- const n = t.assignedSlot || t.parentNode || (ze(t) ? t.host : null) || P(t);
1203
- return ze(n) ? n.host : n;
1319
+ const n = t.assignedSlot || t.parentNode || (Te(t) ? t.host : null) || F(t);
1320
+ return Te(n) ? n.host : n;
1204
1321
  }
1205
1322
  function Ce(t) {
1206
- return H(t) && V(t).position !== "fixed" ? t.offsetParent : null;
1323
+ return S(t) && H(t).position !== "fixed" ? t.offsetParent : null;
1207
1324
  }
1208
1325
  function Re(t) {
1209
- const n = S(t);
1326
+ const n = Y(t);
1210
1327
  let e = Ce(t);
1211
- for (; e && ln(e) && V(e).position === "static"; )
1328
+ for (; e && vn(e) && H(e).position === "static"; )
1212
1329
  e = Ce(e);
1213
- return e && (U(e) === "html" || U(e) === "body" && V(e).position === "static" && !me(e)) ? n : e || function(l) {
1214
- let o = q(l);
1215
- for (; H(o) && !ve(o); ) {
1216
- if (me(o))
1330
+ return e && (Z(e) === "html" || Z(e) === "body" && H(e).position === "static" && !_e(e)) ? n : e || function(a) {
1331
+ let o = te(a);
1332
+ for (; S(o) && !ve(o); ) {
1333
+ if (_e(o))
1217
1334
  return o;
1218
- o = q(o);
1335
+ o = te(o);
1219
1336
  }
1220
1337
  return null;
1221
1338
  }(t) || n;
1222
1339
  }
1223
- function Oe(t) {
1224
- const n = q(t);
1225
- return ve(n) ? t.ownerDocument.body : H(n) && ue(n) ? n : Oe(n);
1340
+ function Ve(t) {
1341
+ const n = te(t);
1342
+ return ve(n) ? t.ownerDocument.body : S(n) && fe(n) ? n : Ve(n);
1226
1343
  }
1227
- function Ve(t, n) {
1344
+ function He(t, n) {
1228
1345
  var e;
1229
1346
  n === void 0 && (n = []);
1230
- const l = Oe(t), o = l === ((e = t.ownerDocument) == null ? void 0 : e.body), s = S(l), i = o ? [s].concat(s.visualViewport || [], ue(l) ? l : []) : l, a = n.concat(i);
1231
- return o ? a : a.concat(Ve(i));
1347
+ const a = Ve(t), o = a === ((e = t.ownerDocument) == null ? void 0 : e.body), l = Y(a), s = o ? [l].concat(l.visualViewport || [], fe(a) ? a : []) : a, i = n.concat(s);
1348
+ return o ? i : i.concat(He(s));
1232
1349
  }
1233
1350
  function Ie(t, n, e) {
1234
- return n === "viewport" ? ae(function(l, o) {
1235
- const s = S(l), i = P(l), a = s.visualViewport;
1236
- let c = i.clientWidth, u = i.clientHeight, m = 0, d = 0;
1237
- if (a) {
1238
- c = a.width, u = a.height;
1239
- const y = je();
1240
- (y || !y && o === "fixed") && (m = a.offsetLeft, d = a.offsetTop);
1351
+ return n === "viewport" ? ie(function(a, o) {
1352
+ const l = Y(a), s = F(a), i = l.visualViewport;
1353
+ let r = s.clientWidth, u = s.clientHeight, _ = 0, d = 0;
1354
+ if (i) {
1355
+ r = i.width, u = i.height;
1356
+ const y = Ee();
1357
+ (y || !y && o === "fixed") && (_ = i.offsetLeft, d = i.offsetTop);
1241
1358
  }
1242
- return { width: c, height: u, x: m, y: d };
1243
- }(t, e)) : K(n) ? function(l, o) {
1244
- const s = Z(l, !1, o === "fixed"), i = s.top + l.clientTop, a = s.left + l.clientLeft;
1245
- return { top: i, left: a, x: a, y: i, right: a + l.clientWidth, bottom: i + l.clientHeight, width: l.clientWidth, height: l.clientHeight };
1246
- }(n, e) : ae(function(l) {
1359
+ return { width: r, height: u, x: _, y: d };
1360
+ }(t, e)) : K(n) ? function(a, o) {
1361
+ const l = X(a, !1, o === "fixed"), s = l.top + a.clientTop, i = l.left + a.clientLeft;
1362
+ return { top: s, left: i, x: i, y: s, right: i + a.clientWidth, bottom: s + a.clientHeight, width: a.clientWidth, height: a.clientHeight };
1363
+ }(n, e) : ie(function(a) {
1247
1364
  var o;
1248
- const s = P(l), i = fe(l), a = (o = l.ownerDocument) == null ? void 0 : o.body, c = J(s.scrollWidth, s.clientWidth, a ? a.scrollWidth : 0, a ? a.clientWidth : 0), u = J(s.scrollHeight, s.clientHeight, a ? a.scrollHeight : 0, a ? a.clientHeight : 0);
1249
- let m = -i.scrollLeft + Ee(l);
1250
- const d = -i.scrollTop;
1251
- return V(a || s).direction === "rtl" && (m += J(s.clientWidth, a ? a.clientWidth : 0) - c), { width: c, height: u, x: m, y: d };
1252
- }(P(t)));
1365
+ const l = F(a), s = pe(a), i = (o = a.ownerDocument) == null ? void 0 : o.body, r = ee(l.scrollWidth, l.clientWidth, i ? i.scrollWidth : 0, i ? i.clientWidth : 0), u = ee(l.scrollHeight, l.clientHeight, i ? i.scrollHeight : 0, i ? i.clientHeight : 0);
1366
+ let _ = -s.scrollLeft + Oe(a);
1367
+ const d = -s.scrollTop;
1368
+ return H(i || l).direction === "rtl" && (_ += ee(l.clientWidth, i ? i.clientWidth : 0) - r), { width: r, height: u, x: _, y: d };
1369
+ }(F(t)));
1253
1370
  }
1254
- const an = { getClippingRect: function(t) {
1255
- let { element: n, boundary: e, rootBoundary: l, strategy: o } = t;
1256
- const s = e === "clippingAncestors" ? function(u) {
1257
- let m = Ve(u).filter((h) => K(h) && U(h) !== "body"), d = null;
1258
- const y = V(u).position === "fixed";
1259
- let g = y ? q(u) : u;
1371
+ const yn = { getClippingRect: function(t) {
1372
+ let { element: n, boundary: e, rootBoundary: a, strategy: o } = t;
1373
+ const l = e === "clippingAncestors" ? function(u) {
1374
+ let _ = He(u).filter((b) => K(b) && Z(b) !== "body"), d = null;
1375
+ const y = H(u).position === "fixed";
1376
+ let g = y ? te(u) : u;
1260
1377
  for (; K(g) && !ve(g); ) {
1261
- const h = V(g), f = me(g);
1262
- (y ? f || d : f || h.position !== "static" || !d || !["absolute", "fixed"].includes(d.position)) ? d = h : m = m.filter((r) => r !== g), g = q(g);
1378
+ const b = H(g), h = _e(g);
1379
+ (y ? h || d : h || b.position !== "static" || !d || !["absolute", "fixed"].includes(d.position)) ? d = b : _ = _.filter((c) => c !== g), g = te(g);
1263
1380
  }
1264
- return m;
1265
- }(n) : [].concat(e), i = [...s, l], a = i[0], c = i.reduce((u, m) => {
1266
- const d = Ie(n, m, o);
1267
- return u.top = J(d.top, u.top), u.right = Te(d.right, u.right), u.bottom = Te(d.bottom, u.bottom), u.left = J(d.left, u.left), u;
1268
- }, Ie(n, a, o));
1269
- return { width: c.right - c.left, height: c.bottom - c.top, x: c.left, y: c.top };
1381
+ return _;
1382
+ }(n) : [].concat(e), s = [...l, a], i = s[0], r = s.reduce((u, _) => {
1383
+ const d = Ie(n, _, o);
1384
+ return u.top = ee(d.top, u.top), u.right = ze(d.right, u.right), u.bottom = ze(d.bottom, u.bottom), u.left = ee(d.left, u.left), u;
1385
+ }, Ie(n, i, o));
1386
+ return { width: r.right - r.left, height: r.bottom - r.top, x: r.left, y: r.top };
1270
1387
  }, convertOffsetParentRelativeRectToViewportRelativeRect: function(t) {
1271
- let { rect: n, offsetParent: e, strategy: l } = t;
1272
- const o = H(e), s = P(e);
1273
- if (e === s)
1388
+ let { rect: n, offsetParent: e, strategy: a } = t;
1389
+ const o = S(e), l = F(e);
1390
+ if (e === l)
1274
1391
  return n;
1275
- let i = { scrollLeft: 0, scrollTop: 0 };
1276
- const a = { x: 0, y: 0 };
1277
- if ((o || !o && l !== "fixed") && ((U(e) !== "body" || ue(s)) && (i = fe(e)), H(e))) {
1278
- const c = Z(e, !0);
1279
- a.x = c.x + e.clientLeft, a.y = c.y + e.clientTop;
1392
+ let s = { scrollLeft: 0, scrollTop: 0 };
1393
+ const i = { x: 0, y: 0 };
1394
+ if ((o || !o && a !== "fixed") && ((Z(e) !== "body" || fe(l)) && (s = pe(e)), S(e))) {
1395
+ const r = X(e, !0);
1396
+ i.x = r.x + e.clientLeft, i.y = r.y + e.clientTop;
1280
1397
  }
1281
- return { ...n, x: n.x - i.scrollLeft + a.x, y: n.y - i.scrollTop + a.y };
1398
+ return { ...n, x: n.x - s.scrollLeft + i.x, y: n.y - s.scrollTop + i.y };
1282
1399
  }, isElement: K, getDimensions: function(t) {
1283
- if (H(t))
1400
+ if (S(t))
1284
1401
  return { width: t.offsetWidth, height: t.offsetHeight };
1285
- const n = Z(t);
1402
+ const n = X(t);
1286
1403
  return { width: n.width, height: n.height };
1287
- }, getOffsetParent: Re, getDocumentElement: P, async getElementRects(t) {
1288
- let { reference: n, floating: e, strategy: l } = t;
1289
- const o = this.getOffsetParent || Re, s = this.getDimensions;
1290
- return { reference: sn(n, await o(e), l), floating: { x: 0, y: 0, ...await s(e) } };
1291
- }, getClientRects: (t) => Array.from(t.getClientRects()), isRTL: (t) => V(t).direction === "rtl" }, rn = (t, n, e) => Ut(t, n, { platform: an, ...e });
1292
- function pe({ value: t }, { value: n }, { value: e }, l, o, s) {
1293
- !t || !n || rn(t, n, {
1294
- placement: l,
1404
+ }, getOffsetParent: Re, getDocumentElement: F, async getElementRects(t) {
1405
+ let { reference: n, floating: e, strategy: a } = t;
1406
+ const o = this.getOffsetParent || Re, l = this.getDimensions;
1407
+ return { reference: bn(n, await o(e), a), floating: { x: 0, y: 0, ...await l(e) } };
1408
+ }, getClientRects: (t) => Array.from(t.getClientRects()), isRTL: (t) => H(t).direction === "rtl" }, kn = (t, n, e) => ln(t, n, { platform: yn, ...e });
1409
+ function he({ value: t }, { value: n }, { value: e }, a, o, l) {
1410
+ !t || !n || kn(t, n, {
1411
+ placement: a,
1295
1412
  middleware: [
1296
- tn(o),
1297
- on({ padding: s }),
1298
- Xt({ element: e }),
1299
- qt(),
1300
- en()
1413
+ mn(o),
1414
+ gn({ padding: l }),
1415
+ cn({ element: e }),
1416
+ pn(),
1417
+ hn()
1301
1418
  ]
1302
- }).then(({ x: i, y: a, placement: c, middlewareData: u }) => {
1419
+ }).then(({ x: s, y: i, placement: r, middlewareData: u }) => {
1303
1420
  if (Object.assign(n.style, {
1304
- left: `${i}px`,
1305
- top: `${a}px`
1421
+ left: `${s}px`,
1422
+ top: `${i}px`
1306
1423
  }), e && u.arrow) {
1307
- const { x: m, y: d } = u.arrow, y = {
1424
+ const { x: _, y: d } = u.arrow, y = {
1308
1425
  top: "bottom",
1309
1426
  right: "left",
1310
1427
  bottom: "top",
1311
1428
  left: "right"
1312
1429
  /* Right */
1313
- }[c.split("-")[0]];
1430
+ }[r.split("-")[0]];
1314
1431
  Object.assign(e.style, {
1315
- left: i != null ? `${m}px` : "",
1316
- top: a != null ? `${d}px` : "",
1432
+ left: s != null ? `${_}px` : "",
1433
+ top: i != null ? `${d}px` : "",
1317
1434
  right: "",
1318
1435
  bottom: "",
1319
1436
  [`${y}`]: "-4px"
@@ -1321,15 +1438,15 @@ function pe({ value: t }, { value: n }, { value: e }, l, o, s) {
1321
1438
  }
1322
1439
  });
1323
1440
  }
1324
- var He = /* @__PURE__ */ ((t) => (t.Top = "top", t.Bottom = "bottom", t.Left = "left", t.Right = "right", t.TopStart = "top-start", t.TopEnd = "top-end", t.RightStart = "right-start", t.RightEnd = "right-end", t.BottomStart = "bottom-start", t.BottomEnd = "bottom-end", t.LeftStart = "left-start", t.LeftEnd = "left-end", t))(He || {}), Y = /* @__PURE__ */ ((t) => (t.Click = "click", t.Hover = "hover", t.Manual = "manual", t))(Y || {});
1325
- const cn = ["aria-disabled", "onClick", "onMouseenter", "onMouseleave", "onMousemove"], dn = ["innerHTML"], un = /* @__PURE__ */ N({
1441
+ var Se = /* @__PURE__ */ ((t) => (t.Top = "top", t.Bottom = "bottom", t.Left = "left", t.Right = "right", t.TopStart = "top-start", t.TopEnd = "top-end", t.RightStart = "right-start", t.RightEnd = "right-end", t.BottomStart = "bottom-start", t.BottomEnd = "bottom-end", t.LeftStart = "left-start", t.LeftEnd = "left-end", t))(Se || {}), P = /* @__PURE__ */ ((t) => (t.Click = "click", t.Hover = "hover", t.Manual = "manual", t))(P || {});
1442
+ const xn = ["aria-disabled", "onClick", "onMouseenter", "onMouseleave", "onMousemove"], wn = ["innerHTML"], $n = /* @__PURE__ */ I({
1326
1443
  __name: "RTooltip",
1327
1444
  props: {
1328
- placement: { default: He.Top },
1445
+ placement: { default: Se.Top },
1329
1446
  text: { default: "" },
1330
1447
  dark: { type: Boolean, default: !0 },
1331
1448
  light: { type: Boolean, default: !1 },
1332
- triggers: { default: Y.Hover },
1449
+ triggers: { default: P.Hover },
1333
1450
  autoHide: { type: Boolean, default: !0 },
1334
1451
  hideDelay: { default: 3e3 },
1335
1452
  showDelay: { default: 0 },
@@ -1344,92 +1461,92 @@ const cn = ["aria-disabled", "onClick", "onMouseenter", "onMouseleave", "onMouse
1344
1461
  emits: ["show", "hide"],
1345
1462
  setup(t, { emit: n }) {
1346
1463
  const e = t;
1347
- Xe((r) => ({
1348
- "271323d4": x(f)
1464
+ Ke((c) => ({
1465
+ "271323d4": w(h)
1349
1466
  }));
1350
- const l = E(null), o = E(null), s = E(null);
1351
- function i() {
1352
- const { placement: r, offset: v, padding: $, disabled: M } = e;
1353
- M || (o.value.style.display = "block", n("show"), pe(l, o, s, r, v, $), c(), e.outsideClick && u("add"));
1467
+ const a = E(null), o = E(null), l = E(null);
1468
+ function s() {
1469
+ const { placement: c, offset: p, padding: k, disabled: M } = e;
1470
+ M || (o.value.style.display = "block", n("show"), he(a, o, l, c, p, k), r(), e.outsideClick && u("add"));
1354
1471
  }
1355
- function a() {
1472
+ function i() {
1356
1473
  o.value.style.display = "", n("hide"), e.outsideClick && u("remove");
1357
1474
  }
1358
- const c = () => {
1475
+ const r = () => {
1359
1476
  e.autoHide && setTimeout(() => {
1360
- a();
1477
+ i();
1361
1478
  }, e.hideDelay);
1362
- }, u = (r) => {
1363
- r === "add" && document.addEventListener("click", a), r === "remove" && document.removeEventListener("click", a);
1364
- }, m = () => {
1365
- e.disabled || e.triggers == Y.Click && (o.value.style.display === "block" ? a() : i());
1479
+ }, u = (c) => {
1480
+ c === "add" && document.addEventListener("click", i), c === "remove" && document.removeEventListener("click", i);
1481
+ }, _ = () => {
1482
+ e.disabled || e.triggers == P.Click && (o.value.style.display === "block" ? i() : s());
1366
1483
  }, d = () => {
1367
- e.disabled || e.triggers === Y.Hover && i();
1484
+ e.disabled || e.triggers === P.Hover && s();
1368
1485
  }, y = () => {
1369
1486
  if (!e.disabled)
1370
- if (o.value.style.display === "" && e.triggers === Y.Hover) {
1371
- i();
1487
+ if (o.value.style.display === "" && e.triggers === P.Hover) {
1488
+ s();
1372
1489
  return;
1373
1490
  } else
1374
- o.value.style.display !== "" && e.triggers === Y.Hover && a();
1491
+ o.value.style.display !== "" && e.triggers === P.Hover && i();
1375
1492
  }, g = () => {
1376
- const { placement: r, offset: v, padding: $, disabled: M } = e;
1377
- M || e.triggers === Y.Hover && pe(l, o, s, r, v, $);
1378
- }, h = w(() => ({
1493
+ const { placement: c, offset: p, padding: k, disabled: M } = e;
1494
+ M || e.triggers === P.Hover && he(a, o, l, c, p, k);
1495
+ }, b = $(() => ({
1379
1496
  tooltip: !0,
1380
1497
  "tooltip--dark": e.dark,
1381
1498
  "tooltip--light": e.light
1382
1499
  }));
1383
1500
  window.onresize = () => {
1384
- const { placement: r, offset: v, padding: $, disabled: M } = e;
1385
- M || e.resizable && pe(l, o, s, r, v, $);
1386
- }, Ke(
1501
+ const { placement: c, offset: p, padding: k, disabled: M } = e;
1502
+ M || e.resizable && he(a, o, l, c, p, k);
1503
+ }, Ge(
1387
1504
  () => {
1388
- e.disabled || e.shown && e.triggers === Y.Manual && i();
1505
+ e.disabled || e.shown && e.triggers === P.Manual && s();
1389
1506
  },
1390
1507
  { flush: "post" }
1391
1508
  // this is important to avoid infinite loop & for fire on mounted
1392
1509
  );
1393
- const f = w(() => `${e.showDelay}ms`);
1394
- return (r, v) => (p(), _(X, null, [
1395
- b("div", {
1510
+ const h = $(() => `${e.showDelay}ms`);
1511
+ return (c, p) => (f(), m(Q, null, [
1512
+ v("div", {
1396
1513
  ref_key: "trigger",
1397
- ref: l,
1514
+ ref: a,
1398
1515
  "aria-disabled": e.disabled,
1399
1516
  class: "trigger",
1400
- onClick: W(m, ["stop"]),
1401
- onMouseenter: W(d, ["stop"]),
1402
- onMouseleave: W(y, ["stop"]),
1403
- onMousemove: W(g, ["stop"])
1517
+ onClick: V(_, ["stop"]),
1518
+ onMouseenter: V(d, ["stop"]),
1519
+ onMouseleave: V(y, ["stop"]),
1520
+ onMousemove: V(g, ["stop"])
1404
1521
  }, [
1405
- O(r.$slots, "trigger", {}, void 0, !0),
1406
- r.$slots.trigger ? T("", !0) : (p(), _("div", {
1522
+ D(c.$slots, "trigger", {}, void 0, !0),
1523
+ c.$slots.trigger ? R("", !0) : (f(), m("div", {
1407
1524
  key: 0,
1408
1525
  innerHTML: e.triggerContent
1409
- }, null, 8, dn))
1410
- ], 40, cn),
1411
- b("div", {
1526
+ }, null, 8, wn))
1527
+ ], 40, xn),
1528
+ v("div", {
1412
1529
  id: "tooltip",
1413
1530
  ref_key: "tooltip",
1414
1531
  ref: o,
1415
- class: k(x(h)),
1532
+ class: x(w(b)),
1416
1533
  role: "tooltip"
1417
1534
  }, [
1418
- O(r.$slots, "content", {}, void 0, !0),
1419
- r.$slots.content ? T("", !0) : (p(), _("div", {
1535
+ D(c.$slots, "content", {}, void 0, !0),
1536
+ c.$slots.content ? R("", !0) : (f(), m("div", {
1420
1537
  key: 0,
1421
- class: k({
1538
+ class: x({
1422
1539
  tooltip__content: !0,
1423
1540
  "tooltip__content--dark": e.dark,
1424
1541
  "tooltip__content--light": e.light
1425
1542
  })
1426
1543
  }, C(e.text), 3)),
1427
- r.$slots.content ? T("", !0) : (p(), _("div", {
1544
+ c.$slots.content ? R("", !0) : (f(), m("div", {
1428
1545
  key: 1,
1429
1546
  id: "arrow",
1430
1547
  ref_key: "arrowElement",
1431
- ref: s,
1432
- class: k({
1548
+ ref: l,
1549
+ class: x({
1433
1550
  tooltip__arrow: !0,
1434
1551
  "tooltip__arrow--dark": e.dark,
1435
1552
  "tooltip__arrow--light": e.light
@@ -1439,27 +1556,29 @@ const cn = ["aria-disabled", "onClick", "onMouseenter", "onMouseleave", "onMouse
1439
1556
  ], 64));
1440
1557
  }
1441
1558
  });
1442
- const fn = (t, n) => {
1559
+ const Mn = (t, n) => {
1443
1560
  const e = t.__vccOpts || t;
1444
- for (const [l, o] of n)
1445
- e[l] = o;
1561
+ for (const [a, o] of n)
1562
+ e[a] = o;
1446
1563
  return e;
1447
- }, $n = /* @__PURE__ */ fn(un, [["__scopeId", "data-v-ee5f5651"]]);
1564
+ }, Vn = /* @__PURE__ */ Mn($n, [["__scopeId", "data-v-ee5f5651"]]);
1448
1565
  export {
1449
- hn as RAlert,
1450
- mn as RAvatar,
1451
- gn as RBadge,
1452
- at as RButton,
1453
- _n as RCheckbox,
1454
- mt as RChip,
1455
- vn as RDropdown,
1456
- B as RIcon,
1566
+ zn as RAccordion,
1567
+ Cn as RAlert,
1568
+ Rn as RAvatar,
1569
+ In as RBadge,
1570
+ ut as RButton,
1571
+ An as RCheckbox,
1572
+ yt as RChip,
1573
+ Ln as RDropdown,
1574
+ N as RIcon,
1457
1575
  Le as RLabel,
1458
- bn as RSnackbar,
1459
- yn as RSwitch,
1460
- Dt as RTabItem,
1461
- xn as RTabs,
1462
- kn as RTextArea,
1463
- wn as RTextfield,
1464
- $n as RTooltip
1576
+ Nn as RModal,
1577
+ Bn as RSnackbar,
1578
+ Dn as RSwitch,
1579
+ Zt as RTabItem,
1580
+ jn as RTabs,
1581
+ En as RTextArea,
1582
+ On as RTextfield,
1583
+ Vn as RTooltip
1465
1584
  };