=0;m--)if((u=C().validPositions[m])&&u.alternation!==n){if(c&&c.locator[u.alternation]!==u.locator[u.alternation])break;s=m,l=C().validPositions[s].alternation,c=u}if(l!==n){h=parseInt(s),C().excludes[h]=C().excludes[h]||[],!0!==e&&C().excludes[h].push(N(c));var g=[],y=0;for(d=h;d0;){var w=k.shift();if(!(v=U(P(n,!0)+1,w,!1,o,!0)))break}if(v&&i!==n){var x=P(e)+1;for(d=h;d
x?x:e,i,r,o,!0)}if(v)break;if(T(),c=D(h),C().validPositions=t.extend(!0,{},p),!C().excludes[h]){v=z(e,i,r,o,h-1);break}var _=N(c);if(-1!==C().excludes[h].indexOf(_)){v=z(e,i,r,o,h-1);break}for(C().excludes[h].push(_),d=h;d
1||t.begin-t.end==1:t.end-t.begin>1||t.end-t.begin==1}r=!0===r;var u=e;function c(i,r,a){var s=!1;return t.each(R(i),function(u,c){var d=c.match;if($(!0),!1!==(s=null!=d.fn?d.fn.test(r,C(),i,a,f,l(e)):(r===d.def||r===f.skipOptionalPartCharacter)&&""!==d.def&&{c:X(i,d,!0)||d.def,pos:i})){var h=s.c!==n?s.c:r,p=i;return h=h===f.skipOptionalPartCharacter&&null===d.fn?X(i,d,!0)||d.def:h,s.remove!==n&&(t.isArray(s.remove)||(s.remove=[s.remove]),t.each(s.remove.sort(function(t,e){return e-t}),function(t,e){K({begin:e,end:e+1})})),s.insert!==n&&(t.isArray(s.insert)||(s.insert=[s.insert]),t.each(s.insert.sort(function(t,e){return t-e}),function(t,e){U(e.pos,e.c,!0,o)})),!0!==s&&s.pos!==n&&s.pos!==i&&(p=s.pos),(!0===s||s.pos!==n||s.c!==n)&&(K(e,t.extend({},c,{input:B(h,d,p)}),o,p)||(s=!1),!1)}}),s}e.begin!==n&&(u=x?e.end:e.begin);var d=!0,h=t.extend(!0,{},C().validPositions);if(t.isFunction(f.preValidation)&&!r&&!0!==o&&!0!==s&&(d=f.preValidation($(),u,i,l(e),f,C())),!0===d){if(V(n,u,!0),(g===n||u0&&!C().validPositions[e];e--);for(var a=e;at+1?e[t+1]&&null===e[t+1].match.fn&&e[t+1]:e[t+1];return o&&a}return!1}var s=e.begin!==n?e.begin:e,l=e.end!==n?e.end:e;if(e.begin>e.end&&(s=e.end,l=e.begin),o=o!==n?o:s,s!==l||f.insertMode&&C().validPositions[o]!==n&&r===n){var u=t.extend(!0,{},C().validPositions),c=P(n,!0);for(C().p=s,m=c;m>=s;m--)C().validPositions[m]&&"+"===C().validPositions[m].match.nativeDef&&(f.isNegative=!1),delete C().validPositions[m];var d=!0,h=o,p=(C().validPositions,!1),v=h,m=h;for(i&&(C().validPositions[o]=t.extend(!0,{},i),v++,h++,s=l||m>=s&&!0!==g.generatedInput&&a(m,u,{begin:s,end:l}))){for(;""!==D(v).match.def;){if(!1===p&&u[v]&&u[v].match.nativeDef===g.match.nativeDef)C().validPositions[v]=t.extend(!0,{},u[v]),C().validPositions[v].input=g.input,V(n,v,!0),h=v+1,d=!0;else if(f.shiftPositions&&j(v,g.match.def)){var y=U(v,g.input,!0,!0);d=!1!==y,h=y.caret||y.insert?P():v+1,p=!0}else d=!0===g.generatedInput||g.input===f.radixPoint&&!0===f.numericInput;if(d)break;if(!d&&v>l&&W(v,!0)&&(null!==g.match.fn||v>C().maskLength))break;v++}""==D(v).match.def&&(d=!1),v=h}if(!d)break}if(!d)return C().validPositions=t.extend(!0,{},u),T(!0),!1}else i&&(C().validPositions[o]=t.extend(!0,{},i));return T(!0),!0}function W(t,e){var n=M(t).match;if(""===n.def&&(n=D(t).match),null!=n.fn)return n.fn;if(!0!==e&&t>-1){var i=R(t);return i.length>1+(""===i[i.length-1].match.def?1:0)}return!1}function G(t,e){for(var n=t+1;""!==D(n).match.def&&(!0===e&&(!0!==D(n).match.newBlockMarker||!W(n))||!0!==e&&!W(n));)n++;return n}function Y(t,e){var n,i=t;if(i<=0)return 0;for(;--i>0&&(!0===e&&!0!==D(i).match.newBlockMarker||!0!==e&&!W(i)&&((n=R(i)).length<2||2===n.length&&""===n[1].match.def)););return i}function Z(e,i,r,o,a){if(o&&t.isFunction(f.onBeforeWrite)){var s=f.onBeforeWrite.call(k,o,i,r,f);if(s){if(s.refreshFromBuffer){var l=s.refreshFromBuffer;H(!0===l?l:l.start,l.end,s.buffer||i),i=$(!0)}r!==n&&(r=s.caret!==n?s.caret:r)}}if(e!==n&&(e.inputmask._valueSet(i.join("")),r===n||o!==n&&"blur"===o.type?ct(e,r,0===i.length):rt(e,r),!0===a)){var u=t(e),c=e.inputmask._valueGet();E=!0,u.trigger("input"),setTimeout(function(){c===F().join("")?u.trigger("cleared"):!0===st(i)&&u.trigger("complete")},0)}}function X(e,i,r){if((i=i||D(e).match).placeholder!==n||!0===r)return t.isFunction(i.placeholder)?i.placeholder(f):i.placeholder;if(null===i.fn){if(e>-1&&C().validPositions[e]===n){var o,a=R(e),s=[];if(a.length>1+(""===a[a.length-1].match.def?1:0))for(var l=0;l1&&/[0-9a-bA-Z]/.test(s[0].match.def)))return f.placeholder.charAt(e%f.placeholder.length)}return i.def}return f.placeholder.charAt(e%f.placeholder.length)}function Q(t,e){if(o){if(t.inputmask._valueGet()!==e&&(t.placeholder!==e||""===t.placeholder)){var n=$().slice(),i=t.inputmask._valueGet();if(i!==e){var r=P();-1===r&&i===F().join("")?n=[]:-1!==r&&at(n),Z(t,n)}}}else t.placeholder!==e&&(t.placeholder=e,""===t.placeholder&&t.removeAttribute("placeholder"))}var J,tt={on:function(e,i,r){var o=function(e){var i=this;if(i.inputmask===n&&"FORM"!==this.nodeName){var o=t.data(i,"_inputmask_opts");o?new c(o).mask(i):tt.off(i)}else{if("setvalue"===e.type||"FORM"===this.nodeName||!(i.disabled||i.readOnly&&!("keydown"===e.type&&e.ctrlKey&&67===e.keyCode||!1===f.tabThrough&&e.keyCode===c.keyCode.TAB))){switch(e.type){case"input":if(!0===E)return E=!1,e.preventDefault();if(s){var a=arguments;return setTimeout(function(){r.apply(i,a),rt(i,i.inputmask.caretPos,n,!0)},0),!1}break;case"keydown":_=!1,E=!1;break;case"keypress":if(!0===_)return e.preventDefault();_=!0;break;case"click":if(l||u){var a=arguments;return setTimeout(function(){r.apply(i,a)},0),!1}}var d=r.apply(i,arguments);return!1===d&&(e.preventDefault(),e.stopPropagation()),d}e.preventDefault()}};e.inputmask.events[i]=e.inputmask.events[i]||[],e.inputmask.events[i].push(o),-1!==t.inArray(i,["submit","reset"])?null!==e.form&&t(e.form).on(i,o):t(e).on(i,o)},off:function(e,n){var i;e.inputmask&&e.inputmask.events&&(n?(i=[])[n]=e.inputmask.events[n]:i=e.inputmask.events,t.each(i,function(n,i){for(;i.length>0;){var r=i.pop();-1!==t.inArray(n,["submit","reset"])?null!==e.form&&t(e.form).off(n,r):t(e).off(n,r)}delete e.inputmask.events[n]}))}},et={keydownEvent:function(e){var n=t(this),i=e.keyCode,r=rt(this);if(i===c.keyCode.BACKSPACE||i===c.keyCode.DELETE||u&&i===c.keyCode.BACKSPACE_SAFARI||e.ctrlKey&&i===c.keyCode.X&&!h("cut"))e.preventDefault(),lt(0,i,r),Z(this,$(!0),C().p,e,this.inputmask._valueGet()!==$().join(""));else if(i===c.keyCode.END||i===c.keyCode.PAGE_DOWN){e.preventDefault();var o=G(P());rt(this,e.shiftKey?r.begin:o,o,!0)}else i===c.keyCode.HOME&&!e.shiftKey||i===c.keyCode.PAGE_UP?(e.preventDefault(),rt(this,0,e.shiftKey?r.begin:0,!0)):(f.undoOnEscape&&i===c.keyCode.ESCAPE||90===i&&e.ctrlKey)&&!0!==e.altKey?(nt(this,!0,!1,v.split("")),n.trigger("click")):i!==c.keyCode.INSERT||e.shiftKey||e.ctrlKey?!0===f.tabThrough&&i===c.keyCode.TAB&&(!0===e.shiftKey?(null===D(r.begin).match.fn&&(r.begin=G(r.begin)),r.end=Y(r.begin,!0),r.begin=Y(r.end,!0)):(r.begin=G(r.begin,!0),r.end=G(r.begin,!0),r.endo.length?-1:0,s=i.substr(0,r.begin),u=i.substr(r.begin),d=o.substr(0,r.begin+a),h=o.substr(r.begin+a),p=r,v="",m=!1;if(s!==d){var g,y=(m=s.length>=d.length)?s.length:d.length;for(g=0;s.charAt(g)===d.charAt(g)&&gh.length?v+=u.slice(0,1):u.length0)t.each(v.split(""),function(e,i){var r=new t.Event("keypress");r.which=i.charCodeAt(0),S=!1,et.keypressEvent.call(n,r)});else{p.begin===p.end-1&&(p.begin=Y(p.begin+1),p.begin===p.end-1?rt(n,p.begin):rt(n,p.begin,p.end));var b=new t.Event("keydown");b.keyCode=f.numericInput?c.keyCode.BACKSPACE:c.keyCode.DELETE,et.keydownEvent.call(n,b)}e.preventDefault()}}},beforeInputEvent:function(e){if(e.cancelable){var n=this;switch(e.inputType){case"insertText":return t.each(e.data.split(""),function(e,i){var r=new t.Event("keypress");r.which=i.charCodeAt(0),S=!1,et.keypressEvent.call(n,r)}),e.preventDefault();case"deleteContentBackward":var i=new t.Event("keydown");return i.keyCode=c.keyCode.BACKSPACE,et.keydownEvent.call(n,i),e.preventDefault();case"deleteContentForward":var i=new t.Event("keydown");return i.keyCode=c.keyCode.DELETE,et.keydownEvent.call(n,i),e.preventDefault()}}},setValueEvent:function(e){this.inputmask.refreshValue=!1;var n=e&&e.detail?e.detail[0]:arguments[1],n=n||this.inputmask._valueGet(!0);t.isFunction(f.onBeforeMask)&&(n=f.onBeforeMask.call(k,n,f)||n),nt(this,!0,!1,n=n.toString().split("")),v=$().join(""),(f.clearMaskOnLostFocus||f.clearIncomplete)&&this.inputmask._valueGet()===F().join("")&&this.inputmask._valueSet("")},focusEvent:function(t){var e=this.inputmask._valueGet();f.showMaskOnFocus&&(e!==$().join("")?Z(this,$(),G(P())):!1===O&&rt(this,G(P()))),!0===f.positionCaretOnTab&&!1===O&&et.clickEvent.apply(this,[t,!0]),v=$().join("")},mouseleaveEvent:function(t){O=!1,f.clearMaskOnLostFocus&&i.activeElement!==this&&Q(this,b)},clickEvent:function(e,r){var o=this;setTimeout(function(){if(i.activeElement===o){var e=rt(o);if(r&&(x?e.end=e.begin:e.begin=e.end),e.begin===e.end)switch(f.positionCaretOnClick){case"none":break;case"select":rt(o,0,$().length);break;case"ignore":rt(o,G(P()));break;case"radixFocus":if(function(e){if(""!==f.radixPoint){var i=C().validPositions;if(i[e]===n||i[e].input===X(e)){if(e=p||s===u)&&(u=p)}rt(o,u)}}}},0)},cutEvent:function(n){t(this);var r=rt(this),o=n.originalEvent||n,a=e.clipboardData||o.clipboardData,s=x?$().slice(r.end,r.begin):$().slice(r.begin,r.end);a.setData("text",x?s.reverse().join(""):s.join("")),i.execCommand&&i.execCommand("copy"),lt(0,c.keyCode.DELETE,r),Z(this,$(),C().p,n,v!==$().join(""))},blurEvent:function(e){var i=t(this);if(this.inputmask){Q(this,b);var r=this.inputmask._valueGet(),o=$().slice();""===r&&y===n||(f.clearMaskOnLostFocus&&(-1===P()&&r===F().join("")?o=[]:at(o)),!1===st(o)&&(setTimeout(function(){i.trigger("incomplete")},0),f.clearIncomplete&&(T(),o=f.clearMaskOnLostFocus?[]:F().slice())),Z(this,o,n,e)),v!==$().join("")&&(v=o.join(""),i.trigger("change"))}},mouseenterEvent:function(t){O=!0,i.activeElement!==this&&f.showMaskOnHover&&Q(this,(x?$().slice().reverse():$()).join(""))},submitEvent:function(t){v!==$().join("")&&m.trigger("change"),f.clearMaskOnLostFocus&&-1===P()&&w.inputmask._valueGet&&w.inputmask._valueGet()===F().join("")&&w.inputmask._valueSet(""),f.clearIncomplete&&!1===st($())&&w.inputmask._valueSet(""),f.removeMaskOnSubmit&&(w.inputmask._valueSet(w.inputmask.unmaskedvalue(),!0),setTimeout(function(){Z(w,$())},0))},resetEvent:function(t){w.inputmask.refreshValue=!0,setTimeout(function(){m.trigger("setvalue")},0)}};function nt(e,i,r,o,a){var s=this||e.inputmask,l=o.slice(),u="",d=-1,h=n;if(T(),r||!0===f.autoUnmask)d=G(d);else{var p=F().slice(0,G(-1)).join(""),v=l.join("").match(new RegExp("^"+c.escapeRegex(p),"g"));v&&v.length>0&&(l.splice(0,v.length*p.length),d=G(d))}-1===d?(C().p=G(d),d=0):C().p=d,s.caretPos={begin:d},t.each(l,function(i,o){if(o!==n)if(C().validPositions[i]===n&&l[i]===X(i)&&W(i,!0)&&!1===U(i,l[i],!0,n,n,!0))C().p++;else{var a=new t.Event("_checkval");a.which=o.charCodeAt(0),u+=o;var c=P(n,!0);!function(t,e){return-1!==A(!0,0,!1).slice(t,G(t)).join("").replace(/'/g,"").indexOf(e)&&!W(t)&&(D(t).match.nativeDef===e.charAt(0)||null===D(t).match.fn&&D(t).match.nativeDef==="'"+e.charAt(0)||" "===D(t).match.nativeDef&&(D(t+1).match.nativeDef===e.charAt(0)||null===D(t+1).match.fn&&D(t+1).match.nativeDef==="'"+e.charAt(0)))}(d,u)?(h=et.keypressEvent.call(e,a,!0,!1,r,s.caretPos.begin))&&(d=s.caretPos.begin+1,u=""):h=et.keypressEvent.call(e,a,!0,!1,r,c+1),h&&(Z(n,$(),h.forwardPosition,a,!1),s.caretPos={begin:h.forwardPosition,end:h.forwardPosition})}}),i&&Z(e,$(),h?h.forwardPosition:n,a||new t.Event("checkval"),a&&"input"===a.type)}function it(e){if(e){if(e.inputmask===n)return e.value;e.inputmask&&e.inputmask.refreshValue&&et.setValueEvent.call(e)}var i=[],r=C().validPositions;for(var o in r)r[o].match&&null!=r[o].match.fn&&i.push(r[o].input);var a=0===i.length?"":(x?i.reverse():i).join("");if(t.isFunction(f.onUnMask)){var s=(x?$().slice().reverse():$()).join("");a=f.onUnMask.call(k,s,a,f)}return a}function rt(r,o,a,s){function l(t){return!x||"number"!=typeof t||f.greedy&&""===f.placeholder||!w||(t=w.inputmask._valueGet().length-t),t}var u;if(o===n)return"selectionStart"in r?(o=r.selectionStart,a=r.selectionEnd):e.getSelection?(u=e.getSelection().getRangeAt(0)).commonAncestorContainer.parentNode!==r&&u.commonAncestorContainer!==r||(o=u.startOffset,a=u.endOffset):i.selection&&i.selection.createRange&&(u=i.selection.createRange(),o=0-u.duplicate().moveStart("character",-r.inputmask._valueGet().length),a=o+u.text.length),{begin:s?o:l(o),end:s?a:l(a)};if(t.isArray(o)&&(a=x?o[0]:o[1],o=x?o[1]:o[0]),o.begin!==n&&(a=x?o.begin:o.end,o=x?o.end:o.begin),"number"==typeof o){o=s?o:l(o),a="number"==typeof(a=s?a:l(a))?a:o;var c=parseInt(((r.ownerDocument.defaultView||e).getComputedStyle?(r.ownerDocument.defaultView||e).getComputedStyle(r,null):r.currentStyle).fontSize)*a;if(r.scrollLeft=c>r.scrollWidth?c:0,r.inputmask.caretPos={begin:o,end:a},r===i.activeElement){if("selectionStart"in r)r.selectionStart=o,r.selectionEnd=a;else if(e.getSelection){if(u=i.createRange(),r.firstChild===n||null===r.firstChild){var d=i.createTextNode("");r.appendChild(d)}u.setStart(r.firstChild,os&&((r=l[i]).match.optionality||r.match.optionalQuantifier&&r.match.newBlockMarker||d&&(d!==l[i].locator[u.alternation]&&null!=r.match.fn||null===r.match.fn&&r.locator[u.alternation]&&q(r.locator[u.alternation].toString().split(","),d.toString().split(","))&&""!==R(i)[0].def))&&o[i]===X(i,r.match);i--)a--;return e?{l:a,def:l[a]?l[a].match:n}:a}function at(t){t.length=0;for(var e,i=A(!0,0,!0,n,!0);(e=i.shift())!==n;)t.push(e);return t}function st(e){if(t.isFunction(f.isComplete))return f.isComplete(e,f);if("*"===f.repeat)return n;var i=!1,r=ot(!0),o=Y(r.l);if(r.def===n||r.def.newBlockMarker||r.def.optionality||r.def.optionalQuantifier){i=!0;for(var a=0;a<=o;a++){var s=M(a).match;if(null!==s.fn&&C().validPositions[a]===n&&!0!==s.optionality&&!0!==s.optionalQuantifier||null===s.fn&&e[a]!==X(a,s)){i=!1;break}}}return i}function lt(t,e,i,r,o){if((f.numericInput||x)&&(e===c.keyCode.BACKSPACE?e=c.keyCode.DELETE:e===c.keyCode.DELETE&&(e=c.keyCode.BACKSPACE),x)){var a=i.end;i.end=i.begin,i.begin=a}if(e===c.keyCode.BACKSPACE&&i.end-i.begin<1?(i.begin=Y(i.begin),C().validPositions[i.begin]!==n&&C().validPositions[i.begin].input===f.groupSeparator&&i.begin--):e===c.keyCode.DELETE&&i.begin===i.end&&(i.end=W(i.end,!0)&&C().validPositions[i.end]&&C().validPositions[i.end].input!==f.radixPoint?i.end+1:G(i.end)+1,C().validPositions[i.begin]!==n&&C().validPositions[i.begin].input===f.groupSeparator&&i.end++),K(i),!0!==r&&!1!==f.keepStatic||null!==f.regex){var s=z(!0);if(s){var l=s.caret!==n?s.caret:s.pos?G(s.pos.begin?s.pos.begin:s.pos):P(-1,!0);(e!==c.keyCode.DELETE||i.begin>l)&&i.begin}}var u=P(i.begin,!0);if(u=t){var c=t-u,d=o.offsetWidth-t;o.innerHTML=l.charAt(e),c-=o.offsetWidth/3,e=c",l.push(t)}else l.push(t);else u=!0,l.push(""+t)}if(y!==n){var h=$();if(e===n?e=rt(t):e.begin===n&&(e={begin:e,end:e}),!0!==r){var p=P();do{C().validPositions[c]?(a=C().validPositions[c],o=a.match,s=a.locator.slice(),d(h[c])):(a=M(c,s,c-1),o=a.match,s=a.locator.slice(),!1===f.jitMasking||cc?d(X(c,o)):u=!1),c++}while((g===n||cc||u);u&&d(),i.activeElement===t&&(l.splice(e.begin,0,e.begin===e.end||e.end>C().maskLength?'':''),l.splice(e.end+1,0,""))}var v=y.getElementsByTagName("div")[0];v.innerHTML=l.join(""),t.inputmask.positionColorMask(t,v)}}if(r!==n)switch(r.action){case"isComplete":return w=r.el,st($());case"unmaskedvalue":return w!==n&&r.value===n||(J=r.value,J=(t.isFunction(f.onBeforeMask)&&f.onBeforeMask.call(k,J,f)||J).split(""),nt.call(this,n,!1,!1,J),t.isFunction(f.onBeforeWrite)&&f.onBeforeWrite.call(k,n,$(),0,f)),it(w);case"mask":!function(e){tt.off(e);var r=function(e,r){var o=e.getAttribute("type"),s="INPUT"===e.tagName&&-1!==t.inArray(o,r.supportsInputType)||e.isContentEditable||"TEXTAREA"===e.tagName;if(!s)if("INPUT"===e.tagName){var l=i.createElement("input");l.setAttribute("type",o),s="text"===l.type,l=null}else s="partial";return!1!==s?function(e){var o,s;function l(){return this.inputmask?this.inputmask.opts.autoUnmask?this.inputmask.unmaskedvalue():-1!==P()||!0!==r.nullable?i.activeElement===this&&r.clearMaskOnLostFocus?(x?at($().slice()).reverse():at($().slice())).join(""):o.call(this):"":o.call(this)}function u(e){s.call(this,e),this.inputmask&&t(this).trigger("setvalue",[e])}if(!e.inputmask.__valueGet){if(!0!==r.noValuePatching){if(Object.getOwnPropertyDescriptor){"function"!=typeof Object.getPrototypeOf&&(Object.getPrototypeOf="object"===a("test".__proto__)?function(t){return t.__proto__}:function(t){return t.constructor.prototype});var c=Object.getPrototypeOf?Object.getOwnPropertyDescriptor(Object.getPrototypeOf(e),"value"):n;c&&c.get&&c.set?(o=c.get,s=c.set,Object.defineProperty(e,"value",{get:l,set:u,configurable:!0})):"INPUT"!==e.tagName&&(o=function(){return this.textContent},s=function(t){this.textContent=t},Object.defineProperty(e,"value",{get:l,set:u,configurable:!0}))}else i.__lookupGetter__&&e.__lookupGetter__("value")&&(o=e.__lookupGetter__("value"),s=e.__lookupSetter__("value"),e.__defineGetter__("value",l),e.__defineSetter__("value",u));e.inputmask.__valueGet=o,e.inputmask.__valueSet=s}e.inputmask._valueGet=function(t){return x&&!0!==t?o.call(this.el).split("").reverse().join(""):o.call(this.el)},e.inputmask._valueSet=function(t,e){s.call(this.el,null===t||t===n?"":!0!==e&&x?t.split("").reverse().join(""):t)},o===n&&(o=function(){return this.value},s=function(t){this.value=t},function(e){if(t.valHooks&&(t.valHooks[e]===n||!0!==t.valHooks[e].inputmaskpatch)){var i=t.valHooks[e]&&t.valHooks[e].get?t.valHooks[e].get:function(t){return t.value},o=t.valHooks[e]&&t.valHooks[e].set?t.valHooks[e].set:function(t,e){return t.value=e,t};t.valHooks[e]={get:function(t){if(t.inputmask){if(t.inputmask.opts.autoUnmask)return t.inputmask.unmaskedvalue();var e=i(t);return-1!==P(n,n,t.inputmask.maskset.validPositions)||!0!==r.nullable?e:""}return i(t)},set:function(e,n){var i,r=t(e);return i=o(e,n),e.inputmask&&r.trigger("setvalue",[n]),i},inputmaskpatch:!0}}}(e.type),function(e){tt.on(e,"mouseenter",function(e){var n=t(this),i=this.inputmask._valueGet();i!==$().join("")&&n.trigger("setvalue")})}(e))}}(e):e.inputmask=n,s}(e,f);if(!1!==r&&(m=t(w=e),b=w.placeholder,-1===(g=w!==n?w.maxLength:n)&&(g=n),!0===f.colorMask&&ut(w),s&&("inputMode"in w&&(w.inputmode=f.inputmode,w.setAttribute("inputmode",f.inputmode)),!0===f.disablePredictiveText&&("autocorrect"in w?w.autocorrect=!1:(!0!==f.colorMask&&ut(w),w.type="password"))),!0===r&&(w.setAttribute("im-insert",f.insertMode),tt.on(w,"submit",et.submitEvent),tt.on(w,"reset",et.resetEvent),tt.on(w,"blur",et.blurEvent),tt.on(w,"focus",et.focusEvent),!0!==f.colorMask&&(tt.on(w,"click",et.clickEvent),tt.on(w,"mouseleave",et.mouseleaveEvent),tt.on(w,"mouseenter",et.mouseenterEvent)),tt.on(w,"paste",et.pasteEvent),tt.on(w,"cut",et.cutEvent),tt.on(w,"complete",f.oncomplete),tt.on(w,"incomplete",f.onincomplete),tt.on(w,"cleared",f.oncleared),s||!0===f.inputEventOnly?w.removeAttribute("maxLength"):(tt.on(w,"keydown",et.keydownEvent),tt.on(w,"keypress",et.keypressEvent)),tt.on(w,"input",et.inputFallBackEvent),tt.on(w,"beforeinput",et.beforeInputEvent)),tt.on(w,"setvalue",et.setValueEvent),v=F().join(""),""!==w.inputmask._valueGet(!0)||!1===f.clearMaskOnLostFocus||i.activeElement===w)){var o=t.isFunction(f.onBeforeMask)&&f.onBeforeMask.call(k,w.inputmask._valueGet(!0),f)||w.inputmask._valueGet(!0);""!==o&&nt(w,!0,!1,o.split(""));var l=$().slice();v=l.join(""),!1===st(l)&&f.clearIncomplete&&T(),f.clearMaskOnLostFocus&&i.activeElement!==w&&(-1===P()?l=[]:at(l)),(!1===f.clearMaskOnLostFocus||f.showMaskOnFocus&&i.activeElement===w||""!==w.inputmask._valueGet(!0))&&Z(w,l),i.activeElement===w&&rt(w,G(P()))}}(w);break;case"format":return J=(t.isFunction(f.onBeforeMask)&&f.onBeforeMask.call(k,r.value,f)||r.value).split(""),nt.call(this,n,!0,!1,J),r.metadata?{value:x?$().slice().reverse().join(""):$().join(""),metadata:p.call(this,{action:"getmetadata"},d,f)}:x?$().slice().reverse().join(""):$().join("");case"isValid":r.value?(J=r.value.split(""),nt.call(this,n,!0,!0,J)):r.value=$().join("");for(var dt=$(),ft=ot(),ht=dt.length-1;ht>ft&&!W(ht);ht--);return dt.splice(ft,ht+1-ft),st(dt)&&r.value===$().join("");case"getemptymask":return F().join("");case"remove":return w&&w.inputmask&&(t.data(w,"_inputmask_opts",null),m=t(w),w.inputmask._valueSet(f.autoUnmask?it(w):w.inputmask._valueGet(!0)),tt.off(w),w.inputmask.colorMask&&((y=w.inputmask.colorMask).removeChild(w),y.parentNode.insertBefore(w,y),y.parentNode.removeChild(y)),Object.getOwnPropertyDescriptor&&Object.getPrototypeOf?Object.getOwnPropertyDescriptor(Object.getPrototypeOf(w),"value")&&w.inputmask.__valueGet&&Object.defineProperty(w,"value",{get:w.inputmask.__valueGet,set:w.inputmask.__valueSet,configurable:!0}):i.__lookupGetter__&&w.__lookupGetter__("value")&&w.inputmask.__valueGet&&(w.__defineGetter__("value",w.inputmask.__valueGet),w.__defineSetter__("value",w.inputmask.__valueSet)),w.inputmask=n),w;case"getmetadata":if(t.isArray(d.metadata)){var pt=A(!0,0,!1).join("");return t.each(d.metadata,function(t,e){if(e.mask===pt)return pt=e,!1}),pt}return d.metadata}}return c.prototype={dataAttribute:"data-inputmask",defaults:{placeholder:"_",optionalmarker:["[","]"],quantifiermarker:["{","}"],groupmarker:["(",")"],alternatormarker:"|",escapeChar:"\\",mask:null,regex:null,oncomplete:t.noop,onincomplete:t.noop,oncleared:t.noop,repeat:0,greedy:!1,autoUnmask:!1,removeMaskOnSubmit:!1,clearMaskOnLostFocus:!0,insertMode:!0,clearIncomplete:!1,alias:null,onKeyDown:t.noop,onBeforeMask:null,onBeforePaste:function(e,n){return t.isFunction(n.onBeforeMask)?n.onBeforeMask.call(this,e,n):e},onBeforeWrite:null,onUnMask:null,showMaskOnFocus:!0,showMaskOnHover:!0,onKeyValidation:t.noop,skipOptionalPartCharacter:" ",numericInput:!1,rightAlign:!1,undoOnEscape:!0,radixPoint:"",_radixDance:!1,groupSeparator:"",keepStatic:null,positionCaretOnTab:!0,tabThrough:!1,supportsInputType:["text","tel","url","password","search"],ignorables:[8,9,13,19,27,33,34,35,36,37,38,39,40,45,46,93,112,113,114,115,116,117,118,119,120,121,122,123,0,229],isComplete:null,preValidation:null,postValidation:null,staticDefinitionSymbol:n,jitMasking:!1,nullable:!0,inputEventOnly:!1,noValuePatching:!1,positionCaretOnClick:"lvp",casing:null,inputmode:"verbatim",colorMask:!1,disablePredictiveText:!1,importDataAttributes:!0,shiftPositions:!0},definitions:{9:{validator:"[0-91-9]",definitionSymbol:"*"},a:{validator:"[A-Za-zА-яЁёÀ-ÿµ]",definitionSymbol:"*"},"*":{validator:"[0-91-9A-Za-zА-яЁёÀ-ÿµ]"}},aliases:{},masksCache:{},mask:function(r){var o=this;return"string"==typeof r&&(r=i.getElementById(r)||i.querySelectorAll(r)),r=r.nodeName?[r]:r,t.each(r,function(i,r){var a=t.extend(!0,{},o.opts);if(function(i,r,o,a){if(!0===r.importDataAttributes){var s,l,u,c,f=i.getAttribute(a),h=function(t,r){null!==(r=r!==n?r:i.getAttribute(a+"-"+t))&&("string"==typeof r&&(0===t.indexOf("on")?r=e[r]:"false"===r?r=!1:"true"===r&&(r=!0)),o[t]=r)};if(f&&""!==f&&(f=f.replace(/'/g,'"'),l=JSON.parse("{"+f+"}")),l)for(c in u=n,l)if("alias"===c.toLowerCase()){u=l[c];break}for(s in h("alias",u),o.alias&&d(o.alias,o,r),r){if(l)for(c in u=n,l)if(c.toLowerCase()===s.toLowerCase()){u=l[c];break}h(s,u)}}return t.extend(!0,r,o),("rtl"===i.dir||r.rightAlign)&&(i.style.textAlign="right"),("rtl"===i.dir||r.numericInput)&&(i.dir="ltr",i.removeAttribute("dir"),r.isRTL=!0),Object.keys(o).length}(r,a,t.extend(!0,{},o.userOptions),o.dataAttribute)){var s=f(a,o.noMasksCache);s!==n&&(r.inputmask!==n&&(r.inputmask.opts.autoUnmask=!0,r.inputmask.remove()),r.inputmask=new c(n,n,!0),r.inputmask.opts=a,r.inputmask.noMasksCache=o.noMasksCache,r.inputmask.userOptions=t.extend(!0,{},o.userOptions),r.inputmask.isRTL=a.isRTL||a.numericInput,r.inputmask.el=r,r.inputmask.maskset=s,t.data(r,"_inputmask_opts",a),p.call(r.inputmask,{action:"mask"}))}}),r&&r[0]&&r[0].inputmask||this},option:function(e,n){return"string"==typeof e?this.opts[e]:"object"===(void 0===e?"undefined":a(e))?(t.extend(this.userOptions,e),this.el&&!0!==n&&this.mask(this.el),this):void 0},unmaskedvalue:function(t){return this.maskset=this.maskset||f(this.opts,this.noMasksCache),p.call(this,{action:"unmaskedvalue",value:t})},remove:function(){return p.call(this,{action:"remove"})},getemptymask:function(){return this.maskset=this.maskset||f(this.opts,this.noMasksCache),p.call(this,{action:"getemptymask"})},hasMaskedValue:function(){return!this.opts.autoUnmask},isComplete:function(){return this.maskset=this.maskset||f(this.opts,this.noMasksCache),p.call(this,{action:"isComplete"})},getmetadata:function(){return this.maskset=this.maskset||f(this.opts,this.noMasksCache),p.call(this,{action:"getmetadata"})},isValid:function(t){return this.maskset=this.maskset||f(this.opts,this.noMasksCache),p.call(this,{action:"isValid",value:t})},format:function(t,e){return this.maskset=this.maskset||f(this.opts,this.noMasksCache),p.call(this,{action:"format",value:t,metadata:e})},setValue:function(e){this.el&&t(this.el).trigger("setvalue",[e])},analyseMask:function(e,i,r){var o,a,s,l,u,d,f=/(?:[?*+]|\{[0-9\+\*]+(?:,[0-9\+\*]*)?(?:\|[0-9\+\*]*)?\})|[^.?*+^${[]()|\\]+|./g,h=/\[\^?]?(?:[^\\\]]+|\\[\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,p=!1,v=new y,m=[],g=[];function y(t,e,n,i){this.matches=[],this.openGroup=t||!1,this.alternatorGroup=!1,this.isGroup=t||!1,this.isOptional=e||!1,this.isQuantifier=n||!1,this.isAlternator=i||!1,this.quantifier={min:1,max:1}}function b(e,o,a){a=a!==n?a:e.matches.length;var s=e.matches[a-1];if(i)0===o.indexOf("[")||p&&/\\d|\\s|\\w]/i.test(o)||"."===o?e.matches.splice(a++,0,{fn:new RegExp(o,r.casing?"i":""),optionality:!1,newBlockMarker:s===n?"master":s.def!==o,casing:null,def:o,placeholder:n,nativeDef:o}):(p&&(o=o[o.length-1]),t.each(o.split(""),function(t,i){s=e.matches[a-1],e.matches.splice(a++,0,{fn:null,optionality:!1,newBlockMarker:s===n?"master":s.def!==i&&null!==s.fn,casing:null,def:r.staticDefinitionSymbol||i,placeholder:r.staticDefinitionSymbol!==n?i:n,nativeDef:(p?"'":"")+i})})),p=!1;else{var l=(r.definitions?r.definitions[o]:n)||c.prototype.definitions[o];l&&!p?e.matches.splice(a++,0,{fn:l.validator?"string"==typeof l.validator?new RegExp(l.validator,r.casing?"i":""):new function(){this.test=l.validator}:new RegExp("."),optionality:!1,newBlockMarker:s===n?"master":s.def!==(l.definitionSymbol||o),casing:l.casing,def:l.definitionSymbol||o,placeholder:l.placeholder,nativeDef:o}):(e.matches.splice(a++,0,{fn:null,optionality:!1,newBlockMarker:s===n?"master":s.def!==o&&null!==s.fn,casing:null,def:r.staticDefinitionSymbol||o,placeholder:r.staticDefinitionSymbol!==n?o:n,nativeDef:(p?"'":"")+o}),p=!1)}}function k(){if(m.length>0){if(b(l=m[m.length-1],a),l.isAlternator){u=m.pop();for(var t=0;t0?(l=m[m.length-1]).matches.push(u):v.matches.push(u)}}else b(v,a)}function w(t){var e=new y(!0);return e.openGroup=!1,e.matches=t,e}for(i&&(r.optionalmarker[0]=n,r.optionalmarker[1]=n);o=i?h.exec(e):f.exec(e);){if(a=o[0],i)switch(a.charAt(0)){case"?":a="{0,1}";break;case"+":case"*":a="{"+a+"}"}if(p)k();else switch(a.charAt(0)){case"(?=":case"(?!":case"(?<=":case"(?0){if((l=m[m.length-1]).matches.push(s),l.isAlternator){u=m.pop();for(var x=0;x0?(l=m[m.length-1]).matches.push(u):v.matches.push(u)}}else v.matches.push(s);else k();break;case r.optionalmarker[0]:m.push(new y(!1,!0));break;case r.groupmarker[0]:m.push(new y(!0));break;case r.quantifiermarker[0]:var _=new y(!1,!1,!0),E=(a=a.replace(/[{}]/g,"")).split("|"),S=E[0].split(","),O=isNaN(S[0])?S[0]:parseInt(S[0]),A=1===S.length?O:isNaN(S[1])?S[1]:parseInt(S[1]);"*"!==O&&"+"!==O||(O="*"===A?0:1),_.quantifier={min:O,max:A,jit:E[1]};var C=m.length>0?m[m.length-1].matches:v.matches;if((o=C.pop()).isAlternator){C.push(o),C=o.matches;var T=new y(!0),P=C.pop();C.push(T),C=T.matches,o=P}o.isGroup||(o=w([o])),C.push(o),C.push(_);break;case r.alternatormarker:var N=function(t){var e=t.pop();return e.isQuantifier&&(e=w([t.pop(),e])),e};if(m.length>0){var I=(l=m[m.length-1]).matches[l.matches.length-1];d=l.openGroup&&(I.matches===n||!1===I.isGroup&&!1===I.isAlternator)?m.pop():N(l.matches)}else d=N(v.matches);if(d.isAlternator)m.push(d);else if(d.alternatorGroup?(u=m.pop(),d.alternatorGroup=!1):u=new y(!1,!1,!1,!0),u.matches.push(d),m.push(u),d.openGroup){d.openGroup=!1;var L=new y(!0);L.alternatorGroup=!0,m.push(L)}break;default:k()}}for(;m.length>0;)s=m.pop(),v.matches.push(s);return v.matches.length>0&&(function e(o){o&&o.matches&&t.each(o.matches,function(t,a){var s=o.matches[t+1];(s===n||s.matches===n||!1===s.isQuantifier)&&a&&a.isGroup&&(a.isGroup=!1,i||(b(a,r.groupmarker[0],0),!0!==a.openGroup&&b(a,r.groupmarker[1]))),e(a)})}(v),g.push(v)),(r.numericInput||r.isRTL)&&function t(e){for(var i in e.matches=e.matches.reverse(),e.matches)if(e.matches.hasOwnProperty(i)){var o=parseInt(i);if(e.matches[i].isQuantifier&&e.matches[o+1]&&e.matches[o+1].isGroup){var a=e.matches[i];e.matches.splice(i,1),e.matches.splice(o+1,0,a)}e.matches[i].matches!==n?e.matches[i]=t(e.matches[i]):e.matches[i]=((s=e.matches[i])===r.optionalmarker[0]?s=r.optionalmarker[1]:s===r.optionalmarker[1]?s=r.optionalmarker[0]:s===r.groupmarker[0]?s=r.groupmarker[1]:s===r.groupmarker[1]&&(s=r.groupmarker[0]),s)}var s;return e}(g[0]),g},positionColorMask:function(t,e){t.style.left=e.offsetLeft+"px"}},c.extendDefaults=function(e){t.extend(!0,c.prototype.defaults,e)},c.extendDefinitions=function(e){t.extend(!0,c.prototype.definitions,e)},c.extendAliases=function(e){t.extend(!0,c.prototype.aliases,e)},c.format=function(t,e,n){return c(e).format(t,n)},c.unmask=function(t,e){return c(e).unmaskedvalue(t)},c.isValid=function(t,e){return c(e).isValid(t)},c.remove=function(e){"string"==typeof e&&(e=i.getElementById(e)||i.querySelectorAll(e)),e=e.nodeName?[e]:e,t.each(e,function(t,e){e.inputmask&&e.inputmask.remove()})},c.setValue=function(e,n){"string"==typeof e&&(e=i.getElementById(e)||i.querySelectorAll(e)),e=e.nodeName?[e]:e,t.each(e,function(e,i){i.inputmask?i.inputmask.setValue(n):t(i).trigger("setvalue",[n])})},c.escapeRegex=function(t){return t.replace(new RegExp("(\\"+["/",".","*","+","?","|","(",")","[","]","{","}","\\","$","^"].join("|\\")+")","gim"),"\\$1")},c.keyCode={BACKSPACE:8,BACKSPACE_SAFARI:127,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,INSERT:45,LEFT:37,PAGE_DOWN:34,PAGE_UP:33,RIGHT:39,SPACE:32,TAB:9,UP:38,X:88,CONTROL:17},c.dependencyLib=t,c})?i.apply(e,r):i)||(t.exports=o)},function(t,e,n){"use strict";var i,r,o;"function"==typeof Symbol&&Symbol.iterator;r=[n(4)],void 0===(o="function"==typeof(i=function(t){return t})?i.apply(e,r):i)||(t.exports=o)},function(t,e){t.exports=jQuery},function(module,exports,__webpack_require__){"use strict";var __WEBPACK_AMD_DEFINE_RESULT__,_typeof="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t};__WEBPACK_AMD_DEFINE_RESULT__=function(){return"undefined"!=typeof window?window:new(eval("require('jsdom').JSDOM"))("").window}.call(exports,__webpack_require__,exports,module),void 0===__WEBPACK_AMD_DEFINE_RESULT__||(module.exports=__WEBPACK_AMD_DEFINE_RESULT__)},function(t,e,n){"use strict";var i,r,o,a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t};r=[n(2)],void 0===(o="function"==typeof(i=function(t){var e=t.dependencyLib,n={d:["[1-9]|[12][0-9]|3[01]",Date.prototype.setDate,"day",Date.prototype.getDate],dd:["0[1-9]|[12][0-9]|3[01]",Date.prototype.setDate,"day",function(){return s(Date.prototype.getDate.call(this),2)}],ddd:[""],dddd:[""],m:["[1-9]|1[012]",Date.prototype.setMonth,"month",function(){return Date.prototype.getMonth.call(this)+1}],mm:["0[1-9]|1[012]",Date.prototype.setMonth,"month",function(){return s(Date.prototype.getMonth.call(this)+1,2)}],mmm:[""],mmmm:[""],yy:["[0-9]{2}",Date.prototype.setFullYear,"year",function(){return s(Date.prototype.getFullYear.call(this),2)}],yyyy:["[0-9]{4}",Date.prototype.setFullYear,"year",function(){return s(Date.prototype.getFullYear.call(this),4)}],h:["[1-9]|1[0-2]",Date.prototype.setHours,"hours",Date.prototype.getHours],hh:["0[1-9]|1[0-2]",Date.prototype.setHours,"hours",function(){return s(Date.prototype.getHours.call(this),2)}],hhh:["[0-9]+",Date.prototype.setHours,"hours",Date.prototype.getHours],H:["1?[0-9]|2[0-3]",Date.prototype.setHours,"hours",Date.prototype.getHours],HH:["0[0-9]|1[0-9]|2[0-3]",Date.prototype.setHours,"hours",function(){return s(Date.prototype.getHours.call(this),2)}],HHH:["[0-9]+",Date.prototype.setHours,"hours",Date.prototype.getHours],M:["[1-5]?[0-9]",Date.prototype.setMinutes,"minutes",Date.prototype.getMinutes],MM:["0[0-9]|1[0-9]|2[0-9]|3[0-9]|4[0-9]|5[0-9]",Date.prototype.setMinutes,"minutes",function(){return s(Date.prototype.getMinutes.call(this),2)}],ss:["[0-5][0-9]",Date.prototype.setSeconds,"seconds",function(){return s(Date.prototype.getSeconds.call(this),2)}],l:["[0-9]{3}",Date.prototype.setMilliseconds,"milliseconds",function(){return s(Date.prototype.getMilliseconds.call(this),3)}],L:["[0-9]{2}",Date.prototype.setMilliseconds,"milliseconds",function(){return s(Date.prototype.getMilliseconds.call(this),2)}],t:["[ap]"],tt:["[ap]m"],T:["[AP]"],TT:["[AP]M"],Z:[""],o:[""],S:[""]},i={isoDate:"yyyy-mm-dd",isoTime:"HH:MM:ss",isoDateTime:"yyyy-mm-dd'T'HH:MM:ss",isoUtcDateTime:"UTC:yyyy-mm-dd'T'HH:MM:ss'Z'"};function r(t){if(!t.tokenizer){var e=[];for(var i in n)-1===e.indexOf(i[0])&&e.push(i[0]);t.tokenizer="("+e.join("+|")+")+?|.",t.tokenizer=new RegExp(t.tokenizer,"g")}return t.tokenizer}function o(e,i,o,a){for(var s,l="";s=r(o).exec(e);)if(void 0===i)if(n[s[0]])l+="("+n[s[0]][0]+")";else switch(s[0]){case"[":l+="(";break;case"]":l+=")?";break;default:l+=t.escapeRegex(s[0])}else if(n[s[0]])if(!0!==a&&n[s[0]][3]){var u=n[s[0]][3];l+=u.call(i.date)}else n[s[0]][2]?l+=i["raw"+n[s[0]][2]]:l+=s[0];else l+=s[0];return l}function s(t,e){for(t=String(t),e=e||2;t.lengtha.slice(0,n.length)?a.slice(n.length):e.toString().slice(n.length))}return e}function f(t,e,n){t[o]=d(e),t["raw"+o]=e,void 0!==l&&l.call(t.date,"month"==o?parseInt(t[o])-1:t[o])}if("string"==typeof c){for(;s=r(i).exec(e);){var h=c.slice(0,s[0].length);n.hasOwnProperty(s[0])&&(n[s[0]][0],o=n[s[0]][2],l=n[s[0]][1],f(u,h)),c=c.slice(h.length)}return u}if(c&&"object"===(void 0===c?"undefined":a(c))&&c.hasOwnProperty("date"))return c}return t.extendAliases({datetime:{mask:function(t){return n.S=t.i18n.ordinalSuffix.join("|"),t.inputFormat=i[t.inputFormat]||t.inputFormat,t.displayFormat=i[t.displayFormat]||t.displayFormat||t.inputFormat,t.outputFormat=i[t.outputFormat]||t.outputFormat||t.inputFormat,t.placeholder=""!==t.placeholder?t.placeholder:t.inputFormat.replace(/[\[\]]/,""),t.regex=o(t.inputFormat,void 0,t),null},placeholder:"",inputFormat:"isoDateTime",displayFormat:void 0,outputFormat:void 0,min:null,max:null,i18n:{dayNames:["Mon","Tue","Wed","Thu","Fri","Sat","Sun","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","Sunday"],monthNames:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec","January","February","March","April","May","June","July","August","September","October","November","December"],ordinalSuffix:["st","nd","rd","th"]},postValidation:function(t,e,n,i){i.min=l(i.min,i.inputFormat,i),i.max=l(i.max,i.inputFormat,i);var r=n,a=l(t.join(""),i.inputFormat,i);return r&&a.date.getTime()==a.date.getTime()&&(r=(r=function(t,e){return(!isFinite(t.rawday)||"29"==t.day&&!isFinite(t.rawyear)||new Date(t.date.getFullYear(),isFinite(t.rawmonth)?t.month:t.date.getMonth()+1,0).getDate()>=t.day)&&e}(a,r))&&function(t,e){var n=!0;if(e.min){if(t.rawyear){var i=t.rawyear.replace(/[^0-9]/g,""),r=e.min.year.substr(0,i.length);n=r<=i}t.year===t.rawyear&&e.min.date.getTime()==e.min.date.getTime()&&(n=e.min.date.getTime()<=t.date.getTime())}return n&&e.max&&e.max.date.getTime()==e.max.date.getTime()&&(n=e.max.date.getTime()>=t.date.getTime()),n}(a,i)),e&&r&&n.pos!==e?{buffer:o(i.inputFormat,a,i),refreshFromBuffer:{start:e,end:n.pos}}:r},onKeyDown:function(n,i,o,a){if(n.ctrlKey&&n.keyCode===t.keyCode.RIGHT){for(var l,u=new Date,c="";l=r(a).exec(a.inputFormat);)"d"===l[0].charAt(0)?c+=s(u.getDate(),l[0].length):"m"===l[0].charAt(0)?c+=s(u.getMonth()+1,l[0].length):"yyyy"===l[0]?c+=u.getFullYear().toString():"y"===l[0].charAt(0)&&(c+=s(u.getYear(),l[0].length));this.inputmask._valueSet(c),e(this).trigger("setvalue")}},onUnMask:function(t,e,n){return o(n.outputFormat,l(t,n.inputFormat,n),n,!0)},casing:function(t,e,n,i){return 0==e.nativeDef.indexOf("[ap]")?t.toLowerCase():0==e.nativeDef.indexOf("[AP]")?t.toUpperCase():t},insertMode:!1,shiftPositions:!1}}),t})?i.apply(e,r):i)||(t.exports=o)},function(t,e,n){"use strict";var i,r,o;"function"==typeof Symbol&&Symbol.iterator;r=[n(2)],void 0===(o="function"==typeof(i=function(t){var e=t.dependencyLib;function n(e,n){for(var i="",r=0;r1&&(t.placeholder=t.placeholder.charAt(0)),"radixFocus"===t.positionCaretOnClick&&""===t.placeholder&&!1===t.integerOptional&&(t.positionCaretOnClick="lvp"),t.definitions[";"]=t.definitions["~"],t.definitions[";"].definitionSymbol="~",!0===t.numericInput&&(t.positionCaretOnClick="radixFocus"===t.positionCaretOnClick?"lvp":t.positionCaretOnClick,t.digitsOptional=!1,isNaN(t.digits)&&(t.digits=2),t.decimalProtect=!1);var r="[+]";if(r+=n(t.prefix,t),!0===t.integerOptional?r+="~{1,"+t.integerDigits+"}":r+="~{"+t.integerDigits+"}",void 0!==t.digits){var o=t.decimalProtect?":":t.radixPoint,a=t.digits.toString().split(",");isFinite(a[0])&&a[1]&&isFinite(a[1])?r+=o+";{"+t.digits+"}":(isNaN(t.digits)||parseInt(t.digits)>0)&&(t.digitsOptional?r+="["+o+";{1,"+t.digits+"}]":r+=o+";{"+t.digits+"}")}return r+=n(t.suffix,t),r+="[-]",t.greedy=!1,r},placeholder:"",greedy:!1,digits:"*",digitsOptional:!0,enforceDigitsOnBlur:!1,radixPoint:".",positionCaretOnClick:"radixFocus",groupSize:3,groupSeparator:"",autoGroup:!1,allowMinus:!0,negationSymbol:{front:"-",back:""},integerDigits:"+",integerOptional:!0,prefix:"",suffix:"",rightAlign:!0,decimalProtect:!0,min:null,max:null,step:1,insertMode:!0,autoUnmask:!1,unmaskAsNumber:!1,inputType:"text",inputmode:"numeric",preValidation:function(t,n,i,r,o,a){if("-"===i||i===o.negationSymbol.front)return!0===o.allowMinus&&(o.isNegative=void 0===o.isNegative||!o.isNegative,""===t.join("")||{caret:a.validPositions[n]?n:void 0,dopost:!0});if(!1===r&&i===o.radixPoint&&void 0!==o.digits&&(isNaN(o.digits)||parseInt(o.digits)>0)){var s=e.inArray(o.radixPoint,t);if(-1!==s&&void 0!==a.validPositions[s])return!0===o.numericInput?n===s:{caret:s+1}}return!0},postValidation:function(n,i,r,o){var a=o.suffix.split(""),s=o.prefix.split("");if(void 0===r.pos&&void 0!==r.caret&&!0!==r.dopost)return r;var l=void 0!==r.caret?r.caret:r.pos,u=n.slice();o.numericInput&&(l=u.length-l-1,u=u.reverse());var c=u[l];if(c===o.groupSeparator&&(c=u[l+=1]),l===u.length-o.suffix.length-1&&c===o.radixPoint)return r;void 0!==c&&c!==o.radixPoint&&c!==o.negationSymbol.front&&c!==o.negationSymbol.back&&(u[l]="?",o.prefix.length>0&&l>=(!1===o.isNegative?1:0)&&l0&&l>=u.length-o.suffix.length-(!1===o.isNegative?1:0)&&(a[l-(u.length-o.suffix.length-(!1===o.isNegative?1:0))]="?")),s=s.join(""),a=a.join("");var d=u.join("").replace(s,"");if(d=(d=(d=(d=d.replace(a,"")).replace(new RegExp(t.escapeRegex(o.groupSeparator),"g"),"")).replace(new RegExp("[-"+t.escapeRegex(o.negationSymbol.front)+"]","g"),"")).replace(new RegExp(t.escapeRegex(o.negationSymbol.back)+"$"),""),isNaN(o.placeholder)&&(d=d.replace(new RegExp(t.escapeRegex(o.placeholder),"g"),"")),d.length>1&&1!==d.indexOf(o.radixPoint)&&("0"===c&&(d=d.replace(/^\?/g,"")),d=d.replace(/^0/g,"")),d.charAt(0)===o.radixPoint&&""!==o.radixPoint&&!0!==o.numericInput&&(d="0"+d),""!==d){if(d=d.split(""),(!o.digitsOptional||o.enforceDigitsOnBlur&&"blur"===r.event)&&isFinite(o.digits)){var f=e.inArray(o.radixPoint,d),h=e.inArray(o.radixPoint,u);-1===f&&(d.push(o.radixPoint),f=d.length-1);for(var p=1;p<=o.digits;p++)o.digitsOptional&&(!o.enforceDigitsOnBlur||"blur"!==r.event)||void 0!==d[f+p]&&d[f+p]!==o.placeholder.charAt(0)?-1!==h&&void 0!==u[h+p]&&(d[f+p]=d[f+p]||u[h+p]):d[f+p]=r.placeholder||o.placeholder.charAt(0)}if(!0!==o.autoGroup||""===o.groupSeparator||c===o.radixPoint&&void 0===r.pos&&!r.dopost)d=d.join("");else{var v=d[d.length-1]===o.radixPoint&&r.c===o.radixPoint;d=t(function(t,e){var n="";if(n+="("+e.groupSeparator+"*{"+e.groupSize+"}){*}",""!==e.radixPoint){var i=t.join("").split(e.radixPoint);i[1]&&(n+=e.radixPoint+"*{"+i[1].match(/^\d*\??\d*/)[0].length+"}")}return n}(d,o),{numericInput:!0,jitMasking:!0,definitions:{"*":{validator:"[0-9?]",cardinality:1}}}).format(d.join("")),v&&(d+=o.radixPoint),d.charAt(0)===o.groupSeparator&&d.substr(1)}}if(o.isNegative&&"blur"===r.event&&(o.isNegative="0"!==d),d=s+d,d+=a,o.isNegative&&(d=o.negationSymbol.front+d,d+=o.negationSymbol.back),d=d.split(""),void 0!==c)if(c!==o.radixPoint&&c!==o.negationSymbol.front&&c!==o.negationSymbol.back)(l=e.inArray("?",d))>-1?d[l]=c:l=r.caret||0;else if(c===o.radixPoint||c===o.negationSymbol.front||c===o.negationSymbol.back){var m=e.inArray(c,d);-1!==m&&(l=m)}o.numericInput&&(l=d.length-l-1,d=d.reverse());var g={caret:void 0!==c&&void 0===r.pos||void 0===l?l:l+(o.numericInput?-1:1),buffer:d,refreshFromBuffer:r.dopost||n.join("")!==d.join("")};return g.refreshFromBuffer?g:r},onBeforeWrite:function(n,i,r,o){if(n)switch(n.type){case"keydown":return o.postValidation(i,r,{caret:r,dopost:!0},o);case"blur":case"checkval":var a;if(function(e){void 0===e.parseMinMaxOptions&&(null!==e.min&&(e.min=e.min.toString().replace(new RegExp(t.escapeRegex(e.groupSeparator),"g"),""),","===e.radixPoint&&(e.min=e.min.replace(e.radixPoint,".")),e.min=isFinite(e.min)?parseFloat(e.min):NaN,isNaN(e.min)&&(e.min=Number.MIN_VALUE)),null!==e.max&&(e.max=e.max.toString().replace(new RegExp(t.escapeRegex(e.groupSeparator),"g"),""),","===e.radixPoint&&(e.max=e.max.replace(e.radixPoint,".")),e.max=isFinite(e.max)?parseFloat(e.max):NaN,isNaN(e.max)&&(e.max=Number.MAX_VALUE)),e.parseMinMaxOptions="done")}(o),null!==o.min||null!==o.max){if(a=o.onUnMask(i.join(""),void 0,e.extend({},o,{unmaskAsNumber:!0})),null!==o.min&&ao.max)return o.isNegative=o.max<0,o.postValidation(o.max.toString().replace(".",o.radixPoint).split(""),r,{caret:r,dopost:!0,placeholder:"0"},o)}return o.postValidation(i,r,{caret:r,placeholder:"0",event:"blur"},o);case"_checkval":return{caret:r}}},regex:{integerPart:function(e,n){return n?new RegExp("["+t.escapeRegex(e.negationSymbol.front)+"+]?"):new RegExp("["+t.escapeRegex(e.negationSymbol.front)+"+]?\\d+")},integerNPart:function(e){return new RegExp("[\\d"+t.escapeRegex(e.groupSeparator)+t.escapeRegex(e.placeholder.charAt(0))+"]+")}},definitions:{"~":{validator:function(e,n,i,r,o,a){var s;if("k"===e||"m"===e){s={insert:[],c:0};for(var l=0,u="k"===e?2:5;l1&&(d[1]=d[1].replace(/0/g,o.placeholder.charAt(0))),"0"===d[0]&&(d[0]=d[0].replace(/0/g,o.placeholder.charAt(0))),c=d[0]+o.radixPoint+d[1]||"";var f=n._buffer.join("");for(c===o.radixPoint&&(c=f);null===c.match(t.escapeRegex(f)+"$");)f=f.slice(1);s=void 0===(c=(c=c.replace(f,"")).split(""))[i]?{pos:i,remove:i}:{pos:i}}}else r||e!==o.radixPoint||void 0!==n.validPositions[i-1]||(s={insert:{pos:i,c:0},pos:i+1});return s},cardinality:1},"+":{validator:function(t,e,n,i,r){return r.allowMinus&&("-"===t||t===r.negationSymbol.front)},cardinality:1,placeholder:""},"-":{validator:function(t,e,n,i,r){return r.allowMinus&&t===r.negationSymbol.back},cardinality:1,placeholder:""},":":{validator:function(e,n,i,r,o){var a="["+t.escapeRegex(o.radixPoint)+"]",s=new RegExp(a).test(e);return s&&n.validPositions[i]&&n.validPositions[i].match.placeholder===o.radixPoint&&(s={caret:i+1}),s},cardinality:1,placeholder:function(t){return t.radixPoint}}},onUnMask:function(e,n,i){if(""===n&&!0===i.nullable)return n;var r=e.replace(i.prefix,"");return r=(r=r.replace(i.suffix,"")).replace(new RegExp(t.escapeRegex(i.groupSeparator),"g"),""),""!==i.placeholder.charAt(0)&&(r=r.replace(new RegExp(i.placeholder.charAt(0),"g"),"0")),i.unmaskAsNumber?(""!==i.radixPoint&&-1!==r.indexOf(i.radixPoint)&&(r=r.replace(t.escapeRegex.call(this,i.radixPoint),".")),r=(r=r.replace(new RegExp("^"+t.escapeRegex(i.negationSymbol.front)),"-")).replace(new RegExp(t.escapeRegex(i.negationSymbol.back)+"$"),""),Number(r)):r},isComplete:function(e,n){var i=(n.numericInput?e.slice().reverse():e).join("");return i=(i=(i=(i=(i=i.replace(new RegExp("^"+t.escapeRegex(n.negationSymbol.front)),"-")).replace(new RegExp(t.escapeRegex(n.negationSymbol.back)+"$"),"")).replace(n.prefix,"")).replace(n.suffix,"")).replace(new RegExp(t.escapeRegex(n.groupSeparator)+"([0-9]{3})","g"),"$1"),","===n.radixPoint&&(i=i.replace(t.escapeRegex(n.radixPoint),".")),isFinite(i)},onBeforeMask:function(n,i){i.isNegative=void 0;var r=i.radixPoint||",";"number"!=typeof n&&"number"!==i.inputType||""===r||(n=n.toString().replace(".",r));var o=n.split(r),a=o[0].replace(/[^\-0-9]/g,""),s=o.length>1?o[1].replace(/[^0-9]/g,""):"";n=a+(""!==s?r+s:s);var l=0;if(""!==r&&(l=s.length,""!==s)){var u=Math.pow(10,l||1);isFinite(i.digits)&&(l=parseInt(i.digits),u=Math.pow(10,l)),n=n.replace(t.escapeRegex(r),"."),isFinite(n)&&(n=Math.round(parseFloat(n)*u)/u),n=n.toString().replace(".",r)}return 0===i.digits&&-1!==n.indexOf(t.escapeRegex(r))&&(n=n.substring(0,n.indexOf(t.escapeRegex(r)))),function(t,n,i){if(n>0){var r=e.inArray(i.radixPoint,t);-1===r&&(t.push(i.radixPoint),r=t.length-1);for(var o=1;o<=n;o++)t[r+o]=t[r+o]||"0"}return t}(n.toString().split(""),l,i).join("")},onKeyDown:function(n,i,r,o){var a=e(this);if(n.ctrlKey)switch(n.keyCode){case t.keyCode.UP:a.val(parseFloat(this.inputmask.unmaskedvalue())+parseInt(o.step)),a.trigger("setvalue");break;case t.keyCode.DOWN:a.val(parseFloat(this.inputmask.unmaskedvalue())-parseInt(o.step)),a.trigger("setvalue")}}},currency:{prefix:"$ ",groupSeparator:",",alias:"numeric",placeholder:"0",autoGroup:!0,digits:2,digitsOptional:!1,clearMaskOnLostFocus:!1},decimal:{alias:"numeric"},integer:{alias:"numeric",digits:0,radixPoint:""},percentage:{alias:"numeric",digits:2,digitsOptional:!0,radixPoint:".",placeholder:"0",autoGroup:!1,min:0,max:100,suffix:" %",allowMinus:!1}}),t})?i.apply(e,r):i)||(t.exports=o)},function(t,e,n){"use strict";var i,r,o,a="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t};r=[n(4),n(2)],void 0===(o="function"==typeof(i=function(t,e){return void 0===t.fn.inputmask&&(t.fn.inputmask=function(n,i){var r,o=this[0];if(void 0===i&&(i={}),"string"==typeof n)switch(n){case"unmaskedvalue":return o&&o.inputmask?o.inputmask.unmaskedvalue():t(o).val();case"remove":return this.each(function(){this.inputmask&&this.inputmask.remove()});case"getemptymask":return o&&o.inputmask?o.inputmask.getemptymask():"";case"hasMaskedValue":return!(!o||!o.inputmask)&&o.inputmask.hasMaskedValue();case"isComplete":return!o||!o.inputmask||o.inputmask.isComplete();case"getmetadata":return o&&o.inputmask?o.inputmask.getmetadata():void 0;case"setvalue":e.setValue(o,i);break;case"option":if("string"!=typeof i)return this.each(function(){if(void 0!==this.inputmask)return this.inputmask.option(i)});if(o&&void 0!==o.inputmask)return o.inputmask.option(i);break;default:return i.alias=n,r=new e(i),this.each(function(){r.mask(this)})}else{if(Array.isArray(n))return i.alias=n,r=new e(i),this.each(function(){r.mask(this)});if("object"==(void 0===n?"undefined":a(n)))return r=new e(n),void 0===n.mask&&void 0===n.alias?this.each(function(){if(void 0!==this.inputmask)return this.inputmask.option(n);r.mask(this)}):this.each(function(){r.mask(this)});if(void 0===n)return this.each(function(){(r=new e(i)).mask(this)})}}),t.fn.inputmask})?i.apply(e,r):i)||(t.exports=o)}]),function(t){"function"==typeof define&&define.amd?define(["./inputmask"],t):"object"==typeof exports?module.exports=t(require("./inputmask")):t(window.Inputmask)}(function(t){var e=t.dependencyLib,n={d:["[1-9]|[12][0-9]|3[01]",Date.prototype.setDate,"day",Date.prototype.getDate],dd:["0[1-9]|[12][0-9]|3[01]",Date.prototype.setDate,"day",function(){return a(Date.prototype.getDate.call(this),2)}],ddd:[""],dddd:[""],m:["[1-9]|1[012]",Date.prototype.setMonth,"month",function(){return Date.prototype.getMonth.call(this)+1}],mm:["0[1-9]|1[012]",Date.prototype.setMonth,"month",function(){return a(Date.prototype.getMonth.call(this)+1,2)}],mmm:[""],mmmm:[""],yy:["[0-9]{2}",Date.prototype.setFullYear,"year",function(){return a(Date.prototype.getFullYear.call(this),2)}],yyyy:["[0-9]{4}",Date.prototype.setFullYear,"year",function(){return a(Date.prototype.getFullYear.call(this),4)}],h:["[1-9]|1[0-2]",Date.prototype.setHours,"hours",Date.prototype.getHours],hh:["0[1-9]|1[0-2]",Date.prototype.setHours,"hours",function(){return a(Date.prototype.getHours.call(this),2)}],hhh:["[0-9]+",Date.prototype.setHours,"hours",Date.prototype.getHours],H:["1?[0-9]|2[0-3]",Date.prototype.setHours,"hours",Date.prototype.getHours],HH:["0[0-9]|1[0-9]|2[0-3]",Date.prototype.setHours,"hours",function(){return a(Date.prototype.getHours.call(this),2)}],HHH:["[0-9]+",Date.prototype.setHours,"hours",Date.prototype.getHours],M:["[1-5]?[0-9]",Date.prototype.setMinutes,"minutes",Date.prototype.getMinutes],MM:["0[0-9]|1[0-9]|2[0-9]|3[0-9]|4[0-9]|5[0-9]",Date.prototype.setMinutes,"minutes",function(){return a(Date.prototype.getMinutes.call(this),2)}],ss:["[0-5][0-9]",Date.prototype.setSeconds,"seconds",function(){return a(Date.prototype.getSeconds.call(this),2)}],l:["[0-9]{3}",Date.prototype.setMilliseconds,"milliseconds",function(){return a(Date.prototype.getMilliseconds.call(this),3)}],L:["[0-9]{2}",Date.prototype.setMilliseconds,"milliseconds",function(){return a(Date.prototype.getMilliseconds.call(this),2)}],t:["[ap]"],tt:["[ap]m"],T:["[AP]"],TT:["[AP]M"],Z:[""],o:[""],S:[""]},i={isoDate:"yyyy-mm-dd",isoTime:"HH:MM:ss",isoDateTime:"yyyy-mm-dd'T'HH:MM:ss",isoUtcDateTime:"UTC:yyyy-mm-dd'T'HH:MM:ss'Z'"};function r(t){if(!t.tokenizer){var e=[];for(var i in n)-1===e.indexOf(i[0])&&e.push(i[0]);t.tokenizer="("+e.join("+|")+")+?|.",t.tokenizer=new RegExp(t.tokenizer,"g")}return t.tokenizer}function o(e,i,o,a){for(var s,l="";s=r(o).exec(e);){if(void 0===i)if(n[s[0]])l+="("+n[s[0]][0]+")";else switch(s[0]){case"[":l+="(";break;case"]":l+=")?";break;default:l+=t.escapeRegex(s[0])}else if(n[s[0]])if(!0!==a&&n[s[0]][3])l+=n[s[0]][3].call(i.date);else n[s[0]][2]?l+=i["raw"+n[s[0]][2]]:l+=s[0];else l+=s[0]}return l}function a(t,e){for(t=String(t),e=e||2;t.lengtha.slice(0,n.length)?a.slice(n.length):e.toString().slice(n.length))}return e}function d(t,e,n){t[o]=c(e),t["raw"+o]=e,void 0!==s&&s.call(t.date,"month"==o?parseInt(t[o])-1:t[o])}if("string"==typeof u){for(;a=r(i).exec(e);){var f=u.slice(0,a[0].length);n.hasOwnProperty(a[0])&&(n[a[0]][0],o=n[a[0]][2],s=n[a[0]][1],d(l,f)),u=u.slice(f.length)}return l}if(u&&"object"==typeof u&&u.hasOwnProperty("date"))return u}return t.extendAliases({datetime:{mask:function(t){return n.S=t.i18n.ordinalSuffix.join("|"),t.inputFormat=i[t.inputFormat]||t.inputFormat,t.displayFormat=i[t.displayFormat]||t.displayFormat||t.inputFormat,t.outputFormat=i[t.outputFormat]||t.outputFormat||t.inputFormat,t.placeholder=""!==t.placeholder?t.placeholder:t.inputFormat.replace(/[\[\]]/,""),t.regex=o(t.inputFormat,void 0,t),null},placeholder:"",inputFormat:"isoDateTime",displayFormat:void 0,outputFormat:void 0,min:null,max:null,i18n:{dayNames:["Mon","Tue","Wed","Thu","Fri","Sat","Sun","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","Sunday"],monthNames:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec","January","February","March","April","May","June","July","August","September","October","November","December"],ordinalSuffix:["st","nd","rd","th"]},postValidation:function(t,e,n,i){i.min=s(i.min,i.inputFormat,i),i.max=s(i.max,i.inputFormat,i);var r=n,a=s(t.join(""),i.inputFormat,i);return r&&a.date.getTime()==a.date.getTime()&&(r=(r=function(t,e){return(!isFinite(t.rawday)||"29"==t.day&&!isFinite(t.rawyear)||new Date(t.date.getFullYear(),isFinite(t.rawmonth)?t.month:t.date.getMonth()+1,0).getDate()>=t.day)&&e}(a,r))&&function(t,e){var n=!0;if(e.min){if(t.rawyear){var i=t.rawyear.replace(/[^0-9]/g,"");n=e.min.year.substr(0,i.length)<=i}t.year===t.rawyear&&e.min.date.getTime()==e.min.date.getTime()&&(n=e.min.date.getTime()<=t.date.getTime())}return n&&e.max&&e.max.date.getTime()==e.max.date.getTime()&&(n=e.max.date.getTime()>=t.date.getTime()),n}(a,i)),e&&r&&n.pos!==e?{buffer:o(i.inputFormat,a,i),refreshFromBuffer:{start:e,end:n.pos}}:r},onKeyDown:function(n,i,o,s){if(n.ctrlKey&&n.keyCode===t.keyCode.RIGHT){for(var l,u=new Date,c="";l=r(s).exec(s.inputFormat);)"d"===l[0].charAt(0)?c+=a(u.getDate(),l[0].length):"m"===l[0].charAt(0)?c+=a(u.getMonth()+1,l[0].length):"yyyy"===l[0]?c+=u.getFullYear().toString():"y"===l[0].charAt(0)&&(c+=a(u.getYear(),l[0].length));this.inputmask._valueSet(c),e(this).trigger("setvalue")}},onUnMask:function(t,e,n){return o(n.outputFormat,s(t,n.inputFormat,n),n,!0)},casing:function(t,e,n,i){return 0==e.nativeDef.indexOf("[ap]")?t.toLowerCase():0==e.nativeDef.indexOf("[AP]")?t.toUpperCase():t},insertMode:!1,shiftPositions:!1}}),t}),function(t){"function"==typeof define&&define.amd?define(["./inputmask"],t):"object"==typeof exports?module.exports=t(require("./inputmask")):t(window.Inputmask)}(function(t){var e=t.dependencyLib;function n(e,n){for(var i="",r=0;r1&&(t.placeholder=t.placeholder.charAt(0)),"radixFocus"===t.positionCaretOnClick&&""===t.placeholder&&!1===t.integerOptional&&(t.positionCaretOnClick="lvp"),t.definitions[";"]=t.definitions["~"],t.definitions[";"].definitionSymbol="~",!0===t.numericInput&&(t.positionCaretOnClick="radixFocus"===t.positionCaretOnClick?"lvp":t.positionCaretOnClick,t.digitsOptional=!1,isNaN(t.digits)&&(t.digits=2),t.decimalProtect=!1);var r="[+]";if(r+=n(t.prefix,t),!0===t.integerOptional?r+="~{1,"+t.integerDigits+"}":r+="~{"+t.integerDigits+"}",void 0!==t.digits){var o=t.decimalProtect?":":t.radixPoint,a=t.digits.toString().split(",");isFinite(a[0])&&a[1]&&isFinite(a[1])?r+=o+";{"+t.digits+"}":(isNaN(t.digits)||parseInt(t.digits)>0)&&(t.digitsOptional?r+="["+o+";{1,"+t.digits+"}]":r+=o+";{"+t.digits+"}")}return r+=n(t.suffix,t),r+="[-]",t.greedy=!1,r},placeholder:"",greedy:!1,digits:"*",digitsOptional:!0,enforceDigitsOnBlur:!1,radixPoint:".",positionCaretOnClick:"radixFocus",groupSize:3,groupSeparator:"",autoGroup:!1,allowMinus:!0,negationSymbol:{front:"-",back:""},integerDigits:"+",integerOptional:!0,prefix:"",suffix:"",rightAlign:!0,decimalProtect:!0,min:null,max:null,step:1,insertMode:!0,autoUnmask:!1,unmaskAsNumber:!1,inputType:"text",inputmode:"numeric",preValidation:function(t,n,i,r,o,a){if("-"===i||i===o.negationSymbol.front)return!0===o.allowMinus&&(o.isNegative=void 0===o.isNegative||!o.isNegative,""===t.join("")||{caret:a.validPositions[n]?n:void 0,dopost:!0});if(!1===r&&i===o.radixPoint&&void 0!==o.digits&&(isNaN(o.digits)||parseInt(o.digits)>0)){var s=e.inArray(o.radixPoint,t);if(-1!==s&&void 0!==a.validPositions[s])return!0===o.numericInput?n===s:{caret:s+1}}return!0},postValidation:function(n,i,r,o){var a=o.suffix.split(""),s=o.prefix.split("");if(void 0===r.pos&&void 0!==r.caret&&!0!==r.dopost)return r;var l=void 0!==r.caret?r.caret:r.pos,u=n.slice();o.numericInput&&(l=u.length-l-1,u=u.reverse());var c=u[l];if(c===o.groupSeparator&&(c=u[l+=1]),l===u.length-o.suffix.length-1&&c===o.radixPoint)return r;void 0!==c&&c!==o.radixPoint&&c!==o.negationSymbol.front&&c!==o.negationSymbol.back&&(u[l]="?",o.prefix.length>0&&l>=(!1===o.isNegative?1:0)&&l0&&l>=u.length-o.suffix.length-(!1===o.isNegative?1:0)&&(a[l-(u.length-o.suffix.length-(!1===o.isNegative?1:0))]="?")),s=s.join(""),a=a.join("");var d=u.join("").replace(s,"");if(d=(d=(d=(d=d.replace(a,"")).replace(new RegExp(t.escapeRegex(o.groupSeparator),"g"),"")).replace(new RegExp("[-"+t.escapeRegex(o.negationSymbol.front)+"]","g"),"")).replace(new RegExp(t.escapeRegex(o.negationSymbol.back)+"$"),""),isNaN(o.placeholder)&&(d=d.replace(new RegExp(t.escapeRegex(o.placeholder),"g"),"")),d.length>1&&1!==d.indexOf(o.radixPoint)&&("0"===c&&(d=d.replace(/^\?/g,"")),d=d.replace(/^0/g,"")),d.charAt(0)===o.radixPoint&&""!==o.radixPoint&&!0!==o.numericInput&&(d="0"+d),""!==d){if(d=d.split(""),(!o.digitsOptional||o.enforceDigitsOnBlur&&"blur"===r.event)&&isFinite(o.digits)){var f=e.inArray(o.radixPoint,d),h=e.inArray(o.radixPoint,u);-1===f&&(d.push(o.radixPoint),f=d.length-1);for(var p=1;p<=o.digits;p++)o.digitsOptional&&(!o.enforceDigitsOnBlur||"blur"!==r.event)||void 0!==d[f+p]&&d[f+p]!==o.placeholder.charAt(0)?-1!==h&&void 0!==u[h+p]&&(d[f+p]=d[f+p]||u[h+p]):d[f+p]=r.placeholder||o.placeholder.charAt(0)}if(!0!==o.autoGroup||""===o.groupSeparator||c===o.radixPoint&&void 0===r.pos&&!r.dopost)d=d.join("");else{var v=d[d.length-1]===o.radixPoint&&r.c===o.radixPoint;d=t(function(t,e){var n="";if(n+="("+e.groupSeparator+"*{"+e.groupSize+"}){*}",""!==e.radixPoint){var i=t.join("").split(e.radixPoint);i[1]&&(n+=e.radixPoint+"*{"+i[1].match(/^\d*\??\d*/)[0].length+"}")}return n}(d,o),{numericInput:!0,jitMasking:!0,definitions:{"*":{validator:"[0-9?]",cardinality:1}}}).format(d.join("")),v&&(d+=o.radixPoint),d.charAt(0)===o.groupSeparator&&d.substr(1)}}if(o.isNegative&&"blur"===r.event&&(o.isNegative="0"!==d),d=s+d,d+=a,o.isNegative&&(d=o.negationSymbol.front+d,d+=o.negationSymbol.back),d=d.split(""),void 0!==c)if(c!==o.radixPoint&&c!==o.negationSymbol.front&&c!==o.negationSymbol.back)(l=e.inArray("?",d))>-1?d[l]=c:l=r.caret||0;else if(c===o.radixPoint||c===o.negationSymbol.front||c===o.negationSymbol.back){var m=e.inArray(c,d);-1!==m&&(l=m)}o.numericInput&&(l=d.length-l-1,d=d.reverse());var g={caret:void 0!==c&&void 0===r.pos||void 0===l?l:l+(o.numericInput?-1:1),buffer:d,refreshFromBuffer:r.dopost||n.join("")!==d.join("")};return g.refreshFromBuffer?g:r},onBeforeWrite:function(n,i,r,o){if(n)switch(n.type){case"keydown":return o.postValidation(i,r,{caret:r,dopost:!0},o);case"blur":case"checkval":var a;if(function(e){void 0===e.parseMinMaxOptions&&(null!==e.min&&(e.min=e.min.toString().replace(new RegExp(t.escapeRegex(e.groupSeparator),"g"),""),","===e.radixPoint&&(e.min=e.min.replace(e.radixPoint,".")),e.min=isFinite(e.min)?parseFloat(e.min):NaN,isNaN(e.min)&&(e.min=Number.MIN_VALUE)),null!==e.max&&(e.max=e.max.toString().replace(new RegExp(t.escapeRegex(e.groupSeparator),"g"),""),","===e.radixPoint&&(e.max=e.max.replace(e.radixPoint,".")),e.max=isFinite(e.max)?parseFloat(e.max):NaN,isNaN(e.max)&&(e.max=Number.MAX_VALUE)),e.parseMinMaxOptions="done")}(o),null!==o.min||null!==o.max){if(a=o.onUnMask(i.join(""),void 0,e.extend({},o,{unmaskAsNumber:!0})),null!==o.min&&ao.max)return o.isNegative=o.max<0,o.postValidation(o.max.toString().replace(".",o.radixPoint).split(""),r,{caret:r,dopost:!0,placeholder:"0"},o)}return o.postValidation(i,r,{caret:r,placeholder:"0",event:"blur"},o);case"_checkval":return{caret:r}}},regex:{integerPart:function(e,n){return n?new RegExp("["+t.escapeRegex(e.negationSymbol.front)+"+]?"):new RegExp("["+t.escapeRegex(e.negationSymbol.front)+"+]?\\d+")},integerNPart:function(e){return new RegExp("[\\d"+t.escapeRegex(e.groupSeparator)+t.escapeRegex(e.placeholder.charAt(0))+"]+")}},definitions:{"~":{validator:function(e,n,i,r,o,a){var s;if("k"===e||"m"===e){s={insert:[],c:0};for(var l=0,u="k"===e?2:5;l1&&(d[1]=d[1].replace(/0/g,o.placeholder.charAt(0))),"0"===d[0]&&(d[0]=d[0].replace(/0/g,o.placeholder.charAt(0))),c=d[0]+o.radixPoint+d[1]||"";var f=n._buffer.join("");for(c===o.radixPoint&&(c=f);null===c.match(t.escapeRegex(f)+"$");)f=f.slice(1);s=void 0===(c=(c=c.replace(f,"")).split(""))[i]?{pos:i,remove:i}:{pos:i}}}else r||e!==o.radixPoint||void 0!==n.validPositions[i-1]||(s={insert:{pos:i,c:0},pos:i+1});return s},cardinality:1},"+":{validator:function(t,e,n,i,r){return r.allowMinus&&("-"===t||t===r.negationSymbol.front)},cardinality:1,placeholder:""},"-":{validator:function(t,e,n,i,r){return r.allowMinus&&t===r.negationSymbol.back},cardinality:1,placeholder:""},":":{validator:function(e,n,i,r,o){var a="["+t.escapeRegex(o.radixPoint)+"]",s=new RegExp(a).test(e);return s&&n.validPositions[i]&&n.validPositions[i].match.placeholder===o.radixPoint&&(s={caret:i+1}),s},cardinality:1,placeholder:function(t){return t.radixPoint}}},onUnMask:function(e,n,i){if(""===n&&!0===i.nullable)return n;var r=e.replace(i.prefix,"");return r=(r=r.replace(i.suffix,"")).replace(new RegExp(t.escapeRegex(i.groupSeparator),"g"),""),""!==i.placeholder.charAt(0)&&(r=r.replace(new RegExp(i.placeholder.charAt(0),"g"),"0")),i.unmaskAsNumber?(""!==i.radixPoint&&-1!==r.indexOf(i.radixPoint)&&(r=r.replace(t.escapeRegex.call(this,i.radixPoint),".")),r=(r=r.replace(new RegExp("^"+t.escapeRegex(i.negationSymbol.front)),"-")).replace(new RegExp(t.escapeRegex(i.negationSymbol.back)+"$"),""),Number(r)):r},isComplete:function(e,n){var i=(n.numericInput?e.slice().reverse():e).join("");return i=(i=(i=(i=(i=i.replace(new RegExp("^"+t.escapeRegex(n.negationSymbol.front)),"-")).replace(new RegExp(t.escapeRegex(n.negationSymbol.back)+"$"),"")).replace(n.prefix,"")).replace(n.suffix,"")).replace(new RegExp(t.escapeRegex(n.groupSeparator)+"([0-9]{3})","g"),"$1"),","===n.radixPoint&&(i=i.replace(t.escapeRegex(n.radixPoint),".")),isFinite(i)},onBeforeMask:function(n,i){i.isNegative=void 0;var r=i.radixPoint||",";"number"!=typeof n&&"number"!==i.inputType||""===r||(n=n.toString().replace(".",r));var o=n.split(r),a=o[0].replace(/[^\-0-9]/g,""),s=o.length>1?o[1].replace(/[^0-9]/g,""):"";n=a+(""!==s?r+s:s);var l=0;if(""!==r&&(l=s.length,""!==s)){var u=Math.pow(10,l||1);isFinite(i.digits)&&(l=parseInt(i.digits),u=Math.pow(10,l)),n=n.replace(t.escapeRegex(r),"."),isFinite(n)&&(n=Math.round(parseFloat(n)*u)/u),n=n.toString().replace(".",r)}return 0===i.digits&&-1!==n.indexOf(t.escapeRegex(r))&&(n=n.substring(0,n.indexOf(t.escapeRegex(r)))),function(t,n,i){if(n>0){var r=e.inArray(i.radixPoint,t);-1===r&&(t.push(i.radixPoint),r=t.length-1);for(var o=1;o<=n;o++)t[r+o]=t[r+o]||"0"}return t}(n.toString().split(""),l,i).join("")},onKeyDown:function(n,i,r,o){var a=e(this);if(n.ctrlKey)switch(n.keyCode){case t.keyCode.UP:a.val(parseFloat(this.inputmask.unmaskedvalue())+parseInt(o.step)),a.trigger("setvalue");break;case t.keyCode.DOWN:a.val(parseFloat(this.inputmask.unmaskedvalue())-parseInt(o.step)),a.trigger("setvalue")}}},currency:{prefix:"$ ",groupSeparator:",",alias:"numeric",placeholder:"0",autoGroup:!0,digits:2,digitsOptional:!1,clearMaskOnLostFocus:!1},decimal:{alias:"numeric"},integer:{alias:"numeric",digits:0,radixPoint:""},percentage:{alias:"numeric",digits:2,digitsOptional:!0,radixPoint:".",placeholder:"0",autoGroup:!1,min:0,max:100,suffix:" %",allowMinus:!1}}),t}),function(t){"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?module.exports=t():window.noUiSlider=t()}(function(){"use strict";var t="14.6.2";function e(t){t.parentElement.removeChild(t)}function n(t){return null!=t}function i(t){t.preventDefault()}function r(t){return"number"==typeof t&&!isNaN(t)&&isFinite(t)}function o(t,e,n){n>0&&(u(t,e),setTimeout(function(){c(t,e)},n))}function a(t){return Math.max(Math.min(t,100),0)}function s(t){return Array.isArray(t)?t:[t]}function l(t){var e=(t=String(t)).split(".");return e.length>1?e[1].length:0}function u(t,e){t.classList&&!/\s/.test(e)?t.classList.add(e):t.className+=" "+e}function c(t,e){t.classList&&!/\s/.test(e)?t.classList.remove(e):t.className=t.className.replace(new RegExp("(^|\\b)"+e.split(" ").join("|")+"(\\b|$)","gi")," ")}function d(t){var e=void 0!==window.pageXOffset,n="CSS1Compat"===(t.compatMode||"");return{x:e?window.pageXOffset:n?t.documentElement.scrollLeft:t.body.scrollLeft,y:e?window.pageYOffset:n?t.documentElement.scrollTop:t.body.scrollTop}}function f(t,e){return 100/(e-t)}function h(t,e,n){return 100*e/(t[n+1]-t[n])}function p(t,e){for(var n=1;t>=e[n];)n+=1;return n}function v(t,e,n){if(n>=t.slice(-1)[0])return 100;var i=p(n,t),r=t[i-1],o=t[i],a=e[i-1],s=e[i];return a+function(t,e){return h(t,t[0]<0?e+Math.abs(t[0]):e-t[0],0)}([r,o],n)/f(a,s)}function m(t,e,n,i){if(100===i)return i;var r=p(i,t),o=t[r-1],a=t[r];return n?i-o>(a-o)/2?a:o:e[r-1]?t[r-1]+function(t,e){return Math.round(t/e)*e}(i-t[r-1],e[r-1]):i}function g(e,n,i){var o;if("number"==typeof n&&(n=[n]),!Array.isArray(n))throw new Error("noUiSlider ("+t+"): 'range' contains invalid value.");if(!r(o="min"===e?0:"max"===e?100:parseFloat(e))||!r(n[0]))throw new Error("noUiSlider ("+t+"): 'range' value isn't numeric.");i.xPct.push(o),i.xVal.push(n[0]),o?i.xSteps.push(!isNaN(n[1])&&n[1]):isNaN(n[1])||(i.xSteps[0]=n[1]),i.xHighestCompleteStep.push(0)}function y(t,e,n){if(e)if(n.xVal[t]!==n.xVal[t+1]){n.xSteps[t]=h([n.xVal[t],n.xVal[t+1]],e,0)/f(n.xPct[t],n.xPct[t+1]);var i=(n.xVal[t+1]-n.xVal[t])/n.xNumSteps[t],r=Math.ceil(Number(i.toFixed(3))-1),o=n.xVal[t]+n.xNumSteps[t]*r;n.xHighestCompleteStep[t]=o}else n.xSteps[t]=n.xHighestCompleteStep[t]=n.xVal[t]}function b(t,e,n){var i;this.xPct=[],this.xVal=[],this.xSteps=[n||!1],this.xNumSteps=[!1],this.xHighestCompleteStep=[],this.snap=e;var r=[];for(i in t)t.hasOwnProperty(i)&&r.push([t[i],i]);for(r.length&&"object"==typeof r[0][0]?r.sort(function(t,e){return t[0][0]-e[0][0]}):r.sort(function(t,e){return t[0]-e[0]}),i=0;ithis.xPct[r+1];)r++;else t===this.xPct[this.xPct.length-1]&&(r=this.xPct.length-2);n||t!==this.xPct[r+1]||r++;var o=1,a=e[r],s=0,l=0,u=0,c=0;for(i=n?(t-this.xPct[r])/(this.xPct[r+1]-this.xPct[r]):(this.xPct[r+1]-t)/(this.xPct[r+1]-this.xPct[r]);a>0;)s=this.xPct[r+1+c]-this.xPct[r+c],e[r+c]*o+100-100*i>100?(l=s*i,o=(a-100*i)/e[r+c],i=1):(l=e[r+c]*s/100*o,o=0),n?(u-=l,this.xPct.length+c>=1&&c--):(u+=l,this.xPct.length-c>=1&&c++),a=e[r+c]*o;return t+u},b.prototype.toStepping=function(t){return t=v(this.xVal,this.xPct,t)},b.prototype.fromStepping=function(t){return function(t,e,n){if(n>=100)return t.slice(-1)[0];var i=p(n,e),r=t[i-1],o=t[i],a=e[i-1];return function(t,e){return e*(t[1]-t[0])/100+t[0]}([r,o],(n-a)*f(a,e[i]))}(this.xVal,this.xPct,t)},b.prototype.getStep=function(t){return t=m(this.xPct,this.xSteps,this.snap,t)},b.prototype.getDefaultStep=function(t,e,n){var i=p(t,this.xPct);return(100===t||e&&t===this.xPct[i-1])&&(i=Math.max(i-1,1)),(this.xVal[i]-this.xVal[i-1])/n},b.prototype.getNearbySteps=function(t){var e=p(t,this.xPct);return{stepBefore:{startValue:this.xVal[e-2],step:this.xNumSteps[e-2],highestStep:this.xHighestCompleteStep[e-2]},thisStep:{startValue:this.xVal[e-1],step:this.xNumSteps[e-1],highestStep:this.xHighestCompleteStep[e-1]},stepAfter:{startValue:this.xVal[e],step:this.xNumSteps[e],highestStep:this.xHighestCompleteStep[e]}}},b.prototype.countStepDecimals=function(){var t=this.xNumSteps.map(l);return Math.max.apply(null,t)},b.prototype.convert=function(t){return this.getStep(this.toStepping(t))};var k={to:function(t){return void 0!==t&&t.toFixed(2)},from:Number},w={target:"target",base:"base",origin:"origin",handle:"handle",handleLower:"handle-lower",handleUpper:"handle-upper",touchArea:"touch-area",horizontal:"horizontal",vertical:"vertical",background:"background",connect:"connect",connects:"connects",ltr:"ltr",rtl:"rtl",textDirectionLtr:"txt-dir-ltr",textDirectionRtl:"txt-dir-rtl",draggable:"draggable",drag:"state-drag",tap:"state-tap",active:"active",tooltip:"tooltip",pips:"pips",pipsHorizontal:"pips-horizontal",pipsVertical:"pips-vertical",marker:"marker",markerHorizontal:"marker-horizontal",markerVertical:"marker-vertical",markerNormal:"marker-normal",markerLarge:"marker-large",markerSub:"marker-sub",value:"value",valueHorizontal:"value-horizontal",valueVertical:"value-vertical",valueNormal:"value-normal",valueLarge:"value-large",valueSub:"value-sub"};function x(e){if(function(t){return"object"==typeof t&&"function"==typeof t.to&&"function"==typeof t.from}(e))return!0;throw new Error("noUiSlider ("+t+"): 'format' requires 'to' and 'from' methods.")}function _(e,n){if(!r(n))throw new Error("noUiSlider ("+t+"): 'step' is not numeric.");e.singleStep=n}function E(e,n){if(!r(n))throw new Error("noUiSlider ("+t+"): 'keyboardPageMultiplier' is not numeric.");e.keyboardPageMultiplier=n}function S(e,n){if(!r(n))throw new Error("noUiSlider ("+t+"): 'keyboardDefaultStep' is not numeric.");e.keyboardDefaultStep=n}function O(e,n){if("object"!=typeof n||Array.isArray(n))throw new Error("noUiSlider ("+t+"): 'range' is not an object.");if(void 0===n.min||void 0===n.max)throw new Error("noUiSlider ("+t+"): Missing 'min' or 'max' in 'range'.");if(n.min===n.max)throw new Error("noUiSlider ("+t+"): 'range' 'min' and 'max' cannot be equal.");e.spectrum=new b(n,e.snap,e.singleStep)}function A(e,n){if(n=s(n),!Array.isArray(n)||!n.length)throw new Error("noUiSlider ("+t+"): 'start' option is incorrect.");e.handles=n.length,e.start=n}function C(e,n){if(e.snap=n,"boolean"!=typeof n)throw new Error("noUiSlider ("+t+"): 'snap' option must be a boolean.")}function T(e,n){if(e.animate=n,"boolean"!=typeof n)throw new Error("noUiSlider ("+t+"): 'animate' option must be a boolean.")}function P(e,n){if(e.animationDuration=n,"number"!=typeof n)throw new Error("noUiSlider ("+t+"): 'animationDuration' option must be a number.")}function N(e,n){var i,r=[!1];if("lower"===n?n=[!0,!1]:"upper"===n&&(n=[!1,!0]),!0===n||!1===n){for(i=1;i1)throw new Error("noUiSlider ("+t+"): 'padding' option must not exceed 100% of the range.")}}function j(e,n){switch(n){case"ltr":e.dir=0;break;case"rtl":e.dir=1;break;default:throw new Error("noUiSlider ("+t+"): 'direction' option was not recognized.")}}function R(e,n){if("string"!=typeof n)throw new Error("noUiSlider ("+t+"): 'behaviour' must be a string containing options.");var i=n.indexOf("tap")>=0,r=n.indexOf("drag")>=0,o=n.indexOf("fixed")>=0,a=n.indexOf("snap")>=0,s=n.indexOf("hover")>=0,l=n.indexOf("unconstrained")>=0;if(o){if(2!==e.handles)throw new Error("noUiSlider ("+t+"): 'fixed' behaviour must be used with 2 handles");L(e,e.start[1]-e.start[0])}if(l&&(e.margin||e.limit))throw new Error("noUiSlider ("+t+"): 'unconstrained' behaviour cannot be used with margin or limit");e.events={tap:i||a,drag:r,fixed:o,snap:a,hover:s,unconstrained:l}}function F(e,n){if(!1!==n)if(!0===n){e.tooltips=[];for(var i=0;iL&&((s=R(i,!1)).className=c(a,r.cssClasses.value),s.setAttribute("data-value",o),s.style[r.style]=t+"%",s.innerHTML=n.to(o))}}(o,t[o][0],t[o][1])}),i}function W(){v&&(e(v),v=null)}function G(e){W();var n=e.mode,i=e.density||1,r=e.filter||!1,o=function(e,n,i){if("range"===e||"steps"===e)return _.xVal;if("count"===e){if(n<2)throw new Error("noUiSlider ("+t+"): 'values' (>= 2) required for mode 'count'.");var r=n-1,o=100/r;for(n=[];r--;)n[r]=r*o;n.push(100),e="positions"}return"positions"===e?n.map(function(t){return _.fromStepping(i?_.getStep(t):t)}):"values"===e?i?n.map(function(t){return _.fromStepping(_.getStep(_.toStepping(t)))}):n:void 0}(n,e.values||!1,e.stepped||!1),a=function(t,e,n){var i,r={},o=_.xVal[0],a=_.xVal[_.xVal.length-1],s=!1,l=!1,u=0;return i=n.slice().sort(function(t,e){return t-e}),(n=i.filter(function(t){return!this[t]&&(this[t]=!0)},{}))[0]!==o&&(n.unshift(o),s=!0),n[n.length-1]!==a&&(n.push(a),l=!0),n.forEach(function(i,o){var a,c,d,f,h,p,v,m,g,y,b=i,k=n[o+1],w="steps"===e;if(w&&(a=_.xNumSteps[o]),a||(a=k-b),!1!==b)for(void 0===k&&(k=b),a=Math.max(a,1e-7),c=b;c<=k;c=(c+a).toFixed(7)/1){for(m=(h=(f=_.toStepping(c))-u)/t,y=h/(g=Math.round(m)),d=1;d<=g;d+=1)r[(p=u+d*y).toFixed(5)]=[_.fromStepping(p),0];v=n.indexOf(c)>-1?M:w?D:L,!o&&s&&c!==k&&(v=0),c===k&&l||(r[f.toFixed(5)]=[c,v]),u=f}}),r}(i,n,o),s=e.format||{to:Math.round};return v=x.appendChild(K(a,r,s))}function Y(){var t=f.getBoundingClientRect(),e="offset"+["Width","Height"][r.ort];return 0===r.ort?t.width||f[e]:t.height||f[e]}function Z(t,e,n,i){var o=function(o){return!!(o=function(t,e,n){var i,r,o=0===t.type.indexOf("touch"),a=0===t.type.indexOf("mouse"),s=0===t.type.indexOf("pointer");0===t.type.indexOf("MSPointer")&&(s=!0);if("mousedown"===t.type&&!t.buttons&&!t.touches)return!1;if(o){var l=function(t){return t.target===n||n.contains(t.target)||t.target.shadowRoot&&t.target.shadowRoot.contains(n)};if("touchstart"===t.type){var u=Array.prototype.filter.call(t.touches,l);if(u.length>1)return!1;i=u[0].pageX,r=u[0].pageY}else{var c=Array.prototype.find.call(t.changedTouches,l);if(!c)return!1;i=c.pageX,r=c.pageY}}e=e||d(T),(a||s)&&(i=t.clientX+e.x,r=t.clientY+e.y);return t.pageOffset=e,t.points=[i,r],t.cursor=a||s,t}(o,i.pageOffset,i.target||e))&&(!(B()&&!i.doNotReject)&&(a=x,s=r.cssClasses.tap,!((a.classList?a.classList.contains(s):new RegExp("\\b"+s+"\\b").test(a.className))&&!i.doNotReject)&&(!(t===k.start&&void 0!==o.buttons&&o.buttons>1)&&((!i.hover||!o.buttons)&&(w||o.preventDefault(),o.calcPoint=o.points[r.ort],void n(o,i))))));var a,s},a=[];return t.split(" ").forEach(function(t){e.addEventListener(t,o,!!w&&{passive:!0}),a.push([t,o])}),a}function X(t){var e,n,i,o,s,l,u=100*(t-(e=f,n=r.ort,i=e.getBoundingClientRect(),o=e.ownerDocument,s=o.documentElement,l=d(o),/webkit.*Chrome.*Mobile/i.test(navigator.userAgent)&&(l.x=0),n?i.top+l.y-s.clientTop:i.left+l.x-s.clientLeft))/Y();return u=a(u),r.dir?100-u:u}function Q(t,e){"mouseout"===t.type&&"HTML"===t.target.nodeName&&null===t.relatedTarget&&tt(t,e)}function J(t,e){if(-1===navigator.appVersion.indexOf("MSIE 9")&&0===t.buttons&&0!==e.buttonsProperty)return tt(t,e);var n=(r.dir?-1:1)*(t.calcPoint-e.startCalcPoint);ut(n>0,100*n/e.baseSize,e.locations,e.handleNumbers)}function tt(t,e){e.handle&&(c(e.handle,r.cssClasses.active),A-=1),e.listeners.forEach(function(t){P.removeEventListener(t[0],t[1])}),0===A&&(c(x,r.cssClasses.drag),dt(),t.cursor&&(N.style.cursor="",N.removeEventListener("selectstart",i))),e.handleNumbers.forEach(function(t){at("change",t),at("set",t),at("end",t)})}function et(t,e){if(e.handleNumbers.some(q))return!1;var n;1===e.handleNumbers.length&&(n=h[e.handleNumbers[0]].children[0],A+=1,u(n,r.cssClasses.active));t.stopPropagation();var o=[],a=Z(k.move,P,J,{target:t.target,handle:n,listeners:o,startCalcPoint:t.calcPoint,baseSize:Y(),pageOffset:t.pageOffset,handleNumbers:e.handleNumbers,buttonsProperty:t.buttons,locations:S.slice()}),s=Z(k.end,P,tt,{target:t.target,handle:n,listeners:o,doNotReject:!0,handleNumbers:e.handleNumbers}),l=Z("mouseout",P,Q,{target:t.target,handle:n,listeners:o,doNotReject:!0,handleNumbers:e.handleNumbers});o.push.apply(o,a.concat(s,l)),t.cursor&&(N.style.cursor=getComputedStyle(t.target).cursor,h.length>1&&u(x,r.cssClasses.drag),N.addEventListener("selectstart",i,!1)),e.handleNumbers.forEach(function(t){at("start",t)})}function nt(t){t.stopPropagation();var e=X(t.calcPoint),n=function(t){var e=100,n=!1;return h.forEach(function(i,r){if(!q(r)){var o=S[r],a=Math.abs(o-t);(ao||100===a&&100===e)&&(n=r,e=a)}}),n}(e);if(!1===n)return!1;r.events.snap||o(x,r.cssClasses.tap,r.animationDuration),ft(n,e,!0,!0),dt(),at("slide",n,!0),at("update",n,!0),at("change",n,!0),at("set",n,!0),r.events.snap&&et(t,{handleNumbers:[n]})}function it(t){var e=X(t.calcPoint),n=_.getStep(e),i=_.fromStepping(n);Object.keys(C).forEach(function(t){"hover"===t.split(".")[0]&&C[t].forEach(function(t){t.call(g,i)})})}function rt(t,e){C[t]=C[t]||[],C[t].push(e),"update"===t.split(".")[0]&&h.forEach(function(t,e){at("update",e)})}function ot(t){var e=t&&t.split(".")[0],n=e&&t.substring(e.length);Object.keys(C).forEach(function(t){var i=t.split(".")[0],r=t.substring(i.length);e&&e!==i||n&&n!==r||delete C[t]})}function at(t,e,n){Object.keys(C).forEach(function(i){var o=i.split(".")[0];t===o&&C[i].forEach(function(t){t.call(g,E.map(r.format.to),e,E.slice(),n||!1,S.slice(),g)})})}function st(t,e,n,i,o,s){var l;return h.length>1&&!r.events.unconstrained&&(i&&e>0&&(l=_.getAbsoluteDistance(t[e-1],r.margin,0),n=Math.max(n,l)),o&&e1&&r.limit&&(i&&e>0&&(l=_.getAbsoluteDistance(t[e-1],r.limit,0),n=Math.min(n,l)),o&&e1?i.forEach(function(t,n){var i=st(r,t,r[t]+e,o[n],a[n],!1);!1===i?e=0:(e=i-r[t],r[t]=i)}):o=a=[!0];var s=!1;i.forEach(function(t,i){s=ft(t,n[t]+e,o[i],a[i])||s}),s&&i.forEach(function(t){at("update",t),at("slide",t)})}function ct(t,e){return r.dir?100-t-e:t}function dt(){O.forEach(function(t){var e=S[t]>50?-1:1,n=3+(h.length+e*t);h[t].style.zIndex=n})}function ft(t,e,n,i,o){return o||(e=st(S,t,e,n,i,!1)),!1!==e&&(function(t,e){S[t]=e,E[t]=_.fromStepping(e);var n="translate("+lt(10*(ct(e,0)-j)+"%","0")+")";h[t].style[r.transformRule]=n,ht(t),ht(t+1)}(t,e),!0)}function ht(t){if(p[t]){var e=0,n=100;0!==t&&(e=S[t-1]),t!==p.length-1&&(n=S[t]);var i=n-e,o="translate("+lt(ct(e,i)+"%","0")+")",a="scale("+lt(i/100,"1")+")";p[t].style[r.transformRule]=o+" "+a}}function pt(t,e){return null===t||!1===t||void 0===t?S[e]:("number"==typeof t&&(t=String(t)),t=r.format.from(t),!1===(t=_.toStepping(t))||isNaN(t)?S[e]:t)}function vt(t,e,n){var i=s(t),a=void 0===S[0];e=void 0===e||!!e,r.animate&&!a&&o(x,r.cssClasses.tap,r.animationDuration),O.forEach(function(t){ft(t,pt(i[t],t),!0,!1,n)});for(var l=1===O.length?0:1;ln.stepAfter.startValue&&(o=n.stepAfter.startValue-i),a=i>n.thisStep.startValue?n.thisStep.step:!1!==n.stepBefore.step&&i-n.stepBefore.highestStep,100===e?o=null:0===e&&(a=null);var s=_.countStepDecimals();return null!==o&&!1!==o&&(o=Number(o.toFixed(s))),null!==a&&!1!==a&&(a=Number(a.toFixed(s))),[a,o]}return u(y=x,r.cssClasses.target),0===r.dir?u(y,r.cssClasses.ltr):u(y,r.cssClasses.rtl),0===r.ort?u(y,r.cssClasses.horizontal):u(y,r.cssClasses.vertical),u(y,"rtl"===getComputedStyle(y).direction?r.cssClasses.textDirectionRtl:r.cssClasses.textDirectionLtr),f=R(y,r.cssClasses.base),function(t,e){var n=R(e,r.cssClasses.connects);h=[],(p=[]).push($(n,t[0]));for(var i=0;i=0&&e-1},get:function(t){return i[n.indexOf(t)]},set:function(t,e){-1===n.indexOf(t)&&(n.push(t),i.push(e))},delete:function(t){var e=n.indexOf(t);e>-1&&(n.splice(e,1),i.splice(e,1))}}),o=function(t){return new Event(t,{bubbles:!0})};try{new Event("test")}catch(t){o=function(t){var e=document.createEvent("Event");return e.initEvent(t,!0,!1),e}}function a(t){if(t&&t.nodeName&&"TEXTAREA"===t.nodeName&&!r.has(t)){var e,n=null,i=null,a=null,s=function(){t.clientWidth!==i&&d()},l=function(e){window.removeEventListener("resize",s,!1),t.removeEventListener("input",d,!1),t.removeEventListener("keyup",d,!1),t.removeEventListener("autosize:destroy",l,!1),t.removeEventListener("autosize:update",d,!1),Object.keys(e).forEach(function(n){t.style[n]=e[n]}),r.delete(t)}.bind(t,{height:t.style.height,resize:t.style.resize,overflowY:t.style.overflowY,overflowX:t.style.overflowX,wordWrap:t.style.wordWrap});t.addEventListener("autosize:destroy",l,!1),"onpropertychange"in t&&"oninput"in t&&t.addEventListener("keyup",d,!1),window.addEventListener("resize",s,!1),t.addEventListener("input",d,!1),t.addEventListener("autosize:update",d,!1),t.style.overflowX="hidden",t.style.wordWrap="break-word",r.set(t,{destroy:l,update:d}),"vertical"===(e=window.getComputedStyle(t,null)).resize?t.style.resize="none":"both"===e.resize&&(t.style.resize="horizontal"),n="content-box"===e.boxSizing?-(parseFloat(e.paddingTop)+parseFloat(e.paddingBottom)):parseFloat(e.borderTopWidth)+parseFloat(e.borderBottomWidth),isNaN(n)&&(n=0),d()}function u(e){var n=t.style.width;t.style.width="0px",t.offsetWidth,t.style.width=n,t.style.overflowY=e}function c(){if(0!==t.scrollHeight){var e=function(t){for(var e=[];t&&t.parentNode&&t.parentNode instanceof Element;)t.parentNode.scrollTop&&e.push({node:t.parentNode,scrollTop:t.parentNode.scrollTop}),t=t.parentNode;return e}(t),r=document.documentElement&&document.documentElement.scrollTop;t.style.height="",t.style.height=t.scrollHeight+n+"px",i=t.clientWidth,e.forEach(function(t){t.node.scrollTop=t.scrollTop}),r&&(document.documentElement.scrollTop=r)}}function d(){c();var e=Math.round(parseFloat(t.style.height)),n=window.getComputedStyle(t,null),i="content-box"===n.boxSizing?Math.round(parseFloat(n.height)):t.offsetHeight;if(i1?n-1:0),r=1;r