From 4ee820e98d2d471c6cb6fe76a63b830faa677e56 Mon Sep 17 00:00:00 2001 From: Gervasio Junior Date: Sun, 29 Nov 2015 18:04:23 -0300 Subject: [PATCH] Update foundation.abide.js password input fix --- js/foundation.abide.js | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/js/foundation.abide.js b/js/foundation.abide.js index e32a7af74..ff5317437 100644 --- a/js/foundation.abide.js +++ b/js/foundation.abide.js @@ -136,6 +136,14 @@ return true; } break; + case 'password': + if ($el.attr('required') && !$el.val()) { + // requirement check does not pass + return false; + } else { + return true; + } + break; case 'checkbox': if ($el.attr('required') && !$el.is(':checked')) { return false; @@ -222,6 +230,7 @@ Abide.prototype.validateInput = function($el, $form) { var self = this, textInput = $form.find('input[type="text"]'), + passwordInput = $form.find('input[type="password"]'), checkInput = $form.find('input[type="checkbox"]'), label, radioGroupName; -- 2.47.3