@kiva/kv-components 6.64.0 → 6.64.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,5 +1,5 @@
1
- import { toRefs as P, ref as c, reactive as Q, computed as j, onMounted as X, onBeforeUnmount as Y, onUnmounted as Z, watch as g, resolveComponent as $, openBlock as p, createElementBlock as k, normalizeClass as b, withModifiers as ee, createElementVNode as w, normalizeStyle as H, createVNode as z, createCommentVNode as x, toDisplayString as te, renderSlot as F, nextTick as oe } from "vue";
2
- import { mdiArrowLeft as ne, mdiClose as ie, mdiOpenInNew as le } from "@mdi/js";
1
+ import { toRefs as P, ref as c, reactive as Q, computed as j, onMounted as X, onBeforeUnmount as Y, onUnmounted as Z, watch as g, resolveComponent as $, openBlock as p, createElementBlock as k, normalizeClass as b, withModifiers as ee, createElementVNode as w, normalizeStyle as H, createVNode as z, createCommentVNode as x, toDisplayString as te, renderSlot as F, nextTick as ne } from "vue";
2
+ import { mdiArrowLeft as oe, mdiClose as ie, mdiOpenInNew as le } from "@mdi/js";
3
3
  import se from "./KvMaterialIcon.js";
4
4
  import ae from "../_virtual/_plugin-vue_export-helper.js";
5
5
  const de = {
@@ -65,7 +65,7 @@ const de = {
65
65
  widthDimensions: {
66
66
  type: [String, Object],
67
67
  default: () => ({ default: "100%", md: "50%" }),
68
- validator: (o) => typeof o == "string" ? /^(\d+px|[\d.]+%|auto|inherit|initial)$/.test(o) : typeof o == "object" ? Object.keys(o).every((n) => ["default", "sm", "md", "lg", "xl", "2xl"].includes(n) && /^(\d+px|[\d.]+%|auto|inherit|initial)$/.test(o[n])) : !1
68
+ validator: (n) => typeof n == "string" ? /^(\d+px|[\d.]+%|auto|inherit|initial)$/.test(n) : typeof n == "object" ? Object.keys(n).every((o) => ["default", "sm", "md", "lg", "xl", "2xl"].includes(o) && /^(\d+px|[\d.]+%|auto|inherit|initial)$/.test(n[o])) : !1
69
69
  },
70
70
  /**
71
71
  * Whether to hide the background of the headline section on mobile (e.g., in Borrower Profile Sidesheet)
@@ -76,14 +76,14 @@ const de = {
76
76
  }
77
77
  },
78
78
  emits: ["side-sheet-closed", "go-to-link"],
79
- setup(o, { emit: n, slots: i }) {
79
+ setup(n, { emit: o, slots: i }) {
80
80
  const {
81
81
  visible: t,
82
82
  kvTrackFunction: I,
83
83
  trackEventCategory: M,
84
84
  widthDimensions: l,
85
85
  hideHeadlineBgOnMobile: d
86
- } = P(o), r = c(!1), a = c({}), O = c(null), m = c(null), y = c(null), _ = c(null), N = c(null), S = c(null), B = c(null), v = Q({
86
+ } = P(n), r = c(!1), a = c({}), O = c(null), m = c(null), y = c(null), _ = c(null), N = c(null), S = c(null), B = c(null), v = Q({
87
87
  headline: 0,
88
88
  controls: 0
89
89
  }), V = j(() => {
@@ -98,7 +98,7 @@ const de = {
98
98
  lg: 1024,
99
99
  xl: 1280,
100
100
  "2xl": 1536
101
- }, s = N.value || window.innerWidth, f = Object.keys(l.value).filter((u) => u !== "default").sort((u, R) => e[R] - e[u]).find((u) => s >= e[u]);
101
+ }, s = N.value || (typeof window < "u" ? window.innerWidth : 0), f = Object.keys(l.value).filter((u) => u !== "default").sort((u, R) => e[R] - e[u]).find((u) => s >= e[u]);
102
102
  return f ? l.value[f] : l.value.default || "100%";
103
103
  }), A = (e, s) => {
104
104
  let f;
@@ -106,8 +106,8 @@ const de = {
106
106
  clearTimeout(f), f = setTimeout(() => e(...u), s);
107
107
  };
108
108
  }, C = () => {
109
- _.value = window.innerHeight, N.value = window.innerWidth, setTimeout(() => {
110
- oe(() => {
109
+ _.value = typeof window < "u" ? window.innerHeight : 0, N.value = typeof window < "u" ? window.innerWidth : 0, setTimeout(() => {
110
+ ne(() => {
111
111
  var e;
112
112
  if (y.value) {
113
113
  const s = y.value.getBoundingClientRect();
@@ -126,10 +126,10 @@ const de = {
126
126
  r.value ? document.body.classList.add(e) : document.body.classList.remove(e);
127
127
  }, K = () => {
128
128
  r.value = !1, T(), I.value(M.value, "click", "side-sheet-closed"), setTimeout(() => {
129
- n("side-sheet-closed");
129
+ o("side-sheet-closed");
130
130
  }, 300), document.removeEventListener("keyup", L);
131
131
  }, G = () => {
132
- n("go-to-link");
132
+ o("go-to-link");
133
133
  }, L = (e) => {
134
134
  (e == null ? void 0 : e.key) === "Escape" && K();
135
135
  };
@@ -187,12 +187,12 @@ const de = {
187
187
  return D.indexOf(h) - D.indexOf(J);
188
188
  }).map((h) => `
189
189
  @media (min-width: ${f[h]}) {
190
- #side-sheet-${o.trackEventCategory || "default"} {
190
+ #side-sheet-${n.trackEventCategory || "default"} {
191
191
  width: ${l.value[h]} !important;
192
192
  }
193
193
  }
194
194
  `).join("");
195
- s.textContent = R, O.value.id = `side-sheet-${o.trackEventCategory || "default"}`;
195
+ s.textContent = R, O.value.id = `side-sheet-${n.trackEventCategory || "default"}`;
196
196
  }
197
197
  };
198
198
  return g(l, () => {
@@ -207,7 +207,7 @@ const de = {
207
207
  sideSheetRef: O,
208
208
  sideSheetStyles: q,
209
209
  goToLink: G,
210
- mdiArrowLeft: ne,
210
+ mdiArrowLeft: oe,
211
211
  mdiClose: ie,
212
212
  mdiOpenInNew: le,
213
213
  modalStyles: a,
@@ -215,7 +215,7 @@ const de = {
215
215
  };
216
216
  }
217
217
  }, re = { class: "tw-flex tw-gap-1.5" }, ce = { key: 1 }, ue = { class: "tw-flex tw-gap-1.5" };
218
- function we(o, n, i, t, I, M) {
218
+ function we(n, o, i, t, I, M) {
219
219
  const l = $("kv-material-icon");
220
220
  return i.visible ? (p(), k("div", {
221
221
  key: 0,
@@ -223,14 +223,14 @@ function we(o, n, i, t, I, M) {
223
223
  "tw-bg-opacity-0 tw-delay-300": !t.open,
224
224
  "tw-bg-opacity-low": t.open
225
225
  }]),
226
- onClick: n[3] || (n[3] = ee((...d) => t.closeSideSheet && t.closeSideSheet(...d), ["self"]))
226
+ onClick: o[3] || (o[3] = ee((...d) => t.closeSideSheet && t.closeSideSheet(...d), ["self"]))
227
227
  }, [
228
228
  w("div", {
229
229
  ref: "sideSheetRef",
230
230
  class: b(["tw-fixed tw-right-0 tw-transition-all tw-duration-300 tw-bg-white", {
231
231
  "tw-translate-x-full": !t.open,
232
232
  "tw-translate-x-0": t.open,
233
- "tw-h-full": o.$slots.controls
233
+ "tw-h-full": n.$slots.controls
234
234
  }]),
235
235
  style: H(t.sideSheetStyles)
236
236
  }, [
@@ -250,7 +250,7 @@ function we(o, n, i, t, I, M) {
250
250
  i.showBackButton ? (p(), k("button", {
251
251
  key: 0,
252
252
  class: "hover:tw-text-action-highlight tw-flex tw-items-center tw-justify-center",
253
- onClick: n[0] || (n[0] = (...d) => t.closeSideSheet && t.closeSideSheet(...d))
253
+ onClick: o[0] || (o[0] = (...d) => t.closeSideSheet && t.closeSideSheet(...d))
254
254
  }, [
255
255
  z(l, {
256
256
  class: "tw-w-3 tw-h-3",
@@ -263,7 +263,7 @@ function we(o, n, i, t, I, M) {
263
263
  i.showGoToLink ? (p(), k("button", {
264
264
  key: 0,
265
265
  class: "hover:tw-text-action-highlight tw-flex tw-items-center tw-justify-center",
266
- onClick: n[1] || (n[1] = (...d) => t.goToLink && t.goToLink(...d))
266
+ onClick: o[1] || (o[1] = (...d) => t.goToLink && t.goToLink(...d))
267
267
  }, [
268
268
  z(l, {
269
269
  class: "tw-w-3 tw-h-3",
@@ -272,7 +272,7 @@ function we(o, n, i, t, I, M) {
272
272
  ])) : x("", !0),
273
273
  w("button", {
274
274
  class: "hover:tw-text-action-highlight tw-flex tw-items-center tw-justify-center",
275
- onClick: n[2] || (n[2] = (...d) => t.closeSideSheet && t.closeSideSheet(...d))
275
+ onClick: o[2] || (o[2] = (...d) => t.closeSideSheet && t.closeSideSheet(...d))
276
276
  }, [
277
277
  z(l, {
278
278
  class: "tw-w-3 tw-h-3",
@@ -292,10 +292,10 @@ function we(o, n, i, t, I, M) {
292
292
  "tw-opacity-full": t.open
293
293
  }])
294
294
  }, [
295
- F(o.$slots, "default")
295
+ F(n.$slots, "default")
296
296
  ], 2)
297
297
  ], 4),
298
- o.$slots.controls ? (p(), k("div", {
298
+ n.$slots.controls ? (p(), k("div", {
299
299
  key: 0,
300
300
  ref: "controlsRef",
301
301
  class: b(["tw-absolute tw-bottom-0 tw-w-full tw-border-t tw-border-tertiary tw-bg-white tw-transition-opacity tw-duration-200", {
@@ -304,7 +304,7 @@ function we(o, n, i, t, I, M) {
304
304
  }]),
305
305
  style: { "z-index": "999" }
306
306
  }, [
307
- F(o.$slots, "controls")
307
+ F(n.$slots, "controls")
308
308
  ], 2)) : x("", !0)
309
309
  ], 4)
310
310
  ], 6)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kiva/kv-components",
3
- "version": "6.64.0",
3
+ "version": "6.64.1",
4
4
  "type": "module",
5
5
  "publishConfig": {
6
6
  "access": "public"
@@ -114,5 +114,5 @@
114
114
  "embla-carousel-fade",
115
115
  "popper.js"
116
116
  ],
117
- "gitHead": "00c839f41376d29da8b7675e9b6bfa32f040e056"
117
+ "gitHead": "623e3e5c52ad8622dc088341b975052412c84980"
118
118
  }