vant 4.9.8 → 4.9.9
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/README.md +1 -0
- package/es/calendar/CalendarHeader.mjs +1 -1
- package/es/calendar/index.css +1 -1
- package/es/dialog/Dialog.d.ts +13 -0
- package/es/dialog/Dialog.mjs +5 -1
- package/es/dialog/index.d.ts +9 -0
- package/es/field/Field.d.ts +5 -1
- package/es/field/Field.mjs +6 -3
- package/es/field/index.d.ts +2 -0
- package/es/field/utils.d.ts +1 -1
- package/es/field/utils.mjs +6 -10
- package/es/index.d.ts +1 -1
- package/es/index.mjs +1 -1
- package/es/search/Search.d.ts +3 -0
- package/es/search/index.d.ts +2 -0
- package/lib/calendar/CalendarHeader.js +1 -1
- package/lib/calendar/index.css +1 -1
- package/lib/dialog/Dialog.d.ts +13 -0
- package/lib/dialog/Dialog.js +5 -1
- package/lib/dialog/index.d.ts +9 -0
- package/lib/field/Field.d.ts +5 -1
- package/lib/field/Field.js +6 -3
- package/lib/field/index.d.ts +2 -0
- package/lib/field/utils.d.ts +1 -1
- package/lib/field/utils.js +6 -10
- package/lib/index.css +1 -1
- package/lib/index.d.ts +1 -1
- package/lib/index.js +1 -1
- package/lib/search/Search.d.ts +3 -0
- package/lib/search/index.d.ts +2 -0
- package/lib/vant.cjs.js +19 -16
- package/lib/vant.es.js +19 -16
- package/lib/vant.js +20 -17
- package/lib/vant.min.js +2 -2
- package/lib/web-types.json +1 -1
- package/package.json +14 -14
package/lib/index.d.ts
CHANGED
package/lib/index.js
CHANGED
@@ -226,7 +226,7 @@ __reExport(stdin_exports, require("./toast"), module.exports);
|
|
226
226
|
__reExport(stdin_exports, require("./tree-select"), module.exports);
|
227
227
|
__reExport(stdin_exports, require("./uploader"), module.exports);
|
228
228
|
__reExport(stdin_exports, require("./watermark"), module.exports);
|
229
|
-
const version = "4.9.
|
229
|
+
const version = "4.9.9";
|
230
230
|
function install(app) {
|
231
231
|
const components = [
|
232
232
|
import_action_bar.ActionBar,
|
package/lib/search/Search.d.ts
CHANGED
@@ -50,6 +50,7 @@ export declare const searchProps: {
|
|
50
50
|
type: BooleanConstructor;
|
51
51
|
default: null;
|
52
52
|
};
|
53
|
+
inputmode: import("vue").PropType<import("vue").HTMLAttributes["inputmode"]>;
|
53
54
|
} & {
|
54
55
|
label: StringConstructor;
|
55
56
|
shape: {
|
@@ -119,6 +120,7 @@ declare const _default: import("vue").DefineComponent<ExtractPropTypes<{
|
|
119
120
|
type: BooleanConstructor;
|
120
121
|
default: null;
|
121
122
|
};
|
123
|
+
inputmode: import("vue").PropType<import("vue").HTMLAttributes["inputmode"]>;
|
122
124
|
} & {
|
123
125
|
label: StringConstructor;
|
124
126
|
shape: {
|
@@ -186,6 +188,7 @@ declare const _default: import("vue").DefineComponent<ExtractPropTypes<{
|
|
186
188
|
type: BooleanConstructor;
|
187
189
|
default: null;
|
188
190
|
};
|
191
|
+
inputmode: import("vue").PropType<import("vue").HTMLAttributes["inputmode"]>;
|
189
192
|
} & {
|
190
193
|
label: StringConstructor;
|
191
194
|
shape: {
|
package/lib/search/index.d.ts
CHANGED
@@ -49,6 +49,7 @@ export declare const Search: import("../utils").WithInstall<import("vue").Define
|
|
49
49
|
type: BooleanConstructor;
|
50
50
|
default: null;
|
51
51
|
};
|
52
|
+
inputmode: import("vue").PropType<import("vue").HTMLAttributes["inputmode"]>;
|
52
53
|
} & {
|
53
54
|
label: StringConstructor;
|
54
55
|
shape: {
|
@@ -116,6 +117,7 @@ export declare const Search: import("../utils").WithInstall<import("vue").Define
|
|
116
117
|
type: BooleanConstructor;
|
117
118
|
default: null;
|
118
119
|
};
|
120
|
+
inputmode: import("vue").PropType<import("vue").HTMLAttributes["inputmode"]>;
|
119
121
|
} & {
|
120
122
|
label: StringConstructor;
|
121
123
|
shape: {
|
package/lib/vant.cjs.js
CHANGED
@@ -4047,20 +4047,16 @@ function resizeTextarea(input, autosize) {
|
|
4047
4047
|
setRootScrollTop(scrollTop);
|
4048
4048
|
}
|
4049
4049
|
}
|
4050
|
-
function mapInputType(type) {
|
4050
|
+
function mapInputType(type, inputmode) {
|
4051
4051
|
if (type === "number") {
|
4052
|
-
|
4053
|
-
|
4054
|
-
inputmode: "decimal"
|
4055
|
-
};
|
4052
|
+
type = "text";
|
4053
|
+
inputmode != null ? inputmode : inputmode = "decimal";
|
4056
4054
|
}
|
4057
4055
|
if (type === "digit") {
|
4058
|
-
|
4059
|
-
|
4060
|
-
inputmode: "numeric"
|
4061
|
-
};
|
4056
|
+
type = "tel";
|
4057
|
+
inputmode != null ? inputmode : inputmode = "numeric";
|
4062
4058
|
}
|
4063
|
-
return { type };
|
4059
|
+
return { type, inputmode };
|
4064
4060
|
}
|
4065
4061
|
function getStringLength(str) {
|
4066
4062
|
return [...str].length;
|
@@ -4106,7 +4102,8 @@ const fieldSharedProps = {
|
|
4106
4102
|
readonly: {
|
4107
4103
|
type: Boolean,
|
4108
4104
|
default: null
|
4109
|
-
}
|
4105
|
+
},
|
4106
|
+
inputmode: String
|
4110
4107
|
};
|
4111
4108
|
const fieldProps = extend({}, cellSharedProps, fieldSharedProps, {
|
4112
4109
|
rows: numericProp,
|
@@ -4449,9 +4446,11 @@ var stdin_default$1v = vue.defineComponent({
|
|
4449
4446
|
onCompositionstart: startComposing
|
4450
4447
|
};
|
4451
4448
|
if (props2.type === "textarea") {
|
4452
|
-
return vue.createVNode("textarea", inputAttrs,
|
4449
|
+
return vue.createVNode("textarea", vue.mergeProps(inputAttrs, {
|
4450
|
+
"inputmode": props2.inputmode
|
4451
|
+
}), null);
|
4453
4452
|
}
|
4454
|
-
return vue.createVNode("input", vue.mergeProps(mapInputType(props2.type), inputAttrs), null);
|
4453
|
+
return vue.createVNode("input", vue.mergeProps(mapInputType(props2.type, props2.inputmode), inputAttrs), null);
|
4455
4454
|
};
|
4456
4455
|
const renderLeftIcon = () => {
|
4457
4456
|
const leftIconSlot = slots["left-icon"];
|
@@ -6826,7 +6825,7 @@ var stdin_default$1e = vue.defineComponent({
|
|
6826
6825
|
const canSwitch = props2.switchMode !== "none";
|
6827
6826
|
return vue.createVNode("div", {
|
6828
6827
|
"class": bem$13("header-subtitle", {
|
6829
|
-
"with-
|
6828
|
+
"with-switch": canSwitch
|
6830
6829
|
}),
|
6831
6830
|
"onClick": onClickSubtitle
|
6832
6831
|
}, [canSwitch ? [renderAction(), vue.createVNode("div", {
|
@@ -9504,7 +9503,8 @@ const dialogProps = extend({}, popupSharedProps, {
|
|
9504
9503
|
confirmButtonColor: String,
|
9505
9504
|
confirmButtonDisabled: Boolean,
|
9506
9505
|
showConfirmButton: truthProp,
|
9507
|
-
closeOnClickOverlay: Boolean
|
9506
|
+
closeOnClickOverlay: Boolean,
|
9507
|
+
keyboardEnabled: truthProp
|
9508
9508
|
});
|
9509
9509
|
const popupInheritKeys$1 = [...popupSharedPropKeys, "transition", "closeOnPopstate"];
|
9510
9510
|
var stdin_default$W = vue.defineComponent({
|
@@ -9551,6 +9551,9 @@ var stdin_default$W = vue.defineComponent({
|
|
9551
9551
|
const onConfirm = getActionHandler("confirm");
|
9552
9552
|
const onKeydown = vue.withKeys((event) => {
|
9553
9553
|
var _a, _b;
|
9554
|
+
if (!props2.keyboardEnabled) {
|
9555
|
+
return;
|
9556
|
+
}
|
9554
9557
|
if (event.target !== ((_b = (_a = root.value) == null ? void 0 : _a.popupRef) == null ? void 0 : _b.value)) {
|
9555
9558
|
return;
|
9556
9559
|
}
|
@@ -17057,7 +17060,7 @@ const Lazyload = {
|
|
17057
17060
|
});
|
17058
17061
|
}
|
17059
17062
|
};
|
17060
|
-
const version = "4.9.
|
17063
|
+
const version = "4.9.9";
|
17061
17064
|
function install(app) {
|
17062
17065
|
const components = [
|
17063
17066
|
ActionBar,
|
package/lib/vant.es.js
CHANGED
@@ -4045,20 +4045,16 @@ function resizeTextarea(input, autosize) {
|
|
4045
4045
|
setRootScrollTop(scrollTop);
|
4046
4046
|
}
|
4047
4047
|
}
|
4048
|
-
function mapInputType(type) {
|
4048
|
+
function mapInputType(type, inputmode) {
|
4049
4049
|
if (type === "number") {
|
4050
|
-
|
4051
|
-
|
4052
|
-
inputmode: "decimal"
|
4053
|
-
};
|
4050
|
+
type = "text";
|
4051
|
+
inputmode != null ? inputmode : inputmode = "decimal";
|
4054
4052
|
}
|
4055
4053
|
if (type === "digit") {
|
4056
|
-
|
4057
|
-
|
4058
|
-
inputmode: "numeric"
|
4059
|
-
};
|
4054
|
+
type = "tel";
|
4055
|
+
inputmode != null ? inputmode : inputmode = "numeric";
|
4060
4056
|
}
|
4061
|
-
return { type };
|
4057
|
+
return { type, inputmode };
|
4062
4058
|
}
|
4063
4059
|
function getStringLength(str) {
|
4064
4060
|
return [...str].length;
|
@@ -4104,7 +4100,8 @@ const fieldSharedProps = {
|
|
4104
4100
|
readonly: {
|
4105
4101
|
type: Boolean,
|
4106
4102
|
default: null
|
4107
|
-
}
|
4103
|
+
},
|
4104
|
+
inputmode: String
|
4108
4105
|
};
|
4109
4106
|
const fieldProps = extend({}, cellSharedProps, fieldSharedProps, {
|
4110
4107
|
rows: numericProp,
|
@@ -4447,9 +4444,11 @@ var stdin_default$1v = defineComponent({
|
|
4447
4444
|
onCompositionstart: startComposing
|
4448
4445
|
};
|
4449
4446
|
if (props2.type === "textarea") {
|
4450
|
-
return createVNode("textarea", inputAttrs,
|
4447
|
+
return createVNode("textarea", mergeProps(inputAttrs, {
|
4448
|
+
"inputmode": props2.inputmode
|
4449
|
+
}), null);
|
4451
4450
|
}
|
4452
|
-
return createVNode("input", mergeProps(mapInputType(props2.type), inputAttrs), null);
|
4451
|
+
return createVNode("input", mergeProps(mapInputType(props2.type, props2.inputmode), inputAttrs), null);
|
4453
4452
|
};
|
4454
4453
|
const renderLeftIcon = () => {
|
4455
4454
|
const leftIconSlot = slots["left-icon"];
|
@@ -6824,7 +6823,7 @@ var stdin_default$1e = defineComponent({
|
|
6824
6823
|
const canSwitch = props2.switchMode !== "none";
|
6825
6824
|
return createVNode("div", {
|
6826
6825
|
"class": bem$13("header-subtitle", {
|
6827
|
-
"with-
|
6826
|
+
"with-switch": canSwitch
|
6828
6827
|
}),
|
6829
6828
|
"onClick": onClickSubtitle
|
6830
6829
|
}, [canSwitch ? [renderAction(), createVNode("div", {
|
@@ -9502,7 +9501,8 @@ const dialogProps = extend({}, popupSharedProps, {
|
|
9502
9501
|
confirmButtonColor: String,
|
9503
9502
|
confirmButtonDisabled: Boolean,
|
9504
9503
|
showConfirmButton: truthProp,
|
9505
|
-
closeOnClickOverlay: Boolean
|
9504
|
+
closeOnClickOverlay: Boolean,
|
9505
|
+
keyboardEnabled: truthProp
|
9506
9506
|
});
|
9507
9507
|
const popupInheritKeys$1 = [...popupSharedPropKeys, "transition", "closeOnPopstate"];
|
9508
9508
|
var stdin_default$W = defineComponent({
|
@@ -9549,6 +9549,9 @@ var stdin_default$W = defineComponent({
|
|
9549
9549
|
const onConfirm = getActionHandler("confirm");
|
9550
9550
|
const onKeydown = withKeys((event) => {
|
9551
9551
|
var _a, _b;
|
9552
|
+
if (!props2.keyboardEnabled) {
|
9553
|
+
return;
|
9554
|
+
}
|
9552
9555
|
if (event.target !== ((_b = (_a = root.value) == null ? void 0 : _a.popupRef) == null ? void 0 : _b.value)) {
|
9553
9556
|
return;
|
9554
9557
|
}
|
@@ -17055,7 +17058,7 @@ const Lazyload = {
|
|
17055
17058
|
});
|
17056
17059
|
}
|
17057
17060
|
};
|
17058
|
-
const version = "4.9.
|
17061
|
+
const version = "4.9.9";
|
17059
17062
|
function install(app) {
|
17060
17063
|
const components = [
|
17061
17064
|
ActionBar,
|
package/lib/vant.js
CHANGED
@@ -2376,7 +2376,7 @@
|
|
2376
2376
|
return propRef;
|
2377
2377
|
};
|
2378
2378
|
/**
|
2379
|
-
* @vue/shared v3.5.
|
2379
|
+
* @vue/shared v3.5.12
|
2380
2380
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
2381
2381
|
* @license MIT
|
2382
2382
|
**/
|
@@ -4509,20 +4509,16 @@
|
|
4509
4509
|
setRootScrollTop(scrollTop);
|
4510
4510
|
}
|
4511
4511
|
}
|
4512
|
-
function mapInputType(type) {
|
4512
|
+
function mapInputType(type, inputmode) {
|
4513
4513
|
if (type === "number") {
|
4514
|
-
|
4515
|
-
|
4516
|
-
inputmode: "decimal"
|
4517
|
-
};
|
4514
|
+
type = "text";
|
4515
|
+
inputmode != null ? inputmode : inputmode = "decimal";
|
4518
4516
|
}
|
4519
4517
|
if (type === "digit") {
|
4520
|
-
|
4521
|
-
|
4522
|
-
inputmode: "numeric"
|
4523
|
-
};
|
4518
|
+
type = "tel";
|
4519
|
+
inputmode != null ? inputmode : inputmode = "numeric";
|
4524
4520
|
}
|
4525
|
-
return { type };
|
4521
|
+
return { type, inputmode };
|
4526
4522
|
}
|
4527
4523
|
function getStringLength(str) {
|
4528
4524
|
return [...str].length;
|
@@ -4568,7 +4564,8 @@
|
|
4568
4564
|
readonly: {
|
4569
4565
|
type: Boolean,
|
4570
4566
|
default: null
|
4571
|
-
}
|
4567
|
+
},
|
4568
|
+
inputmode: String
|
4572
4569
|
};
|
4573
4570
|
const fieldProps = extend({}, cellSharedProps, fieldSharedProps, {
|
4574
4571
|
rows: numericProp,
|
@@ -4911,9 +4908,11 @@
|
|
4911
4908
|
onCompositionstart: startComposing
|
4912
4909
|
};
|
4913
4910
|
if (props2.type === "textarea") {
|
4914
|
-
return vue.createVNode("textarea", inputAttrs,
|
4911
|
+
return vue.createVNode("textarea", vue.mergeProps(inputAttrs, {
|
4912
|
+
"inputmode": props2.inputmode
|
4913
|
+
}), null);
|
4915
4914
|
}
|
4916
|
-
return vue.createVNode("input", vue.mergeProps(mapInputType(props2.type), inputAttrs), null);
|
4915
|
+
return vue.createVNode("input", vue.mergeProps(mapInputType(props2.type, props2.inputmode), inputAttrs), null);
|
4917
4916
|
};
|
4918
4917
|
const renderLeftIcon = () => {
|
4919
4918
|
const leftIconSlot = slots["left-icon"];
|
@@ -7285,7 +7284,7 @@
|
|
7285
7284
|
const canSwitch = props2.switchMode !== "none";
|
7286
7285
|
return vue.createVNode("div", {
|
7287
7286
|
"class": bem$13("header-subtitle", {
|
7288
|
-
"with-
|
7287
|
+
"with-switch": canSwitch
|
7289
7288
|
}),
|
7290
7289
|
"onClick": onClickSubtitle
|
7291
7290
|
}, [canSwitch ? [renderAction(), vue.createVNode("div", {
|
@@ -9943,7 +9942,8 @@
|
|
9943
9942
|
confirmButtonColor: String,
|
9944
9943
|
confirmButtonDisabled: Boolean,
|
9945
9944
|
showConfirmButton: truthProp,
|
9946
|
-
closeOnClickOverlay: Boolean
|
9945
|
+
closeOnClickOverlay: Boolean,
|
9946
|
+
keyboardEnabled: truthProp
|
9947
9947
|
});
|
9948
9948
|
const popupInheritKeys$1 = [...popupSharedPropKeys, "transition", "closeOnPopstate"];
|
9949
9949
|
var stdin_default$W = vue.defineComponent({
|
@@ -9990,6 +9990,9 @@
|
|
9990
9990
|
const onConfirm = getActionHandler("confirm");
|
9991
9991
|
const onKeydown = vue.withKeys((event) => {
|
9992
9992
|
var _a, _b;
|
9993
|
+
if (!props2.keyboardEnabled) {
|
9994
|
+
return;
|
9995
|
+
}
|
9993
9996
|
if (event.target !== ((_b = (_a = root.value) == null ? void 0 : _a.popupRef) == null ? void 0 : _b.value)) {
|
9994
9997
|
return;
|
9995
9998
|
}
|
@@ -18270,7 +18273,7 @@
|
|
18270
18273
|
});
|
18271
18274
|
}
|
18272
18275
|
};
|
18273
|
-
const version = "4.9.
|
18276
|
+
const version = "4.9.9";
|
18274
18277
|
function install(app) {
|
18275
18278
|
const components = [
|
18276
18279
|
ActionBar,
|