@kiva/kv-components 5.3.5 → 5.3.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1 +1 @@
1
- .screen[data-v-50691313]{position:fixed;top:0;right:0;bottom:0;left:0;z-index:1400;background-color:#0003}.modal[data-v-50691313]{width:100%;border-bottom-right-radius:.875rem;border-bottom-left-radius:.875rem;--tw-bg-opacity: 1;background-color:rgba(var(--bg-primary),var(--tw-bg-opacity, 1))}@media (min-width: 45.875rem){.modal[data-v-50691313]{position:absolute;right:0}}.modal[data-v-50691313]{max-height:90%}.modal__body[data-v-50691313]{display:flex;gap:1rem;padding-left:1.25rem;padding-right:1.25rem}@media (min-width: 45.875rem){.modal__body[data-v-50691313]{padding-left:2rem;padding-right:2rem}}.modal__body[data-v-50691313]{height:3.75rem}.loan-image[data-v-50691313]{width:3.75rem}.container[data-v-50691313]{position:absolute;top:0;right:0;bottom:0;left:0}@media (min-width: 45.875rem){.modal[data-v-50691313]{max-width:24.5rem}}
1
+ .screen[data-v-faf9d7e4]{position:fixed;top:0;right:0;bottom:0;left:0;z-index:1400;background-color:#0003}.modal[data-v-faf9d7e4]{width:100%;border-bottom-right-radius:.875rem;border-bottom-left-radius:.875rem;--tw-bg-opacity: 1;background-color:rgba(var(--bg-primary),var(--tw-bg-opacity, 1))}@media (min-width: 45.875rem){.modal[data-v-faf9d7e4]{position:absolute;right:0}}.modal[data-v-faf9d7e4]{max-height:90%}.modal__body[data-v-faf9d7e4]{display:flex;gap:1rem;padding-left:1.25rem;padding-right:1.25rem}@media (min-width: 45.875rem){.modal__body[data-v-faf9d7e4]{padding-left:2rem;padding-right:2rem}}.container[data-v-faf9d7e4]{position:absolute;top:0;right:0;bottom:0;left:0}@media (min-width: 45.875rem){.modal[data-v-faf9d7e4]{max-width:24.5rem}}
@@ -1,19 +1,17 @@
1
- import { toRefs as P, ref as b, computed as d, watch as j, onMounted as K, onBeforeUnmount as R, resolveComponent as C, openBlock as x, createBlock as V, Transition as L, withCtx as g, withDirectives as F, createElementVNode as o, withModifiers as y, renderSlot as O, createVNode as w, createElementBlock as A, createCommentVNode as D, toDisplayString as f, createTextVNode as I, vShow as H, nextTick as U } from "vue";
2
- import { mdiClose as q, mdiCheckCircle as z } from "@mdi/js";
3
- import { useFocusTrap as G } from "@vueuse/integrations/useFocusTrap";
4
- import { hideOthers as J } from "../vendor/aria-hidden/dist/es2015/index.js";
5
- import { unlockScroll as Q, lockScroll as W } from "../utils/scrollLock.js";
6
- import { unlockPrintSingleEl as X, lockPrintSingleEl as Y } from "../utils/printing.js";
7
- import Z from "./KvButton.js";
8
- import $ from "./KvMaterialIcon.js";
9
- import tt from "./KvBorrowerImage.js";
1
+ import { toRefs as B, ref as f, computed as S, watch as M, onMounted as E, onBeforeUnmount as T, resolveComponent as C, openBlock as y, createBlock as N, Transition as V, withCtx as b, withDirectives as K, createElementVNode as e, withModifiers as p, renderSlot as x, createVNode as k, createElementBlock as F, createCommentVNode as I, createTextVNode as P, toDisplayString as R, vShow as j, nextTick as A } from "vue";
2
+ import { mdiClose as D, mdiCheckCircle as L } from "@mdi/js";
3
+ import { useFocusTrap as O } from "@vueuse/integrations/useFocusTrap";
4
+ import { hideOthers as U } from "../vendor/aria-hidden/dist/es2015/index.js";
5
+ import { unlockScroll as q, lockScroll as z } from "../utils/scrollLock.js";
6
+ import { unlockPrintSingleEl as G, lockPrintSingleEl as H } from "../utils/printing.js";
7
+ import J from "./KvButton.js";
8
+ import Q from "./KvMaterialIcon.js";
10
9
  import "./KvCartModal.css";
11
- import et from "../_virtual/_plugin-vue_export-helper.js";
12
- const ot = {
10
+ import W from "../_virtual/_plugin-vue_export-helper.js";
11
+ const X = {
13
12
  components: {
14
- KvMaterialIcon: $,
15
- KvButton: Z,
16
- KvBorrowerImage: tt
13
+ KvMaterialIcon: Q,
14
+ KvButton: J
17
15
  },
18
16
  props: {
19
17
  /**
@@ -37,101 +35,69 @@ const ot = {
37
35
  basketCount: {
38
36
  type: Number,
39
37
  default: 0
40
- },
41
- /**
42
- * The loan added to the basket
43
- * */
44
- addedLoan: {
45
- type: Object,
46
- default: () => ({})
47
- },
48
- /**
49
- * The photo path for the borrower image
50
- * */
51
- photoPath: {
52
- type: String,
53
- default: ""
54
38
  }
55
39
  },
56
40
  emits: [
57
41
  "cart-modal-closed"
58
42
  ],
59
- setup(p, { emit: t }) {
43
+ setup(c, { emit: t }) {
60
44
  const {
61
- visible: a,
62
- preventClose: e,
63
- addedLoan: i
64
- } = P(p), c = b(null), n = b(null), k = b(null), m = d(() => [
65
- c.value
45
+ visible: l,
46
+ preventClose: o
47
+ } = B(c), s = f(null), n = f(null), d = f(null), m = S(() => [
48
+ s.value
66
49
  // This cart modal
67
50
  ]), {
68
51
  activate: r,
69
- deactivate: B
70
- } = G(m, {
52
+ deactivate: h
53
+ } = O(m, {
71
54
  allowOutsideClick: !0
72
55
  // allow clicking outside the cart modal to close it
73
56
  });
74
57
  let u = null, v = null;
75
- const s = (l = "") => {
76
- c.value && n.value && (B(), n.value.scrollTop = 0, X(n.value)), Q(), u && (u(), u = null), document.removeEventListener("keyup", v), t("cart-modal-closed", { type: l });
58
+ const a = (i = "") => {
59
+ s.value && n.value && (h(), n.value.scrollTop = 0, G(n.value)), q(), u && (u(), u = null), document.removeEventListener("keyup", v), t("cart-modal-closed", { type: i });
77
60
  };
78
- v = (l) => {
79
- l && l.key === "Escape" && !e.value && s();
61
+ v = (i) => {
62
+ i && i.key === "Escape" && !o.value && a();
80
63
  };
81
- const S = () => {
82
- e.value || s("background");
83
- }, h = () => {
84
- a.value && (document.addEventListener("keyup", v), U(() => {
85
- c.value && n.value && (r(), u = J(c.value), Y(n.value)), W();
64
+ const _ = () => {
65
+ o.value || a("background");
66
+ }, w = () => {
67
+ l.value && (document.addEventListener("keyup", v), A(() => {
68
+ s.value && n.value && (r(), u = U(s.value), H(n.value)), z();
86
69
  }));
87
- }, _ = d(() => {
88
- var l;
89
- return ((l = i.value) == null ? void 0 : l.name) ?? "";
90
- }), M = d(() => ({
91
- alt: `Photo of ${_.value}`,
92
- aspectRatio: 1,
93
- defaultImage: { width: 300 },
94
- hash: i.value.imageHash,
95
- images: [
96
- {
97
- width: 300
98
- }
99
- ]
100
- })), E = d(() => i.value.country ?? ""), T = d(() => i.value.amount ?? ""), N = (l) => {
101
- s(l);
70
+ }, g = (i) => {
71
+ a(i);
102
72
  };
103
- return j(a, () => {
104
- a.value ? h() : s();
105
- }), K(() => {
106
- a.value && (h(), setTimeout(() => {
73
+ return M(l, () => {
74
+ l.value ? w() : a();
75
+ }), E(() => {
76
+ l.value && (w(), setTimeout(() => {
107
77
  t("cart-modal-closed", { type: "time" });
108
78
  }, 1e4));
109
- }), R(() => s()), {
110
- mdiClose: q,
111
- mdiCheckCircle: z,
79
+ }), T(() => a()), {
80
+ mdiClose: D,
81
+ mdiCheckCircle: L,
112
82
  onKeyUp: v,
113
- onScreenClick: S,
114
- hide: s,
115
- show: h,
116
- controlsRef: k,
117
- handleClick: N,
118
- borrowerName: _,
119
- borrowerImage: M,
120
- borrowerCountry: E,
121
- amount: T
83
+ onScreenClick: _,
84
+ hide: a,
85
+ show: w,
86
+ controlsRef: d,
87
+ handleClick: g
122
88
  };
123
89
  }
124
- }, at = { class: "container" }, lt = { class: "tw-flex tw-p-2.5 md:tw-px-4 md:tw-pt-4 md:tw-pb-3.5" }, nt = { class: "tw-flex tw-flex-grow tw-gap-1 tw-items-center" }, rt = {
90
+ }, Y = { class: "container" }, Z = { class: "tw-flex tw-pt-2 tw-px-2.5" }, $ = { class: "tw-flex tw-flex-grow tw-gap-1 tw-items-center tw-pb-2" }, tt = {
125
91
  id: "kvCartModalBody",
126
92
  ref: "kvCartModalBody",
127
93
  class: "modal__body"
128
- }, st = { class: "tw-flex tw-items-center tw-justify-between tw-w-full tw-gap-1" }, it = { class: "tw-flex tw-flex-col tw-h-full tw-justify-between" }, ct = { class: "tw-overflow-hidden tw-text-ellipsis tw-line-clamp-1" }, dt = { class: "tw-p-1 tw-text-center tw-rounded tw-bg-secondary tw-text-h5 tw-w-max" }, wt = {
94
+ }, et = {
129
95
  ref: "controlsRef",
130
- class: "tw-flex-shrink-0 tw-flex tw-justify-end tw-gap-x-2.5 tw-p-2.5 md:tw-px-4 md:tw-pb-4 tw-flex-col tw-gap-1"
96
+ class: "tw-flex-shrink-0 tw-flex tw-justify-end tw-gap-x-2.5 tw-px-2.5 tw-pb-2 tw-flex-col tw-gap-1"
131
97
  };
132
- function mt(p, t, a, e, i, c) {
133
- const n = C("kv-material-icon"), k = C("kv-borrower-image"), m = C("kv-button");
134
- return x(), V(L, {
98
+ function ot(c, t, l, o, s, n) {
99
+ const d = C("kv-material-icon"), m = C("kv-button");
100
+ return y(), N(V, {
135
101
  "enter-active-class": "tw-transition-opacity tw-duration-300",
136
102
  "leave-active-class": "tw-transition-opacity tw-duration-300",
137
103
  "enter-class": "tw-opacity-0",
@@ -139,97 +105,70 @@ function mt(p, t, a, e, i, c) {
139
105
  "leave-class": "tw-opacity-full",
140
106
  "leave-to-class": "tw-opacity-0"
141
107
  }, {
142
- default: g(() => [
143
- F(o("div", {
108
+ default: b(() => [
109
+ K(e("div", {
144
110
  class: "screen",
145
- onClick: t[4] || (t[4] = y((...r) => e.onScreenClick && e.onScreenClick(...r), ["stop", "prevent"]))
111
+ onClick: t[3] || (t[3] = p((...r) => o.onScreenClick && o.onScreenClick(...r), ["stop", "prevent"]))
146
112
  }, [
147
- o("div", null, [
148
- o("div", at, [
149
- o("div", {
113
+ e("div", null, [
114
+ e("div", Y, [
115
+ e("div", {
150
116
  ref: "kvCartModal",
151
117
  tabindex: "-1",
152
118
  "data-test": "kv-cart-modal",
153
119
  class: "modal",
154
120
  "aria-modal": "true",
155
121
  "aria-label": "Added to basket",
156
- onClick: t[3] || (t[3] = y(() => {
122
+ onClick: t[2] || (t[2] = p(() => {
157
123
  }, ["stop"]))
158
124
  }, [
159
- o("div", lt, [
160
- o("div", nt, [
161
- O(p.$slots, "header", {}, () => [
162
- w(n, {
163
- class: "tw-w-4 tw-h-4 tw-text-brand",
164
- icon: e.mdiCheckCircle
125
+ e("div", Z, [
126
+ e("div", $, [
127
+ x(c.$slots, "header", {}, () => [
128
+ k(d, {
129
+ class: "tw-w-3.5 tw-h-3.5 tw-text-brand",
130
+ icon: o.mdiCheckCircle
165
131
  }, null, 8, ["icon"]),
166
- t[5] || (t[5] = o("p", { class: "tw-flex-1 tw-font-medium" }, " Added to basket ", -1))
132
+ t[4] || (t[4] = e("p", { class: "tw-flex-1 tw-font-medium tw-text-center" }, " Added to basket ", -1))
167
133
  ], !0),
168
- a.preventClose ? D("", !0) : (x(), A("button", {
134
+ l.preventClose ? I("", !0) : (y(), F("button", {
169
135
  key: 0,
170
136
  class: "tw-grid tw-content-center tw-justify-center tw-ml-auto tw-w-6 tw-h-6 tw--m-2 hover:tw-text-action-highlight",
171
- onClick: t[0] || (t[0] = y((r) => e.hide("x-button"), ["stop"]))
137
+ onClick: t[0] || (t[0] = p((r) => o.hide("x-button"), ["stop"]))
172
138
  }, [
173
- w(n, {
174
- class: "tw-w-3 tw-h-3",
175
- icon: e.mdiClose
139
+ k(d, {
140
+ class: "tw-w-3.5 tw-h-3.5",
141
+ icon: o.mdiClose
176
142
  }, null, 8, ["icon"]),
177
- t[6] || (t[6] = o("span", { class: "tw-sr-only" }, "Close", -1))
143
+ t[5] || (t[5] = e("span", { class: "tw-sr-only" }, "Close", -1))
178
144
  ]))
179
145
  ])
180
146
  ]),
181
- o("div", rt, [
182
- o("div", null, [
183
- w(k, {
184
- class: "tw-rounded loan-image",
185
- alt: e.borrowerImage.alt,
186
- "aspect-ratio": e.borrowerImage.aspectRatio,
187
- "default-image": e.borrowerImage.defaultImage,
188
- hash: e.borrowerImage.hash,
189
- images: e.borrowerImage.images,
190
- "photo-path": a.photoPath
191
- }, null, 8, ["alt", "aspect-ratio", "default-image", "hash", "images", "photo-path"])
192
- ]),
193
- o("div", st, [
194
- o("div", it, [
195
- o("p", ct, f(e.borrowerName), 1),
196
- o("p", dt, f(e.borrowerCountry), 1)
197
- ]),
198
- o("p", null, " $" + f(e.amount), 1)
199
- ])
147
+ e("div", tt, [
148
+ x(c.$slots, "content", {}, void 0, !0)
200
149
  ], 512),
201
- o("div", wt, [
202
- w(m, {
150
+ e("div", et, [
151
+ k(m, {
203
152
  class: "tw-w-full",
204
- onClick: t[1] || (t[1] = (r) => e.handleClick("view-basket"))
153
+ onClick: t[1] || (t[1] = (r) => o.handleClick("view-basket"))
205
154
  }, {
206
- default: g(() => [
207
- I(" View basket (" + f(a.basketCount) + ") ", 1)
155
+ default: b(() => [
156
+ P(" View basket (" + R(l.basketCount) + ") ", 1)
208
157
  ]),
209
158
  _: 1
210
- }),
211
- w(m, {
212
- class: "tw-w-full",
213
- variant: "secondary",
214
- onClick: t[2] || (t[2] = (r) => e.handleClick("help-another-person"))
215
- }, {
216
- default: g(() => t[7] || (t[7] = [
217
- I(" Help another person ")
218
- ])),
219
- _: 1
220
159
  })
221
160
  ], 512)
222
161
  ], 512)
223
162
  ])
224
163
  ])
225
164
  ], 512), [
226
- [H, a.visible]
165
+ [j, l.visible]
227
166
  ])
228
167
  ]),
229
168
  _: 3
230
169
  });
231
170
  }
232
- const xt = /* @__PURE__ */ et(ot, [["render", mt], ["__scopeId", "data-v-50691313"]]);
171
+ const mt = /* @__PURE__ */ W(X, [["render", ot], ["__scopeId", "data-v-faf9d7e4"]]);
233
172
  export {
234
- xt as default
173
+ mt as default
235
174
  };
@@ -1 +1 @@
1
- .amountDropdownWrapper[data-v-62cf823a] select{border-radius:14px 0 0 14px}.lend-again[data-v-62cf823a] span{padding-left:0;padding-right:0;padding-left:.5rem;padding-right:.5rem}.lendButtonWrapper[data-v-62cf823a] span:first-child{border-radius:0 14px 14px 0}.filtered-dropdown[data-v-62cf823a] select{cursor:pointer;border-radius:.875rem;border-width:2px;font-weight:500}.unselected-dropdown[data-v-62cf823a] select{--tw-border-opacity: 1;border-color:rgb(158 158 158 / var(--tw-border-opacity, 1))}.selected-dropdown[data-v-62cf823a] select{--tw-border-opacity: 1;border-color:rgb(34 56 41 / var(--tw-border-opacity, 1))}.preset-option[data-v-62cf823a] span.tw-w-full:first-child{border-width:2px;--tw-border-opacity: 1;border-color:rgb(158 158 158 / var(--tw-border-opacity, 1))}.selected-option[data-v-62cf823a] span.tw-w-full:first-child{--tw-border-opacity: 1;border-color:rgba(var(--border-action),var(--tw-border-opacity, 1))}
1
+ .amountDropdownWrapper[data-v-ca361825] select{border-radius:14px 0 0 14px}.lend-again[data-v-ca361825] span{padding-left:0;padding-right:0;padding-left:.5rem;padding-right:.5rem}.lendButtonWrapper[data-v-ca361825] span:first-child{border-radius:0 14px 14px 0}.filtered-dropdown[data-v-ca361825] select{cursor:pointer;border-radius:.875rem;border-width:2px;font-weight:500}.unselected-dropdown[data-v-ca361825] select{--tw-border-opacity: 1;border-color:rgb(158 158 158 / var(--tw-border-opacity, 1))}.selected-dropdown[data-v-ca361825] select{--tw-border-opacity: 1;border-color:rgb(34 56 41 / var(--tw-border-opacity, 1))}.preset-option[data-v-ca361825] span.tw-w-full:first-child{border-width:2px;--tw-border-opacity: 1;border-color:rgb(158 158 158 / var(--tw-border-opacity, 1))}.selected-option[data-v-ca361825] span.tw-w-full:first-child{--tw-border-opacity: 1;border-color:rgba(var(--border-action),var(--tw-border-opacity, 1))}
@@ -1,19 +1,19 @@
1
- import { mdiChevronRight as T } from "@mdi/js";
2
- import { getLendCtaSelectedOption as p, getDropdownPriceArray as x } from "../utils/loanUtils.js";
1
+ import { mdiChevronRight as x } from "@mdi/js";
2
+ import { getLendCtaSelectedOption as L, getDropdownPriceArray as _ } from "../utils/loanUtils.js";
3
3
  import C from "./KvLendAmountButton.js";
4
- import _ from "./KvSelect.js";
5
- import D from "./KvButton.js";
6
- import P from "./KvMaterialIcon.js";
7
- import { resolveComponent as w, openBlock as i, createElementBlock as a, createBlock as l, normalizeClass as r, withCtx as d, createTextVNode as c, toDisplayString as m, createElementVNode as y, createVNode as S, withModifiers as A, Fragment as B, renderList as v, createCommentVNode as u } from "vue";
4
+ import D from "./KvSelect.js";
5
+ import P from "./KvButton.js";
6
+ import S from "./KvMaterialIcon.js";
7
+ import { resolveComponent as k, openBlock as i, createElementBlock as a, createBlock as l, normalizeClass as r, withCtx as d, createTextVNode as m, toDisplayString as f, createElementVNode as A, createVNode as I, withModifiers as B, Fragment as v, renderList as p, createCommentVNode as u } from "vue";
8
8
  import "./KvLendCta.css";
9
9
  import F from "../_virtual/_plugin-vue_export-helper.js";
10
- const I = {
10
+ const w = "Other", O = {
11
11
  name: "KvLendCta",
12
12
  components: {
13
13
  KvLendAmountButton: C,
14
- KvUiButton: D,
15
- KvUiSelect: _,
16
- KvMaterialIcon: P
14
+ KvUiButton: P,
15
+ KvUiSelect: D,
16
+ KvMaterialIcon: S
17
17
  },
18
18
  props: {
19
19
  loan: {
@@ -104,9 +104,9 @@ const I = {
104
104
  data() {
105
105
  var e, s, n;
106
106
  return {
107
- mdiChevronRight: T,
107
+ mdiChevronRight: x,
108
108
  defaultAmountOptions: [25, 50, 75],
109
- selectedOption: p(
109
+ selectedOption: L(
110
110
  this.getCookie,
111
111
  this.setCookie,
112
112
  this.enableFiveDollarsNotes,
@@ -115,7 +115,8 @@ const I = {
115
115
  this.userBalance,
116
116
  this.fiveDollarsSelected
117
117
  ),
118
- selectedDropdownOption: "Other"
118
+ selectedDropdownOption: w,
119
+ OTHER_OPTION: w
119
120
  };
120
121
  },
121
122
  computed: {
@@ -148,7 +149,7 @@ const I = {
148
149
  },
149
150
  prices() {
150
151
  const e = parseFloat(this.unreservedAmount < 25 ? this.minNoteSize : 25);
151
- return x(
152
+ return _(
152
153
  this.unreservedAmount,
153
154
  this.isCompleteLoanActive,
154
155
  e,
@@ -165,7 +166,7 @@ const I = {
165
166
  if (this.prices.length === 4)
166
167
  return [];
167
168
  const e = this.prices.slice(this.defaultAmountOptions.length);
168
- return e.unshift("Other"), e;
169
+ return e.unshift(w), e;
169
170
  },
170
171
  loanName() {
171
172
  var e;
@@ -231,7 +232,7 @@ const I = {
231
232
  return this.isLentTo && !this.isLessThan25;
232
233
  },
233
234
  selectedDropdown() {
234
- return this.selectedDropdownOption !== "Other";
235
+ return this.selectedDropdownOption !== w;
235
236
  },
236
237
  showFilteredDropdown() {
237
238
  return this.presetDropdownPrices.length > 1;
@@ -242,17 +243,17 @@ const I = {
242
243
  },
243
244
  watch: {
244
245
  unreservedAmount(e, s) {
245
- var n, k;
246
- e !== s && s === "" && (this.selectedOption = p(
246
+ var n, y;
247
+ e !== s && s === "" && (this.selectedOption = L(
247
248
  this.getCookie,
248
249
  this.setCookie,
249
250
  this.enableFiveDollarsNotes,
250
- (k = (n = this.route) == null ? void 0 : n.query) == null ? void 0 : k.utm_campaign,
251
+ (y = (n = this.route) == null ? void 0 : n.query) == null ? void 0 : y.utm_campaign,
251
252
  e,
252
253
  this.userBalance,
253
254
  this.fiveDollarsSelected,
254
255
  this.showPresetAmounts
255
- )), this.showPresetAmounts && (this.selectedOption = "Other");
256
+ )), this.showPresetAmounts && (this.selectedOption = w);
256
257
  }
257
258
  },
258
259
  methods: {
@@ -302,7 +303,7 @@ const I = {
302
303
  e,
303
304
  this.loanId,
304
305
  this.loanId
305
- ), this.selectedOption = e;
306
+ ), this.selectedOption = e, this.selectedDropdownOption = w;
306
307
  },
307
308
  handleCheckout() {
308
309
  this.kvTrackFunction(
@@ -314,18 +315,18 @@ const I = {
314
315
  );
315
316
  }
316
317
  }
317
- }, V = { class: "tw-whitespace-nowrap" }, O = {
318
+ }, N = { class: "tw-whitespace-nowrap" }, V = {
318
319
  key: 2,
319
320
  class: "tw-w-full tw-text-center tw-rounded tw-p-2",
320
321
  style: { background: "#f1f1f1" }
321
- }, N = { class: "tw-flex" }, M = ["disabled"], H = ["value"], K = {
322
+ }, H = { class: "tw-flex" }, M = ["disabled"], R = ["value"], K = {
322
323
  key: 1,
323
324
  class: "amountDropdownWrapper"
324
- }, R = ["value"];
325
- function U(e, s, n, k, f, t) {
326
- const h = w("kv-ui-button"), L = w("kv-material-icon"), g = w("kv-ui-select"), b = w("kv-lend-amount-button");
327
- return i(), a("div", V, [
328
- t.isInBasket ? (i(), l(h, {
325
+ }, U = ["value"];
326
+ function j(e, s, n, y, h, t) {
327
+ const c = k("kv-ui-button"), b = k("kv-material-icon"), g = k("kv-ui-select"), T = k("kv-lend-amount-button");
328
+ return i(), a("div", N, [
329
+ t.isInBasket ? (i(), l(c, {
329
330
  key: 0,
330
331
  variant: "secondary",
331
332
  class: r(["tw-inline-flex tw-flex-1", { "tw-w-full": n.showPresetAmounts }]),
@@ -335,18 +336,18 @@ function U(e, s, n, k, f, t) {
335
336
  onClick: s[0] || (s[0] = (o) => t.clickSecondaryButton(o))
336
337
  }, {
337
338
  default: d(() => [
338
- c(m(t.loanInBasketButtonText), 1)
339
+ m(f(t.loanInBasketButtonText), 1)
339
340
  ]),
340
341
  _: 1
341
- }, 8, ["class", "to", "href"])) : t.showNonActionableLoanButton ? (i(), l(h, {
342
+ }, 8, ["class", "to", "href"])) : t.showNonActionableLoanButton ? (i(), l(c, {
342
343
  key: 1,
343
344
  class: "tw-inline-flex tw-flex-1"
344
345
  }, {
345
346
  default: d(() => [
346
- c(m(t.ctaButtonText), 1)
347
+ m(f(t.ctaButtonText), 1)
347
348
  ]),
348
349
  _: 1
349
- })) : t.isFunded ? (i(), a("div", O, " This loan was just funded! 🎉 ")) : n.showViewLoan ? (i(), l(h, {
350
+ })) : t.isFunded ? (i(), a("div", V, " This loan was just funded! 🎉 ")) : n.showViewLoan ? (i(), l(c, {
350
351
  key: 3,
351
352
  state: `${t.allSharesReserved ? "disabled" : ""}`,
352
353
  to: n.externalLinks ? void 0 : t.readMorePath,
@@ -355,11 +356,11 @@ function U(e, s, n, k, f, t) {
355
356
  onClick: s[1] || (s[1] = (o) => e.$emit("show-loan-details", o))
356
357
  }, {
357
358
  default: d(() => [
358
- y("span", N, [
359
- s[5] || (s[5] = c(" View loan ")),
360
- S(L, {
359
+ A("span", H, [
360
+ s[5] || (s[5] = m(" View loan ")),
361
+ I(b, {
361
362
  class: "tw-w-3 tw-h-3 tw-align-middle",
362
- icon: f.mdiChevronRight
363
+ icon: h.mdiChevronRight
363
364
  }, null, 8, ["icon"])
364
365
  ])
365
366
  ]),
@@ -367,9 +368,9 @@ function U(e, s, n, k, f, t) {
367
368
  }, 8, ["state", "to", "href"])) : t.useFormSubmit ? (i(), a("form", {
368
369
  key: 4,
369
370
  class: "tw-w-full tw-flex",
370
- onSubmit: s[4] || (s[4] = A((...o) => t.addToBasket && t.addToBasket(...o), ["prevent"]))
371
+ onSubmit: s[4] || (s[4] = B((...o) => t.addToBasket && t.addToBasket(...o), ["prevent"]))
371
372
  }, [
372
- y("fieldset", {
373
+ A("fieldset", {
373
374
  class: r(["tw-w-full tw-flex", {
374
375
  "tw-flex-col md:tw-flex-row md:tw-justify-between": n.showPresetAmounts,
375
376
  "tw-gap-1.5": n.showPresetAmounts && !t.isLendAmountButton
@@ -381,24 +382,24 @@ function U(e, s, n, k, f, t) {
381
382
  key: 0,
382
383
  class: r(["tw-flex tw-gap-1 lg:tw-gap-2", { "tw-flex-wrap md:tw-flex-nowrap": n.enableHugeAmount }])
383
384
  }, [
384
- t.isLendAmountButton ? u("", !0) : (i(!0), a(B, { key: 0 }, v(t.presetButtonsPrices, (o) => (i(), l(h, {
385
+ t.isLendAmountButton ? u("", !0) : (i(!0), a(v, { key: 0 }, p(t.presetButtonsPrices, (o) => (i(), l(c, {
385
386
  key: o,
386
387
  variant: "secondary",
387
- class: r(["tw-inline-flex tw-flex-1 preset-option tw-w-8", { "selected-option": f.selectedOption == o }]),
388
+ class: r(["tw-inline-flex tw-flex-1 preset-option tw-w-8", { "selected-option": h.selectedOption == o }]),
388
389
  "data-testid": "bp-lend-cta-lend-button",
389
- onClick: (j) => t.clickPresetButton(o)
390
+ onClick: (z) => t.clickPresetButton(o)
390
391
  }, {
391
392
  default: d(() => [
392
- c(" $" + m(o), 1)
393
+ m(" $" + f(o), 1)
393
394
  ]),
394
395
  _: 2
395
396
  }, 1032, ["class", "onClick"]))), 128)),
396
397
  t.showFilteredDropdown ? (i(), l(g, {
397
398
  key: 1,
398
399
  id: `LoanAmountDropdown_${t.loanId}`,
399
- modelValue: f.selectedDropdownOption,
400
+ modelValue: h.selectedDropdownOption,
400
401
  "onUpdate:modelValue": [
401
- s[2] || (s[2] = (o) => f.selectedDropdownOption = o),
402
+ s[2] || (s[2] = (o) => h.selectedDropdownOption = o),
402
403
  t.trackLendAmountSelection
403
404
  ],
404
405
  class: r(["tw-min-w-12 tw-rounded filtered-dropdown", {
@@ -407,13 +408,13 @@ function U(e, s, n, k, f, t) {
407
408
  "tw-w-full": n.enableHugeAmount
408
409
  }]),
409
410
  "aria-label": "Lend amount",
410
- onClick: A(t.clickDropdown, ["stop"])
411
+ onClick: B(t.clickDropdown, ["stop"])
411
412
  }, {
412
413
  default: d(() => [
413
- (i(!0), a(B, null, v(t.presetDropdownPrices, (o) => (i(), a("option", {
414
+ (i(!0), a(v, null, p(t.presetDropdownPrices, (o) => (i(), a("option", {
414
415
  key: o,
415
416
  value: o
416
- }, m(o !== "Other" ? `$${o}` : o), 9, H))), 128))
417
+ }, f(o !== h.OTHER_OPTION ? `$${o}` : o), 9, R))), 128))
417
418
  ]),
418
419
  _: 1
419
420
  }, 8, ["id", "modelValue", "class", "onUpdate:modelValue", "onClick"])) : u("", !0)
@@ -421,54 +422,54 @@ function U(e, s, n, k, f, t) {
421
422
  t.hideShowLendDropdown && !t.isLessThan25 ? (i(), l(g, {
422
423
  key: 0,
423
424
  id: `LoanAmountDropdown_${t.loanId}`,
424
- modelValue: f.selectedOption,
425
+ modelValue: h.selectedOption,
425
426
  "onUpdate:modelValue": [
426
- s[3] || (s[3] = (o) => f.selectedOption = o),
427
+ s[3] || (s[3] = (o) => h.selectedOption = o),
427
428
  t.trackLendAmountSelection
428
429
  ],
429
430
  class: "tw-min-w-12",
430
431
  style: { "border-radius": "14px 0 0 14px" },
431
432
  "aria-label": "Lend amount",
432
- onClick: A(t.clickDropdown, ["stop"])
433
+ onClick: B(t.clickDropdown, ["stop"])
433
434
  }, {
434
435
  default: d(() => [
435
- (i(!0), a(B, null, v(t.prices, (o) => (i(), a("option", {
436
+ (i(!0), a(v, null, p(t.prices, (o) => (i(), a("option", {
436
437
  key: o,
437
438
  value: o
438
- }, " $" + m(o), 9, R))), 128))
439
+ }, " $" + f(o), 9, U))), 128))
439
440
  ]),
440
441
  _: 1
441
442
  }, 8, ["id", "modelValue", "onUpdate:modelValue", "onClick"])) : u("", !0)
442
443
  ])),
443
- y("div", {
444
+ A("div", {
444
445
  class: r({
445
446
  lendButtonWrapper: t.hideShowLendDropdown && !n.showPresetAmounts,
446
447
  "tw-hidden": t.hideLendButton
447
448
  })
448
449
  }, [
449
- t.lendButtonVisibility && !t.isLessThan25 ? (i(), l(h, {
450
+ t.lendButtonVisibility && !t.isLessThan25 ? (i(), l(c, {
450
451
  key: "lendButton",
451
452
  class: r(["tw-inline-flex tw-flex-1", { "tw-w-full": n.showPresetAmounts }]),
452
453
  "data-testid": "bp-lend-cta-lend-button",
453
454
  type: "submit"
454
455
  }, {
455
456
  default: d(() => [
456
- c(m(t.ctaButtonText), 1)
457
+ m(f(t.ctaButtonText), 1)
457
458
  ]),
458
459
  _: 1
459
- }, 8, ["class"])) : t.showLendAgain ? (i(), l(h, {
460
+ }, 8, ["class"])) : t.showLendAgain ? (i(), l(c, {
460
461
  key: "lendAgainButton",
461
462
  class: r(["lend-again", { "tw-w-full": n.showPresetAmounts }]),
462
463
  "data-testid": "bp-lend-cta-lend-again-button",
463
464
  type: "submit"
464
465
  }, {
465
466
  default: d(() => [
466
- c(m(n.primaryButtonText || "Lend") + " again ", 1)
467
+ m(f(n.primaryButtonText || "Lend") + " again ", 1)
467
468
  ]),
468
469
  _: 1
469
470
  }, 8, ["class"])) : u("", !0)
470
471
  ], 2),
471
- t.isLendAmountButton && !n.enableFiveDollarsNotes ? (i(), l(b, {
472
+ t.isLendAmountButton && !n.enableFiveDollarsNotes ? (i(), l(T, {
472
473
  key: 2,
473
474
  class: "tw-w-full",
474
475
  "loan-id": t.loanId,
@@ -477,12 +478,12 @@ function U(e, s, n, k, f, t) {
477
478
  "is-adding": n.isAdding,
478
479
  onAddToBasket: t.addToBasket
479
480
  }, null, 8, ["loan-id", "amount-left", "is-adding", "onAddToBasket"])) : u("", !0),
480
- !n.isLoading && n.isAdding ? (i(), l(h, {
481
+ !n.isLoading && n.isAdding ? (i(), l(c, {
481
482
  key: 3,
482
483
  class: "tw-inline-flex tw-flex-1"
483
484
  }, {
484
485
  default: d(() => s[6] || (s[6] = [
485
- c(" Adding to basket ")
486
+ m(" Adding to basket ")
486
487
  ])),
487
488
  _: 1
488
489
  })) : u("", !0)
@@ -490,7 +491,7 @@ function U(e, s, n, k, f, t) {
490
491
  ], 32)) : u("", !0)
491
492
  ]);
492
493
  }
493
- const Z = /* @__PURE__ */ F(I, [["render", U], ["__scopeId", "data-v-62cf823a"]]);
494
+ const $ = /* @__PURE__ */ F(O, [["render", j], ["__scopeId", "data-v-ca361825"]]);
494
495
  export {
495
- Z as default
496
+ $ as default
496
497
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kiva/kv-components",
3
- "version": "5.3.5",
3
+ "version": "5.3.7",
4
4
  "type": "module",
5
5
  "publishConfig": {
6
6
  "access": "public"
@@ -106,5 +106,5 @@
106
106
  "embla-carousel-fade",
107
107
  "popper.js"
108
108
  ],
109
- "gitHead": "edf2d18c4c65660427738f7ddfa8bb1ae0e71ddb"
109
+ "gitHead": "f8e99cbfcfe195d35e6797f608a4b217fb794509"
110
110
  }