zartui 3.1.90 → 3.1.92
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/es/drawer-select/DrawerSelect.mjs +48 -3
- package/es/drawer-select/index.css +1 -1
- package/es/field/Field.mjs +4 -2
- package/es/index.d.ts +1 -1
- package/es/index.mjs +1 -1
- package/lib/drawer-select/DrawerSelect.js +47 -2
- package/lib/drawer-select/index.css +1 -1
- package/lib/field/Field.js +4 -2
- package/lib/index.css +1 -1
- package/lib/index.d.ts +1 -1
- package/lib/index.js +1 -1
- package/lib/web-types.json +1 -1
- package/lib/zartui.cjs.js +52 -5
- package/lib/zartui.es.js +52 -5
- package/lib/zartui.js +52 -5
- package/lib/zartui.min.js +2 -2
- package/package.json +4 -4
package/lib/zartui.cjs.js
CHANGED
|
@@ -8476,7 +8476,8 @@ var stdin_default$1b = vue.defineComponent({
|
|
|
8476
8476
|
};
|
|
8477
8477
|
const onClickInput = (event) => emit("clickInput", event);
|
|
8478
8478
|
const onClickLeftIcon = (event) => emit("clickLeftIcon", event);
|
|
8479
|
-
const changePasswordView = () => {
|
|
8479
|
+
const changePasswordView = (event) => {
|
|
8480
|
+
preventDefault(event, true);
|
|
8480
8481
|
state.showPassword = !state.showPassword;
|
|
8481
8482
|
};
|
|
8482
8483
|
const onClickRightIcon = (event) => emit("clickRightIcon", event);
|
|
@@ -8560,7 +8561,8 @@ var stdin_default$1b = vue.defineComponent({
|
|
|
8560
8561
|
"type": state.showPassword ? "text" : "password"
|
|
8561
8562
|
}, inputAttrs), null), vue.createVNode(Icon, {
|
|
8562
8563
|
"name": state.showPassword ? "eye" : "eye-closed",
|
|
8563
|
-
"onClick": changePasswordView
|
|
8564
|
+
"onClick": changePasswordView,
|
|
8565
|
+
"onTouchstart": changePasswordView
|
|
8564
8566
|
}, null)]);
|
|
8565
8567
|
}
|
|
8566
8568
|
return vue.createVNode("input", vue.mergeProps(mapInputType(props.type), inputAttrs), null);
|
|
@@ -9078,6 +9080,10 @@ var stdin_default$15 = vue.defineComponent({
|
|
|
9078
9080
|
const historyList = vue.ref([]);
|
|
9079
9081
|
const showAllCommonTypes = vue.ref(false);
|
|
9080
9082
|
const selectCommonId = vue.ref(-1);
|
|
9083
|
+
const commonTypesListRef = vue.ref();
|
|
9084
|
+
const showLeftCommonTypesMask = vue.ref(false);
|
|
9085
|
+
const showRightCommonTypesMask = vue.ref(false);
|
|
9086
|
+
let commonTypesResizeObserver;
|
|
9081
9087
|
const defaultTreeNode = vue.ref(props.treeData);
|
|
9082
9088
|
const fields = vue.computed(() => assignDefaultFields$1(props.treeFieldName));
|
|
9083
9089
|
const visibleCommonTypeList = vue.computed(() => {
|
|
@@ -9092,6 +9098,35 @@ var stdin_default$15 = vue.defineComponent({
|
|
|
9092
9098
|
children,
|
|
9093
9099
|
text: key
|
|
9094
9100
|
} = fields.value;
|
|
9101
|
+
const updateCommonTypesMask = () => {
|
|
9102
|
+
const list = commonTypesListRef.value;
|
|
9103
|
+
if (!list) {
|
|
9104
|
+
showLeftCommonTypesMask.value = false;
|
|
9105
|
+
showRightCommonTypesMask.value = false;
|
|
9106
|
+
return;
|
|
9107
|
+
}
|
|
9108
|
+
const remainingScrollWidth = list.scrollWidth - list.clientWidth - list.scrollLeft;
|
|
9109
|
+
showLeftCommonTypesMask.value = list.scrollLeft > 0;
|
|
9110
|
+
showRightCommonTypesMask.value = remainingScrollWidth > 1;
|
|
9111
|
+
};
|
|
9112
|
+
const onCommonTypesScroll = () => {
|
|
9113
|
+
updateCommonTypesMask();
|
|
9114
|
+
};
|
|
9115
|
+
const observeCommonTypesList = () => {
|
|
9116
|
+
commonTypesResizeObserver == null ? void 0 : commonTypesResizeObserver.disconnect();
|
|
9117
|
+
const list = commonTypesListRef.value;
|
|
9118
|
+
if (!list || typeof ResizeObserver === "undefined") {
|
|
9119
|
+
return;
|
|
9120
|
+
}
|
|
9121
|
+
commonTypesResizeObserver = new ResizeObserver(updateCommonTypesMask);
|
|
9122
|
+
commonTypesResizeObserver.observe(list);
|
|
9123
|
+
};
|
|
9124
|
+
const updateCommonTypesLayout = () => {
|
|
9125
|
+
vue.nextTick(() => {
|
|
9126
|
+
observeCommonTypesList();
|
|
9127
|
+
updateCommonTypesMask();
|
|
9128
|
+
});
|
|
9129
|
+
};
|
|
9095
9130
|
const allData = {
|
|
9096
9131
|
[value]: -1,
|
|
9097
9132
|
[key]: "全部",
|
|
@@ -9168,6 +9203,13 @@ var stdin_default$15 = vue.defineComponent({
|
|
|
9168
9203
|
};
|
|
9169
9204
|
flatData(props.treeData);
|
|
9170
9205
|
updateOffset();
|
|
9206
|
+
updateCommonTypesLayout();
|
|
9207
|
+
});
|
|
9208
|
+
vue.watch(visibleCommonTypeList, updateCommonTypesLayout, {
|
|
9209
|
+
flush: "post"
|
|
9210
|
+
});
|
|
9211
|
+
vue.onBeforeUnmount(() => {
|
|
9212
|
+
commonTypesResizeObserver == null ? void 0 : commonTypesResizeObserver.disconnect();
|
|
9171
9213
|
});
|
|
9172
9214
|
const isEmpty = (item) => !item[children] || item[children].length === 0;
|
|
9173
9215
|
const syncExpandNodeByParent = (item) => {
|
|
@@ -9355,11 +9397,16 @@ var stdin_default$15 = vue.defineComponent({
|
|
|
9355
9397
|
}, [vue.createVNode("span", {
|
|
9356
9398
|
"class": [bem$M("common-types--label")]
|
|
9357
9399
|
}, [vue.createTextVNode("常用小类")]), visibleCommonTypeList.value.length > 0 ? vue.createVNode("div", {
|
|
9358
|
-
"class": [bem$M("common-types--mask")
|
|
9400
|
+
"class": [bem$M("common-types--mask"), bem$M("common-types--mask", {
|
|
9401
|
+
"left-mask": showLeftCommonTypesMask.value,
|
|
9402
|
+
"right-mask": showRightCommonTypesMask.value
|
|
9403
|
+
})]
|
|
9359
9404
|
}, [vue.createVNode("div", {
|
|
9360
9405
|
"class": [bem$M("common-types--viewport")]
|
|
9361
9406
|
}, [vue.createVNode("div", {
|
|
9362
|
-
"
|
|
9407
|
+
"ref": commonTypesListRef,
|
|
9408
|
+
"class": [bem$M("common-types--list")],
|
|
9409
|
+
"onScroll": onCommonTypesScroll
|
|
9363
9410
|
}, [visibleCommonTypeList.value.map(renderCommonTypeButton)])])]) : vue.createVNode("div", {
|
|
9364
9411
|
"class": [bem$M("common-types--empty")]
|
|
9365
9412
|
}, [vue.createTextVNode("暂无常用小类")]), visibleCommonTypeList.value.length > 0 && vue.createVNode("div", {
|
|
@@ -24377,7 +24424,7 @@ const Lazyload = {
|
|
|
24377
24424
|
});
|
|
24378
24425
|
}
|
|
24379
24426
|
};
|
|
24380
|
-
const version = "3.1.
|
|
24427
|
+
const version = "3.1.92";
|
|
24381
24428
|
function install(app) {
|
|
24382
24429
|
const components = [
|
|
24383
24430
|
ActionSheet,
|
package/lib/zartui.es.js
CHANGED
|
@@ -8474,7 +8474,8 @@ var stdin_default$1b = defineComponent({
|
|
|
8474
8474
|
};
|
|
8475
8475
|
const onClickInput = (event) => emit("clickInput", event);
|
|
8476
8476
|
const onClickLeftIcon = (event) => emit("clickLeftIcon", event);
|
|
8477
|
-
const changePasswordView = () => {
|
|
8477
|
+
const changePasswordView = (event) => {
|
|
8478
|
+
preventDefault(event, true);
|
|
8478
8479
|
state.showPassword = !state.showPassword;
|
|
8479
8480
|
};
|
|
8480
8481
|
const onClickRightIcon = (event) => emit("clickRightIcon", event);
|
|
@@ -8558,7 +8559,8 @@ var stdin_default$1b = defineComponent({
|
|
|
8558
8559
|
"type": state.showPassword ? "text" : "password"
|
|
8559
8560
|
}, inputAttrs), null), createVNode(Icon, {
|
|
8560
8561
|
"name": state.showPassword ? "eye" : "eye-closed",
|
|
8561
|
-
"onClick": changePasswordView
|
|
8562
|
+
"onClick": changePasswordView,
|
|
8563
|
+
"onTouchstart": changePasswordView
|
|
8562
8564
|
}, null)]);
|
|
8563
8565
|
}
|
|
8564
8566
|
return createVNode("input", mergeProps(mapInputType(props.type), inputAttrs), null);
|
|
@@ -9076,6 +9078,10 @@ var stdin_default$15 = defineComponent({
|
|
|
9076
9078
|
const historyList = ref([]);
|
|
9077
9079
|
const showAllCommonTypes = ref(false);
|
|
9078
9080
|
const selectCommonId = ref(-1);
|
|
9081
|
+
const commonTypesListRef = ref();
|
|
9082
|
+
const showLeftCommonTypesMask = ref(false);
|
|
9083
|
+
const showRightCommonTypesMask = ref(false);
|
|
9084
|
+
let commonTypesResizeObserver;
|
|
9079
9085
|
const defaultTreeNode = ref(props.treeData);
|
|
9080
9086
|
const fields = computed(() => assignDefaultFields$1(props.treeFieldName));
|
|
9081
9087
|
const visibleCommonTypeList = computed(() => {
|
|
@@ -9090,6 +9096,35 @@ var stdin_default$15 = defineComponent({
|
|
|
9090
9096
|
children,
|
|
9091
9097
|
text: key
|
|
9092
9098
|
} = fields.value;
|
|
9099
|
+
const updateCommonTypesMask = () => {
|
|
9100
|
+
const list = commonTypesListRef.value;
|
|
9101
|
+
if (!list) {
|
|
9102
|
+
showLeftCommonTypesMask.value = false;
|
|
9103
|
+
showRightCommonTypesMask.value = false;
|
|
9104
|
+
return;
|
|
9105
|
+
}
|
|
9106
|
+
const remainingScrollWidth = list.scrollWidth - list.clientWidth - list.scrollLeft;
|
|
9107
|
+
showLeftCommonTypesMask.value = list.scrollLeft > 0;
|
|
9108
|
+
showRightCommonTypesMask.value = remainingScrollWidth > 1;
|
|
9109
|
+
};
|
|
9110
|
+
const onCommonTypesScroll = () => {
|
|
9111
|
+
updateCommonTypesMask();
|
|
9112
|
+
};
|
|
9113
|
+
const observeCommonTypesList = () => {
|
|
9114
|
+
commonTypesResizeObserver == null ? void 0 : commonTypesResizeObserver.disconnect();
|
|
9115
|
+
const list = commonTypesListRef.value;
|
|
9116
|
+
if (!list || typeof ResizeObserver === "undefined") {
|
|
9117
|
+
return;
|
|
9118
|
+
}
|
|
9119
|
+
commonTypesResizeObserver = new ResizeObserver(updateCommonTypesMask);
|
|
9120
|
+
commonTypesResizeObserver.observe(list);
|
|
9121
|
+
};
|
|
9122
|
+
const updateCommonTypesLayout = () => {
|
|
9123
|
+
nextTick(() => {
|
|
9124
|
+
observeCommonTypesList();
|
|
9125
|
+
updateCommonTypesMask();
|
|
9126
|
+
});
|
|
9127
|
+
};
|
|
9093
9128
|
const allData = {
|
|
9094
9129
|
[value]: -1,
|
|
9095
9130
|
[key]: "全部",
|
|
@@ -9166,6 +9201,13 @@ var stdin_default$15 = defineComponent({
|
|
|
9166
9201
|
};
|
|
9167
9202
|
flatData(props.treeData);
|
|
9168
9203
|
updateOffset();
|
|
9204
|
+
updateCommonTypesLayout();
|
|
9205
|
+
});
|
|
9206
|
+
watch(visibleCommonTypeList, updateCommonTypesLayout, {
|
|
9207
|
+
flush: "post"
|
|
9208
|
+
});
|
|
9209
|
+
onBeforeUnmount(() => {
|
|
9210
|
+
commonTypesResizeObserver == null ? void 0 : commonTypesResizeObserver.disconnect();
|
|
9169
9211
|
});
|
|
9170
9212
|
const isEmpty = (item) => !item[children] || item[children].length === 0;
|
|
9171
9213
|
const syncExpandNodeByParent = (item) => {
|
|
@@ -9353,11 +9395,16 @@ var stdin_default$15 = defineComponent({
|
|
|
9353
9395
|
}, [createVNode("span", {
|
|
9354
9396
|
"class": [bem$M("common-types--label")]
|
|
9355
9397
|
}, [createTextVNode("常用小类")]), visibleCommonTypeList.value.length > 0 ? createVNode("div", {
|
|
9356
|
-
"class": [bem$M("common-types--mask")
|
|
9398
|
+
"class": [bem$M("common-types--mask"), bem$M("common-types--mask", {
|
|
9399
|
+
"left-mask": showLeftCommonTypesMask.value,
|
|
9400
|
+
"right-mask": showRightCommonTypesMask.value
|
|
9401
|
+
})]
|
|
9357
9402
|
}, [createVNode("div", {
|
|
9358
9403
|
"class": [bem$M("common-types--viewport")]
|
|
9359
9404
|
}, [createVNode("div", {
|
|
9360
|
-
"
|
|
9405
|
+
"ref": commonTypesListRef,
|
|
9406
|
+
"class": [bem$M("common-types--list")],
|
|
9407
|
+
"onScroll": onCommonTypesScroll
|
|
9361
9408
|
}, [visibleCommonTypeList.value.map(renderCommonTypeButton)])])]) : createVNode("div", {
|
|
9362
9409
|
"class": [bem$M("common-types--empty")]
|
|
9363
9410
|
}, [createTextVNode("暂无常用小类")]), visibleCommonTypeList.value.length > 0 && createVNode("div", {
|
|
@@ -24375,7 +24422,7 @@ const Lazyload = {
|
|
|
24375
24422
|
});
|
|
24376
24423
|
}
|
|
24377
24424
|
};
|
|
24378
|
-
const version = "3.1.
|
|
24425
|
+
const version = "3.1.92";
|
|
24379
24426
|
function install(app) {
|
|
24380
24427
|
const components = [
|
|
24381
24428
|
ActionSheet,
|
package/lib/zartui.js
CHANGED
|
@@ -8725,7 +8725,8 @@ var __publicField = (obj, key, value) => {
|
|
|
8725
8725
|
};
|
|
8726
8726
|
const onClickInput = (event) => emit("clickInput", event);
|
|
8727
8727
|
const onClickLeftIcon = (event) => emit("clickLeftIcon", event);
|
|
8728
|
-
const changePasswordView = () => {
|
|
8728
|
+
const changePasswordView = (event) => {
|
|
8729
|
+
preventDefault(event, true);
|
|
8729
8730
|
state.showPassword = !state.showPassword;
|
|
8730
8731
|
};
|
|
8731
8732
|
const onClickRightIcon = (event) => emit("clickRightIcon", event);
|
|
@@ -8809,7 +8810,8 @@ var __publicField = (obj, key, value) => {
|
|
|
8809
8810
|
"type": state.showPassword ? "text" : "password"
|
|
8810
8811
|
}, inputAttrs), null), vue.createVNode(Icon, {
|
|
8811
8812
|
"name": state.showPassword ? "eye" : "eye-closed",
|
|
8812
|
-
"onClick": changePasswordView
|
|
8813
|
+
"onClick": changePasswordView,
|
|
8814
|
+
"onTouchstart": changePasswordView
|
|
8813
8815
|
}, null)]);
|
|
8814
8816
|
}
|
|
8815
8817
|
return vue.createVNode("input", vue.mergeProps(mapInputType(props.type), inputAttrs), null);
|
|
@@ -9327,6 +9329,10 @@ var __publicField = (obj, key, value) => {
|
|
|
9327
9329
|
const historyList = vue.ref([]);
|
|
9328
9330
|
const showAllCommonTypes = vue.ref(false);
|
|
9329
9331
|
const selectCommonId = vue.ref(-1);
|
|
9332
|
+
const commonTypesListRef = vue.ref();
|
|
9333
|
+
const showLeftCommonTypesMask = vue.ref(false);
|
|
9334
|
+
const showRightCommonTypesMask = vue.ref(false);
|
|
9335
|
+
let commonTypesResizeObserver;
|
|
9330
9336
|
const defaultTreeNode = vue.ref(props.treeData);
|
|
9331
9337
|
const fields = vue.computed(() => assignDefaultFields$1(props.treeFieldName));
|
|
9332
9338
|
const visibleCommonTypeList = vue.computed(() => {
|
|
@@ -9341,6 +9347,35 @@ var __publicField = (obj, key, value) => {
|
|
|
9341
9347
|
children,
|
|
9342
9348
|
text: key
|
|
9343
9349
|
} = fields.value;
|
|
9350
|
+
const updateCommonTypesMask = () => {
|
|
9351
|
+
const list = commonTypesListRef.value;
|
|
9352
|
+
if (!list) {
|
|
9353
|
+
showLeftCommonTypesMask.value = false;
|
|
9354
|
+
showRightCommonTypesMask.value = false;
|
|
9355
|
+
return;
|
|
9356
|
+
}
|
|
9357
|
+
const remainingScrollWidth = list.scrollWidth - list.clientWidth - list.scrollLeft;
|
|
9358
|
+
showLeftCommonTypesMask.value = list.scrollLeft > 0;
|
|
9359
|
+
showRightCommonTypesMask.value = remainingScrollWidth > 1;
|
|
9360
|
+
};
|
|
9361
|
+
const onCommonTypesScroll = () => {
|
|
9362
|
+
updateCommonTypesMask();
|
|
9363
|
+
};
|
|
9364
|
+
const observeCommonTypesList = () => {
|
|
9365
|
+
commonTypesResizeObserver == null ? void 0 : commonTypesResizeObserver.disconnect();
|
|
9366
|
+
const list = commonTypesListRef.value;
|
|
9367
|
+
if (!list || typeof ResizeObserver === "undefined") {
|
|
9368
|
+
return;
|
|
9369
|
+
}
|
|
9370
|
+
commonTypesResizeObserver = new ResizeObserver(updateCommonTypesMask);
|
|
9371
|
+
commonTypesResizeObserver.observe(list);
|
|
9372
|
+
};
|
|
9373
|
+
const updateCommonTypesLayout = () => {
|
|
9374
|
+
vue.nextTick(() => {
|
|
9375
|
+
observeCommonTypesList();
|
|
9376
|
+
updateCommonTypesMask();
|
|
9377
|
+
});
|
|
9378
|
+
};
|
|
9344
9379
|
const allData = {
|
|
9345
9380
|
[value]: -1,
|
|
9346
9381
|
[key]: "全部",
|
|
@@ -9417,6 +9452,13 @@ var __publicField = (obj, key, value) => {
|
|
|
9417
9452
|
};
|
|
9418
9453
|
flatData(props.treeData);
|
|
9419
9454
|
updateOffset();
|
|
9455
|
+
updateCommonTypesLayout();
|
|
9456
|
+
});
|
|
9457
|
+
vue.watch(visibleCommonTypeList, updateCommonTypesLayout, {
|
|
9458
|
+
flush: "post"
|
|
9459
|
+
});
|
|
9460
|
+
vue.onBeforeUnmount(() => {
|
|
9461
|
+
commonTypesResizeObserver == null ? void 0 : commonTypesResizeObserver.disconnect();
|
|
9420
9462
|
});
|
|
9421
9463
|
const isEmpty = (item) => !item[children] || item[children].length === 0;
|
|
9422
9464
|
const syncExpandNodeByParent = (item) => {
|
|
@@ -9604,11 +9646,16 @@ var __publicField = (obj, key, value) => {
|
|
|
9604
9646
|
}, [vue.createVNode("span", {
|
|
9605
9647
|
"class": [bem$M("common-types--label")]
|
|
9606
9648
|
}, [vue.createTextVNode("常用小类")]), visibleCommonTypeList.value.length > 0 ? vue.createVNode("div", {
|
|
9607
|
-
"class": [bem$M("common-types--mask")
|
|
9649
|
+
"class": [bem$M("common-types--mask"), bem$M("common-types--mask", {
|
|
9650
|
+
"left-mask": showLeftCommonTypesMask.value,
|
|
9651
|
+
"right-mask": showRightCommonTypesMask.value
|
|
9652
|
+
})]
|
|
9608
9653
|
}, [vue.createVNode("div", {
|
|
9609
9654
|
"class": [bem$M("common-types--viewport")]
|
|
9610
9655
|
}, [vue.createVNode("div", {
|
|
9611
|
-
"
|
|
9656
|
+
"ref": commonTypesListRef,
|
|
9657
|
+
"class": [bem$M("common-types--list")],
|
|
9658
|
+
"onScroll": onCommonTypesScroll
|
|
9612
9659
|
}, [visibleCommonTypeList.value.map(renderCommonTypeButton)])])]) : vue.createVNode("div", {
|
|
9613
9660
|
"class": [bem$M("common-types--empty")]
|
|
9614
9661
|
}, [vue.createTextVNode("暂无常用小类")]), visibleCommonTypeList.value.length > 0 && vue.createVNode("div", {
|
|
@@ -31890,7 +31937,7 @@ var __publicField = (obj, key, value) => {
|
|
|
31890
31937
|
});
|
|
31891
31938
|
}
|
|
31892
31939
|
};
|
|
31893
|
-
const version = "3.1.
|
|
31940
|
+
const version = "3.1.92";
|
|
31894
31941
|
function install(app) {
|
|
31895
31942
|
const components = [
|
|
31896
31943
|
ActionSheet,
|