{"action":"created","issue":{"url":"https://api.github.com/repos/RobinHerbots/jquery.inputmask/issues/1173","labels_url":"https://api.github.com/repos/RobinHerbots/jquery.inputmask/issues/1173/labels{/name}","comments_url":"https://api.github.com/repos/RobinHerbots/jquery.inputmask/issues/1173/comments","events_url":"https://api.github.com/repos/RobinHerbots/jquery.inputmask/issues/1173/events","html_url":"https://github.com/RobinHerbots/jquery.inputmask/issues/1173","id":129529166,"number":1173,"title":"Is it possible to have mask with digits in range {min:1,max:100}","user":{"login":"surjit","id":927509,"avatar_url":"https://avatars.githubusercontent.com/u/927509?v=3","gravatar_id":"","url":"https://api.github.com/users/surjit","html_url":"https://github.com/surjit","followers_url":"https://api.github.com/users/surjit/followers","following_url":"https://api.github.com/users/surjit/following{/other_user}","gists_url":"https://api.github.com/users/surjit/gists{/gist_id}","starred_url":"https://api.github.com/users/surjit/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/surjit/subscriptions","organizations_url":"https://api.github.com/users/surjit/orgs","repos_url":"https://api.github.com/users/surjit/repos","events_url":"https://api.github.com/users/surjit/events{/privacy}","received_events_url":"https://api.github.com/users/surjit/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/RobinHerbots/jquery.inputmask/labels/Numerics","name":"Numerics","color":"e102d8"}],"state":"open","locked":false,"assignee":null,"milestone":{"url":"https://api.github.com/repos/RobinHerbots/jquery.inputmask/milestones/17","html_url":"https://github.com/RobinHerbots/jquery.inputmask/milestones/3.5","labels_url":"https://api.github.com/repos/RobinHerbots/jquery.inputmask/milestones/17/labels","id":1531061,"number":17,"title":"3.5","description":"Datetime alias","creator":{"login":"RobinHerbots","id":318447,"avatar_url":"https://avatars.githubusercontent.com/u/318447?v=3","gravatar_id":"","url":"https://api.github.com/users/RobinHerbots","html_url":"https://github.com/RobinHerbots","followers_url":"https://api.github.com/users/RobinHerbots/followers","following_url":"https://api.github.com/users/RobinHerbots/following{/other_user}","gists_url":"https://api.github.com/users/RobinHerbots/gists{/gist_id}","starred_url":"https://api.github.com/users/RobinHerbots/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/RobinHerbots/subscriptions","organizations_url":"https://api.github.com/users/RobinHerbots/orgs","repos_url":"https://api.github.com/users/RobinHerbots/repos","events_url":"https://api.github.com/users/RobinHerbots/events{/privacy}","received_events_url":"https://api.github.com/users/RobinHerbots/received_events","type":"User","site_admin":false},"open_issues":31,"closed_issues":1,"state":"open","created_at":"2016-01-21T14:08:06Z","updated_at":"2016-01-29T09:48:05Z","due_on":null,"closed_at":null},"comments":3,"created_at":"2016-01-28T18:07:52Z","updated_at":"2016-01-29T10:00:57Z","closed_at":null,"body":"is it possible to mask only digits in certain range {min:1,max:100}"},"comment":{"url":"https://api.github.com/repos/RobinHerbots/jquery.inputmask/issues/comments/176675652","html_url":"https://github.com/RobinHerbots/jquery.inputmask/issues/1173#issuecomment-176675652","issue_url":"https://api.github.com/repos/RobinHerbots/jquery.inputmask/issues/1173","id":176675652,"user":{"login":"RobinHerbots","id":318447,"avatar_url":"https://avatars.githubusercontent.com/u/318447?v=3","gravatar_id":"","url":"https://api.github.com/users/RobinHerbots","html_url":"https://github.com/RobinHerbots","followers_url":"https://api.github.com/users/RobinHerbots/followers","following_url":"https://api.github.com/users/RobinHerbots/following{/other_user}","gists_url":"https://api.github.com/users/RobinHerbots/gists{/gist_id}","starred_url":"https://api.github.com/users/RobinHerbots/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/RobinHerbots/subscriptions","organizations_url":"https://api.github.com/users/RobinHerbots/orgs","repos_url":"https://api.github.com/users/RobinHerbots/repos","events_url":"https://api.github.com/users/RobinHerbots/events{/privacy}","received_events_url":"https://api.github.com/users/RobinHerbots/received_events","type":"User","site_admin":false},"created_at":"2016-01-29T10:00:57Z","updated_at":"2016-01-29T10:00:57Z","body":"```\r\n\tInputmask.extendAliases({\r\n\t\t\t\"mynumeric\": {\r\n                                 alias: \"numeric\",\r\n                                 postValidation: function(buffer, currentResult, opts) {\r\n\t\t\t\t\tvar isValid = true,\r\n\t\t\t\t\t\tmaskedValue = opts.numericInput ? buffer.slice().reverse().join(\"\") : buffer.join(\"\"),\r\n\t\t\t\t\t\tprocessValue = maskedValue.replace(opts.prefix, \"\");\r\n\t\t\t\t\tprocessValue = processValue.replace(opts.suffix, \"\");\r\n\t\t\t\t\tprocessValue = processValue.replace(new RegExp(Inputmask.escapeRegex(opts.groupSeparator), \"g\"), \"\");\r\n\t\t\t\t\tif (opts.radixPoint === \",\") processValue = processValue.replace(Inputmask.escapeRegex(opts.radixPoint), \".\");\r\n\t\t\t\t\t//handle negation symbol\r\n\t\t\t\t\tprocessValue = processValue.replace(new RegExp(\"^\" + Inputmask.escapeRegex(opts.negationSymbol.front)), \"-\");\r\n\t\t\t\t\tprocessValue = processValue.replace(new RegExp(Inputmask.escapeRegex(opts.negationSymbol.back) + \"$\"), \"\");\r\n\t\t\t\t\tprocessValue = processValue === opts.negationSymbol.front ? processValue + \"0\" : processValue;\r\n\r\n\t\t\t\t\tif (isFinite(processValue)) {\r\n\t\t\t\t\t\r\n// ADD CODE TO CHECK THE MIN MAX FOR DIGITS\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\treturn isValid;\r\n\t\t\t\t}\r\n});\r\n\r\n```\r\n"}}