fds-vue-core 2.0.34 → 2.0.35

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 +1 @@
1
- {"version":3,"file":"FdsModal.vue.d.ts","sourceRoot":"","sources":["../../../src/components/FdsModal/FdsModal.vue"],"names":[],"mappings":"AAqPA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,SAAS,CAAA;AAkV5C,QAAA,IAAI,QAAQ,IAAW,EAAE,QAAQ,IAAY,CAAE;AAC/C,KAAK,WAAW,GAAG,EAAE,GACnB;IAAE,OAAO,CAAC,EAAE,CAAC,KAAK,EAAE,OAAO,QAAQ,KAAK,GAAG,CAAA;CAAE,GAC7C;IAAE,cAAc,CAAC,EAAE,CAAC,KAAK,EAAE,OAAO,QAAQ,KAAK,GAAG,CAAA;CAAE,CAAC;AA8BvD,QAAA,MAAM,eAAe;;;;;;;;;;;;;;;;;4EAInB,CAAC;wBACkB,eAAe,CAAC,OAAO,eAAe,EAAE,WAAW,CAAC;AAAzE,wBAA0E;AAY1E,KAAK,eAAe,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IAChC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
1
+ {"version":3,"file":"FdsModal.vue.d.ts","sourceRoot":"","sources":["../../../src/components/FdsModal/FdsModal.vue"],"names":[],"mappings":"AAyPA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,SAAS,CAAA;AA+U5C,QAAA,IAAI,QAAQ,IAAW,EAAE,QAAQ,IAAY,CAAE;AAC/C,KAAK,WAAW,GAAG,EAAE,GACnB;IAAE,OAAO,CAAC,EAAE,CAAC,KAAK,EAAE,OAAO,QAAQ,KAAK,GAAG,CAAA;CAAE,GAC7C;IAAE,cAAc,CAAC,EAAE,CAAC,KAAK,EAAE,OAAO,QAAQ,KAAK,GAAG,CAAA;CAAE,CAAC;AA+BvD,QAAA,MAAM,eAAe;;;;;;;;;;;;;;;;;4EAInB,CAAC;wBACkB,eAAe,CAAC,OAAO,eAAe,EAAE,WAAW,CAAC;AAAzE,wBAA0E;AAY1E,KAAK,eAAe,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IAChC,QAAO;QACN,MAAM,EAAE,CAAC,CAAC;KAEV,CAAA;CACD,CAAC"}
@@ -439,7 +439,7 @@ const _sfc_main$v = /* @__PURE__ */ vue.defineComponent({
439
439
  ]);
440
440
  const checkboxClasses = vue.computed(() => [
441
441
  "rounded-md transition-colors duration-200 accent-blue-500 m-[3px]",
442
- "peer z-40 bg-white min-w-[18px] min-h-[18px] focus-visible:outline-none",
442
+ "peer z-2 bg-white min-w-[18px] min-h-[18px] focus-visible:outline-none",
443
443
  props.disabled && "cursor-not-allowed"
444
444
  ]);
445
445
  const autoId = `fds-checkbox-${Math.random().toString(36).slice(2, 9)}`;
@@ -1174,7 +1174,7 @@ const _sfc_main$s = /* @__PURE__ */ vue.defineComponent({
1174
1174
  props.disabled && "hover:bg-transparent active:bg-transparent"
1175
1175
  ]);
1176
1176
  const inputClasses = vue.computed(() => [
1177
- "peer z-40 bg-white min-w-[18px] min-h-[18px] focus-visible:outline-none rounded-full accent-blue-500",
1177
+ "peer z-2 bg-white min-w-[18px] min-h-[18px] focus-visible:outline-none rounded-full accent-blue-500",
1178
1178
  props.disabled && "cursor-not-allowed"
1179
1179
  ]);
1180
1180
  return (_ctx, _cache) => {
@@ -3438,12 +3438,16 @@ const _sfc_main$5 = /* @__PURE__ */ vue.defineComponent({
3438
3438
  const slots = vue.useSlots();
3439
3439
  const isOpen = vue.ref(props.open);
3440
3440
  let cleanupFocusTrap = null;
3441
+ const hasFooter = vue.computed(() => !!slots["modal-footer"]);
3442
+ const modalOuterClasses = vue.computed(() => [
3443
+ "fixed top-0 left-0 w-full h-full overflow-auto z-100"
3444
+ ]);
3441
3445
  const modalInnerClasses = vue.computed(() => [
3442
- "fixed min-w-[288px] w-[calc(100%-5rem)] max-h-[80%] bg-white rounded-lg overflow-auto z-[99999] shadow-[0_16px_32px_rgba(12,72,153,0.12)] p-6",
3443
- "translate-x-[-50%]",
3446
+ "relative min-w-[288px] w-[calc(100%-5rem)] bg-white rounded-lg overflow-auto z-[99999] shadow-lg p-6 left-1/2",
3447
+ "top-1/2 translate-x-[-50%]",
3448
+ props.alignTop ? "max-h-[60%] top-[10rem]" : "max-h-[80%] translate-y-[-50%]",
3449
+ hasFooter.value ? "pb-0" : "",
3444
3450
  {
3445
- "left-1/2 top-1/2 translate-y-[-50%]": !props.alignTop,
3446
- "top-[10rem]": props.alignTop,
3447
3451
  "max-w-[480px]": props.size === "sm",
3448
3452
  "max-w-[588px]": props.size === "md",
3449
3453
  "max-w-[768px]": props.size === "lg",
@@ -3468,13 +3472,12 @@ const _sfc_main$5 = /* @__PURE__ */ vue.defineComponent({
3468
3472
  const closeLabel = vue.computed(
3469
3473
  () => props.locale === "sv" ? "Stäng dialogruta" : "Close modal window"
3470
3474
  );
3471
- const hasFooter = vue.computed(() => !!slots["modal-footer"]);
3472
3475
  const footerClasses = vue.computed(() => [
3473
3476
  "mt-6 flex flex-col gap-4 pb-8",
3474
3477
  {
3475
3478
  "sm:flex-row sm:justify-end": !props.alignLeftFooter,
3476
3479
  "sm:flex-row sm:justify-start": props.alignLeftFooter,
3477
- "sticky pt-4 pb-6 mt-4 bottom-0 bg-white shadow-[0px_-8px_16px_0px_rgba(255,255,255,0.59)] z-[2]": props.stickyFooter
3480
+ "sticky p-6 -mx-6 bg-white bottom-0 shadow-[0px_-8px_16px_0px_rgba(255,255,255,0.59)] z-[2]": props.stickyFooter
3478
3481
  }
3479
3482
  ]);
3480
3483
  const handleBackdropClick = () => {
@@ -3500,7 +3503,7 @@ const _sfc_main$5 = /* @__PURE__ */ vue.defineComponent({
3500
3503
  const trapFocus = () => {
3501
3504
  if (!isOpen.value) return;
3502
3505
  vue.nextTick(() => {
3503
- const modal = document.querySelector(".fds-modal__inner");
3506
+ const modal = document.querySelector(".fds-modal-inner");
3504
3507
  if (!modal) return;
3505
3508
  const tabList = getTabList(modal);
3506
3509
  if (tabList.length > 0) {
@@ -3565,12 +3568,12 @@ const _sfc_main$5 = /* @__PURE__ */ vue.defineComponent({
3565
3568
  return vue.openBlock(), vue.createBlock(vue.Teleport, { to: "body" }, [
3566
3569
  isOpen.value ? (vue.openBlock(), vue.createElementBlock("div", {
3567
3570
  key: 0,
3568
- class: "fixed top-0 left-0 w-full h-full overflow-auto z-100",
3569
- onClick: handleBackdropClick
3571
+ onClick: handleBackdropClick,
3572
+ class: vue.normalizeClass(modalOuterClasses.value)
3570
3573
  }, [
3571
3574
  _cache[2] || (_cache[2] = vue.createElementVNode("div", { class: "fixed top-0 left-0 w-full h-full bg-black/34 z-99" }, null, -1)),
3572
3575
  vue.createElementVNode("div", {
3573
- class: vue.normalizeClass(["fds-modal__inner", modalInnerClasses.value]),
3576
+ class: vue.normalizeClass(["fds-modal-inner", modalInnerClasses.value]),
3574
3577
  role: "alertdialog",
3575
3578
  "aria-modal": "true",
3576
3579
  onClick: _cache[1] || (_cache[1] = vue.withModifiers(() => {
@@ -3608,12 +3611,12 @@ const _sfc_main$5 = /* @__PURE__ */ vue.defineComponent({
3608
3611
  vue.renderSlot(_ctx.$slots, "modal-footer", {}, void 0, true)
3609
3612
  ], 2)) : vue.createCommentVNode("", true)
3610
3613
  ], 2)
3611
- ])) : vue.createCommentVNode("", true)
3614
+ ], 2)) : vue.createCommentVNode("", true)
3612
3615
  ]);
3613
3616
  };
3614
3617
  }
3615
3618
  });
3616
- const FdsModal = /* @__PURE__ */ _export_sfc(_sfc_main$5, [["__scopeId", "data-v-8b537fc0"]]);
3619
+ const FdsModal = /* @__PURE__ */ _export_sfc(_sfc_main$5, [["__scopeId", "data-v-9a84f324"]]);
3617
3620
  const _hoisted_1$3 = ["id"];
3618
3621
  const _hoisted_2$1 = { class: "flex items-center justify-start gap-1 w-[100px]" };
3619
3622
  const _hoisted_3 = { class: "flex items-center justify-center w-auto gap-2 order-0 sm:order-0" };