Skip to content

Commit b50346e

Browse files
Merge pull request #35 from global-source/dev
Improved Scroll feature.
2 parents b484955 + 591473e commit b50346e

File tree

3 files changed

+1066
-5
lines changed

3 files changed

+1066
-5
lines changed

src/demo/index3.html

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -88,8 +88,7 @@
8888
<button type="submit" name="btn-save" class="btn btn-default">Submit</button>
8989
</form>
9090
</div>
91-
<script src="./../js/formValidator.js"></script>
92-
<!--<script src="../js/formValidator.es6.min.js"></script>-->
91+
<script src="./../js/multi_formValidator.js"></script>
9392

9493
<script>
9594

@@ -106,12 +105,13 @@
106105
// }
107106
// });
108107

109-
var form = jsValidator.init({
108+
var form = new jsValidator();
109+
form.init({
110110
form: 'clientAdd',
111111
forceFilter: true,
112112
onChange: true,
113113
errorClass: '__error_cap',
114-
// log:true,
114+
log: true,
115115
message: {
116116
required: 'This field is required.',
117117
min: 'This field length is too low.',

src/js/formValidator.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -184,7 +184,7 @@ var jsValidator = {
184184
// Apply filter for Email elements.
185185
if (activeElem.type == 'email') jsFilter.email(activeElem);
186186
// Apply filter for Numeric elements.
187-
// if (activeElem.min || activeElem.max || activeElem.minLength || activeElem.maxLength) jsFilter.limit(activeElem);
187+
if (activeElem.min || activeElem.max || activeElem.minLength || activeElem.maxLength) jsFilter.limit(activeElem);
188188
// Apply filter File elements.
189189
if (activeElem.type == 'file') jsFilter.file(activeElem);
190190
// Apply filter with string, alphaNumeric and pregMatch.

0 commit comments

Comments
 (0)