@oslokommune/punkt-react 19.0.4 → 19.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.
@@ -3231,28 +3231,28 @@ var ir = (e, t) => t && (e.find((e) => e.value === t) || e.find((e) => e.label =
3231
3231
  if (!t) return -1;
3232
3232
  let n = e.findIndex((e) => e.value === t);
3233
3233
  return n >= 0 ? n : e.findIndex((e) => e.label === t);
3234
- }, or = (e, t) => {
3234
+ }, or = (e) => e.value + (e.label || "") + (e.prefix || ""), sr = (e, t) => (e.fulltext || or(e)).toLowerCase().includes(t), cr = (e, t) => {
3235
3235
  if (!t) return [...e];
3236
3236
  let n = t.toLowerCase();
3237
- return e.filter((e) => (e.fulltext || e.value + (e.label || "") + (e.prefix || "")).toLowerCase().includes(n));
3238
- }, sr = (e) => e.value + (e.label || "") + (e.prefix || ""), cr = (e, t) => t !== null && e >= t, lr = (e, t) => {
3237
+ return e.filter((e) => sr(e, n));
3238
+ }, lr = (e, t) => t !== null && e >= t, ur = (e, t) => {
3239
3239
  if (!e) return "";
3240
3240
  switch (t) {
3241
3241
  case "prefixAndValue": return `${e.prefix || ""} ${e.value}`.trim();
3242
3242
  case "value": return e.value;
3243
3243
  default: return e.label || e.value;
3244
3244
  }
3245
- }, ur = (e, t) => e ? Array.isArray(e) ? t ? e : e.length > 0 ? [e[0]] : [] : t ? e.split(",").filter(Boolean) : [e] : [], dr = (e, t) => {
3245
+ }, dr = (e, t) => e ? Array.isArray(e) ? t ? e : e.length > 0 ? [e[0]] : [] : t ? e.split(",").filter(Boolean) : [e] : [], fr = (e, t) => {
3246
3246
  if (!t) return {
3247
3247
  filtered: [...e],
3248
3248
  suggestion: null
3249
3249
  };
3250
- let n = t.toLowerCase(), r = e.filter((e) => e.fulltext?.toLowerCase().includes(n));
3250
+ let n = t.toLowerCase(), r = e.filter((e) => sr(e, n));
3251
3251
  return {
3252
3252
  filtered: r,
3253
3253
  suggestion: r.find((e) => !e.selected && e.label?.toLowerCase().startsWith(n)) || null
3254
3254
  };
3255
- }, fr = (e, t, n, r) => {
3255
+ }, pr = (e, t, n, r) => {
3256
3256
  if (!e.trim()) return {
3257
3257
  addValueText: null,
3258
3258
  userInfoMessage: ""
@@ -3271,7 +3271,7 @@ var ir = (e, t) => t && (e.find((e) => e.value === t) || e.find((e) => e.label =
3271
3271
  addValueText: null,
3272
3272
  userInfoMessage: ""
3273
3273
  };
3274
- }, pr = (e, t, n) => {
3274
+ }, mr = (e, t, n) => {
3275
3275
  switch (e) {
3276
3276
  case ",": return n ? "addValue" : null;
3277
3277
  case "Enter": return "addValue";
@@ -3280,7 +3280,7 @@ var ir = (e, t) => t && (e.find((e) => e.value === t) || e.find((e) => e.label =
3280
3280
  case "Escape": return "closeOptions";
3281
3281
  default: return null;
3282
3282
  }
3283
- }, mr = (e, t, n, r, i) => {
3283
+ }, hr = (e, t, n, r, i) => {
3284
3284
  if (!e) return {
3285
3285
  action: "none",
3286
3286
  value: null
@@ -3302,36 +3302,36 @@ var ir = (e, t) => t && (e.find((e) => e.value === t) || e.find((e) => e.label =
3302
3302
  action: "none",
3303
3303
  value: null
3304
3304
  };
3305
- }, hr = (e, t, n) => {
3305
+ }, gr = (e, t, n) => {
3306
3306
  let r = ir(t, e);
3307
3307
  return n === "label" && r?.label ? r.label : e;
3308
- }, gr = (e) => {
3308
+ }, _r = (e) => {
3309
3309
  e.scrollIntoView({ block: "nearest" }), window.setTimeout(() => e.focus(), 0);
3310
- }, _r = (e) => Array.from(e.querySelectorAll("[role=\"option\"]:not([data-disabled])") || []), vr = (e) => {
3310
+ }, vr = (e) => Array.from(e.querySelectorAll("[role=\"option\"]:not([data-disabled])") || []), yr = (e) => {
3311
3311
  let t = e.nextElementSibling;
3312
- t && gr(t);
3313
- }, yr = (e, t, n) => {
3312
+ t && _r(t);
3313
+ }, br = (e, t, n) => {
3314
3314
  let r = e.previousElementSibling;
3315
3315
  if (e.dataset.index === "0" && n) {
3316
3316
  let e = t.querySelector("[role=\"searchbox\"]");
3317
- e && gr(e);
3318
- } else r && gr(r);
3319
- }, br = (e) => {
3320
- let t = _r(e);
3321
- t[0] && gr(t[0]);
3322
- }, xr = (e, t) => {
3317
+ e && _r(e);
3318
+ } else r && _r(r);
3319
+ }, xr = (e) => {
3320
+ let t = vr(e);
3321
+ t[0] && _r(t[0]);
3322
+ }, Sr = (e, t) => {
3323
3323
  if (t.disabled) return;
3324
- let n = _r(e);
3324
+ let n = vr(e);
3325
3325
  if (t.allowUserInput && t.customUserInput) {
3326
3326
  let t = e.querySelector("[data-type=\"new-option\"]");
3327
3327
  if (t) {
3328
- gr(t);
3328
+ _r(t);
3329
3329
  return;
3330
3330
  }
3331
3331
  }
3332
3332
  let r = n.find((e) => e.dataset.selected === "true");
3333
3333
  if (r) {
3334
- gr(r);
3334
+ _r(r);
3335
3335
  return;
3336
3336
  }
3337
3337
  if (t.includeSearch && !(document.activeElement instanceof HTMLInputElement)) {
@@ -3341,8 +3341,8 @@ var ir = (e, t) => t && (e.find((e) => e.value === t) || e.find((e) => e.label =
3341
3341
  return;
3342
3342
  }
3343
3343
  }
3344
- n[0] && gr(n[0]);
3345
- }, Sr = ({ state: e, outside: t = !1 }) => {
3344
+ n[0] && _r(n[0]);
3345
+ }, Cr = ({ state: e, outside: t = !1 }) => {
3346
3346
  let { values: n, options: r, disabled: i, displayValueAs: a, handleTagRemove: o, handleTagKeydown: s, focusedTagIndex: l } = e, u = p([]);
3347
3347
  if (c(() => {
3348
3348
  !t && l >= 0 && l < n.length && u.current[l]?.focus();
@@ -3352,7 +3352,7 @@ var ir = (e, t) => t && (e.find((e) => e.value === t) || e.find((e) => e.label =
3352
3352
  n.length
3353
3353
  ]), n.length === 0) return null;
3354
3354
  let d = n.map((e, n) => {
3355
- let c = ir(r, e), d = c?.tagSkinColor, f = c ? lr(c, a) : e;
3355
+ let c = ir(r, e), d = c?.tagSkinColor, f = c ? ur(c, a) : e;
3356
3356
  return i ? /* @__PURE__ */ _("li", {
3357
3357
  role: "listitem",
3358
3358
  children: /* @__PURE__ */ _(Wn, {
@@ -3405,17 +3405,17 @@ var ir = (e, t) => t && (e.find((e) => e.value === t) || e.find((e) => e.label =
3405
3405
  className: "pkt-combobox__tag-list",
3406
3406
  children: d
3407
3407
  });
3408
- }, Cr = ({ state: e }) => {
3408
+ }, wr = ({ state: e }) => {
3409
3409
  let { values: t, options: n, editingSingleValue: r, displayValueAs: i } = e;
3410
3410
  if (r || t.length === 0) return null;
3411
3411
  let a = ir(n, t[0]);
3412
3412
  if (!a) return null;
3413
- let o = lr(a, i);
3413
+ let o = ur(a, i);
3414
3414
  return /* @__PURE__ */ _("span", {
3415
3415
  className: "pkt-combobox__value",
3416
3416
  children: o
3417
3417
  });
3418
- }, wr = ({ state: e }) => {
3418
+ }, Tr = ({ state: e }) => {
3419
3419
  let { id: t, inputId: n, listboxId: r, values: i, options: a, isOpen: o, multiple: s, typeahead: c, allowUserInput: l, tagPlacement: u, placeholder: d, disabled: f, fullwidth: p, hasError: m, label: h, inputFocus: g, skipInputTab: y, restoreInputTab: b, inputRef: x, triggerRef: S, handleInputChange: C, handleInputKeydown: w, handleInputFocus: T, handleInputBlur: E, handleInputClick: D, handlePlaceholderClick: O, handleSelectOnlyKeydown: k, name: A, inputSize: j } = e, M = [
3420
3420
  "pkt-combobox__input",
3421
3421
  `pkt-combobox__input--${j}`,
@@ -3453,7 +3453,7 @@ var ir = (e, t) => t && (e.find((e) => e.value === t) || e.find((e) => e.label =
3453
3453
  className: "pkt-combobox__placeholder",
3454
3454
  onClick: O,
3455
3455
  children: d
3456
- }) : te ? s ? /* @__PURE__ */ _(Sr, { state: e }) : P ? null : /* @__PURE__ */ _(Cr, { state: e }) : null,
3456
+ }) : te ? s ? /* @__PURE__ */ _(Cr, { state: e }) : P ? null : /* @__PURE__ */ _(wr, { state: e }) : null,
3457
3457
  P ? /* @__PURE__ */ _("div", {
3458
3458
  className: "pkt-combobox__input-div combobox__input",
3459
3459
  children: /* @__PURE__ */ _("input", {
@@ -3492,7 +3492,7 @@ var ir = (e, t) => t && (e.find((e) => e.value === t) || e.find((e) => e.label =
3492
3492
  })
3493
3493
  ]
3494
3494
  });
3495
- }, Tr = ({ state: e }) => {
3495
+ }, Er = ({ state: e }) => {
3496
3496
  let t = ve(["listbox"], e.strings), { listboxId: n, label: r, isOpen: i, options: a, filteredOptions: o, multiple: s, disabled: c, maxIsReached: l, maxlength: u, includeSearch: d, allowUserInput: f, addValueText: p, userInfoMessage: m, searchPlaceholder: h, searchValue: y, handleOptionClick: b, handleOptionKeydown: x, handleSearchInput: S, handleSearchKeydown: C, handleNewOptionClick: w, handleNewOptionKeydown: T, listboxRef: E } = e, D = o.filter((e) => e.selected).length, O = s && D > 0 && u != null && u > 0, k = f && p && !l, A = !!m, j = [
3497
3497
  "pkt-listbox",
3498
3498
  i && "pkt-listbox__open",
@@ -3625,7 +3625,7 @@ var ir = (e, t) => t && (e.find((e) => e.value === t) || e.find((e) => e.label =
3625
3625
  className: "pkt-visually-hidden",
3626
3626
  children: m
3627
3627
  })] });
3628
- }, Er = (e, t) => {
3628
+ }, Dr = (e, t) => {
3629
3629
  let [n, r] = m(null);
3630
3630
  return c(() => {
3631
3631
  let n = e.current;
@@ -3643,16 +3643,16 @@ var ir = (e, t) => t && (e.find((e) => e.value === t) || e.find((e) => e.label =
3643
3643
  };
3644
3644
  //#endregion
3645
3645
  //#region src/components/combobox/useComboboxState.ts
3646
- function Dr(e, t) {
3646
+ function Or(e, t) {
3647
3647
  return e.map((e) => ({
3648
3648
  ...e,
3649
3649
  label: e.label || e.value,
3650
- fulltext: sr(e),
3650
+ fulltext: or(e),
3651
3651
  selected: t.includes(e.value)
3652
3652
  }));
3653
3653
  }
3654
- function Or(t, n) {
3655
- let { id: r = "", label: i, value: s, defaultValue: l, options: d, defaultOptions: h, multiple: g = !1, maxlength: _, typeahead: v = !1, includeSearch: y = !1, allowUserInput: b = !1, displayValueAs: x = "label", tagPlacement: S, searchPlaceholder: C, placeholder: w, disabled: T = !1, required: E = !1, fullwidth: D = !1, hasError: O = !1, errorMessage: k, helptext: A, helptextDropdown: j, helptextDropdownButton: M, optionalTag: N = !1, optionalText: P, requiredTag: ee = !1, requiredText: te, tagText: ne, useWrapper: F = !0, inline: re = !1, counter: ie, inputSize: ae = "medium", name: oe, form: se, ariaDescribedby: I, className: L, onChange: R, onValueChange: ce, children: z, strings: le } = t, ue = `${r}-input`, de = `${r}-listbox`, V = v || b, H = p(null), U = p(null), W = p(null), G = p(null), K = p(null), fe = Er(K, se), q = o(() => {
3654
+ function kr(t, n) {
3655
+ let { id: r = "", label: i, value: s, defaultValue: l, options: d, defaultOptions: h, multiple: g = !1, maxlength: _, typeahead: v = !1, includeSearch: y = !1, allowUserInput: b = !1, displayValueAs: x = "label", tagPlacement: S, searchPlaceholder: C, placeholder: w, disabled: T = !1, required: E = !1, fullwidth: D = !1, hasError: O = !1, errorMessage: k, helptext: A, helptextDropdown: j, helptextDropdownButton: M, optionalTag: N = !1, optionalText: P, requiredTag: ee = !1, requiredText: te, tagText: ne, useWrapper: F = !0, inline: re = !1, counter: ie, inputSize: ae = "medium", name: oe, form: se, ariaDescribedby: I, className: L, onChange: R, onValueChange: ce, children: z, strings: le } = t, ue = `${r}-input`, de = `${r}-listbox`, V = v || b, H = p(null), U = p(null), W = p(null), G = p(null), K = p(null), fe = Dr(K, se), q = o(() => {
3656
3656
  V ? H.current?.focus() : W.current?.focus();
3657
3657
  }, [V]), pe = o(() => {
3658
3658
  Pe(!0);
@@ -3673,33 +3673,33 @@ function Or(t, n) {
3673
3673
  }), t;
3674
3674
  }, [z]), he = f(() => h && h.length > 0 ? h.map((e) => ({
3675
3675
  ...e,
3676
- fulltext: sr(e)
3676
+ fulltext: or(e)
3677
3677
  })) : d && d.length > 0 ? d.map((e) => ({
3678
3678
  ...e,
3679
- fulltext: sr(e)
3679
+ fulltext: or(e)
3680
3680
  })) : me.length > 0 ? me.map((e) => ({
3681
3681
  ...e,
3682
- fulltext: sr(e)
3682
+ fulltext: or(e)
3683
3683
  })) : [], [
3684
3684
  h,
3685
3685
  d,
3686
3686
  me
3687
3687
  ]), J = s !== void 0, [ge, Y] = m(() => {
3688
- let e = ur(s ?? l, g), t = he.filter((t) => t.selected && !e.includes(t.value)).map((e) => e.value);
3688
+ let e = dr(s ?? l, g), t = he.filter((t) => t.selected && !e.includes(t.value)).map((e) => e.value);
3689
3689
  return t.length ? g ? [...e, ...t] : e.length ? e : [t[0]] : e;
3690
3690
  }), _e = p(ge);
3691
3691
  c(() => {
3692
- J && Y(ur(s, g));
3692
+ J && Y(dr(s, g));
3693
3693
  }, [
3694
3694
  s,
3695
3695
  J,
3696
3696
  g
3697
3697
  ]);
3698
- let X = J ? ur(s, g) : ge, [ye, be] = m([]), Z = f(() => Dr([...ye.filter((e) => !he.some((t) => t.value === e.value)), ...he], X), [
3698
+ let X = J ? dr(s, g) : ge, [ye, be] = m([]), Z = f(() => Or([...ye.filter((e) => !he.some((t) => t.value === e.value)), ...he], X), [
3699
3699
  he,
3700
3700
  ye,
3701
3701
  X
3702
- ]), [Q, xe] = m(!1), [Se, Ce] = m(""), [we, Te] = m(""), [Ee, De] = m(""), [Oe, ke] = m(null), [Ae, je] = m(null), [Me, $] = m(!1), [Ne, Pe] = m(!1), Fe = p(!1), [Ie, Le] = m(!1), [Re, ze] = m(-1), Be = ve(["combobox"], le), Ve = Ee ? B(Be.combobox[Ee], { value: Oe ?? "" }) : "", He = cr(X.length, _ ?? null), Ue = ie ?? (g && _ != null), We = f(() => Se ? v ? dr(Z, Se).filtered : or(Z, Se) : Z, [
3702
+ ]), [Q, xe] = m(!1), [Se, Ce] = m(""), [we, Te] = m(""), [Ee, De] = m(""), [Oe, ke] = m(null), [Ae, je] = m(null), [Me, $] = m(!1), [Ne, Pe] = m(!1), Fe = p(!1), [Ie, Le] = m(!1), [Re, ze] = m(-1), Be = ve(["combobox"], le), Ve = Ee ? B(Be.combobox[Ee], { value: Oe ?? "" }) : "", He = lr(X.length, _ ?? null), Ue = ie ?? (g && _ != null), We = f(() => Se ? v ? fr(Z, Se).filtered : cr(Z, Se) : Z, [
3703
3703
  Z,
3704
3704
  Se,
3705
3705
  v
@@ -3713,7 +3713,7 @@ function Or(t, n) {
3713
3713
  U.current && (U.current.value = qe);
3714
3714
  }, [qe]), c(() => {
3715
3715
  if (Q || !H.current) return;
3716
- let e = !g && X[0] ? hr(X[0], Z, x) : "";
3716
+ let e = !g && X[0] ? gr(X[0], Z, x) : "";
3717
3717
  H.current.value !== e && (H.current.value = e);
3718
3718
  }, [
3719
3719
  X,
@@ -3730,7 +3730,7 @@ function Or(t, n) {
3730
3730
  Ke
3731
3731
  ]), Ye = o((e) => {
3732
3732
  if (!e || X.includes(e)) return;
3733
- if (g && cr(X.length, _ ?? null)) {
3733
+ if (g && lr(X.length, _ ?? null)) {
3734
3734
  De("maxSelected");
3735
3735
  return;
3736
3736
  }
@@ -3756,7 +3756,7 @@ function Or(t, n) {
3756
3756
  let t;
3757
3757
  if (!g) t = [e];
3758
3758
  else {
3759
- if (ir(Z, e) || cr(X.length, _ ?? null)) return;
3759
+ if (ir(Z, e) || lr(X.length, _ ?? null)) return;
3760
3760
  t = [...X, e];
3761
3761
  }
3762
3762
  let n = {
@@ -3776,7 +3776,7 @@ function Or(t, n) {
3776
3776
  if (je(null), e && H.current && H.current.type !== "hidden") {
3777
3777
  Ce(""), Te("");
3778
3778
  let e = t === void 0 ? X[0] : t;
3779
- !g && e ? H.current.value = hr(e, Z, x) : H.current.value = "", g || (Le(!1), De(""));
3779
+ !g && e ? H.current.value = gr(e, Z, x) : H.current.value = "", g || (Le(!1), De(""));
3780
3780
  }
3781
3781
  }, [
3782
3782
  g,
@@ -3786,8 +3786,8 @@ function Or(t, n) {
3786
3786
  ]), et = o((e) => {
3787
3787
  if (T) return;
3788
3788
  De(""), je(null);
3789
- let t = ir(Z, e)?.value || null, n = X.includes(e || t || ""), r = !!t, i = Z.find((t) => t.value === e)?.disabled || !1, a = !e?.trim(), o = !g, s = g, c = cr(X.length, _ ?? null), l = !1, u = !0, d = "", f = null, p = "", m;
3790
- i || (!r && b && !a ? (Qe(e), d = "valueAdded", l = s, o && (m = e || "")) : !r && !b ? (o && X[0] && Xe(X[0]), u = !1, l = !0, d = "noResults") : n ? (Xe(t), l = !0, m = "", o && V && H.current && H.current.type !== "hidden" && (H.current.value = "")) : a && o ? (Ze(), l = !0, m = "") : o ? (X[0] && Xe(X[0]), Ye(t), l = !1, m = t || "", d = "valueSelected", f = V ? hr(t || "", Z, x) : lr(ir(Z, t), x)) : s && !c ? (Ye(t), l = !0) : s && c ? (d = "maxSelected", u = !1, p = e || "") : (o && Ze(), d = "noValidValue", u = !1, l = !0, p = e || "", m = ""), xe(l), Ce(p), $e(u, m), De(d), ke(f), l || window.setTimeout(() => {
3789
+ let t = ir(Z, e)?.value || null, n = X.includes(e || t || ""), r = !!t, i = Z.find((t) => t.value === e)?.disabled || !1, a = !e?.trim(), o = !g, s = g, c = lr(X.length, _ ?? null), l = !1, u = !0, d = "", f = null, p = "", m;
3790
+ i || (!r && b && !a ? (Qe(e), d = "valueAdded", l = s, o && (m = e || "")) : !r && !b ? (o && X[0] && Xe(X[0]), u = !1, l = !0, d = "noResults") : n ? (Xe(t), l = !0, m = "", o && V && H.current && H.current.type !== "hidden" && (H.current.value = "")) : a && o ? (Ze(), l = !0, m = "") : o ? (X[0] && Xe(X[0]), Ye(t), l = !1, m = t || "", d = "valueSelected", f = V ? gr(t || "", Z, x) : ur(ir(Z, t), x)) : s && !c ? (Ye(t), l = !0) : s && c ? (d = "maxSelected", u = !1, p = e || "") : (o && Ze(), d = "noValidValue", u = !1, l = !0, p = e || "", m = ""), xe(l), Ce(p), $e(u, m), De(d), ke(f), l || window.setTimeout(() => {
3791
3791
  pe();
3792
3792
  }, 0));
3793
3793
  }, [
@@ -3815,7 +3815,7 @@ function Or(t, n) {
3815
3815
  n && n.value !== X[0] ? (X[0] && Xe(X[0]), Ye(n.value), t = n.value) : !n && b && (X[0] && Xe(X[0]), Qe(e), t = e);
3816
3816
  }
3817
3817
  } else if (e !== "") {
3818
- let { action: t, value: n } = mr(e, X, Z, b, g);
3818
+ let { action: t, value: n } = hr(e, X, Z, b, g);
3819
3819
  switch (t) {
3820
3820
  case "addUserValue":
3821
3821
  Qe(n);
@@ -3826,7 +3826,7 @@ function Or(t, n) {
3826
3826
  case "removeValue": Xe(n);
3827
3827
  }
3828
3828
  }
3829
- !g && t ? H.current.value = hr(t, Z, x) : H.current.value = "";
3829
+ !g && t ? H.current.value = gr(t, Z, x) : H.current.value = "";
3830
3830
  }
3831
3831
  xe(!1), Le(!1);
3832
3832
  }, [
@@ -3843,7 +3843,7 @@ function Or(t, n) {
3843
3843
  je(null), De(""), !g && X[0] && Xe(X[0]);
3844
3844
  return;
3845
3845
  }
3846
- let t = fr(e, X, Z, b);
3846
+ let t = pr(e, X, Z, b);
3847
3847
  je(t.addValueText), De(t.userInfoMessage);
3848
3848
  }, [
3849
3849
  X,
@@ -3855,7 +3855,7 @@ function Or(t, n) {
3855
3855
  if (T) return;
3856
3856
  let t = e.target.value;
3857
3857
  if (Te(t), Ce(t), nt(t), v && t) {
3858
- let { suggestion: n } = dr(Z, t);
3858
+ let { suggestion: n } = fr(Z, t);
3859
3859
  n?.label && H.current && !e.nativeEvent.inputType?.includes("deleteContent") && (H.current.value = n.label, window.setTimeout(() => H.current?.setSelectionRange(t.length, n.label.length), 0));
3860
3860
  }
3861
3861
  }, [
@@ -3877,7 +3877,7 @@ function Or(t, n) {
3877
3877
  e.preventDefault(), ze(X.length - 1);
3878
3878
  return;
3879
3879
  }
3880
- let t = pr(e.key, e.shiftKey, g);
3880
+ let t = mr(e.key, e.shiftKey, g);
3881
3881
  if (t && !(e.key === "Tab" && !Q)) {
3882
3882
  if (t === "focusListbox" && e.key === "Tab" && !G.current?.querySelector("[role=\"option\"]:not([data-disabled]), [data-type=\"new-option\"]")) {
3883
3883
  tt();
@@ -3894,7 +3894,7 @@ function Or(t, n) {
3894
3894
  break;
3895
3895
  }
3896
3896
  case "focusListbox":
3897
- G.current && (Q || xe(!0), xr(G.current, {
3897
+ G.current && (Q || xe(!0), Sr(G.current, {
3898
3898
  disabled: T,
3899
3899
  allowUserInput: b,
3900
3900
  customUserInput: Ae,
@@ -3922,7 +3922,7 @@ function Or(t, n) {
3922
3922
  Fe.current = !1, $(!0);
3923
3923
  return;
3924
3924
  }
3925
- !g && X[0] && H.current && H.current.type !== "hidden" && (Le(!0), H.current.value = hr(X[0], Z, x)), $(!0), Ce(""), xe(!0);
3925
+ !g && X[0] && H.current && H.current.type !== "hidden" && (Le(!0), H.current.value = gr(X[0], Z, x)), $(!0), Ce(""), xe(!0);
3926
3926
  }
3927
3927
  }, [
3928
3928
  T,
@@ -3949,7 +3949,7 @@ function Or(t, n) {
3949
3949
  else {
3950
3950
  e.stopPropagation(), e.preventDefault();
3951
3951
  let t = !Q;
3952
- xe(t), t && G.current && xr(G.current, {
3952
+ xe(t), t && G.current && Sr(G.current, {
3953
3953
  disabled: T,
3954
3954
  allowUserInput: b,
3955
3955
  customUserInput: Ae,
@@ -3972,7 +3972,7 @@ function Or(t, n) {
3972
3972
  case "ArrowDown":
3973
3973
  case "ArrowUp":
3974
3974
  e.preventDefault(), Q ? xe(!1) : (xe(!0), G.current && window.setTimeout(() => {
3975
- G.current && xr(G.current, {
3975
+ G.current && Sr(G.current, {
3976
3976
  disabled: T,
3977
3977
  allowUserInput: b && !He,
3978
3978
  customUserInput: Ae,
@@ -3986,7 +3986,7 @@ function Or(t, n) {
3986
3986
  case "Home":
3987
3987
  case "End":
3988
3988
  e.preventDefault(), Q || xe(!0), G.current && window.setTimeout(() => {
3989
- G.current && xr(G.current, {
3989
+ G.current && Sr(G.current, {
3990
3990
  disabled: T,
3991
3991
  allowUserInput: b && !He,
3992
3992
  customUserInput: Ae,
@@ -4023,10 +4023,10 @@ function Or(t, n) {
4023
4023
  e.preventDefault(), et(t);
4024
4024
  break;
4025
4025
  case "ArrowDown":
4026
- e.preventDefault(), vr(e.currentTarget);
4026
+ e.preventDefault(), yr(e.currentTarget);
4027
4027
  break;
4028
4028
  case "ArrowUp":
4029
- e.preventDefault(), G.current && yr(e.currentTarget, G.current, y);
4029
+ e.preventDefault(), G.current && br(e.currentTarget, G.current, y);
4030
4030
  break;
4031
4031
  case "Escape":
4032
4032
  e.preventDefault(), xe(!1), V && (Fe.current = !0), q();
@@ -4091,10 +4091,10 @@ function Or(t, n) {
4091
4091
  e.preventDefault(), et(e.currentTarget.dataset.value || "");
4092
4092
  break;
4093
4093
  case "ArrowDown":
4094
- e.preventDefault(), G.current && br(G.current);
4094
+ e.preventDefault(), G.current && xr(G.current);
4095
4095
  break;
4096
4096
  case "ArrowUp":
4097
- e.preventDefault(), G.current && yr(e.currentTarget, G.current, y);
4097
+ e.preventDefault(), G.current && br(e.currentTarget, G.current, y);
4098
4098
  break;
4099
4099
  case "Escape": e.preventDefault(), xe(!1), V && (Fe.current = !0), q();
4100
4100
  }
@@ -4214,8 +4214,8 @@ function Or(t, n) {
4214
4214
  }
4215
4215
  //#endregion
4216
4216
  //#region src/components/combobox/Combobox.tsx
4217
- var kr = i((e, t) => {
4218
- let n = Or(e, t), r = [
4217
+ var Ar = i((e, t) => {
4218
+ let n = kr(e, t), r = [
4219
4219
  "pkt-combobox-component",
4220
4220
  n.fullwidth && "pkt-combobox-component--fullwidth",
4221
4221
  n.className
@@ -4250,8 +4250,8 @@ var kr = i((e, t) => {
4250
4250
  children: [/* @__PURE__ */ v("div", {
4251
4251
  className: "pkt-combobox",
4252
4252
  onBlur: n.handleFocusOut,
4253
- children: [/* @__PURE__ */ _(wr, { state: n }), /* @__PURE__ */ _(Tr, { state: n })]
4254
- }), n.tagPlacement === "outside" && n.multiple && /* @__PURE__ */ _(Sr, {
4253
+ children: [/* @__PURE__ */ _(Tr, { state: n }), /* @__PURE__ */ _(Er, { state: n })]
4254
+ }), n.tagPlacement === "outside" && n.multiple && /* @__PURE__ */ _(Cr, {
4255
4255
  state: n,
4256
4256
  outside: !0
4257
4257
  })]
@@ -4267,10 +4267,10 @@ var kr = i((e, t) => {
4267
4267
  })]
4268
4268
  });
4269
4269
  });
4270
- kr.displayName = "PktCombobox";
4270
+ Ar.displayName = "PktCombobox";
4271
4271
  //#endregion
4272
4272
  //#region src/components/consent/Consent.tsx
4273
- var Ar = null, jr = () => Ar || (Ar = new Promise((e, t) => {
4273
+ var jr = null, Mr = () => jr || (jr = new Promise((e, t) => {
4274
4274
  if (document.querySelector("#oslo-consent-script")) {
4275
4275
  e();
4276
4276
  return;
@@ -4279,14 +4279,14 @@ var Ar = null, jr = () => Ar || (Ar = new Promise((e, t) => {
4279
4279
  n.src = "https://cdn.web.oslo.kommune.no/cb/cb-v1.1.0.js", n.id = "oslo-consent-script", n.onload = () => e(), n.onerror = t, document.head.appendChild(n);
4280
4280
  let r = document.createElement("link");
4281
4281
  r.href = "https://cdn.web.oslo.kommune.no/cb/cb-v1.1.0.css", r.type = "text/css", r.rel = "stylesheet", r.id = "oslo-consent-styles", document.head.appendChild(r);
4282
- }), Ar), Mr = (e) => {
4282
+ }), jr), Nr = (e) => {
4283
4283
  if (typeof e != "string") return e;
4284
4284
  try {
4285
4285
  return JSON.parse(e);
4286
4286
  } catch {
4287
4287
  return e;
4288
4288
  }
4289
- }, Nr = (e) => Mr(e.value).items.reduce((e, t) => (e[t.name] = t.consent, e), {}), Pr = i(function({ devMode: e = !1, cookieDomain: t = null, cookieSecure: n = null, cookieExpiryDays: r = null, hotjarId: i = null, googleAnalyticsId: a = null, i18nLanguage: o = "nb", triggerType: s = "button", triggerText: l, onToggleConsent: u, ...d }, f) {
4289
+ }, Pr = (e) => Nr(e.value).items.reduce((e, t) => (e[t.name] = t.consent, e), {}), Fr = i(function({ devMode: e = !1, cookieDomain: t = null, cookieSecure: n = null, cookieExpiryDays: r = null, hotjarId: i = null, googleAnalyticsId: a = null, i18nLanguage: o = "nb", triggerType: s = "button", triggerText: l, onToggleConsent: u, ...d }, f) {
4290
4290
  let m = p(u);
4291
4291
  m.current = u;
4292
4292
  let h = p({
@@ -4312,7 +4312,7 @@ var Ar = null, jr = () => Ar || (Ar = new Promise((e, t) => {
4312
4312
  let r = (e) => {
4313
4313
  let t = m.current;
4314
4314
  t && t(new CustomEvent("toggle-consent", {
4315
- detail: Nr(e),
4315
+ detail: Pr(e),
4316
4316
  bubbles: !0,
4317
4317
  cancelable: !1
4318
4318
  }));
@@ -4330,7 +4330,7 @@ var Ar = null, jr = () => Ar || (Ar = new Promise((e, t) => {
4330
4330
  e || r({ value: o });
4331
4331
  }, 0), t && i.off("CookieManager.setCookie", t), t = (e) => r(e), i.on("CookieManager.setCookie", t);
4332
4332
  });
4333
- }, jr().then(() => {
4333
+ }, Mr().then(() => {
4334
4334
  e || g.current();
4335
4335
  }), () => {
4336
4336
  e = !0, t && window.__cookieEvents?.off("CookieManager.setCookie", t);
@@ -4370,13 +4370,13 @@ var Ar = null, jr = () => Ar || (Ar = new Promise((e, t) => {
4370
4370
  children: y
4371
4371
  });
4372
4372
  });
4373
- Pr.displayName = "PktConsent";
4373
+ Fr.displayName = "PktConsent";
4374
4374
  //#endregion
4375
4375
  //#region ../../shared-utils/device-utils.ts
4376
- var Fr = () => {
4376
+ var Ir = () => {
4377
4377
  let e = navigator.userAgent;
4378
4378
  return !!(/iP(hone|od|ad)/.test(e) || /Macintosh/.test(e) && "ontouchend" in document);
4379
- }, Ir = () => Fr() ? "text" : "date", Lr = (e) => !e || e.length !== 2 || dn(e[0], e[1]), Rr = (e, t, n, r, i, a, o = "medium") => ({
4379
+ }, Lr = () => Ir() ? "text" : "date", Rr = (e) => !e || e.length !== 2 || dn(e[0], e[1]), zr = (e, t, n, r, i, a, o = "medium") => ({
4380
4380
  "pkt-input": !0,
4381
4381
  "pkt-datepicker__input": !0,
4382
4382
  [`pkt-input--${o}`]: !0,
@@ -4385,27 +4385,27 @@ var Fr = () => {
4385
4385
  "pkt-datepicker--multiple": n,
4386
4386
  "pkt-datepicker--range": r,
4387
4387
  "ios-readonly-hack": i === !1 && a === "text"
4388
- }), zr = (e = "medium") => ({
4388
+ }), Br = (e = "medium") => ({
4389
4389
  "pkt-input-icon": !0,
4390
4390
  "pkt-btn": !0,
4391
4391
  "pkt-btn--icon-only": !0,
4392
4392
  "pkt-btn--tertiary": !0,
4393
4393
  [`pkt-btn--${e}`]: !0,
4394
4394
  "pkt-datepicker__calendar-button": !0
4395
- }), Br = (e) => ({
4395
+ }), Vr = (e) => ({
4396
4396
  "pkt-input-prefix": e,
4397
4397
  "pkt-hide": !e
4398
- }), Vr = (e, t, n) => !t && !n ? Array.isArray(e) ? e[0] || "" : e : Array.isArray(e) ? e.join(",") : e, Hr = (e, t, n = !1) => {
4398
+ }), Hr = (e, t, n) => !t && !n ? Array.isArray(e) ? e[0] || "" : e : Array.isArray(e) ? e.join(",") : e, Ur = (e, t, n = !1) => {
4399
4399
  if (!e || !t) return;
4400
4400
  let r = t.parentElement?.getBoundingClientRect() || t.getBoundingClientRect(), i = n ? r.height + 30 : r.height, a = e.getBoundingClientRect().height, o = n ? "calc(100% - 30px)" : "100%";
4401
4401
  r && typeof window < "u" && r.top + a > window.innerHeight && r.top - a > 0 && (o = `calc(100% - ${i}px - ${a}px)`), e.style.top = o;
4402
- }, Ur = (e, t, n, r, i, a) => {
4402
+ }, Wr = (e, t, n, r, i, a) => {
4403
4403
  let { key: o } = e;
4404
4404
  o === "," && (e.preventDefault(), a ? a(e) : i && i()), (o === "Space" || o === " ") && (e.preventDefault(), t(e)), o === "Enter" && (e.preventDefault(), n ? n() : r ? r() : i && i());
4405
- }, Wr = ({ open: e, multiple: t = !1, range: n = !1, weeknumbers: r = !1, withcontrols: i = !1, selected: a = [], earliest: o, latest: s, excludedates: l, excludeweekdays: u, maxMultiple: d, currentmonth: f, today: m, inputRef: h, hasCounter: g = !1, onDateSelected: v, onClose: y }) => {
4405
+ }, Gr = ({ open: e, multiple: t = !1, range: n = !1, weeknumbers: r = !1, withcontrols: i = !1, selected: a = [], earliest: o, latest: s, excludedates: l, excludeweekdays: u, maxMultiple: d, currentmonth: f, today: m, inputRef: h, hasCounter: g = !1, onDateSelected: v, onClose: y }) => {
4406
4406
  let b = p(null), x = p(!1);
4407
4407
  e && (x.current = !0), c(() => {
4408
- e && Hr(b.current, h?.current ?? null, g);
4408
+ e && Ur(b.current, h?.current ?? null, g);
4409
4409
  }, [
4410
4410
  e,
4411
4411
  h,
@@ -4434,7 +4434,7 @@ var Fr = () => {
4434
4434
  onClose: y
4435
4435
  })
4436
4436
  });
4437
- }, Gr = ({ dates: e, dateformat: t, idBase: n, strings: r, onDateRemoved: i }) => {
4437
+ }, Kr = ({ dates: e, dateformat: t, idBase: n, strings: r, onDateRemoved: i }) => {
4438
4438
  let a = un(e), o = ve(["datepicker"], r).datepicker.deleteDate;
4439
4439
  return /* @__PURE__ */ _("div", {
4440
4440
  className: "pkt-date-tags pkt-datepicker__tags",
@@ -4453,7 +4453,7 @@ var Fr = () => {
4453
4453
  }, e);
4454
4454
  })
4455
4455
  });
4456
- }, Kr = ({ state: e }) => {
4456
+ }, qr = ({ state: e }) => {
4457
4457
  let { id: t, inputId: n, values: r, dateformat: i, multiple: a, range: o, showRangeLabels: s, disabled: c, readOnly: l, required: u, label: d, name: f, placeholder: p, hasError: m, helptext: h, minStr: y, maxStr: b, inputType: x, isIOSDevice: S, strings: C, inputClasses: w, buttonClasses: T, rangeLabelClasses: E, datepickerInputsClasses: D, isInputDisabled: O, inputRef: k, inputRefTo: A, btnRef: j, toggleCalendar: M, handleFocus: N, handleSingleInputChange: P, handleRangeFromChange: ee, handleRangeToChange: te, handleRangeBlur: ne, handleMultipleBlur: F, handleTagRemoved: re, handleSingleKeydown: ie, handleRangeFromKeydown: ae, handleRangeToKeydown: oe, handleMultipleKeydown: se, restProps: I } = e, R = (e) => {
4458
4458
  e.preventDefault(), M();
4459
4459
  }, ce = (e) => {
@@ -4469,7 +4469,7 @@ var Fr = () => {
4469
4469
  children: C.datepicker.openPicker
4470
4470
  })]
4471
4471
  });
4472
- return a ? /* @__PURE__ */ v(g, { children: [/* @__PURE__ */ _(Gr, {
4472
+ return a ? /* @__PURE__ */ v(g, { children: [/* @__PURE__ */ _(Kr, {
4473
4473
  dates: r,
4474
4474
  dateformat: i,
4475
4475
  idBase: t,
@@ -4595,7 +4595,7 @@ var Fr = () => {
4595
4595
  }), z()]
4596
4596
  })
4597
4597
  });
4598
- }, qr = (e) => {
4598
+ }, Jr = (e) => {
4599
4599
  if (!e) return [];
4600
4600
  if (Array.isArray(e)) return e.filter(Boolean);
4601
4601
  if (typeof e == "string" && e.trimStart().startsWith("[")) try {
@@ -4606,8 +4606,8 @@ var Fr = () => {
4606
4606
  };
4607
4607
  //#endregion
4608
4608
  //#region src/components/datepicker/useDatepickerState.ts
4609
- function Jr(e, t) {
4610
- let { id: n, label: r, value: i, defaultValue: a, dateformat: s = "dd.MM.yyyy", multiple: l = !1, maxlength: d, range: h = !1, showRangeLabels: g = !1, weeknumbers: _ = !1, withcontrols: v = !1, excludedates: y, excludeweekdays: b, currentmonth: x, today: S, calendarOpen: C, timezone: w, fullwidth: T = !1, inputSize: E = "medium", hasFieldset: D = !1, counter: O, inline: k = !1, helptext: A, helptextDropdown: j, helptextDropdownButton: M, hasError: N = !1, errorMessage: P, optionalTag: ee = !1, optionalText: te, requiredTag: ne = !1, requiredText: F, tagText: re, useWrapper: ie = !0, strings: ae, disabled: oe = !1, readOnly: se = !1, required: I = !1, name: L, min: R, max: ce, placeholder: z, onChange: B, onValueChange: le, className: ue, ...de } = e, V = o((e) => e === void 0 ? [] : qr(e), []), H = i !== void 0, U = typeof a == "number" ? void 0 : a, [W, G] = m(() => V(i ?? U)), K = H ? V(i) : W, fe = p(W);
4609
+ function Yr(e, t) {
4610
+ let { id: n, label: r, value: i, defaultValue: a, dateformat: s = "dd.MM.yyyy", multiple: l = !1, maxlength: d, range: h = !1, showRangeLabels: g = !1, weeknumbers: _ = !1, withcontrols: v = !1, excludedates: y, excludeweekdays: b, currentmonth: x, today: S, calendarOpen: C, timezone: w, fullwidth: T = !1, inputSize: E = "medium", hasFieldset: D = !1, counter: O, inline: k = !1, helptext: A, helptextDropdown: j, helptextDropdownButton: M, hasError: N = !1, errorMessage: P, optionalTag: ee = !1, optionalText: te, requiredTag: ne = !1, requiredText: F, tagText: re, useWrapper: ie = !0, strings: ae, disabled: oe = !1, readOnly: se = !1, required: I = !1, name: L, min: R, max: ce, placeholder: z, onChange: B, onValueChange: le, className: ue, ...de } = e, V = o((e) => e === void 0 ? [] : Jr(e), []), H = i !== void 0, U = typeof a == "number" ? void 0 : a, [W, G] = m(() => V(i ?? U)), K = H ? V(i) : W, fe = p(W);
4611
4611
  c(() => {
4612
4612
  H && G(V(i));
4613
4613
  }, [
@@ -4619,12 +4619,12 @@ function Jr(e, t) {
4619
4619
  c(() => {
4620
4620
  C !== void 0 && pe(C);
4621
4621
  }, [C]);
4622
- let me = p(null), he = p(null), J = p(null), ge = p(null), Y = p(null), _e = f(() => Ir(), []), X = f(() => Fr(), []), ye = ve([
4622
+ let me = p(null), he = p(null), J = p(null), ge = p(null), Y = p(null), _e = f(() => Lr(), []), X = f(() => Ir(), []), ye = ve([
4623
4623
  "generic",
4624
4624
  "datepicker",
4625
4625
  "validation"
4626
4626
  ], ae), be = ae, Z = typeof R == "string" ? R : R === void 0 ? void 0 : String(R), Q = typeof ce == "string" ? ce : ce === void 0 ? void 0 : String(ce), xe = f(() => {
4627
- let e = Rr(T, g, l, h, se, _e, E);
4627
+ let e = zr(T, g, l, h, se, _e, E);
4628
4628
  return Object.entries(e).filter(([, e]) => e).map(([e]) => e).join(" ");
4629
4629
  }, [
4630
4630
  T,
@@ -4634,8 +4634,8 @@ function Jr(e, t) {
4634
4634
  se,
4635
4635
  _e,
4636
4636
  E
4637
- ]), Se = Object.entries(zr(E)).filter(([, e]) => e).map(([e]) => e).join(" "), Ce = f(() => {
4638
- let e = Br(g);
4637
+ ]), Se = Object.entries(Br(E)).filter(([, e]) => e).map(([e]) => e).join(" "), Ce = f(() => {
4638
+ let e = Vr(g);
4639
4639
  return Object.entries(e).filter(([, e]) => e).map(([e]) => e).join(" ");
4640
4640
  }, [g]), we = f(() => ["pkt-datepicker__inputs", h && "pkt-input__range-inputs"].filter(Boolean).join(" "), [h, g]), Te = f(() => {
4641
4641
  if (x) return x;
@@ -4672,7 +4672,7 @@ function Jr(e, t) {
4672
4672
  let Pe = o(() => {
4673
4673
  X && !q && pe(!0);
4674
4674
  }, [X, q]), Fe = o((e) => {
4675
- let t = qr(Vr(e, l, h));
4675
+ let t = Jr(Hr(e, l, h));
4676
4676
  Ae(t), Me(t), !l && !h && (Ne(), me.current?.focus());
4677
4677
  }, [
4678
4678
  l,
@@ -4700,7 +4700,7 @@ function Jr(e, t) {
4700
4700
  Ae,
4701
4701
  Me
4702
4702
  ]), Be = o(() => {
4703
- K.length === 2 && !Lr(K) && (Ae([K[0]]), Me([K[0]]));
4703
+ K.length === 2 && !Rr(K) && (Ae([K[0]]), Me([K[0]]));
4704
4704
  }, [
4705
4705
  K,
4706
4706
  Ae,
@@ -4736,13 +4736,13 @@ function Jr(e, t) {
4736
4736
  let t = e?.closest("form");
4737
4737
  t ? t.requestSubmit() : e?.blur();
4738
4738
  }, []), Ke = o((e) => {
4739
- Ur(e.nativeEvent, () => $(), () => Ge(me.current), void 0, () => me.current?.blur());
4739
+ Wr(e.nativeEvent, () => $(), () => Ge(me.current), void 0, () => me.current?.blur());
4740
4740
  }, [$, Ge]), qe = o((e) => {
4741
- Ur(e.nativeEvent, () => $(), () => Ge(me.current), () => he.current?.focus(), () => me.current?.blur());
4741
+ Wr(e.nativeEvent, () => $(), () => Ge(me.current), () => he.current?.focus(), () => me.current?.blur());
4742
4742
  }, [$, Ge]), Je = o((e) => {
4743
- Ur(e.nativeEvent, () => $(), () => Ge(he.current), void 0, () => he.current?.blur());
4743
+ Wr(e.nativeEvent, () => $(), () => Ge(he.current), void 0, () => he.current?.blur());
4744
4744
  }, [$, Ge]), Ye = o((e) => {
4745
- Ur(e.nativeEvent, () => $(), () => Ge(me.current), void 0, () => me.current?.blur(), Ue);
4745
+ Wr(e.nativeEvent, () => $(), () => Ge(me.current), void 0, () => me.current?.blur(), Ue);
4746
4746
  }, [
4747
4747
  $,
4748
4748
  Ge,
@@ -4847,8 +4847,8 @@ function Jr(e, t) {
4847
4847
  }
4848
4848
  //#endregion
4849
4849
  //#region src/components/datepicker/Datepicker.tsx
4850
- var Yr = i((e, t) => {
4851
- let n = Jr(e, t), r = [
4850
+ var Xr = i((e, t) => {
4851
+ let n = Yr(e, t), r = [
4852
4852
  "pkt-datepicker",
4853
4853
  `pkt-datepicker--${n.inputSize}`,
4854
4854
  n.fullwidth ? "pkt-datepicker--fullwidth" : "",
@@ -4882,9 +4882,9 @@ var Yr = i((e, t) => {
4882
4882
  counter: n.hasCounter,
4883
4883
  counterCurrent: n.values.length,
4884
4884
  counterMaxLength: n.maxlength,
4885
- children: /* @__PURE__ */ _(Kr, { state: n })
4885
+ children: /* @__PURE__ */ _(qr, { state: n })
4886
4886
  }),
4887
- /* @__PURE__ */ _(Wr, {
4887
+ /* @__PURE__ */ _(Gr, {
4888
4888
  open: n.calendarOpen,
4889
4889
  multiple: n.multiple,
4890
4890
  range: n.range,
@@ -4915,10 +4915,10 @@ var Yr = i((e, t) => {
4915
4915
  ]
4916
4916
  });
4917
4917
  });
4918
- Yr.displayName = "PktDatepicker";
4918
+ Xr.displayName = "PktDatepicker";
4919
4919
  //#endregion
4920
4920
  //#region ../../shared-utils/fileupload/size.ts
4921
- function Xr(e) {
4921
+ function Zr(e) {
4922
4922
  if (e == null || e === "") return;
4923
4923
  if (typeof e == "number") return Number.isFinite(e) && e > 0 ? e : void 0;
4924
4924
  let t = String(e).trim(), n = Number(t);
@@ -4937,15 +4937,15 @@ function Xr(e) {
4937
4937
  default: return;
4938
4938
  }
4939
4939
  }
4940
- function Zr(e) {
4940
+ function Qr(e) {
4941
4941
  return e < 1024 ? `${Math.round(e)} B` : e < 1048576 ? `${Math.round(e / 1024)} KB` : e < 1073741824 ? `${Math.round(e / 1048576)} MB` : `${Math.round(e / 1073741824)} GB`;
4942
4942
  }
4943
4943
  //#endregion
4944
4944
  //#region ../../shared-utils/fileupload/formats.ts
4945
- function Qr(e) {
4945
+ function $r(e) {
4946
4946
  return Array.isArray(e) ? e.map((e) => String(e).trim().toLowerCase()).filter(Boolean) : [];
4947
4947
  }
4948
- function $r(e, t, n) {
4948
+ function ei(e, t, n) {
4949
4949
  let r = e.toLowerCase().replace(/^\./, "");
4950
4950
  if (r.includes("/")) {
4951
4951
  if (r.endsWith("/*")) {
@@ -4956,33 +4956,33 @@ function $r(e, t, n) {
4956
4956
  }
4957
4957
  return t === r;
4958
4958
  }
4959
- function ei(e, t) {
4960
- let n = Qr(t);
4959
+ function ti(e, t) {
4960
+ let n = $r(t);
4961
4961
  if (n.length === 0) return !0;
4962
4962
  let r = e.name.split(".").pop()?.toLowerCase() ?? "", i = e.type.toLowerCase();
4963
- return n.some((e) => $r(e, r, i));
4963
+ return n.some((e) => ei(e, r, i));
4964
4964
  }
4965
- function ti(e, t) {
4965
+ function ni(e, t) {
4966
4966
  let n = (e ?? "").trim();
4967
4967
  if (n) return n;
4968
- let r = Qr(t);
4968
+ let r = $r(t);
4969
4969
  return r.length === 0 ? "" : r.map((e) => e.includes("/") || e.startsWith(".") ? e : `.${e}`).join(", ");
4970
4970
  }
4971
4971
  //#endregion
4972
4972
  //#region ../../shared-utils/fileupload/validation.ts
4973
- function ni(e, t, n) {
4973
+ function ri(e, t, n) {
4974
4974
  return ((e ?? "").trim() || t).replace(/\{(\w+)\}/g, (e, t) => n[t] ?? `{${t}}`);
4975
4975
  }
4976
- function ri(e, t) {
4977
- let n = Qr(t.allowedFormats);
4978
- if (n.length > 0 && !ei(e, n)) {
4976
+ function ii(e, t) {
4977
+ let n = $r(t.allowedFormats);
4978
+ if (n.length > 0 && !ti(e, n)) {
4979
4979
  let e = n.join(", "), r = ce.fileupload.invalidFormat;
4980
- return ni(t.formatErrorMessage, r, { formats: e });
4980
+ return ri(t.formatErrorMessage, r, { formats: e });
4981
4981
  }
4982
- let r = Xr(t.maxFileSize);
4982
+ let r = Zr(t.maxFileSize);
4983
4983
  if (r !== void 0 && e.size > r) {
4984
- let e = Zr(r), n = ce.fileupload.sizeTooLarge;
4985
- return ni(t.sizeErrorMessage, n, { maxSize: e });
4984
+ let e = Qr(r), n = ce.fileupload.sizeTooLarge;
4985
+ return ri(t.sizeErrorMessage, n, { maxSize: e });
4986
4986
  }
4987
4987
  if (t.onFileValidation) {
4988
4988
  let n = t.onFileValidation(e);
@@ -4990,7 +4990,7 @@ function ri(e, t) {
4990
4990
  }
4991
4991
  return null;
4992
4992
  }
4993
- function ii(e) {
4993
+ function ai(e) {
4994
4994
  let t = e.file;
4995
4995
  if (t?.type?.startsWith("image/")) return !0;
4996
4996
  let n = e.attributes?.targetFilename || t?.name || "";
@@ -4998,10 +4998,10 @@ function ii(e) {
4998
4998
  }
4999
4999
  //#endregion
5000
5000
  //#region ../../shared-utils/fileupload/transfers.ts
5001
- function ai(e) {
5001
+ function oi(e) {
5002
5002
  return typeof e == "number" ? "in-progress" : e === "error" ? "error" : "idle";
5003
5003
  }
5004
- function oi(e, t, n) {
5004
+ function si(e, t, n) {
5005
5005
  let r = {
5006
5006
  "in-progress": 0,
5007
5007
  error: 1,
@@ -5016,11 +5016,11 @@ function oi(e, t, n) {
5016
5016
  showProgress: r?.showProgress,
5017
5017
  lastProgress: r?.lastProgress
5018
5018
  };
5019
- }).sort((e, t) => r[ai(e.progress)] - r[ai(t.progress)]);
5019
+ }).sort((e, t) => r[oi(e.progress)] - r[oi(t.progress)]);
5020
5020
  }
5021
5021
  //#endregion
5022
5022
  //#region ../../shared-utils/focus-trap/index.ts
5023
- function si(e) {
5023
+ function ci(e) {
5024
5024
  if (!e) return [];
5025
5025
  let t = [
5026
5026
  "a[href]:not([tabindex=\"-1\"])",
@@ -5032,7 +5032,7 @@ function si(e) {
5032
5032
  ].join(", ");
5033
5033
  return Array.from(e.querySelectorAll(t)).filter((e) => !e.hasAttribute("inert"));
5034
5034
  }
5035
- var ci = [
5035
+ var li = [
5036
5036
  "a[href]",
5037
5037
  "button:not([disabled])",
5038
5038
  "input:not([disabled]):not([type=\"hidden\"])",
@@ -5040,7 +5040,7 @@ var ci = [
5040
5040
  "textarea:not([disabled])",
5041
5041
  "summary",
5042
5042
  "[tabindex]:not([tabindex=\"-1\"])"
5043
- ].join(", "), li = (e) => {
5043
+ ].join(", "), ui = (e) => {
5044
5044
  if (e.hasAttribute("inert") || e.closest("[inert]") || e.hidden || e.closest("[hidden]")) return !0;
5045
5045
  let t = e;
5046
5046
  for (; t;) {
@@ -5053,33 +5053,33 @@ var ci = [
5053
5053
  t = n.parentElement;
5054
5054
  }
5055
5055
  return !1;
5056
- }, ui = (e, t) => {
5057
- e.matches(ci) && !li(e) && t.push(e);
5056
+ }, di = (e, t) => {
5057
+ e.matches(li) && !ui(e) && t.push(e);
5058
5058
  let n = e.shadowRoot;
5059
- if (n) for (let e of Array.from(n.children)) ui(e, t);
5060
- for (let n of Array.from(e.children)) ui(n, t);
5059
+ if (n) for (let e of Array.from(n.children)) di(e, t);
5060
+ for (let n of Array.from(e.children)) di(n, t);
5061
5061
  };
5062
- function di(e) {
5062
+ function fi(e) {
5063
5063
  if (!e) return [];
5064
5064
  let t = [];
5065
- for (let n of Array.from(e.children)) ui(n, t);
5065
+ for (let n of Array.from(e.children)) di(n, t);
5066
5066
  return t;
5067
5067
  }
5068
- function fi(e = document) {
5068
+ function pi(e = document) {
5069
5069
  let t = e.activeElement;
5070
5070
  for (; t?.shadowRoot?.activeElement;) t = t.shadowRoot.activeElement;
5071
5071
  return t;
5072
5072
  }
5073
- function pi(e, t) {
5073
+ function mi(e, t) {
5074
5074
  if (e.key !== "Tab") return !1;
5075
- let n = si(t);
5075
+ let n = ci(t);
5076
5076
  if (n.length === 0) return e.preventDefault(), !0;
5077
5077
  let r = n[0], i = n[n.length - 1], a = (t?.ownerDocument ?? document).activeElement, o = !!a && n.includes(a);
5078
5078
  return e.shiftKey ? !o || a === r ? (e.preventDefault(), i.focus(), !0) : !1 : !o || a === i ? (e.preventDefault(), r.focus(), !0) : !1;
5079
5079
  }
5080
5080
  //#endregion
5081
5081
  //#region ../../shared-utils/fileupload/truncate.ts
5082
- function mi(e, t) {
5082
+ function hi(e, t) {
5083
5083
  return !t || t <= 0 || e.length <= t + 3 ? null : {
5084
5084
  head: e.slice(0, e.length - t),
5085
5085
  tail: e.slice(-t)
@@ -5087,12 +5087,12 @@ function mi(e, t) {
5087
5087
  }
5088
5088
  //#endregion
5089
5089
  //#region ../../shared-utils/fileupload/navigation.ts
5090
- function hi(e, t, n) {
5090
+ function gi(e, t, n) {
5091
5091
  return n <= 0 ? 0 : t === "prev" ? e <= 0 ? n - 1 : e - 1 : e >= n - 1 ? 0 : e + 1;
5092
5092
  }
5093
5093
  //#endregion
5094
5094
  //#region ../../shared-utils/fileupload/announcements.ts
5095
- function gi(e, t) {
5095
+ function _i(e, t) {
5096
5096
  let n = e.length;
5097
5097
  if (n === 0 || !t || t.length === 0) return {
5098
5098
  totalCount: n,
@@ -5112,23 +5112,23 @@ function gi(e, t) {
5112
5112
  }
5113
5113
  //#endregion
5114
5114
  //#region ../../shared-utils/fileupload/filename.ts
5115
- var _i = ".jpeg, .jpg, .png, .gif, .webp, .heic";
5116
- function vi(e, t = ce.fileupload.unknownFilename) {
5115
+ var vi = ".jpeg, .jpg, .png, .gif, .webp, .heic";
5116
+ function yi(e, t = ce.fileupload.unknownFilename) {
5117
5117
  return e.attributes?.targetFilename || e.file?.name || t;
5118
5118
  }
5119
5119
  //#endregion
5120
5120
  //#region src/utils/stringutils.ts
5121
- var yi = () => ("00000000000000000" + (Math.random() * 0x10000000000000000).toString(16)).slice(-16), bi = () => {
5122
- let e = yi(), t = yi();
5121
+ var bi = () => ("00000000000000000" + (Math.random() * 0x10000000000000000).toString(16)).slice(-16), xi = () => {
5122
+ let e = bi(), t = bi();
5123
5123
  return e.slice(0, 8) + "-" + e.slice(8, 12) + "-4" + e.slice(13) + "-a" + t.slice(1, 4) + "-" + t.slice(4);
5124
- }, xi = class {
5124
+ }, Si = class {
5125
5125
  fileId;
5126
5126
  file;
5127
5127
  attributes;
5128
5128
  constructor(e, t) {
5129
- this.fileId = t || bi(), this.file = e, this.attributes = { targetFilename: e.name };
5129
+ this.fileId = t || xi(), this.file = e, this.attributes = { targetFilename: e.name };
5130
5130
  }
5131
- }, Si = n({}), Ci = i(({ id: e, multiple: t, value: n, onFilesAdded: r = () => {}, name: i, uploadStrategy: a, accept: s, isThumbnailView: l = !1, disabled: d = !1, hasVisibleLabel: h = !1, strings: y, ...b }, x) => {
5131
+ }, Ci = n({}), wi = i(({ id: e, multiple: t, value: n, onFilesAdded: r = () => {}, name: i, uploadStrategy: a, accept: s, isThumbnailView: l = !1, disabled: d = !1, hasVisibleLabel: h = !1, strings: y, ...b }, x) => {
5132
5132
  let S = p(null), C = typeof s == "string" && s.trim().length > 0 ? s : void 0, w = f(() => C ? C.split(/\s*,\s*/).map((e) => e.trim()).filter(Boolean).join(", ").toUpperCase() : "", [C]);
5133
5133
  u(x, () => S.current);
5134
5134
  let [T, E] = m(!1), D = ve(["fileupload"], y), O = f(() => l ? t ? {
@@ -5153,14 +5153,14 @@ var yi = () => ("00000000000000000" + (Math.random() * 0x10000000000000000).toSt
5153
5153
  D
5154
5154
  ]), k = o((e) => {
5155
5155
  if (S.current) try {
5156
- S.current.files = wi(e);
5156
+ S.current.files = Ti(e);
5157
5157
  } catch {}
5158
5158
  }, [S.current, n]);
5159
5159
  c(() => {
5160
5160
  k(n);
5161
5161
  }, [S, n]);
5162
5162
  let A = o((e) => {
5163
- r(e.map((e) => new xi(e))), S.current && (S.current.value = "");
5163
+ r(e.map((e) => new Si(e))), S.current && (S.current.value = "");
5164
5164
  }, [r]), j = (e) => {
5165
5165
  let t = e.target.files;
5166
5166
  if (t.length === 0) {
@@ -5244,11 +5244,11 @@ var yi = () => ("00000000000000000" + (Math.random() * 0x10000000000000000).toSt
5244
5244
  })
5245
5245
  ]
5246
5246
  });
5247
- }), wi = (e) => {
5247
+ }), Ti = (e) => {
5248
5248
  let t = new DataTransfer();
5249
5249
  for (let n of e) t.items.add(n.file);
5250
5250
  return t.files;
5251
- }, Ti = i(({ id: e, ariaDescribedby: t, ariaLabelledby: n, counter: r, hasFieldset: i, counterMaxLength: a, className: o, disabled: s, errorMessage: l, hasError: u = !1, helptext: d, helptextDropdown: f, helptextDropdownButton: p, inline: h, fullwidth: g = !1, label: v, name: y, optionalTag: b = !1, optionalText: x, requiredTag: S = !1, requiredText: C, tagText: w = null, placeholder: T, rows: E, useWrapper: D = !0, onChange: O, value: k, autoComplete: A = "off", minLength: j, maxLength: M, readOnly: N, skipForwardTestid: P = !1, inputSize: ee = "medium", strings: te, ...ne }, F) => {
5251
+ }, Ei = i(({ id: e, ariaDescribedby: t, ariaLabelledby: n, counter: r, hasFieldset: i, counterMaxLength: a, className: o, disabled: s, errorMessage: l, hasError: u = !1, helptext: d, helptextDropdown: f, helptextDropdownButton: p, inline: h, fullwidth: g = !1, label: v, name: y, optionalTag: b = !1, optionalText: x, requiredTag: S = !1, requiredText: C, tagText: w = null, placeholder: T, rows: E, useWrapper: D = !0, onChange: O, value: k, autoComplete: A = "off", minLength: j, maxLength: M, readOnly: N, skipForwardTestid: P = !1, inputSize: ee = "medium", strings: te, ...ne }, F) => {
5252
5252
  let re = r ?? (a ?? 0) > 0, ie = [
5253
5253
  o,
5254
5254
  "pkt-textinput",
@@ -5314,19 +5314,19 @@ var yi = () => ("00000000000000000" + (Math.random() * 0x10000000000000000).toSt
5314
5314
  })
5315
5315
  });
5316
5316
  });
5317
- Ti.displayName = "PktTextarea";
5317
+ Ei.displayName = "PktTextarea";
5318
5318
  //#endregion
5319
5319
  //#region src/components/fileupload/extensions/Comments.tsx
5320
- var Ei = "comments", Di = (e) => {
5320
+ var Di = "comments", Oi = (e) => {
5321
5321
  let t = new Date(e);
5322
5322
  return Number.isNaN(t.getTime()) ? e : `${String(t.getDate()).padStart(2, "0")}.${String(t.getMonth() + 1).padStart(2, "0")}.${t.getFullYear()} kl. ${String(t.getHours()).padStart(2, "0")}:${String(t.getMinutes()).padStart(2, "0")}`;
5323
- }, Oi = ({ fileItem: e, disabled: t, closeOperationUi: n, onAddComment: r, existingComment: i }) => {
5323
+ }, ki = ({ fileItem: e, disabled: t, closeOperationUi: n, onAddComment: r, existingComment: i }) => {
5324
5324
  let a = p(null), o = !!i;
5325
5325
  return d(() => {
5326
5326
  let e = setTimeout(() => a.current?.focus({ preventScroll: !0 }), 0);
5327
5327
  return () => clearTimeout(e);
5328
5328
  }, [e.fileId]), /* @__PURE__ */ v(g, { children: [
5329
- /* @__PURE__ */ _(Ti, {
5329
+ /* @__PURE__ */ _(Ei, {
5330
5330
  autoFocus: !0,
5331
5331
  label: o ? "Rediger kommentar" : "Legg til kommentar",
5332
5332
  name: `comment-${e.fileId}`,
@@ -5359,7 +5359,7 @@ var Ei = "comments", Di = (e) => {
5359
5359
  children: "Avbryt"
5360
5360
  })
5361
5361
  ] });
5362
- }, ki = ({ comment: e, disabled: t, onDeleteComment: n, onEditComment: r }) => /* @__PURE__ */ _("div", {
5362
+ }, Ai = ({ comment: e, disabled: t, onDeleteComment: n, onEditComment: r }) => /* @__PURE__ */ _("div", {
5363
5363
  className: "pkt-fileupload__queue-display__item__comments",
5364
5364
  children: /* @__PURE__ */ v("div", {
5365
5365
  className: "pkt-fileupload__queue-display__item__comment",
@@ -5371,7 +5371,7 @@ var Ei = "comments", Di = (e) => {
5371
5371
  children: e.text
5372
5372
  }), /* @__PURE__ */ _("time", {
5373
5373
  className: "pkt-fileupload__queue-display__item__comment__time",
5374
- children: Di(e.timestamp)
5374
+ children: Oi(e.timestamp)
5375
5375
  })]
5376
5376
  }), /* @__PURE__ */ v("div", {
5377
5377
  className: "pkt-fileupload__queue-display__item__comment__actions",
@@ -5392,46 +5392,46 @@ var Ei = "comments", Di = (e) => {
5392
5392
  })]
5393
5393
  })]
5394
5394
  })
5395
- }), Ai = ({ comments: e }) => {
5396
- let t = s(Si);
5395
+ }), ji = ({ comments: e }) => {
5396
+ let t = s(Ci);
5397
5397
  return /* @__PURE__ */ _("input", {
5398
5398
  type: "hidden",
5399
5399
  name: `${t.name}-comments`,
5400
5400
  value: e ? JSON.stringify(e) : ""
5401
5401
  });
5402
- }, ji = (e) => e.getAttribute(Ei) ?? [], Mi = {
5402
+ }, Mi = (e) => e.getAttribute(Di) ?? [], Ni = {
5403
5403
  id: "comment",
5404
- title: (e) => (e.attributes?.[Ei] ?? []).length > 0 ? "" : "Legg til kommentar",
5404
+ title: (e) => (e.attributes?.[Di] ?? []).length > 0 ? "" : "Legg til kommentar",
5405
5405
  ariaLabel: "Legg til kommentar",
5406
5406
  renderExtendedUI: (e) => {
5407
- let t = ji(e)[0];
5408
- return /* @__PURE__ */ _(Oi, {
5407
+ let t = Mi(e)[0];
5408
+ return /* @__PURE__ */ _(ki, {
5409
5409
  fileItem: e.file,
5410
5410
  disabled: e.disabled,
5411
5411
  closeOperationUi: e.close,
5412
5412
  onAddComment: (t) => {
5413
- e.setAttribute(Ei, [t]);
5413
+ e.setAttribute(Di, [t]);
5414
5414
  },
5415
5415
  existingComment: t
5416
5416
  });
5417
5417
  },
5418
5418
  renderContent: (e) => {
5419
5419
  if (e.isActive) return null;
5420
- let t = ji(e)[0];
5421
- return t ? /* @__PURE__ */ _(ki, {
5420
+ let t = Mi(e)[0];
5421
+ return t ? /* @__PURE__ */ _(Ai, {
5422
5422
  comment: t,
5423
5423
  disabled: e.disabled,
5424
5424
  onEditComment: e.activate,
5425
- onDeleteComment: () => e.setAttribute(Ei, void 0)
5425
+ onDeleteComment: () => e.setAttribute(Di, void 0)
5426
5426
  }) : null;
5427
5427
  },
5428
- renderHidden: (e) => /* @__PURE__ */ _(Ai, { comments: e.getAttribute(Ei) }, `comments${e.file.fileId}`)
5429
- }, Ni = (e) => ({
5428
+ renderHidden: (e) => /* @__PURE__ */ _(ji, { comments: e.getAttribute(Di) }, `comments${e.file.fileId}`)
5429
+ }, Pi = (e) => ({
5430
5430
  id: "remove",
5431
5431
  title: "Slett",
5432
5432
  ariaLabel: "Slett fil",
5433
5433
  onClick: ({ file: t }) => e(t.fileId)
5434
- }), Pi = ({ initialValue: e, disabled: t, onSave: n, onCancel: r }) => {
5434
+ }), Fi = ({ initialValue: e, disabled: t, onSave: n, onCancel: r }) => {
5435
5435
  let i = p(null), a = l(), o = () => n(i.current?.value ?? "");
5436
5436
  return /* @__PURE__ */ v(g, { children: [
5437
5437
  /* @__PURE__ */ _("label", {
@@ -5466,19 +5466,19 @@ var Ei = "comments", Di = (e) => {
5466
5466
  children: "Avbryt"
5467
5467
  })
5468
5468
  ] });
5469
- }, Fi = ({ targetFilename: e }) => {
5470
- let t = s(Si);
5469
+ }, Ii = ({ targetFilename: e }) => {
5470
+ let t = s(Ci);
5471
5471
  return /* @__PURE__ */ _("input", {
5472
5472
  type: "hidden",
5473
5473
  name: `${t.name}-targetFilename`,
5474
5474
  value: e
5475
5475
  });
5476
- }, Ii = (e) => e.getAttribute("targetFilename") || vi(e.file, ""), Li = {
5476
+ }, Li = (e) => e.getAttribute("targetFilename") || yi(e.file, ""), Ri = {
5477
5477
  id: "rename",
5478
5478
  title: "Rediger",
5479
5479
  ariaLabel: "Rediger filnavn",
5480
- renderInlineUI: (e) => /* @__PURE__ */ _(Pi, {
5481
- initialValue: Ii(e),
5480
+ renderInlineUI: (e) => /* @__PURE__ */ _(Fi, {
5481
+ initialValue: Li(e),
5482
5482
  disabled: e.disabled,
5483
5483
  onSave: (t) => {
5484
5484
  let n = t.trim();
@@ -5486,8 +5486,8 @@ var Ei = "comments", Di = (e) => {
5486
5486
  },
5487
5487
  onCancel: e.close
5488
5488
  }),
5489
- renderHidden: (e) => /* @__PURE__ */ _(Fi, { targetFilename: Ii(e) }, `rename${e.file.fileId}`)
5490
- }, Ri = (e, t) => {
5489
+ renderHidden: (e) => /* @__PURE__ */ _(Ii, { targetFilename: Li(e) }, `rename${e.file.fileId}`)
5490
+ }, zi = (e, t) => {
5491
5491
  let n = o((t, n) => e.find((e) => e.fileId === t)?.attributes?.[n], [e]), r = o((n, r, i) => {
5492
5492
  let a = e.find((e) => e.fileId === n);
5493
5493
  if (!a) return;
@@ -5507,7 +5507,7 @@ var Ei = "comments", Di = (e) => {
5507
5507
  setAttribute: (t, n) => r(e, t, n)
5508
5508
  }), [n, r])
5509
5509
  };
5510
- }, zi = (e) => {
5510
+ }, Bi = (e) => {
5511
5511
  let [t, n] = m(!1), [r, i] = m(0), a = p(null);
5512
5512
  return {
5513
5513
  isOpen: t,
@@ -5521,10 +5521,10 @@ var Ei = "comments", Di = (e) => {
5521
5521
  n(!1), a.current?.close();
5522
5522
  }, []),
5523
5523
  navigate: o((t) => {
5524
- e.length !== 0 && i((n) => hi(n, t, e.length));
5524
+ e.length !== 0 && i((n) => gi(n, t, e.length));
5525
5525
  }, [e.length])
5526
5526
  };
5527
- }, Bi = (e) => {
5527
+ }, Vi = (e) => {
5528
5528
  let [t, n] = m({});
5529
5529
  return c(() => {
5530
5530
  n((t) => {
@@ -5551,7 +5551,7 @@ var Ei = "comments", Di = (e) => {
5551
5551
  });
5552
5552
  }, [])
5553
5553
  };
5554
- }, Vi = (e, { uploadStrategy: t, required: n, currentFileCount: r, onMissingFiles: i }) => {
5554
+ }, Hi = (e, { uploadStrategy: t, required: n, currentFileCount: r, onMissingFiles: i }) => {
5555
5555
  c(() => {
5556
5556
  if (t !== "custom" || !n) return;
5557
5557
  let a = e.current?.form;
@@ -5569,7 +5569,7 @@ var Ei = "comments", Di = (e) => {
5569
5569
  r,
5570
5570
  i
5571
5571
  ]);
5572
- }, Hi = i(({ ariaLabel: e, ariaLabelledby: t, ariaLive: n = "polite", ariaValueText: r, id: i, role: a = "progressbar", skin: o = "dark-blue", statusPlacement: s = "following", statusType: l = "none", title: u, titlePosition: d = "left", valueCurrent: h = 0, valueMax: g = 100, valueMin: y = 0, className: b, ...x }, S) => {
5572
+ }, Ui = i(({ ariaLabel: e, ariaLabelledby: t, ariaLive: n = "polite", ariaValueText: r, id: i, role: a = "progressbar", skin: o = "dark-blue", statusPlacement: s = "following", statusType: l = "none", title: u, titlePosition: d = "left", valueCurrent: h = 0, valueMax: g = 100, valueMin: y = 0, className: b, ...x }, S) => {
5573
5573
  let C = f(() => qn(), []), w = i || C, T = p(null), [E, D] = m(0);
5574
5574
  c(() => {
5575
5575
  T.current && D(T.current.getBoundingClientRect().width || 0);
@@ -5621,41 +5621,41 @@ var Ei = "comments", Di = (e) => {
5621
5621
  })
5622
5622
  });
5623
5623
  });
5624
- Hi.displayName = "PktProgressbar";
5624
+ Ui.displayName = "PktProgressbar";
5625
5625
  //#endregion
5626
5626
  //#region ../../shared-utils/scroll-lock/index.ts
5627
- var Ui = "is-scroll-locked", Wi = 0, Gi = 0, Ki = () => typeof document < "u" && typeof window < "u", qi = () => {
5627
+ var Wi = "is-scroll-locked", Gi = 0, Ki = 0, qi = () => typeof document < "u" && typeof window < "u", Ji = () => {
5628
5628
  let e = document.body, t = document.documentElement;
5629
- Gi = window.scrollY || window.pageYOffset;
5629
+ Ki = window.scrollY || window.pageYOffset;
5630
5630
  let n = window.innerWidth - t.clientWidth;
5631
- n > 0 && (e.style.paddingRight = `${n}px`), e.style.position = "fixed", e.style.top = `-${Gi}px`, e.style.left = "0", e.style.right = "0", e.style.width = "100%", e.style.overflow = "hidden", t.classList.add(Ui);
5632
- }, Ji = () => {
5633
- let e = document.body, t = document.documentElement;
5634
- e.style.removeProperty("position"), e.style.removeProperty("top"), e.style.removeProperty("left"), e.style.removeProperty("right"), e.style.removeProperty("width"), e.style.removeProperty("overflow"), e.style.removeProperty("padding-right"), t.classList.remove(Ui), typeof window.scrollTo == "function" && window.scrollTo({ top: Gi });
5631
+ n > 0 && (e.style.paddingRight = `${n}px`), e.style.position = "fixed", e.style.top = `-${Ki}px`, e.style.left = "0", e.style.right = "0", e.style.width = "100%", e.style.overflow = "hidden", t.classList.add(Wi);
5635
5632
  }, Yi = () => {
5636
- Ki() && (Wi += 1, Wi === 1 && qi());
5633
+ let e = document.body, t = document.documentElement;
5634
+ e.style.removeProperty("position"), e.style.removeProperty("top"), e.style.removeProperty("left"), e.style.removeProperty("right"), e.style.removeProperty("width"), e.style.removeProperty("overflow"), e.style.removeProperty("padding-right"), t.classList.remove(Wi), typeof window.scrollTo == "function" && window.scrollTo({ top: Ki });
5637
5635
  }, Xi = () => {
5638
- !Ki() || Wi === 0 || (--Wi, Wi === 0 && Ji());
5639
- }, Zi = () => ({ locked: !1 }), Qi = (e, t) => {
5640
- e.locked !== t && (e.locked = t, t ? Yi() : Xi());
5641
- }, $i = i(({ children: e, className: t, open: n = !1, headingText: r = "", hideCloseButton: i = !1, closeOnBackdropClick: a = !1, size: s = "medium", removePadding: l = !1, closeButtonSkin: u = "blue", variant: d = "dialog", drawerPosition: f = "right", transparentBackdrop: m = !1, onClose: h, ...g }, y) => {
5642
- let b = p(null), x = p(Zi()), S = o((e) => {
5636
+ qi() && (Gi += 1, Gi === 1 && Ji());
5637
+ }, Zi = () => {
5638
+ !qi() || Gi === 0 || (--Gi, Gi === 0 && Yi());
5639
+ }, Qi = () => ({ locked: !1 }), $i = (e, t) => {
5640
+ e.locked !== t && (e.locked = t, t ? Xi() : Zi());
5641
+ }, ea = i(({ children: e, className: t, open: n = !1, headingText: r = "", hideCloseButton: i = !1, closeOnBackdropClick: a = !1, size: s = "medium", removePadding: l = !1, closeButtonSkin: u = "blue", variant: d = "dialog", drawerPosition: f = "right", transparentBackdrop: m = !1, onClose: h, ...g }, y) => {
5642
+ let b = p(null), x = p(Qi()), S = o((e) => {
5643
5643
  b.current = e, typeof y == "function" ? y(e) : y && (y.current = e);
5644
5644
  }, [y]), C = o(() => {
5645
- b.current?.open && (b.current.close(), Qi(x.current, !1), h?.());
5645
+ b.current?.open && (b.current.close(), $i(x.current, !1), h?.());
5646
5646
  }, [h]);
5647
5647
  c(() => {
5648
- n ? (b.current?.open || b.current?.showModal(), Qi(x.current, !0)) : (b.current?.open && b.current.close(), Qi(x.current, !1));
5648
+ n ? (b.current?.open || b.current?.showModal(), $i(x.current, !0)) : (b.current?.open && b.current.close(), $i(x.current, !1));
5649
5649
  }, [n]), c(() => {
5650
5650
  let e = x.current;
5651
5651
  return () => {
5652
- Qi(e, !1);
5652
+ $i(e, !1);
5653
5653
  };
5654
5654
  }, []);
5655
5655
  let w = o((e) => {
5656
5656
  a && e.target === b.current && C();
5657
5657
  }, [a, C]), T = o(() => {
5658
- Qi(x.current, !1), h?.();
5658
+ $i(x.current, !1), h?.();
5659
5659
  }, [h]), E = u === "blue", D = (0, M.default)({
5660
5660
  "pkt-modal": !0,
5661
5661
  "pkt-modal--removePadding": l,
@@ -5709,11 +5709,11 @@ var Ui = "is-scroll-locked", Wi = 0, Gi = 0, Ki = () => typeof document < "u" &&
5709
5709
  })
5710
5710
  });
5711
5711
  });
5712
- $i.displayName = "PktModal";
5712
+ ea.displayName = "PktModal";
5713
5713
  //#endregion
5714
5714
  //#region src/components/fileupload/Truncate.tsx
5715
- var ea = n({ tail: 5 }), ta = ({ children: e, tail: t }) => {
5716
- let n = s(ea), r = mi(e, t === void 0 ? n.tail : t);
5715
+ var ta = n({ tail: 5 }), na = ({ children: e, tail: t }) => {
5716
+ let n = s(ta), r = hi(e, t === void 0 ? n.tail : t);
5717
5717
  return r ? /* @__PURE__ */ v(g, { children: [/* @__PURE__ */ _("span", {
5718
5718
  className: "pkt-fileupload__queue-display__item__title__head",
5719
5719
  "data-pkt-truncate-part": "first",
@@ -5726,18 +5726,18 @@ var ea = n({ tail: 5 }), ta = ({ children: e, tail: t }) => {
5726
5726
  "data-pkt-truncate-part": "first",
5727
5727
  children: e
5728
5728
  });
5729
- }, na = (e) => /* @__PURE__ */ _("button", {
5729
+ }, ra = (e) => /* @__PURE__ */ _("button", {
5730
5730
  type: "button",
5731
5731
  onClick: e.onClick,
5732
5732
  disabled: e.disabled,
5733
5733
  className: "pkt-fileupload__queue-display__item__cancel-button",
5734
5734
  "aria-label": e.ariaLabel || "Avbryt opplasting",
5735
5735
  children: e.label || "Avbryt"
5736
- }), ra = () => /* @__PURE__ */ _("span", {
5736
+ }), ia = () => /* @__PURE__ */ _("span", {
5737
5737
  className: "pkt-fileupload__queue-display__item__loading-text",
5738
5738
  "aria-label": "Laster opp fil",
5739
5739
  children: "Laster opp"
5740
- }), ia = ({ cancelTransfer: e, transferItem: t, disabled: n = !1 }) => {
5740
+ }), aa = ({ cancelTransfer: e, transferItem: t, disabled: n = !1 }) => {
5741
5741
  let r = t.showProgress ?? t.progress !== 0;
5742
5742
  return /* @__PURE__ */ v(g, { children: [
5743
5743
  /* @__PURE__ */ _(L, {
@@ -5748,21 +5748,21 @@ var ea = n({ tail: 5 }), ta = ({ children: e, tail: t }) => {
5748
5748
  /* @__PURE__ */ v("p", {
5749
5749
  className: "pkt-fileupload__queue-display__item__title",
5750
5750
  "aria-label": "Filnavn",
5751
- children: [/* @__PURE__ */ _(ta, { children: vi(t) }), /* @__PURE__ */ v("span", {
5751
+ children: [/* @__PURE__ */ _(na, { children: yi(t) }), /* @__PURE__ */ v("span", {
5752
5752
  className: "pkt-fileupload__queue-display__item__filesize",
5753
5753
  children: [
5754
5754
  " ",
5755
5755
  "(",
5756
- Zr(t.file.size),
5756
+ Qr(t.file.size),
5757
5757
  ")"
5758
5758
  ]
5759
5759
  })]
5760
5760
  }),
5761
- /* @__PURE__ */ _(na, {
5761
+ /* @__PURE__ */ _(ra, {
5762
5762
  onClick: e,
5763
5763
  disabled: n
5764
5764
  }),
5765
- r ? /* @__PURE__ */ v(g, { children: [/* @__PURE__ */ _(Hi, {
5765
+ r ? /* @__PURE__ */ v(g, { children: [/* @__PURE__ */ _(Ui, {
5766
5766
  valueCurrent: t.progress * 100,
5767
5767
  statusType: "none",
5768
5768
  valueMax: 100,
@@ -5772,20 +5772,20 @@ var ea = n({ tail: 5 }), ta = ({ children: e, tail: t }) => {
5772
5772
  className: "pkt-fileupload__queue-display__item__percentage",
5773
5773
  "aria-hidden": "true",
5774
5774
  children: `${Math.round(t.progress * 100)}%`
5775
- })] }) : /* @__PURE__ */ _(ra, {})
5775
+ })] }) : /* @__PURE__ */ _(ia, {})
5776
5776
  ] });
5777
- }, aa = ({ transferItem: e }) => /* @__PURE__ */ v("p", {
5777
+ }, oa = ({ transferItem: e }) => /* @__PURE__ */ v("p", {
5778
5778
  className: "pkt-fileupload__queue-display__item__title",
5779
- children: [/* @__PURE__ */ _(ta, { children: vi(e) }), e.file && /* @__PURE__ */ v("span", {
5779
+ children: [/* @__PURE__ */ _(na, { children: yi(e) }), e.file && /* @__PURE__ */ v("span", {
5780
5780
  className: "pkt-fileupload__queue-display__item__filesize",
5781
5781
  children: [
5782
5782
  " ",
5783
5783
  "(",
5784
- Zr(e.file.size),
5784
+ Qr(e.file.size),
5785
5785
  ")"
5786
5786
  ]
5787
5787
  })]
5788
- }), oa = ({ transferItem: e, onRemove: t, disabled: n }) => {
5788
+ }), sa = ({ transferItem: e, onRemove: t, disabled: n }) => {
5789
5789
  let r = (e.lastProgress ?? 1) * 100;
5790
5790
  return /* @__PURE__ */ v(g, { children: [
5791
5791
  /* @__PURE__ */ _(L, {
@@ -5793,14 +5793,14 @@ var ea = n({ tail: 5 }), ta = ({ children: e, tail: t }) => {
5793
5793
  name: "alert-error",
5794
5794
  "aria-hidden": "true"
5795
5795
  }),
5796
- /* @__PURE__ */ _(aa, { transferItem: e }),
5797
- /* @__PURE__ */ _(na, {
5796
+ /* @__PURE__ */ _(oa, { transferItem: e }),
5797
+ /* @__PURE__ */ _(ra, {
5798
5798
  onClick: t,
5799
5799
  label: "Fjern",
5800
5800
  ariaLabel: "Fjern fil som feilet under opplasting",
5801
5801
  disabled: n
5802
5802
  }),
5803
- /* @__PURE__ */ _(Hi, {
5803
+ /* @__PURE__ */ _(Ui, {
5804
5804
  valueCurrent: r,
5805
5805
  statusType: "none",
5806
5806
  valueMax: 100,
@@ -5812,14 +5812,14 @@ var ea = n({ tail: 5 }), ta = ({ children: e, tail: t }) => {
5812
5812
  children: e.errorMessage
5813
5813
  })
5814
5814
  ] });
5815
- }, sa = ({ transferItem: e, onRemove: t, disabled: n }) => /* @__PURE__ */ v(g, { children: [
5815
+ }, ca = ({ transferItem: e, onRemove: t, disabled: n }) => /* @__PURE__ */ v(g, { children: [
5816
5816
  /* @__PURE__ */ _(L, {
5817
5817
  className: "pkt-fileupload__queue-display__item__icon pkt-icon--medium",
5818
5818
  name: "alert-error",
5819
5819
  "aria-hidden": "true"
5820
5820
  }),
5821
- /* @__PURE__ */ _(aa, { transferItem: e }),
5822
- /* @__PURE__ */ _(na, {
5821
+ /* @__PURE__ */ _(oa, { transferItem: e }),
5822
+ /* @__PURE__ */ _(ra, {
5823
5823
  onClick: t,
5824
5824
  label: "Fjern",
5825
5825
  ariaLabel: "Fjern fil som feilet under opplasting",
@@ -5829,15 +5829,15 @@ var ea = n({ tail: 5 }), ta = ({ children: e, tail: t }) => {
5829
5829
  className: "pkt-fileupload__queue-display__item__error-message",
5830
5830
  children: e.errorMessage
5831
5831
  })
5832
- ] }), ca = ({ transferItem: e, onRemove: t, disabled: n }) => e.showProgress ? /* @__PURE__ */ _(oa, {
5832
+ ] }), la = ({ transferItem: e, onRemove: t, disabled: n }) => e.showProgress ? /* @__PURE__ */ _(sa, {
5833
5833
  transferItem: e,
5834
5834
  onRemove: t,
5835
5835
  disabled: n
5836
- }) : /* @__PURE__ */ _(sa, {
5836
+ }) : /* @__PURE__ */ _(ca, {
5837
5837
  transferItem: e,
5838
5838
  onRemove: t,
5839
5839
  disabled: n
5840
- }), la = ({ operation: e, context: t }) => {
5840
+ }), ua = ({ operation: e, context: t }) => {
5841
5841
  let n = typeof e.title == "function" ? e.title(t.file) : e.title;
5842
5842
  return n ? /* @__PURE__ */ _("button", {
5843
5843
  type: "button",
@@ -5849,11 +5849,11 @@ var ea = n({ tail: 5 }), ta = ({ children: e, tail: t }) => {
5849
5849
  "aria-label": typeof e.ariaLabel == "function" ? e.ariaLabel(t.file) : e.ariaLabel,
5850
5850
  children: n
5851
5851
  }) : null;
5852
- }, ua = ({ transferItem: e }) => /* @__PURE__ */ v(g, { children: [/* @__PURE__ */ _(L, {
5852
+ }, da = ({ transferItem: e }) => /* @__PURE__ */ v(g, { children: [/* @__PURE__ */ _(L, {
5853
5853
  name: "document-text",
5854
5854
  className: "pkt-fileupload__queue-display__item__icon pkt-icon--medium",
5855
5855
  "aria-hidden": "true"
5856
- }), /* @__PURE__ */ _(aa, { transferItem: e })] }), da = ({ transferItem: e, onPreviewClick: t }) => {
5856
+ }), /* @__PURE__ */ _(oa, { transferItem: e })] }), fa = ({ transferItem: e, onPreviewClick: t }) => {
5857
5857
  let [n, r] = m(null), [i, a] = m(!1), o = e.file;
5858
5858
  c(() => {
5859
5859
  if (a(!1), o.type.startsWith("image/")) {
@@ -5887,10 +5887,10 @@ var ea = n({ tail: 5 }), ta = ({ children: e, tail: t }) => {
5887
5887
  }), s]
5888
5888
  }), /* @__PURE__ */ _("span", {
5889
5889
  className: "pkt-fileupload__queue-display__item__thumbnail__title",
5890
- children: /* @__PURE__ */ _(ta, { children: e.attributes.targetFilename })
5890
+ children: /* @__PURE__ */ _(na, { children: e.attributes.targetFilename })
5891
5891
  })]
5892
5892
  });
5893
- }, fa = ({ isOpen: e, images: t, currentIndex: n, onClose: r, onNavigate: i, modalRef: a }) => {
5893
+ }, pa = ({ isOpen: e, images: t, currentIndex: n, onClose: r, onNavigate: i, modalRef: a }) => {
5894
5894
  let [o, s] = m(null), [l, u] = m(!1), d = t[n], f = t.length > 1;
5895
5895
  return c(() => {
5896
5896
  if (u(!1), d && d.file.type.startsWith("image/")) {
@@ -5902,7 +5902,7 @@ var ea = n({ tail: 5 }), ta = ({ children: e, tail: t }) => {
5902
5902
  if (!e) return;
5903
5903
  let t = (e) => {
5904
5904
  if (e.key === "Tab") {
5905
- pi(e, a.current);
5905
+ mi(e, a.current);
5906
5906
  return;
5907
5907
  }
5908
5908
  switch (e.key) {
@@ -5921,7 +5921,7 @@ var ea = n({ tail: 5 }), ta = ({ children: e, tail: t }) => {
5921
5921
  i,
5922
5922
  r,
5923
5923
  a
5924
- ]), d ? /* @__PURE__ */ _($i, {
5924
+ ]), d ? /* @__PURE__ */ _(ea, {
5925
5925
  ref: a,
5926
5926
  headingText: d.attributes.targetFilename,
5927
5927
  closeOnBackdropClick: !0,
@@ -5971,7 +5971,7 @@ var ea = n({ tail: 5 }), ta = ({ children: e, tail: t }) => {
5971
5971
  ]
5972
5972
  })
5973
5973
  }) : null;
5974
- }, pa = ({ operation: e, transferItem: t, inputName: n, disabled: r, activatedOperation: i, onActivate: a, onClose: o, buildAttributeAccessors: s }) => {
5974
+ }, ma = ({ operation: e, transferItem: t, inputName: n, disabled: r, activatedOperation: i, onActivate: a, onClose: o, buildAttributeAccessors: s }) => {
5975
5975
  let c = s(t.fileId);
5976
5976
  return {
5977
5977
  file: t,
@@ -5983,29 +5983,29 @@ var ea = n({ tail: 5 }), ta = ({ children: e, tail: t }) => {
5983
5983
  getAttribute: c.getAttribute,
5984
5984
  setAttribute: c.setAttribute
5985
5985
  };
5986
- }, ma = (e, t) => e.map((e) => ({
5986
+ }, ha = (e, t) => e.map((e) => ({
5987
5987
  operation: e,
5988
- context: pa({
5988
+ context: ma({
5989
5989
  operation: e,
5990
5990
  ...t
5991
5991
  })
5992
- })), ha = (e) => {
5993
- let t = ma(e.operations, e);
5992
+ })), ga = (e) => {
5993
+ let t = ha(e.operations, e);
5994
5994
  return /* @__PURE__ */ _("div", {
5995
5995
  className: "pkt-fileupload__queue-display__item__actions",
5996
- children: t.filter(({ operation: t }) => t.id !== e.activatedOperation?.id).map(({ operation: e, context: t }) => /* @__PURE__ */ _(la, {
5996
+ children: t.filter(({ operation: t }) => t.id !== e.activatedOperation?.id).map(({ operation: e, context: t }) => /* @__PURE__ */ _(ua, {
5997
5997
  operation: e,
5998
5998
  context: t
5999
5999
  }, e.id))
6000
6000
  });
6001
- }, ga = (e) => {
6002
- let t = ma(e.operations, e);
6001
+ }, _a = (e) => {
6002
+ let t = ha(e.operations, e);
6003
6003
  return /* @__PURE__ */ _(g, { children: t.filter(({ operation: e }) => e.renderContent).map(({ operation: e, context: t }) => /* @__PURE__ */ _("div", {
6004
6004
  className: "pkt-fileupload__queue-display__item__operation-content",
6005
6005
  children: e.renderContent(t)
6006
6006
  }, e.id)) });
6007
- }, _a = (e) => {
6008
- let { transferItem: t, activatedOperation: n, operations: r, ItemRenderer: i, onPreviewClick: a } = e, o = n ? pa({
6007
+ }, va = (e) => {
6008
+ let { transferItem: t, activatedOperation: n, operations: r, ItemRenderer: i, onPreviewClick: a } = e, o = n ? ma({
6009
6009
  operation: n,
6010
6010
  ...e
6011
6011
  }) : void 0, s = n?.renderInlineUI || n?.renderExtendedUI ? [] : r;
@@ -6021,43 +6021,43 @@ var ea = n({ tail: 5 }), ta = ({ children: e, tail: t }) => {
6021
6021
  queueItemOperations: r,
6022
6022
  onPreviewClick: a
6023
6023
  }),
6024
- s.length > 0 && /* @__PURE__ */ _(ha, {
6024
+ s.length > 0 && /* @__PURE__ */ _(ga, {
6025
6025
  ...e,
6026
6026
  operations: s
6027
6027
  }),
6028
- /* @__PURE__ */ _(ga, { ...e }),
6028
+ /* @__PURE__ */ _(_a, { ...e }),
6029
6029
  n?.renderExtendedUI && o && /* @__PURE__ */ _("div", {
6030
6030
  className: "pkt-fileupload__queue-display__item__expanded-operation-ui",
6031
6031
  children: n.renderExtendedUI(o)
6032
6032
  })
6033
6033
  ] });
6034
- }, va = (e) => {
6035
- let { transferItem: t, enableImagePreview: n, onCancelTransfer: r, onOpenPreview: i, disabled: a } = e, o = ai(t.progress), s = n && t.progress === "done" && ii(t);
6034
+ }, ya = (e) => {
6035
+ let { transferItem: t, enableImagePreview: n, onCancelTransfer: r, onOpenPreview: i, disabled: a } = e, o = oi(t.progress), s = n && t.progress === "done" && ai(t);
6036
6036
  switch (o) {
6037
- case "in-progress": return /* @__PURE__ */ _(ia, {
6037
+ case "in-progress": return /* @__PURE__ */ _(aa, {
6038
6038
  transferItem: t,
6039
6039
  cancelTransfer: () => r(t.fileId),
6040
6040
  disabled: a
6041
6041
  });
6042
- case "error": return /* @__PURE__ */ _(ca, {
6042
+ case "error": return /* @__PURE__ */ _(la, {
6043
6043
  transferItem: t,
6044
6044
  onRemove: () => r(t.fileId),
6045
6045
  disabled: a
6046
6046
  });
6047
- case "idle": return /* @__PURE__ */ _(_a, {
6047
+ case "idle": return /* @__PURE__ */ _(va, {
6048
6048
  ...e,
6049
6049
  onPreviewClick: s ? () => i(t.fileId) : void 0
6050
6050
  });
6051
6051
  }
6052
- }, ya = (e, t, n) => f(() => oi(e, t, n), [
6052
+ }, ba = (e, t, n) => f(() => si(e, t, n), [
6053
6053
  e,
6054
6054
  t,
6055
6055
  n
6056
- ]), ba = (e, t) => f(() => t ? e.filter((e) => e.progress === "done" && ii(e)) : [], [e, t]), xa = ({ files: e, cancelTransfer: t, transfers: n = [], queueItemOperations: r = [], ItemRenderer: i = ua, truncateTail: a, enableImagePreview: o = !1, uploadStrategy: s = "form", disabled: c = !1, inputName: l, buildAttributeAccessors: u }) => {
6057
- let d = ya(e, n, s), f = ba(d, o), p = Bi(r), m = zi(f);
6056
+ ]), xa = (e, t) => f(() => t ? e.filter((e) => e.progress === "done" && ai(e)) : [], [e, t]), Sa = ({ files: e, cancelTransfer: t, transfers: n = [], queueItemOperations: r = [], ItemRenderer: i = da, truncateTail: a, enableImagePreview: o = !1, uploadStrategy: s = "form", disabled: c = !1, inputName: l, buildAttributeAccessors: u }) => {
6057
+ let d = ba(e, n, s), f = xa(d, o), p = Vi(r), m = Bi(f);
6058
6058
  return /* @__PURE__ */ v(g, { children: [/* @__PURE__ */ _("ul", {
6059
6059
  className: "pkt-fileupload__queue-display",
6060
- children: /* @__PURE__ */ _(ea.Provider, {
6060
+ children: /* @__PURE__ */ _(ta.Provider, {
6061
6061
  value: { tail: a },
6062
6062
  children: d.map((e) => {
6063
6063
  let n = {
@@ -6075,10 +6075,10 @@ var ea = n({ tail: 5 }), ta = ({ children: e, tail: t }) => {
6075
6075
  "pkt-fileupload__queue-display__item--in-progress": typeof e.progress == "number",
6076
6076
  [`pkt-fileupload__queue-display__item--${e.progress}`]: typeof e.progress == "string"
6077
6077
  }),
6078
- children: [r.filter((e) => e.renderHidden).map((t) => /* @__PURE__ */ _("span", { children: t.renderHidden(pa({
6078
+ children: [r.filter((e) => e.renderHidden).map((t) => /* @__PURE__ */ _("span", { children: t.renderHidden(ma({
6079
6079
  operation: t,
6080
6080
  ...n
6081
- })) }, `${t.id}-${e.fileId}`)), /* @__PURE__ */ _(va, {
6081
+ })) }, `${t.id}-${e.fileId}`)), /* @__PURE__ */ _(ya, {
6082
6082
  ...n,
6083
6083
  ItemRenderer: i,
6084
6084
  enableImagePreview: o,
@@ -6088,7 +6088,7 @@ var ea = n({ tail: 5 }), ta = ({ children: e, tail: t }) => {
6088
6088
  }, e.fileId);
6089
6089
  })
6090
6090
  })
6091
- }), o && f.length > 0 && /* @__PURE__ */ _(fa, {
6091
+ }), o && f.length > 0 && /* @__PURE__ */ _(pa, {
6092
6092
  modalRef: m.modalRef,
6093
6093
  isOpen: m.isOpen,
6094
6094
  images: f,
@@ -6096,10 +6096,10 @@ var ea = n({ tail: 5 }), ta = ({ children: e, tail: t }) => {
6096
6096
  onClose: m.close,
6097
6097
  onNavigate: m.navigate
6098
6098
  })] });
6099
- }, Sa = {
6100
- filename: ua,
6101
- thumbnail: da
6102
- }, Ca = i(({ value: e, defaultValue: t, id: n, multiple: r = !1, uploadStrategy: i = "form", addCommentsEnabled: a = !1, renameFilesEnabled: s = !1, truncateTail: d = 4, onFilesChanged: h, onFileUploadRequested: g, extraOperations: y = [], itemRenderer: b = Sa.filename, fullwidth: x = !1, allowedFormats: S, formatErrorMessage: C, maxFileSize: w, sizeErrorMessage: T, onFileValidation: E, onFileValidate: D, errorMessage: O, hasError: k = !1, disabled: A = !1, label: j, helptext: N, helptextDropdown: P, helptextDropdownButton: ee, optionalTag: te, optionalText: ne, requiredTag: F, requiredText: re, tagText: ie, required: ae = !1, enableImagePreview: oe = !1, "aria-describedby": se, "aria-invalid": I, strings: L, ...R }, ce) => {
6099
+ }, Ca = {
6100
+ filename: da,
6101
+ thumbnail: fa
6102
+ }, wa = i(({ value: e, defaultValue: t, id: n, multiple: r = !1, uploadStrategy: i = "form", addCommentsEnabled: a = !1, renameFilesEnabled: s = !1, truncateTail: d = 4, onFilesChanged: h, onFileUploadRequested: g, extraOperations: y = [], itemRenderer: b = Ca.filename, fullwidth: x = !1, allowedFormats: S, formatErrorMessage: C, maxFileSize: w, sizeErrorMessage: T, onFileValidation: E, onFileValidate: D, errorMessage: O, hasError: k = !1, disabled: A = !1, label: j, helptext: N, helptextDropdown: P, helptextDropdownButton: ee, optionalTag: te, optionalText: ne, requiredTag: F, requiredText: re, tagText: ie, required: ae = !1, enableImagePreview: oe = !1, "aria-describedby": se, "aria-invalid": I, strings: L, ...R }, ce) => {
6103
6103
  let z = l(), ue = n ?? `pkt-fileupload-${z}`, de = p(null);
6104
6104
  u(ce, () => de.current, []);
6105
6105
  let V = "transfers" in R ? R.transfers : void 0, H = ve(["fileupload"], L).fileupload, [U, W] = m(null), [G, K] = m("");
@@ -6113,7 +6113,7 @@ var ea = n({ tail: 5 }), ta = ({ children: e, tail: t }) => {
6113
6113
  N ? `${ue}-helptext` : void 0,
6114
6114
  pe
6115
6115
  ].filter(Boolean).join(" ") || void 0, he = q || I === !0 || I === "true", J = o((e) => {
6116
- let t = ri(e, {
6116
+ let t = ii(e, {
6117
6117
  allowedFormats: S,
6118
6118
  maxFileSize: w,
6119
6119
  formatErrorMessage: C,
@@ -6139,13 +6139,13 @@ var ea = n({ tail: 5 }), ta = ({ children: e, tail: t }) => {
6139
6139
  ]);
6140
6140
  e !== void 0 && t !== void 0 && console.warn("PktFileupload: Både value og defaultValue er angitt. Komponenten kan være enten 'controlled' eller 'uncontrolled', ikke begge deler. Bruk kun én av dem. Se https://react.dev/reference/react-dom/components/input#controlling-an-input-with-a-state-variable"), e !== void 0 && h === void 0 && console.warn("PktFileupload: value-prop er angitt uten onFilesChanged-callback. Når en komponent er 'controlled', må endringer håndteres via en callback. Vennligst legg til onFilesChanged-callback for å håndtere endringer i fil-listen. Se https://react.dev/reference/react-dom/components/input#controlling-an-input-with-a-state-variable");
6141
6141
  let ge = e !== void 0, [Y, _e] = m(() => t ?? []), X = ge ? e : Y;
6142
- Vi(de, {
6142
+ Hi(de, {
6143
6143
  uploadStrategy: i,
6144
6144
  required: ae,
6145
6145
  currentFileCount: X.length,
6146
6146
  onMissingFiles: o(() => W(H.requiredMissing), [H])
6147
6147
  });
6148
- let be = typeof b == "string" ? Sa[b] : b, Z = b === "thumbnail", Q = typeof R.accept == "string" ? R.accept.trim() : void 0, xe = f(() => ti(Q, S) || void 0, [Q, S]), Se = s && !Z, Ce = a && !Z, we = o((e) => {
6148
+ let be = typeof b == "string" ? Ca[b] : b, Z = b === "thumbnail", Q = typeof R.accept == "string" ? R.accept.trim() : void 0, xe = f(() => ni(Q, S) || void 0, [Q, S]), Se = s && !Z, Ce = a && !Z, we = o((e) => {
6149
6149
  for (let t of e) {
6150
6150
  let e = J(t.file);
6151
6151
  if (e) {
@@ -6185,15 +6185,15 @@ var ea = n({ tail: 5 }), ta = ({ children: e, tail: t }) => {
6185
6185
  X,
6186
6186
  R,
6187
6187
  ge
6188
- ]), { buildAttributeAccessors: De } = Ri(X, Te), Oe = f(() => {
6188
+ ]), { buildAttributeAccessors: De } = zi(X, Te), Oe = f(() => {
6189
6189
  let e = [];
6190
- return Se && e.push(Li), Ce && e.push(Mi), e.push(...y), e.push(Ni(Ee)), e;
6190
+ return Se && e.push(Ri), Ce && e.push(Ni), e.push(...y), e.push(Pi(Ee)), e;
6191
6191
  }, [
6192
6192
  Se,
6193
6193
  Ce,
6194
6194
  y,
6195
6195
  Ee
6196
- ]), { totalCount: ke, uploadedCount: Ae, failedCount: je } = f(() => gi(X, V), [X, V]), Me = le(ke, H.fileLabelOne, H.fileLabelOther), $ = /* @__PURE__ */ _("div", {
6196
+ ]), { totalCount: ke, uploadedCount: Ae, failedCount: je } = f(() => _i(X, V), [X, V]), Me = le(ke, H.fileLabelOne, H.fileLabelOther), $ = /* @__PURE__ */ _("div", {
6197
6197
  className: (0, M.default)("pkt-fileupload", {
6198
6198
  "pkt-fileupload--full-width": x,
6199
6199
  "pkt-fileupload--error": q,
@@ -6201,7 +6201,7 @@ var ea = n({ tail: 5 }), ta = ({ children: e, tail: t }) => {
6201
6201
  }),
6202
6202
  "aria-disabled": A,
6203
6203
  ...A ? { inert: !0 } : {},
6204
- children: /* @__PURE__ */ v(Si.Provider, {
6204
+ children: /* @__PURE__ */ v(Ci.Provider, {
6205
6205
  value: {
6206
6206
  name: R.name || "",
6207
6207
  multiple: !!r,
@@ -6228,7 +6228,7 @@ var ea = n({ tail: 5 }), ta = ({ children: e, tail: t }) => {
6228
6228
  label: Me
6229
6229
  })
6230
6230
  }),
6231
- /* @__PURE__ */ _(Ci, {
6231
+ /* @__PURE__ */ _(wi, {
6232
6232
  id: ue,
6233
6233
  name: R.name || "",
6234
6234
  form: R.form,
@@ -6237,7 +6237,7 @@ var ea = n({ tail: 5 }), ta = ({ children: e, tail: t }) => {
6237
6237
  multiple: r,
6238
6238
  uploadStrategy: i,
6239
6239
  ref: de,
6240
- accept: Z ? _i : xe,
6240
+ accept: Z ? vi : xe,
6241
6241
  isThumbnailView: Z,
6242
6242
  disabled: A,
6243
6243
  required: ae && i === "form",
@@ -6256,7 +6256,7 @@ var ea = n({ tail: 5 }), ta = ({ children: e, tail: t }) => {
6256
6256
  className: "pkt-fileupload__error-alert",
6257
6257
  children: fe
6258
6258
  }),
6259
- X.length > 0 && /* @__PURE__ */ _(xa, {
6259
+ X.length > 0 && /* @__PURE__ */ _(Sa, {
6260
6260
  files: X,
6261
6261
  cancelTransfer: Ee,
6262
6262
  truncateTail: d,
@@ -6293,10 +6293,10 @@ var ea = n({ tail: 5 }), ta = ({ children: e, tail: t }) => {
6293
6293
  })
6294
6294
  });
6295
6295
  });
6296
- Ca.displayName = "PktFileUpload";
6296
+ wa.displayName = "PktFileUpload";
6297
6297
  //#endregion
6298
6298
  //#region ../../shared-utils/header-footer/icon-map.ts
6299
- var wa = {
6299
+ var Ta = {
6300
6300
  automat: "parking-meter",
6301
6301
  bike: "bicycle",
6302
6302
  corona: "virus",
@@ -6321,10 +6321,10 @@ var wa = {
6321
6321
  treatment: "processing",
6322
6322
  "warning-triangle": "alert-warning"
6323
6323
  };
6324
- function Ta(e) {
6325
- return e && (wa[e] ?? e);
6324
+ function Ea(e) {
6325
+ return e && (Ta[e] ?? e);
6326
6326
  }
6327
- var Ea = {
6327
+ var Da = {
6328
6328
  "facebook.com": "facebook",
6329
6329
  "fb.com": "facebook",
6330
6330
  "instagram.com": "instagram",
@@ -6332,36 +6332,36 @@ var Ea = {
6332
6332
  "x.com": "x",
6333
6333
  "github.com": "github"
6334
6334
  };
6335
- function Da(e) {
6335
+ function Oa(e) {
6336
6336
  return e.toLowerCase().replace(/^(?:www|m)\./, "");
6337
6337
  }
6338
- function Oa(e, t) {
6338
+ function ka(e, t) {
6339
6339
  if (e) try {
6340
- let t = Ea[Da(new URL(e).hostname)];
6340
+ let t = Da[Oa(new URL(e).hostname)];
6341
6341
  if (t) return t;
6342
6342
  } catch {}
6343
6343
  if (t) {
6344
6344
  let e = t.trim().toLowerCase().replace(/\s+/g, "-");
6345
6345
  if (e) {
6346
- let t = Ta(e);
6346
+ let t = Ea(e);
6347
6347
  if (t) return t;
6348
6348
  }
6349
6349
  }
6350
6350
  }
6351
6351
  //#endregion
6352
6352
  //#region ../../shared-utils/header-footer/select-megamenu.ts
6353
- var ka = "nb-NO";
6354
- function Aa(e, t = ka) {
6355
- if (e) return e[t] ?? e[ka];
6353
+ var Aa = "nb-NO";
6354
+ function ja(e, t = Aa) {
6355
+ if (e) return e[t] ?? e[Aa];
6356
6356
  }
6357
6357
  //#endregion
6358
6358
  //#region ../../shared-utils/header-footer/external-domain.ts
6359
- var ja = "oslo.kommune.no", Ma = /\.(?:co|com|org|net|gov|edu|ac|kommune)\.[a-z]{2}$/i;
6360
- function Na(e) {
6359
+ var Ma = "oslo.kommune.no", Na = /\.(?:co|com|org|net|gov|edu|ac|kommune)\.[a-z]{2}$/i;
6360
+ function Pa(e) {
6361
6361
  let t = e.toLowerCase().replace(/\.$/, ""), n = t.split(".");
6362
- return n.length <= 2 ? t : n.slice(Ma.test(t) ? -3 : -2).join(".");
6362
+ return n.length <= 2 ? t : n.slice(Na.test(t) ? -3 : -2).join(".");
6363
6363
  }
6364
- function Pa(e) {
6364
+ function Fa(e) {
6365
6365
  if (!e) return;
6366
6366
  let t;
6367
6367
  try {
@@ -6369,9 +6369,9 @@ function Pa(e) {
6369
6369
  } catch {
6370
6370
  return;
6371
6371
  }
6372
- if (t.protocol === "http:" || t.protocol === "https:") return Na(t.hostname.toLowerCase().replace(/\.$/, ""));
6372
+ if (t.protocol === "http:" || t.protocol === "https:") return Pa(t.hostname.toLowerCase().replace(/\.$/, ""));
6373
6373
  }
6374
- function Fa(e, t = ja) {
6374
+ function Ia(e, t = Ma) {
6375
6375
  if (!e) return;
6376
6376
  let n;
6377
6377
  try {
@@ -6381,21 +6381,21 @@ function Fa(e, t = ja) {
6381
6381
  }
6382
6382
  if (n.protocol !== "http:" && n.protocol !== "https:") return;
6383
6383
  let r = n.hostname.toLowerCase().replace(/\.$/, ""), i = t.toLowerCase();
6384
- if (!(r === i || r.endsWith(`.${i}`))) return Na(r);
6384
+ if (!(r === i || r.endsWith(`.${i}`))) return Pa(r);
6385
6385
  }
6386
6386
  //#endregion
6387
6387
  //#region ../../shared-utils/header-footer/fetch-header-footer-data.ts
6388
- var Ia = /* @__PURE__ */ new Map();
6389
- async function La(e) {
6388
+ var La = /* @__PURE__ */ new Map();
6389
+ async function Ra(e) {
6390
6390
  let t = await fetch(e);
6391
6391
  if (!t.ok) throw Error(`pkt-header-menu: failed to fetch ${e} (HTTP ${t.status})`);
6392
6392
  let n = await t.json();
6393
6393
  if (!n || typeof n != "object") throw Error(`pkt-header-menu: ${e} returned a non-object payload`);
6394
6394
  return n;
6395
6395
  }
6396
- function Ra(e, t) {
6397
- return t ? t.aborted ? Promise.reject(za(t.reason)) : new Promise((n, r) => {
6398
- let i = () => r(za(t.reason));
6396
+ function za(e, t) {
6397
+ return t ? t.aborted ? Promise.reject(Ba(t.reason)) : new Promise((n, r) => {
6398
+ let i = () => r(Ba(t.reason));
6399
6399
  t.addEventListener("abort", i, { once: !0 }), e.then((e) => {
6400
6400
  t.removeEventListener("abort", i), n(e);
6401
6401
  }, (e) => {
@@ -6403,22 +6403,22 @@ function Ra(e, t) {
6403
6403
  });
6404
6404
  }) : e;
6405
6405
  }
6406
- function za(e) {
6406
+ function Ba(e) {
6407
6407
  return e instanceof Error ? e : new DOMException("The operation was aborted.", "AbortError");
6408
6408
  }
6409
- async function Ba(e = Rn, t) {
6410
- let n = Ia.get(e);
6411
- return n || (n = La(e), n.catch(() => Ia.delete(e)), Ia.set(e, n)), Ra(n, t);
6409
+ async function Va(e = Rn, t) {
6410
+ let n = La.get(e);
6411
+ return n || (n = Ra(e), n.catch(() => La.delete(e)), La.set(e, n)), za(n, t);
6412
6412
  }
6413
6413
  //#endregion
6414
6414
  //#region src/components/footer/FooterGlobal.tsx
6415
- var Va = "#cb-trigger";
6416
- function Ha({ data: e, dataUrl: t, locale: n = "nb-NO", skipGlobal: r = !1, onDataError: i }) {
6415
+ var Ha = "#cb-trigger";
6416
+ function Ua({ data: e, dataUrl: t, locale: n = "nb-NO", skipGlobal: r = !1, onDataError: i }) {
6417
6417
  let [a, o] = m(), s = p(i);
6418
6418
  s.current = i, c(() => {
6419
6419
  if (e || r) return;
6420
6420
  let n = new AbortController();
6421
- return Ba(t, n.signal).then((e) => {
6421
+ return Va(t, n.signal).then((e) => {
6422
6422
  n.signal.aborted || o(e);
6423
6423
  }).catch((e) => {
6424
6424
  e.name !== "AbortError" && (console.warn("Failed to fetch header/footer data:", e), s.current?.(e));
@@ -6430,20 +6430,20 @@ function Ha({ data: e, dataUrl: t, locale: n = "nb-NO", skipGlobal: r = !1, onDa
6430
6430
  ]);
6431
6431
  let l = e ?? a;
6432
6432
  return f(() => {
6433
- if (!r) return Aa(l, n)?.footer;
6433
+ if (!r) return ja(l, n)?.footer;
6434
6434
  }, [
6435
6435
  l,
6436
6436
  n,
6437
6437
  r
6438
6438
  ]);
6439
6439
  }
6440
- var Ua = ({ link: e, includeConsent: t, consent: n }) => {
6441
- if (e.url === Va) return t ? /* @__PURE__ */ _("li", { children: /* @__PURE__ */ _(Pr, {
6440
+ var Wa = ({ link: e, includeConsent: t, consent: n }) => {
6441
+ if (e.url === Ha) return t ? /* @__PURE__ */ _("li", { children: /* @__PURE__ */ _(Fr, {
6442
6442
  triggerType: "footerlink",
6443
6443
  triggerText: e.text,
6444
6444
  ...n
6445
6445
  }) }) : null;
6446
- let r = Fa(e.url);
6446
+ let r = Ia(e.url);
6447
6447
  return /* @__PURE__ */ _("li", { children: /* @__PURE__ */ v("a", {
6448
6448
  href: e.url,
6449
6449
  children: [e.text, r && /* @__PURE__ */ v("span", {
@@ -6455,15 +6455,15 @@ var Ua = ({ link: e, includeConsent: t, consent: n }) => {
6455
6455
  ]
6456
6456
  })]
6457
6457
  }) });
6458
- }, Wa = ({ section: e, includeConsent: t, consent: n }) => /* @__PURE__ */ v("section", { children: [/* @__PURE__ */ _("h2", { children: e.title }), /* @__PURE__ */ _("ul", {
6458
+ }, Ga = ({ section: e, includeConsent: t, consent: n }) => /* @__PURE__ */ v("section", { children: [/* @__PURE__ */ _("h2", { children: e.title }), /* @__PURE__ */ _("ul", {
6459
6459
  className: "pkt-footer__link-list",
6460
- children: e.links.map((e) => /* @__PURE__ */ _(Ua, {
6460
+ children: e.links.map((e) => /* @__PURE__ */ _(Wa, {
6461
6461
  link: e,
6462
6462
  includeConsent: t,
6463
6463
  consent: n
6464
6464
  }, `${e.url}|${e.text}`))
6465
- })] }), Ga = ({ entry: e }) => {
6466
- let t = Oa(e.url, e.text);
6465
+ })] }), Ka = ({ entry: e }) => {
6466
+ let t = ka(e.url, e.text);
6467
6467
  return t ? /* @__PURE__ */ _("li", { children: /* @__PURE__ */ _("a", {
6468
6468
  className: "pkt-footer__some-link",
6469
6469
  href: e.url,
@@ -6476,7 +6476,7 @@ var Ua = ({ link: e, includeConsent: t, consent: n }) => {
6476
6476
  href: e.url,
6477
6477
  children: e.text
6478
6478
  }) });
6479
- }, Ka = ({ footer: e, includeConsent: t = !1, consent: n = {} }) => {
6479
+ }, qa = ({ footer: e, includeConsent: t = !1, consent: n = {} }) => {
6480
6480
  let r = e.links?.length > 0, i = e.some?.length > 0;
6481
6481
  return /* @__PURE__ */ _("div", {
6482
6482
  className: "pkt-footer__band pkt-footer__band--global",
@@ -6484,7 +6484,7 @@ var Ua = ({ link: e, includeConsent: t, consent: n }) => {
6484
6484
  className: "pkt-footer__inner",
6485
6485
  children: /* @__PURE__ */ v("div", {
6486
6486
  className: "pkt-footer__sections",
6487
- children: [e.sections.map((e) => /* @__PURE__ */ _(Wa, {
6487
+ children: [e.sections.map((e) => /* @__PURE__ */ _(Ga, {
6488
6488
  section: e,
6489
6489
  includeConsent: t,
6490
6490
  consent: n
@@ -6498,14 +6498,14 @@ var Ua = ({ link: e, includeConsent: t, consent: n }) => {
6498
6498
  }) }, `${e.url}|${e.text}`))
6499
6499
  }), i && /* @__PURE__ */ _("ul", {
6500
6500
  className: "pkt-footer__some",
6501
- children: e.some.map((e) => /* @__PURE__ */ _(Ga, { entry: e }, `${e.url}|${e.text}`))
6501
+ children: e.some.map((e) => /* @__PURE__ */ _(Ka, { entry: e }, `${e.url}|${e.text}`))
6502
6502
  })]
6503
6503
  })]
6504
6504
  })
6505
6505
  })
6506
6506
  });
6507
- }, qa = ({ link: e, openLinksInNewTab: t }) => {
6508
- let n = e.openInNewTab || t, r = e.external ? Pa(e.href) : void 0;
6507
+ }, Ja = ({ link: e, openLinksInNewTab: t }) => {
6508
+ let n = e.openInNewTab || t, r = e.external ? Fa(e.href) : void 0;
6509
6509
  return /* @__PURE__ */ _("li", { children: /* @__PURE__ */ v("a", {
6510
6510
  href: e.href,
6511
6511
  target: n ? "_blank" : "_self",
@@ -6519,17 +6519,17 @@ var Ua = ({ link: e, includeConsent: t, consent: n }) => {
6519
6519
  ]
6520
6520
  })]
6521
6521
  }) });
6522
- }, Ja = ({ column: e, openLinksInNewTab: t }) => /* @__PURE__ */ v("section", { children: [
6522
+ }, Ya = ({ column: e, openLinksInNewTab: t }) => /* @__PURE__ */ v("section", { children: [
6523
6523
  /* @__PURE__ */ _("h2", { children: e.title }),
6524
6524
  e.text && /* @__PURE__ */ _("p", { children: e.text }),
6525
6525
  !!e.links?.length && /* @__PURE__ */ _("ul", {
6526
6526
  className: "pkt-footer__link-list",
6527
- children: e.links.map((e) => /* @__PURE__ */ _(qa, {
6527
+ children: e.links.map((e) => /* @__PURE__ */ _(Ja, {
6528
6528
  link: e,
6529
6529
  openLinksInNewTab: t
6530
6530
  }, `${e.href}|${e.text}`))
6531
6531
  })
6532
- ] }), Ya = ({ columns: e, columnOne: t, columnTwo: n, personvernOgInfoLink: r, tilgjengelighetLink: i, socialLinks: a, skipGlobal: o = !1, data: s, dataUrl: l, locale: u = "nb-NO", openLinksInNewTab: d = !1, includeConsent: p = !1, hotjarId: m = null, googleAnalyticsId: h = null, devMode: g = !1, cookieDomain: y = null, cookieSecure: b = null, cookieExpiryDays: x = null, onToggleConsent: S, onDataError: C, className: w, ...T }) => {
6532
+ ] }), Xa = ({ columns: e, columnOne: t, columnTwo: n, personvernOgInfoLink: r, tilgjengelighetLink: i, socialLinks: a, skipGlobal: o = !1, data: s, dataUrl: l, locale: u = "nb-NO", openLinksInNewTab: d = !1, includeConsent: p = !1, hotjarId: m = null, googleAnalyticsId: h = null, devMode: g = !1, cookieDomain: y = null, cookieSecure: b = null, cookieExpiryDays: x = null, onToggleConsent: S, onDataError: C, className: w, ...T }) => {
6533
6533
  c(() => {
6534
6534
  (t || n) && console.warn("PktFooter: The \"columnOne\"/\"columnTwo\" props are deprecated and will be removed in a future version. Please use \"columns\" instead.");
6535
6535
  }, [t, n]), c(() => {
@@ -6537,7 +6537,7 @@ var Ua = ({ link: e, includeConsent: t, consent: n }) => {
6537
6537
  }, [r, i]), c(() => {
6538
6538
  a && console.warn("PktFooter: The \"socialLinks\" prop is deprecated and will be removed in a future version — the social media links now come from the global footer.");
6539
6539
  }, [a]);
6540
- let E = Ha({
6540
+ let E = Ua({
6541
6541
  data: s,
6542
6542
  dataUrl: l,
6543
6543
  locale: u,
@@ -6580,14 +6580,14 @@ var Ua = ({ link: e, includeConsent: t, consent: n }) => {
6580
6580
  children: [
6581
6581
  D.length > 0 && /* @__PURE__ */ _("div", {
6582
6582
  className: "pkt-footer__sections",
6583
- children: D.map((e) => /* @__PURE__ */ _(Ja, {
6583
+ children: D.map((e) => /* @__PURE__ */ _(Ya, {
6584
6584
  column: e,
6585
6585
  openLinksInNewTab: d
6586
6586
  }, e.title))
6587
6587
  }),
6588
6588
  k && /* @__PURE__ */ _("div", {
6589
6589
  className: "pkt-footer__consent",
6590
- children: /* @__PURE__ */ _(Pr, {
6590
+ children: /* @__PURE__ */ _(Fr, {
6591
6591
  triggerType: "footerlink",
6592
6592
  ...O
6593
6593
  })
@@ -6620,14 +6620,14 @@ var Ua = ({ link: e, includeConsent: t, consent: n }) => {
6620
6620
  })
6621
6621
  ]
6622
6622
  })
6623
- }), E && /* @__PURE__ */ _(Ka, {
6623
+ }), E && /* @__PURE__ */ _(qa, {
6624
6624
  footer: E,
6625
6625
  includeConsent: p,
6626
6626
  consent: O
6627
6627
  })]
6628
6628
  });
6629
- }, Xa = ({ link: e, openLinksInNewTab: t }) => {
6630
- let n = e.openInNewTab || t, r = e.external ? Pa(e.href) : void 0;
6629
+ }, Za = ({ link: e, openLinksInNewTab: t }) => {
6630
+ let n = e.openInNewTab || t, r = e.external ? Fa(e.href) : void 0;
6631
6631
  return /* @__PURE__ */ v("a", {
6632
6632
  className: "pkt-footer-simple__link",
6633
6633
  href: e.href,
@@ -6645,11 +6645,11 @@ var Ua = ({ link: e, includeConsent: t, consent: n }) => {
6645
6645
  ]
6646
6646
  })] })]
6647
6647
  });
6648
- }, Za = ({ links: e, personvernOgInfoLink: t, tilgjengelighetLink: n, skipGlobal: r = !1, data: i, dataUrl: a, locale: o = "nb-NO", openLinksInNewTab: s = !1, includeConsent: l = !1, hotjarId: u = null, googleAnalyticsId: d = null, devMode: p = !1, cookieDomain: m = null, cookieSecure: h = null, cookieExpiryDays: g = null, onToggleConsent: y, onDataError: b, className: x, ...S }) => {
6648
+ }, Qa = ({ links: e, personvernOgInfoLink: t, tilgjengelighetLink: n, skipGlobal: r = !1, data: i, dataUrl: a, locale: o = "nb-NO", openLinksInNewTab: s = !1, includeConsent: l = !1, hotjarId: u = null, googleAnalyticsId: d = null, devMode: p = !1, cookieDomain: m = null, cookieSecure: h = null, cookieExpiryDays: g = null, onToggleConsent: y, onDataError: b, className: x, ...S }) => {
6649
6649
  c(() => {
6650
6650
  (t || n) && console.warn("PktFooterSimple: The \"personvernOgInfoLink\"/\"tilgjengelighetLink\" props are deprecated — the links now come from the global footer. Overridden values are rendered in the secondary footer.");
6651
6651
  }, [t, n]);
6652
- let C = Ha({
6652
+ let C = Ua({
6653
6653
  data: i,
6654
6654
  dataUrl: a,
6655
6655
  locale: o,
@@ -6686,22 +6686,22 @@ var Ua = ({ link: e, includeConsent: t, consent: n }) => {
6686
6686
  className: "pkt-footer__inner pkt-footer__inner--compact",
6687
6687
  children: /* @__PURE__ */ v("ul", {
6688
6688
  className: "pkt-footer-simple__list",
6689
- children: [w.map((e) => /* @__PURE__ */ _("li", { children: /* @__PURE__ */ _(Xa, {
6689
+ children: [w.map((e) => /* @__PURE__ */ _("li", { children: /* @__PURE__ */ _(Za, {
6690
6690
  link: e,
6691
6691
  openLinksInNewTab: s
6692
- }) }, `${e.href}|${e.text}`)), E && /* @__PURE__ */ _("li", { children: /* @__PURE__ */ _(Pr, {
6692
+ }) }, `${e.href}|${e.text}`)), E && /* @__PURE__ */ _("li", { children: /* @__PURE__ */ _(Fr, {
6693
6693
  triggerType: "footerlink",
6694
6694
  ...T
6695
6695
  }) })]
6696
6696
  })
6697
6697
  })
6698
- }), C && /* @__PURE__ */ _(Ka, {
6698
+ }), C && /* @__PURE__ */ _(qa, {
6699
6699
  footer: C,
6700
6700
  includeConsent: l,
6701
6701
  consent: T
6702
6702
  })]
6703
6703
  });
6704
- }, Qa = (e, t) => {
6704
+ }, $a = (e, t) => {
6705
6705
  let [n, r] = m(() => typeof window > "u" ? t ?? 0 : t ?? window.innerWidth);
6706
6706
  return c(() => {
6707
6707
  let t = e.current;
@@ -6722,10 +6722,10 @@ var Ua = ({ link: e, includeConsent: t, consent: n }) => {
6722
6722
  };
6723
6723
  //#endregion
6724
6724
  //#region src/hooks/useHeaderChrome.ts
6725
- function $a({ forwardedRef: e, mobileBreakpoint: t, tabletBreakpoint: n, position: r, scrollBehavior: i, pauseScrollHide: a = !1 }) {
6725
+ function eo({ forwardedRef: e, mobileBreakpoint: t, tabletBreakpoint: n, position: r, scrollBehavior: i, pauseScrollHide: a = !1 }) {
6726
6726
  let s = p(null), l = o((t) => {
6727
6727
  s.current = t, typeof e == "function" ? e(t) : e && (e.current = t);
6728
- }, [e]), u = Qa(s), d = u < t, f = u < n, h = r === "fixed", g = r === "sticky", [_, v] = m(!1), y = p(0), b = i === "hide";
6728
+ }, [e]), u = $a(s), d = u < t, f = u < n, h = r === "fixed", g = r === "sticky", [_, v] = m(!1), y = p(0), b = i === "hide";
6729
6729
  c(() => {
6730
6730
  let e = () => {
6731
6731
  if (!b || a) return;
@@ -6755,16 +6755,16 @@ function $a({ forwardedRef: e, mobileBreakpoint: t, tabletBreakpoint: n, positio
6755
6755
  }
6756
6756
  //#endregion
6757
6757
  //#region src/hooks/useScrollLock.ts
6758
- function eo(e) {
6759
- let t = p(Zi());
6758
+ function to(e) {
6759
+ let t = p(Qi());
6760
6760
  c(() => {
6761
6761
  let n = t.current;
6762
- return Qi(n, e), () => Qi(n, !1);
6762
+ return $i(n, e), () => $i(n, !1);
6763
6763
  }, [e]);
6764
6764
  }
6765
6765
  //#endregion
6766
6766
  //#region src/components/header-menu/HeaderMenu.tsx
6767
- var to = ({ dataUrl: e = Rn, data: t, locale: n = "nb-NO", open: r = !1, mobileBreakpoint: i = 768, className: a, onDataLoaded: s, onDataError: l, ref: u, ...d }) => {
6767
+ var no = ({ dataUrl: e = Rn, data: t, locale: n = "nb-NO", open: r = !1, mobileBreakpoint: i = 768, className: a, onDataLoaded: s, onDataError: l, ref: u, ...d }) => {
6768
6768
  let [h, y] = m("loading"), [b, x] = m(void 0), S = t ? "ready" : h, C = p(s), w = p(l);
6769
6769
  c(() => {
6770
6770
  C.current = s;
@@ -6773,19 +6773,19 @@ var to = ({ dataUrl: e = Rn, data: t, locale: n = "nb-NO", open: r = !1, mobileB
6773
6773
  }, [l]);
6774
6774
  let T = p(null), E = o((e) => {
6775
6775
  T.current = e, typeof u == "function" ? u(e) : u && (u.current = e);
6776
- }, [u]), D = Qa(T) < i;
6776
+ }, [u]), D = $a(T) < i;
6777
6777
  c(() => {
6778
6778
  t && C.current?.(t);
6779
6779
  }, [t]), c(() => {
6780
6780
  if (t) return;
6781
6781
  let n = new AbortController();
6782
- return Ba(e, n.signal).then((e) => {
6782
+ return Va(e, n.signal).then((e) => {
6783
6783
  n.signal.aborted || (x(e), y("ready"), C.current?.(e));
6784
6784
  }).catch((e) => {
6785
6785
  e.name !== "AbortError" && (y("error"), w.current?.(e));
6786
6786
  }), () => n.abort();
6787
6787
  }, [t, e]);
6788
- let O = t ?? b, k = f(() => Aa(O, n), [O, n]), A = [
6788
+ let O = t ?? b, k = f(() => ja(O, n), [O, n]), A = [
6789
6789
  "pkt-header-menu",
6790
6790
  r && "pkt-header-menu--open",
6791
6791
  a
@@ -6817,28 +6817,28 @@ var to = ({ dataUrl: e = Rn, data: t, locale: n = "nb-NO", open: r = !1, mobileB
6817
6817
  className: A,
6818
6818
  "aria-label": N,
6819
6819
  children: [
6820
- D ? /* @__PURE__ */ _(ro, {
6820
+ D ? /* @__PURE__ */ _(io, {
6821
6821
  services: j.services,
6822
6822
  sections: j.sections
6823
6823
  }) : /* @__PURE__ */ v(g, { children: [
6824
- /* @__PURE__ */ _(io, { services: j.services }),
6825
- /* @__PURE__ */ _(ao, {
6824
+ /* @__PURE__ */ _(ao, { services: j.services }),
6825
+ /* @__PURE__ */ _(oo, {
6826
6826
  buttons: j.buttons,
6827
6827
  mobile: !1
6828
6828
  }),
6829
- /* @__PURE__ */ _(oo, { sections: j.sections })
6829
+ /* @__PURE__ */ _(so, { sections: j.sections })
6830
6830
  ] }),
6831
- /* @__PURE__ */ _(ao, {
6831
+ /* @__PURE__ */ _(oo, {
6832
6832
  buttons: j.buttons,
6833
6833
  mobile: !0
6834
6834
  }),
6835
- /* @__PURE__ */ _(co, {
6835
+ /* @__PURE__ */ _(lo, {
6836
6836
  links: j.links,
6837
6837
  some: j.some
6838
6838
  })
6839
6839
  ]
6840
6840
  });
6841
- }, no = ({ services: e }) => /* @__PURE__ */ _("ul", {
6841
+ }, ro = ({ services: e }) => /* @__PURE__ */ _("ul", {
6842
6842
  className: "pkt-header-menu__services-list",
6843
6843
  children: e.links.map((e) => /* @__PURE__ */ _("li", {
6844
6844
  className: "pkt-header-menu__service",
@@ -6847,7 +6847,7 @@ var to = ({ dataUrl: e = Rn, data: t, locale: n = "nb-NO", open: r = !1, mobileB
6847
6847
  href: e.url,
6848
6848
  children: [/* @__PURE__ */ _(L, {
6849
6849
  className: "pkt-header-menu__service-icon",
6850
- name: Ta(e.icon),
6850
+ name: Ea(e.icon),
6851
6851
  "aria-hidden": "true"
6852
6852
  }), /* @__PURE__ */ _("span", {
6853
6853
  className: "pkt-header-menu__service-text",
@@ -6855,7 +6855,7 @@ var to = ({ dataUrl: e = Rn, data: t, locale: n = "nb-NO", open: r = !1, mobileB
6855
6855
  })]
6856
6856
  })
6857
6857
  }, e.url))
6858
- }), ro = ({ services: e, sections: t }) => /* @__PURE__ */ _("div", {
6858
+ }), io = ({ services: e, sections: t }) => /* @__PURE__ */ _("div", {
6859
6859
  className: "pkt-header-menu__sections",
6860
6860
  children: /* @__PURE__ */ v(j, {
6861
6861
  className: "pkt-header-menu__sections-inner",
@@ -6866,22 +6866,22 @@ var to = ({ dataUrl: e = Rn, data: t, locale: n = "nb-NO", open: r = !1, mobileB
6866
6866
  skin: "plus-minus",
6867
6867
  id: "pkt-header-menu-services",
6868
6868
  title: e.title,
6869
- children: /* @__PURE__ */ _(no, { services: e })
6869
+ children: /* @__PURE__ */ _(ro, { services: e })
6870
6870
  }), t.map((e, t) => /* @__PURE__ */ _(R, {
6871
6871
  className: "pkt-header-menu__section",
6872
6872
  skin: "plus-minus",
6873
6873
  id: `pkt-header-menu-section-${t}`,
6874
6874
  title: e.title,
6875
- children: /* @__PURE__ */ _(so, { links: e.links })
6875
+ children: /* @__PURE__ */ _(co, { links: e.links })
6876
6876
  }, e.title))]
6877
6877
  })
6878
- }), io = ({ services: e }) => /* @__PURE__ */ v("div", {
6878
+ }), ao = ({ services: e }) => /* @__PURE__ */ v("div", {
6879
6879
  className: "pkt-header-menu__services",
6880
6880
  children: [/* @__PURE__ */ _("h2", {
6881
6881
  className: "pkt-header-menu__services-title",
6882
6882
  children: e.title
6883
- }), /* @__PURE__ */ _(no, { services: e })]
6884
- }), ao = ({ buttons: e, mobile: t }) => {
6883
+ }), /* @__PURE__ */ _(ro, { services: e })]
6884
+ }), oo = ({ buttons: e, mobile: t }) => {
6885
6885
  if (!e || e.length === 0) return null;
6886
6886
  let n = ["pkt-header-menu__buttons", t && "pkt-header-menu__buttons--mobile"].filter(Boolean).join(" ");
6887
6887
  return /* @__PURE__ */ _("div", {
@@ -6891,7 +6891,7 @@ var to = ({ dataUrl: e = Rn, data: t, locale: n = "nb-NO", open: r = !1, mobileB
6891
6891
  href: e.url,
6892
6892
  children: [/* @__PURE__ */ _(L, {
6893
6893
  className: "pkt-btn__icon",
6894
- name: e.iconName ? Ta(e.iconName) : "user",
6894
+ name: e.iconName ? Ea(e.iconName) : "user",
6895
6895
  "aria-hidden": "true"
6896
6896
  }), /* @__PURE__ */ _("span", {
6897
6897
  className: "pkt-btn__text",
@@ -6899,7 +6899,7 @@ var to = ({ dataUrl: e = Rn, data: t, locale: n = "nb-NO", open: r = !1, mobileB
6899
6899
  })]
6900
6900
  }, e.url))
6901
6901
  });
6902
- }, oo = ({ sections: e }) => !e || e.length === 0 ? null : /* @__PURE__ */ _("div", {
6902
+ }, so = ({ sections: e }) => !e || e.length === 0 ? null : /* @__PURE__ */ _("div", {
6903
6903
  className: "pkt-header-menu__sections",
6904
6904
  children: /* @__PURE__ */ _("div", {
6905
6905
  className: "pkt-header-menu__sections-inner",
@@ -6908,17 +6908,17 @@ var to = ({ dataUrl: e = Rn, data: t, locale: n = "nb-NO", open: r = !1, mobileB
6908
6908
  children: [/* @__PURE__ */ _("h2", {
6909
6909
  className: "pkt-header-menu__section-title",
6910
6910
  children: e.title
6911
- }), /* @__PURE__ */ _(so, { links: e.links })]
6911
+ }), /* @__PURE__ */ _(co, { links: e.links })]
6912
6912
  }, e.title))
6913
6913
  })
6914
- }), so = ({ links: e }) => /* @__PURE__ */ _("ul", {
6914
+ }), co = ({ links: e }) => /* @__PURE__ */ _("ul", {
6915
6915
  className: "pkt-header-menu__section-list",
6916
6916
  children: e.map((e) => /* @__PURE__ */ _("li", { children: /* @__PURE__ */ _("a", {
6917
6917
  className: "pkt-header-menu__section-link",
6918
6918
  href: e.url,
6919
6919
  children: e.text
6920
6920
  }) }, e.url))
6921
- }), co = ({ links: e, some: t }) => {
6921
+ }), lo = ({ links: e, some: t }) => {
6922
6922
  let n = e && e.length > 0, r = t && t.length > 0;
6923
6923
  return !n && !r ? null : /* @__PURE__ */ v("div", {
6924
6924
  className: "pkt-header-menu__footer",
@@ -6931,11 +6931,11 @@ var to = ({ dataUrl: e = Rn, data: t, locale: n = "nb-NO", open: r = !1, mobileB
6931
6931
  }) }, e.url))
6932
6932
  }), r && /* @__PURE__ */ _("ul", {
6933
6933
  className: "pkt-header-menu__footer-list pkt-header-menu__footer-list--social",
6934
- children: t.map((e) => /* @__PURE__ */ _(lo, { entry: e }, e.url))
6934
+ children: t.map((e) => /* @__PURE__ */ _(uo, { entry: e }, e.url))
6935
6935
  })]
6936
6936
  });
6937
- }, lo = ({ entry: e }) => {
6938
- let t = Oa(e.url, e.text);
6937
+ }, uo = ({ entry: e }) => {
6938
+ let t = ka(e.url, e.text);
6939
6939
  return /* @__PURE__ */ _("li", { children: /* @__PURE__ */ _("a", {
6940
6940
  className: "pkt-header-menu__social-link",
6941
6941
  href: e.url,
@@ -6945,7 +6945,7 @@ var to = ({ dataUrl: e = Rn, data: t, locale: n = "nb-NO", open: r = !1, mobileB
6945
6945
  "aria-hidden": "true"
6946
6946
  }) : /* @__PURE__ */ _("span", { children: e.text })
6947
6947
  }) });
6948
- }, uo = ({ href: e, iconName: t, className: n, iconPosition: r, external: i, target: a, renderLink: o, children: s, ...c }) => {
6948
+ }, fo = ({ href: e, iconName: t, className: n, iconPosition: r, external: i, target: a, renderLink: o, children: s, ...c }) => {
6949
6949
  let l = {
6950
6950
  "pkt-link": !0,
6951
6951
  "pkt-link--icon-left": !!t && r === "left" || !!(t && !r),
@@ -6971,10 +6971,10 @@ var to = ({ dataUrl: e = Rn, data: t, locale: n = "nb-NO", open: r = !1, mobileB
6971
6971
  }
6972
6972
  });
6973
6973
  };
6974
- uo.displayName = "PktLink";
6974
+ fo.displayName = "PktLink";
6975
6975
  //#endregion
6976
6976
  //#region src/components/headerUserMenu/UserMenu.tsx
6977
- var fo = (e) => typeof e.target == "string" ? {
6977
+ var po = (e) => typeof e.target == "string" ? {
6978
6978
  title: e.title,
6979
6979
  iconName: e.iconName,
6980
6980
  href: e.target
@@ -6982,7 +6982,7 @@ var fo = (e) => typeof e.target == "string" ? {
6982
6982
  title: e.title,
6983
6983
  iconName: e.iconName,
6984
6984
  onClick: e.target
6985
- }, po = ({ item: e, className: t }) => "href" in e ? /* @__PURE__ */ _(uo, {
6985
+ }, mo = ({ item: e, className: t }) => "href" in e ? /* @__PURE__ */ _(fo, {
6986
6986
  iconName: e.iconName,
6987
6987
  href: e.href,
6988
6988
  className: (0, M.default)("pkt-user-menu__link", t),
@@ -6998,14 +6998,14 @@ var fo = (e) => typeof e.target == "string" ? {
6998
6998
  className: "pkt-link__icon",
6999
6999
  "aria-hidden": "true"
7000
7000
  }), e.title]
7001
- }), mo = ({ links: e }) => /* @__PURE__ */ _("ul", {
7001
+ }), ho = ({ links: e }) => /* @__PURE__ */ _("ul", {
7002
7002
  className: "pkt-user-menu__sublist",
7003
7003
  children: e.map((e, t) => /* @__PURE__ */ _("li", {
7004
7004
  className: "pkt-user-menu__subitem",
7005
- children: /* @__PURE__ */ _(po, { item: e })
7005
+ children: /* @__PURE__ */ _(mo, { item: e })
7006
7006
  }, t))
7007
- }), ho = i(({ strings: e, user: t, formattedLastLoggedIn: n, representing: r, userMenu: i, canChangeRepresentation: a, changeRepresentation: o, logoutOnClick: s }, c) => {
7008
- let l = ve(["header"], e).header, u = i?.map(fo);
7007
+ }), go = i(({ strings: e, user: t, formattedLastLoggedIn: n, representing: r, userMenu: i, canChangeRepresentation: a, changeRepresentation: o, logoutOnClick: s }, c) => {
7008
+ let l = ve(["header"], e).header, u = i?.map(po);
7009
7009
  return /* @__PURE__ */ _("nav", {
7010
7010
  className: "pkt-user-menu",
7011
7011
  ref: c,
@@ -7037,7 +7037,7 @@ var fo = (e) => typeof e.target == "string" ? {
7037
7037
  }),
7038
7038
  u && u.length > 0 && /* @__PURE__ */ _("li", {
7039
7039
  className: "pkt-user-menu__item",
7040
- children: /* @__PURE__ */ _(mo, { links: u })
7040
+ children: /* @__PURE__ */ _(ho, { links: u })
7041
7041
  }),
7042
7042
  r && /* @__PURE__ */ v("li", {
7043
7043
  className: "pkt-user-menu__item",
@@ -7059,7 +7059,7 @@ var fo = (e) => typeof e.target == "string" ? {
7059
7059
  className: "pkt-user-menu__sublist mt-size-16",
7060
7060
  children: /* @__PURE__ */ _("li", {
7061
7061
  className: "pkt-user-menu__subitem",
7062
- children: /* @__PURE__ */ _(po, { item: {
7062
+ children: /* @__PURE__ */ _(mo, { item: {
7063
7063
  title: l.changeRepresentation,
7064
7064
  iconName: "cogwheel",
7065
7065
  onClick: o
@@ -7074,7 +7074,7 @@ var fo = (e) => typeof e.target == "string" ? {
7074
7074
  className: "pkt-user-menu__sublist",
7075
7075
  children: /* @__PURE__ */ _("li", {
7076
7076
  className: "pkt-user-menu__subitem",
7077
- children: /* @__PURE__ */ _(po, { item: {
7077
+ children: /* @__PURE__ */ _(mo, { item: {
7078
7078
  title: l.changeRepresentation,
7079
7079
  iconName: "cogwheel",
7080
7080
  onClick: o
@@ -7084,7 +7084,7 @@ var fo = (e) => typeof e.target == "string" ? {
7084
7084
  }),
7085
7085
  s && /* @__PURE__ */ _("li", {
7086
7086
  className: "pkt-user-menu__item",
7087
- children: /* @__PURE__ */ _(po, { item: {
7087
+ children: /* @__PURE__ */ _(mo, { item: {
7088
7088
  title: l.logOut,
7089
7089
  iconName: "exit",
7090
7090
  onClick: s
@@ -7094,10 +7094,10 @@ var fo = (e) => typeof e.target == "string" ? {
7094
7094
  })
7095
7095
  });
7096
7096
  });
7097
- ho.displayName = "PktHeaderUserMenu";
7097
+ go.displayName = "PktHeaderUserMenu";
7098
7098
  //#endregion
7099
7099
  //#region src/components/searchinput/SearchInput.tsx
7100
- var go = i(({ appearance: e = "local", inputSize: t = "medium", disabled: n = !1, fullwidth: r = !1, id: i, label: a, name: o, placeholder: s, suggestions: c, value: l = "", action: u, method: d, onChange: p, onSearch: m, onSuggestionClick: h, strings: y, ...b }, x) => {
7100
+ var _o = i(({ appearance: e = "local", inputSize: t = "medium", disabled: n = !1, fullwidth: r = !1, id: i, label: a, name: o, placeholder: s, suggestions: c, value: l = "", action: u, method: d, onChange: p, onSearch: m, onSuggestionClick: h, strings: y, ...b }, x) => {
7101
7101
  let S = ve(["searchinput"], y), C = s ?? S.searchinput.placeholder, w = (e, t) => {
7102
7102
  e ? e() : h && h(t);
7103
7103
  }, T = (e) => {
@@ -7187,19 +7187,19 @@ var go = i(({ appearance: e = "local", inputSize: t = "medium", disabled: n = !1
7187
7187
  })
7188
7188
  ] }));
7189
7189
  });
7190
- go.displayName = "PktSearchInput";
7190
+ _o.displayName = "PktSearchInput";
7191
7191
  //#endregion
7192
7192
  //#region src/components/header/HeaderGlobal.tsx
7193
- var _o = "https://punkt-cdn.oslo.kommune.no/latest/logos/";
7194
- typeof window < "u" && (window.pktLogoPath = window.pktLogoPath || _o);
7195
- var vo = "pkt-header-global-menu", yo = "pkt-header-global-menu-toggle", bo = "pkt-header-global-search-panel", xo = "pkt-header-global-search-toggle", So = i(({ className: e, "data-mode": t, dataUrl: n, data: r, locale: i = "nb-NO", logoLink: a = zn, logoClick: s, logoPath: l = typeof window < "u" ? window.pktLogoPath : _o, showSearch: u = !0, searchPlaceholder: h, onSearch: y, showContact: b = !0, user: x, userMenu: S, representing: C, canChangeRepresentation: w = !1, changeRepresentation: T, logOutButtonPlacement: E = "none", logOut: D, position: O = "fixed", scrollBehavior: k = "hide", mobileBreakpoint: A = 768, tabletBreakpoint: j = 1024, onDataLoaded: N, onDataError: P, strings: ee }, te) => {
7193
+ var vo = "https://punkt-cdn.oslo.kommune.no/latest/logos/";
7194
+ typeof window < "u" && (window.pktLogoPath = window.pktLogoPath || vo);
7195
+ var yo = "pkt-header-global-menu", bo = "pkt-header-global-menu-toggle", xo = "pkt-header-global-search-panel", So = "pkt-header-global-search-toggle", Co = i(({ className: e, "data-mode": t, dataUrl: n, data: r, locale: i = "nb-NO", logoLink: a = zn, logoClick: s, logoPath: l = typeof window < "u" ? window.pktLogoPath : vo, showSearch: u = !0, searchPlaceholder: h, onSearch: y, showContact: b = !0, user: x, userMenu: S, representing: C, canChangeRepresentation: w = !1, changeRepresentation: T, logOutButtonPlacement: E = "none", logOut: D, position: O = "fixed", scrollBehavior: k = "hide", mobileBreakpoint: A = 768, tabletBreakpoint: j = 1024, onDataLoaded: N, onDataError: P, strings: ee }, te) => {
7196
7196
  let ne = k === "hide", [F, re] = m("none"), [ie, ae] = m(void 0), [oe, se] = m(!1), I = p(N), R = p(P);
7197
7197
  c(() => {
7198
7198
  I.current = N;
7199
7199
  }, [N]), c(() => {
7200
7200
  R.current = P;
7201
7201
  }, [P]);
7202
- let { setRef: ce, isMobile: z, isTablet: B, isFixed: le, isSticky: ue, hidden: de, captureFocus: V, flagRestoreFocus: H, restoreFocus: U } = $a({
7202
+ let { setRef: ce, isMobile: z, isTablet: B, isFixed: le, isSticky: ue, hidden: de, captureFocus: V, flagRestoreFocus: H, restoreFocus: U } = eo({
7203
7203
  forwardedRef: te,
7204
7204
  mobileBreakpoint: A,
7205
7205
  tabletBreakpoint: j,
@@ -7207,13 +7207,13 @@ var vo = "pkt-header-global-menu", yo = "pkt-header-global-menu-toggle", bo = "p
7207
7207
  scrollBehavior: k,
7208
7208
  pauseScrollHide: F !== "none"
7209
7209
  });
7210
- eo(F === "menu" || F === "search");
7210
+ to(F === "menu" || F === "search");
7211
7211
  let W = p(null), G = o((e) => {
7212
7212
  W.current = e, ce(e);
7213
7213
  }, [ce]);
7214
7214
  d(() => {
7215
7215
  if (F !== "menu" && F !== "search") return;
7216
- let e = document.getElementById(F === "menu" ? vo : bo), t = W.current?.getBoundingClientRect();
7216
+ let e = document.getElementById(F === "menu" ? yo : xo), t = W.current?.getBoundingClientRect();
7217
7217
  !e || !t || (e.style.setProperty("--pkt-header-global-top", `${t.top}px`), e.style.setProperty("--pkt-header-global-left", `${t.left}px`), e.style.setProperty("--pkt-header-global-width", `${t.width}px`));
7218
7218
  }, [
7219
7219
  F,
@@ -7224,17 +7224,17 @@ var vo = "pkt-header-global-menu", yo = "pkt-header-global-menu-toggle", bo = "p
7224
7224
  }, [r]), c(() => {
7225
7225
  if (r) return;
7226
7226
  let e = new AbortController();
7227
- return Ba(n, e.signal).then((t) => {
7227
+ return Va(n, e.signal).then((t) => {
7228
7228
  e.signal.aborted || (ae(t), se(!1), I.current?.(t));
7229
7229
  }).catch((e) => {
7230
7230
  e.name !== "AbortError" && (se(!0), R.current?.(e));
7231
7231
  }), () => e.abort();
7232
7232
  }, [r, n]);
7233
- let K = r ?? ie, fe = f(() => Aa(K, i), [K, i]);
7233
+ let K = r ?? ie, fe = f(() => ja(K, i), [K, i]);
7234
7234
  c(() => {
7235
7235
  let e = (e) => {
7236
7236
  let t = e.target;
7237
- F === "user" && !t.closest(".pkt-header-global__user-container") && !t.closest(".pkt-header-global__user-menu") && re("none"), F === "menu" && !t.closest(".pkt-header-menu") && !t.closest(`#${yo}`) && re("none"), F === "search" && !t.closest(".pkt-header-global__search-panel-inner") && !t.closest(`#${xo}`) && re("none");
7237
+ F === "user" && !t.closest(".pkt-header-global__user-container") && !t.closest(".pkt-header-global__user-menu") && re("none"), F === "menu" && !t.closest(".pkt-header-menu") && !t.closest(`#${bo}`) && re("none"), F === "search" && !t.closest(".pkt-header-global__search-panel-inner") && !t.closest(`#${So}`) && re("none");
7238
7238
  }, t = (e) => {
7239
7239
  e.key === "Escape" && F !== "none" && (e.preventDefault(), H(), re("none"));
7240
7240
  };
@@ -7248,13 +7248,13 @@ var vo = "pkt-header-global-menu", yo = "pkt-header-global-menu-toggle", bo = "p
7248
7248
  H
7249
7249
  ]), c(() => {
7250
7250
  if (F !== "menu" && F !== "search") return;
7251
- let e = F === "menu" ? vo : bo, t = F === "menu" ? yo : xo, n = () => document.getElementById(e), r = () => document.getElementById(t), i = (e) => {
7251
+ let e = F === "menu" ? yo : xo, t = F === "menu" ? bo : So, n = () => document.getElementById(e), r = () => document.getElementById(t), i = (e) => {
7252
7252
  re("none"), (e.querySelector("button") ?? e).focus();
7253
7253
  }, a = (e) => {
7254
7254
  if (e.key !== "Tab") return;
7255
7255
  let t = n(), a = r();
7256
7256
  if (!t || !a) return;
7257
- let o = di(t), s = fi();
7257
+ let o = fi(t), s = pi();
7258
7258
  if (s && a.contains(s)) {
7259
7259
  !e.shiftKey && o.length > 0 && (e.preventDefault(), o[0].focus());
7260
7260
  return;
@@ -7317,7 +7317,7 @@ var vo = "pkt-header-global-menu", yo = "pkt-header-global-menu-toggle", bo = "p
7317
7317
  children: [
7318
7318
  !Q && xe && J && /* @__PURE__ */ _("div", {
7319
7319
  className: "pkt-header-global__search",
7320
- children: /* @__PURE__ */ _(go, {
7320
+ children: /* @__PURE__ */ _(_o, {
7321
7321
  appearance: "global",
7322
7322
  inputSize: B ? "small" : "medium",
7323
7323
  fullwidth: !0,
@@ -7332,7 +7332,7 @@ var vo = "pkt-header-global-menu", yo = "pkt-header-global-menu-toggle", bo = "p
7332
7332
  })
7333
7333
  }),
7334
7334
  Q && xe && /* @__PURE__ */ _(Y, {
7335
- id: xo,
7335
+ id: So,
7336
7336
  className: "pkt-header-global__search-toggle",
7337
7337
  skin: "primary",
7338
7338
  color: Z ? void 0 : "yellow",
@@ -7341,12 +7341,12 @@ var vo = "pkt-header-global-menu", yo = "pkt-header-global-menu-toggle", bo = "p
7341
7341
  size: z ? "small" : "medium",
7342
7342
  state: Z ? "active" : "normal",
7343
7343
  "aria-expanded": Z,
7344
- "aria-controls": bo,
7344
+ "aria-controls": xo,
7345
7345
  onClick: () => pe("search"),
7346
7346
  children: X
7347
7347
  }),
7348
7348
  /* @__PURE__ */ _(Y, {
7349
- id: yo,
7349
+ id: bo,
7350
7350
  className: "pkt-header-global__menu-toggle",
7351
7351
  skin: Q ? "tertiary" : "secondary",
7352
7352
  variant: Q ? "icon-only" : "icon-right",
@@ -7354,7 +7354,7 @@ var vo = "pkt-header-global-menu", yo = "pkt-header-global-menu-toggle", bo = "p
7354
7354
  size: B ? "small" : "medium",
7355
7355
  state: ye ? "active" : "normal",
7356
7356
  "aria-expanded": ye,
7357
- "aria-controls": vo,
7357
+ "aria-controls": yo,
7358
7358
  disabled: Ce,
7359
7359
  onClick: () => pe("menu"),
7360
7360
  children: _e
@@ -7391,7 +7391,7 @@ var vo = "pkt-header-global-menu", yo = "pkt-header-global-menu-toggle", bo = "p
7391
7391
  })]
7392
7392
  }), be && /* @__PURE__ */ _("div", {
7393
7393
  className: "pkt-header-global__user-menu is-open",
7394
- children: /* @__PURE__ */ _(ho, {
7394
+ children: /* @__PURE__ */ _(go, {
7395
7395
  strings: ee,
7396
7396
  user: x,
7397
7397
  formattedLastLoggedIn: q,
@@ -7407,8 +7407,8 @@ var vo = "pkt-header-global-menu", yo = "pkt-header-global-menu-toggle", bo = "p
7407
7407
  ]
7408
7408
  }), Te = ye && /* @__PURE__ */ _("div", {
7409
7409
  className: (0, M.default)("pkt-header-global__menu", z && "pkt-header-global__menu--mobile", B && !z && "pkt-header-global__menu--tablet"),
7410
- id: vo,
7411
- children: fe ? /* @__PURE__ */ _(to, {
7410
+ id: yo,
7411
+ children: fe ? /* @__PURE__ */ _(no, {
7412
7412
  data: K,
7413
7413
  locale: i,
7414
7414
  open: !0,
@@ -7422,10 +7422,10 @@ var vo = "pkt-header-global-menu", yo = "pkt-header-global-menu-toggle", bo = "p
7422
7422
  })
7423
7423
  }), Ee = Z && xe && J && /* @__PURE__ */ _("div", {
7424
7424
  className: (0, M.default)("pkt-header-global__search-panel", z && "pkt-header-global__search-panel--mobile", B && !z && "pkt-header-global__search-panel--tablet"),
7425
- id: bo,
7425
+ id: xo,
7426
7426
  children: /* @__PURE__ */ _("div", {
7427
7427
  className: "pkt-header-global__search-panel-inner",
7428
- children: /* @__PURE__ */ _(go, {
7428
+ children: /* @__PURE__ */ _(_o, {
7429
7429
  appearance: "global",
7430
7430
  fullwidth: !0,
7431
7431
  id: Se,
@@ -7454,10 +7454,10 @@ var vo = "pkt-header-global-menu", yo = "pkt-header-global-menu-toggle", bo = "p
7454
7454
  Te
7455
7455
  ] });
7456
7456
  });
7457
- So.displayName = "PktHeaderGlobal";
7457
+ Co.displayName = "PktHeaderGlobal";
7458
7458
  //#endregion
7459
7459
  //#region src/components/textinput/Textinput.tsx
7460
- var Co = i(({ id: e, ariaDescribedby: t, ariaLabelledby: n, autocomplete: r = "off", counter: i, hasFieldset: a, counterMaxLength: o, className: s, disabled: l = !1, errorMessage: u, hasError: d = !1, helptext: f, helptextDropdown: p, helptextDropdownButton: h, iconNameRight: g, inline: y = !1, fullwidth: b = !1, label: x, name: S, optionalTag: C = !1, optionalText: w, requiredTag: T = !1, requiredText: E, tagText: D = null, placeholder: O, prefix: k, suffix: A, type: j = "text", useWrapper: M = !0, omitSearchIcon: N = !1, value: P, minLength: ee, maxLength: te, min: ne, max: F, step: re, size: ie, readonly: ae, required: oe, dataTestid: se, onChange: I, skipForwardTestid: R = !1, inputSize: ce = "medium", strings: z, ...B }, le) => {
7460
+ var wo = i(({ id: e, ariaDescribedby: t, ariaLabelledby: n, autocomplete: r = "off", counter: i, hasFieldset: a, counterMaxLength: o, className: s, disabled: l = !1, errorMessage: u, hasError: d = !1, helptext: f, helptextDropdown: p, helptextDropdownButton: h, iconNameRight: g, inline: y = !1, fullwidth: b = !1, label: x, name: S, optionalTag: C = !1, optionalText: w, requiredTag: T = !1, requiredText: E, tagText: D = null, placeholder: O, prefix: k, suffix: A, type: j = "text", useWrapper: M = !0, omitSearchIcon: N = !1, value: P, minLength: ee, maxLength: te, min: ne, max: F, step: re, size: ie, readonly: ae, required: oe, dataTestid: se, onChange: I, skipForwardTestid: R = !1, inputSize: ce = "medium", strings: z, ...B }, le) => {
7461
7461
  let ue = i ?? (o ?? 0) > 0, de = [s, "pkt-textinput"].filter(Boolean).join(" "), V = j === "search" && !g && !N, H = j === "date" && P ? P.slice(0, 10) : P, [U, W] = m(P?.length || 0), G = Jn(e), K = `${G}`, fe = `${K}-label`, q = n || fe, pe = (e) => {
7462
7462
  ue && W(e.currentTarget?.value?.length || 0), I && I(e);
7463
7463
  };
@@ -7554,12 +7554,12 @@ var Co = i(({ id: e, ariaDescribedby: t, ariaLabelledby: n, autocomplete: r = "o
7554
7554
  })
7555
7555
  });
7556
7556
  });
7557
- Co.displayName = "PktTextinput";
7557
+ wo.displayName = "PktTextinput";
7558
7558
  //#endregion
7559
7559
  //#region src/components/header/HeaderService.tsx
7560
- var wo = "https://punkt-cdn.oslo.kommune.no/latest/logos/";
7561
- typeof window < "u" && (window.pktLogoPath = window.pktLogoPath || wo);
7562
- var To = i(({ mobileBreakpoint: e = 768, tabletBreakpoint: t = 1280, children: n, className: r, compact: i = !1, "data-mode": a, logOutButtonPlacement: s = "none", logOut: l, openedMenu: u, showSearch: d = !1, onSearch: h, onSearchChange: y, searchValue: b, searchPlaceholder: x, representing: S, serviceLink: C, serviceClick: w, serviceName: T, user: E, userMenu: D, userMenuFooter: O, userOptions: k, canChangeRepresentation: A = !1, changeRepresentation: j, hideLogo: N = !1, logoLink: P = zn, logoClick: ee, logoPath: te = typeof window < "u" ? window.pktLogoPath : wo, position: ne = "fixed", scrollBehavior: F = "hide", slotMenuVariant: re = "icon-only", slotMenuText: ie, strings: ae }, oe) => {
7560
+ var To = "https://punkt-cdn.oslo.kommune.no/latest/logos/";
7561
+ typeof window < "u" && (window.pktLogoPath = window.pktLogoPath || To);
7562
+ var Eo = i(({ mobileBreakpoint: e = 768, tabletBreakpoint: t = 1280, children: n, className: r, compact: i = !1, "data-mode": a, logOutButtonPlacement: s = "none", logOut: l, openedMenu: u, showSearch: d = !1, onSearch: h, onSearchChange: y, searchValue: b, searchPlaceholder: x, representing: S, serviceLink: C, serviceClick: w, serviceName: T, user: E, userMenu: D, userMenuFooter: O, userOptions: k, canChangeRepresentation: A = !1, changeRepresentation: j, hideLogo: N = !1, logoLink: P = zn, logoClick: ee, logoPath: te = typeof window < "u" ? window.pktLogoPath : To, position: ne = "fixed", scrollBehavior: F = "hide", slotMenuVariant: re = "icon-only", slotMenuText: ie, strings: ae }, oe) => {
7563
7563
  let se = F === "hide";
7564
7564
  c(() => {
7565
7565
  O && console.warn("PktHeaderService: The \"userMenuFooter\" prop is deprecated and will be removed in a future version. Please use \"userMenu\" instead.");
@@ -7580,14 +7580,14 @@ var To = i(({ mobileBreakpoint: e = 768, tabletBreakpoint: t = 1280, children: n
7580
7580
  c(() => {
7581
7581
  u !== void 0 && B(u);
7582
7582
  }, [u]);
7583
- let [le, ue] = m(!1), [de, V] = m(!1), H = p(null), U = p(null), W = p(null), G = p(null), K = p(null), { setRef: fe, isMobile: q, isTablet: pe, isFixed: me, isSticky: he, hidden: J, captureFocus: ge, flagRestoreFocus: _e, restoreFocus: X } = $a({
7583
+ let [le, ue] = m(!1), [de, V] = m(!1), H = p(null), U = p(null), W = p(null), G = p(null), K = p(null), { setRef: fe, isMobile: q, isTablet: pe, isFixed: me, isSticky: he, hidden: J, captureFocus: ge, flagRestoreFocus: _e, restoreFocus: X } = eo({
7584
7584
  forwardedRef: oe,
7585
7585
  mobileBreakpoint: e,
7586
7586
  tabletBreakpoint: t,
7587
7587
  position: ne,
7588
7588
  scrollBehavior: F
7589
7589
  });
7590
- eo((me || he) && q && z !== "none");
7590
+ to((me || he) && q && z !== "none");
7591
7591
  let ye = o((e, t) => {
7592
7592
  let n = e.relatedTarget, r;
7593
7593
  switch (t) {
@@ -7669,7 +7669,7 @@ var To = i(({ mobileBreakpoint: e = 768, tabletBreakpoint: t = 1280, children: n
7669
7669
  })), T && /* @__PURE__ */ _("span", {
7670
7670
  className: "pkt-header-service__service-name",
7671
7671
  translate: "no",
7672
- children: C ? /* @__PURE__ */ _(uo, {
7672
+ children: C ? /* @__PURE__ */ _(fo, {
7673
7673
  href: C,
7674
7674
  className: "pkt-header-service__service-link ",
7675
7675
  children: T
@@ -7732,7 +7732,7 @@ var To = i(({ mobileBreakpoint: e = 768, tabletBreakpoint: t = 1280, children: n
7732
7732
  }), /* @__PURE__ */ _("div", {
7733
7733
  className: (0, M.default)("pkt-header-service__mobile-menu", z === "search" && "is-open", de && "align-right"),
7734
7734
  ref: K,
7735
- children: z === "search" && /* @__PURE__ */ _(Co, {
7735
+ children: z === "search" && /* @__PURE__ */ _(wo, {
7736
7736
  id: "mobile-search-menu",
7737
7737
  className: "pkt-header-service__search-input",
7738
7738
  type: "search",
@@ -7748,7 +7748,7 @@ var To = i(({ mobileBreakpoint: e = 768, tabletBreakpoint: t = 1280, children: n
7748
7748
  }
7749
7749
  })
7750
7750
  })]
7751
- }) : /* @__PURE__ */ _(Co, {
7751
+ }) : /* @__PURE__ */ _(wo, {
7752
7752
  id: "header-service-search",
7753
7753
  className: "pkt-header-service__search-input",
7754
7754
  type: "search",
@@ -7795,7 +7795,7 @@ var To = i(({ mobileBreakpoint: e = 768, tabletBreakpoint: t = 1280, children: n
7795
7795
  })]
7796
7796
  }), z === "user" && E && /* @__PURE__ */ _("div", {
7797
7797
  className: (0, M.default)(q ? "pkt-header-service__mobile-menu" : "pkt-header-service__user-menu", "is-open"),
7798
- children: /* @__PURE__ */ _(ho, {
7798
+ children: /* @__PURE__ */ _(go, {
7799
7799
  strings: ae,
7800
7800
  user: E,
7801
7801
  formattedLastLoggedIn: ce,
@@ -7822,20 +7822,20 @@ var To = i(({ mobileBreakpoint: e = 768, tabletBreakpoint: t = 1280, children: n
7822
7822
  children: [xe, /* @__PURE__ */ _("div", { className: (0, M.default)("pkt-header-service-spacer", i && "pkt-header-service-spacer--compact", E && "pkt-header-service-spacer--has-user", q && "pkt-header-service-spacer--mobile", pe && "pkt-header-service-spacer--tablet") })]
7823
7823
  }) : xe;
7824
7824
  });
7825
- To.displayName = "PktHeaderService";
7825
+ Eo.displayName = "PktHeaderService";
7826
7826
  //#endregion
7827
7827
  //#region src/components/header/Header.tsx
7828
- var Eo = i((e, t) => e.type === "global" ? /* @__PURE__ */ _(So, {
7828
+ var Do = i((e, t) => e.type === "global" ? /* @__PURE__ */ _(Co, {
7829
7829
  ...e,
7830
7830
  ref: t
7831
- }) : /* @__PURE__ */ _(To, {
7831
+ }) : /* @__PURE__ */ _(Eo, {
7832
7832
  ...e,
7833
7833
  ref: t
7834
7834
  }));
7835
- Eo.displayName = "PktHeader";
7835
+ Do.displayName = "PktHeader";
7836
7836
  //#endregion
7837
7837
  //#region src/components/input/Input.tsx
7838
- var Do = i(({ label: e, id: t, children: n, ...r }, i) => /* @__PURE__ */ v("div", {
7838
+ var Oo = i(({ label: e, id: t, children: n, ...r }, i) => /* @__PURE__ */ v("div", {
7839
7839
  className: "pkt-form-group",
7840
7840
  children: [
7841
7841
  /* @__PURE__ */ _("label", {
@@ -7852,10 +7852,10 @@ var Do = i(({ label: e, id: t, children: n, ...r }, i) => /* @__PURE__ */ v("div
7852
7852
  n
7853
7853
  ]
7854
7854
  }));
7855
- Do.displayName = "PktInput";
7855
+ Oo.displayName = "PktInput";
7856
7856
  //#endregion
7857
7857
  //#region src/components/linkcard/LinkCard.tsx
7858
- var Oo = ({ children: e, skin: t, title: n, href: r, iconName: i, openInNewTab: a, external: o, className: s, strings: c, ...l }) => {
7858
+ var ko = ({ children: e, skin: t, title: n, href: r, iconName: i, openInNewTab: a, external: o, className: s, strings: c, ...l }) => {
7859
7859
  let u = ve(["linkcard"], c), d = ["pkt-linkcard", t && `pkt-linkcard--${t}`].filter(Boolean).join(" "), f = ["pkt-linkcard__title", o && "pkt-link pkt-link--external"].filter(Boolean).join(" ");
7860
7860
  return /* @__PURE__ */ v("a", {
7861
7861
  ...l,
@@ -7885,14 +7885,14 @@ var Oo = ({ children: e, skin: t, title: n, href: r, iconName: i, openInNewTab:
7885
7885
  };
7886
7886
  //#endregion
7887
7887
  //#region src/components/loader/Loader.tsx
7888
- Oo.displayName = "PktLinkCard", typeof window < "u" && (window.pktAnimationPath = window.pktAnimationPath || "https://punkt-cdn.oslo.kommune.no/latest/animations/");
7889
- var ko = (e) => {
7888
+ ko.displayName = "PktLinkCard", typeof window < "u" && (window.pktAnimationPath = window.pktAnimationPath || "https://punkt-cdn.oslo.kommune.no/latest/animations/");
7889
+ var Ao = (e) => {
7890
7890
  switch (e) {
7891
7891
  case "blue": return "spinner-blue";
7892
7892
  case "rainbow": return "spinner";
7893
7893
  default: return "loader";
7894
7894
  }
7895
- }, Ao = i(function({ delay: e = 0, inline: t = !1, isLoading: n = !0, message: r = null, size: i = "medium", variant: a = "rainbow", loadingAnimationPath: o = typeof window < "u" ? window.pktAnimationPath : void 0, className: s, children: l, ...u }, d) {
7895
+ }, jo = i(function({ delay: e = 0, inline: t = !1, isLoading: n = !0, message: r = null, size: i = "medium", variant: a = "rainbow", loadingAnimationPath: o = typeof window < "u" ? window.pktAnimationPath : void 0, className: s, children: l, ...u }, d) {
7896
7896
  let [f, p] = m(e === 0);
7897
7897
  c(() => {
7898
7898
  if (e > 0) {
@@ -7913,7 +7913,7 @@ var ko = (e) => {
7913
7913
  children: [n && f && /* @__PURE__ */ v("div", {
7914
7914
  className: "pkt-loader__spinner",
7915
7915
  children: [/* @__PURE__ */ _(L, {
7916
- name: ko(a),
7916
+ name: Ao(a),
7917
7917
  path: o,
7918
7918
  className: `pkt-loader__svg pkt-loader__${a}`
7919
7919
  }), r && /* @__PURE__ */ _("p", { children: r })]
@@ -7923,10 +7923,10 @@ var ko = (e) => {
7923
7923
  })]
7924
7924
  });
7925
7925
  });
7926
- Ao.displayName = "PktLoader";
7926
+ jo.displayName = "PktLoader";
7927
7927
  //#endregion
7928
7928
  //#region src/components/messagebox/Messagebox.tsx
7929
- var jo = ({ children: e, className: t, skin: n, title: i, compact: a, closable: s, onClose: c, ...l }) => {
7929
+ var Mo = ({ children: e, className: t, skin: n, title: i, compact: a, closable: s, onClose: c, ...l }) => {
7930
7930
  let [u, d] = m(!1), f = {
7931
7931
  "pkt-messagebox": !0,
7932
7932
  "pkt-messagebox--compact": a,
@@ -7964,10 +7964,10 @@ var jo = ({ children: e, className: t, skin: n, title: i, compact: a, closable:
7964
7964
  ]
7965
7965
  });
7966
7966
  };
7967
- jo.displayName = "PktMessagebox";
7967
+ Mo.displayName = "PktMessagebox";
7968
7968
  //#endregion
7969
7969
  //#region src/components/radio/RadioButton.tsx
7970
- var Mo = i(({ id: e, name: t, label: n, className: r, hasTile: i = !1, disabled: a = !1, checkHelptext: o, hasError: s = !1, defaultChecked: c, checked: l, optionalTag: u, optionalText: d, requiredTag: f, requiredText: p, strings: m, tagText: h, "aria-describedby": y, ...b }, x) => {
7970
+ var No = i(({ id: e, name: t, label: n, className: r, hasTile: i = !1, disabled: a = !1, checkHelptext: o, hasError: s = !1, defaultChecked: c, checked: l, optionalTag: u, optionalText: d, requiredTag: f, requiredText: p, strings: m, tagText: h, "aria-describedby": y, ...b }, x) => {
7971
7971
  let S = ve(["forms"], m), C = Jn(e), w = [r, "pkt-input-check"].filter(Boolean).join(" "), T = [
7972
7972
  "pkt-input-check__input",
7973
7973
  i ? "pkt-input-check__input--tile" : "",
@@ -8024,10 +8024,10 @@ var Mo = i(({ id: e, name: t, label: n, className: r, hasTile: i = !1, disabled:
8024
8024
  })
8025
8025
  });
8026
8026
  });
8027
- Mo.displayName = "PktRadioButton";
8027
+ No.displayName = "PktRadioButton";
8028
8028
  //#endregion
8029
8029
  //#region src/components/select/Select.tsx
8030
- var No = i(({ ariaDescribedby: e, ariaLabelledby: t, children: n, className: r, disabled: i = !1, errorMessage: a, hasError: o = !1, helptext: s, helptextDropdown: c, helptextDropdownButton: l, id: u, inline: d = !1, fullwidth: f = !1, label: p, name: m, optionalTag: h = !1, optionalText: g, requiredTag: v = !1, requiredText: y, tagText: b, useWrapper: x = !0, hasFieldset: S, inputSize: C = "medium", strings: w, ...T }, E) => {
8030
+ var Po = i(({ ariaDescribedby: e, ariaLabelledby: t, children: n, className: r, disabled: i = !1, errorMessage: a, hasError: o = !1, helptext: s, helptextDropdown: c, helptextDropdownButton: l, id: u, inline: d = !1, fullwidth: f = !1, label: p, name: m, optionalTag: h = !1, optionalText: g, requiredTag: v = !1, requiredText: y, tagText: b, useWrapper: x = !0, hasFieldset: S, inputSize: C = "medium", strings: w, ...T }, E) => {
8031
8031
  let D = Jn(u), O = [r, "pkt-select"].filter(Boolean).join(" ");
8032
8032
  return /* @__PURE__ */ _("div", {
8033
8033
  className: O,
@@ -8072,10 +8072,10 @@ var No = i(({ ariaDescribedby: e, ariaLabelledby: t, children: n, className: r,
8072
8072
  })
8073
8073
  });
8074
8074
  });
8075
- No.displayName = "PktSelect";
8075
+ Po.displayName = "PktSelect";
8076
8076
  //#endregion
8077
8077
  //#region src/components/stepper/Step.tsx
8078
- var Po = /* @__PURE__ */ _("svg", {
8078
+ var Fo = /* @__PURE__ */ _("svg", {
8079
8079
  xmlns: "http://www.w3.org/2000/svg",
8080
8080
  width: "24",
8081
8081
  height: "24",
@@ -8086,7 +8086,7 @@ var Po = /* @__PURE__ */ _("svg", {
8086
8086
  r: "7",
8087
8087
  style: { fill: "var(--pkt-color-brand-neutrals-300, #CCC)" }
8088
8088
  })
8089
- }), Fo = /* @__PURE__ */ v("svg", {
8089
+ }), Io = /* @__PURE__ */ v("svg", {
8090
8090
  xmlns: "http://www.w3.org/2000/svg",
8091
8091
  width: "24",
8092
8092
  height: "24",
@@ -8103,7 +8103,7 @@ var Po = /* @__PURE__ */ _("svg", {
8103
8103
  r: "6",
8104
8104
  fill: "#2A2859"
8105
8105
  })]
8106
- }), Io = /* @__PURE__ */ v("svg", {
8106
+ }), Lo = /* @__PURE__ */ v("svg", {
8107
8107
  xmlns: "http://www.w3.org/2000/svg",
8108
8108
  width: "24",
8109
8109
  height: "24",
@@ -8115,7 +8115,7 @@ var Po = /* @__PURE__ */ _("svg", {
8115
8115
  d: "m10.34 16-1.11-1.14L7 12.58l1.11-1.15 2.23 2.28L15.88 8 17 9.15l-5.55 5.71L10.34 16Z",
8116
8116
  fill: "#F1FDFF"
8117
8117
  })]
8118
- }), Lo = ({ children: e, className: t, status: n = "incomplete", title: r }) => /* @__PURE__ */ v("li", {
8118
+ }), Ro = ({ children: e, className: t, status: n = "incomplete", title: r }) => /* @__PURE__ */ v("li", {
8119
8119
  className: (0, M.default)("pkt-step", t, `pkt-step--${n}`),
8120
8120
  "data-testid": "pkt-step",
8121
8121
  children: [
@@ -8129,7 +8129,7 @@ var Po = /* @__PURE__ */ _("svg", {
8129
8129
  }),
8130
8130
  /* @__PURE__ */ _("span", {
8131
8131
  className: (0, M.default)("pkt-step__indicator"),
8132
- children: n === "current" ? Fo : n === "completed" ? Io : Po
8132
+ children: n === "current" ? Io : n === "completed" ? Lo : Fo
8133
8133
  }),
8134
8134
  /* @__PURE__ */ _("span", {
8135
8135
  className: "pkt-step__line pkt-step__line--3",
@@ -8146,7 +8146,7 @@ var Po = /* @__PURE__ */ _("svg", {
8146
8146
  })]
8147
8147
  })
8148
8148
  ]
8149
- }), Ro = i(({ activeStep: n, className: r, children: i, hideNonActiveSteps: o = !1, hideNonActiveStepsContent: s = !0, orientation: c = "vertical", ...l }, u) => {
8149
+ }), zo = i(({ activeStep: n, className: r, children: i, hideNonActiveSteps: o = !1, hideNonActiveStepsContent: s = !0, orientation: c = "vertical", ...l }, u) => {
8150
8150
  let d = (0, M.default)(r, "pkt-stepper", c === "horizontal" ? "pkt-stepper--horizontal" : "pkt-stepper--vertical"), f = e.map(i, (e, r) => a(e) ? t(e, { className: (0, M.default)(e.props.className, {
8151
8151
  "pkt-step--hideStep": o && r !== n,
8152
8152
  "pkt-step--hideContent": s && r !== n
@@ -8159,10 +8159,10 @@ var Po = /* @__PURE__ */ _("svg", {
8159
8159
  children: f
8160
8160
  });
8161
8161
  });
8162
- Ro.displayName = "PktStepper";
8162
+ zo.displayName = "PktStepper";
8163
8163
  //#endregion
8164
8164
  //#region src/components/table/Table.tsx
8165
- var zo = ({ className: e, compact: t = !1, skin: n = "basic", responsiveView: r = !0, children: i, ...a }) => /* @__PURE__ */ _("table", {
8165
+ var Bo = ({ className: e, compact: t = !1, skin: n = "basic", responsiveView: r = !0, children: i, ...a }) => /* @__PURE__ */ _("table", {
8166
8166
  "data-testid": "pkt-table",
8167
8167
  className: (0, M.default)(e, "pkt-table", {
8168
8168
  "pkt-table--responsive": r,
@@ -8173,36 +8173,36 @@ var zo = ({ className: e, compact: t = !1, skin: n = "basic", responsiveView: r
8173
8173
  role: "table",
8174
8174
  ...a,
8175
8175
  children: i
8176
- }), Bo = ({ id: e, children: t, className: n, ...r }) => /* @__PURE__ */ _("tbody", {
8176
+ }), Vo = ({ id: e, children: t, className: n, ...r }) => /* @__PURE__ */ _("tbody", {
8177
8177
  id: e,
8178
8178
  className: (0, M.default)(n, "pkt-table__body", {}),
8179
8179
  ...r,
8180
8180
  role: "rowgroup",
8181
8181
  children: t
8182
- }), Vo = ({ children: e, className: t, dataLabel: n, ...r }) => /* @__PURE__ */ _("td", {
8182
+ }), Ho = ({ children: e, className: t, dataLabel: n, ...r }) => /* @__PURE__ */ _("td", {
8183
8183
  className: (0, M.default)(t, "pkt-table__data-cell", {}),
8184
8184
  "data-label": n,
8185
8185
  role: "cell",
8186
8186
  "data-testid": "pkt-table__data-cell",
8187
8187
  ...r,
8188
8188
  children: e
8189
- }), Ho = ({ className: e, children: t, ...n }) => /* @__PURE__ */ _("thead", {
8189
+ }), Uo = ({ className: e, children: t, ...n }) => /* @__PURE__ */ _("thead", {
8190
8190
  className: (0, M.default)(e, "pkt-table__header", {}),
8191
8191
  role: "rowgroup",
8192
8192
  ...n,
8193
8193
  children: t
8194
- }), Uo = ({ className: e, children: t, ...n }) => /* @__PURE__ */ _("th", {
8194
+ }), Wo = ({ className: e, children: t, ...n }) => /* @__PURE__ */ _("th", {
8195
8195
  className: (0, M.default)(e, "pkt-table__header-cell", {}),
8196
8196
  role: "columnheader",
8197
8197
  ...n,
8198
8198
  children: t
8199
- }), Wo = ({ className: e, children: t, ...n }) => /* @__PURE__ */ _("tr", {
8199
+ }), Go = ({ className: e, children: t, ...n }) => /* @__PURE__ */ _("tr", {
8200
8200
  className: (0, M.default)(e, "pkt-table__row", {}),
8201
8201
  role: "row",
8202
8202
  ...n,
8203
8203
  children: t
8204
- }), Go = i(({ children: e, active: t, disabled: n = !1, href: r, onClick: i, icon: a, controls: o, tag: s, tagSkin: c, index: l = 0 }, u) => {
8205
- let { arrowNav: d, registerTabRef: f, handleKeyPress: p, selectTab: m } = qo(), h = !!t && !n, y = {
8204
+ }), Ko = i(({ children: e, active: t, disabled: n = !1, href: r, onClick: i, icon: a, controls: o, tag: s, tagSkin: c, index: l = 0 }, u) => {
8205
+ let { arrowNav: d, registerTabRef: f, handleKeyPress: p, selectTab: m } = Jo(), h = !!t && !n, y = {
8206
8206
  "aria-selected": d ? h : void 0,
8207
8207
  "aria-controls": o,
8208
8208
  role: d ? "tab" : void 0,
@@ -8251,14 +8251,14 @@ var zo = ({ className: e, compact: t = !1, skin: n = "basic", responsiveView: r
8251
8251
  children: b
8252
8252
  });
8253
8253
  });
8254
- Go.displayName = "PktTabItem";
8254
+ Ko.displayName = "PktTabItem";
8255
8255
  //#endregion
8256
8256
  //#region src/components/tabs/Tabs.tsx
8257
- var Ko = n(null), qo = () => {
8258
- let e = s(Ko);
8257
+ var qo = n(null), Jo = () => {
8258
+ let e = s(qo);
8259
8259
  if (!e) throw Error("TabItem must be used within a Tabs component");
8260
8260
  return e;
8261
- }, Jo = i(({ arrowNav: t = !0, disableArrowNav: n = !1, separatorIconName: r, separatorIconPath: i, tabs: a, onTabSelected: o, children: s }, l) => {
8261
+ }, Yo = i(({ arrowNav: t = !0, disableArrowNav: n = !1, separatorIconName: r, separatorIconPath: i, tabs: a, onTabSelected: o, children: s }, l) => {
8262
8262
  let u = p([]), d = p({}), f = t && !n, m = e.toArray(s), h = m.length > 0, g = h ? m.length : a?.length || 0, v = !!(r || i);
8263
8263
  c(() => {
8264
8264
  u.current = u.current.slice(0, g), Object.keys(d.current).forEach((e) => {
@@ -8305,7 +8305,7 @@ var Ko = n(null), qo = () => {
8305
8305
  name: r,
8306
8306
  className: "pkt-tabs__separator-icon"
8307
8307
  }) : null
8308
- }, e), T = (e) => !v || e.length <= 1 ? e : e.flatMap((t, n) => n < e.length - 1 ? [t, w(`separator-${n}`)] : [t]), E = a?.map((e, t) => /* @__PURE__ */ _(Go, {
8308
+ }, e), T = (e) => !v || e.length <= 1 ? e : e.flatMap((t, n) => n < e.length - 1 ? [t, w(`separator-${n}`)] : [t]), E = a?.map((e, t) => /* @__PURE__ */ _(Ko, {
8309
8309
  active: !e.disabled && e.active,
8310
8310
  disabled: e.disabled,
8311
8311
  href: e.href,
@@ -8316,7 +8316,7 @@ var Ko = n(null), qo = () => {
8316
8316
  index: t,
8317
8317
  children: e.text
8318
8318
  }, t)), D = ["pkt-tabs", v && "pkt-tabs--with-separator"].filter(Boolean).join(" "), O = T(h ? m : E || []);
8319
- return /* @__PURE__ */ _(Ko.Provider, {
8319
+ return /* @__PURE__ */ _(qo.Provider, {
8320
8320
  value: {
8321
8321
  arrowNav: f,
8322
8322
  registerTabRef: C,
@@ -8334,53 +8334,53 @@ var Ko = n(null), qo = () => {
8334
8334
  })
8335
8335
  });
8336
8336
  });
8337
- Jo.displayName = "PktTabs";
8337
+ Yo.displayName = "PktTabs";
8338
8338
  //#endregion
8339
8339
  //#region ../../shared-utils/timepicker/options.ts
8340
- var Yo = (e) => e ? Math.max(1, Math.round(e / 60)) : 1, Xo = (e, t) => {
8340
+ var Xo = (e) => e ? Math.max(1, Math.round(e / 60)) : 1, Zo = (e, t) => {
8341
8341
  let n = e ? parseInt(String(e).split(":")[0], 10) : 0, r = t ? parseInt(String(t).split(":")[0], 10) : 23;
8342
8342
  return Array.from({ length: r - n + 1 }, (e, t) => t + n);
8343
- }, Zo = (e) => {
8344
- let t = Yo(e);
8343
+ }, Qo = (e) => {
8344
+ let t = Xo(e);
8345
8345
  return Array.from({ length: Math.floor(60 / t) }, (e, n) => n * t);
8346
- }, Qo = (e, t, n, r) => {
8346
+ }, $o = (e, t, n, r) => {
8347
8347
  let i = e === "" ? n === 1 ? 0 : 23 : parseInt(e, 10), a = t === "" ? n === 1 ? 0 : Math.floor(59 / r) * r : parseInt(t, 10);
8348
8348
  return a += n * r, a > 59 ? (a = 0, i = (i + 1) % 24) : a < 0 && (a = Math.floor(59 / r) * r, i = (i - 1 + 24) % 24), {
8349
8349
  hours: String(i).padStart(2, "0"),
8350
8350
  minutes: String(a).padStart(2, "0")
8351
8351
  };
8352
- }, $o = (e) => /^\d{2}:\d{2}$/.test(e) && parseInt(e.slice(0, 2), 10) <= 23 && parseInt(e.slice(3), 10) <= 59, es = (e) => {
8352
+ }, es = (e) => /^\d{2}:\d{2}$/.test(e) && parseInt(e.slice(0, 2), 10) <= 23 && parseInt(e.slice(3), 10) <= 59, ts = (e) => {
8353
8353
  let [t, n] = e.split(":").map(Number);
8354
8354
  return t * 60 + n;
8355
8355
  };
8356
8356
  //#endregion
8357
8357
  //#region src/components/timepicker/useTimepickerState.ts
8358
- function ts(e) {
8359
- if (e && $o(e)) {
8358
+ function ns(e) {
8359
+ if (e && es(e)) {
8360
8360
  let [t, n] = e.split(":");
8361
8361
  return [t, n];
8362
8362
  }
8363
8363
  return ["", ""];
8364
8364
  }
8365
- function ns(e, t) {
8365
+ function rs(e, t) {
8366
8366
  return `${String(parseInt(e, 10)).padStart(2, "0")}:${String(parseInt(t, 10)).padStart(2, "0")}`;
8367
8367
  }
8368
- function rs(e, t, n) {
8368
+ function is(e, t, n) {
8369
8369
  let { required: r, min: i, max: a, step: o } = t;
8370
8370
  if (r && !e) return {
8371
8371
  valid: !1,
8372
8372
  message: n.valueMissing
8373
8373
  };
8374
8374
  if (!e) return { valid: !0 };
8375
- if (!$o(e)) return {
8375
+ if (!es(e)) return {
8376
8376
  valid: !1,
8377
8377
  message: n.typeMismatch
8378
8378
  };
8379
- let s = es(e), c = Yo(o);
8380
- return i && s < es(String(i)) ? {
8379
+ let s = ts(e), c = Xo(o);
8380
+ return i && s < ts(String(i)) ? {
8381
8381
  valid: !1,
8382
8382
  message: B(n.rangeUnderflowMin, { min: String(i) })
8383
- } : a && s > es(String(a)) ? {
8383
+ } : a && s > ts(String(a)) ? {
8384
8384
  valid: !1,
8385
8385
  message: B(n.rangeOverflowMax, { max: String(a) })
8386
8386
  } : o && s % c !== 0 ? {
@@ -8388,11 +8388,11 @@ function rs(e, t, n) {
8388
8388
  message: c === 60 ? n.timeStepMismatchHour : c === 30 ? n.timeStepMismatchHalfHour : B(n.timeStepMismatch, { step: `${c}, ${c * 2}, ${c * 3}` })
8389
8389
  } : { valid: !0 };
8390
8390
  }
8391
- function is(e) {
8391
+ function as(e) {
8392
8392
  return e === 3600 || e < 3600 && 3600 % e == 0 && e % 60 == 0;
8393
8393
  }
8394
- function as(e, t) {
8395
- let { id: n, label: r, value: i, defaultValue: a, min: s, max: l, step: h = 60, hidePicker: g = !1, stepArrows: _ = !1, fullwidth: v = !1, name: y, form: b, disabled: x = !1, required: S = !1, helptext: C, helptextDropdown: w, helptextDropdownButton: T, hasError: E = !1, errorMessage: D, optionalTag: O = !1, optionalText: k, requiredTag: A = !1, requiredText: j, tagText: M, inline: N = !1, useWrapper: P = !0, ariaDescribedby: ee, strings: te, className: ne, inputSize: F = "medium", onValueChange: re, onFocus: ie, onBlur: ae } = e, oe = ve(["timepicker", "validation"], te), se = oe.timepicker, I = te, L = i !== void 0, R = i === void 0 ? a ?? "" : i ?? "", ce = p(R), [z, B] = m(() => R), le = L ? i ?? "" : z, [ue, de] = m(() => ts(i === void 0 ? a : i)[0]), [V, H] = m(() => ts(i === void 0 ? a : i)[1]), U = p(ue), W = p(V), G = o((e) => {
8394
+ function os(e, t) {
8395
+ let { id: n, label: r, value: i, defaultValue: a, min: s, max: l, step: h = 60, hidePicker: g = !1, stepArrows: _ = !1, fullwidth: v = !1, name: y, form: b, disabled: x = !1, required: S = !1, helptext: C, helptextDropdown: w, helptextDropdownButton: T, hasError: E = !1, errorMessage: D, optionalTag: O = !1, optionalText: k, requiredTag: A = !1, requiredText: j, tagText: M, inline: N = !1, useWrapper: P = !0, ariaDescribedby: ee, strings: te, className: ne, inputSize: F = "medium", onValueChange: re, onFocus: ie, onBlur: ae } = e, oe = ve(["timepicker", "validation"], te), se = oe.timepicker, I = te, L = i !== void 0, R = i === void 0 ? a ?? "" : i ?? "", ce = p(R), [z, B] = m(() => R), le = L ? i ?? "" : z, [ue, de] = m(() => ns(i === void 0 ? a : i)[0]), [V, H] = m(() => ns(i === void 0 ? a : i)[1]), U = p(ue), W = p(V), G = o((e) => {
8396
8396
  U.current = e, de(e);
8397
8397
  }, []), K = o((e) => {
8398
8398
  W.current = e, H(e);
@@ -8400,7 +8400,7 @@ function as(e, t) {
8400
8400
  c(() => {
8401
8401
  if (!L || i === he.current) return;
8402
8402
  he.current = i;
8403
- let [e, t] = ts(i);
8403
+ let [e, t] = ns(i);
8404
8404
  G(e), K(t);
8405
8405
  }, [
8406
8406
  i,
@@ -8408,13 +8408,13 @@ function as(e, t) {
8408
8408
  G,
8409
8409
  K
8410
8410
  ]), c(() => {
8411
- h != null && !is(h) && console.warn(`PktTimepicker: step="${h}" er ikke en gyldig verdi. Step må være et multiplum av 60 (hele minutter) eller nøyaktig 3600 (hel time).`);
8411
+ h != null && !as(h) && console.warn(`PktTimepicker: step="${h}" er ikke en gyldig verdi. Step må være et multiplum av 60 (hele minutter) eller nøyaktig 3600 (hel time).`);
8412
8412
  }, [h]);
8413
- let J = p(null), ge = p(null), Y = p(null), _e = p(null), X = p(null), ye = p(null), be = Er(X, b), Z = p(0), Q = p(-1), xe = p(0), Se = p(-1), [Ce, we] = m(!1), Te = f(() => Object.getOwnPropertyDescriptor(HTMLInputElement.prototype, "value")?.set, []), Ee = f(() => Yo(h), [h]), De = f(() => Xo(s, l), [s, l]), Oe = f(() => Zo(h), [h]), ke = `${n}-hours`, Ae = `${n}-minutes`, je = `${n}-popup`, Me = `${n}-input`;
8413
+ let J = p(null), ge = p(null), Y = p(null), _e = p(null), X = p(null), ye = p(null), be = Dr(X, b), Z = p(0), Q = p(-1), xe = p(0), Se = p(-1), [Ce, we] = m(!1), Te = f(() => Object.getOwnPropertyDescriptor(HTMLInputElement.prototype, "value")?.set, []), Ee = f(() => Xo(h), [h]), De = f(() => Zo(s, l), [s, l]), Oe = f(() => Qo(h), [h]), ke = `${n}-hours`, Ae = `${n}-minutes`, je = `${n}-popup`, Me = `${n}-input`;
8414
8414
  c(() => {
8415
8415
  let e = J.current;
8416
8416
  if (!e) return;
8417
- let t = rs(le, {
8417
+ let t = is(le, {
8418
8418
  required: S,
8419
8419
  min: s,
8420
8420
  max: l,
@@ -8441,20 +8441,20 @@ function as(e, t) {
8441
8441
  ]), Ne = o(() => {
8442
8442
  let e = U.current, t = W.current;
8443
8443
  if (e !== "" && t !== "") {
8444
- let n = ns(e, t);
8444
+ let n = rs(e, t);
8445
8445
  n !== le && $(n);
8446
8446
  } else le !== "" && $("");
8447
8447
  }, [le, $]), Pe = o(() => {
8448
8448
  let e = U.current, t = W.current;
8449
8449
  if (e !== "" && t !== "") {
8450
- let n = ns(e, t);
8450
+ let n = rs(e, t);
8451
8451
  n === le ? ye.current?.dispatchEvent(new Event("input", { bubbles: !0 })) : $(n);
8452
8452
  } else le === "" ? ye.current?.dispatchEvent(new Event("input", { bubbles: !0 })) : $("");
8453
8453
  }, [le, $]), Fe = o(() => {
8454
8454
  we(!0), Ne();
8455
8455
  let e = J.current, t = ye.current;
8456
8456
  if (!e) return;
8457
- let n = rs(t?.value ?? "", {
8457
+ let n = is(t?.value ?? "", {
8458
8458
  required: S,
8459
8459
  min: s,
8460
8460
  max: l,
@@ -8527,7 +8527,7 @@ function as(e, t) {
8527
8527
  G,
8528
8528
  K
8529
8529
  ]), ze = o((e) => {
8530
- let t = Qo(U.current, W.current, e, Ee);
8530
+ let t = $o(U.current, W.current, e, Ee);
8531
8531
  G(t.hours), K(t.minutes), `${t.hours}:${t.minutes}` !== le && $(`${t.hours}:${t.minutes}`);
8532
8532
  }, [
8533
8533
  Ee,
@@ -8745,7 +8745,7 @@ function as(e, t) {
8745
8745
  set value(e) {
8746
8746
  let t = e ?? "";
8747
8747
  L || B(t);
8748
- let [n, r] = ts(t);
8748
+ let [n, r] = ns(t);
8749
8749
  G(n), K(r), ye.current && (ye.current.value = t);
8750
8750
  },
8751
8751
  focus() {
@@ -8762,7 +8762,7 @@ function as(e, t) {
8762
8762
  if (!be) return;
8763
8763
  let e = () => {
8764
8764
  window.setTimeout(() => {
8765
- let e = ce.current, [t, n] = ts(e);
8765
+ let e = ce.current, [t, n] = ns(e);
8766
8766
  G(t), K(n), L || B(e), ye.current && (ye.current.value = e), q(!1), we(!1);
8767
8767
  }, 0);
8768
8768
  };
@@ -8840,8 +8840,8 @@ function as(e, t) {
8840
8840
  }
8841
8841
  //#endregion
8842
8842
  //#region src/components/timepicker/Timepicker.tsx
8843
- var os = i((e, t) => {
8844
- let { onChange: n, inputSize: r = "medium" } = e, i = as(e, t), a = i.strings.hours, o = i.strings.minutes, s = i.label ? `${a}, ${i.label}` : a, c = i.label ? `${o}, ${i.label}` : o, l = Zn({
8843
+ var ss = i((e, t) => {
8844
+ let { onChange: n, inputSize: r = "medium" } = e, i = os(e, t), a = i.strings.hours, o = i.strings.minutes, s = i.label ? `${a}, ${i.label}` : a, c = i.label ? `${o}, ${i.label}` : o, l = Zn({
8845
8845
  id: i.hoursId,
8846
8846
  hasHelptext: !!i.helptext,
8847
8847
  ariaDescribedby: i.ariaDescribedby
@@ -9053,6 +9053,6 @@ var os = i((e, t) => {
9053
9053
  })
9054
9054
  });
9055
9055
  });
9056
- os.displayName = "PktTimepicker";
9056
+ ss.displayName = "PktTimepicker";
9057
9057
  //#endregion
9058
- export { xi as FileItem, Sa as ItemRenderers, j as PktAccordion, R as PktAccordionItem, ye as PktAlert, be as PktBackLink, Z as PktBreadcrumbs, Y as PktButton, Ln as PktCalendar, Gn as PktCard, Yn as PktCheckbox, kr as PktCombobox, Pr as PktConsent, Yr as PktDatepicker, Ca as PktFileUpload, Ya as PktFooter, Za as PktFooterSimple, Eo as PktHeader, So as PktHeaderGlobal, to as PktHeaderMenu, To as PktHeaderService, Un as PktHeading, nr as PktHelptext, L as PktIcon, Do as PktInput, rr as PktInputWrapper, uo as PktLink, Oo as PktLinkCard, Ao as PktLoader, jo as PktMessagebox, $i as PktModal, Hi as PktProgressbar, Mo as PktRadioButton, go as PktSearchInput, No as PktSelect, Lo as PktStep, Ro as PktStepper, X as PktStringsProvider, Go as PktTabItem, zo as PktTable, Bo as PktTableBody, Vo as PktTableDataCell, Ho as PktTableHeader, Uo as PktTableHeaderCell, Wo as PktTableRow, Jo as PktTabs, Wn as PktTag, Ti as PktTextarea, Co as PktTextinput, os as PktTimepicker, W as getPktStrings, ce as pktStringsNb, G as resetPktStrings, U as setPktStrings, K as subscribePktStrings };
9058
+ export { Si as FileItem, Ca as ItemRenderers, j as PktAccordion, R as PktAccordionItem, ye as PktAlert, be as PktBackLink, Z as PktBreadcrumbs, Y as PktButton, Ln as PktCalendar, Gn as PktCard, Yn as PktCheckbox, Ar as PktCombobox, Fr as PktConsent, Xr as PktDatepicker, wa as PktFileUpload, Xa as PktFooter, Qa as PktFooterSimple, Do as PktHeader, Co as PktHeaderGlobal, no as PktHeaderMenu, Eo as PktHeaderService, Un as PktHeading, nr as PktHelptext, L as PktIcon, Oo as PktInput, rr as PktInputWrapper, fo as PktLink, ko as PktLinkCard, jo as PktLoader, Mo as PktMessagebox, ea as PktModal, Ui as PktProgressbar, No as PktRadioButton, _o as PktSearchInput, Po as PktSelect, Ro as PktStep, zo as PktStepper, X as PktStringsProvider, Ko as PktTabItem, Bo as PktTable, Vo as PktTableBody, Ho as PktTableDataCell, Uo as PktTableHeader, Wo as PktTableHeaderCell, Go as PktTableRow, Yo as PktTabs, Wn as PktTag, Ei as PktTextarea, wo as PktTextinput, ss as PktTimepicker, W as getPktStrings, ce as pktStringsNb, G as resetPktStrings, U as setPktStrings, K as subscribePktStrings };