Permalink
Browse files

Mask: Visual Test

  • Loading branch information...
gnarf committed Aug 2, 2011
1 parent af9da8f commit a84baa575afed3e2f3ce3f59b80473bd593d0b2b
Showing with 52 additions and 0 deletions.
  1. +52 −0 tests/visual/mask/mask.html
@@ -0,0 +1,52 @@
+<!doctype html>
+<html>
+<head>
+ <title>Mask Visual Test: Default</title>
+ <link rel="stylesheet" href="../visual.css" type="text/css" />
+ <link rel="stylesheet" href="../../../themes/base/jquery.ui.all.css" type="text/css" title="ui-theme" />
+ <script src="../../../jquery-1.6.2.js"></script>
+ <script src="../../../ui/jquery.ui.core.js"></script>
+ <script src="../../../ui/jquery.ui.widget.js"></script>
+ <script src="../../../ui/jquery.ui.mask.js"></script>
+ <script>
+ $(function() {
+ $( "#mask1" ).mask({ mask: "99/99/9999" });
+ $( "#mask2" ).mask({ mask: "(999) 999-9999" });
+ $( "#mask3" ).mask({ mask: "(999) 999-9999?x999999" });
+ $( "#mask4" ).mask({ mask: "99-9999999" });
+ $( "#mask5" ).mask({ mask: "999-99-9999" });
+ $( "#mask6" ).mask({ mask: "a*-999-a999" });
+ $( "#mask7" ).mask({
+ mask: "~9.99 ~9.99 999",
+ definitions: {
+ "~": /\+|-/
+ }
+ });
+ });
+ </script>
+ <style>
+ label {
+ font-size: 14px;
+ display: block;
+ }
+ </style>
+</head>
+<body>
+ <form>
+ <label for="mask1">Date - 99/99/9999</label>
+ <input type="text" class="masked" id="mask1" data-maskoptions='{"mask":"99/99/9999"}'>
+ <label for="mask2">Phone - (999) 999-9999</label>
+ <input type="text" class="masked" id="mask2" data-maskoptions='{"mask":"(999) 999-9999"}'>
+ <label for="mask3">Phone - (999) 999-9999?x999999 - ? not yet implemented</label>
+ <input type="text" class="masked" id="mask3" data-maskoptions='{"mask":"(999) 999-9999?x999999"}'>
+ <label for="mask4">TaxID - 99-9999999</label>
+ <input type="text" class="masked" id="mask4" data-maskoptions='{"mask":"99-9999999"}'>
+ <label for="mask5">SSN - 999-99-9999</label>
+ <input type="text" class="masked" id="mask5" data-maskoptions='{"mask":"999-99-9999"}'>
+ <label for="mask6">Product Key - a*-999-a999</label>
+ <input type="text" class="masked" id="mask6" data-maskoptions='{"mask":"a*-999-a999"}'>
+ <label for="mask7">Eye Script - ~9.99 ~9.99 999</label>
+ <input type="text" class="masked" id="mask7" data-maskoptions='{"mask":"~9.99 ~9.99 999"}'>
+ </form>
+</body>
+</html>

0 comments on commit a84baa5

Please sign in to comment.