@nutui/nutui 3.1.10-beta.3 → 3.1.12-beta.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 +43 -0
- package/dist/nutui.d.ts +2 -1
- package/dist/nutui.es.js +1642 -926
- package/dist/nutui.umd.js +1648 -931
- package/dist/packages/_es/ActionSheet.js +1 -1
- package/dist/packages/_es/Address.js +1 -1
- package/dist/packages/_es/Avatar.js +1 -1
- package/dist/packages/_es/BackTop.js +1 -1
- package/dist/packages/_es/Badge.js +1 -1
- package/dist/packages/_es/Barrage.js +1 -1
- package/dist/packages/_es/Button.js +1 -1
- package/dist/packages/_es/Calendar.js +1 -1
- package/dist/packages/_es/Cell.js +1 -1
- package/dist/packages/_es/CellGroup.js +1 -1
- package/dist/packages/_es/Checkbox.js +1 -1
- package/dist/packages/_es/CheckboxGroup.js +2 -2
- package/dist/packages/_es/CircleProgress.js +1 -1
- package/dist/packages/_es/Col.js +1 -1
- package/dist/packages/_es/Collapse.js +1 -1
- package/dist/packages/_es/CollapseItem.js +1 -1
- package/dist/packages/_es/CountDown.js +1 -1
- package/dist/packages/_es/CountUp.js +1 -1
- package/dist/packages/_es/DatePicker.js +1 -1
- package/dist/packages/_es/Dialog.js +3 -12
- package/dist/packages/_es/Divider.js +1 -1
- package/dist/packages/_es/Drag.js +1 -1
- package/dist/packages/_es/Elevator.js +1 -1
- package/dist/packages/_es/FixedNav.js +1 -1
- package/dist/packages/_es/Icon.js +1 -1
- package/dist/packages/_es/ImagePreview.js +3 -2
- package/dist/packages/_es/InfiniteLoading.js +1 -1
- package/dist/packages/_es/Input.js +1 -1
- package/dist/packages/_es/InputNumber.js +1 -1
- package/dist/packages/_es/Layout.js +1 -1
- package/dist/packages/_es/Menu.js +83 -167
- package/dist/packages/_es/MenuItem.js +154 -15
- package/dist/packages/_es/Navbar.js +1 -1
- package/dist/packages/_es/NoticeBar.js +1 -1
- package/dist/packages/_es/Notify.js +1 -1
- package/dist/packages/_es/NumberKeyboard.js +1 -1
- package/dist/packages/_es/OverLay.js +1 -1
- package/dist/packages/_es/Pagination.js +1 -1
- package/dist/packages/_es/Picker.js +1 -1
- package/dist/packages/_es/Popover.js +1 -1
- package/dist/packages/_es/Popup.js +52 -13
- package/dist/packages/_es/Price.js +1 -1
- package/dist/packages/_es/Progress.js +1 -1
- package/dist/packages/_es/Radio.js +18 -5
- package/dist/packages/_es/RadioGroup.js +6 -2
- package/dist/packages/_es/Range.js +3 -31
- package/dist/packages/_es/Rate.js +1 -1
- package/dist/packages/_es/Row.js +1 -1
- package/dist/packages/_es/SearchBar.js +52 -49
- package/dist/packages/_es/ShortPassword.js +1 -1
- package/dist/packages/_es/Signature.js +1 -1
- package/dist/packages/_es/Sku.js +533 -0
- package/dist/packages/_es/Step.js +1 -1
- package/dist/packages/_es/Steps.js +1 -1
- package/dist/packages/_es/Swipe.js +1 -1
- package/dist/packages/_es/Swiper.js +2 -2
- package/dist/packages/_es/SwiperItem.js +1 -1
- package/dist/packages/_es/Switch.js +1 -1
- package/dist/packages/_es/TabPane.js +1 -1
- package/dist/packages/_es/Tabbar.js +1 -1
- package/dist/packages/_es/TabbarItem.js +1 -1
- package/dist/packages/_es/Tabs.js +2 -2
- package/dist/packages/_es/Tag.js +1 -1
- package/dist/packages/_es/TextArea.js +1 -1
- package/dist/packages/_es/TimeDetail.js +1 -1
- package/dist/packages/_es/TimePannel.js +1 -1
- package/dist/packages/_es/TimeSelect.js +1 -1
- package/dist/packages/_es/Toast.js +3 -3
- package/dist/packages/_es/Uploader.js +159 -73
- package/dist/packages/_es/Video.js +1 -1
- package/dist/packages/_es/component.js +1 -1
- package/dist/packages/_es/index.js +1 -1
- package/dist/packages/_es/index2.js +31 -8
- package/dist/packages/_es/index3.js +13 -0
- package/dist/packages/_es/plugin-vue_export-helper.js +4 -3
- package/dist/packages/_es/pxCheck.js +1 -1
- package/dist/packages/_es/raf.js +1 -1
- package/dist/packages/button/index.scss +3 -0
- package/dist/packages/menu/index.scss +32 -60
- package/dist/packages/menuitem/index.scss +36 -99
- package/dist/packages/progress/index.scss +2 -0
- package/dist/packages/radio/index.scss +32 -4
- package/dist/packages/radiogroup/index.scss +20 -0
- package/dist/packages/searchbar/index.scss +25 -29
- package/dist/packages/sku/index.scss +147 -0
- package/dist/packages/uploader/index.scss +95 -8
- package/dist/style.css +1 -1
- package/dist/styles/mixins/index.scss +0 -4
- package/dist/styles/themes/default.scss +31 -30
- package/dist/styles/variables.scss +40 -3
- package/package.json +2 -1
- package/dist/packages/_es/style.css +0 -160
|
@@ -18,7 +18,7 @@ var __spreadValues = (a, b) => {
|
|
|
18
18
|
};
|
|
19
19
|
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
20
20
|
/*!
|
|
21
|
-
* @nutui/nutui v3.1.
|
|
21
|
+
* @nutui/nutui v3.1.12-beta.0 Mon Nov 22 2021 20:58:07 GMT+0800 (中国标准时间)
|
|
22
22
|
* (c) 2021 @jdf2e.
|
|
23
23
|
* Released under the MIT License.
|
|
24
24
|
*/
|
|
@@ -15,7 +15,7 @@ var __spreadValues = (a, b) => {
|
|
|
15
15
|
return a;
|
|
16
16
|
};
|
|
17
17
|
/*!
|
|
18
|
-
* @nutui/nutui v3.1.
|
|
18
|
+
* @nutui/nutui v3.1.12-beta.0 Mon Nov 22 2021 20:58:07 GMT+0800 (中国标准时间)
|
|
19
19
|
* (c) 2021 @jdf2e.
|
|
20
20
|
* Released under the MIT License.
|
|
21
21
|
*/
|
|
@@ -15,7 +15,7 @@ var __spreadValues = (a, b) => {
|
|
|
15
15
|
return a;
|
|
16
16
|
};
|
|
17
17
|
/*!
|
|
18
|
-
* @nutui/nutui v3.1.
|
|
18
|
+
* @nutui/nutui v3.1.12-beta.0 Mon Nov 22 2021 20:58:07 GMT+0800 (中国标准时间)
|
|
19
19
|
* (c) 2021 @jdf2e.
|
|
20
20
|
* Released under the MIT License.
|
|
21
21
|
*/
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* @nutui/nutui v3.1.
|
|
2
|
+
* @nutui/nutui v3.1.12-beta.0 Mon Nov 22 2021 20:58:07 GMT+0800 (中国标准时间)
|
|
3
3
|
* (c) 2021 @jdf2e.
|
|
4
4
|
* Released under the MIT License.
|
|
5
5
|
*/
|
|
6
6
|
import { reactive, provide, computed, watch, h } from "vue";
|
|
7
7
|
import { c as createComponent } from "./component.js";
|
|
8
|
-
import { u as useExpose } from "./
|
|
8
|
+
import { u as useExpose } from "./index3.js";
|
|
9
9
|
const { create, componentName } = createComponent("checkboxgroup");
|
|
10
10
|
const _sfc_main = create({
|
|
11
11
|
props: {
|
package/dist/packages/_es/Col.js
CHANGED
|
@@ -18,7 +18,7 @@ var __spreadValues = (a, b) => {
|
|
|
18
18
|
};
|
|
19
19
|
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
20
20
|
/*!
|
|
21
|
-
* @nutui/nutui v3.1.
|
|
21
|
+
* @nutui/nutui v3.1.12-beta.0 Mon Nov 22 2021 20:58:07 GMT+0800 (中国标准时间)
|
|
22
22
|
* (c) 2021 @jdf2e.
|
|
23
23
|
* Released under the MIT License.
|
|
24
24
|
*/
|
|
@@ -18,7 +18,7 @@ var __spreadValues = (a, b) => {
|
|
|
18
18
|
};
|
|
19
19
|
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
20
20
|
/*!
|
|
21
|
-
* @nutui/nutui v3.1.
|
|
21
|
+
* @nutui/nutui v3.1.12-beta.0 Mon Nov 22 2021 20:58:07 GMT+0800 (中国标准时间)
|
|
22
22
|
* (c) 2021 @jdf2e.
|
|
23
23
|
* Released under the MIT License.
|
|
24
24
|
*/
|
|
@@ -18,7 +18,7 @@ var __spreadValues = (a, b) => {
|
|
|
18
18
|
};
|
|
19
19
|
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
20
20
|
/*!
|
|
21
|
-
* @nutui/nutui v3.1.
|
|
21
|
+
* @nutui/nutui v3.1.12-beta.0 Mon Nov 22 2021 20:58:07 GMT+0800 (中国标准时间)
|
|
22
22
|
* (c) 2021 @jdf2e.
|
|
23
23
|
* Released under the MIT License.
|
|
24
24
|
*/
|
|
@@ -18,7 +18,7 @@ var __spreadValues = (a, b) => {
|
|
|
18
18
|
};
|
|
19
19
|
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
20
20
|
/*!
|
|
21
|
-
* @nutui/nutui v3.1.
|
|
21
|
+
* @nutui/nutui v3.1.12-beta.0 Mon Nov 22 2021 20:58:07 GMT+0800 (中国标准时间)
|
|
22
22
|
* (c) 2021 @jdf2e.
|
|
23
23
|
* Released under the MIT License.
|
|
24
24
|
*/
|
|
@@ -22,7 +22,7 @@ var __publicField = (obj, key, value) => {
|
|
|
22
22
|
return value;
|
|
23
23
|
};
|
|
24
24
|
/*!
|
|
25
|
-
* @nutui/nutui v3.1.
|
|
25
|
+
* @nutui/nutui v3.1.12-beta.0 Mon Nov 22 2021 20:58:07 GMT+0800 (中国标准时间)
|
|
26
26
|
* (c) 2021 @jdf2e.
|
|
27
27
|
* Released under the MIT License.
|
|
28
28
|
*/
|
|
@@ -107,16 +107,7 @@ const _sfc_main = create({
|
|
|
107
107
|
default: false
|
|
108
108
|
}
|
|
109
109
|
}),
|
|
110
|
-
emits: [
|
|
111
|
-
"update",
|
|
112
|
-
"update:visible",
|
|
113
|
-
"ok",
|
|
114
|
-
"cancel",
|
|
115
|
-
"open",
|
|
116
|
-
"opened",
|
|
117
|
-
"close",
|
|
118
|
-
"closed"
|
|
119
|
-
],
|
|
110
|
+
emits: ["update", "update:visible", "ok", "cancel", "open", "opened", "close", "closed"],
|
|
120
111
|
setup(props, { emit }) {
|
|
121
112
|
const showPopup = ref(props.visible);
|
|
122
113
|
onMounted(() => {
|
|
@@ -149,8 +140,8 @@ const _sfc_main = create({
|
|
|
149
140
|
}
|
|
150
141
|
};
|
|
151
142
|
const onOk = () => {
|
|
152
|
-
closed();
|
|
153
143
|
emit("ok");
|
|
144
|
+
closed();
|
|
154
145
|
};
|
|
155
146
|
return {
|
|
156
147
|
closed,
|
|
@@ -18,7 +18,7 @@ var __spreadValues = (a, b) => {
|
|
|
18
18
|
};
|
|
19
19
|
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
20
20
|
/*!
|
|
21
|
-
* @nutui/nutui v3.1.
|
|
21
|
+
* @nutui/nutui v3.1.12-beta.0 Mon Nov 22 2021 20:58:07 GMT+0800 (中国标准时间)
|
|
22
22
|
* (c) 2021 @jdf2e.
|
|
23
23
|
* Released under the MIT License.
|
|
24
24
|
*/
|
|
@@ -18,7 +18,7 @@ var __spreadValues = (a, b) => {
|
|
|
18
18
|
};
|
|
19
19
|
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
20
20
|
/*!
|
|
21
|
-
* @nutui/nutui v3.1.
|
|
21
|
+
* @nutui/nutui v3.1.12-beta.0 Mon Nov 22 2021 20:58:07 GMT+0800 (中国标准时间)
|
|
22
22
|
* (c) 2021 @jdf2e.
|
|
23
23
|
* Released under the MIT License.
|
|
24
24
|
*/
|
|
@@ -88,7 +88,8 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
88
88
|
class: "nut-imagepreview-swiper",
|
|
89
89
|
loop: true,
|
|
90
90
|
direction: "horizontal",
|
|
91
|
-
onChange: _ctx.slideChangeEnd
|
|
91
|
+
onChange: _ctx.slideChangeEnd,
|
|
92
|
+
"is-preventDefault": false
|
|
92
93
|
}, {
|
|
93
94
|
default: withCtx(() => [
|
|
94
95
|
(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.images, (item, index2) => {
|
|
@@ -18,7 +18,7 @@ var __spreadValues = (a, b) => {
|
|
|
18
18
|
};
|
|
19
19
|
var __spreadProps = (a, b) => __defProps(a, __getOwnPropDescs(b));
|
|
20
20
|
/*!
|
|
21
|
-
* @nutui/nutui v3.1.
|
|
21
|
+
* @nutui/nutui v3.1.12-beta.0 Mon Nov 22 2021 20:58:07 GMT+0800 (中国标准时间)
|
|
22
22
|
* (c) 2021 @jdf2e.
|
|
23
23
|
* Released under the MIT License.
|
|
24
24
|
*/
|
|
@@ -1,203 +1,119 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* @nutui/nutui v3.1.
|
|
2
|
+
* @nutui/nutui v3.1.12-beta.0 Mon Nov 22 2021 20:58:07 GMT+0800 (中国标准时间)
|
|
3
3
|
* (c) 2021 @jdf2e.
|
|
4
4
|
* Released under the MIT License.
|
|
5
5
|
*/
|
|
6
|
-
import {
|
|
6
|
+
import { ref, computed, reactive, provide, resolveComponent, openBlock, createElementBlock, normalizeClass, createElementVNode, Fragment, renderList, normalizeStyle, toDisplayString, createVNode, renderSlot } from "vue";
|
|
7
7
|
import { c as createComponent } from "./component.js";
|
|
8
|
-
import
|
|
8
|
+
import { u as useRect } from "./index2.js";
|
|
9
9
|
import { _ as _export_sfc } from "./plugin-vue_export-helper.js";
|
|
10
|
-
import "./pxCheck.js";
|
|
11
|
-
var index_vue_vue_type_style_index_0_lang = "";
|
|
12
10
|
const { componentName, create } = createComponent("menu");
|
|
13
11
|
const _sfc_main = create({
|
|
14
|
-
components: {
|
|
15
|
-
[_sfc_main$1.name]: _sfc_main$1
|
|
16
|
-
},
|
|
17
12
|
props: {
|
|
18
|
-
col: {
|
|
19
|
-
type: [String, Number],
|
|
20
|
-
default: 1
|
|
21
|
-
},
|
|
22
13
|
activeColor: {
|
|
23
14
|
type: String,
|
|
24
|
-
default: "#
|
|
15
|
+
default: "#FA2C19"
|
|
16
|
+
},
|
|
17
|
+
overlay: {
|
|
18
|
+
type: Boolean,
|
|
19
|
+
default: true
|
|
20
|
+
},
|
|
21
|
+
duration: {
|
|
22
|
+
type: [Number, String],
|
|
23
|
+
default: 0
|
|
25
24
|
}
|
|
26
25
|
},
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
const
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
if (slots.default) {
|
|
39
|
-
for (let i = 0; i < slots.default().length; i++) {
|
|
40
|
-
if (slots.default()[i].type["name"] === "nut-menu-item") {
|
|
41
|
-
let item = {
|
|
42
|
-
title: slots.default()[i].props["title"],
|
|
43
|
-
disabled: !!slots.default()[i].props["disabled"]
|
|
44
|
-
};
|
|
45
|
-
if (slots.default()[i].props["options"]) {
|
|
46
|
-
item["options"] = slots.default()[i].props["options"];
|
|
47
|
-
} else {
|
|
48
|
-
hasOptions.value = false;
|
|
26
|
+
setup(props, { emit, slots }) {
|
|
27
|
+
const barRef = ref();
|
|
28
|
+
const offset = ref(0);
|
|
29
|
+
const useChildren = () => {
|
|
30
|
+
const publicChildren = reactive([]);
|
|
31
|
+
const internalChildren = reactive([]);
|
|
32
|
+
const linkChildren2 = (value) => {
|
|
33
|
+
const link = (child) => {
|
|
34
|
+
if (child.proxy) {
|
|
35
|
+
internalChildren.push(child);
|
|
36
|
+
publicChildren.push(child.proxy);
|
|
49
37
|
}
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
} else {
|
|
62
|
-
activeTitle.value = title;
|
|
63
|
-
isShowCustomer.value = true;
|
|
64
|
-
showMask.value = true;
|
|
65
|
-
nutMenuIndex.value = 2001;
|
|
66
|
-
}
|
|
67
|
-
return;
|
|
68
|
-
}
|
|
69
|
-
if (menuList.length > 1) {
|
|
70
|
-
if (activeTitle.value === title) {
|
|
71
|
-
activeTitle.value = "";
|
|
72
|
-
nutMenuIndex.value = "auto";
|
|
73
|
-
showMask.value = false;
|
|
74
|
-
} else {
|
|
75
|
-
activeTitle.value = title;
|
|
76
|
-
nutMenuIndex.value = 2001;
|
|
77
|
-
showMask.value = true;
|
|
78
|
-
}
|
|
79
|
-
} else {
|
|
80
|
-
if (activeTitle.value) {
|
|
81
|
-
activeTitle.value = "";
|
|
82
|
-
nutMenuIndex.value = "auto";
|
|
83
|
-
showMask.value = false;
|
|
84
|
-
} else {
|
|
85
|
-
activeTitle.value = title;
|
|
86
|
-
nutMenuIndex.value = 2001;
|
|
87
|
-
showMask.value = true;
|
|
88
|
-
}
|
|
89
|
-
}
|
|
90
|
-
};
|
|
91
|
-
const handleClickOption = (text, index2, value) => {
|
|
92
|
-
menuList[index2].title = text;
|
|
93
|
-
activeTitle.value = "";
|
|
94
|
-
showMask.value = false;
|
|
95
|
-
nutMenuIndex.value = "auto";
|
|
96
|
-
emit("choose", text, value);
|
|
38
|
+
};
|
|
39
|
+
provide("menuParent", Object.assign({
|
|
40
|
+
link,
|
|
41
|
+
children: publicChildren,
|
|
42
|
+
internalChildren
|
|
43
|
+
}, value));
|
|
44
|
+
};
|
|
45
|
+
return {
|
|
46
|
+
children: publicChildren,
|
|
47
|
+
linkChildren: linkChildren2
|
|
48
|
+
};
|
|
97
49
|
};
|
|
50
|
+
const { children, linkChildren } = useChildren();
|
|
51
|
+
const opened = computed(() => children.some((item) => item.state.showWrapper));
|
|
98
52
|
const classes = computed(() => {
|
|
99
53
|
const prefixCls = componentName;
|
|
100
54
|
return {
|
|
101
55
|
[prefixCls]: true
|
|
102
56
|
};
|
|
103
57
|
});
|
|
104
|
-
const
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
isShowCustomer.value = false;
|
|
58
|
+
const updateOffset = () => {
|
|
59
|
+
if (barRef.value) {
|
|
60
|
+
const rect = useRect(barRef);
|
|
61
|
+
offset.value = rect.bottom;
|
|
109
62
|
}
|
|
110
63
|
};
|
|
64
|
+
linkChildren({ props, offset });
|
|
65
|
+
const toggleItem = (active) => {
|
|
66
|
+
children.forEach((item, index2) => {
|
|
67
|
+
if (index2 === active) {
|
|
68
|
+
updateOffset();
|
|
69
|
+
item.toggle();
|
|
70
|
+
} else if (item.state.showPopup) {
|
|
71
|
+
item.toggle(false, { immediate: true });
|
|
72
|
+
}
|
|
73
|
+
});
|
|
74
|
+
};
|
|
111
75
|
return {
|
|
112
|
-
|
|
113
|
-
|
|
76
|
+
toggleItem,
|
|
77
|
+
children,
|
|
78
|
+
opened,
|
|
114
79
|
classes,
|
|
115
|
-
|
|
116
|
-
styleObj,
|
|
117
|
-
nutMenuIndex,
|
|
118
|
-
hasOptions,
|
|
119
|
-
isShowCustomer,
|
|
120
|
-
handleClickTitle,
|
|
121
|
-
handleClickOption,
|
|
122
|
-
handleClose
|
|
80
|
+
barRef
|
|
123
81
|
};
|
|
124
82
|
}
|
|
125
83
|
});
|
|
126
|
-
const _hoisted_1 =
|
|
127
|
-
const _hoisted_2 =
|
|
128
|
-
const _hoisted_3 = ["onClick"];
|
|
129
|
-
const _hoisted_4 = { class: "customer-item" };
|
|
84
|
+
const _hoisted_1 = ["onClick"];
|
|
85
|
+
const _hoisted_2 = { class: "nut-menu__title-text" };
|
|
130
86
|
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
131
|
-
const _component_nut_popup = resolveComponent("nut-popup");
|
|
132
87
|
const _component_nut_icon = resolveComponent("nut-icon");
|
|
133
|
-
return openBlock(), createElementBlock("view",
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
createElementVNode("div", {
|
|
140
|
-
class: normalizeClass(_ctx.classes),
|
|
141
|
-
style: normalizeStyle({ "z-index": _ctx.nutMenuIndex })
|
|
88
|
+
return openBlock(), createElementBlock("view", {
|
|
89
|
+
class: normalizeClass(_ctx.classes)
|
|
90
|
+
}, [
|
|
91
|
+
createElementVNode("view", {
|
|
92
|
+
class: normalizeClass(["nut-menu__bar", { opened: _ctx.opened }]),
|
|
93
|
+
ref: "barRef"
|
|
142
94
|
}, [
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
return openBlock(), createElementBlock("div", {
|
|
146
|
-
key: index2,
|
|
147
|
-
class: normalizeClass(["title", {
|
|
148
|
-
"is-active": _ctx.activeTitle === menu.title,
|
|
149
|
-
disabled: menu.disabled
|
|
150
|
-
}]),
|
|
151
|
-
onClick: ($event) => !menu.disabled && _ctx.handleClickTitle(menu.title, index2)
|
|
152
|
-
}, [
|
|
153
|
-
createTextVNode(toDisplayString(menu.title) + " ", 1),
|
|
154
|
-
_ctx.activeTitle === menu.title ? (openBlock(), createBlock(_component_nut_icon, {
|
|
155
|
-
key: 0,
|
|
156
|
-
size: "10",
|
|
157
|
-
color: "#333",
|
|
158
|
-
name: "arrow-up"
|
|
159
|
-
})) : (openBlock(), createBlock(_component_nut_icon, {
|
|
160
|
-
key: 1,
|
|
161
|
-
size: "10",
|
|
162
|
-
color: "#999",
|
|
163
|
-
name: "arrow-down"
|
|
164
|
-
}))
|
|
165
|
-
], 10, _hoisted_2);
|
|
166
|
-
}), 128))
|
|
167
|
-
]),
|
|
168
|
-
(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.menuList, (menu, index2) => {
|
|
169
|
-
return withDirectives((openBlock(), createElementBlock("div", {
|
|
95
|
+
(openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.children, (item, index2) => {
|
|
96
|
+
return openBlock(), createElementBlock("view", {
|
|
170
97
|
key: index2,
|
|
171
|
-
class: "
|
|
98
|
+
class: normalizeClass(["nut-menu__item", { disabled: item.disabled }]),
|
|
99
|
+
onClick: ($event) => !item.disabled && _ctx.toggleItem(index2),
|
|
100
|
+
style: normalizeStyle({ color: item.state.showPopup ? _ctx.activeColor : "" })
|
|
172
101
|
}, [
|
|
173
|
-
createElementVNode("
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
}), 128))
|
|
189
|
-
])
|
|
190
|
-
], 512)), [
|
|
191
|
-
[vShow, _ctx.hasOptions && _ctx.activeTitle === menu.title]
|
|
192
|
-
]);
|
|
193
|
-
}), 128)),
|
|
194
|
-
withDirectives(createElementVNode("view", _hoisted_4, [
|
|
195
|
-
renderSlot(_ctx.$slots, "default")
|
|
196
|
-
], 512), [
|
|
197
|
-
[vShow, !_ctx.hasOptions && _ctx.isShowCustomer]
|
|
198
|
-
])
|
|
199
|
-
], 6)
|
|
200
|
-
]);
|
|
102
|
+
createElementVNode("view", {
|
|
103
|
+
class: normalizeClass(["nut-menu__title", { active: item.state.showPopup }])
|
|
104
|
+
}, [
|
|
105
|
+
createElementVNode("view", _hoisted_2, toDisplayString(item.renderTitle()), 1),
|
|
106
|
+
createVNode(_component_nut_icon, {
|
|
107
|
+
name: item.titleIcon,
|
|
108
|
+
size: "10",
|
|
109
|
+
class: "nut-menu__title-icon"
|
|
110
|
+
}, null, 8, ["name"])
|
|
111
|
+
], 2)
|
|
112
|
+
], 14, _hoisted_1);
|
|
113
|
+
}), 128))
|
|
114
|
+
], 2),
|
|
115
|
+
renderSlot(_ctx.$slots, "default")
|
|
116
|
+
], 2);
|
|
201
117
|
}
|
|
202
118
|
var index = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render]]);
|
|
203
119
|
export { index as default };
|