@fkui/vue 6.0.1 → 6.2.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.
@@ -4,7 +4,7 @@ const vue = require("vue");
4
4
  const logic = require("@fkui/logic");
5
5
  const date = require("@fkui/date");
6
6
  const statuses = ["default", "warning", "error", "success", "info"];
7
- const _sfc_main$1b = /* @__PURE__ */ vue.defineComponent({
7
+ const _sfc_main$1c = /* @__PURE__ */ vue.defineComponent({
8
8
  __name: "FBadge",
9
9
  props: {
10
10
  /**
@@ -766,8 +766,8 @@ function requireWeakMapBasicDetection() {
766
766
  hasRequiredWeakMapBasicDetection = 1;
767
767
  var globalThis2 = requireGlobalThis();
768
768
  var isCallable2 = requireIsCallable();
769
- var WeakMap = globalThis2.WeakMap;
770
- weakMapBasicDetection = isCallable2(WeakMap) && /native code/.test(String(WeakMap));
769
+ var WeakMap2 = globalThis2.WeakMap;
770
+ weakMapBasicDetection = isCallable2(WeakMap2) && /native code/.test(String(WeakMap2));
771
771
  return weakMapBasicDetection;
772
772
  }
773
773
  var sharedKey;
@@ -806,7 +806,7 @@ function requireInternalState() {
806
806
  var hiddenKeys2 = requireHiddenKeys();
807
807
  var OBJECT_ALREADY_INITIALIZED = "Object already initialized";
808
808
  var TypeError2 = globalThis2.TypeError;
809
- var WeakMap = globalThis2.WeakMap;
809
+ var WeakMap2 = globalThis2.WeakMap;
810
810
  var set, get, has;
811
811
  var enforce = function(it) {
812
812
  return has(it) ? get(it) : set(it, {});
@@ -821,7 +821,7 @@ function requireInternalState() {
821
821
  };
822
822
  };
823
823
  if (NATIVE_WEAK_MAP || shared2.state) {
824
- var store = shared2.state || (shared2.state = new WeakMap());
824
+ var store = shared2.state || (shared2.state = new WeakMap2());
825
825
  store.get = store.get;
826
826
  store.has = store.has;
827
827
  store.set = store.set;
@@ -1883,7 +1883,7 @@ function requireEs_array_push() {
1883
1883
  requireEs_array_push();
1884
1884
  const Flip = ["horizontal", "vertical"];
1885
1885
  const Rotate = ["90", "180", "270"];
1886
- const _sfc_main$1a = vue.defineComponent({
1886
+ const _sfc_main$1b = vue.defineComponent({
1887
1887
  name: "FIcon",
1888
1888
  inheritAttrs: false,
1889
1889
  props: {
@@ -1971,18 +1971,18 @@ const _export_sfc = (sfc, props) => {
1971
1971
  }
1972
1972
  return target;
1973
1973
  };
1974
- const _hoisted_1$U = ["aria-hidden"];
1974
+ const _hoisted_1$V = ["aria-hidden"];
1975
1975
  const _hoisted_2$F = ["xlink:href"];
1976
- function _sfc_render$W(_ctx, _cache, $props, $setup, $data, $options) {
1976
+ function _sfc_render$R(_ctx, _cache, $props, $setup, $data, $options) {
1977
1977
  return vue.openBlock(), vue.createElementBlock("svg", vue.mergeProps(_ctx.$attrs, {
1978
1978
  focusable: "false",
1979
1979
  class: ["icon", [_ctx.spriteKey, ..._ctx.modifiers]],
1980
1980
  "aria-hidden": _ctx.ariaHidden
1981
1981
  }), [vue.renderSlot(_ctx.$slots, "default"), _cache[0] || (_cache[0] = vue.createTextVNode()), vue.createElementVNode("use", {
1982
1982
  "xlink:href": _ctx.spriteId
1983
- }, null, 8, _hoisted_2$F)], 16, _hoisted_1$U);
1983
+ }, null, 8, _hoisted_2$F)], 16, _hoisted_1$V);
1984
1984
  }
1985
- const FIcon = /* @__PURE__ */ _export_sfc(_sfc_main$1a, [["render", _sfc_render$W]]);
1985
+ const FIcon = /* @__PURE__ */ _export_sfc(_sfc_main$1b, [["render", _sfc_render$R]]);
1986
1986
  const DATA_TEST_ATTRIBUTE_NAME = "data-test";
1987
1987
  function throwErrorIfEmpty(value) {
1988
1988
  if (!value) {
@@ -3873,8 +3873,8 @@ function require_WeakMap() {
3873
3873
  if (hasRequired_WeakMap) return _WeakMap;
3874
3874
  hasRequired_WeakMap = 1;
3875
3875
  var getNative = require_getNative(), root = require_root();
3876
- var WeakMap = getNative(root, "WeakMap");
3877
- _WeakMap = WeakMap;
3876
+ var WeakMap2 = getNative(root, "WeakMap");
3877
+ _WeakMap = WeakMap2;
3878
3878
  return _WeakMap;
3879
3879
  }
3880
3880
  var _getTag;
@@ -3882,12 +3882,12 @@ var hasRequired_getTag;
3882
3882
  function require_getTag() {
3883
3883
  if (hasRequired_getTag) return _getTag;
3884
3884
  hasRequired_getTag = 1;
3885
- var DataView2 = require_DataView(), Map2 = require_Map(), Promise2 = require_Promise(), Set = require_Set(), WeakMap = require_WeakMap(), baseGetTag = require_baseGetTag(), toSource = require_toSource();
3885
+ var DataView2 = require_DataView(), Map2 = require_Map(), Promise2 = require_Promise(), Set = require_Set(), WeakMap2 = require_WeakMap(), baseGetTag = require_baseGetTag(), toSource = require_toSource();
3886
3886
  var mapTag = "[object Map]", objectTag = "[object Object]", promiseTag = "[object Promise]", setTag = "[object Set]", weakMapTag = "[object WeakMap]";
3887
3887
  var dataViewTag = "[object DataView]";
3888
- var dataViewCtorString = toSource(DataView2), mapCtorString = toSource(Map2), promiseCtorString = toSource(Promise2), setCtorString = toSource(Set), weakMapCtorString = toSource(WeakMap);
3888
+ var dataViewCtorString = toSource(DataView2), mapCtorString = toSource(Map2), promiseCtorString = toSource(Promise2), setCtorString = toSource(Set), weakMapCtorString = toSource(WeakMap2);
3889
3889
  var getTag = baseGetTag;
3890
- if (DataView2 && getTag(new DataView2(new ArrayBuffer(1))) != dataViewTag || Map2 && getTag(new Map2()) != mapTag || Promise2 && getTag(Promise2.resolve()) != promiseTag || Set && getTag(new Set()) != setTag || WeakMap && getTag(new WeakMap()) != weakMapTag) {
3890
+ if (DataView2 && getTag(new DataView2(new ArrayBuffer(1))) != dataViewTag || Map2 && getTag(new Map2()) != mapTag || Promise2 && getTag(Promise2.resolve()) != promiseTag || Set && getTag(new Set()) != setTag || WeakMap2 && getTag(new WeakMap2()) != weakMapTag) {
3891
3891
  getTag = function(value) {
3892
3892
  var result = baseGetTag(value), Ctor = result == objectTag ? value.constructor : void 0, ctorString = Ctor ? toSource(Ctor) : "";
3893
3893
  if (ctorString) {
@@ -4420,7 +4420,7 @@ function elementIsRadioButton(element) {
4420
4420
  function isHTMLInputElement(element) {
4421
4421
  return element instanceof HTMLInputElement;
4422
4422
  }
4423
- const _sfc_main$19 = vue.defineComponent({
4423
+ const _sfc_main$1a = vue.defineComponent({
4424
4424
  name: "FModal",
4425
4425
  components: {
4426
4426
  FIcon
@@ -4600,7 +4600,7 @@ const _sfc_main$19 = vue.defineComponent({
4600
4600
  }
4601
4601
  }
4602
4602
  });
4603
- const _hoisted_1$T = ["id"];
4603
+ const _hoisted_1$U = ["id"];
4604
4604
  const _hoisted_2$E = {
4605
4605
  class: "modal__backdrop"
4606
4606
  };
@@ -4634,7 +4634,7 @@ const _hoisted_10$4 = {
4634
4634
  class: "modal__shelf"
4635
4635
  };
4636
4636
  const _hoisted_11$3 = ["aria-label"];
4637
- function _sfc_render$V(_ctx, _cache, $props, $setup, $data, $options) {
4637
+ function _sfc_render$Q(_ctx, _cache, $props, $setup, $data, $options) {
4638
4638
  const _component_f_icon = vue.resolveComponent("f-icon");
4639
4639
  return _ctx.isOpen ? (vue.openBlock(), vue.createElementBlock("div", {
4640
4640
  key: 0,
@@ -4662,9 +4662,9 @@ function _sfc_render$V(_ctx, _cache, $props, $setup, $data, $options) {
4662
4662
  })], 8, _hoisted_11$3), _cache[8] || (_cache[8] = vue.createTextVNode()), vue.createElementVNode("div", {
4663
4663
  tabindex: "0",
4664
4664
  onFocus: _cache[2] || (_cache[2] = (...args) => _ctx.onFocusLast && _ctx.onFocusLast(...args))
4665
- }, null, 32)])])], 2)])], 32)])], 10, _hoisted_1$T)) : vue.createCommentVNode("", true);
4665
+ }, null, 32)])])], 2)])], 32)])], 10, _hoisted_1$U)) : vue.createCommentVNode("", true);
4666
4666
  }
4667
- const FModal = /* @__PURE__ */ _export_sfc(_sfc_main$19, [["render", _sfc_render$V]]);
4667
+ const FModal = /* @__PURE__ */ _export_sfc(_sfc_main$1a, [["render", _sfc_render$Q]]);
4668
4668
  function prepareButtonList(src, buttonOrder = config.buttonOrder) {
4669
4669
  const list = src.map((it) => {
4670
4670
  var _it$event, _ref, _it$reason, _it$type;
@@ -4693,7 +4693,7 @@ const defaultButtons = [{
4693
4693
  event: "dismiss",
4694
4694
  type: "secondary"
4695
4695
  }];
4696
- const _sfc_main$18 = vue.defineComponent({
4696
+ const _sfc_main$19 = vue.defineComponent({
4697
4697
  name: "FConfirmModal",
4698
4698
  components: {
4699
4699
  FModal
@@ -4797,7 +4797,7 @@ const _sfc_main$18 = vue.defineComponent({
4797
4797
  }
4798
4798
  }
4799
4799
  });
4800
- const _hoisted_1$S = {
4800
+ const _hoisted_1$T = {
4801
4801
  class: "button-group"
4802
4802
  };
4803
4803
  const _hoisted_2$D = ["onClick"];
@@ -4805,7 +4805,7 @@ const _hoisted_3$v = {
4805
4805
  key: 0,
4806
4806
  class: "sr-only"
4807
4807
  };
4808
- function _sfc_render$U(_ctx, _cache, $props, $setup, $data, $options) {
4808
+ function _sfc_render$P(_ctx, _cache, $props, $setup, $data, $options) {
4809
4809
  const _component_f_modal = vue.resolveComponent("f-modal");
4810
4810
  return vue.openBlock(), vue.createBlock(_component_f_modal, {
4811
4811
  fullscreen: _ctx.fullscreen,
@@ -4818,7 +4818,7 @@ function _sfc_render$U(_ctx, _cache, $props, $setup, $data, $options) {
4818
4818
  }, {
4819
4819
  header: vue.withCtx(() => [vue.renderSlot(_ctx.$slots, "heading", {}, () => [vue.createTextVNode(vue.toDisplayString(_ctx.heading), 1)])]),
4820
4820
  content: vue.withCtx(() => [vue.renderSlot(_ctx.$slots, "content", {}, () => [vue.createTextVNode(vue.toDisplayString(_ctx.content), 1)])]),
4821
- footer: vue.withCtx(() => [vue.createElementVNode("div", _hoisted_1$S, [(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(_ctx.preparedButtons, (button) => {
4821
+ footer: vue.withCtx(() => [vue.createElementVNode("div", _hoisted_1$T, [(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(_ctx.preparedButtons, (button) => {
4822
4822
  return vue.openBlock(), vue.createElementBlock("button", {
4823
4823
  key: button.label,
4824
4824
  type: "button",
@@ -4829,11 +4829,11 @@ function _sfc_render$U(_ctx, _cache, $props, $setup, $data, $options) {
4829
4829
  _: 3
4830
4830
  }, 8, ["fullscreen", "is-open", "aria-close-text", "size", "focus", "onClose"]);
4831
4831
  }
4832
- const FConfirmModal = /* @__PURE__ */ _export_sfc(_sfc_main$18, [["render", _sfc_render$U]]);
4832
+ const FConfirmModal = /* @__PURE__ */ _export_sfc(_sfc_main$19, [["render", _sfc_render$P]]);
4833
4833
  const GAP = ["1x", "2x", "3x", "4x", "5x", "6x", "7x", "8x"];
4834
4834
  const ALIGNMENT = ["top", "center", "bottom"];
4835
4835
  const FLOAT = ["left", "center", "right"];
4836
- const _sfc_main$17 = vue.defineComponent({
4836
+ const _sfc_main$18 = vue.defineComponent({
4837
4837
  name: "IFlex",
4838
4838
  inheritAttrs: true,
4839
4839
  props: {
@@ -4908,13 +4908,13 @@ const _sfc_main$17 = vue.defineComponent({
4908
4908
  }
4909
4909
  }
4910
4910
  });
4911
- function _sfc_render$T(_ctx, _cache, $props, $setup, $data, $options) {
4911
+ function _sfc_render$O(_ctx, _cache, $props, $setup, $data, $options) {
4912
4912
  return vue.openBlock(), vue.createElementBlock("div", {
4913
4913
  class: vue.normalizeClass(["iflex", _ctx.classList])
4914
4914
  }, [vue.renderSlot(_ctx.$slots, "default")], 2);
4915
4915
  }
4916
- const IFlex = /* @__PURE__ */ _export_sfc(_sfc_main$17, [["render", _sfc_render$T]]);
4917
- const _sfc_main$16 = vue.defineComponent({
4916
+ const IFlex = /* @__PURE__ */ _export_sfc(_sfc_main$18, [["render", _sfc_render$O]]);
4917
+ const _sfc_main$17 = vue.defineComponent({
4918
4918
  name: "IFlexItem",
4919
4919
  inheritAttrs: true,
4920
4920
  props: {
@@ -4961,12 +4961,12 @@ const _sfc_main$16 = vue.defineComponent({
4961
4961
  }
4962
4962
  }
4963
4963
  });
4964
- function _sfc_render$S(_ctx, _cache, $props, $setup, $data, $options) {
4964
+ function _sfc_render$N(_ctx, _cache, $props, $setup, $data, $options) {
4965
4965
  return vue.openBlock(), vue.createElementBlock("div", {
4966
4966
  class: vue.normalizeClass(["iflex__item", _ctx.classList])
4967
4967
  }, [vue.renderSlot(_ctx.$slots, "default")], 2);
4968
4968
  }
4969
- const IFlexItem = /* @__PURE__ */ _export_sfc(_sfc_main$16, [["render", _sfc_render$S]]);
4969
+ const IFlexItem = /* @__PURE__ */ _export_sfc(_sfc_main$17, [["render", _sfc_render$N]]);
4970
4970
  function focusError(item) {
4971
4971
  const element = document.querySelector(`#${item.id}`);
4972
4972
  if (!element) {
@@ -4976,7 +4976,7 @@ function focusError(item) {
4976
4976
  logic.scrollTo(element, window.innerHeight * 0.25);
4977
4977
  logic.focus(focusElement2 ? focusElement2 : element);
4978
4978
  }
4979
- const _sfc_main$15 = vue.defineComponent({
4979
+ const _sfc_main$16 = vue.defineComponent({
4980
4980
  name: "FErrorList",
4981
4981
  components: {
4982
4982
  FIcon,
@@ -5032,7 +5032,7 @@ const _sfc_main$15 = vue.defineComponent({
5032
5032
  }
5033
5033
  }
5034
5034
  });
5035
- const _hoisted_1$R = {
5035
+ const _hoisted_1$S = {
5036
5036
  class: "error-list"
5037
5037
  };
5038
5038
  const _hoisted_2$C = {
@@ -5045,11 +5045,11 @@ const _hoisted_4$p = ["onClick"];
5045
5045
  const _hoisted_5$k = {
5046
5046
  class: "error-list__link"
5047
5047
  };
5048
- function _sfc_render$R(_ctx, _cache, $props, $setup, $data, $options) {
5048
+ function _sfc_render$M(_ctx, _cache, $props, $setup, $data, $options) {
5049
5049
  const _component_f_icon = vue.resolveComponent("f-icon");
5050
5050
  const _component_i_flex_item = vue.resolveComponent("i-flex-item");
5051
5051
  const _component_i_flex = vue.resolveComponent("i-flex");
5052
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$R, [vue.createVNode(_component_i_flex, null, {
5052
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$S, [vue.createVNode(_component_i_flex, null, {
5053
5053
  default: vue.withCtx(() => [_ctx.hasTitleSlot ? (vue.openBlock(), vue.createBlock(_component_i_flex_item, {
5054
5054
  key: 0,
5055
5055
  shrink: ""
@@ -5099,7 +5099,7 @@ function _sfc_render$R(_ctx, _cache, $props, $setup, $data, $options) {
5099
5099
  _: 3
5100
5100
  })]);
5101
5101
  }
5102
- const FErrorList = /* @__PURE__ */ _export_sfc(_sfc_main$15, [["render", _sfc_render$R]]);
5102
+ const FErrorList = /* @__PURE__ */ _export_sfc(_sfc_main$16, [["render", _sfc_render$M]]);
5103
5103
  var es_iterator_every = {};
5104
5104
  var hasRequiredEs_iterator_every;
5105
5105
  function requireEs_iterator_every() {
@@ -5187,7 +5187,7 @@ function cleanUpElements(vm) {
5187
5187
  }, 0);
5188
5188
  });
5189
5189
  }
5190
- const _sfc_main$14 = vue.defineComponent({
5190
+ const _sfc_main$15 = vue.defineComponent({
5191
5191
  name: "FValidationGroup",
5192
5192
  props: {
5193
5193
  /**
@@ -5257,19 +5257,19 @@ const _sfc_main$14 = vue.defineComponent({
5257
5257
  }
5258
5258
  }
5259
5259
  });
5260
- function _sfc_render$Q(_ctx, _cache, $props, $setup, $data, $options) {
5260
+ function _sfc_render$L(_ctx, _cache, $props, $setup, $data, $options) {
5261
5261
  return vue.openBlock(), vue.createElementBlock("div", {
5262
5262
  onComponentValidity: _cache[0] || (_cache[0] = (...args) => _ctx.onComponentValidity && _ctx.onComponentValidity(...args)),
5263
5263
  onComponentUnmount: _cache[1] || (_cache[1] = (...args) => _ctx.onComponentUnmount && _ctx.onComponentUnmount(...args))
5264
5264
  }, [vue.renderSlot(_ctx.$slots, "default")], 32);
5265
5265
  }
5266
- const FValidationGroup = /* @__PURE__ */ _export_sfc(_sfc_main$14, [["render", _sfc_render$Q]]);
5266
+ const FValidationGroup = /* @__PURE__ */ _export_sfc(_sfc_main$15, [["render", _sfc_render$L]]);
5267
5267
  var FValidationFormAction = /* @__PURE__ */ ((FValidationFormAction2) => {
5268
5268
  FValidationFormAction2[FValidationFormAction2["CONTINUE"] = 0] = "CONTINUE";
5269
5269
  FValidationFormAction2[FValidationFormAction2["CANCEL"] = 1] = "CANCEL";
5270
5270
  return FValidationFormAction2;
5271
5271
  })(FValidationFormAction || {});
5272
- const _sfc_main$13 = vue.defineComponent({
5272
+ const _sfc_main$14 = vue.defineComponent({
5273
5273
  name: "FValidationForm",
5274
5274
  components: {
5275
5275
  FValidationGroup,
@@ -5408,14 +5408,14 @@ const _sfc_main$13 = vue.defineComponent({
5408
5408
  }
5409
5409
  }
5410
5410
  });
5411
- const _hoisted_1$Q = ["id"];
5411
+ const _hoisted_1$R = ["id"];
5412
5412
  const _hoisted_2$B = {
5413
5413
  key: 0,
5414
5414
  ref: "errors",
5415
5415
  tabindex: "-1",
5416
5416
  role: "group"
5417
5417
  };
5418
- function _sfc_render$P(_ctx, _cache, $props, $setup, $data, $options) {
5418
+ function _sfc_render$K(_ctx, _cache, $props, $setup, $data, $options) {
5419
5419
  const _component_f_error_list = vue.resolveComponent("f-error-list");
5420
5420
  const _component_f_validation_group = vue.resolveComponent("f-validation-group");
5421
5421
  return vue.openBlock(), vue.createBlock(_component_f_validation_group, {
@@ -5437,12 +5437,12 @@ function _sfc_render$P(_ctx, _cache, $props, $setup, $data, $options) {
5437
5437
  }, {
5438
5438
  title: vue.withCtx(() => [vue.renderSlot(_ctx.$slots, "error-message")]),
5439
5439
  _: 3
5440
- }, 8, ["items", "bullets", "before-navigate"])], 512)) : vue.createCommentVNode("", true), _cache[2] || (_cache[2] = vue.createTextVNode()), vue.renderSlot(_ctx.$slots, "default")], 16, _hoisted_1$Q)]),
5440
+ }, 8, ["items", "bullets", "before-navigate"])], 512)) : vue.createCommentVNode("", true), _cache[2] || (_cache[2] = vue.createTextVNode()), vue.renderSlot(_ctx.$slots, "default")], 16, _hoisted_1$R)]),
5441
5441
  _: 3
5442
5442
  }, 8, ["modelValue"]);
5443
5443
  }
5444
- const FValidationForm = /* @__PURE__ */ _export_sfc(_sfc_main$13, [["render", _sfc_render$P]]);
5445
- const _sfc_main$12 = vue.defineComponent({
5444
+ const FValidationForm = /* @__PURE__ */ _export_sfc(_sfc_main$14, [["render", _sfc_render$K]]);
5445
+ const _sfc_main$13 = vue.defineComponent({
5446
5446
  name: "FFormModal",
5447
5447
  components: {
5448
5448
  FModal,
@@ -5591,7 +5591,7 @@ const _sfc_main$12 = vue.defineComponent({
5591
5591
  }
5592
5592
  }
5593
5593
  });
5594
- const _hoisted_1$P = {
5594
+ const _hoisted_1$Q = {
5595
5595
  class: "button-group"
5596
5596
  };
5597
5597
  const _hoisted_2$A = ["type", "form", "onClick"];
@@ -5599,7 +5599,7 @@ const _hoisted_3$t = {
5599
5599
  key: 0,
5600
5600
  class: "sr-only"
5601
5601
  };
5602
- function _sfc_render$O(_ctx, _cache, $props, $setup, $data, $options) {
5602
+ function _sfc_render$J(_ctx, _cache, $props, $setup, $data, $options) {
5603
5603
  const _component_f_validation_form = vue.resolveComponent("f-validation-form");
5604
5604
  const _component_f_modal = vue.resolveComponent("f-modal");
5605
5605
  return vue.openBlock(), vue.createBlock(_component_f_modal, {
@@ -5623,7 +5623,7 @@ function _sfc_render$O(_ctx, _cache, $props, $setup, $data, $options) {
5623
5623
  default: vue.withCtx(() => [_cache[0] || (_cache[0] = vue.createTextVNode()), vue.renderSlot(_ctx.$slots, "input-text-fields")]),
5624
5624
  _: 3
5625
5625
  }, 8, ["id", "before-submit", "before-validation", "use-error-list", "onSubmit", "onCancel"])]),
5626
- footer: vue.withCtx(() => [vue.createElementVNode("div", _hoisted_1$P, [(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(_ctx.preparedButtons, (button) => {
5626
+ footer: vue.withCtx(() => [vue.createElementVNode("div", _hoisted_1$Q, [(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(_ctx.preparedButtons, (button) => {
5627
5627
  return vue.openBlock(), vue.createElementBlock("button", {
5628
5628
  key: button.label,
5629
5629
  type: button.buttonType,
@@ -5635,7 +5635,7 @@ function _sfc_render$O(_ctx, _cache, $props, $setup, $data, $options) {
5635
5635
  _: 3
5636
5636
  }, 8, ["data-test", "fullscreen", "is-open", "size", "aria-close-text", "onClose"]);
5637
5637
  }
5638
- const FFormModal = /* @__PURE__ */ _export_sfc(_sfc_main$12, [["render", _sfc_render$O]]);
5638
+ const FFormModal = /* @__PURE__ */ _export_sfc(_sfc_main$13, [["render", _sfc_render$J]]);
5639
5639
  async function confirmModal(callingInstance, texts) {
5640
5640
  const buttons = [{
5641
5641
  label: texts.confirm,
@@ -5995,7 +5995,7 @@ const ErrorPlugin = {
5995
5995
  }
5996
5996
  }
5997
5997
  };
5998
- const _sfc_main$11 = vue.defineComponent({
5998
+ const _sfc_main$12 = vue.defineComponent({
5999
5999
  name: "FErrorPage",
6000
6000
  props: {
6001
6001
  payload: {
@@ -6005,16 +6005,16 @@ const _sfc_main$11 = vue.defineComponent({
6005
6005
  }
6006
6006
  }
6007
6007
  });
6008
- const _hoisted_1$O = {
6008
+ const _hoisted_1$P = {
6009
6009
  "data-test": "f-error-page"
6010
6010
  };
6011
- function _sfc_render$N(_ctx, _cache, $props, $setup, $data, $options) {
6012
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$O, _cache[0] || (_cache[0] = [vue.createElementVNode("h1", null, "Fel", -1), vue.createTextVNode(), vue.createElementVNode("p", null, "Ett fel har uppstått.", -1), vue.createTextVNode(), vue.createElementVNode("a", {
6011
+ function _sfc_render$I(_ctx, _cache, $props, $setup, $data, $options) {
6012
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$P, _cache[0] || (_cache[0] = [vue.createElementVNode("h1", null, "Fel", -1), vue.createTextVNode(), vue.createElementVNode("p", null, "Ett fel har uppstått.", -1), vue.createTextVNode(), vue.createElementVNode("a", {
6013
6013
  href: "/"
6014
6014
  }, "Gå till startsidan", -1)]));
6015
6015
  }
6016
- const FErrorPage = /* @__PURE__ */ _export_sfc(_sfc_main$11, [["render", _sfc_render$N]]);
6017
- const _sfc_main$10 = vue.defineComponent({
6016
+ const FErrorPage = /* @__PURE__ */ _export_sfc(_sfc_main$12, [["render", _sfc_render$I]]);
6017
+ const _sfc_main$11 = vue.defineComponent({
6018
6018
  name: "FErrorHandlingApp",
6019
6019
  props: {
6020
6020
  defaultComponent: {
@@ -6043,7 +6043,7 @@ const _sfc_main$10 = vue.defineComponent({
6043
6043
  });
6044
6044
  }
6045
6045
  });
6046
- function _sfc_render$M(_ctx, _cache, $props, $setup, $data, $options) {
6046
+ function _sfc_render$H(_ctx, _cache, $props, $setup, $data, $options) {
6047
6047
  return vue.openBlock(), vue.createElementBlock("div", null, [_ctx.hasError ? (vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(_ctx.errorComponent), {
6048
6048
  key: 0,
6049
6049
  payload: _ctx.payload
@@ -6053,7 +6053,7 @@ function _sfc_render$M(_ctx, _cache, $props, $setup, $data, $options) {
6053
6053
  key: 2
6054
6054
  })]);
6055
6055
  }
6056
- const FErrorHandlingApp = /* @__PURE__ */ _export_sfc(_sfc_main$10, [["render", _sfc_render$M]]);
6056
+ const FErrorHandlingApp = /* @__PURE__ */ _export_sfc(_sfc_main$11, [["render", _sfc_render$H]]);
6057
6057
  function isMonthBefore(date2, minDate) {
6058
6058
  return Boolean(minDate && date2.isBefore(minDate.startOfMonth()));
6059
6059
  }
@@ -6094,7 +6094,7 @@ function getMessage($t2, date2, minDate, maxDate) {
6094
6094
  });
6095
6095
  }
6096
6096
  }
6097
- const _sfc_main$$ = vue.defineComponent({
6097
+ const _sfc_main$10 = vue.defineComponent({
6098
6098
  name: "ICalendarNavbar",
6099
6099
  components: {
6100
6100
  FIcon
@@ -6207,7 +6207,7 @@ const _sfc_main$$ = vue.defineComponent({
6207
6207
  }
6208
6208
  }
6209
6209
  });
6210
- const _hoisted_1$N = {
6210
+ const _hoisted_1$O = {
6211
6211
  class: "calendar-navbar"
6212
6212
  };
6213
6213
  const _hoisted_2$z = {
@@ -6222,9 +6222,9 @@ const _hoisted_5$j = ["aria-disabled", "aria-live"];
6222
6222
  const _hoisted_6$f = {
6223
6223
  class: "sr-only"
6224
6224
  };
6225
- function _sfc_render$L(_ctx, _cache, $props, $setup, $data, $options) {
6225
+ function _sfc_render$G(_ctx, _cache, $props, $setup, $data, $options) {
6226
6226
  const _component_f_icon = vue.resolveComponent("f-icon");
6227
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$N, [vue.createElementVNode("div", _hoisted_2$z, vue.toDisplayString(_ctx.currentText), 1), _cache[4] || (_cache[4] = vue.createTextVNode()), vue.createElementVNode("button", {
6227
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$O, [vue.createElementVNode("div", _hoisted_2$z, vue.toDisplayString(_ctx.currentText), 1), _cache[4] || (_cache[4] = vue.createTextVNode()), vue.createElementVNode("button", {
6228
6228
  ref: "previousButton",
6229
6229
  class: "calendar-navbar__arrow calendar-navbar__arrow--previous",
6230
6230
  type: "button",
@@ -6246,14 +6246,14 @@ function _sfc_render$L(_ctx, _cache, $props, $setup, $data, $options) {
6246
6246
  name: "arrow-right"
6247
6247
  }, null, 8, ["class"])], 8, _hoisted_5$j)]);
6248
6248
  }
6249
- const ICalendarNavbar = /* @__PURE__ */ _export_sfc(_sfc_main$$, [["render", _sfc_render$L]]);
6249
+ const ICalendarNavbar = /* @__PURE__ */ _export_sfc(_sfc_main$10, [["render", _sfc_render$G]]);
6250
6250
  function getDayStartOffset(days) {
6251
6251
  return days[0].weekDay - 1;
6252
6252
  }
6253
6253
  function getDayEndOffset(days) {
6254
6254
  return 7 - days[days.length - 1].weekDay;
6255
6255
  }
6256
- const _sfc_main$_ = vue.defineComponent({
6256
+ const _sfc_main$$ = vue.defineComponent({
6257
6257
  name: "ICalendarMonthGrid",
6258
6258
  props: {
6259
6259
  /**
@@ -6327,7 +6327,7 @@ const _sfc_main$_ = vue.defineComponent({
6327
6327
  }
6328
6328
  }
6329
6329
  });
6330
- const _hoisted_1$M = ["aria-label"];
6330
+ const _hoisted_1$N = ["aria-label"];
6331
6331
  const _hoisted_2$y = {
6332
6332
  key: 0,
6333
6333
  class: "calendar-month__col--week"
@@ -6340,23 +6340,26 @@ const _hoisted_3$r = {
6340
6340
  };
6341
6341
  const _hoisted_4$n = ["title"];
6342
6342
  const _hoisted_5$i = {
6343
+ key: 1
6344
+ };
6345
+ const _hoisted_6$e = {
6343
6346
  key: 0,
6344
6347
  class: "calendar-month__cell calendar-month__cell--week-number",
6345
6348
  "aria-hidden": "true"
6346
6349
  };
6347
- const _hoisted_6$e = ["colspan"];
6348
6350
  const _hoisted_7$c = ["colspan"];
6349
- const _hoisted_8$7 = {
6351
+ const _hoisted_8$7 = ["colspan"];
6352
+ const _hoisted_9$5 = {
6350
6353
  key: 0,
6351
6354
  "aria-hidden": "true"
6352
6355
  };
6353
- const _hoisted_9$5 = ["colspan"];
6354
- const _hoisted_10$3 = {
6356
+ const _hoisted_10$3 = ["colspan"];
6357
+ const _hoisted_11$2 = {
6355
6358
  key: 1,
6356
6359
  "aria-hidden": "true"
6357
6360
  };
6358
- const _hoisted_11$2 = ["colspan"];
6359
- function _sfc_render$K(_ctx, _cache, $props, $setup, $data, $options) {
6361
+ const _hoisted_12$2 = ["colspan"];
6362
+ function _sfc_render$F(_ctx, _cache, $props, $setup, $data, $options) {
6360
6363
  return vue.openBlock(), vue.createElementBlock("table", {
6361
6364
  class: "calendar-month__table",
6362
6365
  role: "grid",
@@ -6381,19 +6384,20 @@ function _sfc_render$K(_ctx, _cache, $props, $setup, $data, $options) {
6381
6384
  return vue.openBlock(), vue.createElementBlock("th", {
6382
6385
  key: weekday.name,
6383
6386
  scope: "col",
6387
+ "aria-hidden": "true",
6384
6388
  class: "calendar-month__header-cell"
6385
- }, [vue.createElementVNode("abbr", {
6389
+ }, [_ctx.showShortWeekdays ? (vue.openBlock(), vue.createElementBlock("abbr", {
6390
+ key: 0,
6386
6391
  title: weekday.name
6387
- }, vue.toDisplayString(_ctx.showShortWeekdays ? weekday.shortName : weekday.name), 9, _hoisted_4$n)]);
6392
+ }, vue.toDisplayString(weekday.shortName), 9, _hoisted_4$n)) : (vue.openBlock(), vue.createElementBlock("span", _hoisted_5$i, vue.toDisplayString(weekday.name), 1))]);
6388
6393
  }), 128))])]), _cache[23] || (_cache[23] = vue.createTextVNode()), vue.createElementVNode("tbody", null, [(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(_ctx.weeks, (week) => {
6389
6394
  return vue.openBlock(), vue.createElementBlock("tr", {
6390
6395
  key: week.week
6391
- }, [!_ctx.internalHideWeekNumbers ? (vue.openBlock(), vue.createElementBlock("td", _hoisted_5$i, vue.toDisplayString(week.week), 1)) : vue.createCommentVNode("", true), _cache[17] || (_cache[17] = vue.createTextVNode()), _ctx.getDayStartOffset(week.days) ? (vue.openBlock(), vue.createElementBlock("td", {
6396
+ }, [!_ctx.internalHideWeekNumbers ? (vue.openBlock(), vue.createElementBlock("td", _hoisted_6$e, vue.toDisplayString(week.week), 1)) : vue.createCommentVNode("", true), _cache[17] || (_cache[17] = vue.createTextVNode()), _ctx.getDayStartOffset(week.days) ? (vue.openBlock(), vue.createElementBlock("td", {
6392
6397
  key: 1,
6393
6398
  class: "calendar-month__cell",
6394
- colspan: _ctx.getDayStartOffset(week.days),
6395
- "aria-hidden": "true"
6396
- }, null, 8, _hoisted_6$e)) : vue.createCommentVNode("", true), _cache[18] || (_cache[18] = vue.createTextVNode()), (vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(week.days, (day) => {
6399
+ colspan: _ctx.getDayStartOffset(week.days)
6400
+ }, null, 8, _hoisted_7$c)) : vue.createCommentVNode("", true), _cache[18] || (_cache[18] = vue.createTextVNode()), (vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(week.days, (day) => {
6397
6401
  return vue.openBlock(), vue.createElementBlock("td", {
6398
6402
  key: day.toString(),
6399
6403
  class: "calendar-month__cell",
@@ -6407,18 +6411,18 @@ function _sfc_render$K(_ctx, _cache, $props, $setup, $data, $options) {
6407
6411
  class: "calendar-month__cell",
6408
6412
  colspan: _ctx.getDayEndOffset(week.days),
6409
6413
  "aria-hidden": "true"
6410
- }, null, 8, _hoisted_7$c)) : vue.createCommentVNode("", true)]);
6411
- }), 128)), _cache[20] || (_cache[20] = vue.createTextVNode()), _ctx.weeks.length < 5 ? (vue.openBlock(), vue.createElementBlock("tr", _hoisted_8$7, [vue.createElementVNode("td", {
6414
+ }, null, 8, _hoisted_8$7)) : vue.createCommentVNode("", true)]);
6415
+ }), 128)), _cache[20] || (_cache[20] = vue.createTextVNode()), _ctx.weeks.length < 5 ? (vue.openBlock(), vue.createElementBlock("tr", _hoisted_9$5, [vue.createElementVNode("td", {
6412
6416
  class: "calendar-month__cell",
6413
6417
  colspan: _ctx.totalCols,
6414
6418
  "aria-hidden": "true"
6415
- }, null, 8, _hoisted_9$5)])) : vue.createCommentVNode("", true), _cache[21] || (_cache[21] = vue.createTextVNode()), _ctx.weeks.length < 6 ? (vue.openBlock(), vue.createElementBlock("tr", _hoisted_10$3, [vue.createElementVNode("td", {
6419
+ }, null, 8, _hoisted_10$3)])) : vue.createCommentVNode("", true), _cache[21] || (_cache[21] = vue.createTextVNode()), _ctx.weeks.length < 6 ? (vue.openBlock(), vue.createElementBlock("tr", _hoisted_11$2, [vue.createElementVNode("td", {
6416
6420
  class: "calendar-month__cell",
6417
6421
  colspan: _ctx.totalCols,
6418
6422
  "aria-hidden": "true"
6419
- }, null, 8, _hoisted_11$2)])) : vue.createCommentVNode("", true)])], 40, _hoisted_1$M);
6423
+ }, null, 8, _hoisted_12$2)])) : vue.createCommentVNode("", true)])], 40, _hoisted_1$N);
6420
6424
  }
6421
- const ICalendarMonthGrid = /* @__PURE__ */ _export_sfc(_sfc_main$_, [["render", _sfc_render$K]]);
6425
+ const ICalendarMonthGrid = /* @__PURE__ */ _export_sfc(_sfc_main$$, [["render", _sfc_render$F]]);
6422
6426
  const DayStep = {
6423
6427
  ArrowRight: 1,
6424
6428
  ArrowLeft: -1,
@@ -6442,7 +6446,7 @@ function getDayTabindex(date2, active, entry) {
6442
6446
  return date2.day === 1 ? 0 : -1;
6443
6447
  }
6444
6448
  }
6445
- const _sfc_main$Z = vue.defineComponent({
6449
+ const _sfc_main$_ = vue.defineComponent({
6446
6450
  name: "ICalendarMonth",
6447
6451
  components: {
6448
6452
  ICalendarMonthGrid
@@ -6532,8 +6536,8 @@ const _sfc_main$Z = vue.defineComponent({
6532
6536
  }
6533
6537
  }
6534
6538
  });
6535
- const _hoisted_1$L = ["data-date", "tabindex", "onClick", "onKeydown"];
6536
- function _sfc_render$J(_ctx, _cache, $props, $setup, $data, $options) {
6539
+ const _hoisted_1$M = ["data-date", "tabindex", "onClick", "onKeydown"];
6540
+ function _sfc_render$E(_ctx, _cache, $props, $setup, $data, $options) {
6537
6541
  const _component_i_calendar_month_grid = vue.resolveComponent("i-calendar-month-grid");
6538
6542
  return vue.openBlock(), vue.createBlock(_component_i_calendar_month_grid, {
6539
6543
  value: _ctx.modelValue
@@ -6552,12 +6556,12 @@ function _sfc_render$J(_ctx, _cache, $props, $setup, $data, $options) {
6552
6556
  }, [vue.renderSlot(_ctx.$slots, "default", {
6553
6557
  date: date2,
6554
6558
  isFocused: _ctx.isDayFocused(date2)
6555
- })], 40, _hoisted_1$L)]),
6559
+ })], 40, _hoisted_1$M)]),
6556
6560
  _: 3
6557
6561
  }, 8, ["value"]);
6558
6562
  }
6559
- const ICalendarMonth = /* @__PURE__ */ _export_sfc(_sfc_main$Z, [["render", _sfc_render$J]]);
6560
- const _sfc_main$Y = vue.defineComponent({
6563
+ const ICalendarMonth = /* @__PURE__ */ _export_sfc(_sfc_main$_, [["render", _sfc_render$E]]);
6564
+ const _sfc_main$Z = vue.defineComponent({
6561
6565
  name: "FCalendar",
6562
6566
  components: {
6563
6567
  ICalendarNavbar,
@@ -6608,13 +6612,13 @@ const _sfc_main$Y = vue.defineComponent({
6608
6612
  }
6609
6613
  }
6610
6614
  });
6611
- const _hoisted_1$K = {
6615
+ const _hoisted_1$L = {
6612
6616
  class: "calendar__wrapper"
6613
6617
  };
6614
- function _sfc_render$I(_ctx, _cache, $props, $setup, $data, $options) {
6618
+ function _sfc_render$D(_ctx, _cache, $props, $setup, $data, $options) {
6615
6619
  const _component_i_calendar_navbar = vue.resolveComponent("i-calendar-navbar");
6616
6620
  const _component_i_calendar_month = vue.resolveComponent("i-calendar-month");
6617
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$K, [vue.createVNode(_component_i_calendar_navbar, {
6621
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$L, [vue.createVNode(_component_i_calendar_navbar, {
6618
6622
  "model-value": _ctx.modelValue,
6619
6623
  "min-date": _ctx.minDate,
6620
6624
  "max-date": _ctx.maxDate,
@@ -6637,7 +6641,7 @@ function _sfc_render$I(_ctx, _cache, $props, $setup, $data, $options) {
6637
6641
  _: 3
6638
6642
  }, 8, ["model-value", "min-date", "max-date", "tab-date", "onClick", "onUpdate:modelValue"])]);
6639
6643
  }
6640
- const FCalendar = /* @__PURE__ */ _export_sfc(_sfc_main$Y, [["render", _sfc_render$I]]);
6644
+ const FCalendar = /* @__PURE__ */ _export_sfc(_sfc_main$Z, [["render", _sfc_render$D]]);
6641
6645
  function getCalendarDaySrText(day, enabled, selected, t) {
6642
6646
  const parts = [];
6643
6647
  if (!enabled) {
@@ -6656,7 +6660,7 @@ function getCalendarDaySrText(day, enabled, selected, t) {
6656
6660
  parts.push(day.toString(date.DateFormat.FULL));
6657
6661
  return parts.join(" ");
6658
6662
  }
6659
- const _sfc_main$X = vue.defineComponent({
6663
+ const _sfc_main$Y = vue.defineComponent({
6660
6664
  name: "FCalendarDay",
6661
6665
  mixins: [TranslationMixin],
6662
6666
  props: {
@@ -6721,18 +6725,18 @@ const _sfc_main$X = vue.defineComponent({
6721
6725
  }
6722
6726
  }
6723
6727
  });
6724
- const _hoisted_1$J = {
6728
+ const _hoisted_1$K = {
6725
6729
  "aria-hidden": "true"
6726
6730
  };
6727
6731
  const _hoisted_2$x = {
6728
6732
  class: "sr-only"
6729
6733
  };
6730
- function _sfc_render$H(_ctx, _cache, $props, $setup, $data, $options) {
6734
+ function _sfc_render$C(_ctx, _cache, $props, $setup, $data, $options) {
6731
6735
  return vue.openBlock(), vue.createElementBlock("span", {
6732
6736
  class: vue.normalizeClass(_ctx.dayClasses)
6733
- }, [vue.createElementVNode("span", _hoisted_1$J, vue.toDisplayString(_ctx.day.day), 1), _cache[0] || (_cache[0] = vue.createTextVNode()), vue.createElementVNode("span", _hoisted_2$x, vue.toDisplayString(_ctx.srText), 1)], 2);
6737
+ }, [vue.createElementVNode("span", _hoisted_1$K, vue.toDisplayString(_ctx.day.day), 1), _cache[0] || (_cache[0] = vue.createTextVNode()), vue.createElementVNode("span", _hoisted_2$x, vue.toDisplayString(_ctx.srText), 1)], 2);
6734
6738
  }
6735
- const FCalendarDay = /* @__PURE__ */ _export_sfc(_sfc_main$X, [["render", _sfc_render$H]]);
6739
+ const FCalendarDay = /* @__PURE__ */ _export_sfc(_sfc_main$Y, [["render", _sfc_render$C]]);
6736
6740
  function useEventListener(target, event, callback) {
6737
6741
  vue.onMounted(() => {
6738
6742
  var _a;
@@ -6746,14 +6750,14 @@ function useEventListener(target, event, callback) {
6746
6750
  function useSlotUtils() {
6747
6751
  const $slots = vue.useSlots();
6748
6752
  return {
6749
- hasSlot(name) {
6753
+ hasSlot(...args) {
6750
6754
  return hasSlot({
6751
6755
  $slots
6752
- }, name);
6756
+ }, ...args);
6753
6757
  }
6754
6758
  };
6755
6759
  }
6756
- const _hoisted_1$I = ["id"];
6760
+ const _hoisted_1$J = ["id"];
6757
6761
  const _hoisted_2$w = {
6758
6762
  key: 0,
6759
6763
  class: "card__header"
@@ -6765,7 +6769,7 @@ const _hoisted_4$m = {
6765
6769
  key: 1,
6766
6770
  class: "card__footer"
6767
6771
  };
6768
- const _sfc_main$W = /* @__PURE__ */ vue.defineComponent({
6772
+ const _sfc_main$X = /* @__PURE__ */ vue.defineComponent({
6769
6773
  __name: "FCard",
6770
6774
  props: {
6771
6775
  /**
@@ -6851,11 +6855,11 @@ const _sfc_main$W = /* @__PURE__ */ vue.defineComponent({
6851
6855
  })) : vue.createCommentVNode("", true)]), _cache[2] || (_cache[2] = vue.createTextVNode()), vue.createElementVNode("div", _hoisted_3$q, [vue.renderSlot(_ctx.$slots, "default")]), _cache[3] || (_cache[3] = vue.createTextVNode()), hasFooterSlot.value ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_4$m, [vue.renderSlot(_ctx.$slots, "footer", vue.normalizeProps(vue.guardReactiveProps({
6852
6856
  hasError: hasError.value,
6853
6857
  validationMessage: validationMessage.value
6854
- })))])) : vue.createCommentVNode("", true)], 42, _hoisted_1$I);
6858
+ })))])) : vue.createCommentVNode("", true)], 42, _hoisted_1$J);
6855
6859
  };
6856
6860
  }
6857
6861
  });
6858
- const _sfc_main$V = vue.defineComponent({
6862
+ const _sfc_main$W = vue.defineComponent({
6859
6863
  name: "FExpand",
6860
6864
  data() {
6861
6865
  return {
@@ -6909,7 +6913,7 @@ const _sfc_main$V = vue.defineComponent({
6909
6913
  }
6910
6914
  }
6911
6915
  });
6912
- function _sfc_render$G(_ctx, _cache, $props, $setup, $data, $options) {
6916
+ function _sfc_render$B(_ctx, _cache, $props, $setup, $data, $options) {
6913
6917
  return vue.openBlock(), vue.createBlock(vue.Transition, {
6914
6918
  onEnter: _ctx.enter,
6915
6919
  onAfterEnter: _ctx.afterEnter,
@@ -6921,7 +6925,7 @@ function _sfc_render$G(_ctx, _cache, $props, $setup, $data, $options) {
6921
6925
  _: 3
6922
6926
  }, 8, ["onEnter", "onAfterEnter", "onLeave"]);
6923
6927
  }
6924
- const FExpand = /* @__PURE__ */ _export_sfc(_sfc_main$V, [["render", _sfc_render$G]]);
6928
+ const FExpand = /* @__PURE__ */ _export_sfc(_sfc_main$W, [["render", _sfc_render$B]]);
6925
6929
  function offset(page, el) {
6926
6930
  const rect = el.getBoundingClientRect();
6927
6931
  return {
@@ -7206,7 +7210,7 @@ function isTeleportDisabled(options) {
7206
7210
  }
7207
7211
  return disableTeleport;
7208
7212
  }
7209
- const _sfc_main$U = vue.defineComponent({
7213
+ const _sfc_main$V = vue.defineComponent({
7210
7214
  name: "IPopup",
7211
7215
  inheritAttrs: false,
7212
7216
  props: {
@@ -7487,7 +7491,7 @@ const _sfc_main$U = vue.defineComponent({
7487
7491
  }
7488
7492
  }
7489
7493
  });
7490
- function _sfc_render$F(_ctx, _cache, $props, $setup, $data, $options) {
7494
+ function _sfc_render$A(_ctx, _cache, $props, $setup, $data, $options) {
7491
7495
  return _ctx.isOpen ? (vue.openBlock(), vue.createBlock(vue.Teleport, {
7492
7496
  key: 0,
7493
7497
  to: _ctx.teleportTarget,
@@ -7508,7 +7512,7 @@ function _sfc_render$F(_ctx, _cache, $props, $setup, $data, $options) {
7508
7512
  placement: _ctx.placement
7509
7513
  })))], 544)], 16)], 8, ["to", "disabled"])) : vue.createCommentVNode("", true);
7510
7514
  }
7511
- const IPopup = /* @__PURE__ */ _export_sfc(_sfc_main$U, [["render", _sfc_render$F]]);
7515
+ const IPopup = /* @__PURE__ */ _export_sfc(_sfc_main$V, [["render", _sfc_render$A]]);
7512
7516
  function computeArrowOffset(placement, inputIconRect, wrapperRect) {
7513
7517
  switch (placement) {
7514
7518
  case Placement.A: {
@@ -7572,7 +7576,7 @@ function computeArrowOffset(placement, inputIconRect, wrapperRect) {
7572
7576
  }
7573
7577
  }
7574
7578
  const POPUP_SPACING = 10;
7575
- const _sfc_main$T = vue.defineComponent({
7579
+ const _sfc_main$U = vue.defineComponent({
7576
7580
  name: "IPopupError",
7577
7581
  components: {
7578
7582
  FIcon
@@ -7623,6 +7627,9 @@ const _sfc_main$T = vue.defineComponent({
7623
7627
  },
7624
7628
  errorStyle() {
7625
7629
  return `--i-popup-error-offset: ${this.arrowOffset}px`;
7630
+ },
7631
+ teleportTarget() {
7632
+ return config.teleportTarget;
7626
7633
  }
7627
7634
  },
7628
7635
  watch: {
@@ -7707,21 +7714,21 @@ const _sfc_main$T = vue.defineComponent({
7707
7714
  }
7708
7715
  }
7709
7716
  });
7710
- const _hoisted_1$H = {
7717
+ const _hoisted_1$I = {
7711
7718
  ref: "wrapper",
7712
7719
  class: "popup-error__wrapper"
7713
7720
  };
7714
- function _sfc_render$E(_ctx, _cache, $props, $setup, $data, $options) {
7721
+ function _sfc_render$z(_ctx, _cache, $props, $setup, $data, $options) {
7715
7722
  const _component_f_icon = vue.resolveComponent("f-icon");
7716
7723
  return _ctx.isOpen ? (vue.openBlock(), vue.createBlock(vue.Teleport, {
7717
7724
  key: 0,
7718
- to: "body",
7725
+ to: _ctx.teleportTarget,
7719
7726
  disabled: _ctx.teleportDisabled
7720
7727
  }, [vue.createElementVNode("div", {
7721
7728
  ref: "popup",
7722
7729
  class: vue.normalizeClass(_ctx.popupClasses),
7723
7730
  "aria-hidden": "true"
7724
- }, [vue.createElementVNode("div", _hoisted_1$H, [vue.createElementVNode("div", {
7731
+ }, [vue.createElementVNode("div", _hoisted_1$I, [vue.createElementVNode("div", {
7725
7732
  class: vue.normalizeClass(_ctx.arrowClass),
7726
7733
  style: vue.normalizeStyle(_ctx.errorStyle)
7727
7734
  }, [vue.createElementVNode("span", null, vue.toDisplayString(_ctx.errorMessage), 1), _cache[1] || (_cache[1] = vue.createTextVNode()), vue.createElementVNode("button", {
@@ -7733,9 +7740,9 @@ function _sfc_render$E(_ctx, _cache, $props, $setup, $data, $options) {
7733
7740
  }, [vue.createVNode(_component_f_icon, {
7734
7741
  name: "close",
7735
7742
  class: "button__icon"
7736
- })])], 6)], 512)], 2)], 8, ["disabled"])) : vue.createCommentVNode("", true);
7743
+ })])], 6)], 512)], 2)], 8, ["to", "disabled"])) : vue.createCommentVNode("", true);
7737
7744
  }
7738
- const IPopupError = /* @__PURE__ */ _export_sfc(_sfc_main$T, [["render", _sfc_render$E]]);
7745
+ const IPopupError = /* @__PURE__ */ _export_sfc(_sfc_main$U, [["render", _sfc_render$z]]);
7739
7746
  function numItems(itemHeight, availableHeight, verticalSpacing) {
7740
7747
  const itemsFit = Math.floor((availableHeight - verticalSpacing) / itemHeight);
7741
7748
  return Math.min(itemsFit, 7);
@@ -7802,12 +7809,12 @@ function computeListboxRect(anchor, options, root = document.documentElement, {
7802
7809
  }
7803
7810
  return void 0;
7804
7811
  }
7805
- const _hoisted_1$G = ["onKeyup"];
7812
+ const _hoisted_1$H = ["onKeyup"];
7806
7813
  const _hoisted_2$v = {
7807
7814
  ref: "content"
7808
7815
  };
7809
7816
  const teleportDisabled = false;
7810
- const _sfc_main$S = /* @__PURE__ */ vue.defineComponent({
7817
+ const _sfc_main$T = /* @__PURE__ */ vue.defineComponent({
7811
7818
  __name: "IPopupListbox",
7812
7819
  props: {
7813
7820
  isOpen: {
@@ -7912,7 +7919,11 @@ const _sfc_main$S = /* @__PURE__ */ vue.defineComponent({
7912
7919
  }
7913
7920
  if (verticalSpacing === void 0) {
7914
7921
  const absWrapper = getAbsolutePosition(wrapperElement);
7915
- const marginTotal = absWrapper.y * 2;
7922
+ const {
7923
+ marginTop,
7924
+ marginBottom
7925
+ } = getComputedStyle(wrapperElement);
7926
+ const marginTotal = parseInt(marginTop, 10) + parseInt(marginBottom, 10);
7916
7927
  verticalSpacing = Math.ceil(absWrapper.height - contentItemHeigth * __props.numOfItems) + marginTotal;
7917
7928
  }
7918
7929
  wrapperElement.style.overflowY = "auto";
@@ -7924,7 +7935,7 @@ const _sfc_main$S = /* @__PURE__ */ vue.defineComponent({
7924
7935
  verticalSpacing
7925
7936
  });
7926
7937
  if (rect) {
7927
- var _offsetRect$x;
7938
+ var _offsetRect$x, _offsetRect$top;
7928
7939
  const {
7929
7940
  top,
7930
7941
  left,
@@ -7933,7 +7944,8 @@ const _sfc_main$S = /* @__PURE__ */ vue.defineComponent({
7933
7944
  } = rect;
7934
7945
  const offsetRect = (_a = wrapperElement == null ? void 0 : wrapperElement.offsetParent) == null ? void 0 : _a.getBoundingClientRect();
7935
7946
  const offsetLeft = (_offsetRect$x = offsetRect == null ? void 0 : offsetRect.x) !== null && _offsetRect$x !== void 0 ? _offsetRect$x : 0;
7936
- wrapperElement.style.top = `${top}px`;
7947
+ const offSetTop = Math.floor(((_offsetRect$top = offsetRect == null ? void 0 : offsetRect.top) !== null && _offsetRect$top !== void 0 ? _offsetRect$top : 0) + window.scrollY);
7948
+ wrapperElement.style.top = `${top - offSetTop}px`;
7937
7949
  wrapperElement.style.left = `${left - offsetLeft}px`;
7938
7950
  wrapperElement.style.width = `${width}px`;
7939
7951
  contentWrapper.style.maxHeight = `${height}px`;
@@ -7956,7 +7968,7 @@ const _sfc_main$S = /* @__PURE__ */ vue.defineComponent({
7956
7968
  onKeyup: vue.withKeys(vue.withModifiers(onKeyEsc, ["stop"]), ["esc"]),
7957
7969
  onClick: _cache[0] || (_cache[0] = vue.withModifiers(() => {
7958
7970
  }, ["stop"]))
7959
- }), [vue.createElementVNode("div", _hoisted_2$v, [vue.renderSlot(_ctx.$slots, "default")], 512)], 16, _hoisted_1$G)], 512)], 8, ["to"])) : vue.createCommentVNode("", true);
7971
+ }), [vue.createElementVNode("div", _hoisted_2$v, [vue.renderSlot(_ctx.$slots, "default")], 512)], 16, _hoisted_1$H)], 512)], 8, ["to"])) : vue.createCommentVNode("", true);
7960
7972
  };
7961
7973
  }
7962
7974
  });
@@ -8000,7 +8012,7 @@ async function doMenuAction$2(action, target) {
8000
8012
  }
8001
8013
  }
8002
8014
  const preventKeys$2 = ["Tab", "Up", "Down", "ArrowUp", "ArrowDown", "Home", "End", " ", "Spacebar", "Enter"];
8003
- const _sfc_main$R = vue.defineComponent({
8015
+ const _sfc_main$S = vue.defineComponent({
8004
8016
  name: "IPopupMenu",
8005
8017
  components: {
8006
8018
  IPopup
@@ -8255,7 +8267,7 @@ const _sfc_main$R = vue.defineComponent({
8255
8267
  }
8256
8268
  }
8257
8269
  });
8258
- const _hoisted_1$F = ["aria-label"];
8270
+ const _hoisted_1$G = ["aria-label"];
8259
8271
  const _hoisted_2$u = {
8260
8272
  role: "menu",
8261
8273
  class: "ipopupmenu__list"
@@ -8266,7 +8278,7 @@ const _hoisted_5$h = {
8266
8278
  key: 0,
8267
8279
  class: "sr-only"
8268
8280
  };
8269
- function _sfc_render$D(_ctx, _cache, $props, $setup, $data, $options) {
8281
+ function _sfc_render$y(_ctx, _cache, $props, $setup, $data, $options) {
8270
8282
  const _component_i_popup = vue.resolveComponent("i-popup");
8271
8283
  return vue.openBlock(), vue.createBlock(_component_i_popup, {
8272
8284
  class: "ipopupmenu",
@@ -8298,17 +8310,17 @@ function _sfc_render$D(_ctx, _cache, $props, $setup, $data, $options) {
8298
8310
  target: item.target,
8299
8311
  tabindex: "0"
8300
8312
  }, [_ctx.isSelected(index) ? (vue.openBlock(), vue.createElementBlock("span", _hoisted_5$h, [vue.createElementVNode("span", null, vue.toDisplayString(_ctx.selectedMenuItemScreenReaderText) + " ", 1)])) : vue.createCommentVNode("", true), vue.createTextVNode(" " + vue.toDisplayString(item.label), 1)], 8, _hoisted_4$l)], 10, _hoisted_3$p);
8301
- }), 128))])], 8, _hoisted_1$F)]),
8313
+ }), 128))])], 8, _hoisted_1$G)]),
8302
8314
  _: 1
8303
8315
  }, 8, ["is-open", "anchor", "focus-element", "onKeyup", "onKeydown"]);
8304
8316
  }
8305
- const IPopupMenu = /* @__PURE__ */ _export_sfc(_sfc_main$R, [["render", _sfc_render$D]]);
8317
+ const IPopupMenu = /* @__PURE__ */ _export_sfc(_sfc_main$S, [["render", _sfc_render$y]]);
8306
8318
  const ANIMATION_DURATION = 500;
8307
8319
  const NO_CSS_CLASSES = "";
8308
8320
  const CLOSED_CSS_CLASS_OPACITY = "animate-expand animate-expand--opacity";
8309
8321
  const CLOSED_CSS_CLASS = "animate-expand";
8310
8322
  const ANIMATION_CSS_CLASSES = "animate-expand animate-expand--expanded";
8311
- const _sfc_main$Q = vue.defineComponent({
8323
+ const _sfc_main$R = vue.defineComponent({
8312
8324
  name: "IAnimateExpand",
8313
8325
  props: {
8314
8326
  /**
@@ -8500,19 +8512,19 @@ const _sfc_main$Q = vue.defineComponent({
8500
8512
  }
8501
8513
  }
8502
8514
  });
8503
- const _hoisted_1$E = {
8515
+ const _hoisted_1$F = {
8504
8516
  key: 0,
8505
8517
  ref: "content",
8506
8518
  "data-test": "animation-content"
8507
8519
  };
8508
- function _sfc_render$C(_ctx, _cache, $props, $setup, $data, $options) {
8520
+ function _sfc_render$x(_ctx, _cache, $props, $setup, $data, $options) {
8509
8521
  return vue.openBlock(), vue.createElementBlock("div", {
8510
8522
  class: vue.normalizeClass(_ctx.animationClasses),
8511
8523
  style: vue.normalizeStyle(_ctx.heightStyle)
8512
- }, [_ctx.shouldVIf ? vue.withDirectives((vue.openBlock(), vue.createElementBlock("div", _hoisted_1$E, [vue.renderSlot(_ctx.$slots, "default")], 512)), [[vue.vShow, _ctx.shouldVShow]]) : vue.createCommentVNode("", true)], 6);
8524
+ }, [_ctx.shouldVIf ? vue.withDirectives((vue.openBlock(), vue.createElementBlock("div", _hoisted_1$F, [vue.renderSlot(_ctx.$slots, "default")], 512)), [[vue.vShow, _ctx.shouldVShow]]) : vue.createCommentVNode("", true)], 6);
8513
8525
  }
8514
- const IAnimateExpand = /* @__PURE__ */ _export_sfc(_sfc_main$Q, [["render", _sfc_render$C]]);
8515
- const _sfc_main$P = vue.defineComponent({
8526
+ const IAnimateExpand = /* @__PURE__ */ _export_sfc(_sfc_main$R, [["render", _sfc_render$x]]);
8527
+ const _sfc_main$Q = vue.defineComponent({
8516
8528
  name: "ISkipLink",
8517
8529
  mixins: [TranslationMixin],
8518
8530
  props: {
@@ -8526,14 +8538,14 @@ const _sfc_main$P = vue.defineComponent({
8526
8538
  }
8527
8539
  }
8528
8540
  });
8529
- const _hoisted_1$D = ["href"];
8530
- function _sfc_render$B(_ctx, _cache, $props, $setup, $data, $options) {
8541
+ const _hoisted_1$E = ["href"];
8542
+ function _sfc_render$w(_ctx, _cache, $props, $setup, $data, $options) {
8531
8543
  return vue.openBlock(), vue.createElementBlock("a", {
8532
8544
  class: "iskiplink",
8533
8545
  href: _ctx.href
8534
- }, [vue.renderSlot(_ctx.$slots, "default", {}, () => [vue.createTextVNode(vue.toDisplayString(_ctx.$t("fkui.skip-link.text", "Gå direkt till innehåll")), 1)])], 8, _hoisted_1$D);
8546
+ }, [vue.renderSlot(_ctx.$slots, "default", {}, () => [vue.createTextVNode(vue.toDisplayString(_ctx.$t("fkui.skip-link.text", "Gå direkt till innehåll")), 1)])], 8, _hoisted_1$E);
8535
8547
  }
8536
- const ISkipLink = /* @__PURE__ */ _export_sfc(_sfc_main$P, [["render", _sfc_render$B]]);
8548
+ const ISkipLink = /* @__PURE__ */ _export_sfc(_sfc_main$Q, [["render", _sfc_render$w]]);
8537
8549
  function filterOptions(options, filter2, selectMode) {
8538
8550
  if (logic.isEmpty(filter2) || selectMode) {
8539
8551
  return options;
@@ -8779,12 +8791,12 @@ function useCombobox(inputRef, options, onOptionSelected) {
8779
8791
  }
8780
8792
  }
8781
8793
  }
8782
- const _hoisted_1$C = {
8794
+ const _hoisted_1$D = {
8783
8795
  class: "combobox"
8784
8796
  };
8785
8797
  const _hoisted_2$t = ["id"];
8786
8798
  const _hoisted_3$o = ["id", "aria-selected", "onClick"];
8787
- const _sfc_main$O = /* @__PURE__ */ vue.defineComponent({
8799
+ const _sfc_main$P = /* @__PURE__ */ vue.defineComponent({
8788
8800
  __name: "IComboboxDropdown",
8789
8801
  props: {
8790
8802
  id: {},
@@ -8821,7 +8833,7 @@ const _sfc_main$O = /* @__PURE__ */ vue.defineComponent({
8821
8833
  }
8822
8834
  });
8823
8835
  return (_ctx, _cache) => {
8824
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$C, [vue.createVNode(vue.unref(_sfc_main$S), {
8836
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$D, [vue.createVNode(vue.unref(_sfc_main$T), {
8825
8837
  "is-open": _ctx.isOpen,
8826
8838
  anchor: _ctx.inputNode,
8827
8839
  "num-of-items": _ctx.options.length,
@@ -8852,8 +8864,8 @@ const _sfc_main$O = /* @__PURE__ */ vue.defineComponent({
8852
8864
  };
8853
8865
  }
8854
8866
  });
8855
- const _hoisted_1$B = ["aria-label"];
8856
- const _sfc_main$N = /* @__PURE__ */ vue.defineComponent({
8867
+ const _hoisted_1$C = ["aria-label"];
8868
+ const _sfc_main$O = /* @__PURE__ */ vue.defineComponent({
8857
8869
  __name: "IComboboxToggleButton",
8858
8870
  emits: ["toggle"],
8859
8871
  setup(__props, {
@@ -8872,7 +8884,7 @@ const _sfc_main$N = /* @__PURE__ */ vue.defineComponent({
8872
8884
  }, [vue.createVNode(vue.unref(FIcon), {
8873
8885
  name: "arrow-down",
8874
8886
  class: "text-field__icon"
8875
- })], 8, _hoisted_1$B);
8887
+ })], 8, _hoisted_1$C);
8876
8888
  };
8877
8889
  }
8878
8890
  });
@@ -8974,7 +8986,7 @@ function useHorizontalOffset(options) {
8974
8986
  }, 0);
8975
8987
  }
8976
8988
  }
8977
- const _sfc_main$M = vue.defineComponent({
8989
+ const _sfc_main$N = vue.defineComponent({
8978
8990
  name: "FTooltip",
8979
8991
  components: {
8980
8992
  FExpand,
@@ -9133,7 +9145,7 @@ const _sfc_main$M = vue.defineComponent({
9133
9145
  }
9134
9146
  }
9135
9147
  });
9136
- const _hoisted_1$A = ["aria-expanded"];
9148
+ const _hoisted_1$B = ["aria-expanded"];
9137
9149
  const _hoisted_2$s = {
9138
9150
  class: "icon-stack icon-stack--tooltip"
9139
9151
  };
@@ -9151,7 +9163,7 @@ const _hoisted_5$g = {
9151
9163
  const _hoisted_6$d = {
9152
9164
  class: "tooltip__footer"
9153
9165
  };
9154
- function _sfc_render$A(_ctx, _cache, $props, $setup, $data, $options) {
9166
+ function _sfc_render$v(_ctx, _cache, $props, $setup, $data, $options) {
9155
9167
  const _component_f_icon = vue.resolveComponent("f-icon");
9156
9168
  return vue.openBlock(), vue.createElementBlock(vue.Fragment, null, [(vue.openBlock(), vue.createBlock(vue.Teleport, {
9157
9169
  disabled: _ctx.iconTarget === null,
@@ -9166,7 +9178,7 @@ function _sfc_render$A(_ctx, _cache, $props, $setup, $data, $options) {
9166
9178
  name: "circle"
9167
9179
  }), _cache[2] || (_cache[2] = vue.createTextVNode()), vue.createVNode(_component_f_icon, {
9168
9180
  name: "i"
9169
- }), _cache[3] || (_cache[3] = vue.createTextVNode()), vue.createElementVNode("span", _hoisted_3$n, vue.toDisplayString(_ctx.screenReaderText), 1)])], 8, _hoisted_1$A)], 8, ["disabled", "to"])), _cache[7] || (_cache[7] = vue.createTextVNode()), vue.createElementVNode("div", vue.mergeProps({
9181
+ }), _cache[3] || (_cache[3] = vue.createTextVNode()), vue.createElementVNode("span", _hoisted_3$n, vue.toDisplayString(_ctx.screenReaderText), 1)])], 8, _hoisted_1$B)], 8, ["disabled", "to"])), _cache[7] || (_cache[7] = vue.createTextVNode()), vue.createElementVNode("div", vue.mergeProps({
9170
9182
  ref: "wrapper",
9171
9183
  class: "tooltip"
9172
9184
  }, _ctx.$attrs), [_ctx.ready ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_4$k, [_ctx.hasHeader ? (vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(_ctx.headerTag), {
@@ -9184,7 +9196,7 @@ function _sfc_render$A(_ctx, _cache, $props, $setup, $data, $options) {
9184
9196
  name: "close"
9185
9197
  })])])])) : vue.createCommentVNode("", true)], 16)], 64);
9186
9198
  }
9187
- const FTooltip = /* @__PURE__ */ _export_sfc(_sfc_main$M, [["render", _sfc_render$A]]);
9199
+ const FTooltip = /* @__PURE__ */ _export_sfc(_sfc_main$N, [["render", _sfc_render$v]]);
9188
9200
  function* labelClasses(options) {
9189
9201
  const {
9190
9202
  labelClass
@@ -9225,7 +9237,7 @@ function isEqual(a, b) {
9225
9237
  }
9226
9238
  return a.every((_, i) => a[i] === b[i]);
9227
9239
  }
9228
- const _sfc_main$L = vue.defineComponent({
9240
+ const _sfc_main$M = vue.defineComponent({
9229
9241
  name: "FFieldset",
9230
9242
  components: {
9231
9243
  FIcon
@@ -9453,7 +9465,7 @@ const _sfc_main$L = vue.defineComponent({
9453
9465
  }
9454
9466
  }
9455
9467
  });
9456
- const _hoisted_1$z = ["id"];
9468
+ const _hoisted_1$A = ["id"];
9457
9469
  const _hoisted_2$r = {
9458
9470
  key: 0,
9459
9471
  class: "sr-only"
@@ -9485,7 +9497,7 @@ const _hoisted_9$4 = {
9485
9497
  key: 0,
9486
9498
  class: "label__message label__message--error"
9487
9499
  };
9488
- function _sfc_render$z(_ctx, _cache, $props, $setup, $data, $options) {
9500
+ function _sfc_render$u(_ctx, _cache, $props, $setup, $data, $options) {
9489
9501
  const _component_f_icon = vue.resolveComponent("f-icon");
9490
9502
  return vue.openBlock(), vue.createElementBlock("fieldset", {
9491
9503
  id: _ctx.id,
@@ -9520,11 +9532,11 @@ function _sfc_render$z(_ctx, _cache, $props, $setup, $data, $options) {
9520
9532
  name: "error"
9521
9533
  }), vue.createTextVNode(" " + vue.toDisplayString(_ctx.validity.validationMessage), 1)])) : vue.createCommentVNode("", true)])], 2)) : vue.createCommentVNode("", true)], 64)) : vue.createCommentVNode("", true), _cache[9] || (_cache[9] = vue.createTextVNode()), vue.createElementVNode("div", {
9522
9534
  class: vue.normalizeClass(_ctx.groupContentClass)
9523
- }, [vue.renderSlot(_ctx.$slots, "default")], 2)], 42, _hoisted_1$z);
9535
+ }, [vue.renderSlot(_ctx.$slots, "default")], 2)], 42, _hoisted_1$A);
9524
9536
  }
9525
- const FFieldset = /* @__PURE__ */ _export_sfc(_sfc_main$L, [["render", _sfc_render$z]]);
9537
+ const FFieldset = /* @__PURE__ */ _export_sfc(_sfc_main$M, [["render", _sfc_render$u]]);
9526
9538
  const anyType$1 = [String, Object, Array, Number, Date, Boolean];
9527
- const _sfc_main$K = vue.defineComponent({
9539
+ const _sfc_main$L = vue.defineComponent({
9528
9540
  name: "FCheckboxField",
9529
9541
  inheritAttrs: false,
9530
9542
  props: {
@@ -9710,7 +9722,7 @@ const _sfc_main$K = vue.defineComponent({
9710
9722
  }
9711
9723
  }
9712
9724
  });
9713
- const _hoisted_1$y = ["id", "disabled"];
9725
+ const _hoisted_1$z = ["id", "disabled"];
9714
9726
  const _hoisted_2$q = ["for"];
9715
9727
  const _hoisted_3$l = {
9716
9728
  key: 0,
@@ -9720,7 +9732,7 @@ const _hoisted_4$i = {
9720
9732
  key: 0,
9721
9733
  class: "checkbox__details"
9722
9734
  };
9723
- function _sfc_render$y(_ctx, _cache, $props, $setup, $data, $options) {
9735
+ function _sfc_render$t(_ctx, _cache, $props, $setup, $data, $options) {
9724
9736
  return vue.openBlock(), vue.createElementBlock("div", {
9725
9737
  class: vue.normalizeClass(["checkbox", _ctx.disabledClass]),
9726
9738
  onValidity: _cache[2] || (_cache[2] = (...args) => _ctx.onValidity && _ctx.onValidity(...args))
@@ -9733,7 +9745,7 @@ function _sfc_render$y(_ctx, _cache, $props, $setup, $data, $options) {
9733
9745
  disabled: _ctx.disabled,
9734
9746
  onKeydown: _cache[0] || (_cache[0] = vue.withKeys((...args) => _ctx.onKeydown && _ctx.onKeydown(...args), ["space"])),
9735
9747
  onChange: _cache[1] || (_cache[1] = ($event) => _ctx.updateExpandedFlag())
9736
- }), null, 16, _hoisted_1$y), _cache[9] || (_cache[9] = vue.createTextVNode()), vue.createElementVNode("label", {
9748
+ }), null, 16, _hoisted_1$z), _cache[9] || (_cache[9] = vue.createTextVNode()), vue.createElementVNode("label", {
9737
9749
  class: vue.normalizeClass(_ctx.$slots.details ? "checkbox__label checkbox__width" : "checkbox__label"),
9738
9750
  for: _ctx.id
9739
9751
  }, [vue.renderSlot(_ctx.$slots, "default"), _cache[8] || (_cache[8] = vue.createTextVNode()), _ctx.$slots.details ? (vue.openBlock(), vue.createElementBlock(vue.Fragment, {
@@ -9750,7 +9762,7 @@ function _sfc_render$y(_ctx, _cache, $props, $setup, $data, $options) {
9750
9762
  _: 3
9751
9763
  }, 8, ["onEnter", "onAfterEnter", "onLeave"])) : vue.createCommentVNode("", true)], 64)) : vue.createCommentVNode("", true)], 10, _hoisted_2$q)], 34);
9752
9764
  }
9753
- const FCheckboxField = /* @__PURE__ */ _export_sfc(_sfc_main$K, [["render", _sfc_render$y]]);
9765
+ const FCheckboxField = /* @__PURE__ */ _export_sfc(_sfc_main$L, [["render", _sfc_render$t]]);
9754
9766
  var es_iterator_some = {};
9755
9767
  var hasRequiredEs_iterator_some;
9756
9768
  function requireEs_iterator_some() {
@@ -9829,7 +9841,7 @@ async function doMenuAction$1(action, target) {
9829
9841
  }
9830
9842
  const preventKeys$1 = ["Tab", "Up", "Down", "ArrowUp", "ArrowDown", "Home", "End", " ", "Spacebar", "Enter", "Escape"];
9831
9843
  const keyUp = ["ArrowUp", "Up"];
9832
- const _sfc_main$J = vue.defineComponent({
9844
+ const _sfc_main$K = vue.defineComponent({
9833
9845
  name: "FContextMenu",
9834
9846
  components: {
9835
9847
  IPopup,
@@ -9993,7 +10005,7 @@ const _sfc_main$J = vue.defineComponent({
9993
10005
  }
9994
10006
  }
9995
10007
  });
9996
- const _hoisted_1$x = ["aria-label"];
10008
+ const _hoisted_1$y = ["aria-label"];
9997
10009
  const _hoisted_2$p = {
9998
10010
  ref: "contextmenu",
9999
10011
  role: "menu",
@@ -10006,7 +10018,7 @@ const _hoisted_5$e = {
10006
10018
  key: 0,
10007
10019
  class: "contextmenu__separator"
10008
10020
  };
10009
- function _sfc_render$x(_ctx, _cache, $props, $setup, $data, $options) {
10021
+ function _sfc_render$s(_ctx, _cache, $props, $setup, $data, $options) {
10010
10022
  const _component_f_icon = vue.resolveComponent("f-icon");
10011
10023
  const _component_i_popup = vue.resolveComponent("i-popup");
10012
10024
  return vue.openBlock(), vue.createBlock(_component_i_popup, {
@@ -10042,11 +10054,11 @@ function _sfc_render$x(_ctx, _cache, $props, $setup, $data, $options) {
10042
10054
  ref_for: true,
10043
10055
  ref: "anchors"
10044
10056
  }, vue.toDisplayString(item.label), 513)], 8, _hoisted_4$h), _cache[4] || (_cache[4] = vue.createTextVNode()), _ctx.hasSeparatorAfterItemAt(index) ? (vue.openBlock(), vue.createElementBlock("hr", _hoisted_5$e)) : vue.createCommentVNode("", true)], 8, _hoisted_3$k);
10045
- }), 128))], 512)], 40, _hoisted_1$x)]),
10057
+ }), 128))], 512)], 40, _hoisted_1$y)]),
10046
10058
  _: 1
10047
10059
  }, 8, ["is-open", "anchor", "focus-element"]);
10048
10060
  }
10049
- const FContextMenu = /* @__PURE__ */ _export_sfc(_sfc_main$J, [["render", _sfc_render$x]]);
10061
+ const FContextMenu = /* @__PURE__ */ _export_sfc(_sfc_main$K, [["render", _sfc_render$s]]);
10050
10062
  var Operation = /* @__PURE__ */ ((Operation2) => {
10051
10063
  Operation2[Operation2["ADD"] = 0] = "ADD";
10052
10064
  Operation2[Operation2["DELETE"] = 1] = "DELETE";
@@ -10054,30 +10066,14 @@ var Operation = /* @__PURE__ */ ((Operation2) => {
10054
10066
  Operation2[Operation2["NONE"] = 3] = "NONE";
10055
10067
  return Operation2;
10056
10068
  })(Operation || {});
10057
- const _sfc_main$I = vue.defineComponent({
10058
- name: "FCrudDataset",
10059
- components: {
10060
- FFormModal,
10061
- FConfirmModal,
10062
- FIcon
10063
- },
10064
- mixins: [TranslationMixin],
10065
- provide() {
10066
- return {
10067
- delete: (item) => {
10068
- this.deleteItem(item);
10069
- },
10070
- modify: (item) => {
10071
- this.updateItem(item);
10072
- },
10073
- registerCallbackAfterItemAdd: (callback) => {
10074
- this.callbackAfterItemAdd = callback;
10075
- },
10076
- registerCallbackBeforeItemDelete: (callback) => {
10077
- this.callbackBeforeItemDelete = callback;
10078
- }
10079
- };
10080
- },
10069
+ const _hoisted_1$x = {
10070
+ class: "crud-dataset"
10071
+ };
10072
+ const _hoisted_2$o = {
10073
+ key: 0
10074
+ };
10075
+ const _sfc_main$J = /* @__PURE__ */ vue.defineComponent({
10076
+ __name: "FCrudDataset",
10081
10077
  props: {
10082
10078
  /**
10083
10079
  * The list of items that should be deleted, modified or added to.
@@ -10161,25 +10157,24 @@ const _sfc_main$I = vue.defineComponent({
10161
10157
  }
10162
10158
  },
10163
10159
  emits: ["created", "deleted", "updated", "update:modelValue"],
10164
- data() {
10165
- return {
10166
- result: [],
10167
- Operation,
10168
- operation: Operation.NONE,
10169
- item: null,
10170
- originalItemToUpdate: null,
10171
- isFormModalOpen: false,
10172
- isConfirmModalOpen: false,
10173
- callbackAfterItemAdd() {
10174
- },
10175
- callbackBeforeItemDelete() {
10176
- }
10177
- };
10178
- },
10179
- computed: {
10180
- formModalButtons() {
10181
- const confirmButtonText = this.operation === Operation.ADD ? this.$t("fkui.crud-dataset.modal.confirm.add", "Lägg till") : this.$t("fkui.crud-dataset.modal.confirm.modify", "Spara");
10182
- const cancelButtonText = this.operation === Operation.ADD ? this.$t("fkui.crud-dataset.modal.cancel.add", "Avbryt") : this.$t("fkui.crud-dataset.modal.cancel.modify", "Avbryt");
10160
+ setup(__props, {
10161
+ emit: __emit
10162
+ }) {
10163
+ const $t2 = useTranslate();
10164
+ const slots = vue.useSlots();
10165
+ const result = vue.ref([]);
10166
+ const operation = vue.ref(Operation.NONE);
10167
+ const item = vue.ref(null);
10168
+ const originalItemToUpdate = vue.ref(null);
10169
+ const isFormModalOpen = vue.ref(false);
10170
+ const isConfirmModalOpen = vue.ref(false);
10171
+ const callbackAfterItemAdd = vue.ref(() => ({}));
10172
+ const callbackBeforeItemDelete = vue.ref(() => ({}));
10173
+ const props = __props;
10174
+ const emit = __emit;
10175
+ const formModalButtons = vue.computed(() => {
10176
+ const confirmButtonText = operation.value === Operation.ADD ? $t2("fkui.crud-dataset.modal.confirm.add", "Lägg till") : $t2("fkui.crud-dataset.modal.confirm.modify", "Spara");
10177
+ const cancelButtonText = operation.value === Operation.ADD ? $t2("fkui.crud-dataset.modal.cancel.add", "Avbryt") : $t2("fkui.crud-dataset.modal.cancel.modify", "Avbryt");
10183
10178
  return [{
10184
10179
  label: confirmButtonText,
10185
10180
  event: "confirm",
@@ -10191,182 +10186,175 @@ const _sfc_main$I = vue.defineComponent({
10191
10186
  type: "secondary",
10192
10187
  submitButton: false
10193
10188
  }];
10194
- },
10195
- confirmDeleteButtons() {
10189
+ });
10190
+ const confirmDeleteButtons = vue.computed(() => {
10196
10191
  return [{
10197
- label: this.$t("fkui.crud-dataset.modal.confirm.delete", "Ja, ta bort"),
10192
+ label: $t2("fkui.crud-dataset.modal.confirm.delete", "Ja, ta bort"),
10198
10193
  type: "primary",
10199
10194
  event: "confirm"
10200
10195
  }, {
10201
- label: this.$t("fkui.crud-dataset.modal.cancel.delete", "Nej, avbryt"),
10196
+ label: $t2("fkui.crud-dataset.modal.cancel.delete", "Nej, avbryt"),
10202
10197
  type: "secondary"
10203
10198
  }];
10204
- },
10205
- hasAddSlot() {
10206
- return Boolean(this.$slots.add);
10207
- },
10208
- hasDeleteSlot() {
10209
- return Boolean(this.$slots.delete);
10210
- },
10211
- hasModifySlot() {
10212
- return Boolean(this.$slots.modify);
10213
- },
10214
- formModalHeader() {
10215
- return this.operation === Operation.ADD ? this.addNewModalHeader : this.modifyModalHeader;
10216
- }
10217
- },
10218
- watch: {
10219
- modelValue: {
10220
- immediate: true,
10221
- deep: true,
10222
- handler(data) {
10223
- this.result = [...data];
10199
+ });
10200
+ const hasAddSlot = vue.computed(() => {
10201
+ return Boolean(slots.add);
10202
+ });
10203
+ const hasDeleteSlot = vue.computed(() => {
10204
+ return Boolean(slots.delete);
10205
+ });
10206
+ const hasModifySlot = vue.computed(() => {
10207
+ return Boolean(slots.modify);
10208
+ });
10209
+ const formModalHeader = vue.computed(() => {
10210
+ return operation.value === Operation.ADD ? props.addNewModalHeader : props.modifyModalHeader;
10211
+ });
10212
+ vue.provide("delete", deleteItem);
10213
+ vue.provide("modify", updateItem);
10214
+ vue.provide("registerCallbackAfterItemAdd", (callback) => {
10215
+ callbackAfterItemAdd.value = callback;
10216
+ });
10217
+ vue.provide("registerCallbackBeforeItemDelete", (callback) => {
10218
+ callbackBeforeItemDelete.value = callback;
10219
+ });
10220
+ vue.onMounted(() => {
10221
+ if (!hasAddSlot.value && !hasDeleteSlot.value && !hasModifySlot.value) {
10222
+ throw Error("At least one template of the following must be defined. #add, #delete or #modify");
10224
10223
  }
10225
- }
10226
- },
10227
- mounted() {
10228
- if (!this.hasAddSlot && !this.hasDeleteSlot && !this.hasModifySlot) {
10229
- throw Error("Atleast one template of the following must be defined. #add, #delete or #modify");
10230
- }
10231
- },
10232
- methods: {
10233
- createItem() {
10234
- if (!this.hasAddSlot) {
10224
+ });
10225
+ vue.watch(() => props.modelValue, (data) => {
10226
+ result.value = [...data];
10227
+ }, {
10228
+ immediate: true,
10229
+ deep: true
10230
+ });
10231
+ function createItem() {
10232
+ if (!hasAddSlot.value) {
10235
10233
  throw Error("No template is defined for #add");
10236
10234
  }
10237
- this.operation = Operation.ADD;
10238
- this.item = this.beforeCreate ? this.beforeCreate() : {};
10239
- this.isFormModalOpen = true;
10240
- },
10241
- deleteItem(item) {
10242
- if (!this.hasDeleteSlot) {
10235
+ operation.value = Operation.ADD;
10236
+ item.value = props.beforeCreate ? props.beforeCreate() : {};
10237
+ isFormModalOpen.value = true;
10238
+ }
10239
+ function deleteItem(current) {
10240
+ if (!hasDeleteSlot.value) {
10243
10241
  throw Error("No template is defined for #delete");
10244
10242
  }
10245
- this.operation = Operation.DELETE;
10246
- this.item = item;
10247
- this.isConfirmModalOpen = true;
10248
- },
10249
- onDeleteConfirm() {
10250
- if (!this.item) {
10243
+ operation.value = Operation.DELETE;
10244
+ item.value = current;
10245
+ isConfirmModalOpen.value = true;
10246
+ }
10247
+ function onDeleteConfirm() {
10248
+ if (!item.value) {
10251
10249
  return;
10252
10250
  }
10253
- this.callbackBeforeItemDelete(this.item);
10254
- this.result = this.result.filter((item) => item !== this.item);
10255
- this.$emit("deleted", this.item);
10256
- this.$emit("update:modelValue", this.result);
10257
- logic.alertScreenReader(this.$t("fkui.crud-dataset.aria-live.delete", "Raden har tagits bort"), {
10251
+ callbackBeforeItemDelete.value(item.value);
10252
+ result.value = result.value.filter((it) => it !== item.value);
10253
+ emit("deleted", item.value);
10254
+ emit("update:modelValue", result.value);
10255
+ logic.alertScreenReader($t2("fkui.crud-dataset.aria-live.delete", "Raden har tagits bort"), {
10258
10256
  assertive: true
10259
10257
  });
10260
- },
10261
- onDeleteClose(e) {
10262
- this.onModalClose();
10263
- if (e.reason === "close" && this.onCancel) {
10264
- this.onCancel();
10258
+ }
10259
+ function onDeleteClose(e) {
10260
+ onModalClose();
10261
+ if (e.reason === "close" && props.onCancel) {
10262
+ props.onCancel();
10265
10263
  }
10266
- },
10267
- onModalClose() {
10268
- this.isFormModalOpen = false;
10269
- this.isConfirmModalOpen = false;
10270
- },
10271
- onFormModalSubmit() {
10272
- if (!this.item) {
10264
+ }
10265
+ function onModalClose() {
10266
+ isFormModalOpen.value = false;
10267
+ isConfirmModalOpen.value = false;
10268
+ }
10269
+ function onFormModalSubmit() {
10270
+ if (!item.value) {
10273
10271
  return;
10274
10272
  }
10275
- if (this.operation === Operation.ADD) {
10276
- this.result.push(this.item);
10277
- this.$emit("created", this.item);
10278
- this.$emit("update:modelValue", this.result);
10279
- this.callbackAfterItemAdd(this.item);
10280
- logic.alertScreenReader(this.$t("fkui.crud-dataset.aria-live.add", "En rad har lagts till"), {
10273
+ if (operation.value === Operation.ADD) {
10274
+ result.value.push(item.value);
10275
+ emit("created", item.value);
10276
+ emit("update:modelValue", result.value);
10277
+ callbackAfterItemAdd.value(item.value);
10278
+ logic.alertScreenReader($t2("fkui.crud-dataset.aria-live.add", "En rad har lagts till"), {
10281
10279
  assertive: true
10282
10280
  });
10283
- } else if (this.operation === Operation.MODIFY) {
10284
- if (this.originalItemToUpdate) {
10285
- Object.assign(this.originalItemToUpdate, this.item);
10281
+ } else if (operation.value === Operation.MODIFY) {
10282
+ if (originalItemToUpdate.value) {
10283
+ Object.assign(originalItemToUpdate.value, item.value);
10286
10284
  } else {
10287
- this.originalItemToUpdate = this.item;
10285
+ originalItemToUpdate.value = item.value;
10288
10286
  }
10289
- this.$emit("updated", this.originalItemToUpdate);
10290
- this.$emit("update:modelValue", this.result);
10291
- logic.alertScreenReader(this.$t("fkui.crud-dataset.aria-live.modify", "Raden har ändrats"), {
10287
+ emit("updated", originalItemToUpdate.value);
10288
+ emit("update:modelValue", result.value);
10289
+ logic.alertScreenReader($t2("fkui.crud-dataset.aria-live.modify", "Raden har ändrats"), {
10292
10290
  assertive: true
10293
10291
  });
10294
10292
  }
10295
- this.isFormModalOpen = false;
10296
- },
10297
- updateItem(item) {
10298
- if (!this.hasModifySlot) {
10293
+ isFormModalOpen.value = false;
10294
+ }
10295
+ function updateItem(current) {
10296
+ if (!hasModifySlot.value) {
10299
10297
  throw Error("No template is defined for #modify");
10300
10298
  }
10301
- this.operation = Operation.MODIFY;
10302
- this.originalItemToUpdate = item;
10303
- this.item = logic.deepClone(item);
10304
- this.isFormModalOpen = true;
10299
+ operation.value = Operation.MODIFY;
10300
+ originalItemToUpdate.value = current;
10301
+ item.value = logic.deepClone(current);
10302
+ isFormModalOpen.value = true;
10305
10303
  }
10304
+ return (_ctx, _cache) => {
10305
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$x, [vue.renderSlot(_ctx.$slots, "default"), _cache[5] || (_cache[5] = vue.createTextVNode()), hasAddSlot.value ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_2$o, [vue.createElementVNode("button", {
10306
+ "data-test": "f-crud-dataset-add-button",
10307
+ type: "button",
10308
+ class: "button button--tertiary crud-dataset__add-button",
10309
+ onClick: _cache[0] || (_cache[0] = ($event) => createItem())
10310
+ }, [vue.createVNode(vue.unref(FIcon), {
10311
+ class: "button__icon",
10312
+ name: "plus"
10313
+ }), _cache[1] || (_cache[1] = vue.createTextVNode()), vue.renderSlot(_ctx.$slots, "add-button", {}, () => [vue.createTextVNode(vue.toDisplayString(vue.unref($t2)("fkui.crud-dataset.button.add", "Lägg till ny")), 1)])])])) : vue.createCommentVNode("", true), _cache[6] || (_cache[6] = vue.createTextVNode()), vue.createVNode(vue.unref(FFormModal), {
10314
+ "is-open": isFormModalOpen.value,
10315
+ "aria-close-text": vue.unref($t2)("fkui.crud-dataset.modal.close", "Stäng"),
10316
+ buttons: formModalButtons.value,
10317
+ "use-error-list": false,
10318
+ "before-submit": __props.beforeSubmit,
10319
+ "before-validation": __props.beforeValidation,
10320
+ "on-cancel": __props.onCancel,
10321
+ onClose: onModalClose,
10322
+ onCancel: __props.onCancel,
10323
+ onSubmit: onFormModalSubmit
10324
+ }, {
10325
+ header: vue.withCtx(() => [vue.createTextVNode(vue.toDisplayString(formModalHeader.value), 1)]),
10326
+ "input-text-fields": vue.withCtx(() => [operation.value === vue.unref(Operation).ADD ? vue.renderSlot(_ctx.$slots, "add", vue.normalizeProps(vue.mergeProps({
10327
+ key: 0
10328
+ }, {
10329
+ item: item.value
10330
+ }))) : vue.createCommentVNode("", true), _cache[2] || (_cache[2] = vue.createTextVNode()), operation.value === vue.unref(Operation).MODIFY ? vue.renderSlot(_ctx.$slots, "modify", vue.normalizeProps(vue.mergeProps({
10331
+ key: 1
10332
+ }, {
10333
+ item: item.value
10334
+ }))) : vue.createCommentVNode("", true)]),
10335
+ _: 3
10336
+ }, 8, ["is-open", "aria-close-text", "buttons", "before-submit", "before-validation", "on-cancel", "onCancel"]), _cache[7] || (_cache[7] = vue.createTextVNode()), vue.createVNode(vue.unref(FConfirmModal), {
10337
+ "is-open": isConfirmModalOpen.value,
10338
+ buttons: confirmDeleteButtons.value,
10339
+ onConfirm: onDeleteConfirm,
10340
+ onClose: onDeleteClose
10341
+ }, {
10342
+ heading: vue.withCtx(() => [vue.createTextVNode(vue.toDisplayString(__props.deleteModalHeader), 1)]),
10343
+ content: vue.withCtx(() => [vue.renderSlot(_ctx.$slots, "delete", vue.normalizeProps(vue.guardReactiveProps({
10344
+ item: item.value
10345
+ })))]),
10346
+ _: 3
10347
+ }, 8, ["is-open", "buttons"])]);
10348
+ };
10306
10349
  }
10307
10350
  });
10308
- const _hoisted_1$w = {
10309
- class: "crud-dataset"
10310
- };
10311
- const _hoisted_2$o = {
10312
- key: 0
10313
- };
10314
- function _sfc_render$w(_ctx, _cache, $props, $setup, $data, $options) {
10315
- const _component_f_icon = vue.resolveComponent("f-icon");
10316
- const _component_f_form_modal = vue.resolveComponent("f-form-modal");
10317
- const _component_f_confirm_modal = vue.resolveComponent("f-confirm-modal");
10318
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$w, [vue.renderSlot(_ctx.$slots, "default"), _cache[5] || (_cache[5] = vue.createTextVNode()), _ctx.hasAddSlot ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_2$o, [vue.createElementVNode("button", {
10319
- "data-test": "f-crud-dataset-add-button",
10320
- type: "button",
10321
- class: "button button--tertiary crud-dataset__add-button",
10322
- onClick: _cache[0] || (_cache[0] = ($event) => _ctx.createItem())
10323
- }, [vue.createVNode(_component_f_icon, {
10324
- class: "button__icon",
10325
- name: "plus"
10326
- }), _cache[1] || (_cache[1] = vue.createTextVNode()), vue.renderSlot(_ctx.$slots, "add-button", {}, () => [vue.createTextVNode(vue.toDisplayString(_ctx.$t("fkui.crud-dataset.button.add", "Lägg till ny")), 1)])])])) : vue.createCommentVNode("", true), _cache[6] || (_cache[6] = vue.createTextVNode()), vue.createVNode(_component_f_form_modal, {
10327
- "is-open": _ctx.isFormModalOpen,
10328
- "aria-close-text": _ctx.$t("fkui.crud-dataset.modal.close", "Stäng"),
10329
- buttons: _ctx.formModalButtons,
10330
- "use-error-list": false,
10331
- "before-submit": _ctx.beforeSubmit,
10332
- "before-validation": _ctx.beforeValidation,
10333
- "on-cancel": _ctx.onCancel,
10334
- onClose: _ctx.onModalClose,
10335
- onCancel: _ctx.onCancel,
10336
- onSubmit: _ctx.onFormModalSubmit
10337
- }, {
10338
- header: vue.withCtx(() => [vue.createTextVNode(vue.toDisplayString(_ctx.formModalHeader), 1)]),
10339
- "input-text-fields": vue.withCtx(() => [_ctx.operation === _ctx.Operation.ADD ? vue.renderSlot(_ctx.$slots, "add", vue.normalizeProps(vue.mergeProps({
10340
- key: 0
10341
- }, {
10342
- item: _ctx.item
10343
- }))) : vue.createCommentVNode("", true), _cache[2] || (_cache[2] = vue.createTextVNode()), _ctx.operation === _ctx.Operation.MODIFY ? vue.renderSlot(_ctx.$slots, "modify", vue.normalizeProps(vue.mergeProps({
10344
- key: 1
10345
- }, {
10346
- item: _ctx.item
10347
- }))) : vue.createCommentVNode("", true)]),
10348
- _: 3
10349
- }, 8, ["is-open", "aria-close-text", "buttons", "before-submit", "before-validation", "on-cancel", "onClose", "onCancel", "onSubmit"]), _cache[7] || (_cache[7] = vue.createTextVNode()), vue.createVNode(_component_f_confirm_modal, {
10350
- "is-open": _ctx.isConfirmModalOpen,
10351
- buttons: _ctx.confirmDeleteButtons,
10352
- onConfirm: _ctx.onDeleteConfirm,
10353
- onClose: _ctx.onDeleteClose
10354
- }, {
10355
- heading: vue.withCtx(() => [vue.createTextVNode(vue.toDisplayString(_ctx.deleteModalHeader), 1)]),
10356
- content: vue.withCtx(() => [vue.renderSlot(_ctx.$slots, "delete", vue.normalizeProps(vue.guardReactiveProps({
10357
- item: _ctx.item
10358
- })))]),
10359
- _: 3
10360
- }, 8, ["is-open", "buttons", "onConfirm", "onClose"])]);
10361
- }
10362
- const FCrudDataset = /* @__PURE__ */ _export_sfc(_sfc_main$I, [["render", _sfc_render$w]]);
10363
10351
  function FCrudDatasetInjected() {
10364
10352
  return {
10365
10353
  delete: vue.inject("delete"),
10366
10354
  modify: vue.inject("modify")
10367
10355
  };
10368
10356
  }
10369
- const _sfc_main$H = vue.defineComponent({
10357
+ const _sfc_main$I = vue.defineComponent({
10370
10358
  name: "FCrudButton",
10371
10359
  components: {
10372
10360
  FIcon
@@ -10422,11 +10410,11 @@ const _sfc_main$H = vue.defineComponent({
10422
10410
  }
10423
10411
  }
10424
10412
  });
10425
- const _hoisted_1$v = {
10413
+ const _hoisted_1$w = {
10426
10414
  key: 1,
10427
10415
  class: "sr-only"
10428
10416
  };
10429
- function _sfc_render$v(_ctx, _cache, $props, $setup, $data, $options) {
10417
+ function _sfc_render$r(_ctx, _cache, $props, $setup, $data, $options) {
10430
10418
  const _component_f_icon = vue.resolveComponent("f-icon");
10431
10419
  return vue.openBlock(), vue.createElementBlock("button", {
10432
10420
  type: "button",
@@ -10436,11 +10424,11 @@ function _sfc_render$v(_ctx, _cache, $props, $setup, $data, $options) {
10436
10424
  key: 0,
10437
10425
  class: "button__icon",
10438
10426
  name: _ctx.iconName
10439
- }, null, 8, ["name"])) : vue.createCommentVNode("", true), _cache[1] || (_cache[1] = vue.createTextVNode()), !_ctx.label ? (vue.openBlock(), vue.createElementBlock("span", _hoisted_1$v, [vue.renderSlot(_ctx.$slots, "default", {}, () => [vue.createTextVNode(vue.toDisplayString(_ctx.buttonText), 1)])])) : vue.createCommentVNode("", true), _cache[2] || (_cache[2] = vue.createTextVNode()), _ctx.label ? vue.renderSlot(_ctx.$slots, "default", {
10427
+ }, null, 8, ["name"])) : vue.createCommentVNode("", true), _cache[1] || (_cache[1] = vue.createTextVNode()), !_ctx.label ? (vue.openBlock(), vue.createElementBlock("span", _hoisted_1$w, [vue.renderSlot(_ctx.$slots, "default", {}, () => [vue.createTextVNode(vue.toDisplayString(_ctx.buttonText), 1)])])) : vue.createCommentVNode("", true), _cache[2] || (_cache[2] = vue.createTextVNode()), _ctx.label ? vue.renderSlot(_ctx.$slots, "default", {
10440
10428
  key: 2
10441
10429
  }, () => [vue.createTextVNode(vue.toDisplayString(_ctx.buttonText), 1)]) : vue.createCommentVNode("", true)]);
10442
10430
  }
10443
- const FCrudButton = /* @__PURE__ */ _export_sfc(_sfc_main$H, [["render", _sfc_render$v]]);
10431
+ const FCrudButton = /* @__PURE__ */ _export_sfc(_sfc_main$I, [["render", _sfc_render$r]]);
10444
10432
  function ActivateItemInjected() {
10445
10433
  return {
10446
10434
  registerCallbackAfterItemAdd: vue.inject("registerCallbackAfterItemAdd", () => void 0),
@@ -10524,7 +10512,7 @@ function FTableInjected() {
10524
10512
  renderColumns: vue.inject("renderColumns", false)
10525
10513
  };
10526
10514
  }
10527
- const _sfc_main$G = vue.defineComponent({
10515
+ const _sfc_main$H = vue.defineComponent({
10528
10516
  name: "FTableColumn",
10529
10517
  inheritAttrs: false,
10530
10518
  props: {
@@ -10665,7 +10653,7 @@ const _sfc_main$G = vue.defineComponent({
10665
10653
  });
10666
10654
  }
10667
10655
  });
10668
- function _sfc_render$u(_ctx, _cache, $props, $setup, $data, $options) {
10656
+ function _sfc_render$q(_ctx, _cache, $props, $setup, $data, $options) {
10669
10657
  return _ctx.renderColumns && _ctx.visible ? (vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(_ctx.tagName), vue.mergeProps({
10670
10658
  key: 0,
10671
10659
  class: _ctx.classes,
@@ -10677,7 +10665,7 @@ function _sfc_render$u(_ctx, _cache, $props, $setup, $data, $options) {
10677
10665
  _: 3
10678
10666
  }, 16, ["class", "scope"])) : vue.createCommentVNode("", true);
10679
10667
  }
10680
- const FTableColumn = /* @__PURE__ */ _export_sfc(_sfc_main$G, [["render", _sfc_render$u]]);
10668
+ const FTableColumn = /* @__PURE__ */ _export_sfc(_sfc_main$H, [["render", _sfc_render$q]]);
10681
10669
  function FSortFilterDatasetInjected() {
10682
10670
  return {
10683
10671
  sort: vue.inject("sort", () => void 0),
@@ -10685,7 +10673,7 @@ function FSortFilterDatasetInjected() {
10685
10673
  registerCallbackOnMount: vue.inject("registerCallbackOnMount", () => void 0)
10686
10674
  };
10687
10675
  }
10688
- const _sfc_main$F = vue.defineComponent({
10676
+ const _sfc_main$G = vue.defineComponent({
10689
10677
  name: "FLabel",
10690
10678
  components: {
10691
10679
  FIcon
@@ -10724,7 +10712,7 @@ const _sfc_main$F = vue.defineComponent({
10724
10712
  }
10725
10713
  }
10726
10714
  });
10727
- const _hoisted_1$u = {
10715
+ const _hoisted_1$v = {
10728
10716
  key: 0
10729
10717
  };
10730
10718
  const _hoisted_2$n = {
@@ -10742,9 +10730,9 @@ const _hoisted_7$a = {
10742
10730
  key: 0,
10743
10731
  class: "label__message label__message--error"
10744
10732
  };
10745
- function _sfc_render$t(_ctx, _cache, $props, $setup, $data, $options) {
10733
+ function _sfc_render$p(_ctx, _cache, $props, $setup, $data, $options) {
10746
10734
  const _component_f_icon = vue.resolveComponent("f-icon");
10747
- return _ctx.$slots.tooltip ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_1$u, [_ctx.hasDefaultSlot ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_2$n, [vue.createElementVNode("label", {
10735
+ return _ctx.$slots.tooltip ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_1$v, [_ctx.hasDefaultSlot ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_2$n, [vue.createElementVNode("label", {
10748
10736
  class: "label",
10749
10737
  for: _ctx.forProperty
10750
10738
  }, [vue.renderSlot(_ctx.$slots, "default")], 8, _hoisted_3$j)], 512)) : vue.createCommentVNode("", true), _cache[2] || (_cache[2] = vue.createTextVNode()), vue.renderSlot(_ctx.$slots, "tooltip"), _cache[3] || (_cache[3] = vue.createTextVNode()), _ctx.hasDescriptionSlot || _ctx.hasErrorMessageSlot ? (vue.openBlock(), vue.createElementBlock("label", {
@@ -10769,11 +10757,11 @@ function _sfc_render$t(_ctx, _cache, $props, $setup, $data, $options) {
10769
10757
  name: "error"
10770
10758
  }), _cache[4] || (_cache[4] = vue.createTextVNode()), vue.renderSlot(_ctx.$slots, "error-message")])) : vue.createCommentVNode("", true)], 8, _hoisted_6$b));
10771
10759
  }
10772
- const FLabel = /* @__PURE__ */ _export_sfc(_sfc_main$F, [["render", _sfc_render$t]]);
10760
+ const FLabel = /* @__PURE__ */ _export_sfc(_sfc_main$G, [["render", _sfc_render$p]]);
10773
10761
  function resolveWidthClass$1(words, inline) {
10774
10762
  return inline ? void 0 : words.split(" ").map((word) => `i-width-${word}`).join(" ");
10775
10763
  }
10776
- const _sfc_main$E = vue.defineComponent({
10764
+ const _sfc_main$F = vue.defineComponent({
10777
10765
  name: "FSelectField",
10778
10766
  components: {
10779
10767
  FIcon,
@@ -10904,8 +10892,8 @@ const _sfc_main$E = vue.defineComponent({
10904
10892
  }
10905
10893
  }
10906
10894
  });
10907
- const _hoisted_1$t = ["id"];
10908
- function _sfc_render$s(_ctx, _cache, $props, $setup, $data, $options) {
10895
+ const _hoisted_1$u = ["id"];
10896
+ function _sfc_render$o(_ctx, _cache, $props, $setup, $data, $options) {
10909
10897
  const _component_f_label = vue.resolveComponent("f-label");
10910
10898
  const _component_f_icon = vue.resolveComponent("f-icon");
10911
10899
  return vue.openBlock(), vue.createElementBlock("div", {
@@ -10942,7 +10930,7 @@ function _sfc_render$s(_ctx, _cache, $props, $setup, $data, $options) {
10942
10930
  id: _ctx.id,
10943
10931
  "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.vModel = $event),
10944
10932
  class: "select-field__select"
10945
- }, _ctx.attrs), [vue.renderSlot(_ctx.$slots, "default")], 16, _hoisted_1$t), [[vue.vModelSelect, _ctx.vModel]]), _cache[5] || (_cache[5] = vue.createTextVNode()), _ctx.hasError && _ctx.textFieldTableMode ? (vue.openBlock(), vue.createBlock(_component_f_icon, {
10933
+ }, _ctx.attrs), [vue.renderSlot(_ctx.$slots, "default")], 16, _hoisted_1$u), [[vue.vModelSelect, _ctx.vModel]]), _cache[5] || (_cache[5] = vue.createTextVNode()), _ctx.hasError && _ctx.textFieldTableMode ? (vue.openBlock(), vue.createBlock(_component_f_icon, {
10946
10934
  key: 0,
10947
10935
  ref: "icon",
10948
10936
  class: "text-field__icon input-icon select-field__error-popup-icon",
@@ -10952,7 +10940,7 @@ function _sfc_render$s(_ctx, _cache, $props, $setup, $data, $options) {
10952
10940
  name: "arrow-down"
10953
10941
  })], 2)], 34);
10954
10942
  }
10955
- const FSelectField = /* @__PURE__ */ _export_sfc(_sfc_main$E, [["render", _sfc_render$s]]);
10943
+ const FSelectField = /* @__PURE__ */ _export_sfc(_sfc_main$F, [["render", _sfc_render$o]]);
10956
10944
  function resolveWidthClass(words, inline) {
10957
10945
  return inline ? void 0 : words.split(" ").map((word) => `i-width-${word}`).join(" ");
10958
10946
  }
@@ -10996,14 +10984,14 @@ function useTextFieldSetup(props) {
10996
10984
  closeDropdown
10997
10985
  };
10998
10986
  }
10999
- const _sfc_main$D = vue.defineComponent({
10987
+ const _sfc_main$E = vue.defineComponent({
11000
10988
  name: "FTextField",
11001
10989
  components: {
11002
10990
  FLabel,
11003
10991
  FIcon,
11004
10992
  IPopupError,
11005
- IComboboxDropdown: _sfc_main$O,
11006
- IComboboxToggleButton: _sfc_main$N
10993
+ IComboboxDropdown: _sfc_main$P,
10994
+ IComboboxToggleButton: _sfc_main$O
11007
10995
  },
11008
10996
  inheritAttrs: false,
11009
10997
  props: {
@@ -11334,7 +11322,7 @@ const _sfc_main$D = vue.defineComponent({
11334
11322
  }
11335
11323
  }
11336
11324
  });
11337
- const _hoisted_1$s = {
11325
+ const _hoisted_1$t = {
11338
11326
  key: 0
11339
11327
  };
11340
11328
  const _hoisted_2$m = {
@@ -11357,7 +11345,7 @@ const _hoisted_7$9 = {
11357
11345
  key: 3,
11358
11346
  class: "text-field__append-inner"
11359
11347
  };
11360
- function _sfc_render$r(_ctx, _cache, $props, $setup, $data, $options) {
11348
+ function _sfc_render$n(_ctx, _cache, $props, $setup, $data, $options) {
11361
11349
  const _component_f_label = vue.resolveComponent("f-label");
11362
11350
  const _component_f_icon = vue.resolveComponent("f-icon");
11363
11351
  const _component_i_popup_error = vue.resolveComponent("i-popup-error");
@@ -11371,7 +11359,7 @@ function _sfc_render$r(_ctx, _cache, $props, $setup, $data, $options) {
11371
11359
  for: _ctx.id,
11372
11360
  class: vue.normalizeClass(_ctx.labelClass)
11373
11361
  }, vue.createSlots({
11374
- default: vue.withCtx(() => [vue.renderSlot(_ctx.$slots, "default", {}, () => [_ctx.defaultText !== "" ? (vue.openBlock(), vue.createElementBlock("span", _hoisted_1$s, vue.toDisplayString(_ctx.defaultText), 1)) : vue.createCommentVNode("", true)])]),
11362
+ default: vue.withCtx(() => [vue.renderSlot(_ctx.$slots, "default", {}, () => [_ctx.defaultText !== "" ? (vue.openBlock(), vue.createElementBlock("span", _hoisted_1$t, vue.toDisplayString(_ctx.defaultText), 1)) : vue.createCommentVNode("", true)])]),
11375
11363
  description: vue.withCtx(({
11376
11364
  descriptionClass,
11377
11365
  formatDescriptionClass
@@ -11440,8 +11428,8 @@ function _sfc_render$r(_ctx, _cache, $props, $setup, $data, $options) {
11440
11428
  onClose: _ctx.onDropdownClose
11441
11429
  }, null, 8, ["id", "is-open", "options", "active-option", "active-option-id", "input-node", "onSelect", "onClose"])) : vue.createCommentVNode("", true)], 2);
11442
11430
  }
11443
- const FTextField = /* @__PURE__ */ _export_sfc(_sfc_main$D, [["render", _sfc_render$r]]);
11444
- const _sfc_main$C = vue.defineComponent({
11431
+ const FTextField = /* @__PURE__ */ _export_sfc(_sfc_main$E, [["render", _sfc_render$n]]);
11432
+ const _sfc_main$D = vue.defineComponent({
11445
11433
  name: "FEmailTextField",
11446
11434
  components: {
11447
11435
  FTextField
@@ -11557,10 +11545,10 @@ const _sfc_main$C = vue.defineComponent({
11557
11545
  }
11558
11546
  }
11559
11547
  });
11560
- const _hoisted_1$r = {
11548
+ const _hoisted_1$s = {
11561
11549
  key: 0
11562
11550
  };
11563
- function _sfc_render$q(_ctx, _cache, $props, $setup, $data, $options) {
11551
+ function _sfc_render$m(_ctx, _cache, $props, $setup, $data, $options) {
11564
11552
  const _component_f_text_field = vue.resolveComponent("f-text-field");
11565
11553
  return vue.openBlock(), vue.createElementBlock("div", null, [vue.createVNode(_component_f_text_field, vue.mergeProps({
11566
11554
  id: _ctx.id,
@@ -11574,7 +11562,7 @@ function _sfc_render$q(_ctx, _cache, $props, $setup, $data, $options) {
11574
11562
  onValidity: _ctx.onValidity,
11575
11563
  onPendingValidity: _ctx.onPendingValidity
11576
11564
  }), {
11577
- "error-message": vue.withCtx(() => [_ctx.showPasteErrorMessage ? (vue.openBlock(), vue.createElementBlock("span", _hoisted_1$r, vue.toDisplayString(_ctx.pasteErrorText), 1)) : vue.createCommentVNode("", true)]),
11565
+ "error-message": vue.withCtx(() => [_ctx.showPasteErrorMessage ? (vue.openBlock(), vue.createElementBlock("span", _hoisted_1$s, vue.toDisplayString(_ctx.pasteErrorText), 1)) : vue.createCommentVNode("", true)]),
11578
11566
  default: vue.withCtx(() => [vue.renderSlot(_ctx.$slots, "default", {}, () => [vue.createTextVNode(vue.toDisplayString(_ctx.defaultText), 1)]), _cache[2] || (_cache[2] = vue.createTextVNode())]),
11579
11567
  _: 3
11580
11568
  }, 16, ["id", "maxlength", "model-value", "onChange", "onBlur", "onUpdate:modelValue", "onValidity", "onPendingValidity"]), _cache[3] || (_cache[3] = vue.createTextVNode()), _ctx.extendedValidation ? (vue.openBlock(), vue.createBlock(_component_f_text_field, {
@@ -11590,8 +11578,8 @@ function _sfc_render$q(_ctx, _cache, $props, $setup, $data, $options) {
11590
11578
  _: 3
11591
11579
  }, 8, ["modelValue", "maxlength", "onPaste"])) : vue.createCommentVNode("", true)]);
11592
11580
  }
11593
- const FEmailTextField = /* @__PURE__ */ _export_sfc(_sfc_main$C, [["render", _sfc_render$q]]);
11594
- const _sfc_main$B = vue.defineComponent({
11581
+ const FEmailTextField = /* @__PURE__ */ _export_sfc(_sfc_main$D, [["render", _sfc_render$m]]);
11582
+ const _sfc_main$C = vue.defineComponent({
11595
11583
  name: "FPhoneTextField",
11596
11584
  components: {
11597
11585
  FTextField
@@ -11691,7 +11679,7 @@ const _sfc_main$B = vue.defineComponent({
11691
11679
  }
11692
11680
  }
11693
11681
  });
11694
- function _sfc_render$p(_ctx, _cache, $props, $setup, $data, $options) {
11682
+ function _sfc_render$l(_ctx, _cache, $props, $setup, $data, $options) {
11695
11683
  const _component_f_text_field = vue.resolveComponent("f-text-field");
11696
11684
  return vue.openBlock(), vue.createElementBlock("div", null, [vue.createVNode(_component_f_text_field, vue.mergeProps({
11697
11685
  id: _ctx.id,
@@ -11718,8 +11706,8 @@ function _sfc_render$p(_ctx, _cache, $props, $setup, $data, $options) {
11718
11706
  _: 3
11719
11707
  }, 8, ["modelValue", "maxlength"])) : vue.createCommentVNode("", true)]);
11720
11708
  }
11721
- const FPhoneTextField = /* @__PURE__ */ _export_sfc(_sfc_main$B, [["render", _sfc_render$p]]);
11722
- const _sfc_main$A = vue.defineComponent({
11709
+ const FPhoneTextField = /* @__PURE__ */ _export_sfc(_sfc_main$C, [["render", _sfc_render$l]]);
11710
+ const _sfc_main$B = vue.defineComponent({
11723
11711
  name: "FCurrencyTextField",
11724
11712
  extends: FTextField,
11725
11713
  mixins: [TranslationMixin],
@@ -11754,7 +11742,7 @@ const _sfc_main$A = vue.defineComponent({
11754
11742
  logic.ValidationService.validateElement(inputElement);
11755
11743
  }
11756
11744
  });
11757
- const _sfc_main$z = vue.defineComponent({
11745
+ const _sfc_main$A = vue.defineComponent({
11758
11746
  name: "FSearchTextField",
11759
11747
  components: {
11760
11748
  FTextField,
@@ -11814,10 +11802,10 @@ const _sfc_main$z = vue.defineComponent({
11814
11802
  }
11815
11803
  }
11816
11804
  });
11817
- const _hoisted_1$q = {
11805
+ const _hoisted_1$r = {
11818
11806
  class: "sr-only"
11819
11807
  };
11820
- function _sfc_render$o(_ctx, _cache, $props, $setup, $data, $options) {
11808
+ function _sfc_render$k(_ctx, _cache, $props, $setup, $data, $options) {
11821
11809
  const _component_f_icon = vue.resolveComponent("f-icon");
11822
11810
  const _component_f_text_field = vue.resolveComponent("f-text-field");
11823
11811
  return vue.openBlock(), vue.createElementBlock("div", null, [vue.createVNode(_component_f_text_field, vue.mergeProps({
@@ -11863,12 +11851,12 @@ function _sfc_render$o(_ctx, _cache, $props, $setup, $data, $options) {
11863
11851
  }, [vue.createVNode(_component_f_icon, {
11864
11852
  name: "cross",
11865
11853
  class: "clear-button__icon"
11866
- }), _cache[1] || (_cache[1] = vue.createTextVNode()), vue.createElementVNode("span", _hoisted_1$q, vue.toDisplayString(_ctx.clearableScreenReaderText), 1)])]),
11854
+ }), _cache[1] || (_cache[1] = vue.createTextVNode()), vue.createElementVNode("span", _hoisted_1$r, vue.toDisplayString(_ctx.clearableScreenReaderText), 1)])]),
11867
11855
  key: "1"
11868
11856
  } : void 0]), 1040, ["id", "maxlength", "model-value", "onChange", "onInput", "onBlur", "onUpdate"])]);
11869
11857
  }
11870
- const FSearchTextField = /* @__PURE__ */ _export_sfc(_sfc_main$z, [["render", _sfc_render$o]]);
11871
- const _sfc_main$y = vue.defineComponent({
11858
+ const FSearchTextField = /* @__PURE__ */ _export_sfc(_sfc_main$A, [["render", _sfc_render$k]]);
11859
+ const _sfc_main$z = vue.defineComponent({
11872
11860
  name: "FBankAccountNumberTextField",
11873
11861
  extends: FTextField,
11874
11862
  mixins: [TranslationMixin],
@@ -11897,7 +11885,7 @@ const _sfc_main$y = vue.defineComponent({
11897
11885
  logic.ValidationService.validateElement(inputElement);
11898
11886
  }
11899
11887
  });
11900
- const _sfc_main$x = vue.defineComponent({
11888
+ const _sfc_main$y = vue.defineComponent({
11901
11889
  name: "FBankgiroTextField",
11902
11890
  extends: FTextField,
11903
11891
  mixins: [TranslationMixin],
@@ -11929,7 +11917,7 @@ const _sfc_main$x = vue.defineComponent({
11929
11917
  logic.ValidationService.validateElement(inputElement);
11930
11918
  }
11931
11919
  });
11932
- const _sfc_main$w = vue.defineComponent({
11920
+ const _sfc_main$x = vue.defineComponent({
11933
11921
  name: "FClearingnumberTextField",
11934
11922
  extends: FTextField,
11935
11923
  mixins: [TranslationMixin],
@@ -11961,7 +11949,7 @@ const _sfc_main$w = vue.defineComponent({
11961
11949
  function defaultFormatter$1(modelValue) {
11962
11950
  return logic.formatNumber(modelValue, this.decimals);
11963
11951
  }
11964
- const _sfc_main$v = vue.defineComponent({
11952
+ const _sfc_main$w = vue.defineComponent({
11965
11953
  name: "FNumericTextField",
11966
11954
  extends: FTextField,
11967
11955
  props: {
@@ -11998,7 +11986,7 @@ const _sfc_main$v = vue.defineComponent({
11998
11986
  logic.ValidationService.validateElement(inputElement);
11999
11987
  }
12000
11988
  });
12001
- const _sfc_main$u = vue.defineComponent({
11989
+ const _sfc_main$v = vue.defineComponent({
12002
11990
  name: "FPersonnummerTextField",
12003
11991
  extends: FTextField,
12004
11992
  mixins: [TranslationMixin],
@@ -12038,7 +12026,7 @@ const _sfc_main$u = vue.defineComponent({
12038
12026
  logic.ValidationService.validateElement(inputElement);
12039
12027
  }
12040
12028
  });
12041
- const _sfc_main$t = vue.defineComponent({
12029
+ const _sfc_main$u = vue.defineComponent({
12042
12030
  name: "FPlusgiroTextField",
12043
12031
  extends: FTextField,
12044
12032
  mixins: [TranslationMixin],
@@ -12070,7 +12058,7 @@ const _sfc_main$t = vue.defineComponent({
12070
12058
  logic.ValidationService.validateElement(inputElement);
12071
12059
  }
12072
12060
  });
12073
- const _sfc_main$s = vue.defineComponent({
12061
+ const _sfc_main$t = vue.defineComponent({
12074
12062
  name: "FPostalCodeTextField",
12075
12063
  extends: FTextField,
12076
12064
  mixins: [TranslationMixin],
@@ -12107,7 +12095,7 @@ const _sfc_main$s = vue.defineComponent({
12107
12095
  function defaultFormatter(modelValue) {
12108
12096
  return logic.formatPercent(modelValue, this.decimals);
12109
12097
  }
12110
- const _sfc_main$r = vue.defineComponent({
12098
+ const _sfc_main$s = vue.defineComponent({
12111
12099
  name: "FPercentTextField",
12112
12100
  extends: FTextField,
12113
12101
  mixins: [TranslationMixin],
@@ -12155,7 +12143,7 @@ const _sfc_main$r = vue.defineComponent({
12155
12143
  logic.ValidationService.validateElement(inputElement);
12156
12144
  }
12157
12145
  });
12158
- const _sfc_main$q = vue.defineComponent({
12146
+ const _sfc_main$r = vue.defineComponent({
12159
12147
  name: "FOrganisationsnummerTextField",
12160
12148
  extends: FTextField,
12161
12149
  mixins: [TranslationMixin],
@@ -12263,39 +12251,28 @@ function filter(list, filterAttributes, searchString) {
12263
12251
  const searchTerms = searchString.split(/\s+/).map((word) => word.toLocaleLowerCase());
12264
12252
  return list.filter((item) => includesAllSearchTerms(item, filterAttributes, searchTerms));
12265
12253
  }
12266
- const _sfc_main$p = vue.defineComponent({
12267
- name: "FSortFilterDataset",
12268
- components: {
12269
- FSelectField,
12270
- FTextField,
12271
- FIcon,
12272
- IFlex,
12273
- IFlexItem
12274
- },
12275
- mixins: [TranslationMixin],
12276
- provide() {
12277
- return {
12278
- sort: (attribute, ascending) => {
12279
- const foundAttribute = this.sortOrders.find((item) => item.attribute === attribute && item.ascending === ascending);
12280
- if (foundAttribute) {
12281
- this.sortAttribute = foundAttribute;
12282
- } else {
12283
- this.sortAttribute = {
12284
- attribute: "",
12285
- ascending: false
12286
- };
12287
- }
12288
- this.sortFilterData();
12289
- this.$emit("usedSortAttributes", this.sortAttribute);
12290
- },
12291
- registerCallbackOnSort: (callback) => {
12292
- this.tableCallbackOnSort = callback;
12293
- },
12294
- registerCallbackOnMount: (callback) => {
12295
- this.tableCallbackSortableColumns = callback;
12296
- }
12297
- };
12298
- },
12254
+ const _hoisted_1$q = {
12255
+ class: "sort-filter-dataset"
12256
+ };
12257
+ const _hoisted_2$l = {
12258
+ class: "sort-filter-dataset__search"
12259
+ };
12260
+ const _hoisted_3$h = {
12261
+ class: "sr-only"
12262
+ };
12263
+ const _hoisted_4$e = ["title"];
12264
+ const _hoisted_5$b = {
12265
+ class: "sr-only"
12266
+ };
12267
+ const _hoisted_6$9 = {
12268
+ value: {
12269
+ attribute: "",
12270
+ ascending: false
12271
+ }
12272
+ };
12273
+ const _hoisted_7$8 = ["value"];
12274
+ const _sfc_main$q = /* @__PURE__ */ vue.defineComponent({
12275
+ __name: "FSortFilterDataset",
12299
12276
  props: {
12300
12277
  /**
12301
12278
  * The data that you wish to sort or filter.
@@ -12344,7 +12321,7 @@ const _sfc_main$p = vue.defineComponent({
12344
12321
  placeholderFilter: {
12345
12322
  type: String,
12346
12323
  required: false,
12347
- default: TranslationMixin.methods.$t("fkui.sort-filter-dataset.placeholder.filter", "Sök")
12324
+ default: logic.TranslationService.provider.translate("fkui.sort-filter-dataset.placeholder.filter", "Sök")
12348
12325
  },
12349
12326
  /**
12350
12327
  * The order the data will be sorted by if defaultSortAttribute has been set.
@@ -12356,243 +12333,237 @@ const _sfc_main$p = vue.defineComponent({
12356
12333
  }
12357
12334
  },
12358
12335
  emits: ["datasetSorted", "usedSortAttributes"],
12359
- data() {
12360
- return {
12361
- searchString: "",
12362
- sortAttribute: {
12363
- attribute: "",
12364
- ascending: false
12365
- },
12366
- sortFilterResult: [],
12367
- tableCallbackOnSort: () => {
12368
- return;
12369
- },
12370
- tableCallbackSortableColumns: () => {
12371
- return;
12372
- }
12336
+ setup(__props, {
12337
+ emit: __emit
12338
+ }) {
12339
+ const $t2 = useTranslate();
12340
+ const searchString = vue.ref("");
12341
+ const sortAttribute = vue.ref({
12342
+ attribute: "",
12343
+ name: "",
12344
+ ascendingName: "",
12345
+ ascending: false,
12346
+ id: 0
12347
+ });
12348
+ const sortFilterResult = vue.ref([]);
12349
+ const debouncedFilterResultset = logic.debounce(filterResultset, 250);
12350
+ let tableCallbackOnSort = () => {
12373
12351
  };
12374
- },
12375
- computed: {
12376
- showClearButton() {
12377
- return this.searchString.length > 0;
12378
- },
12379
- sortOrders() {
12352
+ let tableCallbackSortableColumns = () => {
12353
+ };
12354
+ const props = __props;
12355
+ const emit = __emit;
12356
+ const showClearButton = vue.computed(() => {
12357
+ return searchString.value.length > 0;
12358
+ });
12359
+ const sortOrders = vue.computed(() => {
12380
12360
  const arr = [];
12381
12361
  let id = 0;
12382
- Object.keys(this.sortableAttributes).forEach((key) => {
12362
+ Object.keys(props.sortableAttributes).forEach((key) => {
12383
12363
  arr.push({
12384
12364
  attribute: key,
12385
- name: this.sortableAttributes[key],
12386
- ascendingName: this.$t("fkui.sort-filter-dataset.label.ascending", "stigande"),
12365
+ name: props.sortableAttributes[key],
12366
+ ascendingName: $t2("fkui.sort-filter-dataset.label.ascending", "stigande"),
12387
12367
  ascending: true,
12388
12368
  id: id++
12389
12369
  });
12390
12370
  arr.push({
12391
12371
  attribute: key,
12392
- name: this.sortableAttributes[key],
12393
- ascendingName: this.$t("fkui.sort-filter-dataset.label.descending", "fallande"),
12372
+ name: props.sortableAttributes[key],
12373
+ ascendingName: $t2("fkui.sort-filter-dataset.label.descending", "fallande"),
12394
12374
  ascending: false,
12395
12375
  id: id++
12396
12376
  });
12397
12377
  });
12398
12378
  return arr;
12399
- },
12400
- filterAttributes() {
12401
- return Object.keys(this.sortableAttributes);
12402
- }
12403
- },
12404
- watch: {
12405
- data: {
12406
- immediate: true,
12407
- deep: true,
12408
- handler: function() {
12409
- if (this.defaultSortAttribute !== "") {
12410
- const foundAttribute = this.sortOrders.find((item) => item.attribute === this.defaultSortAttribute && item.ascending === this.defaultSortAscending);
12411
- if (foundAttribute) {
12412
- this.sortAttribute = foundAttribute;
12413
- }
12379
+ });
12380
+ const filterAttributes = vue.computed(() => {
12381
+ return Object.keys(props.sortableAttributes);
12382
+ });
12383
+ vue.provide("sort", (attribute, ascending) => {
12384
+ const foundAttribute = sortOrders.value.find((item) => {
12385
+ return item.attribute === attribute && item.ascending === ascending;
12386
+ });
12387
+ if (foundAttribute) {
12388
+ sortAttribute.value = foundAttribute;
12389
+ } else {
12390
+ sortAttribute.value = {
12391
+ attribute: "",
12392
+ ascending: false
12393
+ };
12394
+ }
12395
+ sortFilterData();
12396
+ emit("usedSortAttributes", sortAttribute.value);
12397
+ });
12398
+ vue.provide("registerCallbackOnSort", (callback) => {
12399
+ tableCallbackOnSort = callback;
12400
+ });
12401
+ vue.provide("registerCallbackOnMount", (callback) => {
12402
+ tableCallbackSortableColumns = callback;
12403
+ });
12404
+ vue.onMounted(() => {
12405
+ tableCallbackSortableColumns(Object.keys(props.sortableAttributes));
12406
+ });
12407
+ vue.watch(() => props.data, () => {
12408
+ if (props.defaultSortAttribute !== "") {
12409
+ const foundAttribute = sortOrders.value.find((item) => {
12410
+ return item.attribute === props.defaultSortAttribute && item.ascending === props.defaultSortAscending;
12411
+ });
12412
+ if (foundAttribute) {
12413
+ sortAttribute.value = foundAttribute;
12414
12414
  }
12415
- this.sortFilterData();
12416
12415
  }
12417
- }
12418
- },
12419
- created() {
12420
- this.debouncedFilterResultset = logic.debounce(this.filterResultset, 250).bind(this);
12421
- },
12422
- mounted() {
12423
- this.tableCallbackSortableColumns(Object.keys(this.sortableAttributes));
12424
- },
12425
- methods: {
12426
- sortFilterData() {
12427
- const filteredData = filter(this.data, this.filterAttributes, this.searchString);
12428
- if (this.sortAttribute.attribute === "") {
12429
- this.sortFilterResult = filteredData;
12416
+ sortFilterData();
12417
+ }, {
12418
+ immediate: true,
12419
+ deep: true
12420
+ });
12421
+ function sortFilterData() {
12422
+ const filteredData = filter(props.data, filterAttributes.value, searchString.value);
12423
+ if (sortAttribute.value.attribute === "") {
12424
+ sortFilterResult.value = filteredData;
12430
12425
  } else {
12431
- this.sortFilterResult = sort([...filteredData], this.sortAttribute.attribute, this.sortAttribute.ascending);
12426
+ sortFilterResult.value = sort([...filteredData], sortAttribute.value.attribute, sortAttribute.value.ascending);
12432
12427
  }
12433
- this.$nextTick(() => {
12434
- this.tableCallbackOnSort(this.sortAttribute.attribute, this.sortAttribute.ascending);
12428
+ vue.nextTick(() => {
12429
+ tableCallbackOnSort(sortAttribute.value.attribute, sortAttribute.value.ascending);
12435
12430
  });
12436
- this.$emit("datasetSorted", this.sortFilterResult);
12437
- },
12438
- onChangeSortAttribute() {
12439
- this.sortFilterData();
12440
- this.$emit("usedSortAttributes", this.sortAttribute);
12441
- },
12442
- onSearchInput(event) {
12443
- this.searchString = event.target.value;
12444
- this.debouncedFilterResultset();
12445
- },
12446
- onClickClearSearch() {
12447
- this.searchString = "";
12448
- this.sortFilterData();
12449
- const input = this.$el.querySelector(".text-field--inline input");
12431
+ emit("datasetSorted", sortFilterResult.value);
12432
+ }
12433
+ function onChangeSortAttribute() {
12434
+ sortFilterData();
12435
+ emit("usedSortAttributes", sortAttribute.value);
12436
+ }
12437
+ function onSearchInput(event) {
12438
+ searchString.value = event.target.value;
12439
+ debouncedFilterResultset();
12440
+ }
12441
+ function onClickClearSearch() {
12442
+ searchString.value = "";
12443
+ sortFilterData();
12444
+ const input = vue.useTemplateRef("search-field").value;
12450
12445
  logic.focus(input);
12451
- },
12452
- debouncedFilterResultset() {
12453
- },
12454
- filterResultset() {
12455
- this.sortFilterData();
12456
- if (this.searchString === "") {
12457
- logic.alertScreenReader(this.$t("fkui.sort-filter-dataset.aria-live.empty", "Sök redigera Sök tom"));
12446
+ }
12447
+ function filterResultset() {
12448
+ sortFilterData();
12449
+ if (searchString.value === "") {
12450
+ logic.alertScreenReader($t2("fkui.sort-filter-dataset.aria-live.empty", "Sök redigera Sök tom"));
12458
12451
  } else {
12459
- const searchAriaLive = this.$t("fkui.sort-filter-dataset.aria-live.search", `Din sökning på "{{ search }}" gav {{ result }} träffar.`, {
12460
- result: this.sortFilterResult.length,
12461
- search: this.searchString
12452
+ const searchAriaLive = $t2("fkui.sort-filter-dataset.aria-live.search", `Din sökning på "{{ search }}" gav {{ result }} träffar.`, {
12453
+ result: sortFilterResult.value.length,
12454
+ search: searchString.value
12462
12455
  });
12463
12456
  logic.alertScreenReader(searchAriaLive);
12464
12457
  }
12465
12458
  }
12466
- }
12467
- });
12468
- const _hoisted_1$p = {
12469
- class: "sort-filter-dataset"
12470
- };
12471
- const _hoisted_2$l = {
12472
- class: "sort-filter-dataset__search"
12473
- };
12474
- const _hoisted_3$h = {
12475
- class: "sr-only"
12476
- };
12477
- const _hoisted_4$e = ["title"];
12478
- const _hoisted_5$b = {
12479
- class: "sr-only"
12480
- };
12481
- const _hoisted_6$9 = {
12482
- value: {
12483
- attribute: "",
12484
- ascending: false
12485
- }
12486
- };
12487
- const _hoisted_7$8 = ["value"];
12488
- function _sfc_render$n(_ctx, _cache, $props, $setup, $data, $options) {
12489
- const _component_i_flex_item = vue.resolveComponent("i-flex-item");
12490
- const _component_f_icon = vue.resolveComponent("f-icon");
12491
- const _component_f_text_field = vue.resolveComponent("f-text-field");
12492
- const _component_f_select_field = vue.resolveComponent("f-select-field");
12493
- const _component_i_flex = vue.resolveComponent("i-flex");
12494
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$p, [vue.createVNode(_component_i_flex, {
12495
- collapse: "",
12496
- gap: "3x",
12497
- wrap: ""
12498
- }, {
12499
- default: vue.withCtx(() => [vue.createVNode(_component_i_flex_item, {
12500
- shrink: "",
12501
- align: "center"
12502
- }, {
12503
- default: vue.withCtx(() => [vue.renderSlot(_ctx.$slots, "header", vue.normalizeProps(vue.guardReactiveProps({
12504
- slotClass: "sort-filter-dataset__toolbar__header"
12505
- })))]),
12506
- _: 3
12507
- }), _cache[9] || (_cache[9] = vue.createTextVNode()), vue.createVNode(_component_i_flex_item, {
12508
- grow: ""
12509
- }, {
12510
- default: vue.withCtx(() => [vue.createVNode(_component_i_flex, {
12459
+ return (_ctx, _cache) => {
12460
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$q, [vue.createVNode(vue.unref(IFlex), {
12511
12461
  collapse: "",
12512
- float: "right"
12462
+ gap: "3x",
12463
+ wrap: ""
12513
12464
  }, {
12514
- default: vue.withCtx(() => [_ctx.showFilter ? (vue.openBlock(), vue.createBlock(_component_i_flex_item, {
12515
- key: 0,
12465
+ default: vue.withCtx(() => [vue.createVNode(vue.unref(IFlexItem), {
12516
12466
  shrink: "",
12517
12467
  align: "center"
12518
12468
  }, {
12519
- default: vue.withCtx(() => [vue.createElementVNode("div", _hoisted_2$l, [vue.createVNode(_component_f_icon, {
12520
- name: "search",
12521
- class: "sort-filter-dataset__search__magnify-icon"
12522
- }), _cache[4] || (_cache[4] = vue.createTextVNode()), vue.createVNode(_component_f_text_field, {
12523
- modelValue: _ctx.searchString,
12524
- "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => _ctx.searchString = $event),
12525
- inline: "",
12526
- placeholder: _ctx.placeholderFilter,
12527
- maxlength: "64",
12528
- onInput: _ctx.onSearchInput
12529
- }, {
12530
- default: vue.withCtx(() => [vue.createElementVNode("span", _hoisted_3$h, vue.toDisplayString(_ctx.placeholderFilter), 1)]),
12531
- _: 1
12532
- }, 8, ["modelValue", "placeholder", "onInput"]), _cache[5] || (_cache[5] = vue.createTextVNode()), _ctx.showClearButton ? (vue.openBlock(), vue.createElementBlock("button", {
12533
- key: 0,
12534
- type: "button",
12535
- class: "button button--discrete sort-filter-dataset__search__close-icon",
12536
- title: _ctx.$t("fkui.sort-filter-dataset.clear.filter", "Rensa sökfält"),
12537
- onClick: _cache[1] || (_cache[1] = (...args) => _ctx.onClickClearSearch && _ctx.onClickClearSearch(...args))
12538
- }, [vue.createVNode(_component_f_icon, {
12539
- name: "close"
12540
- }), _cache[3] || (_cache[3] = vue.createTextVNode()), vue.createElementVNode("span", _hoisted_5$b, vue.toDisplayString(_ctx.$t("fkui.sort-filter-dataset.clear.filter", "Rensa sökfält")), 1)], 8, _hoisted_4$e)) : vue.createCommentVNode("", true)])]),
12541
- _: 1
12542
- })) : vue.createCommentVNode("", true), _cache[8] || (_cache[8] = vue.createTextVNode()), _ctx.showSort ? (vue.openBlock(), vue.createBlock(_component_i_flex_item, {
12543
- key: 1,
12544
- shrink: "",
12545
- align: "center"
12469
+ default: vue.withCtx(() => [vue.renderSlot(_ctx.$slots, "header", vue.normalizeProps(vue.guardReactiveProps({
12470
+ slotClass: "sort-filter-dataset__toolbar__header"
12471
+ })))]),
12472
+ _: 3
12473
+ }), _cache[8] || (_cache[8] = vue.createTextVNode()), vue.createVNode(vue.unref(IFlexItem), {
12474
+ grow: ""
12546
12475
  }, {
12547
- default: vue.withCtx(() => [vue.createVNode(_component_f_select_field, {
12548
- modelValue: _ctx.sortAttribute,
12549
- "onUpdate:modelValue": _cache[2] || (_cache[2] = ($event) => _ctx.sortAttribute = $event),
12550
- class: "sort-filter-dataset__sort",
12551
- inline: "",
12552
- onChange: _ctx.onChangeSortAttribute
12476
+ default: vue.withCtx(() => [vue.createVNode(vue.unref(IFlex), {
12477
+ collapse: "",
12478
+ float: "right"
12553
12479
  }, {
12554
- label: vue.withCtx(() => [vue.createTextVNode(vue.toDisplayString(_ctx.$t("fkui.sort-filter-dataset.label.sort", "Sortera på")), 1)]),
12555
- default: vue.withCtx(() => [_cache[6] || (_cache[6] = vue.createTextVNode()), vue.createElementVNode("option", _hoisted_6$9, vue.toDisplayString(_ctx.$t("fkui.sort-filter-dataset.label.unsorted", "Välj")), 1), _cache[7] || (_cache[7] = vue.createTextVNode()), (vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(_ctx.sortOrders, (sortOrder) => {
12556
- return vue.openBlock(), vue.createElementBlock("option", {
12557
- key: sortOrder.id,
12558
- value: sortOrder
12559
- }, vue.toDisplayString(sortOrder.name) + " (" + vue.toDisplayString(sortOrder.ascendingName) + ")\n ", 9, _hoisted_7$8);
12560
- }), 128))]),
12480
+ default: vue.withCtx(() => [__props.showFilter ? (vue.openBlock(), vue.createBlock(vue.unref(IFlexItem), {
12481
+ key: 0,
12482
+ shrink: "",
12483
+ align: "center"
12484
+ }, {
12485
+ default: vue.withCtx(() => [vue.createElementVNode("div", _hoisted_2$l, [vue.createVNode(vue.unref(FIcon), {
12486
+ name: "search",
12487
+ class: "sort-filter-dataset__search__magnify-icon"
12488
+ }), _cache[3] || (_cache[3] = vue.createTextVNode()), vue.createVNode(vue.unref(FTextField), {
12489
+ ref: "search-field",
12490
+ modelValue: searchString.value,
12491
+ "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => searchString.value = $event),
12492
+ inline: "",
12493
+ placeholder: __props.placeholderFilter,
12494
+ maxlength: "64",
12495
+ onInput: onSearchInput
12496
+ }, {
12497
+ default: vue.withCtx(() => [vue.createElementVNode("span", _hoisted_3$h, vue.toDisplayString(__props.placeholderFilter), 1)]),
12498
+ _: 1
12499
+ }, 8, ["modelValue", "placeholder"]), _cache[4] || (_cache[4] = vue.createTextVNode()), showClearButton.value ? (vue.openBlock(), vue.createElementBlock("button", {
12500
+ key: 0,
12501
+ type: "button",
12502
+ class: "button button--discrete sort-filter-dataset__search__close-icon",
12503
+ title: vue.unref($t2)("fkui.sort-filter-dataset.clear.filter", "Rensa sökfält"),
12504
+ onClick: onClickClearSearch
12505
+ }, [vue.createVNode(vue.unref(FIcon), {
12506
+ name: "close"
12507
+ }), _cache[2] || (_cache[2] = vue.createTextVNode()), vue.createElementVNode("span", _hoisted_5$b, vue.toDisplayString(vue.unref($t2)("fkui.sort-filter-dataset.clear.filter", "Rensa sökfält")), 1)], 8, _hoisted_4$e)) : vue.createCommentVNode("", true)])]),
12508
+ _: 1
12509
+ })) : vue.createCommentVNode("", true), _cache[7] || (_cache[7] = vue.createTextVNode()), __props.showSort ? (vue.openBlock(), vue.createBlock(vue.unref(IFlexItem), {
12510
+ key: 1,
12511
+ shrink: "",
12512
+ align: "center"
12513
+ }, {
12514
+ default: vue.withCtx(() => [vue.createVNode(vue.unref(FSelectField), {
12515
+ modelValue: sortAttribute.value,
12516
+ "onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => sortAttribute.value = $event),
12517
+ class: "sort-filter-dataset__sort",
12518
+ inline: "",
12519
+ onChange: onChangeSortAttribute
12520
+ }, {
12521
+ label: vue.withCtx(() => [vue.createTextVNode(vue.toDisplayString(vue.unref($t2)("fkui.sort-filter-dataset.label.sort", "Sortera på")), 1)]),
12522
+ default: vue.withCtx(() => [_cache[5] || (_cache[5] = vue.createTextVNode()), vue.createElementVNode("option", _hoisted_6$9, vue.toDisplayString(vue.unref($t2)("fkui.sort-filter-dataset.label.unsorted", "Välj")), 1), _cache[6] || (_cache[6] = vue.createTextVNode()), (vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(sortOrders.value, (sortOrder) => {
12523
+ return vue.openBlock(), vue.createElementBlock("option", {
12524
+ key: sortOrder.id,
12525
+ value: sortOrder
12526
+ }, vue.toDisplayString(sortOrder.name) + " (" + vue.toDisplayString(sortOrder.ascendingName) + ")\n ", 9, _hoisted_7$8);
12527
+ }), 128))]),
12528
+ _: 1
12529
+ }, 8, ["modelValue"])]),
12530
+ _: 1
12531
+ })) : vue.createCommentVNode("", true)]),
12561
12532
  _: 1
12562
- }, 8, ["modelValue", "onChange"])]),
12533
+ })]),
12563
12534
  _: 1
12564
- })) : vue.createCommentVNode("", true)]),
12565
- _: 1
12566
- })]),
12567
- _: 1
12568
- })]),
12569
- _: 3
12570
- }), _cache[10] || (_cache[10] = vue.createTextVNode()), vue.renderSlot(_ctx.$slots, "default", vue.normalizeProps(vue.guardReactiveProps({
12571
- sortFilterResult: _ctx.sortFilterResult
12572
- })))]);
12573
- }
12574
- const FSortFilterDataset = /* @__PURE__ */ _export_sfc(_sfc_main$p, [["render", _sfc_render$n]]);
12575
- const _sfc_main$o = vue.defineComponent({
12576
- name: "FDataTable",
12577
- components: {
12578
- FIcon
12579
- },
12580
- mixins: [TranslationMixin],
12581
- provide() {
12582
- return {
12583
- addColumn: (column) => {
12584
- if (column.type === FTableColumnType.ACTION) {
12585
- throw new Error("Cannot use action column in FDataTable component");
12586
- }
12587
- this.columns = addColumn(this.columns, column);
12588
- },
12589
- setVisibilityColumn: (id, visible) => {
12590
- setVisibilityColumn(this.columns, id, visible);
12591
- },
12592
- textFieldTableMode: true
12535
+ })]),
12536
+ _: 3
12537
+ }), _cache[9] || (_cache[9] = vue.createTextVNode()), vue.renderSlot(_ctx.$slots, "default", vue.normalizeProps(vue.guardReactiveProps({
12538
+ sortFilterResult: sortFilterResult.value
12539
+ })))]);
12593
12540
  };
12541
+ }
12542
+ });
12543
+ const _hoisted_1$p = ["tabindex"];
12544
+ const _hoisted_2$k = {
12545
+ key: 0
12546
+ };
12547
+ const _hoisted_3$g = {
12548
+ class: "table__row"
12549
+ };
12550
+ const _hoisted_4$d = ["innerHTML"];
12551
+ const _hoisted_5$a = {
12552
+ key: 1,
12553
+ class: "table__column__description"
12554
+ };
12555
+ const _hoisted_6$8 = {
12556
+ key: 0
12557
+ };
12558
+ const _hoisted_7$7 = {
12559
+ key: 1
12560
+ };
12561
+ const _hoisted_8$5 = ["colspan"];
12562
+ const _sfc_main$p = /* @__PURE__ */ vue.defineComponent({
12563
+ ...{
12564
+ inheritAttrs: false
12594
12565
  },
12595
- inheritAttrs: false,
12566
+ __name: "FDataTable",
12596
12567
  props: {
12597
12568
  /**
12598
12569
  * The rows to be listed.
@@ -12635,67 +12606,80 @@ const _sfc_main$o = vue.defineComponent({
12635
12606
  }
12636
12607
  }
12637
12608
  },
12638
- setup(props) {
12639
- vue.provide("renderColumns", vue.computed(() => props.rows.length > 0));
12640
- return FSortFilterDatasetInjected();
12641
- },
12642
- data() {
12643
- return {
12644
- columns: []
12645
- };
12646
- },
12647
- computed: {
12648
- hasCaption() {
12649
- return hasSlot(this, "caption", {}, {
12609
+ setup(__props) {
12610
+ const $t2 = useTranslate();
12611
+ const {
12612
+ hasSlot: hasSlot2
12613
+ } = useSlotUtils();
12614
+ const {
12615
+ sort: sort2,
12616
+ registerCallbackOnSort,
12617
+ registerCallbackOnMount
12618
+ } = FSortFilterDatasetInjected();
12619
+ const columns = vue.ref([]);
12620
+ const props = __props;
12621
+ const hasCaption = vue.computed(() => {
12622
+ return hasSlot2("caption", {}, {
12650
12623
  stripClasses: []
12651
12624
  });
12652
- },
12653
- tableClasses() {
12625
+ });
12626
+ const tableClasses = vue.computed(() => {
12654
12627
  const classes = [];
12655
- if (this.striped) {
12628
+ if (props.striped) {
12656
12629
  classes.push("table--striped");
12657
12630
  }
12658
12631
  return classes;
12659
- },
12660
- isEmpty() {
12661
- return this.rows.length === 0;
12662
- },
12663
- visibleColumns() {
12664
- return this.columns.filter((col) => col.visible);
12665
- },
12666
- wrapperClasses() {
12667
- return tableScrollClasses(this.scroll);
12668
- },
12669
- tabindex() {
12670
- return this.scroll !== TableScroll.NONE ? 0 : void 0;
12671
- }
12672
- },
12673
- mounted() {
12674
- this.registerCallbackOnSort(this.callbackOnSort);
12675
- this.registerCallbackOnMount(this.callbackSortableColumns);
12676
- },
12677
- methods: {
12678
- rowKey(item) {
12679
- const key = item[this.keyAttribute];
12632
+ });
12633
+ const isEmpty = vue.computed(() => {
12634
+ return props.rows.length === 0;
12635
+ });
12636
+ const visibleColumns = vue.computed(() => {
12637
+ return columns.value.filter((col) => col.visible);
12638
+ });
12639
+ const wrapperClasses = vue.computed(() => {
12640
+ return tableScrollClasses(props.scroll);
12641
+ });
12642
+ const tabindex = vue.computed(() => {
12643
+ return props.scroll !== TableScroll.NONE ? 0 : void 0;
12644
+ });
12645
+ vue.provide("addColumn", (column) => {
12646
+ if (column.type === FTableColumnType.ACTION) {
12647
+ throw new Error("Cannot use action column in FDataTable component");
12648
+ }
12649
+ columns.value = addColumn(columns.value, column);
12650
+ });
12651
+ vue.provide("setVisibilityColumn", (id, visible) => {
12652
+ setVisibilityColumn(columns.value, id, visible);
12653
+ });
12654
+ vue.provide("textFieldTableMode", true);
12655
+ vue.provide("renderColumns", vue.computed(() => {
12656
+ return props.rows.length > 0;
12657
+ }));
12658
+ vue.onMounted(() => {
12659
+ registerCallbackOnSort(callbackOnSort);
12660
+ registerCallbackOnMount(callbackSortableColumns);
12661
+ });
12662
+ function rowKey(item) {
12663
+ const key = item[props.keyAttribute];
12680
12664
  if (typeof key === "undefined") {
12681
- throw new Error(`Key attribute [${this.keyAttribute}]' is missing in row`);
12665
+ throw new Error(`Key attribute [${props.keyAttribute}]' is missing in row`);
12682
12666
  }
12683
12667
  return String(key);
12684
- },
12685
- columnClasses(column) {
12668
+ }
12669
+ function columnClasses(column) {
12686
12670
  const classes = ["table__column", `table__column--${column.type}`, column.size];
12687
12671
  if (column.sortable) {
12688
12672
  classes.push("table__column--sortable");
12689
12673
  }
12690
12674
  return classes;
12691
- },
12692
- iconClasses(column) {
12675
+ }
12676
+ function iconClasses2(column) {
12693
12677
  return getSortableIconClasses(column);
12694
- },
12695
- iconName(column) {
12678
+ }
12679
+ function iconName(column) {
12696
12680
  return getSortableIconName(column);
12697
- },
12698
- onClickColumnHeader(column) {
12681
+ }
12682
+ function onClickColumnHeader(column) {
12699
12683
  if (!column.sortable) {
12700
12684
  return;
12701
12685
  }
@@ -12704,81 +12688,60 @@ const _sfc_main$o = vue.defineComponent({
12704
12688
  columnName = "";
12705
12689
  column.sort = FTableColumnSort.UNSORTED;
12706
12690
  }
12707
- this.sort(columnName, column.sort !== FTableColumnSort.ASCENDING);
12708
- },
12709
- callbackOnSort(columnName, ascending) {
12710
- updateSortOrder(this.columns, columnName, ascending);
12711
- },
12712
- callbackSortableColumns(columnNames) {
12713
- setSortableColumns(this.columns, columnNames);
12714
- },
12715
- escapeNewlines(value) {
12691
+ sort2(columnName, column.sort !== FTableColumnSort.ASCENDING);
12692
+ }
12693
+ function callbackOnSort(columnName, ascending) {
12694
+ updateSortOrder(columns.value, columnName, ascending);
12695
+ }
12696
+ function callbackSortableColumns(columnNames) {
12697
+ setSortableColumns(columns.value, columnNames);
12698
+ }
12699
+ function escapeNewlines(value) {
12716
12700
  return value.replace(/\n/g, "<br/>");
12717
12701
  }
12702
+ return (_ctx, _cache) => {
12703
+ return vue.openBlock(), vue.createElementBlock("div", {
12704
+ class: vue.normalizeClass(wrapperClasses.value)
12705
+ }, [vue.createElementVNode("table", vue.mergeProps({
12706
+ class: ["table", tableClasses.value],
12707
+ tabindex: tabindex.value
12708
+ }, _ctx.$attrs), [hasCaption.value ? (vue.openBlock(), vue.createElementBlock("caption", _hoisted_2$k, [vue.renderSlot(_ctx.$slots, "caption")])) : vue.createCommentVNode("", true), _cache[4] || (_cache[4] = vue.createTextVNode()), vue.createElementVNode("colgroup", null, [(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(columns.value, (column) => {
12709
+ return vue.openBlock(), vue.createElementBlock("col", {
12710
+ key: column.id,
12711
+ class: vue.normalizeClass(column.size)
12712
+ }, null, 2);
12713
+ }), 128))]), _cache[5] || (_cache[5] = vue.createTextVNode()), vue.createElementVNode("thead", null, [vue.createElementVNode("tr", _hoisted_3$g, [(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(visibleColumns.value, (column) => {
12714
+ return vue.openBlock(), vue.createElementBlock("th", vue.mergeProps({
12715
+ key: column.id,
12716
+ scope: "col",
12717
+ class: columnClasses(column)
12718
+ }, vue.toHandlers(column.sortable ? {
12719
+ click: () => onClickColumnHeader(column)
12720
+ } : {}, true)), [vue.createElementVNode("span", {
12721
+ innerHTML: escapeNewlines(column.title)
12722
+ }, null, 8, _hoisted_4$d), _cache[0] || (_cache[0] = vue.createTextVNode()), column.sortable ? (vue.openBlock(), vue.createBlock(vue.unref(FIcon), {
12723
+ key: 0,
12724
+ class: vue.normalizeClass(iconClasses2(column)),
12725
+ name: iconName(column)
12726
+ }, null, 8, ["class", "name"])) : vue.createCommentVNode("", true), _cache[1] || (_cache[1] = vue.createTextVNode()), column.description ? (vue.openBlock(), vue.createElementBlock("span", _hoisted_5$a, vue.toDisplayString(column.description), 1)) : vue.createCommentVNode("", true)], 16);
12727
+ }), 128))])]), _cache[6] || (_cache[6] = vue.createTextVNode()), vue.createElementVNode("tbody", null, [isEmpty.value && columns.value.length === 0 ? (vue.openBlock(), vue.createElementBlock("tr", _hoisted_6$8, [vue.renderSlot(_ctx.$slots, "default", vue.normalizeProps(vue.guardReactiveProps({
12728
+ row: {}
12729
+ })))])) : vue.createCommentVNode("", true), _cache[2] || (_cache[2] = vue.createTextVNode()), isEmpty.value ? (vue.openBlock(), vue.createElementBlock("tr", _hoisted_7$7, [vue.createElementVNode("td", {
12730
+ class: "table__column table__column--action",
12731
+ colspan: columns.value.length
12732
+ }, [vue.renderSlot(_ctx.$slots, "empty", {}, () => [vue.createTextVNode(vue.toDisplayString(vue.unref($t2)("fkui.data-table.empty", "Tabellen är tom")), 1)])], 8, _hoisted_8$5)])) : vue.createCommentVNode("", true), _cache[3] || (_cache[3] = vue.createTextVNode()), (vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(__props.rows, (row) => {
12733
+ return vue.openBlock(), vue.createElementBlock("tr", {
12734
+ key: rowKey(row),
12735
+ class: "table__row"
12736
+ }, [vue.renderSlot(_ctx.$slots, "default", vue.mergeProps({
12737
+ ref_for: true
12738
+ }, {
12739
+ row
12740
+ }))]);
12741
+ }), 128))])], 16, _hoisted_1$p)], 2);
12742
+ };
12718
12743
  }
12719
12744
  });
12720
- const _hoisted_1$o = ["tabindex"];
12721
- const _hoisted_2$k = {
12722
- key: 0
12723
- };
12724
- const _hoisted_3$g = {
12725
- class: "table__row"
12726
- };
12727
- const _hoisted_4$d = ["innerHTML"];
12728
- const _hoisted_5$a = {
12729
- key: 1,
12730
- class: "table__column__description"
12731
- };
12732
- const _hoisted_6$8 = {
12733
- key: 0
12734
- };
12735
- const _hoisted_7$7 = {
12736
- key: 1
12737
- };
12738
- const _hoisted_8$5 = ["colspan"];
12739
- function _sfc_render$m(_ctx, _cache, $props, $setup, $data, $options) {
12740
- const _component_f_icon = vue.resolveComponent("f-icon");
12741
- return vue.openBlock(), vue.createElementBlock("div", {
12742
- class: vue.normalizeClass(_ctx.wrapperClasses)
12743
- }, [vue.createElementVNode("table", vue.mergeProps({
12744
- class: ["table", _ctx.tableClasses],
12745
- tabindex: _ctx.tabindex
12746
- }, _ctx.$attrs), [_ctx.hasCaption ? (vue.openBlock(), vue.createElementBlock("caption", _hoisted_2$k, [vue.renderSlot(_ctx.$slots, "caption")])) : vue.createCommentVNode("", true), _cache[4] || (_cache[4] = vue.createTextVNode()), vue.createElementVNode("colgroup", null, [(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(_ctx.columns, (column) => {
12747
- return vue.openBlock(), vue.createElementBlock("col", {
12748
- key: column.id,
12749
- class: vue.normalizeClass(column.size)
12750
- }, null, 2);
12751
- }), 128))]), _cache[5] || (_cache[5] = vue.createTextVNode()), vue.createElementVNode("thead", null, [vue.createElementVNode("tr", _hoisted_3$g, [(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(_ctx.visibleColumns, (column) => {
12752
- return vue.openBlock(), vue.createElementBlock("th", vue.mergeProps({
12753
- key: column.id,
12754
- scope: "col",
12755
- class: _ctx.columnClasses(column)
12756
- }, vue.toHandlers(column.sortable ? {
12757
- click: () => _ctx.onClickColumnHeader(column)
12758
- } : {}, true)), [vue.createElementVNode("span", {
12759
- innerHTML: _ctx.escapeNewlines(column.title)
12760
- }, null, 8, _hoisted_4$d), _cache[0] || (_cache[0] = vue.createTextVNode()), column.sortable ? (vue.openBlock(), vue.createBlock(_component_f_icon, {
12761
- key: 0,
12762
- class: vue.normalizeClass(_ctx.iconClasses(column)),
12763
- name: _ctx.iconName(column)
12764
- }, null, 8, ["class", "name"])) : vue.createCommentVNode("", true), _cache[1] || (_cache[1] = vue.createTextVNode()), column.description ? (vue.openBlock(), vue.createElementBlock("span", _hoisted_5$a, vue.toDisplayString(column.description), 1)) : vue.createCommentVNode("", true)], 16);
12765
- }), 128))])]), _cache[6] || (_cache[6] = vue.createTextVNode()), vue.createElementVNode("tbody", null, [_ctx.isEmpty && _ctx.columns.length === 0 ? (vue.openBlock(), vue.createElementBlock("tr", _hoisted_6$8, [vue.renderSlot(_ctx.$slots, "default", vue.normalizeProps(vue.guardReactiveProps({
12766
- row: {}
12767
- })))])) : vue.createCommentVNode("", true), _cache[2] || (_cache[2] = vue.createTextVNode()), _ctx.isEmpty ? (vue.openBlock(), vue.createElementBlock("tr", _hoisted_7$7, [vue.createElementVNode("td", {
12768
- class: "table__column table__column--action",
12769
- colspan: _ctx.columns.length
12770
- }, [vue.renderSlot(_ctx.$slots, "empty", {}, () => [vue.createTextVNode(vue.toDisplayString(_ctx.$t("fkui.data-table.empty", "Tabellen är tom")), 1)])], 8, _hoisted_8$5)])) : vue.createCommentVNode("", true), _cache[3] || (_cache[3] = vue.createTextVNode()), (vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(_ctx.rows, (row) => {
12771
- return vue.openBlock(), vue.createElementBlock("tr", {
12772
- key: _ctx.rowKey(row),
12773
- class: "table__row"
12774
- }, [vue.renderSlot(_ctx.$slots, "default", vue.mergeProps({
12775
- ref_for: true
12776
- }, {
12777
- row
12778
- }))]);
12779
- }), 128))])], 16, _hoisted_1$o)], 2);
12780
- }
12781
- const FDataTable = /* @__PURE__ */ _export_sfc(_sfc_main$o, [["render", _sfc_render$m]]);
12782
12745
  function isDayEnabled(day, config2) {
12783
12746
  return passesMinDate(day, config2.minDate) && passesMaxDate(day, config2.maxDate) && passesInvalidDates(day, config2.invalidDates) && passesInvalidWeekdays(day, config2.invalidWeekdays);
12784
12747
  }
@@ -12854,7 +12817,7 @@ function getDisplayMonth(minDate, maxDate, selectedDate, initialMonth) {
12854
12817
  }
12855
12818
  return month || date.FDate.now().startOfMonth();
12856
12819
  }
12857
- const _sfc_main$n = vue.defineComponent({
12820
+ const _sfc_main$o = vue.defineComponent({
12858
12821
  name: "FDatepickerField",
12859
12822
  components: {
12860
12823
  FCalendar,
@@ -13112,7 +13075,7 @@ const _sfc_main$n = vue.defineComponent({
13112
13075
  }
13113
13076
  }
13114
13077
  });
13115
- const _hoisted_1$n = {
13078
+ const _hoisted_1$o = {
13116
13079
  ref: "component",
13117
13080
  class: "datepicker-field"
13118
13081
  };
@@ -13123,13 +13086,13 @@ const _hoisted_3$f = {
13123
13086
  const _hoisted_4$c = {
13124
13087
  class: "datepicker-field__close"
13125
13088
  };
13126
- function _sfc_render$l(_ctx, _cache, $props, $setup, $data, $options) {
13089
+ function _sfc_render$j(_ctx, _cache, $props, $setup, $data, $options) {
13127
13090
  const _component_f_icon = vue.resolveComponent("f-icon");
13128
13091
  const _component_f_text_field = vue.resolveComponent("f-text-field");
13129
13092
  const _component_f_calendar_day = vue.resolveComponent("f-calendar-day");
13130
13093
  const _component_f_calendar = vue.resolveComponent("f-calendar");
13131
13094
  const _component_i_popup = vue.resolveComponent("i-popup");
13132
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$n, [vue.createElementVNode("div", {
13095
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$o, [vue.createElementVNode("div", {
13133
13096
  ref: "calendarInputs",
13134
13097
  onFocusout: _cache[2] || (_cache[2] = (...args) => _ctx.onFocusoutTextFieldButton && _ctx.onFocusoutTextFieldButton(...args))
13135
13098
  }, [vue.createVNode(_component_f_text_field, vue.mergeProps(_ctx.$attrs, {
@@ -13193,7 +13156,7 @@ function _sfc_render$l(_ctx, _cache, $props, $setup, $data, $options) {
13193
13156
  "min-date": _ctx.minDate,
13194
13157
  "max-date": _ctx.maxDate,
13195
13158
  onClick: _ctx.onSelectCalendarDay,
13196
- onKeyup: vue.withKeys(vue.withModifiers(_ctx.onKeyupEsc, ["stop"]), ["esc", "native"])
13159
+ onKeyup: vue.withKeys(vue.withModifiers(_ctx.onKeyupEsc, ["stop"]), ["esc"])
13197
13160
  }, {
13198
13161
  default: vue.withCtx(({
13199
13162
  date: date2,
@@ -13219,11 +13182,11 @@ function _sfc_render$l(_ctx, _cache, $props, $setup, $data, $options) {
13219
13182
  _: 1
13220
13183
  }, 8, ["is-open", "anchor", "inline", "onOpen", "onClose"])], 512);
13221
13184
  }
13222
- const FDatepickerField = /* @__PURE__ */ _export_sfc(_sfc_main$n, [["render", _sfc_render$l]]);
13185
+ const FDatepickerField = /* @__PURE__ */ _export_sfc(_sfc_main$o, [["render", _sfc_render$j]]);
13223
13186
  function isDialogueTreeEndQuestion(value) {
13224
13187
  return Boolean(value.userData);
13225
13188
  }
13226
- const _sfc_main$m = vue.defineComponent({
13189
+ const _sfc_main$n = vue.defineComponent({
13227
13190
  name: "FDialogueTree",
13228
13191
  components: {
13229
13192
  FIcon
@@ -13301,7 +13264,7 @@ const _sfc_main$m = vue.defineComponent({
13301
13264
  }
13302
13265
  }
13303
13266
  });
13304
- const _hoisted_1$m = {
13267
+ const _hoisted_1$n = {
13305
13268
  class: "dialogue-tree"
13306
13269
  };
13307
13270
  const _hoisted_2$i = {
@@ -13309,9 +13272,9 @@ const _hoisted_2$i = {
13309
13272
  class: "dialogue-tree__list"
13310
13273
  };
13311
13274
  const _hoisted_3$e = ["onClick"];
13312
- function _sfc_render$k(_ctx, _cache, $props, $setup, $data, $options) {
13275
+ function _sfc_render$i(_ctx, _cache, $props, $setup, $data, $options) {
13313
13276
  const _component_f_icon = vue.resolveComponent("f-icon");
13314
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$m, [_ctx.options.length > 0 ? (vue.openBlock(), vue.createElementBlock("ul", _hoisted_2$i, [(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(_ctx.options, (option, index) => {
13277
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$n, [_ctx.options.length > 0 ? (vue.openBlock(), vue.createElementBlock("ul", _hoisted_2$i, [(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(_ctx.options, (option, index) => {
13315
13278
  return vue.openBlock(), vue.createElementBlock("li", {
13316
13279
  key: option.label,
13317
13280
  class: "dialogue-tree__list-item"
@@ -13329,8 +13292,8 @@ function _sfc_render$k(_ctx, _cache, $props, $setup, $data, $options) {
13329
13292
  userData: _ctx.userData
13330
13293
  })))]);
13331
13294
  }
13332
- const FDialogueTree = /* @__PURE__ */ _export_sfc(_sfc_main$m, [["render", _sfc_render$k]]);
13333
- const _sfc_main$l = vue.defineComponent({
13295
+ const FDialogueTree = /* @__PURE__ */ _export_sfc(_sfc_main$n, [["render", _sfc_render$i]]);
13296
+ const _sfc_main$m = vue.defineComponent({
13334
13297
  name: "FExpandablePanel",
13335
13298
  components: {
13336
13299
  FIcon,
@@ -13404,7 +13367,7 @@ const _sfc_main$l = vue.defineComponent({
13404
13367
  }
13405
13368
  }
13406
13369
  });
13407
- const _hoisted_1$l = ["aria-expanded", "aria-controls"];
13370
+ const _hoisted_1$m = ["aria-expanded", "aria-controls"];
13408
13371
  const _hoisted_2$h = {
13409
13372
  class: "expandable-panel__icon"
13410
13373
  };
@@ -13423,7 +13386,7 @@ const _hoisted_8$4 = {
13423
13386
  key: 0,
13424
13387
  class: "expandable-panel__outside"
13425
13388
  };
13426
- function _sfc_render$j(_ctx, _cache, $props, $setup, $data, $options) {
13389
+ function _sfc_render$h(_ctx, _cache, $props, $setup, $data, $options) {
13427
13390
  const _component_f_icon = vue.resolveComponent("f-icon");
13428
13391
  const _component_f_expand = vue.resolveComponent("f-expand");
13429
13392
  return vue.openBlock(), vue.createElementBlock("div", {
@@ -13450,7 +13413,7 @@ function _sfc_render$j(_ctx, _cache, $props, $setup, $data, $options) {
13450
13413
  })
13451
13414
  }, [vue.createElementVNode("span", _hoisted_5$9, vue.toDisplayString(_ctx.screenReaderNotificationText), 1), _cache[2] || (_cache[2] = vue.createTextVNode()), vue.createVNode(_component_f_icon, {
13452
13415
  name: "bell"
13453
- })], 8, _hoisted_4$b)) : vue.createCommentVNode("", true)], 16, _hoisted_1$l)]),
13416
+ })], 8, _hoisted_4$b)) : vue.createCommentVNode("", true)], 16, _hoisted_1$m)]),
13454
13417
  _: 3
13455
13418
  })), _cache[6] || (_cache[6] = vue.createTextVNode()), vue.createVNode(_component_f_expand, null, {
13456
13419
  default: vue.withCtx(() => [vue.withDirectives(vue.createElementVNode("div", {
@@ -13460,8 +13423,8 @@ function _sfc_render$j(_ctx, _cache, $props, $setup, $data, $options) {
13460
13423
  _: 3
13461
13424
  })], 2);
13462
13425
  }
13463
- const FExpandablePanel = /* @__PURE__ */ _export_sfc(_sfc_main$l, [["render", _sfc_render$j]]);
13464
- const _sfc_main$k = vue.defineComponent({
13426
+ const FExpandablePanel = /* @__PURE__ */ _export_sfc(_sfc_main$m, [["render", _sfc_render$h]]);
13427
+ const _sfc_main$l = vue.defineComponent({
13465
13428
  name: "FExpandableParagraph",
13466
13429
  components: {
13467
13430
  FIcon,
@@ -13543,7 +13506,7 @@ const _sfc_main$k = vue.defineComponent({
13543
13506
  }
13544
13507
  }
13545
13508
  });
13546
- const _hoisted_1$k = ["aria-expanded", "aria-controls"];
13509
+ const _hoisted_1$l = ["aria-expanded", "aria-controls"];
13547
13510
  const _hoisted_2$g = {
13548
13511
  class: "expandable-paragraph__icon"
13549
13512
  };
@@ -13562,7 +13525,7 @@ const _hoisted_7$5 = {
13562
13525
  key: 0,
13563
13526
  class: "expandable-paragraph__separator"
13564
13527
  };
13565
- function _sfc_render$i(_ctx, _cache, $props, $setup, $data, $options) {
13528
+ function _sfc_render$g(_ctx, _cache, $props, $setup, $data, $options) {
13566
13529
  const _component_f_icon = vue.resolveComponent("f-icon");
13567
13530
  const _component_f_expand = vue.resolveComponent("f-expand");
13568
13531
  return vue.openBlock(), vue.createElementBlock("div", {
@@ -13583,7 +13546,7 @@ function _sfc_render$i(_ctx, _cache, $props, $setup, $data, $options) {
13583
13546
  name: "dash"
13584
13547
  }), _cache[1] || (_cache[1] = vue.createTextVNode()), vue.createVNode(_component_f_icon, {
13585
13548
  name: "dash"
13586
- })])]), _cache[2] || (_cache[2] = vue.createTextVNode()), vue.renderSlot(_ctx.$slots, "title")], 16, _hoisted_1$k)]),
13549
+ })])]), _cache[2] || (_cache[2] = vue.createTextVNode()), vue.renderSlot(_ctx.$slots, "title")], 16, _hoisted_1$l)]),
13587
13550
  _: 3
13588
13551
  }, 8, ["class"])), _cache[3] || (_cache[3] = vue.createTextVNode()), _ctx.hasRelatedSlot ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_4$a, [vue.renderSlot(_ctx.$slots, "related")])) : vue.createCommentVNode("", true)], 2), _cache[5] || (_cache[5] = vue.createTextVNode()), vue.createVNode(_component_f_expand, null, {
13589
13552
  default: vue.withCtx(() => [vue.withDirectives(vue.createElementVNode("div", {
@@ -13593,7 +13556,7 @@ function _sfc_render$i(_ctx, _cache, $props, $setup, $data, $options) {
13593
13556
  _: 3
13594
13557
  })], 2);
13595
13558
  }
13596
- const FExpandableParagraph = /* @__PURE__ */ _export_sfc(_sfc_main$k, [["render", _sfc_render$i]]);
13559
+ const FExpandableParagraph = /* @__PURE__ */ _export_sfc(_sfc_main$l, [["render", _sfc_render$g]]);
13597
13560
  const DEFAULT_ICON = "file";
13598
13561
  const iconMap = {
13599
13562
  "image/*": "pic",
@@ -13602,7 +13565,7 @@ const iconMap = {
13602
13565
  "application/vnd.openxmlformats-officedocument.wordprocessingml.document": "doc",
13603
13566
  "application/vnd.openxmlformats-officedocument.wordprocessingml.template": "doc"
13604
13567
  };
13605
- const _sfc_main$j = vue.defineComponent({
13568
+ const _sfc_main$k = vue.defineComponent({
13606
13569
  name: "FFileItem",
13607
13570
  components: {
13608
13571
  FIcon
@@ -13681,7 +13644,7 @@ const _sfc_main$j = vue.defineComponent({
13681
13644
  }
13682
13645
  }
13683
13646
  });
13684
- const _hoisted_1$j = {
13647
+ const _hoisted_1$k = {
13685
13648
  class: "file-item"
13686
13649
  };
13687
13650
  const _hoisted_2$f = {
@@ -13701,9 +13664,9 @@ const _hoisted_7$4 = {
13701
13664
  key: 0,
13702
13665
  class: "file-item__change-info"
13703
13666
  };
13704
- function _sfc_render$h(_ctx, _cache, $props, $setup, $data, $options) {
13667
+ function _sfc_render$f(_ctx, _cache, $props, $setup, $data, $options) {
13705
13668
  const _component_f_icon = vue.resolveComponent("f-icon");
13706
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$j, [vue.createElementVNode("div", _hoisted_2$f, [vue.createElementVNode("a", vue.mergeProps({
13669
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$k, [vue.createElementVNode("div", _hoisted_2$f, [vue.createElementVNode("a", vue.mergeProps({
13707
13670
  id: _ctx.id,
13708
13671
  class: "file-item__file-open"
13709
13672
  }, _ctx.$attrs), [vue.createElementVNode("div", _hoisted_4$9, [vue.createVNode(_component_f_icon, {
@@ -13714,8 +13677,8 @@ function _sfc_render$h(_ctx, _cache, $props, $setup, $data, $options) {
13714
13677
  class: "file-item__separator"
13715
13678
  }, null, -1))]);
13716
13679
  }
13717
- const FFileItem = /* @__PURE__ */ _export_sfc(_sfc_main$j, [["render", _sfc_render$h]]);
13718
- const _sfc_main$i = vue.defineComponent({
13680
+ const FFileItem = /* @__PURE__ */ _export_sfc(_sfc_main$k, [["render", _sfc_render$f]]);
13681
+ const _sfc_main$j = vue.defineComponent({
13719
13682
  name: "FFileSelector",
13720
13683
  components: {
13721
13684
  FIcon
@@ -13776,14 +13739,14 @@ const _sfc_main$i = vue.defineComponent({
13776
13739
  }
13777
13740
  }
13778
13741
  });
13779
- const _hoisted_1$i = {
13742
+ const _hoisted_1$j = {
13780
13743
  class: "file-selector"
13781
13744
  };
13782
13745
  const _hoisted_2$e = ["id", "aria-labelledby", "aria-disabled"];
13783
13746
  const _hoisted_3$a = ["id", "for"];
13784
- function _sfc_render$g(_ctx, _cache, $props, $setup, $data, $options) {
13747
+ function _sfc_render$e(_ctx, _cache, $props, $setup, $data, $options) {
13785
13748
  const _component_f_icon = vue.resolveComponent("f-icon");
13786
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$i, [vue.createElementVNode("input", vue.mergeProps({
13749
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$j, [vue.createElementVNode("input", vue.mergeProps({
13787
13750
  id: _ctx.id,
13788
13751
  ref: "file-selector",
13789
13752
  type: "file",
@@ -13802,32 +13765,41 @@ function _sfc_render$g(_ctx, _cache, $props, $setup, $data, $options) {
13802
13765
  name: "paper-clip"
13803
13766
  }), _cache[1] || (_cache[1] = vue.createTextVNode()), vue.renderSlot(_ctx.$slots, "default")], 10, _hoisted_3$a)]);
13804
13767
  }
13805
- const FFileSelector = /* @__PURE__ */ _export_sfc(_sfc_main$i, [["render", _sfc_render$g]]);
13806
- const keybindings = Object.fromEntries([["Up", focusTrAbove], ["Down", focusTrBelow], ["ArrowUp", focusTrAbove], ["ArrowDown", focusTrBelow], [" ", activateRow], ["Spacebar", activateRow]]);
13807
- function focusTrAbove(current) {
13768
+ const FFileSelector = /* @__PURE__ */ _export_sfc(_sfc_main$j, [["render", _sfc_render$e]]);
13769
+ const keybindings = {
13770
+ Up: focusTrAbove,
13771
+ Down: focusTrBelow,
13772
+ ArrowUp: focusTrAbove,
13773
+ ArrowDown: focusTrBelow,
13774
+ " ": activateRow,
13775
+ Spacebar: activateRow
13776
+ };
13777
+ function focusTrAbove(table, current) {
13778
+ const tr = table.tr.value;
13808
13779
  if (current > 0) {
13809
- this.tr[current - 1].focus();
13780
+ tr[current - 1].focus();
13810
13781
  } else {
13811
- this.tr[this.tr.length - 1].focus();
13782
+ tr[tr.length - 1].focus();
13812
13783
  }
13813
13784
  }
13814
- function focusTrBelow(current) {
13815
- if (current < this.tr.length - 1) {
13816
- this.tr[current + 1].focus();
13785
+ function focusTrBelow(table, current) {
13786
+ const tr = table.tr.value;
13787
+ if (current < tr.length - 1) {
13788
+ tr[current + 1].focus();
13817
13789
  } else {
13818
- this.tr[0].focus();
13790
+ tr[0].focus();
13819
13791
  }
13820
13792
  }
13821
- function activateRow(current) {
13822
- const row = this.rows[current];
13823
- const element = this.tr[current];
13824
- this.activate(row, element);
13793
+ function activateRow(table, current) {
13794
+ const row = table.rows[current];
13795
+ const element = table.tr.value[current];
13796
+ table.activate(row, element);
13825
13797
  }
13826
- function onKeydown(event, current) {
13798
+ function onKeydown(table, event, current) {
13827
13799
  const fn2 = keybindings[event.key];
13828
13800
  if (fn2) {
13829
13801
  event.preventDefault();
13830
- fn2.call(this, current);
13802
+ fn2(table, current);
13831
13803
  }
13832
13804
  }
13833
13805
  function useExpandableTable(expandableAttribute, keyAttribute, describedby, emit, slots) {
@@ -13891,7 +13863,6 @@ function useExpandableTable(expandableAttribute, keyAttribute, describedby, emit
13891
13863
  return Boolean(expandableRows(row));
13892
13864
  }
13893
13865
  return {
13894
- expandedRows,
13895
13866
  isExpandableTable,
13896
13867
  hasExpandableSlot,
13897
13868
  toggleExpanded,
@@ -13903,32 +13874,76 @@ function useExpandableTable(expandableAttribute, keyAttribute, describedby, emit
13903
13874
  hasExpandableContent
13904
13875
  };
13905
13876
  }
13906
- function forceRepaintIE11(target) {
13907
- if (navigator.userAgent.includes("Trident")) {
13908
- target.style.display = "none";
13909
- target.offsetHeight;
13910
- target.style.removeProperty("display");
13911
- }
13912
- }
13913
- const _sfc_main$h = vue.defineComponent({
13914
- name: "FInteractiveTable",
13915
- components: {
13916
- FCheckboxField,
13917
- FIcon
13918
- },
13919
- mixins: [TranslationMixin],
13920
- provide() {
13921
- return {
13922
- addColumn: (column) => {
13923
- this.columns = addColumn(this.columns, column);
13924
- },
13925
- setVisibilityColumn: (id, visible) => {
13926
- setVisibilityColumn(this.columns, id, visible);
13927
- },
13928
- textFieldTableMode: true
13929
- };
13877
+ const _hoisted_1$i = ["role"];
13878
+ const _hoisted_2$d = {
13879
+ key: 0
13880
+ };
13881
+ const _hoisted_3$9 = {
13882
+ key: 0,
13883
+ class: "table__column--shrink"
13884
+ };
13885
+ const _hoisted_4$8 = {
13886
+ key: 1,
13887
+ class: "table__column--shrink"
13888
+ };
13889
+ const _hoisted_5$6 = {
13890
+ class: "table__row"
13891
+ };
13892
+ const _hoisted_6$4 = {
13893
+ key: 0,
13894
+ scope: "col"
13895
+ };
13896
+ const _hoisted_7$3 = {
13897
+ class: "sr-only"
13898
+ };
13899
+ const _hoisted_8$3 = {
13900
+ key: 1,
13901
+ scope: "col"
13902
+ };
13903
+ const _hoisted_9$3 = {
13904
+ class: "sr-only"
13905
+ };
13906
+ const _hoisted_10$2 = ["innerHTML"];
13907
+ const _hoisted_11$1 = {
13908
+ key: 1,
13909
+ class: "table__column__description"
13910
+ };
13911
+ const _hoisted_12$1 = ["aria-label", "aria-expanded", "aria-level", "aria-describedby", "onKeydown", "onClick"];
13912
+ const _hoisted_13 = {
13913
+ key: 0
13914
+ };
13915
+ const _hoisted_14 = {
13916
+ key: 0,
13917
+ class: "table__expand-icon"
13918
+ };
13919
+ const _hoisted_15 = {
13920
+ key: 1,
13921
+ class: "table__column--selectable"
13922
+ };
13923
+ const _hoisted_16 = {
13924
+ class: "table__input"
13925
+ };
13926
+ const _hoisted_17 = {
13927
+ key: 0,
13928
+ class: "sr-only"
13929
+ };
13930
+ const _hoisted_18 = {
13931
+ key: 0,
13932
+ class: "table__column--placeholder"
13933
+ };
13934
+ const _hoisted_19 = ["colspan"];
13935
+ const _hoisted_20 = {
13936
+ key: 0
13937
+ };
13938
+ const _hoisted_21 = {
13939
+ key: 1
13940
+ };
13941
+ const _hoisted_22 = ["colspan"];
13942
+ const _sfc_main$i = /* @__PURE__ */ vue.defineComponent({
13943
+ ...{
13944
+ inheritAttrs: false
13930
13945
  },
13931
- inheritAttrs: false,
13946
+ __name: "FInteractiveTable",
13932
13947
  props: {
13933
13948
  /**
13934
13949
  * The rows to be listed.
@@ -14025,230 +14040,237 @@ const _sfc_main$h = vue.defineComponent({
14025
14040
  default: () => void 0
14026
14041
  }
14027
14042
  },
14028
- emits: [
14029
- "change",
14030
- "click",
14031
- "unselect",
14032
- "update:modelValue",
14033
- "update:active",
14034
- "select",
14035
- /**
14036
- * Emitted when row is expanded.
14037
- *
14038
- * @event expand
14039
- * @param row
14040
- * @type {ListItem}
14041
- */
14042
- "expand",
14043
- /**
14044
- * Emitted when row is collapsed.
14045
- *
14046
- * @event collapse
14047
- * @param row
14048
- * @type {ListItem}
14049
- */
14050
- "collapse"
14051
- ],
14052
- setup(props, context) {
14053
- vue.provide("renderColumns", vue.computed(() => props.rows.length > 0));
14054
- const sortFilterDatasetInjected = FSortFilterDatasetInjected();
14055
- const activateItemInjected = ActivateItemInjected();
14056
- const expandableTable = useExpandableTable(props.expandableAttribute, props.keyAttribute, props.expandableDescribedby, context.emit, context.slots);
14057
- return {
14058
- ...sortFilterDatasetInjected,
14059
- ...activateItemInjected,
14060
- ...expandableTable
14061
- };
14062
- },
14063
- data() {
14064
- return {
14065
- activeRow: void 0,
14066
- columns: [],
14067
- selectedRows: [],
14068
- tr: [],
14069
- tbodyKey: 0
14070
- };
14071
- },
14072
- computed: {
14073
- hasCaption() {
14074
- return hasSlot(this, "caption", {}, {
14043
+ emits: ["change", "click", "unselect", "update:modelValue", "update:active", "select", "expand", "collapse"],
14044
+ setup(__props, {
14045
+ emit: __emit
14046
+ }) {
14047
+ const $t2 = useTranslate();
14048
+ const slots = vue.useSlots();
14049
+ const {
14050
+ hasSlot: hasSlot2
14051
+ } = useSlotUtils();
14052
+ const {
14053
+ sort: sort2,
14054
+ registerCallbackOnSort,
14055
+ registerCallbackOnMount
14056
+ } = FSortFilterDatasetInjected();
14057
+ const {
14058
+ registerCallbackAfterItemAdd,
14059
+ registerCallbackBeforeItemDelete
14060
+ } = ActivateItemInjected();
14061
+ const activeRow = vue.ref(void 0);
14062
+ const columns = vue.ref([]);
14063
+ const selectedRows = vue.ref([]);
14064
+ const tr = vue.shallowRef([]);
14065
+ const tbodyKey = vue.ref(0);
14066
+ const props = __props;
14067
+ const emit = __emit;
14068
+ const expandableTable = useExpandableTable(props.expandableAttribute, props.keyAttribute, props.expandableDescribedby, emit, slots);
14069
+ const {
14070
+ isExpandableTable,
14071
+ hasExpandableSlot,
14072
+ toggleExpanded,
14073
+ isExpanded,
14074
+ rowAriaExpanded,
14075
+ expandableRowClasses,
14076
+ getExpandableDescribedby,
14077
+ expandableRows,
14078
+ hasExpandableContent
14079
+ } = expandableTable;
14080
+ const hasCaption = vue.computed(() => {
14081
+ return hasSlot2("caption", {}, {
14075
14082
  stripClasses: []
14076
14083
  });
14077
- },
14078
- hasCheckboxDescription() {
14079
- const firstRow = this.rows[0];
14080
- return hasSlot(this, "checkbox-description", {
14084
+ });
14085
+ const hasCheckboxDescription = vue.computed(() => {
14086
+ const firstRow = props.rows[0];
14087
+ return hasSlot2("checkbox-description", {
14081
14088
  row: firstRow
14082
14089
  });
14083
- },
14084
- isEmpty() {
14085
- return this.rows.length === 0;
14086
- },
14087
- visibleColumns() {
14088
- return this.columns.filter((col) => col.visible);
14089
- },
14090
- tableClasses() {
14090
+ });
14091
+ const isEmpty = vue.computed(() => {
14092
+ return props.rows.length === 0;
14093
+ });
14094
+ const visibleColumns = vue.computed(() => {
14095
+ return columns.value.filter((col) => col.visible);
14096
+ });
14097
+ const tableClasses = vue.computed(() => {
14091
14098
  const classes = [];
14092
- if (this.selectable) {
14099
+ if (props.selectable) {
14093
14100
  classes.push("table--selectable");
14094
14101
  }
14095
- if (this.hover) {
14102
+ if (props.hover) {
14096
14103
  classes.push("table--hover");
14097
14104
  }
14098
14105
  return classes;
14099
- },
14100
- tableRole() {
14101
- return this.isExpandableTable ? "treegrid" : "grid";
14102
- },
14103
- wrapperClasses() {
14104
- return tableScrollClasses(this.scroll);
14105
- },
14106
- nbOfColumns() {
14107
- let columnCount = this.visibleColumns.length;
14108
- if (this.selectable) {
14106
+ });
14107
+ const tableRole = vue.computed(() => {
14108
+ return isExpandableTable.value ? "treegrid" : "grid";
14109
+ });
14110
+ const wrapperClasses = vue.computed(() => {
14111
+ return tableScrollClasses(props.scroll);
14112
+ });
14113
+ const nbOfColumns = vue.computed(() => {
14114
+ let columnCount = visibleColumns.value.length;
14115
+ if (props.selectable) {
14109
14116
  columnCount++;
14110
14117
  }
14111
- if (this.isExpandableTable) {
14118
+ if (isExpandableTable.value) {
14112
14119
  columnCount++;
14113
14120
  }
14114
14121
  return columnCount;
14115
- }
14116
- },
14117
- watch: {
14118
- rows: {
14119
- immediate: true,
14120
- deep: true,
14121
- handler: function() {
14122
- if (this.modelValue) {
14123
- this.selectedRows = this.modelValue.filter((row) => {
14124
- return includeItem(row, this.rows, this.keyAttribute);
14125
- });
14126
- }
14127
- }
14128
- },
14129
- active: {
14130
- immediate: true,
14131
- handler: function() {
14132
- this.updateActiveRowFromVModel();
14122
+ });
14123
+ vue.provide("addColumn", (column) => {
14124
+ columns.value = addColumn(columns.value, column);
14125
+ });
14126
+ vue.provide("setVisibilityColumn", (id, visible) => {
14127
+ setVisibilityColumn(columns.value, id, visible);
14128
+ });
14129
+ vue.provide("textFieldTableMode", true);
14130
+ vue.provide("renderColumns", vue.computed(() => props.rows.length > 0));
14131
+ vue.watch(() => props.rows, () => {
14132
+ if (props.modelValue) {
14133
+ selectedRows.value = props.modelValue.filter((row) => {
14134
+ return includeItem(row, props.rows, props.keyAttribute);
14135
+ });
14133
14136
  }
14134
- },
14135
- showActive: {
14137
+ }, {
14136
14138
  immediate: true,
14137
- handler: function(val) {
14138
- if (!val) {
14139
- this.tbodyKey ^= 1;
14140
- }
14139
+ deep: true
14140
+ });
14141
+ vue.watch(() => props.active, () => {
14142
+ updateActiveRowFromVModel();
14143
+ }, {
14144
+ immediate: true
14145
+ });
14146
+ vue.watch(() => props.showActive, (val) => {
14147
+ if (!val) {
14148
+ tbodyKey.value ^= 1;
14141
14149
  }
14150
+ }, {
14151
+ immediate: true
14152
+ });
14153
+ function updateTr(tbodyElement) {
14154
+ const trElements = [].slice.call(tbodyElement.children);
14155
+ const trInteractableElements = trElements.filter((tr2) => {
14156
+ return tr2.tabIndex === 0;
14157
+ });
14158
+ tr.value = trInteractableElements;
14142
14159
  }
14143
- },
14144
- updated() {
14145
- const tbodyElement = this.$refs["tbodyElement"];
14146
- const trElements = [].slice.call(tbodyElement.children);
14147
- const trInteractableElements = trElements.filter((tr) => {
14148
- return tr.tabIndex === 0;
14160
+ vue.onUpdated(() => {
14161
+ const tbodyElement = vue.useTemplateRef("tbodyElement");
14162
+ if (tbodyElement.value) {
14163
+ updateTr(tbodyElement.value);
14164
+ }
14149
14165
  });
14150
- this.tr = trInteractableElements;
14151
- },
14152
- mounted() {
14153
- this.registerCallbackOnSort(this.callbackOnSort);
14154
- this.registerCallbackOnMount(this.callbackSortableColumns);
14155
- this.registerCallbackAfterItemAdd(this.callbackAfterItemAdd);
14156
- this.registerCallbackBeforeItemDelete(this.callbackBeforeItemDelete);
14157
- },
14158
- methods: {
14159
- isActive(row) {
14160
- if (!this.showActive) {
14161
- return false;
14166
+ vue.onMounted(() => {
14167
+ const tbodyElement = vue.useTemplateRef("tbodyElement");
14168
+ if (tbodyElement.value) {
14169
+ updateTr(tbodyElement.value);
14170
+ }
14171
+ registerCallbackOnSort(callbackOnSort);
14172
+ registerCallbackOnMount(callbackSortableColumns);
14173
+ registerCallbackAfterItemAdd(callbackAfterItemAdd);
14174
+ registerCallbackBeforeItemDelete(callbackBeforeItemDelete);
14175
+ });
14176
+ function forceRepaintIE11(target) {
14177
+ if (navigator.userAgent.includes("Trident")) {
14178
+ target.style.display = "none";
14179
+ target.offsetHeight;
14180
+ target.style.removeProperty("display");
14162
14181
  }
14163
- return itemEquals(row, this.activeRow, this.keyAttribute);
14164
- },
14165
- isSelected(row) {
14166
- return includeItem(row, this.selectedRows, this.keyAttribute);
14167
- },
14168
- onKeydownExpandable(event, index) {
14169
- if (event.key === " " || event.key === "Spacebar") {
14170
- event.preventDefault();
14171
- return;
14182
+ }
14183
+ function isActive(row) {
14184
+ if (!props.showActive) {
14185
+ return false;
14172
14186
  }
14173
- onKeydown.call(this, event, index);
14174
- },
14175
- onKeydown(event, index) {
14176
- onKeydown.call(this, event, index);
14177
- },
14178
- onClick(event, row) {
14187
+ return itemEquals(row, activeRow.value, props.keyAttribute);
14188
+ }
14189
+ function isSelected(row) {
14190
+ return includeItem(row, selectedRows.value, props.keyAttribute);
14191
+ }
14192
+ function onKeydown$1(event, index) {
14193
+ onKeydown({
14194
+ rows: props.rows,
14195
+ tr,
14196
+ activate
14197
+ }, event, index);
14198
+ }
14199
+ function onClick(event, row) {
14179
14200
  const {
14180
14201
  target
14181
14202
  } = event;
14182
14203
  const isRelevant = ["TD", "TH"].includes(target.nodeName);
14183
14204
  if (isRelevant) {
14184
14205
  const parent = target.parentElement;
14185
- this.activate(row, parent);
14206
+ activate(row, parent);
14186
14207
  }
14187
- },
14188
- activate(row, tr) {
14189
- this.$emit("click", row);
14190
- if (this.isExpandableTable && this.hasExpandableContent(row)) {
14191
- this.toggleExpanded(row);
14208
+ }
14209
+ function activate(row, tr2) {
14210
+ emit("click", row);
14211
+ if (isExpandableTable.value && hasExpandableContent(row)) {
14212
+ toggleExpanded(row);
14192
14213
  }
14193
- if (!itemEquals(row, this.activeRow, this.keyAttribute)) {
14194
- this.$emit("change", row);
14195
- this.setActiveRow(row);
14196
- if (tr) {
14197
- tr.focus();
14198
- const td = tr.children[0];
14214
+ if (!itemEquals(row, activeRow.value, props.keyAttribute)) {
14215
+ emit("change", row);
14216
+ setActiveRow(row);
14217
+ if (tr2) {
14218
+ tr2.focus();
14219
+ const td = tr2.children[0];
14199
14220
  forceRepaintIE11(td);
14200
14221
  }
14201
14222
  }
14202
- },
14203
- rowDescription(row) {
14204
- const slot = this.$slots["row-description"];
14223
+ }
14224
+ function rowDescription(row) {
14225
+ const slot = slots["row-description"];
14205
14226
  return renderSlotText(slot, {
14206
14227
  row
14207
14228
  });
14208
- },
14209
- onSelect(row) {
14210
- if (includeItem(row, this.selectedRows, this.keyAttribute)) {
14211
- this.selectedRows = this.selectedRows.filter((i) => !itemEquals(i, row, this.keyAttribute));
14212
- this.$emit("unselect", row);
14229
+ }
14230
+ function onSelect(row) {
14231
+ var _a, _b;
14232
+ if (includeItem(row, selectedRows.value, props.keyAttribute)) {
14233
+ selectedRows.value = selectedRows.value.filter((i) => !itemEquals(i, row, props.keyAttribute));
14234
+ emit("unselect", row);
14213
14235
  } else {
14214
- this.selectedRows.push(row);
14215
- this.$emit("select", row);
14236
+ selectedRows.value.push(row);
14237
+ emit("select", row);
14216
14238
  }
14217
- this.updateVModelWithSelectedRows();
14218
- this.$forceUpdate();
14219
- },
14220
- updateVModelWithSelectedRows() {
14221
- if (this.modelValue) {
14222
- this.$emit("update:modelValue", this.selectedRows);
14239
+ updateVModelWithSelectedRows();
14240
+ (_b = (_a = vue.getCurrentInstance()) == null ? void 0 : _a.proxy) == null ? void 0 : _b.$forceUpdate();
14241
+ }
14242
+ function updateVModelWithSelectedRows() {
14243
+ if (props.modelValue) {
14244
+ emit("update:modelValue", selectedRows.value);
14223
14245
  }
14224
- },
14225
- rowClasses(row, index) {
14226
- const active = this.isActive(row) ? ["table__row--active"] : [];
14227
- const selected = this.isSelected(row) ? ["table__row--selected"] : [];
14228
- const isExpandableRow = this.isExpandableTable && this.hasExpandableContent(row);
14246
+ }
14247
+ function rowClasses(row, index) {
14248
+ const active = isActive(row) ? ["table__row--active"] : [];
14249
+ const selected = isSelected(row) ? ["table__row--selected"] : [];
14250
+ const isExpandableRow = isExpandableTable.value && hasExpandableContent(row);
14229
14251
  const expandable = isExpandableRow ? ["table__row--expandable"] : [];
14230
- const expanded = this.isExpanded(row) ? ["table__row--expanded-border"] : [];
14231
- const striped = this.striped && index % 2 !== 0 ? ["table__row--striped"] : [];
14252
+ const expanded = isExpanded(row) ? ["table__row--expanded-border"] : [];
14253
+ const striped = props.striped && index % 2 !== 0 ? ["table__row--striped"] : [];
14232
14254
  return ["table__row", ...active, ...selected, ...striped, ...expandable, ...expanded];
14233
- },
14234
- rowKey(row) {
14235
- const key = row[this.keyAttribute];
14255
+ }
14256
+ function rowKey(row) {
14257
+ const key = row[props.keyAttribute];
14236
14258
  if (typeof key === "undefined") {
14237
- throw new Error(`Key attribute [${this.keyAttribute}]' is missing in row`);
14259
+ throw new Error(`Key attribute [${props.keyAttribute}]' is missing in row`);
14238
14260
  }
14239
14261
  return String(key);
14240
- },
14241
- columnClasses(column) {
14262
+ }
14263
+ function columnClasses(column) {
14242
14264
  const sortable = column.sortable ? ["table__column--sortable"] : [];
14243
14265
  return ["table__column", `table__column--${column.type}`, ...sortable, column.size];
14244
- },
14245
- iconClasses(column) {
14266
+ }
14267
+ function iconClasses2(column) {
14246
14268
  return getSortableIconClasses(column);
14247
- },
14248
- iconName(column) {
14269
+ }
14270
+ function iconName(column) {
14249
14271
  return getSortableIconName(column);
14250
- },
14251
- onClickColumnHeader(column) {
14272
+ }
14273
+ function onClickColumnHeader(column) {
14252
14274
  if (!column.sortable) {
14253
14275
  return;
14254
14276
  }
@@ -14257,206 +14279,138 @@ const _sfc_main$h = vue.defineComponent({
14257
14279
  columnName = "";
14258
14280
  column.sort = FTableColumnSort.UNSORTED;
14259
14281
  }
14260
- this.sort(columnName, column.sort !== FTableColumnSort.ASCENDING);
14261
- },
14262
- callbackOnSort(columnName, ascending) {
14263
- updateSortOrder(this.columns, columnName, ascending);
14264
- },
14265
- callbackSortableColumns(columnNames) {
14266
- setSortableColumns(this.columns, columnNames);
14267
- },
14268
- callbackAfterItemAdd(item) {
14269
- this.activate(item, null);
14270
- },
14271
- callbackBeforeItemDelete(item) {
14272
- if (this.rows.length === 0) {
14282
+ sort2(columnName, column.sort !== FTableColumnSort.ASCENDING);
14283
+ }
14284
+ function callbackOnSort(columnName, ascending) {
14285
+ updateSortOrder(columns.value, columnName, ascending);
14286
+ }
14287
+ function callbackSortableColumns(columnNames) {
14288
+ setSortableColumns(columns.value, columnNames);
14289
+ }
14290
+ function callbackAfterItemAdd(item) {
14291
+ activate(item, null);
14292
+ }
14293
+ function callbackBeforeItemDelete(item) {
14294
+ if (props.rows.length === 0) {
14273
14295
  return;
14274
14296
  }
14275
- let targetIndex = this.rows.indexOf(item) - 1;
14276
- if (targetIndex < 0 && this.rows.length > 1) {
14297
+ let targetIndex = props.rows.indexOf(item) - 1;
14298
+ if (targetIndex < 0 && props.rows.length > 1) {
14277
14299
  targetIndex = 1;
14278
14300
  } else if (targetIndex < 0) {
14279
14301
  targetIndex = 0;
14280
14302
  }
14281
- this.activate(this.rows[targetIndex], this.tr[targetIndex]);
14282
- },
14283
- escapeNewlines(value) {
14303
+ activate(props.rows[targetIndex], tr.value[targetIndex]);
14304
+ }
14305
+ function escapeNewlines(value) {
14284
14306
  return value.replace(/\n/g, "<br/>");
14285
- },
14286
- updateActiveRowFromVModel() {
14287
- if (this.active === void 0) {
14288
- this.setActiveRow(void 0);
14289
- } else if (!itemEquals(this.active, this.activeRow, this.keyAttribute)) {
14290
- this.setActiveRow(this.active);
14307
+ }
14308
+ function updateActiveRowFromVModel() {
14309
+ if (props.active === void 0) {
14310
+ setActiveRow(void 0);
14311
+ } else if (!itemEquals(props.active, activeRow.value, props.keyAttribute)) {
14312
+ setActiveRow(props.active);
14291
14313
  }
14292
- },
14293
- setActiveRow(row) {
14294
- this.activeRow = row;
14295
- this.$emit("update:active", this.activeRow);
14296
14314
  }
14315
+ function setActiveRow(row) {
14316
+ activeRow.value = row;
14317
+ emit("update:active", activeRow.value);
14318
+ }
14319
+ return (_ctx, _cache) => {
14320
+ return vue.openBlock(), vue.createElementBlock("div", {
14321
+ class: vue.normalizeClass(wrapperClasses.value)
14322
+ }, [vue.createCommentVNode("", true), _cache[18] || (_cache[18] = vue.createTextVNode()), vue.createElementVNode("table", vue.mergeProps({
14323
+ class: ["table", tableClasses.value],
14324
+ role: tableRole.value
14325
+ }, _ctx.$attrs), [hasCaption.value ? (vue.openBlock(), vue.createElementBlock("caption", _hoisted_2$d, [vue.renderSlot(_ctx.$slots, "caption")])) : vue.createCommentVNode("", true), _cache[15] || (_cache[15] = vue.createTextVNode()), vue.createElementVNode("colgroup", null, [vue.unref(isExpandableTable) ? (vue.openBlock(), vue.createElementBlock("col", _hoisted_3$9)) : vue.createCommentVNode("", true), _cache[0] || (_cache[0] = vue.createTextVNode()), __props.selectable ? (vue.openBlock(), vue.createElementBlock("col", _hoisted_4$8)) : vue.createCommentVNode("", true), _cache[1] || (_cache[1] = vue.createTextVNode()), (vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(columns.value, (column) => {
14326
+ return vue.openBlock(), vue.createElementBlock("col", {
14327
+ key: column.id,
14328
+ class: vue.normalizeClass(column.size)
14329
+ }, null, 2);
14330
+ }), 128))]), _cache[16] || (_cache[16] = vue.createTextVNode()), vue.createElementVNode("thead", null, [vue.createElementVNode("tr", _hoisted_5$6, [vue.unref(isExpandableTable) ? (vue.openBlock(), vue.createElementBlock("th", _hoisted_6$4, [vue.createElementVNode("span", _hoisted_7$3, vue.toDisplayString(vue.unref($t2)("fkui.interactive-table.select", "Expandera")), 1)])) : vue.createCommentVNode("", true), _cache[4] || (_cache[4] = vue.createTextVNode()), __props.selectable ? (vue.openBlock(), vue.createElementBlock("th", _hoisted_8$3, [vue.createElementVNode("span", _hoisted_9$3, vue.toDisplayString(vue.unref($t2)("fkui.interactive-table.select", "Markera")), 1)])) : vue.createCommentVNode("", true), _cache[5] || (_cache[5] = vue.createTextVNode()), (vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(visibleColumns.value, (column) => {
14331
+ return vue.openBlock(), vue.createElementBlock("th", vue.mergeProps({
14332
+ key: column.id,
14333
+ scope: "col",
14334
+ class: columnClasses(column)
14335
+ }, vue.toHandlers(column.sortable ? {
14336
+ click: () => onClickColumnHeader(column)
14337
+ } : {}, true)), [vue.createElementVNode("span", {
14338
+ innerHTML: escapeNewlines(column.title)
14339
+ }, null, 8, _hoisted_10$2), _cache[2] || (_cache[2] = vue.createTextVNode()), column.sortable ? (vue.openBlock(), vue.createBlock(vue.unref(FIcon), {
14340
+ key: 0,
14341
+ class: vue.normalizeClass(iconClasses2(column)),
14342
+ name: iconName(column)
14343
+ }, null, 8, ["class", "name"])) : vue.createCommentVNode("", true), _cache[3] || (_cache[3] = vue.createTextVNode()), column.description ? (vue.openBlock(), vue.createElementBlock("span", _hoisted_11$1, vue.toDisplayString(column.description), 1)) : vue.createCommentVNode("", true)], 16);
14344
+ }), 128))])]), _cache[17] || (_cache[17] = vue.createTextVNode()), (vue.openBlock(), vue.createElementBlock("tbody", {
14345
+ ref: "tbodyElement",
14346
+ key: tbodyKey.value
14347
+ }, [(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(__props.rows, (row, index) => {
14348
+ return vue.openBlock(), vue.createElementBlock(vue.Fragment, {
14349
+ key: rowKey(row)
14350
+ }, [vue.createElementVNode("tr", {
14351
+ class: vue.normalizeClass(rowClasses(row, index)),
14352
+ "aria-label": rowDescription(row),
14353
+ "aria-expanded": vue.unref(rowAriaExpanded)(row),
14354
+ "aria-level": vue.unref(isExpandableTable) ? 1 : void 0,
14355
+ "aria-describedby": vue.unref(getExpandableDescribedby)(row),
14356
+ tabindex: "0",
14357
+ onKeydown: vue.withModifiers(($event) => onKeydown$1($event, index), ["self"]),
14358
+ onClick: ($event) => onClick($event, row)
14359
+ }, [vue.unref(isExpandableTable) ? (vue.openBlock(), vue.createElementBlock("td", _hoisted_13, [vue.unref(hasExpandableContent)(row) ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_14, [vue.createVNode(vue.unref(FIcon), {
14360
+ name: "arrow-right",
14361
+ rotate: vue.unref(isExpanded)(row) ? "270" : "90"
14362
+ }, null, 8, ["rotate"])])) : vue.createCommentVNode("", true)])) : vue.createCommentVNode("", true), _cache[6] || (_cache[6] = vue.createTextVNode()), __props.selectable ? (vue.openBlock(), vue.createElementBlock("td", _hoisted_15, [vue.createElementVNode("div", _hoisted_16, [vue.createVNode(vue.unref(FCheckboxField), {
14363
+ value: true,
14364
+ "model-value": isSelected(row),
14365
+ onClick: vue.withModifiers(($event) => onSelect(row), ["self"])
14366
+ }, {
14367
+ default: vue.withCtx(() => [hasCheckboxDescription.value ? (vue.openBlock(), vue.createElementBlock("span", _hoisted_17, [vue.renderSlot(_ctx.$slots, "checkbox-description", vue.mergeProps({
14368
+ ref_for: true
14369
+ }, {
14370
+ row
14371
+ }))])) : vue.createCommentVNode("", true)]),
14372
+ _: 2
14373
+ }, 1032, ["model-value", "onClick"])])])) : vue.createCommentVNode("", true), _cache[7] || (_cache[7] = vue.createTextVNode()), vue.renderSlot(_ctx.$slots, "default", vue.mergeProps({
14374
+ ref_for: true
14375
+ }, {
14376
+ row
14377
+ }))], 42, _hoisted_12$1), _cache[11] || (_cache[11] = vue.createTextVNode()), vue.unref(isExpandableTable) && vue.unref(hasExpandableContent)(row) ? (vue.openBlock(true), vue.createElementBlock(vue.Fragment, {
14378
+ key: 0
14379
+ }, vue.renderList(vue.unref(expandableRows)(row), (expandableRow, expandableIndex) => {
14380
+ return vue.openBlock(), vue.createElementBlock("tr", {
14381
+ key: rowKey(expandableRow),
14382
+ "aria-level": "2",
14383
+ class: vue.normalizeClass(vue.unref(expandableRowClasses)(row, expandableIndex))
14384
+ }, [_cache[8] || (_cache[8] = vue.createElementVNode("td", {
14385
+ class: "table__column--placeholder"
14386
+ }, null, -1)), _cache[9] || (_cache[9] = vue.createTextVNode()), __props.selectable ? (vue.openBlock(), vue.createElementBlock("td", _hoisted_18)) : vue.createCommentVNode("", true), _cache[10] || (_cache[10] = vue.createTextVNode()), !vue.unref(hasExpandableSlot) ? vue.renderSlot(_ctx.$slots, "default", vue.mergeProps({
14387
+ key: 1,
14388
+ ref_for: true
14389
+ }, {
14390
+ row: expandableRow
14391
+ })) : (vue.openBlock(), vue.createElementBlock("td", {
14392
+ key: 2,
14393
+ class: "table__column table__column--indented",
14394
+ colspan: columns.value.length
14395
+ }, [vue.renderSlot(_ctx.$slots, "expandable", vue.mergeProps({
14396
+ ref_for: true
14397
+ }, {
14398
+ expandableRow,
14399
+ parentRow: row
14400
+ }))], 8, _hoisted_19))], 2);
14401
+ }), 128)) : vue.createCommentVNode("", true)], 64);
14402
+ }), 128)), _cache[13] || (_cache[13] = vue.createTextVNode()), isEmpty.value && columns.value.length === 0 ? (vue.openBlock(), vue.createElementBlock("tr", _hoisted_20, [vue.renderSlot(_ctx.$slots, "default", vue.normalizeProps(vue.guardReactiveProps({
14403
+ row: {}
14404
+ })))])) : vue.createCommentVNode("", true), _cache[14] || (_cache[14] = vue.createTextVNode()), isEmpty.value ? (vue.openBlock(), vue.createElementBlock("tr", _hoisted_21, [vue.createElementVNode("td", {
14405
+ class: "table__column table__column--action",
14406
+ colspan: nbOfColumns.value
14407
+ }, [vue.renderSlot(_ctx.$slots, "empty", {}, () => [vue.createTextVNode(vue.toDisplayString(vue.unref($t2)("fkui.interactive-table.empty", "Tabellen är tom")), 1)])], 8, _hoisted_22), _cache[12] || (_cache[12] = vue.createTextVNode()), vue.renderSlot(_ctx.$slots, "default", vue.normalizeProps(vue.guardReactiveProps({
14408
+ row: {}
14409
+ })))])) : vue.createCommentVNode("", true)]))], 16, _hoisted_1$i)], 2);
14410
+ };
14297
14411
  }
14298
14412
  });
14299
- const _hoisted_1$h = ["role"];
14300
- const _hoisted_2$d = {
14301
- key: 0
14302
- };
14303
- const _hoisted_3$9 = {
14304
- key: 0,
14305
- class: "table__column--shrink"
14306
- };
14307
- const _hoisted_4$8 = {
14308
- key: 1,
14309
- class: "table__column--shrink"
14310
- };
14311
- const _hoisted_5$6 = {
14312
- class: "table__row"
14313
- };
14314
- const _hoisted_6$4 = {
14315
- key: 0,
14316
- scope: "col"
14317
- };
14318
- const _hoisted_7$3 = {
14319
- class: "sr-only"
14320
- };
14321
- const _hoisted_8$3 = {
14322
- key: 1,
14323
- scope: "col"
14324
- };
14325
- const _hoisted_9$3 = {
14326
- class: "sr-only"
14327
- };
14328
- const _hoisted_10$2 = ["innerHTML"];
14329
- const _hoisted_11$1 = {
14330
- key: 1,
14331
- class: "table__column__description"
14332
- };
14333
- const _hoisted_12$1 = ["aria-label", "aria-expanded", "aria-level", "aria-describedby", "onKeydown", "onClick"];
14334
- const _hoisted_13 = {
14335
- key: 0
14336
- };
14337
- const _hoisted_14 = {
14338
- key: 0,
14339
- class: "table__expand-icon"
14340
- };
14341
- const _hoisted_15 = {
14342
- key: 1,
14343
- class: "table__column--selectable"
14344
- };
14345
- const _hoisted_16 = {
14346
- class: "table__input"
14347
- };
14348
- const _hoisted_17 = {
14349
- key: 0,
14350
- class: "sr-only"
14351
- };
14352
- const _hoisted_18 = {
14353
- key: 0,
14354
- class: "table__column--placeholder"
14355
- };
14356
- const _hoisted_19 = ["colspan"];
14357
- const _hoisted_20 = {
14358
- key: 0
14359
- };
14360
- const _hoisted_21 = {
14361
- key: 1
14362
- };
14363
- const _hoisted_22 = ["colspan"];
14364
- function _sfc_render$f(_ctx, _cache, $props, $setup, $data, $options) {
14365
- const _component_f_icon = vue.resolveComponent("f-icon");
14366
- const _component_f_checkbox_field = vue.resolveComponent("f-checkbox-field");
14367
- return vue.openBlock(), vue.createElementBlock("div", {
14368
- class: vue.normalizeClass(_ctx.wrapperClasses)
14369
- }, [vue.createElementVNode("table", vue.mergeProps({
14370
- class: ["table", _ctx.tableClasses],
14371
- role: _ctx.tableRole
14372
- }, _ctx.$attrs), [_ctx.hasCaption ? (vue.openBlock(), vue.createElementBlock("caption", _hoisted_2$d, [vue.renderSlot(_ctx.$slots, "caption")])) : vue.createCommentVNode("", true), _cache[15] || (_cache[15] = vue.createTextVNode()), vue.createElementVNode("colgroup", null, [_ctx.isExpandableTable ? (vue.openBlock(), vue.createElementBlock("col", _hoisted_3$9)) : vue.createCommentVNode("", true), _cache[0] || (_cache[0] = vue.createTextVNode()), _ctx.selectable ? (vue.openBlock(), vue.createElementBlock("col", _hoisted_4$8)) : vue.createCommentVNode("", true), _cache[1] || (_cache[1] = vue.createTextVNode()), (vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(_ctx.columns, (column) => {
14373
- return vue.openBlock(), vue.createElementBlock("col", {
14374
- key: column.id,
14375
- class: vue.normalizeClass(column.size)
14376
- }, null, 2);
14377
- }), 128))]), _cache[16] || (_cache[16] = vue.createTextVNode()), vue.createElementVNode("thead", null, [vue.createElementVNode("tr", _hoisted_5$6, [_ctx.isExpandableTable ? (vue.openBlock(), vue.createElementBlock("th", _hoisted_6$4, [vue.createElementVNode("span", _hoisted_7$3, vue.toDisplayString(_ctx.$t("fkui.interactive-table.select", "Expandera")), 1)])) : vue.createCommentVNode("", true), _cache[4] || (_cache[4] = vue.createTextVNode()), _ctx.selectable ? (vue.openBlock(), vue.createElementBlock("th", _hoisted_8$3, [vue.createElementVNode("span", _hoisted_9$3, vue.toDisplayString(_ctx.$t("fkui.interactive-table.select", "Markera")), 1)])) : vue.createCommentVNode("", true), _cache[5] || (_cache[5] = vue.createTextVNode()), (vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(_ctx.visibleColumns, (column) => {
14378
- return vue.openBlock(), vue.createElementBlock("th", vue.mergeProps({
14379
- key: column.id,
14380
- scope: "col",
14381
- class: _ctx.columnClasses(column)
14382
- }, vue.toHandlers(column.sortable ? {
14383
- click: () => _ctx.onClickColumnHeader(column)
14384
- } : {}, true)), [vue.createElementVNode("span", {
14385
- innerHTML: _ctx.escapeNewlines(column.title)
14386
- }, null, 8, _hoisted_10$2), _cache[2] || (_cache[2] = vue.createTextVNode()), column.sortable ? (vue.openBlock(), vue.createBlock(_component_f_icon, {
14387
- key: 0,
14388
- class: vue.normalizeClass(_ctx.iconClasses(column)),
14389
- name: _ctx.iconName(column)
14390
- }, null, 8, ["class", "name"])) : vue.createCommentVNode("", true), _cache[3] || (_cache[3] = vue.createTextVNode()), column.description ? (vue.openBlock(), vue.createElementBlock("span", _hoisted_11$1, vue.toDisplayString(column.description), 1)) : vue.createCommentVNode("", true)], 16);
14391
- }), 128))])]), _cache[17] || (_cache[17] = vue.createTextVNode()), (vue.openBlock(), vue.createElementBlock("tbody", {
14392
- ref: "tbodyElement",
14393
- key: _ctx.tbodyKey
14394
- }, [(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(_ctx.rows, (row, index) => {
14395
- return vue.openBlock(), vue.createElementBlock(vue.Fragment, {
14396
- key: _ctx.rowKey(row)
14397
- }, [vue.createElementVNode("tr", {
14398
- class: vue.normalizeClass(_ctx.rowClasses(row, index)),
14399
- "aria-label": _ctx.rowDescription(row),
14400
- "aria-expanded": _ctx.rowAriaExpanded(row),
14401
- "aria-level": _ctx.isExpandableTable ? 1 : void 0,
14402
- "aria-describedby": _ctx.getExpandableDescribedby(row),
14403
- tabindex: "0",
14404
- onKeydown: vue.withModifiers(($event) => _ctx.onKeydown($event, index), ["self"]),
14405
- onClick: ($event) => _ctx.onClick($event, row, index)
14406
- }, [_ctx.isExpandableTable ? (vue.openBlock(), vue.createElementBlock("td", _hoisted_13, [_ctx.hasExpandableContent(row) ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_14, [vue.createVNode(_component_f_icon, {
14407
- name: "arrow-right",
14408
- rotate: _ctx.isExpanded(row) ? "270" : "90"
14409
- }, null, 8, ["rotate"])])) : vue.createCommentVNode("", true)])) : vue.createCommentVNode("", true), _cache[6] || (_cache[6] = vue.createTextVNode()), _ctx.selectable ? (vue.openBlock(), vue.createElementBlock("td", _hoisted_15, [vue.createElementVNode("div", _hoisted_16, [vue.createVNode(_component_f_checkbox_field, {
14410
- value: true,
14411
- "model-value": _ctx.isSelected(row),
14412
- onClick: vue.withModifiers(($event) => _ctx.onSelect(row), ["self"])
14413
- }, {
14414
- default: vue.withCtx(() => [_ctx.hasCheckboxDescription ? (vue.openBlock(), vue.createElementBlock("span", _hoisted_17, [vue.renderSlot(_ctx.$slots, "checkbox-description", vue.mergeProps({
14415
- ref_for: true
14416
- }, {
14417
- row
14418
- }))])) : vue.createCommentVNode("", true)]),
14419
- _: 2
14420
- }, 1032, ["model-value", "onClick"])])])) : vue.createCommentVNode("", true), _cache[7] || (_cache[7] = vue.createTextVNode()), vue.renderSlot(_ctx.$slots, "default", vue.mergeProps({
14421
- ref_for: true
14422
- }, {
14423
- row
14424
- }))], 42, _hoisted_12$1), _cache[11] || (_cache[11] = vue.createTextVNode()), _ctx.isExpandableTable && _ctx.hasExpandableContent(row) ? (vue.openBlock(true), vue.createElementBlock(vue.Fragment, {
14425
- key: 0
14426
- }, vue.renderList(_ctx.expandableRows(row), (expandableRow, expandableIndex) => {
14427
- return vue.openBlock(), vue.createElementBlock("tr", {
14428
- key: _ctx.rowKey(expandableRow),
14429
- "aria-level": "2",
14430
- class: vue.normalizeClass(_ctx.expandableRowClasses(row, expandableIndex))
14431
- }, [_cache[8] || (_cache[8] = vue.createElementVNode("td", {
14432
- class: "table__column--placeholder"
14433
- }, null, -1)), _cache[9] || (_cache[9] = vue.createTextVNode()), _ctx.selectable ? (vue.openBlock(), vue.createElementBlock("td", _hoisted_18)) : vue.createCommentVNode("", true), _cache[10] || (_cache[10] = vue.createTextVNode()), !_ctx.hasExpandableSlot ? vue.renderSlot(_ctx.$slots, "default", vue.mergeProps({
14434
- key: 1,
14435
- ref_for: true
14436
- }, {
14437
- row: expandableRow
14438
- })) : (vue.openBlock(), vue.createElementBlock("td", {
14439
- key: 2,
14440
- class: "table__column table__column--indented",
14441
- colspan: _ctx.columns.length
14442
- }, [vue.renderSlot(_ctx.$slots, "expandable", vue.mergeProps({
14443
- ref_for: true
14444
- }, {
14445
- expandableRow,
14446
- parentRow: row
14447
- }))], 8, _hoisted_19))], 2);
14448
- }), 128)) : vue.createCommentVNode("", true)], 64);
14449
- }), 128)), _cache[13] || (_cache[13] = vue.createTextVNode()), _ctx.isEmpty && _ctx.columns.length === 0 ? (vue.openBlock(), vue.createElementBlock("tr", _hoisted_20, [vue.renderSlot(_ctx.$slots, "default", vue.normalizeProps(vue.guardReactiveProps({
14450
- row: {}
14451
- })))])) : vue.createCommentVNode("", true), _cache[14] || (_cache[14] = vue.createTextVNode()), _ctx.isEmpty ? (vue.openBlock(), vue.createElementBlock("tr", _hoisted_21, [vue.createElementVNode("td", {
14452
- class: "table__column table__column--action",
14453
- colspan: _ctx.nbOfColumns
14454
- }, [vue.renderSlot(_ctx.$slots, "empty", {}, () => [vue.createTextVNode(vue.toDisplayString(_ctx.$t("fkui.interactive-table.empty", "Tabellen är tom")), 1)])], 8, _hoisted_22), _cache[12] || (_cache[12] = vue.createTextVNode()), vue.renderSlot(_ctx.$slots, "default", vue.normalizeProps(vue.guardReactiveProps({
14455
- row: {}
14456
- })))])) : vue.createCommentVNode("", true)]))], 16, _hoisted_1$h)], 2);
14457
- }
14458
- const FInteractiveTable = /* @__PURE__ */ _export_sfc(_sfc_main$h, [["render", _sfc_render$f]]);
14459
- const _sfc_main$g = vue.defineComponent({
14413
+ const _sfc_main$h = vue.defineComponent({
14460
14414
  name: "FLayoutApplicationTemplate",
14461
14415
  computed: {
14462
14416
  showHeader() {
@@ -14481,7 +14435,7 @@ const _sfc_main$g = vue.defineComponent({
14481
14435
  }
14482
14436
  }
14483
14437
  });
14484
- const _hoisted_1$g = {
14438
+ const _hoisted_1$h = {
14485
14439
  class: "layout-application-template"
14486
14440
  };
14487
14441
  const _hoisted_2$c = {
@@ -14500,12 +14454,12 @@ const _hoisted_5$5 = {
14500
14454
  key: 0,
14501
14455
  class: "layout-application-template__footer"
14502
14456
  };
14503
- function _sfc_render$e(_ctx, _cache, $props, $setup, $data, $options) {
14504
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$g, [_ctx.showHeader || _ctx.showTopNavigation ? (vue.openBlock(), vue.createElementBlock("header", _hoisted_2$c, [_ctx.showHeader ? vue.renderSlot(_ctx.$slots, "header", {
14457
+ function _sfc_render$d(_ctx, _cache, $props, $setup, $data, $options) {
14458
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$h, [_ctx.showHeader || _ctx.showTopNavigation ? (vue.openBlock(), vue.createElementBlock("header", _hoisted_2$c, [_ctx.showHeader ? vue.renderSlot(_ctx.$slots, "header", {
14505
14459
  key: 0
14506
14460
  }) : vue.createCommentVNode("", true), _cache[0] || (_cache[0] = vue.createTextVNode()), _ctx.showTopNavigation ? (vue.openBlock(), vue.createElementBlock("nav", _hoisted_3$8, [vue.renderSlot(_ctx.$slots, "top-navigation")])) : vue.createCommentVNode("", true)], 512)) : vue.createCommentVNode("", true), _cache[2] || (_cache[2] = vue.createTextVNode()), vue.createElementVNode("main", _hoisted_4$7, [vue.renderSlot(_ctx.$slots, "default"), _cache[1] || (_cache[1] = vue.createTextVNode()), _ctx.showFooter ? (vue.openBlock(), vue.createElementBlock("footer", _hoisted_5$5, [vue.renderSlot(_ctx.$slots, "footer")])) : vue.createCommentVNode("", true)], 512)]);
14507
14461
  }
14508
- const FLayoutApplicationTemplate = /* @__PURE__ */ _export_sfc(_sfc_main$g, [["render", _sfc_render$e]]);
14462
+ const FLayoutApplicationTemplate = /* @__PURE__ */ _export_sfc(_sfc_main$h, [["render", _sfc_render$d]]);
14509
14463
  function getGridClasses(target) {
14510
14464
  if (target === null) {
14511
14465
  return {};
@@ -14606,7 +14560,7 @@ function useLayoutPanel(options) {
14606
14560
  rightPrimaryClasses
14607
14561
  };
14608
14562
  }
14609
- const _sfc_main$f = vue.defineComponent({
14563
+ const _sfc_main$g = vue.defineComponent({
14610
14564
  name: "FLayoutLeftPanel",
14611
14565
  components: {
14612
14566
  FIcon
@@ -14691,7 +14645,7 @@ const _sfc_main$f = vue.defineComponent({
14691
14645
  }
14692
14646
  }
14693
14647
  });
14694
- const _hoisted_1$f = {
14648
+ const _hoisted_1$g = {
14695
14649
  class: "layout-navigation"
14696
14650
  };
14697
14651
  const _hoisted_2$b = ["aria-expanded"];
@@ -14702,9 +14656,9 @@ const _hoisted_4$6 = {
14702
14656
  key: 1,
14703
14657
  class: "layout-navigation__navigation__inner--minimized"
14704
14658
  };
14705
- function _sfc_render$d(_ctx, _cache, $props, $setup, $data, $options) {
14659
+ function _sfc_render$c(_ctx, _cache, $props, $setup, $data, $options) {
14706
14660
  const _component_f_icon = vue.resolveComponent("f-icon");
14707
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$f, [vue.createElementVNode("nav", {
14661
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$g, [vue.createElementVNode("nav", {
14708
14662
  id: "layout-navigation__navigation",
14709
14663
  class: "layout-navigation__navigation",
14710
14664
  style: vue.normalizeStyle(_ctx.navigationStyle),
@@ -14753,7 +14707,7 @@ function _sfc_render$d(_ctx, _cache, $props, $setup, $data, $options) {
14753
14707
  style: vue.normalizeStyle(_ctx.primaryStyle)
14754
14708
  }, [vue.renderSlot(_ctx.$slots, "default")], 6)]);
14755
14709
  }
14756
- const FLayoutLeftPanel = /* @__PURE__ */ _export_sfc(_sfc_main$f, [["render", _sfc_render$d]]);
14710
+ const FLayoutLeftPanel = /* @__PURE__ */ _export_sfc(_sfc_main$g, [["render", _sfc_render$c]]);
14757
14711
  class FRightPanelServiceImpl {
14758
14712
  constructor() {
14759
14713
  _defineProperty(this, "focusedElementBeforeOpenining", null);
@@ -14783,7 +14737,7 @@ class FRightPanelServiceImpl {
14783
14737
  }
14784
14738
  }
14785
14739
  const FLayoutRightPanelService = new FRightPanelServiceImpl();
14786
- const _sfc_main$e = vue.defineComponent({
14740
+ const _sfc_main$f = vue.defineComponent({
14787
14741
  name: "FLayoutRightPanel",
14788
14742
  components: {
14789
14743
  FIcon
@@ -14900,15 +14854,15 @@ const _sfc_main$e = vue.defineComponent({
14900
14854
  }
14901
14855
  }
14902
14856
  });
14903
- const _hoisted_1$e = {
14857
+ const _hoisted_1$f = {
14904
14858
  class: "layout-secondary"
14905
14859
  };
14906
14860
  const _hoisted_2$a = {
14907
14861
  class: "layout-secondary__secondary__inner"
14908
14862
  };
14909
- function _sfc_render$c(_ctx, _cache, $props, $setup, $data, $options) {
14863
+ function _sfc_render$b(_ctx, _cache, $props, $setup, $data, $options) {
14910
14864
  const _component_f_icon = vue.resolveComponent("f-icon");
14911
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$e, [vue.createElementVNode("div", {
14865
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$f, [vue.createElementVNode("div", {
14912
14866
  id: "layout-secondary__primary",
14913
14867
  class: vue.normalizeClass(["layout-secondary__primary", _ctx.rightPrimaryClasses]),
14914
14868
  style: vue.normalizeStyle(_ctx.primaryStyle)
@@ -14945,13 +14899,34 @@ function _sfc_render$c(_ctx, _cache, $props, $setup, $data, $options) {
14945
14899
  name: "close"
14946
14900
  })])], 6)])], 4)) : vue.createCommentVNode("", true)]);
14947
14901
  }
14948
- const FLayoutRightPanel = /* @__PURE__ */ _export_sfc(_sfc_main$e, [["render", _sfc_render$c]]);
14949
- const _sfc_main$d = vue.defineComponent({
14950
- name: "FList",
14951
- components: {
14952
- FCheckboxField
14953
- },
14954
- mixins: [TranslationMixin],
14902
+ const FLayoutRightPanel = /* @__PURE__ */ _export_sfc(_sfc_main$f, [["render", _sfc_render$b]]);
14903
+ const _hoisted_1$e = {
14904
+ key: 0,
14905
+ class: "list"
14906
+ };
14907
+ const _hoisted_2$9 = {
14908
+ key: 0,
14909
+ class: "list__item"
14910
+ };
14911
+ const _hoisted_3$6 = {
14912
+ class: "list__item__itempane"
14913
+ };
14914
+ const _hoisted_4$5 = ["tabindex"];
14915
+ const _hoisted_5$4 = ["id", "aria-labelledby", "tabindex", "onKeydown"];
14916
+ const _hoisted_6$3 = ["onClick"];
14917
+ const _hoisted_7$2 = {
14918
+ class: "list__item__selectpane__input"
14919
+ };
14920
+ const _hoisted_8$2 = ["id"];
14921
+ const _hoisted_9$2 = {
14922
+ key: 0,
14923
+ class: "list__item"
14924
+ };
14925
+ const _hoisted_10$1 = {
14926
+ class: "list__item__itempane"
14927
+ };
14928
+ const _sfc_main$e = /* @__PURE__ */ vue.defineComponent({
14929
+ __name: "FList",
14955
14930
  props: {
14956
14931
  /**
14957
14932
  * The items to be listed.
@@ -15011,274 +14986,235 @@ const _sfc_main$d = vue.defineComponent({
15011
14986
  default: () => logic.ElementIdService.generateElementId()
15012
14987
  }
15013
14988
  },
15014
- emits: ["change", "click", "unselect", "update:modelValue", "select", "update:active"],
15015
- setup() {
15016
- return ActivateItemInjected();
15017
- },
15018
- data() {
15019
- return {
15020
- selectedItems: [],
15021
- activeItem: void 0
15022
- };
15023
- },
15024
- computed: {
15025
- isEmpty() {
15026
- return this.items.length === 0;
15027
- },
15028
- ariaActiveDescendant() {
15029
- return this.activeItem ? this.getItemId(this.activeItem) : void 0;
15030
- }
15031
- },
15032
- watch: {
15033
- items: {
14989
+ emits: ["change", "click", "select", "unselect", "update:active", "update:modelValue"],
14990
+ setup(__props, {
14991
+ emit: __emit
14992
+ }) {
14993
+ const $t2 = useTranslate();
14994
+ const slots = vue.useSlots();
14995
+ const {
14996
+ registerCallbackAfterItemAdd,
14997
+ registerCallbackBeforeItemDelete
14998
+ } = ActivateItemInjected();
14999
+ const selectedItems = vue.ref([]);
15000
+ const activeItem = vue.ref(void 0);
15001
+ const ulElement = vue.ref();
15002
+ const props = __props;
15003
+ const emit = __emit;
15004
+ const isEmpty = vue.computed(() => {
15005
+ return props.items.length === 0;
15006
+ });
15007
+ vue.watch(() => props.items, () => {
15008
+ updateSelectedItemsFromVModel();
15009
+ }, {
15034
15010
  deep: true,
15035
- immediate: true,
15036
- handler: function() {
15037
- this.updateSelectedItemsFromVModel();
15038
- }
15039
- },
15040
- modelValue: {
15011
+ immediate: true
15012
+ });
15013
+ vue.watch(() => props.modelValue, () => {
15014
+ updateSelectedItemsFromVModel();
15015
+ }, {
15041
15016
  deep: true,
15042
- immediate: true,
15043
- handler: function() {
15044
- this.updateSelectedItemsFromVModel();
15045
- }
15046
- },
15047
- active: {
15048
- immediate: true,
15049
- handler: function() {
15050
- this.updateActiveItemFromVModel();
15051
- }
15052
- }
15053
- },
15054
- mounted() {
15055
- if (this.selectable && this.checkbox) {
15056
- if (!this.$slots["screenreader"]) {
15057
- throw Error('Slot "screenreader" is required when having "selectable" & "checkbox" option.');
15017
+ immediate: true
15018
+ });
15019
+ vue.watch(() => props.active, () => {
15020
+ updateActiveItemFromVModel();
15021
+ }, {
15022
+ immediate: true
15023
+ });
15024
+ vue.onMounted(() => {
15025
+ if (props.selectable && props.checkbox) {
15026
+ if (!slots["screenreader"]) {
15027
+ throw Error('Slot "screenreader" is required when having "selectable" & "checkbox" option.');
15028
+ }
15029
+ registerCallbackAfterItemAdd(callbackAfterItemAdd);
15030
+ registerCallbackBeforeItemDelete(callbackBeforeItemDelete);
15058
15031
  }
15059
- this.registerCallbackAfterItemAdd(this.callbackAfterItemAdd);
15060
- this.registerCallbackBeforeItemDelete(this.callbackBeforeItemDelete);
15032
+ });
15033
+ function getLiElements() {
15034
+ const element = getElementFromVueRef(ulElement.value);
15035
+ return Array.from(element.children);
15061
15036
  }
15062
- },
15063
- methods: {
15064
- getLiElements() {
15065
- const ulElement = getElementFromVueRef(this.$refs["ulElement"]);
15066
- return Array.from(ulElement.children);
15067
- },
15068
- itemKey(item) {
15069
- const key = item[this.keyAttribute];
15037
+ function itemKey(item) {
15038
+ const key = item[props.keyAttribute];
15070
15039
  if (typeof key === "undefined") {
15071
- throw new Error(`Key attribute [${this.keyAttribute}]' is missing in item`);
15040
+ throw new Error(`Key attribute [${props.keyAttribute}]' is missing in item`);
15072
15041
  }
15073
15042
  return String(key);
15074
- },
15075
- isSelected(item) {
15076
- return includeItem(item, this.selectedItems, this.keyAttribute);
15077
- },
15078
- itemClasses(item) {
15043
+ }
15044
+ function isSelected(item) {
15045
+ return includeItem(item, selectedItems.value, props.keyAttribute);
15046
+ }
15047
+ function itemClasses(item) {
15079
15048
  return {
15080
- "list__item--selected": this.isSelected(item),
15081
- "list__item--active": this.isActive(item)
15049
+ "list__item--selected": isSelected(item),
15050
+ "list__item--active": isActive(item)
15082
15051
  };
15083
- },
15084
- getAriaSelected(item) {
15085
- return String(itemEquals(this.activeItem, item, this.keyAttribute));
15086
- },
15087
- onSelect(item) {
15088
- if (includeItem(item, this.selectedItems, this.keyAttribute)) {
15089
- this.selectedItems = this.selectedItems.filter((i) => !itemEquals(i, item, this.keyAttribute));
15090
- this.$emit("unselect", item);
15052
+ }
15053
+ function onSelect(item) {
15054
+ var _a, _b;
15055
+ if (includeItem(item, selectedItems.value, props.keyAttribute)) {
15056
+ selectedItems.value = selectedItems.value.filter((i) => !itemEquals(i, item, props.keyAttribute));
15057
+ emit("unselect", item);
15091
15058
  } else {
15092
- this.selectedItems.push(item);
15093
- this.$emit("select", item);
15059
+ selectedItems.value.push(item);
15060
+ emit("select", item);
15094
15061
  }
15095
- this.updateVModelWithSelectedItems();
15096
- this.$forceUpdate();
15097
- },
15098
- setActiveItem(item) {
15099
- this.$emit("click", item);
15100
- if (!itemEquals(item, this.activeItem, this.keyAttribute)) {
15101
- this.$emit("change", item);
15102
- this.activeItem = item;
15103
- this.$emit("update:active", this.activeItem);
15062
+ updateVModelWithSelectedItems();
15063
+ (_b = (_a = vue.getCurrentInstance()) == null ? void 0 : _a.proxy) == null ? void 0 : _b.$forceUpdate();
15064
+ }
15065
+ function setActiveItem(item) {
15066
+ emit("click", item);
15067
+ if (!itemEquals(item, activeItem.value, props.keyAttribute)) {
15068
+ emit("change", item);
15069
+ activeItem.value = item;
15070
+ emit("update:active", activeItem.value);
15104
15071
  }
15105
- },
15106
- onItemClick(event, index, item) {
15107
- this.setActiveItem(item);
15108
- },
15109
- updateVModelWithSelectedItems() {
15110
- if (this.modelValue) {
15111
- this.$emit("update:modelValue", this.selectedItems);
15072
+ }
15073
+ function onItemClick(event, index, item) {
15074
+ setActiveItem(item);
15075
+ }
15076
+ function updateVModelWithSelectedItems() {
15077
+ if (props.modelValue) {
15078
+ emit("update:modelValue", selectedItems.value);
15112
15079
  }
15113
- },
15114
- updateSelectedItemsFromVModel() {
15115
- if (Array.isArray(this.modelValue)) {
15116
- this.selectedItems = this.modelValue.filter((item) => {
15117
- return includeItem(item, this.items, this.keyAttribute);
15080
+ }
15081
+ function updateSelectedItemsFromVModel() {
15082
+ if (Array.isArray(props.modelValue)) {
15083
+ selectedItems.value = props.modelValue.filter((item) => {
15084
+ return includeItem(item, props.items, props.keyAttribute);
15118
15085
  });
15119
15086
  } else {
15120
- this.selectedItems = [];
15087
+ selectedItems.value = [];
15121
15088
  }
15122
- },
15123
- updateActiveItemFromVModel() {
15124
- if (this.active === void 0) {
15125
- this.activeItem = void 0;
15126
- } else if (!itemEquals(this.active, this.activeItem, this.keyAttribute)) {
15127
- this.activeItem = this.active;
15089
+ }
15090
+ function updateActiveItemFromVModel() {
15091
+ if (props.active === void 0) {
15092
+ activeItem.value = void 0;
15093
+ } else if (!itemEquals(props.active, activeItem.value, props.keyAttribute)) {
15094
+ activeItem.value = props.active;
15128
15095
  }
15129
- },
15130
- onItemKeyDown(event, item) {
15096
+ }
15097
+ function onItemKeyDown(event, item) {
15131
15098
  switch (event.key) {
15132
15099
  case "Up":
15133
15100
  case "Down":
15134
15101
  case "ArrowUp":
15135
15102
  case "ArrowDown":
15136
15103
  event.preventDefault();
15137
- handleKeyboardFocusNavigation(event.key, event.target, this.getLiElements());
15104
+ handleKeyboardFocusNavigation(event.key, event.target, getLiElements());
15138
15105
  break;
15139
15106
  case " ":
15140
15107
  case "Spacebar":
15141
15108
  event.preventDefault();
15142
- this.setActiveItem(item);
15109
+ setActiveItem(item);
15143
15110
  break;
15144
15111
  }
15145
- },
15146
- // Unique id to connect aria-labelledby with readonly label
15147
- getAriaLabelledbyId(item) {
15148
- return `${this.elementId}_${this.itemKey(item)}`;
15149
- },
15150
- // Unique id to connect aria-labelledby with readonly label
15151
- getItemId(item) {
15152
- return `${this.elementId}_item_${this.itemKey(item)}`;
15153
- },
15154
- // Focus effect is done with box-shadow.
15155
- // By setting position to relative the
15156
- // item and box-shadow is drawn with a higher z-index,
15157
- // thus no focus border under other list items.
15158
- onItemFocus(event) {
15112
+ }
15113
+ function getAriaLabelledbyId(item) {
15114
+ return `${props.elementId}_${itemKey(item)}`;
15115
+ }
15116
+ function getItemId(item) {
15117
+ return `${props.elementId}_item_${itemKey(item)}`;
15118
+ }
15119
+ function onItemFocus(event) {
15159
15120
  if (event && event.target) {
15160
15121
  event.target.style.position = "relative";
15161
15122
  }
15162
- },
15163
- onItemBlur(event) {
15123
+ }
15124
+ function onItemBlur(event) {
15164
15125
  if (event && event.target) {
15165
15126
  event.target.style.position = "static";
15166
15127
  }
15167
- },
15168
- callbackAfterItemAdd(item) {
15169
- this.setActiveItem(item);
15170
- },
15171
- callbackBeforeItemDelete(item) {
15172
- if (this.items.length === 0) {
15128
+ }
15129
+ function callbackAfterItemAdd(item) {
15130
+ setActiveItem(item);
15131
+ }
15132
+ function callbackBeforeItemDelete(item) {
15133
+ if (props.items.length === 0) {
15173
15134
  return;
15174
15135
  }
15175
- let targetIndex = this.items.indexOf(item) - 1;
15176
- if (targetIndex < 0 && this.items.length > 1) {
15136
+ let targetIndex = props.items.indexOf(item) - 1;
15137
+ if (targetIndex < 0 && props.items.length > 1) {
15177
15138
  targetIndex = 1;
15178
15139
  } else if (targetIndex < 0) {
15179
15140
  targetIndex = 0;
15180
15141
  }
15181
- this.setActiveItem(this.items[targetIndex]);
15182
- if (this.getLiElements()[targetIndex]) {
15183
- this.getLiElements()[targetIndex].focus();
15142
+ setActiveItem(props.items[targetIndex]);
15143
+ const targetElement = getLiElements()[targetIndex];
15144
+ if (targetElement) {
15145
+ targetElement.focus();
15184
15146
  }
15185
- },
15186
- isActive(item) {
15187
- return this.checkbox && itemEquals(this.activeItem, item, this.keyAttribute);
15188
15147
  }
15148
+ function isActive(item) {
15149
+ return props.checkbox && itemEquals(activeItem.value, item, props.keyAttribute);
15150
+ }
15151
+ return (_ctx, _cache) => {
15152
+ return !__props.selectable ? (vue.openBlock(), vue.createElementBlock("ul", _hoisted_1$e, [(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(__props.items, (item) => {
15153
+ return vue.openBlock(), vue.createElementBlock("li", {
15154
+ key: itemKey(item),
15155
+ class: "list__item"
15156
+ }, [vue.createElementVNode("div", {
15157
+ ref_for: true,
15158
+ ref: "listItemPanes",
15159
+ class: "list__item__itempane"
15160
+ }, [vue.renderSlot(_ctx.$slots, "default", vue.mergeProps({
15161
+ ref_for: true
15162
+ }, {
15163
+ item
15164
+ }))], 512)]);
15165
+ }), 128)), _cache[0] || (_cache[0] = vue.createTextVNode()), isEmpty.value ? (vue.openBlock(), vue.createElementBlock("li", _hoisted_2$9, [vue.createElementVNode("div", _hoisted_3$6, [vue.renderSlot(_ctx.$slots, "empty", {}, () => [vue.createElementVNode("em", null, vue.toDisplayString(vue.unref($t2)("fkui.list.empty", "Listan är tom")), 1)])])])) : vue.createCommentVNode("", true)])) : (vue.openBlock(), vue.createElementBlock("ul", {
15166
+ key: 1,
15167
+ ref_key: "ulElement",
15168
+ ref: ulElement,
15169
+ class: "list list--hover",
15170
+ tabindex: __props.checkbox ? 0 : void 0
15171
+ }, [(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(__props.items, (item, index) => {
15172
+ return vue.openBlock(), vue.createElementBlock("li", {
15173
+ id: getItemId(item),
15174
+ key: itemKey(item),
15175
+ "aria-labelledby": getItemId(item),
15176
+ class: vue.normalizeClass([itemClasses(item), "list__item"]),
15177
+ tabindex: __props.checkbox ? 0 : void 0,
15178
+ onKeydown: vue.withModifiers(($event) => onItemKeyDown($event, item), ["self"]),
15179
+ onFocus: vue.withModifiers(onItemFocus, ["self"]),
15180
+ onBlur: vue.withModifiers(onItemBlur, ["self"])
15181
+ }, [__props.checkbox ? (vue.openBlock(), vue.createElementBlock("div", {
15182
+ key: 0,
15183
+ class: "list__item__selectpane",
15184
+ onClick: vue.withModifiers(($event) => onSelect(item), ["self"])
15185
+ }, [vue.createElementVNode("div", _hoisted_7$2, [vue.createVNode(vue.unref(FCheckboxField), {
15186
+ value: true,
15187
+ "model-value": isSelected(item),
15188
+ onClick: vue.withModifiers(($event) => onSelect(item), ["self"])
15189
+ }, {
15190
+ default: vue.withCtx(() => [vue.createElementVNode("span", {
15191
+ id: getAriaLabelledbyId(item),
15192
+ class: "sr-only"
15193
+ }, [vue.renderSlot(_ctx.$slots, "screenreader", vue.mergeProps({
15194
+ ref_for: true
15195
+ }, {
15196
+ item
15197
+ }))], 8, _hoisted_8$2)]),
15198
+ _: 2
15199
+ }, 1032, ["model-value", "onClick"])])], 8, _hoisted_6$3)) : vue.createCommentVNode("", true), _cache[1] || (_cache[1] = vue.createTextVNode()), (vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(__props.checkbox ? "div" : "a"), {
15200
+ ref_for: true,
15201
+ ref: "listItemPanes",
15202
+ href: !__props.checkbox ? "javascript:" : void 0,
15203
+ class: "list__item__itempane",
15204
+ onClick: ($event) => onItemClick($event, index, item)
15205
+ }, {
15206
+ default: vue.withCtx(() => [vue.renderSlot(_ctx.$slots, "default", vue.mergeProps({
15207
+ ref_for: true
15208
+ }, {
15209
+ item
15210
+ }))]),
15211
+ _: 2
15212
+ }, 1032, ["href", "onClick"]))], 42, _hoisted_5$4);
15213
+ }), 128)), _cache[2] || (_cache[2] = vue.createTextVNode()), isEmpty.value ? (vue.openBlock(), vue.createElementBlock("li", _hoisted_9$2, [vue.createElementVNode("div", _hoisted_10$1, [vue.renderSlot(_ctx.$slots, "empty", {}, () => [vue.createElementVNode("em", null, vue.toDisplayString(vue.unref($t2)("fkui.list.empty", "Listan är tom")), 1)])])])) : vue.createCommentVNode("", true)], 8, _hoisted_4$5));
15214
+ };
15189
15215
  }
15190
15216
  });
15191
- const _hoisted_1$d = {
15192
- key: 0,
15193
- class: "list"
15194
- };
15195
- const _hoisted_2$9 = {
15196
- key: 0,
15197
- class: "list__item"
15198
- };
15199
- const _hoisted_3$6 = {
15200
- class: "list__item__itempane"
15201
- };
15202
- const _hoisted_4$5 = ["tabindex"];
15203
- const _hoisted_5$4 = ["id", "aria-labelledby", "tabindex", "onKeydown"];
15204
- const _hoisted_6$3 = ["onClick"];
15205
- const _hoisted_7$2 = {
15206
- class: "list__item__selectpane__input"
15207
- };
15208
- const _hoisted_8$2 = ["id"];
15209
- const _hoisted_9$2 = {
15210
- key: 0,
15211
- class: "list__item"
15212
- };
15213
- const _hoisted_10$1 = {
15214
- class: "list__item__itempane"
15215
- };
15216
- function _sfc_render$b(_ctx, _cache, $props, $setup, $data, $options) {
15217
- const _component_f_checkbox_field = vue.resolveComponent("f-checkbox-field");
15218
- return !_ctx.selectable ? (vue.openBlock(), vue.createElementBlock("ul", _hoisted_1$d, [(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(_ctx.items, (item) => {
15219
- return vue.openBlock(), vue.createElementBlock("li", {
15220
- key: _ctx.itemKey(item),
15221
- class: "list__item"
15222
- }, [vue.createElementVNode("div", {
15223
- ref_for: true,
15224
- ref: "listItemPanes",
15225
- class: "list__item__itempane"
15226
- }, [vue.renderSlot(_ctx.$slots, "default", vue.mergeProps({
15227
- ref_for: true
15228
- }, {
15229
- item
15230
- }))], 512)]);
15231
- }), 128)), _cache[2] || (_cache[2] = vue.createTextVNode()), _ctx.isEmpty ? (vue.openBlock(), vue.createElementBlock("li", _hoisted_2$9, [vue.createElementVNode("div", _hoisted_3$6, [vue.renderSlot(_ctx.$slots, "empty", {}, () => [vue.createElementVNode("em", null, vue.toDisplayString(_ctx.$t("fkui.list.empty", "Listan är tom")), 1)])])])) : vue.createCommentVNode("", true)])) : (vue.openBlock(), vue.createElementBlock("ul", {
15232
- key: 1,
15233
- ref: "ulElement",
15234
- class: "list list--hover",
15235
- tabindex: _ctx.checkbox ? 0 : void 0
15236
- }, [(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(_ctx.items, (item, index) => {
15237
- return vue.openBlock(), vue.createElementBlock("li", {
15238
- id: _ctx.getItemId(item),
15239
- key: _ctx.itemKey(item),
15240
- "aria-labelledby": _ctx.getItemId(item),
15241
- class: vue.normalizeClass([_ctx.itemClasses(item), "list__item"]),
15242
- tabindex: _ctx.checkbox ? 0 : void 0,
15243
- onKeydown: vue.withModifiers(($event) => _ctx.onItemKeyDown($event, item), ["self"]),
15244
- onFocus: _cache[0] || (_cache[0] = vue.withModifiers((...args) => _ctx.onItemFocus && _ctx.onItemFocus(...args), ["self"])),
15245
- onBlur: _cache[1] || (_cache[1] = vue.withModifiers((...args) => _ctx.onItemBlur && _ctx.onItemBlur(...args), ["self"]))
15246
- }, [_ctx.checkbox ? (vue.openBlock(), vue.createElementBlock("div", {
15247
- key: 0,
15248
- class: "list__item__selectpane",
15249
- onClick: vue.withModifiers(($event) => _ctx.onSelect(item), ["self"])
15250
- }, [vue.createElementVNode("div", _hoisted_7$2, [vue.createVNode(_component_f_checkbox_field, {
15251
- value: true,
15252
- "model-value": _ctx.isSelected(item),
15253
- onClick: vue.withModifiers(($event) => _ctx.onSelect(item), ["self"])
15254
- }, {
15255
- default: vue.withCtx(() => [vue.createElementVNode("span", {
15256
- id: _ctx.getAriaLabelledbyId(item),
15257
- class: "sr-only"
15258
- }, [vue.renderSlot(_ctx.$slots, "screenreader", vue.mergeProps({
15259
- ref_for: true
15260
- }, {
15261
- item
15262
- }))], 8, _hoisted_8$2)]),
15263
- _: 2
15264
- }, 1032, ["model-value", "onClick"])])], 8, _hoisted_6$3)) : vue.createCommentVNode("", true), _cache[3] || (_cache[3] = vue.createTextVNode()), (vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(_ctx.checkbox ? "div" : "a"), {
15265
- ref_for: true,
15266
- ref: "listItemPanes",
15267
- href: !_ctx.checkbox ? "javascript:" : void 0,
15268
- class: "list__item__itempane",
15269
- onClick: ($event) => _ctx.onItemClick($event, index, item)
15270
- }, {
15271
- default: vue.withCtx(() => [vue.renderSlot(_ctx.$slots, "default", vue.mergeProps({
15272
- ref_for: true
15273
- }, {
15274
- item
15275
- }))]),
15276
- _: 2
15277
- }, 1032, ["href", "onClick"]))], 42, _hoisted_5$4);
15278
- }), 128)), _cache[4] || (_cache[4] = vue.createTextVNode()), _ctx.isEmpty ? (vue.openBlock(), vue.createElementBlock("li", _hoisted_9$2, [vue.createElementVNode("div", _hoisted_10$1, [vue.renderSlot(_ctx.$slots, "empty", {}, () => [vue.createElementVNode("em", null, vue.toDisplayString(_ctx.$t("fkui.list.empty", "Listan är tom")), 1)])])])) : vue.createCommentVNode("", true)], 8, _hoisted_4$5));
15279
- }
15280
- const FList = /* @__PURE__ */ _export_sfc(_sfc_main$d, [["render", _sfc_render$b]]);
15281
- const _sfc_main$c = vue.defineComponent({
15217
+ const _sfc_main$d = vue.defineComponent({
15282
15218
  name: "FLoader",
15283
15219
  mixins: [TranslationMixin],
15284
15220
  inheritAttrs: false,
@@ -15390,7 +15326,7 @@ const _sfc_main$c = vue.defineComponent({
15390
15326
  }
15391
15327
  }
15392
15328
  });
15393
- const _hoisted_1$c = {
15329
+ const _hoisted_1$d = {
15394
15330
  class: "loader__backdrop"
15395
15331
  };
15396
15332
  const _hoisted_2$8 = {
@@ -15402,7 +15338,7 @@ function _sfc_render$a(_ctx, _cache, $props, $setup, $data, $options) {
15402
15338
  disabled: _ctx.teleportDisabled
15403
15339
  }, [vue.withDirectives(vue.createElementVNode("div", vue.mergeProps(_ctx.$attrs, {
15404
15340
  class: ["loader", _ctx.classes]
15405
- }), [vue.createElementVNode("div", _hoisted_1$c, [_cache[0] || (_cache[0] = vue.createElementVNode("div", {
15341
+ }), [vue.createElementVNode("div", _hoisted_1$d, [_cache[0] || (_cache[0] = vue.createElementVNode("div", {
15406
15342
  class: "loader__wrapper"
15407
15343
  }, [vue.createElementVNode("div", {
15408
15344
  class: "loader__spinner-1 loader__spinner"
@@ -15442,8 +15378,8 @@ function _sfc_render$a(_ctx, _cache, $props, $setup, $data, $options) {
15442
15378
  tabindex: "-1"
15443
15379
  }, [vue.createElementVNode("span", _hoisted_2$8, [vue.renderSlot(_ctx.$slots, "default", {}, () => [vue.createTextVNode(vue.toDisplayString(_ctx.$t("fkui.loader.wait.text", _ctx.defaultLoadingText)), 1)])])], 2)])], 16), [[vue.vShow, _ctx.show]])], 8, ["to", "disabled"]);
15444
15380
  }
15445
- const FLoader = /* @__PURE__ */ _export_sfc(_sfc_main$c, [["render", _sfc_render$a]]);
15446
- const _hoisted_1$b = ["aria-label"];
15381
+ const FLoader = /* @__PURE__ */ _export_sfc(_sfc_main$d, [["render", _sfc_render$a]]);
15382
+ const _hoisted_1$c = ["aria-label"];
15447
15383
  const __default__ = vue.defineComponent({
15448
15384
  computed: {
15449
15385
  ariaLabel() {
@@ -15455,7 +15391,7 @@ const __default__ = vue.defineComponent({
15455
15391
  }
15456
15392
  }
15457
15393
  });
15458
- const _sfc_main$b = /* @__PURE__ */ vue.defineComponent({
15394
+ const _sfc_main$c = /* @__PURE__ */ vue.defineComponent({
15459
15395
  ...__default__,
15460
15396
  __name: "FLogo",
15461
15397
  props: {
@@ -15479,7 +15415,7 @@ const _sfc_main$b = /* @__PURE__ */ vue.defineComponent({
15479
15415
  class: vue.normalizeClass(`logo logo--${props.size}`),
15480
15416
  "aria-label": _ctx.ariaLabel,
15481
15417
  role: "img"
15482
- }, null, 10, _hoisted_1$b);
15418
+ }, null, 10, _hoisted_1$c);
15483
15419
  };
15484
15420
  }
15485
15421
  });
@@ -15509,7 +15445,7 @@ const iconClasses = {
15509
15445
  screenReaderContextDefault: "Informationsmeddelande"
15510
15446
  }
15511
15447
  };
15512
- const _sfc_main$a = vue.defineComponent({
15448
+ const _sfc_main$b = vue.defineComponent({
15513
15449
  name: "FMessageBox",
15514
15450
  components: {
15515
15451
  FIcon,
@@ -15599,7 +15535,7 @@ const _sfc_main$a = vue.defineComponent({
15599
15535
  }
15600
15536
  }
15601
15537
  });
15602
- const _hoisted_1$a = {
15538
+ const _hoisted_1$b = {
15603
15539
  key: 0,
15604
15540
  class: "sr-only"
15605
15541
  };
@@ -15609,7 +15545,7 @@ function _sfc_render$9(_ctx, _cache, $props, $setup, $data, $options) {
15609
15545
  const _component_i_flex = vue.resolveComponent("i-flex");
15610
15546
  return vue.openBlock(), vue.createElementBlock("div", {
15611
15547
  class: vue.normalizeClass(["message-box", [_ctx.messageBoxType, _ctx.bannerType]])
15612
- }, [_ctx.provideScreenReaderContext ? (vue.openBlock(), vue.createElementBlock("span", _hoisted_1$a, vue.toDisplayString(_ctx.screenReaderContext()), 1)) : vue.createCommentVNode("", true), _cache[2] || (_cache[2] = vue.createTextVNode()), vue.createVNode(_component_i_flex, {
15548
+ }, [_ctx.provideScreenReaderContext ? (vue.openBlock(), vue.createElementBlock("span", _hoisted_1$b, vue.toDisplayString(_ctx.screenReaderContext()), 1)) : vue.createCommentVNode("", true), _cache[2] || (_cache[2] = vue.createTextVNode()), vue.createVNode(_component_i_flex, {
15613
15549
  gap: "2x"
15614
15550
  }, {
15615
15551
  default: vue.withCtx(() => [_ctx.layout === "short" ? (vue.openBlock(), vue.createBlock(_component_i_flex_item, {
@@ -15641,7 +15577,7 @@ function _sfc_render$9(_ctx, _cache, $props, $setup, $data, $options) {
15641
15577
  _: 3
15642
15578
  })], 2);
15643
15579
  }
15644
- const FMessageBox = /* @__PURE__ */ _export_sfc(_sfc_main$a, [["render", _sfc_render$9]]);
15580
+ const FMessageBox = /* @__PURE__ */ _export_sfc(_sfc_main$b, [["render", _sfc_render$9]]);
15645
15581
  function findOverflowIndex(totalWidth, elements) {
15646
15582
  let sum = 0;
15647
15583
  const index = elements.findIndex((element) => {
@@ -15691,7 +15627,7 @@ const upKeys = ["Up", "ArrowUp"];
15691
15627
  const downKeys = ["Down", "ArrowDown"];
15692
15628
  const verticalKeys = [...upKeys, ...downKeys];
15693
15629
  const preventKeys = ["Tab", "Left", "Right", "ArrowLeft", "ArrowRight", "Home", "End", " ", "Spacebar", "Enter", ...verticalKeys];
15694
- const _sfc_main$9 = vue.defineComponent({
15630
+ const _sfc_main$a = vue.defineComponent({
15695
15631
  name: "FNavigationMenu",
15696
15632
  components: {
15697
15633
  FIcon,
@@ -16024,7 +15960,7 @@ const _sfc_main$9 = vue.defineComponent({
16024
15960
  }
16025
15961
  }
16026
15962
  });
16027
- const _hoisted_1$9 = ["aria-label"];
15963
+ const _hoisted_1$a = ["aria-label"];
16028
15964
  const _hoisted_2$7 = ["data-ref-index", "onClick"];
16029
15965
  const _hoisted_3$5 = {
16030
15966
  class: "imenu__list__anchor-container"
@@ -16105,11 +16041,11 @@ function _sfc_render$8(_ctx, _cache, $props, $setup, $data, $options) {
16105
16041
  "enable-keyboard-navigation": "",
16106
16042
  onSelect: _ctx.onPopupMenuItemSelected,
16107
16043
  onClose: _cache[5] || (_cache[5] = ($event) => _ctx.togglePopup(false))
16108
- }, null, 8, ["modelValue", "focused-item", "items", "is-open", "anchor", "selected-menu-item-screen-reader-text", "aria-label", "onSelect"])], 10, _hoisted_1$9);
16044
+ }, null, 8, ["modelValue", "focused-item", "items", "is-open", "anchor", "selected-menu-item-screen-reader-text", "aria-label", "onSelect"])], 10, _hoisted_1$a);
16109
16045
  }
16110
- const FNavigationMenu = /* @__PURE__ */ _export_sfc(_sfc_main$9, [["render", _sfc_render$8]]);
16046
+ const FNavigationMenu = /* @__PURE__ */ _export_sfc(_sfc_main$a, [["render", _sfc_render$8]]);
16111
16047
  const EVENTS = ["online", "offline"];
16112
- const _sfc_main$8 = vue.defineComponent({
16048
+ const _sfc_main$9 = vue.defineComponent({
16113
16049
  name: "FOffline",
16114
16050
  components: {
16115
16051
  FIcon,
@@ -16157,7 +16093,7 @@ const _sfc_main$8 = vue.defineComponent({
16157
16093
  }
16158
16094
  }
16159
16095
  });
16160
- const _hoisted_1$8 = ["role"];
16096
+ const _hoisted_1$9 = ["role"];
16161
16097
  const _hoisted_2$6 = {
16162
16098
  key: 0,
16163
16099
  class: "offline"
@@ -16203,10 +16139,10 @@ function _sfc_render$7(_ctx, _cache, $props, $setup, $data, $options) {
16203
16139
  })])) : vue.createCommentVNode("", true), _cache[3] || (_cache[3] = vue.createTextVNode()), vue.withDirectives(vue.createElementVNode("span", {
16204
16140
  class: "sr-only",
16205
16141
  "aria-hidden": _ctx.shouldNotRead ? "true" : void 0
16206
- }, "\n Din internetuppkoppling fungerar igen\n ", 8, _hoisted_5$2), [[vue.vShow, _ctx.isOnline]])], 8, _hoisted_1$8);
16142
+ }, "\n Din internetuppkoppling fungerar igen\n ", 8, _hoisted_5$2), [[vue.vShow, _ctx.isOnline]])], 8, _hoisted_1$9);
16207
16143
  }
16208
- const FOffline = /* @__PURE__ */ _export_sfc(_sfc_main$8, [["render", _sfc_render$7]]);
16209
- const _sfc_main$7 = vue.defineComponent({
16144
+ const FOffline = /* @__PURE__ */ _export_sfc(_sfc_main$9, [["render", _sfc_render$7]]);
16145
+ const _sfc_main$8 = vue.defineComponent({
16210
16146
  name: "FOutputField",
16211
16147
  components: {
16212
16148
  FLabel
@@ -16239,13 +16175,13 @@ const _sfc_main$7 = vue.defineComponent({
16239
16175
  }
16240
16176
  }
16241
16177
  });
16242
- const _hoisted_1$7 = {
16178
+ const _hoisted_1$8 = {
16243
16179
  class: "output-field"
16244
16180
  };
16245
16181
  const _hoisted_2$5 = ["id", "for"];
16246
16182
  function _sfc_render$6(_ctx, _cache, $props, $setup, $data, $options) {
16247
16183
  const _component_f_label = vue.resolveComponent("f-label");
16248
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$7, [vue.createVNode(_component_f_label, {
16184
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$8, [vue.createVNode(_component_f_label, {
16249
16185
  for: _ctx.id
16250
16186
  }, vue.createSlots({
16251
16187
  default: vue.withCtx(() => [vue.renderSlot(_ctx.$slots, "label")]),
@@ -16260,8 +16196,8 @@ function _sfc_render$6(_ctx, _cache, $props, $setup, $data, $options) {
16260
16196
  class: "output-field__output"
16261
16197
  }, _ctx.$attrs), [vue.renderSlot(_ctx.$slots, "default")], 16, _hoisted_2$5)]);
16262
16198
  }
16263
- const FOutputField = /* @__PURE__ */ _export_sfc(_sfc_main$7, [["render", _sfc_render$6]]);
16264
- const _sfc_main$6 = vue.defineComponent({
16199
+ const FOutputField = /* @__PURE__ */ _export_sfc(_sfc_main$8, [["render", _sfc_render$6]]);
16200
+ const _sfc_main$7 = vue.defineComponent({
16265
16201
  name: "FPageHeader",
16266
16202
  components: {
16267
16203
  ISkipLink
@@ -16308,7 +16244,7 @@ const _sfc_main$6 = vue.defineComponent({
16308
16244
  }
16309
16245
  }
16310
16246
  });
16311
- const _hoisted_1$6 = {
16247
+ const _hoisted_1$7 = {
16312
16248
  class: "page-header__root"
16313
16249
  };
16314
16250
  const _hoisted_2$4 = {
@@ -16330,7 +16266,7 @@ const _hoisted_6$1 = {
16330
16266
  };
16331
16267
  function _sfc_render$5(_ctx, _cache, $props, $setup, $data, $options) {
16332
16268
  const _component_i_skip_link = vue.resolveComponent("i-skip-link");
16333
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$6, [_ctx.skipLinkAnchor ? (vue.openBlock(), vue.createElementBlock("nav", _hoisted_2$4, [vue.createVNode(_component_i_skip_link, {
16269
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$7, [_ctx.skipLinkAnchor ? (vue.openBlock(), vue.createElementBlock("nav", _hoisted_2$4, [vue.createVNode(_component_i_skip_link, {
16334
16270
  href: _ctx.skipLinkAnchor
16335
16271
  }, {
16336
16272
  default: vue.withCtx(() => [vue.renderSlot(_ctx.$slots, "skip-link-text")]),
@@ -16342,7 +16278,306 @@ function _sfc_render$5(_ctx, _cache, $props, $setup, $data, $options) {
16342
16278
  _: 3
16343
16279
  })), _cache[1] || (_cache[1] = vue.createTextVNode()), vue.createElementVNode("div", _hoisted_5$1, [vue.createElementVNode("div", _hoisted_6$1, [vue.renderSlot(_ctx.$slots, "right")])])], 512)]);
16344
16280
  }
16345
- const FPageHeader = /* @__PURE__ */ _export_sfc(_sfc_main$6, [["render", _sfc_render$5]]);
16281
+ const FPageHeader = /* @__PURE__ */ _export_sfc(_sfc_main$7, [["render", _sfc_render$5]]);
16282
+ const layoutRegister = {};
16283
+ function getLayout(name) {
16284
+ var _layoutRegister$name;
16285
+ return (_layoutRegister$name = layoutRegister[name]) !== null && _layoutRegister$name !== void 0 ? _layoutRegister$name : null;
16286
+ }
16287
+ function setLayout(name, layout) {
16288
+ layoutRegister[name] = layout;
16289
+ }
16290
+ function defineLayout(definition) {
16291
+ return normalizeDefinition(definition);
16292
+ }
16293
+ function registerLayout(definition) {
16294
+ setLayout(definition.name, normalizeDefinition(definition));
16295
+ }
16296
+ function normalizeDefinition(definition) {
16297
+ return {
16298
+ name: definition.name,
16299
+ areas: normalizeAreasDefinition(definition.areas)
16300
+ };
16301
+ }
16302
+ function normalizeAreasDefinition(areas) {
16303
+ return Object.fromEntries(Object.entries(areas).map(([key, area]) => {
16304
+ var _area$scroll;
16305
+ return [key, {
16306
+ attachPanel: area.attachPanel,
16307
+ direction: area.direction,
16308
+ scroll: (_area$scroll = area.scroll) !== null && _area$scroll !== void 0 ? _area$scroll : false
16309
+ }];
16310
+ }));
16311
+ }
16312
+ function _checkPrivateRedeclaration(e, t) {
16313
+ if (t.has(e)) throw new TypeError("Cannot initialize the same private elements twice on an object");
16314
+ }
16315
+ function _classPrivateFieldInitSpec(e, t, a) {
16316
+ _checkPrivateRedeclaration(e, t), t.set(e, a);
16317
+ }
16318
+ function _assertClassBrand(e, t, n) {
16319
+ if ("function" == typeof e ? e === t : e.has(t)) return arguments.length < 3 ? t : n;
16320
+ throw new TypeError("Private element is not present on this object");
16321
+ }
16322
+ function _classPrivateFieldGet2(s, a) {
16323
+ return s.get(_assertClassBrand(s, a));
16324
+ }
16325
+ function _classPrivateFieldSet2(s, a, r) {
16326
+ return s.set(_assertClassBrand(s, a), r), r;
16327
+ }
16328
+ const VAR_NAME_AREA = "--f-layout-area";
16329
+ const VAR_NAME_ATTACH_PANEL = "--f-layout-panel";
16330
+ const VAR_NAME_DIRECTION = "--f-layout-direction";
16331
+ registerLayout({
16332
+ name: "simple",
16333
+ areas: {
16334
+ header: {
16335
+ attachPanel: "none",
16336
+ direction: "column"
16337
+ },
16338
+ content: {
16339
+ attachPanel: "none",
16340
+ direction: "column",
16341
+ scroll: true
16342
+ },
16343
+ footer: {
16344
+ attachPanel: "none",
16345
+ direction: "column"
16346
+ }
16347
+ }
16348
+ });
16349
+ registerLayout({
16350
+ name: "left-panel",
16351
+ areas: {
16352
+ header: {
16353
+ attachPanel: "none",
16354
+ direction: "column"
16355
+ },
16356
+ left: {
16357
+ attachPanel: "left",
16358
+ direction: "column"
16359
+ },
16360
+ content: {
16361
+ attachPanel: "none",
16362
+ direction: "column",
16363
+ scroll: true
16364
+ },
16365
+ footer: {
16366
+ attachPanel: "none",
16367
+ direction: "column"
16368
+ }
16369
+ }
16370
+ });
16371
+ registerLayout({
16372
+ name: "right-panel",
16373
+ areas: {
16374
+ header: {
16375
+ attachPanel: "none",
16376
+ direction: "column"
16377
+ },
16378
+ right: {
16379
+ attachPanel: "right",
16380
+ direction: "column"
16381
+ },
16382
+ content: {
16383
+ attachPanel: "none",
16384
+ direction: "column",
16385
+ scroll: true
16386
+ },
16387
+ footer: {
16388
+ attachPanel: "none",
16389
+ direction: "column"
16390
+ }
16391
+ }
16392
+ });
16393
+ registerLayout({
16394
+ name: "three-column",
16395
+ areas: {
16396
+ header: {
16397
+ attachPanel: "top",
16398
+ direction: "column"
16399
+ },
16400
+ left: {
16401
+ attachPanel: "left",
16402
+ direction: "column"
16403
+ },
16404
+ right: {
16405
+ attachPanel: "right",
16406
+ direction: "column"
16407
+ },
16408
+ content: {
16409
+ attachPanel: "none",
16410
+ direction: "column",
16411
+ scroll: true
16412
+ },
16413
+ footer: {
16414
+ attachPanel: "bottom",
16415
+ direction: "column"
16416
+ }
16417
+ }
16418
+ });
16419
+ const styleContent = '.page-layout {\n display: grid;\n height: 100cqh;\n width: min(100%, 100cqw);\n\n &[part~="simple"] {\n grid-template:\n "header" min-content\n "content" 1fr\n "footer" min-content\n / 1fr;\n }\n\n &[part~="left-panel"] {\n grid-template:\n "header header" min-content\n "left content" 1fr\n "footer footer" min-content\n / min-content 1fr;\n }\n\n &[part~="right-panel"] {\n grid-template:\n "header header" min-content\n "content right" 1fr\n "footer footer" min-content\n / 1fr min-content;\n }\n\n &[part~="three-column"] {\n grid-template:\n "header header header" min-content\n "left content right" 1fr\n "footer footer footer" min-content\n / min-content 1fr min-content;\n }\n}\n\n.page-layout__area {\n display: flex;\n position: relative;\n\n &[data-direction="column"] {\n flex-direction: column;\n }\n\n &[data-direction="row"] {\n flex-direction: row;\n }\n\n &[data-scroll] {\n overflow-y: auto;\n }\n\n &:empty {\n display: none;\n }\n}\n\n:host ::slotted(*) {\n display: contents;\n}\n';
16420
+ const stubLayout = defineLayout({
16421
+ name: "",
16422
+ areas: {}
16423
+ });
16424
+ function getSlotNames(element) {
16425
+ return Array.from(element.querySelectorAll(":scope > [slot]"), (it) => it.slot);
16426
+ }
16427
+ var _wrapper = /* @__PURE__ */ new WeakMap();
16428
+ var _elements = /* @__PURE__ */ new WeakMap();
16429
+ var _layout = /* @__PURE__ */ new WeakMap();
16430
+ var _observer = /* @__PURE__ */ new WeakMap();
16431
+ var _slotNames = /* @__PURE__ */ new WeakMap();
16432
+ class PageLayout extends HTMLElement {
16433
+ constructor() {
16434
+ super();
16435
+ _classPrivateFieldInitSpec(this, _wrapper, void 0);
16436
+ _classPrivateFieldInitSpec(this, _elements, {});
16437
+ _classPrivateFieldInitSpec(this, _layout, stubLayout);
16438
+ _classPrivateFieldInitSpec(this, _observer, void 0);
16439
+ _classPrivateFieldInitSpec(this, _slotNames, []);
16440
+ _classPrivateFieldSet2(_wrapper, this, document.createElement("div"));
16441
+ _classPrivateFieldSet2(_observer, this, new MutationObserver(() => {
16442
+ this.slotNames = getSlotNames(this);
16443
+ }));
16444
+ }
16445
+ /* eslint-disable-next-line @typescript-eslint/explicit-function-return-type -- this one is better to infer or each attribute would have to be duplicated */
16446
+ static get observedAttributes() {
16447
+ return ["layout"];
16448
+ }
16449
+ connectedCallback() {
16450
+ this.slotNames = getSlotNames(this);
16451
+ _classPrivateFieldGet2(_observer, this).observe(this, {
16452
+ childList: true
16453
+ });
16454
+ const shadow = this.attachShadow({
16455
+ mode: "open"
16456
+ });
16457
+ const style = document.createElement("style");
16458
+ style.textContent = styleContent;
16459
+ shadow.append(style);
16460
+ shadow.append(_classPrivateFieldGet2(_wrapper, this));
16461
+ }
16462
+ disconnectedCallback() {
16463
+ _classPrivateFieldGet2(_observer, this).disconnect();
16464
+ }
16465
+ attributeChangedCallback(name, _oldValue, value) {
16466
+ switch (name) {
16467
+ case "layout": {
16468
+ var _getLayout;
16469
+ const part = ["grid", value].filter(Boolean).join(" ");
16470
+ _classPrivateFieldGet2(_wrapper, this).className = "page-layout";
16471
+ _classPrivateFieldGet2(_wrapper, this).setAttribute("part", part);
16472
+ _classPrivateFieldSet2(_layout, this, (_getLayout = getLayout(value)) !== null && _getLayout !== void 0 ? _getLayout : stubLayout);
16473
+ this.updateSlotElements();
16474
+ break;
16475
+ }
16476
+ }
16477
+ }
16478
+ get slotNames() {
16479
+ return _classPrivateFieldGet2(_slotNames, this);
16480
+ }
16481
+ set slotNames(slots) {
16482
+ _classPrivateFieldSet2(_slotNames, this, slots);
16483
+ this.updateSlotElements();
16484
+ }
16485
+ updateSlotElements() {
16486
+ const wrapper = _classPrivateFieldGet2(_wrapper, this);
16487
+ const layout = _classPrivateFieldGet2(_layout, this);
16488
+ for (const slot of _classPrivateFieldGet2(_slotNames, this)) {
16489
+ const existing = _classPrivateFieldGet2(_elements, this)[slot];
16490
+ const element = existing !== null && existing !== void 0 ? existing : document.createElement("div");
16491
+ const area = layout.areas[slot];
16492
+ if (!area) {
16493
+ continue;
16494
+ }
16495
+ const {
16496
+ attachPanel: attach,
16497
+ direction,
16498
+ scroll
16499
+ } = area;
16500
+ element.className = "";
16501
+ element.classList.add("page-layout__area");
16502
+ element.setAttribute("part", ["area", slot].join(" "));
16503
+ element.setAttribute("data-direction", direction);
16504
+ if (scroll) {
16505
+ element.setAttribute("data-scroll", "true");
16506
+ } else {
16507
+ element.removeAttribute("data-scroll");
16508
+ }
16509
+ element.style.setProperty("grid-area", slot);
16510
+ element.style.setProperty(VAR_NAME_AREA, `"${slot}"`);
16511
+ element.style.setProperty(VAR_NAME_ATTACH_PANEL, `"${attach}"`);
16512
+ element.style.setProperty(VAR_NAME_DIRECTION, `"${direction}"`);
16513
+ if (!existing) {
16514
+ const slotElement = document.createElement("slot");
16515
+ slotElement.name = slot;
16516
+ element.append(slotElement);
16517
+ wrapper.append(element);
16518
+ _classPrivateFieldGet2(_elements, this)[slot] = element;
16519
+ }
16520
+ }
16521
+ }
16522
+ }
16523
+ const _hoisted_1$6 = ["slot"];
16524
+ const tagName = `ce-page-layout`;
16525
+ const _sfc_main$6 = /* @__PURE__ */ vue.defineComponent({
16526
+ __name: "FPageLayout",
16527
+ props: {
16528
+ layout: {}
16529
+ },
16530
+ setup(__props) {
16531
+ const slots = vue.useSlots();
16532
+ const slotNames = vue.computed(() => {
16533
+ return Object.keys(slots);
16534
+ });
16535
+ vue.onMounted(() => {
16536
+ if (!customElements.get(tagName)) {
16537
+ customElements.define(tagName, PageLayout);
16538
+ }
16539
+ });
16540
+ return (_ctx, _cache) => {
16541
+ return vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(tagName), {
16542
+ layout: _ctx.layout
16543
+ }, {
16544
+ default: vue.withCtx(() => [(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(slotNames.value, (slot) => {
16545
+ return vue.openBlock(), vue.createElementBlock("div", {
16546
+ key: slot,
16547
+ slot
16548
+ }, [vue.renderSlot(_ctx.$slots, slot)], 8, _hoisted_1$6);
16549
+ }), 128))]),
16550
+ _: 3
16551
+ }, 8, ["layout"]);
16552
+ };
16553
+ }
16554
+ });
16555
+ function getProperty(style, key) {
16556
+ const value = style.getPropertyValue(key);
16557
+ if (value === "") {
16558
+ return null;
16559
+ } else {
16560
+ return JSON.parse(value);
16561
+ }
16562
+ }
16563
+ function useAreaData(element) {
16564
+ const area = vue.ref(null);
16565
+ const attachPanel = vue.ref(null);
16566
+ const direction = vue.ref(null);
16567
+ vue.watchEffect(() => {
16568
+ if (element.value) {
16569
+ const style = getComputedStyle(element.value);
16570
+ area.value = getProperty(style, VAR_NAME_AREA);
16571
+ attachPanel.value = getProperty(style, VAR_NAME_ATTACH_PANEL);
16572
+ direction.value = getProperty(style, VAR_NAME_DIRECTION);
16573
+ }
16574
+ });
16575
+ return {
16576
+ area,
16577
+ attachPanel,
16578
+ direction
16579
+ };
16580
+ }
16346
16581
  const _hoisted_1$5 = {
16347
16582
  class: "progress"
16348
16583
  };
@@ -17387,20 +17622,20 @@ exports.ErrorData = ErrorData;
17387
17622
  exports.ErrorPlugin = ErrorPlugin;
17388
17623
  exports.ErrorViewData = ErrorViewData;
17389
17624
  exports.EventBus = EventBus;
17390
- exports.FBadge = _sfc_main$1b;
17391
- exports.FBankAccountNumberTextField = _sfc_main$y;
17392
- exports.FBankgiroTextField = _sfc_main$x;
17625
+ exports.FBadge = _sfc_main$1c;
17626
+ exports.FBankAccountNumberTextField = _sfc_main$z;
17627
+ exports.FBankgiroTextField = _sfc_main$y;
17393
17628
  exports.FCalendar = FCalendar;
17394
17629
  exports.FCalendarDay = FCalendarDay;
17395
- exports.FCard = _sfc_main$W;
17630
+ exports.FCard = _sfc_main$X;
17396
17631
  exports.FCheckboxField = FCheckboxField;
17397
- exports.FClearingnumberTextField = _sfc_main$w;
17632
+ exports.FClearingnumberTextField = _sfc_main$x;
17398
17633
  exports.FConfirmModal = FConfirmModal;
17399
17634
  exports.FContextMenu = FContextMenu;
17400
17635
  exports.FCrudButton = FCrudButton;
17401
- exports.FCrudDataset = FCrudDataset;
17402
- exports.FCurrencyTextField = _sfc_main$A;
17403
- exports.FDataTable = FDataTable;
17636
+ exports.FCrudDataset = _sfc_main$J;
17637
+ exports.FCurrencyTextField = _sfc_main$B;
17638
+ exports.FDataTable = _sfc_main$p;
17404
17639
  exports.FDatepickerField = FDatepickerField;
17405
17640
  exports.FDialogueTree = FDialogueTree;
17406
17641
  exports.FEmailTextField = FEmailTextField;
@@ -17415,34 +17650,35 @@ exports.FFileSelector = FFileSelector;
17415
17650
  exports.FFormModal = FFormModal;
17416
17651
  exports.FFormModalAction = FValidationFormAction;
17417
17652
  exports.FIcon = FIcon;
17418
- exports.FInteractiveTable = FInteractiveTable;
17653
+ exports.FInteractiveTable = _sfc_main$i;
17419
17654
  exports.FKUIConfigButtonOrder = FKUIConfigButtonOrder;
17420
17655
  exports.FLabel = FLabel;
17421
17656
  exports.FLayoutApplicationTemplate = FLayoutApplicationTemplate;
17422
17657
  exports.FLayoutLeftPanel = FLayoutLeftPanel;
17423
17658
  exports.FLayoutRightPanel = FLayoutRightPanel;
17424
17659
  exports.FLayoutRightPanelService = FLayoutRightPanelService;
17425
- exports.FList = FList;
17660
+ exports.FList = _sfc_main$e;
17426
17661
  exports.FLoader = FLoader;
17427
- exports.FLogo = _sfc_main$b;
17662
+ exports.FLogo = _sfc_main$c;
17428
17663
  exports.FMessageBox = FMessageBox;
17429
17664
  exports.FModal = FModal;
17430
17665
  exports.FNavigationMenu = FNavigationMenu;
17431
- exports.FNumericTextField = _sfc_main$v;
17666
+ exports.FNumericTextField = _sfc_main$w;
17432
17667
  exports.FOffline = FOffline;
17433
- exports.FOrganisationsnummerTextField = _sfc_main$q;
17668
+ exports.FOrganisationsnummerTextField = _sfc_main$r;
17434
17669
  exports.FOutputField = FOutputField;
17435
17670
  exports.FPageHeader = FPageHeader;
17436
- exports.FPercentTextField = _sfc_main$r;
17437
- exports.FPersonnummerTextField = _sfc_main$u;
17671
+ exports.FPageLayout = _sfc_main$6;
17672
+ exports.FPercentTextField = _sfc_main$s;
17673
+ exports.FPersonnummerTextField = _sfc_main$v;
17438
17674
  exports.FPhoneTextField = FPhoneTextField;
17439
- exports.FPlusgiroTextField = _sfc_main$t;
17440
- exports.FPostalCodeTextField = _sfc_main$s;
17675
+ exports.FPlusgiroTextField = _sfc_main$u;
17676
+ exports.FPostalCodeTextField = _sfc_main$t;
17441
17677
  exports.FProgressbar = _sfc_main$5;
17442
17678
  exports.FRadioField = FRadioField;
17443
17679
  exports.FSearchTextField = FSearchTextField;
17444
17680
  exports.FSelectField = FSelectField;
17445
- exports.FSortFilterDataset = FSortFilterDataset;
17681
+ exports.FSortFilterDataset = _sfc_main$q;
17446
17682
  exports.FSortFilterDatasetInjected = FSortFilterDatasetInjected;
17447
17683
  exports.FStaticField = FStaticField;
17448
17684
  exports.FTableColumn = FTableColumn;
@@ -17463,13 +17699,13 @@ exports.IAnimateExpand = IAnimateExpand;
17463
17699
  exports.ICalendarMonth = ICalendarMonth;
17464
17700
  exports.ICalendarMonthGrid = ICalendarMonthGrid;
17465
17701
  exports.ICalendarNavbar = ICalendarNavbar;
17466
- exports.IComboboxDropdown = _sfc_main$O;
17467
- exports.IComboboxToggleButton = _sfc_main$N;
17702
+ exports.IComboboxDropdown = _sfc_main$P;
17703
+ exports.IComboboxToggleButton = _sfc_main$O;
17468
17704
  exports.IFlex = IFlex;
17469
17705
  exports.IFlexItem = IFlexItem;
17470
17706
  exports.IPopup = IPopup;
17471
17707
  exports.IPopupError = IPopupError;
17472
- exports.IPopupListbox = _sfc_main$S;
17708
+ exports.IPopupListbox = _sfc_main$T;
17473
17709
  exports.IPopupMenu = IPopupMenu;
17474
17710
  exports.ISkipLink = ISkipLink;
17475
17711
  exports.IValidationForm = FValidationForm;
@@ -17518,10 +17754,12 @@ exports.refIsElementArray = refIsElementArray;
17518
17754
  exports.refIsHTMLElementArray = refIsHTMLElementArray;
17519
17755
  exports.refIsVue = refIsVue;
17520
17756
  exports.refIsVueArray = refIsVueArray;
17757
+ exports.registerLayout = registerLayout;
17521
17758
  exports.renderSlotText = renderSlotText;
17522
17759
  exports.setRunningContext = setRunningContext;
17523
17760
  exports.tableScrollClasses = tableScrollClasses;
17524
17761
  exports.tooltipAttachTo = tooltipAttachTo;
17762
+ exports.useAreaData = useAreaData;
17525
17763
  exports.useCombobox = useCombobox;
17526
17764
  exports.useModal = useModal;
17527
17765
  exports.useSlotUtils = useSlotUtils;