@kiva/kv-components 6.62.0 → 6.62.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.
@@ -0,0 +1,9 @@
1
+ const r = (t, o) => {
2
+ let e;
3
+ return (...u) => {
4
+ clearTimeout(e), e = setTimeout(() => t(...u), o);
5
+ };
6
+ };
7
+ export {
8
+ r as debounce
9
+ };
@@ -1 +1 @@
1
- .header-link[data-v-d33b2f4e]{cursor:pointer;padding-top:1rem;padding-bottom:1rem;--tw-text-opacity: 1;color:rgba(var(--text-primary),var(--tw-text-opacity, 1));text-decoration-line:none}.header-link[data-v-d33b2f4e]:hover{--tw-text-opacity: 1;color:rgba(var(--text-action),var(--tw-text-opacity, 1));text-decoration-line:none}[data-v-d33b2f4e] .avatar div:first-child{display:flex}
1
+ .header-link[data-v-0420196f]{cursor:pointer;padding-top:1rem;padding-bottom:1rem;--tw-text-opacity: 1;color:rgba(var(--text-primary),var(--tw-text-opacity, 1));text-decoration-line:none}.header-link[data-v-0420196f]:hover{--tw-text-opacity: 1;color:rgba(var(--text-action),var(--tw-text-opacity, 1));text-decoration-line:none}[data-v-0420196f] .avatar div:first-child{display:flex}
@@ -1,4 +1,4 @@
1
- import { defineAsyncComponent as k, ref as r, inject as Y, computed as x, watch as C, onMounted as Z, onUnmounted as $, resolveComponent as b, resolveDirective as ee, openBlock as i, createElementBlock as w, withDirectives as s, normalizeClass as p, withModifiers as H, createVNode as L, createBlock as y, withCtx as U, createTextVNode as f, createElementVNode as T, createCommentVNode as _, vShow as P, toDisplayString as ne } from "vue";
1
+ import { defineAsyncComponent as k, ref as r, inject as Y, computed as x, watch as P, onMounted as Z, onUnmounted as $, resolveComponent as b, resolveDirective as ee, openBlock as i, createElementBlock as w, withDirectives as s, normalizeClass as p, withModifiers as H, createVNode as U, createBlock as T, withCtx as B, createTextVNode as f, createElementVNode as y, createCommentVNode as V, vShow as R, toDisplayString as ne } from "vue";
2
2
  import { mdiAccountCircle as te, mdiChevronDown as oe, mdiMagnify as ae, mdiMenu as le } from "@mdi/js";
3
3
  import re from "numeral";
4
4
  import ie from "../KvMaterialIcon.js";
@@ -9,7 +9,7 @@ import { throttle as ve } from "../../utils/throttle.js";
9
9
  import { isLegacyPlaceholderAvatar as se } from "../../utils/imageUtils.js";
10
10
  import "./KvHeaderLinkBar.css";
11
11
  import ce from "../../_virtual/_plugin-vue_export-helper.js";
12
- const we = k(() => import("./KvHeaderMobileMenu.js")), V = k(() => import("./KvHeaderMyKivaMenu.js")), fe = k(() => import("./LendMenu/KvLendMenu.js")), Me = k(() => import("./KvHeaderTakeActionMenu.js")), ke = k(() => import("./KvHeaderAboutMenu.js")), B = 120, M = "avatar-menu", K = "menuButton", R = { top: "-3.75rem", width: "100%" }, F = "lendButton", ge = {
12
+ const we = k(() => import("./KvHeaderMobileMenu.js")), F = k(() => import("./KvHeaderMyKivaMenu.js")), fe = k(() => import("./LendMenu/KvLendMenu.js")), Me = k(() => import("./KvHeaderTakeActionMenu.js")), ke = k(() => import("./KvHeaderAboutMenu.js")), K = 120, M = "avatar-menu", N = "menuButton", z = { top: "-3.75rem", width: "100%" }, A = "lendButton", he = {
13
13
  components: {
14
14
  KvMaterialIcon: ie,
15
15
  KvIconBag: de,
@@ -58,58 +58,62 @@ const we = k(() => import("./KvHeaderMobileMenu.js")), V = k(() => import("./KvH
58
58
  "item-hover"
59
59
  ],
60
60
  setup(l, { emit: n }) {
61
- const a = r(null), e = r(null), N = r(null), O = r(null), g = r(null), c = r(null), A = r(null), I = r(null), d = r(null), t = r(null), z = Y("$kvTrackEvent"), u = (o, v, m = null) => {
61
+ const a = r(null), e = r(null), O = r(null), E = r(null), h = r(null), c = r(null), I = r(null), L = r(null), d = r(null), t = r(null), D = Y("$kvTrackEvent"), u = (o, v, m = null) => {
62
62
  n("item-hover", o, v, m);
63
63
  }, W = (o, v, m = null) => {
64
- navigator.maxTouchPoints || (t.value = o, u(
64
+ navigator.maxTouchPoints || (o === A && t.value !== A && D(
65
+ "TopNav",
66
+ "hover-Lend-menu",
67
+ "Lend"
68
+ ), t.value = o, u(
65
69
  o,
66
70
  v,
67
- o === K && l.isMobile ? R : m
71
+ o === N && l.isMobile ? z : m
68
72
  ));
69
73
  }, j = (o) => {
70
74
  !navigator.maxTouchPoints && t.value === o && (t.value = null, u());
71
- }, E = () => {
72
- var S;
73
- const o = (S = a.value) == null ? void 0 : S.getBoundingClientRect();
75
+ }, S = () => {
76
+ var _;
77
+ const o = (_ = a.value) == null ? void 0 : _.getBoundingClientRect();
74
78
  if (!o) return null;
75
- const m = o.left + o.width / 2 - B / 2;
79
+ const m = o.left + o.width / 2 - K / 2;
76
80
  return {
77
- ...m + B > window.innerWidth ? { right: 0 } : { left: l.isMobile ? 0 : `${m}px` },
81
+ ...m + K > window.innerWidth ? { right: 0 } : { left: l.isMobile ? 0 : `${m}px` },
78
82
  marginTop: "-2px",
79
83
  // Avoid closing avatar menu on header edge
80
84
  borderRadius: l.isMobile ? "auto" : "0px 0px 8px 8px",
81
- width: l.isMobile ? "100%" : `${B}px`
85
+ width: l.isMobile ? "100%" : `${K}px`
82
86
  };
83
- }, h = () => {
84
- t.value = M, u(a.value, V, E());
87
+ }, g = () => {
88
+ t.value = M, u(a.value, F, S());
85
89
  }, q = (o, v, m) => {
86
- o === F && t.value !== F && z(
90
+ o === A && t.value !== A && D(
87
91
  "TopNav",
88
92
  "hover-Lend-menu",
89
93
  "Lend"
90
- ), t.value === K && (t.value = null), !t.value || t.value !== o ? (t.value = o, o === M ? h() : o === K && l.isMobile ? u(o, v, R) : u(o, v, m)) : (t.value = null, u());
91
- }, D = ve(() => {
92
- t.value === M && h();
94
+ ), t.value === N && (t.value = null), !t.value || t.value !== o ? (t.value = o, o === M ? g() : o === N && l.isMobile ? u(o, v, z) : u(o, v, m)) : (t.value = null, u());
95
+ }, C = ve(() => {
96
+ t.value === M && g();
93
97
  }, 100), G = x(() => l.isMobile ? void 0 : "/lend-by-category"), J = x(() => {
94
98
  var o;
95
99
  return ((o = l.lenderImageUrl) == null ? void 0 : o.split("/").pop()) ?? "";
96
100
  }), Q = x(() => Math.floor(l.balance)), X = (o) => {
97
101
  o.target === o.currentTarget && u();
98
102
  };
99
- return C(
103
+ return P(
100
104
  () => l.isMobile,
101
105
  () => {
102
- t.value === M && h();
106
+ t.value === M && g();
103
107
  }
104
- ), C(
108
+ ), P(
105
109
  () => l.openMenuItem,
106
110
  (o) => {
107
111
  o || (t.value = null);
108
112
  }
109
113
  ), Z(() => {
110
- import("./KvHeaderMobileMenu.js"), import("./KvHeaderMyKivaMenu.js"), import("./LendMenu/KvLendMenu.js"), import("./KvHeaderTakeActionMenu.js"), import("./KvHeaderAboutMenu.js"), window.addEventListener("resize", D);
114
+ import("./KvHeaderMobileMenu.js"), import("./KvHeaderMyKivaMenu.js"), import("./LendMenu/KvLendMenu.js"), import("./KvHeaderTakeActionMenu.js"), import("./KvHeaderAboutMenu.js"), window.addEventListener("resize", C);
111
115
  }), $(() => {
112
- window.removeEventListener("resize", D);
116
+ window.removeEventListener("resize", C);
113
117
  }), {
114
118
  AVATAR_MENU_ID: M,
115
119
  openMenuId: t,
@@ -121,33 +125,33 @@ const we = k(() => import("./KvHeaderMobileMenu.js")), V = k(() => import("./KvH
121
125
  onHover: u,
122
126
  avatar: a,
123
127
  lendButton: e,
124
- aboutUsLink: N,
125
- partnerWithUsLink: O,
126
- borrowLink: g,
128
+ aboutUsLink: O,
129
+ partnerWithUsLink: E,
130
+ borrowLink: h,
127
131
  supportKivaLink: c,
128
- basketLink: A,
129
- signInLink: I,
132
+ basketLink: I,
133
+ signInLink: L,
130
134
  menuButton: d,
131
135
  lendUrl: G,
132
136
  avatarFilename: J,
133
137
  handleOnHover: W,
134
138
  handleTouchStart: q,
135
139
  handleMouseOut: j,
136
- handleAvatarMenuPosition: h,
140
+ handleAvatarMenuPosition: g,
137
141
  KvHeaderMobileMenu: we,
138
- KvHeaderMyKivaMenu: V,
142
+ KvHeaderMyKivaMenu: F,
139
143
  KvLendMenu: fe,
140
144
  KvHeaderTakeActionMenu: Me,
141
145
  KvHeaderAboutMenu: ke,
142
146
  isLegacyPlaceholderAvatar: se,
143
- getAvatarMenuPosition: E,
147
+ getAvatarMenuPosition: S,
144
148
  handleEmptySpaceClick: X,
145
149
  roundedBalance: Q
146
150
  };
147
151
  }
148
- }, he = ["href"], be = { class: "tw-text-eco-green-4" }, pe = ["href"];
149
- function ye(l, n, a, e, N, O) {
150
- const g = b("kv-material-icon"), c = b("KvHeaderDropdownLink"), A = b("kv-icon-bag"), I = b("KvUserAvatar"), d = ee("kv-track-event");
152
+ }, ge = ["href"], be = { class: "tw-text-eco-green-4" }, pe = ["href"];
153
+ function Te(l, n, a, e, O, E) {
154
+ const h = b("kv-material-icon"), c = b("KvHeaderDropdownLink"), I = b("kv-icon-bag"), L = b("KvUserAvatar"), d = ee("kv-track-event");
151
155
  return i(), w("div", {
152
156
  class: "tw-h-full tw-flex tw-items-center tw-gap-0.5 md:tw-gap-2 lg:tw-gap-2.5",
153
157
  onTouchstart: n[10] || (n[10] = (...t) => e.handleEmptySpaceClick && e.handleEmptySpaceClick(...t))
@@ -161,11 +165,11 @@ function ye(l, n, a, e, N, O) {
161
165
  onMouseout: n[1] || (n[1] = (t) => e.handleMouseOut("menuButton")),
162
166
  onTouchstart: n[2] || (n[2] = H((t) => e.handleTouchStart("menuButton", e.KvHeaderMobileMenu), ["stop"]))
163
167
  }, [
164
- L(g, { icon: e.mdiMenu }, null, 8, ["icon"])
168
+ U(h, { icon: e.mdiMenu }, null, 8, ["icon"])
165
169
  ], 34)), [
166
170
  [d, a.openMenuItem === e.KvHeaderMobileMenu ? ["TopNav", "click-Hamburger-menu"] : null]
167
171
  ]),
168
- s((i(), y(c, {
172
+ s((i(), T(c, {
169
173
  class: "tw-py-1",
170
174
  "ref-name": "lendButton",
171
175
  href: e.lendUrl,
@@ -174,17 +178,17 @@ function ye(l, n, a, e, N, O) {
174
178
  "dropdown-icon": e.mdiChevronDown,
175
179
  "base-class": "tw-inline-flex md:tw-border md:tw-rounded-md tw-px-1.5 tw-py-1",
176
180
  onOnHover: e.handleOnHover,
177
- onMouseout: n[3] || (n[3] = (t) => e.handleMouseOut("lendButton")),
181
+ onMouseleave: n[3] || (n[3] = (t) => e.handleMouseOut("lendButton")),
178
182
  onTouchstart: n[4] || (n[4] = H((t) => e.handleTouchStart("lendButton", e.KvLendMenu), ["stop"]))
179
183
  }, {
180
- default: U(() => n[11] || (n[11] = [
184
+ default: B(() => n[11] || (n[11] = [
181
185
  f(" Lend ")
182
186
  ])),
183
187
  _: 1
184
188
  }, 8, ["href", "menu-component", "open-menu-item", "dropdown-icon", "onOnHover"])), [
185
189
  [d, ["TopNav", "click-Lend"]]
186
190
  ]),
187
- s((i(), y(c, {
191
+ s((i(), T(c, {
188
192
  "ref-name": "takeActionButton",
189
193
  "base-class": "tw-hidden md:tw-inline-flex tw-py-1",
190
194
  "menu-component": e.KvHeaderTakeActionMenu,
@@ -192,17 +196,17 @@ function ye(l, n, a, e, N, O) {
192
196
  "dropdown-icon": e.mdiChevronDown,
193
197
  "send-link-position": "",
194
198
  onOnHover: e.handleOnHover,
195
- onMouseout: n[5] || (n[5] = (t) => e.handleMouseOut("takeActionButton")),
199
+ onMouseleave: n[5] || (n[5] = (t) => e.handleMouseOut("takeActionButton")),
196
200
  onUserTap: e.handleTouchStart
197
201
  }, {
198
- default: U(() => n[12] || (n[12] = [
202
+ default: B(() => n[12] || (n[12] = [
199
203
  f(" Take action ")
200
204
  ])),
201
205
  _: 1
202
206
  }, 8, ["menu-component", "open-menu-item", "dropdown-icon", "onOnHover", "onUserTap"])), [
203
207
  [d, ["TopNav", "click-take-action"]]
204
208
  ]),
205
- L(c, {
209
+ U(c, {
206
210
  "ref-name": "aboutUsLink",
207
211
  "data-testid": "header-about",
208
212
  "base-class": "tw-hidden md:tw-inline-flex tw-py-1",
@@ -211,15 +215,15 @@ function ye(l, n, a, e, N, O) {
211
215
  "dropdown-icon": e.mdiChevronDown,
212
216
  "send-link-position": "",
213
217
  onOnHover: e.handleOnHover,
214
- onMouseout: n[6] || (n[6] = (t) => e.handleMouseOut("aboutUsLink")),
218
+ onMouseleave: n[6] || (n[6] = (t) => e.handleMouseOut("aboutUsLink")),
215
219
  onUserTap: e.handleTouchStart
216
220
  }, {
217
- default: U(() => n[13] || (n[13] = [
221
+ default: B(() => n[13] || (n[13] = [
218
222
  f(" About ")
219
223
  ])),
220
224
  _: 1
221
225
  }, 8, ["menu-component", "open-menu-item", "dropdown-icon", "onOnHover", "onUserTap"]),
222
- n[17] || (n[17] = T("div", { class: "tw-flex-1 tw-h-full" }, null, -1)),
226
+ n[17] || (n[17] = y("div", { class: "tw-flex-1 tw-h-full" }, null, -1)),
223
227
  a.loggedIn ? s((i(), w("a", {
224
228
  key: 0,
225
229
  ref: "dashboardLink",
@@ -227,9 +231,9 @@ function ye(l, n, a, e, N, O) {
227
231
  class: p(["header-link tw-hidden md:tw-block", { "tw-text-tertiary": !!a.openMenuItem }])
228
232
  }, n[14] || (n[14] = [
229
233
  f(" My dashboard ")
230
- ]), 10, he)), [
234
+ ]), 10, ge)), [
231
235
  [d, ["TopNav", "click-Dashboard"]]
232
- ]) : _("", !0),
236
+ ]) : V("", !0),
233
237
  s((i(), w("a", {
234
238
  ref: "basketLink",
235
239
  href: "/basket",
@@ -237,38 +241,38 @@ function ye(l, n, a, e, N, O) {
237
241
  style: { "margin-right": "2px" },
238
242
  "data-testid": "header-basket"
239
243
  }, [
240
- L(A, {
244
+ U(I, {
241
245
  class: "tw-w-3 tw-h-3 md:tw-w-3.5 md:tw-h-3.5 tw-pointer-events-none",
242
246
  count: a.basketCount
243
247
  }, null, 8, ["count"]),
244
- n[15] || (n[15] = T("span", { class: "tw-hidden md:tw-block" }, "Basket", -1))
248
+ n[15] || (n[15] = y("span", { class: "tw-hidden md:tw-block" }, "Basket", -1))
245
249
  ], 2)), [
246
- [P, a.basketCount > 0],
250
+ [R, a.basketCount > 0],
247
251
  [d, ["TopNav", "click-Basket"]]
248
252
  ]),
249
- s(T("div", {
253
+ s(y("div", {
250
254
  ref: "avatar",
251
255
  class: "tw-cursor-pointer tw-flex tw-items-center tw-gap-1 tw-bg-eco-green-1 tw-rounded-md tw-py-0.5 md:tw-py-1 tw-px-1 md:tw-px-2",
252
256
  onMouseover: n[7] || (n[7] = (t) => e.handleOnHover(e.AVATAR_MENU_ID, e.KvHeaderMyKivaMenu, e.getAvatarMenuPosition())),
253
257
  onMouseout: n[8] || (n[8] = (t) => e.handleMouseOut(e.AVATAR_MENU_ID)),
254
258
  onTouchstart: n[9] || (n[9] = H((t) => e.handleTouchStart(e.AVATAR_MENU_ID), ["stop"]))
255
259
  }, [
256
- e.isLegacyPlaceholderAvatar(e.avatarFilename) || !e.avatarFilename ? (i(), y(g, {
260
+ e.isLegacyPlaceholderAvatar(e.avatarFilename) || !e.avatarFilename ? (i(), T(h, {
257
261
  key: 0,
258
262
  icon: e.mdiAccountCircle,
259
263
  class: "tw-w-3"
260
- }, null, 8, ["icon"])) : (i(), y(I, {
264
+ }, null, 8, ["icon"])) : (i(), T(L, {
261
265
  key: 1,
262
266
  class: "avatar",
263
267
  "lender-name": a.lenderName,
264
268
  "lender-image-url": a.lenderImageUrl,
265
269
  "is-small": ""
266
270
  }, null, 8, ["lender-name", "lender-image-url"])),
267
- T("span", be, ne(e.numeral(e.roundedBalance).format("$0")), 1)
271
+ y("span", be, ne(e.numeral(e.roundedBalance).format("$0")), 1)
268
272
  ], 544), [
269
- [P, a.loggedIn]
273
+ [R, a.loggedIn]
270
274
  ]),
271
- a.loggedIn ? _("", !0) : s((i(), w("a", {
275
+ a.loggedIn ? V("", !0) : s((i(), w("a", {
272
276
  key: 1,
273
277
  ref: "signInLink",
274
278
  href: a.loginUrl,
@@ -280,7 +284,7 @@ function ye(l, n, a, e, N, O) {
280
284
  ])
281
285
  ], 32);
282
286
  }
283
- const De = /* @__PURE__ */ ce(ge, [["render", ye], ["__scopeId", "data-v-d33b2f4e"]]);
287
+ const De = /* @__PURE__ */ ce(he, [["render", Te], ["__scopeId", "data-v-0420196f"]]);
284
288
  export {
285
289
  De as default
286
290
  };
@@ -1 +1 @@
1
- .header-fade-enter-active[data-v-8d56e82f]{transition-property:opacity;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.3s}.header-fade-leave-active[data-v-8d56e82f]{transition-property:opacity;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.1s}.header-fade-enter[data-v-8d56e82f],.header-fade-leave-to[data-v-8d56e82f]{opacity:0}.header-fade-leave[data-v-8d56e82f],.header-fade-enter-to[data-v-8d56e82f]{opacity:1}.bg-opacity-50[data-v-8d56e82f]{background-color:rgba(var(--bg-action-highlight),.5)}
1
+ .header-fade-enter-active[data-v-57d0ee01]{transition-property:opacity;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.3s}.header-fade-leave-active[data-v-57d0ee01]{transition-property:opacity;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.1s}.header-fade-enter[data-v-57d0ee01],.header-fade-leave-to[data-v-57d0ee01]{opacity:0}.header-fade-leave[data-v-57d0ee01],.header-fade-enter-to[data-v-57d0ee01]{opacity:1}.bg-opacity-50[data-v-57d0ee01]{background-color:rgba(var(--bg-action-highlight),.5)}
@@ -1,18 +1,19 @@
1
- import { ref as a, shallowRef as N, computed as B, onMounted as S, onBeforeUnmount as x, resolveComponent as g, resolveDirective as A, openBlock as w, createBlock as E, withCtx as b, createElementVNode as k, normalizeStyle as h, createVNode as v, Transition as I, withDirectives as y, vShow as T, createElementBlock as K, normalizeClass as O, resolveDynamicComponent as G, withModifiers as z } from "vue";
2
- import P from "@kiva/kv-tokens";
3
- import R from "./KvWwwHeader/KvHeaderLinkBar.js";
4
- import V from "./KvWwwHeader/KvHeaderLogo.js";
5
- import W from "./KvThemeProvider.js";
6
- import Y from "./KvPageContainer.js";
7
- import { throttle as j } from "../utils/throttle.js";
1
+ import { ref as l, shallowRef as B, computed as S, onMounted as x, onBeforeUnmount as A, resolveComponent as g, resolveDirective as K, openBlock as w, createBlock as I, withCtx as b, createElementVNode as k, normalizeStyle as h, createVNode as v, Transition as C, withDirectives as y, vShow as T, createElementBlock as O, normalizeClass as G, resolveDynamicComponent as z, withModifiers as P } from "vue";
2
+ import R from "@kiva/kv-tokens";
3
+ import V from "./KvWwwHeader/KvHeaderLinkBar.js";
4
+ import W from "./KvWwwHeader/KvHeaderLogo.js";
5
+ import Y from "./KvThemeProvider.js";
6
+ import j from "./KvPageContainer.js";
7
+ import { throttle as q } from "../utils/throttle.js";
8
+ import { debounce as F } from "../utils/debounce.js";
8
9
  import "./KvWwwHeader.css";
9
- import q from "../_virtual/_plugin-vue_export-helper.js";
10
- const F = "3.75rem", J = ["lendMenu", "aboutUsLink"], Q = {
10
+ import J from "../_virtual/_plugin-vue_export-helper.js";
11
+ const Q = "3.75rem", X = ["lendMenu", "aboutUsLink"], Z = {
11
12
  components: {
12
- KvHeaderLinkBar: R,
13
- KvHeaderLogo: V,
14
- KvThemeProvider: W,
15
- KvPageContainer: Y
13
+ KvHeaderLinkBar: V,
14
+ KvHeaderLogo: W,
15
+ KvThemeProvider: Y,
16
+ KvPageContainer: j
16
17
  },
17
18
  props: {
18
19
  loggedIn: {
@@ -67,56 +68,56 @@ const F = "3.75rem", J = ["lendMenu", "aboutUsLink"], Q = {
67
68
  emits: [
68
69
  "load-lend-menu-data"
69
70
  ],
70
- setup(C, { emit: o }) {
71
- const n = a(!0), e = a(null), r = a(!1), i = N(null), u = a(null), d = a({ left: 0, position: "relative" }), m = a(!1), c = a(null);
72
- let f;
73
- const l = B(() => {
71
+ setup(L, { emit: o }) {
72
+ const n = l(!0), e = l(null), a = l(!1), i = B(null), u = l(null), d = l({ left: 0, position: "relative" }), m = l(!1), c = l(null), f = l(!1);
73
+ let r;
74
+ const _ = S(() => {
74
75
  var s, t;
75
76
  return ((t = (s = u.value) == null ? void 0 : s.$options) == null ? void 0 : t.name) === "KvHeaderMobileMenu";
76
- }), _ = (s, t, p) => {
77
- t ? (c.value = s, clearTimeout(f), i.value !== t && (d.value = { left: 0, position: "relative" }), i.value = t, r.value = !0, p && (d.value = {
78
- ...p,
77
+ }), M = F((s, t, E) => {
78
+ f.value && (t ? (c.value = s, clearTimeout(r), i.value !== t && (d.value = { left: 0, position: "relative" }), i.value = t, a.value = !0, E && (d.value = {
79
+ ...E,
79
80
  position: "absolute"
80
- })) : r.value && (f = setTimeout(() => {
81
- r.value = !1, i.value = null;
82
- }, 100));
83
- }, L = (s) => {
81
+ })) : a.value && (r = setTimeout(() => {
82
+ a.value = !1, i.value = null;
83
+ }, 100)));
84
+ }, 50), U = (s) => {
84
85
  var t;
85
86
  (t = u.value) == null || t.onLoad(s);
86
- }, U = () => {
87
- if (!l.value) return _();
88
87
  }, D = () => {
88
+ if (!_.value) return M();
89
+ }, N = () => {
89
90
  o("load-lend-menu-data");
90
- }, M = () => {
91
- m.value = (window == null ? void 0 : window.innerWidth) < P.breakpoints.md, m.value && J.includes(c.value) && (i.value = null, r.value = !1);
92
- }, H = j(M, 100);
93
- return S(() => {
94
- M(), window.addEventListener("resize", H);
95
- }), x(() => {
91
+ }, p = () => {
92
+ m.value = (window == null ? void 0 : window.innerWidth) < R.breakpoints.md, m.value && X.includes(c.value) && (i.value = null, a.value = !1);
93
+ }, H = q(p, 100);
94
+ return x(() => {
95
+ p(), window.addEventListener("resize", H), f.value = !0;
96
+ }), A(() => {
96
97
  window.removeEventListener("resize", H);
97
98
  }), {
98
- HEADER_HEIGHT: F,
99
- emitLendMenuEvent: D,
99
+ HEADER_HEIGHT: Q,
100
+ emitLendMenuEvent: N,
100
101
  isMobile: m,
101
102
  linksVisible: n,
102
- menuOpen: r,
103
- isMobileMenuActive: l,
104
- onHover: _,
105
- loadMenuData: L,
106
- handleOverlayClick: U,
103
+ menuOpen: a,
104
+ isMobileMenuActive: _,
105
+ onHover: M,
106
+ loadMenuData: U,
107
+ handleOverlayClick: D,
107
108
  activeHeaderItem: e,
108
109
  menuComponent: i,
109
110
  menuComponentInstance: u,
110
111
  menuPosition: d
111
112
  };
112
113
  }
113
- }, X = {
114
+ }, $ = {
114
115
  href: "/",
115
116
  class: "tw-px-1 tw-py-2 tw-cursor-pointer tw-absolute tw-top-1/2 tw-left-1/2 tw--translate-y-1/2 tw--translate-x-1/2 tw-transition-all tw-duration-300"
116
117
  };
117
- function Z(C, o, n, e, r, i) {
118
- const u = g("kv-header-link-bar"), d = g("kv-header-logo"), m = g("kv-page-container"), c = g("kv-theme-provider"), f = A("kv-track-event");
119
- return w(), E(c, {
118
+ function ee(L, o, n, e, a, i) {
119
+ const u = g("kv-header-link-bar"), d = g("kv-header-logo"), m = g("kv-page-container"), c = g("kv-theme-provider"), f = K("kv-track-event");
120
+ return w(), I(c, {
120
121
  tag: "div",
121
122
  class: "tw-bg-primary"
122
123
  }, {
@@ -127,7 +128,7 @@ function Z(C, o, n, e, r, i) {
127
128
  }, [
128
129
  v(m, null, {
129
130
  default: b(() => [
130
- v(I, { name: "header-fade" }, {
131
+ v(C, { name: "header-fade" }, {
131
132
  default: b(() => [
132
133
  y(v(u, {
133
134
  "logged-in": n.loggedIn,
@@ -146,7 +147,7 @@ function Z(C, o, n, e, r, i) {
146
147
  ]),
147
148
  _: 1
148
149
  }),
149
- y((w(), K("a", X, [
150
+ y((w(), O("a", $, [
150
151
  v(d)
151
152
  ])), [
152
153
  [f, ["TopNav", "click-Logo"]]
@@ -155,23 +156,23 @@ function Z(C, o, n, e, r, i) {
155
156
  _: 1
156
157
  })
157
158
  ], 4),
158
- v(I, { name: "header-fade" }, {
159
+ v(C, { name: "header-fade" }, {
159
160
  default: b(() => [
160
161
  y(k("div", {
161
162
  class: "tw-absolute tw-z-modal tw-h-full tw-inset-x-0 tw-bg-eco-green-4 bg-opacity-50 tw-min-h-screen",
162
163
  style: h({ top: e.HEADER_HEIGHT }),
163
- onTouchstart: o[4] || (o[4] = (...l) => e.handleOverlayClick && e.handleOverlayClick(...l))
164
+ onTouchstart: o[4] || (o[4] = (...r) => e.handleOverlayClick && e.handleOverlayClick(...r))
164
165
  }, [
165
166
  k("div", {
166
- class: O(["tw-bg-primary tw-overflow-y-auto", { "tw-min-h-dvh": e.isMobileMenuActive }]),
167
+ class: G(["tw-bg-primary tw-overflow-y-auto", { "tw-min-h-dvh": e.isMobileMenuActive }]),
167
168
  style: h({
168
169
  ...e.menuPosition,
169
170
  maxHeight: e.isMobileMenuActive ? "auto" : `calc(100dvh - ${e.HEADER_HEIGHT})`
170
171
  }),
171
- onMouseover: o[2] || (o[2] = (l) => e.onHover(e.activeHeaderItem, e.menuComponent)),
172
- onMouseout: o[3] || (o[3] = (l) => e.onHover())
172
+ onMouseover: o[2] || (o[2] = (r) => e.onHover(e.activeHeaderItem, e.menuComponent)),
173
+ onMouseout: o[3] || (o[3] = (r) => e.onHover())
173
174
  }, [
174
- (w(), E(G(e.menuComponent), {
175
+ (w(), I(z(e.menuComponent), {
175
176
  ref: "menuComponentInstance",
176
177
  "logged-in": n.loggedIn,
177
178
  "login-url": n.loginUrl,
@@ -183,8 +184,8 @@ function Z(C, o, n, e, r, i) {
183
184
  "is-mobile": e.isMobile,
184
185
  "countries-not-lent-to-url": n.countriesNotLentToUrl,
185
186
  onLoadLendMenuData: e.emitLendMenuEvent,
186
- onClosingMenu: o[0] || (o[0] = (l) => e.onHover()),
187
- onTouchstart: o[1] || (o[1] = z(() => {
187
+ onClosingMenu: o[0] || (o[0] = (r) => e.onHover()),
188
+ onTouchstart: o[1] || (o[1] = P(() => {
188
189
  }, ["stop"]))
189
190
  }, null, 40, ["logged-in", "login-url", "user-id", "is-borrower", "is-trustee", "my-dashboard-url", "show-m-g-upsell-link", "is-mobile", "countries-not-lent-to-url", "onLoadLendMenuData"]))
190
191
  ], 38)
@@ -198,7 +199,7 @@ function Z(C, o, n, e, r, i) {
198
199
  _: 1
199
200
  });
200
201
  }
201
- const se = /* @__PURE__ */ q(Q, [["render", Z], ["__scopeId", "data-v-8d56e82f"]]);
202
+ const me = /* @__PURE__ */ J(Z, [["render", ee], ["__scopeId", "data-v-57d0ee01"]]);
202
203
  export {
203
- se as default
204
+ me as default
204
205
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kiva/kv-components",
3
- "version": "6.62.0",
3
+ "version": "6.62.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": "e0ac2f7a901efa25536b185c77d9371e41c21dcd"
117
+ "gitHead": "ed195d6675eadc89322ba07cc8b73b83a6286432"
118
118
  }