@vuetify/nightly 2.6.6 → 2.6.7-master-20220616.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 +6 -6
- package/dist/json/web-types.json +5 -5
- package/dist/vuetify.css +41 -43
- package/dist/vuetify.css.map +1 -1
- package/dist/vuetify.js +26 -58
- package/dist/vuetify.js.map +1 -1
- package/dist/vuetify.min.css +2 -2
- package/dist/vuetify.min.js +2 -2
- package/es5/components/VOtpInput/VOtpInput.js +26 -58
- package/es5/components/VOtpInput/VOtpInput.js.map +1 -1
- package/es5/framework.js +1 -1
- package/lib/components/VOtpInput/VOtpInput.js +25 -55
- package/lib/components/VOtpInput/VOtpInput.js.map +1 -1
- package/lib/framework.js +1 -1
- package/package.json +1 -1
- package/src/components/VAutocomplete/VAutocomplete.sass +0 -4
- package/src/components/VInput/VInput.sass +2 -5
- package/src/components/VOtpInput/VOtpInput.ts +23 -43
- package/src/components/VOtpInput/__tests__/VOtpInput.spec.ts +3 -27
- package/src/components/VRadioGroup/VRadio.sass +0 -4
- package/src/components/VSelect/VSelect.sass +3 -1
- package/src/components/VTimeline/VTimeline.sass +16 -9
- package/src/components/VTimeline/_mixins.sass +4 -3
- package/src/styles/components/_selection-controls.sass +3 -0
package/dist/vuetify.js
CHANGED
|
@@ -20849,7 +20849,6 @@ var baseMixins = Object(_util_mixins__WEBPACK_IMPORTED_MODULE_7__["default"])(_V
|
|
|
20849
20849
|
},
|
|
20850
20850
|
data: function data() {
|
|
20851
20851
|
return {
|
|
20852
|
-
badInput: false,
|
|
20853
20852
|
initialValue: null,
|
|
20854
20853
|
isBooted: false,
|
|
20855
20854
|
otp: []
|
|
@@ -20863,9 +20862,6 @@ var baseMixins = Object(_util_mixins__WEBPACK_IMPORTED_MODULE_7__["default"])(_V
|
|
|
20863
20862
|
return __assign(__assign(__assign({}, _VInput__WEBPACK_IMPORTED_MODULE_2__["default"].options.computed.classes.call(this)), _VTextField_VTextField__WEBPACK_IMPORTED_MODULE_3__["default"].options.computed.classes.call(this)), {
|
|
20864
20863
|
'v-otp-input--plain': this.plain
|
|
20865
20864
|
});
|
|
20866
|
-
},
|
|
20867
|
-
isDirty: function isDirty() {
|
|
20868
|
-
return _VInput__WEBPACK_IMPORTED_MODULE_2__["default"].options.computed.isDirty.call(this) || this.badInput;
|
|
20869
20865
|
}
|
|
20870
20866
|
},
|
|
20871
20867
|
watch: {
|
|
@@ -20971,12 +20967,12 @@ var baseMixins = Object(_util_mixins__WEBPACK_IMPORTED_MODULE_7__["default"])(_V
|
|
|
20971
20967
|
min: this.type === 'number' ? 0 : null
|
|
20972
20968
|
},
|
|
20973
20969
|
attrs: __assign(__assign({}, this.attrs$), {
|
|
20970
|
+
autocomplete: 'one-time-code',
|
|
20974
20971
|
disabled: this.isDisabled,
|
|
20975
20972
|
readonly: this.isReadonly,
|
|
20976
20973
|
type: this.type,
|
|
20977
20974
|
id: this.computedId + "--" + otpIdx,
|
|
20978
|
-
class: "otp-field-box--" + otpIdx
|
|
20979
|
-
maxlength: 1
|
|
20975
|
+
class: "otp-field-box--" + otpIdx
|
|
20980
20976
|
}),
|
|
20981
20977
|
on: Object.assign(listeners, {
|
|
20982
20978
|
blur: this.onBlur,
|
|
@@ -20986,9 +20982,6 @@ var baseMixins = Object(_util_mixins__WEBPACK_IMPORTED_MODULE_7__["default"])(_V
|
|
|
20986
20982
|
focus: function focus(e) {
|
|
20987
20983
|
return _this.onFocus(e, otpIdx);
|
|
20988
20984
|
},
|
|
20989
|
-
paste: function paste(e) {
|
|
20990
|
-
return _this.onPaste(e, otpIdx);
|
|
20991
|
-
},
|
|
20992
20985
|
keydown: this.onKeyDown,
|
|
20993
20986
|
keyup: function keyup(e) {
|
|
20994
20987
|
return _this.onKeyUp(e, otpIdx);
|
|
@@ -21033,24 +21026,32 @@ var baseMixins = Object(_util_mixins__WEBPACK_IMPORTED_MODULE_7__["default"])(_V
|
|
|
21033
21026
|
e && this.$emit('focus', e);
|
|
21034
21027
|
}
|
|
21035
21028
|
},
|
|
21036
|
-
onInput: function onInput(e,
|
|
21037
|
-
var
|
|
21038
|
-
|
|
21029
|
+
onInput: function onInput(e, index) {
|
|
21030
|
+
var maxCursor = +this.length - 1;
|
|
21039
21031
|
var target = e.target;
|
|
21040
21032
|
var value = target.value;
|
|
21041
|
-
|
|
21042
|
-
_this.internalValue = _this.otp.join('');
|
|
21043
|
-
});
|
|
21044
|
-
this.badInput = target.validity && target.validity.badInput;
|
|
21045
|
-
var nextIndex = otpIdx + 1;
|
|
21033
|
+
var inputDataArray = (value === null || value === void 0 ? void 0 : value.split('')) || [];
|
|
21046
21034
|
|
|
21047
|
-
|
|
21048
|
-
|
|
21049
|
-
|
|
21050
|
-
|
|
21051
|
-
|
|
21052
|
-
|
|
21053
|
-
|
|
21035
|
+
var newOtp = __spread(this.otp);
|
|
21036
|
+
|
|
21037
|
+
for (var i = 0; i < inputDataArray.length; i++) {
|
|
21038
|
+
var appIdx = index + i;
|
|
21039
|
+
if (appIdx > maxCursor) break;
|
|
21040
|
+
newOtp[appIdx] = inputDataArray[i].toString();
|
|
21041
|
+
}
|
|
21042
|
+
|
|
21043
|
+
if (!inputDataArray.length) {
|
|
21044
|
+
newOtp.splice(index, 1);
|
|
21045
|
+
}
|
|
21046
|
+
|
|
21047
|
+
this.otp = newOtp;
|
|
21048
|
+
this.internalValue = this.otp.join('');
|
|
21049
|
+
|
|
21050
|
+
if (index + inputDataArray.length >= +this.length) {
|
|
21051
|
+
this.onCompleted();
|
|
21052
|
+
this.clearFocus(index);
|
|
21053
|
+
} else if (inputDataArray.length) {
|
|
21054
|
+
this.changeFocus(index + inputDataArray.length);
|
|
21054
21055
|
}
|
|
21055
21056
|
},
|
|
21056
21057
|
clearFocus: function clearFocus(index) {
|
|
@@ -21077,39 +21078,6 @@ var baseMixins = Object(_util_mixins__WEBPACK_IMPORTED_MODULE_7__["default"])(_V
|
|
|
21077
21078
|
if (this.hasMouseDown) this.focus(e, otpIdx);
|
|
21078
21079
|
_VInput__WEBPACK_IMPORTED_MODULE_2__["default"].options.methods.onMouseUp.call(this, e);
|
|
21079
21080
|
},
|
|
21080
|
-
onPaste: function onPaste(event, index) {
|
|
21081
|
-
var _a;
|
|
21082
|
-
|
|
21083
|
-
var maxCursor = +this.length - 1;
|
|
21084
|
-
var inputVal = (_a = event === null || event === void 0 ? void 0 : event.clipboardData) === null || _a === void 0 ? void 0 : _a.getData('Text');
|
|
21085
|
-
var inputDataArray = (inputVal === null || inputVal === void 0 ? void 0 : inputVal.split('')) || [];
|
|
21086
|
-
event.preventDefault();
|
|
21087
|
-
|
|
21088
|
-
var newOtp = __spread(this.otp);
|
|
21089
|
-
|
|
21090
|
-
for (var i = 0; i < inputDataArray.length; i++) {
|
|
21091
|
-
var appIdx = index + i;
|
|
21092
|
-
if (appIdx > maxCursor) break;
|
|
21093
|
-
newOtp[appIdx] = inputDataArray[i].toString();
|
|
21094
|
-
}
|
|
21095
|
-
|
|
21096
|
-
this.otp = newOtp;
|
|
21097
|
-
this.internalValue = this.otp.join('');
|
|
21098
|
-
var targetFocus = Math.min(index + inputDataArray.length, maxCursor);
|
|
21099
|
-
this.changeFocus(targetFocus);
|
|
21100
|
-
|
|
21101
|
-
if (newOtp.length === +this.length) {
|
|
21102
|
-
this.onCompleted();
|
|
21103
|
-
this.clearFocus(targetFocus);
|
|
21104
|
-
}
|
|
21105
|
-
},
|
|
21106
|
-
applyValue: function applyValue(index, inputVal, next) {
|
|
21107
|
-
var newOtp = __spread(this.otp);
|
|
21108
|
-
|
|
21109
|
-
newOtp[index] = inputVal;
|
|
21110
|
-
this.otp = newOtp;
|
|
21111
|
-
next();
|
|
21112
|
-
},
|
|
21113
21081
|
changeFocus: function changeFocus(index) {
|
|
21114
21082
|
this.onFocus(undefined, index || 0);
|
|
21115
21083
|
},
|
|
@@ -35046,7 +35014,7 @@ function () {
|
|
|
35046
35014
|
|
|
35047
35015
|
Vuetify.install = _install__WEBPACK_IMPORTED_MODULE_0__["install"];
|
|
35048
35016
|
Vuetify.installed = false;
|
|
35049
|
-
Vuetify.version = "2.6.
|
|
35017
|
+
Vuetify.version = "2.6.7-master-20220616.0";
|
|
35050
35018
|
Vuetify.config = {
|
|
35051
35019
|
silent: false
|
|
35052
35020
|
};
|