energy-components 1.13.0 → 1.14.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 (39) hide show
  1. package/dist/components/breadcrumbs.es.js +59 -40
  2. package/dist/components/dropdown.es.js +201 -152
  3. package/dist/components/indicator.es.js +8 -8
  4. package/dist/components/multiselect.es.js +15 -11
  5. package/dist/components/style/accordion.css +1 -1
  6. package/dist/components/style/actionButton.css +1 -1
  7. package/dist/components/style/breadcrumbs.css +1 -1
  8. package/dist/components/style/button.css +1 -1
  9. package/dist/components/style/checkbox.css +1 -1
  10. package/dist/components/style/collapsable.css +1 -1
  11. package/dist/components/style/directAccess.css +1 -1
  12. package/dist/components/style/dragAndDrop.css +1 -1
  13. package/dist/components/style/dropdown.css +1 -1
  14. package/dist/components/style/filterChip.css +1 -1
  15. package/dist/components/style/filterTag.css +1 -1
  16. package/dist/components/style/indicator.css +1 -1
  17. package/dist/components/style/infoBox.css +1 -1
  18. package/dist/components/style/link.css +1 -1
  19. package/dist/components/style/multiselect.css +1 -1
  20. package/dist/components/style/persistentToast.css +1 -1
  21. package/dist/components/style/progressBar.css +1 -1
  22. package/dist/components/style/quantitySelector.css +1 -1
  23. package/dist/components/style/radioButton.css +1 -1
  24. package/dist/components/style/selectionChip.css +1 -1
  25. package/dist/components/style/switch.css +1 -1
  26. package/dist/components/style/tableslotedcomponent.css +1 -1
  27. package/dist/components/style/tag.css +1 -1
  28. package/dist/components/style/textArea.css +1 -1
  29. package/dist/components/style/textField.css +1 -1
  30. package/dist/components/style/tooltip.css +1 -1
  31. package/dist/components/tooltip.es.js +344 -325
  32. package/dist/energy-components.es.js +4874 -4783
  33. package/dist/energy-components.umd.js +2 -2
  34. package/dist/style.css +1 -1
  35. package/dist/types/src/components/input/dropdown/dropdown.vue.d.ts +58 -13
  36. package/dist/types/src/components/navigation/breadcrumbs/breadcrumbs.vue.d.ts +15 -0
  37. package/dist/types/src/components/overlay/tooltip/tooltip.vue.d.ts +15 -0
  38. package/dist/types/tsconfig.tsbuildinfo +1 -1
  39. package/package.json +2 -2
@@ -1,15 +1,15 @@
1
- import { unref as at, defineComponent as Ft, toRefs as Ht, ref as U, computed as jt, createElementBlock as vt, openBlock as bt, createElementVNode as Z, renderSlot as At, normalizeClass as Rt, createCommentVNode as It, createVNode as Yt, toDisplayString as Ct, createTextVNode as zt } from "vue";
2
- import { R as Xt } from "./icon-svg-DuzOdbk1.js";
3
- import { _ as Kt } from "./_plugin-vue_export-helper-CHgC5LLL.js";
4
- import './style/tooltip.css';const X = Math.min, S = Math.max, nt = Math.round, $ = (t) => ({
1
+ import { unref as at, defineComponent as jt, toRefs as It, ref as U, computed as Yt, createElementBlock as vt, openBlock as bt, createElementVNode as Z, renderSlot as At, normalizeClass as Ct, createCommentVNode as zt, createVNode as Xt, toDisplayString as Rt, createTextVNode as Kt } from "vue";
2
+ import { R as qt } from "./icon-svg-DuzOdbk1.js";
3
+ import { _ as Gt } from "./_plugin-vue_export-helper-CHgC5LLL.js";
4
+ import './style/tooltip.css';const X = Math.min, S = Math.max, nt = Math.round, N = (t) => ({
5
5
  x: t,
6
6
  y: t
7
- }), qt = {
7
+ }), Jt = {
8
8
  left: "right",
9
9
  right: "left",
10
10
  bottom: "top",
11
11
  top: "bottom"
12
- }, Gt = {
12
+ }, Qt = {
13
13
  start: "end",
14
14
  end: "start"
15
15
  };
@@ -25,53 +25,54 @@ function I(t) {
25
25
  function Q(t) {
26
26
  return t.split("-")[1];
27
27
  }
28
- function Dt(t) {
28
+ function Lt(t) {
29
29
  return t === "x" ? "y" : "x";
30
30
  }
31
31
  function mt(t) {
32
32
  return t === "y" ? "height" : "width";
33
33
  }
34
- function V(t) {
35
- return ["top", "bottom"].includes(I(t)) ? "y" : "x";
34
+ const Ut = /* @__PURE__ */ new Set(["top", "bottom"]);
35
+ function B(t) {
36
+ return Ut.has(I(t)) ? "y" : "x";
36
37
  }
37
38
  function pt(t) {
38
- return Dt(V(t));
39
+ return Lt(B(t));
39
40
  }
40
- function Jt(t, e, o) {
41
+ function Zt(t, e, o) {
41
42
  o === void 0 && (o = !1);
42
43
  const n = Q(t), i = pt(t), r = mt(i);
43
44
  let s = i === "x" ? n === (o ? "end" : "start") ? "right" : "left" : n === "start" ? "bottom" : "top";
44
45
  return e.reference[r] > e.floating[r] && (s = ot(s)), [s, ot(s)];
45
46
  }
46
- function Qt(t) {
47
+ function te(t) {
47
48
  const e = ot(t);
48
49
  return [ut(t), e, ut(e)];
49
50
  }
50
51
  function ut(t) {
51
- return t.replace(/start|end/g, (e) => Gt[e]);
52
+ return t.replace(/start|end/g, (e) => Qt[e]);
52
53
  }
53
- function Ut(t, e, o) {
54
- const n = ["left", "right"], i = ["right", "left"], r = ["top", "bottom"], s = ["bottom", "top"];
54
+ const Ot = ["left", "right"], St = ["right", "left"], ee = ["top", "bottom"], ne = ["bottom", "top"];
55
+ function oe(t, e, o) {
55
56
  switch (t) {
56
57
  case "top":
57
58
  case "bottom":
58
- return o ? e ? i : n : e ? n : i;
59
+ return o ? e ? St : Ot : e ? Ot : St;
59
60
  case "left":
60
61
  case "right":
61
- return e ? r : s;
62
+ return e ? ee : ne;
62
63
  default:
63
64
  return [];
64
65
  }
65
66
  }
66
- function Zt(t, e, o, n) {
67
+ function ie(t, e, o, n) {
67
68
  const i = Q(t);
68
- let r = Ut(I(t), o === "start", n);
69
+ let r = oe(I(t), o === "start", n);
69
70
  return i && (r = r.map((s) => s + "-" + i), e && (r = r.concat(r.map(ut)))), r;
70
71
  }
71
72
  function ot(t) {
72
- return t.replace(/left|right|bottom|top/g, (e) => qt[e]);
73
+ return t.replace(/left|right|bottom|top/g, (e) => Jt[e]);
73
74
  }
74
- function te(t) {
75
+ function se(t) {
75
76
  return {
76
77
  top: 0,
77
78
  right: 0,
@@ -80,8 +81,8 @@ function te(t) {
80
81
  ...t
81
82
  };
82
83
  }
83
- function Lt(t) {
84
- return typeof t != "number" ? te(t) : {
84
+ function Et(t) {
85
+ return typeof t != "number" ? se(t) : {
85
86
  top: t,
86
87
  right: t,
87
88
  bottom: t,
@@ -106,14 +107,14 @@ function it(t) {
106
107
  y: o
107
108
  };
108
109
  }
109
- function Ot(t, e, o) {
110
+ function _t(t, e, o) {
110
111
  let {
111
112
  reference: n,
112
113
  floating: i
113
114
  } = t;
114
- const r = V(e), s = pt(e), l = mt(s), c = I(e), a = r === "y", f = n.x + n.width / 2 - i.width / 2, u = n.y + n.height / 2 - i.height / 2, p = n[l] / 2 - i[l] / 2;
115
+ const r = B(e), s = pt(e), l = mt(s), a = I(e), c = r === "y", f = n.x + n.width / 2 - i.width / 2, u = n.y + n.height / 2 - i.height / 2, p = n[l] / 2 - i[l] / 2;
115
116
  let d;
116
- switch (c) {
117
+ switch (a) {
117
118
  case "top":
118
119
  d = {
119
120
  x: f,
@@ -146,34 +147,34 @@ function Ot(t, e, o) {
146
147
  }
147
148
  switch (Q(e)) {
148
149
  case "start":
149
- d[s] -= p * (o && a ? -1 : 1);
150
+ d[s] -= p * (o && c ? -1 : 1);
150
151
  break;
151
152
  case "end":
152
- d[s] += p * (o && a ? -1 : 1);
153
+ d[s] += p * (o && c ? -1 : 1);
153
154
  break;
154
155
  }
155
156
  return d;
156
157
  }
157
- const ee = async (t, e, o) => {
158
+ const re = async (t, e, o) => {
158
159
  const {
159
160
  placement: n = "bottom",
160
161
  strategy: i = "absolute",
161
162
  middleware: r = [],
162
163
  platform: s
163
- } = o, l = r.filter(Boolean), c = await (s.isRTL == null ? void 0 : s.isRTL(e));
164
- let a = await s.getElementRects({
164
+ } = o, l = r.filter(Boolean), a = await (s.isRTL == null ? void 0 : s.isRTL(e));
165
+ let c = await s.getElementRects({
165
166
  reference: t,
166
167
  floating: e,
167
168
  strategy: i
168
169
  }), {
169
170
  x: f,
170
171
  y: u
171
- } = Ot(a, n, c), p = n, d = {}, m = 0;
172
- for (let g = 0; g < l.length; g++) {
172
+ } = _t(c, n, a), p = n, d = {}, m = 0;
173
+ for (let h = 0; h < l.length; h++) {
173
174
  const {
174
- name: h,
175
+ name: g,
175
176
  fn: w
176
- } = l[g], {
177
+ } = l[h], {
177
178
  x,
178
179
  y,
179
180
  data: b,
@@ -185,7 +186,7 @@ const ee = async (t, e, o) => {
185
186
  placement: p,
186
187
  strategy: i,
187
188
  middlewareData: d,
188
- rects: a,
189
+ rects: c,
189
190
  platform: s,
190
191
  elements: {
191
192
  reference: t,
@@ -194,18 +195,18 @@ const ee = async (t, e, o) => {
194
195
  });
195
196
  f = x ?? f, u = y ?? u, d = {
196
197
  ...d,
197
- [h]: {
198
- ...d[h],
198
+ [g]: {
199
+ ...d[g],
199
200
  ...b
200
201
  }
201
- }, v && m <= 50 && (m++, typeof v == "object" && (v.placement && (p = v.placement), v.rects && (a = v.rects === !0 ? await s.getElementRects({
202
+ }, v && m <= 50 && (m++, typeof v == "object" && (v.placement && (p = v.placement), v.rects && (c = v.rects === !0 ? await s.getElementRects({
202
203
  reference: t,
203
204
  floating: e,
204
205
  strategy: i
205
206
  }) : v.rects), {
206
207
  x: f,
207
208
  y: u
208
- } = Ot(a, p, c)), g = -1);
209
+ } = _t(c, p, a)), h = -1);
209
210
  }
210
211
  return {
211
212
  x: f,
@@ -215,7 +216,7 @@ const ee = async (t, e, o) => {
215
216
  middlewareData: d
216
217
  };
217
218
  };
218
- async function gt(t, e) {
219
+ async function ht(t, e) {
219
220
  var o;
220
221
  e === void 0 && (e = {});
221
222
  const {
@@ -224,18 +225,18 @@ async function gt(t, e) {
224
225
  platform: r,
225
226
  rects: s,
226
227
  elements: l,
227
- strategy: c
228
+ strategy: a
228
229
  } = t, {
229
- boundary: a = "clippingAncestors",
230
+ boundary: c = "clippingAncestors",
230
231
  rootBoundary: f = "viewport",
231
232
  elementContext: u = "floating",
232
233
  altBoundary: p = !1,
233
234
  padding: d = 0
234
- } = J(e, t), m = Lt(d), h = l[p ? u === "floating" ? "reference" : "floating" : u], w = it(await r.getClippingRect({
235
- element: (o = await (r.isElement == null ? void 0 : r.isElement(h))) == null || o ? h : h.contextElement || await (r.getDocumentElement == null ? void 0 : r.getDocumentElement(l.floating)),
236
- boundary: a,
235
+ } = J(e, t), m = Et(d), g = l[p ? u === "floating" ? "reference" : "floating" : u], w = it(await r.getClippingRect({
236
+ element: (o = await (r.isElement == null ? void 0 : r.isElement(g))) == null || o ? g : g.contextElement || await (r.getDocumentElement == null ? void 0 : r.getDocumentElement(l.floating)),
237
+ boundary: c,
237
238
  rootBoundary: f,
238
- strategy: c
239
+ strategy: a
239
240
  })), x = u === "floating" ? {
240
241
  x: n,
241
242
  y: i,
@@ -251,7 +252,7 @@ async function gt(t, e) {
251
252
  elements: l,
252
253
  rect: x,
253
254
  offsetParent: y,
254
- strategy: c
255
+ strategy: a
255
256
  }) : x);
256
257
  return {
257
258
  top: (w.top - v.top + m.top) / b.y,
@@ -260,7 +261,7 @@ async function gt(t, e) {
260
261
  right: (v.right - w.right + m.right) / b.x
261
262
  };
262
263
  }
263
- const ne = (t) => ({
264
+ const le = (t) => ({
264
265
  name: "arrow",
265
266
  options: t,
266
267
  async fn(e) {
@@ -271,33 +272,33 @@ const ne = (t) => ({
271
272
  rects: r,
272
273
  platform: s,
273
274
  elements: l,
274
- middlewareData: c
275
+ middlewareData: a
275
276
  } = e, {
276
- element: a,
277
+ element: c,
277
278
  padding: f = 0
278
279
  } = J(t, e) || {};
279
- if (a == null)
280
+ if (c == null)
280
281
  return {};
281
- const u = Lt(f), p = {
282
+ const u = Et(f), p = {
282
283
  x: o,
283
284
  y: n
284
- }, d = pt(i), m = mt(d), g = await s.getDimensions(a), h = d === "y", w = h ? "top" : "left", x = h ? "bottom" : "right", y = h ? "clientHeight" : "clientWidth", b = r.reference[m] + r.reference[d] - p[d] - r.floating[m], v = p[d] - r.reference[d], E = await (s.getOffsetParent == null ? void 0 : s.getOffsetParent(a));
285
- let R = E ? E[y] : 0;
286
- (!R || !await (s.isElement == null ? void 0 : s.isElement(E))) && (R = l.floating[y] || r.floating[m]);
287
- const W = b / 2 - v / 2, P = R / 2 - g[m] / 2 - 1, O = X(u[w], P), F = X(u[x], P), k = O, H = R - g[m] - F, A = R / 2 - g[m] / 2 + W, z = ft(k, A, H), M = !c.arrow && Q(i) != null && A !== z && r.reference[m] / 2 - (A < k ? O : F) - g[m] / 2 < 0, T = M ? A < k ? A - k : A - H : 0;
285
+ }, d = pt(i), m = mt(d), h = await s.getDimensions(c), g = d === "y", w = g ? "top" : "left", x = g ? "bottom" : "right", y = g ? "clientHeight" : "clientWidth", b = r.reference[m] + r.reference[d] - p[d] - r.floating[m], v = p[d] - r.reference[d], E = await (s.getOffsetParent == null ? void 0 : s.getOffsetParent(c));
286
+ let C = E ? E[y] : 0;
287
+ (!C || !await (s.isElement == null ? void 0 : s.isElement(E))) && (C = l.floating[y] || r.floating[m]);
288
+ const _ = b / 2 - v / 2, k = C / 2 - h[m] / 2 - 1, O = X(u[w], k), F = X(u[x], k), $ = O, H = C - h[m] - F, A = C / 2 - h[m] / 2 + _, z = ft($, A, H), W = !a.arrow && Q(i) != null && A !== z && r.reference[m] / 2 - (A < $ ? O : F) - h[m] / 2 < 0, T = W ? A < $ ? A - $ : A - H : 0;
288
289
  return {
289
290
  [d]: p[d] + T,
290
291
  data: {
291
292
  [d]: z,
292
293
  centerOffset: A - z - T,
293
- ...M && {
294
+ ...W && {
294
295
  alignmentOffset: T
295
296
  }
296
297
  },
297
- reset: M
298
+ reset: W
298
299
  };
299
300
  }
300
- }), oe = function(t) {
301
+ }), ce = function(t) {
301
302
  return t === void 0 && (t = {}), {
302
303
  name: "flip",
303
304
  options: t,
@@ -308,36 +309,36 @@ const ne = (t) => ({
308
309
  middlewareData: r,
309
310
  rects: s,
310
311
  initialPlacement: l,
311
- platform: c,
312
- elements: a
312
+ platform: a,
313
+ elements: c
313
314
  } = e, {
314
315
  mainAxis: f = !0,
315
316
  crossAxis: u = !0,
316
317
  fallbackPlacements: p,
317
318
  fallbackStrategy: d = "bestFit",
318
319
  fallbackAxisSideDirection: m = "none",
319
- flipAlignment: g = !0,
320
- ...h
320
+ flipAlignment: h = !0,
321
+ ...g
321
322
  } = J(t, e);
322
323
  if ((o = r.arrow) != null && o.alignmentOffset)
323
324
  return {};
324
- const w = I(i), x = V(l), y = I(l) === l, b = await (c.isRTL == null ? void 0 : c.isRTL(a.floating)), v = p || (y || !g ? [ot(l)] : Qt(l)), E = m !== "none";
325
- !p && E && v.push(...Zt(l, g, m, b));
326
- const R = [l, ...v], W = await gt(e, h), P = [];
325
+ const w = I(i), x = B(l), y = I(l) === l, b = await (a.isRTL == null ? void 0 : a.isRTL(c.floating)), v = p || (y || !h ? [ot(l)] : te(l)), E = m !== "none";
326
+ !p && E && v.push(...ie(l, h, m, b));
327
+ const C = [l, ...v], _ = await ht(e, g), k = [];
327
328
  let O = ((n = r.flip) == null ? void 0 : n.overflows) || [];
328
- if (f && P.push(W[w]), u) {
329
- const A = Jt(i, s, b);
330
- P.push(W[A[0]], W[A[1]]);
329
+ if (f && k.push(_[w]), u) {
330
+ const A = Zt(i, s, b);
331
+ k.push(_[A[0]], _[A[1]]);
331
332
  }
332
333
  if (O = [...O, {
333
334
  placement: i,
334
- overflows: P
335
- }], !P.every((A) => A <= 0)) {
336
- var F, k;
337
- const A = (((F = r.flip) == null ? void 0 : F.index) || 0) + 1, z = R[A];
338
- if (z && (!(u === "alignment" ? x !== V(z) : !1) || // We leave the current main axis only if every placement on that axis
335
+ overflows: k
336
+ }], !k.every((A) => A <= 0)) {
337
+ var F, $;
338
+ const A = (((F = r.flip) == null ? void 0 : F.index) || 0) + 1, z = C[A];
339
+ if (z && (!(u === "alignment" ? x !== B(z) : !1) || // We leave the current main axis only if every placement on that axis
339
340
  // overflows the main axis.
340
- O.every((_) => _.overflows[0] > 0 && V(_.placement) === x)))
341
+ O.every((D) => D.overflows[0] > 0 && B(D.placement) === x)))
341
342
  return {
342
343
  data: {
343
344
  index: A,
@@ -347,44 +348,44 @@ const ne = (t) => ({
347
348
  placement: z
348
349
  }
349
350
  };
350
- let M = (k = O.filter((T) => T.overflows[0] <= 0).sort((T, _) => T.overflows[1] - _.overflows[1])[0]) == null ? void 0 : k.placement;
351
- if (!M)
351
+ let W = ($ = O.filter((T) => T.overflows[0] <= 0).sort((T, D) => T.overflows[1] - D.overflows[1])[0]) == null ? void 0 : $.placement;
352
+ if (!W)
352
353
  switch (d) {
353
354
  case "bestFit": {
354
355
  var H;
355
- const T = (H = O.filter((_) => {
356
+ const T = (H = O.filter((D) => {
356
357
  if (E) {
357
- const j = V(_.placement);
358
+ const j = B(D.placement);
358
359
  return j === x || // Create a bias to the `y` side axis due to horizontal
359
360
  // reading directions favoring greater width.
360
361
  j === "y";
361
362
  }
362
363
  return !0;
363
- }).map((_) => [_.placement, _.overflows.filter((j) => j > 0).reduce((j, Bt) => j + Bt, 0)]).sort((_, j) => _[1] - j[1])[0]) == null ? void 0 : H[0];
364
- T && (M = T);
364
+ }).map((D) => [D.placement, D.overflows.filter((j) => j > 0).reduce((j, Ht) => j + Ht, 0)]).sort((D, j) => D[1] - j[1])[0]) == null ? void 0 : H[0];
365
+ T && (W = T);
365
366
  break;
366
367
  }
367
368
  case "initialPlacement":
368
- M = l;
369
+ W = l;
369
370
  break;
370
371
  }
371
- if (i !== M)
372
+ if (i !== W)
372
373
  return {
373
374
  reset: {
374
- placement: M
375
+ placement: W
375
376
  }
376
377
  };
377
378
  }
378
379
  return {};
379
380
  }
380
381
  };
381
- };
382
- async function ie(t, e) {
382
+ }, ae = /* @__PURE__ */ new Set(["left", "top"]);
383
+ async function fe(t, e) {
383
384
  const {
384
385
  placement: o,
385
386
  platform: n,
386
387
  elements: i
387
- } = t, r = await (n.isRTL == null ? void 0 : n.isRTL(i.floating)), s = I(o), l = Q(o), c = V(o) === "y", a = ["left", "top"].includes(s) ? -1 : 1, f = r && c ? -1 : 1, u = J(e, t);
388
+ } = t, r = await (n.isRTL == null ? void 0 : n.isRTL(i.floating)), s = I(o), l = Q(o), a = B(o) === "y", c = ae.has(s) ? -1 : 1, f = r && a ? -1 : 1, u = J(e, t);
388
389
  let {
389
390
  mainAxis: p,
390
391
  crossAxis: d,
@@ -398,15 +399,15 @@ async function ie(t, e) {
398
399
  crossAxis: u.crossAxis || 0,
399
400
  alignmentAxis: u.alignmentAxis
400
401
  };
401
- return l && typeof m == "number" && (d = l === "end" ? m * -1 : m), c ? {
402
+ return l && typeof m == "number" && (d = l === "end" ? m * -1 : m), a ? {
402
403
  x: d * f,
403
- y: p * a
404
+ y: p * c
404
405
  } : {
405
- x: p * a,
406
+ x: p * c,
406
407
  y: d * f
407
408
  };
408
409
  }
409
- const se = function(t) {
410
+ const ue = function(t) {
410
411
  return t === void 0 && (t = 0), {
411
412
  name: "offset",
412
413
  options: t,
@@ -417,18 +418,18 @@ const se = function(t) {
417
418
  y: r,
418
419
  placement: s,
419
420
  middlewareData: l
420
- } = e, c = await ie(e, t);
421
+ } = e, a = await fe(e, t);
421
422
  return s === ((o = l.offset) == null ? void 0 : o.placement) && (n = l.arrow) != null && n.alignmentOffset ? {} : {
422
- x: i + c.x,
423
- y: r + c.y,
423
+ x: i + a.x,
424
+ y: r + a.y,
424
425
  data: {
425
- ...c,
426
+ ...a,
426
427
  placement: s
427
428
  }
428
429
  };
429
430
  }
430
431
  };
431
- }, re = function(t) {
432
+ }, de = function(t) {
432
433
  return t === void 0 && (t = {}), {
433
434
  name: "shift",
434
435
  options: t,
@@ -441,41 +442,41 @@ const se = function(t) {
441
442
  mainAxis: r = !0,
442
443
  crossAxis: s = !1,
443
444
  limiter: l = {
444
- fn: (h) => {
445
+ fn: (g) => {
445
446
  let {
446
447
  x: w,
447
448
  y: x
448
- } = h;
449
+ } = g;
449
450
  return {
450
451
  x: w,
451
452
  y: x
452
453
  };
453
454
  }
454
455
  },
455
- ...c
456
- } = J(t, e), a = {
456
+ ...a
457
+ } = J(t, e), c = {
457
458
  x: o,
458
459
  y: n
459
- }, f = await gt(e, c), u = V(I(i)), p = Dt(u);
460
- let d = a[p], m = a[u];
460
+ }, f = await ht(e, a), u = B(I(i)), p = Lt(u);
461
+ let d = c[p], m = c[u];
461
462
  if (r) {
462
- const h = p === "y" ? "top" : "left", w = p === "y" ? "bottom" : "right", x = d + f[h], y = d - f[w];
463
+ const g = p === "y" ? "top" : "left", w = p === "y" ? "bottom" : "right", x = d + f[g], y = d - f[w];
463
464
  d = ft(x, d, y);
464
465
  }
465
466
  if (s) {
466
- const h = u === "y" ? "top" : "left", w = u === "y" ? "bottom" : "right", x = m + f[h], y = m - f[w];
467
+ const g = u === "y" ? "top" : "left", w = u === "y" ? "bottom" : "right", x = m + f[g], y = m - f[w];
467
468
  m = ft(x, m, y);
468
469
  }
469
- const g = l.fn({
470
+ const h = l.fn({
470
471
  ...e,
471
472
  [p]: d,
472
473
  [u]: m
473
474
  });
474
475
  return {
475
- ...g,
476
+ ...h,
476
477
  data: {
477
- x: g.x - o,
478
- y: g.y - n,
478
+ x: h.x - o,
479
+ y: h.y - n,
479
480
  enabled: {
480
481
  [p]: r,
481
482
  [u]: s
@@ -484,7 +485,7 @@ const se = function(t) {
484
485
  };
485
486
  }
486
487
  };
487
- }, le = function(t) {
488
+ }, me = function(t) {
488
489
  return t === void 0 && (t = {}), {
489
490
  name: "size",
490
491
  options: t,
@@ -496,28 +497,28 @@ const se = function(t) {
496
497
  platform: s,
497
498
  elements: l
498
499
  } = e, {
499
- apply: c = () => {
500
+ apply: a = () => {
500
501
  },
501
- ...a
502
- } = J(t, e), f = await gt(e, a), u = I(i), p = Q(i), d = V(i) === "y", {
502
+ ...c
503
+ } = J(t, e), f = await ht(e, c), u = I(i), p = Q(i), d = B(i) === "y", {
503
504
  width: m,
504
- height: g
505
+ height: h
505
506
  } = r.floating;
506
- let h, w;
507
- u === "top" || u === "bottom" ? (h = u, w = p === (await (s.isRTL == null ? void 0 : s.isRTL(l.floating)) ? "start" : "end") ? "left" : "right") : (w = u, h = p === "end" ? "top" : "bottom");
508
- const x = g - f.top - f.bottom, y = m - f.left - f.right, b = X(g - f[h], x), v = X(m - f[w], y), E = !e.middlewareData.shift;
509
- let R = b, W = v;
510
- if ((o = e.middlewareData.shift) != null && o.enabled.x && (W = y), (n = e.middlewareData.shift) != null && n.enabled.y && (R = x), E && !p) {
511
- const O = S(f.left, 0), F = S(f.right, 0), k = S(f.top, 0), H = S(f.bottom, 0);
512
- d ? W = m - 2 * (O !== 0 || F !== 0 ? O + F : S(f.left, f.right)) : R = g - 2 * (k !== 0 || H !== 0 ? k + H : S(f.top, f.bottom));
507
+ let g, w;
508
+ u === "top" || u === "bottom" ? (g = u, w = p === (await (s.isRTL == null ? void 0 : s.isRTL(l.floating)) ? "start" : "end") ? "left" : "right") : (w = u, g = p === "end" ? "top" : "bottom");
509
+ const x = h - f.top - f.bottom, y = m - f.left - f.right, b = X(h - f[g], x), v = X(m - f[w], y), E = !e.middlewareData.shift;
510
+ let C = b, _ = v;
511
+ if ((o = e.middlewareData.shift) != null && o.enabled.x && (_ = y), (n = e.middlewareData.shift) != null && n.enabled.y && (C = x), E && !p) {
512
+ const O = S(f.left, 0), F = S(f.right, 0), $ = S(f.top, 0), H = S(f.bottom, 0);
513
+ d ? _ = m - 2 * (O !== 0 || F !== 0 ? O + F : S(f.left, f.right)) : C = h - 2 * ($ !== 0 || H !== 0 ? $ + H : S(f.top, f.bottom));
513
514
  }
514
- await c({
515
+ await a({
515
516
  ...e,
516
- availableWidth: W,
517
- availableHeight: R
517
+ availableWidth: _,
518
+ availableHeight: C
518
519
  });
519
- const P = await s.getDimensions(l.floating);
520
- return m !== P.width || g !== P.height ? {
520
+ const k = await s.getDimensions(l.floating);
521
+ return m !== k.width || h !== k.height ? {
521
522
  reset: {
522
523
  rects: !0
523
524
  }
@@ -529,28 +530,29 @@ function st() {
529
530
  return typeof window < "u";
530
531
  }
531
532
  function K(t) {
532
- return ht(t) ? (t.nodeName || "").toLowerCase() : "#document";
533
+ return gt(t) ? (t.nodeName || "").toLowerCase() : "#document";
533
534
  }
534
- function C(t) {
535
+ function R(t) {
535
536
  var e;
536
537
  return (t == null || (e = t.ownerDocument) == null ? void 0 : e.defaultView) || window;
537
538
  }
538
- function B(t) {
539
+ function M(t) {
539
540
  var e;
540
- return (e = (ht(t) ? t.ownerDocument : t.document) || window.document) == null ? void 0 : e.documentElement;
541
+ return (e = (gt(t) ? t.ownerDocument : t.document) || window.document) == null ? void 0 : e.documentElement;
541
542
  }
542
- function ht(t) {
543
- return st() ? t instanceof Node || t instanceof C(t).Node : !1;
543
+ function gt(t) {
544
+ return st() ? t instanceof Node || t instanceof R(t).Node : !1;
544
545
  }
545
- function D(t) {
546
- return st() ? t instanceof Element || t instanceof C(t).Element : !1;
546
+ function P(t) {
547
+ return st() ? t instanceof Element || t instanceof R(t).Element : !1;
547
548
  }
548
- function N(t) {
549
- return st() ? t instanceof HTMLElement || t instanceof C(t).HTMLElement : !1;
549
+ function V(t) {
550
+ return st() ? t instanceof HTMLElement || t instanceof R(t).HTMLElement : !1;
550
551
  }
551
- function St(t) {
552
- return !st() || typeof ShadowRoot > "u" ? !1 : t instanceof ShadowRoot || t instanceof C(t).ShadowRoot;
552
+ function Tt(t) {
553
+ return !st() || typeof ShadowRoot > "u" ? !1 : t instanceof ShadowRoot || t instanceof R(t).ShadowRoot;
553
554
  }
555
+ const pe = /* @__PURE__ */ new Set(["inline", "contents"]);
554
556
  function et(t) {
555
557
  const {
556
558
  overflow: e,
@@ -558,13 +560,15 @@ function et(t) {
558
560
  overflowY: n,
559
561
  display: i
560
562
  } = L(t);
561
- return /auto|scroll|overlay|hidden|clip/.test(e + n + o) && !["inline", "contents"].includes(i);
563
+ return /auto|scroll|overlay|hidden|clip/.test(e + n + o) && !pe.has(i);
562
564
  }
563
- function ce(t) {
564
- return ["table", "td", "th"].includes(K(t));
565
+ const he = /* @__PURE__ */ new Set(["table", "td", "th"]);
566
+ function ge(t) {
567
+ return he.has(K(t));
565
568
  }
569
+ const we = [":popover-open", ":modal"];
566
570
  function rt(t) {
567
- return [":popover-open", ":modal"].some((e) => {
571
+ return we.some((e) => {
568
572
  try {
569
573
  return t.matches(e);
570
574
  } catch {
@@ -572,13 +576,14 @@ function rt(t) {
572
576
  }
573
577
  });
574
578
  }
579
+ const xe = ["transform", "translate", "scale", "rotate", "perspective"], ye = ["transform", "translate", "scale", "rotate", "perspective", "filter"], ve = ["paint", "layout", "strict", "content"];
575
580
  function wt(t) {
576
- const e = xt(), o = D(t) ? L(t) : t;
577
- return ["transform", "translate", "scale", "rotate", "perspective"].some((n) => o[n] ? o[n] !== "none" : !1) || (o.containerType ? o.containerType !== "normal" : !1) || !e && (o.backdropFilter ? o.backdropFilter !== "none" : !1) || !e && (o.filter ? o.filter !== "none" : !1) || ["transform", "translate", "scale", "rotate", "perspective", "filter"].some((n) => (o.willChange || "").includes(n)) || ["paint", "layout", "strict", "content"].some((n) => (o.contain || "").includes(n));
581
+ const e = xt(), o = P(t) ? L(t) : t;
582
+ return xe.some((n) => o[n] ? o[n] !== "none" : !1) || (o.containerType ? o.containerType !== "normal" : !1) || !e && (o.backdropFilter ? o.backdropFilter !== "none" : !1) || !e && (o.filter ? o.filter !== "none" : !1) || ye.some((n) => (o.willChange || "").includes(n)) || ve.some((n) => (o.contain || "").includes(n));
578
583
  }
579
- function ae(t) {
584
+ function be(t) {
580
585
  let e = Y(t);
581
- for (; N(e) && !G(e); ) {
586
+ for (; V(e) && !G(e); ) {
582
587
  if (wt(e))
583
588
  return e;
584
589
  if (rt(e))
@@ -590,14 +595,15 @@ function ae(t) {
590
595
  function xt() {
591
596
  return typeof CSS > "u" || !CSS.supports ? !1 : CSS.supports("-webkit-backdrop-filter", "none");
592
597
  }
598
+ const Ae = /* @__PURE__ */ new Set(["html", "body", "#document"]);
593
599
  function G(t) {
594
- return ["html", "body", "#document"].includes(K(t));
600
+ return Ae.has(K(t));
595
601
  }
596
602
  function L(t) {
597
- return C(t).getComputedStyle(t);
603
+ return R(t).getComputedStyle(t);
598
604
  }
599
605
  function lt(t) {
600
- return D(t) ? {
606
+ return P(t) ? {
601
607
  scrollLeft: t.scrollLeft,
602
608
  scrollTop: t.scrollTop
603
609
  } : {
@@ -612,90 +618,90 @@ function Y(t) {
612
618
  // Step into the shadow DOM of the parent of a slotted node.
613
619
  t.assignedSlot || // DOM Element detected.
614
620
  t.parentNode || // ShadowRoot detected.
615
- St(t) && t.host || // Fallback.
616
- B(t)
621
+ Tt(t) && t.host || // Fallback.
622
+ M(t)
617
623
  );
618
- return St(e) ? e.host : e;
624
+ return Tt(e) ? e.host : e;
619
625
  }
620
- function Et(t) {
626
+ function kt(t) {
621
627
  const e = Y(t);
622
- return G(e) ? t.ownerDocument ? t.ownerDocument.body : t.body : N(e) && et(e) ? e : Et(e);
628
+ return G(e) ? t.ownerDocument ? t.ownerDocument.body : t.body : V(e) && et(e) ? e : kt(e);
623
629
  }
624
- function Pt(t, e, o) {
630
+ function $t(t, e, o) {
625
631
  var n;
626
632
  e === void 0 && (e = []);
627
- const i = Et(t), r = i === ((n = t.ownerDocument) == null ? void 0 : n.body), s = C(i);
628
- return r ? (dt(s), e.concat(s, s.visualViewport || [], et(i) ? i : [], [])) : e.concat(i, Pt(i, []));
633
+ const i = kt(t), r = i === ((n = t.ownerDocument) == null ? void 0 : n.body), s = R(i);
634
+ return r ? (dt(s), e.concat(s, s.visualViewport || [], et(i) ? i : [], [])) : e.concat(i, $t(i, []));
629
635
  }
630
636
  function dt(t) {
631
637
  return t.parent && Object.getPrototypeOf(t.parent) ? t.frameElement : null;
632
638
  }
633
- function kt(t) {
639
+ function Nt(t) {
634
640
  const e = L(t);
635
641
  let o = parseFloat(e.width) || 0, n = parseFloat(e.height) || 0;
636
- const i = N(t), r = i ? t.offsetWidth : o, s = i ? t.offsetHeight : n, l = nt(o) !== r || nt(n) !== s;
642
+ const i = V(t), r = i ? t.offsetWidth : o, s = i ? t.offsetHeight : n, l = nt(o) !== r || nt(n) !== s;
637
643
  return l && (o = r, n = s), {
638
644
  width: o,
639
645
  height: n,
640
646
  $: l
641
647
  };
642
648
  }
643
- function $t(t) {
644
- return D(t) ? t : t.contextElement;
649
+ function Vt(t) {
650
+ return P(t) ? t : t.contextElement;
645
651
  }
646
652
  function q(t) {
647
- const e = $t(t);
648
- if (!N(e))
649
- return $(1);
653
+ const e = Vt(t);
654
+ if (!V(e))
655
+ return N(1);
650
656
  const o = e.getBoundingClientRect(), {
651
657
  width: n,
652
658
  height: i,
653
659
  $: r
654
- } = kt(e);
660
+ } = Nt(e);
655
661
  let s = (r ? nt(o.width) : o.width) / n, l = (r ? nt(o.height) : o.height) / i;
656
662
  return (!s || !Number.isFinite(s)) && (s = 1), (!l || !Number.isFinite(l)) && (l = 1), {
657
663
  x: s,
658
664
  y: l
659
665
  };
660
666
  }
661
- const fe = /* @__PURE__ */ $(0);
662
- function Nt(t) {
663
- const e = C(t);
664
- return !xt() || !e.visualViewport ? fe : {
667
+ const Ce = /* @__PURE__ */ N(0);
668
+ function Wt(t) {
669
+ const e = R(t);
670
+ return !xt() || !e.visualViewport ? Ce : {
665
671
  x: e.visualViewport.offsetLeft,
666
672
  y: e.visualViewport.offsetTop
667
673
  };
668
674
  }
669
- function ue(t, e, o) {
670
- return e === void 0 && (e = !1), !o || e && o !== C(t) ? !1 : e;
675
+ function Re(t, e, o) {
676
+ return e === void 0 && (e = !1), !o || e && o !== R(t) ? !1 : e;
671
677
  }
672
678
  function tt(t, e, o, n) {
673
679
  e === void 0 && (e = !1), o === void 0 && (o = !1);
674
- const i = t.getBoundingClientRect(), r = $t(t);
675
- let s = $(1);
676
- e && (n ? D(n) && (s = q(n)) : s = q(t));
677
- const l = ue(r, o, n) ? Nt(r) : $(0);
678
- let c = (i.left + l.x) / s.x, a = (i.top + l.y) / s.y, f = i.width / s.x, u = i.height / s.y;
680
+ const i = t.getBoundingClientRect(), r = Vt(t);
681
+ let s = N(1);
682
+ e && (n ? P(n) && (s = q(n)) : s = q(t));
683
+ const l = Re(r, o, n) ? Wt(r) : N(0);
684
+ let a = (i.left + l.x) / s.x, c = (i.top + l.y) / s.y, f = i.width / s.x, u = i.height / s.y;
679
685
  if (r) {
680
- const p = C(r), d = n && D(n) ? C(n) : n;
681
- let m = p, g = dt(m);
682
- for (; g && n && d !== m; ) {
683
- const h = q(g), w = g.getBoundingClientRect(), x = L(g), y = w.left + (g.clientLeft + parseFloat(x.paddingLeft)) * h.x, b = w.top + (g.clientTop + parseFloat(x.paddingTop)) * h.y;
684
- c *= h.x, a *= h.y, f *= h.x, u *= h.y, c += y, a += b, m = C(g), g = dt(m);
686
+ const p = R(r), d = n && P(n) ? R(n) : n;
687
+ let m = p, h = dt(m);
688
+ for (; h && n && d !== m; ) {
689
+ const g = q(h), w = h.getBoundingClientRect(), x = L(h), y = w.left + (h.clientLeft + parseFloat(x.paddingLeft)) * g.x, b = w.top + (h.clientTop + parseFloat(x.paddingTop)) * g.y;
690
+ a *= g.x, c *= g.y, f *= g.x, u *= g.y, a += y, c += b, m = R(h), h = dt(m);
685
691
  }
686
692
  }
687
693
  return it({
688
694
  width: f,
689
695
  height: u,
690
- x: c,
691
- y: a
696
+ x: a,
697
+ y: c
692
698
  });
693
699
  }
694
700
  function yt(t, e) {
695
701
  const o = lt(t).scrollLeft;
696
- return e ? e.left + o : tt(B(t)).left + o;
702
+ return e ? e.left + o : tt(M(t)).left + o;
697
703
  }
698
- function Wt(t, e, o) {
704
+ function Bt(t, e, o) {
699
705
  o === void 0 && (o = !1);
700
706
  const n = t.getBoundingClientRect(), i = n.left + e.scrollLeft - (o ? 0 : (
701
707
  // RTL <body> scrollbar.
@@ -706,38 +712,38 @@ function Wt(t, e, o) {
706
712
  y: r
707
713
  };
708
714
  }
709
- function de(t) {
715
+ function Oe(t) {
710
716
  let {
711
717
  elements: e,
712
718
  rect: o,
713
719
  offsetParent: n,
714
720
  strategy: i
715
721
  } = t;
716
- const r = i === "fixed", s = B(n), l = e ? rt(e.floating) : !1;
722
+ const r = i === "fixed", s = M(n), l = e ? rt(e.floating) : !1;
717
723
  if (n === s || l && r)
718
724
  return o;
719
- let c = {
725
+ let a = {
720
726
  scrollLeft: 0,
721
727
  scrollTop: 0
722
- }, a = $(1);
723
- const f = $(0), u = N(n);
724
- if ((u || !u && !r) && ((K(n) !== "body" || et(s)) && (c = lt(n)), N(n))) {
728
+ }, c = N(1);
729
+ const f = N(0), u = V(n);
730
+ if ((u || !u && !r) && ((K(n) !== "body" || et(s)) && (a = lt(n)), V(n))) {
725
731
  const d = tt(n);
726
- a = q(n), f.x = d.x + n.clientLeft, f.y = d.y + n.clientTop;
732
+ c = q(n), f.x = d.x + n.clientLeft, f.y = d.y + n.clientTop;
727
733
  }
728
- const p = s && !u && !r ? Wt(s, c, !0) : $(0);
734
+ const p = s && !u && !r ? Bt(s, a, !0) : N(0);
729
735
  return {
730
- width: o.width * a.x,
731
- height: o.height * a.y,
732
- x: o.x * a.x - c.scrollLeft * a.x + f.x + p.x,
733
- y: o.y * a.y - c.scrollTop * a.y + f.y + p.y
736
+ width: o.width * c.x,
737
+ height: o.height * c.y,
738
+ x: o.x * c.x - a.scrollLeft * c.x + f.x + p.x,
739
+ y: o.y * c.y - a.scrollTop * c.y + f.y + p.y
734
740
  };
735
741
  }
736
- function me(t) {
742
+ function Se(t) {
737
743
  return Array.from(t.getClientRects());
738
744
  }
739
- function pe(t) {
740
- const e = B(t), o = lt(t), n = t.ownerDocument.body, i = S(e.scrollWidth, e.clientWidth, n.scrollWidth, n.clientWidth), r = S(e.scrollHeight, e.clientHeight, n.scrollHeight, n.clientHeight);
745
+ function _e(t) {
746
+ const e = M(t), o = lt(t), n = t.ownerDocument.body, i = S(e.scrollWidth, e.clientWidth, n.scrollWidth, n.clientWidth), r = S(e.scrollHeight, e.clientHeight, n.scrollHeight, n.clientHeight);
741
747
  let s = -o.scrollLeft + yt(t);
742
748
  const l = -o.scrollTop;
743
749
  return L(n).direction === "rtl" && (s += S(e.clientWidth, n.clientWidth) - i), {
@@ -747,40 +753,41 @@ function pe(t) {
747
753
  y: l
748
754
  };
749
755
  }
750
- function ge(t, e) {
751
- const o = C(t), n = B(t), i = o.visualViewport;
752
- let r = n.clientWidth, s = n.clientHeight, l = 0, c = 0;
756
+ function Te(t, e) {
757
+ const o = R(t), n = M(t), i = o.visualViewport;
758
+ let r = n.clientWidth, s = n.clientHeight, l = 0, a = 0;
753
759
  if (i) {
754
760
  r = i.width, s = i.height;
755
- const a = xt();
756
- (!a || a && e === "fixed") && (l = i.offsetLeft, c = i.offsetTop);
761
+ const c = xt();
762
+ (!c || c && e === "fixed") && (l = i.offsetLeft, a = i.offsetTop);
757
763
  }
758
764
  return {
759
765
  width: r,
760
766
  height: s,
761
767
  x: l,
762
- y: c
768
+ y: a
763
769
  };
764
770
  }
765
- function he(t, e) {
766
- const o = tt(t, !0, e === "fixed"), n = o.top + t.clientTop, i = o.left + t.clientLeft, r = N(t) ? q(t) : $(1), s = t.clientWidth * r.x, l = t.clientHeight * r.y, c = i * r.x, a = n * r.y;
771
+ const De = /* @__PURE__ */ new Set(["absolute", "fixed"]);
772
+ function Pe(t, e) {
773
+ const o = tt(t, !0, e === "fixed"), n = o.top + t.clientTop, i = o.left + t.clientLeft, r = V(t) ? q(t) : N(1), s = t.clientWidth * r.x, l = t.clientHeight * r.y, a = i * r.x, c = n * r.y;
767
774
  return {
768
775
  width: s,
769
776
  height: l,
770
- x: c,
771
- y: a
777
+ x: a,
778
+ y: c
772
779
  };
773
780
  }
774
- function Tt(t, e, o) {
781
+ function Dt(t, e, o) {
775
782
  let n;
776
783
  if (e === "viewport")
777
- n = ge(t, o);
784
+ n = Te(t, o);
778
785
  else if (e === "document")
779
- n = pe(B(t));
780
- else if (D(e))
781
- n = he(e, o);
786
+ n = _e(M(t));
787
+ else if (P(e))
788
+ n = Pe(e, o);
782
789
  else {
783
- const i = Nt(t);
790
+ const i = Wt(t);
784
791
  n = {
785
792
  x: e.x - i.x,
786
793
  y: e.y - i.y,
@@ -792,66 +799,66 @@ function Tt(t, e, o) {
792
799
  }
793
800
  function Mt(t, e) {
794
801
  const o = Y(t);
795
- return o === e || !D(o) || G(o) ? !1 : L(o).position === "fixed" || Mt(o, e);
802
+ return o === e || !P(o) || G(o) ? !1 : L(o).position === "fixed" || Mt(o, e);
796
803
  }
797
- function we(t, e) {
804
+ function Le(t, e) {
798
805
  const o = e.get(t);
799
806
  if (o)
800
807
  return o;
801
- let n = Pt(t, []).filter((l) => D(l) && K(l) !== "body"), i = null;
808
+ let n = $t(t, []).filter((l) => P(l) && K(l) !== "body"), i = null;
802
809
  const r = L(t).position === "fixed";
803
810
  let s = r ? Y(t) : t;
804
- for (; D(s) && !G(s); ) {
805
- const l = L(s), c = wt(s);
806
- !c && l.position === "fixed" && (i = null), (r ? !c && !i : !c && l.position === "static" && !!i && ["absolute", "fixed"].includes(i.position) || et(s) && !c && Mt(t, s)) ? n = n.filter((f) => f !== s) : i = l, s = Y(s);
811
+ for (; P(s) && !G(s); ) {
812
+ const l = L(s), a = wt(s);
813
+ !a && l.position === "fixed" && (i = null), (r ? !a && !i : !a && l.position === "static" && !!i && De.has(i.position) || et(s) && !a && Mt(t, s)) ? n = n.filter((f) => f !== s) : i = l, s = Y(s);
807
814
  }
808
815
  return e.set(t, n), n;
809
816
  }
810
- function xe(t) {
817
+ function Ee(t) {
811
818
  let {
812
819
  element: e,
813
820
  boundary: o,
814
821
  rootBoundary: n,
815
822
  strategy: i
816
823
  } = t;
817
- const s = [...o === "clippingAncestors" ? rt(e) ? [] : we(e, this._c) : [].concat(o), n], l = s[0], c = s.reduce((a, f) => {
818
- const u = Tt(e, f, i);
819
- return a.top = S(u.top, a.top), a.right = X(u.right, a.right), a.bottom = X(u.bottom, a.bottom), a.left = S(u.left, a.left), a;
820
- }, Tt(e, l, i));
824
+ const s = [...o === "clippingAncestors" ? rt(e) ? [] : Le(e, this._c) : [].concat(o), n], l = s[0], a = s.reduce((c, f) => {
825
+ const u = Dt(e, f, i);
826
+ return c.top = S(u.top, c.top), c.right = X(u.right, c.right), c.bottom = X(u.bottom, c.bottom), c.left = S(u.left, c.left), c;
827
+ }, Dt(e, l, i));
821
828
  return {
822
- width: c.right - c.left,
823
- height: c.bottom - c.top,
824
- x: c.left,
825
- y: c.top
829
+ width: a.right - a.left,
830
+ height: a.bottom - a.top,
831
+ x: a.left,
832
+ y: a.top
826
833
  };
827
834
  }
828
- function ye(t) {
835
+ function ke(t) {
829
836
  const {
830
837
  width: e,
831
838
  height: o
832
- } = kt(t);
839
+ } = Nt(t);
833
840
  return {
834
841
  width: e,
835
842
  height: o
836
843
  };
837
844
  }
838
- function ve(t, e, o) {
839
- const n = N(e), i = B(e), r = o === "fixed", s = tt(t, !0, r, e);
845
+ function $e(t, e, o) {
846
+ const n = V(e), i = M(e), r = o === "fixed", s = tt(t, !0, r, e);
840
847
  let l = {
841
848
  scrollLeft: 0,
842
849
  scrollTop: 0
843
850
  };
844
- const c = $(0);
845
- function a() {
846
- c.x = yt(i);
851
+ const a = N(0);
852
+ function c() {
853
+ a.x = yt(i);
847
854
  }
848
855
  if (n || !n && !r)
849
856
  if ((K(e) !== "body" || et(i)) && (l = lt(e)), n) {
850
857
  const d = tt(e, !0, r, e);
851
- c.x = d.x + e.clientLeft, c.y = d.y + e.clientTop;
852
- } else i && a();
853
- r && !n && i && a();
854
- const f = i && !n && !r ? Wt(i, l) : $(0), u = s.left + l.scrollLeft - c.x - f.x, p = s.top + l.scrollTop - c.y - f.y;
858
+ a.x = d.x + e.clientLeft, a.y = d.y + e.clientTop;
859
+ } else i && c();
860
+ r && !n && i && c();
861
+ const f = i && !n && !r ? Bt(i, l) : N(0), u = s.left + l.scrollLeft - a.x - f.x, p = s.top + l.scrollTop - a.y - f.y;
855
862
  return {
856
863
  x: u,
857
864
  y: p,
@@ -862,36 +869,36 @@ function ve(t, e, o) {
862
869
  function ct(t) {
863
870
  return L(t).position === "static";
864
871
  }
865
- function _t(t, e) {
866
- if (!N(t) || L(t).position === "fixed")
872
+ function Pt(t, e) {
873
+ if (!V(t) || L(t).position === "fixed")
867
874
  return null;
868
875
  if (e)
869
876
  return e(t);
870
877
  let o = t.offsetParent;
871
- return B(t) === o && (o = o.ownerDocument.body), o;
878
+ return M(t) === o && (o = o.ownerDocument.body), o;
872
879
  }
873
- function Vt(t, e) {
874
- const o = C(t);
880
+ function Ft(t, e) {
881
+ const o = R(t);
875
882
  if (rt(t))
876
883
  return o;
877
- if (!N(t)) {
884
+ if (!V(t)) {
878
885
  let i = Y(t);
879
886
  for (; i && !G(i); ) {
880
- if (D(i) && !ct(i))
887
+ if (P(i) && !ct(i))
881
888
  return i;
882
889
  i = Y(i);
883
890
  }
884
891
  return o;
885
892
  }
886
- let n = _t(t, e);
887
- for (; n && ce(n) && ct(n); )
888
- n = _t(n, e);
889
- return n && G(n) && ct(n) && !wt(n) ? o : n || ae(t) || o;
893
+ let n = Pt(t, e);
894
+ for (; n && ge(n) && ct(n); )
895
+ n = Pt(n, e);
896
+ return n && G(n) && ct(n) && !wt(n) ? o : n || be(t) || o;
890
897
  }
891
- const be = async function(t) {
892
- const e = this.getOffsetParent || Vt, o = this.getDimensions, n = await o(t.floating);
898
+ const Ne = async function(t) {
899
+ const e = this.getOffsetParent || Ft, o = this.getDimensions, n = await o(t.floating);
893
900
  return {
894
- reference: ve(t.reference, await e(t.floating), t.strategy),
901
+ reference: $e(t.reference, await e(t.floating), t.strategy),
895
902
  floating: {
896
903
  x: 0,
897
904
  y: 0,
@@ -900,63 +907,63 @@ const be = async function(t) {
900
907
  }
901
908
  };
902
909
  };
903
- function Ae(t) {
910
+ function Ve(t) {
904
911
  return L(t).direction === "rtl";
905
912
  }
906
- const Re = {
907
- convertOffsetParentRelativeRectToViewportRelativeRect: de,
908
- getDocumentElement: B,
909
- getClippingRect: xe,
910
- getOffsetParent: Vt,
911
- getElementRects: be,
912
- getClientRects: me,
913
- getDimensions: ye,
913
+ const We = {
914
+ convertOffsetParentRelativeRectToViewportRelativeRect: Oe,
915
+ getDocumentElement: M,
916
+ getClippingRect: Ee,
917
+ getOffsetParent: Ft,
918
+ getElementRects: Ne,
919
+ getClientRects: Se,
920
+ getDimensions: ke,
914
921
  getScale: q,
915
- isElement: D,
916
- isRTL: Ae
917
- }, Ce = se, Oe = re, Se = oe, Te = le, _e = ne, De = (t, e, o) => {
922
+ isElement: P,
923
+ isRTL: Ve
924
+ }, Be = ue, Me = de, Fe = ce, He = me, je = le, Ie = (t, e, o) => {
918
925
  const n = /* @__PURE__ */ new Map(), i = {
919
- platform: Re,
926
+ platform: We,
920
927
  ...o
921
928
  }, r = {
922
929
  ...i.platform,
923
930
  _c: n
924
931
  };
925
- return ee(t, e, {
932
+ return re(t, e, {
926
933
  ...i,
927
934
  platform: r
928
935
  });
929
936
  };
930
- function Le(t) {
937
+ function Ye(t) {
931
938
  return t != null && typeof t == "object" && "$el" in t;
932
939
  }
933
- function Ee(t) {
934
- if (Le(t)) {
940
+ function ze(t) {
941
+ if (Ye(t)) {
935
942
  const e = t.$el;
936
- return ht(e) && K(e) === "#comment" ? null : e;
943
+ return gt(e) && K(e) === "#comment" ? null : e;
937
944
  }
938
945
  return t;
939
946
  }
940
- function Pe(t) {
947
+ function Xe(t) {
941
948
  return typeof t == "function" ? t() : at(t);
942
949
  }
943
- function ke(t) {
950
+ function Ke(t) {
944
951
  return {
945
952
  name: "arrow",
946
953
  options: t,
947
954
  fn(e) {
948
- const o = Ee(Pe(t.element));
949
- return o == null ? {} : _e({
955
+ const o = ze(Xe(t.element));
956
+ return o == null ? {} : je({
950
957
  element: o,
951
958
  padding: t.padding
952
959
  }).fn(e);
953
960
  }
954
961
  };
955
962
  }
956
- const $e = { class: "rds-e-tooltip" }, Ne = {
963
+ const qe = { class: "rds-e-tooltip" }, Ge = {
957
964
  key: 0,
958
965
  class: "rds-e-tooltip__header"
959
- }, We = { class: "rds-e-tooltip__title" }, Me = { class: "rds-e-tooltip__content" }, Ve = /* @__PURE__ */ Ft({
966
+ }, Je = { class: "rds-e-tooltip__title" }, Qe = { class: "rds-e-tooltip__content" }, Ue = /* @__PURE__ */ jt({
960
967
  __name: "tooltip",
961
968
  props: {
962
969
  /**
@@ -1000,97 +1007,109 @@ const $e = { class: "rds-e-tooltip" }, Ne = {
1000
1007
  fullWidth: {
1001
1008
  type: Boolean,
1002
1009
  default: !1
1010
+ },
1011
+ /**
1012
+ * <span>Invierte los colores del tooltip</span>
1013
+ */
1014
+ inverse: {
1015
+ type: Boolean,
1016
+ default: !1
1003
1017
  }
1004
1018
  },
1005
1019
  setup(t) {
1006
- const e = t, { large: o, fullWidth: n, title: i } = Ht(e), r = U(), s = U(), l = U(), c = U(!0), a = U(""), f = async () => {
1007
- const { x: m, y: g, middlewareData: h, placement: w } = await De(
1008
- r.value,
1020
+ const e = t, { large: o, fullWidth: n, title: i, inverse: r } = It(e), s = U(), l = U(), a = U(), c = U(!0), f = U(""), u = Yt(() => ({
1021
+ "rds-e-tooltip__tooltip": !0,
1022
+ "rds-e-tooltip__tooltip-hidden": c.value,
1023
+ "rds-e-tooltip__tooltip--large": o.value,
1024
+ "rds-e-tooltip__tooltip--inverse": r.value
1025
+ })), p = async () => {
1026
+ const { x: h, y: g, middlewareData: w, placement: x } = await Ie(
1009
1027
  s.value,
1028
+ l.value,
1010
1029
  {
1011
1030
  placement: e.placement,
1012
1031
  middleware: [
1013
- Ce(e.offsetSpace),
1014
- Se(),
1015
- Oe(),
1016
- Te({
1017
- apply({ availableHeight: v, availableWidth: E, elements: R }) {
1018
- Object.assign(R.floating.style, {
1019
- maxWidth: n.value ? `${Math.max(0, E)}px` : "380px",
1032
+ Be(e.offsetSpace),
1033
+ Fe(),
1034
+ Me(),
1035
+ He({
1036
+ apply({ availableHeight: E, availableWidth: C, elements: _ }) {
1037
+ Object.assign(_.floating.style, {
1038
+ maxWidth: n.value ? `${Math.max(0, C)}px` : "380px",
1020
1039
  width: "max-content",
1021
- maxHeight: `${Math.max(0, v)}px`
1040
+ maxHeight: `${Math.max(0, E)}px`
1022
1041
  });
1023
1042
  }
1024
1043
  }),
1025
- ke({
1026
- element: l.value,
1044
+ Ke({
1045
+ element: a.value,
1027
1046
  padding: o.value ? 16 : 8
1028
1047
  })
1029
1048
  ]
1030
1049
  }
1031
1050
  );
1032
- Object.assign(s.value.style, {
1033
- left: `${m}px`,
1051
+ Object.assign(l.value.style, {
1052
+ left: `${h}px`,
1034
1053
  top: `${g}px`
1035
1054
  });
1036
- const { x, y } = h.arrow, b = {
1055
+ const { x: y, y: b } = w.arrow, v = {
1037
1056
  left: "right",
1038
1057
  right: "left",
1039
1058
  bottom: "top",
1040
1059
  top: "bottom"
1041
1060
  };
1042
- a.value = `rds-e-tooltip__tooltip-arrow--${w}`, Object.assign(l.value.style, {
1043
- left: x != null ? `${x}px` : "",
1044
- top: y != null ? `${y}px` : "",
1061
+ f.value = `rds-e-tooltip__tooltip-arrow--${x}`, Object.assign(a.value.style, {
1062
+ left: y != null ? `${y}px` : "",
1063
+ top: b != null ? `${b}px` : "",
1045
1064
  bottom: "",
1046
1065
  right: "",
1047
- [b[w.split("-")[0]]]: "-4px"
1066
+ [v[x.split("-")[0]]]: "-4px"
1048
1067
  });
1049
- }, u = () => {
1068
+ }, d = () => {
1050
1069
  i != null && i.value || (c.value = !0);
1051
- }, p = () => {
1052
- c.value = !1, f();
1053
- }, d = jt(() => `rds-e-tooltip__tooltip ${c.value ? "rds-e-tooltip__tooltip-hidden " : ""}${o.value || i != null && i.value ? "rds-e-tooltip__tooltip--large " : ""}`);
1054
- return (m, g) => (bt(), vt("div", $e, [
1070
+ }, m = () => {
1071
+ c.value = !1, p();
1072
+ };
1073
+ return (h, g) => (bt(), vt("div", qe, [
1055
1074
  Z("div", {
1056
1075
  ref_key: "referenceRef",
1057
- ref: r,
1076
+ ref: s,
1058
1077
  class: "rds-e-tooltip__trigger",
1059
- onBlur: u,
1060
- onFocus: p,
1061
- onMouseenter: p,
1062
- onMouseleave: u
1078
+ onBlur: d,
1079
+ onFocus: m,
1080
+ onMouseenter: m,
1081
+ onMouseleave: d
1063
1082
  }, [
1064
- At(m.$slots, "default", {}, void 0, !0)
1083
+ At(h.$slots, "default", {}, void 0, !0)
1065
1084
  ], 544),
1066
1085
  Z("div", {
1067
1086
  ref_key: "floatingRef",
1068
- ref: s,
1069
- class: Rt(d.value)
1087
+ ref: l,
1088
+ class: Ct(u.value)
1070
1089
  }, [
1071
- at(i) ? (bt(), vt("div", Ne, [
1072
- Z("h3", We, Ct(at(i)), 1),
1073
- Yt(Xt, {
1090
+ at(i) ? (bt(), vt("div", Ge, [
1091
+ Z("h3", Je, Rt(at(i)), 1),
1092
+ Xt(qt, {
1074
1093
  name: "close",
1075
1094
  "aria-hidden": "true",
1076
1095
  class: "rds-e-tooltip__icon",
1077
- onClick: g[0] || (g[0] = (h) => c.value = !c.value)
1096
+ onClick: g[0] || (g[0] = (w) => c.value = !c.value)
1078
1097
  })
1079
- ])) : It("", !0),
1080
- Z("div", Me, [
1081
- At(m.$slots, "tooltip-content", {}, () => [
1082
- zt(Ct(t.content), 1)
1098
+ ])) : zt("", !0),
1099
+ Z("div", Qe, [
1100
+ At(h.$slots, "tooltip-content", {}, () => [
1101
+ Kt(Rt(t.content), 1)
1083
1102
  ], !0)
1084
1103
  ]),
1085
1104
  Z("div", {
1086
1105
  ref_key: "arrowRef",
1087
- ref: l,
1088
- class: Rt(["rds-e-tooltip__tooltip-arrow", a.value])
1106
+ ref: a,
1107
+ class: Ct(["rds-e-tooltip__tooltip-arrow", f.value])
1089
1108
  }, null, 2)
1090
1109
  ], 2)
1091
1110
  ]));
1092
1111
  }
1093
- }), je = /* @__PURE__ */ Kt(Ve, [["__scopeId", "data-v-b36c3878"]]);
1112
+ }), nn = /* @__PURE__ */ Gt(Ue, [["__scopeId", "data-v-eb4d3fb1"]]);
1094
1113
  export {
1095
- je as default
1114
+ nn as default
1096
1115
  };