@kiva/kv-components 9.1.1 → 10.0.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.
- package/dist/vue/KvCheckoutReceipt.css +1 -1
- package/dist/vue/KvCheckoutReceipt.js +20 -21
- package/dist/vue/KvLoanTag.js +9 -10
- package/dist/vue/KvPopper.vue.d.ts +16 -0
- package/dist/vue/KvPopper2.js +42 -9
- package/dist/vue/KvSecondaryNav.css +1 -1
- package/dist/vue/KvSecondaryNav.js +7 -10
- package/dist/vue/KvTextLink.js +3 -3
- package/dist/vue/KvTooltip.css +1 -1
- package/dist/vue/KvTooltip.js +40 -40
- package/dist/vue/KvTooltip2.js +42 -51
- package/package.json +2 -2
|
@@ -1 +1 @@
|
|
|
1
|
-
.section[data-v-
|
|
1
|
+
.section[data-v-e06307e1]{border-bottom-width:.0625rem;border-top-width:0px;--tw-border-opacity: 1;border-color:rgba(var(--border-tertiary),var(--tw-border-opacity, 1));padding:.5rem;display:block;overflow:hidden}@media print{.section[data-v-e06307e1]{page-break-inside:avoid}}.section--lender-info[data-v-e06307e1]{padding-top:0}.section--print[data-v-e06307e1]{border-bottom:0}.checkout-receipt__headline[data-v-e06307e1]{text-align:center;margin-bottom:1.5rem}.checkout-receipt__item-list[data-v-e06307e1]{list-style:none;margin:0;width:100%}.loan__name[data-v-e06307e1]{margin-bottom:.5rem}.loan__name--inline[data-v-e06307e1]{display:inline-block}.loan__amount[data-v-e06307e1]{text-align:right}.total[data-v-e06307e1]{display:flex;align-items:baseline}.total__header[data-v-e06307e1],.total__amount[data-v-e06307e1]{text-align:right;flex:1}.total__amount[data-v-e06307e1]{flex-grow:.33}.payments[data-v-e06307e1]{border-bottom:none}.payments__type[data-v-e06307e1]{display:flex;text-align:right}.payments__type-title[data-v-e06307e1],.payments__type-amount[data-v-e06307e1]{flex:1}.print[data-v-e06307e1]{margin:0 auto}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { resolveComponent as _, resolveDirective as
|
|
1
|
+
import f from "./KvCheckoutReceipt2.js";
|
|
2
|
+
import { resolveComponent as _, resolveDirective as h, openBlock as s, createElementBlock as o, createElementVNode as e, toDisplayString as i, createCommentVNode as d, Fragment as c, renderList as k, createTextVNode as l, createVNode as p, withCtx as v, withDirectives as b } from "vue";
|
|
3
3
|
import "./KvCheckoutReceipt.css";
|
|
4
4
|
import x from "../_virtual/_plugin-vue_export-helper.js";
|
|
5
5
|
const g = { class: "checkout-receipt" }, T = { class: "checkout-receipt__wrapper tw-bg-primary tw-p-4 tw-rounded-xs tw-border tw-border-tertiary" }, j = {
|
|
@@ -33,24 +33,24 @@ const g = { class: "checkout-receipt" }, T = { class: "checkout-receipt__wrapper
|
|
|
33
33
|
}, B = {
|
|
34
34
|
"data-testid": "kcard",
|
|
35
35
|
class: "loan kcard"
|
|
36
|
-
},
|
|
36
|
+
}, U = {
|
|
37
37
|
class: "loan__details data-hj-suppress",
|
|
38
38
|
"data-testid": "kcard-details"
|
|
39
|
-
},
|
|
39
|
+
}, q = {
|
|
40
40
|
key: 0,
|
|
41
41
|
"data-testid": "kcard-details",
|
|
42
42
|
class: "loan__details data-hj-suppress"
|
|
43
|
-
},
|
|
43
|
+
}, z = {
|
|
44
44
|
class: "loan__details data-hj-suppress",
|
|
45
45
|
"data-testid": "kcard-details"
|
|
46
|
-
},
|
|
46
|
+
}, L = {
|
|
47
47
|
class: "loan__amount tw-text-title",
|
|
48
48
|
"data-testid": "kcard-amount"
|
|
49
|
-
},
|
|
49
|
+
}, S = {
|
|
50
50
|
key: 0,
|
|
51
51
|
"data-testid": "kcard-portfolio",
|
|
52
52
|
class: "section tw-text-center print:!tw-hidden"
|
|
53
|
-
},
|
|
53
|
+
}, W = { href: "/portfolio/kiva-cards" }, Y = { class: "checkout-receipt__item-list" }, G = { class: "section" }, H = {
|
|
54
54
|
class: "loan",
|
|
55
55
|
"data-testid": "donation"
|
|
56
56
|
}, J = {
|
|
@@ -103,7 +103,7 @@ const g = { class: "checkout-receipt" }, T = { class: "checkout-receipt__wrapper
|
|
|
103
103
|
"data-testid": "amount-charged-payment-amount"
|
|
104
104
|
}, ct = { class: "section section--print print:!tw-hidden" };
|
|
105
105
|
function pt(_t, t, n, m, mt, r) {
|
|
106
|
-
const u = _("kv-material-icon"), y = _("kv-tooltip"), w = _("kv-button"),
|
|
106
|
+
const u = _("kv-material-icon"), y = _("kv-tooltip"), w = _("kv-button"), C = h("kv-track-event");
|
|
107
107
|
return s(), o("div", g, [
|
|
108
108
|
t[25] || (t[25] = e("h2", { class: "checkout-receipt__headline" }, " Order Confirmation ", -1)),
|
|
109
109
|
e("div", T, [
|
|
@@ -167,8 +167,7 @@ function pt(_t, t, n, m, mt, r) {
|
|
|
167
167
|
}, null, 8, ["id", "icon"]),
|
|
168
168
|
p(y, {
|
|
169
169
|
"data-testid": "kcard-tool-tip-text",
|
|
170
|
-
controller: `print-card-${a.id}
|
|
171
|
-
theme: "ecoGreenLight"
|
|
170
|
+
controller: `print-card-${a.id}`
|
|
172
171
|
}, {
|
|
173
172
|
default: v(() => t[2] || (t[2] = [
|
|
174
173
|
l(" You can print this card now. We'll also send it to you in an email so you can print it later. ")
|
|
@@ -193,7 +192,7 @@ function pt(_t, t, n, m, mt, r) {
|
|
|
193
192
|
class: "loan__name tw-text-title",
|
|
194
193
|
"data-testid": "kcard-type-postal"
|
|
195
194
|
}, " Postal delivery Kiva Card ", -1)),
|
|
196
|
-
e("div",
|
|
195
|
+
e("div", U, [
|
|
197
196
|
l(" For: " + i(a.kivaCardObject.mailingInfo.firstName) + " " + i(a.kivaCardObject.mailingInfo.lastName), 1),
|
|
198
197
|
t[6] || (t[6] = e("br", null, null, -1)),
|
|
199
198
|
l(" " + i(a.kivaCardObject.mailingInfo.address), 1),
|
|
@@ -209,13 +208,13 @@ function pt(_t, t, n, m, mt, r) {
|
|
|
209
208
|
class: "loan__name tw-text-title",
|
|
210
209
|
"data-testid": "kcard-type-lender"
|
|
211
210
|
}, " Kiva Card ", -1)),
|
|
212
|
-
a.kivaCardObject.recipient.name ? (s(), o("div",
|
|
211
|
+
a.kivaCardObject.recipient.name ? (s(), o("div", q, " For: " + i(a.kivaCardObject.recipient.name), 1)) : d("", !0)
|
|
213
212
|
], 64)) : a.kivaCardObject.deliveryType === "email" ? (s(), o(c, { key: 3 }, [
|
|
214
213
|
t[11] || (t[11] = e("h3", {
|
|
215
214
|
class: "loan__name tw-text-title",
|
|
216
215
|
"data-testid": "kcard-type-email"
|
|
217
216
|
}, " Email delivery Kiva Card ", -1)),
|
|
218
|
-
e("div",
|
|
217
|
+
e("div", z, [
|
|
219
218
|
t[10] || (t[10] = l(" For: ")),
|
|
220
219
|
a.kivaCardObject.recipient.name ? (s(), o(c, { key: 0 }, [
|
|
221
220
|
l(i(a.kivaCardObject.recipient.name) + " – ", 1)
|
|
@@ -223,23 +222,23 @@ function pt(_t, t, n, m, mt, r) {
|
|
|
223
222
|
l(" " + i(a.kivaCardObject.recipient.email), 1)
|
|
224
223
|
])
|
|
225
224
|
], 64)) : d("", !0),
|
|
226
|
-
e("div",
|
|
225
|
+
e("div", L, " $" + i(a.price), 1)
|
|
227
226
|
])
|
|
228
227
|
]))), 128)),
|
|
229
|
-
r.kivaCards.length > 0 ? (s(), o("li",
|
|
228
|
+
r.kivaCards.length > 0 ? (s(), o("li", S, [
|
|
230
229
|
t[13] || (t[13] = l(" For more details about all your Kiva Card purchases, please visit your ")),
|
|
231
|
-
b((s(), o("a",
|
|
230
|
+
b((s(), o("a", W, t[12] || (t[12] = [
|
|
232
231
|
l(" Kiva portfolio ")
|
|
233
232
|
]))), [
|
|
234
|
-
[
|
|
233
|
+
[C, ["Thanks", "click", "kiva-card-portfolio"]]
|
|
235
234
|
]),
|
|
236
235
|
t[14] || (t[14] = l(". "))
|
|
237
236
|
])) : d("", !0)
|
|
238
237
|
])
|
|
239
238
|
]),
|
|
240
239
|
e("section", null, [
|
|
241
|
-
e("ul",
|
|
242
|
-
e("li",
|
|
240
|
+
e("ul", Y, [
|
|
241
|
+
e("li", G, [
|
|
243
242
|
e("div", H, [
|
|
244
243
|
t[15] || (t[15] = e("h3", { class: "loan__name tw-text-title" }, " Donation to Kiva ", -1)),
|
|
245
244
|
n.receipt.totals.donationTotal > 0 ? (s(), o("a", {
|
|
@@ -307,7 +306,7 @@ function pt(_t, t, n, m, mt, r) {
|
|
|
307
306
|
])
|
|
308
307
|
]);
|
|
309
308
|
}
|
|
310
|
-
const wt = /* @__PURE__ */ x(
|
|
309
|
+
const wt = /* @__PURE__ */ x(f, [["render", pt], ["__scopeId", "data-v-e06307e1"]]);
|
|
311
310
|
export {
|
|
312
311
|
wt as default
|
|
313
312
|
};
|
package/dist/vue/KvLoanTag.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import h from "./KvLoanTag2.js";
|
|
2
2
|
import { KV_LOAN_TAG_FRAGMENT as L } from "./KvLoanTag2.js";
|
|
3
|
-
import { resolveComponent as d, openBlock as e, createElementBlock as r, normalizeStyle as _, normalizeClass as w, Fragment as
|
|
3
|
+
import { resolveComponent as d, openBlock as e, createElementBlock as r, normalizeStyle as _, normalizeClass as w, Fragment as o, createTextVNode as m, toDisplayString as a, createElementVNode as l, createVNode as p, withCtx as y, renderList as k, createBlock as f, createCommentVNode as s } from "vue";
|
|
4
4
|
import x from "../_virtual/_plugin-vue_export-helper.js";
|
|
5
5
|
const v = ["id"], M = { class: "tw-whitespace-nowrap tw-pb-0.5" };
|
|
6
6
|
function N(b, i, c, C, T, t) {
|
|
@@ -10,30 +10,29 @@ function N(b, i, c, C, T, t) {
|
|
|
10
10
|
class: w(["tw-text-small tw-font-medium tw-pt-0.5", { "tw-line-clamp-1": !t.isMultipleMatch }]),
|
|
11
11
|
style: _({ color: t.tagColor })
|
|
12
12
|
}, [
|
|
13
|
-
t.isMultipleMatch ? (e(), r(
|
|
13
|
+
t.isMultipleMatch ? (e(), r(o, { key: 0 }, [
|
|
14
14
|
m(a(t.totalMatchRatio) + "x match by ", 1),
|
|
15
|
-
|
|
15
|
+
l("span", {
|
|
16
16
|
id: `matching-orgs-${c.loan.id}`,
|
|
17
17
|
class: "tw-underline tw-decoration-dotted tw-cursor-pointer"
|
|
18
18
|
}, a(t.multiMatchingOrgs.length) + " organizations", 9, v),
|
|
19
19
|
p(u, {
|
|
20
20
|
controller: `matching-orgs-${c.loan.id}`,
|
|
21
|
-
"max-width": "320px"
|
|
22
|
-
theme: "default"
|
|
21
|
+
"max-width": "320px"
|
|
23
22
|
}, {
|
|
24
23
|
default: y(() => [
|
|
25
|
-
|
|
26
|
-
i[0] || (i[0] =
|
|
27
|
-
(e(!0), r(
|
|
24
|
+
l("p", M, " Your contribution is matched by " + a(t.multiMatchingOrgs.length) + " partners ", 1),
|
|
25
|
+
i[0] || (i[0] = l("hr", { class: "tw-border-caution-highlight tw-py-0.5" }, null, -1)),
|
|
26
|
+
(e(!0), r(o, null, k(t.multiMatchingOrgs, (n) => (e(), r("p", {
|
|
28
27
|
key: n.managedAccountId,
|
|
29
28
|
class: "tw-m-0"
|
|
30
29
|
}, a(n.ratio) + ":1 matching by " + a(t.orgDisplayName(n)), 1))), 128))
|
|
31
30
|
]),
|
|
32
31
|
_: 1
|
|
33
32
|
}, 8, ["controller"])
|
|
34
|
-
], 64)) : (e(), r(
|
|
33
|
+
], 64)) : (e(), r(o, { key: 1 }, [
|
|
35
34
|
m(a(t.tagText) + " ", 1),
|
|
36
|
-
t.variation === "ending-soon" ? (e(),
|
|
35
|
+
t.variation === "ending-soon" ? (e(), f(g, {
|
|
37
36
|
key: 0,
|
|
38
37
|
deadline: t.deadline
|
|
39
38
|
}, null, 8, ["deadline"])) : s("", !0)
|
|
@@ -23,17 +23,28 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
|
|
|
23
23
|
type: ObjectConstructor;
|
|
24
24
|
default: () => void;
|
|
25
25
|
};
|
|
26
|
+
persistent: {
|
|
27
|
+
type: BooleanConstructor;
|
|
28
|
+
default: boolean;
|
|
29
|
+
};
|
|
26
30
|
}>, {}, {
|
|
27
31
|
popper: any;
|
|
28
32
|
popperPromise: any;
|
|
29
33
|
styles: {};
|
|
30
34
|
show: boolean;
|
|
31
35
|
timeout: any;
|
|
36
|
+
suppressOpen: boolean;
|
|
32
37
|
}, {
|
|
33
38
|
reference(): any;
|
|
39
|
+
hitTargets(): any[];
|
|
34
40
|
}, {
|
|
35
41
|
open(): void;
|
|
36
42
|
close(): void;
|
|
43
|
+
closeOnLeave(): void;
|
|
44
|
+
hide(): void;
|
|
45
|
+
outsideHandler(e: any): void;
|
|
46
|
+
dismiss(): void;
|
|
47
|
+
keyupHandler(e: any): void;
|
|
37
48
|
toggle(): void;
|
|
38
49
|
update(): void;
|
|
39
50
|
initPopper(): any;
|
|
@@ -70,11 +81,16 @@ declare const _default: import('vue').DefineComponent<import('vue').ExtractPropT
|
|
|
70
81
|
type: ObjectConstructor;
|
|
71
82
|
default: () => void;
|
|
72
83
|
};
|
|
84
|
+
persistent: {
|
|
85
|
+
type: BooleanConstructor;
|
|
86
|
+
default: boolean;
|
|
87
|
+
};
|
|
73
88
|
}>> & Readonly<{}>, {
|
|
74
89
|
openDelay: number;
|
|
75
90
|
closeDelay: number;
|
|
76
91
|
transitionType: string;
|
|
77
92
|
popperPlacement: string;
|
|
78
93
|
popperModifiers: Record<string, any>;
|
|
94
|
+
persistent: boolean;
|
|
79
95
|
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
|
|
80
96
|
export default _default;
|
package/dist/vue/KvPopper2.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { offBodyTouchstart as
|
|
1
|
+
import { offBodyTouchstart as i, onBodyTouchstart as o, isTargetElement as r } from "../utils/touchEvents.js";
|
|
2
2
|
const h = {
|
|
3
3
|
name: "KvPopper",
|
|
4
4
|
props: {
|
|
@@ -14,7 +14,13 @@ const h = {
|
|
|
14
14
|
transitionType: { type: String, default: "" },
|
|
15
15
|
popperPlacement: { type: String, default: "bottom-start" },
|
|
16
16
|
popperModifiers: { type: Object, default: () => {
|
|
17
|
-
} }
|
|
17
|
+
} },
|
|
18
|
+
/**
|
|
19
|
+
* Stay open once shown, rather than closing when the pointer or focus leaves the
|
|
20
|
+
* controller. Escape and an outside click still close it. Use for poppers holding
|
|
21
|
+
* something interactive, which the user has to be able to reach and act on.
|
|
22
|
+
*/
|
|
23
|
+
persistent: { type: Boolean, default: !1 }
|
|
18
24
|
},
|
|
19
25
|
data() {
|
|
20
26
|
return {
|
|
@@ -22,12 +28,18 @@ const h = {
|
|
|
22
28
|
popperPromise: null,
|
|
23
29
|
styles: {},
|
|
24
30
|
show: !1,
|
|
25
|
-
timeout: null
|
|
31
|
+
timeout: null,
|
|
32
|
+
suppressOpen: !1
|
|
26
33
|
};
|
|
27
34
|
},
|
|
28
35
|
computed: {
|
|
29
36
|
reference() {
|
|
30
37
|
return typeof this.controller == "string" ? document.getElementById(this.controller) : this.controller;
|
|
38
|
+
},
|
|
39
|
+
// reference resolves by id on every read, so it is null once the controller leaves
|
|
40
|
+
// the DOM while this popper is still mounted.
|
|
41
|
+
hitTargets() {
|
|
42
|
+
return [this.reference, this.$el].filter(Boolean);
|
|
31
43
|
}
|
|
32
44
|
},
|
|
33
45
|
watch: {
|
|
@@ -46,7 +58,7 @@ const h = {
|
|
|
46
58
|
},
|
|
47
59
|
methods: {
|
|
48
60
|
open() {
|
|
49
|
-
this.initPopper().then(() => {
|
|
61
|
+
this.suppressOpen || this.initPopper().then(() => {
|
|
50
62
|
this.setTimeout(() => {
|
|
51
63
|
this.show = !0, this.popper.scheduleUpdate(), this.attachBodyEvents();
|
|
52
64
|
}, this.openDelay);
|
|
@@ -57,6 +69,27 @@ const h = {
|
|
|
57
69
|
this.show = !1, this.removeBodyEvents();
|
|
58
70
|
}, this.closeDelay);
|
|
59
71
|
},
|
|
72
|
+
// Persistent content has to stay reachable, so leaving the controller must not close
|
|
73
|
+
// it — by pointer or by tabbing in. Checked here so the prop can change after mount.
|
|
74
|
+
closeOnLeave() {
|
|
75
|
+
this.persistent || this.close();
|
|
76
|
+
},
|
|
77
|
+
// Close now, skipping closeDelay, for dismissals the user asked for directly.
|
|
78
|
+
hide() {
|
|
79
|
+
window.clearTimeout(this.timeout), this.show = !1, this.removeBodyEvents();
|
|
80
|
+
},
|
|
81
|
+
outsideHandler(e) {
|
|
82
|
+
r(e, this.hitTargets) || this.hide();
|
|
83
|
+
},
|
|
84
|
+
// Ends the current viewing. Returns focus only if it was inside, so it is not
|
|
85
|
+
// stranded on content that just went away.
|
|
86
|
+
dismiss() {
|
|
87
|
+
const e = this.$el.contains(document.activeElement);
|
|
88
|
+
this.hide(), e && this.reference && (this.suppressOpen = !0, this.reference.focus(), this.suppressOpen = !1);
|
|
89
|
+
},
|
|
90
|
+
keyupHandler(e) {
|
|
91
|
+
e.key === "Escape" && (e.stopPropagation(), this.dismiss());
|
|
92
|
+
},
|
|
60
93
|
toggle() {
|
|
61
94
|
this.show ? this.close() : this.open();
|
|
62
95
|
},
|
|
@@ -80,22 +113,22 @@ const h = {
|
|
|
80
113
|
}), this.popperPromise);
|
|
81
114
|
},
|
|
82
115
|
bodyTouchHandler(e) {
|
|
83
|
-
|
|
116
|
+
r(e, this.hitTargets) || (this.show = !1, this.removeBodyEvents());
|
|
84
117
|
},
|
|
85
118
|
referenceTapHandler(e) {
|
|
86
119
|
e.preventDefault(), this.toggle();
|
|
87
120
|
},
|
|
88
121
|
attachEvents() {
|
|
89
|
-
this.reference.addEventListener("mouseover", this.open), this.reference.addEventListener("focus", this.open), this.reference.addEventListener("
|
|
122
|
+
this.reference.addEventListener("mouseover", this.open), this.reference.addEventListener("focus", this.open), this.reference.addEventListener("touchstart", this.referenceTapHandler), this.reference.addEventListener("mouseout", this.closeOnLeave), this.reference.addEventListener("blur", this.closeOnLeave), this.$el.addEventListener("mouseover", this.open), this.$el.addEventListener("mouseout", this.closeOnLeave);
|
|
90
123
|
},
|
|
91
124
|
attachBodyEvents() {
|
|
92
|
-
o(this.bodyTouchHandler);
|
|
125
|
+
o(this.bodyTouchHandler), document.addEventListener("click", this.outsideHandler), document.addEventListener("keyup", this.keyupHandler, !0);
|
|
93
126
|
},
|
|
94
127
|
removeEvents() {
|
|
95
|
-
this.removeBodyEvents(), this.reference.removeEventListener("touchstart", this.referenceTapHandler), this.reference.removeEventListener("mouseover", this.open), this.reference.removeEventListener("mouseout", this.
|
|
128
|
+
this.removeBodyEvents(), this.reference.removeEventListener("touchstart", this.referenceTapHandler), this.reference.removeEventListener("mouseover", this.open), this.reference.removeEventListener("focus", this.open), this.reference.removeEventListener("mouseout", this.closeOnLeave), this.reference.removeEventListener("blur", this.closeOnLeave), this.$el.removeEventListener("mouseover", this.open), this.$el.removeEventListener("mouseout", this.closeOnLeave);
|
|
96
129
|
},
|
|
97
130
|
removeBodyEvents() {
|
|
98
|
-
|
|
131
|
+
i(this.bodyTouchHandler), document.removeEventListener("click", this.outsideHandler), document.removeEventListener("keyup", this.keyupHandler, !0);
|
|
99
132
|
},
|
|
100
133
|
setAttributes(e) {
|
|
101
134
|
Object.keys(e).forEach((t) => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
.kv-secondary-nav-holder[data-v-
|
|
1
|
+
.kv-secondary-nav-holder[data-v-230060bf]{height:62px}.kv-secondary-nav[data-v-230060bf]{min-height:62px}
|
|
@@ -1,14 +1,11 @@
|
|
|
1
1
|
import x from "./KvSecondaryNav2.js";
|
|
2
|
-
import { resolveComponent as l, openBlock as i, createBlock as d, withCtx as o, createElementVNode as r, normalizeClass as a, createVNode as
|
|
2
|
+
import { resolveComponent as l, openBlock as i, createBlock as d, withCtx as o, createElementVNode as r, normalizeClass as a, createVNode as v, createElementBlock as c, resolveDynamicComponent as s, createTextVNode as m, toDisplayString as _, createCommentVNode as u, Fragment as y, renderList as b } from "vue";
|
|
3
3
|
import "./KvSecondaryNav.css";
|
|
4
4
|
import C from "../_virtual/_plugin-vue_export-helper.js";
|
|
5
5
|
const L = { class: "kv-secondary-nav__links tw-flex tw-flex-col md:tw-flex-row tw-items-center tw-gap-3" };
|
|
6
6
|
function N(p, w, t, e, E, A) {
|
|
7
7
|
const g = l("kv-material-icon"), h = l("kv-page-container"), k = l("kv-theme-provider");
|
|
8
|
-
return i(), d(k, {
|
|
9
|
-
theme: e.themeStyle,
|
|
10
|
-
class: "kv-tailwind"
|
|
11
|
-
}, {
|
|
8
|
+
return i(), d(k, { theme: e.themeStyle }, {
|
|
12
9
|
default: o(() => [
|
|
13
10
|
r("div", {
|
|
14
11
|
class: a(["tw-z-1 tw-w-full kv-secondary-nav-holder relative tw-text-primary", e.bgClass])
|
|
@@ -16,7 +13,7 @@ function N(p, w, t, e, E, A) {
|
|
|
16
13
|
r("div", {
|
|
17
14
|
class: a(["tw-w-full tw-overflow-x-auto kv-secondary-nav tw-absolute tw-top-0 tw-left-0 tw-right-0", e.bgClass])
|
|
18
15
|
}, [
|
|
19
|
-
|
|
16
|
+
v(h, null, {
|
|
20
17
|
default: o(() => [
|
|
21
18
|
r("div", {
|
|
22
19
|
ref: "navInner",
|
|
@@ -26,7 +23,7 @@ function N(p, w, t, e, E, A) {
|
|
|
26
23
|
key: 0,
|
|
27
24
|
class: a(["kv-secondary-nav__heading-container", { "tw-block md:tw-hidden": t.linkAlignment === "left" || t.linkAlignment === "center" }])
|
|
28
25
|
}, [
|
|
29
|
-
(i(), d(
|
|
26
|
+
(i(), d(s(e.hasHeadingLink ? t.headingLink.isExternal ? "a" : "router-link" : "div"), {
|
|
30
27
|
to: e.hasHeadingLink ? t.headingLink.isExternal ? void 0 : t.headingLink.href : void 0,
|
|
31
28
|
href: e.hasHeadingLink && t.headingLink.isExternal ? t.headingLink.href : void 0,
|
|
32
29
|
class: a(["kv-secondary-nav__heading tw-text-h3 tw-text-primary tw-bg-transparent tw-border-none tw-no-underline", {
|
|
@@ -43,7 +40,7 @@ function N(p, w, t, e, E, A) {
|
|
|
43
40
|
class: "kv-secondary-nav__toggle tw-flex md:tw-hidden tw-text-primary tw-bg-transparent tw-border-none tw-cursor-pointer",
|
|
44
41
|
onClick: w[0] || (w[0] = (...n) => e.toggleSubNavigation && e.toggleSubNavigation(...n))
|
|
45
42
|
}, [
|
|
46
|
-
|
|
43
|
+
v(g, {
|
|
47
44
|
icon: e.subNavigationOpen ? e.mdiChevronUp : e.mdiChevronDown
|
|
48
45
|
}, null, 8, ["icon"])
|
|
49
46
|
]),
|
|
@@ -56,7 +53,7 @@ function N(p, w, t, e, E, A) {
|
|
|
56
53
|
key: f,
|
|
57
54
|
class: "kv-secondary-nav__link-item tw-w-full md:tw-w-auto"
|
|
58
55
|
}, [
|
|
59
|
-
(i(), d(
|
|
56
|
+
(i(), d(s(n.isExternal ? "a" : "router-link"), {
|
|
60
57
|
to: n.isExternal ? void 0 : n.href,
|
|
61
58
|
href: n.isExternal ? n.href : void 0,
|
|
62
59
|
class: a([{
|
|
@@ -83,7 +80,7 @@ function N(p, w, t, e, E, A) {
|
|
|
83
80
|
_: 1
|
|
84
81
|
}, 8, ["theme"]);
|
|
85
82
|
}
|
|
86
|
-
const z = /* @__PURE__ */ C(x, [["render", N], ["__scopeId", "data-v-
|
|
83
|
+
const z = /* @__PURE__ */ C(x, [["render", N], ["__scopeId", "data-v-230060bf"]]);
|
|
87
84
|
export {
|
|
88
85
|
z as default
|
|
89
86
|
};
|
package/dist/vue/KvTextLink.js
CHANGED
|
@@ -7,7 +7,7 @@ function u(a, _, t, e, k, x) {
|
|
|
7
7
|
ref: "buttonRef",
|
|
8
8
|
to: t.to,
|
|
9
9
|
disabled: t.state === "disabled",
|
|
10
|
-
class: s(["tw-text-
|
|
10
|
+
class: s(["tw-text-label tw-text-link", {
|
|
11
11
|
"tw-opacity-low tw-pointer-events-none": t.state === "disabled",
|
|
12
12
|
"tw-group tw-inline-flex tw-items-center tw-gap-x-0.5": t.icon
|
|
13
13
|
}]),
|
|
@@ -24,7 +24,7 @@ function u(a, _, t, e, k, x) {
|
|
|
24
24
|
_: 3
|
|
25
25
|
}, 8, ["to", "disabled", "class", "onClick"]);
|
|
26
26
|
}
|
|
27
|
-
const
|
|
27
|
+
const g = /* @__PURE__ */ f(r, [["render", u]]);
|
|
28
28
|
export {
|
|
29
|
-
|
|
29
|
+
g as default
|
|
30
30
|
};
|
package/dist/vue/KvTooltip.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
.tooltip-pane[data-v-
|
|
1
|
+
.tooltip-pane[data-v-46d2c93a],.tooltip-arrow[data-v-46d2c93a]{box-shadow:0 4px 12px #00000014}.tooltip-arrow[data-v-46d2c93a]{margin:.5rem}.tooltip-pane--light .tooltip-arrow[data-v-46d2c93a]{border-color:#fff}.tooltip-pane--dark .tooltip-arrow[data-v-46d2c93a]{border-color:#212121}.tooltip-pane--dark[data-v-46d2c93a] .tw-text-link{color:#78c79f}.tooltip-pane--dark[data-v-46d2c93a] .tw-text-link:hover,.tooltip-pane--dark[data-v-46d2c93a] .tw-text-link:focus{color:#fff}.tooltip-pane[x-placement^=top][data-v-46d2c93a]{margin-bottom:.5rem}.tooltip-pane[x-placement^=top] .tooltip-arrow[data-v-46d2c93a]{border-width:8px 8px 0 8px;border-left-color:transparent;border-right-color:transparent;border-bottom-color:transparent;left:calc(50% - 8px);bottom:-.5rem;margin-top:0;margin-bottom:0}.tooltip-pane[x-placement^=bottom][data-v-46d2c93a]{margin-top:.5rem}.tooltip-pane[x-placement^=bottom] .tooltip-arrow[data-v-46d2c93a]{border-width:0 8px 8px 8px;border-left-color:transparent;border-right-color:transparent;border-top-color:transparent;left:calc(50% - 8px);top:-.5rem;margin-bottom:0;margin-top:0}.tooltip-pane[x-placement^=right][data-v-46d2c93a]{margin-left:.5rem}.tooltip-pane[x-placement^=right] .tooltip-arrow[data-v-46d2c93a]{border-width:8px 8px 8px 0;border-left-color:transparent;border-top-color:transparent;border-bottom-color:transparent;top:calc(50% - 8px);left:-.5rem;margin-left:0;margin-right:0}.tooltip-pane[x-placement^=left][data-v-46d2c93a]{margin-right:.5rem}.tooltip-pane[x-placement^=left] .tooltip-arrow[data-v-46d2c93a]{border-width:8px 0 8px 8px;border-top-color:transparent;border-right-color:transparent;border-bottom-color:transparent;top:calc(50% - 8px);right:-.5rem;margin-left:0;margin-right:0}
|
package/dist/vue/KvTooltip.js
CHANGED
|
@@ -1,52 +1,52 @@
|
|
|
1
1
|
import f from "./KvTooltip2.js";
|
|
2
|
-
import { resolveComponent as
|
|
2
|
+
import { resolveComponent as c, openBlock as l, createBlock as v, normalizeClass as w, withCtx as u, createElementVNode as i, normalizeStyle as n, createElementBlock as p, renderSlot as s, createCommentVNode as a } from "vue";
|
|
3
3
|
import "./KvTooltip.css";
|
|
4
4
|
import k from "../_virtual/_plugin-vue_export-helper.js";
|
|
5
5
|
const y = {
|
|
6
6
|
key: 0,
|
|
7
|
-
class: "tw-
|
|
8
|
-
}
|
|
9
|
-
function b(
|
|
10
|
-
const
|
|
11
|
-
return
|
|
12
|
-
|
|
13
|
-
|
|
7
|
+
class: "tw-font-medium tw-mb-1.5"
|
|
8
|
+
};
|
|
9
|
+
function b(e, t, r, o, C, h) {
|
|
10
|
+
const d = c("kv-popper");
|
|
11
|
+
return l(), v(d, {
|
|
12
|
+
ref: "popperRef",
|
|
13
|
+
controller: r.controller,
|
|
14
|
+
"popper-modifiers": o.popperModifiers,
|
|
15
|
+
"popper-placement": r.placement,
|
|
16
|
+
persistent: !!e.$slots.action,
|
|
17
|
+
"transition-type": "kvfastfade",
|
|
18
|
+
class: w(["tooltip-pane tw-absolute tw-rounded tw-z-popover", o.paneClass]),
|
|
19
|
+
onHide: t[0] || (t[0] = (m) => o.handleKvPopperVisibility(!1)),
|
|
20
|
+
onShow: t[1] || (t[1] = (m) => o.handleKvPopperVisibility(!0))
|
|
14
21
|
}, {
|
|
15
|
-
default:
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
"
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
}, {
|
|
26
|
-
default: n(() => [
|
|
27
|
-
i("div", {
|
|
28
|
-
class: "tw-p-2.5",
|
|
29
|
-
style: w({ maxWidth: r.maxWidth })
|
|
30
|
-
}, [
|
|
31
|
-
o.$slots.title ? (p(), _("div", y, [
|
|
32
|
-
d(o.$slots, "title", {}, void 0, !0)
|
|
33
|
-
])) : u("", !0),
|
|
34
|
-
i("div", h, [
|
|
35
|
-
d(o.$slots, "default", {}, void 0, !0)
|
|
36
|
-
])
|
|
37
|
-
], 4),
|
|
38
|
-
e[2] || (e[2] = i("div", {
|
|
39
|
-
class: "tooltip-arrow tw-absolute tw-w-0 tw-h-0 tw-border-solid",
|
|
40
|
-
"x-arrow": ""
|
|
41
|
-
}, null, -1))
|
|
22
|
+
default: u(() => [
|
|
23
|
+
i("div", {
|
|
24
|
+
class: "tw-p-2.5",
|
|
25
|
+
style: n({ maxWidth: r.maxWidth })
|
|
26
|
+
}, [
|
|
27
|
+
e.$slots.title ? (l(), p("div", y, [
|
|
28
|
+
s(e.$slots, "title", {}, void 0, !0)
|
|
29
|
+
])) : a("", !0),
|
|
30
|
+
i("div", null, [
|
|
31
|
+
s(e.$slots, "default", {}, void 0, !0)
|
|
42
32
|
]),
|
|
43
|
-
|
|
44
|
-
|
|
33
|
+
e.$slots.action ? (l(), p("div", {
|
|
34
|
+
key: 1,
|
|
35
|
+
class: "tooltip-action tw-mt-1.5",
|
|
36
|
+
style: n(o.defaultTheme)
|
|
37
|
+
}, [
|
|
38
|
+
s(e.$slots, "action", { close: o.dismiss }, void 0, !0)
|
|
39
|
+
], 4)) : a("", !0)
|
|
40
|
+
], 4),
|
|
41
|
+
t[2] || (t[2] = i("div", {
|
|
42
|
+
class: "tooltip-arrow tw-absolute tw-w-0 tw-h-0 tw-border-solid",
|
|
43
|
+
"x-arrow": ""
|
|
44
|
+
}, null, -1))
|
|
45
45
|
]),
|
|
46
46
|
_: 3
|
|
47
|
-
}, 8, ["
|
|
47
|
+
}, 8, ["controller", "popper-modifiers", "popper-placement", "persistent", "class"]);
|
|
48
48
|
}
|
|
49
|
-
const
|
|
49
|
+
const K = /* @__PURE__ */ k(f, [["render", b], ["__scopeId", "data-v-46d2c93a"]]);
|
|
50
50
|
export {
|
|
51
|
-
|
|
51
|
+
K as default
|
|
52
52
|
};
|
package/dist/vue/KvTooltip2.js
CHANGED
|
@@ -1,12 +1,10 @@
|
|
|
1
|
-
import { toRefs as
|
|
2
|
-
import {
|
|
3
|
-
import
|
|
4
|
-
|
|
5
|
-
const K = {
|
|
1
|
+
import { toRefs as g, computed as s, ref as w, watch as y } from "vue";
|
|
2
|
+
import { defaultTheme as h } from "@kiva/kv-tokens";
|
|
3
|
+
import b from "./KvPopper.js";
|
|
4
|
+
const T = ["light", "dark"], S = {
|
|
6
5
|
name: "KvTooltip",
|
|
7
6
|
components: {
|
|
8
|
-
KvPopper:
|
|
9
|
-
KvThemeProvider: S
|
|
7
|
+
KvPopper: b
|
|
10
8
|
},
|
|
11
9
|
props: {
|
|
12
10
|
controller: {
|
|
@@ -32,63 +30,56 @@ const K = {
|
|
|
32
30
|
type: Boolean,
|
|
33
31
|
default: !1
|
|
34
32
|
},
|
|
35
|
-
|
|
33
|
+
/**
|
|
34
|
+
* Fixed neutral color of the tooltip.
|
|
35
|
+
* Use `dark` over light surfaces and `light` over dark surfaces.
|
|
36
|
+
*/
|
|
37
|
+
variant: {
|
|
36
38
|
type: String,
|
|
37
|
-
default: "
|
|
39
|
+
default: "light",
|
|
38
40
|
validator(e) {
|
|
39
|
-
return
|
|
40
|
-
"default",
|
|
41
|
-
"ecoGreenLight",
|
|
42
|
-
"ecoGreenDark",
|
|
43
|
-
"ecoLightMarigold",
|
|
44
|
-
"ecoStoneLight"
|
|
45
|
-
].indexOf(e) !== -1;
|
|
41
|
+
return T.indexOf(e) !== -1;
|
|
46
42
|
}
|
|
47
43
|
}
|
|
48
44
|
},
|
|
49
|
-
emits: ["tool-tip-visible"],
|
|
50
|
-
setup(e, { emit:
|
|
45
|
+
emits: ["tool-tip-visible", "dismiss"],
|
|
46
|
+
setup(e, { emit: n }) {
|
|
51
47
|
const {
|
|
52
|
-
modifiers:
|
|
53
|
-
showTooltip:
|
|
54
|
-
|
|
55
|
-
} =
|
|
56
|
-
...
|
|
48
|
+
modifiers: l,
|
|
49
|
+
showTooltip: a,
|
|
50
|
+
variant: p
|
|
51
|
+
} = g(e), u = s(() => ({
|
|
52
|
+
...l.value,
|
|
57
53
|
preventOverflow: {
|
|
58
|
-
...
|
|
54
|
+
...l.value.preventOverflow,
|
|
59
55
|
padding: 10
|
|
60
56
|
}
|
|
61
|
-
})),
|
|
62
|
-
|
|
63
|
-
},
|
|
64
|
-
const
|
|
65
|
-
if (
|
|
66
|
-
const
|
|
67
|
-
|
|
57
|
+
})), r = w(null), d = () => typeof e.controller == "string" ? document.getElementById(e.controller) : e.controller, f = (t) => {
|
|
58
|
+
n("tool-tip-visible", t);
|
|
59
|
+
}, m = (t = !0) => {
|
|
60
|
+
const o = d();
|
|
61
|
+
if (o) {
|
|
62
|
+
const i = t ? "mouseover" : "mouseout";
|
|
63
|
+
o.dispatchEvent(new MouseEvent(i, { bubbles: !0 }));
|
|
68
64
|
}
|
|
69
|
-
},
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
return b(s, (t) => {
|
|
77
|
-
o(!!t);
|
|
65
|
+
}, c = () => {
|
|
66
|
+
var t;
|
|
67
|
+
(t = r.value) == null || t.dismiss(), n("dismiss");
|
|
68
|
+
}, v = s(() => p.value === "dark" ? "tooltip-pane--dark tw-bg-gray-800 tw-text-white" : "tooltip-pane--light tw-bg-white tw-text-gray-800");
|
|
69
|
+
return y(a, (t) => {
|
|
70
|
+
var o, i;
|
|
71
|
+
t ? (o = r.value) == null || o.open() : (i = r.value) == null || i.dismiss();
|
|
78
72
|
}), {
|
|
79
|
-
defaultTheme:
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
popperRef: h,
|
|
87
|
-
themeStyle: y,
|
|
88
|
-
triggerHover: o
|
|
73
|
+
defaultTheme: h,
|
|
74
|
+
dismiss: c,
|
|
75
|
+
handleKvPopperVisibility: f,
|
|
76
|
+
paneClass: v,
|
|
77
|
+
popperModifiers: u,
|
|
78
|
+
popperRef: r,
|
|
79
|
+
triggerHover: m
|
|
89
80
|
};
|
|
90
81
|
}
|
|
91
82
|
};
|
|
92
83
|
export {
|
|
93
|
-
|
|
84
|
+
S as default
|
|
94
85
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@kiva/kv-components",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "10.0.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public"
|
|
@@ -112,5 +112,5 @@
|
|
|
112
112
|
"dependencies": {
|
|
113
113
|
"fuse.js": "^7.1.0"
|
|
114
114
|
},
|
|
115
|
-
"gitHead": "
|
|
115
|
+
"gitHead": "9d71c196ea2984bc7070275550eb2edecec9df7f"
|
|
116
116
|
}
|