@hlw-uni/mp-vue 1.0.34 → 1.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/dist/composables/theme/font.d.ts +9 -0
- package/dist/composables/theme/index.d.ts +9 -0
- package/dist/composables/theme/palette.d.ts +8 -0
- package/dist/index.d.ts +11 -0
- package/dist/index.js +623 -98
- package/dist/index.mjs +623 -97
- package/dist/style.css +547 -1
- package/package.json +9 -9
- package/src/components/hlw-button/index.vue +116 -0
- package/src/components/hlw-cell/index.vue +113 -0
- package/src/components/hlw-divider/index.vue +52 -0
- package/src/components/hlw-modal/index.vue +127 -0
- package/src/components/hlw-notice-bar/index.vue +99 -0
- package/src/components/hlw-popup/index.vue +108 -0
- package/src/components/hlw-search/index.vue +95 -0
- package/src/components/hlw-skeleton/index.vue +82 -0
- package/src/components/hlw-tabs/index.vue +104 -0
- package/src/components/hlw-tag/index.vue +76 -0
- package/src/composables/theme/font.ts +51 -0
- package/src/composables/theme/index.ts +33 -0
- package/src/composables/theme/palette.ts +36 -0
- package/src/index.ts +11 -0
- package/dist/composables/theme.d.ts +0 -22
- package/src/composables/theme.ts +0 -142
package/dist/index.mjs
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import { defineComponent, resolveComponent, openBlock, createBlock, ref, computed, createElementBlock, normalizeClass, createElementVNode, toDisplayString,
|
|
1
|
+
import { defineComponent, resolveComponent, openBlock, createBlock, ref, computed, createElementBlock, normalizeClass, createElementVNode, toDisplayString, createCommentVNode, renderSlot, useSlots, withCtx, createTextVNode, normalizeStyle, unref, Fragment, renderList, withModifiers, createVNode, onMounted, onUnmounted } from "vue";
|
|
2
|
+
import { useColor } from "@hlw-uni/mp-core";
|
|
2
3
|
import { defineStore } from "pinia";
|
|
3
|
-
const _sfc_main$
|
|
4
|
+
const _sfc_main$h = /* @__PURE__ */ defineComponent({
|
|
4
5
|
...{ name: "HlwAd" },
|
|
5
6
|
__name: "index",
|
|
6
7
|
props: {
|
|
@@ -31,13 +32,13 @@ const _sfc_main$7 = /* @__PURE__ */ defineComponent({
|
|
|
31
32
|
};
|
|
32
33
|
}
|
|
33
34
|
});
|
|
34
|
-
const _hoisted_1$
|
|
35
|
-
const _hoisted_2$
|
|
35
|
+
const _hoisted_1$f = ["src"];
|
|
36
|
+
const _hoisted_2$d = {
|
|
36
37
|
key: 1,
|
|
37
38
|
class: "hlw-avatar__placeholder"
|
|
38
39
|
};
|
|
39
|
-
const _hoisted_3$
|
|
40
|
-
const _sfc_main$
|
|
40
|
+
const _hoisted_3$8 = { class: "hlw-avatar__initial" };
|
|
41
|
+
const _sfc_main$g = /* @__PURE__ */ defineComponent({
|
|
41
42
|
__name: "index",
|
|
42
43
|
props: {
|
|
43
44
|
src: {},
|
|
@@ -62,8 +63,8 @@ const _sfc_main$6 = /* @__PURE__ */ defineComponent({
|
|
|
62
63
|
src: __props.src,
|
|
63
64
|
mode: "aspectFill",
|
|
64
65
|
onError: _cache[0] || (_cache[0] = ($event) => loadError.value = true)
|
|
65
|
-
}, null, 40, _hoisted_1$
|
|
66
|
-
createElementVNode("text", _hoisted_3$
|
|
66
|
+
}, null, 40, _hoisted_1$f)) : (openBlock(), createElementBlock("view", _hoisted_2$d, [
|
|
67
|
+
createElementVNode("text", _hoisted_3$8, toDisplayString(initial.value), 1)
|
|
67
68
|
]))
|
|
68
69
|
], 2);
|
|
69
70
|
};
|
|
@@ -76,40 +77,80 @@ const _export_sfc = (sfc, props) => {
|
|
|
76
77
|
}
|
|
77
78
|
return target;
|
|
78
79
|
};
|
|
79
|
-
const index$
|
|
80
|
-
const _hoisted_1$
|
|
80
|
+
const index$g = /* @__PURE__ */ _export_sfc(_sfc_main$g, [["__scopeId", "data-v-89dcbc96"]]);
|
|
81
|
+
const _hoisted_1$e = ["disabled", "open-type"];
|
|
82
|
+
const _hoisted_2$c = {
|
|
83
|
+
key: 0,
|
|
84
|
+
class: "hlw-btn-spinner"
|
|
85
|
+
};
|
|
86
|
+
const _sfc_main$f = /* @__PURE__ */ defineComponent({
|
|
87
|
+
__name: "index",
|
|
88
|
+
props: {
|
|
89
|
+
type: { default: "primary" },
|
|
90
|
+
size: { default: "medium" },
|
|
91
|
+
loading: { type: Boolean, default: false },
|
|
92
|
+
disabled: { type: Boolean, default: false },
|
|
93
|
+
block: { type: Boolean, default: false },
|
|
94
|
+
round: { type: Boolean, default: false },
|
|
95
|
+
icon: { default: "" },
|
|
96
|
+
openType: { default: "" }
|
|
97
|
+
},
|
|
98
|
+
emits: ["click"],
|
|
99
|
+
setup(__props) {
|
|
100
|
+
return (_ctx, _cache) => {
|
|
101
|
+
return openBlock(), createElementBlock("button", {
|
|
102
|
+
class: normalizeClass(["hlw-btn", [
|
|
103
|
+
`hlw-btn--${__props.type}`,
|
|
104
|
+
`hlw-btn--${__props.size}`,
|
|
105
|
+
{ "hlw-btn--block": __props.block, "hlw-btn--round": __props.round, "hlw-btn--disabled": __props.disabled, "hlw-btn--loading": __props.loading }
|
|
106
|
+
]]),
|
|
107
|
+
disabled: __props.disabled || __props.loading,
|
|
108
|
+
"open-type": __props.openType,
|
|
109
|
+
onTap: _cache[0] || (_cache[0] = ($event) => _ctx.$emit("click"))
|
|
110
|
+
}, [
|
|
111
|
+
__props.loading ? (openBlock(), createElementBlock("view", _hoisted_2$c)) : __props.icon ? (openBlock(), createElementBlock("view", {
|
|
112
|
+
key: 1,
|
|
113
|
+
class: normalizeClass([__props.icon, "hlw-btn-icon"])
|
|
114
|
+
}, null, 2)) : createCommentVNode("", true),
|
|
115
|
+
renderSlot(_ctx.$slots, "default", {}, void 0, true)
|
|
116
|
+
], 42, _hoisted_1$e);
|
|
117
|
+
};
|
|
118
|
+
}
|
|
119
|
+
});
|
|
120
|
+
const index$f = /* @__PURE__ */ _export_sfc(_sfc_main$f, [["__scopeId", "data-v-199073be"]]);
|
|
121
|
+
const _hoisted_1$d = {
|
|
81
122
|
key: 0,
|
|
82
123
|
class: "hlw-card-header"
|
|
83
124
|
};
|
|
84
|
-
const _hoisted_2$
|
|
85
|
-
const _hoisted_3$
|
|
86
|
-
const _hoisted_4$
|
|
125
|
+
const _hoisted_2$b = { class: "hlw-card-header-inner" };
|
|
126
|
+
const _hoisted_3$7 = { class: "hlw-card-header-left" };
|
|
127
|
+
const _hoisted_4$4 = {
|
|
87
128
|
key: 0,
|
|
88
129
|
class: "hlw-card-title"
|
|
89
130
|
};
|
|
90
|
-
const _hoisted_5$
|
|
131
|
+
const _hoisted_5$2 = {
|
|
91
132
|
key: 0,
|
|
92
133
|
class: "hlw-card-header-right"
|
|
93
134
|
};
|
|
94
|
-
const _hoisted_6$
|
|
135
|
+
const _hoisted_6$2 = {
|
|
95
136
|
key: 0,
|
|
96
137
|
class: "hlw-card-extra"
|
|
97
138
|
};
|
|
98
|
-
const _hoisted_7$
|
|
139
|
+
const _hoisted_7$2 = {
|
|
99
140
|
key: 1,
|
|
100
141
|
class: "hlw-card-divider"
|
|
101
142
|
};
|
|
102
|
-
const _hoisted_8$
|
|
143
|
+
const _hoisted_8$2 = {
|
|
103
144
|
key: 2,
|
|
104
145
|
class: "hlw-card-footer"
|
|
105
146
|
};
|
|
106
|
-
const _hoisted_9$
|
|
107
|
-
const _hoisted_10$
|
|
108
|
-
const _hoisted_11$
|
|
147
|
+
const _hoisted_9$2 = { class: "hlw-card-footer-inner" };
|
|
148
|
+
const _hoisted_10$2 = { class: "hlw-card-footer-left" };
|
|
149
|
+
const _hoisted_11$2 = {
|
|
109
150
|
key: 0,
|
|
110
151
|
class: "hlw-card-footer-right"
|
|
111
152
|
};
|
|
112
|
-
const _sfc_main$
|
|
153
|
+
const _sfc_main$e = /* @__PURE__ */ defineComponent({
|
|
113
154
|
__name: "index",
|
|
114
155
|
props: {
|
|
115
156
|
title: { default: "" },
|
|
@@ -140,35 +181,35 @@ const _sfc_main$5 = /* @__PURE__ */ defineComponent({
|
|
|
140
181
|
__props.border ? "hlw-card--bordered" : ""
|
|
141
182
|
]])
|
|
142
183
|
}, [
|
|
143
|
-
hasHeader.value ? (openBlock(), createElementBlock("view", _hoisted_1$
|
|
184
|
+
hasHeader.value ? (openBlock(), createElementBlock("view", _hoisted_1$d, [
|
|
144
185
|
renderSlot(_ctx.$slots, "header", {}, () => [
|
|
145
|
-
createElementVNode("view", _hoisted_2$
|
|
146
|
-
createElementVNode("view", _hoisted_3$
|
|
186
|
+
createElementVNode("view", _hoisted_2$b, [
|
|
187
|
+
createElementVNode("view", _hoisted_3$7, [
|
|
147
188
|
renderSlot(_ctx.$slots, "header-left", {}, () => [
|
|
148
|
-
__props.title ? (openBlock(), createElementBlock("text", _hoisted_4$
|
|
189
|
+
__props.title ? (openBlock(), createElementBlock("text", _hoisted_4$4, toDisplayString(__props.title), 1)) : createCommentVNode("", true)
|
|
149
190
|
], true)
|
|
150
191
|
]),
|
|
151
|
-
_ctx.$slots["header-right"] || __props.extra ? (openBlock(), createElementBlock("view", _hoisted_5$
|
|
192
|
+
_ctx.$slots["header-right"] || __props.extra ? (openBlock(), createElementBlock("view", _hoisted_5$2, [
|
|
152
193
|
renderSlot(_ctx.$slots, "header-right", {}, () => [
|
|
153
|
-
__props.extra ? (openBlock(), createElementBlock("text", _hoisted_6$
|
|
194
|
+
__props.extra ? (openBlock(), createElementBlock("text", _hoisted_6$2, toDisplayString(__props.extra), 1)) : createCommentVNode("", true)
|
|
154
195
|
], true)
|
|
155
196
|
])) : createCommentVNode("", true)
|
|
156
197
|
])
|
|
157
198
|
], true)
|
|
158
199
|
])) : createCommentVNode("", true),
|
|
159
|
-
showDivider.value ? (openBlock(), createElementBlock("view", _hoisted_7$
|
|
200
|
+
showDivider.value ? (openBlock(), createElementBlock("view", _hoisted_7$2)) : createCommentVNode("", true),
|
|
160
201
|
createElementVNode("view", {
|
|
161
202
|
class: normalizeClass(["hlw-card-body", { "hlw-card-body--padded": __props.padding }])
|
|
162
203
|
}, [
|
|
163
204
|
renderSlot(_ctx.$slots, "default", {}, void 0, true)
|
|
164
205
|
], 2),
|
|
165
|
-
hasFooter.value ? (openBlock(), createElementBlock("view", _hoisted_8$
|
|
206
|
+
hasFooter.value ? (openBlock(), createElementBlock("view", _hoisted_8$2, [
|
|
166
207
|
renderSlot(_ctx.$slots, "footer", {}, () => [
|
|
167
|
-
createElementVNode("view", _hoisted_9$
|
|
168
|
-
createElementVNode("view", _hoisted_10$
|
|
208
|
+
createElementVNode("view", _hoisted_9$2, [
|
|
209
|
+
createElementVNode("view", _hoisted_10$2, [
|
|
169
210
|
renderSlot(_ctx.$slots, "footer-left", {}, void 0, true)
|
|
170
211
|
]),
|
|
171
|
-
_ctx.$slots["footer-right"] ? (openBlock(), createElementBlock("view", _hoisted_11$
|
|
212
|
+
_ctx.$slots["footer-right"] ? (openBlock(), createElementBlock("view", _hoisted_11$2, [
|
|
172
213
|
renderSlot(_ctx.$slots, "footer-right", {}, void 0, true)
|
|
173
214
|
])) : createCommentVNode("", true)
|
|
174
215
|
])
|
|
@@ -178,15 +219,148 @@ const _sfc_main$5 = /* @__PURE__ */ defineComponent({
|
|
|
178
219
|
};
|
|
179
220
|
}
|
|
180
221
|
});
|
|
181
|
-
const index$
|
|
182
|
-
const _hoisted_1$
|
|
183
|
-
|
|
184
|
-
|
|
222
|
+
const index$e = /* @__PURE__ */ _export_sfc(_sfc_main$e, [["__scopeId", "data-v-cf55252e"]]);
|
|
223
|
+
const _hoisted_1$c = {
|
|
224
|
+
key: 0,
|
|
225
|
+
class: "hlw-cell-icon"
|
|
226
|
+
};
|
|
227
|
+
const _hoisted_2$a = { class: "hlw-cell-body" };
|
|
228
|
+
const _hoisted_3$6 = { class: "hlw-cell-title" };
|
|
229
|
+
const _hoisted_4$3 = {
|
|
230
|
+
key: 0,
|
|
231
|
+
class: "hlw-cell-label"
|
|
232
|
+
};
|
|
233
|
+
const _hoisted_5$1 = { class: "hlw-cell-value" };
|
|
234
|
+
const _hoisted_6$1 = ["hover-class"];
|
|
235
|
+
const _hoisted_7$1 = {
|
|
236
|
+
key: 0,
|
|
237
|
+
class: "hlw-cell-icon"
|
|
238
|
+
};
|
|
239
|
+
const _hoisted_8$1 = { class: "hlw-cell-body" };
|
|
240
|
+
const _hoisted_9$1 = { class: "hlw-cell-title" };
|
|
241
|
+
const _hoisted_10$1 = {
|
|
242
|
+
key: 0,
|
|
243
|
+
class: "hlw-cell-label"
|
|
244
|
+
};
|
|
245
|
+
const _hoisted_11$1 = { class: "hlw-cell-value" };
|
|
246
|
+
const _hoisted_12$1 = {
|
|
247
|
+
key: 1,
|
|
248
|
+
class: "hlw-cell-arrow"
|
|
249
|
+
};
|
|
250
|
+
const _sfc_main$d = /* @__PURE__ */ defineComponent({
|
|
251
|
+
__name: "index",
|
|
252
|
+
props: {
|
|
253
|
+
title: { default: "" },
|
|
254
|
+
label: { default: "" },
|
|
255
|
+
value: { default: "" },
|
|
256
|
+
icon: { default: "" },
|
|
257
|
+
isLink: { type: Boolean, default: false },
|
|
258
|
+
url: { default: "" },
|
|
259
|
+
border: { type: Boolean, default: true }
|
|
260
|
+
},
|
|
261
|
+
emits: ["click"],
|
|
262
|
+
setup(__props) {
|
|
263
|
+
return (_ctx, _cache) => {
|
|
264
|
+
const _component_navigator = resolveComponent("navigator");
|
|
265
|
+
return __props.url ? (openBlock(), createBlock(_component_navigator, {
|
|
266
|
+
key: 0,
|
|
267
|
+
url: __props.url,
|
|
268
|
+
class: normalizeClass(["hlw-cell", { "hlw-cell--border": __props.border }]),
|
|
269
|
+
"hover-class": "hlw-cell--hover"
|
|
270
|
+
}, {
|
|
271
|
+
default: withCtx(() => [
|
|
272
|
+
__props.icon || _ctx.$slots.icon ? (openBlock(), createElementBlock("view", _hoisted_1$c, [
|
|
273
|
+
renderSlot(_ctx.$slots, "icon", {}, () => [
|
|
274
|
+
createElementVNode("view", {
|
|
275
|
+
class: normalizeClass(__props.icon)
|
|
276
|
+
}, null, 2)
|
|
277
|
+
], true)
|
|
278
|
+
])) : createCommentVNode("", true),
|
|
279
|
+
createElementVNode("view", _hoisted_2$a, [
|
|
280
|
+
createElementVNode("view", _hoisted_3$6, [
|
|
281
|
+
renderSlot(_ctx.$slots, "title", {}, () => [
|
|
282
|
+
createTextVNode(toDisplayString(__props.title), 1)
|
|
283
|
+
], true),
|
|
284
|
+
__props.label ? (openBlock(), createElementBlock("view", _hoisted_4$3, toDisplayString(__props.label), 1)) : createCommentVNode("", true)
|
|
285
|
+
]),
|
|
286
|
+
createElementVNode("view", _hoisted_5$1, [
|
|
287
|
+
renderSlot(_ctx.$slots, "value", {}, () => [
|
|
288
|
+
createTextVNode(toDisplayString(__props.value), 1)
|
|
289
|
+
], true)
|
|
290
|
+
])
|
|
291
|
+
]),
|
|
292
|
+
_cache[1] || (_cache[1] = createElementVNode("view", { class: "hlw-cell-arrow" }, null, -1))
|
|
293
|
+
]),
|
|
294
|
+
_: 3
|
|
295
|
+
}, 8, ["url", "class"])) : (openBlock(), createElementBlock("view", {
|
|
296
|
+
key: 1,
|
|
297
|
+
class: normalizeClass(["hlw-cell", { "hlw-cell--border": __props.border, "hlw-cell--link": __props.isLink }]),
|
|
298
|
+
"hover-class": __props.isLink ? "hlw-cell--hover" : "",
|
|
299
|
+
onTap: _cache[0] || (_cache[0] = ($event) => _ctx.$emit("click"))
|
|
300
|
+
}, [
|
|
301
|
+
__props.icon || _ctx.$slots.icon ? (openBlock(), createElementBlock("view", _hoisted_7$1, [
|
|
302
|
+
renderSlot(_ctx.$slots, "icon", {}, () => [
|
|
303
|
+
createElementVNode("view", {
|
|
304
|
+
class: normalizeClass(__props.icon)
|
|
305
|
+
}, null, 2)
|
|
306
|
+
], true)
|
|
307
|
+
])) : createCommentVNode("", true),
|
|
308
|
+
createElementVNode("view", _hoisted_8$1, [
|
|
309
|
+
createElementVNode("view", _hoisted_9$1, [
|
|
310
|
+
renderSlot(_ctx.$slots, "title", {}, () => [
|
|
311
|
+
createTextVNode(toDisplayString(__props.title), 1)
|
|
312
|
+
], true),
|
|
313
|
+
__props.label ? (openBlock(), createElementBlock("view", _hoisted_10$1, toDisplayString(__props.label), 1)) : createCommentVNode("", true)
|
|
314
|
+
]),
|
|
315
|
+
createElementVNode("view", _hoisted_11$1, [
|
|
316
|
+
renderSlot(_ctx.$slots, "value", {}, () => [
|
|
317
|
+
createTextVNode(toDisplayString(__props.value), 1)
|
|
318
|
+
], true)
|
|
319
|
+
])
|
|
320
|
+
]),
|
|
321
|
+
__props.isLink ? (openBlock(), createElementBlock("view", _hoisted_12$1)) : createCommentVNode("", true),
|
|
322
|
+
renderSlot(_ctx.$slots, "right", {}, void 0, true)
|
|
323
|
+
], 42, _hoisted_6$1));
|
|
324
|
+
};
|
|
325
|
+
}
|
|
326
|
+
});
|
|
327
|
+
const index$d = /* @__PURE__ */ _export_sfc(_sfc_main$d, [["__scopeId", "data-v-2bd8c24d"]]);
|
|
328
|
+
const _hoisted_1$b = {
|
|
329
|
+
key: 0,
|
|
330
|
+
class: "hlw-divider-text"
|
|
331
|
+
};
|
|
332
|
+
const _sfc_main$c = /* @__PURE__ */ defineComponent({
|
|
333
|
+
__name: "index",
|
|
334
|
+
props: {
|
|
335
|
+
text: { default: "" },
|
|
336
|
+
position: { default: "center" },
|
|
337
|
+
dashed: { type: Boolean, default: false }
|
|
338
|
+
},
|
|
339
|
+
setup(__props) {
|
|
340
|
+
return (_ctx, _cache) => {
|
|
341
|
+
return openBlock(), createElementBlock("view", {
|
|
342
|
+
class: normalizeClass(["hlw-divider", [`hlw-divider--${__props.position}`, { "hlw-divider--dashed": __props.dashed }]])
|
|
343
|
+
}, [
|
|
344
|
+
_cache[0] || (_cache[0] = createElementVNode("view", { class: "hlw-divider-line" }, null, -1)),
|
|
345
|
+
__props.text || _ctx.$slots.default ? (openBlock(), createElementBlock("view", _hoisted_1$b, [
|
|
346
|
+
renderSlot(_ctx.$slots, "default", {}, () => [
|
|
347
|
+
createTextVNode(toDisplayString(__props.text), 1)
|
|
348
|
+
], true)
|
|
349
|
+
])) : createCommentVNode("", true),
|
|
350
|
+
_cache[1] || (_cache[1] = createElementVNode("view", { class: "hlw-divider-line" }, null, -1))
|
|
351
|
+
], 2);
|
|
352
|
+
};
|
|
353
|
+
}
|
|
354
|
+
});
|
|
355
|
+
const index$c = /* @__PURE__ */ _export_sfc(_sfc_main$c, [["__scopeId", "data-v-e34c6f87"]]);
|
|
356
|
+
const _hoisted_1$a = { class: "hlw-empty" };
|
|
357
|
+
const _hoisted_2$9 = ["src"];
|
|
358
|
+
const _hoisted_3$5 = {
|
|
185
359
|
key: 1,
|
|
186
360
|
class: "hlw-empty__icon"
|
|
187
361
|
};
|
|
188
|
-
const _hoisted_4$
|
|
189
|
-
const _sfc_main$
|
|
362
|
+
const _hoisted_4$2 = { class: "hlw-empty__text" };
|
|
363
|
+
const _sfc_main$b = /* @__PURE__ */ defineComponent({
|
|
190
364
|
__name: "index",
|
|
191
365
|
props: {
|
|
192
366
|
text: {},
|
|
@@ -194,29 +368,29 @@ const _sfc_main$4 = /* @__PURE__ */ defineComponent({
|
|
|
194
368
|
},
|
|
195
369
|
setup(__props) {
|
|
196
370
|
return (_ctx, _cache) => {
|
|
197
|
-
return openBlock(), createElementBlock("view", _hoisted_1$
|
|
371
|
+
return openBlock(), createElementBlock("view", _hoisted_1$a, [
|
|
198
372
|
__props.image ? (openBlock(), createElementBlock("image", {
|
|
199
373
|
key: 0,
|
|
200
374
|
class: "hlw-empty__image",
|
|
201
375
|
src: __props.image,
|
|
202
376
|
mode: "aspectFit"
|
|
203
|
-
}, null, 8, _hoisted_2$
|
|
204
|
-
createElementVNode("text", _hoisted_4$
|
|
377
|
+
}, null, 8, _hoisted_2$9)) : (openBlock(), createElementBlock("text", _hoisted_3$5, "📦")),
|
|
378
|
+
createElementVNode("text", _hoisted_4$2, toDisplayString(__props.text || "暂无数据"), 1),
|
|
205
379
|
renderSlot(_ctx.$slots, "default", {}, void 0, true)
|
|
206
380
|
]);
|
|
207
381
|
};
|
|
208
382
|
}
|
|
209
383
|
});
|
|
210
|
-
const index$
|
|
211
|
-
const _hoisted_1$
|
|
384
|
+
const index$b = /* @__PURE__ */ _export_sfc(_sfc_main$b, [["__scopeId", "data-v-08b8d8fe"]]);
|
|
385
|
+
const _hoisted_1$9 = {
|
|
212
386
|
key: 0,
|
|
213
387
|
class: "header-placeholder"
|
|
214
388
|
};
|
|
215
|
-
const _hoisted_2$
|
|
389
|
+
const _hoisted_2$8 = {
|
|
216
390
|
key: 0,
|
|
217
391
|
class: "header-title header-title--center"
|
|
218
392
|
};
|
|
219
|
-
const _sfc_main$
|
|
393
|
+
const _sfc_main$a = /* @__PURE__ */ defineComponent({
|
|
220
394
|
__name: "index",
|
|
221
395
|
props: {
|
|
222
396
|
extraHeight: { default: 0 },
|
|
@@ -303,9 +477,9 @@ const _sfc_main$3 = /* @__PURE__ */ defineComponent({
|
|
|
303
477
|
}, toDisplayString(props.title), 5)
|
|
304
478
|
], true)
|
|
305
479
|
], 2),
|
|
306
|
-
props.titleAlign === "center" ? (openBlock(), createElementBlock("view", _hoisted_1$
|
|
480
|
+
props.titleAlign === "center" ? (openBlock(), createElementBlock("view", _hoisted_1$9)) : createCommentVNode("", true)
|
|
307
481
|
], 64)) : renderSlot(_ctx.$slots, "default", { key: 1 }, () => [
|
|
308
|
-
props.title ? (openBlock(), createElementBlock("view", _hoisted_2$
|
|
482
|
+
props.title ? (openBlock(), createElementBlock("view", _hoisted_2$8, [
|
|
309
483
|
createElementVNode("text", {
|
|
310
484
|
class: "header-title-text",
|
|
311
485
|
style: normalizeStyle(titleStyle.value)
|
|
@@ -317,37 +491,37 @@ const _sfc_main$3 = /* @__PURE__ */ defineComponent({
|
|
|
317
491
|
};
|
|
318
492
|
}
|
|
319
493
|
});
|
|
320
|
-
const index$
|
|
321
|
-
const _hoisted_1$
|
|
322
|
-
const _hoisted_2$
|
|
494
|
+
const index$a = /* @__PURE__ */ _export_sfc(_sfc_main$a, [["__scopeId", "data-v-fa8f2a18"]]);
|
|
495
|
+
const _hoisted_1$8 = { class: "hlw-loading" };
|
|
496
|
+
const _hoisted_2$7 = {
|
|
323
497
|
key: 0,
|
|
324
498
|
class: "hlw-loading__text"
|
|
325
499
|
};
|
|
326
|
-
const _sfc_main$
|
|
500
|
+
const _sfc_main$9 = /* @__PURE__ */ defineComponent({
|
|
327
501
|
__name: "index",
|
|
328
502
|
props: {
|
|
329
503
|
text: {}
|
|
330
504
|
},
|
|
331
505
|
setup(__props) {
|
|
332
506
|
return (_ctx, _cache) => {
|
|
333
|
-
return openBlock(), createElementBlock("view", _hoisted_1$
|
|
507
|
+
return openBlock(), createElementBlock("view", _hoisted_1$8, [
|
|
334
508
|
_cache[0] || (_cache[0] = createElementVNode("view", { class: "hlw-loading__spinner" }, null, -1)),
|
|
335
|
-
__props.text ? (openBlock(), createElementBlock("text", _hoisted_2$
|
|
509
|
+
__props.text ? (openBlock(), createElementBlock("text", _hoisted_2$7, toDisplayString(__props.text), 1)) : createCommentVNode("", true)
|
|
336
510
|
]);
|
|
337
511
|
};
|
|
338
512
|
}
|
|
339
513
|
});
|
|
340
|
-
const index$
|
|
341
|
-
const _hoisted_1$
|
|
514
|
+
const index$9 = /* @__PURE__ */ _export_sfc(_sfc_main$9, [["__scopeId", "data-v-14242381"]]);
|
|
515
|
+
const _hoisted_1$7 = {
|
|
342
516
|
key: 0,
|
|
343
517
|
class: "hlw-menu-title"
|
|
344
518
|
};
|
|
345
|
-
const _hoisted_2$
|
|
519
|
+
const _hoisted_2$6 = {
|
|
346
520
|
key: 1,
|
|
347
521
|
class: "hlw-menu-title-divider"
|
|
348
522
|
};
|
|
349
|
-
const _hoisted_3$
|
|
350
|
-
const _hoisted_4 = { class: "hlw-menu-label" };
|
|
523
|
+
const _hoisted_3$4 = { class: "hlw-menu-left" };
|
|
524
|
+
const _hoisted_4$1 = { class: "hlw-menu-label" };
|
|
351
525
|
const _hoisted_5 = { class: "hlw-menu-right" };
|
|
352
526
|
const _hoisted_6 = {
|
|
353
527
|
key: 0,
|
|
@@ -374,7 +548,7 @@ const _hoisted_15 = { class: "hlw-menu-grid-label" };
|
|
|
374
548
|
const _hoisted_16 = ["onClick"];
|
|
375
549
|
const _hoisted_17 = { class: "hlw-menu-grid-icon-wrap" };
|
|
376
550
|
const _hoisted_18 = { class: "hlw-menu-grid-label" };
|
|
377
|
-
const _sfc_main$
|
|
551
|
+
const _sfc_main$8 = /* @__PURE__ */ defineComponent({
|
|
378
552
|
__name: "index",
|
|
379
553
|
props: {
|
|
380
554
|
items: {},
|
|
@@ -396,10 +570,10 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
396
570
|
return openBlock(), createElementBlock("view", {
|
|
397
571
|
class: normalizeClass(["hlw-menu", { "hlw-menu--no-border": !props.border }])
|
|
398
572
|
}, [
|
|
399
|
-
props.title ? (openBlock(), createElementBlock("view", _hoisted_1$
|
|
573
|
+
props.title ? (openBlock(), createElementBlock("view", _hoisted_1$7, [
|
|
400
574
|
createElementVNode("text", null, toDisplayString(props.title), 1)
|
|
401
575
|
])) : createCommentVNode("", true),
|
|
402
|
-
props.title ? (openBlock(), createElementBlock("view", _hoisted_2$
|
|
576
|
+
props.title ? (openBlock(), createElementBlock("view", _hoisted_2$6)) : createCommentVNode("", true),
|
|
403
577
|
props.mode === "list" ? (openBlock(true), createElementBlock(Fragment, { key: 2 }, renderList(visibleItems.value, (item, index2) => {
|
|
404
578
|
return openBlock(), createElementBlock(Fragment, { key: index2 }, [
|
|
405
579
|
item.url ? (openBlock(), createBlock(_component_navigator, {
|
|
@@ -409,7 +583,7 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
409
583
|
"hover-class": "hlw-menu-item--active"
|
|
410
584
|
}, {
|
|
411
585
|
default: withCtx(() => [
|
|
412
|
-
createElementVNode("view", _hoisted_3$
|
|
586
|
+
createElementVNode("view", _hoisted_3$4, [
|
|
413
587
|
createElementVNode("view", {
|
|
414
588
|
class: normalizeClass(["hlw-menu-icon", `hlw-menu-icon--${item.iconTheme || "slate"}`])
|
|
415
589
|
}, [
|
|
@@ -417,7 +591,7 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
417
591
|
class: normalizeClass(item.icon)
|
|
418
592
|
}, null, 2)
|
|
419
593
|
], 2),
|
|
420
|
-
createElementVNode("text", _hoisted_4, toDisplayString(item.label), 1)
|
|
594
|
+
createElementVNode("text", _hoisted_4$1, toDisplayString(item.label), 1)
|
|
421
595
|
]),
|
|
422
596
|
createElementVNode("view", _hoisted_5, [
|
|
423
597
|
item.value ? (openBlock(), createElementBlock("text", _hoisted_6, toDisplayString(item.value), 1)) : createCommentVNode("", true),
|
|
@@ -515,11 +689,137 @@ const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
|
515
689
|
};
|
|
516
690
|
}
|
|
517
691
|
});
|
|
518
|
-
const index$
|
|
519
|
-
const _hoisted_1 = {
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
692
|
+
const index$8 = /* @__PURE__ */ _export_sfc(_sfc_main$8, [["__scopeId", "data-v-2d7cd322"]]);
|
|
693
|
+
const _hoisted_1$6 = {
|
|
694
|
+
key: 0,
|
|
695
|
+
class: "hlw-modal-title"
|
|
696
|
+
};
|
|
697
|
+
const _hoisted_2$5 = { class: "hlw-modal-body" };
|
|
698
|
+
const _hoisted_3$3 = { class: "hlw-modal-footer" };
|
|
699
|
+
const _sfc_main$7 = /* @__PURE__ */ defineComponent({
|
|
700
|
+
__name: "index",
|
|
701
|
+
props: {
|
|
702
|
+
show: { type: Boolean, default: false },
|
|
703
|
+
title: { default: "" },
|
|
704
|
+
showCancel: { type: Boolean, default: true },
|
|
705
|
+
confirmText: { default: "确定" },
|
|
706
|
+
cancelText: { default: "取消" },
|
|
707
|
+
closeOnMask: { type: Boolean, default: true }
|
|
708
|
+
},
|
|
709
|
+
emits: ["update:show", "confirm", "cancel"],
|
|
710
|
+
setup(__props, { emit: __emit }) {
|
|
711
|
+
const emit = __emit;
|
|
712
|
+
function close() {
|
|
713
|
+
emit("update:show", false);
|
|
714
|
+
}
|
|
715
|
+
function onMask() {
|
|
716
|
+
close();
|
|
717
|
+
}
|
|
718
|
+
function onConfirm() {
|
|
719
|
+
emit("confirm");
|
|
720
|
+
close();
|
|
721
|
+
}
|
|
722
|
+
function onCancel() {
|
|
723
|
+
emit("cancel");
|
|
724
|
+
close();
|
|
725
|
+
}
|
|
726
|
+
return (_ctx, _cache) => {
|
|
727
|
+
return __props.show ? (openBlock(), createElementBlock("view", {
|
|
728
|
+
key: 0,
|
|
729
|
+
class: "hlw-modal-mask",
|
|
730
|
+
onTap: withModifiers(onMask, ["self"])
|
|
731
|
+
}, [
|
|
732
|
+
createElementVNode("view", {
|
|
733
|
+
class: normalizeClass(["hlw-modal", { "hlw-modal--show": __props.show }])
|
|
734
|
+
}, [
|
|
735
|
+
__props.title ? (openBlock(), createElementBlock("view", _hoisted_1$6, toDisplayString(__props.title), 1)) : createCommentVNode("", true),
|
|
736
|
+
createElementVNode("view", _hoisted_2$5, [
|
|
737
|
+
renderSlot(_ctx.$slots, "default", {}, void 0, true)
|
|
738
|
+
]),
|
|
739
|
+
renderSlot(_ctx.$slots, "footer", {}, () => [
|
|
740
|
+
createElementVNode("view", _hoisted_3$3, [
|
|
741
|
+
__props.showCancel ? (openBlock(), createElementBlock("view", {
|
|
742
|
+
key: 0,
|
|
743
|
+
class: "hlw-modal-btn hlw-modal-btn--cancel",
|
|
744
|
+
onTap: onCancel
|
|
745
|
+
}, toDisplayString(__props.cancelText), 33)) : createCommentVNode("", true),
|
|
746
|
+
createElementVNode("view", {
|
|
747
|
+
class: "hlw-modal-btn hlw-modal-btn--confirm",
|
|
748
|
+
onTap: onConfirm
|
|
749
|
+
}, toDisplayString(__props.confirmText), 33)
|
|
750
|
+
])
|
|
751
|
+
], true)
|
|
752
|
+
], 2)
|
|
753
|
+
], 32)) : createCommentVNode("", true);
|
|
754
|
+
};
|
|
755
|
+
}
|
|
756
|
+
});
|
|
757
|
+
const index$7 = /* @__PURE__ */ _export_sfc(_sfc_main$7, [["__scopeId", "data-v-fa78c7c6"]]);
|
|
758
|
+
const _hoisted_1$5 = {
|
|
759
|
+
key: 1,
|
|
760
|
+
class: "hlw-notice-left-icon"
|
|
761
|
+
};
|
|
762
|
+
const _hoisted_2$4 = { class: "hlw-notice-text" };
|
|
763
|
+
const _hoisted_3$2 = {
|
|
764
|
+
key: 1,
|
|
765
|
+
class: "hlw-notice-text hlw-notice-text--ellipsis"
|
|
766
|
+
};
|
|
767
|
+
const _sfc_main$6 = /* @__PURE__ */ defineComponent({
|
|
768
|
+
__name: "index",
|
|
769
|
+
props: {
|
|
770
|
+
text: { default: "" },
|
|
771
|
+
scrollable: { type: Boolean, default: true },
|
|
772
|
+
closable: { type: Boolean, default: false },
|
|
773
|
+
color: { default: "#ed6a0c" },
|
|
774
|
+
background: { default: "#fffbe8" },
|
|
775
|
+
speed: { default: 60 },
|
|
776
|
+
leftIcon: { default: "" }
|
|
777
|
+
},
|
|
778
|
+
emits: ["close", "click"],
|
|
779
|
+
setup(__props) {
|
|
780
|
+
const props = __props;
|
|
781
|
+
const closed = ref(false);
|
|
782
|
+
const duration = computed(() => Math.max(3, props.text.length * 20 / props.speed));
|
|
783
|
+
const animStyle = computed(() => ({ animationDuration: `${duration.value}s` }));
|
|
784
|
+
function onClose() {
|
|
785
|
+
closed.value = true;
|
|
786
|
+
}
|
|
787
|
+
return (_ctx, _cache) => {
|
|
788
|
+
return !closed.value ? (openBlock(), createElementBlock("view", {
|
|
789
|
+
key: 0,
|
|
790
|
+
class: "hlw-notice",
|
|
791
|
+
style: normalizeStyle({ color: __props.color, background: __props.background })
|
|
792
|
+
}, [
|
|
793
|
+
__props.leftIcon ? (openBlock(), createElementBlock("view", {
|
|
794
|
+
key: 0,
|
|
795
|
+
class: normalizeClass([__props.leftIcon, "hlw-notice-left-icon"])
|
|
796
|
+
}, null, 2)) : (openBlock(), createElementBlock("view", _hoisted_1$5, "📣")),
|
|
797
|
+
createElementVNode("view", {
|
|
798
|
+
class: "hlw-notice-wrap",
|
|
799
|
+
onTap: _cache[0] || (_cache[0] = ($event) => _ctx.$emit("click"))
|
|
800
|
+
}, [
|
|
801
|
+
__props.scrollable ? (openBlock(), createElementBlock("view", {
|
|
802
|
+
key: 0,
|
|
803
|
+
class: "hlw-notice-scroll",
|
|
804
|
+
style: normalizeStyle(animStyle.value)
|
|
805
|
+
}, [
|
|
806
|
+
createElementVNode("text", _hoisted_2$4, toDisplayString(__props.text), 1)
|
|
807
|
+
], 4)) : (openBlock(), createElementBlock("text", _hoisted_3$2, toDisplayString(__props.text), 1))
|
|
808
|
+
], 32),
|
|
809
|
+
__props.closable ? (openBlock(), createElementBlock("view", {
|
|
810
|
+
key: 2,
|
|
811
|
+
class: "hlw-notice-close",
|
|
812
|
+
onTap: onClose
|
|
813
|
+
}, "×", 32)) : createCommentVNode("", true)
|
|
814
|
+
], 4)) : createCommentVNode("", true);
|
|
815
|
+
};
|
|
816
|
+
}
|
|
817
|
+
});
|
|
818
|
+
const index$6 = /* @__PURE__ */ _export_sfc(_sfc_main$6, [["__scopeId", "data-v-e3f87071"]]);
|
|
819
|
+
const _hoisted_1$4 = { class: "hlw-page" };
|
|
820
|
+
const _hoisted_2$3 = { class: "hlw-page-header" };
|
|
821
|
+
const _hoisted_3$1 = { class: "hlw-page-footer" };
|
|
822
|
+
const _sfc_main$5 = /* @__PURE__ */ defineComponent({
|
|
523
823
|
__name: "index",
|
|
524
824
|
props: {
|
|
525
825
|
title: { default: "" },
|
|
@@ -531,8 +831,8 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
531
831
|
return (_ctx, _cache) => {
|
|
532
832
|
const _component_hlw_header = resolveComponent("hlw-header");
|
|
533
833
|
const _component_scroll_view = resolveComponent("scroll-view");
|
|
534
|
-
return openBlock(), createElementBlock("view", _hoisted_1, [
|
|
535
|
-
createElementVNode("view", _hoisted_2, [
|
|
834
|
+
return openBlock(), createElementBlock("view", _hoisted_1$4, [
|
|
835
|
+
createElementVNode("view", _hoisted_2$3, [
|
|
536
836
|
renderSlot(_ctx.$slots, "header", {}, () => [
|
|
537
837
|
props.title || props.isBack ? (openBlock(), createBlock(_component_hlw_header, {
|
|
538
838
|
key: 0,
|
|
@@ -554,32 +854,244 @@ const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
554
854
|
]),
|
|
555
855
|
_: 3
|
|
556
856
|
}),
|
|
557
|
-
createElementVNode("view", _hoisted_3, [
|
|
857
|
+
createElementVNode("view", _hoisted_3$1, [
|
|
558
858
|
renderSlot(_ctx.$slots, "footer", {}, void 0, true)
|
|
559
859
|
])
|
|
560
860
|
]);
|
|
561
861
|
};
|
|
562
862
|
}
|
|
563
863
|
});
|
|
564
|
-
const index = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-d8833363"]]);
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
|
|
573
|
-
}
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
864
|
+
const index$5 = /* @__PURE__ */ _export_sfc(_sfc_main$5, [["__scopeId", "data-v-d8833363"]]);
|
|
865
|
+
const _hoisted_1$3 = {
|
|
866
|
+
key: 0,
|
|
867
|
+
class: "hlw-popup-header"
|
|
868
|
+
};
|
|
869
|
+
const _hoisted_2$2 = { class: "hlw-popup-title" };
|
|
870
|
+
const _sfc_main$4 = /* @__PURE__ */ defineComponent({
|
|
871
|
+
__name: "index",
|
|
872
|
+
props: {
|
|
873
|
+
show: { type: Boolean, default: false },
|
|
874
|
+
position: { default: "bottom" },
|
|
875
|
+
round: { type: Boolean, default: true },
|
|
876
|
+
closable: { type: Boolean, default: true },
|
|
877
|
+
title: { default: "" }
|
|
878
|
+
},
|
|
879
|
+
emits: ["update:show", "close"],
|
|
880
|
+
setup(__props, { emit: __emit }) {
|
|
881
|
+
const emit = __emit;
|
|
882
|
+
function onClose() {
|
|
883
|
+
emit("update:show", false);
|
|
884
|
+
emit("close");
|
|
885
|
+
}
|
|
886
|
+
return (_ctx, _cache) => {
|
|
887
|
+
return openBlock(), createElementBlock(Fragment, null, [
|
|
888
|
+
__props.show ? (openBlock(), createElementBlock("view", {
|
|
889
|
+
key: 0,
|
|
890
|
+
class: "hlw-popup-mask",
|
|
891
|
+
onTap: withModifiers(onClose, ["self"])
|
|
892
|
+
}, null, 32)) : createCommentVNode("", true),
|
|
893
|
+
createElementVNode("view", {
|
|
894
|
+
class: normalizeClass(["hlw-popup", [`hlw-popup--${__props.position}`, { "hlw-popup--show": __props.show, "hlw-popup--round": __props.round }]])
|
|
895
|
+
}, [
|
|
896
|
+
__props.title || __props.closable ? (openBlock(), createElementBlock("view", _hoisted_1$3, [
|
|
897
|
+
createElementVNode("text", _hoisted_2$2, toDisplayString(__props.title), 1),
|
|
898
|
+
__props.closable ? (openBlock(), createElementBlock("view", {
|
|
899
|
+
key: 0,
|
|
900
|
+
class: "hlw-popup-close",
|
|
901
|
+
onTap: onClose
|
|
902
|
+
}, "×", 32)) : createCommentVNode("", true)
|
|
903
|
+
])) : createCommentVNode("", true),
|
|
904
|
+
renderSlot(_ctx.$slots, "default", {}, void 0, true)
|
|
905
|
+
], 2)
|
|
906
|
+
], 64);
|
|
907
|
+
};
|
|
908
|
+
}
|
|
909
|
+
});
|
|
910
|
+
const index$4 = /* @__PURE__ */ _export_sfc(_sfc_main$4, [["__scopeId", "data-v-a6f8d1a5"]]);
|
|
911
|
+
const _hoisted_1$2 = ["value", "placeholder", "disabled"];
|
|
912
|
+
const _sfc_main$3 = /* @__PURE__ */ defineComponent({
|
|
913
|
+
__name: "index",
|
|
914
|
+
props: {
|
|
915
|
+
modelValue: { default: "" },
|
|
916
|
+
placeholder: { default: "搜索" },
|
|
917
|
+
disabled: { type: Boolean, default: false },
|
|
918
|
+
clearable: { type: Boolean, default: true },
|
|
919
|
+
shape: { default: "round" },
|
|
920
|
+
background: { default: "" }
|
|
921
|
+
},
|
|
922
|
+
emits: ["update:modelValue", "search", "clear", "focus", "blur"],
|
|
923
|
+
setup(__props, { emit: __emit }) {
|
|
924
|
+
const emit = __emit;
|
|
925
|
+
function onInput(e) {
|
|
926
|
+
emit("update:modelValue", e.detail.value);
|
|
927
|
+
}
|
|
928
|
+
function onClear() {
|
|
929
|
+
emit("update:modelValue", "");
|
|
930
|
+
emit("clear");
|
|
931
|
+
}
|
|
932
|
+
return (_ctx, _cache) => {
|
|
933
|
+
return openBlock(), createElementBlock("view", {
|
|
934
|
+
class: "hlw-search",
|
|
935
|
+
style: normalizeStyle(__props.background ? { background: __props.background } : {})
|
|
936
|
+
}, [
|
|
937
|
+
createElementVNode("view", {
|
|
938
|
+
class: normalizeClass(["hlw-search-box", { "hlw-search-box--round": __props.shape === "round" }])
|
|
939
|
+
}, [
|
|
940
|
+
_cache[3] || (_cache[3] = createElementVNode("view", { class: "hlw-search-icon" }, "🔍", -1)),
|
|
941
|
+
createElementVNode("input", {
|
|
942
|
+
class: "hlw-search-input",
|
|
943
|
+
type: "text",
|
|
944
|
+
value: __props.modelValue,
|
|
945
|
+
placeholder: __props.placeholder,
|
|
946
|
+
disabled: __props.disabled,
|
|
947
|
+
"confirm-type": "search",
|
|
948
|
+
onInput,
|
|
949
|
+
onConfirm: _cache[0] || (_cache[0] = ($event) => _ctx.$emit("search", __props.modelValue)),
|
|
950
|
+
onFocus: _cache[1] || (_cache[1] = ($event) => _ctx.$emit("focus")),
|
|
951
|
+
onBlur: _cache[2] || (_cache[2] = ($event) => _ctx.$emit("blur"))
|
|
952
|
+
}, null, 40, _hoisted_1$2),
|
|
953
|
+
__props.clearable && __props.modelValue ? (openBlock(), createElementBlock("view", {
|
|
954
|
+
key: 0,
|
|
955
|
+
class: "hlw-search-clear",
|
|
956
|
+
onTap: onClear
|
|
957
|
+
}, "×", 32)) : createCommentVNode("", true)
|
|
958
|
+
], 2)
|
|
959
|
+
], 4);
|
|
960
|
+
};
|
|
961
|
+
}
|
|
962
|
+
});
|
|
963
|
+
const index$3 = /* @__PURE__ */ _export_sfc(_sfc_main$3, [["__scopeId", "data-v-761affc9"]]);
|
|
964
|
+
const _hoisted_1$1 = { class: "hlw-skeleton-content" };
|
|
965
|
+
const _hoisted_2$1 = {
|
|
966
|
+
key: 0,
|
|
967
|
+
class: "hlw-skeleton-title"
|
|
968
|
+
};
|
|
969
|
+
const _sfc_main$2 = /* @__PURE__ */ defineComponent({
|
|
970
|
+
__name: "index",
|
|
971
|
+
props: {
|
|
972
|
+
loading: { type: Boolean, default: true },
|
|
973
|
+
rows: { default: 3 },
|
|
974
|
+
avatar: { type: Boolean, default: false },
|
|
975
|
+
title: { type: Boolean, default: true },
|
|
976
|
+
animate: { type: Boolean, default: true },
|
|
977
|
+
avatarSize: { default: "medium" }
|
|
978
|
+
},
|
|
979
|
+
setup(__props) {
|
|
980
|
+
return (_ctx, _cache) => {
|
|
981
|
+
return __props.loading ? (openBlock(), createElementBlock("view", {
|
|
982
|
+
key: 0,
|
|
983
|
+
class: normalizeClass(["hlw-skeleton", { "hlw-skeleton--animate": __props.animate }])
|
|
984
|
+
}, [
|
|
985
|
+
__props.avatar ? (openBlock(), createElementBlock("view", {
|
|
986
|
+
key: 0,
|
|
987
|
+
class: normalizeClass(["hlw-skeleton-avatar", `hlw-skeleton-avatar--${__props.avatarSize}`])
|
|
988
|
+
}, null, 2)) : createCommentVNode("", true),
|
|
989
|
+
createElementVNode("view", _hoisted_1$1, [
|
|
990
|
+
__props.title ? (openBlock(), createElementBlock("view", _hoisted_2$1)) : createCommentVNode("", true),
|
|
991
|
+
(openBlock(true), createElementBlock(Fragment, null, renderList(__props.rows, (i) => {
|
|
992
|
+
return openBlock(), createElementBlock("view", {
|
|
993
|
+
key: i,
|
|
994
|
+
class: "hlw-skeleton-row",
|
|
995
|
+
style: normalizeStyle({ width: i === __props.rows ? "60%" : "100%" })
|
|
996
|
+
}, null, 4);
|
|
997
|
+
}), 128))
|
|
998
|
+
])
|
|
999
|
+
], 2)) : renderSlot(_ctx.$slots, "default", { key: 1 }, void 0, true);
|
|
1000
|
+
};
|
|
1001
|
+
}
|
|
1002
|
+
});
|
|
1003
|
+
const index$2 = /* @__PURE__ */ _export_sfc(_sfc_main$2, [["__scopeId", "data-v-c2d1fca4"]]);
|
|
1004
|
+
const _hoisted_1 = { class: "hlw-tabs-wrap" };
|
|
1005
|
+
const _hoisted_2 = ["onTap"];
|
|
1006
|
+
const _hoisted_3 = { class: "hlw-tab-text" };
|
|
1007
|
+
const _hoisted_4 = {
|
|
1008
|
+
key: 0,
|
|
1009
|
+
class: "hlw-tab-badge"
|
|
1010
|
+
};
|
|
1011
|
+
const _sfc_main$1 = /* @__PURE__ */ defineComponent({
|
|
1012
|
+
__name: "index",
|
|
1013
|
+
props: {
|
|
1014
|
+
modelValue: { default: 0 },
|
|
1015
|
+
items: { default: () => [] },
|
|
1016
|
+
scrollable: { type: Boolean, default: false },
|
|
1017
|
+
lineWidth: { default: "40rpx" }
|
|
1018
|
+
},
|
|
1019
|
+
emits: ["update:modelValue", "change"],
|
|
1020
|
+
setup(__props, { emit: __emit }) {
|
|
1021
|
+
const emit = __emit;
|
|
1022
|
+
function onChange(index2) {
|
|
1023
|
+
emit("update:modelValue", index2);
|
|
1024
|
+
emit("change", index2);
|
|
1025
|
+
}
|
|
1026
|
+
return (_ctx, _cache) => {
|
|
1027
|
+
const _component_scroll_view = resolveComponent("scroll-view");
|
|
1028
|
+
return openBlock(), createBlock(_component_scroll_view, {
|
|
1029
|
+
class: "hlw-tabs",
|
|
1030
|
+
"scroll-x": __props.scrollable,
|
|
1031
|
+
enhanced: true,
|
|
1032
|
+
"show-scrollbar": false
|
|
1033
|
+
}, {
|
|
1034
|
+
default: withCtx(() => [
|
|
1035
|
+
createElementVNode("view", _hoisted_1, [
|
|
1036
|
+
(openBlock(true), createElementBlock(Fragment, null, renderList(__props.items, (item, index2) => {
|
|
1037
|
+
return openBlock(), createElementBlock("view", {
|
|
1038
|
+
key: index2,
|
|
1039
|
+
class: normalizeClass(["hlw-tab", { "hlw-tab--active": __props.modelValue === index2 }]),
|
|
1040
|
+
onTap: ($event) => onChange(index2)
|
|
1041
|
+
}, [
|
|
1042
|
+
createElementVNode("text", _hoisted_3, toDisplayString(typeof item === "string" ? item : item.label), 1),
|
|
1043
|
+
typeof item !== "string" && item.badge ? (openBlock(), createElementBlock("view", _hoisted_4, toDisplayString(item.badge), 1)) : createCommentVNode("", true),
|
|
1044
|
+
__props.modelValue === index2 ? (openBlock(), createElementBlock("view", {
|
|
1045
|
+
key: 1,
|
|
1046
|
+
class: "hlw-tab-line",
|
|
1047
|
+
style: normalizeStyle({ width: __props.lineWidth })
|
|
1048
|
+
}, null, 4)) : createCommentVNode("", true)
|
|
1049
|
+
], 42, _hoisted_2);
|
|
1050
|
+
}), 128))
|
|
1051
|
+
])
|
|
1052
|
+
]),
|
|
1053
|
+
_: 1
|
|
1054
|
+
}, 8, ["scroll-x"]);
|
|
1055
|
+
};
|
|
1056
|
+
}
|
|
1057
|
+
});
|
|
1058
|
+
const index$1 = /* @__PURE__ */ _export_sfc(_sfc_main$1, [["__scopeId", "data-v-f6f0b949"]]);
|
|
1059
|
+
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
1060
|
+
__name: "index",
|
|
1061
|
+
props: {
|
|
1062
|
+
type: { default: "primary" },
|
|
1063
|
+
plain: { type: Boolean, default: false },
|
|
1064
|
+
closable: { type: Boolean, default: false },
|
|
1065
|
+
size: { default: "medium" },
|
|
1066
|
+
round: { type: Boolean, default: false },
|
|
1067
|
+
color: { default: "" }
|
|
1068
|
+
},
|
|
1069
|
+
emits: ["click", "close"],
|
|
1070
|
+
setup(__props) {
|
|
1071
|
+
const props = __props;
|
|
1072
|
+
const customStyle = computed(() => {
|
|
1073
|
+
if (!props.color)
|
|
1074
|
+
return {};
|
|
1075
|
+
return props.plain ? { color: props.color, borderColor: props.color, background: "transparent" } : { background: props.color, color: "#fff", borderColor: props.color };
|
|
1076
|
+
});
|
|
1077
|
+
return (_ctx, _cache) => {
|
|
1078
|
+
return openBlock(), createElementBlock("view", {
|
|
1079
|
+
class: normalizeClass(["hlw-tag", [`hlw-tag--${__props.type}`, `hlw-tag--${__props.size}`, { "hlw-tag--plain": __props.plain, "hlw-tag--round": __props.round }]]),
|
|
1080
|
+
style: normalizeStyle(customStyle.value),
|
|
1081
|
+
onTap: _cache[1] || (_cache[1] = ($event) => _ctx.$emit("click"))
|
|
1082
|
+
}, [
|
|
1083
|
+
renderSlot(_ctx.$slots, "default", {}, void 0, true),
|
|
1084
|
+
__props.closable ? (openBlock(), createElementBlock("view", {
|
|
1085
|
+
key: 0,
|
|
1086
|
+
class: "hlw-tag-close",
|
|
1087
|
+
onTap: _cache[0] || (_cache[0] = withModifiers(($event) => _ctx.$emit("close"), ["stop"]))
|
|
1088
|
+
}, "×", 32)) : createCommentVNode("", true)
|
|
1089
|
+
], 38);
|
|
1090
|
+
};
|
|
1091
|
+
}
|
|
1092
|
+
});
|
|
1093
|
+
const index = /* @__PURE__ */ _export_sfc(_sfc_main, [["__scopeId", "data-v-42e75bd0"]]);
|
|
580
1094
|
const FONT_SCALE_KEY = "hlw_font_scale";
|
|
581
|
-
const THEME_COLOR_KEY = "hlw_theme_color";
|
|
582
|
-
const THEME_CHANGE_EVENT = "hlw:theme-change";
|
|
583
1095
|
const FONT_PRESETS = {
|
|
584
1096
|
small: {
|
|
585
1097
|
label: "小字体",
|
|
@@ -638,6 +1150,8 @@ function getCurrentFontScale() {
|
|
|
638
1150
|
function getCurrentFontVars() {
|
|
639
1151
|
return FONT_PRESETS[getCurrentFontScale()].vars;
|
|
640
1152
|
}
|
|
1153
|
+
const { hexToRgba, darkenHex } = useColor();
|
|
1154
|
+
const THEME_COLOR_KEY = "hlw_theme_color";
|
|
641
1155
|
const DEFAULT_THEMES = [
|
|
642
1156
|
{ label: "默认蓝", value: "#3b82f6" },
|
|
643
1157
|
{ label: "活力橙", value: "#f97316" },
|
|
@@ -663,6 +1177,8 @@ function getCurrentThemeVars() {
|
|
|
663
1177
|
"--primary-dark": darkenHex(color)
|
|
664
1178
|
};
|
|
665
1179
|
}
|
|
1180
|
+
const { varsToStyle } = useColor();
|
|
1181
|
+
const THEME_CHANGE_EVENT = "hlw:theme-change";
|
|
666
1182
|
function buildThemeStyle() {
|
|
667
1183
|
return varsToStyle({
|
|
668
1184
|
...getCurrentFontVars(),
|
|
@@ -719,14 +1235,24 @@ export {
|
|
|
719
1235
|
DEFAULT_THEMES,
|
|
720
1236
|
FONT_PRESETS,
|
|
721
1237
|
FONT_SCALE_KEY,
|
|
722
|
-
_sfc_main$
|
|
723
|
-
index$
|
|
724
|
-
index$
|
|
725
|
-
index$
|
|
726
|
-
index$
|
|
727
|
-
index$
|
|
728
|
-
index$
|
|
729
|
-
index as
|
|
1238
|
+
_sfc_main$h as HlwAd,
|
|
1239
|
+
index$g as HlwAvatar,
|
|
1240
|
+
index$f as HlwButton,
|
|
1241
|
+
index$e as HlwCard,
|
|
1242
|
+
index$d as HlwCell,
|
|
1243
|
+
index$c as HlwDivider,
|
|
1244
|
+
index$b as HlwEmpty,
|
|
1245
|
+
index$a as HlwHeader,
|
|
1246
|
+
index$9 as HlwLoading,
|
|
1247
|
+
index$8 as HlwMenu,
|
|
1248
|
+
index$7 as HlwModal,
|
|
1249
|
+
index$6 as HlwNoticeBar,
|
|
1250
|
+
index$5 as HlwPage,
|
|
1251
|
+
index$4 as HlwPopup,
|
|
1252
|
+
index$3 as HlwSearch,
|
|
1253
|
+
index$2 as HlwSkeleton,
|
|
1254
|
+
index$1 as HlwTabs,
|
|
1255
|
+
index as HlwTag,
|
|
730
1256
|
THEME_CHANGE_EVENT,
|
|
731
1257
|
THEME_COLOR_KEY,
|
|
732
1258
|
buildThemeStyle,
|