Upgrade jquery validate
This commit is contained in:
@@ -806,9 +806,9 @@
|
||||
<Content Include="scripts\jquery.validate.min.js" />
|
||||
<Content Include="scripts\jquery.validate.unobtrusive.bootstrap.js" />
|
||||
<Content Include="scripts\jquery.validate.unobtrusive.bootstrap.min.js" />
|
||||
<Content Include="scripts\jquery.validate.custom.js" />
|
||||
<Content Include="scripts\jquery.validate.unobtrusive.js" />
|
||||
<Content Include="scripts\jquery.validate.unobtrusive.min.js" />
|
||||
<Content Include="scripts\jquery.validate.custom.js" />
|
||||
<Content Include="scripts\LeafInputCreate.js" />
|
||||
<Content Include="scripts\popper-utils.js" />
|
||||
<Content Include="scripts\popper-utils.min.js" />
|
||||
|
||||
@@ -44,7 +44,7 @@
|
||||
<package id="Microsoft.CodeAnalysis.CSharp" version="1.0.0" targetFramework="net452" />
|
||||
<package id="Microsoft.CodeDom.Providers.DotNetCompilerPlatform" version="2.0.1" targetFramework="net452" />
|
||||
<package id="Microsoft.IO.RecyclableMemoryStream" version="1.2.2" targetFramework="net452" />
|
||||
<package id="Microsoft.jQuery.Unobtrusive.Validation" version="3.2.3" targetFramework="net452" />
|
||||
<package id="Microsoft.jQuery.Unobtrusive.Validation" version="3.2.11" targetFramework="net452" />
|
||||
<package id="Microsoft.Net.Compilers" version="1.0.0" targetFramework="net452" developmentDependency="true" />
|
||||
<package id="Microsoft.NETCore.Platforms" version="1.1.0" targetFramework="net452" />
|
||||
<package id="Microsoft.Owin" version="4.1.0" targetFramework="net452" />
|
||||
|
||||
+32
-29
@@ -1,26 +1,23 @@
|
||||
/* NUGET: BEGIN LICENSE TEXT
|
||||
*
|
||||
* Microsoft grants you the right to use these script files for the sole
|
||||
* purpose of either: (i) interacting through your browser with the Microsoft
|
||||
* website or online service, subject to the applicable licensing or use
|
||||
* terms; or (ii) using the files as included with a Microsoft product subject
|
||||
* to that product's license terms. Microsoft reserves all other rights to the
|
||||
* files not expressly granted by Microsoft, whether by implication, estoppel
|
||||
* or otherwise. Insofar as a script file is dual licensed under GPL,
|
||||
* Microsoft neither took the code under GPL nor distributes it thereunder but
|
||||
* under the terms set out in this paragraph. All notices and licenses
|
||||
* below are for informational purposes only.
|
||||
*
|
||||
* NUGET: END LICENSE TEXT */
|
||||
/*!
|
||||
** Unobtrusive validation support library for jQuery and jQuery Validate
|
||||
** Copyright (C) Microsoft Corporation. All rights reserved.
|
||||
*/
|
||||
// Unobtrusive validation support library for jQuery and jQuery Validate
|
||||
// Copyright (c) .NET Foundation. All rights reserved.
|
||||
// Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information.
|
||||
// @version v3.2.11
|
||||
|
||||
/*jslint white: true, browser: true, onevar: true, undef: true, nomen: true, eqeqeq: true, plusplus: true, bitwise: true, regexp: true, newcap: true, immed: true, strict: false */
|
||||
/*global document: false, jQuery: false */
|
||||
|
||||
(function ($) {
|
||||
(function (factory) {
|
||||
if (typeof define === 'function' && define.amd) {
|
||||
// AMD. Register as an anonymous module.
|
||||
define("jquery.validate.unobtrusive", ['jquery-validation'], factory);
|
||||
} else if (typeof module === 'object' && module.exports) {
|
||||
// CommonJS-like environments that support module.exports
|
||||
module.exports = factory(require('jquery-validation'));
|
||||
} else {
|
||||
// Browser global
|
||||
jQuery.validator.unobtrusive = factory(jQuery);
|
||||
}
|
||||
}(function ($) {
|
||||
var $jQval = $.validator,
|
||||
adapters,
|
||||
data_validation = "unobtrusiveValidation";
|
||||
@@ -84,11 +81,12 @@
|
||||
}
|
||||
|
||||
function onSuccess(error) { // 'this' is the form element
|
||||
var container = error.data("unobtrusiveContainer"),
|
||||
replaceAttrValue = container.attr("data-valmsg-replace"),
|
||||
replace = replaceAttrValue ? $.parseJSON(replaceAttrValue) : null;
|
||||
var container = error.data("unobtrusiveContainer");
|
||||
|
||||
if (container) {
|
||||
var replaceAttrValue = container.attr("data-valmsg-replace"),
|
||||
replace = replaceAttrValue ? $.parseJSON(replaceAttrValue) : null;
|
||||
|
||||
container.addClass("field-validation-valid").removeClass("field-validation-error");
|
||||
error.removeData("unobtrusiveContainer");
|
||||
|
||||
@@ -120,7 +118,7 @@
|
||||
.removeClass("field-validation-error")
|
||||
.removeData("unobtrusiveContainer")
|
||||
.find(">*") // If we were using valmsg-replace, get the underlying error
|
||||
.removeData("unobtrusiveContainer");
|
||||
.removeData("unobtrusiveContainer");
|
||||
}
|
||||
|
||||
function validationInfo(form) {
|
||||
@@ -131,7 +129,7 @@
|
||||
execInContext = function (name, args) {
|
||||
var func = defaultOptions[name];
|
||||
func && $.isFunction(func) && func.apply(form, args);
|
||||
}
|
||||
};
|
||||
|
||||
if (!result) {
|
||||
result = {
|
||||
@@ -236,10 +234,10 @@
|
||||
// element with data-val=true
|
||||
var $selector = $(selector),
|
||||
$forms = $selector.parents()
|
||||
.addBack()
|
||||
.filter("form")
|
||||
.add($selector.find("form"))
|
||||
.has("[data-val=true]");
|
||||
.addBack()
|
||||
.filter("form")
|
||||
.add($selector.find("form"))
|
||||
.has("[data-val=true]");
|
||||
|
||||
$selector.find("[data-val=true]").each(function () {
|
||||
$jQval.unobtrusive.parseElement(this, true);
|
||||
@@ -422,8 +420,13 @@
|
||||
setValidationValues(options, "regex", options.params.regex);
|
||||
}
|
||||
});
|
||||
adapters.add("fileextensions", ["extensions"], function (options) {
|
||||
setValidationValues(options, "extension", options.params.extensions);
|
||||
});
|
||||
|
||||
$(function () {
|
||||
$jQval.unobtrusive.parse(document);
|
||||
});
|
||||
}(jQuery));
|
||||
|
||||
return $jQval.unobtrusive;
|
||||
}));
|
||||
|
||||
+5
-19
File diff suppressed because one or more lines are too long
@@ -42,7 +42,7 @@
|
||||
$($el).height('auto');
|
||||
topPostion = $el.position().top;
|
||||
|
||||
if (currentRowStart != topPostion) {
|
||||
if (currentRowStart !== topPostion) {
|
||||
for (currentDiv = 0; currentDiv < rowDivs.length; currentDiv++) {
|
||||
rowDivs[currentDiv].height(currentTallest);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user