@solar-taro/ui-sun 2.9.0 → 3.1.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/CHANGELOG.md +27 -0
- package/empty/index.d.ts +1 -0
- package/empty/index.scss +23 -0
- package/empty/index.vue.d.ts +18 -0
- package/index.d.ts +4 -0
- package/index.js +44 -36
- package/index10.js +29 -17
- package/index11.js +19 -25
- package/index12.js +81 -34
- package/index13.js +24 -75
- package/index14.js +34 -20
- package/index15.js +72 -46
- package/index16.js +19 -144
- package/index17.js +48 -28
- package/index18.js +144 -21
- package/index19.js +28 -42
- package/index20.js +77 -26
- package/index21.js +19 -10
- package/index22.js +41 -27
- package/index23.js +24 -18
- package/index24.js +14 -32
- package/index25.js +27 -117
- package/index26.js +17 -9
- package/index27.js +34 -11
- package/index28.js +123 -11
- package/index29.js +14 -8
- package/index30.js +10 -9
- package/index31.js +8 -7
- package/index32.js +11 -2
- package/index33.js +8 -2
- package/index34.js +10 -2
- package/index35.js +10 -2
- package/index36.js +1 -1
- package/index37.js +1 -1
- package/index38.js +2 -7
- package/index39.js +1 -1
- package/index4.js +1 -1
- package/index40.js +1 -1
- package/index41.js +1 -1
- package/index42.js +7 -2
- package/index43.js +1 -1
- package/index44.js +1 -1
- package/index45.js +1 -1
- package/index46.js +1 -1
- package/index47.js +1 -1
- package/index48.js +1 -1
- package/index49.js +1 -1
- package/index50.js +1 -1
- package/index51.js +1 -1
- package/index52.js +1 -1
- package/index53.js +1 -1
- package/index54.js +1 -1
- package/index55.js +2 -526
- package/index56.js +2 -3
- package/index57.js +2 -66
- package/index58.js +2 -12
- package/index59.js +2 -25
- package/index60.js +2 -14
- package/index61.js +1 -1
- package/index62.js +1 -1
- package/index63.js +2 -26
- package/index64.js +3 -2
- package/index65.js +525 -505
- package/index66.js +65 -78
- package/index67.js +12 -70
- package/index68.js +25 -69
- package/index69.js +14 -543
- package/index7.js +18 -17
- package/index70.js +26 -2
- package/index72.js +506 -2
- package/index73.js +78 -3
- package/index74.js +70 -2
- package/index75.js +69 -4
- package/index76.js +543 -2
- package/index79.js +2 -2
- package/index8.js +13 -14
- package/index80.js +3 -47
- package/index81.js +2 -82
- package/index82.js +4 -2
- package/index83.js +2 -2
- package/index84.js +2 -2
- package/index85.js +4 -0
- package/index86.js +50 -0
- package/index87.js +84 -0
- package/index88.js +4 -0
- package/index89.js +4 -0
- package/index9.js +16 -30
- package/index90.js +4 -0
- package/index91.js +4 -0
- package/item-divider/index.d.ts +1 -0
- package/item-divider/index.scss +9 -0
- package/item-divider/index.vue.d.ts +18 -0
- package/list/index.d.ts +1 -0
- package/list/index.vue.d.ts +90 -0
- package/package.json +1 -1
- package/stepper/index.d.ts +1 -0
- package/stepper/index.scss +61 -0
- package/stepper/index.vue.d.ts +19 -0
- package/toggle/index.vue.d.ts +2 -2
package/index20.js
CHANGED
|
@@ -1,30 +1,81 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
},
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
"sun-
|
|
19
|
-
}));
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
|
|
1
|
+
import { defineComponent as I, mergeModels as w, useModel as z, ref as f, computed as r, effect as C, unref as T, createVNode as _, normalizeClass as h, createElementVNode as S, openBlock as j, createElementBlock as q } from "vue";
|
|
2
|
+
import { vibrator as v } from "@solar-taro/core";
|
|
3
|
+
import c from "./index29.js";
|
|
4
|
+
const b = T, V = _, m = h, d = S, A = j, D = q, G = ["type", "value", "disabled"], L = /* @__PURE__ */ I({
|
|
5
|
+
__name: "index",
|
|
6
|
+
props: /* @__PURE__ */ w({
|
|
7
|
+
type: { default: "decimal" },
|
|
8
|
+
min: { default: -1 / 0 },
|
|
9
|
+
max: { default: 1 / 0 },
|
|
10
|
+
disabled: { type: Boolean }
|
|
11
|
+
}, {
|
|
12
|
+
modelValue: { default: 0 },
|
|
13
|
+
modelModifiers: {}
|
|
14
|
+
}),
|
|
15
|
+
emits: ["update:modelValue"],
|
|
16
|
+
setup(p) {
|
|
17
|
+
const t = p, u = z(p, "modelValue"), a = f(""), x = r(() => t.type === "integer" ? "number" : "digit"), y = r(() => ({
|
|
18
|
+
"sun-stepper-disabled": t.disabled
|
|
19
|
+
})), o = f(!1), M = r(() => u.value <= t.min), B = r(() => u.value >= t.max);
|
|
20
|
+
function g() {
|
|
21
|
+
const e = u.value;
|
|
22
|
+
e >= t.max || (u.value = i(Math.min(t.max, e + 1)), a.value = s(u.value), v.short());
|
|
23
|
+
}
|
|
24
|
+
function F() {
|
|
25
|
+
const e = u.value;
|
|
26
|
+
e <= t.min || (u.value = i(Math.max(t.min, e - 1)), a.value = s(u.value), v.short());
|
|
27
|
+
}
|
|
28
|
+
function N(e) {
|
|
29
|
+
a.value = e.detail.value;
|
|
30
|
+
let n = E(a.value);
|
|
31
|
+
n > t.max ? n = t.max : n < t.min && (n = t.min), u.value = n;
|
|
32
|
+
}
|
|
33
|
+
function $() {
|
|
34
|
+
o.value = !0;
|
|
35
|
+
}
|
|
36
|
+
function k() {
|
|
37
|
+
a.value = s(u.value), o.value = !1;
|
|
38
|
+
}
|
|
39
|
+
function E(e) {
|
|
40
|
+
return e ? i(Number.parseFloat(e) || 0) : 0;
|
|
41
|
+
}
|
|
42
|
+
function s(e) {
|
|
43
|
+
return e = +e, Number.isFinite(e) ? (t.type === "integer" ? Math.trunc(e) : e).toString() : "";
|
|
44
|
+
}
|
|
45
|
+
function i(e) {
|
|
46
|
+
return t.type === "integer" ? Math.trunc(e) : +e.toFixed(2);
|
|
47
|
+
}
|
|
48
|
+
return C(() => {
|
|
49
|
+
o.value || (a.value = s(u.value));
|
|
50
|
+
}), (e, n) => (A(), D("view", {
|
|
51
|
+
class: m(["sun-stepper", y.value])
|
|
52
|
+
}, [
|
|
53
|
+
d("view", {
|
|
54
|
+
class: m(["sun-stepper-btn sun-stepper-btn-dec", { "sun-stepper-btn-disabled": M.value }]),
|
|
55
|
+
"hover-class": "hover",
|
|
56
|
+
onTap: n[0] || (n[0] = (l) => F())
|
|
57
|
+
}, [
|
|
58
|
+
V(b(c), { name: "remove" })
|
|
59
|
+
], 34),
|
|
60
|
+
d("input", {
|
|
61
|
+
class: "sun-stepper-input",
|
|
62
|
+
type: x.value,
|
|
63
|
+
value: a.value,
|
|
64
|
+
disabled: e.disabled,
|
|
65
|
+
onInput: n[1] || (n[1] = (l) => N(l)),
|
|
66
|
+
onFocus: n[2] || (n[2] = (l) => $()),
|
|
67
|
+
onBlur: n[3] || (n[3] = (l) => k())
|
|
68
|
+
}, null, 40, G),
|
|
69
|
+
d("view", {
|
|
70
|
+
class: m(["sun-stepper-btn sun-stepper-btn-inc", { "sun-stepper-btn-disabled": B.value }]),
|
|
71
|
+
"hover-class": "hover",
|
|
72
|
+
onTap: n[4] || (n[4] = (l) => g())
|
|
73
|
+
}, [
|
|
74
|
+
V(b(c), { name: "add" })
|
|
75
|
+
], 34)
|
|
76
|
+
], 2));
|
|
26
77
|
}
|
|
27
78
|
});
|
|
28
79
|
export {
|
|
29
|
-
|
|
80
|
+
L as default
|
|
30
81
|
};
|
package/index21.js
CHANGED
|
@@ -1,18 +1,27 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
const a =
|
|
3
|
-
__name: "
|
|
1
|
+
import { defineComponent as u, computed as n, renderSlot as c, mergeProps as r, openBlock as l, createElementBlock as d } from "vue";
|
|
2
|
+
const a = c, m = r, p = l, k = d, _ = /* @__PURE__ */ u({
|
|
3
|
+
__name: "sudoku",
|
|
4
4
|
props: {
|
|
5
|
-
|
|
6
|
-
|
|
5
|
+
size: String,
|
|
6
|
+
count: {
|
|
7
|
+
type: Number,
|
|
8
|
+
default: 9
|
|
9
|
+
}
|
|
7
10
|
},
|
|
8
|
-
setup(
|
|
9
|
-
|
|
10
|
-
|
|
11
|
+
setup(o) {
|
|
12
|
+
const e = o, t = n(() => ({
|
|
13
|
+
"sun-sudoku-sm": e.count === 1,
|
|
14
|
+
"sun-sudoku-md": e.count === 2 || e.count === 4,
|
|
15
|
+
"sun-sudoku-lg": e.count === 3 || e.count > 4
|
|
16
|
+
}));
|
|
17
|
+
return (s, i) => (p(), k("view", m(s.$attrs, {
|
|
18
|
+
class: ["sun-sudoku", t.value],
|
|
19
|
+
style: { "--sudoku-width": o.size }
|
|
11
20
|
}), [
|
|
12
|
-
a(
|
|
21
|
+
a(s.$slots, "default")
|
|
13
22
|
], 16));
|
|
14
23
|
}
|
|
15
24
|
});
|
|
16
25
|
export {
|
|
17
|
-
|
|
26
|
+
_ as default
|
|
18
27
|
};
|
package/index22.js
CHANGED
|
@@ -1,35 +1,49 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
import { defineComponent as u, computed as p, renderList as _, Fragment as f, openBlock as d, createElementBlock as g, renderSlot as v, unref as b, createBlock as k, createCommentVNode as h, toDisplayString as B, createTextVNode as y, normalizeClass as C, mergeProps as $ } from "vue";
|
|
2
|
+
import w from "./index29.js";
|
|
3
|
+
const N = _, S = f, r = d, n = g, T = v, V = b, L = k, z = h, D = B, E = y, F = C, P = $, j = ["scroll-left"], q = ["onTap"], I = /* @__PURE__ */ u({
|
|
4
|
+
__name: "index",
|
|
4
5
|
props: {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
outerBordered: { type: Boolean, default: !0 },
|
|
8
|
-
zebra: { type: Boolean },
|
|
9
|
-
size: { default: "default" },
|
|
10
|
-
layout: {}
|
|
6
|
+
tabs: {},
|
|
7
|
+
active: { default: 0 }
|
|
11
8
|
},
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
"
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
"sun-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
9
|
+
emits: ["update:active", "toggle"],
|
|
10
|
+
setup(s, { emit: c }) {
|
|
11
|
+
const a = c, l = s, i = p(() => l.active > 2 ? (l.active - 2) * 150 + "rpx" : 0);
|
|
12
|
+
function m(e) {
|
|
13
|
+
a("toggle", e), a("update:active", e);
|
|
14
|
+
}
|
|
15
|
+
return (e, x) => (r(), n("scroll-view", P(e.$attrs, {
|
|
16
|
+
class: "sun-tabbar",
|
|
17
|
+
"scroll-x": !0,
|
|
18
|
+
"enable-flex": !0,
|
|
19
|
+
enhanced: !0,
|
|
20
|
+
"show-scrollbar": !1,
|
|
21
|
+
"scroll-with-animation": !0,
|
|
22
|
+
"scroll-left": i.value
|
|
24
23
|
}), [
|
|
25
|
-
|
|
26
|
-
|
|
24
|
+
(r(!0), n(S, null, N(e.tabs, (t, o) => (r(), n("view", {
|
|
25
|
+
key: o,
|
|
26
|
+
class: F(["sun-tabbar-item", {
|
|
27
|
+
"sun-tabbar-item-active": e.active === o,
|
|
28
|
+
"sun-tabbar-item-icon-only": !t.text
|
|
29
|
+
}]),
|
|
30
|
+
onTap: (A) => m(o)
|
|
27
31
|
}, [
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
32
|
+
T(e.$slots, "default", {
|
|
33
|
+
tab: t,
|
|
34
|
+
index: o
|
|
35
|
+
}, () => [
|
|
36
|
+
t.icon ? (r(), L(V(w), {
|
|
37
|
+
key: 0,
|
|
38
|
+
class: "sun-tabbar-item-icon",
|
|
39
|
+
name: e.active === o ? t.icon[0] : t.icon[1] || `${t.icon[0]}-outline`
|
|
40
|
+
}, null, 8, ["name"])) : z("", !0),
|
|
41
|
+
E(" " + D(t.text), 1)
|
|
42
|
+
])
|
|
43
|
+
], 42, q))), 128))
|
|
44
|
+
], 16, j));
|
|
31
45
|
}
|
|
32
46
|
});
|
|
33
47
|
export {
|
|
34
|
-
|
|
48
|
+
I as default
|
|
35
49
|
};
|
package/index23.js
CHANGED
|
@@ -1,24 +1,30 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
const
|
|
3
|
-
__name: "
|
|
1
|
+
import { defineComponent as o, computed as r, renderSlot as n, mergeProps as i, openBlock as a, createElementBlock as c } from "vue";
|
|
2
|
+
const d = n, p = i, h = a, m = c, b = /* @__PURE__ */ o({
|
|
3
|
+
__name: "table-cell",
|
|
4
4
|
props: {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
5
|
+
sticky: {},
|
|
6
|
+
head: { type: Boolean },
|
|
7
|
+
width: {},
|
|
8
|
+
maxWidth: {},
|
|
9
|
+
ellipsis: { type: Boolean },
|
|
10
|
+
breakWord: { type: Boolean }
|
|
8
11
|
},
|
|
9
|
-
setup(
|
|
10
|
-
const e =
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
12
|
+
setup(l) {
|
|
13
|
+
const e = l, s = r(() => ({
|
|
14
|
+
"sun-tb-cell-sticky-left": e.sticky === "left",
|
|
15
|
+
"sun-tb-cell-sticky-right": e.sticky === "right",
|
|
16
|
+
"sun-tb-cell-ellipsis": e.ellipsis,
|
|
17
|
+
"sun-tb-cell-head": e.head,
|
|
18
|
+
"sun-tb-cell-break-word": e.breakWord
|
|
19
|
+
}));
|
|
20
|
+
return (t, u) => (h(), m("view", p(t.$attrs, {
|
|
21
|
+
class: ["sun-tb-cell", s.value],
|
|
22
|
+
style: { width: t.width, "min-width": t.width, "max-width": t.maxWidth }
|
|
23
|
+
}), [
|
|
24
|
+
d(t.$slots, "default")
|
|
25
|
+
], 16));
|
|
20
26
|
}
|
|
21
27
|
});
|
|
22
28
|
export {
|
|
23
|
-
|
|
29
|
+
b as default
|
|
24
30
|
};
|
package/index24.js
CHANGED
|
@@ -1,36 +1,18 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
const
|
|
3
|
-
__name: "
|
|
4
|
-
props:
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
},
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
`sun-toggle-${o.color}`,
|
|
15
|
-
{
|
|
16
|
-
"sun-toggle-disabled": o.disabled,
|
|
17
|
-
"sun-toggle-checked": l.value
|
|
18
|
-
}
|
|
19
|
-
]);
|
|
20
|
-
function a() {
|
|
21
|
-
o.disabled || (l.value = !l.value);
|
|
22
|
-
}
|
|
23
|
-
return (B, e) => (f(), k("view", {
|
|
24
|
-
class: v(["sun-toggle", n.value]),
|
|
25
|
-
"hover-class": "hover",
|
|
26
|
-
onTap: e[0] || (e[0] = (V) => a())
|
|
27
|
-
}, e[1] || (e[1] = [
|
|
28
|
-
t("view", { class: "sun-toggle-toggle-icon-wrapper" }, [
|
|
29
|
-
t("view", { class: "sun-toggle-toggle-icon" })
|
|
30
|
-
], -1)
|
|
31
|
-
]), 34));
|
|
1
|
+
import { defineComponent as o, renderSlot as t, mergeProps as r, openBlock as n, createElementBlock as s } from "vue";
|
|
2
|
+
const a = t, l = r, p = n, c = s, u = /* @__PURE__ */ o({
|
|
3
|
+
__name: "table-row",
|
|
4
|
+
props: {
|
|
5
|
+
head: { type: Boolean },
|
|
6
|
+
foot: { type: Boolean }
|
|
7
|
+
},
|
|
8
|
+
setup(m) {
|
|
9
|
+
return (e, d) => (p(), c("view", l(e.$attrs, {
|
|
10
|
+
class: ["sun-tb-row", { "sun-tb-head": e.head, "sun-tb-foot": e.foot }]
|
|
11
|
+
}), [
|
|
12
|
+
a(e.$slots, "default")
|
|
13
|
+
], 16));
|
|
32
14
|
}
|
|
33
15
|
});
|
|
34
16
|
export {
|
|
35
|
-
|
|
17
|
+
u as default
|
|
36
18
|
};
|
package/index25.js
CHANGED
|
@@ -1,125 +1,35 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
import { createSelectorQuery as J } from "@tarojs/taro";
|
|
5
|
-
import Z from "./index17.js";
|
|
6
|
-
const ee = A, te = M, s = E, c = K, z = R, g = j, re = q, le = O, oe = Q, B = U, ie = W, ne = X, ae = Y, se = ["id", "refresher-enabled", "refresher-triggered", "refresher-background", "scroll-x", "scroll-y", "scroll-top", "scroll-left"], ue = {
|
|
7
|
-
key: 1,
|
|
8
|
-
class: "sun-virtual-scroll-placeholder",
|
|
9
|
-
style: { display: "flex", "justify-content": "center", "align-items": "center", height: "85%" }
|
|
10
|
-
};
|
|
11
|
-
let ce = 1;
|
|
12
|
-
const he = /* @__PURE__ */ I({
|
|
13
|
-
__name: "index",
|
|
1
|
+
import { defineComponent as s, computed as o, renderSlot as l, normalizeClass as u, createElementVNode as d, mergeProps as b, openBlock as c, createElementBlock as p } from "vue";
|
|
2
|
+
const m = l, i = u, B = d, _ = b, f = c, z = p, k = /* @__PURE__ */ s({
|
|
3
|
+
__name: "table",
|
|
14
4
|
props: {
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
itemKey: {},
|
|
22
|
-
id: { default: () => `sun-virtual-scroll-${ce++}` },
|
|
23
|
-
bottomSpace: { default: 0 },
|
|
24
|
-
loading: { type: Boolean },
|
|
25
|
-
loadingText: { default: "Loading" }
|
|
5
|
+
rounded: { type: Boolean, default: !0 },
|
|
6
|
+
bordered: { type: Boolean },
|
|
7
|
+
outerBordered: { type: Boolean, default: !0 },
|
|
8
|
+
zebra: { type: Boolean },
|
|
9
|
+
size: { default: "default" },
|
|
10
|
+
layout: {}
|
|
26
11
|
},
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
"
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
[t.value ? "height" : "width"]: b(n.value)
|
|
40
|
-
})), P = a(
|
|
41
|
-
() => r.items.slice(
|
|
42
|
-
Math.max(v.value - u.value, 0),
|
|
43
|
-
v.value + u.value * 2
|
|
44
|
-
)
|
|
45
|
-
);
|
|
46
|
-
function V({ detail: e }) {
|
|
47
|
-
m && cancelAnimationFrame(m), m = requestAnimationFrame(() => {
|
|
48
|
-
i = t.value ? e.scrollTop : e.scrollLeft, v.value = ~~(i / n.value), v.value > u.value - 1 ? p.value = i - n.value * u.value - i % n.value : p.value = i - i % (n.value * u.value), m = 0;
|
|
49
|
-
});
|
|
50
|
-
}
|
|
51
|
-
function w() {
|
|
52
|
-
setTimeout(() => {
|
|
53
|
-
J().select(`#${r.id}`).boundingClientRect((e) => {
|
|
54
|
-
if (S) return;
|
|
55
|
-
if (e = e, !(e != null && e.height) || !(e != null && e.width))
|
|
56
|
-
return w();
|
|
57
|
-
const { height: l, width: o } = e, d = t.value ? l : o;
|
|
58
|
-
u.value = Math.ceil(d / n.value);
|
|
59
|
-
}).exec();
|
|
60
|
-
}, 50);
|
|
61
|
-
}
|
|
62
|
-
return D(() => {
|
|
63
|
-
h.value = i;
|
|
64
|
-
}), L(() => {
|
|
65
|
-
w();
|
|
66
|
-
}), N(() => {
|
|
67
|
-
S = !0;
|
|
68
|
-
}), (e, l) => (s(), c("scroll-view", ae(e.$attrs, {
|
|
69
|
-
id: e.id,
|
|
70
|
-
class: "sun-virtual-scroll",
|
|
71
|
-
"refresher-enabled": e.refresher,
|
|
72
|
-
"refresher-triggered": e.refreshing,
|
|
73
|
-
"refresher-background": e.refresherBg,
|
|
74
|
-
"scroll-x": !t.value,
|
|
75
|
-
"scroll-y": t.value,
|
|
76
|
-
"scroll-top": t.value ? h.value : 0,
|
|
77
|
-
"scroll-left": t.value ? 0 : h.value,
|
|
78
|
-
enhanced: !0,
|
|
79
|
-
"lower-threshold": 300,
|
|
80
|
-
onScrollPassive: l[0] || (l[0] = (o) => V(o)),
|
|
81
|
-
onRefresherrefresh: l[1] || (l[1] = (o) => {
|
|
82
|
-
B(H).short("light"), y("refresh");
|
|
83
|
-
}),
|
|
84
|
-
onScrolltolower: l[2] || (l[2] = (o) => y("lower"))
|
|
12
|
+
setup(r) {
|
|
13
|
+
const e = r, n = o(() => ({
|
|
14
|
+
"sun-tb-rounded": e.rounded,
|
|
15
|
+
"sun-tb-bordered": e.bordered,
|
|
16
|
+
"sun-tb-outer-bordered": e.outerBordered,
|
|
17
|
+
[`sun-tb-size-${e.size}`]: e.size
|
|
18
|
+
})), a = o(() => ({
|
|
19
|
+
"sun-tb-zebra": e.zebra,
|
|
20
|
+
[`sun-tb-layout-${e.layout}`]: e.layout
|
|
21
|
+
}));
|
|
22
|
+
return (t, y) => (f(), z("view", _(t.$attrs, {
|
|
23
|
+
class: ["sun-tb", n.value]
|
|
85
24
|
}), [
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
class: "sun-virtual-scroll-content-container",
|
|
89
|
-
style: g(_.value)
|
|
25
|
+
B("view", {
|
|
26
|
+
class: i(["sun-tb-inner", a.value])
|
|
90
27
|
}, [
|
|
91
|
-
(
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
key: (k = o[e.itemKey]) != null ? k : d,
|
|
95
|
-
class: "sun-virtual-scroll-item",
|
|
96
|
-
style: g(F.value)
|
|
97
|
-
}, [
|
|
98
|
-
z(e.$slots, "default", {
|
|
99
|
-
item: o,
|
|
100
|
-
index: d
|
|
101
|
-
})
|
|
102
|
-
], 4);
|
|
103
|
-
}), 128))
|
|
104
|
-
], 4)) : (s(), c("view", ue, [
|
|
105
|
-
e.loading ? (s(), ne(B(Z), {
|
|
106
|
-
key: 0,
|
|
107
|
-
size: "large"
|
|
108
|
-
}, {
|
|
109
|
-
default: ie(() => [
|
|
110
|
-
oe(le(e.loadingText), 1)
|
|
111
|
-
]),
|
|
112
|
-
_: 1
|
|
113
|
-
})) : z(e.$slots, "empty", { key: 1 })
|
|
114
|
-
])),
|
|
115
|
-
e.items.length ? (s(), c("view", {
|
|
116
|
-
key: 2,
|
|
117
|
-
class: "sun-virtual-scroll-spacer",
|
|
118
|
-
style: g(T.value)
|
|
119
|
-
}, null, 4)) : re("", !0)
|
|
120
|
-
], 16, se));
|
|
28
|
+
m(t.$slots, "default")
|
|
29
|
+
], 2)
|
|
30
|
+
], 16));
|
|
121
31
|
}
|
|
122
32
|
});
|
|
123
33
|
export {
|
|
124
|
-
|
|
34
|
+
k as default
|
|
125
35
|
};
|
package/index26.js
CHANGED
|
@@ -1,16 +1,24 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
const
|
|
1
|
+
import { defineComponent as n, computed as a, renderSlot as l, normalizeClass as r, openBlock as c, createElementBlock as p } from "vue";
|
|
2
|
+
const u = l, d = r, m = c, _ = p, g = /* @__PURE__ */ n({
|
|
3
3
|
__name: "index",
|
|
4
4
|
props: {
|
|
5
|
-
|
|
5
|
+
type: { default: "solid" },
|
|
6
|
+
color: {},
|
|
7
|
+
shape: { default: "round" }
|
|
6
8
|
},
|
|
7
|
-
setup(
|
|
8
|
-
const
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
9
|
+
setup(o) {
|
|
10
|
+
const e = o, t = a(() => [
|
|
11
|
+
`sun-tag-${e.type}`,
|
|
12
|
+
`sun-tag-${e.color}`,
|
|
13
|
+
`sun-tag-${e.shape}`
|
|
14
|
+
]);
|
|
15
|
+
return (s, i) => (m(), _("view", {
|
|
16
|
+
class: d(["sun-tag", t.value])
|
|
17
|
+
}, [
|
|
18
|
+
u(s.$slots, "default")
|
|
19
|
+
], 2));
|
|
12
20
|
}
|
|
13
21
|
});
|
|
14
22
|
export {
|
|
15
|
-
|
|
23
|
+
g as default
|
|
16
24
|
};
|
package/index27.js
CHANGED
|
@@ -1,13 +1,36 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
}
|
|
10
|
-
|
|
1
|
+
import { defineComponent as r, mergeModels as d, useModel as c, computed as u, createElementVNode as i, normalizeClass as m, openBlock as g, createElementBlock as p } from "vue";
|
|
2
|
+
const t = i, v = m, f = g, k = p, w = /* @__PURE__ */ r({
|
|
3
|
+
__name: "index",
|
|
4
|
+
props: /* @__PURE__ */ d({
|
|
5
|
+
disabled: { type: Boolean },
|
|
6
|
+
color: { default: "primary" }
|
|
7
|
+
}, {
|
|
8
|
+
modelValue: { type: Boolean },
|
|
9
|
+
modelModifiers: {}
|
|
10
|
+
}),
|
|
11
|
+
emits: ["update:modelValue"],
|
|
12
|
+
setup(s) {
|
|
13
|
+
const o = s, l = c(s, "modelValue"), n = u(() => [
|
|
14
|
+
`sun-toggle-${o.color}`,
|
|
15
|
+
{
|
|
16
|
+
"sun-toggle-disabled": o.disabled,
|
|
17
|
+
"sun-toggle-checked": l.value
|
|
18
|
+
}
|
|
19
|
+
]);
|
|
20
|
+
function a() {
|
|
21
|
+
o.disabled || (l.value = !l.value);
|
|
22
|
+
}
|
|
23
|
+
return (B, e) => (f(), k("view", {
|
|
24
|
+
class: v(["sun-toggle", n.value]),
|
|
25
|
+
"hover-class": "hover",
|
|
26
|
+
onTap: e[0] || (e[0] = (V) => a())
|
|
27
|
+
}, e[1] || (e[1] = [
|
|
28
|
+
t("view", { class: "sun-toggle-toggle-icon-wrapper" }, [
|
|
29
|
+
t("view", { class: "sun-toggle-toggle-icon" })
|
|
30
|
+
], -1)
|
|
31
|
+
]), 34));
|
|
32
|
+
}
|
|
33
|
+
});
|
|
11
34
|
export {
|
|
12
|
-
|
|
35
|
+
w as default
|
|
13
36
|
};
|