@rocketui/vue 0.3.0-alpha.2 → 0.3.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.
@@ -1,5 +1,5 @@
1
- import { defineComponent as R, openBlock as m, createElementBlock as a, createElementVNode as u, unref as J, reactive as T1, Fragment as H1, renderList as t1, normalizeClass as p, renderSlot as h, toDisplayString as b, createVNode as q, computed as g, createCommentVNode as O, mergeProps as F1, createBlock as _, watch as G, getCurrentScope as h2, onScopeDispose as g2, ref as E, watchEffect as j1, onMounted as A2, onUnmounted as e2, Teleport as k2, withCtx as b1, withDirectives as t2, withModifiers as d1, withKeys as X1, vModelText as B2, createTextVNode as s1, normalizeStyle as $1, vShow as b2, resolveComponent as w2, provide as h1, resolveDynamicComponent as v2, inject as g1 } from "vue";
2
- const y2 = {
1
+ import { defineComponent as F, openBlock as m, createElementBlock as r, createElementVNode as s, unref as e1, reactive as _1, Fragment as A1, renderList as n1, normalizeClass as O, renderSlot as g, toDisplayString as b, createVNode as H1, computed as h, createCommentVNode as f, mergeProps as $1, createBlock as R, watch as $, getCurrentScope as P2, onScopeDispose as T2, ref as E, watchEffect as M2, onMounted as a2, onUnmounted as Y1, Teleport as r2, withCtx as F1, withDirectives as Z2, withModifiers as a1, withKeys as i2, vModelText as F2, createTextVNode as u1, normalizeStyle as J1, vShow as R2, resolveComponent as x2, provide as v1, resolveDynamicComponent as D2, inject as w1 } from "vue";
2
+ const E2 = {
3
3
  mdiAbTesting: "M4 2A2 2 0 0 0 2 4V12H4V8H6V12H8V4A2 2 0 0 0 6 2H4M4 4H6V6H4M22 15.5V14A2 2 0 0 0 20 12H16V22H20A2 2 0 0 0 22 20V18.5A1.54 1.54 0 0 0 20.5 17A1.54 1.54 0 0 0 22 15.5M20 20H18V18H20V20M20 16H18V14H20M5.79 21.61L4.21 20.39L18.21 2.39L19.79 3.61Z",
4
4
  mdiAbacus: "M5 5H7V11H5V5M10 5H8V11H10V5M5 19H7V13H5V19M10 13H8V19H10V17H15V15H10V13M2 21H4V3H2V21M20 3V7H13V5H11V11H13V9H20V15H18V13H16V19H18V17H20V21H22V3H20Z",
5
5
  mdiAbjadArabic: "M12 4C10.08 4 8.5 5.58 8.5 7.5C8.5 8.43 8.88 9.28 9.5 9.91C7.97 10.91 7 12.62 7 14.5C7 17.53 9.47 20 12.5 20C14.26 20 16 19.54 17.5 18.66L16.5 16.93C15.28 17.63 13.9 18 12.5 18C10.56 18 9 16.45 9 14.5C9 12.91 10.06 11.53 11.59 11.12L16.8 9.72L16.28 7.79L11.83 9C11.08 8.9 10.5 8.28 10.5 7.5C10.5 6.66 11.16 6 12 6C12.26 6 12.5 6.07 12.75 6.2L13.75 4.47C13.22 4.16 12.61 4 12 4Z",
@@ -7296,7 +7296,7 @@ const y2 = {
7296
7296
  mdiZodiacScorpio: "M17.71,15.29L16.29,16.71L17.59,18H16A2,2 0 0,1 14,16V6A3,3 0 0,0 11,3C10.25,3 9.55,3.29 9,3.78C7.86,2.76 6.14,2.76 5,3.78C4.45,3.28 3.74,3 3,3V5A1,1 0 0,1 4,6V16H6V6A1,1 0 0,1 7,5A1,1 0 0,1 8,6V16H10V6A1,1 0 0,1 11,5A1,1 0 0,1 12,6V16A4,4 0 0,0 16,20H17.59L16.29,21.29L17.71,22.71L21.41,19L17.71,15.29Z",
7297
7297
  mdiZodiacTaurus: "M15.59,9C17.7,7.74 19,5.46 19,3H17A5,5 0 0,1 12,8A5,5 0 0,1 7,3H5C5,5.46 6.3,7.74 8.41,9C5.09,11 4,15.28 6,18.6C7.97,21.92 12.27,23 15.59,21C18.91,19.04 20,14.74 18,11.42C17.42,10.43 16.58,9.59 15.59,9M12,20A5,5 0 0,1 7,15A5,5 0 0,1 12,10A5,5 0 0,1 17,15A5,5 0 0,1 12,20Z",
7298
7298
  mdiZodiacVirgo: "M18.5,19.13C20,17.77 20,15.18 20,14A4,4 0 0,0 16,10C15.3,10 14.6,10.2 14,10.56V6A3,3 0 0,0 11,3C10.25,3 9.55,3.29 9,3.78C7.86,2.76 6.14,2.76 5,3.78C4.45,3.28 3.74,3 3,3V5A1,1 0 0,1 4,6V16H6V6A1,1 0 0,1 7,5A1,1 0 0,1 8,6V16H10V6A1,1 0 0,1 11,5A1,1 0 0,1 12,6V14C12,15.18 12,17.77 13.5,19.13C12.72,19.54 11.88,19.84 11,20V22C12.29,22 14.84,20.74 16,20.13C17.16,20.74 19.71,22 21,22V20C20.12,19.84 19.28,19.54 18.5,19.13M16,12A2,2 0 0,1 18,14C18,16.92 17.46,18 16,18C14.54,18 14,16.92 14,14A2,2 0 0,1 16,12Z"
7299
- }, P2 = ["height", "viewBox", "width"], T2 = ["d"], D = /* @__PURE__ */ R({
7299
+ }, _2 = ["id", "height", "viewBox", "width"], $2 = ["id", "d"], T = /* @__PURE__ */ F({
7300
7300
  __name: "RIcon",
7301
7301
  props: {
7302
7302
  name: { default: "" },
@@ -7305,79 +7305,98 @@ const y2 = {
7305
7305
  },
7306
7306
  setup(H) {
7307
7307
  const V = H;
7308
- return (C, M) => (m(), a("svg", {
7308
+ return (C, i) => (m(), r("svg", {
7309
+ id: C.id,
7309
7310
  class: "r-icon",
7310
7311
  height: V.size,
7311
7312
  viewBox: V.viewBox,
7312
7313
  width: V.size
7313
7314
  }, [
7314
- u("path", {
7315
- d: J(y2)[V.name]
7316
- }, null, 8, T2)
7317
- ], 8, P2));
7315
+ s("path", {
7316
+ id: `${C.id}-path`,
7317
+ d: e1(E2)[V.name]
7318
+ }, null, 8, $2)
7319
+ ], 8, _2));
7318
7320
  }
7319
- }), F2 = ["data-state", "onClick"], R2 = { class: "r-accordion__header" }, x2 = { class: "r-accordion__title" }, D2 = { class: "r-accordion__icon" }, _2 = { class: "r-accordion__content" }, h0 = /* @__PURE__ */ R({
7321
+ }), W2 = ["id", "data-state", "onClick"], N2 = ["id"], I2 = { class: "r-accordion__title" }, Q2 = ["id"], G2 = ["id"], U2 = ["id"], C7 = /* @__PURE__ */ F({
7320
7322
  __name: "RAccordion",
7321
7323
  props: {
7322
7324
  accordions: {},
7323
- multiple: { type: Boolean }
7325
+ multiple: { type: Boolean },
7326
+ id: { default: "r-accordion" }
7324
7327
  },
7325
7328
  setup(H) {
7326
- const V = H, C = T1(
7327
- V.accordions.map(({ title: i, content: L }, A) => ({
7328
- title: i,
7329
+ const V = H, C = _1(
7330
+ V.accordions.map(({ title: A, content: L }, M) => ({
7331
+ title: A,
7329
7332
  content: L,
7330
- open: V.accordions[A].open || !1,
7331
- disabled: V.accordions[A].disabled || !1
7333
+ open: V.accordions[M].open || !1,
7334
+ disabled: V.accordions[M].disabled || !1
7332
7335
  }))
7333
7336
  );
7334
- function M(i) {
7335
- if (!C[i].disabled) {
7337
+ function i(A) {
7338
+ if (!C[A].disabled) {
7336
7339
  if (V.multiple) {
7337
- C[i].open = !C[i].open;
7340
+ C[A].open = !C[A].open;
7338
7341
  return;
7339
7342
  }
7340
- C.forEach((L, A) => {
7341
- C[A].open = A === i ? !C[A].open : !1;
7343
+ C.forEach((L, M) => {
7344
+ C[M].open = M === A ? !C[M].open : !1;
7342
7345
  });
7343
7346
  }
7344
7347
  }
7345
- return (i, L) => (m(!0), a(H1, null, t1(C, (A, e) => (m(), a("div", {
7348
+ return (A, L) => (m(!0), r(A1, null, n1(C, (M, e) => (m(), r("div", {
7349
+ id: `${A.id}-${e}`,
7346
7350
  key: e,
7347
- class: p(["r-accordion", {
7348
- "r-accordion--disabled": A.disabled,
7349
- "cursor-pointer": !A.open
7351
+ class: O(["r-accordion", {
7352
+ "r-accordion--disabled": M.disabled,
7353
+ "cursor-pointer": !M.open
7350
7354
  }]),
7351
- "data-state": A.open ? "opened" : "closed",
7352
- onClick: (t) => M(e)
7355
+ "data-state": M.open ? "opened" : "closed",
7356
+ onClick: (d) => i(e)
7353
7357
  }, [
7354
- u("div", R2, [
7355
- h(i.$slots, "title", { accordion: A }, () => [
7356
- u("div", x2, b(A.title), 1)
7358
+ s("div", {
7359
+ id: `${A.id}-header-${e}`,
7360
+ class: "r-accordion__header"
7361
+ }, [
7362
+ g(A.$slots, "title", { accordion: M }, () => [
7363
+ s("div", I2, b(M.title), 1)
7357
7364
  ]),
7358
- u("div", D2, [
7359
- h(i.$slots, "icon", {
7360
- item: A,
7361
- open: A.open
7365
+ s("div", {
7366
+ id: `${A.id}-icon-wrapper-${e}`,
7367
+ class: "r-accordion__icon"
7368
+ }, [
7369
+ g(A.$slots, "icon", {
7370
+ id: `${A.id}-icon-${e}`,
7371
+ item: M,
7372
+ open: M.open
7362
7373
  }, () => [
7363
- q(D, { name: "mdiChevronDown" })
7374
+ H1(T, {
7375
+ id: `${A.id}-icon-${e}`,
7376
+ name: "mdiChevronDown"
7377
+ }, null, 8, ["id"])
7364
7378
  ])
7379
+ ], 8, Q2)
7380
+ ], 8, N2),
7381
+ s("div", {
7382
+ id: `${A.id}-content-${e}`,
7383
+ class: "r-accordion__content"
7384
+ }, [
7385
+ g(A.$slots, "content", {
7386
+ id: `${A.id}-content-${e}`,
7387
+ accordion: M
7388
+ }, () => [
7389
+ s("span", {
7390
+ id: `${A.id}-content-${e}`
7391
+ }, b(M.content), 9, U2)
7365
7392
  ])
7366
- ]),
7367
- u("div", _2, [
7368
- h(i.$slots, "content", { accordion: A }, () => [
7369
- u("span", null, b(A.content), 1)
7370
- ])
7371
- ])
7372
- ], 10, F2))), 128));
7393
+ ], 8, G2)
7394
+ ], 10, W2))), 128));
7373
7395
  }
7374
- }), E2 = { class: "r-alert__icon" }, W2 = { class: "r-alert__content" }, N2 = { class: "r-alert__content__title" }, I2 = {
7396
+ }), z2 = ["id"], K2 = ["id"], q2 = ["id"], j2 = { class: "r-alert__content__title" }, X2 = {
7375
7397
  key: 0,
7376
7398
  class: "r-alert__content__description"
7377
- }, Q2 = {
7378
- key: 0,
7379
- class: "r-alert__close"
7380
- }, g0 = /* @__PURE__ */ R({
7399
+ }, Y2 = ["id"], H7 = /* @__PURE__ */ F({
7381
7400
  __name: "RAlert",
7382
7401
  props: {
7383
7402
  type: { default: "info" },
@@ -7385,101 +7404,122 @@ const y2 = {
7385
7404
  variant: { default: "ghost" },
7386
7405
  description: { default: "" },
7387
7406
  closable: { type: Boolean, default: !0 },
7388
- block: { type: Boolean, default: !1 }
7407
+ block: { type: Boolean, default: !1 },
7408
+ id: { default: "r-alert" }
7389
7409
  },
7390
7410
  emits: ["close"],
7391
7411
  setup(H, { emit: V }) {
7392
- const C = H, M = V, i = g(() => ({
7412
+ const C = H, i = V, A = h(() => ({
7393
7413
  " r-alert": !0,
7394
7414
  [`r-alert--${C.variant}`]: !0,
7395
7415
  "r-alert--block": C.block,
7396
7416
  [`r-alert--${C.variant}--${C.type}`]: !0
7397
- })), L = g(() => ({
7417
+ })), L = h(() => ({
7398
7418
  success: "mdiCheckCircle",
7399
7419
  error: "mdiAlertCircle",
7400
7420
  warning: "mdiAlert",
7401
7421
  info: "mdiInformation"
7402
7422
  })[C.type]);
7403
- function A() {
7404
- M("close");
7423
+ function M() {
7424
+ i("close");
7405
7425
  }
7406
- return (e, t) => (m(), a("div", {
7407
- class: p(i.value)
7426
+ return (e, d) => (m(), r("div", {
7427
+ id: e.id,
7428
+ class: O(A.value)
7408
7429
  }, [
7409
- u("div", E2, [
7410
- h(e.$slots, "alert-icon", {}, () => [
7411
- q(D, {
7430
+ s("div", {
7431
+ id: `${e.id}-icon`,
7432
+ class: "r-alert__icon"
7433
+ }, [
7434
+ g(e.$slots, "alert-icon", {}, () => [
7435
+ H1(T, {
7412
7436
  name: L.value,
7413
7437
  size: 24
7414
7438
  }, null, 8, ["name"])
7415
7439
  ])
7416
- ]),
7417
- u("div", W2, [
7418
- h(e.$slots, "content", {}, () => [
7419
- u("p", N2, b(C.title), 1),
7420
- C.description ? (m(), a("p", I2, b(C.description), 1)) : O("", !0)
7440
+ ], 8, K2),
7441
+ s("div", {
7442
+ id: `${e.id}-content`,
7443
+ class: "r-alert__content"
7444
+ }, [
7445
+ g(e.$slots, "content", {}, () => [
7446
+ s("p", j2, b(C.title), 1),
7447
+ C.description ? (m(), r("p", X2, b(C.description), 1)) : f("", !0)
7421
7448
  ])
7422
- ]),
7423
- C.closable ? (m(), a("div", Q2, [
7424
- h(e.$slots, "custom-close", {
7425
- close: A,
7449
+ ], 8, q2),
7450
+ C.closable ? (m(), r("div", {
7451
+ key: 0,
7452
+ id: `${e.id}-close`,
7453
+ class: "r-alert__close"
7454
+ }, [
7455
+ g(e.$slots, "custom-close", {
7456
+ close: M,
7426
7457
  slotClass: "r-alert__close__button"
7427
7458
  }, () => [
7428
- q(D, {
7459
+ H1(T, {
7460
+ id: `${e.id}-close-button`,
7429
7461
  class: "r-alert__close__button",
7430
7462
  name: "mdiClose",
7431
7463
  size: 16,
7432
- onClick: A
7433
- })
7464
+ onClick: M
7465
+ }, null, 8, ["id"])
7434
7466
  ])
7435
- ])) : O("", !0)
7436
- ], 2));
7467
+ ], 8, Y2)) : f("", !0)
7468
+ ], 10, z2));
7437
7469
  }
7438
- }), Y1 = "data:image/svg+xml,%3csvg%20width='27'%20height='28'%20viewBox='0%200%2027%2028'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M13.4993%2014C17.1827%2014%2020.166%2011.0167%2020.166%207.33334C20.166%203.65%2017.1827%200.666672%2013.4993%200.666672C9.81602%200.666672%206.83268%203.65%206.83268%207.33334C6.83268%2011.0167%209.81602%2014%2013.4993%2014ZM13.4993%2017.3333C9.04935%2017.3333%200.166016%2019.5667%200.166016%2024V25.6667C0.166016%2026.5833%200.916016%2027.3333%201.83268%2027.3333H25.166C26.0827%2027.3333%2026.8327%2026.5833%2026.8327%2025.6667V24C26.8327%2019.5667%2017.9493%2017.3333%2013.4993%2017.3333Z'%20fill='%234C5BE1'/%3e%3c/svg%3e", G2 = { class: "r-avatar__wrapper" }, $2 = ["alt", "src"], k0 = /* @__PURE__ */ R({
7470
+ }), A2 = "data:image/svg+xml,%3csvg%20width='27'%20height='28'%20viewBox='0%200%2027%2028'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M13.4993%2014C17.1827%2014%2020.166%2011.0167%2020.166%207.33334C20.166%203.65%2017.1827%200.666672%2013.4993%200.666672C9.81602%200.666672%206.83268%203.65%206.83268%207.33334C6.83268%2011.0167%209.81602%2014%2013.4993%2014ZM13.4993%2017.3333C9.04935%2017.3333%200.166016%2019.5667%200.166016%2024V25.6667C0.166016%2026.5833%200.916016%2027.3333%201.83268%2027.3333H25.166C26.0827%2027.3333%2026.8327%2026.5833%2026.8327%2025.6667V24C26.8327%2019.5667%2017.9493%2017.3333%2013.4993%2017.3333Z'%20fill='%234C5BE1'/%3e%3c/svg%3e", J2 = ["id"], C5 = ["id"], H5 = ["id"], V5 = ["id", "alt", "src"], L5 = ["id"], V7 = /* @__PURE__ */ F({
7439
7471
  __name: "RAvatar",
7440
7472
  props: {
7441
7473
  type: { default: "image" },
7442
- src: { default: Y1 },
7474
+ src: { default: A2 },
7443
7475
  alt: { default: "Avatar" },
7444
7476
  size: { default: "2xl" },
7445
7477
  online: { type: Boolean, default: !1 },
7446
- text: { default: "" }
7478
+ text: { default: "" },
7479
+ id: { default: "r-avatar" }
7447
7480
  },
7448
7481
  setup(H) {
7449
- const V = H, C = g(() => ({
7482
+ const V = H, C = h(() => ({
7450
7483
  "r-avatar": !0,
7451
7484
  [`r-avatar--${V.size}`]: !0
7452
- })), M = g(() => V.type === "image" && !V.src), i = g(() => M.value ? Y1 : V.src);
7453
- function L(A) {
7454
- const e = A.split(" ");
7485
+ })), i = h(() => V.type === "image" && !V.src), A = h(() => i.value ? A2 : V.src);
7486
+ function L(M) {
7487
+ const e = M.split(" ");
7455
7488
  return e.length === 1 ? e[0].substring(0, 2) : `${e[0].charAt(0)}${e[1].charAt(0)}`;
7456
7489
  }
7457
- return (A, e) => (m(), a("div", G2, [
7458
- u("div", {
7459
- class: p(C.value)
7490
+ return (M, e) => (m(), r("div", {
7491
+ id: M.id,
7492
+ class: "r-avatar__wrapper"
7493
+ }, [
7494
+ s("div", {
7495
+ id: `${M.id}-wrapper`,
7496
+ class: O(C.value)
7460
7497
  }, [
7461
- V.type === "text" ? (m(), a("p", {
7498
+ V.type === "text" ? (m(), r("p", {
7462
7499
  key: 0,
7463
- class: p(["r-avatar__text", { [`r-avatar__text--${V.size}`]: !0 }])
7464
- }, b(L(V.text)), 3)) : (m(), a("img", {
7500
+ id: `${M.id}-text`,
7501
+ class: O(["r-avatar__text", { [`r-avatar__text--${V.size}`]: !0 }])
7502
+ }, b(L(V.text)), 11, H5)) : (m(), r("img", {
7465
7503
  key: 1,
7504
+ id: `${M.id}-image`,
7466
7505
  alt: V.alt,
7467
- class: p(["r-avatar__image", {
7506
+ class: O(["r-avatar__image", {
7468
7507
  [`r-avatar__image--${V.size}`]: !0,
7469
- "r-avatar__image--anonymous": M.value
7508
+ "r-avatar__image--anonymous": i.value
7470
7509
  }]),
7471
- src: i.value
7472
- }, null, 10, $2))
7473
- ], 2),
7474
- V.online ? (m(), a("span", {
7510
+ src: A.value
7511
+ }, null, 10, V5))
7512
+ ], 10, C5),
7513
+ V.online ? (m(), r("span", {
7475
7514
  key: 0,
7476
- class: p(["r-avatar__online", {
7515
+ id: `${M.id}-online`,
7516
+ class: O(["r-avatar__online", {
7477
7517
  [`r-avatar__online--${V.size}`]: !0
7478
7518
  }])
7479
- }, null, 2)) : O("", !0)
7480
- ]));
7519
+ }, null, 10, L5)) : f("", !0)
7520
+ ], 8, J2));
7481
7521
  }
7482
- }), U2 = ["innerHTML"], B0 = /* @__PURE__ */ R({
7522
+ }), M5 = ["id"], i5 = ["id"], A5 = ["id", "innerHTML"], L7 = /* @__PURE__ */ F({
7483
7523
  __name: "RBadge",
7484
7524
  props: {
7485
7525
  variant: { default: "primary" },
@@ -7491,11 +7531,12 @@ const y2 = {
7491
7531
  class: { default: "" },
7492
7532
  content: { default: "" },
7493
7533
  contentClass: { default: "" },
7494
- wrapperClass: { default: "" }
7534
+ wrapperClass: { default: "" },
7535
+ id: { default: "r-badge" }
7495
7536
  },
7496
7537
  emits: ["click"],
7497
7538
  setup(H) {
7498
- const V = H, C = g(() => ({
7539
+ const V = H, C = h(() => ({
7499
7540
  "r-badge": !0,
7500
7541
  [`r-badge--content ${V.contentClass}`]: V.content,
7501
7542
  [`r-badge--overlap-${V.placement}`]: V.overlap,
@@ -7505,20 +7546,25 @@ const y2 = {
7505
7546
  [`r-badge--${V.variant}`]: V.variant,
7506
7547
  [V.class]: V.class
7507
7548
  }));
7508
- return (M, i) => (m(), a("div", {
7509
- class: p(["r-badge-wrapper group", [V.wrapperClass]])
7549
+ return (i, A) => (m(), r("div", {
7550
+ id: i.id,
7551
+ class: O(["r-badge-wrapper group", [V.wrapperClass]])
7510
7552
  }, [
7511
- u("span", {
7512
- class: p([{ "animate-ping-2": V.animation }, C.value])
7513
- }, null, 2),
7514
- u("span", {
7515
- class: p(C.value),
7553
+ s("span", {
7554
+ id: `${i.id}-badge`,
7555
+ class: O([{ "animate-ping-2": V.animation }, C.value])
7556
+ }, null, 10, i5),
7557
+ s("span", {
7558
+ id: `${i.id}-content`,
7559
+ class: O(C.value),
7516
7560
  innerHTML: V.content
7517
- }, null, 10, U2),
7518
- h(M.$slots, "default")
7519
- ], 2));
7561
+ }, null, 10, A5),
7562
+ g(i.$slots, "default", {
7563
+ id: `${i.id}-slot`
7564
+ })
7565
+ ], 10, M5));
7520
7566
  }
7521
- }), z2 = ["disabled"], b0 = /* @__PURE__ */ R({
7567
+ }), e5 = ["id", "disabled"], M7 = /* @__PURE__ */ F({
7522
7568
  __name: "RButton",
7523
7569
  props: {
7524
7570
  variant: { default: "default" },
@@ -7530,11 +7576,12 @@ const y2 = {
7530
7576
  icon: { type: Boolean, default: !1 },
7531
7577
  size: { default: "medium" },
7532
7578
  height: { default: "" },
7533
- block: { type: Boolean, default: !1 }
7579
+ block: { type: Boolean, default: !1 },
7580
+ id: { default: "r-button" }
7534
7581
  },
7535
7582
  emits: ["click"],
7536
7583
  setup(H) {
7537
- const V = H, C = g(() => ({
7584
+ const V = H, C = h(() => ({
7538
7585
  "r-button": !0,
7539
7586
  [`r-button__${V.variant}`]: !0,
7540
7587
  [`r-button__${V.variant}--${V.variant === "default" && V.color === void 0 ? "primary" : V.color}`]: !0,
@@ -7542,54 +7589,51 @@ const y2 = {
7542
7589
  [`r-button--${V.size || "medium"}`]: !0,
7543
7590
  "r-button--only-icon": V.icon,
7544
7591
  "r-button--block": V.block
7545
- })), M = g(() => ({
7592
+ })), i = h(() => ({
7546
7593
  small: 16,
7547
7594
  medium: 16,
7548
7595
  large: 20
7549
- })[V.size || "medium"]), i = g(() => ({
7596
+ })[V.size || "medium"]), A = h(() => ({
7550
7597
  height: V.height ? `${V.height}px` : ""
7551
7598
  }));
7552
- return (L, A) => (m(), a("button", F1(L.$attrs, {
7599
+ return (L, M) => (m(), r("button", $1(L.$attrs, {
7600
+ id: L.id,
7553
7601
  class: C.value,
7554
7602
  disabled: L.disabled,
7555
- style: i.value,
7556
- onClick: A[0] || (A[0] = (e) => L.$emit("click"))
7603
+ style: A.value,
7604
+ onClick: M[0] || (M[0] = (e) => L.$emit("click"))
7557
7605
  }), [
7558
- h(L.$slots, "prepend", {
7606
+ g(L.$slots, "prepend", {
7559
7607
  onlyIcon: V.icon
7560
7608
  }, () => [
7561
- V.prependIcon ? (m(), _(D, {
7609
+ V.prependIcon ? (m(), R(T, {
7562
7610
  key: 0,
7563
- class: p(["r-button__prepend-icon", {
7611
+ id: `${L.id}-prepend-icon`,
7612
+ class: O(["r-button__prepend-icon", {
7564
7613
  "r-button__prepend-icon--only": V.icon
7565
7614
  }]),
7566
7615
  name: V.prependIcon,
7567
- size: M.value
7568
- }, null, 8, ["class", "name", "size"])) : O("", !0)
7616
+ size: i.value
7617
+ }, null, 8, ["id", "class", "name", "size"])) : f("", !0)
7569
7618
  ]),
7570
- h(L.$slots, "default", { disabled: L.disabled }),
7571
- h(L.$slots, "append", {
7619
+ g(L.$slots, "default", {
7620
+ id: `${L.id}-slot`,
7621
+ disabled: L.disabled
7622
+ }),
7623
+ g(L.$slots, "append", {
7572
7624
  onlyIcon: V.icon
7573
7625
  }, () => [
7574
- !V.icon && V.appendIcon ? (m(), _(D, {
7626
+ !V.icon && V.appendIcon ? (m(), R(T, {
7575
7627
  key: 0,
7628
+ id: `${L.id}-append-icon`,
7576
7629
  class: "r-button__append-icon",
7577
7630
  name: V.appendIcon,
7578
- size: M.value
7579
- }, null, 8, ["name", "size"])) : O("", !0)
7631
+ size: i.value
7632
+ }, null, 8, ["id", "name", "size"])) : f("", !0)
7580
7633
  ])
7581
- ], 16, z2));
7634
+ ], 16, e5));
7582
7635
  }
7583
- }), K2 = { class: "r-checkbox-wrapper" }, q2 = { class: "r-checkbox-container" }, j2 = ["id", "checked", "disabled", "indeterminate"], X2 = ["data-disabled"], Y2 = { class: "r-checkbox-texts" }, J2 = ["data-disabled", "for"], C5 = {
7584
- key: 0,
7585
- class: "r-checkbox-texts__details"
7586
- }, H5 = {
7587
- key: 0,
7588
- class: "r-checkbox-texts__error"
7589
- }, V5 = {
7590
- key: 1,
7591
- class: "r-checkbox-texts__hint"
7592
- }, w0 = /* @__PURE__ */ R({
7636
+ }), d5 = { class: "r-checkbox-wrapper" }, t5 = ["id"], m5 = ["id", "checked", "disabled", "indeterminate"], l5 = ["id", "data-disabled"], o5 = ["id"], n5 = ["id", "data-disabled", "for"], a5 = ["id"], r5 = ["id"], Z5 = ["id"], i7 = /* @__PURE__ */ F({
7593
7637
  __name: "RCheckbox",
7594
7638
  props: {
7595
7639
  id: { default: "" },
@@ -7603,77 +7647,99 @@ const y2 = {
7603
7647
  },
7604
7648
  emits: ["update:modelValue"],
7605
7649
  setup(H, { emit: V }) {
7606
- const C = H, M = V, i = T1({
7650
+ const C = H, i = V, A = _1({
7607
7651
  checked: !1,
7608
7652
  indeterminate: !1
7609
7653
  }), L = {
7610
7654
  checked: "mdiCheck",
7611
7655
  unchecked: "",
7612
7656
  indeterminate: "mdiMinus"
7613
- }, A = g(() => i.indeterminate ? L.indeterminate : i.checked ? L.checked : L.unchecked), e = g(() => ({
7657
+ }, M = h(() => A.indeterminate ? L.indeterminate : A.checked ? L.checked : L.unchecked), e = h(() => ({
7614
7658
  "r-checkbox": !0,
7615
- "r-checkbox--checked": i.checked,
7659
+ "r-checkbox--checked": A.checked,
7616
7660
  "r-checkbox--disabled": C.disabled,
7617
- "r-checkbox--indeterminate": i.indeterminate,
7661
+ "r-checkbox--indeterminate": A.indeterminate,
7618
7662
  "r-checkbox--error": !!C.errorMsg
7619
7663
  }));
7620
- function t(d) {
7621
- C.disabled || (i.checked = d.target.checked, i.indeterminate = !1, M("update:modelValue", i.checked));
7664
+ function d(n) {
7665
+ C.disabled || (A.checked = n.target.checked, A.indeterminate = !1, i("update:modelValue", A.checked));
7622
7666
  }
7623
- return G(
7667
+ $(
7624
7668
  () => C.indeterminate,
7625
- (d) => {
7626
- i.indeterminate = d, d === !0 && (i.checked = !1, M("update:modelValue", i.checked));
7669
+ (n) => {
7670
+ A.indeterminate = n, n === !0 && (A.checked = !1, i("update:modelValue", A.checked));
7627
7671
  },
7628
7672
  {
7629
7673
  // need immediate to set the state on first render for storybook
7630
7674
  // TODO: find a better way to do this
7631
7675
  immediate: !0
7632
7676
  }
7633
- ), G(
7677
+ ), $(
7634
7678
  () => C.modelValue,
7635
- (d) => {
7636
- i.checked = d;
7679
+ (n) => {
7680
+ A.checked = n;
7637
7681
  },
7638
7682
  {
7639
7683
  // need immediate to set the state on first render for storybook
7640
7684
  // TODO: find a better way to do this
7641
7685
  immediate: !0
7642
7686
  }
7643
- ), (d, l) => (m(), a("div", K2, [
7644
- u("div", q2, [
7645
- u("input", {
7646
- id: C.id,
7647
- checked: i.checked,
7687
+ );
7688
+ const l = h(() => C.id || "r-checkbox");
7689
+ return (n, Z) => (m(), r("div", d5, [
7690
+ s("div", {
7691
+ id: `${l.value}-container`,
7692
+ class: "r-checkbox-container"
7693
+ }, [
7694
+ s("input", {
7695
+ id: l.value,
7696
+ checked: A.checked,
7648
7697
  class: "r-checkbox-container__input",
7649
7698
  disabled: C.disabled,
7650
- indeterminate: i.indeterminate,
7699
+ indeterminate: A.indeterminate,
7651
7700
  type: "checkbox",
7652
- onChange: t
7653
- }, null, 40, j2),
7654
- u("div", {
7655
- class: p(e.value),
7701
+ onChange: d
7702
+ }, null, 40, m5),
7703
+ s("div", {
7704
+ id: `${l.value}-icon`,
7705
+ class: O(e.value),
7656
7706
  "data-disabled": C.disabled
7657
7707
  }, [
7658
- q(D, {
7659
- name: A.value,
7708
+ H1(T, {
7709
+ name: M.value,
7660
7710
  size: 24
7661
7711
  }, null, 8, ["name"])
7662
- ], 10, X2)
7663
- ]),
7664
- u("div", Y2, [
7665
- u("label", {
7712
+ ], 10, l5)
7713
+ ], 8, t5),
7714
+ s("div", {
7715
+ id: `${l.value}-texts`,
7716
+ class: "r-checkbox-texts"
7717
+ }, [
7718
+ s("label", {
7719
+ id: `${l.value}-label`,
7666
7720
  class: "r-checkbox-texts__label",
7667
7721
  "data-disabled": C.disabled,
7668
- for: C.id
7669
- }, b(C.label), 9, J2),
7670
- C.hideDetails ? O("", !0) : (m(), a("div", C5, [
7671
- C.errorMsg ? (m(), a("p", H5, b(C.errorMsg), 1)) : (m(), a("p", V5, b(C.hint), 1))
7672
- ]))
7673
- ])
7722
+ for: l.value
7723
+ }, b(C.label), 9, n5),
7724
+ C.hideDetails ? f("", !0) : (m(), r("div", {
7725
+ key: 0,
7726
+ id: `${l.value}-details`,
7727
+ class: "r-checkbox-texts__details"
7728
+ }, [
7729
+ C.errorMsg ? (m(), r("p", {
7730
+ key: 0,
7731
+ id: `${l.value}-error`,
7732
+ class: "r-checkbox-texts__error"
7733
+ }, b(C.errorMsg), 9, r5)) : (m(), r("p", {
7734
+ key: 1,
7735
+ id: `${l.value}-hint`,
7736
+ class: "r-checkbox-texts__hint"
7737
+ }, b(C.hint), 9, Z5))
7738
+ ], 8, a5))
7739
+ ], 8, o5)
7674
7740
  ]));
7675
7741
  }
7676
- }), L5 = /* @__PURE__ */ R({
7742
+ }), u5 = ["id"], S5 = ["id"], s5 = ["id"], c5 = /* @__PURE__ */ F({
7677
7743
  __name: "RChip",
7678
7744
  props: {
7679
7745
  variant: { default: "primary" },
@@ -7683,220 +7749,226 @@ const y2 = {
7683
7749
  appendIcon: { default: "" },
7684
7750
  ghost: { type: Boolean, default: !1 },
7685
7751
  clearable: { type: Boolean, default: !1 },
7686
- noWrap: { type: Boolean, default: !1 }
7752
+ noWrap: { type: Boolean, default: !1 },
7753
+ id: { default: "r-chip" }
7687
7754
  },
7688
7755
  emits: ["click:chip", "click:close"],
7689
7756
  setup(H, { emit: V }) {
7690
- const C = H, M = V, i = g(() => ({
7757
+ const C = H, i = V, A = h(() => ({
7691
7758
  "r-chip": !0,
7692
7759
  "r-chip--disabled": C.disabled,
7693
7760
  [`r-chip__${C.variant}`]: C.variant,
7694
7761
  [`r-chip__${C.variant}--ghost`]: C.ghost,
7695
7762
  "r-chip--clearable": C.clearable
7696
7763
  }));
7697
- function L(t) {
7698
- C.clearable && t.stopPropagation(), !C.disabled && M("click:chip", t);
7764
+ function L(d) {
7765
+ C.clearable && d.stopPropagation(), !C.disabled && i("click:chip", d);
7699
7766
  }
7700
- function A(t) {
7701
- C.disabled || !C.clearable || (t.stopPropagation(), M("click:close", t));
7767
+ function M(d) {
7768
+ C.disabled || !C.clearable || (d.stopPropagation(), i("click:close", d));
7702
7769
  }
7703
- const e = g(() => C.clearable ? "mdiClose" : C.appendIcon);
7704
- return (t, d) => (m(), a("div", {
7705
- class: p(i.value)
7770
+ const e = h(() => C.clearable ? "mdiClose" : C.appendIcon);
7771
+ return (d, l) => (m(), r("div", {
7772
+ id: d.id,
7773
+ class: O(A.value)
7706
7774
  }, [
7707
- u("div", {
7775
+ s("div", {
7776
+ id: `${d.id}-content`,
7708
7777
  class: "r-chip__content",
7709
- onClick: d[0] || (d[0] = (l) => L(l))
7778
+ onClick: l[0] || (l[0] = (n) => L(n))
7710
7779
  }, [
7711
- h(t.$slots, "prepend", {
7780
+ g(d.$slots, "prepend", {
7712
7781
  disabled: C.disabled
7713
7782
  }, () => [
7714
- C.prependIcon ? (m(), _(D, {
7783
+ C.prependIcon ? (m(), R(T, {
7715
7784
  key: 0,
7785
+ id: `${d.id}-prepend-icon`,
7716
7786
  "aria-disabled": C.disabled,
7717
7787
  class: "r-chip__content__prepend-icon",
7718
7788
  name: C.prependIcon,
7719
7789
  size: 12
7720
- }, null, 8, ["aria-disabled", "name"])) : O("", !0)
7790
+ }, null, 8, ["id", "aria-disabled", "name"])) : f("", !0)
7721
7791
  ]),
7722
- u("span", {
7723
- class: p(["r-chip__content__label", [C.noWrap && "whitespace-nowrap"]])
7724
- }, b(C.label), 3)
7725
- ]),
7726
- h(t.$slots, "append", {
7792
+ s("span", {
7793
+ id: `${d.id}`,
7794
+ class: O(["r-chip__content__label", [C.noWrap && "whitespace-nowrap"]])
7795
+ }, b(C.label), 11, s5)
7796
+ ], 8, S5),
7797
+ g(d.$slots, "append", {
7727
7798
  disabled: C.disabled
7728
7799
  }, () => [
7729
- e.value ? (m(), _(D, {
7800
+ e.value ? (m(), R(T, {
7730
7801
  key: 0,
7802
+ id: `${d.id}-append-icon`,
7731
7803
  "aria-disabled": C.disabled,
7732
7804
  class: "r-chip__content__append-icon",
7733
7805
  name: e.value,
7734
7806
  size: 12,
7735
- onClick: d[1] || (d[1] = (l) => A(l))
7736
- }, null, 8, ["aria-disabled", "name"])) : O("", !0)
7807
+ onClick: l[1] || (l[1] = (n) => M(n))
7808
+ }, null, 8, ["id", "aria-disabled", "name"])) : f("", !0)
7737
7809
  ])
7738
- ], 2));
7810
+ ], 10, u5));
7739
7811
  }
7740
7812
  });
7741
- function M5(H) {
7742
- return h2() ? (g2(H), !0) : !1;
7813
+ function p5(H) {
7814
+ return P2() ? (T2(H), !0) : !1;
7743
7815
  }
7744
- function d2(H) {
7745
- return typeof H == "function" ? H() : J(H);
7816
+ function u2(H) {
7817
+ return typeof H == "function" ? H() : e1(H);
7746
7818
  }
7747
- const m2 = typeof window < "u" && typeof document < "u";
7819
+ const S2 = typeof window < "u" && typeof document < "u";
7748
7820
  typeof WorkerGlobalScope < "u" && globalThis instanceof WorkerGlobalScope;
7749
- const i5 = Object.prototype.toString, A5 = (H) => i5.call(H) === "[object Object]", W1 = () => {
7750
- }, e5 = /* @__PURE__ */ t5();
7751
- function t5() {
7821
+ const O5 = Object.prototype.toString, f5 = (H) => O5.call(H) === "[object Object]", K1 = () => {
7822
+ }, h5 = /* @__PURE__ */ g5();
7823
+ function g5() {
7752
7824
  var H;
7753
- return m2 && ((H = window == null ? void 0 : window.navigator) == null ? void 0 : H.userAgent) && /* @__PURE__ */ /iP(ad|hone|od)/.test(window.navigator.userAgent);
7825
+ return S2 && ((H = window == null ? void 0 : window.navigator) == null ? void 0 : H.userAgent) && /* @__PURE__ */ /iP(ad|hone|od)/.test(window.navigator.userAgent);
7754
7826
  }
7755
- function a1(H) {
7827
+ function p1(H) {
7756
7828
  var V;
7757
- const C = d2(H);
7829
+ const C = u2(H);
7758
7830
  return (V = C == null ? void 0 : C.$el) != null ? V : C;
7759
7831
  }
7760
- const l2 = m2 ? window : void 0;
7761
- function E1(...H) {
7762
- let V, C, M, i;
7763
- if (typeof H[0] == "string" || Array.isArray(H[0]) ? ([C, M, i] = H, V = l2) : [V, C, M, i] = H, !V)
7764
- return W1;
7765
- Array.isArray(C) || (C = [C]), Array.isArray(M) || (M = [M]);
7766
- const L = [], A = () => {
7767
- L.forEach((l) => l()), L.length = 0;
7768
- }, e = (l, r, o, n) => (l.addEventListener(r, o, n), () => l.removeEventListener(r, o, n)), t = G(
7769
- () => [a1(V), d2(i)],
7770
- ([l, r]) => {
7771
- if (A(), !l)
7832
+ const s2 = S2 ? window : void 0;
7833
+ function z1(...H) {
7834
+ let V, C, i, A;
7835
+ if (typeof H[0] == "string" || Array.isArray(H[0]) ? ([C, i, A] = H, V = s2) : [V, C, i, A] = H, !V)
7836
+ return K1;
7837
+ Array.isArray(C) || (C = [C]), Array.isArray(i) || (i = [i]);
7838
+ const L = [], M = () => {
7839
+ L.forEach((n) => n()), L.length = 0;
7840
+ }, e = (n, Z, o, a) => (n.addEventListener(Z, o, a), () => n.removeEventListener(Z, o, a)), d = $(
7841
+ () => [p1(V), u2(A)],
7842
+ ([n, Z]) => {
7843
+ if (M(), !n)
7772
7844
  return;
7773
- const o = A5(r) ? { ...r } : r;
7845
+ const o = f5(Z) ? { ...Z } : Z;
7774
7846
  L.push(
7775
- ...C.flatMap((n) => M.map((S) => e(l, n, S, o)))
7847
+ ...C.flatMap((a) => i.map((S) => e(n, a, S, o)))
7776
7848
  );
7777
7849
  },
7778
7850
  { immediate: !0, flush: "post" }
7779
- ), d = () => {
7780
- t(), A();
7851
+ ), l = () => {
7852
+ d(), M();
7781
7853
  };
7782
- return M5(d), d;
7854
+ return p5(l), l;
7783
7855
  }
7784
- let J1 = !1;
7785
- function d5(H, V, C = {}) {
7786
- const { window: M = l2, ignore: i = [], capture: L = !0, detectIframe: A = !1 } = C;
7787
- if (!M)
7856
+ let e2 = !1;
7857
+ function k5(H, V, C = {}) {
7858
+ const { window: i = s2, ignore: A = [], capture: L = !0, detectIframe: M = !1 } = C;
7859
+ if (!i)
7788
7860
  return;
7789
- e5 && !J1 && (J1 = !0, Array.from(M.document.body.children).forEach((o) => o.addEventListener("click", W1)), M.document.documentElement.addEventListener("click", W1));
7861
+ h5 && !e2 && (e2 = !0, Array.from(i.document.body.children).forEach((o) => o.addEventListener("click", K1)), i.document.documentElement.addEventListener("click", K1));
7790
7862
  let e = !0;
7791
- const t = (o) => i.some((n) => {
7792
- if (typeof n == "string")
7793
- return Array.from(M.document.querySelectorAll(n)).some((S) => S === o.target || o.composedPath().includes(S));
7863
+ const d = (o) => A.some((a) => {
7864
+ if (typeof a == "string")
7865
+ return Array.from(i.document.querySelectorAll(a)).some((S) => S === o.target || o.composedPath().includes(S));
7794
7866
  {
7795
- const S = a1(n);
7867
+ const S = p1(a);
7796
7868
  return S && (o.target === S || o.composedPath().includes(S));
7797
7869
  }
7798
- }), l = [
7799
- E1(M, "click", (o) => {
7800
- const n = a1(H);
7801
- if (!(!n || n === o.target || o.composedPath().includes(n))) {
7802
- if (o.detail === 0 && (e = !t(o)), !e) {
7870
+ }), n = [
7871
+ z1(i, "click", (o) => {
7872
+ const a = p1(H);
7873
+ if (!(!a || a === o.target || o.composedPath().includes(a))) {
7874
+ if (o.detail === 0 && (e = !d(o)), !e) {
7803
7875
  e = !0;
7804
7876
  return;
7805
7877
  }
7806
7878
  V(o);
7807
7879
  }
7808
7880
  }, { passive: !0, capture: L }),
7809
- E1(M, "pointerdown", (o) => {
7810
- const n = a1(H);
7811
- e = !t(o) && !!(n && !o.composedPath().includes(n));
7881
+ z1(i, "pointerdown", (o) => {
7882
+ const a = p1(H);
7883
+ e = !d(o) && !!(a && !o.composedPath().includes(a));
7812
7884
  }, { passive: !0 }),
7813
- A && E1(M, "blur", (o) => {
7885
+ M && z1(i, "blur", (o) => {
7814
7886
  setTimeout(() => {
7815
- var n;
7816
- const S = a1(H);
7817
- ((n = M.document.activeElement) == null ? void 0 : n.tagName) === "IFRAME" && !(S != null && S.contains(M.document.activeElement)) && V(o);
7887
+ var a;
7888
+ const S = p1(H);
7889
+ ((a = i.document.activeElement) == null ? void 0 : a.tagName) === "IFRAME" && !(S != null && S.contains(i.document.activeElement)) && V(o);
7818
7890
  }, 0);
7819
7891
  })
7820
7892
  ].filter(Boolean);
7821
- return () => l.forEach((o) => o());
7893
+ return () => n.forEach((o) => o());
7822
7894
  }
7823
- function m5() {
7895
+ function B5() {
7824
7896
  function H() {
7825
7897
  return ((1 + Math.random()) * 65536 | 0).toString(16).substring(1);
7826
7898
  }
7827
7899
  return `${H() + H()}-${H()}-${H()}-${H()}-${H()}${H()}${H()}`;
7828
7900
  }
7829
- const l5 = ["top", "right", "bottom", "left"], u1 = Math.min, m1 = Math.max, w1 = Math.round, V1 = (H) => ({
7901
+ const b5 = ["top", "right", "bottom", "left"], f1 = Math.min, r1 = Math.max, R1 = Math.round, d1 = (H) => ({
7830
7902
  x: H,
7831
7903
  y: H
7832
- }), o5 = {
7904
+ }), v5 = {
7833
7905
  left: "right",
7834
7906
  right: "left",
7835
7907
  bottom: "top",
7836
7908
  top: "bottom"
7837
- }, n5 = {
7909
+ }, w5 = {
7838
7910
  start: "end",
7839
7911
  end: "start"
7840
7912
  };
7841
- function N1(H, V, C) {
7842
- return m1(H, u1(V, C));
7913
+ function q1(H, V, C) {
7914
+ return r1(H, f1(V, C));
7843
7915
  }
7844
- function n1(H, V) {
7916
+ function s1(H, V) {
7845
7917
  return typeof H == "function" ? H(V) : H;
7846
7918
  }
7847
- function e1(H) {
7919
+ function o1(H) {
7848
7920
  return H.split("-")[0];
7849
7921
  }
7850
- function c1(H) {
7922
+ function g1(H) {
7851
7923
  return H.split("-")[1];
7852
7924
  }
7853
- function o2(H) {
7925
+ function c2(H) {
7854
7926
  return H === "x" ? "y" : "x";
7855
7927
  }
7856
- function U1(H) {
7928
+ function C2(H) {
7857
7929
  return H === "y" ? "height" : "width";
7858
7930
  }
7859
- function R1(H) {
7860
- return ["top", "bottom"].includes(e1(H)) ? "y" : "x";
7931
+ function W1(H) {
7932
+ return ["top", "bottom"].includes(o1(H)) ? "y" : "x";
7861
7933
  }
7862
- function z1(H) {
7863
- return o2(R1(H));
7934
+ function H2(H) {
7935
+ return c2(W1(H));
7864
7936
  }
7865
- function r5(H, V, C) {
7937
+ function y5(H, V, C) {
7866
7938
  C === void 0 && (C = !1);
7867
- const M = c1(H), i = z1(H), L = U1(i);
7868
- let A = i === "x" ? M === (C ? "end" : "start") ? "right" : "left" : M === "start" ? "bottom" : "top";
7869
- return V.reference[L] > V.floating[L] && (A = v1(A)), [A, v1(A)];
7939
+ const i = g1(H), A = H2(H), L = C2(A);
7940
+ let M = A === "x" ? i === (C ? "end" : "start") ? "right" : "left" : i === "start" ? "bottom" : "top";
7941
+ return V.reference[L] > V.floating[L] && (M = x1(M)), [M, x1(M)];
7870
7942
  }
7871
- function a5(H) {
7872
- const V = v1(H);
7873
- return [I1(H), V, I1(V)];
7943
+ function P5(H) {
7944
+ const V = x1(H);
7945
+ return [j1(H), V, j1(V)];
7874
7946
  }
7875
- function I1(H) {
7876
- return H.replace(/start|end/g, (V) => n5[V]);
7947
+ function j1(H) {
7948
+ return H.replace(/start|end/g, (V) => w5[V]);
7877
7949
  }
7878
- function Z5(H, V, C) {
7879
- const M = ["left", "right"], i = ["right", "left"], L = ["top", "bottom"], A = ["bottom", "top"];
7950
+ function T5(H, V, C) {
7951
+ const i = ["left", "right"], A = ["right", "left"], L = ["top", "bottom"], M = ["bottom", "top"];
7880
7952
  switch (H) {
7881
7953
  case "top":
7882
7954
  case "bottom":
7883
- return C ? V ? i : M : V ? M : i;
7955
+ return C ? V ? A : i : V ? i : A;
7884
7956
  case "left":
7885
7957
  case "right":
7886
- return V ? L : A;
7958
+ return V ? L : M;
7887
7959
  default:
7888
7960
  return [];
7889
7961
  }
7890
7962
  }
7891
- function u5(H, V, C, M) {
7892
- const i = c1(H);
7893
- let L = Z5(e1(H), C === "start", M);
7894
- return i && (L = L.map((A) => A + "-" + i), V && (L = L.concat(L.map(I1)))), L;
7963
+ function F5(H, V, C, i) {
7964
+ const A = g1(H);
7965
+ let L = T5(o1(H), C === "start", i);
7966
+ return A && (L = L.map((M) => M + "-" + A), V && (L = L.concat(L.map(j1)))), L;
7895
7967
  }
7896
- function v1(H) {
7897
- return H.replace(/left|right|bottom|top/g, (V) => o5[V]);
7968
+ function x1(H) {
7969
+ return H.replace(/left|right|bottom|top/g, (V) => v5[V]);
7898
7970
  }
7899
- function S5(H) {
7971
+ function R5(H) {
7900
7972
  return {
7901
7973
  top: 0,
7902
7974
  right: 0,
@@ -7905,15 +7977,15 @@ function S5(H) {
7905
7977
  ...H
7906
7978
  };
7907
7979
  }
7908
- function n2(H) {
7909
- return typeof H != "number" ? S5(H) : {
7980
+ function p2(H) {
7981
+ return typeof H != "number" ? R5(H) : {
7910
7982
  top: H,
7911
7983
  right: H,
7912
7984
  bottom: H,
7913
7985
  left: H
7914
7986
  };
7915
7987
  }
7916
- function y1(H) {
7988
+ function D1(H) {
7917
7989
  return {
7918
7990
  ...H,
7919
7991
  top: H.y,
@@ -7922,263 +7994,263 @@ function y1(H) {
7922
7994
  bottom: H.y + H.height
7923
7995
  };
7924
7996
  }
7925
- function C2(H, V, C) {
7997
+ function d2(H, V, C) {
7926
7998
  let {
7927
- reference: M,
7928
- floating: i
7999
+ reference: i,
8000
+ floating: A
7929
8001
  } = H;
7930
- const L = R1(V), A = z1(V), e = U1(A), t = e1(V), d = L === "y", l = M.x + M.width / 2 - i.width / 2, r = M.y + M.height / 2 - i.height / 2, o = M[e] / 2 - i[e] / 2;
7931
- let n;
7932
- switch (t) {
8002
+ const L = W1(V), M = H2(V), e = C2(M), d = o1(V), l = L === "y", n = i.x + i.width / 2 - A.width / 2, Z = i.y + i.height / 2 - A.height / 2, o = i[e] / 2 - A[e] / 2;
8003
+ let a;
8004
+ switch (d) {
7933
8005
  case "top":
7934
- n = {
7935
- x: l,
7936
- y: M.y - i.height
8006
+ a = {
8007
+ x: n,
8008
+ y: i.y - A.height
7937
8009
  };
7938
8010
  break;
7939
8011
  case "bottom":
7940
- n = {
7941
- x: l,
7942
- y: M.y + M.height
8012
+ a = {
8013
+ x: n,
8014
+ y: i.y + i.height
7943
8015
  };
7944
8016
  break;
7945
8017
  case "right":
7946
- n = {
7947
- x: M.x + M.width,
7948
- y: r
8018
+ a = {
8019
+ x: i.x + i.width,
8020
+ y: Z
7949
8021
  };
7950
8022
  break;
7951
8023
  case "left":
7952
- n = {
7953
- x: M.x - i.width,
7954
- y: r
8024
+ a = {
8025
+ x: i.x - A.width,
8026
+ y: Z
7955
8027
  };
7956
8028
  break;
7957
8029
  default:
7958
- n = {
7959
- x: M.x,
7960
- y: M.y
8030
+ a = {
8031
+ x: i.x,
8032
+ y: i.y
7961
8033
  };
7962
8034
  }
7963
- switch (c1(V)) {
8035
+ switch (g1(V)) {
7964
8036
  case "start":
7965
- n[A] -= o * (C && d ? -1 : 1);
8037
+ a[M] -= o * (C && l ? -1 : 1);
7966
8038
  break;
7967
8039
  case "end":
7968
- n[A] += o * (C && d ? -1 : 1);
8040
+ a[M] += o * (C && l ? -1 : 1);
7969
8041
  break;
7970
8042
  }
7971
- return n;
8043
+ return a;
7972
8044
  }
7973
- const s5 = async (H, V, C) => {
8045
+ const x5 = async (H, V, C) => {
7974
8046
  const {
7975
- placement: M = "bottom",
7976
- strategy: i = "absolute",
8047
+ placement: i = "bottom",
8048
+ strategy: A = "absolute",
7977
8049
  middleware: L = [],
7978
- platform: A
7979
- } = C, e = L.filter(Boolean), t = await (A.isRTL == null ? void 0 : A.isRTL(V));
7980
- let d = await A.getElementRects({
8050
+ platform: M
8051
+ } = C, e = L.filter(Boolean), d = await (M.isRTL == null ? void 0 : M.isRTL(V));
8052
+ let l = await M.getElementRects({
7981
8053
  reference: H,
7982
8054
  floating: V,
7983
- strategy: i
8055
+ strategy: A
7984
8056
  }), {
7985
- x: l,
7986
- y: r
7987
- } = C2(d, M, t), o = M, n = {}, S = 0;
8057
+ x: n,
8058
+ y: Z
8059
+ } = d2(l, i, d), o = i, a = {}, S = 0;
7988
8060
  for (let v = 0; v < e.length; v++) {
7989
8061
  const {
7990
8062
  name: B,
7991
- fn: T
8063
+ fn: y
7992
8064
  } = e[v], {
7993
- x: k,
7994
- y,
7995
- data: F,
7996
- reset: P
7997
- } = await T({
7998
- x: l,
7999
- y: r,
8000
- initialPlacement: M,
8065
+ x: u,
8066
+ y: w,
8067
+ data: _,
8068
+ reset: D
8069
+ } = await y({
8070
+ x: n,
8071
+ y: Z,
8072
+ initialPlacement: i,
8001
8073
  placement: o,
8002
- strategy: i,
8003
- middlewareData: n,
8004
- rects: d,
8005
- platform: A,
8074
+ strategy: A,
8075
+ middlewareData: a,
8076
+ rects: l,
8077
+ platform: M,
8006
8078
  elements: {
8007
8079
  reference: H,
8008
8080
  floating: V
8009
8081
  }
8010
8082
  });
8011
- if (l = k ?? l, r = y ?? r, n = {
8012
- ...n,
8083
+ if (n = u ?? n, Z = w ?? Z, a = {
8084
+ ...a,
8013
8085
  [B]: {
8014
- ...n[B],
8015
- ...F
8086
+ ...a[B],
8087
+ ..._
8016
8088
  }
8017
- }, P && S <= 50) {
8018
- S++, typeof P == "object" && (P.placement && (o = P.placement), P.rects && (d = P.rects === !0 ? await A.getElementRects({
8089
+ }, D && S <= 50) {
8090
+ S++, typeof D == "object" && (D.placement && (o = D.placement), D.rects && (l = D.rects === !0 ? await M.getElementRects({
8019
8091
  reference: H,
8020
8092
  floating: V,
8021
- strategy: i
8022
- }) : P.rects), {
8023
- x: l,
8024
- y: r
8025
- } = C2(d, o, t)), v = -1;
8093
+ strategy: A
8094
+ }) : D.rects), {
8095
+ x: n,
8096
+ y: Z
8097
+ } = d2(l, o, d)), v = -1;
8026
8098
  continue;
8027
8099
  }
8028
8100
  }
8029
8101
  return {
8030
- x: l,
8031
- y: r,
8102
+ x: n,
8103
+ y: Z,
8032
8104
  placement: o,
8033
- strategy: i,
8034
- middlewareData: n
8105
+ strategy: A,
8106
+ middlewareData: a
8035
8107
  };
8036
8108
  };
8037
- async function P1(H, V) {
8109
+ async function E1(H, V) {
8038
8110
  var C;
8039
8111
  V === void 0 && (V = {});
8040
8112
  const {
8041
- x: M,
8042
- y: i,
8113
+ x: i,
8114
+ y: A,
8043
8115
  platform: L,
8044
- rects: A,
8116
+ rects: M,
8045
8117
  elements: e,
8046
- strategy: t
8118
+ strategy: d
8047
8119
  } = H, {
8048
- boundary: d = "clippingAncestors",
8049
- rootBoundary: l = "viewport",
8050
- elementContext: r = "floating",
8120
+ boundary: l = "clippingAncestors",
8121
+ rootBoundary: n = "viewport",
8122
+ elementContext: Z = "floating",
8051
8123
  altBoundary: o = !1,
8052
- padding: n = 0
8053
- } = n1(V, H), S = n2(n), B = e[o ? r === "floating" ? "reference" : "floating" : r], T = y1(await L.getClippingRect({
8124
+ padding: a = 0
8125
+ } = s1(V, H), S = p2(a), B = e[o ? Z === "floating" ? "reference" : "floating" : Z], y = D1(await L.getClippingRect({
8054
8126
  element: (C = await (L.isElement == null ? void 0 : L.isElement(B))) == null || C ? B : B.contextElement || await (L.getDocumentElement == null ? void 0 : L.getDocumentElement(e.floating)),
8055
- boundary: d,
8056
- rootBoundary: l,
8057
- strategy: t
8058
- })), k = r === "floating" ? {
8059
- ...A.floating,
8060
- x: M,
8061
- y: i
8062
- } : A.reference, y = await (L.getOffsetParent == null ? void 0 : L.getOffsetParent(e.floating)), F = await (L.isElement == null ? void 0 : L.isElement(y)) ? await (L.getScale == null ? void 0 : L.getScale(y)) || {
8127
+ boundary: l,
8128
+ rootBoundary: n,
8129
+ strategy: d
8130
+ })), u = Z === "floating" ? {
8131
+ ...M.floating,
8132
+ x: i,
8133
+ y: A
8134
+ } : M.reference, w = await (L.getOffsetParent == null ? void 0 : L.getOffsetParent(e.floating)), _ = await (L.isElement == null ? void 0 : L.isElement(w)) ? await (L.getScale == null ? void 0 : L.getScale(w)) || {
8063
8135
  x: 1,
8064
8136
  y: 1
8065
8137
  } : {
8066
8138
  x: 1,
8067
8139
  y: 1
8068
- }, P = y1(L.convertOffsetParentRelativeRectToViewportRelativeRect ? await L.convertOffsetParentRelativeRectToViewportRelativeRect({
8069
- rect: k,
8070
- offsetParent: y,
8071
- strategy: t
8072
- }) : k);
8140
+ }, D = D1(L.convertOffsetParentRelativeRectToViewportRelativeRect ? await L.convertOffsetParentRelativeRectToViewportRelativeRect({
8141
+ rect: u,
8142
+ offsetParent: w,
8143
+ strategy: d
8144
+ }) : u);
8073
8145
  return {
8074
- top: (T.top - P.top + S.top) / F.y,
8075
- bottom: (P.bottom - T.bottom + S.bottom) / F.y,
8076
- left: (T.left - P.left + S.left) / F.x,
8077
- right: (P.right - T.right + S.right) / F.x
8146
+ top: (y.top - D.top + S.top) / _.y,
8147
+ bottom: (D.bottom - y.bottom + S.bottom) / _.y,
8148
+ left: (y.left - D.left + S.left) / _.x,
8149
+ right: (D.right - y.right + S.right) / _.x
8078
8150
  };
8079
8151
  }
8080
- const c5 = (H) => ({
8152
+ const D5 = (H) => ({
8081
8153
  name: "arrow",
8082
8154
  options: H,
8083
8155
  async fn(V) {
8084
8156
  const {
8085
8157
  x: C,
8086
- y: M,
8087
- placement: i,
8158
+ y: i,
8159
+ placement: A,
8088
8160
  rects: L,
8089
- platform: A,
8161
+ platform: M,
8090
8162
  elements: e,
8091
- middlewareData: t
8163
+ middlewareData: d
8092
8164
  } = V, {
8093
- element: d,
8094
- padding: l = 0
8095
- } = n1(H, V) || {};
8096
- if (d == null)
8165
+ element: l,
8166
+ padding: n = 0
8167
+ } = s1(H, V) || {};
8168
+ if (l == null)
8097
8169
  return {};
8098
- const r = n2(l), o = {
8170
+ const Z = p2(n), o = {
8099
8171
  x: C,
8100
- y: M
8101
- }, n = z1(i), S = U1(n), v = await A.getDimensions(d), B = n === "y", T = B ? "top" : "left", k = B ? "bottom" : "right", y = B ? "clientHeight" : "clientWidth", F = L.reference[S] + L.reference[n] - o[n] - L.floating[S], P = o[n] - L.reference[n], U = await (A.getOffsetParent == null ? void 0 : A.getOffsetParent(d));
8102
- let W = U ? U[y] : 0;
8103
- (!W || !await (A.isElement == null ? void 0 : A.isElement(U))) && (W = e.floating[y] || L.floating[S]);
8104
- const f = F / 2 - P / 2, N = W / 2 - v[S] / 2 - 1, i1 = u1(r[T], N), A1 = u1(r[k], N), I = i1, Z = W - v[S] - A1, s = W / 2 - v[S] / 2 + f, w = N1(I, s, Z), x = !t.arrow && c1(i) != null && s != w && L.reference[S] / 2 - (s < I ? i1 : A1) - v[S] / 2 < 0, c = x ? s < I ? s - I : s - Z : 0;
8172
+ y: i
8173
+ }, a = H2(A), S = C2(a), v = await M.getDimensions(l), B = a === "y", y = B ? "top" : "left", u = B ? "bottom" : "right", w = B ? "clientHeight" : "clientWidth", _ = L.reference[S] + L.reference[a] - o[a] - L.floating[S], D = o[a] - L.reference[a], z = await (M.getOffsetParent == null ? void 0 : M.getOffsetParent(l));
8174
+ let W = z ? z[w] : 0;
8175
+ (!W || !await (M.isElement == null ? void 0 : M.isElement(z))) && (W = e.floating[w] || L.floating[S]);
8176
+ const J = _ / 2 - D / 2, k = W / 2 - v[S] / 2 - 1, N = f1(Z[y], k), Q = f1(Z[u], k), x = N, l1 = W - v[S] - Q, I = W / 2 - v[S] / 2 + J, q = q1(x, I, l1), j = !d.arrow && g1(A) != null && I != q && L.reference[S] / 2 - (I < x ? N : Q) - v[S] / 2 < 0, C1 = j ? I < x ? I - x : I - l1 : 0;
8105
8177
  return {
8106
- [n]: o[n] + c,
8178
+ [a]: o[a] + C1,
8107
8179
  data: {
8108
- [n]: w,
8109
- centerOffset: s - w - c,
8110
- ...x && {
8111
- alignmentOffset: c
8180
+ [a]: q,
8181
+ centerOffset: I - q - C1,
8182
+ ...j && {
8183
+ alignmentOffset: C1
8112
8184
  }
8113
8185
  },
8114
- reset: x
8186
+ reset: j
8115
8187
  };
8116
8188
  }
8117
- }), p5 = function(H) {
8189
+ }), E5 = function(H) {
8118
8190
  return H === void 0 && (H = {}), {
8119
8191
  name: "flip",
8120
8192
  options: H,
8121
8193
  async fn(V) {
8122
- var C, M;
8194
+ var C, i;
8123
8195
  const {
8124
- placement: i,
8196
+ placement: A,
8125
8197
  middlewareData: L,
8126
- rects: A,
8198
+ rects: M,
8127
8199
  initialPlacement: e,
8128
- platform: t,
8129
- elements: d
8200
+ platform: d,
8201
+ elements: l
8130
8202
  } = V, {
8131
- mainAxis: l = !0,
8132
- crossAxis: r = !0,
8203
+ mainAxis: n = !0,
8204
+ crossAxis: Z = !0,
8133
8205
  fallbackPlacements: o,
8134
- fallbackStrategy: n = "bestFit",
8206
+ fallbackStrategy: a = "bestFit",
8135
8207
  fallbackAxisSideDirection: S = "none",
8136
8208
  flipAlignment: v = !0,
8137
8209
  ...B
8138
- } = n1(H, V);
8210
+ } = s1(H, V);
8139
8211
  if ((C = L.arrow) != null && C.alignmentOffset)
8140
8212
  return {};
8141
- const T = e1(i), k = e1(e) === e, y = await (t.isRTL == null ? void 0 : t.isRTL(d.floating)), F = o || (k || !v ? [v1(e)] : a5(e));
8142
- !o && S !== "none" && F.push(...u5(e, v, S, y));
8143
- const P = [e, ...F], U = await P1(V, B), W = [];
8144
- let f = ((M = L.flip) == null ? void 0 : M.overflows) || [];
8145
- if (l && W.push(U[T]), r) {
8146
- const I = r5(i, A, y);
8147
- W.push(U[I[0]], U[I[1]]);
8213
+ const y = o1(A), u = o1(e) === e, w = await (d.isRTL == null ? void 0 : d.isRTL(l.floating)), _ = o || (u || !v ? [x1(e)] : P5(e));
8214
+ !o && S !== "none" && _.push(...F5(e, v, S, w));
8215
+ const D = [e, ..._], z = await E1(V, B), W = [];
8216
+ let J = ((i = L.flip) == null ? void 0 : i.overflows) || [];
8217
+ if (n && W.push(z[y]), Z) {
8218
+ const x = y5(A, M, w);
8219
+ W.push(z[x[0]], z[x[1]]);
8148
8220
  }
8149
- if (f = [...f, {
8150
- placement: i,
8221
+ if (J = [...J, {
8222
+ placement: A,
8151
8223
  overflows: W
8152
- }], !W.every((I) => I <= 0)) {
8153
- var N, i1;
8154
- const I = (((N = L.flip) == null ? void 0 : N.index) || 0) + 1, Z = P[I];
8155
- if (Z)
8224
+ }], !W.every((x) => x <= 0)) {
8225
+ var k, N;
8226
+ const x = (((k = L.flip) == null ? void 0 : k.index) || 0) + 1, l1 = D[x];
8227
+ if (l1)
8156
8228
  return {
8157
8229
  data: {
8158
- index: I,
8159
- overflows: f
8230
+ index: x,
8231
+ overflows: J
8160
8232
  },
8161
8233
  reset: {
8162
- placement: Z
8234
+ placement: l1
8163
8235
  }
8164
8236
  };
8165
- let s = (i1 = f.filter((w) => w.overflows[0] <= 0).sort((w, x) => w.overflows[1] - x.overflows[1])[0]) == null ? void 0 : i1.placement;
8166
- if (!s)
8167
- switch (n) {
8237
+ let I = (N = J.filter((q) => q.overflows[0] <= 0).sort((q, j) => q.overflows[1] - j.overflows[1])[0]) == null ? void 0 : N.placement;
8238
+ if (!I)
8239
+ switch (a) {
8168
8240
  case "bestFit": {
8169
- var A1;
8170
- const w = (A1 = f.map((x) => [x.placement, x.overflows.filter((c) => c > 0).reduce((c, Q) => c + Q, 0)]).sort((x, c) => x[1] - c[1])[0]) == null ? void 0 : A1[0];
8171
- w && (s = w);
8241
+ var Q;
8242
+ const q = (Q = J.map((j) => [j.placement, j.overflows.filter((C1) => C1 > 0).reduce((C1, Q1) => C1 + Q1, 0)]).sort((j, C1) => j[1] - C1[1])[0]) == null ? void 0 : Q[0];
8243
+ q && (I = q);
8172
8244
  break;
8173
8245
  }
8174
8246
  case "initialPlacement":
8175
- s = e;
8247
+ I = e;
8176
8248
  break;
8177
8249
  }
8178
- if (i !== s)
8250
+ if (A !== I)
8179
8251
  return {
8180
8252
  reset: {
8181
- placement: s
8253
+ placement: I
8182
8254
  }
8183
8255
  };
8184
8256
  }
@@ -8186,7 +8258,7 @@ const c5 = (H) => ({
8186
8258
  }
8187
8259
  };
8188
8260
  };
8189
- function H2(H, V) {
8261
+ function t2(H, V) {
8190
8262
  return {
8191
8263
  top: H.top - V.height,
8192
8264
  right: H.right - V.width,
@@ -8194,10 +8266,10 @@ function H2(H, V) {
8194
8266
  left: H.left - V.width
8195
8267
  };
8196
8268
  }
8197
- function V2(H) {
8198
- return l5.some((V) => H[V] >= 0);
8269
+ function m2(H) {
8270
+ return b5.some((V) => H[V] >= 0);
8199
8271
  }
8200
- const O5 = function(H) {
8272
+ const _5 = function(H) {
8201
8273
  return H === void 0 && (H = {}), {
8202
8274
  name: "hide",
8203
8275
  options: H,
@@ -8205,31 +8277,31 @@ const O5 = function(H) {
8205
8277
  const {
8206
8278
  rects: C
8207
8279
  } = V, {
8208
- strategy: M = "referenceHidden",
8209
- ...i
8210
- } = n1(H, V);
8211
- switch (M) {
8280
+ strategy: i = "referenceHidden",
8281
+ ...A
8282
+ } = s1(H, V);
8283
+ switch (i) {
8212
8284
  case "referenceHidden": {
8213
- const L = await P1(V, {
8214
- ...i,
8285
+ const L = await E1(V, {
8286
+ ...A,
8215
8287
  elementContext: "reference"
8216
- }), A = H2(L, C.reference);
8288
+ }), M = t2(L, C.reference);
8217
8289
  return {
8218
8290
  data: {
8219
- referenceHiddenOffsets: A,
8220
- referenceHidden: V2(A)
8291
+ referenceHiddenOffsets: M,
8292
+ referenceHidden: m2(M)
8221
8293
  }
8222
8294
  };
8223
8295
  }
8224
8296
  case "escaped": {
8225
- const L = await P1(V, {
8226
- ...i,
8297
+ const L = await E1(V, {
8298
+ ...A,
8227
8299
  altBoundary: !0
8228
- }), A = H2(L, C.floating);
8300
+ }), M = t2(L, C.floating);
8229
8301
  return {
8230
8302
  data: {
8231
- escapedOffsets: A,
8232
- escaped: V2(A)
8303
+ escapedOffsets: M,
8304
+ escaped: m2(M)
8233
8305
  }
8234
8306
  };
8235
8307
  }
@@ -8239,162 +8311,162 @@ const O5 = function(H) {
8239
8311
  }
8240
8312
  };
8241
8313
  };
8242
- async function f5(H, V) {
8314
+ async function $5(H, V) {
8243
8315
  const {
8244
8316
  placement: C,
8245
- platform: M,
8246
- elements: i
8247
- } = H, L = await (M.isRTL == null ? void 0 : M.isRTL(i.floating)), A = e1(C), e = c1(C), t = R1(C) === "y", d = ["left", "top"].includes(A) ? -1 : 1, l = L && t ? -1 : 1, r = n1(V, H);
8317
+ platform: i,
8318
+ elements: A
8319
+ } = H, L = await (i.isRTL == null ? void 0 : i.isRTL(A.floating)), M = o1(C), e = g1(C), d = W1(C) === "y", l = ["left", "top"].includes(M) ? -1 : 1, n = L && d ? -1 : 1, Z = s1(V, H);
8248
8320
  let {
8249
8321
  mainAxis: o,
8250
- crossAxis: n,
8322
+ crossAxis: a,
8251
8323
  alignmentAxis: S
8252
- } = typeof r == "number" ? {
8253
- mainAxis: r,
8324
+ } = typeof Z == "number" ? {
8325
+ mainAxis: Z,
8254
8326
  crossAxis: 0,
8255
8327
  alignmentAxis: null
8256
8328
  } : {
8257
8329
  mainAxis: 0,
8258
8330
  crossAxis: 0,
8259
8331
  alignmentAxis: null,
8260
- ...r
8332
+ ...Z
8261
8333
  };
8262
- return e && typeof S == "number" && (n = e === "end" ? S * -1 : S), t ? {
8263
- x: n * l,
8264
- y: o * d
8334
+ return e && typeof S == "number" && (a = e === "end" ? S * -1 : S), d ? {
8335
+ x: a * n,
8336
+ y: o * l
8265
8337
  } : {
8266
- x: o * d,
8267
- y: n * l
8338
+ x: o * l,
8339
+ y: a * n
8268
8340
  };
8269
8341
  }
8270
- const h5 = function(H) {
8342
+ const W5 = function(H) {
8271
8343
  return H === void 0 && (H = 0), {
8272
8344
  name: "offset",
8273
8345
  options: H,
8274
8346
  async fn(V) {
8275
8347
  const {
8276
8348
  x: C,
8277
- y: M
8278
- } = V, i = await f5(V, H);
8349
+ y: i
8350
+ } = V, A = await $5(V, H);
8279
8351
  return {
8280
- x: C + i.x,
8281
- y: M + i.y,
8282
- data: i
8352
+ x: C + A.x,
8353
+ y: i + A.y,
8354
+ data: A
8283
8355
  };
8284
8356
  }
8285
8357
  };
8286
- }, g5 = function(H) {
8358
+ }, N5 = function(H) {
8287
8359
  return H === void 0 && (H = {}), {
8288
8360
  name: "shift",
8289
8361
  options: H,
8290
8362
  async fn(V) {
8291
8363
  const {
8292
8364
  x: C,
8293
- y: M,
8294
- placement: i
8365
+ y: i,
8366
+ placement: A
8295
8367
  } = V, {
8296
8368
  mainAxis: L = !0,
8297
- crossAxis: A = !1,
8369
+ crossAxis: M = !1,
8298
8370
  limiter: e = {
8299
8371
  fn: (B) => {
8300
8372
  let {
8301
- x: T,
8302
- y: k
8373
+ x: y,
8374
+ y: u
8303
8375
  } = B;
8304
8376
  return {
8305
- x: T,
8306
- y: k
8377
+ x: y,
8378
+ y: u
8307
8379
  };
8308
8380
  }
8309
8381
  },
8310
- ...t
8311
- } = n1(H, V), d = {
8382
+ ...d
8383
+ } = s1(H, V), l = {
8312
8384
  x: C,
8313
- y: M
8314
- }, l = await P1(V, t), r = R1(e1(i)), o = o2(r);
8315
- let n = d[o], S = d[r];
8385
+ y: i
8386
+ }, n = await E1(V, d), Z = W1(o1(A)), o = c2(Z);
8387
+ let a = l[o], S = l[Z];
8316
8388
  if (L) {
8317
- const B = o === "y" ? "top" : "left", T = o === "y" ? "bottom" : "right", k = n + l[B], y = n - l[T];
8318
- n = N1(k, n, y);
8389
+ const B = o === "y" ? "top" : "left", y = o === "y" ? "bottom" : "right", u = a + n[B], w = a - n[y];
8390
+ a = q1(u, a, w);
8319
8391
  }
8320
- if (A) {
8321
- const B = r === "y" ? "top" : "left", T = r === "y" ? "bottom" : "right", k = S + l[B], y = S - l[T];
8322
- S = N1(k, S, y);
8392
+ if (M) {
8393
+ const B = Z === "y" ? "top" : "left", y = Z === "y" ? "bottom" : "right", u = S + n[B], w = S - n[y];
8394
+ S = q1(u, S, w);
8323
8395
  }
8324
8396
  const v = e.fn({
8325
8397
  ...V,
8326
- [o]: n,
8327
- [r]: S
8398
+ [o]: a,
8399
+ [Z]: S
8328
8400
  });
8329
8401
  return {
8330
8402
  ...v,
8331
8403
  data: {
8332
8404
  x: v.x - C,
8333
- y: v.y - M
8405
+ y: v.y - i
8334
8406
  }
8335
8407
  };
8336
8408
  }
8337
8409
  };
8338
8410
  };
8339
- function L1(H) {
8340
- return r2(H) ? (H.nodeName || "").toLowerCase() : "#document";
8411
+ function t1(H) {
8412
+ return O2(H) ? (H.nodeName || "").toLowerCase() : "#document";
8341
8413
  }
8342
- function z(H) {
8414
+ function K(H) {
8343
8415
  var V;
8344
8416
  return (H == null || (V = H.ownerDocument) == null ? void 0 : V.defaultView) || window;
8345
8417
  }
8346
- function M1(H) {
8418
+ function m1(H) {
8347
8419
  var V;
8348
- return (V = (r2(H) ? H.ownerDocument : H.document) || window.document) == null ? void 0 : V.documentElement;
8420
+ return (V = (O2(H) ? H.ownerDocument : H.document) || window.document) == null ? void 0 : V.documentElement;
8349
8421
  }
8350
- function r2(H) {
8351
- return H instanceof Node || H instanceof z(H).Node;
8422
+ function O2(H) {
8423
+ return H instanceof Node || H instanceof K(H).Node;
8352
8424
  }
8353
- function C1(H) {
8354
- return H instanceof Element || H instanceof z(H).Element;
8425
+ function i1(H) {
8426
+ return H instanceof Element || H instanceof K(H).Element;
8355
8427
  }
8356
- function j(H) {
8357
- return H instanceof HTMLElement || H instanceof z(H).HTMLElement;
8428
+ function V1(H) {
8429
+ return H instanceof HTMLElement || H instanceof K(H).HTMLElement;
8358
8430
  }
8359
- function L2(H) {
8360
- return typeof ShadowRoot > "u" ? !1 : H instanceof ShadowRoot || H instanceof z(H).ShadowRoot;
8431
+ function l2(H) {
8432
+ return typeof ShadowRoot > "u" ? !1 : H instanceof ShadowRoot || H instanceof K(H).ShadowRoot;
8361
8433
  }
8362
- function p1(H) {
8434
+ function k1(H) {
8363
8435
  const {
8364
8436
  overflow: V,
8365
8437
  overflowX: C,
8366
- overflowY: M,
8367
- display: i
8368
- } = K(H);
8369
- return /auto|scroll|overlay|hidden|clip/.test(V + M + C) && !["inline", "contents"].includes(i);
8438
+ overflowY: i,
8439
+ display: A
8440
+ } = Y(H);
8441
+ return /auto|scroll|overlay|hidden|clip/.test(V + i + C) && !["inline", "contents"].includes(A);
8370
8442
  }
8371
- function k5(H) {
8372
- return ["table", "td", "th"].includes(L1(H));
8443
+ function I5(H) {
8444
+ return ["table", "td", "th"].includes(t1(H));
8373
8445
  }
8374
- function K1(H) {
8375
- const V = q1(), C = K(H);
8376
- return C.transform !== "none" || C.perspective !== "none" || (C.containerType ? C.containerType !== "normal" : !1) || !V && (C.backdropFilter ? C.backdropFilter !== "none" : !1) || !V && (C.filter ? C.filter !== "none" : !1) || ["transform", "perspective", "filter"].some((M) => (C.willChange || "").includes(M)) || ["paint", "layout", "strict", "content"].some((M) => (C.contain || "").includes(M));
8446
+ function V2(H) {
8447
+ const V = L2(), C = Y(H);
8448
+ return C.transform !== "none" || C.perspective !== "none" || (C.containerType ? C.containerType !== "normal" : !1) || !V && (C.backdropFilter ? C.backdropFilter !== "none" : !1) || !V && (C.filter ? C.filter !== "none" : !1) || ["transform", "perspective", "filter"].some((i) => (C.willChange || "").includes(i)) || ["paint", "layout", "strict", "content"].some((i) => (C.contain || "").includes(i));
8377
8449
  }
8378
- function B5(H) {
8379
- let V = o1(H);
8380
- for (; j(V) && !x1(V); ) {
8381
- if (K1(V))
8450
+ function Q5(H) {
8451
+ let V = S1(H);
8452
+ for (; V1(V) && !N1(V); ) {
8453
+ if (V2(V))
8382
8454
  return V;
8383
- V = o1(V);
8455
+ V = S1(V);
8384
8456
  }
8385
8457
  return null;
8386
8458
  }
8387
- function q1() {
8459
+ function L2() {
8388
8460
  return typeof CSS > "u" || !CSS.supports ? !1 : CSS.supports("-webkit-backdrop-filter", "none");
8389
8461
  }
8390
- function x1(H) {
8391
- return ["html", "body", "#document"].includes(L1(H));
8462
+ function N1(H) {
8463
+ return ["html", "body", "#document"].includes(t1(H));
8392
8464
  }
8393
- function K(H) {
8394
- return z(H).getComputedStyle(H);
8465
+ function Y(H) {
8466
+ return K(H).getComputedStyle(H);
8395
8467
  }
8396
- function D1(H) {
8397
- return C1(H) ? {
8468
+ function I1(H) {
8469
+ return i1(H) ? {
8398
8470
  scrollLeft: H.scrollLeft,
8399
8471
  scrollTop: H.scrollTop
8400
8472
  } : {
@@ -8402,252 +8474,252 @@ function D1(H) {
8402
8474
  scrollTop: H.pageYOffset
8403
8475
  };
8404
8476
  }
8405
- function o1(H) {
8406
- if (L1(H) === "html")
8477
+ function S1(H) {
8478
+ if (t1(H) === "html")
8407
8479
  return H;
8408
8480
  const V = (
8409
8481
  // Step into the shadow DOM of the parent of a slotted node.
8410
8482
  H.assignedSlot || // DOM Element detected.
8411
8483
  H.parentNode || // ShadowRoot detected.
8412
- L2(H) && H.host || // Fallback.
8413
- M1(H)
8484
+ l2(H) && H.host || // Fallback.
8485
+ m1(H)
8414
8486
  );
8415
- return L2(V) ? V.host : V;
8487
+ return l2(V) ? V.host : V;
8416
8488
  }
8417
- function a2(H) {
8418
- const V = o1(H);
8419
- return x1(V) ? H.ownerDocument ? H.ownerDocument.body : H.body : j(V) && p1(V) ? V : a2(V);
8489
+ function f2(H) {
8490
+ const V = S1(H);
8491
+ return N1(V) ? H.ownerDocument ? H.ownerDocument.body : H.body : V1(V) && k1(V) ? V : f2(V);
8420
8492
  }
8421
- function Q1(H, V, C) {
8422
- var M;
8493
+ function X1(H, V, C) {
8494
+ var i;
8423
8495
  V === void 0 && (V = []), C === void 0 && (C = !0);
8424
- const i = a2(H), L = i === ((M = H.ownerDocument) == null ? void 0 : M.body), A = z(i);
8425
- return L ? V.concat(A, A.visualViewport || [], p1(i) ? i : [], A.frameElement && C ? Q1(A.frameElement) : []) : V.concat(i, Q1(i, [], C));
8496
+ const A = f2(H), L = A === ((i = H.ownerDocument) == null ? void 0 : i.body), M = K(A);
8497
+ return L ? V.concat(M, M.visualViewport || [], k1(A) ? A : [], M.frameElement && C ? X1(M.frameElement) : []) : V.concat(A, X1(A, [], C));
8426
8498
  }
8427
- function Z2(H) {
8428
- const V = K(H);
8429
- let C = parseFloat(V.width) || 0, M = parseFloat(V.height) || 0;
8430
- const i = j(H), L = i ? H.offsetWidth : C, A = i ? H.offsetHeight : M, e = w1(C) !== L || w1(M) !== A;
8431
- return e && (C = L, M = A), {
8499
+ function h2(H) {
8500
+ const V = Y(H);
8501
+ let C = parseFloat(V.width) || 0, i = parseFloat(V.height) || 0;
8502
+ const A = V1(H), L = A ? H.offsetWidth : C, M = A ? H.offsetHeight : i, e = R1(C) !== L || R1(i) !== M;
8503
+ return e && (C = L, i = M), {
8432
8504
  width: C,
8433
- height: M,
8505
+ height: i,
8434
8506
  $: e
8435
8507
  };
8436
8508
  }
8437
- function u2(H) {
8438
- return C1(H) ? H : H.contextElement;
8509
+ function g2(H) {
8510
+ return i1(H) ? H : H.contextElement;
8439
8511
  }
8440
- function l1(H) {
8441
- const V = u2(H);
8442
- if (!j(V))
8443
- return V1(1);
8512
+ function Z1(H) {
8513
+ const V = g2(H);
8514
+ if (!V1(V))
8515
+ return d1(1);
8444
8516
  const C = V.getBoundingClientRect(), {
8445
- width: M,
8446
- height: i,
8517
+ width: i,
8518
+ height: A,
8447
8519
  $: L
8448
- } = Z2(V);
8449
- let A = (L ? w1(C.width) : C.width) / M, e = (L ? w1(C.height) : C.height) / i;
8450
- return (!A || !Number.isFinite(A)) && (A = 1), (!e || !Number.isFinite(e)) && (e = 1), {
8451
- x: A,
8520
+ } = h2(V);
8521
+ let M = (L ? R1(C.width) : C.width) / i, e = (L ? R1(C.height) : C.height) / A;
8522
+ return (!M || !Number.isFinite(M)) && (M = 1), (!e || !Number.isFinite(e)) && (e = 1), {
8523
+ x: M,
8452
8524
  y: e
8453
8525
  };
8454
8526
  }
8455
- const b5 = /* @__PURE__ */ V1(0);
8456
- function S2(H) {
8457
- const V = z(H);
8458
- return !q1() || !V.visualViewport ? b5 : {
8527
+ const G5 = /* @__PURE__ */ d1(0);
8528
+ function k2(H) {
8529
+ const V = K(H);
8530
+ return !L2() || !V.visualViewport ? G5 : {
8459
8531
  x: V.visualViewport.offsetLeft,
8460
8532
  y: V.visualViewport.offsetTop
8461
8533
  };
8462
8534
  }
8463
- function w5(H, V, C) {
8464
- return V === void 0 && (V = !1), !C || V && C !== z(H) ? !1 : V;
8535
+ function U5(H, V, C) {
8536
+ return V === void 0 && (V = !1), !C || V && C !== K(H) ? !1 : V;
8465
8537
  }
8466
- function S1(H, V, C, M) {
8538
+ function h1(H, V, C, i) {
8467
8539
  V === void 0 && (V = !1), C === void 0 && (C = !1);
8468
- const i = H.getBoundingClientRect(), L = u2(H);
8469
- let A = V1(1);
8470
- V && (M ? C1(M) && (A = l1(M)) : A = l1(H));
8471
- const e = w5(L, C, M) ? S2(L) : V1(0);
8472
- let t = (i.left + e.x) / A.x, d = (i.top + e.y) / A.y, l = i.width / A.x, r = i.height / A.y;
8540
+ const A = H.getBoundingClientRect(), L = g2(H);
8541
+ let M = d1(1);
8542
+ V && (i ? i1(i) && (M = Z1(i)) : M = Z1(H));
8543
+ const e = U5(L, C, i) ? k2(L) : d1(0);
8544
+ let d = (A.left + e.x) / M.x, l = (A.top + e.y) / M.y, n = A.width / M.x, Z = A.height / M.y;
8473
8545
  if (L) {
8474
- const o = z(L), n = M && C1(M) ? z(M) : M;
8546
+ const o = K(L), a = i && i1(i) ? K(i) : i;
8475
8547
  let S = o.frameElement;
8476
- for (; S && M && n !== o; ) {
8477
- const v = l1(S), B = S.getBoundingClientRect(), T = K(S), k = B.left + (S.clientLeft + parseFloat(T.paddingLeft)) * v.x, y = B.top + (S.clientTop + parseFloat(T.paddingTop)) * v.y;
8478
- t *= v.x, d *= v.y, l *= v.x, r *= v.y, t += k, d += y, S = z(S).frameElement;
8548
+ for (; S && i && a !== o; ) {
8549
+ const v = Z1(S), B = S.getBoundingClientRect(), y = Y(S), u = B.left + (S.clientLeft + parseFloat(y.paddingLeft)) * v.x, w = B.top + (S.clientTop + parseFloat(y.paddingTop)) * v.y;
8550
+ d *= v.x, l *= v.y, n *= v.x, Z *= v.y, d += u, l += w, S = K(S).frameElement;
8479
8551
  }
8480
8552
  }
8481
- return y1({
8482
- width: l,
8483
- height: r,
8484
- x: t,
8485
- y: d
8553
+ return D1({
8554
+ width: n,
8555
+ height: Z,
8556
+ x: d,
8557
+ y: l
8486
8558
  });
8487
8559
  }
8488
- function v5(H) {
8560
+ function z5(H) {
8489
8561
  let {
8490
8562
  rect: V,
8491
8563
  offsetParent: C,
8492
- strategy: M
8564
+ strategy: i
8493
8565
  } = H;
8494
- const i = j(C), L = M1(C);
8566
+ const A = V1(C), L = m1(C);
8495
8567
  if (C === L)
8496
8568
  return V;
8497
- let A = {
8569
+ let M = {
8498
8570
  scrollLeft: 0,
8499
8571
  scrollTop: 0
8500
- }, e = V1(1);
8501
- const t = V1(0);
8502
- if ((i || !i && M !== "fixed") && ((L1(C) !== "body" || p1(L)) && (A = D1(C)), j(C))) {
8503
- const d = S1(C);
8504
- e = l1(C), t.x = d.x + C.clientLeft, t.y = d.y + C.clientTop;
8572
+ }, e = d1(1);
8573
+ const d = d1(0);
8574
+ if ((A || !A && i !== "fixed") && ((t1(C) !== "body" || k1(L)) && (M = I1(C)), V1(C))) {
8575
+ const l = h1(C);
8576
+ e = Z1(C), d.x = l.x + C.clientLeft, d.y = l.y + C.clientTop;
8505
8577
  }
8506
8578
  return {
8507
8579
  width: V.width * e.x,
8508
8580
  height: V.height * e.y,
8509
- x: V.x * e.x - A.scrollLeft * e.x + t.x,
8510
- y: V.y * e.y - A.scrollTop * e.y + t.y
8581
+ x: V.x * e.x - M.scrollLeft * e.x + d.x,
8582
+ y: V.y * e.y - M.scrollTop * e.y + d.y
8511
8583
  };
8512
8584
  }
8513
- function y5(H) {
8585
+ function K5(H) {
8514
8586
  return Array.from(H.getClientRects());
8515
8587
  }
8516
- function s2(H) {
8517
- return S1(M1(H)).left + D1(H).scrollLeft;
8588
+ function B2(H) {
8589
+ return h1(m1(H)).left + I1(H).scrollLeft;
8518
8590
  }
8519
- function P5(H) {
8520
- const V = M1(H), C = D1(H), M = H.ownerDocument.body, i = m1(V.scrollWidth, V.clientWidth, M.scrollWidth, M.clientWidth), L = m1(V.scrollHeight, V.clientHeight, M.scrollHeight, M.clientHeight);
8521
- let A = -C.scrollLeft + s2(H);
8591
+ function q5(H) {
8592
+ const V = m1(H), C = I1(H), i = H.ownerDocument.body, A = r1(V.scrollWidth, V.clientWidth, i.scrollWidth, i.clientWidth), L = r1(V.scrollHeight, V.clientHeight, i.scrollHeight, i.clientHeight);
8593
+ let M = -C.scrollLeft + B2(H);
8522
8594
  const e = -C.scrollTop;
8523
- return K(M).direction === "rtl" && (A += m1(V.clientWidth, M.clientWidth) - i), {
8524
- width: i,
8595
+ return Y(i).direction === "rtl" && (M += r1(V.clientWidth, i.clientWidth) - A), {
8596
+ width: A,
8525
8597
  height: L,
8526
- x: A,
8598
+ x: M,
8527
8599
  y: e
8528
8600
  };
8529
8601
  }
8530
- function T5(H, V) {
8531
- const C = z(H), M = M1(H), i = C.visualViewport;
8532
- let L = M.clientWidth, A = M.clientHeight, e = 0, t = 0;
8533
- if (i) {
8534
- L = i.width, A = i.height;
8535
- const d = q1();
8536
- (!d || d && V === "fixed") && (e = i.offsetLeft, t = i.offsetTop);
8602
+ function j5(H, V) {
8603
+ const C = K(H), i = m1(H), A = C.visualViewport;
8604
+ let L = i.clientWidth, M = i.clientHeight, e = 0, d = 0;
8605
+ if (A) {
8606
+ L = A.width, M = A.height;
8607
+ const l = L2();
8608
+ (!l || l && V === "fixed") && (e = A.offsetLeft, d = A.offsetTop);
8537
8609
  }
8538
8610
  return {
8539
8611
  width: L,
8540
- height: A,
8612
+ height: M,
8541
8613
  x: e,
8542
- y: t
8614
+ y: d
8543
8615
  };
8544
8616
  }
8545
- function F5(H, V) {
8546
- const C = S1(H, !0, V === "fixed"), M = C.top + H.clientTop, i = C.left + H.clientLeft, L = j(H) ? l1(H) : V1(1), A = H.clientWidth * L.x, e = H.clientHeight * L.y, t = i * L.x, d = M * L.y;
8617
+ function X5(H, V) {
8618
+ const C = h1(H, !0, V === "fixed"), i = C.top + H.clientTop, A = C.left + H.clientLeft, L = V1(H) ? Z1(H) : d1(1), M = H.clientWidth * L.x, e = H.clientHeight * L.y, d = A * L.x, l = i * L.y;
8547
8619
  return {
8548
- width: A,
8620
+ width: M,
8549
8621
  height: e,
8550
- x: t,
8551
- y: d
8622
+ x: d,
8623
+ y: l
8552
8624
  };
8553
8625
  }
8554
- function M2(H, V, C) {
8555
- let M;
8626
+ function o2(H, V, C) {
8627
+ let i;
8556
8628
  if (V === "viewport")
8557
- M = T5(H, C);
8629
+ i = j5(H, C);
8558
8630
  else if (V === "document")
8559
- M = P5(M1(H));
8560
- else if (C1(V))
8561
- M = F5(V, C);
8631
+ i = q5(m1(H));
8632
+ else if (i1(V))
8633
+ i = X5(V, C);
8562
8634
  else {
8563
- const i = S2(H);
8564
- M = {
8635
+ const A = k2(H);
8636
+ i = {
8565
8637
  ...V,
8566
- x: V.x - i.x,
8567
- y: V.y - i.y
8638
+ x: V.x - A.x,
8639
+ y: V.y - A.y
8568
8640
  };
8569
8641
  }
8570
- return y1(M);
8642
+ return D1(i);
8571
8643
  }
8572
- function c2(H, V) {
8573
- const C = o1(H);
8574
- return C === V || !C1(C) || x1(C) ? !1 : K(C).position === "fixed" || c2(C, V);
8644
+ function b2(H, V) {
8645
+ const C = S1(H);
8646
+ return C === V || !i1(C) || N1(C) ? !1 : Y(C).position === "fixed" || b2(C, V);
8575
8647
  }
8576
- function R5(H, V) {
8648
+ function Y5(H, V) {
8577
8649
  const C = V.get(H);
8578
8650
  if (C)
8579
8651
  return C;
8580
- let M = Q1(H, [], !1).filter((e) => C1(e) && L1(e) !== "body"), i = null;
8581
- const L = K(H).position === "fixed";
8582
- let A = L ? o1(H) : H;
8583
- for (; C1(A) && !x1(A); ) {
8584
- const e = K(A), t = K1(A);
8585
- !t && e.position === "fixed" && (i = null), (L ? !t && !i : !t && e.position === "static" && !!i && ["absolute", "fixed"].includes(i.position) || p1(A) && !t && c2(H, A)) ? M = M.filter((l) => l !== A) : i = e, A = o1(A);
8652
+ let i = X1(H, [], !1).filter((e) => i1(e) && t1(e) !== "body"), A = null;
8653
+ const L = Y(H).position === "fixed";
8654
+ let M = L ? S1(H) : H;
8655
+ for (; i1(M) && !N1(M); ) {
8656
+ const e = Y(M), d = V2(M);
8657
+ !d && e.position === "fixed" && (A = null), (L ? !d && !A : !d && e.position === "static" && !!A && ["absolute", "fixed"].includes(A.position) || k1(M) && !d && b2(H, M)) ? i = i.filter((n) => n !== M) : A = e, M = S1(M);
8586
8658
  }
8587
- return V.set(H, M), M;
8659
+ return V.set(H, i), i;
8588
8660
  }
8589
- function x5(H) {
8661
+ function J5(H) {
8590
8662
  let {
8591
8663
  element: V,
8592
8664
  boundary: C,
8593
- rootBoundary: M,
8594
- strategy: i
8665
+ rootBoundary: i,
8666
+ strategy: A
8595
8667
  } = H;
8596
- const A = [...C === "clippingAncestors" ? R5(V, this._c) : [].concat(C), M], e = A[0], t = A.reduce((d, l) => {
8597
- const r = M2(V, l, i);
8598
- return d.top = m1(r.top, d.top), d.right = u1(r.right, d.right), d.bottom = u1(r.bottom, d.bottom), d.left = m1(r.left, d.left), d;
8599
- }, M2(V, e, i));
8668
+ const M = [...C === "clippingAncestors" ? Y5(V, this._c) : [].concat(C), i], e = M[0], d = M.reduce((l, n) => {
8669
+ const Z = o2(V, n, A);
8670
+ return l.top = r1(Z.top, l.top), l.right = f1(Z.right, l.right), l.bottom = f1(Z.bottom, l.bottom), l.left = r1(Z.left, l.left), l;
8671
+ }, o2(V, e, A));
8600
8672
  return {
8601
- width: t.right - t.left,
8602
- height: t.bottom - t.top,
8603
- x: t.left,
8604
- y: t.top
8673
+ width: d.right - d.left,
8674
+ height: d.bottom - d.top,
8675
+ x: d.left,
8676
+ y: d.top
8605
8677
  };
8606
8678
  }
8607
- function D5(H) {
8608
- return Z2(H);
8679
+ function C3(H) {
8680
+ return h2(H);
8609
8681
  }
8610
- function _5(H, V, C) {
8611
- const M = j(V), i = M1(V), L = C === "fixed", A = S1(H, !0, L, V);
8682
+ function H3(H, V, C) {
8683
+ const i = V1(V), A = m1(V), L = C === "fixed", M = h1(H, !0, L, V);
8612
8684
  let e = {
8613
8685
  scrollLeft: 0,
8614
8686
  scrollTop: 0
8615
8687
  };
8616
- const t = V1(0);
8617
- if (M || !M && !L)
8618
- if ((L1(V) !== "body" || p1(i)) && (e = D1(V)), M) {
8619
- const d = S1(V, !0, L, V);
8620
- t.x = d.x + V.clientLeft, t.y = d.y + V.clientTop;
8688
+ const d = d1(0);
8689
+ if (i || !i && !L)
8690
+ if ((t1(V) !== "body" || k1(A)) && (e = I1(V)), i) {
8691
+ const l = h1(V, !0, L, V);
8692
+ d.x = l.x + V.clientLeft, d.y = l.y + V.clientTop;
8621
8693
  } else
8622
- i && (t.x = s2(i));
8694
+ A && (d.x = B2(A));
8623
8695
  return {
8624
- x: A.left + e.scrollLeft - t.x,
8625
- y: A.top + e.scrollTop - t.y,
8626
- width: A.width,
8627
- height: A.height
8696
+ x: M.left + e.scrollLeft - d.x,
8697
+ y: M.top + e.scrollTop - d.y,
8698
+ width: M.width,
8699
+ height: M.height
8628
8700
  };
8629
8701
  }
8630
- function i2(H, V) {
8631
- return !j(H) || K(H).position === "fixed" ? null : V ? V(H) : H.offsetParent;
8702
+ function n2(H, V) {
8703
+ return !V1(H) || Y(H).position === "fixed" ? null : V ? V(H) : H.offsetParent;
8632
8704
  }
8633
- function p2(H, V) {
8634
- const C = z(H);
8635
- if (!j(H))
8705
+ function v2(H, V) {
8706
+ const C = K(H);
8707
+ if (!V1(H))
8636
8708
  return C;
8637
- let M = i2(H, V);
8638
- for (; M && k5(M) && K(M).position === "static"; )
8639
- M = i2(M, V);
8640
- return M && (L1(M) === "html" || L1(M) === "body" && K(M).position === "static" && !K1(M)) ? C : M || B5(H) || C;
8709
+ let i = n2(H, V);
8710
+ for (; i && I5(i) && Y(i).position === "static"; )
8711
+ i = n2(i, V);
8712
+ return i && (t1(i) === "html" || t1(i) === "body" && Y(i).position === "static" && !V2(i)) ? C : i || Q5(H) || C;
8641
8713
  }
8642
- const E5 = async function(H) {
8714
+ const V3 = async function(H) {
8643
8715
  let {
8644
8716
  reference: V,
8645
8717
  floating: C,
8646
- strategy: M
8718
+ strategy: i
8647
8719
  } = H;
8648
- const i = this.getOffsetParent || p2, L = this.getDimensions;
8720
+ const A = this.getOffsetParent || v2, L = this.getDimensions;
8649
8721
  return {
8650
- reference: _5(V, await i(C), M),
8722
+ reference: H3(V, await A(C), i),
8651
8723
  floating: {
8652
8724
  x: 0,
8653
8725
  y: 0,
@@ -8655,82 +8727,83 @@ const E5 = async function(H) {
8655
8727
  }
8656
8728
  };
8657
8729
  };
8658
- function W5(H) {
8659
- return K(H).direction === "rtl";
8730
+ function L3(H) {
8731
+ return Y(H).direction === "rtl";
8660
8732
  }
8661
- const N5 = {
8662
- convertOffsetParentRelativeRectToViewportRelativeRect: v5,
8663
- getDocumentElement: M1,
8664
- getClippingRect: x5,
8665
- getOffsetParent: p2,
8666
- getElementRects: E5,
8667
- getClientRects: y5,
8668
- getDimensions: D5,
8669
- getScale: l1,
8670
- isElement: C1,
8671
- isRTL: W5
8672
- }, I5 = (H, V, C) => {
8673
- const M = /* @__PURE__ */ new Map(), i = {
8674
- platform: N5,
8733
+ const M3 = {
8734
+ convertOffsetParentRelativeRectToViewportRelativeRect: z5,
8735
+ getDocumentElement: m1,
8736
+ getClippingRect: J5,
8737
+ getOffsetParent: v2,
8738
+ getElementRects: V3,
8739
+ getClientRects: K5,
8740
+ getDimensions: C3,
8741
+ getScale: Z1,
8742
+ isElement: i1,
8743
+ isRTL: L3
8744
+ }, i3 = (H, V, C) => {
8745
+ const i = /* @__PURE__ */ new Map(), A = {
8746
+ platform: M3,
8675
8747
  ...C
8676
8748
  }, L = {
8677
- ...i.platform,
8678
- _c: M
8749
+ ...A.platform,
8750
+ _c: i
8679
8751
  };
8680
- return s5(H, V, {
8681
- ...i,
8752
+ return x5(H, V, {
8753
+ ...A,
8682
8754
  platform: L
8683
8755
  });
8684
8756
  };
8685
- var O2 = /* @__PURE__ */ ((H) => (H.Top = "top", H.Bottom = "bottom", H.Left = "left", H.Right = "right", H.TopStart = "top-start", H.TopEnd = "top-end", H.RightStart = "right-start", H.RightEnd = "right-end", H.BottomStart = "bottom-start", H.BottomEnd = "bottom-end", H.LeftStart = "left-start", H.LeftEnd = "left-end", H))(O2 || {}), Y = /* @__PURE__ */ ((H) => (H.Click = "click", H.Hover = "hover", H.Manual = "manual", H))(Y || {}), G1 = /* @__PURE__ */ ((H) => (H.Tooltip = "tooltip", H.Popover = "popover", H.Dropdown = "dropdown", H))(G1 || {});
8686
- async function Q5({ value: H }, { value: V }, { value: C }, M, i, L, A = 300, e) {
8687
- !H || !V || I5(H, V, {
8688
- placement: M,
8757
+ var w2 = /* @__PURE__ */ ((H) => (H.Top = "top", H.Bottom = "bottom", H.Left = "left", H.Right = "right", H.TopStart = "top-start", H.TopEnd = "top-end", H.RightStart = "right-start", H.RightEnd = "right-end", H.BottomStart = "bottom-start", H.BottomEnd = "bottom-end", H.LeftStart = "left-start", H.LeftEnd = "left-end", H))(w2 || {}), M1 = /* @__PURE__ */ ((H) => (H.Click = "click", H.Hover = "hover", H.Manual = "manual", H))(M1 || {}), T1 = /* @__PURE__ */ ((H) => (H.Tooltip = "tooltip", H.Popover = "popover", H.Dropdown = "dropdown", H))(T1 || {});
8758
+ async function A3({ value: H }, { value: V }, { value: C }, i, A, L, M = 300, e) {
8759
+ !H || !V || i3(H, V, {
8760
+ placement: i,
8689
8761
  middleware: [
8690
- h5(i),
8691
- g5({ padding: L }),
8692
- c5({ element: C }),
8693
- p5(),
8694
- O5()
8762
+ W5(A),
8763
+ N5({ padding: L }),
8764
+ D5({ element: C }),
8765
+ E5(),
8766
+ _5()
8695
8767
  ]
8696
- }).then(({ x: t, y: d, placement: l, middlewareData: r }) => {
8768
+ }).then(({ x: d, y: l, placement: n, middlewareData: Z }) => {
8697
8769
  var S, v;
8698
8770
  if (!V)
8699
8771
  return;
8700
- r.flip && V.setAttribute("data-placement", l);
8701
- const o = (S = H.offsetParent) == null ? void 0 : S.getBoundingClientRect().left, n = (v = H.offsetParent) == null ? void 0 : v.getBoundingClientRect().width;
8772
+ Z.flip && V.setAttribute("data-placement", n);
8773
+ const o = (S = H.offsetParent) == null ? void 0 : S.getBoundingClientRect().left, a = (v = H.offsetParent) == null ? void 0 : v.getBoundingClientRect().width;
8702
8774
  if (Object.assign(V.style, {
8703
- maxWidth: e === "dropdown" ? `${n}px` : "auto",
8704
- left: e === "dropdown" ? `${o}px` : `${t}px`,
8705
- top: `${d}px`,
8706
- animation: `r-tooltip-show ${A}ms ease-in-out forwards`,
8775
+ maxWidth: e === "dropdown" ? `${a}px` : "auto",
8776
+ left: e === "dropdown" ? `${o}px` : `${d}px`,
8777
+ top: `${l}px`,
8778
+ animation: `r-tooltip-show ${M}ms ease-in-out forwards`,
8707
8779
  transformOrigin: "start"
8708
- }), C && r.arrow) {
8709
- const { x: B, y: T } = r.arrow, k = {
8780
+ }), C && Z.arrow) {
8781
+ const { x: B, y } = Z.arrow, u = {
8710
8782
  top: "bottom",
8711
8783
  right: "left",
8712
8784
  bottom: "top",
8713
8785
  left: "right"
8714
8786
  /* Right */
8715
- }[l.split("-")[0]];
8787
+ }[n.split("-")[0]];
8716
8788
  Object.assign(C.style, {
8717
- left: t != null ? `${B}px` : "",
8718
- top: d != null ? `${T}px` : "",
8789
+ left: d != null ? `${B}px` : "",
8790
+ top: l != null ? `${y}px` : "",
8719
8791
  right: "",
8720
8792
  bottom: "",
8721
- [`${k}`]: "-4px"
8793
+ [`${u}`]: "-4px"
8722
8794
  });
8723
8795
  }
8724
8796
  });
8725
8797
  }
8726
- const G5 = ["aria-disabled"], $5 = ["innerHTML"], U5 = ["id"], z5 = /* @__PURE__ */ R({
8798
+ const e3 = ["id", "aria-disabled"], d3 = ["innerHTML"], t3 = ["id"], m3 = ["id"], l3 = /* @__PURE__ */ F({
8727
8799
  __name: "RTooltip",
8728
8800
  props: {
8729
- placement: { default: O2.Top },
8801
+ id: { default: "r-tooltip" },
8802
+ placement: { default: w2.Top },
8730
8803
  text: { default: "" },
8731
8804
  dark: { type: Boolean, default: !0 },
8732
8805
  light: { type: Boolean, default: !1 },
8733
- triggers: { default: () => [Y.Hover] },
8806
+ triggers: { default: () => [M1.Hover] },
8734
8807
  autoHide: { type: Boolean, default: !0 },
8735
8808
  hideDelay: { default: 3e3 },
8736
8809
  showDelay: { default: 300 },
@@ -8744,169 +8817,158 @@ const G5 = ["aria-disabled"], $5 = ["innerHTML"], U5 = ["id"], z5 = /* @__PURE__
8744
8817
  triggerClass: { default: "" },
8745
8818
  tooltipClass: { default: "" },
8746
8819
  persistent: { type: Boolean, default: !1 },
8747
- type: { default: G1.Tooltip }
8820
+ type: { default: T1.Tooltip }
8748
8821
  },
8749
8822
  emits: ["show", "hide"],
8750
8823
  setup(H, { emit: V }) {
8751
- const C = H, M = V, i = E(), L = E(), A = E(), e = m5();
8752
- let t = null;
8753
- async function d() {
8824
+ const C = H, i = V, A = E(), L = E(), M = E(), e = B5();
8825
+ let d = null;
8826
+ async function l() {
8754
8827
  if (!(C.disabled || !L.value)) {
8755
8828
  if (!C.persistent) {
8756
- const k = document.querySelectorAll(
8829
+ const u = document.querySelectorAll(
8757
8830
  ".r-tooltip--active"
8758
8831
  );
8759
- k.length > 0 && k.forEach((y) => {
8760
- y.dataset.persistent === "true" || (y.style.display = "", y.classList.remove("r-tooltip--active"), y.dataset.show = "false");
8832
+ u.length > 0 && u.forEach((w) => {
8833
+ w.dataset.persistent === "true" || (w.style.display = "", w.classList.remove("r-tooltip--active"), w.dataset.show = "false");
8761
8834
  });
8762
8835
  }
8763
- L.value.classList.contains("r-tooltip--active") ? l() : (B(), L.value.style.display = "block", L.value.classList.add("r-tooltip--active"), L.value.dataset.show = "true", L.value.dataset.persistent = C.persistent.toString(), M("show", L.value.id), r());
8836
+ L.value.classList.contains("r-tooltip--active") ? n() : (B(), L.value.style.display = "block", L.value.classList.add("r-tooltip--active"), L.value.dataset.show = "true", L.value.dataset.persistent = C.persistent.toString(), i("show", L.value.id), Z());
8764
8837
  }
8765
8838
  }
8766
- function l(k = null) {
8767
- C.disabled || !L.value || (L.value.style.display = "", L.value.classList.remove("r-tooltip--active"), L.value.dataset.show = "false", L.value.dataset.persistent = "false", M("hide", L.value.id));
8839
+ function n(u = null) {
8840
+ C.disabled || !L.value || (L.value.style.display = "", L.value.classList.remove("r-tooltip--active"), L.value.dataset.show = "false", L.value.dataset.persistent = "false", i("hide", L.value.id));
8768
8841
  }
8769
- function r() {
8842
+ function Z() {
8770
8843
  C.autoHide && setTimeout(() => {
8771
- l();
8844
+ n();
8772
8845
  }, C.hideDelay);
8773
8846
  }
8774
- function o(k) {
8775
- C.disabled || C.triggers.includes(Y.Click) && (L.value.style.display === "block" ? l() : d());
8847
+ function o(u) {
8848
+ C.disabled || C.triggers.includes(M1.Click) && (L.value.style.display === "block" ? n() : l());
8776
8849
  }
8777
- function n() {
8778
- C.disabled || C.triggers.includes(Y.Hover) && d();
8850
+ function a() {
8851
+ C.disabled || C.triggers.includes(M1.Hover) && l();
8779
8852
  }
8780
8853
  function S() {
8781
- C.disabled || (L.value.style.display === "" && C.triggers.includes(Y.Hover) ? d() : L.value.style.display !== "" && C.triggers.includes(Y.Hover) && l());
8854
+ C.disabled || (L.value.style.display === "" && C.triggers.includes(M1.Hover) ? l() : L.value.style.display !== "" && C.triggers.includes(M1.Hover) && n());
8782
8855
  }
8783
8856
  function v() {
8784
- C.triggers.includes(Y.Hover) && B();
8857
+ C.triggers.includes(M1.Hover) && B();
8785
8858
  }
8786
- function B(k) {
8787
- const { placement: y, offset: F, padding: P, disabled: U, showDelay: W, type: f } = C;
8788
- U || Q5(
8789
- i,
8790
- L,
8859
+ function B() {
8860
+ const { placement: u, offset: w, padding: _, disabled: D, showDelay: z, type: W } = C;
8861
+ D || A3(
8791
8862
  A,
8792
- y,
8793
- F,
8794
- P,
8795
- W,
8796
- f
8863
+ L,
8864
+ M,
8865
+ u,
8866
+ w,
8867
+ _,
8868
+ z,
8869
+ W
8797
8870
  );
8798
8871
  }
8799
- const T = g(() => ({
8872
+ const y = h(() => ({
8800
8873
  "r-tooltip": !0,
8801
8874
  "r-tooltip--dark": C.dark && !C.light,
8802
- "r-tooltip--light": C.light
8875
+ "r-tooltip--light": C.light,
8876
+ "r-tooltip--dropdown": C.type === T1.Dropdown
8803
8877
  }));
8804
8878
  return window.onresize = () => {
8805
8879
  C.resizable && B();
8806
- }, j1(
8880
+ }, M2(
8807
8881
  () => {
8808
- C.disabled || (C.shown && C.triggers.includes(Y.Manual) ? d() : !C.shown && C.triggers.includes(Y.Manual) && l());
8882
+ C.disabled || (C.shown && C.triggers.includes(M1.Manual) ? l() : !C.shown && C.triggers.includes(M1.Manual) && n());
8809
8883
  },
8810
8884
  { flush: "post" }
8811
8885
  // this is important to avoid infinite loop & for fire on mounted
8812
- ), j1(() => {
8813
- t && (t(), t = null), C.outsideClick && i.value && (t = d5(
8814
- i,
8815
- (k) => {
8816
- L.value && L.value.classList.contains("r-tooltip--active") && l(k);
8886
+ ), M2(() => {
8887
+ d && (d(), d = null), C.outsideClick && A.value && (d = k5(
8888
+ A,
8889
+ (u) => {
8890
+ L.value && L.value.classList.contains("r-tooltip--active") && n(u);
8817
8891
  },
8818
8892
  { ignore: [L] }
8819
- ));
8820
- }), A2(() => {
8821
- var k, y;
8822
- C.resizable && ((y = (k = i.value) == null ? void 0 : k.parentElement) == null || y.parentElement.addEventListener(
8893
+ ) ?? null);
8894
+ }), a2(() => {
8895
+ var u, w;
8896
+ C.resizable && ((w = (u = A.value) == null ? void 0 : u.parentElement) == null || w.parentElement.addEventListener(
8823
8897
  "scroll",
8824
- B()
8825
- )), C.type === G1.Dropdown && document.addEventListener("scroll", () => {
8898
+ () => B()
8899
+ )), C.type === T1.Dropdown && document.addEventListener("scroll", () => {
8826
8900
  B();
8827
8901
  });
8828
- }), e2(() => {
8829
- t && (t(), t = null);
8830
- }), (k, y) => (m(), a(H1, null, [
8831
- u("div", {
8902
+ }), Y1(() => {
8903
+ d && (d(), d = null);
8904
+ }), (u, w) => (m(), r(A1, null, [
8905
+ s("div", {
8906
+ id: u.id,
8832
8907
  ref_key: "trigger",
8833
- ref: i,
8908
+ ref: A,
8834
8909
  "aria-disabled": C.disabled,
8835
- class: p(["r-tooltip-trigger", k.triggerClass]),
8910
+ class: O(["r-tooltip-trigger", u.triggerClass]),
8836
8911
  onClick: o,
8837
- onMouseenter: n,
8912
+ onMouseenter: a,
8838
8913
  onMouseleave: S,
8839
8914
  onMousemove: v
8840
8915
  }, [
8841
- h(k.$slots, "default", {
8916
+ g(u.$slots, "default", {
8917
+ id: `${u.id}-slot`,
8842
8918
  activators: {
8843
8919
  click: o,
8844
- mouseenter: n,
8920
+ mouseenter: a,
8845
8921
  mouseleave: S,
8846
8922
  mousemove: v
8847
8923
  },
8848
- tooltipId: J(e),
8924
+ tooltipId: e1(e),
8849
8925
  updatePosition: B
8850
8926
  }, () => [
8851
- u("div", {
8927
+ s("div", {
8852
8928
  innerHTML: C.triggerContent
8853
- }, null, 8, $5)
8929
+ }, null, 8, d3)
8854
8930
  ])
8855
- ], 42, G5),
8856
- (m(), _(k2, { to: "body" }, [
8857
- u("div", {
8858
- id: J(e),
8931
+ ], 42, e3),
8932
+ (m(), R(r2, { to: "body" }, [
8933
+ s("div", {
8934
+ id: `${u.id}-tooltip`,
8859
8935
  ref_key: "tooltip",
8860
8936
  ref: L,
8861
- class: p([T.value, k.tooltipClass]),
8937
+ class: O([y.value, u.tooltipClass]),
8862
8938
  "data-show": "false",
8863
8939
  role: "tooltip"
8864
8940
  }, [
8865
- h(k.$slots, "content", {
8866
- hide: l,
8941
+ g(u.$slots, "content", {
8942
+ id: `${u.id}-content-slot`,
8943
+ hide: n,
8867
8944
  updatePosition: B
8868
8945
  }, () => [
8869
- C.text ? (m(), a("div", {
8946
+ C.text ? (m(), r("div", {
8870
8947
  key: 0,
8871
- class: p(["r-tooltip__content", {
8948
+ class: O(["r-tooltip__content", {
8872
8949
  "r-tooltip__content--dark": C.dark,
8873
8950
  "r-tooltip__content--light": C.light
8874
8951
  }])
8875
- }, b(C.text), 3)) : O("", !0),
8876
- C.text ? (m(), a("div", {
8952
+ }, b(C.text), 3)) : f("", !0),
8953
+ C.text ? (m(), r("div", {
8877
8954
  key: 1,
8878
- id: "arrow",
8955
+ id: `${u.id}-arrow`,
8879
8956
  ref_key: "arrowElement",
8880
- ref: A,
8881
- class: p(["r-tooltip__arrow", {
8957
+ ref: M,
8958
+ class: O(["r-tooltip__arrow", {
8882
8959
  "r-tooltip__arrow--dark": C.dark,
8883
8960
  "r-tooltip__arrow--light": C.light
8884
8961
  }])
8885
- }, null, 2)) : O("", !0)
8962
+ }, null, 10, m3)) : f("", !0)
8886
8963
  ])
8887
- ], 10, U5)
8964
+ ], 10, t3)
8888
8965
  ]))
8889
8966
  ], 64));
8890
8967
  }
8891
- }), K5 = ["id", "onClick"], q5 = { class: "r-dropdown__selections" }, j5 = { class: "flex flex-wrap items-center gap-2 text-sm" }, X5 = {
8892
- key: 0,
8893
- class: "r-dropdown__remaining-count-text"
8894
- }, Y5 = ["id", "autocomplete", "disabled", "placeholder", "readonly", "onInput", "onKeydown"], J5 = ["id", "data-has-value", "onClick"], C3 = ["onClick"], H3 = { class: "flex items-center" }, V3 = { class: "r-dropdown-options__option__label" }, L3 = {
8895
- key: 1,
8896
- class: "r-dropdown-options__divider"
8897
- }, M3 = ["aria-disabled", "onClick"], i3 = { class: "flex items-center" }, A3 = {
8898
- key: 2,
8899
- class: "r-dropdown-options__no-option"
8900
- }, e3 = {
8901
- key: 0,
8902
- class: "r-dropdown-details"
8903
- }, t3 = {
8968
+ }), o3 = ["id"], n3 = ["id"], a3 = ["id", "onClick"], r3 = ["id"], Z3 = ["id"], u3 = ["id"], S3 = ["id"], s3 = ["id"], c3 = ["id", "autocomplete", "disabled", "placeholder", "readonly", "onInput", "onKeydown"], p3 = ["id", "data-has-value", "onClick"], O3 = ["id"], f3 = ["id"], h3 = {
8904
8969
  key: 0,
8905
- class: "r-dropdown-error"
8906
- }, d3 = {
8907
- key: 1,
8908
- class: "r-dropdown-hint"
8909
- }, m3 = /* @__PURE__ */ R({
8970
+ class: "r-dropdown-options__loading"
8971
+ }, g3 = { key: 1 }, k3 = ["onClick"], B3 = { class: "flex items-center" }, b3 = { class: "r-dropdown-options__option__label" }, v3 = ["id"], w3 = ["id", "aria-disabled", "onClick"], y3 = ["id"], P3 = ["id"], T3 = ["id"], F3 = ["id"], R3 = ["id"], x3 = ["id"], D3 = /* @__PURE__ */ F({
8910
8972
  __name: "RDropdown",
8911
8973
  props: {
8912
8974
  options: { default: () => [] },
@@ -8935,140 +8997,209 @@ const G5 = ["aria-disabled"], $5 = ["innerHTML"], U5 = ["id"], z5 = /* @__PURE__
8935
8997
  showSelectAll: { type: Boolean, default: !1 },
8936
8998
  selectAllText: { default: "Select all" },
8937
8999
  disableDeselect: { type: Boolean, default: !1 },
8938
- maxVisibleChips: { default: 2 }
9000
+ maxVisibleChips: { default: 2 },
9001
+ innerSearch: { type: Boolean, default: !0 },
9002
+ searchLoading: { type: Boolean, default: !1 }
8939
9003
  },
8940
- emits: ["update:modelValue", "clear", "removeOption"],
9004
+ emits: ["update:modelValue", "clear", "removeOption", "search"],
8941
9005
  setup(H, { emit: V }) {
8942
- const C = H, M = V, i = E({}), L = E([]), A = E(!1), e = E("");
8943
- function t(Z) {
8944
- if (!Z || typeof Z == "object" || typeof Z == "function" || typeof Z == "symbol" || typeof Z > "u" || Array.isArray(Z))
9006
+ const C = H, i = V, A = E({}), L = E([]), M = E(!1), e = E("");
9007
+ function d(t) {
9008
+ const c = window.getComputedStyle(t);
9009
+ return /(auto|scroll|overlay)/.test(c.overflowY);
9010
+ }
9011
+ function l(t) {
9012
+ let c = t;
9013
+ for (; c && c !== document.body; ) {
9014
+ if (d(c))
9015
+ return c;
9016
+ c = c.parentElement;
9017
+ }
9018
+ return document.body;
9019
+ }
9020
+ function n(t) {
9021
+ if (!t || typeof t == "object" || typeof t == "function" || typeof t == "symbol" || typeof t > "u" || Array.isArray(t))
8945
9022
  return !0;
8946
- const [s] = Object == null ? void 0 : Object.keys(Z);
8947
- return ["label", "value"].includes(s);
9023
+ const [c] = Object.keys(t);
9024
+ return ["label", "value"].includes(c);
8948
9025
  }
8949
- const d = g(() => {
8950
- const Z = C.options;
8951
- return t(Z[0]) ? Z : Z.map((s) => ({
8952
- value: s,
8953
- label: String(s)
9026
+ const Z = h(() => {
9027
+ const t = C.options;
9028
+ return n(t[0]) ? t : t.map((c) => ({
9029
+ value: c,
9030
+ label: String(c)
8954
9031
  }));
8955
- }), l = g(() => {
8956
- const Z = C.modelValue;
8957
- return t(Z) ? Z : {
8958
- value: Z,
8959
- label: String(Z)
9032
+ }), o = h(() => {
9033
+ const t = C.modelValue;
9034
+ return n(t) ? t : {
9035
+ value: t,
9036
+ label: String(t)
8960
9037
  };
8961
- }), r = E(), o = E(), n = E();
8962
- function S(Z) {
8963
- var x, c, Q, O1;
9038
+ }), a = E(), S = E(), v = E(), B = E(null);
9039
+ function y(t) {
9040
+ B.value = t;
9041
+ }
9042
+ const u = E(null);
9043
+ function w() {
9044
+ if (!u.value) {
9045
+ const t = v.value || a.value;
9046
+ t && (u.value = l(t));
9047
+ }
9048
+ u.value && (M.value ? u.value.dataset.rOriginalOverflow || (u.value.dataset.rOriginalOverflow = u.value.style.overflowY || "", u.value.style.overflowY = "hidden") : u.value.dataset.rOriginalOverflow !== void 0 && (u.value.style.overflowY = u.value.dataset.rOriginalOverflow, delete u.value.dataset.rOriginalOverflow));
9049
+ }
9050
+ function _(t) {
9051
+ var X, p, G, B1;
8964
9052
  if (C.disabled)
8965
9053
  return;
8966
- const s = document.getElementById(Z);
8967
- document.querySelectorAll(".r-dropdown--active").forEach(($) => {
8968
- var f1;
8969
- $.id !== ((f1 = r.value) == null ? void 0 : f1.id) && $.classList.contains("r-dropdown--active") && ($.childNodes.forEach((X) => {
8970
- X != null && X.classList && (Object == null || Object.values(X == null ? void 0 : X.classList).filter((_1) => _1.includes("--active")).forEach((_1) => {
8971
- X == null || X.classList.remove(_1);
8972
- }));
8973
- }), $.classList.remove("r-dropdown--active"));
8974
- }), s != null && s.classList.contains("r-dropdown--active") ? (s.classList.remove("r-dropdown--active"), A.value = !1, (x = r.value) == null || x.blur(), (c = o.value) == null || c.blur()) : (s == null || s.classList.add("r-dropdown--active"), A.value = !0, (Q = r.value) == null || Q.focus(), (O1 = o.value) == null || O1.focus(), s == null || s.childNodes.forEach(($) => {
8975
- $ != null && $.classList && (Object == null || Object.values($ == null ? void 0 : $.classList).forEach((f1) => {
8976
- $ == null || $.classList.add(`${f1}--active`);
9054
+ const c = document.getElementById(t);
9055
+ document.querySelectorAll(".r-dropdown--active").forEach((U) => {
9056
+ var b1;
9057
+ if (U.id !== ((b1 = a.value) == null ? void 0 : b1.id) && U.classList.contains("r-dropdown--active")) {
9058
+ const c1 = l(
9059
+ U
9060
+ );
9061
+ c1 && c1.dataset.rOriginalOverflow !== void 0 && (c1.style.overflowY = c1.dataset.rOriginalOverflow, delete c1.dataset.rOriginalOverflow), U.childNodes.forEach((L1) => {
9062
+ L1 != null && L1.classList && (Object == null || Object.values(L1 == null ? void 0 : L1.classList).filter((U1) => U1.includes("--active")).forEach((U1) => {
9063
+ L1 == null || L1.classList.remove(U1);
9064
+ }));
9065
+ }), U.classList.remove("r-dropdown--active");
9066
+ }
9067
+ }), c != null && c.classList.contains("r-dropdown--active") ? (c.classList.remove("r-dropdown--active"), M.value = !1, (X = a.value) == null || X.blur(), (p = S.value) == null || p.blur()) : (c == null || c.classList.add("r-dropdown--active"), M.value = !0, (G = a.value) == null || G.focus(), (B1 = S.value) == null || B1.focus(), c == null || c.childNodes.forEach((U) => {
9068
+ U != null && U.classList && (Object == null || Object.values(U == null ? void 0 : U.classList).forEach((b1) => {
9069
+ U == null || U.classList.add(`${b1}--active`);
8977
9070
  }));
8978
9071
  }));
8979
9072
  }
8980
- function v(Z) {
8981
- const s = document.getElementById(Z);
8982
- s == null || s.classList.remove("r-dropdown--active"), A.value = !1;
9073
+ function D(t) {
9074
+ const c = document.getElementById(t);
9075
+ c == null || c.classList.remove("r-dropdown--active"), M.value = !1;
8983
9076
  }
8984
- function B(Z, s, w, x) {
8985
- var c;
8986
- if (!(C.disabled || s.disabled)) {
8987
- if (x(), s.value === "select-all") {
8988
- i1();
9077
+ function z() {
9078
+ var t;
9079
+ (t = B.value) == null || t.call(B);
9080
+ }
9081
+ function W(t, c, P, X) {
9082
+ var p;
9083
+ if (!(C.disabled || c.disabled)) {
9084
+ if (X(), c.value === "select-all") {
9085
+ C1();
8989
9086
  return;
8990
9087
  }
8991
9088
  if (C.multiple) {
8992
- if (!L.value.find((Q) => Q.value === s.value))
8993
- L.value.push(s);
9089
+ if (!L.value.find((G) => G.value === c.value))
9090
+ L.value.push(c);
8994
9091
  else {
8995
- const Q = L.value.findIndex((O1) => O1.value === s.value);
8996
- L.value.splice(Q, 1), M("removeOption", s);
9092
+ const G = L.value.findIndex(
9093
+ (B1) => B1.value === c.value
9094
+ );
9095
+ L.value.splice(G, 1), i("removeOption", c);
8997
9096
  }
8998
- e.value = "", C.searchable && ((c = o.value) == null || c.focus());
9097
+ e.value = "", C.searchable && ((p = S.value) == null || p.focus());
8999
9098
  return;
9000
9099
  }
9001
- T(Z, s), C.closeOnSelect && w();
9100
+ J(t, c), C.closeOnSelect && P();
9002
9101
  }
9003
9102
  }
9004
- function T(Z, s) {
9005
- if (i.value.value === s.value && !C.disableDeselect) {
9006
- i.value = {}, e.value = "", M("update:modelValue", ""), M("removeOption", s);
9103
+ function J(t, c) {
9104
+ if (A.value.value === c.value && !C.disableDeselect) {
9105
+ A.value = {}, e.value = "", i("update:modelValue", ""), i("removeOption", c);
9007
9106
  return;
9008
9107
  }
9009
- e.value = s.label, i.value = s, M("update:modelValue", s);
9108
+ e.value = c.label, A.value = c, i("update:modelValue", c);
9010
9109
  }
9011
- function k(Z, s, w) {
9012
- if (Z instanceof KeyboardEvent && Z.key !== "Backspace" || e.value !== "")
9110
+ function k(t, c, P) {
9111
+ if (t instanceof KeyboardEvent && t.key !== "Backspace" || e.value !== "")
9013
9112
  return;
9014
- Z.stopPropagation(), w();
9015
- const x = L.value.findIndex((c) => c.value === s.value);
9016
- L.value.splice(x, 1), M("removeOption", s), M("update:modelValue", L.value);
9113
+ t.stopPropagation(), P();
9114
+ const X = L.value.findIndex(
9115
+ (p) => p.value === c.value
9116
+ );
9117
+ L.value.splice(X, 1), i("removeOption", c), i("update:modelValue", L.value);
9017
9118
  }
9018
- function y(Z, s) {
9019
- var c;
9119
+ function N(t, c) {
9120
+ var p;
9020
9121
  if (!C.multiple)
9021
9122
  return;
9022
- Z.stopPropagation(), s();
9023
- const w = e.value;
9024
- if (w === "")
9123
+ t.stopPropagation(), c();
9124
+ const P = e.value;
9125
+ if (P === "")
9025
9126
  return;
9026
- d.value.find((Q) => Q.label === w) || (L.value.push({ value: w, label: w }), e.value = "", (c = o.value) == null || c.focus());
9127
+ Z.value.find(
9128
+ (G) => G.label === P
9129
+ ) || (L.value.push({ value: P, label: P }), e.value = "", (p = S.value) == null || p.focus());
9027
9130
  }
9028
- function F(Z) {
9029
- var s;
9030
- return !Z || (Z == null ? void 0 : Z.value) === void 0 || (Z == null ? void 0 : Z.value) === null ? !1 : C.multiple ? L.value.find((w) => (w == null ? void 0 : w.value) === (Z == null ? void 0 : Z.value)) : ((s = i.value) == null ? void 0 : s.value) === (Z == null ? void 0 : Z.value);
9131
+ function Q(t) {
9132
+ var c;
9133
+ return !t || (t == null ? void 0 : t.value) === void 0 || (t == null ? void 0 : t.value) === null ? !1 : C.multiple ? L.value.find((P) => (P == null ? void 0 : P.value) === (t == null ? void 0 : t.value)) : ((c = A.value) == null ? void 0 : c.value) === (t == null ? void 0 : t.value);
9031
9134
  }
9032
- const P = g(() => !C.searchable || i.value.label === e.value ? d.value : d.value.filter((s) => s.label.toLowerCase().includes(e.value.toLowerCase()))), U = g(() => !C.searchable);
9033
- function W() {
9034
- l.value ? C.multiple ? L.value = l.value : (i.value = l.value, e.value = l.value.label) : (i.value = {}, L.value.splice(0, L.value.length));
9135
+ const x = h(() => !C.searchable || A.value.label === e.value || !C.innerSearch && C.searchable ? Z.value : Z.value.filter((c) => c.label.toLowerCase().includes(e.value.toLowerCase()))), l1 = h(() => !C.searchable);
9136
+ function I() {
9137
+ o.value ? C.multiple ? L.value = o.value : (A.value = o.value, e.value = o.value.label) : (A.value = {}, L.value.splice(0, L.value.length));
9035
9138
  }
9036
- function f(Z) {
9037
- C.searchable && Z(), !C.multiple && e.value === "" && (i.value = {}, M("update:modelValue", ""), M("removeOption", i.value));
9139
+ function q(t) {
9140
+ C.searchable && t(), !C.multiple && e.value === "" && (A.value = {}, i("update:modelValue", ""), i("removeOption", A.value));
9038
9141
  }
9039
- function N(Z, s) {
9040
- if (Z.stopPropagation(), s(), C.multiple) {
9041
- L.value.splice(0, L.value.length), M("clear", L.value);
9142
+ function j(t, c) {
9143
+ if (t.stopPropagation(), c(), C.multiple) {
9144
+ L.value.splice(0, L.value.length), i("clear", L.value);
9042
9145
  return;
9043
9146
  }
9044
- i.value = {}, e.value = "", M("update:modelValue", ""), M("clear", i.value);
9147
+ A.value = {}, e.value = "", i("update:modelValue", ""), i("clear", A.value);
9045
9148
  }
9046
- function i1() {
9047
- if (L.value.length === P.value.length) {
9149
+ function C1() {
9150
+ if (L.value.length === x.value.length) {
9048
9151
  L.value.splice(0, L.value.length);
9049
9152
  return;
9050
9153
  }
9051
- L.value = P.value;
9154
+ L.value = x.value;
9052
9155
  }
9053
- const A1 = g(() => !C.multiple || !Array.isArray(C.modelValue) ? [] : C.modelValue.slice(0, C.maxVisibleChips)), I = g(() => !C.multiple || !Array.isArray(C.modelValue) ? 0 : Math.max(0, C.modelValue.length - C.maxVisibleChips));
9054
- return A2(() => {
9055
- W(), navigator.userAgent.includes("iPhone") && document.querySelector("[name=viewport]").setAttribute("content", "width=device-width, initial-scale=1, maximum-scale=1");
9056
- }), G(
9156
+ const Q1 = h(() => !C.multiple || !Array.isArray(C.modelValue) ? [] : C.modelValue.slice(0, C.maxVisibleChips)), G1 = h(() => !C.multiple || !Array.isArray(C.modelValue) ? 0 : Math.max(0, C.modelValue.length - C.maxVisibleChips));
9157
+ return a2(() => {
9158
+ I(), navigator.userAgent.includes("iPhone") && document.querySelector("[name=viewport]").setAttribute(
9159
+ "content",
9160
+ "width=device-width, initial-scale=1, maximum-scale=1"
9161
+ );
9162
+ }), $(
9057
9163
  L,
9058
- (Z) => {
9059
- M("update:modelValue", Z);
9164
+ (t) => {
9165
+ i("update:modelValue", t);
9060
9166
  },
9061
9167
  {
9062
9168
  deep: !0
9063
9169
  }
9064
- ), G(() => l.value, (Z) => {
9065
- W();
9066
- }), (Z, s) => (m(), a("div", {
9170
+ ), $(
9171
+ () => o.value,
9172
+ (t) => {
9173
+ I();
9174
+ }
9175
+ ), $(
9176
+ () => M.value,
9177
+ () => {
9178
+ w();
9179
+ }
9180
+ ), $(
9181
+ () => e.value,
9182
+ (t) => {
9183
+ !C.innerSearch && C.searchable && A.value.label !== t && i("search", t.trim());
9184
+ }
9185
+ ), Y1(() => {
9186
+ u.value && u.value.dataset.rOriginalOverflow !== void 0 && (u.value.style.overflowY = u.value.dataset.rOriginalOverflow, delete u.value.dataset.rOriginalOverflow);
9187
+ }), (t, c) => (m(), r("div", {
9188
+ id: t.id,
9067
9189
  ref_key: "wrapper",
9068
- ref: n,
9190
+ ref: v,
9069
9191
  class: "r-dropdown-wrapper"
9070
9192
  }, [
9071
- q(z5, {
9193
+ (m(), R(r2, { to: "body" }, [
9194
+ M.value ? (m(), r("div", {
9195
+ key: 0,
9196
+ id: `${t.id}-overlay`,
9197
+ class: "r-dropdown-overlay",
9198
+ onClick: z
9199
+ }, null, 8, n3)) : f("", !0)
9200
+ ])),
9201
+ H1(l3, {
9202
+ id: `${t.id}-tooltip`,
9072
9203
  "auto-hide": !1,
9073
9204
  disabled: C.disabled,
9074
9205
  offset: 0,
@@ -9078,16 +9209,16 @@ const G5 = ["aria-disabled"], $5 = ["innerHTML"], U5 = ["id"], z5 = /* @__PURE__
9078
9209
  "trigger-class": "w-full",
9079
9210
  triggers: ["click"],
9080
9211
  type: "dropdown",
9081
- onHide: s[1] || (s[1] = (w) => {
9082
- v(w);
9212
+ onHide: c[1] || (c[1] = (P) => {
9213
+ D(P);
9083
9214
  })
9084
9215
  }, {
9085
- default: b1(({ updatePosition: w, tooltipId: x }) => [
9086
- u("div", {
9087
- id: x,
9216
+ default: F1(({ updatePosition: P, tooltipId: X }) => [
9217
+ s("div", {
9218
+ id: `${t.id}-dropdown`,
9088
9219
  ref_key: "dropdown",
9089
- ref: r,
9090
- class: p(["r-dropdown", {
9220
+ ref: a,
9221
+ class: O(["r-dropdown", {
9091
9222
  "r-dropdown--disabled": C.disabled,
9092
9223
  "r-dropdown--loading": C.loading,
9093
9224
  [C.dropdownClass]: C.dropdownClass,
@@ -9095,199 +9226,268 @@ const G5 = ["aria-disabled"], $5 = ["innerHTML"], U5 = ["id"], z5 = /* @__PURE__
9095
9226
  group: e.value !== "" || L.value.length
9096
9227
  }]),
9097
9228
  role: "select",
9098
- onClick: (c) => S(x)
9229
+ onClick: (p) => _(X)
9099
9230
  }, [
9100
- C.prependIcon || Z.$slots.prepend ? (m(), a("div", {
9231
+ C.prependIcon || t.$slots.prepend ? (m(), r("div", {
9101
9232
  key: 0,
9102
- class: p(["r-dropdown__prepend-icon", {
9103
- "r-dropdown__prepend-icon--active": A.value,
9233
+ id: `${t.id}-prepend-icon`,
9234
+ class: O(["r-dropdown__prepend-icon", {
9235
+ "r-dropdown__prepend-icon--active": M.value,
9104
9236
  "r-dropdown__prepend-icon--error": C.errorMsg
9105
9237
  }])
9106
9238
  }, [
9107
- h(Z.$slots, "prepend", {
9108
- active: A.value,
9239
+ g(t.$slots, "prepend", {
9240
+ id: `${t.id}-prepend-icon`,
9241
+ active: M.value,
9109
9242
  disabled: C.disabled,
9110
9243
  error: C.errorMsg.length,
9111
9244
  loading: C.loading
9112
9245
  }, () => [
9113
- C.prependIcon ? (m(), _(D, {
9246
+ C.prependIcon ? (m(), R(T, {
9114
9247
  key: 0,
9248
+ id: `${t.id}-prepend-icon`,
9115
9249
  name: C.prependIcon
9116
- }, null, 8, ["name"])) : O("", !0)
9250
+ }, null, 8, ["id", "name"])) : f("", !0)
9117
9251
  ])
9118
- ], 2)) : O("", !0),
9119
- u("div", q5, [
9120
- h(Z.$slots, "selection", {
9252
+ ], 10, r3)) : f("", !0),
9253
+ s("div", {
9254
+ id: `${t.id}-selections`,
9255
+ class: "r-dropdown__selections"
9256
+ }, [
9257
+ g(t.$slots, "selection", {
9258
+ id: `${t.id}-selection`,
9121
9259
  removeOption: k,
9122
9260
  selected: L.value
9123
9261
  }, () => [
9124
- u("div", j5, [
9125
- C.multiple && C.chips ? (m(), a(H1, { key: 0 }, [
9126
- (m(!0), a(H1, null, t1(A1.value, (c) => (m(), _(L5, {
9127
- key: c.value,
9262
+ s("div", {
9263
+ id: `${t.id}-selections-content`,
9264
+ class: "flex flex-wrap items-center gap-2 text-sm"
9265
+ }, [
9266
+ C.multiple && C.chips ? (m(), r(A1, { key: 0 }, [
9267
+ (m(!0), r(A1, null, n1(Q1.value, (p) => (m(), R(c5, {
9268
+ key: p.value,
9269
+ id: `${t.id}-chip-${p.value}`,
9128
9270
  clearable: "",
9129
9271
  ghost: "",
9130
- label: c.label,
9272
+ label: p.label,
9131
9273
  variant: "primary",
9132
- "onClick:close": (Q) => k(Q, c, w)
9133
- }, null, 8, ["label", "onClick:close"]))), 128)),
9134
- h(Z.$slots, "remaining-count", { count: I.value }, () => [
9135
- I.value > 0 ? (m(), a("span", X5, " +" + b(I.value), 1)) : O("", !0)
9274
+ "onClick:close": (G) => k(G, p, P)
9275
+ }, null, 8, ["id", "label", "onClick:close"]))), 128)),
9276
+ g(t.$slots, "remaining-count", {
9277
+ id: `${t.id}-remaining-count`,
9278
+ count: G1.value
9279
+ }, () => [
9280
+ G1.value > 0 ? (m(), r("span", {
9281
+ key: 0,
9282
+ id: `${t.id}-remaining-count-text`,
9283
+ class: "r-dropdown__remaining-count-text"
9284
+ }, " +" + b(G1.value), 9, S3)) : f("", !0)
9136
9285
  ])
9137
- ], 64)) : C.multiple ? (m(!0), a(H1, { key: 1 }, t1(L.value, (c, Q) => (m(), a("span", {
9138
- key: c.value
9139
- }, b(c.label) + b(Q < L.value.length - 1 ? ", " : ""), 1))), 128)) : O("", !0)
9140
- ])
9286
+ ], 64)) : C.multiple ? (m(!0), r(A1, { key: 1 }, n1(L.value, (p, G) => (m(), r("span", {
9287
+ id: `${t.id}-selected-option-${G}`,
9288
+ key: p.value
9289
+ }, b(p.label) + " " + b(G < L.value.length - 1 ? ", " : ""), 9, s3))), 128)) : f("", !0)
9290
+ ], 8, u3)
9141
9291
  ]),
9142
- t2(u("input", {
9143
- id: C.id,
9292
+ Z2(s("input", {
9293
+ id: `${t.id}`,
9144
9294
  ref_key: "input",
9145
- ref: o,
9146
- "onUpdate:modelValue": s[0] || (s[0] = (c) => e.value = c),
9295
+ ref: S,
9296
+ "onUpdate:modelValue": c[0] || (c[0] = (p) => e.value = p),
9147
9297
  autocomplete: C.autocomplete,
9148
- class: p(["r-dropdown__input", {
9298
+ class: O(["r-dropdown__input", {
9149
9299
  "r-dropdown__input--loading": C.loading
9150
9300
  }]),
9151
9301
  disabled: C.disabled,
9152
9302
  placeholder: C.placeholder,
9153
- readonly: U.value,
9303
+ readonly: l1.value,
9154
9304
  role: "presentation",
9155
9305
  type: "text",
9156
- onInput: d1((c) => f(w), ["prevent"]),
9306
+ onInput: a1((p) => q(P), ["prevent"]),
9157
9307
  onKeydown: [
9158
- X1((c) => k(c, L.value[L.value.length - 1], w), ["backspace"]),
9159
- X1((c) => y(c, w), ["enter"])
9308
+ i2((p) => k(
9309
+ p,
9310
+ L.value[L.value.length - 1],
9311
+ P
9312
+ ), ["backspace"]),
9313
+ i2((p) => N(p, P), ["enter"])
9160
9314
  ]
9161
- }, null, 42, Y5), [
9162
- [B2, e.value]
9315
+ }, null, 42, c3), [
9316
+ [F2, e.value]
9163
9317
  ])
9164
- ]),
9165
- C.clearable ? (m(), a("div", {
9318
+ ], 8, Z3),
9319
+ C.clearable ? (m(), r("div", {
9166
9320
  key: 1,
9167
9321
  id: C.id ? `${C.id}-clearable-icon` : "clearable-icon",
9168
9322
  class: "r-dropdown__clearable",
9169
- "data-has-value": (e.value !== "" || L.value.length) && A.value,
9170
- onClick: (c) => N(c, w)
9323
+ "data-has-value": (e.value !== "" || L.value.length) && M.value,
9324
+ onClick: (p) => j(p, P)
9171
9325
  }, [
9172
- h(Z.$slots, "clearable", {}, () => [
9173
- q(D, {
9326
+ g(t.$slots, "clearable", {}, () => [
9327
+ H1(T, {
9328
+ id: `${t.id}-clearable-icon`,
9174
9329
  name: "mdiCloseCircle",
9175
9330
  size: "18"
9176
- })
9331
+ }, null, 8, ["id"])
9177
9332
  ])
9178
- ], 8, J5)) : O("", !0),
9179
- C.appendIcon || Z.$slots.append ? (m(), a("div", {
9333
+ ], 8, p3)) : f("", !0),
9334
+ C.appendIcon || t.$slots.append ? (m(), r("div", {
9180
9335
  key: 2,
9181
- class: p(["r-dropdown__append-icon", {
9182
- "r-dropdown__append-icon--active": A.value,
9336
+ id: `${t.id}-append-icon`,
9337
+ class: O(["r-dropdown__append-icon", {
9338
+ "r-dropdown__append-icon--active": M.value,
9183
9339
  "r-dropdown__append-icon--error": C.errorMsg
9184
9340
  }])
9185
9341
  }, [
9186
- h(Z.$slots, "append", {
9187
- active: A.value,
9342
+ g(t.$slots, "append", {
9343
+ id: `${t.id}-append-icon`,
9344
+ active: M.value,
9188
9345
  disabled: C.disabled,
9189
9346
  error: C.errorMsg.length,
9190
9347
  loading: C.loading
9191
9348
  }, () => [
9192
- C.appendIcon ? (m(), _(D, {
9349
+ C.appendIcon ? (m(), R(T, {
9193
9350
  key: 0,
9194
9351
  name: C.appendIcon
9195
- }, null, 8, ["name"])) : O("", !0)
9352
+ }, null, 8, ["name"])) : f("", !0)
9196
9353
  ])
9197
- ], 2)) : O("", !0)
9198
- ], 10, K5)
9354
+ ], 10, O3)) : f("", !0)
9355
+ ], 10, a3)
9199
9356
  ]),
9200
- content: b1(({ hide: w, updatePosition: x }) => [
9201
- u("ul", {
9202
- class: p(["r-dropdown-options", {
9203
- "r-dropdown-options--active": A.value,
9357
+ content: F1(({ hide: P, updatePosition: X }) => [
9358
+ u1(b(y(P)) + " ", 1),
9359
+ s("ul", {
9360
+ id: `${t.id}-options`,
9361
+ class: O(["r-dropdown-options", {
9362
+ "r-dropdown-options--active": M.value,
9204
9363
  [C.optionsClass]: C.optionsClass
9205
9364
  }])
9206
9365
  }, [
9207
- C.showSelectAll && C.multiple && P.value.length > 0 ? (m(), a("li", {
9208
- key: 0,
9209
- class: p(["r-dropdown-options__option", {
9210
- "r-dropdown-options__option--active": L.value.length === P.value.length,
9211
- "r-dropdown-options__option--disabled": !1
9212
- }]),
9213
- onClick: d1((c) => B(c, { label: C.selectAllText, value: "select-all" }, w, x), ["prevent"])
9214
- }, [
9215
- u("div", H3, [
9216
- u("p", V3, b(C.selectAllText), 1)
9217
- ]),
9218
- L.value.length === P.value.length && !C.hideOptionCheckIcon ? (m(), _(D, {
9366
+ C.searchLoading ? (m(), r("div", h3, [
9367
+ H1(T, {
9368
+ name: "mdiLoading",
9369
+ size: "24"
9370
+ })
9371
+ ])) : x.value.length > 0 ? (m(), r("div", g3, [
9372
+ C.showSelectAll && C.multiple && x.value.length > 0 ? (m(), r("li", {
9219
9373
  key: 0,
9220
- class: p(["r-dropdown-options__option__append-icon", {
9221
- "r-dropdown-options__option__append-icon--active": L.value.length === P.value.length
9374
+ class: O(["r-dropdown-options__option", {
9375
+ "r-dropdown-options__option--active": L.value.length === x.value.length,
9376
+ "r-dropdown-options__option--disabled": !1
9222
9377
  }]),
9223
- name: "mdiCheck"
9224
- }, null, 8, ["class"])) : O("", !0)
9225
- ], 10, C3)) : O("", !0),
9226
- C.showSelectAll && P.value.length > 0 ? (m(), a("hr", L3)) : O("", !0),
9227
- (m(!0), a(H1, null, t1(P.value, (c) => (m(), a("li", {
9228
- key: c.value,
9229
- "aria-disabled": c.disabled,
9230
- class: p(["r-dropdown-options__option", {
9231
- "r-dropdown-options__option--active": F(c),
9232
- "r-dropdown-options__option--disabled": c.disabled,
9233
- "r-dropdown-options__option--deselect": F(c) && C.disableDeselect
9234
- }]),
9235
- onClick: d1((Q) => B(Q, c, w, x), ["prevent"])
9236
- }, [
9237
- h(Z.$slots, "option", {
9238
- disabled: c.disabled,
9239
- isSelected: F(c),
9240
- item: c
9241
- }, () => [
9242
- u("div", i3, [
9243
- h(Z.$slots, "option-prepend", {
9244
- disabled: c.disabled,
9245
- isSelected: F(c)
9378
+ onClick: a1((p) => W(
9379
+ p,
9380
+ { label: C.selectAllText, value: "select-all" },
9381
+ P,
9382
+ X
9383
+ ), ["prevent"])
9384
+ }, [
9385
+ s("div", B3, [
9386
+ s("p", b3, b(C.selectAllText), 1)
9387
+ ]),
9388
+ L.value.length === x.value.length && !C.hideOptionCheckIcon ? (m(), R(T, {
9389
+ key: 0,
9390
+ class: O(["r-dropdown-options__option__append-icon", {
9391
+ "r-dropdown-options__option__append-icon--active": L.value.length === x.value.length
9392
+ }]),
9393
+ name: "mdiCheck"
9394
+ }, null, 8, ["class"])) : f("", !0)
9395
+ ], 10, k3)) : f("", !0),
9396
+ C.showSelectAll && x.value.length > 0 ? (m(), r("hr", {
9397
+ key: 1,
9398
+ id: `${t.id}-divider`,
9399
+ class: "r-dropdown-options__divider"
9400
+ }, null, 8, v3)) : f("", !0),
9401
+ (m(!0), r(A1, null, n1(x.value, (p) => (m(), r("li", {
9402
+ id: `${t.id}-option-${p.value}`,
9403
+ key: p.value,
9404
+ "aria-disabled": p.disabled,
9405
+ class: O(["r-dropdown-options__option", {
9406
+ "r-dropdown-options__option--active": Q(p),
9407
+ "r-dropdown-options__option--disabled": p.disabled,
9408
+ "r-dropdown-options__option--deselect": Q(p) && C.disableDeselect
9409
+ }]),
9410
+ onClick: a1((G) => W(G, p, P, X), ["prevent"])
9411
+ }, [
9412
+ g(t.$slots, "option", {
9413
+ id: `${t.id}-option-${p.value}`,
9414
+ disabled: p.disabled,
9415
+ isSelected: Q(p),
9416
+ item: p
9417
+ }, () => [
9418
+ s("div", {
9419
+ id: `${t.id}-option-content-${p.value}`,
9420
+ class: "flex items-center"
9421
+ }, [
9422
+ g(t.$slots, "option-prepend", {
9423
+ id: `${t.id}-option-prepend-${p.value}`,
9424
+ disabled: p.disabled,
9425
+ isSelected: Q(p)
9426
+ }, () => [
9427
+ p.prependIcon ? (m(), R(T, {
9428
+ key: 0,
9429
+ id: `${t.id}-option-prepend-icon-${p.value}`,
9430
+ class: O(["r-dropdown-options__option__prepend-icon", {
9431
+ "r-dropdown-options__option__prepend-icon--active": Q(p)
9432
+ }]),
9433
+ name: p.prependIcon
9434
+ }, null, 8, ["id", "class", "name"])) : f("", !0)
9435
+ ]),
9436
+ s("p", {
9437
+ id: `${t.id}-option-label-${p.value}`,
9438
+ class: O(["r-dropdown-options__option__label", {
9439
+ "r-dropdown-options__option__label--active": Q(p)
9440
+ }])
9441
+ }, b(p.label), 11, P3)
9442
+ ], 8, y3),
9443
+ g(t.$slots, "option-append", {
9444
+ id: `${t.id}-option-append-${p.value}`,
9445
+ disabled: p.disabled,
9446
+ isSelected: Q(p)
9246
9447
  }, () => [
9247
- c.prependIcon ? (m(), _(D, {
9448
+ Q(p) && !C.hideOptionCheckIcon ? (m(), R(T, {
9248
9449
  key: 0,
9249
- class: p(["r-dropdown-options__option__prepend-icon", {
9250
- "r-dropdown-options__option__prepend-icon--active": F(c)
9450
+ class: O(["r-dropdown-options__option__append-icon", {
9451
+ "r-dropdown-options__option__append-icon--active": Q(p)
9251
9452
  }]),
9252
- name: c.prependIcon
9253
- }, null, 8, ["class", "name"])) : O("", !0)
9254
- ]),
9255
- u("p", {
9256
- class: p(["r-dropdown-options__option__label", {
9257
- "r-dropdown-options__option__label--active": F(c)
9258
- }])
9259
- }, b(c.label), 3)
9260
- ]),
9261
- h(Z.$slots, "option-append", {
9262
- disabled: c.disabled,
9263
- isSelected: F(c)
9264
- }, () => [
9265
- F(c) && !C.hideOptionCheckIcon ? (m(), _(D, {
9266
- key: 0,
9267
- class: p(["r-dropdown-options__option__append-icon", {
9268
- "r-dropdown-options__option__append-icon--active": F(c)
9269
- }]),
9270
- name: "mdiCheck"
9271
- }, null, 8, ["class"])) : O("", !0)
9453
+ name: "mdiCheck"
9454
+ }, null, 8, ["class"])) : f("", !0)
9455
+ ])
9272
9456
  ])
9457
+ ], 10, w3))), 128)),
9458
+ g(t.$slots, "pagination")
9459
+ ])) : x.value.length === 0 ? (m(), r("div", {
9460
+ key: 2,
9461
+ id: `${t.id}-no-option`,
9462
+ class: "r-dropdown-options__no-option"
9463
+ }, [
9464
+ g(t.$slots, "not-options", {}, () => [
9465
+ u1(b(C.noOptionsText), 1)
9273
9466
  ])
9274
- ], 10, M3))), 128)),
9275
- P.value.length === 0 ? (m(), a("li", A3, [
9276
- h(Z.$slots, "not-options", {}, () => [
9277
- s1(b(C.noOptionsText), 1)
9278
- ])
9279
- ])) : O("", !0)
9280
- ], 2)
9467
+ ], 8, T3)) : f("", !0)
9468
+ ], 10, f3)
9281
9469
  ]),
9282
9470
  _: 3
9283
- }, 8, ["disabled", "tooltip-class"]),
9284
- Z.$props.hideDetails ? O("", !0) : (m(), a("div", e3, [
9285
- C.errorMsg ? (m(), a("div", t3, b(C.errorMsg), 1)) : O("", !0),
9286
- C.hint ? (m(), a("div", d3, b(C.hint), 1)) : O("", !0)
9287
- ]))
9288
- ], 512));
9471
+ }, 8, ["id", "disabled", "tooltip-class"]),
9472
+ t.$props.hideDetails ? f("", !0) : (m(), r("div", {
9473
+ key: 0,
9474
+ id: `${t.id}-details`,
9475
+ class: "r-dropdown-details"
9476
+ }, [
9477
+ C.errorMsg ? (m(), r("div", {
9478
+ key: 0,
9479
+ id: `${t.id}-error`,
9480
+ class: "r-dropdown-error"
9481
+ }, b(C.errorMsg), 9, R3)) : f("", !0),
9482
+ C.hint ? (m(), r("div", {
9483
+ key: 1,
9484
+ id: `${t.id}-hint`,
9485
+ class: "r-dropdown-hint"
9486
+ }, b(C.hint), 9, x3)) : f("", !0)
9487
+ ], 8, F3))
9488
+ ], 8, o3));
9289
9489
  }
9290
- }), l3 = ["id", "for"], f2 = /* @__PURE__ */ R({
9490
+ }), E3 = ["id", "for"], y2 = /* @__PURE__ */ F({
9291
9491
  __name: "RLabel",
9292
9492
  props: {
9293
9493
  id: { default: "" },
@@ -9295,27 +9495,20 @@ const G5 = ["aria-disabled"], $5 = ["innerHTML"], U5 = ["id"], z5 = /* @__PURE__
9295
9495
  text: { default: "" }
9296
9496
  },
9297
9497
  setup(H) {
9298
- const V = H;
9299
- return (C, M) => (m(), a("label", {
9300
- id: V.id,
9498
+ const V = H, C = h(() => V.id || "r-label");
9499
+ return (i, A) => (m(), r("label", {
9500
+ id: C.value,
9301
9501
  class: "r-label",
9302
9502
  for: V.for
9303
9503
  }, [
9304
- h(C.$slots, "default", {}, () => [
9305
- s1(b(V.text), 1)
9504
+ g(i.$slots, "default", {
9505
+ id: `${C.value}-slot`
9506
+ }, () => [
9507
+ u1(b(V.text), 1)
9306
9508
  ])
9307
- ], 8, l3));
9509
+ ], 8, E3));
9308
9510
  }
9309
- }), o3 = ["onClick"], n3 = ["open"], r3 = { class: "r-dialog__header" }, a3 = {
9310
- key: 0,
9311
- class: "icon"
9312
- }, Z3 = {
9313
- key: 1,
9314
- class: "title"
9315
- }, u3 = {
9316
- key: 2,
9317
- class: "description"
9318
- }, S3 = { class: "r-dialog__body" }, s3 = { class: "r-dialog__actions" }, v0 = /* @__PURE__ */ R({
9511
+ }), _3 = ["id", "onClick"], $3 = ["id", "open"], W3 = ["id"], N3 = ["id"], I3 = ["id"], Q3 = ["id"], G3 = ["id"], U3 = ["id"], A7 = /* @__PURE__ */ F({
9319
9512
  __name: "RModal",
9320
9513
  props: {
9321
9514
  modelValue: { type: Boolean, default: !1 },
@@ -9330,99 +9523,136 @@ const G5 = ["aria-disabled"], $5 = ["innerHTML"], U5 = ["id"], z5 = /* @__PURE__
9330
9523
  class: { default: "" },
9331
9524
  overlayClass: { default: "" },
9332
9525
  style: { default: "" },
9333
- allowBodyScroll: { type: Boolean, default: !1 }
9526
+ allowBodyScroll: { type: Boolean, default: !1 },
9527
+ id: { default: "r-modal" }
9334
9528
  },
9335
9529
  emits: ["update:modelValue"],
9336
9530
  setup(H, { emit: V }) {
9337
- const C = H, M = V, i = g(() => ({
9531
+ const C = H, i = V, A = h(() => ({
9338
9532
  "r-dialog": !0,
9339
9533
  "r-dialog--block": C.block,
9340
9534
  "p-0 gap-0": C.clearContent,
9341
9535
  [`${C.class}`]: !0
9342
- })), L = g(() => ({
9536
+ })), L = h(() => ({
9343
9537
  width: C.width,
9344
9538
  height: C.height
9345
9539
  }));
9346
- function A(e) {
9347
- C.outsideClick && e.target === e.currentTarget && M("update:modelValue", !1);
9540
+ function M(e) {
9541
+ C.outsideClick && e.target === e.currentTarget && i("update:modelValue", !1);
9348
9542
  }
9349
- return e2(() => {
9543
+ return Y1(() => {
9350
9544
  !C.modelValue && C.allowBodyScroll && (document.body.style.overflow = "auto");
9351
9545
  }), window.addEventListener("keydown", (e) => {
9352
- e.key === "Escape" && C.modelValue && C.outsideClick && M("update:modelValue", !1);
9353
- }), (e, t) => t2((m(), a("div", {
9354
- class: p(["r-modal-overlay", e.overlayClass]),
9355
- onClick: d1(A, ["stop"])
9546
+ e.key === "Escape" && C.modelValue && C.outsideClick && i("update:modelValue", !1);
9547
+ }), (e, d) => Z2((m(), r("div", {
9548
+ id: e.id,
9549
+ class: O(["r-modal-overlay", e.overlayClass]),
9550
+ onClick: a1(M, ["stop"])
9356
9551
  }, [
9357
- u("div", {
9552
+ s("div", {
9553
+ id: `${e.id}-dialog`,
9358
9554
  "aria-modal": "true",
9359
- class: p(i.value),
9555
+ class: O(A.value),
9360
9556
  open: C.modelValue,
9361
9557
  role: "dialog",
9362
- style: $1(L.value)
9558
+ style: J1(L.value)
9363
9559
  }, [
9364
- h(e.$slots, "wrapper", {}, () => [
9365
- u("div", r3, [
9366
- h(e.$slots, "header"),
9367
- C.icon ? (m(), a("div", a3, [
9368
- q(D, {
9560
+ g(e.$slots, "wrapper", {
9561
+ id: `${e.id}-wrapper`
9562
+ }, () => [
9563
+ s("div", {
9564
+ id: `${e.id}-header`,
9565
+ class: "r-dialog__header"
9566
+ }, [
9567
+ g(e.$slots, "header", {
9568
+ id: `${e.id}-header`
9569
+ }),
9570
+ C.icon ? (m(), r("div", {
9571
+ key: 0,
9572
+ id: `${e.id}-icon`,
9573
+ class: "icon"
9574
+ }, [
9575
+ H1(T, {
9369
9576
  name: C.icon
9370
9577
  }, null, 8, ["name"])
9371
- ])) : O("", !0),
9372
- C.title ? (m(), a("div", Z3, b(C.title), 1)) : O("", !0),
9373
- C.description ? (m(), a("div", u3, b(C.description), 1)) : O("", !0)
9374
- ]),
9375
- u("div", S3, [
9376
- h(e.$slots, "default")
9377
- ]),
9378
- u("div", s3, [
9379
- h(e.$slots, "actions")
9380
- ])
9578
+ ], 8, N3)) : f("", !0),
9579
+ C.title ? (m(), r("div", {
9580
+ key: 1,
9581
+ id: `${e.id}-title`,
9582
+ class: "title"
9583
+ }, b(C.title), 9, I3)) : f("", !0),
9584
+ C.description ? (m(), r("div", {
9585
+ key: 2,
9586
+ id: `${e.id}-description`,
9587
+ class: "description"
9588
+ }, b(C.description), 9, Q3)) : f("", !0)
9589
+ ], 8, W3),
9590
+ s("div", {
9591
+ id: `${e.id}-body`,
9592
+ class: "r-dialog__body"
9593
+ }, [
9594
+ g(e.$slots, "default", {
9595
+ id: `${e.id}-body`
9596
+ })
9597
+ ], 8, G3),
9598
+ s("div", {
9599
+ id: `${e.id}-actions`,
9600
+ class: "r-dialog__actions"
9601
+ }, [
9602
+ g(e.$slots, "actions", {
9603
+ id: `${e.id}-actions`
9604
+ })
9605
+ ], 8, U3)
9381
9606
  ])
9382
- ], 14, n3)
9383
- ], 10, o3)), [
9384
- [b2, e.modelValue]
9607
+ ], 14, $3)
9608
+ ], 10, _3)), [
9609
+ [R2, e.modelValue]
9385
9610
  ]);
9386
9611
  }
9387
- }), c3 = ["data-open"], p3 = ["data-open"], O3 = ["data-open"], y0 = /* @__PURE__ */ R({
9612
+ }), z3 = ["id", "data-open"], K3 = ["id", "data-open"], q3 = ["id", "data-open"], e7 = /* @__PURE__ */ F({
9388
9613
  __name: "RSidebar",
9389
9614
  props: {
9390
9615
  modelValue: { type: Boolean, default: !1 },
9391
9616
  showTrigger: { type: Boolean, default: !0 },
9392
9617
  class: {},
9393
9618
  triggerClass: {},
9394
- wrapperClass: {}
9619
+ wrapperClass: {},
9620
+ id: { default: "r-sidebar" }
9395
9621
  },
9396
9622
  emits: ["update:modelValue"],
9397
9623
  setup(H, { emit: V }) {
9398
- const C = H, M = V;
9399
- return (i, L) => (m(), a("div", {
9400
- class: p(["r-sidebar__wrapper", [i.$props.wrapperClass]]),
9624
+ const C = H, i = V;
9625
+ return (A, L) => (m(), r("div", {
9626
+ id: A.id,
9627
+ class: O(["r-sidebar__wrapper", [A.$props.wrapperClass]]),
9401
9628
  "data-open": C.modelValue
9402
9629
  }, [
9403
- u("aside", {
9404
- class: p(["r-sidebar", [C.class]]),
9630
+ s("aside", {
9631
+ id: `${A.id}-aside`,
9632
+ class: O(["r-sidebar", [C.class]]),
9405
9633
  "data-open": C.modelValue
9406
9634
  }, [
9407
- h(i.$slots, "default", {
9635
+ g(A.$slots, "default", {
9408
9636
  open: C.modelValue
9409
9637
  })
9410
- ], 10, p3),
9411
- C.showTrigger ? (m(), a("div", {
9638
+ ], 10, K3),
9639
+ C.showTrigger ? (m(), r("div", {
9412
9640
  key: 0,
9413
- class: p(["r-sidebar__trigger", [C.triggerClass]]),
9641
+ id: `${A.id}-trigger`,
9642
+ class: O(["r-sidebar__trigger", [C.triggerClass]]),
9414
9643
  "data-open": C.modelValue,
9415
- onClick: L[0] || (L[0] = (A) => M("update:modelValue", !C.modelValue))
9644
+ onClick: L[0] || (L[0] = (M) => i("update:modelValue", !C.modelValue))
9416
9645
  }, [
9417
- h(i.$slots, "trigger", {
9646
+ g(A.$slots, "trigger", {
9647
+ id: `${A.id}-trigger-slot`,
9418
9648
  open: C.modelValue
9419
9649
  }, () => [
9420
- s1(" > ")
9650
+ u1(" > ")
9421
9651
  ])
9422
- ], 10, O3)) : O("", !0)
9423
- ], 10, c3));
9652
+ ], 10, q3)) : f("", !0)
9653
+ ], 10, z3));
9424
9654
  }
9425
- }), f3 = { class: "r-snackbar__text" }, P0 = /* @__PURE__ */ R({
9655
+ }), j3 = ["id"], X3 = ["id"], d7 = /* @__PURE__ */ F({
9426
9656
  __name: "RSnackbar",
9427
9657
  props: {
9428
9658
  modelValue: { type: Boolean, default: !1 },
@@ -9431,74 +9661,77 @@ const G5 = ["aria-disabled"], $5 = ["innerHTML"], U5 = ["id"], z5 = /* @__PURE__
9431
9661
  left: { type: Boolean, default: !1 },
9432
9662
  timeout: { default: 0 },
9433
9663
  variant: {},
9434
- top: { type: Boolean }
9664
+ top: { type: Boolean },
9665
+ id: { default: "r-snackbar" }
9435
9666
  },
9436
9667
  emits: ["action", "update:modelValue"],
9437
9668
  setup(H, { emit: V }) {
9438
- const C = H, M = V;
9439
- G(
9669
+ const C = H, i = V;
9670
+ $(
9440
9671
  () => C.modelValue,
9441
9672
  () => {
9442
9673
  C.timeout > 0 && C.modelValue && setTimeout(() => {
9443
- M("update:modelValue", !1);
9674
+ i("update:modelValue", !1);
9444
9675
  }, C.timeout);
9445
9676
  },
9446
9677
  {
9447
9678
  immediate: !0
9448
9679
  }
9449
9680
  );
9450
- const i = g(() => ({
9681
+ const A = h(() => ({
9451
9682
  "r-snackbar": !0,
9452
9683
  [`r-snackbar--${C.variant}`]: !0,
9453
9684
  [C.left ? "r-snackbar__left" : "r-snackbar__right"]: !0,
9454
9685
  [C.modelValue ? "r-snackbar--shown" : "r-snackbar--hidden"]: !0,
9455
9686
  [C.top ? "r-snackbar__top" : "r-snackbar__bottom"]: !0,
9456
9687
  "r-snackbar--closable": C.closable
9457
- })), L = g(() => ({
9688
+ })), L = h(() => ({
9458
9689
  success: "mdiCheckCircle",
9459
9690
  error: "mdiAlertCircle",
9460
9691
  warning: "mdiAlert",
9461
9692
  info: "mdiInformation"
9462
9693
  })[C.variant || "info"]);
9463
- return (A, e) => (m(), a("div", {
9464
- class: p(i.value)
9694
+ return (M, e) => (m(), r("div", {
9695
+ id: M.id,
9696
+ class: O(A.value)
9465
9697
  }, [
9466
- h(A.$slots, "icon", {}, () => [
9467
- C.variant ? (m(), _(D, {
9698
+ g(M.$slots, "icon", {
9699
+ id: `${M.id}-icon`
9700
+ }, () => [
9701
+ C.variant ? (m(), R(T, {
9468
9702
  key: 0,
9469
9703
  class: "r-snackbar__icon",
9470
9704
  name: L.value
9471
- }, null, 8, ["name"])) : O("", !0)
9705
+ }, null, 8, ["name"])) : f("", !0)
9472
9706
  ]),
9473
- u("div", f3, [
9474
- h(A.$slots, "default", {}, () => [
9475
- s1(b(C.text), 1)
9707
+ s("div", {
9708
+ id: `${M.id}-text`,
9709
+ class: "r-snackbar__text"
9710
+ }, [
9711
+ g(M.$slots, "default", {
9712
+ id: `${M.id}-text-slot`
9713
+ }, () => [
9714
+ u1(b(C.text), 1)
9476
9715
  ])
9477
- ]),
9478
- C.closable ? (m(), a("div", {
9716
+ ], 8, X3),
9717
+ C.closable ? (m(), r("div", {
9479
9718
  key: 0,
9480
9719
  class: "r-snackbar__close",
9481
- onClick: e[0] || (e[0] = d1((t) => A.$emit("update:modelValue", !1), ["stop"]))
9720
+ onClick: e[0] || (e[0] = a1((d) => M.$emit("update:modelValue", !1), ["stop"]))
9482
9721
  }, [
9483
- h(A.$slots, "close", {}, () => [
9484
- q(D, {
9722
+ g(M.$slots, "close", {
9723
+ id: `${M.id}-close-slot`
9724
+ }, () => [
9725
+ H1(T, {
9726
+ id: `${M.id}-close-icon`,
9485
9727
  name: "mdiClose",
9486
9728
  size: 16
9487
- })
9729
+ }, null, 8, ["id"])
9488
9730
  ])
9489
- ])) : O("", !0)
9490
- ], 2));
9731
+ ])) : f("", !0)
9732
+ ], 10, j3));
9491
9733
  }
9492
- }), h3 = ["id", "checked", "disabled", "name"], g3 = /* @__PURE__ */ u("span", { class: "slider round" }, null, -1), k3 = ["id", "for"], B3 = {
9493
- key: 0,
9494
- class: "r-switch-texts__details"
9495
- }, b3 = {
9496
- key: 0,
9497
- class: "r-switch-texts__error"
9498
- }, w3 = {
9499
- key: 1,
9500
- class: "r-switch-texts__hint"
9501
- }, T0 = /* @__PURE__ */ R({
9734
+ }), Y3 = ["id", "checked", "disabled", "name"], J3 = /* @__PURE__ */ s("span", { class: "slider round" }, null, -1), C0 = ["id", "for"], H0 = ["id"], V0 = ["id"], L0 = ["id"], t7 = /* @__PURE__ */ F({
9502
9735
  __name: "RSwitch",
9503
9736
  props: {
9504
9737
  id: { default: "switch" },
@@ -9514,70 +9747,82 @@ const G5 = ["aria-disabled"], $5 = ["innerHTML"], U5 = ["id"], z5 = /* @__PURE__
9514
9747
  },
9515
9748
  emits: ["update:modelValue"],
9516
9749
  setup(H, { emit: V }) {
9517
- const C = H, M = V, i = E({
9750
+ const C = H, i = V, A = E({
9518
9751
  checked: !1
9519
- }), L = g(() => ({
9752
+ }), L = h(() => ({
9520
9753
  "r-switch": !0,
9521
9754
  "r-switch--disabled": C.disabled,
9522
9755
  [`r-switch--${C.size}`]: C.size,
9523
9756
  "r-switch--error": C.errorMsg
9524
- }));
9525
- function A(e) {
9526
- C.disabled || (i.value.checked = e.target.checked, M("update:modelValue", i.value.checked));
9757
+ })), M = h(() => C.id || "r-switch");
9758
+ function e(d) {
9759
+ C.disabled || (A.value.checked = d.target.checked, i("update:modelValue", A.value.checked));
9527
9760
  }
9528
- return G(
9761
+ return $(
9529
9762
  () => C.modelValue,
9530
- (e) => {
9531
- i.value.checked = e;
9763
+ (d) => {
9764
+ A.value.checked = d;
9532
9765
  },
9533
9766
  {
9534
9767
  // need immediate to set the state on first render for storybook
9535
9768
  // TODO: find a better way to do this
9536
9769
  immediate: !0
9537
9770
  }
9538
- ), (e, t) => (m(), a("div", {
9539
- class: p(["r-switch-container", {
9771
+ ), (d, l) => (m(), r("div", {
9772
+ class: O(["r-switch-container", {
9540
9773
  "r-switch-container--reverse": C.reverse,
9541
9774
  "r-switch-container--hide-details": C.hideDetails
9542
9775
  }])
9543
9776
  }, [
9544
- u("div", {
9545
- class: p(L.value)
9777
+ s("div", {
9778
+ class: O(L.value)
9546
9779
  }, [
9547
- u("input", {
9548
- id: C.id,
9549
- checked: i.value.checked,
9780
+ s("input", {
9781
+ id: M.value,
9782
+ checked: A.value.checked,
9550
9783
  class: "r-switch__input",
9551
9784
  disabled: C.disabled,
9552
9785
  name: C.name,
9553
9786
  type: "checkbox",
9554
- onChange: A
9555
- }, null, 40, h3),
9556
- g3
9787
+ onChange: e
9788
+ }, null, 40, Y3),
9789
+ J3
9557
9790
  ], 2),
9558
- u("div", {
9559
- class: p(["r-switch-texts", {
9791
+ s("div", {
9792
+ class: O(["r-switch-texts", {
9560
9793
  [`r-switch-texts--${C.size}`]: !0
9561
9794
  }])
9562
9795
  }, [
9563
- u("label", {
9564
- id: `${C.id}-label`,
9796
+ s("label", {
9797
+ id: `${M.value}-label`,
9565
9798
  class: "r-switch-texts__label",
9566
- for: C.id
9567
- }, b(C.label), 9, k3),
9568
- C.hideDetails ? O("", !0) : (m(), a("div", B3, [
9569
- C.errorMsg ? (m(), a("p", b3, b(C.errorMsg), 1)) : (m(), a("p", w3, b(C.hint), 1))
9570
- ]))
9799
+ for: M.value
9800
+ }, b(C.label), 9, C0),
9801
+ C.hideDetails ? f("", !0) : (m(), r("div", {
9802
+ key: 0,
9803
+ id: `${M.value}-details`,
9804
+ class: "r-switch-texts__details"
9805
+ }, [
9806
+ C.errorMsg ? (m(), r("p", {
9807
+ key: 0,
9808
+ id: `${M.value}-error`,
9809
+ class: "r-switch-texts__error"
9810
+ }, b(C.errorMsg), 9, V0)) : (m(), r("p", {
9811
+ key: 1,
9812
+ id: `${M.value}-hint`,
9813
+ class: "r-switch-texts__hint"
9814
+ }, b(C.hint), 9, L0))
9815
+ ], 8, H0))
9571
9816
  ], 2)
9572
9817
  ], 2));
9573
9818
  }
9574
9819
  });
9575
- var Z1 = /* @__PURE__ */ ((H) => (H.DEFAULT = "default", H.TEXT = "text", H.ICON = "icon", H))(Z1 || {});
9576
- const v3 = ["aria-disabled", "aria-selected", "disabled"], y3 = { key: 0 }, P3 = /* @__PURE__ */ R({
9820
+ var O1 = /* @__PURE__ */ ((H) => (H.DEFAULT = "default", H.TEXT = "text", H.ICON = "icon", H))(O1 || {});
9821
+ const M0 = ["id", "aria-disabled", "aria-selected", "disabled"], i0 = { key: 0 }, A0 = /* @__PURE__ */ F({
9577
9822
  __name: "RTabItem",
9578
9823
  props: {
9579
9824
  id: {},
9580
- variant: { default: Z1.DEFAULT },
9825
+ variant: { default: O1.DEFAULT },
9581
9826
  label: { default: "" },
9582
9827
  prependIcon: { default: "" },
9583
9828
  appendIcon: { default: "" },
@@ -9589,123 +9834,120 @@ const v3 = ["aria-disabled", "aria-selected", "disabled"], y3 = { key: 0 }, P3 =
9589
9834
  },
9590
9835
  emits: ["update:modelValue"],
9591
9836
  setup(H, { emit: V }) {
9592
- const C = H, M = V, i = g(() => ({
9837
+ const C = H, i = V, A = h(() => ({
9593
9838
  "r-tab-item": !0,
9594
9839
  [`r-tab-item--${C.variant}`]: !0,
9595
9840
  "r-tab-item--tile": C.tile,
9596
9841
  "r-tab-item--block": C.block
9597
- })), L = g(() => ({
9842
+ })), L = h(() => ({
9598
9843
  color: C.color
9599
- })), A = g(() => C.modelValue === C.id);
9600
- function e(t) {
9601
- M("update:modelValue", t);
9844
+ })), M = h(() => C.modelValue === C.id);
9845
+ function e(d) {
9846
+ i("update:modelValue", d);
9602
9847
  }
9603
- return (t, d) => (m(), a("button", {
9848
+ return (d, l) => (m(), r("button", {
9849
+ id: `r-tab-item-${C.id}`,
9604
9850
  "aria-disabled": C.disabled,
9605
- "aria-selected": A.value,
9606
- class: p(i.value),
9851
+ "aria-selected": M.value,
9852
+ class: O(A.value),
9607
9853
  disabled: C.disabled,
9608
- style: $1(L.value),
9609
- onClick: d[0] || (d[0] = d1((l) => e(C.id), ["stop"]))
9854
+ style: J1(L.value),
9855
+ onClick: l[0] || (l[0] = a1((n) => e(C.id), ["stop"]))
9610
9856
  }, [
9611
- h(t.$slots, "prepend", {
9612
- active: A.value,
9857
+ g(d.$slots, "prepend", {
9858
+ active: M.value,
9613
9859
  disabled: C.disabled
9614
9860
  }, () => [
9615
- C.variant !== J(Z1).TEXT && C.prependIcon ? (m(), _(D, {
9861
+ C.variant !== e1(O1).TEXT && C.prependIcon ? (m(), R(T, {
9616
9862
  key: 0,
9617
9863
  class: "r-tab-item__prepend-icon",
9618
9864
  name: C.prependIcon,
9619
9865
  size: 16
9620
- }, null, 8, ["name"])) : O("", !0)
9866
+ }, null, 8, ["name"])) : f("", !0)
9621
9867
  ]),
9622
- C.variant !== J(Z1).ICON ? (m(), a("span", y3, [
9623
- h(t.$slots, "default", {
9868
+ C.variant !== e1(O1).ICON ? (m(), r("span", i0, [
9869
+ g(d.$slots, "default", {
9624
9870
  label: C.label
9625
9871
  }, () => [
9626
- s1(b(C.label), 1)
9872
+ u1(b(C.label), 1)
9627
9873
  ])
9628
- ])) : O("", !0),
9629
- h(t.$slots, "append", {
9630
- active: A.value,
9874
+ ])) : f("", !0),
9875
+ g(d.$slots, "append", {
9876
+ active: M.value,
9631
9877
  disabled: C.disabled
9632
9878
  }, () => [
9633
- C.variant !== J(Z1).TEXT && C.appendIcon ? (m(), _(D, {
9879
+ C.variant !== e1(O1).TEXT && C.appendIcon ? (m(), R(T, {
9634
9880
  key: 0,
9635
9881
  class: "r-tab-item__append-icon",
9636
9882
  name: C.appendIcon,
9637
9883
  size: 16
9638
- }, null, 8, ["name"])) : O("", !0)
9884
+ }, null, 8, ["name"])) : f("", !0)
9639
9885
  ])
9640
- ], 14, v3));
9886
+ ], 14, M0));
9641
9887
  }
9642
- }), F0 = /* @__PURE__ */ R({
9888
+ }), e0 = ["id"], d0 = ["id"], m7 = /* @__PURE__ */ F({
9643
9889
  __name: "RTabs",
9644
9890
  props: {
9645
9891
  tabs: { default: () => [] },
9646
9892
  block: { type: Boolean, default: !1 },
9647
9893
  modelValue: { default: "" },
9648
9894
  tile: { type: Boolean, default: !1 },
9649
- scrollable: { type: Boolean, default: !1 }
9895
+ scrollable: { type: Boolean, default: !1 },
9896
+ id: { default: "r-tabs" }
9650
9897
  },
9651
9898
  emits: ["update:modelValue"],
9652
9899
  setup(H, { emit: V }) {
9653
- const C = H, M = V, i = E(C.modelValue || C.tabs[0].id), L = g(() => ({
9900
+ const C = H, i = V, A = E(C.modelValue || (C.tabs.length > 0 ? C.tabs[0].id : "")), L = h(() => ({
9654
9901
  "r-tabs": !0,
9655
9902
  "r-tabs--tile": C.tile
9656
9903
  }));
9657
- return G(
9658
- () => i.value,
9904
+ return $(
9905
+ () => A.value,
9659
9906
  () => {
9660
- M("update:modelValue", i.value);
9907
+ i("update:modelValue", A.value);
9661
9908
  }
9662
- ), G(
9909
+ ), $(
9663
9910
  () => C.modelValue,
9664
9911
  () => {
9665
- i.value = C.modelValue;
9912
+ A.value = C.modelValue;
9666
9913
  },
9667
9914
  {
9668
9915
  immediate: !0
9669
9916
  }
9670
- ), (A, e) => (m(), a("div", {
9671
- class: p(L.value)
9917
+ ), (M, e) => (m(), r("div", {
9918
+ id: M.id,
9919
+ class: O(L.value)
9672
9920
  }, [
9673
- u("div", {
9674
- class: p(["flex", [{
9921
+ s("div", {
9922
+ id: `${M.id}-tabs`,
9923
+ class: O(["flex", [{
9675
9924
  "w-full": C.block,
9676
9925
  "overflow-x-auto": C.scrollable,
9677
9926
  "gap-0.5": C.tile
9678
9927
  }]])
9679
9928
  }, [
9680
- h(A.$slots, "default", { activeTab: i.value }, () => [
9681
- (m(!0), a(H1, null, t1(C.tabs, (t, d) => (m(), _(P3, {
9682
- id: t.id,
9683
- key: d,
9684
- modelValue: i.value,
9685
- "onUpdate:modelValue": e[0] || (e[0] = (l) => i.value = l),
9686
- active: d === i.value,
9687
- "append-icon": t.appendIcon,
9688
- block: A.block,
9689
- disabled: t.disabled,
9690
- label: t.label,
9691
- "prepend-icon": t.prependIcon,
9692
- tile: A.tile,
9693
- variant: t.variant
9694
- }, null, 8, ["id", "modelValue", "active", "append-icon", "block", "disabled", "label", "prepend-icon", "tile", "variant"]))), 128))
9929
+ g(M.$slots, "default", {
9930
+ id: `${M.id}-slot`,
9931
+ activeTab: A.value
9932
+ }, () => [
9933
+ (m(!0), r(A1, null, n1(C.tabs, (d, l) => (m(), R(A0, {
9934
+ id: d.id,
9935
+ key: l,
9936
+ modelValue: A.value,
9937
+ "onUpdate:modelValue": e[0] || (e[0] = (n) => A.value = n),
9938
+ "append-icon": d.appendIcon,
9939
+ block: M.block,
9940
+ disabled: d.disabled,
9941
+ label: d.label,
9942
+ "prepend-icon": d.prependIcon,
9943
+ tile: M.tile,
9944
+ variant: d.variant
9945
+ }, null, 8, ["id", "modelValue", "append-icon", "block", "disabled", "label", "prepend-icon", "tile", "variant"]))), 128))
9695
9946
  ])
9696
- ], 2)
9697
- ], 2));
9947
+ ], 10, d0)
9948
+ ], 10, e0));
9698
9949
  }
9699
- }), T3 = { class: "r-textarea-wrapper" }, F3 = ["id", "disabled", "placeholder", "value"], R3 = {
9700
- key: 1,
9701
- class: "r-textarea__details"
9702
- }, x3 = {
9703
- key: 0,
9704
- class: "r-textarea__error"
9705
- }, D3 = {
9706
- key: 1,
9707
- class: "r-textarea__hint"
9708
- }, R0 = /* @__PURE__ */ R({
9950
+ }), t0 = { class: "r-textarea-wrapper" }, m0 = ["id", "disabled", "placeholder", "value"], l0 = ["id"], o0 = ["id"], n0 = ["id"], l7 = /* @__PURE__ */ F({
9709
9951
  __name: "RTextArea",
9710
9952
  props: {
9711
9953
  id: { default: "" },
@@ -9719,54 +9961,62 @@ const v3 = ["aria-disabled", "aria-selected", "disabled"], y3 = { key: 0 }, P3 =
9719
9961
  },
9720
9962
  emits: ["update:modelValue"],
9721
9963
  setup(H, { emit: V }) {
9722
- const C = H, M = V, i = T1({
9964
+ const C = H, i = V, A = _1({
9723
9965
  value: ""
9724
9966
  });
9725
- function L(A) {
9726
- M("update:modelValue", A.target.value);
9967
+ function L(e) {
9968
+ i("update:modelValue", e.target.value);
9727
9969
  }
9728
- return G(
9970
+ $(
9729
9971
  () => C.modelValue,
9730
- (A) => {
9731
- i.value = A;
9972
+ (e) => {
9973
+ A.value = e;
9732
9974
  },
9733
9975
  {
9734
9976
  immediate: !0
9735
9977
  }
9736
- ), (A, e) => (m(), a("div", T3, [
9737
- C.label ? (m(), _(f2, {
9978
+ );
9979
+ const M = h(() => C.id || "r-textarea");
9980
+ return (e, d) => (m(), r("div", t0, [
9981
+ C.label ? (m(), R(y2, {
9738
9982
  key: 0,
9739
- id: `${C.id}-label`,
9983
+ id: `${M.value}-label`,
9740
9984
  class: "r-textarea__label",
9741
- for: "textarea",
9985
+ for: M.value,
9742
9986
  text: C.label
9743
- }, null, 8, ["id", "text"])) : O("", !0),
9744
- u("textarea", F1(A.$attrs, {
9745
- id: C.id,
9987
+ }, null, 8, ["id", "for", "text"])) : f("", !0),
9988
+ s("textarea", $1(e.$props, {
9989
+ id: `${M.value}`,
9746
9990
  class: ["r-textarea", {
9747
9991
  "r-textarea--error": C.errorMsg,
9748
9992
  "r-textarea--disabled": C.disabled
9749
9993
  }],
9750
9994
  disabled: C.disabled,
9751
9995
  placeholder: C.placeholder,
9752
- value: i.value,
9996
+ value: A.value,
9753
9997
  onInput: L
9754
- }), null, 16, F3),
9755
- C.hideDetails ? O("", !0) : (m(), a("div", R3, [
9756
- C.errorMsg ? (m(), a("p", x3, b(C.errorMsg), 1)) : (m(), a("p", D3, b(C.hint), 1))
9757
- ]))
9998
+ }), null, 16, m0),
9999
+ C.hideDetails ? f("", !0) : (m(), r("div", {
10000
+ key: 1,
10001
+ id: `${M.value}-details`,
10002
+ class: "r-textarea__details"
10003
+ }, [
10004
+ C.errorMsg ? (m(), r("p", {
10005
+ key: 0,
10006
+ id: `${M.value}-error`,
10007
+ class: "r-textarea__error"
10008
+ }, b(C.errorMsg), 9, o0)) : (m(), r("p", {
10009
+ key: 1,
10010
+ id: `${M.value}-hint`,
10011
+ class: "r-textarea__hint"
10012
+ }, b(C.hint), 9, n0))
10013
+ ], 8, l0))
9758
10014
  ]));
9759
10015
  }
9760
- }), _3 = { class: "r-textfield__wrapper" }, E3 = { class: "input-wrapper" }, W3 = ["id", "disabled", "max", "min", "placeholder", "readonly", "role", "type", "value"], N3 = {
9761
- key: 0,
9762
- class: "r-textfield__details"
9763
- }, I3 = {
9764
- key: 0,
9765
- class: "r-textfield__error"
9766
- }, Q3 = {
10016
+ }), a0 = { class: "r-textfield__wrapper" }, r0 = ["id"], Z0 = ["id"], u0 = ["id", "disabled", "max", "min", "placeholder", "readonly", "role", "type", "value"], S0 = ["id"], s0 = ["id"], c0 = {
9767
10017
  key: 1,
9768
10018
  class: "r-textfield__hint"
9769
- }, x0 = /* @__PURE__ */ R({
10019
+ }, o7 = /* @__PURE__ */ F({
9770
10020
  __name: "RTextfield",
9771
10021
  props: {
9772
10022
  id: { default: "" },
@@ -9796,231 +10046,257 @@ const v3 = ["aria-disabled", "aria-selected", "disabled"], y3 = { key: 0 }, P3 =
9796
10046
  "click:clear"
9797
10047
  ],
9798
10048
  setup(H, { emit: V }) {
9799
- const C = H, M = V, i = E(), L = T1({
10049
+ const C = H, i = V, A = E(), L = _1({
9800
10050
  value: ""
9801
- }), A = E(C.type), e = {
10051
+ }), M = E(C.type), e = {
9802
10052
  password: "mdiLock",
9803
10053
  email: "mdiEmailOutline",
9804
10054
  tel: "mdiPhone",
9805
10055
  url: "mdiLink",
9806
10056
  number: "mdiNumeric",
9807
10057
  text: ""
9808
- }, t = E(!1), d = g(() => !!L.value), l = g(() => L.value.length > 0), r = g(() => {
9809
- var f;
9810
- return (f = C.errorMsg) == null ? void 0 : f.length;
9811
- }), o = g(() => C.clearable && l.value), n = g(() => {
9812
- const { disabled: f, loading: N } = C;
10058
+ }, d = E(!1), l = h(() => !!L.value), n = h(() => L.value.length > 0), Z = h(() => {
10059
+ var k;
10060
+ return (k = C.errorMsg) == null ? void 0 : k.length;
10061
+ }), o = h(() => C.clearable && n.value), a = h(() => {
10062
+ const { disabled: k, loading: N } = C;
9813
10063
  return {
9814
10064
  "r-textfield": !0,
9815
- "r-textfield--error": r.value,
10065
+ "r-textfield--error": Z.value,
9816
10066
  "r-textfield--loading": N,
9817
- "r-textfield--disabled": f,
10067
+ "r-textfield--disabled": k,
9818
10068
  "r-textfield--clearable": o.value,
9819
- "r-textfield--focus": t.value,
9820
- "r-textfield--filled": d.value
10069
+ "r-textfield--focus": d.value,
10070
+ "r-textfield--filled": l.value
9821
10071
  };
9822
- }), S = g(() => ({
10072
+ }), S = h(() => ({
9823
10073
  "r-textfield__prepend-icon": !0,
9824
10074
  "r-textfield__prepend-icon--loading": C.loading,
9825
- "r-textfield__prepend-icon--error": r.value && d.value
9826
- })), v = g(() => ({
10075
+ "r-textfield__prepend-icon--error": Z.value && l.value
10076
+ })), v = h(() => ({
9827
10077
  "r-textfield__append-icon": !0,
9828
10078
  "r-textfield__append-icon--clear": o.value,
9829
- "r-textfield__append-icon--error": r.value
9830
- })), B = g(() => {
9831
- const { prependIcon: f, type: N } = C;
9832
- return f === "none" ? "" : f || e[N];
9833
- }), T = g(() => {
9834
- const { appendIcon: f, type: N } = C;
9835
- return f === "none" ? "" : r.value ? "mdiAlertCircleOutline" : o.value && ["text", "email"].includes(N) ? "mdiClose" : N === "password" && A.value === "password" ? "mdiEyeOutline" : N === "password" && A.value === "text" ? "mdiEyeOffOutline" : f;
9836
- });
9837
- function k(f) {
9838
- t.value = !0, M("focus", f);
10079
+ "r-textfield__append-icon--error": Z.value
10080
+ })), B = h(() => {
10081
+ const { prependIcon: k, type: N } = C;
10082
+ return k === "none" ? "" : k || e[N];
10083
+ }), y = h(() => {
10084
+ const { appendIcon: k, type: N } = C;
10085
+ return k === "none" ? "" : Z.value ? "mdiAlertCircleOutline" : o.value && ["text", "email"].includes(N) ? "mdiClose" : N === "password" && M.value === "password" ? "mdiEyeOutline" : N === "password" && M.value === "text" ? "mdiEyeOffOutline" : k;
10086
+ }), u = h(() => C.id || "r-textfield");
10087
+ function w(k) {
10088
+ d.value = !0, i("focus", k);
9839
10089
  }
9840
- function y(f) {
9841
- t.value = !1, M("blur", f);
10090
+ function _(k) {
10091
+ d.value = !1, i("blur", k);
9842
10092
  }
9843
- function F(f) {
9844
- L.value = f.target.value, M("input", f);
10093
+ function D(k) {
10094
+ L.value = k.target.value, i("input", k);
9845
10095
  }
9846
- function P() {
9847
- var f;
10096
+ function z() {
10097
+ var k;
9848
10098
  if (o.value) {
9849
- L.value = "", (f = i.value) == null || f.focus(), M("click:clear", {
9850
- value: A.value === "number" ? +L.value : L.value
10099
+ L.value = "", (k = A.value) == null || k.focus(), i("click:clear", {
10100
+ value: M.value === "number" ? +L.value : L.value
9851
10101
  });
9852
10102
  return;
9853
10103
  }
9854
- M("click:icon", {
9855
- value: A.value === "number" ? +L.value : L.value
9856
- }), C.type === "password" && U();
9857
- }
9858
- function U() {
9859
- A.value = A.value === "password" ? "text" : "password";
10104
+ i("click:icon", {
10105
+ value: M.value === "number" ? +L.value : L.value
10106
+ }), C.type === "password" && W();
9860
10107
  }
9861
10108
  function W() {
9862
- var f;
9863
- (f = i.value) == null || f.focus();
10109
+ M.value = M.value === "password" ? "text" : "password";
10110
+ }
10111
+ function J() {
10112
+ var k;
10113
+ (k = A.value) == null || k.focus();
9864
10114
  }
9865
- return G(
10115
+ return $(
9866
10116
  () => C.modelValue,
9867
- (f) => {
9868
- L.value = f;
10117
+ (k) => {
10118
+ L.value = k;
9869
10119
  },
9870
10120
  {
9871
10121
  immediate: !0
9872
10122
  }
9873
- ), G(
10123
+ ), $(
9874
10124
  () => L.value,
9875
- (f) => {
9876
- M(
10125
+ (k) => {
10126
+ i(
9877
10127
  "update:modelValue",
9878
- A.value === "number" ? +f : f
10128
+ M.value === "number" ? +k : k
9879
10129
  );
9880
10130
  }
9881
- ), (f, N) => (m(), a("div", _3, [
9882
- C.label ? (m(), _(f2, {
10131
+ ), (k, N) => (m(), r("div", a0, [
10132
+ C.label ? (m(), R(y2, {
9883
10133
  key: 0,
9884
- id: `${C.id}-label`,
10134
+ id: `${u.value}-label`,
9885
10135
  class: "r-textfield__label",
9886
- for: C.id,
10136
+ for: u.value,
9887
10137
  text: C.label,
9888
- onClick: W
9889
- }, null, 8, ["id", "for", "text"])) : O("", !0),
9890
- u("div", E3, [
9891
- u("div", {
9892
- class: p(n.value)
10138
+ onClick: J
10139
+ }, null, 8, ["id", "for", "text"])) : f("", !0),
10140
+ s("div", {
10141
+ id: `${u.value}-input-wrapper`,
10142
+ class: "input-wrapper"
10143
+ }, [
10144
+ s("div", {
10145
+ id: `${u.value}-input-wrapper-inner`,
10146
+ class: O(a.value)
9893
10147
  }, [
9894
- h(f.$slots, "prepend", {
10148
+ g(k.$slots, "prepend", {
10149
+ id: `${u.value}-prepend-slot`,
9895
10150
  disabled: C.disabled,
9896
- error: r.value,
10151
+ error: Z.value,
9897
10152
  loading: C.loading
9898
10153
  }, () => [
9899
- B.value ? (m(), _(D, {
10154
+ B.value ? (m(), R(T, {
9900
10155
  key: 0,
9901
- class: p(S.value),
10156
+ id: `${u.value}-prepend-icon`,
10157
+ class: O(S.value),
9902
10158
  name: B.value,
9903
10159
  size: 20
9904
- }, null, 8, ["class", "name"])) : O("", !0)
10160
+ }, null, 8, ["id", "class", "name"])) : f("", !0)
9905
10161
  ]),
9906
- u("input", F1(f.$attrs, {
9907
- id: C.id,
10162
+ s("input", $1(k.$props, {
10163
+ id: `${u.value}`,
9908
10164
  ref_key: "inputRef",
9909
- ref: i,
10165
+ ref: A,
9910
10166
  disabled: C.disabled,
9911
10167
  max: C.max,
9912
10168
  min: C.min,
9913
10169
  placeholder: C.placeholder,
9914
10170
  readonly: C.readonly,
9915
10171
  role: C.role,
9916
- type: A.value,
10172
+ type: M.value,
9917
10173
  value: L.value,
9918
- onBlur: y,
9919
- onFocus: k,
9920
- onInput: F
9921
- }), null, 16, W3),
9922
- h(f.$slots, "append", {
10174
+ onBlur: _,
10175
+ onFocus: w,
10176
+ onInput: D
10177
+ }), null, 16, u0),
10178
+ g(k.$slots, "append", {
10179
+ id: `${u.value}-append-slot`,
9923
10180
  disabled: C.disabled,
9924
- error: r.value,
10181
+ error: Z.value,
9925
10182
  loading: C.loading
9926
10183
  }, () => [
9927
- f.$props.type === "password" && r.value ? (m(), _(D, {
10184
+ k.$props.type === "password" && Z.value ? (m(), R(T, {
9928
10185
  key: 0,
9929
- name: A.value === "password" ? "mdiEyeOutline" : "mdiEyeOffOutline",
10186
+ id: `${u.value}-append-icon`,
10187
+ name: M.value === "password" ? "mdiEyeOutline" : "mdiEyeOffOutline",
9930
10188
  size: 20,
9931
- onClick: P
9932
- }, null, 8, ["name"])) : O("", !0),
9933
- T.value && !f.$slots.append || r.value ? (m(), _(D, {
10189
+ onClick: z
10190
+ }, null, 8, ["id", "name"])) : f("", !0),
10191
+ y.value && !k.$slots.append || Z.value ? (m(), R(T, {
9934
10192
  key: 1,
9935
- class: p(v.value),
9936
- name: `${T.value}`,
10193
+ id: `${u.value}-append-icon`,
10194
+ class: O(v.value),
10195
+ name: `${y.value}`,
9937
10196
  size: 20,
9938
- onClick: P
9939
- }, null, 8, ["class", "name"])) : O("", !0)
10197
+ onClick: z
10198
+ }, null, 8, ["id", "class", "name"])) : f("", !0)
9940
10199
  ])
9941
- ], 2),
9942
- C.hideDetails ? O("", !0) : (m(), a("div", N3, [
9943
- C.errorMsg ? (m(), a("p", I3, b(C.errorMsg), 1)) : O("", !0),
9944
- !C.errorMsg && C.hint ? (m(), a("p", Q3, b(C.hint), 1)) : O("", !0)
9945
- ]))
9946
- ])
10200
+ ], 10, Z0),
10201
+ C.hideDetails ? f("", !0) : (m(), r("div", {
10202
+ key: 0,
10203
+ id: `${u.value}-details`,
10204
+ class: "r-textfield__details"
10205
+ }, [
10206
+ C.errorMsg ? (m(), r("p", {
10207
+ key: 0,
10208
+ id: `${u.value}-error`,
10209
+ class: "r-textfield__error"
10210
+ }, b(C.errorMsg), 9, s0)) : f("", !0),
10211
+ !C.errorMsg && C.hint ? (m(), r("p", c0, b(C.hint), 1)) : f("", !0)
10212
+ ], 8, S0))
10213
+ ], 8, r0)
9947
10214
  ]));
9948
10215
  }
9949
- }), G3 = { class: "r-breadcrumb" }, $3 = {
9950
- key: 0,
9951
- class: "r-breadcrumb__title"
9952
- }, D0 = /* @__PURE__ */ R({
10216
+ }), p0 = ["id"], O0 = ["id"], n7 = /* @__PURE__ */ F({
9953
10217
  __name: "RBreadcrumb",
9954
10218
  props: {
9955
10219
  items: { default: () => [] },
9956
- seperator: { default: "mdiChevronRight" }
10220
+ seperator: { default: "mdiChevronRight" },
10221
+ id: { default: "r-breadcrumb" }
9957
10222
  },
9958
10223
  setup(H) {
9959
10224
  const V = H;
9960
- return (C, M) => {
9961
- const i = w2("router-link");
9962
- return m(), a("div", G3, [
9963
- (m(!0), a(H1, null, t1(V.items, (L, A) => (m(), a("div", {
9964
- key: A,
10225
+ return (C, i) => {
10226
+ const A = x2("router-link");
10227
+ return m(), r("div", {
10228
+ id: C.id,
10229
+ class: "r-breadcrumb"
10230
+ }, [
10231
+ (m(!0), r(A1, null, n1(V.items, (L, M) => (m(), r("div", {
10232
+ key: M,
9965
10233
  class: "r-breadcrumb__item"
9966
10234
  }, [
9967
- q(i, {
10235
+ H1(A, {
10236
+ id: `${C.id}-link-${M}`,
9968
10237
  class: "r-breadcrumb__link",
9969
10238
  to: L.to
9970
10239
  }, {
9971
- default: b1(() => [
9972
- h(C.$slots, "item-icon", {}, () => [
9973
- L.icon ? (m(), _(D, {
10240
+ default: F1(() => [
10241
+ g(C.$slots, "item-icon", {}, () => [
10242
+ L.icon ? (m(), R(T, {
9974
10243
  key: 0,
9975
10244
  name: L.icon
9976
- }, null, 8, ["name"])) : O("", !0)
10245
+ }, null, 8, ["name"])) : f("", !0)
9977
10246
  ]),
9978
- L.onlyIcon ? O("", !0) : (m(), a("span", $3, b(L.title), 1))
10247
+ L.onlyIcon ? f("", !0) : (m(), r("span", {
10248
+ key: 0,
10249
+ id: `${C.id}-title-${M}`,
10250
+ class: "r-breadcrumb__title"
10251
+ }, b(L.title), 9, O0))
9979
10252
  ]),
9980
10253
  _: 2
9981
- }, 1032, ["to"]),
9982
- h(C.$slots, "custom-seperator", {}, () => [
9983
- A !== C.items.length - 1 && V.seperator ? (m(), _(D, {
10254
+ }, 1032, ["id", "to"]),
10255
+ g(C.$slots, "custom-seperator", {
10256
+ id: `${C.id}-separator-${M}`
10257
+ }, () => [
10258
+ M !== C.items.length - 1 && V.seperator ? (m(), R(T, {
9984
10259
  key: 0,
10260
+ id: `${C.id}-separator-${M}`,
9985
10261
  class: "r-breadcrumb__separator",
9986
10262
  name: V.seperator
9987
- }, null, 8, ["name"])) : O("", !0)
10263
+ }, null, 8, ["id", "name"])) : f("", !0)
9988
10264
  ])
9989
10265
  ]))), 128))
9990
- ]);
10266
+ ], 8, p0);
9991
10267
  };
9992
10268
  }
9993
- }), U3 = { class: "r-pagination__paginator" }, z3 = { class: "r-pagination__paginator__per-page" }, K3 = { class: "r-pagination__paginator__info" }, q3 = ["disabled"], j3 = /* @__PURE__ */ u("path", {
10269
+ }), f0 = ["id"], h0 = ["id"], g0 = ["id"], k0 = ["id"], B0 = ["id", "disabled"], b0 = /* @__PURE__ */ s("path", {
9994
10270
  d: "M0 0h24v24H0z",
9995
10271
  fill: "none",
9996
10272
  stroke: "none"
9997
- }, null, -1), X3 = /* @__PURE__ */ u("path", { d: "M7 6v12" }, null, -1), Y3 = /* @__PURE__ */ u("path", { d: "M18 6l-6 6l6 6" }, null, -1), J3 = [
9998
- j3,
9999
- X3,
10000
- Y3
10001
- ], C0 = ["disabled"], H0 = /* @__PURE__ */ u("path", {
10273
+ }, null, -1), v0 = /* @__PURE__ */ s("path", { d: "M7 6v12" }, null, -1), w0 = /* @__PURE__ */ s("path", { d: "M18 6l-6 6l6 6" }, null, -1), y0 = [
10274
+ b0,
10275
+ v0,
10276
+ w0
10277
+ ], P0 = ["id", "disabled"], T0 = /* @__PURE__ */ s("path", {
10002
10278
  d: "M0 0h24v24H0z",
10003
10279
  fill: "none",
10004
10280
  stroke: "none"
10005
- }, null, -1), V0 = /* @__PURE__ */ u("path", { d: "M15 6l-6 6l6 6" }, null, -1), L0 = [
10006
- H0,
10007
- V0
10008
- ], M0 = ["disabled"], i0 = /* @__PURE__ */ u("path", {
10281
+ }, null, -1), F0 = /* @__PURE__ */ s("path", { d: "M15 6l-6 6l6 6" }, null, -1), R0 = [
10282
+ T0,
10283
+ F0
10284
+ ], x0 = ["id", "disabled"], D0 = /* @__PURE__ */ s("path", {
10009
10285
  d: "M0 0h24v24H0z",
10010
10286
  fill: "none",
10011
10287
  stroke: "none"
10012
- }, null, -1), A0 = /* @__PURE__ */ u("path", { d: "M9 6l6 6l-6 6" }, null, -1), e0 = [
10013
- i0,
10014
- A0
10015
- ], t0 = ["disabled"], d0 = /* @__PURE__ */ u("path", {
10288
+ }, null, -1), E0 = /* @__PURE__ */ s("path", { d: "M9 6l6 6l-6 6" }, null, -1), _0 = [
10289
+ D0,
10290
+ E0
10291
+ ], $0 = ["id", "disabled"], W0 = /* @__PURE__ */ s("path", {
10016
10292
  d: "M0 0h24v24H0z",
10017
10293
  fill: "none",
10018
10294
  stroke: "none"
10019
- }, null, -1), m0 = /* @__PURE__ */ u("path", { d: "M6 6l6 6l-6 6" }, null, -1), l0 = /* @__PURE__ */ u("path", { d: "M17 5v13" }, null, -1), o0 = [
10020
- d0,
10021
- m0,
10022
- l0
10023
- ], _0 = /* @__PURE__ */ R({
10295
+ }, null, -1), N0 = /* @__PURE__ */ s("path", { d: "M6 6l6 6l-6 6" }, null, -1), I0 = /* @__PURE__ */ s("path", { d: "M17 5v13" }, null, -1), Q0 = [
10296
+ W0,
10297
+ N0,
10298
+ I0
10299
+ ], a7 = /* @__PURE__ */ F({
10024
10300
  __name: "RPagination",
10025
10301
  props: {
10026
10302
  page: { default: 1 },
@@ -10029,57 +10305,71 @@ const v3 = ["aria-disabled", "aria-selected", "disabled"], y3 = { key: 0 }, P3 =
10029
10305
  perPageOptions: { default: () => [10, 20, 50, 100] },
10030
10306
  itemsPerPageText: { default: "Items per page:" },
10031
10307
  position: { default: "right" },
10032
- infoText: { default: "1-10 of 100" }
10308
+ infoText: { default: "1-10 of 100" },
10309
+ id: { default: "r-pagination" }
10033
10310
  },
10034
10311
  emits: ["update:page", "update:perPage", "update:info"],
10035
10312
  setup(H, { emit: V }) {
10036
- const C = H, M = V, i = E(C.perPage || 10), L = g(() => Math.ceil(C.totalItems / C.perPage)), A = g(() => ({
10313
+ const C = H, i = V, A = E(C.perPage || 10), L = h(() => Math.ceil(C.totalItems / C.perPage)), M = h(() => ({
10037
10314
  start: C.page * C.perPage - C.perPage,
10038
10315
  end: C.page * C.perPage
10039
- })), e = g(() => C.infoText || `${A.value.start + 1}-${A.value.end} of ${C.totalItems}`), t = g(() => +C.page == +L.value), d = g(() => +C.page == 1);
10040
- G(() => A.value, () => {
10041
- M("update:info", A.value);
10042
- }), G(() => C.perPage, () => {
10043
- i.value = C.perPage, l(1);
10316
+ })), e = h(() => C.infoText || `${M.value.start + 1}-${M.value.end} of ${C.totalItems}`), d = h(() => +C.page == +L.value), l = h(() => +C.page == 1);
10317
+ $(() => M.value, () => {
10318
+ i("update:info", M.value);
10319
+ }), $(() => C.perPage, () => {
10320
+ A.value = C.perPage, n(1);
10044
10321
  });
10045
- function l(o) {
10046
- const n = Math.ceil(o);
10047
- n < 1 || n > L.value || M("update:page", n);
10322
+ function n(o) {
10323
+ const a = Math.ceil(o);
10324
+ a < 1 || a > L.value || i("update:page", a);
10048
10325
  }
10049
- function r({ value: o }) {
10326
+ function Z({ value: o }) {
10050
10327
  if (o) {
10051
- M("update:perPage", o);
10328
+ i("update:perPage", o);
10052
10329
  return;
10053
10330
  }
10054
- M("update:perPage", 10);
10331
+ i("update:perPage", 10);
10055
10332
  }
10056
- return (o, n) => (m(), a("div", {
10057
- class: p(["r-pagination", [`r-pagination--${C.position}`]])
10333
+ return (o, a) => (m(), r("div", {
10334
+ id: o.id,
10335
+ class: O(["r-pagination", [`r-pagination--${C.position}`]])
10058
10336
  }, [
10059
- u("div", U3, [
10060
- u("div", z3, [
10061
- u("span", null, b(C.itemsPerPageText), 1),
10062
- q(m3, {
10063
- modelValue: i.value,
10337
+ s("div", {
10338
+ id: `${o.id}-paginator`,
10339
+ class: "r-pagination__paginator"
10340
+ }, [
10341
+ s("div", {
10342
+ id: `${o.id}-paginator-per-page`,
10343
+ class: "r-pagination__paginator__per-page"
10344
+ }, [
10345
+ s("span", null, b(C.itemsPerPageText), 1),
10346
+ H1(D3, {
10347
+ modelValue: A.value,
10064
10348
  "onUpdate:modelValue": [
10065
- n[0] || (n[0] = (S) => i.value = S),
10066
- r
10349
+ a[0] || (a[0] = (S) => A.value = S),
10350
+ Z
10067
10351
  ],
10068
10352
  class: "w-24",
10069
10353
  "hide-details": "",
10070
10354
  "hide-option-check-icon": "",
10071
10355
  options: C.perPageOptions
10072
10356
  }, null, 8, ["modelValue", "options"])
10073
- ]),
10074
- u("span", K3, b(e.value), 1),
10075
- u("button", {
10357
+ ], 8, g0),
10358
+ s("span", {
10359
+ id: `${o.id}-paginator-info`,
10360
+ class: "r-pagination__paginator__info"
10361
+ }, b(e.value), 9, k0),
10362
+ s("button", {
10363
+ id: `${o.id}-paginator-first`,
10076
10364
  class: "r-pagination__paginator__first",
10077
- disabled: d.value,
10078
- onClick: n[1] || (n[1] = (S) => l(1))
10365
+ disabled: l.value,
10366
+ onClick: a[1] || (a[1] = (S) => n(1))
10079
10367
  }, [
10080
- h(o.$slots, "first", {}, () => [
10081
- (m(), a("svg", {
10082
- class: p(["icon icon-tabler icon-tabler-chevron-left-pipe", { "stroke-gray-400": d.value }]),
10368
+ g(o.$slots, "first", {
10369
+ id: `${o.id}-paginator-first-slot`
10370
+ }, () => [
10371
+ (m(), r("svg", {
10372
+ class: O(["icon icon-tabler icon-tabler-chevron-left-pipe", { "stroke-gray-400": l.value }]),
10083
10373
  fill: "none",
10084
10374
  height: "20",
10085
10375
  stroke: "#000000",
@@ -10089,17 +10379,20 @@ const v3 = ["aria-disabled", "aria-selected", "disabled"], y3 = { key: 0 }, P3 =
10089
10379
  viewBox: "0 0 24 24",
10090
10380
  width: "20",
10091
10381
  xmlns: "http://www.w3.org/2000/svg"
10092
- }, J3, 2))
10382
+ }, y0, 2))
10093
10383
  ])
10094
- ], 8, q3),
10095
- u("button", {
10384
+ ], 8, B0),
10385
+ s("button", {
10386
+ id: `${o.id}-paginator-prev`,
10096
10387
  class: "r-pagination__paginator__prev",
10097
- disabled: d.value,
10098
- onClick: n[2] || (n[2] = (S) => l(+C.page - 1))
10388
+ disabled: l.value,
10389
+ onClick: a[2] || (a[2] = (S) => n(+C.page - 1))
10099
10390
  }, [
10100
- h(o.$slots, "prev", {}, () => [
10101
- (m(), a("svg", {
10102
- class: p(["icon icon-tabler icon-tabler-chevron-left", { "stroke-gray-400": d.value }]),
10391
+ g(o.$slots, "prev", {
10392
+ id: `${o.id}-paginator-prev-slot`
10393
+ }, () => [
10394
+ (m(), r("svg", {
10395
+ class: O(["icon icon-tabler icon-tabler-chevron-left", { "stroke-gray-400": l.value }]),
10103
10396
  fill: "none",
10104
10397
  height: "20",
10105
10398
  stroke: "#000000",
@@ -10109,17 +10402,20 @@ const v3 = ["aria-disabled", "aria-selected", "disabled"], y3 = { key: 0 }, P3 =
10109
10402
  viewBox: "0 0 24 24",
10110
10403
  width: "20",
10111
10404
  xmlns: "http://www.w3.org/2000/svg"
10112
- }, L0, 2))
10405
+ }, R0, 2))
10113
10406
  ])
10114
- ], 8, C0),
10115
- u("button", {
10407
+ ], 8, P0),
10408
+ s("button", {
10409
+ id: `${o.id}-paginator-next`,
10116
10410
  class: "r-pagination__paginator__next",
10117
- disabled: t.value,
10118
- onClick: n[3] || (n[3] = (S) => l(+C.page + 1))
10411
+ disabled: d.value,
10412
+ onClick: a[3] || (a[3] = (S) => n(+C.page + 1))
10119
10413
  }, [
10120
- h(o.$slots, "next", {}, () => [
10121
- (m(), a("svg", {
10122
- class: p(["icon icon-tabler icon-tabler-chevron-right", { "stroke-gray-400": t.value }]),
10414
+ g(o.$slots, "next", {
10415
+ id: `${o.id}-paginator-next-slot`
10416
+ }, () => [
10417
+ (m(), r("svg", {
10418
+ class: O(["icon icon-tabler icon-tabler-chevron-right", { "stroke-gray-400": d.value }]),
10123
10419
  fill: "none",
10124
10420
  height: "20",
10125
10421
  stroke: "#000000",
@@ -10129,17 +10425,20 @@ const v3 = ["aria-disabled", "aria-selected", "disabled"], y3 = { key: 0 }, P3 =
10129
10425
  viewBox: "0 0 24 24",
10130
10426
  width: "20",
10131
10427
  xmlns: "http://www.w3.org/2000/svg"
10132
- }, e0, 2))
10428
+ }, _0, 2))
10133
10429
  ])
10134
- ], 8, M0),
10135
- u("button", {
10430
+ ], 8, x0),
10431
+ s("button", {
10432
+ id: `${o.id}-paginator-last`,
10136
10433
  class: "r-pagination__paginator__last",
10137
10434
  disabled: C.page === L.value,
10138
- onClick: n[4] || (n[4] = (S) => l(L.value))
10435
+ onClick: a[4] || (a[4] = (S) => n(L.value))
10139
10436
  }, [
10140
- h(o.$slots, "last", {}, () => [
10141
- (m(), a("svg", {
10142
- class: p(["icon icon-tabler icon-tabler-chevron-right-pipe", { "stroke-gray-400": t.value }]),
10437
+ g(o.$slots, "last", {
10438
+ id: `${o.id}-paginator-last-slot`
10439
+ }, () => [
10440
+ (m(), r("svg", {
10441
+ class: O(["icon icon-tabler icon-tabler-chevron-right-pipe", { "stroke-gray-400": d.value }]),
10143
10442
  fill: "none",
10144
10443
  height: "20",
10145
10444
  stroke: "#000000",
@@ -10149,30 +10448,32 @@ const v3 = ["aria-disabled", "aria-selected", "disabled"], y3 = { key: 0 }, P3 =
10149
10448
  viewBox: "0 0 24 24",
10150
10449
  width: "20",
10151
10450
  xmlns: "http://www.w3.org/2000/svg"
10152
- }, o0, 2))
10451
+ }, Q0, 2))
10153
10452
  ])
10154
- ], 8, t0)
10155
- ])
10156
- ], 2));
10453
+ ], 8, $0)
10454
+ ], 8, h0)
10455
+ ], 10, f0));
10157
10456
  }
10158
- }), n0 = ["value"], E0 = /* @__PURE__ */ R({
10457
+ }), G0 = ["id", "value"], r7 = /* @__PURE__ */ F({
10159
10458
  __name: "RProgressbar",
10160
10459
  props: {
10161
10460
  value: { default: 0 },
10162
- height: { default: 8 }
10461
+ height: { default: 8 },
10462
+ id: { default: "r-progressbar" }
10163
10463
  },
10164
10464
  setup(H) {
10165
10465
  const V = H;
10166
- return (C, M) => (m(), a("progress", {
10466
+ return (C, i) => (m(), r("progress", {
10467
+ id: C.id,
10167
10468
  "aria-valuemax": 100,
10168
10469
  class: "r-progressbar",
10169
10470
  max: 100,
10170
10471
  role: "progressbar",
10171
- style: $1({ height: `${V.height}px` }),
10472
+ style: J1({ height: `${V.height}px` }),
10172
10473
  value: V.value
10173
- }, null, 12, n0));
10474
+ }, null, 12, G0));
10174
10475
  }
10175
- }), k1 = "rocket-ui:r-item-group", W0 = /* @__PURE__ */ R({
10476
+ }), y1 = "rocket-ui:r-item-group", Z7 = /* @__PURE__ */ F({
10176
10477
  __name: "RItemGroup",
10177
10478
  props: {
10178
10479
  modelValue: { default: () => [] },
@@ -10181,65 +10482,66 @@ const v3 = ["aria-disabled", "aria-selected", "disabled"], y3 = { key: 0 }, P3 =
10181
10482
  mandatory: { type: Boolean, default: !1 },
10182
10483
  max: { default: 0 },
10183
10484
  as: { default: "div" },
10184
- multiple: { type: Boolean }
10485
+ multiple: { type: Boolean },
10486
+ id: { default: "r-item-group" }
10185
10487
  },
10186
10488
  emits: ["update:modelValue"],
10187
10489
  setup(H, { emit: V }) {
10188
- const C = H, M = V, i = E(C.as ?? "div"), L = E(C.modelValue), A = g(() => C.selectedClass);
10189
- h1(`${k1}:selectedClass`, A.value);
10190
- function e(l) {
10191
- return L.value.includes(l);
10490
+ const C = H, i = V, A = E(C.as ?? "div"), L = E(C.modelValue), M = h(() => C.selectedClass);
10491
+ v1(`${y1}:selectedClass`, M.value);
10492
+ function e(n) {
10493
+ return L.value.includes(n);
10192
10494
  }
10193
- h1(`${k1}:isSelected`, e);
10194
- function t(l, r) {
10195
- C.disabled || C.mandatory && L.value.length === 1 && !r || C.max && L.value.length === C.max && r || (C.multiple ? r ? L.value.push(l) : L.value = L.value.filter((o) => o !== l) : L.value = l ? [l] : [], M("update:modelValue", L.value));
10495
+ v1(`${y1}:isSelected`, e);
10496
+ function d(n, Z) {
10497
+ C.disabled || C.mandatory && L.value.length === 1 && !Z || C.max && L.value.length === C.max && Z || (C.multiple ? Z ? L.value.push(n) : L.value = L.value.filter((o) => o !== n) : L.value = n ? [n] : [], i("update:modelValue", L.value));
10196
10498
  }
10197
- h1(`${k1}:select`, t);
10198
- function d() {
10499
+ v1(`${y1}:select`, d);
10500
+ function l() {
10199
10501
  return C.disabled;
10200
10502
  }
10201
- return h1(`${k1}:isDisabled`, d), G(() => C.modelValue, () => {
10503
+ return v1(`${y1}:isDisabled`, l), $(() => C.modelValue, () => {
10202
10504
  L.value = C.modelValue;
10203
- }), (l, r) => (m(), _(v2(i.value), null, {
10204
- default: b1(() => [
10205
- h(l.$slots, "default", {
10505
+ }), (n, Z) => (m(), R(D2(A.value), { id: n.id }, {
10506
+ default: F1(() => [
10507
+ g(n.$slots, "default", {
10508
+ id: `${n.id}-slot`,
10206
10509
  isSelected: e,
10207
- select: t,
10510
+ select: d,
10208
10511
  selected: L.value
10209
10512
  })
10210
10513
  ]),
10211
10514
  _: 3
10212
- }));
10515
+ }, 8, ["id"]));
10213
10516
  }
10214
- }), B1 = "rocket-ui:r-item-group", N0 = /* @__PURE__ */ R({
10517
+ }), P1 = "rocket-ui:r-item-group", u7 = /* @__PURE__ */ F({
10215
10518
  __name: "RItem",
10216
10519
  props: {
10217
10520
  value: { default: null },
10218
- selectedClass: { default: "" }
10521
+ selectedClass: { default: "" },
10522
+ id: { default: "r-item" }
10219
10523
  },
10220
10524
  setup(H) {
10221
- const V = H, C = g1(`${B1}:isSelected`), M = g1(`${B1}:selectedClass`, ""), i = g1(`${B1}:select`), L = g1(`${B1}:isDisabled`), A = g(() => C(V.value) && [M, V.selectedClass]);
10525
+ const V = H, C = w1(`${P1}:isSelected`), i = w1(`${P1}:selectedClass`, ""), A = w1(`${P1}:select`), L = w1(`${P1}:isDisabled`), M = h(() => C(V.value) && [i, V.selectedClass]);
10222
10526
  function e() {
10223
- V.disabled || i(V.value, !C(V.value));
10527
+ V.disabled || A(V.value, !C(V.value));
10224
10528
  }
10225
- function t() {
10226
- V.disabled || i(V.value, !0);
10529
+ function d() {
10530
+ V.disabled || A(V.value, !0);
10227
10531
  }
10228
- return (d, l) => h(d.$slots, "default", {
10229
- disabled: J(L)(V.value),
10230
- isSelected: J(C)(V.value),
10231
- select: t,
10232
- selectedClass: A.value,
10532
+ return (l, n) => g(l.$slots, "default", {
10533
+ id: `${l.id}-slot`,
10534
+ disabled: e1(L)(V.value),
10535
+ isSelected: e1(C)(V.value),
10536
+ select: d,
10537
+ selectedClass: M.value,
10233
10538
  toggle: e
10234
10539
  });
10235
10540
  }
10236
- }), r0 = ["id", "checked", "disabled", "name", "value"], a0 = { class: "flex flex-col" }, Z0 = {
10237
- key: 1,
10238
- class: "r-radio__error"
10239
- }, I0 = /* @__PURE__ */ R({
10541
+ }), U0 = ["id", "checked", "disabled", "name", "value"], z0 = ["id"], K0 = ["id"], q0 = { class: "flex flex-col" }, j0 = ["id"], X0 = ["id"], Y0 = ["id"], S7 = /* @__PURE__ */ F({
10240
10542
  __name: "RRadio",
10241
10543
  props: {
10242
- id: { default: "radio-id" },
10544
+ id: { default: "" },
10243
10545
  modelValue: { type: Boolean, default: !1 },
10244
10546
  name: { default: "radio-group" },
10245
10547
  disabled: { type: Boolean, default: !1 },
@@ -10251,175 +10553,83 @@ const v3 = ["aria-disabled", "aria-selected", "disabled"], y3 = { key: 0 }, P3 =
10251
10553
  },
10252
10554
  emits: ["update:modelValue"],
10253
10555
  setup(H) {
10254
- const V = H, C = E(V.modelValue), M = g(() => [
10556
+ const V = H, C = h(() => V.id || "r-radio"), i = E(V.modelValue), A = h(() => [
10255
10557
  "r-radio group",
10256
10558
  {
10257
10559
  "r-radio--disabled": V.disabled,
10258
10560
  "r-radio--error": V.errorMsg
10259
10561
  }
10260
10562
  ]);
10261
- return G(() => V.modelValue, (i) => {
10262
- C.value = i;
10263
- }, { immediate: !0 }), (i, L) => (m(), a("div", {
10264
- class: p(M.value)
10563
+ return $(() => V.modelValue, (L) => {
10564
+ i.value = L;
10565
+ }, { immediate: !0 }), (L, M) => (m(), r("div", {
10566
+ class: O(A.value)
10265
10567
  }, [
10266
- u("input", F1(i.$attrs, {
10267
- id: V.id,
10268
- checked: C.value,
10568
+ s("input", $1(L.$attrs, {
10569
+ id: `${C.value}`,
10570
+ checked: i.value,
10269
10571
  class: "r-radio__input",
10270
10572
  disabled: V.disabled,
10271
10573
  name: V.name,
10272
10574
  type: "radio",
10273
10575
  value: V.value,
10274
- onChange: L[0] || (L[0] = (A) => i.$emit("update:modelValue"))
10275
- }), null, 16, r0),
10276
- u("span", {
10277
- class: p(["r-radio__label", [V.errorMsg && "r-radio__label--error"]]),
10278
- onClick: L[1] || (L[1] = (A) => i.$emit("update:modelValue"))
10576
+ onChange: M[0] || (M[0] = (e) => L.$emit("update:modelValue"))
10577
+ }), null, 16, U0),
10578
+ s("span", {
10579
+ id: `${C.value}-label`,
10580
+ class: O(["r-radio__label", [V.errorMsg && "r-radio__label--error"]]),
10581
+ onClick: M[1] || (M[1] = (e) => L.$emit("update:modelValue"))
10279
10582
  }, [
10280
- u("span", {
10281
- class: p(["r-radio__custom", [V.errorMsg && "r-radio__custom--error", V.disabled && "r-radio__custom--disabled"]])
10282
- }, null, 2),
10283
- u("div", a0, [
10284
- V.title ? (m(), a("span", {
10583
+ s("span", {
10584
+ id: `${C.value}-custom`,
10585
+ class: O(["r-radio__custom", [V.errorMsg && "r-radio__custom--error", V.disabled && "r-radio__custom--disabled"]])
10586
+ }, null, 10, K0),
10587
+ s("div", q0, [
10588
+ V.title ? (m(), r("span", {
10285
10589
  key: 0,
10286
- class: p(["r-radio__title", [V.errorMsg && "r-radio__title--error", V.disabled && "r-radio__title--disabled"]])
10287
- }, b(V.title), 3)) : O("", !0),
10288
- u("span", null, b(V.label), 1)
10590
+ id: `${C.value}-title`,
10591
+ class: O(["r-radio__title", [V.errorMsg && "r-radio__title--error", V.disabled && "r-radio__title--disabled"]])
10592
+ }, b(V.title), 11, j0)) : f("", !0),
10593
+ s("span", null, b(V.label), 1)
10289
10594
  ])
10290
- ], 2),
10291
- V.hint && !V.errorMsg ? (m(), a("span", {
10595
+ ], 10, z0),
10596
+ V.hint && !V.errorMsg ? (m(), r("span", {
10292
10597
  key: 0,
10293
- class: p(["r-radio__hint", [V.disabled && "r-radio__hint--disabled"]])
10294
- }, b(V.hint), 3)) : O("", !0),
10295
- V.errorMsg ? (m(), a("span", Z0, b(V.errorMsg), 1)) : O("", !0)
10598
+ id: `${C.value}-hint`,
10599
+ class: O(["r-radio__hint", [V.disabled && "r-radio__hint--disabled"]])
10600
+ }, b(V.hint), 11, X0)) : f("", !0),
10601
+ V.errorMsg ? (m(), r("span", {
10602
+ key: 1,
10603
+ id: `${C.value}-error`,
10604
+ class: "r-radio__error"
10605
+ }, b(V.errorMsg), 9, Y0)) : f("", !0)
10296
10606
  ], 2));
10297
10607
  }
10298
- }), r1 = /* @__PURE__ */ new WeakMap();
10299
- function u0(H) {
10300
- const V = document.createElement("div");
10301
- V.className = "r-tooltip", V.style.cssText = `
10302
- position: absolute;
10303
- z-index: 10000;
10304
- background: transparent;
10305
- margin: 0;
10306
- padding: 0;
10307
- top: 0;
10308
- left: 0;
10309
- display: none;
10310
- `, V.dataset.show = "false";
10311
- const C = document.createElement("div");
10312
- C.className = `r-tooltip__content ${H.dark !== !1 ? "r-tooltip__content--dark" : "r-tooltip__content--light"}`, C.textContent = H.text || "";
10313
- const M = document.createElement("div");
10314
- return M.id = "arrow", M.className = `r-tooltip__arrow ${H.dark !== !1 ? "r-tooltip__arrow--dark" : "r-tooltip__arrow--light"}`, H.dark === !1 && V.classList.add("r-tooltip--light"), V.appendChild(C), V.appendChild(M), V;
10315
- }
10316
- function S0(H, V, C = "top", M = 8) {
10317
- const i = V.getBoundingClientRect(), L = window.pageXOffset, A = window.pageYOffset, e = H.querySelector("#arrow");
10318
- H.style.visibility = "hidden", H.style.display = "block";
10319
- const t = H.getBoundingClientRect();
10320
- H.style.visibility = "";
10321
- let d = 0, l = 0;
10322
- switch (C) {
10323
- case "top":
10324
- d = i.left + L + (i.width - t.width) / 2, l = i.top + A - t.height - M;
10325
- break;
10326
- case "bottom":
10327
- d = i.left + L + (i.width - t.width) / 2, l = i.bottom + A + M;
10328
- break;
10329
- case "left":
10330
- d = i.left + L - t.width - M, l = i.top + A + (i.height - t.height) / 2;
10331
- break;
10332
- case "right":
10333
- d = i.right + L + M, l = i.top + A + (i.height - t.height) / 2;
10334
- break;
10335
- }
10336
- const r = window.innerWidth, o = window.innerHeight;
10337
- d < 0 && (d = 8), d + t.width > r && (d = r - t.width - 8), l < A && (l = A + 8), l + t.height > A + o && (l = A + o - t.height - 8), H.style.left = `${d}px`, H.style.top = `${l}px`, e && s0(e, C, t);
10338
- }
10339
- function s0(H, V, C, M) {
10340
- H.style.left = "", H.style.top = "", H.style.right = "", H.style.bottom = "";
10341
- const i = 8;
10342
- switch (V) {
10343
- case "top":
10344
- H.style.left = `${C.width / 2 - i}px`, H.style.bottom = "-4px";
10345
- break;
10346
- case "bottom":
10347
- H.style.left = `${C.width / 2 - i}px`, H.style.top = "-4px";
10348
- break;
10349
- case "left":
10350
- H.style.top = `${C.height / 2 - i}px`, H.style.right = "-4px";
10351
- break;
10352
- case "right":
10353
- H.style.top = `${C.height / 2 - i}px`, H.style.left = "-4px";
10354
- break;
10355
- }
10356
- }
10357
- function c0(H, V, C) {
10358
- C.disabled || (document.body.appendChild(H), S0(H, V, C.placement, C.offset), H.style.display = "block", H.classList.add("r-tooltip--active"), H.dataset.show = "true", H.style.animation = "r-tooltip-show 200ms ease-out forwards");
10359
- }
10360
- function p0(H) {
10361
- H.style.display = "", H.classList.remove("r-tooltip--active"), H.dataset.show = "false", H.parentNode && document.body.removeChild(H);
10362
- }
10363
- const O0 = {
10364
- mounted(H, V) {
10365
- const C = typeof V.value == "string" ? { text: V.value } : { ...V.value };
10366
- if (!C.text || C.disabled)
10367
- return;
10368
- const M = u0(C);
10369
- let i, L;
10370
- const A = () => {
10371
- clearTimeout(L), i = setTimeout(() => {
10372
- c0(M, H, C);
10373
- }, C.delay || 0);
10374
- }, e = () => {
10375
- clearTimeout(i), L = setTimeout(() => {
10376
- p0(M);
10377
- }, 100);
10378
- }, t = () => {
10379
- M.parentNode ? e() : A();
10380
- }, d = (r) => {
10381
- C.outsideClick && !H.contains(r.target) && !M.contains(r.target) && e();
10382
- };
10383
- C.trigger === "click" ? (H.addEventListener("click", t), C.outsideClick && document.addEventListener("click", d)) : (H.addEventListener("mouseenter", A), H.addEventListener("mouseleave", e));
10384
- const l = () => {
10385
- clearTimeout(i), clearTimeout(L), H.removeEventListener("mouseenter", A), H.removeEventListener("mouseleave", e), H.removeEventListener("click", t), document.removeEventListener("click", d), M.parentNode && document.body.removeChild(M);
10386
- };
10387
- r1.set(H, { element: M, cleanup: l });
10388
- },
10389
- updated(H, V) {
10390
- const C = r1.get(H);
10391
- C && (C.cleanup(), r1.delete(H)), O0.mounted(H, V, null, null);
10392
- },
10393
- unmounted(H) {
10394
- const V = r1.get(H);
10395
- V && (V.cleanup(), r1.delete(H));
10396
- }
10397
- };
10608
+ });
10398
10609
  export {
10399
- h0 as RAccordion,
10400
- g0 as RAlert,
10401
- k0 as RAvatar,
10402
- B0 as RBadge,
10403
- D0 as RBreadcrumb,
10404
- b0 as RButton,
10405
- w0 as RCheckbox,
10406
- L5 as RChip,
10407
- m3 as RDropdown,
10408
- D as RIcon,
10409
- N0 as RItem,
10410
- W0 as RItemGroup,
10411
- f2 as RLabel,
10412
- v0 as RModal,
10413
- _0 as RPagination,
10414
- E0 as RProgressbar,
10415
- I0 as RRadio,
10416
- y0 as RSidebar,
10417
- P0 as RSnackbar,
10418
- T0 as RSwitch,
10419
- P3 as RTabItem,
10420
- F0 as RTabs,
10421
- R0 as RTextArea,
10422
- x0 as RTextfield,
10423
- z5 as RTooltip,
10424
- O0 as vTooltip
10610
+ C7 as RAccordion,
10611
+ H7 as RAlert,
10612
+ V7 as RAvatar,
10613
+ L7 as RBadge,
10614
+ n7 as RBreadcrumb,
10615
+ M7 as RButton,
10616
+ i7 as RCheckbox,
10617
+ c5 as RChip,
10618
+ D3 as RDropdown,
10619
+ T as RIcon,
10620
+ u7 as RItem,
10621
+ Z7 as RItemGroup,
10622
+ y2 as RLabel,
10623
+ A7 as RModal,
10624
+ a7 as RPagination,
10625
+ r7 as RProgressbar,
10626
+ S7 as RRadio,
10627
+ e7 as RSidebar,
10628
+ d7 as RSnackbar,
10629
+ t7 as RSwitch,
10630
+ A0 as RTabItem,
10631
+ m7 as RTabs,
10632
+ l7 as RTextArea,
10633
+ o7 as RTextfield,
10634
+ l3 as RTooltip
10425
10635
  };