Permalink
Browse files

Mask: add visual display of field's value and validity in visual test…

… case
  • Loading branch information...
1 parent 9d038dd commit 26c18642135df237fa60e06f328d6c3bb9ef8850 Zach Shepherd committed Oct 15, 2012
Showing with 10 additions and 0 deletions.
  1. +10 −0 tests/visual/mask/mask.html
@@ -50,6 +50,16 @@
}
});
+ $("input").each(function( index, value ) {
+ var span = $("<span></span>");
+
+ value = $(value);
+ value.after(span);
+ value.keyup(function(event) {
+ span.text("Value: " + $(event.target).mask('value') + " Valid: " + $(event.target).mask('valid'));
+ });
+ });
+
function sixty( value ) {
value = parseInt( value, 10 );
if ( value >= 0 && value <= 59 ) {

0 comments on commit 26c1864

Please sign in to comment.