Skip to content

Commit 26c1864

Browse files
author
Zach Shepherd
committed
Mask: add visual display of field's value and validity in visual test case
1 parent 9d038dd commit 26c1864

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

tests/visual/mask/mask.html

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,16 @@
5050
}
5151
});
5252

53+
$("input").each(function( index, value ) {
54+
var span = $("<span></span>");
55+
56+
value = $(value);
57+
value.after(span);
58+
value.keyup(function(event) {
59+
span.text("Value: " + $(event.target).mask('value') + " Valid: " + $(event.target).mask('valid'));
60+
});
61+
});
62+
5363
function sixty( value ) {
5464
value = parseInt( value, 10 );
5565
if ( value >= 0 && value <= 59 ) {

0 commit comments

Comments
 (0)