{"version":3,"sources":["webpack:///webpack/bootstrap","webpack:///./node_modules/inputmask/dist/inputmask/global/window.js","webpack:///./node_modules/inputmask/dist/inputmask/global/document.js","webpack:///external \"jQuery\"","webpack:///./node_modules/inputmask/dist/inputmask/jquery.inputmask.js","webpack:///./node_modules/inputmask/dist/inputmask/inputmask.js","webpack:///./node_modules/inputmask/dist/inputmask/dependencyLibs/inputmask.dependencyLib.js","webpack:///./src/webpack/vendor/formstyler/jquery.formstyler.js"],"names":["installedModules","__webpack_require__","moduleId","exports","module","i","l","modules","call","m","c","d","name","getter","o","Object","defineProperty","enumerable","get","r","Symbol","toStringTag","value","t","mode","__esModule","ns","create","key","bind","n","object","property","prototype","hasOwnProperty","p","s","window","document","jQuery","$","Inputmask","fn","inputmask","options","nptmask","input","this","unmaskedvalue","val","each","remove","getemptymask","hasMaskedValue","isComplete","getmetadata","setValue","option","alias","mask","undefined","ua","navigator","userAgent","mobile","isInputEventSupported","iemobile","test","iphone","internal","el","events","maskset","refreshValue","isPlainObject","opts","extend","defaults","noMasksCache","definitions","userOptions","isRTL","numericInput","resolveAlias","aliasStr","aliasDefinition","aliases","generateMaskSet","nocache","generateMask","metadata","regexMask","regex","replace","length","greedy","repeat","placeholder","repeatStart","groupmarker","quantifiermarker","masksetDefinition","maskdefKey","split","reverse","join","masksCache","maskToken","analyseMask","validPositions","_buffer","buffer","tests","excludes","maskLength","isFunction","isArray","keepStatic","charAt","altMask","ndx","msk","alternatormarker","pop","eventName","createElement","evName","isSupported","setAttribute","maskScope","actionObj","undoValue","$el","maxLength","colorMask","skipKeyPressEvent","skipInputEvent","ignorable","mouseEnter","getMaskTemplate","baseOnInput","minimalPos","includeMode","noJit","clearOptionalTail","ndxIntlzr","testPos","maskTemplate","pos","lvp","getLastValidPosition","getMaskSet","match","optionality","generatedInput","skipOptionalPartCharacter","determineTestTemplate","getTests","locator","slice","push","nativeDef","getPlaceholder","getTestTemplate","jitMasking","jit","isFinite","optionalQuantifier","newBlockMarker","def","resetMaskSet","soft","closestTo","strict","before","after","valids","posNdx","psNdx","parseInt","getDecisionTaker","tst","decisionTaker","alternation","toString","getLocator","align","mloc","tstLocator","closest","bestMatch","targetLocator","getTest","distance","Math","abs","tstPs","positionCanMatchDefinition","valid","tndx","latestMatch","maskTokens","ndxInitializer","matches","insertStop","cacheDependency","resolveTestFromToken","loopNdx","quantifierRecurse","handleMatch","isFirstMatch","tokenGroup","firstMatch","inArray","isQuantifier","isOptional","isAlternate","resolveNdxInitializer","alternateNdx","targetAlternation","indexPos","lmnt","ndxPos","indexOf","bestMatchAltIndex","isSubsetOf","source","target","expand","pattern","start","end","expanded","charCodeAt","String","fromCharCode","setMergeLocators","targetMatch","altMatch","locNdx","keys","cd","isGroup","optionalToken","mtch","isAlternator","maltMatches","alternateToken","malternateMatches","currentMatches","loopNdxCnt","altIndex","shift","amndx","currentPos","ndxInitializerClone","altIndexArr","altIndexArrClone","splice","unMatchedAlternation","concat","ndx1","dropMatch","ndx2","altMatch2","qt","qndx","isNaN","quantifier","max","min","previousPos","mtndx","casing","getBufferTemplate","getBuffer","noCache","refreshFromBuffer","valResult","isValid","caret","checkAlternationMatch","altArr1","altArr2","na","naNdx","altArrC","isMatch","naArr","alndx","alternate","fromSetValid","rAltPos","lastAlt","altPos","prevAltPos","validPos","decisionPos","validPsClone","isValidRslt","lAltPos","validInputsClone","staticInputsBeforePos","posOffset","validInputs","targetLvp","fromAlternate","validateOnly","isSelection","posObj","begin","maskPos","_isValid","position","rslt","elem","validatedPos","sort","a","b","revalidateMask","insert","toUpperCase","toLowerCase","posBefore","keyCode","SPACE","args","Array","arguments","apply","result","positionsClone","preValidation","trackbackPositions","currentPosValid","insertMode","seekNext","isMask","nPos","snPos","postValidation","postResult","refresh","originalPos","newPos","fillOnly","ps","cvpInput","validTest","IsEnclosedStatic","selection","posMatch","radixPoint","prevMatch","nextMatch","isNegative","j","needsValidation","newBlock","seekPrevious","writeBuffer","caretPos","event","triggerEvents","onBeforeWrite","_valueSet","type","renderColorMask","$input","nptVal","_valueGet","trigger","setTimeout","returnPL","prevTest","staticAlternations","valueBuffer","EventRuler","on","eventHandler","ev","e","that","nodeName","imOpts","data","off","disabled","readOnly","ctrlKey","tabThrough","TAB","preventDefault","returnVal","stopPropagation","form","evArr","EventHandlers","keydownEvent","k","BACKSPACE","DELETE","BACKSPACE_SAFARI","X","handleRemove","END","PAGE_DOWN","shiftKey","HOME","PAGE_UP","undoOnEscape","ESCAPE","altKey","checkVal","INSERT","RIGHT","LEFT","onKeyDown","ignorables","keypressEvent","checkval","writeOut","which","charCode","metaKey","ENTER","forwardPosition","offset","_radixDance","writeOutBuffer","onKeyValidation","pasteEvent","tempValue","originalEvent","inputValue","valueBeforeCaret","substr","valueAfterCaret","clipboardData","getData","pasteValue","onBeforePaste","inputFallBackEvent","inputChar","iv","frontPart","backPart","frontBufferPart","backBufferPart","entries","isEntry","fpl","entry","keypress","Event","keydown","beforeInputEvent","cancelable","inputType","setValueEvent","detail","onBeforeMask","clearMaskOnLostFocus","clearIncomplete","focusEvent","nptValue","showMaskOnFocus","showMaskOnHover","positionCaretOnTab","clickEvent","mouseleaveEvent","activeElement","getAttribute","tabbed","selectedCaret","positionCaretOnClick","clickPos","vps","radixPos","vp","clickPosition","lvclickPosition","lastPosition","tt","cutEvent","clipData","setData","execCommand","blurEvent","mouseenterEvent","submitEvent","removeMaskOnSubmit","resetEvent","nptvl","initiatingEvent","charCodes","initialNdx","autoUnmask","staticInput","RegExp","escapeRegex","umValue","pndx","unmaskedValue","onUnMask","bufferValue","translatePosition","notranslate","range","setSelectionRange","selectionStart","selectionEnd","getSelection","getRangeAt","commonAncestorContainer","parentNode","startOffset","endOffset","createRange","duplicate","moveStart","text","scrollCalc","ownerDocument","defaultView","getComputedStyle","currentStyle","fontSize","scrollLeft","scrollWidth","firstChild","textNode","createTextNode","appendChild","setStart","setEnd","collapse","sel","removeAllRanges","addRange","createTextRange","moveEnd","select","determineLastRequiredPosition","returnDefinition","bl","positions","lvTest","lvTestAlt","template","complete","lrp","aml","fromIsValid","pend","groupSeparator","initializeColorMask","computedStyle","style","width","textAlign","className","insertBefore","removeChild","left","offsetLeft","clientx","textTransform","letterSpacing","height","visibility","whiteSpace","body","itl","inputText","previousWidth","innerHTML","offsetWidth","offset1","offset2","clientX","clear","isStatic","setEntry","mtl","getElementsByTagName","positionColorMask","action","elementType","tagName","supportsInputType","isContentEditable","npt","valueGet","valueSet","nullable","setter","__valueGet","noValuePatching","getOwnPropertyDescriptor","getPrototypeOf","__proto__","constructor","valueProperty","set","configurable","textContent","__lookupGetter__","__lookupSetter__","__defineGetter__","__defineSetter__","__valueSet","overruleRTL","valHooks","inputmaskpatch","valhookGet","valhookSet","$elem","inputmode","disablePredictiveText","autocorrect","oncomplete","onincomplete","oncleared","inputEventOnly","removeAttribute","initialValue","rl","lmib","maskTarget","mtdt","dataAttribute","optionalmarker","escapeChar","noop","pastedValue","rightAlign","staticDefinitionSymbol","importDataAttributes","9","validator","definitionSymbol","elems","getElementById","querySelectorAll","scopedOpts","dataoptions","optionData","attrOptions","importOption","JSON","parse","dir","noremask","format","openingToken","currentOpeningToken","alternator","lastMatch","tokenizer","regexTokenizer","escaped","currentToken","MaskToken","openenings","openGroup","alternatorGroup","insertTestDefinition","mtoken","element","maskdef","defaultCase","mndx","groupify","groupToken","exec","mqj","mq","mq0","mq1","tmpMatch","groupQuantifier","subToken","verifyGroupMarker","token","nextToken","reverseTokens","intMatch","st","extendDefaults","extendDefinitions","definition","extendAliases","unmask","str","DOWN","UP","CONTROL","isWindow","obj","isValidElement","Element","DependencyLib","querySelector","eventRegistry","handler","_events","endx","nsEvent","namespace","addEventListener","attachEvent","removeEvent","removeEventListener","detachEvent","nmsp","resolveNamespace","hndx","hndL","evts","evNdx","offEvents","offEventsL","evnt","params","bubbles","createEvent","CustomEvent","initCustomEvent","dispatchEvent","createEventObject","eventType","fireEvent","arr","list","len","nodeType","src","copy","copyIsArray","clone","deep","callback","ltype","owner","__data","evt","define","idSuffix","filePlaceholder","fileBrowse","fileNumber","selectPlaceholder","selectSearch","selectSearchLimit","selectSearchNotFound","selectSearchPlaceholder","selectVisibleOptions","selectSmartPositioning","locale","locales","onSelectOpened","onSelectClosed","onFormStyled","Plugin","init","onDocumentClick","parents","hasClass","selectbox","search","dropdown","find","keyup","hide","addClass","removeClass","opt","iOS","Android","Attributes","attr","id","title","classes","is","checkboxOutput","att","checkbox","prependTo","click","triggerHandler","prop","focus","change","add","parent","radioOutput","radio","commonParents","cachedThis","first","filter","commonParent","inputName","fileOutput","browse","file","appendTo","files","number","numberOutput","wrap","step","timeout","interval","isNumeric","Number","changeValue","spin","newValue","decimals","multiplier","round","setInterval","clearTimeout","clearInterval","selectboxOutput","preventScrolling","selector","scrollDiff","outerHeight","wheelDelta","scrollTop","makeList","op","eq","li","liClass","liClasses","dataList","optionClass","optgroupClass","dataJqfsClass","html","append","ul","size","ulHeight","liHeight","css","top","index","clkd","siblings","prev","next","prevAll","nextAll","not","arrIndexes","innerHeight","doMultipleSelect","searchHTML","selectzIndex","divSelect","divText","optionSelected","notFound","liWidthInner","liWidth","innerWidth","selClone","selCloneWidth","outerWidth","selectHeight","searchHeight","isMaxHeight","liSelected","liOuterHeight","win","topOffset","bottomOffset","visible","minHeight","newHeight","dropDown","bottom","maxHeightBottom","floor","maxHeightTop","dropUp","right","zIndex","show","query","hover","liText","mouseout","selectedIndex","registered","doSelect","destroy","removeData","removeAttr","returns","promise","done","instance"],"mappings":"aACE,IAAIA,EAAmB,GAGvB,SAASC,EAAoBC,GAG5B,GAAGF,EAAiBE,GACnB,OAAOF,EAAiBE,GAAUC,QAGnC,IAAIC,EAASJ,EAAiBE,GAAY,CACzCG,EAAGH,EACHI,GAAG,EACHH,QAAS,IAUV,OANAI,EAAQL,GAAUM,KAAKJ,EAAOD,QAASC,EAAQA,EAAOD,QAASF,GAG/DG,EAAOE,GAAI,EAGJF,EAAOD,QAKfF,EAAoBQ,EAAIF,EAGxBN,EAAoBS,EAAIV,EAGxBC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EAAUrkB,MAAMvS,UAAU8H,MAAMvJ,KAAK+T,EAAM,aAG5D3Q,IAAZ80B,EAAwBA,EAAU31B,WARnC,GAgCRgtB,EAAgBsI,YAAa,IAnkC5B,gC","file":"frontend.bundle.js","sourcesContent":[" \t// The module cache\n \tvar installedModules = {};\n\n \t// The require function\n \tfunction __webpack_require__(moduleId) {\n\n \t\t// Check if module is in cache\n \t\tif(installedModules[moduleId]) {\n \t\t\treturn installedModules[moduleId].exports;\n \t\t}\n \t\t// Create a new module (and put it into the cache)\n \t\tvar module = installedModules[moduleId] = {\n \t\t\ti: moduleId,\n \t\t\tl: false,\n \t\t\texports: {}\n \t\t};\n\n \t\t// Execute the module function\n \t\tmodules[moduleId].call(module.exports, module, module.exports, __webpack_require__);\n\n \t\t// Flag the module as loaded\n \t\tmodule.l = true;\n\n \t\t// Return the exports of the module\n \t\treturn module.exports;\n \t}\n\n\n \t// expose the modules object (__webpack_modules__)\n \t__webpack_require__.m = modules;\n\n \t// expose the module cache\n \t__webpack_require__.c = installedModules;\n\n \t// define getter function for harmony exports\n \t__webpack_require__.d = function(exports, name, getter) {\n \t\tif(!__webpack_require__.o(exports, name)) {\n \t\t\tObject.defineProperty(exports, name, { enumerable: true, get: getter });\n \t\t}\n \t};\n\n \t// define __esModule on exports\n \t__webpack_require__.r = function(exports) {\n \t\tif(typeof Symbol !== 'undefined' && Symbol.toStringTag) {\n \t\t\tObject.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });\n \t\t}\n \t\tObject.defineProperty(exports, '__esModule', { value: true });\n \t};\n\n \t// create a fake namespace object\n \t// mode & 1: value is a module id, require it\n \t// mode & 2: merge all properties of value into the ns\n \t// mode & 4: return value when already ns object\n \t// mode & 8|1: behave like require\n \t__webpack_require__.t = function(value, mode) {\n \t\tif(mode & 1) value = __webpack_require__(value);\n \t\tif(mode & 8) return value;\n \t\tif((mode & 4) && typeof value === 'object' && value && value.__esModule) return value;\n \t\tvar ns = Object.create(null);\n \t\t__webpack_require__.r(ns);\n \t\tObject.defineProperty(ns, 'default', { enumerable: true, value: value });\n \t\tif(mode & 2 && typeof value != 'string') for(var key in value) __webpack_require__.d(ns, key, function(key) { return value[key]; }.bind(null, key));\n \t\treturn ns;\n \t};\n\n \t// getDefaultExport function for compatibility with non-harmony modules\n \t__webpack_require__.n = function(module) {\n \t\tvar getter = module && module.__esModule ?\n \t\t\tfunction getDefault() { return module['default']; } :\n \t\t\tfunction getModuleExports() { return module; };\n \t\t__webpack_require__.d(getter, 'a', getter);\n \t\treturn getter;\n \t};\n\n \t// Object.prototype.hasOwnProperty.call\n \t__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };\n\n \t// __webpack_public_path__\n \t__webpack_require__.p = \"\";\n\n\n \t// Load entry module and return exports\n \treturn __webpack_require__(__webpack_require__.s = 44);\n","/*!\n* global/window.js\n* https://github.com/RobinHerbots/Inputmask\n* Copyright (c) 2010 - 2018 Robin Herbots\n* Licensed under the MIT license (http://www.opensource.org/licenses/mit-license.php)\n* Version: 4.0.0\n*/\n\n\"function\" == typeof define && define.amd ? define(function() {\n return window;\n}) : \"object\" == typeof exports && (module.exports = window);","/*!\n* global/document.js\n* https://github.com/RobinHerbots/Inputmask\n* Copyright (c) 2010 - 2018 Robin Herbots\n* Licensed under the MIT license (http://www.opensource.org/licenses/mit-license.php)\n* Version: 4.0.0\n*/\n\n\"function\" == typeof define && define.amd ? define(function() {\n return document;\n}) : \"object\" == typeof exports && (module.exports = document);","module.exports = jQuery;","/*!\n* jquery.inputmask.js\n* https://github.com/RobinHerbots/Inputmask\n* Copyright (c) 2010 - 2018 Robin Herbots\n* Licensed under the MIT license (http://www.opensource.org/licenses/mit-license.php)\n* Version: 4.0.0\n*/\n\n!function(factory) {\n \"function\" == typeof define && define.amd ? define([ \"jquery\", \"./inputmask\" ], factory) : \"object\" == typeof exports ? module.exports = factory(require(\"jquery\"), require(\"./inputmask\")) : factory(jQuery, window.Inputmask);\n}(function($, Inputmask) {\n return void 0 === $.fn.inputmask && ($.fn.inputmask = function(fn, options) {\n var nptmask, input = this[0];\n if (void 0 === options && (options = {}), \"string\" == typeof fn) switch (fn) {\n case \"unmaskedvalue\":\n return input && input.inputmask ? input.inputmask.unmaskedvalue() : $(input).val();\n\n case \"remove\":\n return this.each(function() {\n this.inputmask && this.inputmask.remove();\n });\n\n case \"getemptymask\":\n return input && input.inputmask ? input.inputmask.getemptymask() : \"\";\n\n case \"hasMaskedValue\":\n return !(!input || !input.inputmask) && input.inputmask.hasMaskedValue();\n\n case \"isComplete\":\n return !input || !input.inputmask || input.inputmask.isComplete();\n\n case \"getmetadata\":\n return input && input.inputmask ? input.inputmask.getmetadata() : void 0;\n\n case \"setvalue\":\n Inputmask.setValue(input, options);\n break;\n\n case \"option\":\n if (\"string\" != typeof options) return this.each(function() {\n if (void 0 !== this.inputmask) return this.inputmask.option(options);\n });\n if (input && void 0 !== input.inputmask) return input.inputmask.option(options);\n break;\n\n default:\n return options.alias = fn, nptmask = new Inputmask(options), this.each(function() {\n nptmask.mask(this);\n });\n } else {\n if (\"object\" == typeof fn) return nptmask = new Inputmask(fn), void 0 === fn.mask && void 0 === fn.alias ? this.each(function() {\n if (void 0 !== this.inputmask) return this.inputmask.option(fn);\n nptmask.mask(this);\n }) : this.each(function() {\n nptmask.mask(this);\n });\n if (void 0 === fn) return this.each(function() {\n (nptmask = new Inputmask(options)).mask(this);\n });\n }\n }), $.fn.inputmask;\n});","/*!\n* inputmask.js\n* https://github.com/RobinHerbots/Inputmask\n* Copyright (c) 2010 - 2018 Robin Herbots\n* Licensed under the MIT license (http://www.opensource.org/licenses/mit-license.php)\n* Version: 4.0.0\n*/\n\n!function(factory) {\n \"function\" == typeof define && define.amd ? define([ \"./dependencyLibs/inputmask.dependencyLib\", \"./global/window\", \"./global/document\" ], factory) : \"object\" == typeof exports ? module.exports = factory(require(\"./dependencyLibs/inputmask.dependencyLib\"), require(\"./global/window\"), require(\"./global/document\")) : window.Inputmask = factory(window.dependencyLib || jQuery, window, document);\n}(function($, window, document, undefined) {\n var ua = navigator.userAgent, mobile = isInputEventSupported(\"touchstart\"), iemobile = /iemobile/i.test(ua), iphone = /iphone/i.test(ua) && !iemobile;\n function Inputmask(alias, options, internal) {\n if (!(this instanceof Inputmask)) return new Inputmask(alias, options, internal);\n this.el = undefined, this.events = {}, this.maskset = undefined, this.refreshValue = !1, \n !0 !== internal && ($.isPlainObject(alias) ? options = alias : (options = options || {}, \n alias && (options.alias = alias)), this.opts = $.extend(!0, {}, this.defaults, options), \n this.noMasksCache = options && options.definitions !== undefined, this.userOptions = options || {}, \n this.isRTL = this.opts.numericInput, resolveAlias(this.opts.alias, options, this.opts));\n }\n function resolveAlias(aliasStr, options, opts) {\n var aliasDefinition = Inputmask.prototype.aliases[aliasStr];\n return aliasDefinition ? (aliasDefinition.alias && resolveAlias(aliasDefinition.alias, undefined, opts), \n $.extend(!0, opts, aliasDefinition), $.extend(!0, opts, options), !0) : (null === opts.mask && (opts.mask = aliasStr), \n !1);\n }\n function generateMaskSet(opts, nocache) {\n function generateMask(mask, metadata, opts) {\n var regexMask = !1;\n if (null !== mask && \"\" !== mask || ((regexMask = null !== opts.regex) ? mask = (mask = opts.regex).replace(/^(\\^)(.*)(\\$)$/, \"$2\") : (regexMask = !0, \n mask = \".*\")), 1 === mask.length && !1 === opts.greedy && 0 !== opts.repeat && (opts.placeholder = \"\"), \n opts.repeat > 0 || \"*\" === opts.repeat || \"+\" === opts.repeat) {\n var repeatStart = \"*\" === opts.repeat ? 0 : \"+\" === opts.repeat ? 1 : opts.repeat;\n mask = opts.groupmarker[0] + mask + opts.groupmarker[1] + opts.quantifiermarker[0] + repeatStart + \",\" + opts.repeat + opts.quantifiermarker[1];\n }\n var masksetDefinition, maskdefKey = regexMask ? \"regex_\" + opts.regex : opts.numericInput ? mask.split(\"\").reverse().join(\"\") : mask;\n return Inputmask.prototype.masksCache[maskdefKey] === undefined || !0 === nocache ? (masksetDefinition = {\n mask: mask,\n maskToken: Inputmask.prototype.analyseMask(mask, regexMask, opts),\n validPositions: {},\n _buffer: undefined,\n buffer: undefined,\n tests: {},\n excludes: {},\n metadata: metadata,\n maskLength: undefined\n }, !0 !== nocache && (Inputmask.prototype.masksCache[maskdefKey] = masksetDefinition, \n masksetDefinition = $.extend(!0, {}, Inputmask.prototype.masksCache[maskdefKey]))) : masksetDefinition = $.extend(!0, {}, Inputmask.prototype.masksCache[maskdefKey]), \n masksetDefinition;\n }\n if ($.isFunction(opts.mask) && (opts.mask = opts.mask(opts)), $.isArray(opts.mask)) {\n if (opts.mask.length > 1) {\n if (null === opts.keepStatic) {\n opts.keepStatic = \"auto\";\n for (var i = 0; i < opts.mask.length; i++) if (opts.mask[i].charAt(0) !== opts.mask[0].charAt(0)) {\n opts.keepStatic = !0;\n break;\n }\n }\n var altMask = opts.groupmarker[0];\n return $.each(opts.isRTL ? opts.mask.reverse() : opts.mask, function(ndx, msk) {\n altMask.length > 1 && (altMask += opts.groupmarker[1] + opts.alternatormarker + opts.groupmarker[0]), \n msk.mask === undefined || $.isFunction(msk.mask) ? altMask += msk : altMask += msk.mask;\n }), generateMask(altMask += opts.groupmarker[1], opts.mask, opts);\n }\n opts.mask = opts.mask.pop();\n }\n return opts.mask && opts.mask.mask !== undefined && !$.isFunction(opts.mask.mask) ? generateMask(opts.mask.mask, opts.mask, opts) : generateMask(opts.mask, opts.mask, opts);\n }\n function isInputEventSupported(eventName) {\n var el = document.createElement(\"input\"), evName = \"on\" + eventName, isSupported = evName in el;\n return isSupported || (el.setAttribute(evName, \"return;\"), isSupported = \"function\" == typeof el[evName]), \n el = null, isSupported;\n }\n function maskScope(actionObj, maskset, opts) {\n maskset = maskset || this.maskset, opts = opts || this.opts;\n var undoValue, $el, maxLength, colorMask, inputmask = this, el = this.el, isRTL = this.isRTL, skipKeyPressEvent = !1, skipInputEvent = !1, ignorable = !1, mouseEnter = !1;\n function getMaskTemplate(baseOnInput, minimalPos, includeMode, noJit, clearOptionalTail) {\n !0 !== noJit && (undefined, 0);\n var greedy = opts.greedy;\n clearOptionalTail && (opts.greedy = !1), minimalPos = minimalPos || 0;\n var ndxIntlzr, test, testPos, maskTemplate = [], pos = 0, lvp = getLastValidPosition();\n do {\n if (!0 === baseOnInput && getMaskSet().validPositions[pos]) test = (testPos = clearOptionalTail && !0 === getMaskSet().validPositions[pos].match.optionality && getMaskSet().validPositions[pos + 1] === undefined && (!0 === getMaskSet().validPositions[pos].generatedInput || getMaskSet().validPositions[pos].input == opts.skipOptionalPartCharacter && pos > 0) ? determineTestTemplate(pos, getTests(pos, ndxIntlzr, pos - 1)) : getMaskSet().validPositions[pos]).match, \n ndxIntlzr = testPos.locator.slice(), maskTemplate.push(!0 === includeMode ? testPos.input : !1 === includeMode ? test.nativeDef : getPlaceholder(pos, test)); else {\n test = (testPos = getTestTemplate(pos, ndxIntlzr, pos - 1)).match, ndxIntlzr = testPos.locator.slice();\n var jitMasking = !0 !== noJit && (!1 !== opts.jitMasking ? opts.jitMasking : test.jit);\n !1 === jitMasking || jitMasking === undefined || pos < lvp || \"number\" == typeof jitMasking && isFinite(jitMasking) && jitMasking > pos ? maskTemplate.push(!1 === includeMode ? test.nativeDef : getPlaceholder(pos, test)) : test.jit && test.optionalQuantifier !== undefined && (pos, \n 0);\n }\n \"auto\" === opts.keepStatic && test.newBlockMarker && null !== test.fn && (opts.keepStatic = pos - 1), \n pos++;\n } while ((maxLength === undefined || pos < maxLength) && (null !== test.fn || \"\" !== test.def) || minimalPos > pos);\n return \"\" === maskTemplate[maskTemplate.length - 1] && maskTemplate.pop(), !1 === includeMode && getMaskSet().maskLength !== undefined || (getMaskSet().maskLength = pos - 1), \n opts.greedy = greedy, maskTemplate;\n }\n function getMaskSet() {\n return maskset;\n }\n function resetMaskSet(soft) {\n var maskset = getMaskSet();\n maskset.buffer = undefined, !0 !== soft && (maskset.validPositions = {}, maskset.p = 0);\n }\n function getLastValidPosition(closestTo, strict, validPositions) {\n var before = -1, after = -1, valids = validPositions || getMaskSet().validPositions;\n for (var posNdx in closestTo === undefined && (closestTo = -1), valids) {\n var psNdx = parseInt(posNdx);\n valids[psNdx] && (strict || !0 !== valids[psNdx].generatedInput) && (psNdx <= closestTo && (before = psNdx), \n psNdx >= closestTo && (after = psNdx));\n }\n return -1 === before || before == closestTo ? after : -1 == after ? before : closestTo - before < after - closestTo ? before : after;\n }\n function getDecisionTaker(tst) {\n var decisionTaker = tst.locator[tst.alternation];\n return \"string\" == typeof decisionTaker && decisionTaker.length > 0 && (decisionTaker = decisionTaker.split(\",\")[0]), \n decisionTaker !== undefined ? decisionTaker.toString() : \"\";\n }\n function getLocator(tst, align) {\n var locator = (tst.alternation != undefined ? tst.mloc[getDecisionTaker(tst)] : tst.locator).join(\"\");\n if (\"\" !== locator) for (;locator.length < align; ) locator += \"0\";\n return locator;\n }\n function determineTestTemplate(pos, tests) {\n for (var tstLocator, closest, bestMatch, targetLocator = getLocator(getTest(pos = pos > 0 ? pos - 1 : 0)), ndx = 0; ndx < tests.length; ndx++) {\n var tst = tests[ndx];\n tstLocator = getLocator(tst, targetLocator.length);\n var distance = Math.abs(tstLocator - targetLocator);\n (closest === undefined || \"\" !== tstLocator && distance < closest || bestMatch && bestMatch.match.optionality && \"master\" === bestMatch.match.newBlockMarker && (!tst.match.optionality || !tst.match.newBlockMarker) || bestMatch && bestMatch.match.optionalQuantifier && !tst.match.optionalQuantifier) && (closest = distance, \n bestMatch = tst);\n }\n return bestMatch;\n }\n function getTestTemplate(pos, ndxIntlzr, tstPs) {\n return getMaskSet().validPositions[pos] || determineTestTemplate(pos, getTests(pos, ndxIntlzr ? ndxIntlzr.slice() : ndxIntlzr, tstPs));\n }\n function getTest(pos, tests) {\n return getMaskSet().validPositions[pos] ? getMaskSet().validPositions[pos] : (tests || getTests(pos))[0];\n }\n function positionCanMatchDefinition(pos, def) {\n for (var valid = !1, tests = getTests(pos), tndx = 0; tndx < tests.length; tndx++) if (tests[tndx].match && tests[tndx].match.def === def) {\n valid = !0;\n break;\n }\n return valid;\n }\n function getTests(pos, ndxIntlzr, tstPs) {\n var latestMatch, maskTokens = getMaskSet().maskToken, testPos = ndxIntlzr ? tstPs : 0, ndxInitializer = ndxIntlzr ? ndxIntlzr.slice() : [ 0 ], matches = [], insertStop = !1, cacheDependency = ndxIntlzr ? ndxIntlzr.join(\"\") : \"\";\n function resolveTestFromToken(maskToken, ndxInitializer, loopNdx, quantifierRecurse) {\n function handleMatch(match, loopNdx, quantifierRecurse) {\n function isFirstMatch(latestMatch, tokenGroup) {\n var firstMatch = 0 === $.inArray(latestMatch, tokenGroup.matches);\n return firstMatch || $.each(tokenGroup.matches, function(ndx, match) {\n if (!0 === match.isQuantifier ? firstMatch = isFirstMatch(latestMatch, tokenGroup.matches[ndx - 1]) : !0 === match.isOptional ? firstMatch = isFirstMatch(latestMatch, match) : !0 === match.isAlternate && (firstMatch = isFirstMatch(latestMatch, match)), \n firstMatch) return !1;\n }), firstMatch;\n }\n function resolveNdxInitializer(pos, alternateNdx, targetAlternation) {\n var bestMatch, indexPos;\n if ((getMaskSet().tests[pos] || getMaskSet().validPositions[pos]) && $.each(getMaskSet().tests[pos] || [ getMaskSet().validPositions[pos] ], function(ndx, lmnt) {\n if (lmnt.mloc[alternateNdx]) return bestMatch = lmnt, !1;\n var alternation = targetAlternation !== undefined ? targetAlternation : lmnt.alternation, ndxPos = lmnt.locator[alternation] !== undefined ? lmnt.locator[alternation].toString().indexOf(alternateNdx) : -1;\n (indexPos === undefined || ndxPos < indexPos) && -1 !== ndxPos && (bestMatch = lmnt, \n indexPos = ndxPos);\n }), bestMatch) {\n var bestMatchAltIndex = bestMatch.locator[bestMatch.alternation];\n return (bestMatch.mloc[alternateNdx] || bestMatch.mloc[bestMatchAltIndex] || bestMatch.locator).slice((targetAlternation !== undefined ? targetAlternation : bestMatch.alternation) + 1);\n }\n return targetAlternation !== undefined ? resolveNdxInitializer(pos, alternateNdx) : undefined;\n }\n function isSubsetOf(source, target) {\n function expand(pattern) {\n for (var start, end, expanded = [], i = 0, l = pattern.length; i < l; i++) if (\"-\" === pattern.charAt(i)) for (end = pattern.charCodeAt(i + 1); ++start < end; ) expanded.push(String.fromCharCode(start)); else start = pattern.charCodeAt(i), \n expanded.push(pattern.charAt(i));\n return expanded.join(\"\");\n }\n return opts.regex && null !== source.match.fn && null !== target.match.fn ? -1 !== expand(target.match.def.replace(/[\\[\\]]/g, \"\")).indexOf(expand(source.match.def.replace(/[\\[\\]]/g, \"\"))) : source.match.def === target.match.nativeDef;\n }\n function setMergeLocators(targetMatch, altMatch) {\n if (altMatch === undefined || targetMatch.alternation === altMatch.alternation && -1 === targetMatch.locator[targetMatch.alternation].toString().indexOf(altMatch.locator[altMatch.alternation])) {\n targetMatch.mloc = targetMatch.mloc || {};\n var locNdx = targetMatch.locator[targetMatch.alternation];\n if (locNdx !== undefined) {\n if (\"string\" == typeof locNdx && (locNdx = locNdx.split(\",\")[0]), targetMatch.mloc[locNdx] === undefined && (targetMatch.mloc[locNdx] = targetMatch.locator.slice()), \n altMatch !== undefined) {\n for (var ndx in altMatch.mloc) \"string\" == typeof ndx && (ndx = ndx.split(\",\")[0]), \n targetMatch.mloc[ndx] === undefined && (targetMatch.mloc[ndx] = altMatch.mloc[ndx]);\n targetMatch.locator[targetMatch.alternation] = Object.keys(targetMatch.mloc).join(\",\");\n }\n return !0;\n }\n targetMatch.alternation = undefined;\n }\n return !1;\n }\n if (testPos > 5e3) throw \"Inputmask: There is probably an error in your mask definition or in the code. Create an issue on github with an example of the mask you are using. \" + getMaskSet().mask;\n if (testPos === pos && match.matches === undefined) return matches.push({\n match: match,\n locator: loopNdx.reverse(),\n cd: cacheDependency,\n mloc: {}\n }), !0;\n if (match.matches !== undefined) {\n if (match.isGroup && quantifierRecurse !== match) {\n if (match = handleMatch(maskToken.matches[$.inArray(match, maskToken.matches) + 1], loopNdx, quantifierRecurse)) return !0;\n } else if (match.isOptional) {\n var optionalToken = match;\n if (match = resolveTestFromToken(match, ndxInitializer, loopNdx, quantifierRecurse)) {\n if ($.each(matches, function(ndx, mtch) {\n mtch.match.optionality = !0;\n }), latestMatch = matches[matches.length - 1].match, quantifierRecurse !== undefined || !isFirstMatch(latestMatch, optionalToken)) return !0;\n insertStop = !0, testPos = pos;\n }\n } else if (match.isAlternator) {\n var maltMatches, alternateToken = match, malternateMatches = [], currentMatches = matches.slice(), loopNdxCnt = loopNdx.length, altIndex = ndxInitializer.length > 0 ? ndxInitializer.shift() : -1;\n if (-1 === altIndex || \"string\" == typeof altIndex) {\n var amndx, currentPos = testPos, ndxInitializerClone = ndxInitializer.slice(), altIndexArr = [];\n if (\"string\" == typeof altIndex) altIndexArr = altIndex.split(\",\"); else for (amndx = 0; amndx < alternateToken.matches.length; amndx++) altIndexArr.push(amndx.toString());\n if (getMaskSet().excludes[pos]) {\n for (var altIndexArrClone = altIndexArr.slice(), i = 0, el = getMaskSet().excludes[pos].length; i < el; i++) altIndexArr.splice(altIndexArr.indexOf(getMaskSet().excludes[pos][i].toString()), 1);\n 0 === altIndexArr.length && (getMaskSet().excludes[pos] = undefined, altIndexArr = altIndexArrClone);\n }\n (!0 === opts.keepStatic || isFinite(parseInt(opts.keepStatic)) && currentPos >= opts.keepStatic) && (altIndexArr = altIndexArr.slice(0, 1));\n for (var unMatchedAlternation = !1, ndx = 0; ndx < altIndexArr.length; ndx++) {\n amndx = parseInt(altIndexArr[ndx]), matches = [], ndxInitializer = \"string\" == typeof altIndex && resolveNdxInitializer(testPos, amndx, loopNdxCnt) || ndxInitializerClone.slice(), \n alternateToken.matches[amndx] && handleMatch(alternateToken.matches[amndx], [ amndx ].concat(loopNdx), quantifierRecurse) ? match = !0 : 0 === ndx && (unMatchedAlternation = !0), \n maltMatches = matches.slice(), testPos = currentPos, matches = [];\n for (var ndx1 = 0; ndx1 < maltMatches.length; ndx1++) {\n var altMatch = maltMatches[ndx1], dropMatch = !1;\n altMatch.match.jit = altMatch.match.jit || unMatchedAlternation, altMatch.alternation = altMatch.alternation || loopNdxCnt, \n setMergeLocators(altMatch);\n for (var ndx2 = 0; ndx2 < malternateMatches.length; ndx2++) {\n var altMatch2 = malternateMatches[ndx2];\n if (\"string\" != typeof altIndex || altMatch.alternation !== undefined && -1 !== $.inArray(altMatch.locator[altMatch.alternation].toString(), altIndexArr)) {\n if (altMatch.match.nativeDef === altMatch2.match.nativeDef) {\n dropMatch = !0, setMergeLocators(altMatch2, altMatch);\n break;\n }\n if (isSubsetOf(altMatch, altMatch2)) {\n setMergeLocators(altMatch, altMatch2) && (dropMatch = !0, malternateMatches.splice(malternateMatches.indexOf(altMatch2), 0, altMatch));\n break;\n }\n if (isSubsetOf(altMatch2, altMatch)) {\n setMergeLocators(altMatch2, altMatch);\n break;\n }\n if (target = altMatch2, null === (source = altMatch).match.fn && null !== target.match.fn && target.match.fn.test(source.match.def, getMaskSet(), pos, !1, opts, !1)) {\n setMergeLocators(altMatch, altMatch2) && (dropMatch = !0, malternateMatches.splice(malternateMatches.indexOf(altMatch2), 0, altMatch));\n break;\n }\n }\n }\n dropMatch || malternateMatches.push(altMatch);\n }\n }\n matches = currentMatches.concat(malternateMatches), testPos = pos, insertStop = matches.length > 0, \n match = malternateMatches.length > 0, ndxInitializer = ndxInitializerClone.slice();\n } else match = handleMatch(alternateToken.matches[altIndex] || maskToken.matches[altIndex], [ altIndex ].concat(loopNdx), quantifierRecurse);\n if (match) return !0;\n } else if (match.isQuantifier && quantifierRecurse !== maskToken.matches[$.inArray(match, maskToken.matches) - 1]) for (var qt = match, qndx = ndxInitializer.length > 0 ? ndxInitializer.shift() : 0; qndx < (isNaN(qt.quantifier.max) ? qndx + 1 : qt.quantifier.max) && testPos <= pos; qndx++) {\n var tokenGroup = maskToken.matches[$.inArray(qt, maskToken.matches) - 1];\n if (match = handleMatch(tokenGroup, [ qndx ].concat(loopNdx), tokenGroup)) {\n if ((latestMatch = matches[matches.length - 1].match).optionalQuantifier = qndx > qt.quantifier.min - 1, \n latestMatch.jit = qndx + tokenGroup.matches.indexOf(latestMatch) >= qt.quantifier.jit, \n isFirstMatch(latestMatch, tokenGroup) && qndx > qt.quantifier.min - 1) {\n insertStop = !0, testPos = pos;\n break;\n }\n if (qt.quantifier.jit !== undefined && isNaN(qt.quantifier.max) && latestMatch.optionalQuantifier && getMaskSet().validPositions[pos - 1] === undefined) {\n matches.pop(), insertStop = !0, testPos = pos, cacheDependency = undefined;\n break;\n }\n return !0;\n }\n } else if (match = resolveTestFromToken(match, ndxInitializer, loopNdx, quantifierRecurse)) return !0;\n } else testPos++;\n var source, target;\n }\n for (var tndx = ndxInitializer.length > 0 ? ndxInitializer.shift() : 0; tndx < maskToken.matches.length; tndx++) if (!0 !== maskToken.matches[tndx].isQuantifier) {\n var match = handleMatch(maskToken.matches[tndx], [ tndx ].concat(loopNdx), quantifierRecurse);\n if (match && testPos === pos) return match;\n if (testPos > pos) break;\n }\n }\n if (pos > -1) {\n if (ndxIntlzr === undefined) {\n for (var test, previousPos = pos - 1; (test = getMaskSet().validPositions[previousPos] || getMaskSet().tests[previousPos]) === undefined && previousPos > -1; ) previousPos--;\n test !== undefined && previousPos > -1 && (ndxInitializer = function(pos, tests) {\n var locator = [];\n return $.isArray(tests) || (tests = [ tests ]), tests.length > 0 && (tests[0].alternation === undefined ? 0 === (locator = determineTestTemplate(pos, tests.slice()).locator.slice()).length && (locator = tests[0].locator.slice()) : $.each(tests, function(ndx, tst) {\n if (\"\" !== tst.def) if (0 === locator.length) locator = tst.locator.slice(); else for (var i = 0; i < locator.length; i++) tst.locator[i] && -1 === locator[i].toString().indexOf(tst.locator[i]) && (locator[i] += \",\" + tst.locator[i]);\n })), locator;\n }(previousPos, test), cacheDependency = ndxInitializer.join(\"\"), testPos = previousPos);\n }\n if (getMaskSet().tests[pos] && getMaskSet().tests[pos][0].cd === cacheDependency) return getMaskSet().tests[pos];\n for (var mtndx = ndxInitializer.shift(); mtndx < maskTokens.length; mtndx++) {\n if (resolveTestFromToken(maskTokens[mtndx], ndxInitializer, [ mtndx ]) && testPos === pos || testPos > pos) break;\n }\n }\n return (0 === matches.length || insertStop) && matches.push({\n match: {\n fn: null,\n optionality: !1,\n casing: null,\n def: \"\",\n placeholder: \"\"\n },\n locator: [],\n mloc: {},\n cd: cacheDependency\n }), ndxIntlzr !== undefined && getMaskSet().tests[pos] ? $.extend(!0, [], matches) : (getMaskSet().tests[pos] = $.extend(!0, [], matches), \n getMaskSet().tests[pos]);\n }\n function getBufferTemplate() {\n return getMaskSet()._buffer === undefined && (getMaskSet()._buffer = getMaskTemplate(!1, 1), \n getMaskSet().buffer === undefined && (getMaskSet().buffer = getMaskSet()._buffer.slice())), \n getMaskSet()._buffer;\n }\n function getBuffer(noCache) {\n return getMaskSet().buffer !== undefined && !0 !== noCache || (getMaskSet().buffer = getMaskTemplate(!0, getLastValidPosition(), !0)), \n getMaskSet().buffer;\n }\n function refreshFromBuffer(start, end, buffer) {\n var i, p;\n if (!0 === start) resetMaskSet(), start = 0, end = buffer.length; else for (i = start; i < end; i++) delete getMaskSet().validPositions[i];\n for (p = start, i = start; i < end; i++) if (resetMaskSet(!0), buffer[i] !== opts.skipOptionalPartCharacter) {\n var valResult = isValid(p, buffer[i], !0, !0);\n !1 !== valResult && (resetMaskSet(!0), p = valResult.caret !== undefined ? valResult.caret : valResult.pos + 1);\n }\n }\n function checkAlternationMatch(altArr1, altArr2, na) {\n for (var naNdx, altArrC = opts.greedy ? altArr2 : altArr2.slice(0, 1), isMatch = !1, naArr = na !== undefined ? na.split(\",\") : [], i = 0; i < naArr.length; i++) -1 !== (naNdx = altArr1.indexOf(naArr[i])) && altArr1.splice(naNdx, 1);\n for (var alndx = 0; alndx < altArr1.length; alndx++) if (-1 !== $.inArray(altArr1[alndx], altArrC)) {\n isMatch = !0;\n break;\n }\n return isMatch;\n }\n function alternate(pos, c, strict, fromSetValid, rAltPos) {\n var lastAlt, alternation, altPos, prevAltPos, i, validPos, decisionPos, validPsClone = $.extend(!0, {}, getMaskSet().validPositions), isValidRslt = !1, lAltPos = rAltPos !== undefined ? rAltPos : getLastValidPosition();\n if (-1 === lAltPos && rAltPos === undefined) alternation = (prevAltPos = getTest(lastAlt = 0)).alternation; else for (;lAltPos >= 0; lAltPos--) if ((altPos = getMaskSet().validPositions[lAltPos]) && altPos.alternation !== undefined) {\n if (prevAltPos && prevAltPos.locator[altPos.alternation] !== altPos.locator[altPos.alternation]) break;\n lastAlt = lAltPos, alternation = getMaskSet().validPositions[lastAlt].alternation, \n prevAltPos = altPos;\n }\n if (alternation !== undefined) {\n decisionPos = parseInt(lastAlt), getMaskSet().excludes[decisionPos] = getMaskSet().excludes[decisionPos] || [], \n !0 !== pos && getMaskSet().excludes[decisionPos].push(getDecisionTaker(prevAltPos));\n var validInputsClone = [], staticInputsBeforePos = 0;\n for (i = decisionPos; i < getLastValidPosition(undefined, !0) + 1; i++) (validPos = getMaskSet().validPositions[i]) && !0 !== validPos.generatedInput ? validInputsClone.push(validPos.input) : i < pos && staticInputsBeforePos++, \n delete getMaskSet().validPositions[i];\n for (;getMaskSet().excludes[decisionPos] && getMaskSet().excludes[decisionPos].length < 10; ) {\n var posOffset = -1 * staticInputsBeforePos, validInputs = validInputsClone.slice();\n for (getMaskSet().tests[decisionPos] = undefined, resetMaskSet(!0), isValidRslt = !0; validInputs.length > 0; ) {\n var input = validInputs.shift();\n if (!(isValidRslt = isValid(getLastValidPosition(undefined, !0) + 1, input, !1, fromSetValid, !0))) break;\n }\n if (isValidRslt && c !== undefined) {\n var targetLvp = getLastValidPosition(pos) + 1;\n for (i = decisionPos; i < getLastValidPosition() + 1; i++) ((validPos = getMaskSet().validPositions[i]) === undefined || null == validPos.match.fn) && i < pos + posOffset && posOffset++;\n isValidRslt = isValid((pos += posOffset) > targetLvp ? targetLvp : pos, c, strict, fromSetValid, !0);\n }\n if (isValidRslt) break;\n if (resetMaskSet(), prevAltPos = getTest(decisionPos), getMaskSet().validPositions = $.extend(!0, {}, validPsClone), \n !getMaskSet().excludes[decisionPos]) {\n isValidRslt = alternate(pos, c, strict, fromSetValid, decisionPos - 1);\n break;\n }\n var decisionTaker = getDecisionTaker(prevAltPos);\n if (-1 !== getMaskSet().excludes[decisionPos].indexOf(decisionTaker)) {\n isValidRslt = alternate(pos, c, strict, fromSetValid, decisionPos - 1);\n break;\n }\n for (getMaskSet().excludes[decisionPos].push(decisionTaker), i = decisionPos; i < getLastValidPosition(undefined, !0) + 1; i++) delete getMaskSet().validPositions[i];\n }\n }\n return getMaskSet().excludes[decisionPos] = undefined, isValidRslt;\n }\n function isValid(pos, c, strict, fromSetValid, fromAlternate, validateOnly) {\n function isSelection(posObj) {\n return isRTL ? posObj.begin - posObj.end > 1 || posObj.begin - posObj.end == 1 : posObj.end - posObj.begin > 1 || posObj.end - posObj.begin == 1;\n }\n strict = !0 === strict;\n var maskPos = pos;\n function _isValid(position, c, strict) {\n var rslt = !1;\n return $.each(getTests(position), function(ndx, tst) {\n var test = tst.match;\n if (getBuffer(!0), !1 !== (rslt = null != test.fn ? test.fn.test(c, getMaskSet(), position, strict, opts, isSelection(pos)) : (c === test.def || c === opts.skipOptionalPartCharacter) && \"\" !== test.def && {\n c: getPlaceholder(position, test, !0) || test.def,\n pos: position\n })) {\n var elem = rslt.c !== undefined ? rslt.c : c, validatedPos = position;\n return elem = elem === opts.skipOptionalPartCharacter && null === test.fn ? getPlaceholder(position, test, !0) || test.def : elem, \n rslt.remove !== undefined && ($.isArray(rslt.remove) || (rslt.remove = [ rslt.remove ]), \n $.each(rslt.remove.sort(function(a, b) {\n return b - a;\n }), function(ndx, lmnt) {\n revalidateMask({\n begin: lmnt,\n end: lmnt + 1\n });\n })), rslt.insert !== undefined && ($.isArray(rslt.insert) || (rslt.insert = [ rslt.insert ]), \n $.each(rslt.insert.sort(function(a, b) {\n return a - b;\n }), function(ndx, lmnt) {\n isValid(lmnt.pos, lmnt.c, !0, fromSetValid);\n })), !0 !== rslt && rslt.pos !== undefined && rslt.pos !== position && (validatedPos = rslt.pos), \n !0 !== rslt && rslt.pos === undefined && rslt.c === undefined ? !1 : (revalidateMask(pos, $.extend({}, tst, {\n input: function(elem, test, pos) {\n switch (opts.casing || test.casing) {\n case \"upper\":\n elem = elem.toUpperCase();\n break;\n\n case \"lower\":\n elem = elem.toLowerCase();\n break;\n\n case \"title\":\n var posBefore = getMaskSet().validPositions[pos - 1];\n elem = 0 === pos || posBefore && posBefore.input === String.fromCharCode(Inputmask.keyCode.SPACE) ? elem.toUpperCase() : elem.toLowerCase();\n break;\n\n default:\n if ($.isFunction(opts.casing)) {\n var args = Array.prototype.slice.call(arguments);\n args.push(getMaskSet().validPositions), elem = opts.casing.apply(this, args);\n }\n }\n return elem;\n }(elem, test, validatedPos)\n }), fromSetValid, validatedPos) || (rslt = !1), !1);\n }\n }), rslt;\n }\n pos.begin !== undefined && (maskPos = isRTL ? pos.end : pos.begin);\n var result = !0, positionsClone = $.extend(!0, {}, getMaskSet().validPositions);\n if ($.isFunction(opts.preValidation) && !strict && !0 !== fromSetValid && !0 !== validateOnly && (result = opts.preValidation(getBuffer(), maskPos, c, isSelection(pos), opts, getMaskSet())), \n !0 === result) {\n if (trackbackPositions(undefined, maskPos, !0), (maxLength === undefined || maskPos < maxLength) && (result = _isValid(maskPos, c, strict), \n (!strict || !0 === fromSetValid) && !1 === result && !0 !== validateOnly)) {\n var currentPosValid = getMaskSet().validPositions[maskPos];\n if (!currentPosValid || null !== currentPosValid.match.fn || currentPosValid.match.def !== c && c !== opts.skipOptionalPartCharacter) {\n if ((opts.insertMode || getMaskSet().validPositions[seekNext(maskPos)] === undefined) && !isMask(maskPos, !0)) for (var nPos = maskPos + 1, snPos = seekNext(maskPos); nPos <= snPos; nPos++) if (!1 !== (result = _isValid(nPos, c, strict))) {\n result = trackbackPositions(maskPos, result.pos !== undefined ? result.pos : nPos) || result, \n maskPos = nPos;\n break;\n }\n } else result = {\n caret: seekNext(maskPos)\n };\n }\n !1 !== result || !1 === opts.keepStatic || null != opts.regex && !isComplete(getBuffer()) || strict || !0 === fromAlternate || (result = alternate(maskPos, c, strict, fromSetValid)), \n !0 === result && (result = {\n pos: maskPos\n });\n }\n if ($.isFunction(opts.postValidation) && !1 !== result && !strict && !0 !== fromSetValid && !0 !== validateOnly) {\n var postResult = opts.postValidation(getBuffer(!0), result, opts);\n if (postResult !== undefined) {\n if (postResult.refreshFromBuffer && postResult.buffer) {\n var refresh = postResult.refreshFromBuffer;\n refreshFromBuffer(!0 === refresh ? refresh : refresh.start, refresh.end, postResult.buffer);\n }\n result = !0 === postResult ? result : postResult;\n }\n }\n return result && result.pos === undefined && (result.pos = maskPos), !1 !== result && !0 !== validateOnly || (resetMaskSet(!0), \n getMaskSet().validPositions = $.extend(!0, {}, positionsClone)), result;\n }\n function trackbackPositions(originalPos, newPos, fillOnly) {\n var result;\n if (originalPos === undefined) for (originalPos = newPos - 1; originalPos > 0 && !getMaskSet().validPositions[originalPos]; originalPos--) ;\n for (var ps = originalPos; ps < newPos; ps++) {\n if (getMaskSet().validPositions[ps] === undefined && !isMask(ps, !0)) if (0 == ps ? getTest(ps) : getMaskSet().validPositions[ps - 1]) {\n var tests = getTests(ps).slice();\n \"\" === tests[tests.length - 1].match.def && tests.pop();\n var bestMatch = determineTestTemplate(ps, tests);\n if ((bestMatch = $.extend({}, bestMatch, {\n input: getPlaceholder(ps, bestMatch.match, !0) || bestMatch.match.def\n })).generatedInput = !0, revalidateMask(ps, bestMatch, !0), !0 !== fillOnly) {\n var cvpInput = getMaskSet().validPositions[newPos].input;\n getMaskSet().validPositions[newPos] = undefined, result = isValid(newPos, cvpInput, !0, !0);\n }\n }\n }\n return result;\n }\n function revalidateMask(pos, validTest, fromSetValid, validatedPos) {\n function IsEnclosedStatic(pos, valids, selection) {\n var posMatch = valids[pos];\n if (posMatch !== undefined && (null === posMatch.match.fn && !0 !== posMatch.match.optionality || posMatch.input === opts.radixPoint)) {\n var prevMatch = selection.begin <= pos - 1 ? valids[pos - 1] && null === valids[pos - 1].match.fn && valids[pos - 1] : valids[pos - 1], nextMatch = selection.end > pos + 1 ? valids[pos + 1] && null === valids[pos + 1].match.fn && valids[pos + 1] : valids[pos + 1];\n return prevMatch && nextMatch;\n }\n return !1;\n }\n var begin = pos.begin !== undefined ? pos.begin : pos, end = pos.end !== undefined ? pos.end : pos;\n if (pos.begin > pos.end && (begin = pos.end, end = pos.begin), validatedPos = validatedPos !== undefined ? validatedPos : begin, \n begin !== end || opts.insertMode && getMaskSet().validPositions[validatedPos] !== undefined && fromSetValid === undefined) {\n var positionsClone = $.extend(!0, {}, getMaskSet().validPositions), lvp = getLastValidPosition(undefined, !0);\n for (getMaskSet().p = begin, i = lvp; i >= begin; i--) getMaskSet().validPositions[i] && \"+\" === getMaskSet().validPositions[i].match.nativeDef && (opts.isNegative = !1), \n delete getMaskSet().validPositions[i];\n var valid = !0, j = validatedPos, needsValidation = (getMaskSet().validPositions, \n !1), posMatch = j, i = j;\n for (validTest && (getMaskSet().validPositions[validatedPos] = $.extend(!0, {}, validTest), \n posMatch++, j++, begin < end && i++); i <= lvp; i++) {\n var t = positionsClone[i];\n if (t !== undefined && (i >= end || i >= begin && !0 !== t.generatedInput && IsEnclosedStatic(i, positionsClone, {\n begin: begin,\n end: end\n }))) {\n for (;\"\" !== getTest(posMatch).match.def; ) {\n if (!1 === needsValidation && positionsClone[posMatch] && positionsClone[posMatch].match.nativeDef === t.match.nativeDef) getMaskSet().validPositions[posMatch] = $.extend(!0, {}, positionsClone[posMatch]), \n getMaskSet().validPositions[posMatch].input = t.input, trackbackPositions(undefined, posMatch, !0), \n j = posMatch + 1, valid = !0; else if (positionCanMatchDefinition(posMatch, t.match.def)) {\n var result = isValid(posMatch, t.input, !0, !0);\n valid = !1 !== result, j = result.caret || result.insert ? getLastValidPosition() : posMatch + 1, \n needsValidation = !0;\n } else if (!(valid = !0 === t.generatedInput || t.input === opts.radixPoint && !0 === opts.numericInput) && \"\" === getTest(posMatch).match.def) break;\n if (valid) break;\n posMatch++;\n }\n \"\" == getTest(posMatch).match.def && (valid = !1), posMatch = j;\n }\n if (!valid) break;\n }\n if (!valid) return getMaskSet().validPositions = $.extend(!0, {}, positionsClone), \n resetMaskSet(!0), !1;\n } else validTest && (getMaskSet().validPositions[validatedPos] = $.extend(!0, {}, validTest));\n return resetMaskSet(!0), !0;\n }\n function isMask(pos, strict) {\n var test = getTestTemplate(pos).match;\n if (\"\" === test.def && (test = getTest(pos).match), null != test.fn) return test.fn;\n if (!0 !== strict && pos > -1) {\n var tests = getTests(pos);\n return tests.length > 1 + (\"\" === tests[tests.length - 1].match.def ? 1 : 0);\n }\n return !1;\n }\n function seekNext(pos, newBlock) {\n for (var position = pos + 1; \"\" !== getTest(position).match.def && (!0 === newBlock && (!0 !== getTest(position).match.newBlockMarker || !isMask(position)) || !0 !== newBlock && !isMask(position)); ) position++;\n return position;\n }\n function seekPrevious(pos, newBlock) {\n var tests, position = pos;\n if (position <= 0) return 0;\n for (;--position > 0 && (!0 === newBlock && !0 !== getTest(position).match.newBlockMarker || !0 !== newBlock && !isMask(position) && ((tests = getTests(position)).length < 2 || 2 === tests.length && \"\" === tests[1].match.def)); ) ;\n return position;\n }\n function writeBuffer(input, buffer, caretPos, event, triggerEvents) {\n if (event && $.isFunction(opts.onBeforeWrite)) {\n var result = opts.onBeforeWrite.call(inputmask, event, buffer, caretPos, opts);\n if (result) {\n if (result.refreshFromBuffer) {\n var refresh = result.refreshFromBuffer;\n refreshFromBuffer(!0 === refresh ? refresh : refresh.start, refresh.end, result.buffer || buffer), \n buffer = getBuffer(!0);\n }\n caretPos !== undefined && (caretPos = result.caret !== undefined ? result.caret : caretPos);\n }\n }\n if (input !== undefined && (input.inputmask._valueSet(buffer.join(\"\")), caretPos === undefined || event !== undefined && \"blur\" === event.type ? renderColorMask(input, caretPos, 0 === buffer.length) : caret(input, caretPos), \n !0 === triggerEvents)) {\n var $input = $(input), nptVal = input.inputmask._valueGet();\n skipInputEvent = !0, $input.trigger(\"input\"), setTimeout(function() {\n nptVal === getBufferTemplate().join(\"\") ? $input.trigger(\"cleared\") : !0 === isComplete(buffer) && $input.trigger(\"complete\");\n }, 0);\n }\n }\n function getPlaceholder(pos, test, returnPL) {\n if ((test = test || getTest(pos).match).placeholder !== undefined || !0 === returnPL) return $.isFunction(test.placeholder) ? test.placeholder(opts) : test.placeholder;\n if (null === test.fn) {\n if (pos > -1 && getMaskSet().validPositions[pos] === undefined) {\n var prevTest, tests = getTests(pos), staticAlternations = [];\n if (tests.length > 1 + (\"\" === tests[tests.length - 1].match.def ? 1 : 0)) for (var i = 0; i < tests.length; i++) if (!0 !== tests[i].match.optionality && !0 !== tests[i].match.optionalQuantifier && (null === tests[i].match.fn || prevTest === undefined || !1 !== tests[i].match.fn.test(prevTest.match.def, getMaskSet(), pos, !0, opts)) && (staticAlternations.push(tests[i]), \n null === tests[i].match.fn && (prevTest = tests[i]), staticAlternations.length > 1 && /[0-9a-bA-Z]/.test(staticAlternations[0].match.def))) return opts.placeholder.charAt(pos % opts.placeholder.length);\n }\n return test.def;\n }\n return opts.placeholder.charAt(pos % opts.placeholder.length);\n }\n var valueBuffer, EventRuler = {\n on: function(input, eventName, eventHandler) {\n var ev = function(e) {\n var that = this;\n if (that.inputmask === undefined && \"FORM\" !== this.nodeName) {\n var imOpts = $.data(that, \"_inputmask_opts\");\n imOpts ? new Inputmask(imOpts).mask(that) : EventRuler.off(that);\n } else {\n if (\"setvalue\" === e.type || \"FORM\" === this.nodeName || !(that.disabled || that.readOnly && !(\"keydown\" === e.type && e.ctrlKey && 67 === e.keyCode || !1 === opts.tabThrough && e.keyCode === Inputmask.keyCode.TAB))) {\n switch (e.type) {\n case \"input\":\n if (!0 === skipInputEvent) return skipInputEvent = !1, e.preventDefault();\n if (mobile) {\n var args = arguments;\n return setTimeout(function() {\n eventHandler.apply(that, args), caret(that, that.inputmask.caretPos, undefined, !0);\n }, 0), !1;\n }\n break;\n\n case \"keydown\":\n skipKeyPressEvent = !1, skipInputEvent = !1;\n break;\n\n case \"keypress\":\n if (!0 === skipKeyPressEvent) return e.preventDefault();\n skipKeyPressEvent = !0;\n break;\n\n case \"click\":\n if (iemobile || iphone) {\n args = arguments;\n return setTimeout(function() {\n eventHandler.apply(that, args);\n }, 0), !1;\n }\n }\n var returnVal = eventHandler.apply(that, arguments);\n return !1 === returnVal && (e.preventDefault(), e.stopPropagation()), returnVal;\n }\n e.preventDefault();\n }\n };\n input.inputmask.events[eventName] = input.inputmask.events[eventName] || [], input.inputmask.events[eventName].push(ev), \n -1 !== $.inArray(eventName, [ \"submit\", \"reset\" ]) ? null !== input.form && $(input.form).on(eventName, ev) : $(input).on(eventName, ev);\n },\n off: function(input, event) {\n var events;\n input.inputmask && input.inputmask.events && (event ? (events = [])[event] = input.inputmask.events[event] : events = input.inputmask.events, \n $.each(events, function(eventName, evArr) {\n for (;evArr.length > 0; ) {\n var ev = evArr.pop();\n -1 !== $.inArray(eventName, [ \"submit\", \"reset\" ]) ? null !== input.form && $(input.form).off(eventName, ev) : $(input).off(eventName, ev);\n }\n delete input.inputmask.events[eventName];\n }));\n }\n }, EventHandlers = {\n keydownEvent: function(e) {\n var input = this, $input = $(input), k = e.keyCode, pos = caret(input);\n if (k === Inputmask.keyCode.BACKSPACE || k === Inputmask.keyCode.DELETE || iphone && k === Inputmask.keyCode.BACKSPACE_SAFARI || e.ctrlKey && k === Inputmask.keyCode.X && !isInputEventSupported(\"cut\")) e.preventDefault(), \n handleRemove(input, k, pos), writeBuffer(input, getBuffer(!0), getMaskSet().p, e, input.inputmask._valueGet() !== getBuffer().join(\"\")); else if (k === Inputmask.keyCode.END || k === Inputmask.keyCode.PAGE_DOWN) {\n e.preventDefault();\n var caretPos = seekNext(getLastValidPosition());\n opts.insertMode || caretPos !== getMaskSet().maskLength || e.shiftKey || caretPos--, \n caret(input, e.shiftKey ? pos.begin : caretPos, caretPos, !0);\n } else k === Inputmask.keyCode.HOME && !e.shiftKey || k === Inputmask.keyCode.PAGE_UP ? (e.preventDefault(), \n caret(input, 0, e.shiftKey ? pos.begin : 0, !0)) : (opts.undoOnEscape && k === Inputmask.keyCode.ESCAPE || 90 === k && e.ctrlKey) && !0 !== e.altKey ? (checkVal(input, !0, !1, undoValue.split(\"\")), \n $input.trigger(\"click\")) : k !== Inputmask.keyCode.INSERT || e.shiftKey || e.ctrlKey ? !0 === opts.tabThrough && k === Inputmask.keyCode.TAB ? (!0 === e.shiftKey ? (null === getTest(pos.begin).match.fn && (pos.begin = seekNext(pos.begin)), \n pos.end = seekPrevious(pos.begin, !0), pos.begin = seekPrevious(pos.end, !0)) : (pos.begin = seekNext(pos.begin, !0), \n pos.end = seekNext(pos.begin, !0), pos.end < getMaskSet().maskLength && pos.end--), \n pos.begin < getMaskSet().maskLength && (e.preventDefault(), caret(input, pos.begin, pos.end))) : e.shiftKey || !1 === opts.insertMode && (k === Inputmask.keyCode.RIGHT ? setTimeout(function() {\n var caretPos = caret(input);\n caret(input, caretPos.begin);\n }, 0) : k === Inputmask.keyCode.LEFT && setTimeout(function() {\n var caretPos = caret(input);\n caret(input, isRTL ? caretPos.begin + 1 : caretPos.begin - 1);\n }, 0)) : (opts.insertMode = !opts.insertMode, caret(input, opts.insertMode || pos.begin !== getMaskSet().maskLength ? pos.begin : pos.begin - 1));\n opts.onKeyDown.call(this, e, getBuffer(), caret(input).begin, opts), ignorable = -1 !== $.inArray(k, opts.ignorables);\n },\n keypressEvent: function(e, checkval, writeOut, strict, ndx) {\n var input = this, $input = $(input), k = e.which || e.charCode || e.keyCode;\n if (!(!0 === checkval || e.ctrlKey && e.altKey) && (e.ctrlKey || e.metaKey || ignorable)) return k === Inputmask.keyCode.ENTER && undoValue !== getBuffer().join(\"\") && (undoValue = getBuffer().join(\"\"), \n setTimeout(function() {\n $input.trigger(\"change\");\n }, 0)), !0;\n if (k) {\n 46 === k && !1 === e.shiftKey && \"\" !== opts.radixPoint && (k = opts.radixPoint.charCodeAt(0));\n var forwardPosition, pos = checkval ? {\n begin: ndx,\n end: ndx\n } : caret(input), c = String.fromCharCode(k), offset = 0;\n if (opts._radixDance && opts.numericInput) {\n var caretPos = getBuffer().indexOf(opts.radixPoint.charAt(0)) + 1;\n pos.begin <= caretPos && (k === opts.radixPoint.charCodeAt(0) && (offset = 1), pos.begin -= 1, \n pos.end -= 1);\n }\n getMaskSet().writeOutBuffer = !0;\n var valResult = isValid(pos, c, strict);\n if (!1 !== valResult && (resetMaskSet(!0), forwardPosition = valResult.caret !== undefined ? valResult.caret : seekNext(valResult.pos.begin ? valResult.pos.begin : valResult.pos), \n getMaskSet().p = forwardPosition), forwardPosition = (opts.numericInput && valResult.caret === undefined ? seekPrevious(forwardPosition) : forwardPosition) + offset, \n !1 !== writeOut && (setTimeout(function() {\n opts.onKeyValidation.call(input, k, valResult, opts);\n }, 0), getMaskSet().writeOutBuffer && !1 !== valResult)) {\n var buffer = getBuffer();\n writeBuffer(input, buffer, forwardPosition, e, !0 !== checkval);\n }\n if (e.preventDefault(), checkval) return !1 !== valResult && (valResult.forwardPosition = forwardPosition), \n valResult;\n }\n },\n pasteEvent: function(e) {\n var tempValue, ev = e.originalEvent || e, inputValue = ($(this), this.inputmask._valueGet(!0)), caretPos = caret(this);\n isRTL && (tempValue = caretPos.end, caretPos.end = caretPos.begin, caretPos.begin = tempValue);\n var valueBeforeCaret = inputValue.substr(0, caretPos.begin), valueAfterCaret = inputValue.substr(caretPos.end, inputValue.length);\n if (valueBeforeCaret === (isRTL ? getBufferTemplate().reverse() : getBufferTemplate()).slice(0, caretPos.begin).join(\"\") && (valueBeforeCaret = \"\"), \n valueAfterCaret === (isRTL ? getBufferTemplate().reverse() : getBufferTemplate()).slice(caretPos.end).join(\"\") && (valueAfterCaret = \"\"), \n window.clipboardData && window.clipboardData.getData) inputValue = valueBeforeCaret + window.clipboardData.getData(\"Text\") + valueAfterCaret; else {\n if (!ev.clipboardData || !ev.clipboardData.getData) return !0;\n inputValue = valueBeforeCaret + ev.clipboardData.getData(\"text/plain\") + valueAfterCaret;\n }\n var pasteValue = inputValue;\n if ($.isFunction(opts.onBeforePaste)) {\n if (!1 === (pasteValue = opts.onBeforePaste.call(inputmask, inputValue, opts))) return e.preventDefault();\n pasteValue || (pasteValue = inputValue);\n }\n return checkVal(this, !1, !1, pasteValue.toString().split(\"\")), writeBuffer(this, getBuffer(), seekNext(getLastValidPosition()), e, undoValue !== getBuffer().join(\"\")), \n e.preventDefault();\n },\n inputFallBackEvent: function(e) {\n var input = this, inputValue = input.inputmask._valueGet();\n if (getBuffer().join(\"\") !== inputValue) {\n var caretPos = caret(input);\n if (inputValue = function(input, inputValue, caretPos) {\n if (iemobile) {\n var inputChar = inputValue.replace(getBuffer().join(\"\"), \"\");\n if (1 === inputChar.length) {\n var iv = inputValue.split(\"\");\n iv.splice(caretPos.begin, 0, inputChar), inputValue = iv.join(\"\");\n }\n }\n return inputValue;\n }(0, inputValue = function(input, inputValue, caretPos) {\n return \".\" === inputValue.charAt(caretPos.begin - 1) && \"\" !== opts.radixPoint && ((inputValue = inputValue.split(\"\"))[caretPos.begin - 1] = opts.radixPoint.charAt(0), \n inputValue = inputValue.join(\"\")), inputValue;\n }(0, inputValue, caretPos), caretPos), getBuffer().join(\"\") !== inputValue) {\n var buffer = getBuffer().join(\"\"), offset = !opts.numericInput && inputValue.length > buffer.length ? -1 : 0, frontPart = inputValue.substr(0, caretPos.begin), backPart = inputValue.substr(caretPos.begin), frontBufferPart = buffer.substr(0, caretPos.begin + offset), backBufferPart = buffer.substr(caretPos.begin + offset), selection = caretPos, entries = \"\", isEntry = !1;\n if (frontPart !== frontBufferPart) {\n for (var fpl = (isEntry = frontPart.length >= frontBufferPart.length) ? frontPart.length : frontBufferPart.length, i = 0; frontPart.charAt(i) === frontBufferPart.charAt(i) && i < fpl; i++) ;\n isEntry && (0 === offset && (selection.begin = i), entries += frontPart.slice(i, selection.end));\n }\n if (backPart !== backBufferPart && (backPart.length > backBufferPart.length ? entries += backPart.slice(0, 1) : backPart.length < backBufferPart.length && (selection.end += backBufferPart.length - backPart.length, \n isEntry || \"\" === opts.radixPoint || \"\" !== backPart || frontPart.charAt(selection.begin + offset - 1) !== opts.radixPoint || (selection.begin--, \n entries = opts.radixPoint))), writeBuffer(input, getBuffer(), {\n begin: selection.begin + offset,\n end: selection.end + offset\n }), entries.length > 0) $.each(entries.split(\"\"), function(ndx, entry) {\n var keypress = new $.Event(\"keypress\");\n keypress.which = entry.charCodeAt(0), ignorable = !1, EventHandlers.keypressEvent.call(input, keypress);\n }); else {\n selection.begin === selection.end - 1 && (selection.begin = seekPrevious(selection.begin + 1), \n selection.begin === selection.end - 1 ? caret(input, selection.begin) : caret(input, selection.begin, selection.end));\n var keydown = new $.Event(\"keydown\");\n keydown.keyCode = opts.numericInput ? Inputmask.keyCode.BACKSPACE : Inputmask.keyCode.DELETE, \n EventHandlers.keydownEvent.call(input, keydown), iphone || !1 !== opts.insertMode || caret(input, caret(input).begin - 1);\n }\n e.preventDefault();\n }\n }\n },\n beforeInputEvent: function(e) {\n if (e.cancelable) {\n var input = this;\n switch (e.inputType) {\n case \"insertText\":\n return $.each(e.data.split(\"\"), function(ndx, entry) {\n var keypress = new $.Event(\"keypress\");\n keypress.which = entry.charCodeAt(0), ignorable = !1, EventHandlers.keypressEvent.call(input, keypress);\n }), e.preventDefault();\n\n case \"deleteContentBackward\":\n return (keydown = new $.Event(\"keydown\")).keyCode = Inputmask.keyCode.BACKSPACE, \n EventHandlers.keydownEvent.call(input, keydown), e.preventDefault();\n\n case \"deleteContentForward\":\n var keydown;\n return (keydown = new $.Event(\"keydown\")).keyCode = Inputmask.keyCode.DELETE, EventHandlers.keydownEvent.call(input, keydown), \n e.preventDefault();\n }\n }\n },\n setValueEvent: function(e) {\n this.inputmask.refreshValue = !1;\n var value = (value = e && e.detail ? e.detail[0] : arguments[1]) || this.inputmask._valueGet(!0);\n $.isFunction(opts.onBeforeMask) && (value = opts.onBeforeMask.call(inputmask, value, opts) || value), \n checkVal(this, !0, !1, value = value.split(\"\")), undoValue = getBuffer().join(\"\"), \n (opts.clearMaskOnLostFocus || opts.clearIncomplete) && this.inputmask._valueGet() === getBufferTemplate().join(\"\") && this.inputmask._valueSet(\"\");\n },\n focusEvent: function(e) {\n var nptValue = this.inputmask._valueGet();\n opts.showMaskOnFocus && (!opts.showMaskOnHover || opts.showMaskOnHover && \"\" === nptValue) && (this.inputmask._valueGet() !== getBuffer().join(\"\") ? writeBuffer(this, getBuffer(), seekNext(getLastValidPosition())) : !1 === mouseEnter && caret(this, seekNext(getLastValidPosition()))), \n !0 === opts.positionCaretOnTab && !1 === mouseEnter && EventHandlers.clickEvent.apply(this, [ e, !0 ]), \n undoValue = getBuffer().join(\"\");\n },\n mouseleaveEvent: function(e) {\n if (mouseEnter = !1, opts.clearMaskOnLostFocus && document.activeElement !== this) {\n var buffer = getBuffer().slice(), nptValue = this.inputmask._valueGet();\n nptValue !== this.getAttribute(\"placeholder\") && \"\" !== nptValue && (-1 === getLastValidPosition() && nptValue === getBufferTemplate().join(\"\") ? buffer = [] : clearOptionalTail(buffer), \n writeBuffer(this, buffer));\n }\n },\n clickEvent: function(e, tabbed) {\n var input = this;\n setTimeout(function() {\n if (document.activeElement === input) {\n var selectedCaret = caret(input);\n if (tabbed && (isRTL ? selectedCaret.end = selectedCaret.begin : selectedCaret.begin = selectedCaret.end), \n selectedCaret.begin === selectedCaret.end) switch (opts.positionCaretOnClick) {\n case \"none\":\n break;\n\n case \"select\":\n caret(input, 0, getBuffer().length);\n break;\n\n case \"ignore\":\n caret(input, seekNext(getLastValidPosition()));\n break;\n\n case \"radixFocus\":\n if (function(clickPos) {\n if (\"\" !== opts.radixPoint) {\n var vps = getMaskSet().validPositions;\n if (vps[clickPos] === undefined || vps[clickPos].input === getPlaceholder(clickPos)) {\n if (clickPos < seekNext(-1)) return !0;\n var radixPos = $.inArray(opts.radixPoint, getBuffer());\n if (-1 !== radixPos) {\n for (var vp in vps) if (radixPos < vp && vps[vp].input !== getPlaceholder(vp)) return !1;\n return !0;\n }\n }\n }\n return !1;\n }(selectedCaret.begin)) {\n var radixPos = getBuffer().join(\"\").indexOf(opts.radixPoint);\n caret(input, opts.numericInput ? seekNext(radixPos) : radixPos);\n break;\n }\n\n default:\n var clickPosition = selectedCaret.begin, lvclickPosition = getLastValidPosition(clickPosition, !0), lastPosition = seekNext(lvclickPosition);\n if (clickPosition < lastPosition) caret(input, isMask(clickPosition, !0) || isMask(clickPosition - 1, !0) ? clickPosition : seekNext(clickPosition)); else {\n var lvp = getMaskSet().validPositions[lvclickPosition], tt = getTestTemplate(lastPosition, lvp ? lvp.match.locator : undefined, lvp), placeholder = getPlaceholder(lastPosition, tt.match);\n if (\"\" !== placeholder && getBuffer()[lastPosition] !== placeholder && !0 !== tt.match.optionalQuantifier && !0 !== tt.match.newBlockMarker || !isMask(lastPosition, opts.keepStatic) && tt.match.def === placeholder) {\n var newPos = seekNext(lastPosition);\n (clickPosition >= newPos || clickPosition === lastPosition) && (lastPosition = newPos);\n }\n caret(input, lastPosition);\n }\n }\n }\n }, 0);\n },\n cutEvent: function(e) {\n $(this);\n var pos = caret(this), ev = e.originalEvent || e, clipboardData = window.clipboardData || ev.clipboardData, clipData = isRTL ? getBuffer().slice(pos.end, pos.begin) : getBuffer().slice(pos.begin, pos.end);\n clipboardData.setData(\"text\", isRTL ? clipData.reverse().join(\"\") : clipData.join(\"\")), \n document.execCommand && document.execCommand(\"copy\"), handleRemove(this, Inputmask.keyCode.DELETE, pos), \n writeBuffer(this, getBuffer(), getMaskSet().p, e, undoValue !== getBuffer().join(\"\"));\n },\n blurEvent: function(e) {\n var $input = $(this);\n if (this.inputmask) {\n var nptValue = this.inputmask._valueGet(), buffer = getBuffer().slice();\n \"\" === nptValue && colorMask === undefined || (opts.clearMaskOnLostFocus && (-1 === getLastValidPosition() && nptValue === getBufferTemplate().join(\"\") ? buffer = [] : clearOptionalTail(buffer)), \n !1 === isComplete(buffer) && (setTimeout(function() {\n $input.trigger(\"incomplete\");\n }, 0), opts.clearIncomplete && (resetMaskSet(), buffer = opts.clearMaskOnLostFocus ? [] : getBufferTemplate().slice())), \n writeBuffer(this, buffer, undefined, e)), undoValue !== getBuffer().join(\"\") && (undoValue = buffer.join(\"\"), \n $input.trigger(\"change\"));\n }\n },\n mouseenterEvent: function(e) {\n mouseEnter = !0, document.activeElement !== this && opts.showMaskOnHover && this.inputmask._valueGet() !== getBuffer().join(\"\") && writeBuffer(this, getBuffer());\n },\n submitEvent: function(e) {\n undoValue !== getBuffer().join(\"\") && $el.trigger(\"change\"), opts.clearMaskOnLostFocus && -1 === getLastValidPosition() && el.inputmask._valueGet && el.inputmask._valueGet() === getBufferTemplate().join(\"\") && el.inputmask._valueSet(\"\"), \n opts.clearIncomplete && !1 === isComplete(getBuffer()) && el.inputmask._valueSet(\"\"), \n opts.removeMaskOnSubmit && (el.inputmask._valueSet(el.inputmask.unmaskedvalue(), !0), \n setTimeout(function() {\n writeBuffer(el, getBuffer());\n }, 0));\n },\n resetEvent: function(e) {\n el.inputmask.refreshValue = !0, setTimeout(function() {\n $el.trigger(\"setvalue\");\n }, 0);\n }\n };\n function checkVal(input, writeOut, strict, nptvl, initiatingEvent) {\n var inputmask = this || input.inputmask, inputValue = nptvl.slice(), charCodes = \"\", initialNdx = -1, result = undefined;\n if (resetMaskSet(), strict || !0 === opts.autoUnmask) initialNdx = seekNext(initialNdx); else {\n var staticInput = getBufferTemplate().slice(0, seekNext(-1)).join(\"\"), matches = inputValue.join(\"\").match(new RegExp(\"^\" + Inputmask.escapeRegex(staticInput), \"g\"));\n matches && matches.length > 0 && (inputValue.splice(0, matches.length * staticInput.length), \n initialNdx = seekNext(initialNdx));\n }\n -1 === initialNdx ? (getMaskSet().p = seekNext(initialNdx), initialNdx = 0) : getMaskSet().p = initialNdx, \n inputmask.caretPos = {\n begin: initialNdx\n }, $.each(inputValue, function(ndx, charCode) {\n if (charCode !== undefined) if (getMaskSet().validPositions[ndx] === undefined && inputValue[ndx] === getPlaceholder(ndx) && isMask(ndx, !0) && !1 === isValid(ndx, inputValue[ndx], !0, undefined, undefined, !0)) getMaskSet().p++; else {\n var keypress = new $.Event(\"_checkval\");\n keypress.which = charCode.charCodeAt(0), charCodes += charCode;\n var lvp = getLastValidPosition(undefined, !0);\n !function(ndx, charCodes) {\n return -1 !== getMaskTemplate(!0, 0, !1).slice(ndx, seekNext(ndx)).join(\"\").replace(/'/g, \"\").indexOf(charCodes) && !isMask(ndx) && (getTest(ndx).match.nativeDef === charCodes.charAt(0) || null === getTest(ndx).match.fn && getTest(ndx).match.nativeDef === \"'\" + charCodes.charAt(0) || \" \" === getTest(ndx).match.nativeDef && (getTest(ndx + 1).match.nativeDef === charCodes.charAt(0) || null === getTest(ndx + 1).match.fn && getTest(ndx + 1).match.nativeDef === \"'\" + charCodes.charAt(0)));\n }(initialNdx, charCodes) ? (result = EventHandlers.keypressEvent.call(input, keypress, !0, !1, strict, inputmask.caretPos.begin)) && (initialNdx = inputmask.caretPos.begin + 1, \n charCodes = \"\") : result = EventHandlers.keypressEvent.call(input, keypress, !0, !1, strict, lvp + 1), \n result && (writeBuffer(undefined, getBuffer(), result.forwardPosition, keypress, !1), \n inputmask.caretPos = {\n begin: result.forwardPosition,\n end: result.forwardPosition\n });\n }\n }), writeOut && writeBuffer(input, getBuffer(), result ? result.forwardPosition : undefined, initiatingEvent || new $.Event(\"checkval\"), initiatingEvent && \"input\" === initiatingEvent.type);\n }\n function unmaskedvalue(input) {\n if (input) {\n if (input.inputmask === undefined) return input.value;\n input.inputmask && input.inputmask.refreshValue && EventHandlers.setValueEvent.call(input);\n }\n var umValue = [], vps = getMaskSet().validPositions;\n for (var pndx in vps) vps[pndx].match && null != vps[pndx].match.fn && umValue.push(vps[pndx].input);\n var unmaskedValue = 0 === umValue.length ? \"\" : (isRTL ? umValue.reverse() : umValue).join(\"\");\n if ($.isFunction(opts.onUnMask)) {\n var bufferValue = (isRTL ? getBuffer().slice().reverse() : getBuffer()).join(\"\");\n unmaskedValue = opts.onUnMask.call(inputmask, bufferValue, unmaskedValue, opts);\n }\n return unmaskedValue;\n }\n function translatePosition(pos) {\n return !isRTL || \"number\" != typeof pos || opts.greedy && \"\" === opts.placeholder || !el || (pos = el.inputmask._valueGet().length - pos), \n pos;\n }\n function caret(input, begin, end, notranslate) {\n var range;\n if (begin === undefined) return input.setSelectionRange ? (begin = input.selectionStart, \n end = input.selectionEnd) : window.getSelection ? (range = window.getSelection().getRangeAt(0)).commonAncestorContainer.parentNode !== input && range.commonAncestorContainer !== input || (begin = range.startOffset, \n end = range.endOffset) : document.selection && document.selection.createRange && (end = (begin = 0 - (range = document.selection.createRange()).duplicate().moveStart(\"character\", -input.inputmask._valueGet().length)) + range.text.length), \n {\n begin: notranslate ? begin : translatePosition(begin),\n end: notranslate ? end : translatePosition(end)\n };\n if ($.isArray(begin) && (end = isRTL ? begin[0] : begin[1], begin = isRTL ? begin[1] : begin[0]), \n begin.begin !== undefined && (end = isRTL ? begin.begin : begin.end, begin = isRTL ? begin.end : begin.begin), \n \"number\" == typeof begin) {\n begin = notranslate ? begin : translatePosition(begin), end = \"number\" == typeof (end = notranslate ? end : translatePosition(end)) ? end : begin;\n var scrollCalc = parseInt(((input.ownerDocument.defaultView || window).getComputedStyle ? (input.ownerDocument.defaultView || window).getComputedStyle(input, null) : input.currentStyle).fontSize) * end;\n if (input.scrollLeft = scrollCalc > input.scrollWidth ? scrollCalc : 0, iphone || !1 !== opts.insertMode || begin !== end || end++, \n input.inputmask.caretPos = {\n begin: begin,\n end: end\n }, input.setSelectionRange) input.selectionStart = begin, input.selectionEnd = end; else if (window.getSelection) {\n if (range = document.createRange(), input.firstChild === undefined || null === input.firstChild) {\n var textNode = document.createTextNode(\"\");\n input.appendChild(textNode);\n }\n range.setStart(input.firstChild, begin < input.inputmask._valueGet().length ? begin : input.inputmask._valueGet().length), \n range.setEnd(input.firstChild, end < input.inputmask._valueGet().length ? end : input.inputmask._valueGet().length), \n range.collapse(!0);\n var sel = window.getSelection();\n sel.removeAllRanges(), sel.addRange(range);\n } else input.createTextRange && ((range = input.createTextRange()).collapse(!0), \n range.moveEnd(\"character\", end), range.moveStart(\"character\", begin), range.select());\n renderColorMask(input, {\n begin: begin,\n end: end\n });\n }\n }\n function determineLastRequiredPosition(returnDefinition) {\n var pos, testPos, buffer = getMaskTemplate(!0, getLastValidPosition(), !0, !0), bl = buffer.length, lvp = getLastValidPosition(), positions = {}, lvTest = getMaskSet().validPositions[lvp], ndxIntlzr = lvTest !== undefined ? lvTest.locator.slice() : undefined;\n for (pos = lvp + 1; pos < buffer.length; pos++) ndxIntlzr = (testPos = getTestTemplate(pos, ndxIntlzr, pos - 1)).locator.slice(), \n positions[pos] = $.extend(!0, {}, testPos);\n var lvTestAlt = lvTest && lvTest.alternation !== undefined ? lvTest.locator[lvTest.alternation] : undefined;\n for (pos = bl - 1; pos > lvp && (((testPos = positions[pos]).match.optionality || testPos.match.optionalQuantifier && testPos.match.newBlockMarker || lvTestAlt && (lvTestAlt !== positions[pos].locator[lvTest.alternation] && null != testPos.match.fn || null === testPos.match.fn && testPos.locator[lvTest.alternation] && checkAlternationMatch(testPos.locator[lvTest.alternation].toString().split(\",\"), lvTestAlt.toString().split(\",\")) && \"\" !== getTests(pos)[0].def)) && buffer[pos] === getPlaceholder(pos, testPos.match)); pos--) bl--;\n return returnDefinition ? {\n l: bl,\n def: positions[bl] ? positions[bl].match : undefined\n } : bl;\n }\n function clearOptionalTail(buffer) {\n buffer.length = 0;\n for (var lmnt, template = getMaskTemplate(!0, 0, !0, undefined, !0); (lmnt = template.shift()) !== undefined; ) buffer.push(lmnt);\n return buffer;\n }\n function isComplete(buffer) {\n if ($.isFunction(opts.isComplete)) return opts.isComplete(buffer, opts);\n if (\"*\" === opts.repeat) return undefined;\n var complete = !1, lrp = determineLastRequiredPosition(!0), aml = seekPrevious(lrp.l);\n if (lrp.def === undefined || lrp.def.newBlockMarker || lrp.def.optionality || lrp.def.optionalQuantifier) {\n complete = !0;\n for (var i = 0; i <= aml; i++) {\n var test = getTestTemplate(i).match;\n if (null !== test.fn && getMaskSet().validPositions[i] === undefined && !0 !== test.optionality && !0 !== test.optionalQuantifier || null === test.fn && buffer[i] !== getPlaceholder(i, test)) {\n complete = !1;\n break;\n }\n }\n }\n return complete;\n }\n function handleRemove(input, k, pos, strict, fromIsValid) {\n if ((opts.numericInput || isRTL) && (k === Inputmask.keyCode.BACKSPACE ? k = Inputmask.keyCode.DELETE : k === Inputmask.keyCode.DELETE && (k = Inputmask.keyCode.BACKSPACE), \n isRTL)) {\n var pend = pos.end;\n pos.end = pos.begin, pos.begin = pend;\n }\n if (k === Inputmask.keyCode.BACKSPACE && (pos.end - pos.begin < 1 || !1 === opts.insertMode) ? (pos.begin = seekPrevious(pos.begin), \n getMaskSet().validPositions[pos.begin] !== undefined && getMaskSet().validPositions[pos.begin].input === opts.groupSeparator && pos.begin--, \n !1 === opts.insertMode && pos.end !== getMaskSet().maskLength && pos.end--) : k === Inputmask.keyCode.DELETE && pos.begin === pos.end && (pos.end = isMask(pos.end, !0) && getMaskSet().validPositions[pos.end] && getMaskSet().validPositions[pos.end].input !== opts.radixPoint ? pos.end + 1 : seekNext(pos.end) + 1, \n getMaskSet().validPositions[pos.begin] !== undefined && getMaskSet().validPositions[pos.begin].input === opts.groupSeparator && pos.end++), \n revalidateMask(pos), !0 !== strict && !1 !== opts.keepStatic || null !== opts.regex) {\n var result = alternate(!0);\n if (result) {\n var newPos = result.caret !== undefined ? result.caret : result.pos ? seekNext(result.pos.begin ? result.pos.begin : result.pos) : getLastValidPosition(-1, !0);\n (k !== Inputmask.keyCode.DELETE || pos.begin > newPos) && pos.begin;\n }\n }\n var lvp = getLastValidPosition(pos.begin, !0);\n if (lvp < pos.begin || -1 === pos.begin) getMaskSet().p = seekNext(lvp); else if (!0 !== strict && (getMaskSet().p = pos.begin, \n !0 !== fromIsValid)) for (;getMaskSet().p < lvp && getMaskSet().validPositions[getMaskSet().p] === undefined; ) getMaskSet().p++;\n }\n function initializeColorMask(input) {\n var computedStyle = (input.ownerDocument.defaultView || window).getComputedStyle(input, null);\n var template = document.createElement(\"div\");\n template.style.width = computedStyle.width, template.style.textAlign = computedStyle.textAlign, \n colorMask = document.createElement(\"div\"), input.inputmask.colorMask = colorMask, \n colorMask.className = \"im-colormask\", input.parentNode.insertBefore(colorMask, input), \n input.parentNode.removeChild(input), colorMask.appendChild(input), colorMask.appendChild(template), \n input.style.left = template.offsetLeft + \"px\", $(colorMask).on(\"mouseleave\", function(e) {\n return EventHandlers.mouseleaveEvent.call(input, [ e ]);\n }), $(colorMask).on(\"mouseenter\", function(e) {\n return EventHandlers.mouseenterEvent.call(input, [ e ]);\n }), $(colorMask).on(\"click\", function(e) {\n return caret(input, function(clientx) {\n var caretPos, e = document.createElement(\"span\");\n for (var style in computedStyle) isNaN(style) && -1 !== style.indexOf(\"font\") && (e.style[style] = computedStyle[style]);\n e.style.textTransform = computedStyle.textTransform, e.style.letterSpacing = computedStyle.letterSpacing, \n e.style.position = \"absolute\", e.style.height = \"auto\", e.style.width = \"auto\", \n e.style.visibility = \"hidden\", e.style.whiteSpace = \"nowrap\", document.body.appendChild(e);\n var itl, inputText = input.inputmask._valueGet(), previousWidth = 0;\n for (caretPos = 0, itl = inputText.length; caretPos <= itl; caretPos++) {\n if (e.innerHTML += inputText.charAt(caretPos) || \"_\", e.offsetWidth >= clientx) {\n var offset1 = clientx - previousWidth, offset2 = e.offsetWidth - clientx;\n e.innerHTML = inputText.charAt(caretPos), caretPos = (offset1 -= e.offsetWidth / 3) < offset2 ? caretPos - 1 : caretPos;\n break;\n }\n previousWidth = e.offsetWidth;\n }\n return document.body.removeChild(e), caretPos;\n }(e.clientX)), EventHandlers.clickEvent.call(input, [ e ]);\n }), $(input).on(\"keydown\", function(e) {\n e.shiftKey || !1 === opts.insertMode || setTimeout(function() {\n renderColorMask(input);\n }, 0);\n });\n }\n function renderColorMask(input, caretPos, clear) {\n var test, testPos, ndxIntlzr, maskTemplate = [], isStatic = !1, pos = 0;\n function setEntry(entry) {\n if (entry === undefined && (entry = \"\"), isStatic || null !== test.fn && testPos.input !== undefined) if (isStatic && (null !== test.fn && testPos.input !== undefined || \"\" === test.def)) {\n isStatic = !1;\n var mtl = maskTemplate.length;\n maskTemplate[mtl - 1] = maskTemplate[mtl - 1] + \"\", maskTemplate.push(entry);\n } else maskTemplate.push(entry); else isStatic = !0, maskTemplate.push(\"\" + entry);\n }\n if (colorMask !== undefined) {\n var buffer = getBuffer();\n if (caretPos === undefined ? caretPos = caret(input) : caretPos.begin === undefined && (caretPos = {\n begin: caretPos,\n end: caretPos\n }), !0 !== clear) {\n var lvp = getLastValidPosition();\n do {\n getMaskSet().validPositions[pos] ? (testPos = getMaskSet().validPositions[pos], \n test = testPos.match, ndxIntlzr = testPos.locator.slice(), setEntry(buffer[pos])) : (testPos = getTestTemplate(pos, ndxIntlzr, pos - 1), \n test = testPos.match, ndxIntlzr = testPos.locator.slice(), !1 === opts.jitMasking || pos < lvp || \"number\" == typeof opts.jitMasking && isFinite(opts.jitMasking) && opts.jitMasking > pos ? setEntry(getPlaceholder(pos, test)) : isStatic = !1), \n pos++;\n } while ((maxLength === undefined || pos < maxLength) && (null !== test.fn || \"\" !== test.def) || lvp > pos || isStatic);\n isStatic && setEntry(), document.activeElement === input && (maskTemplate.splice(caretPos.begin, 0, caretPos.begin === caretPos.end || caretPos.end > getMaskSet().maskLength ? '' : ''), \n maskTemplate.splice(caretPos.end + 1, 0, \"\"));\n }\n var template = colorMask.getElementsByTagName(\"div\")[0];\n template.innerHTML = maskTemplate.join(\"\"), input.inputmask.positionColorMask(input, template);\n }\n }\n if (Inputmask.prototype.positionColorMask = function(input, template) {\n input.style.left = template.offsetLeft + \"px\";\n }, actionObj !== undefined) switch (actionObj.action) {\n case \"isComplete\":\n return el = actionObj.el, isComplete(getBuffer());\n\n case \"unmaskedvalue\":\n return el !== undefined && actionObj.value === undefined || (valueBuffer = actionObj.value, \n valueBuffer = ($.isFunction(opts.onBeforeMask) && opts.onBeforeMask.call(inputmask, valueBuffer, opts) || valueBuffer).split(\"\"), \n checkVal.call(this, undefined, !1, !1, valueBuffer), $.isFunction(opts.onBeforeWrite) && opts.onBeforeWrite.call(inputmask, undefined, getBuffer(), 0, opts)), \n unmaskedvalue(el);\n\n case \"mask\":\n !function(elem) {\n EventRuler.off(elem);\n var isSupported = function(input, opts) {\n var elementType = input.getAttribute(\"type\"), isSupported = \"INPUT\" === input.tagName && -1 !== $.inArray(elementType, opts.supportsInputType) || input.isContentEditable || \"TEXTAREA\" === input.tagName;\n if (!isSupported) if (\"INPUT\" === input.tagName) {\n var el = document.createElement(\"input\");\n el.setAttribute(\"type\", elementType), isSupported = \"text\" === el.type, el = null;\n } else isSupported = \"partial\";\n return !1 !== isSupported ? function(npt) {\n var valueGet, valueSet;\n function getter() {\n return this.inputmask ? this.inputmask.opts.autoUnmask ? this.inputmask.unmaskedvalue() : -1 !== getLastValidPosition() || !0 !== opts.nullable ? document.activeElement === this && opts.clearMaskOnLostFocus ? (isRTL ? clearOptionalTail(getBuffer().slice()).reverse() : clearOptionalTail(getBuffer().slice())).join(\"\") : valueGet.call(this) : \"\" : valueGet.call(this);\n }\n function setter(value) {\n valueSet.call(this, value), this.inputmask && $(this).trigger(\"setvalue\", [ value ]);\n }\n if (!npt.inputmask.__valueGet) {\n if (!0 !== opts.noValuePatching) {\n if (Object.getOwnPropertyDescriptor) {\n \"function\" != typeof Object.getPrototypeOf && (Object.getPrototypeOf = \"object\" == typeof \"test\".__proto__ ? function(object) {\n return object.__proto__;\n } : function(object) {\n return object.constructor.prototype;\n });\n var valueProperty = Object.getPrototypeOf ? Object.getOwnPropertyDescriptor(Object.getPrototypeOf(npt), \"value\") : undefined;\n valueProperty && valueProperty.get && valueProperty.set ? (valueGet = valueProperty.get, \n valueSet = valueProperty.set, Object.defineProperty(npt, \"value\", {\n get: getter,\n set: setter,\n configurable: !0\n })) : \"INPUT\" !== npt.tagName && (valueGet = function() {\n return this.textContent;\n }, valueSet = function(value) {\n this.textContent = value;\n }, Object.defineProperty(npt, \"value\", {\n get: getter,\n set: setter,\n configurable: !0\n }));\n } else document.__lookupGetter__ && npt.__lookupGetter__(\"value\") && (valueGet = npt.__lookupGetter__(\"value\"), \n valueSet = npt.__lookupSetter__(\"value\"), npt.__defineGetter__(\"value\", getter), \n npt.__defineSetter__(\"value\", setter));\n npt.inputmask.__valueGet = valueGet, npt.inputmask.__valueSet = valueSet;\n }\n npt.inputmask._valueGet = function(overruleRTL) {\n return isRTL && !0 !== overruleRTL ? valueGet.call(this.el).split(\"\").reverse().join(\"\") : valueGet.call(this.el);\n }, npt.inputmask._valueSet = function(value, overruleRTL) {\n valueSet.call(this.el, null === value || value === undefined ? \"\" : !0 !== overruleRTL && isRTL ? value.split(\"\").reverse().join(\"\") : value);\n }, valueGet === undefined && (valueGet = function() {\n return this.value;\n }, valueSet = function(value) {\n this.value = value;\n }, function(type) {\n if ($.valHooks && ($.valHooks[type] === undefined || !0 !== $.valHooks[type].inputmaskpatch)) {\n var valhookGet = $.valHooks[type] && $.valHooks[type].get ? $.valHooks[type].get : function(elem) {\n return elem.value;\n }, valhookSet = $.valHooks[type] && $.valHooks[type].set ? $.valHooks[type].set : function(elem, value) {\n return elem.value = value, elem;\n };\n $.valHooks[type] = {\n get: function(elem) {\n if (elem.inputmask) {\n if (elem.inputmask.opts.autoUnmask) return elem.inputmask.unmaskedvalue();\n var result = valhookGet(elem);\n return -1 !== getLastValidPosition(undefined, undefined, elem.inputmask.maskset.validPositions) || !0 !== opts.nullable ? result : \"\";\n }\n return valhookGet(elem);\n },\n set: function(elem, value) {\n var result, $elem = $(elem);\n return result = valhookSet(elem, value), elem.inputmask && $elem.trigger(\"setvalue\", [ value ]), \n result;\n },\n inputmaskpatch: !0\n };\n }\n }(npt.type), function(npt) {\n EventRuler.on(npt, \"mouseenter\", function(event) {\n var $input = $(this);\n this.inputmask._valueGet() !== getBuffer().join(\"\") && $input.trigger(\"setvalue\");\n });\n }(npt));\n }\n }(input) : input.inputmask = undefined, isSupported;\n }(elem, opts);\n if (!1 !== isSupported && ($el = $(el = elem), -1 === (maxLength = el !== undefined ? el.maxLength : undefined) && (maxLength = undefined), \n !0 === opts.colorMask && initializeColorMask(el), mobile && (\"inputmode\" in el && (el.inputmode = opts.inputmode, \n el.setAttribute(\"inputmode\", opts.inputmode)), !0 === opts.disablePredictiveText && (\"autocorrect\" in el ? el.autocorrect = !1 : (!0 !== opts.colorMask && initializeColorMask(el), \n el.type = \"password\"))), !0 === isSupported && (EventRuler.on(el, \"submit\", EventHandlers.submitEvent), \n EventRuler.on(el, \"reset\", EventHandlers.resetEvent), EventRuler.on(el, \"blur\", EventHandlers.blurEvent), \n EventRuler.on(el, \"focus\", EventHandlers.focusEvent), !0 !== opts.colorMask && (EventRuler.on(el, \"click\", EventHandlers.clickEvent), \n EventRuler.on(el, \"mouseleave\", EventHandlers.mouseleaveEvent), EventRuler.on(el, \"mouseenter\", EventHandlers.mouseenterEvent)), \n EventRuler.on(el, \"paste\", EventHandlers.pasteEvent), EventRuler.on(el, \"cut\", EventHandlers.cutEvent), \n EventRuler.on(el, \"complete\", opts.oncomplete), EventRuler.on(el, \"incomplete\", opts.onincomplete), \n EventRuler.on(el, \"cleared\", opts.oncleared), mobile || !0 === opts.inputEventOnly ? el.removeAttribute(\"maxLength\") : (EventRuler.on(el, \"keydown\", EventHandlers.keydownEvent), \n EventRuler.on(el, \"keypress\", EventHandlers.keypressEvent)), EventRuler.on(el, \"input\", EventHandlers.inputFallBackEvent), \n EventRuler.on(el, \"beforeinput\", EventHandlers.beforeInputEvent)), EventRuler.on(el, \"setvalue\", EventHandlers.setValueEvent), \n undoValue = getBufferTemplate().join(\"\"), \"\" !== el.inputmask._valueGet(!0) || !1 === opts.clearMaskOnLostFocus || document.activeElement === el)) {\n var initialValue = $.isFunction(opts.onBeforeMask) && opts.onBeforeMask.call(inputmask, el.inputmask._valueGet(!0), opts) || el.inputmask._valueGet(!0);\n \"\" !== initialValue && checkVal(el, !0, !1, initialValue.split(\"\"));\n var buffer = getBuffer().slice();\n undoValue = buffer.join(\"\"), !1 === isComplete(buffer) && opts.clearIncomplete && resetMaskSet(), \n opts.clearMaskOnLostFocus && document.activeElement !== el && (-1 === getLastValidPosition() ? buffer = [] : clearOptionalTail(buffer)), \n (!1 === opts.clearMaskOnLostFocus || opts.showMaskOnFocus && document.activeElement === el || \"\" !== el.inputmask._valueGet(!0)) && writeBuffer(el, buffer), \n document.activeElement === el && caret(el, seekNext(getLastValidPosition()));\n }\n }(el);\n break;\n\n case \"format\":\n return valueBuffer = ($.isFunction(opts.onBeforeMask) && opts.onBeforeMask.call(inputmask, actionObj.value, opts) || actionObj.value).split(\"\"), \n checkVal.call(this, undefined, !0, !1, valueBuffer), actionObj.metadata ? {\n value: isRTL ? getBuffer().slice().reverse().join(\"\") : getBuffer().join(\"\"),\n metadata: maskScope.call(this, {\n action: \"getmetadata\"\n }, maskset, opts)\n } : isRTL ? getBuffer().slice().reverse().join(\"\") : getBuffer().join(\"\");\n\n case \"isValid\":\n actionObj.value ? (valueBuffer = actionObj.value.split(\"\"), checkVal.call(this, undefined, !0, !0, valueBuffer)) : actionObj.value = getBuffer().join(\"\");\n for (var buffer = getBuffer(), rl = determineLastRequiredPosition(), lmib = buffer.length - 1; lmib > rl && !isMask(lmib); lmib--) ;\n return buffer.splice(rl, lmib + 1 - rl), isComplete(buffer) && actionObj.value === getBuffer().join(\"\");\n\n case \"getemptymask\":\n return getBufferTemplate().join(\"\");\n\n case \"remove\":\n if (el && el.inputmask) $.data(el, \"_inputmask_opts\", null), $el = $(el), el.inputmask._valueSet(opts.autoUnmask ? unmaskedvalue(el) : el.inputmask._valueGet(!0)), \n EventRuler.off(el), el.inputmask.colorMask && ((colorMask = el.inputmask.colorMask).removeChild(el), \n colorMask.parentNode.insertBefore(el, colorMask), colorMask.parentNode.removeChild(colorMask)), \n Object.getOwnPropertyDescriptor && Object.getPrototypeOf ? Object.getOwnPropertyDescriptor(Object.getPrototypeOf(el), \"value\") && el.inputmask.__valueGet && Object.defineProperty(el, \"value\", {\n get: el.inputmask.__valueGet,\n set: el.inputmask.__valueSet,\n configurable: !0\n }) : document.__lookupGetter__ && el.__lookupGetter__(\"value\") && el.inputmask.__valueGet && (el.__defineGetter__(\"value\", el.inputmask.__valueGet), \n el.__defineSetter__(\"value\", el.inputmask.__valueSet)), el.inputmask = undefined;\n return el;\n\n case \"getmetadata\":\n if ($.isArray(maskset.metadata)) {\n var maskTarget = getMaskTemplate(!0, 0, !1).join(\"\");\n return $.each(maskset.metadata, function(ndx, mtdt) {\n if (mtdt.mask === maskTarget) return maskTarget = mtdt, !1;\n }), maskTarget;\n }\n return maskset.metadata;\n }\n }\n return Inputmask.prototype = {\n dataAttribute: \"data-inputmask\",\n defaults: {\n placeholder: \"_\",\n optionalmarker: [ \"[\", \"]\" ],\n quantifiermarker: [ \"{\", \"}\" ],\n groupmarker: [ \"(\", \")\" ],\n alternatormarker: \"|\",\n escapeChar: \"\\\\\",\n mask: null,\n regex: null,\n oncomplete: $.noop,\n onincomplete: $.noop,\n oncleared: $.noop,\n repeat: 0,\n greedy: !1,\n autoUnmask: !1,\n removeMaskOnSubmit: !1,\n clearMaskOnLostFocus: !0,\n insertMode: !0,\n clearIncomplete: !1,\n alias: null,\n onKeyDown: $.noop,\n onBeforeMask: null,\n onBeforePaste: function(pastedValue, opts) {\n return $.isFunction(opts.onBeforeMask) ? opts.onBeforeMask.call(this, pastedValue, opts) : pastedValue;\n },\n onBeforeWrite: null,\n onUnMask: null,\n showMaskOnFocus: !0,\n showMaskOnHover: !0,\n onKeyValidation: $.noop,\n skipOptionalPartCharacter: \" \",\n numericInput: !1,\n rightAlign: !1,\n undoOnEscape: !0,\n radixPoint: \"\",\n _radixDance: !1,\n groupSeparator: \"\",\n keepStatic: null,\n positionCaretOnTab: !0,\n tabThrough: !1,\n supportsInputType: [ \"text\", \"tel\", \"password\", \"search\" ],\n 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 ],\n isComplete: null,\n preValidation: null,\n postValidation: null,\n staticDefinitionSymbol: undefined,\n jitMasking: !1,\n nullable: !0,\n inputEventOnly: !1,\n noValuePatching: !1,\n positionCaretOnClick: \"lvp\",\n casing: null,\n inputmode: \"verbatim\",\n colorMask: !1,\n disablePredictiveText: !1,\n importDataAttributes: !0\n },\n definitions: {\n 9: {\n validator: \"[0-91-9]\",\n definitionSymbol: \"*\"\n },\n a: {\n validator: \"[A-Za-zА-яЁёÀ-ÿµ]\",\n definitionSymbol: \"*\"\n },\n \"*\": {\n validator: \"[0-91-9A-Za-zА-яЁёÀ-ÿµ]\"\n }\n },\n aliases: {},\n masksCache: {},\n mask: function(elems) {\n var that = this;\n return \"string\" == typeof elems && (elems = document.getElementById(elems) || document.querySelectorAll(elems)), \n elems = elems.nodeName ? [ elems ] : elems, $.each(elems, function(ndx, el) {\n var scopedOpts = $.extend(!0, {}, that.opts);\n if (function(npt, opts, userOptions, dataAttribute) {\n if (!0 === opts.importDataAttributes) {\n var option, dataoptions, optionData, p, attrOptions = npt.getAttribute(dataAttribute);\n function importOption(option, optionData) {\n null !== (optionData = optionData !== undefined ? optionData : npt.getAttribute(dataAttribute + \"-\" + option)) && (\"string\" == typeof optionData && (0 === option.indexOf(\"on\") ? optionData = window[optionData] : \"false\" === optionData ? optionData = !1 : \"true\" === optionData && (optionData = !0)), \n userOptions[option] = optionData);\n }\n if (attrOptions && \"\" !== attrOptions && (attrOptions = attrOptions.replace(/'/g, '\"'), \n dataoptions = JSON.parse(\"{\" + attrOptions + \"}\")), dataoptions) for (p in optionData = undefined, \n dataoptions) if (\"alias\" === p.toLowerCase()) {\n optionData = dataoptions[p];\n break;\n }\n for (option in importOption(\"alias\", optionData), userOptions.alias && resolveAlias(userOptions.alias, userOptions, opts), \n opts) {\n if (dataoptions) for (p in optionData = undefined, dataoptions) if (p.toLowerCase() === option.toLowerCase()) {\n optionData = dataoptions[p];\n break;\n }\n importOption(option, optionData);\n }\n }\n return $.extend(!0, opts, userOptions), (\"rtl\" === npt.dir || opts.rightAlign) && (npt.style.textAlign = \"right\"), \n (\"rtl\" === npt.dir || opts.numericInput) && (npt.dir = \"ltr\", npt.removeAttribute(\"dir\"), \n opts.isRTL = !0), Object.keys(userOptions).length;\n }(el, scopedOpts, $.extend(!0, {}, that.userOptions), that.dataAttribute)) {\n var maskset = generateMaskSet(scopedOpts, that.noMasksCache);\n maskset !== undefined && (el.inputmask !== undefined && (el.inputmask.opts.autoUnmask = !0, \n el.inputmask.remove()), el.inputmask = new Inputmask(undefined, undefined, !0), \n el.inputmask.opts = scopedOpts, el.inputmask.noMasksCache = that.noMasksCache, el.inputmask.userOptions = $.extend(!0, {}, that.userOptions), \n el.inputmask.isRTL = scopedOpts.isRTL || scopedOpts.numericInput, el.inputmask.el = el, \n el.inputmask.maskset = maskset, $.data(el, \"_inputmask_opts\", scopedOpts), maskScope.call(el.inputmask, {\n action: \"mask\"\n }));\n }\n }), elems && elems[0] && elems[0].inputmask || this;\n },\n option: function(options, noremask) {\n return \"string\" == typeof options ? this.opts[options] : \"object\" == typeof options ? ($.extend(this.userOptions, options), \n this.el && !0 !== noremask && this.mask(this.el), this) : void 0;\n },\n unmaskedvalue: function(value) {\n return this.maskset = this.maskset || generateMaskSet(this.opts, this.noMasksCache), \n maskScope.call(this, {\n action: \"unmaskedvalue\",\n value: value\n });\n },\n remove: function() {\n return maskScope.call(this, {\n action: \"remove\"\n });\n },\n getemptymask: function() {\n return this.maskset = this.maskset || generateMaskSet(this.opts, this.noMasksCache), \n maskScope.call(this, {\n action: \"getemptymask\"\n });\n },\n hasMaskedValue: function() {\n return !this.opts.autoUnmask;\n },\n isComplete: function() {\n return this.maskset = this.maskset || generateMaskSet(this.opts, this.noMasksCache), \n maskScope.call(this, {\n action: \"isComplete\"\n });\n },\n getmetadata: function() {\n return this.maskset = this.maskset || generateMaskSet(this.opts, this.noMasksCache), \n maskScope.call(this, {\n action: \"getmetadata\"\n });\n },\n isValid: function(value) {\n return this.maskset = this.maskset || generateMaskSet(this.opts, this.noMasksCache), \n maskScope.call(this, {\n action: \"isValid\",\n value: value\n });\n },\n format: function(value, metadata) {\n return this.maskset = this.maskset || generateMaskSet(this.opts, this.noMasksCache), \n maskScope.call(this, {\n action: \"format\",\n value: value,\n metadata: metadata\n });\n },\n setValue: function(value) {\n this.el && $(this.el).trigger(\"setvalue\", [ value ]);\n },\n analyseMask: function(mask, regexMask, opts) {\n var match, m, openingToken, currentOpeningToken, alternator, lastMatch, tokenizer = /(?:[?*+]|\\{[0-9\\+\\*]+(?:,[0-9\\+\\*]*)?(?:\\|[0-9\\+\\*]*)?\\})|[^.?*+^${[]()|\\\\]+|./g, regexTokenizer = /\\[\\^?]?(?:[^\\\\\\]]+|\\\\[\\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, escaped = !1, currentToken = new MaskToken(), openenings = [], maskTokens = [];\n function MaskToken(isGroup, isOptional, isQuantifier, isAlternator) {\n this.matches = [], this.openGroup = isGroup || !1, this.alternatorGroup = !1, this.isGroup = isGroup || !1, \n this.isOptional = isOptional || !1, this.isQuantifier = isQuantifier || !1, this.isAlternator = isAlternator || !1, \n this.quantifier = {\n min: 1,\n max: 1\n };\n }\n function insertTestDefinition(mtoken, element, position) {\n position = position !== undefined ? position : mtoken.matches.length;\n var prevMatch = mtoken.matches[position - 1];\n if (regexMask) 0 === element.indexOf(\"[\") || escaped && /\\\\d|\\\\s|\\\\w]/i.test(element) || \".\" === element ? mtoken.matches.splice(position++, 0, {\n fn: new RegExp(element, opts.casing ? \"i\" : \"\"),\n optionality: !1,\n newBlockMarker: prevMatch === undefined ? \"master\" : prevMatch.def !== element,\n casing: null,\n def: element,\n placeholder: undefined,\n nativeDef: element\n }) : (escaped && (element = element[element.length - 1]), $.each(element.split(\"\"), function(ndx, lmnt) {\n prevMatch = mtoken.matches[position - 1], mtoken.matches.splice(position++, 0, {\n fn: null,\n optionality: !1,\n newBlockMarker: prevMatch === undefined ? \"master\" : prevMatch.def !== lmnt && null !== prevMatch.fn,\n casing: null,\n def: opts.staticDefinitionSymbol || lmnt,\n placeholder: opts.staticDefinitionSymbol !== undefined ? lmnt : undefined,\n nativeDef: (escaped ? \"'\" : \"\") + lmnt\n });\n })), escaped = !1; else {\n var maskdef = (opts.definitions ? opts.definitions[element] : undefined) || Inputmask.prototype.definitions[element];\n maskdef && !escaped ? mtoken.matches.splice(position++, 0, {\n fn: maskdef.validator ? \"string\" == typeof maskdef.validator ? new RegExp(maskdef.validator, opts.casing ? \"i\" : \"\") : new function() {\n this.test = maskdef.validator;\n }() : new RegExp(\".\"),\n optionality: !1,\n newBlockMarker: prevMatch === undefined ? \"master\" : prevMatch.def !== (maskdef.definitionSymbol || element),\n casing: maskdef.casing,\n def: maskdef.definitionSymbol || element,\n placeholder: maskdef.placeholder,\n nativeDef: element\n }) : (mtoken.matches.splice(position++, 0, {\n fn: null,\n optionality: !1,\n newBlockMarker: prevMatch === undefined ? \"master\" : prevMatch.def !== element && null !== prevMatch.fn,\n casing: null,\n def: opts.staticDefinitionSymbol || element,\n placeholder: opts.staticDefinitionSymbol !== undefined ? element : undefined,\n nativeDef: (escaped ? \"'\" : \"\") + element\n }), escaped = !1);\n }\n }\n function defaultCase() {\n if (openenings.length > 0) {\n if (insertTestDefinition(currentOpeningToken = openenings[openenings.length - 1], m), \n currentOpeningToken.isAlternator) {\n alternator = openenings.pop();\n for (var mndx = 0; mndx < alternator.matches.length; mndx++) alternator.matches[mndx].isGroup && (alternator.matches[mndx].isGroup = !1);\n openenings.length > 0 ? (currentOpeningToken = openenings[openenings.length - 1]).matches.push(alternator) : currentToken.matches.push(alternator);\n }\n } else insertTestDefinition(currentToken, m);\n }\n function groupify(matches) {\n var groupToken = new MaskToken(!0);\n return groupToken.openGroup = !1, groupToken.matches = matches, groupToken;\n }\n for (regexMask && (opts.optionalmarker[0] = undefined, opts.optionalmarker[1] = undefined); match = regexMask ? regexTokenizer.exec(mask) : tokenizer.exec(mask); ) {\n if (m = match[0], regexMask) switch (m.charAt(0)) {\n case \"?\":\n m = \"{0,1}\";\n break;\n\n case \"+\":\n case \"*\":\n m = \"{\" + m + \"}\";\n }\n if (escaped) defaultCase(); else switch (m.charAt(0)) {\n case \"(?=\":\n case \"(?!\":\n case \"(?<=\":\n case \"(? 0) {\n if ((currentOpeningToken = openenings[openenings.length - 1]).matches.push(openingToken), \n currentOpeningToken.isAlternator) {\n alternator = openenings.pop();\n for (var mndx = 0; mndx < alternator.matches.length; mndx++) alternator.matches[mndx].isGroup = !1, \n alternator.matches[mndx].alternatorGroup = !1;\n openenings.length > 0 ? (currentOpeningToken = openenings[openenings.length - 1]).matches.push(alternator) : currentToken.matches.push(alternator);\n }\n } else currentToken.matches.push(openingToken); else defaultCase();\n break;\n\n case opts.optionalmarker[0]:\n openenings.push(new MaskToken(!1, !0));\n break;\n\n case opts.groupmarker[0]:\n openenings.push(new MaskToken(!0));\n break;\n\n case opts.quantifiermarker[0]:\n var quantifier = new MaskToken(!1, !1, !0), mqj = (m = m.replace(/[{}]/g, \"\")).split(\"|\"), mq = mqj[0].split(\",\"), mq0 = isNaN(mq[0]) ? mq[0] : parseInt(mq[0]), mq1 = 1 === mq.length ? mq0 : isNaN(mq[1]) ? mq[1] : parseInt(mq[1]);\n \"*\" !== mq0 && \"+\" !== mq0 || (mq0 = \"*\" === mq1 ? 0 : 1), quantifier.quantifier = {\n min: mq0,\n max: mq1,\n jit: mqj[1]\n };\n var matches = openenings.length > 0 ? openenings[openenings.length - 1].matches : currentToken.matches;\n if ((match = matches.pop()).isAlternator) {\n matches.push(match), matches = match.matches;\n var groupToken = new MaskToken(!0), tmpMatch = matches.pop();\n matches.push(groupToken), matches = groupToken.matches, match = tmpMatch;\n }\n match.isGroup || (match = groupify([ match ])), matches.push(match), matches.push(quantifier);\n break;\n\n case opts.alternatormarker:\n function groupQuantifier(matches) {\n var lastMatch = matches.pop();\n return lastMatch.isQuantifier && (lastMatch = groupify([ matches.pop(), lastMatch ])), \n lastMatch;\n }\n if (openenings.length > 0) {\n var subToken = (currentOpeningToken = openenings[openenings.length - 1]).matches[currentOpeningToken.matches.length - 1];\n lastMatch = currentOpeningToken.openGroup && (subToken.matches === undefined || !1 === subToken.isGroup && !1 === subToken.isAlternator) ? openenings.pop() : groupQuantifier(currentOpeningToken.matches);\n } else lastMatch = groupQuantifier(currentToken.matches);\n if (lastMatch.isAlternator) openenings.push(lastMatch); else if (lastMatch.alternatorGroup ? (alternator = openenings.pop(), \n lastMatch.alternatorGroup = !1) : alternator = new MaskToken(!1, !1, !1, !0), alternator.matches.push(lastMatch), \n openenings.push(alternator), lastMatch.openGroup) {\n lastMatch.openGroup = !1;\n var alternatorGroup = new MaskToken(!0);\n alternatorGroup.alternatorGroup = !0, openenings.push(alternatorGroup);\n }\n break;\n\n default:\n defaultCase();\n }\n }\n for (;openenings.length > 0; ) openingToken = openenings.pop(), currentToken.matches.push(openingToken);\n return currentToken.matches.length > 0 && (!function verifyGroupMarker(maskToken) {\n maskToken && maskToken.matches && $.each(maskToken.matches, function(ndx, token) {\n var nextToken = maskToken.matches[ndx + 1];\n (nextToken === undefined || nextToken.matches === undefined || !1 === nextToken.isQuantifier) && token && token.isGroup && (token.isGroup = !1, \n regexMask || (insertTestDefinition(token, opts.groupmarker[0], 0), !0 !== token.openGroup && insertTestDefinition(token, opts.groupmarker[1]))), \n verifyGroupMarker(token);\n });\n }(currentToken), maskTokens.push(currentToken)), (opts.numericInput || opts.isRTL) && function reverseTokens(maskToken) {\n for (var match in maskToken.matches = maskToken.matches.reverse(), maskToken.matches) if (maskToken.matches.hasOwnProperty(match)) {\n var intMatch = parseInt(match);\n if (maskToken.matches[match].isQuantifier && maskToken.matches[intMatch + 1] && maskToken.matches[intMatch + 1].isGroup) {\n var qt = maskToken.matches[match];\n maskToken.matches.splice(match, 1), maskToken.matches.splice(intMatch + 1, 0, qt);\n }\n maskToken.matches[match].matches !== undefined ? maskToken.matches[match] = reverseTokens(maskToken.matches[match]) : maskToken.matches[match] = ((st = maskToken.matches[match]) === opts.optionalmarker[0] ? st = opts.optionalmarker[1] : st === opts.optionalmarker[1] ? st = opts.optionalmarker[0] : st === opts.groupmarker[0] ? st = opts.groupmarker[1] : st === opts.groupmarker[1] && (st = opts.groupmarker[0]), \n st);\n }\n var st;\n return maskToken;\n }(maskTokens[0]), maskTokens;\n }\n }, Inputmask.extendDefaults = function(options) {\n $.extend(!0, Inputmask.prototype.defaults, options);\n }, Inputmask.extendDefinitions = function(definition) {\n $.extend(!0, Inputmask.prototype.definitions, definition);\n }, Inputmask.extendAliases = function(alias) {\n $.extend(!0, Inputmask.prototype.aliases, alias);\n }, Inputmask.format = function(value, options, metadata) {\n return Inputmask(options).format(value, metadata);\n }, Inputmask.unmask = function(value, options) {\n return Inputmask(options).unmaskedvalue(value);\n }, Inputmask.isValid = function(value, options) {\n return Inputmask(options).isValid(value);\n }, Inputmask.remove = function(elems) {\n \"string\" == typeof elems && (elems = document.getElementById(elems) || document.querySelectorAll(elems)), \n elems = elems.nodeName ? [ elems ] : elems, $.each(elems, function(ndx, el) {\n el.inputmask && el.inputmask.remove();\n });\n }, Inputmask.setValue = function(elems, value) {\n \"string\" == typeof elems && (elems = document.getElementById(elems) || document.querySelectorAll(elems)), \n elems = elems.nodeName ? [ elems ] : elems, $.each(elems, function(ndx, el) {\n el.inputmask ? el.inputmask.setValue(value) : $(el).trigger(\"setvalue\", [ value ]);\n });\n }, Inputmask.escapeRegex = function(str) {\n return str.replace(new RegExp(\"(\\\\\" + [ \"/\", \".\", \"*\", \"+\", \"?\", \"|\", \"(\", \")\", \"[\", \"]\", \"{\", \"}\", \"\\\\\", \"$\", \"^\" ].join(\"|\\\\\") + \")\", \"gim\"), \"\\\\$1\");\n }, Inputmask.keyCode = {\n BACKSPACE: 8,\n BACKSPACE_SAFARI: 127,\n DELETE: 46,\n DOWN: 40,\n END: 35,\n ENTER: 13,\n ESCAPE: 27,\n HOME: 36,\n INSERT: 45,\n LEFT: 37,\n PAGE_DOWN: 34,\n PAGE_UP: 33,\n RIGHT: 39,\n SPACE: 32,\n TAB: 9,\n UP: 38,\n X: 88,\n CONTROL: 17\n }, Inputmask;\n});","/*!\n* dependencyLibs/inputmask.dependencyLib.js\n* https://github.com/RobinHerbots/Inputmask\n* Copyright (c) 2010 - 2018 Robin Herbots\n* Licensed under the MIT license (http://www.opensource.org/licenses/mit-license.php)\n* Version: 4.0.0\n*/\n\n!function(factory) {\n \"function\" == typeof define && define.amd ? define([ \"../global/window\", \"../global/document\" ], factory) : \"object\" == typeof exports ? module.exports = factory(require(\"../global/window\"), require(\"../global/document\")) : window.dependencyLib = factory(window, document);\n}(function(window, document) {\n function isWindow(obj) {\n return null != obj && obj === obj.window;\n }\n function isValidElement(elem) {\n return elem instanceof Element;\n }\n function DependencyLib(elem) {\n return elem instanceof DependencyLib ? elem : this instanceof DependencyLib ? void (void 0 !== elem && null !== elem && elem !== window && (this[0] = elem.nodeName ? elem : void 0 !== elem[0] && elem[0].nodeName ? elem[0] : document.querySelector(elem), \n void 0 !== this[0] && null !== this[0] && (this[0].eventRegistry = this[0].eventRegistry || {}))) : new DependencyLib(elem);\n }\n return DependencyLib.prototype = {\n on: function(events, handler) {\n if (isValidElement(this[0])) {\n var eventRegistry = this[0].eventRegistry, elem = this[0];\n function addEvent(ev, namespace) {\n elem.addEventListener ? elem.addEventListener(ev, handler, !1) : elem.attachEvent && elem.attachEvent(\"on\" + ev, handler), \n eventRegistry[ev] = eventRegistry[ev] || {}, eventRegistry[ev][namespace] = eventRegistry[ev][namespace] || [], \n eventRegistry[ev][namespace].push(handler);\n }\n for (var _events = events.split(\" \"), endx = 0; endx < _events.length; endx++) {\n var nsEvent = _events[endx].split(\".\");\n addEvent(nsEvent[0], nsEvent[1] || \"global\");\n }\n }\n return this;\n },\n off: function(events, handler) {\n if (isValidElement(this[0])) {\n var eventRegistry = this[0].eventRegistry, elem = this[0];\n function removeEvent(ev, namespace, handler) {\n if (ev in eventRegistry == !0) if (elem.removeEventListener ? elem.removeEventListener(ev, handler, !1) : elem.detachEvent && elem.detachEvent(\"on\" + ev, handler), \n \"global\" === namespace) for (var nmsp in eventRegistry[ev]) eventRegistry[ev][nmsp].splice(eventRegistry[ev][nmsp].indexOf(handler), 1); else eventRegistry[ev][namespace].splice(eventRegistry[ev][namespace].indexOf(handler), 1);\n }\n function resolveNamespace(ev, namespace) {\n var hndx, hndL, evts = [];\n if (ev.length > 0) if (void 0 === handler) for (hndx = 0, hndL = eventRegistry[ev][namespace].length; hndx < hndL; hndx++) evts.push({\n ev: ev,\n namespace: namespace && namespace.length > 0 ? namespace : \"global\",\n handler: eventRegistry[ev][namespace][hndx]\n }); else evts.push({\n ev: ev,\n namespace: namespace && namespace.length > 0 ? namespace : \"global\",\n handler: handler\n }); else if (namespace.length > 0) for (var evNdx in eventRegistry) for (var nmsp in eventRegistry[evNdx]) if (nmsp === namespace) if (void 0 === handler) for (hndx = 0, \n hndL = eventRegistry[evNdx][nmsp].length; hndx < hndL; hndx++) evts.push({\n ev: evNdx,\n namespace: nmsp,\n handler: eventRegistry[evNdx][nmsp][hndx]\n }); else evts.push({\n ev: evNdx,\n namespace: nmsp,\n handler: handler\n });\n return evts;\n }\n for (var _events = events.split(\" \"), endx = 0; endx < _events.length; endx++) for (var nsEvent = _events[endx].split(\".\"), offEvents = resolveNamespace(nsEvent[0], nsEvent[1]), i = 0, offEventsL = offEvents.length; i < offEventsL; i++) removeEvent(offEvents[i].ev, offEvents[i].namespace, offEvents[i].handler);\n }\n return this;\n },\n trigger: function(events) {\n if (isValidElement(this[0])) for (var eventRegistry = this[0].eventRegistry, elem = this[0], _events = \"string\" == typeof events ? events.split(\" \") : [ events.type ], endx = 0; endx < _events.length; endx++) {\n var nsEvent = _events[endx].split(\".\"), ev = nsEvent[0], namespace = nsEvent[1] || \"global\";\n if (void 0 !== document && \"global\" === namespace) {\n var evnt, i, params = {\n bubbles: !0,\n cancelable: !0,\n detail: arguments[1]\n };\n if (document.createEvent) {\n try {\n evnt = new CustomEvent(ev, params);\n } catch (e) {\n (evnt = document.createEvent(\"CustomEvent\")).initCustomEvent(ev, params.bubbles, params.cancelable, params.detail);\n }\n events.type && DependencyLib.extend(evnt, events), elem.dispatchEvent(evnt);\n } else (evnt = document.createEventObject()).eventType = ev, evnt.detail = arguments[1], \n events.type && DependencyLib.extend(evnt, events), elem.fireEvent(\"on\" + evnt.eventType, evnt);\n } else if (void 0 !== eventRegistry[ev]) if (arguments[0] = arguments[0].type ? arguments[0] : DependencyLib.Event(arguments[0]), \n \"global\" === namespace) for (var nmsp in eventRegistry[ev]) for (i = 0; i < eventRegistry[ev][nmsp].length; i++) eventRegistry[ev][nmsp][i].apply(elem, arguments); else for (i = 0; i < eventRegistry[ev][namespace].length; i++) eventRegistry[ev][namespace][i].apply(elem, arguments);\n }\n return this;\n }\n }, DependencyLib.isFunction = function(obj) {\n return \"function\" == typeof obj;\n }, DependencyLib.noop = function() {}, DependencyLib.isArray = Array.isArray, DependencyLib.inArray = function(elem, arr, i) {\n return null == arr ? -1 : function(list, elem) {\n for (var i = 0, len = list.length; i < len; i++) if (list[i] === elem) return i;\n return -1;\n }(arr, elem);\n }, DependencyLib.valHooks = void 0, DependencyLib.isPlainObject = function(obj) {\n return \"object\" == typeof obj && !obj.nodeType && !isWindow(obj) && !(obj.constructor && !Object.hasOwnProperty.call(obj.constructor.prototype, \"isPrototypeOf\"));\n }, DependencyLib.extend = function() {\n var options, name, src, copy, copyIsArray, clone, target = arguments[0] || {}, i = 1, length = arguments.length, deep = !1;\n for (\"boolean\" == typeof target && (deep = target, target = arguments[i] || {}, \n i++), \"object\" == typeof target || DependencyLib.isFunction(target) || (target = {}), \n i === length && (target = this, i--); i < length; i++) if (null != (options = arguments[i])) for (name in options) src = target[name], \n target !== (copy = options[name]) && (deep && copy && (DependencyLib.isPlainObject(copy) || (copyIsArray = DependencyLib.isArray(copy))) ? (copyIsArray ? (copyIsArray = !1, \n clone = src && DependencyLib.isArray(src) ? src : []) : clone = src && DependencyLib.isPlainObject(src) ? src : {}, \n target[name] = DependencyLib.extend(deep, clone, copy)) : void 0 !== copy && (target[name] = copy));\n return target;\n }, DependencyLib.each = function(obj, callback) {\n var i = 0;\n if (function(obj) {\n var length = \"length\" in obj && obj.length, ltype = typeof obj;\n return \"function\" !== ltype && !isWindow(obj) && (!(1 !== obj.nodeType || !length) || \"array\" === ltype || 0 === length || \"number\" == typeof length && length > 0 && length - 1 in obj);\n }(obj)) for (var length = obj.length; i < length && !1 !== callback.call(obj[i], i, obj[i]); i++) ; else for (i in obj) if (!1 === callback.call(obj[i], i, obj[i])) break;\n return obj;\n }, DependencyLib.data = function(owner, key, value) {\n if (void 0 === value) return owner.__data ? owner.__data[key] : null;\n owner.__data = owner.__data || {}, owner.__data[key] = value;\n }, \"function\" == typeof window.CustomEvent ? DependencyLib.Event = window.CustomEvent : (DependencyLib.Event = function(event, params) {\n params = params || {\n bubbles: !1,\n cancelable: !1,\n detail: void 0\n };\n var evt = document.createEvent(\"CustomEvent\");\n return evt.initCustomEvent(event, params.bubbles, params.cancelable, params.detail), \n evt;\n }, DependencyLib.Event.prototype = window.Event.prototype), DependencyLib;\n});","/*\n * jQuery Form Styler v2.0.2\n * https://github.com/Dimox/jQueryFormStyler\n *\n * Copyright 2012-2017 Dimox (http://dimox.name/)\n * Released under the MIT license.\n *\n * Date: 2017.10.22\n *\n */\n\n;(function(factory) {\n\tif (typeof define === 'function' && define.amd) {\n\t\t// AMD\n\t\tdefine(['jquery'], factory);\n\t} else if (typeof exports === 'object') {\n\t\t// CommonJS\n\t\tmodule.exports = factory($ || require('jquery'));\n\t} else {\n\t\tfactory(jQuery);\n\t}\n}(function($) {\n\n\t'use strict';\n\n\tvar pluginName = 'styler',\n\t\t\tdefaults = {\n\t\t\t\tidSuffix: '-styler',\n\t\t\t\tfilePlaceholder: 'Файл не выбран',\n\t\t\t\tfileBrowse: 'Обзор...',\n\t\t\t\tfileNumber: 'Выбрано файлов: %s',\n\t\t\t\tselectPlaceholder: 'Выберите...',\n\t\t\t\tselectSearch: false,\n\t\t\t\tselectSearchLimit: 10,\n\t\t\t\tselectSearchNotFound: 'Совпадений не найдено',\n\t\t\t\tselectSearchPlaceholder: 'Поиск...',\n\t\t\t\tselectVisibleOptions: 0,\n\t\t\t\tselectSmartPositioning: true,\n\t\t\t\tlocale: 'ru',\n\t\t\t\tlocales: {\n\t\t\t\t\t'en': {\n\t\t\t\t\t\tfilePlaceholder: 'No file selected',\n\t\t\t\t\t\tfileBrowse: 'Browse...',\n\t\t\t\t\t\tfileNumber: 'Selected files: %s',\n\t\t\t\t\t\tselectPlaceholder: 'Select...',\n\t\t\t\t\t\tselectSearchNotFound: 'No matches found',\n\t\t\t\t\t\tselectSearchPlaceholder: 'Search...'\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t\tonSelectOpened: function() {},\n\t\t\t\tonSelectClosed: function() {},\n\t\t\t\tonFormStyled: function() {}\n\t\t\t};\n\n\tfunction Plugin(element, options) {\n\t\tthis.element = element;\n\t\tthis.options = $.extend({}, defaults, options);\n\t\tvar locale = this.options.locale;\n\t\tif (this.options.locales[locale] !== undefined) {\n\t\t\t$.extend(this.options, this.options.locales[locale]);\n\t\t}\n\t\tthis.init();\n\t}\n\n\tPlugin.prototype = {\n\n\t\t// инициализация\n\t\tinit: function() {\n\n\t\t\tvar el = $(this.element);\n\t\t\tvar opt = this.options;\n\n\t\t\tvar iOS = (navigator.userAgent.match(/(iPad|iPhone|iPod)/i) && !navigator.userAgent.match(/(Windows\\sPhone)/i)) ? true : false;\n\t\t\tvar Android = (navigator.userAgent.match(/Android/i) && !navigator.userAgent.match(/(Windows\\sPhone)/i)) ? true : false;\n\n\t\t\tfunction Attributes() {\n\t\t\t\tif (el.attr('id') !== undefined && el.attr('id') !== '') {\n\t\t\t\t\tthis.id = el.attr('id') + opt.idSuffix;\n\t\t\t\t}\n\t\t\t\tthis.title = el.attr('title');\n\t\t\t\tthis.classes = el.attr('class');\n\t\t\t\tthis.data = el.data();\n\t\t\t}\n\n\t\t\t// checkbox\n\t\t\tif (el.is(':checkbox')) {\n\n\t\t\t\tvar checkboxOutput = function() {\n\n\t\t\t\t\tvar att = new Attributes();\n\t\t\t\t\tvar checkbox = $('
')\n\t\t\t\t\t\t.attr({\n\t\t\t\t\t\t\tid: att.id,\n\t\t\t\t\t\t\ttitle: att.title\n\t\t\t\t\t\t})\n\t\t\t\t\t\t.addClass(att.classes)\n\t\t\t\t\t\t.data(att.data)\n\t\t\t\t\t;\n\n\t\t\t\t\tel.after(checkbox).prependTo(checkbox);\n\t\t\t\t\tif (el.is(':checked')) checkbox.addClass('checked');\n\t\t\t\t\tif (el.is(':disabled')) checkbox.addClass('disabled');\n\n\t\t\t\t\t// клик на псевдочекбокс\n\t\t\t\t\tcheckbox.click(function(e) {\n\t\t\t\t\t\te.preventDefault();\n\t\t\t\t\t\tel.triggerHandler('click');\n\t\t\t\t\t\tif (!checkbox.is('.disabled')) {\n\t\t\t\t\t\t\tif (el.is(':checked')) {\n\t\t\t\t\t\t\t\tel.prop('checked', false);\n\t\t\t\t\t\t\t\tcheckbox.removeClass('checked');\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\tel.prop('checked', true);\n\t\t\t\t\t\t\t\tcheckbox.addClass('checked');\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tel.focus().change();\n\t\t\t\t\t\t}\n\t\t\t\t\t});\n\t\t\t\t\t// клик на label\n\t\t\t\t\tel.closest('label').add('label[for=\"' + el.attr('id') + '\"]').on('click.styler', function(e) {\n\t\t\t\t\t\tif (!$(e.target).is('a') && !$(e.target).closest(checkbox).length) {\n\t\t\t\t\t\t\tcheckbox.triggerHandler('click');\n\t\t\t\t\t\t\te.preventDefault();\n\t\t\t\t\t\t}\n\t\t\t\t\t});\n\t\t\t\t\t// переключение по Space или Enter\n\t\t\t\t\tel.on('change.styler', function() {\n\t\t\t\t\t\tif (el.is(':checked')) checkbox.addClass('checked');\n\t\t\t\t\t\telse checkbox.removeClass('checked');\n\t\t\t\t\t})\n\t\t\t\t\t// чтобы переключался чекбокс, который находится в теге label\n\t\t\t\t\t.on('keydown.styler', function(e) {\n\t\t\t\t\t\tif (e.which == 32) checkbox.click();\n\t\t\t\t\t})\n\t\t\t\t\t.on('focus.styler', function() {\n\t\t\t\t\t\tif (!checkbox.is('.disabled')) checkbox.addClass('focused');\n\t\t\t\t\t})\n\t\t\t\t\t.on('blur.styler', function() {\n\t\t\t\t\t\tcheckbox.removeClass('focused');\n\t\t\t\t\t});\n\n\t\t\t\t}; // end checkboxOutput()\n\n\t\t\t\tcheckboxOutput();\n\n\t\t\t\t// обновление при динамическом изменении\n\t\t\t\tel.on('refresh', function() {\n\t\t\t\t\tel.closest('label').add('label[for=\"' + el.attr('id') + '\"]').off('.styler');\n\t\t\t\t\tel.off('.styler').parent().before(el).remove();\n\t\t\t\t\tcheckboxOutput();\n\t\t\t\t});\n\n\t\t\t// end checkbox\n\n\t\t\t// radio\n\t\t\t} else if (el.is(':radio')) {\n\n\t\t\t\tvar radioOutput = function() {\n\n\t\t\t\t\tvar att = new Attributes();\n\t\t\t\t\tvar radio = $('
')\n\t\t\t\t\t\t.attr({\n\t\t\t\t\t\t\tid: att.id,\n\t\t\t\t\t\t\ttitle: att.title\n\t\t\t\t\t\t})\n\t\t\t\t\t\t.addClass(att.classes)\n\t\t\t\t\t\t.data(att.data)\n\t\t\t\t\t;\n\n\t\t\t\t\tel.after(radio).prependTo(radio);\n\t\t\t\t\tif (el.is(':checked')) radio.addClass('checked');\n\t\t\t\t\tif (el.is(':disabled')) radio.addClass('disabled');\n\n\t\t\t\t\t// определяем общего родителя у радиокнопок с одинаковым name\n\t\t\t\t\t// http://stackoverflow.com/a/27733847\n\t\t\t\t\t$.fn.commonParents = function() {\n\t\t\t\t\t\tvar cachedThis = this;\n\t\t\t\t\t\treturn cachedThis.first().parents().filter(function() {\n\t\t\t\t\t\t\treturn $(this).find(cachedThis).length === cachedThis.length;\n\t\t\t\t\t\t});\n\t\t\t\t\t};\n\t\t\t\t\t$.fn.commonParent = function() {\n\t\t\t\t\t\treturn $(this).commonParents().first();\n\t\t\t\t\t};\n\n\t\t\t\t\t// клик на псевдорадиокнопке\n\t\t\t\t\tradio.click(function(e) {\n\t\t\t\t\t\te.preventDefault();\n\t\t\t\t\t\tel.triggerHandler('click');\n\t\t\t\t\t\tif (!radio.is('.disabled')) {\n\t\t\t\t\t\t\tvar inputName = $('input[name=\"' + el.attr('name') + '\"]');\n\t\t\t\t\t\t\tinputName.commonParent().find(inputName).prop('checked', false).parent().removeClass('checked');\n\t\t\t\t\t\t\tel.prop('checked', true).parent().addClass('checked');\n\t\t\t\t\t\t\tel.focus().change();\n\t\t\t\t\t\t}\n\t\t\t\t\t});\n\t\t\t\t\t// клик на label\n\t\t\t\t\tel.closest('label').add('label[for=\"' + el.attr('id') + '\"]').on('click.styler', function(e) {\n\t\t\t\t\t\tif (!$(e.target).is('a') && !$(e.target).closest(radio).length) {\n\t\t\t\t\t\t\tradio.triggerHandler('click');\n\t\t\t\t\t\t\te.preventDefault();\n\t\t\t\t\t\t}\n\t\t\t\t\t});\n\t\t\t\t\t// переключение стрелками\n\t\t\t\t\tel.on('change.styler', function() {\n\t\t\t\t\t\tel.parent().addClass('checked');\n\t\t\t\t\t})\n\t\t\t\t\t.on('focus.styler', function() {\n\t\t\t\t\t\tif (!radio.is('.disabled')) radio.addClass('focused');\n\t\t\t\t\t})\n\t\t\t\t\t.on('blur.styler', function() {\n\t\t\t\t\t\tradio.removeClass('focused');\n\t\t\t\t\t});\n\n\t\t\t\t}; // end radioOutput()\n\n\t\t\t\tradioOutput();\n\n\t\t\t\t// обновление при динамическом изменении\n\t\t\t\tel.on('refresh', function() {\n\t\t\t\t\tel.closest('label').add('label[for=\"' + el.attr('id') + '\"]').off('.styler');\n\t\t\t\t\tel.off('.styler').parent().before(el).remove();\n\t\t\t\t\tradioOutput();\n\t\t\t\t});\n\n\t\t\t// end radio\n\n\t\t\t// file\n\t\t\t} else if (el.is(':file')) {\n\n\t\t\t\tvar fileOutput = function() {\n\n\t\t\t\t\tvar att = new Attributes();\n\t\t\t\t\tvar placeholder = el.data('placeholder');\n\t\t\t\t\tif (placeholder === undefined) placeholder = opt.filePlaceholder;\n\t\t\t\t\tvar browse = el.data('browse');\n\t\t\t\t\tif (browse === undefined || browse === '') browse = opt.fileBrowse;\n\n\t\t\t\t\tvar file =\n\t\t\t\t\t\t$('
' +\n\t\t\t\t\t\t\t\t'
' + placeholder + '
' +\n\t\t\t\t\t\t\t\t'
' + browse + '
' +\n\t\t\t\t\t\t\t'
')\n\t\t\t\t\t\t.attr({\n\t\t\t\t\t\t\tid: att.id,\n\t\t\t\t\t\t\ttitle: att.title\n\t\t\t\t\t\t})\n\t\t\t\t\t\t.addClass(att.classes)\n\t\t\t\t\t\t.data(att.data)\n\t\t\t\t\t;\n\n\t\t\t\t\tel.after(file).appendTo(file);\n\t\t\t\t\tif (el.is(':disabled')) file.addClass('disabled');\n\n\t\t\t\t\tvar value = el.val();\n\t\t\t\t\tvar name = $('div.jq-file__name', file);\n\n\t\t\t\t\t// чтобы при динамическом изменении имя файла не сбрасывалось\n\t\t\t\t\tif (value) name.text(value.replace(/.+[\\\\\\/]/, ''));\n\n\t\t\t\t\tel.on('change.styler', function() {\n\t\t\t\t\t\tvar value = el.val();\n\t\t\t\t\t\tif (el.is('[multiple]')) {\n\t\t\t\t\t\t\tvalue = '';\n\t\t\t\t\t\t\tvar files = el[0].files.length;\n\t\t\t\t\t\t\tif (files > 0) {\n\t\t\t\t\t\t\t\tvar number = el.data('number');\n\t\t\t\t\t\t\t\tif (number === undefined) number = opt.fileNumber;\n\t\t\t\t\t\t\t\tnumber = number.replace('%s', files);\n\t\t\t\t\t\t\t\tvalue = number;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tname.text(value.replace(/.+[\\\\\\/]/, ''));\n\t\t\t\t\t\tif (value === '') {\n\t\t\t\t\t\t\tname.text(placeholder);\n\t\t\t\t\t\t\tfile.removeClass('changed');\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tfile.addClass('changed');\n\t\t\t\t\t\t}\n\t\t\t\t\t})\n\t\t\t\t\t.on('focus.styler', function() {\n\t\t\t\t\t\tfile.addClass('focused');\n\t\t\t\t\t})\n\t\t\t\t\t.on('blur.styler', function() {\n\t\t\t\t\t\tfile.removeClass('focused');\n\t\t\t\t\t})\n\t\t\t\t\t.on('click.styler', function() {\n\t\t\t\t\t\tfile.removeClass('focused');\n\t\t\t\t\t});\n\n\t\t\t\t}; // end fileOutput()\n\n\t\t\t\tfileOutput();\n\n\t\t\t\t// обновление при динамическом изменении\n\t\t\t\tel.on('refresh', function() {\n\t\t\t\t\tel.off('.styler').parent().before(el).remove();\n\t\t\t\t\tfileOutput();\n\t\t\t\t});\n\n\t\t\t// end file\n\n\t\t\t// number\n\t\t\t} else if (el.is('input[type=\"number\"]')) {\n\n\t\t\t\tvar numberOutput = function() {\n\n\t\t\t\t\tvar att = new Attributes();\n\t\t\t\t\tvar number =\n\t\t\t\t\t\t$('
' +\n\t\t\t\t\t\t\t\t'
' +\n\t\t\t\t\t\t\t\t'
' +\n\t\t\t\t\t\t\t'
')\n\t\t\t\t\t\t.attr({\n\t\t\t\t\t\t\tid: att.id,\n\t\t\t\t\t\t\ttitle: att.title\n\t\t\t\t\t\t})\n\t\t\t\t\t\t.addClass(att.classes)\n\t\t\t\t\t\t.data(att.data)\n\t\t\t\t\t;\n\n\t\t\t\t\tel.after(number).prependTo(number).wrap('
');\n\t\t\t\t\tif (el.is(':disabled')) number.addClass('disabled');\n\n\t\t\t\t\tvar min,\n\t\t\t\t\t\t\tmax,\n\t\t\t\t\t\t\tstep,\n\t\t\t\t\t\t\ttimeout = null,\n\t\t\t\t\t\t\tinterval = null;\n\t\t\t\t\tif (el.attr('min') !== undefined) min = el.attr('min');\n\t\t\t\t\tif (el.attr('max') !== undefined) max = el.attr('max');\n\t\t\t\t\tif (el.attr('step') !== undefined && $.isNumeric(el.attr('step')))\n\t\t\t\t\t\tstep = Number(el.attr('step'));\n\t\t\t\t\telse\n\t\t\t\t\t\tstep = Number(1);\n\n\t\t\t\t\tvar changeValue = function(spin) {\n\t\t\t\t\t\tvar value = el.val(),\n\t\t\t\t\t\t\t\tnewValue;\n\n\t\t\t\t\t\tif (!$.isNumeric(value)) {\n\t\t\t\t\t\t\tvalue = 0;\n\t\t\t\t\t\t\tel.val('0');\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tif (spin.is('.minus')) {\n\t\t\t\t\t\t\tnewValue = Number(value) - step;\n\t\t\t\t\t\t} else if (spin.is('.plus')) {\n\t\t\t\t\t\t\tnewValue = Number(value) + step;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t// определяем количество десятичных знаков после запятой в step\n\t\t\t\t\t\tvar decimals = (step.toString().split('.')[1] || []).length;\n\t\t\t\t\t\tif (decimals > 0) {\n\t\t\t\t\t\t\tvar multiplier = '1';\n\t\t\t\t\t\t\twhile (multiplier.length <= decimals) multiplier = multiplier + '0';\n\t\t\t\t\t\t\t// избегаем появления лишних знаков после запятой\n\t\t\t\t\t\t\tnewValue = Math.round(newValue * multiplier) / multiplier;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tif ($.isNumeric(min) && $.isNumeric(max)) {\n\t\t\t\t\t\t\tif (newValue >= min && newValue <= max) el.val(newValue);\n\t\t\t\t\t\t} else if ($.isNumeric(min) && !$.isNumeric(max)) {\n\t\t\t\t\t\t\tif (newValue >= min) el.val(newValue);\n\t\t\t\t\t\t} else if (!$.isNumeric(min) && $.isNumeric(max)) {\n\t\t\t\t\t\t\tif (newValue <= max) el.val(newValue);\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tel.val(newValue);\n\t\t\t\t\t\t}\n\t\t\t\t\t};\n\n\t\t\t\t\tif (!number.is('.disabled')) {\n\t\t\t\t\t\tnumber.on('mousedown', 'div.jq-number__spin', function() {\n\t\t\t\t\t\t\tvar spin = $(this);\n\t\t\t\t\t\t\tchangeValue(spin);\n\t\t\t\t\t\t\ttimeout = setTimeout(function(){\n\t\t\t\t\t\t\t\tinterval = setInterval(function(){ changeValue(spin); }, 40);\n\t\t\t\t\t\t\t}, 350);\n\t\t\t\t\t\t}).on('mouseup mouseout', 'div.jq-number__spin', function() {\n\t\t\t\t\t\t\tclearTimeout(timeout);\n\t\t\t\t\t\t\tclearInterval(interval);\n\t\t\t\t\t\t}).on('mouseup', 'div.jq-number__spin', function() {\n\t\t\t\t\t\t\tel.change().trigger('input');\n\t\t\t\t\t\t});\n\t\t\t\t\t\tel.on('focus.styler', function() {\n\t\t\t\t\t\t\tnumber.addClass('focused');\n\t\t\t\t\t\t})\n\t\t\t\t\t\t.on('blur.styler', function() {\n\t\t\t\t\t\t\tnumber.removeClass('focused');\n\t\t\t\t\t\t});\n\t\t\t\t\t}\n\n\t\t\t\t}; // end numberOutput()\n\n\t\t\t\tnumberOutput();\n\n\t\t\t\t// обновление при динамическом изменении\n\t\t\t\tel.on('refresh', function() {\n\t\t\t\t\tel.off('.styler').closest('.jq-number').before(el).remove();\n\t\t\t\t\tnumberOutput();\n\t\t\t\t});\n\n\t\t\t// end number\n\n\t\t\t// select\n\t\t\t} else if (el.is('select')) {\n\n\t\t\t\tvar selectboxOutput = function() {\n\n\t\t\t\t\t// запрещаем прокрутку страницы при прокрутке селекта\n\t\t\t\t\tfunction preventScrolling(selector) {\n\n\t\t\t\t\t\tvar scrollDiff = selector.prop('scrollHeight') - selector.outerHeight(),\n\t\t\t\t\t\t\t\twheelDelta = null,\n\t\t\t\t\t\t\t\tscrollTop = null;\n\n\t\t\t\t\t\tselector.off('mousewheel DOMMouseScroll').on('mousewheel DOMMouseScroll', function(e) {\n\n\t\t\t\t\t\t\t/**\n\t\t\t\t\t\t\t * нормализация направления прокрутки\n\t\t\t\t\t\t\t * (firefox < 0 || chrome etc... > 0)\n\t\t\t\t\t\t\t * (e.originalEvent.detail < 0 || e.originalEvent.wheelDelta > 0)\n\t\t\t\t\t\t\t */\n\t\t\t\t\t\t\twheelDelta = (e.originalEvent.detail < 0 || e.originalEvent.wheelDelta > 0) ? 1 : -1; // направление прокрутки (-1 вниз, 1 вверх)\n\t\t\t\t\t\t\tscrollTop = selector.scrollTop(); // позиция скролла\n\n\t\t\t\t\t\t\tif ((scrollTop >= scrollDiff && wheelDelta < 0) || (scrollTop <= 0 && wheelDelta > 0)) {\n\t\t\t\t\t\t\t\te.stopPropagation();\n\t\t\t\t\t\t\t\te.preventDefault();\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t});\n\t\t\t\t\t}\n\n\t\t\t\t\tvar option = $('option', el);\n\t\t\t\t\tvar list = '';\n\t\t\t\t\t// формируем список селекта\n\t\t\t\t\tfunction makeList() {\n\t\t\t\t\t\tfor (var i = 0; i < option.length; i++) {\n\t\t\t\t\t\t\tvar op = option.eq(i);\n\t\t\t\t\t\t\tvar li = '',\n\t\t\t\t\t\t\t\t\tliClass = '',\n\t\t\t\t\t\t\t\t\tliClasses = '',\n\t\t\t\t\t\t\t\t\tid = '',\n\t\t\t\t\t\t\t\t\ttitle = '',\n\t\t\t\t\t\t\t\t\tdataList = '',\n\t\t\t\t\t\t\t\t\toptionClass = '',\n\t\t\t\t\t\t\t\t\toptgroupClass = '',\n\t\t\t\t\t\t\t\t\tdataJqfsClass = '';\n\t\t\t\t\t\t\tvar disabled = 'disabled';\n\t\t\t\t\t\t\tvar selDis = 'selected sel disabled';\n\t\t\t\t\t\t\tif (op.prop('selected')) liClass = 'selected sel';\n\t\t\t\t\t\t\tif (op.is(':disabled')) liClass = disabled;\n\t\t\t\t\t\t\tif (op.is(':selected:disabled')) liClass = selDis;\n\t\t\t\t\t\t\tif (op.attr('id') !== undefined && op.attr('id') !== '') id = ' id=\"' + op.attr('id') + opt.idSuffix + '\"';\n\t\t\t\t\t\t\tif (op.attr('title') !== undefined && option.attr('title') !== '') title = ' title=\"' + op.attr('title') + '\"';\n\t\t\t\t\t\t\tif (op.attr('class') !== undefined) {\n\t\t\t\t\t\t\t\toptionClass = ' ' + op.attr('class');\n\t\t\t\t\t\t\t\tdataJqfsClass = ' data-jqfs-class=\"' + op.attr('class') + '\"';\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tvar data = op.data();\n\t\t\t\t\t\t\tfor (var k in data) {\n\t\t\t\t\t\t\t\tif (data[k] !== '') dataList += ' data-' + k + '=\"' + data[k] + '\"';\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tif ( (liClass + optionClass) !== '' ) liClasses = ' class=\"' + liClass + optionClass + '\"';\n\t\t\t\t\t\t\tli = ''+ op.html() +'';\n\n\t\t\t\t\t\t\t// если есть optgroup\n\t\t\t\t\t\t\tif (op.parent().is('optgroup')) {\n\t\t\t\t\t\t\t\tif (op.parent().attr('class') !== undefined) optgroupClass = ' ' + op.parent().attr('class');\n\t\t\t\t\t\t\t\tli = ''+ op.html() +'';\n\t\t\t\t\t\t\t\tif (op.is(':first-child')) {\n\t\t\t\t\t\t\t\t\tli = '
  • ' + op.parent().attr('label') + '
  • ' + li;\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tlist += li;\n\t\t\t\t\t\t}\n\t\t\t\t\t} // end makeList()\n\n\t\t\t\t\t// одиночный селект\n\t\t\t\t\tfunction doSelect() {\n\n\t\t\t\t\t\tvar att = new Attributes();\n\t\t\t\t\t\tvar searchHTML = '';\n\t\t\t\t\t\tvar selectPlaceholder = el.data('placeholder');\n\t\t\t\t\t\tvar selectSearch = el.data('search');\n\t\t\t\t\t\tvar selectSearchLimit = el.data('search-limit');\n\t\t\t\t\t\tvar selectSearchNotFound = el.data('search-not-found');\n\t\t\t\t\t\tvar selectSearchPlaceholder = el.data('search-placeholder');\n\t\t\t\t\t\tvar selectSmartPositioning = el.data('smart-positioning');\n\n\t\t\t\t\t\tif (selectPlaceholder === undefined) selectPlaceholder = opt.selectPlaceholder;\n\t\t\t\t\t\tif (selectSearch === undefined || selectSearch === '') selectSearch = opt.selectSearch;\n\t\t\t\t\t\tif (selectSearchLimit === undefined || selectSearchLimit === '') selectSearchLimit = opt.selectSearchLimit;\n\t\t\t\t\t\tif (selectSearchNotFound === undefined || selectSearchNotFound === '') selectSearchNotFound = opt.selectSearchNotFound;\n\t\t\t\t\t\tif (selectSearchPlaceholder === undefined) selectSearchPlaceholder = opt.selectSearchPlaceholder;\n\t\t\t\t\t\tif (selectSmartPositioning === undefined || selectSmartPositioning === '') selectSmartPositioning = opt.selectSmartPositioning;\n\n\t\t\t\t\t\tvar selectbox =\n\t\t\t\t\t\t\t$('
    ' +\n\t\t\t\t\t\t\t\t\t'
    ' +\n\t\t\t\t\t\t\t\t\t\t'
    ' +\n\t\t\t\t\t\t\t\t\t\t'
    ' +\n\t\t\t\t\t\t\t\t\t\t\t'
    ' +\n\t\t\t\t\t\t\t\t\t'
    ' +\n\t\t\t\t\t\t\t\t'
    ')\n\t\t\t\t\t\t\t.attr({\n\t\t\t\t\t\t\t\tid: att.id,\n\t\t\t\t\t\t\t\ttitle: att.title\n\t\t\t\t\t\t\t})\n\t\t\t\t\t\t\t.addClass(att.classes)\n\t\t\t\t\t\t\t.data(att.data)\n\t\t\t\t\t\t;\n\n\t\t\t\t\t\tel.after(selectbox).prependTo(selectbox);\n\n\t\t\t\t\t\tvar selectzIndex = selectbox.css('z-index');\n\t\t\t\t\t\tselectzIndex = (selectzIndex > 0 ) ? selectzIndex : 1;\n\t\t\t\t\t\tvar divSelect = $('div.jq-selectbox__select', selectbox);\n\t\t\t\t\t\tvar divText = $('div.jq-selectbox__select-text', selectbox);\n\t\t\t\t\t\tvar optionSelected = option.filter(':selected');\n\n\t\t\t\t\t\tmakeList();\n\n\t\t\t\t\t\tif (selectSearch) searchHTML =\n\t\t\t\t\t\t\t'
    ' +\n\t\t\t\t\t\t\t'
    ' + selectSearchNotFound + '
    ';\n\t\t\t\t\t\tvar dropdown =\n\t\t\t\t\t\t\t$('
    ' +\n\t\t\t\t\t\t\t\t\tsearchHTML + '
      ' + list + '
    ' +\n\t\t\t\t\t\t\t\t'
    ');\n\t\t\t\t\t\tselectbox.append(dropdown);\n\t\t\t\t\t\tvar ul = $('ul', dropdown);\n\t\t\t\t\t\tvar li = $('li', dropdown);\n\t\t\t\t\t\tvar search = $('input', dropdown);\n\t\t\t\t\t\tvar notFound = $('div.jq-selectbox__not-found', dropdown).hide();\n\t\t\t\t\t\tif (li.length < selectSearchLimit) search.parent().hide();\n\n\t\t\t\t\t\t// показываем опцию по умолчанию\n\t\t\t\t\t\t// если у 1-й опции нет текста, она выбрана по умолчанию и параметр selectPlaceholder не false, то показываем плейсхолдер\n\t\t\t\t\t\tif (option.first().text() === '' && option.first().is(':selected') && selectPlaceholder !== false) {\n\t\t\t\t\t\t\tdivText.text(selectPlaceholder).addClass('placeholder');\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tdivText.text(optionSelected.text());\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t// определяем самый широкий пункт селекта\n\t\t\t\t\t\tvar liWidthInner = 0,\n\t\t\t\t\t\t\t\tliWidth = 0;\n\t\t\t\t\t\tli.css({'display': 'inline-block'});\n\t\t\t\t\t\tli.each(function() {\n\t\t\t\t\t\t\tvar l = $(this);\n\t\t\t\t\t\t\tif (l.innerWidth() > liWidthInner) {\n\t\t\t\t\t\t\t\tliWidthInner = l.innerWidth();\n\t\t\t\t\t\t\t\tliWidth = l.width();\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t});\n\t\t\t\t\t\tli.css({'display': ''});\n\n\t\t\t\t\t\t// подстраиваем ширину свернутого селекта в зависимости\n\t\t\t\t\t\t// от ширины плейсхолдера или самого широкого пункта\n\t\t\t\t\t\tif (divText.is('.placeholder') && (divText.width() > liWidthInner)) {\n\t\t\t\t\t\t\tdivText.width(divText.width());\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tvar selClone = selectbox.clone().appendTo('body').width('auto');\n\t\t\t\t\t\t\tvar selCloneWidth = selClone.outerWidth();\n\t\t\t\t\t\t\tselClone.remove();\n\t\t\t\t\t\t\tif (selCloneWidth == selectbox.outerWidth()) {\n\t\t\t\t\t\t\t\tdivText.width(liWidth);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t// подстраиваем ширину выпадающего списка в зависимости от самого широкого пункта\n\t\t\t\t\t\tif (liWidthInner > selectbox.width()) dropdown.width(liWidthInner);\n\n\t\t\t\t\t\t// прячем 1-ю пустую опцию, если она есть и если атрибут data-placeholder не пустой\n\t\t\t\t\t\t// если все же нужно, чтобы первая пустая опция отображалась, то указываем у селекта: data-placeholder=\"\"\n\t\t\t\t\t\tif (option.first().text() === '' && el.data('placeholder') !== '') {\n\t\t\t\t\t\t\tli.first().hide();\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tvar selectHeight = selectbox.outerHeight(true);\n\t\t\t\t\t\tvar searchHeight = search.parent().outerHeight(true) || 0;\n\t\t\t\t\t\tvar isMaxHeight = ul.css('max-height');\n\t\t\t\t\t\tvar liSelected = li.filter('.selected');\n\t\t\t\t\t\tif (liSelected.length < 1) li.first().addClass('selected sel');\n\t\t\t\t\t\tif (li.data('li-height') === undefined) {\n\t\t\t\t\t\t\tvar liOuterHeight = li.outerHeight();\n\t\t\t\t\t\t\tif (selectPlaceholder !== false) liOuterHeight = li.eq(1).outerHeight();\n\t\t\t\t\t\t\tli.data('li-height', liOuterHeight);\n\t\t\t\t\t\t}\n\t\t\t\t\t\tvar position = dropdown.css('top');\n\t\t\t\t\t\tif (dropdown.css('left') == 'auto') dropdown.css({left: 0});\n\t\t\t\t\t\tif (dropdown.css('top') == 'auto') {\n\t\t\t\t\t\t\tdropdown.css({top: selectHeight});\n\t\t\t\t\t\t\tposition = selectHeight;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tdropdown.hide();\n\n\t\t\t\t\t\t// если выбран не дефолтный пункт\n\t\t\t\t\t\tif (liSelected.length) {\n\t\t\t\t\t\t\t// добавляем класс, показывающий изменение селекта\n\t\t\t\t\t\t\tif (option.first().text() != optionSelected.text()) {\n\t\t\t\t\t\t\t\tselectbox.addClass('changed');\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t// передаем селекту класс выбранного пункта\n\t\t\t\t\t\t\tselectbox.data('jqfs-class', liSelected.data('jqfs-class'));\n\t\t\t\t\t\t\tselectbox.addClass(liSelected.data('jqfs-class'));\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t// если селект неактивный\n\t\t\t\t\t\tif (el.is(':disabled')) {\n\t\t\t\t\t\t\tselectbox.addClass('disabled');\n\t\t\t\t\t\t\treturn false;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t// при клике на псевдоселекте\n\t\t\t\t\t\tdivSelect.click(function() {\n\n\t\t\t\t\t\t\t// колбек при закрытии селекта\n\t\t\t\t\t\t\tif ($('div.jq-selectbox').filter('.opened').length) {\n\t\t\t\t\t\t\t\topt.onSelectClosed.call($('div.jq-selectbox').filter('.opened'));\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tel.focus();\n\n\t\t\t\t\t\t\t// если iOS, то не показываем выпадающий список,\n\t\t\t\t\t\t\t// т.к. отображается нативный и неизвестно, как его спрятать\n\t\t\t\t\t\t\tif (iOS) return;\n\n\t\t\t\t\t\t\t// умное позиционирование\n\t\t\t\t\t\t\tvar win = $(window);\n\t\t\t\t\t\t\tvar liHeight = li.data('li-height');\n\t\t\t\t\t\t\tvar topOffset = selectbox.offset().top;\n\t\t\t\t\t\t\tvar bottomOffset = win.height() - selectHeight - (topOffset - win.scrollTop());\n\t\t\t\t\t\t\tvar visible = el.data('visible-options');\n\t\t\t\t\t\t\tif (visible === undefined || visible === '') visible = opt.selectVisibleOptions;\n\t\t\t\t\t\t\tvar minHeight = liHeight * 5;\n\t\t\t\t\t\t\tvar newHeight = liHeight * visible;\n\t\t\t\t\t\t\tif (visible > 0 && visible < 6) minHeight = newHeight;\n\t\t\t\t\t\t\tif (visible === 0) newHeight = 'auto';\n\n\t\t\t\t\t\t\tvar dropDown = function() {\n\t\t\t\t\t\t\t\tdropdown.height('auto').css({bottom: 'auto', top: position});\n\t\t\t\t\t\t\t\tvar maxHeightBottom = function() {\n\t\t\t\t\t\t\t\t\tul.css('max-height', Math.floor((bottomOffset - 20 - searchHeight) / liHeight) * liHeight);\n\t\t\t\t\t\t\t\t};\n\t\t\t\t\t\t\t\tmaxHeightBottom();\n\t\t\t\t\t\t\t\tul.css('max-height', newHeight);\n\t\t\t\t\t\t\t\tif (isMaxHeight != 'none') {\n\t\t\t\t\t\t\t\t\tul.css('max-height', isMaxHeight);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tif (bottomOffset < (dropdown.outerHeight() + 20)) {\n\t\t\t\t\t\t\t\t\tmaxHeightBottom();\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t};\n\n\t\t\t\t\t\t\tvar dropUp = function() {\n\t\t\t\t\t\t\t\tdropdown.height('auto').css({top: 'auto', bottom: position});\n\t\t\t\t\t\t\t\tvar maxHeightTop = function() {\n\t\t\t\t\t\t\t\t\tul.css('max-height', Math.floor((topOffset - win.scrollTop() - 20 - searchHeight) / liHeight) * liHeight);\n\t\t\t\t\t\t\t\t};\n\t\t\t\t\t\t\t\tmaxHeightTop();\n\t\t\t\t\t\t\t\tul.css('max-height', newHeight);\n\t\t\t\t\t\t\t\tif (isMaxHeight != 'none') {\n\t\t\t\t\t\t\t\t\tul.css('max-height', isMaxHeight);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\tif ((topOffset - win.scrollTop() - 20) < (dropdown.outerHeight() + 20)) {\n\t\t\t\t\t\t\t\t\tmaxHeightTop();\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t};\n\n\t\t\t\t\t\t\tif (selectSmartPositioning === true || selectSmartPositioning === 1) {\n\t\t\t\t\t\t\t\t// раскрытие вниз\n\t\t\t\t\t\t\t\tif (bottomOffset > (minHeight + searchHeight + 20)) {\n\t\t\t\t\t\t\t\t\tdropDown();\n\t\t\t\t\t\t\t\t\tselectbox.removeClass('dropup').addClass('dropdown');\n\t\t\t\t\t\t\t\t// раскрытие вверх\n\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\tdropUp();\n\t\t\t\t\t\t\t\t\tselectbox.removeClass('dropdown').addClass('dropup');\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t} else if (selectSmartPositioning === false || selectSmartPositioning === 0) {\n\t\t\t\t\t\t\t\t// раскрытие вниз\n\t\t\t\t\t\t\t\tif (bottomOffset > (minHeight + searchHeight + 20)) {\n\t\t\t\t\t\t\t\t\tdropDown();\n\t\t\t\t\t\t\t\t\tselectbox.removeClass('dropup').addClass('dropdown');\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t// если умное позиционирование отключено\n\t\t\t\t\t\t\t\tdropdown.height('auto').css({bottom: 'auto', top: position});\n\t\t\t\t\t\t\t\tul.css('max-height', newHeight);\n\t\t\t\t\t\t\t\tif (isMaxHeight != 'none') {\n\t\t\t\t\t\t\t\t\tul.css('max-height', isMaxHeight);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t// если выпадающий список выходит за правый край окна браузера,\n\t\t\t\t\t\t\t// то меняем позиционирование с левого на правое\n\t\t\t\t\t\t\tif (selectbox.offset().left + dropdown.outerWidth() > win.width()) {\n\t\t\t\t\t\t\t\tdropdown.css({left: 'auto', right: 0});\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t// конец умного позиционирования\n\n\t\t\t\t\t\t\t$('div.jqselect').css({zIndex: (selectzIndex - 1)}).removeClass('opened');\n\t\t\t\t\t\t\tselectbox.css({zIndex: selectzIndex});\n\t\t\t\t\t\t\tif (dropdown.is(':hidden')) {\n\t\t\t\t\t\t\t\t$('div.jq-selectbox__dropdown:visible').hide();\n\t\t\t\t\t\t\t\tdropdown.show();\n\t\t\t\t\t\t\t\tselectbox.addClass('opened focused');\n\t\t\t\t\t\t\t\t// колбек при открытии селекта\n\t\t\t\t\t\t\t\topt.onSelectOpened.call(selectbox);\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\tdropdown.hide();\n\t\t\t\t\t\t\t\tselectbox.removeClass('opened dropup dropdown');\n\t\t\t\t\t\t\t\t// колбек при закрытии селекта\n\t\t\t\t\t\t\t\tif ($('div.jq-selectbox').filter('.opened').length) {\n\t\t\t\t\t\t\t\t\topt.onSelectClosed.call(selectbox);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t// поисковое поле\n\t\t\t\t\t\t\tif (search.length) {\n\t\t\t\t\t\t\t\tsearch.val('').keyup();\n\t\t\t\t\t\t\t\tnotFound.hide();\n\t\t\t\t\t\t\t\tsearch.keyup(function() {\n\t\t\t\t\t\t\t\t\tvar query = $(this).val();\n\t\t\t\t\t\t\t\t\tli.each(function() {\n\t\t\t\t\t\t\t\t\t\tif (!$(this).html().match(new RegExp('.*?' + query + '.*?', 'i'))) {\n\t\t\t\t\t\t\t\t\t\t\t$(this).hide();\n\t\t\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\t\t\t$(this).show();\n\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\t\t// прячем 1-ю пустую опцию\n\t\t\t\t\t\t\t\t\tif (option.first().text() === '' && el.data('placeholder') !== '') {\n\t\t\t\t\t\t\t\t\t\tli.first().hide();\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\tif (li.filter(':visible').length < 1) {\n\t\t\t\t\t\t\t\t\t\tnotFound.show();\n\t\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\t\tnotFound.hide();\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t// прокручиваем до выбранного пункта при открытии списка\n\t\t\t\t\t\t\tif (li.filter('.selected').length) {\n\t\t\t\t\t\t\t\tif (el.val() === '') {\n\t\t\t\t\t\t\t\t\tul.scrollTop(0);\n\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\t// если нечетное количество видимых пунктов,\n\t\t\t\t\t\t\t\t\t// то высоту пункта делим пополам для последующего расчета\n\t\t\t\t\t\t\t\t\tif ( (ul.innerHeight() / liHeight) % 2 !== 0 ) liHeight = liHeight / 2;\n\t\t\t\t\t\t\t\t\tul.scrollTop(ul.scrollTop() + li.filter('.selected').position().top - ul.innerHeight() / 2 + liHeight);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tpreventScrolling(ul);\n\n\t\t\t\t\t\t}); // end divSelect.click()\n\n\t\t\t\t\t\t// при наведении курсора на пункт списка\n\t\t\t\t\t\tli.hover(function() {\n\t\t\t\t\t\t\t$(this).siblings().removeClass('selected');\n\t\t\t\t\t\t});\n\t\t\t\t\t\tvar selectedText = li.filter('.selected').text();\n\n\t\t\t\t\t\t// при клике на пункт списка\n\t\t\t\t\t\tli.filter(':not(.disabled):not(.optgroup)').click(function() {\n\t\t\t\t\t\t\tel.focus();\n\t\t\t\t\t\t\tvar t = $(this);\n\t\t\t\t\t\t\tvar liText = t.text();\n\t\t\t\t\t\t\tif (!t.is('.selected')) {\n\t\t\t\t\t\t\t\tvar index = t.index();\n\t\t\t\t\t\t\t\tindex -= t.prevAll('.optgroup').length;\n\t\t\t\t\t\t\t\tt.addClass('selected sel').siblings().removeClass('selected sel');\n\t\t\t\t\t\t\t\toption.prop('selected', false).eq(index).prop('selected', true);\n\t\t\t\t\t\t\t\tselectedText = liText;\n\t\t\t\t\t\t\t\tdivText.text(liText);\n\n\t\t\t\t\t\t\t\t// передаем селекту класс выбранного пункта\n\t\t\t\t\t\t\t\tif (selectbox.data('jqfs-class')) selectbox.removeClass(selectbox.data('jqfs-class'));\n\t\t\t\t\t\t\t\tselectbox.data('jqfs-class', t.data('jqfs-class'));\n\t\t\t\t\t\t\t\tselectbox.addClass(t.data('jqfs-class'));\n\n\t\t\t\t\t\t\t\tel.change();\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tdropdown.hide();\n\t\t\t\t\t\t\tselectbox.removeClass('opened dropup dropdown');\n\t\t\t\t\t\t\t// колбек при закрытии селекта\n\t\t\t\t\t\t\topt.onSelectClosed.call(selectbox);\n\n\t\t\t\t\t\t});\n\t\t\t\t\t\tdropdown.mouseout(function() {\n\t\t\t\t\t\t\t$('li.sel', dropdown).addClass('selected');\n\t\t\t\t\t\t});\n\n\t\t\t\t\t\t// изменение селекта\n\t\t\t\t\t\tel.on('change.styler', function() {\n\t\t\t\t\t\t\tdivText.text(option.filter(':selected').text()).removeClass('placeholder');\n\t\t\t\t\t\t\tli.removeClass('selected sel').not('.optgroup').eq(el[0].selectedIndex).addClass('selected sel');\n\t\t\t\t\t\t\t// добавляем класс, показывающий изменение селекта\n\t\t\t\t\t\t\tif (option.first().text() != li.filter('.selected').text()) {\n\t\t\t\t\t\t\t\tselectbox.addClass('changed');\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\tselectbox.removeClass('changed');\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t})\n\t\t\t\t\t\t.on('focus.styler', function() {\n\t\t\t\t\t\t\tselectbox.addClass('focused');\n\t\t\t\t\t\t\t$('div.jqselect').not('.focused').removeClass('opened dropup dropdown').find('div.jq-selectbox__dropdown').hide();\n\t\t\t\t\t\t})\n\t\t\t\t\t\t.on('blur.styler', function() {\n\t\t\t\t\t\t\tselectbox.removeClass('focused');\n\t\t\t\t\t\t})\n\t\t\t\t\t\t// изменение селекта с клавиатуры\n\t\t\t\t\t\t.on('keydown.styler keyup.styler', function(e) {\n\t\t\t\t\t\t\tvar liHeight = li.data('li-height');\n\t\t\t\t\t\t\tif (el.val() === '') {\n\t\t\t\t\t\t\t\tdivText.text(selectPlaceholder).addClass('placeholder');\n\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\tdivText.text(option.filter(':selected').text());\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tli.removeClass('selected sel').not('.optgroup').eq(el[0].selectedIndex).addClass('selected sel');\n\t\t\t\t\t\t\t// вверх, влево, Page Up, Home\n\t\t\t\t\t\t\tif (e.which == 38 || e.which == 37 || e.which == 33 || e.which == 36) {\n\t\t\t\t\t\t\t\tif (el.val() === '') {\n\t\t\t\t\t\t\t\t\tul.scrollTop(0);\n\t\t\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\t\t\tul.scrollTop(ul.scrollTop() + li.filter('.selected').position().top);\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t// вниз, вправо, Page Down, End\n\t\t\t\t\t\t\tif (e.which == 40 || e.which == 39 || e.which == 34 || e.which == 35) {\n\t\t\t\t\t\t\t\tul.scrollTop(ul.scrollTop() + li.filter('.selected').position().top - ul.innerHeight() + liHeight);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t// закрываем выпадающий список при нажатии Enter\n\t\t\t\t\t\t\tif (e.which == 13) {\n\t\t\t\t\t\t\t\te.preventDefault();\n\t\t\t\t\t\t\t\tdropdown.hide();\n\t\t\t\t\t\t\t\tselectbox.removeClass('opened dropup dropdown');\n\t\t\t\t\t\t\t\t// колбек при закрытии селекта\n\t\t\t\t\t\t\t\topt.onSelectClosed.call(selectbox);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}).on('keydown.styler', function(e) {\n\t\t\t\t\t\t\t// открываем выпадающий список при нажатии Space\n\t\t\t\t\t\t\tif (e.which == 32) {\n\t\t\t\t\t\t\t\te.preventDefault();\n\t\t\t\t\t\t\t\tdivSelect.click();\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t});\n\n\t\t\t\t\t\t// прячем выпадающий список при клике за пределами селекта\n\t\t\t\t\t\tif (!onDocumentClick.registered) {\n\t\t\t\t\t\t\t$(document).on('click', onDocumentClick);\n\t\t\t\t\t\t\tonDocumentClick.registered = true;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t} // end doSelect()\n\n\t\t\t\t\t// мультиселект\n\t\t\t\t\tfunction doMultipleSelect() {\n\n\t\t\t\t\t\tvar att = new Attributes();\n\t\t\t\t\t\tvar selectbox =\n\t\t\t\t\t\t\t$('
    ')\n\t\t\t\t\t\t\t.attr({\n\t\t\t\t\t\t\t\tid: att.id,\n\t\t\t\t\t\t\t\ttitle: att.title\n\t\t\t\t\t\t\t})\n\t\t\t\t\t\t\t.addClass(att.classes)\n\t\t\t\t\t\t\t.data(att.data)\n\t\t\t\t\t\t;\n\n\t\t\t\t\t\tel.after(selectbox);\n\n\t\t\t\t\t\tmakeList();\n\t\t\t\t\t\tselectbox.append('
      ' + list + '
    ');\n\t\t\t\t\t\tvar ul = $('ul', selectbox);\n\t\t\t\t\t\tvar li = $('li', selectbox);\n\t\t\t\t\t\tvar size = el.attr('size');\n\t\t\t\t\t\tvar ulHeight = ul.outerHeight();\n\t\t\t\t\t\tvar liHeight = li.outerHeight();\n\t\t\t\t\t\tif (size !== undefined && size > 0) {\n\t\t\t\t\t\t\tul.css({'height': liHeight * size});\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tul.css({'height': liHeight * 4});\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif (ulHeight > selectbox.height()) {\n\t\t\t\t\t\t\tul.css('overflowY', 'scroll');\n\t\t\t\t\t\t\tpreventScrolling(ul);\n\t\t\t\t\t\t\t// прокручиваем до выбранного пункта\n\t\t\t\t\t\t\tif (li.filter('.selected').length) {\n\t\t\t\t\t\t\t\tul.scrollTop(ul.scrollTop() + li.filter('.selected').position().top);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t// прячем оригинальный селект\n\t\t\t\t\t\tel.prependTo(selectbox);\n\n\t\t\t\t\t\t// если селект неактивный\n\t\t\t\t\t\tif (el.is(':disabled')) {\n\t\t\t\t\t\t\tselectbox.addClass('disabled');\n\t\t\t\t\t\t\toption.each(function() {\n\t\t\t\t\t\t\t\tif ($(this).is(':selected')) li.eq($(this).index()).addClass('selected');\n\t\t\t\t\t\t\t});\n\n\t\t\t\t\t\t// если селект активный\n\t\t\t\t\t\t} else {\n\n\t\t\t\t\t\t\t// при клике на пункт списка\n\t\t\t\t\t\t\tli.filter(':not(.disabled):not(.optgroup)').click(function(e) {\n\t\t\t\t\t\t\t\tel.focus();\n\t\t\t\t\t\t\t\tvar clkd = $(this);\n\t\t\t\t\t\t\t\tif(!e.ctrlKey && !e.metaKey) clkd.addClass('selected');\n\t\t\t\t\t\t\t\tif(!e.shiftKey) clkd.addClass('first');\n\t\t\t\t\t\t\t\tif(!e.ctrlKey && !e.metaKey && !e.shiftKey) clkd.siblings().removeClass('selected first');\n\n\t\t\t\t\t\t\t\t// выделение пунктов при зажатом Ctrl\n\t\t\t\t\t\t\t\tif(e.ctrlKey || e.metaKey) {\n\t\t\t\t\t\t\t\t\tif (clkd.is('.selected')) clkd.removeClass('selected first');\n\t\t\t\t\t\t\t\t\t\telse clkd.addClass('selected first');\n\t\t\t\t\t\t\t\t\tclkd.siblings().removeClass('first');\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t// выделение пунктов при зажатом Shift\n\t\t\t\t\t\t\t\tif(e.shiftKey) {\n\t\t\t\t\t\t\t\t\tvar prev = false,\n\t\t\t\t\t\t\t\t\t\t\tnext = false;\n\t\t\t\t\t\t\t\t\tclkd.siblings().removeClass('selected').siblings('.first').addClass('selected');\n\t\t\t\t\t\t\t\t\tclkd.prevAll().each(function() {\n\t\t\t\t\t\t\t\t\t\tif ($(this).is('.first')) prev = true;\n\t\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\t\tclkd.nextAll().each(function() {\n\t\t\t\t\t\t\t\t\t\tif ($(this).is('.first')) next = true;\n\t\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\t\tif (prev) {\n\t\t\t\t\t\t\t\t\t\tclkd.prevAll().each(function() {\n\t\t\t\t\t\t\t\t\t\t\tif ($(this).is('.selected')) return false;\n\t\t\t\t\t\t\t\t\t\t\t\telse $(this).not('.disabled, .optgroup').addClass('selected');\n\t\t\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\tif (next) {\n\t\t\t\t\t\t\t\t\t\tclkd.nextAll().each(function() {\n\t\t\t\t\t\t\t\t\t\t\tif ($(this).is('.selected')) return false;\n\t\t\t\t\t\t\t\t\t\t\t\telse $(this).not('.disabled, .optgroup').addClass('selected');\n\t\t\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\tif (li.filter('.selected').length == 1) clkd.addClass('first');\n\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t// отмечаем выбранные мышью\n\t\t\t\t\t\t\t\toption.prop('selected', false);\n\t\t\t\t\t\t\t\tli.filter('.selected').each(function() {\n\t\t\t\t\t\t\t\t\tvar t = $(this);\n\t\t\t\t\t\t\t\t\tvar index = t.index();\n\t\t\t\t\t\t\t\t\tif (t.is('.option')) index -= t.prevAll('.optgroup').length;\n\t\t\t\t\t\t\t\t\toption.eq(index).prop('selected', true);\n\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\tel.change();\n\n\t\t\t\t\t\t\t});\n\n\t\t\t\t\t\t\t// отмечаем выбранные с клавиатуры\n\t\t\t\t\t\t\toption.each(function(i) {\n\t\t\t\t\t\t\t\t$(this).data('optionIndex', i);\n\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\tel.on('change.styler', function() {\n\t\t\t\t\t\t\t\tli.removeClass('selected');\n\t\t\t\t\t\t\t\tvar arrIndexes = [];\n\t\t\t\t\t\t\t\toption.filter(':selected').each(function() {\n\t\t\t\t\t\t\t\t\tarrIndexes.push($(this).data('optionIndex'));\n\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\tli.not('.optgroup').filter(function(i) {\n\t\t\t\t\t\t\t\t\treturn $.inArray(i, arrIndexes) > -1;\n\t\t\t\t\t\t\t\t}).addClass('selected');\n\t\t\t\t\t\t\t})\n\t\t\t\t\t\t\t.on('focus.styler', function() {\n\t\t\t\t\t\t\t\tselectbox.addClass('focused');\n\t\t\t\t\t\t\t})\n\t\t\t\t\t\t\t.on('blur.styler', function() {\n\t\t\t\t\t\t\t\tselectbox.removeClass('focused');\n\t\t\t\t\t\t\t});\n\n\t\t\t\t\t\t\t// прокручиваем с клавиатуры\n\t\t\t\t\t\t\tif (ulHeight > selectbox.height()) {\n\t\t\t\t\t\t\t\tel.on('keydown.styler', function(e) {\n\t\t\t\t\t\t\t\t\t// вверх, влево, PageUp\n\t\t\t\t\t\t\t\t\tif (e.which == 38 || e.which == 37 || e.which == 33) {\n\t\t\t\t\t\t\t\t\t\tul.scrollTop(ul.scrollTop() + li.filter('.selected').position().top - liHeight);\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t// вниз, вправо, PageDown\n\t\t\t\t\t\t\t\t\tif (e.which == 40 || e.which == 39 || e.which == 34) {\n\t\t\t\t\t\t\t\t\t\tul.scrollTop(ul.scrollTop() + li.filter('.selected:last').position().top - ul.innerHeight() + liHeight * 2);\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t}\n\t\t\t\t\t} // end doMultipleSelect()\n\n\t\t\t\t\tif (el.is('[multiple]')) {\n\n\t\t\t\t\t\t// если Android или iOS, то мультиселект не стилизуем\n\t\t\t\t\t\t// причина для Android - в стилизованном селекте нет возможности выбрать несколько пунктов\n\t\t\t\t\t\t// причина для iOS - в стилизованном селекте неправильно отображаются выбранные пункты\n\t\t\t\t\t\tif (Android || iOS) return;\n\n\t\t\t\t\t\tdoMultipleSelect();\n\t\t\t\t\t} else {\n\t\t\t\t\t\tdoSelect();\n\t\t\t\t\t}\n\n\t\t\t\t}; // end selectboxOutput()\n\n\t\t\t\tselectboxOutput();\n\n\t\t\t\t// обновление при динамическом изменении\n\t\t\t\tel.on('refresh', function() {\n\t\t\t\t\tel.off('.styler').parent().before(el).remove();\n\t\t\t\t\tselectboxOutput();\n\t\t\t\t});\n\n\t\t\t// end select\n\n\t\t\t// reset\n\t\t\t} else if (el.is(':reset')) {\n\t\t\t\tel.on('click', function() {\n\t\t\t\t\tsetTimeout(function() {\n\t\t\t\t\t\tel.closest('form').find('input, select').trigger('refresh');\n\t\t\t\t\t}, 1);\n\t\t\t\t});\n\t\t\t} // end reset\n\n\t\t}, // init: function()\n\n\t\t// деструктор\n\t\tdestroy: function() {\n\n\t\t\tvar el = $(this.element);\n\n\t\t\tif (el.is(':checkbox') || el.is(':radio')) {\n\t\t\t\tel.removeData('_' + pluginName).off('.styler refresh').removeAttr('style').parent().before(el).remove();\n\t\t\t\tel.closest('label').add('label[for=\"' + el.attr('id') + '\"]').off('.styler');\n\t\t\t} else if (el.is('input[type=\"number\"]')) {\n\t\t\t\tel.removeData('_' + pluginName).off('.styler refresh').closest('.jq-number').before(el).remove();\n\t\t\t} else if (el.is(':file') || el.is('select')) {\n\t\t\t\tel.removeData('_' + pluginName).off('.styler refresh').removeAttr('style').parent().before(el).remove();\n\t\t\t}\n\n\t\t} // destroy: function()\n\n\t}; // Plugin.prototype\n\n\t$.fn[pluginName] = function(options) {\n\t\tvar args = arguments;\n\t\tif (options === undefined || typeof options === 'object') {\n\t\t\tthis.each(function() {\n\t\t\t\tif (!$.data(this, '_' + pluginName)) {\n\t\t\t\t\t$.data(this, '_' + pluginName, new Plugin(this, options));\n\t\t\t\t}\n\t\t\t})\n\t\t\t// колбек после выполнения плагина\n\t\t\t.promise()\n\t\t\t.done(function() {\n\t\t\t\tvar opt = $(this[0]).data('_' + pluginName);\n\t\t\t\tif (opt) opt.options.onFormStyled.call();\n\t\t\t});\n\t\t\treturn this;\n\t\t} else if (typeof options === 'string' && options[0] !== '_' && options !== 'init') {\n\t\t\tvar returns;\n\t\t\tthis.each(function() {\n\t\t\t\tvar instance = $.data(this, '_' + pluginName);\n\t\t\t\tif (instance instanceof Plugin && typeof instance[options] === 'function') {\n\t\t\t\t\treturns = instance[options].apply(instance, Array.prototype.slice.call(args, 1));\n\t\t\t\t}\n\t\t\t});\n\t\t\treturn returns !== undefined ? returns : this;\n\t\t}\n\t};\n\n\t// прячем выпадающий список при клике за пределами селекта\n\tfunction onDocumentClick(e) {\n\t\t// e.target.nodeName != 'OPTION' - добавлено для обхода бага в Opera на движке Presto\n\t\t// (при изменении селекта с клавиатуры срабатывает событие onclick)\n\t\tif (!$(e.target).parents().hasClass('jq-selectbox') && e.target.nodeName != 'OPTION') {\n\t\t\tif ($('div.jq-selectbox.opened').length) {\n\t\t\t\tvar selectbox = $('div.jq-selectbox.opened'),\n\t\t\t\t\t\tsearch = $('div.jq-selectbox__search input', selectbox),\n\t\t\t\t\t\tdropdown = $('div.jq-selectbox__dropdown', selectbox),\n\t\t\t\t\t\topt = selectbox.find('select').data('_' + pluginName).options;\n\n\t\t\t\t// колбек при закрытии селекта\n\t\t\t\topt.onSelectClosed.call(selectbox);\n\n\t\t\t\tif (search.length) search.val('').keyup();\n\t\t\t\tdropdown.hide().find('li.sel').addClass('selected');\n\t\t\t\tselectbox.removeClass('focused opened dropup dropdown');\n\t\t\t}\n\t\t}\n\t}\n\tonDocumentClick.registered = false;\n\n}));"],"sourceRoot":""}