Robin Herbots 12 years ago
parent
commit
2aab746e28

+ 1 - 1
build.properties

@@ -7,7 +7,7 @@ distdir = dist
 
 build.major = 2
 build.minor = 4
-build.revision = 2
+build.revision = 3
 
 target = jquery.inputmask.bundle.js
 target.min = jquery.inputmask.bundle.min.js

+ 1 - 1
component.json

@@ -1,6 +1,6 @@
 {
     "name": "jquery.inputmask",
-    "version": "2.4.2",
+    "version": "2.4.3",
     "main": "./dist/jquery.inputmask.bundle.js",
     "dependencies": {
         "jquery": ">=1.7"

BIN
dist/jQuery.InputMask.2.4.2.nupkg


BIN
dist/jQuery.InputMask.2.4.3.nupkg


+ 10 - 9
dist/jquery.inputmask.bundle.js

@@ -3,7 +3,7 @@
 * http://github.com/RobinHerbots/jquery.inputmask
 * Copyright (c) 2010 - 2013 Robin Herbots
 * Licensed under the MIT license (http://www.opensource.org/licenses/mit-license.php)
-* Version: 2.4.2
+* Version: 2.4.3
 */
 
 (function ($) {
@@ -325,7 +325,6 @@
                 var maskTokens = [];
                 function analyseMask(mask) { //just an idea - not in use for the moment
                     var tokenizer = /(?:[?*+]|\{[0-9]+(?:,[0-9]*)?\})\??|[^.?*+^${[]()|\\]+|./g;
-                    //var tokenizer = /\[\^?]?(?:[^\\\]]+ | \\[\S\s]?)*]? | \\(?:0(?:[0-3][0-7]{0,2} | [4-7][0-7]?)? | [1-9][0-9]* | x[0-9A-Fa-f]{2} | u[0-9A-Fa-f]{4} | c[A-Za-z] | [\S\s]?) | \((?:\?[:=!]?)? | (?:[?*+] | \{[0-9]+(?:,[0-9]*)?\})\?? | [^.?*+^${[() | \\]+ | ./g;
                     function maskToken() {
                         this.matches = [];
                         this.isGroup = false;
@@ -349,7 +348,7 @@
                                     openenings[openenings.length - 1]["matches"].push(openingToken);
                                 } else {
                                     maskTokens.push(openingToken);
-                                    currentToken = new maskToken();
+                                    currentToken = openingToken; //new maskToken();
                                 }
                                 break;
                             case opts.optionalmarker.start:
@@ -383,6 +382,8 @@
                                 if (openenings.length > 0) {
                                     openenings[openenings.length - 1]["matches"].push(m);
                                 } else {
+                                    if (currentToken.isGroup || currentToken.isOptional)
+                                        currentToken = new maskToken();
                                     currentToken.matches.push(m);
                                 }
                         }
@@ -1435,7 +1436,7 @@
                         } else if ((k == opts.keyCode.HOME && !e.shiftKey) || k == opts.keyCode.PAGE_UP) { //Home or page_up
                             caret(input, 0, e.shiftKey ? pos.begin : 0);
                         } else if (k == opts.keyCode.ESCAPE || (k == 90 && e.ctrlKey)) { //escape && undo
-                            checkVal(input, true, false, valueOnFocus);
+                            checkVal(input, true, false, valueOnFocus.split(''));
                             $input.click();
                         } else if (k == opts.keyCode.INSERT && !(e.shiftKey || e.ctrlKey)) { //insert
                             opts.insertMode = !opts.insertMode;
@@ -1645,7 +1646,7 @@ Input Mask plugin extensions
 http://github.com/RobinHerbots/jquery.inputmask
 Copyright (c) 2010 - 2013 Robin Herbots
 Licensed under the MIT license (http://www.opensource.org/licenses/mit-license.php)
-Version: 2.4.2
+Version: 2.4.3
 
 Optional extensions on the jquery.inputmask base
 */
@@ -1767,7 +1768,7 @@ Input Mask plugin extensions
 http://github.com/RobinHerbots/jquery.inputmask
 Copyright (c) 2010 - 2012 Robin Herbots
 Licensed under the MIT license (http://www.opensource.org/licenses/mit-license.php)
-Version: 2.4.2
+Version: 2.4.3
 
 Optional extensions on the jquery.inputmask base
 */
@@ -2251,7 +2252,7 @@ Input Mask plugin extensions
 http://github.com/RobinHerbots/jquery.inputmask
 Copyright (c) 2010 - 2013 Robin Herbots
 Licensed under the MIT license (http://www.opensource.org/licenses/mit-license.php)
-Version: 2.4.2
+Version: 2.4.3
 
 Optional extensions on the jquery.inputmask base
 */
@@ -2428,7 +2429,7 @@ Input Mask plugin extensions
 http://github.com/RobinHerbots/jquery.inputmask
 Copyright (c) 2010 - 2013 Robin Herbots
 Licensed under the MIT license (http://www.opensource.org/licenses/mit-license.php)
-Version: 2.4.2
+Version: 2.4.3
 
 Regex extensions on the jquery.inputmask base
 Allows for using regular expressions as a mask
@@ -2598,7 +2599,7 @@ Input Mask plugin extensions
 http://github.com/RobinHerbots/jquery.inputmask
 Copyright (c) 2010 - 2013 Robin Herbots
 Licensed under the MIT license (http://www.opensource.org/licenses/mit-license.php)
-Version: 2.4.2
+Version: 2.4.3
 
 Phone extension.
 When using this extension make sure you specify the correct url to get the masks

File diff suppressed because it is too large
+ 29 - 29
dist/jquery.inputmask.bundle.min.js


File diff suppressed because it is too large
+ 32 - 32
dist/min/jquery.inputmask.js


+ 1 - 1
jquery.inputmask.jquery.json

@@ -8,7 +8,7 @@
 		"inputmask",
 		"mask"
     ],
-    "version": "2.4.2",
+    "version": "2.4.3",
     "author": {
         "name": "Robin Herbots",
         "url": "http://github.com/RobinHerbots/jquery.inputmask"