Socket
Socket
Sign inDemoInstall

vee-validate

Package Overview
Dependencies
0
Maintainers
1
Versions
332
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 2.0.0-beta.3 to 2.0.0-beta.4

1

dist/locale/ar.js

@@ -7,2 +7,3 @@ export default {

confirmed: (field, [confirmedField]) => `${field} لا يماثل التأكيد.`,
decimal: (field, [decimals] = ['*']) => `${field} يجب ان يكون قيمة رقمية وقد يحتوي على ${decimals === '*' ? '' : decimals} ارقام عشرية.`,
digits: (field, [length]) => `${field} يجب ان تحتوي فقط على ارقام والا يزيد عددها عن ${length} رقم.`,

@@ -9,0 +10,0 @@ dimensions: (field, [width, height]) => `${field} يجب ان تكون بمقاس ${width} بكسل في ${height} بكسل.`,

@@ -7,2 +7,3 @@ export default {

confirmed: (field, [confirmedField]) => `The ${field} does not match the ${confirmedField}.`,
decimal: (field, [decimals] = ['*']) => `The ${field} must be numeric and may contain ${decimals === '*' ? '' : decimals} decimal points.`,
digits: (field, [length]) => `The ${field} must be numeric and exactly contain ${length} digits.`,

@@ -9,0 +10,0 @@ dimensions: (field, [width, height]) => `The ${field} must be ${width} pixels by ${height} pixels.`,

197

dist/vee-validate.js

@@ -74,3 +74,3 @@ (function webpackUniversalModuleDefinition(root, factory) {

/******/ // Load entry module and return exports
/******/ return __webpack_require__(__webpack_require__.s = 32);
/******/ return __webpack_require__(__webpack_require__.s = 33);
/******/ })

@@ -326,7 +326,7 @@ /************************************************************************/

"use strict";
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__rules__ = __webpack_require__(19);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__rules__ = __webpack_require__(20);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__errorBag__ = __webpack_require__(0);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__exceptions_validatorException__ = __webpack_require__(5);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__messages__ = __webpack_require__(7);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__utils_warn__ = __webpack_require__(31);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__utils_warn__ = __webpack_require__(32);
var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol ? "symbol" : typeof obj; };

@@ -550,3 +550,3 @@

value: function _normalizeRule(rule) {
var params = null;
var params = [];
if (~rule.indexOf(':')) {

@@ -769,3 +769,3 @@ params = rule.split(':')[1].split(',');

"use strict";
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__utils_debouncer_js__ = __webpack_require__(30);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__utils_debouncer_js__ = __webpack_require__(31);

@@ -949,9 +949,9 @@

alpha_dash: function alpha_dash(field) {
return "The " + field + " may contain alpha-numeric characters as well as dashes and underscores.";
return 'The ' + field + ' may contain alpha-numeric characters as well as dashes and underscores.';
},
alpha_num: function alpha_num(field) {
return "The " + field + " may only contain alpha-numeric characters.";
return 'The ' + field + ' may only contain alpha-numeric characters.';
},
alpha: function alpha(field) {
return "The " + field + " may only contain alphabetic characters.";
return 'The ' + field + ' may only contain alphabetic characters.';
},

@@ -963,3 +963,3 @@ between: function between(field, _ref) {

var max = _ref2[1];
return "The " + field + " must be between " + min + " and " + max + ".";
return 'The ' + field + ' must be between ' + min + ' and ' + max + '.';
},

@@ -970,67 +970,75 @@ confirmed: function confirmed(field, _ref3) {

var confirmedField = _ref4[0];
return "The " + field + " does not match the " + confirmedField + ".";
return 'The ' + field + ' does not match the ' + confirmedField + '.';
},
digits: function digits(field, _ref5) {
decimal: function decimal(field) {
var _ref5 = arguments.length <= 1 || arguments[1] === undefined ? ['*'] : arguments[1];
var _ref6 = _slicedToArray(_ref5, 1);
var length = _ref6[0];
return "The " + field + " must be numeric and exactly contain " + length + " digits.";
var decimals = _ref6[0];
return 'The ' + field + ' must be numeric and may contain ' + (decimals === '*' ? '' : decimals) + ' decimal points.';
},
dimensions: function dimensions(field, _ref7) {
var _ref8 = _slicedToArray(_ref7, 2);
digits: function digits(field, _ref7) {
var _ref8 = _slicedToArray(_ref7, 1);
var width = _ref8[0];
var height = _ref8[1];
return "The " + field + " must be " + width + " pixels by " + height + " pixels.";
var length = _ref8[0];
return 'The ' + field + ' must be numeric and exactly contain ' + length + ' digits.';
},
dimensions: function dimensions(field, _ref9) {
var _ref10 = _slicedToArray(_ref9, 2);
var width = _ref10[0];
var height = _ref10[1];
return 'The ' + field + ' must be ' + width + ' pixels by ' + height + ' pixels.';
},
email: function email(field) {
return "The " + field + " must be a valid email.";
return 'The ' + field + ' must be a valid email.';
},
ext: function ext(field) {
return "The " + field + " must be a valid file.";
return 'The ' + field + ' must be a valid file.';
},
image: function image(field) {
return "The " + field + " must be an image.";
return 'The ' + field + ' must be an image.';
},
in: function _in(field) {
return "The " + field + " must be a valid value.";
return 'The ' + field + ' must be a valid value.';
},
ip: function ip(field) {
return "The " + field + " must be a valid ip address.";
return 'The ' + field + ' must be a valid ip address.';
},
max: function max(field, _ref9) {
var _ref10 = _slicedToArray(_ref9, 1);
max: function max(field, _ref11) {
var _ref12 = _slicedToArray(_ref11, 1);
var length = _ref10[0];
return "The " + field + " may not be greater than " + length + " characters.";
var length = _ref12[0];
return 'The ' + field + ' may not be greater than ' + length + ' characters.';
},
mimes: function mimes(field) {
return "The " + field + " must have a valid file type.";
return 'The ' + field + ' must have a valid file type.';
},
min: function min(field, _ref11) {
var _ref12 = _slicedToArray(_ref11, 1);
min: function min(field, _ref13) {
var _ref14 = _slicedToArray(_ref13, 1);
var length = _ref12[0];
return "The " + field + " must be at least " + length + " characters.";
var length = _ref14[0];
return 'The ' + field + ' must be at least ' + length + ' characters.';
},
not_in: function not_in(field) {
return "The " + field + " must be a valid value.";
return 'The ' + field + ' must be a valid value.';
},
numeric: function numeric(field) {
return "The " + field + " may only contain numeric characters.";
return 'The ' + field + ' may only contain numeric characters.';
},
regex: function regex(field) {
return "The " + field + " format is invalid.";
return 'The ' + field + ' format is invalid.';
},
required: function required(field) {
return "The " + field + " is required.";
return 'The ' + field + ' is required.';
},
size: function size(field, _ref13) {
var _ref14 = _slicedToArray(_ref13, 1);
size: function size(field, _ref15) {
var _ref16 = _slicedToArray(_ref15, 1);
var _size = _ref14[0];
return "The " + field + " must be less than " + _size + " KB.";
var _size = _ref16[0];
return 'The ' + field + ' must be less than ' + _size + ' KB.';
},
url: function url(field) {
return "The " + field + " is not a valid URL.";
return 'The ' + field + ' is not a valid URL.';
}

@@ -1117,2 +1125,34 @@ };

/* harmony default export */ exports["a"] = function (value) {
var _ref = arguments.length <= 1 || arguments[1] === undefined ? ['*'] : arguments[1];
var _ref2 = _slicedToArray(_ref, 1);
var decimals = _ref2[0];
if (Array.isArray(value)) {
return false;
}
if (value === null || value === undefined || value === '') {
return true;
}
var regexPart = decimals === '*' ? '*' : '{0,' + decimals + '}';
var regex = new RegExp('^[0-9]*.?[0-9]' + regexPart + '$');
if (!regex.test(value)) {
return false;
}
return !Number.isNaN(parseFloat(value));
};
/***/ },
/* 14 */
/***/ function(module, exports, __webpack_require__) {
"use strict";
var _slicedToArray = function () { function sliceIterator(arr, i) { var _arr = []; var _n = true; var _d = false; var _e = undefined; try { for (var _i = arr[Symbol.iterator](), _s; !(_n = (_s = _i.next()).done); _n = true) { _arr.push(_s.value); if (i && _arr.length === i) break; } } catch (err) { _d = true; _e = err; } finally { try { if (!_n && _i["return"]) _i["return"](); } finally { if (_d) throw _e; } } return _arr; } return function (arr, i) { if (Array.isArray(arr)) { return arr; } else if (Symbol.iterator in Object(arr)) { return sliceIterator(arr, i); } else { throw new TypeError("Invalid attempt to destructure non-iterable instance"); } }; }();
/* harmony default export */ exports["a"] = function (value, _ref) {

@@ -1130,3 +1170,3 @@ var _ref2 = _slicedToArray(_ref, 1);

/***/ },
/* 14 */
/* 15 */
/***/ function(module, exports, __webpack_require__) {

@@ -1181,3 +1221,3 @@

/***/ },
/* 15 */
/* 16 */
/***/ function(module, exports, __webpack_require__) {

@@ -1192,3 +1232,3 @@

/***/ },
/* 16 */
/* 17 */
/***/ function(module, exports, __webpack_require__) {

@@ -1209,3 +1249,3 @@

/***/ },
/* 17 */
/* 18 */
/***/ function(module, exports, __webpack_require__) {

@@ -1225,3 +1265,3 @@

/***/ },
/* 18 */
/* 19 */
/***/ function(module, exports, __webpack_require__) {

@@ -1237,27 +1277,28 @@

/***/ },
/* 19 */
/* 20 */
/***/ function(module, exports, __webpack_require__) {
"use strict";
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__email__ = __webpack_require__(15);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__in__ = __webpack_require__(18);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__required__ = __webpack_require__(27);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__min__ = __webpack_require__(23);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__max__ = __webpack_require__(21);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__notIn__ = __webpack_require__(24);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__email__ = __webpack_require__(16);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__in__ = __webpack_require__(19);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__required__ = __webpack_require__(28);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__min__ = __webpack_require__(24);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__max__ = __webpack_require__(22);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__notIn__ = __webpack_require__(25);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__alpha__ = __webpack_require__(8);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7__alpha_num__ = __webpack_require__(10);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8__alpha_dash__ = __webpack_require__(9);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9__numeric__ = __webpack_require__(25);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_10__regex__ = __webpack_require__(26);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_11__ip__ = __webpack_require__(20);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_12__ext__ = __webpack_require__(16);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_13__mimes__ = __webpack_require__(22);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_14__size__ = __webpack_require__(28);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_15__digits__ = __webpack_require__(13);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_16__image__ = __webpack_require__(17);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_17__dimensions__ = __webpack_require__(14);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9__numeric__ = __webpack_require__(26);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_10__regex__ = __webpack_require__(27);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_11__ip__ = __webpack_require__(21);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_12__ext__ = __webpack_require__(17);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_13__mimes__ = __webpack_require__(23);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_14__size__ = __webpack_require__(29);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_15__digits__ = __webpack_require__(14);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_16__image__ = __webpack_require__(18);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_17__dimensions__ = __webpack_require__(15);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_18__between__ = __webpack_require__(11);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_19__confirmed__ = __webpack_require__(12);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_20__url__ = __webpack_require__(29);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_20__url__ = __webpack_require__(30);
/* harmony import */ var __WEBPACK_IMPORTED_MODULE_21__decimal__ = __webpack_require__(13);

@@ -1285,2 +1326,3 @@

/* harmony default export */ exports["a"] = {

@@ -1307,7 +1349,8 @@ email: __WEBPACK_IMPORTED_MODULE_0__email__["a" /* default */],

confirmed: __WEBPACK_IMPORTED_MODULE_19__confirmed__["a" /* default */],
url: __WEBPACK_IMPORTED_MODULE_20__url__["a" /* default */]
url: __WEBPACK_IMPORTED_MODULE_20__url__["a" /* default */],
decimal: __WEBPACK_IMPORTED_MODULE_21__decimal__["a" /* default */]
};
/***/ },
/* 20 */
/* 21 */
/***/ function(module, exports, __webpack_require__) {

@@ -1323,3 +1366,3 @@

/***/ },
/* 21 */
/* 22 */
/***/ function(module, exports, __webpack_require__) {

@@ -1343,3 +1386,3 @@

/***/ },
/* 22 */
/* 23 */
/***/ function(module, exports, __webpack_require__) {

@@ -1360,3 +1403,3 @@

/***/ },
/* 23 */
/* 24 */
/***/ function(module, exports, __webpack_require__) {

@@ -1380,3 +1423,3 @@

/***/ },
/* 24 */
/* 25 */
/***/ function(module, exports, __webpack_require__) {

@@ -1392,3 +1435,3 @@

/***/ },
/* 25 */
/* 26 */
/***/ function(module, exports, __webpack_require__) {

@@ -1402,3 +1445,3 @@

/***/ },
/* 26 */
/* 27 */
/***/ function(module, exports, __webpack_require__) {

@@ -1420,3 +1463,3 @@

/***/ },
/* 27 */
/* 28 */
/***/ function(module, exports, __webpack_require__) {

@@ -1438,3 +1481,3 @@

/***/ },
/* 28 */
/* 29 */
/***/ function(module, exports, __webpack_require__) {

@@ -1465,3 +1508,3 @@

/***/ },
/* 29 */
/* 30 */
/***/ function(module, exports, __webpack_require__) {

@@ -1483,3 +1526,3 @@

/***/ },
/* 30 */
/* 31 */
/***/ function(module, exports, __webpack_require__) {

@@ -1523,3 +1566,3 @@

/***/ },
/* 31 */
/* 32 */
/***/ function(module, exports, __webpack_require__) {

@@ -1538,3 +1581,3 @@

/***/ },
/* 32 */
/* 33 */
/***/ function(module, exports, __webpack_require__) {

@@ -1541,0 +1584,0 @@

@@ -1,1 +0,1 @@

!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.VeeValidate=e():t.VeeValidate=e()}(this,function(){return function(t){function e(n){if(r[n])return r[n].exports;var a=r[n]={i:n,l:!1,exports:{}};return t[n].call(a.exports,a,a.exports,e),a.l=!0,a.exports}var r={};return e.m=t,e.c=r,e.i=function(t){return t},e.d=function(t,e,r){Object.defineProperty(t,e,{configurable:!1,enumerable:!0,get:r})},e.n=function(t){var r=t&&t.__esModule?function(){return t["default"]}:function(){return t};return e.d(r,"a",r),r},e.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},e.p="",e(e.s=32)}([function(t,e,r){"use strict";function n(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}var a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol?"symbol":typeof t},i=function(){function t(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}return function(e,r,n){return r&&t(e.prototype,r),n&&t(e,n),e}}(),o=function(){function t(){n(this,t),this.errors=[]}return i(t,[{key:"add",value:function(t,e){this.errors.push({field:t,msg:e})}},{key:"all",value:function(){return this.errors.map(function(t){return t.msg})}},{key:"any",value:function(){return!!this.errors.length}},{key:"clear",value:function(){this.errors=[]}},{key:"collect",value:function(t){var e=this;if(!t){var r=function(){var t={};return e.errors.forEach(function(e){t[e.field]||(t[e.field]=[]),t[e.field].push(e.msg)}),{v:t}}();if("object"===("undefined"==typeof r?"undefined":a(r)))return r.v}return this.errors.filter(function(e){return e.field===t}).map(function(t){return t.msg})}},{key:"count",value:function(){return this.errors.length}},{key:"first",value:function(t){for(var e=0;e<this.errors.length;e++)if(this.errors[e].field===t)return this.errors[e].msg;return null}},{key:"has",value:function(t){for(var e=0;e<this.errors.length;e++)if(this.errors[e].field===t)return!0;return!1}},{key:"remove",value:function(t){this.errors=this.errors.filter(function(e){return e.field!==t})}}]),t}();e.a=o},function(t,e,r){"use strict";var n=r(2);r.d(e,"b",function(){return o}),r.d(e,"a",function(){return u});var a=[],i=function(t){for(var e=0;e<a.length;e++)if(a[e].$vm===t)return a[e].$validator},o=function(t){var e=i(t);return e||(e=n.a.create(void 0,t),a.push({$vm:t,$validator:e})),e},u=function(t){for(var e=0;e<a.length;e++)if(a[e].$vm===t)return a.splice(e,1),!0;return!1}},function(t,e,r){"use strict";function n(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}var a=r(19),i=r(0),o=r(5),u=r(7),c=r(31),s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol?"symbol":typeof t},f=function(){function t(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}return function(e,r,n){return r&&t(e.prototype,r),n&&t(e,n),e}}(),l="veeValidate",v="en",d=function(){function t(e,r){n(this,t),this.locale=v,this.$fields=this._normalize(e),this.errorBag=new i.a,this.$vm=r}return f(t,[{key:"setLocale",value:function(t){u.a[t]||r.i(c.a)("You are setting the validator locale to a locale that is not defined in the dicitionary. English messages may still be generated."),this.locale=t}},{key:"attach",value:function(t,e){var r=this,n=arguments.length<=2||void 0===arguments[2]?null:arguments[2];this.$fields[t]||(this.$fields[t]={}),this.$fields[t].validations=[],this.errorBag.remove(t),e.split("|").forEach(function(e){r.$fields[t].validations.push(r._normalizeRule(e))}),n&&(this.$fields[t].name=n)}},{key:"updateDictionary",value:function(e){t.updateDictionary(e)}},{key:"detach",value:function(t){delete this.$fields[t]}},{key:"extend",value:function(e,r){t.extend(e,r)}},{key:"validateAll",value:function(t){var e=this;if(this.errorBag.clear(),this.$vm&&!this.values)return void this.$vm.$emit(l);var r=!0;return Object.keys(t).forEach(function(n){r=e.validate(n,t[n])}),r}},{key:"validate",value:function(t,e){var n=this;if(!this.$fields[t])return r.i(c.a)('You are trying to validate a non-existant field. Use "attach()" first.'),!1;var a=!0;return this.errorBag.remove(t),this.$fields[t].validations.forEach(function(r){a=n._test(t,e,r)}),a}},{key:"_normalize",value:function(t){var e=this;if(!t)return{};var r={};return Object.keys(t).forEach(function(n){t[n].split("|").forEach(function(t){r[n]||(r[n]={validations:[]}),r[n].validations.push(e._normalizeRule(t))})}),r}},{key:"_normalizeRule",value:function(t){var e=null;return~t.indexOf(":")&&(e=t.split(":")[1].split(",")),{name:t.split(":")[0],params:e}}},{key:"_formatErrorMessage",value:function(t,e){return u.a[this.locale]&&"function"==typeof u.a[this.locale][e.name]?u.a[this.locale][e.name](t,e.params):u.a.en[e.name](t,e.params)}},{key:"_test",value:function(t,e,r){var n=this,i=a.a[r.name],o=i(e,r.params),u=this.$fields[t].name||t;return o instanceof Promise?o.then(function(e){var a=e.reduce(function(t,e){return t&&e.valid},!0);return a||n.errorBag.add(t,n._formatErrorMessage(u,r)),a}):(o||this.errorBag.add(t,this._formatErrorMessage(u,r)),o)}},{key:"getErrors",value:function(){return this.errorBag}}],[{key:"setDefaultLocale",value:function(){var t=arguments.length<=0||void 0===arguments[0]?"en":arguments[0];u.a[t]||r.i(c.a)("You are setting the validator locale to a locale that is not defined in the dicitionary. English messages may still be generated."),v=t}},{key:"updateDictionary",value:function(t){Object.keys(t).forEach(function(e){u.a[e]||(u.a[e]={}),Object.keys(t[e]).forEach(function(r){u.a[e][r]=t[e][r]})})}},{key:"create",value:function(e,r){return new t(e,r)}},{key:"extend",value:function(e,r){t._guardExtend(e,r),t._merge(e,r)}},{key:"_merge",value:function(t,e){return"function"==typeof e?(a.a[t]=e,void(u.a.en[t]=function(t){return"The "+t+" value is not valid."})):(a.a[t]=e.validate,e.getMessage&&"function"==typeof e.getMessage&&(u.a.en[t]=e.getMessage),void(e.messages&&Object.keys(e.messages).forEach(function(r){u.a[r]||(u.a[r]={}),u.a[r][t]=e.messages[r]})))}},{key:"_guardExtend",value:function(t,e){if(a.a[t])throw new o.a("Extension Error: There is an existing validator with the same name '"+t+"'.");if("function"!=typeof e){if("function"!=typeof e.validate)throw new o.a("Extension Error: The validator '"+t+"' must be a function or have a 'validate' method.");if("function"!=typeof e.getMessage&&"object"!==s(e.messages))throw new o.a("Extension Error: The validator '"+t+"' must have a 'getMessage' method or have a 'messages' object.")}}}]),t}();e.a=d},function(t,e,r){"use strict";var n=r(30),a=[],i="veeValidate",o=function(t,e,r){var n=e.expression,a=r.context;return function(){a.$validator.validate(n||t.name,t.value)}},u=function(t,e,r){var n=e.modifiers,a=e.expression,i=r.context;return function(){!i.$validator.validate(a||t.name,t.files)&&n.reject&&(t.value="")}},c=function(t,e,r){var n=e.expression,u=e.value,c=r.context,s=void 0;s=n?o(t,{expression:n},{context:c}):function(){return c.$validator.validate(n||t.name,u)},a.push({vm:c,event:"validatorEvent",callback:s,el:t}),c.$on(i,s)};e.a=function(t){return{bind:function(e,i,s){var f=s.context;if(f.$validator.attach(i.expression||e.name,e.dataset.rules,e.dataset.as),c(e,i,{context:f}),i.expression&&!i.modifiers.initial)return void f.$validator.validate(i.expression,i.value);var l="file"===e.type?u(e,i,{context:f}):o(e,{},{context:f}),v=e.dataset.delay||t.delay;l=v?r.i(n.a)(l,v):l;var d="file"===e.type?"change":"input";e.addEventListener(d,l),a.push({vm:f,event:d,callback:l,el:e}),e.dataset.rules&&~e.dataset.rules.indexOf("confirmed")&&!function(){var t=e.dataset.rules.split("|").filter(function(t){return!!~t.indexOf("confirmed")})[0].split(":")[1];f.$once("validatorReady",function(){document.querySelector("input[name='"+t+"']").addEventListener("input",l)})}()},update:function(t,e,r){var n=e.expression,a=e.value,i=(e.modifiers,e.oldValue),o=r.context;n&&a!==i&&o.$validator.validate(n||t.name,a)},unbind:function(t,e,r){var n=r.context,o=a.filter(function(e){return e.vm===n&&e.el===t});n.$off(i,o.filter(function(t){var e=t.event;return"validatorEvent"===e})[0]),o.filter(function(t){var e=t.event;return"validatorEvent"!==e}).forEach(function(e){t.removeEventListener(e.event,e.callback)})}}}},function(t,e,r){"use strict";function n(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var a=r(1);e.a=function(t){return{data:function(){return n({},t.errorBagName,this.$validator.errorBag)},mounted:function(){this.$emit("validatorReady")},destroyed:function(){r.i(a.a)(this)}}}},function(t,e,r){"use strict";function n(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}var a=function(){function t(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}return function(e,r,n){return r&&t(e.prototype,r),n&&t(e,n),e}}(),i=function(){function t(e){n(this,t),this.msg=e}return a(t,[{key:"toString",value:function(){return this.msg}}]),t}();e.a=i},function(t,e,r){"use strict";var n=function(){function t(t,e){var r=[],n=!0,a=!1,i=void 0;try{for(var o,u=t[Symbol.iterator]();!(n=(o=u.next()).done)&&(r.push(o.value),!e||r.length!==e);n=!0);}catch(c){a=!0,i=c}finally{try{!n&&u["return"]&&u["return"]()}finally{if(a)throw i}}return r}return function(e,r){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,r);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}();e.a={alpha_dash:function(t){return"The "+t+" may contain alpha-numeric characters as well as dashes and underscores."},alpha_num:function(t){return"The "+t+" may only contain alpha-numeric characters."},alpha:function(t){return"The "+t+" may only contain alphabetic characters."},between:function(t,e){var r=n(e,2),a=r[0],i=r[1];return"The "+t+" must be between "+a+" and "+i+"."},confirmed:function(t,e){var r=n(e,1),a=r[0];return"The "+t+" does not match the "+a+"."},digits:function(t,e){var r=n(e,1),a=r[0];return"The "+t+" must be numeric and exactly contain "+a+" digits."},dimensions:function(t,e){var r=n(e,2),a=r[0],i=r[1];return"The "+t+" must be "+a+" pixels by "+i+" pixels."},email:function(t){return"The "+t+" must be a valid email."},ext:function(t){return"The "+t+" must be a valid file."},image:function(t){return"The "+t+" must be an image."},"in":function(t){return"The "+t+" must be a valid value."},ip:function(t){return"The "+t+" must be a valid ip address."},max:function(t,e){var r=n(e,1),a=r[0];return"The "+t+" may not be greater than "+a+" characters."},mimes:function(t){return"The "+t+" must have a valid file type."},min:function(t,e){var r=n(e,1),a=r[0];return"The "+t+" must be at least "+a+" characters."},not_in:function(t){return"The "+t+" must be a valid value."},numeric:function(t){return"The "+t+" may only contain numeric characters."},regex:function(t){return"The "+t+" format is invalid."},required:function(t){return"The "+t+" is required."},size:function(t,e){var r=n(e,1),a=r[0];return"The "+t+" must be less than "+a+" KB."},url:function(t){return"The "+t+" is not a valid URL."}}},function(t,e,r){"use strict";var n=r(6);e.a={en:n.a}},function(t,e,r){"use strict";e.a=function(t){return!Array.isArray(t)&&/^[a-zA-Z]*$/.test(t)}},function(t,e,r){"use strict";e.a=function(t){return!Array.isArray(t)&&/^[a-zA-Z0-9_-]*$/.test(t)}},function(t,e,r){"use strict";e.a=function(t){return!Array.isArray(t)&&/^[a-zA-Z0-9]*$/.test(t)}},function(t,e,r){"use strict";var n=function(){function t(t,e){var r=[],n=!0,a=!1,i=void 0;try{for(var o,u=t[Symbol.iterator]();!(n=(o=u.next()).done)&&(r.push(o.value),!e||r.length!==e);n=!0);}catch(c){a=!0,i=c}finally{try{!n&&u["return"]&&u["return"]()}finally{if(a)throw i}}return r}return function(e,r){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,r);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}();e.a=function(t,e){var r=n(e,2),a=r[0],i=r[1];return Number(a)<=t&&Number(i)>=t}},function(t,e,r){"use strict";var n=function(){function t(t,e){var r=[],n=!0,a=!1,i=void 0;try{for(var o,u=t[Symbol.iterator]();!(n=(o=u.next()).done)&&(r.push(o.value),!e||r.length!==e);n=!0);}catch(c){a=!0,i=c}finally{try{!n&&u["return"]&&u["return"]()}finally{if(a)throw i}}return r}return function(e,r){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,r);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}();e.a=function(t,e){var r=n(e,1),a=r[0],i=document.querySelector("input[name='"+a+"']");return!(!i||String(t)!==i.value)}},function(t,e,r){"use strict";var n=function(){function t(t,e){var r=[],n=!0,a=!1,i=void 0;try{for(var o,u=t[Symbol.iterator]();!(n=(o=u.next()).done)&&(r.push(o.value),!e||r.length!==e);n=!0);}catch(c){a=!0,i=c}finally{try{!n&&u["return"]&&u["return"]()}finally{if(a)throw i}}return r}return function(e,r){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,r);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}();e.a=function(t,e){var r=n(e,1),a=r[0],i=String(t);return/^[0-9]*$/.test(i)&&i.length===Number(a)}},function(t,e,r){"use strict";var n=function(){function t(t,e){var r=[],n=!0,a=!1,i=void 0;try{for(var o,u=t[Symbol.iterator]();!(n=(o=u.next()).done)&&(r.push(o.value),!e||r.length!==e);n=!0);}catch(c){a=!0,i=c}finally{try{!n&&u["return"]&&u["return"]()}finally{if(a)throw i}}return r}return function(e,r){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,r);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),a=function(t,e,r){var n=window.URL||window.webkitURL;return new Promise(function(a){var i=new Image;i.onerror=function(){return a({name:t.name,valid:!1})},i.onload=function(){var n=i.width===Number(e)&&i.height===Number(r);a({name:t.name,valid:n})},i.src=n.createObjectURL(t)})};e.a=function(t,e){for(var r=n(e,2),i=r[0],o=r[1],u=[],c=0;c<t.length;c++){if(!/\.(jpg|svg|jpeg|png|bmp|gif)$/i.test(t[c].name))return!1;u.push(t[c])}return Promise.all(u.map(function(t){return a(t,i,o)}))}},function(t,e,r){"use strict";e.a=function(t){return/^[a-zA-Z0-9._-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,6}$/.test(t)}},function(t,e,r){"use strict";e.a=function(t,e){for(var r=new RegExp(".("+e.join("|")+")$","i"),n=0;n<t.length;n++)if(!r.test(t[n].name))return!1;return!0}},function(t,e,r){"use strict";e.a=function(t){for(var e=0;e<t.length;e++)if(!/\.(jpg|svg|jpeg|png|bmp|gif)$/i.test(t[e].name))return!1;return!0}},function(t,e,r){"use strict";e.a=function(t,e){return!!e.filter(function(e){return e==t}).length}},function(t,e,r){"use strict";var n=r(15),a=r(18),i=r(27),o=r(23),u=r(21),c=r(24),s=r(8),f=r(10),l=r(9),v=r(25),d=r(26),h=r(20),y=r(16),m=r(22),p=r(28),g=r(13),b=r(17),w=r(14),x=r(11),E=r(12),$=r(29);e.a={email:n.a,min:o.a,max:u.a,required:i.a,"in":a.a,not_in:c.a,alpha:s.a,alpha_num:f.a,alpha_dash:l.a,numeric:v.a,regex:d.a,ip:h.a,ext:y.a,mimes:m.a,size:p.a,digits:g.a,image:b.a,dimensions:w.a,between:x.a,confirmed:E.a,url:$.a}},function(t,e,r){"use strict";e.a=function(t){return/^(?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.){3}(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)$/.test(t)}},function(t,e,r){"use strict";var n=function(){function t(t,e){var r=[],n=!0,a=!1,i=void 0;try{for(var o,u=t[Symbol.iterator]();!(n=(o=u.next()).done)&&(r.push(o.value),!e||r.length!==e);n=!0);}catch(c){a=!0,i=c}finally{try{!n&&u["return"]&&u["return"]()}finally{if(a)throw i}}return r}return function(e,r){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,r);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}();e.a=function(t,e){var r=n(e,1),a=r[0];return void 0===t||null===t?a>=0:String(t).length<=a}},function(t,e,r){"use strict";e.a=function(t,e){for(var r=new RegExp(e.join("|").replace("*",".+")+"$","i"),n=0;n<t.length;n++)if(!r.test(t[n].type))return!1;return!0}},function(t,e,r){"use strict";var n=function(){function t(t,e){var r=[],n=!0,a=!1,i=void 0;try{for(var o,u=t[Symbol.iterator]();!(n=(o=u.next()).done)&&(r.push(o.value),!e||r.length!==e);n=!0);}catch(c){a=!0,i=c}finally{try{!n&&u["return"]&&u["return"]()}finally{if(a)throw i}}return r}return function(e,r){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,r);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}();e.a=function(t,e){var r=n(e,1),a=r[0];return void 0!==t&&null!==t&&String(t).length>=a}},function(t,e,r){"use strict";e.a=function(t,e){return!e.filter(function(e){return e==t}).length}},function(t,e,r){"use strict";e.a=function(t){return!Array.isArray(t)&&/^[0-9]*$/.test(t)}},function(t,e,r){"use strict";function n(t){return Array.isArray(t)?t:Array.from(t)}e.a=function(t,e){var r=n(e),a=r[0],i=r.slice(1);return new RegExp(a,i).test(String(t))}},function(t,e,r){"use strict";e.a=function(t){return Array.isArray(t)?!!t.length:void 0!==t&&null!==t&&!!String(t).length}},function(t,e,r){"use strict";var n=function(){function t(t,e){var r=[],n=!0,a=!1,i=void 0;try{for(var o,u=t[Symbol.iterator]();!(n=(o=u.next()).done)&&(r.push(o.value),!e||r.length!==e);n=!0);}catch(c){a=!0,i=c}finally{try{!n&&u["return"]&&u["return"]()}finally{if(a)throw i}}return r}return function(e,r){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,r);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}();e.a=function(t,e){var r=n(e,1),a=r[0];if(isNaN(a))return!1;for(var i=1024*Number(a),o=0;o<t.length;o++)if(t[o].size>i)return!1;return!0}},function(t,e,r){"use strict";e.a=function(t,e){var r=/^https?:\/\/([\da-z\.-]+)\.([a-z\.]{2,6})([\/\w\.\(\)%-]*)*\/?$/.test(t),n=e&&e[0];return n&&r?new RegExp("^https?://(([da-z.-]+).)*("+e[0].replace(".","\\$&")+")").test(t):r}},function(t,e,r){"use strict";function n(t){if(Array.isArray(t)){for(var e=0,r=Array(t.length);e<t.length;e++)r[e]=t[e];return r}return Array.from(t)}function a(t){return Array.isArray(t)?t:Array.from(t)}e.a=function(t){var e=arguments.length<=1||void 0===arguments[1]?100:arguments[1],r=!(arguments.length<=2||void 0===arguments[2])&&arguments[2],i=void 0;return function(o){function u(){r||t.apply(f,s),i=null}var c=a(o),s=c,f=this;i?clearTimeout(i):r&&t.apply.apply(t,[f].concat(n(s))),i=setTimeout(u,e||100)}}},function(t,e,r){"use strict";e.a=function(t){console&&console.warn("vee-validate: "+t)}},function(t,e,r){"use strict";var n=r(2),a=r(1),i=r(4),o=r(3),u=r(0);r.d(e,"install",function(){return c});var c=function(t){var e=arguments.length<=1||void 0===arguments[1]?{locale:"en",delay:0,errorBagName:"errors",messages:null}:arguments[1],u=e.locale,c=e.delay,s=e.errorBagName,f=e.messages;f&&n.a.updateDictionary(f),n.a.setDefaultLocale(u);var l={locale:u,delay:c,messages:f,errorBagName:s};Object.defineProperties(t.prototype,{$validator:{get:function(){return r.i(a.b)(this)}}}),t.mixin(r.i(i.a)(l)),t.directive("validate",r.i(o.a)(l))};r.o(n,"a")&&r.d(e,"Validator",function(){return n.a}),r.o(u,"a")&&r.d(e,"ErrorBag",function(){return u.a})}])});
!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.VeeValidate=e():t.VeeValidate=e()}(this,function(){return function(t){function e(n){if(r[n])return r[n].exports;var i=r[n]={i:n,l:!1,exports:{}};return t[n].call(i.exports,i,i.exports,e),i.l=!0,i.exports}var r={};return e.m=t,e.c=r,e.i=function(t){return t},e.d=function(t,e,r){Object.defineProperty(t,e,{configurable:!1,enumerable:!0,get:r})},e.n=function(t){var r=t&&t.__esModule?function(){return t["default"]}:function(){return t};return e.d(r,"a",r),r},e.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},e.p="",e(e.s=33)}([function(t,e,r){"use strict";function n(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}var i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol?"symbol":typeof t},a=function(){function t(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}return function(e,r,n){return r&&t(e.prototype,r),n&&t(e,n),e}}(),o=function(){function t(){n(this,t),this.errors=[]}return a(t,[{key:"add",value:function(t,e){this.errors.push({field:t,msg:e})}},{key:"all",value:function(){return this.errors.map(function(t){return t.msg})}},{key:"any",value:function(){return!!this.errors.length}},{key:"clear",value:function(){this.errors=[]}},{key:"collect",value:function(t){var e=this;if(!t){var r=function(){var t={};return e.errors.forEach(function(e){t[e.field]||(t[e.field]=[]),t[e.field].push(e.msg)}),{v:t}}();if("object"===("undefined"==typeof r?"undefined":i(r)))return r.v}return this.errors.filter(function(e){return e.field===t}).map(function(t){return t.msg})}},{key:"count",value:function(){return this.errors.length}},{key:"first",value:function(t){for(var e=0;e<this.errors.length;e++)if(this.errors[e].field===t)return this.errors[e].msg;return null}},{key:"has",value:function(t){for(var e=0;e<this.errors.length;e++)if(this.errors[e].field===t)return!0;return!1}},{key:"remove",value:function(t){this.errors=this.errors.filter(function(e){return e.field!==t})}}]),t}();e.a=o},function(t,e,r){"use strict";var n=r(2);r.d(e,"b",function(){return o}),r.d(e,"a",function(){return u});var i=[],a=function(t){for(var e=0;e<i.length;e++)if(i[e].$vm===t)return i[e].$validator},o=function(t){var e=a(t);return e||(e=n.a.create(void 0,t),i.push({$vm:t,$validator:e})),e},u=function(t){for(var e=0;e<i.length;e++)if(i[e].$vm===t)return i.splice(e,1),!0;return!1}},function(t,e,r){"use strict";function n(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}var i=r(20),a=r(0),o=r(5),u=r(7),c=r(32),s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol?"symbol":typeof t},f=function(){function t(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}return function(e,r,n){return r&&t(e.prototype,r),n&&t(e,n),e}}(),l="veeValidate",v="en",d=function(){function t(e,r){n(this,t),this.locale=v,this.$fields=this._normalize(e),this.errorBag=new a.a,this.$vm=r}return f(t,[{key:"setLocale",value:function(t){u.a[t]||r.i(c.a)("You are setting the validator locale to a locale that is not defined in the dicitionary. English messages may still be generated."),this.locale=t}},{key:"attach",value:function(t,e){var r=this,n=arguments.length<=2||void 0===arguments[2]?null:arguments[2];this.$fields[t]||(this.$fields[t]={}),this.$fields[t].validations=[],this.errorBag.remove(t),e.split("|").forEach(function(e){r.$fields[t].validations.push(r._normalizeRule(e))}),n&&(this.$fields[t].name=n)}},{key:"updateDictionary",value:function(e){t.updateDictionary(e)}},{key:"detach",value:function(t){delete this.$fields[t]}},{key:"extend",value:function(e,r){t.extend(e,r)}},{key:"validateAll",value:function(t){var e=this;if(this.errorBag.clear(),this.$vm&&!this.values)return void this.$vm.$emit(l);var r=!0;return Object.keys(t).forEach(function(n){r=e.validate(n,t[n])}),r}},{key:"validate",value:function(t,e){var n=this;if(!this.$fields[t])return r.i(c.a)('You are trying to validate a non-existant field. Use "attach()" first.'),!1;var i=!0;return this.errorBag.remove(t),this.$fields[t].validations.forEach(function(r){i=n._test(t,e,r)}),i}},{key:"_normalize",value:function(t){var e=this;if(!t)return{};var r={};return Object.keys(t).forEach(function(n){t[n].split("|").forEach(function(t){r[n]||(r[n]={validations:[]}),r[n].validations.push(e._normalizeRule(t))})}),r}},{key:"_normalizeRule",value:function(t){var e=[];return~t.indexOf(":")&&(e=t.split(":")[1].split(",")),{name:t.split(":")[0],params:e}}},{key:"_formatErrorMessage",value:function(t,e){return u.a[this.locale]&&"function"==typeof u.a[this.locale][e.name]?u.a[this.locale][e.name](t,e.params):u.a.en[e.name](t,e.params)}},{key:"_test",value:function(t,e,r){var n=this,a=i.a[r.name],o=a(e,r.params),u=this.$fields[t].name||t;return o instanceof Promise?o.then(function(e){var i=e.reduce(function(t,e){return t&&e.valid},!0);return i||n.errorBag.add(t,n._formatErrorMessage(u,r)),i}):(o||this.errorBag.add(t,this._formatErrorMessage(u,r)),o)}},{key:"getErrors",value:function(){return this.errorBag}}],[{key:"setDefaultLocale",value:function(){var t=arguments.length<=0||void 0===arguments[0]?"en":arguments[0];u.a[t]||r.i(c.a)("You are setting the validator locale to a locale that is not defined in the dicitionary. English messages may still be generated."),v=t}},{key:"updateDictionary",value:function(t){Object.keys(t).forEach(function(e){u.a[e]||(u.a[e]={}),Object.keys(t[e]).forEach(function(r){u.a[e][r]=t[e][r]})})}},{key:"create",value:function(e,r){return new t(e,r)}},{key:"extend",value:function(e,r){t._guardExtend(e,r),t._merge(e,r)}},{key:"_merge",value:function(t,e){return"function"==typeof e?(i.a[t]=e,void(u.a.en[t]=function(t){return"The "+t+" value is not valid."})):(i.a[t]=e.validate,e.getMessage&&"function"==typeof e.getMessage&&(u.a.en[t]=e.getMessage),void(e.messages&&Object.keys(e.messages).forEach(function(r){u.a[r]||(u.a[r]={}),u.a[r][t]=e.messages[r]})))}},{key:"_guardExtend",value:function(t,e){if(i.a[t])throw new o.a("Extension Error: There is an existing validator with the same name '"+t+"'.");if("function"!=typeof e){if("function"!=typeof e.validate)throw new o.a("Extension Error: The validator '"+t+"' must be a function or have a 'validate' method.");if("function"!=typeof e.getMessage&&"object"!==s(e.messages))throw new o.a("Extension Error: The validator '"+t+"' must have a 'getMessage' method or have a 'messages' object.")}}}]),t}();e.a=d},function(t,e,r){"use strict";var n=r(31),i=[],a="veeValidate",o=function(t,e,r){var n=e.expression,i=r.context;return function(){i.$validator.validate(n||t.name,t.value)}},u=function(t,e,r){var n=e.modifiers,i=e.expression,a=r.context;return function(){!a.$validator.validate(i||t.name,t.files)&&n.reject&&(t.value="")}},c=function(t,e,r){var n=e.expression,u=e.value,c=r.context,s=void 0;s=n?o(t,{expression:n},{context:c}):function(){return c.$validator.validate(n||t.name,u)},i.push({vm:c,event:"validatorEvent",callback:s,el:t}),c.$on(a,s)};e.a=function(t){return{bind:function(e,a,s){var f=s.context;if(f.$validator.attach(a.expression||e.name,e.dataset.rules,e.dataset.as),c(e,a,{context:f}),a.expression&&!a.modifiers.initial)return void f.$validator.validate(a.expression,a.value);var l="file"===e.type?u(e,a,{context:f}):o(e,{},{context:f}),v=e.dataset.delay||t.delay;l=v?r.i(n.a)(l,v):l;var d="file"===e.type?"change":"input";e.addEventListener(d,l),i.push({vm:f,event:d,callback:l,el:e}),e.dataset.rules&&~e.dataset.rules.indexOf("confirmed")&&!function(){var t=e.dataset.rules.split("|").filter(function(t){return!!~t.indexOf("confirmed")})[0].split(":")[1];f.$once("validatorReady",function(){document.querySelector("input[name='"+t+"']").addEventListener("input",l)})}()},update:function(t,e,r){var n=e.expression,i=e.value,a=(e.modifiers,e.oldValue),o=r.context;n&&i!==a&&o.$validator.validate(n||t.name,i)},unbind:function(t,e,r){var n=r.context,o=i.filter(function(e){return e.vm===n&&e.el===t});n.$off(a,o.filter(function(t){var e=t.event;return"validatorEvent"===e})[0]),o.filter(function(t){var e=t.event;return"validatorEvent"!==e}).forEach(function(e){t.removeEventListener(e.event,e.callback)})}}}},function(t,e,r){"use strict";function n(t,e,r){return e in t?Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}):t[e]=r,t}var i=r(1);e.a=function(t){return{data:function(){return n({},t.errorBagName,this.$validator.errorBag)},mounted:function(){this.$emit("validatorReady")},destroyed:function(){r.i(i.a)(this)}}}},function(t,e,r){"use strict";function n(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}var i=function(){function t(t,e){for(var r=0;r<e.length;r++){var n=e[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(t,n.key,n)}}return function(e,r,n){return r&&t(e.prototype,r),n&&t(e,n),e}}(),a=function(){function t(e){n(this,t),this.msg=e}return i(t,[{key:"toString",value:function(){return this.msg}}]),t}();e.a=a},function(t,e,r){"use strict";var n=function(){function t(t,e){var r=[],n=!0,i=!1,a=void 0;try{for(var o,u=t[Symbol.iterator]();!(n=(o=u.next()).done)&&(r.push(o.value),!e||r.length!==e);n=!0);}catch(c){i=!0,a=c}finally{try{!n&&u["return"]&&u["return"]()}finally{if(i)throw a}}return r}return function(e,r){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,r);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}();e.a={alpha_dash:function(t){return"The "+t+" may contain alpha-numeric characters as well as dashes and underscores."},alpha_num:function(t){return"The "+t+" may only contain alpha-numeric characters."},alpha:function(t){return"The "+t+" may only contain alphabetic characters."},between:function(t,e){var r=n(e,2),i=r[0],a=r[1];return"The "+t+" must be between "+i+" and "+a+"."},confirmed:function(t,e){var r=n(e,1),i=r[0];return"The "+t+" does not match the "+i+"."},decimal:function(t){var e=arguments.length<=1||void 0===arguments[1]?["*"]:arguments[1],r=n(e,1),i=r[0];return"The "+t+" must be numeric and may contain "+("*"===i?"":i)+" decimal points."},digits:function(t,e){var r=n(e,1),i=r[0];return"The "+t+" must be numeric and exactly contain "+i+" digits."},dimensions:function(t,e){var r=n(e,2),i=r[0],a=r[1];return"The "+t+" must be "+i+" pixels by "+a+" pixels."},email:function(t){return"The "+t+" must be a valid email."},ext:function(t){return"The "+t+" must be a valid file."},image:function(t){return"The "+t+" must be an image."},"in":function(t){return"The "+t+" must be a valid value."},ip:function(t){return"The "+t+" must be a valid ip address."},max:function(t,e){var r=n(e,1),i=r[0];return"The "+t+" may not be greater than "+i+" characters."},mimes:function(t){return"The "+t+" must have a valid file type."},min:function(t,e){var r=n(e,1),i=r[0];return"The "+t+" must be at least "+i+" characters."},not_in:function(t){return"The "+t+" must be a valid value."},numeric:function(t){return"The "+t+" may only contain numeric characters."},regex:function(t){return"The "+t+" format is invalid."},required:function(t){return"The "+t+" is required."},size:function(t,e){var r=n(e,1),i=r[0];return"The "+t+" must be less than "+i+" KB."},url:function(t){return"The "+t+" is not a valid URL."}}},function(t,e,r){"use strict";var n=r(6);e.a={en:n.a}},function(t,e,r){"use strict";e.a=function(t){return!Array.isArray(t)&&/^[a-zA-Z]*$/.test(t)}},function(t,e,r){"use strict";e.a=function(t){return!Array.isArray(t)&&/^[a-zA-Z0-9_-]*$/.test(t)}},function(t,e,r){"use strict";e.a=function(t){return!Array.isArray(t)&&/^[a-zA-Z0-9]*$/.test(t)}},function(t,e,r){"use strict";var n=function(){function t(t,e){var r=[],n=!0,i=!1,a=void 0;try{for(var o,u=t[Symbol.iterator]();!(n=(o=u.next()).done)&&(r.push(o.value),!e||r.length!==e);n=!0);}catch(c){i=!0,a=c}finally{try{!n&&u["return"]&&u["return"]()}finally{if(i)throw a}}return r}return function(e,r){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,r);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}();e.a=function(t,e){var r=n(e,2),i=r[0],a=r[1];return Number(i)<=t&&Number(a)>=t}},function(t,e,r){"use strict";var n=function(){function t(t,e){var r=[],n=!0,i=!1,a=void 0;try{for(var o,u=t[Symbol.iterator]();!(n=(o=u.next()).done)&&(r.push(o.value),!e||r.length!==e);n=!0);}catch(c){i=!0,a=c}finally{try{!n&&u["return"]&&u["return"]()}finally{if(i)throw a}}return r}return function(e,r){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,r);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}();e.a=function(t,e){var r=n(e,1),i=r[0],a=document.querySelector("input[name='"+i+"']");return!(!a||String(t)!==a.value)}},function(t,e,r){"use strict";var n=function(){function t(t,e){var r=[],n=!0,i=!1,a=void 0;try{for(var o,u=t[Symbol.iterator]();!(n=(o=u.next()).done)&&(r.push(o.value),!e||r.length!==e);n=!0);}catch(c){i=!0,a=c}finally{try{!n&&u["return"]&&u["return"]()}finally{if(i)throw a}}return r}return function(e,r){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,r);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}();e.a=function(t){var e=arguments.length<=1||void 0===arguments[1]?["*"]:arguments[1],r=n(e,1),i=r[0];if(Array.isArray(t))return!1;if(null===t||void 0===t||""===t)return!0;var a="*"===i?"*":"{0,"+i+"}",o=new RegExp("^[0-9]*.?[0-9]"+a+"$");return!!o.test(t)&&!Number.isNaN(parseFloat(t))}},function(t,e,r){"use strict";var n=function(){function t(t,e){var r=[],n=!0,i=!1,a=void 0;try{for(var o,u=t[Symbol.iterator]();!(n=(o=u.next()).done)&&(r.push(o.value),!e||r.length!==e);n=!0);}catch(c){i=!0,a=c}finally{try{!n&&u["return"]&&u["return"]()}finally{if(i)throw a}}return r}return function(e,r){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,r);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}();e.a=function(t,e){var r=n(e,1),i=r[0],a=String(t);return/^[0-9]*$/.test(a)&&a.length===Number(i)}},function(t,e,r){"use strict";var n=function(){function t(t,e){var r=[],n=!0,i=!1,a=void 0;try{for(var o,u=t[Symbol.iterator]();!(n=(o=u.next()).done)&&(r.push(o.value),!e||r.length!==e);n=!0);}catch(c){i=!0,a=c}finally{try{!n&&u["return"]&&u["return"]()}finally{if(i)throw a}}return r}return function(e,r){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,r);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),i=function(t,e,r){var n=window.URL||window.webkitURL;return new Promise(function(i){var a=new Image;a.onerror=function(){return i({name:t.name,valid:!1})},a.onload=function(){var n=a.width===Number(e)&&a.height===Number(r);i({name:t.name,valid:n})},a.src=n.createObjectURL(t)})};e.a=function(t,e){for(var r=n(e,2),a=r[0],o=r[1],u=[],c=0;c<t.length;c++){if(!/\.(jpg|svg|jpeg|png|bmp|gif)$/i.test(t[c].name))return!1;u.push(t[c])}return Promise.all(u.map(function(t){return i(t,a,o)}))}},function(t,e,r){"use strict";e.a=function(t){return/^[a-zA-Z0-9._-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,6}$/.test(t)}},function(t,e,r){"use strict";e.a=function(t,e){for(var r=new RegExp(".("+e.join("|")+")$","i"),n=0;n<t.length;n++)if(!r.test(t[n].name))return!1;return!0}},function(t,e,r){"use strict";e.a=function(t){for(var e=0;e<t.length;e++)if(!/\.(jpg|svg|jpeg|png|bmp|gif)$/i.test(t[e].name))return!1;return!0}},function(t,e,r){"use strict";e.a=function(t,e){return!!e.filter(function(e){return e==t}).length}},function(t,e,r){"use strict";var n=r(16),i=r(19),a=r(28),o=r(24),u=r(22),c=r(25),s=r(8),f=r(10),l=r(9),v=r(26),d=r(27),h=r(21),y=r(17),m=r(23),p=r(29),g=r(14),b=r(18),w=r(15),x=r(11),E=r(12),A=r(30),$=r(13);e.a={email:n.a,min:o.a,max:u.a,required:a.a,"in":i.a,not_in:c.a,alpha:s.a,alpha_num:f.a,alpha_dash:l.a,numeric:v.a,regex:d.a,ip:h.a,ext:y.a,mimes:m.a,size:p.a,digits:g.a,image:b.a,dimensions:w.a,between:x.a,confirmed:E.a,url:A.a,decimal:$.a}},function(t,e,r){"use strict";e.a=function(t){return/^(?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.){3}(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)$/.test(t)}},function(t,e,r){"use strict";var n=function(){function t(t,e){var r=[],n=!0,i=!1,a=void 0;try{for(var o,u=t[Symbol.iterator]();!(n=(o=u.next()).done)&&(r.push(o.value),!e||r.length!==e);n=!0);}catch(c){i=!0,a=c}finally{try{!n&&u["return"]&&u["return"]()}finally{if(i)throw a}}return r}return function(e,r){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,r);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}();e.a=function(t,e){var r=n(e,1),i=r[0];return void 0===t||null===t?i>=0:String(t).length<=i}},function(t,e,r){"use strict";e.a=function(t,e){for(var r=new RegExp(e.join("|").replace("*",".+")+"$","i"),n=0;n<t.length;n++)if(!r.test(t[n].type))return!1;return!0}},function(t,e,r){"use strict";var n=function(){function t(t,e){var r=[],n=!0,i=!1,a=void 0;try{for(var o,u=t[Symbol.iterator]();!(n=(o=u.next()).done)&&(r.push(o.value),!e||r.length!==e);n=!0);}catch(c){i=!0,a=c}finally{try{!n&&u["return"]&&u["return"]()}finally{if(i)throw a}}return r}return function(e,r){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,r);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}();e.a=function(t,e){var r=n(e,1),i=r[0];return void 0!==t&&null!==t&&String(t).length>=i}},function(t,e,r){"use strict";e.a=function(t,e){return!e.filter(function(e){return e==t}).length}},function(t,e,r){"use strict";e.a=function(t){return!Array.isArray(t)&&/^[0-9]*$/.test(t)}},function(t,e,r){"use strict";function n(t){return Array.isArray(t)?t:Array.from(t)}e.a=function(t,e){var r=n(e),i=r[0],a=r.slice(1);return new RegExp(i,a).test(String(t))}},function(t,e,r){"use strict";e.a=function(t){return Array.isArray(t)?!!t.length:void 0!==t&&null!==t&&!!String(t).length}},function(t,e,r){"use strict";var n=function(){function t(t,e){var r=[],n=!0,i=!1,a=void 0;try{for(var o,u=t[Symbol.iterator]();!(n=(o=u.next()).done)&&(r.push(o.value),!e||r.length!==e);n=!0);}catch(c){i=!0,a=c}finally{try{!n&&u["return"]&&u["return"]()}finally{if(i)throw a}}return r}return function(e,r){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,r);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}();e.a=function(t,e){var r=n(e,1),i=r[0];if(isNaN(i))return!1;for(var a=1024*Number(i),o=0;o<t.length;o++)if(t[o].size>a)return!1;return!0}},function(t,e,r){"use strict";e.a=function(t,e){var r=/^https?:\/\/([\da-z\.-]+)\.([a-z\.]{2,6})([\/\w\.\(\)%-]*)*\/?$/.test(t),n=e&&e[0];return n&&r?new RegExp("^https?://(([da-z.-]+).)*("+e[0].replace(".","\\$&")+")").test(t):r}},function(t,e,r){"use strict";function n(t){if(Array.isArray(t)){for(var e=0,r=Array(t.length);e<t.length;e++)r[e]=t[e];return r}return Array.from(t)}function i(t){return Array.isArray(t)?t:Array.from(t)}e.a=function(t){var e=arguments.length<=1||void 0===arguments[1]?100:arguments[1],r=!(arguments.length<=2||void 0===arguments[2])&&arguments[2],a=void 0;return function(o){function u(){r||t.apply(f,s),a=null}var c=i(o),s=c,f=this;a?clearTimeout(a):r&&t.apply.apply(t,[f].concat(n(s))),a=setTimeout(u,e||100)}}},function(t,e,r){"use strict";e.a=function(t){console&&console.warn("vee-validate: "+t)}},function(t,e,r){"use strict";var n=r(2),i=r(1),a=r(4),o=r(3),u=r(0);r.d(e,"install",function(){return c});var c=function(t){var e=arguments.length<=1||void 0===arguments[1]?{locale:"en",delay:0,errorBagName:"errors",messages:null}:arguments[1],u=e.locale,c=e.delay,s=e.errorBagName,f=e.messages;f&&n.a.updateDictionary(f),n.a.setDefaultLocale(u);var l={locale:u,delay:c,messages:f,errorBagName:s};Object.defineProperties(t.prototype,{$validator:{get:function(){return r.i(i.b)(this)}}}),t.mixin(r.i(a.a)(l)),t.directive("validate",r.i(o.a)(l))};r.o(n,"a")&&r.d(e,"Validator",function(){return n.a}),r.o(u,"a")&&r.d(e,"ErrorBag",function(){return u.a})}])});
{
"name": "vee-validate",
"version": "2.0.0-beta.3",
"version": "2.0.0-beta.4",
"description": "Simple VueJS input validation plugin",

@@ -5,0 +5,0 @@ "main": "dist/vee-validate.js",

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc