Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

ngx-mask

Package Overview
Dependencies
Maintainers
1
Versions
255
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ngx-mask - npm Package Compare versions

Comparing version 7.4.0 to 7.4.1

14

bundles/ngx-mask.umd.js

@@ -671,2 +671,16 @@ (function (global, factory) {

var result = _super.prototype.applyMask.call(this, inputValue, maskExpression, position, cb);
if (this.maskExpression === 'dot_separator.2' && this.dropSpecialCharacters === true) {
this.maskSpecialCharacters = this.maskSpecialCharacters.filter(( /**
* @param {?} item
* @return {?}
*/function (item) { return item !== ','; }));
}
if ((this.maskExpression === 'coma_separator.2' && this.dropSpecialCharacters === true)) {
this.maskSpecialCharacters = this.maskSpecialCharacters.filter(( /**
* @param {?} item
* @return {?}
*/function (item) { return item !== '.'; }));
}
// tslint:disable-next-line:no-console
console.table(this.maskSpecialCharacters, this.dropSpecialCharacters, this.maskExpression);
Array.isArray(this.dropSpecialCharacters)

@@ -673,0 +687,0 @@ ? this.onChange(this._removeMask(this._removeSufix(this._removePrefix(result)), this.dropSpecialCharacters))

2

bundles/ngx-mask.umd.min.js

@@ -1,2 +0,2 @@

!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("@angular/forms"),require("@angular/common"),require("@angular/core")):"function"==typeof define&&define.amd?define("ngx-mask",["exports","@angular/forms","@angular/common","@angular/core"],t):t(e["ngx-mask"]={},e.ng.forms,e.ng.common,e.ng.core)}(this,function(e,t,r,s){"use strict";var n=new s.InjectionToken("config"),i=new s.InjectionToken("NEW_CONFIG"),a=new s.InjectionToken("INITIAL_CONFIG"),o={sufix:"",prefix:"",clearIfNotMatch:!1,showTemplate:!1,showMaskTyped:!1,dropSpecialCharacters:!0,shownMaskExpression:"",specialCharacters:["-","/","(",")",".",":"," ","+",",","@","[","]",'"',"'"],patterns:{0:{pattern:new RegExp("\\d")},9:{pattern:new RegExp("\\d"),optional:!0},A:{pattern:new RegExp("[a-zA-Z0-9]")},S:{pattern:new RegExp("[a-zA-Z]")},d:{pattern:new RegExp("\\d")},m:{pattern:new RegExp("\\d")},H:{pattern:new RegExp("\\d")},h:{pattern:new RegExp("\\d")},s:{pattern:new RegExp("\\d")}}},c=function(e,t){return(c=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)};var h=function(){return(h=Object.assign||function(e){for(var t,r=1,i=arguments.length;r<i;r++)for(var s in t=arguments[r])Object.prototype.hasOwnProperty.call(t,s)&&(e[s]=t[s]);return e}).apply(this,arguments)};function p(i,s){var n,a,o,e,c={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return e={next:t(0),"throw":t(1),"return":t(2)},"function"==typeof Symbol&&(e[Symbol.iterator]=function(){return this}),e;function t(t){return function(e){return function r(e){if(n)throw new TypeError("Generator is already executing.");for(;c;)try{if(n=1,a&&(o=2&e[0]?a["return"]:e[0]?a["throw"]||((o=a["return"])&&o.call(a),0):a.next)&&!(o=o.call(a,e[1])).done)return o;switch(a=0,o&&(e=[2&e[0],o.value]),e[0]){case 0:case 1:o=e;break;case 4:return c.label++,{value:e[1],done:!1};case 5:c.label++,a=e[1],e=[0];continue;case 7:e=c.ops.pop(),c.trys.pop();continue;default:if(!(o=0<(o=c.trys).length&&o[o.length-1])&&(6===e[0]||2===e[0])){c=0;continue}if(3===e[0]&&(!o||e[1]>o[0]&&e[1]<o[3])){c.label=e[1];break}if(6===e[0]&&c.label<o[1]){c.label=o[1],o=e;break}if(o&&c.label<o[2]){c.label=o[2],c.ops.push(e);break}o[2]&&c.ops.pop(),c.trys.pop();continue}e=s.call(i,c)}catch(t){e=[6,t],a=0}finally{n=o=0}if(5&e[0])throw e[1];return{value:e[0]?e[1]:void 0,done:!0}}([t,e])}}}function l(e,t){var r="function"==typeof Symbol&&e[Symbol.iterator];if(!r)return e;var i,s,n=r.call(e),a=[];try{for(;(void 0===t||0<t--)&&!(i=n.next()).done;)a.push(i.value)}catch(o){s={error:o}}finally{try{i&&!i.done&&(r=n["return"])&&r.call(n)}finally{if(s)throw s.error}}return a}var u=function(){function e(e){this._config=e,this.maskExpression="",this.shownMaskExpression="",this.separator=function(e,t,r,i){for(var s=(e+="").split(r),n=1<s.length?""+r+s[1]:"",a=s[0],o=/(\d+)(\d{3})/;o.test(a);)a=a.replace(o,"$1"+t+"$2");return i===undefined?a+n:0===i?a:a+n.substr(0,i+1)},this.percentage=function(e){return 0<=Number(e)&&Number(e)<=100},this.getPrecision=function(e){var t=e.split(".");return 1<t.length?Number(t[t.length-1]):Infinity},this.checkInputPrecision=function(e,t,r){if(t<Infinity){var i=void 0;i="."===r?new RegExp("\\.\\d{"+t+"}.*$"):new RegExp(",\\d{"+t+"}.*$");var s=e.match(i);s&&s[0].length-1>t?e=e.substring(0,e.length-1):0===t&&e.endsWith(r)&&(e=e.substring(0,e.length-1))}return e},this._shift=new Set,this.maskSpecialCharacters=this._config.specialCharacters,this.maskAvailablePatterns=this._config.patterns,this.clearIfNotMatch=this._config.clearIfNotMatch,this.dropSpecialCharacters=this._config.dropSpecialCharacters,this.maskSpecialCharacters=this._config.specialCharacters,this.maskAvailablePatterns=this._config.patterns,this.prefix=this._config.prefix,this.sufix=this._config.sufix}return e.prototype.applyMaskWithPattern=function(e,t){var r=l(t,2),i=r[0],s=r[1];return this.customPattern=s,this.applyMask(e,i)},e.prototype.applyMask=function(e,t,r,i){if(void 0===r&&(r=0),void 0===i&&(i=function(){}),e===undefined||null===e||t===undefined)return"";var s=0,n="",a=!1;e.slice(0,this.prefix.length)===this.prefix&&(e=e.slice(this.prefix.length,e.length));var o=e.toString().split("");if("percent"===t)(e.match("[a-z]|[A-Z]")||e.match(/[-!$%^&*()_+|~=`{}\[\]:";'<>?,\/]/))&&(e=e.substring(0,e.length-1)),n=this.percentage(e)?e:e.substring(0,e.length-1);else if("separator"===t||"dot_separator"===t||t.startsWith("dot_separator")||"coma_separator"===t||t.startsWith("coma_separator")){(e.match("[a-z]|[A-Z]")||e.match(/[@#!$%^&*()_+|~=`{}\[\]:";<>?\/]/))&&(e=e.substring(0,e.length-1));var c=this.getPrecision(t),h=void 0;"separator"===t?(e.includes(",")&&e.endsWith(",")&&e.indexOf(",")!==e.lastIndexOf(",")&&(e=e.substring(0,e.length-1)),(e.match("[a-z]|[A-Z]")||e.match(/[@#!$%^&*()_+|~=`{}\[\]:.";<>?\/]/))&&(e=e.substring(0,e.length-1)),h=e.replace(/\s/g,""),n=this.separator(h," ",".",c)):"dot_separator"===t||t.startsWith("dot_separator")?((e.match("[a-z]|[A-Z]")||e.match(/[@#!$%^&*()_+|~=`{}\[\]:\s";<>?\/]/))&&(e=e.substring(0,e.length-1)),h=(e=this.checkInputPrecision(e,c,",")).replace(/\./g,""),n=this.separator(h,".",",",c)):("coma_separator"===t||t.startsWith("coma_separator"))&&(h=(e=this.checkInputPrecision(e,c,".")).replace(/\,/g,""),n=this.separator(h,",",".",c)),s=r=n.length+1;var p=/\*|\?/g.test(t.slice(0,s))?o.length:s;this._shift.add(p+this.prefix.length||0)}else for(var l=0,u=o[0];l<o.length&&s!==t.length;u=o[++l])if(this._checkSymbolMask(u,t[s])&&"?"===t[s+1])n+=u,s+=2;else if("*"===t[s+1]&&a&&this._checkSymbolMask(u,t[s+2]))n+=u,s+=3,a=!1;else if(this._checkSymbolMask(u,t[s])&&"*"===t[s+1])n+=u,a=!0;else if("?"===t[s+1]&&this._checkSymbolMask(u,t[s+2]))n+=u,s+=3;else if(this._checkSymbolMask(u,t[s])){if("H"===t[s]&&2<Number(u)){n+=0,s+=1;p=/\*|\?/g.test(t.slice(0,s))?o.length:s;this._shift.add(p+this.prefix.length||0),l--;continue}if("h"===t[s]&&"2"===n&&3<Number(u))continue;if("m"===t[s]&&5<Number(u)){n+=0,s+=1;p=/\*|\?/g.test(t.slice(0,s))?o.length:s;this._shift.add(p+this.prefix.length||0),l--;continue}if("s"===t[s]&&5<Number(u)){n+=0,s+=1;p=/\*|\?/g.test(t.slice(0,s))?o.length:s;this._shift.add(p+this.prefix.length||0),l--;continue}if("d"===t[s]&&3<Number(u)){n+=0,s+=1;p=/\*|\?/g.test(t.slice(0,s))?o.length:s;this._shift.add(p+this.prefix.length||0),l--;continue}if("d"===t[s-1]&&31<Number(e.slice(s-1,s+1)))continue;if("m"===t[s]&&1<Number(u)){n+=0,s+=1;p=/\*|\?/g.test(t.slice(0,s))?o.length:s;this._shift.add(p+this.prefix.length||0),l--;continue}if("m"===t[s-1]&&12<Number(e.slice(s-1,s+1)))continue;n+=u,s++}else if(-1!==this.maskSpecialCharacters.indexOf(t[s])){n+=t[s],s++;p=/\*|\?/g.test(t.slice(0,s))?o.length:s;this._shift.add(p+this.prefix.length||0),l--}else-1<this.maskSpecialCharacters.indexOf(u)&&this.maskAvailablePatterns[t[s]]&&this.maskAvailablePatterns[t[s]].optional?(s++,l--):"*"===this.maskExpression[s+1]&&this._findSpecialChar(this.maskExpression[s+2])&&this._findSpecialChar(u)===this.maskExpression[s+2]&&a&&(s+=3,n+=u);n.length+1===t.length&&-1!==this.maskSpecialCharacters.indexOf(t[t.length-1])&&(n+=t[t.length-1]);for(var f=1,m=r+1;this._shift.has(m);)f++,m++;i(this._shift.has(r)?f:0);var d=""+this.prefix+n;return d=this.sufix?""+this.prefix+n+this.sufix:""+this.prefix+n,0===n.length&&(d=""+this.prefix+n),d},e.prototype._findSpecialChar=function(t){return this.maskSpecialCharacters.find(function(e){return e===t})},e.prototype._checkSymbolMask=function(e,t){return this.maskAvailablePatterns=this.customPattern?this.customPattern:this.maskAvailablePatterns,this.maskAvailablePatterns[t]&&this.maskAvailablePatterns[t].pattern&&this.maskAvailablePatterns[t].pattern.test(e)},e.decorators=[{type:s.Injectable}],e.ctorParameters=function(){return[{type:undefined,decorators:[{type:s.Inject,args:[n]}]}]},e}(),f=function(a){function e(e,t,r,i){var s=a.call(this,t)||this;return s.document=e,s._config=t,s._elementRef=r,s._renderer=i,s.maskExpression="",s.isNumberValue=!1,s.showMaskTyped=!1,s.maskIsShown="",s.onChange=function(e){},s.onTouch=function(){},s._formElement=s._elementRef.nativeElement,s}return function i(e,t){function r(){this.constructor=e}c(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}(e,a),e.prototype.applyMask=function(e,t,r,i){if(void 0===r&&(r=0),void 0===i&&(i=function(){}),this.maskIsShown=this.showMaskTyped?this.showMaskInInput():"",!e&&this.showMaskTyped)return this.prefix+this.maskIsShown;var s=a.prototype.applyMask.call(this,e,t,r,i);Array.isArray(this.dropSpecialCharacters)?this.onChange(this._removeMask(this._removeSufix(this._removePrefix(s)),this.dropSpecialCharacters)):!0===this.dropSpecialCharacters?this.onChange(this.isNumberValue?Number(this._removeMask(this._removeSufix(this._removePrefix(s)),this.maskSpecialCharacters)):this._removeMask(this._removeSufix(this._removePrefix(s)),this.maskSpecialCharacters)):this.onChange(this._removeSufix(this._removePrefix(s)));if(!this.showMaskTyped)return s;var n=s.length;return s+(this.prefix+this.maskIsShown).slice(n)},e.prototype.applyValueChanges=function(e,t){void 0===e&&(e=0),void 0===t&&(t=function(){});var r=this.applyMask(this._formElement.value,this.maskExpression,e,t);this._formElement.value=r,this._formElement!==this.document.activeElement&&this.clearIfNotMatchFn()},e.prototype.showMaskInInput=function(){if(this.showMaskTyped&&this.shownMaskExpression){if(this.maskExpression.length!==this.shownMaskExpression.length)throw new Error("Mask expression must match mask placeholder length");return this.shownMaskExpression}return this.showMaskTyped?this.maskExpression.replace(/\w/g,"_"):""},e.prototype.clearIfNotMatchFn=function(){!0===this.clearIfNotMatch&&this.maskExpression.length!==this._formElement.value.length&&(this.formElementProperty=["value",""],this.applyMask(this._formElement.value,this.maskExpression))},Object.defineProperty(e.prototype,"formElementProperty",{set:function(e){var t=l(e,2),r=t[0],i=t[1];this._renderer.setProperty(this._formElement,r,i)},enumerable:!0,configurable:!0}),e.prototype._removeMask=function(e,t){return e?e.replace(this._regExpForRemove(t),""):e},e.prototype._removePrefix=function(e){return this.prefix&&e?e.replace(this.prefix,""):e},e.prototype._removeSufix=function(e){return this.sufix&&e?e.replace(this.sufix,""):e},e.prototype._regExpForRemove=function(e){return new RegExp(e.map(function(e){return"\\"+e}).join("|"),"gi")},e.decorators=[{type:s.Injectable}],e.ctorParameters=function(){return[{type:undefined,decorators:[{type:s.Inject,args:[r.DOCUMENT]}]},{type:undefined,decorators:[{type:s.Inject,args:[n]}]},{type:s.ElementRef},{type:s.Renderer2}]},e}(u),m=function(){function e(e,t){this.document=e,this._maskService=t,this._position=null,this.onChange=function(e){},this.onTouch=function(){}}return Object.defineProperty(e.prototype,"maskExpression",{set:function(e){this._maskValue=e||"",this._maskValue&&(this._maskService.maskExpression=this._repeatPatternSymbols(this._maskValue),this._maskService.formElementProperty=["value",this._maskService.applyMask(this._inputValue,this._maskService.maskExpression)])},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"specialCharacters",{set:function(e){e&&Array.isArray(e)&&(!Array.isArray(e)||e.length)&&(this._maskService.maskSpecialCharacters=e)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"patterns",{set:function(e){e&&(this._maskService.maskAvailablePatterns=e)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"prefix",{set:function(e){e&&(this._maskService.prefix=e)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"sufix",{set:function(e){e&&(this._maskService.sufix=e)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"dropSpecialCharacters",{set:function(e){this._maskService.dropSpecialCharacters=e},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"showMaskTyped",{set:function(e){e&&(this._maskService.showMaskTyped=e)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"shownMaskExpression",{set:function(e){e&&(this._maskService.shownMaskExpression=e)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"showTemplate",{set:function(e){this._maskService.showTemplate=e},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"clearIfNotMatch",{set:function(e){this._maskService.clearIfNotMatch=e},enumerable:!0,configurable:!0}),e.prototype.onInput=function(e){var t=e.target;if(this._inputValue=t.value,this._maskValue){var r=1===t.selectionStart?t.selectionStart+this._maskService.prefix.length:t.selectionStart,i=0;this._maskService.applyValueChanges(r,function(e){return i=e}),this.document.activeElement===t&&(t.selectionStart=t.selectionEnd=null!==this._position?this._position:r+("deleteContentBackward"===e.inputType?0:i),this._position=null)}else this.onChange(t.value)},e.prototype.onBlur=function(){this._maskService.clearIfNotMatchFn(),this.onTouch()},e.prototype.onFocus=function(e){var t=e.target;null!==t&&null!==t.selectionStart&&t.selectionStart===t.selectionEnd&&t.selectionStart>this._maskService.prefix.length&&38!==e.keyCode||(this._maskService.showMaskTyped&&(this._maskService.maskIsShown=this._maskService.showMaskInInput()),t.value=t.value&&t.value!==this._maskService.prefix?t.value:this._maskService.prefix+this._maskService.maskIsShown,(t.selectionStart||t.selectionEnd)<=this._maskService.prefix.length&&(t.selectionStart=this._maskService.prefix.length))},e.prototype.a=function(e){var t=e.target;38===e.keyCode&&e.preventDefault(),37!==e.keyCode&&8!==e.keyCode||(t.selectionStart<=this._maskService.prefix.length&&t.selectionEnd<=this._maskService.prefix.length&&e.preventDefault(),this.onFocus(e),8===e.keyCode&&0===t.selectionStart&&t.selectionEnd===t.value.length&&(t.value=this._maskService.prefix,this._position=this._maskService.prefix?this._maskService.prefix.length:1,this.onInput(e)))},e.prototype.onPaste=function(){this._position=Number.MAX_SAFE_INTEGER},e.prototype.writeValue=function(t){return function e(t,a,o,c){return new(o||(o=Promise))(function(e,r){function i(e){try{n(c.next(e))}catch(t){r(t)}}function s(e){try{n(c["throw"](e))}catch(t){r(t)}}function n(t){t.done?e(t.value):new o(function(e){e(t.value)}).then(i,s)}n((c=c.apply(t,a||[])).next())})}(this,void 0,void 0,function(){return p(this,function(e){return t===undefined&&(t=""),"number"==typeof t&&(t=String(t),this._maskService.isNumberValue=!0),t&&this._maskService.maskExpression||this._maskService.maskExpression&&(this._maskService.prefix||this._maskService.showMaskTyped)?this._maskService.formElementProperty=["value",this._maskService.applyMask(t,this._maskService.maskExpression)]:this._maskService.formElementProperty=["value",t],this._inputValue=t,[2]})})},e.prototype.registerOnChange=function(e){this.onChange=e,this._maskService.onChange=this.onChange},e.prototype.registerOnTouched=function(e){this.onTouch=e},e.prototype.setDisabledState=function(e){this._maskService.formElementProperty=["disabled",e]},e.prototype._repeatPatternSymbols=function(s){var n=this;return s.match(/{[0-9]+}/)&&s.split("").reduce(function(e,t,r){if(n._start="{"===t?r:n._start,"}"!==t)return n._maskService._findSpecialChar(t)?e+t:e;n._end=r;var i=Number(s.slice(n._start+1,n._end));return e+new Array(i+1).join(s[n._start-1])},"")||s},e.decorators=[{type:s.Directive,args:[{selector:"[mask]",providers:[{provide:t.NG_VALUE_ACCESSOR,useExisting:s.forwardRef(function(){return e}),multi:!0},f]}]}],e.ctorParameters=function(){return[{type:undefined,decorators:[{type:s.Inject,args:[r.DOCUMENT]}]},{type:f}]},e.propDecorators={maskExpression:[{type:s.Input,args:["mask"]}],specialCharacters:[{type:s.Input}],patterns:[{type:s.Input}],prefix:[{type:s.Input}],sufix:[{type:s.Input}],dropSpecialCharacters:[{type:s.Input}],showMaskTyped:[{type:s.Input}],shownMaskExpression:[{type:s.Input}],showTemplate:[{type:s.Input}],clearIfNotMatch:[{type:s.Input}],onInput:[{type:s.HostListener,args:["input",["$event"]]}],onBlur:[{type:s.HostListener,args:["blur"]}],onFocus:[{type:s.HostListener,args:["click",["$event"]]}],a:[{type:s.HostListener,args:["keydown",["$event"]]}],onPaste:[{type:s.HostListener,args:["paste"]}]},e}(),d=function(){function e(e){this._maskService=e}return e.prototype.transform=function(e,t){return e?"string"==typeof t?this._maskService.applyMask(""+e,t):this._maskService.applyMaskWithPattern(""+e,t):""},e.decorators=[{type:s.Pipe,args:[{name:"mask",pure:!0}]}],e.ctorParameters=function(){return[{type:u}]},e}(),y=function(){function t(){}return t.forRoot=function(e){return{ngModule:t,providers:[{provide:i,useValue:e},{provide:a,useValue:o},{provide:n,useFactory:k,deps:[a,i]}]}},t.forChild=function(e){return{ngModule:t}},t.decorators=[{type:s.NgModule,args:[{providers:[u],exports:[m,d],declarations:[m,d]}]}],t}();function k(e,t){return"function"==typeof t?t():h({},e,t)}e.config=n,e.NEW_CONFIG=i,e.INITIAL_CONFIG=a,e.initialConfig=o,e.MaskDirective=m,e.MaskService=f,e._configFactory=k,e.NgxMaskModule=y,e.MaskPipe=d,e.ɵa=u,Object.defineProperty(e,"__esModule",{value:!0})});
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?t(exports,require("@angular/forms"),require("@angular/common"),require("@angular/core")):"function"==typeof define&&define.amd?define("ngx-mask",["exports","@angular/forms","@angular/common","@angular/core"],t):t(e["ngx-mask"]={},e.ng.forms,e.ng.common,e.ng.core)}(this,function(e,t,r,i){"use strict";var n=new i.InjectionToken("config"),s=new i.InjectionToken("NEW_CONFIG"),a=new i.InjectionToken("INITIAL_CONFIG"),o={sufix:"",prefix:"",clearIfNotMatch:!1,showTemplate:!1,showMaskTyped:!1,dropSpecialCharacters:!0,shownMaskExpression:"",specialCharacters:["-","/","(",")",".",":"," ","+",",","@","[","]",'"',"'"],patterns:{0:{pattern:new RegExp("\\d")},9:{pattern:new RegExp("\\d"),optional:!0},A:{pattern:new RegExp("[a-zA-Z0-9]")},S:{pattern:new RegExp("[a-zA-Z]")},d:{pattern:new RegExp("\\d")},m:{pattern:new RegExp("\\d")},H:{pattern:new RegExp("\\d")},h:{pattern:new RegExp("\\d")},s:{pattern:new RegExp("\\d")}}},c=function(e,t){return(c=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)t.hasOwnProperty(r)&&(e[r]=t[r])})(e,t)};var h=function(){return(h=Object.assign||function(e){for(var t,r=1,s=arguments.length;r<s;r++)for(var i in t=arguments[r])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)};function p(s,i){var n,a,o,e,c={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]};return e={next:t(0),"throw":t(1),"return":t(2)},"function"==typeof Symbol&&(e[Symbol.iterator]=function(){return this}),e;function t(t){return function(e){return function r(e){if(n)throw new TypeError("Generator is already executing.");for(;c;)try{if(n=1,a&&(o=2&e[0]?a["return"]:e[0]?a["throw"]||((o=a["return"])&&o.call(a),0):a.next)&&!(o=o.call(a,e[1])).done)return o;switch(a=0,o&&(e=[2&e[0],o.value]),e[0]){case 0:case 1:o=e;break;case 4:return c.label++,{value:e[1],done:!1};case 5:c.label++,a=e[1],e=[0];continue;case 7:e=c.ops.pop(),c.trys.pop();continue;default:if(!(o=0<(o=c.trys).length&&o[o.length-1])&&(6===e[0]||2===e[0])){c=0;continue}if(3===e[0]&&(!o||e[1]>o[0]&&e[1]<o[3])){c.label=e[1];break}if(6===e[0]&&c.label<o[1]){c.label=o[1],o=e;break}if(o&&c.label<o[2]){c.label=o[2],c.ops.push(e);break}o[2]&&c.ops.pop(),c.trys.pop();continue}e=i.call(s,c)}catch(t){e=[6,t],a=0}finally{n=o=0}if(5&e[0])throw e[1];return{value:e[0]?e[1]:void 0,done:!0}}([t,e])}}}function l(e,t){var r="function"==typeof Symbol&&e[Symbol.iterator];if(!r)return e;var s,i,n=r.call(e),a=[];try{for(;(void 0===t||0<t--)&&!(s=n.next()).done;)a.push(s.value)}catch(o){i={error:o}}finally{try{s&&!s.done&&(r=n["return"])&&r.call(n)}finally{if(i)throw i.error}}return a}var u=function(){function e(e){this._config=e,this.maskExpression="",this.shownMaskExpression="",this.separator=function(e,t,r,s){for(var i=(e+="").split(r),n=1<i.length?""+r+i[1]:"",a=i[0],o=/(\d+)(\d{3})/;o.test(a);)a=a.replace(o,"$1"+t+"$2");return s===undefined?a+n:0===s?a:a+n.substr(0,s+1)},this.percentage=function(e){return 0<=Number(e)&&Number(e)<=100},this.getPrecision=function(e){var t=e.split(".");return 1<t.length?Number(t[t.length-1]):Infinity},this.checkInputPrecision=function(e,t,r){if(t<Infinity){var s=void 0;s="."===r?new RegExp("\\.\\d{"+t+"}.*$"):new RegExp(",\\d{"+t+"}.*$");var i=e.match(s);i&&i[0].length-1>t?e=e.substring(0,e.length-1):0===t&&e.endsWith(r)&&(e=e.substring(0,e.length-1))}return e},this._shift=new Set,this.maskSpecialCharacters=this._config.specialCharacters,this.maskAvailablePatterns=this._config.patterns,this.clearIfNotMatch=this._config.clearIfNotMatch,this.dropSpecialCharacters=this._config.dropSpecialCharacters,this.maskSpecialCharacters=this._config.specialCharacters,this.maskAvailablePatterns=this._config.patterns,this.prefix=this._config.prefix,this.sufix=this._config.sufix}return e.prototype.applyMaskWithPattern=function(e,t){var r=l(t,2),s=r[0],i=r[1];return this.customPattern=i,this.applyMask(e,s)},e.prototype.applyMask=function(e,t,r,s){if(void 0===r&&(r=0),void 0===s&&(s=function(){}),e===undefined||null===e||t===undefined)return"";var i=0,n="",a=!1;e.slice(0,this.prefix.length)===this.prefix&&(e=e.slice(this.prefix.length,e.length));var o=e.toString().split("");if("percent"===t)(e.match("[a-z]|[A-Z]")||e.match(/[-!$%^&*()_+|~=`{}\[\]:";'<>?,\/]/))&&(e=e.substring(0,e.length-1)),n=this.percentage(e)?e:e.substring(0,e.length-1);else if("separator"===t||"dot_separator"===t||t.startsWith("dot_separator")||"coma_separator"===t||t.startsWith("coma_separator")){(e.match("[a-z]|[A-Z]")||e.match(/[@#!$%^&*()_+|~=`{}\[\]:";<>?\/]/))&&(e=e.substring(0,e.length-1));var c=this.getPrecision(t),h=void 0;"separator"===t?(e.includes(",")&&e.endsWith(",")&&e.indexOf(",")!==e.lastIndexOf(",")&&(e=e.substring(0,e.length-1)),(e.match("[a-z]|[A-Z]")||e.match(/[@#!$%^&*()_+|~=`{}\[\]:.";<>?\/]/))&&(e=e.substring(0,e.length-1)),h=e.replace(/\s/g,""),n=this.separator(h," ",".",c)):"dot_separator"===t||t.startsWith("dot_separator")?((e.match("[a-z]|[A-Z]")||e.match(/[@#!$%^&*()_+|~=`{}\[\]:\s";<>?\/]/))&&(e=e.substring(0,e.length-1)),h=(e=this.checkInputPrecision(e,c,",")).replace(/\./g,""),n=this.separator(h,".",",",c)):("coma_separator"===t||t.startsWith("coma_separator"))&&(h=(e=this.checkInputPrecision(e,c,".")).replace(/\,/g,""),n=this.separator(h,",",".",c)),i=r=n.length+1;var p=/\*|\?/g.test(t.slice(0,i))?o.length:i;this._shift.add(p+this.prefix.length||0)}else for(var l=0,u=o[0];l<o.length&&i!==t.length;u=o[++l])if(this._checkSymbolMask(u,t[i])&&"?"===t[i+1])n+=u,i+=2;else if("*"===t[i+1]&&a&&this._checkSymbolMask(u,t[i+2]))n+=u,i+=3,a=!1;else if(this._checkSymbolMask(u,t[i])&&"*"===t[i+1])n+=u,a=!0;else if("?"===t[i+1]&&this._checkSymbolMask(u,t[i+2]))n+=u,i+=3;else if(this._checkSymbolMask(u,t[i])){if("H"===t[i]&&2<Number(u)){n+=0,i+=1;p=/\*|\?/g.test(t.slice(0,i))?o.length:i;this._shift.add(p+this.prefix.length||0),l--;continue}if("h"===t[i]&&"2"===n&&3<Number(u))continue;if("m"===t[i]&&5<Number(u)){n+=0,i+=1;p=/\*|\?/g.test(t.slice(0,i))?o.length:i;this._shift.add(p+this.prefix.length||0),l--;continue}if("s"===t[i]&&5<Number(u)){n+=0,i+=1;p=/\*|\?/g.test(t.slice(0,i))?o.length:i;this._shift.add(p+this.prefix.length||0),l--;continue}if("d"===t[i]&&3<Number(u)){n+=0,i+=1;p=/\*|\?/g.test(t.slice(0,i))?o.length:i;this._shift.add(p+this.prefix.length||0),l--;continue}if("d"===t[i-1]&&31<Number(e.slice(i-1,i+1)))continue;if("m"===t[i]&&1<Number(u)){n+=0,i+=1;p=/\*|\?/g.test(t.slice(0,i))?o.length:i;this._shift.add(p+this.prefix.length||0),l--;continue}if("m"===t[i-1]&&12<Number(e.slice(i-1,i+1)))continue;n+=u,i++}else if(-1!==this.maskSpecialCharacters.indexOf(t[i])){n+=t[i],i++;p=/\*|\?/g.test(t.slice(0,i))?o.length:i;this._shift.add(p+this.prefix.length||0),l--}else-1<this.maskSpecialCharacters.indexOf(u)&&this.maskAvailablePatterns[t[i]]&&this.maskAvailablePatterns[t[i]].optional?(i++,l--):"*"===this.maskExpression[i+1]&&this._findSpecialChar(this.maskExpression[i+2])&&this._findSpecialChar(u)===this.maskExpression[i+2]&&a&&(i+=3,n+=u);n.length+1===t.length&&-1!==this.maskSpecialCharacters.indexOf(t[t.length-1])&&(n+=t[t.length-1]);for(var f=1,m=r+1;this._shift.has(m);)f++,m++;s(this._shift.has(r)?f:0);var k=""+this.prefix+n;return k=this.sufix?""+this.prefix+n+this.sufix:""+this.prefix+n,0===n.length&&(k=""+this.prefix+n),k},e.prototype._findSpecialChar=function(t){return this.maskSpecialCharacters.find(function(e){return e===t})},e.prototype._checkSymbolMask=function(e,t){return this.maskAvailablePatterns=this.customPattern?this.customPattern:this.maskAvailablePatterns,this.maskAvailablePatterns[t]&&this.maskAvailablePatterns[t].pattern&&this.maskAvailablePatterns[t].pattern.test(e)},e.decorators=[{type:i.Injectable}],e.ctorParameters=function(){return[{type:undefined,decorators:[{type:i.Inject,args:[n]}]}]},e}(),f=function(a){function e(e,t,r,s){var i=a.call(this,t)||this;return i.document=e,i._config=t,i._elementRef=r,i._renderer=s,i.maskExpression="",i.isNumberValue=!1,i.showMaskTyped=!1,i.maskIsShown="",i.onChange=function(e){},i.onTouch=function(){},i._formElement=i._elementRef.nativeElement,i}return function s(e,t){function r(){this.constructor=e}c(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}(e,a),e.prototype.applyMask=function(e,t,r,s){if(void 0===r&&(r=0),void 0===s&&(s=function(){}),this.maskIsShown=this.showMaskTyped?this.showMaskInInput():"",!e&&this.showMaskTyped)return this.prefix+this.maskIsShown;var i=a.prototype.applyMask.call(this,e,t,r,s);"dot_separator.2"===this.maskExpression&&!0===this.dropSpecialCharacters&&(this.maskSpecialCharacters=this.maskSpecialCharacters.filter(function(e){return","!==e})),"coma_separator.2"===this.maskExpression&&!0===this.dropSpecialCharacters&&(this.maskSpecialCharacters=this.maskSpecialCharacters.filter(function(e){return"."!==e})),console.table(this.maskSpecialCharacters,this.dropSpecialCharacters,this.maskExpression),Array.isArray(this.dropSpecialCharacters)?this.onChange(this._removeMask(this._removeSufix(this._removePrefix(i)),this.dropSpecialCharacters)):!0===this.dropSpecialCharacters?this.onChange(this.isNumberValue?Number(this._removeMask(this._removeSufix(this._removePrefix(i)),this.maskSpecialCharacters)):this._removeMask(this._removeSufix(this._removePrefix(i)),this.maskSpecialCharacters)):this.onChange(this._removeSufix(this._removePrefix(i)));if(!this.showMaskTyped)return i;var n=i.length;return i+(this.prefix+this.maskIsShown).slice(n)},e.prototype.applyValueChanges=function(e,t){void 0===e&&(e=0),void 0===t&&(t=function(){});var r=this.applyMask(this._formElement.value,this.maskExpression,e,t);this._formElement.value=r,this._formElement!==this.document.activeElement&&this.clearIfNotMatchFn()},e.prototype.showMaskInInput=function(){if(this.showMaskTyped&&this.shownMaskExpression){if(this.maskExpression.length!==this.shownMaskExpression.length)throw new Error("Mask expression must match mask placeholder length");return this.shownMaskExpression}return this.showMaskTyped?this.maskExpression.replace(/\w/g,"_"):""},e.prototype.clearIfNotMatchFn=function(){!0===this.clearIfNotMatch&&this.maskExpression.length!==this._formElement.value.length&&(this.formElementProperty=["value",""],this.applyMask(this._formElement.value,this.maskExpression))},Object.defineProperty(e.prototype,"formElementProperty",{set:function(e){var t=l(e,2),r=t[0],s=t[1];this._renderer.setProperty(this._formElement,r,s)},enumerable:!0,configurable:!0}),e.prototype._removeMask=function(e,t){return e?e.replace(this._regExpForRemove(t),""):e},e.prototype._removePrefix=function(e){return this.prefix&&e?e.replace(this.prefix,""):e},e.prototype._removeSufix=function(e){return this.sufix&&e?e.replace(this.sufix,""):e},e.prototype._regExpForRemove=function(e){return new RegExp(e.map(function(e){return"\\"+e}).join("|"),"gi")},e.decorators=[{type:i.Injectable}],e.ctorParameters=function(){return[{type:undefined,decorators:[{type:i.Inject,args:[r.DOCUMENT]}]},{type:undefined,decorators:[{type:i.Inject,args:[n]}]},{type:i.ElementRef},{type:i.Renderer2}]},e}(u),m=function(){function e(e,t){this.document=e,this._maskService=t,this._position=null,this.onChange=function(e){},this.onTouch=function(){}}return Object.defineProperty(e.prototype,"maskExpression",{set:function(e){this._maskValue=e||"",this._maskValue&&(this._maskService.maskExpression=this._repeatPatternSymbols(this._maskValue),this._maskService.formElementProperty=["value",this._maskService.applyMask(this._inputValue,this._maskService.maskExpression)])},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"specialCharacters",{set:function(e){e&&Array.isArray(e)&&(!Array.isArray(e)||e.length)&&(this._maskService.maskSpecialCharacters=e)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"patterns",{set:function(e){e&&(this._maskService.maskAvailablePatterns=e)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"prefix",{set:function(e){e&&(this._maskService.prefix=e)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"sufix",{set:function(e){e&&(this._maskService.sufix=e)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"dropSpecialCharacters",{set:function(e){this._maskService.dropSpecialCharacters=e},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"showMaskTyped",{set:function(e){e&&(this._maskService.showMaskTyped=e)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"shownMaskExpression",{set:function(e){e&&(this._maskService.shownMaskExpression=e)},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"showTemplate",{set:function(e){this._maskService.showTemplate=e},enumerable:!0,configurable:!0}),Object.defineProperty(e.prototype,"clearIfNotMatch",{set:function(e){this._maskService.clearIfNotMatch=e},enumerable:!0,configurable:!0}),e.prototype.onInput=function(e){var t=e.target;if(this._inputValue=t.value,this._maskValue){var r=1===t.selectionStart?t.selectionStart+this._maskService.prefix.length:t.selectionStart,s=0;this._maskService.applyValueChanges(r,function(e){return s=e}),this.document.activeElement===t&&(t.selectionStart=t.selectionEnd=null!==this._position?this._position:r+("deleteContentBackward"===e.inputType?0:s),this._position=null)}else this.onChange(t.value)},e.prototype.onBlur=function(){this._maskService.clearIfNotMatchFn(),this.onTouch()},e.prototype.onFocus=function(e){var t=e.target;null!==t&&null!==t.selectionStart&&t.selectionStart===t.selectionEnd&&t.selectionStart>this._maskService.prefix.length&&38!==e.keyCode||(this._maskService.showMaskTyped&&(this._maskService.maskIsShown=this._maskService.showMaskInInput()),t.value=t.value&&t.value!==this._maskService.prefix?t.value:this._maskService.prefix+this._maskService.maskIsShown,(t.selectionStart||t.selectionEnd)<=this._maskService.prefix.length&&(t.selectionStart=this._maskService.prefix.length))},e.prototype.a=function(e){var t=e.target;38===e.keyCode&&e.preventDefault(),37!==e.keyCode&&8!==e.keyCode||(t.selectionStart<=this._maskService.prefix.length&&t.selectionEnd<=this._maskService.prefix.length&&e.preventDefault(),this.onFocus(e),8===e.keyCode&&0===t.selectionStart&&t.selectionEnd===t.value.length&&(t.value=this._maskService.prefix,this._position=this._maskService.prefix?this._maskService.prefix.length:1,this.onInput(e)))},e.prototype.onPaste=function(){this._position=Number.MAX_SAFE_INTEGER},e.prototype.writeValue=function(t){return function e(t,a,o,c){return new(o||(o=Promise))(function(e,r){function s(e){try{n(c.next(e))}catch(t){r(t)}}function i(e){try{n(c["throw"](e))}catch(t){r(t)}}function n(t){t.done?e(t.value):new o(function(e){e(t.value)}).then(s,i)}n((c=c.apply(t,a||[])).next())})}(this,void 0,void 0,function(){return p(this,function(e){return t===undefined&&(t=""),"number"==typeof t&&(t=String(t),this._maskService.isNumberValue=!0),t&&this._maskService.maskExpression||this._maskService.maskExpression&&(this._maskService.prefix||this._maskService.showMaskTyped)?this._maskService.formElementProperty=["value",this._maskService.applyMask(t,this._maskService.maskExpression)]:this._maskService.formElementProperty=["value",t],this._inputValue=t,[2]})})},e.prototype.registerOnChange=function(e){this.onChange=e,this._maskService.onChange=this.onChange},e.prototype.registerOnTouched=function(e){this.onTouch=e},e.prototype.setDisabledState=function(e){this._maskService.formElementProperty=["disabled",e]},e.prototype._repeatPatternSymbols=function(i){var n=this;return i.match(/{[0-9]+}/)&&i.split("").reduce(function(e,t,r){if(n._start="{"===t?r:n._start,"}"!==t)return n._maskService._findSpecialChar(t)?e+t:e;n._end=r;var s=Number(i.slice(n._start+1,n._end));return e+new Array(s+1).join(i[n._start-1])},"")||i},e.decorators=[{type:i.Directive,args:[{selector:"[mask]",providers:[{provide:t.NG_VALUE_ACCESSOR,useExisting:i.forwardRef(function(){return e}),multi:!0},f]}]}],e.ctorParameters=function(){return[{type:undefined,decorators:[{type:i.Inject,args:[r.DOCUMENT]}]},{type:f}]},e.propDecorators={maskExpression:[{type:i.Input,args:["mask"]}],specialCharacters:[{type:i.Input}],patterns:[{type:i.Input}],prefix:[{type:i.Input}],sufix:[{type:i.Input}],dropSpecialCharacters:[{type:i.Input}],showMaskTyped:[{type:i.Input}],shownMaskExpression:[{type:i.Input}],showTemplate:[{type:i.Input}],clearIfNotMatch:[{type:i.Input}],onInput:[{type:i.HostListener,args:["input",["$event"]]}],onBlur:[{type:i.HostListener,args:["blur"]}],onFocus:[{type:i.HostListener,args:["click",["$event"]]}],a:[{type:i.HostListener,args:["keydown",["$event"]]}],onPaste:[{type:i.HostListener,args:["paste"]}]},e}(),k=function(){function e(e){this._maskService=e}return e.prototype.transform=function(e,t){return e?"string"==typeof t?this._maskService.applyMask(""+e,t):this._maskService.applyMaskWithPattern(""+e,t):""},e.decorators=[{type:i.Pipe,args:[{name:"mask",pure:!0}]}],e.ctorParameters=function(){return[{type:u}]},e}(),d=function(){function t(){}return t.forRoot=function(e){return{ngModule:t,providers:[{provide:s,useValue:e},{provide:a,useValue:o},{provide:n,useFactory:y,deps:[a,s]}]}},t.forChild=function(e){return{ngModule:t}},t.decorators=[{type:i.NgModule,args:[{providers:[u],exports:[m,k],declarations:[m,k]}]}],t}();function y(e,t){return"function"==typeof t?t():h({},e,t)}e.config=n,e.NEW_CONFIG=s,e.INITIAL_CONFIG=a,e.initialConfig=o,e.MaskDirective=m,e.MaskService=f,e._configFactory=y,e.NgxMaskModule=d,e.MaskPipe=k,e.ɵa=u,Object.defineProperty(e,"__esModule",{value:!0})});
//# sourceMappingURL=ngx-mask.umd.min.js.map

@@ -55,2 +55,18 @@ /**

const result = super.applyMask(inputValue, maskExpression, position, cb);
if (this.maskExpression === 'dot_separator.2' && this.dropSpecialCharacters === true) {
this.maskSpecialCharacters = this.maskSpecialCharacters.filter((/**
* @param {?} item
* @return {?}
*/
(item) => item !== ','));
}
if ((this.maskExpression === 'coma_separator.2' && this.dropSpecialCharacters === true)) {
this.maskSpecialCharacters = this.maskSpecialCharacters.filter((/**
* @param {?} item
* @return {?}
*/
(item) => item !== '.'));
}
// tslint:disable-next-line:no-console
console.table(this.maskSpecialCharacters, this.dropSpecialCharacters, this.maskExpression);
Array.isArray(this.dropSpecialCharacters)

@@ -225,2 +241,2 @@ ? this.onChange(this._removeMask(this._removeSufix(this._removePrefix(result)), this.dropSpecialCharacters))

}
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibWFzay5zZXJ2aWNlLmpzIiwic291cmNlUm9vdCI6Im5nOi8vbmd4LW1hc2svIiwic291cmNlcyI6WyJhcHAvbmd4LW1hc2svbWFzay5zZXJ2aWNlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiI7Ozs7QUFBQSxPQUFPLEVBQUUsVUFBVSxFQUFFLE1BQU0sRUFBRSxVQUFVLEVBQUUsU0FBUyxFQUFFLE1BQU0sZUFBZSxDQUFDO0FBQzFFLE9BQU8sRUFBRSxNQUFNLEVBQVcsTUFBTSxVQUFVLENBQUM7QUFDM0MsT0FBTyxFQUFFLFFBQVEsRUFBRSxNQUFNLGlCQUFpQixDQUFD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h0aGlzLnByZWZpeCwgJycpXG4gICAgICA6IHZhbHVlO1xuICB9XG5cbiAgcHJpdmF0ZSBfcmVtb3ZlU3VmaXgodmFsdWU6IHN0cmluZyk6IHN0cmluZyB7XG4gICAgaWYgKCF0aGlzLnN1Zml4KSB7XG4gICAgICByZXR1cm4gdmFsdWU7XG4gICAgfVxuICAgIHJldHVybiB2YWx1ZVxuICAgICAgPyB2YWx1ZS5yZXBsYWNlKHRoaXMuc3VmaXgsICcnKVxuICAgICAgOiB2YWx1ZTtcbiAgfVxuXG4gIHByaXZhdGUgX3JlZ0V4cEZvclJlbW92ZShzcGVjaWFsQ2hhcmFjdGVyc0ZvclJlbW92ZTogc3RyaW5nW10pOiBSZWdFeHAge1xuICAgIHJldHVybiBuZXcgUmVnRXhwKFxuICAgICAgc3BlY2lhbENoYXJhY3RlcnNGb3JSZW1vdmUubWFwKChpdGVtOiBzdHJpbmcpID0+IGBcXFxcJHtpdGVtfWApLmpvaW4oJ3wnKSxcbiAgICAgICdnaSdcbiAgICApO1xuICB9XG59XG4iXX0=

@@ -61,2 +61,18 @@ /**

var result = _super.prototype.applyMask.call(this, inputValue, maskExpression, position, cb);
if (this.maskExpression === 'dot_separator.2' && this.dropSpecialCharacters === true) {
this.maskSpecialCharacters = this.maskSpecialCharacters.filter((/**
* @param {?} item
* @return {?}
*/
function (item) { return item !== ','; }));
}
if ((this.maskExpression === 'coma_separator.2' && this.dropSpecialCharacters === true)) {
this.maskSpecialCharacters = this.maskSpecialCharacters.filter((/**
* @param {?} item
* @return {?}
*/
function (item) { return item !== '.'; }));
}
// tslint:disable-next-line:no-console
console.table(this.maskSpecialCharacters, this.dropSpecialCharacters, this.maskExpression);
Array.isArray(this.dropSpecialCharacters)

@@ -272,2 +288,2 @@ ? this.onChange(this._removeMask(this._removeSufix(this._removePrefix(result)), this.dropSpecialCharacters))

}
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibWFzay5zZXJ2aWNlLm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gpIHtcbiAgICAgIHJldHVybiB2YWx1ZTtcbiAgICB9XG4gICAgcmV0dXJuIHZhbHVlXG4gICAgICA/IHZhbHVlLnJlcGxhY2UodGhpcy5zdWZpeCwgJycpXG4gICAgICA6IHZhbHVlO1xuICB9XG5cbiAgcHJpdmF0ZSBfcmVnRXhwRm9yUmVtb3ZlKHNwZWNpYWxDaGFyYWN0ZXJzRm9yUmVtb3ZlOiBzdHJpbmdbXSk6IFJlZ0V4cCB7XG4gICAgcmV0dXJuIG5ldyBSZWdFeHAoXG4gICAgICBzcGVjaWFsQ2hhcmFjdGVyc0ZvclJlbW92ZS5tYXAoKGl0ZW06IHN0cmluZykgPT4gYFxcXFwke2l0ZW19YCkuam9pbignfCcpLFxuICAgICAgJ2dpJ1xuICAgICk7XG4gIH1cbn1cbiJdfQ==

@@ -487,2 +487,18 @@ import { __awaiter } from 'tslib';

const result = super.applyMask(inputValue, maskExpression, position, cb);
if (this.maskExpression === 'dot_separator.2' && this.dropSpecialCharacters === true) {
this.maskSpecialCharacters = this.maskSpecialCharacters.filter((/**
* @param {?} item
* @return {?}
*/
(item) => item !== ','));
}
if ((this.maskExpression === 'coma_separator.2' && this.dropSpecialCharacters === true)) {
this.maskSpecialCharacters = this.maskSpecialCharacters.filter((/**
* @param {?} item
* @return {?}
*/
(item) => item !== '.'));
}
// tslint:disable-next-line:no-console
console.table(this.maskSpecialCharacters, this.dropSpecialCharacters, this.maskExpression);
Array.isArray(this.dropSpecialCharacters)

@@ -489,0 +505,0 @@ ? this.onChange(this._removeMask(this._removeSufix(this._removePrefix(result)), this.dropSpecialCharacters))

@@ -517,2 +517,18 @@ import { NG_VALUE_ACCESSOR } from '@angular/forms';

var result = _super.prototype.applyMask.call(this, inputValue, maskExpression, position, cb);
if (this.maskExpression === 'dot_separator.2' && this.dropSpecialCharacters === true) {
this.maskSpecialCharacters = this.maskSpecialCharacters.filter((/**
* @param {?} item
* @return {?}
*/
function (item) { return item !== ','; }));
}
if ((this.maskExpression === 'coma_separator.2' && this.dropSpecialCharacters === true)) {
this.maskSpecialCharacters = this.maskSpecialCharacters.filter((/**
* @param {?} item
* @return {?}
*/
function (item) { return item !== '.'; }));
}
// tslint:disable-next-line:no-console
console.table(this.maskSpecialCharacters, this.dropSpecialCharacters, this.maskExpression);
Array.isArray(this.dropSpecialCharacters)

@@ -519,0 +535,0 @@ ? this.onChange(this._removeMask(this._removeSufix(this._removePrefix(result)), this.dropSpecialCharacters))

{
"name": "ngx-mask",
"version": "7.4.0",
"version": "7.4.1",
"description": "awesome ngx mask",

@@ -5,0 +5,0 @@ "license": "MIT",

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc