@nutui/nutui 3.2.6 → 3.2.8-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 +41 -0
- package/README.md +11 -1
- package/dist/nutui.es.js +2685 -4599
- package/dist/nutui.umd.js +2684 -4600
- package/dist/packages/_es/ActionSheet.js +2 -5
- package/dist/packages/_es/Address.js +162 -250
- package/dist/packages/_es/AddressList.js +229 -307
- package/dist/packages/_es/Animate.js +1 -1
- package/dist/packages/_es/Audio.js +1 -1
- package/dist/packages/_es/AudioOperate.js +1 -1
- package/dist/packages/_es/Avatar.js +1 -1
- package/dist/packages/_es/AvatarGroup.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 +11 -4
- package/dist/packages/_es/CalendarItem.js +1 -1
- package/dist/packages/_es/Card.js +1 -1
- package/dist/packages/_es/Cascader.js +2 -5
- package/dist/packages/_es/Category.js +1 -1
- package/dist/packages/_es/CategoryPane.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 +1 -1
- package/dist/packages/_es/CircleProgress.js +2 -2
- package/dist/packages/_es/Col.js +1 -1
- package/dist/packages/_es/Collapse.js +4 -11
- package/dist/packages/_es/CollapseItem.js +12 -12
- package/dist/packages/_es/Comment.js +1 -1
- package/dist/packages/_es/ConfigProvider.js +1 -1
- package/dist/packages/_es/CountDown.js +2 -10
- package/dist/packages/_es/CountUp.js +1 -1
- package/dist/packages/_es/DatePicker.js +8 -17
- package/dist/packages/_es/Dialog.js +38 -63
- package/dist/packages/_es/Divider.js +1 -1
- package/dist/packages/_es/Drag.js +1 -1
- package/dist/packages/_es/Ecard.js +1 -1
- package/dist/packages/_es/Elevator.js +9 -3
- package/dist/packages/_es/Ellipsis.js +3 -3
- package/dist/packages/_es/Empty.js +1 -1
- package/dist/packages/_es/FixedNav.js +1 -1
- package/dist/packages/_es/Form.js +39 -31
- package/dist/packages/_es/FormItem.js +1 -1
- package/dist/packages/_es/Grid.js +2 -2
- package/dist/packages/_es/GridItem.js +1 -1
- package/dist/packages/_es/Icon.js +1 -1
- package/dist/packages/_es/Image.js +1 -1
- package/dist/packages/_es/ImagePreview.js +131 -214
- package/dist/packages/_es/Indicator.js +4 -4
- package/dist/packages/_es/InfiniteLoading.js +9 -2
- package/dist/packages/_es/Input.js +109 -132
- package/dist/packages/_es/InputNumber.js +1 -1
- package/dist/packages/_es/Invoice.js +1 -1
- package/dist/packages/_es/Layout.js +1 -1
- package/dist/packages/_es/List.js +1 -1
- package/dist/packages/_es/Menu.js +14 -1
- package/dist/packages/_es/MenuItem.js +14 -8
- package/dist/packages/_es/Navbar.js +1 -1
- package/dist/packages/_es/NoticeBar.js +1 -1
- package/dist/packages/_es/Notify.js +5 -7
- package/dist/packages/_es/NumberKeyboard.js +4 -4
- package/dist/packages/_es/OverLay.js +60 -63
- package/dist/packages/_es/Pagination.js +1 -1
- package/dist/packages/_es/Picker.js +25 -50
- package/dist/packages/_es/Popover.js +111 -930
- package/dist/packages/_es/Popup.js +108 -261
- package/dist/packages/_es/Price.js +1 -1
- package/dist/packages/_es/Progress.js +1 -1
- package/dist/packages/_es/Radio.js +1 -1
- package/dist/packages/_es/RadioGroup.js +1 -1
- package/dist/packages/_es/Range.js +1 -1
- package/dist/packages/_es/Rate.js +1 -1
- package/dist/packages/_es/Row.js +1 -1
- package/dist/packages/_es/SearchBar.js +1 -1
- package/dist/packages/_es/ShortPassword.js +4 -4
- package/dist/packages/_es/SideNavBar.js +1 -1
- package/dist/packages/_es/SideNavBarItem.js +1 -1
- package/dist/packages/_es/Signature.js +1 -1
- package/dist/packages/_es/Skeleton.js +19 -24
- package/dist/packages/_es/Sku.js +4 -7
- package/dist/packages/_es/Step.js +1 -1
- package/dist/packages/_es/Steps.js +1 -1
- package/dist/packages/_es/Sticky.js +1 -1
- package/dist/packages/_es/SubSideNavBar.js +1 -1
- package/dist/packages/_es/Swipe.js +1 -1
- package/dist/packages/_es/Swiper.js +1 -1
- 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 +24 -10
- package/dist/packages/_es/Table.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 +4 -4
- package/dist/packages/_es/Toast.js +5 -6
- package/dist/packages/_es/TrendArrow.js +1 -1
- package/dist/packages/_es/Uploader.js +7 -7
- package/dist/packages/_es/Video.js +3 -2
- package/dist/packages/_es/WaterMark.js +1 -1
- package/dist/packages/_es/common.js +1 -1
- package/dist/packages/_es/component.js +22 -2
- package/dist/packages/_es/index.js +1 -1
- package/dist/packages/_es/index2.js +1 -1
- package/dist/packages/_es/index3.js +1 -1
- package/dist/packages/_es/index4.js +1 -1
- package/dist/packages/_es/index5.js +8 -2
- package/dist/packages/_es/interceptor.js +32 -0
- package/dist/packages/_es/mountComponent.js +42 -0
- package/dist/packages/_es/plugin-vue_export-helper.js +1 -1
- package/dist/packages/_es/props.js +80 -0
- package/dist/packages/_es/pxCheck.js +1 -1
- package/dist/packages/_es/raf.js +1 -1
- package/dist/packages/_es/style.css +1 -1
- package/dist/packages/address/index.scss +12 -3
- package/dist/packages/addresslist/index.scss +61 -101
- package/dist/packages/card/index.scss +1 -0
- package/dist/packages/ellipsis/index.scss +4 -0
- package/dist/packages/formitem/index.scss +2 -0
- package/dist/packages/imagepreview/index.scss +14 -1
- package/dist/packages/inputnumber/index.scss +5 -1
- package/dist/packages/locale/lang/baseLang.js +1 -1
- package/dist/packages/locale/lang/en-US.js +1 -1
- package/dist/packages/locale/lang/id-ID.js +1 -1
- package/dist/packages/locale/lang/index.js +1 -1
- package/dist/packages/locale/lang/zh-CN.js +1 -1
- package/dist/packages/locale/lang/zh-TW.js +1 -1
- package/dist/packages/menuitem/index.scss +0 -14
- package/dist/packages/notify/index.scss +2 -2
- package/dist/packages/overlay/index.scss +2 -1
- package/dist/packages/picker/index.scss +20 -12
- package/dist/packages/popover/index.scss +191 -363
- package/dist/packages/popup/index.scss +3 -14
- package/dist/packages/signature/index.scss +6 -2
- package/dist/packages/skeleton/index.scss +21 -19
- package/dist/packages/sticky/index.scss +3 -0
- package/dist/packages/tabbaritem/index.scss +4 -0
- package/dist/packages/timeselect/index.scss +0 -1
- package/dist/smartips/attributes.json +91 -111
- package/dist/smartips/tags.json +22 -35
- package/dist/smartips/web-types.json +162 -221
- package/dist/style.css +1 -1
- package/dist/styles/font/config.json +4 -0
- package/dist/styles/font/demo_index.html +118 -26
- package/dist/styles/font/iconfont.css +23 -7
- package/dist/styles/font/iconfont.js +6 -6
- package/dist/styles/font/iconfont.json +35 -7
- package/dist/styles/font/iconfont.ttf +0 -0
- package/dist/styles/font/iconfont.woff +0 -0
- package/dist/styles/font/iconfont.woff2 +0 -0
- package/dist/styles/themes/default.scss +52 -54
- package/dist/styles/themes/jdb.scss +52 -54
- package/dist/styles/themes/jddkh.scss +52 -54
- package/dist/styles/themes/jdt.scss +52 -54
- package/dist/styles/variables-jdb.scss +8 -1
- package/dist/styles/variables-jddkh.scss +8 -1
- package/dist/styles/variables-jdt.scss +8 -1
- package/dist/styles/variables.scss +17 -1
- package/dist/types/__VUE/actionsheet/index.vue.d.ts +58 -54
- package/dist/types/__VUE/address/index.vue.d.ts +71 -91
- package/dist/types/__VUE/addresslist/components/GeneralShell.vue.d.ts +29 -9
- package/dist/types/__VUE/addresslist/components/ItemContents.vue.d.ts +4 -13
- package/dist/types/__VUE/addresslist/components/SwipeShell.vue.d.ts +9 -9
- package/dist/types/__VUE/addresslist/index.vue.d.ts +23 -20
- package/dist/types/__VUE/audio/index.vue.d.ts +4 -4
- package/dist/types/__VUE/avatar/index.vue.d.ts +2 -2
- package/dist/types/__VUE/avatargroup/index.vue.d.ts +1 -1
- package/dist/types/__VUE/backtop/index.vue.d.ts +1 -1
- package/dist/types/__VUE/badge/index.vue.d.ts +1 -1
- package/dist/types/__VUE/button/index.vue.d.ts +1 -1
- package/dist/types/__VUE/calendar/index.vue.d.ts +11 -0
- package/dist/types/__VUE/calendaritem/index.vue.d.ts +15 -5
- package/dist/types/__VUE/cascader/index.vue.d.ts +47 -52
- package/dist/types/__VUE/cell/index.vue.d.ts +5 -5
- package/dist/types/__VUE/collapseitem/index.vue.d.ts +1 -1
- package/dist/types/__VUE/countdown/index.vue.d.ts +0 -1
- package/dist/types/__VUE/countdown/util.d.ts +0 -1
- package/dist/types/__VUE/countup/index.vue.d.ts +2 -2
- package/dist/types/__VUE/datepicker/index.vue.d.ts +55 -60
- package/dist/types/__VUE/dialog/index.d.ts +0 -3
- package/dist/types/__VUE/dialog/index.vue.d.ts +48 -57
- package/dist/types/__VUE/elevator/index.vue.d.ts +2 -1
- package/dist/types/__VUE/form/common.d.ts +4 -2
- package/dist/types/__VUE/form/index.vue.d.ts +4 -4
- package/dist/types/__VUE/grid/index.vue.d.ts +2 -2
- package/dist/types/__VUE/image/index.vue.d.ts +1 -1
- package/dist/types/__VUE/imagepreview/imagePreviewItem.vue.d.ts +27 -20
- package/dist/types/__VUE/imagepreview/index.d.ts +19 -5
- package/dist/types/__VUE/imagepreview/index.vue.d.ts +56 -42
- package/dist/types/__VUE/imagepreview/types.d.ts +44 -0
- package/dist/types/__VUE/indicator/index.vue.d.ts +1 -0
- package/dist/types/__VUE/input/index.vue.d.ts +37 -26
- package/dist/types/__VUE/invoice/index.vue.d.ts +1 -1
- package/dist/types/__VUE/menuitem/index.vue.d.ts +3 -1
- package/dist/types/__VUE/navbar/index.vue.d.ts +1 -1
- package/dist/types/__VUE/noticebar/index.vue.d.ts +4 -4
- package/dist/types/__VUE/notify/index.vue.d.ts +3 -3
- package/dist/types/__VUE/numberkeyboard/index.vue.d.ts +3 -3
- package/dist/types/__VUE/overlay/index.vue.d.ts +11 -12
- package/dist/types/__VUE/picker/Column.vue.d.ts +4 -6
- package/dist/types/__VUE/picker/index.vue.d.ts +60 -67
- package/dist/types/__VUE/popover/index.vue.d.ts +36 -139
- package/dist/types/__VUE/popup/common.d.ts +103 -0
- package/dist/types/__VUE/popup/index.vue.d.ts +55 -1591
- package/dist/types/__VUE/popup/props.d.ts +82 -0
- package/dist/types/__VUE/range/index.vue.d.ts +7 -7
- package/dist/types/__VUE/shortpassword/index.vue.d.ts +4 -4
- package/dist/types/__VUE/skeleton/common.d.ts +2 -3
- package/dist/types/__VUE/skeleton/index.vue.d.ts +2 -3
- package/dist/types/__VUE/sku/index.vue.d.ts +56 -61
- package/dist/types/__VUE/step/index.vue.d.ts +1 -1
- package/dist/types/__VUE/swiper/index.vue.d.ts +1 -1
- package/dist/types/__VUE/tabbaritem/index.vue.d.ts +2 -1
- package/dist/types/__VUE/timeselect/index.vue.d.ts +3 -3
- package/dist/types/__VUE/toast/index.vue.d.ts +1 -1
- package/dist/types/__VUE/uploader/index.vue.d.ts +15 -6
- package/dist/types/__VUE/video/index.vue.d.ts +5 -5
- package/dist/types/index.d.ts +1 -1
- package/dist/types/nutui.d.ts +1 -3
- package/package.json +3 -3
- package/dist/packages/_es/OldPicker.js +0 -486
- package/dist/packages/_es/PullRefresh.js +0 -349
- package/dist/packages/oldpicker/index.scss +0 -133
- package/dist/packages/pullrefresh/index.scss +0 -71
- package/dist/types/__VUE/addresslist/components/LongPressShell.vue.d.ts +0 -47
- package/dist/types/__VUE/datepicker/utils.d.ts +0 -5
- package/dist/types/__VUE/oldpicker/Column.vue.d.ts +0 -96
- package/dist/types/__VUE/oldpicker/commonProps.d.ts +0 -22
- package/dist/types/__VUE/oldpicker/index.vue.d.ts +0 -369
- package/dist/types/__VUE/oldpicker/types.d.ts +0 -24
- package/dist/types/__VUE/popup/use-lock-scroll.d.ts +0 -5
- package/dist/types/__VUE/pullrefresh/index.vue.d.ts +0 -128
- package/dist/types/__VUE/pullrefresh/use-touch.d.ts +0 -20
- package/dist/types/__VUE/pullrefresh/util.d.ts +0 -6
|
@@ -1,35 +1,29 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* @nutui/nutui v3.2.
|
|
2
|
+
* @nutui/nutui v3.2.7 Fri Dec 02 2022 14:12:17 GMT+0800 (中国标准时间)
|
|
3
3
|
* (c) 2022 @jdf2e.
|
|
4
4
|
* Released under the MIT License.
|
|
5
5
|
*/
|
|
6
|
-
import { resolveComponent, openBlock, createElementBlock, createElementVNode, renderSlot, toDisplayString, createCommentVNode, createVNode, createTextVNode, ref,
|
|
7
|
-
import { c as createComponent,
|
|
6
|
+
import { resolveComponent, openBlock, createElementBlock, createElementVNode, renderSlot, toDisplayString, createCommentVNode, createVNode, createTextVNode, ref, createBlock, withCtx, reactive, computed, watch, onMounted, normalizeClass, Fragment, renderList, createSlots } from "vue";
|
|
7
|
+
import { c as createComponent, k as floatData } from "./component.js";
|
|
8
8
|
import { _ as _export_sfc } from "./plugin-vue_export-helper.js";
|
|
9
9
|
import "../locale/lang";
|
|
10
|
-
|
|
11
|
-
const { componentName: componentName$4, create: create$4 } = createComponent("item-contents");
|
|
10
|
+
const { create: create$3 } = createComponent("addresslist-item");
|
|
12
11
|
const { translate: translate$1 } = createComponent("addresslist");
|
|
13
|
-
const _sfc_main$
|
|
12
|
+
const _sfc_main$3 = create$3({
|
|
14
13
|
props: {
|
|
15
|
-
name: {
|
|
16
|
-
type: String,
|
|
17
|
-
default: ""
|
|
18
|
-
},
|
|
19
14
|
item: {
|
|
20
15
|
type: Object,
|
|
21
16
|
default: {}
|
|
22
17
|
}
|
|
23
18
|
},
|
|
24
|
-
|
|
25
|
-
emits: ["delIconClick", "editIconClick", "itemClick"],
|
|
19
|
+
emits: ["delIcon", "editIcon", "itemClick"],
|
|
26
20
|
setup(props, { emit }) {
|
|
27
21
|
const delClick = (event) => {
|
|
28
|
-
emit("
|
|
22
|
+
emit("delIcon", event, props.item);
|
|
29
23
|
event.stopPropagation();
|
|
30
24
|
};
|
|
31
25
|
const editClick = (event) => {
|
|
32
|
-
emit("
|
|
26
|
+
emit("editIcon", event, props.item);
|
|
33
27
|
event.stopPropagation();
|
|
34
28
|
};
|
|
35
29
|
const contentsClick = (event) => {
|
|
@@ -44,23 +38,23 @@ const _sfc_main$4 = create$4({
|
|
|
44
38
|
};
|
|
45
39
|
}
|
|
46
40
|
});
|
|
47
|
-
const _hoisted_1$
|
|
48
|
-
const _hoisted_2$1 = { class: "nut-
|
|
49
|
-
const _hoisted_3$1 = { class: "nut-
|
|
50
|
-
const _hoisted_4$1 = { class: "nut-
|
|
41
|
+
const _hoisted_1$2 = { class: "nut-addresslist-item__info" };
|
|
42
|
+
const _hoisted_2$1 = { class: "nut-addresslist-item__info-contact" };
|
|
43
|
+
const _hoisted_3$1 = { class: "nut-addresslist-item__info-contact-name" };
|
|
44
|
+
const _hoisted_4$1 = { class: "nut-addresslist-item__info-contact-tel" };
|
|
51
45
|
const _hoisted_5$1 = {
|
|
52
46
|
key: 0,
|
|
53
|
-
class: "nut-
|
|
47
|
+
class: "nut-addresslist-item__info-contact-default"
|
|
54
48
|
};
|
|
55
|
-
const _hoisted_6$1 = { class: "nut-
|
|
56
|
-
const _hoisted_7$1 = { class: "nut-
|
|
57
|
-
function _sfc_render$
|
|
49
|
+
const _hoisted_6$1 = { class: "nut-addresslist-item__info-handle" };
|
|
50
|
+
const _hoisted_7$1 = { class: "nut-addresslist-item__addr" };
|
|
51
|
+
function _sfc_render$3(_ctx, _cache, $props, $setup, $data, $options) {
|
|
58
52
|
const _component_nut_icon = resolveComponent("nut-icon");
|
|
59
53
|
return openBlock(), createElementBlock("div", {
|
|
60
|
-
class: "nut-item
|
|
54
|
+
class: "nut-addresslist-item",
|
|
61
55
|
onClick: _cache[0] || (_cache[0] = (...args) => _ctx.contentsClick && _ctx.contentsClick(...args))
|
|
62
56
|
}, [
|
|
63
|
-
createElementVNode("div", _hoisted_1$
|
|
57
|
+
createElementVNode("div", _hoisted_1$2, [
|
|
64
58
|
createElementVNode("div", _hoisted_2$1, [
|
|
65
59
|
renderSlot(_ctx.$slots, "contentTop", {}, () => [
|
|
66
60
|
createElementVNode("div", _hoisted_3$1, toDisplayString(_ctx.item.addressName), 1),
|
|
@@ -72,12 +66,12 @@ function _sfc_render$4(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
72
66
|
renderSlot(_ctx.$slots, "contentIcon", {}, () => [
|
|
73
67
|
createVNode(_component_nut_icon, {
|
|
74
68
|
name: "del",
|
|
75
|
-
class: "nut-
|
|
69
|
+
class: "nut-addresslist-item__info-handle-del",
|
|
76
70
|
onClick: _ctx.delClick
|
|
77
71
|
}, null, 8, ["onClick"]),
|
|
78
72
|
createVNode(_component_nut_icon, {
|
|
79
73
|
name: "edit",
|
|
80
|
-
class: "nut-
|
|
74
|
+
class: "nut-addresslist-item__info-handle-edit",
|
|
81
75
|
onClick: _ctx.editClick
|
|
82
76
|
}, null, 8, ["onClick"])
|
|
83
77
|
])
|
|
@@ -90,184 +84,8 @@ function _sfc_render$4(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
90
84
|
])
|
|
91
85
|
]);
|
|
92
86
|
}
|
|
93
|
-
var ItemContents = /* @__PURE__ */ _export_sfc(_sfc_main$
|
|
94
|
-
const {
|
|
95
|
-
const _sfc_main$3 = create$3({
|
|
96
|
-
props: {
|
|
97
|
-
item: {
|
|
98
|
-
type: Object,
|
|
99
|
-
default: {}
|
|
100
|
-
}
|
|
101
|
-
},
|
|
102
|
-
emits: [
|
|
103
|
-
"holdingDown",
|
|
104
|
-
"handleDel",
|
|
105
|
-
"handelMask",
|
|
106
|
-
"handleCopy",
|
|
107
|
-
"handleSet",
|
|
108
|
-
"handleDelIcon",
|
|
109
|
-
"handleEditIcon",
|
|
110
|
-
"handleItemContent"
|
|
111
|
-
],
|
|
112
|
-
components: {
|
|
113
|
-
ItemContents
|
|
114
|
-
},
|
|
115
|
-
setup(props, { emit, slots }) {
|
|
116
|
-
let loop = null;
|
|
117
|
-
const showMaskRef = ref(false);
|
|
118
|
-
const holdingFunc = (event) => {
|
|
119
|
-
loop = 0;
|
|
120
|
-
showMaskRef.value = true;
|
|
121
|
-
emit("holdingDown", event, props.item);
|
|
122
|
-
};
|
|
123
|
-
const holddownstart = (event) => {
|
|
124
|
-
loop = setTimeout(() => {
|
|
125
|
-
holdingFunc(event);
|
|
126
|
-
}, 300);
|
|
127
|
-
};
|
|
128
|
-
const holddownmove = (event) => {
|
|
129
|
-
clearTimeout(loop);
|
|
130
|
-
};
|
|
131
|
-
const holddownend = (event) => {
|
|
132
|
-
clearTimeout(loop);
|
|
133
|
-
};
|
|
134
|
-
const hideMaskClick = (event) => {
|
|
135
|
-
showMaskRef.value = false;
|
|
136
|
-
};
|
|
137
|
-
const copyCLick = (event) => {
|
|
138
|
-
if (loop == 0)
|
|
139
|
-
return;
|
|
140
|
-
emit("handleCopy", event, props.item);
|
|
141
|
-
event.stopPropagation();
|
|
142
|
-
};
|
|
143
|
-
const setDefault = (event) => {
|
|
144
|
-
if (loop == 0)
|
|
145
|
-
return;
|
|
146
|
-
emit("handleSet", event, props.item);
|
|
147
|
-
event.stopPropagation();
|
|
148
|
-
};
|
|
149
|
-
const delClick = (event) => {
|
|
150
|
-
if (loop == 0)
|
|
151
|
-
return;
|
|
152
|
-
emit("handleDel", event, props.item);
|
|
153
|
-
event.stopPropagation();
|
|
154
|
-
};
|
|
155
|
-
const maskClick = (event) => {
|
|
156
|
-
if (loop != 0) {
|
|
157
|
-
showMaskRef.value = false;
|
|
158
|
-
}
|
|
159
|
-
event.stopPropagation();
|
|
160
|
-
event.preventDefault();
|
|
161
|
-
};
|
|
162
|
-
const delShellClick = (event, item) => {
|
|
163
|
-
emit("handleDelIcon", event, props.item);
|
|
164
|
-
event.stopPropagation();
|
|
165
|
-
};
|
|
166
|
-
const editShellClick = (event, item) => {
|
|
167
|
-
emit("handleEditIcon", event, props.item);
|
|
168
|
-
event.stopPropagation();
|
|
169
|
-
};
|
|
170
|
-
const itemShellClick = (event, item) => {
|
|
171
|
-
emit("handleItemContent", event, props.item);
|
|
172
|
-
event.stopPropagation();
|
|
173
|
-
};
|
|
174
|
-
return {
|
|
175
|
-
holddownstart,
|
|
176
|
-
holddownmove,
|
|
177
|
-
holddownend,
|
|
178
|
-
showMaskRef,
|
|
179
|
-
delClick,
|
|
180
|
-
copyCLick,
|
|
181
|
-
hideMaskClick,
|
|
182
|
-
setDefault,
|
|
183
|
-
maskClick,
|
|
184
|
-
delShellClick,
|
|
185
|
-
editShellClick,
|
|
186
|
-
itemShellClick
|
|
187
|
-
};
|
|
188
|
-
}
|
|
189
|
-
});
|
|
190
|
-
const _hoisted_1$3 = { class: "nut-long-press-shell" };
|
|
191
|
-
const _hoisted_2 = /* @__PURE__ */ createElementVNode("div", { class: "mask-contain" }, [
|
|
192
|
-
/* @__PURE__ */ createTextVNode(" \u590D\u5236"),
|
|
193
|
-
/* @__PURE__ */ createElementVNode("br"),
|
|
194
|
-
/* @__PURE__ */ createTextVNode("\u5730\u5740 ")
|
|
195
|
-
], -1);
|
|
196
|
-
const _hoisted_3 = [
|
|
197
|
-
_hoisted_2
|
|
198
|
-
];
|
|
199
|
-
const _hoisted_4 = /* @__PURE__ */ createElementVNode("div", { class: "mask-contain" }, [
|
|
200
|
-
/* @__PURE__ */ createTextVNode(" \u8BBE\u7F6E"),
|
|
201
|
-
/* @__PURE__ */ createElementVNode("br"),
|
|
202
|
-
/* @__PURE__ */ createTextVNode("\u9ED8\u8BA4 ")
|
|
203
|
-
], -1);
|
|
204
|
-
const _hoisted_5 = [
|
|
205
|
-
_hoisted_4
|
|
206
|
-
];
|
|
207
|
-
const _hoisted_6 = /* @__PURE__ */ createElementVNode("div", { class: "mask-contain" }, [
|
|
208
|
-
/* @__PURE__ */ createTextVNode(" \u5220\u9664"),
|
|
209
|
-
/* @__PURE__ */ createElementVNode("br"),
|
|
210
|
-
/* @__PURE__ */ createTextVNode("\u5730\u5740 ")
|
|
211
|
-
], -1);
|
|
212
|
-
const _hoisted_7 = [
|
|
213
|
-
_hoisted_6
|
|
214
|
-
];
|
|
215
|
-
function _sfc_render$3(_ctx, _cache, $props, $setup, $data, $options) {
|
|
216
|
-
const _component_item_contents = resolveComponent("item-contents");
|
|
217
|
-
return openBlock(), createElementBlock("div", _hoisted_1$3, [
|
|
218
|
-
createElementVNode("div", {
|
|
219
|
-
class: "nut-long-press-shell__contain",
|
|
220
|
-
onTouchstart: _cache[4] || (_cache[4] = (...args) => _ctx.holddownstart && _ctx.holddownstart(...args)),
|
|
221
|
-
onTouchend: _cache[5] || (_cache[5] = (...args) => _ctx.holddownend && _ctx.holddownend(...args)),
|
|
222
|
-
onTouchmove: _cache[6] || (_cache[6] = (...args) => _ctx.holddownmove && _ctx.holddownmove(...args))
|
|
223
|
-
}, [
|
|
224
|
-
createVNode(_component_item_contents, {
|
|
225
|
-
item: _ctx.item,
|
|
226
|
-
onDelIconClick: _ctx.delShellClick,
|
|
227
|
-
onEditIconClick: _ctx.editShellClick,
|
|
228
|
-
onItemClick: _ctx.itemShellClick
|
|
229
|
-
}, {
|
|
230
|
-
contentTop: withCtx(() => [
|
|
231
|
-
renderSlot(_ctx.$slots, "contentInfo")
|
|
232
|
-
]),
|
|
233
|
-
contentIcon: withCtx(() => [
|
|
234
|
-
renderSlot(_ctx.$slots, "contentIcons")
|
|
235
|
-
]),
|
|
236
|
-
contentAddr: withCtx(() => [
|
|
237
|
-
renderSlot(_ctx.$slots, "contentAddrs")
|
|
238
|
-
]),
|
|
239
|
-
_: 3
|
|
240
|
-
}, 8, ["item", "onDelIconClick", "onEditIconClick", "onItemClick"]),
|
|
241
|
-
_ctx.showMaskRef ? (openBlock(), createElementBlock("div", {
|
|
242
|
-
key: 0,
|
|
243
|
-
class: "nut-long-press-shell__contain-mask",
|
|
244
|
-
onClick: _cache[3] || (_cache[3] = (...args) => _ctx.maskClick && _ctx.maskClick(...args))
|
|
245
|
-
}, [
|
|
246
|
-
renderSlot(_ctx.$slots, "longpressAll", {}, () => [
|
|
247
|
-
createElementVNode("div", {
|
|
248
|
-
class: "nut-long-press-shell__contain-mask-copy",
|
|
249
|
-
onClick: _cache[0] || (_cache[0] = (...args) => _ctx.copyCLick && _ctx.copyCLick(...args))
|
|
250
|
-
}, _hoisted_3),
|
|
251
|
-
createElementVNode("div", {
|
|
252
|
-
class: "nut-long-press-shell__contain-mask-set",
|
|
253
|
-
onClick: _cache[1] || (_cache[1] = (...args) => _ctx.setDefault && _ctx.setDefault(...args))
|
|
254
|
-
}, _hoisted_5),
|
|
255
|
-
createElementVNode("div", {
|
|
256
|
-
class: "nut-long-press-shell__contain-mask-del",
|
|
257
|
-
onClick: _cache[2] || (_cache[2] = (...args) => _ctx.delClick && _ctx.delClick(...args))
|
|
258
|
-
}, _hoisted_7)
|
|
259
|
-
])
|
|
260
|
-
])) : createCommentVNode("", true)
|
|
261
|
-
], 32),
|
|
262
|
-
_ctx.showMaskRef ? (openBlock(), createElementBlock("div", {
|
|
263
|
-
key: 0,
|
|
264
|
-
class: "nut-addresslist__mask-bottom",
|
|
265
|
-
onClick: _cache[7] || (_cache[7] = (...args) => _ctx.hideMaskClick && _ctx.hideMaskClick(...args))
|
|
266
|
-
})) : createCommentVNode("", true)
|
|
267
|
-
]);
|
|
268
|
-
}
|
|
269
|
-
var LongPressShell = /* @__PURE__ */ _export_sfc(_sfc_main$3, [["render", _sfc_render$3]]);
|
|
270
|
-
const { componentName: componentName$2, create: create$2 } = createComponent("swipe-shell");
|
|
87
|
+
var ItemContents = /* @__PURE__ */ _export_sfc(_sfc_main$3, [["render", _sfc_render$3]]);
|
|
88
|
+
const { create: create$2 } = createComponent("addresslist-swipe");
|
|
271
89
|
const _sfc_main$2 = create$2({
|
|
272
90
|
props: {
|
|
273
91
|
item: {
|
|
@@ -275,28 +93,28 @@ const _sfc_main$2 = create$2({
|
|
|
275
93
|
default: {}
|
|
276
94
|
}
|
|
277
95
|
},
|
|
278
|
-
emits: ["
|
|
96
|
+
emits: ["delIcon", "editIcon", "itemClick", "swipeDel"],
|
|
279
97
|
components: {
|
|
280
98
|
ItemContents
|
|
281
99
|
},
|
|
282
|
-
setup(props, { emit
|
|
100
|
+
setup(props, { emit }) {
|
|
283
101
|
const moveRef = ref(false);
|
|
284
|
-
const
|
|
285
|
-
emit("
|
|
102
|
+
const delClick = (event) => {
|
|
103
|
+
emit("delIcon", event, props.item);
|
|
286
104
|
event.stopPropagation();
|
|
287
105
|
};
|
|
288
|
-
const
|
|
289
|
-
emit("
|
|
106
|
+
const editClick = (event) => {
|
|
107
|
+
emit("editIcon", event, props.item);
|
|
290
108
|
event.stopPropagation();
|
|
291
109
|
};
|
|
292
|
-
const
|
|
110
|
+
const itemClick = (event) => {
|
|
293
111
|
if (moveRef.value)
|
|
294
112
|
return;
|
|
295
|
-
emit("
|
|
113
|
+
emit("itemClick", event, props.item);
|
|
296
114
|
event.stopPropagation();
|
|
297
115
|
};
|
|
298
|
-
const swipeDelClick = (event
|
|
299
|
-
emit("
|
|
116
|
+
const swipeDelClick = (event) => {
|
|
117
|
+
emit("swipeDel", event, props.item);
|
|
300
118
|
event.stopPropagation();
|
|
301
119
|
};
|
|
302
120
|
const swipestart = () => {
|
|
@@ -306,16 +124,16 @@ const _sfc_main$2 = create$2({
|
|
|
306
124
|
moveRef.value = true;
|
|
307
125
|
};
|
|
308
126
|
return {
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
127
|
+
delClick,
|
|
128
|
+
editClick,
|
|
129
|
+
itemClick,
|
|
312
130
|
swipeDelClick,
|
|
313
131
|
swipestart,
|
|
314
132
|
swipemove
|
|
315
133
|
};
|
|
316
134
|
}
|
|
317
135
|
});
|
|
318
|
-
const _hoisted_1$
|
|
136
|
+
const _hoisted_1$1 = { class: "nut-addresslist-swipe" };
|
|
319
137
|
function _sfc_render$2(_ctx, _cache, $props, $setup, $data, $options) {
|
|
320
138
|
const _component_item_contents = resolveComponent("item-contents");
|
|
321
139
|
const _component_nut_button = resolveComponent("nut-button");
|
|
@@ -337,12 +155,12 @@ function _sfc_render$2(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
337
155
|
])
|
|
338
156
|
]),
|
|
339
157
|
default: withCtx(() => [
|
|
340
|
-
createElementVNode("div", _hoisted_1$
|
|
158
|
+
createElementVNode("div", _hoisted_1$1, [
|
|
341
159
|
createVNode(_component_item_contents, {
|
|
342
160
|
item: _ctx.item,
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
onItemClick: _ctx.
|
|
161
|
+
onDelIcon: _ctx.delClick,
|
|
162
|
+
onEditIcon: _ctx.editClick,
|
|
163
|
+
onItemClick: _ctx.itemClick,
|
|
346
164
|
onTouchmove: _ctx.swipemove,
|
|
347
165
|
onTouchstart: _ctx.swipestart
|
|
348
166
|
}, {
|
|
@@ -356,59 +174,134 @@ function _sfc_render$2(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
356
174
|
renderSlot(_ctx.$slots, "contentAddrs")
|
|
357
175
|
]),
|
|
358
176
|
_: 3
|
|
359
|
-
}, 8, ["item", "
|
|
177
|
+
}, 8, ["item", "onDelIcon", "onEditIcon", "onItemClick", "onTouchmove", "onTouchstart"])
|
|
360
178
|
])
|
|
361
179
|
]),
|
|
362
180
|
_: 3
|
|
363
181
|
});
|
|
364
182
|
}
|
|
365
183
|
var SwipeShell = /* @__PURE__ */ _export_sfc(_sfc_main$2, [["render", _sfc_render$2]]);
|
|
366
|
-
const {
|
|
184
|
+
const { create: create$1 } = createComponent("addresslist-general");
|
|
367
185
|
const _sfc_main$1 = create$1({
|
|
368
186
|
props: {
|
|
369
187
|
item: {
|
|
370
188
|
type: Object,
|
|
371
189
|
default: {}
|
|
190
|
+
},
|
|
191
|
+
longPress: {
|
|
192
|
+
type: Boolean,
|
|
193
|
+
default: false
|
|
372
194
|
}
|
|
373
195
|
},
|
|
374
|
-
emits: ["
|
|
196
|
+
emits: ["delIcon", "editIcon", "itemClick", "longDown", "longCopy", "longSet", "longDel"],
|
|
375
197
|
components: {
|
|
376
198
|
ItemContents
|
|
377
199
|
},
|
|
378
|
-
setup(props, { emit
|
|
379
|
-
|
|
380
|
-
|
|
200
|
+
setup(props, { emit }) {
|
|
201
|
+
let loop = null;
|
|
202
|
+
const showMaskRef = ref(false);
|
|
203
|
+
const delShellClick = (event) => {
|
|
204
|
+
emit("delIcon", event, props.item);
|
|
205
|
+
event.stopPropagation();
|
|
206
|
+
};
|
|
207
|
+
const editShellClick = (event) => {
|
|
208
|
+
emit("editIcon", event, props.item);
|
|
209
|
+
event.stopPropagation();
|
|
210
|
+
};
|
|
211
|
+
const itemShellClick = (event) => {
|
|
212
|
+
emit("itemClick", event, props.item);
|
|
213
|
+
event.stopPropagation();
|
|
214
|
+
};
|
|
215
|
+
const holdingFunc = (event) => {
|
|
216
|
+
loop = 0;
|
|
217
|
+
showMaskRef.value = true;
|
|
218
|
+
emit("longDown", event, props.item);
|
|
219
|
+
};
|
|
220
|
+
const holddownstart = (event) => {
|
|
221
|
+
loop = setTimeout(() => {
|
|
222
|
+
holdingFunc(event);
|
|
223
|
+
}, 300);
|
|
224
|
+
};
|
|
225
|
+
const holddownmove = () => {
|
|
226
|
+
clearTimeout(loop);
|
|
227
|
+
};
|
|
228
|
+
const holddownend = () => {
|
|
229
|
+
clearTimeout(loop);
|
|
230
|
+
};
|
|
231
|
+
const hideMaskClick = () => {
|
|
232
|
+
showMaskRef.value = false;
|
|
233
|
+
};
|
|
234
|
+
const copyCLick = (event) => {
|
|
235
|
+
emit("longCopy", event, props.item);
|
|
381
236
|
event.stopPropagation();
|
|
382
237
|
};
|
|
383
|
-
const
|
|
384
|
-
emit("
|
|
238
|
+
const setDefault = (event) => {
|
|
239
|
+
emit("longSet", event, props.item);
|
|
385
240
|
event.stopPropagation();
|
|
386
241
|
};
|
|
387
|
-
const
|
|
388
|
-
emit("
|
|
242
|
+
const delClick = (event) => {
|
|
243
|
+
emit("longDel", event, props.item);
|
|
389
244
|
event.stopPropagation();
|
|
390
245
|
};
|
|
391
|
-
const
|
|
392
|
-
|
|
246
|
+
const maskClick = (event) => {
|
|
247
|
+
if (loop != 0) {
|
|
248
|
+
showMaskRef.value = false;
|
|
249
|
+
}
|
|
393
250
|
event.stopPropagation();
|
|
251
|
+
event.preventDefault();
|
|
394
252
|
};
|
|
395
253
|
return {
|
|
396
254
|
delShellClick,
|
|
397
255
|
editShellClick,
|
|
398
256
|
itemShellClick,
|
|
399
|
-
|
|
257
|
+
holddownstart,
|
|
258
|
+
holddownmove,
|
|
259
|
+
holddownend,
|
|
260
|
+
showMaskRef,
|
|
261
|
+
delClick,
|
|
262
|
+
copyCLick,
|
|
263
|
+
hideMaskClick,
|
|
264
|
+
setDefault,
|
|
265
|
+
maskClick
|
|
400
266
|
};
|
|
401
267
|
}
|
|
402
268
|
});
|
|
403
|
-
const _hoisted_1
|
|
269
|
+
const _hoisted_1 = { class: "nut-addresslist-general" };
|
|
270
|
+
const _hoisted_2 = /* @__PURE__ */ createElementVNode("div", { class: "nut-addresslist-mask-contain" }, [
|
|
271
|
+
/* @__PURE__ */ createTextVNode(" \u590D\u5236"),
|
|
272
|
+
/* @__PURE__ */ createElementVNode("br"),
|
|
273
|
+
/* @__PURE__ */ createTextVNode("\u5730\u5740 ")
|
|
274
|
+
], -1);
|
|
275
|
+
const _hoisted_3 = [
|
|
276
|
+
_hoisted_2
|
|
277
|
+
];
|
|
278
|
+
const _hoisted_4 = /* @__PURE__ */ createElementVNode("div", { class: "nut-addresslist-mask-contain" }, [
|
|
279
|
+
/* @__PURE__ */ createTextVNode(" \u8BBE\u7F6E"),
|
|
280
|
+
/* @__PURE__ */ createElementVNode("br"),
|
|
281
|
+
/* @__PURE__ */ createTextVNode("\u9ED8\u8BA4 ")
|
|
282
|
+
], -1);
|
|
283
|
+
const _hoisted_5 = [
|
|
284
|
+
_hoisted_4
|
|
285
|
+
];
|
|
286
|
+
const _hoisted_6 = /* @__PURE__ */ createElementVNode("div", { class: "nut-addresslist-mask-contain" }, [
|
|
287
|
+
/* @__PURE__ */ createTextVNode(" \u5220\u9664"),
|
|
288
|
+
/* @__PURE__ */ createElementVNode("br"),
|
|
289
|
+
/* @__PURE__ */ createTextVNode("\u5730\u5740 ")
|
|
290
|
+
], -1);
|
|
291
|
+
const _hoisted_7 = [
|
|
292
|
+
_hoisted_6
|
|
293
|
+
];
|
|
404
294
|
function _sfc_render$1(_ctx, _cache, $props, $setup, $data, $options) {
|
|
405
295
|
const _component_item_contents = resolveComponent("item-contents");
|
|
406
|
-
return openBlock(), createElementBlock("div", _hoisted_1
|
|
296
|
+
return openBlock(), createElementBlock("div", _hoisted_1, [
|
|
407
297
|
createVNode(_component_item_contents, {
|
|
408
298
|
item: _ctx.item,
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
onItemClick: _ctx.itemShellClick
|
|
299
|
+
onDelIcon: _ctx.delShellClick,
|
|
300
|
+
onEditIcon: _ctx.editShellClick,
|
|
301
|
+
onItemClick: _ctx.itemShellClick,
|
|
302
|
+
onTouchstart: _ctx.holddownstart,
|
|
303
|
+
onTouchend: _ctx.holddownend,
|
|
304
|
+
onTouchmove: _ctx.holddownmove
|
|
412
305
|
}, {
|
|
413
306
|
contentTop: withCtx(() => [
|
|
414
307
|
renderSlot(_ctx.$slots, "contentInfo")
|
|
@@ -420,7 +313,32 @@ function _sfc_render$1(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
420
313
|
renderSlot(_ctx.$slots, "contentAddrs")
|
|
421
314
|
]),
|
|
422
315
|
_: 3
|
|
423
|
-
}, 8, ["item", "
|
|
316
|
+
}, 8, ["item", "onDelIcon", "onEditIcon", "onItemClick", "onTouchstart", "onTouchend", "onTouchmove"]),
|
|
317
|
+
_ctx.longPress && _ctx.showMaskRef ? (openBlock(), createElementBlock("div", {
|
|
318
|
+
key: 0,
|
|
319
|
+
class: "nut-addresslist-general__mask",
|
|
320
|
+
onClick: _cache[3] || (_cache[3] = (...args) => _ctx.maskClick && _ctx.maskClick(...args))
|
|
321
|
+
}, [
|
|
322
|
+
renderSlot(_ctx.$slots, "longpressAll", {}, () => [
|
|
323
|
+
createElementVNode("div", {
|
|
324
|
+
class: "nut-addresslist-general__mask-copy",
|
|
325
|
+
onClick: _cache[0] || (_cache[0] = (...args) => _ctx.copyCLick && _ctx.copyCLick(...args))
|
|
326
|
+
}, _hoisted_3),
|
|
327
|
+
createElementVNode("div", {
|
|
328
|
+
class: "nut-addresslist-general__mask-set",
|
|
329
|
+
onClick: _cache[1] || (_cache[1] = (...args) => _ctx.setDefault && _ctx.setDefault(...args))
|
|
330
|
+
}, _hoisted_5),
|
|
331
|
+
createElementVNode("div", {
|
|
332
|
+
class: "nut-addresslist-general__mask-del",
|
|
333
|
+
onClick: _cache[2] || (_cache[2] = (...args) => _ctx.delClick && _ctx.delClick(...args))
|
|
334
|
+
}, _hoisted_7)
|
|
335
|
+
])
|
|
336
|
+
])) : createCommentVNode("", true),
|
|
337
|
+
_ctx.showMaskRef ? (openBlock(), createElementBlock("div", {
|
|
338
|
+
key: 1,
|
|
339
|
+
class: "nut-addresslist__mask-bottom",
|
|
340
|
+
onClick: _cache[4] || (_cache[4] = (...args) => _ctx.hideMaskClick && _ctx.hideMaskClick(...args))
|
|
341
|
+
})) : createCommentVNode("", true)
|
|
424
342
|
]);
|
|
425
343
|
}
|
|
426
344
|
var GeneralShell = /* @__PURE__ */ _export_sfc(_sfc_main$1, [["render", _sfc_render$1]]);
|
|
@@ -431,7 +349,7 @@ const _sfc_main = create({
|
|
|
431
349
|
type: Array,
|
|
432
350
|
default: []
|
|
433
351
|
},
|
|
434
|
-
|
|
352
|
+
longPress: {
|
|
435
353
|
type: Boolean,
|
|
436
354
|
default: false
|
|
437
355
|
},
|
|
@@ -449,20 +367,10 @@ const _sfc_main = create({
|
|
|
449
367
|
}
|
|
450
368
|
},
|
|
451
369
|
components: {
|
|
452
|
-
LongPressShell,
|
|
453
370
|
SwipeShell,
|
|
454
371
|
GeneralShell
|
|
455
372
|
},
|
|
456
|
-
emits: [
|
|
457
|
-
"handelDelIcon",
|
|
458
|
-
"handelEditIcon",
|
|
459
|
-
"handelItem",
|
|
460
|
-
"longPressCopyClick",
|
|
461
|
-
"longPressSetClick",
|
|
462
|
-
"longPressDelClick",
|
|
463
|
-
"swipeDelClick",
|
|
464
|
-
"addAddressClick"
|
|
465
|
-
],
|
|
373
|
+
emits: ["delIcon", "editIcon", "itemClick", "longCopy", "longSet", "longDel", "swipeDel", "add"],
|
|
466
374
|
setup(props, { emit }) {
|
|
467
375
|
const dataArray = ref([]);
|
|
468
376
|
const dataInfo = reactive({
|
|
@@ -472,9 +380,15 @@ const _sfc_main = create({
|
|
|
472
380
|
defaultAddress: false,
|
|
473
381
|
fullAddress: "\u5317\u4EAC\u5E02\u901A\u5DDE\u533A\u6D4B\u8BD5\u6D4B\u8BD5\u6D4B\u8BD5\u6D4B\u8BD5\u6D4B\u8BD5\u6D4B\u8BD5\u6D4B\u8BD5\u6D4B\u8BD5\u6D4B\u8BD5"
|
|
474
382
|
});
|
|
383
|
+
const classes = computed(() => {
|
|
384
|
+
const prefixCls = componentName;
|
|
385
|
+
return {
|
|
386
|
+
[prefixCls]: true
|
|
387
|
+
};
|
|
388
|
+
});
|
|
475
389
|
const trowelData = () => {
|
|
476
390
|
if (Object.keys(props.dataMapOptions).length > 0) {
|
|
477
|
-
dataArray.value = props.data.map((item
|
|
391
|
+
dataArray.value = props.data.map((item) => {
|
|
478
392
|
return floatData(dataInfo, item, props.dataMapOptions);
|
|
479
393
|
});
|
|
480
394
|
}
|
|
@@ -485,41 +399,42 @@ const _sfc_main = create({
|
|
|
485
399
|
{ deep: true }
|
|
486
400
|
);
|
|
487
401
|
const clickDelIcon = (event, item) => {
|
|
488
|
-
emit("
|
|
402
|
+
emit("delIcon", event, item);
|
|
489
403
|
event.stopPropagation();
|
|
490
404
|
};
|
|
491
405
|
const clickEditIcon = (event, item) => {
|
|
492
|
-
emit("
|
|
406
|
+
emit("editIcon", event, item);
|
|
493
407
|
event.stopPropagation();
|
|
494
408
|
};
|
|
495
409
|
const clickContentItem = (event, item) => {
|
|
496
|
-
emit("
|
|
410
|
+
emit("itemClick", event, item);
|
|
497
411
|
event.stopPropagation();
|
|
498
412
|
};
|
|
499
413
|
const clickLongCopy = (event, item) => {
|
|
500
|
-
emit("
|
|
414
|
+
emit("longCopy", event, item);
|
|
501
415
|
event.stopPropagation();
|
|
502
416
|
};
|
|
503
417
|
const clickLongSet = (event, item) => {
|
|
504
|
-
emit("
|
|
418
|
+
emit("longSet", event, item);
|
|
505
419
|
event.stopPropagation();
|
|
506
420
|
};
|
|
507
421
|
const clickLongDel = (event, item) => {
|
|
508
|
-
emit("
|
|
422
|
+
emit("longDel", event, item);
|
|
509
423
|
event.stopPropagation();
|
|
510
424
|
};
|
|
511
425
|
const clickSwipeDel = (event, item) => {
|
|
512
|
-
emit("
|
|
426
|
+
emit("swipeDel", event, item);
|
|
513
427
|
event.stopPropagation();
|
|
514
428
|
};
|
|
515
429
|
const addAddress = (event) => {
|
|
516
|
-
emit("
|
|
430
|
+
emit("add", event);
|
|
517
431
|
event.stopPropagation();
|
|
518
432
|
};
|
|
519
433
|
onMounted(() => {
|
|
520
434
|
trowelData();
|
|
521
435
|
});
|
|
522
436
|
return {
|
|
437
|
+
classes,
|
|
523
438
|
clickDelIcon,
|
|
524
439
|
clickEditIcon,
|
|
525
440
|
clickContentItem,
|
|
@@ -533,57 +448,64 @@ const _sfc_main = create({
|
|
|
533
448
|
};
|
|
534
449
|
}
|
|
535
450
|
});
|
|
536
|
-
const _hoisted_1 = { class: "nut-addresslist" };
|
|
537
451
|
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
538
452
|
const _component_general_shell = resolveComponent("general-shell");
|
|
539
|
-
const _component_long_press_shell = resolveComponent("long-press-shell");
|
|
540
453
|
const _component_swipe_shell = resolveComponent("swipe-shell");
|
|
541
454
|
const _component_nut_button = resolveComponent("nut-button");
|
|
542
|
-
return openBlock(), createElementBlock("div",
|
|
543
|
-
|
|
455
|
+
return openBlock(), createElementBlock("div", {
|
|
456
|
+
class: normalizeClass(_ctx.classes)
|
|
457
|
+
}, [
|
|
458
|
+
!_ctx.swipeEdition ? (openBlock(true), createElementBlock(Fragment, { key: 0 }, renderList(_ctx.dataArray, (item, index2) => {
|
|
544
459
|
return openBlock(), createBlock(_component_general_shell, {
|
|
545
|
-
key:
|
|
460
|
+
key: index2,
|
|
546
461
|
item,
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
|
|
561
|
-
|
|
562
|
-
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
462
|
+
longPress: _ctx.longPress,
|
|
463
|
+
onDelIcon: _ctx.clickDelIcon,
|
|
464
|
+
onEditIcon: _ctx.clickEditIcon,
|
|
465
|
+
onItemClick: _ctx.clickContentItem,
|
|
466
|
+
onSwipeDel: _ctx.clickSwipeDel,
|
|
467
|
+
onLongCopy: _ctx.clickLongCopy,
|
|
468
|
+
onLongSet: _ctx.clickLongSet,
|
|
469
|
+
onLongDel: _ctx.clickLongDel
|
|
470
|
+
}, createSlots({ _: 2 }, [
|
|
471
|
+
_ctx.longPress ? {
|
|
472
|
+
name: "contentInfo",
|
|
473
|
+
fn: withCtx(() => [
|
|
474
|
+
renderSlot(_ctx.$slots, "iteminfos")
|
|
475
|
+
]),
|
|
476
|
+
key: "0"
|
|
477
|
+
} : void 0,
|
|
478
|
+
_ctx.longPress ? {
|
|
479
|
+
name: "contentIcons",
|
|
480
|
+
fn: withCtx(() => [
|
|
481
|
+
renderSlot(_ctx.$slots, "itemicon")
|
|
482
|
+
]),
|
|
483
|
+
key: "1"
|
|
484
|
+
} : void 0,
|
|
485
|
+
_ctx.longPress ? {
|
|
486
|
+
name: "contentAddrs",
|
|
487
|
+
fn: withCtx(() => [
|
|
488
|
+
renderSlot(_ctx.$slots, "itemaddr")
|
|
489
|
+
]),
|
|
490
|
+
key: "2"
|
|
491
|
+
} : void 0,
|
|
492
|
+
_ctx.longPress ? {
|
|
493
|
+
name: "longpressAll",
|
|
494
|
+
fn: withCtx(() => [
|
|
495
|
+
renderSlot(_ctx.$slots, "longpressbtns")
|
|
496
|
+
]),
|
|
497
|
+
key: "3"
|
|
498
|
+
} : void 0
|
|
499
|
+
]), 1032, ["item", "longPress", "onDelIcon", "onEditIcon", "onItemClick", "onSwipeDel", "onLongCopy", "onLongSet", "onLongDel"]);
|
|
578
500
|
}), 128)) : createCommentVNode("", true),
|
|
579
|
-
|
|
501
|
+
_ctx.swipeEdition ? (openBlock(true), createElementBlock(Fragment, { key: 1 }, renderList(_ctx.dataArray, (item, index2) => {
|
|
580
502
|
return openBlock(), createBlock(_component_swipe_shell, {
|
|
581
|
-
key:
|
|
503
|
+
key: index2,
|
|
582
504
|
item,
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
|
|
505
|
+
onDelIcon: _ctx.clickDelIcon,
|
|
506
|
+
onEditIcon: _ctx.clickEditIcon,
|
|
507
|
+
onItemClick: _ctx.clickContentItem,
|
|
508
|
+
onSwipeDel: _ctx.clickSwipeDel
|
|
587
509
|
}, {
|
|
588
510
|
contentInfo: withCtx(() => [
|
|
589
511
|
renderSlot(_ctx.$slots, "iteminfos")
|
|
@@ -598,10 +520,10 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
598
520
|
renderSlot(_ctx.$slots, "swiperight")
|
|
599
521
|
]),
|
|
600
522
|
_: 2
|
|
601
|
-
}, 1032, ["item", "
|
|
523
|
+
}, 1032, ["item", "onDelIcon", "onEditIcon", "onItemClick", "onSwipeDel"]);
|
|
602
524
|
}), 128)) : createCommentVNode("", true),
|
|
603
525
|
_ctx.showBottomButton ? (openBlock(), createElementBlock("div", {
|
|
604
|
-
key:
|
|
526
|
+
key: 2,
|
|
605
527
|
class: "nut-addresslist__bottom",
|
|
606
528
|
onClick: _cache[0] || (_cache[0] = (...args) => _ctx.addAddress && _ctx.addAddress(...args))
|
|
607
529
|
}, [
|
|
@@ -615,7 +537,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
615
537
|
_: 1
|
|
616
538
|
})
|
|
617
539
|
])) : createCommentVNode("", true)
|
|
618
|
-
]);
|
|
540
|
+
], 2);
|
|
619
541
|
}
|
|
620
542
|
var index = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render]]);
|
|
621
543
|
export { index as default };
|