@nmorph/nmorph-ui-kit 3.0.6 → 3.0.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.
- package/dist/assets/icons/hand.svg.js +2 -2
- package/dist/components/data/nmorph-calendar/NmorphCalendar.vue.js +34 -36
- package/dist/components/data/nmorph-calendar/NmorphCalendar.vue2.js +80 -78
- package/dist/components/data/nmorph-image-preview/NmorphImagePreview.vue.js +60 -60
- package/dist/components/data/nmorph-image-preview/NmorphImagePreview.vue2.js +118 -94
- package/dist/components/data/nmorph-media-tile/NmorphMediaTile.vue2.js +49 -39
- package/dist/components/data/nmorph-pagination/NmorphPagination.css +1 -1
- package/dist/components/data/nmorph-pagination/NmorphPagination.vue.js +5 -5
- package/dist/components/data/nmorph-pagination/NmorphPagination.vue2.js +80 -56
- package/dist/components/data/nmorph-table/NmorphTable.css +1 -1
- package/dist/components/data/nmorph-table/NmorphTable.vue.js +6 -6
- package/dist/components/data/nmorph-table/NmorphTable.vue2.js +41 -38
- package/dist/components/feedback/nmorph-drawer/NmorphDrawer.vue.js +8 -8
- package/dist/components/feedback/nmorph-drawer/NmorphDrawer.vue2.js +64 -24
- package/dist/index.umd.js +22 -22
- package/dist/package.json.js +1 -1
- package/dist/src/components/data/nmorph-pagination/NmorphPagination.vue.d.ts +3 -0
- package/dist/src/components/data/nmorph-pagination/types.d.ts +3 -0
- package/dist/src/components/data/nmorph-table/NmorphTable.vue.d.ts +2 -20
- package/dist/src/components/data/nmorph-table/types.d.ts +11 -3
- package/dist/style.css +1 -1
- package/package.json +1 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { openBlock as t, createElementBlock as o, createElementVNode as r } from "vue";
|
|
2
2
|
const n = {
|
|
3
3
|
xmlns: "http://www.w3.org/2000/svg",
|
|
4
|
-
viewBox: "0 0 1024
|
|
4
|
+
viewBox: "0 0 1024 1088"
|
|
5
5
|
};
|
|
6
6
|
function c(l, e) {
|
|
7
7
|
return t(), o("svg", n, [...e[0] || (e[0] = [
|
|
@@ -9,7 +9,7 @@ function c(l, e) {
|
|
|
9
9
|
"path",
|
|
10
10
|
{
|
|
11
11
|
fill: "currentColor",
|
|
12
|
-
d: "M360
|
|
12
|
+
d: "M360 131.2c0-39.366 29.55-71.28 66-71.28s66 31.914 66 71.28v453.6h32V72.88c0-39.366 29.55-71.28 66-71.28s66 31.914 66 71.28V584.8h32v-432c0-39.366 29.55-71.28 66-71.28s66 31.914 66 71.28v457.92h30V256.48c0-39.366 29.55-71.28 66-71.28s66 31.914 66 71.28V736c0 181.332-136.1 328.32-304 328.32h-82c-98.69 0-190.2-55.62-241.34-146.794L109.73 665.67a70 75.6 0 0 1 120.06-77.5L360 822.4z"
|
|
13
13
|
},
|
|
14
14
|
null,
|
|
15
15
|
-1
|
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
import './NmorphCalendar.css';
|
|
2
2
|
import f from "./NmorphCalendar.vue2.js";
|
|
3
|
-
import { openBlock as o, createElementBlock as
|
|
3
|
+
import { openBlock as o, createElementBlock as r, normalizeStyle as k, normalizeClass as i, renderSlot as n, createVNode as s, mergeProps as C, withCtx as l, Fragment as c, renderList as y, createBlock as D, createElementVNode as m, createTextVNode as _, toDisplayString as v } from "vue";
|
|
4
4
|
/* empty css */
|
|
5
|
-
import
|
|
5
|
+
import T from "../../../_virtual/_plugin-vue_export-helper.js";
|
|
6
6
|
const g = ["data-date", "onClick"];
|
|
7
|
-
function
|
|
8
|
-
return o(),
|
|
7
|
+
function p(d, B, M, a, w, x) {
|
|
8
|
+
return o(), r(
|
|
9
9
|
"div",
|
|
10
10
|
{
|
|
11
|
-
class:
|
|
11
|
+
class: i(a.modifiers),
|
|
12
12
|
style: k(a.styles)
|
|
13
13
|
},
|
|
14
14
|
[
|
|
15
|
-
|
|
15
|
+
n(d.$slots, "header", {}, () => [
|
|
16
16
|
s(a.NmorphCalendarHeader, {
|
|
17
17
|
year: a.initialDate.getFullYear(),
|
|
18
18
|
month: a.initialDate.getMonth(),
|
|
@@ -25,54 +25,52 @@ function T(d, p, B, a, M, w) {
|
|
|
25
25
|
onClickToday: a.setTodayMonth
|
|
26
26
|
}, null, 8, ["year", "month", "design", "show-previous-month-button", "show-today-button", "show-next-month-button"])
|
|
27
27
|
]),
|
|
28
|
-
|
|
29
|
-
s(a.NmorphTable, {
|
|
28
|
+
n(d.$slots, "content", {}, () => [
|
|
29
|
+
s(a.NmorphTable, C({
|
|
30
30
|
data: a.calendar,
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
design: a.props.design
|
|
34
|
-
}, {
|
|
31
|
+
"row-hover": !1
|
|
32
|
+
}, a.tableDesignProps), {
|
|
35
33
|
default: l(() => [
|
|
36
|
-
(o(!0),
|
|
34
|
+
(o(!0), r(
|
|
37
35
|
c,
|
|
38
36
|
null,
|
|
39
|
-
y(a.days, (
|
|
40
|
-
key: `${
|
|
41
|
-
prop:
|
|
42
|
-
label:
|
|
37
|
+
y(a.days, (t) => (o(), D(a.NmorphTableColumn, {
|
|
38
|
+
key: `${t}`,
|
|
39
|
+
prop: t,
|
|
40
|
+
label: t.toUpperCase()
|
|
43
41
|
}, {
|
|
44
42
|
default: l(({ scope: b }) => [
|
|
45
|
-
(o(!0),
|
|
43
|
+
(o(!0), r(
|
|
46
44
|
c,
|
|
47
45
|
null,
|
|
48
|
-
y(b.rows, (
|
|
49
|
-
key:
|
|
50
|
-
row:
|
|
46
|
+
y(b.rows, (e, h) => (o(), D(a.NmorphTableCell, {
|
|
47
|
+
key: h,
|
|
48
|
+
row: h
|
|
51
49
|
}, {
|
|
52
50
|
default: l(() => [
|
|
53
|
-
|
|
54
|
-
"data-date": `${a.dateData(t
|
|
55
|
-
class:
|
|
51
|
+
m("div", {
|
|
52
|
+
"data-date": `${a.dateData(e[t]).date}`,
|
|
53
|
+
class: i([
|
|
56
54
|
"nmorph-calendar-date",
|
|
57
|
-
`nmorph-calendar-date--${a.dateData(t
|
|
55
|
+
`nmorph-calendar-date--${a.dateData(e[t]).monthType}`,
|
|
58
56
|
{
|
|
59
|
-
"nmorph-calendar-date--today": a.dateData(t
|
|
57
|
+
"nmorph-calendar-date--today": a.dateData(e[t]).isToday && !a.dateData(e[t]).hidden && a.props.markToday
|
|
60
58
|
},
|
|
61
|
-
{ "nmorph-calendar-date--hidden": a.dateData(t
|
|
59
|
+
{ "nmorph-calendar-date--hidden": a.dateData(e[t]).hidden },
|
|
62
60
|
{
|
|
63
|
-
"nmorph-calendar-date--selected": a.isValueSelected(a.dateData(t
|
|
61
|
+
"nmorph-calendar-date--selected": a.isValueSelected(a.dateData(e[t]).date)
|
|
64
62
|
}
|
|
65
63
|
]),
|
|
66
|
-
onClick: (
|
|
64
|
+
onClick: (P) => a.clickDate(a.dateData(e[t]))
|
|
67
65
|
}, [
|
|
68
|
-
|
|
66
|
+
n(d.$slots, "date-cell", {
|
|
69
67
|
scope: {
|
|
70
|
-
...a.dateData(t
|
|
71
|
-
selected: a.isValueSelected(a.dateData(t
|
|
68
|
+
...a.dateData(e[t]),
|
|
69
|
+
selected: a.isValueSelected(a.dateData(e[t]).date)
|
|
72
70
|
}
|
|
73
71
|
}, () => [
|
|
74
72
|
_(
|
|
75
|
-
|
|
73
|
+
v(a.dateData(e[t]).hidden ? "-" : a.dateData(e[t]).value),
|
|
76
74
|
1
|
|
77
75
|
/* TEXT */
|
|
78
76
|
)
|
|
@@ -95,14 +93,14 @@ function T(d, p, B, a, M, w) {
|
|
|
95
93
|
]),
|
|
96
94
|
_: 3
|
|
97
95
|
/* FORWARDED */
|
|
98
|
-
},
|
|
96
|
+
}, 16, ["data"])
|
|
99
97
|
])
|
|
100
98
|
],
|
|
101
99
|
6
|
|
102
100
|
/* CLASS, STYLE */
|
|
103
101
|
);
|
|
104
102
|
}
|
|
105
|
-
const
|
|
103
|
+
const E = /* @__PURE__ */ T(f, [["render", p], ["__file", "/builds/ketjo/nmorph/library/src/components/data/nmorph-calendar/NmorphCalendar.vue"]]);
|
|
106
104
|
export {
|
|
107
|
-
|
|
105
|
+
E as default
|
|
108
106
|
};
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import './NmorphCalendar.css';
|
|
2
|
-
import { defineComponent as
|
|
3
|
-
import { useModifiers as
|
|
4
|
-
import { createCssSizeVariables as
|
|
5
|
-
import
|
|
6
|
-
import { useCalendarTexts as
|
|
7
|
-
import { hasAnyRangeDateInPrevMonth as
|
|
8
|
-
import
|
|
9
|
-
import
|
|
10
|
-
import
|
|
11
|
-
const
|
|
2
|
+
import { defineComponent as O, ref as x, onMounted as k, reactive as j, watch as h, computed as u } from "vue";
|
|
3
|
+
import { useModifiers as z } from "../../../utils/create-modifiers.js";
|
|
4
|
+
import { createCssSizeVariables as W } from "../../../utils/common.js";
|
|
5
|
+
import Z from "./inner-components/nmorph-calendar-header/NmorphCalendarHeader.vue.js";
|
|
6
|
+
import { useCalendarTexts as F } from "./hooks/use-calendar-texts.js";
|
|
7
|
+
import { hasAnyRangeDateInPrevMonth as G, hasAnyRangeDateInNextMonth as J, isTodayInMonthRange as K, resetTimeToZero as d, getMonthDaysByWeek as L } from "./utils.js";
|
|
8
|
+
import Q from "../nmorph-table/components/nmorph-table-cell/NmorphTableCell.vue.js";
|
|
9
|
+
import U from "../nmorph-table/components/nmorph-table-column/NmorphTableColumn.vue.js";
|
|
10
|
+
import X from "../nmorph-table/NmorphTable.vue.js";
|
|
11
|
+
const se = /* @__PURE__ */ O({
|
|
12
12
|
__name: "NmorphCalendar",
|
|
13
13
|
props: {
|
|
14
14
|
markToday: { type: Boolean, required: !1, default: !0 },
|
|
@@ -22,119 +22,121 @@ const ue = /* @__PURE__ */ R({
|
|
|
22
22
|
emits: ["update:model-value", "update-initial-date"],
|
|
23
23
|
setup(N, { expose: b, emit: _ }) {
|
|
24
24
|
b();
|
|
25
|
-
const
|
|
26
|
-
|
|
25
|
+
const a = N, s = _, { days: v } = F(), y = () => {
|
|
26
|
+
o.value = M.value;
|
|
27
27
|
}, C = () => {
|
|
28
|
-
|
|
28
|
+
o.value = /* @__PURE__ */ new Date();
|
|
29
29
|
}, g = () => {
|
|
30
|
-
|
|
31
|
-
},
|
|
30
|
+
o.value = A.value;
|
|
31
|
+
}, i = () => {
|
|
32
32
|
throw new Error("model value and type prop not matched");
|
|
33
33
|
}, c = (e) => {
|
|
34
34
|
if (e === null) return null;
|
|
35
|
-
if (
|
|
35
|
+
if (a.type === "date") {
|
|
36
36
|
if (e instanceof Date)
|
|
37
37
|
return d(e);
|
|
38
|
-
|
|
38
|
+
i();
|
|
39
39
|
}
|
|
40
|
-
const
|
|
41
|
-
if (
|
|
42
|
-
if (
|
|
43
|
-
return e.map((
|
|
44
|
-
|
|
40
|
+
const l = Array.isArray(e) && e.every((r) => r instanceof Date);
|
|
41
|
+
if (a.type === "dates") {
|
|
42
|
+
if (l)
|
|
43
|
+
return e.map((r) => d(r));
|
|
44
|
+
i();
|
|
45
45
|
}
|
|
46
|
-
if (
|
|
47
|
-
if (
|
|
48
|
-
return e.map((
|
|
49
|
-
|
|
46
|
+
if (a.type === "daterange") {
|
|
47
|
+
if (l)
|
|
48
|
+
return e.map((r) => d(r)).slice(0, 2);
|
|
49
|
+
i();
|
|
50
50
|
}
|
|
51
51
|
}, q = (e) => {
|
|
52
52
|
if (t.value === null) return;
|
|
53
|
-
const { monthType:
|
|
54
|
-
if (
|
|
55
|
-
|
|
53
|
+
const { monthType: l, hidden: r } = e;
|
|
54
|
+
if (r) return;
|
|
55
|
+
l === "next" && g(), l === "previous" && y();
|
|
56
56
|
const { date: n } = e;
|
|
57
|
-
if (
|
|
58
|
-
if (!Array.isArray(t.value)) return
|
|
59
|
-
const m = n.toDateString(), w = t.value.map((
|
|
60
|
-
w !== -1 ? t.value.splice(w, 1) : t.value.push(n),
|
|
57
|
+
if (a.type === "date" && (t.value = n, s("update:model-value", t.value)), a.type === "dates") {
|
|
58
|
+
if (!Array.isArray(t.value)) return i();
|
|
59
|
+
const m = n.toDateString(), w = t.value.map((R) => R.toDateString()).indexOf(m);
|
|
60
|
+
w !== -1 ? t.value.splice(w, 1) : t.value.push(n), s("update:model-value", t.value);
|
|
61
61
|
}
|
|
62
|
-
if (
|
|
63
|
-
if (!Array.isArray(t.value)) return
|
|
64
|
-
t.value.length === 0 ? t.value.push(n) : t.value.length === 1 ? n < t.value[0] ? t.value = [n, t.value[0]] : t.value.push(n) : t.value = [n],
|
|
62
|
+
if (a.type === "daterange") {
|
|
63
|
+
if (!Array.isArray(t.value)) return i();
|
|
64
|
+
t.value.length === 0 ? t.value.push(n) : t.value.length === 1 ? n < t.value[0] ? t.value = [n, t.value[0]] : t.value.push(n) : t.value = [n], s("update:model-value", t.value.slice(0, 2));
|
|
65
65
|
}
|
|
66
|
-
}, D = (e,
|
|
67
|
-
const [
|
|
68
|
-
return
|
|
66
|
+
}, D = (e, l) => {
|
|
67
|
+
const [r, n] = l;
|
|
68
|
+
return l.length === 1 ? e.toDateString() === r.toDateString() : r && n ? e >= d(r) && e <= d(n) : !1;
|
|
69
69
|
}, B = (e) => {
|
|
70
70
|
if (t.value === null) return !1;
|
|
71
|
-
if (
|
|
72
|
-
return Array.isArray(t.value) ?
|
|
73
|
-
if (
|
|
74
|
-
return Array.isArray(t.value) ? !!t.value.find((
|
|
75
|
-
if (
|
|
76
|
-
return Array.isArray(t.value) ? D(e, t.value) :
|
|
77
|
-
},
|
|
78
|
-
|
|
79
|
-
|
|
71
|
+
if (a.type === "date")
|
|
72
|
+
return Array.isArray(t.value) ? i() : t.value.toDateString() === e.toDateString();
|
|
73
|
+
if (a.type === "dates")
|
|
74
|
+
return Array.isArray(t.value) ? !!t.value.find((r) => r.toDateString() === e.toDateString()) : i();
|
|
75
|
+
if (a.type === "daterange")
|
|
76
|
+
return Array.isArray(t.value) ? D(e, t.value) : i();
|
|
77
|
+
}, o = x(a.initialDate), t = x(c(a.modelValue));
|
|
78
|
+
k(() => {
|
|
79
|
+
s("update:model-value", t.value);
|
|
80
80
|
});
|
|
81
|
-
let p =
|
|
81
|
+
let p = j([]);
|
|
82
82
|
const f = () => {
|
|
83
|
-
p = [],
|
|
84
|
-
const
|
|
85
|
-
|
|
86
|
-
const T =
|
|
87
|
-
|
|
88
|
-
}), p.push(
|
|
83
|
+
p = [], L(o, a.range).forEach((l) => {
|
|
84
|
+
const r = {};
|
|
85
|
+
l.forEach((n, m) => {
|
|
86
|
+
const T = v[m];
|
|
87
|
+
r[T] = n;
|
|
88
|
+
}), p.push(r);
|
|
89
89
|
});
|
|
90
90
|
};
|
|
91
|
-
|
|
92
|
-
() =>
|
|
91
|
+
h(
|
|
92
|
+
() => a.initialDate,
|
|
93
93
|
(e) => {
|
|
94
|
-
|
|
94
|
+
o.value = e;
|
|
95
95
|
},
|
|
96
96
|
{
|
|
97
97
|
deep: !0
|
|
98
98
|
}
|
|
99
|
-
),
|
|
100
|
-
f(),
|
|
101
|
-
}),
|
|
102
|
-
() =>
|
|
99
|
+
), h(o, () => {
|
|
100
|
+
f(), s("update-initial-date", o.value);
|
|
101
|
+
}), h(
|
|
102
|
+
() => a.modelValue,
|
|
103
103
|
(e) => {
|
|
104
104
|
t.value = c(e);
|
|
105
105
|
}
|
|
106
106
|
);
|
|
107
|
-
const M =
|
|
108
|
-
const { range: e } =
|
|
107
|
+
const M = u(() => new Date(o.value.setMonth(o.value.getMonth() - 1))), A = u(() => new Date(o.value.setMonth(o.value.getMonth() + 1))), V = u(() => {
|
|
108
|
+
const { range: e } = a, l = e ? G(o.value, e[0]) : !0, r = e ? J(o.value, e[1]) : !0, n = K(e);
|
|
109
109
|
return {
|
|
110
|
-
showPreviousMonthButton:
|
|
111
|
-
showNextMonthButton:
|
|
110
|
+
showPreviousMonthButton: l,
|
|
111
|
+
showNextMonthButton: r,
|
|
112
112
|
showTodayButton: n
|
|
113
113
|
};
|
|
114
|
-
}), E =
|
|
115
|
-
() =>
|
|
114
|
+
}), E = u(
|
|
115
|
+
() => z({
|
|
116
116
|
"nmorph-calendar": []
|
|
117
117
|
})
|
|
118
|
-
),
|
|
119
|
-
() =>
|
|
120
|
-
"--nmorph-private-calendar-cell-height":
|
|
118
|
+
), P = u(
|
|
119
|
+
() => W({
|
|
120
|
+
"--nmorph-private-calendar-cell-height": a.cellHeight
|
|
121
121
|
})
|
|
122
|
+
), H = u(
|
|
123
|
+
() => a.design === "plain" ? { design: "plain", bordered: !0 } : { design: "nmorph" }
|
|
122
124
|
), I = (e) => e;
|
|
123
125
|
f();
|
|
124
|
-
const S = { props:
|
|
126
|
+
const S = { props: a, emit: s, days: v, setPreviousMonth: y, setTodayMonth: C, setNextMonth: g, wrongType: i, convertValue: c, clickDate: q, isDateInRange: D, isValueSelected: B, initialDate: o, selectedValue: t, get calendar() {
|
|
125
127
|
return p;
|
|
126
128
|
}, set calendar(e) {
|
|
127
129
|
p = e;
|
|
128
|
-
}, updateCalendar: f, prevMonth: M, nextMonth: A, showHeaderButtons: V, modifiers: E, styles: H, dateData: I, get NmorphTable() {
|
|
129
|
-
return
|
|
130
|
+
}, updateCalendar: f, prevMonth: M, nextMonth: A, showHeaderButtons: V, modifiers: E, styles: P, tableDesignProps: H, dateData: I, get NmorphTable() {
|
|
131
|
+
return X;
|
|
130
132
|
}, get NmorphTableColumn() {
|
|
131
|
-
return
|
|
133
|
+
return U;
|
|
132
134
|
}, get NmorphTableCell() {
|
|
133
|
-
return
|
|
134
|
-
}, NmorphCalendarHeader:
|
|
135
|
+
return Q;
|
|
136
|
+
}, NmorphCalendarHeader: Z };
|
|
135
137
|
return Object.defineProperty(S, "__isScriptSetup", { enumerable: !1, value: !0 }), S;
|
|
136
138
|
}
|
|
137
139
|
});
|
|
138
140
|
export {
|
|
139
|
-
|
|
141
|
+
se as default
|
|
140
142
|
};
|
|
@@ -1,96 +1,96 @@
|
|
|
1
1
|
import './NmorphImagePreview.css';
|
|
2
2
|
import _ from "./NmorphImagePreview.vue2.js";
|
|
3
|
-
import { openBlock as n, createElementBlock as a, Fragment as g, normalizeStyle as
|
|
3
|
+
import { openBlock as n, createElementBlock as a, Fragment as g, normalizeStyle as p, normalizeClass as w, createElementVNode as m, renderList as v, withModifiers as k, createVNode as l, createSlots as d, withCtx as o, renderSlot as t, toDisplayString as y, createCommentVNode as c, createBlock as s, resolveDynamicComponent as f } from "vue";
|
|
4
4
|
/* empty css */
|
|
5
5
|
import b from "../../../_virtual/_plugin-vue_export-helper.js";
|
|
6
6
|
const N = ["aria-label", "onClick"], C = {
|
|
7
7
|
key: 0,
|
|
8
8
|
class: "nmorph-image-preview__trigger-more"
|
|
9
9
|
}, S = { class: "nmorph-image-preview__action-element" };
|
|
10
|
-
function I(
|
|
10
|
+
function I(e, T, B, r, P, z) {
|
|
11
11
|
return n(), a(
|
|
12
12
|
g,
|
|
13
13
|
null,
|
|
14
14
|
[
|
|
15
|
-
|
|
15
|
+
r.props.showTrigger ? (n(), a(
|
|
16
16
|
"div",
|
|
17
17
|
{
|
|
18
18
|
key: 0,
|
|
19
|
-
class: w(
|
|
20
|
-
style:
|
|
19
|
+
class: w(r.modifiers),
|
|
20
|
+
style: p(r.triggerStyle)
|
|
21
21
|
},
|
|
22
22
|
[
|
|
23
|
-
|
|
23
|
+
m("div", {
|
|
24
24
|
class: "nmorph-image-preview__trigger",
|
|
25
|
-
onClick:
|
|
25
|
+
onClick: r.clickHandler
|
|
26
26
|
}, [
|
|
27
|
-
|
|
27
|
+
r.showGalleryTrigger ? (n(!0), a(
|
|
28
28
|
g,
|
|
29
29
|
{ key: 0 },
|
|
30
|
-
|
|
30
|
+
v(r.triggerSources, (i) => (n(), a("button", {
|
|
31
31
|
key: `${i.src}-${i.index}`,
|
|
32
32
|
type: "button",
|
|
33
33
|
class: "nmorph-image-preview__trigger-item",
|
|
34
|
-
"aria-label":
|
|
35
|
-
onClick: k((h) =>
|
|
34
|
+
"aria-label": r.getTriggerLabel(i.index),
|
|
35
|
+
onClick: k((h) => r.openPreviewAt(i.index), ["stop"])
|
|
36
36
|
}, [
|
|
37
|
-
l(
|
|
37
|
+
l(r.NmorphImage, {
|
|
38
38
|
src: i.src,
|
|
39
|
-
alt:
|
|
40
|
-
fit:
|
|
39
|
+
alt: r.getTriggerLabel(i.index),
|
|
40
|
+
fit: r.props.fit,
|
|
41
41
|
design: "plain",
|
|
42
42
|
"frame-border": 0
|
|
43
|
-
},
|
|
43
|
+
}, d({
|
|
44
44
|
_: 2
|
|
45
45
|
/* DYNAMIC */
|
|
46
46
|
}, [
|
|
47
|
-
|
|
47
|
+
e.$slots.loading ? {
|
|
48
48
|
name: "loading",
|
|
49
49
|
fn: o(() => [
|
|
50
|
-
t(
|
|
50
|
+
t(e.$slots, "loading")
|
|
51
51
|
]),
|
|
52
52
|
key: "0"
|
|
53
53
|
} : void 0,
|
|
54
|
-
|
|
54
|
+
e.$slots.error ? {
|
|
55
55
|
name: "error",
|
|
56
56
|
fn: o(() => [
|
|
57
|
-
t(
|
|
57
|
+
t(e.$slots, "error")
|
|
58
58
|
]),
|
|
59
59
|
key: "1"
|
|
60
60
|
} : void 0
|
|
61
61
|
]), 1032, ["src", "alt", "fit"]),
|
|
62
|
-
i.index ===
|
|
62
|
+
i.index === r.lastVisibleTriggerIndex && r.hiddenTriggerCount > 0 ? (n(), a(
|
|
63
63
|
"span",
|
|
64
64
|
C,
|
|
65
|
-
" +" + y(
|
|
65
|
+
" +" + y(r.hiddenTriggerCount),
|
|
66
66
|
1
|
|
67
67
|
/* TEXT */
|
|
68
68
|
)) : c("v-if", !0)
|
|
69
69
|
], 8, N))),
|
|
70
70
|
128
|
|
71
71
|
/* KEYED_FRAGMENT */
|
|
72
|
-
)) : (n(), s(
|
|
72
|
+
)) : (n(), s(r.NmorphImage, {
|
|
73
73
|
key: 1,
|
|
74
|
-
src:
|
|
75
|
-
alt:
|
|
76
|
-
fit:
|
|
74
|
+
src: r.triggerSource,
|
|
75
|
+
alt: r.props.alt,
|
|
76
|
+
fit: r.props.fit,
|
|
77
77
|
design: "plain",
|
|
78
78
|
"frame-border": 0
|
|
79
|
-
},
|
|
79
|
+
}, d({
|
|
80
80
|
_: 2
|
|
81
81
|
/* DYNAMIC */
|
|
82
82
|
}, [
|
|
83
|
-
|
|
83
|
+
e.$slots.loading ? {
|
|
84
84
|
name: "loading",
|
|
85
85
|
fn: o(() => [
|
|
86
|
-
t(
|
|
86
|
+
t(e.$slots, "loading")
|
|
87
87
|
]),
|
|
88
88
|
key: "0"
|
|
89
89
|
} : void 0,
|
|
90
|
-
|
|
90
|
+
e.$slots.error ? {
|
|
91
91
|
name: "error",
|
|
92
92
|
fn: o(() => [
|
|
93
|
-
t(
|
|
93
|
+
t(e.$slots, "error")
|
|
94
94
|
]),
|
|
95
95
|
key: "1"
|
|
96
96
|
} : void 0
|
|
@@ -100,34 +100,34 @@ function I(r, B, T, e, L, P) {
|
|
|
100
100
|
6
|
|
101
101
|
/* CLASS, STYLE */
|
|
102
102
|
)) : c("v-if", !0),
|
|
103
|
-
|
|
103
|
+
r.open ? (n(), s(r.NmorphPreviewPortal, {
|
|
104
104
|
key: 1,
|
|
105
|
-
show:
|
|
106
|
-
"z-index":
|
|
105
|
+
show: r.open,
|
|
106
|
+
"z-index": r.props.zIndex,
|
|
107
107
|
"root-class": "nmorph-image-preview__portal",
|
|
108
|
-
"state-class":
|
|
108
|
+
"state-class": r.modifiers,
|
|
109
109
|
"content-class": "nmorph-image-preview__content",
|
|
110
110
|
"left-class": "nmorph-image-preview__left",
|
|
111
111
|
"right-class": "nmorph-image-preview__right",
|
|
112
112
|
"actions-class": "nmorph-image-preview__actions",
|
|
113
|
-
"navigation-button-margin":
|
|
114
|
-
"content-width":
|
|
115
|
-
"content-height":
|
|
116
|
-
"show-navigation":
|
|
117
|
-
"show-action-bar":
|
|
118
|
-
onClose:
|
|
119
|
-
onPrevious:
|
|
120
|
-
onNext:
|
|
113
|
+
"navigation-button-margin": r.props.navigationButtonMargin,
|
|
114
|
+
"content-width": r.props.previewWidth,
|
|
115
|
+
"content-height": r.props.previewHeight,
|
|
116
|
+
"show-navigation": r.showNavigation,
|
|
117
|
+
"show-action-bar": r.props.showActionBar,
|
|
118
|
+
onClose: r.closeHandler,
|
|
119
|
+
onPrevious: r.previousHandler,
|
|
120
|
+
onNext: r.nextHandler
|
|
121
121
|
}, {
|
|
122
122
|
actions: o(() => [
|
|
123
123
|
(n(), a(
|
|
124
124
|
g,
|
|
125
125
|
null,
|
|
126
|
-
|
|
126
|
+
v(r.actions, (i, h) => m("div", {
|
|
127
127
|
key: h,
|
|
128
128
|
class: "nmorph-image-preview__action-element"
|
|
129
129
|
}, [
|
|
130
|
-
l(
|
|
130
|
+
l(r.NmorphButton, {
|
|
131
131
|
class: "nmorph-preview-portal__control-button",
|
|
132
132
|
design: "plain",
|
|
133
133
|
borderless: "",
|
|
@@ -135,7 +135,7 @@ function I(r, B, T, e, L, P) {
|
|
|
135
135
|
}, {
|
|
136
136
|
default: o(() => [
|
|
137
137
|
l(
|
|
138
|
-
|
|
138
|
+
r.NmorphIcon,
|
|
139
139
|
null,
|
|
140
140
|
{
|
|
141
141
|
default: o(() => [
|
|
@@ -155,18 +155,18 @@ function I(r, B, T, e, L, P) {
|
|
|
155
155
|
64
|
|
156
156
|
/* STABLE_FRAGMENT */
|
|
157
157
|
)),
|
|
158
|
-
|
|
159
|
-
l(
|
|
158
|
+
m("div", S, [
|
|
159
|
+
l(r.NmorphButton, {
|
|
160
160
|
class: "nmorph-preview-portal__control-button",
|
|
161
161
|
design: "plain",
|
|
162
162
|
borderless: "",
|
|
163
|
-
disabled:
|
|
164
|
-
onClick:
|
|
163
|
+
disabled: r.scaleLevel === 1,
|
|
164
|
+
onClick: r.enlargeShrinkActionData.handler
|
|
165
165
|
}, {
|
|
166
166
|
default: o(() => [
|
|
167
|
-
l(
|
|
167
|
+
l(r.NmorphIcon, null, {
|
|
168
168
|
default: o(() => [
|
|
169
|
-
(n(), s(f(
|
|
169
|
+
(n(), s(f(r.enlargeShrinkActionData.icon)))
|
|
170
170
|
]),
|
|
171
171
|
_: 1
|
|
172
172
|
/* STABLE */
|
|
@@ -178,28 +178,28 @@ function I(r, B, T, e, L, P) {
|
|
|
178
178
|
])
|
|
179
179
|
]),
|
|
180
180
|
default: o(() => [
|
|
181
|
-
l(
|
|
182
|
-
src:
|
|
183
|
-
alt:
|
|
181
|
+
l(r.NmorphImage, {
|
|
182
|
+
src: r.triggerSource,
|
|
183
|
+
alt: r.props.alt,
|
|
184
184
|
fit: "contain",
|
|
185
185
|
design: "plain",
|
|
186
186
|
"frame-border": 0,
|
|
187
|
-
style:
|
|
188
|
-
},
|
|
187
|
+
style: p({ transform: r.imageTransform })
|
|
188
|
+
}, d({
|
|
189
189
|
_: 2
|
|
190
190
|
/* DYNAMIC */
|
|
191
191
|
}, [
|
|
192
|
-
|
|
192
|
+
e.$slots.loading ? {
|
|
193
193
|
name: "loading",
|
|
194
194
|
fn: o(() => [
|
|
195
|
-
t(
|
|
195
|
+
t(e.$slots, "loading")
|
|
196
196
|
]),
|
|
197
197
|
key: "0"
|
|
198
198
|
} : void 0,
|
|
199
|
-
|
|
199
|
+
e.$slots.error ? {
|
|
200
200
|
name: "error",
|
|
201
201
|
fn: o(() => [
|
|
202
|
-
t(
|
|
202
|
+
t(e.$slots, "error")
|
|
203
203
|
]),
|
|
204
204
|
key: "1"
|
|
205
205
|
} : void 0
|