1 2/* AUTOGENERATED: jquery.min.js */
vendor: 89,475 bytes, lines 3-4
3/*! jQuery v3.5.1 | (c) JS Foundation and other contributors | jquery.org/license */ 4!function(e,t){"use strict";"object"==typeof module&&"object"==typeof module.exports?module.exports=e.document?t(e,!0):function(e){if(!e.document)throw new Error("jQuery requires a window with a document");return t(e)}:t(e)}("undefined"!=typeof window?window:this,function(C,e){"use strict";var t=[],r=Object.getPrototypeOf,s=t.slice,g=t.flat?function(e){return t.flat.call(e)}:function(e){return t.concat.apply([],e)},u=t.push,i=t.indexOf,n={},o=n.toString,v=n.hasOwnProperty,a=v.toString,l=a.call(Object),y={},m=function(e){return"function"==typeof e&&"number"!=typeof e.nodeType},x=function(e){return null!=e&&e===e.window},E=C.document,c={type:!0,src:!0,nonce:!0,noModule:!0};function b(e,t,n){var r,i,o=(n=n||E).createElement("script");if(o.text=e,t)for(r in c)(i=t[r]||t.getAttribute&&t.getAttribute(r))&&o.setAttribute(r,i);n.head.appendChild(o).parentNode.removeChild(o)}function w(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?n[o.call(e)]||"object":typeof e}var f="3.5.1",S=function(e,t){return new S.fn.init(e,t)};function p(e){var t=!!e&&"length"in e&&e.length,n=w(e);return!m(e)&&!x(e)&&("array"===n||0===t||"number"==typeof t&&0<t&&t-1 in e)}S.fn=S.prototype={jquery:f,constructor:S,length:0,toArray:function(){return s.call(this)},get:function(e){return null==e?s.call(this):e<0?this[e+this.length]:this[e]},pushStack:function(e){var t=S.merge(this.constructor(),e);return t.prevObject=this,t},each:function(e){return S.each(this,e)},map:function(n){return this.pushStack(S.map(this,function(e,t){return n.call(e,t,e)}))},slice:function(){return this.pushStack(s.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},even:function(){return this.pushStack(S.grep(this,function(e,t){return(t+1)%2}))},odd:function(){return this.pushStack(S.grep(this,function(e,t){return t%2}))},eq:function(e){var t=this.length,n=+e+(e<0?t:0);return this.pushStack(0<=n&&n<t?[this[n]]:[])},end:function(){return this.prevObject||this.constructor()},push:u,sort:t.sort,splice:t.splice},S.extend=S.fn.extend=function(){var e,t,n,r,i,o,a=arguments[0]||{},s=1,u=arguments.length,l=!1;for("boolean"==typeof a&&(l=a,a=arguments[s]||{},s++),"object"==typeof a||m(a)||(a={}),s===u&&(a=this,s--);s<u;s++)if(null!=(e=arguments[s]))for(t in e)r=e[t],"__proto__"!==t&&a!==r&&(l&&r&&(S.isPlainObject(r)||(i=Array.isArray(r)))?(n=a[t],o=i&&!Array.isArray(n)?[]:i||S.isPlainObject(n)?n:{},i=!1,a[t]=S.extend(l,o,r)):void 0!==r&&(a[t]=r));return a},S.extend({expando:"jQuery"+(f+Math.random()).replace(/\D/g,""),isReady:!0,error:function(e){throw new Error(e)},noop:function(){},isPlainObject:function(e){var t,n;return!(!e||"[object Object]"!==o.call(e))&&(!(t=r(e))||"function"==typeof(n=v.call(t,"constructor")&&t.constructor)&&a.call(n)===l)},isEmptyObject:function(e){var t;for(t in e)return!1;return!0},globalEval:function(e,t,n){b(e,{nonce:t&&t.nonce},n)},each:function(e,t){var n,r=0;if(p(e)){for(n=e.length;r<n;r++)if(!1===t.call(e[r],r,e[r]))break}else for(r in e)if(!1===t.call(e[r],r,e[r]))break;return e},makeArray:function(e,t){var n=t||[];return null!=e&&(p(Object(e))?S.merge(n,"string"==typeof e?[e]:e):u.call(n,e)),n},inArray:function(e,t,n){return null==t?-1:i.call(t,e,n)},merge:function(e,t){for(var n=+t.length,r=0,i=e.length;r<n;r++)e[i++]=t[r];return e.length=i,e},grep:function(e,t,n){for(var r=[],i=0,o=e.length,a=!n;i<o;i++)!t(e[i],i)!==a&&r.push(e[i]);return r},map:function(e,t,n){var r,i,o=0,a=[];if(p(e))for(r=e.length;o<r;o++)null!=(i=t(e[o],o,n))&&a.push(i);else for(o in e)null!=(i=t(e[o],o,n))&&a.push(i);return g(a)},guid:1,support:y}),"function"==typeof Symbol&&(S.fn[Symbol.iterator]=t[Symbol.iterator]),S.each("Boolean Number String Function Array Date RegExp Object Error Symbol".split(" "),function(e,t){n["[object "+t+"]"]=t.toLowerCase()});var d=function(n){var e,d,b,o,i,h,f,g,w,u,l,T,C,a,E,v,s,c,y,S="sizzle"+1*new Date,p=n.document,k=0,r=0,m=ue(),x=ue(),A=ue(),N=ue(),D=function(e,t){return e===t&&(l=!0),0},j={}.hasOwnProperty,t=[],q=t.pop,L=t.push,H=t.push,O=t.slice,P=function(e,t){for(var n=0,r=e.length;n<r;n++)if(e[n]===t)return n;return-1},R="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",M="[\\x20\\t\\r\\n\\f]",I="(?:\\\\[\\da-fA-F]{1,6}"+M+"?|\\\\[^\\r\\n\\f]|[\\w-]|[^\0-\\x7f])+",W="\\["+M+"*("+I+")(?:"+M+"*([*^$|!~]?=)"+M+"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|("+I+"))|)"+M+"*\\]",F=":("+I+")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|"+W+")*)|.*)\\)|)",B=new RegExp(M+"+","g"),$=new RegExp("^"+M+"+|((?:^|[^\\\\])(?:\\\\.)*)"+M+"+$","g"),_=new RegExp("^"+M+"*,"+M+"*"),z=new RegExp("^"+M+"*([>+~]|"+M+")"+M+"*"),U=new RegExp(M+"|>"),X=new RegExp(F),V=new RegExp("^"+I+"$"),G={ID:new RegExp("^#("+I+")"),CLASS:new RegExp("^\\.("+I+")"),TAG:new RegExp("^("+I+"|[*])"),ATTR:new RegExp("^"+W),PSEUDO:new RegExp("^"+F),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+M+"*(even|odd|(([+-]|)(\\d*)n|)"+M+"*(?:([+-]|)"+M+"*(\\d+)|))"+M+"*\\)|)","i"),bool:new RegExp("^(?:"+R+")$","i"),needsContext:new RegExp("^"+M+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+M+"*((?:-\\d)?\\d*)"+M+"*\\)|)(?=[^-]|$)","i")},Y=/HTML$/i,Q=/^(?:input|select|textarea|button)$/i,J=/^h\d$/i,K=/^[^{]+\{\s*\[native \w/,Z=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,ee=/[+~]/,te=new RegExp("\\\\[\\da-fA-F]{1,6}"+M+"?|\\\\([^\\r\\n\\f])","g"),ne=function(e,t){var n="0x"+e.slice(1)-65536;return t||(n<0?String.fromCharCode(n+65536):String.fromCharCode(n>>10|55296,1023&n|56320))},re=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\0-\x1f\x7f-\uFFFF\w-]/g,ie=function(e,t){return t?"\0"===e?"\ufffd":e.slice(0,-1)+"\\"+e.charCodeAt(e.length-1).toString(16)+" ":"\\"+e},oe=function(){T()},ae=be(function(e){return!0===e.disabled&&"fieldset"===e.nodeName.toLowerCase()},{dir:"parentNode",next:"legend"});try{H.apply(t=O.call(p.childNodes),p.childNodes),t[p.childNodes.length].nodeType}catch(e){H={apply:t.length?function(e,t){L.apply(e,O.call(t))}:function(e,t){var n=e.length,r=0;while(e[n++]=t[r++]);e.length=n-1}}}function se(t,e,n,r){var i,o,a,s,u,l,c,f=e&&e.ownerDocument,p=e?e.nodeType:9;if(n=n||[],"string"!=typeof t||!t||1!==p&&9!==p&&11!==p)return n;if(!r&&(T(e),e=e||C,E)){if(11!==p&&(u=Z.exec(t)))if(i=u[1]){if(9===p){if(!(a=e.getElementById(i)))return n;if(a.id===i)return n.push(a),n}else if(f&&(a=f.getElementById(i))&&y(e,a)&&a.id===i)return n.push(a),n}else{if(u[2])return H.apply(n,e.getElementsByTagName(t)),n;if((i=u[3])&&d.getElementsByClassName&&e.getElementsByClassName)return H.apply(n,e.getElementsByClassName(i)),n}if(d.qsa&&!N[t+" "]&&(!v||!v.test(t))&&(1!==p||"object"!==e.nodeName.toLowerCase())){if(c=t,f=e,1===p&&(U.test(t)||z.test(t))){(f=ee.test(t)&&ye(e.parentNode)||e)===e&&d.scope||((s=e.getAttribute("id"))?s=s.replace(re,ie):e.setAttribute("id",s=S)),o=(l=h(t)).length;while(o--)l[o]=(s?"#"+s:":scope")+" "+xe(l[o]);c=l.join(",")}try{return H.apply(n,f.querySelectorAll(c)),n}catch(e){N(t,!0)}finally{s===S&&e.removeAttribute("id")}}}return g(t.replace($,"$1"),e,n,r)}function ue(){var r=[];return function e(t,n){return r.push(t+" ")>b.cacheLength&&delete e[r.shift()],e[t+" "]=n}}function le(e){return e[S]=!0,e}function ce(e){var t=C.createElement("fieldset");try{return!!e(t)}catch(e){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function fe(e,t){var n=e.split("|"),r=n.length;while(r--)b.attrHandle[n[r]]=t}function pe(e,t){var n=t&&e,r=n&&1===e.nodeType&&1===t.nodeType&&e.sourceIndex-t.sourceIndex;if(r)return r;if(n)while(n=n.nextSibling)if(n===t)return-1;return e?1:-1}function de(t){return function(e){return"input"===e.nodeName.toLowerCase()&&e.type===t}}function he(n){return function(e){var t=e.nodeName.toLowerCase();return("input"===t||"button"===t)&&e.type===n}}function ge(t){return function(e){return"form"in e?e.parentNode&&!1===e.disabled?"label"in e?"label"in e.parentNode?e.parentNode.disabled===t:e.disabled===t:e.isDisabled===t||e.isDisabled!==!t&&ae(e)===t:e.disabled===t:"label"in e&&e.disabled===t}}function ve(a){return le(function(o){return o=+o,le(function(e,t){var n,r=a([],e.length,o),i=r.length;while(i--)e[n=r[i]]&&(e[n]=!(t[n]=e[n]))})})}function ye(e){return e&&"undefined"!=typeof e.getElementsByTagName&&e}for(e in d=se.support={},i=se.isXML=function(e){var t=e.namespaceURI,n=(e.ownerDocument||e).documentElement;return!Y.test(t||n&&n.nodeName||"HTML")},T=se.setDocument=function(e){var t,n,r=e?e.ownerDocument||e:p;return r!=C&&9===r.nodeType&&r.documentElement&&(a=(C=r).documentElement,E=!i(C),p!=C&&(n=C.defaultView)&&n.top!==n&&(n.addEventListener?n.addEventListener("unload",oe,!1):n.attachEvent&&n.attachEvent("onunload",oe)),d.scope=ce(function(e){return a.appendChild(e).appendChild(C.createElement("div")),"undefined"!=typeof e.querySelectorAll&&!e.querySelectorAll(":scope fieldset div").length}),d.attributes=ce(function(e){return e.className="i",!e.getAttribute("className")}),d.getElementsByTagName=ce(function(e){return e.appendChild(C.createComment("")),!e.getElementsByTagName("*").length}),d.getElementsByClassName=K.test(C.getElementsByClassName),d.getById=ce(function(e){return a.appendChild(e).id=S,!C.getElementsByName||!C.getElementsByName(S).length}),d.getById?(b.filter.ID=function(e){var t=e.replace(te,ne);return function(e){return e.getAttribute("id")===t}},b.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&E){var n=t.getElementById(e);return n?[n]:[]}}):(b.filter.ID=function(e){var n=e.replace(te,ne);return function(e){var t="undefined"!=typeof e.getAttributeNode&&e.getAttributeNode("id");return t&&t.value===n}},b.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&E){var n,r,i,o=t.getElementById(e);if(o){if((n=o.getAttributeNode("id"))&&n.value===e)return[o];i=t.getElementsByName(e),r=0;while(o=i[r++])if((n=o.getAttributeNode("id"))&&n.value===e)return[o]}return[]}}),b.find.TAG=d.getElementsByTagName?function(e,t){return"undefined"!=typeof t.getElementsByTagName?t.getElementsByTagName(e):d.qsa?t.querySelectorAll(e):void 0}:function(e,t){var n,r=[],i=0,o=t.getElementsByTagName(e);if("*"===e){while(n=o[i++])1===n.nodeType&&r.push(n);return r}return o},b.find.CLASS=d.getElementsByClassName&&function(e,t){if("undefined"!=typeof t.getElementsByClassName&&E)return t.getElementsByClassName(e)},s=[],v=[],(d.qsa=K.test(C.querySelectorAll))&&(ce(function(e){var t;a.appendChild(e).innerHTML="<a id='"+S+"'></a><select id='"+S+"-\r\\' msallowcapture=''><option selected=''></option></select>",e.querySelectorAll("[msallowcapture^='']").length&&v.push("[*^$]="+M+"*(?:''|\"\")"),e.querySelectorAll("[selected]").length||v.push("\\["+M+"*(?:value|"+R+")"),e.querySelectorAll("[id~="+S+"-]").length||v.push("~="),(t=C.createElement("input")).setAttribute("name",""),e.appendChild(t),e.querySelectorAll("[name='']").length||v.push("\\["+M+"*name"+M+"*="+M+"*(?:''|\"\")"),e.querySelectorAll(":checked").length||v.push(":checked"),e.querySelectorAll("a#"+S+"+*").length||v.push(".#.+[+~]"),e.querySelectorAll("\\\f"),v.push("[\\r\\n\\f]")}),ce(function(e){e.innerHTML="<a href='' disabled='disabled'></a><select disabled='disabled'><option/></select>";var t=C.createElement("input");t.setAttribute("type","hidden"),e.appendChild(t).setAttribute("name","D"),e.querySelectorAll("[name=d]").length&&v.push("name"+M+"*[*^$|!~]?="),2!==e.querySelectorAll(":enabled").length&&v.push(":enabled",":disabled"),a.appendChild(e).disabled=!0,2!==e.querySelectorAll(":disabled").length&&v.push(":enabled",":disabled"),e.querySelectorAll("*,:x"),v.push(",.*:")})),(d.matchesSelector=K.test(c=a.matches||a.webkitMatchesSelector||a.mozMatchesSelector||a.oMatchesSelector||a.msMatchesSelector))&&ce(function(e){d.disconnectedMatch=c.call(e,"*"),c.call(e,"[s!='']:x"),s.push("!=",F)}),v=v.length&&new RegExp(v.join("|")),s=s.length&&new RegExp(s.join("|")),t=K.test(a.compareDocumentPosition),y=t||K.test(a.contains)?function(e,t){var n=9===e.nodeType?e.documentElement:e,r=t&&t.parentNode;return e===r||!(!r||1!==r.nodeType||!(n.contains?n.contains(r):e.compareDocumentPosition&&16&e.compareDocumentPosition(r)))}:function(e,t){if(t)while(t=t.parentNode)if(t===e)return!0;return!1},D=t?function(e,t){if(e===t)return l=!0,0;var n=!e.compareDocumentPosition-!t.compareDocumentPosition;return n||(1&(n=(e.ownerDocument||e)==(t.ownerDocument||t)?e.compareDocumentPosition(t):1)||!d.sortDetached&&t.compareDocumentPosition(e)===n?e==C||e.ownerDocument==p&&y(p,e)?-1:t==C||t.ownerDocument==p&&y(p,t)?1:u?P(u,e)-P(u,t):0:4&n?-1:1)}:function(e,t){if(e===t)return l=!0,0;var n,r=0,i=e.parentNode,o=t.parentNode,a=[e],s=[t];if(!i||!o)return e==C?-1:t==C?1:i?-1:o?1:u?P(u,e)-P(u,t):0;if(i===o)return pe(e,t);n=e;while(n=n.parentNode)a.unshift(n);n=t;while(n=n.parentNode)s.unshift(n);while(a[r]===s[r])r++;return r?pe(a[r],s[r]):a[r]==p?-1:s[r]==p?1:0}),C},se.matches=function(e,t){return se(e,null,null,t)},se.matchesSelector=function(e,t){if(T(e),d.matchesSelector&&E&&!N[t+" "]&&(!s||!s.test(t))&&(!v||!v.test(t)))try{var n=c.call(e,t);if(n||d.disconnectedMatch||e.document&&11!==e.document.nodeType)return n}catch(e){N(t,!0)}return 0<se(t,C,null,[e]).length},se.contains=function(e,t){return(e.ownerDocument||e)!=C&&T(e),y(e,t)},se.attr=function(e,t){(e.ownerDocument||e)!=C&&T(e);var n=b.attrHandle[t.toLowerCase()],r=n&&j.call(b.attrHandle,t.toLowerCase())?n(e,t,!E):void 0;return void 0!==r?r:d.attributes||!E?e.getAttribute(t):(r=e.getAttributeNode(t))&&r.specified?r.value:null},se.escape=function(e){return(e+"").replace(re,ie)},se.error=function(e){throw new Error("Syntax error, unrecognized expression: "+e)},se.uniqueSort=function(e){var t,n=[],r=0,i=0;if(l=!d.detectDuplicates,u=!d.sortStable&&e.slice(0),e.sort(D),l){while(t=e[i++])t===e[i]&&(r=n.push(i));while(r--)e.splice(n[r],1)}return u=null,e},o=se.getText=function(e){var t,n="",r=0,i=e.nodeType;if(i){if(1===i||9===i||11===i){if("string"==typeof e.textContent)return e.textContent;for(e=e.firstChild;e;e=e.nextSibling)n+=o(e)}else if(3===i||4===i)return e.nodeValue}else while(t=e[r++])n+=o(t);return n},(b=se.selectors={cacheLength:50,createPseudo:le,match:G,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(te,ne),e[3]=(e[3]||e[4]||e[5]||"").replace(te,ne),"~="===e[2]&&(e[3]=" "+e[3]+" "),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),"nth"===e[1].slice(0,3)?(e[3]||se.error(e[0]),e[4]=+(e[4]?e[5]+(e[6]||1):2*("even"===e[3]||"odd"===e[3])),e[5]=+(e[7]+e[8]||"odd"===e[3])):e[3]&&se.error(e[0]),e},PSEUDO:function(e){var t,n=!e[6]&&e[2];return G.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||"":n&&X.test(n)&&(t=h(n,!0))&&(t=n.indexOf(")",n.length-t)-n.length)&&(e[0]=e[0].slice(0,t),e[2]=n.slice(0,t)),e.slice(0,3))}},filter:{TAG:function(e){var t=e.replace(te,ne).toLowerCase();return"*"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=m[e+" "];return t||(t=new RegExp("(^|"+M+")"+e+"("+M+"|$)"))&&m(e,function(e){return t.test("string"==typeof e.className&&e.className||"undefined"!=typeof e.getAttribute&&e.getAttribute("class")||"")})},ATTR:function(n,r,i){return function(e){var t=se.attr(e,n);return null==t?"!="===r:!r||(t+="","="===r?t===i:"!="===r?t!==i:"^="===r?i&&0===t.indexOf(i):"*="===r?i&&-1<t.indexOf(i):"$="===r?i&&t.slice(-i.length)===i:"~="===r?-1<(" "+t.replace(B," ")+" ").indexOf(i):"|="===r&&(t===i||t.slice(0,i.length+1)===i+"-"))}},CHILD:function(h,e,t,g,v){var y="nth"!==h.slice(0,3),m="last"!==h.slice(-4),x="of-type"===e;return 1===g&&0===v?function(e){return!!e.parentNode}:function(e,t,n){var r,i,o,a,s,u,l=y!==m?"nextSibling":"previousSibling",c=e.parentNode,f=x&&e.nodeName.toLowerCase(),p=!n&&!x,d=!1;if(c){if(y){while(l){a=e;while(a=a[l])if(x?a.nodeName.toLowerCase()===f:1===a.nodeType)return!1;u=l="only"===h&&!u&&"nextSibling"}return!0}if(u=[m?c.firstChild:c.lastChild],m&&p){d=(s=(r=(i=(o=(a=c)[S]||(a[S]={}))[a.uniqueID]||(o[a.uniqueID]={}))[h]||[])[0]===k&&r[1])&&r[2],a=s&&c.childNodes[s];while(a=++s&&a&&a[l]||(d=s=0)||u.pop())if(1===a.nodeType&&++d&&a===e){i[h]=[k,s,d];break}}else if(p&&(d=s=(r=(i=(o=(a=e)[S]||(a[S]={}))[a.uniqueID]||(o[a.uniqueID]={}))[h]||[])[0]===k&&r[1]),!1===d)while(a=++s&&a&&a[l]||(d=s=0)||u.pop())if((x?a.nodeName.toLowerCase()===f:1===a.nodeType)&&++d&&(p&&((i=(o=a[S]||(a[S]={}))[a.uniqueID]||(o[a.uniqueID]={}))[h]=[k,d]),a===e))break;return(d-=v)===g||d%g==0&&0<=d/g}}},PSEUDO:function(e,o){var t,a=b.pseudos[e]||b.setFilters[e.toLowerCase()]||se.error("unsupported pseudo: "+e);return a[S]?a(o):1<a.length?(t=[e,e,"",o],b.setFilters.hasOwnProperty(e.toLowerCase())?le(function(e,t){var n,r=a(e,o),i=r.length;while(i--)e[n=P(e,r[i])]=!(t[n]=r[i])}):function(e){return a(e,0,t)}):a}},pseudos:{not:le(function(e){var r=[],i=[],s=f(e.replace($,"$1"));return s[S]?le(function(e,t,n,r){var i,o=s(e,null,r,[]),a=e.length;while(a--)(i=o[a])&&(e[a]=!(t[a]=i))}):function(e,t,n){return r[0]=e,s(r,null,n,i),r[0]=null,!i.pop()}}),has:le(function(t){return function(e){return 0<se(t,e).length}}),contains:le(function(t){return t=t.replace(te,ne),function(e){return-1<(e.textContent||o(e)).indexOf(t)}}),lang:le(function(n){return V.test(n||"")||se.error("unsupported lang: "+n),n=n.replace(te,ne).toLowerCase(),function(e){var t;do{if(t=E?e.lang:e.getAttribute("xml:lang")||e.getAttribute("lang"))return(t=t.toLowerCase())===n||0===t.indexOf(n+"-")}while((e=e.parentNode)&&1===e.nodeType);return!1}}),target:function(e){var t=n.location&&n.location.hash;return t&&t.slice(1)===e.id},root:function(e){return e===a},focus:function(e){return e===C.activeElement&&(!C.hasFocus||C.hasFocus())&&!!(e.type||e.href||~e.tabIndex)},enabled:ge(!1),disabled:ge(!0),checked:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&!!e.checked||"option"===t&&!!e.selected},selected:function(e){return e.parentNode&&e.parentNode.selectedIndex,!0===e.selected},empty:function(e){for(e=e.firstChild;e;e=e.nextSibling)if(e.nodeType<6)return!1;return!0},parent:function(e){return!b.pseudos.empty(e)},header:function(e){return J.test(e.nodeName)},input:function(e){return Q.test(e.nodeName)},button:function(e){var t=e.nodeName.toLowerCase();return"input"===t&&"button"===e.type||"button"===t},text:function(e){var t;return"input"===e.nodeName.toLowerCase()&&"text"===e.type&&(null==(t=e.getAttribute("type"))||"text"===t.toLowerCase())},first:ve(function(){return[0]}),last:ve(function(e,t){return[t-1]}),eq:ve(function(e,t,n){return[n<0?n+t:n]}),even:ve(function(e,t){for(var n=0;n<t;n+=2)e.push(n);return e}),odd:ve(function(e,t){for(var n=1;n<t;n+=2)e.push(n);return e}),lt:ve(function(e,t,n){for(var r=n<0?n+t:t<n?t:n;0<=--r;)e.push(r);return e}),gt:ve(function(e,t,n){for(var r=n<0?n+t:n;++r<t;)e.push(r);return e})}}).pseudos.nth=b.pseudos.eq,{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})b.pseudos[e]=de(e);for(e in{submit:!0,reset:!0})b.pseudos[e]=he(e);function me(){}function xe(e){for(var t=0,n=e.length,r="";t<n;t++)r+=e[t].value;return r}function be(s,e,t){var u=e.dir,l=e.next,c=l||u,f=t&&"parentNode"===c,p=r++;return e.first?function(e,t,n){while(e=e[u])if(1===e.nodeType||f)return s(e,t,n);return!1}:function(e,t,n){var r,i,o,a=[k,p];if(n){while(e=e[u])if((1===e.nodeType||f)&&s(e,t,n))return!0}else while(e=e[u])if(1===e.nodeType||f)if(i=(o=e[S]||(e[S]={}))[e.uniqueID]||(o[e.uniqueID]={}),l&&l===e.nodeName.toLowerCase())e=e[u]||e;else{if((r=i[c])&&r[0]===k&&r[1]===p)return a[2]=r[2];if((i[c]=a)[2]=s(e,t,n))return!0}return!1}}function we(i){return 1<i.length?function(e,t,n){var r=i.length;while(r--)if(!i[r](e,t,n))return!1;return!0}:i[0]}function Te(e,t,n,r,i){for(var o,a=[],s=0,u=e.length,l=null!=t;s<u;s++)(o=e[s])&&(n&&!n(o,r,i)||(a.push(o),l&&t.push(s)));return a}function Ce(d,h,g,v,y,e){return v&&!v[S]&&(v=Ce(v)),y&&!y[S]&&(y=Ce(y,e)),le(function(e,t,n,r){var i,o,a,s=[],u=[],l=t.length,c=e||function(e,t,n){for(var r=0,i=t.length;r<i;r++)se(e,t[r],n);return n}(h||"*",n.nodeType?[n]:n,[]),f=!d||!e&&h?c:Te(c,s,d,n,r),p=g?y||(e?d:l||v)?[]:t:f;if(g&&g(f,p,n,r),v){i=Te(p,u),v(i,[],n,r),o=i.length;while(o--)(a=i[o])&&(p[u[o]]=!(f[u[o]]=a))}if(e){if(y||d){if(y){i=[],o=p.length;while(o--)(a=p[o])&&i.push(f[o]=a);y(null,p=[],i,r)}o=p.length;while(o--)(a=p[o])&&-1<(i=y?P(e,a):s[o])&&(e[i]=!(t[i]=a))}}else p=Te(p===t?p.splice(l,p.length):p),y?y(null,t,p,r):H.apply(t,p)})}function Ee(e){for(var i,t,n,r=e.length,o=b.relative[e[0].type],a=o||b.relative[" "],s=o?1:0,u=be(function(e){return e===i},a,!0),l=be(function(e){return-1<P(i,e)},a,!0),c=[function(e,t,n){var r=!o&&(n||t!==w)||((i=t).nodeType?u(e,t,n):l(e,t,n));return i=null,r}];s<r;s++)if(t=b.relative[e[s].type])c=[be(we(c),t)];else{if((t=b.filter[e[s].type].apply(null,e[s].matches))[S]){for(n=++s;n<r;n++)if(b.relative[e[n].type])break;return Ce(1<s&&we(c),1<s&&xe(e.slice(0,s-1).concat({value:" "===e[s-2].type?"*":""})).replace($,"$1"),t,s<n&&Ee(e.slice(s,n)),n<r&&Ee(e=e.slice(n)),n<r&&xe(e))}c.push(t)}return we(c)}return me.prototype=b.filters=b.pseudos,b.setFilters=new me,h=se.tokenize=function(e,t){var n,r,i,o,a,s,u,l=x[e+" "];if(l)return t?0:l.slice(0);a=e,s=[],u=b.preFilter;while(a){for(o in n&&!(r=_.exec(a))||(r&&(a=a.slice(r[0].length)||a),s.push(i=[])),n=!1,(r=z.exec(a))&&(n=r.shift(),i.push({value:n,type:r[0].replace($," ")}),a=a.slice(n.length)),b.filter)!(r=G[o].exec(a))||u[o]&&!(r=u[o](r))||(n=r.shift(),i.push({value:n,type:o,matches:r}),a=a.slice(n.length));if(!n)break}return t?a.length:a?se.error(e):x(e,s).slice(0)},f=se.compile=function(e,t){var n,v,y,m,x,r,i=[],o=[],a=A[e+" "];if(!a){t||(t=h(e)),n=t.length;while(n--)(a=Ee(t[n]))[S]?i.push(a):o.push(a);(a=A(e,(v=o,m=0<(y=i).length,x=0<v.length,r=function(e,t,n,r,i){var o,a,s,u=0,l="0",c=e&&[],f=[],p=w,d=e||x&&b.find.TAG("*",i),h=k+=null==p?1:Math.random()||.1,g=d.length;for(i&&(w=t==C||t||i);l!==g&&null!=(o=d[l]);l++){if(x&&o){a=0,t||o.ownerDocument==C||(T(o),n=!E);while(s=v[a++])if(s(o,t||C,n)){r.push(o);break}i&&(k=h)}m&&((o=!s&&o)&&u--,e&&c.push(o))}if(u+=l,m&&l!==u){a=0;while(s=y[a++])s(c,f,t,n);if(e){if(0<u)while(l--)c[l]||f[l]||(f[l]=q.call(r));f=Te(f)}H.apply(r,f),i&&!e&&0<f.length&&1<u+y.length&&se.uniqueSort(r)}return i&&(k=h,w=p),c},m?le(r):r))).selector=e}return a},g=se.select=function(e,t,n,r){var i,o,a,s,u,l="function"==typeof e&&e,c=!r&&h(e=l.selector||e);if(n=n||[],1===c.length){if(2<(o=c[0]=c[0].slice(0)).length&&"ID"===(a=o[0]).type&&9===t.nodeType&&E&&b.relative[o[1].type]){if(!(t=(b.find.ID(a.matches[0].replace(te,ne),t)||[])[0]))return n;l&&(t=t.parentNode),e=e.slice(o.shift().value.length)}i=G.needsContext.test(e)?0:o.length;while(i--){if(a=o[i],b.relative[s=a.type])break;if((u=b.find[s])&&(r=u(a.matches[0].replace(te,ne),ee.test(o[0].type)&&ye(t.parentNode)||t))){if(o.splice(i,1),!(e=r.length&&xe(o)))return H.apply(n,r),n;break}}}return(l||f(e,c))(r,t,!E,n,!t||ee.test(e)&&ye(t.parentNode)||t),n},d.sortStable=S.split("").sort(D).join("")===S,d.detectDuplicates=!!l,T(),d.sortDetached=ce(function(e){return 1&e.compareDocumentPosition(C.createElement("fieldset"))}),ce(function(e){return e.innerHTML="<a href='#'></a>","#"===e.firstChild.getAttribute("href")})||fe("type|href|height|width",function(e,t,n){if(!n)return e.getAttribute(t,"type"===t.toLowerCase()?1:2)}),d.attributes&&ce(function(e){return e.innerHTML="<input/>",e.firstChild.setAttribute("value",""),""===e.firstChild.getAttribute("value")})||fe("value",function(e,t,n){if(!n&&"input"===e.nodeName.toLowerCase())return e.defaultValue}),ce(function(e){return null==e.getAttribute("disabled")})||fe(R,function(e,t,n){var r;if(!n)return!0===e[t]?t.toLowerCase():(r=e.getAttributeNode(t))&&r.specified?r.value:null}),se}(C);S.find=d,S.expr=d.selectors,S.expr[":"]=S.expr.pseudos,S.uniqueSort=S.unique=d.uniqueSort,S.text=d.getText,S.isXMLDoc=d.isXML,S.contains=d.contains,S.escapeSelector=d.escape;var h=function(e,t,n){var r=[],i=void 0!==n;while((e=e[t])&&9!==e.nodeType)if(1===e.nodeType){if(i&&S(e).is(n))break;r.push(e)}return r},T=function(e,t){for(var n=[];e;e=e.nextSibling)1===e.nodeType&&e!==t&&n.push(e);return n},k=S.expr.match.needsContext;function A(e,t){return e.nodeName&&e.nodeName.toLowerCase()===t.toLowerCase()}var N=/^<([a-z][^\/\0>:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;function D(e,n,r){return m(n)?S.grep(e,function(e,t){return!!n.call(e,t,e)!==r}):n.nodeType?S.grep(e,function(e){return e===n!==r}):"string"!=typeof n?S.grep(e,function(e){return-1<i.call(n,e)!==r}):S.filter(n,e,r)}S.filter=function(e,t,n){var r=t[0];return n&&(e=":not("+e+")"),1===t.length&&1===r.nodeType?S.find.matchesSelector(r,e)?[r]:[]:S.find.matches(e,S.grep(t,function(e){return 1===e.nodeType}))},S.fn.extend({find:function(e){var t,n,r=this.length,i=this;if("string"!=typeof e)return this.pushStack(S(e).filter(function(){for(t=0;t<r;t++)if(S.contains(i[t],this))return!0}));for(n=this.pushStack([]),t=0;t<r;t++)S.find(e,i[t],n);return 1<r?S.uniqueSort(n):n},filter:function(e){return this.pushStack(D(this,e||[],!1))},not:function(e){return this.pushStack(D(this,e||[],!0))},is:function(e){return!!D(this,"string"==typeof e&&k.test(e)?S(e):e||[],!1).length}});var j,q=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]+))$/;(S.fn.init=function(e,t,n){var r,i;if(!e)return this;if(n=n||j,"string"==typeof e){if(!(r="<"===e[0]&&">"===e[e.length-1]&&3<=e.length?[null,e,null]:q.exec(e))||!r[1]&&t)return!t||t.jquery?(t||n).find(e):this.constructor(t).find(e);if(r[1]){if(t=t instanceof S?t[0]:t,S.merge(this,S.parseHTML(r[1],t&&t.nodeType?t.ownerDocument||t:E,!0)),N.test(r[1])&&S.isPlainObject(t))for(r in t)m(this[r])?this[r](t[r]):this.attr(r,t[r]);return this}return(i=E.getElementById(r[2]))&&(this[0]=i,this.length=1),this}return e.nodeType?(this[0]=e,this.length=1,this):m(e)?void 0!==n.ready?n.ready(e):e(S):S.makeArray(e,this)}).prototype=S.fn,j=S(E);var L=/^(?:parents|prev(?:Until|All))/,H={children:!0,contents:!0,next:!0,prev:!0};function O(e,t){while((e=e[t])&&1!==e.nodeType);return e}S.fn.extend({has:function(e){var t=S(e,this),n=t.length;return this.filter(function(){for(var e=0;e<n;e++)if(S.contains(this,t[e]))return!0})},closest:function(e,t){var n,r=0,i=this.length,o=[],a="string"!=typeof e&&S(e);if(!k.test(e))for(;r<i;r++)for(n=this[r];n&&n!==t;n=n.parentNode)if(n.nodeType<11&&(a?-1<a.index(n):1===n.nodeType&&S.find.matchesSelector(n,e))){o.push(n);break}return this.pushStack(1<o.length?S.uniqueSort(o):o)},index:function(e){return e?"string"==typeof e?i.call(S(e),this[0]):i.call(this,e.jquery?e[0]:e):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(e,t){return this.pushStack(S.uniqueSort(S.merge(this.get(),S(e,t))))},addBack:function(e){return this.add(null==e?this.prevObject:this.prevObject.filter(e))}}),S.each({parent:function(e){var t=e.parentNode;return t&&11!==t.nodeType?t:null},parents:function(e){return h(e,"parentNode")},parentsUntil:function(e,t,n){return h(e,"parentNode",n)},next:function(e){return O(e,"nextSibling")},prev:function(e){return O(e,"previousSibling")},nextAll:function(e){return h(e,"nextSibling")},prevAll:function(e){return h(e,"previousSibling")},nextUntil:function(e,t,n){return h(e,"nextSibling",n)},prevUntil:function(e,t,n){return h(e,"previousSibling",n)},siblings:function(e){return T((e.parentNode||{}).firstChild,e)},children:function(e){return T(e.firstChild)},contents:function(e){return null!=e.contentDocument&&r(e.contentDocument)?e.contentDocument:(A(e,"template")&&(e=e.content||e),S.merge([],e.childNodes))}},function(r,i){S.fn[r]=function(e,t){var n=S.map(this,i,e);return"Until"!==r.slice(-5)&&(t=e),t&&"string"==typeof t&&(n=S.filter(t,n)),1<this.length&&(H[r]||S.uniqueSort(n),L.test(r)&&n.reverse()),this.pushStack(n)}});var P=/[^\x20\t\r\n\f]+/g;function R(e){return e}function M(e){throw e}function I(e,t,n,r){var i;try{e&&m(i=e.promise)?i.call(e).done(t).fail(n):e&&m(i=e.then)?i.call(e,t,n):t.apply(void 0,[e].slice(r))}catch(e){n.apply(void 0,[e])}}S.Callbacks=function(r){var e,n;r="string"==typeof r?(e=r,n={},S.each(e.match(P)||[],function(e,t){n[t]=!0}),n):S.extend({},r);var i,t,o,a,s=[],u=[],l=-1,c=function(){for(a=a||r.once,o=i=!0;u.length;l=-1){t=u.shift();while(++l<s.length)!1===s[l].apply(t[0],t[1])&&r.stopOnFalse&&(l=s.length,t=!1)}r.memory||(t=!1),i=!1,a&&(s=t?[]:"")},f={add:function(){return s&&(t&&!i&&(l=s.length-1,u.push(t)),function n(e){S.each(e,function(e,t){m(t)?r.unique&&f.has(t)||s.push(t):t&&t.length&&"string"!==w(t)&&n(t)})}(arguments),t&&!i&&c()),this},remove:function(){return S.each(arguments,function(e,t){var n;while(-1<(n=S.inArray(t,s,n)))s.splice(n,1),n<=l&&l--}),this},has:function(e){return e?-1<S.inArray(e,s):0<s.length},empty:function(){return s&&(s=[]),this},disable:function(){return a=u=[],s=t="",this},disabled:function(){return!s},lock:function(){return a=u=[],t||i||(s=t=""),this},locked:function(){return!!a},fireWith:function(e,t){return a||(t=[e,(t=t||[]).slice?t.slice():t],u.push(t),i||c()),this},fire:function(){return f.fireWith(this,arguments),this},fired:function(){return!!o}};return f},S.extend({Deferred:function(e){var o=[["notify","progress",S.Callbacks("memory"),S.Callbacks("memory"),2],["resolve","done",S.Callbacks("once memory"),S.Callbacks("once memory"),0,"resolved"],["reject","fail",S.Callbacks("once memory"),S.Callbacks("once memory"),1,"rejected"]],i="pending",a={state:function(){return i},always:function(){return s.done(arguments).fail(arguments),this},"catch":function(e){return a.then(null,e)},pipe:function(){var i=arguments;return S.Deferred(function(r){S.each(o,function(e,t){var n=m(i[t[4]])&&i[t[4]];s[t[1]](function(){var e=n&&n.apply(this,arguments);e&&m(e.promise)?e.promise().progress(r.notify).done(r.resolve).fail(r.reject):r[t[0]+"With"](this,n?[e]:arguments)})}),i=null}).promise()},then:function(t,n,r){var u=0;function l(i,o,a,s){return function(){var n=this,r=arguments,e=function(){var e,t;if(!(i<u)){if((e=a.apply(n,r))===o.promise())throw new TypeError("Thenable self-resolution");t=e&&("object"==typeof e||"function"==typeof e)&&e.then,m(t)?s?t.call(e,l(u,o,R,s),l(u,o,M,s)):(u++,t.call(e,l(u,o,R,s),l(u,o,M,s),l(u,o,R,o.notifyWith))):(a!==R&&(n=void 0,r=[e]),(s||o.resolveWith)(n,r))}},t=s?e:function(){try{e()}catch(e){S.Deferred.exceptionHook&&S.Deferred.exceptionHook(e,t.stackTrace),u<=i+1&&(a!==M&&(n=void 0,r=[e]),o.rejectWith(n,r))}};i?t():(S.Deferred.getStackHook&&(t.stackTrace=S.Deferred.getStackHook()),C.setTimeout(t))}}return S.Deferred(function(e){o[0][3].add(l(0,e,m(r)?r:R,e.notifyWith)),o[1][3].add(l(0,e,m(t)?t:R)),o[2][3].add(l(0,e,m(n)?n:M))}).promise()},promise:function(e){return null!=e?S.extend(e,a):a}},s={};return S.each(o,function(e,t){var n=t[2],r=t[5];a[t[1]]=n.add,r&&n.add(function(){i=r},o[3-e][2].disable,o[3-e][3].disable,o[0][2].lock,o[0][3].lock),n.add(t[3].fire),s[t[0]]=function(){return s[t[0]+"With"](this===s?void 0:this,arguments),this},s[t[0]+"With"]=n.fireWith}),a.promise(s),e&&e.call(s,s),s},when:function(e){var n=arguments.length,t=n,r=Array(t),i=s.call(arguments),o=S.Deferred(),a=function(t){return function(e){r[t]=this,i[t]=1<arguments.length?s.call(arguments):e,--n||o.resolveWith(r,i)}};if(n<=1&&(I(e,o.done(a(t)).resolve,o.reject,!n),"pending"===o.state()||m(i[t]&&i[t].then)))return o.then();while(t--)I(i[t],a(t),o.reject);return o.promise()}});var W=/^(Eval|Internal|Range|Reference|Syntax|Type|URI)Error$/;S.Deferred.exceptionHook=function(e,t){C.console&&C.console.warn&&e&&W.test(e.name)&&C.console.warn("jQuery.Deferred exception: "+e.message,e.stack,t)},S.readyException=function(e){C.setTimeout(function(){throw e})};var F=S.Deferred();function B(){E.removeEventListener("DOMContentLoaded",B),C.removeEventListener("load",B),S.ready()}S.fn.ready=function(e){return F.then(e)["catch"](function(e){S.readyException(e)}),this},S.extend({isReady:!1,readyWait:1,ready:function(e){(!0===e?--S.readyWait:S.isReady)||(S.isReady=!0)!==e&&0<--S.readyWait||F.resolveWith(E,[S])}}),S.ready.then=F.then,"complete"===E.readyState||"loading"!==E.readyState&&!E.documentElement.doScroll?C.setTimeout(S.ready):(E.addEventListener("DOMContentLoaded",B),C.addEventListener("load",B));var $=function(e,t,n,r,i,o,a){var s=0,u=e.length,l=null==n;if("object"===w(n))for(s in i=!0,n)$(e,t,s,n[s],!0,o,a);else if(void 0!==r&&(i=!0,m(r)||(a=!0),l&&(a?(t.call(e,r),t=null):(l=t,t=function(e,t,n){return l.call(S(e),n)})),t))for(;s<u;s++)t(e[s],n,a?r:r.call(e[s],s,t(e[s],n)));return i?e:l?t.call(e):u?t(e[0],n):o},_=/^-ms-/,z=/-([a-z])/g;function U(e,t){return t.toUpperCase()}function X(e){return e.replace(_,"ms-").replace(z,U)}var V=function(e){return 1===e.nodeType||9===e.nodeType||!+e.nodeType};function G(){this.expando=S.expando+G.uid++}G.uid=1,G.prototype={cache:function(e){var t=e[this.expando];return t||(t={},V(e)&&(e.nodeType?e[this.expando]=t:Object.defineProperty(e,this.expando,{value:t,configurable:!0}))),t},set:function(e,t,n){var r,i=this.cache(e);if("string"==typeof t)i[X(t)]=n;else for(r in t)i[X(r)]=t[r];return i},get:function(e,t){return void 0===t?this.cache(e):e[this.expando]&&e[this.expando][X(t)]},access:function(e,t,n){return void 0===t||t&&"string"==typeof t&&void 0===n?this.get(e,t):(this.set(e,t,n),void 0!==n?n:t)},remove:function(e,t){var n,r=e[this.expando];if(void 0!==r){if(void 0!==t){n=(t=Array.isArray(t)?t.map(X):(t=X(t))in r?[t]:t.match(P)||[]).length;while(n--)delete r[t[n]]}(void 0===t||S.isEmptyObject(r))&&(e.nodeType?e[this.expando]=void 0:delete e[this.expando])}},hasData:function(e){var t=e[this.expando];return void 0!==t&&!S.isEmptyObject(t)}};var Y=new G,Q=new G,J=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,K=/[A-Z]/g;function Z(e,t,n){var r,i;if(void 0===n&&1===e.nodeType)if(r="data-"+t.replace(K,"-$&").toLowerCase(),"string"==typeof(n=e.getAttribute(r))){try{n="true"===(i=n)||"false"!==i&&("null"===i?null:i===+i+""?+i:J.test(i)?JSON.parse(i):i)}catch(e){}Q.set(e,t,n)}else n=void 0;return n}S.extend({hasData:function(e){return Q.hasData(e)||Y.hasData(e)},data:function(e,t,n){return Q.access(e,t,n)},removeData:function(e,t){Q.remove(e,t)},_data:function(e,t,n){return Y.access(e,t,n)},_removeData:function(e,t){Y.remove(e,t)}}),S.fn.extend({data:function(n,e){var t,r,i,o=this[0],a=o&&o.attributes;if(void 0===n){if(this.length&&(i=Q.get(o),1===o.nodeType&&!Y.get(o,"hasDataAttrs"))){t=a.length;while(t--)a[t]&&0===(r=a[t].name).indexOf("data-")&&(r=X(r.slice(5)),Z(o,r,i[r]));Y.set(o,"hasDataAttrs",!0)}return i}return"object"==typeof n?this.each(function(){Q.set(this,n)}):$(this,function(e){var t;if(o&&void 0===e)return void 0!==(t=Q.get(o,n))?t:void 0!==(t=Z(o,n))?t:void 0;this.each(function(){Q.set(this,n,e)})},null,e,1<arguments.length,null,!0)},removeData:function(e){return this.each(function(){Q.remove(this,e)})}}),S.extend({queue:function(e,t,n){var r;if(e)return t=(t||"fx")+"queue",r=Y.get(e,t),n&&(!r||Array.isArray(n)?r=Y.access(e,t,S.makeArray(n)):r.push(n)),r||[]},dequeue:function(e,t){t=t||"fx";var n=S.queue(e,t),r=n.length,i=n.shift(),o=S._queueHooks(e,t);"inprogress"===i&&(i=n.shift(),r--),i&&("fx"===t&&n.unshift("inprogress"),delete o.stop,i.call(e,function(){S.dequeue(e,t)},o)),!r&&o&&o.empty.fire()},_queueHooks:function(e,t){var n=t+"queueHooks";return Y.get(e,n)||Y.access(e,n,{empty:S.Callbacks("once memory").add(function(){Y.remove(e,[t+"queue",n])})})}}),S.fn.extend({queue:function(t,n){var e=2;return"string"!=typeof t&&(n=t,t="fx",e--),arguments.length<e?S.queue(this[0],t):void 0===n?this:this.each(function(){var e=S.queue(this,t,n);S._queueHooks(this,t),"fx"===t&&"inprogress"!==e[0]&&S.dequeue(this,t)})},dequeue:function(e){return this.each(function(){S.dequeue(this,e)})},clearQueue:function(e){return this.queue(e||"fx",[])},promise:function(e,t){var n,r=1,i=S.Deferred(),o=this,a=this.length,s=function(){--r||i.resolveWith(o,[o])};"string"!=typeof e&&(t=e,e=void 0),e=e||"fx";while(a--)(n=Y.get(o[a],e+"queueHooks"))&&n.empty&&(r++,n.empty.add(s));return s(),i.promise(t)}});var ee=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,te=new RegExp("^(?:([+-])=|)("+ee+")([a-z%]*)$","i"),ne=["Top","Right","Bottom","Left"],re=E.documentElement,ie=function(e){return S.contains(e.ownerDocument,e)},oe={composed:!0};re.getRootNode&&(ie=function(e){return S.contains(e.ownerDocument,e)||e.getRootNode(oe)===e.ownerDocument});var ae=function(e,t){return"none"===(e=t||e).style.display||""===e.style.display&&ie(e)&&"none"===S.css(e,"display")};function se(e,t,n,r){var i,o,a=20,s=r?function(){return r.cur()}:function(){return S.css(e,t,"")},u=s(),l=n&&n[3]||(S.cssNumber[t]?"":"px"),c=e.nodeType&&(S.cssNumber[t]||"px"!==l&&+u)&&te.exec(S.css(e,t));if(c&&c[3]!==l){u/=2,l=l||c[3],c=+u||1;while(a--)S.style(e,t,c+l),(1-o)*(1-(o=s()/u||.5))<=0&&(a=0),c/=o;c*=2,S.style(e,t,c+l),n=n||[]}return n&&(c=+c||+u||0,i=n[1]?c+(n[1]+1)*n[2]:+n[2],r&&(r.unit=l,r.start=c,r.end=i)),i}var ue={};function le(e,t){for(var n,r,i,o,a,s,u,l=[],c=0,f=e.length;c<f;c++)(r=e[c]).style&&(n=r.style.display,t?("none"===n&&(l[c]=Y.get(r,"display")||null,l[c]||(r.style.display="")),""===r.style.display&&ae(r)&&(l[c]=(u=a=o=void 0,a=(i=r).ownerDocument,s=i.nodeName,(u=ue[s])||(o=a.body.appendChild(a.createElement(s)),u=S.css(o,"display"),o.parentNode.removeChild(o),"none"===u&&(u="block"),ue[s]=u)))):"none"!==n&&(l[c]="none",Y.set(r,"display",n)));for(c=0;c<f;c++)null!=l[c]&&(e[c].style.display=l[c]);return e}S.fn.extend({show:function(){return le(this,!0)},hide:function(){return le(this)},toggle:function(e){return"boolean"==typeof e?e?this.show():this.hide():this.each(function(){ae(this)?S(this).show():S(this).hide()})}});var ce,fe,pe=/^(?:checkbox|radio)$/i,de=/<([a-z][^\/\0>\x20\t\r\n\f]*)/i,he=/^$|^module$|\/(?:java|ecma)script/i;ce=E.createDocumentFragment().appendChild(E.createElement("div")),(fe=E.createElement("input")).setAttribute("type","radio"),fe.setAttribute("checked","checked"),fe.setAttribute("name","t"),ce.appendChild(fe),y.checkClone=ce.cloneNode(!0).cloneNode(!0).lastChild.checked,ce.innerHTML="<textarea>x</textarea>",y.noCloneChecked=!!ce.cloneNode(!0).lastChild.defaultValue,ce.innerHTML="<option></option>",y.option=!!ce.lastChild;var ge={thead:[1,"<table>","</table>"],col:[2,"<table><colgroup>","</colgroup></table>"],tr:[2,"<table><tbody>","</tbody></table>"],td:[3,"<table><tbody><tr>","</tr></tbody></table>"],_default:[0,"",""]};function ve(e,t){var n;return n="undefined"!=typeof e.getElementsByTagName?e.getElementsByTagName(t||"*"):"undefined"!=typeof e.querySelectorAll?e.querySelectorAll(t||"*"):[],void 0===t||t&&A(e,t)?S.merge([e],n):n}function ye(e,t){for(var n=0,r=e.length;n<r;n++)Y.set(e[n],"globalEval",!t||Y.get(t[n],"globalEval"))}ge.tbody=ge.tfoot=ge.colgroup=ge.caption=ge.thead,ge.th=ge.td,y.option||(ge.optgroup=ge.option=[1,"<select multiple='multiple'>","</select>"]);var me=/<|&#?\w+;/;function xe(e,t,n,r,i){for(var o,a,s,u,l,c,f=t.createDocumentFragment(),p=[],d=0,h=e.length;d<h;d++)if((o=e[d])||0===o)if("object"===w(o))S.merge(p,o.nodeType?[o]:o);else if(me.test(o)){a=a||f.appendChild(t.createElement("div")),s=(de.exec(o)||["",""])[1].toLowerCase(),u=ge[s]||ge._default,a.innerHTML=u[1]+S.htmlPrefilter(o)+u[2],c=u[0];while(c--)a=a.lastChild;S.merge(p,a.childNodes),(a=f.firstChild).textContent=""}else p.push(t.createTextNode(o));f.textContent="",d=0;while(o=p[d++])if(r&&-1<S.inArray(o,r))i&&i.push(o);else if(l=ie(o),a=ve(f.appendChild(o),"script"),l&&ye(a),n){c=0;while(o=a[c++])he.test(o.type||"")&&n.push(o)}return f}var be=/^key/,we=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,Te=/^([^.]*)(?:\.(.+)|)/;function Ce(){return!0}function Ee(){return!1}function Se(e,t){return e===function(){try{return E.activeElement}catch(e){}}()==("focus"===t)}function ke(e,t,n,r,i,o){var a,s;if("object"==typeof t){for(s in"string"!=typeof n&&(r=r||n,n=void 0),t)ke(e,s,n,r,t[s],o);return e}if(null==r&&null==i?(i=n,r=n=void 0):null==i&&("string"==typeof n?(i=r,r=void 0):(i=r,r=n,n=void 0)),!1===i)i=Ee;else if(!i)return e;return 1===o&&(a=i,(i=function(e){return S().off(e),a.apply(this,arguments)}).guid=a.guid||(a.guid=S.guid++)),e.each(function(){S.event.add(this,t,i,r,n)})}function Ae(e,i,o){o?(Y.set(e,i,!1),S.event.add(e,i,{namespace:!1,handler:function(e){var t,n,r=Y.get(this,i);if(1&e.isTrigger&&this[i]){if(r.length)(S.event.special[i]||{}).delegateType&&e.stopPropagation();else if(r=s.call(arguments),Y.set(this,i,r),t=o(this,i),this[i](),r!==(n=Y.get(this,i))||t?Y.set(this,i,!1):n={},r!==n)return e.stopImmediatePropagation(),e.preventDefault(),n.value}else r.length&&(Y.set(this,i,{value:S.event.trigger(S.extend(r[0],S.Event.prototype),r.slice(1),this)}),e.stopImmediatePropagation())}})):void 0===Y.get(e,i)&&S.event.add(e,i,Ce)}S.event={global:{},add:function(t,e,n,r,i){var o,a,s,u,l,c,f,p,d,h,g,v=Y.get(t);if(V(t)){n.handler&&(n=(o=n).handler,i=o.selector),i&&S.find.matchesSelector(re,i),n.guid||(n.guid=S.guid++),(u=v.events)||(u=v.events=Object.create(null)),(a=v.handle)||(a=v.handle=function(e){return"undefined"!=typeof S&&S.event.triggered!==e.type?S.event.dispatch.apply(t,arguments):void 0}),l=(e=(e||"").match(P)||[""]).length;while(l--)d=g=(s=Te.exec(e[l])||[])[1],h=(s[2]||"").split(".").sort(),d&&(f=S.event.special[d]||{},d=(i?f.delegateType:f.bindType)||d,f=S.event.special[d]||{},c=S.extend({type:d,origType:g,data:r,handler:n,guid:n.guid,selector:i,needsContext:i&&S.expr.match.needsContext.test(i),namespace:h.join(".")},o),(p=u[d])||((p=u[d]=[]).delegateCount=0,f.setup&&!1!==f.setup.call(t,r,h,a)||t.addEventListener&&t.addEventListener(d,a)),f.add&&(f.add.call(t,c),c.handler.guid||(c.handler.guid=n.guid)),i?p.splice(p.delegateCount++,0,c):p.push(c),S.event.global[d]=!0)}},remove:function(e,t,n,r,i){var o,a,s,u,l,c,f,p,d,h,g,v=Y.hasData(e)&&Y.get(e);if(v&&(u=v.events)){l=(t=(t||"").match(P)||[""]).length;while(l--)if(d=g=(s=Te.exec(t[l])||[])[1],h=(s[2]||"").split(".").sort(),d){f=S.event.special[d]||{},p=u[d=(r?f.delegateType:f.bindType)||d]||[],s=s[2]&&new RegExp("(^|\\.)"+h.join("\\.(?:.*\\.|)")+"(\\.|$)"),a=o=p.length;while(o--)c=p[o],!i&&g!==c.origType||n&&n.guid!==c.guid||s&&!s.test(c.namespace)||r&&r!==c.selector&&("**"!==r||!c.selector)||(p.splice(o,1),c.selector&&p.delegateCount--,f.remove&&f.remove.call(e,c));a&&!p.length&&(f.teardown&&!1!==f.teardown.call(e,h,v.handle)||S.removeEvent(e,d,v.handle),delete u[d])}else for(d in u)S.event.remove(e,d+t[l],n,r,!0);S.isEmptyObject(u)&&Y.remove(e,"handle events")}},dispatch:function(e){var t,n,r,i,o,a,s=new Array(arguments.length),u=S.event.fix(e),l=(Y.get(this,"events")||Object.create(null))[u.type]||[],c=S.event.special[u.type]||{};for(s[0]=u,t=1;t<arguments.length;t++)s[t]=arguments[t];if(u.delegateTarget=this,!c.preDispatch||!1!==c.preDispatch.call(this,u)){a=S.event.handlers.call(this,u,l),t=0;while((i=a[t++])&&!u.isPropagationStopped()){u.currentTarget=i.elem,n=0;while((o=i.handlers[n++])&&!u.isImmediatePropagationStopped())u.rnamespace&&!1!==o.namespace&&!u.rnamespace.test(o.namespace)||(u.handleObj=o,u.data=o.data,void 0!==(r=((S.event.special[o.origType]||{}).handle||o.handler).apply(i.elem,s))&&!1===(u.result=r)&&(u.preventDefault(),u.stopPropagation()))}return c.postDispatch&&c.postDispatch.call(this,u),u.result}},handlers:function(e,t){var n,r,i,o,a,s=[],u=t.delegateCount,l=e.target;if(u&&l.nodeType&&!("click"===e.type&&1<=e.button))for(;l!==this;l=l.parentNode||this)if(1===l.nodeType&&("click"!==e.type||!0!==l.disabled)){for(o=[],a={},n=0;n<u;n++)void 0===a[i=(r=t[n]).selector+" "]&&(a[i]=r.needsContext?-1<S(i,this).index(l):S.find(i,this,null,[l]).length),a[i]&&o.push(r);o.length&&s.push({elem:l,handlers:o})}return l=this,u<t.length&&s.push({elem:l,handlers:t.slice(u)}),s},addProp:function(t,e){Object.defineProperty(S.Event.prototype,t,{enumerable:!0,configurable:!0,get:m(e)?function(){if(this.originalEvent)return e(this.originalEvent)}:function(){if(this.originalEvent)return this.originalEvent[t]},set:function(e){Object.defineProperty(this,t,{enumerable:!0,configurable:!0,writable:!0,value:e})}})},fix:function(e){return e[S.expando]?e:new S.Event(e)},special:{load:{noBubble:!0},click:{setup:function(e){var t=this||e;return pe.test(t.type)&&t.click&&A(t,"input")&&Ae(t,"click",Ce),!1},trigger:function(e){var t=this||e;return pe.test(t.type)&&t.click&&A(t,"input")&&Ae(t,"click"),!0},_default:function(e){var t=e.target;return pe.test(t.type)&&t.click&&A(t,"input")&&Y.get(t,"click")||A(t,"a")}},beforeunload:{postDispatch:function(e){void 0!==e.result&&e.originalEvent&&(e.originalEvent.returnValue=e.result)}}}},S.removeEvent=function(e,t,n){e.removeEventListener&&e.removeEventListener(t,n)},S.Event=function(e,t){if(!(this instanceof S.Event))return new S.Event(e,t);e&&e.type?(this.originalEvent=e,this.type=e.type,this.isDefaultPrevented=e.defaultPrevented||void 0===e.defaultPrevented&&!1===e.returnValue?Ce:Ee,this.target=e.target&&3===e.target.nodeType?e.target.parentNode:e.target,this.currentTarget=e.currentTarget,this.relatedTarget=e.relatedTarget):this.type=e,t&&S.extend(this,t),this.timeStamp=e&&e.timeStamp||Date.now(),this[S.expando]=!0},S.Event.prototype={constructor:S.Event,isDefaultPrevented:Ee,isPropagationStopped:Ee,isImmediatePropagationStopped:Ee,isSimulated:!1,preventDefault:function(){var e=this.originalEvent;this.isDefaultPrevented=Ce,e&&!this.isSimulated&&e.preventDefault()},stopPropagation:function(){var e=this.originalEvent;this.isPropagationStopped=Ce,e&&!this.isSimulated&&e.stopPropagation()},stopImmediatePropagation:function(){var e=this.originalEvent;this.isImmediatePropagationStopped=Ce,e&&!this.isSimulated&&e.stopImmediatePropagation(),this.stopPropagation()}},S.each({altKey:!0,bubbles:!0,cancelable:!0,changedTouches:!0,ctrlKey:!0,detail:!0,eventPhase:!0,metaKey:!0,pageX:!0,pageY:!0,shiftKey:!0,view:!0,"char":!0,code:!0,charCode:!0,key:!0,keyCode:!0,button:!0,buttons:!0,clientX:!0,clientY:!0,offsetX:!0,offsetY:!0,pointerId:!0,pointerType:!0,screenX:!0,screenY:!0,targetTouches:!0,toElement:!0,touches:!0,which:function(e){var t=e.button;return null==e.which&&be.test(e.type)?null!=e.charCode?e.charCode:e.keyCode:!e.which&&void 0!==t&&we.test(e.type)?1&t?1:2&t?3:4&t?2:0:e.which}},S.event.addProp),S.each({focus:"focusin",blur:"focusout"},function(e,t){S.event.special[e]={setup:function(){return Ae(this,e,Se),!1},trigger:function(){return Ae(this,e),!0},delegateType:t}}),S.each({mouseenter:"mouseover",mouseleave:"mouseout",pointerenter:"pointerover",pointerleave:"pointerout"},function(e,i){S.event.special[e]={delegateType:i,bindType:i,handle:function(e){var t,n=e.relatedTarget,r=e.handleObj;return n&&(n===this||S.contains(this,n))||(e.type=r.origType,t=r.handler.apply(this,arguments),e.type=i),t}}}),S.fn.extend({on:function(e,t,n,r){return ke(this,e,t,n,r)},one:function(e,t,n,r){return ke(this,e,t,n,r,1)},off:function(e,t,n){var r,i;if(e&&e.preventDefault&&e.handleObj)return r=e.handleObj,S(e.delegateTarget).off(r.namespace?r.origType+"."+r.namespace:r.origType,r.selector,r.handler),this;if("object"==typeof e){for(i in e)this.off(i,t,e[i]);return this}return!1!==t&&"function"!=typeof t||(n=t,t=void 0),!1===n&&(n=Ee),this.each(function(){S.event.remove(this,e,n,t)})}});var Ne=/<script|<style|<link/i,De=/checked\s*(?:[^=]|=\s*.checked.)/i,je=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g;function qe(e,t){return A(e,"table")&&A(11!==t.nodeType?t:t.firstChild,"tr")&&S(e).children("tbody")[0]||e}function Le(e){return e.type=(null!==e.getAttribute("type"))+"/"+e.type,e}function He(e){return"true/"===(e.type||"").slice(0,5)?e.type=e.type.slice(5):e.removeAttribute("type"),e}function Oe(e,t){var n,r,i,o,a,s;if(1===t.nodeType){if(Y.hasData(e)&&(s=Y.get(e).events))for(i in Y.remove(t,"handle events"),s)for(n=0,r=s[i].length;n<r;n++)S.event.add(t,i,s[i][n]);Q.hasData(e)&&(o=Q.access(e),a=S.extend({},o),Q.set(t,a))}}function Pe(n,r,i,o){r=g(r);var e,t,a,s,u,l,c=0,f=n.length,p=f-1,d=r[0],h=m(d);if(h||1<f&&"string"==typeof d&&!y.checkClone&&De.test(d))return n.each(function(e){var t=n.eq(e);h&&(r[0]=d.call(this,e,t.html())),Pe(t,r,i,o)});if(f&&(t=(e=xe(r,n[0].ownerDocument,!1,n,o)).firstChild,1===e.childNodes.length&&(e=t),t||o)){for(s=(a=S.map(ve(e,"script"),Le)).length;c<f;c++)u=e,c!==p&&(u=S.clone(u,!0,!0),s&&S.merge(a,ve(u,"script"))),i.call(n[c],u,c);if(s)for(l=a[a.length-1].ownerDocument,S.map(a,He),c=0;c<s;c++)u=a[c],he.test(u.type||"")&&!Y.access(u,"globalEval")&&S.contains(l,u)&&(u.src&&"module"!==(u.type||"").toLowerCase()?S._evalUrl&&!u.noModule&&S._evalUrl(u.src,{nonce:u.nonce||u.getAttribute("nonce")},l):b(u.textContent.replace(je,""),u,l))}return n}function Re(e,t,n){for(var r,i=t?S.filter(t,e):e,o=0;null!=(r=i[o]);o++)n||1!==r.nodeType||S.cleanData(ve(r)),r.parentNode&&(n&&ie(r)&&ye(ve(r,"script")),r.parentNode.removeChild(r));return e}S.extend({htmlPrefilter:function(e){return e},clone:function(e,t,n){var r,i,o,a,s,u,l,c=e.cloneNode(!0),f=ie(e);if(!(y.noCloneChecked||1!==e.nodeType&&11!==e.nodeType||S.isXMLDoc(e)))for(a=ve(c),r=0,i=(o=ve(e)).length;r<i;r++)s=o[r],u=a[r],void 0,"input"===(l=u.nodeName.toLowerCase())&&pe.test(s.type)?u.checked=s.checked:"input"!==l&&"textarea"!==l||(u.defaultValue=s.defaultValue);if(t)if(n)for(o=o||ve(e),a=a||ve(c),r=0,i=o.length;r<i;r++)Oe(o[r],a[r]);else Oe(e,c);return 0<(a=ve(c,"script")).length&&ye(a,!f&&ve(e,"script")),c},cleanData:function(e){for(var t,n,r,i=S.event.special,o=0;void 0!==(n=e[o]);o++)if(V(n)){if(t=n[Y.expando]){if(t.events)for(r in t.events)i[r]?S.event.remove(n,r):S.removeEvent(n,r,t.handle);n[Y.expando]=void 0}n[Q.expando]&&(n[Q.expando]=void 0)}}}),S.fn.extend({detach:function(e){return Re(this,e,!0)},remove:function(e){return Re(this,e)},text:function(e){return $(this,function(e){return void 0===e?S.text(this):this.empty().each(function(){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||(this.textContent=e)})},null,e,arguments.length)},append:function(){return Pe(this,arguments,function(e){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||qe(this,e).appendChild(e)})},prepend:function(){return Pe(this,arguments,function(e){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var t=qe(this,e);t.insertBefore(e,t.firstChild)}})},before:function(){return Pe(this,arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this)})},after:function(){return Pe(this,arguments,function(e){this.parentNode&&this.parentNode.insertBefore(e,this.nextSibling)})},empty:function(){for(var e,t=0;null!=(e=this[t]);t++)1===e.nodeType&&(S.cleanData(ve(e,!1)),e.textContent="");return this},clone:function(e,t){return e=null!=e&&e,t=null==t?e:t,this.map(function(){return S.clone(this,e,t)})},html:function(e){return $(this,function(e){var t=this[0]||{},n=0,r=this.length;if(void 0===e&&1===t.nodeType)return t.innerHTML;if("string"==typeof e&&!Ne.test(e)&&!ge[(de.exec(e)||["",""])[1].toLowerCase()]){e=S.htmlPrefilter(e);try{for(;n<r;n++)1===(t=this[n]||{}).nodeType&&(S.cleanData(ve(t,!1)),t.innerHTML=e);t=0}catch(e){}}t&&this.empty().append(e)},null,e,arguments.length)},replaceWith:function(){var n=[];return Pe(this,arguments,function(e){var t=this.parentNode;S.inArray(this,n)<0&&(S.cleanData(ve(this)),t&&t.replaceChild(e,this))},n)}}),S.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(e,a){S.fn[e]=function(e){for(var t,n=[],r=S(e),i=r.length-1,o=0;o<=i;o++)t=o===i?this:this.clone(!0),S(r[o])[a](t),u.apply(n,t.get());return this.pushStack(n)}});var Me=new RegExp("^("+ee+")(?!px)[a-z%]+$","i"),Ie=function(e){var t=e.ownerDocument.defaultView;return t&&t.opener||(t=C),t.getComputedStyle(e)},We=function(e,t,n){var r,i,o={};for(i in t)o[i]=e.style[i],e.style[i]=t[i];for(i in r=n.call(e),t)e.style[i]=o[i];return r},Fe=new RegExp(ne.join("|"),"i");function Be(e,t,n){var r,i,o,a,s=e.style;return(n=n||Ie(e))&&(""!==(a=n.getPropertyValue(t)||n[t])||ie(e)||(a=S.style(e,t)),!y.pixelBoxStyles()&&Me.test(a)&&Fe.test(t)&&(r=s.width,i=s.minWidth,o=s.maxWidth,s.minWidth=s.maxWidth=s.width=a,a=n.width,s.width=r,s.minWidth=i,s.maxWidth=o)),void 0!==a?a+"":a}function $e(e,t){return{get:function(){if(!e())return(this.get=t).apply(this,arguments);delete this.get}}}!function(){function e(){if(l){u.style.cssText="position:absolute;left:-11111px;width:60px;margin-top:1px;padding:0;border:0",l.style.cssText="position:relative;display:block;box-sizing:border-box;overflow:scroll;margin:auto;border:1px;padding:1px;width:60%;top:1%",re.appendChild(u).appendChild(l);var e=C.getComputedStyle(l);n="1%"!==e.top,s=12===t(e.marginLeft),l.style.right="60%",o=36===t(e.right),r=36===t(e.width),l.style.position="absolute",i=12===t(l.offsetWidth/3),re.removeChild(u),l=null}}function t(e){return Math.round(parseFloat(e))}var n,r,i,o,a,s,u=E.createElement("div"),l=E.createElement("div");l.style&&(l.style.backgroundClip="content-box",l.cloneNode(!0).style.backgroundClip="",y.clearCloneStyle="content-box"===l.style.backgroundClip,S.extend(y,{boxSizingReliable:function(){return e(),r},pixelBoxStyles:function(){return e(),o},pixelPosition:function(){return e(),n},reliableMarginLeft:function(){return e(),s},scrollboxSize:function(){return e(),i},reliableTrDimensions:function(){var e,t,n,r;return null==a&&(e=E.createElement("table"),t=E.createElement("tr"),n=E.createElement("div"),e.style.cssText="position:absolute;left:-11111px",t.style.height="1px",n.style.height="9px",re.appendChild(e).appendChild(t).appendChild(n),r=C.getComputedStyle(t),a=3<parseInt(r.height),re.removeChild(e)),a}}))}();var _e=["Webkit","Moz","ms"],ze=E.createElement("div").style,Ue={};function Xe(e){var t=S.cssProps[e]||Ue[e];return t||(e in ze?e:Ue[e]=function(e){var t=e[0].toUpperCase()+e.slice(1),n=_e.length;while(n--)if((e=_e[n]+t)in ze)return e}(e)||e)}var Ve=/^(none|table(?!-c[ea]).+)/,Ge=/^--/,Ye={position:"absolute",visibility:"hidden",display:"block"},Qe={letterSpacing:"0",fontWeight:"400"};function Je(e,t,n){var r=te.exec(t);return r?Math.max(0,r[2]-(n||0))+(r[3]||"px"):t}function Ke(e,t,n,r,i,o){var a="width"===t?1:0,s=0,u=0;if(n===(r?"border":"content"))return 0;for(;a<4;a+=2)"margin"===n&&(u+=S.css(e,n+ne[a],!0,i)),r?("content"===n&&(u-=S.css(e,"padding"+ne[a],!0,i)),"margin"!==n&&(u-=S.css(e,"border"+ne[a]+"Width",!0,i))):(u+=S.css(e,"padding"+ne[a],!0,i),"padding"!==n?u+=S.css(e,"border"+ne[a]+"Width",!0,i):s+=S.css(e,"border"+ne[a]+"Width",!0,i));return!r&&0<=o&&(u+=Math.max(0,Math.ceil(e["offset"+t[0].toUpperCase()+t.slice(1)]-o-u-s-.5))||0),u}function Ze(e,t,n){var r=Ie(e),i=(!y.boxSizingReliable()||n)&&"border-box"===S.css(e,"boxSizing",!1,r),o=i,a=Be(e,t,r),s="offset"+t[0].toUpperCase()+t.slice(1);if(Me.test(a)){if(!n)return a;a="auto"}return(!y.boxSizingReliable()&&i||!y.reliableTrDimensions()&&A(e,"tr")||"auto"===a||!parseFloat(a)&&"inline"===S.css(e,"display",!1,r))&&e.getClientRects().length&&(i="border-box"===S.css(e,"boxSizing",!1,r),(o=s in e)&&(a=e[s])),(a=parseFloat(a)||0)+Ke(e,t,n||(i?"border":"content"),o,r,a)+"px"}function et(e,t,n,r,i){return new et.prototype.init(e,t,n,r,i)}S.extend({cssHooks:{opacity:{get:function(e,t){if(t){var n=Be(e,"opacity");return""===n?"1":n}}}},cssNumber:{animationIterationCount:!0,columnCount:!0,fillOpacity:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,gridArea:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnStart:!0,gridRow:!0,gridRowEnd:!0,gridRowStart:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{},style:function(e,t,n,r){if(e&&3!==e.nodeType&&8!==e.nodeType&&e.style){var i,o,a,s=X(t),u=Ge.test(t),l=e.style;if(u||(t=Xe(s)),a=S.cssHooks[t]||S.cssHooks[s],void 0===n)return a&&"get"in a&&void 0!==(i=a.get(e,!1,r))?i:l[t];"string"===(o=typeof n)&&(i=te.exec(n))&&i[1]&&(n=se(e,t,i),o="number"),null!=n&&n==n&&("number"!==o||u||(n+=i&&i[3]||(S.cssNumber[s]?"":"px")),y.clearCloneStyle||""!==n||0!==t.indexOf("background")||(l[t]="inherit"),a&&"set"in a&&void 0===(n=a.set(e,n,r))||(u?l.setProperty(t,n):l[t]=n))}},css:function(e,t,n,r){var i,o,a,s=X(t);return Ge.test(t)||(t=Xe(s)),(a=S.cssHooks[t]||S.cssHooks[s])&&"get"in a&&(i=a.get(e,!0,n)),void 0===i&&(i=Be(e,t,r)),"normal"===i&&t in Qe&&(i=Qe[t]),""===n||n?(o=parseFloat(i),!0===n||isFinite(o)?o||0:i):i}}),S.each(["height","width"],function(e,u){S.cssHooks[u]={get:function(e,t,n){if(t)return!Ve.test(S.css(e,"display"))||e.getClientRects().length&&e.getBoundingClientRect().width?Ze(e,u,n):We(e,Ye,function(){return Ze(e,u,n)})},set:function(e,t,n){var r,i=Ie(e),o=!y.scrollboxSize()&&"absolute"===i.position,a=(o||n)&&"border-box"===S.css(e,"boxSizing",!1,i),s=n?Ke(e,u,n,a,i):0;return a&&o&&(s-=Math.ceil(e["offset"+u[0].toUpperCase()+u.slice(1)]-parseFloat(i[u])-Ke(e,u,"border",!1,i)-.5)),s&&(r=te.exec(t))&&"px"!==(r[3]||"px")&&(e.style[u]=t,t=S.css(e,u)),Je(0,t,s)}}}),S.cssHooks.marginLeft=$e(y.reliableMarginLeft,function(e,t){if(t)return(parseFloat(Be(e,"marginLeft"))||e.getBoundingClientRect().left-We(e,{marginLeft:0},function(){return e.getBoundingClientRect().left}))+"px"}),S.each({margin:"",padding:"",border:"Width"},function(i,o){S.cssHooks[i+o]={expand:function(e){for(var t=0,n={},r="string"==typeof e?e.split(" "):[e];t<4;t++)n[i+ne[t]+o]=r[t]||r[t-2]||r[0];return n}},"margin"!==i&&(S.cssHooks[i+o].set=Je)}),S.fn.extend({css:function(e,t){return $(this,function(e,t,n){var r,i,o={},a=0;if(Array.isArray(t)){for(r=Ie(e),i=t.length;a<i;a++)o[t[a]]=S.css(e,t[a],!1,r);return o}return void 0!==n?S.style(e,t,n):S.css(e,t)},e,t,1<arguments.length)}}),((S.Tween=et).prototype={constructor:et,init:function(e,t,n,r,i,o){this.elem=e,this.prop=n,this.easing=i||S.easing._default,this.options=t,this.start=this.now=this.cur(),this.end=r,this.unit=o||(S.cssNumber[n]?"":"px")},cur:function(){var e=et.propHooks[this.prop];return e&&e.get?e.get(this):et.propHooks._default.get(this)},run:function(e){var t,n=et.propHooks[this.prop];return this.options.duration?this.pos=t=S.easing[this.easing](e,this.options.duration*e,0,1,this.options.duration):this.pos=t=e,this.now=(this.end-this.start)*t+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),n&&n.set?n.set(this):et.propHooks._default.set(this),this}}).init.prototype=et.prototype,(et.propHooks={_default:{get:function(e){var t;return 1!==e.elem.nodeType||null!=e.elem[e.prop]&&null==e.elem.style[e.prop]?e.elem[e.prop]:(t=S.css(e.elem,e.prop,""))&&"auto"!==t?t:0},set:function(e){S.fx.step[e.prop]?S.fx.step[e.prop](e):1!==e.elem.nodeType||!S.cssHooks[e.prop]&&null==e.elem.style[Xe(e.prop)]?e.elem[e.prop]=e.now:S.style(e.elem,e.prop,e.now+e.unit)}}}).scrollTop=et.propHooks.scrollLeft={set:function(e){e.elem.nodeType&&e.elem.parentNode&&(e.elem[e.prop]=e.now)}},S.easing={linear:function(e){return e},swing:function(e){return.5-Math.cos(e*Math.PI)/2},_default:"swing"},S.fx=et.prototype.init,S.fx.step={};var tt,nt,rt,it,ot=/^(?:toggle|show|hide)$/,at=/queueHooks$/;function st(){nt&&(!1===E.hidden&&C.requestAnimationFrame?C.requestAnimationFrame(st):C.setTimeout(st,S.fx.interval),S.fx.tick())}function ut(){return C.setTimeout(function(){tt=void 0}),tt=Date.now()}function lt(e,t){var n,r=0,i={height:e};for(t=t?1:0;r<4;r+=2-t)i["margin"+(n=ne[r])]=i["padding"+n]=e;return t&&(i.opacity=i.width=e),i}function ct(e,t,n){for(var r,i=(ft.tweeners[t]||[]).concat(ft.tweeners["*"]),o=0,a=i.length;o<a;o++)if(r=i[o].call(n,t,e))return r}function ft(o,e,t){var n,a,r=0,i=ft.prefilters.length,s=S.Deferred().always(function(){delete u.elem}),u=function(){if(a)return!1;for(var e=tt||ut(),t=Math.max(0,l.startTime+l.duration-e),n=1-(t/l.duration||0),r=0,i=l.tweens.length;r<i;r++)l.tweens[r].run(n);return s.notifyWith(o,[l,n,t]),n<1&&i?t:(i||s.notifyWith(o,[l,1,0]),s.resolveWith(o,[l]),!1)},l=s.promise({elem:o,props:S.extend({},e),opts:S.extend(!0,{specialEasing:{},easing:S.easing._default},t),originalProperties:e,originalOptions:t,startTime:tt||ut(),duration:t.duration,tweens:[],createTween:function(e,t){var n=S.Tween(o,l.opts,e,t,l.opts.specialEasing[e]||l.opts.easing);return l.tweens.push(n),n},stop:function(e){var t=0,n=e?l.tweens.length:0;if(a)return this;for(a=!0;t<n;t++)l.tweens[t].run(1);return e?(s.notifyWith(o,[l,1,0]),s.resolveWith(o,[l,e])):s.rejectWith(o,[l,e]),this}}),c=l.props;for(!function(e,t){var n,r,i,o,a;for(n in e)if(i=t[r=X(n)],o=e[n],Array.isArray(o)&&(i=o[1],o=e[n]=o[0]),n!==r&&(e[r]=o,delete e[n]),(a=S.cssHooks[r])&&"expand"in a)for(n in o=a.expand(o),delete e[r],o)n in e||(e[n]=o[n],t[n]=i);else t[r]=i}(c,l.opts.specialEasing);r<i;r++)if(n=ft.prefilters[r].call(l,o,c,l.opts))return m(n.stop)&&(S._queueHooks(l.elem,l.opts.queue).stop=n.stop.bind(n)),n;return S.map(c,ct,l),m(l.opts.start)&&l.opts.start.call(o,l),l.progress(l.opts.progress).done(l.opts.done,l.opts.complete).fail(l.opts.fail).always(l.opts.always),S.fx.timer(S.extend(u,{elem:o,anim:l,queue:l.opts.queue})),l}S.Animation=S.extend(ft,{tweeners:{"*":[function(e,t){var n=this.createTween(e,t);return se(n.elem,e,te.exec(t),n),n}]},tweener:function(e,t){m(e)?(t=e,e=["*"]):e=e.match(P);for(var n,r=0,i=e.length;r<i;r++)n=e[r],ft.tweeners[n]=ft.tweeners[n]||[],ft.tweeners[n].unshift(t)},prefilters:[function(e,t,n){var r,i,o,a,s,u,l,c,f="width"in t||"height"in t,p=this,d={},h=e.style,g=e.nodeType&&ae(e),v=Y.get(e,"fxshow");for(r in n.queue||(null==(a=S._queueHooks(e,"fx")).unqueued&&(a.unqueued=0,s=a.empty.fire,a.empty.fire=function(){a.unqueued||s()}),a.unqueued++,p.always(function(){p.always(function(){a.unqueued--,S.queue(e,"fx").length||a.empty.fire()})})),t)if(i=t[r],ot.test(i)){if(delete t[r],o=o||"toggle"===i,i===(g?"hide":"show")){if("show"!==i||!v||void 0===v[r])continue;g=!0}d[r]=v&&v[r]||S.style(e,r)}if((u=!S.isEmptyObject(t))||!S.isEmptyObject(d))for(r in f&&1===e.nodeType&&(n.overflow=[h.overflow,h.overflowX,h.overflowY],null==(l=v&&v.display)&&(l=Y.get(e,"display")),"none"===(c=S.css(e,"display"))&&(l?c=l:(le([e],!0),l=e.style.display||l,c=S.css(e,"display"),le([e]))),("inline"===c||"inline-block"===c&&null!=l)&&"none"===S.css(e,"float")&&(u||(p.done(function(){h.display=l}),null==l&&(c=h.display,l="none"===c?"":c)),h.display="inline-block")),n.overflow&&(h.overflow="hidden",p.always(function(){h.overflow=n.overflow[0],h.overflowX=n.overflow[1],h.overflowY=n.overflow[2]})),u=!1,d)u||(v?"hidden"in v&&(g=v.hidden):v=Y.access(e,"fxshow",{display:l}),o&&(v.hidden=!g),g&&le([e],!0),p.done(function(){for(r in g||le([e]),Y.remove(e,"fxshow"),d)S.style(e,r,d[r])})),u=ct(g?v[r]:0,r,p),r in v||(v[r]=u.start,g&&(u.end=u.start,u.start=0))}],prefilter:function(e,t){t?ft.prefilters.unshift(e):ft.prefilters.push(e)}}),S.speed=function(e,t,n){var r=e&&"object"==typeof e?S.extend({},e):{complete:n||!n&&t||m(e)&&e,duration:e,easing:n&&t||t&&!m(t)&&t};return S.fx.off?r.duration=0:"number"!=typeof r.duration&&(r.duration in S.fx.speeds?r.duration=S.fx.speeds[r.duration]:r.duration=S.fx.speeds._default),null!=r.queue&&!0!==r.queue||(r.queue="fx"),r.old=r.complete,r.complete=function(){m(r.old)&&r.old.call(this),r.queue&&S.dequeue(this,r.queue)},r},S.fn.extend({fadeTo:function(e,t,n,r){return this.filter(ae).css("opacity",0).show().end().animate({opacity:t},e,n,r)},animate:function(t,e,n,r){var i=S.isEmptyObject(t),o=S.speed(e,n,r),a=function(){var e=ft(this,S.extend({},t),o);(i||Y.get(this,"finish"))&&e.stop(!0)};return a.finish=a,i||!1===o.queue?this.each(a):this.queue(o.queue,a)},stop:function(i,e,o){var a=function(e){var t=e.stop;delete e.stop,t(o)};return"string"!=typeof i&&(o=e,e=i,i=void 0),e&&this.queue(i||"fx",[]),this.each(function(){var e=!0,t=null!=i&&i+"queueHooks",n=S.timers,r=Y.get(this);if(t)r[t]&&r[t].stop&&a(r[t]);else for(t in r)r[t]&&r[t].stop&&at.test(t)&&a(r[t]);for(t=n.length;t--;)n[t].elem!==this||null!=i&&n[t].queue!==i||(n[t].anim.stop(o),e=!1,n.splice(t,1));!e&&o||S.dequeue(this,i)})},finish:function(a){return!1!==a&&(a=a||"fx"),this.each(function(){var e,t=Y.get(this),n=t[a+"queue"],r=t[a+"queueHooks"],i=S.timers,o=n?n.length:0;for(t.finish=!0,S.queue(this,a,[]),r&&r.stop&&r.stop.call(this,!0),e=i.length;e--;)i[e].elem===this&&i[e].queue===a&&(i[e].anim.stop(!0),i.splice(e,1));for(e=0;e<o;e++)n[e]&&n[e].finish&&n[e].finish.call(this);delete t.finish})}}),S.each(["toggle","show","hide"],function(e,r){var i=S.fn[r];S.fn[r]=function(e,t,n){return null==e||"boolean"==typeof e?i.apply(this,arguments):this.animate(lt(r,!0),e,t,n)}}),S.each({slideDown:lt("show"),slideUp:lt("hide"),slideToggle:lt("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(e,r){S.fn[e]=function(e,t,n){return this.animate(r,e,t,n)}}),S.timers=[],S.fx.tick=function(){var e,t=0,n=S.timers;for(tt=Date.now();t<n.length;t++)(e=n[t])()||n[t]!==e||n.splice(t--,1);n.length||S.fx.stop(),tt=void 0},S.fx.timer=function(e){S.timers.push(e),S.fx.start()},S.fx.interval=13,S.fx.start=function(){nt||(nt=!0,st())},S.fx.stop=function(){nt=null},S.fx.speeds={slow:600,fast:200,_default:400},S.fn.delay=function(r,e){return r=S.fx&&S.fx.speeds[r]||r,e=e||"fx",this.queue(e,function(e,t){var n=C.setTimeout(e,r);t.stop=function(){C.clearTimeout(n)}})},rt=E.createElement("input"),it=E.createElement("select").appendChild(E.createElement("option")),rt.type="checkbox",y.checkOn=""!==rt.value,y.optSelected=it.selected,(rt=E.createElement("input")).value="t",rt.type="radio",y.radioValue="t"===rt.value;var pt,dt=S.expr.attrHandle;S.fn.extend({attr:function(e,t){return $(this,S.attr,e,t,1<arguments.length)},removeAttr:function(e){return this.each(function(){S.removeAttr(this,e)})}}),S.extend({attr:function(e,t,n){var r,i,o=e.nodeType;if(3!==o&&8!==o&&2!==o)return"undefined"==typeof e.getAttribute?S.prop(e,t,n):(1===o&&S.isXMLDoc(e)||(i=S.attrHooks[t.toLowerCase()]||(S.expr.match.bool.test(t)?pt:void 0)),void 0!==n?null===n?void S.removeAttr(e,t):i&&"set"in i&&void 0!==(r=i.set(e,n,t))?r:(e.setAttribute(t,n+""),n):i&&"get"in i&&null!==(r=i.get(e,t))?r:null==(r=S.find.attr(e,t))?void 0:r)},attrHooks:{type:{set:function(e,t){if(!y.radioValue&&"radio"===t&&A(e,"input")){var n=e.value;return e.setAttribute("type",t),n&&(e.value=n),t}}}},removeAttr:function(e,t){var n,r=0,i=t&&t.match(P);if(i&&1===e.nodeType)while(n=i[r++])e.removeAttribute(n)}}),pt={set:function(e,t,n){return!1===t?S.removeAttr(e,n):e.setAttribute(n,n),n}},S.each(S.expr.match.bool.source.match(/\w+/g),function(e,t){var a=dt[t]||S.find.attr;dt[t]=function(e,t,n){var r,i,o=t.toLowerCase();return n||(i=dt[o],dt[o]=r,r=null!=a(e,t,n)?o:null,dt[o]=i),r}});var ht=/^(?:input|select|textarea|button)$/i,gt=/^(?:a|area)$/i;function vt(e){return(e.match(P)||[]).join(" ")}function yt(e){return e.getAttribute&&e.getAttribute("class")||""}function mt(e){return Array.isArray(e)?e:"string"==typeof e&&e.match(P)||[]}S.fn.extend({prop:function(e,t){return $(this,S.prop,e,t,1<arguments.length)},removeProp:function(e){return this.each(function(){delete this[S.propFix[e]||e]})}}),S.extend({prop:function(e,t,n){var r,i,o=e.nodeType;if(3!==o&&8!==o&&2!==o)return 1===o&&S.isXMLDoc(e)||(t=S.propFix[t]||t,i=S.propHooks[t]),void 0!==n?i&&"set"in i&&void 0!==(r=i.set(e,n,t))?r:e[t]=n:i&&"get"in i&&null!==(r=i.get(e,t))?r:e[t]},propHooks:{tabIndex:{get:function(e){var t=S.find.attr(e,"tabindex");return t?parseInt(t,10):ht.test(e.nodeName)||gt.test(e.nodeName)&&e.href?0:-1}}},propFix:{"for":"htmlFor","class":"className"}}),y.optSelected||(S.propHooks.selected={get:function(e){var t=e.parentNode;return t&&t.parentNode&&t.parentNode.selectedIndex,null},set:function(e){var t=e.parentNode;t&&(t.selectedIndex,t.parentNode&&t.parentNode.selectedIndex)}}),S.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){S.propFix[this.toLowerCase()]=this}),S.fn.extend({addClass:function(t){var e,n,r,i,o,a,s,u=0;if(m(t))return this.each(function(e){S(this).addClass(t.call(this,e,yt(this)))});if((e=mt(t)).length)while(n=this[u++])if(i=yt(n),r=1===n.nodeType&&" "+vt(i)+" "){a=0;while(o=e[a++])r.indexOf(" "+o+" ")<0&&(r+=o+" ");i!==(s=vt(r))&&n.setAttribute("class",s)}return this},removeClass:function(t){var e,n,r,i,o,a,s,u=0;if(m(t))return this.each(function(e){S(this).removeClass(t.call(this,e,yt(this)))});if(!arguments.length)return this.attr("class","");if((e=mt(t)).length)while(n=this[u++])if(i=yt(n),r=1===n.nodeType&&" "+vt(i)+" "){a=0;while(o=e[a++])while(-1<r.indexOf(" "+o+" "))r=r.replace(" "+o+" "," ");i!==(s=vt(r))&&n.setAttribute("class",s)}return this},toggleClass:function(i,t){var o=typeof i,a="string"===o||Array.isArray(i);return"boolean"==typeof t&&a?t?this.addClass(i):this.removeClass(i):m(i)?this.each(function(e){S(this).toggleClass(i.call(this,e,yt(this),t),t)}):this.each(function(){var e,t,n,r;if(a){t=0,n=S(this),r=mt(i);while(e=r[t++])n.hasClass(e)?n.removeClass(e):n.addClass(e)}else void 0!==i&&"boolean"!==o||((e=yt(this))&&Y.set(this,"__className__",e),this.setAttribute&&this.setAttribute("class",e||!1===i?"":Y.get(this,"__className__")||""))})},hasClass:function(e){var t,n,r=0;t=" "+e+" ";while(n=this[r++])if(1===n.nodeType&&-1<(" "+vt(yt(n))+" ").indexOf(t))return!0;return!1}});var xt=/\r/g;S.fn.extend({val:function(n){var r,e,i,t=this[0];return arguments.length?(i=m(n),this.each(function(e){var t;1===this.nodeType&&(null==(t=i?n.call(this,e,S(this).val()):n)?t="":"number"==typeof t?t+="":Array.isArray(t)&&(t=S.map(t,function(e){return null==e?"":e+""})),(r=S.valHooks[this.type]||S.valHooks[this.nodeName.toLowerCase()])&&"set"in r&&void 0!==r.set(this,t,"value")||(this.value=t))})):t?(r=S.valHooks[t.type]||S.valHooks[t.nodeName.toLowerCase()])&&"get"in r&&void 0!==(e=r.get(t,"value"))?e:"string"==typeof(e=t.value)?e.replace(xt,""):null==e?"":e:void 0}}),S.extend({valHooks:{option:{get:function(e){var t=S.find.attr(e,"value");return null!=t?t:vt(S.text(e))}},select:{get:function(e){var t,n,r,i=e.options,o=e.selectedIndex,a="select-one"===e.type,s=a?null:[],u=a?o+1:i.length;for(r=o<0?u:a?o:0;r<u;r++)if(((n=i[r]).selected||r===o)&&!n.disabled&&(!n.parentNode.disabled||!A(n.parentNode,"optgroup"))){if(t=S(n).val(),a)return t;s.push(t)}return s},set:function(e,t){var n,r,i=e.options,o=S.makeArray(t),a=i.length;while(a--)((r=i[a]).selected=-1<S.inArray(S.valHooks.option.get(r),o))&&(n=!0);return n||(e.selectedIndex=-1),o}}}}),S.each(["radio","checkbox"],function(){S.valHooks[this]={set:function(e,t){if(Array.isArray(t))return e.checked=-1<S.inArray(S(e).val(),t)}},y.checkOn||(S.valHooks[this].get=function(e){return null===e.getAttribute("value")?"on":e.value})}),y.focusin="onfocusin"in C;var bt=/^(?:focusinfocus|focusoutblur)$/,wt=function(e){e.stopPropagation()};S.extend(S.event,{trigger:function(e,t,n,r){var i,o,a,s,u,l,c,f,p=[n||E],d=v.call(e,"type")?e.type:e,h=v.call(e,"namespace")?e.namespace.split("."):[];if(o=f=a=n=n||E,3!==n.nodeType&&8!==n.nodeType&&!bt.test(d+S.event.triggered)&&(-1<d.indexOf(".")&&(d=(h=d.split(".")).shift(),h.sort()),u=d.indexOf(":")<0&&"on"+d,(e=e[S.expando]?e:new S.Event(d,"object"==typeof e&&e)).isTrigger=r?2:3,e.namespace=h.join("."),e.rnamespace=e.namespace?new RegExp("(^|\\.)"+h.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,e.result=void 0,e.target||(e.target=n),t=null==t?[e]:S.makeArray(t,[e]),c=S.event.special[d]||{},r||!c.trigger||!1!==c.trigger.apply(n,t))){if(!r&&!c.noBubble&&!x(n)){for(s=c.delegateType||d,bt.test(s+d)||(o=o.parentNode);o;o=o.parentNode)p.push(o),a=o;a===(n.ownerDocument||E)&&p.push(a.defaultView||a.parentWindow||C)}i=0;while((o=p[i++])&&!e.isPropagationStopped())f=o,e.type=1<i?s:c.bindType||d,(l=(Y.get(o,"events")||Object.create(null))[e.type]&&Y.get(o,"handle"))&&l.apply(o,t),(l=u&&o[u])&&l.apply&&V(o)&&(e.result=l.apply(o,t),!1===e.result&&e.preventDefault());return e.type=d,r||e.isDefaultPrevented()||c._default&&!1!==c._default.apply(p.pop(),t)||!V(n)||u&&m(n[d])&&!x(n)&&((a=n[u])&&(n[u]=null),S.event.triggered=d,e.isPropagationStopped()&&f.addEventListener(d,wt),n[d](),e.isPropagationStopped()&&f.removeEventListener(d,wt),S.event.triggered=void 0,a&&(n[u]=a)),e.result}},simulate:function(e,t,n){var r=S.extend(new S.Event,n,{type:e,isSimulated:!0});S.event.trigger(r,null,t)}}),S.fn.extend({trigger:function(e,t){return this.each(function(){S.event.trigger(e,t,this)})},triggerHandler:function(e,t){var n=this[0];if(n)return S.event.trigger(e,t,n,!0)}}),y.focusin||S.each({focus:"focusin",blur:"focusout"},function(n,r){var i=function(e){S.event.simulate(r,e.target,S.event.fix(e))};S.event.special[r]={setup:function(){var e=this.ownerDocument||this.document||this,t=Y.access(e,r);t||e.addEventListener(n,i,!0),Y.access(e,r,(t||0)+1)},teardown:function(){var e=this.ownerDocument||this.document||this,t=Y.access(e,r)-1;t?Y.access(e,r,t):(e.removeEventListener(n,i,!0),Y.remove(e,r))}}});var Tt=C.location,Ct={guid:Date.now()},Et=/\?/;S.parseXML=function(e){var t;if(!e||"string"!=typeof e)return null;try{t=(new C.DOMParser).parseFromString(e,"text/xml")}catch(e){t=void 0}return t&&!t.getElementsByTagName("parsererror").length||S.error("Invalid XML: "+e),t};var St=/\[\]$/,kt=/\r?\n/g,At=/^(?:submit|button|image|reset|file)$/i,Nt=/^(?:input|select|textarea|keygen)/i;function Dt(n,e,r,i){var t;if(Array.isArray(e))S.each(e,function(e,t){r||St.test(n)?i(n,t):Dt(n+"["+("object"==typeof t&&null!=t?e:"")+"]",t,r,i)});else if(r||"object"!==w(e))i(n,e);else for(t in e)Dt(n+"["+t+"]",e[t],r,i)}S.param=function(e,t){var n,r=[],i=function(e,t){var n=m(t)?t():t;r[r.length]=encodeURIComponent(e)+"="+encodeURIComponent(null==n?"":n)};if(null==e)return"";if(Array.isArray(e)||e.jquery&&!S.isPlainObject(e))S.each(e,function(){i(this.name,this.value)});else for(n in e)Dt(n,e[n],t,i);return r.join("&")},S.fn.extend({serialize:function(){return S.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var e=S.prop(this,"elements");return e?S.makeArray(e):this}).filter(function(){var e=this.type;return this.name&&!S(this).is(":disabled")&&Nt.test(this.nodeName)&&!At.test(e)&&(this.checked||!pe.test(e))}).map(function(e,t){var n=S(this).val();return null==n?null:Array.isArray(n)?S.map(n,function(e){return{name:t.name,value:e.replace(kt,"\r\n")}}):{name:t.name,value:n.replace(kt,"\r\n")}}).get()}});var jt=/%20/g,qt=/#.*$/,Lt=/([?&])_=[^&]*/,Ht=/^(.*?):[ \t]*([^\r\n]*)$/gm,Ot=/^(?:GET|HEAD)$/,Pt=/^\/\//,Rt={},Mt={},It="*/".concat("*"),Wt=E.createElement("a");function Ft(o){return function(e,t){"string"!=typeof e&&(t=e,e="*");var n,r=0,i=e.toLowerCase().match(P)||[];if(m(t))while(n=i[r++])"+"===n[0]?(n=n.slice(1)||"*",(o[n]=o[n]||[]).unshift(t)):(o[n]=o[n]||[]).push(t)}}function Bt(t,i,o,a){var s={},u=t===Mt;function l(e){var r;return s[e]=!0,S.each(t[e]||[],function(e,t){var n=t(i,o,a);return"string"!=typeof n||u||s[n]?u?!(r=n):void 0:(i.dataTypes.unshift(n),l(n),!1)}),r}return l(i.dataTypes[0])||!s["*"]&&l("*")}function $t(e,t){var n,r,i=S.ajaxSettings.flatOptions||{};for(n in t)void 0!==t[n]&&((i[n]?e:r||(r={}))[n]=t[n]);return r&&S.extend(!0,e,r),e}Wt.href=Tt.href,S.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:Tt.href,type:"GET",isLocal:/^(?:about|app|app-storage|.+-extension|file|res|widget):$/.test(Tt.protocol),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":It,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/\bxml\b/,html:/\bhtml/,json:/\bjson\b/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":JSON.parse,"text xml":S.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(e,t){return t?$t($t(e,S.ajaxSettings),t):$t(S.ajaxSettings,e)},ajaxPrefilter:Ft(Rt),ajaxTransport:Ft(Mt),ajax:function(e,t){"object"==typeof e&&(t=e,e=void 0),t=t||{};var c,f,p,n,d,r,h,g,i,o,v=S.ajaxSetup({},t),y=v.context||v,m=v.context&&(y.nodeType||y.jquery)?S(y):S.event,x=S.Deferred(),b=S.Callbacks("once memory"),w=v.statusCode||{},a={},s={},u="canceled",T={readyState:0,getResponseHeader:function(e){var t;if(h){if(!n){n={};while(t=Ht.exec(p))n[t[1].toLowerCase()+" "]=(n[t[1].toLowerCase()+" "]||[]).concat(t[2])}t=n[e.toLowerCase()+" "]}return null==t?null:t.join(", ")},getAllResponseHeaders:function(){return h?p:null},setRequestHeader:function(e,t){return null==h&&(e=s[e.toLowerCase()]=s[e.toLowerCase()]||e,a[e]=t),this},overrideMimeType:function(e){return null==h&&(v.mimeType=e),this},statusCode:function(e){var t;if(e)if(h)T.always(e[T.status]);else for(t in e)w[t]=[w[t],e[t]];return this},abort:function(e){var t=e||u;return c&&c.abort(t),l(0,t),this}};if(x.promise(T),v.url=((e||v.url||Tt.href)+"").replace(Pt,Tt.protocol+"//"),v.type=t.method||t.type||v.method||v.type,v.dataTypes=(v.dataType||"*").toLowerCase().match(P)||[""],null==v.crossDomain){r=E.createElement("a");try{r.href=v.url,r.href=r.href,v.crossDomain=Wt.protocol+"//"+Wt.host!=r.protocol+"//"+r.host}catch(e){v.crossDomain=!0}}if(v.data&&v.processData&&"string"!=typeof v.data&&(v.data=S.param(v.data,v.traditional)),Bt(Rt,v,t,T),h)return T;for(i in(g=S.event&&v.global)&&0==S.active++&&S.event.trigger("ajaxStart"),v.type=v.type.toUpperCase(),v.hasContent=!Ot.test(v.type),f=v.url.replace(qt,""),v.hasContent?v.data&&v.processData&&0===(v.contentType||"").indexOf("application/x-www-form-urlencoded")&&(v.data=v.data.replace(jt,"+")):(o=v.url.slice(f.length),v.data&&(v.processData||"string"==typeof v.data)&&(f+=(Et.test(f)?"&":"?")+v.data,delete v.data),!1===v.cache&&(f=f.replace(Lt,"$1"),o=(Et.test(f)?"&":"?")+"_="+Ct.guid+++o),v.url=f+o),v.ifModified&&(S.lastModified[f]&&T.setRequestHeader("If-Modified-Since",S.lastModified[f]),S.etag[f]&&T.setRequestHeader("If-None-Match",S.etag[f])),(v.data&&v.hasContent&&!1!==v.contentType||t.contentType)&&T.setRequestHeader("Content-Type",v.contentType),T.setRequestHeader("Accept",v.dataTypes[0]&&v.accepts[v.dataTypes[0]]?v.accepts[v.dataTypes[0]]+("*"!==v.dataTypes[0]?", "+It+"; q=0.01":""):v.accepts["*"]),v.headers)T.setRequestHeader(i,v.headers[i]);if(v.beforeSend&&(!1===v.beforeSend.call(y,T,v)||h))return T.abort();if(u="abort",b.add(v.complete),T.done(v.success),T.fail(v.error),c=Bt(Mt,v,t,T)){if(T.readyState=1,g&&m.trigger("ajaxSend",[T,v]),h)return T;v.async&&0<v.timeout&&(d=C.setTimeout(function(){T.abort("timeout")},v.timeout));try{h=!1,c.send(a,l)}catch(e){if(h)throw e;l(-1,e)}}else l(-1,"No Transport");function l(e,t,n,r){var i,o,a,s,u,l=t;h||(h=!0,d&&C.clearTimeout(d),c=void 0,p=r||"",T.readyState=0<e?4:0,i=200<=e&&e<300||304===e,n&&(s=function(e,t,n){var r,i,o,a,s=e.contents,u=e.dataTypes;while("*"===u[0])u.shift(),void 0===r&&(r=e.mimeType||t.getResponseHeader("Content-Type"));if(r)for(i in s)if(s[i]&&s[i].test(r)){u.unshift(i);break}if(u[0]in n)o=u[0];else{for(i in n){if(!u[0]||e.converters[i+" "+u[0]]){o=i;break}a||(a=i)}o=o||a}if(o)return o!==u[0]&&u.unshift(o),n[o]}(v,T,n)),!i&&-1<S.inArray("script",v.dataTypes)&&(v.converters["text script"]=function(){}),s=function(e,t,n,r){var i,o,a,s,u,l={},c=e.dataTypes.slice();if(c[1])for(a in e.converters)l[a.toLowerCase()]=e.converters[a];o=c.shift();while(o)if(e.responseFields[o]&&(n[e.responseFields[o]]=t),!u&&r&&e.dataFilter&&(t=e.dataFilter(t,e.dataType)),u=o,o=c.shift())if("*"===o)o=u;else if("*"!==u&&u!==o){if(!(a=l[u+" "+o]||l["* "+o]))for(i in l)if((s=i.split(" "))[1]===o&&(a=l[u+" "+s[0]]||l["* "+s[0]])){!0===a?a=l[i]:!0!==l[i]&&(o=s[0],c.unshift(s[1]));break}if(!0!==a)if(a&&e["throws"])t=a(t);else try{t=a(t)}catch(e){return{state:"parsererror",error:a?e:"No conversion from "+u+" to "+o}}}return{state:"success",data:t}}(v,s,T,i),i?(v.ifModified&&((u=T.getResponseHeader("Last-Modified"))&&(S.lastModified[f]=u),(u=T.getResponseHeader("etag"))&&(S.etag[f]=u)),204===e||"HEAD"===v.type?l="nocontent":304===e?l="notmodified":(l=s.state,o=s.data,i=!(a=s.error))):(a=l,!e&&l||(l="error",e<0&&(e=0))),T.status=e,T.statusText=(t||l)+"",i?x.resolveWith(y,[o,l,T]):x.rejectWith(y,[T,l,a]),T.statusCode(w),w=void 0,g&&m.trigger(i?"ajaxSuccess":"ajaxError",[T,v,i?o:a]),b.fireWith(y,[T,l]),g&&(m.trigger("ajaxComplete",[T,v]),--S.active||S.event.trigger("ajaxStop")))}return T},getJSON:function(e,t,n){return S.get(e,t,n,"json")},getScript:function(e,t){return S.get(e,void 0,t,"script")}}),S.each(["get","post"],function(e,i){S[i]=function(e,t,n,r){return m(t)&&(r=r||n,n=t,t=void 0),S.ajax(S.extend({url:e,type:i,dataType:r,data:t,success:n},S.isPlainObject(e)&&e))}}),S.ajaxPrefilter(function(e){var t;for(t in e.headers)"content-type"===t.toLowerCase()&&(e.contentType=e.headers[t]||"")}),S._evalUrl=function(e,t,n){return S.ajax({url:e,type:"GET",dataType:"script",cache:!0,async:!1,global:!1,converters:{"text script":function(){}},dataFilter:function(e){S.globalEval(e,t,n)}})},S.fn.extend({wrapAll:function(e){var t;return this[0]&&(m(e)&&(e=e.call(this[0])),t=S(e,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&t.insertBefore(this[0]),t.map(function(){var e=this;while(e.firstElementChild)e=e.firstElementChild;return e}).append(this)),this},wrapInner:function(n){return m(n)?this.each(function(e){S(this).wrapInner(n.call(this,e))}):this.each(function(){var e=S(this),t=e.contents();t.length?t.wrapAll(n):e.append(n)})},wrap:function(t){var n=m(t);return this.each(function(e){S(this).wrapAll(n?t.call(this,e):t)})},unwrap:function(e){return this.parent(e).not("body").each(function(){S(this).replaceWith(this.childNodes)}),this}}),S.expr.pseudos.hidden=function(e){return!S.expr.pseudos.visible(e)},S.expr.pseudos.visible=function(e){return!!(e.offsetWidth||e.offsetHeight||e.getClientRects().length)},S.ajaxSettings.xhr=function(){try{return new C.XMLHttpRequest}catch(e){}};var _t={0:200,1223:204},zt=S.ajaxSettings.xhr();y.cors=!!zt&&"withCredentials"in zt,y.ajax=zt=!!zt,S.ajaxTransport(function(i){var o,a;if(y.cors||zt&&!i.crossDomain)return{send:function(e,t){var n,r=i.xhr();if(r.open(i.type,i.url,i.async,i.username,i.password),i.xhrFields)for(n in i.xhrFields)r[n]=i.xhrFields[n];for(n in i.mimeType&&r.overrideMimeType&&r.overrideMimeType(i.mimeType),i.crossDomain||e["X-Requested-With"]||(e["X-Requested-With"]="XMLHttpRequest"),e)r.setRequestHeader(n,e[n]);o=function(e){return function(){o&&(o=a=r.onload=r.onerror=r.onabort=r.ontimeout=r.onreadystatechange=null,"abort"===e?r.abort():"error"===e?"number"!=typeof r.status?t(0,"error"):t(r.status,r.statusText):t(_t[r.status]||r.status,r.statusText,"text"!==(r.responseType||"text")||"string"!=typeof r.responseText?{binary:r.response}:{text:r.responseText},r.getAllResponseHeaders()))}},r.onload=o(),a=r.onerror=r.ontimeout=o("error"),void 0!==r.onabort?r.onabort=a:r.onreadystatechange=function(){4===r.readyState&&C.setTimeout(function(){o&&a()})},o=o("abort");try{r.send(i.hasContent&&i.data||null)}catch(e){if(o)throw e}},abort:function(){o&&o()}}}),S.ajaxPrefilter(function(e){e.crossDomain&&(e.contents.script=!1)}),S.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/\b(?:java|ecma)script\b/},converters:{"text script":function(e){return S.globalEval(e),e}}}),S.ajaxPrefilter("script",function(e){void 0===e.cache&&(e.cache=!1),e.crossDomain&&(e.type="GET")}),S.ajaxTransport("script",function(n){var r,i;if(n.crossDomain||n.scriptAttrs)return{send:function(e,t){r=S("<script>").attr(n.scriptAttrs||{}).prop({charset:n.scriptCharset,src:n.url}).on("load error",i=function(e){r.remove(),i=null,e&&t("error"===e.type?404:200,e.type)}),E.head.appendChild(r[0])},abort:function(){i&&i()}}});var Ut,Xt=[],Vt=/(=)\?(?=&|$)|\?\?/;S.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var e=Xt.pop()||S.expando+"_"+Ct.guid++;return this[e]=!0,e}}),S.ajaxPrefilter("json jsonp",function(e,t,n){var r,i,o,a=!1!==e.jsonp&&(Vt.test(e.url)?"url":"string"==typeof e.data&&0===(e.contentType||"").indexOf("application/x-www-form-urlencoded")&&Vt.test(e.data)&&"data");if(a||"jsonp"===e.dataTypes[0])return r=e.jsonpCallback=m(e.jsonpCallback)?e.jsonpCallback():e.jsonpCallback,a?e[a]=e[a].replace(Vt,"$1"+r):!1!==e.jsonp&&(e.url+=(Et.test(e.url)?"&":"?")+e.jsonp+"="+r),e.converters["script json"]=function(){return o||S.error(r+" was not called"),o[0]},e.dataTypes[0]="json",i=C[r],C[r]=function(){o=arguments},n.always(function(){void 0===i?S(C).removeProp(r):C[r]=i,e[r]&&(e.jsonpCallback=t.jsonpCallback,Xt.push(r)),o&&m(i)&&i(o[0]),o=i=void 0}),"script"}),y.createHTMLDocument=((Ut=E.implementation.createHTMLDocument("").body).innerHTML="<form></form><form></form>",2===Ut.childNodes.length),S.parseHTML=function(e,t,n){return"string"!=typeof e?[]:("boolean"==typeof t&&(n=t,t=!1),t||(y.createHTMLDocument?((r=(t=E.implementation.createHTMLDocument("")).createElement("base")).href=E.location.href,t.head.appendChild(r)):t=E),o=!n&&[],(i=N.exec(e))?[t.createElement(i[1])]:(i=xe([e],t,o),o&&o.length&&S(o).remove(),S.merge([],i.childNodes)));var r,i,o},S.fn.load=function(e,t,n){var r,i,o,a=this,s=e.indexOf(" ");return-1<s&&(r=vt(e.slice(s)),e=e.slice(0,s)),m(t)?(n=t,t=void 0):t&&"object"==typeof t&&(i="POST"),0<a.length&&S.ajax({url:e,type:i||"GET",dataType:"html",data:t}).done(function(e){o=arguments,a.html(r?S("<div>").append(S.parseHTML(e)).find(r):e)}).always(n&&function(e,t){a.each(function(){n.apply(this,o||[e.responseText,t,e])})}),this},S.expr.pseudos.animated=function(t){return S.grep(S.timers,function(e){return t===e.elem}).length},S.offset={setOffset:function(e,t,n){var r,i,o,a,s,u,l=S.css(e,"position"),c=S(e),f={};"static"===l&&(e.style.position="relative"),s=c.offset(),o=S.css(e,"top"),u=S.css(e,"left"),("absolute"===l||"fixed"===l)&&-1<(o+u).indexOf("auto")?(a=(r=c.position()).top,i=r.left):(a=parseFloat(o)||0,i=parseFloat(u)||0),m(t)&&(t=t.call(e,n,S.extend({},s))),null!=t.top&&(f.top=t.top-s.top+a),null!=t.left&&(f.left=t.left-s.left+i),"using"in t?t.using.call(e,f):("number"==typeof f.top&&(f.top+="px"),"number"==typeof f.left&&(f.left+="px"),c.css(f))}},S.fn.extend({offset:function(t){if(arguments.length)return void 0===t?this:this.each(function(e){S.offset.setOffset(this,t,e)});var e,n,r=this[0];return r?r.getClientRects().length?(e=r.getBoundingClientRect(),n=r.ownerDocument.defaultView,{top:e.top+n.pageYOffset,left:e.left+n.pageXOffset}):{top:0,left:0}:void 0},position:function(){if(this[0]){var e,t,n,r=this[0],i={top:0,left:0};if("fixed"===S.css(r,"position"))t=r.getBoundingClientRect();else{t=this.offset(),n=r.ownerDocument,e=r.offsetParent||n.documentElement;while(e&&(e===n.body||e===n.documentElement)&&"static"===S.css(e,"position"))e=e.parentNode;e&&e!==r&&1===e.nodeType&&((i=S(e).offset()).top+=S.css(e,"borderTopWidth",!0),i.left+=S.css(e,"borderLeftWidth",!0))}return{top:t.top-i.top-S.css(r,"marginTop",!0),left:t.left-i.left-S.css(r,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){var e=this.offsetParent;while(e&&"static"===S.css(e,"position"))e=e.offsetParent;return e||re})}}),S.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(t,i){var o="pageYOffset"===i;S.fn[t]=function(e){return $(this,function(e,t,n){var r;if(x(e)?r=e:9===e.nodeType&&(r=e.defaultView),void 0===n)return r?r[i]:e[t];r?r.scrollTo(o?r.pageXOffset:n,o?n:r.pageYOffset):e[t]=n},t,e,arguments.length)}}),S.each(["top","left"],function(e,n){S.cssHooks[n]=$e(y.pixelPosition,function(e,t){if(t)return t=Be(e,n),Me.test(t)?S(e).position()[n]+"px":t})}),S.each({Height:"height",Width:"width"},function(a,s){S.each({padding:"inner"+a,content:s,"":"outer"+a},function(r,o){S.fn[o]=function(e,t){var n=arguments.length&&(r||"boolean"!=typeof e),i=r||(!0===e||!0===t?"margin":"border");return $(this,function(e,t,n){var r;return x(e)?0===o.indexOf("outer")?e["inner"+a]:e.document.documentElement["client"+a]:9===e.nodeType?(r=e.documentElement,Math.max(e.body["scroll"+a],r["scroll"+a],e.body["offset"+a],r["offset"+a],r["client"+a])):void 0===n?S.css(e,t,i):S.style(e,t,n,i)},s,n?e:void 0,n)}})}),S.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(e,t){S.fn[t]=function(e){return this.on(t,e)}}),S.fn.extend({bind:function(e,t,n){return this.on(e,null,t,n)},unbind:function(e,t){return this.off(e,null,t)},delegate:function(e,t,n,r){return this.on(t,e,n,r)},undelegate:function(e,t,n){return 1===arguments.length?this.off(e,"**"):this.off(t,e||"**",n)},hover:function(e,t){return this.mouseenter(e).mouseleave(t||e)}}),S.each("blur focus focusin focusout resize scroll click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup contextmenu".split(" "),function(e,n){S.fn[n]=function(e,t){return 0<arguments.length?this.on(n,null,e,t):this.trigger(n)}});var Gt=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g;S.proxy=function(e,t){var n,r,i;if("string"==typeof t&&(n=e[t],t=e,e=n),m(e))return r=s.call(arguments,2),(i=function(){return e.apply(t||this,r.concat(s.call(arguments)))}).guid=e.guid=e.guid||S.guid++,i},S.holdReady=function(e){e?S.readyWait++:S.ready(!0)},S.isArray=Array.isArray,S.parseJSON=JSON.parse,S.nodeName=A,S.isFunction=m,S.isWindow=x,S.camelCase=X,S.type=w,S.now=Date.now,S.isNumeric=function(e){var t=S.type(e);return("number"===t||"string"===t)&&!isNaN(e-parseFloat(e))},S.trim=function(e){return null==e?"":(e+"").replace(Gt,"")},"function"==typeof define&&define.amd&&define("jquery",[],function(){return S});var Yt=C.jQuery,Qt=C.$;return S.noConflict=function(e){return C.$===S&&(C.$=Qt),e&&C.jQuery===S&&(C.jQuery=Yt),S},"undefined"==typeof e&&(C.jQuery=C.$=S),S});
4; 5/* AUTOGENERATED: jquery-migrate.min.js */ 6/*! jQuery Migrate v3.3.2 | (c) OpenJS Foundation and other contributors | jquery.org/license */ 7"undefined"==typeof jQuery.migrateMute&&(jQuery.migrateMute=!0),function(t){"use strict";"function"==typeof define&&define.amd?define(["jquery"],function(e){return t(e,window)}):"object"==typeof module&&module.exports?module.exports=t(require("jquery"),window):t(jQuery,window)}(function(s,n){"use strict";function e(e){return 0<=function(e,t){for(var r=/^(\d+)\.(\d+)\.(\d+)/,n=r.exec(e)||[],o=r.exec(t)||[],i=1;i<=3;i++){if(+o[i]<+n[i])return 1;if(+n[i]<+o[i])return-1}return 0}(s.fn.jquery,e)}s.migrateVersion="3.3.2",n.console&&n.console.log&&(s&&e("3.0.0")||n.console.log("JQMIGRATE: jQuery 3.0.0+ REQUIRED"),s.migrateWarnings&&n.console.log("JQMIGRATE: Migrate plugin loaded multiple times"),n.console.log("JQMIGRATE: Migrate is installed"+(s.migrateMute?"":" with logging active")+", version "+s.migrateVersion));var r={};function u(e){var t=n.console;s.migrateDeduplicateWarnings&&r[e]||(r[e]=!0,s.migrateWarnings.push(e),t&&t.warn&&!s.migrateMute&&(t.warn("JQMIGRATE: "+e),s.migrateTrace&&t.trace&&t.trace()))}function t(e,t,r,n){Object.defineProperty(e,t,{configurable:!0,enumerable:!0,get:function(){return u(n),r},set:function(e){u(n),r=e}})}function o(e,t,r,n){e[t]=function(){return u(n),r.apply(this,arguments)}}s.migrateDeduplicateWarnings=!0,s.migrateWarnings=[],void 0===s.migrateTrace&&(s.migrateTrace=!0),s.migrateReset=function(){r={},s.migrateWarnings.length=0},"BackCompat"===n.document.compatMode&&u("jQuery is not compatible with Quirks Mode");var i,a,c,d={},l=s.fn.init,p=s.find,f=/\[(\s*[-\w]+\s*)([~|^$*]?=)\s*([-\w#]*?#[-\w#]*)\s*\]/,y=/\[(\s*[-\w]+\s*)([~|^$*]?=)\s*([-\w#]*?#[-\w#]*)\s*\]/g,m=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g;for(i in s.fn.init=function(e){var t=Array.prototype.slice.call(arguments);return"string"==typeof e&&"#"===e&&(u("jQuery( '#' ) is not a valid selector"),t[0]=[]),l.apply(this,t)},s.fn.init.prototype=s.fn,s.find=function(t){var r=Array.prototype.slice.call(arguments);if("string"==typeof t&&f.test(t))try{n.document.querySelector(t)}catch(e){t=t.replace(y,function(e,t,r,n){return"["+t+r+'"'+n+'"]'});try{n.document.querySelector(t),u("Attribute selector with '#' must be quoted: "+r[0]),r[0]=t}catch(e){u("Attribute selector with '#' was not fixed: "+r[0])}}return p.apply(this,r)},p)Object.prototype.hasOwnProperty.call(p,i)&&(s.find[i]=p[i]);o(s.fn,"size",function(){return this.length},"jQuery.fn.size() is deprecated and removed; use the .length property"),o(s,"parseJSON",function(){return JSON.parse.apply(null,arguments)},"jQuery.parseJSON is deprecated; use JSON.parse"),o(s,"holdReady",s.holdReady,"jQuery.holdReady is deprecated"),o(s,"unique",s.uniqueSort,"jQuery.unique is deprecated; use jQuery.uniqueSort"),t(s.expr,"filters",s.expr.pseudos,"jQuery.expr.filters is deprecated; use jQuery.expr.pseudos"),t(s.expr,":",s.expr.pseudos,"jQuery.expr[':'] is deprecated; use jQuery.expr.pseudos"),e("3.1.1")&&o(s,"trim",function(e){return null==e?"":(e+"").replace(m,"")},"jQuery.trim is deprecated; use String.prototype.trim"),e("3.2.0")&&(o(s,"nodeName",function(e,t){return e.nodeName&&e.nodeName.toLowerCase()===t.toLowerCase()},"jQuery.nodeName is deprecated"),o(s,"isArray",Array.isArray,"jQuery.isArray is deprecated; use Array.isArray")),e("3.3.0")&&(o(s,"isNumeric",function(e){var t=typeof e;return("number"==t||"string"==t)&&!isNaN(e-parseFloat(e))},"jQuery.isNumeric() is deprecated"),s.each("Boolean Number String Function Array Date RegExp Object Error Symbol".split(" "),function(e,t){d["[object "+t+"]"]=t.toLowerCase()}),o(s,"type",function(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?d[Object.prototype.toString.call(e)]||"object":typeof e},"jQuery.type is deprecated"),o(s,"isFunction",function(e){return"function"==typeof e},"jQuery.isFunction() is deprecated"),o(s,"isWindow",function(e){return null!=e&&e===e.window},"jQuery.isWindow() is deprecated")),s.ajax&&(a=s.ajax,c=/(=)\?(?=&|$)|\?\?/,s.ajax=function(){var e=a.apply(this,arguments);return e.promise&&(o(e,"success",e.done,"jQXHR.success is deprecated and removed"),o(e,"error",e.fail,"jQXHR.error is deprecated and removed"),o(e,"complete",e.always,"jQXHR.complete is deprecated and removed")),e},e("4.0.0")||s.ajaxPrefilter("+json",function(e){!1!==e.jsonp&&(c.test(e.url)||"string"==typeof e.data&&0===(e.contentType||"").indexOf("application/x-www-form-urlencoded")&&c.test(e.data))&&u("JSON-to-JSONP auto-promotion is deprecated")}));var g=s.fn.removeAttr,h=s.fn.toggleClass,v=/\S+/g;function j(e){return e.replace(/-([a-z])/g,function(e,t){return t.toUpperCase()})}s.fn.removeAttr=function(e){var r=this;return s.each(e.match(v),function(e,t){s.expr.match.bool.test(t)&&(u("jQuery.fn.removeAttr no longer sets boolean properties: "+t),r.prop(t,!1))}),g.apply(this,arguments)};var Q,b=!(s.fn.toggleClass=function(t){return void 0!==t&&"boolean"!=typeof t?h.apply(this,arguments):(u("jQuery.fn.toggleClass( boolean ) is deprecated"),this.each(function(){var e=this.getAttribute&&this.getAttribute("class")||"";e&&s.data(this,"__className__",e),this.setAttribute&&this.setAttribute("class",!e&&!1!==t&&s.data(this,"__className__")||"")}))}),w=/^[a-z]/,x=/^(?:Border(?:Top|Right|Bottom|Left)?(?:Width|)|(?:Margin|Padding)?(?:Top|Right|Bottom|Left)?|(?:Min|Max)?(?:Width|Height))$/;s.swap&&s.each(["height","width","reliableMarginRight"],function(e,t){var r=s.cssHooks[t]&&s.cssHooks[t].get;r&&(s.cssHooks[t].get=function(){var e;return b=!0,e=r.apply(this,arguments),b=!1,e})}),s.swap=function(e,t,r,n){var o,i,a={};for(i in b||u("jQuery.swap() is undocumented and deprecated"),t)a[i]=e.style[i],e.style[i]=t[i];for(i in o=r.apply(e,n||[]),t)e.style[i]=a[i];return o},e("3.4.0")&&"undefined"!=typeof Proxy&&(s.cssProps=new Proxy(s.cssProps||{},{set:function(){return u("JQMIGRATE: jQuery.cssProps is deprecated"),Reflect.set.apply(this,arguments)}})),s.cssNumber||(s.cssNumber={}),Q=s.fn.css,s.fn.css=function(e,t){var r,n,o=this;return e&&"object"==typeof e&&!Array.isArray(e)?(s.each(e,function(e,t){s.fn.css.call(o,e,t)}),this):("number"==typeof t&&(r=j(e),n=r,w.test(n)&&x.test(n[0].toUpperCase()+n.slice(1))||s.cssNumber[r]||u('Number-typed values are deprecated for jQuery.fn.css( "'+e+'", value )')),Q.apply(this,arguments))};var A,k,S,M,N=s.data;s.data=function(e,t,r){var n,o,i;if(t&&"object"==typeof t&&2===arguments.length){for(i in n=s.hasData(e)&&N.call(this,e),o={},t)i!==j(i)?(u("jQuery.data() always sets/gets camelCased names: "+i),n[i]=t[i]):o[i]=t[i];return N.call(this,e,o),t}return t&&"string"==typeof t&&t!==j(t)&&(n=s.hasData(e)&&N.call(this,e))&&t in n?(u("jQuery.data() always sets/gets camelCased names: "+t),2<arguments.length&&(n[t]=r),n[t]):N.apply(this,arguments)},s.fx&&(S=s.Tween.prototype.run,M=function(e){return e},s.Tween.prototype.run=function(){1<s.easing[this.easing].length&&(u("'jQuery.easing."+this.easing.toString()+"' should use only one argument"),s.easing[this.easing]=M),S.apply(this,arguments)},A=s.fx.interval||13,k="jQuery.fx.interval is deprecated",n.requestAnimationFrame&&Object.defineProperty(s.fx,"interval",{configurable:!0,enumerable:!0,get:function(){return n.document.hidden||u(k),A},set:function(e){u(k),A=e}}));var R=s.fn.load,H=s.event.add,C=s.event.fix;s.event.props=[],s.event.fixHooks={},t(s.event.props,"concat",s.event.props.concat,"jQuery.event.props.concat() is deprecated and removed"),s.event.fix=function(e){var t,r=e.type,n=this.fixHooks[r],o=s.event.props;if(o.length){u("jQuery.event.props are deprecated and removed: "+o.join());while(o.length)s.event.addProp(o.pop())}if(n&&!n._migrated_&&(n._migrated_=!0,u("jQuery.event.fixHooks are deprecated and removed: "+r),(o=n.props)&&o.length))while(o.length)s.event.addProp(o.pop());return t=C.call(this,e),n&&n.filter?n.filter(t,e):t},s.event.add=function(e,t){return e===n&&"load"===t&&"complete"===n.document.readyState&&u("jQuery(window).on('load'...) called after load event occurred"),H.apply(this,arguments)},s.each(["load","unload","error"],function(e,t){s.fn[t]=function(){var e=Array.prototype.slice.call(arguments,0);return"load"===t&&"string"==typeof e[0]?R.apply(this,e):(u("jQuery.fn."+t+"() is deprecated"),e.splice(0,0,t),arguments.length?this.on.apply(this,e):(this.triggerHandler.apply(this,e),this))}}),s.each("blur focus focusin focusout resize scroll click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup contextmenu".split(" "),function(e,r){s.fn[r]=function(e,t){return u("jQuery.fn."+r+"
7() event shorthand is deprecated"),0<arguments.length?this.on(r,null,e,t):this.trigger(r)}}),s(function(){s(n.document).triggerHandler("ready")}),s.event.special.ready={setup:function(){this===n.document&&u("'ready' event is deprecated")}},s.fn.extend({bind:function(e,t,r){return u("jQuery.fn.bind() is deprecated"),this.on(e,null,t,r)},unbind:function(e,t){return u("jQuery.fn.unbind() is deprecated"),this.off(e,null,t)},delegate:function(e,t,r,n){return u("jQuery.fn.delegate() is deprecated"),this.on(t,e,r,n)},undelegate:function(e,t,r){return u("jQuery.fn.undelegate() is deprecated"),1===arguments.length?this.off(e,"**"):this.off(t,e||"**",r)},hover:function(e,t){return u("jQuery.fn.hover() is deprecated"),this.on("mouseenter",e).on("mouseleave",t||e)}});function T(e){var t=n.document.implementation.createHTMLDocument("");return t.body.innerHTML=e,t.body&&t.body.innerHTML}function P(e){var t=e.replace(O,"<$1></$2>");t!==e&&T(e)!==T(t)&&u("HTML tags must be properly nested and closed: "+e)}var O=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([a-z][^\/\0>\x20\t\r\n\f]*)[^>]*)\/>/gi,q=s.htmlPrefilter;s.UNSAFE_restoreLegacyHtmlPrefilter=function(){s.htmlPrefilter=function(e){return P(e),e.replace(O,"<$1></$2>")}},s.htmlPrefilter=function(e){return P(e),q(e)};var D,_=s.fn.offset;s.fn.offset=function(){var e=this[0];return!e||e.nodeType&&e.getBoundingClientRect?_.apply(this,arguments):(u("jQuery.fn.offset() requires a valid DOM element"),arguments.length?this:void 0)},s.ajax&&(D=s.param,s.param=function(e,t){var r=s.ajaxSettings&&s.ajaxSettings.traditional;return void 0===t&&r&&(u("jQuery.param() no longer uses jQuery.ajaxSettings.traditional"),t=r),D.call(this,e,t)});var E,F,J=s.fn.andSelf||s.fn.addBack;return s.fn.andSelf=function(){return u("jQuery.fn.andSelf() is deprecated and removed, use jQuery.fn.addBack()"),J.apply(this,arguments)},s.Deferred&&(E=s.Deferred,F=[["resolve","done",s.Callbacks("once memory"),s.Callbacks("once memory"),"resolved"],["reject","fail",s.Callbacks("once memory"),s.Callbacks("once memory"),"rejected"],["notify","progress",s.Callbacks("memory"),s.Callbacks("memory")]],s.Deferred=function(e){var i=E(),a=i.promise();return i.pipe=a.pipe=function(){var o=arguments;return u("deferred.pipe() is deprecated"),s.Deferred(function(n){s.each(F,function(e,t){var r="function"==typeof o[e]&&o[e];i[t[1]](function(){var e=r&&r.apply(this,arguments);e&&"function"==typeof e.promise?e.promise().done(n.resolve).fail(n.reject).progress(n.notify):n[t[0]+"With"](this===a?n.promise():this,r?[e]:arguments)})}),o=null}).promise()},e&&e.call(i,i),i},s.Deferred.exceptionHook=E.exceptionHook),s});; 8/* AUTOGENERATED: jquery-ui.min.js */
vendor: 33,137 bytes, lines 9-14
9/*! jQuery UI - v1.12.1 - 2016-09-14 10* http://jqueryui.com 11* Includes: widget.js, position.js, data.js, disable-selection.js, effect.js, effects/effect-blind.js, effects/effect-bounce.js, effects/effect-clip.js, effects/effect-drop.js, effects/effect-explode.js, effects/effect-fade.js, effects/effect-fold.js, effects/effect-highlight.js, effects/effect-puff.js, effects/effect-pulsate.js, effects/effect-scale.js, effects/effect-shake.js, effects/effect-size.js, effects/effect-slide.js, effects/effect-transfer.js, focusable.js, form-reset-mixin.js, jquery-1-7.js, keycode.js, labels.js, scroll-parent.js, tabbable.js, unique-id.js, widgets/accordion.js, widgets/autocomplete.js, widgets/button.js, widgets/checkboxradio.js, widgets/controlgroup.js, widgets/datepicker.js, widgets/dialog.js, widgets/draggable.js, widgets/droppable.js, widgets/menu.js, widgets/mouse.js, widgets/progressbar.js, widgets/resizable.js, widgets/selectable.js, widgets/selectmenu.js, widgets/slider.js, widgets/sortable.js, widgets/spinner.js, widgets/tabs.js, widgets/tooltip.js 12* Copyright jQuery Foundation and other contributors; Licensed MIT */ 13 14(function(t){"function"==typeof define&&define.amd?define(["jquery"],t):t(jQuery)})(function(t){function e(t){for(var e=t.css("visibility");"inherit"===e;)t=t.parent(),e=t.css("visibility");return"hidden"!==e}function i(t){for(var e,i;t.length&&t[0]!==document;){if(e=t.css("position"),("absolute"===e||"relative"===e||"fixed"===e)&&(i=parseInt(t.css("zIndex"),10),!isNaN(i)&&0!==i))return i;t=t.parent()}return 0}function s(){this._curInst=null,this._keyEvent=!1,this._disabledInputs=[],this._datepickerShowing=!1,this._inDialog=!1,this._mainDivId="ui-datepicker-div",this._inlineClass="ui-datepicker-inline",this._appendClass="ui-datepicker-append",this._triggerClass="ui-datepicker-trigger",this._dialogClass="ui-datepicker-dialog",this._disableClass="ui-datepicker-disabled",this._unselectableClass="ui-datepicker-unselectable",this._currentClass="ui-datepicker-current-day",this._dayOverClass="ui-datepicker-days-cell-over",this.regional=[],this.regional[""]={closeText:"Done",prevText:"Prev",nextText:"Next",currentText:"Today",monthNames:["January","February","March","April","May","June","July","August","September","October","November","December"],monthNamesShort:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],dayNames:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],dayNamesShort:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],dayNamesMin:["Su","Mo","Tu","We","Th","Fr","Sa"],weekHeader:"Wk",dateFormat:"mm/dd/yy",firstDay:0,isRTL:!1,showMonthAfterYear:!1,yearSuffix:""},this._defaults={showOn:"focus",showAnim:"fadeIn",showOptions:{},defaultDate:null,appendText:"",buttonText:"...",buttonImage:"",buttonImageOnly:!1,hideIfNoPrevNext:!1,navigationAsDateFormat:!1,gotoCurrent:!1,changeMonth:!1,changeYear:!1,yearRange:"c-10:c+10",showOtherMonths:!1,selectOtherMonths:!1,showWeek:!1,calculateWeek:this.iso8601Week,shortYearCutoff:"+10",minDate:null,maxDate:null,duration:"fast",beforeShowDay:null,beforeShow:null,onSelect:null,onChangeMonthYear:null,onClose:null,numberOfMonths:1,showCurrentAtPos:0,stepMonths:1,stepBigMonths:12,altField:"",altFormat:"",constrainInput:!0,showButtonPanel:!1,autoSize:!1,disabled:!1},t.extend(this._defaults,this.regional[""]),this.regional.en=t.extend(!0,{},this.regional[""]),this.regional["en-US"]=t.extend(!0,{},this.regional.en),this.dpDiv=n(t("<div id='"+this._mainDivId+"' class='ui-datepicker ui-widget ui-widget-content ui-helper-clearfix ui-corner-all'></div>"))}function n(e){var i="button, .ui-datepicker-prev, .ui-datepicker-next, .ui-datepicker-calendar td a";return e.on("mouseout",i,function(){t(this).removeClass("ui-state-hover"),-1!==this.className.indexOf("ui-datepicker-prev")&&t(this).removeClass("ui-datepicker-prev-hover"),-1!==this.className.indexOf("ui-datepicker-next")&&t(this).removeClass("ui-datepicker-next-hover")}).on("mouseover",i,o)}function o(){t.datepicker._isDisabledDatepicker(m.inline?m.dpDiv.parent()[0]:m.input[0])||(t(this).parents(".ui-datepicker-calendar").find("a").removeClass("ui-state-hover"),t(this).addClass("ui-state-hover"),-1!==this.className.indexOf("ui-datepicker-prev")&&t(this).addClass("ui-datepicker-prev-hover"),-1!==this.className.indexOf("ui-datepicker-next")&&t(this).addClass("ui-datepicker-next-hover"))}function a(e,i){t.extend(e,i);for(var s in i)null==i[s]&&(e[s]=i[s]);return e}function r(t){return function(){var e=this.element.val();t.apply(this,arguments),this._refresh(),e!==this.element.val()&&this._trigger("change")}}t.ui=t.ui||{},t.ui.version="1.12.1";var h=0,l=Array.prototype.slice;t.cleanData=function(e){return function(i){var s,n,o;for(o=0;null!=(n=i[o]);o++)try{s=t._data(n,"events"),s&&s.remove&&t(n).triggerHandler("remove")}catch(a){}e(i)}}(t.cleanData),t.widget=function(e,i,s){var n,o,a,r={},h=e.split(".")[0];e=e.split(".")[1];var l=h+"-"+e;return s||(s=i,i=t.Widget),t.isArray(s)&&(s=t.extend.apply(null,[{}].concat(s))),t.expr[":"][l.toLowerCase()]=function(e){return!!t.data(e,l)},t[h]=t[h]||{},n=t[h][e],o=t[h][e]=function(t,e){return this._createWidget?(arguments.length&&this._createWidget(t,e),void 0):new o(t,e)},t.extend(o,n,{version:s.version,_proto:t.extend({},s),_childConstructors:[]}),a=new i,a.options=t.widget.extend({},a.options),t.each(s,function(e,s){return t.isFunction(s)?(r[e]=function(){function t(){return i.prototype[e].apply(this,arguments)}function n(t){return i.prototype[e].apply(this,t)}return function(){var e,i=this._super,o=this._superApply;return this._super=t,this._superApply=n,e=s.apply(this,arguments),this._super=i,this._superApply=o,e}}(),void 0):(r[e]=s,void 0)}),o.prototype=t.widget.extend(a,{widgetEventPrefix:n?a.widgetEventPrefix||e:e},r,{constructor:o,namespace:h,widgetName:e,widgetFullName:l}),n?(t.each(n._childConstructors,function(e,i){var s=i.prototype;t.widget(s.namespace+"."+s.widgetName,o,i._proto)}),delete n._childConstructors):i._childConstructors.push(o),t.widget.bridge(e,o),o},t.widget.extend=function(e){for(var i,s,n=l.call(arguments,1),o=0,a=n.length;a>o;o++)for(i in n[o])s=n[o][i],n[o].hasOwnProperty(i)&&void 0!==s&&(e[i]=t.isPlainObject(s)?t.isPlainObject(e[i])?t.widget.extend({},e[i],s):t.widget.extend({},s):s);return e},t.widget.bridge=function(e,i){var s=i.prototype.widgetFullName||e;t.fn[e]=function(n){var o="string"==typeof n,a=l.call(arguments,1),r=this;return o?this.length||"instance"!==n?this.each(function(){var i,o=t.data(this,s);return"instance"===n?(r=o,!1):o?t.isFunction(o[n])&&"_"!==n.charAt(0)?(i=o[n].apply(o,a),i!==o&&void 0!==i?(r=i&&i.jquery?r.pushStack(i.get()):i,!1):void 0):t.error("no such method '"+n+"' for "+e+" widget instance"):t.error("cannot call methods on "+e+" prior to initialization; "+"attempted to call method '"+n+"'")}):r=void 0:(a.length&&(n=t.widget.extend.apply(null,[n].concat(a))),this.each(function(){var e=t.data(this,s);e?(e.option(n||{}),e._init&&e._init()):t.data(this,s,new i(n,this))})),r}},t.Widget=function(){},t.Widget._childConstructors=[],t.Widget.prototype={widgetName:"widget",widgetEventPrefix:"",defaultElement:"<div>",options:{classes:{},disabled:!1,create:null},_createWidget:function(e,i){i=t(i||this.defaultElement||this)[0],this.element=t(i),this.uuid=h++,this.eventNamespace="."+this.widgetName+this.uuid,this.bindings=t(),this.hoverable=t(),this.focusable=t(),this.classesElementLookup={},i!==this&&(t.data(i,this.widgetFullName,this),this._on(!0,this.element,{remove:function(t){t.target===i&&this.destroy()}}),this.document=t(i.style?i.ownerDocument:i.document||i),this.window=t(this.document[0].defaultView||this.document[0].parentWindow)),this.options=t.widget.extend({},this.options,this._getCreateOptions(),e),this._create(),this.options.disabled&&this._setOptionDisabled(this.options.disabled),this._trigger("create",null,this._getCreateEventData()),this._init()},_getCreateOptions:function(){return{}},_getCreateEventData:t.noop,_create:t.noop,_init:t.noop,destroy:function(){var e=this;this._destroy(),t.each(this.classesElementLookup,function(t,i){e._removeClass(i,t)}),this.element.off(this.eventNamespace).removeData(this.widgetFullName),this.widget().off(this.eventNamespace).removeAttr("aria-disabled"),this.bindings.off(this.eventNamespace)},_destroy:t.noop,widget:function(){return this.element},option:function(e,i){var s,n,o,a=e;if(0===arguments.length)return t.widget.extend({},this.options);if("string"==typeof e)if(a={},s=e.split("."),e=s.shift(),s.length){for(n=a[e]=t.widget.extend({},this.options[e]),o=0;s.length-1>o;o++)n[s[o]]=n[s[o]]||{},n=n[s[o]];if(e=s.pop(),1===arguments.length)return void 0===n[e]?null:n[e];n[e]=i}else{if(1===arguments.length)return void 0===this.options[e]?null:this.options[e];a[e]=i}return this._setOptions(a),this},_setOptions:function(t){var e;for(e in t)this._setOption(e,t[e]);return this},_setOption:function(t,e){return"classes"===t&&this._setOptionClasses(e),this.options[t]=e,"disabled"===t&&this._setOptionDisabled(e),this},_setOptionClasses:function(e){var i,s,n;for(i in e)n=this.classesElementLookup[i],e[i]!==this.options.classes[i]&&n&&n.length&&(s=t(n.get()),this._removeClass(n,i),s.addClass(this._classes({element:s,keys:i,classes:e,add:!0})))},_setOptionDisabled:function(t){this._toggleClass(this.widget(),this.widgetFullName+"-disabled",null,!!t),t&&(this._removeClass(this.hoverable,null,"ui-state-hover"),this._removeClass(this.focusable,null,"ui-state-focus"))},enable:function(){return this._setOptions({disabled:!1})},disable:function(){return this._setOptions({disabled:!0})},_classes:function(e){function i(i,o){var a,r;for(r=0;i.length>r;r++)a=n.classesElementLookup[i[r]]||t(),a=e.add?t(t.unique(a.get().concat(e.element.get()))):t(a.not(e.element).get()),n.classesElementLookup[i[r]]=a,s.push(i[r]),o&&e.classes[i[r]]&&s.push(e.classes[i[r]])}var s=[],n=this;return e=t.extend({element:this.element,classes:this.options.classes||{}},e),this._on(e.element,{remove:"_untrackClassesElement"}),e.keys&&i(e.keys.match(/\S+/g)||[],!0),e.extra&&i(e.extra.match(/\S+/g)||[]),s.join(" ")},_untrackClassesElement:function(e){var i=this;t.each(i.classesElementLookup,function(s,n){-1!==t.inArray(e.target,n)&&(i.classesElementLookup[s]=t(n.not(e.target).get()))})},_removeClass:function(t,e,i){return this._toggleClass(t,e,i,!1)},_addClass:function(t,e,i){return this._toggleClass(t,e,i,!0)},_toggleClass:function(t,e,i,s){s="boolean"==typeof s?s:i;var n="string"==typeof t||null===t,o={extra:n?e:i,keys:n?t:e,element:n?this.element:t,add:s};return o.element.toggleClass(this._classes(o),s),this},_on:function(e,i,s){var n,o=this;"boolean"!=typeof e&&(s=i,i=e,e=!1),s?(i=n=t(i),this.bindings=this.bindings.add(i)):(s=i,i=this.element,n=this.widget()),t.each(s,function(s,a){function r(){return e||o.options.disabled!==!0&&!t(this).hasClass("ui-state-disabled")?("string"==typeof a?o[a]:a).apply(o,arguments):void 0}"string"!=typeof a&&(r.guid=a.guid=a.guid||r.guid||t.guid++);var h=s.match(/^([\w:-]*)\s*(.*)$/),l=h[1]+o.eventNamespace,c=h[2];c?n.on(l,c,r):i.on(l,r)})},_off:function(e,i){i=(i||"").split(" ").join(this.eventNamespace+" ")+this.eventNamespace,e.off(i).off(i),this.bindings=t(this.bindings.not(e).get()),this.focusable=t(this.focusable.not(e).get()),this.hoverable=t(this.hoverable.not(e).get())},_delay:function(t,e){function i(){return("string"==typeof t?s[t]:t).apply(s,arguments)}var s=this;return setTimeout(i,e||0)},_hoverable:function(e){this.hoverable=this.hoverable.add(e),this._on(e,{mouseenter:function(e){this._addClass(t(e.currentTarget),null,"ui-state-hover")},mouseleave:function(e){this._removeClass(t(e.currentTarget),null,"ui-state-hover")}})},_focusable:function(e){this.focusable=this.focusable.add(e),this._on(e,{focusin:function(e){this._addClass(t(e.currentTarget),null,"ui-state-focus")},focusout:function(e){this._removeClass(t(e.currentTarget),null,"ui-state-focus")}})},_trigger:function(e,i,s){var n,o,a=this.options[e];if(s=s||{},i=t.Event(i),i.type=(e===this.widgetEventPrefix?e:this.widgetEventPrefix+e).toLowerCase(),i.target=this.element[0],o=i.originalEvent)for(n in o)n in i||(i[n]=o[n]);return this.element.trigger(i,s),!(t.isFunction(a)&&a.apply(this.element[0],[i].concat(s))===!1||i.isDefaultPrevented())}},t.each({show:"fadeIn",hide:"fadeOut"},function(e,i){t.Widget.prototype["_"+e]=function(s,n,o){"string"==typeof n&&(n={effect:n});var a,r=n?n===!0||"number"==typeof n?i:n.effect||i:e;n=n||{},"number"==typeof n&&(n={duration:n}),a=!t.isEmptyObject(n),n.complete=o,n.delay&&s.delay(n.delay),a&&t.effects&&t.effects.effect[r]?s[e](n):r!==e&&s[r]?s[r](n.duration,n.easing,o):s.queue(function(i){t(this)[e](),o&&o.call(s[0]),i()})}}),t.widget,function(){function e(t,e,i){return[parseFloat(t[0])*(u.test(t[0])?e/100:1),parseFloat(t[1])*(u.test(t[1])?i/100:1)]}function i(e,i){return parseInt(t.css(e,i),10)||0}function s(e){var i=e[0];return 9===i.nodeType?{width:e.width(),height:e.height(),offset:{top:0,left:0}}:t.isWindow(i)?{width:e.width(),height:e.height(),offset:{top:e.scrollTop(),left:e.scrollLeft()}}:i.preventDefault?{width:0,height:0,offset:{top:i.pageY,left:i.pageX}}:{width:e.outerWidth(),height:e.outerHeight(),offset:e.offset()}}var n,o=Math.max,a=Math.abs,r=/left|center|right/,h=/top|center|bottom/,l=/[\+\-]\d+(\.[\d]+)?%?/,c=/^\w+/,u=/%$/,d=t.fn.position;t.position={scrollbarWidth:function(){if(void 0!==n)return n;var e,i,s=t("<div style='display:block;position:absolute;width:50px;height:50px;overflow:hidden;'><div style='height:100px;width:auto;'></div></div>"),o=s.children()[0];return t("body").append(s),e=o.offsetWidth,s.css("overflow","scroll"),i=o.offsetWidth,e===i&&(i=s[0].clientWidth),s.remove(),n=e-i},getScrollInfo:function(e){var i=e.isWindow||e.isDocument?"":e.element.css("overflow-x"),s=e.isWindow||e.isDocument?"":e.element.css("overflow-y"),n="scroll"===i||"auto"===i&&e.width<e.element[0].scrollWidth,o="scroll"===s||"auto"===s&&e.height<e.element[0].scrollHeight;return{width:o?t.position.scrollbarWidth():0,height:n?t.position.scrollbarWidth():0}},getWithinInfo:function(e){var i=t(e||window),s=t.isWindow(i[0]),n=!!i[0]&&9===i[0].nodeType,o=!s&&!n;return{element:i,isWindow:s,isDocument:n,offset:o?t(e).offset():{left:0,top:0},scrollLeft:i.scrollLeft(),scrollTop:i.scrollTop(),width:i.outerWidth(),height:i.outerHeight()}}},t.fn.position=function(n){if(!n||!n.of)return d.apply(this,arguments);n=t.extend({},n);var u,p,f,g,m,_,v=t(n.of),b=t.position.getWithinInfo(n.within),y=t.position.getScrollInfo(b),w=(n.collision||"flip").split(" "),k={};return _=s(v),v[0].preventDefault&&(n.at="left top"),p=_.width,f=_.height,g=_.offset,m=t.extend({},g),t.each(["my","at"],function(){var t,e,i=(n[this]||"").split(" ");1===i.length&&(i=r.test(i[0])?i.concat(["center"]):h.test(i[0])?["center"].concat(i):["center","center"]),i[0]=r.test(i[0])?i[0]:"center",i[1]=h.test(i[1])?i[1]:"center",t=l.exec(i[0]),e=l.exec(i[1]),k[this]=[t?t[0]:0,e?e[0]:0],n[this]=[c.exec(i[0])[0],c.exec(i[1])[0]]}),1===w.length&&(w[1]=w[0]),"right"===n.at[0]?m.left+=p:"center"===n.at[0]&&(m.left+=p/2),"bottom"===n.at[1]?m.top+=f:"center"===n.at[1]&&(m.top+=f/2),u=e(k.at,p,f),m.left+=u[0],m.top+=u[1],this.each(function(){var s,r,h=t(this),l=h.outerWidth(),c=h.outerHeight(),d=i(this,"marginLeft"),_=i(this,"marginTop"),x=l+d+i(this,"marginRight")+y.width,C=c+_+i(this,"marginBottom")+y.height,D=t.extend({},m),I=e(k.my,h.outerWidth(),h.outerHeight());"right"===n.my[0]?D.left-=l:"center"===n.my[0]&&(D.left-=l/2),"bottom"===n.my[1]?D.top-=c:"center"===n.my[1]&&(D.top-=c/2),D.left+=I[0],D.top+=I[1],s={marginLeft:d,marginTop:_},t.each(["left","top"],function(e,i){t.ui.position[w[e]]&&t.ui.position[w[e]][i](D,{targetWidth:p,targetHeight:f,elemWidth:l,elemHeight:c,collisionPosition:s,collisionWidth:x,collisionHeight:C,offset:[u[0]+I[0],u[1]+I[1]],my:n.my,at:n.at,within:b,elem:h})}),n.using&&(r=function(t){var e=g.left-D.left,i=e+p-l,s=g.top-D.top,r=s+f-c,u={target:{element:v,left:g.left,top:g.top,width:p,height:f},element:{element:h,left:D.left,top:D.top,width:l,height:c},horizontal:0>i?"left":e>0?"right":"center",vertical:0>r?"top":s>0?"bottom":"middle"};l>p&&p>a(e+i)&&(u.horizontal="center"),c>f&&f>a(s+r)&&(u.vertical="middle"),u.important=o(a(e),a(i))>o(a(s),a(r))?"horizontal":"vertical",n.using.call(this,t,u)}),h.offset(t.extend(D,{using:r}))})},t.ui.position={fit:{left:function(t,e){var i,s=e.within,n=s.isWindow?s.scrollLeft:s.offset.left,a=s.width,r=t.left-e.collisionPosition.marginLeft,h=n-r,l=r+e.collisionWidth-a-n;e.collisionWidth>a?h>0&&0>=l?(i=t.left+h+e.collisionWidth-a-n,t.left+=h-i):t.left=l>0&&0>=h?n:h>l?n+a-e.collisionWidth:n:h>0?t.left+=h:l>0?t.left-=l:t.left=o(t.left-r,t.left)},top:function(t,e){var i,s=e.within,n=s.isWindow?s.scrollTop:s.offset.top,a=e.within.height,r=t.top-e.collisionPosition.marginTop,h=n-r,l=r+e.collisionHeight-a-n;e.collisionHeight>a?h>0&&0>=l?(i=t.top+h+e.collisionHeight-a-n,t.top+=h-i):t.top=l>0&&0>=h?n:h>l?n+a-e.collisionHeight:n:h>0?t.top+=h:l>0?t.top-=l:t.top=o(t.top-r,t.top)}},flip:{left:function(t,e){var i,s,n=e.within,o=n.offset.left+n.scrollLeft,r=n.width,h=n.isWindow?n.scrollLeft:n.offset.left,l=t.left-e.collisionPosition.marginLeft,c=l-h,u=l+e.collisionWidth-r-h,d="left"===e.my[0]?-e.elemWidth:"right"===e.my[0]?e.elemWidth:0,p="left"===e.at[0]?e.targetWidth:"right"===e.at[0]?-e.targetWidth:0,f=-2*e.offset[0];0>c?(i=t.left+d+p+f+e.collisionWidth-r-o,(0>i||a(c)>i)&&(t.left+=d+p+f)):u>0&&(s=t.left-e.collisionPosition.marginLeft+d+p+f-h,(s>0||u>a(s))&&(t.left+=d+p+f))},top:function(t,e){var i,s,n=e.within,o=n.offset.top+n.scrollTop,r=n.height,h=n.isWindow?n.scrollTop:n.offset.top,l=t.top-e.collisionPosition.marginTop,c=l-h,u=l+e.collisionHeight-r-h,d="top"===e.my[1],p=d?-e.elemHeight:"bottom"===e.my[1]?e.elemHeight:0,f="top"===e.at[1]?e.targetHeight:"bottom"===e.at[1]?-e.targetHeight:0,g=-2*e.offset[1];0>c?(s=t.top+p+f+g+e.collisionHeight-r-o,(0>s||a(c)>s)&&(t.top+=p+f+g)):u>0&&(i=t.top-e.collisionPosition.marginTop+p+f+g-h,(i>0||u>a(i))&&(t.top+=p+f+g))}},flipfit:{left:function(){t.ui.position.flip.left.apply(this,arguments),t.ui.position.fit.left.apply(this,arguments)},top:function(){t.ui.position.flip.top.apply(this,arguments),t.ui.position.fit.top.apply(this,arguments)}}}}(),t.ui.position,t.extend(t.expr[":"],{data:t.expr.createPseudo?t.expr.createPseudo(function(e){return function(i){return!!t.data(i,e)}}):function(e,i,s){return!!t.data(e,s[3])}}),t.fn.extend({disableSelection:function(){var t="onselectstart"in document.createElement("div")?"selectstart":"mousedown";return function(){return this.on(t+".ui-disableSelection",function(t){t.preventDefault()})}}(),enableSelection:function(){return this.off(".ui-disableSelection")}});var c="ui-effects-",u="ui-effects-style",d="ui-effects-animated",p=t;t.effects={effect:{}},function(t,e){function i(t,e,i){var s=u[e.type]||{};return null==t?i||!e.def?null:e.def:(t=s.floor?~~t:parseFloat(t),isNaN(t)?e.def:s.mod?(t+s.mod)%s.mod:0>t?0:t>s.max?s.max:t)}function s(i){var s=l(),n=s._rgba=[];return i=i.toLowerCase(),f(h,function(t,o){var a,r=o.re.exec(i),h=r&&o.parse(r),l=o.space||"rgba";return h?(a=s[l](h),s[c[l].cache]=a[c[l].cache],n=s._rgba=a._rgba,!1):e}),n.length?("0,0,0,0"===n.join()&&t.extend(n,o.transparent),s):o[i]}function n(t,e,i){return i=(i+1)%1,1>6*i?t+6*(e-t)*i:1>2*i?e:2>3*i?t+6*(e-t)*(2/3-i):t}var o,a="backgroundColor borderBottomColor borderLeftColor borderRightColor borderTopColor color columnRuleColor outlineColor textDecorationColor textEmphasisColor",r=/^([\-+])=\s*(\d+\.?\d*)/,h=[{re:/rgba?\(\s*(\d{1,3})\s*,\s*(\d{1,3})\s*,\s*(\d{1,3})\s*(?:,\s*(\d?(?:\.\d+)?)\s*)?\)/,parse:function(t){return[t[1],t[2],t[3],t[4]]}},{re:/rgba?\(\s*(\d+(?:\.\d+)?)\%\s*,\s*(\d+(?:\.\d+)?)\%\s*,\s*(\d+(?:\.\d+)?)\%\s*(?:,\s*(\d?(?:\.\d+)?)\s*)?\)/,parse:function(t){return[2.55*t[1],2.55*t[2],2.55*t[3],t[4]]}},{re:/#([a-f0-9]{2})([a-f0-9]{2})([a-f0-9]{2})/,parse:function(t){return[parseInt(t[1],16),parseInt(t[2],16),parseInt(t[3],16)]}},{re:/#([a-f0-9])([a-f0-9])([a-f0-9])/,parse:function(t){return[parseInt(t[1]+t[1],16),parseInt(t[2]+t[2],16),parseInt(t[3]+t[3],16)]}},{re:/hsla?\(\s*(\d+(?:\.\d+)?)\s*,\s*(\d+(?:\.\d+)?)\%\s*,\s*(\d+(?:\.\d+)?)\%\s*(?:,\s*(\d?(?:\.\d+)?)\s*)?\)/,space:"hsla",parse:function(t){return[t[1],t[2]/100,t[3]/100,t[4]]}}],l=t.Color=function(e,i,s,n){return new t.Color.fn.parse(e,i,s,n)},c={rgba:{props:{red:{idx:0,type:"byte"},green:{idx:1,type:"byte"},blue:{idx:2,type:"byte"}}},hsla:{props:{hue:{idx:0,type:"degrees"},saturation:{idx:1,type:"percent"},lightness:{idx:2,type:"percent"}}}},u={"byte":{floor:!0,max:255},percent:{max:1},degrees:{mod:360,floor:!0}},d=l.support={},p=t("<p>")[0],f=t.each;p.style.cssText="background-color:rgba(1,1,1,.5)",d.rgba=p.style.backgroundColor.indexOf("rgba")>-1,f(c,function(t,e){e.cache="_"+t,e.props.alpha={idx:3,type:"percent",def:1}}),l.fn=t.extend(l.prototype,{parse:function(n,a,r,h){if(n===e)return this._rgba=[null,null,null,null],this;(n.jquery||n.nodeType)&&(n=t(n).css(a),a=e);var u=this,d=t.type(n),p=this._rgba=[];return a!==e&&(n=[n,a,r,h],d="array"),"string"===d?this.parse(s(n)||o._default):"array"===d?(f(c.rgba.props,function(t,e){p[e.idx]=i(n[e.idx],e)}),this):"object"===d?(n instanceof l?f(c,function(t,e){n[e.cache]&&(u[e.cache]=n[e.cache].slice())}):f(c,function(e,s){var o=s.cache;f(s.props,function(t,e){if(!u[o]&&s.to){if("alpha"===t||null==n[t])return;u[o]=s.to(u._rgba)}u[o][e.idx]=i(n[t],e,!0)}),u[o]&&0>t.inArray(null,u[o].slice(0,3))&&(u[o][3]=1,s.from&&(u._rgba=s.from(u[o])))}),this):e},is:function(t){var i=l(t),s=!0,n=this;return f(c,function(t,o){var a,r=i[o.cache];return r&&(a=n[o.cache]||o.to&&o.to(n._rgba)||[],f(o.props,function(t,i){return null!=r[i.idx]?s=r[i.idx]===a[i.idx]:e})),s}),s},_space:function(){var t=[],e=this;return f(c,function(i,s){e[s.cache]&&t.push(i)}),t.pop()},transition:function(t,e){var s=l(t),n=s._space(),o=c[n],a=0===this.alpha()?l("transparent"):this,r=a[o.cache]||o.to(a._rgba),h=r.slice();return s=s[o.cache],f(o.props,function(t,n){var o=n.idx,a=r[o],l=s[o],c=u[n.type]||{};null!==l&&(null===a?h[o]=l:(c.mod&&(l-a>c.mod/2?a+=c.mod:a-l>c.mod/2&&(a-=c.mod)),h[o]=i((l-a)*e+a,n)))}),this[n](h)},blend:function(e){if(1===this._rgba[3])return this;var i=this._rgba.slice(),s=i.pop(),n=l(e)._rgba;return l(t.map(i,function(t,e){return(1-s)*n[e]+s*t}))},toRgbaString:function(){var e="rgba(",i=t.map(this._rgba,function(t,e){return null==t?e>2?1:0:t});return 1===i[3]&&(i.pop(),e="rgb("),e+i.join()+")"},toHslaString:function(){var e="hsla(",i=t.map(this.hsla(),function(t,e){return null==t&&(t=e>2?1:0),e&&3>e&&(t=Math.round(100*t)+"%"),t});return 1===i[3]&&(i.pop(),e="hsl("),e+i.join()+")"},toHexString:function(e){var i=this._rgba.slice(),s=i.pop();return e&&i.push(~~(255*s)),"#"+t.map(i,function(t){return t=(t||0).toString(16),1===t.length?"0"+t:t}).join("")},toString:function(){return 0===this._rgba[3]?"transparent":this.toRgbaString()}}),l.fn.parse.prototype=l.fn,c.hsla.to=function(t){if(null==t[0]||null==t[1]||null==t[2])return[null,null,null,t[3]];var e,i,s=t[0]/255,n=t[1]/255,o=t[2]/255,a=t[3],r=Math.max(s,n,o),h=Math.min(s,n,o),l=r-h,c=r+h,u=.5*c;return e=h===r?0:s===r?60*(n-o)/l+360:n===r?60*(o-s)/l+120:60*(s-n)/l+240,i=0===l?0:.5>=u?l/c:l/(2-c),[Math.round(e)%360,i,u,null==a?1:a]},c.hsla.from=function(t){if(null==t[0]||null==t[1]||null==t[2])return[null,null,null,t[3]];var e=t[0]/360,i=t[1],s=t[2],o=t[3],a=.5>=s?s*(1+i):s+i-s*i,r=2*s-a;return[Math.round(255*n(r,a,e+1/3)),Math.round(255*n(r,a,e)),Math.round(255*n(r,a,e-1/3)),o]},f(c,function(s,n){var o=n.props,a=n.cache,h=n.to,c=n.from;l.fn[s]=function(s){if(h&&!this[a]&&(this[a]=h(this._rgba)),s===e)return this[a].slice();var n,r=t.type(s),u="array"===r||"object"===r?s:arguments,d=this[a].slice();return f(o,function(t,e){var s=u["object"===r?t:e.idx];null==s&&(s=d[e.idx]),d[e.idx]=i(s,e)}),c?(n=l(c(d)),n[a]=d,n):l(d)},f(o,function(e,i){l.fn[e]||(l.fn[e]=function(n){var o,a=t.type(n),h="alpha"===e?this._hsla?"hsla":"rgba":s,l=this[h](),c=l[i.idx];return"undefined"===a?c:("function"===a&&(n=n.call(this,c),a=t.type(n)),null==n&&i.empty?this:("string"===a&&(o=r.exec(n),o&&(n=c+parseFloat(o[2])*("+"===o[1]?1:-1))),l[i.idx]=n,this[h](l)))})})}),l.hook=function(e){var i=e.split(" ");f(i,function(e,i){t.cssHooks[i]={set:function(e,n){var o,a,r="";if("transparent"!==n&&("string"!==t.type(n)||(o=s(n)))){if(n=l(o||n),!d.rgba&&1!==n._rgba[3]){for(a="backgroundColor"===i?e.parentNode:e;(""===r||"transparent"===r)&&a&&a.style;)try{r=t.css(a,"backgroundColor"),a=a.parentNode}catch(h){}n=n.blend(r&&"transparent"!==r?r:"_default")}n=n.toRgbaString()}try{e.style[i]=n}catch(h){}}},t.fx.step[i]=function(e){e.colorInit||(e.start=l(e.elem,i),e.end=l(e.end),e.colorInit=!0),t.cssHooks[i].set(e.elem,e.start.transition(e.end,e.pos))}})},l.hook(a),t.cssHooks.borderColor={expand:function(t){var e={};return f(["Top","Right","Bottom","Left"],function(i,s){e["border"+s+"Color"]=t}),e}},o=t.Color.names={aqua:"#00ffff",black:"#000000",blue:"#0000ff",fuchsia:"#ff00ff",gray:"#808080",green:"#008000",lime:"#00ff00",maroon:"#800000",navy:"#000080",olive:"#808000",purple:"#800080",red:"#ff0000",silver:"#c0c0c0",teal:"#008080",white:"#ffffff",yellow:"#ffff00",transparent:[null,null,null,0],_default:"#ffffff"}}(p),function(){function e(e){var i,s,n=e.ownerDocument.defaultView?e.ownerDocument.defaultView.getComputedStyle(e,null):e.currentStyle,o={};if(n&&n.length&&n[0]&&n[n[0]])for(s=n.length;s--;)i=n[s],"string"==typeof n[i]&&(o[t.camelCase(i)]=n[i]);else for(i in n)"string"==typeof n[i]&&(o[i]=n[i]);return o}function i(e,i){var s,o,a={};for(s in i)o=i[s],e[s]!==o&&(n[s]||(t.fx.step[s]||!isNaN(parseFloat(o)))&&(a[s]=o));return a}var s=["add","remove","toggle"],n={border:1,borderBottom:1,borderColor:1,borderLeft:1,borderRight:1,borderTop:1,borderWidth:1,margin:1,padding:1};t.each(["borderLeftStyle","borderRightStyle","borderBottomStyle","borderTopStyle"],function(e,i){t.fx.step[i]=function(t){("none"!==t.end&&!t.setAttr||1===t.pos&&!t.setAttr)&&(p.style(t.elem,i,t.end),t.setAttr=!0)}}),t.fn.addBack||(t.fn.addBack=function(t){return this.add(null==t?this.prevObject:this.prevObject.filter(t))}),t.effects.animateClass=function(n,o,a,r){var h=t.speed(o,a,r);return this.queue(function(){var o,a=t(this),r=a.attr("class")||"",l=h.children?a.find("*").addBack():a;l=l.map(function(){var i=t(this);return{el:i,start:e(this)}}),o=function(){t.each(s,function(t,e){n[e]&&a[e+"Class"](n[e])})},o(),l=l.map(function(){return this.end=e(this.el[0]),this.diff=i(this.start,this.end),this}),a.attr("class",r),l=l.map(function(){var e=this,i=t.Deferred(),s=t.extend({},h,{queue:!1,complete:function(){i.resolve(e)}});return this.el.animate(this.diff,s),i.promise()}),t.when.apply(t,l.get()).done(function(){o(),t.each(arguments,function(){var e=this.el;t.each(this.diff,function(t){e.css(t,"")})}),h.complete.call(a[0])})})},t.fn.extend({addClass:function(e){return function(i,s,n,o){return s?t.effects.animateClass.call(this,{add:i},s,n,o):e.apply(this,arguments)}}(t.fn.addClass),removeClass:function(e){return function(i,s,n,o){return arguments.length>1?t.effects.animateClass.call(this,{remove:i},s,n,o):e.apply(this,arguments)}}(t.fn.removeClass),toggleClass:function(e){return function(i,s,n,o,a){return"boolean"==typeof s||void 0===s?n?t.effects.animateClass.call(this,s?{add:i}:{remove:i},n,o,a):e.apply(this,arguments):t.effects.animateClass.call(this,{toggle:i},s,n,o)}}(t.fn.toggleClass),switchClass:function(e,i,s,n,o){return t.effects.animateClass.call(this,{add:i,remove:e},s,n,o)}})}(),function(){function e(e,i,s,n){return t.isPlainObject(e)&&(i=e,e=e.effect),e={effect:e},null==i&&(i={}),t.isFunction(i)&&(n=i,s=null,i={}),("number"==typeof i||t.fx.speeds[i])&&(n=s,s=i,i={}),t.isFunction(s)&&(n=s,s=null),i&&t.extend(e,i),s=s||i.duration,e.duration=t.fx.off?0:"number"==typeof s?s:s in t.fx.speeds?t.fx.speeds[s]:t.fx.speeds._default,e.complete=n||i.complete,e}function i(e){return!e||"number"==typeof e||t.fx.speeds[e]?!0:"string"!=typeof e||t.effects.effect[e]?t.isFunction(e)?!0:"object"!=typeof e||e.effect?!1:!0:!0}function s(t,e){var i=e.outerWidth(),s=e.outerHeight(),n=/^rect\((-?\d*\.?\d*px|-?\d+%|auto),?\s*(-?\d*\.?\d*px|-?\d+%|auto),?\s*(-?\d*\.?\d*px|-?\d+%|auto),?\s*(-?\d*\.?\d*px|-?\d+%|auto)\)$/,o=n.exec(t)||["",0,i,s,0];return{top:parseFloat(o[1])||0,right:"auto"===o[2]?i:parseFloat(o[2]),bottom:"auto"===o[3]?s:parseFloat(o[3]),left:parseFloat(o[4])||0}}t.expr&&t.expr.filters&&t.expr.filters.animated&&(t.expr.filters.animated=function(e){return function(i){return!!t(i).data(d)||e(i)}}(t.expr.filters.animated)),t.uiBackCompat!==!1&&t.extend(t.effects,{save:function(t,e){for(var i=0,s=e.length;s>i;i++)null!==e[i]&&t.data(c+e[i],t[0].style[e[i]])},restore:function(t,e){for(var i,s=0,n=e.length;n>s;s++)null!==e[s]&&(i=t.data(c+e[s]),t.css(e[s],i))},setMode:function(t,e){return"toggle"===e&&(e=t.is(":hidden")?"show":"hide"),e},createWrapper:function(e){if(e.parent().is(".ui-effects-wrapper"))return e.parent();var i={width:e.outerWidth(!0),height:e.outerHeight(!0),"float":e.css("float")},s=t("<div></div>").addClass("ui-effects-wrapper").css({fontSize:"100%",background:"transparent",border:"none",margin:0,padding:0}),n={width:e.width(),height:e.height()},o=document.activeElement;try{o.id}catch(a){o=document.body}return e.wrap(s),(e[0]===o||t.contains(e[0],o))&&t(o).trigger("focus"),s=e.parent(),"static"===e.css("position")?(s.css({position:"relative"}),e.css({position:"relative"})):(t.extend(i,{position:e.css("position"),zIndex:e.css("z-index")}),t.each(["top","left","bottom","right"],function(t,s){i[s]=e.css(s),isNaN(parseInt(i[s],10))&&(i[s]="auto")}),e.css({position:"relative",top:0,left:0,right:"auto",bottom:"auto"})),e.css(n),s.css(i).show()},removeWrapper:function(e){var i=document.activeElement;return e.parent().is(".ui-effects-wrapper")&&(e.parent().replaceWith(e),(e[0]===i||t.contains(e[0],i))&&t(i).trigger("focus")),e}}),t.extend(t.effects,{version:"1.12.1",define:function(e,i,s){return s||(s=i,i="effect"),t.effects.effect[e]=s,t.effects.effect[e].mode=i,s},scaledDimensions:function(t,e,i){if(0===e)return{height:0,width:0,outerHeight:0,outerWidth:0};var s="horizontal"!==i?(e||100)/100:1,n="vertical"!==i?(e||100)/100:1;return{height:t.height()*n,width:t.width()*s,outerHeight:t.outerHeight()*n,outerWidth:t.outerWidth()*s}},clipToBox:function(t){return{width:t.clip.right-t.clip.left,height:t.clip.bottom-t.clip.top,left:t.clip.left,top:t.clip.top}},unshift:function(t,e,i){var s=t.queue();e>1&&s.splice.apply(s,[1,0].concat(s.splice(e,i))),t.dequeue()},saveStyle:function(t){t.data(u,t[0].style.cssText)},restoreStyle:function(t){t[0].style.cssText=t.data(u)||"",t.removeData(u)},mode:function(t,e){var i=t.is(":hidden");return"toggle"===e&&(e=i?"show":"hide"),(i?"hide"===e:"show"===e)&&(e="none"),e},getBaseline:function(t,e){var i,s;switch(t[0]){case"top":i=0;break;case"middle":i=.5;break;case"bottom":i=1;break;default:i=t[0]/e.height}switch(t[1]){case"left":s=0;break;case"center":s=.5;break;case"right":s=1;break;default:s=t[1]/e.width}return{x:s,y:i}},createPlaceholder:function(e){var i,s=e.css("position"),n=e.position();return e.css({marginTop:e.css("marginTop"),marginBottom:e.css("marginBottom"),marginLeft:e.css("marginLeft"),marginRight:e.css("marginRight")}).outerWidth(e.outerWidth()).outerHeight(e.outerHeight()),/^(static|relative)/.test(s)&&(s="absolute",i=t("<"+e[0].nodeName+">").insertAfter(e).css({display:/^(inline|ruby)/.test(e.css("display"))?"inline-block":"block",visibility:"hidden",marginTop:e.css("marginTop"),marginBottom:e.css("marginBottom"),marginLeft:e.css("marginLeft"),marginRight:e.css("marginRight"),"float":e.css("float")}).outerWidth(e.outerWidth()).outerHeight(e.outerHeight()).addClass("ui-effects-placeholder"),e.data(c+"placeholder",i)),e.css({position:s,left:n.left,top:n.top}),i},removePlaceholder:function(t){var e=c+"placeholder",i=t.data(e);i&&(i.remove(),t.removeData(e))},cleanUp:function(e){t.effects.restoreStyle(e),t.effects.removePlaceholder(e)},setTransition:function(e,i,s,n){return n=n||{},t.each(i,function(t,i){var o=e.cssUnit(i);o[0]>0&&(n[i]=o[0]*s+o[1])}),n}}),t.fn.extend({effect:function(){function i(e){function i(){r.removeData(d),t.effects.cleanUp(r),"hide"===s.mode&&r.hide(),a()}function a(){t.isFunction(h)&&h.call(r[0]),t.isFunction(e)&&e()}var r=t(this);s.mode=c.shift(),t.uiBackCompat===!1||o?"none"===s.mode?(r[l](),a()):n.call(r[0],s,i):(r.is(":hidden")?"hide"===l:"show"===l)?(r[l](),a()):n.call(r[0],s,a)}var s=e.apply(this,arguments),n=t.effects.effect[s.effect],o=n.mode,a=s.queue,r=a||"fx",h=s.complete,l=s.mode,c=[],u=function(e){var i=t(this),s=t.effects.mode(i,l)||o;i.data(d,!0),c.push(s),o&&("show"===s||s===o&&"hide"===s)&&i.show(),o&&"none"===s||t.effects.saveStyle(i),t.isFunction(e)&&e()};return t.fx.off||!n?l?this[l](s.duration,h):this.each(function(){h&&h.call(this)}):a===!1?this.each(u).each(i):this.queue(r,u).queue(r,i)},show:function(t){return function(s){if(i(s))return t.apply(this,arguments);var n=e.apply(this,arguments);return n.mode="show",this.effect.call(this,n)
15
vendor: 32,074 bytes, line 15
15}}(t.fn.show),hide:function(t){return function(s){if(i(s))return t.apply(this,arguments);var n=e.apply(this,arguments);return n.mode="hide",this.effect.call(this,n)}}(t.fn.hide),toggle:function(t){return function(s){if(i(s)||"boolean"==typeof s)return t.apply(this,arguments);var n=e.apply(this,arguments);return n.mode="toggle",this.effect.call(this,n)}}(t.fn.toggle),cssUnit:function(e){var i=this.css(e),s=[];return t.each(["em","px","%","pt"],function(t,e){i.indexOf(e)>0&&(s=[parseFloat(i),e])}),s},cssClip:function(t){return t?this.css("clip","rect("+t.top+"px "+t.right+"px "+t.bottom+"px "+t.left+"px)"):s(this.css("clip"),this)},transfer:function(e,i){var s=t(this),n=t(e.to),o="fixed"===n.css("position"),a=t("body"),r=o?a.scrollTop():0,h=o?a.scrollLeft():0,l=n.offset(),c={top:l.top-r,left:l.left-h,height:n.innerHeight(),width:n.innerWidth()},u=s.offset(),d=t("<div class='ui-effects-transfer'></div>").appendTo("body").addClass(e.className).css({top:u.top-r,left:u.left-h,height:s.innerHeight(),width:s.innerWidth(),position:o?"fixed":"absolute"}).animate(c,e.duration,e.easing,function(){d.remove(),t.isFunction(i)&&i()})}}),t.fx.step.clip=function(e){e.clipInit||(e.start=t(e.elem).cssClip(),"string"==typeof e.end&&(e.end=s(e.end,e.elem)),e.clipInit=!0),t(e.elem).cssClip({top:e.pos*(e.end.top-e.start.top)+e.start.top,right:e.pos*(e.end.right-e.start.right)+e.start.right,bottom:e.pos*(e.end.bottom-e.start.bottom)+e.start.bottom,left:e.pos*(e.end.left-e.start.left)+e.start.left})}}(),function(){var e={};t.each(["Quad","Cubic","Quart","Quint","Expo"],function(t,i){e[i]=function(e){return Math.pow(e,t+2)}}),t.extend(e,{Sine:function(t){return 1-Math.cos(t*Math.PI/2)},Circ:function(t){return 1-Math.sqrt(1-t*t)},Elastic:function(t){return 0===t||1===t?t:-Math.pow(2,8*(t-1))*Math.sin((80*(t-1)-7.5)*Math.PI/15)},Back:function(t){return t*t*(3*t-2)},Bounce:function(t){for(var e,i=4;((e=Math.pow(2,--i))-1)/11>t;);return 1/Math.pow(4,3-i)-7.5625*Math.pow((3*e-2)/22-t,2)}}),t.each(e,function(e,i){t.easing["easeIn"+e]=i,t.easing["easeOut"+e]=function(t){return 1-i(1-t)},t.easing["easeInOut"+e]=function(t){return.5>t?i(2*t)/2:1-i(-2*t+2)/2}})}();var f=t.effects;t.effects.define("blind","hide",function(e,i){var s={up:["bottom","top"],vertical:["bottom","top"],down:["top","bottom"],left:["right","left"],horizontal:["right","left"],right:["left","right"]},n=t(this),o=e.direction||"up",a=n.cssClip(),r={clip:t.extend({},a)},h=t.effects.createPlaceholder(n);r.clip[s[o][0]]=r.clip[s[o][1]],"show"===e.mode&&(n.cssClip(r.clip),h&&h.css(t.effects.clipToBox(r)),r.clip=a),h&&h.animate(t.effects.clipToBox(r),e.duration,e.easing),n.animate(r,{queue:!1,duration:e.duration,easing:e.easing,complete:i})}),t.effects.define("bounce",function(e,i){var s,n,o,a=t(this),r=e.mode,h="hide"===r,l="show"===r,c=e.direction||"up",u=e.distance,d=e.times||5,p=2*d+(l||h?1:0),f=e.duration/p,g=e.easing,m="up"===c||"down"===c?"top":"left",_="up"===c||"left"===c,v=0,b=a.queue().length;for(t.effects.createPlaceholder(a),o=a.css(m),u||(u=a["top"===m?"outerHeight":"outerWidth"]()/3),l&&(n={opacity:1},n[m]=o,a.css("opacity",0).css(m,_?2*-u:2*u).animate(n,f,g)),h&&(u/=Math.pow(2,d-1)),n={},n[m]=o;d>v;v++)s={},s[m]=(_?"-=":"+=")+u,a.animate(s,f,g).animate(n,f,g),u=h?2*u:u/2;h&&(s={opacity:0},s[m]=(_?"-=":"+=")+u,a.animate(s,f,g)),a.queue(i),t.effects.unshift(a,b,p+1)}),t.effects.define("clip","hide",function(e,i){var s,n={},o=t(this),a=e.direction||"vertical",r="both"===a,h=r||"horizontal"===a,l=r||"vertical"===a;s=o.cssClip(),n.clip={top:l?(s.bottom-s.top)/2:s.top,right:h?(s.right-s.left)/2:s.right,bottom:l?(s.bottom-s.top)/2:s.bottom,left:h?(s.right-s.left)/2:s.left},t.effects.createPlaceholder(o),"show"===e.mode&&(o.cssClip(n.clip),n.clip=s),o.animate(n,{queue:!1,duration:e.duration,easing:e.easing,complete:i})}),t.effects.define("drop","hide",function(e,i){var s,n=t(this),o=e.mode,a="show"===o,r=e.direction||"left",h="up"===r||"down"===r?"top":"left",l="up"===r||"left"===r?"-=":"+=",c="+="===l?"-=":"+=",u={opacity:0};t.effects.createPlaceholder(n),s=e.distance||n["top"===h?"outerHeight":"outerWidth"](!0)/2,u[h]=l+s,a&&(n.css(u),u[h]=c+s,u.opacity=1),n.animate(u,{queue:!1,duration:e.duration,easing:e.easing,complete:i})}),t.effects.define("explode","hide",function(e,i){function s(){b.push(this),b.length===u*d&&n()}function n(){p.css({visibility:"visible"}),t(b).remove(),i()}var o,a,r,h,l,c,u=e.pieces?Math.round(Math.sqrt(e.pieces)):3,d=u,p=t(this),f=e.mode,g="show"===f,m=p.show().css("visibility","hidden").offset(),_=Math.ceil(p.outerWidth()/d),v=Math.ceil(p.outerHeight()/u),b=[];for(o=0;u>o;o++)for(h=m.top+o*v,c=o-(u-1)/2,a=0;d>a;a++)r=m.left+a*_,l=a-(d-1)/2,p.clone().appendTo("body").wrap("<div></div>").css({position:"absolute",visibility:"visible",left:-a*_,top:-o*v}).parent().addClass("ui-effects-explode").css({position:"absolute",overflow:"hidden",width:_,height:v,left:r+(g?l*_:0),top:h+(g?c*v:0),opacity:g?0:1}).animate({left:r+(g?0:l*_),top:h+(g?0:c*v),opacity:g?1:0},e.duration||500,e.easing,s)}),t.effects.define("fade","toggle",function(e,i){var s="show"===e.mode;t(this).css("opacity",s?0:1).animate({opacity:s?1:0},{queue:!1,duration:e.duration,easing:e.easing,complete:i})}),t.effects.define("fold","hide",function(e,i){var s=t(this),n=e.mode,o="show"===n,a="hide"===n,r=e.size||15,h=/([0-9]+)%/.exec(r),l=!!e.horizFirst,c=l?["right","bottom"]:["bottom","right"],u=e.duration/2,d=t.effects.createPlaceholder(s),p=s.cssClip(),f={clip:t.extend({},p)},g={clip:t.extend({},p)},m=[p[c[0]],p[c[1]]],_=s.queue().length;h&&(r=parseInt(h[1],10)/100*m[a?0:1]),f.clip[c[0]]=r,g.clip[c[0]]=r,g.clip[c[1]]=0,o&&(s.cssClip(g.clip),d&&d.css(t.effects.clipToBox(g)),g.clip=p),s.queue(function(i){d&&d.animate(t.effects.clipToBox(f),u,e.easing).animate(t.effects.clipToBox(g),u,e.easing),i()}).animate(f,u,e.easing).animate(g,u,e.easing).queue(i),t.effects.unshift(s,_,4)}),t.effects.define("highlight","show",function(e,i){var s=t(this),n={backgroundColor:s.css("backgroundColor")};"hide"===e.mode&&(n.opacity=0),t.effects.saveStyle(s),s.css({backgroundImage:"none",backgroundColor:e.color||"#ffff99"}).animate(n,{queue:!1,duration:e.duration,easing:e.easing,complete:i})}),t.effects.define("size",function(e,i){var s,n,o,a=t(this),r=["fontSize"],h=["borderTopWidth","borderBottomWidth","paddingTop","paddingBottom"],l=["borderLeftWidth","borderRightWidth","paddingLeft","paddingRight"],c=e.mode,u="effect"!==c,d=e.scale||"both",p=e.origin||["middle","center"],f=a.css("position"),g=a.position(),m=t.effects.scaledDimensions(a),_=e.from||m,v=e.to||t.effects.scaledDimensions(a,0);t.effects.createPlaceholder(a),"show"===c&&(o=_,_=v,v=o),n={from:{y:_.height/m.height,x:_.width/m.width},to:{y:v.height/m.height,x:v.width/m.width}},("box"===d||"both"===d)&&(n.from.y!==n.to.y&&(_=t.effects.setTransition(a,h,n.from.y,_),v=t.effects.setTransition(a,h,n.to.y,v)),n.from.x!==n.to.x&&(_=t.effects.setTransition(a,l,n.from.x,_),v=t.effects.setTransition(a,l,n.to.x,v))),("content"===d||"both"===d)&&n.from.y!==n.to.y&&(_=t.effects.setTransition(a,r,n.from.y,_),v=t.effects.setTransition(a,r,n.to.y,v)),p&&(s=t.effects.getBaseline(p,m),_.top=(m.outerHeight-_.outerHeight)*s.y+g.top,_.left=(m.outerWidth-_.outerWidth)*s.x+g.left,v.top=(m.outerHeight-v.outerHeight)*s.y+g.top,v.left=(m.outerWidth-v.outerWidth)*s.x+g.left),a.css(_),("content"===d||"both"===d)&&(h=h.concat(["marginTop","marginBottom"]).concat(r),l=l.concat(["marginLeft","marginRight"]),a.find("*[width]").each(function(){var i=t(this),s=t.effects.scaledDimensions(i),o={height:s.height*n.from.y,width:s.width*n.from.x,outerHeight:s.outerHeight*n.from.y,outerWidth:s.outerWidth*n.from.x},a={height:s.height*n.to.y,width:s.width*n.to.x,outerHeight:s.height*n.to.y,outerWidth:s.width*n.to.x};n.from.y!==n.to.y&&(o=t.effects.setTransition(i,h,n.from.y,o),a=t.effects.setTransition(i,h,n.to.y,a)),n.from.x!==n.to.x&&(o=t.effects.setTransition(i,l,n.from.x,o),a=t.effects.setTransition(i,l,n.to.x,a)),u&&t.effects.saveStyle(i),i.css(o),i.animate(a,e.duration,e.easing,function(){u&&t.effects.restoreStyle(i)})})),a.animate(v,{queue:!1,duration:e.duration,easing:e.easing,complete:function(){var e=a.offset();0===v.opacity&&a.css("opacity",_.opacity),u||(a.css("position","static"===f?"relative":f).offset(e),t.effects.saveStyle(a)),i()}})}),t.effects.define("scale",function(e,i){var s=t(this),n=e.mode,o=parseInt(e.percent,10)||(0===parseInt(e.percent,10)?0:"effect"!==n?0:100),a=t.extend(!0,{from:t.effects.scaledDimensions(s),to:t.effects.scaledDimensions(s,o,e.direction||"both"),origin:e.origin||["middle","center"]},e);e.fade&&(a.from.opacity=1,a.to.opacity=0),t.effects.effect.size.call(this,a,i)}),t.effects.define("puff","hide",function(e,i){var s=t.extend(!0,{},e,{fade:!0,percent:parseInt(e.percent,10)||150});t.effects.effect.scale.call(this,s,i)}),t.effects.define("pulsate","show",function(e,i){var s=t(this),n=e.mode,o="show"===n,a="hide"===n,r=o||a,h=2*(e.times||5)+(r?1:0),l=e.duration/h,c=0,u=1,d=s.queue().length;for((o||!s.is(":visible"))&&(s.css("opacity",0).show(),c=1);h>u;u++)s.animate({opacity:c},l,e.easing),c=1-c;s.animate({opacity:c},l,e.easing),s.queue(i),t.effects.unshift(s,d,h+1)}),t.effects.define("shake",function(e,i){var s=1,n=t(this),o=e.direction||"left",a=e.distance||20,r=e.times||3,h=2*r+1,l=Math.round(e.duration/h),c="up"===o||"down"===o?"top":"left",u="up"===o||"left"===o,d={},p={},f={},g=n.queue().length;for(t.effects.createPlaceholder(n),d[c]=(u?"-=":"+=")+a,p[c]=(u?"+=":"-=")+2*a,f[c]=(u?"-=":"+=")+2*a,n.animate(d,l,e.easing);r>s;s++)n.animate(p,l,e.easing).animate(f,l,e.easing);n.animate(p,l,e.easing).animate(d,l/2,e.easing).queue(i),t.effects.unshift(n,g,h+1)}),t.effects.define("slide","show",function(e,i){var s,n,o=t(this),a={up:["bottom","top"],down:["top","bottom"],left:["right","left"],right:["left","right"]},r=e.mode,h=e.direction||"left",l="up"===h||"down"===h?"top":"left",c="up"===h||"left"===h,u=e.distance||o["top"===l?"outerHeight":"outerWidth"](!0),d={};t.effects.createPlaceholder(o),s=o.cssClip(),n=o.position()[l],d[l]=(c?-1:1)*u+n,d.clip=o.cssClip(),d.clip[a[h][1]]=d.clip[a[h][0]],"show"===r&&(o.cssClip(d.clip),o.css(l,d[l]),d.clip=s,d[l]=n),o.animate(d,{queue:!1,duration:e.duration,easing:e.easing,complete:i})});var f;t.uiBackCompat!==!1&&(f=t.effects.define("transfer",function(e,i){t(this).transfer(e,i)})),t.ui.focusable=function(i,s){var n,o,a,r,h,l=i.nodeName.toLowerCase();return"area"===l?(n=i.parentNode,o=n.name,i.href&&o&&"map"===n.nodeName.toLowerCase()?(a=t("img[usemap='#"+o+"']"),a.length>0&&a.is(":visible")):!1):(/^(input|select|textarea|button|object)$/.test(l)?(r=!i.disabled,r&&(h=t(i).closest("fieldset")[0],h&&(r=!h.disabled))):r="a"===l?i.href||s:s,r&&t(i).is(":visible")&&e(t(i)))},t.extend(t.expr[":"],{focusable:function(e){return t.ui.focusable(e,null!=t.attr(e,"tabindex"))}}),t.ui.focusable,t.fn.form=function(){return"string"==typeof this[0].form?this.closest("form"):t(this[0].form)},t.ui.formResetMixin={_formResetHandler:function(){var e=t(this);setTimeout(function(){var i=e.data("ui-form-reset-instances");t.each(i,function(){this.refresh()})})},_bindFormResetHandler:function(){if(this.form=this.element.form(),this.form.length){var t=this.form.data("ui-form-reset-instances")||[];t.length||this.form.on("reset.ui-form-reset",this._formResetHandler),t.push(this),this.form.data("ui-form-reset-instances",t)}},_unbindFormResetHandler:function(){if(this.form.length){var e=this.form.data("ui-form-reset-instances");e.splice(t.inArray(this,e),1),e.length?this.form.data("ui-form-reset-instances",e):this.form.removeData("ui-form-reset-instances").off("reset.ui-form-reset")}}},"1.7"===t.fn.jquery.substring(0,3)&&(t.each(["Width","Height"],function(e,i){function s(e,i,s,o){return t.each(n,function(){i-=parseFloat(t.css(e,"padding"+this))||0,s&&(i-=parseFloat(t.css(e,"border"+this+"Width"))||0),o&&(i-=parseFloat(t.css(e,"margin"+this))||0)}),i}var n="Width"===i?["Left","Right"]:["Top","Bottom"],o=i.toLowerCase(),a={innerWidth:t.fn.innerWidth,innerHeight:t.fn.innerHeight,outerWidth:t.fn.outerWidth,outerHeight:t.fn.outerHeight};t.fn["inner"+i]=function(e){return void 0===e?a["inner"+i].call(this):this.each(function(){t(this).css(o,s(this,e)+"px")})},t.fn["outer"+i]=function(e,n){return"number"!=typeof e?a["outer"+i].call(this,e):this.each(function(){t(this).css(o,s(this,e,!0,n)+"px")})}}),t.fn.addBack=function(t){return this.add(null==t?this.prevObject:this.prevObject.filter(t))}),t.ui.keyCode={BACKSPACE:8,COMMA:188,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,LEFT:37,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SPACE:32,TAB:9,UP:38},t.ui.escapeSelector=function(){var t=/([!"#$%&'()*+,./:;<=>?@[\]^`{|}~])/g;return function(e){return e.replace(t,"\\$1")}}(),t.fn.labels=function(){var e,i,s,n,o;return this[0].labels&&this[0].labels.length?this.pushStack(this[0].labels):(n=this.eq(0).parents("label"),s=this.attr("id"),s&&(e=this.eq(0).parents().last(),o=e.add(e.length?e.siblings():this.siblings()),i="label[for='"+t.ui.escapeSelector(s)+"']",n=n.add(o.find(i).addBack(i))),this.pushStack(n))},t.fn.scrollParent=function(e){var i=this.css("position"),s="absolute"===i,n=e?/(auto|scroll|hidden)/:/(auto|scroll)/,o=this.parents().filter(function(){var e=t(this);return s&&"static"===e.css("position")?!1:n.test(e.css("overflow")+e.css("overflow-y")+e.css("overflow-x"))}).eq(0);return"fixed"!==i&&o.length?o:t(this[0].ownerDocument||document)},t.extend(t.expr[":"],{tabbable:function(e){var i=t.attr(e,"tabindex"),s=null!=i;return(!s||i>=0)&&t.ui.focusable(e,s)}}),t.fn.extend({uniqueId:function(){var t=0;return function(){return this.each(function(){this.id||(this.id="ui-id-"+ ++t)})}}(),removeUniqueId:function(){return this.each(function(){/^ui-id-\d+$/.test(this.id)&&t(this).removeAttr("id")})}}),t.widget("ui.accordion",{version:"1.12.1",options:{active:0,animate:{},classes:{"ui-accordion-header":"ui-corner-top","ui-accordion-header-collapsed":"ui-corner-all","ui-accordion-content":"ui-corner-bottom"},collapsible:!1,event:"click",header:"> li > :first-child, > :not(li):even",heightStyle:"auto",icons:{activeHeader:"ui-icon-triangle-1-s",header:"ui-icon-triangle-1-e"},activate:null,beforeActivate:null},hideProps:{borderTopWidth:"hide",borderBottomWidth:"hide",paddingTop:"hide",paddingBottom:"hide",height:"hide"},showProps:{borderTopWidth:"show",borderBottomWidth:"show",paddingTop:"show",paddingBottom:"show",height:"show"},_create:function(){var e=this.options;this.prevShow=this.prevHide=t(),this._addClass("ui-accordion","ui-widget ui-helper-reset"),this.element.attr("role","tablist"),e.collapsible||e.active!==!1&&null!=e.active||(e.active=0),this._processPanels(),0>e.active&&(e.active+=this.headers.length),this._refresh()},_getCreateEventData:function(){return{header:this.active,panel:this.active.length?this.active.next():t()}},_createIcons:function(){var e,i,s=this.options.icons;s&&(e=t("<span>"),this._addClass(e,"ui-accordion-header-icon","ui-icon "+s.header),e.prependTo(this.headers),i=this.active.children(".ui-accordion-header-icon"),this._removeClass(i,s.header)._addClass(i,null,s.activeHeader)._addClass(this.headers,"ui-accordion-icons"))},_destroyIcons:function(){this._removeClass(this.headers,"ui-accordion-icons"),this.headers.children(".ui-accordion-header-icon").remove()},_destroy:function(){var t;this.element.removeAttr("role"),this.headers.removeAttr("role aria-expanded aria-selected aria-controls tabIndex").removeUniqueId(),this._destroyIcons(),t=this.headers.next().css("display","").removeAttr("role aria-hidden aria-labelledby").removeUniqueId(),"content"!==this.options.heightStyle&&t.css("height","")},_setOption:function(t,e){return"active"===t?(this._activate(e),void 0):("event"===t&&(this.options.event&&this._off(this.headers,this.options.event),this._setupEvents(e)),this._super(t,e),"collapsible"!==t||e||this.options.active!==!1||this._activate(0),"icons"===t&&(this._destroyIcons(),e&&this._createIcons()),void 0)},_setOptionDisabled:function(t){this._super(t),this.element.attr("aria-disabled",t),this._toggleClass(null,"ui-state-disabled",!!t),this._toggleClass(this.headers.add(this.headers.next()),null,"ui-state-disabled",!!t)},_keydown:function(e){if(!e.altKey&&!e.ctrlKey){var i=t.ui.keyCode,s=this.headers.length,n=this.headers.index(e.target),o=!1;switch(e.keyCode){case i.RIGHT:case i.DOWN:o=this.headers[(n+1)%s];break;case i.LEFT:case i.UP:o=this.headers[(n-1+s)%s];break;case i.SPACE:case i.ENTER:this._eventHandler(e);break;case i.HOME:o=this.headers[0];break;case i.END:o=this.headers[s-1]}o&&(t(e.target).attr("tabIndex",-1),t(o).attr("tabIndex",0),t(o).trigger("focus"),e.preventDefault())}},_panelKeyDown:function(e){e.keyCode===t.ui.keyCode.UP&&e.ctrlKey&&t(e.currentTarget).prev().trigger("focus")},refresh:function(){var e=this.options;this._processPanels(),e.active===!1&&e.collapsible===!0||!this.headers.length?(e.active=!1,this.active=t()):e.active===!1?this._activate(0):this.active.length&&!t.contains(this.element[0],this.active[0])?this.headers.length===this.headers.find(".ui-state-disabled").length?(e.active=!1,this.active=t()):this._activate(Math.max(0,e.active-1)):e.active=this.headers.index(this.active),this._destroyIcons(),this._refresh()},_processPanels:function(){var t=this.headers,e=this.panels;this.headers=this.element.find(this.options.header),this._addClass(this.headers,"ui-accordion-header ui-accordion-header-collapsed","ui-state-default"),this.panels=this.headers.next().filter(":not(.ui-accordion-content-active)").hide(),this._addClass(this.panels,"ui-accordion-content","ui-helper-reset ui-widget-content"),e&&(this._off(t.not(this.headers)),this._off(e.not(this.panels)))},_refresh:function(){var e,i=this.options,s=i.heightStyle,n=this.element.parent();this.active=this._findActive(i.active),this._addClass(this.active,"ui-accordion-header-active","ui-state-active")._removeClass(this.active,"ui-accordion-header-collapsed"),this._addClass(this.active.next(),"ui-accordion-content-active"),this.active.next().show(),this.headers.attr("role","tab").each(function(){var e=t(this),i=e.uniqueId().attr("id"),s=e.next(),n=s.uniqueId().attr("id");e.attr("aria-controls",n),s.attr("aria-labelledby",i)}).next().attr("role","tabpanel"),this.headers.not(this.active).attr({"aria-selected":"false","aria-expanded":"false",tabIndex:-1}).next().attr({"aria-hidden":"true"}).hide(),this.active.length?this.active.attr({"aria-selected":"true","aria-expanded":"true",tabIndex:0}).next().attr({"aria-hidden":"false"}):this.headers.eq(0).attr("tabIndex",0),this._createIcons(),this._setupEvents(i.event),"fill"===s?(e=n.height(),this.element.siblings(":visible").each(function(){var i=t(this),s=i.css("position");"absolute"!==s&&"fixed"!==s&&(e-=i.outerHeight(!0))}),this.headers.each(function(){e-=t(this).outerHeight(!0)}),this.headers.next().each(function(){t(this).height(Math.max(0,e-t(this).innerHeight()+t(this).height()))}).css("overflow","auto")):"auto"===s&&(e=0,this.headers.next().each(function(){var i=t(this).is(":visible");i||t(this).show(),e=Math.max(e,t(this).css("height","").height()),i||t(this).hide()}).height(e))},_activate:function(e){var i=this._findActive(e)[0];i!==this.active[0]&&(i=i||this.active[0],this._eventHandler({target:i,currentTarget:i,preventDefault:t.noop}))},_findActive:function(e){return"number"==typeof e?this.headers.eq(e):t()},_setupEvents:function(e){var i={keydown:"_keydown"};e&&t.each(e.split(" "),function(t,e){i[e]="_eventHandler"}),this._off(this.headers.add(this.headers.next())),this._on(this.headers,i),this._on(this.headers.next(),{keydown:"_panelKeyDown"}),this._hoverable(this.headers),this._focusable(this.headers)},_eventHandler:function(e){var i,s,n=this.options,o=this.active,a=t(e.currentTarget),r=a[0]===o[0],h=r&&n.collapsible,l=h?t():a.next(),c=o.next(),u={oldHeader:o,oldPanel:c,newHeader:h?t():a,newPanel:l};e.preventDefault(),r&&!n.collapsible||this._trigger("beforeActivate",e,u)===!1||(n.active=h?!1:this.headers.index(a),this.active=r?t():a,this._toggle(u),this._removeClass(o,"ui-accordion-header-active","ui-state-active"),n.icons&&(i=o.children(".ui-accordion-header-icon"),this._removeClass(i,null,n.icons.activeHeader)._addClass(i,null,n.icons.header)),r||(this._removeClass(a,"ui-accordion-header-collapsed")._addClass(a,"ui-accordion-header-active","ui-state-active"),n.icons&&(s=a.children(".ui-accordion-header-icon"),this._removeClass(s,null,n.icons.header)._addClass(s,null,n.icons.activeHeader)),this._addClass(a.next(),"ui-accordion-content-active")))},_toggle:function(e){var i=e.newPanel,s=this.prevShow.length?this.prevShow:e.oldPanel;this.prevShow.add(this.prevHide).stop(!0,!0),this.prevShow=i,this.prevHide=s,this.options.animate?this._animate(i,s,e):(s.hide(),i.show(),this._toggleComplete(e)),s.attr({"aria-hidden":"true"}),s.prev().attr({"aria-selected":"false","aria-expanded":"false"}),i.length&&s.length?s.prev().attr({tabIndex:-1,"aria-expanded":"false"}):i.length&&this.headers.filter(function(){return 0===parseInt(t(this).attr("tabIndex"),10)}).attr("tabIndex",-1),i.attr("aria-hidden","false").prev().attr({"aria-selected":"true","aria-expanded":"true",tabIndex:0})},_animate:function(t,e,i){var s,n,o,a=this,r=0,h=t.css("box-sizing"),l=t.length&&(!e.length||t.index()<e.index()),c=this.options.animate||{},u=l&&c.down||c,d=function(){a._toggleComplete(i)};return"number"==typeof u&&(o=u),"string"==typeof u&&(n=u),n=n||u.easing||c.easing,o=o||u.duration||c.duration,e.length?t.length?(s=t.show().outerHeight(),e.animate(this.hideProps,{duration:o,easing:n,step:function(t,e){e.now=Math.round(t)}}),t.hide().animate(this.showProps,{duration:o,easing:n,complete:d,step:function(t,i){i.now=Math.round(t),"height"!==i.prop?"content-box"===h&&(r+=i.now):"content"!==a.options.heightStyle&&(i.now=Math.round(s-e.outerHeight()-r),r=0)}}),void 0):e.animate(this.hideProps,o,n,d):t.animate(this.showProps,o,n,d)},_toggleComplete:function(t){var e=t.oldPanel,i=e.prev();this._removeClass(e,"ui-accordion-content-active"),this._removeClass(i,"ui-accordion-header-active")._addClass(i,"ui-accordion-header-collapsed"),e.length&&(e.parent()[0].className=e.parent()[0].className),this._trigger("activate",null,t)}}),t.ui.safeActiveElement=function(t){var e;try{e=t.activeElement}catch(i){e=t.body}return e||(e=t.body),e.nodeName||(e=t.body),e},t.widget("ui.menu",{version:"1.12.1",defaultElement:"<ul>",delay:300,options:{icons:{submenu:"ui-icon-caret-1-e"},items:"> *",menus:"ul",position:{my:"left top",at:"right top"},role:"menu",blur:null,focus:null,select:null},_create:function(){this.activeMenu=this.element,this.mouseHandled=!1,this.element.uniqueId().attr({role:this.options.role,tabIndex:0}),this._addClass("ui-menu","ui-widget ui-widget-content"),this._on({"mousedown .ui-menu-item":function(t){t.preventDefault()},"click .ui-menu-item":function(e){var i=t(e.target),s=t(t.ui.safeActiveElement(this.document[0]));!this.mouseHandled&&i.not(".ui-state-disabled").length&&(this.select(e),e.isPropagationStopped()||(this.mouseHandled=!0),i.has(".ui-menu").length?this.expand(e):!this.element.is(":focus")&&s.closest(".ui-menu").length&&(this.element.trigger("focus",[!0]),this.active&&1===this.active.parents(".ui-menu").length&&clearTimeout(this.timer)))},"mouseenter .ui-menu-item":function(e){if(!this.previousFilter){var i=t(e.target).closest(".ui-menu-item"),s=t(e.currentTarget);i[0]===s[0]&&(this._removeClass(s.siblings().children(".ui-state-active"),null,"ui-state-active"),this.focus(e,s))}},mouseleave:"collapseAll","mouseleave .ui-menu":"collapseAll",focus:function(t,e){var i=this.active||this.element.find(this.options.items).eq(0);e||this.focus(t,i)},blur:function(e){this._delay(function(){var i=!t.contains(this.element[0],t.ui.safeActiveElement(this.document[0]));i&&this.collapseAll(e)})},keydown:"_keydown"}),this.refresh(),this._on(this.document,{click:function(t){this._closeOnDocumentClick(t)&&this.collapseAll(t),this.mouseHandled=!1}})},_destroy:function(){var e=this.element.find(".ui-menu-item").removeAttr("role aria-disabled"),i=e.children(".ui-menu-item-wrapper").removeUniqueId().removeAttr("tabIndex role aria-haspopup");this.element.removeAttr("aria-activedescendant").find(".ui-menu").addBack().removeAttr("role aria-labelledby aria-expanded aria-hidden aria-disabled tabIndex").removeUniqueId().show(),i.children().each(function(){var e=t(this);e.data("ui-menu-submenu-caret")&&e.remove()})},_keydown:function(e){var i,s,n,o,a=!0;switch(e.keyCode){case t.ui.keyCode.PAGE_UP:this.previousPage(e);break;case t.ui.keyCode.PAGE_DOWN:this.nextPage(e);break;case t.ui.keyCode.HOME:this._move("first","first",e);break;case t.ui.keyCode.END:this._move("last","last",e);break;case t.ui.keyCode.UP:this.previous(e);break;case t.ui.keyCode.DOWN:this.next(e);break;case t.ui.keyCode.LEFT:this.collapse(e);break;case t.ui.keyCode.RIGHT:this.active&&!this.active.is(".ui-state-disabled")&&this.expand(e);break;case t.ui.keyCode.ENTER:case t.ui.keyCode.SPACE:this._activate(e);break;case t.ui.keyCode.ESCAPE:this.collapse(e);break;default:a=!1,s=this.previousFilter||"",o=!1,n=e.keyCode>=96&&105>=e.keyCode?""+(e.keyCode-96):String.fromCharCode(e.keyCode),clearTimeout(this.filterTimer),n===s?o=!0:n=s+n,i=this._filterMenuItems(n),i=o&&-1!==i.index(this.active.next())?this.active.nextAll(".ui-menu-item"):i,i.length||(n=String.fromCharCode(e.keyCode),i=this._filterMenuItems(n)),i.length?(this.focus(e,i),this.previousFilter=n,this.filterTimer=this._delay(function(){delete this.previousFilter},1e3)):delete this.previousFilter}a&&e.preventDefault()},_activate:function(t){this.active&&!this.active.is(".ui-state-disabled")&&(this.active.children("[aria-haspopup='true']").length?this.expand(t):this.select(t))},refresh:function(){var e,i,s,n,o,a=this,r=this.options.icons.submenu,h=this.element.find(this.options.menus);this._toggleClass("ui-menu-icons",null,!!this.element.find(".ui-icon").length),s=h.filter(":not(.ui-menu)").hide().attr({role:this.options.role,"aria-hidden":"true","aria-expanded":"false"}).each(function(){var e=t(this),i=e.prev(),s=t("<span>").data("ui-menu-submenu-caret",!0);a._addClass(s,"ui-menu-icon","ui-icon "+r),i.attr("aria-haspopup","true").prepend(s),e.attr("aria-labelledby",i.attr("id"))}),this._addClass(s,"ui-menu","ui-widget ui-widget-content ui-front"),e=h.add(this.element),i=e.find(this.options.items),i.not(".ui-menu-item").each(function(){var e=t(this);a._isDivider(e)&&a._addClass(e,"ui-menu-divider","ui-widget-content")}),n=i.not(".ui-menu-item, .ui-menu-divider"),o=n.children().not(".ui-menu").uniqueId().attr({tabIndex:-1,role:this._itemRole()}),this._addClass(n,"ui-menu-item")._addClass(o,"ui-menu-item-wrapper"),i.filter(".ui-state-disabled").attr("aria-disabled","true"),this.active&&!t.contains(this.element[0],this.active[0])&&this.blur()},_itemRole:function(){return{menu:"menuitem",listbox:"option"}[this.options.role]},_setOption:function(t,e){if("icons"===t){var i=this.element.find(".ui-menu-icon");this._removeClass(i,null,this.options.icons.submenu)._addClass(i,null,e.submenu)}this._super(t,e)},_setOptionDisabled:function(t){this._super(t),this.element.attr("aria-disabled",t+""),this._toggleClass(null,"ui-state-disabled",!!t)},focus:function(t,e){var i,s,n;this.blur(t,t&&"focus"===t.type),this._scrollIntoView(e),this.active=e.first(),s=this.active.children(".ui-menu-item-wrapper"),this._addClass(s,null,"ui-state-active"),this.options.role&&this.element.attr("aria-activedescendant",s.attr("id")),n=this.active.parent().closest(".ui-menu-item").children(".ui-menu-item-wrapper"),this._addClass(n,null,"ui-state-active"),t&&"keydown"===t.type?this._close():this.timer=this._delay(function(){this._close()},this.delay),i=e.children(".ui-menu"),i.length&&t&&/^mouse/.test(t.type)&&this._startOpening(i),this.activeMenu=e.parent(),this._trigger("focus",t,{item:e})},_scrollIntoView:function(e){var i,s,n,o,a,r;this._hasScroll()&&(i=parseFloat(t.css(this.activeMenu[0],"borderTopWidth"))||0,s=parseFloat(t.css(this.activeMenu[0],"paddingTop"))||0,n=e.offset().top-this.activeMenu.offset().top-i-s,o=this.activeMenu.scrollTop(),a=this.activeMenu.height(),r=e.outerHeight(),0>n?this.activeMenu.scrollTop(o+n):n+r>a&&this.activeMenu.scrollTop(o+n-a+r))},blur:function(t,e){e||clearTimeout(this.timer),this.active&&(this._removeClass(this.active.children(".ui-menu-item-wrapper"),null,"ui-state-active"),this._trigger("blur",t,{item:this.active}),this.active=null)},_startOpening:function(t){clearTimeout(this.timer),"true"===t.attr("aria-hidden")&&(this.timer=this._delay(function(){this._close(),this._open(t)},this.delay))},_open:function(e){var i=t.extend({of:this.active},this.options.position);clearTimeout(this.timer),this.element.find(".ui-menu").not(e.parents(".ui-menu")).hide().attr("aria-hidden","true"),e.show().removeAttr("aria-hidden").attr("aria-expanded","true").position(i)},collapseAll:function(e,i){clearTimeout(this.timer),this.timer=this._delay(function(){var s=i?this.element:t(e&&e.target).closest(this.element.find(".ui-menu"));s.length||(s=this.element),this._close(s),this.blur(e),this._removeClass(s.find(".ui-state-active"),null,"ui-state-active"),this.activeMenu=s},this.delay)},_close:function(t){t||(t=this.active?this.active.parent():this.element),t.find(".ui-menu").hide().attr("aria-hidden","true").attr("aria-expanded","false")},_closeOnDocumentClick:function(e){return!t(e.target).closest(".ui-menu").length},_isDivider:function(t){return!/[^\-\u2014\u2013\s]/.test(t.text())},collapse:function(t){var e=this.active&&this.active.parent().closest(".ui-menu-item",this.element);e&&e.length&&(this._close(),this.focus(t,e))},expand:function(t){var e=this.active&&this.active.children(".ui-menu ").find(this.options.items).first();e&&e.length&&(this._open(e.parent()),this._delay(function(){this.focus(t,e)}))},next:function(t){this._move("next","first",t)},previous:function(t){this._move("prev","last",t)},isFirstItem:function(){return this.active&&!this.active.prevAll(".ui-menu-item").length},isLastItem:function(){return this.active&&!this.active.nextAll(".ui-menu-item").length},_move:function(t,e,i){var s;this.active&&(s="first"===t||"last"===t?this.active["first"===t?"prevAll":"nextAll"](".ui-menu-item").eq(-1):this.active[t+"All"](".ui-menu-item").eq(0)),s&&s.length&&this.active||(s=this.activeMenu.find(this.options.items)[e]()),this.focus(i,s)},nextPage:function(e){var i,s,n;return this.active?(this.isLastItem()||(this._hasScroll()?(s=this.active.offset().top,n=this.element.height(),this.active.nextAll(".ui-menu-item").each(function(){return i=t(this),0>i.offset().top-s-n}),this.focus(e,i)):this.focus(e,this.activeMenu.find(this.options.items)[this.active?"last":"first"]())),void 0):(this.next(e),void 0)},previousPage:function(e){var i,s,n;return this.active?(this.isFirstItem()||(this._hasScroll()?(s=this.active.offset().top,n=this.element.height(),this.active.prevAll(".ui-menu-item").each(function(){return i=t(this),i.offset().top-s+n>0}),this.focus(e,i)):this.focus(e,this.activeMenu.find(this.options.items).first())),void 0):(this.next(e),void 0)},_hasScroll:function(){return this.element.outerHeight()<this.element.prop("scrollHeight")},select:function(e){this.active=this.active||t(e.target).closest(".ui-menu-item");var i={item:this.active};this.active.has(".ui-menu").length||this.collapseAll(e,!0),this._trigger("select",e,i)},_filterMenuItems:function(e){var i=e.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&"),s=RegExp("^"+i,"i");return this.activeMenu.find(this.options.items).filter(".ui-menu-item").filter(function(){return s.test(t.trim(t(this).children(".ui-menu-item-wrapper").text()))})}}),t.widget("ui.autocomplete",{version:"1.12.1",defaultElement:"<input>",options:{appendTo:null,autoFocus:!1,delay:300,minLength:1,position:{my:"left top",at:"left bottom",collision:"none"},source:null,change:null,close:null,focus:null,open:null,response:null,search:null,select:null},requestIndex:0,pending:0,_create:function(){var e,i,s,n=this.element[0].nodeName.toLowerCase(),o="textarea"===n,a="input"===n;
16
vendor: 5,506 bytes, line 16
16this.isMultiLine=o||!a&&this._isContentEditable(this.element),this.valueMethod=this.element[o||a?"val":"text"],this.isNewMenu=!0,this._addClass("ui-autocomplete-input"),this.element.attr("autocomplete","off"),this._on(this.element,{keydown:function(n){if(this.element.prop("readOnly"))return e=!0,s=!0,i=!0,void 0;e=!1,s=!1,i=!1;var o=t.ui.keyCode;switch(n.keyCode){case o.PAGE_UP:e=!0,this._move("previousPage",n);break;case o.PAGE_DOWN:e=!0,this._move("nextPage",n);break;case o.UP:e=!0,this._keyEvent("previous",n);break;case o.DOWN:e=!0,this._keyEvent("next",n);break;case o.ENTER:this.menu.active&&(e=!0,n.preventDefault(),this.menu.select(n));break;case o.TAB:this.menu.active&&this.menu.select(n);break;case o.ESCAPE:this.menu.element.is(":visible")&&(this.isMultiLine||this._value(this.term),this.close(n),n.preventDefault());break;default:i=!0,this._searchTimeout(n)}},keypress:function(s){if(e)return e=!1,(!this.isMultiLine||this.menu.element.is(":visible"))&&s.preventDefault(),void 0;if(!i){var n=t.ui.keyCode;switch(s.keyCode){case n.PAGE_UP:this._move("previousPage",s);break;case n.PAGE_DOWN:this._move("nextPage",s);break;case n.UP:this._keyEvent("previous",s);break;case n.DOWN:this._keyEvent("next",s)}}},input:function(t){return s?(s=!1,t.preventDefault(),void 0):(this._searchTimeout(t),void 0)},focus:function(){this.selectedItem=null,this.previous=this._value()},blur:function(t){return this.cancelBlur?(delete this.cancelBlur,void 0):(clearTimeout(this.searching),this.close(t),this._change(t),void 0)}}),this._initSource(),this.menu=t("<ul>").appendTo(this._appendTo()).menu({role:null}).hide().menu("instance"),this._addClass(this.menu.element,"ui-autocomplete","ui-front"),this._on(this.menu.element,{mousedown:function(e){e.preventDefault(),this.cancelBlur=!0,this._delay(function(){delete this.cancelBlur,this.element[0]!==t.ui.safeActiveElement(this.document[0])&&this.element.trigger("focus")})},menufocus:function(e,i){var s,n;return this.isNewMenu&&(this.isNewMenu=!1,e.originalEvent&&/^mouse/.test(e.originalEvent.type))?(this.menu.blur(),this.document.one("mousemove",function(){t(e.target).trigger(e.originalEvent)}),void 0):(n=i.item.data("ui-autocomplete-item"),!1!==this._trigger("focus",e,{item:n})&&e.originalEvent&&/^key/.test(e.originalEvent.type)&&this._value(n.value),s=i.item.attr("aria-label")||n.value,s&&t.trim(s).length&&(this.liveRegion.children().hide(),t("<div>").text(s).appendTo(this.liveRegion)),void 0)},menuselect:function(e,i){var s=i.item.data("ui-autocomplete-item"),n=this.previous;this.element[0]!==t.ui.safeActiveElement(this.document[0])&&(this.element.trigger("focus"),this.previous=n,this._delay(function(){this.previous=n,this.selectedItem=s})),!1!==this._trigger("select",e,{item:s})&&this._value(s.value),this.term=this._value(),this.close(e),this.selectedItem=s}}),this.liveRegion=t("<div>",{role:"status","aria-live":"assertive","aria-relevant":"additions"}).appendTo(this.document[0].body),this._addClass(this.liveRegion,null,"ui-helper-hidden-accessible"),this._on(this.window,{beforeunload:function(){this.element.removeAttr("autocomplete")}})},_destroy:function(){clearTimeout(this.searching),this.element.removeAttr("autocomplete"),this.menu.element.remove(),this.liveRegion.remove()},_setOption:function(t,e){this._super(t,e),"source"===t&&this._initSource(),"appendTo"===t&&this.menu.element.appendTo(this._appendTo()),"disabled"===t&&e&&this.xhr&&this.xhr.abort()},_isEventTargetInWidget:function(e){var i=this.menu.element[0];return e.target===this.element[0]||e.target===i||t.contains(i,e.target)},_closeOnClickOutside:function(t){this._isEventTargetInWidget(t)||this.close()},_appendTo:function(){var e=this.options.appendTo;return e&&(e=e.jquery||e.nodeType?t(e):this.document.find(e).eq(0)),e&&e[0]||(e=this.element.closest(".ui-front, dialog")),e.length||(e=this.document[0].body),e},_initSource:function(){var e,i,s=this;t.isArray(this.options.source)?(e=this.options.source,this.source=function(i,s){s(t.ui.autocomplete.filter(e,i.term))}):"string"==typeof this.options.source?(i=this.options.source,this.source=function(e,n){s.xhr&&s.xhr.abort(),s.xhr=t.ajax({url:i,data:e,dataType:"json",success:function(t){n(t)},error:function(){n([])}})}):this.source=this.options.source},_searchTimeout:function(t){clearTimeout(this.searching),this.searching=this._delay(function(){var e=this.term===this._value(),i=this.menu.element.is(":visible"),s=t.altKey||t.ctrlKey||t.metaKey||t.shiftKey;(!e||e&&!i&&!s)&&(this.selectedItem=null,this.search(null,t))},this.options.delay)},search:function(t,e){return t=null!=t?t:this._value(),this.term=this._value(),t.length<this.options.minLength?this.close(e):this._trigger("search",e)!==!1?this._search(t):void 0},_search:function(t){this.pending++,this._addClass("ui-autocomplete-loading"),this.cancelSearch=!1,this.source({term:t},this._response())},_response:function(){var e=++this.requestIndex;return t.proxy(function(t){e===this.requestIndex&&this.__response(t),this.pending--,this.pending||this._removeClass("ui-autocomplete-loading")},this)},__response:function(t){t&&(t=this._normalize(t)),this._trigger("response",null,{content:t}),!this.options.disabled&&t&&t.length&&!this.cancelSearch?(this._suggest(t),this._trigger("open")):this._close()},close:function(t){this.cancelSearch=!0,this._close(t)},_close:function(t){this._off(this.document,"mousedown"),this.menu.element.is(":visible")&&(this.menu.element.hide(),this.menu.blur(),this.isNewMenu=!0,this._trigger("close",t))}
vendor: 27,091 bytes, line 16
16,_change:function(t){this.previous!==this._value()&&this._trigger("change",t,{item:this.selectedItem})},_normalize:function(e){return e.length&&e[0].label&&e[0].value?e:t.map(e,function(e){return"string"==typeof e?{label:e,value:e}:t.extend({},e,{label:e.label||e.value,value:e.value||e.label})})},_suggest:function(e){var i=this.menu.element.empty();this._renderMenu(i,e),this.isNewMenu=!0,this.menu.refresh(),i.show(),this._resizeMenu(),i.position(t.extend({of:this.element},this.options.position)),this.options.autoFocus&&this.menu.next(),this._on(this.document,{mousedown:"_closeOnClickOutside"})},_resizeMenu:function(){var t=this.menu.element;t.outerWidth(Math.max(t.width("").outerWidth()+1,this.element.outerWidth()))},_renderMenu:function(e,i){var s=this;t.each(i,function(t,i){s._renderItemData(e,i)})},_renderItemData:function(t,e){return this._renderItem(t,e).data("ui-autocomplete-item",e)},_renderItem:function(e,i){return t("<li>").append(t("<div>").text(i.label)).appendTo(e)},_move:function(t,e){return this.menu.element.is(":visible")?this.menu.isFirstItem()&&/^previous/.test(t)||this.menu.isLastItem()&&/^next/.test(t)?(this.isMultiLine||this._value(this.term),this.menu.blur(),void 0):(this.menu[t](e),void 0):(this.search(null,e),void 0)},widget:function(){return this.menu.element},_value:function(){return this.valueMethod.apply(this.element,arguments)},_keyEvent:function(t,e){(!this.isMultiLine||this.menu.element.is(":visible"))&&(this._move(t,e),e.preventDefault())},_isContentEditable:function(t){if(!t.length)return!1;var e=t.prop("contentEditable");return"inherit"===e?this._isContentEditable(t.parent()):"true"===e}}),t.extend(t.ui.autocomplete,{escapeRegex:function(t){return t.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&")},filter:function(e,i){var s=RegExp(t.ui.autocomplete.escapeRegex(i),"i");return t.grep(e,function(t){return s.test(t.label||t.value||t)})}}),t.widget("ui.autocomplete",t.ui.autocomplete,{options:{messages:{noResults:"No search results.",results:function(t){return t+(t>1?" results are":" result is")+" available, use up and down arrow keys to navigate."}}},__response:function(e){var i;this._superApply(arguments),this.options.disabled||this.cancelSearch||(i=e&&e.length?this.options.messages.results(e.length):this.options.messages.noResults,this.liveRegion.children().hide(),t("<div>").text(i).appendTo(this.liveRegion))}}),t.ui.autocomplete;var g=/ui-corner-([a-z]){2,6}/g;t.widget("ui.controlgroup",{version:"1.12.1",defaultElement:"<div>",options:{direction:"horizontal",disabled:null,onlyVisible:!0,items:{button:"input[type=button], input[type=submit], input[type=reset], button, a",controlgroupLabel:".ui-controlgroup-label",checkboxradio:"input[type='checkbox'], input[type='radio']",selectmenu:"select",spinner:".ui-spinner-input"}},_create:function(){this._enhance()},_enhance:function(){this.element.attr("role","toolbar"),this.refresh()},_destroy:function(){this._callChildMethod("destroy"),this.childWidgets.removeData("ui-controlgroup-data"),this.element.removeAttr("role"),this.options.items.controlgroupLabel&&this.element.find(this.options.items.controlgroupLabel).find(".ui-controlgroup-label-contents").contents().unwrap()},_initWidgets:function(){var e=this,i=[];t.each(this.options.items,function(s,n){var o,a={};return n?"controlgroupLabel"===s?(o=e.element.find(n),o.each(function(){var e=t(this);e.children(".ui-controlgroup-label-contents").length||e.contents().wrapAll("<span class='ui-controlgroup-label-contents'></span>")}),e._addClass(o,null,"ui-widget ui-widget-content ui-state-default"),i=i.concat(o.get()),void 0):(t.fn[s]&&(a=e["_"+s+"Options"]?e["_"+s+"Options"]("middle"):{classes:{}},e.element.find(n).each(function(){var n=t(this),o=n[s]("instance"),r=t.widget.extend({},a);if("button"!==s||!n.parent(".ui-spinner").length){o||(o=n[s]()[s]("instance")),o&&(r.classes=e._resolveClassesValues(r.classes,o)),n[s](r);var h=n[s]("widget");t.data(h[0],"ui-controlgroup-data",o?o:n[s]("instance")),i.push(h[0])}})),void 0):void 0}),this.childWidgets=t(t.unique(i)),this._addClass(this.childWidgets,"ui-controlgroup-item")},_callChildMethod:function(e){this.childWidgets.each(function(){var i=t(this),s=i.data("ui-controlgroup-data");s&&s[e]&&s[e]()})},_updateCornerClass:function(t,e){var i="ui-corner-top ui-corner-bottom ui-corner-left ui-corner-right ui-corner-all",s=this._buildSimpleOptions(e,"label").classes.label;this._removeClass(t,null,i),this._addClass(t,null,s)},_buildSimpleOptions:function(t,e){var i="vertical"===this.options.direction,s={classes:{}};return s.classes[e]={middle:"",first:"ui-corner-"+(i?"top":"left"),last:"ui-corner-"+(i?"bottom":"right"),only:"ui-corner-all"}[t],s},_spinnerOptions:function(t){var e=this._buildSimpleOptions(t,"ui-spinner");return e.classes["ui-spinner-up"]="",e.classes["ui-spinner-down"]="",e},_buttonOptions:function(t){return this._buildSimpleOptions(t,"ui-button")},_checkboxradioOptions:function(t){return this._buildSimpleOptions(t,"ui-checkboxradio-label")},_selectmenuOptions:function(t){var e="vertical"===this.options.direction;return{width:e?"auto":!1,classes:{middle:{"ui-selectmenu-button-open":"","ui-selectmenu-button-closed":""},first:{"ui-selectmenu-button-open":"ui-corner-"+(e?"top":"tl"),"ui-selectmenu-button-closed":"ui-corner-"+(e?"top":"left")},last:{"ui-selectmenu-button-open":e?"":"ui-corner-tr","ui-selectmenu-button-closed":"ui-corner-"+(e?"bottom":"right")},only:{"ui-selectmenu-button-open":"ui-corner-top","ui-selectmenu-button-closed":"ui-corner-all"}}[t]}},_resolveClassesValues:function(e,i){var s={};return t.each(e,function(n){var o=i.options.classes[n]||"";o=t.trim(o.replace(g,"")),s[n]=(o+" "+e[n]).replace(/\s+/g," ")}),s},_setOption:function(t,e){return"direction"===t&&this._removeClass("ui-controlgroup-"+this.options.direction),this._super(t,e),"disabled"===t?(this._callChildMethod(e?"disable":"enable"),void 0):(this.refresh(),void 0)},refresh:function(){var e,i=this;this._addClass("ui-controlgroup ui-controlgroup-"+this.options.direction),"horizontal"===this.options.direction&&this._addClass(null,"ui-helper-clearfix"),this._initWidgets(),e=this.childWidgets,this.options.onlyVisible&&(e=e.filter(":visible")),e.length&&(t.each(["first","last"],function(t,s){var n=e[s]().data("ui-controlgroup-data");if(n&&i["_"+n.widgetName+"Options"]){var o=i["_"+n.widgetName+"Options"](1===e.length?"only":s);o.classes=i._resolveClassesValues(o.classes,n),n.element[n.widgetName](o)}else i._updateCornerClass(e[s](),s)}),this._callChildMethod("refresh"))}}),t.widget("ui.checkboxradio",[t.ui.formResetMixin,{version:"1.12.1",options:{disabled:null,label:null,icon:!0,classes:{"ui-checkboxradio-label":"ui-corner-all","ui-checkboxradio-icon":"ui-corner-all"}},_getCreateOptions:function(){var e,i,s=this,n=this._super()||{};return this._readType(),i=this.element.labels(),this.label=t(i[i.length-1]),this.label.length||t.error("No label found for checkboxradio widget"),this.originalLabel="",this.label.contents().not(this.element[0]).each(function(){s.originalLabel+=3===this.nodeType?t(this).text():this.outerHTML}),this.originalLabel&&(n.label=this.originalLabel),e=this.element[0].disabled,null!=e&&(n.disabled=e),n},_create:function(){var t=this.element[0].checked;this._bindFormResetHandler(),null==this.options.disabled&&(this.options.disabled=this.element[0].disabled),this._setOption("disabled",this.options.disabled),this._addClass("ui-checkboxradio","ui-helper-hidden-accessible"),this._addClass(this.label,"ui-checkboxradio-label","ui-button ui-widget"),"radio"===this.type&&this._addClass(this.label,"ui-checkboxradio-radio-label"),this.options.label&&this.options.label!==this.originalLabel?this._updateLabel():this.originalLabel&&(this.options.label=this.originalLabel),this._enhance(),t&&(this._addClass(this.label,"ui-checkboxradio-checked","ui-state-active"),this.icon&&this._addClass(this.icon,null,"ui-state-hover")),this._on({change:"_toggleClasses",focus:function(){this._addClass(this.label,null,"ui-state-focus ui-visual-focus")},blur:function(){this._removeClass(this.label,null,"ui-state-focus ui-visual-focus")}})},_readType:function(){var e=this.element[0].nodeName.toLowerCase();this.type=this.element[0].type,"input"===e&&/radio|checkbox/.test(this.type)||t.error("Can't create checkboxradio on element.nodeName="+e+" and element.type="+this.type)},_enhance:function(){this._updateIcon(this.element[0].checked)},widget:function(){return this.label},_getRadioGroup:function(){var e,i=this.element[0].name,s="input[name='"+t.ui.escapeSelector(i)+"']";return i?(e=this.form.length?t(this.form[0].elements).filter(s):t(s).filter(function(){return 0===t(this).form().length}),e.not(this.element)):t([])},_toggleClasses:function(){var e=this.element[0].checked;this._toggleClass(this.label,"ui-checkboxradio-checked","ui-state-active",e),this.options.icon&&"checkbox"===this.type&&this._toggleClass(this.icon,null,"ui-icon-check ui-state-checked",e)._toggleClass(this.icon,null,"ui-icon-blank",!e),"radio"===this.type&&this._getRadioGroup().each(function(){var e=t(this).checkboxradio("instance");e&&e._removeClass(e.label,"ui-checkboxradio-checked","ui-state-active")})},_destroy:function(){this._unbindFormResetHandler(),this.icon&&(this.icon.remove(),this.iconSpace.remove())},_setOption:function(t,e){return"label"!==t||e?(this._super(t,e),"disabled"===t?(this._toggleClass(this.label,null,"ui-state-disabled",e),this.element[0].disabled=e,void 0):(this.refresh(),void 0)):void 0},_updateIcon:function(e){var i="ui-icon ui-icon-background ";this.options.icon?(this.icon||(this.icon=t("<span>"),this.iconSpace=t("<span> </span>"),this._addClass(this.iconSpace,"ui-checkboxradio-icon-space")),"checkbox"===this.type?(i+=e?"ui-icon-check ui-state-checked":"ui-icon-blank",this._removeClass(this.icon,null,e?"ui-icon-blank":"ui-icon-check")):i+="ui-icon-blank",this._addClass(this.icon,"ui-checkboxradio-icon",i),e||this._removeClass(this.icon,null,"ui-icon-check ui-state-checked"),this.icon.prependTo(this.label).after(this.iconSpace)):void 0!==this.icon&&(this.icon.remove(),this.iconSpace.remove(),delete this.icon)},_updateLabel:function(){var t=this.label.contents().not(this.element[0]);this.icon&&(t=t.not(this.icon[0])),this.iconSpace&&(t=t.not(this.iconSpace[0])),t.remove(),this.label.append(this.options.label)},refresh:function(){var t=this.element[0].checked,e=this.element[0].disabled;this._updateIcon(t),this._toggleClass(this.label,"ui-checkboxradio-checked","ui-state-active",t),null!==this.options.label&&this._updateLabel(),e!==this.options.disabled&&this._setOptions({disabled:e})}}]),t.ui.checkboxradio,t.widget("ui.button",{version:"1.12.1",defaultElement:"<button>",options:{classes:{"ui-button":"ui-corner-all"},disabled:null,icon:null,iconPosition:"beginning",label:null,showLabel:!0},_getCreateOptions:function(){var t,e=this._super()||{};return this.isInput=this.element.is("input"),t=this.element[0].disabled,null!=t&&(e.disabled=t),this.originalLabel=this.isInput?this.element.val():this.element.html(),this.originalLabel&&(e.label=this.originalLabel),e},_create:function(){!this.option.showLabel&!this.options.icon&&(this.options.showLabel=!0),null==this.options.disabled&&(this.options.disabled=this.element[0].disabled||!1),this.hasTitle=!!this.element.attr("title"),this.options.label&&this.options.label!==this.originalLabel&&(this.isInput?this.element.val(this.options.label):this.element.html(this.options.label)),this._addClass("ui-button","ui-widget"),this._setOption("disabled",this.options.disabled),this._enhance(),this.element.is("a")&&this._on({keyup:function(e){e.keyCode===t.ui.keyCode.SPACE&&(e.preventDefault(),this.element[0].click?this.element[0].click():this.element.trigger("click"))}})},_enhance:function(){this.element.is("button")||this.element.attr("role","button"),this.options.icon&&(this._updateIcon("icon",this.options.icon),this._updateTooltip())},_updateTooltip:function(){this.title=this.element.attr("title"),this.options.showLabel||this.title||this.element.attr("title",this.options.label)},_updateIcon:function(e,i){var s="iconPosition"!==e,n=s?this.options.iconPosition:i,o="top"===n||"bottom"===n;this.icon?s&&this._removeClass(this.icon,null,this.options.icon):(this.icon=t("<span>"),this._addClass(this.icon,"ui-button-icon","ui-icon"),this.options.showLabel||this._addClass("ui-button-icon-only")),s&&this._addClass(this.icon,null,i),this._attachIcon(n),o?(this._addClass(this.icon,null,"ui-widget-icon-block"),this.iconSpace&&this.iconSpace.remove()):(this.iconSpace||(this.iconSpace=t("<span> </span>"),this._addClass(this.iconSpace,"ui-button-icon-space")),this._removeClass(this.icon,null,"ui-wiget-icon-block"),this._attachIconSpace(n))},_destroy:function(){this.element.removeAttr("role"),this.icon&&this.icon.remove(),this.iconSpace&&this.iconSpace.remove(),this.hasTitle||this.element.removeAttr("title")},_attachIconSpace:function(t){this.icon[/^(?:end|bottom)/.test(t)?"before":"after"](this.iconSpace)},_attachIcon:function(t){this.element[/^(?:end|bottom)/.test(t)?"append":"prepend"](this.icon)},_setOptions:function(t){var e=void 0===t.showLabel?this.options.showLabel:t.showLabel,i=void 0===t.icon?this.options.icon:t.icon;e||i||(t.showLabel=!0),this._super(t)},_setOption:function(t,e){"icon"===t&&(e?this._updateIcon(t,e):this.icon&&(this.icon.remove(),this.iconSpace&&this.iconSpace.remove())),"iconPosition"===t&&this._updateIcon(t,e),"showLabel"===t&&(this._toggleClass("ui-button-icon-only",null,!e),this._updateTooltip()),"label"===t&&(this.isInput?this.element.val(e):(this.element.html(e),this.icon&&(this._attachIcon(this.options.iconPosition),this._attachIconSpace(this.options.iconPosition)))),this._super(t,e),"disabled"===t&&(this._toggleClass(null,"ui-state-disabled",e),this.element[0].disabled=e,e&&this.element.blur())},refresh:function(){var t=this.element.is("input, button")?this.element[0].disabled:this.element.hasClass("ui-button-disabled");t!==this.options.disabled&&this._setOptions({disabled:t}),this._updateTooltip()}}),t.uiBackCompat!==!1&&(t.widget("ui.button",t.ui.button,{options:{text:!0,icons:{primary:null,secondary:null}},_create:function(){this.options.showLabel&&!this.options.text&&(this.options.showLabel=this.options.text),!this.options.showLabel&&this.options.text&&(this.options.text=this.options.showLabel),this.options.icon||!this.options.icons.primary&&!this.options.icons.secondary?this.options.icon&&(this.options.icons.primary=this.options.icon):this.options.icons.primary?this.options.icon=this.options.icons.primary:(this.options.icon=this.options.icons.secondary,this.options.iconPosition="end"),this._super()},_setOption:function(t,e){return"text"===t?(this._super("showLabel",e),void 0):("showLabel"===t&&(this.options.text=e),"icon"===t&&(this.options.icons.primary=e),"icons"===t&&(e.primary?(this._super("icon",e.primary),this._super("iconPosition","beginning")):e.secondary&&(this._super("icon",e.secondary),this._super("iconPosition","end"))),this._superApply(arguments),void 0)}}),t.fn.button=function(e){return function(){return!this.length||this.length&&"INPUT"!==this[0].tagName||this.length&&"INPUT"===this[0].tagName&&"checkbox"!==this.attr("type")&&"radio"!==this.attr("type")?e.apply(this,arguments):(t.ui.checkboxradio||t.error("Checkboxradio widget missing"),0===arguments.length?this.checkboxradio({icon:!1}):this.checkboxradio.apply(this,arguments))}}(t.fn.button),t.fn.buttonset=function(){return t.ui.controlgroup||t.error("Controlgroup widget missing"),"option"===arguments[0]&&"items"===arguments[1]&&arguments[2]?this.controlgroup.apply(this,[arguments[0],"items.button",arguments[2]]):"option"===arguments[0]&&"items"===arguments[1]?this.controlgroup.apply(this,[arguments[0],"items.button"]):("object"==typeof arguments[0]&&arguments[0].items&&(arguments[0].items={button:arguments[0].items}),this.controlgroup.apply(this,arguments))}),t.ui.button,t.extend(t.ui,{datepicker:{version:"1.12.1"}});var m;t.extend(s.prototype,{markerClassName:"hasDatepicker",maxRows:4,_widgetDatepicker:function(){return this.dpDiv},setDefaults:function(t){return a(this._defaults,t||{}),this},_attachDatepicker:function(e,i){var s,n,o;s=e.nodeName.toLowerCase(),n="div"===s||"span"===s,e.id||(this.uuid+=1,e.id="dp"+this.uuid),o=this._newInst(t(e),n),o.settings=t.extend({},i||{}),"input"===s?this._connectDatepicker(e,o):n&&this._inlineDatepicker(e,o)},_newInst:function(e,i){var s=e[0].id.replace(/([^A-Za-z0-9_\-])/g,"\\\\$1");return{id:s,input:e,selectedDay:0,selectedMonth:0,selectedYear:0,drawMonth:0,drawYear:0,inline:i,dpDiv:i?n(t("<div class='"+this._inlineClass+" ui-datepicker ui-widget ui-widget-content ui-helper-clearfix ui-corner-all'></div>")):this.dpDiv}},_connectDatepicker:function(e,i){var s=t(e);i.append=t([]),i.trigger=t([]),s.hasClass(this.markerClassName)||(this._attachments(s,i),s.addClass(this.markerClassName).on("keydown",this._doKeyDown).on("keypress",this._doKeyPress).on("keyup",this._doKeyUp),this._autoSize(i),t.data(e,"datepicker",i),i.settings.disabled&&this._disableDatepicker(e))},_attachments:function(e,i){var s,n,o,a=this._get(i,"appendText"),r=this._get(i,"isRTL");i.append&&i.append.remove(),a&&(i.append=t("<span class='"+this._appendClass+"'>"+a+"</span>"),e[r?"before":"after"](i.append)),e.off("focus",this._showDatepicker),i.trigger&&i.trigger.remove(),s=this._get(i,"showOn"),("focus"===s||"both"===s)&&e.on("focus",this._showDatepicker),("button"===s||"both"===s)&&(n=this._get(i,"buttonText"),o=this._get(i,"buttonImage"),i.trigger=t(this._get(i,"buttonImageOnly")?t("<img/>").addClass(this._triggerClass).attr({src:o,alt:n,title:n}):t("<button type='button'></button>").addClass(this._triggerClass).html(o?t("<img/>").attr({src:o,alt:n,title:n}):n)),e[r?"before":"after"](i.trigger),i.trigger.on("click",function(){return t.datepicker._datepickerShowing&&t.datepicker._lastInput===e[0]?t.datepicker._hideDatepicker():t.datepicker._datepickerShowing&&t.datepicker._lastInput!==e[0]?(t.datepicker._hideDatepicker(),t.datepicker._showDatepicker(e[0])):t.datepicker._showDatepicker(e[0]),!1}))},_autoSize:function(t){if(this._get(t,"autoSize")&&!t.inline){var e,i,s,n,o=new Date(2009,11,20),a=this._get(t,"dateFormat");a.match(/[DM]/)&&(e=function(t){for(i=0,s=0,n=0;t.length>n;n++)t[n].length>i&&(i=t[n].length,s=n);return s},o.setMonth(e(this._get(t,a.match(/MM/)?"monthNames":"monthNamesShort"))),o.setDate(e(this._get(t,a.match(/DD/)?"dayNames":"dayNamesShort"))+20-o.getDay())),t.input.attr("size",this._formatDate(t,o).length)}},_inlineDatepicker:function(e,i){var s=t(e);s.hasClass(this.markerClassName)||(s.addClass(this.markerClassName).append(i.dpDiv),t.data(e,"datepicker",i),this._setDate(i,this._getDefaultDate(i),!0),this._updateDatepicker(i),this._updateAlternate(i),i.settings.disabled&&this._disableDatepicker(e),i.dpDiv.css("display","block"))},_dialogDatepicker:function(e,i,s,n,o){var r,h,l,c,u,d=this._dialogInst;return d||(this.uuid+=1,r="dp"+this.uuid,this._dialogInput=t("<input type='text' id='"+r+"' style='position: absolute; top: -100px; width: 0px;'/>"),this._dialogInput.on("keydown",this._doKeyDown),t("body").append(this._dialogInput),d=this._dialogInst=this._newInst(this._dialogInput,!1),d.settings={},t.data(this._dialogInput[0],"datepicker",d)),a(d.settings,n||{}),i=i&&i.constructor===Date?this._formatDate(d,i):i,this._dialogInput.val(i),this._pos=o?o.length?o:[o.pageX,o.pageY]:null,this._pos||(h=document.documentElement.clientWidth,l=document.documentElement.clientHeight,c=document.documentElement.scrollLeft||document.body.scrollLeft,u=document.documentElement.scrollTop||document.body.scrollTop,this._pos=[h/2-100+c,l/2-150+u]),this._dialogInput.css("left",this._pos[0]+20+"px").css("top",this._pos[1]+"px"),d.settings.onSelect=s,this._inDialog=!0,this.dpDiv.addClass(this._dialogClass),this._showDatepicker(this._dialogInput[0]),t.blockUI&&t.blockUI(this.dpDiv),t.data(this._dialogInput[0],"datepicker",d),this},_destroyDatepicker:function(e){var i,s=t(e),n=t.data(e,"datepicker");s.hasClass(this.markerClassName)&&(i=e.nodeName.toLowerCase(),t.removeData(e,"datepicker"),"input"===i?(n.append.remove(),n.trigger.remove(),s.removeClass(this.markerClassName).off("focus",this._showDatepicker).off("keydown",this._doKeyDown).off("keypress",this._doKeyPress).off("keyup",this._doKeyUp)):("div"===i||"span"===i)&&s.removeClass(this.markerClassName).empty(),m===n&&(m=null))},_enableDatepicker:function(e){var i,s,n=t(e),o=t.data(e,"datepicker");n.hasClass(this.markerClassName)&&(i=e.nodeName.toLowerCase(),"input"===i?(e.disabled=!1,o.trigger.filter("button").each(function(){this.disabled=!1}).end().filter("img").css({opacity:"1.0",cursor:""})):("div"===i||"span"===i)&&(s=n.children("."+this._inlineClass),s.children().removeClass("ui-state-disabled"),s.find("select.ui-datepicker-month, select.ui-datepicker-year").prop("disabled",!1)),this._disabledInputs=t.map(this._disabledInputs,function(t){return t===e?null:t}))},_disableDatepicker:function(e){var i,s,n=t(e),o=t.data(e,"datepicker");n.hasClass(this.markerClassName)&&(i=e.nodeName.toLowerCase(),"input"===i?(e.disabled=!0,o.trigger.filter("button").each(function(){this.disabled=!0}).end().filter("img").css({opacity:"0.5",cursor:"default"})):("div"===i||"span"===i)&&(s=n.children("."+this._inlineClass),s.children().addClass("ui-state-disabled"),s.find("select.ui-datepicker-month, select.ui-datepicker-year").prop("disabled",!0)),this._disabledInputs=t.map(this._disabledInputs,function(t){return t===e?null:t}),this._disabledInputs[this._disabledInputs.length]=e)},_isDisabledDatepicker:function(t){if(!t)return!1;for(var e=0;this._disabledInputs.length>e;e++)if(this._disabledInputs[e]===t)return!0;return!1},_getInst:function(e){try{return t.data(e,"datepicker")}catch(i){throw"Missing instance data for this datepicker"}},_optionDatepicker:function(e,i,s){var n,o,r,h,l=this._getInst(e);return 2===arguments.length&&"string"==typeof i?"defaults"===i?t.extend({},t.datepicker._defaults):l?"all"===i?t.extend({},l.settings):this._get(l,i):null:(n=i||{},"string"==typeof i&&(n={},n[i]=s),l&&(this._curInst===l&&this._hideDatepicker(),o=this._getDateDatepicker(e,!0),r=this._getMinMaxDate(l,"min"),h=this._getMinMaxDate(l,"max"),a(l.settings,n),null!==r&&void 0!==n.dateFormat&&void 0===n.minDate&&(l.settings.minDate=this._formatDate(l,r)),null!==h&&void 0!==n.dateFormat&&void 0===n.maxDate&&(l.settings.maxDate=this._formatDate(l,h)),"disabled"in n&&(n.disabled?this._disableDatepicker(e):this._enableDatepicker(e)),this._attachments(t(e),l),this._autoSize(l),this._setDate(l,o),this._updateAlternate(l),this._updateDatepicker(l)),void 0)},_changeDatepicker:function(t,e,i){this._optionDatepicker(t,e,i)},_refreshDatepicker:function(t){var e=this._getInst(t);e&&this._updateDatepicker(e)},_setDateDatepicker:function(t,e){var i=this._getInst(t);i&&(this._setDate(i,e),this._updateDatepicker(i),this._updateAlternate(i))},_getDateDatepicker:function(t,e){var i=this._getInst(t);return i&&!i.inline&&this._setDateFromField(i,e),i?this._getDate(i):null},_doKeyDown:function(e){var i,s,n,o=t.datepicker._getInst(e.target),a=!0,r=o.dpDiv.is(".ui-datepicker-rtl");if(o._keyEvent=!0,t.datepicker._datepickerShowing)switch(e.keyCode){case 9:t.datepicker._hideDatepicker(),a=!1;break;case 13:return n=t("td."+t.datepicker._dayOverClass+":not(."+t.datepicker._currentClass+")",o.dpDiv),n[0]&&t.datepicker._selectDay(e.target,o.selectedMonth,o.selectedYear,n[0]),i=t.datepicker._get(o,"onSelect"),i?(s=t.datepicker._formatDate(o),i.apply(o.input?o.input[0]:null,[s,o])):t.datepicker._hideDatepicker(),!1;case 27:t.datepicker._hideDatepicker();break;case 33:t.datepicker._adjustDate(e.target,e.ctrlKey?-t.datepicker._get(o,"stepBigMonths"):-t.datepicker._get(o,"stepMonths"),"M");break;case 34:t.datepicker._adjustDate(e.target,e.ctrlKey?+t.datepicker._get(o,"stepBigMonths"):+t.datepicker._get(o,"stepMonths"),"M");break;case 35:(e.ctrlKey||e.metaKey)&&t.datepicker._clearDate(e.target),a=e.ctrlKey||e.metaKey;break;case 36:(e.ctrlKey||e.metaKey)&&t.datepicker._gotoToday(e.target),a=e.ctrlKey||e.metaKey;break;case 37:(e.ctrlKey||e.metaKey)&&t.datepicker._adjustDate(e.target,r?1:-1,"D"),a=e.ctrlKey||e.metaKey,e.originalEvent.altKey&&t.datepicker._adjustDate(e.target,e.ctrlKey?-t.datepicker._get(o,"stepBigMonths"):-t.datepicker._get(o,"stepMonths"),"M");break;case 38:(e.ctrlKey||e.metaKey)&&t.datepicker._adjustDate(e.target,-7,"D"),a=e.ctrlKey||e.metaKey;break;case 39:(e.ctrlKey||e.metaKey)&&t.datepicker._adjustDate(e.target,r?-1:1,"D"),a=e.ctrlKey||e.metaKey,e.originalEvent.altKey&&t.datepicker._adjustDate(e.target,e.ctrlKey?+t.datepicker._get(o,"stepBigMonths"):+t.datepicker._get(o,"stepMonths"),"M");break;case 40:(e.ctrlKey||e.metaKey)&&t.datepicker._adjustDate(e.target,7,"D"),a=e.ctrlKey||e.metaKey;break;default:a=!1}else 36===e.keyCode&&e.ctrlKey?t.datepicker._showDatepicker(this):a=!1;a&&(e.preventDefault(),e.stopPropagation())},_doKeyPress:function(e){var i,s,n=t.datepicker._getInst(e.target);return t.datepicker._get(n,"constrainInput")?(i=t.datepicker._possibleChars(t.datepicker._get(n,"dateFormat")),s=String.fromCharCode(null==e.charCode?e.keyCode:e.charCode),e.ctrlKey||e.metaKey||" ">s||!i||i.indexOf(s)>-1):void 0},_doKeyUp:function(e){var i,s=t.datepicker._getInst(e.target);if(s.input.val()!==s.lastVal)try{i=t.datepicker.parseDate(t.datepicker._get(s,"dateFormat"),s.input?s.input.val():null,t.datepicker._getFormatConfig(s)),i&&(t.datepicker._setDateFromField(s),t.datepicker._updateAlternate(s),t.datepicker._updateDatepicker(s))}catch(n){}return!0},_showDatepicker:function(e){if(e=e.target||e,"input"!==e.nodeName.toLowerCase()&&(e=t("input",e.parentNode)[0]),!t.datepicker._isDisabledDatepicker(e)&&t.datepicker._lastInput!==e){var s,n,o,r,h,l,c;s=t.datepicker._getInst(e),t.datepicker._curInst&&t.datepicker._curInst!==s&&(t.datepicker._curInst.dpDiv.stop(!0,!0),s&&t.datepicker._datepickerShowing&&t.datepicker._hideDatepicker(t.datepicker._curInst.input[0])),n=t.datepicker._get(s,"beforeShow"),o=n?n.apply(e,[e,s]):{},o!==!1&&(a(s.settings,o),s.lastVal=null,t.datepicker._lastInput=e,t.datepicker._setDateFromField(s),t.datepicker._inDialog&&(e.value=""),t.datepicker._pos||(t.datepicker._pos=t.datepicker._findPos(e),t.datepicker._pos[1]+=e.offsetHeight),r=!1,t(e).parents().each(function(){return r|="fixed"===t(this).css("position"),!r}),h={left:t.datepicker._pos[0],top:t.datepicker._pos[1]},t.datepicker._pos=null,s.dpDiv.empty(),s.dpDiv.css({position:"absolute",display:"block",top:"-1000px"}),t.datepicker._updateDatepicker(s),h=t.datepicker._checkOffset(s,h,r),s.dpDiv.css({position:t.datepicker._inDialog&&t.blockUI?"static":r?"fixed":"absolute",display:"none",left:h.left+"px",top:h.top+"px"}),s.inline||(l=t.datepicker._get(s,"showAnim"),c=t.datepicker._get(s,"duration"),s.dpDiv.css("z-index",i(t(e))+1),t.datepicker._datepickerShowing=!0,t.effects&&t.effects.effect[l]?s.dpDiv.show(l,t.datepicker._get(s,"showOptions"),c):s.dpDiv[l||"show"](l?c:null),t.datepicker._shouldFocusInput(s)&&s.input.trigger("focus"),t.datepicker._curInst=s))
17 }},_updateDatepicker:function(e){this.maxRows=4,m
vendor: 10,629 bytes, line 17
17=e,e.dpDiv.empty().append(this._generateHTML(e)),this._attachHandlers(e);var i,s=this._getNumberOfMonths(e),n=s[1],a=17,r=e.dpDiv.find("."+this._dayOverClass+" a");r.length>0&&o.apply(r.get(0)),e.dpDiv.removeClass("ui-datepicker-multi-2 ui-datepicker-multi-3 ui-datepicker-multi-4").width(""),n>1&&e.dpDiv.addClass("ui-datepicker-multi-"+n).css("width",a*n+"em"),e.dpDiv[(1!==s[0]||1!==s[1]?"add":"remove")+"Class"]("ui-datepicker-multi"),e.dpDiv[(this._get(e,"isRTL")?"add":"remove")+"Class"]("ui-datepicker-rtl"),e===t.datepicker._curInst&&t.datepicker._datepickerShowing&&t.datepicker._shouldFocusInput(e)&&e.input.trigger("focus"),e.yearshtml&&(i=e.yearshtml,setTimeout(function(){i===e.yearshtml&&e.yearshtml&&e.dpDiv.find("select.ui-datepicker-year:first").replaceWith(e.yearshtml),i=e.yearshtml=null},0))},_shouldFocusInput:function(t){return t.input&&t.input.is(":visible")&&!t.input.is(":disabled")&&!t.input.is(":focus")},_checkOffset:function(e,i,s){var n=e.dpDiv.outerWidth(),o=e.dpDiv.outerHeight(),a=e.input?e.input.outerWidth():0,r=e.input?e.input.outerHeight():0,h=document.documentElement.clientWidth+(s?0:t(document).scrollLeft()),l=document.documentElement.clientHeight+(s?0:t(document).scrollTop());return i.left-=this._get(e,"isRTL")?n-a:0,i.left-=s&&i.left===e.input.offset().left?t(document).scrollLeft():0,i.top-=s&&i.top===e.input.offset().top+r?t(document).scrollTop():0,i.left-=Math.min(i.left,i.left+n>h&&h>n?Math.abs(i.left+n-h):0),i.top-=Math.min(i.top,i.top+o>l&&l>o?Math.abs(o+r):0),i},_findPos:function(e){for(var i,s=this._getInst(e),n=this._get(s,"isRTL");e&&("hidden"===e.type||1!==e.nodeType||t.expr.filters.hidden(e));)e=e[n?"previousSibling":"nextSibling"];return i=t(e).offset(),[i.left,i.top]},_hideDatepicker:function(e){var i,s,n,o,a=this._curInst;!a||e&&a!==t.data(e,"datepicker")||this._datepickerShowing&&(i=this._get(a,"showAnim"),s=this._get(a,"duration"),n=function(){t.datepicker._tidyDialog(a)},t.effects&&(t.effects.effect[i]||t.effects[i])?a.dpDiv.hide(i,t.datepicker._get(a,"showOptions"),s,n):a.dpDiv["slideDown"===i?"slideUp":"fadeIn"===i?"fadeOut":"hide"](i?s:null,n),i||n(),this._datepickerShowing=!1,o=this._get(a,"onClose"),o&&o.apply(a.input?a.input[0]:null,[a.input?a.input.val():"",a]),this._lastInput=null,this._inDialog&&(this._dialogInput.css({position:"absolute",left:"0",top:"-100px"}),t.blockUI&&(t.unblockUI(),t("body").append(this.dpDiv))),this._inDialog=!1)},_tidyDialog:function(t){t.dpDiv.removeClass(this._dialogClass).off(".ui-datepicker-calendar")},_checkExternalClick:function(e){if(t.datepicker._curInst){var i=t(e.target),s=t.datepicker._getInst(i[0]);(i[0].id!==t.datepicker._mainDivId&&0===i.parents("#"+t.datepicker._mainDivId).length&&!i.hasClass(t.datepicker.markerClassName)&&!i.closest("."+t.datepicker._triggerClass).length&&t.datepicker._datepickerShowing&&(!t.datepicker._inDialog||!t.blockUI)||i.hasClass(t.datepicker.markerClassName)&&t.datepicker._curInst!==s)&&t.datepicker._hideDatepicker()}},_adjustDate:function(e,i,s){var n=t(e),o=this._getInst(n[0]);this._isDisabledDatepicker(n[0])||(this._adjustInstDate(o,i+("M"===s?this._get(o,"showCurrentAtPos"):0),s),this._updateDatepicker(o))},_gotoToday:function(e){var i,s=t(e),n=this._getInst(s[0]);this._get(n,"gotoCurrent")&&n.currentDay?(n.selectedDay=n.currentDay,n.drawMonth=n.selectedMonth=n.currentMonth,n.drawYear=n.selectedYear=n.currentYear):(i=new Date,n.selectedDay=i.getDate(),n.drawMonth=n.selectedMonth=i.getMonth(),n.drawYear=n.selectedYear=i.getFullYear()),this._notifyChange(n),this._adjustDate(s)},_selectMonthYear:function(e,i,s){var n=t(e),o=this._getInst(n[0]);o["selected"+("M"===s?"Month":"Year")]=o["draw"+("M"===s?"Month":"Year")]=parseInt(i.options[i.selectedIndex].value,10),this._notifyChange(o),this._adjustDate(n)},_selectDay:function(e,i,s,n){var o,a=t(e);t(n).hasClass(this._unselectableClass)||this._isDisabledDatepicker(a[0])||(o=this._getInst(a[0]),o.selectedDay=o.currentDay=t("a",n).html(),o.selectedMonth=o.currentMonth=i,o.selectedYear=o.currentYear=s,this._selectDate(e,this._formatDate(o,o.currentDay,o.currentMonth,o.currentYear)))},_clearDate:function(e){var i=t(e);this._selectDate(i,"")},_selectDate:function(e,i){var s,n=t(e),o=this._getInst(n[0]);i=null!=i?i:this._formatDate(o),o.input&&o.input.val(i),this._updateAlternate(o),s=this._get(o,"onSelect"),s?s.apply(o.input?o.input[0]:null,[i,o]):o.input&&o.input.trigger("change"),o.inline?this._updateDatepicker(o):(this._hideDatepicker(),this._lastInput=o.input[0],"object"!=typeof o.input[0]&&o.input.trigger("focus"),this._lastInput=null)},_updateAlternate:function(e){var i,s,n,o=this._get(e,"altField");o&&(i=this._get(e,"altFormat")||this._get(e,"dateFormat"),s=this._getDate(e),n=this.formatDate(i,s,this._getFormatConfig(e)),t(o).val(n))},noWeekends:function(t){var e=t.getDay();return[e>0&&6>e,""]},iso8601Week:function(t){var e,i=new Date(t.getTime());return i.setDate(i.getDate()+4-(i.getDay()||7)),e=i.getTime(),i.setMonth(0),i.setDate(1),Math.floor(Math.round((e-i)/864e5)/7)+1},parseDate:function(e,i,s){if(null==e||null==i)throw"Invalid arguments";if(i="object"==typeof i?""+i:i+"",""===i)return null;var n,o,a,r,h=0,l=(s?s.shortYearCutoff:null)||this._defaults.shortYearCutoff,c="string"!=typeof l?l:(new Date).getFullYear()%100+parseInt(l,10),u=(s?s.dayNamesShort:null)||this._defaults.dayNamesShort,d=(s?s.dayNames:null)||this._defaults.dayNames,p=(s?s.monthNamesShort:null)||this._defaults.monthNamesShort,f=(s?s.monthNames:null)||this._defaults.monthNames,g=-1,m=-1,_=-1,v=-1,b=!1,y=function(t){var i=e.length>n+1&&e.charAt(n+1)===t;return i&&n++,i},w=function(t){var e=y(t),s="@"===t?14:"!"===t?20:"y"===t&&e?4:"o"===t?3:2,n="y"===t?s:1,o=RegExp("^\\d{"+n+","+s+"}"),a=i.substring(h).match(o);if(!a)throw"Missing number at position "+h;return h+=a[0].length,parseInt(a[0],10)},k=function(e,s,n){var o=-1,a=t.map(y(e)?n:s,function(t,e){return[[e,t]]}).sort(function(t,e){return-(t[1].length-e[1].length)});if(t.each(a,function(t,e){var s=e[1];return i.substr(h,s.length).toLowerCase()===s.toLowerCase()?(o=e[0],h+=s.length,!1):void 0}),-1!==o)return o+1;throw"Unknown name at position "+h},x=function(){if(i.charAt(h)!==e.charAt(n))throw"Unexpected literal at position "+h;h++};for(n=0;e.length>n;n++)if(b)"'"!==e.charAt(n)||y("'")?x():b=!1;else switch(e.charAt(n)){case"d":_=w("d");break;case"D":k("D",u,d);break;case"o":v=w("o");break;case"m":m=w("m");break;case"M":m=k("M",p,f);break;case"y":g=w("y");break;case"@":r=new Date(w("@")),g=r.getFullYear(),m=r.getMonth()+1,_=r.getDate();break;case"!":r=new Date((w("!")-this._ticksTo1970)/1e4),g=r.getFullYear(),m=r.getMonth()+1,_=r.getDate();break;case"'":y("'")?x():b=!0;break;default:x()}if(i.length>h&&(a=i.substr(h),!/^\s+/.test(a)))throw"Extra/unparsed characters found in date: "+a;if(-1===g?g=(new Date).getFullYear():100>g&&(g+=(new Date).getFullYear()-(new Date).getFullYear()%100+(c>=g?0:-100)),v>-1)for(m=1,_=v;;){if(o=this._getDaysInMonth(g,m-1),o>=_)break;m++,_-=o}if(r=this._daylightSavingAdjust(new Date(g,m-1,_)),r.getFullYear()!==g||r.getMonth()+1!==m||r.getDate()!==_)throw"Invalid date";return r},ATOM:"yy-mm-dd",COOKIE:"D, dd M yy",ISO_8601:"yy-mm-dd",RFC_822:"D, d M y",RFC_850:"DD, dd-M-y",RFC_1036:"D, d M y",RFC_1123:"D, d M yy",RFC_2822:"D, d M yy",RSS:"D, d M y",TICKS:"!",TIMESTAMP:"@",W3C:"yy-mm-dd",_ticksTo1970:1e7*60*60*24*(718685+Math.floor(492.5)-Math.floor(19.7)+Math.floor(4.925)),formatDate:function(t,e,i){if(!e)return"";var s,n=(i?i.dayNamesShort:null)||this._defaults.dayNamesShort,o=(i?i.dayNames:null)||this._defaults.dayNames,a=(i?i.monthNamesShort:null)||this._defaults.monthNamesShort,r=(i?i.monthNames:null)||this._defaults.monthNames,h=function(e){var i=t.length>s+1&&t.charAt(s+1)===e;return i&&s++,i},l=function(t,e,i){var s=""+e;if(h(t))for(;i>s.length;)s="0"+s;return s},c=function(t,e,i,s){return h(t)?s[e]:i[e]},u="",d=!1;if(e)for(s=0;t.length>s;s++)if(d)"'"!==t.charAt(s)||h("'")?u+=t.charAt(s):d=!1;else switch(t.charAt(s)){case"d":u+=l("d",e.getDate(),2);break;case"D":u+=c("D",e.getDay(),n,o);break;case"o":u+=l("o",Math.round((new Date(e.getFullYear(),e.getMonth(),e.getDate()).getTime()-new Date(e.getFullYear(),0,0).getTime())/864e5),3);break;case"m":u+=l("m",e.getMonth()+1,2);break;case"M":u+=c("M",e.getMonth(),a,r);break;case"y":u+=h("y")?e.getFullYear():(10>e.getFullYear()%100?"0":"")+e.getFullYear()%100;break;case"@":u+=e.getTime();break;case"!":u+=1e4*e.getTime()+this._ticksTo1970;break;case"'":h("'")?u+="'":d=!0;break;default:u+=t.charAt(s)}return u},_possibleChars:function(t){var e,i="",s=!1,n=function(i){var s=t.length>e+1&&t.charAt(e+1)===i;return s&&e++,s};for(e=0;t.length>e;e++)if(s)"'"!==t.charAt(e)||n("'")?i+=t.charAt(e):s=!1;else switch(t.charAt(e)){case"d":case"m":case"y":case"@":i+="0123456789";break;case"D":case"M":return null;case"'":n("'")?i+="'":s=!0;break;default:i+=t.charAt(e)}return i},_get:function(t,e){return void 0!==t.settings[e]?t.settings[e]:this._defaults[e]},_setDateFromField:function(t,e){if(t.input.val()!==t.lastVal){var i=this._get(t,"dateFormat"),s=t.lastVal=t.input?t.input.val():null,n=this._getDefaultDate(t),o=n,a=this._getFormatConfig(t);try{o=this.parseDate(i,s,a)||n}catch(r){s=e?"":s}t.selectedDay=o.getDate(),t.drawMonth=t.selectedMonth=o.getMonth(),t.drawYear=t.selectedYear=o.getFullYear(),t.currentDay=s?o.getDate():0,t.currentMonth=s?o.getMonth():0,t.currentYear=s?o.getFullYear():0,this._adjustInstDate(t)}},_getDefaultDate:function(t){return this._restrictMinMax(t,this._determineDate(t,this._get(t,"defaultDate"),new Date))},_determineDate:function(e,i,s){var n=function(t){var e=new Date;return e.setDate(e.getDate()+t),e},o=function(i){try{return t.datepicker.parseDate(t.datepicker._get(e,"dateFormat"),i,t.datepicker._getFormatConfig(e))}catch(s){}for(var n=(i.toLowerCase().match(/^c/)?t.datepicker._getDate(e):null)||new Date,o=n.getFullYear(),a=n.getMonth(),r=n.getDate(),h=/([+\-]?[0-9]+)\s*(d|D|w|W|m|M|y|Y)?/g,l=h.exec(i);l;){switch(l[2]||"d"){case"d":case"D":r+=parseInt(l[1],10);break;case"w":case"W":r+=7*parseInt(l[1],10);break;case"m":case"M":a+=parseInt(l[1],10),r=Math.min(r,t.datepicker._getDaysInMonth(o,a));break;case"y":case"Y":o+=parseInt(l[1],10),r=Math.min(r,t.datepicker._getDaysInMonth(o,a))}l=h.exec(i)}return new Date(o,a,r)},a=null==i||""===i?s:"string"==typeof i?o(i):"number"==typeof i?isNaN(i)?s:n(i):new Date(i.getTime());return a=a&&"Invalid Date"==""+a?s:a,a&&(a.setHours(0),a.setMinutes(0),a.setSeconds(0),a.setMilliseconds(0)),this._daylightSavingAdjust(a)},_daylightSavingAdjust:function(t){return t?(t.setHours(t.getHours()>12?t.getHours()+2:0),t):null}
vendor: 21,365 bytes, line 17
17,_setDate:function(t,e,i){var s=!e,n=t.selectedMonth,o=t.selectedYear,a=this._restrictMinMax(t,this._determineDate(t,e,new Date));t.selectedDay=t.currentDay=a.getDate(),t.drawMonth=t.selectedMonth=t.currentMonth=a.getMonth(),t.drawYear=t.selectedYear=t.currentYear=a.getFullYear(),n===t.selectedMonth&&o===t.selectedYear||i||this._notifyChange(t),this._adjustInstDate(t),t.input&&t.input.val(s?"":this._formatDate(t))},_getDate:function(t){var e=!t.currentYear||t.input&&""===t.input.val()?null:this._daylightSavingAdjust(new Date(t.currentYear,t.currentMonth,t.currentDay));return e},_attachHandlers:function(e){var i=this._get(e,"stepMonths"),s="#"+e.id.replace(/\\\\/g,"\\");e.dpDiv.find("[data-handler]").map(function(){var e={prev:function(){t.datepicker._adjustDate(s,-i,"M")},next:function(){t.datepicker._adjustDate(s,+i,"M")},hide:function(){t.datepicker._hideDatepicker()},today:function(){t.datepicker._gotoToday(s)},selectDay:function(){return t.datepicker._selectDay(s,+this.getAttribute("data-month"),+this.getAttribute("data-year"),this),!1},selectMonth:function(){return t.datepicker._selectMonthYear(s,this,"M"),!1},selectYear:function(){return t.datepicker._selectMonthYear(s,this,"Y"),!1}};t(this).on(this.getAttribute("data-event"),e[this.getAttribute("data-handler")])})},_generateHTML:function(t){var e,i,s,n,o,a,r,h,l,c,u,d,p,f,g,m,_,v,b,y,w,k,x,C,D,I,T,P,M,S,H,z,O,A,N,W,E,F,L,R=new Date,B=this._daylightSavingAdjust(new Date(R.getFullYear(),R.getMonth(),R.getDate())),Y=this._get(t,"isRTL"),j=this._get(t,"showButtonPanel"),q=this._get(t,"hideIfNoPrevNext"),K=this._get(t,"navigationAsDateFormat"),U=this._getNumberOfMonths(t),V=this._get(t,"showCurrentAtPos"),$=this._get(t,"stepMonths"),X=1!==U[0]||1!==U[1],G=this._daylightSavingAdjust(t.currentDay?new Date(t.currentYear,t.currentMonth,t.currentDay):new Date(9999,9,9)),Q=this._getMinMaxDate(t,"min"),J=this._getMinMaxDate(t,"max"),Z=t.drawMonth-V,te=t.drawYear;if(0>Z&&(Z+=12,te--),J)for(e=this._daylightSavingAdjust(new Date(J.getFullYear(),J.getMonth()-U[0]*U[1]+1,J.getDate())),e=Q&&Q>e?Q:e;this._daylightSavingAdjust(new Date(te,Z,1))>e;)Z--,0>Z&&(Z=11,te--);for(t.drawMonth=Z,t.drawYear=te,i=this._get(t,"prevText"),i=K?this.formatDate(i,this._daylightSavingAdjust(new Date(te,Z-$,1)),this._getFormatConfig(t)):i,s=this._canAdjustMonth(t,-1,te,Z)?"<a class='ui-datepicker-prev ui-corner-all' data-handler='prev' data-event='click' title='"+i+"'><span class='ui-icon ui-icon-circle-triangle-"+(Y?"e":"w")+"'>"+i+"</span></a>":q?"":"<a class='ui-datepicker-prev ui-corner-all ui-state-disabled' title='"+i+"'><span class='ui-icon ui-icon-circle-triangle-"+(Y?"e":"w")+"'>"+i+"</span></a>",n=this._get(t,"nextText"),n=K?this.formatDate(n,this._daylightSavingAdjust(new Date(te,Z+$,1)),this._getFormatConfig(t)):n,o=this._canAdjustMonth(t,1,te,Z)?"<a class='ui-datepicker-next ui-corner-all' data-handler='next' data-event='click' title='"+n+"'><span class='ui-icon ui-icon-circle-triangle-"+(Y?"w":"e")+"'>"+n+"</span></a>":q?"":"<a class='ui-datepicker-next ui-corner-all ui-state-disabled' title='"+n+"'><span class='ui-icon ui-icon-circle-triangle-"+(Y?"w":"e")+"'>"+n+"</span></a>",a=this._get(t,"currentText"),r=this._get(t,"gotoCurrent")&&t.currentDay?G:B,a=K?this.formatDate(a,r,this._getFormatConfig(t)):a,h=t.inline?"":"<button type='button' class='ui-datepicker-close ui-state-default ui-priority-primary ui-corner-all' data-handler='hide' data-event='click'>"+this._get(t,"closeText")+"</button>",l=j?"<div class='ui-datepicker-buttonpane ui-widget-content'>"+(Y?h:"")+(this._isInRange(t,r)?"<button type='button' class='ui-datepicker-current ui-state-default ui-priority-secondary ui-corner-all' data-handler='today' data-event='click'>"+a+"</button>":"")+(Y?"":h)+"</div>":"",c=parseInt(this._get(t,"firstDay"),10),c=isNaN(c)?0:c,u=this._get(t,"showWeek"),d=this._get(t,"dayNames"),p=this._get(t,"dayNamesMin"),f=this._get(t,"monthNames"),g=this._get(t,"monthNamesShort"),m=this._get(t,"beforeShowDay"),_=this._get(t,"showOtherMonths"),v=this._get(t,"selectOtherMonths"),b=this._getDefaultDate(t),y="",k=0;U[0]>k;k++){for(x="",this.maxRows=4,C=0;U[1]>C;C++){if(D=this._daylightSavingAdjust(new Date(te,Z,t.selectedDay)),I=" ui-corner-all",T="",X){if(T+="<div class='ui-datepicker-group",U[1]>1)switch(C){case 0:T+=" ui-datepicker-group-first",I=" ui-corner-"+(Y?"right":"left");break;case U[1]-1:T+=" ui-datepicker-group-last",I=" ui-corner-"+(Y?"left":"right");break;default:T+=" ui-datepicker-group-middle",I=""}T+="'>"}for(T+="<div class='ui-datepicker-header ui-widget-header ui-helper-clearfix"+I+"'>"+(/all|left/.test(I)&&0===k?Y?o:s:"")+(/all|right/.test(I)&&0===k?Y?s:o:"")+this._generateMonthYearHeader(t,Z,te,Q,J,k>0||C>0,f,g)+"</div><table class='ui-datepicker-calendar'><thead>"+"<tr>",P=u?"<th class='ui-datepicker-week-col'>"+this._get(t,"weekHeader")+"</th>":"",w=0;7>w;w++)M=(w+c)%7,P+="<th scope='col'"+((w+c+6)%7>=5?" class='ui-datepicker-week-end'":"")+">"+"<span title='"+d[M]+"'>"+p[M]+"</span></th>";for(T+=P+"</tr></thead><tbody>",S=this._getDaysInMonth(te,Z),te===t.selectedYear&&Z===t.selectedMonth&&(t.selectedDay=Math.min(t.selectedDay,S)),H=(this._getFirstDayOfMonth(te,Z)-c+7)%7,z=Math.ceil((H+S)/7),O=X?this.maxRows>z?this.maxRows:z:z,this.maxRows=O,A=this._daylightSavingAdjust(new Date(te,Z,1-H)),N=0;O>N;N++){for(T+="<tr>",W=u?"<td class='ui-datepicker-week-col'>"+this._get(t,"calculateWeek")(A)+"</td>":"",w=0;7>w;w++)E=m?m.apply(t.input?t.input[0]:null,[A]):[!0,""],F=A.getMonth()!==Z,L=F&&!v||!E[0]||Q&&Q>A||J&&A>J,W+="<td class='"+((w+c+6)%7>=5?" ui-datepicker-week-end":"")+(F?" ui-datepicker-other-month":"")+(A.getTime()===D.getTime()&&Z===t.selectedMonth&&t._keyEvent||b.getTime()===A.getTime()&&b.getTime()===D.getTime()?" "+this._dayOverClass:"")+(L?" "+this._unselectableClass+" ui-state-disabled":"")+(F&&!_?"":" "+E[1]+(A.getTime()===G.getTime()?" "+this._currentClass:"")+(A.getTime()===B.getTime()?" ui-datepicker-today":""))+"'"+(F&&!_||!E[2]?"":" title='"+E[2].replace(/'/g,"'")+"'")+(L?"":" data-handler='selectDay' data-event='click' data-month='"+A.getMonth()+"' data-year='"+A.getFullYear()+"'")+">"+(F&&!_?" ":L?"<span class='ui-state-default'>"+A.getDate()+"</span>":"<a class='ui-state-default"+(A.getTime()===B.getTime()?" ui-state-highlight":"")+(A.getTime()===G.getTime()?" ui-state-active":"")+(F?" ui-priority-secondary":"")+"' href='#'>"+A.getDate()+"</a>")+"</td>",A.setDate(A.getDate()+1),A=this._daylightSavingAdjust(A);T+=W+"</tr>"}Z++,Z>11&&(Z=0,te++),T+="</tbody></table>"+(X?"</div>"+(U[0]>0&&C===U[1]-1?"<div class='ui-datepicker-row-break'></div>":""):""),x+=T}y+=x}return y+=l,t._keyEvent=!1,y},_generateMonthYearHeader:function(t,e,i,s,n,o,a,r){var h,l,c,u,d,p,f,g,m=this._get(t,"changeMonth"),_=this._get(t,"changeYear"),v=this._get(t,"showMonthAfterYear"),b="<div class='ui-datepicker-title'>",y="";if(o||!m)y+="<span class='ui-datepicker-month'>"+a[e]+"</span>";else{for(h=s&&s.getFullYear()===i,l=n&&n.getFullYear()===i,y+="<select class='ui-datepicker-month' data-handler='selectMonth' data-event='change'>",c=0;12>c;c++)(!h||c>=s.getMonth())&&(!l||n.getMonth()>=c)&&(y+="<option value='"+c+"'"+(c===e?" selected='selected'":"")+">"+r[c]+"</option>");y+="</select>"}if(v||(b+=y+(!o&&m&&_?"":" ")),!t.yearshtml)if(t.yearshtml="",o||!_)b+="<span class='ui-datepicker-year'>"+i+"</span>";else{for(u=this._get(t,"yearRange").split(":"),d=(new Date).getFullYear(),p=function(t){var e=t.match(/c[+\-].*/)?i+parseInt(t.substring(1),10):t.match(/[+\-].*/)?d+parseInt(t,10):parseInt(t,10);return isNaN(e)?d:e},f=p(u[0]),g=Math.max(f,p(u[1]||"")),f=s?Math.max(f,s.getFullYear()):f,g=n?Math.min(g,n.getFullYear()):g,t.yearshtml+="<select class='ui-datepicker-year' data-handler='selectYear' data-event='change'>";g>=f;f++)t.yearshtml+="<option value='"+f+"'"+(f===i?" selected='selected'":"")+">"+f+"</option>";t.yearshtml+="</select>",b+=t.yearshtml,t.yearshtml=null}return b+=this._get(t,"yearSuffix"),v&&(b+=(!o&&m&&_?"":" ")+y),b+="</div>"},_adjustInstDate:function(t,e,i){var s=t.selectedYear+("Y"===i?e:0),n=t.selectedMonth+("M"===i?e:0),o=Math.min(t.selectedDay,this._getDaysInMonth(s,n))+("D"===i?e:0),a=this._restrictMinMax(t,this._daylightSavingAdjust(new Date(s,n,o)));t.selectedDay=a.getDate(),t.drawMonth=t.selectedMonth=a.getMonth(),t.drawYear=t.selectedYear=a.getFullYear(),("M"===i||"Y"===i)&&this._notifyChange(t)},_restrictMinMax:function(t,e){var i=this._getMinMaxDate(t,"min"),s=this._getMinMaxDate(t,"max"),n=i&&i>e?i:e;return s&&n>s?s:n},_notifyChange:function(t){var e=this._get(t,"onChangeMonthYear");e&&e.apply(t.input?t.input[0]:null,[t.selectedYear,t.selectedMonth+1,t])},_getNumberOfMonths:function(t){var e=this._get(t,"numberOfMonths");return null==e?[1,1]:"number"==typeof e?[1,e]:e},_getMinMaxDate:function(t,e){return this._determineDate(t,this._get(t,e+"Date"),null)},_getDaysInMonth:function(t,e){return 32-this._daylightSavingAdjust(new Date(t,e,32)).getDate()},_getFirstDayOfMonth:function(t,e){return new Date(t,e,1).getDay()},_canAdjustMonth:function(t,e,i,s){var n=this._getNumberOfMonths(t),o=this._daylightSavingAdjust(new Date(i,s+(0>e?e:n[0]*n[1]),1));return 0>e&&o.setDate(this._getDaysInMonth(o.getFullYear(),o.getMonth())),this._isInRange(t,o)},_isInRange:function(t,e){var i,s,n=this._getMinMaxDate(t,"min"),o=this._getMinMaxDate(t,"max"),a=null,r=null,h=this._get(t,"yearRange");return h&&(i=h.split(":"),s=(new Date).getFullYear(),a=parseInt(i[0],10),r=parseInt(i[1],10),i[0].match(/[+\-].*/)&&(a+=s),i[1].match(/[+\-].*/)&&(r+=s)),(!n||e.getTime()>=n.getTime())&&(!o||e.getTime()<=o.getTime())&&(!a||e.getFullYear()>=a)&&(!r||r>=e.getFullYear())},_getFormatConfig:function(t){var e=this._get(t,"shortYearCutoff");return e="string"!=typeof e?e:(new Date).getFullYear()%100+parseInt(e,10),{shortYearCutoff:e,dayNamesShort:this._get(t,"dayNamesShort"),dayNames:this._get(t,"dayNames"),monthNamesShort:this._get(t,"monthNamesShort"),monthNames:this._get(t,"monthNames")}},_formatDate:function(t,e,i,s){e||(t.currentDay=t.selectedDay,t.currentMonth=t.selectedMonth,t.currentYear=t.selectedYear);var n=e?"object"==typeof e?e:this._daylightSavingAdjust(new Date(s,i,e)):this._daylightSavingAdjust(new Date(t.currentYear,t.currentMonth,t.currentDay));return this.formatDate(this._get(t,"dateFormat"),n,this._getFormatConfig(t))}}),t.fn.datepicker=function(e){if(!this.length)return this;t.datepicker.initialized||(t(document).on("mousedown",t.datepicker._checkExternalClick),t.datepicker.initialized=!0),0===t("#"+t.datepicker._mainDivId).length&&t("body").append(t.datepicker.dpDiv);var i=Array.prototype.slice.call(arguments,1);return"string"!=typeof e||"isDisabled"!==e&&"getDate"!==e&&"widget"!==e?"option"===e&&2===arguments.length&&"string"==typeof arguments[1]?t.datepicker["_"+e+"Datepicker"].apply(t.datepicker,[this[0]].concat(i)):this.each(function(){"string"==typeof e?t.datepicker["_"+e+"Datepicker"].apply(t.datepicker,[this].concat(i)):t.datepicker._attachDatepicker(this,e)}):t.datepicker["_"+e+"Datepicker"].apply(t.datepicker,[this[0]].concat(i))},t.datepicker=new s,t.datepicker.initialized=!1,t.datepicker.uuid=(new Date).getTime(),t.datepicker.version="1.12.1",t.datepicker,t.ui.ie=!!/msie [\w.]+/.exec(navigator.userAgent.toLowerCase());var _=!1;t(document).on("mouseup",function(){_=!1}),t.widget("ui.mouse",{version:"1.12.1",options:{cancel:"input, textarea, button, select, option",distance:1,delay:0},_mouseInit:function(){var e=this;this.element.on("mousedown."+this.widgetName,function(t){return e._mouseDown(t)}).on("click."+this.widgetName,function(i){return!0===t.data(i.target,e.widgetName+".preventClickEvent")?(t.removeData(i.target,e.widgetName+".preventClickEvent"),i.stopImmediatePropagation(),!1):void 0}),this.started=!1},_mouseDestroy:function(){this.element.off("."+this.widgetName),this._mouseMoveDelegate&&this.document.off("mousemove."+this.widgetName,this._mouseMoveDelegate).off("mouseup."+this.widgetName,this._mouseUpDelegate)},_mouseDown:function(e){if(!_){this._mouseMoved=!1,this._mouseStarted&&this._mouseUp(e),this._mouseDownEvent=e;var i=this,s=1===e.which,n="string"==typeof this.options.cancel&&e.target.nodeName?t(e.target).closest(this.options.cancel).length:!1;return s&&!n&&this._mouseCapture(e)?(this.mouseDelayMet=!this.options.delay,this.mouseDelayMet||(this._mouseDelayTimer=setTimeout(function(){i.mouseDelayMet=!0},this.options.delay)),this._mouseDistanceMet(e)&&this._mouseDelayMet(e)&&(this._mouseStarted=this._mouseStart(e)!==!1,!this._mouseStarted)?(e.preventDefault(),!0):(!0===t.data(e.target,this.widgetName+".preventClickEvent")&&t.removeData(e.target,this.widgetName+".preventClickEvent"),this._mouseMoveDelegate=function(t){return i._mouseMove(t)},this._mouseUpDelegate=function(t){return i._mouseUp(t)},this.document.on("mousemove."+this.widgetName,this._mouseMoveDelegate).on("mouseup."+this.widgetName,this._mouseUpDelegate),e.preventDefault(),_=!0,!0)):!0}},_mouseMove:function(e){if(this._mouseMoved){if(t.ui.ie&&(!document.documentMode||9>document.documentMode)&&!e.button)return this._mouseUp(e);if(!e.which)if(e.originalEvent.altKey||e.originalEvent.ctrlKey||e.originalEvent.metaKey||e.originalEvent.shiftKey)this.ignoreMissingWhich=!0;else if(!this.ignoreMissingWhich)return this._mouseUp(e)}return(e.which||e.button)&&(this._mouseMoved=!0),this._mouseStarted?(this._mouseDrag(e),e.preventDefault()):(this._mouseDistanceMet(e)&&this._mouseDelayMet(e)&&(this._mouseStarted=this._mouseStart(this._mouseDownEvent,e)!==!1,this._mouseStarted?this._mouseDrag(e):this._mouseUp(e)),!this._mouseStarted)},_mouseUp:function(e){this.document.off("mousemove."+this.widgetName,this._mouseMoveDelegate).off("mouseup."+this.widgetName,this._mouseUpDelegate),this._mouseStarted&&(this._mouseStarted=!1,e.target===this._mouseDownEvent.target&&t.data(e.target,this.widgetName+".preventClickEvent",!0),this._mouseStop(e)),this._mouseDelayTimer&&(clearTimeout(this._mouseDelayTimer),delete this._mouseDelayTimer),this.ignoreMissingWhich=!1,_=!1,e.preventDefault()},_mouseDistanceMet:function(t){return Math.max(Math.abs(this._mouseDownEvent.pageX-t.pageX),Math.abs(this._mouseDownEvent.pageY-t.pageY))>=this.options.distance},_mouseDelayMet:function(){return this.mouseDelayMet},_mouseStart:function(){},_mouseDrag:function(){},_mouseStop:function(){},_mouseCapture:function(){return!0}}),t.ui.plugin={add:function(e,i,s){var n,o=t.ui[e].prototype;for(n in s)o.plugins[n]=o.plugins[n]||[],o.plugins[n].push([i,s[n]])},call:function(t,e,i,s){var n,o=t.plugins[e];if(o&&(s||t.element[0].parentNode&&11!==t.element[0].parentNode.nodeType))for(n=0;o.length>n;n++)t.options[o[n][0]]&&o[n][1].apply(t.element,i)}},t.ui.safeBlur=function(e){e&&"body"!==e.nodeName.toLowerCase()&&t(e).trigger("blur")},t.widget("ui.draggable",t.ui.mouse,{version:"1.12.1",widgetEventPrefix:"drag",options:{addClasses:!0,appendTo:"parent",axis:!1,connectToSortable:!1,containment:!1,cursor:"auto",cursorAt:!1,grid:!1,handle:!1,helper:"original",iframeFix:!1,opacity:!1,refreshPositions:!1,revert:!1,revertDuration:500,scope:"default",scroll:!0,scrollSensitivity:20,scrollSpeed:20,snap:!1,snapMode:"both",snapTolerance:20,stack:!1,zIndex:!1,drag:null,start:null,stop:null},_create:function(){"original"===this.options.helper&&this._setPositionRelative(),this.options.addClasses&&this._addClass("ui-draggable"),this._setHandleClassName(),this._mouseInit()},_setOption:function(t,e){this._super(t,e),"handle"===t&&(this._removeHandleClassName(),this._setHandleClassName())},_destroy:function(){return(this.helper||this.element).is(".ui-draggable-dragging")?(this.destroyOnClear=!0,void 0):(this._removeHandleClassName(),this._mouseDestroy(),void 0)},_mouseCapture:function(e){var i=this.options;return this.helper||i.disabled||t(e.target).closest(".ui-resizable-handle").length>0?!1:(this.handle=this._getHandle(e),this.handle?(this._blurActiveElement(e),this._blockFrames(i.iframeFix===!0?"iframe":i.iframeFix),!0):!1)},_blockFrames:function(e){this.iframeBlocks=this.document.find(e).map(function(){var e=t(this);return t("<div>").css("position","absolute").appendTo(e.parent()).outerWidth(e.outerWidth()).outerHeight(e.outerHeight()).offset(e.offset())[0]})},_unblockFrames:function(){this.iframeBlocks&&(this.iframeBlocks.remove(),delete this.iframeBlocks)},_blurActiveElement:function(e){var i=t.ui.safeActiveElement(this.document[0]),s=t(e.target);s.closest(i).length||t.ui.safeBlur(i)},_mouseStart:function(e){var i=this.options;return this.helper=this._createHelper(e),this._addClass(this.helper,"ui-draggable-dragging"),this._cacheHelperProportions(),t.ui.ddmanager&&(t.ui.ddmanager.current=this),this._cacheMargins(),this.cssPosition=this.helper.css("position"),this.scrollParent=this.helper.scrollParent(!0),this.offsetParent=this.helper.offsetParent(),this.hasFixedAncestor=this.helper.parents().filter(function(){return"fixed"===t(this).css("position")}).length>0,this.positionAbs=this.element.offset(),this._refreshOffsets(e),this.originalPosition=this.position=this._generatePosition(e,!1),this.originalPageX=e.pageX,this.originalPageY=e.pageY,i.cursorAt&&this._adjustOffsetFromHelper(i.cursorAt),this._setContainment(),this._trigger("start",e)===!1?(this._clear(),!1):(this._cacheHelperProportions(),t.ui.ddmanager&&!i.dropBehaviour&&t.ui.ddmanager.prepareOffsets(this,e),this._mouseDrag(e,!0),t.ui.ddmanager&&t.ui.ddmanager.dragStart(this,e),!0)},_refreshOffsets:function(t){this.offset={top:this.positionAbs.top-this.margins.top,left:this.positionAbs.left-this.margins.left,scroll:!1,parent:this._getParentOffset(),relative:this._getRelativeOffset()},this.offset.click={left:t.pageX-this.offset.left,top:t.pageY-this.offset.top}},_mouseDrag:function(e,i){if(this.hasFixedAncestor&&(this.offset.parent=this._getParentOffset()),this.position=this._generatePosition(e,!0),this.positionAbs=this._convertPositionTo("absolute"),!i){var s=this._uiHash();if(this._trigger("drag",e,s)===!1)return this._mouseUp(new t.Event("mouseup",e)),!1;this.position=s.position}return this.helper[0].style.left=this.position.left+"px",this.helper[0].style.top=this.position.top+"px",t.ui.ddmanager&&t.ui.ddmanager.drag(this,e),!1},_mouseStop:function(e){var i=this,s=!1;return t.ui.ddmanager&&!this.options.dropBehaviour&&(s=t.ui.ddmanager.drop(this,e)),this.dropped&&(s=this.dropped,this.dropped=!1),"invalid"===this.options.revert&&!s||"valid"===this.options.revert&&s||this.options.revert===!0||t.isFunction(this.options.revert)&&this.options.revert.call(this.element,s)?t(this.helper).animate(this.originalPosition,parseInt(this.options.revertDuration,10),function(){i._trigger("stop",e)!==!1&&i._clear()}):this._trigger("stop",e)!==!1&&this._clear(),!1},_mouseUp:function(e){return this._unblockFrames(),t.ui.ddmanager&&t.ui.ddmanager.dragStop(this,e),this.handleElement.is(e.target)&&this.element.trigger("focus"),t.ui.mouse.prototype._mouseUp.call(this,e)},cancel:function(){return this.helper.is(".ui-draggable-dragging")?this._mouseUp(new t.Event("mouseup",{target:this.element[0]})):this._clear(),this},_getHandle:function(e){return this.options.handle?!!t(e.target).closest(this.element.find(this.options.handle)).length:!0},_setHandleClassName:function(){this.handleElement=this.options.handle?this.element.find(this.options.handle):this.element,this._addClass(this.handleElement,"ui-draggable-handle")},_removeHandleClassName:function(){this._removeClass(this.handleElement,"ui-draggable-handle")},_createHelper:function(e){var i=this.options,s=t.isFunction(i.helper),n=s?t(i.helper.apply(this.element[0],[e])):"clone"===i.helper?this.element.clone().removeAttr("id"):this.element;return n.parents("body").length||n.appendTo("parent"===i.appendTo?this.element[0].parentNode:i.appendTo),s&&n[0]===this.element[0]&&this._setPositionRelative(),n[0]===this.element[0]||/(fixed|absolute)/.test(n.css("position"))||n.css("position","absolute"),n},_setPositionRelative:function(){/^(?:r|a|f)/.test(this.element.css("position"))||(this.element[0].style.position="relative")},_adjustOffsetFromHelper:function(e){"string"==typeof e&&(e=e.split(" ")),t.isArray(e)&&(e={left:+e[0],top:+e[1]||0}),"left"in e&&(this.offset.click.left=e.left+this.margins.left),"right"in e&&(this.offset.click.left=this.helperProportions.width-e.right+this.margins.left),"top"in e&&(this.offset.click.top=e.top+this.margins.top),"bottom"in e&&(this.offset.click.top=this.helperProportions.height-e.bottom+this.margins.top)},_isRootNode:function(t){return/(html|body)/i.test(t.tagName)||t===this.document[0]},_getParentOffset:function(){var e=this.offsetParent.offset(),i=this.document[0];return"absolute"===this.cssPosition&&this.scrollParent[0]!==i&&t.contains(this.scrollParent[0],this.offsetParent[0])&&(e.left+=this.scrollParent.scrollLeft(),e.top+=this.scrollParent.scrollTop()),this._isRootNode(this.offsetParent[0])&&(e={top:0,left:0}),{top:e.top+(parseInt(this.offsetParent.css("borderTopWidth"),10)||0),left:e.left+(parseInt(this.offsetParent.css("borderLeftWidth"),10)||0)}},_getRelativeOffset:function(){if("relative"!==this.cssPosition)return{top:0,left:0};var t=this.element.position(),e=this._isRootNode(this.scrollParent[0]);return{top:t.top-(parseInt(this.helper.css("top"),10)||0)+(e?0:this.scrollParent.scrollTop()),left:t.left-(parseInt(this.helper.css("left"),10)||0)+(e?0:this.scrollParent.scrollLeft())}
vendor: 2,000 bytes, line 18
18 },_cacheMargins:function(){this.margins={left:parseInt(this.element.css("marginLeft"),10)||0,top:parseInt(this.element.css("marginTop"),10)||0,right:parseInt(this.element.css("marginRight"),10)||0,bottom:parseInt(this.element.css("marginBottom"),10)||0}},_cacheHelperProportions:function(){this.helperProportions={width:this.helper.outerWidth(),height:this.helper.outerHeight()}},_setContainment:function(){var e,i,s,n=this.options,o=this.document[0];return this.relativeContainer=null,n.containment?"window"===n.containment?(this.containment=[t(window).scrollLeft()-this.offset.relative.left-this.offset.parent.left,t(window).scrollTop()-this.offset.relative.top-this.offset.parent.top,t(window).scrollLeft()+t(window).width()-this.helperProportions.width-this.margins.left,t(window).scrollTop()+(t(window).height()||o.body.parentNode.scrollHeight)-this.helperProportions.height-this.margins.top],void 0):"document"===n.containment?(this.containment=[0,0,t(o).width()-this.helperProportions.width-this.margins.left,(t(o).height()||o.body.parentNode.scrollHeight)-this.helperProportions.height-this.margins.top],void 0):n.containment.constructor===Array?(this.containment=n.containment,void 0):("parent"===n.containment&&(n.containment=this.helper[0].parentNode),i=t(n.containment),s=i[0],s&&(e=/(scroll|auto)/.test(i.css("overflow")),this.containment=[(parseInt(i.css("borderLeftWidth"),10)||0)+(parseInt(i.css("paddingLeft"),10)||0),(parseInt(i.css("borderTopWidth"),10)||0)+(parseInt(i.css("paddingTop"),10)||0),(e?Math.max(s.scrollWidth,s.offsetWidth):s.offsetWidth)-(parseInt(i.css("borderRightWidth"),10)||0)-(parseInt(i.css("paddingRight"),10)||0)-this.helperProportions.width-this.margins.left-this.margins.right,(e?Math.max(s.scrollHeight,s.offsetHeight):s.offsetHeight)-(parseInt(i.css("borderBottomWidth"),10)||0)-(parseInt(i.css("paddingBottom"),10)||0)-this.helperProportions.height-this.margins.top-this.margins.bottom],this.relativeContainer=i),void 0):(this.containment=null,void 0)
vendor: 5,462 bytes, line 18
18},_convertPositionTo:function(t,e){e||(e=this.position);var i="absolute"===t?1:-1,s=this._isRootNode(this.scrollParent[0]);return{top:e.top+this.offset.relative.top*i+this.offset.parent.top*i-("fixed"===this.cssPosition?-this.offset.scroll.top:s?0:this.offset.scroll.top)*i,left:e.left+this.offset.relative.left*i+this.offset.parent.left*i-("fixed"===this.cssPosition?-this.offset.scroll.left:s?0:this.offset.scroll.left)*i}},_generatePosition:function(t,e){var i,s,n,o,a=this.options,r=this._isRootNode(this.scrollParent[0]),h=t.pageX,l=t.pageY;return r&&this.offset.scroll||(this.offset.scroll={top:this.scrollParent.scrollTop(),left:this.scrollParent.scrollLeft()}),e&&(this.containment&&(this.relativeContainer?(s=this.relativeContainer.offset(),i=[this.containment[0]+s.left,this.containment[1]+s.top,this.containment[2]+s.left,this.containment[3]+s.top]):i=this.containment,t.pageX-this.offset.click.left<i[0]&&(h=i[0]+this.offset.click.left),t.pageY-this.offset.click.top<i[1]&&(l=i[1]+this.offset.click.top),t.pageX-this.offset.click.left>i[2]&&(h=i[2]+this.offset.click.left),t.pageY-this.offset.click.top>i[3]&&(l=i[3]+this.offset.click.top)),a.grid&&(n=a.grid[1]?this.originalPageY+Math.round((l-this.originalPageY)/a.grid[1])*a.grid[1]:this.originalPageY,l=i?n-this.offset.click.top>=i[1]||n-this.offset.click.top>i[3]?n:n-this.offset.click.top>=i[1]?n-a.grid[1]:n+a.grid[1]:n,o=a.grid[0]?this.originalPageX+Math.round((h-this.originalPageX)/a.grid[0])*a.grid[0]:this.originalPageX,h=i?o-this.offset.click.left>=i[0]||o-this.offset.click.left>i[2]?o:o-this.offset.click.left>=i[0]?o-a.grid[0]:o+a.grid[0]:o),"y"===a.axis&&(h=this.originalPageX),"x"===a.axis&&(l=this.originalPageY)),{top:l-this.offset.click.top-this.offset.relative.top-this.offset.parent.top+("fixed"===this.cssPosition?-this.offset.scroll.top:r?0:this.offset.scroll.top),left:h-this.offset.click.left-this.offset.relative.left-this.offset.parent.left+("fixed"===this.cssPosition?-this.offset.scroll.left:r?0:this.offset.scroll.left)}},_clear:function(){this._removeClass(this.helper,"ui-draggable-dragging"),this.helper[0]===this.element[0]||this.cancelHelperRemoval||this.helper.remove(),this.helper=null,this.cancelHelperRemoval=!1,this.destroyOnClear&&this.destroy()},_trigger:function(e,i,s){return s=s||this._uiHash(),t.ui.plugin.call(this,e,[i,s,this],!0),/^(drag|start|stop)/.test(e)&&(this.positionAbs=this._convertPositionTo("absolute"),s.offset=this.positionAbs),t.Widget.prototype._trigger.call(this,e,i,s)},plugins:{},_uiHash:function(){return{helper:this.helper,position:this.position,originalPosition:this.originalPosition,offset:this.positionAbs}}}),t.ui.plugin.add("draggable","connectToSortable",{start:function(e,i,s){var n=t.extend({},i,{item:s.element});s.sortables=[],t(s.options.connectToSortable).each(function(){var i=t(this).sortable("instance");i&&!i.options.disabled&&(s.sortables.push(i),i.refreshPositions(),i._trigger("activate",e,n))})},stop:function(e,i,s){var n=t.extend({},i,{item:s.element});s.cancelHelperRemoval=!1,t.each(s.sortables,function(){var t=this;t.isOver?(t.isOver=0,s.cancelHelperRemoval=!0,t.cancelHelperRemoval=!1,t._storedCSS={position:t.placeholder.css("position"),top:t.placeholder.css("top"),left:t.placeholder.css("left")},t._mouseStop(e),t.options.helper=t.options._helper):(t.cancelHelperRemoval=!0,t._trigger("deactivate",e,n))})},drag:function(e,i,s){t.each(s.sortables,function(){var n=!1,o=this;o.positionAbs=s.positionAbs,o.helperProportions=s.helperProportions,o.offset.click=s.offset.click,o._intersectsWith(o.containerCache)&&(n=!0,t.each(s.sortables,function(){return this.positionAbs=s.positionAbs,this.helperProportions=s.helperProportions,this.offset.click=s.offset.click,this!==o&&this._intersectsWith(this.containerCache)&&t.contains(o.element[0],this.element[0])&&(n=!1),n})),n?(o.isOver||(o.isOver=1,s._parent=i.helper.parent(),o.currentItem=i.helper.appendTo(o.element).data("ui-sortable-item",!0),o.options._helper=o.options.helper,o.options.helper=function(){return i.helper[0]},e.target=o.currentItem[0],o._mouseCapture(e,!0),o._mouseStart(e,!0,!0),o.offset.click.top=s.offset.click.top,o.offset.click.left=s.offset.click.left,o.offset.parent.left-=s.offset.parent.left-o.offset.parent.left,o.offset.parent.top-=s.offset.parent.top-o.offset.parent.top,s._trigger("toSortable",e),s.dropped=o.element,t.each(s.sortables,function(){this.refreshPositions()}),s.currentItem=s.element,o.fromOutside=s),o.currentItem&&(o._mouseDrag(e),i.position=o.position)):o.isOver&&(o.isOver=0,o.cancelHelperRemoval=!0,o.options._revert=o.options.revert,o.options.revert=!1,o._trigger("out",e,o._uiHash(o)),o._mouseStop(e,!0),o.options.revert=o.options._revert,o.options.helper=o.options._helper,o.placeholder&&o.placeholder.remove(),i.helper.appendTo(s._parent),s._refreshOffsets(e),i.position=s._generatePosition(e,!0),s._trigger("fromSortable",e),s.dropped=!1,t.each(s.sortables,function(){this.refreshPositions()}))})}}),t.ui.plugin.add("draggable","cursor",{start:function(e,i,s){var n=t("body"),o=s.options;n.css("cursor")&&(o._cursor=n.css("cursor")),n.css("cursor",o.cursor)},stop:function(e,i,s){var n=s.options;n._cursor&&t("body").css("cursor",n._cursor)}}),t.ui.plugin.add("draggable","opacity",{start:function(e,i,s){var n=t(i.helper),o=s.options;n.css("opacity")&&(o._opacity=n.css("opacity")),n.css("opacity",o.opacity)},stop:function(e,i,s){var n=s.options;n._opacity&&t(i.helper).css("opacity",n._opacity)}}
vendor: 8,104 bytes, line 18
18),t.ui.plugin.add("draggable","scroll",{start:function(t,e,i){i.scrollParentNotHidden||(i.scrollParentNotHidden=i.helper.scrollParent(!1)),i.scrollParentNotHidden[0]!==i.document[0]&&"HTML"!==i.scrollParentNotHidden[0].tagName&&(i.overflowOffset=i.scrollParentNotHidden.offset())},drag:function(e,i,s){var n=s.options,o=!1,a=s.scrollParentNotHidden[0],r=s.document[0];a!==r&&"HTML"!==a.tagName?(n.axis&&"x"===n.axis||(s.overflowOffset.top+a.offsetHeight-e.pageY<n.scrollSensitivity?a.scrollTop=o=a.scrollTop+n.scrollSpeed:e.pageY-s.overflowOffset.top<n.scrollSensitivity&&(a.scrollTop=o=a.scrollTop-n.scrollSpeed)),n.axis&&"y"===n.axis||(s.overflowOffset.left+a.offsetWidth-e.pageX<n.scrollSensitivity?a.scrollLeft=o=a.scrollLeft+n.scrollSpeed:e.pageX-s.overflowOffset.left<n.scrollSensitivity&&(a.scrollLeft=o=a.scrollLeft-n.scrollSpeed))):(n.axis&&"x"===n.axis||(e.pageY-t(r).scrollTop()<n.scrollSensitivity?o=t(r).scrollTop(t(r).scrollTop()-n.scrollSpeed):t(window).height()-(e.pageY-t(r).scrollTop())<n.scrollSensitivity&&(o=t(r).scrollTop(t(r).scrollTop()+n.scrollSpeed))),n.axis&&"y"===n.axis||(e.pageX-t(r).scrollLeft()<n.scrollSensitivity?o=t(r).scrollLeft(t(r).scrollLeft()-n.scrollSpeed):t(window).width()-(e.pageX-t(r).scrollLeft())<n.scrollSensitivity&&(o=t(r).scrollLeft(t(r).scrollLeft()+n.scrollSpeed)))),o!==!1&&t.ui.ddmanager&&!n.dropBehaviour&&t.ui.ddmanager.prepareOffsets(s,e)}}),t.ui.plugin.add("draggable","snap",{start:function(e,i,s){var n=s.options;s.snapElements=[],t(n.snap.constructor!==String?n.snap.items||":data(ui-draggable)":n.snap).each(function(){var e=t(this),i=e.offset();this!==s.element[0]&&s.snapElements.push({item:this,width:e.outerWidth(),height:e.outerHeight(),top:i.top,left:i.left})})},drag:function(e,i,s){var n,o,a,r,h,l,c,u,d,p,f=s.options,g=f.snapTolerance,m=i.offset.left,_=m+s.helperProportions.width,v=i.offset.top,b=v+s.helperProportions.height;for(d=s.snapElements.length-1;d>=0;d--)h=s.snapElements[d].left-s.margins.left,l=h+s.snapElements[d].width,c=s.snapElements[d].top-s.margins.top,u=c+s.snapElements[d].height,h-g>_||m>l+g||c-g>b||v>u+g||!t.contains(s.snapElements[d].item.ownerDocument,s.snapElements[d].item)?(s.snapElements[d].snapping&&s.options.snap.release&&s.options.snap.release.call(s.element,e,t.extend(s._uiHash(),{snapItem:s.snapElements[d].item})),s.snapElements[d].snapping=!1):("inner"!==f.snapMode&&(n=g>=Math.abs(c-b),o=g>=Math.abs(u-v),a=g>=Math.abs(h-_),r=g>=Math.abs(l-m),n&&(i.position.top=s._convertPositionTo("relative",{top:c-s.helperProportions.height,left:0}).top),o&&(i.position.top=s._convertPositionTo("relative",{top:u,left:0}).top),a&&(i.position.left=s._convertPositionTo("relative",{top:0,left:h-s.helperProportions.width}).left),r&&(i.position.left=s._convertPositionTo("relative",{top:0,left:l}).left)),p=n||o||a||r,"outer"!==f.snapMode&&(n=g>=Math.abs(c-v),o=g>=Math.abs(u-b),a=g>=Math.abs(h-m),r=g>=Math.abs(l-_),n&&(i.position.top=s._convertPositionTo("relative",{top:c,left:0}).top),o&&(i.position.top=s._convertPositionTo("relative",{top:u-s.helperProportions.height,left:0}).top),a&&(i.position.left=s._convertPositionTo("relative",{top:0,left:h}).left),r&&(i.position.left=s._convertPositionTo("relative",{top:0,left:l-s.helperProportions.width}).left)),!s.snapElements[d].snapping&&(n||o||a||r||p)&&s.options.snap.snap&&s.options.snap.snap.call(s.element,e,t.extend(s._uiHash(),{snapItem:s.snapElements[d].item})),s.snapElements[d].snapping=n||o||a||r||p)}}),t.ui.plugin.add("draggable","stack",{start:function(e,i,s){var n,o=s.options,a=t.makeArray(t(o.stack)).sort(function(e,i){return(parseInt(t(e).css("zIndex"),10)||0)-(parseInt(t(i).css("zIndex"),10)||0)});a.length&&(n=parseInt(t(a[0]).css("zIndex"),10)||0,t(a).each(function(e){t(this).css("zIndex",n+e)}),this.css("zIndex",n+a.length))}}),t.ui.plugin.add("draggable","zIndex",{start:function(e,i,s){var n=t(i.helper),o=s.options;n.css("zIndex")&&(o._zIndex=n.css("zIndex")),n.css("zIndex",o.zIndex)},stop:function(e,i,s){var n=s.options;n._zIndex&&t(i.helper).css("zIndex",n._zIndex)}}),t.ui.draggable,t.widget("ui.resizable",t.ui.mouse,{version:"1.12.1",widgetEventPrefix:"resize",options:{alsoResize:!1,animate:!1,animateDuration:"slow",animateEasing:"swing",aspectRatio:!1,autoHide:!1,classes:{"ui-resizable-se":"ui-icon ui-icon-gripsmall-diagonal-se"},containment:!1,ghost:!1,grid:!1,handles:"e,s,se",helper:!1,maxHeight:null,maxWidth:null,minHeight:10,minWidth:10,zIndex:90,resize:null,start:null,stop:null},_num:function(t){return parseFloat(t)||0},_isNumber:function(t){return!isNaN(parseFloat(t))},_hasScroll:function(e,i){if("hidden"===t(e).css("overflow"))return!1;var s=i&&"left"===i?"scrollLeft":"scrollTop",n=!1;return e[s]>0?!0:(e[s]=1,n=e[s]>0,e[s]=0,n)},_create:function(){var e,i=this.options,s=this;this._addClass("ui-resizable"),t.extend(this,{_aspectRatio:!!i.aspectRatio,aspectRatio:i.aspectRatio,originalElement:this.element,_proportionallyResizeElements:[],_helper:i.helper||i.ghost||i.animate?i.helper||"ui-resizable-helper":null}),this.element[0].nodeName.match(/^(canvas|textarea|input|select|button|img)$/i)&&(this.element.wrap(t("<div class='ui-wrapper' style='overflow: hidden;'></div>").css({position:this.element.css("position"),width:this.element.outerWidth(),height:this.element.outerHeight(),top:this.element.css("top"),left:this.element.css("left")})),this.element=this.element.parent().data("ui-resizable",this.element.resizable("instance")),this.elementIsWrapper=!0,e={marginTop:this.originalElement.css("marginTop"),marginRight:this.originalElement.css("marginRight"),marginBottom:this.originalElement.css("marginBottom"),marginLeft:this.originalElement.css("marginLeft")},this.element.css(e),this.originalElement.css("margin",0),this.originalResizeStyle=this.originalElement.css("resize"),this.originalElement.css("resize","none"),this._proportionallyResizeElements.push(this.originalElement.css({position:"static",zoom:1,display:"block"})),this.originalElement.css(e),this._proportionallyResize()),this._setupHandles(),i.autoHide&&t(this.element).on("mouseenter",function(){i.disabled||(s._removeClass("ui-resizable-autohide"),s._handles.show())}).on("mouseleave",function(){i.disabled||s.resizing||(s._addClass("ui-resizable-autohide"),s._handles.hide())}),this._mouseInit()},_destroy:function(){this._mouseDestroy();var e,i=function(e){t(e).removeData("resizable").removeData("ui-resizable").off(".resizable").find(".ui-resizable-handle").remove()};return this.elementIsWrapper&&(i(this.element),e=this.element,this.originalElement.css({position:e.css("position"),width:e.outerWidth(),height:e.outerHeight(),top:e.css("top"),left:e.css("left")}).insertAfter(e),e.remove()),this.originalElement.css("resize",this.originalResizeStyle),i(this.originalElement),this},_setOption:function(t,e){switch(this._super(t,e),t){case"handles":this._removeHandles(),this._setupHandles();break;default:}},_setupHandles:function(){var e,i,s,n,o,a=this.options,r=this;if(this.handles=a.handles||(t(".ui-resizable-handle",this.element).length?{n:".ui-resizable-n",e:".ui-resizable-e",s:".ui-resizable-s",w:".ui-resizable-w",se:".ui-resizable-se",sw:".ui-resizable-sw",ne:".ui-resizable-ne",nw:".ui-resizable-nw"}:"e,s,se"),this._handles=t(),this.handles.constructor===String)for("all"===this.handles&&(this.handles="n,e,s,w,se,sw,ne,nw"),s=this.handles.split(","),this.handles={},i=0;s.length>i;i++)e=t.trim(s[i]),n="ui-resizable-"+e,o=t("<div>"),this._addClass(o,"ui-resizable-handle "+n),o.css({zIndex:a.zIndex}),this.handles[e]=".ui-resizable-"+e,this.element.append(o);this._renderAxis=function(e){var i,s,n,o;e=e||this.element;for(i in this.handles)this.handles[i].constructor===String?this.handles[i]=this.element.children(this.handles[i]).first().show():(this.handles[i].jquery||this.handles[i].nodeType)&&(this.handles[i]=t(this.handles[i]),this._on(this.handles[i],{mousedown:r._mouseDown})),this.elementIsWrapper&&this.originalElement[0].nodeName.match(/^(textarea|input|select|button)$/i)&&(s=t(this.handles[i],this.element),o=/sw|ne|nw|se|n|s/.test(i)?s.outerHeight():s.outerWidth(),n=["padding",/ne|nw|n
vendor: 12,214 bytes, line 18
18/.test(i)?"Top":/se|sw|s/.test(i)?"Bottom":/^e$/.test(i)?"Right":"Left"].join(""),e.css(n,o),this._proportionallyResize()),this._handles=this._handles.add(this.handles[i])},this._renderAxis(this.element),this._handles=this._handles.add(this.element.find(".ui-resizable-handle")),this._handles.disableSelection(),this._handles.on("mouseover",function(){r.resizing||(this.className&&(o=this.className.match(/ui-resizable-(se|sw|ne|nw|n|e|s|w)/i)),r.axis=o&&o[1]?o[1]:"se")}),a.autoHide&&(this._handles.hide(),this._addClass("ui-resizable-autohide"))},_removeHandles:function(){this._handles.remove()},_mouseCapture:function(e){var i,s,n=!1;for(i in this.handles)s=t(this.handles[i])[0],(s===e.target||t.contains(s,e.target))&&(n=!0);return!this.options.disabled&&n},_mouseStart:function(e){var i,s,n,o=this.options,a=this.element;return this.resizing=!0,this._renderProxy(),i=this._num(this.helper.css("left")),s=this._num(this.helper.css("top")),o.containment&&(i+=t(o.containment).scrollLeft()||0,s+=t(o.containment).scrollTop()||0),this.offset=this.helper.offset(),this.position={left:i,top:s},this.size=this._helper?{width:this.helper.width(),height:this.helper.height()}:{width:a.width(),height:a.height()},this.originalSize=this._helper?{width:a.outerWidth(),height:a.outerHeight()}:{width:a.width(),height:a.height()},this.sizeDiff={width:a.outerWidth()-a.width(),height:a.outerHeight()-a.height()},this.originalPosition={left:i,top:s},this.originalMousePosition={left:e.pageX,top:e.pageY},this.aspectRatio="number"==typeof o.aspectRatio?o.aspectRatio:this.originalSize.width/this.originalSize.height||1,n=t(".ui-resizable-"+this.axis).css("cursor"),t("body").css("cursor","auto"===n?this.axis+"-resize":n),this._addClass("ui-resizable-resizing"),this._propagate("start",e),!0},_mouseDrag:function(e){var i,s,n=this.originalMousePosition,o=this.axis,a=e.pageX-n.left||0,r=e.pageY-n.top||0,h=this._change[o];return this._updatePrevProperties(),h?(i=h.apply(this,[e,a,r]),this._updateVirtualBoundaries(e.shiftKey),(this._aspectRatio||e.shiftKey)&&(i=this._updateRatio(i,e)),i=this._respectSize(i,e),this._updateCache(i),this._propagate("resize",e),s=this._applyChanges(),!this._helper&&this._proportionallyResizeElements.length&&this._proportionallyResize(),t.isEmptyObject(s)||(this._updatePrevProperties(),this._trigger("resize",e,this.ui()),this._applyChanges()),!1):!1},_mouseStop:function(e){this.resizing=!1;var i,s,n,o,a,r,h,l=this.options,c=this;return this._helper&&(i=this._proportionallyResizeElements,s=i.length&&/textarea/i.test(i[0].nodeName),n=s&&this._hasScroll(i[0],"left")?0:c.sizeDiff.height,o=s?0:c.sizeDiff.width,a={width:c.helper.width()-o,height:c.helper.height()-n},r=parseFloat(c.element.css("left"))+(c.position.left-c.originalPosition.left)||null,h=parseFloat(c.element.css("top"))+(c.position.top-c.originalPosition.top)||null,l.animate||this.element.css(t.extend(a,{top:h,left:r})),c.helper.height(c.size.height),c.helper.width(c.size.width),this._helper&&!l.animate&&this._proportionallyResize()),t("body").css("cursor","auto"),this._removeClass("ui-resizable-resizing"),this._propagate("stop",e),this._helper&&this.helper.remove(),!1},_updatePrevProperties:function(){this.prevPosition={top:this.position.top,left:this.position.left},this.prevSize={width:this.size.width,height:this.size.height}},_applyChanges:function(){var t={};return this.position.top!==this.prevPosition.top&&(t.top=this.position.top+"px"),this.position.left!==this.prevPosition.left&&(t.left=this.position.left+"px"),this.size.width!==this.prevSize.width&&(t.width=this.size.width+"px"),this.size.height!==this.prevSize.height&&(t.height=this.size.height+"px"),this.helper.css(t),t},_updateVirtualBoundaries:function(t){var e,i,s,n,o,a=this.options;o={minWidth:this._isNumber(a.minWidth)?a.minWidth:0,maxWidth:this._isNumber(a.maxWidth)?a.maxWidth:1/0,minHeight:this._isNumber(a.minHeight)?a.minHeight:0,maxHeight:this._isNumber(a.maxHeight)?a.maxHeight:1/0},(this._aspectRatio||t)&&(e=o.minHeight*this.aspectRatio,s=o.minWidth/this.aspectRatio,i=o.maxHeight*this.aspectRatio,n=o.maxWidth/this.aspectRatio,e>o.minWidth&&(o.minWidth=e),s>o.minHeight&&(o.minHeight=s),o.maxWidth>i&&(o.maxWidth=i),o.maxHeight>n&&(o.maxHeight=n)),this._vBoundaries=o},_updateCache:function(t){this.offset=this.helper.offset(),this._isNumber(t.left)&&(this.position.left=t.left),this._isNumber(t.top)&&(this.position.top=t.top),this._isNumber(t.height)&&(this.size.height=t.height),this._isNumber(t.width)&&(this.size.width=t.width)},_updateRatio:function(t){var e=this.position,i=this.size,s=this.axis;return this._isNumber(t.height)?t.width=t.height*this.aspectRatio:this._isNumber(t.width)&&(t.height=t.width/this.aspectRatio),"sw"===s&&(t.left=e.left+(i.width-t.width),t.top=null),"nw"===s&&(t.top=e.top+(i.height-t.height),t.left=e.left+(i.width-t.width)),t},_respectSize:function(t){var e=this._vBoundaries,i=this.axis,s=this._isNumber(t.width)&&e.maxWidth&&e.maxWidth<t.width,n=this._isNumber(t.height)&&e.maxHeight&&e.maxHeight<t.height,o=this._isNumber(t.width)&&e.minWidth&&e.minWidth>t.width,a=this._isNumber(t.height)&&e.minHeight&&e.minHeight>t.height,r=this.originalPosition.left+this.originalSize.width,h=this.originalPosition.top+this.originalSize.height,l=/sw|nw|w/.test(i),c=/nw|ne|n/.test(i);return o&&(t.width=e.minWidth),a&&(t.height=e.minHeight),s&&(t.width=e.maxWidth),n&&(t.height=e.maxHeight),o&&l&&(t.left=r-e.minWidth),s&&l&&(t.left=r-e.maxWidth),a&&c&&(t.top=h-e.minHeight),n&&c&&(t.top=h-e.maxHeight),t.width||t.height||t.left||!t.top?t.width||t.height||t.top||!t.left||(t.left=null):t.top=null,t},_getPaddingPlusBorderDimensions:function(t){for(var e=0,i=[],s=[t.css("borderTopWidth"),t.css("borderRightWidth"),t.css("borderBottomWidth"),t.css("borderLeftWidth")],n=[t.css("paddingTop"),t.css("paddingRight"),t.css("paddingBottom"),t.css("paddingLeft")];4>e;e++)i[e]=parseFloat(s[e])||0,i[e]+=parseFloat(n[e])||0;return{height:i[0]+i[2],width:i[1]+i[3]}},_proportionallyResize:function(){if(this._proportionallyResizeElements.length)for(var t,e=0,i=this.helper||this.element;this._proportionallyResizeElements.length>e;e++)t=this._proportionallyResizeElements[e],this.outerDimensions||(this.outerDimensions=this._getPaddingPlusBorderDimensions(t)),t.css({height:i.height()-this.outerDimensions.height||0,width:i.width()-this.outerDimensions.width||0})},_renderProxy:function(){var e=this.element,i=this.options;this.elementOffset=e.offset(),this._helper?(this.helper=this.helper||t("<div style='overflow:hidden;'></div>"),this._addClass(this.helper,this._helper),this.helper.css({width:this.element.outerWidth(),height:this.element.outerHeight(),position:"absolute",left:this.elementOffset.left+"px",top:this.elementOffset.top+"px",zIndex:++i.zIndex}),this.helper.appendTo("body").disableSelection()):this.helper=this.element},_change:{e:function(t,e){return{width:this.originalSize.width+e}},w:function(t,e){var i=this.originalSize,s=this.originalPosition;return{left:s.left+e,width:i.width-e}},n:function(t,e,i){var s=this.originalSize,n=this.originalPosition;return{top:n.top+i,height:s.height-i}},s:function(t,e,i){return{height:this.originalSize.height+i}},se:function(e,i,s){return t.extend(this._change.s.apply(this,arguments),this._change.e.apply(this,[e,i,s]))},sw:function(e,i,s){return t.extend(this._change.s.apply(this,arguments),this._change.w.apply(this,[e,i,s]))},ne:function(e,i,s){return t.extend(this._change.n.apply(this,arguments),this._change.e.apply(this,[e,i,s]))},nw:function(e,i,s){return t.extend(this._change.n.apply(this,arguments),this._change.w.apply(this,[e,i,s]))}},_propagate:function(e,i){t.ui.plugin.call(this,e,[i,this.ui()]),"resize"!==e&&this._trigger(e,i,this.ui())},plugins:{},ui:function(){return{originalElement:this.originalElement,element:this.element,helper:this.helper,position:this.position,size:this.size,originalSize:this.originalSize,originalPosition:this.originalPosition}}}),t.ui.plugin.add("resizable","animate",{stop:function(e){var i=t(this).resizable("instance"),s=i.options,n=i._proportionallyResizeElements,o=n.length&&/textarea/i.test(n[0].nodeName),a=o&&i._hasScroll(n[0],"left")?0:i.sizeDiff.height,r=o?0:i.sizeDiff.width,h={width:i.size.width-r,height:i.size.height-a},l=parseFloat(i.element.css("left"))+(i.position.left-i.originalPosition.left)||null,c=parseFloat(i.element.css("top"))+(i.position.top-i.originalPosition.top)||null;i.element.animate(t.extend(h,c&&l?{top:c,left:l}:{}),{duration:s.animateDuration,easing:s.animateEasing,step:function(){var s={width:parseFloat(i.element.css("width")),height:parseFloat(i.element.css("height")),top:parseFloat(i.element.css("top")),left:parseFloat(i.element.css("left"))};n&&n.length&&t(n[0]).css({width:s.width,height:s.height}),i._updateCache(s),i._propagate("resize",e)}})}}),t.ui.plugin.add("resizable","containment",{start:function(){var e,i,s,n,o,a,r,h=t(this).resizable("instance"),l=h.options,c=h.element,u=l.containment,d=u instanceof t?u.get(0):/parent/.test(u)?c.parent().get(0):u;d&&(h.containerElement=t(d),/document/.test(u)||u===document?(h.containerOffset={left:0,top:0},h.containerPosition={left:0,top:0},h.parentData={element:t(document),left:0,top:0,width:t(document).width(),height:t(document).height()||document.body.parentNode.scrollHeight}):(e=t(d),i=[],t(["Top","Right","Left","Bottom"]).each(function(t,s){i[t]=h._num(e.css("padding"+s))}),h.containerOffset=e.offset(),h.containerPosition=e.position(),h.containerSize={height:e.innerHeight()-i[3],width:e.innerWidth()-i[1]},s=h.containerOffset,n=h.containerSize.height,o=h.containerSize.width,a=h._hasScroll(d,"left")?d.scrollWidth:o,r=h._hasScroll(d)?d.scrollHeight:n,h.parentData={element:d,left:s.left,top:s.top,width:a,height:r}))},resize:function(e){var i,s,n,o,a=t(this).resizable("instance"),r=a.options,h=a.containerOffset,l=a.position,c=a._aspectRatio||e.shiftKey,u={top:0,left:0},d=a.containerElement,p=!0;d[0]!==document&&/static/.test(d.css("position"))&&(u=h),l.left<(a._helper?h.left:0)&&(a.size.width=a.size.width+(a._helper?a.position.left-h.left:a.position.left-u.left),c&&(a.size.height=a.size.width/a.aspectRatio,p=!1),a.position.left=r.helper?h.left:0),l.top<(a._helper?h.top:0)&&(a.size.height=a.size.height+(a._helper?a.position.top-h.top:a.position.top),c&&(a.size.width=a.size.height*a.aspectRatio,p=!1),a.position.top=a._helper?h.top:0),n=a.containerElement.get(0)===a.element.parent().get(0),o=/relative|absolute/.test(a.containerElement.css("position")),n&&o?(a.offset.left=a.parentData.left+a.position.left,a.offset.top=a.parentData.top+a.position.top):(a.offset.left=a.element.offset().left,a.offset.top=a.element.offset().top),i=Math.abs(a.sizeDiff.width+(a._helper?a.offset.left-u.left:a.offset.left-h.left)),s=Math.abs(a.sizeDiff.height+(a._helper?a.offset.top-u.top:a.offset.top-h.top)),i+a.size.width>=a.parentData.width&&(a.size.width=a.parentData.width-i,c&&(a.size.height=a.size.width/a.aspectRatio,p=!1)),s+a.size.height>=a.parentData.height&&(a.size.height=a.parentData.height-s,c&&(a.size.width=a.size.height*a.aspectRatio,p=!1)),p||(a.position.left=a.prevPosition.left,a.position.top=a.prevPosition.top,a.size.width=a.prevSize.width,a.size.height=a.prevSize.height)},stop:function(){var e=t(this).resizable("instance"),i=e.options,s=e.containerOffset,n=e.containerPosition,o=e.containerElement,a=t(e.helper),r=a.offset(),h=a.outerWidth()-e.sizeDiff.width,l=a.outerHeight()-e.sizeDiff.height;e._helper&&!i.animate&&/relative/.test(o.css("position"))&&t(this).css({left:r.left-n.left-s.left,width:h,height:l}),e._helper&&!i.animate&&/static/.test(o.css("position"))&&t(this).css({left:r.left-n.left-s.left,width:h,height:l})}}),t.ui.plugin.add("resizable","alsoResize",{start:function(){var e=t(this).resizable("instance"),i=e.options;t(i.alsoResize).each(function(){var e=t(this);e.data("ui-resizable-alsoresize",{width:parseFloat(e.width()),height:parseFloat(e.height()),left:parseFloat(e.css("left")),top:parseFloat(e.css("top"))})})},resize:function(e,i){var s=t(this).resizable("instance"),n=s.options,o=s.originalSize,a=s.originalPosition,r={height:s.size.height-o.height||0,width:s.size.width-o.width||0,top:s.position.top-a.top||0,left:s.position.left-a.left||0};
vendor: 4,263 bytes, lines 18-19
18t(n.alsoResize).each(function(){var e=t(this),s=t(this).data("ui-resizable-alsoresize"),n={},o=e.parents(i.originalElement[0]).length?["width","height"]:["width","height","top","left"];t.each(o,function(t,e){var i=(s[e]||0)+(r[e]||0);i&&i>=0&&(n[e]=i||null)}),e.css(n)})},stop:function(){t(this).removeData("ui-resizable-alsoresize")}}),t.ui.plugin.add("resizable","ghost",{start:function(){var e=t(this).resizable("instance"),i=e.size;e.ghost=e.originalElement.clone(),e.ghost.css({opacity:.25,display:"block",position:"relative",height:i.height,width:i.width,margin:0,left:0,top:0}),e._addClass(e.ghost,"ui-resizable-ghost"),t.uiBackCompat!==!1&&"string"==typeof e.options.ghost&&e.ghost.addClass(this.options.ghost),e.ghost.appendTo(e.helper)},resize:function(){var e=t(this).resizable("instance");e.ghost&&e.ghost.css({position:"relative",height:e.size.height,width:e.size.width})},stop:function(){var e=t(this).resizable("instance");e.ghost&&e.helper&&e.helper.get(0).removeChild(e.ghost.get(0))}}),t.ui.plugin.add("resizable","grid",{resize:function(){var e,i=t(this).resizable("instance"),s=i.options,n=i.size,o=i.originalSize,a=i.originalPosition,r=i.axis,h="number"==typeof s.grid?[s.grid,s.grid]:s.grid,l=h[0]||1,c=h[1]||1,u=Math.round((n.width-o.width)/l)*l,d=Math.round((n.height-o.height)/c)*c,p=o.width+u,f=o.height+d,g=s.maxWidth&&p>s.maxWidth,m=s.maxHeight&&f>s.maxHeight,_=s.minWidth&&s.minWidth>p,v=s.minHeight&&s.minHeight>f;s.grid=h,_&&(p+=l),v&&(f+=c),g&&(p-=l),m&&(f-=c),/^(se|s|e)$/.test(r)?(i.size.width=p,i.size.height=f):/^(ne)$/.test(r)?(i.size.width=p,i.size.height=f,i.position.top=a.top-d):/^(sw)$/.test(r)?(i.size.width=p,i.size.height=f,i.position.left=a.left-u):((0>=f-c||0>=p-l)&&(e=i._getPaddingPlusBorderDimensions(this)),f-c>0?(i.size.height=f,i.position.top=a.top-d):(f=c-e.height,i.size.height=f,i.position.top=a.top+o.height-f),p-l>0?(i.size.width=p,i.position.left=a.left-u):(p=l-e.width,i.size.width=p,i.position.left=a.left+o.width-p))}}),t.ui.resizable,t.widget("ui.dialog",{version:"1.12.1",options:{appendTo:"body",autoOpen:!0,buttons:[],classes:{"ui-dialog":"ui-corner-all","ui-dialog-titlebar":"ui-corner-all"},closeOnEscape:!0,closeText:"Close",draggable:!0,hide:null,height:"auto",maxHeight:null,maxWidth:null,minHeight:150,minWidth:150,modal:!1,position:{my:"center",at:"center",of:window,collision:"fit",using:function(e){var i=t(this).css(e).offset().top;0>i&&t(this).css("top",e.top-i)}},resizable:!0,show:null,title:null,width:300,beforeClose:null,close:null,drag:null,dragStart:null,dragStop:null,focus:null,open:null,resize:null,resizeStart:null,resizeStop:null},sizeRelatedOptions:{buttons:!0,height:!0,maxHeight:!0,maxWidth:!0,minHeight:!0,minWidth:!0,width:!0},resizableRelatedOptions:{maxHeight:!0,maxWidth:!0,minHeight:!0,minWidth:!0},_create:function(){this.originalCss={display:this.element[0].style.display,width:this.element[0].style.width,minHeight:this.element[0].style.minHeight,maxHeight:this.element[0].style.maxHeight,height:this.element[0].style.height},this.originalPosition={parent:this.element.parent(),index:this.element.parent().children().index(this.element)},this.originalTitle=this.element.attr("title"),null==this.options.title&&null!=this.originalTitle&&(this.options.title=this.originalTitle),this.options.disabled&&(this.options.disabled=!1),this._createWrapper(),this.element.show().removeAttr("title").appendTo(this.uiDialog),this._addClass("ui-dialog-content","ui-widget-content"),this._createTitlebar(),this._createButtonPane(),this.options.draggable&&t.fn.draggable&&this._makeDraggable(),this.options.resizable&&t.fn.resizable&&this._makeResizable(),this._isOpen=!1,this._trackFocus()},_init:function(){this.options.autoOpen&&this.open()},_appendTo:function(){var e=this.options.appendTo;return e&&(e.jquery||e.nodeType)?t(e):this.document.find(e||"body").eq(0)},_destroy:function(){var t,e=this.originalPosition;this._untrackInstance(),this._destroyOverlay(),this.element.removeUniqueId().css(this.originalCss).detach(),this.uiDialog.remove(),this.originalTitle&&this.element.attr("title",this.originalTitle),t=e.parent.children().eq(e.index),t.length&&t[0]!==this.element[0]?t.before(this.element):e.parent.append(this.element)},widget:function(){return this.uiDialog 19
vendor: 23,254 bytes, line 19
19},disable:t.noop,enable:t.noop,close:function(e){var i=this;this._isOpen&&this._trigger("beforeClose",e)!==!1&&(this._isOpen=!1,this._focusedElement=null,this._destroyOverlay(),this._untrackInstance(),this.opener.filter(":focusable").trigger("focus").length||t.ui.safeBlur(t.ui.safeActiveElement(this.document[0])),this._hide(this.uiDialog,this.options.hide,function(){i._trigger("close",e)}))},isOpen:function(){return this._isOpen},moveToTop:function(){this._moveToTop()},_moveToTop:function(e,i){var s=!1,n=this.uiDialog.siblings(".ui-front:visible").map(function(){return+t(this).css("z-index")}).get(),o=Math.max.apply(null,n);return o>=+this.uiDialog.css("z-index")&&(this.uiDialog.css("z-index",o+1),s=!0),s&&!i&&this._trigger("focus",e),s},open:function(){var e=this;return this._isOpen?(this._moveToTop()&&this._focusTabbable(),void 0):(this._isOpen=!0,this.opener=t(t.ui.safeActiveElement(this.document[0])),this._size(),this._position(),this._createOverlay(),this._moveToTop(null,!0),this.overlay&&this.overlay.css("z-index",this.uiDialog.css("z-index")-1),this._show(this.uiDialog,this.options.show,function(){e._focusTabbable(),e._trigger("focus")}),this._makeFocusTarget(),this._trigger("open"),void 0)},_focusTabbable:function(){var t=this._focusedElement;t||(t=this.element.find("[autofocus]")),t.length||(t=this.element.find(":tabbable")),t.length||(t=this.uiDialogButtonPane.find(":tabbable")),t.length||(t=this.uiDialogTitlebarClose.filter(":tabbable")),t.length||(t=this.uiDialog),t.eq(0).trigger("focus")},_keepFocus:function(e){function i(){var e=t.ui.safeActiveElement(this.document[0]),i=this.uiDialog[0]===e||t.contains(this.uiDialog[0],e);i||this._focusTabbable()}e.preventDefault(),i.call(this),this._delay(i)},_createWrapper:function(){this.uiDialog=t("<div>").hide().attr({tabIndex:-1,role:"dialog"}).appendTo(this._appendTo()),this._addClass(this.uiDialog,"ui-dialog","ui-widget ui-widget-content ui-front"),this._on(this.uiDialog,{keydown:function(e){if(this.options.closeOnEscape&&!e.isDefaultPrevented()&&e.keyCode&&e.keyCode===t.ui.keyCode.ESCAPE)return e.preventDefault(),this.close(e),void 0;if(e.keyCode===t.ui.keyCode.TAB&&!e.isDefaultPrevented()){var i=this.uiDialog.find(":tabbable"),s=i.filter(":first"),n=i.filter(":last");e.target!==n[0]&&e.target!==this.uiDialog[0]||e.shiftKey?e.target!==s[0]&&e.target!==this.uiDialog[0]||!e.shiftKey||(this._delay(function(){n.trigger("focus")}),e.preventDefault()):(this._delay(function(){s.trigger("focus")}),e.preventDefault())}},mousedown:function(t){this._moveToTop(t)&&this._focusTabbable()}}),this.element.find("[aria-describedby]").length||this.uiDialog.attr({"aria-describedby":this.element.uniqueId().attr("id")})},_createTitlebar:function(){var e;this.uiDialogTitlebar=t("<div>"),this._addClass(this.uiDialogTitlebar,"ui-dialog-titlebar","ui-widget-header ui-helper-clearfix"),this._on(this.uiDialogTitlebar,{mousedown:function(e){t(e.target).closest(".ui-dialog-titlebar-close")||this.uiDialog.trigger("focus")}}),this.uiDialogTitlebarClose=t("<button type='button'></button>").button({label:t("<a>").text(this.options.closeText).html(),icon:"ui-icon-closethick",showLabel:!1}).appendTo(this.uiDialogTitlebar),this._addClass(this.uiDialogTitlebarClose,"ui-dialog-titlebar-close"),this._on(this.uiDialogTitlebarClose,{click:function(t){t.preventDefault(),this.close(t)}}),e=t("<span>").uniqueId().prependTo(this.uiDialogTitlebar),this._addClass(e,"ui-dialog-title"),this._title(e),this.uiDialogTitlebar.prependTo(this.uiDialog),this.uiDialog.attr({"aria-labelledby":e.attr("id")})},_title:function(t){this.options.title?t.text(this.options.title):t.html(" ")},_createButtonPane:function(){this.uiDialogButtonPane=t("<div>"),this._addClass(this.uiDialogButtonPane,"ui-dialog-buttonpane","ui-widget-content ui-helper-clearfix"),this.uiButtonSet=t("<div>").appendTo(this.uiDialogButtonPane),this._addClass(this.uiButtonSet,"ui-dialog-buttonset"),this._createButtons()},_createButtons:function(){var e=this,i=this.options.buttons;return this.uiDialogButtonPane.remove(),this.uiButtonSet.empty(),t.isEmptyObject(i)||t.isArray(i)&&!i.length?(this._removeClass(this.uiDialog,"ui-dialog-buttons"),void 0):(t.each(i,function(i,s){var n,o;s=t.isFunction(s)?{click:s,text:i}:s,s=t.extend({type:"button"},s),n=s.click,o={icon:s.icon,iconPosition:s.iconPosition,showLabel:s.showLabel,icons:s.icons,text:s.text},delete s.click,delete s.icon,delete s.iconPosition,delete s.showLabel,delete s.icons,"boolean"==typeof s.text&&delete s.text,t("<button></button>",s).button(o).appendTo(e.uiButtonSet).on("click",function(){n.apply(e.element[0],arguments)})}),this._addClass(this.uiDialog,"ui-dialog-buttons"),this.uiDialogButtonPane.appendTo(this.uiDialog),void 0)},_makeDraggable:function(){function e(t){return{position:t.position,offset:t.offset}}var i=this,s=this.options;this.uiDialog.draggable({cancel:".ui-dialog-content, .ui-dialog-titlebar-close",handle:".ui-dialog-titlebar",containment:"document",start:function(s,n){i._addClass(t(this),"ui-dialog-dragging"),i._blockFrames(),i._trigger("dragStart",s,e(n))},drag:function(t,s){i._trigger("drag",t,e(s))},stop:function(n,o){var a=o.offset.left-i.document.scrollLeft(),r=o.offset.top-i.document.scrollTop();s.position={my:"left top",at:"left"+(a>=0?"+":"")+a+" "+"top"+(r>=0?"+":"")+r,of:i.window},i._removeClass(t(this),"ui-dialog-dragging"),i._unblockFrames(),i._trigger("dragStop",n,e(o))}})},_makeResizable:function(){function e(t){return{originalPosition:t.originalPosition,originalSize:t.originalSize,position:t.position,size:t.size}}var i=this,s=this.options,n=s.resizable,o=this.uiDialog.css("position"),a="string"==typeof n?n:"n,e,s,w,se,sw,ne,nw";this.uiDialog.resizable({cancel:".ui-dialog-content",containment:"document",alsoResize:this.element,maxWidth:s.maxWidth,maxHeight:s.maxHeight,minWidth:s.minWidth,minHeight:this._minHeight(),handles:a,start:function(s,n){i._addClass(t(this),"ui-dialog-resizing"),i._blockFrames(),i._trigger("resizeStart",s,e(n))},resize:function(t,s){i._trigger("resize",t,e(s))},stop:function(n,o){var a=i.uiDialog.offset(),r=a.left-i.document.scrollLeft(),h=a.top-i.document.scrollTop();s.height=i.uiDialog.height(),s.width=i.uiDialog.width(),s.position={my:"left top",at:"left"+(r>=0?"+":"")+r+" "+"top"+(h>=0?"+":"")+h,of:i.window},i._removeClass(t(this),"ui-dialog-resizing"),i._unblockFrames(),i._trigger("resizeStop",n,e(o))}}).css("position",o)},_trackFocus:function(){this._on(this.widget(),{focusin:function(e){this._makeFocusTarget(),this._focusedElement=t(e.target)}})},_makeFocusTarget:function(){this._untrackInstance(),this._trackingInstances().unshift(this)},_untrackInstance:function(){var e=this._trackingInstances(),i=t.inArray(this,e);-1!==i&&e.splice(i,1)},_trackingInstances:function(){var t=this.document.data("ui-dialog-instances");return t||(t=[],this.document.data("ui-dialog-instances",t)),t},_minHeight:function(){var t=this.options;return"auto"===t.height?t.minHeight:Math.min(t.minHeight,t.height)},_position:function(){var t=this.uiDialog.is(":visible");t||this.uiDialog.show(),this.uiDialog.position(this.options.position),t||this.uiDialog.hide()},_setOptions:function(e){var i=this,s=!1,n={};t.each(e,function(t,e){i._setOption(t,e),t in i.sizeRelatedOptions&&(s=!0),t in i.resizableRelatedOptions&&(n[t]=e)}),s&&(this._size(),this._position()),this.uiDialog.is(":data(ui-resizable)")&&this.uiDialog.resizable("option",n)},_setOption:function(e,i){var s,n,o=this.uiDialog;"disabled"!==e&&(this._super(e,i),"appendTo"===e&&this.uiDialog.appendTo(this._appendTo()),"buttons"===e&&this._createButtons(),"closeText"===e&&this.uiDialogTitlebarClose.button({label:t("<a>").text(""+this.options.closeText).html()}),"draggable"===e&&(s=o.is(":data(ui-draggable)"),s&&!i&&o.draggable("destroy"),!s&&i&&this._makeDraggable()),"position"===e&&this._position(),"resizable"===e&&(n=o.is(":data(ui-resizable)"),n&&!i&&o.resizable("destroy"),n&&"string"==typeof i&&o.resizable("option","handles",i),n||i===!1||this._makeResizable()),"title"===e&&this._title(this.uiDialogTitlebar.find(".ui-dialog-title")))},_size:function(){var t,e,i,s=this.options;this.element.show().css({width:"auto",minHeight:0,maxHeight:"none",height:0}),s.minWidth>s.width&&(s.width=s.minWidth),t=this.uiDialog.css({height:"auto",width:s.width}).outerHeight(),e=Math.max(0,s.minHeight-t),i="number"==typeof s.maxHeight?Math.max(0,s.maxHeight-t):"none","auto"===s.height?this.element.css({minHeight:e,maxHeight:i,height:"auto"}):this.element.height(Math.max(0,s.height-t)),this.uiDialog.is(":data(ui-resizable)")&&this.uiDialog.resizable("option","minHeight",this._minHeight())},_blockFrames:function(){this.iframeBlocks=this.document.find("iframe").map(function(){var e=t(this);return t("<div>").css({position:"absolute",width:e.outerWidth(),height:e.outerHeight()}).appendTo(e.parent()).offset(e.offset())[0]})},_unblockFrames:function(){this.iframeBlocks&&(this.iframeBlocks.remove(),delete this.iframeBlocks)},_allowInteraction:function(e){return t(e.target).closest(".ui-dialog").length?!0:!!t(e.target).closest(".ui-datepicker").length},_createOverlay:function(){if(this.options.modal){var e=!0;this._delay(function(){e=!1}),this.document.data("ui-dialog-overlays")||this._on(this.document,{focusin:function(t){e||this._allowInteraction(t)||(t.preventDefault(),this._trackingInstances()[0]._focusTabbable())}}),this.overlay=t("<div>").appendTo(this._appendTo()),this._addClass(this.overlay,null,"ui-widget-overlay ui-front"),this._on(this.overlay,{mousedown:"_keepFocus"}),this.document.data("ui-dialog-overlays",(this.document.data("ui-dialog-overlays")||0)+1)}},_destroyOverlay:function(){if(this.options.modal&&this.overlay){var t=this.document.data("ui-dialog-overlays")-1;t?this.document.data("ui-dialog-overlays",t):(this._off(this.document,"focusin"),this.document.removeData("ui-dialog-overlays")),this.overlay.remove(),this.overlay=null}}}),t.uiBackCompat!==!1&&t.widget("ui.dialog",t.ui.dialog,{options:{dialogClass:""},_createWrapper:function(){this._super(),this.uiDialog.addClass(this.options.dialogClass)},_setOption:function(t,e){"dialogClass"===t&&this.uiDialog.removeClass(this.options.dialogClass).addClass(e),this._superApply(arguments)}}),t.ui.dialog,t.widget("ui.droppable",{version:"1.12.1",widgetEventPrefix:"drop",options:{accept:"*",addClasses:!0,greedy:!1,scope:"default",tolerance:"intersect",activate:null,deactivate:null,drop:null,out:null,over:null},_create:function(){var e,i=this.options,s=i.accept;this.isover=!1,this.isout=!0,this.accept=t.isFunction(s)?s:function(t){return t.is(s)},this.proportions=function(){return arguments.length?(e=arguments[0],void 0):e?e:e={width:this.element[0].offsetWidth,height:this.element[0].offsetHeight}},this._addToManager(i.scope),i.addClasses&&this._addClass("ui-droppable")},_addToManager:function(e){t.ui.ddmanager.droppables[e]=t.ui.ddmanager.droppables[e]||[],t.ui.ddmanager.droppables[e].push(this)},_splice:function(t){for(var e=0;t.length>e;e++)t[e]===this&&t.splice(e,1)},_destroy:function(){var e=t.ui.ddmanager.droppables[this.options.scope];this._splice(e)},_setOption:function(e,i){if("accept"===e)this.accept=t.isFunction(i)?i:function(t){return t.is(i)};else if("scope"===e){var s=t.ui.ddmanager.droppables[this.options.scope];this._splice(s),this._addToManager(i)}this._super(e,i)},_activate:function(e){var i=t.ui.ddmanager.current;this._addActiveClass(),i&&this._trigger("activate",e,this.ui(i))},_deactivate:function(e){var i=t.ui.ddmanager.current;this._removeActiveClass(),i&&this._trigger("deactivate",e,this.ui(i))},_over:function(e){var i=t.ui.ddmanager.current;i&&(i.currentItem||i.element)[0]!==this.element[0]&&this.accept.call(this.element[0],i.currentItem||i.element)&&(this._addHoverClass(),this._trigger("over",e,this.ui(i)))},_out:function(e){var i=t.ui.ddmanager.current;i&&(i.currentItem||i.element)[0]!==this.element[0]&&this.accept.call(this.element[0],i.currentItem||i.element)&&(this._removeHoverClass(),this._trigger("out",e,this.ui(i)))},_drop:function(e,i){var s=i||t.ui.ddmanager.current,n=!1;return s&&(s.currentItem||s.element)[0]!==this.element[0]?(this.element.find(":data(ui-droppable)").not(".ui-draggable-dragging").each(function(){var i=t(this).droppable("instance");return i.options.greedy&&!i.options.disabled&&i.options.scope===s.options.scope&&i.accept.call(i.element[0],s.currentItem||s.element)&&v(s,t.extend(i,{offset:i.element.offset()}),i.options.tolerance,e)?(n=!0,!1):void 0}),n?!1:this.accept.call(this.element[0],s.currentItem||s.element)?(this._removeActiveClass(),this._removeHoverClass(),this._trigger("drop",e,this.ui(s)),this.element):!1):!1},ui:function(t){return{draggable:t.currentItem||t.element,helper:t.helper,position:t.position,offset:t.positionAbs}},_addHoverClass:function(){this._addClass("ui-droppable-hover")},_removeHoverClass:function(){this._removeClass("ui-droppable-hover")},_addActiveClass:function(){this._addClass("ui-droppable-active")},_removeActiveClass:function(){this._removeClass("ui-droppable-active")}});var v=t.ui.intersect=function(){function t(t,e,i){return t>=e&&e+i>t}return function(e,i,s,n){if(!i.offset)return!1;var o=(e.positionAbs||e.position.absolute).left+e.margins.left,a=(e.positionAbs||e.position.absolute).top+e.margins.top,r=o+e.helperProportions.width,h=a+e.helperProportions.height,l=i.offset.left,c=i.offset.top,u=l+i.proportions().width,d=c+i.proportions().height;switch(s){case"fit":return o>=l&&u>=r&&a>=c&&d>=h;case"intersect":return o+e.helperProportions.width/2>l&&u>r-e.helperProportions.width/2&&a+e.helperProportions.height/2>c&&d>h-e.helperProportions.height/2;case"pointer":return t(n.pageY,c,i.proportions().height)&&t(n.pageX,l,i.proportions().width);case"touch":return(a>=c&&d>=a||h>=c&&d>=h||c>a&&h>d)&&(o>=l&&u>=o||r>=l&&u>=r||l>o&&r>u);default:return!1}}}();t.ui.ddmanager={current:null,droppables:{"default":[]},prepareOffsets:function(e,i){var s,n,o=t.ui.ddmanager.droppables[e.options.scope]||[],a=i?i.type:null,r=(e.currentItem||e.element).find(":data(ui-droppable)").addBack();t:for(s=0;o.length>s;s++)if(!(o[s].options.disabled||e&&!o[s].accept.call(o[s].element[0],e.currentItem||e.element))){for(n=0;r.length>n;n++)if(r[n]===o[s].element[0]){o[s].proportions().height=0;continue t}o[s].visible="none"!==o[s].element.css("display"),o[s].visible&&("mousedown"===a&&o[s]._activate.call(o[s],i),o[s].offset=o[s].element.offset(),o[s].proportions({width:o[s].element[0].offsetWidth,height:o[s].element[0].offsetHeight}))}},drop:function(e,i){var s=!1;return t.each((t.ui.ddmanager.droppables[e.options.scope]||[]).slice(),function(){this.options&&(!this.options.disabled&&this.visible&&v(e,this,this.options.tolerance,i)&&(s=this._drop.call(this,i)||s),!this.options.disabled&&this.visible&&this.accept.call(this.element[0],e.currentItem||e.element)&&(this.isout=!0,this.isover=!1,this._deactivate.call(this,i)))}),s},dragStart:function(e,i){e.element.parentsUntil("body").on("scroll.droppable",function(){e.options.refreshPositions||t.ui.ddmanager.prepareOffsets(e,i)})},drag:function(e,i){e.options.refreshPositions&&t.ui.ddmanager.prepareOffsets(e,i),t.each(t.ui.ddmanager.droppables[e.options.scope]||[],function(){if(!this.options.disabled&&!this.greedyChild&&this.visible){var s,n,o,a=v(e,this,this.options.tolerance,i),r=!a&&this.isover?"isout":a&&!this.isover?"isover":null;r&&(this.options.greedy&&(n=this.options.scope,o=this.element.parents(":data(ui-droppable)").filter(function(){return t(this).droppable("instance").options.scope===n}),o.length&&(s=t(o[0]).droppable("instance"),s.greedyChild="isover"===r)),s&&"isover"===r&&(s.isover=!1,s.isout=!0,s._out.call(s,i)),this[r]=!0,this["isout"===r?"isover":"isout"]=!1,this["isover"===r?"_over":"_out"].call(this,i),s&&"isout"===r&&(s.isout=!1,s.isover=!0,s._over.call(s,i)))}})},dragStop:function(e,i){e.element.parentsUntil("body").off("scroll.droppable"),e.options.refreshPositions||t.ui.ddmanager.prepareOffsets(e,i)}},t.uiBackCompat!==!1&&t.widget("ui.droppable",t.ui.droppable,{options:{hoverClass:!1,activeClass:!1},_addActiveClass:function(){this._super(),this.options.activeClass&&this.element.addClass(this.options.activeClass)},_removeActiveClass:function(){this._super(),this.options.activeClass&&this.element.removeClass(this.options.activeClass)},_addHoverClass:function(){this._super(),this.options.hoverClass&&this.element.addClass(this.options.hoverClass)},_removeHoverClass:function(){this._super(),this.options.hoverClass&&this.element.removeClass(this.options.hoverClass)}}),t.ui.droppable,t.widget("ui.progressbar",{version:"1.12.1",options:{classes:{"ui-progressbar":"ui-corner-all","ui-progressbar-value":"ui-corner-left","ui-progressbar-complete":"ui-corner-right"},max:100,value:0,change:null,complete:null},min:0,_create:function(){this.oldValue=this.options.value=this._constrainedValue(),this.element.attr({role:"progressbar","aria-valuemin":this.min}),this._addClass("ui-progressbar","ui-widget ui-widget-content"),this.valueDiv=t("<div>").appendTo(this.element),this._addClass(this.valueDiv,"ui-progressbar-value","ui-widget-header"),this._refreshValue()},_destroy:function(){this.element.removeAttr("role aria-valuemin aria-valuemax aria-valuenow"),this.valueDiv.remove()},value:function(t){return void 0===t?this.options.value:(this.options.value=this._constrainedValue(t),this._refreshValue(),void 0)},_constrainedValue:function(t){return void 0===t&&(t=this.options.value),this.indeterminate=t===!1,"number"!=typeof t&&(t=0),this.indeterminate?!1:Math.min(this.options.max,Math.max(this.min,t))},_setOptions:function(t){var e=t.value;delete t.value,this._super(t),this.options.value=this._constrainedValue(e),this._refreshValue()},_setOption:function(t,e){"max"===t&&(e=Math.max(this.min,e)),this._super(t,e)},_setOptionDisabled:function(t){this._super(t),this.element.attr("aria-disabled",t),this._toggleClass(null,"ui-state-disabled",!!t)},_percentage:function(){return this.indeterminate?100:100*(this.options.value-this.min)/(this.options.max-this.min)},_refreshValue:function(){var e=this.options.value,i=this._percentage();this.valueDiv.toggle(this.indeterminate||e>this.min).width(i.toFixed(0)+"%"),this._toggleClass(this.valueDiv,"ui-progressbar-complete",null,e===this.options.max)._toggleClass("ui-progressbar-indeterminate",null,this.indeterminate),this.indeterminate?(this.element.removeAttr("aria-valuenow"),this.overlayDiv||(this.overlayDiv=t("<div>").appendTo(this.valueDiv),this._addClass(this.overlayDiv,"ui-progressbar-overlay"))):(this.element.attr({"aria-valuemax":this.options.max,"aria-valuenow":e}),this.overlayDiv&&(this.overlayDiv.remove(),this.overlayDiv=null)),this.oldValue!==e&&(this.oldValue=e,this._trigger("change")),e===this.options.max&&this._trigger("complete")}}),t.widget("ui.selectable",t.ui.mouse,{version:"1.12.1",options:{appendTo:"body",autoRefresh:!0,distance:0,filter:"*",tolerance:"touch",selected:null,selecting:null,start:null,stop:null,unselected:null,unselecting:null},_create:function(){var e=this;this._addClass("ui-selectable"),this.dragged=!1,this.refresh=function(){e.elementPos=t(e.element[0]).offset(),e.selectees=t(e.options.filter,e.element[0]),e._addClass(e.selectees,"ui-selectee"),e.selectees.each(function(){var i=t(this),s=i.offset(),n={left:s.left-e.elementPos.left,top:s.top-e.elementPos.top};t.data(this,"selectable-item",{element:this,$element:i,left:n.left,top:n.top,right:n.left+i.outerWidth(),bottom:n.top+i.outerHeight(),startselected:!1,selected:i.hasClass("ui-selected"),selecting:i.hasClass("ui-selecting"),unselecting:i.hasClass("ui-unselecting")})})},this.refresh(),this._mouseInit(),this.helper=t("<div>"),this._addClass(this.helper,"ui-selectable-helper")},_destroy:function(){this.selectees.removeData("selectable-item"),this._mouseDestroy()},_mouseStart:function(e){var i=this,s=this.options;this.opos=[e.pageX,e.pageY],this.elementPos=t(this.element[0]).offset(),this.options.disabled||(this.selectees=t(s.filter,this.element[0]),this._trigger("start",e),t(s.appendTo).append(this.helper),this.helper.css({left:e.pageX,top:e.pageY,width:0,height:0}),s.autoRefresh&&this.refresh(),this.selectees.filter(".ui-selected").each(function(){var s=t.data(this,"selectable-item");s.startselected=!0,e.metaKey||e.ctrlKey||(i._removeClass(s.$element,"ui-selected"),s.selected=!1,i._addClass(s.$element,"ui-unselecting"),s.unselecting=!0,i._trigger("unselecting",e,{unselecting:s.element}))}),t(e.target).parents().addBack().each(function(){var s,n=t.data(this,"selectable-item");return n?(s=!e.metaKey&&!e.ctrlKey||!n.$element.hasClass("ui-selected"),i._removeClass(n.$element,s?"ui-unselecting":"ui-selected")._addClass(n.$element,s?"ui-selecting":"ui-unselecting"),n.unselecting=!s,n.selecting=s,n.selected=s,s?i._trigger("selecting",e,{selecting:n.element}):i._trigger("unselecting",e,{unselecting:n.element}),!1):void 0}))},_mouseDrag:function(e){if(this.dragged=!0,!this.options.disabled){var i,s=this,n=this.options,o=this.opos[0],a=this.opos[1],r=e.pageX,h=e.pageY;return o>r&&(i=r,r=o,o=i),a>h&&(i=h,h=a,a=i),this.helper.css({left:o,top:a,width:r-o,height:h-a}),this.selectees.each(function(){var i=t.data(this,"selectable-item"),l=!1,c={};i&&i.element!==s.element[0]&&(c.left=i.left+s.elementPos.left,c.right=i.right+s.elementPos.left,c.top=i.top+s.elementPos.top,c.bottom=i.bottom+s.elementPos.top,"touch"===n.tolerance?l=!(c.left>r||o>c.right||c.top>h||a>c.bottom):"fit"===n.tolerance&&(l=c.left>o&&r>c.right&&c.top>a&&h>c.bottom),l?(i.selected&&(s._removeClass(i.$element,"ui-selected"),i.selected=!1),i.unselecting&&(s._removeClass(i.$element,"ui-unselecting"),i.unselecting=!1),i.selecting||(s._addClass(i.$element,"ui-selecting"),i.selecting=!0,s._trigger("selecting",e,{selecting:i.element}))):(i.selecting&&((e.metaKey||e.ctrlKey)&&i.startselected?(s._removeClass(i.$element,"ui-selecting"),i.selecting=!1,s._addClass(i.$element,"ui-selected"),i.selected=!0):(s._removeClass(i.$element,"ui-selecting"),i.selecting=!1,i.startselected&&(s._addClass(i.$element,"ui-unselecting"),i.unselecting=!0),s._trigger("unselecting",e,{unselecting:i.element}))),i.selected&&(e.metaKey||e.ctrlKey||i.startselected||(s._removeClass(i.$element,"ui-selected"),i.selected=!1,s._addClass(i.$element,"ui-unselecting"),i.unselecting=!0,s._trigger("unselecting",e,{unselecting:i.element})))))}),!1}},_mouseStop:function(e){var i=this;return this.dragged=!1,t(".ui-unselecting",this.element[0]).each(function(){var s=t.data(this,"selectable-item");i._removeClass(s.$element,"ui-unselecting"),s.unselecting=!1,s.startselected=!1,i._trigger("unselected",e,{unselected:s.element})}),t(".ui-selecting",this.element[0]).each(function(){var s=t.data(this,"selectable-item");i._removeClass(s.$element,"ui-selecting")._addClass(s.$element,"ui-selected"),s.selecting=!1,s.selected=!0,s.startselected=!0,i._trigger("selected",e,{selected:s.element})}),this._trigger("stop",e),this.helper.remove(),!1}}),t.widget("ui.selectmenu",[t.ui.formResetMixin,{version:"1.12.1",defaultElement:"<select>",options:{appendTo:null,classes:{"ui-selectmenu-button-open":"ui-corner-top","ui-selectmenu-button-closed":"ui-corner-all"},disabled:null,icons:{button:"ui-icon-triangle-1-s"},position:{my:"left top",at:"left bottom",collision:"none"}
vendor: 4,710 bytes, line 19
19,width:!1,change:null,close:null,focus:null,open:null,select:null},_create:function(){var e=this.element.uniqueId().attr("id");this.ids={element:e,button:e+"-button",menu:e+"-menu"},this._drawButton(),this._drawMenu(),this._bindFormResetHandler(),this._rendered=!1,this.menuItems=t()},_drawButton:function(){var e,i=this,s=this._parseOption(this.element.find("option:selected"),this.element[0].selectedIndex);this.labels=this.element.labels().attr("for",this.ids.button),this._on(this.labels,{click:function(t){this.button.focus(),t.preventDefault()}}),this.element.hide(),this.button=t("<span>",{tabindex:this.options.disabled?-1:0,id:this.ids.button,role:"combobox","aria-expanded":"false","aria-autocomplete":"list","aria-owns":this.ids.menu,"aria-haspopup":"true",title:this.element.attr("title")}).insertAfter(this.element),this._addClass(this.button,"ui-selectmenu-button ui-selectmenu-button-closed","ui-button ui-widget"),e=t("<span>").appendTo(this.button),this._addClass(e,"ui-selectmenu-icon","ui-icon "+this.options.icons.button),this.buttonItem=this._renderButtonItem(s).appendTo(this.button),this.options.width!==!1&&this._resizeButton(),this._on(this.button,this._buttonEvents),this.button.one("focusin",function(){i._rendered||i._refreshMenu()})},_drawMenu:function(){var e=this;this.menu=t("<ul>",{"aria-hidden":"true","aria-labelledby":this.ids.button,id:this.ids.menu}),this.menuWrap=t("<div>").append(this.menu),this._addClass(this.menuWrap,"ui-selectmenu-menu","ui-front"),this.menuWrap.appendTo(this._appendTo()),this.menuInstance=this.menu.menu({classes:{"ui-menu":"ui-corner-bottom"},role:"listbox",select:function(t,i){t.preventDefault(),e._setSelection(),e._select(i.item.data("ui-selectmenu-item"),t)},focus:function(t,i){var s=i.item.data("ui-selectmenu-item");null!=e.focusIndex&&s.index!==e.focusIndex&&(e._trigger("focus",t,{item:s}),e.isOpen||e._select(s,t)),e.focusIndex=s.index,e.button.attr("aria-activedescendant",e.menuItems.eq(s.index).attr("id"))}}).menu("instance"),this.menuInstance._off(this.menu,"mouseleave"),this.menuInstance._closeOnDocumentClick=function(){return!1},this.menuInstance._isDivider=function(){return!1}},refresh:function(){this._refreshMenu(),this.buttonItem.replaceWith(this.buttonItem=this._renderButtonItem(this._getSelectedItem().data("ui-selectmenu-item")||{})),null===this.options.width&&this._resizeButton()},_refreshMenu:function(){var t,e=this.element.find("option");this.menu.empty(),this._parseOptions(e),this._renderMenu(this.menu,this.items),this.menuInstance.refresh(),this.menuItems=this.menu.find("li").not(".ui-selectmenu-optgroup").find(".ui-menu-item-wrapper"),this._rendered=!0,e.length&&(t=this._getSelectedItem(),this.menuInstance.focus(null,t),this._setAria(t.data("ui-selectmenu-item")),this._setOption("disabled",this.element.prop("disabled")))},open:function(t){this.options.disabled||(this._rendered?(this._removeClass(this.menu.find(".ui-state-active"),null,"ui-state-active"),this.menuInstance.focus(null,this._getSelectedItem())):this._refreshMenu(),this.menuItems.length&&(this.isOpen=!0,this._toggleAttr(),this._resizeMenu(),this._position(),this._on(this.document,this._documentClick),this._trigger("open",t)))},_position:function(){this.menuWrap.position(t.extend({of:this.button},this.options.position))},close:function(t){this.isOpen&&(this.isOpen=!1,this._toggleAttr(),this.range=null,this._off(this.document),this._trigger("close",t))},widget:function(){return this.button},menuWidget:function(){return this.menu},_renderButtonItem:function(e){var i=t("<span>");return this._setText(i,e.label),this._addClass(i,"ui-selectmenu-text"),i},_renderMenu:function(e,i){var s=this,n="";t.each(i,function(i,o){var a;o.optgroup!==n&&(a=t("<li>",{text:o.optgroup}),s._addClass(a,"ui-selectmenu-optgroup","ui-menu-divider"+(o.element.parent("optgroup").prop("disabled")?" ui-state-disabled":"")),a.appendTo(e),n=o.optgroup),s._renderItemData(e,o)})},_renderItemData:function(t,e){return this._renderItem(t,e).data("ui-selectmenu-item",e)},_renderItem:function(e,i){var s=t("<li>"),n=t("<div>",{title:i.element.attr("title")});return i.disabled&&this._addClass(s,null,"ui-state-disabled"),this._setText(n,i.label),s.append(n).appendTo(e)},_setText:function(t,e){e?t.text(e):t.html(" ")},_move:function(t,e){var i,s,n=".ui-menu-item";this.isOpen?i=this.menuItems.eq(this.focusIndex).parent("li"):(i=this.menuItems.eq(this.element[0].selectedIndex).parent("li"),n+=":not(.ui-state-disabled)"),s="first"===t||"last"===t?i["first"===t?"prevAll":"nextAll"](n).eq(-1):i[t+"All"](n).eq(0),s.length&&this.menuInstance.focus(e,s)},_getSelectedItem:function(){return this.menuItems.eq(this.element[0].selectedIndex).parent("li")}
vendor: 4,655 bytes, line 19
19,_toggle:function(t){this[this.isOpen?"close":"open"](t)},_setSelection:function(){var t;this.range&&(window.getSelection?(t=window.getSelection(),t.removeAllRanges(),t.addRange(this.range)):this.range.select(),this.button.focus())},_documentClick:{mousedown:function(e){this.isOpen&&(t(e.target).closest(".ui-selectmenu-menu, #"+t.ui.escapeSelector(this.ids.button)).length||this.close(e))}},_buttonEvents:{mousedown:function(){var t;window.getSelection?(t=window.getSelection(),t.rangeCount&&(this.range=t.getRangeAt(0))):this.range=document.selection.createRange()},click:function(t){this._setSelection(),this._toggle(t)},keydown:function(e){var i=!0;switch(e.keyCode){case t.ui.keyCode.TAB:case t.ui.keyCode.ESCAPE:this.close(e),i=!1;break;case t.ui.keyCode.ENTER:this.isOpen&&this._selectFocusedItem(e);break;case t.ui.keyCode.UP:e.altKey?this._toggle(e):this._move("prev",e);break;case t.ui.keyCode.DOWN:e.altKey?this._toggle(e):this._move("next",e);break;case t.ui.keyCode.SPACE:this.isOpen?this._selectFocusedItem(e):this._toggle(e);break;case t.ui.keyCode.LEFT:this._move("prev",e);break;case t.ui.keyCode.RIGHT:this._move("next",e);break;case t.ui.keyCode.HOME:case t.ui.keyCode.PAGE_UP:this._move("first",e);break;case t.ui.keyCode.END:case t.ui.keyCode.PAGE_DOWN:this._move("last",e);break;default:this.menu.trigger(e),i=!1}i&&e.preventDefault()}},_selectFocusedItem:function(t){var e=this.menuItems.eq(this.focusIndex).parent("li");e.hasClass("ui-state-disabled")||this._select(e.data("ui-selectmenu-item"),t)},_select:function(t,e){var i=this.element[0].selectedIndex;this.element[0].selectedIndex=t.index,this.buttonItem.replaceWith(this.buttonItem=this._renderButtonItem(t)),this._setAria(t),this._trigger("select",e,{item:t}),t.index!==i&&this._trigger("change",e,{item:t}),this.close(e)},_setAria:function(t){var e=this.menuItems.eq(t.index).attr("id");this.button.attr({"aria-labelledby":e,"aria-activedescendant":e}),this.menu.attr("aria-activedescendant",e)},_setOption:function(t,e){if("icons"===t){var i=this.button.find("span.ui-icon");this._removeClass(i,null,this.options.icons.button)._addClass(i,null,e.button)}this._super(t,e),"appendTo"===t&&this.menuWrap.appendTo(this._appendTo()),"width"===t&&this._resizeButton()},_setOptionDisabled:function(t){this._super(t),this.menuInstance.option("disabled",t),this.button.attr("aria-disabled",t),this._toggleClass(this.button,null,"ui-state-disabled",t),this.element.prop("disabled",t),t?(this.button.attr("tabindex",-1),this.close()):this.button.attr("tabindex",0)},_appendTo:function(){var e=this.options.appendTo;return e&&(e=e.jquery||e.nodeType?t(e):this.document.find(e).eq(0)),e&&e[0]||(e=this.element.closest(".ui-front, dialog")),e.length||(e=this.document[0].body),e},_toggleAttr:function(){this.button.attr("aria-expanded",this.isOpen),this._removeClass(this.button,"ui-selectmenu-button-"+(this.isOpen?"closed":"open"))._addClass(this.button,"ui-selectmenu-button-"+(this.isOpen?"open":"closed"))._toggleClass(this.menuWrap,"ui-selectmenu-open",null,this.isOpen),this.menu.attr("aria-hidden",!this.isOpen)},_resizeButton:function(){var t=this.options.width;return t===!1?(this.button.css("width",""),void 0):(null===t&&(t=this.element.show().outerWidth(),this.element.hide()),this.button.outerWidth(t),void 0)},_resizeMenu:function(){this.menu.outerWidth(Math.max(this.button.outerWidth(),this.menu.width("").outerWidth()+1))},_getCreateOptions:function(){var t=this._super();return t.disabled=this.element.prop("disabled"),t},_parseOptions:function(e){var i=this,s=[];e.each(function(e,n){s.push(i._parseOption(t(n),e))}),this.items=s},_parseOption:function(t,e){var i=t.parent("optgroup");return{element:t,index:e,value:t.val(),label:t.text(),optgroup:i.attr("label")||"",disabled:i.prop("disabled")||t.prop("disabled")}},_destroy:function(){this._unbindFormResetHandler(),this.menuWrap.remove(),this.button.remove(),this.element.show(),this.element.removeUniqueId(),this.labels.attr("for",this.ids.element)}}]),t.widget("ui.slider",t.ui.mouse,{version:"1.12.1",widgetEventPrefix:"slide",options:{animate:!1,classes:{"ui-slider":"ui-corner-all","ui-slider-handle":"ui-corner-all","ui-slider-range":"ui-corner-all ui-widget-header"},distance:0,max:100,min:0,orientation:"horizontal",range:!1,step:1,value:0,values:null,change:null,slide:null,start:null,stop:null},numPages:5,_create:function(){this._keySliding=!1,this._mouseSliding=!1,this._animateOff=!0,this._handleIndex=null,this._detectOrientation(),this._mouseInit(),this._calculateNewMax(),this._addClass("ui-slider ui-slider-"+this.orientation,"ui-widget ui-widget-content"),this._refresh(),this._animateOff=!1
20
vendor: 10,397 bytes, line 20
20},_refresh:function(){this._createRange(),this._createHandles(),this._setupEvents(),this._refreshValue()},_createHandles:function(){var e,i,s=this.options,n=this.element.find(".ui-slider-handle"),o="<span tabindex='0'></span>",a=[];for(i=s.values&&s.values.length||1,n.length>i&&(n.slice(i).remove(),n=n.slice(0,i)),e=n.length;i>e;e++)a.push(o);this.handles=n.add(t(a.join("")).appendTo(this.element)),this._addClass(this.handles,"ui-slider-handle","ui-state-default"),this.handle=this.handles.eq(0),this.handles.each(function(e){t(this).data("ui-slider-handle-index",e).attr("tabIndex",0)})},_createRange:function(){var e=this.options;e.range?(e.range===!0&&(e.values?e.values.length&&2!==e.values.length?e.values=[e.values[0],e.values[0]]:t.isArray(e.values)&&(e.values=e.values.slice(0)):e.values=[this._valueMin(),this._valueMin()]),this.range&&this.range.length?(this._removeClass(this.range,"ui-slider-range-min ui-slider-range-max"),this.range.css({left:"",bottom:""})):(this.range=t("<div>").appendTo(this.element),this._addClass(this.range,"ui-slider-range")),("min"===e.range||"max"===e.range)&&this._addClass(this.range,"ui-slider-range-"+e.range)):(this.range&&this.range.remove(),this.range=null)},_setupEvents:function(){this._off(this.handles),this._on(this.handles,this._handleEvents),this._hoverable(this.handles),this._focusable(this.handles)},_destroy:function(){this.handles.remove(),this.range&&this.range.remove(),this._mouseDestroy()},_mouseCapture:function(e){var i,s,n,o,a,r,h,l,c=this,u=this.options;return u.disabled?!1:(this.elementSize={width:this.element.outerWidth(),height:this.element.outerHeight()},this.elementOffset=this.element.offset(),i={x:e.pageX,y:e.pageY},s=this._normValueFromMouse(i),n=this._valueMax()-this._valueMin()+1,this.handles.each(function(e){var i=Math.abs(s-c.values(e));(n>i||n===i&&(e===c._lastChangedValue||c.values(e)===u.min))&&(n=i,o=t(this),a=e)}),r=this._start(e,a),r===!1?!1:(this._mouseSliding=!0,this._handleIndex=a,this._addClass(o,null,"ui-state-active"),o.trigger("focus"),h=o.offset(),l=!t(e.target).parents().addBack().is(".ui-slider-handle"),this._clickOffset=l?{left:0,top:0}:{left:e.pageX-h.left-o.width()/2,top:e.pageY-h.top-o.height()/2-(parseInt(o.css("borderTopWidth"),10)||0)-(parseInt(o.css("borderBottomWidth"),10)||0)+(parseInt(o.css("marginTop"),10)||0)},this.handles.hasClass("ui-state-hover")||this._slide(e,a,s),this._animateOff=!0,!0))},_mouseStart:function(){return!0},_mouseDrag:function(t){var e={x:t.pageX,y:t.pageY},i=this._normValueFromMouse(e);return this._slide(t,this._handleIndex,i),!1},_mouseStop:function(t){return this._removeClass(this.handles,null,"ui-state-active"),this._mouseSliding=!1,this._stop(t,this._handleIndex),this._change(t,this._handleIndex),this._handleIndex=null,this._clickOffset=null,this._animateOff=!1,!1},_detectOrientation:function(){this.orientation="vertical"===this.options.orientation?"vertical":"horizontal"},_normValueFromMouse:function(t){var e,i,s,n,o;return"horizontal"===this.orientation?(e=this.elementSize.width,i=t.x-this.elementOffset.left-(this._clickOffset?this._clickOffset.left:0)):(e=this.elementSize.height,i=t.y-this.elementOffset.top-(this._clickOffset?this._clickOffset.top:0)),s=i/e,s>1&&(s=1),0>s&&(s=0),"vertical"===this.orientation&&(s=1-s),n=this._valueMax()-this._valueMin(),o=this._valueMin()+s*n,this._trimAlignValue(o)},_uiHash:function(t,e,i){var s={handle:this.handles[t],handleIndex:t,value:void 0!==e?e:this.value()};return this._hasMultipleValues()&&(s.value=void 0!==e?e:this.values(t),s.values=i||this.values()),s},_hasMultipleValues:function(){return this.options.values&&this.options.values.length},_start:function(t,e){return this._trigger("start",t,this._uiHash(e))},_slide:function(t,e,i){var s,n,o=this.value(),a=this.values();this._hasMultipleValues()&&(n=this.values(e?0:1),o=this.values(e),2===this.options.values.length&&this.options.range===!0&&(i=0===e?Math.min(n,i):Math.max(n,i)),a[e]=i),i!==o&&(s=this._trigger("slide",t,this._uiHash(e,i,a)),s!==!1&&(this._hasMultipleValues()?this.values(e,i):this.value(i)))},_stop:function(t,e){this._trigger("stop",t,this._uiHash(e))},_change:function(t,e){this._keySliding||this._mouseSliding||(this._lastChangedValue=e,this._trigger("change",t,this._uiHash(e)))},value:function(t){return arguments.length?(this.options.value=this._trimAlignValue(t),this._refreshValue(),this._change(null,0),void 0):this._value()},values:function(e,i){var s,n,o;if(arguments.length>1)return this.options.values[e]=this._trimAlignValue(i),this._refreshValue(),this._change(null,e),void 0;if(!arguments.length)return this._values();if(!t.isArray(arguments[0]))return this._hasMultipleValues()?this._values(e):this.value();for(s=this.options.values,n=arguments[0],o=0;s.length>o;o+=1)s[o]=this._trimAlignValue(n[o]),this._change(null,o);this._refreshValue()},_setOption:function(e,i){var s,n=0;switch("range"===e&&this.options.range===!0&&("min"===i?(this.options.value=this._values(0),this.options.values=null):"max"===i&&(this.options.value=this._values(this.options.values.length-1),this.options.values=null)),t.isArray(this.options.values)&&(n=this.options.values.length),this._super(e,i),e){case"orientation":this._detectOrientation(),this._removeClass("ui-slider-horizontal ui-slider-vertical")._addClass("ui-slider-"+this.orientation),this._refreshValue(),this.options.range&&this._refreshRange(i),this.handles.css("horizontal"===i?"bottom":"left","");break;case"value":this._animateOff=!0,this._refreshValue(),this._change(null,0),this._animateOff=!1;break;case"values":for(this._animateOff=!0,this._refreshValue(),s=n-1;s>=0;s--)this._change(null,s);this._animateOff=!1;break;case"step":case"min":case"max":this._animateOff=!0,this._calculateNewMax(),this._refreshValue(),this._animateOff=!1;break;case"range":this._animateOff=!0,this._refresh(),this._animateOff=!1}},_setOptionDisabled:function(t){this._super(t),this._toggleClass(null,"ui-state-disabled",!!t)},_value:function(){var t=this.options.value;return t=this._trimAlignValue(t)},_values:function(t){var e,i,s;if(arguments.length)return e=this.options.values[t],e=this._trimAlignValue(e);if(this._hasMultipleValues()){for(i=this.options.values.slice(),s=0;i.length>s;s+=1)i[s]=this._trimAlignValue(i[s]);return i}return[]},_trimAlignValue:function(t){if(this._valueMin()>=t)return this._valueMin();if(t>=this._valueMax())return this._valueMax();var e=this.options.step>0?this.options.step:1,i=(t-this._valueMin())%e,s=t-i;return 2*Math.abs(i)>=e&&(s+=i>0?e:-e),parseFloat(s.toFixed(5))},_calculateNewMax:function(){var t=this.options.max,e=this._valueMin(),i=this.options.step,s=Math.round((t-e)/i)*i;t=s+e,t>this.options.max&&(t-=i),this.max=parseFloat(t.toFixed(this._precision()))},_precision:function(){var t=this._precisionOf(this.options.step);return null!==this.options.min&&(t=Math.max(t,this._precisionOf(this.options.min))),t},_precisionOf:function(t){var e=""+t,i=e.indexOf(".");return-1===i?0:e.length-i-1},_valueMin:function(){return this.options.min},_valueMax:function(){return this.max},_refreshRange:function(t){"vertical"===t&&this.range.css({width:"",left:""}),"horizontal"===t&&this.range.css({height:"",bottom:""})},_refreshValue:function(){var e,i,s,n,o,a=this.options.range,r=this.options,h=this,l=this._animateOff?!1:r.animate,c={};this._hasMultipleValues()?this.handles.each(function(s){i=100*((h.values(s)-h._valueMin())/(h._valueMax()-h._valueMin())),c["horizontal"===h.orientation?"left":"bottom"]=i+"%",t(this).stop(1,1)[l?"animate":"css"](c,r.animate),h.options.range===!0&&("horizontal"===h.orientation?(0===s&&h.range.stop(1,1)[l?"animate":"css"]({left:i+"%"},r.animate),1===s&&h.range[l?"animate":"css"]({width:i-e+"%"},{queue:!1,duration:r.animate})):(0===s&&h.range.stop(1,1)[l?"animate":"css"]({bottom:i+"%"},r.animate),1===s&&h.range[l?"animate":"css"]({height:i-e+"%"},{queue:!1,duration:r.animate}))),e=i}):(s=this.value(),n=this._valueMin(),o=this._valueMax(),i=o!==n?100*((s-n)/(o-n)):0,c["horizontal"===this.orientation?"left":"bottom"]=i+"%",this.handle.stop(1,1)[l?"animate":"css"](c,r.animate),"min"===a&&"horizontal"===this.orientation&&this.range.stop(1,1)[l?"animate":"css"]({width:i+"%"},r.animate),"max"===a&&"horizontal"===this.orientation&&this.range.stop(1,1)[l?"animate":"css"]({width:100-i+"%"},r.animate),"min"===a&&"vertical"===this.orientation&&this.range.stop(1,1)[l?"animate":"css"]({height:i+"%"},r.animate),"max"===a&&"vertical"===this.orientation&&this.range.stop(1,1)[l?"animate":"css"]({height:100-i+"%"},r.animate))},_handleEvents:{keydown:function(e){var i,s,n,o,a=t(e.target).data("ui-slider-handle-index");switch(e.keyCode){case t.ui.keyCode.HOME:case t.ui.keyCode.END:case t.ui.keyCode.PAGE_UP:case t.ui.keyCode.PAGE_DOWN:case t.ui.keyCode.UP:case t.ui.keyCode.RIGHT:case t.ui.keyCode.DOWN:case t.ui.keyCode.LEFT:if(e.preventDefault(),!this._keySliding&&(this._keySliding=!0,this._addClass(t(e.target),null,"ui-state-active"),i=this._start(e,a),i===!1))return}switch(o=this.options.step,s=n=this._hasMultipleValues()?this.values(a):this.value(),e.keyCode){case t.ui.keyCode.HOME:n=this._valueMin();break;case t.ui.keyCode.END:n=this._valueMax();break;case t.ui.keyCode.PAGE_UP:n=this._trimAlignValue(s+(this._valueMax()-this._valueMin())/this.numPages);break;case t.ui.keyCode.PAGE_DOWN:n=this._trimAlignValue(s-(this._valueMax()-this._valueMin())/this.numPages);break;case t.ui.keyCode.UP:case t.ui.keyCode.RIGHT:if(s===this._valueMax())return;n=this._trimAlignValue(s+o);break;case t.ui.keyCode.DOWN:case t.ui.keyCode.LEFT:if(s===this._valueMin())return;n=this._trimAlignValue(s-o)}this._slide(e,a,n)},keyup:function(e){var i=t(e.target).data("ui-slider-handle-index");this._keySliding&&(this._keySliding=!1,this._stop(e,i),this._change(e,i),this._removeClass(t(e.target),null,"ui-state-active"))}}}),t.widget("ui.sortable",t.ui.mouse,{version:"1.12.1",widgetEventPrefix:"sort",ready:!1,options:{appendTo:"parent",axis:!1,connectWith:!1,containment:!1,cursor:"auto",cursorAt:!1,dropOnEmpty:!0,forcePlaceholderSize:!1,forceHelperSize:!1,grid:!1,handle:!1,helper:"original",items:"> *",opacity:!1,placeholder:!1,revert:!1,scroll:!0,scrollSensitivity:20,scrollSpeed:20,scope:"default",tolerance:"intersect",zIndex:1e3,activate:null,beforeStop:null,change:null,deactivate:null,out:null,over:null,receive:null,remove:null,sort:null,start:null,stop:null,update:null}
vendor: 5,429 bytes, line 20
20,_isOverAxis:function(t,e,i){return t>=e&&e+i>t},_isFloating:function(t){return/left|right/.test(t.css("float"))||/inline|table-cell/.test(t.css("display"))},_create:function(){this.containerCache={},this._addClass("ui-sortable"),this.refresh(),this.offset=this.element.offset(),this._mouseInit(),this._setHandleClassName(),this.ready=!0},_setOption:function(t,e){this._super(t,e),"handle"===t&&this._setHandleClassName()},_setHandleClassName:function(){var e=this;this._removeClass(this.element.find(".ui-sortable-handle"),"ui-sortable-handle"),t.each(this.items,function(){e._addClass(this.instance.options.handle?this.item.find(this.instance.options.handle):this.item,"ui-sortable-handle")})},_destroy:function(){this._mouseDestroy();for(var t=this.items.length-1;t>=0;t--)this.items[t].item.removeData(this.widgetName+"-item");return this},_mouseCapture:function(e,i){var s=null,n=!1,o=this;return this.reverting?!1:this.options.disabled||"static"===this.options.type?!1:(this._refreshItems(e),t(e.target).parents().each(function(){return t.data(this,o.widgetName+"-item")===o?(s=t(this),!1):void 0}),t.data(e.target,o.widgetName+"-item")===o&&(s=t(e.target)),s?!this.options.handle||i||(t(this.options.handle,s).find("*").addBack().each(function(){this===e.target&&(n=!0)}),n)?(this.currentItem=s,this._removeCurrentsFromItems(),!0):!1:!1)},_mouseStart:function(e,i,s){var n,o,a=this.options;if(this.currentContainer=this,this.refreshPositions(),this.helper=this._createHelper(e),this._cacheHelperProportions(),this._cacheMargins(),this.scrollParent=this.helper.scrollParent(),this.offset=this.currentItem.offset(),this.offset={top:this.offset.top-this.margins.top,left:this.offset.left-this.margins.left},t.extend(this.offset,{click:{left:e.pageX-this.offset.left,top:e.pageY-this.offset.top},parent:this._getParentOffset(),relative:this._getRelativeOffset()}),this.helper.css("position","absolute"),this.cssPosition=this.helper.css("position"),this.originalPosition=this._generatePosition(e),this.originalPageX=e.pageX,this.originalPageY=e.pageY,a.cursorAt&&this._adjustOffsetFromHelper(a.cursorAt),this.domPosition={prev:this.currentItem.prev()[0],parent:this.currentItem.parent()[0]},this.helper[0]!==this.currentItem[0]&&this.currentItem.hide(),this._createPlaceholder(),a.containment&&this._setContainment(),a.cursor&&"auto"!==a.cursor&&(o=this.document.find("body"),this.storedCursor=o.css("cursor"),o.css("cursor",a.cursor),this.storedStylesheet=t("<style>*{ cursor: "+a.cursor+" !important; }</style>").appendTo(o)),a.opacity&&(this.helper.css("opacity")&&(this._storedOpacity=this.helper.css("opacity")),this.helper.css("opacity",a.opacity)),a.zIndex&&(this.helper.css("zIndex")&&(this._storedZIndex=this.helper.css("zIndex")),this.helper.css("zIndex",a.zIndex)),this.scrollParent[0]!==this.document[0]&&"HTML"!==this.scrollParent[0].tagName&&(this.overflowOffset=this.scrollParent.offset()),this._trigger("start",e,this._uiHash()),this._preserveHelperProportions||this._cacheHelperProportions(),!s)for(n=this.containers.length-1;n>=0;n--)this.containers[n]._trigger("activate",e,this._uiHash(this));return t.ui.ddmanager&&(t.ui.ddmanager.current=this),t.ui.ddmanager&&!a.dropBehaviour&&t.ui.ddmanager.prepareOffsets(this,e),this.dragging=!0,this._addClass(this.helper,"ui-sortable-helper"),this._mouseDrag(e),!0},_mouseDrag:function(e){var i,s,n,o,a=this.options,r=!1;for(this.position=this._generatePosition(e),this.positionAbs=this._convertPositionTo("absolute"),this.lastPositionAbs||(this.lastPositionAbs=this.positionAbs),this.options.scroll&&(this.scrollParent[0]!==this.document[0]&&"HTML"!==this.scrollParent[0].tagName?(this.overflowOffset.top+this.scrollParent[0].offsetHeight-e.pageY<a.scrollSensitivity?this.scrollParent[0].scrollTop=r=this.scrollParent[0].scrollTop+a.scrollSpeed:e.pageY-this.overflowOffset.top<a.scrollSensitivity&&(this.scrollParent[0].scrollTop=r=this.scrollParent[0].scrollTop-a.scrollSpeed),this.overflowOffset.left+this.scrollParent[0].offsetWidth-e.pageX<a.scrollSensitivity?this.scrollParent[0].scrollLeft=r=this.scrollParent[0].scrollLeft+a.scrollSpeed:e.pageX-this.overflowOffset.left<a.scrollSensitivity&&(this.scrollParent[0].scrollLeft=r=this.scrollParent[0].scrollLeft-a.scrollSpeed)):(e.pageY-this.document.scrollTop()<a.scrollSensitivity?r=this.document.scrollTop(this.document.scrollTop()-a.scrollSpeed):this.window.height()-(e.pageY-this.document.scrollTop())<a.scrollSensitivity&&(r=this.document.scrollTop(this.document.scrollTop()+a.scrollSpeed)),e.pageX-this.document.scrollLeft()<a.scrollSensitivity?r=this.document.scrollLeft(this.document.scrollLeft()-a.scrollSpeed):this.window.width()-(e.pageX-this.document.scrollLeft())<a.scrollSensitivity&&(r=this.document.scrollLeft(this.document.scrollLeft()+a.scrollSpeed))),r!==!1&&t.ui.ddmanager&&!a.dropBehaviour&&t.ui.ddmanager.prepareOffsets(this,e)),this.positionAbs=this._convertPositionTo("absolute"),this.options.axis&&"y"===this.options.axis||(this.helper[0].style.left=this.position.left+"px"),this.options.axis&&"x"===this.options.axis||(this.helper[0].style.top=this.position.top+"px"),i=this.items.length-1;i>=0;i--)if(s=this.items[i],n=s.item[0],o=this._intersectsWithPointer(s),o&&s.instance===this.currentContainer&&n!==this.currentItem[0]&&this.placeholder[1===o?"next":"prev"]()[0]!==n&&!t.contains(this.placeholder[0],n)&&("semi-dynamic"===this.options.type?!t.contains(this.element[0],n):!0)){if
vendor: 4,213 bytes, line 20
20(this.direction=1===o?"down":"up","pointer"!==this.options.tolerance&&!this._intersectsWithSides(s))break;this._rearrange(e,s),this._trigger("change",e,this._uiHash());break}return this._contactContainers(e),t.ui.ddmanager&&t.ui.ddmanager.drag(this,e),this._trigger("sort",e,this._uiHash()),this.lastPositionAbs=this.positionAbs,!1},_mouseStop:function(e,i){if(e){if(t.ui.ddmanager&&!this.options.dropBehaviour&&t.ui.ddmanager.drop(this,e),this.options.revert){var s=this,n=this.placeholder.offset(),o=this.options.axis,a={};o&&"x"!==o||(a.left=n.left-this.offset.parent.left-this.margins.left+(this.offsetParent[0]===this.document[0].body?0:this.offsetParent[0].scrollLeft)),o&&"y"!==o||(a.top=n.top-this.offset.parent.top-this.margins.top+(this.offsetParent[0]===this.document[0].body?0:this.offsetParent[0].scrollTop)),this.reverting=!0,t(this.helper).animate(a,parseInt(this.options.revert,10)||500,function(){s._clear(e)})}else this._clear(e,i);return!1}},cancel:function(){if(this.dragging){this._mouseUp(new t.Event("mouseup",{target:null})),"original"===this.options.helper?(this.currentItem.css(this._storedCSS),this._removeClass(this.currentItem,"ui-sortable-helper")):this.currentItem.show();for(var e=this.containers.length-1;e>=0;e--)this.containers[e]._trigger("deactivate",null,this._uiHash(this)),this.containers[e].containerCache.over&&(this.containers[e]._trigger("out",null,this._uiHash(this)),this.containers[e].containerCache.over=0)}return this.placeholder&&(this.placeholder[0].parentNode&&this.placeholder[0].parentNode.removeChild(this.placeholder[0]),"original"!==this.options.helper&&this.helper&&this.helper[0].parentNode&&this.helper.remove(),t.extend(this,{helper:null,dragging:!1,reverting:!1,_noFinalSort:null}),this.domPosition.prev?t(this.domPosition.prev).after(this.currentItem):t(this.domPosition.parent).prepend(this.currentItem)),this},serialize:function(e){var i=this._getItemsAsjQuery(e&&e.connected),s=[];return e=e||{},t(i).each(function(){var i=(t(e.item||this).attr(e.attribute||"id")||"").match(e.expression||/(.+)[\-=_](.+)/);i&&s.push((e.key||i[1]+"[]")+"="+(e.key&&e.expression?i[1]:i[2]))}),!s.length&&e.key&&s.push(e.key+"="),s.join("&")},toArray:function(e){var i=this._getItemsAsjQuery(e&&e.connected),s=[];return e=e||{},i.each(function(){s.push(t(e.item||this).attr(e.attribute||"id")||"")}),s},_intersectsWith:function(t){var e=this.positionAbs.left,i=e+this.helperProportions.width,s=this.positionAbs.top,n=s+this.helperProportions.height,o=t.left,a=o+t.width,r=t.top,h=r+t.height,l=this.offset.click.top,c=this.offset.click.left,u="x"===this.options.axis||s+l>r&&h>s+l,d="y"===this.options.axis||e+c>o&&a>e+c,p=u&&d;return"pointer"===this.options.tolerance||this.options.forcePointerForContainers||"pointer"!==this.options.tolerance&&this.helperProportions[this.floating?"width":"height"]>t[this.floating?"width":"height"]?p:e+this.helperProportions.width/2>o&&a>i-this.helperProportions.width/2&&s+this.helperProportions.height/2>r&&h>n-this.helperProportions.height/2},_intersectsWithPointer:function(t){var e,i,s="x"===this.options.axis||this._isOverAxis(this.positionAbs.top+this.offset.click.top,t.top,t.height),n="y"===this.options.axis||this._isOverAxis(this.positionAbs.left+this.offset.click.left,t.left,t.width),o=s&&n;return o?(e=this._getDragVerticalDirection(),i=this._getDragHorizontalDirection(),this.floating?"right"===i||"down"===e?2:1:e&&("down"===e?2:1)):!1},_intersectsWithSides:function(t){var e=this._isOverAxis(this.positionAbs.top+this.offset.click.top,t.top+t.height/2,t.height),i=this._isOverAxis(this.positionAbs.left+this.offset.click.left,t.left+t.width/2,t.width),s=this._getDragVerticalDirection(),n=this._getDragHorizontalDirection();return this.floating&&n?"right"===n&&i||"left"===n&&!i:s&&("down"===s&&e||"up"===s&&!e)},_getDragVerticalDirection:function(){var t=this.positionAbs.top-this.lastPositionAbs.top;return 0!==t&&(t>0?"down":"up")},_getDragHorizontalDirection:function(){var t=this.positionAbs.left-this.lastPositionAbs.left;return 0!==t&&(t>0?"right":"left")},refresh:function(t){return this._refreshItems(t),this._setHandleClassName(),this.refreshPositions(),this},_connectWith:function(){var t=this.options;
vendor: 2,278 bytes, line 20
20return t.connectWith.constructor===String?[t.connectWith]:t.connectWith},_getItemsAsjQuery:function(e){function i(){r.push(this)}var s,n,o,a,r=[],h=[],l=this._connectWith();if(l&&e)for(s=l.length-1;s>=0;s--)for(o=t(l[s],this.document[0]),n=o.length-1;n>=0;n--)a=t.data(o[n],this.widgetFullName),a&&a!==this&&!a.options.disabled&&h.push([t.isFunction(a.options.items)?a.options.items.call(a.element):t(a.options.items,a.element).not(".ui-sortable-helper").not(".ui-sortable-placeholder"),a]);for(h.push([t.isFunction(this.options.items)?this.options.items.call(this.element,null,{options:this.options,item:this.currentItem}):t(this.options.items,this.element).not(".ui-sortable-helper").not(".ui-sortable-placeholder"),this]),s=h.length-1;s>=0;s--)h[s][0].each(i);return t(r)},_removeCurrentsFromItems:function(){var e=this.currentItem.find(":data("+this.widgetName+"-item)");this.items=t.grep(this.items,function(t){for(var i=0;e.length>i;i++)if(e[i]===t.item[0])return!1;return!0})},_refreshItems:function(e){this.items=[],this.containers=[this];var i,s,n,o,a,r,h,l,c=this.items,u=[[t.isFunction(this.options.items)?this.options.items.call(this.element[0],e,{item:this.currentItem}):t(this.options.items,this.element),this]],d=this._connectWith();if(d&&this.ready)for(i=d.length-1;i>=0;i--)for(n=t(d[i],this.document[0]),s=n.length-1;s>=0;s--)o=t.data(n[s],this.widgetFullName),o&&o!==this&&!o.options.disabled&&(u.push([t.isFunction(o.options.items)?o.options.items.call(o.element[0],e,{item:this.currentItem}):t(o.options.items,o.element),o]),this.containers.push(o));for(i=u.length-1;i>=0;i--)for(a=u[i][1],r=u[i][0],s=0,l=r.length;l>s;s++)h=t(r[s]),h.data(this.widgetName+"-item",a),c.push({item:h,instance:a,width:0,height:0,left:0,top:0})},refreshPositions:function(e){this.floating=this.items.length?"x"===this.options.axis||this._isFloating(this.items[0].item):!1,this.offsetParent&&this.helper&&(this.offset.parent=this._getParentOffset());var i,s,n,o;for(i=this.items.length-1;i>=0;i--)s=this.items[i],s.instance!==this.currentContainer&&this.currentContainer&&s.item[0]!==this.currentItem[0]||(n=this.options.toleranceElement?t(this.options.toleranceElement,s.item):s.item,e||(s.width=n.outerWidth(),s.height=n.outerHeight()),o=n.offset(),s.left=o.left,s.top=o.top);
vendor: 1,142 bytes, line 20
20if(this.options.custom&&this.options.custom.refreshContainers)this.options.custom.refreshContainers.call(this);else for(i=this.containers.length-1;i>=0;i--)o=this.containers[i].element.offset(),this.containers[i].containerCache.left=o.left,this.containers[i].containerCache.top=o.top,this.containers[i].containerCache.width=this.containers[i].element.outerWidth(),this.containers[i].containerCache.height=this.containers[i].element.outerHeight();return this},_createPlaceholder:function(e){e=e||this;var i,s=e.options;s.placeholder&&s.placeholder.constructor!==String||(i=s.placeholder,s.placeholder={element:function(){var s=e.currentItem[0].nodeName.toLowerCase(),n=t("<"+s+">",e.document[0]);return e._addClass(n,"ui-sortable-placeholder",i||e.currentItem[0].className)._removeClass(n,"ui-sortable-helper"),"tbody"===s?e._createTrPlaceholder(e.currentItem.find("tr").eq(0),t("<tr>",e.document[0]).appendTo(n)):"tr"===s?e._createTrPlaceholder(e.currentItem,n):"img"===s&&n.attr("src",e.currentItem.attr("src")),i||n.css("visibility","hidden"),n},update:function(t,n){(!i||s.forcePlaceholderSize)&&(n.height()||n.height(e.currentItem.innerHe
vendor: 8,546 bytes, line 20
20ight()-parseInt(e.currentItem.css("paddingTop")||0,10)-parseInt(e.currentItem.css("paddingBottom")||0,10)),n.width()||n.width(e.currentItem.innerWidth()-parseInt(e.currentItem.css("paddingLeft")||0,10)-parseInt(e.currentItem.css("paddingRight")||0,10)))}}),e.placeholder=t(s.placeholder.element.call(e.element,e.currentItem)),e.currentItem.after(e.placeholder),s.placeholder.update(e,e.placeholder)},_createTrPlaceholder:function(e,i){var s=this;e.children().each(function(){t("<td> </td>",s.document[0]).attr("colspan",t(this).attr("colspan")||1).appendTo(i)})},_contactContainers:function(e){var i,s,n,o,a,r,h,l,c,u,d=null,p=null;for(i=this.containers.length-1;i>=0;i--)if(!t.contains(this.currentItem[0],this.containers[i].element[0]))if(this._intersectsWith(this.containers[i].containerCache)){if(d&&t.contains(this.containers[i].element[0],d.element[0]))continue;d=this.containers[i],p=i}else this.containers[i].containerCache.over&&(this.containers[i]._trigger("out",e,this._uiHash(this)),this.containers[i].containerCache.over=0);if(d)if(1===this.containers.length)this.containers[p].containerCache.over||(this.containers[p]._trigger("over",e,this._uiHash(this)),this.containers[p].containerCache.over=1);else{for(n=1e4,o=null,c=d.floating||this._isFloating(this.currentItem),a=c?"left":"top",r=c?"width":"height",u=c?"pageX":"pageY",s=this.items.length-1;s>=0;s--)t.contains(this.containers[p].element[0],this.items[s].item[0])&&this.items[s].item[0]!==this.currentItem[0]&&(h=this.items[s].item.offset()[a],l=!1,e[u]-h>this.items[s][r]/2&&(l=!0),n>Math.abs(e[u]-h)&&(n=Math.abs(e[u]-h),o=this.items[s],this.direction=l?"up":"down"));if(!o&&!this.options.dropOnEmpty)return;if(this.currentContainer===this.containers[p])return this.currentContainer.containerCache.over||(this.containers[p]._trigger("over",e,this._uiHash()),this.currentContainer.containerCache.over=1),void 0;o?this._rearrange(e,o,null,!0):this._rearrange(e,null,this.containers[p].element,!0),this._trigger("change",e,this._uiHash()),this.containers[p]._trigger("change",e,this._uiHash(this)),this.currentContainer=this.containers[p],this.options.placeholder.update(this.currentContainer,this.placeholder),this.containers[p]._trigger("over",e,this._uiHash(this)),this.containers[p].containerCache.over=1}},_createHelper:function(e){var i=this.options,s=t.isFunction(i.helper)?t(i.helper.apply(this.element[0],[e,this.currentItem])):"clone"===i.helper?this.currentItem.clone():this.currentItem;return s.parents("body").length||t("parent"!==i.appendTo?i.appendTo:this.currentItem[0].parentNode)[0].appendChild(s[0]),s[0]===this.currentItem[0]&&(this._storedCSS={width:this.currentItem[0].style.width,height:this.currentItem[0].style.height,position:this.currentItem.css("position"),top:this.currentItem.css("top"),left:this.currentItem.css("left")}),(!s[0].style.width||i.forceHelperSize)&&s.width(this.currentItem.width()),(!s[0].style.height||i.forceHelperSize)&&s.height(this.currentItem.height()),s},_adjustOffsetFromHelper:function(e){"string"==typeof e&&(e=e.split(" ")),t.isArray(e)&&(e={left:+e[0],top:+e[1]||0}),"left"in e&&(this.offset.click.left=e.left+this.margins.left),"right"in e&&(this.offset.click.left=this.helperProportions.width-e.right+this.margins.left),"top"in e&&(this.offset.click.top=e.top+this.margins.top),"bottom"in e&&(this.offset.click.top=this.helperProportions.height-e.bottom+this.margins.top)},_getParentOffset:function(){this.offsetParent=this.helper.offsetParent();var e=this.offsetParent.offset();return"absolute"===this.cssPosition&&this.scrollParent[0]!==this.document[0]&&t.contains(this.scrollParent[0],this.offsetParent[0])&&(e.left+=this.scrollParent.scrollLeft(),e.top+=this.scrollParent.scrollTop()),(this.offsetParent[0]===this.document[0].body||this.offsetParent[0].tagName&&"html"===this.offsetParent[0].tagName.toLowerCase()&&t.ui.ie)&&(e={top:0,left:0}),{top:e.top+(parseInt(this.offsetParent.css("borderTopWidth"),10)||0),left:e.left+(parseInt(this.offsetParent.css("borderLeftWidth"),10)||0)}},_getRelativeOffset:function(){if("relative"===this.cssPosition){var t=this.currentItem.position();return{top:t.top-(parseInt(this.helper.css("top"),10)||0)+this.scrollParent.scrollTop(),left:t.left-(parseInt(this.helper.css("left"),10)||0)+this.scrollParent.scrollLeft()}}return{top:0,left:0}},_cacheMargins:function(){this.margins={left:parseInt(this.currentItem.css("marginLeft"),10)||0,top:parseInt(this.currentItem.css("marginTop"),10)||0}},_cacheHelperProportions:function(){this.helperProportions={width:this.helper.outerWidth(),height:this.helper.outerHeight()}},_setContainment:function(){var e,i,s,n=this.options;"parent"===n.containment&&(n.containment=this.helper[0].parentNode),("document"===n.containment||"window"===n.containment)&&(this.containment=[0-this.offset.relative.left-this.offset.parent.left,0-this.offset.relative.top-this.offset.parent.top,"document"===n.containment?this.document.width():this.window.width()-this.helperProportions.width-this.margins.left,("document"===n.containment?this.document.height()||document.body.parentNode.scrollHeight:this.window.height()||this.document[0].body.parentNode.scrollHeight)-this.helperProportions.height-this.margins.top]),/^(document|window|parent)$/.test(n.containment)||(e=t(n.containment)[0],i=t(n.containment).offset(),s="hidden"!==t(e).css("overflow"),this.containment=[i.left+(parseInt(t(e).css("borderLeftWidth"),10)||0)+(parseInt(t(e).css("paddingLeft"),10)||0)-this.margins.left,i.top+(parseInt(t(e).css("borderTopWidth"),10)||0)+(parseInt(t(e).css("paddingTop"),10)||0)-this.margins.top,i.left+(s?Math.max(e.scrollWidth,e.offsetWidth):e.offsetWidth)-(parseInt(t(e).css("borderLeftWidth"),10)||0)-(parseInt(t(e).css("paddingRight"),10)||0)-this.helperProportions.width-this.margins.left,i.top+(s?Math.max(e.scrollHeight,e.offsetHeight):e.offsetHeight)-(parseInt(t(e).css("borderTopWidth"),10)||0)-(parseInt(t(e).css("paddingBottom"),10)||0)-this.helperProportions.height-this.margins.top])},_convertPositionTo:function(e,i){i||(i=this.position);var s="absolute"===e?1:-1,n="absolute"!==this.cssPosition||this.scrollParent[0]!==this.document[0]&&t.contains(this.scrollParent[0],this.offsetParent[0])?this.scrollParent:this.offsetParent,o=/(html|body)/i.test(n[0].tagName);return{top:i.top+this.offset.relative.top*s+this.offset.parent.top*s-("fixed"===this.cssPosition?-this.scrollParent.scrollTop():o?0:n.scrollTop())*s,left:i.left+this.offset.relative.left*s+this.offset.parent.left*s-("fixed"===this.cssPosition?-this.scrollParent.scrollLeft():o?0:n.scrollLeft())*s}},_generatePosition:function(e){var i,s,n=this.options,o=e.pageX,a=e.pageY,r="absolute"!==this.cssPosition||this.scrollParent[0]!==this.document[0]&&t.contains(this.scrollParent[0],this.offsetParent[0])?this.scrollParent:this.offsetParent,h=/(html|body)/i.test(r[0].tagName);return"relative"!==this.cssPosition||this.scrollParent[0]!==this.document[0]&&this.scrollParent[0]!==this.offsetParent[0]||(this.offset.relative=this._getRelativeOffset()),this.originalPosition&&(this.containment&&(e.pageX-this.offset.click.left<this.containment[0]&&(o=this.containment[0]+this.offset.click.left),e.pageY-this.offset.click.top<this.containment[1]&&(a=this.containment[1]+this.offset.click.top),e.pageX-this.offset.click.left>this.containment[2]&&(o=this.containment[2]+this.offset.click.left),e.pageY-this.offset.click.top>this.containment[3]&&(a=this.containment[3]+this.offset.click.top)),n.grid&&(i=this.originalPageY+Math.round((a-this.originalPageY)/n.grid[1])*n.grid[1],a=this.containment?i-this.offset.click.top>=this.containment[1]&&i-this.offset.click.top<=this.containment[3]?i:i-this.offset.click.top>=this.containment[1]?i-n.grid[1]:i+n.grid[1]:i,s=this.originalPageX+Math.round((o-this.originalPageX)/n.grid[0])*n.grid[0],o=this.containment?s-this.offset.click.left>=this.containment[0]&&s-this.offset.click.left<=this.containment[2]?s:s-this.offset.click.left>=this.containment[0]?s-n.grid[0]:s+n.grid[0]:s)),{top:a-this.offset.click.top-this.offset.relative.top-this.offset.parent.top+("fixed"===this.cssPosition?-this.scrollParent.scrollTop():h?0:r.scrollTop()),left:o-this.offset.click.left-this.offset.relative.left-this.offset.parent.left+("fixed"===this.cssPosition?-this.scrollParent.scrollLeft():h?0:r.scrollLeft())}},_rearrange:function(t,e,i,s){i?i[0].appendChild(this.placeholder[0]):e.item[0].parentNode.insertBefore(this.placeholder[0],"down"===this.direction?e.item[0]:e.item[0].nextSibling),this.counter=this.counter?++this.counter:1;var n=this.counter;
vendor: 2,446 bytes, lines 20-21
20 21 this._delay(function(){n===this.counter&&this.refreshPositions(!s)})},_clear:function(t,e){function i(t,e,i){return function(s){i._trigger(t,s,e._uiHash(e))}}this.reverting=!1;var s,n=[];if(!this._noFinalSort&&this.currentItem.parent().length&&this.placeholder.before(this.currentItem),this._noFinalSort=null,this.helper[0]===this.currentItem[0]){for(s in this._storedCSS)("auto"===this._storedCSS[s]||"static"===this._storedCSS[s])&&(this._storedCSS[s]="");this.currentItem.css(this._storedCSS),this._removeClass(this.currentItem,"ui-sortable-helper")}else this.currentItem.show();for(this.fromOutside&&!e&&n.push(function(t){this._trigger("receive",t,this._uiHash(this.fromOutside))}),!this.fromOutside&&this.domPosition.prev===this.currentItem.prev().not(".ui-sortable-helper")[0]&&this.domPosition.parent===this.currentItem.parent()[0]||e||n.push(function(t){this._trigger("update",t,this._uiHash())}),this!==this.currentContainer&&(e||(n.push(function(t){this._trigger("remove",t,this._uiHash())}),n.push(function(t){return function(e){t._trigger("receive",e,this._uiHash(this))}}.call(this,this.currentContainer)),n.push(function(t){return function(e){t._trigger("update",e,this._uiHash(this))}}.call(this,this.currentContainer)))),s=this.containers.length-1;s>=0;s--)e||n.push(i("deactivate",this,this.containers[s])),this.containers[s].containerCache.over&&(n.push(i("out",this,this.containers[s])),this.containers[s].containerCache.over=0);if(this.storedCursor&&(this.document.find("body").css("cursor",this.storedCursor),this.storedStylesheet.remove()),this._storedOpacity&&this.helper.css("opacity",this._storedOpacity),this._storedZIndex&&this.helper.css("zIndex","auto"===this._storedZIndex?"":this._storedZIndex),this.dragging=!1,e||this._trigger("beforeStop",t,this._uiHash()),this.placeholder[0].parentNode.removeChild(this.placeholder[0]),this.cancelHelperRemoval||(this.helper[0]!==this.currentItem[0]&&this.helper.remove(),this.helper=null),!e){for(s=0;n.length>s;s++)n[s].call(this,t);this._trigger("stop",t,this._uiHash())}return this.fromOutside=!1,!this.cancelHelperRemoval},_trigger:function(){t.Widget.prototype._trigger.apply(this,arguments)===!1&&this.cancel()},_uiHash:function(e){var i=e||this;return{helper:i.helper,placeholder:i.placeholder||t([]),position:i.position,originalPosition:i.originalPosition,offset:i.positionAbs,item:i.currentItem,sender:e?e.element:null}}}),t.widget("ui.spinner",{version:"1.12.1
vendor: 6,813 bytes, line 21
21",defaultElement:"<input>",widgetEventPrefix:"spin",options:{classes:{"ui-spinner":"ui-corner-all","ui-spinner-down":"ui-corner-br","ui-spinner-up":"ui-corner-tr"},culture:null,icons:{down:"ui-icon-triangle-1-s",up:"ui-icon-triangle-1-n"},incremental:!0,max:null,min:null,numberFormat:null,page:10,step:1,change:null,spin:null,start:null,stop:null},_create:function(){this._setOption("max",this.options.max),this._setOption("min",this.options.min),this._setOption("step",this.options.step),""!==this.value()&&this._value(this.element.val(),!0),this._draw(),this._on(this._events),this._refresh(),this._on(this.window,{beforeunload:function(){this.element.removeAttr("autocomplete")}})},_getCreateOptions:function(){var e=this._super(),i=this.element;return t.each(["min","max","step"],function(t,s){var n=i.attr(s);null!=n&&n.length&&(e[s]=n)}),e},_events:{keydown:function(t){this._start(t)&&this._keydown(t)&&t.preventDefault()},keyup:"_stop",focus:function(){this.previous=this.element.val()},blur:function(t){return this.cancelBlur?(delete this.cancelBlur,void 0):(this._stop(),this._refresh(),this.previous!==this.element.val()&&this._trigger("change",t),void 0)},mousewheel:function(t,e){if(e){if(!this.spinning&&!this._start(t))return!1;this._spin((e>0?1:-1)*this.options.step,t),clearTimeout(this.mousewheelTimer),this.mousewheelTimer=this._delay(function(){this.spinning&&this._stop(t)},100),t.preventDefault()}},"mousedown .ui-spinner-button":function(e){function i(){var e=this.element[0]===t.ui.safeActiveElement(this.document[0]);e||(this.element.trigger("focus"),this.previous=s,this._delay(function(){this.previous=s}))}var s;s=this.element[0]===t.ui.safeActiveElement(this.document[0])?this.previous:this.element.val(),e.preventDefault(),i.call(this),this.cancelBlur=!0,this._delay(function(){delete this.cancelBlur,i.call(this)}),this._start(e)!==!1&&this._repeat(null,t(e.currentTarget).hasClass("ui-spinner-up")?1:-1,e)},"mouseup .ui-spinner-button":"_stop","mouseenter .ui-spinner-button":function(e){return t(e.currentTarget).hasClass("ui-state-active")?this._start(e)===!1?!1:(this._repeat(null,t(e.currentTarget).hasClass("ui-spinner-up")?1:-1,e),void 0):void 0},"mouseleave .ui-spinner-button":"_stop"},_enhance:function(){this.uiSpinner=this.element.attr("autocomplete","off").wrap("<span>").parent().append("<a></a><a></a>")},_draw:function(){this._enhance(),this._addClass(this.uiSpinner,"ui-spinner","ui-widget ui-widget-content"),this._addClass("ui-spinner-input"),this.element.attr("role","spinbutton"),this.buttons=this.uiSpinner.children("a").attr("tabIndex",-1).attr("aria-hidden",!0).button({classes:{"ui-button":""}}),this._removeClass(this.buttons,"ui-corner-all"),this._addClass(this.buttons.first(),"ui-spinner-button ui-spinner-up"),this._addClass(this.buttons.last(),"ui-spinner-button ui-spinner-down"),this.buttons.first().button({icon:this.options.icons.up,showLabel:!1}),this.buttons.last().button({icon:this.options.icons.down,showLabel:!1}),this.buttons.height()>Math.ceil(.5*this.uiSpinner.height())&&this.uiSpinner.height()>0&&this.uiSpinner.height(this.uiSpinner.height())},_keydown:function(e){var i=this.options,s=t.ui.keyCode;switch(e.keyCode){case s.UP:return this._repeat(null,1,e),!0;case s.DOWN:return this._repeat(null,-1,e),!0;case s.PAGE_UP:return this._repeat(null,i.page,e),!0;case s.PAGE_DOWN:return this._repeat(null,-i.page,e),!0}return!1},_start:function(t){return this.spinning||this._trigger("start",t)!==!1?(this.counter||(this.counter=1),this.spinning=!0,!0):!1},_repeat:function(t,e,i){t=t||500,clearTimeout(this.timer),this.timer=this._delay(function(){this._repeat(40,e,i)},t),this._spin(e*this.options.step,i)},_spin:function(t,e){var i=this.value()||0;this.counter||(this.counter=1),i=this._adjustValue(i+t*this._increment(this.counter)),this.spinning&&this._trigger("spin",e,{value:i})===!1||(this._value(i),this.counter++)},_increment:function(e){var i=this.options.incremental;return i?t.isFunction(i)?i(e):Math.floor(e*e*e/5e4-e*e/500+17*e/200+1):1},_precision:function(){var t=this._precisionOf(this.options.step);return null!==this.options.min&&(t=Math.max(t,this._precisionOf(this.options.min))),t},_precisionOf:function(t){var e=""+t,i=e.indexOf(".");return-1===i?0:e.length-i-1},_adjustValue:function(t){var e,i,s=this.options;return e=null!==s.min?s.min:0,i=t-e,i=Math.round(i/s.step)*s.step,t=e+i,t=parseFloat(t.toFixed(this._precision())),null!==s.max&&t>s.max?s.max:null!==s.min&&s.min>t?s.min:t},_stop:function(t){this.spinning&&(clearTimeout(this.timer),clearTimeout(this.mousewheelTimer),this.counter=0,this.spinning=!1,this._trigger("stop",t))},_setOption:function(t,e){var i,s,n;return"culture"===t||"numberFormat"===t?(i=this._parse(this.element.val()),this.options[t]=e,this.element.val(this._format(i)),void 0):(("max"===t||"min"===t||"step"===t)&&"string"==typeof e&&(e=this._parse(e)),"icons"===t&&(s=this.buttons.first().find(".ui-icon"),this._removeClass(s,null,this.options.icons.up),this._addClass(s,null,e.up),n=this.buttons.last().find(".ui-icon"),this._removeClass(n,null,this.options.icons.down),this._addClass(n,null,e.down)),this._super(t,e),void 0)},_setOptionDisabled:function(t){this._super(t),this._toggleClass(this.uiSpinner,null,"ui-state-disabled",!!t),this.element.prop("disabled",!!t),this.buttons.button(t?"disable":"enable")},_setOptions:r(function(t){this._super(t)}),_parse:function(t){return"string"==typeof t&&""!==t&&(t=window.Globalize&&this.options.numberFormat?Globalize.parseFloat(t,10,this.options.culture):+t),""===t||isNaN(t)?null:t},_format:function(t){return""===t?"":window.Globalize&&this.options.numberFormat?Globalize.format(t,this.options.numberFormat,this.options.culture):t},_refresh:function(){this.element.attr({"aria-valuemin":this.options.min,"aria-valuemax":this.options.max,"aria-valuenow":this._parse(this.element.val())})},isValid:function(){var t=this.value();return null===t?!1:t===this._adjustValue(t)},_value:function(t,e){var i;""!==t&&(i=this._parse(t),null!==i&&(e||(i=this._adjustValue(i)),t=this._format(i))),this.element.val(t),this._refresh()},_destroy:function(){this.element.prop("disabled",!1).removeAttr("autocomplete role aria-valuemin aria-valuemax aria-valuenow"),this.uiSpinner.replaceWith(this.element)},stepUp:r(function(t){this._stepUp(t)}),_stepUp:function(t){this._start()&&(this._spin((t||1)*this.options.step),this._stop())},stepDown:r(function(t){this._stepDown(t)}),_stepDown:function(t){this._start()&&(this._spin((t||1)*-this.options.step),this._stop())},pageUp:r(function(t){this._stepUp((t||1)*this.options.page)}),pageDown:r(function(t){this._stepDown((t||1)*this.options.page)}),value:function(t){return arguments.length?(r(this._value).call(this,t),void 0):this._parse(this.element.val())},widget:function(){return this.uiSpinner}}
vendor: 17,899 bytes, line 21
21),t.uiBackCompat!==!1&&t.widget("ui.spinner",t.ui.spinner,{_enhance:function(){this.uiSpinner=this.element.attr("autocomplete","off").wrap(this._uiSpinnerHtml()).parent().append(this._buttonHtml())},_uiSpinnerHtml:function(){return"<span>"},_buttonHtml:function(){return"<a></a><a></a>"}}),t.ui.spinner,t.widget("ui.tabs",{version:"1.12.1",delay:300,options:{active:null,classes:{"ui-tabs":"ui-corner-all","ui-tabs-nav":"ui-corner-all","ui-tabs-panel":"ui-corner-bottom","ui-tabs-tab":"ui-corner-top"},collapsible:!1,event:"click",heightStyle:"content",hide:null,show:null,activate:null,beforeActivate:null,beforeLoad:null,load:null},_isLocal:function(){var t=/#.*$/;return function(e){var i,s;i=e.href.replace(t,""),s=location.href.replace(t,"");try{i=decodeURIComponent(i)}catch(n){}try{s=decodeURIComponent(s)}catch(n){}return e.hash.length>1&&i===s}}(),_create:function(){var e=this,i=this.options;this.running=!1,this._addClass("ui-tabs","ui-widget ui-widget-content"),this._toggleClass("ui-tabs-collapsible",null,i.collapsible),this._processTabs(),i.active=this._initialActive(),t.isArray(i.disabled)&&(i.disabled=t.unique(i.disabled.concat(t.map(this.tabs.filter(".ui-state-disabled"),function(t){return e.tabs.index(t)}))).sort()),this.active=this.options.active!==!1&&this.anchors.length?this._findActive(i.active):t(),this._refresh(),this.active.length&&this.load(i.active)},_initialActive:function(){var e=this.options.active,i=this.options.collapsible,s=location.hash.substring(1);return null===e&&(s&&this.tabs.each(function(i,n){return t(n).attr("aria-controls")===s?(e=i,!1):void 0}),null===e&&(e=this.tabs.index(this.tabs.filter(".ui-tabs-active"))),(null===e||-1===e)&&(e=this.tabs.length?0:!1)),e!==!1&&(e=this.tabs.index(this.tabs.eq(e)),-1===e&&(e=i?!1:0)),!i&&e===!1&&this.anchors.length&&(e=0),e},_getCreateEventData:function(){return{tab:this.active,panel:this.active.length?this._getPanelForTab(this.active):t()}},_tabKeydown:function(e){var i=t(t.ui.safeActiveElement(this.document[0])).closest("li"),s=this.tabs.index(i),n=!0;if(!this._handlePageNav(e)){switch(e.keyCode){case t.ui.keyCode.RIGHT:case t.ui.keyCode.DOWN:s++;break;case t.ui.keyCode.UP:case t.ui.keyCode.LEFT:n=!1,s--;break;case t.ui.keyCode.END:s=this.anchors.length-1;break;case t.ui.keyCode.HOME:s=0;break;case t.ui.keyCode.SPACE:return e.preventDefault(),clearTimeout(this.activating),this._activate(s),void 0;case t.ui.keyCode.ENTER:return e.preventDefault(),clearTimeout(this.activating),this._activate(s===this.options.active?!1:s),void 0;default:return}e.preventDefault(),clearTimeout(this.activating),s=this._focusNextTab(s,n),e.ctrlKey||e.metaKey||(i.attr("aria-selected","false"),this.tabs.eq(s).attr("aria-selected","true"),this.activating=this._delay(function(){this.option("active",s)},this.delay))}},_panelKeydown:function(e){this._handlePageNav(e)||e.ctrlKey&&e.keyCode===t.ui.keyCode.UP&&(e.preventDefault(),this.active.trigger("focus"))},_handlePageNav:function(e){return e.altKey&&e.keyCode===t.ui.keyCode.PAGE_UP?(this._activate(this._focusNextTab(this.options.active-1,!1)),!0):e.altKey&&e.keyCode===t.ui.keyCode.PAGE_DOWN?(this._activate(this._focusNextTab(this.options.active+1,!0)),!0):void 0},_findNextTab:function(e,i){function s(){return e>n&&(e=0),0>e&&(e=n),e}for(var n=this.tabs.length-1;-1!==t.inArray(s(),this.options.disabled);)e=i?e+1:e-1;return e},_focusNextTab:function(t,e){return t=this._findNextTab(t,e),this.tabs.eq(t).trigger("focus"),t},_setOption:function(t,e){return"active"===t?(this._activate(e),void 0):(this._super(t,e),"collapsible"===t&&(this._toggleClass("ui-tabs-collapsible",null,e),e||this.options.active!==!1||this._activate(0)),"event"===t&&this._setupEvents(e),"heightStyle"===t&&this._setupHeightStyle(e),void 0)},_sanitizeSelector:function(t){return t?t.replace(/[!"$%&'()*+,.\/:;<=>?@\[\]\^`{|}~]/g,"\\$&"):""},refresh:function(){var e=this.options,i=this.tablist.children(":has(a[href])");e.disabled=t.map(i.filter(".ui-state-disabled"),function(t){return i.index(t)}),this._processTabs(),e.active!==!1&&this.anchors.length?this.active.length&&!t.contains(this.tablist[0],this.active[0])?this.tabs.length===e.disabled.length?(e.active=!1,this.active=t()):this._activate(this._findNextTab(Math.max(0,e.active-1),!1)):e.active=this.tabs.index(this.active):(e.active=!1,this.active=t()),this._refresh()},_refresh:function(){this._setOptionDisabled(this.options.disabled),this._setupEvents(this.options.event),this._setupHeightStyle(this.options.heightStyle),this.tabs.not(this.active).attr({"aria-selected":"false","aria-expanded":"false",tabIndex:-1}),this.panels.not(this._getPanelForTab(this.active)).hide().attr({"aria-hidden":"true"}),this.active.length?(this.active.attr({"aria-selected":"true","aria-expanded":"true",tabIndex:0}),this._addClass(this.active,"ui-tabs-active","ui-state-active"),this._getPanelForTab(this.active).show().attr({"aria-hidden":"false"})):this.tabs.eq(0).attr("tabIndex",0)},_processTabs:function(){var e=this,i=this.tabs,s=this.anchors,n=this.panels;this.tablist=this._getList().attr("role","tablist"),this._addClass(this.tablist,"ui-tabs-nav","ui-helper-reset ui-helper-clearfix ui-widget-header"),this.tablist.on("mousedown"+this.eventNamespace,"> li",function(e){t(this).is(".ui-state-disabled")&&e.preventDefault()}).on("focus"+this.eventNamespace,".ui-tabs-anchor",function(){t(this).closest("li").is(".ui-state-disabled")&&this.blur()}),this.tabs=this.tablist.find("> li:has(a[href])").attr({role:"tab",tabIndex:-1}),this._addClass(this.tabs,"ui-tabs-tab","ui-state-default"),this.anchors=this.tabs.map(function(){return t("a",this)[0]}).attr({role:"presentation",tabIndex:-1}),this._addClass(this.anchors,"ui-tabs-anchor"),this.panels=t(),this.anchors.each(function(i,s){var n,o,a,r=t(s).uniqueId().attr("id"),h=t(s).closest("li"),l=h.attr("aria-controls");e._isLocal(s)?(n=s.hash,a=n.substring(1),o=e.element.find(e._sanitizeSelector(n))):(a=h.attr("aria-controls")||t({}).uniqueId()[0].id,n="#"+a,o=e.element.find(n),o.length||(o=e._createPanel(a),o.insertAfter(e.panels[i-1]||e.tablist)),o.attr("aria-live","polite")),o.length&&(e.panels=e.panels.add(o)),l&&h.data("ui-tabs-aria-controls",l),h.attr({"aria-controls":a,"aria-labelledby":r}),o.attr("aria-labelledby",r)}),this.panels.attr("role","tabpanel"),this._addClass(this.panels,"ui-tabs-panel","ui-widget-content"),i&&(this._off(i.not(this.tabs)),this._off(s.not(this.anchors)),this._off(n.not(this.panels)))},_getList:function(){return this.tablist||this.element.find("ol, ul").eq(0)},_createPanel:function(e){return t("<div>").attr("id",e).data("ui-tabs-destroy",!0)},_setOptionDisabled:function(e){var i,s,n;for(t.isArray(e)&&(e.length?e.length===this.anchors.length&&(e=!0):e=!1),n=0;s=this.tabs[n];n++)i=t(s),e===!0||-1!==t.inArray(n,e)?(i.attr("aria-disabled","true"),this._addClass(i,null,"ui-state-disabled")):(i.removeAttr("aria-disabled"),this._removeClass(i,null,"ui-state-disabled"));this.options.disabled=e,this._toggleClass(this.widget(),this.widgetFullName+"-disabled",null,e===!0)},_setupEvents:function(e){var i={};e&&t.each(e.split(" "),function(t,e){i[e]="_eventHandler"}),this._off(this.anchors.add(this.tabs).add(this.panels)),this._on(!0,this.anchors,{click:function(t){t.preventDefault()}}),this._on(this.anchors,i),this._on(this.tabs,{keydown:"_tabKeydown"}),this._on(this.panels,{keydown:"_panelKeydown"}),this._focusable(this.tabs),this._hoverable(this.tabs)},_setupHeightStyle:function(e){var i,s=this.element.parent();"fill"===e?(i=s.height(),i-=this.element.outerHeight()-this.element.height(),this.element.siblings(":visible").each(function(){var e=t(this),s=e.css("position");"absolute"!==s&&"fixed"!==s&&(i-=e.outerHeight(!0))}),this.element.children().not(this.panels).each(function(){i-=t(this).outerHeight(!0)}),this.panels.each(function(){t(this).height(Math.max(0,i-t(this).innerHeight()+t(this).height()))}).css("overflow","auto")):"auto"===e&&(i=0,this.panels.each(function(){i=Math.max(i,t(this).height("").height())}).height(i))},_eventHandler:function(e){var i=this.options,s=this.active,n=t(e.currentTarget),o=n.closest("li"),a=o[0]===s[0],r=a&&i.collapsible,h=r?t():this._getPanelForTab(o),l=s.length?this._getPanelForTab(s):t(),c={oldTab:s,oldPanel:l,newTab:r?t():o,newPanel:h};e.preventDefault(),o.hasClass("ui-state-disabled")||o.hasClass("ui-tabs-loading")||this.running||a&&!i.collapsible||this._trigger("beforeActivate",e,c)===!1||(i.active=r?!1:this.tabs.index(o),this.active=a?t():o,this.xhr&&this.xhr.abort(),l.length||h.length||t.error("jQuery UI Tabs: Mismatching fragment identifier."),h.length&&this.load(this.tabs.index(o),e),this._toggle(e,c))},_toggle:function(e,i){function s(){o.running=!1,o._trigger("activate",e,i)}function n(){o._addClass(i.newTab.closest("li"),"ui-tabs-active","ui-state-active"),a.length&&o.options.show?o._show(a,o.options.show,s):(a.show(),s())}var o=this,a=i.newPanel,r=i.oldPanel;this.running=!0,r.length&&this.options.hide?this._hide(r,this.options.hide,function(){o._removeClass(i.oldTab.closest("li"),"ui-tabs-active","ui-state-active"),n()}):(this._removeClass(i.oldTab.closest("li"),"ui-tabs-active","ui-state-active"),r.hide(),n()),r.attr("aria-hidden","true"),i.oldTab.attr({"aria-selected":"false","aria-expanded":"false"}),a.length&&r.length?i.oldTab.attr("tabIndex",-1):a.length&&this.tabs.filter(function(){return 0===t(this).attr("tabIndex")}).attr("tabIndex",-1),a.attr("aria-hidden","false"),i.newTab.attr({"aria-selected":"true","aria-expanded":"true",tabIndex:0})},_activate:function(e){var i,s=this._findActive(e);s[0]!==this.active[0]&&(s.length||(s=this.active),i=s.find(".ui-tabs-anchor")[0],this._eventHandler({target:i,currentTarget:i,preventDefault:t.noop}))},_findActive:function(e){return e===!1?t():this.tabs.eq(e)},_getIndex:function(e){return"string"==typeof e&&(e=this.anchors.index(this.anchors.filter("[href$='"+t.ui.escapeSelector(e)+"']"))),e},_destroy:function(){this.xhr&&this.xhr.abort(),this.tablist.removeAttr("role").off(this.eventNamespace),this.anchors.removeAttr("role tabIndex").removeUniqueId(),this.tabs.add(this.panels).each(function(){t.data(this,"ui-tabs-destroy")?t(this).remove():t(this).removeAttr("role tabIndex aria-live aria-busy aria-selected aria-labelledby aria-hidden aria-expanded")}),this.tabs.each(function(){var e=t(this),i=e.data("ui-tabs-aria-controls");i?e.attr("aria-controls",i).removeData("ui-tabs-aria-controls"):e.removeAttr("aria-controls")}),this.panels.show(),"content"!==this.options.heightStyle&&this.panels.css("height","")},enable:function(e){var i=this.options.disabled;i!==!1&&(void 0===e?i=!1:(e=this._getIndex(e),i=t.isArray(i)?t.map(i,function(t){return t!==e?t:null}):t.map(this.tabs,function(t,i){return i!==e?i:null})),this._setOptionDisabled(i))},disable:function(e){var i=this.options.disabled;if(i!==!0){if(void 0===e)i=!0;else{if(e=this._getIndex(e),-1!==t.inArray(e,i))return;i=t.isArray(i)?t.merge([e],i).sort():[e]}this._setOptionDisabled(i)}},load:function(e,i){e=this._getIndex(e);var s=this,n=this.tabs.eq(e),o=n.find(".ui-tabs-anchor"),a=this._getPanelForTab(n),r={tab:n,panel:a},h=function(t,e){"abort"===e&&s.panels.stop(!1,!0),s._removeClass(n,"ui-tabs-loading"),a.removeAttr("aria-busy"),t===s.xhr&&delete s.xhr};this._isLocal(o[0])||(this.xhr=t.ajax(this._ajaxSettings(o,i,r)),this.xhr&&"canceled"!==this.xhr.statusText&&(this._addClass(n,"ui-tabs-loading"),a.attr("aria-busy","true"),this.xhr.done(function(t,e,n){setTimeout(function(){a.html(t),s._trigger("load",i,r),h(n,e)},1)}).fail(function(t,e){setTimeout(function(){h(t,e)},1)})))},_ajaxSettings:function(e,i,s){var n=this;return{url:e.attr("href").replace(/#.*$/,""),beforeSend:function(e,o){return n._trigger("beforeLoad",i,t.extend({jqXHR:e,ajaxSettings:o},s))}}},_getPanelForTab:function(e){var i=t(e).attr("aria-controls");return this.element.find(this._sanitizeSelector("#"+i))}}),t.uiBackCompat!==!1&&t.widget("ui.tabs",t.ui.tabs,{_processTabs:function(){this._superApply(arguments),this._addClass(this.tabs,"ui-tab")}}),t.ui.tabs,t.widget("ui.tooltip",{version:"1.12.1",options:{classes:{"ui-tooltip":"ui-corner-all ui-widget-shadow"},content:function(){var e=t(this).attr("title")||"";return t("<a>").text(e).html()},hide:!0,items:"[title]:not([disabled])",position:{my:"left top+15",at:"left bottom",collision:"flipfit flip"},show:!0,track:!1,close:null,open:null},_addDescribedBy:function(e,i){var s=(e.attr("aria-describedby")||"").split(/\s+/);s.push(i),e.data("ui-tooltip-id",i).attr("aria-describedby",t.trim(s.join(" ")))},_removeDescribedBy:function(e){var i=e.data("ui-tooltip-id"),s=(e.attr("aria-describedby")||"").split(/\s+/),n=t.inArray(i,s);-1!==n&&s.splice(n,1),e.removeData("ui-tooltip-id"),s=t.trim(s.join(" ")),s?e.attr("aria-describedby",s):e.removeAttr("aria-describedby")},_create:function(){this._on({mouseover:"open",focusin:"open"}),this.tooltips={},this.parents={},this.liveRegion=t("<div>").attr({role:"log","aria-live":"assertive","aria-relevant":"additions"}).appendTo(this.document[0].body),this._addClass(this.liveRegion,null,"ui-helper-hidden-accessible"),this.disabledTitles=t([])},_setOption:function(e,i){var s=this;this._super(e,i),"content"===e&&t.each(this.tooltips,function(t,e){s._updateContent(e.element)})},_setOptionDisabled:function(t){this[t?"_disable":"_enable"]()},_disable:function(){var e=this;t.each(this.tooltips,function(i,s){var n=t.Event("blur");n.target=n.currentTarget=s.element[0],e.close(n,!0)}),this.disabledTitles=this.disabledTitles.add(this.element.find(this.options.items).addBack().filter(function(){var e=t(this);return e.is("[title]")?e.data("ui-tooltip-title",e.attr("title")).removeAttr("title"):void 0}))},_enable:function(){this.disabledTitles.each(function(){var e=t(this);e.data("ui-tooltip-title")&&e.attr("title",e.data("ui-tooltip-title"))}),this.disabledTitles=t([])},open:function(e){var i=this,s=t(e?e.target:this.element).closest(this.options.items);s.length&&!s.data("ui-tooltip-id")&&(s.attr("title")&&s.data("ui-tooltip-title",s.attr("title")),s.data("ui-tooltip-open",!0),e&&"mouseover"===e.type&&s.parents().each(function(){var e,s=t(this);s.data("ui-tooltip-open")&&(e=t.Event("blur"),e.target=e.currentTarget=this,i.close(e,!0)),s.attr("title")&&(s.uniqueId(),i.parents[this.id]={element:this,title:s.attr("title")},s.attr("title",""))}),this._registerCloseHandlers(e,s),this._updateContent(s,e))},_updateContent:function(t,e){var i,s=this.options.content,n=this,o=e?e.type:null;return"string"==typeof s||s.nodeType||s.jquery?this._open(e,t,s):(i=s.call(t[0],function(i){n._delay(function(){t.data("ui-tooltip-open")&&(e&&(e.type=o),this._open(e,t,i))})}),i&&this._open(e,t,i),void 0)},_open:function(e,i,s){function n(t){l.of=t,a.is(":hidden")||a.position(l)}var o,a,r,h,l=t.extend({},this.options.position);if(s){if(o=this._find(i))return o.tooltip.find(".ui-tooltip-content").html(s),void 0;i.is("[title]")&&(e&&"mouseover"===e.type?i.attr("title",""):i.removeAttr("title")),o=this._tooltip(i),a=o.tooltip,this._addDescribedBy(i,a.attr("id")),a.find(".ui-tooltip-content").html(s),this.liveRegion.children().hide(),h=t("<div>").html(a.find(".ui-tooltip-content").html()),h.removeAttr("name").find("[name]").removeAttr("name"),h.removeAttr("id").find("[id]").removeAttr("id"),h.appendTo(this.liveRegion),this.options.track&&e&&/^mouse/.test(e.type)?(this._on(this.document,{mousemove:n}),n(e)):a.position(t.extend({of:i},this.options.position)),a.hide(),this._show(a,this.options.show),this.options.track&&this.options.show&&this.options.show.delay&&(r=this.delayedShow=setInterval(function(){a.is(":visible")&&(n(l.of),clearInterval(r))},t.fx.interval)),this._trigger("open",e,{tooltip:a})}},_registerCloseHandlers:function(e,i){var s={keyup:function(e){if(e.keyCode===t.ui.keyCode.ESCAPE){var s=t.Event(e);s.currentTarget=i[0],this.close(s,!0)}}};i[0]!==this.element[0]&&(s.remove=function(){this._removeTooltip(this._find(i).tooltip)}),e&&"mouseover"!==e.type||(s.mouseleave="close"),e&&"focusin"!==e.type||(s.focusout="close"),this._on(!0,i,s)},close:function(e){var i,s=this,n=t(e?e.currentTarget:this.element),o=this._find(n);return o?(i=o.tooltip,o.closing||(clearInterval(this.delayedShow),n.data("ui-tooltip-title")&&!n.attr("title")&&n.attr("title",n.data("ui-tooltip-title")),this._removeDescribedBy(n),o.hiding=!0,i.stop(!0),this._hide(i,this.options.hide,function(){s._removeTooltip(t(this))}),n.removeData("ui-tooltip-open"),this._off(n,"mouseleave focusout keyup"),n[0]!==this.element[0]&&this._off(n,"remove"),this._off(this.document,"mousemove"),e&&"mouseleave"===e.type&&t.each(this.parents,function(e,i){t(i.element).attr("title",i.title),delete s.parents[e]}),o.closing=!0,this._trigger("close",e,{tooltip:i}),o.hiding||(o.closing=!1)),void 0):(n.removeData("ui-tooltip-open"),void 0)},_tooltip:function(e){var i=t("<div>").attr("role","tooltip"),s=t("<div>").appendTo(i),n=i.uniqueId().attr("id");return this._addClass(s,"ui-tooltip-content"),this._addClass(i,"ui-tooltip","ui-widget ui-widget-content"),i.appendTo(this._appendTo(e)),this.tooltips[n]={element:e,tooltip:i}},_find:function(t){var e=t.data("ui-tooltip-id");return e?this.tooltips[e]:null},_removeTooltip:function(t){t.remove(),delete this.tooltips[t.attr("id")]},_appendTo:function(t){var e=t.closest(".ui-front, dialog");return e.length||(e=this.document[0].body),e},_destroy:function(){var e=this;t.each(this.tooltips,function(i,s){var n=t.Event("blur"),o=s.element;n.target=n.currentTarget=o[0],e.close(n,!0),t("#"+i).remove(),o.data("ui-tooltip-title")&&(o.attr("title")||o.attr("title",o.data("ui-tooltip-title")),o.removeData("ui-tooltip-title"))}),this.liveRegion.remove()}}),t.uiBackCompat!==!1&&t.widget("ui.tooltip",t.ui.tooltip,{options:{tooltipClass:null},_tooltip:function(){var t=this._superApply(arguments);return this.options.tooltipClass&&t.tooltip.addClass(this.options.tooltipClass),t}}),t.ui.tooltip});
21; 22/* AUTOGENERATED: jquery.ui.touch-punch.min.js */ 23/*! 24 * jQuery UI Touch Punch 0.2.3 25 * 26 * Copyright 2011â2014, Dave Furfero 27 * Dual licensed under the MIT or GPL Version 2 licenses. 28 * 29 * Depends: 30 * jquery.ui.widget.js 31 * jquery.ui.mouse.js 32 */ 33!function(a){function f(a,b){if(!(a.originalEvent.touches.length>1)){a.preventDefault();var c=a.originalEvent.changedTouches[0],d=document.createEvent("MouseEvents");d.initMouseEvent(b,!0,!0,window,1,c.screenX,c.screenY,c.clientX,c.clientY,!1,!1,!1,!1,0,null),a.target.dispatchEvent(d)}}if(a.support.touch="ontouchend"in document,a.support.touch){var e,b=a.ui.mouse.prototype,c=b._mouseInit,d=b._mouseDestroy;b._touchStart=function(a){var b=this;!e&&b._mouseCapture(a.originalEvent.changedTouches[0])&&(e=!0,b._touchMoved=!1,f(a,"mouseover"),f(a,"mousemove"),f(a,"mousedown"))},b._touchMove=function(a){e&&(this._touchMoved=!0,f(a,"mousemove"))},b._touchEnd=function(a){e&&(f(a,"mouseup"),f(a,"mouseout"),this._touchMoved||f(a,"click"),e=!1)},b._mouseInit=function(){var b=this;b.element.bind({touchstart:a.proxy(b,"_touchStart"),touchmove:a.proxy(b,"_touchMove"),touchend:a.proxy(b,"_touchEnd")}),c.call(b)},b._mouseDestroy=function(){var b=this;b.element.unbind({touchstart:a.proxy(b,"_touchStart"),touchmove:a.proxy(b,"_touchMove"),touchend:a.proxy(b,"_touchEnd")}),d.call(b)}}}(jQuery);; 34/* AUTOGENERATED: jquery.cookie.min.js */ 35(function(factory){if(typeof define==='function'&&define.amd){define(['jquery'],factory)}else if(typeof exports==='object'){factory(require('jquery'))}else factory(jQuery)}(function($){var pluses=/\+/g 36function encode(s){return config.raw?s:encodeURIComponent(s)} 37function decode(s){return config.raw?s:decodeURIComponent(s)} 38function stringifyCookieValue(value){return encode(config.json?JSON.stringify(value):String(value))} 39function parseCookieValue(s){if(s.indexOf('"')===0)s=s.slice(1,-1).replace(/\\"/g,'"').replace(/\\\\/g,'\\');try{s=decodeURIComponent(s.replace(pluses,' '));return config.json?JSON.parse(s):s}catch(e){}} 40function read(s,converter){var value=config.raw?s:parseCookieValue(s);return $.isFunction(converter)?converter(value):value};var config=$.cookie=function(key,value,options){if(arguments.length>1&&!$.isFunction(value)){options=$.extend({},config.defaults,options);if(typeof options.expires==='number'){var days=options.expires,t=options.expires=new Date();t.setTime(+t+days*864e+5)};return(document.cookie=[encode(key),'=',stringifyCookieValue(value),options.expires?'; expires='+options.expires.toUTCString():'',options.path?'; path='+options.path:'',options.domain?'; domain='+options.domain:'',options.secure?'; secure':''].join(''))};var result=key?undefined:{},cookies=document.cookie?document.cookie.split('; '):[];for(var i=0,l=cookies.length;i<l;i++){var parts=cookies[i].split('='),name=decode(parts.shift()),cookie=parts.join('=');if(key&&key===name){result=read(cookie,value);break};if(!key&&(cookie=read(cookie))!==undefined)result[name]=cookie};return result};config.defaults={};
vendor: 5,374 bytes, lines 40-47
40$.removeCookie=function(key,options){if($.cookie(key)===undefined)return false;$.cookie(key,'',$.extend({},options,{expires:-1}));return!$.cookie(key)}}));; 41/* AUTOGENERATED: underscore-min.js */ 42!function(n,r){"object"==typeof exports&&"undefined"!=typeof module?module.exports=r():"function"==typeof define&&define.amd?define("underscore",r):(n=n||self,function(){var t=n._,e=n._=r();e.noConflict=function(){return n._=t,e}}())}(this,(function(){ 43// Underscore.js 1.12.0 44// https://underscorejs.org 45// (c) 2009-2020 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors 46// Underscore may be freely distributed under the MIT license. 47 var n="1.12.0",r="object"==typeof self&&self.self===self&&self||"object"==typeof global&&global.global===global&&global||Function("return this")()||{},t=Array.prototype,e=Object.prototype,u="undefined"!=typeof Symbol?Symbol.prototype:null,o=t.push,i=t.slice,a=e.toString,f=e.hasOwnProperty,c="undefined"!=typeof ArrayBuffer,l="undefined"!=typeof DataView,s=Array.isArray,p=Object.keys,v=Object.create,h=c&&ArrayBuffer.isView,y=isNaN,g=isFinite,d=!{toString:null}.propertyIsEnumerable("toString"),b=["valueOf","isPrototypeOf","toString","propertyIsEnumerable","hasOwnProperty","toLocaleString"],m=Math.pow(2,53)-1;function j(n,r){return r=null==r?n.length-1:+r,function(){for(var t=Math.max(arguments.length-r,0),e=Array(t),u=0;u<t;u++)e[u]=arguments[u+r];switch(r){case 0:return n.call(this,e);case 1:return n.call(this,arguments[0],e);case 2:return n.call(this,arguments[0],arguments[1],e)}var o=Array(r+1);for(u=0;u<r;u++)o[u]=arguments[u];return o[r]=e,n.apply(this,o)}}function _(n){var r=typeof n;return"function"===r||"object"===r&&!!n}function w(n){return void 0===n}function A(n){return!0===n||!1===n||"[object Boolean]"===a.call(n)}function x(n){var r="[object "+n+"]";return function(n){return a.call(n)===r}}var S=x("String"),O=x("Number"),M=x("Date"),E=x("RegExp"),B=x("Error"),N=x("Symbol"),I=x("ArrayBuffer"),k=x("Function"),T=r.document&&r.document.childNodes;"function"!=typeof/./&&"object"!=typeof Int8Array&&"function"!=typeof T&&(k=function(n){return"function"==typeof n||!1});var D=k,R=x("Object"),F=l&&R(new DataView(new ArrayBuffer(8))),V="undefined"!=typeof Map&&R(new Map),P=x("DataView");var q=F?function(n){return null!=n&&D(n.getInt8)&&I(n.buffer)}:P,U=s||x("Array");function W(n,r){return null!=n&&f.call(n,r)}var z=x("Arguments");!function(){z(arguments)||(z=function(n){return W(n,"callee")})}();var L=z;function C(n){return O(n)&&y(n)}function K(n){return function(){return n}}function J(n){return function(r){var t=n(r);return"number"==typeof t&&t>=0&&t<=m}}function $(n){return function(r){return null==r?void 0:r[n]}}var G=$("byteLength"),H=J(G),Q=/\[object ((I|Ui)nt(8|16|32)|Float(32|64)|Uint8Clamped|Big(I|Ui)nt64)Array\]/;var X=c?function(n){return h?h(n)&&!q(n):H(n)&&Q.test(a.call(n))}:K(!1),Y=$("length");function Z(n,r){r=function(n){for(var r={},t=n.length,e=0;e<t;++e)r[n[e]]=!0;return{contains:function(n){return r[n]},push:function(t){return r[t]=!0,n.push(t)}}}(r);var t=b.length,u=n.constructor,o=D(u)&&u.prototype||e,i="constructor";for(W(n,i)&&!r.contains(i)&&r.push(i);t--;)(i=b[t])in n&&n[i]!==o[i]&&!r.contains(i)&&r.push(i)}function nn(n){if(!_(n))return[];if(p)return p(n);var r=[];for(var t in n)W(n,t)&&r.push(t);return d&&Z(n,r),r}function rn(n,r){var t=nn(r),e=t.length;if(null==n)return!e;for(var u=Object(n),o=0;o<e;o++){var i=t[o];if(r[i]!==u[i]||!(i in u))return!1}return!0}function tn(n){return n instanceof tn?n:this instanceof tn?void(this._wrapped=n):new tn(n)}function en(n){return new Uint8Array(n.buffer||n,n.byteOffset||0,G(n))}tn.VERSION=n,tn.prototype.value=function(){return this._wrapped},tn.prototype.valueOf=tn.prototype.toJSON=tn.prototype.value,tn.prototype.toString=function(){return String(this._wrapped)};var un="[object DataView]";function on(n,r,t,e){if(n===r)return 0!==n||1/n==1/r;if(null==n||null==r)return!1;if(n!=n)return r!=r;var o=typeof n;return("function"===o||"object"===o||"object"==typeof r)&&function n(r,t,e,o){r instanceof tn&&(r=r._wrapped);t instanceof tn&&(t=t._wrapped);var i=a.call(r);if(i!==a.call(t))return!1;if(F&&"[object Object]"==i&&q(r)){if(!q(t))return!1;i=un}switch(i){case"[object RegExp]":case"[object String]":return""+r==""+t;case"[object Number]":return+r!=+r?+t!=+t:0==+r?1/+r==1/t:+r==+t;case"[object Date]":case"[object Boolean]":return+r==+t;case"[object Symbol]":return u.valueOf.call(r)===u.valueOf.call(t);case"[object ArrayBuffer]":case un:return n(en(r),en(t),e,o)}var f="[object Array]"===i;if(!f&&X(r)){if(G(r)!==G(t))return!1;if(r.buffer===t.buffer&&r.byteOffset===t.byteOffset)return!0;f=!0}if(!f){if("object"!=typeof r||"object"!=typeof t)return!1;var c=r.constructor,l=t.constructor;if(c!==l&&!(D(c)&&c instanceof c&&D(l)&&l instanceof l)&&"constructor"in r&&"constructor"in t)return!1}o=o||[];var s=(e=e||[]).length;for(;s--;)if(e[s]===r)return o[s]===t;if(e.push(r),o.push(t),f){if((s=r.length)!==t.length)return!1;for(;s--;)if(!on(r[s],t[s],e,o))return!1}else{var p,v=nn(r);if(s=v.length,nn(t).length!==s)return!1;for(;s--;)if(p=v[s],!W(t,p)||!on(r[p],t[p],e,o))return!1}return e.pop(),o.pop(),!0}(n,r,t,e)}function an(n){if(!_(n))return[];var r=[];for(var t in n)r.push(t);return d&&Z(n,r),r}function fn(n){var r=Y(n);return function(t){if(null==t)return!1;var e=an(t);
vendor: 12,005 bytes, line 47
47if(Y(e))return!1;for(var u=0;u<r;u++)if(!D(t[n[u]]))return!1;return n!==hn||!D(t[cn])}}var cn="forEach",ln="has",sn=["clear","delete"],pn=["get",ln,"set"],vn=sn.concat(cn,pn),hn=sn.concat(pn),yn=["add"].concat(sn,cn,ln),gn=V?fn(vn):x("Map"),dn=V?fn(hn):x("WeakMap"),bn=V?fn(yn):x("Set"),mn=x("WeakSet");function jn(n){for(var r=nn(n),t=r.length,e=Array(t),u=0;u<t;u++)e[u]=n[r[u]];return e}function _n(n){for(var r={},t=nn(n),e=0,u=t.length;e<u;e++)r[n[t[e]]]=t[e];return r}function wn(n){var r=[];for(var t in n)D(n[t])&&r.push(t);return r.sort()}function An(n,r){return function(t){var e=arguments.length;if(r&&(t=Object(t)),e<2||null==t)return t;for(var u=1;u<e;u++)for(var o=arguments[u],i=n(o),a=i.length,f=0;f<a;f++){var c=i[f];r&&void 0!==t[c]||(t[c]=o[c])}return t}}var xn=An(an),Sn=An(nn),On=An(an,!0);function Mn(n){if(!_(n))return{};if(v)return v(n);var r=function(){};r.prototype=n;var t=new r;return r.prototype=null,t}function En(n){return _(n)?U(n)?n.slice():xn({},n):n}function Bn(n){return U(n)?n:[n]}function Nn(n){return tn.toPath(n)}function In(n,r){for(var t=r.length,e=0;e<t;e++){if(null==n)return;n=n[r[e]]}return t?n:void 0}function kn(n,r,t){var e=In(n,Nn(r));return w(e)?t:e}function Tn(n){return n}function Dn(n){return n=Sn({},n),function(r){return rn(r,n)}}function Rn(n){return n=Nn(n),function(r){return In(r,n)}}function Fn(n,r,t){if(void 0===r)return n;switch(null==t?3:t){case 1:return function(t){return n.call(r,t)};case 3:return function(t,e,u){return n.call(r,t,e,u)};case 4:return function(t,e,u,o){return n.call(r,t,e,u,o)}}return function(){return n.apply(r,arguments)}}function Vn(n,r,t){return null==n?Tn:D(n)?Fn(n,r,t):_(n)&&!U(n)?Dn(n):Rn(n)}function Pn(n,r){return Vn(n,r,1/0)}function qn(n,r,t){return tn.iteratee!==Pn?tn.iteratee(n,r):Vn(n,r,t)}function Un(){}function Wn(n,r){return null==r&&(r=n,n=0),n+Math.floor(Math.random()*(r-n+1))}tn.toPath=Bn,tn.iteratee=Pn;var zn=Date.now||function(){return(new Date).getTime()};function Ln(n){var r=function(r){return n[r]},t="(?:"+nn(n).join("|")+")",e=RegExp(t),u=RegExp(t,"g");return function(n){return n=null==n?"":""+n,e.test(n)?n.replace(u,r):n}}var Cn={"&":"&","<":"<",">":">",'"':""","'":"'","`":"`"},Kn=Ln(Cn),Jn=Ln(_n(Cn)),$n=tn.templateSettings={evaluate:/<%([\s\S]+?)%>/g,interpolate:/<%=([\s\S]+?)%>/g,escape:/<%-([\s\S]+?)%>/g},Gn=/(.)^/,Hn={"'":"'","\\":"\\","\r":"r","\n":"n","\u2028":"u2028","\u2029":"u2029"},Qn=/\\|'|\r|\n|\u2028|\u2029/g;function Xn(n){return"\\"+Hn[n]}var Yn=0;function Zn(n,r,t,e,u){if(!(e instanceof r))return n.apply(t,u);var o=Mn(n.prototype),i=n.apply(o,u);return _(i)?i:o}var nr=j((function(n,r){var t=nr.placeholder,e=function(){for(var u=0,o=r.length,i=Array(o),a=0;a<o;a++)i[a]=r[a]===t?arguments[u++]:r[a];for(;u<arguments.length;)i.push(arguments[u++]);return Zn(n,e,this,this,i)};return e}));nr.placeholder=tn;var rr=j((function(n,r,t){if(!D(n))throw new TypeError("Bind must be called on a function");var e=j((function(u){return Zn(n,e,r,this,t.concat(u))}));return e})),tr=J(Y);function er(n,r,t,e){if(e=e||[],r||0===r){if(r<=0)return e.concat(n)}else r=1/0;for(var u=e.length,o=0,i=Y(n);o<i;o++){var a=n[o];if(tr(a)&&(U(a)||L(a)))if(r>1)er(a,r-1,t,e),u=e.length;else for(var f=0,c=a.length;f<c;)e[u++]=a[f++];else t||(e[u++]=a)}return e}var ur=j((function(n,r){var t=(r=er(r,!1,!1)).length;if(t<1)throw new Error("bindAll must be passed function names");for(;t--;){var e=r[t];n[e]=rr(n[e],n)}return n}));var or=j((function(n,r,t){return setTimeout((function(){return n.apply(null,t)}),r)})),ir=nr(or,tn,1);function ar(n){return function(){return!n.apply(this,arguments)}}function fr(n,r){var t;return function(){return--n>0&&(t=r.apply(this,arguments)),n<=1&&(r=null),t}}var cr=nr(fr,2);function lr(n,r,t){r=qn(r,t);for(var e,u=nn(n),o=0,i=u.length;o<i;o++)if(r(n[e=u[o]],e,n))return e}function sr(n){return function(r,t,e){t=qn(t,e);for(var u=Y(r),o=n>0?0:u-1;o>=0&&o<u;o+=n)if(t(r[o],o,r))return o;return-1}}var pr=sr(1),vr=sr(-1);function hr(n,r,t,e){for(var u=(t=qn(t,e,1))(r),o=0,i=Y(n);o<i;){var a=Math.floor((o+i)/2);t(n[a])<u?o=a+1:i=a}return o}function yr(n,r,t){return function(e,u,o){var a=0,f=Y(e);if("number"==typeof o)n>0?a=o>=0?o:Math.max(o+f,a):f=o>=0?Math.min(o+1,f):o+f+1;else if(t&&o&&f)return e[o=t(e,u)]===u?o:-1;if(u!=u)return(o=r(i.call(e,a,f),C))>=0?o+a:-1;for(o=n>0?a:f-1;o>=0&&o<f;o+=n)if(e[o]===u)return o;return-1}}var gr=yr(1,pr,hr),dr=yr(-1,vr);function br(n,r,t){var e=(tr(n)?pr:lr)(n,r,t);if(void 0!==e&&-1!==e)return n[e]}function mr(n,r,t){var e,u;if(r=Fn(r,t),tr(n))for(e=0,u=n.length;e<u;e++)r(n[e],e,n);else{var o=nn(n);for(e=0,u=o.length;e<u;e++)r(n[o[e]],o[e],n)}return n}function jr(n,r,t){r=qn(r,t);for(var e=!tr(n)&&nn(n),u=(e||n).length,o=Array(u),i=0;i<u;i++){var a=e?e[i]:i;o[i]=r(n[a],a,n)}return o}function _r(n){var r=function(r,t,e,u){var o=!tr(r)&&nn(r),i=(o||r).length,a=n>0?0:i-1;for(u||(e=r[o?o[a]:a],a+=n);a>=0&&a<i;a+=n){var f=o?o[a]:a;e=t(e,r[f],f,r)}return e};return function(n,t,e,u){var o=arguments.length>=3;return r(n,Fn(t,u,4),e,o)}}var wr=_r(1),Ar=_r(-1);function xr(n,r,t){var e=[];return r=qn(r,t),mr(n,(function(n,t,u){r(n,t,u)&&e.push(n)})),e}function Sr(n,r,t){r=qn(r,t);for(var e=!tr(n)&&nn(n),u=(e||n).length,o=0;o<u;o++){var i=e?e[o]:o;if(!r(n[i],i,n))return!1}return!0}function Or(n,r,t){r=qn(r,t);for(var e=!tr(n)&&nn(n),u=(e||n).length,o=0;o<u;o++){var i=e?e[o]:o;if(r(n[i],i,n))return!0}return!1}function Mr(n,r,t,e){return tr(n)||(n=jn(n)),("number"!=typeof t||e)&&(t=0),gr(n,r,t)>=0}var Er=j((function(n,r,t){var e,u;return D(r)?u=r:(r=Nn(r),e=r.slice(0,-1),r=r[r.length-1]),jr(n,(function(n){var o=u;if(!o){if(e&&e.length&&(n=In(n,e)),null==n)return;o=n[r]}return null==o?o:o.apply(n,t)}))}));function Br(n,r){return jr(n,Rn(r))}function Nr(n,r,t){var e,u,o=-1/0,i=-1/0;if(null==r||"number"==typeof r&&"object"!=typeof n[0]&&null!=n)for(var a=0,f=(n=tr(n)?n:jn(n)).length;a<f;a++)null!=(e=n[a])&&e>o&&(o=e);else r=qn(r,t),mr(n,(function(n,t,e){((u=r(n,t,e))>i||u===-1/0&&o===-1/0)&&(o=n,i=u)}));return o}function Ir(n,r,t){if(null==r||t)return tr(n)||(n=jn(n)),n[Wn(n.length-1)];var e=tr(n)?En(n):jn(n),u=Y(e);r=Math.max(Math.min(r,u),0);for(var o=u-1,i=0;i<r;i++){var a=Wn(i,o),f=e[i];e[i]=e[a],e[a]=f}return e.slice(0,r)}function kr(n,r){return function(t,e,u){var o=r?[[],[]]:{};return e=qn(e,u),mr(t,(function(r,u){var i=e(r,u,t);n(o,r,i)})),o}}var Tr=kr((function(n,r,t){W(n,t)?n[t].push(r):n[t]=[r]})),Dr=kr((function(n,r,t){n[t]=r})),Rr=kr((function(n,r,t){W(n,t)?n[t]++:n[t]=1})),Fr=kr((function(n,r,t){n[t?0:1].push(r)}),!0),Vr=/[^\ud800-\udfff]|[\ud800-\udbff][\udc00-\udfff]|[\ud800-\udfff]/g;function Pr(n,r,t){return r in t}var qr=j((function(n,r){var t={},e=r[0];if(null==n)return t;D(e)?(r.length>1&&(e=Fn(e,r[1])),r=an(n)):(e=Pr,r=er(r,!1,!1),n=Object(n));for(var u=0,o=r.length;u<o;u++){var i=r[u],a=n[i];e(a,i,n)&&(t[i]=a)}return t})),Ur=j((function(n,r){var t,e=r[0];return D(e)?(e=ar(e),r.length>1&&(t=r[1])):(r=jr(er(r,!1,!1),String),e=function(n,t){return!Mr(r,t)}),qr(n,e,t)}));function Wr(n,r,t){return i.call(n,0,Math.max(0,n.length-(null==r||t?1:r)))}function zr(n,r,t){return null==n||n.length<1?null==r||t?void 0:[]:null==r||t?n[0]:Wr(n,n.length-r)}function Lr(n,r,t){return i.call(n,null==r||t?1:r)}var Cr=j((function(n,r){return r=er(r,!0,!0),xr(n,(function(n){return!Mr(r,n)}))})),Kr=j((function(n,r){return Cr(n,r)}));function Jr(n,r,t,e){A(r)||(e=t,t=r,r=!1),null!=t&&(t=qn(t,e));for(var u=[],o=[],i=0,a=Y(n);i<a;i++){var f=n[i],c=t?t(f,i,n):f;r&&!t?(i&&o===c||u.push(f),o=c):t?Mr(o,c)||(o.push(c),u.push(f)):Mr(u,f)||u.push(f)}return u}var $r=j((function(n){return Jr(er(n,!0,!0))}));function Gr(n){for(var r=n&&Nr(n,Y).length||0,t=Array(r),e=0;e<r;e++)t[e]=Br(n,e);return t}var Hr=j(Gr);function Qr(n,r){return n._chain?tn(r).chain():r}function Xr(n){return mr(wn(n),(function(r){var t=tn[r]=n[r];tn.prototype[r]=function(){var n=[this._wrapped];return o.apply(n,arguments),Qr(this,t.apply(tn,n))}})),tn}mr(["pop","push","reverse","shift","sort","splice","unshift"],(function(n){var r=t[n];tn.prototype[n]=function(){var t=this._wrapped;return null!=t&&(r.apply(t,arguments),"shift"!==n&&"splice"!==n||0!==t.length||delete t[0]),Qr(this,t)}})),mr(["concat","join","slice"],(function(n){var r=t[n];tn.prototype[n]=function(){var n=this._wrapped;return null!=n&&(n=r.apply(n,arguments)),Qr(this,n)}}));var Yr=Xr({__proto__:null,VERSION:n,restArguments:j,isObject:_,isNull:function(n){return null===n},isUndefined:w,isBoolean:A,isElement:function(n){return!(!n||1!==n.nodeType)},isString:S,isNumber:O,isDate:M,isRegExp:E,isError:B,isSymbol:N,isArrayBuffer:I,isDataView:q,isArray:U,isFunction:D,isArguments:L,isFinite:function(n){return!N(n)&&g(n)&&!isNaN(parseFloat(n))},isNaN:C,isTypedArray:X,isEmpty:function(n){if(null==n)return!0;var r=Y(n);return"number"==typeof r&&(U(n)||S(n)||L(n))?0===r:0===Y(nn(n))},isMatch:rn,isEqual:function(n,r){return on(n,r)},isMap:gn,isWeakMap:dn,isSet:bn,isWeakSet:mn,keys:nn,allKeys:an,values:jn,pairs:function(n){for(var r=nn(n),t=r.length,e=Array(t),u=0;u<t;u++)e[u]=[r[u],n[r[u]]];return e},invert:_n,functions:wn,methods:wn,extend:xn,extendOwn:Sn,assign:Sn,defaults:On,create:function(n,r){var t=Mn(n);return r&&Sn(t,r),t},clone:En,tap:function(n,r){return r(n),n},get:kn,has:function(n,r){for(var t=(r=Nn(r)).length,e=0;e<t;e++){var u=r[e];if(!W(n,u))return!1;n=n[u]}return!!t},mapObject:function(n,r,t){r=qn(r,t);for(var e=nn(n),u=e.length,o={},i=0;i<u;i++){var a=e[i];o[a]=r(n[a],a,n)}return o},identity:Tn,constant:K,noop:Un,toPath:Bn,property:Rn,propertyOf:function(n){return null==n?Un:function(r){return kn(n,r)}},matcher:Dn,matches:Dn,times:function(n,r,t){var e=Array(Math.max(0,n));r=Fn(r,t,1);for(var u=0;u<n;u++)e[u]=r(u);return e},random:Wn,now:zn,escape:Kn,unescape:Jn,templateSettings:$n,template:function(n,r,t){!r&&t&&(r=t),r=On({},r,tn.templateSettings);var e,u=RegExp([(r.escape||Gn).source,(r.interpolate||Gn).source,(r.evaluate||Gn).source].join("|")+"|$","g"),o=0,i="__p+='";n.replace(u,(function(r,t,e,u,a){return i+=n.slice(o,a).replace(Qn,Xn),o=a+r.length,t?i+="'+\n((__t=("+t+"))==null?'':_.escape(__t))+\n'":e?i+="'+\n((__t=("+e+"))==null?'':__t)+\n'":u&&(i+="';\n"+u+"\n__p+='"),r})),i+="';\n",r.variable||(i="with(obj||{}){\n"+i+"}\n"),i="var __t,__p='',__j=Array.prototype.join,"+"print=function(){__p+=__j.call(arguments,'');};\n"+i+"return __p;\n";try{e=new Function(r.variable||"obj","_",i)}catch(n){throw n.source=i,n}var a=function(n){return e.call(this,n,tn)},f=r.variable||"obj";return a.source="function("+f+"){\n"+i+"}",a},result:function(n,r,t){var e=(r=Nn(r)).length;if(!e)return D(t)?t.call(n):t;for(var u=0;u<e;u++){var o=null==n?void 0:n[r[u]];void 0===o&&(o=t,u=e),n=D(o)?o.call(n):o}return n},uniqueId:function(n){var r=++Yn+"";return n?n+r:r},chain:function(n){var r=tn(n);return r._chain=!0,r},iteratee:Pn,partial:nr,bind:rr,bindAll:ur,memoize:function(n,r){var t=function(e){var u=t.cache,o=""+(r?r.apply(this,arguments):e);return W(u,o)||(u[o]=n.apply(this,arguments)),u[o]};return t.cache={},t},delay:or,defer:ir,throttle:function(n,r,t){var e,u,o,i,a=0;t||(t={});var f=function(){a=!1===t.leading?0:zn(),e=null,i=n.apply(u,o),e||(u=o=null)},c=function(){var c=zn();a||!1!==t.leading||(a=c);var l=r-(c-a);return u=this,o=arguments,l<=0||l>r?(e&&(clearTimeout(e),e=null),a=c,i=n.apply(u,o),e||(u=o=null)):e||!1===t.trailing||(e=setTimeout(f,l)),i};return c.cancel=function(){clearTimeout(e),a=0,e=u=o=null},c},debounce:function(n,r,t){var e,u,o=function(r,t){e=null,t&&(u=n.apply(r,t))},i=j((function(i){if(e&&clearTimeout(e),t){var a=!e;e=setTimeout(o,r),a&&(u=n.apply(this,i))}else e=or(o,r,this,i);return u}));return i.cancel=function(){clearTimeout(e),e=null},i},wrap:function(n,r){return nr(r,n)},negate:ar,compose:function(){var n=arguments,r=n.length-1;return function(){for(var t=r,e=n[r].apply(this,arguments);t--;)e=n[t].call(this,e);return e}},after:function(n,r){return function(){if(--n<1)return r.apply(this,arguments)}}
47,before:fr,once:cr,findKey:lr,findIndex:pr,findLastIndex:vr,sortedIndex:hr,indexOf:gr,lastIndexOf:dr,find:br,detect:br,findWhere:function(n,r){return br(n,Dn(r))},each:mr,forEach:mr,map:jr,collect:jr,reduce:wr,foldl:wr,inject:wr,reduceRight:Ar,foldr:Ar,filter:xr,select:xr,reject:function(n,r,t){return xr(n,ar(qn(r)),t)},every:Sr,all:Sr,some:Or,any:Or,contains:Mr,includes:Mr,include:Mr,invoke:Er,pluck:Br,where:function(n,r){return xr(n,Dn(r))},max:Nr,min:function(n,r,t){var e,u,o=1/0,i=1/0;if(null==r||"number"==typeof r&&"object"!=typeof n[0]&&null!=n)for(var a=0,f=(n=tr(n)?n:jn(n)).length;a<f;a++)null!=(e=n[a])&&e<o&&(o=e);else r=qn(r,t),mr(n,(function(n,t,e){((u=r(n,t,e))<i||u===1/0&&o===1/0)&&(o=n,i=u)}));return o},shuffle:function(n){return Ir(n,1/0)},sample:Ir,sortBy:function(n,r,t){var e=0;return r=qn(r,t),Br(jr(n,(function(n,t,u){return{value:n,index:e++,criteria:r(n,t,u)}})).sort((function(n,r){var t=n.criteria,e=r.criteria;if(t!==e){if(t>e||void 0===t)return 1;if(t<e||void 0===e)return-1}return n.index-r.index})),"value")},groupBy:Tr,indexBy:Dr,countBy:Rr,partition:Fr,toArray:function(n){return n?U(n)?i.call(n):S(n)?n.match(Vr):tr(n)?jr(n,Tn):jn(n):[]},size:function(n){return null==n?0:tr(n)?n.length:nn(n).length},pick:qr,omit:Ur,first:zr,head:zr,take:zr,initial:Wr,last:function(n,r,t){return null==n||n.length<1?null==r||t?void 0:[]:null==r||t?n[n.length-1]:Lr(n,Math.max(0,n.length-r))},rest:Lr,tail:Lr,drop:Lr,compact:function(n){return xr(n,Boolean)},flatten:function(n,r){return er(n,r,!1)},without:Kr,uniq:Jr,unique:Jr,union:$r,intersection:function(n){for(var r=[],t=arguments.length,e=0,u=Y(n);e<u;e++){var o=n[e];if(!Mr(r,o)){var i;for(i=1;i<t&&Mr(arguments[i],o);i++);i===t&&r.push(o)}}return r},difference:Cr,unzip:Gr,transpose:Gr,zip:Hr,object:function(n,r){for(var t={},e=0,u=Y(n);e<u;e++)r?t[n[e]]=r[e]:t[n[e][0]]=n[e][1];return t},range:function(n,r,t){null==r&&(r=n||0,n=0),t||(t=r<n?-1:1);for(var e=Math.max(Math.ceil((r-n)/t),0),u=Array(e),o=0;o<e;o++,n+=t)u[o]=n;return u},chunk:function(n,r){if(null==r||r<1)return[];for(var t=[],e=0,u=n.length;e<u;)t.push(i.call(n,e,e+=r));return t},mixin:Xr,default:tn});return Yr._=Yr,Yr}));; 48/* AUTOGENERATED: underscore.string.min.js */ 49/* 50* Underscore.string 51* (c) 2010 Esa-Matti Suuronen <esa-matti aet suuronen dot org> 52* Underscore.string is freely distributable under the terms of the MIT license. 53* Documentation: https://github.com/epeli/underscore.string 54* Some code is borrowed from MooTools and Alexandru Marasteanu. 55* Version '3.3.4' 56* @preserve 57*/ 58(function(f){if(typeof exports==="object"&&typeof module!=="undefined"){module.exports=f()}else if(typeof define==="function"&&define.amd){define([],f)}else{var g;if(typeof window!=="undefined"){g=window}else if(typeof global!=="undefined"){g=global}else if(typeof self!=="undefined"){g=self}else{g=this}g.s=f()}})(function(){var define,module,exports;return function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s}({1:[function(require,module,exports){var trim=require("./trim");var decap=require("./decapitalize");module.exports=function camelize(str,decapitalize){str=trim(str).replace(/[-_\s]+(.)?/g,function(match,c){return c?c.toUpperCase():""});if(decapitalize===true){return decap(str)}else{return str}}},{"./decapitalize":10,"./trim":65}],2:[function(require,module,exports){var makeString=require("./helper/makeString");module.exports=function capitalize(str,lowercaseRest){str=makeString(str);var remainingChars=!lowercaseRest?str.slice(1):str.slice(1).toLowerCase();return str.charAt(0).toUpperCase()+remainingChars}},{"./helper/makeString":20}],3:[function(require,module,exports){var makeString=require("./helper/makeString");module.exports=function chars(str){return makeString(str).split("")}},{"./helper/makeString":20}],4:[function(require,module,exports){module.exports=function chop(str,step){if(str==null)return[];str=String(str);step=~~step;return step>0?str.match(new RegExp(".{1,"+step+"}","g")):[str]}},{}],5:[function(require,module,exports){var capitalize=require("./capitalize");var camelize=require("./camelize");var makeString=require("./helper/makeString");module.exports=function classify(str){str=makeString(str);return capitalize(camelize(str.replace(/[\W_]/g," ")).replace(/\s/g,""))}},{"./camelize":1,"./capitalize":2,"./helper/makeString":20}],6:[function(require,module,exports){var trim=require("./trim");module.exports=function clean(str){return trim(str).replace(/\s\s+/g," ")}},{"./trim":65}],7:[function(require,module,exports){var makeString=require("./helper/makeString");var from="Ä Ã Ã¡Ã¤Ã¢Ã£Ã¥Ã¦ÄÄÄÄÄèéëêÄĥìÃïîĵÅľÅÅòóöÅôõðøÅÈÅÅ¡ÅÅ¥ÈÅ£Åùúüűûñÿýçżźž",to="aaaaaaaaaccceeeeeghiiiijllnnoooooooossssstttuuuuuunyyczzz";from+=from.toUpperCase();to+=to.toUpperCase();to=to.split("");from+="Ã";to.push("ss");module.exports=function cleanDiacritics(str){return makeString(str).replace(/.{1}/g,function(c){var index=from.indexOf(c);return index===-1?c:to[index]})}},{"./helper/makeString":20}],8:[function(require,module,exports){var makeString=require("./helper/makeString");module.exports=function(str,substr){str=makeString(str);substr=makeString(substr);if(str.length===0||substr.length===0)return 0;
58return str.split(substr).length-1}},{"./helper/makeString":20}],9:[function(require,module,exports){var trim=require("./trim");module.exports=function dasherize(str){return trim(str).replace(/([A-Z])/g,"-$1").replace(/[-_\s]+/g,"-").toLowerCase()}},{"./trim":65}],10:[function(require,module,exports){var makeString=require("./helper/makeString");module.exports=function decapitalize(str){str=makeString(str);return str.charAt(0).toLowerCase()+str.slice(1)}},{"./helper/makeString":20}],11:[function(require,module,exports){var makeString=require("./helper/makeString");function getIndent(str){var matches=str.match(/^[\s\\t]*/gm);var indent=matches[0].length;for(var i=1;i<matches.length;i++){indent=Math.min(matches[i].length,indent)}return indent}module.exports=function dedent(str,pattern){str=makeString(str);var indent=getIndent(str);var reg;if(indent===0)return str;if(typeof pattern==="string"){reg=new RegExp("^"+pattern,"gm")}else{reg=new RegExp("^[ \\t]{"+indent+"}","gm")}return str.replace(reg,"")}},{"./helper/makeString":20}],12:[function(require,module,exports){var makeString=require("./helper/makeString");var toPositive=require("./helper/toPositive");module.exports=function endsWith(str,ends,position){str=makeString(str);ends=""+ends;if(typeof position=="undefined"){position=str.length-ends.length}else{position=Math.min(toPositive(position),str.length)-ends.length}return position>=0&&str.indexOf(ends,position)===position}},{"./helper/makeString":20,"./helper/toPositive":22}],13:[function(require,module,exports){var makeString=require("./helper/makeString");var escapeChars=require("./helper/escapeChars");var regexString="[";for(var key in escapeChars){regexString+=key}regexString+="]";var regex=new RegExp(regexString,"g");module.exports=function escapeHTML(str){return makeString(str).replace(regex,function(m){return"&"+escapeChars[m]+";"})}},{"./helper/escapeChars":17,"./helper/makeString":20}],14:[function(require,module,exports){module.exports=function(){var result={};for(var prop in this){if(!this.hasOwnProperty(prop)||prop.match(/^(?:include|contains|reverse|join|map|wrap)$/))continue;result[prop]=this[prop]}return result}},{}],15:[function(require,module,exports){var makeString=require("./makeString");module.exports=function adjacent(str,direction){str=makeString(str);if(str.length===0){return""}return str.slice(0,-1)+String.fromCharCode(str.charCodeAt(str.length-1)+direction)}},{"./makeString":20}],16:[function(require,module,exports){var escapeRegExp=require("./escapeRegExp");module.exports=function defaultToWhiteSpace(characters){if(characters==null)return"\\s";else if(characters.source)return characters.source;else return"["+escapeRegExp(characters)+"]"}},{"./escapeRegExp":18}],17:[function(require,module,exports){var escapeChars={"¢":"cent","£":"pound","Â¥":"yen","â¬":"euro","©":"copy","®":"reg","<":"lt",">":"gt",'"':"quot","&":"amp","'":"#39"};module.exports=escapeChars},{}],18:[function(require,module,exports){var makeString=require("./makeString");module.exports=function escapeRegExp(str){return makeString(str).replace(/([.*+?^=!:${}()|[\]\/\\])/g,"\\$1")}},{"./makeString":20}],19:[function(require,module,exports){var htmlEntities={nbsp:" ",cent:"¢",pound:"£",yen:"Â¥",euro:"â¬",copy:"©",reg:"®",lt:"<",gt:">",quot:'"',amp:"&",apos:"'"};module.exports=htmlEntities},{}],20:[function(require,module,exports){module.exports=function makeString(object){if(object==null)return"";return""+object}},{}],21:[function(require,module,exports){module.exports=function strRepeat(str,qty){if(qty<1)return"";var result="";while(qty>0){if(qty&1)result+=str;qty>>=1,str+=str}return result}},{}],22:[function(require,module,exports){module.exports=function toPositive(number){return number<0?0:+number||0}},{}],23:[function(require,module,exports){var capitalize=require("./capitalize");var underscored=require("./underscored");var trim=require("./trim");module.exports=function humanize(str){return capitalize(trim(underscored(str).replace(/_id$/,"").replace(/_/g," ")))}},{"./capitalize":2,"./trim":65,"./underscored":67}],24:[function(require,module,exports){var makeString=require("./helper/makeString");module.exports=function include(str,needle){if(needle==="")return true;return makeString(str).indexOf(needle)!==-1}},{"./helper/makeString":20}],25:[function(require,module,exports){/* 59* Underscore.string 60* (c) 2010 Esa-Matti Suuronen <esa-matti aet suuronen dot org> 61* Underscore.string is freely distributable under the terms of the MIT license. 62* Documentation: https://github.com/epeli/underscore.string 63* Some code is borrowed from MooTools and Alexandru Marasteanu. 64* Version '3.3.4' 65* @preserve 66*/ 67 "use strict";function s(value){if(!(this instanceof s))return new s(value);this._wrapped=value}s.VERSION="3.3.4";s.isBlank=require("./isBlank");s.stripTags=require("./stripTags");s.capitalize=require("./capitalize");s.decapitalize=require("./decapitalize");s.chop=require("./chop");s.trim=require("./trim");s.clean=require("./clean");s.cleanDiacritics=require("./cleanDiacritics");s.count=require("./count");s.chars=require("./chars");s.swapCase=require("./swapCase");s.escapeHTML=require("./escapeHTML");s.unescapeHTML=require("./unescapeHTML");s.splice=require("./splice");s.insert=require("./insert");
67s.replaceAll=require("./replaceAll");s.include=require("./include");s.join=require("./join");s.lines=require("./lines");s.dedent=require("./dedent");s.reverse=require("./reverse");s.startsWith=require("./startsWith");s.endsWith=require("./endsWith");s.pred=require("./pred");s.succ=require("./succ");s.titleize=require("./titleize");s.camelize=require("./camelize");s.underscored=require("./underscored");s.dasherize=require("./dasherize");s.classify=require("./classify");s.humanize=require("./humanize");s.ltrim=require("./ltrim");s.rtrim=require("./rtrim");s.truncate=require("./truncate");s.prune=require("./prune");s.words=require("./words");s.pad=require("./pad");s.lpad=require("./lpad");s.rpad=require("./rpad");s.lrpad=require("./lrpad");s.sprintf=require("./sprintf");s.vsprintf=require("./vsprintf");s.toNumber=require("./toNumber");s.numberFormat=require("./numberFormat");s.strRight=require("./strRight");s.strRightBack=require("./strRightBack");s.strLeft=require("./strLeft");s.strLeftBack=require("./strLeftBack");s.toSentence=require("./toSentence");s.toSentenceSerial=require("./toSentenceSerial");s.slugify=require("./slugify");s.surround=require("./surround");s.quote=require("./quote");s.unquote=require("./unquote");s.repeat=require("./repeat");s.naturalCmp=require("./naturalCmp");s.levenshtein=require("./levenshtein");s.toBoolean=require("./toBoolean");s.exports=require("./exports");s.escapeRegExp=require("./helper/escapeRegExp");s.wrap=require("./wrap");s.map=require("./map");s.strip=s.trim;s.lstrip=s.ltrim;s.rstrip=s.rtrim;s.center=s.lrpad;s.rjust=s.lpad;s.ljust=s.rpad;s.contains=s.include;s.q=s.quote;s.toBool=s.toBoolean;s.camelcase=s.camelize;s.mapChars=s.map;s.prototype={value:function value(){return this._wrapped}};function fn2method(key,fn){if(typeof fn!=="function")return;s.prototype[key]=function(){var args=[this._wrapped].concat(Array.prototype.slice.call(arguments));var res=fn.apply(null,args);return typeof res==="string"?new s(res):res}}for(var key in s)fn2method(key,s[key]);fn2method("tap",function tap(string,fn){return fn(string)});function prototype2method(methodName){fn2method(methodName,function(context){var args=Array.prototype.slice.call(arguments,1);return String.prototype[methodName].apply(context,args)})}var prototypeMethods=["toUpperCase","toLowerCase","split","replace","slice","substring","substr","concat"];for(var method in prototypeMethods)prototype2method(prototypeMethods[method]);module.exports=s},{"./camelize":1,"./capitalize":2,"./chars":3,"./chop":4,"./classify":5,"./clean":6,"./cleanDiacritics":7,"./count":8,"./dasherize":9,"./decapitalize":10,"./dedent":11,"./endsWith":12,"./escapeHTML":13,"./exports":14,"./helper/escapeRegExp":18,"./humanize":23,"./include":24,"./insert":26,"./isBlank":27,"./join":28,"./levenshtein":29,"./lines":30,"./lpad":31,"./lrpad":32,"./ltrim":33,"./map":34,"./naturalCmp":35,"./numberFormat":38,"./pad":39,"./pred":40,"./prune":41,"./quote":42,"./repeat":43,"./replaceAll":44,"./reverse":45,"./rpad":46,"./rtrim":47,"./slugify":48,"./splice":49,"./sprintf":50,"./startsWith":51,"./strLeft":52,"./strLeftBack":53,"./strRight":54,"./strRightBack":55,"./stripTags":56,"./succ":57,"./surround":58,"./swapCase":59,"./titleize":60,"./toBoolean":61,"./toNumber":62,"./toSentence":63,"./toSentenceSerial":64,"./trim":65,"./truncate":66,"./underscored":67,"./unescapeHTML":68,"./unquote":69,"./vsprintf":70,"./words":71,"./wrap":72}],26:[function(require,module,exports){var splice=require("./splice");module.exports=function insert(str,i,substr){return splice(str,i,0,substr)}},{"./splice":49}],27:[function(require,module,exports){var makeString=require("./helper/makeString");module.exports=function isBlank(str){return/^\s*$/.test(makeString(str))}},{"./helper/makeString":20}],28:[function(require,module,exports){var makeString=require("./helper/makeString");var slice=[].slice;module.exports=function join(){var args=slice.call(arguments),separator=args.shift();return args.join(makeString(separator))}},{"./helper/makeString":20}],29:[function(require,module,exports){var makeString=require("./helper/makeString");module.exports=function levenshtein(str1,str2){"use strict";str1=makeString(str1);str2=makeString(str2);if(str1===str2)return 0;if(!str1||!str2)return Math.max(str1.length,str2.length);var prevRow=new Array(str2.length+1);for(var i=0;i<prevRow.length;++i){prevRow[i]=i}for(i=0;i<str1.length;++i){var nextCol=i+1;for(var j=0;j<str2.length;++j){var curCol=nextCol;nextCol=prevRow[j]+(str1.charAt(i)===str2.charAt(j)?0:1);var tmp=curCol+1;if(nextCol>tmp){nextCol=tmp}tmp=prevRow[j+1]+1;if(nextCol>tmp){nextCol=tmp}prevRow[j]=curCol}prevRow[j]=nextCol}return nextCol}},{"./helper/makeString":20}],30:[function(require,module,exports){module.exports=function lines(str){if(str==null)return[];return String(str).split(/\r\n?|\n/)}},{}],31:[function(require,module,exports){var pad=require("./pad");module.exports=function lpad(str,length,padStr){return pad(str,length,padStr)}}
67,{"./pad":39}],32:[function(require,module,exports){var pad=require("./pad");module.exports=function lrpad(str,length,padStr){return pad(str,length,padStr,"both")}},{"./pad":39}],33:[function(require,module,exports){var makeString=require("./helper/makeString");var defaultToWhiteSpace=require("./helper/defaultToWhiteSpace");var nativeTrimLeft=String.prototype.trimLeft;module.exports=function ltrim(str,characters){str=makeString(str);if(!characters&&nativeTrimLeft)return nativeTrimLeft.call(str);characters=defaultToWhiteSpace(characters);return str.replace(new RegExp("^"+characters+"+"),"")}},{"./helper/defaultToWhiteSpace":16,"./helper/makeString":20}],34:[function(require,module,exports){var makeString=require("./helper/makeString");module.exports=function(str,callback){str=makeString(str);if(str.length===0||typeof callback!=="function")return str;return str.replace(/./g,callback)}},{"./helper/makeString":20}],35:[function(require,module,exports){module.exports=function naturalCmp(str1,str2){if(str1==str2)return 0;if(!str1)return-1;if(!str2)return 1;var cmpRegex=/(\.\d+|\d+|\D+)/g,tokens1=String(str1).match(cmpRegex),tokens2=String(str2).match(cmpRegex),count=Math.min(tokens1.length,tokens2.length);for(var i=0;i<count;i++){var a=tokens1[i],b=tokens2[i];if(a!==b){var num1=+a;var num2=+b;if(num1===num1&&num2===num2){return num1>num2?1:-1}return a<b?-1:1}}if(tokens1.length!=tokens2.length)return tokens1.length-tokens2.length;return str1<str2?-1:1}},{}],36:[function(require,module,exports){(function(window){var re={not_string:/[^s]/,number:/[diefg]/,json:/[j]/,not_json:/[^j]/,text:/^[^\x25]+/,modulo:/^\x25{2}/,placeholder:/^\x25(?:([1-9]\d*)\$|\(([^\)]+)\))?(\+)?(0|'[^$])?(-)?(\d+)?(?:\.(\d+))?([b-gijosuxX])/,key:/^([a-z_][a-z_\d]*)/i,key_access:/^\.([a-z_][a-z_\d]*)/i,index_access:/^\[(\d+)\]/,sign:/^[\+\-]/};function sprintf(){var key=arguments[0],cache=sprintf.cache;if(!(cache[key]&&cache.hasOwnProperty(key))){cache[key]=sprintf.parse(key)}return sprintf.format.call(null,cache[key],arguments)}sprintf.format=function(parse_tree,argv){var cursor=1,tree_length=parse_tree.length,node_type="",arg,output=[],i,k,match,pad,pad_character,pad_length,is_positive=true,sign="";for(i=0;i<tree_length;i++){node_type=get_type(parse_tree[i]);if(node_type==="string"){output[output.length]=parse_tree[i]}else if(node_type==="array"){match=parse_tree[i];if(match[2]){arg=argv[cursor];for(k=0;k<match[2].length;k++){if(!arg.hasOwnProperty(match[2][k])){throw new Error(sprintf("[sprintf] property '%s' does not exist",match[2][k]))}arg=arg[match[2][k]]}}else if(match[1]){arg=argv[match[1]]}else{arg=argv[cursor++]}if(get_type(arg)=="function"){arg=arg()}if(re.not_string.test(match[8])&&re.not_json.test(match[8])&&(get_type(arg)!="number"&&isNaN(arg))){throw new TypeError(sprintf("[sprintf] expecting number but found %s",get_type(arg)))}if(re.number.test(match[8])){is_positive=arg>=0}switch(match[8]){case"b":arg=arg.toString(2);break;case"c":arg=String.fromCharCode(arg);break;case"d":case"i":arg=parseInt(arg,10);break;case"j":arg=JSON.stringify(arg,null,match[6]?parseInt(match[6]):0);break;case"e":arg=match[7]?arg.toExponential(match[7]):arg.toExponential();break;case"f":arg=match[7]?parseFloat(arg).toFixed(match[7]):parseFloat(arg);break;case"g":arg=match[7]?parseFloat(arg).toPrecision(match[7]):parseFloat(arg);break;case"o":arg=arg.toString(8);break;case"s":arg=(arg=String(arg))&&match[7]?arg.substring(0,match[7]):arg;break;case"u":arg=arg>>>0;break;case"x":arg=arg.toString(16);break;case"X":arg=arg.toString(16).toUpperCase();break}if(re.json.test(match[8])){output[output.length]=arg}else{if(re.number.test(match[8])&&(!is_positive||match[3])){sign=is_positive?"+":"-";arg=arg.toString().replace(re.sign,"")}else{sign=""}pad_character=match[4]?match[4]==="0"?"0":match[4].charAt(1):" ";pad_length=match[6]-(sign+arg).length;pad=match[6]?pad_length>0?str_repeat(pad_character,pad_length):"":"";output[output.length]=match[5]?sign+arg+pad:pad_character==="0"?sign+pad+arg:pad+sign+arg}}}return output.join("")};sprintf.cache={};sprintf.parse=function(fmt){var _fmt=fmt,match=[],parse_tree=[],arg_names=0;while(_fmt){if((match=re.text.exec(_fmt))!==null){parse_tree[parse_tree.length]=match[0]}else if((match=re.modulo.exec(_fmt))!==null){parse_tree[parse_tree.length]="%"}else if((match=re.placeholder.exec(_fmt))!==null){if(match[2]){arg_names|=1;var field_list=[],replacement_field=match[2],field_match=[];if((field_match=re.key.exec(replacement_field))!==null){field_list[field_list.length]=field_match[1];while((replacement_field=replacement_field.substring(field_match[0].length))!==""){if((field_match=re.key_access.exec(replacement_field))!==null){field_list[field_list.length]=field_match[1]}else if((field_match=re.index_access.exec(replacement_field))!==null){field_list[field_list.length]=field_match[1]}else{throw new SyntaxError("[sprintf] failed to parse named argument key")}}}else{throw new SyntaxError("[sprintf] failed to parse named argument key")}match[2]=field_list}else{arg_names|=2}if(arg_names===3){throw new Error("[sprintf] mixing positional and named placeholders is not (yet) supported")}parse_tree[parse_tree.length]=match}else{throw new SyntaxError("[sprintf] unexpected placeholder")}_fmt=_fmt.substring(match[0].length)}return parse_tree};var vsprintf=function(fmt,argv,_argv){_argv=(argv||[]).slice(0);_argv.splice(0,0,fmt);return sprintf.apply(null,_argv)};function get_type(variable){return Object.prototype.toString.call(variable).slice(8,-1).toLowerCase()}function str_repeat(input,multiplier){return Array(multiplier+1).join(input)}if(typeof exports!=="undefined"){exports.sprintf=sprintf;exports.vsprintf=vsprintf}else{window.sprintf=sprintf;window.vsprintf=vsprintf;if(typeof define==="function"&&define.amd){define(function(){return{sprintf:sprintf,vsprintf:vsprintf}})}}})(typeof window==="undefined"?this:window)},{}],37:[function(require,module,exports){(function(global){module.exports=deprecate;function deprecate(fn,msg){if(config("noDeprecation")){return fn}var warned=false;function deprecated(){if(!warned){if(config("throwDeprecation")){throw new Error(msg)}else if(config("traceDeprecation")){console.trace(msg)}else{console.warn(msg)}warned=true}return fn.apply(this,arguments)}return deprecated}function config(name){try{if(!global.localStorage)return false}catch(_){return false}var val=global.localStorage[name];if(null==val)return false;return String(val).toLowerCase()==="true"}}).call(this,typeof global!=="undefined"?global:typeof self!=="undefined"?self:typeof window!=="undefined"?window:{})},{}],38:[function(require,module,exports){module.exports=function numberFormat(number,dec,dsep,tsep){if(isNaN(number)||number==null)return"";number=number.toFixed(~~dec);
67tsep=typeof tsep=="string"?tsep:",";var parts=number.split("."),fnums=parts[0],decimals=parts[1]?(dsep||".")+parts[1]:"";return fnums.replace(/(\d)(?=(?:\d{3})+$)/g,"$1"+tsep)+decimals}},{}],39:[function(require,module,exports){var makeString=require("./helper/makeString");var strRepeat=require("./helper/strRepeat");module.exports=function pad(str,length,padStr,type){str=makeString(str);length=~~length;var padlen=0;if(!padStr)padStr=" ";else if(padStr.length>1)padStr=padStr.charAt(0);switch(type){case"right":padlen=length-str.length;return str+strRepeat(padStr,padlen);case"both":padlen=length-str.length;return strRepeat(padStr,Math.ceil(padlen/2))+str+strRepeat(padStr,Math.floor(padlen/2));default:padlen=length-str.length;return strRepeat(padStr,padlen)+str}}},{"./helper/makeString":20,"./helper/strRepeat":21}],40:[function(require,module,exports){var adjacent=require("./helper/adjacent");module.exports=function succ(str){return adjacent(str,-1)}},{"./helper/adjacent":15}],41:[function(require,module,exports){var makeString=require("./helper/makeString");var rtrim=require("./rtrim");module.exports=function prune(str,length,pruneStr){str=makeString(str);length=~~length;pruneStr=pruneStr!=null?String(pruneStr):"...";if(str.length<=length)return str;var tmpl=function(c){return c.toUpperCase()!==c.toLowerCase()?"A":" "},template=str.slice(0,length+1).replace(/.(?=\W*\w*$)/g,tmpl);if(template.slice(template.length-2).match(/\w\w/))template=template.replace(/\s*\S+$/,"");else template=rtrim(template.slice(0,template.length-1));return(template+pruneStr).length>str.length?str:str.slice(0,template.length)+pruneStr}},{"./helper/makeString":20,"./rtrim":47}],42:[function(require,module,exports){var surround=require("./surround");module.exports=function quote(str,quoteChar){return surround(str,quoteChar||'"')}},{"./surround":58}],43:[function(require,module,exports){var makeString=require("./helper/makeString");var strRepeat=require("./helper/strRepeat");module.exports=function repeat(str,qty,separator){str=makeString(str);qty=~~qty;if(separator==null)return strRepeat(str,qty);for(var repeat=[];qty>0;repeat[--qty]=str){}return repeat.join(separator)}},{"./helper/makeString":20,"./helper/strRepeat":21}],44:[function(require,module,exports){var makeString=require("./helper/makeString");module.exports=function replaceAll(str,find,replace,ignorecase){var flags=ignorecase===true?"gi":"g";var reg=new RegExp(find,flags);return makeString(str).replace(reg,replace)}},{"./helper/makeString":20}],45:[function(require,module,exports){var chars=require("./chars");module.exports=function reverse(str){return chars(str).reverse().join("")}},{"./chars":3}],46:[function(require,module,exports){var pad=require("./pad");module.exports=function rpad(str,length,padStr){return pad(str,length,padStr,"right")}},{"./pad":39}],47:[function(require,module,exports){var makeString=require("./helper/makeString");var defaultToWhiteSpace=require("./helper/defaultToWhiteSpace");var nativeTrimRight=String.prototype.trimRight;module.exports=function rtrim(str,characters){str=makeString(str);if(!characters&&nativeTrimRight)return nativeTrimRight.call(str);characters=defaultToWhiteSpace(characters);return str.replace(new RegExp(characters+"+$"),"")}},{"./helper/defaultToWhiteSpace":16,"./helper/makeString":20}],48:[function(require,module,exports){var trim=require("./trim");var dasherize=require("./dasherize");var cleanDiacritics=require("./cleanDiacritics");module.exports=function slugify(str){return trim(dasherize(cleanDiacritics(str).replace(/[^\w\s-]/g,"-").toLowerCase()),"-")}},{"./cleanDiacritics":7,"./dasherize":9,"./trim":65}],49:[function(require,module,exports){var chars=require("./chars");module.exports=function splice(str,i,howmany,substr){var arr=chars(str);arr.splice(~~i,~~howmany,substr);return arr.join("")}},{"./chars":3}],50:[function(require,module,exports){var deprecate=require("util-deprecate");module.exports=deprecate(require("sprintf-js").sprintf,"sprintf() will be removed in the next major release, use the sprintf-js package instead.")},{"sprintf-js":36,"util-deprecate":37}],51:[function(require,module,exports){var makeString=require("./helper/makeString");var toPositive=require("./helper/toPositive");module.exports=function startsWith(str,starts,position){str=makeString(str);starts=""+starts;position=position==null?0:Math.min(toPositive(position),str.length);return str.lastIndexOf(starts,position)===position}},{"./helper/makeString":20,"./helper/toPositive":22}],52:[function(require,module,exports){var makeString=require("./helper/makeString");module.exports=function strLeft(str,sep){str=makeString(str);sep=makeString(sep);var pos=!sep?-1:str.indexOf(sep);return~pos?str.slice(0,pos):str}},{"./helper/makeString":20}],53:[function(require,module,exports){var makeString=require("./helper/makeString");module.exports=function strLeftBack(str,sep){str=makeString(str);sep=makeString(sep);var pos=str.lastIndexOf(sep);return~pos?str.slice(0,pos):str}},{"./helper/makeString":20}],54:[function(require,module,exports){var makeString=require("./helper/makeString");module.exports=function strRight(str,sep){str=makeString(str);sep=makeString(sep);var pos=!sep?-1:str.indexOf(sep);return~pos?str.slice(pos+sep.length,str.length):str}},{"./helper/makeString":20}],55:[function(require,module,exports){var makeString=require("./helper/makeString");module.exports=function strRightBack(str,sep){str=makeString(str);sep=makeString(sep);var pos=!sep?-1:str.lastIndexOf(sep);return~pos?str.slice(pos+sep.length,str.length):str}},{"./helper/makeString":20}],56:[function(require,module,exports){var makeString=require("./helper/makeString");module.exports=function stripTags(str){return makeString(str).replace(/<\/?[^>]+>/g,"")}},{"./helper/makeString":20}],57:[function(require,module,exports){var adjacent=require("./helper/adjacent");module.exports=function succ(str){return adjacent(str,1)}},{"./helper/adjacent":15}],58:[function(require,module,exports){module.exports=function surround(str,wrapper){return[wrapper,str,wrapper].join("")}},{}],59:[function(require,module,exports){var makeString=require("./helper/makeString");module.exports=function swapCase(str){return makeString(str).replace(/\S/g,function(c){return c===c.toUpperCase()?c.toLowerCase():c.toUpperCase()})}},{"./helper/makeString":20}],60:[function(require,module,exports){var makeString=require("./helper/makeString");module.exports=function titleize(str){return makeString(str).toLowerCase().replace(/(?:^|\s|-)\S/g,function(c){return c.toUpperCase()})}},{"./helper/makeString":20}],61:[function(require,module,exports){var trim=require("./trim");function boolMatch(s,matchers){var i,matcher,down=s.toLowerCase();matchers=[].concat(matchers);for(i=0;i<matchers.length;i+=1){matcher=matchers[i];if(!matcher)continue;if(matcher.test&&matcher.test(s))return true;if(matcher.toLowerCase()===down)return true}}module.exports=function toBoolean(str,trueValues,falseValues){if(typeof str==="number")str=""+str;if(typeof str!=="string")return!!str;str=trim(str);if(boolMatch(str,trueValues||["true","1"]))return true;if(boolMatch(str,falseValues||["false","0"]))return false}},{"./trim":65}],62:[function(require,module,exports){module.exports=function toNumber(num,precision){if(num==null)return 0;var factor=Math.pow(10,isFinite(precision)?precision:0);return Math.round(num*factor)/factor}},{}],63:[function(require,module,exports){var rtrim=require("./rtrim");module.exports=function toSentence(array,separator,lastSeparator,serial){separator=separator||", ";lastSeparator=lastSeparator||" and ";var a=array.slice(),lastMember=a.pop();if(array.length>2&&serial)lastSeparator=rtrim(separator)+lastSeparator;return a.length?a.join(separator)+lastSeparator+lastMember:lastMember}},{"./rtrim":47}],64:[function(require,module,exports){var toSentence=require("./toSentence");module.exports=function toSentenceSerial(array,sep,lastSep){return toSentence(array,sep,lastSep,true)}},{"./toSentence":63}],65:[function(require,module,exports){var makeString=require("./helper/makeString");var defaultToWhiteSpace=require("./helper/defaultToWhiteSpace");var nativeTrim=String.prototype.trim;module.exports=function trim(str,characters){str=makeString(str);if(!characters&&nativeTrim)return nativeTrim.call(str);characters=defaultToWhiteSpace(characters);return str.replace(new RegExp("^"+characters+"+|"+characters+"+$","g"),"")}},{"./helper/defaultToWhiteSpace":16,"./helper/makeString":20}],66:[function(require,module,exports){var makeString=require("./helper/makeString");module.exports=function truncate(str,length,truncateStr){str=makeString(str);truncateStr=truncateStr||"...";length=~~length;return str.length>length?str.slice(0,length)+truncateStr:str}},{"./helper/makeString":20}],67:[function(require,module,exports){var trim=require("./trim");module.exports=function underscored(str){return trim(str).replace(/([a-z\d])([A-Z]+)/g,"$1_$2").replace(/[-\s]+/g,"_").toLowerCase()}},{"./trim":65}],68:[function(require,module,exports){var makeString=require("./helper/makeString");var htmlEntities=require("./helper/htmlEntities");module.exports=function unescapeHTML(str){return makeString(str).replace(/\&([^;]+);/g,function(entity,entityCode){var match;if(entityCode in htmlEntities){return htmlEntities[entityCode]}else if(match=entityCode.match(/^#x([\da-fA-F]+)$/)){return String.fromCharCode(parseInt(match[1],16))}else if(match=entityCode.match(/^#(\d+)$/)){return String.fromCharCode(~~match[1])}else{return entity}})}},{"./helper/htmlEntities":19,"./helper/makeString":20}],69:[function(require,module,exports){module.exports=function unquote(str,quoteChar){quoteChar=quoteChar||'"';if(str[0]===quoteChar&&str[str.length-1]===quoteChar)return str.slice(1,str.length-1);else return str}},{}],70:[function(require,module,exports){var deprecate=require("util-deprecate");module.exports=deprecate(require("sprintf-js").vsprintf,"vsprintf() will be removed in the next major release, use the sprintf-js package instead.")},{"sprintf-js":36,"util-deprecate":37}],71:[function(require,module,exports){var isBlank=require("./isBlank");var trim=require("./trim");module.exports=function words(str,delimiter){if(isBlank(str))return[];return trim(str,delimiter).split(delimiter||/\s+/)}},{"./isBlank":27,"./trim":65}],72:[function(require,module,exports){var makeString=require("./helper/makeString");module.exports=function wrap(str,options){str=makeString(str);options=options||{};var width=options.width||75;var seperator=options.seperator||"\n";var cut=options.cut||false;var preserveSpaces=options.preserveSpaces||false;var trailingSpaces=options.trailingSpaces||false;var result;if(width<=0){return str}else if(!cut){var words=str.split(" ");var current_column=0;result="";while(words.length>0){if(1+words[0].length+current_column>width){if(current_column>0){if(preserveSpaces){result+=" ";current_column++}else if(trailingSpaces){while(current_column<width){result+=" ";current_column++}}result+=seperator;current_column=0}}if(current_column>0){result+=" ";current_column++}result+=words[0];current_column+=words[0].length;words.shift()}if(trailingSpaces){while(current_column<width){result+=" ";current_column++}}return result}else{var index=0;result="";while(index<str.length){if(index%width==0&&index>0){result+=seperator}result+=str.charAt(index);index++}if(trailingSpaces){while(index%width>0){result+=" ";index++}}return result}}},{"./helper/makeString":20}]},{},[25])(25)}); 68 69_.mixin(s.exports());;
70/* AUTOGENERATED: bootstrap.min.js */
vendor: 39,680 bytes, lines 71-76
71/*! 72 * Bootstrap v3.4.1 (https://getbootstrap.com/) 73 * Copyright 2011-2019 Twitter, Inc. 74 * Licensed under the MIT license 75 */ 76if("undefined"==typeof jQuery)throw new Error("Bootstrap's JavaScript requires jQuery");!function(t){"use strict";var e=jQuery.fn.jquery.split(" ")[0].split(".");if(e[0]<2&&e[1]<9||1==e[0]&&9==e[1]&&e[2]<1||3<e[0])throw new Error("Bootstrap's JavaScript requires jQuery version 1.9.1 or higher, but lower than version 4")}(),function(n){"use strict";n.fn.emulateTransitionEnd=function(t){var e=!1,i=this;n(this).one("bsTransitionEnd",function(){e=!0});return setTimeout(function(){e||n(i).trigger(n.support.transition.end)},t),this},n(function(){n.support.transition=function o(){var t=document.createElement("bootstrap"),e={WebkitTransition:"webkitTransitionEnd",MozTransition:"transitionend",OTransition:"oTransitionEnd otransitionend",transition:"transitionend"};for(var i in e)if(t.style[i]!==undefined)return{end:e[i]};return!1}(),n.support.transition&&(n.event.special.bsTransitionEnd={bindType:n.support.transition.end,delegateType:n.support.transition.end,handle:function(t){if(n(t.target).is(this))return t.handleObj.handler.apply(this,arguments)}})})}(jQuery),function(s){"use strict";var e='[data-dismiss="alert"]',a=function(t){s(t).on("click",e,this.close)};a.VERSION="3.4.1",a.TRANSITION_DURATION=150,a.prototype.close=function(t){var e=s(this),i=e.attr("data-target");i||(i=(i=e.attr("href"))&&i.replace(/.*(?=#[^\s]*$)/,"")),i="#"===i?[]:i;var o=s(document).find(i);function n(){o.detach().trigger("closed.bs.alert").remove()}t&&t.preventDefault(),o.length||(o=e.closest(".alert")),o.trigger(t=s.Event("close.bs.alert")),t.isDefaultPrevented()||(o.removeClass("in"),s.support.transition&&o.hasClass("fade")?o.one("bsTransitionEnd",n).emulateTransitionEnd(a.TRANSITION_DURATION):n())};var t=s.fn.alert;s.fn.alert=function o(i){return this.each(function(){var t=s(this),e=t.data("bs.alert");e||t.data("bs.alert",e=new a(this)),"string"==typeof i&&e[i].call(t)})},s.fn.alert.Constructor=a,s.fn.alert.noConflict=function(){return s.fn.alert=t,this},s(document).on("click.bs.alert.data-api",e,a.prototype.close)}(jQuery),function(s){"use strict";var n=function(t,e){this.$element=s(t),this.options=s.extend({},n.DEFAULTS,e),this.isLoading=!1};function i(o){return this.each(function(){var t=s(this),e=t.data("bs.button"),i="object"==typeof o&&o;e||t.data("bs.button",e=new n(this,i)),"toggle"==o?e.toggle():o&&e.setState(o)})}n.VERSION="3.4.1",n.DEFAULTS={loadingText:"loading..."},n.prototype.setState=function(t){var e="disabled",i=this.$element,o=i.is("input")?"val":"html",n=i.data();t+="Text",null==n.resetText&&i.data("resetText",i[o]()),setTimeout(s.proxy(function(){i[o](null==n[t]?this.options[t]:n[t]),"loadingText"==t?(this.isLoading=!0,i.addClass(e).attr(e,e).prop(e,!0)):this.isLoading&&(this.isLoading=!1,i.removeClass(e).removeAttr(e).prop(e,!1))},this),0)},n.prototype.toggle=function(){var t=!0,e=this.$element.closest('[data-toggle="buttons"]');if(e.length){var i=this.$element.find("input");"radio"==i.prop("type")?(i.prop("checked")&&(t=!1),e.find(".active").removeClass("active"),this.$element.addClass("active")):"checkbox"==i.prop("type")&&(i.prop("checked")!==this.$element.hasClass("active")&&(t=!1),this.$element.toggleClass("active")),i.prop("checked",this.$element.hasClass("active")),t&&i.trigger("change")}else this.$element.attr("aria-pressed",!this.$element.hasClass("active")),this.$element.toggleClass("active")};var t=s.fn.button;s.fn.button=i,s.fn.button.Constructor=n,s.fn.button.noConflict=function(){return s.fn.button=t,this},s(document).on("click.bs.button.data-api",'[data-toggle^="button"]',function(t){var e=s(t.target).closest(".btn");i.call(e,"toggle"),s(t.target).is('input[type="radio"], input[type="checkbox"]')||(t.preventDefault(),e.is("input,button")?e.trigger("focus"):e.find("input:visible,button:visible").first().trigger("focus"))}).on("focus.bs.button.data-api blur.bs.button.data-api",'[data-toggle^="button"]',function(t){s(t.target).closest(".btn").toggleClass("focus",/^focus(in)?$/.test(t.type))})}(jQuery),function(p){"use strict";var c=function(t,e){this.$element=p(t),this.$indicators=this.$element.find(".carousel-indicators"),this.options=e,this.paused=null,this.sliding=null,this.interval=null,this.$active=null,this.$items=null,this.options.keyboard&&this.$element.on("keydown.bs.carousel",p.proxy(this.keydown,this)),"hover"==this.options.pause&&!("ontouchstart"in document.documentElement)&&this.$element.on("mouseenter.bs.carousel",p.proxy(this.pause,this)).on("mouseleave.bs.carousel",p.proxy(this.cycle,this))};function r(n){return this.each(function(){var t=p(this),e=t.data("bs.carousel"),i=p.extend({},c.DEFAULTS,t.data(),"object"==typeof n&&n),o="string"==typeof n?n:i.slide;e||t.data("bs.carousel",e=new c(this,i)),"number"==typeof n?e.to(n):o?e[o]():i.interval&&e.pause().cycle()})}c.VERSION="3.4.1",c.TRANSITION_DURATION=600,c.DEFAULTS={interval:5e3,pause:"hover",wrap:!0,keyboard:!0},c.prototype.keydown=function(t){if(!/input|textarea/i.test(t.target.tagName)){switch(t.which){case 37:this.prev();break;case 39:this.next();break;default:return}t.preventDefault()}},c.prototype.cycle=function(t){return t||(this.paused=!1),this.interval&&clearInterval(this.interval),this.options.interval&&!this.paused&&(this.interval=setInterval(p.proxy(this.next,this),this.options.interval)),this},c.prototype.getItemIndex=function(t){return this.$items=t.parent().children(".item"),this.$items.index(t||this.$active)},c.prototype.getItemForDirection=function(t,e){var i=this.getItemIndex(e);if(("prev"==t&&0===i||"next"==t&&i==this.$items.length-1)&&!this.options.wrap)return e;var o=(i+("prev"==t?-1:1))%this.$items.length;return this.$items.eq(o)},c.prototype.to=function(t){var e=this,i=this.getItemIndex(this.$active=this.$element.find(".item.active"));if(!(t>this.$items.length-1||t<0))return this.sliding?this.$element.one("slid.bs.carousel",function(){e.to(t)}):i==t?this.pause().cycle():this.slide(i<t?"next":"prev",this.$items.eq(t))},c.prototype.pause=function(t){return t||(this.paused=!0),this.$element.find(".next, .prev").length&&p.support.transition&&(this.$element.trigger(p.support.transition.end),this.cycle(!0)),this.interval=clearInterval(this.interval),this},c.prototype.next=function(){if(!this.sliding)return this.slide("next")},c.prototype.prev=function(){if(!this.sliding)return this.slide("prev")},c.prototype.slide=function(t,e){var i=this.$element.find(".item.active"),o=e||this.getItemForDirection(t,i),n=this.interval,s="next"==t?"left":"right",a=this;if(o.hasClass("active"))return this.sliding=!1;var r=o[0],l=p.Event("slide.bs.carousel",{relatedTarget:r,direction:s});if(this.$element.trigger(l),!l.isDefaultPrevented()){if(this.sliding=!0,n&&this.pause(),this.$indicators.length){this.$indicators.find(".active").removeClass("active");var h=p(this.$indicators.children()[this.getItemIndex(o)]);h&&h.addClass("active")}var d=p.Event("slid.bs.carousel",{relatedTarget:r,direction:s});return p.support.transition&&this.$element.hasClass("slide")?(o.addClass(t),"object"==typeof o&&o.length&&o[0].offsetWidth,i.addClass(s),o.addClass(s),i.one("bsTransitionEnd",function(){o.removeClass([t,s].join(" ")).addClass("active"),i.removeClass(["active",s].join(" ")),a.sliding=!1,setTimeout(function(){a.$element.trigger(d)},0)}).emulateTransitionEnd(c.TRANSITION_DURATION)):(i.removeClass("active"),o.addClass("active"),this.sliding=!1,this.$element.trigger(d)),n&&this.cycle(),this}};var t=p.fn.carousel;p.fn.carousel=r,p.fn.carousel.Constructor=c,p.fn.carousel.noConflict=function(){return p.fn.carousel=t,this};var e=function(t){var e=p(this),i=e.attr("href");i&&(i=i.replace(/.*(?=#[^\s]+$)/,""));var o=e.attr("data-target")||i,n=p(document).find(o);if(n.hasClass("carousel")){var s=p.extend({},n.data(),e.data()),a=e.attr("data-slide-to");a&&(s.interval=!1),r.call(n,s),a&&n.data("bs.carousel").to(a),t.preventDefault()}};p(document).on("click.bs.carousel.data-api","[data-slide]",e).on("click.bs.carousel.data-api","[data-slide-to]",e),p(window).on("load",function(){p('[data-ride="carousel"]').each(function(){var t=p(this);r.call(t,t.data())})})}(jQuery),function(a){"use strict";var r=function(t,e){this.$element=a(t),this.options=a.extend({},r.DEFAULTS,e),this.$trigger=a('[data-toggle="collapse"][href="#'+t.id+'"],[data-toggle="collapse"][data-target="#'+t.id+'"]'),this.transitioning=null,this.options.parent?this.$parent=this.getParent():this.addAriaAndCollapsedClass(this.$element,this.$trigger),this.options.toggle&&this.toggle()};function n(t){var e,i=t.attr("data-target")||(e=t.attr("href"))&&e.replace(/.*(?=#[^\s]+$)/,"");return a(document).find(i)}function l(o){return this.each(function(){var t=a(this),e=t.data("bs.collapse"),i=a.extend({},r.DEFAULTS,t.data(),"object"==typeof o&&o);!e&&i.toggle&&/show|hide/.test(o)&&(i.toggle=!1),e||t.data("bs.collapse",e=new r(this,i)),"string"==typeof o&&e[o]()})}r.VERSION="3.4.1",r.TRANSITION_DURATION=350,r.DEFAULTS={toggle:!0},r.prototype.dimension=function(){return this.$element.hasClass("width")?"width":"height"},r.prototype.show=function(){if(!this.transitioning&&!this.$element.hasClass("in")){var t,e=this.$parent&&this.$parent.children(".panel").children(".in, .collapsing");if(!(e&&e.length&&(t=e.data("bs.collapse"))&&t.transitioning)){var i=a.Event("show.bs.collapse");if(this.$element.trigger(i),!i.isDefaultPrevented()){e&&e.length&&(l.call(e,"hide"),t||e.data("bs.collapse",null));var o=this.dimension();this.$element.removeClass("collapse").addClass("collapsing")[o](0).attr("aria-expanded",!0),this.$trigger.removeClass("collapsed").attr("aria-expanded",!0),this.transitioning=1;var n=function(){this.$element.removeClass("collapsing").addClass("collapse in")[o](""),this.transitioning=0,this.$element.trigger("shown.bs.collapse")};if(!a.support.transition)return n.call(this);var s=a.camelCase(["scroll",o].join("-"));this.$element.one("bsTransitionEnd",a.proxy(n,this)).emulateTransitionEnd(r.TRANSITION_DURATION)[o](this.$element[0][s])}}}},r.prototype.hide=function(){if(!this.transitioning&&this.$element.hasClass("in")){var t=a.Event("hide.bs.collapse");if(this.$element.trigger(t),!t.isDefaultPrevented()){var e=this.dimension();this.$element[e](this.$element[e]())[0].offsetHeight,this.$element.addClass("collapsing").removeClass("collapse in").attr("aria-expanded",!1),this.$trigger.addClass("collapsed").attr("aria-expanded",!1),this.transitioning=1;var i=function(){this.transitioning=0,this.$element.removeClass("collapsing").addClass("collapse").trigger("hidden.bs.collapse")};if(!a.support.transition)return i.call(this);this.$element[e](0).one("bsTransitionEnd",a.proxy(i,this)).emulateTransitionEnd(r.TRANSITION_DURATION)}}},r.prototype.toggle=function(){this[this.$element.hasClass("in")?"hide":"show"]()},r.prototype.getParent=function(){return a(document).find(this.options.parent).find('[data-toggle="collapse"][data-parent="'+this.options.parent+'"]').each(a.proxy(function(t,e){var i=a(e);this.addAriaAndCollapsedClass(n(i),i)},this)).end()},r.prototype.addAriaAndCollapsedClass=function(t,e){var i=t.hasClass("in");t.attr("aria-expanded",i),e.toggleClass("collapsed",!i).attr("aria-expanded",i)};var t=a.fn.collapse;a.fn.collapse=l,a.fn.collapse.Constructor=r,a.fn.collapse.noConflict=function(){return a.fn.collapse=t,this},a(document).on("click.bs.collapse.data-api",'[data-toggle="collapse"]',function(t){var e=a(this);e.attr("data-target")||t.preventDefault();var i=n(e),o=i.data("bs.collapse")?"toggle":e.data();l.call(i,o)})}(jQuery),function(a){"use strict";var r='[data-toggle="dropdown"]',o=function(t){a(t).on("click.bs.dropdown",this.toggle)};function l(t){var e=t.attr("data-target");e||(e=(e=t.attr("href"))&&/#[A-Za-z]/.test(e)&&e.replace(/.*(?=#[^\s]*$)/,""));var i="#"!==e?a(document).find(e):null;return i&&i.length?i:t.parent()}function s(o){o&&3===o.which||(a(".dropdown-backdrop").remove(),a(r).each(function(){var t=a(this),e=l(t),i={relatedTarget:this};e.hasClass("open")&&(o&&"click"==o.type&&/input|textarea/i.test(o.target.tagName)&&a.contains(e[0],o.target)||(e.trigger(o=a.Event("hide.bs.dropdown",i)),o.isDefaultPrevented()||(t.attr("aria-expanded","false"),e.removeClass("open").trigger(a.Event("hidden.bs.dropdown",i)))))}))}o.VERSION="3.4.1",o.prototype.toggle=function(t){var e=a(this);if(!e.is(".disabled, :disabled")){var i=l(e),o=i.hasClass("open");if(s(),!o){"ontouchstart"in document.documentElement&&!i.closest(".navbar-nav").length&&a(document.createElement("div")).addClass("dropdown-backdrop").insertAfter(a(this)).on("click",s);var n={relatedTarget:this};if(i.trigger(t=a.Event("show.bs.dropdown",n)),t.isDefaultPrevented())return;e.trigger("focus").attr("aria-expanded","true"),i.toggleClass("open").trigger(a.Event("shown.bs.dropdown",n))}return!1}},o.prototype.keydown=function(t){if(/(38|40|27|32)/.test(t.which)&&!/input|textarea/i.test(t.target.tagName)){var e=a(this);if(t.preventDefault(),t.stopPropagation(),!e.is(".disabled, :disabled")){var i=l(e),o=i.hasClass("open");if(!o&&27!=t.which||o&&27==t.which)return 27==t.which&&i.find(r).trigger("focus"),e.trigger("click");var n=i.find(".dropdown-menu li:not(.disabled):visible a");if(n.length){var s=n.index(t.target);38==t.which&&0<s&&s--,40==t.which&&s<n.length-1&&s++,~s||(s=0),n.eq(s).trigger("focus")}}}};var t=a.fn.dropdown;a.fn.dropdown=function e(i){return this.each(function(){var t=a(this),e=t.data("bs.dropdown");e||t.data("bs.dropdown",e=new o(this)),"string"==typeof i&&e[i].call(t)})},a.fn.dropdown.Constructor=o,a.fn.dropdown.noConflict=function(){return a.fn.dropdown=t,this},a(document).on("click.bs.dropdown.data-api",s).on("click.bs.dropdown.data-api",".dropdown form",function(t){t.stopPropagation()}).on("click.bs.dropdown.data-api",r,o.prototype.toggle).on("keydown.bs.dropdown.data-api",r,o.prototype.keydown).on("keydown.bs.dropdown.data-api",".dropdown-menu",o.prototype.keydown)}(jQuery),function(a){"use strict";var s=function(t,e){this.options=e,this.$body=a(document.body),this.$element=a(t),this.$dialog=this.$element.find(".modal-dialog"),this.$backdrop=null,this.isShown=null,this.originalBodyPad=null,this.scrollbarWidth=0,this.ignoreBackdropClick=!1,this.fixedContent=".navbar-fixed-top, .navbar-fixed-bottom",this.options.remote&&this.$element.find(".modal-content").load(this.options.remote,a.proxy(function(){this.$element.trigger("loaded.bs.modal")},this))};function r(o,n){return this.each(function(){var t=a(this),e=t.data("bs.modal"),i=a.extend({},s.DEFAULTS,t.data(),"object"==typeof o&&o);e||t.data("bs.modal",e=new s(this,i)),"string"==typeof o?e[o](n):i.show&&e.show(n)})}s.VERSION="3.4.1",s.TRANSITION_DURATION=300,s.BACKDROP_TRANSITION_DURATION=150,s.DEFAULTS={backdrop:!0,keyboard:!0,show:!0},s.prototype.toggle=function(t){return this.isShown?this.hide():this.show(t)},s.prototype.show=function(i){var o=this,t=a.Event("show.bs.modal",{relatedTarget:i});this.$element.trigger(t),this.isShown||t.isDefaultPrevented()||(this.isShown=!0,this.checkScrollbar(),this.setScrollbar(),this.$body.addClass("modal-open"),this.escape(),this.resize(),this.$element.on("click.dismiss.bs.modal",'[data-dismiss="modal"]',a.proxy(this.hide,this)),this.$dialog.on("mousedown.dismiss.bs.modal",function(){o.$element.one("mouseup.dismiss.bs.modal",function(t){a(t.target).is(o.$element)&&(o.ignoreBackdropClick=!0)})}),this.backdrop(function(){var t=a.support.transition&&o.$element.hasClass("fade");o.$element.parent().length||o.$element.appendTo(o.$body),o.$element.show().scrollTop(0),o.adjustDialog(),t&&o.$element[0].offsetWidth,o.$element.addClass("in"),o.enforceFocus();var e=a.Event("shown.bs.modal",{relatedTarget:i});t?o.$dialog.one("bsTransitionEnd",function(){o.$element.trigger("focus").trigger(e)}).emulateTransitionEnd(s.TRANSITION_DURATION):o.$element.trigger("focus").trigger(e)}))},s.prototype.hide=function(t){t&&t.preventDefault(),t=a.Event("hide.bs.modal"),this.$element.trigger(t),this.isShown&&!t.isDefaultPrevented()&&(this.isShown=!1,this.escape(),this.resize(),a(document).off("focusin.bs.modal"),this.$element.removeClass("in").off("click.dismiss.bs.modal").off("mouseup.dismiss.bs.modal"),this.$dialog.off("mousedown.dismiss.bs.modal"),a.support.transition&&this.$element.hasClass("fade")?this.$element.one("bsTransitionEnd",a.proxy(this.hideModal,this)).emulateTransitionEnd(s.TRANSITION_DURATION):this.hideModal())},s.prototype.enforceFocus=function(){a(document).off("focusin.bs.modal").on("focusin.bs.modal",a.proxy(function(t){document===t.target||this.$element[0]===t.target||this.$element.has(t.target).length||this.$element.trigger("focus")},this))},s.prototype.escape=function(){this.isShown&&this.options.keyboard?this.$element.on("keydown.dismiss.bs.modal",a.proxy(function(t){27==t.which&&this.hide()},this)):this.isShown||this.$element.off("keydown.dismiss.bs.modal")},s.prototype.resize=function(){this.isShown?a(window).on("resize.bs.modal",a.proxy(this.handleUpdate,this)):a(window).off("resize.bs.modal")},s.prototype.hideModal=function(){var t=this;this.$element.hide(),this.backdrop(function(){t.$body.removeClass("modal-open"),t.resetAdjustments(),t.resetScrollbar(),t.$element.trigger("hidden.bs.modal")})},s.prototype.removeBackdrop=function(){this.$backdrop&&this.$backdrop.remove(),this.$backdrop=null},s.prototype.backdrop=function(t){var e=this,i=this.$element.hasClass("fade")?"fade":"";if(this.isShown&&this.options.backdrop){var o=a.support.transition&&i;if(this.$backdrop=a(document.createElement("div")).addClass("modal-backdrop "+i).appendTo(this.$body),this.$element.on("click.dismiss.bs.modal",a.proxy(function(t){this.ignoreBackdropClick?this.ignoreBackdropClick=!1:t.target===t.currentTarget&&("static"==this.options.backdrop?this.$element[0].focus():this.hide())},this)),o&&this.$backdrop[0].offsetWidth,this.$backdrop.addClass("in"),!t)return;o?this.$backdrop.one("bsTransitionEnd",t).emulateTransitionEnd(s.BACKDROP_TRANSITION_DURATION):t()}else if(!this.isShown&&this.$backdrop){this.$backdrop.removeClass("in");var n=function(){e.removeBackdrop(),t&&t()};a.support.transition&&this.$element.hasClass("fade")?this.$backdrop.one("bsTransitionEnd",n).emulateTransitionEnd(s.BACKDROP_TRANSITION_DURATION):n()}else t&&t()},s.prototype.handleUpdate=function(){this.adjustDialog()},s.prototype.adjustDialog=function(){var t=this.$element[0].scrollHeight>document.documentElement.clientHeight;this.$element.css({paddingLeft:!this.bodyIsOverflowing&&t?this.scrollbarWidth:"",paddingRight:this.bodyIsOverflowing&&!t?this.scrollbarWidth:""})},s.prototype.resetAdjustments=function(){this.$element.css({paddingLeft:"",paddingRight:""})},s.prototype.checkScrollbar=function(){var t=window.innerWidth;if(!t){var e=document.documentElement.getBoundingClientRect();t=e.right-Math.abs(e.left)}this.bodyIsOverflowing=document.body.clientWidth<t,this.scrollbarWidth=this.measureScrollbar()},s.prototype.setScrollbar=function(){var t=parseInt(this.$body.css("padding-right")||0,10);this.originalBodyPad=document.body.style.paddingRight||"";var n=this.scrollbarWidth;this.bodyIsOverflowing&&(this.$body.css("padding-right",t+n),a(this.fixedContent).each(function(t,e){var i=e.style.paddingRight,o=a(e).css("padding-right");a(e).data("padding-right",i).css("padding-right",parseFloat(o)+n+"px")}))},s.prototype.resetScrollbar=function(){this.$body.css("padding-right",this.originalBodyPad),a(this.fixedContent).each(function(t,e){var i=a(e).data("padding-right");a(e).removeData("padding-right"),e.style.paddingRight=i||""})},s.prototype.measureScrollbar=function(){var t=document.createElement("div");t.className="modal-scrollbar-measure",this.$body.append(t);var e=t.offsetWidth-t.clientWidth;return this.$body[0].removeChild(t),e};var t=a.fn.modal;a.fn.modal=r,a.fn.modal.Constructor=s,a.fn.modal.noConflict=function(){return a.fn.modal=t,this},a(document).on("click.bs.modal.data-api",'[data-toggle="modal"]',function(t){var e=a(this),i=e.attr("href"),o=e.attr("data-target")||i&&i.replace(/.*(?=#[^\s]+$)/,""),n=a(document).find(o),s=n.data("bs.modal")?"toggle":a.extend({remote:!/#/.test(i)&&i},n.data(),e.data());e.is("a")&&t.preventDefault(),n.one("show.bs.modal",function(t){t.isDefaultPrevented()||n.one("hidden.bs.modal",function(){e.is(":visible")&&e.trigger("focus")})}),r.call(n,s,this)})}(jQuery),function(g){"use strict";var o=["sanitize","whiteList","sanitizeFn"],a=["background","cite","href","itemtype","longdesc","poster","src","xlink:href"],t={"*":["class","dir","id","lang","role",/^aria-[\w-]*$/i],a:["target","href","title","rel"],area:[],b:[],br:[],col:[],code:[],div:[],em:[],hr:[],h1:[],h2:[],h3:[],h4:[],h5:[],h6:[],i:[],img:["src","alt","title","width","height"],li:[],ol:[],p:[],pre:[],s:[],small:[],span:[],sub:[],sup:[],strong:[],u:[],ul:[]},r=/^(?:(?:https?|mailto|ftp|tel|file):|[^&:/?#]*(?:[/?#]|$))/gi,l=/^data:(?:image\/(?:bmp|gif|jpeg|jpg|png|tiff|webp)|video\/(?:mpeg|mp4|ogg|webm)|audio\/(?:mp3|oga|ogg|opus));base64,[a-z0-9+/]+=*$/i;function u(t,e){var i=t.nodeName.toLowerCase();if(-1!==g.inArray(i,e))return-1===g.inArray(i,a)||Boolean(t.nodeValue.match(r)||t.nodeValue.match(l));for(var o=g(e).filter(function(t,e){return e instanceof RegExp}),n=0,s=o.length;n<s;n++)if(i.match(o[n]))return!0;return!1}function n(t,e,i){if(0===t.length)return t;if(i&&"function"==typeof i)return i(t);if(!document.implementation||!document.implementation.createHTMLDocument)return t;var o=document.implementation.createHTMLDocument("sanitization");o.body.innerHTML=t;for(var n=g.map(e,function(t,e){return e}),s=g(o.body).find("*"),a=0,r=s.length;a<r;a++){var l=s[a],h=l.nodeName.toLowerCase();if(-1!==g.inArray(h,n))for(var d=g.map(l.attributes,function(t){return t}),p=[].concat(e["*"]||[],e[h]||[]),c=0,f=d.length;c<f;c++)u(d[c],p)||l.removeAttribute(d[c].nodeName);else l.parentNode.removeChild(l)}return o.body.innerHTML}var m=function(t,e){this.type=null,this.options=null,this.enabled=null,this.timeout=null,this.hoverState=null,this.$element=null,this.inState=null,this.init("tooltip",t,e)};m.VERSION="3.4.1",m.TRANSITION_DURATION=150,m.DEFAULTS={animation:!0,placement:"top",selector:!1,template:'<div class="tooltip" role="tooltip"><div class="tooltip-arrow"></div><div class="tooltip-inner"></div></div>',trigger:"hover focus",title:"",delay:0,html:!1,container:!1,viewport:{selector:"body",padding:0},sanitize:!0,sanitizeFn:null,whiteList:t},m.prototype.init=function(t,e,i){if(this.enabled=!0,this.type=t,this.$element=g(e),this.options=this.getOptions(i),this.$viewport=this.options.viewport&&g(document).find(g.isFunction(this.options.viewport)?this.options.viewport.call(this,this.$element):this.options.viewport.selector||this.options.viewport),this.inState={click:!1,hover:!1,focus:!1},this.$element[0]instanceof document.constructor&&!this.options.selector)throw new Error("`selector` option must be specified when initializing "+this.type+" on the window.document object!");for(var o=this.options.trigger.split(" "),n=o.length;n--;){var s=o[n];if("click"==s)this.$element.on("click."+this.type,this.options.selector,g.proxy(this.toggle,this));else if("manual"!=s){var a="hover"==s?"mouseenter":"focusin",r="hover"==s?"mouseleave":"focusout";this.$element.on(a+"."+this.type,this.options.selector,g.proxy(this.enter,this)),this.$element.on(r+"."+this.type,this.options.selector,g.proxy(this.leave,this))}}this.options.selector?this._options=g.extend({},this.options,{trigger:"manual",selector:""}):this.fixTitle()},m.prototype.getDefaults=function(){return m.DEFAULTS},m.prototype.getOptions=function(t){var e=this.$element.data();for(var i in e)e.hasOwnProperty(i)&&-1!==g.inArray(i,o)&&delete e[i];return(t=g.extend({},this.getDefaults(),e,t)).delay&&"number"==typeof t.delay&&(t.delay={show:t.delay,hide:t.delay}),t.sanitize&&(t.template=n(t.template,t.whiteList,t.sanitizeFn)),t},m.prototype.getDelegateOptions=function(){var i={},o=this.getDefaults();return this._options&&g.each(this._options,function(t,e){o[t]!=e&&(i[t]=e)}),i},m.prototype.enter=function(t){var e=t instanceof this.constructor?t:g(t.currentTarget).data("bs."+this.type);if(e||(e=new this.constructor(t.currentTarget,this.getDelegateOptions()),g(t.currentTarget).data("bs."+this.type,e)),t instanceof g.Event&&(e.inState["focusin"==t.type?"focus":"hover"]=!0),e.tip().hasClass("in")||"in"==e.hoverState)e.hoverState="in";else{if(clearTimeout(e.timeout),e.hoverState="in",!e.options.delay||!e.options.delay.show)return e.show();e.timeout=setTimeout(function(){"in"==e.hoverState&&e.show()},e.options.delay.show)}},m.prototype.isInStateTrue=function(){for(var t in this.inState)if(this.inState[t])return!0;return!1},m.prototype.leave=function(t){var e=t instanceof this.constructor?t:g(t.currentTarget).data("bs."+this.type);if(e||(e=new this.constructor(t.currentTarget,this.getDelegateOptions()),g(t.currentTarget).data("bs."+this.type,e)),t instanceof g.Event&&(e.inState["focusout"==t.type?"focus":"hover"]=!1),!e.isInStateTrue()){if(clearTimeout(e.timeout),e.hoverState="out",!e.options.delay||!e.options.delay.hide)return e.hide();e.timeout=setTimeout(function(){"out"==e.hoverState&&e.hide()},e.options.delay.hide)}},m.prototype.show=function(){var t=g.Event("show.bs."+this.type);if(this.hasContent()&&this.enabled){this.$element.trigger(t);var e=g.contains(this.$element[0].ownerDocument.documentElement,this.$element[0]);if(t.isDefaultPrevented()||!e)return;var i=this,o=this.tip(),n=this.getUID(this.type);this.setContent(),o.attr("id",n),this.$element.attr("aria-describedby",n),this.options.animation&&o.addClass("fade");var s="function"==typeof this.options.placement?this.options.placement.call(this,o[0],this.$element[0]):this.options.placement,a=/\s?auto?\s?/i,r=a.test(s);r&&(s=s.replace(a,"")||"top"),o.detach().css({top:0,left:0,display:"block"}).addClass(s).data("bs."+this.type,this),this.options.container?o.appendTo(g(document).find(this.options.container)):o.insertAfter(this.$element),this.$element.trigger("inserted.bs."+this.type);var l=this.getPosition(),h=o[0].offsetWidth,d=o[0].offsetHeight;if(r){var p=s,c=this.getPosition(this.$viewport);s="bottom"==s&&l.bottom+d>c.bottom?"top":"top"==s&&l.top-d<c.top?"bottom":"right"==s&&l.right+h>c.width?"left":"left"==s&&l.left-h<c.left?"right":s,o.removeClass(p).addClass(s)}var f=this.getCalculatedOffset(s,l,h,d);this.applyPlacement(f,s);var u=function(){var t=i.hoverState;i.$element.trigger("shown.bs."+i.type),i.hoverState=null,"out"==t&&i.leave(i)};g.support.transition&&this.$tip.hasClass("fade")?o.one("bsTransitionEnd",u).emulateTransitionEnd(m.TRANSITION_DURATION):u()}},m.prototype.applyPlacement=function(t,e){var i=this.tip(),o=i[0].offsetWidth,n=i[0].offsetHeight,s=parseInt(i.css("margin-top"),10),a=parseInt(i.css("margin-left"),10);isNaN(s)&&(s=0),isNaN(a)&&(a=0),t.top+=s,t.left+=a,g.offset.setOffset(i[0],g.extend({using:function(t){i.css({top:Math.round(t.top),left:Math.round(t.left)})}},t),0),i.addClass("in");var r=i[0].offsetWidth,l=i[0].offsetHeight;"top"==e&&l!=n&&(t.top=t.top+n-l);var h=this.getViewportAdjustedDelta(e,t,r,l);h.left?t.left+=h.left:t.top+=h.top;var d=/top|bottom/.test(e),p=d?2*h.left-o+r:2*h.top-n+l,c=d?"offsetWidth":"offsetHeight";i.offset(t),this.replaceArrow(p,i[0][c],d)},m.prototype.replaceArrow=function(t,e,i){this.arrow().css(i?"left":"top",50*(1-t/e)+"%").css(i?"top":"left","")},m.prototype.setContent=function(){var t=this.tip(),e=this.getTitle();this.options.html?(this.options.sanitize&&(e=n(e,this.options.whiteList,this.options.sanitizeFn)),t.find(".tooltip-inner").html(e)):t.find(".tooltip-inner").text(e),t.removeClass("fade in top bottom left right")},m.prototype.hide=function(t){var e=this,i=g(this.$tip),o=g.Event("hide.bs."+this.type);function n(){"in"!=e.hoverState&&i.detach(),e.$element&&e.$element.removeAttr("aria-describedby").trigger("hidden.bs."+e.type),t&&t()}if(this.$element.trigger(o),!o.isDefaultPrevented())return i.removeClass("in"),g.support.transition&&i.hasClass("fade")?i.one("bsTransitionEnd",n).emulateTransitionEnd(m.TRANSITION_DURATION):n(),this.hoverState=null,this},m.prototype.fixTitle=function(){var t=this.$element;(t.attr("title")||"string"!=typeof t.attr("data-original-title"))&&t.attr("data-original-title",t.attr("title")||"").attr("title","")},m.prototype.hasContent=function(){return this.getTitle()},m.prototype.getPosition=function(t){var e=(t=t||this.$element)[0],i="BODY"==e.tagName,o=e.getBoundingClientRect();null==o.width&&(o=g.extend({},o,{width:o.right-o.left,height:o.bottom-o.top}));var n=window.SVGElement&&e instanceof window.SVGElement,s=i?{top:0,left:0}:n?null:t.offset(),a={scroll:i?document.documentElement.scrollTop||document.body.scrollTop:t.scrollTop()},r=i?{width:g(window).width(),height:g(window).height()}:null;return g.extend({},o,a,r,s)},m.prototype.getCalculatedOffset=function(t,e,i,o){return"bottom"==t?{top:e.top+e.height,left:e.left+e.width/2-i/2}:"top"==t?{top:e.top-o,left:e.left+e.width/2-i/2}:"left"==t?{top:e.top+e.height/2-o/2,left:e.left-i}:{top:e.top+e.height/2-o/2,left:e.left+e.width}},m.prototype.getViewportAdjustedDelta=function(t,e,i,o){var n={top:0,left:0};if(!this.$viewport)return n;var s=this.options.viewport&&this.options.viewport.padding||0,a=this.getPosition(this.$viewport);if(/right|left/.test(t)){var r=e.top-s-a.scroll,l=e.top+s-a.scroll+o;r<a.top?n.top=a.top-r:l>a.top+a.height&&(n.top=a.top+a.height-l)}else{var h=e.left-s,d=e.left+s+i;h<a.left?n.left=a.left-h:d>a.right&&(n.left=a.left+a.width-d)}return n},m.prototype.getTitle=function(){var t=this.$element,e=this.options;return t.attr("data-original-title")||("function"==typeof e.title?e.title.call(t[0]):e.title)},m.prototype.getUID=function(t){for(;t+=~~(1e6*Math.random()),document.getElementById(t););return t},m.prototype.tip=function(){if(!this.$tip&&(this.$tip=g(this.options.template),1!=this.$tip.length))throw new Error(this.type+" `template` option must consist of exactly 1 top-level element!");return this.$tip},m.prototype.arrow=function(){return this.$arrow=this.$arrow||this.tip().find(".tooltip-arrow")},m.prototype.enable=function(){this.enabled=!0},m.prototype.disable=function(){this.enabled=!1},m.prototype.toggleEnabled=function(){this.enabled=!this.enabled},m.prototype.toggle=function(t){var e=this;t&&((e=g(t.currentTarget).data("bs."+this.type))||(e=new this.constructor(t.currentTarget,this.getDelegateOptions()),g(t.currentTarget).data("bs."+this.type,e))),t?(e.inState.click=!e.inState.click,e.isInStateTrue()?e.enter(e):e.leave(e)):e.tip().hasClass("in")?e.leave(e):e.enter(e)},m.prototype.destroy=function(){var t=this;clearTimeout(this.timeout),this.hide(function(){t.$element.off("."+t.type).removeData("bs."+t.type),t.$tip&&t.$tip.detach(),t.$tip=null,t.$arrow=null,t.$viewport=null,t.$element=null})},m.prototype.sanitizeHtml=function(t){return n(t,this.options.whiteList,this.options.sanitizeFn)};var e=g.fn.tooltip;g.fn.tooltip=function i(o){return this.each(function(){var t=g(this),e=t.data("bs.tooltip"),i="object"==typeof o&&o;!e&&/destroy|hide/.test(o)||(e||t.data("bs.tooltip",e=new m(this,i)),"string"==typeof o&&e[o]())})},g.fn.tooltip.Constructor=m,g.fn.tooltip.noConflict=function(){return g.fn.tooltip=e,this}}(jQuery),function(n){"use strict";var s=function(t,e){this.init("popover",t,e)};if(!n.fn.tooltip)throw new Error("Popover requires tooltip.js");s.VERSION="3.4.1",s.DEFAULTS=n.extend({},n.fn.tooltip.Constructor.DEFAULTS,{placement:"right",trigger:"click",content:"",template:'<div class="popover" role="tooltip"><div class="arrow"></div><h3 class="popover-title"></h3><div class="popover-content"></div></div>'}),((s.prototype=n.extend({},n.fn.tooltip.Constructor.prototype)).constructor=s).prototype.getDefaults=function(){return s.DEFAULTS},s.prototype.setContent=function(){var t=this.tip(),e=this.getTitle(),i=this.getContent();if(this.options.html){var o=typeof i;this.options.sanitize&&(e=this.sanitizeHtml(e),"string"===o&&(i=this.sanitizeHtml(i))),t.find(".popover-title").html(e),t.find(".popover-content").children().detach().end()["string"===o?"html":"append"](i)}else t.find(".popover-title").text(e),t.find(".popover-content").children().detach().end().text(i);t.removeClass("fade top bottom left right in"),t.find(".popover-title").html()||t.find(".popover-title").hide()},s.prototype.hasContent=function(){return this.getTitle()||this.getContent()},s.prototype.getContent=function(){var t=this.$element,e=this.options;return t.attr("data-content")||("function"==typeof e.content?e.content.call(t[0]):e.content)},s.prototype.arrow=function(){return this.$arrow=this.$arrow||this.tip().find(".arrow")};var t=n.fn.popover;n.fn.popover=function e(o){return this.each(function(){var t=n(this),e=t.data("bs.popover"),i="object"==typeof o&&o;!e&&/destroy|hide/.test(o)||(e||t.data("bs.popover",e=new s(this,i)),"string"==typeof o&&e[o]())})},n.fn.popover.Constructor=s,n.fn.popover.noConflict=function(){return n.fn.popover=t,this}}(jQuery),function(s){"use strict";function n(t,e){this.$body=s(document.body),this.$scrollElement=s(t).is(document.body)?s(window):s(t),this.options=s.extend({},n.DEFAULTS,e),this.selector=(this.options.target||"")+" .nav li > a",this.offsets=[],this.targets=[],this.activeTarget=null,this.scrollHeight=0,this.$scrollElement.on("scroll.bs.scrollspy",s.proxy(this.process,this)),this.refresh(),this.process()}function e(o){return this.each(function(){var t=s(this),e=t.data("bs.scrollspy"),i="object"==typeof o&&o;e||t.data("bs.scrollspy",e=new n(this,i)),"string"==typeof o&&e[o]()})}n.VERSION="3.4.1",n.DEFAULTS={offset:10},n.prototype.getScrollHeight=function(){return this.$scrollElement[0].scrollHeight||Math.max(this.$body[0].scrollHeight,document.documentElement.scrollHeight)},n.prototype.refresh=function(){var t=this,o="offset",n=0;this.offsets=[],this.targets=[],this.scrollHeight=this.getScrollHeight(),s.isWindow(this.$scrollElement[0])||(o="position",n=this.$scrollElement.scrollTop()),this.$body.find(this.selector).map(function(){var t=s(this),e=t.data("target")||t.attr("href"),i=/^#./.test(e)&&s(e);return i&&i.length&&i.is(":visible")&&[[i[o]().top+n,e]]||null}).sort(function(t,e){return t[0]-e[0]}).each(function(){t.offsets.push(this[0]),t.targets.push(this[1])})},n.prototype.process=function(){var t,e=this.$scrollElement.scrollTop()+this.options.offset,i=this.getScrollHeight(),o=this.options.offset+i-this.$scrollElement.height(),n=this.offsets,s=this.targets,a=this.activeTarget;if(this.scrollHeight!=i&&this.refresh(),o<=e)return a!=(t=s[s.length-1])&&this.activate(t);if(a&&e<n[0])return this.activeTarget=null,this.clear();for(t=n.length;t--;)a!=s[t]&&e>=n[t]&&(n[t+1]===undefined||e<n[t+1])&&this.activate(s[t])},n.prototype.activate=function(t){this.activeTarget=t,this.clear();var e=this.selector+'[data-target="'+t+'"],'+this.selector+'[href="'+t+'"]',i=s(e).parents("li").addClass("active");i.parent(".dropdown-menu").length&&(i=i.closest("li.dropdown").addClass("active")),i.trigger("activate.bs.scrollspy")},n.prototype.clear=function(){s(this.selector).parentsUntil(this.options.target,".active").removeClass("active")};var t=s.fn.scrollspy;s.fn.scrollspy=e,s.fn.scrollspy.Constructor=n,s.fn.scrollspy.noConflict=function(){return s.fn.scrollspy=t,this},s(window).on("load.bs.scrollspy.data-api",function(){s('[data-spy="scroll"]').each(function(){var t=s(this);e.call(t,t.data())})})}(jQuery),function(r){"use strict";var a=function(t){this.element=r(t)};function e(i){return this.each(function(){var t=r(this),e=t.data("bs.tab");e||t.data("bs.tab",e=new a(this)),"string"==typeof i&&e[i]()})}a.VERSION="3.4.1",a.TRANSITION_DURATION=150,a.prototype.show=function(){var t=this.element,e=t.closest("ul:not(.dropdown-menu)"),i=t.data("target");if(i||(i=(i=t.attr("href"))&&i.replace(/.*(?=#[^\s]*$)/,"")),!t.parent("li").hasClass("active")){var o=e.find(".active:last a"),n=r.Event("hide.bs.tab",{relatedTarget:t[0]}),s=r.Event("show.bs.tab",{relatedTarget:o[0]});if(o.trigger(n),t.trigger(s),!s.isDefaultPrevented()&&!n.isDefaultPrevented()){var a=r(document).find(i);this.activate(t.closest("li"),e),this.activate(a,a.parent(),function(){o.trigger({type:"hidden.bs.tab",relatedTarget:t[0]}),t.trigger({type:"shown.bs.tab",relatedTarget:o[0]})})}}},a.prototype.activate=function(t,e,i){var o=e.find("> .active"),n=i&&r.support.transition&&(o.length&&o.hasClass("fade")||!!e.find("> .fade").length);function s(){o.removeClass("active").find("> .dropdown-menu > .active").removeClass("active").end().find('[data-toggle="tab"]').attr("aria-expanded",!1),t.addClass("active").find('[data-toggle="tab"]').attr("aria-expanded",!0),n?(t[0].offsetWidth,t.addClass("in")):t.removeClass("fade"),t.parent(".dropdown-menu").length&&t.closest("li.dropdown").addClass("active").end().find('[data-toggle="tab"]').attr("aria-expanded",!0),i&&i()}o.length&&n?o.one("bsTransitionEnd",s).emulateTransitionEnd(a.TRANSITION_DURATION):s(),o.removeClass("in")};var t=r.fn.tab;r.fn.tab=e,r.fn.tab.Constructor=a,r.fn.tab.noConflict=function(){return r.fn.tab=t,this};var i=function(t){t.preventDefault(),e.call(r(this),"show")};r(document).on("click.bs.tab.data-api",'[data-toggle="tab"]',i).on("click.bs.tab.data-api",'[data-toggle="pill"]',i)}(jQuery),function(l){"use strict";var h=function(t,e){this.options=l.extend({},h.DEFAULTS,e);var i=this.options.target===h.DEFAULTS.target?l(this.options.target):l(document).find(this.options.target);this.$target=i.on("scroll.bs.affix.data-api",l.proxy(this.checkPosition,this)).on("click.bs.affix.data-api",l.proxy(this.checkPositionWithEventLoop,this)),this.$element=l(t),this.affixed=null,this.unpin=null,this.pinnedOffset=null,this.checkPosition()};function i(o){return this.each(function(){var t=l(this),e=t.data("bs.affix"),i="object"==typeof o&&o;e||t.data("bs.affix",e=new h(this,i)),"string"==typeof o&&e[o]()})}h.VERSION="3.4.1",h.RESET="affix affix-top affix-bottom",h.DEFAULTS={offset:0,target:window},h.prototype.getState=function(t,e,i,o){var n=this.$target.scrollTop(),s=this.$element.offset(),a=this.$target.height();if(null!=i&&"top"==this.affixed)return n<i&&"top";if("bottom"==this.affixed)return null!=i?!(n+this.unpin<=s.top)&&"bottom":!(n+a<=t-o)&&"bottom";var r=null==this.affixed,l=r?n:s.top;return null!=i&&n<=i?"top":null!=o&&t-o<=l+(r?a:e)&&"bottom"},h.prototype.getPinnedOffset=function(){if(this.pinnedOffset)return this.pinnedOffset;this.$element.removeClass(h.RESET).addClass("affix");var t=this.$target.scrollTop(),e=this.$element.offset();return this.pinnedOffset=e.top-t},h.prototype.checkPositionWithEventLoop=function(){setTimeout(l.proxy(this.checkPosition,this),1)},h.prototype.checkPosition=function(){if(this.$element.is(":visible")){var t=this.$element.height(),e=this.options.offset,i=e.top,o=e.bottom,n=Math.max(l(document).height(),l(document.body).height());"object"!=typeof e&&(o=i=e),"function"==typeof i&&(i=e.top(this.$element)),"function"==typeof o&&(o=e.bottom(this.$element));var s=this.getState(n,t,i,o);if(this.affixed!=s){null!=this.unpin&&this.$element.css("top","");var a="affix"+(s?"-"+s:""),r=l.Event(a+".bs.affix");if(this.$element.trigger(r),r.isDefaultPrevented())return;this.affixed=s,this.unpin="bottom"==s?this.getPinnedOffset():null,this.$element.removeClass(h.RESET).addClass(a).trigger(a.replace("affix","affixed")+".bs.affix")}"bottom"==s&&this.$element.offset({top:n-t-o})}};var t=l.fn.affix;l.fn.affix=i,l.fn.affix.Constructor=h,l.fn.affix.noConflict=function(){return l.fn.affix=t,this},l(window).on("load",function(){l('[data-spy="affix"]').each(function(){var t=l(this),e=t.data();e.offset=e.offset||{},null!=e.offsetBottom&&(e.offset.bottom=e.offsetBottom),null!=e.offsetTop&&(e.offset.top=e.offsetTop),i.call(t,e)})})}(jQuery);
76; 77/* AUTOGENERATED: hash.js */ 78(function(a,b){"use strict";var c=function(){var b=function(){var b=a.location.hash?a.location.hash.substr(1).split("&"):[],c={};for(var d=0;d<b.length;d++){var e=b[d].split("=");c[e[0]]=decodeURIComponent(e[1])}return c};var c=function(b){var c=[];for(var d in b){c.push(d+"="+encodeURIComponent(b[d]))}a.location.hash=c.join("&")};return{get:function(a){var c=b();if(a){return c[a]}else{return c}},add:function(a){var d=b();for(var e in a){d[e]=a[e]}c(d)},remove:function(a){a=typeof a=="string"?[a]:a;var d=b();for(var e=0;e<a.length;e++){delete d[a[e]]}c(d)},clear:function(){c({})}}}();a.hash=c})(window);; 79/* AUTOGENERATED: object_hash.js */ 80!function(e){if("object"==typeof exports)module.exports=e();else if("function"==typeof define&&define.amd)define(e);else{var t;"undefined"!=typeof window?t=window:"undefined"!=typeof global?t=global:"undefined"!=typeof self&&(t=self),t.objectHash=e()}}(function(){return function e(t,r,n){function o(u,a){if(!r[u]){if(!t[u]){var s="function"==typeof require&&require;if(!a&&s)return s(u,!0);if(i)return i(u,!0);throw new Error("Cannot find module '"+u+"'")}var f=r[u]={exports:{}};t[u][0].call(f.exports,function(e){var r=t[u][1][e];return o(r?r:e)},f,f.exports,e,t,r,n)}return r[u].exports}for(var i="function"==typeof require&&require,u=0;u<n.length;u++)o(n[u]);return o}({1:[function(e,t,r){(function(n,o,i,u,a,s,f,c,l){"use strict";function d(e,t){return t=h(e,t),g(e,t)}function h(e,t){var r=m.getHashes?m.getHashes():["sha1","md5"],n=["buffer","hex","binary","base64"];if(t=t||{},t.algorithm=t.algorithm||"sha1",t.encoding=t.encoding||"hex",t.excludeValues=t.excludeValues?!0:!1,t.algorithm=t.algorithm.toLowerCase(),t.encoding=t.encoding.toLowerCase(),t.ignoreUnknown=t.ignoreUnknown!==!0?!1:!0,t.respectType=t.respectType===!1?!1:!0,t.respectFunctionNames=t.respectFunctionNames===!1?!1:!0,t.respectFunctionProperties=t.respectFunctionProperties===!1?!1:!0,t.unorderedArrays=t.unorderedArrays!==!0?!1:!0,t.unorderedSets=t.unorderedSets===!1?!1:!0,t.replacer=t.replacer||void 0,"undefined"==typeof e)throw new Error("Object argument required.");r.push("passthrough");for(var o=0;o<r.length;++o)r[o].toLowerCase()===t.algorithm.toLowerCase()&&(t.algorithm=r[o]);if(-1===r.indexOf(t.algorithm))throw new Error('Algorithm "'+t.algorithm+'" not supported. supported values: '+r.join(", "));if(-1===n.indexOf(t.encoding)&&"passthrough"!==t.algorithm)throw new Error('Encoding "'+t.encoding+'" not supported. supported values: '+n.join(", "));return t}function p(e){if("function"!=typeof e)return!1;var t=/^function\s+\w*\s*\(\s*\)\s*{\s+\[native code\]\s+}$/i;return null!=t.exec(Function.prototype.toString.call(e))}function g(e,t){var r;r="passthrough"!==t.algorithm?m.createHash(t.algorithm):new y,"undefined"==typeof r.write&&(r.write=r.update,r.end=r.update);var n=w(t,r);if(n.dispatch(e),r.end(""),"undefined"==typeof r.read&&"function"==typeof r.digest)return r.digest("buffer"===t.encoding?void 0:t.encoding);var o=r.read();return"buffer"===t.encoding?o:o.toString(t.encoding)}function w(e,t,r){return r=r||[],{dispatch:function(t){e.replacer&&(t=e.replacer(t));var r=typeof t;return null===t&&(r="null"),this["_"+r](t)},_object:function(n){var o=/\[object (.*)\]/i,u=Object.prototype.toString.call(n),a=o.exec(u);a=a?a[1]:"unknown:["+u+"]",a=a.toLowerCase();var s=null;if((s=r.indexOf(n))>=0)return this.dispatch("[CIRCULAR:"+s+"]");if(r.push(n),"undefined"!=typeof i&&i.isBuffer&&i.isBuffer(n))return t.write("buffer:"),t.write(n);if("object"===a||"function"===a){var f=Object.keys(n).sort();e.respectType===!1||p(n)||f.splice(0,0,"prototype","__proto__","constructor"),t.write("object:"+f.length+":");var c=this;return f.forEach(function(r){c.dispatch(r),t.write(":"),e.excludeValues||c.dispatch(n[r]),t.write(",")})}if(!this["_"+a]){if(e.ignoreUnknown)return t.write("["+a+"]");throw new Error('Unknown object type "'+a+'"')}this["_"+a](n)},_array:function(n,o){o="undefined"!=typeof o?o:e.unorderedArrays!==!1;var i=this;if(t.write("array:"+n.length+":"),!o||n.length<=1)return n.forEach(function(e){return i.dispatch(e)});var u=[],a=n.map(function(t){var n=new y,o=r.slice(),i=w(e,n,o);return i.dispatch(t),u=u.concat(o.slice(r.length)),n.read().toString()});return r=r.concat(u),a.sort(),this._array(a,!1)},_date:function(e){return t.write("date:"+e.toJSON())},_symbol:function(e){return t.write("symbol:"+e.toString(),"utf8")},_error:function(e){return t.write("error:"+e.toString(),"utf8")},_boolean:function(e){return t.write("bool:"+e.toString())}
80,_string:function(e){t.write("string:"+e.length+":"),t.write(e,"utf8")},_function:function(r){t.write("fn:"),p(r)?this.dispatch("[native]"):this.dispatch(r.toString()),e.respectFunctionNames!==!1&&this.dispatch("function-name:"+String(r.name)),e.respectFunctionProperties&&this._object(r)},_number:function(e){return t.write("number:"+e.toString())},_xml:function(e){return t.write("xml:"+e.toString(),"utf8")},_null:function(){return t.write("Null")},_undefined:function(){return t.write("Undefined")},_regexp:function(e){return t.write("regex:"+e.toString(),"utf8")},_uint8array:function(e){return t.write("uint8array:"),this.dispatch(Array.prototype.slice.call(e))},_uint8clampedarray:function(e){return t.write("uint8clampedarray:"),this.dispatch(Array.prototype.slice.call(e))},_int8array:function(e){return t.write("uint8array:"),this.dispatch(Array.prototype.slice.call(e))},_uint16array:function(e){return t.write("uint16array:"),this.dispatch(Array.prototype.slice.call(e))},_int16array:function(e){return t.write("uint16array:"),this.dispatch(Array.prototype.slice.call(e))},_uint32array:function(e){return t.write("uint32array:"),this.dispatch(Array.prototype.slice.call(e))},_int32array:function(e){return t.write("uint32array:"),this.dispatch(Array.prototype.slice.call(e))},_float32array:function(e){return t.write("float32array:"),this.dispatch(Array.prototype.slice.call(e))},_float64array:function(e){return t.write("float64array:"),this.dispatch(Array.prototype.slice.call(e))},_arraybuffer:function(e){return t.write("arraybuffer:"),this.dispatch(new Uint8Array(e))},_url:function(e){return t.write("url:"+e.toString(),"utf8")},_map:function(r){t.write("map:");var n=Array.from(r);return this._array(n,e.unorderedSets!==!1)},_set:function(r){t.write("set:");var n=Array.from(r);return this._array(n,e.unorderedSets!==!1)},_blob:function(){if(e.ignoreUnknown)return t.write("[blob]");throw Error('Hashing Blob objects is currently not supported\n(see https://github.com/puleos/object-hash/issues/26)\nUse "options.replacer" or "options.ignoreUnknown"\n')},_domwindow:function(){return t.write("domwindow")},_process:function(){return t.write("process")},_timer:function(){return t.write("timer")},_pipe:function(){return t.write("pipe")},_tcp:function(){return t.write("tcp")},_udp:function(){return t.write("udp")},_tty:function(){return t.write("tty")},_statwatcher:function(){return t.write("statwatcher")},_securecontext:function(){return t.write("securecontext")},_connection:function(){return t.write("connection")},_zlib:function(){return t.write("zlib")},_context:function(){return t.write("context")},_nodescript:function(){return t.write("nodescript")},_httpparser:function(){return t.write("httpparser")},_dataview:function(){return t.write("dataview")},_signal:function(){return t.write("signal")},_fsevent:function(){return t.write("fsevent")},_tlswrap:function(){return t.write("tlswrap")}}}function y(){return{buf:"",write:function(e){this.buf+=e},end:function(e){this.buf+=e},read:function(){return this.buf}}}var m=e("crypto");r=t.exports=d,r.sha1=function(e){return d(e)},r.keys=function(e){return d(e,{excludeValues:!0,algorithm:"sha1",encoding:"hex"})},r.MD5=function(e){return d(e,{algorithm:"md5",encoding:"hex"})},r.keysMD5=function(e){return d(e,{algorithm:"md5",encoding:"hex",excludeValues:!0})},r.writeToStream=function(e,t,r){return"undefined"==typeof r&&(r=t,t={}),t=h(e,t),w(t,r).dispatch(e)}}).call(this,e("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/fake_50da2638.js","/")},{buffer:3,crypto:5,lYpoI2:10}],2:[function(e,t,r){(function(e,t,n,o,i,u,a,s,f){var c="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/";!function(e){"use strict";function t(e){var t=e.charCodeAt(0);return t===i||t===l?62:t===u||t===d?63:a>t?-1:a+10>t?t-a+26+26:f+26>t?t-f:s+26>t?t-s+26:void 0}function r(e){function r(e){f[l++]=e}var n,i,u,a,s,f;if(e.length%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var c=e.length;s="="===e.charAt(c-2)?2:"="===e.charAt(c-1)?1:0,f=new o(3*e.length/4-s),u=s>0?e.length-4:e.length;var l=0;for(n=0,i=0;u>n;n+=4,i+=3)a=t(e.charAt(n))<<18|t(e.charAt(n+1))<<12|t(e.charAt(n+2))<<6|t(e.charAt(n+3)),r((16711680&a)>>16),r((65280&a)>>8),r(255&a);return 2===s?(a=t(e.charAt(n))<<2|t(e.charAt(n+1))>>4,r(255&a)):1===s&&(a=t(e.charAt(n))<<10|t(e.charAt(n+1))<<4|t(e.charAt(n+2))>>2,r(a>>8&255),r(255&a)),f}function n(e){function t(e){return c.charAt(e)}function r(e){return t(e>>18&63)+t(e>>12&63)+t(e>>6&63)+t(63&e)}var n,o,i,u=e.length%3,a="";for(n=0,i=e.length-u;i>n;n+=3)o=(e[n]<<16)+(e[n+1]<<8)+e[n+2],a+=r(o);switch(u){case 1:o=e[e.length-1],a+=t(o>>2),a+=t(o<<4&63),a+="==";break;case 2:o=(e[e.length-2]<<8)+e[e.length-1],a+=t(o>>10),a+=t(o>>4&63),a+=t(o<<2&63),a+="="}return a}var o="undefined"!=typeof Uint8Array?Uint8Array:Array,i="+".charCodeAt(0),u="/".charCodeAt(0),a="0".charCodeAt(0),s="a".charCodeAt(0),f="A".charCodeAt(0),l="-".charCodeAt(0),d="_".charCodeAt(0);e.toByteArray=r,e.fromByteArray=n}("undefined"==typeof r?this.base64js={}:r)}).call(this,e("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/base64-js/lib/b64.js","/node_modules/gulp-browserify/node_modules/base64-js/lib")},{buffer:3,lYpoI2:10}],3:[function(e,t,r){(function(t,n,o,i,u,a,s,f,c){function o(e,t,r){if(!(this instanceof o))return new o(e,t,r);var n=typeof e;if("base64"===t&&"string"===n)for(e=N(e);e.length%4!==0;)e+="=";var i;if("number"===n)i=F(e);else if("string"===n)i=o.byteLength(e,t);else{if("object"!==n)throw new Error("First argument needs to be a number, array or string.");i=F(e.length)}var u;
80o._useTypedArrays?u=o._augment(new Uint8Array(i)):(u=this,u.length=i,u._isBuffer=!0);var a;if(o._useTypedArrays&&"number"==typeof e.byteLength)u._set(e);else if(O(e))for(a=0;i>a;a++)o.isBuffer(e)?u[a]=e.readUInt8(a):u[a]=e[a];else if("string"===n)u.write(e,0,t);else if("number"===n&&!o._useTypedArrays&&!r)for(a=0;i>a;a++)u[a]=0;return u}function l(e,t,r,n){r=Number(r)||0;var i=e.length-r;n?(n=Number(n),n>i&&(n=i)):n=i;var u=t.length;G(u%2===0,"Invalid hex string"),n>u/2&&(n=u/2);for(var a=0;n>a;a++){var s=parseInt(t.substr(2*a,2),16);G(!isNaN(s),"Invalid hex string"),e[r+a]=s}return o._charsWritten=2*a,a}function d(e,t,r,n){var i=o._charsWritten=W(V(t),e,r,n);return i}function h(e,t,r,n){var i=o._charsWritten=W(q(t),e,r,n);return i}function p(e,t,r,n){return h(e,t,r,n)}function g(e,t,r,n){var i=o._charsWritten=W(R(t),e,r,n);return i}function w(e,t,r,n){var i=o._charsWritten=W(P(t),e,r,n);return i}function y(e,t,r){return 0===t&&r===e.length?K.fromByteArray(e):K.fromByteArray(e.slice(t,r))}function m(e,t,r){var n="",o="";r=Math.min(e.length,r);for(var i=t;r>i;i++)e[i]<=127?(n+=J(o)+String.fromCharCode(e[i]),o=""):o+="%"+e[i].toString(16);return n+J(o)}function b(e,t,r){var n="";r=Math.min(e.length,r);for(var o=t;r>o;o++)n+=String.fromCharCode(e[o]);return n}function v(e,t,r){return b(e,t,r)}function _(e,t,r){var n=e.length;(!t||0>t)&&(t=0),(!r||0>r||r>n)&&(r=n);for(var o="",i=t;r>i;i++)o+=H(e[i]);return o}function E(e,t,r){for(var n=e.slice(t,r),o="",i=0;i<n.length;i+=2)o+=String.fromCharCode(n[i]+256*n[i+1]);return o}function I(e,t,r,n){n||(G("boolean"==typeof r,"missing or invalid endian"),G(void 0!==t&&null!==t,"missing offset"),G(t+1<e.length,"Trying to read beyond buffer length"));var o=e.length;if(!(t>=o)){var i;return r?(i=e[t],o>t+1&&(i|=e[t+1]<<8)):(i=e[t]<<8,o>t+1&&(i|=e[t+1])),i}}function A(e,t,r,n){n||(G("boolean"==typeof r,"missing or invalid endian"),G(void 0!==t&&null!==t,"missing offset"),G(t+3<e.length,"Trying to read beyond buffer length"));var o=e.length;if(!(t>=o)){var i;return r?(o>t+2&&(i=e[t+2]<<16),o>t+1&&(i|=e[t+1]<<8),i|=e[t],o>t+3&&(i+=e[t+3]<<24>>>0)):(o>t+1&&(i=e[t+1]<<16),o>t+2&&(i|=e[t+2]<<8),o>t+3&&(i|=e[t+3]),i+=e[t]<<24>>>0),i}}function B(e,t,r,n){n||(G("boolean"==typeof r,"missing or invalid endian"),G(void 0!==t&&null!==t,"missing offset"),G(t+1<e.length,"Trying to read beyond buffer length"));var o=e.length;if(!(t>=o)){var i=I(e,t,r,!0),u=32768&i;return u?-1*(65535-i+1):i}}function L(e,t,r,n){n||(G("boolean"==typeof r,"missing or invalid endian"),G(void 0!==t&&null!==t,"missing offset"),G(t+3<e.length,"Trying to read beyond buffer length"));var o=e.length;if(!(t>=o)){var i=A(e,t,r,!0),u=2147483648&i;return u?-1*(4294967295-i+1):i}}function U(e,t,r,n){return n||(G("boolean"==typeof r,"missing or invalid endian"),G(t+3<e.length,"Trying to read beyond buffer length")),Q.read(e,t,r,23,4)}function x(e,t,r,n){return n||(G("boolean"==typeof r,"missing or invalid endian"),G(t+7<e.length,"Trying to read beyond buffer length")),Q.read(e,t,r,52,8)}function S(e,t,r,n,o){o||(G(void 0!==t&&null!==t,"missing value"),G("boolean"==typeof n,"missing or invalid endian"),G(void 0!==r&&null!==r,"missing offset"),G(r+1<e.length,"trying to write beyond buffer length"),z(t,65535));var i=e.length;if(!(r>=i))for(var u=0,a=Math.min(i-r,2);a>u;u++)e[r+u]=(t&255<<8*(n?u:1-u))>>>8*(n?u:1-u)}function C(e,t,r,n,o){o||(G(void 0!==t&&null!==t,"missing value"),G("boolean"==typeof n,"missing or invalid endian"),G(void 0!==r&&null!==r,"missing offset"),G(r+3<e.length,"trying to write beyond buffer length"),z(t,4294967295));var i=e.length;if(!(r>=i))for(var u=0,a=Math.min(i-r,4);a>u;u++)e[r+u]=t>>>8*(n?u:3-u)&255}function j(e,t,r,n,o){o||(G(void 0!==t&&null!==t,"missing value"),G("boolean"==typeof n,"missing or invalid endian"),G(void 0!==r&&null!==r,"missing offset"),G(r+1<e.length,"Trying to write beyond buffer length"),X(t,32767,-32768));var i=e.length;r>=i||(t>=0?S(e,t,r,n,o):S(e,65535+t+1,r,n,o))}function k(e,t,r,n,o){o||(G(void 0!==t&&null!==t,"missing value"),G("boolean"==typeof n,"missing or invalid endian"),G(void 0!==r&&null!==r,"missing offset"),G(r+3<e.length,"Trying to write beyond buffer length"),X(t,2147483647,-2147483648));var i=e.length;r>=i||(t>=0?C(e,t,r,n,o):C(e,4294967295+t+1,r,n,o))}function T(e,t,r,n,o){o||(G(void 0!==t&&null!==t,"missing value"),G("boolean"==typeof n,"missing or invalid endian"),G(void 0!==r&&null!==r,"missing offset"),G(r+3<e.length,"Trying to write beyond buffer length"),$(t,3.4028234663852886e38,-3.4028234663852886e38));var i=e.length;r>=i||Q.write(e,t,r,n,23,4)}function M(e,t,r,n,o){o||(G(void 0!==t&&null!==t,"missing value"),G("boolean"==typeof n,"missing or invalid endian"),G(void 0!==r&&null!==r,"missing offset"),G(r+7<e.length,"Trying to write beyond buffer length"),$(t,1.7976931348623157e308,-1.7976931348623157e308));var i=e.length;r>=i||Q.write(e,t,r,n,52,8)}function N(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}function Y(e,t,r){return"number"!=typeof e?r:(e=~~e,e>=t?t:e>=0?e:(e+=t,e>=0?e:0))}function F(e){return e=~~Math.ceil(+e),0>
80e?0:e}function D(e){return(Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)})(e)}function O(e){return D(e)||o.isBuffer(e)||e&&"object"==typeof e&&"number"==typeof e.length}function H(e){return 16>e?"0"+e.toString(16):e.toString(16)}function V(e){for(var t=[],r=0;r<e.length;r++){var n=e.charCodeAt(r);if(127>=n)t.push(e.charCodeAt(r));else{var o=r;n>=55296&&57343>=n&&r++;for(var i=encodeURIComponent(e.slice(o,r+1)).substr(1).split("%"),u=0;u<i.length;u++)t.push(parseInt(i[u],16))}}return t}function q(e){for(var t=[],r=0;r<e.length;r++)t.push(255&e.charCodeAt(r));return t}function P(e){for(var t,r,n,o=[],i=0;i<e.length;i++)t=e.charCodeAt(i),r=t>>8,n=t%256,o.push(n),o.push(r);return o}function R(e){return K.toByteArray(e)}function W(e,t,r,n){for(var o=0;n>o&&!(o+r>=t.length||o>=e.length);o++)t[o+r]=e[o];return o}function J(e){try{return decodeURIComponent(e)}catch(t){return String.fromCharCode(65533)}}function z(e,t){G("number"==typeof e,"cannot write a non-number as a number"),G(e>=0,"specified a negative value for writing an unsigned value"),G(t>=e,"value is larger than maximum value for type"),G(Math.floor(e)===e,"value has a fractional component")}function X(e,t,r){G("number"==typeof e,"cannot write a non-number as a number"),G(t>=e,"value larger than maximum allowed value"),G(e>=r,"value smaller than minimum allowed value"),G(Math.floor(e)===e,"value has a fractional component")}function $(e,t,r){G("number"==typeof e,"cannot write a non-number as a number"),G(t>=e,"value larger than maximum allowed value"),G(e>=r,"value smaller than minimum allowed value")}function G(e,t){if(!e)throw new Error(t||"Failed assertion")}var K=e("base64-js"),Q=e("ieee754");r.Buffer=o,r.SlowBuffer=o,r.INSPECT_MAX_BYTES=50,o.poolSize=8192,o._useTypedArrays=function(){try{var e=new ArrayBuffer(0),t=new Uint8Array(e);return t.foo=function(){return 42},42===t.foo()&&"function"==typeof t.subarray}catch(r){return!1}}(),o.isEncoding=function(e){switch(String(e).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"binary":case"base64":case"raw":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},o.isBuffer=function(e){return!(null===e||void 0===e||!e._isBuffer)},o.byteLength=function(e,t){var r;switch(e+="",t||"utf8"){case"hex":r=e.length/2;break;case"utf8":case"utf-8":r=V(e).length;break;case"ascii":case"binary":case"raw":r=e.length;break;case"base64":r=R(e).length;break;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":r=2*e.length;break;default:throw new Error("Unknown encoding")}return r},o.concat=function(e,t){if(G(D(e),"Usage: Buffer.concat(list, [totalLength])\nlist should be an Array."),0===e.length)return new o(0);if(1===e.length)return e[0];var r;if("number"!=typeof t)for(t=0,r=0;r<e.length;r++)t+=e[r].length;var n=new o(t),i=0;for(r=0;r<e.length;r++){var u=e[r];u.copy(n,i),i+=u.length}return n},o.prototype.write=function(e,t,r,n){if(isFinite(t))isFinite(r)||(n=r,r=void 0);else{var o=n;n=t,t=r,r=o}t=Number(t)||0;var i=this.length-t;r?(r=Number(r),r>i&&(r=i)):r=i,n=String(n||"utf8").toLowerCase();var u;switch(n){case"hex":u=l(this,e,t,r);break;case"utf8":case"utf-8":u=d(this,e,t,r);break;case"ascii":u=h(this,e,t,r);break;case"binary":u=p(this,e,t,r);break;case"base64":u=g(this,e,t,r);break;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":u=w(this,e,t,r);break;default:throw new Error("Unknown encoding")}return u},o.prototype.toString=function(e,t,r){var n=this;if(e=String(e||"utf8").toLowerCase(),t=Number(t)||0,r=void 0!==r?Number(r):r=n.length,r===t)return"";var o;switch(e){case"hex":o=_(n,t,r);break;case"utf8":case"utf-8":o=m(n,t,r);break;case"ascii":o=b(n,t,r);break;case"binary":o=v(n,t,r);break;case"base64":o=y(n,t,r);break;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":o=E(n,t,r);break;default:throw new Error("Unknown encoding")}return o},o.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}},o.prototype.copy=function(e,t,r,n){var i=this;if(r||(r=0),n||0===n||(n=this.length),t||(t=0),n!==r&&0!==e.length&&0!==i.length){G(n>=r,"sourceEnd < sourceStart"),G(t>=0&&t<e.length,"targetStart out of bounds"),G(r>=0&&r<i.length,"sourceStart out of bounds"),G(n>=0&&n<=i.length,"sourceEnd out of bounds"),n>this.length&&(n=this.length),e.length-t<n-r&&(n=e.length-t+r);var u=n-r;if(100>u||!o._useTypedArrays)for(var a=0;u>a;a++)e[a+t]=this[a+r];else e._set(this.subarray(r,r+u),t)}},o.prototype.slice=function(e,t){var r=this.length;if(e=Y(e,r,0),t=Y(t,r,r),o._useTypedArrays)return o._augment(this.subarray(e,t));for(var n=t-e,i=new o(n,void 0,!0),u=0;n>u;u++)i[u]=this[u+e];return i},o.prototype.get=function(e){return console.log(".get() is deprecated. Access using array indexes instead."),this.readUInt8(e)},o.prototype.set=function(e,t){return console.log(".set() is deprecated. Access using array indexes instead."),this.writeUInt8(e,t)},o.prototype.readUInt8=function(e,t){return t||(G(void 0!==e&&null!==e,"missing offset"),G(e<this.length,"Trying to read beyond buffer length")),e>=this.length?void 0:this[e]},o.prototype.readUInt16LE=function(e,t){return I(this,e,!0,t)},o.prototype.readUInt16BE=function(e,t){return I(this,e,!1,t)},o.prototype.readUInt32LE=function(e,t){return A(this,e,!0,t)},o.prototype.readUInt32BE=function(e,t){return A(this,e,!1,t)},o.prototype.readInt8=function(e,t){if(t||(G(void 0!==e&&null!==e,"missing offset"),G(e<this.length,"Trying to read beyond buffer length")),!(e>=this.length)){var r=128&this[e];return r?-1*(255-this[e]+1):this[e]}},o.prototype.readInt16LE=function(e,t){return B(this,e,!0,t)},o.prototype.readInt16BE=function(e,t){return B(this,e,!1,t)},o.prototype.readInt32LE=function(e,t){return L(this,e,!0,t)},o.prototype.readInt32BE=function(e,t){return L(this,e,!1,t)},o.prototype.readFloatLE=function(e,t){return U(this,e,!0,t)},o.prototype.readFloatBE=function(e,t){return U(this,e,!1,t)},o.prototype.readDoubleLE=function(e,t){return x(this,e,!0,t)},o.prototype.readDoubleBE=function(e,t){return x(this,e,!1,t)},o.prototype.writeUInt8=function(e,t,r){r||(G(void 0!==e&&null!==e,"missing value"),G(void 0!==t&&null!==t,"missing offset"),G(t<this.length,"trying to write beyond buffer length"),z(e,255)),t>=this.length||(this[t]=e)},o.prototype.writeUInt16LE=function(e,t,r){S(this,e,t,!0,r)},o.prototype.writeUInt16BE=function(e,t,r){S(this,e,t,!1,r)},o.prototype.writeUInt32LE=function(e,t,r){C(this,e,t,!0,r)},o.prototype.writeUInt32BE=function(e,t,r){C(this,e,t,!1,r)},o.prototype.writeInt8=function(e,t,r){r||(G(void 0!==e&&null!==e,"missing value"),G(void 0!==t&&null!==t,"missing offset"),G(t<this.length,"Trying to write beyond buffer length"),X(e,127,-128)),t>=this.length||(e>=0?this.writeUInt8(e,t,r):this.writeUInt8(255+e+1,t,r))},o.prototype.writeInt16LE=function(e,t,r){j(this,e,t,!0,r)},o.prototype.writeInt16BE=function(e,t,r){j(this,e,t,!1,r)},o.prototype.writeInt32LE=function(e,t,r){k(this,e,t,!0,r)},o.prototype.writeInt32BE=function(e,t,r){k(this,e,t,!1,r)},o.prototype.writeFloatLE=function(e,t,r){T(this,e,t,!0,r)},o.prototype.writeFloatBE=function(e,t,r){T(this,e,t,!1,r)},o.prototype.writeDoubleLE=function(e,t,r){M(this,e,t,!0,r)},o.prototype.writeDoubleBE=function(e,t,r){M(this,e,t,!1,r)},o.prototype.fill=function(e,t,r){if(e||(e=0),t||(t=0),r||(r=this.length),"string"==typeof e&&(e=e.charCodeAt(0)),G("number"==typeof e&&!isNaN(e),"value is not a number"),G(r>=t,"end < start"),r!==t&&0!==this.length){G(t>=0&&t<this.length,"start out of bounds"),G(r>=0&&r<=this.length,"end out of bounds");for(var n=t;r>n;n++)this[n]=e}},o.prototype.inspect=function(){for(var e=[],t=this.length,n=0;t>n;n++)if(e[n]=H(this[n]),n===r.INSPECT_MAX_BYTES){e[n+1]="...";break}return"<Buffer "+e.join(" ")+">"},o.prototype.toArrayBuffer=function(){if("undefined"!=typeof Uint8Array){if(o._useTypedArrays)return new o(this).buffer;for(var e=new Uint8Array(this.length),t=0,r=e.length;r>t;t+=1)e[t]=this[t];return e.buffer}throw new Error("Buffer.toArrayBuffer not supported in this browser")};var Z=o.prototype;o._augment=function(e){return e._isBuffer=!0,e._get=e.get,e._set=e.set,e.get=Z.get,e.set=Z.set,e.write=Z.write,e.toString=Z.toString,e.toLocaleStr
80ing=Z.toString,e.toJSON=Z.toJSON,e.copy=Z.copy,e.slice=Z.slice,e.readUInt8=Z.readUInt8,e.readUInt16LE=Z.readUInt16LE,e.readUInt16BE=Z.readUInt16BE,e.readUInt32LE=Z.readUInt32LE,e.readUInt32BE=Z.readUInt32BE,e.readInt8=Z.readInt8,e.readInt16LE=Z.readInt16LE,e.readInt16BE=Z.readInt16BE,e.readInt32LE=Z.readInt32LE,e.readInt32BE=Z.readInt32BE,e.readFloatLE=Z.readFloatLE,e.readFloatBE=Z.readFloatBE,e.readDoubleLE=Z.readDoubleLE,e.readDoubleBE=Z.readDoubleBE,e.writeUInt8=Z.writeUInt8,e.writeUInt16LE=Z.writeUInt16LE,e.writeUInt16BE=Z.writeUInt16BE,e.writeUInt32LE=Z.writeUInt32LE,e.writeUInt32BE=Z.writeUInt32BE,e.writeInt8=Z.writeInt8,e.writeInt16LE=Z.writeInt16LE,e.writeInt16BE=Z.writeInt16BE,e.writeInt32LE=Z.writeInt32LE,e.writeInt32BE=Z.writeInt32BE,e.writeFloatLE=Z.writeFloatLE,e.writeFloatBE=Z.writeFloatBE,e.writeDoubleLE=Z.writeDoubleLE,e.writeDoubleBE=Z.writeDoubleBE,e.fill=Z.fill,e.inspect=Z.inspect,e.toArrayBuffer=Z.toArrayBuffer,e}}).call(this,e("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/buffer/index.js","/node_modules/gulp-browserify/node_modules/buffer")},{"base64-js":2,buffer:3,ieee754:11,lYpoI2:10}],4:[function(e,t,r){(function(r,n,o,i,u,a,s,f,c){function l(e,t){if(e.length%p!==0){var r=e.length+(p-e.length%p);e=o.concat([e,g],r)}for(var n=[],i=t?e.readInt32BE:e.readInt32LE,u=0;u<e.length;u+=p)n.push(i.call(e,u));return n}function d(e,t,r){for(var n=new o(t),i=r?n.writeInt32BE:n.writeInt32LE,u=0;u<e.length;u++)i.call(n,e[u],4*u,!0);return n}function h(e,t,r,n){o.isBuffer(e)||(e=new o(e));var i=t(l(e,n),e.length*w);return d(i,r,n)}var o=e("buffer").Buffer,p=4,g=new o(p);g.fill(0);var w=8;t.exports={hash:h}}).call(this,e("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/helpers.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{buffer:3,lYpoI2:10}],5:[function(e,t,r){(function(t,n,o,i,u,a,s,f,c){function l(e,t,r){o.isBuffer(t)||(t=new o(t)),o.isBuffer(r)||(r=new o(r)),t.length>v?t=e(t):t.length<v&&(t=o.concat([t,_],v));for(var n=new o(v),i=new o(v),u=0;v>u;u++)n[u]=54^t[u],i[u]=92^t[u];var a=e(o.concat([n,r]));return e(o.concat([i,a]))}function d(e,t){e=e||"sha1";var r=b[e],n=[],i=0;return r||h("algorithm:",e,"is not yet supported"),{update:function(e){return o.isBuffer(e)||(e=new o(e)),n.push(e),i+=e.length,this},digest:function(e){var i=o.concat(n),u=t?l(r,t,i):r(i);return n=null,e?u.toString(e):u}}}function h(){var e=[].slice.call(arguments).join(" ");throw new Error([e,"we accept pull requests","http://github.com/dominictarr/crypto-browserify"].join("\n"))}function p(e,t){for(var r in e)t(e[r],r)}var o=e("buffer").Buffer,g=e("./sha"),w=e("./sha256"),y=e("./rng"),m=e("./md5"),b={sha1:g,sha256:w,md5:m},v=64,_=new o(v);_.fill(0),r.createHash=function(e){return d(e)},r.createHmac=function(e,t){return d(e,t)},r.randomBytes=function(e,t){if(!t||!t.call)return new o(y(e));try{t.call(this,void 0,new o(y(e)))}catch(r){t(r)}},p(["createCredentials","createCipher","createCipheriv","createDecipher","createDecipheriv","createSign","createVerify","createDiffieHellman","pbkdf2"],function(e){r[e]=function(){h("sorry,",e,"is not implemented yet")}})}).call(this,e("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/index.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{"./md5":6,"./rng":7,"./sha":8,"./sha256":9,buffer:3,lYpoI2:10}],6:[function(e,t,r){(function(r,n,o,i,u,a,s,f,c){function l(e,t){e[t>>5]|=128<<t%32,e[(t+64>>>9<<4)+14]=t;for(var r=1732584193,n=-271733879,o=-1732584194,i=271733878,u=0;u<e.length;u+=16){var a=r,s=n,f=o,c=i;r=h(r,n,o,i,e[u+0],7,-680876936),i=h(i,r,n,o,e[u+1],12,-389564586),o=h(o,i,r,n,e[u+2],17,606105819),n=h(n,o,i,r,e[u+3],22,-1044525330),r=h(r,n,o,i,e[u+4],7,-176418897),i=h(i,r,n,o,e[u+5],12,1200080426),o=h(o,i,r,n,e[u+6],17,-1473231341),n=h(n,o,i,r,e[u+7],22,-45705983),r=h(r,n,o,i,e[u+8],7,1770035416),i=h(i,r,n,o,e[u+9],12,-1958414417),o=h(o,i,r,n,e[u+10],17,-42063),n=h(n,o,i,r,e[u+11],22,-1990404162),r=h(r,n,o,i,e[u+12],7,1804603682),i=h(i,r,n,o,e[u+13],12,-40341101),o=h(o,i,r,n,e[u+14],17,-1502002290),n=h(n,o,i,r,e[u+15],22,1236535329),r=p(r,n,o,i,e[u+1],5,-165796510),i=p(i,r,n,o,e[u+6],9,-1069501632),o=p(o,i,r,n,e[u+11],14,643717713),n=p(n,o,i,r,e[u+0],20,-373897302),r=p(r,n,o,i,e[u+5],5,-701558691),i=p(i,r,n,o,e[u+10],9,38016083),o=p(o,i,r,n,e[u+15],14,-660478335),n=p(n,o,i,r,e[u+4],20,-405537848),r=p(r,n,o,i,e[u+9],5,568446438),i=p(i,r,n,o,e[u+14],9,-1019803690),o=p(o,i,r,n,e[u+3],14,-187363961),n=p(n,o,i,r,e[u+8],20,1163531501),r=p(r,n,o,i,e[u+13],5,-1444681467),i=p(i,r,n,o,e[u+2],9,-51403784),o=p(o,i,r,n,e[u+7],14,1735328473),n=p(n,o,i,r,e[u+12],20,-1926607734),r=g(r,n,o,i,e[u+5],4,-378558),i=g(i,r,n,o,e[u+8],11,-2022574463),o=g(o,i,r,n,e[u+11],16,1839030562),n=g(n,o,i,r,e[u+14],23,-35309556),r=g(r,
80n,o,i,e[u+1],4,-1530992060),i=g(i,r,n,o,e[u+4],11,1272893353),o=g(o,i,r,n,e[u+7],16,-155497632),n=g(n,o,i,r,e[u+10],23,-1094730640),r=g(r,n,o,i,e[u+13],4,681279174),i=g(i,r,n,o,e[u+0],11,-358537222),o=g(o,i,r,n,e[u+3],16,-722521979),n=g(n,o,i,r,e[u+6],23,76029189),r=g(r,n,o,i,e[u+9],4,-640364487),i=g(i,r,n,o,e[u+12],11,-421815835),o=g(o,i,r,n,e[u+15],16,530742520),n=g(n,o,i,r,e[u+2],23,-995338651),r=w(r,n,o,i,e[u+0],6,-198630844),i=w(i,r,n,o,e[u+7],10,1126891415),o=w(o,i,r,n,e[u+14],15,-1416354905),n=w(n,o,i,r,e[u+5],21,-57434055),r=w(r,n,o,i,e[u+12],6,1700485571),i=w(i,r,n,o,e[u+3],10,-1894986606),o=w(o,i,r,n,e[u+10],15,-1051523),n=w(n,o,i,r,e[u+1],21,-2054922799),r=w(r,n,o,i,e[u+8],6,1873313359),i=w(i,r,n,o,e[u+15],10,-30611744),o=w(o,i,r,n,e[u+6],15,-1560198380),n=w(n,o,i,r,e[u+13],21,1309151649),r=w(r,n,o,i,e[u+4],6,-145523070),i=w(i,r,n,o,e[u+11],10,-1120210379),o=w(o,i,r,n,e[u+2],15,718787259),n=w(n,o,i,r,e[u+9],21,-343485551),r=y(r,a),n=y(n,s),o=y(o,f),i=y(i,c)}return Array(r,n,o,i)}function d(e,t,r,n,o,i){return y(m(y(y(t,e),y(n,i)),o),r)}function h(e,t,r,n,o,i,u){return d(t&r|~t&n,e,t,o,i,u)}function p(e,t,r,n,o,i,u){return d(t&n|r&~n,e,t,o,i,u)}function g(e,t,r,n,o,i,u){return d(t^r^n,e,t,o,i,u)}function w(e,t,r,n,o,i,u){return d(r^(t|~n),e,t,o,i,u)}function y(e,t){var r=(65535&e)+(65535&t),n=(e>>16)+(t>>16)+(r>>16);return n<<16|65535&r}function m(e,t){return e<<t|e>>>32-t}var b=e("./helpers");t.exports=function(e){return b.hash(e,l,16)}}).call(this,e("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/md5.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{"./helpers":4,buffer:3,lYpoI2:10}],7:[function(e,t,r){(function(e,r,n,o,i,u,a,s,f){!function(){var e,r,n=this;e=function(e){for(var t,t,r=new Array(e),n=0;e>n;n++)0==(3&n)&&(t=4294967296*Math.random()),r[n]=t>>>((3&n)<<3)&255;return r},n.crypto&&crypto.getRandomValues&&(r=function(e){var t=new Uint8Array(e);return crypto.getRandomValues(t),t}),t.exports=r||e}()}).call(this,e("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/rng.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{buffer:3,lYpoI2:10}],8:[function(e,t,r){(function(r,n,o,i,u,a,s,f,c){function l(e,t){e[t>>5]|=128<<24-t%32,e[(t+64>>9<<4)+15]=t;for(var r=Array(80),n=1732584193,o=-271733879,i=-1732584194,u=271733878,a=-1009589776,s=0;s<e.length;s+=16){for(var f=n,c=o,l=i,w=u,y=a,m=0;80>m;m++){16>m?r[m]=e[s+m]:r[m]=g(r[m-3]^r[m-8]^r[m-14]^r[m-16],1);var b=p(p(g(n,5),d(m,o,i,u)),p(p(a,r[m]),h(m)));a=u,u=i,i=g(o,30),o=n,n=b}n=p(n,f),o=p(o,c),i=p(i,l),u=p(u,w),a=p(a,y)}return Array(n,o,i,u,a)}function d(e,t,r,n){return 20>e?t&r|~t&n:40>e?t^r^n:60>e?t&r|t&n|r&n:t^r^n}function h(e){return 20>e?1518500249:40>e?1859775393:60>e?-1894007588:-899497514}function p(e,t){var r=(65535&e)+(65535&t),n=(e>>16)+(t>>16)+(r>>16);return n<<16|65535&r}function g(e,t){return e<<t|e>>>32-t}var w=e("./helpers");t.exports=function(e){return w.hash(e,l,20,!0)}}).call(this,e("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/sha.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{"./helpers":4,buffer:3,lYpoI2:10}],9:[function(e,t,r){(function(r,n,o,i,u,a,s,f,c){var l=e("./helpers"),d=function(e,t){var r=(65535&e)+(65535&t),n=(e>>16)+(t>>16)+(r>>16);return n<<16|65535&r},h=function(e,t){return e>>>t|e<<32-t; 81},p=function(e,t){return e>>>t},g=function(e,t,r){return e&t^~e&r},w=function(e,t,r){return e&t^e&r^t&r},y=function(e){return h(e,2)^h(e,13)^h(e,22)},m=function(e){return h(e,6)^h(e,11)^h(e,25)},b=function(e){return h(e,7)^h(e,18)^p(e,3)},v=function(e){return h(e,17)^h(e,19)^p(e,10)},_=function(e,t){var r,n,o,i,u,a,s,f,c,l,h,p,_=new Array(1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756
81734187,3204031479,3329325298),E=new Array(1779033703,3144134277,1013904242,2773480762,1359893119,2600822924,528734635,1541459225),I=new Array(64);e[t>>5]|=128<<24-t%32,e[(t+64>>9<<4)+15]=t;for(var c=0;c<e.length;c+=16){r=E[0],n=E[1],o=E[2],i=E[3],u=E[4],a=E[5],s=E[6],f=E[7];for(var l=0;64>l;l++)16>l?I[l]=e[l+c]:I[l]=d(d(d(v(I[l-2]),I[l-7]),b(I[l-15])),I[l-16]),h=d(d(d(d(f,m(u)),g(u,a,s)),_[l]),I[l]),p=d(y(r),w(r,n,o)),f=s,s=a,a=u,u=d(i,h),i=o,o=n,n=r,r=d(h,p);E[0]=d(r,E[0]),E[1]=d(n,E[1]),E[2]=d(o,E[2]),E[3]=d(i,E[3]),E[4]=d(u,E[4]),E[5]=d(a,E[5]),E[6]=d(s,E[6]),E[7]=d(f,E[7])}return E};t.exports=function(e){return l.hash(e,_,32,!0)}}).call(this,e("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/crypto-browserify/sha256.js","/node_modules/gulp-browserify/node_modules/crypto-browserify")},{"./helpers":4,buffer:3,lYpoI2:10}],10:[function(e,t,r){(function(e,r,n,o,i,u,a,s,f){function c(){}var e=t.exports={};e.nextTick=function(){var e="undefined"!=typeof window&&window.setImmediate,t="undefined"!=typeof window&&window.postMessage&&window.addEventListener;if(e)return function(e){return window.setImmediate(e)};if(t){var r=[];return window.addEventListener("message",function(e){var t=e.source;if((t===window||null===t)&&"process-tick"===e.data&&(e.stopPropagation(),r.length>0)){var n=r.shift();n()}},!0),function(e){r.push(e),window.postMessage("process-tick","*")}}return function(e){setTimeout(e,0)}}(),e.title="browser",e.browser=!0,e.env={},e.argv=[],e.on=c,e.addListener=c,e.once=c,e.off=c,e.removeListener=c,e.removeAllListeners=c,e.emit=c,e.binding=function(e){throw new Error("process.binding is not supported")},e.cwd=function(){return"/"},e.chdir=function(e){throw new Error("process.chdir is not supported")}}).call(this,e("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/gulp-browserify/node_modules/process/browser.js","/node_modules/gulp-browserify/node_modules/process")},{buffer:3,lYpoI2:10}],11:[function(e,t,r){(function(e,t,n,o,i,u,a,s,f){r.read=function(e,t,r,n,o){var i,u,a=8*o-n-1,s=(1<<a)-1,f=s>>1,c=-7,l=r?o-1:0,d=r?-1:1,h=e[t+l];for(l+=d,i=h&(1<<-c)-1,h>>=-c,c+=a;c>0;i=256*i+e[t+l],l+=d,c-=8);for(u=i&(1<<-c)-1,i>>=-c,c+=n;c>0;u=256*u+e[t+l],l+=d,c-=8);if(0===i)i=1-f;else{if(i===s)return u?NaN:(h?-1:1)*(1/0);u+=Math.pow(2,n),i-=f}return(h?-1:1)*u*Math.pow(2,i-n)},r.write=function(e,t,r,n,o,i){var u,a,s,f=8*i-o-1,c=(1<<f)-1,l=c>>1,d=23===o?Math.pow(2,-24)-Math.pow(2,-77):0,h=n?0:i-1,p=n?1:-1,g=0>t||0===t&&0>1/t?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(a=isNaN(t)?1:0,u=c):(u=Math.floor(Math.log(t)/Math.LN2),t*(s=Math.pow(2,-u))<1&&(u--,s*=2),t+=u+l>=1?d/s:d*Math.pow(2,1-l),t*s>=2&&(u++,s/=2),u+l>=c?(a=0,u=c):u+l>=1?(a=(t*s-1)*Math.pow(2,o),u+=l):(a=t*Math.pow(2,l-1)*Math.pow(2,o),u=0));o>=8;e[r+h]=255&a,h+=p,a/=256,o-=8);for(u=u<<o|a,f+=o;f>0;e[r+h]=255&u,h+=p,u/=256,f-=8);e[r+h-p]|=128*g}}).call(this,e("lYpoI2"),"undefined"!=typeof self?self:"undefined"!=typeof window?window:{},e("buffer").Buffer,arguments[3],arguments[4],arguments[5],arguments[6],"/node_modules/ieee754/index.js","/node_modules/ieee754")},{buffer:3,lYpoI2:10}]},{},[1])(1)});; 82/* AUTOGENERATED: jquery.validationEngine-en.js */ 83!function(e){e.fn.validationEngineLanguage=function(){},e.validationEngineLanguage={newLang:function(){e.validationEngineLanguage.allRules={required:{regex:"none",alertText:"* This field is required",alertTextCheckboxMultiple:"* Please select an option",alertTextCheckboxe:"* This checkbox is required",alertTextDateRange:"* Both date range fields are required"},requiredInFunction:{func:function(e,a,t,d){return"test"==e.val()},alertText:"* Field must equal test"},dateRange:{regex:"none",alertText:"* Invalid ",alertText2:"Date Range"},dateTimeRange:{regex:"none",alertText:"* Invalid ",alertText2:"Date Time Range"},minSize:{regex:"none",alertText:"* Minimum ",alertText2:" characters required"},maxSize:{regex:"none",alertText:"* Maximum ",alertText2:" characters allowed"},groupRequired:{regex:"none",alertText:"* You must fill one of the following fields",alertTextCheckboxMultiple:"* Please select an option",alertTextCheckboxe:"* This checkbox is required"},min:{regex:"none",alertText:"* Minimum value is "},max:{regex:"none",alertText:"* Maximum value is "},past:{regex:"none",alertText:"* Date prior to "},future:{regex:"none",alertText:"* Date past "},maxCheckbox:{regex:"none",alertText:"* Maximum ",alertText2:" options allowed"},minCheckbox:{regex:"none",alertText:"* Please select ",alertText2:" options"},equals:{regex:"none",alertText:"* Fields do not match"},creditCard:{regex:"none",alertText:"* Invalid credit card number"},phone:{regex:/^([\+][0-9]{1,3}([ \.\-])?)?([\(][0-9]{1,6}[\)])?([0-9 \.\-]{1,32})(([A-Za-z \:]{1,11})?[0-9]{1,4}?)$/,alertText:"* Invalid phone number"},email:{regex:/^(([^<>()[\]\\.,;:\s@\"]+(\.[^<>()[\]\\.,;:\s@\"]+)*)|(\".+\"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/,alertText:"* Invalid email address"},fullname:{regex:/^([a-zA-Z]+[\'\,\.\-]?[a-zA-Z ]*)+[ ]([a-zA-Z]+[\'\,\.\-]?[a-zA-Z ]+)+$/,alertText:"* Must be first and last name"},zip:{regex:/^\d{5}$|^\d{5}-\d{4}$/,alertText:"* Invalid zip format"},integer:{regex:/^[\-\+]?\d+$/,alertText:"* Not a valid integer"},number:{regex:/^[\-\+]?((([0-9]{1,3})([,][0-9]{3})*)|([0-9]+))?([\.]([0-9]+))?$/,alertText:"* Invalid floating decimal number"},date:{func:function(e){var a=new RegExp(/^(\d{4})[\/\-\.](0?[1-9]|1[012])[\/\-\.](0?[1-9]|[12][0-9]|3[01])$/).exec(e.val());if(null==a)return!1;var t=a[1],d=+a[2],r=+a[3],l=new Date(t,d-1,r);return l.getFullYear()==t&&l.getMonth()==d-1&&l.getDate()==r},alertText:"* Invalid date, must be in YYYY-MM-DD format"},ipv4:{regex:/^((([01]?[0-9]{1,2})|(2[0-4][0-9])|(25[0-5]))[.]){3}(([0-1]?[0-9]{1,2})|(2[0-4][0-9])|(25[0-5]))$/,alertText:"* Invalid IP address"},ip:{regex:/((^\s*((([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5]))\s*$)|(^\s*((([0-9A-Fa-f]{1,4}:){7}([0-9A-Fa-f]{1,4}|:))|(([0-9A-Fa-f]{1,4}:){6}(:[0-9A-Fa-f]{1,4}|((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){5}(((:[0-9A-Fa-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){4}(((:[0-9A-Fa-f]{1,4}){1,3})|((:[0-9A-Fa-f]{1,4})?:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){3}(((:[0-9A-Fa-f]{1,4}){1,4})|((:[0-9A-Fa-f]{1,4}){0,2}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){2}(((:[0-9A-Fa-f]{1,4}){1,5})|((:[0-9A-Fa-f]{1,4}){0,3}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){1}(((:[0-9A-Fa-f]{1,4}){1,6})|((:[0-9A-Fa-f]{1,4}){0,4}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(:(((:[0-9A-Fa-f]{1,4}){1,7})|((:[0-9A-Fa-f]{1,4}){0,5}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))(%.+)?\s*$))/,alertText:"* Invalid IP address"},url:{regex:/^(https?|ftp):\/\/(((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:)*@)?(((\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]))|((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?)(:\d*)?)(\/((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)+(\/(([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)*)*)?)?(\?((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|[\uE000-\uF8FF]|\/|\?)*)?(\#((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|\/|\?)*)?$/i,alertText:"* Invalid URL"},onlyNumberSp:{regex:/^[0-9\ ]+$/,alertText:"* Numbers only"},onlyLetterSp:{regex:/^[a-zA-Z\ \']+$/,alertText:"* Letters only"}
83,onlyLetterAccentSp:{regex:/^[a-z\u00C0-\u017F\ ]+$/i,alertText:"* Letters only (accents allowed)"},onlyLetterNumber:{regex:/^[0-9a-zA-Z]+$/,alertText:"* No special characters allowed"},ajaxUserCall:{url:"ajaxValidateFieldUser",extraData:"name=eric",alertText:"* This user is already taken",alertTextLoad:"* Validating, please wait"},ajaxUserCallPhp:{url:"phpajax/ajaxValidateFieldUser.php",extraData:"name=eric",alertTextOk:"* This username is available",alertText:"* This user is already taken",alertTextLoad:"* Validating, please wait"},ajaxNameCall:{url:"ajaxValidateFieldName",alertText:"* This name is already taken",alertTextOk:"* This name is available",alertTextLoad:"* Validating, please wait"},ajaxNameCallPhp:{url:"phpajax/ajaxValidateFieldName.php",alertText:"* This name is already taken",alertTextLoad:"* Validating, please wait"},validate2fields:{alertText:"* Please input HELLO"},dateFormat:{regex:/^\d{4}[\/\-](0?[1-9]|1[012])[\/\-](0?[1-9]|[12][0-9]|3[01])$|^(?:(?:(?:0?[13578]|1[02])(\/|-)31)|(?:(?:0?[1,3-9]|1[0-2])(\/|-)(?:29|30)))(\/|-)(?:[1-9]\d\d\d|\d[1-9]\d\d|\d\d[1-9]\d|\d\d\d[1-9])$|^(?:(?:0?[1-9]|1[0-2])(\/|-)(?:0?[1-9]|1\d|2[0-8]))(\/|-)(?:[1-9]\d\d\d|\d[1-9]\d\d|\d\d[1-9]\d|\d\d\d[1-9])$|^(0?2(\/|-)29)(\/|-)(?:(?:0[48]00|[13579][26]00|[2468][048]00)|(?:\d\d)?(?:0[48]|[2468][048]|[13579][26]))$/,alertText:"* Invalid Date"},dateTimeFormat:{regex:/^\d{4}[\/\-](0?[1-9]|1[012])[\/\-](0?[1-9]|[12][0-9]|3[01])\s+(1[012]|0?[1-9]){1}:(0?[1-5]|[0-6][0-9]){1}:(0?[0-6]|[0-6][0-9]){1}\s+(am|pm|AM|PM){1}$|^(?:(?:(?:0?[13578]|1[02])(\/|-)31)|(?:(?:0?[1,3-9]|1[0-2])(\/|-)(?:29|30)))(\/|-)(?:[1-9]\d\d\d|\d[1-9]\d\d|\d\d[1-9]\d|\d\d\d[1-9])$|^((1[012]|0?[1-9]){1}\/(0?[1-9]|[12][0-9]|3[01]){1}\/\d{2,4}\s+(1[012]|0?[1-9]){1}:(0?[1-5]|[0-6][0-9]){1}:(0?[0-6]|[0-6][0-9]){1}\s+(am|pm|AM|PM){1})$/,alertText:"* Invalid Date or Date Format",alertText2:"Expected Format: ",alertText3:"mm/dd/yyyy hh:mm:ss AM|PM or ",alertText4:"yyyy-mm-dd hh:mm:ss AM|PM"}}}},e.validationEngineLanguage.newLang()}(jQuery);; 84/* AUTOGENERATED: jquery.validationEngine.js */ 85!function(T){"use strict";var F={init:function(e){var t=this;return t.data("jqv")&&null!=t.data("jqv")||(e=F._saveOptions(t,e),T(document).on("click",".formError",function(){T(this).fadeOut(150,function(){T(this).closest(".formError").remove()})})),this},attach:function(e){var t,a=this;return(t=e?F._saveOptions(a,e):a.data("jqv")).validateAttribute=a.find("[data-validation-engine*=validate]").length?"data-validation-engine":"class",t.binded&&(a.on(t.validationEventTrigger,"["+t.validateAttribute+"*=validate]:not([type=checkbox]):not([type=radio]):not(.datepicker)",F._onFieldEvent),a.on("click","["+t.validateAttribute+"*=validate][type=checkbox],["+t.validateAttribute+"*=validate][type=radio]",F._onFieldEvent),a.on(t.validationEventTrigger,"["+t.validateAttribute+"*=validate][class*=datepicker]",{delay:300},F._onFieldEvent)),t.autoPositionUpdate&&T(window).bind("resize",{noAnimation:!0,formElem:a},F.updatePromptsPosition),a.on("click","a[data-validation-engine-skip], a[class*='validate-skip'], button[data-validation-engine-skip], button[class*='validate-skip'], input[data-validation-engine-skip], input[class*='validate-skip']",F._submitButtonClick),a.removeData("jqv_submitButton"),a.on("submit",F._onSubmitEvent),this},detach:function(){var e=this,t=e.data("jqv");return e.off(t.validationEventTrigger,"["+t.validateAttribute+"*=validate]:not([type=checkbox]):not([type=radio]):not(.datepicker)",F._onFieldEvent),e.off("click","["+t.validateAttribute+"*=validate][type=checkbox],["+t.validateAttribute+"*=validate][type=radio]",F._onFieldEvent),e.off(t.validationEventTrigger,"["+t.validateAttribute+"*=validate][class*=datepicker]",F._onFieldEvent),e.off("submit",F._onSubmitEvent),e.removeData("jqv"),e.off("click","a[data-validation-engine-skip], a[class*='validate-skip'], button[data-validation-engine-skip], button[class*='validate-skip'], input[data-validation-engine-skip], input[class*='validate-skip']",F._submitButtonClick),e.removeData("jqv_submitButton"),t.autoPositionUpdate&&T(window).off("resize",F.updatePromptsPosition),this},validate:function(e){var t,a=T(this),r=null;
85if(a.is("form")||a.hasClass("validationEngineContainer")){if(a.hasClass("validating"))return!1;a.addClass("validating"),t=e?F._saveOptions(a,e):a.data("jqv");r=F._validateFields(this);setTimeout(function(){a.removeClass("validating")},100),r&&t.onSuccess?t.onSuccess():!r&&t.onFailure&&t.onFailure()}else{if(!a.is("form")&&!a.hasClass("validationEngineContainer")){var i=a.closest("form, .validationEngineContainer");return t=i.data("jqv")?i.data("jqv"):T.validationEngine.defaults,(r=F._validateField(a,t))&&t.onFieldSuccess?t.onFieldSuccess():t.onFieldFailure&&0<t.InvalidFields.length&&t.onFieldFailure(),!r}a.removeClass("validating")}return t.onValidationComplete?!!t.onValidationComplete(i,r):r},updatePromptsPosition:function(e){if(e&&this==window)var r=e.data.formElem,i=e.data.noAnimation;else r=T(this.closest("form, .validationEngineContainer"));var o=r.data("jqv");return o||(o=F._saveOptions(r,o)),r.find("["+o.validateAttribute+"*=validate]").not(":disabled").each(function(){var e=T(this);o.prettySelect&&e.is(":hidden")&&(e=r.find("#"+o.usePrefix+e.attr("id")+o.useSuffix));var t=F._getPrompt(e),a=T(t).find(".formErrorContent").html();t&&F._updatePrompt(e,T(t),a,void 0,!1,o,i)}),this},showPrompt:function(e,t,a,r){var i=this.closest("form, .validationEngineContainer").data("jqv");return i||(i=F._saveOptions(this,i)),a&&(i.promptPosition=a),i.showArrow=1==r,F._showPrompt(this,e,t,!1,i),this},hide:function(){var e=T(this).closest("form, .validationEngineContainer"),t=e.data("jqv");t||(t=F._saveOptions(e,t));var a,r=t&&t.fadeDuration?t.fadeDuration:.3;
85return a=e.is("form")||e.hasClass("validationEngineContainer")?"parentForm"+F._getClassName(T(e).attr("id")):F._getClassName(T(e).attr("id"))+"formError",T("."+a).fadeTo(r,0,function(){T(this).closest(".formError").remove()}),this},hideAll:function(){var e=this.data("jqv"),t=e?e.fadeDuration:300;return T(".formError").fadeTo(t,0,function(){T(this).closest(".formError").remove()}),this},_onFieldEvent:function(e){var t=T(this),a=t.closest("form, .validationEngineContainer"),r=a.data("jqv");r||(r=F._saveOptions(a,r)),r.eventTrigger="field",1==r.notEmpty?0<t.val().length&&window.setTimeout(function(){F._validateField(t,r)},e.data?e.data.delay:0):window.setTimeout(function(){F._validateField(t,r)},e.data?e.data.delay:0)},_onSubmitEvent:function(){var e=T(this),t=e.data("jqv");if(e.data("jqv_submitButton")){var a=T("#"+e.data("jqv_submitButton"));if(a&&0<a.length&&(a.hasClass("validate-skip")||"true"==a.attr("data-validation-engine-skip")))return!0}t.eventTrigger="submit";var r=F._validateFields(e);return r&&t.ajaxFormValidation?(F._validateFormWithAjax(e,t),!1):t.onValidationComplete?!!t.onValidationComplete(e,r):r},_checkAjaxStatus:function(e){var a=!0;return T.each(e.ajaxValidCache,function(e,t){if(!t)return a=!1}),a},_checkAjaxFieldStatus:function(e,t){return 1==t.ajaxValidCache[e]},_validateFields:function(a){var r=a.data("jqv"),i=!1;a.trigger("jqv.form.validating");var o=null;if(a.find("["+r.validateAttribute+"*=validate]").not(":disabled").each(function(){var e=T(this),t=[];if(T.inArray(e.attr("name"),t)<0){if((i|=F._validateField(e,r))&&null==o&&(o=e.is(":hidden")&&r.prettySelect?e=a.find("#"+r.usePrefix+F._jqSelector(e.attr("id"))+r.useSuffix):(e.data("jqv-prompt-at")instanceof jQuery?e=e.data("jqv-prompt-at"):e.data("jqv-prompt-at")&&(e=T(e.data("jqv-prompt-at"))),e)),r.doNotShowAllErrosOnSubmit)return!1;if(t.push(e.attr("name")),1==r.showOneMessage&&i)return!1}}),a.trigger("jqv.form.result",[i]),i){if(r.scroll){var e=o.offset().top,t=o.offset().left,s=r.promptPosition;if("string"==typeof s&&-1!=s.indexOf(":")&&(s=s.substring(0,s.indexOf(":"))),"bottomRight"!=s&&"bottomLeft"!=s){var n=F._getPrompt(o);n&&(e=n.offset().top)}if(r.scrollOffset&&(e-=r.scrollOffset),r.isOverflown){var l=T(r.overflownDIV);if(!l.length)return!1;e+=l.scrollTop()+-parseInt(l.offset().top)-5,T(r.overflownDIV).filter(":not(:animated)").animate({scrollTop:e},1100,function(){r.focusFirstField&&o.focus()})}else T("html, body").animate({scrollTop:e},1100,function(){r.focusFirstField&&o.focus()}),T("html, body").animate({scrollLeft:t},1100)}else r.focusFirstField&&o.focus();return!1}return!0},_validateFormWithAjax:function(l,d){var e=l.serialize(),t=d.ajaxFormValidationMethod?d.ajaxFormValidationMethod:"GET",a=d.ajaxFormValidationURL?d.ajaxFormValidationURL:l.attr("action"),u=d.dataType?d.dataType:"json";T.ajax({type:t,url:a,cache:!1,dataType:u,data:e,form:l,methods:F,options:d,beforeSend:function(){return d.onBeforeAjaxFormValidation(l,d)},error:function(e,t){d.onFailure?d.onFailure(e,t):F._ajaxError(e,t)},success:function(e){if("json"==u&&!0!==e){for(var t=!1,a=0;a<e.length;a++){var r=e[a],i=r[0],o=T(T("#"+i)[0]);if(1==o.length){var s=r[2];if(1==r[1])if(""!=s&&s){if(d.allrules[s])(n=d.allrules[s].alertTextOk)&&(s=n);d.showPrompts&&F._showPrompt(o,s,"pass",!1,d,!0)}else F._closePrompt(o);else{var n;if(t|=!0,d.allrules[s])(n=d.allrules[s].alertText)&&(s=n);d.showPrompts&&F._showPrompt(o,s,"",!1,d,!0)}}}d.onAjaxFormComplete(!t,l,e,d)}else d.onAjaxFormComplete(!0,l,e,d)}})},_validateField:function(e,t,a){if(e.attr("id")||(e.attr("id","form-validation-field-"+T.validationEngine.fieldIdCounter),++T.validationEngine.fieldIdCounter),e.hasClass(t.ignoreFieldsWithClass))return!1;if(!t.validateNonVisibleFields&&(e.is(":hidden")&&!t.prettySelect||e.parent().is(":hidden")))return!1;var r=e.attr(t.validateAttribute),i=/validate\[(.*)\]/.exec(r);if(!i)return!1;var o=i[1],s=o.split(/\[|,|\]/),n=e.attr("name"),l="",d="",u=!1,c=!1;t.isError=!1,t.showArrow=1==t.showArrow,0<t.maxErrorsPerField&&(c=!0);for(var f=T(e.closest("form, .validationEngineContainer")),v=0;v<s.length;v++)s[v]=s[v].toString().replace(" ",""),""===s[v]&&delete s[v];v=0;for(var p=0;v<s.length;v++){if(c&&p>=t.maxErrorsPerField){if(!u){var m=T.inArray("required",s);u=-1!=m&&v<=m}break}var g=void 0;switch(s[v]){case"required":u=!0,g=F._getErrorMessage(f,e,s[v],s,v,t,F._required);break;
85case"custom":g=F._getErrorMessage(f,e,s[v],s,v,t,F._custom);break;case"groupRequired":var h="["+t.validateAttribute+"*="+s[v+1]+"]",x=f.find(h).eq(0);x[0]!=e[0]&&(F._validateField(x,t,a),t.showArrow=!0),(g=F._getErrorMessage(f,e,s[v],s,v,t,F._groupRequired))&&(u=!0),t.showArrow=!1;break;case"ajax":(g=F._ajax(e,s,v,t))&&(d="load");break;case"minSize":g=F._getErrorMessage(f,e,s[v],s,v,t,F._minSize);break;case"maxSize":g=F._getErrorMessage(f,e,s[v],s,v,t,F._maxSize);break;case"min":g=F._getErrorMessage(f,e,s[v],s,v,t,F._min);break;case"max":g=F._getErrorMessage(f,e,s[v],s,v,t,F._max);break;case"past":g=F._getErrorMessage(f,e,s[v],s,v,t,F._past);break;case"future":g=F._getErrorMessage(f,e,s[v],s,v,t,F._future);break;case"dateRange":h="["+t.validateAttribute+"*="+s[v+1]+"]";t.firstOfGroup=f.find(h).eq(0),t.secondOfGroup=f.find(h).eq(1),(t.firstOfGroup[0].value||t.secondOfGroup[0].value)&&(g=F._getErrorMessage(f,e,s[v],s,v,t,F._dateRange)),g&&(u=!0),t.showArrow=!1;break;case"dateTimeRange":h="["+t.validateAttribute+"*="+s[v+1]+"]";t.firstOfGroup=f.find(h).eq(0),t.secondOfGroup=f.find(h).eq(1),(t.firstOfGroup[0].value||t.secondOfGroup[0].value)&&(g=F._getErrorMessage(f,e,s[v],s,v,t,F._dateTimeRange)),g&&(u=!0),t.showArrow=!1;break;case"maxCheckbox":e=T(f.find("input[name='"+n+"']")),g=F._getErrorMessage(f,e,s[v],s,v,t,F._maxCheckbox);break;case"minCheckbox":e=T(f.find("input[name='"+n+"']")),g=F._getErrorMessage(f,e,s[v],s,v,t,F._minCheckbox);break;case"equals":g=F._getErrorMessage(f,e,s[v],s,v,t,F._equals);break;case"funcCall":g=F._getErrorMessage(f,e,s[v],s,v,t,F._funcCall);break;case"creditCard":g=F._getErrorMessage(f,e,s[v],s,v,t,F._creditCard);break;case"condRequired":void 0!==(g=F._getErrorMessage(f,e,s[v],s,v,t,F._condRequired))&&(u=!0);break;case"funcCallRequired":void 0!==(g=F._getErrorMessage(f,e,s[v],s,v,t,F._funcCallRequired))&&(u=!0)}var _=!1;if("object"==typeof g)switch(g.status){case"_break":_=!0;break;case"_error":g=g.message;break;case"_error_no_prompt":return!0}if(0==v&&0==o.indexOf("funcCallRequired")&&void 0!==g&&(""!=l&&(l+="<br/>"),l+=g,p++,_=t.isError=!0),_)break;"string"==typeof g&&(""!=l&&(l+="<br/>"),l+=g,t.isError=!0,p++)}!u&&!e.val()&&e.val().length<1&&T.inArray("equals",s)<0&&(t.isError=!1);var C=e.prop("type"),b=e.data("promptPosition")||t.promptPosition;("radio"==C||"checkbox"==C)&&1<f.find("input[name='"+n+"']").length&&(e=T("inline"===b?f.find("input[name='"+n+"'][type!=hidden]:last"):f.find("input[name='"+n+"'][type!=hidden]:first")),t.showArrow=t.showArrowOnRadioAndCheckbox),e.is(":hidden")&&t.prettySelect&&(e=f.find("#"+t.usePrefix+F._jqSelector(e.attr("id"))+t.useSuffix)),t.isError&&t.showPrompts?F._showPrompt(e,l,d,!1,t):F._closePrompt(e),e.trigger("jqv.field.result",[e,t.isError,l]);var E=T.inArray(e[0],t.InvalidFields);return-1==E?t.isError&&t.InvalidFields.push(e[0]):t.isError||t.InvalidFields.splice(E,1),F._handleStatusCssClasses(e,t),t.isError&&t.onFieldFailure&&t.onFieldFailure(e),!t.isError&&t.onFieldSuccess&&t.onFieldSuccess(e),t.isError},_handleStatusCssClasses:function(e,t){t.addSuccessCssClassToField&&e.removeClass(t.addSuccessCssClassToField),t.addFailureCssClassToField&&e.removeClass(t.addFailureCssClassToField),t.addSuccessCssClassToField&&!t.isError&&e.addClass(t.addSuccessCssClassToField),t.addFailureCssClassToField&&t.isError&&e.addClass(t.addFailureCssClassToField)},_getErrorMessage:function(e,t,a,r,i,o,s){var n=jQuery.inArray(a,r);"custom"!==a&&"funcCall"!==a&&"funcCallRequired"!==a||(a=a+"["+r[n+1]+"]",delete r[n]);var l,d=a,u=(t.attr("data-validation-engine")?t.attr("data-validation-engine"):t.attr("class")).split(" ");if(null!=(l="future"==a||"past"==a||"maxCheckbox"==a||"minCheckbox"==a?s(e,t,r,i,o):s(t,r,i,o))){var c=F._getCustomErrorMessage(T(t),u,d,o);c&&(l=c)}return l},_getCustomErrorMessage:function(e,t,a,r){var i=!1,o=/^custom\[.*\]$/.test(a)?F._validityProp.custom:F._validityProp[a];if(null!=o&&null!=(i=e.attr("data-errormessage-"+o)))return i;if(null!=(i=e.attr("data-errormessage")))return i;var s="#"+e.attr("id");if(void 0!==r.custom_error_messages[s]&&void 0!==r.custom_error_messages[s][a])i=r.custom_error_messages[s][a].message;else if(0<t.length)for(var n=0;n<t.length&&0<t.length;n++){var l="."+t[n];if(void 0!==r.custom_error_messages[l]&&void 0!==r.custom_error_messages[l][a]){i=r.custom_error_messages[l][a].message;break}}return i||void 0===r.custom_error_messages[a]||void 0===r.custom_error_messages[a].message||(i=r.custom_error_messages[a].message),i},_validityProp:{required:"value-missing",custom:"custom-error",groupRequired:"value-missing",ajax:"custom-error",minSize:"range-underflow",maxSize:"range-overflow",min:"range-underflow",max:"range-overflow",past:"type-mismatch",future:"type-mismatch",dateRange:"type-mismatch",dateTimeRange:"type-mismatch",maxCheckbox:"range-overflow",minCheckbox:"range-underflow",equals:"pattern-mismatch",funcCall:"custom-error",funcCallRequired:"custom-error",creditCard:"pattern-mismatch",condRequired:"value-missing"},_required:function(e,t,a,r,i){switch(e.prop("type")){case"radio":case"checkbox":if(i){if(!e.prop("checked"))return r.allrules[t[a]].alertTextCheckboxMultiple;break}var o=e.closest("form, .validationEngineContainer"),s=e.attr("name");if(0==o.find("input[name='"+s+"']:checked").length)return 1==o.find("input[name='"+s+"']:visible").length?r.allrules[t[a]].alertTextCheckboxe:r.allrules[t[a]].alertTextCheckboxMultiple;break;case"text":case"password":case"textarea":case"file":case"select-one":case"select-multiple":default:var n=T.trim(e.val()),l=T.trim(e.attr("data-validation-placeholder")),d=T.trim(e.attr("placeholder"));if(!n||l&&n==l||d&&n==d)return r.allrules[t[a]].alertText}},_groupRequired:function(e,t,a,r){var i="["+r.validateAttribute+"*="+t[a+1]+"]",o=!1;if(e.closest("form, .validationEngineContainer").find(i).each(function(){if(!F._required(T(this),t,a,r))return!(o=!0)}),!o)return r.allrules[t[a]].alertText},_custom:function(e,t,a,r){var i,o=t[a+1],s=r.allrules[o];if(s)if(s.regex){var n=s.regex;if(!n)return void alert("jqv:custom regex not found - "+o);if(!new RegExp(n).test(e.val()))return r.allrules[o].alertText}else{if(!s.func)return void alert("jqv:custom type not allowed "+o);if("function"!=typeof(i=s.func))return void alert("jqv:custom parameter 'function' is no function - "+o);if(!i(e,t,a,r))return r.allrules[o].alertText}else alert("jqv:custom rule not found - "+o)},_funcCall:function(e,t,a,r){var i,o=t[a+1];if(-1<o.indexOf(".")){for(var s=o.split("."),n=window;s.length;)n=n[s.shift()];i=n}else i=window[o]||r.customFunctions[o];if("function"==typeof i)return i(e,t,a,r)},_funcCallRequired:function(e,t,a,r){return F._funcCall(e,t,a,r)},_equals:function(e,t,a,r){var i=t[a+1];if(e.val()!=T("#"+i).val())return r.allrules.equals.alertText},_maxSize:function(e,t,a,r){var i=t[a+1];if(i<e.val().length){var o=r.allrules.maxSize;return o.alertText+i+o.alertText2}},_minSize:function(e,t,a,r){var i=t[a+1];if(e.val().length<i){var o=r.allrules.minSize;return o.alertText+i+o.alertText2}},_min:function(e,t,a,r){var i=parseFloat(t[a+1]);if(parseFloat(e.val())<i){var o=r.allrules.min;return o.alertText2?o.alertText+i+o.alertText2:o.alertText+i}},_max:function(e,t,a,r){var i=parseFloat(t[a+1]);
85if(i<parseFloat(e.val())){var o=r.allrules.max;return o.alertText2?o.alertText+i+o.alertText2:o.alertText+i}},_past:function(e,t,a,r,i){var o,s=a[r+1],n=T(e.find("*[name='"+s.replace(/^#+/,"")+"']"));if("now"==s.toLowerCase())o=new Date;else if(null!=n.val()){if(n.is(":disabled"))return;o=F._parseDate(n.val())}else o=F._parseDate(s);if(o<F._parseDate(t.val())){var l=i.allrules.past;return l.alertText2?l.alertText+F._dateToString(o)+l.alertText2:l.alertText+F._dateToString(o)}},_future:function(e,t,a,r,i){var o,s=a[r+1],n=T(e.find("*[name='"+s.replace(/^#+/,"")+"']"));if("now"==s.toLowerCase())o=new Date;else if(null!=n.val()){if(n.is(":disabled"))return;o=F._parseDate(n.val())}else o=F._parseDate(s);if(F._parseDate(t.val())<o){var l=i.allrules.future;return l.alertText2?l.alertText+F._dateToString(o)+l.alertText2:l.alertText+F._dateToString(o)}},_isDate:function(e){return new RegExp(/^\d{4}[\/\-](0?[1-9]|1[012])[\/\-](0?[1-9]|[12][0-9]|3[01])$|^(?:(?:(?:0?[13578]|1[02])(\/|-)31)|(?:(?:0?[1,3-9]|1[0-2])(\/|-)(?:29|30)))(\/|-)(?:[1-9]\d\d\d|\d[1-9]\d\d|\d\d[1-9]\d|\d\d\d[1-9])$|^(?:(?:0?[1-9]|1[0-2])(\/|-)(?:0?[1-9]|1\d|2[0-8]))(\/|-)(?:[1-9]\d\d\d|\d[1-9]\d\d|\d\d[1-9]\d|\d\d\d[1-9])$|^(0?2(\/|-)29)(\/|-)(?:(?:0[48]00|[13579][26]00|[2468][048]00)|(?:\d\d)?(?:0[48]|[2468][048]|[13579][26]))$/).test(e)},_isDateTime:function(e){return new RegExp(/^\d{4}[\/\-](0?[1-9]|1[012])[\/\-](0?[1-9]|[12][0-9]|3[01])\s+(1[012]|0?[1-9]){1}:(0?[1-5]|[0-6][0-9]){1}:(0?[0-6]|[0-6][0-9]){1}\s+(am|pm|AM|PM){1}$|^(?:(?:(?:0?[13578]|1[02])(\/|-)31)|(?:(?:0?[1,3-9]|1[0-2])(\/|-)(?:29|30)))(\/|-)(?:[1-9]\d\d\d|\d[1-9]\d\d|\d\d[1-9]\d|\d\d\d[1-9])$|^((1[012]|0?[1-9]){1}\/(0?[1-9]|[12][0-9]|3[01]){1}\/\d{2,4}\s+(1[012]|0?[1-9]){1}:(0?[1-5]|[0-6][0-9]){1}:(0?[0-6]|[0-6][0-9]){1}\s+(am|pm|AM|PM){1})$/).test(e)},_dateCompare:function(e,t){return new Date(e.toString())<new Date(t.toString())},_dateRange:function(e,t,a,r){return!r.firstOfGroup[0].value&&r.secondOfGroup[0].value||r.firstOfGroup[0].value&&!r.secondOfGroup[0].value?r.allrules[t[a]].alertText+r.allrules[t[a]].alertText2:F._isDate(r.firstOfGroup[0].value)&&F._isDate(r.secondOfGroup[0].value)&&F._dateCompare(r.firstOfGroup[0].value,r.secondOfGroup[0].value)?void 0:r.allrules[t[a]].alertText+r.allrules[t[a]].alertText2},_dateTimeRange:function(e,t,a,r){return!r.firstOfGroup[0].value&&r.secondOfGroup[0].value||r.firstOfGroup[0].value&&!r.secondOfGroup[0].value?r.allrules[t[a]].alertText+r.allrules[t[a]].alertText2:F._isDateTime(r.firstOfGroup[0].value)&&F._isDateTime(r.secondOfGroup[0].value)&&F._dateCompare(r.firstOfGroup[0].value,r.secondOfGroup[0].value)?void 0:r.allrules[t[a]].alertText+r.allrules[t[a]].alertText2},_maxCheckbox:function(e,t,a,r,i){var o=a[r+1],s=t.attr("name");if(o<e.find("input[name='"+s+"']:checked").length)return i.showArrow=!1,i.allrules.maxCheckbox.alertText2?i.allrules.maxCheckbox.alertText+" "+o+" "+i.allrules.maxCheckbox.alertText2:i.allrules.maxCheckbox.alertText},_minCheckbox:function(e,t,a,r,i){var o=a[r+1],s=t.attr("name");if(e.find("input[name='"+s+"']:checked").length<o)return i.showArrow=!1,i.allrules.minCheckbox.alertText+" "+o+" "+i.allrules.minCheckbox.alertText2},_creditCard:function(e,t,a,r){var i=!1,o=e.val().replace(/ +/g,"").replace(/-+/g,""),s=o.length;if(14<=s&&s<=16&&0<parseInt(o)){for(var n,l=0,d=(a=s-1,1),u=new String;n=parseInt(o.charAt(a)),u+=d++%2==0?2*n:n,0<=--a;);for(a=0;a<u.length;a++)l+=parseInt(u.charAt(a));i=l%10==0}if(!i)return r.allrules.creditCard.alertText},_ajax:function(s,e,t,n){var a=e[t+1],l=n.allrules[a],r=l.extraData,i=l.extraDataDynamic,o={fieldId:s.attr("id"),fieldValue:s.val()};if("object"==typeof r)T.extend(o,r);else if("string"==typeof r){var d=r.split("&");for(t=0;t<d.length;t++){var u=d[t].split("=");u[0]&&u[0]&&(o[u[0]]=u[1])}}if(i){var c=String(i).split(",");for(t=0;t<c.length;t++){var f=c[t];if(T(f).length){var v=s.closest("form, .validationEngineContainer").find(f).val();f.replace("#",""),escape(v);o[f.replace("#","")]=v}}}if("field"==n.eventTrigger&&delete n.ajaxValidCache[s.attr("id")],!n.isError&&!F._checkAjaxFieldStatus(s.attr("id"),n))return T.ajax({type:n.ajaxFormValidationMethod,url:l.url,cache:!1,dataType:"json",data:o,field:s,rule:l,methods:F,options:n,beforeSend:function(){},error:function(e,t){n.onFailure?n.onFailure(e,t):F._ajaxError(e,t)},success:function(e){var t=e[0],a=T("#"+t).eq(0);if(1==a.length){var r=e[1],i=e[2];if(r){if(n.ajaxValidCache[t]=!0,i){if(n.allrules[i])(o=n.allrules[i].alertTextOk)&&(i=o)}else i=l.alertTextOk;n.showPrompts&&(i?F._showPrompt(a,i,"pass",!0,n):F._closePrompt(a)),"submit"==n.eventTrigger&&s.closest("form").submit()}else{var o;if(n.ajaxValidCache[t]=!1,n.isError=!0,i){if(n.allrules[i])(o=n.allrules[i].alertText)&&(i=o)}else i=l.alertText;n.showPrompts&&F._showPrompt(a,i,"",!0,n)}}a.trigger("jqv.field.result",[a,n.isError,i])}}),l.alertTextLoad},_ajaxError:function(e,t){0==e.status&&null==t?alert("The page is not served from a server! ajax call failed"):"undefined"!=typeof console&&console.log("Ajax error: "+e.status+" "+t)},_dateToString:function(e){return e.getFullYear()+"-"+(e.getMonth()+1)+"-"+e.getDate()},_parseDate:function(e){var t=e.split("-");return t==e&&(t=e.split("/")),t==e?(t=e.split("."),new Date(t[2],t[1]-1,t[0])):new Date(t[0],t[1]-1,t[2])},_showPrompt:function(e,t,a,r,i,o){e.data("jqv-prompt-at")instanceof jQuery?e=e.data("jqv-prompt-at"):e.data("jqv-prompt-at")&&(e=T(e.data("jqv-prompt-at")));var s=F._getPrompt(e);o&&(s=!1),T.trim(t)&&(s?F._updatePrompt(e,s,t,a,r,i):F._buildPrompt(e,t,a,r,i))},_buildPrompt:function(e,t,a,r,i){var o=T("<div>");switch(o.addClass(F._getClassName(e.attr("id"))+"formError"),o.addClass("parentForm"+F._getClassName(e.closest("form, .validationEngineContainer").attr("id"))),o.addClass("formError"),a){case"pass":o.addClass("greenPopup");break;case"load":o.addClass("blackPopup")}r&&o.addClass("ajaxed");T("<div>").addClass("formErrorContent").html(t).appendTo(o);var s=e.data("promptPosition")||i.promptPosition;if(i.showArrow){var n=T("<div>").addClass("formErrorArrow");if("string"==typeof s)-1!=(u=s.indexOf(":"))&&(s=s.substring(0,u));switch(s){case"bottomLeft":case"bottomRight":o.find(".formErrorContent").before(n),n.addClass("formErrorArrowBottom").html('<div class="line1">\x3c!-- --\x3e</div><div class="line2">\x3c!-- --\x3e</div><div class="line3">\x3c!-- --\x3e</div><div class="line4">\x3c!-- --\x3e</div><div class="line5">\x3c!-- --\x3e</div><div class="line6">\x3c!-- --\x3e</div><div class="line7">\x3c!-- --\x3e</div><div class="line8">\x3c!-- --\x3e</div><div class="line9">\x3c!-- --\x3e</div><div class="line10">\x3c!-- --\x3e</div>');break;case"topLeft":case"topRight":n.html('<div class="line10">\x3c!-- --\x3e</div><div class="line9">\x3c!-- --\x3e</div><div class="line8">\x3c!-- --\x3e</div><div class="line7">\x3c!-- --\x3e</div><div class="line6">\x3c!-- --\x3e</div><div class="line5">\x3c!-- --\x3e</div><div class="line4">\x3c!-- --\x3e</div><div class="line3">\x3c!-- --\x3e</div><div class="line2">\x3c!-- --\x3e</div><div class="line1">\x3c!-- --\x3e</div>'),o.append(n)}}i.addPromptClass&&o.addClass(i.addPromptClass);var l=e.attr("data-required-class");if(void 0!==l)o.addClass(l);else if(i.prettySelect&&T("#"+e.attr("id")).next().is("select")){var d=T("#"+e.attr("id").substr(i.usePrefix.length).substring(i.useSuffix.length)).attr("data-required-class");void 0!==d&&o.addClass(d)}o.css({opacity:0}
85),"inline"===s?(o.addClass("inline"),void 0!==e.attr("data-prompt-target")&&0<T("#"+e.attr("data-prompt-target")).length?o.appendTo(T("#"+e.attr("data-prompt-target"))):e.after(o)):e.before(o);var u=F._calculatePosition(e,o,i);return T("body").hasClass("rtl")?o.css({position:"inline"===s?"relative":"absolute",top:u.callerTopPosition,left:"initial",right:u.callerleftPosition,marginTop:u.marginTopSize,opacity:0}).data("callerField",e):o.css({position:"inline"===s?"relative":"absolute",top:u.callerTopPosition,left:u.callerleftPosition,right:"initial",marginTop:u.marginTopSize,opacity:0}).data("callerField",e),i.autoHidePrompt&&setTimeout(function(){o.animate({opacity:0},function(){o.closest(".formError").remove()})},i.autoHideDelay),o.animate({opacity:.87})},_updatePrompt:function(e,t,a,r,i,o,s){if(t){void 0!==r&&("pass"==r?t.addClass("greenPopup"):t.removeClass("greenPopup"),"load"==r?t.addClass("blackPopup"):t.removeClass("blackPopup")),i?t.addClass("ajaxed"):t.removeClass("ajaxed"),t.find(".formErrorContent").html(a);var n=F._calculatePosition(e,t,o);if(T("body").hasClass("rtl"))var l={top:n.callerTopPosition,left:"initial",right:n.callerleftPosition,marginTop:n.marginTopSize,opacity:.87};else l={top:n.callerTopPosition,left:n.callerleftPosition,right:"initial",marginTop:n.marginTopSize,opacity:.87};t.css({opacity:0,display:"block"}),s?t.css(l):t.animate(l)}},_closePrompt:function(e){var t=F._getPrompt(e);t&&t.fadeTo("fast",0,function(){t.closest(".formError").remove()})},closePrompt:function(e){return F._closePrompt(e)},_getPrompt:function(e){var t=T(e).closest("form, .validationEngineContainer").attr("id"),a=F._getClassName(e.attr("id"))+"formError",r=T("."+F._escapeExpression(a)+".parentForm"+F._getClassName(t))[0];if(r)return T(r)},_escapeExpression:function(e){return e.replace(/([#;&,\.\+\*\~':"\!\^$\[\]\(\)=>\|])/g,"\\$1")},isRTL:function(e){var t=T(document),a=T("body"),r=e&&e.hasClass("rtl")||e&&"rtl"===(e.attr("dir")||"").toLowerCase()||t.hasClass("rtl")||"rtl"===(t.attr("dir")||"").toLowerCase()||a.hasClass("rtl")||"rtl"===(a.attr("dir")||"").toLowerCase();return Boolean(r)},_calculatePosition:function(e,t,a){var r,i,o,s=e.width(),n=e.position().left,l=e.position().top;e.height();r=i=0,o=-t.height();var d=e.data("promptPosition")||a.promptPosition,u="",c="",f=0,v=0;switch("string"==typeof d&&-1!=d.indexOf(":")&&(u=d.substring(d.indexOf(":")+1),d=d.substring(0,d.indexOf(":")),-1!=u.indexOf(",")&&(c=u.substring(u.indexOf(",")+1),u=u.substring(0,u.indexOf(",")),v=parseInt(c),isNaN(v)&&(v=0)),f=parseInt(u),isNaN(u)&&(u=0)),d){default:case"topRight":i+=n+s-27,r+=l;break;case"topLeft":r+=l,i+=n;break;case"centerRight":r=l+4,o=0,i=n+e.outerWidth(!0)+5;break;case"centerLeft":i=n-(t.width()+2),r=l+4,o=0;break;case"bottomLeft":r=l+e.height()+5,o=0,i=n;break;case"bottomRight":i=n+s-27,r=l+e.height()+5,o=0;break;case"inline":o=r=i=0}return{callerTopPosition:(r+=v)+"px",callerleftPosition:(i+=f)+"px",marginTopSize:o+"px"}},_saveOptions:function(e,t){if(T.validationEngineLanguage)var a=T.validationEngineLanguage.allRules;else T.error("jQuery.validationEngine rules are not loaded, plz add localization files to the page");T.validationEngine.defaults.allrules=a;var r=T.extend(!0,{},T.validationEngine.defaults,t);return e.data("jqv",r),r},_getClassName:function(e){if(e)return e.replace(/:/g,"_").replace(/\./g,"_")},_jqSelector:function(e){return e.replace(/([;&,\.\+\*\~':"\!\^#$%@\[\]\(\)=>\|])/g,"\\$1")},_condRequired:function(e,t,a,r){var i,o;for(i=a+1;i<t.length;i++)if((o=jQuery("#"+t[i]).first()).length&&null==F._required(o,["required"],0,r,!0))return F._required(e,["required"],0,r)},_submitButtonClick:function(e){var t=T(this);t.closest("form, .validationEngineContainer").data("jqv_submitButton",t.attr("id"))}};T.fn.validationEngine=function(e){var t=T(this);return t[0]?"string"==typeof e&&"_"!=e.charAt(0)&&F[e]?("showPrompt"!=e&&"hide"!=e&&"hideAll"!=e&&F.init.apply(t),F[e].apply(t,Array.prototype.slice.call(arguments,1))):"object"!=typeof e&&e?void T.error("Method "+e+" does not exist in jQuery.validationEngine"):(F.init.apply(t,arguments),F.attach.apply(t)):t},T.validationEngine={fieldIdCounter:0,defaults:{validationEventTrigger:"blur",scroll:!0,focusFirstField:!0,showPrompts:!0,validateNonVisibleFields:!1,ignoreFieldsWithClass:"ignoreMe",promptPosition:"topRight",bindMethod:"bind",inlineAjax:!1,ajaxFormValidation:!1,ajaxFormValidationURL:!1,ajaxFormValidationMethod:"get",onAjaxFormComplete:T.noop,onBeforeAjaxFormValidation:T.noop,onValidationComplete:!1,doNotShowAllErrosOnSubmit:!1,custom_error_messages:{},binded:!0,notEmpty:!1,showArrow:!0,showArrowOnRadioAndCheckbox:!1,isError:!1,maxErrorsPerField:!1,ajaxValidCache:{},autoPositionUpdate:!1,InvalidFields:[],onFieldSuccess:!1,onFieldFailure:!1,onSuccess:!1,onFailure:!1,validateAttribute:"class",addSuccessCssClassToField:"",addFailureCssClassToField:"",autoHidePrompt:!1,autoHideDelay:1e4,fadeDuration:300,prettySelect:!1,addPromptClass:"",usePrefix:"",useSuffix:"",showOneMessage:!1}},T(function(){T.validationEngine.defaults.promptPosition=F.isRTL()?"topLeft":"topRight"})}(jQuery);; 86/* AUTOGENERATED: custom.validationEngine.js */ 87(function(a){a.validationEngineLanguage.allRules.onlySmallLetterNumberUnder={regex:/^[a-z][0-9a-z_]+$/,alertText:"* Only small letter, digits and undescore sign are allowed"};a.validationEngineLanguage.allRules.modifier={regex:/^[\-\+]{1}([0-9]+)([\.,]([0-9]+))?([%]{1})?$/,alertText:"* Wrong format"};a.validationEngineLanguage.allRules.numberWithInfinity={regex:/^[\-\+]?((([0-9]{1,3})([,][0-9]{3})*)|([0-9]+)|\u221e)?([\.]([0-9]+))?$/,alertText:"* Wrong format"};a.validationEngineLanguage.allRules.integerWithInfinity= 88 {regex:/^[\-\+]?(\d+|\u221e)$/,alertText:"* Not a valid integer"};a.validationEngineLanguage.allRules.url={regex:/^[a-z](?:[-a-z0-9\+\.])*:(?:\/\/(?:(?:%[0-9a-f][0-9a-f]|[-a-z0-9\._~\xA0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF!\$&'\(\)\*\+,;
88=:])*@)?(?:\[(?:(?:(?:[0-9a-f]{1,4}:){6}(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:[0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])(?:\.(?:[0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])){3})|::(?:[0-9a-f]{1,4}:){5}(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:[0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])(?:\.(?:[0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])){3})|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:[0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])(?:\.(?:[0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])){3})|(?:[0-9a-f]{1,4}:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:[0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])(?:\.(?:[0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])){3})|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:[0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])(?:\.(?:[0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])){3})|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:[0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])(?:\.(?:[0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])){3})|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:[0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])(?:\.(?:[0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])){3})|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|v[0-9a-f]+[-a-z0-9\._~!\$&'\(\)\*\+,;=:]+)\]|(?:[0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])(?:\.(?:[0-9]|[1-9][0-9]|1[0-9][0-9]|2[0-4][0-9]|25[0-5])){3}|(?:%[0-9a-f][0-9a-f]|[-a-z0-9\._~\xA0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF!\$&'\(\)\*\+,;=@])*)(?::[0-9]*)?(?:\/(?:(?:%[0-9a-f][0-9a-f]|[-a-z0-9\._~\xA0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF!\$&'\(\)\*\+,;=:@]))*)*|\/(?:(?:(?:(?:%[0-9a-f][0-9a-f]|[-a-z0-9\._~\xA0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF!\$&'\(\)\*\+,;=:@]))+)(?:\/(?:(?:%[0-9a-f][0-9a-f]|[-a-z0-9\._~\xA0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF!\$&'\(\)\*\+,;=:@]))*)*)?|(?:(?:(?:%[0-9a-f][0-9a-f]|[-a-z0-9\._~\xA0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF!\$&'\(\)\*\+,;=:@]))+)(?:\/(?:(?:%[0-9a-f][0-9a-f]|[-a-z0-9\._~\xA0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF!\$&'\(\)\*\+,;=:@]))*)*|(?!(?:%[0-9a-f][0-9a-f]|[-a-z0-9\._~\xA0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF!\$&'\(\)\*\+,;=:@])))(?:\?(?:(?:%[0-9a-f][0-9a-f]|[-a-z0-9\._~\xA0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF!\$&'\(\)\*\+,;=:@])|[\/\?])*)?$/i, 89 alertText:"* Invalid URL"};a.validationEngineLanguage.allRules.phone={regex:/^([\+]?[\d]{1,3})?(?:\s*[ \(]([\d]{2,6})[ \)])?\s*([\d \.\-\/]{3,20})\s*(?:x|ext|extension|,)?\s*([\d]{1,4})?$/,alertText:"* Wrong number format"};a.validationEngineLanguage.allRules.email={func:function(field,rules,i,options){field.val(a.trim(field.val()));var customRule=rules[i+1];var rule=options.allrules[customRule];var pattern=new RegExp(rule.regex_old);return pattern.test(field.val())}
vendor: 4,183 bytes, lines 89-129
89,regex:null,regex_old:a.validationEngineLanguage.allRules.email.regex,alertText:a.validationEngineLanguage.allRules.email.alertText}})(jQuery);; 90/* AUTOGENERATED: jquery.mousewheel.min.js */ 91/*! 92 * jQuery Mousewheel 3.1.13 93 * 94 * Copyright 2015 jQuery Foundation and other contributors 95 * Released under the MIT license. 96 * http://jquery.org/license 97 */ 98!function(a){"function"==typeof define&&define.amd?define(["jquery"],a):"object"==typeof exports?module.exports=a:a(jQuery)}(function(a){function b(b){var g=b||window.event,h=i.call(arguments,1),j=0,l=0,m=0,n=0,o=0,p=0;if(b=a.event.fix(g),b.type="mousewheel","detail"in g&&(m=-1*g.detail),"wheelDelta"in g&&(m=g.wheelDelta),"wheelDeltaY"in g&&(m=g.wheelDeltaY),"wheelDeltaX"in g&&(l=-1*g.wheelDeltaX),"axis"in g&&g.axis===g.HORIZONTAL_AXIS&&(l=-1*m,m=0),j=0===m?l:m,"deltaY"in g&&(m=-1*g.deltaY,j=m),"deltaX"in g&&(l=g.deltaX,0===m&&(j=-1*l)),0!==m||0!==l){if(1===g.deltaMode){var q=a.data(this,"mousewheel-line-height");j*=q,m*=q,l*=q}else if(2===g.deltaMode){var r=a.data(this,"mousewheel-page-height");j*=r,m*=r,l*=r}if(n=Math.max(Math.abs(m),Math.abs(l)),(!f||f>n)&&(f=n,d(g,n)&&(f/=40)),d(g,n)&&(j/=40,l/=40,m/=40),j=Math[j>=1?"floor":"ceil"](j/f),l=Math[l>=1?"floor":"ceil"](l/f),m=Math[m>=1?"floor":"ceil"](m/f),k.settings.normalizeOffset&&this.getBoundingClientRect){var s=this.getBoundingClientRect();o=b.clientX-s.left,p=b.clientY-s.top}return b.deltaX=l,b.deltaY=m,b.deltaFactor=f,b.offsetX=o,b.offsetY=p,b.deltaMode=0,h.unshift(b,j,l,m),e&&clearTimeout(e),e=setTimeout(c,200),(a.event.dispatch||a.event.handle).apply(this,h)}}function c(){f=null}function d(a,b){return k.settings.adjustOldDeltas&&"mousewheel"===a.type&&b%120===0}var e,f,g=["wheel","mousewheel","DOMMouseScroll","MozMousePixelScroll"],h="onwheel"in document||document.documentMode>=9?["wheel"]:["mousewheel","DomMouseScroll","MozMousePixelScroll"],i=Array.prototype.slice;if(a.event.fixHooks)for(var j=g.length;j;)a.event.fixHooks[g[--j]]=a.event.mouseHooks;var k=a.event.special.mousewheel={version:"3.1.12",setup:function(){if(this.addEventListener)for(var c=h.length;c;)this.addEventListener(h[--c],b,!1);else this.onmousewheel=b;a.data(this,"mousewheel-line-height",k.getLineHeight(this)),a.data(this,"mousewheel-page-height",k.getPageHeight(this))},teardown:function(){if(this.removeEventListener)for(var c=h.length;c;)this.removeEventListener(h[--c],b,!1);else this.onmousewheel=null;a.removeData(this,"mousewheel-line-height"),a.removeData(this,"mousewheel-page-height")},getLineHeight:function(b){var c=a(b),d=c["offsetParent"in a.fn?"offsetParent":"parent"]();return d.length||(d=a("body")),parseInt(d.css("fontSize"),10)||parseInt(c.css("fontSize"),10)||16},getPageHeight:function(b){return a(b).height()},settings:{adjustOldDeltas:!0,normalizeOffset:!0}};a.fn.extend({mousewheel:function(a){return a?this.bind("mousewheel",a):this.trigger("mousewheel")},unmousewheel:function(a){return this.unbind("mousewheel",a)}})});; 99/* AUTOGENERATED: regex-mask-plugin.js */ 100/* vim: set ts=2 sw=2 sts=2 et: */ 101 102/** 103 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 104 * See https://www.x-cart.com/license-agreement.html for license details. 105 */ 106 107(function ($){ 108 $.fn.regexMask = function (mask) { 109 if (!mask) { 110 throw 'mandatory mask argument missing'; 111 } else if (mask == 'float-ptbr') { 112 mask = /^((\d{1,3}(\.\d{3})*(((\.\d{0,2}))|((\,\d*)?)))|(\d+(\,\d*)?))$/; 113 } else if (mask == 'float-enus') { 114 mask = /^((\d{1,3}(\,\d{3})*(((\,\d{0,2}))|((\.\d*)?)))|(\d+(\.\d*)?))$/; 115 } else if (mask == 'integer') { 116 mask = /^\d+$/; 117 } else { 118 try { 119 mask.test(""); 120 } catch(e) { 121 throw 'mask regex need to support test method'; 122 } 123 } 124 $(this).keypress(function (event) { 125 if (!event.charCode) return true; 126 var part1 = this.value.substring(0,this.selectionStart); 127 var part2 = this.value.substring(this.selectionEnd,this.value.length); 128 if (!mask.test(part1 + String.fromCharCode(event.charCode) + part2)) 129 return false;
130 }); 131 }; 132})(jQuery);; 133/* AUTOGENERATED: common.js */ 134/* vim: set ts=2 sw=2 sts=2 et: */ 135 136/** 137 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 138 * See https://www.x-cart.com/license-agreement.html for license details. 139 */ 140 141var URLHandler = { 142 143 excluded: { 144 'base': true 145 }, 146 baseURLPart: '', 147 querySeparator: '?', 148 argSeparator: '&', 149 nameValueSeparator: '=', 150 151 // Return query param 152 getParamValue: function (name, params) { 153 return name 154 + this.nameValueSeparator 155 + encodeURIComponent(typeof params[name] === 'boolean' ? Number(params[name]) : params[name]); 156 }, 157 158 // Get param value for the remained params 159 getQueryParamValue: function (name, params) { 160 return URLHandler.getParamValue(name, params); 161 }, 162 163 // Build HTTP query 164 implodeParams: function (params, method) { 165 result = ''; 166 isStarted = false; 167 168 for (x in params) { 169 170 if (isStarted) { 171 result += this.argSeparator; 172 } else { 173 isStarted = true; 174 } 175 176 result += method(x, params); 177 } 178 179 return result; 180 }, 181 182 // Implode remained params 183 implodeQueryParams: function (params) { 184 return this.implodeParams(params, this.getQueryParamValue); 185 }, 186 187 // Unset some params 188 clearParams: function (params, excluded) { 189 // clone object 190 var result = {}; 191 192 for (key in params) { 193 if (params[key] !== undefined && params[key] !== null && !(key in excluded)) { 194 result[key] = params[key]; 195 } 196 } 197 198 return result; 199 }, 200 201 preprocessParams: function (params) { 202 return this.clearParams(params, this.excluded); 203 }, 204 205 // Get base url 206 buildBaseUrl: function (params) { 207 var base = params.base || this.baseURLPart; 208 209 if (xliteConfig.clean_url && base === xliteConfig.clean_urls_base) { 210 return ''; 211 } 212 213 return params.base || this.baseURLPart; 214 }, 215 216 // Compose query params 217 buildQueryParams: function (params) { 218 return this.querySeparator + this.implodeQueryParams(this.preprocessParams(params)); 219 }, 220 221 getBuildURLPrefix: function (params) { 222 return xliteConfig.ajax_prefix && !(params && params.base === xliteConfig.admin_script) 223 ? (xliteConfig.ajax_prefix + '/') 224 : ''; 225 }, 226 227 // Compose URL 228 buildURL: function (params) { 229 return this.getBuildURLPrefix(params) + this.buildBaseUrl(params) + this.buildQueryParams(params); 230 } 231}; 232 233// Dialog 234 235// Abstract open dialog 236function openDialog(selector, additionalOptions) { 237 additionalOptions = additionalOptions || {}; 238 239 var box = jQuery(selector); 240 241 _.each( 242 ['h2', 'h1'], 243 function (tag) { 244 var elm = box.find(tag); 245 if ('undefined' == typeof(additionalOptions.title) || !additionalOptions.title) { 246 additionalOptions.title = elm.html(); 247 } 248 elm.remove(); 249 } 250 ); 251 252 popup.isLoading = false; 253 return popup.open(jQuery(selector), additionalOptions); 254} 255 256// Loadable dialog 257function loadDialog(url, dialogOptions, callback, link, $this) { 258 openWaitBar(); 259 260 var selector = 'tmp-dialog-' + (new Date()).getTime() + '-' + jQuery(link).attr('class').toString().replace(/[ \.]/g, '-'); 261 262 xcart.get( 263 url, 264 function (xhr, status, data) { 265 if (data) { 266 var div = jQuery(document.body.appendChild(document.createElement('div'))).hide(); 267 268 var uuid = _.uniqueId(); 269 270 xcart.bind(['resources.ready', 'resources.empty'], _.bind( 271 function (event, args) { 272 if (args.uuid === uuid) { 273 if (1 == div.get(0).childNodes.length) { 274 div = jQuery(div.get(0).childNodes[0]); 275 } 276 277 // Specific CSS class to manage this specific popup window 278 div.addClass(selector); 279 280 // Every popup window (even hidden one) has this one defined CSS class. 281 // You should use this selector to manage any popup window entry. 282 div.addClass('popup-window-entry'); 283 284 openDialog('.' + selector, dialogOptions); 285 286 if (callback) { 287 callback.call($this, '.' + selector, link); 288 } 289 } 290 }, 291 this) 292 ); 293 294 div.html(jQuery.trim(data)); 295 296 xcart.parsePreloadedLabels(div, uuid); 297 xcart.parseResources(div, uuid); 298 } 299 } 300 ); 301 302 return '.' + selector; 303} 304 305// Load dialog by link 306function loadDialogByLink(link, url, options, callback, $this) { 307 if (!link.linkedDialog || 0 == jQuery(link.linkedDialog).length || jQuery(link).hasClass('always-reload')) { 308 link.linkedDialog = loadDialog(url, options, callback, link, $this); 309 310 } else { 311 openDialog(link.linkedDialog, options, callback); 312 } 313} 314 315function openWaitBar() { 316 popup.openAsWait(); 317} 318 319function closeWaitBar() { 320 popup.close(); 321} 322 323// Check for the AJAX support 324function hasAJAXSupport() { 325 if (typeof(window.ajaxSupport) == 'undefined') { 326 window.ajaxSupport = false;
327 try { 328 329 var xhr = window.ActiveXObject ? new ActiveXObject('Microsoft.XMLHTTP') : new XMLHttpRequest(); 330 window.ajaxSupport = xhr ? true : false; 331 332 } catch (e) { 333 } 334 } 335 336 return window.ajaxSupport; 337} 338 339// Check list of checkboxes 340function checkMarks(form, reg, lbl) { 341 var is_exist = false; 342 343 if (!form || form.elements.length == 0) 344 return true; 345 346 for (var x = 0; x < form.elements.length; x++) { 347 if ( 348 form.elements[x].type == 'checkbox' 349 && form.elements[x].name.search(reg) == 0 350 && !form.elements[x].disabled 351 ) { 352 is_exist = true; 353 354 if (form.elements[x].checked) 355 return true; 356 } 357 } 358 359 if (!is_exist) 360 return true; 361 362 if (lbl) { 363 alert(lbl); 364 365 } else if (lbl_no_items_have_been_selected) { 366 alert(lbl_no_items_have_been_selected); 367 368 } 369 370 return false; 371} 372 373/* 374 Parameters: 375 checkboxes - array of tag names 376 checkboxes_form - form name with these checkboxes 377 */ 378function change_all(flag, formname, arr) { 379 if (!formname) 380 formname = checkboxes_form; 381 if (!arr) 382 arr = checkboxes; 383 if (!document.forms[formname] || arr.length == 0) 384 return false; 385 for (var x = 0; x < arr.length; x++) { 386 if (arr[x] != '' && document.forms[formname].elements[arr[x]] && !document.forms[formname].elements[arr[x]].disabled) { 387 document.forms[formname].elements[arr[x]].checked = flag; 388 if (document.forms[formname].elements[arr[x]].onclick) 389 document.forms[formname].elements[arr[x]].onclick(); 390 } 391 } 392} 393 394function checkAll(flag, form, prefix) { 395 if (!form) { 396 return; 397 } 398 399 if (prefix) { 400 var reg = new RegExp('^' + prefix, ''); 401 } 402 for (var i = 0; i < form.elements.length; i++) { 403 if ( 404 form.elements[i].type == "checkbox" 405 && (!prefix || form.elements[i].name.search(reg) == 0) 406 && !form.elements[i].disabled 407 ) { 408 form.elements[i].checked = flag; 409 } 410 } 411} 412 413/* 414 Opener/Closer HTML block 415 */ 416function visibleBox(id, skipOpenClose) { 417 var elm1 = document.getElementById('open' + id); 418 var elm2 = document.getElementById('close' + id); 419 var elm3 = document.getElementById('box' + id); 420 421 if (!elm3) { 422 return false; 423 } 424 425 if (skipOpenClose) { 426 elm3.style.display = (elm3.style.display == '') ? 'none' : ''; 427 428 } else if (elm1) { 429 if (elm1.style.display == '') { 430 elm1.style.display = 'none'; 431 432 if (elm2) { 433 elm2.style.display = ''; 434 } 435 436 elm3.style.display = 'none'; 437 jQuery('.DialogBox').css('height', '1%'); 438 439 } else { 440 elm1.style.display = ''; 441 if (elm2) { 442 elm2.style.display = 'none'; 443 } 444 445 elm3.style.display = ''; 446 } 447 } 448 449 return true; 450} 451 452/** 453 * Attach tooltip to some element on hover action 454 */ 455function attachTooltip(elm, content, forcePlacement, ttl) { 456 var placement = 'right'; 457 458 elm = jQuery(elm); 459 460 if ( 461 elm.length 462 && ( 463 (jQuery(window).width() - elm.offset().left) < 200 464 || ( 465 elm.parents('.ui-dialog').length 466 && (elm.parents('.ui-dialog').offset().left + elm.parents('.ui-dialog').width() - elm.offset().left) < 200 467 ) 468 ) 469 ) { 470 placement = 'left'; 471 } 472 placement = forcePlacement || placement; 473 474 jQuery(elm).each( 475 function () { 476 if (isBootstrapUse()) { 477 478 if ('undefined' == typeof(this.tooltipAssigned) || !this.tooltipAssigned) { 479 480 var to; 481 var obj = jQuery(this); 482 if (undefined === ttl) { 483 ttl = 500; 484 } 485 ; 486 487 var options = { 488 html: true, 489 title: content, 490 placement: placement, 491 trigger: 'manual' 492 }; 493 494 if (elm.data('container')) { 495 options['container'] = elm.data('container'); 496 } else if (elm.parents('.ui-dialog').length > 0) { 497 options['container'] = '.ui-dialog'; 498 } 499 ; 500 obj.tooltip(options); 501 502 obj.mouseover( 503 function () { 504 if (to) { 505 clearTimeout(to); 506 to = null; 507 } 508 if (!obj.next('.tooltip').length) { 509 jQuery(this).tooltip('show'); 510 } 511 } 512 ); 513 514 obj.mouseout( 515 function () { 516 to = setTimeout( 517 function () { 518 obj.tooltip('hide'); 519 }, 520 ttl 521 ); 522 } 523 ); 524 525 obj.on( 526 'shown.bs.tooltip', 527 function (event) { 528 var next = jQuery(event.currentTarget).next(); 529 if ('undefined' == typeof(next.get(0).tooltipAssigned) || !next.get(0).tooltipAssigned) { 530 next 531 .mouseover(function () { 532 obj.mouseover(); 533 }) 534 .mouseout(function () { 535 obj.mouseout(); 536 }); 537 next.get(0).tooltipAssigned = true; 538 } 539 } 540 ); 541 542 this.tooltipAssigned = true; 543 544 } 545 546 } else { 547 jQuery(this).tooltip({ 548 items: this, 549 'content': content 550 }); 551 552 } 553 554 jQuery(document).on('click', '.tooltip-main .tooltip', function (evt) { 555 return false;
556 }); 557 558 jQuery(document).on('click', '.tooltip-main .tooltip a', function (evt) { 559 evt.stopPropagation(); 560 }); 561 } 562 ); 563} 564 565/** 566 * Wait overlay 567 */ 568 569function assignWaitOverlay(elem) { 570 return createOverlay(elem, 'wait'); 571} 572 573function unassignWaitOverlay(elem, force) { 574 return removeOverlay(elem, force); 575} 576 577/** 578 * Shade overlay 579 */ 580 581function assignShadeOverlay(elem) { 582 return createOverlay(elem, 'shade'); 583} 584 585function unassignShadeOverlay(elem, force) { 586 return removeOverlay(elem, force); 587} 588 589var overlayRegistry = {}; 590var overlayAttr = 'data-overlay-id'; 591 592function getOverlaySelector (elem) { 593 return elem.attr(overlayAttr) || generateOverlayId(); 594} 595 596function generateOverlayId() { 597 do { 598 var pattern = 'overlay-' + Math.round(Math.random() * 1000000); 599 var isUnique = $('[' + overlayAttr + '=' + pattern + ']').length === 0; 600 } while (!isUnique); 601 602 return pattern; 603} 604 605function createOverlay(elem, type) { 606 type = type || 'wait'; 607 var pattern = getOverlaySelector(elem); 608 609 $.each(elem, function() { 610 var elem = $(this); 611 612 if (!_.isUndefined(this.overlay) && this.overlay) { 613 unassignWaitOverlay(elem); 614 } 615 616 var overlayElement = null; 617 if (type === 'wait') { 618 overlayElement = jQuery('<div class="wait-block-overlay"><div class="wait-block"><div></div></div></div>'); 619 } else { 620 overlayElement = jQuery('<div class="shade-block-overlay"></div>'); 621 } 622 623 overlayElement.css({ 624 width: elem.outerWidth() + 'px', 625 height: elem.outerHeight() + 'px' 626 }); 627 628 // We do not show the overlay if the element has zero width or height (the element is not visible) 629 if (0 !== elem.outerWidth() && 0 !== elem.outerHeight()) { 630 elem.prepend(overlayElement) 631 } 632 633 var leftOffset = elem.offset().left - overlayElement.offset().left; 634 var topOffset = elem.offset().top - overlayElement.offset().top; 635 overlayElement.css('margin-left', leftOffset + 'px'); 636 overlayElement.css('margin-top', topOffset + 'px'); 637 638 overlayElement.attr('id', pattern); 639 elem.attr(overlayAttr, pattern); 640 overlayRegistry[pattern] = overlayElement; 641 this.overlay = overlayElement; 642 643 elem.trigger('assignOverlay', {widget: elem, type: type}); 644 }); 645 646 return $('#' + pattern); 647} 648 649function removeOverlay(elem, force) { 650 var pattern = getOverlaySelector(elem); 651 652 $.each(elem, function() { 653 var elem = $(this); 654 655 var overlay = null; 656 if (pattern && typeof overlayRegistry[pattern] !== "undefined") { 657 overlay = overlayRegistry[pattern]; 658 } else if (force) { 659 overlay = $('.wait-block-overlay, .shade-block-overlay'); 660 } 661 662 if (overlay) { 663 overlay.remove(); 664 elem.attr(overlayAttr, null); 665 elem.trigger('unassignOverlay', {widget: elem}); 666 this.overlay = null; 667 } 668 }); 669} 670 671function isBootstrapUse() { 672 return 'undefined' != typeof(jQuery.fn.modal) 673 && _.isFunction(jQuery.fn.modal); 674} 675 676/** 677 * State widget specific objects and methods (used in select_country.js ) 678 */ 679 680var StatesList = (function () { 681 var instance; 682 683 function createInstance() { 684 function StatesListProto() { 685 } 686 687 extend(StatesListProto, Object); 688 689 StatesListProto.states = []; 690 StatesListProto.stateSelectors = []; 691 StatesListProto.forceCustomState = false; 692 StatesListProto.forceCustomStateCountries = []; 693 694 StatesListProto.prototype.addStates = function (states) { 695 StatesListProto.states = array_merge(this.states, states); 696 return this; 697 }; 698 699 StatesListProto.prototype.getStates = function (country) { 700 return StatesListProto.states[country]; 701 }; 702 703 StatesListProto.prototype.getAllStates = function () { 704 return StatesListProto.states; 705 }; 706 707 StatesListProto.prototype.getStatesArray = function (country) { 708 var extractStates = function (state) { 709 if (state instanceof Object) { 710 if (!_.isUndefined(state.name)) { 711 return [state.name]; 712 } 713 714 var result = []; 715 716 if (state instanceof Array) { 717 state.map(function (v) { 718 result = result.concat(extractStates(v)); 719 }); 720 } else { 721 Object.keys(state).forEach(function (key) { 722 result = result.concat(extractStates(state[key])); 723 }); 724 } 725 726 return result.sort(function (a, b) { 727 return a.toLowerCase().localeCompare(b.toLowerCase()); 728 }); 729 } 730 731 return []; 732 }; 733 734 return extractStates(this.getStates(country)); 735 }; 736 737 StatesListProto.prototype.addStateSelector = function (fieldId, stateSelector) { 738 StatesListProto.stateSelectors[fieldId] = stateSelector; 739 return this; 740 }; 741 742 StatesListProto.prototype.getStateSelectors = function () { 743 return StatesListProto.stateSelectors; 744 }; 745 746 StatesListProto.prototype.isForceCustomState = function (country) { 747 return StatesListProto.forceCustomState 748 || StatesListProto.forceCustomStateCountries.indexOf(country) != -1; 749 }; 750 751 StatesListProto.prototype.updateStatesList = function (base) { 752 var _stateSelectors, _forceCustomState, o = this; 753 754 base = base || document; 755 756 if (!jQuery('.country-selector', base).length) { 757 o.addStates(window.statesList); 758 } else { 759 jQuery('.country-selector', base).each(function (index, elem) { 760 o.addStates(xcart.getCommentedData(elem, 'statesList')); 761 _forceCustomState = xcart.getCommentedData(elem, 'forceCustomState'); 762 _stateSelectors = xcart.getCommentedData(elem, 'stateSelectors'); 763 764 if (_forceCustomState instanceof Array) { 765 if (_forceCustomState.indexOf('All') != -1) { 766 StatesListProto.forceCustomState = true; 767 _forceCustomState.splice(_forceCustomState.indexOf('All'), 1); 768 } 769 770 StatesListProto.forceCustomStateCountries = array_merge( 771 StatesListProto.forceCustomStateCountries, 772 _forceCustomState 773 ); 774 } 775 776 if (_stateSelectors) { 777 o.addStateSelector(_stateSelectors.fieldId, new StateSelector( 778 _stateSelectors.fieldId, 779 _stateSelectors.stateSelectorId, 780 _stateSelectors.stateInputId 781 )); 782 } 783 }); 784 } 785 }; 786 787 return new StatesListProto; 788 } 789 790 return { 791 getInstance: function () { 792 if (!instance) { 793 instance = createInstance(); 794 795 instance.updateStatesList(); 796 } 797 return instance; 798 } 799 }; 800})(); 801 802function setPriceElement(element, value, e) { 803 e = e || 2; 804 805 var str = xcart.numberToString(value, '.', '', e); 806 var parts = str.split('.'); 807 808 // Sign 809 if (!element.find('.part-sign').length) { 810 if (!element.find('.part-prefix').length) { 811 element.find('.part-integer').before('<span class="part-sign"></span>'); 812 813 } else { 814 element.find('.part-prefix').before('<span class="part-sign"></span>'); 815 } 816 } 817 if (value >= 0) { 818 element.find('.part-sign').html(''); 819 820 } else { 821 element.find('.part-sign').html('− '); 822 } 823 824 element.find('.part-integer').html(Math.abs(parseInt(parts[0]))); 825 if (parts[1]) { 826 element.find('.part-decimal').html(parts[1]); 827 828 } else { 829 element.find('.part-decimal').html(''); 830 } 831} 832 833function CacheEngine() { 834 this.cache = []; 835} 836 837CacheEngine.prototype.add = function (key, value) { 838 var updated = false;
839 840 for (var i = 0; i < this.cache.length; i++) { 841 if (this.cache[i].key === key) { 842 updated = true; 843 this.cache[i].value = value; 844 845 break; 846 } 847 } 848 849 if (!updated) { 850 this.cache.push({key: key, value: value}); 851 } 852}; 853 854CacheEngine.prototype.get = function (key) { 855 for (var i = 0; i < this.cache.length; i++) { 856 if (this.cache[i].key === key) { 857 return this.cache[i].value; 858 } 859 } 860}; 861 862CacheEngine.prototype.has = function (key) { 863 for (var i = 0; i < this.cache.length; i++) { 864 if (this.cache[i].key === key) { 865 return true; 866 } 867 } 868}; 869 870CacheEngine.prototype.remove = function (key) { 871 var index = null; 872 873 for (var i = 0; i < this.cache.length; i++) { 874 if (this.cache[i].key === key) { 875 index = i; 876 877 break; 878 } 879 } 880 881 this.cache.splice(index, 1); 882}; 883 884CacheEngine.prototype.clear = function () { 885 this.cache = []; 886}; 887 888function getPasswordDifficulty(password) { 889 var digits = new RegExp('\\d'); 890 891 var lowerLetters, upperLetters, specials; 892 try { 893 lowerLetters = new RegExp('\\p{Ll}', 'u'); 894 upperLetters = new RegExp('\\p{Lu}', 'u'); 895 specials = new RegExp('[^\\d\\p{L}]', 'u'); 896 } catch (e) { 897 console.log("Current browser doesn't support regular expressions with unicode"); 898 lowerLetters = new RegExp('[a-z]'); 899 upperLetters = new RegExp('[A-Z]'); 900 specials = new RegExp('[^A-Za-z\\d]'); 901 } 902 903 var rating = 0; 904 [digits, lowerLetters, upperLetters, specials].forEach(function(item) { 905 if (item.test(password)) { 906 rating++; 907 } 908 }); 909 910 if (password.length >= 6) { 911 rating++; 912 } 913 914 if (rating < 3) { 915 return 'Weak password'; 916 } 917 918 return (rating < 4) ? 'Good password' : 'Strong password'; 919} 920 921function showPasswordDifficultyMessage(elem, difficulty) { 922 elem.html(xcart.t(difficulty)); 923} 924 925function setPasswordDifficultyColor(elem, difficulty) { 926 if (difficulty == 'Weak password') { 927 elem.css("color", "#D4142C"); 928 } else if (difficulty == 'Good password') { 929 elem.css("color", "#A66908"); 930 } else if (difficulty == 'Strong password') { 931 elem.css("color", "#598103"); 932 } 933} 934 935function smartTrim(string, maxLength) { 936 if (string.length <= maxLength) { 937 return string; 938 } 939 940 if (maxLength == 1) { 941 return string.substring(0,1) + '...'; 942 } 943 944 const midpoint = Math.ceil(string.length / 2); 945 const toremove = string.length - maxLength; 946 const lstrip = Math.ceil(toremove/2); 947 const rstrip = toremove - lstrip; 948 949 return string.substring(0, midpoint-lstrip) + '...' 950 + string.substring(midpoint+rstrip); 951}; 952 953jQuery(document).ready( 954 function () { 955 var isIE11 = !!navigator.userAgent.match(/Trident.*rv[ :]*11\./); 956 957 if (isIE11) { 958 jQuery('body').addClass('ie11'); 959 } 960 961 // Open warning popup 962 xcart.microhandlers.add( 963 'OverlayHeightResize', 964 '>*:first', 965 function (event) { 966 jQuery('.ui-widget-overlay').css('height', jQuery(document).height()); 967 jQuery('.ui-widget-overlay').css('width', jQuery('body').innerWidth()); 968 } 969 ); 970 971 xcart.microhandlers.add( 972 'PopupModelButtonWidthFix', 973 '.model-form-buttons', 974 function (event) { 975 jQuery('.ajax-container-loadable .model-form-buttons') 976 .each(function (index, elem) { 977 jQuery('.button', elem).width(jQuery(elem).width()); 978 }); 979 } 980 ); 981 982 xcart.microhandlers.add( 983 'promo-close', 984 '.promo-block .close', 985 function (event) { 986 $(this).click(function () { 987 var block = jQuery(this).parents('.promo-block').get(0); 988 var blockId = jQuery(block).data('promo-id'); 989 if (0 < blockId.length) { 990 blockId = blockId + 'PromoBlock'; 991 document.cookie = blockId + '=1'; 992 } 993 jQuery(block).hide(); 994 }); 995 } 996 ); 997 998 xcart.microhandlers.add( 999 'promo-close-2', 1000 '.promo-block-close', 1001 function (event) { 1002 $(this).click(function () { 1003 var blockSelector = jQuery(this).data('promo-selector'); 1004 var block = null; 1005 1006 if (blockSelector) { 1007 block = jQuery(blockSelector); 1008 } else { 1009 block = jQuery(this).parents('.promo-block').get(0) 1010 } 1011 1012 var blockId = jQuery(block).data('promo-id'); 1013 if (0 < blockId.length) { 1014 blockId = blockId + 'PromoBlock'; 1015 document.cookie = blockId + '=1'; 1016 } 1017 jQuery(block).hide(); 1018 }); 1019 } 1020 ); 1021 1022 xcart.microhandlers.add( 1023 'promo-close-2', 1024 'input.column-selector', 1025 function (event) { 1026 $(this).click(function () { 1027 if (!this.columnSelectors) { 1028 var idx = jQuery(this).parents('th').get(0).cellIndex; 1029 var table = jQuery(this).parents('table').get(0); 1030 this.columnSelectors = jQuery('tr', table) 1031 .find('td') 1032 .eq(idx) 1033 .find(':checkbox'); 1034 } 1035 1036 this.columnSelectors.prop('checked', this.checked ? 'checked' : ''); 1037 }); 1038 } 1039 ); 1040 1041 xcart.microhandlers.add( 1042 'input-file', 1043 'input.inputfile', 1044 function (event) { 1045 $(this).change(function () { 1046 if (this.files) { 1047 var filename = ''; 1048 if (this.files.length > 1) { 1049 filename = this.files.length + " files selected"; 1050 } else { 1051 filename = this.files[0].name; 1052 } 1053 1054 const filenameElement = $(this).siblings('span.input-filename'); 1055 if (filename) { 1056 filename = filename 1057 .replace(/&/g, "&") 1058 .replace(/</g, "<") 1059 .replace(/>/g, ">") 1060 .replace(/"/g, """) 1061 .replace(/'/g, "'"); 1062 filenameElement.html(smartTrim(filename, 20)); 1063 } 1064 } 1065 }); 1066 } 1067 ); 1068 1069 1070 if (xliteConfig.zone === 'customer') { 1071 xcart.microhandlers.add( 1072 '.profile-form', 1073 'input#password', 1074 function (event) { 1075 $(this) 1076 .last() 1077 .on('input', function () { 1078 var difficulty = getPasswordDifficulty($(this).val()); 1079 1080 var form = $(this).closest('form'); 1081 var formId = form.attr('id') 1082 var passwordDifficultyElem = $(".password-difficulty[form-id=" + formId + "]"); 1083 1084 if (passwordDifficultyElem.length == 0) { 1085 form.find('.password-label').append( 1086 "<span class='password-difficulty' form-id='" + formId + "'></span>" 1087 ); 1088 passwordDifficultyElem = $(".password-difficulty[form-id=" + formId + "]"); 1089 } 1090 1091 1092 showPasswordDifficultyMessage(passwordDifficultyElem, difficulty); 1093 setPasswordDifficultyColor(passwordDifficultyElem, difficulty); 1094 }); 1095 } 1096 ); 1097 } 1098 1099 xcart.bind('popup.open', function () { 1100 jQuery('html').addClass('popup-opened'); 1101 }); 1102 xcart.bind('popup.close', function () { 1103 jQuery('html').removeClass('popup-opened'); 1104 }); 1105 });; 1106/* AUTOGENERATED: xcart.element.js */ 1107/* vim: set ts=2 sw=2 sts=2 et: */ 1108 1109/** 1110 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 1111 * See https://www.x-cart.com/license-agreement.html for license details. 1112 */ 1113 1114Element.prototype.fireEvent = Window.prototype.fireEvent = function fireEvent(event, eventInterface) { 1115 eventInterface = eventInterface || 'Event'; 1116 emitEvent(this, event, eventInterface); 1117}; 1118 1119function emitEvent(object, event, eventInterface) { 1120 if (document.createEventObject) { 1121 // dispatch for IE 1122 var evt = document.createEventObject(); 1123 return object.fireEvent('on' + event, evt); 1124 } else { 1125 // dispatch for firefox + others 1126 eventInterface = eventInterface || 'Event'; 1127 var evt = document.createEvent(eventInterface); 1128 evt.initEvent(event, true, true); // event type,bubbling,cancelable 1129 return !object.dispatchEvent(evt); 1130 } 1131}; 1132/* AUTOGENERATED: xcart.js */ 1133/* vim: set ts=2 sw=2 sts=2 et: */ 1134 1135/** 1136 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 1137 * See https://www.x-cart.com/license-agreement.html for license details. 1138 */ 1139 1140/** 1141 * OOP core 1142 */ 1143 1144// OOP extends emulation 1145function extend(child, parent) { 1146 var F = function () { 1147 }; 1148 F.prototype = parent.prototype; 1149 child.prototype = new F(); 1150 child.prototype.constructor = child; 1151 child.superclass = parent.prototype; 1152 1153 child.prototype.inherit_stack = child.prototype.inherit_stack === undefined 1154 ? [] 1155 : child.prototype.inherit_stack.slice(0); 1156 child.prototype.inherit_stack.push(parent); 1157} 1158 1159// Decorate / add method 1160function decorate(c, methodName, method) { 1161 c = getClassByName(c); 1162 1163 var result = false;
1164 1165 if (c) { 1166 method.previousMethod = 'undefined' == typeof (c.prototype[methodName]) ? null : c.prototype[methodName]; 1167 c.prototype[methodName] = method; 1168 result = true; 1169 } 1170 1171 return result; 1172} 1173 1174// Get class object by name (or object) 1175function getClassByName(c) { 1176 if (c && c.constructor == String) { 1177 c = eval('(("undefined" != typeof(window.' + c + ') && ' + c + '.constructor == Function) ? ' + c + ' : null)'); 1178 1179 } else if (!c || c.constructor != Function) { 1180 c = null; 1181 } 1182 1183 return c; 1184} 1185 1186// Base class 1187function Base() { 1188 this.triggerVent('initialize'); 1189} 1190 1191// Call parent method by name nad arguments list 1192Base.prototype.callSupermethod = function (name, args) { 1193 var call_stack_head = false; 1194 this.call_stack = this.call_stack === undefined ? {} : this.call_stack; 1195 if (!this.call_stack.hasOwnProperty(name) || this.call_stack[name] === undefined) { 1196 call_stack_head = true; 1197 this.call_stack[name] = this.inherit_stack.slice(0); 1198 } 1199 1200 var superClass = this.call_stack[name].pop(); 1201 var result = (name === 'constructor' ? superClass : superClass.prototype[name]).apply(this, args); 1202 this.call_stack[name].push(superClass); 1203 1204 if (call_stack_head) { 1205 this.call_stack[name] = undefined; 1206 } 1207 1208 return result; 1209}; 1210 1211// Bind event handler 1212Base.prototype.bind = function (name, handler) { 1213 jQuery(this).bind(name, handler); 1214 1215 return this; 1216}; 1217 1218// Unbind event handler 1219Base.prototype.unbind = function (name, handler) { 1220 jQuery(this).unbind(name, handler); 1221 1222 return this; 1223}; 1224 1225// Trigger event on common mediator object 1226Base.prototype.triggerVent = function (name, data) { 1227 var ns = this.getEventNamespace(); 1228 if (ns) { 1229 xcart.trigger(ns + '.' + name, data); 1230 } 1231 1232 return jQuery(this).trigger('local.' + name, data); 1233}; 1234 1235// Get event namespace (prefix) 1236Base.prototype.getEventNamespace = function () { 1237 return null; 1238}; 1239 1240var reverseArguments = function (func) { 1241 return function () { 1242 return func.apply(this, Array.prototype.reverse.call(arguments)); 1243 }; 1244}; 1245 1246// Core definition 1247window.xcart = { 1248 1249 isDebug: false, 1250 1251 isReady: false, 1252 1253 isRequesterEnabled: false, 1254 1255 savedEvents: [], 1256 1257 messages: jQuery({}), 1258 1259 resources: [], 1260 1261 resourcesCacheTimestamp: '', 1262 1263 htmlResourcesLoadDeferred: new $.Deferred(), 1264 1265 // Collections of the getters which return the parameters of the widgets to get via widgets collection process 1266 widgetsParamsGetters: {}, 1267 1268 doShadeWidgetsCollection: true, 1269 1270 xhrMiddlewares: [], 1271 1272 getXhrMiddlewares: function () { 1273 return [ 1274 this.processBackendEvents 1275 ].concat(this.xhrMiddlewares); 1276 }, 1277 1278 addXhrMiddleware: function (callback) { 1279 this.xhrMiddlewares.push(callback); 1280 }, 1281 1282 registerWidgetsParamsGetter: function (widgetsId, getter) { 1283 if (!this.widgetsParamsGetters[widgetsId]) { 1284 this.widgetsParamsGetters[widgetsId] = []; 1285 } 1286 this.widgetsParamsGetters[widgetsId].push(getter); 1287 }, 1288 1289 getWidgetsParams: function (widgetsId, paramsToCall) { 1290 var params = []; 1291 for (var key in this.widgetsParamsGetters[widgetsId]) { 1292 params = array_merge(params, this.widgetsParamsGetters[widgetsId][key](paramsToCall)); 1293 } 1294 return params; 1295 }, 1296 1297 widgetsTriggers: {}, 1298 1299 registerWidgetsTriggers: function (widgetsId, triggersGetter) { 1300 if (!this.widgetsTriggers[widgetsId]) { 1301 this.widgetsTriggers[widgetsId] = []; 1302 } 1303 this.widgetsTriggers[widgetsId].push(triggersGetter); 1304 }, 1305 1306 getWidgetsTriggers: function (widgetsId) { 1307 var triggers = []; 1308 for (var key in this.widgetsTriggers[widgetsId]) { 1309 triggers.push(this.widgetsTriggers[widgetsId][key]()); 1310 } 1311 return triggers; 1312 }, 1313 1314 shadowWidgets: {}, 1315 1316 registerShadowWidgets: function (widgetsId, shadowGetter) { 1317 if ('undefined' === typeof (this.shadowWidgets[widgetsId])) { 1318 this.shadowWidgets[widgetsId] = []; 1319 } 1320 this.shadowWidgets[widgetsId].push(shadowGetter); 1321 }, 1322 1323 getShadowWidgets: function (widgetsId) { 1324 var shadow = []; 1325 for (var key in this.shadowWidgets[widgetsId]) { 1326 shadow.push(this.shadowWidgets[widgetsId][key]()); 1327 } 1328 return array_unique(shadow); 1329 }, 1330 1331 widgetsTriggersBind: {}, 1332 1333 registerTriggersBind: function (widgetsId, triggersGetter) { 1334 if (!this.widgetsTriggersBind[widgetsId]) { 1335 this.widgetsTriggersBind[widgetsId] = []; 1336 } 1337 this.widgetsTriggersBind[widgetsId].push(triggersGetter); 1338 }, 1339 1340 callTriggersBind: function (widgetsId) { 1341 for (var key in this.widgetsTriggersBind[widgetsId]) { 1342 this.widgetsTriggersBind[widgetsId][key](); 1343 } 1344 }, 1345 1346 shadeWidgetsCollection: function (base) { 1347 if (this.doShadeWidgetsCollection) { 1348 jQuery(base).append('<div class="single-progress-mark"><div></div></div>'); 1349 } 1350 this.doShadeWidgetsCollection = true; 1351 }, 1352 1353 unshadeWidgetsCollection: function (base) { 1354 jQuery(base + ' .single-progress-mark').remove(); 1355 }, 1356 1357 processUpdateWidgetsCollection: function (widgetsId, widgetsCollection, widgetsCollectionParamsCommon, base) { 1358 // Shadows triggers (unbind and disable the trigger elements) 1359 var triggers = this.getWidgetsTriggers(widgetsId); 1360 for (var k in triggers) { 1361 jQuery(triggers[k]).unbind(k).prop('disabled', 'disabled'); 1362 } 1363 this.shadeWidgetsCollection('.product-details-info'); 1364 1365 // Shadow widgets collection
1366 //this.shadowCollection(base, this.getShadowWidgets(widgetsId)); 1367 1368 // Load widgets 1369 this.loadWidgetsCollection( 1370 base, 1371 widgetsCollection, 1372 array_merge( 1373 widgetsCollectionParamsCommon, 1374 this.getWidgetsParams(widgetsId, widgetsCollectionParamsCommon) 1375 ), 1376 function () { 1377 // Unshadow triggers (bind and enable trigger elements) 1378 for (var k in triggers) { 1379 jQuery(triggers[k]).removeAttr('disabled'); 1380 } 1381 xcart.unshadeWidgetsCollection('.product-details-info'); 1382 xcart.callTriggersBind(widgetsId); 1383 } 1384 ); 1385 }, 1386 1387 // Performs browser redirect on setTimeout 1388 redirectTo: function (url) { 1389 _.defer(function () { 1390 window.location.href = url; 1391 }); 1392 }, 1393 1394 // Trigger common message 1395 trigger: function (name, params) { 1396 var result = true; 1397 1398 name = name.toLowerCase(); 1399 1400 if (this.isReady) { 1401 1402 if (this.isDebug && 'undefined' != typeof (window.console)) { 1403 if (params) { 1404 console.log('Fire \'' + name + '\' event with arguments: ' + var_export(params, true)); 1405 } else { 1406 } 1407 console.log('Fire \'' + name + '\' event'); 1408 } 1409 1410 result = this.messages.trigger(name, [params]); 1411 1412 } else { 1413 this.savedEvents.push( 1414 { 1415 name: name, 1416 params: params 1417 } 1418 ); 1419 } 1420 1421 return result; 1422 }, 1423 1424 // Bind on common messages 1425 bind: function (name, callback) { 1426 if (_.isArray(name)) { 1427 for (var key in name) { 1428 if (name.hasOwnProperty(key)) { 1429 this.messages.bind(name[key].toLowerCase(), callback); 1430 } 1431 } 1432 } else { 1433 this.messages.bind(name.toLowerCase(), callback); 1434 } 1435 1436 return this; 1437 }, 1438 1439 // Unbind on common messages 1440 unbind: function (name, callback) { 1441 if (_.isArray(name)) { 1442 for (var key in name) { 1443 this.messages.unbind(name[key].toLowerCase(), callback); 1444 } 1445 } else { 1446 this.messages.unbind(name.toLowerCase(), callback); 1447 } 1448 1449 return this; 1450 }, 1451 1452 // Get HTML data from server 1453 get: function (url, callback, data, options) { 1454 if (_.isObject(url)) { 1455 url = URLHandler.buildURL(url); 1456 } 1457 1458 options = options || {}; 1459 1460 var completeCallback = options.complete || function () { 1461 }; 1462 var successCallback = options.success || function () { 1463 }; 1464 1465 var headers = { 1466 'ajaxRefererTarget': xcart.getTarget() 1467 }; 1468 options = jQuery.extend( 1469 { 1470 async: true, 1471 cache: false, 1472 contentType: 'text/html', 1473 global: false, 1474 timeout: xliteConfig.ajax_timeout, 1475 type: 'GET', 1476 url: url, 1477 data: data, 1478 headers: headers 1479 }, 1480 options, 1481 { 1482 complete: function () { 1483 _.partial(xcart.onXhrComplete, callback, options, data).apply(this, arguments); 1484 completeCallback.apply(this, arguments); 1485 }, 1486 success: function () { 1487 xcart.onXhrSuccess.apply(this, arguments); 1488 successCallback.apply(this, arguments); 1489 } 1490 } 1491 ); 1492 1493 return jQuery.ajax(options); 1494 }, 1495 1496 // Post form data to server 1497 post: function (url, callback, data, options) { 1498 if (_.isObject(url)) { 1499 url = URLHandler.buildURL(url); 1500 } 1501 1502 options = options || {}; 1503 1504 var completeCallback = options.complete || function () { 1505 }; 1506 var successCallback = options.success || function () { 1507 }; 1508 1509 var headers = { 1510 'ajaxRefererTarget': xcart.getTarget() 1511 }; 1512 1513 options = jQuery.extend( 1514 { 1515 async: true, 1516 cache: false, 1517 contentType: 'application/x-www-form-urlencoded', 1518 global: false, 1519 timeout: xliteConfig.ajax_timeout, 1520 type: 'POST', 1521 url: url, 1522 data: data, 1523 headers: headers 1524 }, 1525 options, 1526 { 1527 complete: function () { 1528 _.partial(xcart.onXhrComplete, callback, options, data).apply(this, arguments); 1529 completeCallback.apply(this, arguments); 1530 }, 1531 success: function () { 1532 xcart.onXhrSuccess.apply(this, arguments); 1533 successCallback.apply(this, arguments); 1534 } 1535 } 1536 ); 1537 1538 return jQuery.ajax(options); 1539 }, 1540 1541 onXhrSuccess: function (data, textStatus, XMLHttpRequest) { 1542 var list = XMLHttpRequest.getAllResponseHeaders().split(/\n/); 1543 1544 var header = _.find(list, function (headerValue) { 1545 return -1 !== headerValue.search(/update-csrf: (.*)/i); 1546 }); 1547 1548 var matches = header 1549 ? header.match(/update-csrf: (.*)/i) 1550 : null; 1551 1552 if (matches && matches[1]) { 1553 var headerData = JSON.parse(matches[1]); 1554 1555 if (headerData.name === 'xcart_form_id' && headerData.old === xliteConfig.form_id) {
1556 xliteConfig.form_id = headerData.value; 1557 } 1558 } 1559 }, 1560 1561 onXhrComplete: function (callback, options, data, XMLHttpRequest, textStatus) { 1562 var callCallback = xcart.preprocessResponse(XMLHttpRequest, options, callback); 1563 data = xcart.processResponse(XMLHttpRequest); 1564 var notValid = !!XMLHttpRequest.getResponseHeader('not-valid'); 1565 1566 return (callCallback && callback) ? callback(XMLHttpRequest, textStatus, data, !notValid) : true; 1567 }, 1568 1569 // Response preprocess (run callback or not) 1570 preprocessResponse: function (xhr, options, callback) { 1571 var result = true; 1572 1573 var responseStatus = parseInt(xhr.getResponseHeader('ajax-response-status')); 1574 1575 if (200 == xhr.status && 279 == responseStatus && xhr.getResponseHeader('AJAX-Location') && (!options || !options.rpc)) { 1576 xcart.get( 1577 xhr.getResponseHeader('AJAX-Location'), 1578 callback 1579 ); 1580 1581 result = false; 1582 1583 } else if (278 == responseStatus) { 1584 if (options.preventRedirect) { 1585 return result 1586 } 1587 1588 // Redirect 1589 var url = xhr.getResponseHeader('AJAX-Location'); 1590 1591 if (url) { 1592 window.location.assign(url); 1593 } 1594 1595 if (!url || this.urlHasHash(url)) { 1596 window.location.reload(true); 1597 } 1598 1599 result = false;
1600 } 1601 1602 return result; 1603 }, 1604 1605 urlHasHash: function (url) { 1606 return url.indexOf('#') !== -1; 1607 }, 1608 1609 // Process response from server 1610 processResponse: function (xhr) { 1611 var response = xhr.responseText; 1612 this.getXhrMiddlewares().forEach(function (callback) { 1613 var result = callback(xhr, response); 1614 if (typeof (result) !== 'undefined') { 1615 response = result; 1616 } 1617 }); 1618 1619 return (4 == xhr.readyState && 200 == xhr.status) ? response : false; 1620 }, 1621 1622 processBackendEvents: function (xhr) { 1623 if (4 == xhr.readyState) { 1624 var list = xhr.getAllResponseHeaders().split(/\n/); 1625 1626 for (var i = 0; i < list.length; i++) { 1627 if (-1 !== list[i].search(/^event-([^:]+):(.+)/i)) { 1628 1629 // Server-side event 1630 var m = list[i].match(/event-([^:]+):(.+)/i); 1631 xcart.trigger(m[1].toLowerCase(), eval('(' + m[2] + ')')); 1632 } 1633 } 1634 } 1635 }, 1636 1637 showInternalError: function () { 1638 return this.showError(this.t('Javascript core internal error. Page will be refreshed automatically')); 1639 }, 1640 1641 showServerError: function () { 1642 return this.showError(this.t('Background request to server side is failed. Page will be refreshed automatically')); 1643 }, 1644 1645 showError: function (message) { 1646 xcart.trigger( 1647 'message', 1648 {'type': 'error', 'message': message} 1649 ); 1650 }, 1651 1652 translator: null, 1653 1654 t: function (label, substitute) { 1655 return this.getTranslator().translate(label, substitute); 1656 }, 1657 1658 loadLanguageHash: function (hash) { 1659 return this.getTranslator().loadLanguageHash(hash); 1660 }, 1661 1662 getTranslator: function () { 1663 if (this.translator === null) { 1664 this.translator = new Translator(); 1665 } 1666 1667 return this.translator; 1668 }, 1669 1670 getHtmlResourcesLoadPromise: function () { 1671 return this.htmlResourcesLoadDeferred.promise(); 1672 }, 1673 1674 loadResource: function (resource, type) { 1675 var deferred = new $.Deferred(); 1676 if (_.isString(resource)) { 1677 resource = { 1678 url: resource, 1679 widget: '' 1680 }; 1681 } 1682 1683 type = type || xcart.getExtension(resource.url); 1684 1685 if (!resource.url.startsWith('var/theme/custom.css') && xcart.isLoadedResource(resource.url)) { 1686 return; 1687 } 1688 1689 var url = resource.url; 1690 1691 if ('' !== xcart.resourcesCacheTimestamp) { 1692 url = url 1693 + (url.indexOf('?') === -1 ? '?' : '&') 1694 + xcart.resourcesCacheTimestamp; 1695 } 1696 1697 LazyLoad[type](url, function () { 1698 xcart.registerResources([url]); 1699 xcart.trigger('resources.loaded', {file: url, widget: resource.widget}); 1700 deferred.resolve(); 1701 }); 1702 1703 return deferred.promise(); 1704 }, 1705 1706 isLoadedResource: function (url) { 1707 return _.contains(xcart.resources, url); 1708 }, 1709 1710 registerResources: function (list) { 1711 for (var key in list) { 1712 xcart.resources.push(list[key]); 1713 } 1714 }, 1715 1716 parseResources: function (element, uuid) { 1717 var restoreCallback = xcart.microhandlers.supressRun(); 1718 uuid = uuid || ''; 1719 element = jQuery(element); 1720 var resource = element.find('script[data-resource]').first(); 1721 1722 if (resource.length) { 1723 var data = JSON.parse(resource.html()); 1724 resource.remove(); 1725 1726 if (data.css || data.js) { 1727 var cssLoaded = xcart.loadResources(data.css, 'css'); 1728 var jsLoaded = xcart.loadResources(data.js, 'js'); 1729 1730 jQuery.when(cssLoaded, jsLoaded).done( 1731 function () { 1732 restoreCallback(); 1733 xcart.trigger('resources.ready', {widget: data.widget, uuid: uuid}); 1734 } 1735 ); 1736 } else { 1737 restoreCallback(); 1738 xcart.trigger('resources.empty', {widget: data.widget, uuid: uuid}); 1739 } 1740 } 1741 }, 1742 1743 loadResources: function (list, type) { 1744 var deferred = new $.Deferred(); 1745 var promises = []; 1746 1747 $.when(this.getHtmlResourcesLoadPromise()).then(function () { 1748 for (var key in list) { 1749 var resource = list[key]; 1750 1751 promises.push(xcart.loadResource(resource, type)); 1752 } 1753 1754 $.when.apply($, promises).then( 1755 function () { 1756 deferred.resolve(); 1757 } 1758 ); 1759 }); 1760 1761 return deferred.promise(); 1762 }, 1763 1764 parsePreloadedLabels: function (element, uuid) { 1765 element = jQuery(element); 1766 uuid = uuid || ''; 1767 var labelsContainer = element.find('script[data-preloaded-labels]').first(); 1768 1769 if (labelsContainer.length) { 1770 var data = JSON.parse(labelsContainer.html()); 1771 labelsContainer.remove(); 1772 1773 if (data.labels) { 1774 xcart.loadLabels(data.labels); 1775 xcart.trigger('preloaded_labels.ready', {widget: data.widget, uuid: uuid}); 1776 } else { 1777 xcart.trigger('preloaded_labels.empty', {widget: data.widget, uuid: uuid}); 1778 } 1779 } 1780 }, 1781 1782 loadLabels: function (list) { 1783 this.loadLanguageHash(list); 1784 }, 1785 1786 parseObjectString: function (objectString) { 1787 if (typeof (JSON5) !== 'undefined') { 1788 return JSON5.parse(objectString); 1789 } 1790 1791 console.error('Cannot parse JS object from string: JSON5 is not loaded'); 1792 }, 1793 1794 getLayoutOptions: function () {
1795 return window.xliteLayoutOptions || {}; 1796 }, 1797 1798 rest: { 1799 1800 lastResponse: null, 1801 1802 request: function (type, name, id, data, callback) { 1803 if (!type || !name) { 1804 return false; 1805 } 1806 1807 this.lastResponse = null; 1808 1809 var xhr = jQuery.ajax( 1810 { 1811 async: false !== callback, 1812 cache: false, 1813 complete: function (xhr, status) { 1814 return this.callback(xhr, status, callback); 1815 }, 1816 context: this, 1817 data: data, 1818 timeout: 30000, 1819 type: ('get' == type ? 'GET' : 'POST'), 1820 url: URLHandler.buildURL( 1821 { 1822 target: 'rest', 1823 action: type, 1824 name: name, 1825 id: id 1826 } 1827 ) 1828 } 1829 ); 1830 1831 if (false === callback) { 1832 xhr = (this.lastResponse && this.lastResponse.status == 'success') ? this.lastResponse.data : null; 1833 } 1834 1835 return xhr; 1836 }, 1837 1838 get: function (name, id, callback) { 1839 return this.request('get', name, id, null, callback); 1840 }, 1841 1842 post: function (name, id, data, callback) { 1843 return this.request('post', name, id, data, callback); 1844 }, 1845 1846 put: function (name, data, callback) { 1847 return this.request('put', name, null, data, callback); 1848 }, 1849 1850 'delete': function (name, id, callback) { 1851 return this.request('delete', name, id, null, callback); 1852 }, 1853 1854 callback: function (xhr, status, callback) { 1855 try { 1856 var data = jQuery.parseJSON(xhr.responseText); 1857 1858 } catch (e) { 1859 var data = null; 1860 } 1861 1862 if (false === callback) { 1863 xcart.rest.lastResponse = data; 1864 1865 } else if (callback) { 1866 callback(xhr, status, data); 1867 } 1868 } 1869 }, 1870 1871 clearHash: function (paramName) { 1872 var scrollV, scrollH, loc = window.location; 1873 var newHash = ''; 1874 1875 if (paramName !== undefined) { 1876 var pattern = '&?(' + paramName + '(\\[\\S*\\])*=[^&]*&?)'; 1877 var re = new RegExp(pattern, 'gi'); 1878 1879 newHash = loc.hash.replace(re, '').slice(1); 1880 } 1881 ; 1882 1883 // Prevent scrolling by storing the page's current scroll offset 1884 scrollV = document.body.scrollTop; 1885 scrollH = document.body.scrollLeft; 1886 1887 if (newHash !== loc.hash) { 1888 loc.hash = newHash; 1889 } 1890 1891 // Restore the scroll offset, should be flicker free 1892 document.body.scrollTop = scrollV; 1893 document.body.scrollLeft = scrollH; 1894 }, 1895 1896 autoload: function (className, element, extendedClass = null) { 1897 if ('function' === typeof (className)) { 1898 let m = className.toString().match(/function ([^\(]+)/); 1899 1900 m = !m && extendedClass ? extendedClass : m[1]; 1901 window[m] = className; 1902 className = m; 1903 } 1904 1905 var classObject = window[className]; 1906 1907 jQuery(document).ready( 1908 function () { 1909 if ('undefined' != typeof (classObject)) { 1910 if ('undefined' != typeof (element)) { 1911 jQuery(element).each(function (index, el) { 1912 jQuery(el).data('controller', new (classObject)(jQuery(el))); 1913 }); 1914 } else if ('function' == typeof (classObject.autoload)) { 1915 classObject.autoload(); 1916 1917 } else { 1918 new (classObject)(); 1919 } 1920 } 1921 } 1922 ); 1923 }, 1924 1925 // Return value of variable that is given in class attribute: e.g. class="superclass productid-100001 test" 1926 getValueFromClass: function (obj, prefix) { 1927 var m = jQuery(obj) 1928 .attr('class') 1929 .match(new RegExp(prefix + '-([^ ]+)( |$)')); 1930 1931 return m ? m[1] : null; 1932 }, 1933 1934 // Return value of variable that is given in comment block: e.g. <!-- 'productid': '100001', 'var': 'value', -->" 1935 getCommentedData: function (obj, name) { 1936 if (jQuery(obj).get(0)) { 1937 var children = jQuery(obj).get(0).childNodes; 1938 } else { 1939 return name ? null : []; 1940 } 1941 var m = false; 1942 1943 for (var i = 0; i < children.length && !m; i++) { 1944 if ('SCRIPT' == children[i].nodeName && 'text/x-cart-data' == children[i].type) { 1945 m = children[i].innerHTML; 1946 m = m.replace(/^\n\r/, '').replace(/\r\n$/, ''); 1947 try { 1948 m = eval('(' + m + ')'); 1949 } catch (e) { 1950 m = false;
1951 } 1952 } 1953 } 1954 1955 if (m && name) { 1956 m = 'undefined' == typeof (m[name]) ? null : m[name]; 1957 } 1958 1959 return m ? m : null; 1960 }, 1961 1962 // Toggle link text and toggle obj visibility 1963 toggleText: function (link, text, obj) { 1964 if (undefined === link.prevValue) { 1965 link.prevValue = jQuery(link).html(); 1966 } 1967 jQuery(link).html(jQuery(link).html() === text ? link.prevValue : text); 1968 jQuery(obj).toggle(); 1969 }, 1970 1971 setRelArray: function ($obj, relArray) { 1972 $obj.attr('data-rel', _.map(_.pairs(relArray), function (value) { 1973 return value.join(': '); 1974 }).join(', ')); 1975 }, 1976 1977 getRelArray: function ($obj) { 1978 var rel = $obj.attr('data-rel'); 1979 1980 return _.object(_.map(rel.split(','), function (value, key, list) { 1981 return _.map(_.trim(value).split(':'), function (value) { 1982 return _.trim(value); 1983 }); 1984 })); 1985 }, 1986 1987 // Decorate class after page loading 1988 decorate: function (className, methodName, func) { 1989 xcart.bind( 1990 'load', 1991 function () { 1992 decorate(className, methodName, func); 1993 } 1994 ); 1995 }, 1996 1997 // Decorate some class after page loading 1998 decorates: function (list, func) { 1999 xcart.bind( 2000 'load', 2001 function () { 2002 for (var i = 0; i < list.length; i++) { 2003 decorate(list[i][0], list[i][1], func); 2004 } 2005 } 2006 ); 2007 }, 2008 2009 stringToNumber: function (number, dDelim, tDelim) { 2010 if ('' !== tDelim) { 2011 number = number.replace(new RegExp('\\' + tDelim, 'g'), ''); 2012 } 2013 2014 var a = number.split(dDelim); 2015 2016 return parseFloat(a[0] + '.' + a[1]); 2017 }, 2018 2019 numberToString: function (number, dDelim, tDelim, precision) { 2020 dDelim = dDelim || '.'; 2021 tDelim = tDelim || ''; 2022 precision = precision || 0; 2023 2024 precision = Math.max(parseInt(precision), 0); 2025 2026 number = this.round(number, precision).toString(); 2027 /* 2028 Author: Robert Hashemian 2029 http://www.hashemian.com/ 2030 2031 You can use this code in any manner so long as the author's name, 2032 Web address and this disclaimer is kept intact. 2033 ********************************************************/ 2034 2035 var a = number.split('.'); 2036 var x = a[0]; // decimal 2037 var y = a[1]; // fraction 2038 var z = ''; 2039 2040 if (typeof (x) != 'undefined') { 2041 // reverse the digits. regexp works from left to right. 2042 for (var i = x.length - 1; i >= 0; i--) { 2043 z += x.charAt(i); 2044 } 2045 2046 // add separators. but undo the trailing one, if there 2047 z = z.replace(/(\d{3})/g, '$1' + tDelim); 2048 2049 if (z.slice(-tDelim.length) == tDelim) { 2050 z = z.slice(0, -tDelim.length); 2051 } 2052 2053 x = ''; 2054 2055 // reverse again to get back the number 2056 for (i = z.length - 1; i >= 0; i--) { 2057 x += z.charAt(i); 2058 } 2059 2060 // add the fraction back in, if it was there 2061 if (typeof (y) != 'undefined' && y.length > 0) { 2062 x += dDelim + y + this.repeat('0', precision - y.length); 2063 2064 } else if (precision > 0) { 2065 x += dDelim + this.repeat('0', precision); 2066 } 2067 } 2068 2069 return x; 2070 }, 2071 2072 getExtension: function (path) { 2073 return path.slice((path.lastIndexOf('.') - 1 >>> 0) + 2); 2074 }, 2075 2076 repeat: function (s, n) { 2077 var a = []; 2078 while (a.length < n) { 2079 a.push(s); 2080 } 2081 2082 return a.join(''); 2083 }, 2084 2085 round: function (number, precision) { 2086 precision = precision || 0; 2087 precision = Math.max(parseInt(precision), 0); 2088 2089 var pow = Math.pow(10, precision); 2090 2091 return Math.round(number * pow) / pow; 2092 }, 2093 2094 loadWidgetsCollection: function (base, collectionName, params, restoreCallback) { 2095 this.get( 2096 URLHandler.buildURL(array_merge({ 2097 'target': 'widgets_collection', 2098 'action': 'get', 2099 'widget': collectionName 2100 }, params)), 2101 function (XMLHttpRequest, textStatus, data) { 2102 try { 2103 data = JSON.parse(data); 2104 for (var key in data) { 2105 jQuery('.' + data[key].view, jQuery(base)).replaceWith(data[key].content); 2106// xcart.unshadowWidget(base, '.' + data[key].view); 2107 } 2108 restoreCallback(); 2109 2110 } catch (error) { 2111 console.log(error.message); 2112 } 2113 } 2114 ); 2115 }, 2116 2117 shadowCollection: function (base, collection) { 2118 for (key in collection) { 2119 jQuery(collection[key], jQuery(base)).after('<div class="single-progress-mark"></div>'); 2120 } 2121 }, 2122 2123 unshadowWidget: function (base, widget) { 2124 jQuery('.single-progress-mark', jQuery(widget, jQuery(base)).parent()).remove(); 2125 }, 2126 2127 getURLParam: function (name) { 2128 name = name.replace(/[\[]/, '\\\[').replace(/[\]]/, '\\\]'); 2129 var regexS = '[\\?&]' + name + '=([^&#]*)'; 2130 var regex = new RegExp(regexS); 2131 var results = regex.exec(window.location.href); 2132 if (results == null) { 2133 return ''; 2134 } else { 2135 return results[1]; 2136 } 2137 }, 2138 2139 getUrlParams: function (url) { 2140 if (_.isUndefined(url)) { 2141 url = window.location.search; 2142 } 2143 2144 if (url.indexOf('?') >= 0) { 2145 url = url.substr(url.indexOf('?') + 1); 2146 } 2147 2148 var searchParams = new URLSearchParams(url); 2149 2150 var result = []; 2151 for (const [key, value] of searchParams) { 2152 result[key] = searchParams.get(key); 2153 } 2154 return result; 2155 }, 2156 2157 getTarget: function () { 2158 return xliteConfig.target; 2159 }, 2160 2161 getFormIdString: function () { 2162 return xliteConfig.form_id_name + '=' + xliteConfig.form_id; 2163 }, 2164 2165 /** 2166 * @param {Element} el 2167 * @param {string} selector 2168 * @return {Array<Element>} 2169 */ 2170 parents: (el, selector) => { 2171 const parents = []; 2172 2173 while ((el = el.parentNode) && el !== document) { 2174 if (el.matches(selector) || !selector) { 2175 parents.push(el); 2176 } 2177 } 2178 2179 return parents; 2180 } 2181}; 2182 2183// HTTP requester detection 2184try { 2185 const xhr = window.ActiveXObject ? new ActiveXObject('Microsoft.XMLHTTP') : new XMLHttpRequest() 2186 xcart.isRequesterEnabled = !!xhr 2187} catch (e) { 2188} 2189 2190// Common onready event handler 2191jQuery(document).ready( 2192 function () { 2193 xcart.isReady = true; 2194 xcart.trigger('load'); 2195 for (var i = 0; i < xcart.savedEvents.length; i++) { 2196 xcart.trigger(xcart.savedEvents[i].name, xcart.savedEvents[i].params); 2197 } 2198 xcart.savedEvents = []; 2199 } 2200); 2201 2202xcart.isDeveloperMode = xliteConfig.developer_mode; 2203 2204/** 2205 * Common functions 2206 */ 2207 2208// Check - specified object is HTML element or not 2209function isElement(obj, type) { 2210 return obj && typeof (obj.tagName) != 'undefined' && obj.tagName.toLowerCase() == type; 2211} 2212 2213jQuery.extend({ 2214 getQueryParameters: function (str) { 2215 return (str || document.location.search).replace(/(^\?)/, '').split('&').map(function (n) { 2216 return n = n.split('='), this[n[0]] = n[1], this; 2217 }.bind({}))[0]; 2218 } 2219}); 2220 2221xcart.bind( 2222 'load', 2223 function () { 2224 jQuery('input[type=checkbox]').each( 2225 function () { 2226 var checkbox = this; 2227 2228 jQuery(checkbox).bind( 2229 'click', 2230 function () { 2231 return !jQuery(checkbox).prop('readonly'); 2232 } 2233 ); 2234 } 2235 ); 2236 2237 jQuery('.model-form-buttons .button:first-child button').addClass('btn-warning'); 2238 } 2239); 2240 2241/* Microhandlers */ 2242 2243xcart.microhandlers = {}; 2244 2245xcart.microhandlers.list = {}; 2246 2247xcart.microhandlers.initialRunned = false;
2248xcart.microhandlers.supressRunOnAdd = false; 2249 2250xcart.microhandlers.supressRun = function () { 2251 var previous = this.supressRunOnAdd; 2252 this.supressRunOnAdd = true; 2253 2254 return _.bind( 2255 function () { 2256 this.supressRunOnAdd = false; 2257 }, 2258 this 2259 ); 2260}; 2261 2262xcart.microhandlers.add = function (name, pattern, handler) { 2263 this.list[name] = { 2264 'pattern': pattern, 2265 'handler': handler 2266 }; 2267 2268 if (this.initialRunned && !this.supressRunOnAdd) { 2269 this.run(name); 2270 } 2271}; 2272 2273xcart.microhandlers.run = function (name, base) { 2274 base = base || document; 2275 2276 if ('undefined' != typeof (this.list[name]) && this.list[name]) { 2277 if (_.isString(this.list[name].pattern)) { 2278 jQuery(this.list[name].pattern, base) 2279 .filter(_.bind(this.filterByMark(name), this)) 2280 .each(this.list[name].handler) 2281 .each(_.bind(this.assignMark(name), this)); 2282 2283 } else if (_.isFunction(this.list[name].pattern)) { 2284 this.list[name].pattern() 2285 .filter(_.bind(this.filterByMark(name), this)) 2286 .each(this.list[name].handler) 2287 .each(_.bind(this.assignMark(name), this)); 2288 } 2289 } 2290}; 2291 2292xcart.microhandlers.runInitial = function () { 2293 this.initialRunned = true; 2294 this.runAll(document); 2295}; 2296 2297xcart.microhandlers.runAll = function (base) { 2298 _.each( 2299 _.keys(this.list), 2300 function (name) { 2301 if (typeof this.run !== 'undefined') { 2302 this.run(name, base); 2303 } 2304 }, 2305 this 2306 ); 2307}; 2308 2309xcart.microhandlers.filterByMark = function (name) { 2310 return function (idx, elm) { 2311 return !jQuery(elm).data('microhandler-' + name); 2312 }; 2313}; 2314 2315xcart.microhandlers.assignMark = function (name) { 2316 return function (idx, elm) { 2317 jQuery(elm).data('microhandler-' + name, true); 2318 }; 2319}; 2320 2321xcart.microhandlers.add( 2322 'BootstrapTooltip', 2323 '[data-toggle="tooltip"]', 2324 function (event) { 2325 jQuery(this).tooltip(); 2326 } 2327); 2328 2329xcart.microhandlers.add( 2330 'BootstrapPopover', 2331 '[data-toggle="popover"]', 2332 function (event) { 2333 if (!_.isUndefined(jQuery(this).startTooltip)) { 2334 jQuery(this).startTooltip(); 2335 } 2336 } 2337); 2338 2339xcart.bind( 2340 'load', 2341 function () { 2342 xcart.microhandlers.runInitial(); 2343 } 2344); 2345 2346xcart.bind( 2347 'loader.loaded', 2348 function (event, widget) { 2349 xcart.microhandlers.runAll(widget.base); 2350 } 2351); 2352 2353xcart.bind( 2354 'vue-form.ready', 2355 function (event, element) { 2356 xcart.microhandlers.runAll(element); 2357 } 2358); 2359 2360if (window.CoreAMD !== undefined) { 2361 define('js/xcart', function () { 2362 return xcart; 2363 }); 2364} else { 2365 document.addEventListener('amd-ready', function (event) { 2366 define('js/xcart', function () { 2367 return xcart; 2368 }); 2369 }); 2370}; 2371/* AUTOGENERATED: xcart.extend.js */ 2372/* vim: set ts=2 sw=2 sts=2 et: */ 2373 2374/** 2375 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 2376 * See https://www.x-cart.com/license-agreement.html for license details. 2377 */ 2378 2379Object.getOwnPropertyDescriptors = function getOwnPropertyDescriptors(obj) { 2380 var descriptors = {}; 2381 for (var prop in obj) { 2382 if (obj.hasOwnProperty(prop)) { 2383 descriptors[prop] = Object.getOwnPropertyDescriptor(obj, prop); 2384 } 2385 } 2386 return descriptors; 2387}; 2388 2389Function.prototype.extend = function (proto) { 2390 var superclass = this; 2391 var constructor; 2392 2393 if (!proto.hasOwnProperty('constructor')) { 2394 Object.defineProperty(proto, 'constructor', { 2395 value: function () { 2396 // Default call to superclass as in maxmin classes 2397 superclass.apply(this, arguments); 2398 }, 2399 writable: true, 2400 configurable: true, 2401 enumerable: false 2402 }); 2403 } 2404 constructor = proto.constructor; 2405 2406 constructor.prototype = Object.create(this.prototype, Object.getOwnPropertyDescriptors(proto)); 2407 2408 constructor.superclass = superclass.prototype; 2409 2410 return constructor; 2411};; 2412/* AUTOGENERATED: xcart.controller.js */ 2413/* vim: set ts=2 sw=2 sts=2 et: */ 2414 2415/** 2416 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 2417 * See https://www.x-cart.com/license-agreement.html for license details. 2418 */ 2419 2420// Abstract controller 2421function AController(base) 2422{ 2423 if (!base) { 2424 2425 // Search base DOM element(s) 2426 base = this.findBase(); 2427 } 2428 2429 if (base) { 2430 2431 if (base.length > 1) { 2432 2433 // Multiple binding 2434 for (var i = 0; i < base.length; i++) { 2435 eval('new ' + this.name + '(jQuery(base[i]))'); 2436 } 2437 2438 } else { 2439 2440 // Simple binding 2441 this.bind(jQuery(base)); 2442 } 2443 } 2444} 2445 2446// Parent class - Base 2447extend(AController, Base); 2448 2449// [ABSTRACT] Controller unique name 2450AController.prototype.name = null; 2451 2452// Base DOM element 2453AController.prototype.base = null; 2454 2455// Find jQuery pattern 2456AController.prototype.findPattern = null; 2457 2458// Check - controller is catch base DOM element or not 2459AController.prototype.isBinded = function() 2460{ 2461 return !!this.base; 2462} 2463 2464// Bind controller to base DOM element 2465AController.prototype.bind = function(base) 2466{ 2467 var result = false;
2468 2469 if (this.name && !this.isBaseCatched(base) && this.detectBase(base)) { 2470 var o = this; 2471 base = jQuery(base); 2472 base.map( 2473 function() { 2474 this.controller = o; 2475 } 2476 ); 2477 this.base = base; 2478 2479 this.initialize(); 2480 2481 result = true; 2482 } 2483 2484 return result; 2485} 2486 2487// Check - controller is binded to base DOM element or not 2488AController.prototype.isBaseCatched = function(base) 2489{ 2490 var result = false; 2491 2492 if ('undefined' != typeof(base.map)) { 2493 base.map( 2494 function() { 2495 if (!result && typeof(this.controller) != 'undefined') { 2496 result = true; 2497 } 2498 } 2499 ); 2500 2501 } else if (typeof(base.controller) != 'undefined') { 2502 result = true; 2503 } 2504 2505 return result; 2506} 2507 2508// [ABSTRACT] Detect base 2509AController.prototype.detectBase = function() 2510{ 2511 return !!this.findPattern; 2512} 2513 2514// [ABSTRACT] Initialize controller 2515AController.prototype.initialize = function() 2516{ 2517} 2518 2519// Find base if controller create without base DOM element specification 2520AController.prototype.findBase = function() 2521{ 2522 return this.findPattern ? jQuery(this.findPattern) : false; 2523}; 2524/* AUTOGENERATED: xcart.loadable.js */ 2525/* vim: set ts=2 sw=2 sts=2 et: */ 2526 2527/** 2528 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 2529 * See https://www.x-cart.com/license-agreement.html for license details. 2530 */ 2531 2532// Constructor 2533function ALoadable(base) 2534{ 2535 ALoadable.superclass.constructor.apply(this, arguments); 2536 2537 if (base && this.checkBase(jQuery(base))) { 2538 this.basePattern = base; 2539 this.base = jQuery(base); 2540 this.loadHandlerCallback = _.bind(this.loadHandler, this); 2541 this.postprocess(true, true); 2542 2543 if (this.listenToHash && (!jQuery.isEmptyObject(hash.get()))) { 2544 jQuery(document).ready(_.bind(this.loadByHash, this)); 2545 } 2546 2547 if (this.replaceState) { 2548 window.addEventListener( "popstate", function ( event ) { 2549 window.location.reload(true); 2550 }); 2551 } 2552 } 2553} 2554 2555extend(ALoadable, Base); 2556 2557// Base element(s) 2558ALoadable.prototype.base = null; 2559 2560// Base pattern 2561ALoadable.prototype.basePattern = null; 2562 2563// Shade flag 2564ALoadable.prototype.isShowModalScreen = false; 2565 2566// Widget loading flag 2567ALoadable.prototype.isLoading = false; 2568 2569// Widget has deferred load operation 2570ALoadable.prototype.deferredLoad = false; 2571 2572// Preload event custom handler 2573ALoadable.prototype.preloadHandler = null; 2574 2575// Postload event custom handler 2576ALoadable.prototype.postloadHandler = null; 2577 2578ALoadable.prototype.listenToHash = false; 2579 2580ALoadable.prototype.listenToHashPrefix = ''; 2581 2582ALoadable.prototype.replaceState = false; 2583 2584ALoadable.prototype.replaceStatePrefix = ''; 2585 2586 2587// Options 2588 2589// Use shade 2590ALoadable.prototype.shadeWidget = true; 2591 2592// Class for shade overlay 2593ALoadable.prototype.shadeClass = null; 2594 2595// Use widget blocking 2596ALoadable.prototype.blockWidget = true; 2597 2598// Update page title from loaded request or not 2599ALoadable.prototype.updatePageTitle = false; 2600 2601// Update breadcrumb last node from loaded request or not 2602ALoadable.prototype.updateBreadcrumb = false;
2603 2604// Widget target 2605ALoadable.prototype.widgetTarget = null; 2606 2607// Widget parameters 2608ALoadable.prototype.widgetParams = null; 2609 2610// Widget class name 2611ALoadable.prototype.widgetClass = null; 2612 2613// Page title element pattern 2614ALoadable.prototype.titlePattern = 'h1'; 2615 2616// Page title element pattern in request's response data 2617ALoadable.prototype.titleRequestPattern = '.ajax-container-loadable'; 2618 2619// Container element pattern in request's response data 2620ALoadable.prototype.containerRequestPattern = 'div.ajax-container-loadable'; 2621 2622ALoadable.prototype.reloadIfError = true; 2623 2624// Check base 2625ALoadable.prototype.checkBase = function(base) 2626{ 2627 var result = 0 < base.length; 2628 2629 if (result) { 2630 base.map( 2631 function() { 2632 if (result && 'undefined' != typeof(this.loadable)) { 2633 result = false; 2634 } 2635 } 2636 ); 2637 } 2638 2639 return result; 2640} 2641 2642// Load widget 2643ALoadable.prototype.doReplaceState = function(params) { 2644 var o = this, origParams = {}; 2645 2646 window.location.search.substring(1).split('&').forEach(function (v) { 2647 var pair = v.split('='); 2648 2649 if ( 2650 !_.isUndefined(pair[0]) 2651 && !_.isUndefined(pair[1]) 2652 && pair[0] !== o.replaceStatePrefix 2653 ) { 2654 // this condition for 'reset filter' 2655 if (jQuery.isEmptyObject(params) && pair[0].indexOf(o.replaceStatePrefix + '[') == 0) { 2656 return; 2657 } 2658 origParams[pair[0]] = pair[1]; 2659 } 2660 }); 2661 2662 var url = window.location.pathname; 2663 var queryString = ''; 2664 params = array_merge(origParams, params || {}); 2665 2666 $.each(params, function (key, value) { 2667 queryString += '&' + key + '=' + value; 2668 }); 2669 2670 if (queryString) { 2671 url += '?'; 2672 } 2673 url += queryString.substring(1); 2674 2675 window.history.pushState(params, 'Filter', url); 2676}; 2677 2678// Load widget 2679ALoadable.prototype.load = function(params) 2680{ 2681 if (this.replaceState) { 2682 this.doReplaceState(params); 2683 } 2684 2685 if (this.listenToHash) { 2686 hash.add(params); 2687 } 2688 2689 if (!xcart.isRequesterEnabled) { 2690 return false; 2691 } 2692 2693 if (this.isLoading) { 2694 this.deferredLoad = true; 2695 return true; 2696 } 2697 2698 this.isLoading = true; 2699 this.deferredLoad = false; 2700 2701 this.lastLoadParams = params; 2702 2703 var url = this.buildWidgetRequestURL(params); 2704 2705 if (this.base) { 2706 this.base.trigger('preload', [this, url]); 2707 2708 if (typeof(this.preloadHandler) == 'function') { 2709 2710 // Call preload event handler 2711 this.preloadHandler.call(this.base); 2712 } 2713 } 2714 2715 var state = { 'widget': this, 'url': url, 'options': this.getLoaderOptions() } 2716 2717 this.triggerVent('preload', state); 2718 2719 this.saveState(); 2720 2721 this.shade(); 2722 2723 state.xhr = xcart.get(state.url, this.loadHandlerCallback, null, state.options); 2724 2725 this.triggerVent('afterload', state); 2726 2727 return state.xhr; 2728}; 2729 2730// Build request widget URL (AJAX) 2731ALoadable.prototype.buildWidgetRequestURL = function(params) 2732{ 2733 return URLHandler.buildURL(this.getParams(params)); 2734}; 2735 2736// [ABSTRACT] Get additional parameters 2737ALoadable.prototype.getParams = function(params) 2738{ 2739 params = params ? params : {}; 2740 2741 // Set widget target and parameters 2742 if ('undefined' == typeof(params.target) && this.widgetTarget) { 2743 params.target = this.widgetTarget; 2744 } 2745 2746 if (this.widgetParams) { 2747 for (var i in this.widgetParams) { 2748 params[i] = this.widgetParams[i]; 2749 } 2750 } 2751 2752 // TODO remove if it will be no use!! 2753 if ('undefined' == typeof(params.sessionCell) && this.sessionCell) { 2754 params.sessionCell = this.sessionCell; 2755 } 2756 2757 if ('undefined' == typeof(params.action)) { 2758 params.action = ''; 2759 } 2760 2761 if ('undefined' == typeof(params.widget) && this.widgetClass) { 2762 params.widget = this.widgetClass; 2763 } 2764 2765 return params; 2766}; 2767 2768// Loader AJAX options 2769ALoadable.prototype.getLoaderOptions = function() 2770{ 2771 return {}; 2772} 2773 2774ALoadable.prototype.createTemporaryContainer = function(data){ 2775 2776 var container = this.getTemporaryContainer(); 2777 2778 container.html(data); 2779 2780 return container; 2781}; 2782 2783// onload handler 2784ALoadable.prototype.loadHandler = function(xhr, s, data) 2785{ 2786 this.isLoading = false; 2787 2788 this.unshade(); 2789 2790 if (false !== data) { 2791 2792 var container = this.createTemporaryContainer(data); 2793 2794 var uuid = _.uniqueId(); 2795 2796 xcart.bind(['resources.ready', 'resources.empty'], _.bind( 2797 function(event, args){ 2798 if (args.uuid === uuid) { 2799 var content = this.extractRequestData(container); 2800 container.remove(); 2801 if (this.isValidContent(content)) { 2802 var processed = false;
2803 processed = this.placeRequestData(content); 2804 this.finishLoadHandler(processed); 2805 } 2806 } 2807 }, 2808 this) 2809 ); 2810 2811 xcart.parsePreloadedLabels(container, uuid); 2812 xcart.parseResources(container, uuid); 2813 } 2814}; 2815 2816 2817// Check loaded content 2818ALoadable.prototype.finishLoadHandler = function(processed) 2819{ 2820 jQuery(this.base).data('controller', this); 2821 2822 this.postprocess(processed); 2823 2824 if (!this.isLoading && this.deferredLoad) { 2825 this.deferredLoad = false; 2826 this.load(this.lastLoadParams); 2827 2828 } else if (processed) { 2829 if (typeof(this.postloadHandler) == 'function') { 2830 this.postloadHandler.call(this.base, xhr); 2831 } 2832 2833 this.triggerVent('loaded', this); 2834 xcart.trigger('loader.loaded', this); 2835 2836 } else { 2837 2838 this.triggerVent('loadingError', {'widget': this, 'arguments': arguments}); 2839 if (this.reloadIfError) { 2840 setTimeout( 2841 _.bind( 2842 function() { 2843 this.load(this.lastLoadParams); 2844 }, 2845 this 2846 ), 2847 300 2848 ); 2849 } 2850 } 2851} 2852 2853// Check loaded content 2854ALoadable.prototype.isValidContent = function(content) 2855{ 2856 return 0 < jQuery(this.containerRequestPattern, content).length; 2857}; 2858 2859// Get temporary container 2860ALoadable.prototype.getTemporaryContainer = function() 2861{ 2862 var div = document.createElement('DIV'); 2863 div.style.display = 'none'; 2864 jQuery('body').get(0).appendChild(div); 2865 return jQuery(div); 2866}; 2867 2868// Extract widget data 2869ALoadable.prototype.extractRequestData = function(div) 2870{ 2871 div.find('script[type!="text/x-cart-data"]').first().remove(); 2872 return div; 2873}; 2874 2875// Place request data 2876ALoadable.prototype.placeRequestData = function(box) 2877{ 2878 // Update page title 2879 if (this.updatePageTitle || this.updateBreadcrumb) { 2880 this.replacePageTitle(box); 2881 } 2882 2883 box = this.extractContent(box); 2884 2885 //TODO: find any reason to add random class. 2886 var id = 'temporary-ajax-id-' + (new Date()).getTime(); 2887 2888 box.addClass(id); 2889 2890 this.base.trigger('reload', [box]); 2891 2892 if (0 < box.length) { 2893 this.base = this.insertIntoDOM(box); 2894 } else { 2895 this.base.empty(); 2896 } 2897 2898 this.base.removeClass(id); 2899 2900 return true; 2901}; 2902 2903// Extract widget content 2904ALoadable.prototype.extractContent = function(box) 2905{ 2906 box = jQuery(this.containerRequestPattern, box); 2907 if (box.children().eq(0).hasClass('block')) { 2908 box = jQuery('.block', box.eq(0)) 2909 .first() 2910 .find('> .content'); 2911 } 2912 2913 return box.children(); 2914}; 2915 2916// Place parsed request data into DOM 2917ALoadable.prototype.insertIntoDOM = function(box) 2918{ 2919 this.base.replaceWith(box); 2920 return box; 2921}; 2922 2923// Replace page title 2924ALoadable.prototype.replacePageTitle = function(box) 2925{ 2926 var title = jQuery(this.titleRequestPattern, box).eq(0).attr('title'); 2927 if (title) { 2928 this.placeNewPageTitle(title); 2929 } 2930 2931 return title; 2932}; 2933 2934// Place new page title 2935ALoadable.prototype.placeNewPageTitle = function(title) 2936{ 2937 if (this.updatePageTitle) { 2938 jQuery(this.titlePattern).eq(0).html(title); 2939 jQuery("head title").eq(0).html(title); 2940 } 2941 2942 if (this.updateBreadcrumb) { 2943 jQuery('#breadcrumb .last').find('a,span').html(title); 2944 } 2945}; 2946 2947// [ABSTRACT] Widget post processing (after new widget data placing) 2948ALoadable.prototype.postprocess = function(isSuccess, initial) 2949{ 2950 if (isSuccess) { 2951 var o = this; 2952 2953 this.base.map( 2954 function() { 2955 this.loadable = o; 2956 } 2957 ); 2958 2959 if (!initial && 'undefined' != typeof(window.CommonForm)) { 2960 this.base.filter('form').each( 2961 function() { 2962 new CommonForm(this); 2963 } 2964 ); 2965 2966 jQuery('form', this.base).each( 2967 function() { 2968 new CommonForm(this); 2969 } 2970 ); 2971 2972 this.base.filter('*:input').each( 2973 function() { 2974 new CommonElement(this); 2975 } 2976 ); 2977 2978 jQuery('*:input', this.base).each( 2979 function() { 2980 new CommonElement(this); 2981 } 2982 ); 2983 2984 } 2985 } 2986 2987 this.triggerVent('postprocess', {'widget': this, 'isSuccess': isSuccess, 'initial': initial}); 2988}; 2989 2990// Load content by hash 2991ALoadable.prototype.loadByHash = function() 2992{ 2993 if (!this.isHashEqual()) { 2994 this.load(hash.get()); 2995 } 2996}; 2997 2998// Check - has is equal arguments of widget 2999ALoadable.prototype.isHashEqual = function() 3000{ 3001 var result = true; 3002 3003 var current = this.base.data('widget-arguments'); 3004 if (current && hash.get()) { 3005 result = _.every( 3006 hash.get(), 3007 function(v, k) { 3008 return 'undefined' != typeof(current[k]) && current[k] == v; 3009 } 3010 ); 3011 3012 } else if (!current && _.size(hash.get()) > 0) { 3013 result = false;
3014 } 3015 3016 return result; 3017}; 3018 3019// [ABSTRACT] Widget save state (before widget load / reload) 3020ALoadable.prototype.saveState = function() 3021{ 3022}; 3023 3024// Show modal screen 3025ALoadable.prototype.shade = function() 3026{ 3027 if (!this.base || !this.base.length) { 3028 return false; 3029 } 3030 3031 if (this.isShowModalScreen) { 3032 return true; 3033 } 3034 3035 if (this.isShade()) { 3036 var overlay = this.assignWaitOverlay(this.getShadeBase()); 3037 3038 if (this.shadeClass) { 3039 overlay.addClass(this.shadeClass); 3040 } 3041 3042 this.triggerVent('shaded', this); 3043 3044 } else if (this.blockWidget) { 3045 3046 this.base.click(this.blocker).focus(this.blocker); 3047 } 3048 3049 this.isShowModalScreen = true; 3050 3051 return true; 3052}; 3053 3054// Assemble overlay 3055ALoadable.prototype.assignWaitOverlay = function(base) 3056{ 3057 return assignWaitOverlay(base); 3058}; 3059 3060// Unshade widget 3061ALoadable.prototype.unshade = function() 3062{ 3063 if (!this.base || !this.isShowModalScreen || this.isLoading) { 3064 return false; 3065 } 3066 3067 if (_.result(this, 'shadeWidget')) { 3068 this.unassignWaitOverlay(this.getShadeBase()); 3069 this.triggerVent('unshaded', this); 3070 3071 } else if (this.blockWidget) { 3072 this.base.unbind('click', this.blocker).unbind('focus', this.blocker); 3073 } 3074 3075 this.isShowModalScreen = false; 3076 3077 return true; 3078}; 3079 3080ALoadable.prototype.unassignWaitOverlay = function(base) 3081{ 3082 unassignWaitOverlay(base, true); 3083}; 3084 3085ALoadable.prototype.isShade = function() 3086{ 3087 var state = { 3088 widget: this, 3089 result: _.result(this, 'shadeWidget') 3090 }; 3091 3092 this.triggerVent('shade', state); 3093 3094 return state.result; 3095}; 3096 3097// Get base element for shade / unshade operation 3098ALoadable.prototype.getShadeBase = function() { 3099 return this.base; 3100}; 3101 3102// Event blocker 3103ALoadable.prototype.blocker = function(event) { 3104 event.stopPropagation(); 3105 3106 return false; 3107}; 3108 3109// Submit specified form 3110ALoadable.prototype.submitForm = function(form, callback) 3111{ 3112 return form.submitBackground( 3113 callback, 3114 false, 3115 { 3116 rpc: 'POST' == jQuery(form).attr('method').toUpperCase() 3117 } 3118 ); 3119};; 3120/* AUTOGENERATED: xcart.utils.js */ 3121/* vim: set ts=2 sw=2 sts=2 et: */ 3122 3123/** 3124 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 3125 * See https://www.x-cart.com/license-agreement.html for license details. 3126 */ 3127 3128window.xcart.utils = { 3129 3130 /** 3131 * Generates hash from given value using md5 algorithm 3132 * @param mixed value Value to be hased 3133 * @return string MD5 hash of value 3134 */ 3135 hash: function(value) { 3136 return objectHash.MD5(value); 3137 }, 3138 3139 /** 3140 * escape some html entities 3141 * @see select2 Utils.escapeMarkup 3142 * @param string str 3143 * @returns string 3144 */ 3145 escapeString: function (str) { 3146 var replaceMap = { 3147 '\\': '\', 3148 '&': '&', 3149 '<': '<', 3150 '>': '>', 3151 '"': '"', 3152 '\'': ''', 3153 '/': '/' 3154 }; 3155 3156 // Do not try to escape the markup if it's not a string 3157 if (typeof str !== 'string') { 3158 return str; 3159 } 3160 3161 return String(str).replace(/[&<>"'\/\\]/g, function (match) { 3162 return replaceMap[match]; 3163 }); 3164 }, 3165 3166 /** 3167 * Detect SVG width/height. 3168 * 3169 * @param {string} svgContent The content of the SVG image. 3170 * 3171 * @return {{width: number, height: number}} Image width and height, or {width: 0, height: 0} in case anything has 3172 * gone wrong. 3173 */ 3174 getSvgImageSizes: function (svgContent) { 3175 const elem = document.createElement('DIV'); 3176 elem.setAttribute( 3177 'style', 3178 'position:fixed;top:-10000px;left:-10000px;width:3000px;height:3000px;opacity:0;z-index:-1000;pointer-events:none' 3179 ); 3180 document.body.appendChild(elem); 3181 3182 elem.innerHTML = svgContent; 3183 3184 const svg = elem.querySelector('svg'); 3185 let result = { 3186 width: 0, 3187 height: 0 3188 }; 3189 if (svg && svg.getBBox) { 3190 result = svg.getBBox(); 3191 } 3192 document.body.removeChild(elem); 3193 3194 return { 3195 width: Math.round(result.width), 3196 height: Math.round(result.height) 3197 }; 3198 } 3199 3200}; 3201 3202window.await = function (promises, callback) { 3203 jQuery.when.apply(jQuery, promises).done(callback); 3204}; 3205 3206// Shim array.prototype.find for es5 3207if (!Array.prototype.find) { 3208 Object.defineProperty(Array.prototype, "find", { 3209 value: function(predicate) { 3210 if (this === null) { 3211 throw new TypeError('Array.prototype.find called on null or undefined'); 3212 } 3213 if (typeof predicate !== 'function') { 3214 throw new TypeError('predicate must be a function'); 3215 } 3216 var list = Object(this); 3217 var length = list.length >>> 0; 3218 var thisArg = arguments[1]; 3219 var value; 3220 3221 for (var i = 0; i < length; i++) { 3222 value = list[i]; 3223 if (predicate.call(thisArg, value, i, list)) { 3224 return value; 3225 } 3226 } 3227 return undefined; 3228 } 3229 }); 3230}; 3231/* AUTOGENERATED: lazyload.js */ 3232/*jslint browser: true, eqeqeq: true, bitwise: true, newcap: true, immed: true, regexp: false */ 3233 3234/** 3235LazyLoad makes it easy and painless to lazily load one or more external 3236JavaScript or CSS files on demand either during or after the rendering of a web 3237page. 3238 3239Supported browsers include Firefox 3.6+, IE9+, Safari 5.1.4+ (untested) (including Mobile 3240Safari), Google Chrome 10+, and Opera 12+. Other browsers may or may not work and 3241are not officially supported, including the browsers supported by the original LazyLoad: 3242Firefox 2+, IE6+, Safari 3+, Google Chrome 0.8+, and Opera 9+ (not yet tested). 3243 3244Visit https://github.com/lewisje/lazyload/ for more info. 3245 3246Copyright (c) 2011 Ryan Grove <[email protected]> 3247All rights reserved. 3248Changes made by Cezary Daniel Nowak, 2014, and James Edward Lewis II, 2015. 3249 3250Permission is hereby granted, free of charge, to any person obtaining a copy of 3251this software and associated documentation files (the 'Software'), to deal in 3252the Software without restriction, including without limitation the rights to 3253use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of 3254the Software, and to permit persons to whom the Software is furnished to do so, 3255subject to the following conditions: 3256 3257The above copyright notice and this permission notice shall be included in all 3258copies or substantial portions of the Software. 3259 3260THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 3261IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS 3262FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR 3263COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER 3264IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN 3265CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 3266 3267@module lazyload 3268@class LazyLoad 3269@static 3270*/ 3271 3272var LazyLoad = (function (doc) { 3273 'use strict'; 3274 // -- Private Variables ------------------------------------------------------ 3275 3276 // Reference to the <head> element (populated lazily). 3277 var head, 3278 3279 // Requests currently in progress, if any. 3280 pending = {}, 3281 3282 // Number of times we've polled to check whether a pending stylesheet has 3283 // finished loading. If this gets too high, we're probably stalled. 3284 pollCount = 0, 3285 3286 // Cached requests. 3287 cache = {}, 3288 3289 // Queued requests. 3290 queue = {css: [], js: []}, 3291 3292 // Whether Function#bind exists. 3293 canBind = typeof Function.prototype.bind === 'function', 3294 3295 // Reference to the browser's list of stylesheets. 3296 styleSheets = doc.styleSheets, 3297 finishCSS = canBind ? finish.bind(doc, 'css') : function finishCSS() {finish('css');}, 3298 ua = navigator.userAgent, 3299 // User agent and feature test information. 3300 env = { 3301 // True if this browser supports disabling async mode on dynamically 3302 // created script nodes. See 3303 // http://wiki.whatwg.org/wiki/Dynamic_Script_Execution_Order 3304 async: createNode('script').async === true 3305 }; 3306
3307 if (/AppleWebKit\//.test(ua)) env.webkit = true; 3308 else if (/MSIE|Trident/.test(ua)) env.ie = true; 3309 else if (/Opera/.test(ua)) env.opera = true; 3310 else if (/Gecko\//.test(ua)) env.gecko = true; 3311 else env.unknown = true; 3312 // -- Private Methods -------------------------------------------------------- 3313 3314 /** 3315 Creates and returns an HTML element with the specified name and attributes. 3316 3317 @method createNode 3318 @param {String} name element name 3319 @param {Object} attrs name/value mapping of element attributes 3320 @return {HTMLElement} 3321 @private 3322 */ 3323 function createNode(name, attrs) { 3324 var attr, 3325 node = doc.createElement(name); 3326 3327 if(attrs) { 3328 for (attr in attrs) { 3329 if (attrs.hasOwnProperty(attr)) { 3330 node.setAttribute(attr, attrs[attr]); 3331 } 3332 } 3333 } 3334 3335 return node; 3336 } 3337 3338 /** 3339 Called when the current pending resource of the specified type has finished 3340 loading. Executes the associated callback (if any) and loads the next 3341 resource in the queue. 3342 3343 @method finish 3344 @param {String} type resource type ('css' or 'js') 3345 @private 3346 */ 3347 function finish(type) { 3348 var p = pending[type], callback, urls; 3349 3350 if (p) { 3351 callback = p.callback; 3352 urls = p.urls; 3353 3354 cache[urls.shift()] = true; 3355 pollCount = 0; 3356 3357 // If this is the last of the pending URLs, execute the callback and 3358 // start the next request in the queue (if any). 3359 if (!urls.length) { 3360 if (typeof callback === 'function') callback.call(p.context, p.obj); 3361 pending[type] = 0; 3362 if (queue[type].length) load(type); 3363 } 3364 } 3365 } 3366 3367 /** 3368 Loads the specified resources, or the next resource of the specified type 3369 in the queue if no resources are specified. If a resource of the specified 3370 type is already being loaded, the new request will be queued until the 3371 first request has been finished. 3372 3373 When an array of resource URLs is specified, those URLs will be loaded in 3374 parallel if it is possible to do so while preserving execution order. All 3375 browsers support parallel loading of CSS, but only Firefox and Opera 3376 support parallel loading of scripts. In other browsers, scripts will be 3377 queued and loaded one at a time to ensure correct execution order. 3378 3379 @method load 3380 @param {String} type resource type ('css' or 'js') 3381 @param {String|Array} urls (optional) URL or array of URLs to load 3382 @param {Function} callback (optional) callback function to execute when the 3383 resource is loaded 3384 @param {Object} obj (optional) object to pass to the callback function 3385 @param {Object} context (optional) if provided, the callback function will 3386 be executed in this object's context 3387 @private 3388 */ 3389 function load(type, urls, callback, obj, context) { 3390 var _finish = canBind ? finish.bind(doc, type) : function _finish() {finish(type);}, 3391 isCSS = type === 'css', nodes = [], i, len, node, p, pendingUrls, url; 3392 3393 if (urls) { 3394 // If urls is a string, wrap it in an array. Otherwise assume it's an 3395 // array and create a copy of it so modifications won't be made to the 3396 // original. 3397 urls = typeof urls === 'string' ? [urls] : urls.slice(); 3398 3399 // Create a request object for each URL. If multiple URLs are specified, 3400 // the callback will only be executed after all URLs have been loaded. 3401 // 3402 // Sadly, Firefox and Opera are the only browsers capable of loading 3403 // scripts in parallel while preserving execution order. In all other 3404 // browsers, scripts must be loaded sequentially. 3405 // 3406 // All browsers respect CSS specificity based on the order of the link 3407 // elements in the DOM, regardless of the order in which the stylesheets 3408 // are actually downloaded. 3409 if (isCSS || env.async || env.gecko || env.opera) { 3410 // Load in parallel. 3411 queue[type].push({ 3412 urls : urls, 3413 callback: callback, 3414 obj : obj, 3415 context : context 3416 }); 3417 } else { 3418 // Load sequentially. 3419 for (i = 0, len = urls.length; i < len; ++i) { 3420 queue[type].push({ 3421 urls : [urls[i]], 3422 callback: i === len - 1 ? callback : 0, // callback is only added to the last URL 3423 obj : obj, 3424 context : context 3425 }); 3426 } 3427 } 3428 } 3429 3430 // If a previous load request of this type is currently in progress, we'll 3431 // wait our turn. Otherwise, grab the next item in the queue. 3432 if (pending[type] || !(p = pending[type] = queue[type].shift())) return; 3433 head = head || doc.head || doc.getElementsByTagName('head')[0]; 3434 pendingUrls = p.urls.slice(); 3435 3436 var nodeReady = function nodeReady() { 3437 if (/^(?:loaded|complete)$/i.test(node.readyState)) { 3438 node.onreadystatechange = null; 3439 _finish(); 3440 } 3441 }; 3442 for (i = 0, len = pendingUrls.length; i < len; ++i) { 3443 url = pendingUrls[i]; 3444 if(cache[url] != null && !url.startsWith("var/theme/custom.css")) { 3445 // _finish here can cause unexpected behavior when cache[url] === false but 3446 // I won't figure out solution, since first issue on github :-) 3447 _finish(); 3448 continue; //prevent scripts/css from being loaded multiple times 3449 } else { 3450 cache[url] = false;
3451 } 3452 if (isCSS) { 3453 node = env.gecko ? createNode('style') : createNode('link', { 3454 href: url, 3455 rel : 'stylesheet' 3456 }); 3457 } else { 3458 node = createNode('script', {src: url}); 3459 node.async = false; 3460 } 3461 3462 node.className = 'lazyload'; 3463 node.setAttribute('charset', 'utf-8'); 3464 3465 if (env.ie && !isCSS && 'onreadystatechange' in node && !('draggable' in node)) { 3466 node.onreadystatechange = nodeReady; 3467 } else if (isCSS && (env.gecko || env.webkit)) { 3468 // Gecko and WebKit don't support the onload event on link nodes. 3469 if (env.webkit) { 3470 // In WebKit, we can poll for changes to document.styleSheets to 3471 // figure out when stylesheets have loaded. 3472 p.urls[i] = node.href; // resolve relative URLs (or polling won't work) 3473 pollWebKit(); 3474 } else { 3475 // In Gecko, we can import the requested URL into a <style> node and 3476 // poll for the existence of node.sheet.cssRules. Props to Zach 3477 // Leatherman for calling my attention to this technique. 3478 node.innerHTML = '@import "' + url + '";'; 3479 pollGecko(node); 3480 } 3481 } else { 3482 node.onload = node.onerror = _finish; 3483 } 3484 nodes.push(node); 3485 } 3486 for (i = 0, len = nodes.length; i < len; ++i) { 3487 head.appendChild(nodes[i]); 3488 } 3489 } 3490 3491 /** 3492 Begins polling to determine when the specified stylesheet has finished loading 3493 in Gecko. Polling stops when all pending stylesheets have loaded or after 10 3494 seconds (to prevent stalls). 3495 3496 Thanks to Zach Leatherman for calling my attention to the @import-based 3497 cross-domain technique used here, and to Oleg Slobodskoi for an earlier 3498 same-domain implementation. See Zach's blog for more details: 3499 http://www.zachleat.com/web/2010/07/29/load-css-dynamically/ 3500 3501 @method pollGecko 3502 @param {HTMLElement} node Style node to poll. 3503 @private 3504 */ 3505 function pollGecko(node) { 3506 var hasRules = 'sheet' in node && node.sheet && 'cssRules' in node.sheet; 3507 3508 if (!hasRules) { 3509 // The stylesheet is still loading. 3510 ++pollCount; 3511 if (pollCount < 200) { 3512 setTimeout(canBind ? pollGecko.bind(doc, node) : function pollBind() {pollGecko(node);}, 50); 3513 } else { 3514 // We've been polling for 10 seconds and nothing's happened. Stop 3515 // polling and finish the pending requests to avoid blocking further 3516 // requests. 3517 if (hasRules) finishCSS(); 3518 } 3519 return; 3520 } 3521 // If we get here, the stylesheet has loaded. 3522 finishCSS(); 3523 } 3524 3525 /** 3526 Begins polling to determine when pending stylesheets have finished loading 3527 in WebKit. Polling stops when all pending stylesheets have loaded or after 10 3528 seconds (to prevent stalls). 3529 3530 @method pollWebKit 3531 @private 3532 */ 3533 function pollWebKit() { 3534 var css = pending.css, i; 3535 3536 if (css) { 3537 i = styleSheets.length; 3538 // Look for a stylesheet matching the pending URL. 3539 while (--i >= 0) { 3540 if (styleSheets[i].href === css.urls[0]) { 3541 finishCSS(); 3542 break; 3543 } 3544 } 3545 3546 ++pollCount; 3547 if (css) { 3548 if (pollCount < 200) { 3549 setTimeout(pollWebKit, 50); 3550 } else { 3551 // We've been polling for 10 seconds and nothing's happened, which may 3552 // indicate that the stylesheet has been removed from the document 3553 // before it had a chance to load. Stop polling and finish the pending 3554 // request to prevent blocking further requests. 3555 finishCSS(); 3556 } 3557 } 3558 } 3559 } 3560 3561 return { 3562 /** 3563 Requests the specified CSS URL or URLs and executes the specified 3564 callback (if any) when they have finished loading. If an array of URLs is 3565 specified, the stylesheets will be loaded in parallel and the callback 3566 will be executed after all stylesheets have finished loading. 3567 3568 @method css 3569 @param {String|Array} urls CSS URL or array of CSS URLs to load 3570 @param {Function} callback (optional) callback function to execute when 3571 the specified stylesheets are loaded 3572 @static 3573 */ 3574 css: canBind ? load.bind(load, 'css') : function css(urls, callback, obj, context) { 3575 load('css', urls, callback, obj, context); 3576 }, 3577 3578 /** 3579 Requests the specified JavaScript URL or URLs and executes the specified 3580 callback (if any) when they have finished loading. If an array of URLs is 3581 specified and the browser supports it, the scripts will be loaded in 3582 parallel and the callback will be executed after all scripts have 3583 finished loading. 3584
3585 Currently, only Firefox and Opera support parallel loading of scripts while 3586 preserving execution order. In other browsers, scripts will be 3587 queued and loaded one at a time to ensure correct execution order. 3588 3589 @method js 3590 @param {String|Array} urls JS URL or array of JS URLs to load 3591 @param {Function} callback (optional) callback function to execute when 3592 the specified scripts are loaded 3593 @static 3594 */ 3595 js: canBind ? load.bind(load, 'js') : function js(urls, callback, obj, context) { 3596 load('js', urls, callback, obj, context); 3597 } 3598 }; 3599})(this.document);; 3600/* AUTOGENERATED: json5.min.js */ 3601!function(u,D){"object"==typeof exports&&"undefined"!=typeof module?module.exports=D():"function"==typeof define&&define.amd?define(D):u.JSON5=D()}(this,function(){"use strict";var u={Space_Separator:/[\u1680\u2000-\u200A\u202F\u205F\u3000]/,ID_Start:/[\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u0860-\u086A\u08A0-\u08B4\u08B6-\u08BD\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0980\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u09FC\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0AF9\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D\u0C58-\u0C5A\u0C60\u0C61\u0C80\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D3A\u0D3D\u0D4E\u0D54-\u0D56\u0D5F-\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u170C\u170E-\u1711\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7\u17DC\u1820-\u1877\u1880-\u1884\u1887-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191E\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u1A00-\u1A16\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1C80-\u1C88\u1CE9-\u1CEC\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005-\u3007\u3021-\u3029\u3031-\u3035\u3038-\u303C\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312E\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FEA\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B\uA640-\uA66E\uA67F-\uA69D\uA6A0-\uA6EF\uA717-\uA71F\uA722-\uA788\uA78B-\uA7AE\uA7B0-\uA7B7\uA7F7-\uA801\uA803-\uA805\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB\uA8FD\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uA9E0-\uA9E4\uA9E6-\uA9EF\uA9FA-\uA9FE\uAA00-\uAA28\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA7E-\uAAAF\uAAB1\uAAB5\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB65\uAB70-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFB
3601D3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]|\uD800[\uDC00-\uDC0B\uDC0D-\uDC26\uDC28-\uDC3A\uDC3C\uDC3D\uDC3F-\uDC4D\uDC50-\uDC5D\uDC80-\uDCFA\uDD40-\uDD74\uDE80-\uDE9C\uDEA0-\uDED0\uDF00-\uDF1F\uDF2D-\uDF4A\uDF50-\uDF75\uDF80-\uDF9D\uDFA0-\uDFC3\uDFC8-\uDFCF\uDFD1-\uDFD5]|\uD801[\uDC00-\uDC9D\uDCB0-\uDCD3\uDCD8-\uDCFB\uDD00-\uDD27\uDD30-\uDD63\uDE00-\uDF36\uDF40-\uDF55\uDF60-\uDF67]|\uD802[\uDC00-\uDC05\uDC08\uDC0A-\uDC35\uDC37\uDC38\uDC3C\uDC3F-\uDC55\uDC60-\uDC76\uDC80-\uDC9E\uDCE0-\uDCF2\uDCF4\uDCF5\uDD00-\uDD15\uDD20-\uDD39\uDD80-\uDDB7\uDDBE\uDDBF\uDE00\uDE10-\uDE13\uDE15-\uDE17\uDE19-\uDE33\uDE60-\uDE7C\uDE80-\uDE9C\uDEC0-\uDEC7\uDEC9-\uDEE4\uDF00-\uDF35\uDF40-\uDF55\uDF60-\uDF72\uDF80-\uDF91]|\uD803[\uDC00-\uDC48\uDC80-\uDCB2\uDCC0-\uDCF2]|\uD804[\uDC03-\uDC37\uDC83-\uDCAF\uDCD0-\uDCE8\uDD03-\uDD26\uDD50-\uDD72\uDD76\uDD83-\uDDB2\uDDC1-\uDDC4\uDDDA\uDDDC\uDE00-\uDE11\uDE13-\uDE2B\uDE80-\uDE86\uDE88\uDE8A-\uDE8D\uDE8F-\uDE9D\uDE9F-\uDEA8\uDEB0-\uDEDE\uDF05-\uDF0C\uDF0F\uDF10\uDF13-\uDF28\uDF2A-\uDF30\uDF32\uDF33\uDF35-\uDF39\uDF3D\uDF50\uDF5D-\uDF61]|\uD805[\uDC00-\uDC34\uDC47-\uDC4A\uDC80-\uDCAF\uDCC4\uDCC5\uDCC7\uDD80-\uDDAE\uDDD8-\uDDDB\uDE00-\uDE2F\uDE44\uDE80-\uDEAA\uDF00-\uDF19]|\uD806[\uDCA0-\uDCDF\uDCFF\uDE00\uDE0B-\uDE32\uDE3A\uDE50\uDE5C-\uDE83\uDE86-\uDE89\uDEC0-\uDEF8]|\uD807[\uDC00-\uDC08\uDC0A-\uDC2E\uDC40\uDC72-\uDC8F\uDD00-\uDD06\uDD08\uDD09\uDD0B-\uDD30\uDD46]|\uD808[\uDC00-\uDF99]|\uD809[\uDC00-\uDC6E\uDC80-\uDD43]|[\uD80C\uD81C-\uD820\uD840-\uD868\uD86A-\uD86C\uD86F-\uD872\uD874-\uD879][\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2E]|\uD811[\uDC00-\uDE46]|\uD81A[\uDC00-\uDE38\uDE40-\uDE5E\uDED0-\uDEED\uDF00-\uDF2F\uDF40-\uDF43\uDF63-\uDF77\uDF7D-\uDF8F]|\uD81B[\uDF00-\uDF44\uDF50\uDF93-\uDF9F\uDFE0\uDFE1]|\uD821[\uDC00-\uDFEC]|\uD822[\uDC00-\uDEF2]|\uD82C[\uDC00-\uDD1E\uDD70-\uDEFB]|\uD82F[\uDC00-\uDC6A\uDC70-\uDC7C\uDC80-\uDC88\uDC90-\uDC99]|\uD835[\uDC00-\uDC54\uDC56-\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDEA5\uDEA8-\uDEC0\uDEC2-\uDEDA\uDEDC-\uDEFA\uDEFC-\uDF14\uDF16-\uDF34\uDF36-\uDF4E\uDF50-\uDF6E\uDF70-\uDF88\uDF8A-\uDFA8\uDFAA-\uDFC2\uDFC4-\uDFCB]|\uD83A[\uDC00-\uDCC4\uDD00-\uDD43]|\uD83B[\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB]|\uD869[\uDC00-\uDED6\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF34\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEA1\uDEB0-\uDFFF]|\uD87A[\uDC00-\uDFE0]|\uD87E[\uDC00-\uDE1D]/,ID_Continue:/[\xAA\xB5\xBA\xC0-\xD6\xD8-\xF6\xF8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0300-\u0374\u0376\u0377\u037A-\u037D\u037F\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5\u03F7-\u0481\u0483-\u0487\u048A-\u052F\u0531-\u0556\u0559\u0561-\u0587\u0591-\u05BD\u05BF\u05C1\u05C2\u05C4\u05C5\u05C7\u05D0-\u05EA\u05F0-\u05F2\u0610-\u061A\u0620-\u0669\u066E-\u06D3\u06D5-\u06DC\u06DF-\u06E8\u06EA-\u06FC\u06FF\u0710-\u074A\u074D-\u07B1\u07C0-\u07F5\u07FA\u0800-\u082D\u0840-\u085B\u0860-\u086A\u08A0-\u08B4\u08B6-\u08BD\u08D4-\u08E1\u08E3-\u0963\u0966-\u096F\u0971-\u0983\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2\u09B6-\u09B9\u09BC-\u09C4\u09C7\u09C8\u09CB-\u09CE\u09D7\u09DC\u09DD\u09DF-\u09E3\u09E6-\u09F1\u09FC\u0A01-\u0A03\u0A05-\u0A0A\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39\u0A3C\u0A3E-\u0A42\u0A47\u0A48\u0A4B-\u0A4D\u0A51\u0A59-\u0A5C\u0A5E\u0A66-\u0A75\u0A81-\u0A83\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABC-\u0AC5\u0AC7-\u0AC9\u0ACB-\u0ACD\u0AD0\u0AE0-\u0AE3\u0AE6-\u0AEF\u0AF9-\u0AFF\u0B01-\u0B03\u0B05-\u0B0C\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3C-\u0B44\u0B47\u0B48\u0B4B-\u0B4D\u0B56\u0B57\u0B5C\u0B5D\u0B5F-\u0B63\u0B66-\u0B6F\u0B71\u0B82\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BBE-\u0BC2\u0BC6-\u0BC8\u0BCA-\u0BCD\u0BD0\u0BD7\u0BE6-\u0BEF\u0C00-\u0C03\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C39\u0C3D-\u0C44\u0C46-\u0C48\u0C4A-\u0C4D\u0C55\u0C56\u0C58-\u0C5A\u0C60-\u0C63\u0C66-\u0C6F\u0C80-\u0C83\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3\u0CB5-\u0CB9\u0CBC-\u0CC4\u0CC6-\u0CC8\u0CCA-\u0CCD\u0CD5\u0CD6\u0CDE\u0CE0-\u0CE3\u0CE6-\u0CEF\u0CF1\u0CF2\u0D00-\u0D03\u0D05-\u0D0C\u0D0E-\u0D10\u0D12-\u0D44\u0D46-\u0D48\u0D4A-\u0D4E\u0D54-\u0D57\u0D5F-\u0D63\u0D66-\u0D6F\u0D7A-\u0D7F\u0D82\u0D83\u0D85-\u0D96\u0D9A-\u0DB1\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0DCA\u0DCF-\u0DD4\u0DD6\u0DD8-\u0DDF\u0DE6-\u0DEF\u0DF2\u0DF3\u0E01-\u0E3A\u0E40-\u0E4E\u0E50-\u0E59\u0E81\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB9\u0EBB-\u0EBD\u0EC0-\u0EC4\u0EC6\u0EC8-\u0ECD\u0ED0-\u0ED9\u0EDC-\u0EDF\u0F00\u0F18\u0F19\u0F20-\u0F29\u0F35\u0F37\u0F39\u0F3E-\u0F47\u0F49-\u0F6C\u0F71-\u0F84\u0F86-\u0F97\u0F99-\u0FBC\u0FC6\u1000-\u1049\u1050-\u109D\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310\u1312-\u1315\u1318-\u135A\u135D-\u135F\u1380-\u138F\u13A0-\u13F5\u13F8-\u13FD\u1401-\u166C\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u16EE-\u16F8\u1700-\u170C\u170E-\u1714\u1720-\u1734\u1740-\u1753\u1760-\u176C\u176E-\u1770\u1772\u1773\u1780-\u17D3\u17D7\u17DC\u17DD\u17E0-\u17E9\u180B-\u180D\u1810-\u1819\u1820-\u1877\u1880-\u18AA\u18B0-\u18F5\u1900-\u191E\u1920-\u192B\u1930-\u193B\u1946-\u196D\u1970-\u1974\u1980-\u19AB\u19B0-\u19C9\u19D0-\u19D9\u1A00-\u1A1B\u1A20-\u1A5E\u1A60-\u1A7C\u1A7F-\u1A89\u1A90-\u1A99\u1AA7\u1AB0-\u1ABD\u1B00-\u1B4B\u1B50-\u1B59\u1B6B-\u1B73\u1B80-\u1BF3\u1C00-\u1C37\u1C40-\u1C49\u1C4D-\u1C7D\u1C80-\u1C88\u1CD0-\u1CD2\u1CD4-\u1CF9\u1D00-\u1DF9\u1DFB-\u1F15\u1F18-\u1F1D\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u203F\u2040\u2054\u2071\u207F\u2090-\u209C\u20D0-\u20DC\u20E1\u20E5-\u20F0\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2160-\u2188\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CF3\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D7F-\u2D96\u2DA0-\u2DA6\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE\u2DD0-\u2DD6\u2DD8-\u2DDE\u2DE0-\u2DFF\u2E2F\u3005-\u3007\u3021-\u302F\u3031-\u3035\u3038-\u303C\u3041-\u3096\u3099\u309A\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312E\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FEA\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA62B\uA640-\uA66F\uA674-\uA67D\uA67F-\uA6F1\uA717-\uA71F\uA722-\uA788\uA78B-\uA7AE\uA7B0-\uA7B7\uA7F7-\uA827\uA840-\uA873\uA880-\uA8C5\uA8D0-\uA8D9\uA8E0-\uA8F7\uA8FB\uA8FD\uA900-\uA92D\uA930-\uA953\uA960-\uA97C\uA980-\uA9C0\uA9CF-\uA9D9\uA9E0-\uA9FE\uAA00-\uAA36\uAA40-\uAA4D\uAA50-\uAA59\uAA60-\uAA76\uAA7A-\uAAC2\uAADB-\uAADD\uAAE0-\uAAEF\uAAF2-\uAAF6\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E\uAB30-\uAB5A\uAB5C-\uAB65\uAB70-\uABEA\uABEC\uABED\uABF0-\uABF9\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D-\uFB28\uFB2A-\uFB36\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFB
3601D3-\uFD3D\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE00-\uFE0F\uFE20-\uFE2F\uFE33\uFE34\uFE4D-\uFE4F\uFE70-\uFE74\uFE76-\uFEFC\uFF10-\uFF19\uFF21-\uFF3A\uFF3F\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF\uFFD2-\uFFD7\uFFDA-\uFFDC]|\uD800[\uDC00-\uDC0B\uDC0D-\uDC26\uDC28-\uDC3A\uDC3C\uDC3D\uDC3F-\uDC4D\uDC50-\uDC5D\uDC80-\uDCFA\uDD40-\uDD74\uDDFD\uDE80-\uDE9C\uDEA0-\uDED0\uDEE0\uDF00-\uDF1F\uDF2D-\uDF4A\uDF50-\uDF7A\uDF80-\uDF9D\uDFA0-\uDFC3\uDFC8-\uDFCF\uDFD1-\uDFD5]|\uD801[\uDC00-\uDC9D\uDCA0-\uDCA9\uDCB0-\uDCD3\uDCD8-\uDCFB\uDD00-\uDD27\uDD30-\uDD63\uDE00-\uDF36\uDF40-\uDF55\uDF60-\uDF67]|\uD802[\uDC00-\uDC05\uDC08\uDC0A-\uDC35\uDC37\uDC38\uDC3C\uDC3F-\uDC55\uDC60-\uDC76\uDC80-\uDC9E\uDCE0-\uDCF2\uDCF4\uDCF5\uDD00-\uDD15\uDD20-\uDD39\uDD80-\uDDB7\uDDBE\uDDBF\uDE00-\uDE03\uDE05\uDE06\uDE0C-\uDE13\uDE15-\uDE17\uDE19-\uDE33\uDE38-\uDE3A\uDE3F\uDE60-\uDE7C\uDE80-\uDE9C\uDEC0-\uDEC7\uDEC9-\uDEE6\uDF00-\uDF35\uDF40-\uDF55\uDF60-\uDF72\uDF80-\uDF91]|\uD803[\uDC00-\uDC48\uDC80-\uDCB2\uDCC0-\uDCF2]|\uD804[\uDC00-\uDC46\uDC66-\uDC6F\uDC7F-\uDCBA\uDCD0-\uDCE8\uDCF0-\uDCF9\uDD00-\uDD34\uDD36-\uDD3F\uDD50-\uDD73\uDD76\uDD80-\uDDC4\uDDCA-\uDDCC\uDDD0-\uDDDA\uDDDC\uDE00-\uDE11\uDE13-\uDE37\uDE3E\uDE80-\uDE86\uDE88\uDE8A-\uDE8D\uDE8F-\uDE9D\uDE9F-\uDEA8\uDEB0-\uDEEA\uDEF0-\uDEF9\uDF00-\uDF03\uDF05-\uDF0C\uDF0F\uDF10\uDF13-\uDF28\uDF2A-\uDF30\uDF32\uDF33\uDF35-\uDF39\uDF3C-\uDF44\uDF47\uDF48\uDF4B-\uDF4D\uDF50\uDF57\uDF5D-\uDF63\uDF66-\uDF6C\uDF70-\uDF74]|\uD805[\uDC00-\uDC4A\uDC50-\uDC59\uDC80-\uDCC5\uDCC7\uDCD0-\uDCD9\uDD80-\uDDB5\uDDB8-\uDDC0\uDDD8-\uDDDD\uDE00-\uDE40\uDE44\uDE50-\uDE59\uDE80-\uDEB7\uDEC0-\uDEC9\uDF00-\uDF19\uDF1D-\uDF2B\uDF30-\uDF39]|\uD806[\uDCA0-\uDCE9\uDCFF\uDE00-\uDE3E\uDE47\uDE50-\uDE83\uDE86-\uDE99\uDEC0-\uDEF8]|\uD807[\uDC00-\uDC08\uDC0A-\uDC36\uDC38-\uDC40\uDC50-\uDC59\uDC72-\uDC8F\uDC92-\uDCA7\uDCA9-\uDCB6\uDD00-\uDD06\uDD08\uDD09\uDD0B-\uDD36\uDD3A\uDD3C\uDD3D\uDD3F-\uDD47\uDD50-\uDD59]|\uD808[\uDC00-\uDF99]|\uD809[\uDC00-\uDC6E\uDC80-\uDD43]|[\uD80C\uD81C-\uD820\uD840-\uD868\uD86A-\uD86C\uD86F-\uD872\uD874-\uD879][\uDC00-\uDFFF]|\uD80D[\uDC00-\uDC2E]|\uD811[\uDC00-\uDE46]|\uD81A[\uDC00-\uDE38\uDE40-\uDE5E\uDE60-\uDE69\uDED0-\uDEED\uDEF0-\uDEF4\uDF00-\uDF36\uDF40-\uDF43\uDF50-\uDF59\uDF63-\uDF77\uDF7D-\uDF8F]|\uD81B[\uDF00-\uDF44\uDF50-\uDF7E\uDF8F-\uDF9F\uDFE0\uDFE1]|\uD821[\uDC00-\uDFEC]|\uD822[\uDC00-\uDEF2]|\uD82C[\uDC00-\uDD1E\uDD70-\uDEFB]|\uD82F[\uDC00-\uDC6A\uDC70-\uDC7C\uDC80-\uDC88\uDC90-\uDC99\uDC9D\uDC9E]|\uD834[\uDD65-\uDD69\uDD6D-\uDD72\uDD7B-\uDD82\uDD85-\uDD8B\uDDAA-\uDDAD\uDE42-\uDE44]|\uD835[\uDC00-\uDC54\uDC56-\uDC9C\uDC9E\uDC9F\uDCA2\uDCA5\uDCA6\uDCA9-\uDCAC\uDCAE-\uDCB9\uDCBB\uDCBD-\uDCC3\uDCC5-\uDD05\uDD07-\uDD0A\uDD0D-\uDD14\uDD16-\uDD1C\uDD1E-\uDD39\uDD3B-\uDD3E\uDD40-\uDD44\uDD46\uDD4A-\uDD50\uDD52-\uDEA5\uDEA8-\uDEC0\uDEC2-\uDEDA\uDEDC-\uDEFA\uDEFC-\uDF14\uDF16-\uDF34\uDF36-\uDF4E\uDF50-\uDF6E\uDF70-\uDF88\uDF8A-\uDFA8\uDFAA-\uDFC2\uDFC4-\uDFCB\uDFCE-\uDFFF]|\uD836[\uDE00-\uDE36\uDE3B-\uDE6C\uDE75\uDE84\uDE9B-\uDE9F\uDEA1-\uDEAF]|\uD838[\uDC00-\uDC06\uDC08-\uDC18\uDC1B-\uDC21\uDC23\uDC24\uDC26-\uDC2A]|\uD83A[\uDC00-\uDCC4\uDCD0-\uDCD6\uDD00-\uDD4A\uDD50-\uDD59]|\uD83B[\uDE00-\uDE03\uDE05-\uDE1F\uDE21\uDE22\uDE24\uDE27\uDE29-\uDE32\uDE34-\uDE37\uDE39\uDE3B\uDE42\uDE47\uDE49\uDE4B\uDE4D-\uDE4F\uDE51\uDE52\uDE54\uDE57\uDE59\uDE5B\uDE5D\uDE5F\uDE61\uDE62\uDE64\uDE67-\uDE6A\uDE6C-\uDE72\uDE74-\uDE77\uDE79-\uDE7C\uDE7E\uDE80-\uDE89\uDE8B-\uDE9B\uDEA1-\uDEA3\uDEA5-\uDEA9\uDEAB-\uDEBB]|\uD869[\uDC00-\uDED6\uDF00-\uDFFF]|\uD86D[\uDC00-\uDF34\uDF40-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEA1\uDEB0-\uDFFF]|\uD87A[\uDC00-\uDFE0]|\uD87E[\uDC00-\uDE1D]|\uDB40[\uDD00-\uDDEF]/},D={isSpaceSeparator:D=>u.Space_Separator.test(D),isIdStartChar:D=>D>="a"&&D<="z"||D>="A"&&D<="Z"||"$"===D||"_"===D||u.ID_Start.test(D),isIdContinueChar:D=>D>="a"&&D<="z"||D>="A"&&D<="Z"||D>="0"&&D<="9"||"$"===D||"_"===D||"â"===D||"â"===D||u.ID_Continue.test(D),isDigit:u=>/[0-9]/.test(u),isHexDigit:u=>/[0-9A-Fa-f]/.test(u)};let F,e,C,A,E,t,r,n,i;let B,a,o,c,s;function f(){for(B="default",a="",o=!1,c=1;;){s=l();const u=h[B]();if(u)return u}}function l(){if(F[A])return String.fromCodePoint(F.codePointAt(A))}function d(){const u=l();return"\n"===u?(E++,t=0):u?t+=u.length:t++,u&&(A+=u.length),u}const h={default(){switch(s){case"\t":case"\v":case"\f":case" ":case" ":case"\ufeff":case"\n":case"\r":case"\u2028":case"\u2029":return void d();case"/":return d(),void(B="comment");case void 0:return d(),m("eof")}
vendor: 4,211 bytes, line 3601
3601if(!D.isSpaceSeparator(s))return h[e]();d()},comment(){switch(s){case"*":return d(),void(B="multiLineComment");case"/":return d(),void(B="singleLineComment")}throw b(d())},multiLineComment(){switch(s){case"*":return d(),void(B="multiLineCommentAsterisk");case void 0:throw b(d())}d()},multiLineCommentAsterisk(){switch(s){case"*":return void d();case"/":return d(),void(B="default");case void 0:throw b(d())}d(),B="multiLineComment"},singleLineComment(){switch(s){case"\n":case"\r":case"\u2028":case"\u2029":return d(),void(B="default");case void 0:return d(),m("eof")}d()},value(){switch(s){case"{":case"[":return m("punctuator",d());case"n":return d(),p("ull"),m("null",null);case"t":return d(),p("rue"),m("boolean",!0);case"f":return d(),p("alse"),m("boolean",!1);case"-":case"+":return"-"===d()&&(c=-1),void(B="sign");case".":return a=d(),void(B="decimalPointLeading");case"0":return a=d(),void(B="zero");case"1":case"2":case"3":case"4":case"5":case"6":case"7":case"8":case"9":return a=d(),void(B="decimalInteger");case"I":return d(),p("nfinity"),m("numeric",1/0);case"N":return d(),p("aN"),m("numeric",NaN);case'"':case"'":return o='"'===d(),a="",void(B="string")}throw b(d())},identifierNameStartEscape(){if("u"!==s)throw b(d());d();const u=v();switch(u){case"$":case"_":break;default:if(!D.isIdStartChar(u))throw S()}a+=u,B="identifierName"},identifierName(){switch(s){case"$":case"_":case"â":case"â":return void(a+=d());case"\\":return d(),void(B="identifierNameEscape")}if(!D.isIdContinueChar(s))return m("identifier",a);a+=d()},identifierNameEscape(){if("u"!==s)throw b(d());d();const u=v();switch(u){case"$":case"_":case"â":case"â":break;default:if(!D.isIdContinueChar(u))throw S()}a+=u,B="identifierName"},sign(){switch(s){case".":return a=d(),void(B="decimalPointLeading");case"0":return a=d(),void(B="zero");case"1":case"2":case"3":case"4":case"5":case"6":case"7":case"8":case"9":return a=d(),void(B="decimalInteger");case"I":return d(),p("nfinity"),m("numeric",c*(1/0));case"N":return d(),p("aN"),m("numeric",NaN)}throw b(d())},zero(){switch(s){case".":return a+=d(),void(B="decimalPoint");case"e":case"E":return a+=d(),void(B="decimalExponent");case"x":case"X":return a+=d(),void(B="hexadecimal")}return m("numeric",0*c)},decimalInteger(){switch(s){case".":return a+=d(),void(B="decimalPoint");case"e":case"E":return a+=d(),void(B="decimalExponent")}if(!D.isDigit(s))return m("numeric",c*Number(a));a+=d()},decimalPointLeading(){if(D.isDigit(s))return a+=d(),void(B="decimalFraction");throw b(d())},decimalPoint(){switch(s){case"e":case"E":return a+=d(),void(B="decimalExponent")}return D.isDigit(s)?(a+=d(),void(B="decimalFraction")):m("numeric",c*Number(a))},decimalFraction(){switch(s){case"e":case"E":return a+=d(),void(B="decimalExponent")}if(!D.isDigit(s))return m("numeric",c*Number(a));a+=d()},decimalExponent(){switch(s){case"+":case"-":return a+=d(),void(B="decimalExponentSign")}if(D.isDigit(s))return a+=d(),void(B="decimalExponentInteger");throw b(d())},decimalExponentSign(){if(D.isDigit(s))return a+=d(),void(B="decimalExponentInteger");throw b(d())},decimalExponentInteger(){if(!D.isDigit(s))return m("numeric",c*Number(a));a+=d()},hexadecimal(){if(D.isHexDigit(s))return a+=d(),void(B="hexadecimalInteger");throw b(d())},hexadecimalInteger(){if(!D.isHexDigit(s))return m("numeric",c*Number(a));a+=d()},string(){switch(s){case"\\":return d(),void(a+=function(){switch(l()){case"b":return d(),"\b";case"f":return d(),"\f";case"n":return d(),"\n";case"r":return d(),"\r";case"t":return d(),"\t";case"v":return d(),"\v";case"0":if(d(),D.isDigit(l()))throw b(d());return"\0";case"x":return d(),function(){let u="",F=l();if(!D.isHexDigit(F))throw b(d());if(u+=d(),F=l(),!D.isHexDigit(F))throw b(d());return u+=d(),String.fromCodePoint(parseInt(u,16))}();case"u":return d(),v();case"\n":case"\u2028":case"\u2029":return d(),"";case"\r":return d(),"\n"===l()&&d(),"";case"1":case"2":case"3":case"4":case"5":case"6":case"7":case"8":case"9":case void 0:throw b(d())}return d()}());case'"':return o?(d(),m("string",a)):void(a+=d());case"'":return o?void(a+=d()):(d(),m("string",a));case"\n":case"\r":throw b(d());case"\u2028":case"\u2029":!function(u){console.warn(`JSON5: '${x(u)}
3601' in strings is not valid ECMAScript; consider escaping`)}(s);break;case void 0:throw b(d())}a+=d()},start(){switch(s){case"{":case"[":return m("punctuator",d())}B="value"},beforePropertyName(){switch(s){case"$":case"_":return a=d(),void(B="identifierName");case"\\":return d(),void(B="identifierNameStartEscape");case"}":return m("punctuator",d());case'"':case"'":return o='"'===d(),void(B="string")}if(D.isIdStartChar(s))return a+=d(),void(B="identifierName");throw b(d())},afterPropertyName(){if(":"===s)return m("punctuator",d());throw b(d())},beforePropertyValue(){B="value"},afterPropertyValue(){switch(s){case",":case"}":return m("punctuator",d())}throw b(d())},beforeArrayValue(){if("]"===s)return m("punctuator",d());B="value"},afterArrayValue(){switch(s){case",":case"]":return m("punctuator",d())}throw b(d())},end(){throw b(d())}};function m(u,D){return{type:u,value:D,line:E,column:t}}function p(u){for(const D of u){if(l()!==D)throw b(d());d()}}function v(){let u="",F=4;for(;F-- >0;){const F=l();if(!D.isHexDigit(F))throw b(d());u+=d()}return String.fromCodePoint(parseInt(u,16))}const g={start(){if("eof"===r.type)throw N();y()},beforePropertyName(){switch(r.type){case"identifier":case"string":return n=r.value,void(e="afterPropertyName");case"punctuator":return void w();case"eof":throw N()}},afterPropertyName(){if("eof"===r.type)throw N();e="beforePropertyValue"},beforePropertyValue(){if("eof"===r.type)throw N();y()},beforeArrayValue(){if("eof"===r.type)throw N();"punctuator"!==r.type||"]"!==r.value?y():w()},afterPropertyValue(){if("eof"===r.type)throw N();switch(r.value){case",":return void(e="beforePropertyName");case"}":w()}},afterArrayValue(){if("eof"===r.type)throw N();switch(r.value){case",":return void(e="beforeArrayValue");case"]":w()}},end(){}};function y(){let u;switch(r.type){case"punctuator":switch(r.value){case"{":u={};break;case"[":u=[]}break;case"null":case"boolean":case"numeric":case"string":u=r.value}if(void 0===i)i=u;else{const D=C[C.length-1];Array.isArray(D)?D.push(u):D[n]=u}if(null!==u&&"object"==typeof u)C.push(u),e=Array.isArray(u)?"beforeArrayValue":"beforePropertyName";else{const u=C[C.length-1];e=null==u?"end":Array.isArray(u)?"afterArrayValue":"afterPropertyValue"}}function w(){C.pop();const u=C[C.length-1];e=null==u?"end":Array.isArray(u)?"afterArrayValue":"afterPropertyValue"}function b(u){return P(void 0===u?`JSON5: invalid end of input at ${E}:${t}`:`JSON5: invalid character '${x(u)}' at ${E}:${t}`)}function N(){return P(`JSON5: invalid end of input at ${E}:${t}`)}function S(){return P(`JSON5: invalid identifier character at ${E}:${t-=5}`)}function x(u){const D={"'":"\\'",'"':'\\"',"\\":"\\\\","\b":"\\b","\f":"\\f","\n":"\\n","\r":"\\r","\t":"\\t","\v":"\\v","\0":"\\0","\u2028":"\\u2028","\u2029":"\\u2029"};if(D[u])return D[u];if(u<" "){const D=u.charCodeAt(0).toString(16);return"\\x"+("00"+D).substring(D.length)}return u}function P(u){const D=new SyntaxError(u);return D.lineNumber=E,D.columnNumber=t,D}return{parse:function(u,D){F=String(u),e="start",C=[],A=0,E=1,t=0,r=void 0,n=void 0,i=void 0;do{r=f(),g[e]()}while("eof"!==r.type);return"function"==typeof D?function u(D,F,e){const C=D[F];if(null!=C&&"object"==typeof C)for(const D in C){const F=u(C,D,e);void 0===F?delete C[D]:C[D]=F}return e.call(D,F,C)}({"":i},"",D):i},stringify:function(u,F,e){const C=[];let A,E,t,r="",n="";if(null==F||"object"!=typeof F||Array.isArray(F)||(e=F.space,t=F.quote,F=F.replacer),"function"==typeof F)E=F;else if(Array.isArray(F)){A=[];for(const u of F){let D;"string"==typeof u?D=u:("number"==typeof u||u instanceof String||u instanceof Number)&&(D=String(u)),void 0!==D&&A.indexOf(D)<0&&A.push(D)}}return e instanceof Number?e=Number(e):e instanceof String&&(e=String(e)),"number"==typeof e?e>0&&(e=Math.min(10,Math.floor(e)),n=" ".substr(0,e)):"string"==typeof e&&(n=e.substr(0,10)),i("",{"":u});function i(u,D){let F=D[u];switch(null!=F&&("function"==typeof F.toJSON5?F=F.toJSON5(u):"function"==typeof F.toJSON&&(F=F.toJSON(u))),E&&(F=E.call(D,u,F)),F instanceof Number?F=Number(F):F instanceof String?F=String(F):F instanceof Boolean&&(F=F.valueOf()),F){case null:return"null";case!0:return"true";case!1:return"false"}return"string"==typeof F?B(F):"number"==typeof F?String(F):"object"==typeof F?Array.isArray(F)?function(u){if(C.indexOf(u)>=0)throw TypeError("Converting circular structure to JSON5");C.push(u);let D=r;r+=n;let F,e=[];for(let D=0;D<u.length;D++){const F=i(String(D),u);e.push(void 0!==F?F:"null")}if(0===e.length)F="[]";else if(""===n){let u=e.join(",");F="["+u+"]"}else{let u=",\n"+r,C=e.join(u);F="[\n"+r+C+",\n"+D+"]"}return C.pop(),r=D,F}(F):function(u){if(C.indexOf(u)>=0)throw TypeError("Converting circular structure to JSON5");C.push(u);let D=r;r+=n;let F,e=A||Object.keys(u),E=[];for(const D of e){const F=i(D,u);if(void 0!==F){let u=a(D)+":";""!==n&&(u+=" "),u+=F,E.push(u)}}if(0===E.length)F="{}";else{let u;if(""===n)u=E.join(","),F="{"+u+"}";else{let e=",\n"+r;u=E.join(e),F="{\n"+r+u+",\n"+D+"}"}}return C.pop(),r=D,F}(F):void 0}function B(u){const D={"'":.1,'"':.2},F={"'":"\\'",'"':'\\"',"\\":"\\\\","\b":"\\b","\f":"\\f","\n":"\\n","\r":"\\r","\t":"\\t","\v":"\\v","\0":"\\0","\u2028":"\\u2028","\u2029":"\\u2029"};let e="";for(const C of u){switch(C){case"'":case'"':D[C]++,e+=C;continue}if(F[C])e+=F[C];else if(C<" "){let u=C.charCodeAt(0).toString(16);
3601e+="\\x"+("00"+u).substring(u.length)}else e+=C}const C=t||Object.keys(D).reduce((u,F)=>D[u]<D[F]?u:F);return C+(e=e.replace(new RegExp(C,"g"),F[C]))+C}function a(u){if(0===u.length)return B(u);const F=String.fromCodePoint(u.codePointAt(0));if(!D.isIdStartChar(F))return B(u);for(let e=F.length;e<u.length;e++)if(!D.isIdContinueChar(String.fromCodePoint(u.codePointAt(e))))return B(u);return u}}}});; 3602/* AUTOGENERATED: xcart.form.js */ 3603/* vim: set ts=2 sw=2 sts=2 et: */ 3604 3605/** 3606 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 3607 * See https://www.x-cart.com/license-agreement.html for license details. 3608 */ 3609 3610/** 3611 * Form 3612 */ 3613 3614// Constructor 3615function CommonForm(form) 3616{ 3617 if (!form) { 3618 return false; 3619 } 3620 3621 form = jQuery(form).filter('form').eq(0); 3622 if (!form.length || form.get(0).commonController) { 3623 return false; 3624 } 3625 3626 this.form = form.get(0); 3627 this.$form = form; 3628 3629 var o = this; 3630 3631 this.form.commonController = this; 3632 3633 if (!this.form.getAttribute('id')) { 3634 var d = new Date(); 3635 this.form.setAttribute('id', 'form-' + d.getTime()); 3636 } 3637 3638 var methods = [ 3639 'validate', 'submitBackground', 'isChanged', 'getElements' 3640 ]; 3641 3642 for (var i = 0; i < methods.length; i++) { 3643 var method = methods[i]; 3644 this.form[method] = new Function('', 'return this.commonController.' + method + '.apply(this.commonController, arguments);'); 3645 } 3646 3647 this.form.isBgSubmitting = false; 3648 3649 // Central validation before form submit and background submit 3650 form.submit( 3651 function(event) 3652 { 3653 jQuery('input', this).trigger('sanitize'); 3654 3655 if (this.isBgSubmitting) { 3656 return false; 3657 } 3658 3659 o.triggerVent('submit.prevalidate', o); 3660 3661 var result = this.validate(); 3662 3663 if (result && o.submitOnlyChanged && !o.isChanged(true)) { 3664 result = false;
3665 } 3666 3667 // Trigger the validationSuccess or validationFailure events accordingly the validation result 3668 var validationEvent = jQuery.Event(result ? 'validationSuccess' : 'validationFailure'); 3669 o.$form.trigger(validationEvent); 3670 3671 if (result && o.backgroundSubmit) { 3672 var e = jQuery.Event('beforeSubmit'); 3673 o.$form.trigger(e); 3674 3675 o.triggerVent('submit.postvalidate', o); 3676 3677 if (e.result !== false) { 3678 o.unmarkAsInvalid(); 3679 if (o.submitBackground(null, true)) { 3680 result = false; 3681 } 3682 } 3683 3684 } else if (result) { 3685 o.unmarkAsInvalid(); 3686 } 3687 3688 return result; 3689 } 3690 ); 3691 3692 this.bindElements(); 3693 3694 // Process invalidElement event 3695 xcart.bind( 3696 'invalidElement', 3697 function(event, data) { 3698 if (o.form.isBgSubmitting && o.form.elements.namedItem(data.name)) { 3699 o.form.elements.namedItem(data.name).markAsInvalid(data.message, null, true); 3700 } 3701 } 3702 ); 3703 3704 // Process invalidForm event 3705 xcart.bind( 3706 'invalidForm', 3707 function(event, data) { 3708 if (data.name && o.$form.is('.' + data.name)) { 3709 o.markAsInvalid(data.message); 3710 o.triggerVent( 3711 'invalid.form', 3712 _.extend(_.clone(data), {widget: o}) 3713 ); 3714 } 3715 } 3716 ); 3717 3718 var triggerStateEvents = function(form) { 3719 if (form.get(0).commonController.isChanged()) { 3720 form.addClass('changed'); 3721 form.trigger('state-changed', { 3722 valid: form.get(0).commonController.validate(true) 3723 }); 3724 3725 } else { 3726 form.removeClass('changed'); 3727 form.trigger('state-initial'); 3728 } 3729 }; 3730 3731 var debouncedTriggerStateEvents = _.debounce(triggerStateEvents, 100); 3732 3733 var changeHandler = function (event) { 3734 var obj = event.target || event.srcElement; 3735 var form = jQuery(this); 3736 3737 if ( 3738 !obj 3739 || !jQuery(obj) 3740 || !jQuery(obj).hasClass('not-significant') 3741 ) { 3742 debouncedTriggerStateEvents(form); 3743 } 3744 3745 if (!jQuery(obj).hasClass('selectAll')) { 3746 if (form.find('input.selector:checked').length > 0) { 3747 if (!form.hasClass('more-action-enabled')) { 3748 form.addClass('more-action-enabled'); 3749 form.trigger('more-action-enabled'); 3750 } 3751 3752 } else if (form.hasClass('more-action-enabled')) { 3753 form.removeClass('more-action-enabled'); 3754 form.trigger('more-action-initial'); 3755 } 3756 } 3757 3758 var state = this.commonController.checkDependencyState(); 3759 this.commonController.setDependencyState(state); 3760 }; 3761 3762 form.change(changeHandler); 3763 3764 var state = this.checkDependencyState(); 3765 this.setDependencyState(state); 3766 3767 this.triggerVent('initialized', this); 3768} 3769 3770extend(CommonForm, Base); 3771 3772// Element controllers 3773CommonForm.elementControllers = []; 3774 3775// Autoload class method 3776CommonForm.autoload = function() 3777{ 3778 jQuery('form').each( 3779 function() { 3780 new CommonForm(this); 3781 } 3782 ); 3783}; 3784 3785// Autoassign class method 3786CommonForm.autoassign = function(base) 3787{ 3788 jQuery('form', base).each( 3789 function() { 3790 new CommonForm(this); 3791 } 3792 ); 3793 3794 jQuery(base).parents('form').each( 3795 function() { 3796 if (typeof(this.commonController) !== 'undefined') { 3797 this.commonController.bindElements(); 3798 } 3799 } 3800 ); 3801}; 3802 3803// Form DOM element 3804CommonForm.prototype.form = null; 3805 3806// Form jQuery element 3807CommonForm.prototype.$form = null; 3808 3809CommonForm.prototype.blurTTL = 300; 3810 3811CommonForm.prototype.elementBlurTO = null; 3812 3813CommonForm.prototype.isFocus = false; 3814/** 3815 * Options 3816 */ 3817 3818// Auto-submit form in background mode 3819CommonForm.prototype.backgroundSubmit = false; 3820 3821// Submit form ony if form changed 3822CommonForm.prototype.submitOnlyChanged = false; 3823 3824// POST request as RPC-request 3825CommonForm.prototype.postAsRPC = true; 3826 3827// GET request as RPC-request 3828CommonForm.prototype.getAsRPC = false; 3829 3830CommonForm.prototype.errorPlace = null; 3831 3832CommonForm.prototype.formIdName = 'xcart_form_id'; 3833// Get elements jQuery collection 3834CommonForm.prototype.getElements = function() 3835{ 3836 var data = { 3837 widget: this, 3838 list: this.$form.find(':input, .separator h2') 3839 }; 3840 3841 this.triggerVent('filterElements', data); 3842 3843 return data.list; 3844}; 3845 3846// Bind form elements 3847CommonForm.prototype.bindElements = function() 3848{ 3849 var o = this; 3850 var form = this.$form; 3851 3852 this.getElements().each( 3853 function() { 3854 if (typeof(this.commonController) === 'undefined') { 3855 var elm = new CommonElement(this); 3856 3857 jQuery.each( 3858 CommonForm.elementControllers, 3859 function (i, controller) { 3860 if (typeof(controller) === 'function') { 3861 3862 // Controller is function-handler 3863 controller.call(elm); 3864 } 3865 } 3866 ); 3867 3868 this.commonController.bind('local.blur', _.bind(o.handleElementBlur, o));
3869 this.commonController.bind('local.focus', _.bind(o.handleElementFocus, o)); 3870 } 3871 } 3872 ); 3873 3874 jQuery.each( 3875 CommonForm.elementControllers, 3876 function (i, controller) { 3877 if ( 3878 typeof(controller) === 'object' 3879 && form.find(controller.pattern).length > 0 3880 && (typeof(controller.condition) === 'undefined' || form.find(controller.condition).length > 0) 3881 ) { 3882 3883 // Controller is { pattern: '.element', handler: function () { ... } } 3884 form.find(controller.pattern).each( 3885 function () { 3886 if (typeof(this.assignedElementControllers) === 'undefined') { 3887 this.assignedElementControllers = []; 3888 } 3889 3890 if (jQuery.inArray(i, this.assignedElementControllers) == -1) { 3891 controller.handler.call(this, form); 3892 this.assignedElementControllers.push(i); 3893 } 3894 } 3895 ); 3896 } 3897 } 3898 ); 3899 3900 // Cancel button 3901 this.$form.find('.form-cancel') 3902 .not('.assigned') 3903 .click( 3904 function (event) { 3905 event.stopPropagation(); 3906 var form = jQuery(this).not('.disabled').parents('form').get(0); 3907 if (form ) { 3908 form.commonController.undo(); 3909 } 3910 3911 return false; 3912 } 3913 ) 3914 .addClass('assigned'); 3915}; 3916 3917// Validate form 3918CommonForm.prototype.validate = function(options) 3919{ 3920 var silent = options; 3921 var focus = true; 3922 if (typeof(options) === 'object') { 3923 var silent = typeof(options.silent) !== 'undefined' ? options.silent : false; 3924 var focus = typeof(options.focus) !== 'undefined' ? options.focus : true; 3925 } 3926 3927 var options = focus !== false; 3928 var all = this.getElements(); 3929 var failed = all.filter('input,select,textarea').filter( 3930 function() { 3931 return this.commonController && !this.commonController.validate(silent); 3932 } 3933 ); 3934 3935 var state = { 3936 'widget': this, 3937 'result': failed.length == 0, 3938 'all': all, 3939 'failed': failed 3940 }; 3941 this.triggerVent('validate', state); 3942 3943 if (!state.result && !silent && focus) { 3944 this.focusOnFirstInvalid(); 3945 } 3946 3947 return state.result; 3948}; 3949 3950CommonForm.prototype.focusOnFirstInvalid = function(message) 3951{ 3952 var elm = this.getElements().filter('.validation-error').eq(0); 3953 if (elm.length) { 3954 elm.focus(); 3955 } 3956}; 3957 3958CommonForm.prototype.markAsInvalid = function(message) 3959{ 3960 this.getErrorPlace() 3961 .html(message) 3962 .show(); 3963 3964 this.$form.addClass('invalid-form'); 3965}; 3966 3967CommonForm.prototype.unmarkAsInvalid = function() 3968{ 3969 this.getErrorPlace() 3970 .hide(); 3971 3972 this.$form.removeClass('invalid-form'); 3973}; 3974 3975CommonForm.prototype.getFormId = function () { 3976 return this.$form 3977 .find('input[type="hidden"]') 3978 .filter('input[name="' + this.formIdName + '"]').eq(0) 3979 .val(); 3980}; 3981 3982CommonForm.prototype.replaceCSRFToken = function (value) { 3983 return this.$form 3984 .find('input[type="hidden"]') 3985 .filter('input[name="' + this.formIdName + '"]').eq(0) 3986 .val(value); 3987}; 3988 3989CommonForm.prototype.getErrorPlace = function () { 3990 if (!this.errorPlace) { 3991 this.errorPlace = jQuery('<div></div>') 3992 .addClass('form-error') 3993 .hide() 3994 .insertBefore(this.$form.children().eq(0)); 3995 } 3996 3997 return this.errorPlace; 3998}; 3999 4000// Undo all changes 4001CommonForm.prototype.undo = function () { 4002 this.getElements().filter('input,select,textarea').each(function () { 4003 this.commonController.undo(); 4004 }); 4005 this.$form.trigger('undo'); 4006 this.$form.change(); 4007}; 4008 4009// Enabled background submit mode and set callbacks 4010CommonForm.prototype.enableBackgroundSubmit = function(beforeCallback, afterCallback) { 4011 this.backgroundSubmit = true; 4012 4013 if (beforeCallback) { 4014 this.$form.bind('beforeSubmit', beforeCallback); 4015 } 4016 4017 if (afterCallback) { 4018 this.$form.bind('afterSubmit', afterCallback); 4019 } 4020 4021 return this; 4022}; 4023 4024// Submit form in background mode 4025CommonForm.prototype.submitBackground = function(callback, disableValidation, options) 4026{ 4027 var result = false;
4028 4029 if (disableValidation || this.form.validate()) { 4030 4031 var state = { 4032 'widget': this, 4033 'state': true 4034 }; 4035 4036 this.triggerVent('beforeSubmit', state); 4037 if (!state.state) { 4038 return result; 4039 } 4040 4041 this.preprocessBackgroundSubmit(); 4042 4043 var o = this; 4044 4045 var isPOST = this.$form.attr('method').toUpperCase() == 'POST'; 4046 var method = isPOST ? 'post' : 'get'; 4047 4048 options = options || {}; 4049 4050 if ( 4051 typeof(options.rpc) === 'undefined' 4052 && ((isPOST && this.postAsRPC) || (!isPOST && this.getAsRPC)) 4053 ) { 4054 options.rpc = true; 4055 } 4056 4057 if (typeof(options.timeout) === 'undefined') { 4058 options.timeout = 60000; 4059 } 4060 4061 result = xcart[method]( 4062 this.$form.attr('action'), 4063 function(XMLHttpRequest, textStatus, data, isValid) { 4064 var args = { 4065 'XMLHttpRequest': XMLHttpRequest, 4066 'textStatus': textStatus, 4067 'data': data, 4068 'isValid': isValid 4069 }; 4070 o.postprocessBackgroundSubmit(); 4071 o.tryRestoreCSRFToken(XMLHttpRequest); 4072 o.$form.trigger('afterSubmit', args); 4073 o.triggerVent('submitted', args); 4074 if (isValid) { 4075 o.triggerVent('submit.success', args); 4076 4077 } else { 4078 o.triggerVent('submit.error', args); 4079 } 4080 4081 return callback ? callback(XMLHttpRequest, textStatus, data, isValid) : true; 4082 },
4083 this.getSerializedValues(), 4084 options 4085 ); 4086 4087 if (result) { 4088 this.form.currentSubmitXHR = result; 4089 4090 } else { 4091 xcart.showInternalError(); 4092 } 4093 4094 this.triggerVent('afterSubmit', {'widget': this, 'state': result, 'arguments': arguments}); 4095 } 4096 4097 return result; 4098}; 4099 4100CommonForm.prototype.getSerializedValues = function() 4101{ 4102 return this.getElements().serialize(); 4103}; 4104 4105CommonForm.prototype.tryRestoreCSRFToken = function(xhr) 4106{ 4107 var list = xhr.getAllResponseHeaders().split(/\n/); 4108 var tokenHeader = _.find(list, function(headerValue){ 4109 return headerValue.search(/update-csrf: (.*)/i) !== -1; 4110 }); 4111 4112 var newTokenMatches = tokenHeader 4113 ? tokenHeader.match(/update-csrf: (.*)/i) 4114 : null; 4115 4116 if (newTokenMatches && newTokenMatches[1]) { 4117 var newTokenValue = JSON.parse(newTokenMatches[1]); 4118 4119 if (newTokenValue.value) { 4120 this.replaceCSRFToken(newTokenValue.value); 4121 } 4122 } 4123}; 4124// Submit form in force mode 4125CommonForm.prototype.submitForce = function() 4126{ 4127 this.skipCurrentBgSubmit(); 4128 4129 var oldValue = this.submitOnlyChanged; 4130 this.submitOnlyChanged = false; 4131 4132 this.$form.submit(); 4133 4134 this.submitOnlyChanged = oldValue; 4135}; 4136 4137// Prepare form before background submit 4138CommonForm.prototype.preprocessBackgroundSubmit = function() 4139{ 4140 this.form.isBgSubmitting = true; 4141 4142 this.triggerVent('submit.preprocess', this); 4143 4144 this.getElements().commonController('preprocessBackgroundSubmit'); 4145}; 4146 4147// Prepare form after background submit 4148CommonForm.prototype.postprocessBackgroundSubmit = function() 4149{ 4150 this.form.isBgSubmitting = false; 4151 if (this.form.currentSubmitXHR) { 4152 delete this.form.currentSubmitXHR; 4153 } 4154 4155 this.getElements().commonController('postprocessBackgroundSubmit'); 4156}; 4157 4158CommonForm.prototype.isSaveValue = function (element) { 4159 return true; 4160}; 4161 4162// Skip current background submit 4163CommonForm.prototype.skipCurrentBgSubmit = function () { 4164 if (this.form.isBgSubmitting) { 4165 this.form.isBgSubmitting = false; 4166 4167 if (this.form.currentSubmitXHR) { 4168 this.form.currentSubmitXHR.abort(); 4169 delete this.form.currentSubmitXHR; 4170 } 4171 4172 this.getElements().commonController('skipCurrentBgSubmit'); 4173 } 4174}; 4175 4176// Form has any changed state watcher's elements 4177CommonForm.prototype.hasChangedWatcher = function () { 4178 return this.getElements().filter(function() { 4179 return this.isChangedWatcher(); 4180 }).length > 0; 4181}; 4182 4183// Check - form changed or not 4184CommonForm.prototype.isChanged = function(onlyVisible) 4185{ 4186 return this.getElements().filter( 4187 function() { 4188 return this.commonController ? this.commonController.isChanged(onlyVisible) : false; 4189 } 4190 ).length > 0; 4191}; 4192 4193// Check - form was filled or not 4194CommonForm.prototype.wasFilledOnce = function() 4195{ 4196 var fields = this.getElements().filter( 4197 function() { 4198 return this.commonController ? this.commonController.isRequired() : false; 4199 } 4200 ); 4201 4202 return _.every(fields, function(item) { 4203 return item.commonController.wasFilledOnce() || !item.commonController.isVisible(); 4204 }); 4205}; 4206 4207CommonForm.prototype.handleElementBlur = function(elm) 4208{ 4209 this.elementBlurTO = setTimeout( 4210 _.bind(this.triggerBlur, this), 4211 this.blurTTL 4212 ); 4213}; 4214 4215CommonForm.prototype.handleElementFocus = function(elm) 4216{ 4217 if (this.elementBlurTO) { 4218 clearTimeout(this.elementBlurTO); 4219 this.elementBlurTO = null; 4220 } 4221 4222 if (!this.isFocus) { 4223 this.isFocus = true; 4224 this.triggerVent('focus', this); 4225 } 4226}; 4227 4228CommonForm.prototype.triggerBlur = function() 4229{ 4230 if (this.isFocus) { 4231 this.isFocus = false; 4232 this.triggerVent('blur', this); 4233 } 4234}; 4235 4236CommonForm.prototype.checkDependencyState = function() 4237{ 4238 var state = {}; 4239 4240 var checkState = _.bind(function (state, field, deps, show) { 4241 var depField, depValue, value; 4242 var input, element; 4243 for (depField in deps) if (deps.hasOwnProperty(depField)) { 4244 input = jQuery('[name="' + depField + '"]', jQuery(this.form)).not('[type="hidden"]').get(0); 4245 if (!input || !input.commonController) { 4246 continue; 4247 } 4248 depValue = deps[depField]; 4249 element = input.commonController.$element; 4250 4251 if (element.is('[type="checkbox"]')) { 4252 value = element.is(':checked') ? true : false;
4253 } else { 4254 value = element.val(); 4255 } 4256 4257 if (show) { 4258 if (depValue == value || ((typeof depValue === 'object') && _.contains(depValue, value))) { 4259 if (state[field] !== false) { 4260 state[field] = true; 4261 } 4262 } else { 4263 state[field] = false; 4264 } 4265 } else { 4266 if (depValue == value || ((typeof depValue === 'object') && _.contains(depValue, value))) { 4267 if (state[field] !== true) { 4268 state[field] = false; 4269 } 4270 } else { 4271 state[field] = true; 4272 } 4273 } 4274 } 4275 4276 return state; 4277 }, this); 4278 4279 _.each( 4280 this.getDependency(), 4281 function(value, field) { 4282 state = checkState(state, field, value.hide, false); 4283 state = checkState(state, field, value.show, true); 4284 } 4285 ); 4286 4287 return state; 4288}; 4289 4290CommonForm.prototype.getDependency = function() 4291{ 4292 var dependency = {}; 4293 4294 this.$form.find('.has-dependency :input, .separator.has-dependency h2').each( 4295 function () { 4296 if (typeof(this.commonController) !== 'undefined') { 4297 if (typeof(this.commonController.hasDependency) !== 'undefined' && this.commonController.hasDependency()) { 4298 var name = this.commonController.element.name || this.commonController.$element.data('name'); 4299 dependency[name] = this.commonController.getDependency(); 4300 } 4301 } 4302 } 4303 ); 4304 4305 return dependency; 4306}; 4307 4308CommonForm.prototype.setDependencyState = function(state) 4309{ 4310 _.each( 4311 state, 4312 this.setElementDependency, 4313 this 4314 ); 4315}; 4316 4317CommonForm.prototype.setElementDependency = function (state, field) 4318{ 4319 var element = jQuery(this.form.elements.namedItem(field)).add('[data-name="' + field + '"]', this.form).filter('[type!="hidden"]').get(0); 4320 if (element) { 4321 var elementController = element.commonController; 4322 4323 if (state) { 4324 elementController.showByDependency(); 4325 4326 } else { 4327 elementController.hideByDependency(); 4328 } 4329 } 4330}; 4331 4332// {{{ Form readiness 4333 4334CommonForm.prototype.controlReadiness = false; 4335 4336CommonForm.prototype.isReady = null; 4337 4338CommonForm.prototype.switchControlReadiness = function(flag) 4339{ 4340 this.controlReadiness = flag === true || typeof(flag) === 'undefined'; 4341 4342 if (this.controlReadiness) { 4343 this.processReadiness(); 4344 } 4345 4346 return this; 4347}; 4348 4349CommonForm.prototype.resetReadiness = function() 4350{ 4351 this.isReady = null; 4352 4353 return this; 4354}; 4355 4356CommonForm.prototype.processReadiness = function() 4357{ 4358 if (this.isReadinessChanged()) { 4359 if (this.isReady) { 4360 this.triggerVent('ready', this); 4361 4362 } else { 4363 this.triggerVent('unready', this); 4364 } 4365 } 4366}; 4367 4368CommonForm.prototype.isReadinessChanged = function() 4369{ 4370 var tmp = this.isReady; 4371 this.isReady = this.validate(true); 4372 4373 return tmp != this.isReady; 4374}; 4375 4376CommonForm.prototype.findParentCellForElementOnStickyPanel = function(element) { 4377 let result = element; 4378 while (result && result.parentNode && result.classList && !result.classList.contains('panel-cell')) { 4379 result = result.parentNode; 4380 } 4381 if (result && result.classList && result.classList.contains('panel-cell')) { 4382 return result; 4383 } 4384 return element; 4385}; 4386 4387// }}} 4388 4389/** 4390 * Element 4391 */ 4392 4393// Constructor 4394function CommonElement(elm) 4395{ 4396 this.validationCallbacks = []; 4397 4398 if (elm && !elm.commonController) { 4399 this.bindElement(elm); 4400 } 4401} 4402 4403extend(CommonElement, Base); 4404 4405CommonElement.prototype.element = null; 4406CommonElement.prototype.$element = null; 4407// Validattion class-base rule pattern 4408CommonElement.prototype.classRegExp = /^field-(.+)$/; 4409CommonElement.prototype.watchTTL = 2000; 4410CommonElement.prototype.promptPosition = 'bottomLeft'; 4411 4412// Bind element 4413CommonElement.prototype.bindElement = function(elm) 4414{ 4415 this.element = elm; 4416 this.$element = jQuery(elm); 4417 4418 this.element.commonController = this; 4419 4420 // Add methods and properties 4421 var methods = [ 4422 'showInlineError', 'hideInlineError', 'markAsInvalid', 4423 'unmarkAsInvalid', 'markAsProgress', 'unmarkAsProgress', 4424 'validate', 'isChanged', 'markAsWatcher', 4425 'toggleActivity', 'isEnabled', 'enable', 4426 'disable', 'isVisible', 4427 'showInlineMessage', 'hideInlineMessage' 4428 ]; 4429 4430 _.each( 4431 methods, 4432 function(method) { 4433 this.element[method] = _.bind( 4434 function() { 4435 return this[method].apply(this, arguments); 4436 }, 4437 this 4438 ); 4439 }, 4440 this 4441 ); 4442 4443 this.saveValue(); 4444 this.element.isInitialError = this.$element.hasClass('validation-error'); 4445 4446 this.assignHandlers(); 4447 4448 this.$element.bind('jqv.field.result', _.bind(this.handleValidationEngineResult, this)); 4449 var debounced = _.debounce(_.bind(this.handleKeyUp, this), 100); 4450 var debouncedChange = _.debounce(_.bind(this.handleChange, this), 100); 4451 this.$element 4452 .change(debouncedChange) 4453 .keyup(debounced) 4454 .bind('paste', debounced); 4455 4456 if (this.$element.parents('.instant-control-readiness').length > 0) { 4457 this.$element.keyup(_.debounce(_.bind(this.handleKeyUpControlReadiness, this), 100)); 4458 } 4459 4460 this.triggerVent('bind'); 4461}; 4462 4463CommonElement.prototype.getForm = function () { 4464 return (this.element.form && this.element.form.commonController) 4465 ? this.element.form.commonController 4466 : null; 4467}; 4468 4469// Get validators by form element 4470CommonElement.prototype.getValidators = function () {
4471 var validators = []; 4472 4473 if (this.element.className) { 4474 var classes = this.element.className.split(/ /); 4475 var m, methodName; 4476 for (var i = 0; i < classes.length; i++) { 4477 4478 m = classes[i].match(this.classRegExp); 4479 4480 if (m && m[1]) { 4481 methodName = m[1].replace(/-[a-z]/, this.buildMethodName); 4482 methodName = 'validate' + methodName.substr(0, 1).toUpperCase() + methodName.substr(1); 4483 if (typeof(this[methodName]) !== 'undefined') { 4484 validators.push( 4485 { 4486 key: m[1], 4487 method: this[methodName] 4488 } 4489 ); 4490 } 4491 } 4492 } 4493 } 4494 4495 return validators; 4496}; 4497 4498// Get element label by form element 4499CommonElement.prototype.getLabel = function() 4500{ 4501 var label = null; 4502 4503 if (this.element.id) { 4504 var lbl = jQuery('label[for="' + this.element.id + '"]'); 4505 if (lbl.length) { 4506 label = jQuery.trim(lbl.eq(0).html()).replace(/:$/, '').replace(/<.+$/, ''); 4507 } 4508 } 4509 4510 return label; 4511}; 4512 4513// Check - element visible or not 4514CommonElement.prototype.isVisible = function() 4515{ 4516 if (this.$element.css('display') == 'none') { 4517 return false; 4518 } 4519 4520 return this.$element 4521 .parents() 4522 .filter( 4523 function() { 4524 return $(this).css('display') == 'none'; 4525 } 4526 ) 4527 .length == 0; 4528}; 4529 4530CommonElement.prototype.isVisibleForValidation = function() 4531{ 4532 var data = this.$element.data('jqv'); 4533 4534 return this.isVisible() || (data && data.validateNonVisibleFields === true) 4535 || this.$element.data('custom-validate') === true; 4536}; 4537 4538// Build validator method name helper 4539CommonElement.prototype.buildMethodName = function(str) 4540{ 4541 return str.substr(1).toUpperCase(); 4542}; 4543 4544// Validate form element 4545CommonElement.prototype.addValidationCallback = function(callback) 4546{ 4547 this.validationCallbacks.push(callback); 4548}; 4549 4550// Validate form element 4551CommonElement.prototype.getValidationCallbacks = function() 4552{ 4553 return this.validationCallbacks; 4554}; 4555 4556// Validate form element 4557CommonElement.prototype.validate = function(silent, noFocus) 4558{ 4559 var result = true; 4560 4561 if (!this.isVisibleForValidation()) { 4562 return result; 4563 } 4564 4565 if ( 4566 this.$element.is(':input') 4567 && ( 4568 (typeof(this.element.type) !== 'undefined' && this.element.type == 'hidden') 4569 || this.$element.closest('.hidden').length > 0 4570 ) 4571 ) { 4572 // Hidden input always validate successfull 4573 result = true; 4574 4575 } else if (this.$element.hasClass('no-validate')) { 4576 4577 // Hidden element always validate successfull 4578 result = true; 4579 4580 } else if (this.$element.hasClass('server-validation-error') && !this.isChanged() && !this.wasFilledOnce()) { 4581 4582 // Element is fail server validation and element's value did not changed 4583 result = false;
4584 4585 } else { 4586 4587 this.$element.data('validation-silent', !!silent); 4588 4589 var validators = this.getValidators(); 4590 4591 if (validators.length > 0 && this.isVisibleForValidation()) { 4592 4593 // Check by validators 4594 for (var i = 0; i < validators.length && result; i++) { 4595 4596 var res = validators[i].method.call(this); 4597 if (!res.status && res.apply) { 4598 result = false; 4599 4600 if (!silent) { 4601 res.message = xcart.t(res.message); 4602 this.markAsInvalid(res.message, validators[i].key); 4603 } 4604 } 4605 } 4606 4607 if (result && !silent && this.$element.hasClass('validation-error')) { 4608 this.unmarkAsInvalid(); 4609 } 4610 } 4611 4612 // Validation using validationEngine plugin 4613 if (result && this.$element.validationEngine && this.$element.attr('id')) { 4614 this.$element.validationEngine('validate'); 4615 result = !this.$element.data('validation-error'); 4616 } 4617 4618 var state = {'widget': this, 'result': result, 'silent': silent}; 4619 this.triggerVent('validate', state); 4620 4621 result = state.result; 4622 4623 if (result && silent) { 4624 this.unmarkAsInvalid(); 4625 } 4626 4627 if (result && !_.isEmpty(this.element.value) && this.$element.hasClass('show-valid-state')) { 4628 this.markAsValid(); 4629 } 4630 } 4631 4632 var element = this.$element; 4633 4634 return result && _.every(this.getValidationCallbacks(), function(callback) { 4635 return callback(element); 4636 }); 4637}; 4638 4639// Check 4640CommonElement.prototype.isUseInlineError = function() 4641{ 4642 return jQuery(this.element.form).hasClass('use-inline-error'); 4643}; 4644 4645// Check 4646CommonElement.prototype.isUsePromptError = function() 4647{ 4648 return jQuery(this.element.form).hasClass('use-prompt-error') 4649 && typeof(this.$element.validationEngine) !== 'undefined'; 4650}; 4651 4652// Mark element as invalid (validation is NOT passed) 4653CommonElement.prototype.markAsInvalid = function(message, key, serverSideError) 4654{ 4655 key = key || this.element.name; 4656 4657 var oldErrorMessage = this.$element.data('lastValidationError'); 4658 var common_container = this.$element.closest(".table-value").parent(); 4659 4660 this.$element 4661 .addClass('validation-error') 4662 .data('lastValidationError', message) 4663 .data('lastValidationKey', key); 4664 4665 this.$element.parent().addClass('has-error'); 4666 common_container.addClass('has-error'); 4667 this.$element.parent().removeClass('has-success has-success-mark'); 4668 4669 if (this.isUseInlineError()) { 4670 this.$element 4671 .not('.forbid-inline-error') 4672 .each( 4673 function() { 4674 this.hideInlineError(); 4675 this.hideInlineMessage(); 4676 this.showInlineError(message); 4677 } 4678 ); 4679 4680 } else if (this.isUsePromptError()) { 4681 this.$element.validationEngine( 4682 'showPrompt', 4683 message, 4684 null, 4685 this.promptPosition, 4686 true 4687 ); 4688 4689 } else { 4690 if (this.$element.attr('title')) { 4691 this.element.oldTitle = this.$element.attr('title'); 4692 this.$element.removeAttr('title'); 4693 } 4694 if (typeof(this.element.errorTooltipAssigned) === 'undefined' || !this.element.errorTooltipAssigned) { 4695 this.$element.tooltip({ 4696 title: message, 4697 placement: 'bottom', 4698 trigger: 'focus' 4699 }); 4700 this.element.errorTooltipAssigned = true; 4701 this.$element.tooltip('show'); 4702 4703 } else if (message !== oldErrorMessage) { 4704 this.$element.tooltip('hide').attr('data-original-title', message).tooltip('show'); 4705 } 4706 } 4707 4708 if (serverSideError) { 4709 this.$element.addClass('server-validation-error'); 4710 } 4711 4712 this.$element.trigger('invalid'); 4713 this.triggerVent('markAsInvalid', this); 4714}; 4715 4716// Unmark element as invalid (validation is passed) 4717CommonElement.prototype.unmarkAsInvalid = function() 4718{ 4719 var common_container = this.$element.parents(".table-value").parent(); 4720 4721 if (this.$element.hasClass('validation-error')) { 4722 this.$element.trigger('valid'); 4723 } 4724 4725 this.$element 4726 .data('lastValidationError', null) 4727 .data('lastValidationKey', null) 4728 .removeClass('validation-error') 4729 .removeClass('server-validation-error') 4730 .each(function() { 4731 this.hideInlineError(); 4732 }); 4733 4734 this.$element.parent().removeClass('has-error'); 4735 common_container.removeClass('has-error'); 4736 if (typeof(this.element.errorTooltipAssigned) !== 'undefined' && this.element.errorTooltipAssigned) { 4737 this.$element.tooltip('destroy'); 4738 this.element.errorTooltipAssigned = false;
4739 } 4740 if (typeof(this.element.oldTitle) !== 'undefined' && this.element.oldTitle) { 4741 this.$element.attr('title', this.element.oldTitle); 4742 this.element.oldTitle = null; 4743 } 4744 4745 this.triggerVent('unmarkAsInvalid', this); 4746}; 4747 4748// Mark element as valid (validation is passed) 4749CommonElement.prototype.markAsValid = function(message) 4750{ 4751 this.unmarkAsInvalid(); 4752 4753 this.$element 4754 .data('lastValidationMessage', message) 4755 .each( 4756 function() { 4757 this.hideInlineMessage(); 4758 this.showInlineMessage(message); 4759 } 4760 ); 4761 4762 this.$element.parent().addClass('has-success'); 4763 if (isElement(this.element, 'input') && jQuery.inArray(this.element.type, ['checkbox', 'radio']) == -1) { 4764 this.$element.parent().addClass('has-success-mark'); 4765 } 4766 4767 this.triggerVent('markAsValid', this); 4768}; 4769 4770// Show element inline error message 4771CommonElement.prototype.showInlineError = function(message) 4772{ 4773 var elm = jQuery(document.createElement('p')) 4774 .addClass('error') 4775 .addClass('inline-error') 4776 .html(message); 4777 var placed = false; 4778 4779 this.triggerVent('placeError', {'widget': this, 'element': elm, 'placed': placed}); 4780 if (!placed) { 4781 if (this.$element.is(':checkbox') && this.$element.nextAll('label').length) { 4782 elm.insertAfter(this.$element.nextAll('label').eq(0)); 4783 4784 } else { 4785 elm.insertAfter(this.$element); 4786 } 4787 } 4788}; 4789 4790// Hide element inline error message 4791CommonElement.prototype.hideInlineError = function() 4792{ 4793 return jQuery('p.inline-error', this.element.parentNode).remove(); 4794}; 4795 4796// Show element inline error message 4797CommonElement.prototype.showInlineMessage = function(message) 4798{ 4799 var elm = jQuery(document.createElement('p')) 4800 .addClass('message') 4801 .addClass('inline-message') 4802 .html(message); 4803 var placed = false; 4804 4805 this.triggerVent('placeMessage', {'widget': this, 'element': elm, 'placed': placed}); 4806 if (!placed) { 4807 if (this.$element.is(':checkbox') && this.$element.nextAll('label').length) { 4808 elm.insertAfter(this.$element.nextAll('label').eq(0)); 4809 4810 } else { 4811 elm.insertAfter(this.$element); 4812 } 4813 } 4814}; 4815 4816// Hide element inline error message 4817CommonElement.prototype.hideInlineMessage = function() 4818{ 4819 return jQuery('p.inline-message', this.element.parentNode).remove(); 4820}; 4821 4822// Mark element as in-progress element 4823CommonElement.prototype.markAsProgress = function() 4824{ 4825 this.$element.addClass('progress-mark-apply'); 4826 this.$element.parent().removeClass('has-success has-success-mark'); 4827 4828 return jQuery('<div></div>') 4829 .insertAfter(this.$element) 4830 .addClass('single-progress-mark'); 4831}; 4832 4833// Unmark element as in-progress element 4834CommonElement.prototype.unmarkAsProgress = function() 4835{ 4836 this.$element.removeClass('progress-mark-apply'); 4837 4838 return jQuery('.single-progress-mark', this.element.parentNode).remove(); 4839}; 4840 4841// Mark element as change watcher 4842CommonElement.prototype.markAsWatcher = function(beforeCallback) 4843{ 4844 var o = this; 4845 4846 this.element.selfSubmitting = false; 4847 this.element.selfSubmitTO = null; 4848 this.element.lastValue = this.element.value; 4849 4850 var submitElement = function(event) { 4851 if (o.element.selfSubmitTO) { 4852 clearTimeout(o.element.selfSubmitTO); 4853 o.element.selfSubmitTO = null; 4854 } 4855 4856 if ( 4857 (o.isChanged() || (o.$element.hasClass('validation-error') && !o.$element.hasClass('server-validation-error'))) 4858 && (!beforeCallback || beforeCallback(o.element)) 4859 ) { 4860 jQuery(o.element.form).submit(); 4861 } 4862 }; 4863 4864 var delayedUpdate = function(event) { 4865 if (this.lastValue !== this.value) { 4866 4867 this.lastValue = this.value; 4868 4869 if (this.selfSubmitTO) { 4870 clearTimeout(this.selfSubmitTO); 4871 this.selfSubmitTO = null; 4872 } 4873 4874 this.selfSubmitTO = setTimeout(submitElement, o.watchTTL); 4875 } 4876 }; 4877 4878 o.$element 4879 .blur(submitElement) 4880 .keyup(delayedUpdate) 4881 .filter('[type="checkbox"]') 4882 .click(submitElement); 4883 4884 if (typeof(jQuery.fn.mousewheel) !== 'undefined') { 4885 o.$element.mousewheel(delayedUpdate); 4886 } 4887}; 4888 4889// Element is column checkboxes switcher 4890CommonElement.prototype.markAsColumnSwitcher = function() 4891{ 4892 this.$element.click( 4893 function() { 4894 var idx = jQuery(this).parents('th').get(0).cellIndex; 4895 var newState = this.checked; 4896 4897 jQuery(this).parents('table').find('tr').each( 4898 function() { 4899 jQuery(this.cells[idx]).find(':checkbox').get(0).checked = newState; 4900 } 4901 ); 4902 } 4903 ); 4904}; 4905 4906// Element is mouse wheel controlled 4907CommonElement.prototype.markAsWheelControlled = function() 4908{ 4909 var o = this; 4910 4911 this.$element.mousewheel( 4912 function(event, delta) { 4913 4914 // Pull min and max value from the validationEndine class 4915 if (o.$element.attr('class').match(/min\[(\d+)\].*max\[(\d+)\]/)) { 4916 o.$element.mousewheel.options = { 4917 'min': RegExp.$1, 4918 'max': RegExp.$2 4919 }; 4920 } 4921 4922 return o.$element.hasClass('focused') && o.updateByMouseWheel(event, delta); 4923 } 4924 ); 4925 4926 if (!this.$element.hasClass('no-wheel-mark') && this.$element.nextAll('.wheel-mark').length == 0) { 4927 jQuery(document.createElement('span')) 4928 .addClass('wheel-mark') 4929 .html(' ') 4930 .insertAfter(this.$element); 4931 } 4932 4933 this.$element.addClass('wheel-mark-input'); 4934 4935 this.$element.focus( 4936 function() { 4937 jQuery(this).addClass('focused'); 4938 } 4939 ); 4940 4941 this.$element.blur( 4942 function() { 4943 jQuery(this).removeClass('focused'); 4944 } 4945 ); 4946}; 4947 4948// Update element by mouse wheel 4949CommonElement.prototype.updateByMouseWheel = function(event, delta) 4950{ 4951 event.stopPropagation(); 4952 4953 var value = false;
4954 var mantis = 0; 4955 4956 if (this.element.value.length == 0) { 4957 value = 0; 4958 4959 } else if (this.element.value.search(/^ *[+-]?[0-9]+\.?[0-9]* *$/) != -1) { 4960 var m = this.element.value.match(/^ *[+-]?[0-9]+\.([0-9]+) *$/); 4961 if (m && m[1]) { 4962 mantis = m[1].length; 4963 } 4964 4965 value = parseFloat(this.element.value); 4966 if (isNaN(value)) { 4967 value = false; 4968 } 4969 } 4970 4971 if (value !== false) { 4972 4973 value = value + delta; 4974 4975 if ( 4976 typeof(jQuery(this).mousewheel) !== 'undefined' 4977 && typeof(jQuery(this).mousewheel.options) !== 'undefined' 4978 ) { 4979 4980 var mwBase = jQuery(this).mousewheel.options, 4981 min = parseFloat(mwBase.min), 4982 max = parseFloat(mwBase.max); 4983 4984 if (typeof(mwBase.min) !== 'undefined' && min > value) { 4985 value = min; 4986 } else if (typeof(mwBase.max) !== 'undefined' && max < value) { 4987 value = max; 4988 } 4989 } 4990 4991 value = mantis 4992 ? Math.round(value * Math.pow(10, mantis)) / Math.pow(10, mantis) 4993 : Math.round(value); 4994 4995 var oldValue = this.element.value; 4996 this.element.value = value; 4997 4998 if (jQuery(this.element).validationEngine('validate')) { 4999 this.element.value = oldValue; 5000 5001 } else { 5002 this.$element.change(); 5003 jQuery(this.element.form).change(); 5004 5005 } 5006 5007 this.$element.removeClass('wrong-amount'); 5008 } 5009 5010 return false; 5011}; 5012 5013// Undo changes 5014CommonElement.prototype.undo = function() 5015{ 5016 if (this.isChanged(true)) { 5017 if (isElement(this.element, 'input') && jQuery.inArray(this.element.type, ['checkbox', 'radio']) !== -1) { 5018 this.element.checked = this.element.initialValue; 5019 5020 } else { 5021 this.element.value = this.element.initialValue; 5022 } 5023 this.$element.change(); 5024 5025 this.$element.trigger('undo'); 5026 } 5027}; 5028 5029// Element is state watcher 5030CommonElement.prototype.isWatcher = function() 5031{ 5032 return typeof(this.element.selfSubmitting) !== 'undefined'; 5033}; 5034 5035// Element is changed state watcher 5036CommonElement.prototype.isChangedWatcher = function() 5037{ 5038 return this.isWatcher() && this.element.selfSubmitTO; 5039}; 5040 5041// Check - element changed or not 5042CommonElement.prototype.isChanged = function(onlyVisible) 5043{ 5044 var result = false;
5045 5046 if ((!(onlyVisible && !this.isVisible()) && this.isSignificantInput()) || this.isAffectChange()) { 5047 if ( 5048 (isElement(this.element, 'input') && jQuery.inArray(this.element.type, ['text', 'number', 'password', 'hidden', 'file']) !== -1) 5049 || isElement(this.element, 'select') 5050 || isElement(this.element, 'textarea') 5051 ) { 5052 if (isElement(this.element, 'select') && this.$element.prop('multiple')) { 5053 result = !this.isEqualArrayValues(this.element.initialValue, this.$element.val(), this.$element); 5054 5055 } else { 5056 result = !this.isEqualValues(this.element.initialValue, this.element.value, this.$element); 5057 } 5058 5059 } else if (isElement(this.element, 'input') && jQuery.inArray(this.element.type, ['checkbox', 'radio']) !== -1) { 5060 result = !this.isEqualValues(this.element.initialValue, !!this.element.checked, this.$element); 5061 } 5062 } 5063 5064 return result; 5065}; 5066 5067// Check - element was filled once or not 5068CommonElement.prototype.wasFilledOnce = function () 5069{ 5070 if (!this.wasFilled) { 5071 if (isElement(this.element, 'input') && jQuery.inArray(this.element.type, ['text', 'password', 'hidden', 'file']) !== -1) { 5072 this.wasFilled = !_.isEmpty(this.element.value) || this.isChanged(true); 5073 } else { 5074 this.wasFilled = true; 5075 } 5076 } 5077 5078 return this.wasFilled; 5079}; 5080 5081// Check - element is significant or not 5082CommonElement.prototype.isSignificantInput = function () 5083{ 5084 return !this.$element.hasClass('not-significant'); 5085}; 5086 5087CommonElement.prototype.isAffectChange = function () 5088{ 5089 return this.$element.hasClass('affect-change'); 5090}; 5091 5092CommonElement.prototype.isRequired = function () 5093{ 5094 return this.element.className.indexOf('required') != -1; 5095}; 5096 5097// Check element old value and new valies - equal or not 5098CommonElement.prototype.isEqualValues = function(oldValue, newValue) 5099{ 5100 return oldValue == newValue; 5101}; 5102 5103// Check array values and return true if they are equal 5104CommonElement.prototype.isEqualArrayValues = function(oldValue, newValue, element) 5105{ 5106 var result = false;
5107 5108 if (oldValue == null) { 5109 result = (oldValue == newValue); 5110 5111 } else if (newValue != null && oldValue.length == newValue.length) { 5112 5113 result = true; 5114 5115 for (var i = 0; i < oldValue.length; i++) { 5116 if (oldValue[i] != newValue[i]) { 5117 result = false; 5118 break; 5119 } 5120 } 5121 } 5122 5123 return result; 5124}; 5125 5126// Save element value as initial value 5127CommonElement.prototype.saveValue = function() 5128{ 5129 var customInitValue = this.$element.data('init-value'); 5130 this.element.initialValue = customInitValue ? customInitValue : this.getCanonicalValue(); 5131}; 5132 5133// Get canonical element value 5134CommonElement.prototype.getCanonicalValue = function() 5135{ 5136 var result = null; 5137 5138 if ( 5139 (isElement(this.element, 'input') && jQuery.inArray(this.element.type, ['text', 'number', 'password', 'hidden', 'file']) != -1) 5140 || isElement(this.element, 'select') 5141 || isElement(this.element, 'textarea') 5142 ) { 5143 if (isElement(this.element, 'select') && this.$element.prop('multiple')) { 5144 result = this.$element.val(); 5145 5146 } else { 5147 result = this.element.value; 5148 } 5149 5150 } else if (isElement(this.element, 'input') && jQuery.inArray(this.element.type, ['checkbox', 'radio']) != -1) { 5151 result = this.element.checked; 5152 } 5153 5154 return result; 5155}; 5156 5157// Prepare element before background submit 5158CommonElement.prototype.preprocessBackgroundSubmit = function() 5159{ 5160 if (this.$element.hasClass('progress-mark-owner') && this.isVisible() && this.isChanged()) { 5161 this.markAsProgress(); 5162 } 5163 5164 if (!this.$element.prop('readonly')) { 5165 if (isElement(this.element, 'select')) { 5166 this.$element.addClass('readonly-mark'); 5167 } 5168 this.$element.prop('readonly', 'readonly'); 5169 this.element.isTemporaryReadonly = true; 5170 } 5171}; 5172 5173// Prepare element after background submit 5174CommonElement.prototype.postprocessBackgroundSubmit = function() 5175{ 5176 if (this.getForm() && this.getForm().isSaveValue(this)) { 5177 this.saveValue(); 5178 } 5179 5180 if (this.$element.hasClass('progress-mark-apply')) { 5181 this.unmarkAsProgress(); 5182 } 5183 5184 if (this.element.isTemporaryReadonly) { 5185 if (isElement(this.element, 'select')) { 5186 this.$element.removeClass('readonly-mark'); 5187 } 5188 this.$element.prop('readonly', false); 5189 this.element.isTemporaryReadonly = null; 5190 } 5191}; 5192 5193// 'Skip current background submit' form event 5194CommonElement.prototype.skipCurrentBgSubmit = function() 5195{ 5196 this.postprocessBackgroundSubmit(); 5197}; 5198 5199CommonElement.prototype.linkWithCountry = function() 5200{ 5201 var countryName = this.element.name.replace(/state/, 'country'); 5202 var country = this.element.form.elements.namedItem(countryName); 5203 5204 if (country && typeof(window.CountriesStates) !== 'undefined') { 5205
5206 this.element.isFocused = false; 5207 5208 jQuery(this.$element) 5209 .focus(function() { 5210 this.isFocused = true; 5211 }) 5212 .blur(function() { 5213 this.isFocused = false; 5214 }); 5215 5216 var stateSwitcher = document.createElement('input'); 5217 stateSwitcher.type = 'hidden'; 5218 stateSwitcher.name = this.element.name.replace(/state/, 'is_custom_state'); 5219 stateSwitcher.value = isElement(this.element, 'input') ? '1' : ''; 5220 country.form.appendChild(stateSwitcher); 5221 new CommonElement(stateSwitcher); 5222 5223 this.element.currentCountryCode = false; 5224 country.stateInput = this.element; 5225 5226 var o = this; 5227 5228 o.lastStateText = ''; 5229 5230 var replaceElement = function(type) 5231 { 5232 var inp = document.createElement(type); 5233 if (type == 'input') { 5234 inp.type = 'text'; 5235 } 5236 inp.id = this.stateInput.id; 5237 inp.className = this.stateInput.className; 5238 inp.name = this.stateInput.name; 5239 inp.currentCountryCode = this.stateInput.currentCountryCode; 5240 5241 var isFocused = this.stateInput.isFocused; 5242 5243 jQuery(this.stateInput).replaceWith(inp); 5244 this.stateInput = inp; 5245 5246 if (isFocused) { 5247 this.stateInput.focus(); 5248 } 5249 5250 jQuery(this.stateInput) 5251 .focus(function() { 5252 this.isFocused = true; 5253 }) 5254 .blur(function() { 5255 this.isFocused = false; 5256 }); 5257 5258 o.bind(inp); 5259 }; 5260 5261 var change = function() 5262 { 5263 if (this.stateInput.currentCountryCode == this.value) { 5264 return true; 5265 } 5266 5267 this.stateInput.currentCountryCode = this.value; 5268 5269 if (typeof(CountriesStates[this.value]) === 'undefined') { 5270 5271 // As input box 5272 if (!isElement(this.stateInput, 'input')) { 5273 replaceElement.call(this, 'input'); 5274 this.stateInput.value = o.lastStateText; 5275 } 5276 5277 stateSwitcher.value = '1'; 5278 5279 } else { 5280 5281 // As select box 5282 var previousSelected = null; 5283 if (isElement(this.stateInput, 'select')) { 5284 5285 if (this.stateInput.options.length > 0 && this.stateInput.options[this.stateInput.selectedIndex].value !== '' ) { 5286 previousSelected = this.stateInput.options[this.stateInput.selectedIndex].value; 5287 jQuery('option', this.stateInput).remove(); 5288 } 5289 5290 } else { 5291 o.lastStateText = this.stateInput.value; 5292 replaceElement.call(this, 'select'); 5293 } 5294 5295 for (var i = 0; i < CountriesStates[this.value].length; i++) { 5296 var s = CountriesStates[this.value][i]; 5297 this.stateInput.options[i] = new Option(s.state, s.state_code); 5298 5299 if (previousSelected && previousSelected == s.state_code) { 5300 this.stateInput.options[i].selected = true; 5301 this.stateInput.selectedIndex = i; 5302 } 5303 } 5304 5305 stateSwitcher.value = ''; 5306 } 5307 }; 5308 5309 jQuery(country).change(change); 5310 5311 change.call(country); 5312 } 5313}; 5314 5315// Prepare element with onclick-based location change 5316CommonElement.prototype.processLocation = function() 5317{ 5318 if ( 5319 this.$element.attr('onclick') 5320 && this.$element.attr('onclick').toString().search(/\.location[ ]*=[ ]*['"].+['"]/) !== -1 5321 ) { 5322 var m = this.$element.attr('onclick').toString().match(/\.location[ ]*=[ ]*['"](.+)['"]/); 5323 this.$element 5324 .data('location', m[1]) 5325 .removeAttr('onclick'); 5326 } 5327}; 5328 5329// Toggle element activity 5330CommonElement.prototype.toggleActivity = function(condition) 5331{ 5332 if ( 5333 (typeof(condition) !== 'undefined' && condition) 5334 || (typeof(condition) === 'undefined' && !this.isEnabled()) 5335 ) { 5336 this.enable(); 5337 5338 } else { 5339 this.disable(); 5340 } 5341}; 5342 5343// Check element activity 5344CommonElement.prototype.isEnabled = function() 5345{ 5346 return !this.$element.hasClass('disabled'); 5347}; 5348 5349// Disable element 5350CommonElement.prototype.disable = function() 5351{ 5352 var common_container = this.$element.parents(".table-value").parent(); 5353 5354 common_container.addClass('disabled'); 5355 this.$element 5356 .addClass('disabled') 5357 .prop('disabled', true); 5358}; 5359 5360// Enable element 5361CommonElement.prototype.enable = function() 5362{ 5363 var common_container = this.$element.parents(".table-value").parent(); 5364 5365 common_container.removeClass('disabled'); 5366 this.$element 5367 .removeClass('disabled') 5368 .prop('disabled', false); 5369}; 5370 5371CommonElement.prototype.handleChange = function(event) 5372{ 5373 var controlReadiness = this.element.form && this.element.form.commonController.controlReadiness; 5374 5375 if (controlReadiness 5376 || this.$element.hasClass('validation-error') 5377 || this.$element.hasClass('touched') 5378 ) { 5379 this.validate(); 5380 } 5381 5382 if (controlReadiness) { 5383 this.element.form.commonController.processReadiness(); 5384 } 5385 5386 this.$element.addClass('touched'); 5387}; 5388 5389CommonElement.prototype.handleKeyUp = function(event) 5390{ 5391 if (this.isSignificantInput()) { 5392 jQuery(this.element.form).change(); 5393 } 5394}; 5395 5396CommonElement.prototype.handleKeyUpControlReadiness = function(event) 5397{ 5398 var controlReadiness = this.element.form && this.element.form.commonController.controlReadiness; 5399 5400 if (controlReadiness) { 5401 this.element.form.commonController.processReadiness(); 5402 } 5403}; 5404 5405CommonElement.prototype.handleValidationEngineResult = function(event, field, errorFound, prompText) 5406{ 5407 if (errorFound) { 5408 jQuery('.formError').remove(); 5409 5410 if ( 5411 !field.data('validation-silent') 5412 || (field.get(0).isChanged() && field.get(0) !== document.activeElement) 5413 ) { 5414 field.get(0).commonController.markAsInvalid( 5415 prompText.replace(/^\* /g, '').replace(/<br.>.*$/g, '') 5416 ); 5417 } 5418 } else { 5419 field.get(0).commonController.unmarkAsInvalid(); 5420 } 5421 5422 field.data('validation-error', errorFound); 5423}; 5424 5425/** 5426 * Validators 5427 */ 5428 5429// E-mail 5430CommonElement.prototype.validateEmail = function() 5431{ 5432 var re = new RegExp( 5433 "^[a-z0-9!#$%&\'*+\\/=?^_`{|}~-]+(?:\\.[a-z0-9!#$%&\'*+\\/=?^_`{|}~-]+)*@(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\\.)+[a-z](?:[a-z0-9-]*[a-z0-9])?\\s*$", 5434 'gi' 5435 ); 5436 5437 var apply = isElement(this.element, 'input') || isElement(this.element, 'textarea'); 5438 5439 return {
5440 status: !apply || !this.element.value.length || this.element.value.search(re) !== -1, 5441 message: 'Enter a correct email', 5442 apply: apply 5443 }; 5444}; 5445 5446// Integer 5447CommonElement.prototype.validateInteger = function() 5448{ 5449 var apply = isElement(this.element, 'input') || isElement(this.element, 'textarea'); 5450 5451 return { 5452 status: !apply || !this.element.value.length || this.element.value.search(/^ *[0-9]+ */) != -1, 5453 message: 'Enter an integer', 5454 apply: apply 5455 }; 5456}; 5457 5458// Float 5459CommonElement.prototype.validateFloat = function() 5460{ 5461 var apply = isElement(this.element, 'input') || isElement(this.element, 'textarea'); 5462 5463 var value = this.element.value.replace(/^ +/, '').replace(/ +$/, ''); 5464 var sanitized = parseFloat(value); 5465 5466 return { 5467 status: !apply || !this.element.value.length || (!isNaN(sanitized)), 5468 message: 'Enter a number', 5469 apply: apply 5470 }; 5471}; 5472 5473// Positive number 5474CommonElement.prototype.validatePositive = function() 5475{ 5476 var apply = isElement(this.element, 'input') || isElement(this.element, 'textarea'); 5477 5478 var value = parseFloat(this.element.value); 5479 5480 return { 5481 status: !apply || !this.element.value.length || (!isNaN(value) && value >= 0), 5482 message: 'Enter a positive number', 5483 apply: apply 5484 }; 5485}; 5486 5487// Negative number 5488CommonElement.prototype.validateNegative = function() 5489{ 5490 var apply = isElement(this.element, 'input') || isElement(this.element, 'textarea'); 5491 5492 var value = parseFloat(this.element.value); 5493 5494 return { 5495 status: !apply || !this.element.value.length || (!isNaN(value) && value <= 0), 5496 message: 'Enter a negative number', 5497 apply: apply 5498 }; 5499}; 5500 5501// Non-zero number 5502CommonElement.prototype.validateNonZero = function() 5503{ 5504 var apply = isElement(this.element, 'input') || isElement(this.element, 'textarea'); 5505 5506 var value = parseFloat(this.element.value); 5507 5508 return { 5509 status: !apply || !this.element.value.length || (!isNaN(value) && value != 0), 5510 message: 'Zero cannot be used', 5511 apply: apply 5512 }; 5513}; 5514 5515// Range (min - max) number 5516CommonElement.prototype.validateRange = function() 5517{ 5518 var apply = isElement(this.element, 'input') || isElement(this.element, 'textarea'); 5519 5520 var result = { 5521 status: true, 5522 message: 'This field is required', 5523 apply: apply 5524 }; 5525 5526 if (apply && this.element.value.length) { 5527 5528 var value = parseFloat(this.element.value); 5529 5530 if (isNaN(value)) { 5531 result.status = false; 5532 5533 } else if (typeof(this.element.min) !== 'undefined' && this.element.min > value) { 5534 result.status = false; 5535 result.message = 'Field too small!'; 5536 5537 } else if (typeof(this.element.max) !== 'undefined' && this.element.max < value) { 5538 5539 result.status = false; 5540 result.message = 'Field too big!'; 5541 } 5542 } 5543 5544 return result; 5545}; 5546 5547// Required field 5548CommonElement.prototype.validateRequired = function() 5549{ 5550 return { 5551 status: this.element.value !== null && this.element.value.length > 0, 5552 message: 'Field is required!', 5553 apply: true 5554 }; 5555}; 5556 5557// Handlers mechanism 5558 5559// Assign handlers 5560CommonElement.prototype.assignHandlers = function () 5561{ 5562 var o = this; 5563 5564 jQuery.each( 5565 this.handlers, 5566 function (index, elm) { 5567 if (elm.canApply.call(o)) { 5568 elm.handler.call(o); 5569 } 5570 } 5571 ); 5572}; 5573 5574// Handlers repository 5575CommonElement.prototype.handlers = [ 5576 { 5577 canApply: function () { 5578 return this.$element.hasClass('watcher'); 5579 }, 5580 handler: CommonElement.prototype.markAsWatcher 5581 }, 5582 { 5583 canApply: function () { 5584 return this.$element.hasClass('field-state') && this.$element.hasClass('linked'); 5585 }, 5586 handler: CommonElement.prototype.linkWithCountry 5587 }, 5588 { 5589 canApply: function () { 5590 return this.$element.hasClass('column-switcher') && this.$element.parents('th').length > 0; 5591 }, 5592 handler: CommonElement.prototype.markAsColumnSwitcher 5593 }, 5594 { 5595 canApply: function () { 5596 return this.$element.hasClass('wheel-ctrl'); 5597 }, 5598 handler: CommonElement.prototype.markAsWheelControlled 5599 }, 5600 { 5601 canApply: function () { 5602 return this.$element.is('textarea.resizeble-txt'); 5603 }, 5604 handler: function() { 5605 var min = this.$element.data('min-size-height') || this.$element.height(); 5606 var max = this.$element.data('max-size-height'); 5607 5608 this.$element.TextAreaExpander(min, max); 5609 } 5610 }, 5611 { 5612 canApply: function () { 5613 return this.$element; 5614 }, 5615 handler: function() { 5616 this.$element.blur( 5617 _.bind( 5618 function() { 5619 this.triggerVent('blur', this); 5620 }, 5621 this 5622 ) 5623 ); 5624 } 5625 }, 5626 { 5627 canApply: function () { 5628 return this.$element; 5629 }, 5630 handler: function() { 5631 this.$element.focus( 5632 _.bind( 5633 function() { 5634 this.triggerVent('focus', this); 5635 }, 5636 this 5637 ) 5638 ); 5639 } 5640 } 5641]; 5642 5643CommonElement.prototype.hasDependency = function () 5644{ 5645 return this.$element.closest('.has-dependency').length > 0; 5646}; 5647 5648CommonElement.prototype.getDependency = function () 5649{ 5650 return this.hasDependency() 5651 ? xcart.getCommentedData(this.$element.closest('.has-dependency'), 'depen
5651dency') 5652 : {}; 5653}; 5654 5655CommonElement.prototype.hideByDependency = function () 5656{ 5657 this.$element.closest('.has-dependency').addClass('hidden'); 5658}; 5659 5660CommonElement.prototype.showByDependency = function () 5661{ 5662 this.$element.closest('.has-dependency').removeClass('hidden'); 5663}; 5664 5665// Autostart 5666xcart.autoload(CommonForm); 5667 5668// Common controller as jQuery plugin 5669(function ($) { 5670 jQuery.fn.commonController = function(property) { 5671 var args = Array.prototype.slice.call(arguments, 1); 5672 5673 this.each( 5674 function() { 5675 if (typeof(this.commonController) === 'undefined') { 5676 if (isElement(this, 'form')) { 5677 new CommonForm(this); 5678 5679 } else if ( 5680 isElement(this, 'input') 5681 || isElement(this, 'select') 5682 || isElement(this, 'textarea') 5683 || isElement(this, 'button') 5684 ) { 5685 new CommonElement(this); 5686 } 5687 } 5688 5689 if ( 5690 typeof(this.commonController) !== 'undefined' 5691 && typeof(this.commonController[property]) !== 'undefined' 5692 ) { 5693 if (typeof(this.commonController[property]) === 'function') { 5694 this.commonController[property].apply(this.commonController, args); 5695 5696 } else { 5697 this.commonController[property] = args[0]; 5698 } 5699 } 5700 } 5701 ); 5702 5703 return this; 5704 }; 5705 5706})(jQuery);; 5707/* AUTOGENERATED: loadCSS.min.js */ 5708!function(c){"use strict";function e(e,t,n,o){var r,i=c.document,d=i.createElement("link");if(t)r=t;else{var a=(i.body||i.getElementsByTagName("head")[0]).childNodes;r=a[a.length-1]}var f=i.styleSheets;if(o)for(var l in o)o.hasOwnProperty(l)&&d.setAttribute(l,o[l]);d.rel="stylesheet",d.href=e,d.media="only x",function e(t){if(i.body)return t();setTimeout(function(){e(t)})}(function(){r.parentNode.insertBefore(d,t?r:r.nextSibling)});var s=function(e){for(var t=d.href,n=f.length;n--;)if(f[n].href===t)return e();setTimeout(function(){s(e)})};function u(){d.addEventListener&&d.removeEventListener("load",u),d.media=n||"all"}return d.addEventListener&&d.addEventListener("load",u),(d.onloadcssdefined=s)(u),d}"undefined"!=typeof exports?exports.loadCSS=e:c.loadCSS=e}("undefined"!=typeof global?global:this);; 5709/* AUTOGENERATED: onloadCSS.min.js */ 5710function onloadCSS(n,a){var t;function d(){!t&&a&&(t=!0,a.call(n))}n.addEventListener&&n.addEventListener("load",d),n.attachEvent&&n.attachEvent("onload",d),"isApplicationInstalled"in navigator&&"onloadcssdefined"in n&&n.onloadcssdefined(d)}; 5711/* AUTOGENERATED: Function.name.js */ 5712(function() { 5713 5714 var fnNameMatchRegex = /^\s*function(?:\s|\s*\/\*.*\*\/\s*)+([^\(\s\/]*)\s*/; 5715 5716 function _name() { 5717 var match, name; 5718 if (this === Function || this === Function.prototype.constructor) { 5719 name = "Function"; 5720 } 5721 else if (this !== Function.prototype) { 5722 match = ("" + this).match(fnNameMatchRegex); 5723 name = match && match[1]; 5724 } 5725 return name || ""; 5726 } 5727 5728// Inspect the polyfill-ability of this browser 5729 var needsPolyfill = !("name" in Function.prototype && "name" in (function x() {})); 5730 var canDefineProp = typeof Object.defineProperty === "function" && 5731 (function() { 5732 var result; 5733 try { 5734 Object.defineProperty(Function.prototype, "_xyz", { 5735 get: function() { 5736 return "blah"; 5737 }, 5738 configurable: true 5739 }); 5740 result = Function.prototype._xyz === "blah"; 5741 delete Function.prototype._xyz; 5742 } 5743 catch (e) { 5744 result = false;
5745 } 5746 return result; 5747 })(); 5748 var canDefineGetter = typeof Object.prototype.__defineGetter__ === "function" && 5749 (function() { 5750 var result; 5751 try { 5752 Function.prototype.__defineGetter__("_abc", function() { 5753 return "foo"; 5754 }); 5755 result = Function.prototype._abc === "foo"; 5756 delete Function.prototype._abc; 5757 } 5758 catch (e) { 5759 result = false; 5760 } 5761 return result; 5762 })(); 5763 5764 5765 5766// Add the "private" property for testing, even if the real property can be polyfilled 5767 Function.prototype._name = _name; 5768 5769 5770// Polyfill it! 5771// For: 5772// * IE >=9 <12 5773// * Chrome <33 5774 if (needsPolyfill) { 5775 // For: 5776 // * IE >=9 <12 5777 // * Chrome >=5 <33 5778 if (canDefineProp) { 5779 Object.defineProperty(Function.prototype, "name", { 5780 get: function() { 5781 var name = _name.call(this); 5782 5783 // Since named function definitions have immutable names, also memoize the 5784 // output by defining the `name` property directly on this Function 5785 // instance so that this polyfill will not need to be invoked again 5786 if (this !== Function.prototype) { 5787 Object.defineProperty(this, "name", { 5788 value: name, 5789 configurable: true 5790 }); 5791 } 5792 5793 return name; 5794 }, 5795 configurable: true 5796 }); 5797 } 5798 // For: 5799 // * Chrome <5 5800 else if (canDefineGetter) { 5801 // NOTE: 5802 // The snippet: 5803 // 5804 // x.__defineGetter__('y', z); 5805 // 5806 // ...is essentially equivalent to: 5807 // 5808 // Object.defineProperty(x, 'y', { 5809 // get: z, 5810 // configurable: true, // <-- key difference #1 5811 // enumerable: true // <-- key difference #2 5812 // }); 5813 // 5814 Function.prototype.__defineGetter__("name", function() { 5815 var name = _name.call(this); 5816 5817 // Since named function definitions have immutable names, also memoize the 5818 // output by defining the `name` property directly on this Function 5819 // instance so that this polyfill will not need to be invoked again 5820 if (this !== Function.prototype) { 5821 this.__defineGetter__("name", function() { return name; }); 5822 } 5823 5824 return name; 5825 }); 5826 } 5827 } 5828 5829})();; 5830/* AUTOGENERATED: php.min.js */ 5831function var_export(mixed_expression,bool_return){var retstr='',iret='',cnt=0,x=[],i=0,funcParts=[],idtLevel=arguments[2]||2,innerIndent='',outerIndent='',getFuncName=function(fn){var name=/\W*function\s+([\w\$]+)\s*\(/.exec(fn);if(!name)return'(Anonymous)';return name[1]},_makeIndent=function(idtLevel){return(new Array(idtLevel+1)).join(' ')},__getType=function(inp){var i=0,match,type=typeof inp;if(type==='object'&&inp!==null&&inp.constructor&&getFuncName(inp.constructor)==='PHPJS_Resource')return'resource';if(type==='function')return'function';if(type==='object'&&!inp)return'null';if(type==="object"){if(!inp.constructor)return'object';var cons=inp.constructor.toString();match=cons.match(/(\w+)\(/);if(match)cons=match[1].toLowerCase();var types=["boolean","number","string","array"];for(i=0;i<types.length;i++)if(cons===types[i]){type=types[i];break}};return type},type=__getType(mixed_expression);if(type===null){retstr="NULL"}else if(type==='array'||type==='object'){outerIndent=_makeIndent(idtLevel-2);innerIndent=_makeIndent(idtLevel);for(i in mixed_expression){var value=this.var_export(mixed_expression[i],true,idtLevel+2);x[cnt++]=innerIndent+i+' => '+(__getType(mixed_expression[i])==='array'?'\n':'')+value};iret=x.join(',\n');retstr=outerIndent+"array (\n"+iret+'\n'+outerIndent+')'}else if(type==='function'){funcParts=mixed_expression.toString().match(/function .*?\((.*?)\) \{([\s\S]*)\}/);retstr="create_function ('"+funcParts[1]+"', '"+funcParts[2].replace(new RegExp("'",'g'),"\\'")+"')"}else if(type==='resource'){retstr='NULL'}else retstr=(typeof mixed_expression!=='string')?mixed_expression:"'"+mixed_expression.replace(/(["'])/g,"\\$1").replace(/\0/g,"\\0")+"'";if(bool_return!==true){this.echo(retstr);return null}else return retstr} 5832function is_null(mixed_var){return(mixed_var===null)} 5833function echo(){var arg='',argc=arguments.length,argv=arguments,i=0,holder,win=this.window,d=win.document,ns_xhtml='http://www.w3.org/1999/xhtml',ns_xul='http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul',stringToDOM=function(str,parent,ns,container){var extraNSs='';if(ns===ns_xul)extraNSs=' xmlns:html="'+ns_xhtml+'"';var stringContainer='<'+container+' xmlns="'+ns+'"'+extraNSs+'>'+str+'</'+container+'>',dils=win.DOMImplementationLS,dp=win.DOMParser,ax=win.ActiveXObject;if(dils&&dils.createLSInput&&dils.createLSParser){var lsInput=dils.createLSInput();lsInput.stringData=stringContainer;var lsParser=dils.createLSParser(1,null);return lsParser.parse(lsInput).firstChild}else if(dp){try{var fc=new dp().parseFromString(stringContainer,'text/xml');if(fc&&fc.documentElement&&fc.documentElement.localName!=='parsererror'&&fc.documentElement.namespaceURI!=='http://www.mozilla.org/newlayout/xml/parsererror.xml')return fc.documentElement.firstChild}catch(e){}}else if(ax){var axo=new ax('MSXML2.DOMDocument');axo.loadXML(str);return axo.documentElement};if(d.createElementNS&&(d.documentElement.namespaceURI||d.documentElement.nodeName.toLowerCase()!=='html'||(d.contentType&&d.contentType!=='text/html'))){holder=d.createElementNS(ns,container)}else holder=d.createElement(container);holder.innerHTML=str;while(holder.firstChild)parent.appendChild(holder.firstChild);return false},ieFix=function(node){if(node.nodeType===1){var newNode=d.createElement(node.nodeName),i,len;if(node.attributes&&node.attributes.length>0)for(i=0,len=node.attributes.length;i<len;i++)newNode.setAttribute(node.attributes[i].nodeName,node.getAttribute(node.attributes[i].nodeName));if(node.childNodes&&node.childNodes.length>0)for(i=0,len=node.childNodes.length;i<len;
5833i++)newNode.appendChild(ieFix(node.childNodes[i]));return newNode}else return d.createTextNode(node.nodeValue)},replacer=function(s,m1,m2){if(m1!=='\\'){return m1+eval(m2)}else return s};this.php_js=this.php_js||{};var phpjs=this.php_js,ini=phpjs.ini,obs=phpjs.obs;for(i=0;i<argc;i++){arg=argv[i];if(ini&&ini['phpjs.echo_embedded_vars'])arg=arg.replace(/(.?)\{?\$(\w*?\}|\w*)/g,replacer);if(!phpjs.flushing&&obs&&obs.length){obs[obs.length-1].buffer+=arg;continue};if(d.appendChild){if(d.body){if(win.navigator.appName==='Microsoft Internet Explorer'){d.body.appendChild(stringToDOM(ieFix(arg)))}else{var unappendedLeft=stringToDOM(arg,d.body,ns_xhtml,'div').cloneNode(true);if(unappendedLeft)d.body.appendChild(unappendedLeft)}}else d.documentElement.appendChild(stringToDOM(arg,d.documentElement,ns_xul,'description'))}else if(d.write)d.write(arg)}} 5834function htmlspecialchars(string,quote_style,charset,double_encode){var optTemp=0,i=0,noquotes=false;if(typeof quote_style==='undefined'||quote_style===null)quote_style=2;string=string.toString();if(double_encode!==false)string=string.replace(/&/g,'&');string=string.replace(/</g,'<').replace(/>/g,'>').replace(/\s/g,' ');var OPTS={ENT_NOQUOTES:0,ENT_HTML_QUOTE_SINGLE:1,ENT_HTML_QUOTE_DOUBLE:2,ENT_COMPAT:2,ENT_QUOTES:3,ENT_IGNORE:4};if(quote_style===0)noquotes=true;if(typeof quote_style!=='number'){quote_style=[].concat(quote_style);for(i=0;i<quote_style.length;i++)if(OPTS[quote_style[i]]===0){noquotes=true}else if(OPTS[quote_style[i]])optTemp=optTemp|OPTS[quote_style[i]];quote_style=optTemp};if(quote_style&OPTS.ENT_HTML_QUOTE_SINGLE)string=string.replace(/'/g,''');if(!noquotes)string=string.replace(/"/g,'"');return string} 5835function htmlspecialchars_decode(string,quote_style){var optTemp=0,i=0,noquotes=false;if(typeof quote_style==='undefined')quote_style=2;string=string.toString().replace(/</g,'<').replace(/>/g,'>').replace(/ /g,' ');var OPTS={ENT_NOQUOTES:0,ENT_HTML_QUOTE_SINGLE:1,ENT_HTML_QUOTE_DOUBLE:2,ENT_COMPAT:2,ENT_QUOTES:3,ENT_IGNORE:4};if(quote_style===0)noquotes=true;if(typeof quote_style!=='number'){quote_style=[].concat(quote_style);for(i=0;i<quote_style.length;i++)if(OPTS[quote_style[i]]===0){noquotes=true}else if(OPTS[quote_style[i]])optTemp=optTemp|OPTS[quote_style[i]];quote_style=optTemp};if(quote_style&OPTS.ENT_HTML_QUOTE_SINGLE)string=string.replace(/�*39;/g,"'");if(!noquotes)string=string.replace(/"/g,'"');string=string.replace(/&/g,'&');return string} 5836function str_replace(search,replace,subject,count){var i=0,j=0,temp='',repl='',sl=0,fl=0,f=[].concat(search),r=[].concat(replace),s=subject,ra=Object.prototype.toString.call(r)==='[object Array]',sa=Object.prototype.toString.call(s)==='[object Array]';s=[].concat(s);if(count)this.window[count]=0;for(i=0,sl=s.length;i<sl;i++){if(s[i]==='')continue;for(j=0,fl=f.length;j<fl;j++){temp=s[i]+'';repl=ra?(r[j]!==undefined?r[j]:''):r[0];s[i]=temp.split(f[j]).join(repl);if(count&&s[i]!==temp)this.window[count]+=(temp.length-s[i].length)/f[j].length}};return sa?s:s[0]} 5837function array_merge(){var args=Array.prototype.slice.call(arguments),argl=args.length,arg,retObj={},k='',argil=0,j=0,i=0,ct=0,toStr=Object.prototype.toString,retArr=true;for(i=0;i<argl;i++)if(toStr.call(args[i])!=='[object Array]'){retArr=false;break};if(retArr){retArr=[];for(i=0;i<argl;i++)retArr=retArr.concat(args[i]);return retArr};for(i=0,ct=0;i<argl;i++){arg=args[i];if(toStr.call(arg)==='[object Array]'){for(j=0,argil=arg.length;j<argil;j++)retObj[ct++]=arg[j]}else for(k in arg)if(arg.hasOwnProperty(k))if(parseInt(k,10)+''===k){retObj[ct++]=arg[k]}else retObj[k]=arg[k]};return retObj} 5838function array_unique(inputArr){var key='',tmp_arr2={},val='',__array_search=function(needle,haystack){var fkey='';for(fkey in haystack)if(haystack.hasOwnProperty(fkey))if((haystack[fkey]+'')===(needle+''))return fkey;return false};for(key in inputArr)if(inputArr.hasOwnProperty(key)){val=inputArr[key];if(false===__array_search(val,tmp_arr2))tmp_arr2[key]=val};return tmp_arr2} 5839function intval(mixed_var,base){var tmp,type=typeof mixed_var;if(type==='boolean'){return+mixed_var}else if(type==='string'){tmp=parseInt(mixed_var,base||10);return(isNaN(tmp)||!isFinite(tmp))?0:tmp}else if(type==='number'&&isFinite(mixed_var)){return mixed_var|0}else return 0}; 5840/* AUTOGENERATED: amd.js */ 5841/* vim: set ts=2 sw=2 sts=2 et: */ 5842 5843/** 5844 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 5845 * See https://www.x-cart.com/license-agreement.html for license details. 5846 */ 5847 5848var CoreAMD = { 5849 pending: {}, 5850 5851 define: function (name, dependencies, callback) { 5852 5853 if (_.isFunction(dependencies)) {
5854 callback = dependencies; 5855 dependencies = []; 5856 } 5857 5858 if (_.isString(dependencies)) { 5859 dependencies = [dependencies]; 5860 } 5861 5862 if (dependencies === undefined) { 5863 dependencies = []; 5864 } 5865 5866 if (callback === undefined) { 5867 callback = function () { 5868 }; 5869 } 5870 5871 var moduleDeferred = this._createDeferred(name); 5872 5873 jQuery 5874 .when.apply(jQuery, dependencies.map(_.bind(this._createDeferred, this))) 5875 .done(function () { 5876 moduleDeferred.resolve(callback.apply(window, arguments)); 5877 }) 5878 }, 5879 5880 require: function (dependencies, callback) { 5881 if (_.isString(dependencies)) { 5882 dependencies = [dependencies]; 5883 } 5884 5885 jQuery 5886 .when.apply(jQuery, dependencies.map(_.bind(this._createDeferred, this))) 5887 .done(function () { 5888 callback.apply(window, arguments); 5889 }); 5890 }, 5891 5892 getUnresolvedDependencies: function () { 5893 var result = []; 5894 for (var name in this.pending) if (this.pending.hasOwnProperty(name)) { 5895 if (this.pending[name].state() === 'pending') { 5896 result.push(name); 5897 } 5898 } 5899 5900 return result; 5901 }, 5902 5903 _createDeferred: function (name) { 5904 if (this.pending[name] === undefined) { 5905 this.pending[name] = new jQuery.Deferred(); 5906 } 5907 5908 return this.pending[name]; 5909 } 5910}; 5911 5912if (window.define) { 5913 window._define = window.define; 5914} 5915window.define = _.bind(CoreAMD.define, CoreAMD); 5916 5917if (window.require) { 5918 window._require = window.require; 5919} 5920window.require = _.bind(CoreAMD.require, CoreAMD); 5921 5922define('js/jquery', function () { 5923 return jQuery; 5924}); 5925define('js/underscore', function () { 5926 return _; 5927}); 5928 5929jQuery(function () { 5930 define('ready'); 5931 5932 setTimeout(function() { 5933 var unresolvedDependencies = CoreAMD.getUnresolvedDependencies(); 5934 if (unresolvedDependencies.length && xcart.isDeveloperMode) { 5935 console.warn('Unresolved dependencies', unresolvedDependencies); 5936 } 5937 }, 1); 5938}); 5939 5940(function () { 5941 var event = document.createEvent('HTMLEvents'); 5942 event.initEvent('amd-ready', true, true); 5943 document.dispatchEvent(event); 5944})();; 5945/* AUTOGENERATED: translate.js */ 5946/* vim: set ts=2 sw=2 sts=2 et: */ 5947 5948/** 5949 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 5950 * See https://www.x-cart.com/license-agreement.html for license details. 5951 */ 5952 5953var Translator = Object.extend({ 5954 languageLabels: [], 5955 5956 constructor: function TranslatorConstructor() { 5957 this.loadPreloadedLabels(); 5958 }, 5959 5960 loadPreloadedLabels: function () { 5961 this.loadLanguageHash( 5962 window.xlite_preloaded_labels 5963 ); 5964 }, 5965 5966 translate: function(label, params) 5967 { 5968 var translation = this._findInLoaded(label); 5969 5970 if (translation === null) { 5971 translation = this._loadLabel(label); 5972 5973 if (translation) { 5974 this._saveToLoaded(label, translation); 5975 } 5976 } 5977 5978 if (params) { 5979 translation = this._processTranslationParams(translation, params) 5980 } 5981 5982 return translation; 5983 }, 5984 5985 5986 loadLanguageHash: function(hash) 5987 { 5988 _.each( 5989 hash, 5990 _.bind( 5991 function (translation, label) { 5992 var foundTranslation = this._findInLoaded(label); 5993 5994 if (foundTranslation === null) { 5995 this._saveToLoaded(label, translation); 5996 } 5997 }, 5998 this 5999 ) 6000 ); 6001 }, 6002 6003 _processTranslationParams: function(translation, params) { 6004 _.each(params, function (paramValue, paramName) { 6005 translation = translation.replace('{{' + paramName + '}}', paramValue); 6006 }); 6007 6008 return translation; 6009 }, 6010 6011 _findInLoaded: function(label) { 6012 var translation = null; 6013 6014 for (var i = 0; i < this.languageLabels.length; i++) { 6015 if (this.languageLabels[i].name == label) { 6016 translation = this.languageLabels[i].label; 6017 break; 6018 } 6019 } 6020 6021 return translation; 6022 }, 6023 6024 _saveToLoaded: function(label, translation) { 6025 this.languageLabels.push( 6026 { 6027 name: label, 6028 label: translation 6029 } 6030 ); 6031 }, 6032 6033 _loadLabel: function(label) { 6034 return xcart.rest.get('translation', label, false); 6035 }, 6036 6037});; 6038/* AUTOGENERATED: lazysizes.min.js */ 6039/*! lazysizes - v5.2.1 */ 6040 6041!function(e){var t=function(u,D,f){"use strict";var k,H;if(function(){var e;var t={lazyClass:"lazyload",loadedClass:"lazyloaded",loadingClass:"lazyloading",preloadClass:"lazypreload",errorClass:"lazyerror",autosizesClass:"lazyautosizes",srcAttr:"data-src",srcsetAttr:"data-srcset",sizesAttr:"data-sizes",minSize:40,customMedia:{},init:true,expFactor:1.5,hFac:.8,loadMode:2,loadHidden:true,ricTimeout:0,throttleDelay:125};H=u.lazySizesConfig||u.lazysizesConfig||{};for(e in t){if(!(e in H)){H[e]=t[e]}}}(),!D||!D.getElementsByClassName){return{init:function(){},cfg:H,noSupport:true}}var O=D.documentElement,a=u.HTMLPictureElement,P="addEventListener",$="getAttribute",q=u[P].bind(u),I=u.setTimeout,U=u.requestAnimationFrame||I,l=u.requestIdleCallback,j=/^picture$/i,r=["load","error","lazyincluded","_lazyloaded"],i={},G=Array.prototype.forEach,J=function(e,t){if(!i[t]){i[t]=new RegExp("(\\s|^)"+t+"(\\s|$)")}return i[t].test(e[$]("class")||"")&&i[t]},K=function(e,t){if(!J(e,t)){e.setAttribute("class",(e[$]("class")||"").trim()+" "+t)}},Q=function(e,t){var i;if(i=J(e,t)){e.setAttribute("class",(e[$]("class")||"").replace(i," "))}},V=function(t,i,e){var a=e?P:"removeEventListener";if(e){V(t,i)}r.forEach(function(e){t[a](e,i)})},X=function(e,t,i,a,r){var n=D.createEvent("Event");
vendor: 5,178 bytes, line 6041
6041if(!i){i={}}i.instance=k;n.initEvent(t,!a,!r);n.detail=i;e.dispatchEvent(n);return n},Y=function(e,t){var i;if(!a&&(i=u.picturefill||H.pf)){if(t&&t.src&&!e[$]("srcset")){e.setAttribute("srcset",t.src)}i({reevaluate:true,elements:[e]})}else if(t&&t.src){e.src=t.src}},Z=function(e,t){return(getComputedStyle(e,null)||{})[t]},s=function(e,t,i){i=i||e.offsetWidth;while(i<H.minSize&&t&&!e._lazysizesWidth){i=t.offsetWidth;t=t.parentNode}return i},ee=function(){var i,a;var t=[];var r=[];var n=t;var s=function(){var e=n;n=t.length?r:t;i=true;a=false;while(e.length){e.shift()()}i=false};var e=function(e,t){if(i&&!t){e.apply(this,arguments)}else{n.push(e);if(!a){a=true;(D.hidden?I:U)(s)}}};e._lsFlush=s;return e}(),te=function(i,e){return e?function(){ee(i)}:function(){var e=this;var t=arguments;ee(function(){i.apply(e,t)})}},ie=function(e){var i;var a=0;var r=H.throttleDelay;var n=H.ricTimeout;var t=function(){i=false;a=f.now();e()};var s=l&&n>49?function(){l(t,{timeout:n});if(n!==H.ricTimeout){n=H.ricTimeout}}:te(function(){I(t)},true);return function(e){var t;if(e=e===true){n=33}if(i){return}i=true;t=r-(f.now()-a);if(t<0){t=0}if(e||t<9){s()}else{I(s,t)}}},ae=function(e){var t,i;var a=99;var r=function(){t=null;e()};var n=function(){var e=f.now()-i;if(e<a){I(n,a-e)}else{(l||r)(r)}};return function(){i=f.now();if(!t){t=I(n,a)}}},e=function(){var v,m,c,h,e;var y,z,g,p,C,b,A;var n=/^img$/i;var d=/^iframe$/i;var E="onscroll"in u&&!/(gle|ing)bot/.test(navigator.userAgent);var _=0;var w=0;var N=0;var M=-1;var x=function(e){N--;if(!e||N<0||!e.target){N=0}};var W=function(e){if(A==null){A=Z(D.body,"visibility")=="hidden"}return A||!(Z(e.parentNode,"visibility")=="hidden"&&Z(e,"visibility")=="hidden")};var S=function(e,t){var i;var a=e;var r=W(e);g-=t;b+=t;p-=t;C+=t;while(r&&(a=a.offsetParent)&&a!=D.body&&a!=O){r=(Z(a,"opacity")||1)>0;if(r&&Z(a,"overflow")!="visible"){i=a.getBoundingClientRect();r=C>i.left&&p<i.right&&b>i.top-1&&g<i.bottom+1}}return r};var t=function(){var e,t,i,a,r,n,s,l,o,u,f,c;var d=k.elements;if((h=H.loadMode)&&N<8&&(e=d.length)){t=0;M++;for(;t<e;t++){if(!d[t]||d[t]._lazyRace){continue}if(!E||k.prematureUnveil&&k.prematureUnveil(d[t])){R(d[t]);continue}if(!(l=d[t][$]("data-expand"))||!(n=l*1)){n=w}if(!u){u=!H.expand||H.expand<1?O.clientHeight>500&&O.clientWidth>500?500:370:H.expand;k._defEx=u;f=u*H.expFactor;c=H.hFac;A=null;if(w<f&&N<1&&M>2&&h>2&&!D.hidden){w=f;M=0}else if(h>1&&M>1&&N<6){w=u}else{w=_}}if(o!==n){y=innerWidth+n*c;z=innerHeight+n;s=n*-1;o=n}i=d[t].getBoundingClientRect();if((b=i.bottom)>=s&&(g=i.top)<=z&&(C=i.right)>=s*c&&(p=i.left)<=y&&(b||C||p||g)&&(H.loadHidden||W(d[t]))&&(m&&N<3&&!l&&(h<3||M<4)||S(d[t],n))){R(d[t]);r=true;if(N>9){break}}else if(!r&&m&&!a&&N<4&&M<4&&h>2&&(v[0]||H.preloadAfterLoad)&&(v[0]||!l&&(b||C||p||g||d[t][$](H.sizesAttr)!="auto"))){a=v[0]||d[t]}}if(a&&!r){R(a)}}};var i=ie(t);var B=function(e){var t=e.target;if(t._lazyCache){delete t._lazyCache;return}x(e);K(t,H.loadedClass);Q(t,H.loadingClass);V(t,L);X(t,"lazyloaded")};var a=te(B);var L=function(e){a({target:e.target})};var T=function(t,i){try{t.contentWindow.location.replace(i)}catch(e){t.src=i}};var F=function(e){var t;var i=e[$](H.srcsetAttr);if(t=H.customMedia[e[$]("data-media")||e[$]("media")]){e.setAttribute("media",t)}if(i){e.setAttribute("srcset",i)}};var s=te(function(t,e,i,a,r){var n,s,l,o,u,f;if(!(u=X(t,"lazybeforeunveil",e)).defaultPrevented){if(a){if(i){K(t,H.autosizesClass)}else{t.setAttribute("sizes",a)}}s=t[$](H.srcsetAttr);n=t[$](H.srcAttr);if(r){l=t.parentNode;o=l&&j.test(l.nodeName||"")}f=e.firesLoad||"src"in t&&(s||n||o);u={target:t};K(t,H.loadingClass);if(f){clearTimeout(c);c=I(x,2500);V(t,L,true)}if(o){G.call(l.getElementsByTagName("source"),F)}if(s){t.setAttribute("srcset",s)}else if(n&&!o){if(d.test(t.nodeName)){T(t,n)}else{t.src=n}}if(r&&(s||o)){Y(t,{src:n})}}if(t._lazyRace){delete t._lazyRace}Q(t,H.lazyClass);ee(function(){var e=t.complete&&t.naturalWidth>1;if(!f||e){if(e){K(t,"ls-is-cached")}B(u);t._lazyCache=true;I(function(){if("_lazyCache"in t){delete t._lazyCache}},9)}if(t.loading=="lazy"){N--}},true)});var R=function(e){if(e._lazyRace){return}var t;var i=n.test(e.nodeName);var a=i&&(e[$](H.sizesAttr)||e[$]("sizes"));var r=a=="auto";if((r||!m)&&i&&(e[$]("src")||e.srcset)&&!e.complete&&!J(e,H.errorClass)&&J(e,H.lazyClass)){return}t=X(e,"lazyunveilread").detail;if(r){re.updateElem(e,true,e.offsetWidth)}e._lazyRace=true;N++;s(e,t,r,a,i)};var r=ae(function(){H.loadMode=3;i()});var l=function(){if(H.loadMode==3){H.loadMode=2}r()};var o=function(){if(m){return}if(f.now()-e<999){I(o,999);return}m=true;H.loadMode=3;i();q("scroll",l,true)};return{_:function(){e=f.now();k.elements=D.getElementsByClassName(H.lazyClass);v=D.getElementsByClassName(H.lazyClass+" "+H.preloadClass);q("scroll",i,true);q("resize",i,true);q("pageshow",function(e){if(e.persisted){var t=D.querySelectorAll("."+H.loadingClass);if(t.length&&t.forEach){U(function(){t.forEach(function(e){if(e.complete){R(e)}})})}}});if(u.MutationObserver){new MutationObserver(i).observe(O,{childList:true,subtree:true,attributes:true})}else{O[P]("DOMNodeInserted",i,true);O[P]("DOMAttrModified",i,true);setInterval(i,999)}
6041q("hashchange",i,true);["focus","mouseover","click","load","transitionend","animationend"].forEach(function(e){D[P](e,i,true)});if(/d$|^c/.test(D.readyState)){o()}else{q("load",o);D[P]("DOMContentLoaded",i);I(o,2e4)}if(k.elements.length){t();ee._lsFlush()}else{i()}},checkElems:i,unveil:R,_aLSL:l}}(),re=function(){var i;var n=te(function(e,t,i,a){var r,n,s;e._lazysizesWidth=a;a+="px";e.setAttribute("sizes",a);if(j.test(t.nodeName||"")){r=t.getElementsByTagName("source");for(n=0,s=r.length;n<s;n++){r[n].setAttribute("sizes",a)}}if(!i.detail.dataAttr){Y(e,i.detail)}});var a=function(e,t,i){var a;var r=e.parentNode;if(r){i=s(e,r,i);a=X(e,"lazybeforesizes",{width:i,dataAttr:!!t});if(!a.defaultPrevented){i=a.detail.width;if(i&&i!==e._lazysizesWidth){n(e,r,a,i)}}}};var e=function(){var e;var t=i.length;if(t){e=0;for(;e<t;e++){a(i[e])}}};var t=ae(e);return{_:function(){i=D.getElementsByClassName(H.autosizesClass);q("resize",t)},checkElems:t,updateElem:a}}(),t=function(){if(!t.i&&D.getElementsByClassName){t.i=true;re._();e._()}};return I(function(){H.init&&t()}),k={cfg:H,autoSizer:re,loader:e,init:t,uP:Y,aC:K,rC:Q,hC:J,fire:X,gW:s,rAF:ee}}(e,e.document,Date);e.lazySizes=t,"object"==typeof module&&module.exports&&(module.exports=t)}("undefined"!=typeof window?window:{});; 6042/* AUTOGENERATED: tooltip.js */ 6043/* vim: set ts=2 sw=2 sts=2 et: */ 6044 6045/** 6046 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 6047 * See https://www.x-cart.com/license-agreement.html for license details. 6048 */ 6049 6050jQuery.fn.extend({ 6051 startTooltip: function() { 6052 return this.each(function() { 6053 window.startTooltip(this); 6054 }); 6055 }, 6056 popoverKeepOnHover: function () { 6057 var keepOnHoverInit = function (element) { 6058 var debouncedToggle = _.debounce(function(element, option) { 6059 if (option === 'show' 6060 && $(element).data('bs.popover') 6061 && $(element).data('bs.popover').$tip 6062 && $(element).data('bs.popover').$tip.is(':visible') 6063 ) { 6064 return; 6065 } 6066 6067 $(element).popover(option); 6068 }, 150); 6069 6070 $(element).on("mouseenter", function () { 6071 var _this = this; 6072 debouncedToggle($(_this), 'show'); 6073 }).on("mouseleave", function () { 6074 var _this = this; 6075 var hoveredPopover = $(".popover:hover"); 6076 if (!hoveredPopover.length) { 6077 debouncedToggle($(_this), 'hide'); 6078 } else { 6079 hoveredPopover.on("mouseleave", function() { 6080 debouncedToggle($(_this), 'hide'); 6081 }); 6082 } 6083 }); 6084 }; 6085 6086 return this.each(function() { 6087 keepOnHoverInit(this); 6088 }); 6089 } 6090}); 6091 6092(function ($) { 6093 6094 // Tooltips in customer area 6095 jQuery('.tooltip-main').each( 6096 function () { 6097 attachTooltip( 6098 jQuery('i', this), 6099 jQuery('.help-text', this).hide().html() 6100 ); 6101 } 6102 ); 6103 6104 window.startTooltip = function (element) { 6105 var helpId = $(element).data('help-id'); 6106 var params = {sanitize: false}; 6107 6108 if ($(element).parents('.ui-widget-content').first().length) { 6109 params.viewport = ('#' + $(element).parents('.ui-widget-content').first().attr('id')); 6110 } 6111 6112 const container = ($(element).data('container')) 6113 const isNeedRenderInContainer = container && container !== '' 6114 if (isNeedRenderInContainer) { 6115 params.container = container 6116 } 6117 6118 if (helpId) { 6119 content = $('#' + helpId).html(); 6120 if (content) { 6121 params.content = content; 6122 $(element).popover(params); 6123 } 6124 } else { 6125 const getContainerElement = (elm) => { 6126 if (getComputedStyle(elm.parentElement).position === 'absolute') { 6127 return elm.parentElement.parentElement; 6128 } 6129 return elm; 6130 }; 6131 if (!isNeedRenderInContainer) { 6132 params.container = getContainerElement(element) || element; 6133 } 6134 $(element).popover(params); 6135 } 6136 6137 if ($(element).data('keep-on-hover')) { 6138 $(element).popoverKeepOnHover(); 6139 } 6140 }; 6141 6142 define('xlite-tooltip', ['vue/vue'], function (Vue) { 6143 Vue.directive('xlite-tooltip', { 6144 inserted: function (el) { 6145 startTooltip(el); 6146 } 6147 }); 6148 }); 6149 6150})(jQuery); 6151 6152xcart.microhandlers.add( 6153 'Tooltip', 6154 '[data-toggle="popover"]', 6155 function () { 6156 startTooltip(this); 6157 } 6158);; 6159/* AUTOGENERATED: popover.js */ 6160/* vim: set ts=2 sw=2 sts=2 et: */ 6161 6162/** 6163 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 6164 * See https://www.x-cart.com/license-agreement.html for license details. 6165 */ 6166 6167if ($.fn.popover) { 6168 let myDefaultWhiteList = $.fn.popover.Constructor.DEFAULTS.whiteList; 6169 6170 myDefaultWhiteList.input = []; 6171 myDefaultWhiteList.textarea = []; 6172 myDefaultWhiteList.select = []; 6173 myDefaultWhiteList.button = []; 6174 myDefaultWhiteList.table = []; 6175 myDefaultWhiteList.th = []; 6176 myDefaultWhiteList.tr = []; 6177 myDefaultWhiteList.td = []; 6178 6179 myDefaultWhiteList['*'].push('type', 'width', 'height'); 6180}; 6181/* AUTOGENERATED: ga-core.js */ 6182/* vim: set ts=2 sw=2 sts=2 et: */ 6183 6184/** 6185 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 6186 * See https://www.x-cart.com/license-agreement.html for license details. 6187 */ 6188 6189define('googleAnalytics/base/core', ['js/underscore'], function(_) { 6190 return Object.extend({ 6191 6192 settings: { 6193 sendPageview: true, 6194 currency: 'USD' 6195 }, 6196 6197 constructor: function () { 6198 let $initScript = jQuery('#ga-init-script') 6199 if ($initScript.length) { 6200 this.settings = _.defaults( 6201 $initScript.data('settings'), 6202 this.settings 6203 ) 6204 } 6205 6206 this.initialize() 6207 }, 6208 6209 getSetting (name) { 6210 return this.settings[name] 6211 }, 6212 6213 initialize () { 6214 if (this.settings.sendPageview) { 6215 jQuery().ready(_.bind(this.sendPageViewInit, this)) 6216 } 6217 }, 6218 6219 sendPageViewInit () { 6220 }, 6221 6222 registerPageView () { 6223 }, 6224 6225 registerEvent () { 6226 }, 6227 6228 isAvailable () { 6229 } 6230 }); 6231});; 6232/* AUTOGENERATED: ga-event.js */ 6233/* vim: set ts=2 sw=2 sts=2 et: */ 6234 6235/** 6236 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 6237 * See https://www.x-cart.com/license-agreement.html for license details. 6238 */ 6239 6240define('googleAnalytics/event', [ 'googleAnalytics/core', 'js/underscore' ], function(GACore, _) { 6241 return Object.extend({ 6242 constructor: function () { 6243 this.coreInstance = GACore.instance 6244 6245 this.initialize() 6246 }, 6247 6248 initialize() { 6249 jQuery().ready(_.bind(function () { 6250 this.executeIsBecomesAvailable(this.processReady, 10, 100); 6251 }, this)); 6252 6253 this.bindListeners() 6254 }, 6255 6256 bindListeners () { 6257 _.each( 6258 this.getListeners(), 6259 _.bind( 6260 function (handler, eventName) { 6261 xcart.bind(eventName, _.bind(function (event, params) { 6262 const callback = _.partial(handler, event, params) 6263 this.executeIsBecomesAvailable(callback, 10, 100); 6264 }, this)) 6265 }, 6266 this 6267 ) 6268 ) 6269 }, 6270 6271 executeIsBecomesAvailable(callback, count, delay) { 6272 if (!this.coreInstance.isAvailable()) { 6273 if (count > 0) { 6274 console.log('XCart-GA: waiting for GA', count, this) 6275 _.delay(_.partial(_.bind(this.executeIsBecomesAvailable, this), c
6275allback, count - 1, delay), delay); 6276 } else { 6277 console.warn('XCart-GA: GA not available', callback, this) 6278 } 6279 return; 6280 } 6281 6282 callback.apply(this); 6283 }, 6284 6285 createFunctionWithTimeout (callback, args, opt_timeout) { 6286 var called = false 6287 6288 function fn () { 6289 if (!called) { 6290 called = true 6291 callback(args) 6292 } 6293 } 6294 6295 setTimeout(fn, opt_timeout || 500) 6296 return fn 6297 }, 6298 6299 getListeners () { 6300 return {} 6301 }, 6302 6303 processReady () { 6304 }, 6305 6306 sendPageView () { 6307 this.coreInstance.registerPageView() 6308 }, 6309 6310 sendEvent (name, label, value, namespace) { 6311 this.coreInstance.registerEvent(namespace || this.namespace, name, label, value) 6312 } 6313 }); 6314});; 6315/* AUTOGENERATED: ga-core.js */ 6316/* vim: set ts=2 sw=2 sts=2 et: */ 6317 6318/** 6319 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 6320 * See https://www.x-cart.com/license-agreement.html for license details. 6321 */ 6322 6323define('googleAnalytics/core', ['googleAnalytics/base/core', 'js/underscore'], function(GACoreBase, _) { 6324 let GACore = GACoreBase.extend({ 6325 6326 sendPageViewInit () {
6327 GACore.superclass.sendPageViewInit.apply(this, arguments) 6328 6329 xcart.trigger('ga-pageview-sending') 6330 this.sendGAPageView() 6331 xcart.trigger('ga-pageview-sent') 6332 }, 6333 6334 sendGAPageView () { 6335 if ('undefined' != typeof (window.ga)) { 6336 ga('send', 'pageview') 6337 } 6338 }, 6339 6340 /** 6341 * Send the event 6342 * 6343 * @param {string} category Typically the object that was interacted with (e.g. button) 6344 * @param {string} action The type of interaction (e.g. click) 6345 * @param {string} label Useful for categorizing events (e.g. nav buttons) 6346 * @param {number} value Values must be non-negative. Useful to pass counts (e.g. 4 times) 6347 * @return void 6348 */ 6349 sendGAEvent (category, action, label, value) { 6350 if ('undefined' != typeof (window.ga)) { 6351 var data = { 6352 eventCategory: category, 6353 eventAction: action 6354 } 6355 if (label || value) { 6356 data.eventLabel = label 6357 } 6358 if (value) { 6359 data.eventValue = value 6360 } 6361 6362 data.hitCallback = function () { 6363 xcart.trigger('ga-event-sent', data) 6364 } 6365 6366 ga('send', 'event', data) 6367 } 6368 }, 6369 6370 /** 6371 * Send the ecommerce event 6372 * 6373 * @return void 6374 */ 6375 sendGAECEvent () { 6376 if (arguments.length === 2 && !_.isEmpty(arguments[1])) { 6377 ga('ec:' + arguments[0], arguments[1]) 6378 } 6379 if (arguments.length === 3 && arguments[0] === 'setAction' && !_.isEmpty(arguments[2])) { 6380 ga('ec:' + arguments[0], arguments[1], arguments[2]) 6381 } 6382 }, 6383 6384 registerPageView () { 6385 this.sendGAPageView() 6386 }, 6387 6388 registerEvent () { 6389 if (!_.isEmpty(arguments)) { 6390 this.sendGAEvent.apply(this, arguments) 6391 } 6392 }, 6393 6394 registerECEvent () { 6395 if (!_.isEmpty(arguments)) { 6396 this.sendGAECEvent.apply(this, arguments) 6397 } 6398 }, 6399 6400 isAvailable () { 6401 return !_.isUndefined(window.ga) && !_.isUndefined(ga.loaded) && ga.loaded 6402 } 6403 }) 6404 6405 GACore.instance = new GACore(); 6406 6407 return GACore; 6408});; 6409/* AUTOGENERATED: ga-ec-core.js */ 6410/* vim: set ts=2 sw=2 sts=2 et: */ 6411 6412/** 6413 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 6414 * See https://www.x-cart.com/license-agreement.html for license details. 6415 */ 6416 6417define('googleAnalytics/base/eCommerceCoreEvent', ['googleAnalytics/event', 'js/underscore'], function (GAEvent, _) { 6418 let eCommerceCoreEventBase = GAEvent.extend({ 6419 constructor: function () { 6420 eCommerceCoreEventBase.superclass.constructor.apply(this, arguments) 6421 }, 6422 6423 getActions (type, context) { 6424 if (!jQuery(context).length) { 6425 context = document 6426 } 6427 6428 var actionsOnPage = _.map( 6429 jQuery('*[data-ga-ec-action]', context), 6430 function (actionEl) { 6431 return jQuery(actionEl).data('ga-ec-action') 6432 } 6433 ) 6434 6435 return _.filter(actionsOnPage, function (action) { 6436 return action['ga-type'] === type 6437 }) 6438 } 6439 }) 6440 6441 return eCommerceCoreEventBase; 6442});; 6443/* AUTOGENERATED: ga-ec-core.js */ 6444/* vim: set ts=2 sw=2 sts=2 et: */ 6445 6446/** 6447 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 6448 * See https://www.x-cart.com/license-agreement.html for license details. 6449 */ 6450 6451define('googleAnalytics/eCommerceCoreEvent', ['googleAnalytics/base/eCommerceCoreEvent', 'googleAnalytics/event', 'js/underscore'], function (eCommerceCoreEventBase, GAEvent, _) {
6452 var requireEC = _.once(function (gaCoreInstance) { 6453 ga('require', 'ec'); 6454 6455 ga('set', '&cu', gaCoreInstance.getSetting('currency')); 6456 }); 6457 6458 let eCommerceCoreEvent = eCommerceCoreEventBase.extend({ 6459 namespace: 'Ecommerce', 6460 6461 constructor: function () { 6462 eCommerceCoreEvent.superclass.constructor.apply(this, arguments) 6463 6464 requireEC(this.coreInstance) 6465 }, 6466 6467 sendECEvent (event, data, is_action) { 6468 if (is_action) { 6469 this.coreInstance.registerECEvent('setAction', event, data) 6470 } else { 6471 this.coreInstance.registerECEvent(event, data) 6472 } 6473 } 6474 }) 6475 6476 eCommerceCoreEvent.instance = new eCommerceCoreEvent(); 6477 6478 return eCommerceCoreEvent; 6479});; 6480/* AUTOGENERATED: ga-ec-impressions.js */ 6481/* vim: set ts=2 sw=2 sts=2 et: */ 6482 6483/** 6484 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 6485 * See https://www.x-cart.com/license-agreement.html for license details. 6486 */ 6487 6488define('googleAnalytics/base/eCommerceImpressionsEvent', ['googleAnalytics/eCommerceCoreEvent', 'js/underscore'], function (eCommerceCoreEvent, _) { 6489 let eCommerceImpressionsEventBase = eCommerceCoreEvent.extend({ 6490 6491 chunkThreshold: 6000, 6492 processedImpressions: {}, 6493 6494 initialize() { 6495 eCommerceImpressionsEventBase.superclass.initialize.apply(this, arguments) 6496 this.resetContainer() 6497 }, 6498 6499 resetContainer () { 6500 this.container = {} 6501 }, 6502 6503 getListeners () { 6504 return { 6505 'ga-pageview-sending': this.registerAllImpressionsInitial, 6506 'list.products.loaded': this.registerAllImpressionsInList, 6507 'ga-ec-addImpression': this.addImpressionExternalHandler 6508 } 6509 }, 6510 6511 registerAllImpressionsInitial (event, data) { 6512 var self = this 6513 6514 self.processImpressionsList(self.getActions('impression')) 6515 }, 6516 6517 registerAllImpressionsInList (event, widget) { 6518 var self = this 6519 6520 self.processedImpressions = {} 6521 6522 self.processImpressionsList(self.getActions('impression', widget['base'])) 6523 }, 6524 6525 addImpressionExternalHandler (event, data) { 6526 this.addImpression(data) 6527 }, 6528 6529 processImpressionsList (actionsData) { 6530 var self = this 6531 var length = 0 6532 6533 _.each( 6534 actionsData, 6535 function (action, index) { 6536 if (self.addImpression(action.data)) { 6537 length += JSON.stringify(action.data).length 6538 } 6539 if (self.calculateChunkThresholdLength(length) > self.chunkThreshold) { 6540 self.flushImpressions() 6541 length = 0 6542 } 6543 } 6544 ) 6545 6546 if (length) { 6547 self.flushImpressions() 6548 } 6549 }, 6550 6551 calculateChunkThresholdLength (length) { 6552 return length 6553 }, 6554 6555 addImpression (impressionData) { 6556 var self = this 6557 var result = false 6558 var hash = self.getImpressionHash(impressionData) 6559 6560 if (hash && !self.processedImpressions[hash]) { 6561 self.addImpressionAction(impressionData) 6562 result = true 6563 6564 self.processedImpressions[hash] = true 6565 } 6566 6567 return result 6568 }, 6569 6570 getImpressionHash (data) { 6571 return null 6572 }, 6573 6574 addImpressionAction (data) { 6575 }, 6576 6577 flushImpressions () { 6578 } 6579 6580 }) 6581 6582 return eCommerceImpressionsEventBase; 6583});; 6584/* AUTOGENERATED: ga-ec-shopping-cart.js */ 6585/* vim: set ts=2 sw=2 sts=2 et: */ 6586 6587/** 6588 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 6589 * See https://www.x-cart.com/license-agreement.html for license details. 6590 */ 6591 6592define('googleAnalytics/base/GAShoppingCartHandleEvent', ['googleAnalytics/eCommerceCoreEvent', 'js/underscore'], function(eCommerceCoreEvent, _) { 6593 let GAShoppingCartHandleEventBase = eCommerceCoreEvent.extend({ 6594 namespace: 'Product', 6595 chunkThreshold: 6000, 6596 6597 constructor: function () { 6598 GAShoppingCartHandleEventBase.superclass.constructor.apply(this, arguments) 6599 this.resetContainer() 6600 }, 6601 6602 resetContainer () { 6603 this.container = {} 6604 }, 6605 6606 getListeners () { 6607 return { 6608 'ga-pageview-sending': this.registerViewCart, 6609 'ga-update-cart': this.registerUpdateCart 6610 } 6611 }, 6612 6613 registerViewCart (event, data) { 6614 var self = this 6615 6616 var actionData = _.first(self.getActions('view_cart')) 6617 if (actionData && !_.isUndefined(actionData.data)) { 6618 self.processViewCart(actionData.data) 6619 } 6620 }, 6621 6622 processViewCart (cartData) { 6623 var self = this 6624 var length = 0 6625 var baseLength = JSON.stringify(this.container).length 6626 6627 _.each( 6628 cartData.items, 6629 function (item, index) { 6630 self.addCartItemAction(item) 6631 length += JSON.stringify(item).length
6632 if ((length + baseLength) > self.chunkThreshold) { 6633 self.flushViewCart() 6634 length = 0 6635 } 6636 } 6637 ) 6638 6639 if (length) { 6640 self.flushViewCart() 6641 } 6642 }, 6643 6644 addCartItemAction (data) { 6645 }, 6646 6647 flushViewCart () { 6648 }, 6649 6650 registerUpdateCart (event, parent_data) { 6651 var data = parent_data.data 6652 if (data.items) { 6653 for (var i = 0; i < data.items.length; i++) { 6654 var item = data.items[i] 6655 6656 if (item.quantity_change > 0) { 6657 this.registerAddItem(item['ga-data'], item.quantity_change) 6658 } else if (item.quantity_change < 0) { 6659 this.registerRemoveItem(item['ga-data'], item.quantity_change) 6660 } 6661 } 6662 } 6663 this.registerItemsChange(data) 6664 }, 6665 6666 registerItemsChange (data) { 6667 }, 6668 registerAddItem (item) { 6669 }, 6670 registerRemoveItem (item) { 6671 } 6672 }) 6673 6674 return GAShoppingCartHandleEventBase; 6675});; 6676/* AUTOGENERATED: ga-ec-change-item.js */ 6677/* vim: set ts=2 sw=2 sts=2 et: */ 6678 6679/** 6680 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 6681 * See https://www.x-cart.com/license-agreement.html for license details. 6682 */ 6683 6684define('googleAnalytics/base/eCommerceChangeItemEvent', ['googleAnalytics/eCommerceCoreEvent', 'js/underscore'], function (eCommerceCoreEvent, _) { 6685 return eCommerceCoreEvent.extend({ 6686 namespace: 'Product', 6687 6688 getListeners () { 6689 return { 6690 productAddedToCart: this.registerAddToCart, 6691 productsAddedToCart: this.registerAddsToCart 6692 } 6693 }, 6694 6695 registerAddToCart (event, data) { 6696 }, 6697 6698 registerAddsToCart (event, data) { 6699 } 6700 6701 }); 6702 } 6703);; 6704/* AUTOGENERATED: ga-ec-product-details-shown.js */ 6705/* vim: set ts=2 sw=2 sts=2 et: */ 6706 6707/** 6708 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 6709 * See https://www.x-cart.com/license-agreement.html for license details. 6710 */ 6711 6712define('googleAnalytics/base/eCommerceDetailsShownEvent', ['googleAnalytics/eCommerceCoreEvent', 'js/underscore'], function (eCommerceCoreEvent, _) { 6713 return eCommerceCoreEvent.extend({ 6714 6715 getListeners () { 6716 return { 6717 'ga-pageview-sending': this.registerAllDetailsShown 6718 } 6719 }, 6720 6721 registerAllDetailsShown (event, data) { 6722 var self = this 6723 6724 _.each( 6725 this.getActions('addProduct'), 6726 function (action, index) { 6727 self.registerDetailsShown(action.data) 6728 } 6729 ) 6730 }, 6731 6732 registerDetailsShown (addProductData) { 6733 } 6734 6735 }); 6736});; 6737/* AUTOGENERATED: ga-ec-product-click.js */ 6738/* vim: set ts=2 sw=2 sts=2 et: */ 6739 6740/** 6741 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 6742 * See https://www.x-cart.com/license-agreement.html for license details. 6743 */ 6744 6745define('googleAnalytics/base/eCommerceProductClickEvent', ['googleAnalytics/eCommerceCoreEvent', 'js/underscore'], function (eCommerceCoreEvent, _) { 6746 let eCommerceProductClickEventBase = eCommerceCoreEvent.extend({ 6747 6748 constructor: function () { 6749 eCommerceProductClickEventBase.superclass.constructor.apply(this, arguments) 6750 6751 var productLinks = jQuery('.products a.product-thumbnail, .products a.fn, .products a.url') 6752 6753 var self = this 6754 6755 productLinks.click(function (event) { 6756 var dataOwner = jQuery('*[data-ga-ec-action]', jQuery(event.currentTarget).parents('.product')) 6757 6758 if (dataOwner.length) { 6759 self.onProductDetailsClick( 6760 dataOwner.data('ga-ec-action').data, 6761 event 6762 ) 6763 } 6764 6765 return true 6766 }) 6767 }, 6768 6769 onProductDetailsClick (data) { 6770 } 6771 6772 }) 6773 6774 return eCommerceProductClickEventBase; 6775});; 6776/* AUTOGENERATED: ga-change-shipping.js */ 6777/* vim: set ts=2 sw=2 sts=2 et: */ 6778 6779/** 6780 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 6781 * See https://www.x-cart.com/license-agreement.html for license details. 6782 */ 6783 6784define('googleAnalytics/base/changeShippingEvent', [ 'googleAnalytics/eCommerceCoreEvent' ], function(Event) { 6785 return Event.extend({ 6786 namespace: 'Checkout', 6787 6788 getListeners () { 6789 return { 6790 updateCart: this.updateCartHandler 6791 } 6792 }, 6793 6794 updateCartHandler (event, data) { 6795 var actionData = _.first(this.getActions('checkout')) 6796 6797 if (actionData && data.shippingMethodName) { 6798 this.sendChangeMethodEvent(data.shippingMethodName, data.shippingTotal || null, actionData) 6799 } 6800 }, 6801 6802 sendChangeMethodEvent (methodName) { 6803 } 6804 }); 6805});; 6806/* AUTOGENERATED: ga-change-payment.js */ 6807/* vim: set ts=2 sw=2 sts=2 et: */ 6808 6809/** 6810 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 6811 * See https://www.x-cart.com/license-agreement.html for license details. 6812 */ 6813 6814define('googleAnalytics/base/changePaymentMethod', [ 'googleAnalytics/eCommerceCoreEvent' ], function(Event) { 6815 return Event.extend({ 6816 namespace: 'Checkout', 6817 6818 getListeners () { 6819 return { 6820 updateCart: this.updateCartHandler 6821 } 6822 }, 6823 6824 updateCartHandler (event, data) { 6825 var actionData = _.first(this.getActions('checkout')) 6826 6827 if (actionData && data.paymentMethodName && xcart.getTarget() === 'checkout') { 6828 this.sendChangeMethodEvent(data.paymentMethodName, actionData) 6829 } 6830 }, 6831 6832 sendChangeMethodEvent (methodName) { 6833 } 6834 }); 6835});; 6836/* AUTOGENERATED: ga-ec-checkout.js */ 6837/* vim: set ts=2 sw=2 sts=2 et: */ 6838 6839/** 6840 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 6841 * See https://www.x-cart.com/license-agreement.html for license details. 6842 */ 6843 6844define('googleAnalytics/base/eCommerceCheckoutStepsEvent', ['googleAnalytics/eCommerceCoreEvent', 'js/underscore'], 6845 function (eCommerceCoreEvent, _) { 6846 6847 return eCommerceCoreEvent.extend({ 6848 ADDRESS_STEP: 'address', 6849 SHIPPING_STEP: 'shipping', 6850 PAYMENT_STEP: 'payment', 6851 PLACE_STEP: 'place', 6852 COMPLETE_STEP: 'complete', 6853 6854 namespace: 'Checkout', 6855 6856 getListeners () { 6857 return { 6858 'ga-checkout-step-entered': this.handleStepEntered, 6859 'ga-checkout-step-completed': this.handleStepCompleted 6860 } 6861 }, 6862 6863 handleStepEntered (event, data) { 6864 var actionData = _.first( 6865 this.getActions('checkout') 6866 ) 6867 6868 if (actionData) { 6869 this._handleStepEntered(data.step, data, actionData) 6870 } 6871 }, 6872 6873 handleStepCompleted (event, data) { 6874 const actionsName = data.step === this.COMPLETE_STEP
6875 ? 'checkout_complete' 6876 : 'checkout' 6877 var actionData = _.first( 6878 this.getActions(actionsName) 6879 ) 6880 6881 if (actionData) { 6882 this._handleStepCompleted(data.step, data, actionData) 6883 } 6884 }, 6885 6886 6887 _handleStepEntered (step, data, actionData) { 6888 }, 6889 _handleStepCompleted (step, data, actionData) { 6890 } 6891 }); 6892 } 6893);; 6894/* AUTOGENERATED: checkout-complete.js */ 6895/* vim: set ts=2 sw=2 sts=2 et: */ 6896 6897/** 6898 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 6899 * See https://www.x-cart.com/license-agreement.html for license details. 6900 */ 6901 6902define('googleAnalytics/checkoutCompleteEvent', ['googleAnalytics/eCommerceCoreEvent'], function(eCommerceCoreEvent) { 6903 let GACheckoutCompleteEvent = eCommerceCoreEvent.extend({ 6904 namespace: 'Checkout', 6905 6906 getListeners () { 6907 return { 6908 'ga-pageview-sending': this.registerInvoiceEnter 6909 } 6910 }, 6911 6912 registerInvoiceEnter () { 6913 xcart.trigger('ga-checkout-step-completed', { 6914 step: 'complete' 6915 }) 6916 } 6917 }) 6918 6919 GACheckoutCompleteEvent.instance = new GACheckoutCompleteEvent(); 6920 6921 return GACheckoutCompleteEvent; 6922});; 6923/* AUTOGENERATED: ga-ec-purchase.js */ 6924/* vim: set ts=2 sw=2 sts=2 et: */ 6925 6926/** 6927 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 6928 * See https://www.x-cart.com/license-agreement.html for license details. 6929 */ 6930 6931define('googleAnalytics/base/eCommercePurchaseEvent', ['googleAnalytics/eCommerceCoreEvent', 'js/underscore'], 6932 function (eCommerceCoreEvent, _) { 6933 return eCommerceCoreEvent.extend({ 6934 6935 getListeners () { 6936 return { 6937 'ga-pageview-sending': this.registerPurchase 6938 } 6939 }, 6940 6941 registerPurchase (event, data) { 6942 //to prevent sending purchase action before step 5 checkout action 6943 setTimeout(this._registerPurchase.bind(this), 300) 6944 }, 6945 6946 _registerPurchase (event, data) { 6947 var actionData = _.first(this.getActions('purchase')) 6948 6949 if (actionData) { 6950 this._registerPurchaseEvent( 6951 actionData['data']['products'], 6952 actionData['data']['actionData'] 6953 ) 6954 } 6955 }, 6956 6957 _registerPurchaseEvent (productsData, actionData) { 6958 } 6959 6960 }); 6961 } 6962);; 6963/* AUTOGENERATED: ga-vehicle.js */ 6964/* vim: set ts=2 sw=2 sts=2 et: */ 6965 6966/** 6967 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 6968 * See https://www.x-cart.com/license-agreement.html for license details. 6969 */ 6970 6971define('googleAnalytics/base/vehicle_event', ['googleAnalytics/eCommerceCoreEvent'], function (eCommerceCoreEvent) { 6972 6973 return eCommerceCoreEvent.extend({ 6974 namespace: 'vehicleEvent', 6975 6976 findGaLevelSelectorData () { 6977 return $('.last_make_vehicle_data') 6978 }, 6979 6980 processReady () { 6981 this.processGaEvents() 6982 this.processSuccessfullySelectedVin() 6983 }, 6984 6985 processGaEvents () { 6986 const levelSelectors = this.findGaLevelSelectorData() 6987 6988 if (!levelSelectors.length) { 6989 return 6990 } 6991 6992 const _this = this 6993 6994 levelSelectors.each(function () { 6995 const gaEvent = $(this).attr('data-ga-ec-action') 6996 const parsedEvent = JSON.parse(gaEvent) 6997 _this.sendVehicleEvent(parsedEvent) 6998 }) 6999 }, 7000 7001 processSuccessfullySelectedVin() { 7002 const _this = this 7003 xcart.bind('vinSuccessfullySelectedGA', function (event, data) { 7004 const formattedEvent = _this.formatVinDataForSendEvent(data.data) 7005 const configuredEvents = _this.setEventsForVinSelect(formattedEvent, data.data.isAddToGarage) 7006 configuredEvents.forEach((item) => { 7007 _this.sendVehicleEvent(item) 7008 }) 7009 }); 7010 }, 7011 7012 formatVinDataForSendEvent(data) { 7013 const levels = [1, 2, 3, 4] 7014 let eventData = { 7015 data: { 7016 vehicle: '', 7017 } 7018 } 7019 7020 levels.forEach(function (item, index) { 7021 if (data.selected[item]) { 7022 if (index > 0) { 7023 7024 eventData.data.vehicle += '/'; 7025 } 7026 eventData.data.vehicle += data.selected[item].value; 7027 } 7028 }); 7029
7030 const keys = Object.keys(data.selected) 7031 7032 const lastKey = keys[keys.length - 1] 7033 7034 eventData.data['level' + lastKey + '_id'] = data.selected[lastKey].id; 7035 7036 return eventData 7037 }, 7038 7039 setEventsForVinSelect(event, isAddToGarage) { 7040 let events = [{...event, 'ga-type': 'select_vehicle'}] 7041 7042 if (isAddToGarage) { 7043 events.push({...event, 'ga-type': 'add_vehicle'}) 7044 } 7045 7046 return events 7047 }, 7048 7049 sendVehicleEvent (eventData) { 7050 7051 } 7052 7053 }) 7054});; 7055/* AUTOGENERATED: ga-ec-impressions.js */ 7056/* vim: set ts=2 sw=2 sts=2 et: */ 7057 7058/** 7059 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 7060 * See https://www.x-cart.com/license-agreement.html for license details. 7061 */ 7062 7063define('googleAnalytics/eCommerceImpressionsEvent', ['googleAnalytics/base/eCommerceImpressionsEvent', 'js/underscore'], function (eCommerceImpressionsEventBase, _) { 7064 let eCommerceImpressionEvent = eCommerceImpressionsEventBase.extend({ 7065 getImpressionHash (data) { 7066 return window.xcart.utils.hash( 7067 _.omit(data, 'position') 7068 ) 7069 }, 7070 7071 addImpressionAction (data) { 7072 this.sendECEvent('addImpression', data) 7073 }, 7074 7075 flushImpressions () { 7076 this.sendPageView() 7077 } 7078 }) 7079 7080 eCommerceImpressionEvent.instance = new eCommerceImpressionEvent(); 7081 7082 return eCommerceImpressionEvent; 7083});; 7084/* AUTOGENERATED: ga-ec-shopping-cart.js */ 7085/* vim: set ts=2 sw=2 sts=2 et: */ 7086 7087/** 7088 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 7089 * See https://www.x-cart.com/license-agreement.html for license details. 7090 */ 7091 7092define('googleAnalytics/GAShoppingCartHandleEvent', ['googleAnalytics/base/GAShoppingCartHandleEvent', 'googleAnalytics/eCommerceCoreEvent'], function(GAShoppingCartHandleEventBase, eCommerceCoreEvent) { 7093 let GAShoppingCartHandleEvent = GAShoppingCartHandleEventBase.extend({ 7094 7095 registerAddItem(item, quantity_change) { 7096 item.quantity = Math.abs(quantity_change); 7097 7098 this.sendECEvent('addProduct', item); 7099 this.sendECEvent('add', {}, true); 7100 7101 this.sendEvent('AddToCart', 'Add to cart'); 7102 }, 7103 7104 registerRemoveItem(item, quantity_change) { 7105 item.quantity = Math.abs(quantity_change); 7106 7107 this.sendECEvent('addProduct', item); 7108 this.sendECEvent('remove', {}, true); 7109 7110 this.sendEvent('RemoveFromCart', 'Remove from cart'); 7111 }, 7112 7113 }); 7114 7115 GAShoppingCartHandleEvent.instance = new GAShoppingCartHandleEvent(); 7116 7117 return GAShoppingCartHandleEvent; 7118});; 7119/* AUTOGENERATED: ga-ec-change-item.js */ 7120/* vim: set ts=2 sw=2 sts=2 et: */ 7121 7122/** 7123 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 7124 * See https://www.x-cart.com/license-agreement.html for license details. 7125 */ 7126 7127define('googleAnalytics/eCommerceChangeItemEvent', ['googleAnalytics/base/eCommerceChangeItemEvent', 'js/underscore'],function (eCommerceChangeItemEventBase, _) { 7128 let eCommerceChangeItemEvent = eCommerceChangeItemEventBase.extend({ 7129 7130 registerAddToCart (event, data) { 7131 var gaProductData = data.gaProductData 7132 7133 if (gaProductData) { 7134 this.sendECEvent('addProduct', gaProductData) 7135 7136 var actionData = {} 7137 if (!_.isUndefined(gaProductData.list)) { 7138 actionData.list = gaProductData.list 7139 } 7140 this.sendECEvent('add', actionData, true) 7141 7142 this.sendEvent('AddToCart', 'Add to cart') 7143 } 7144 }, 7145 7146 registerAddsToCart (event, products) { 7147 products.forEach((product) => this.registerAddToCart(event, product)) 7148 } 7149 7150 }); 7151 7152 eCommerceChangeItemEvent.instance = new eCommerceChangeItemEvent(); 7153 7154 return eCommerceChangeItemEvent; 7155 } 7156);; 7157/* AUTOGENERATED: ga-ec-product-details-shown.js */ 7158/* vim: set ts=2 sw=2 sts=2 et: */ 7159 7160/** 7161 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 7162 * See https://www.x-cart.com/license-agreement.html for license details. 7163 */ 7164 7165define('googleAnalytics/eCommerceDetailsShownEvent', ['googleAnalytics/base/eCommerceDetailsShownEvent', 'js/underscore'], function (eCommerceDetailsShownEventBase, _) { 7166 let eCommerceDetailsShownEvent = eCommerceDetailsShownEventBase.extend({ 7167 7168 registerDetailsShown(addProductData) { 7169 this.sendECEvent('addProduct', addProductData); 7170 this.sendECEvent('detail', {}, true); 7171 }, 7172 7173 }); 7174 7175 eCommerceDetailsShownEvent.instance = new eCommerceDetailsShownEvent(); 7176 7177 return eCommerceDetailsShownEvent; 7178});;
7179/* AUTOGENERATED: ga-ec-product-click.js */ 7180/* vim: set ts=2 sw=2 sts=2 et: */ 7181 7182/** 7183 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 7184 * See https://www.x-cart.com/license-agreement.html for license details. 7185 */ 7186 7187define('googleAnalytics/eCommerceProductClickEvent', ['googleAnalytics/base/eCommerceProductClickEvent', 'js/underscore'], function (eCommerceProductClickEventBase, _) { 7188 let eCommerceProductClickEvent = eCommerceProductClickEventBase.extend({ 7189 7190 onProductDetailsClick (data, event) { 7191 this.sendECEvent('addProduct', data) 7192 this.sendECEvent('click', { 7193 list: data.list 7194 }, true) 7195 } 7196 7197 }); 7198 7199 eCommerceProductClickEvent.instance = new eCommerceProductClickEvent(); 7200 7201 return eCommerceProductClickEvent; 7202});; 7203/* AUTOGENERATED: ga-change-shipping.js */ 7204/* vim: set ts=2 sw=2 sts=2 et: */ 7205 7206/** 7207 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 7208 * See https://www.x-cart.com/license-agreement.html for license details. 7209 */ 7210 7211define('googleAnalytics/changeShippingEvent', [ 'googleAnalytics/base/changeShippingEvent', 'googleAnalytics/event' ], function(GAChangeShippingEventBase, Event) { 7212 let GAChangeShippingEvent = GAChangeShippingEventBase.extend({ 7213 sendChangeMethodEvent(methodName) { 7214 this.sendEvent('changeShippingMethod', methodName, methodName, 'checkout'); 7215 } 7216 }); 7217 7218 GAChangeShippingEvent.instance = new GAChangeShippingEvent(); 7219 7220 return GAChangeShippingEvent; 7221});; 7222/* AUTOGENERATED: ga-change-payment.js */ 7223/* vim: set ts=2 sw=2 sts=2 et: */ 7224 7225/** 7226 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 7227 * See https://www.x-cart.com/license-agreement.html for license details. 7228 */ 7229 7230define('googleAnalytics/changePaymentMethod', [ 'googleAnalytics/base/changePaymentMethod', 'googleAnalytics/event' ], function(GAChangePaymentEventBase, Event) { 7231 let GAChangePaymentEvent = GAChangePaymentEventBase.extend({ 7232 sendChangeMethodEvent(methodName) { 7233 this.sendEvent('changePaymentMethod', methodName, methodName, 'checkout'); 7234 } 7235 }); 7236 7237 GAChangePaymentEvent.instance = new GAChangePaymentEvent(); 7238 7239 return GAChangePaymentEvent; 7240});; 7241/* AUTOGENERATED: ga-ec-checkout.js */ 7242/* vim: set ts=2 sw=2 sts=2 et: */ 7243 7244/** 7245 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 7246 * See https://www.x-cart.com/license-agreement.html for license details. 7247 */ 7248 7249define('googleAnalytics/eCommerceCheckoutStepsEvent', [ 'googleAnalytics/base/eCommerceCheckoutStepsEvent', 'googleAnalytics/event' ], function(eCommerceCheckoutStepBaseEvent, Event) { 7250 let eCommerceCheckoutStepEvent = eCommerceCheckoutStepBaseEvent.extend({ 7251 _handleStepEntered(step, data, actionData) { 7252 switch (step) { 7253 case this.ADDRESS_STEP: 7254 this._registerECommerceCheckout(actionData.products, {step: 1}) 7255 this._registerCheckoutEvent('Checkout entered') 7256 break; 7257 7258 case this.SHIPPING_STEP: 7259 let actionDataLocal = { 7260 step: 2 7261 } 7262 7263 if (!_.isUndefined(actionData.data.shipping_method)) { 7264 actionDataLocal.option = actionData.data.shipping_method; 7265 } 7266 7267 this._registerECommerceCheckout(actionData.products, actionDataLocal) 7268 this._registerCheckoutEvent('Checkout continue') 7269 break; 7270 7271 case this.PAYMENT_STEP: 7272 this._registerECommerceCheckout(actionData.products, {step: 3}) 7273 this._registerCheckoutEvent('Checkout continue') 7274 break; 7275 7276 case this.PLACE_STEP: 7277 this._registerECommerceCheckout(actionData.products, {step: 4}) 7278 this._registerCheckoutEvent('Checkout continue') 7279 break; 7280 7281 case this.COMPLETE_STEP: 7282 break; 7283 } 7284 }, 7285 7286 _handleStepCompleted(step, data, actionData) { 7287 switch (step) { 7288 case this.ADDRESS_STEP: 7289 this.sendCheckoutOption({ 7290 step: 1, 7291 option: "Address choosen" 7292 }) 7293 break; 7294 7295 case this.SHIPPING_STEP: 7296 this.sendCheckoutOption({ 7297 step: 2, 7298 option: data.option 7299 }) 7300 break; 7301 7302 case this.PAYMENT_STEP: 7303 this.sendCheckoutOption({ 7304 step: 3, 7305 option: data.option 7306 }) 7307 break; 7308 7309 case this.PLACE_STEP: 7310 this.sendCheckoutOption({ 7311 step: 4, 7312 option: data 7313 }) 7314 break; 7315 7316 case this.COMPLETE_STEP: 7317 this._registerECommerceCheckout(actionData.products, {step: 5}) 7318 this._registerCheckoutEvent('Checkout success') 7319 break; 7320 } 7321 }, 7322 7323 _registerECommerceCheckout(productsData, actionData) { 7324 const self = this 7325 _.each(productsData, function (product) { 7326 self.sendECEvent('addProduct', product) 7327 }); 7328 7329 this.sendECEvent('checkout', actionData || {}, true) 7330 }, 7331 7332 _registerCheckoutEvent(data) { 7333 this.sendEvent('Checkout', data) 7334 }, 7335 7336 sendCheckoutOption(data) { 7337 this._sendCheckoutOption(data); 7338 7339 this._registerCheckoutEvent('Option'); 7340 }, 7341 7342 _sendCheckoutOption(data) { 7343 if (!data || _.isUndefined(data.option)) { 7344 return; 7345 } 7346 7347 this.sendECEvent('checkout_option', data, true) 7348 }, 7349 }); 7350 7351 eCommerceCheckoutStepEvent.instance = new eCommerceCheckoutStepEvent(); 7352 7353 return eCommerceCheckoutStepEvent; 7354});;
7355/* AUTOGENERATED: ga-ec-purchase.js */ 7356/* vim: set ts=2 sw=2 sts=2 et: */ 7357 7358/** 7359 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 7360 * See https://www.x-cart.com/license-agreement.html for license details. 7361 */ 7362 7363define('googleAnalytics/purchaseEvent', ['googleAnalytics/base/eCommercePurchaseEvent', 'js/underscore'], 7364 function (eCommercePurchaseBaseEvent, _) { 7365 let eCommercePurchaseEvent = eCommercePurchaseBaseEvent.extend({ 7366 _registerPurchaseEvent(productsData, actionData) { 7367 const self = this 7368 _.each(productsData, function (product) { 7369 self.sendECEvent('addProduct', product) 7370 }); 7371 7372 this.sendECEvent('purchase', actionData || {}, true) 7373 this.sendEvent('Checkout', 'Purchase') 7374 }, 7375 7376 }); 7377 7378 eCommercePurchaseEvent.instance = new eCommercePurchaseEvent(); 7379 7380 return eCommercePurchaseEvent; 7381 } 7382);; 7383/* AUTOGENERATED: ga-vehicle.js */ 7384/* vim: set ts=2 sw=2 sts=2 et: */ 7385 7386/** 7387 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 7388 * See https://www.x-cart.com/license-agreement.html for license details. 7389 */ 7390 7391define('googleAnalytics/vehicle_event', ['googleAnalytics/base/vehicle_event'], function (vehicleEvent) { 7392 const handleVehicleEvent = vehicleEvent.extend({ 7393 sendVehicleEvent (eventData) { 7394 this.sendEvent(eventData['ga-type'], JSON.stringify(eventData['data'])) 7395 } 7396 }) 7397 7398 handleVehicleEvent.instance = new handleVehicleEvent() 7399 7400 return handleVehicleEvent 7401});; 7402/* AUTOGENERATED: sticky_footer.js */ 7403/* vim: set ts=2 sw=2 sts=2 et: */ 7404 7405/** 7406 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 7407 * See https://www.x-cart.com/license-agreement.html for license details. 7408 */ 7409 7410(function() { 7411 var browserDetectCache = null; 7412 7413 function isIE() { 7414 if (browserDetectCache === null) { 7415 var 7416 ua = navigator.userAgent, 7417 browser = /Edge\/\d+/.test(ua) ? 'ed' : /MSIE 9/.test(ua) ? 'ie9' : /MSIE 10/.test(ua) ? 'ie10' : /MSIE 11/.test(ua) ? 'ie11' : /MSIE\s\d/.test(ua) ? 'ie?' : /rv\:11/.test(ua) ? 'ie11' : /Firefox\W\d/.test(ua) ? 'ff' : /Chrome\W\d/.test(ua) ? 'gc' : /Chromium\W\d/.test(ua) ? 'oc' : /\bSafari\W\d/.test(ua) ? 'sa' : /\bOpera\W\d/.test(ua) ? 'op' : /\bOPR\W\d/i.test(ua) ? 'op' : typeof MSPointerEvent !== 'undefined' ? 'ie?' : '', 7418 os = /Windows NT 10/.test(ua) ? "win10" : /Windows NT 6\.0/.test(ua) ? "winvista" : /Windows NT 6\.1/.test(ua) ? "win7" : /Windows NT 6\.\d/.test(ua) ? "win8" : /Windows NT 5\.1/.test(ua) ? "winxp" : /Windows NT [1-5]\./.test(ua) ? "winnt" : /Mac/.test(ua) ? "mac" : /Linux/.test(ua) ? "linux" : /X11/.test(ua) ? "nix" : ""; 7419 7420 browserDetectCache = browser.indexOf('ie') === 0; 7421 } 7422 7423 return browserDetectCache; 7424 } 7425 7426 function repositionStickyFooter() { 7427 if (isIE()) { 7428 var footer = document.getElementById('footer-area'); 7429 var space = document.documentElement.scrollHeight - (footer.offsetTop + footer.offsetHeight); 7430 7431 footer.style.paddingTop = space + 'px'; 7432 } 7433 } 7434 7435 repositionStickyFooter(); 7436 window.onresize = repositionStickyFooter; 7437})();; 7438/* AUTOGENERATED: responsive_navbar.js */ 7439/* vim: set ts=2 sw=2 sts=2 et: */ 7440 7441/** 7442 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 7443 * See https://www.x-cart.com/license-agreement.html for license details. 7444 */ 7445 7446(function() { 7447 7448 function loadWidget(widget, selector, dfd) { 7449 xcart.get({ 7450 target: "main", 7451 widget: widget 7452 }).done(function(data) { 7453 if ($(selector).children().length > 0) { 7454 dfd.resolve(); 7455 return; 7456 } 7457 7458 var widget = $(data); 7459 7460 var uuid = _.uniqueId(); 7461 7462 xcart.bind(['resources.ready', 'resources.empty'], _.bind( 7463 function(event, args){ 7464 if (args.uuid === uuid) { 7465 var newContent = widget.find(selector); 7466 $(selector).replaceWith(newContent); 7467 7468 dfd.resolve(); 7469 } 7470 }, 7471 this) 7472 ); 7473 7474 xcart.parsePreloadedLabels(widget, uuid); 7475 xcart.parseResources(widget, uuid); 7476 }); 7477 } 7478 7479 function loadDesktopNavbar() { 7480 var dfd = new jQuery.Deferred(); 7481 var responsiveClass = getResponsiveClass(document.body); 7482 7483 if (responsiveClass !== 'mobile' || !responsiveClass) { 7484 dfd.resolve(); 7485 } else { 7486 loadWidget("XLite\\View\\Layout\\Customer\\DesktopNavbar", "[data-desktop-navbar]", dfd); 7487 } 7488 7489 return dfd; 7490 } 7491 7492 function loadMobileNavbar() { 7493 var dfd = new jQuery.Deferred(); 7494 var responsiveClass = getResponsiveClass(document.body); 7495 7496 if (responsiveClass !== 'desktop' || !responsiveClass) { 7497 dfd.resolve(); 7498 } else { 7499 loadWidget("XLite\\View\\Slidebar", "[data-mobile-navbar]", dfd); 7500 } 7501 7502 return dfd; 7503 } 7504 7505 function getResponsiveClass(element) { 7506 var matches = element.className.match(/responsive-(\w+)/); //get a match to match the pattern some-class-somenumber and extract that classname 7507 7508 if (matches) { 7509 return matches[1]; 7510 } 7511 7512 return null; 7513 } 7514 7515 function loadNavbars() { 7516 loadDesktopNavbar().then(function() { 7517 xcart.trigger('navbar.desktop.loaded'); 7518 }); 7519
7520 loadMobileNavbar().then(function() { 7521 xcart.trigger('navbar.mobile.loaded'); 7522 }); 7523 } 7524 7525 loadNavbars(); 7526})();; 7527/* AUTOGENERATED: bootstrap-tabcollapse.js */ 7528!function ($) { 7529 7530 "use strict"; 7531 7532 // TABCOLLAPSE CLASS DEFINITION 7533 // ====================== 7534 7535 var TabCollapse = function (el, options) { 7536 this.options = options; 7537 this.$tabs = $(el); 7538 7539 this._accordionVisible = false; //content is attached to tabs at first 7540 this._initAccordion(); 7541 this._checkStateOnResize(); 7542 7543 7544 // checkState() has gone to setTimeout for making it possible to attach listeners to 7545 // shown-accordion.bs.tabcollapse event on page load. 7546 // See https://github.com/flatlogic/bootstrap-tabcollapse/issues/23 7547 var that = this; 7548 setTimeout(function() { 7549 that.checkState(); 7550 }, 0); 7551 }; 7552 7553 TabCollapse.DEFAULTS = { 7554 accordionClass: 'visible-xs', 7555 tabsClass: 'hidden-xs', 7556 accordionTemplate: function(heading, groupId, parentId, active) { 7557 return '<div class="panel panel-default">' + 7558 ' <div class="panel-heading">' + 7559 ' <h4 class="panel-title">' + 7560 ' </h4>' + 7561 ' </div>' + 7562 ' <div id="' + groupId + '" data-parent="#' + parentId + '" class="panel-collapse collapse ' + (active ? 'in' : '') + '">' + 7563 ' <div class="panel-body js-tabcollapse-panel-body">' + 7564 ' </div>' + 7565 ' </div>' + 7566 '</div>' 7567 7568 } 7569 }; 7570 7571 TabCollapse.prototype.checkState = function(){ 7572 if (this.$tabs.is(':visible') && this._accordionVisible){ 7573 this.showTabs(); 7574 this._accordionVisible = false; 7575 } else if (this.$accordion.is(':visible') && !this._accordionVisible){ 7576 this.showAccordion(); 7577 this._accordionVisible = true; 7578 } 7579 }; 7580 7581 TabCollapse.prototype.showTabs = function(){ 7582 var view = this; 7583 this.$tabs.trigger($.Event('show-tabs.bs.tabcollapse')); 7584 7585 var $panelHeadings = this.$accordion.find('.js-tabcollapse-panel-heading').detach(); 7586 7587 $panelHeadings.each(function() { 7588 var $panelHeading = $(this), 7589 $parentLi = $panelHeading.data('bs.tabcollapse.parentLi'); 7590 7591 var $oldHeading = view._panelHeadingToTabHeading($panelHeading); 7592 7593 $parentLi.removeClass('active'); 7594 if ($parentLi.parent().hasClass('dropdown-menu') && !$parentLi.siblings('li').hasClass('active')) { 7595 $parentLi.parent().parent().removeClass('active'); 7596 } 7597 7598 if (!$oldHeading.hasClass('collapsed')) { 7599 $parentLi.addClass('active'); 7600 if ($parentLi.parent().hasClass('dropdown-menu')) { 7601 $parentLi.parent().parent().addClass('active'); 7602 } 7603 } else { 7604 $oldHeading.removeClass('collapsed'); 7605 } 7606 7607 $parentLi.append($panelHeading); 7608 }); 7609 7610 if (!$('li').hasClass('active')) { 7611 $('li').first().addClass('active') 7612 } 7613 7614 var $panelBodies = this.$accordion.find('.js-tabcollapse-panel-body'); 7615 $panelBodies.each(function(){ 7616 var $panelBody = $(this), 7617 $tabPane = $panelBody.data('bs.tabcollapse.tabpane'); 7618 $tabPane.append($panelBody.contents().detach()); 7619 }); 7620 this.$accordion.html(''); 7621 7622 if(this.options.updateLinks) { 7623 var $tabContents = this.getTabContentElement(); 7624 $tabContents.find('[data-toggle-was="tab"], [data-toggle-was="pill"]').each(function() { 7625 var $el = $(this); 7626 var href = $el.attr('href').replace(/-collapse$/g, ''); 7627 $el.attr({ 7628 'data-toggle': $el.attr('data-toggle-was'), 7629 'data-toggle-was': '', 7630 'data-parent': '', 7631 href: href 7632 }); 7633 }); 7634 } 7635 7636 this.$tabs.trigger($.Event('shown-tabs.bs.tabcollapse')); 7637 }; 7638
7639 TabCollapse.prototype.getTabContentElement = function(){ 7640 var $tabContents = $(this.options.tabContentSelector); 7641 if($tabContents.length === 0) { 7642 $tabContents = this.$tabs.siblings('.tab-content'); 7643 } 7644 return $tabContents; 7645 }; 7646 7647 TabCollapse.prototype.showAccordion = function(){ 7648 this.$tabs.trigger($.Event('show-accordion.bs.tabcollapse')); 7649 7650 var $headings = this.$tabs.find('li:not(.dropdown) [data-toggle="tab"], li:not(.dropdown) [data-toggle="pill"]'), 7651 view = this; 7652 $headings.each(function(){ 7653 var $heading = $(this), 7654 $parentLi = $heading.parent(); 7655 $heading.data('bs.tabcollapse.parentLi', $parentLi); 7656 view.$accordion.append(view._createAccordionGroup(view.$accordion.attr('id'), $heading.detach())); 7657 }); 7658 7659 if(this.options.updateLinks) { 7660 var parentId = this.$accordion.attr('id'); 7661 var $selector = this.$accordion.find('.js-tabcollapse-panel-body'); 7662 $selector.find('[data-toggle="tab"], [data-toggle="pill"]').each(function() { 7663 var $el = $(this); 7664 var href = $el.attr('href') + '-collapse'; 7665 $el.attr({ 7666 'data-toggle-was': $el.attr('data-toggle'), 7667 'data-toggle': 'collapse', 7668 'data-parent': '#' + parentId, 7669 href: href 7670 }); 7671 }); 7672 } 7673 7674 this.$tabs.trigger($.Event('shown-accordion.bs.tabcollapse')); 7675 }; 7676 7677 TabCollapse.prototype._panelHeadingToTabHeading = function($heading) { 7678 var href = $heading.attr('href').replace(/-collapse$/g, ''); 7679 $heading.attr({ 7680 'data-toggle': 'tab', 7681 'href': href, 7682 'data-parent': '' 7683 }); 7684 return $heading; 7685 }; 7686 7687 TabCollapse.prototype._tabHeadingToPanelHeading = function($heading, groupId, parentId, active) { 7688 $heading.addClass('js-tabcollapse-panel-heading ' + (active ? '' : 'collapsed')); 7689 $heading.attr({ 7690 'data-toggle': 'collapse', 7691 'data-target': '#' + groupId, 7692 'href': '#' + groupId 7693 }); 7694 return $heading; 7695 }; 7696 7697 TabCollapse.prototype._checkStateOnResize = function(){ 7698 var view = this; 7699 $(window).resize(function(){ 7700 clearTimeout(view._resizeTimeout); 7701 view._resizeTimeout = setTimeout(function(){ 7702 view.checkState(); 7703 }, 100); 7704 }); 7705 }; 7706 7707 7708 TabCollapse.prototype._initAccordion = function(){ 7709 var randomString = function() { 7710 var result = "", 7711 possible = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789"; 7712 for( var i=0; i < 5; i++ ) { 7713 result += possible.charAt(Math.floor(Math.random() * possible.length)); 7714 } 7715 return result; 7716 }; 7717 7718 var srcId = this.$tabs.attr('id'), 7719 accordionId = (srcId ? srcId : randomString()) + '-accordion'; 7720 7721 this.$accordion = $('<div class="panel-group ' + this.options.accordionClass + '" id="' + accordionId +'"></div>'); 7722 this.$tabs.after(this.$accordion); 7723 this.$tabs.addClass(this.options.tabsClass); 7724 this.getTabContentElement().addClass(this.options.tabsClass); 7725 }; 7726 7727 TabCollapse.prototype._createAccordionGroup = function(parentId, $heading){ 7728 var tabSelector = $heading.attr('data-target'), 7729 active = $heading.data('bs.tabcollapse.parentLi').is('.active'); 7730 7731 if (!tabSelector) { 7732 tabSelector = $heading.attr('href'); 7733 tabSelector = tabSelector && tabSelector.replace(/.*(?=#[^\s]*$)/, ''); //strip for ie7 7734 } 7735 7736 var $tabPane = $(tabSelector), 7737 groupId = $tabPane.attr('id') + '-collapse', 7738 $panel = $(this.options.accordionTemplate($heading, groupId, parentId, active)); 7739 $panel.find('.panel-heading > .panel-title').append(this._tabHeadingToPanelHeading($heading, groupId, parentId, active)); 7740 $panel.find('.panel-body').append($tabPane.contents().detach()) 7741 .data('bs.tabcollapse.tabpane', $tabPane); 7742 7743 return $panel; 7744 }; 7745 7746 7747 7748 // TABCOLLAPSE PLUGIN DEFINITION 7749 // ======================= 7750 7751 $.fn.tabCollapse = function (option) { 7752 return this.each(function () { 7753 var $this = $(this); 7754 var data = $this.data('bs.tabcollapse'); 7755 var options = $.extend({}, TabCollapse.DEFAULTS, $this.data(), typeof option === 'object' && option); 7756 7757 if (!data) $this.data('bs.tabcollapse', new TabCollapse(this, options)); 7758 }); 7759 }; 7760 7761 $.fn.tabCollapse.Constructor = TabCollapse; 7762 7763 7764}(window.jQuery);; 7765/* AUTOGENERATED: jquery.collapser.js */ 7766/* vim: set ts=2 sw=2 sts=2 et: */ 7767 7768/** 7769 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 7770 * See https://www.x-cart.com/license-agreement.html for license details. 7771 */ 7772 7773(function($) { 7774 7775 var defaults = { 7776 accordion: true, 7777 7778 submenu: "ul", 7779 item: "li", 7780 firstOpen: false, 7781 }; 7782 7783 options = {}; 7784 7785 // jQuery plugin definition 7786 $.fn.collapser = function(overrides) { 7787 if ('undefined' === typeof(overrides)) { 7788 overrides = {}; 7789 } 7790 7791 options = _.defaults(overrides, defaults); 7792 7793 initialize(this); 7794 7795 return this; 7796 }; 7797 7798 function initialize(base) { 7799 if (base) { 7800 var parent = $(base); 7801 var items = parent.children(options.item); 7802 items.each(function() { 7803 var submenu = $(this).children(options.submenu); 7804 var link = $(document.createElement('a')) 7805 link.addClass('collapser'); 7806 link.on('click', function() { 7807 submenu.collapse('toggle'); 7808 }); 7809 7810 $(this).prepend(link); 7811 7812 submenu.on('show.bs.collapse',function() { 7813 link.removeClass('trigger-show'); 7814 link.addClass('trigger-hide'); 7815 }); 7816 submenu.on('hide.bs.collapse',function() { 7817 link.removeClass('trigger-hide'); 7818 link.addClass('trigger-show'); 7819 }); 7820 submenu.addClass('in'); 7821 submenu.collapse(); 7822 7823 return this; 7824 }); 7825 7826 if (options.firstOpen) { 7827 items.children(options.submenu).first().toggle(); 7828 } 7829 7830 parent.on('show.bs.collapse', function () { 7831 if (options.accordion) parent.find('.in').collapse('hide'); 7832 }); 7833 } 7834 } 7835 7836})(jQuery);; 7837/* AUTOGENERATED: jquery.actual.min.js */ 7838/*! Copyright 2012, Ben Lin (http://dreamerslab.com/) 7839 * Licensed under the MIT License (LICENSE.txt). 7840 * 7841 * Version: 1.0.19 7842 * 7843 * Requires: jQuery >= 1.2.3 7844 */
7845(function(a){if(typeof define==="function"&&define.amd){define(["jquery"],a); 7846}else{a(jQuery);}}(function(a){a.fn.addBack=a.fn.addBack||a.fn.andSelf;a.fn.extend({actual:function(b,l){if(!this[b]){throw'$.actual => The jQuery method "'+b+'" you called does not exist'; 7847}var f={absolute:false,clone:false,includeMargin:false,display:"block"};var i=a.extend(f,l);var e=this.eq(0);var h,j;if(i.clone===true){h=function(){var m="position: absolute !important; top: -1000 !important; "; 7848e=e.clone().attr("style",m).appendTo("body");};j=function(){e.remove();};}else{var g=[];var d="";var c;h=function(){c=e.parents().addBack().filter(":hidden"); 7849d+="visibility: hidden !important; display: "+i.display+" !important; ";if(i.absolute===true){d+="position: absolute !important; ";}c.each(function(){var m=a(this); 7850var n=m.attr("style");g.push(n);m.attr("style",n?n+";"+d:d);});};j=function(){c.each(function(m){var o=a(this);var n=g[m];if(n===undefined){o.removeAttr("style"); 7851}else{o.attr("style",n);}});};}h();var k=/(outer)/.test(b)?e[b](i.includeMargin):e[b]();j();return k;}});}));; 7852/* AUTOGENERATED: jquery.floating-label.js */ 7853/* vim: set ts=2 sw=2 sts=2 et: */ 7854 7855/** 7856 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 7857 * See https://www.x-cart.com/license-agreement.html for license details. 7858 */ 7859 7860(function ($) { 7861 7862 var defaults = {} 7863 7864 options = {} 7865 7866 // jQuery plugin definition 7867 $.fn.floatingLabel = function (options) { 7868 if ('undefined' === typeof (options)) { 7869 options = {} 7870 } 7871 7872 pluginOptions = _.defaults(options, defaults) 7873 7874 if (this.length > 0) { 7875 this.each(function () { 7876 const parent = findParent(this) 7877 if (parent) { 7878 const label = jQuery(parent).find('label') 7879 7880 const labelWidth = parent.is(':hidden') ? label.actual('outerWidth') : label.outerWidth() 7881 const elemWidth = parent.is(':hidden') ? jQuery(this).actual('outerWidth') : jQuery(this).outerWidth() 7882 7883 if (labelWidth < elemWidth) { 7884 assignHandlers(this) 7885 7886 // capture initial state 7887 handler.apply(this, [null]) 7888 } else if (parent && parent.length) { 7889 parent.addClass('not-floating') 7890 } 7891 } 7892 }) 7893 } 7894 7895 return this 7896 } 7897 7898 function assignHandlers (element) { 7899 if (!element.floatingLabel) { 7900 element.floatingLabel = true 7901 $(element).on('focus blur change', handler) 7902 } 7903 } 7904 7905 function handler (e) { 7906 var item = findParent(this) 7907 if (item && item.length > 0) { 7908 7909 item.toggleClass('focused', ((e && e.type === 'focus') || this.value.length > 0 || document.activeElement === this)) 7910 item.toggleClass('no-value-selected', (this.value.length === 0)) 7911 } 7912 } 7913 7914 function findParent (element) { 7915 var parent = null 7916 if ($(element).siblings('label:not(.form-control-label)').length == 1) { 7917 parent = $(element).parent() 7918 } else if ($(element).closest('.floating-label').length > 0) { 7919 parent = $(element).closest('.floating-label') 7920 } else if ($(element).closest('.table-value').length > 0) { 7921 parent = $(element).closest('.table-value').parent() 7922 } 7923 7924 return parent 7925 } 7926 7927})(jQuery);; 7928/* AUTOGENERATED: jquery.path.js */ 7929/* 7930 * jQuery css bezier animation support -- Jonah Fox 7931 * version 0.0.1 7932 * Released under the MIT license. 7933 */ 7934/* 7935 var path = $.path.bezier({ 7936 start: {x:10, y:10, angle: 20, length: 0.3}, 7937 end: {x:20, y:30, angle: -20, length: 0.2} 7938 }) 7939 $("myobj").animate({path: path}, duration) 7940 7941*/ 7942 7943;(function($){ 7944 7945 $.path = {}; 7946 7947 var V = { 7948 rotate: function(p, degrees) { 7949 var radians = degrees * Math.PI / 180, 7950 c = Math.cos(radians), 7951 s = Math.sin(radians); 7952 return [c*p[0] - s*p[1], s*p[0] + c*p[1]]; 7953 }, 7954 scale: function(p, n) { 7955 return [n*p[0], n*p[1]]; 7956 }, 7957 add: function(a, b) { 7958 return [a[0]+b[0], a[1]+b[1]]; 7959 }, 7960 minus: function(a, b) { 7961 return [a[0]-b[0], a[1]-b[1]]; 7962 } 7963 }; 7964 7965 $.path.bezier = function( params, rotate ) { 7966 params.start = $.extend( {angle: 0, length: 0.3333}, params.start ); 7967 params.end = $.extend( {angle: 0, length: 0.3333}, params.end ); 7968 7969 this.p1 = [params.start.x, params.start.y]; 7970 this.p4 = [params.end.x, params.end.y]; 7971 7972 var v14 = V.minus( this.p4, this.p1 ), 7973 v12 = V.scale( v14, params.start.length ), 7974 v41 = V.scale( v14, -1 ), 7975 v43 = V.scale( v41, params.end.length ); 7976 7977 v12 = V.rotate( v12, params.start.angle ); 7978 this.p2 = V.add( this.p1, v12 ); 7979 7980 v43 = V.rotate(v43, params.end.angle ); 7981 this.p3 = V.add( this.p4, v43 ); 7982 7983 this.f1 = function(t) { return (t*t*t); }; 7984 this.f2 = function(t) { return (3*t*t*(1-t)); }; 7985 this.f3 = function(t) { return (3*t*(1-t)*(1-t)); }; 7986 this.f4 = function(t) { return ((1-t)*(1-t)*(1-t)); }; 7987 7988 /* p from 0 to 1 */ 7989 this.css = function(p) { 7990 var f1 = this.f1(p), f2 = this.f2(p), f3 = this.f3(p), f4=this.f4(p), css = {}; 7991 if (rotate) { 7992 css.prevX = this.x; 7993 css.prevY = this.y; 7994 } 7995 css.x = this.x = ( this.p1[0]*f1 + this.p2[0]*f2 +this.p3[0]*f3 + this.p4[0]*f4 +.5 )|0; 7996 css.y = this.y = ( this.p1[1]*f1 + this.p2[1]*f2 +this.p3[1]*f3 + this.p4[1]*f4 +.5 )|0; 7997 css.left = css.x + "px"; 7998 css.top = css.y + "px"; 7999 return css; 8000 }; 8001 }; 8002 8003 $.path.arc = function(params, rotate) { 8004 for ( var i in params ) { 8005 this[i] = params[i]; 8006 } 8007 8008 this.dir = this.dir || 1; 8009 8010 while ( this.start > this.end && this.dir > 0 ) { 8011 this.start -= 360; 8012 } 8013 8014 while ( this.start < this.end && this.dir < 0 ) { 8015 this.start += 360; 8016 } 8017 8018 this.css = function(p) { 8019 var a = ( this.start * (p ) + this.end * (1-(p )) ) * Math.PI / 180, 8020 css = {}; 8021 8022 if (rotate) { 8023 css.prevX = this.x; 8024 css.prevY = this.y; 8025 } 8026 css.x = this.x = ( Math.sin(a) * this.radius + this.center[0] +.5 )|0;
8027 css.y = this.y = ( Math.cos(a) * this.radius + this.center[1] +.5 )|0; 8028 css.left = css.x + "px"; 8029 css.top = css.y + "px"; 8030 return css; 8031 }; 8032 }; 8033 8034 $.fx.step.path = function(fx) { 8035 var css = fx.end.css( 1 - fx.pos ); 8036 if ( css.prevX != null ) { 8037 $.cssHooks.transform.set( fx.elem, "rotate(" + Math.atan2(css.prevY - css.y, css.prevX - css.x) + ")" ); 8038 } 8039 fx.elem.style.top = css.top; 8040 fx.elem.style.left = css.left; 8041 }; 8042 8043})(jQuery);; 8044/* AUTOGENERATED: jquery.fly.js */ 8045/* vim: set ts=2 sw=2 sts=2 et: */ 8046 8047/** 8048 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 8049 * See https://www.x-cart.com/license-agreement.html for license details. 8050 */ 8051 8052(function ($) { 8053 8054 var defaults = { 8055 duration: 500, 8056 startAngle: 0, 8057 endAngle: -20, 8058 width: 32, 8059 height: 32, 8060 opacity: 0.0, 8061 cloneCss: { 8062 'position': 'fixed', 8063 'z-index': 102000, 8064 'opacity': 0.99 8065 }, 8066 callback: null, 8067 removeOnEnd: true, 8068 space: $('body'), 8069 view: null, 8070 }; 8071 8072 var pluginOptions = {}; 8073 8074 // jQuery plugin definition 8075 $.fn.fly = function (target, options) { 8076 if ('undefined' === typeof(options)) { 8077 options = {}; 8078 } 8079 8080 pluginOptions = _.defaults(options, defaults); 8081 animateMotion(this, target); 8082 return this; 8083 }; 8084 8085 function animateMotion(element, target) { 8086 var clone = getFlyingElement(element); 8087 var path = new $.path.bezier({ 8088 start: getCoords(element, pluginOptions.startAngle), 8089 end: getCoords(target, pluginOptions.endAngle) 8090 }); 8091 8092 clone.animate( 8093 { 8094 path: path, 8095 width: pluginOptions.width, 8096 height: pluginOptions.height, 8097 }, 8098 pluginOptions.duration, 8099 _.partial(onAnimationEnd, clone) 8100 ); 8101 } 8102 8103 function getFlyingElement(element) { 8104 if (pluginOptions.view) { 8105 return getClone(pluginOptions.view) 8106 } else { 8107 return getClone(element); 8108 } 8109 } 8110 8111 function getCoords(element, angle) { 8112 return { 8113 x: element[0].getBoundingClientRect().left, 8114 y: element[0].getBoundingClientRect().top, 8115 angle: angle, 8116 }; 8117 } 8118 8119 function getClone(element) { 8120 var clone = element.clone(); 8121 clone.css(pluginOptions.cloneCss); 8122 pluginOptions.space.append(clone); 8123 8124 return clone; 8125 } 8126 8127 function onAnimationEnd(clone) { 8128 if (pluginOptions.callback) { 8129 pluginOptions.callback.apply(this, arguments); 8130 } 8131 if (pluginOptions.removeOnEnd) { 8132 clone.remove(); 8133 } 8134 } 8135 8136})(jQuery);; 8137/* AUTOGENERATED: utils.js */ 8138/* vim: set ts=2 sw=2 sts=2 et: */ 8139 8140/** 8141 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 8142 * See https://www.x-cart.com/license-agreement.html for license details. 8143 */ 8144 8145window.getProductRepresentationFor = function(element) { 8146 var product = null; 8147 8148 var itemView = null; 8149 var item = null; 8150 8151 // on product details page 8152 if ($(element).hasClass('product-details')) { 8153 var product = $(element); 8154 } else { 8155 var product = $(element).closest('[class*="product-info-"]'); 8156 } 8157 8158 if (!product || product.length == 0) { 8159 // on product list page 8160 var product = $(element).closest('.product[class*="productid-"]'); 8161 var products_list = product.closest('.items-list-products'); 8162 var list_params = products_list.data('widget-arguments'); 8163 8164 switch(list_params.displayMode) { 8165 case 'grid': 8166 case 'list': 8167 var item = product.find('.product-photo img'); 8168 break; 8169 8170 case 'table': 8171 // var item = $(element).closest('tr').find('.product-sku'); 8172 // var itemView = product.find('.product-table-representation'); 8173 break; 8174 } 8175 } else { 8176 var item = product.find('.product-photo img'); 8177 } 8178 8179 return { 8180 element: item, 8181 view: itemView 8182 }; 8183} 8184 8185$('[data-toggle="collapse"]').each(function(index, el) { 8186 var $el = jQuery(el); 8187 var target = jQuery($el.data('target')); 8188 8189 target.on('hide.bs.collapse', function () { 8190 $el.removeClass('shown'); 8191 }) 8192 target.on('hidden.bs.collapse', function () { 8193 $el.removeClass('shown'); 8194 }) 8195 target.on('show.bs.collapse', function () { 8196 $el.addClass('shown'); 8197 }) 8198 target.on('shown.bs.collapse', function () { 8199 $el.addClass('shown'); 8200 }) 8201});; 8202/* AUTOGENERATED: header.js */ 8203/* vim: set ts=2 sw=2 sts=2 et: */ 8204 8205/** 8206 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 8207 * See https://www.x-cart.com/license-agreement.html for license details. 8208 */ 8209 8210const desktopHeader = $('.desktop-header'); 8211const headerArea = $('#header-area'); 8212 8213desktopHeader.affix({ 8214 offset: { 8215 top: function () { 8216 return 140; 8217 }, 8218 } 8219}); 8220 8221$('.mobile_header .nav').affix({ 8222 offset: { 8223 top: function () { 8224 return 140; 8225 }, 8226 } 8227}); 8228 8229$(document).on('click', '#header-area .dropdown .dropdown-menu', function (e) { 8230 e.stopPropagation(); 8231}); 8232 8233var panel = $('.header_search-panel'); 8234panel.on('hidden.bs.collapse', function() { 8235 $(this).siblings('a').addClass('collapsed'); 8236}); 8237 8238panel.on('show.bs.collapse', function() { 8239 $(this).siblings('a').removeClass('collapsed'); 8240}); 8241 8242$(document).on('click', '.header_search a', function() { 8243 if ($(this).hasClass('shown')) { 8244 panel.find('input[name="substring"]').focus(); 8245 } 8246}); 8247 8248function searchPanelToggle(event) { 8249 if(!$(event.target).closest('.simple-search-box').length && 8250 !$(event.target).is('.simple-search-box')) { 8251 if (panel.hasClass('in')) { 8252 panel.collapse('hide'); 8253 panel.find('input[name="substring"]').blur(); 8254 } 8255 } 8256} 8257 8258if ('ontouchstart' in document.documentElement) { 8259 $(document).on('touchstart', function(event) { 8260 searchPanelToggle(event); 8261 }); 8262} else { 8263 $(document).click(function(event) { 8264 searchPanelToggle(event); 8265 }); 8266} 8267 8268$('.simple-search-box').focusin(function () { 8269 $(this).addClass('focus').removeClass('filled'); 8270}).focusout(function () { 8271 $(this).removeClass('focus'); 8272 if ($(this).find('input[name="substring"]').val()) { 8273 $(this).addClass('filled') 8274 } 8275}).click(function () { 8276 $(this).find('input[name="substring"]').focus(); 8277}); 8278 8279// minicart 8280function materializeMinicart() { 8281 var viewportWidth = Math.max(document.documentElement.clientWidth, window.innerWidth || 0); 8282 8283 // mobile view 8284 if (viewportWidth < 992) { 8285 switchMinicarts('.mobile_header .lc-minicart-placeholder'); 8286 } else if (desktopHeader.find('.lc-minicart').length < 1) { 8287 switchMinicarts('.desktop-header .lc-minicart-placeholder'); 8288 } 8289}; 8290 8291function switchMinicarts(target) { 8292 var placeholder = document.createElement('div'); 8293 $(placeholder).addClass('lc-minicart-placeholder'); 8294 $('.lc-minicart').after(placeholder); 8295 8296 var cartElement = $('.lc-minicart').detach(); 8297 8298 $(target).replaceWith(cartElement); 8299} 8300 8301materializeMinicart(); 8302 8303$(window).resize(function() { 8304 materializeMinicart(); 8305});; 8306/* AUTOGENERATED: footer.js */ 8307/* vim: set ts=2 sw=2 sts=2 et: */ 8308 8309/** 8310 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 8311 * See https://www.x-cart.com/license-agreement.html for license details. 8312 */ 8313 8314jQuery(function() { 8315 var heightFixer = function () { 8316 jQuery(this).addClass('notransition'); 8317 8318 if (this.scrollHeight > this.clientHeight) { 8319 this.style.height = (this.scrollHeight + 10) + 'px'; 8320 } 8321 8322 jQuery(this).removeClass('notransition'); 8323 }; 8324 8325 var mobileWidth = 768; 8326 var collapserAssigned = false;
8327 var assignCollapser = function () { 8328 var windowWidth = $(window).width(); 8329 8330 if (!collapserAssigned && windowWidth < mobileWidth) { 8331 jQuery('.footer-menu').collapser(); 8332 collapserAssigned = true; 8333 } 8334 } 8335 8336 assignCollapser(); 8337 8338 $(window).resize(_.debounce(function () { 8339 assignCollapser(); 8340 }, 200)); 8341 8342 jQuery('.form-control').floatingLabel(); 8343 jQuery('textarea.form-control').keyup(heightFixer).keyup(); 8344 8345 xcart.bind('checkout.main.ready', function() { 8346 jQuery('.checkout_fastlane_container .form-control').floatingLabel(); 8347 jQuery('.checkout_fastlane_container textarea.form-control').keyup(heightFixer).keyup(); 8348 }); 8349 8350 xcart.bind(['load', 'loader.loaded', 'popup.open'], function() { 8351 jQuery('.form-control').floatingLabel(); 8352 jQuery('textarea.form-control').keyup(heightFixer).keyup(); 8353 }); 8354 8355});; 8356/* AUTOGENERATED: vue.min.js */ 8357/*! 8358 * Vue.js v2.6.12 8359 * (c) 2014-2020
vendor: 37,807 bytes, lines 8359-8362
8359 Evan You 8360 * Released under the MIT License. 8361 */ 8362!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e=e||self).Vue=t()}(this,function(){"use strict";var e=Object.freeze({});function t(e){return null==e}function n(e){return null!=e}function r(e){return!0===e}function i(e){return"string"==typeof e||"number"==typeof e||"symbol"==typeof e||"boolean"==typeof e}function o(e){return null!==e&&"object"==typeof e}var a=Object.prototype.toString;function s(e){return"[object Object]"===a.call(e)}function c(e){var t=parseFloat(String(e));return t>=0&&Math.floor(t)===t&&isFinite(e)}function u(e){return n(e)&&"function"==typeof e.then&&"function"==typeof e.catch}function l(e){return null==e?"":Array.isArray(e)||s(e)&&e.toString===a?JSON.stringify(e,null,2):String(e)}function f(e){var t=parseFloat(e);return isNaN(t)?e:t}function p(e,t){for(var n=Object.create(null),r=e.split(","),i=0;i<r.length;i++)n[r[i]]=!0;return t?function(e){return n[e.toLowerCase()]}:function(e){return n[e]}}var d=p("slot,component",!0),v=p("key,ref,slot,slot-scope,is");function h(e,t){if(e.length){var n=e.indexOf(t);if(n>-1)return e.splice(n,1)}}var m=Object.prototype.hasOwnProperty;function y(e,t){return m.call(e,t)}function g(e){var t=Object.create(null);return function(n){return t[n]||(t[n]=e(n))}}var _=/-(\w)/g,b=g(function(e){return e.replace(_,function(e,t){return t?t.toUpperCase():""})}),$=g(function(e){return e.charAt(0).toUpperCase()+e.slice(1)}),w=/\B([A-Z])/g,C=g(function(e){return e.replace(w,"-$1").toLowerCase()});var x=Function.prototype.bind?function(e,t){return e.bind(t)}:function(e,t){function n(n){var r=arguments.length;return r?r>1?e.apply(t,arguments):e.call(t,n):e.call(t)}return n._length=e.length,n};function k(e,t){t=t||0;for(var n=e.length-t,r=new Array(n);n--;)r[n]=e[n+t];return r}function A(e,t){for(var n in t)e[n]=t[n];return e}function O(e){for(var t={},n=0;n<e.length;n++)e[n]&&A(t,e[n]);return t}function S(e,t,n){}var T=function(e,t,n){return!1},E=function(e){return e};function N(e,t){if(e===t)return!0;var n=o(e),r=o(t);if(!n||!r)return!n&&!r&&String(e)===String(t);try{var i=Array.isArray(e),a=Array.isArray(t);if(i&&a)return e.length===t.length&&e.every(function(e,n){return N(e,t[n])});if(e instanceof Date&&t instanceof Date)return e.getTime()===t.getTime();if(i||a)return!1;var s=Object.keys(e),c=Object.keys(t);return s.length===c.length&&s.every(function(n){return N(e[n],t[n])})}catch(e){return!1}}function j(e,t){for(var n=0;n<e.length;n++)if(N(e[n],t))return n;return-1}function D(e){var t=!1;return function(){t||(t=!0,e.apply(this,arguments))}}var L="data-server-rendered",M=["component","directive","filter"],I=["beforeCreate","created","beforeMount","mounted","beforeUpdate","updated","beforeDestroy","destroyed","activated","deactivated","errorCaptured","serverPrefetch"],F={optionMergeStrategies:Object.create(null),silent:!1,productionTip:!1,devtools:!1,performance:!1,errorHandler:null,warnHandler:null,ignoredElements:[],keyCodes:Object.create(null),isReservedTag:T,isReservedAttr:T,isUnknownElement:T,getTagNamespace:S,parsePlatformTagName:E,mustUseProp:T,async:!0,_lifecycleHooks:I},P=/a-zA-Z\u00B7\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u037D\u037F-\u1FFF\u200C-\u200D\u203F-\u2040\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD/;function R(e,t,n,r){Object.defineProperty(e,t,{value:n,enumerable:!!r,writable:!0,configurable:!0})}var H=new RegExp("[^"+P.source+".$_\\d]");var B,U="__proto__"in{},z="undefined"!=typeof window,V="undefined"!=typeof WXEnvironment&&!!WXEnvironment.platform,K=V&&WXEnvironment.platform.toLowerCase(),J=z&&window.navigator.userAgent.toLowerCase(),q=J&&/msie|trident/.test(J),W=J&&J.indexOf("msie 9.0")>0,Z=J&&J.indexOf("edge/")>0,G=(J&&J.indexOf("android"),J&&/iphone|ipad|ipod|ios/.test(J)||"ios"===K),X=(J&&/chrome\/\d+/.test(J),J&&/phantomjs/.test(J),J&&J.match(/firefox\/(\d+)/)),Y={}.watch,Q=!1;if(z)try{var ee={};Object.defineProperty(ee,"passive",{get:function(){Q=!0}}),window.addEventListener("test-passive",null,ee)}catch(e){}var te=function(){return void 0===B&&(B=!z&&!V&&"undefined"!=typeof global&&(global.process&&"server"===global.process.env.VUE_ENV)),B},ne=z&&window.__VUE_DEVTOOLS_GLOBAL_HOOK__;function re(e){return"function"==typeof e&&/native code/.test(e.toString())}var ie,oe="undefined"!=typeof Symbol&&re(Symbol)&&"undefined"!=typeof Reflect&&re(Reflect.ownKeys);ie="undefined"!=typeof Set&&re(Set)?Set:function(){function e(){this.set=Object.create(null)}return e.prototype.has=function(e){return!0===this.set[e]},e.prototype.add=function(e){this.set[e]=!0},e.prototype.clear=function(){this.set=Object.create(null)},e}();var ae=S,se=0,ce=function(){this.id=se++,this.subs=[]};ce.prototype.addSub=function(e){this.subs.push(e)},ce.prototype.removeSub=function(e){h(this.subs,e)},ce.prototype.depend=function(){ce.target&&ce.target.addDep(this)},ce.prototype.notify=function(){for(var e=this.subs.slice(),t=0,n=e.length;t<n;t++)e[t].update()},ce.target=null;var ue=[];function le(e){ue.push(e),ce.target=e}function fe(){ue.pop(),ce.target=ue[ue.length-1]}var pe=function(e,t,n,r,i,o,a,s){this.tag=e,this.data=t,this.children=n,this.text=r,this.elm=i,this.ns=void 0,this.context=o,this.fnContext=void 0,this.fnOptions=void 0,this.fnScopeId=void 0,this.key=t&&t.key,this.componentOptions=a,this.componentInstance=void 0,this.parent=void 0,this.raw=!1,this.isStatic=!1,this.isRootInsert=!0,this.isComment=!1,this.isCloned=!1,this.isOnce=!1,this.asyncFactory=s,this.asyncMeta=void 0,this.isAsyncPlaceholder=!1},de={child:{configurable:!0}};de.child.get=function(){return this.componentInstance},Object.defineProperties(pe.prototype,de);var ve=function(e){void 0===e&&(e="");var t=new pe;return t.text=e,t.isComment=!0,t};function he(e){return new pe(void 0,void 0,void 0,String(e))}function me(e){var t=new pe(e.tag,e.data,e.children&&e.children.slice(),e.text,e.elm,e.context,e.componentOptions,e.asyncFactory);return t.ns=e.ns,t.isStatic=e.isStatic,t.key=e.key,t.isComment=e.isComment,t.fnContext=e.fnContext,t.fnOptions=e.fnOptions,t.fnScopeId=e.fnScopeId,t.asyncMeta=e.asyncMeta,t.isCloned=!0,t}var ye=Array.prototype,ge=Object.create(ye);["push","pop","shift","unshift","splice","sort","reverse"].forEach(function(e){var t=ye[e];R(ge,e,function(){for(var n=[],r=arguments.length;r--;)n[r]=arguments[r];var i,o=t.apply(this,n),a=this.__ob__;switch(e){case"push":case"unshift":i=n;break;case"splice":i=n.slice(2)}return i&&a.observeArray(i),a.dep.notify(),o})});var _e=Object.getOwnPropertyNames(ge),be=!0;function $e(e){be=e}var we=function(e){var t;this.value=e,this.dep=new ce,this.vmCount=0,R(e,"__ob__",this),Array.isArray(e)?(U?(t=ge,e.__proto__=t):function(e,t,n){for(var r=0,i=n.length;r<i;r++){var o=n[r];R(e,o,t[o])}}(e,ge,_e),this.observeArray(e)):this.walk(e)};function Ce(e,t){var n;if(o(e)&&!(e instanceof pe))return y(e,"__ob__")&&e.__ob__ instanceof we?n=e.__ob__:be&&!te()&&(Array.isArray(e)||s(e))&&Object.isExtensible(e)&&!e._isVue&&(n=new we(e)),t&&n&&n.vmCount++,n}function xe(e,t,n,r,i){var o=new ce,a=Object.getOwnPropertyDescriptor(e,t);if(!a||!1!==a.configurable){var s=a&&a.get,c=a&&a.set;s&&!c||2!==arguments.length||(n=e[t]);var u=!i&&Ce(n);Object.defineProperty(e,t,{enumerable:!0,configurable:!0,get:function(){var t=s?s.call(e):n;return ce.target&&(o.depend(),u&&(u.dep.depend(),Array.isArray(t)&&function e(t){for(var n=void 0,r=0,i=t.length;r<i;r++)(n=t[r])&&n.__ob__&&n.__ob__.dep.depend(),Array.isArray(n)&&e(n)}(t))),t},set:function(t){var r=s?s.call(e):n;t===r||t!=t&&r!=r||s&&!c||(c?c.call(e,t):n=t,u=!i&&Ce(t),o.notify())}})}}function ke(e,t,n){if(Array.isArray(e)&&c(t))return e.length=Math.max(e.length,t),e.splice(t,1,n),n;if(t in e&&!(t in Object.prototype))return e[t]=n,n;var r=e.__ob__;return e._isVue||r&&r.vmCount?n:r?(xe(r.value,t,n),r.dep.notify(),n):(e[t]=n,n)}function Ae(e,t){if(Array.isArray(e)&&c(t))e.splice(t,1);else{var n=e.__ob__;e._isVue||n&&n.vmCount||y(e,t)&&(delete e[t],n&&n.dep.notify())}}we.prototype.walk=function(e){for(var t=Object.keys(e),n=0;n<t.length;n++)xe(e,t[n])},we.prototype.observeArray=function(e){for(var t=0,n=e.length;t<n;t++)Ce(e[t])};var Oe=F.optionMergeStrategies;function Se(e,t){if(!t)return e;for(var n,r,i,o=oe?Reflect.ownKeys(t):Object.keys(t),a=0;a<o.length;a++)"__ob__"!==(n=o[a])&&(r=e[n],i=t[n],y(e,n)?r!==i&&s(r)&&s(i)&&Se(r,i):ke(e,n,i));return e}function Te(e,t,n){return n?function(){var r="function"==typeof t?t.call(n,n):t,i="function"==typeof e?e.call(n,n):e;return r?Se(r,i):i}:t?e?function(){return Se("function"==typeof t?t.call(this,this):t,"function"==typeof e?e.call(this,this):e)}:t:e}function Ee(e,t){var n=t?e?e.concat(t):Array.isArray(t)?t:[t]:e;return n?function(e){for(var t=[],n=0;n<e.length;n++)-1===t.indexOf(e[n])&&t.push(e[n]);return t}(n):n}function Ne(e,t,n,r){var i=Object.create(e||null);return t?A(i,t):i}Oe.data=function(e,t,n){return n?Te(e,t,n):t&&"function"!=typeof t?e:Te(e,t)},I.forEach(function(e){Oe[e]=Ee}),M.forEach(function(e){Oe[e+"s"]=Ne}),Oe.watch=function(e,t,n,r){if(e===Y&&(e=void 0),t===Y&&(t=void 0),!t)return Object.create(e||null);if(!e)return t;var i={};for(var o in A(i,e),t){var a=i[o],s=t[o];a&&!Array.isArray(a)&&(a=[a]),i[o]=a?a.concat(s):Array.isArray(s)?s:[s]}return i},Oe.props=Oe.methods=Oe.inject=Oe.computed=function(e,t,n,r){if(!e)return t;var i=Object.create(null);return A(i,e),t&&A(i,t),i},Oe.provide=Te;var je=function(e,t){return void 0===t?e:t};function De(e,t,n){if("function"==typeof t&&(t=t.options),function(e,t){var n=e.props;if(n){var r,i,o={};if(Array.isArray(n))for(r=n.length;r--;)"string"==typeof(i=n[r])&&(o[b(i)]={type:null});else if(s(n))for(var a in n)i=n[a],o[b(a)]=s(i)?i:{type:i};e.props=o}}(t),function(e,t){var n=e.inject;if(n){var r=e.inject={};if(Array.isArray(n))for(var i=0;i<n.length;i++)r[n[i]]={from:n[i]};else if(s(n))for(var o in n){var a=n[o];r[o]=s(a)?A({from:o},a):{from:a}}}}(t),function(e){var t=e.directives;if(t)for(var n in t){var r=t[n];"function"==typeof r&&(t[n]={bind:r,update:r})}}(t),!t._base&&(t.extends&&(e=De(e,t.extends,n)),t.mixins))for(var r=0,i=t.mixins.length;r<i;r++)e=De(e,t.mixins[r],n);var o,a={};for(o in e)c(o);for(o in t)y(e,o)||c(o);function c(r){var i=Oe[r]||je;a[r]=i(e[r],t[r],n,r)}return a}function Le(e,t,n,r){if("string"==typeof n){var i=e[t];if(y(i,n))return i[n];var o=b(n);if(y(i,o))return i[o];var a=$(o);return y(i,a)?i[a]:i[n]||i[o]||i[a]}}function Me(e,t,n,r){var i=t[e],o=!y(n,e),a=n[e],s=Pe(Boolean,i.type);if(s>-1)if(o&&!y(i,"default"))a=!1;else if(""===a||a===C(e)){var c=Pe(String,i.type);(c<0||s<c)&&(a=!0)}if(void 0===a){a=function(e,t,n){if(!y(t,"default"))return;var r=t.default;if(e&&e.$options.propsData&&void 0===e.$options.propsData[n]&&void 0!==e._props[n])return e._props[n];return"function"==typeof r&&"Function"!==Ie(t.type)?r.call(e):r}(r,i,e);var u=be;$e(!0),Ce(a),$e(u)}return a}function Ie(e){var t=e&&e.toString().match(/^\s*function (\w+)/);return t?t[1]:""}function Fe(e,t){return Ie(e)===Ie(t)}function Pe(e,t){if(!Array.isArray(t))return Fe(t,e)?0:-1;for(var n=0,r=t.length;n<r;n++)if(Fe(t[n],e))return n;return-1}function Re(e,t,n){le();try{if(t)for(var r=t;r=r.$parent;){var i=r.$options.errorCaptured;if(i)for(var o=0;o<i.length;o++)try{if(!1===i[o].call(r,e,t,n))return}catch(e){Be(e,r,"errorCaptured hook")}}Be(e,t,n)}finally{fe()}}function He(e,t,n,r,i){var o;try{(o=n?e.apply(t,n):e.call(t))&&!o._isVue&&u(o)&&!o._handled&&(o.catch(function(e){return Re(e,r,i+" (Promise/async)")}),o._handled=!0)}catch(e){Re(e,r,i)}return o}function Be(e,t,n){if(F.errorHandler)try{return F.errorHandler.call(null,e,t,n)}catch(t){t!==e&&Ue(t,null,"config.errorHandler")}Ue(e,t,n)}function Ue(e,t,n){if(!z&&!V||"undefined"==typeof console)throw e;console.error(e)}var ze,Ve=!1,Ke=[],Je=!1;function qe(){Je=!1;var e=Ke.slice(0);Ke.length=0;for(var t=0;t<e.length;t++)e[t]()}if("undefined"!=typeof Promise&&re(Promise)){var We=Promise.resolve();ze=function(){We.then(qe),G&&setTimeout(S)},Ve=!0}else if(q||"undefined"==typeof MutationObserver||!re(MutationObserver)&&"[object MutationObserverConstructor]"!==MutationObserver.toString())ze="undefined"!=typeof setImmediate&&re(setImmediate)?function(){setImmediate(qe)}:function(){setTimeout(qe,0)};else{var Ze=1,Ge=new MutationObserver(qe),Xe=document.createTextNode(String(Ze));Ge.observe(Xe,{characterData:!0}),ze=function(){Ze=(Ze+1)%2,Xe.data=String(Ze)},Ve=!0}function Ye(e,t){var n;if(Ke.push(function(){if(e)try{e.call(t)}catch(e){Re(e,t,"nextTick")}else n&&n(t)}),Je||(Je=!0,ze()),!e&&"undefined"!=typeof Promise)return new Promise(function(e){n=e})}var Qe=new ie;function et(e){!function e(t,n){var r,i;var a=Array.isArray(t);if(!a&&!o(t)||Object.isFrozen(t)||t instanceof pe)return;if(t.__ob__){var s=t.__ob__.dep.id;if(n.has(s))return;n.add(s)}if(a)for(r=t.length;r--;)e(t[r],n);else for(i=Object.keys(t),r=i.length;r--;)e(t[i[r]],n)}(e,Qe),Qe.clear()}var tt=g(function(e){var t="&"===e.charAt(0),n="~"===(e=t?e.slice(1):e).charAt(0),r="!"===(e=n?e.slice(1):e).charAt(0);return{name:e=r?e.slice(1):e,once:n,capture:r,passive:t}});function nt(e,t){function n(){var e=arguments,r=n.fns;if(!Array.isArray(r))return He(r,null,arguments,t,"v-on handler");for(var i=r.slice(),o=0;o<i.length;o++)He(i[o],null,e,t,"v-on handler")}return n.fns=e,n}function rt(e,n,i,o,a,s){var c,u,l,f;for(c in e)u=e[c],l=n[c],f=tt(c),t(u)||(t(l)?(t(u.fns)&&(u=e[c]=nt(u,s)),r(f.once)&&(u=e[c]=a(f.name,u,f.capture)),i(f.name,u,f.capture,f.passive,f.params)):u!==l&&(l.fns=u,e[c]=l));for(c in n)t(e[c])&&o((f=tt(c)).name,n[c],f.capture)}function it(e,i,o){var a;e instanceof pe&&(e=e.data.hook||(e.data.hook={}));var s=e[i];function c(){o.apply(this,arguments),h(a.fns,c)}t(s)?a=nt([c]):n(s.fns)&&r(s.merged)?(a=s).fns.push(c):a=nt([s,c]),a.merged=!0,e[i]=a}function ot(e,t,r,i,o){if(n(t)){if(y(t,r))return e[r]=t[r],o||delete t[r],!0;if(y(t,i))return e[r]=t[i],o||delete t[i],!0}return!1}function at(e){return i(e)?[he(e)]:Array.isArray(e)?function e(o,a){var s=[];var c,u,l,f;for(c=0;c<o.length;c++)t(u=o[c])||"boolean"==typeof u||(l=s.length-1,f=s[l],Array.isArray(u)?u.length>0&&(st((u=e(u,(a||"")+"_"+c))[0])&&st(f)&&(s[l]=he(f.text+u[0].text),u.shift()),s.push.apply(s,u)):i(u)?st(f)?s[l]=he(f.text+u):""!==u&&s.push(he(u)):st(u)&&st(f)?s[l]=he(f.text+u.text):(r(o._isVList)&&n(u.tag)&&t(u.key)&&n(a)&&(u.key="__vlist"+a+"_"+c+"__"),s.push(u)));return s}(e):void 0}function st(e){return n(e)&&n(e.text)&&!1===e.isComment}function ct(e,t){if(e){for(var n=Object.create(null),r=oe?Reflect.ownKeys(e):Object.keys(e),i=0;i<r.length;i++){var o=r[i];if("__ob__"!==o){for(var a=e[o].from,s=t;s;){if(s._provided&&y(s._provided,a)){n[o]=s._provided[a];break}s=s.$parent}if(!s&&"default"in e[o]){var c=e[o].default;n[o]="function"==typeof c?c.call(t):c}}}return n}}function ut(e,t){if(!e||!e.length)return{};for(var n={},r=0,i=e.length;r<i;r++){var o=e[r],a=o.data;if(a&&a.attrs&&a.attrs.slot&&delete a.attrs.slot,o.context!==t&&o.fnContext!==t||!a||null==a.slot)(n.default||(n.default=[])).push(o);else{var s=a.slot,c=n[s]||(n[s]=[]);"template"===o.tag?c.push.apply(c,o.children||[]):c.push(o)}}for(var u in n)n[u].every(lt)&&delete n[u];return n}function lt(e){return e.isComment&&!e.asyncFactory||" "===e.text}function ft(t,n,r){var i,o=Object.keys(n).length>0,a=t?!!t.$stable:!o,s=t&&t.$key;if(t){if(t._normalized)return t._normalized;if(a&&r&&r!==e&&s===r.$key&&!o&&!r.$hasNormal)return r;for(var c in i={},t)t[c]&&"$"!==c[0]&&(i[c]=pt(n,c,t[c]))}else i={};for(var u in n)u in i||(i[u]=dt(n,u));return t&&Object.isExtensible(t)&&(t._normalized=i),R(i,"$stable",a),R(i,"$key",s),R(i,"$hasNormal",o),i}function pt(e,t,n){var r=function(){var e=arguments.length?n.apply(null,arguments):n({});return(e=e&&"object"==typeof e&&!Array.isArray(e)?[e]:at(e))&&(0===e.length||1===e.length&&e[0].isComment)?void 0:e};return n.proxy&&Object.defineProperty(e,t,{get:r,enumerable:!0,configurable:!0}),r}function dt(e,t){return function(){return e[t]}}function vt(e,t){var r,i,a,s,c;if(Array.isArray(e)||"string"==typeof e)for(r=new Array(e.length),i=0,a=e.length;i<a;i++)r[i]=t(e[i],i);else if("number"==typeof e)for(r=new Array(e),i=0;i<e;i++)r[i]=t(i+1,i);else if(o(e))if(oe&&e[Symbol.iterator]){r=[];for(var u=e[Symbol.iterator](),l=u.next();!l.done;)r.push(t(l.value,r.length)),l=u.next()}else for(s=Object.keys(e),r=new Array(s.length),i=0,a=s.length;i<a;i++)c=s[i],r[i]=t(e[c],c,i);return n(r)||(r=[]),r._isVList=!0,r}function ht(e,t,n,r){var i,o=this.$scopedSlots[e];o?(n=n||{},r&&(n=A(A({},r),n)),i=o(n)||t):i=this.$slots[e]||t;var a=n&&n.slot;return a?this.$createElement("template",{slot:a},i):i}function mt(e){return Le(this.$options,"filters",e)||E}function yt(e,t){return Array.isArray(e)?-1===e.indexOf(t):e!==t}function gt(e,t,n,r,i){var o=F.keyCodes[t]||n;return i&&r&&!F.keyCodes[t]?yt(i,r):o?yt(o,e):r?C(r)!==t:void 0}function _t(e,t,n,r,i){if(n)if(o(n)){var a;Array.isArray(n)&&(n=O(n));var s=function(o){if("class"===o||"style"===o||v(o))a=e;else{var s=e.attrs&&e.attrs.type;a=r||F.mustUseProp(t,s,o)?e.domProps||(e.domProps={}):e.attrs||(e.attrs={})}var c=b(o),u=C(o);c in a||u in a||(a[o]=n[o],i&&((e.on||(e.on={}))["update:"+o]=function(e){n[o]=e}))};for(var c in n)s(c)}else;return e}function bt(e,t){var n=this._staticTrees||(this._staticTrees=[]),r=n[e];return r&&!t?r:(wt(r=n[e]=this.$options.staticRenderFns[e].call(this._renderProxy,null,this),"__static__"+e,!1),r)}function $t(e,t,n){return wt(e,"__once__"+t+(n?"_"+n:""),!0),e}function wt(e,t,n){if(Array.isArray(e))for(var r=0;r<e.length;r++)e[r]&&"string"!=typeof e[r]&&Ct(e[r],t+"_"+r,n);else Ct(e,t,n)}function Ct(e,t,n){e.isStatic=!0,e.key=t,e.isOnce=n}function xt(e,t){if(t)if(s(t)){var n=e.on=e.on?A({},e.on):{};for(var r in t){var i=n[r],o=t[r];n[r]=i?[].concat(i,o):o}}else;return e}function kt(e,t,n,r){t=t||{$stable:!n};for(var i=0;i<e.length;i++){var o=e[i];Array.isArray(o)?kt(o,t,n):o&&(o.proxy&&(o.fn.proxy=!0),t[o.key]=o.fn)}return r&&(t.$key=r),t}function At(e,t){for(var n=0;n<t.length;n+=2){var r=t[n];"string"==typeof r&&r&&(e[t[n]]=t[n+1])}return e}function Ot(e,t){return"string"==typeof e?t+e:e}function St(e){e._o=$t,e._n=f,e._s=l,e._l=vt,e._t=ht,e._q=N,e._i=j,e._m=bt,e._f=mt,e._k=gt,e._b=_t,e._v=he,e._e=ve,e._u=kt,e._g=xt,e._d=At,e._p=Ot}function Tt(t,n,i,o,a){var s,c=this,u=a.options;y(o,"_uid")?(s=Object.create(o))._original=o:(s=o,o=o._original);var l=r(u._compiled),f=!l;this.data=t,this.props=n,this.children=i,this.parent=o,this.listeners=t.on||e,this.injections=ct(u.inject,o),this.slots=function(){return c.$slots||ft(t.scopedSlots,c.$slots=ut(i,o)),c.$slots},Object.defineProperty(this,"scopedSlots",{enumerable:!0,get:function(){return ft(t.scopedSlots,this.slots())}}),l&&(this.$options=u,this.$slots=this.slots(),this.$scopedSlots=ft(t.scopedSlots,this.$slots)),u._scopeId?this._c=function(e,t,n,r){var i=Pt(s,e,t,n,r,f);return i&&!Array.isArray(i)&&(i.fnScopeId=u._scopeId,i.fnContext=o),i}:this._c=function(e,t,n,r){return Pt(s,e,t,n,r,f)}}function Et(e,t,n,r,i){var o=me(e);return o.fnContext=n,o.fnOptions=r,t.slot&&((o.data||(o.data={})).slot=t.slot),o}function Nt(e,t){for(var n in t)e[b(n)]=t[n]}St(Tt.prototype);var jt={init:function(e,t){if(e.componentInstance&&!e.componentInstance._isDestroyed&&e.data.keepAlive){var r=e;jt.prepatch(r,r)}else{(e.componentInstance=function(e,t){var r={_isComponent:!0,_parentVnode:e,parent:t},i=e.data.inlineTemplate;n(i)&&(r.render=i.render,r.staticRenderFns=i.staticRenderFns);return new e.componentOptions.Ctor(r)}(e,Wt)).$mount(t?e.elm:void 0,t)}},prepatch:function(t,n){var r=n.componentOptions;!function(t,n,r,i,o){var a=i.data.scopedSlots,s=t.$scopedSlots,c=!!(a&&!a.$stable||s!==e&&!s.$stable||a&&t.$scopedSlots.$key!==a.$key),u=!!(o||t.$options._renderChildren||c);t.$options._parentVnode=i,t.$vnode=i,t._vnode&&(t._vnode.parent=i);if(t.$options._renderChildren=o,t.$attrs=i.data.attrs||e,t.$listeners=r||e,n&&t.$options.props){$e(!1);for(var l=t._props,f=t.$options._propKeys||[],p=0;p<f.length;p++){var d=f[p],v=t.$options.props;l[d]=Me(d,v,n,t)}$e(!0),t.$options.propsData=n}r=r||e;var h=t.$options._parentListeners;t.$options._parentListeners=r,qt(t,r,h),u&&(t.$slots=ut(o,i.context),t.$forceUpdate())}(n.componentInstance=t.componentInstance,r.propsData,r.listeners,n,r.children)},insert:function(e){var t,n=e.context,r=e.componentInstance;r._isMounted||(r._isMounted=!0,Yt(r,"mounted")),e.data.keepAlive&&(n._isMounted?((t=r)._inactive=!1,en.push(t)):Xt(r,!0))},destroy:function(e){var t=e.componentInstance;t._isDestroyed||(e.data.keepAlive?function e(t,n){if(n&&(t._directInactive=!0,Gt(t)))return;if(!t._inactive){t._inactive=!0;for(var r=0;r<t.$children.length;r++)e(t.$children[r]);Yt(t,"deactivated")}}(t,!0):t.$destroy())}},Dt=Object.keys(jt);function Lt(i,a,s,c,l){if(!t(i)){var f=s.$options._base;if(o(i)&&(i=f.extend(i)),"function"==typeof i){var p;if(t(i.cid)&&void 0===(i=function(e,i){if(r(e.error)&&n(e.errorComp))return e.errorComp;if(n(e.resolved))return e.resolved;var a=Ht;a&&n(e.owners)&&-1===e.owners.indexOf(a)&&e.owners.push(a);if(r(e.loading)&&n(e.loadingComp))return e.loadingComp;if(a&&!n(e.owners)){var s=e.owners=[a],c=!0,l=null,f=null;a.$on("hook:destroyed",function(){return h(s,a)});var p=function(e){for(var t=0,n=s.length;t<n;t++)s[t].$forceUpdate();e&&(s.length=0,null!==l&&(clearTimeout(l),l=null),null!==f&&(clearTimeout(f),f=null))},d=D(function(t){e.resolved=Bt(t,i),c?s.length=0:p(!0)}),v=D(function(t){n(e.errorComp)&&(e.error=!0,p(!0))}),m=e(d,v);return o(m)&&(u(m)?t(e.resolved)&&m.then(d,v):u(m.component)&&(m.component.then(d,v),n(m.error)&&(e.errorComp=Bt(m.error,i)),n(m.loading)&&(e.loadingComp=Bt(m.loading,i),0===m.delay?e.loading=!0:l=setTimeout(function(){l=null,t(e.resolved)&&t(e.error)&&(e.loading=!0,p(!1))},m.delay||200)),n(m.timeout)&&(f=setTimeout(function(){f=null,t(e.resolved)&&v(null)},m.timeout)))),c=!1,e.loading?e.loadingComp:e.resolved}}(p=i,f)))return function(e,t,n,r,i){var o=ve();return o.asyncFactory=e,o.asyncMeta={data:t,context:n,children:r,tag:i},o}(p,a,s,c,l);a=a||{},$n(i),n(a.model)&&function(e,t){var r=e.model&&e.model.prop||"value",i=e.model&&e.model.event||"input";(t.attrs||(t.attrs={}))[r]=t.model.value;var o=t.on||(t.on={}),a=o[i],s=t.model.callback;n(a)?(Array.isArray(a)?-1===a.indexOf(s):a!==s)&&(o[i]=[s].concat(a)):o[i]=s}(i.options,a);var d=function(e,r,i){var o=r.options.props;if(!t(o)){var a={},s=e.attrs,c=e.props;if(n(s)||n(c))for(var u in o){var l=C(u);ot(a,c,u,l,!0)||ot(a,s,u,l,!1)}return a}}(a,i);if(r(i.options.functional))return function(t,r,i,o,a){var s=t.options,c={},u=s.props;if(n(u))for(var l in u)c[l]=Me(l,u,r||e);else n(i.attrs)&&Nt(c,i.attrs),n(i.props)&&Nt(c,i.props);var f=new Tt(i,c,a,o,t),p=s.render.call(null,f._c,f);if(p instanceof pe)return Et(p,i,f.parent,s);if(Array.isArray(p)){for(var d=at(p)||[],v=new Array(d.length),h=0;h<d.length;h++)v[h]=Et(d[h],i,f.parent,s);return v}}(i,d,a,s,c);var v=a.on;if(a.on=a.nativeOn,r(i.options.abstract)){var m=a.slot;a={},m&&(a.slot=m)}!function(e){for(var t=e.hook||(e.hook={}),n=0;n<Dt.length;n++){var r=Dt[n],i=t[r],o=jt[r];i===o||i&&i._merged||(t[r]=i?Mt(o,i):o)}}(a);var y=i.options.name||l;return new pe("vue-component-"+i.cid+(y?"-"+y:""),a,void 0,void 0,void 0,s,{Ctor:i,propsData:d,listeners:v,tag:l,children:c},p)}}}function Mt(e,t){var n=function(n,r){e(n,r),t(n,r)};return n._merged=!0,n}var It=1,Ft=2;function Pt(e,a,s,c,u,l){return(Array.isArray(s)||i(s))&&(u=c,c=s,s=void 0),r(l)&&(u=Ft),function(e,i,a,s,c){if(n(a)&&n(a.__ob__))return ve();n(a)&&n(a.is)&&(i=a.is);if(!i)return ve();Array.isArray(s)&&"function"==typeof s[0]&&((a=a||{}).scopedSlots={default:s[0]},s.length=0);c===Ft?s=at(s):c===It&&(s=function(e){for(var t=0;t<e.length;t++)if(Array.isArray(e[t]))return Array.prototype.concat.apply([],e);return e}(s));var u,l;if("string"==typeof i){var f;l=e.$vnode&&e.$vnode.ns||F.getTagNamespace(i),u=F.isReservedTag(i)?new pe(F.parsePlatformTagName(i),a,s,void 0,void 0,e):a&&a.pre||!n(f=Le(e.$options,"components",i))?new pe(i,a,s,void 0,void 0,e):Lt(f,a,e,s,i)}else u=Lt(i,a,e,s);return Array.isArray(u)?u:n(u)?(n(l)&&function e(i,o,a){i.ns=o;"foreignObject"===i.tag&&(o=void 0,a=!0);if(n(i.children))for(var s=0,c=i.children.length;s<c;s++){var u=i.children[s];n(u.tag)&&(t(u.ns)||r(a)&&"svg"!==u.tag)&&e(u,o,a)}}(u,l),n(a)&&function(e){o(e.style)&&et(e.style);o(e.class)&&et(e.class)}(a),u):ve()}(e,a,s,c,u)}var Rt,Ht=null;function Bt(e,t){return(e.__esModule||oe&&"Module"===e[Symbol.toStringTag])&&(e=e.default),o(e)?t.extend(e):e}function Ut(e){return e.isComment&&e.asyncFactory}function zt(e){if(Array.isArray(e))for(var t=0;t<e.length;t++){var r=e[t];if(n(r)&&(n(r.componentOptions)||Ut(r)))return r}}function Vt(e,t){Rt.$on(e,t)}function Kt(e,t){Rt.$off(e,t)}function Jt(e,t){var n=Rt;return function r(){null!==t.apply(null,arguments)&&n.$off(e,r)}}function qt(e,t,n){Rt=e,rt(t,n||{},Vt,Kt,Jt,e),Rt=void 0}var Wt=null;function Zt(e){var t=Wt;return Wt=e,function(){Wt=t}}function Gt(e){for(;e&&(e=e.$parent);)if(e._inactive)return!0;return!1}function Xt(e,t){if(t){if(e._directInactive=!1,Gt(e))return}else if(e._directInactive)return;if(e._inactive||null===e._inactive){e._inactive=!1;for(var n=0;n<e.$children.length;n++)Xt(e.$children[n]);Yt(e,"activated")}}function Yt(e,t){le();var n=e.$options[t],r=t+" hook";if(n)for(var i=0,o=n.length;i<o;i++)He(n[i],e,null,e,r);e._hasHookEvent&&e.$emit("hook:"+t),fe()}var Qt=[],en=[],tn={},nn=!1,rn=!1,on=0;var an=0,sn=Date.now;if(z&&!q){var cn=window.performance;cn&&"function"==typeof cn.now&&sn()>document.createEvent("Event").timeStamp&&(sn=function(){return cn.now()})}function un(){var e,t;for(an=sn(),rn=!0,Qt.sort(function(e,t){return e.id-t.id}),on=0;on<Qt.length;on++)(e=Qt[on]).before&&e.before(),t=e.id,tn[t]=null,e.run();var n=en.slice(),r=Qt.slice();on=Qt.length=en.length=0,tn={},nn=rn=!1,function(e){for(var t=0;t<e.length;t++)e[t]._inactive=!0,Xt(e[t],!0)}(n),function(e){var t=e.length;for(;t--;){var n=e[t],r=n.vm;r._watcher===n&&r._isMounted&&!r._isDestroyed&&Yt(r,"updated")}}(r),ne&&F.devtools&&ne.emit("flush")}var ln=0,fn=function(e,t,n,r,i){this.vm=e,i&&(e._watcher=this),e._watchers.push(this),r?(this.deep=!!r.deep,this.user=!!r.user,this.lazy=!!r.lazy,this.sync=!!r.sync,this.before=r.before):this.deep=this.user=this.lazy=this.sync=!1,this.cb=n,this.id=++ln,this.active=!0,this.dirty=this.lazy,this.deps=[],this.newDeps=[],this.depIds=new ie,this.newDepIds=new ie,this.expression="","function"==typeof t?this.getter=t:(this.getter=function(e){if(!H.test(e)){var t=e.split(".");return function(e){for(var n=0;n<t.length;n++){if(!e)return;e=e[t[n]]}return e}}}(t),this.getter||(this.getter=S)),this.value=this.lazy?void 0:this.get()};fn.prototype.get=function(){var e;le(this);var t=this.vm;try{e=this.getter.call(t,t)}catch(e){if(!this.user)throw e;Re(e,t,'getter for watcher "'+this.expression+'"')}finally{this.deep&&et(e),fe(),this.cleanupDeps()}return e},fn.prototype.addDep=function(e){var t=e.id;this.newDepIds.has(t)||(this.newDepIds.add(t),this.newDeps.push(e),this.depIds.has(t)||e.addSub(this))},fn.prototype.cleanupDeps=function(){for(var e=this.deps.length;e--;){var t=this.deps[e];this.newDepIds.has(t.id)||t.removeSub(this)}var n=this.depIds;this.depIds=this.newDepIds,this.newDepIds=n,this.newDepIds.clear(),n=this.deps,this.deps=this.newDeps,this.newDeps=n,this.newDeps.length=0},fn.prototype.update=function(){this.lazy?this.dirty=!0:this.sync?this.run():function(e){var t=e.id;if(null==tn[t]){if(tn[t]=!0,rn){for(var n=Qt.length-1;n>on&&Qt[n].id>e.id;)n--;Qt.splice(n+1,0,e)}else Qt.push(e);nn||(nn=!0,Ye(un))}}(this)},fn.prototype.run=function(){if(this.active){var e=this.get();if(e!==this.value||o(e)||this.deep){var t=this.value;if(this.value=e,this.user)try{this.cb.call(this.vm,e,t)}catch(e){Re(e,this.vm,'callback for watcher "'+this.expression+'"')}else this.cb.call(this.vm,e,t)}}},fn.prototype.evaluate=function(){this.value=this.get(),this.dirty=!1},fn.prototype.depend=function(){for(var e=this.deps.length;e--;)this.deps[e].depend()},fn.prototype.teardown=function(){if(this.active){this.vm._isBeingDestroyed||h(this.vm._watchers,this);for(var e=this.deps.length;e--;)this.deps[e].removeSub(this);this.active=!1}};var pn={enumerable:!0,configurable:!0,get:S,set:S};function dn(e,t,n){pn.get=function(){return this[t][n]},pn.set=function(e){this[t][n]=e},Object.defineProperty(e,n,pn)}function vn(e){e._watchers=[];var t=e.$options;t.props&&function(e,t){var n=e.$options.propsData||{},r=e._props={},i=e.$options._propKeys=[];e.$parent&&$e(!1);var o=function(o){i.push(o);var a=Me(o,t,n,e);xe(r,o,a),o in e||dn(e,"_props",o)};for(var a in t)o(a);$e(!0)}(e,t.props),t.methods&&function(e,t){e.$options.props;for(var n in t)e[n]="function"!=typeof t[n]?S:x(t[n],e)}(e,t.methods),t.data?function(e){var t=e.$options.data;s(t=e._data="function"==typeof t?function(e,t){le();try{return e.call(t,t)}catch(e){return Re(e,t,"data()"),{}}finally{fe()}}(t,e):t||{})||(t={});var n=Object.keys(t),r=e.$options.props,i=(e.$options.methods,n.length);for(;i--;){var o=n[i];r&&y(r,o)||(a=void 0,36!==(a=(o+"").charCodeAt(0))&&95!==a&&dn(e,"_data",o))}var a;Ce(t,!0)}(e):Ce(e._data={},!0),t.computed&&function(e,t){var n=e._computedWatchers=Object.create(null),r=te();for(var i in t){var o=t[i],a="function"==typeof o?o:o.get;r||(n[i]=new fn(e,a||S,S,hn)),i in e||mn(e,i,o)}}(e,t.computed),t.watch&&t.watch!==Y&&function(e,t){for(var n in t){var r=t[n];if(Array.isArray(r))for(var i=0;i<r.length;i++)_n(e,n,r[i]);else _n(e,n,r)}}(e,t.watch)}var hn={lazy:!0};function mn(e,t,n){var r=!te();"function"==typeof n?(pn.get=r?yn(t):gn(n),pn.set=S):(pn.get=n.get?r&&!1!==n.cache?yn(t):gn(n.get):S,pn.set=n.set||S),Object.defineProperty(e,t,pn)}function yn(e){return function(){var t=this._computedWatchers&&this._computedWatchers[e];if(t)return t.dirty&&t.evaluate(),ce.target&&t.depend(),t.value}}function gn(e){return function(){return e.call(this,this)}}function _n(e,t,n,r){return s(n)&&(r=n,n=n.handler),"string"==typeof n&&(n=e[n]),e.$watch(t,n,r)}var bn=0;function $n(e){var t=e.options;if(e.super){var n=$n(e.super);if(n!==e.superOptions){e.superOptions=n;var r=function(e){var t,n=e.options,r=e.sealedOptions;for(var i in n)n[i]!==r[i]&&(t||(t={}),t[i]=n[i]);return t}(e);r&&A(e.extendOptions,r),(t=e.options=De(n,e.extendOptions)).name&&(t.components[t.name]=e)}}return t}function wn(e){this._init(e)}function Cn(e){e.cid=0;var t=1;e.extend=function(e){e=e||{};var n=this,r=n.cid,i=e._Ctor||(e._Ctor={});if(i[r])return i[r];var o=e.name||n.options.name,a=function(e){this._init(e)};return(a.prototype=Object.create(n.prototype)).constructor=a,a.cid=t++,a.options=De(n.options,e),a.super=n,a.options.props&&function(e){var t=e.options.props;for(var n in t)dn(e.prototype,"_props",n)}(a),a.options.computed&&function(e){var t=e.options.computed;for(var n in t)mn(e.prototype,n,t[n])}(a),a.extend=n.extend,a.mixin=n.mixin,a.use=n.use,M.forEach(function(e){a[e]=n[e]}),o&&(a.options.components[o]=a),a.superOptions=n.options,a.extendOptions=e,a.sealedOptions=A({},a.options),i[r]=a,a}}function xn(e){return e&&(e.Ctor.options.name||e.tag)}function kn(e,t){return Array.isArray(e)?e.indexOf(t)>-1:"string"==typeof e?e.split(",").indexOf(t)>-1:(n=e,"[object RegExp]"===a.call(n)&&e.test(t));var n}function An(e,t){var n=e.cache,r=e.keys,i=e._vnode;for(var o in n){var a=n[o];if(a){var s=xn(a.componentOptions);s&&!t(s)&&On(n,o,r,i)}}}function On(e,t,n,r){var i=e[t];!i||r&&i.tag===r.tag||i.componentInstance.$destroy(),e[t]=null,h(n,t)}!function(t){t.prototype._init=function(t){var n=this;n._uid=bn++,n._isVue=!0,t&&t._isComponent?function(e,t){var n=e.$options=Object.create(e.constructor.options),r=t._parentVnode;n.parent=t.parent,n._parentVnode=r;var i=r.componentOptions;n.propsData=i.propsData,n._parentListeners=i.listeners,n._renderChildren=i.children,n._componentTag=i.tag,t.render&&(n.render=t.render,n.staticRenderFns=t.staticRenderFns)}(n,t):n.$options=De($n(n.constructor),t||{},n),n._renderProxy=n,n._self=n,function(e){var t=e.$options,n=t.parent;if(n&&!t.abstract){for(;n.$options.abstract&&n.$parent;)n=n.$parent;n.$children.push(e)}e.$parent=n,e.$root=n?n.$root:e,e.$children=[],e.$refs={},e._watcher=null,e._inactive=null,e._directInactive=!1,e._isMounted=!1,e._isDestroyed=!1,e._isBeingDestroyed=!1}(n),function(e){e._events=Object.create(null),e._hasHookEvent=!1;var t=e.$options._parentListeners;t&&qt(e,t)}(n),function(t){t._vnode=null,t._staticTrees=null;var n=t.$options,r=t.$vnode=n._parentVnode,i=r&&r.context;t.$slots=ut(n._renderChildren,i),t.$scopedSlots=e,t._c=function(e,n,r,i){return Pt(t,e,n,r,i,!1)},t.$createElement=function(e,n,r,i){return Pt(t,e,n,r,i,!0)};var o=r&&r.data;xe(t,"$attrs",o&&o.attrs||e,null,!0),xe(t,"$listeners",n._parentListeners||e,null,!0)}(n),Yt(n,"beforeCreate"),function(e){var t=ct(e.$options.inject,e);t&&($e(!1),Object.keys(t).forEach(function(n){xe(e,n,t[n])}),$e(!0))}(n),vn(n),function(e){var t=e.$options.provide;t&&(e._provided="function"==typeof t?t.call(e):t)}(n),Yt(n,"created"),n.$options.el&&n.$mount(n.$options.el)}}(wn),function(e){var t={get:function(){return this._data}},n={get:function(){return this._props}};Object.defineProperty(e.prototype,"$data",t),Object.defineProperty(e.prototype,"$props",n),e.prototype.$set=ke,e.prototype.$delete=Ae,e.prototype.$watch=function(e,t,n){if(s(t))return _n(this,e,t,n);(n=n||{}).user=!0;var r=new fn(this,e,t,n);if(n.immediate)try{t.call(this,r.value)}catch(e){Re(e,this,'callback for immediate watcher "'+r.expression+'"')}return function(){r.teardown()}}}(wn),function(e){var t=/^hook:/;e.prototype.$on=function(e,n){var r=this;if(Array.isArray(e))for(var i=0,o=e.length;i<o;i++)r.$on(e[i],n);else(r._events[e]||(r._events[e]=[])).push(n),t.test(e)&&(r._hasHookEvent=!0);return r},e.prototype.$once=function(e,t){var n=this;function r(){n.$off(e,r),t.apply(n,arguments)}return r.fn=t,n.$on(e,r),n},e.prototype.$off=function(e,t){var n=this;if(!arguments.length)return n._events=Object.create(null),n;if(Array.isArray(e)){for(var r=0,i=e.length;r<i;r++)n.$off(e[r],t);return n}var o,a=n._events[e];if(!a)return n;if(!t)return n._events[e]=null,n;for(var s=a.length;s--;)if((o=a[s])===t||o.fn===t){a.splice(s,1);break}return n},e.prototype.$emit=function(e){var t=this._events[e];if(t){t=t.length>1?k(t):t;for(var n=k(arguments,1),r='event handler for "'+e+'"',i=0,o=t.length;i<o;i++)He(t[i],this,n,this,r)}return this}}(wn),function(e){e.prototype._update=function(e,t){var n=this,r=n.$el,i=n._vnode,o=Zt(n);n._vnode=e,n.$el=i?n.__patch__(i,e):n.__patch__(n.$el,e,t,!1),o(),r&&(r.__vue__=null),n.$el&&(n.$el.__vue__=n),n.$vnode&&n.$parent&&n.$vnode===n.$parent._vnode&&(n.$parent.$el=n.$el)},e.prototype.$forceUpdate=function(){this._watcher&&this._watcher.update()},e.prototype.$destroy=function(){var e=this;if(!e._isBeingDestroyed){Yt(e,"beforeDestroy"),e._isBeingDestroyed=!0;var t=e.$parent;!t||t._isBeingDestroyed||e.$options.abstract||h(t.$children,e),e._watcher&&e._watcher.teardown();for(var n=e._watchers.length;n--;)e._watchers[n].teardown();e._data.__ob__&&e._data.__ob__.vmCount--,e._isDestroyed=!0,e.__patch__(e._vnode,null),Yt(e,"destroyed"),e.$off(),e.$el&&(e.$el.__vue__=null),e.$vnode&&(e.$vnode.parent=null)}}}(wn),function(e){St(e.prototype),e.prototype.$nextTick=function(e){return Ye(e,this)},e.prototype._render=function(){var e,t=this,n=t.$options,r=n.render,i=n._parentVnode;i&&(t.$scopedSlots=ft(i.data.scopedSlots,t.$slots,t.$scopedSlots)),t.$vnode=i;try{Ht=t,e=r.call(t._renderProxy,t.$createElement)}catch(n){Re(n,t,"render"),e=t._vnode}finally{Ht=null}return Array.isArray(e)&&1===e.length&&(e=e[0]),e instanceof pe||(e=ve()),e.parent=i,e}}(wn);var Sn=[String,RegExp,Array],Tn={KeepAlive:{name:"keep-alive",abstract:!0,props:{include:Sn,exclude:Sn,max:[String,Number]},created:function(){this.cache=Object.create(null),this.keys=[]},destroyed:function(){for(var e in this.cache)On(this.cache,e,this.keys)},mounted:function(){var e=this;this.$watch("include",function(t){An(e,function(e){return kn(t,e)})}),this.$watch("exclude",function(t){An(e,function(e){return!kn(t,e)})})},render:function(){var e=this.$slots.default,t=zt(e),n=t&&t.componentOptions;if(n){var r=xn(n),i=this.include,o=this.exclude;if(i&&(!r||!kn(i,r))||o&&r&&kn(o,r))return t;var a=this.cache,s=this.keys,c=null==t.key?n.Ctor.cid+(n.tag?"::"+n.tag:""):t.key;a[c]?(t.componentInstance=a[c].componentInstance,h(s,c),s.push(c)):(a[c]=t,s.push(c),this.max&&s.length>parseInt(this.max)&&On(a,s[0],s,this._vnode)),t.data.keepAlive=!0}return t||e&&e[0]}}};!function(e){var t={get:function(){return F}};Object.defineProperty(e,"config",t),e.util={warn:ae,extend:A,mergeOptions:De,defineReactive:xe},e.set=ke,e.delete=Ae,e.nextTick=Ye,e.observable=function(e){return Ce(e),e},e.options=Object.create(null),M.forEach(function(t){e.options[t+"s"]=Object.create(null)}),e.options._base=e,A(e.options.components,Tn),function(e){e.use=function(e){var t=this._installedPlugins||(this._installedPlugins=[]);if(t.indexOf(e)>-1)return this;var n=k(arguments,1);return n.unshift(this),"function"==typeof e.install?e.install.apply(e,n):"function"==typeof e&&e.apply(null,n),t.push(e),this}}(e),function(e){e.mixin=function(e){return this.options=De(this.options,e),this}}(e),Cn(e),function(e){M.forEach(function(t){e[t]=function(e,n){return n?("component"===t&&s(n)&&(n.name=n.name||e,n=this.options._base.extend(n)),"directive"===t&&"function"==typeof n&&(n={bind:n,update:n}),this.options[t+"s"][e]=n,n):this.options[t+"s"][e]}})}(e)}(wn),Object.defineProperty(wn.prototype,"$isServer",{get:te}),Object.defineProperty(wn.prototype,"$ssrContext",{get:function(){return this.$vnode&&this.$vnode.ssrContext}}),Object.defineProperty(wn,"FunctionalRenderContext",{value:Tt}),wn.version="2.6.1
83622
vendor: 55,824 bytes, line 8362
8362";var En=p("style,class"),Nn=p("input,textarea,option,select,progress"),jn=function(e,t,n){return"value"===n&&Nn(e)&&"button"!==t||"selected"===n&&"option"===e||"checked"===n&&"input"===e||"muted"===n&&"video"===e},Dn=p("contenteditable,draggable,spellcheck"),Ln=p("events,caret,typing,plaintext-only"),Mn=function(e,t){return Hn(t)||"false"===t?"false":"contenteditable"===e&&Ln(t)?t:"true"},In=p("allowfullscreen,async,autofocus,autoplay,checked,compact,controls,declare,default,defaultchecked,defaultmuted,defaultselected,defer,disabled,enabled,formnovalidate,hidden,indeterminate,inert,ismap,itemscope,loop,multiple,muted,nohref,noresize,noshade,novalidate,nowrap,open,pauseonexit,readonly,required,reversed,scoped,seamless,selected,sortable,translate,truespeed,typemustmatch,visible"),Fn="http://www.w3.org/1999/xlink",Pn=function(e){return":"===e.charAt(5)&&"xlink"===e.slice(0,5)},Rn=function(e){return Pn(e)?e.slice(6,e.length):""},Hn=function(e){return null==e||!1===e};function Bn(e){for(var t=e.data,r=e,i=e;n(i.componentInstance);)(i=i.componentInstance._vnode)&&i.data&&(t=Un(i.data,t));for(;n(r=r.parent);)r&&r.data&&(t=Un(t,r.data));return function(e,t){if(n(e)||n(t))return zn(e,Vn(t));return""}(t.staticClass,t.class)}function Un(e,t){return{staticClass:zn(e.staticClass,t.staticClass),class:n(e.class)?[e.class,t.class]:t.class}}function zn(e,t){return e?t?e+" "+t:e:t||""}function Vn(e){return Array.isArray(e)?function(e){for(var t,r="",i=0,o=e.length;i<o;i++)n(t=Vn(e[i]))&&""!==t&&(r&&(r+=" "),r+=t);return r}(e):o(e)?function(e){var t="";for(var n in e)e[n]&&(t&&(t+=" "),t+=n);return t}(e):"string"==typeof e?e:""}var Kn={svg:"http://www.w3.org/2000/svg",math:"http://www.w3.org/1998/Math/MathML"},Jn=p("html,body,base,head,link,meta,style,title,address,article,aside,footer,header,h1,h2,h3,h4,h5,h6,hgroup,nav,section,div,dd,dl,dt,figcaption,figure,picture,hr,img,li,main,ol,p,pre,ul,a,b,abbr,bdi,bdo,br,cite,code,data,dfn,em,i,kbd,mark,q,rp,rt,rtc,ruby,s,samp,small,span,strong,sub,sup,time,u,var,wbr,area,audio,map,track,video,embed,object,param,source,canvas,script,noscript,del,ins,caption,col,colgroup,table,thead,tbody,td,th,tr,button,datalist,fieldset,form,input,label,legend,meter,optgroup,option,output,progress,select,textarea,details,dialog,menu,menuitem,summary,content,element,shadow,template,blockquote,iframe,tfoot"),qn=p("svg,animate,circle,clippath,cursor,defs,desc,ellipse,filter,font-face,foreignObject,g,glyph,image,line,marker,mask,missing-glyph,path,pattern,polygon,polyline,rect,switch,symbol,text,textpath,tspan,use,view",!0),Wn=function(e){return Jn(e)||qn(e)};function Zn(e){return qn(e)?"svg":"math"===e?"math":void 0}var Gn=Object.create(null);var Xn=p("text,number,password,search,email,tel,url");function Yn(e){if("string"==typeof e){var t=document.querySelector(e);return t||document.createElement("div")}return e}var Qn=Object.freeze({createElement:function(e,t){var n=document.createElement(e);return"select"!==e?n:(t.data&&t.data.attrs&&void 0!==t.data.attrs.multiple&&n.setAttribute("multiple","multiple"),n)},createElementNS:function(e,t){return document.createElementNS(Kn[e],t)},createTextNode:function(e){return document.createTextNode(e)},createComment:function(e){return document.createComment(e)},insertBefore:function(e,t,n){e.insertBefore(t,n)},removeChild:function(e,t){e.removeChild(t)},appendChild:function(e,t){e.appendChild(t)},parentNode:function(e){return e.parentNode},nextSibling:function(e){return e.nextSibling},tagName:function(e){return e.tagName},setTextContent:function(e,t){e.textContent=t},setStyleScope:function(e,t){e.setAttribute(t,"")}}),er={create:function(e,t){tr(t)},update:function(e,t){e.data.ref!==t.data.ref&&(tr(e,!0),tr(t))},destroy:function(e){tr(e,!0)}};function tr(e,t){var r=e.data.ref;if(n(r)){var i=e.context,o=e.componentInstance||e.elm,a=i.$refs;t?Array.isArray(a[r])?h(a[r],o):a[r]===o&&(a[r]=void 0):e.data.refInFor?Array.isArray(a[r])?a[r].indexOf(o)<0&&a[r].push(o):a[r]=[o]:a[r]=o}}var nr=new pe("",{},[]),rr=["create","activate","update","remove","destroy"];function ir(e,i){return e.key===i.key&&(e.tag===i.tag&&e.isComment===i.isComment&&n(e.data)===n(i.data)&&function(e,t){if("input"!==e.tag)return!0;var r,i=n(r=e.data)&&n(r=r.attrs)&&r.type,o=n(r=t.data)&&n(r=r.attrs)&&r.type;return i===o||Xn(i)&&Xn(o)}(e,i)||r(e.isAsyncPlaceholder)&&e.asyncFactory===i.asyncFactory&&t(i.asyncFactory.error))}function or(e,t,r){var i,o,a={};for(i=t;i<=r;++i)n(o=e[i].key)&&(a[o]=i);return a}var ar={create:sr,update:sr,destroy:function(e){sr(e,nr)}};function sr(e,t){(e.data.directives||t.data.directives)&&function(e,t){var n,r,i,o=e===nr,a=t===nr,s=ur(e.data.directives,e.context),c=ur(t.data.directives,t.context),u=[],l=[];for(n in c)r=s[n],i=c[n],r?(i.oldValue=r.value,i.oldArg=r.arg,fr(i,"update",t,e),i.def&&i.def.componentUpdated&&l.push(i)):(fr(i,"bind",t,e),i.def&&i.def.inserted&&u.push(i));if(u.length){var f=function(){for(var n=0;n<u.length;n++)fr(u[n],"inserted",t,e)};o?it(t,"insert",f):f()}l.length&&it(t,"postpatch",function(){for(var n=0;n<l.length;n++)fr(l[n],"componentUpdated",t,e)});if(!o)for(n in s)c[n]||fr(s[n],"unbind",e,e,a)}(e,t)}var cr=Object.create(null);function ur(e,t){var n,r,i=Object.create(null);if(!e)return i;for(n=0;n<e.length;n++)(r=e[n]).modifiers||(r.modifiers=cr),i[lr(r)]=r,r.def=Le(t.$options,"directives",r.name);return i}function lr(e){return e.rawName||e.name+"."+Object.keys(e.modifiers||{}).join(".")}function fr(e,t,n,r,i){var o=e.def&&e.def[t];if(o)try{o(n.elm,e,n,r,i)}catch(r){Re(r,n.context,"directive "+e.name+" "+t+" hook")}}var pr=[er,ar];function dr(e,r){var i=r.componentOptions;if(!(n(i)&&!1===i.Ctor.options.inheritAttrs||t(e.data.attrs)&&t(r.data.attrs))){var o,a,s=r.elm,c=e.data.attrs||{},u=r.data.attrs||{};for(o in n(u.__ob__)&&(u=r.data.attrs=A({},u)),u)a=u[o],c[o]!==a&&vr(s,o,a);for(o in(q||Z)&&u.value!==c.value&&vr(s,"value",u.value),c)t(u[o])&&(Pn(o)?s.removeAttributeNS(Fn,Rn(o)):Dn(o)||s.removeAttribute(o))}}function vr(e,t,n){e.tagName.indexOf("-")>-1?hr(e,t,n):In(t)?Hn(n)?e.removeAttribute(t):(n="allowfullscreen"===t&&"EMBED"===e.tagName?"true":t,e.setAttribute(t,n)):Dn(t)?e.setAttribute(t,Mn(t,n)):Pn(t)?Hn(n)?e.removeAttributeNS(Fn,Rn(t)):e.setAttributeNS(Fn,t,n):hr(e,t,n)}function hr(e,t,n){if(Hn(n))e.removeAttribute(t);else{if(q&&!W&&"TEXTAREA"===e.tagName&&"placeholder"===t&&""!==n&&!e.__ieph){var r=function(t){t.stopImmediatePropagation(),e.removeEventListener("input",r)};e.addEventListener("input",r),e.__ieph=!0}e.setAttribute(t,n)}}var mr={create:dr,update:dr};function yr(e,r){var i=r.elm,o=r.data,a=e.data;if(!(t(o.staticClass)&&t(o.class)&&(t(a)||t(a.staticClass)&&t(a.class)))){var s=Bn(r),c=i._transitionClasses;n(c)&&(s=zn(s,Vn(c))),s!==i._prevClass&&(i.setAttribute("class",s),i._prevClass=s)}}var gr,_r,br,$r,wr,Cr,xr={create:yr,update:yr},kr=/[\w).+\-_$\]]/;function Ar(e){var t,n,r,i,o,a=!1,s=!1,c=!1,u=!1,l=0,f=0,p=0,d=0;for(r=0;r<e.length;r++)if(n=t,t=e.charCodeAt(r),a)39===t&&92!==n&&(a=!1);else if(s)34===t&&92!==n&&(s=!1);else if(c)96===t&&92!==n&&(c=!1);else if(u)47===t&&92!==n&&(u=!1);else if(124!==t||124===e.charCodeAt(r+1)||124===e.charCodeAt(r-1)||l||f||p){switch(t){case 34:s=!0;break;case 39:a=!0;break;case 96:c=!0;break;case 40:p++;break;case 41:p--;break;case 91:f++;break;case 93:f--;break;case 123:l++;break;case 125:l--}if(47===t){for(var v=r-1,h=void 0;v>=0&&" "===(h=e.charAt(v));v--);h&&kr.test(h)||(u=!0)}}else void 0===i?(d=r+1,i=e.slice(0,r).trim()):m();function m(){(o||(o=[])).push(e.slice(d,r).trim()),d=r+1}if(void 0===i?i=e.slice(0,r).trim():0!==d&&m(),o)for(r=0;r<o.length;r++)i=Or(i,o[r]);return i}function Or(e,t){var n=t.indexOf("(");if(n<0)return'_f("'+t+'")('+e+")";var r=t.slice(0,n),i=t.slice(n+1);return'_f("'+r+'")('+e+(")"!==i?","+i:i)}function Sr(e,t){console.error("[Vue compiler]: "+e)}function Tr(e,t){return e?e.map(function(e){return e[t]}).filter(function(e){return e}):[]}function Er(e,t,n,r,i){(e.props||(e.props=[])).push(Rr({name:t,value:n,dynamic:i},r)),e.plain=!1}function Nr(e,t,n,r,i){(i?e.dynamicAttrs||(e.dynamicAttrs=[]):e.attrs||(e.attrs=[])).push(Rr({name:t,value:n,dynamic:i},r)),e.plain=!1}function jr(e,t,n,r){e.attrsMap[t]=n,e.attrsList.push(Rr({name:t,value:n},r))}function Dr(e,t,n,r,i,o,a,s){(e.directives||(e.directives=[])).push(Rr({name:t,rawName:n,value:r,arg:i,isDynamicArg:o,modifiers:a},s)),e.plain=!1}function Lr(e,t,n){return n?"_p("+t+',"'+e+'")':e+t}function Mr(t,n,r,i,o,a,s,c){var u;(i=i||e).right?c?n="("+n+")==='click'?'contextmenu':("+n+")":"click"===n&&(n="contextmenu",delete i.right):i.middle&&(c?n="("+n+")==='click'?'mouseup':("+n+")":"click"===n&&(n="mouseup")),i.capture&&(delete i.capture,n=Lr("!",n,c)),i.once&&(delete i.once,n=Lr("~",n,c)),i.passive&&(delete i.passive,n=Lr("&",n,c)),i.native?(delete i.native,u=t.nativeEvents||(t.nativeEvents={})):u=t.events||(t.events={});var l=Rr({value:r.trim(),dynamic:c},s);i!==e&&(l.modifiers=i);var f=u[n];Array.isArray(f)?o?f.unshift(l):f.push(l):u[n]=f?o?[l,f]:[f,l]:l,t.plain=!1}function Ir(e,t,n){var r=Fr(e,":"+t)||Fr(e,"v-bind:"+t);if(null!=r)return Ar(r);if(!1!==n){var i=Fr(e,t);if(null!=i)return JSON.stringify(i)}}function Fr(e,t,n){var r;if(null!=(r=e.attrsMap[t]))for(var i=e.attrsList,o=0,a=i.length;o<a;o++)if(i[o].name===t){i.splice(o,1);break}return n&&delete e.attrsMap[t],r}function Pr(e,t){for(var n=e.attrsList,r=0,i=n.length;r<i;r++){var o=n[r];if(t.test(o.name))return n.splice(r,1),o}}function Rr(e,t){return t&&(null!=t.start&&(e.start=t.start),null!=t.end&&(e.end=t.end)),e}function Hr(e,t,n){var r=n||{},i=r.number,o="$$v";r.trim&&(o="(typeof $$v === 'string'? $$v.trim(): $$v)"),i&&(o="_n("+o+")");var a=Br(t,o);e.model={value:"("+t+")",expression:JSON.stringify(t),callback:"function ($$v) {"+a+"}"}}function Br(e,t){var n=function(e){if(e=e.trim(),gr=e.length,e.indexOf("[")<0||e.lastIndexOf("]")<gr-1)return($r=e.lastIndexOf("."))>-1?{exp:e.slice(0,$r),key:'"'+e.slice($r+1)+'"'}:{exp:e,key:null};_r=e,$r=wr=Cr=0;for(;!zr();)Vr(br=Ur())?Jr(br):91===br&&Kr(br);return{exp:e.slice(0,wr),key:e.slice(wr+1,Cr)}}(e);return null===n.key?e+"="+t:"$set("+n.exp+", "+n.key+", "+t+")"}function Ur(){return _r.charCodeAt(++$r)}function zr(){return $r>=gr}function Vr(e){return 34===e||39===e}function Kr(e){var t=1;for(wr=$r;!zr();)if(Vr(e=Ur()))Jr(e);else if(91===e&&t++,93===e&&t--,0===t){Cr=$r;break}}function Jr(e){for(var t=e;!zr()&&(e=Ur())!==t;);}var qr,Wr="__r",Zr="__c";function Gr(e,t,n){var r=qr;return function i(){null!==t.apply(null,arguments)&&Qr(e,i,n,r)}}var Xr=Ve&&!(X&&Number(X[1])<=53);function Yr(e,t,n,r){if(Xr){var i=an,o=t;t=o._wrapper=function(e){if(e.target===e.currentTarget||e.timeStamp>=i||e.timeStamp<=0||e.target.ownerDocument!==document)return o.apply(this,arguments)}}qr.addEventListener(e,t,Q?{capture:n,passive:r}:n)}function Qr(e,t,n,r){(r||qr).removeEventListener(e,t._wrapper||t,n)}function ei(e,r){if(!t(e.data.on)||!t(r.data.on)){var i=r.data.on||{},o=e.data.on||{};qr=r.elm,function(e){if(n(e[Wr])){var t=q?"change":"input";e[t]=[].concat(e[Wr],e[t]||[]),delete e[Wr]}n(e[Zr])&&(e.change=[].concat(e[Zr],e.change||[]),delete e[Zr])}(i),rt(i,o,Yr,Qr,Gr,r.context),qr=void 0}}var ti,ni={create:ei,update:ei};function ri(e,r){if(!t(e.data.domProps)||!t(r.data.domProps)){var i,o,a=r.elm,s=e.data.domProps||{},c=r.data.domProps||{};for(i in n(c.__ob__)&&(c=r.data.domProps=A({},c)),s)i in c||(a[i]="");for(i in c){if(o=c[i],"textContent"===i||"innerHTML"===i){if(r.children&&(r.children.length=0),o===s[i])continue;1===a.childNodes.length&&a.removeChild(a.childNodes[0])}if("value"===i&&"PROGRESS"!==a.tagName){a._value=o;var u=t(o)?"":String(o);ii(a,u)&&(a.value=u)}else if("innerHTML"===i&&qn(a.tagName)&&t(a.innerHTML)){(ti=ti||document.createElement("div")).innerHTML="<svg>"+o+"</svg>";for(var l=ti.firstChild;a.firstChild;)a.removeChild(a.firstChild);for(;l.firstChild;)a.appendChild(l.firstChild)}else if(o!==s[i])try{a[i]=o}catch(e){}}}}function ii(e,t){return!e.composing&&("OPTION"===e.tagName||function(e,t){var n=!0;try{n=document.activeElement!==e}catch(e){}return n&&e.value!==t}(e,t)||function(e,t){var r=e.value,i=e._vModifiers;if(n(i)){if(i.number)return f(r)!==f(t);if(i.trim)return r.trim()!==t.trim()}return r!==t}(e,t))}var oi={create:ri,update:ri},ai=g(function(e){var t={},n=/:(.+)/;return e.split(/;(?![^(]*\))/g).forEach(function(e){if(e){var r=e.split(n);r.length>1&&(t[r[0].trim()]=r[1].trim())}}),t});function si(e){var t=ci(e.style);return e.staticStyle?A(e.staticStyle,t):t}function ci(e){return Array.isArray(e)?O(e):"string"==typeof e?ai(e):e}var ui,li=/^--/,fi=/\s*!important$/,pi=function(e,t,n){if(li.test(t))e.style.setProperty(t,n);else if(fi.test(n))e.style.setProperty(C(t),n.replace(fi,""),"important");else{var r=vi(t);if(Array.isArray(n))for(var i=0,o=n.length;i<o;i++)e.style[r]=n[i];else e.style[r]=n}},di=["Webkit","Moz","ms"],vi=g(function(e){if(ui=ui||document.createElement("div").style,"filter"!==(e=b(e))&&e in ui)return e;for(var t=e.charAt(0).toUpperCase()+e.slice(1),n=0;n<di.length;n++){var r=di[n]+t;if(r in ui)return r}});function hi(e,r){var i=r.data,o=e.data;if(!(t(i.staticStyle)&&t(i.style)&&t(o.staticStyle)&&t(o.style))){var a,s,c=r.elm,u=o.staticStyle,l=o.normalizedStyle||o.style||{},f=u||l,p=ci(r.data.style)||{};r.data.normalizedStyle=n(p.__ob__)?A({},p):p;var d=function(e,t){var n,r={};if(t)for(var i=e;i.componentInstance;)(i=i.componentInstance._vnode)&&i.data&&(n=si(i.data))&&A(r,n);(n=si(e.data))&&A(r,n);for(var o=e;o=o.parent;)o.data&&(n=si(o.data))&&A(r,n);return r}(r,!0);for(s in f)t(d[s])&&pi(c,s,"");for(s in d)(a=d[s])!==f[s]&&pi(c,s,null==a?"":a)}}var mi={create:hi,update:hi},yi=/\s+/;function gi(e,t){if(t&&(t=t.trim()))if(e.classList)t.indexOf(" ")>-1?t.split(yi).forEach(function(t){return e.classList.add(t)}):e.classList.add(t);else{var n=" "+(e.getAttribute("class")||"")+" ";n.indexOf(" "+t+" ")<0&&e.setAttribute("class",(n+t).trim())}}function _i(e,t){if(t&&(t=t.trim()))if(e.classList)t.indexOf(" ")>-1?t.split(yi).forEach(function(t){return e.classList.remove(t)}):e.classList.remove(t),e.classList.length||e.removeAttribute("class");else{for(var n=" "+(e.getAttribute("class")||"")+" ",r=" "+t+" ";n.indexOf(r)>=0;)n=n.replace(r," ");(n=n.trim())?e.setAttribute("class",n):e.removeAttribute("class")}}function bi(e){if(e){if("object"==typeof e){var t={};return!1!==e.css&&A(t,$i(e.name||"v")),A(t,e),t}return"string"==typeof e?$i(e):void 0}}var $i=g(function(e){return{enterClass:e+"-enter",enterToClass:e+"-enter-to",enterActiveClass:e+"-enter-active",leaveClass:e+"-leave",leaveToClass:e+"-leave-to",leaveActiveClass:e+"-leave-active"}}),wi=z&&!W,Ci="transition",xi="animation",ki="transition",Ai="transitionend",Oi="animation",Si="animationend";wi&&(void 0===window.ontransitionend&&void 0!==window.onwebkittransitionend&&(ki="WebkitTransition",Ai="webkitTransitionEnd"),void 0===window.onanimationend&&void 0!==window.onwebkitanimationend&&(Oi="WebkitAnimation",Si="webkitAnimationEnd"));var Ti=z?window.requestAnimationFrame?window.requestAnimationFrame.bind(window):setTimeout:function(e){return e()};function Ei(e){Ti(function(){Ti(e)})}function Ni(e,t){var n=e._transitionClasses||(e._transitionClasses=[]);n.indexOf(t)<0&&(n.push(t),gi(e,t))}function ji(e,t){e._transitionClasses&&h(e._transitionClasses,t),_i(e,t)}function Di(e,t,n){var r=Mi(e,t),i=r.type,o=r.timeout,a=r.propCount;if(!i)return n();var s=i===Ci?Ai:Si,c=0,u=function(){e.removeEventListener(s,l),n()},l=function(t){t.target===e&&++c>=a&&u()};setTimeout(function(){c<a&&u()},o+1),e.addEventListener(s,l)}var Li=/\b(transform|all)(,|$)/;function Mi(e,t){var n,r=window.getComputedStyle(e),i=(r[ki+"Delay"]||"").split(", "),o=(r[ki+"Duration"]||"").split(", "),a=Ii(i,o),s=(r[Oi+"Delay"]||"").split(", "),c=(r[Oi+"Duration"]||"").split(", "),u=Ii(s,c),l=0,f=0;return t===Ci?a>0&&(n=Ci,l=a,f=o.length):t===xi?u>0&&(n=xi,l=u,f=c.length):f=(n=(l=Math.max(a,u))>0?a>u?Ci:xi:null)?n===Ci?o.length:c.length:0,{type:n,timeout:l,propCount:f,hasTransform:n===Ci&&Li.test(r[ki+"Property"])}}function Ii(e,t){for(;e.length<t.length;)e=e.concat(e);return Math.max.apply(null,t.map(function(t,n){return Fi(t)+Fi(e[n])}))}function Fi(e){return 1e3*Number(e.slice(0,-1).replace(",","."))}function Pi(e,r){var i=e.elm;n(i._leaveCb)&&(i._leaveCb.cancelled=!0,i._leaveCb());var a=bi(e.data.transition);if(!t(a)&&!n(i._enterCb)&&1===i.nodeType){for(var s=a.css,c=a.type,u=a.enterClass,l=a.enterToClass,p=a.enterActiveClass,d=a.appearClass,v=a.appearToClass,h=a.appearActiveClass,m=a.beforeEnter,y=a.enter,g=a.afterEnter,_=a.enterCancelled,b=a.beforeAppear,$=a.appear,w=a.afterAppear,C=a.appearCancelled,x=a.duration,k=Wt,A=Wt.$vnode;A&&A.parent;)k=A.context,A=A.parent;var O=!k._isMounted||!e.isRootInsert;if(!O||$||""===$){var S=O&&d?d:u,T=O&&h?h:p,E=O&&v?v:l,N=O&&b||m,j=O&&"function"==typeof $?$:y,L=O&&w||g,M=O&&C||_,I=f(o(x)?x.enter:x),F=!1!==s&&!W,P=Bi(j),R=i._enterCb=D(function(){F&&(ji(i,E),ji(i,T)),R.cancelled?(F&&ji(i,S),M&&M(i)):L&&L(i),i._enterCb=null});e.data.show||it(e,"insert",function(){var t=i.parentNode,n=t&&t._pending&&t._pending[e.key];n&&n.tag===e.tag&&n.elm._leaveCb&&n.elm._leaveCb(),j&&j(i,R)}),N&&N(i),F&&(Ni(i,S),Ni(i,T),Ei(function(){ji(i,S),R.cancelled||(Ni(i,E),P||(Hi(I)?setTimeout(R,I):Di(i,c,R)))})),e.data.show&&(r&&r(),j&&j(i,R)),F||P||R()}}}function Ri(e,r){var i=e.elm;n(i._enterCb)&&(i._enterCb.cancelled=!0,i._enterCb());var a=bi(e.data.transition);if(t(a)||1!==i.nodeType)return r();if(!n(i._leaveCb)){var s=a.css,c=a.type,u=a.leaveClass,l=a.leaveToClass,p=a.leaveActiveClass,d=a.beforeLeave,v=a.leave,h=a.afterLeave,m=a.leaveCancelled,y=a.delayLeave,g=a.duration,_=!1!==s&&!W,b=Bi(v),$=f(o(g)?g.leave:g),w=i._leaveCb=D(function(){i.parentNode&&i.parentNode._pending&&(i.parentNode._pending[e.key]=null),_&&(ji(i,l),ji(i,p)),w.cancelled?(_&&ji(i,u),m&&m(i)):(r(),h&&h(i)),i._leaveCb=null});y?y(C):C()}function C(){w.cancelled||(!e.data.show&&i.parentNode&&((i.parentNode._pending||(i.parentNode._pending={}))[e.key]=e),d&&d(i),_&&(Ni(i,u),Ni(i,p),Ei(function(){ji(i,u),w.cancelled||(Ni(i,l),b||(Hi($)?setTimeout(w,$):Di(i,c,w)))})),v&&v(i,w),_||b||w())}}function Hi(e){return"number"==typeof e&&!isNaN(e)}function Bi(e){if(t(e))return!1;var r=e.fns;return n(r)?Bi(Array.isArray(r)?r[0]:r):(e._length||e.length)>1}function Ui(e,t){!0!==t.data.show&&Pi(t)}var zi=function(e){var o,a,s={},c=e.modules,u=e.nodeOps;for(o=0;o<rr.length;++o)for(s[rr[o]]=[],a=0;a<c.length;++a)n(c[a][rr[o]])&&s[rr[o]].push(c[a][rr[o]]);function l(e){var t=u.parentNode(e);n(t)&&u.removeChild(t,e)}function f(e,t,i,o,a,c,l){if(n(e.elm)&&n(c)&&(e=c[l]=me(e)),e.isRootInsert=!a,!function(e,t,i,o){var a=e.data;if(n(a)){var c=n(e.componentInstance)&&a.keepAlive;if(n(a=a.hook)&&n(a=a.init)&&a(e,!1),n(e.componentInstance))return d(e,t),v(i,e.elm,o),r(c)&&function(e,t,r,i){for(var o,a=e;a.componentInstance;)if(a=a.componentInstance._vnode,n(o=a.data)&&n(o=o.transition)){for(o=0;o<s.activate.length;++o)s.activate[o](nr,a);t.push(a);break}v(r,e.elm,i)}(e,t,i,o),!0}}(e,t,i,o)){var f=e.data,p=e.children,m=e.tag;n(m)?(e.elm=e.ns?u.createElementNS(e.ns,m):u.createElement(m,e),g(e),h(e,p,t),n(f)&&y(e,t),v(i,e.elm,o)):r(e.isComment)?(e.elm=u.createComment(e.text),v(i,e.elm,o)):(e.elm=u.createTextNode(e.text),v(i,e.elm,o))}}function d(e,t){n(e.data.pendingInsert)&&(t.push.apply(t,e.data.pendingInsert),e.data.pendingInsert=null),e.elm=e.componentInstance.$el,m(e)?(y(e,t),g(e)):(tr(e),t.push(e))}function v(e,t,r){n(e)&&(n(r)?u.parentNode(r)===e&&u.insertBefore(e,t,r):u.appendChild(e,t))}function h(e,t,n){if(Array.isArray(t))for(var r=0;r<t.length;++r)f(t[r],n,e.elm,null,!0,t,r);else i(e.text)&&u.appendChild(e.elm,u.createTextNode(String(e.text)))}function m(e){for(;e.componentInstance;)e=e.componentInstance._vnode;return n(e.tag)}function y(e,t){for(var r=0;r<s.create.length;++r)s.create[r](nr,e);n(o=e.data.hook)&&(n(o.create)&&o.create(nr,e),n(o.insert)&&t.push(e))}function g(e){var t;if(n(t=e.fnScopeId))u.setStyleScope(e.elm,t);else for(var r=e;r;)n(t=r.context)&&n(t=t.$options._scopeId)&&u.setStyleScope(e.elm,t),r=r.parent;n(t=Wt)&&t!==e.context&&t!==e.fnContext&&n(t=t.$options._scopeId)&&u.setStyleScope(e.elm,t)}function _(e,t,n,r,i,o){for(;r<=i;++r)f(n[r],o,e,t,!1,n,r)}function b(e){var t,r,i=e.data;if(n(i))for(n(t=i.hook)&&n(t=t.destroy)&&t(e),t=0;t<s.destroy.length;++t)s.destroy[t](e);if(n(t=e.children))for(r=0;r<e.children.length;++r)b(e.children[r])}function $(e,t,r){for(;t<=r;++t){var i=e[t];n(i)&&(n(i.tag)?(w(i),b(i)):l(i.elm))}}function w(e,t){if(n(t)||n(e.data)){var r,i=s.remove.length+1;for(n(t)?t.listeners+=i:t=function(e,t){function n(){0==--n.listeners&&l(e)}return n.listeners=t,n}(e.elm,i),n(r=e.componentInstance)&&n(r=r._vnode)&&n(r.data)&&w(r,t),r=0;r<s.remove.length;++r)s.remove[r](e,t);n(r=e.data.hook)&&n(r=r.remove)?r(e,t):t()}else l(e.elm)}function C(e,t,r,i){for(var o=r;o<i;o++){var a=t[o];if(n(a)&&ir(e,a))return o}}function x(e,i,o,a,c,l){if(e!==i){n(i.elm)&&n(a)&&(i=a[c]=me(i));var p=i.elm=e.elm;if(r(e.isAsyncPlaceholder))n(i.asyncFactory.resolved)?O(e.elm,i,o):i.isAsyncPlaceholder=!0;else if(r(i.isStatic)&&r(e.isStatic)&&i.key===e.key&&(r(i.isCloned)||r(i.isOnce)))i.componentInstance=e.componentInstance;else{var d,v=i.data;n(v)&&n(d=v.hook)&&n(d=d.prepatch)&&d(e,i);var h=e.children,y=i.children;if(n(v)&&m(i)){for(d=0;d<s.update.length;++d)s.update[d](e,i);n(d=v.hook)&&n(d=d.update)&&d(e,i)}t(i.text)?n(h)&&n(y)?h!==y&&function(e,r,i,o,a){for(var s,c,l,p=0,d=0,v=r.length-1,h=r[0],m=r[v],y=i.length-1,g=i[0],b=i[y],w=!a;p<=v&&d<=y;)t(h)?h=r[++p]:t(m)?m=r[--v]:ir(h,g)?(x(h,g,o,i,d),h=r[++p],g=i[++d]):ir(m,b)?(x(m,b,o,i,y),m=r[--v],b=i[--y]):ir(h,b)?(x(h,b,o,i,y),w&&u.insertBefore(e,h.elm,u.nextSibling(m.elm)),h=r[++p],b=i[--y]):ir(m,g)?(x(m,g,o,i,d),w&&u.insertBefore(e,m.elm,h.elm),m=r[--v],g=i[++d]):(t(s)&&(s=or(r,p,v)),t(c=n(g.key)?s[g.key]:C(g,r,p,v))?f(g,o,e,h.elm,!1,i,d):ir(l=r[c],g)?(x(l,g,o,i,d),r[c]=void 0,w&&u.insertBefore(e,l.elm,h.elm)):f(g,o,e,h.elm,!1,i,d),g=i[++d]);p>v?_(e,t(i[y+1])?null:i[y+1].elm,i,d,y,o):d>y&&$(r,p,v)}(p,h,y,o,l):n(y)?(n(e.text)&&u.setTextContent(p,""),_(p,null,y,0,y.length-1,o)):n(h)?$(h,0,h.length-1):n(e.text)&&u.setTextContent(p,""):e.text!==i.text&&u.setTextContent(p,i.text),n(v)&&n(d=v.hook)&&n(d=d.postpatch)&&d(e,i)}}}function k(e,t,i){if(r(i)&&n(e.parent))e.parent.data.pendingInsert=t;else for(var o=0;o<t.length;++o)t[o].data.hook.insert(t[o])}var A=p("attrs,class,staticClass,staticStyle,key");function O(e,t,i,o){var a,s=t.tag,c=t.data,u=t.children;if(o=o||c&&c.pre,t.elm=e,r(t.isComment)&&n(t.asyncFactory))return t.isAsyncPlaceholder=!0,!0;if(n(c)&&(n(a=c.hook)&&n(a=a.init)&&a(t,!0),n(a=t.componentInstance)))return d(t,i),!0;if(n(s)){if(n(u))if(e.hasChildNodes())if(n(a=c)&&n(a=a.domProps)&&n(a=a.innerHTML)){if(a!==e.innerHTML)return!1}else{for(var l=!0,f=e.firstChild,p=0;p<u.length;p++){if(!f||!O(f,u[p],i,o)){l=!1;break}f=f.nextSibling}if(!l||f)return!1}else h(t,u,i);if(n(c)){var v=!1;for(var m in c)if(!A(m)){v=!0,y(t,i);break}!v&&c.class&&et(c.class)}}else e.data!==t.text&&(e.data=t.text);return!0}return function(e,i,o,a){if(!t(i)){var c,l=!1,p=[];if(t(e))l=!0,f(i,p);else{var d=n(e.nodeType);if(!d&&ir(e,i))x(e,i,p,null,null,a);else{if(d){if(1===e.nodeType&&e.hasAttribute(L)&&(e.removeAttribute(L),o=!0),r(o)&&O(e,i,p))return k(i,p,!0),e;c=e,e=new pe(u.tagName(c).toLowerCase(),{},[],void 0,c)}var v=e.elm,h=u.parentNode(v);if(f(i,p,v._leaveCb?null:h,u.nextSibling(v)),n(i.parent))for(var y=i.parent,g=m(i);y;){for(var _=0;_<s.destroy.length;++_)s.destroy[_](y);if(y.elm=i.elm,g){for(var w=0;w<s.create.length;++w)s.create[w](nr,y);var C=y.data.hook.insert;if(C.merged)for(var A=1;A<C.fns.length;A++)C.fns[A]()}else tr(y);y=y.parent}n(h)?$([e],0,0):n(e.tag)&&b(e)}}return k(i,p,l),i.elm}n(e)&&b(e)}}({nodeOps:Qn,modules:[mr,xr,ni,oi,mi,z?{create:Ui,activate:Ui,remove:function(e,t){!0!==e.data.show?Ri(e,t):t()}}:{}].concat(pr)});W&&document.addEventListener("selectionchange",function(){var e=document.activeElement;e&&e.vmodel&&Xi(e,"input")});var Vi={inserted:function(e,t,n,r){"select"===n.tag?(r.elm&&!r.elm._vOptions?it(n,"postpatch",function(){Vi.componentUpdated(e,t,n)}):Ki(e,t,n.context),e._vOptions=[].map.call(e.options,Wi)):("textarea"===n.tag||Xn(e.type))&&(e._vModifiers=t.modifiers,t.modifiers.lazy||(e.addEventListener("compositionstart",Zi),e.addEventListener("compositionend",Gi),e.addEventListener("change",Gi),W&&(e.vmodel=!0)))},componentUpdated:function(e,t,n){if("select"===n.tag){Ki(e,t,n.context);var r=e._vOptions,i=e._vOptions=[].map.call(e.options,Wi);if(i.some(function(e,t){return!N(e,r[t])}))(e.multiple?t.value.some(function(e){return qi(e,i)}):t.value!==t.oldValue&&qi(t.value,i))&&Xi(e,"change")}}};function Ki(e,t,n){Ji(e,t,n),(q||Z)&&setTimeout(function(){Ji(e,t,n)},0)}function Ji(e,t,n){var r=t.value,i=e.multiple;if(!i||Array.isArray(r)){for(var o,a,s=0,c=e.options.length;s<c;s++)if(a=e.options[s],i)o=j(r,Wi(a))>-1,a.selected!==o&&(a.selected=o);else if(N(Wi(a),r))return void(e.selectedIndex!==s&&(e.selectedIndex=s));i||(e.selectedIndex=-1)}}function qi(e,t){return t.every(function(t){return!N(t,e)})}function Wi(e){return"_value"in e?e._value:e.value}function Zi(e){e.target.composing=!0}function Gi(e){e.target.composing&&(e.target.composing=!1,Xi(e.target,"input"))}function Xi(e,t){var n=document.createEvent("HTMLEvents");n.initEvent(t,!0,!0),e.dispatchEvent(n)}function Yi(e){return!e.componentInstance||e.data&&e.data.transition?e:Yi(e.componentInstance._vnode)}var Qi={model:Vi,show:{bind:function(e,t,n){var r=t.value,i=(n=Yi(n)).data&&n.data.transition,o=e.__vOriginalDisplay="none"===e.style.display?"":e.style.display;r&&i?(n.data.show=!0,Pi(n,function(){e.style.display=o})):e.style.display=r?o:"none"},update:function(e,t,n){var r=t.value;!r!=!t.oldValue&&((n=Yi(n)).data&&n.data.transition?(n.data.show=!0,r?Pi(n,function(){e.style.display=e.__vOriginalDisplay}):Ri(n,function(){e.style.display="none"})):e.style.display=r?e.__vOriginalDisplay:"none")},unbind:function(e,t,n,r,i){i||(e.style.display=e.__vOriginalDisplay)}}},eo={name:String,appear:Boolean,css:Boolean,mode:String,type:String,enterClass:String,leaveClass:String,enterToClass:String,leaveToClass:String,enterActiveClass:String,leaveActiveClass:String,appearClass:String,appearActiveClass:String,appearToClass:String,duration:[Number,String,Object]};function to(e){var t=e&&e.componentOptions;return t&&t.Ctor.options.abstract?to(zt(t.children)):e}function no(e){var t={},n=e.$options;for(var r in n.propsData)t[r]=e[r];var i=n._parentListeners;for(var o in i)t[b(o)]=i[o];return t}function ro(e,t){if(/\d-keep-alive$/.test(t.tag))return e("keep-alive",{props:t.componentOptions.propsData})}var io=function(e){return e.tag||Ut(e)},oo=function(e){return"show"===e.name},ao={name:"transition",props:eo,abstract:!0,render:function(e){var t=this,n=this.$slots.default;if(n&&(n=n.filter(io)).length){var r=this.mode,o=n[0];if(function(e){for(;e=e.parent;)if(e.data.transition)return!0}(this.$vnode))return o;var a=to(o);if(!a)return o;if(this._leaving)return ro(e,o);var s="__transition-"+this._uid+"-";a.key=null==a.key?a.isComment?s+"comment":s+a.tag:i(a.key)?0===String(a.key).indexOf(s)?a.key:s+a.key:a.key;var c=(a.data||(a.data={})).transition=no(this),u=this._vnode,l=to(u);if(a.data.directives&&a.data.directives.some(oo)&&(a.data.show=!0),l&&l.data&&!function(e,t){return t.key===e.key&&t.tag===e.tag}(a,l)&&!Ut(l)&&(!l.componentInstance||!l.componentInstance._vnode.isComment)){var f=l.data.transition=A({},c);if("out-in"===r)return this._leaving=!0,it(f,"afterLeave",function(){t._leaving=!1,t.$forceUpdate()}),ro(e,o);if("in-out"===r){if(Ut(a))return u;var p,d=function(){p()};it(c,"afterEnter",d),it(c,"enterCancelled",d),it(f,"delayLeave",function(e){p=e})}}return o}}},so=A({tag:String,moveClass:String},eo);function co(e){e.elm._moveCb&&e.elm._moveCb(),e.elm._enterCb&&e.elm._enterCb()}function uo(e){e.data.newPos=e.elm.getBoundingClientRect()}function lo(e){var t=e.data.pos,n=e.data.newPos,r=t.left-n.left,i=t.top-n.top;if(r||i){e.data.moved=!0;var o=e.elm.style;o.transform=o.WebkitTransform="translate("+r+"px,"+i+"px)",o.transitionDuration="0s"}}delete so.mode;var fo={Transition:ao,TransitionGroup:{props:so,beforeMount:function(){var e=this,t=this._update;this._update=function(n,r){var i=Zt(e);e.__patch__(e._vnode,e.kept,!1,!0),e._vnode=e.kept,i(),t.call(e,n,r)}},render:function(e){for(var t=this.tag||this.$vnode.data.tag||"span",n=Object.create(null),r=this.prevChildren=this.children,i=this.$slots.default||[],o=this.children=[],a=no(this),s=0;s<i.length;s++){var c=i[s];c.tag&&null!=c.key&&0!==String(c.key).indexOf("__vlist")&&(o.push(c),n[c.key]=c,(c.data||(c.data={})).transition=a)}if(r){for(var u=[],l=[],f=0;f<r.length;f++){var p=r[f];p.data.transition=a,p.data.pos=p.elm.getBoundingClientRect(),n[p.key]?u.push(p):l.push(p)}this.kept=e(t,null,u),this.removed=l}return e(t,null,o)},updated:function(){var e=this.prevChildren,t=this.moveClass||(this.name||"v")+"-move";e.length&&this.hasMove(e[0].elm,t)&&(e.forEach(co),e.forEach(uo),e.forEach(lo),this._reflow=document.body.offsetHeight,e.forEach(function(e){if(e.data.moved){var n=e.elm,r=n.style;Ni(n,t),r.transform=r.WebkitTransform=r.transitionDuration="",n.addEventListener(Ai,n._moveCb=function e(r){r&&r.target!==n||r&&!/transform$/.test(r.propertyName)||(n.removeEventListener(Ai,e),n._moveCb=null,ji(n,t))})}}))},methods:{hasMove:function(e,t){if(!wi)return!1;if(this._hasMove)return this._hasMove;var n=e.cloneNode();e._transitionClasses&&e._transitionClasses.forEach(function(e){_i(n,e)}),gi(n,t),n.style.display="none",this.$el.appendChild(n);var r=Mi(n);return this.$el.removeChild(n),this._hasMove=r.hasTransform}}}};wn.config.mustUseProp=jn,wn.config.isReservedTag=Wn,wn.config.isReservedAttr=En,wn.config.getTagNamespace=Zn,wn.config.isUnknownElement=function(e){if(!z)return!0;if(Wn(e))return!1;if(e=e.toLowerCase(),null!=Gn[e])return Gn[e];var t=document.createElement(e);return e.indexOf("-")>-1?Gn[e]=t.constructor===window.HTMLUnknownElement||t.constructor===window.HTMLElement:Gn[e]=/HTMLUnknownElement/.test(t.toString())},A(wn.options.directives,Qi),A(wn.options.components,fo),wn.prototype.__patch__=z?zi:S,wn.prototype.$mount=function(e,t){return function(e,t,n){var r;return e.$el=t,e.$options.render||(e.$options.render=ve),Yt(e,"beforeMount"),r=function(){e._update(e._render(),n)},new fn(e,r,S,{before:function(){e._isMounted&&!e._isDestroyed&&Yt(e,"beforeUpdate")}},!0),n=!1,null==e.$vnode&&(e._isMounted=!0,Yt(e,"mounted")),e}(this,e=e&&z?Yn(e):void 0,t)},z&&setTimeout(function(){F.devtools&&ne&&ne.emit("init",wn)},0);var po=/\{\{((?:.|\r?\n)+?)\}\}/g,vo=/[-.*+?^${}()|[\]\/\\]/g,ho=g(function(e){var t=e[0].replace(vo,"\\$&"),n=e[1].replace(vo,"\\$&");return new RegExp(t+"((?:.|\\n)+?)"+n,"g")});var mo={staticKeys:["staticClass"],transformNode:function(e,t){t.warn;var n=Fr(e,"class");n&&(e.staticClass=JSON.stringify(n));var r=Ir(e,"class",!1);r&&(e.classBinding=r)},genData:function(e){var t="";return e.staticClass&&(t+="staticClass:"+e.staticClass+","),e.classBinding&&(t+="class:"+e.classBinding+","),t}};var yo,go={staticKeys:["staticStyle"],transformNode:function(e,t){t.warn;var n=Fr(e,"style");n&&(e.staticStyle=JSON.stringify(ai(n)));var r=Ir(e,"style",!1);r&&(e.styleBinding=r)},genData:function(e){var t="";return e.staticStyle&&(t+="staticStyle:"+e.staticStyle+","),e.styleBinding&&(t+="style:("+e.styleBinding+"),"),t}},_o=function(e){return(yo=yo||document.createElement("div")).innerHTML=e,yo.textContent},bo=p("area,base,br,col,embed,frame,hr,img,input,isindex,keygen,link,meta,param,source,track,wbr"),$o=p("colgroup,dd,dt,li,options,p,td,tfoot,th,thead,tr,source"),wo=p("address,article,aside,base,blockquote,body,caption,col,colgroup,dd,details,dialog,div,dl,dt,fieldset,figcaption,figure,footer,form,h1,h2,h3,h4,h5,h6,head,header,hgroup,hr,html,legend,li,menuitem,meta,optgroup,option,param,rp,rt,source,style,summary,tbody,td,tfoot,th,thead,title,tr,track"),Co=/^\s*([^\s"'<>\/=]+)(?:\s*(=)\s*(?:"([^"]*)"+|'([^']*)'+|([^\s"'=<>`]+)))?/,xo=/^\s*((?:v-[\w-]+:|@|:|#)\[[^=]+\][^\s"'<>\/=]*)(?:\s*(=)\s*(?:"([^"]*)"+|'([^']*)'+|([^\s"'=<>`]+)))?/,ko="[a-zA-Z_][\\-\\.0-9_a-zA-Z"+P.source+"]*",Ao="((?:"+ko+"\\:)?"+ko+")",Oo=new RegExp("^<"+Ao),So=/^\s*(\/?)>/,To=new RegExp("^<\\/"+Ao+"[^>]*>"),Eo=/^<!DOCTYPE [^>]+>/i,No=/^<!\--/,jo=/^<!\[/,Do=p("script,style,textarea",!0),Lo={},Mo={"<":"<",">":">",""":'"',"&":"&"," ":"\n","	":"\t","'":"'"},Io=/&(?:lt|gt|quot|amp|#39);/g,Fo=/&(?:lt|gt|quot|amp|#39|#10|#9);/g,Po=p("pre,textarea",!0),Ro=function(e,t){return e&&Po(e)&&"\n"===t[0]};function Ho(e,t){var n=t?Fo:Io;return e.replace(n,function(e){return Mo[e]})}var Bo,Uo,zo,Vo,Ko,Jo,qo,Wo,Zo=/^@|^v-on:/,Go=/^v-|^@|^:|^#/,Xo=/([\s\S]*?)\s+(?:in|of)\s+([\s\S]*)/,Yo=/,([^,\}\]]*)(?:,([^,\}\]]*))?$/,Qo=/^\(|\)$/g,ea=/^\[.*\]$/,ta=/:(.*)$/,na=/^:|^\.|^v-bind:/,ra=/\.[^.\]]+(?=[^\]]*$)/g,ia=/^v-slot(:|$)|^#/,oa=/[\r\n]/,aa=/\s+/g,sa=g(_o),ca="_empty_";function ua(e,t,n){return{type:1,tag:e,attrsList:t,attrsMap:ma(t),rawAttrsMap:{},parent:n,children:[]}}function la(e,t){Bo=t.warn||Sr,Jo=t.isPreTag||T,qo=t.mustUseProp||T,Wo=t.getTagNamespace||T;t.isReservedTag;zo=Tr(t.modules,"transformNode"),Vo=Tr(t.modules,"preTransformNode"),Ko=Tr(t.modules,"postTransformNode"),Uo=t.delimiters;var n,r,i=[],o=!1!==t.preserveWhitespace,a=t.whitespace,s=!1,c=!1;function u(e){if(l(e),s||e.processed||(e=fa(e,t)),i.length||e===n||n.if&&(e.elseif||e.else)&&da(n,{exp:e.elseif,block:e}),r&&!e.forbidden)if(e.elseif||e.else)a=e,(u=function(e){var t=e.length;for(;t--;){if(1===e[t].type)return e[t];e.pop()}}(r.children))&&u.if&&da(u,{exp:a.elseif,block:a});else{if(e.slotScope){var o=e.slotTarget||'"default"';(r.scopedSlots||(r.scopedSlots={}))[o]=e}r.children.push(e),e.parent=r}var a,u;e.children=e.children.filter(function(e){return!e.slotScope}),l(e),e.pre&&(s=!1),Jo(e.tag)&&(c=!1);for(var f=0;f<Ko.length;f++)Ko[f](e,t)}function l(e){if(!c)for(var t;(t=e.children[e.children.length-1])&&3===t.type&&" "===t.text;)e.children.pop()}return function(e,t){for(var n,r,i=[],o=t.expectHTML,a=t.isUnaryTag||T,s=t.canBeLeftOpenTag||T,c=0;e;){if(n=e,r&&Do(r)){var u=0,l=r.toLowerCase(),f=Lo[l]||(Lo[l]=new RegExp("([\\s\\S]*?)(</"+l+"[^>]*>)","i")),p=e.replace(f,function(e,n,r){return u=r.length,Do(l)||"noscript"===l||(n=n.replace(/<!\--([\s\S]*?)-->/g,"$1").replace(/<!\[CDATA\[([\s\S]*?)]]>/g,"$1")),Ro(l,n)&&(n=n.slice(1)),t.chars&&t.chars(n),""});c+=e.length-p.length,e=p,A(l,c-u,c)}else{var d=e.indexOf("<");if(0===d){if(No.test(e)){var v=e.indexOf("--\x3e");if(v>=0){t.shouldKeepComment&&t.comment(e.substring(4,v),c,c+v+3),C(v+3);continue}}if(jo.test(e)){var h=e.indexOf("]>");if(h>=0){C(h+2);continue}}var m=e.match(Eo);if(m){C(m[0].length);continue}var y=e.match(To);if(y){var g=c;C(y[0].length),A(y[1],g,c);continue}var _=x();if(_){k(_),Ro(_.tagName,e)&&C(1);continue}}var b=void 0,$=void 0,w=void 0;if(d>=0){for($=e.slice(d);!(To.test($)||Oo.test($)||No.test($)||jo.test($)||(w=$.indexOf("<",1))<0);)d+=w,$=e.slice(d);b=e.substring(0,d)}d<0&&(b=e),b&&C(b.length),t.chars&&b&&t.chars(b,c-b.length,c)}if(e===n){t.chars&&t.chars(e);break}}function C(t){c+=t,e=e.substring(t)}function x(){var t=e.match(Oo);if(t){var n,r,i={tagName:t[1],attrs:[],start:c};for(C(t[0].length);!(n=e.match(So))&&(r=e.match(xo)||e.match(Co));)r.start=c,C(r[0].length),r.end=c,i.attrs.push(r);if(n)return i.unarySlash=n[1],C(n[0].length),i.end=c,i}}function k(e){var n=e.tagName,c=e.unarySlash;o&&("p"===r&&wo(n)&&A(r),s(n)&&r===n&&A(n));for(var u=a(n)||!!c,l=e.attrs.length,f=new Array(l),p=0;p<l;p++){var d=e.attrs[p],v=d[3]||d[4]||d[5]||"",h="a"===n&&"href"===d[1]?t.shouldDecodeNewlinesForHref:t.shouldDecodeNewlines;f[p]={name:d[1],value:Ho(v,h)}}u||(i.push({tag:n,lowerCasedTag:n.toLowerCase(),attrs:f,start:e.start,end:e.end}),r=n),t.start&&t.start(n,f,u,e.start,e.end)}function A(e,n,o){var a,s;if(null==n&&(n=c),null==o&&(o=c),e)for(s=e.toLowerCase(),a=i.length-1;a>=0&&i[a].lowerCasedTag!==s;a--);else a=0;if(a>=0){for(var u=i.length-1;u>=a;u--)t.end&&t.end(i[u].tag,n,o);i.length=a,r=a&&i[a-1].tag}else"br"===s?t.start&&t.start(e,[],!0,n,o):"p"===s&&(t.start&&t.start(e,[],!1,n,o),t.end&&t.end(e,n,o))}A()}(e,{warn:Bo,expectHTML:t.expectHTML,isUnaryTag:t.isUnaryTag,canBeLeftOpenTag:t.canBeLeftOpenTag,shouldDecodeNewlines:t.shouldDecodeNewlines,shouldDecodeNewlinesForHref:t.shouldDecodeNewlinesForHref,shouldKeepComment:t.comments,outputSourceRange:t.outputSourceRange,start:function(e,o,a,l,f){var p=r&&r.ns||Wo(e);q&&"svg"===p&&(o=function(e){for(var t=[],n=0;n<e.length;n++){var r=e[n];ya.test(r.name)||(r.name=r.name.replace(ga,""),t.push(r))}return t}(o));var d,v=ua(e,o,r);p&&(v.ns=p),"style"!==(d=v).tag&&("script"!==d.tag||d.attrsMap.type&&"text/javascript"!==d.attrsMap.type)||te()||(v.forbidden=!0);for(var h=0;h<Vo.length;h++)v=Vo[h](v,t)||v;s||(!function(e){null!=Fr(e,"v-pre")&&(e.pre=!0)}(v),v.pre&&(s=!0)),Jo(v.tag)&&(c=!0),s?function(e){var t=e.attrsList,n=t.length;if(n)for(var r=e.attrs=new Array(n),i=0;i<n;i++)r[i]={name:t[i].name,value:JSON.stringify(t[i].value)},null!=t[i].start&&(r[i].start=t[i].start,r[i].end=t[i].end);else e.pre||(e.plain=!0)}(v):v.processed||(pa(v),function(e){var t=Fr(e,"v-if");if(t)e.if=t,da(e,{exp:t,block:e});else{null!=Fr(e,"v-else")&&(e.else=!0);var n=Fr(e,"v-else-if");n&&(e.elseif=n)}}(v),function(e){null!=Fr(e,"v-once")&&(e.once=!0)}(v)),n||(n=v),a?u(v):(r=v,i.push(v))},end:function(e,t,n){var o=i[i.length-1];i.length-=1,r=i[i.length-1],u(o)},chars:function(e,t,n){if(r&&(!q||"textarea"!==r.tag||r.attrsMap.placeholder!==e)){var i,u,l,f=r.children;if(e=c||e.trim()?"script"===(i=r).tag||"style"===i.tag?e:sa(e):f.length?a?"condense"===a&&oa.test(e)?"":" ":o?" ":"":"")c||"condense"!==a||(e=e.replace(aa," ")),!s&&" "!==e&&(u=function(e,t){var n=t?ho(t):po;if(n.test(e)){for(var r,i,o,a=[],s=[],c=n.lastIndex=0;r=n.exec(e);){(i=r.index)>c&&(s.push(o=e.slice(c,i)),a.push(JSON.stringify(o)));var u=Ar(r[1].trim());a.push("_s("+u+")"),s.push({"@binding":u}),c=i+r[0].length}return c<e.length&&(s.push(o=e.slice(c)),a.push(JSON.stringify(o))),{expression:a.join("+"),tokens:s}}}(e,Uo))?l={type:2,expression:u.expression,tokens:u.tokens,text:e}:" "===e&&f.length&&" "===f[f.length-1].text||(l={type:3,text:e}),l&&f.push(l)}},comment:function(e,t,n){if(r){var i={type:3,text:e,isComment:!0};r.children.push(i)}}}),n}function fa(e,t){var n,r;(r=Ir(n=e,"key"))&&(n.key=r),e.plain=!e.key&&!e.scopedSlots&&!e.attrsList.length,function(e){var t=Ir(e,"ref");t&&(e.ref=t,e.refInFor=function(e){var t=e;for(;t;){if(void 0!==t.for)return!0;t=t.parent}return!1}(e))}(e),function(e){var t;"template"===e.tag?(t=Fr(e,"scope"),e.slotScope=t||Fr(e,"slot-scope")):(t=Fr(e,"slot-scope"))&&(e.slotScope=t);var n=Ir(e,"slot");n&&(e.slotTarget='""'===n?'"default"':n,e.slotTargetDynamic=!(!e.attrsMap[":slot"]&&!e.attrsMap["v-bind:slot"]),"template"===e.tag||e.slotScope||Nr(e,"slot",n,function(e,t){return e.rawAttrsMap[":"+t]||e.rawAttrsMap["v-bind:"+t]||e.rawAttrsMap[t]}(e,"slot")));if("template"===e.tag){var r=Pr(e,ia);if(r){var i=va(r),o=i.name,a=i.dynamic;e.slotTarget=o,e.slotTargetDynamic=a,e.slotScope=r.value||ca}}else{var s=Pr(e,ia);if(s){var c=e.scopedSlots||(e.scopedSlots={}),u=va(s),l=u.name,f=u.dynamic,p=c[l]=ua("template",[],e);p.slotTarget=l,p.slotTargetDynamic=f,p.children=e.children.filter(function(e){if(!e.slotScope)return e.parent=p,!0}),p.slotScope=s.value||ca,e.children=[],e.plain=!1}}}(e),function(e){"slot"===e.tag&&(e.slotName=Ir(e,"name"))}(e),function(e){var t;(t=Ir(e,"is"))&&(e.component=t);null!=Fr(e,"inline-template")&&(e.inlineTemplate=!0)}(e);for(var i=0;i<zo.length;i++)e=zo[i](e,t)||e;return function(e){var t,n,r,i,o,a,s,c,u=e.attrsList;for(t=0,n=u.length;t<n;t++)if(r=i=u[t].name,o=u[t].value,Go.test(r))if(e.hasBindings=!0,(a=ha(r.replace(Go,"")))&&(r=r.replace(ra,"")),na.test(r))r=r.replace(na,""),o=Ar(o),(c=ea.test(r))&&(r=r.slice(1,-1)),a&&(a.prop&&!c&&"innerHtml"===(r=b(r))&&(r="innerHTML"),a.camel&&!c&&(r=b(r)),a.sync&&(s=Br(o,"$event"),c?Mr(e,'"update:"+('+r+")",s,null,!1,0,u[t],!0):(Mr(e,"update:"+b(r),s,null,!1,0,u[t]),C(r)!==b(r)&&Mr(e,"update:"+C(r),s,null,!1,0,u[t])))),a&&a.prop||!e.component&&qo(e.tag,e.attrsMap.type,r)?Er(e,r,o,u[t],c):Nr(e,r,o,u[t],c);else if(Zo.test(r))r=r.replace(Zo,""),(c=ea.test(r))&&(r=r.slice(1,-1)),Mr(e,r,o,a,!1,0,u[t],c);else{var l=(r=r.replace(Go,"")).match(ta),f=l&&l[1];c=!1,f&&(r=r.slice(0,-(f.length+1)),ea.test(f)&&(f=f.slice(1,-1),c=!0)),Dr(e,r,i,o,f,c,a,u[t])}else Nr(e,r,JSON.stringify(o),u[t]),!e.component&&"muted"===r&&qo(e.tag,e.attrsMap.type,r)&&Er(e,r,"true",u[t])}(e),e}function pa(e){var t;if(t=Fr(e,"v-for")){var n=function(e){var t=e.match(Xo);if(!t)return;var n={};n.for=t[2].trim();var r=t[1].trim().replace(Qo,""),i=r.match(Yo);i?(n.alias=r.replace(Yo,"").trim(),n.iterator1=i[1].trim(),i[2]&&(n.iterator2=i[2].trim())):n.alias=r;return n}(t);n&&A(e,n)}}function da(e,t){e.ifConditions||(e.ifConditions=[]),e.ifConditions.push(t)}function va(e){var t=e.name.replace(ia,"");return t||"#"!==e.name[0]&&(t="default"),ea.test(t)?{name:t.slice(1,-1),dynamic:!0}:{name:'"'+t+'"',dynamic:!1}}function ha(e){var t=e.match(ra);if(t){var n={};return t.forEach(function(e){n[e.slice(1)]=!0}),n}}function ma(e){for(var t={},n=0,r=e.length;n<r;n++)t[e[n].name]=e[n].value;return t}var ya=/^xmlns:NS\d+/,ga=/^NS\d+:/;function _a(e){return ua(e.tag,e.attrsList.slice(),e.parent)}var ba=[mo,go,{preTransformNode:function(e,t){if("input"===e.tag){var n,r=e.attrsMap;if(!r["v-model"])return;if((r[":type"]||r["v-bind:type"])&&(n=Ir(e,"type")),r.type||n||!r["v-bind"]||(n="("+r["v-bind"]+").type"),n){var i=Fr(e,"v-if",!0),o=i?"&&("+i+")":"",a=null!=Fr(e,"v-else",!0),s=Fr(e,"v-else-if",!0),c=_a(e);pa(c),jr(c,"type","checkbox"),fa(c,t),c.processed=!0,c.if="("+n+")==='checkbox'"+o,da(c,{exp:c.if,block:c});var u=_a(e);Fr(u,"v-for",!0),jr(u,"type","radio"),fa(u,t),da(c,{exp:"("+n+")==='radio'"+o,block:u});var l=_a(e);return Fr(l,"v-for",!0),jr(l,":type",n),fa(l,t),da(c,{exp:i,block:l}),a?c.else=!0:s&&(c.elseif=s),c}}}}];var $a,wa,Ca={expectHTML:!0,modules:ba,directives:{model:function(e,t,n){var r=t.value,i=t.modifiers,o=e.tag,a=e.attrsMap.type;if(e.component)return Hr(e,r,i),!1;if("select"===o)!function(e,t,n){var r='var $$selectedVal = Array.prototype.filter.call($event.target.options,function(o){return o.selected}).map(function(o){var val = "_value" in o ? o._value : o.value;return '+(n&&n.number?"_n(val)":"val")+"});";r=r+" "+Br(t,"$event.target.multiple ? $$selectedVal : $$selectedVal[0]"),Mr(e,"change",r,null,!0)}(e,r,i);else if("input"===o&&"checkbox"===a)!function(e,t,n){var r=n&&n.number,i=Ir(e,"value")||"null",o=Ir(e,"true-value")||"true",a=Ir(e,"false-value")||"false";Er(e,"checked","Array.isArray("+t+")?_i("+t+","+i+")>-1"+("true"===o?":("+t+")":":_q("+t+","+o+")")),Mr(e,"change","var $$a="+t+",$$el=$event.target,$$c=$$el.checked?("+o+"):("+a+");if(Array.isArray($$a)){var $$v="+(r?"_n("+i+")":i)+",$$i=_i($$a,$$v);if($$el.checked){$$i<0&&("+Br(t,"$$a.concat([$$v])")+")}else{$$i>-1&&("+Br(t,"$$a.slice(0,$$i).concat($$a.slice($$i+1))")+")}}else{"+Br(t,"$$c")+"}",null,!0)}(e,r,i);else if("input"===o&&"radio"===a)!function(e,t,n){var r=n&&n.number,i=Ir(e,"value")||"null";Er(e,"checked","_q("+t+","+(i=r?"_n("+i+")":i)+")"),Mr(e,"change",Br(t,i),null,!0)}(e,r,i);else if("input"===o||"textarea"===o)!function(e,t,n){var r=e.attrsMap.type,i=n||{},o=i.lazy,a=i.number,s=i.trim,c=!o&&"range"!==r,u=o?"change":"range"===r?Wr:"input",l="$event.target.value";s&&(l="$event.target.value.trim()"),a&&(l="_n("+l+")");var f=Br(t,l);c&&(f="if($event.target.composing)return;"+f),Er(e,"value","("+t+")"),Mr(e,u,f,null,!0),(s||a)&&Mr(e,"blur","$forceUpdate()")}(e,r,i);else if(!F.isReservedTag(o))return Hr(e,r,i),!1;return!0},text:function(e,t){t.value&&Er(e,"textContent","_s("+t.value+")",t)},html:function(e,t){t.value&&Er(e,"innerHTML","_s("+t.value+")",t)}},isPreTag:function(e){return"pre"===e},isUnaryTag:bo,mustUseProp:jn,canBeLeftOpenTag:$o,isReservedTag:Wn,getTagNamespace:Zn,staticKeys:function(e){return e.reduce(function(e,t){return e.concat(t.staticKeys||[])},[]).join(",")}(ba)},xa=g(function(e){return p("type,tag,attrsList,attrsMap,plain,parent,children,attrs,start,end,rawAttrsMap"+(e?","+e:""))});function ka(e,t){e&&($a=xa(t.staticKeys||""),wa=t.isReservedTag||T,function e(t){t.static=function(e){if(2===e.type)return!1;if(3===e.type)return!0;return!(!e.pre&&(e.hasBindings||e.if||e.for||d(e.tag)||!wa(e.tag)||function(e){for(;e.parent;){if("template"!==(e=e.parent).tag)return!1;if(e.for)return!0}return!1}(e)||!Object.keys(e).every($a)))}(t);if(1===t.type){if(!wa(t.tag)&&"slot"!==t.tag&&null==t.attrsMap["inline-template"])return;for(var n=0,r=t.children.length;n<r;n++){var i=t.children[n];e(i),i.static||(t.static=!1)}if(t.ifConditions)for(var o=1,a=t.ifConditions.length;o<a;o++){var s=t.ifConditions[o].block;e(s),s.static||(t.static=!1)}}}(e),function e(t,n){if(1===t.type){if((t.static||t.once)&&(t.staticInFor=n),t.static&&t.children.length&&(1!==t.children.length||3!==t.children[0].type))return void(t.staticRoot=!0);if(t.staticRoot=!1,t.children)for(var r=0,i=t.children.length;r<i;r++)e(t.children[r],n||!!t.for);if(t.ifConditions)for(var o=1,a=t.ifConditions.length;o<a;o++)e(t.ifConditions[o].block,n)}}(e,!1))}var Aa=/^([\w$_]+|\([^)]*?\))\s*=>|^function(?:\s+[\w$]+)?\s*\(/,Oa=/\([^)]*?\);*$/,Sa=/^[A-Za-z_$][\w$]*(?:\.[A-Za-z_$][\w$]*|\['[^']*?']|\["[^"]*?"]|\[\d+]|\[[A-Za-z_$][\w$]*])*$/,Ta={esc:27,tab:9,enter:13,space:32,up:38,left:37,right:39,down:40,delete:[8,46]},Ea={esc:["Esc","Escape"],tab:"Tab",enter:"Enter",space:[" ","Spacebar"],up:["Up","ArrowUp"],left:["Left","ArrowLeft"],right:["Right","ArrowRight"],down:["Down","ArrowDown"],delete:["Backspace","Delete","Del"]},Na=function(e){return"if("+e+")return null;"},ja={stop:"$event.stopPropagation();",prevent:"$event.preventDefault();",self:Na("$event.target !== $event.currentTarget"),ctrl:Na("!$event.ctrlKey"),shift:Na("!$event.shiftKey"),alt:Na("!$event.altKey"),meta:Na("!$event.metaKey"),left:Na("'button' in $event && $event.button !== 0"),middle:Na("'button' in $event && $event.button !== 1"),right:Na("'button' in $event && $event.button !== 2")};function Da(e,t){var n=t?"nativeOn:":"on:",r="",i="";for(var o in e){var a=La(e[o]);e[o]&&e[o].dynamic?i+=o+","+a+",":r+='"'+o+'":'+a+","}return r="{"+r.slice(0,-1)+"}",i?n+"_d("+r+",["+i.slice(0,-1)+"])":n+r}function La(e){if(!e)return"function(){}";if(Array.isArray(e))return"["+e.map(function(e){return La(e)}).join(",")+"]";var t=Sa.test(e.value),n=Aa.test(e.value),r=Sa.test(e.value.replace(Oa,""));if(e.modifiers){var i="",o="",a=[];for(var s in e.modifiers)if(ja[s])o+=ja[s],Ta[s]&&a.push(s);else if("exact"===s){var c=e.modifiers;o+=Na(["ctrl","shift","alt","meta"].filter(function(e){return!c[e]}).map(function(e){return"$event."+e+"Key"}).join("||"))}else a.push(s);return a.length&&(i+=function(e){return"if(!$event.type.indexOf('key')&&"+e.map(Ma).join("&&")+")return null;"}(a)),o&&(i+=o),"function($event){"+i+(t?"return "+e.value+"($event)":n?"return ("+e.value+")($event)":r?"return "+e.value:e.value)+"}"}return t||n?e.value:"function($event){"+(r?"return "+e.value:e.value)+"}"}function Ma(e){var t=parseInt(e,10);if(t)return"$event.keyCode!=="+t;var n=Ta[e],r=Ea[e];return"_k($event.keyCode,"+JSON.stringify(e)+","+JSON.stringify(n)+",$event.key,"+JSON.stringify(r)+")"}var Ia={on:function(e,t){e.wrapListeners=function(e){return"_g("+e+","+t.value+")"}},bind:function(e,t){e.wrapData=function(n){return"_b("+n+",'"+e.tag+"',"+t.value+","+(t.modifiers&&t.modifiers.prop?"true":"false")+(t.modifiers&&t.modifiers.sync?",true":"")+")"}},cloak:S},Fa=function(e){this.options=e,this.warn=e.warn||Sr,this.transforms=Tr(e.modules,"transformCode"),this.dataGenFns=Tr(e.modules,"genData"),this.directives=A(A({},Ia),e.directives);var t=e.isReservedTag||T;this.maybeComponent=function(e){return!!e.component||!t(e.tag)},this.onceId=0,this.staticRenderFns=[],this.pre=!1};function Pa(e,t){var n=new Fa(t);return{render:"with(this){return "+(e?Ra(e,n):'_c("div")')+"}",staticRenderFns:n.staticRenderFns}}function Ra(e,t){if(e.parent&&(e.pre=e.pre||e.parent.pre),e.staticRoot&&!e.staticProcessed)return Ha(e,t);if(e.once&&!e.onceProcessed)return Ba(e,t);if(e.for&&!e.forProcessed)return za(e,t);if(e.if&&!e.ifProcessed)return Ua(e,t);if("template"!==e.tag||e.slotTarget||t.pre){if("slot"===e.tag)return function(e,t){var n=e.slotName||'"default"',r=qa(e,t),i="_t("+n+(r?","+r:""),o=e.attrs||e.dynamicAttrs?Ga((e.attrs||[]).concat(e.dynamicAttrs||[]).map(function(e){return{name:b(e.name),value:e.value,dynamic:e.dynamic}})):null,a=e.attrsMap["v-bind"];!o&&!a||r||(i+=",null");o&&(i+=","+o);a&&(i+=(o?"":",null")+","+a);return i+")"}(e,t);var n;if(e.component)n=function(e,t,n){var r=t.inlineTemplate?null:qa(t,n,!0);return"_c("+e+","+Va(t,n)+(r?","+r:"")+")"}(e.component,e,t);else{var r;(!e.plain||e.pre&&t.maybeComponent(e))&&(r=Va(e,t));var i=e.inlineTemplate?null:qa(e,t,!0);n="_c('"+e.tag+"'"+(r?","+r:"")+(i?","+i:"")+")"}for(var o=0;o<t.transforms.length;o++)n=t.transforms[o](e,n);return n}return qa(e,t)||"void 0"}function Ha(e,t){e.staticProcessed=!0;var n=t.pre;return e.pre&&(t.pre=e.pre),t.staticRenderFns.push("with(this){return "+Ra(e,t)+"}"),t.pre=n,"_m("+(t.staticRenderFns.length-1)+(e.staticInFor?",true":"")+")"}function Ba(e,t){if(e.onceProcessed=!0,e.if&&!e.ifProcessed)return Ua(e,t);if(e.staticInFor){for(var n="",r=e.parent;r;){if(r.for){n=r.key;break}r=r.parent}return n?"_o("+Ra(e,t)+","+t.onceId+++","+n+")":Ra(e,t)}return Ha(e,t)}function Ua(e,t,n,r){return e.ifProcessed=!0,function e(t,n,r,i){if(!t.length)return i||"_e()";var o=t.shift();return o.exp?"("+o.exp+")?"+a(o.block)+":"+e(t,n,r,i):""+a(o.block);function a(e){return r?r(e,n):e.once?Ba(e,n):Ra(e,n)}}(e.ifConditions.slice(),t,n,r)}function za(e,t,n,r){var i=e.for,o=e.alias,a=e.iterator1?","+e.iterator1:"",s=e.iterator2?","+e.iterator2:"";return e.forProcessed=!0,(r||"_l")+"(("+i+"),function("+o+a+s+"){return "+(n||Ra)(e,t)+"})"}function Va(e,t){var n="{",r=function(e,t){var n=e.directives;if(!n)return;var r,i,o,a,s="directives:[",c=!1;for(r=0,i=n.length;r<i;r++){o=n[r],a=!0;var u=t.directives[o.name];u&&(a=!!u(e,o,t.warn)),a&&(c=!0,s+='{name:"'+o.name+'",rawName:"'+o.rawName+'"'+(o.value?",value:("+o.value+"),expression:"+JSON.stringify(o.value):"")+(o.arg?",arg:"+(o.isDynamicArg?o.arg:'"'+o.arg+'"'):"")+(o.modifiers?",modifiers:"+JSON.stringify(o.modifiers):"")+"},")}if(c)return s.slice(0,-1)+"]"}(e,t);r&&(n+=r+","),e.key&&(n+="key:"+e.key+","),e.ref&&(n+="ref:"+e.ref+","),e.refInFor&&(n+="refInFor:true,"),e.pre&&(n+="pre:true,"),e.component&&(n+='tag:"'+e.tag+'",');for(var i=0;i<t.dataGenFns.length;i++)n+=t.dataGenFns[i](e);if(e.attrs&&(n+="attrs:"+Ga(e.attrs)+","),e.props&&(n+="domProps:"+Ga(e.props)+","),e.events&&(n+=Da(e.events,!1)+","),e.nativeEvents&&(n+=Da(e.nativeEvents,!0)+","),e.slotTarget&&!e.slotScope&&(n+="slot:"+e.slotTarget+","),e.scopedSlots&&(n+=function(e,t,n){var r=e.for||Object.keys(t).some(function(e){var n=t[e];return n.slotTargetDynamic||n.if||n.for||Ka(n)}),i=!!e.if;if(!r)for(var o=e.parent;o;){if(o.slotScope&&o.slotScope!==ca||o.for){r=!0;break}o.if&&(i=!0),o=o.parent}var a=Object.keys(t).map(function(e){return Ja(t[e],n)}).join(",");return"scopedSlots:_u(["+a+"]"+(r?",null,true":"")+(!r&&i?",null,false,"+function(e){var t=5381,n=e.length;for(;n;)t=33*t^e.charCodeAt(--n);return t>>>0}(a):"")+")"}(e,e.scopedSlots,t)+","),e.model&&(n+="model:{value:"+e.model.value+",callback:"+e.model.callback+",expression:"+e.model.expression+"},"),e.inlineTemplate){var o=function(e,t){var n=e.children[0];if(n&&1===n.type){var r=Pa(n,t.options);return"inlineTemplate:{render:function(){"+r.render+"},staticRenderFns:["+r.staticRenderFns.map(function(e){return"function(){"+e+"}"}).join(",")+"]}"}}(e,t);o&&(n+=o+",")}return n=n.replace(/,$/,"")+"}",e.dynamicAttrs&&(n="_b("+n+',"'+e.tag+'",'+Ga(e.dynamicAttrs)+")"),e.wrapData&&(n=e.wrapData(n)),e.wrapListeners&&(n=e.wrapListeners(n)),n}function Ka(e){return 1===e.type&&("slot"===e.tag||e.children.some(Ka))}function Ja(e,t){var n=e.attrsMap["slot-scope"];if(e.if&&!e.ifProcessed&&!n)return Ua(e,t,Ja,"null");if(e.for&&!e.forProcessed)return za(e,t,Ja);var r=e.slotScope===ca?"":String(e.slotScope),i="function("+r+"){return "+("template"===e.tag?e.if&&n?"("+e.if+")?"+(qa(e,t)||"undefined")+":undefined":qa(e,t)||"undefined":Ra(e,t))+"}",o=r?"":",proxy:true";return"{key:"+(e.slotTarget||'"default"')+",fn:"+i+o+"}"}function qa(e,t,n,r,i){var o=e.children;if(o.length){var a=o[0];if(1===o.length&&a.for&&"template"!==a.tag&&"slot"!==a.tag){var s=n?t.maybeComponent(a)?",1":",0":"";return""+(r||Ra)(a,t)+s}var c=n?function(e,t){for(var n=0,r=0;r<e.length;r++){var i=e[r];if(1===i.type){if(Wa(i)||i.ifConditions&&i.ifConditions.some(function(e){return Wa(e.block)})){n=2;break}(t(i)||i.ifConditions&&i.ifConditions.some(function(e){return t(e.block)}))&&(n=1)}}return n}(o,t.maybeComponent):0,u=i||Za;return"["+o.map(function(e){return u(e,t)}).join(",")+"]"+(c?","+c:"")}}function Wa(e){return void 0!==e.for||"template"===e.tag||"slot"===e.tag}function Za(e,t){return 1===e.type?Ra(e,t):3===e.type&&e.isComment?(r=e,"_e("+JSON.stringify(r.text)+")"):"_v("+(2===(n=e).type?n.expression:Xa(JSON.stringify(n.text)))+")";var n,r}function Ga(e){for(var t="",n="",r=0;r<e.length;r++){var i=e[r],o=Xa(i.value);i.dynamic?n+=i.name+","+o+",":t+='"'+i.name+'":'+o+","}return t="{"+t.slice(0,-1)+"}",n?"_d("+t+",["+n.slice(0,-1)+"])":t}function Xa(e){return e.replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")}new RegExp("\\b"+"do,if,for,let,new,try,var,case,else,with,await,break,catch,class,const,super,throw,while,yield,delete,export,import,return,switch,default,extends,finally,continue,debugger,function,arguments".split(",").join("\\b|\\b")+"\\b");function Ya(e,t){try{return new Function(e)}catch(n){return t.push({err:n,code:e}),S}}function Qa(e){var t=Object.create(null);return function(n,r,i){(r=A({},r)).warn;delete r.warn;var o=r.delimiters?String(r.delimiters)+n:n;if(t[o])return t[o];var a=e(n,r),s={},c=[];return s.render=Ya(a.render,c),s.staticRenderFns=a.staticRenderFns.map(function(e){return Ya(e,c)}),t[o]=s}}var es,ts,ns=(es=function(e,t){var n=la(e.trim(),t);!1!==t.optimize&&ka(n,t);var r=Pa(n,t);return{ast:n,render:r.render,staticRenderFns:r.staticRenderFns}},function(e){function t(t,n){var r=Object.create(e),i=[],o=[];if(n)for(var a in n.modules&&(r.modules=(e.modules||[]).concat(n.modules)),n.directives&&(r.directives=A(Object.create(e.directives||null),n.directives)),n)"modules"!==a&&"directives"!==a&&(r[a]=n[a]);r.warn=function(e,t,n){(n?o:i).push(e)};var s=es(t.trim(),r);return s.errors=i,s.tips=o,s}return{compile:t,compileToFunctions:Qa(t)}})(Ca),rs=(ns.compile,ns.compileToFunctions);function is(e){return(ts=ts||document.createElement("div")).innerHTML=e?'<a href="\n"/>':'<div a="\n"/>',ts.innerHTML.indexOf(" ")>0}var os=!!z&&is(!1),as=!!z&&is(!0),ss=g(function(e){var t=Yn(e);return t&&t.innerHTML}),cs=wn.prototype.$mount;return wn.prototype.$mount=function(e,t){if((e=e&&Yn(e))===document.body||e===document.documentElement)return this;var n=this.$options;if(!n.render){var r=n.template;if(r)if("string"==typeof r)"#"===r.charAt(0)&&(r=ss(r));else{if(!r.nodeType)return this;r=r.innerHTML}else e&&(r=function(e){if(e.outerHTML)return e.outerHTML;var t=document.createElement("div");return t.appendChild(e.cloneNode(!0)),t.innerHTML}(e));if(r){var i=rs(r,{outputSourceRange:!1,shouldDecodeNewlines:os,shouldDecodeNewlinesForHref:as,delimiters:n.delimiters,comments:n.comments},this),o=i.render,a=i.staticRenderFns;n.render=o,n.staticRenderFns=a}}return cs.call(this,e,t)},wn.compile=rs,wn});
vendor: 1,874 bytes, lines 8362-8369
8362; 8363/* AUTOGENERATED: vuex.min.js */ 8364/*! 8365 * vuex v3.6.2 8366 * (c) 2021 Evan You 8367 * @license MIT 8368 */ 8369!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):(t="undefined"!=typeof globalThis?globalThis:t||self).Vuex=e()}(this,(function(){"use strict";var t=("undefined"!=typeof window?window:"undefined"!=typeof global?global:{}).__VUE_DEVTOOLS_GLOBAL_HOOK__;function e(t,n){if(void 0===n&&(n=[]),null===t||"object"!=typeof t)return t;var o,r=(o=function(e){return e.original===t},n.filter(o)[0]);if(r)return r.copy;var i=Array.isArray(t)?[]:{};return n.push({original:t,copy:i}),Object.keys(t).forEach((function(o){i[o]=e(t[o],n)})),i}function n(t,e){Object.keys(t).forEach((function(n){return e(t[n],n)}))}function o(t){return null!==t&&"object"==typeof t}var r=function(t,e){this.runtime=e,this._children=Object.create(null),this._rawModule=t;var n=t.state;this.state=("function"==typeof n?n():n)||{}},i={namespaced:{configurable:!0}};i.namespaced.get=function(){return!!this._rawModule.namespaced},r.prototype.addChild=function(t,e){this._children[t]=e},r.prototype.removeChild=function(t){delete this._children[t]},r.prototype.getChild=function(t){return this._children[t]},r.prototype.hasChild=function(t){return t in this._children},r.prototype.update=function(t){this._rawModule.namespaced=t.namespaced,t.actions&&(this._rawModule.actions=t.actions),t.mutations&&(this._rawModule.mutations=t.mutations),t.getters&&(this._rawModule.getters=t.getters)},r.prototype.forEachChild=function(t){n(this._children,t)},r.prototype.forEachGetter=function(t){this._rawModule.getters&&n(this._rawModule.getters,t)},r.prototype.forEachAction=function(t){this._rawModule.actions&&n(this._rawModule.actions,t)},r.prototype.forEachMutation=function(t){this._rawModule.mutations&&n(this._rawModule.mutations,t)}
8369,Object.defineProperties(r.prototype,i);var c,a=function(t){this.register([],t,!1)};a.prototype.get=function(t){return t.reduce((function(t,e){return t.getChild(e)}),this.root)},a.prototype.getNamespace=function(t){var e=this.root;return t.reduce((function(t,n){return t+((e=e.getChild(n)).namespaced?n+"/":"")}),"")},a.prototype.update=function(t){!function t(e,n,o){if(n.update(o),o.modules)for(var r in o.modules){if(!n.getChild(r))return;t(e.concat(r),n.getChild(r),o.modules[r])}}([],this.root,t)},a.prototype.register=function(t,e,o){var i=this;void 0===o&&(o=!0);var c=new r(e,o);0===t.length?this.root=c:this.get(t.slice(0,-1)).addChild(t[t.length-1],c);e.modules&&n(e.modules,(function(e,n){i.register(t.concat(n),e,o)}))},a.prototype.unregister=function(t){var e=this.get(t.slice(0,-1)),n=t[t.length-1],o=e.getChild(n);o&&o.runtime&&e.removeChild(n)},a.prototype.isRegistered=function(t){var e=this.get(t.slice(0,-1)),n=t[t.length-1];return!!e&&e.hasChild(n)};var s=function(e){var n=this;void 0===e&&(e={}),!c&&"undefined"!=typeof window&&window.Vue&&v(window.Vue);var o=e.plugins;void 0===o&&(o=[]);var r=e.strict;void 0===r&&(r=!1),this._committing=!1,this._actions=Object.create(null),this._actionSubscribers=[],this._mutations=Object.create(null),this._wrappedGetters=Object.create(null),this._modules=new a(e),this._modulesNamespaceMap=Object.create(null),this._subscribers=[],this._watcherVM=new c,this._makeLocalGettersCache=Object.create(null);var i=this,s=this.dispatch,u=this.commit;this.dispatch=function(t,e){return s.call(i,t,e)},this.commit=function(t,e,n){return u.call(i,t,e,n)},this.strict=r;var f=this._modules.root.state;p(this,f,[],this._modules.root),h(this,f),o.forEach((function(t){return t(n)})),(void 0!==e.devtools?e.devtools:c.config.devtools)&&function(e){t&&(e._devtoolHook=t,t.emit("vuex:init",e),t.on("vuex:travel-to-state",(function(t){e.replaceState(t)})),e.subscribe((function(e,n){t.emit("vuex:mutation",e,n)}),{prepend:!0}),e.subscribeAction((function(e,n){t.emit("vuex:action",e,n)}),{prepend:!0}))}(this)},u={state:{configurable:!0}};function f(t,e,n){return e.indexOf(t)<0&&(n&&n.prepend?e.unshift(t):e.push(t)),function(){var n=e.indexOf(t);n>-1&&e.splice(n,1)}}function l(t,e){t._actions=Object.create(null),t._mutations=Object.create(null),t._wrappedGetters=Object.create(null),t._modulesNamespaceMap=Object.create(null);var n=t.state;p(t,n,[],t._modules.root,!0),h(t,n,e)}function h(t,e,o){var r=t._vm;t.getters={},t._makeLocalGettersCache=Object.create(null);var i=t._wrappedGetters,a={};n(i,(function(e,n){a[n]=function(t,e){return function(){return t(e)}}(e,t),Object.defineProperty(t.getters,n,{get:function(){return t._vm[n]},enumerable:!0})}));var s=c.config.silent;c.config.silent=!0,t._vm=new c({data:{$$state:e},computed:a}),c.config.silent=s,t.strict&&function(t){t._vm.$watch((function(){return this._data.$$state}),(function(){}),{deep:!0,sync:!0})}(t),r&&(o&&t._withCommit((function(){r._data.$$state=null})),c.nextTick((function(){return r.$destroy()})))}function p(t,e,n,o,r){var i=!n.length,a=t._modules.getNamespace(n);if(o.namespaced&&(t._modulesNamespaceMap[a],t._modulesNamespaceMap[a]=o),!i&&!r){var s=d(e,n.slice(0,-1)),u=n[n.length-1];t._withCommit((function(){c.set(s,u,o.state)}))}var f=o.context=function(t,e,n){var o=""===e,r={dispatch:o?t.dispatch:function(n,o,r){var i=m(n,o,r),c=i.payload,a=i.options,s=i.type;return a&&a.root||(s=e+s),t.dispatch(s,c)},commit:o?t.commit:function(n,o,r){var i=m(n,o,r),c=i.payload,a=i.options,s=i.type;a&&a.root||(s=e+s),t.commit(s,c,a)}};return Object.defineProperties(r,{getters:{get:o?function(){return t.getters}:function(){return function(t,e){if(!t._makeLocalGettersCache[e]){var n={},o=e.length;Object.keys(t.getters).forEach((function(r){if(r.slice(0,o)===e){var i=r.slice(o);Object.defineProperty(n,i,{get:function(){return t.getters[r]},enumerable:!0})}})),t._makeLocalGettersCache[e]=n}return t._makeLocalGettersCache[e]}(t,e)}},state:{get:function(){return d(t.state,n)}}}),r}(t,a,n);o.forEachMutation((function(e,n){!function(t,e,n,o){(t._mutations[e]||(t._mutations[e]=[])).push((function(e){n.call(t,o.state,e)}))}(t,a+n,e,f)})),o.forEachAction((function(e,n){var o=e.root?n:a+n,r=e.handler||e;!function(t,e,n,o){(t._actions[e]||(t._actions[e]=[])).push((function(e){var r,i=n.call(t,{dispatch:o.dispatch,commit:o.commit,getters:o.getters,state:o.state,rootGetters:t.getters,rootState:t.state},e);
vendor: 6,352 bytes, lines 8369-8372
8369return(r=i)&&"function"==typeof r.then||(i=Promise.resolve(i)),t._devtoolHook?i.catch((function(e){throw t._devtoolHook.emit("vuex:error",e),e})):i}))}(t,o,r,f)})),o.forEachGetter((function(e,n){!function(t,e,n,o){if(t._wrappedGetters[e])return;t._wrappedGetters[e]=function(t){return n(o.state,o.getters,t.state,t.getters)}}(t,a+n,e,f)})),o.forEachChild((function(o,i){p(t,e,n.concat(i),o,r)}))}function d(t,e){return e.reduce((function(t,e){return t[e]}),t)}function m(t,e,n){return o(t)&&t.type&&(n=e,e=t,t=t.type),{type:t,payload:e,options:n}}function v(t){c&&t===c||function(t){if(Number(t.version.split(".")[0])>=2)t.mixin({beforeCreate:n});else{var e=t.prototype._init;t.prototype._init=function(t){void 0===t&&(t={}),t.init=t.init?[n].concat(t.init):n,e.call(this,t)}}function n(){var t=this.$options;t.store?this.$store="function"==typeof t.store?t.store():t.store:t.parent&&t.parent.$store&&(this.$store=t.parent.$store)}}(c=t)}u.state.get=function(){return this._vm._data.$$state},u.state.set=function(t){},s.prototype.commit=function(t,e,n){var o=this,r=m(t,e,n),i=r.type,c=r.payload,a={type:i,payload:c},s=this._mutations[i];s&&(this._withCommit((function(){s.forEach((function(t){t(c)}))})),this._subscribers.slice().forEach((function(t){return t(a,o.state)})))},s.prototype.dispatch=function(t,e){var n=this,o=m(t,e),r=o.type,i=o.payload,c={type:r,payload:i},a=this._actions[r];if(a){try{this._actionSubscribers.slice().filter((function(t){return t.before})).forEach((function(t){return t.before(c,n.state)}))}catch(t){}var s=a.length>1?Promise.all(a.map((function(t){return t(i)}))):a[0](i);return new Promise((function(t,e){s.then((function(e){try{n._actionSubscribers.filter((function(t){return t.after})).forEach((function(t){return t.after(c,n.state)}))}catch(t){}t(e)}),(function(t){try{n._actionSubscribers.filter((function(t){return t.error})).forEach((function(e){return e.error(c,n.state,t)}))}catch(t){}e(t)}))}))}},s.prototype.subscribe=function(t,e){return f(t,this._subscribers,e)},s.prototype.subscribeAction=function(t,e){return f("function"==typeof t?{before:t}:t,this._actionSubscribers,e)},s.prototype.watch=function(t,e,n){var o=this;return this._watcherVM.$watch((function(){return t(o.state,o.getters)}),e,n)},s.prototype.replaceState=function(t){var e=this;this._withCommit((function(){e._vm._data.$$state=t}))},s.prototype.registerModule=function(t,e,n){void 0===n&&(n={}),"string"==typeof t&&(t=[t]),this._modules.register(t,e),p(this,this.state,t,this._modules.get(t),n.preserveState),h(this,this.state)},s.prototype.unregisterModule=function(t){var e=this;"string"==typeof t&&(t=[t]),this._modules.unregister(t),this._withCommit((function(){var n=d(e.state,t.slice(0,-1));c.delete(n,t[t.length-1])})),l(this)},s.prototype.hasModule=function(t){return"string"==typeof t&&(t=[t]),this._modules.isRegistered(t)},s.prototype.hotUpdate=function(t){this._modules.update(t),l(this,!0)},s.prototype._withCommit=function(t){var e=this._committing;this._committing=!0,t(),this._committing=e},Object.defineProperties(s.prototype,u);var g=M((function(t,e){var n={};return w(e).forEach((function(e){var o=e.key,r=e.val;n[o]=function(){var e=this.$store.state,n=this.$store.getters;if(t){var o=$(this.$store,"mapState",t);if(!o)return;e=o.context.state,n=o.context.getters}return"function"==typeof r?r.call(this,e,n):e[r]},n[o].vuex=!0})),n})),y=M((function(t,e){var n={};return w(e).forEach((function(e){var o=e.key,r=e.val;n[o]=function(){for(var e=[],n=arguments.length;n--;)e[n]=arguments[n];var o=this.$store.commit;if(t){var i=$(this.$store,"mapMutations",t);if(!i)return;o=i.context.commit}return"function"==typeof r?r.apply(this,[o].concat(e)):o.apply(this.$store,[r].concat(e))}})),n})),_=M((function(t,e){var n={};return w(e).forEach((function(e){var o=e.key,r=e.val;r=t+r,n[o]=function(){if(!t||$(this.$store,"mapGetters",t))return this.$store.getters[r]},n[o].vuex=!0})),n})),b=M((function(t,e){var n={};return w(e).forEach((function(e){var o=e.key,r=e.val;n[o]=function(){for(var e=[],n=arguments.length;n--;)e[n]=arguments[n];var o=this.$store.dispatch;if(t){var i=$(this.$store,"mapActions",t);if(!i)return;o=i.context.dispatch}return"function"==typeof r?r.apply(this,[o].concat(e)):o.apply(this.$store,[r].concat(e))}})),n}));function w(t){return function(t){return Array.isArray(t)||o(t)}(t)?Array.isArray(t)?t.map((function(t){return{key:t,val:t}})):Object.keys(t).map((function(e){return{key:e,val:t[e]}})):[]}function M(t){return function(e,n){return"string"!=typeof e?(n=e,e=""):"/"!==e.charAt(e.length-1)&&(e+="/"),t(e,n)}}function $(t,e,n){return t._modulesNamespaceMap[n]}function C(t,e,n){var o=n?t.groupCollapsed:t.group;try{o.call(t,e)}catch(n){t.log(e)}}function E(t){try{t.groupEnd()}catch(e){t.log("ââ log end ââ")}}function O(){var t=new Date;return" @ "+j(t.getHours(),2)+":"+j(t.getMinutes(),2)+":"+j(t.getSeconds(),2)+"."+j(t.getMilliseconds(),3)}function j(t,e){return n="0",o=e-t.toString().length,new Array(o+1).join(n)+t;var n,o}return{Store:s,install:v,version:"3.6.2",mapState:g,mapMutations:y,mapGetters:_,mapActions:b,createNamespacedHelpers:function(t){return{mapState:g.bind(null,t),mapGetters:_.bind(null,t),mapMutations:y.bind(null,t),mapActions:b.bind(null,t)}},createLogger:function(t){void 0===t&&(t={});var n=t.collapsed;void 0===n&&(n=!0);var o=t.filter;void 0===o&&(o=function(t,e,n){return!0});var r=t.transformer;void 0===r&&(r=function(t){return t});var i=t.mutationTransformer;void 0===i&&(i=function(t){return t});var c=t.actionFilter;void 0===c&&(c=function(t,e){return!0});var a=t.actionTransformer;void 0===a&&(a=function(t){return t});var s=t.logMutations;void 0===s&&(s=!0);var u=t.logActions;void 0===u&&(u=!0);var f=t.logger;return void 0===f&&(f=console),function(t){var l=e(t.state);void 0!==f&&(s&&t.subscribe((function(t,c){var a=e(c);if(o(t,l,a)){var s=O(),u=i(t),h="mutation "+t.type+s;C(f,h,n),f.log("%c prev state","color: #9E9E9E; font-weight: bold",r(l)),f.log("%c mutation","color: #03A9F4; font-weight: bold",u),f.log("%c next state","color: #4CAF50; font-weight: bold",r(a)),E(f)}l=a})),u&&t.subscribeAction((function(t,e){if(c(t,e)){var o=O(),r=a(t),i="action "+t.type+o;C(f,i,n),f.log("%c action","color: #03A9F4; font-weight: bold",r),E(f)}})))}}}}));; 8370/* AUTOGENERATED: vue.loadable.js */ 8371(function () { 8372 var initialCompiled = false;
8373 8374 var cache = {}; 8375 8376 var VueLoadableMixin = { 8377 created: function () { 8378 // TODO: This code is unreliable since it's not a part of the public API 8379 Vue.util.defineReactive(this, '$reloading', false); 8380 }, 8381 8382 beforeMount: function () { 8383 if (this.$options.loadable && this.$options.loadable.loadOnCompile && !initialCompiled) { 8384 this.$reload(); 8385 initialCompiled = true; 8386 } 8387 }, 8388 8389 methods: { 8390 $reload: function () { 8391 var loader = this.$options.loadable.loader; 8392 8393 if (loader) { 8394 this.$reloading = true; 8395 var promise; 8396 8397 if (this.$options.loadable.cacheSimultaneous) { 8398 if (!_.has(cache, this._getCacheKey())) { 8399 cache[this._getCacheKey()] = loader.call(this, arguments); 8400 } 8401 promise = cache[this._getCacheKey()]; 8402 } else { 8403 promise = loader.call(this, arguments); 8404 } 8405 8406 if (promise && typeof promise.then === 'function') { 8407 promise.then(this._resolve, this._reject); 8408 } 8409 } 8410 }, 8411 8412 _getCacheKey: function() { 8413 return _.isFunction(this.$options.loadable.cacheKey) 8414 ? this.$options.loadable.cacheKey.apply(this) 8415 : this.$options.name; 8416 }, 8417 8418 _resolve: function (data) { 8419 var uuid = _.uniqueId(); 8420 var self = this; 8421 8422 xcart.bind(['resources.ready', 'resources.empty'], _.bind( 8423 function (event, args) { 8424 if (args.uuid === uuid) { 8425 if (this.$options.loadable.transferState) { 8426 var oldData = JSON.parse(JSON.stringify(this.$data)); 8427 } 8428 8429 if (this.$options.loadable.update !== false) { 8430 this._updateComponent(data); 8431 } 8432 8433 if (this.$options.loadable.transferState) { 8434 // TODO: doesn't work 8435 this.$data = oldData; 8436 } 8437 8438 this.$reloading = false; 8439 8440 if ('function' === typeof(this.$options.loadable.resolve)) { 8441 this.$options.loadable.resolve.apply(this, [data]); 8442 } 8443 8444 delete cache[this._getCacheKey()]; 8445 } 8446 }, 8447 this) 8448 ); 8449 8450 xcart.parsePreloadedLabels(data, uuid); 8451 xcart.parseResources(data, uuid); 8452 }, 8453 8454 _reject: function (data) { 8455 this.$reloading = false; 8456 if ('function' === typeof(this.$options.loadable.reject)) { 8457 this.$options.loadable.reject.apply(this, [data]); 8458 } 8459 8460 delete cache[this._getCacheKey()]; 8461 }, 8462 8463 _updateComponent: function (html) { 8464 var element = this._parseTemplate(html); 8465 // Disable optimization to avoid static roots are not refreshing 8466 this.$options.render = Vue.compile(element.outerHTML, {optimize: false}).render; 8467 8468 var update = typeof(this.$options.loadable.update) === 'function' 8469 ? this.$options.loadable.update(this) 8470 : this.$options.loadable.update; 8471 8472 // Force "initial render" instead of old vnode update (see Vue.prototype._update implementation) 8473 if (update === true) { 8474 this._vnode = null; 8475 } 8476 8477 this._update(this._render(), false); 8478 }, 8479 8480 _parseTemplate: function (html) { 8481 var element; 8482 8483 if (this.$options.loadable.parser) { 8484 element = this.$options.loadable.parser.apply(this, [html]); 8485 } else { 8486 var temp = document.createElement('div'); 8487 temp.innerHTML = html; 8488 8489 element = temp.querySelector('[is=' + this.$options._componentTag + '] > *'); 8490 if (!element) { 8491 element = temp.querySelector(this.$options._componentTag + ' > *'); 8492 } 8493 } 8494 8495 return element; 8496 } 8497 } 8498 } 8499 8500 if (typeof exports === 'object' && typeof module === 'object') { 8501 module.exports = VueLoadableMixin 8502 } else if(typeof define === 'function' && define.amd) { 8503 define(function () { return VueLoadableMixin }) 8504 } else if (typeof window !== 'undefined') { 8505 window.VueLoadableMixin = VueLoadableMixin 8506 } 8507})(); 8508 8509define('vue/vue.loadable', function () { return VueLoadableMixin; });; 8510/* AUTOGENERATED: vue.registerComponent.js */ 8511(function () { 8512 function install (Vue) { 8513 Vue.registerComponent = function (parent, child, name) { 8514 name = name || child.options.name; 8515 if (typeof(parent) === 'function' && typeof(child) === 'function') { 8516 var record = {}; 8517 record[name] = child; 8518 parent = parent.extend({ 8519 components: _.extend(parent.options.components, record) 8520 }); 8521 } else { 8522 console.groupCollapsed("[vue.registerComponent] error");
8523 console.error('Given argument is not a object constructor'); 8524 console.error(arguments); 8525 console.groupEnd(); 8526 } 8527 } 8528 } 8529 8530 if (typeof exports == "object") { 8531 module.exports = install 8532 } else if (typeof define == "function" && define.amd) { 8533 define([], function(){ return install }) 8534 } else if (window.Vue) { 8535 Vue.use(install) 8536 } 8537})();; 8538/* AUTOGENERATED: vue.js */ 8539/* vim: set ts=2 sw=2 sts=2 et: */ 8540 8541/** 8542 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 8543 * See https://www.x-cart.com/license-agreement.html for license details. 8544 */ 8545 8546define('vue/vue', function () { return Vue; }); 8547 8548if ('undefined' !== typeof(Vuex)) { 8549 Vue.use(Vuex); 8550 define('vue/vuex', function () { return Vuex; }); 8551} 8552 8553define('js/vue/vue', ['vue/vue', 'vue/eventbus', 'js/vue/component'], function (Vue, EventBus, XLiteVueComponent) { 8554 Vue.getClosestVueInstance = function (el) { 8555 var _getClosestVueInstance = function (element) { 8556 if (element) { 8557 return element.__vue__ || _getClosestVueInstance(element.parentElement); 8558 } 8559 } 8560 8561 return _getClosestVueInstance(el); 8562 }; 8563 8564 Vue.directive('data', { 8565 inserted: function (el, binding) { 8566 var vm = Vue.getClosestVueInstance(el); 8567 8568 if (!vm) { 8569 return; 8570 } 8571 8572 var object = binding.value; 8573 for (var key in object) { 8574 var parts = key.replace('[','.').replace(']','').split('.'); 8575 var path = ''; 8576 8577 parts.forEach(function (part) { 8578 if (path) { 8579 path = isNaN(part)
8580 ? path.concat('.' + part) 8581 : path.concat('[' + part + ']'); 8582 } else { 8583 path = part; 8584 } 8585 8586 // TODO: doesn't work since we don't have this/self and $get method anymore 8587 /*if (_.isUndefined(self.vm.$get(path))) { 8588 self.vm.$set(path, {}); 8589 }*/ 8590 }); 8591 8592 if (vm[key] !== undefined) { 8593 vm[key] = object[key]; 8594 } 8595 } 8596 }, 8597 8598 // for loadable components only 8599 update: function (el, binding) { 8600 var vm = Vue.getClosestVueInstance(el); 8601 8602 if (!vm || vm.$options.loadable === undefined) { 8603 return; 8604 } 8605 8606 var object = binding.value; 8607 for (var key in object) { 8608 if (vm.$options.loadable.ignoreUpdates && _.contains(vm.$options.loadable.ignoreUpdates, key)) { 8609 continue; 8610 } 8611 8612 if (vm[key] !== undefined && !_.isEqual(vm[key], object[key])) { 8613 vm[key] = object[key]; 8614 } 8615 } 8616 } 8617 }); 8618 8619 function XLiteVue() { 8620 this.root = null; 8621 } 8622 8623 XLiteVue.prototype.components = {}; 8624 8625 XLiteVue.prototype.start = function (element) { 8626 for (var componentName in this.components) if (this.components.hasOwnProperty(componentName)) { 8627 Vue.component(componentName, this.components[componentName].definition) 8628 } 8629 8630 if (_.isEmpty(this.components)) { 8631 return; 8632 } 8633 8634 var elementToInit = element || '#page-wrapper'; 8635 8636 if (element instanceof jQuery && element.length > 0) { 8637 elementToInit = element.get(0); 8638 } 8639 8640 this.root = new Vue({el: elementToInit}); 8641 8642 Vue.nextTick(function () { 8643 typeof CommonForm !== 'undefined' && CommonForm.autoload(); 8644 typeof StickyPanel !== 'undefined' && StickyPanel.reload(); 8645 xcart.microhandlers.runInitial(); 8646 }); 8647 }; 8648 8649 XLiteVue.prototype.component = function (name, definition) { 8650 if (this.components[name]) { 8651 this.components[name].extend(definition); 8652 } else { 8653 this.components[name] = new XLiteVueComponent(name, definition); 8654 } 8655 8656 return this.components[name].definition; 8657 }; 8658 8659 Vue.prototype.$dispatch = function (event) { 8660 EventBus.$emit.apply(EventBus, arguments); 8661 }; 8662 8663 Vue.prototype.$broadcast = function (event) { 8664 EventBus.$emit.apply(EventBus, arguments); 8665 }; 8666 8667 Vue.mixin({ 8668 created: function () { 8669 if (typeof this.$options.events !== 'undefined') { 8670 var self = this; 8671 for (var eventName in this.$options.events) { 8672 if (this.$options.events.hasOwnProperty(eventName)) { 8673 (function (_eventName) { 8674 EventBus.$on(_eventName, _.bind(function () { 8675 this.$options.events[_eventName].apply(this, arguments); 8676 }, self)); 8677 })(eventName); 8678 } 8679 } 8680 } 8681 }, 8682 8683 mounted: function () { 8684 if (typeof this.$options.ready !== 'undefined') { 8685 this.$nextTick(function () { 8686 this.$options.ready.call(this); 8687 }); 8688 } 8689 }, 8690 }) 8691 8692 return new XLiteVue(); 8693}); 8694 8695jQuery(document).ready(function () { 8696 define('xlite_vue_model_start', ['js/vue/vue', 'ready'], function (XLiteVue) { 8697 if ('admin' === xliteConfig.zone) { 8698 XLiteVue.start(); 8699 } 8700 }); 8701});; 8702/* AUTOGENERATED: component.js */ 8703/* vim: set ts=2 sw=2 sts=2 et: */ 8704 8705/** 8706 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 8707 * See https://www.x-cart.com/license-agreement.html for license details. 8708 */ 8709 8710define('js/vue/component', ['js/underscore', 'vue/vue'], function (_, Vue) { 8711 8712 var XLiteVueComponent = function (name, definition) { 8713 this.name = name; 8714 this.definition = Vue.extend(definition); 8715 }; 8716 8717 XLiteVueComponent.prototype.extend = function (definition) { 8718 this.definition = this.definition.extend(definition); 8719 this._provideParentMethods(); 8720 }; 8721 8722 XLiteVueComponent.prototype._provideParentMethods = function () { 8723 var methods = this.definition.options.methods; 8724 var parent = this.definition.super.options.methods; 8725 8726 for (var methodName in methods) if ('undefined' === typeof(methods.hasOwnProperty) || methods.hasOwnProperty(methodName)) { 8727 if (parent[methodName]) { 8728 methods[methodName].parent = parent[methodName]; 8729 } 8730 } 8731 }; 8732 8733 return XLiteVueComponent; 8734});;
8735/* AUTOGENERATED: event_bus.js */ 8736/* vim: set ts=2 sw=2 sts=2 et: */ 8737 8738/** 8739 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 8740 * See https://www.x-cart.com/license-agreement.html for license details. 8741 */ 8742 8743define('vue/eventbus', ['vue/vue'], function (Vue) { 8744 return new Vue(); 8745});; 8746/* AUTOGENERATED: xcart.popup.js */ 8747/* vim: set ts=2 sw=2 sts=2 et: */ 8748 8749/** 8750 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 8751 * See https://www.x-cart.com/license-agreement.html for license details. 8752 */ 8753 8754var popup = {}; 8755 8756/** 8757 * Properties 8758 */ 8759 8760// Loading status 8761popup.isLoading = false; 8762 8763// Request type status - POST or GET 8764popup.isPostRequest = false; 8765 8766// Current unblock event handler 8767popup.currentUnblockCallback = null; 8768 8769// Current popup 8770popup.currentPopup = null; 8771 8772// Load options 8773popup.loadOptions = null; 8774 8775// Do not do real close popup in popup.close() 8776// popup.pseudoClose = false; 8777 8778/** 8779 * Methods 8780 */ 8781 8782// Load data to popup 8783popup.load = function(url, unblockCallback, timeout) 8784{ 8785 if (_.isObject(unblockCallback) && !_.isFunction(unblockCallback)) { 8786 var options = unblockCallback; 8787 options.unblockCallback = 'undefined' == typeof(options.unblockCallback) ? null : options.unblockCallback; 8788 options.timeout = timeout || null; 8789 8790 } else { 8791 var options = { 8792 'unblockCallback': unblockCallback, 8793 'timeout': timeout 8794 }; 8795 } 8796 8797 this.loadOptions = options; 8798 8799 var result = false;
8800 if (xcart.isRequesterEnabled) { 8801 var method = null; 8802 8803 if (_.isObject(url) && !_.isElement(url)) { 8804 url = url.get(0); 8805 } 8806 8807 if (url.constructor == String) { 8808 method = 'loadByURL'; 8809 8810 } else if (url.constructor == HTMLFormElement) { 8811 method = 'loadByForm'; 8812 8813 } else if (url.constructor == HTMLAnchorElement) { 8814 method = 'loadByLink'; 8815 8816 } else if (url.constructor == HTMLButtonElement) { 8817 method = 'loadByButton'; 8818 8819 } 8820 8821 if (method) { 8822 this.isLoading = true; 8823 this.currentUnblockCallback = options.unblockCallback; 8824 8825 if (this.currentPopup) { 8826 // Reload popup content only 8827 this.shade(); 8828 } else { 8829 // Open waiting dialog 8830 this.openAsWait(); 8831 } 8832 8833 this.isPostRequest = false; 8834 result = this[method](url, options.timeout); 8835 } 8836 } 8837 8838 return result; 8839}; 8840 8841// Load by URL 8842popup.loadByURL = function(url, timeout) 8843{ 8844 return xcart.get( 8845 this.preprocessURL(url), 8846 _.bind(this.postprocessRequest, this), 8847 null, 8848 { 8849 timeout: timeout 8850 } 8851 ); 8852}; 8853 8854// Load by form element 8855popup.loadByForm = function(form) 8856{ 8857 form = jQuery(form).get(0); 8858 8859 form.setAttribute('action', this.preprocessURL(form.getAttribute('action'))); 8860 8861 return form ? form.submitBackground(_.bind(this.postprocessRequest, this)) : false; 8862}; 8863 8864// Load by link element 8865popup.loadByLink = function(link) 8866{ 8867 link = jQuery(link).eq(0); 8868 8869 var href = (1 == link.length && link.attr('href')) ? link.attr('href') : false; 8870 8871 return href 8872 ? xcart.get(this.preprocessURL(href), _.bind(this.postprocessRequest, this)) 8873 : false; 8874}; 8875 8876// Load by button element 8877popup.loadByButton = function(button) 8878{ 8879 var result = false;
8880 8881 button = jQuery(button); 8882 8883 if (button.attr('onclick') && -1 !== button.attr('onclick').toString().search(/\.location[ ]*=[ ]*['"].+['"]/)) { 8884 8885 // By onclick attribute 8886 var m = button.attr('onclick').toString().match(/\.location[ ]*=[ ]*['"](.+)['"]/); 8887 result = xcart.get(this.preprocessURL(m[1]), _.bind(this.postprocessRequest, this)); 8888 8889 } else if (button.data('location')) { 8890 8891 // By kQuery data cell 8892 result = xcart.get(this.preprocessURL(button.data('location')), _.bind(this.postprocessRequest, this)); 8893 8894 } else if (0 < button.parents('form').length) { 8895 8896 // By button's form 8897 result = this.loadByForm(jQuery(button).parents('form').eq(0)); 8898 8899 } 8900 8901 return result; 8902}; 8903 8904// Preprocess URL 8905popup.preprocessURL = function(url) 8906{ 8907 if (url && -1 == url.search(/only_center=1/)) { 8908 url += (-1 == url.search(/\?/) ? '?' : '&') + 'only_center=1'; 8909 } 8910 8911 return url; 8912}; 8913 8914// Postprocess request 8915popup.postprocessRequest = function(XMLHttpRequest, textStatus, data, isValid) 8916{ 8917 if (XMLHttpRequest && XMLHttpRequest instanceof jQuery.Event && textStatus) { 8918 var event = XMLHttpRequest; 8919 XMLHttpRequest = textStatus.XMLHttpRequest; 8920 data = textStatus.data; 8921 isValid = textStatus.isValid; 8922 textStatus = textStatus.textStatus; 8923 } 8924 8925 var responseStatus = 4 == XMLHttpRequest.readyState ? parseInt(XMLHttpRequest.getResponseHeader('ajax-response-status')) : 0; 8926 8927 if (4 != XMLHttpRequest.readyState) { 8928 8929 // Connection failed 8930 this.destroy(); 8931 // TODO - add top message 8932 8933 } else if (278 == responseStatus) { 8934 8935 // Redirect 8936 this.destroy(); 8937 var url = XMLHttpRequest.getResponseHeader('AJAX-Location'); 8938 if (url) { 8939 self.location = url; 8940 8941 } else { 8942 self.location.reload(true); 8943 } 8944 8945 } else if (279 == responseStatus) { 8946 8947 // Internal redirect 8948 var url = XMLHttpRequest.getResponseHeader('AJAX-Location'); 8949 if (url) { 8950 this.load(url, this.currentUnblockCallback); 8951 8952 } else { 8953 self.location.reload(true); 8954 } 8955 8956 } else if (277 == responseStatus) { 8957 8958 // Close popup in silence 8959 this.close(); 8960 8961 } else if (200 == XMLHttpRequest.status) { 8962 8963 // Load new content 8964 this.unshade(); 8965 8966 var uuid = _.uniqueId(); 8967 8968 if (data) { 8969 xcart.bind(['resources.ready', 'resources.empty'], _.bind( 8970 function(event, args){ 8971 if (args.uuid === uuid) { 8972 this.place(data, this.loadOptions); 8973 xcart.trigger( 8974 'afterPopupPlace', 8975 { 8976 'XMLHttpRequest': XMLHttpRequest, 8977 'textStatus': textStatus, 8978 'data': data, 8979 'isValid': isValid 8980 } 8981 ); 8982 } 8983 }, 8984 this) 8985 ); 8986 8987 xcart.parsePreloadedLabels(jQuery.parseHTML(data), uuid); 8988 xcart.parseResources(jQuery.parseHTML(data), uuid); 8989 8990 } else { 8991 this.unfreezePopup(); 8992 } 8993 8994 } else { 8995 8996 // Loading failed 8997 this.close(); 8998 8999 } 9000}; 9001 9002// Place request data 9003popup.place = function(data, options) 9004{ 9005 this.isLoading = false; 9006 9007 if (false !== data) { 9008 data = this.extractRequestData(data); 9009 this.assignHandlers(data); 9010 this.open(data, options); 9011 } 9012}; 9013 9014// Extract widget data 9015popup.extractRequestData = function(data) 9016{ 9017 return jQuery(data); 9018}; 9019 9020popup.assignHandlers = function(data) 9021{ 9022 // Do not need this assignment since the microhandlers would be run after the popup placement 9023 // xcart.microhandlers.runAll(data); 9024}; 9025 9026popup.shade = function() 9027{ 9028 this.currentPopup.widget.find('.ui-dialog-content') 9029 .append('<div class="wait-overlay"><div class="wait-overlay-progress"><div></div></div></div>'); 9030}; 9031 9032popup.unshade = function() 9033{ 9034 if (this.currentPopup) { 9035 this.currentPopup.widget.find('.wait-overlay').remove(); 9036 } 9037}; 9038 9039// Popup post processing 9040popup.postprocess = function() 9041{ 9042 // If for some cases you need direct submit of the form (inside the popup widget) 9043 // then provide the form with the "no-popup-ajax-submit" CSS class 9044 this.currentPopup.widget 9045 .find('form') 9046 .not('.no-popup-ajax-submit') 9047 .commonController(
9048 'enableBackgroundSubmit', 9049 _.bind(this.freezePopup, this), 9050 _.bind(this.postprocessRequest, this) 9051 ); 9052 9053 xcart.microhandlers.runAll(this.currentPopup.widget); 9054 9055 if (!this.isLoading) { 9056 xcart.trigger('popup.postprocess', { widget: this }); 9057 } 9058}; 9059 9060// Freeze popup content 9061popup.freezePopup = function() 9062{ 9063 if (this.currentPopup) { 9064 this.currentPopup.widget.find('form').each( 9065 function() { 9066 jQuery('button,input:image,input:submit', this).each( 9067 function() { 9068 if (!this.disabled) { 9069 this.temporaryDisabled = true; 9070 jQuery(this).prop('disabled', 'disabled'); 9071 } 9072 } 9073 ); 9074 } 9075 ); 9076 9077 this.shade(); 9078 } 9079}; 9080 9081// Unfreeze popup content 9082popup.unfreezePopup = function() 9083{ 9084 if (this.currentPopup) { 9085 this.currentPopup.widget.find('form').each( 9086 function() { 9087 jQuery('button,input:image,input:submit', this).each( 9088 function() { 9089 if (this.temporaryDisabled) { 9090 jQuery(this).removeAttr('disabled'); 9091 this.temporaryDisabled = true; 9092 } 9093 } 9094 ); 9095 } 9096 ); 9097 } 9098}; 9099 9100// Open as wait box 9101popup.openAsWait = function() 9102{ 9103 this.isLoading = true; 9104 this.open(jQuery('<div data-dialog-class="block-wait-box"><div class="block-wait"><div></div></div></div>')); 9105}; 9106 9107// Open-n-display popup 9108popup.open = function(box, additionalOptions) 9109{ 9110 additionalOptions = additionalOptions || {}; 9111 9112 if (this.currentPopup) { 9113 this.destroy(); 9114 } 9115 9116 if (box && _.isString(box)) { 9117 box = jQuery('<div></div>') 9118 .html(box); 9119 } 9120 9121 box = jQuery(box); 9122 if (box.attr('title')) { 9123 box.data('title', box.attr('title')); 9124 additionalOptions.title = box.data('title'); 9125 9126 } else if (box.data('title')) { 9127 box.attr('title', box.data('title')); 9128 additionalOptions.title = box.data('title'); 9129 } 9130 9131 box.dialog( 9132 this.extendOptions(this.getPopupOptions(box), additionalOptions) 9133 ); 9134 9135 this.currentPopup = { 9136 'box': box, 9137 'widget': jQuery(box).dialog('widget') 9138 }; 9139 9140 9141 this.postprocess(); 9142 this.reposition(); 9143}; 9144 9145popup.getPopupOptions = function(box) 9146{ 9147 return { 9148 autoOpen: true, 9149 closeOnEscape: !box.data('dialog-no-close'), 9150 dialogClass: (box.data('dialog-class') ? box.data('dialog-class') : 'default-dialog') 9151 + ' ' + (box.attr('title') ? 'has-title' : 'no-title') + (box.data('dialog-no-close') ? ' no-close' : ''), 9152 draggable: false, 9153 height: 'auto', 9154 modal: (typeof(box.data('dialog-modal')) !== 'undefined' ? box.data('dialog-modal') : true), 9155 position: { my: "center", at: "center", of: window }, 9156 resizable: false, 9157 width: 'auto', 9158 minWidth: 300, 9159 minHeight: 150, 9160 9161 open: _.bind( 9162 function(event, ui) { 9163 jQuery('.overlay-blur-base').addClass('overlay-blur'); 9164 xcart.trigger('popup.open', { widget: this, event }); 9165 }, 9166 this 9167 ), 9168 close: _.bind( 9169 function(event, ui) { 9170 jQuery('.overlay-blur-base').removeClass('overlay-blur'); 9171 this.currentPopup.widget.find('form').each( 9172 function (index, elem) { 9173 jQuery(elem).validationEngine('hide'); 9174 } 9175 ); 9176 9177 this.close(event); 9178 }, 9179 this 9180 ), 9181 9182 beforeClose: _.bind(this.beforeClose, this) 9183 }; 9184}; 9185 9186popup.extendOptions = function(first, second) 9187{ 9188 _.each( 9189 ['dialogClass'], 9190 function (key) { 9191 if (_.isString(first[key]) && _.isString(second[key])) { 9192 first[key] += ' ' + second[key]; 9193 delete second[key]; 9194 } 9195 } 9196 ); 9197 9198 return _.extend(first, second); 9199}; 9200 9201// Reposition (center) popup 9202popup.reposition = function() 9203{ 9204 if (!this.currentPopup) { 9205 return; 9206 } 9207 9208 const box = this.currentPopup.box 9209 9210 if (box.length) { 9211 const self = this; 9212 setTimeout( 9213 function() { 9214 const widgetHeight = self.currentPopup.widget.outerHeight(true); 9215 const windowHeight = $(window).height(); 9216 9217 window.stickyElementsForPopup = { 9218 top: null, 9219 sizes: { 9220 top: 0, 9221 left: 0 9222 } 9223 }; 9224 9225 /** window.stickyElementsForPopup is expected to change in the event listeners. **/ 9226 window.dispatchEvent(new CustomEvent('updateStickyElementsForPopup')); 9227
9228 const atHorizontal = ("center+".concat(Math.round(window.stickyElementsForPopup.sizes.left / 2).toString())); 9229 9230 if (widgetHeight < windowHeight - window.stickyElementsForPopup.sizes.top) { 9231 const verticalShift = (" center+".concat(Math.round(window.stickyElementsForPopup.sizes.top / 2).toString())); 9232 try { 9233 box.dialog( 9234 "option", 9235 "position", 9236 { 9237 my: "center", 9238 at: atHorizontal.concat(verticalShift), 9239 of: window 9240 } 9241 ) 9242 } catch (e) {} 9243 } else if (window.stickyElementsForPopup.top) { 9244 try { 9245 box.dialog( 9246 "option", 9247 "position", 9248 { 9249 my: "top", 9250 at: atHorizontal.concat(" bottom"), 9251 of: window.stickyElementsForPopup.top 9252 } 9253 ) 9254 } catch (e) {} 9255 } else { 9256 try { 9257 box.dialog( 9258 "option", 9259 "position", 9260 { 9261 my: "top", 9262 at: "top", 9263 of: window, 9264 collision: "fit" 9265 } 9266 ) 9267 } catch (e) {} 9268 } 9269 }, 1 9270 ) 9271 } 9272}; 9273 9274// Destroy 9275popup.destroy = function() 9276{ 9277 if (this.currentPopup && this.currentPopup.box) { 9278 const box = this.currentPopup.box 9279 this.close() 9280 box.dialog('destroy') 9281 box.remove(); 9282 } 9283} 9284 9285 9286// Close popup 9287popup.close = function(event) 9288{ 9289 var box; 9290 if (this.currentPopup && this.currentPopup.box) { 9291 box = this.currentPopup.box; 9292 box.dialog('close'); 9293 9294 if (this.currentUnblockCallback && _.isFunction(this.currentUnblockCallback)) { 9295 this.currentUnblockCallback(); 9296 } 9297 } 9298 9299 this.currentUnblockCallback = null; 9300 this.currentPopup = null; 9301 9302 xcart.trigger('popup.close', { 'widget': this, 'box': box, event }); 9303}; 9304 9305popup.beforeClose = function(event) 9306{ 9307 var box; 9308 if (this.currentPopup && this.currentPopup.box) { 9309 box = this.currentPopup.box; 9310 } 9311 9312 xcart.trigger('popup.beforeClose', { 'widget': this, 'box': box, event }); 9313}; 9314 9315xcart.bind('popup.open', function () { 9316 document.querySelectorAll('.ui-dialog-titlebar-close').forEach(btn => { 9317 if (!btn.innerText) { 9318 btn.innerHTML += '<span class="visually-hidden">' + xcart.t('Close') + '</span>'; 9319 } 9320 }); 9321}); 9322 9323jQuery(window).resize( 9324 function(event) { 9325 popup.reposition(); 9326 } 9327);; 9328/* AUTOGENERATED: xcart.popup_button.js */ 9329/* vim: set ts=2 sw=2 sts=2 et: */ 9330 9331/** 9332 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 9333 * See https://www.x-cart.com/license-agreement.html for license details. 9334 */ 9335 9336var lastPopupButton; 9337 9338function PopupButton(base) { 9339 var obj = this; 9340 9341 if (base) { 9342 this.base = base; 9343 this.eachCallback(base); 9344 } else { 9345 this.base = jQuery(this.pattern); 9346 this.base.each( 9347 function () { 9348 obj.eachCallback(this); 9349 } 9350 ); 9351 } 9352} 9353 9354PopupButton.prototype.pattern = '.popup-button.default-popup-button'; 9355 9356PopupButton.prototype.enableBackgroundSubmit = true; 9357 9358PopupButton.prototype.options = { 9359 width: 'auto' 9360}; 9361 9362PopupButton.prototype.afterSubmit = function (selector) { 9363}; 9364 9365PopupButton.prototype.callback = function (selector, link) { 9366 9367 var obj = this; 9368 9369 var shouldClose = jQuery(this.base).data('without-close') === true || !jQuery(this.base).data('without-close'); 9370 9371 if (!this.enableBackgroundSubmit) { 9372 jQuery('form', selector).each(function () { 9373 this.commonController.backgroundSubmit = false; 9374 }); 9375 } else if (shouldClose) { 9376 jQuery('form', selector).each(function () { 9377 jQuery(this).commonController( 9378 'enableBackgroundSubmit', 9379 function () { 9380 // Close dialog (but it is available in DOM) 9381 popup.close(); 9382 openWaitBar(); 9383 9384 return true; 9385 }, 9386 function (event) { 9387 closeWaitBar(); 9388 9389 obj.afterSubmit(selector); 9390 9391 // Remove dialog from DOM 9392 jQuery(selector).remove(); 9393 link.linkedDialog = null; 9394 9395 return false; 9396 } 9397 ); 9398 }); 9399 } 9400 9401 $(link).trigger('popup.open'); 9402 9403 xcart.autoload(PopupButton); 9404}; 9405 9406PopupButton.prototype.getURLParams = function (button) { 9407 return xcart.getCommentedData(button, 'url_params'); 9408}; 9409 9410PopupButton.prototype.getJSConfirmText = function (button) { 9411 return xcart.getCommentedData(button, 'jsConfirm'); 9412}; 9413 9414PopupButton.prototype.eachClick = function (elem) { 9415 lastPopupButton = jQuery(elem); 9416 9417 var proceed = true; 9418 9419 if (lastPopupButton.hasClass('disabled')) { 9420 return false;
9421 } 9422 9423 if (this.getJSConfirmText(elem)) { 9424 proceed = confirm(this.getJSConfirmText(elem)); 9425 } 9426 9427 if (proceed) { 9428 this.beforeLoadDialog(elem); 9429 return loadDialogByLink( 9430 elem, 9431 URLHandler.buildURL(this.getURLParams(elem)), 9432 this.options, 9433 _.bind(this.callback, this), 9434 elem 9435 ); 9436 } 9437 9438 return proceed; 9439}; 9440 9441PopupButton.prototype.beforeLoadDialog = function (elem) { 9442}; 9443 9444PopupButton.prototype.eachCallback = function (elem) { 9445 var obj = this; 9446 elem.popupController = obj; 9447 9448 var handler = _.bind(obj.eachClick, this); 9449 jQuery(elem).click( 9450 function (event) { 9451 handler(this); 9452 event.stopImmediatePropagation(); 9453 9454 return false; 9455 } 9456 ); 9457};; 9458/* AUTOGENERATED: Sortable.js */ 9459/*! Sortable 1.13.0 - MIT | git://github.com/SortableJS/Sortable.git */ 9460!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):(t=t||self).Sortable=e()}(this,function(){"use strict";function o(t){return(o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t})(t)}function a(){return(a=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(t[o]=n[o])}return t}).apply(this,arguments)}function I(i){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{},e=Object.keys(r);"function"==typeof Object.getOwnPropertySymbols&&(e=e.concat(Object.getOwnPropertySymbols(r).filter(function(t){return Object.getOwnPropertyDescriptor(r,t).enumerable}))),e.forEach(function(t){var e,n,o;e=i,o=r[n=t],n in e?Object.defineProperty(e,n,{value:o,enumerable:!0,configurable:!0,writable:!0}):e[n]=o})}return i}function l(t,e){if(null==t)return{};var n,o,i=function(t,e){if(null==t)return{};var n,o,i={},r=Object.keys(t);for(o=0;o<r.length;o++)n=r[o],0<=e.indexOf(n)||(i[n]=t[n]);return i}(t,e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);for(o=0;o<r.length;o++)n=r[o],0<=e.indexOf(n)||Object.prototype.propertyIsEnumerable.call(t,n)&&(i[n]=t[n])}return i}function e(t){return function(t){if(Array.isArray(t)){for(var e=0,n=new Array(t.length);e<t.length;e++)n[e]=t[e];return n}}(t)||function(t){if(Symbol.iterator in Object(t)||"[object Arguments]"===Object.prototype.toString.call(t))return Array.from(t)}(t)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance")}()}function t(t){if("undefined"!=typeof window&&window.navigator)return!!navigator.userAgent.match(t)}var w=t(/(?:Trident.*rv[ :]?11\.|msie|iemobile|Windows Phone)/i),E=t(/Edge/i),c=t(/firefox/i),u=t(/safari/i)&&!t(/chrome/i)&&!t(/android/i),n=t(/iP(ad|od|hone)/i),i=t(/chrome/i)&&t(/android/i),r={capture:!1,passive:!1};function d(t,e,n){t.addEventListener(e,n,!w&&r)}function s(t,e,n){t.removeEventListener(e,n,!w&&r)}function h(t,e){if(e){if(">"===e[0]&&(e=e.substring(1)),t)try{if(t.matches)return t.matches(e);if(t.msMatchesSelector)return t.msMatchesSelector(e);if(t.webkitMatchesSelector)return t.webkitMatchesSelector(e)}catch(t){return!1}return!1}}function P(t,e,n,o){if(t){n=n||document;do{if(null!=e&&(">"===e[0]?t.parentNode===n&&h(t,e):h(t,e))||o&&t===n)return t;if(t===n)break}while(t=(i=t).host&&i!==document&&i.host.nodeType?i.host:i.parentNode)}var i;return null}var f,p=/\s+/g;function k(t,e,n){if(t&&e)if(t.classList)t.classList[n?"add":"remove"](e);else{var o=(" "+t.className+" ").replace(p," ").replace(" "+e+" "," ");t.className=(o+(n?" "+e:"")).replace(p," ")}}function R(t,e,n){var o=t&&t.style;if(o){if(void 0===n)return document.defaultView&&document.defaultView.getComputedStyle?n=document.defaultView.getComputedStyle(t,""):t.currentStyle&&(n=t.currentStyle),void 0===e?n:n[e];e in o||-1!==e.indexOf("webkit")||(e="-webkit-"+e),o[e]=n+("string"==typeof n?"":"px")}}function v(t,e){var n="";if("string"==typeof t)n=t;else do{var o=R(t,"transform");o&&"none"!==o&&(n=o+" "+n)}while(!e&&(t=t.parentNode));var i=window.DOMMatrix||window.WebKitCSSMatrix||window.CSSMatrix||window.MSCSSMatrix;return i&&new i(n)}function g(t,e,n){if(t){var o=t.getElementsByTagName(e),i=0,r=o.length;if(n)for(;i<r;i++)n(o[i],i);return o}return[]}function A(){var t=document.scrollingElement;return t||document.documentElement}function X(t,e,n,o,i){if(t.getBoundingClientRect||t===window){var r,a,l,s,c,u,d;if(d=t!==window&&t.parentNode&&t!==A()?(a=(r=t.getBoundingClientRect()).top,l=r.left,s=r.bottom,c=r.right,u=r.height,r.width):(l=a=0,s=window.innerHeight,c=window.innerWidth,u=window.innerHeight,window.innerWidth),(e||n)&&t!==window&&(i=i||t.parentNode,!w))do{if(i&&i.getBoundingClientRect&&("none"!==R(i,"transform")||n&&"static"!==R(i,"position"))){var h=i.getBoundingClientRect();a-=h.top+parseInt(R(i,"border-top-width")),l-=h.left+parseInt(R(i,"border-left-width")),s=a+r.height,c=l+r.width;break}}while(i=i.parentNode);
vendor: 4,111 bytes, line 9460
9460if(o&&t!==window){var f=v(i||t),p=f&&f.a,g=f&&f.d;f&&(s=(a/=g)+(u/=g),c=(l/=p)+(d/=p))}return{top:a,left:l,bottom:s,right:c,width:d,height:u}}}function Y(t,e,n){for(var o=H(t,!0),i=X(t)[e];o;){var r=X(o)[n];if(!("top"===n||"left"===n?r<=i:i<=r))return o;if(o===A())break;o=H(o,!1)}return!1}function m(t,e,n){for(var o=0,i=0,r=t.children;i<r.length;){if("none"!==r[i].style.display&&r[i]!==Rt.ghost&&r[i]!==Rt.dragged&&P(r[i],n.draggable,t,!1)){if(o===e)return r[i];o++}i++}return null}function B(t,e){for(var n=t.lastElementChild;n&&(n===Rt.ghost||"none"===R(n,"display")||e&&!h(n,e));)n=n.previousElementSibling;return n||null}function F(t,e){var n=0;if(!t||!t.parentNode)return-1;for(;t=t.previousElementSibling;)"TEMPLATE"===t.nodeName.toUpperCase()||t===Rt.clone||e&&!h(t,e)||n++;return n}function b(t){var e=0,n=0,o=A();if(t)do{var i=v(t),r=i.a,a=i.d;e+=t.scrollLeft*r,n+=t.scrollTop*a}while(t!==o&&(t=t.parentNode));return[e,n]}function H(t,e){if(!t||!t.getBoundingClientRect)return A();var n=t,o=!1;do{if(n.clientWidth<n.scrollWidth||n.clientHeight<n.scrollHeight){var i=R(n);if(n.clientWidth<n.scrollWidth&&("auto"==i.overflowX||"scroll"==i.overflowX)||n.clientHeight<n.scrollHeight&&("auto"==i.overflowY||"scroll"==i.overflowY)){if(!n.getBoundingClientRect||n===document.body)return A();if(o||e)return n;o=!0}}}while(n=n.parentNode);return A()}function y(t,e){return Math.round(t.top)===Math.round(e.top)&&Math.round(t.left)===Math.round(e.left)&&Math.round(t.height)===Math.round(e.height)&&Math.round(t.width)===Math.round(e.width)}function D(e,n){return function(){if(!f){var t=arguments;1===t.length?e.call(this,t[0]):e.apply(this,t),f=setTimeout(function(){f=void 0},n)}}}function L(t,e,n){t.scrollLeft+=e,t.scrollTop+=n}function S(t){var e=window.Polymer,n=window.jQuery||window.Zepto;return e&&e.dom?e.dom(t).cloneNode(!0):n?n(t).clone(!0)[0]:t.cloneNode(!0)}function _(t,e){R(t,"position","absolute"),R(t,"top",e.top),R(t,"left",e.left),R(t,"width",e.width),R(t,"height",e.height)}function C(t){R(t,"position",""),R(t,"top",""),R(t,"left",""),R(t,"width",""),R(t,"height","")}var j="Sortable"+(new Date).getTime();function T(){var e,o=[];return{captureAnimationState:function(){o=[],this.options.animation&&[].slice.call(this.el.children).forEach(function(t){if("none"!==R(t,"display")&&t!==Rt.ghost){o.push({target:t,rect:X(t)});var e=I({},o[o.length-1].rect);if(t.thisAnimationDuration){var n=v(t,!0);n&&(e.top-=n.f,e.left-=n.e)}t.fromRect=e}})},addAnimationState:function(t){o.push(t)},removeAnimationState:function(t){o.splice(function(t,e){for(var n in t)if(t.hasOwnProperty(n))for(var o in e)if(e.hasOwnProperty(o)&&e[o]===t[n][o])return Number(n);return-1}(o,{target:t}),1)},animateAll:function(t){var c=this;if(!this.options.animation)return clearTimeout(e),void("function"==typeof t&&t());var u=!1,d=0;o.forEach(function(t){var e=0,n=t.target,o=n.fromRect,i=X(n),r=n.prevFromRect,a=n.prevToRect,l=t.rect,s=v(n,!0);s&&(i.top-=s.f,i.left-=s.e),n.toRect=i,n.thisAnimationDuration&&y(r,i)&&!y(o,i)&&(l.top-i.top)/(l.left-i.left)==(o.top-i.top)/(o.left-i.left)&&(e=function(t,e,n,o){return Math.sqrt(Math.pow(e.top-t.top,2)+Math.pow(e.left-t.left,2))/Math.sqrt(Math.pow(e.top-n.top,2)+Math.pow(e.left-n.left,2))*o.animation}(l,r,a,c.options)),y(i,o)||(n.prevFromRect=o,n.prevToRect=i,e||(e=c.options.animation),c.animate(n,l,i,e)),e&&(u=!0,d=Math.max(d,e),clearTimeout(n.animationResetTimer),n.animationResetTimer=setTimeout(function(){n.animationTime=0,n.prevFromRect=null,n.fromRect=null,n.prevToRect=null,n.thisAnimationDuration=null},e),n.thisAnimationDuration=e)}),clearTimeout(e),u?e=setTimeout(function(){"function"==typeof t&&t()},d):"function"==typeof t&&t(),o=[]},animate:function(t,e,n,o){if(o){R(t,"transition",""),R(t,"transform","");var i=v(this.el),r=i&&i.a,a=i&&i.d,l=(e.left-n.left)/(r||1),s=(e.top-n.top)/(a||1);t.animatingX=!!l,t.animatingY=!!s,R(t,"transform","translate3d("+l+"px,"+s+"px,0)"),this.forRepaintDummy=function(t){return t.offsetWidth}(t),R(t,"transition","transform "+o+"ms"+(this.options.easing?" "+this.options.easing:"")),R(t,"transform","translate3d(0,
94600,0)"),"number"==typeof t.animated&&clearTimeout(t.animated),t.animated=setTimeout(function(){R(t,"transition",""),R(t,"transform",""),t.animated=!1,t.animatingX=!1,t.animatingY=!1},o)}}}}var x=[],M={initializeByDefault:!0},O={mount:function(e){for(var t in M)!M.hasOwnProperty(t)||t in e||(e[t]=M[t]);x.forEach(function(t){if(t.pluginName===e.pluginName)throw"Sortable: Cannot mount plugin ".concat(e.pluginName," more than once")}),x.push(e)},pluginEvent:function(e,n,o){var t=this;this.eventCanceled=!1,o.cancel=function(){t.eventCanceled=!0};var i=e+"Global";x.forEach(function(t){n[t.pluginName]&&(n[t.pluginName][i]&&n[t.pluginName][i](I({sortable:n},o)),n.options[t.pluginName]&&n[t.pluginName][e]&&n[t.pluginName][e](I({sortable:n},o)))})},initializePlugins:function(o,i,r,t){for(var e in x.forEach(function(t){var e=t.pluginName;if(o.options[e]||t.initializeByDefault){var n=new t(o,i,o.options);n.sortable=o,n.options=o.options,o[e]=n,a(r,n.defaults)}}),o.options)if(o.options.hasOwnProperty(e)){var n=this.modifyOption(o,e,o.options[e]);void 0!==n&&(o.options[e]=n)}},getEventProperties:function(e,n){var o={};return x.forEach(function(t){"function"==typeof t.eventProperties&&a(o,t.eventProperties.call(n[t.pluginName],e))}),o},modifyOption:function(e,n,o){var i;return x.forEach(function(t){e[t.pluginName]&&t.optionListeners&&"function"==typeof t.optionListeners[n]&&(i=t.optionListeners[n].call(e[t.pluginName],o))}),i}};function N(t){var e=t.sortable,n=t.rootEl,o=t.name,i=t.targetEl,r=t.cloneEl,a=t.toEl,l=t.fromEl,s=t.oldIndex,c=t.newIndex,u=t.oldDraggableIndex,d=t.newDraggableIndex,h=t.originalEvent,f=t.putSortable,p=t.extraEventProperties;if(e=e||n&&n[j]){var g,v=e.options,m="on"+o.charAt(0).toUpperCase()+o.substr(1);!window.CustomEvent||w||E?(g=document.createEvent("Event")).initEvent(o,!0,!0):g=new CustomEvent(o,{bubbles:!0,cancelable:!0}),g.to=a||n,g.from=l||n,g.item=i||n,g.clone=r,g.oldIndex=s,g.newIndex=c,g.oldDraggableIndex=u,g.newDraggableIndex=d,g.originalEvent=h,g.pullMode=f?f.lastPutMode:void 0;var b=I({},p,O.getEventProperties(o,e));for(var y in b)g[y]=b[y];n&&n.dispatchEvent(g),v[m]&&v[m].call(e,g)}}function K(t,e,n){var o=2<arguments.length&&void 0!==n?n:{},i=o.evt,r=l(o,["evt"]);O.pluginEvent.bind(Rt)(t,e,I({dragEl:z,parentEl:G,ghostEl:U,rootEl:q,nextEl:V,lastDownEl:Z,cloneEl:Q,cloneHidden:$,dragStarted:dt,putSortable:it,activeSortable:Rt.active,originalEvent:i,oldIndex:J,oldDraggableIndex:et,newIndex:tt,newDraggableIndex:nt,hideGhostForTarget:At,unhideGhostForTarget:It,cloneNowHidden:function(){$=!0},cloneNowShown:function(){$=!1},dispatchSortableEvent:function(t){W({sortable:e,name:t,originalEvent:i})}},r))}function W(t){N(I({putSortable:it,cloneEl:Q,targetEl:z,rootEl:q,oldIndex:J,oldDraggableIndex:et,newIndex:tt,newDraggableIndex:nt},t))}var z,G,U,q,V,Z,Q,$,J,tt,et,nt,ot,it,rt,at,lt,st,ct,ut,dt,ht,ft,pt,gt,vt=!1,mt=!1,bt=[],yt=!1,wt=!1,Et=[],Dt=!1,St=[],_t="undefined"!=typeof document,Ct=n,Tt=E||w?"cssFloat":"float",xt=_t&&!i&&!n&&"draggable"in document.createElement("div"),Mt=function(){if(_t){if(w)return!1;var t=document.createElement("x");return t.style.cssText="pointer-events:auto","auto"===t.style.pointerEvents}}
vendor: 11,393 bytes, line 9460
9460(),Ot=function(t,e){var n=R(t),o=parseInt(n.width)-parseInt(n.paddingLeft)-parseInt(n.paddingRight)-parseInt(n.borderLeftWidth)-parseInt(n.borderRightWidth),i=m(t,0,e),r=m(t,1,e),a=i&&R(i),l=r&&R(r),s=a&&parseInt(a.marginLeft)+parseInt(a.marginRight)+X(i).width,c=l&&parseInt(l.marginLeft)+parseInt(l.marginRight)+X(r).width;if("flex"===n.display)return"column"===n.flexDirection||"column-reverse"===n.flexDirection?"vertical":"horizontal";if("grid"===n.display)return n.gridTemplateColumns.split(" ").length<=1?"vertical":"horizontal";if(i&&a.float&&"none"!==a.float){var u="left"===a.float?"left":"right";return!r||"both"!==l.clear&&l.clear!==u?"horizontal":"vertical"}return i&&("block"===a.display||"flex"===a.display||"table"===a.display||"grid"===a.display||o<=s&&"none"===n[Tt]||r&&"none"===n[Tt]&&o<s+c)?"vertical":"horizontal"},Nt=function(t){function s(a,l){return function(t,e,n,o){var i=t.options.group.name&&e.options.group.name&&t.options.group.name===e.options.group.name;if(null==a&&(l||i))return!0;if(null==a||!1===a)return!1;if(l&&"clone"===a)return a;if("function"==typeof a)return s(a(t,e,n,o),l)(t,e,n,o);var r=(l?t:e).options.group.name;return!0===a||"string"==typeof a&&a===r||a.join&&-1<a.indexOf(r)}}var e={},n=t.group;n&&"object"==o(n)||(n={name:n}),e.name=n.name,e.checkPull=s(n.pull,!0),e.checkPut=s(n.put),e.revertClone=n.revertClone,t.group=e},At=function(){!Mt&&U&&R(U,"display","none")},It=function(){!Mt&&U&&R(U,"display","")};_t&&document.addEventListener("click",function(t){if(mt)return t.preventDefault(),t.stopPropagation&&t.stopPropagation(),t.stopImmediatePropagation&&t.stopImmediatePropagation(),mt=!1},!0);function Pt(t){if(z){var e=function(r,a){var l;return bt.some(function(t){if(!B(t)){var e=X(t),n=t[j].options.emptyInsertThreshold,o=r>=e.left-n&&r<=e.right+n,i=a>=e.top-n&&a<=e.bottom+n;return n&&o&&i?l=t:void 0}}),l}((t=t.touches?t.touches[0]:t).clientX,t.clientY);if(e){var n={};for(var o in t)t.hasOwnProperty(o)&&(n[o]=t[o]);n.target=n.rootEl=e,n.preventDefault=void 0,n.stopPropagation=void 0,e[j]._onDragOver(n)}}}function kt(t){z&&z.parentNode[j]._isOutsideThisEl(t.target)}function Rt(t,e){if(!t||!t.nodeType||1!==t.nodeType)throw"Sortable: `el` must be an HTMLElement, not ".concat({}.toString.call(t));this.el=t,this.options=e=a({},e),t[j]=this;var n={group:null,sort:!0,disabled:!1,store:null,handle:null,draggable:/^[uo]l$/i.test(t.nodeName)?">li":">*",swapThreshold:1,invertSwap:!1,invertedSwapThreshold:null,removeCloneOnHide:!0,direction:function(){return Ot(t,this.options)},ghostClass:"sortable-ghost",chosenClass:"sortable-chosen",dragClass:"sortable-drag",ignore:"a, img",filter:null,preventOnFilter:!0,animation:0,easing:null,setData:function(t,e){t.setData("Text",e.textContent)},dropBubble:!1,dragoverBubble:!1,dataIdAttr:"data-id",delay:0,delayOnTouchOnly:!1,touchStartThreshold:(Number.parseInt?Number:window).parseInt(window.devicePixelRatio,10)||1,forceFallback:!1,fallbackClass:"sortable-fallback",fallbackOnBody:!1,fallbackTolerance:0,fallbackOffset:{x:0,y:0},supportPointer:!1!==Rt.supportPointer&&"PointerEvent"in window&&!u,emptyInsertThreshold:5};for(var o in O.initializePlugins(this,t,n),n)o in e||(e[o]=n[o]);for(var i in Nt(e),this)"_"===i.charAt(0)&&"function"==typeof this[i]&&(this[i]=this[i].bind(this));this.nativeDraggable=!e.forceFallback&&xt,this.nativeDraggable&&(this.options.touchStartThreshold=1),e.supportPointer?d(t,"pointerdown",this._onTapStart):(d(t,"mousedown",this._onTapStart),d(t,"touchstart",this._onTapStart)),this.nativeDraggable&&(d(t,"dragover",this),d(t,"dragenter",this)),bt.push(this.el),e.store&&e.store.get&&this.sort(e.store.get(this)||[]),a(this,T())}function Xt(t,e,n,o,i,r,a,l){var s,c,u=t[j],d=u.options.onMove;return!window.CustomEvent||w||E?(s=document.createEvent("Event")).initEvent("move",!0,!0):s=new CustomEvent("move",{bubbles:!0,cancelable:!0}),s.to=e,s.from=t,s.dragged=n,s.draggedRect=o,s.related=i||e,s.relatedRect=r||X(e),s.willInsertAfter=l,s.originalEvent=a,t.dispatchEvent(s),d&&(c=d.call(u,s,a)),c}function Yt(t){t.draggable=!1}function Bt(){Dt=!1}function Ft(t){for(var e=t.tagName+t.className+t.src+t.href+t.textContent,n=e.length,o=0;n--;)o+=e.charCodeAt(n);return o.toString(36)}function Ht(t){return setTimeout(t,0)}function Lt(t){return clearTimeout(t)}Rt.prototype={constructor:Rt,_isOutsideThisEl:function(t){this.el.contains(t)||t===this.el||(ht=null)},_getDirection:function(t,e){return"function"==typeof this.options.direction?this.options.direction.call(this,t,e,z):this.options.direction},_onTapStart:function(e){if(e.cancelable){var n=this,o=this.el,t=this.options,i=t.preventOnFilter,r=e.type,a=e.touches&&e.touches[0]||e.pointerType&&"touch"===e.pointerType&&e,l=(a||e).target,s=e.target.shadowRoot&&(e.path&&e.path[0]||e.composedPath&&e.composedPath()[0])||l,c=t.filter;if(function(t){St.length=0;var e=t.getElementsByTagName("input"),n=e.length;for(;n--;){var o=e[n];o.checked&&St.push(o)}}(o),!z&&!(/mousedown|pointerdown/.test(r)&&0!==e.button||t.disabled)&&!s.isContentEditable&&(this.nativeDraggable||!u||!l||"SELECT"!==l.tagName.toUpperCase())&&!((l=P(l,t.draggable,o,!1))&&l.animated||Z===l)){if(J=F(l),et=F(l,t.draggable),"function"==typeof c){if(c.call(this,e,l,this))return W({sortable:n,rootEl:s,name:"filter",targetEl:l,toEl:o,fromEl:o}),K("filter",n,{evt:e}),void(i&&e.cancelable&&e.preventDefault())}else if(c&&(c=c.split(",").some(function(t){if(t=P(s,t.trim(),o,!1))return W({sortable:n,rootEl:t,name:"filter",targetEl:l,fromEl:o,toEl:o}),K("filter",n,{evt:e}),!0})))return void(i&&e.cancelable&&e.preventDefault());t.handle&&!P(s,t.handle,o,!1)||this._prepareDragStart(e,a,l)}}},_prepareDragStart:function(t,e,n){var o,i=this,r=i.el,a=i.options,l=r.ownerDocument;if(n&&!z&&n.parentNode===r){var s=X(n);if(q=r,G=(z=n).parentNode,V=z.nextSibling,Z=n,ot=a.group,rt={target:Rt.dragged=z,clientX:(e||t).clientX,clientY:(e||t).clientY},ct=rt.clientX-s.left,ut=rt.clientY-s.top,this._lastX=(e||t).clientX,this._lastY=(e||t).clientY,z.style["will-change"]="all",o=function(){K("delayEnded",i,{evt:t}),Rt.eventCanceled?i._onDrop():(i._disableDelayedDragEvents(),!c&&i.nativeDraggable&&(z.draggable=!0),i._triggerDragStart(t,e),W({sortable:i,name:"choose",originalEvent:t}),k(z,a.chosenClass,!0))},a.ignore.split(",").forEach(function(t){g(z,t.trim(),Yt)}),d(l,"dragover",Pt),d(l,"mousemove",Pt),d(l,"touchmove",Pt),d(l,"mouseup",i._onDrop),d(l,"touchend",i._onDrop),d(l,"touchcancel",i._onDrop),c&&this.nativeDraggable&&(this.options.touchStartThreshold=4,z.draggable=!0),K("delayStart",this,{evt:t}),!a.delay||a.delayOnTouchOnly&&!e||this.nativeDraggable&&(E||w))o();else{if(Rt.eventCanceled)return void this._onDrop();d(l,"mouseup",i._disableDelayedDrag),d(l,"touchend",i._disableDelayedDrag),d(l,"touchcancel",i._disableDelayedDrag),d(l,"mousemove",i._delayedDragTouchMoveHandler),d(l,"touchmove",i._delayedDragTouchMoveHandler),a.supportPointer&&d(l,"pointermove",i._delayedDragTouchMoveHandler),i._dragStartTimer=setTimeout(o,a.delay)}}},_delayedDragTouchMoveHandler:function(t){var e=t.touches?t.touches[0]:t;Math.max(Math.abs(e.clientX-this._lastX),Math.abs(e.clientY-this._lastY))>=Math.floor(this.options.touchStartThreshold/(this.nativeDraggable&&window.devicePixelRatio||1))&&this._disableDelayedDrag()},_disableDelayedDrag:function(){z&&Yt(z),clearTimeout(this._dragStartTimer),this._disableDelayedDragEvents()},_disableDelayedDragEvents:function(){var t=this.el.ownerDocument;s(t,"mouseup",this._disableDelayedDrag),s(t,"touchend",this._disableDelayedDrag),s(t,"touchcancel",this._disableDelayedDrag),s(t,"mousemove",this._delayedDragTouchMoveHandler),s(t,"touchmove",this._delayedDragTouchMoveHandler),s(t,"pointermove",this._delayedDragTouchMoveHandler)},_triggerDragStart:function(t,e){e=e||"touch"==t.pointerType&&t,!this.nativeDraggable||e?this.options.supportPointer?d(document,"pointermove",this._onTouchMove):d(document,e?"touchmove":"mousemove",this._onTouchMove):(d(z,"dragend",this),d(q,"dragstart",this._onDragStart));try{document.selection?Ht(function(){document.selection.empty()}):window.getSelection().removeAllRanges()}catch(t){}},_dragStarted:function(t,e){if(vt=!1,q&&z){K("dragStarted",this,{evt:e}),this.nativeDraggable&&d(document,"dragover",kt);var n=this.options;t||k(z,n.dragClass,!1),k(z,n.ghostClass,!0),Rt.active=this,t&&this._appendGhost(),W({sortable:this,name:"start",originalEvent:e})}else this._nulling()},_emulateDragOver:function(){if(at){this._lastX=at.clientX,this._lastY=at.clientY,At();for(var t=document.elementFromPoint(at.clientX,at.clientY),e=t;t&&t.shadowRoot&&(t=t.shadowRoot.elementFromPoint(at.clientX,at.clientY))!==e;)e=t;if(z.parentNode[j]._isOutsideThisEl(t),e)do{if(e[j]){if(e[j]._onDragOver({clientX:at.clientX,clientY:at.clientY,target:t,rootEl:e})&&!this.options.dragoverBubble)break}t=e}while(e=e.parentNode);It()}},_onTouchMove:function(t){if(rt){var e=this.options,n=e.fallbackTolerance,o=e.fallbackOffset,i=t.touches?t.touches[0]:t,r=U&&v(U,!0),a=U&&r&&r.a,l=U&&r&&r.d,s=Ct&>&&b(gt),c=(i.clientX-rt.clientX+o.x)/(a||1)+(s?s[0]-Et[0]:0)/(a||1),u=(i.clientY-rt.clientY+o.y)/(l||1)+(s?s[1]-Et[1]:0)/(l||1);if(!Rt.active&&!vt){if(n&&Math.max(Math.abs(i.clientX-this._lastX),Math.abs(i.clientY-this._lastY))<n)return;this._onDragStart(t,!0)}if(U){r?(r.e+=c-(lt||0),r.f+=u-(st||0)):r={a:1,b:0,c:0,d:1,e:c,f:u};var d="matrix(".concat(r.a,",").concat(r.b,",").concat(r.c,",").concat(r.d,",").concat(r.e,",").concat(r.f,")");R(U,"webkitTransform",d),R(U,"mozTransform",d),R(U,"msTransform",d),R(U,"transform",d),lt=c,st=u,at=i}t.cancelable&&t.preventDefault()}},_appendGhost:function(){if(!U){var t=this.options.fallbackOnBody?document.body:q,e=X(z,!0,Ct,!0,t),n=this.options;if(Ct){for(gt=t;"static"===R(gt,"position")&&"none"===R(gt,"transform")&>!==document;)gt=gt.parentNode;gt!==document.body&>!==document.documentElement?(gt===document&&(gt=A()),e.top+=gt.scrollTop,e.left+=gt.scrollLeft):gt=A(),Et=b(gt)}k(U=z.cloneNode(!0),n.ghostClass,!1),k(U,n.fallbackClass,!0),k(U,n.dragClass,!0),R(U,"transition",""),R(U,"transform",""),R(U,"box-sizing","border-box"),R(U,"margin",0),R(U,"top",e.top),R(U,"left",e.left),R(U,"width",e.width),R(U,"height",e.height),R(U,"opacity","0.8"),R(U,"position",Ct?"absolute":"fixed"),R(U,"zIndex","100000"),R(U,"pointerEvents","none"),Rt.ghost=U,t.appendChild(U),R(U,"transform-origin",ct/parseInt(U.style.width)*100+"% "+ut/parseInt(U.style.height)*100+"%")}},_onDragStart:function(t,e){var n=this,o=t.dataTransfer,i=n.options;K("dragStart",this,{evt:t}),Rt.eventCanceled?this._onDrop():(K("setupClone",this),Rt.eventCanceled||((Q=S(z)).draggable=!1,Q.style["will-change"]="",this._hideClone(),k(Q,this.options.chosenClass,!1),Rt.clone=Q),n.cloneId=Ht(function(){K("clone",n),Rt.eventCanceled||(n.options.removeCloneOnHide||q.insertBefore(Q,z),n._hideClone(),W({sortable:n,name:"clone"}))}),e||k(z,i.dragClass,!0),e?(mt=!0,n._loopId=setInterval(n._emulateDragOver,50)):(s(document,"mouseup",n._onDrop),s(document,"touchend",n._onDrop),s(document,"touchcancel",n._onDrop),o&&(o.effectAllowed="move",i.setData&&i.setData.call(n,o,z)),d(document,"drop",n),R(z,"transform","translateZ(0)")),vt=!0,n._dragStartId=Ht(n._dragStarted.bind(n,e,t)),d(document,"selectstart",n),dt=!0,u&&R(document.body,"user-select","none"))},_onDragOver:function(n){var o,i,r,a,l=this.el,s=n.target,e=this.options,t=e.group,c=Rt.active,u=ot===t,d=e.s
vendor: 4,823 bytes, line 9460
9460ort,h=it||c,f=this,p=!1;if(!Dt){if(void 0!==n.preventDefault&&n.cancelable&&n.preventDefault(),s=P(s,e.draggable,l,!0),M("dragOver"),Rt.eventCanceled)return p;if(z.contains(n.target)||s.animated&&s.animatingX&&s.animatingY||f._ignoreWhileAnimating===s)return N(!1);if(mt=!1,c&&!e.disabled&&(u?d||(r=!q.contains(z)):it===this||(this.lastPutMode=ot.checkPull(this,c,z,n))&&t.checkPut(this,c,z,n))){if(a="vertical"===this._getDirection(n,s),o=X(z),M("dragOverValid"),Rt.eventCanceled)return p;if(r)return G=q,O(),this._hideClone(),M("revert"),Rt.eventCanceled||(V?q.insertBefore(z,V):q.appendChild(z)),N(!0);var g=B(l,e.draggable);if(!g||function(t,e,n){var o=X(B(n.el,n.options.draggable));return e?t.clientX>o.right+10||t.clientX<=o.right&&t.clientY>o.bottom&&t.clientX>=o.left:t.clientX>o.right&&t.clientY>o.top||t.clientX<=o.right&&t.clientY>o.bottom+10}(n,a,this)&&!g.animated){if(g===z)return N(!1);if(g&&l===n.target&&(s=g),s&&(i=X(s)),!1!==Xt(q,l,z,o,s,i,n,!!s))return O(),l.appendChild(z),G=l,A(),N(!0)}else if(s.parentNode===l){i=X(s);var v,m,b,y=z.parentNode!==l,w=!function(t,e,n){var o=n?t.left:t.top,i=n?t.right:t.bottom,r=n?t.width:t.height,a=n?e.left:e.top,l=n?e.right:e.bottom,s=n?e.width:e.height;return o===a||i===l||o+r/2===a+s/2}(z.animated&&z.toRect||o,s.animated&&s.toRect||i,a),E=a?"top":"left",D=Y(s,"top","top")||Y(z,"top","top"),S=D?D.scrollTop:void 0;if(ht!==s&&(m=i[E],yt=!1,wt=!w&&e.invertSwap||y),0!==(v=function(t,e,n,o,i,r,a,l){var s=o?t.clientY:t.clientX,c=o?n.height:n.width,u=o?n.top:n.left,d=o?n.bottom:n.right,h=!1;if(!a)if(l&&pt<c*i){if(!yt&&(1===ft?u+c*r/2<s:s<d-c*r/2)&&(yt=!0),yt)h=!0;else if(1===ft?s<u+pt:d-pt<s)return-ft}else if(u+c*(1-i)/2<s&&s<d-c*(1-i)/2)return function(t){return F(z)<F(t)?1:-1}(e);if((h=h||a)&&(s<u+c*r/2||d-c*r/2<s))return u+c/2<s?1:-1;return 0}(n,s,i,a,w?1:e.swapThreshold,null==e.invertedSwapThreshold?e.swapThreshold:e.invertedSwapThreshold,wt,ht===s)))for(var _=F(z);_-=v,(b=G.children[_])&&("none"===R(b,"display")||b===U););if(0===v||b===s)return N(!1);ft=v;var C=(ht=s).nextElementSibling,T=!1,x=Xt(q,l,z,o,s,i,n,T=1===v);if(!1!==x)return 1!==x&&-1!==x||(T=1===x),Dt=!0,setTimeout(Bt,30),O(),T&&!C?l.appendChild(z):s.parentNode.insertBefore(z,T?C:s),D&&L(D,0,S-D.scrollTop),G=z.parentNode,void 0===m||wt||(pt=Math.abs(m-X(s)[E])),A(),N(!0)}if(l.contains(z))return N(!1)}return!1}function M(t,e){K(t,f,I({evt:n,isOwner:u,axis:a?"vertical":"horizontal",revert:r,dragRect:o,targetRect:i,canSort:d,fromSortable:h,target:s,completed:N,onMove:function(t,e){return Xt(q,l,z,o,t,X(t),n,e)},changed:A},e))}function O(){M("dragOverAnimationCapture"),f.captureAnimationState(),f!==h&&h.captureAnimationState()}function N(t){return M("dragOverCompleted",{insertion:t}),t&&(u?c._hideClone():c._showClone(f),f!==h&&(k(z,it?it.options.ghostClass:c.options.ghostClass,!1),k(z,e.ghostClass,!0)),it!==f&&f!==Rt.active?it=f:f===Rt.active&&it&&(it=null),h===f&&(f._ignoreWhileAnimating=s),f.animateAll(function(){M("dragOverAnimationComplete"),f._ignoreWhileAnimating=null}),f!==h&&(h.animateAll(),h._ignoreWhileAnimating=null)),(s===z&&!z.animated||s===l&&!s.animated)&&(ht=null),e.dragoverBubble||n.rootEl||s===document||(z.parentNode[j]._isOutsideThisEl(n.target),t||Pt(n)),!e.dragoverBubble&&n.stopPropagation&&n.stopPropagation(),p=!0}function A(){tt=F(z),nt=F(z,e.draggable),W({sortable:f,name:"change",toEl:l,newIndex:tt,newDraggableIndex:nt,originalEvent:n})}},_ignoreWhileAnimating:null,_offMoveEvents:function(){s(document,"mousemove",this._onTouchMove),s(document,"touchmove",this._onTouchMove),s(document,"pointermove",this._onTouchMove),s(document,"dragover",Pt),s(document,"mousemove",Pt),s(document,"touchmove",Pt)},_offUpEvents:function(){var t=this.el.ownerDocument;s(t,"mouseup",this._onDrop),s(t,"touchend",this._onDrop),s(t,"pointerup",this._onDrop),s(t,"touchcancel",this._onDrop),s(document,"selectstart",this)},_onDrop:function(t){var e=this.el,n=this.options;tt=F(z),nt=F(z,n.draggable),K("drop",this,{evt:t}),G=z&&z.parentNode,tt=F(z),nt=F(z,n.draggable),Rt.eventCanceled||(yt=wt=vt=!1,clearInterval(this._loopId),clearTimeout(this._dragStartTimer),Lt(this.cloneId),Lt(this._dragStartId),this.nativeDraggable&&(s(document,"drop",this),s(e,"dragstart",this._onDragStart)),this._offMoveEvents(),this._offUpEvents(),u&&R(document.body,"user-select",""),R(z,"transform",""),t&&(dt&&(t.cancelable&&t.preventDefault(),n.dropBubble||t.stopPropagation()),U&&U.parentNode&&U.parentNode.removeChild(U),(q===G||it&&"clone"!==it.lastPutMode)&&Q&&Q.parentNode&&Q.parentNode.removeChild(Q),z&&(this.nativeDraggable&&s(z,"dragend",this),Yt(z),z.style["will-change"]="",dt&&!vt&&k(z,it?it.options.ghostClass:this.options.ghostClass,!1),k(z,this.options.chosenClass,!1),W({sortable:this,name:"unchoose",toEl:G,newIndex:null,newDraggableIndex:null,originalEvent:t}
vendor: 4,187 bytes, line 9460
9460),q!==G?(0<=tt&&(W({rootEl:G,name:"add",toEl:G,fromEl:q,originalEvent:t}),W({sortable:this,name:"remove",toEl:G,originalEvent:t}),W({rootEl:G,name:"sort",toEl:G,fromEl:q,originalEvent:t}),W({sortable:this,name:"sort",toEl:G,originalEvent:t})),it&&it.save()):tt!==J&&0<=tt&&(W({sortable:this,name:"update",toEl:G,originalEvent:t}),W({sortable:this,name:"sort",toEl:G,originalEvent:t})),Rt.active&&(null!=tt&&-1!==tt||(tt=J,nt=et),W({sortable:this,name:"end",toEl:G,originalEvent:t}),this.save())))),this._nulling()},_nulling:function(){K("nulling",this),q=z=G=U=V=Q=Z=$=rt=at=dt=tt=nt=J=et=ht=ft=it=ot=Rt.dragged=Rt.ghost=Rt.clone=Rt.active=null,St.forEach(function(t){t.checked=!0}),St.length=lt=st=0},handleEvent:function(t){switch(t.type){case"drop":case"dragend":this._onDrop(t);break;case"dragenter":case"dragover":z&&(this._onDragOver(t),function(t){t.dataTransfer&&(t.dataTransfer.dropEffect="move");t.cancelable&&t.preventDefault()}(t));break;case"selectstart":t.preventDefault()}},toArray:function(){for(var t,e=[],n=this.el.children,o=0,i=n.length,r=this.options;o<i;o++)P(t=n[o],r.draggable,this.el,!1)&&e.push(t.getAttribute(r.dataIdAttr)||Ft(t));return e},sort:function(t,e){var o={},i=this.el;this.toArray().forEach(function(t,e){var n=i.children[e];P(n,this.options.draggable,i,!1)&&(o[t]=n)},this),e&&this.captureAnimationState(),t.forEach(function(t){o[t]&&(i.removeChild(o[t]),i.appendChild(o[t]))}),e&&this.animateAll()},save:function(){var t=this.options.store;t&&t.set&&t.set(this)},closest:function(t,e){return P(t,e||this.options.draggable,this.el,!1)},option:function(t,e){var n=this.options;if(void 0===e)return n[t];var o=O.modifyOption(this,t,e);n[t]=void 0!==o?o:e,"group"===t&&Nt(n)},destroy:function(){K("destroy",this);var t=this.el;t[j]=null,s(t,"mousedown",this._onTapStart),s(t,"touchstart",this._onTapStart),s(t,"pointerdown",this._onTapStart),this.nativeDraggable&&(s(t,"dragover",this),s(t,"dragenter",this)),Array.prototype.forEach.call(t.querySelectorAll("[draggable]"),function(t){t.removeAttribute("draggable")}),this._onDrop(),this._disableDelayedDragEvents(),bt.splice(bt.indexOf(this.el),1),this.el=t=null},_hideClone:function(){if(!$){if(K("hideClone",this),Rt.eventCanceled)return;R(Q,"display","none"),this.options.removeCloneOnHide&&Q.parentNode&&Q.parentNode.removeChild(Q),$=!0}},_showClone:function(t){if("clone"===t.lastPutMode){if($){if(K("showClone",this),Rt.eventCanceled)return;z.parentNode!=q||this.options.group.revertClone?V?q.insertBefore(Q,V):q.appendChild(Q):q.insertBefore(Q,z),this.options.group.revertClone&&this.animate(z,Q),R(Q,"display",""),$=!1}}else this._hideClone()}},_t&&d(document,"touchmove",function(t){(Rt.active||vt)&&t.cancelable&&t.preventDefault()}),Rt.utils={on:d,off:s,css:R,find:g,is:function(t,e){return!!P(t,e,t,!1)},extend:function(t,e){if(t&&e)for(var n in e)e.hasOwnProperty(n)&&(t[n]=e[n]);return t},throttle:D,closest:P,toggleClass:k,clone:S,index:F,nextTick:Ht,cancelNextTick:Lt,detectDirection:Ot,getChild:m},Rt.get=function(t){return t[j]},Rt.mount=function(){for(var t=arguments.length,e=new Array(t),n=0;n<t;n++)e[n]=arguments[n];e[0].constructor===Array&&(e=e[0]),e.forEach(function(t){if(!t.prototype||!t.prototype.constructor)throw"Sortable: Mounted plugin must be a constructor function, not ".concat({}.toString.call(t));t.utils&&(Rt.utils=I({},Rt.utils,t.utils)),O.mount(t)})},Rt.create=function(t,e){return new Rt(t,e)};var jt,Kt,Wt,zt,Gt,Ut,qt=[],Vt=!(Rt.version="1.13.0");function Zt(){qt.forEach(function(t){clearInterval(t.pid)}),qt=[]}function Qt(){clearInterval(Ut)}function $t(t){var e=t.originalEvent,n=t.putSortable,o=t.dragEl,i=t.activeSortable,r=t.dispatchSortableEvent,a=t.hideGhostForTarget,l=t.unhideGhostForTarget;if(e){var s=n||i;a();var c=e.changedTouches&&e.changedTouches.length?e.changedTouches[0]:e,u=document.elementFromPoint(c.clientX,c.clientY);l(),s&&!s.el.contains(u)&&(r("spill"),this.onSpill({dragEl:o,putSortable:n}))}}var Jt,te=D(function(n,t,e,o){if(t.scroll){var i,r=(n.touches?n.touches[0]:n).clientX,a=(n.touches?n.touches[0]:n).clientY,l=t.scrollSensitivity,s=t.scrollSpeed,c=A(),u=!1;Kt!==e&&(Kt=e,Zt(),jt=t.scroll,i=t.scrollFn,!0===jt&&(jt=H(e,!0))
vendor: 5,137 bytes, line 9460
9460);var d=0,h=jt;do{var f=h,p=X(f),g=p.top,v=p.bottom,m=p.left,b=p.right,y=p.width,w=p.height,E=void 0,D=void 0,S=f.scrollWidth,_=f.scrollHeight,C=R(f),T=f.scrollLeft,x=f.scrollTop;D=f===c?(E=y<S&&("auto"===C.overflowX||"scroll"===C.overflowX||"visible"===C.overflowX),w<_&&("auto"===C.overflowY||"scroll"===C.overflowY||"visible"===C.overflowY)):(E=y<S&&("auto"===C.overflowX||"scroll"===C.overflowX),w<_&&("auto"===C.overflowY||"scroll"===C.overflowY));var M=E&&(Math.abs(b-r)<=l&&T+y<S)-(Math.abs(m-r)<=l&&!!T),O=D&&(Math.abs(v-a)<=l&&x+w<_)-(Math.abs(g-a)<=l&&!!x);if(!qt[d])for(var N=0;N<=d;N++)qt[N]||(qt[N]={});qt[d].vx==M&&qt[d].vy==O&&qt[d].el===f||(qt[d].el=f,qt[d].vx=M,qt[d].vy=O,clearInterval(qt[d].pid),0==M&&0==O||(u=!0,qt[d].pid=setInterval(function(){o&&0===this.layer&&Rt.active._onTouchMove(Gt);var t=qt[this.layer].vy?qt[this.layer].vy*s:0,e=qt[this.layer].vx?qt[this.layer].vx*s:0;"function"==typeof i&&"continue"!==i.call(Rt.dragged.parentNode[j],e,t,n,Gt,qt[this.layer].el)||L(qt[this.layer].el,e,t)}.bind({layer:d}),24))),d++}while(t.bubbleScroll&&h!==c&&(h=H(h,!1)));Vt=u}},30);function ee(){}function ne(){}ee.prototype={startIndex:null,dragStart:function(t){var e=t.oldDraggableIndex;this.startIndex=e},onSpill:function(t){var e=t.dragEl,n=t.putSortable;this.sortable.captureAnimationState(),n&&n.captureAnimationState();var o=m(this.sortable.el,this.startIndex,this.options);o?this.sortable.el.insertBefore(e,o):this.sortable.el.appendChild(e),this.sortable.animateAll(),n&&n.animateAll()},drop:$t},a(ee,{pluginName:"revertOnSpill"}),ne.prototype={onSpill:function(t){var e=t.dragEl,n=t.putSortable||this.sortable;n.captureAnimationState(),e.parentNode&&e.parentNode.removeChild(e),n.animateAll()},drop:$t},a(ne,{pluginName:"removeOnSpill"});var oe,ie,re,ae,le,se=[],ce=[],ue=!1,de=!1,he=!1;function fe(o,i){ce.forEach(function(t,e){var n=i.children[t.sortableIndex+(o?Number(e):0)];n?i.insertBefore(t,n):i.appendChild(t)})}function pe(){se.forEach(function(t){t!==re&&t.parentNode&&t.parentNode.removeChild(t)})}return Rt.mount(new function(){function t(){for(var t in this.defaults={scroll:!0,scrollSensitivity:30,scrollSpeed:10,bubbleScroll:!0},this)"_"===t.charAt(0)&&"function"==typeof this[t]&&(this[t]=this[t].bind(this))}return t.prototype={dragStarted:function(t){var e=t.originalEvent;this.sortable.nativeDraggable?d(document,"dragover",this._handleAutoScroll):this.options.supportPointer?d(document,"pointermove",this._handleFallbackAutoScroll):e.touches?d(document,"touchmove",this._handleFallbackAutoScroll):d(document,"mousemove",this._handleFallbackAutoScroll)},dragOverCompleted:function(t){var e=t.originalEvent;this.options.dragOverBubble||e.rootEl||this._handleAutoScroll(e)},drop:function(){this.sortable.nativeDraggable?s(document,"dragover",this._handleAutoScroll):(s(document,"pointermove",this._handleFallbackAutoScroll),s(document,"touchmove",this._handleFallbackAutoScroll),s(document,"mousemove",this._handleFallbackAutoScroll)),Qt(),Zt(),clearTimeout(f),f=void 0},nulling:function(){Gt=Kt=jt=Vt=Ut=Wt=zt=null,qt.length=0},_handleFallbackAutoScroll:function(t){this._handleAutoScroll(t,!0)},_handleAutoScroll:function(e,n){var o=this,i=(e.touches?e.touches[0]:e).clientX,r=(e.touches?e.touches[0]:e).clientY,t=document.elementFromPoint(i,r);if(Gt=e,n||E||w||u){te(e,this.options,t,n);var a=H(t,!0);!Vt||Ut&&i===Wt&&r===zt||(Ut&&Qt(),Ut=setInterval(function(){var t=H(document.elementFromPoint(i,r),!0);t!==a&&(a=t,Zt()),te(e,o.options,t,n)},10),Wt=i,zt=r)}else{if(!this.options.bubbleScroll||H(t,!0)===A())return void Zt();te(e,this.options,H(t,!1),!1)}}},a(t,{pluginName:"scroll",initializeByDefault:!0})}),Rt.mount(ne,ee),Rt.mount(new function(){function t(){this.defaults={swapClass:"sortable-swap-highlight"}}return t.prototype={dragStart:function(t){var e=t.dragEl;Jt=e},dragOverValid:function(t){var e=t.completed,n=t.target,o=t.onMove,i=t.activeSortable,r=t.changed,a=t.cancel;if(i.options.swap){var l=this.sortable.el,s=this.options;if(n&&n!==l){var c=Jt;Jt=!1!==o(n)?(k(n,s.swapClass,!0),n):null,c&&c!==Jt&&k(c,s.swapClass,!1)}r(),e(!0),a()}},drop:function(t){var e=t.activeSortable,n=t.putSortable,o=t.dragEl,i=n||this.sortable,r=this.options;Jt&&k(Jt,r.swapClass,!1),Jt&&(r.swap||n&&n.options.swap)&&o!==Jt&&(i.captureAnimationState(),i!==e&&e.captureAnimationState(),function(t,e){var n,o,i=t.parentNode,r=e.parentNode;if(!i||!r||i.isEqualNode(e)||r.isEqualNode(t))return;n=F(t),o=F(e),i.isEqualNode(r)&&n<o&&o++;i.insertBefore(e,i.children[n]),r.insertBefore(t,r.children[o])}(o,Jt),i.animateAll(),i!==e&&e.animateAll())},nulling:function(){Jt=null}},a(t,{pluginName:"swap",eventProperties:function(){return{swapItem:Jt}}})}),Rt.mount(new function(){function t(o){for(var t in this)"_"===t.charAt(0)&&"function"==typeof this[t]&&(this[t]=this[t].bind(this));o.options.supportPointer?d(document,"pointerup",this._deselectMultiDrag):(d(document,"mouseup",this._deselectMultiDrag),d(document,"touchend",this._deselectMultiDrag)),d(document,"keydown",this._checkKeyDown),d(document,"keyup",this._checkKeyUp),this.defaults={selectedClass:"sortable-selected",multiDragKey:null,
9460setData:function(t,e){var n="";se.length&&ie===o?se.forEach(function(t,e){n+=(e?", ":"")+t.textContent}):n=e.textContent,t.setData("Text",n)}}}return t.prototype={multiDragKeyDown:!1,isMultiDrag:!1,delayStartGlobal:function(t){var e=t.dragEl;re=e},delayEnded:function(){this.isMultiDrag=~se.indexOf(re)},setupClone:function(t){var e=t.sortable,n=t.cancel;if(this.isMultiDrag){for(var o=0;o<se.length;o++)ce.push(S(se[o])),ce[o].sortableIndex=se[o].sortableIndex,ce[o].draggable=!1,ce[o].style["will-change"]="",k(ce[o],this.options.selectedClass,!1),se[o]===re&&k(ce[o],this.options.chosenClass,!1);e._hideClone(),n()}},clone:function(t){var e=t.sortable,n=t.rootEl,o=t.dispatchSortableEvent,i=t.cancel;this.isMultiDrag&&(this.options.removeCloneOnHide||se.length&&ie===e&&(fe(!0,n),o("clone"),i()))},showClone:function(t){var e=t.cloneNowShown,n=t.rootEl,o=t.cancel;this.isMultiDrag&&(fe(!1,n),ce.forEach(function(t){R(t,"display","")}),e(),le=!1,o())},hideClone:function(t){var e=this,n=(t.sortable,t.cloneNowHidden),o=t.cancel;this.isMultiDrag&&(ce.forEach(function(t){R(t,"display","none"),e.options.removeCloneOnHide&&t.parentNode&&t.parentNode.removeChild(t)}),n(),le=!0,o())},dragStartGlobal:function(t){t.sortable;!this.isMultiDrag&&ie&&ie.multiDrag._deselectMultiDrag(),se.forEach(function(t){t.sortableIndex=F(t)}),se=se.sort(function(t,e){return t.sortableIndex-e.sortableIndex}),he=!0},dragStarted:function(t){var e=this,n=t.sortable;if(this.isMultiDrag){if(this.options.sort&&(n.captureAnimationState(),this.options.animation)){se.forEach(function(t){t!==re&&R(t,"position","absolute")});var o=X(re,!1,!0,!0);se.forEach(function(t){t!==re&&_(t,o)}),ue=de=!0}n.animateAll(function(){ue=de=!1,e.options.animation&&se.forEach(function(t){C(t)}),e.options.sort&&pe()})}},dragOver:function(t){var e=t.target,n=t.completed,o=t.cancel;de&&~se.indexOf(e)&&(n(!1),o())},revert:function(t){var e=t.fromSortable,n=t.rootEl,o=t.sortable,i=t.dragRect;1<se.length&&(se.forEach(function(t){o.addAnimationState({target:t,rect:de?X(t):i}),C(t),t.fromRect=i,e.removeAnimationState(t)}),de=!1,function(o,i){se.forEach(function(t,e){var n=i.children[t.sortableIndex+(o?Number(e):0)];n?i.insertBefore(t,n):i.appendChild(t)})}(!this.options.removeCloneOnHide,n))},dragOverCompleted:function(t){var e=t.sortable,n=t.isOwner,o=t.insertion,i=t.activeSortable,r=t.parentEl,a=t.putSortable,l=this.options;if(o){if(n&&i._hideClone(),ue=!1,l.animation&&1<se.length&&(de||!n&&!i.options.sort&&!a)){var s=X(re,!1,!0,!0);se.forEach(function(t){t!==re&&(_(t,s),r.appendChild(t))}),de=!0}if(!n)if(de||pe(),1<se.length){var c=le;i._showClone(e),i.options.animation&&!le&&c&&ce.forEach(function(t){i.addAnimationState({target:t,rect:ae}),t.fromRect=ae,t.thisAnimationDuration=null})}else i._showClone(e)}},dragOverAnimationCapture:function(t){var e=t.dragRect,n=t.isOwner,o=t.activeSortable;if(se.forEach(function(t){t.thisAnimationDuration=null}),o.options.animation&&!n&&o.multiDrag.isMultiDrag){ae=a({},e);var i=v(re,!0);ae.top-=i.f,ae.left-=i.e}},dragOverAnimationComplete:function(){de&&(de=!1,pe())},drop:function(t){var e=t.originalEvent,n=t.rootEl,o=t.parentEl,i=t.sortable,r=t.dispatchSortableEvent,a=t.oldIndex,l=t.putSortable,s=l||this.sortable;if(e){var c=this.options,u=o.children;if(!he)if(c.multiDragKey&&!this.multiDragKeyDown&&this._deselectMultiDrag(),k(re,c.selectedClass,!~se.indexOf(re)),~se.indexOf(re))se.splice(se.indexOf(re),1),oe=null,N({sortable:i,rootEl:n,name:"deselect",targetEl:re,originalEvt:e});else{if(se.push(re),N({sortable:i,rootEl:n,name:"select",targetEl:re,originalEvt:e}),e.shiftKey&&oe&&i.el.contains(oe)){var d,h,f=F(oe),p=F(re);if(~f&&~p&&f!==p)for(d=f<p?(h=f,p):(h=p,f+1);h<d;h++)~se.indexOf(u[h])||(k(u[h],c.selectedClass,!0),se.push(u[h]),N({sortable:i,rootEl:n,name:"select",targetEl:u[h],originalEvt:e}))}else oe=re;ie=s}if(he&&this.isMultiDrag){if((o[j].options.sort||o!==n)&&1<se.length){var g=X(re),v=F(re,":not(."+this.options.selectedClass+")");if(!ue&&c.animation&&(re.thisAnimationDuration=null),s.captureAnimationState(),!ue&&(c.animation&&(re.fromRect=g,se.forEach(function(t){if(t.thisAnimationDuration=null,t!==re){var e=de?X(t):g;t.fromRect=e,s.addAnimationState({target:t,rect:e})}})),pe(),se.forEach(function(t){u[v]?o.insertBefore(t,u[v]):o.appendChild(t),v++}),a===F(re))){var m=!1;se.forEach(function(t){t.sortableIndex===F(t)||(m=!0)}),m&&r("update")}se.forEach(function(t){C(t)}),s.animateAll()}ie=s}(n===o||l&&"clone"!==l.lastPutMode)&&ce.forEach(function(t){t.parentNode&&t.parentNode.removeChild(t)})}},nullingGlobal:function(){this.isMultiDrag=he=!1,ce.length=0}
9460,destroyGlobal:function(){this._deselectMultiDrag(),s(document,"pointerup",this._deselectMultiDrag),s(document,"mouseup",this._deselectMultiDrag),s(document,"touchend",this._deselectMultiDrag),s(document,"keydown",this._checkKeyDown),s(document,"keyup",this._checkKeyUp)},_deselectMultiDrag:function(t){if(!(void 0!==he&&he||ie!==this.sortable||t&&P(t.target,this.options.draggable,this.sortable.el,!1)||t&&0!==t.button))for(;se.length;){var e=se[0];k(e,this.options.selectedClass,!1),se.shift(),N({sortable:this.sortable,rootEl:this.sortable.el,name:"deselect",targetEl:e,originalEvt:t})}},_checkKeyDown:function(t){t.key===this.options.multiDragKey&&(this.multiDragKeyDown=!0)},_checkKeyUp:function(t){t.key===this.options.multiDragKey&&(this.multiDragKeyDown=!1)}},a(t,{pluginName:"multiDrag",utils:{select:function(t){var e=t.parentNode[j];e&&e.options.multiDrag&&!~se.indexOf(t)&&(ie&&ie!==e&&(ie.multiDrag._deselectMultiDrag(),ie=e),k(t,e.options.selectedClass,!0),se.push(t))},deselect:function(t){var e=t.parentNode[j],n=se.indexOf(t);e&&e.options.multiDrag&&~n&&(k(t,e.options.selectedClass,!1),se.splice(n,1))}},eventProperties:function(){var n=this,o=[],i=[];return se.forEach(function(t){var e;o.push({multiDragElement:t,index:t.sortableIndex}),e=de&&t!==re?-1:de?F(t,":not(."+n.options.selectedClass+")"):F(t),i.push({multiDragElement:t,index:e})}),{items:e(se),clones:[].concat(ce),oldIndicies:o,newIndicies:i}},optionListeners:{multiDragKey:function(t){return"ctrl"===(t=t.toLowerCase())?t="Control":1<t.length&&(t=t.charAt(0).toUpperCase()+t.substr(1)),t}}})}),Rt});; 9461/* AUTOGENERATED: jquery.mmenu.min.all.js */ 9462/* 9463 * jQuery mmenu v5.3.3 9464 * @requires jQuery 1.7.0 or later 9465 * 9466 * mmenu.frebsite.nl 9467 * 9468 * Copyright (c) Fred Heusschen 9469 * www.frebsite.nl 9470 * 9471 * Licensed under the MIT license: 9472 * http://en.wikipedia.org/wiki/MIT_License 9473 */ 9474!function(e){var t,n,s,a,i="mmenu";e[i]||(e[i]=function(e,t,n){this.$menu=e,this._api=["bind","init","update","setSelected","getInstance","openPanel","closePanel","closeAllPanels"],this.opts=t,this.conf=n,this.vars={},this.cbck={},"function"==typeof this.___deprecated&&this.___deprecated(),this._initMenu(),this._initAnchors();var s=this.$menu.children(this.conf.panelNodetype);return this._initAddons(),this.init(s),"function"==typeof this.___debug&&this.___debug(),this},e[i].version="5.3.3",e[i].addons={},e[i].uniqueId=0,e[i].defaults={extensions:[],navbar:{add:!0,title:"Menu",titleLink:"panel"},onClick:{setSelected:!0},slidingSubmenus:!0},e[i].configuration={classNames:{divider:"Divider",inset:"Inset",panel:"Panel",selected:"Selected",spacer:"Spacer",vertical:"Vertical"},clone:!1,openingInterval:25,panelNodetype:"ul, ol, div",transitionDuration:400},e[i].prototype={init:function(e){e=e.not("."+t.nopanel),e=this._initPanels(e),this.trigger("init",e),this.trigger("update")},update:function(){this.trigger("update")},setSelected:function(e){this.$menu.find("."+t.listview).children().removeClass(t.selected),e.addClass(t.selected),this.trigger("setSelected",e)},openPanel:function(e){var n=e.parent();if(n.hasClass(t.vertical)){var s=n.parents("."+t.subopened);if(s.length)return this.openPanel(s.first());n.addClass(t.opened)}else{if(e.hasClass(t.current))return;var a=this.$menu.children("."+t.panel),i=a.filter("."+t.current);a.removeClass(t.highest).removeClass(t.current).not(e).not(i).not("."+t.vertical).addClass(t.hidden),e.hasClass(t.opened)?e.nextAll("."+t.opened).addClass(t.highest).removeClass(t.opened).removeClass(t.subopened):(e.addClass(t.highest),i.addClass(t.subopened)),e.removeClass(t.hidden).addClass(t.current),setTimeout(function(){e.removeClass(t.subopened).addClass(t.opened)},this.conf.openingInterval)}this.trigger("openPanel",e)},closePanel:function(e){var n=e.parent();n.hasClass(t.vertical)&&(n.removeClass(t.opened),this.trigger("closePanel",e))},closeAllPanels:function(){this.$menu.find("."+t.listview).children().removeClass(t.selected).filter("."+t.vertical).removeClass(t.opened);var e=this.$menu.children("."+t.panel).first();this.$menu.children("."+t.panel).not(e).removeClass(t.subopened).removeClass(t.o
9474pened).removeClass(t.current).removeClass(t.highest).addClass(t.hidden),this.openPanel(e)},togglePanel:function(e){var n=e.parent();n.hasClass(t.vertical)&&this[n.hasClass(t.opened)?"closePanel":"openPanel"](e)},getInstance:function(){return this},bind:function(e,t){this.cbck[e]=this.cbck[e]||[],this.cbck[e].push(t)},trigger:function(){var e=Array.prototype.slice.call(arguments),t=e.shift();if(this.cbck[t])for(var n=0,s=this.cbck[t].length;n<s;n++)this.cbck[t][n].apply(this,e)},_initMenu:function(){this.opts.offCanvas&&this.conf.clone&&(this.$menu=this.$menu.clone(!0),this.$menu.add(this.$menu.find("[id]")).filter("[id]").each(function(){e(this).attr("id",t.mm(e(this).attr("id")))})),this.$menu.contents().each(function(){3==e(this)[0].nodeType&&e(this).remove()}),this.$menu.parent().addClass(t.wrapper);var n=[t.menu];this.opts.slidingSubmenus||n.push(t.vertical),this.opts.extensions=this.opts.extensions.length?"mm-"+this.opts.extensions.join(" mm-"):"",this.opts.extensions&&n.push(this.opts.extensions),this.$menu.addClass(n.join(" "))},_initPanels:function(s){var a=this,i=this.__findAddBack(s,"ul, ol");this.__refactorClass(i,this.conf.classNames.inset,"inset").addClass(t.nolistview+" "+t.nopanel),i.not("."+t.nolistview).addClass(t.listview);var l=this.__findAddBack(s,"."+t.listview).children();this.__refactorClass(l,this.conf.classNames.selected,"selected"),this.__refactorClass(l,this.conf.classNames.divider,"divider"),this.__refactorClass(l,this.conf.classNames.spacer,"spacer"),this.__refactorClass(this.__findAddBack(s,"."+this.conf.classNames.panel),this.conf.classNames.panel,"panel");var r=e(),d=s.add(s.find("."+t.panel)).add(this.__findAddBack(s,"."+t.listview).children().children(this.conf.panelNodetype)).not("."+t.nopanel);this.__refactorClass(d,this.conf.classNames.vertical,"vertical"),this.opts.slidingSubmenus||d.addClass(t.vertical),d.each(function(){var n=e(this),s=n;n.is("ul, ol")?(n.wrap('<div class="'+t.panel+'" />'),s=n.parent()):s.addClass(t.panel);var i=n.attr("id");n.removeAttr("id"),s.attr("id",i||a.__getUniqueId()),n.hasClass(t.vertical)&&(n.removeClass(a.conf.classNames.vertical),s.add(s.parent()).addClass(t.vertical)),r=r.add(s)});var o=e("."+t.panel,this.$menu);r.each(function(s){var i=e(this),l=(o=i.parent()).children("a, span").first();if(o.is("."+t.menu)||(o.data(n.sub,i),i.data(n.parent,o)),!o.children("."+t.next).length&&o.parent().is("."+t.listview)){var r=i.attr("id"),d=e('<a class="'+t.next+'" href="#'+r+'" data-target="#'+r+'"><span class="visually hidden">'+xcart.t('Open submenu').replace('{name}', l.text())+'</span></a>').insertBefore(l);l.is("span")&&d.addClass(t.fullsubopen)}if(!i.children("."+t.navbar).length&&!o.hasClass(t.vertical)){if(o.parent().is("."+t.listview))var o=o.closest("."+t.panel);else o=(l=o.closest("."+t.panel).find('a[href="#'+i.attr("id")+'"]').first()).closest("."+t.panel);var c=e('<div class="'+t.navbar+'" />');if(o.length){r=o.attr("id");switch(a.opts.navbar.titleLink){case"anchor":_url=l.attr("href");break;case"panel":case"parent":_url="#"+r;break;case"none":default:_url=!1}var h=document.createElement("a");h.className=t.title,h.textContent=l.text(),h.setAttribute('aria-hidden', (h.textContent ? 'false' : 'true')),h.textContent=(h.textContent ? h.textContent : xcart.t('Title')),_url&&(h.href=_url),c.append('<a class="'+t.btn+" "+t.prev+'" href="#'+r+'" data-target="#'+r+'"><span class="visually-hidden">'+xcart.t('Back')+'</span></a>').append(h).prependTo(i),a.opts.navbar.add&&i.addClass(t.hasnavbar)}else a.opts.navbar.title&&(c.append('<a class="'+t.title+'">'+a.opts.navbar.title+"</a>").prependTo(i),a.opts.navbar.add&&i.addClass(t.hasnavbar))}});var c=this.__findAddBack(s,"."+t.listview).children("."+t.selected).removeClass(t.selected).last().addClass(t.selected);c.add(c.parentsUntil("."+t.menu,"li")).filter("."+t.vertical).addClass(t.opened).end().not("."+t.vertical).each(function(){e(this).parentsUntil("."+t.menu,"."+t.panel).not("."+t.vertical).first().addClass(t.opened).parentsUntil("."+t.menu,"."+t.panel).not("."+t.vertical).first().addClass(t.opened).addClass(t.subopened)}
9474),c.children("."+t.panel).not("."+t.vertical).addClass(t.opened).parentsUntil("."+t.menu,"."+t.panel).not("."+t.vertical).first().addClass(t.opened).addClass(t.subopened);var h=o.filter("."+t.opened);return h.length||(h=r.first()),h.addClass(t.opened).last().addClass(t.current),r.not("."+t.vertical).not(h.last()).addClass(t.hidden).end().appendTo(this.$menu),r},_initAnchors:function(){var n=this;a.$body.on(s.click+"-oncanvas","a[href]",function(s){var l=e(this),r=!1,d=n.$menu.find(l).length;for(var o in e[i].addons)if(r=e[i].addons[o].clickAnchor.call(n,l,d))break;if(!r&&d){var c=l.attr("href");if(c.length>1&&"#"==c.slice(0,1))try{var h=e(c,n.$menu);h.is("."+t.panel)&&(r=!0,n[l.parent().hasClass(t.vertical)?"togglePanel":"openPanel"](h))}catch(e){}}if(r&&s.preventDefault(),!r&&d&&l.is("."+t.listview+" > li > a")&&!l.is('[rel="external"]')&&!l.is('[target="_blank"]')){n.__valueOrFn(n.opts.onClick.setSelected,l)&&n.setSelected(e(s.target).parent());var u=n.__valueOrFn(n.opts.onClick.preventDefault,l,"#"==c.slice(0,1));u&&s.preventDefault(),n.__valueOrFn(n.opts.onClick.blockUI,l,!u)&&a.$html.addClass(t.blocking),n.__valueOrFn(n.opts.onClick.close,l,u)&&n.close()}})},_initAddons:function(){for(var t in e[i].addons)e[i].addons[t].add.call(this),e[i].addons[t].add=function(){};for(var t in e[i].addons)e[i].addons[t].setup.call(this)},__api:function(){var t=this,n={};return e.each(this._api,function(e){var s=this;n[s]=function(){var e=t[s].apply(t,arguments);return void 0===e?n:e}}),n},__valueOrFn:function(e,t,n){return"function"==typeof e?e.call(t[0]):void 0===e&&void 0!==n?n:e},__refactorClass:function(e,n,s){return e.filter("."+n).removeClass(n).addClass(t[s])},__findAddBack:function(e,t){return e.find(t).add(e.filter(t))},__filterListItems:function(e){return e.not("."+t.divider).not("."+t.hidden)},__transitionend:function(e,t,n){var a=!1,i=function(){a||t.call(e[0]),a=!0};e.one(s.transitionend,i),e.one(s.webkitTransitionEnd,i),setTimeout(i,1.1*n)},__getUniqueId:function(){return t.mm(e[i].uniqueId++)}},e.fn[i]=function(l,r){return function(){if(e[i].glbl)return;a={$wndw:e(window),$html:e("html"),$body:e("body")},t={},n={},s={},e.each([t,n,s],function(e,t){t.add=function(e){e=e.split(" ");for(var n=0,s=e.length;n<s;n++)t[e[n]]=t.mm(e[n])}}),t.mm=function(e){return"mm-"+e},t.add("wrapper menu panel nopanel current highest opened subopened navbar hasnavbar title btn prev next listview nolistview inset vertical selected divider spacer hidden fullsubopen"),t.umm=function(e){return"mm-"==e.slice(0,3)&&(e=e.slice(3)),e},n.mm=function(e){return"mm-"+e},n.add("parent sub"),s.mm=function(e){return e+".mm"},s.add("transitionend webkitTransitionEnd mousedown mouseup touchstart touchmove touchend click keydown"),e[i]._c=t,e[i]._d=n,e[i]._e=s,e[i].glbl=a}(),l=e.extend(!0,{},e[i].defaults,l),r=e.extend(!0,{},e[i].configuration,r),this.each(function(){var t=e(this);if(!t.data(i)){var n=new e[i](t,l,r);t.data(i,n.__api())}})},e[i].support={touch:"ontouchstart"in window||navigator.msMaxTouchPoints})}(jQuery); 9475/* 9476 * jQuery mmenu offCanvas addon 9477 * mmenu.frebsite.nl 9478 * 9479 * Copyright (c) Fred Heusschen 9480 */ 9481!function(t){var e="mmenu",o="offCanvas";t[e].addons[o]={setup:function(){if(this.opts[o]){var n=this.opts[o],i=this.conf[o];a=t[e].glbl,this._api=t.merge(this._api,["open","close","setPage"]),("top"==n.position||"bottom"==n.position)&&(n.zposition="front"),"string"!=typeof i.pageSelector&&(i.pageSelector="> "+i.pageNodetype),a.$allMenus=(a.$allMenus||t()).add(this.$menu),this.vars.opened=!1;var r=[s.offcanvas];"left"!=n.position&&r.push(s.mm(n.position)),"back"!=n.zposition&&r.push(s.mm(n.zposition)),this.$menu.addClass(r.join(" ")).parent().removeClass(s.wrapper),this.setPage(a.$page),this._initBlocker(),this["_initWindow_"+o](),this.$menu[i.menuInjectMethod+"To"](i.menuWrapperSelector)}},add:function(){s=t[e]._c,n=t[e]._d,i=t[e]._e,s.add("offcanvas slideout modal background opening blocker page"),n.add("style"),i.add("resize")},clickAnchor:function(t){if(!this.opts[o])return!1;var e=this.$menu.attr("id");if(e&&e.length&&(this.conf.clone&&(e=s.umm(e)),t.is('[href="#'+e+'"]')))return this.open(),!0;if(a.$page){var e=a.$page.first().attr("id");return e&&e.length&&t.is('[href="#'+e+'"]')?(this.close(),!0):!1}}},t[e].defaults[o]={position:"left",zposition:"back",modal:!1,moveBackgroun
9481d:!0},t[e].configuration[o]={pageNodetype:"div",pageSelector:null,wrapPageIfNeeded:!0,menuWrapperSelector:"body",menuInjectMethod:"prepend"},t[e].prototype.open=function(){if(!this.vars.opened){var t=this;this._openSetup(),setTimeout(function(){t._openFinish()},this.conf.openingInterval),this.trigger("open")}},t[e].prototype._openSetup=function(){var e=this;this.closeAllOthers(),a.$page.each(function(){t(this).data(n.style,t(this).attr("style")||"")}),a.$wndw.trigger(i.resize+"-offcanvas",[!0]);var r=[s.opened];this.opts[o].modal&&r.push(s.modal),this.opts[o].moveBackground&&r.push(s.background),"left"!=this.opts[o].position&&r.push(s.mm(this.opts[o].position)),"back"!=this.opts[o].zposition&&r.push(s.mm(this.opts[o].zposition)),this.opts.extensions&&r.push(this.opts.extensions),a.$html.addClass(r.join(" ")),setTimeout(function(){e.vars.opened=!0},this.conf.openingInterval),this.$menu.addClass(s.current+" "+s.opened)},t[e].prototype._openFinish=function(){var t=this;this.__transitionend(a.$page.first(),function(){t.trigger("opened")},this.conf.transitionDuration),a.$html.addClass(s.opening),this.trigger("opening")},t[e].prototype.close=function(){if(this.vars.opened){var e=this;this.__transitionend(a.$page.first(),function(){e.$menu.removeClass(s.current).removeClass(s.opened),a.$html.removeClass(s.opened).removeClass(s.modal).removeClass(s.background).removeClass(s.mm(e.opts[o].position)).removeClass(s.mm(e.opts[o].zposition)),e.opts.extensions&&a.$html.removeClass(e.opts.extensions),a.$page.each(function(){t(this).attr("style",t(this).data(n.style))}),e.vars.opened=!1,e.trigger("closed")},this.conf.transitionDuration),a.$html.removeClass(s.opening),this.trigger("close"),this.trigger("closing")}},t[e].prototype.closeAllOthers=function(){a.$allMenus.not(this.$menu).each(function(){var o=t(this).data(e);o&&o.close&&o.close()})},t[e].prototype.setPage=function(e){var n=this,i=this.conf[o];e&&e.length||(e=a.$body.find(i.pageSelector),e.length>1&&i.wrapPageIfNeeded&&(e=e.wrapAll("<"+this.conf[o].pageNodetype+" />").parent())),e.each(function(){t(this).attr("id",t(this).attr("id")||n.__getUniqueId())}),e.addClass(s.page+" "+s.slideout),a.$page=e,this.trigger("setPage",e)},t[e].prototype["_initWindow_"+o]=function(){a.$wndw.off(i.keydown+"-offcanvas").on(i.keydown+"-offcanvas",function(t){return a.$html.hasClass(s.opened)&&9==t.keyCode?(t.preventDefault(),!1):void 0});var t=0;a.$wndw.off(i.resize+"-offcanvas").on(i.resize+"-offcanvas",function(e,o){if(1==a.$page.length&&(o||a.$html.hasClass(s.opened))){var n=a.$wndw.height();(o||n!=t)&&(t=n,a.$page.css("minHeight",n))}})},t[e].prototype._initBlocker=function(){var e=this;a.$blck||(a.$blck=t('<div id="'+s.blocker+'" class="'+s.slideout+'" />')),a.$blck.appendTo(a.$body).off(i.touchstart+"-offcanvas "+i.touchmove+"-offcanvas").on(i.touchstart+"-offcanvas "+i.touchmove+"-offcanvas",function(t){t.preventDefault(),t.stopPropagation(),a.$blck.trigger(i.mousedown+"-offcanvas")}).off(i.mousedown+"-offcanvas").on(i.mousedown+"-offcanvas",function(t){t.preventDefault(),a.$html.hasClass(s.modal)||(e.closeAllOthers(),e.close())})};var s,n,i,a}(jQuery); 9482/* 9483 * jQuery mmenu autoHeight addon 9484 * mmenu.frebsite.nl 9485 * 9486 * Copyright (c) Fred Heusschen 9487 */ 9488!function(t){var e="mmenu",i="autoHeight";t[e].addons[i]={setup:function(){if(this.opts.offCanvas){switch(this.opts.offCanvas.position){case"left":case"right":return}var n=this,o=this.opts[i];if(this.conf[i],h=t[e].glbl,"boolean"==typeof o&&o&&(o={height:"auto"}),"object"!=typeof o&&(o={}),o=this.opts[i]=t.extend(!0,{},t[e].defaults[i],o),"auto"==o.height){this.$menu.addClass(s.autoheight);var u=function(t){var e=this.$menu.children("."+s.current);_top=parseInt(e.css("top"),10)||0,_bot=parseInt(e.css("bottom"),10)||0,this.$menu.addClass(s.measureheight),t=t||this.$menu.children("."+s.current),t.is("."+s.vertical)&&(t=t.parents("."+s.panel).not("."+s.vertical).first()),this.$menu.height(t.outerHeight()+_top+_bot).removeClass(s.measureheight)};this.bind("update",u),this.bind("openPanel",u),this.bind("closePanel",u),this.bind("open",u),h.$wndw.off(a.resize+"-autoheight").on(a.resize+"-autoheight",function(){u.call(n)})}}},add:function(){s=t[e]._c,n=t[e]._d,a=t[e]._e,s.add("autoheight measureheight"),a.add("resize")},clickAnchor:function(){}},t[e].defaults[i]={height:"default"};var s,n,a,h}(jQuery); 9489/* 9490 * jQuery mmenu backButton addon 9491 * mmenu.frebsite.nl 9492 * 9493 * Copyright (c) Fred Heusschen 9494 */ 9495!function(o){var t="mmenu",n="backButton";o[t].addons[n]={setup:function(){if(this.opts.offCanvas){var i=this,e=this.opts[n];if(this.conf[n],a=o[t].glbl,"boolean"==typeof e&&(e={close:e}),"object"!=typeof e&&(e={}),e=o.extend(!0,{},o[t].defaults[n],e),e.close){var c="#"+i.$menu.attr("id");this.bind("opened",function(){location.hash!=c&&history.pushState(null,document.title,c)}),o(window).on("popstate",function(o){a.$html.hasClass(s.opened)?(o.stopPropagation(),i.close()):location.hash==c&&(o.stopPropagation(),i.open())})}}},add:function(){return window.history&&window.history.pushState?(s=o[t]._c,i=o[t]._d,e=o[t]._e,void 0):(o[t].addons[n].setup=function(){},void 0)},clickAnchor:function(){}},o[t].defaults[n]={close:!1};var s,i,e,a}(jQuery); 9496/* 9497 * jQuery mmenu counters addon 9498 * mmenu.frebsite.nl 9499 * 9500 * Copyright (c) Fred Heusschen 9501 */ 9502!function(t){var n="mmenu",e="counters";t[n].addons[e]={setup:function(){var c=this,o=this.opts[e];this.conf[e],s=t[n].glbl,"boolean"==typeof o&&(o={add:o,update:o}),"object"!=typeof o&&(o={}),o=this.opts[e]=t.extend(!0,{},t[n].defaults[e],o),this.bind("init",function(n){this.__refactorClass(t("em",n),this.conf.classNames[e].counter,"counter")}),o.add&&this.bind("init",function(n){n.each(function(){var n=t(this).data(a.parent);
9502n&&(n.children("em."+i.counter).length||n.prepend(t('<em class="'+i.counter+'" />')))})}),o.update&&this.bind("update",function(){this.$menu.find("."+i.panel).each(function(){var n=t(this),e=n.data(a.parent);if(e){var s=e.children("em."+i.counter);s.length&&(n=n.children("."+i.listview),n.length&&s.html(c.__filterListItems(n.children()).length))}})})},add:function(){i=t[n]._c,a=t[n]._d,c=t[n]._e,i.add("counter search noresultsmsg")},clickAnchor:function(){}},t[n].defaults[e]={add:!1,update:!1},t[n].configuration.classNames[e]={counter:"Counter"};var i,a,c,s}(jQuery); 9503/* 9504 * jQuery mmenu dividers addon 9505 * mmenu.frebsite.nl 9506 * 9507 * Copyright (c) Fred Heusschen 9508 */ 9509!function(i){var e="mmenu",s="dividers";i[e].addons[s]={setup:function(){var n=this,a=this.opts[s];if(this.conf[s],l=i[e].glbl,"boolean"==typeof a&&(a={add:a,fixed:a}),"object"!=typeof a&&(a={}),a=this.opts[s]=i.extend(!0,{},i[e].defaults[s],a),this.bind("init",function(){this.__refactorClass(i("li",this.$menu),this.conf.classNames[s].collapsed,"collapsed")}),a.add&&this.bind("init",function(e){switch(a.addTo){case"panels":var s=e;break;default:var s=i(a.addTo,this.$menu).filter("."+d.panel)}i("."+d.divider,s).remove(),s.find("."+d.listview).not("."+d.vertical).each(function(){var e="";n.__filterListItems(i(this).children()).each(function(){var s=i.trim(i(this).children("a, span").text()).slice(0,1).toLowerCase();s!=e&&s.length&&(e=s,i('<li class="'+d.divider+'">'+s+"</li>").insertBefore(this))})})}),a.collapse&&this.bind("init",function(e){i("."+d.divider,e).each(function(){var e=i(this),s=e.nextUntil("."+d.divider,"."+d.collapsed);s.length&&(e.children("."+d.subopen).length||(e.wrapInner("<span />"),e.prepend('<a href="#" class="'+d.subopen+" "+d.fullsubopen+'" />')))})}),a.fixed){var o=function(e){e=e||this.$menu.children("."+d.current);var s=e.find("."+d.divider).not("."+d.hidden);if(s.length){this.$menu.addClass(d.hasdividers);var n=e.scrollTop()||0,t="";e.is(":visible")&&e.find("."+d.divider).not("."+d.hidden).each(function(){i(this).position().top+n<n+1&&(t=i(this).text())}),this.$fixeddivider.text(t)}else this.$menu.removeClass(d.hasdividers)};this.$fixeddivider=i('<ul class="'+d.listview+" "+d.fixeddivider+'"><li class="'+d.divider+'"></li></ul>').prependTo(this.$menu).children(),this.bind("openPanel",o),this.bind("init",function(e){e.off(t.scroll+"-dividers "+t.touchmove+"-dividers").on(t.scroll+"-dividers "+t.touchmove+"-dividers",function(){o.call(n,i(this))})})}},add:function(){d=i[e]._c,n=i[e]._d,t=i[e]._e,d.add("collapsed uncollapsed fixeddivider hasdividers"),t.add("scroll")},clickAnchor:function(i,e){if(this.opts[s].collapse&&e){var n=i.parent();if(n.is("."+d.divider)){var t=n.nextUntil("."+d.divider,"."+d.collapsed);return n.toggleClass(d.opened),t[n.hasClass(d.opened)?"addClass":"removeClass"](d.uncollapsed),!0}}return!1}},i[e].defaults[s]={add:!1,addTo:"panels",fixed:!1,collapse:!1},i[e].configuration.classNames[s]={collapsed:"Collapsed"};var d,n,t,l}(jQuery); 9510/* 9511 * jQuery mmenu dragOpen addon 9512 * mmenu.frebsite.nl 9513 * 9514 * Copyright (c) Fred Heusschen 9515 */ 9516!function(e){function t(e,t,n){return t>e&&(e=t),e>n&&(e=n),e}var n="mmenu",o="dragOpen";e[n].addons[o]={setup:function(){if(this.opts.offCanvas){var i=this,a=this.opts[o],p=this.conf[o];if(r=e[n].glbl,"boolean"==typeof a&&(a={open:a}),"object"!=typeof a&&(a={}),a=this.opts[o]=e.extend(!0,{},e[n].defaults[o],a),a.open){var d,f,c,u,h,l={},m=0,g=!1,v=!1,w=0,_=0;switch(this.opts.offCanvas.position){case"left":case"right":l.events="panleft panright",l.typeLower="x",l.typeUpper="X",v="width";break;case"top":case"bottom":l.events="panup pandown",l.typeLower="y",l.typeUpper="Y",v="height"}switch(this.opts.offCanvas.position){case"right":case"bottom":l.negative=!0,u=function(e){e>=r.$wndw[v]()-a.maxStartPos&&(m=1)};break;default:l.negative=!1,u=function(e){e<=a.maxStartPos&&(m=1)}}switch(this.opts.offCanvas.position){case"left":l.open_dir="right",l.close_dir="left";break;case"right":l.open_dir="left",l.close_dir="right";break;case"top":l.open_dir="down",l.close_dir="up";break;case"bottom":l.open_dir="up",l.close_dir="down"}switch(this.opts.offCanvas.zposition){case"front":h=function(){return this.$menu};break;default:h=function(){return e("."+s.slideout)}}var b=this.__valueOrFn(a.pageNode,this.$menu,r.$page);"string"==typeof b&&(b=e(b));var y=new Hammer(b[0],a.vendors.hammer);y.on("panstart",function(e){u(e.center[l.typeLower]),r.$slideOutNodes=h(),g=l.open_dir}).on(l.events+" panend",function(e){m>0&&e.preventDefault()}).on(l.events,function(e){if(d=e["delta"+l.typeUpper],l.negative&&(d=-d),d!=w&&(g=d>=w?l.open_dir:l.close_dir),w=d,w>a.threshold&&1==m){if(r.$html.hasClass(s.opened))return;m=2,i._openSetup(),i.trigger("opening"),r.$html.addClass(s.dragging),_=t(r.$wndw[v]()*p[v].perc,p[v].min,p[v].max)}2==m&&(f=t(w,10,_)-("front"==i.opts.offCanvas.zposition?_:0),l.negative&&(f=-f),c="translate"+l.typeUpper+"("+f+"px )",r.$slideOutNodes.css({"-webkit-transform":"-webkit-"+c,transform:c}))}).on("panend",function(){2==m&&(r.$html.removeClass(s.dragging),r.$slideOutNodes.css("transform",""),i[g==l.open_dir?"_openFinish":"close"]()),m=0})}}},add:function(){return"function"!=typeof Hammer||Hammer.VERSION<2?(e[n].addons[o].setup=function(){},void 0):(s=e[n]._c,i=e[n]._d,a=e[n]._e,s.add("dragging"),void 0)},clickAnchor:function(){}},e[n].defaults[o]={open:!1,maxStartPos:100,threshold:50,vendors:{hammer
9516:{}}},e[n].configuration[o]={width:{perc:.8,min:140,max:440},height:{perc:.8,min:140,max:880}};var s,i,a,r}(jQuery); 9517/* 9518 * jQuery mmenu fixedElements addon 9519 * mmenu.frebsite.nl 9520 * 9521 * Copyright (c) Fred Heusschen 9522 */ 9523!function(i){var s="mmenu",n="fixedElements";i[s].addons[n]={setup:function(){if(this.opts.offCanvas){this.opts[n],this.conf[n],o=i[s].glbl;var a=function(i){var s=this.conf.classNames[n].fixed;this.__refactorClass(i.find("."+s),s,"slideout").appendTo(o.$body)};a.call(this,o.$page),this.bind("setPage",a)}},add:function(){a=i[s]._c,t=i[s]._d,e=i[s]._e,a.add("fixed")},clickAnchor:function(){}},i[s].configuration.classNames[n]={fixed:"Fixed"};var a,t,e,o}(jQuery); 9524/* 9525 * jQuery mmenu iconPanels addon 9526 * mmenu.frebsite.nl 9527 * 9528 * Copyright (c) Fred Heusschen 9529 */ 9530!function(e){var n="mmenu",i="iconPanels";e[n].addons[i]={setup:function(){var a=this,l=this.opts[i];if(this.conf[i],d=e[n].glbl,"boolean"==typeof l&&(l={add:l}),"number"==typeof l&&(l={add:!0,visible:l}),"object"!=typeof l&&(l={}),l=this.opts[i]=e.extend(!0,{},e[n].defaults[i],l),l.visible++,l.add){this.$menu.addClass(s.iconpanel);for(var t=[],o=0;o<=l.visible;o++)t.push(s.iconpanel+"-"+o);t=t.join(" ");var c=function(n){var i=a.$menu.children("."+s.panel).removeClass(t),d=i.filter("."+s.subopened);d.removeClass(s.hidden).add(n).slice(-l.visible).each(function(n){e(this).addClass(s.iconpanel+"-"+n)})};this.bind("openPanel",c),this.bind("init",function(n){c.call(a,a.$menu.children("."+s.current)),l.hideNavbars&&n.removeClass(s.hasnavbar),n.each(function(){e(this).children("."+s.subblocker).length||e(this).prepend('<a href="#'+e(this).closest("."+s.panel).attr("id")+'" class="'+s.subblocker+'" />')})})}},add:function(){s=e[n]._c,a=e[n]._d,l=e[n]._e,s.add("iconpanel subblocker")},clickAnchor:function(){}},e[n].defaults[i]={add:!1,visible:3,hideNavbars:!1};var s,a,l,d}(jQuery); 9531/* 9532 * jQuery mmenu navbar addon 9533 * mmenu.frebsite.nl 9534 * 9535 * Copyright (c) Fred Heusschen 9536 */ 9537!function(n){var a="mmenu",e="navbars";n[a].addons[e]={setup:function(){var r=this,i=this.opts[e],c=this.conf[e];if(s=n[a].glbl,"undefined"!=typeof i){i instanceof Array||(i=[i]);var d={};n.each(i,function(s){var o=i[s];"boolean"==typeof o&&o&&(o={}),"object"!=typeof o&&(o={}),"undefined"==typeof o.content&&(o.content=["prev","title"]),o.content instanceof Array||(o.content=[o.content]),o=n.extend(!0,{},r.opts.navbar,o);var l=o.position,h=o.height;"number"!=typeof h&&(h=1),h=Math.min(4,Math.max(1,h)),"bottom"!=l&&(l="top"),d[l]||(d[l]=0),d[l]++;var f=n("<div />").addClass(t.navbar+" "+t.navbar+"-"+l+" "+t.navbar+"-"+l+"-"+d[l]+" "+t.navbar+"-size-"+h);d[l]+=h-1;for(var v=0,u=o.content.length;u>v;v++){var p=n[a].addons[e][o.content[v]]||!1;p?p.call(r,f,o,c):(p=o.content[v],p instanceof n||(p=n(o.content[v])),p.each(function(){f.append(n(this))}))}var b=Math.ceil(f.children().not("."+t.btn).length/h);b>1&&f.addClass(t.navbar+"-content-"+b),f.children("."+t.btn).length&&f.addClass(t.hasbtns),f.prependTo(r.$menu)});for(var o in d)r.$menu.addClass(t.hasnavbar+"-"+o+"-"+d[o])}},add:function(){t=n[a]._c,r=n[a]._d,i=n[a]._e,t.add("close hasbtns")},clickAnchor:function(){}},n[a].configuration[e]={breadcrumbSeparator:"/"},n[a].configuration.classNames[e]={panelTitle:"Title",panelNext:"Next",panelPrev:"Prev"};var t,r,i,s}(jQuery),/* 9538 * jQuery mmenu navbar addon breadcrumbs content 9539 * mmenu.frebsite.nl 9540 * 9541 * Copyright (c) Fred Heusschen 9542 */ 9543 function(n){var a="mmenu",e="navbars",t="breadcrumbs";n[a].addons[e][t]=function(e,t,r){var i=n[a]._c,s=n[a]._d;i.add("breadcrumbs separator"),e.append('<span class="'+i.breadcrumbs+'"></span>'),this.bind("init",function(a){a.removeClass(i.hasnavbar).each(function(){for(var a=[],e=n(this),t=n('<span class="'+i.breadcrumbs+'"></span>'),c=n(this).children().first(),d=!0;c&&c.length;){c.is("."+i.panel)||(c=c.closest("."+i.panel));var o=c.children("."+i.navbar).children("."+i.title).text();a.unshift(d?"<span>"+o+"</span>":'<a href="#'+c.attr("id")+'">'+o+"</a>"),d=!1,c=c.data(s.parent)}t.append(a.join('<span class="'+i.separator+'">'+r.breadcrumbSeparator+"</span>")).appendTo(e.children("."+i.navbar))})});var c=function(){var n=this.$menu.children("."+i.current),a=e.find("."+i.breadcrumbs),t=n.children("."+i.navbar).children("."+i.breadcrumbs);a.html(t.html())};this.bind("openPanel",c),this.bind("init",c)}}(jQuery),/* 9544 * jQuery mmenu navbar addon close content 9545 * mmenu.frebsite.nl 9546 * 9547 * Copyright (c) Fred Heusschen 9548 */ 9549 function(n){var a="mmenu",e="navbars",t="close";n[a].addons[e][t]=function(e){var t=n[a]._c,r=n[a].glbl;e.append('<a class="'+t.close+" "+t.btn+'" href="#"></a>');var i=function(n){e.find("."+t.close).attr("href","#"+n.attr("id"))};i.call(this,r.$page),this.bind("setPage",i)}}(jQuery),/* 9550 * jQuery mmenu navbar addon next content 9551 * mmenu.frebsite.nl 9552 * 9553 * Copyright (c) Fred Heusschen 9554 */ 9555 function(n){var a="mmenu",e="navbars",t="next";n[a].addons[e][t]=function(t){var r=n[a]._c;t.append('<a class="'+r.next+" "+r.btn+'" href="#"></a>');var i=function(n){n=n||this.$menu.children("."+r.current);var a=t.find("."+r.next),i=n.find("."+this.conf.classNames[e].panelNext),s=i.attr("href"),c=i.html();a[s?"attr":"removeAttr"]("href",s),a[s||c?"removeClass":"addClass"](r.hidden),a.html(c)};this.bind("openPanel",i),this.bind("init",function(){i.call(this)})}}(jQuery),/* 9556 * jQuery mmenu navbar addon prev content 9557 * mmenu.frebsite.nl 9558 * 9559 * Copyright (c) Fred Heusschen 9560 */ 9561 function(n){var a="mmenu",e="navbars",t="prev";n[a].addons[e][t]=function(t){var r=n[a]._c;t.append('<a class="'+r.prev+" "+r.btn+'" href="#"></a>'),this.bind("init",function(n){n.removeClass(r.hasnavbar)});var i=function(){var n=this.$menu.children("."+r.current),a=t.find("."+r.prev),i=n.find("."+this.conf.classNames[e].panelPrev);i.length||(i=n.children("."+r.navbar).children("."+r.prev));var s=i.attr("href"),c=i.html();a[s?"attr":"removeAttr"]("href",s),a[s||c?"removeClass":"addClass"](r.hidden),a.html(c)};this.bind("openPanel",i),this.bind("init",i)}}(jQuery),/* 9562 * jQuery mmenu navbar addon searchfield content 9563 * mmenu.frebsite.nl 9564 * 9565 * Copyright (c) Fred Heusschen 9566 */ 9567 function(n){var a="mmenu",e="navbars",t="searchfield";n[a].addons[e][t]=function(e){var t=n[a]._c,r=n('<div class="'+t.search+'" />').appendTo(e);"object"!=typeof this.opts.searchfield&&(this.opts.searchfield={}),this.opts.searchfield.add=!0,this.opts.searchfield.addTo=r}}(jQuery),/* 9568 * jQuery mmenu navbar addon title content 9569 * mmenu.frebsite.nl 9570 * 9571 * Copyright (c) Fred Heusschen 9572 */ 9573 function(n){var a="mmenu",e="navbars",t="title";n[a].addons[e][t]=function(t,r){var i=n[a]._c;t.append('<a class="'+i.title+'"></a>');var s=function(n){n=n||this.$menu.children("."+i.current);var a=t.find("."+i.title),s=n.find("."+this.conf.classNames[e].panelTitle);s.length||(s=n.children("."+i.navbar).children("."+i.title));var c=s.attr("href"),d=s.html()||r.title;a[c?"attr":"removeAttr"]("href",c),a[c||d?"removeClass":"addClass"](i.hidden),a.html(d)};
9573this.bind("openPanel",s),this.bind("init",function(){s.call(this)})}}(jQuery); 9574/* 9575 * jQuery mmenu searchfield addon 9576 * mmenu.frebsite.nl 9577 * 9578 * Copyright (c) Fred Heusschen 9579 */ 9580!function(e){function s(e){switch(e){case 9:case 16:case 17:case 18:case 37:case 38:case 39:case 40:return!0}return!1}var n="mmenu",a="searchfield";e[n].addons[a]={setup:function(){var o=this,d=this.opts[a],c=this.conf[a];r=e[n].glbl,"boolean"==typeof d&&(d={add:d}),"object"!=typeof d&&(d={}),d=this.opts[a]=e.extend(!0,{},e[n].defaults[a],d),this.bind("close",function(){this.$menu.find("."+t.search).find("input").blur()}),this.bind("init",function(n){if(d.add){switch(d.addTo){case"panels":var a=n;break;default:var a=e(d.addTo,this.$menu)}a.each(function(){var s=e(this);if(!s.is("."+t.panel)||!s.is("."+t.vertical)){if(!s.children("."+t.search).length){var n=c.form?"form":"div",a=e("<"+n+' class="'+t.search+'" />');if(c.form&&"object"==typeof c.form)for(var l in c.form)a.attr(l,c.form[l]);a.append('<input placeholder="'+d.placeholder+'" type="text" autocomplete="off" />'),s.hasClass(t.search)?s.replaceWith(a):s.prepend(a).addClass(t.hassearch)}if(d.noResults){var i=s.closest("."+t.panel).length;if(i||(s=o.$menu.children("."+t.panel).first()),!s.children("."+t.noresultsmsg).length){var r=s.children("."+t.listview).first();e('<div class="'+t.noresultsmsg+'" />').append(d.noResults)[r.length?"insertAfter":"prependTo"](r.length?r:s)}}}}),d.search&&e("."+t.search,this.$menu).each(function(){var n=e(this),a=n.closest("."+t.panel).length;if(a)var r=n.closest("."+t.panel),c=r;else var r=e("."+t.panel,o.$menu),c=o.$menu;var h=n.children("input"),u=o.__findAddBack(r,"."+t.listview).children("li"),f=u.filter("."+t.divider),p=o.__filterListItems(u),v="> a",m=v+", > span",b=function(){var s=h.val().toLowerCase();r.scrollTop(0),p.add(f).addClass(t.hidden).find("."+t.fullsubopensearch).removeClass(t.fullsubopen).removeClass(t.fullsubopensearch),p.each(function(){var n=e(this),a=v;(d.showTextItems||d.showSubPanels&&n.find("."+t.next))&&(a=m),e(a,n).text().toLowerCase().indexOf(s)>-1&&n.add(n.prevAll("."+t.divider).first()).removeClass(t.hidden)}),d.showSubPanels&&r.each(function(){var s=e(this);o.__filterListItems(s.find("."+t.listview).children()).each(function(){var s=e(this),n=s.data(l.sub);s.removeClass(t.nosubresults),n&&n.find("."+t.listview).children().removeClass(t.hidden)})}),e(r.get().reverse()).each(function(s){var n=e(this),i=n.data(l.parent);i&&(o.__filterListItems(n.find("."+t.listview).children()).length?(i.hasClass(t.hidden)&&i.children("."+t.next).not("."+t.fullsubopen).addClass(t.fullsubopen).addClass(t.fullsubopensearch),i.removeClass(t.hidden).removeClass(t.nosubresults).prevAll("."+t.divider).first().removeClass(t.hidden)):a||(n.hasClass(t.opened)&&setTimeout(function(){o.openPanel(i.closest("."+t.panel))},1.5*(s+1)*o.conf.openingInterval),i.addClass(t.nosubresults)))}),c[p.not("."+t.hidden).length?"removeClass":"addClass"](t.noresults),this.update()};h.off(i.keyup+"-searchfield "+i.change+"-searchfield").on(i.keyup+"-searchfield",function(e){s(e.keyCode)||b.call(o)}).on(i.change+"-searchfield",function(){b.call(o)})})}})},add:function(){t=e[n]._c,l=e[n]._d,i=e[n]._e,t.add("search hassearch noresultsmsg noresults nosubresults fullsubopensearch"),i.add("change keyup")},clickAnchor:function(){}},e[n].defaults[a]={add:!1,addTo:"panels",search:!0,placeholder:"Search",noResults:"No results found.",showTextItems:!1,showSubPanels:!0},e[n].configuration[a]={form:!1};var t,l,i,r}(jQuery); 9581/* 9582 * jQuery mmenu sectionIndexer addon 9583 * mmenu.frebsite.nl 9584 * 9585 * Copyright (c) Fred Heusschen 9586 */ 9587!function(e){var a="mmenu",r="sectionIndexer";e[a].addons[r]={setup:function(){var i=this,d=this.opts[r];this.conf[r],s=e[a].glbl,"boolean"==typeof d&&(d={add:d}),"object"!=typeof d&&(d={}),d=this.opts[r]=e.extend(!0,{},e[a].defaults[r],d),this.bind("init",function(a){if(d.add){switch(d.addTo){case"panels":var r=a;break;default:var r=e(d.addTo,this.$menu).filter("."+n.panel)}r.find("."+n.divider).closest("."+n.panel).addClass(n.hasindexer)}if(!this.$indexer&&this.$menu.children("."+n.hasindexer).length){this.$indexer=e('<div class="'+n.indexer+'" />').prependTo(this.$menu).append('<a href="#a">a</a><a href="#b">b</a><a href="#c">c</a><a href="#d">d</a><a href="#e">e</a><a href="#f">f</a><a href="#g">g</a><a href="#h">h</a><a href="#i">i</a><a href="#j">j</a><a href="#k">k</a><a href="#l">l</a><a href="#m">m</a><a href="#n">n</a><a href="#o">o</a><a href="#p">p</a><a href="#q">q</a><a href="#r">r</a><a href="#s">s</a><a href="#t">t</a><a href="#u">u</a><a href="#v">v</a><a href="#w">w</a><a href="#x">x</a><a href="#y">y</a><a href="#z">z</a>'),this.$indexer.children().on(t.mouseover+"-sectionindexer "+n.touchstart+"-sectionindexer",function(){var a=e(this).attr("href").slice(1),r=i.$menu.children("."+n.current),t=r.find("."+n.listview),s=!1,d=r.scrollTop(),h=t.position().top+parseInt(t.css("margin-top"),10)+parseInt(t.css("padding-top"),10)+d;r.scrollTop(0),t.children("."+n.divider).not("."+n.hidden).each(function(){s===!1&&a==e(this).text().slice(0,1).toLowerCase()&&(s=e(this).position().top+h)}),r.scrollTop(s!==!1?s:d)});var s=function(e){i.$menu[(e.hasClass(n.hasindexer)?"add":"remove")+"Class"](n.hasindexer)};this.bind("openPanel",s),s.call(this,this.$menu.children("."+n.current))}})},add:function(){n=e[a]._c,i=e[a]._d,t=e[a]._e,n.add("indexer hasindexer"),t.add("mouseover touchstart")},clickAnchor:function(e){return e.parent().is("."+n.indexer)?!0:void 0}},e[a].defaults[r]={add:!1,addTo:"panels"};var n,i,t,s}(jQuery); 9588/* 9589 * jQuery mmenu toggles addon 9590 * mmenu.frebsite.nl 9591 * 9592 * Copyright (c) Fred Heusschen 9593 */ 9594!function(t){var e="mmenu",c="toggles";t[e].addons[c]={setup:function(){var n=this;this.opts[c],this.conf[c],l=t[e].glbl,this.bind("init",function(e){this.__refactorClass(t("input",e),this.conf.classNames[c].toggle,"toggle"),this.__refactorClass(t("input",e),this.conf.classNames[c].check,"check"),t("input."+s.toggle+", input."+s.check,e).each(function(){var e=t(this),c=e.closest("li"),i=e.hasClass(s.toggle)?"toggle":"check",l=e.attr("id")||n.__getUniqueId();c.children('label[for="'+l+'"]').length||(e.attr("id",l),c.prepend(e),t('<label for="'+l+'" class="'+s[i]+'"></label>').insertBefore(c.children("a, span").last()))})})},add:function(){s=t[e]._c,n=t[e]._d,i=t[e]._e,s.add("toggle check")},clickAnchor:function(){}},t[e].configuration.classNames[c]={toggle:"Toggle",check:"Check"};var s,n,i,l}(jQuery);; 9595/* AUTOGENERATED: slidebar.js */ 9596/* vim: set ts=2 sw=2 sts=2 et: */ 9597 9598/** 9599 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 9600 * See https://www.x-cart.com/license-agreement.html for license details. 9601 */ 9602 9603function slidebar() { 9604 var self = this; 9605 jQuery(function () { 9606 xcart.trigger('mm-menu.before_create', jQuery('#slidebar')); 9607 jQuery('#slidebar').mmenu(self.options, self.configuration); 9608 9609 var api = jQuery('#slidebar').data('mmenu'); 9610 9611 if (!_.isUndefined(api)) { 9612 xcart.trigger('mm-menu.created', api); 9613 api.bind('closed', function () { 9614 api.closeAllPanels(); 9615 }); 9616 } 9617 9618 jQuery('.dropdown-menu#search_box').parent().on('shown.bs.dropdown', function () { 9619 jQuery('#header').addClass('hidden'); 9620 }); 9621 9622 jQuery('.dropdown-menu#search_box').parent().on('hidden.bs.dropdown', function () { 9623 jQuery('#header').removeClass('hidden'); 9624 }); 9625 }); 9626} 9627 9628slidebar.prototype.options = { 9629 extensions: ['pagedim-black'], 9630 navbar: { 9631 title: xcart.t('Menu') 9632 }, 9633 offCanvas: { 9634 pageSelector: "#page-wrapper" 9635 } 9636}; 9637 9638slidebar.prototype.configuration = { 9639 panelNodetype: "ul, ol" 9640}; 9641 9642xcart.bind('navbar.mobile.loaded', function () { 9643 xcart.autoload(slidebar); 9644});; 9645/* AUTOGENERATED: slidebar_options.js */ 9646/* vim: set ts=2 sw=2 sts=2 et: */ 9647 9648/** 9649 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 9650 * See https://www.x-cart.com/license-agreement.html for license details. 9651 */ 9652 9653slidebar.prototype.options = _.extend(slidebar.prototype.options, { 9654 offCanvas: _.extend(slidebar.prototype.options.offCanvas, { 9655 position: 'right', 9656 zposition: 'front' 9657 }), 9658 navbar: _.extend(slidebar.prototype.options.navbar, { 9659 add: true, 9660 title: '' 9661 }), 9662 navbars: [ 9663 { 9664 position: 'top', 9665 content: getNavbarItems() 9666 }, 9667 { 9668 position: 'top', 9669 content: ['title'] 9670 } 9671 ] 9672}); 9673 9674xcart.bind('mm-menu.before_create', function (event, element) { 9675 if (element.find('#settings-panel ul').length) { 9676 element.find('#settings-panel ul').addClass('Inset'); 9677 } 9678}); 9679 9680xcart.bind('mm-menu.created', function (event, api) { 9681 api.bind('openPanel', function ($panel) { 9682 if ($panel.is('.mm-panel')) { 9683 $panel.parent('#slidebar').addClass('first-opened'); 9684 } else { 9685 $panel.parent('#slidebar').removeClass('first-opened'); 9686 } 9687 9688 const navbarAccountIcon = jQuery('.navbar-account span'); 9689 if ($panel.attr('id') == 'account-navbar-panel') { 9690 navbarAccountIcon.addClass('active'); 9691 } else { 9692 navbarAccountIcon.removeClass('active'); 9693 } 9694 9695 const navbarSettingsLabel = jQuery('.navbar-settings span'); 9696 if ($panel.attr('id') == 'settings-navbar-panel') { 9697 navbarSettingsLabel.addClass('active'); 9698 } else { 9699 navbarSettingsLabel.removeClass('active'); 9700 } 9701 9702 if ($panel.find('.mm-title').length && $panel.find('.mm-title').html()) { 9703 jQuery('.mm-navbar-top-2').show(); 9704 $panel.css('padding-top', '90px'); 9705 } else { 9706 jQuery('.mm-navbar-top-2').hide(); 9707 } 9708 }); 9709 9710 api.bind('open', function () { 9711 jQuery('#slidebar').addClass('first-opened'); 9712 }); 9713 9714 jQuery('#slidebar button.popup-button').on('popup.open', function () { 9715 var mmenu = jQuery('#slidebar').data('mmenu'); 9716 9717 if (mmenu) { 9718 mmenu.close(); 9719 } 9720 }); 9721 9722 slidebarItemsReposition(); 9723 removeAccountFromMainMenu(); 9724 addCompareIndicator(); 9725}); 9726 9727function getNavbarItems() { 9728 const navbarItems = [ 9729 'prev', 9730 '<a class=\'navbar-account\' href=\'#account-navbar-panel\'><span class="visually-hidden">' + xcart.t('My account') + '</span><span class=\'icon-account\' aria-hidden="true"></span></a>' 9731 ]; 9732 9733 var showSettingsNavbar = false;
9734 var settingsNavbarLabel = ''; 9735 9736 const currency = jQuery('.currency-indicator'); 9737 if (currency.length) { 9738 showSettingsNavbar = true; 9739 settingsNavbarLabel += '<span>' + currency.html() + '</span>'; 9740 } 9741 9742 const language = jQuery('.language-indicator'); 9743 if (language.length) { 9744 showSettingsNavbar = true; 9745 settingsNavbarLabel += '<span>' + language.html() + '</span>'; 9746 } 9747 9748 if (showSettingsNavbar) { 9749 navbarItems.push('<a class=\'navbar-settings\' href=\'#settings-navbar-panel\'>' + settingsNavbarLabel + '</a>'); 9750 } 9751 9752 return navbarItems; 9753} 9754 9755function slidebarItemsReposition() { 9756 const menuCategory = jQuery('#slidebar .mm-listview .slidebar-categories'); 9757 const menuHome = jQuery('#slidebar .mm-listview .first'); 9758 menuHome.insertBefore(menuCategory); 9759} 9760 9761function removeAccountFromMainMenu() { 9762 const accountAnchor = jQuery('#slidebar .mm-listview .leaf.has-sub a[href="?target=order_list"]'); 9763 accountAnchor.closest('li').remove(); 9764} 9765 9766function addCompareIndicator() { 9767 const compareIndicator = jQuery('#slidebar #account-navbar-panel .compare-indicator'); 9768 if (compareIndicator.hasClass('recently-updated')) { 9769 const iconAccount = jQuery('#slidebar .icon-account'); 9770 iconAccount.addClass('recently-updated-icon'); 9771 } 9772}; 9773/* AUTOGENERATED: top_menu.js */ 9774/* vim: set ts=2 sw=2 sts=2 et: */ 9775 9776/** 9777 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 9778 * See https://www.x-cart.com/license-agreement.html for license details. 9779 */ 9780 9781/** 9782 * @param element containing the navbar items 9783 * @constructor 9784 */ 9785function TopMenuAutoHide(element) { 9786 this.$element = jQuery(element); 9787 this.element = this.$element.get(0); 9788 9789 this.bindHandlers(); 9790 9791 this.init(); 9792 this.updateMenu(); 9793 setTimeout(_.bind(this.updateMenu, this), 200) 9794} 9795 9796TopMenuAutoHide.prototype.element = null; 9797TopMenuAutoHide.prototype.$element = null; 9798 9799var superBind = function (func, context) { 9800 return function () { 9801 _.partial(func, this).apply(context, arguments); 9802 } 9803}; 9804 9805TopMenuAutoHide.prototype.bindHandlers = function () { 9806 var handler = _.bind(this.updateMenu, this); 9807 9808 jQuery(window).resize(handler); 9809 9810 jQuery('.desktop-header') 9811 .bind('affixed-top.bs.affix', handler) 9812 .bind('affixed.bs.affix', handler); 9813 9814 jQuery('.header_search-panel') 9815 .bind('show.bs.collapse', handler) 9816 .bind('hidden.bs.collapse', handler); 9817 9818 jQuery(this.$element).on('mouseenter', '.has-sub', superBind(this.checkSubMenuPosition, this)); 9819}; 9820 9821TopMenuAutoHide.prototype.init = function () { 9822 var index = 0; 9823 this.$element.children(':not(.more)').each(function () { 9824 this.menuItemPosition = index++; 9825 }) 9826}; 9827 9828TopMenuAutoHide.prototype.sortItems = function (items) { 9829 items.sort(function (a, b) { 9830 var ap = a.menuItemPosition; 9831 var bp = b.menuItemPosition; 9832 return ((ap < bp) ? -1 : ((ap > bp) ? 1 : 0)); 9833 }); 9834 9835 return items; 9836}; 9837 9838/** 9839 * Recalculates more item position and content, hides extra elements, must be triggered on any navbar layout change 9840 */ 9841TopMenuAutoHide.prototype.updateMenu = function () { 9842 var more = this.$element.find('.more'); 9843 9844 if (more.length) { 9845 more.find('ul').first().find('> li').appendTo(this.$element); 9846 more.detach(); 9847 } else { 9848 more = this.createMoreItem(); 9849 } 9850 9851 var menuItems = this.$element.children().detach().filter(function () { 9852 return jQuery(this).find('*').length; 9853 }); 9854 9855 var containerWidth = this.calculateNavbarWidth(); 9856 this.$element.append(this.sortItems(menuItems)); 9857 9858 this.$element.children().removeClass('last'); 9859 9860 var extraPadding = this.getExtraPadding(); 9861 9862 while ( 9863 this.$element.outerWidth() > containerWidth - extraPadding 9864 && this.$element.children(':not(.more)').length > 2 9865 ) { 9866 this.$element.children(':not(.more)').last().prependTo(more.find('ul').first()); 9867 } 9868 9869 if (!more.find('ul').first().find('> li').length) { 9870 more.remove(); 9871 } else { 9872 more.appendTo(this.$element); 9873 9874 if (this.$element.outerWidth() > containerWidth - extraPadding) { 9875 this.$element.children(':not(.more)').last().prependTo(more.find('ul').first()); 9876 } 9877 9878 if ( 9879 more.find('ul').first().find('> li').html() === '' 9880 && more.find('ul').first().find('> li').text() === '' 9881 ) { 9882 more.remove(); 9883 } 9884 } 9885
9886 this.$element.children().last().addClass('last'); 9887 this.$element.closest('[data-desktop-navbar]').css('overflow', 'visible'); 9888 9889 this.updateSubmenusPos(); 9890}; 9891 9892TopMenuAutoHide.prototype.updateSubmenusPos = function () { 9893 var menu = this.$element; 9894 menu.children('.has-sub').each(function () { 9895 $menuItem = $(this); 9896 var $submenu = $menuItem.children('.sublevel'); 9897 9898 if ($submenu.length === 0) { 9899 return; 9900 } 9901 9902 if (!$submenu.hasClass('pos-updated')) { 9903 9904 var submenuRightPos = $submenu.offset().left + $submenu.outerWidth(); 9905 var pageRightPos = $('body').outerWidth(); 9906 9907 if (submenuRightPos > pageRightPos) { 9908 $submenu.css('left', 'auto'); 9909 $submenu.css('right', -1); 9910 $submenu.addClass('right-arrow'); 9911 } 9912 9913 $submenu.addClass('pos-updated'); 9914 } 9915 }); 9916}; 9917 9918TopMenuAutoHide.prototype.createMoreItem = function () { 9919 var label_more = xcart.t ? xcart.t('More') : 'More'; 9920 return jQuery('<li class="leaf has-sub more"><span>' + label_more + '</span><ul/><li>'); 9921}; 9922 9923/** 9924 * @deprecated 9925 * @returns {number} parent container width 9926 */ 9927TopMenuAutoHide.prototype.getContainerWidth = function () { 9928 return this.$element.parent().innerWidth(); 9929}; 9930 9931/** 9932 * Calculates available navbar space via flex hacks. Only possible on empty navbar with flex-grow: 1. 9933 * @since 5.3.3.2 9934 * @returns {Number} width 9935 */ 9936TopMenuAutoHide.prototype.calculateNavbarWidth = function () { 9937 var navbar = this.$element.closest('[data-desktop-navbar]'); 9938 navbar.css('flex-basis', '1%'); 9939 navbar.css('max-width', '100%'); 9940 var width = navbar.innerWidth() - 1; 9941 navbar.css('flex-basis', 'auto'); 9942 navbar.css('max-width', 'none'); 9943 9944 return width; 9945}; 9946 9947/** 9948 * @deprecated 9949 * @returns {number} width of the siblings 9950 */ 9951TopMenuAutoHide.prototype.getSiblingsWidth = function () { 9952 var state = jQuery('.desktop-header').hasClass('affix-top') ? 'top' : 'affix'; 9953 9954 var width; 9955 if (state === 'top') { 9956 width = jQuery('.header-right-bar').outerWidth(); 9957 9958 } else if (state === 'affix') { 9959 var rightBarWidth = jQuery('.header-right-bar .header-right-bar').outerWidth(); 9960 var searchWidth = 190; // FIXME: Hardcoded because search is initially hidden. 9961 var logo = $('.affix .company-logo'); 9962 var logoWidth = logo.length ? logo.outerWidth() : 0; 9963 9964 width = logoWidth + rightBarWidth + searchWidth; 9965 } 9966 9967 return width; 9968}; 9969 9970/** 9971 * @returns {number} Get extra padding width 9972 */ 9973TopMenuAutoHide.prototype.getExtraPadding = function() { 9974 var searchPanel = jQuery('.header-right-bar .header_search-panel').get(0); 9975 9976 return searchPanel.getBoundingClientRect().width > 0 9977 ? searchPanel.getBoundingClientRect().width 9978 : 0 9979}; 9980 9981TopMenuAutoHide.prototype.checkSubMenuPosition = function (element, event) { 9982 var subMenu = jQuery('ul', element).first(); 9983 if (event.type === 'mouseenter') { 9984 subMenu.removeClass('right'); 9985 subMenu.toggleClass('right', subMenu.offset().left + subMenu.outerWidth() > window.innerWidth); 9986 } 9987}; 9988 9989xcart.autoload(TopMenuAutoHide, 'ul.top-main-menu');; 9990/* AUTOGENERATED: button.js */ 9991/* vim: set ts=2 sw=2 sts=2 et: */ 9992 9993/** 9994 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 9995 * See https://www.x-cart.com/license-agreement.html for license details. 9996 */ 9997 9998function setFormAttribute(form, name, value) 9999{ 10000 form.elements[name].value = value; 10001} 10002 10003function setFormAction(form, action) 10004{ 10005 setFormAttribute('action', action); 10006} 10007 10008function submitForm(form, attrs) 10009{ 10010 jQuery.each( 10011 attrs, 10012 function (name, value) { 10013 var e = form.elements.namedItem(name); 10014 if (e) { 10015 e.value = value; 10016 } 10017 } 10018 ); 10019 10020 jQuery(form).submit(); 10021} 10022 10023function submitFormDefault(form, action) 10024{ 10025 var attrs = {}; 10026 if (typeof(action) != 'undefined' && action !== null) { 10027 attrs['action'] = action; 10028 } 10029 10030 submitForm(form, attrs); 10031} 10032 10033jQuery(document).ready(function () { 10034 jQuery('a.disabled').click(function(event){ 10035 event.preventDefault(); 10036 }); 10037});; 10038/* AUTOGENERATED: login.js */ 10039/* vim: set ts=2 sw=2 sts=2 et: */ 10040 10041/** 10042 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 10043 * See https://www.x-cart.com/license-agreement.html for license details. 10044 */ 10045 10046function PopupButtonLogin(base) 10047{ 10048 PopupButtonLogin.superclass.constructor.apply(this, arguments); 10049} 10050 10051extend(PopupButtonLogin, PopupButton); 10052 10053PopupButtonLogin.prototype.pattern = '.popup-button.popup-login'; 10054 10055decorate( 10056 'PopupButtonLogin', 10057 'callback', 10058 function (selector) 10059 { 10060 arguments.callee.previousMethod.apply(this, arguments); 10061 xcart.autoload(PopupButton); 10062 } 10063); 10064 10065decorate( 10066 'PopupButton', 10067 'callback', 10068 function (selector) 10069 { 10070 arguments.callee.previousMethod.apply(this, arguments); 10071 xcart.autoload(PopupButtonLogin); 10072 } 10073); 10074 10075xcart.autoload(PopupButtonLogin); 10076 10077xcart.bind('PopupButtonForgotPasswordLoad', function() { 10078 xcart.autoload(PopupButtonLogin); 10079});; 10080/* AUTOGENERATED: login.js */ 10081/* vim: set ts=2 sw=2 sts=2 et: */ 10082 10083/** 10084 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 10085 * See https://www.x-cart.com/license-agreement.html for license details. 10086 */ 10087 10088jQuery(document).ready( 10089 function() { 10090 10091 // Open login link is popup 10092 xcart.microhandlers.add( 10093 'loginPopup', 10094 'a.log-in', 10095 function() { 10096 10097 jQuery(this).click( 10098 function(event) { 10099 loadDialogByLink( 10100 event.currentTarget, 10101 URLHandler.buildURL({ 10102 'target': 'login', 10103 'widget': '\\XLite\\View\\Authorization', 10104 'popup': 1, 10105 'fromURL': jQuery(this).data('return-url') || (self.location + ''), 10106 'login': jQuery(event.currentTarget).data('login') ? jQuery(event.currentTarget).data('login') : '' 10107 }), 10108 {width: 'auto'}, 10109 null, 10110 this 10111 ); 10112 10113 return false;
10114 } 10115 ) 10116 } 10117 ); 10118 10119 var initiateTimer = function(base) { 10120 var timeLeft = base.data('time-left'); 10121 if (timeLeft) { 10122 (function() { 10123 timeLeft--; 10124 if (0 < timeLeft) { 10125 var min = parseInt(timeLeft / 60); 10126 var sec = timeLeft % 60; 10127 jQuery('#timer', base).text((10 > min ? '0' : '') + min + ':' + (10 > sec ? '0' : '') + sec); 10128 setTimeout(arguments.callee, 1000); 10129 10130 } else { 10131 jQuery(base).removeClass('locked-out'); 10132 } 10133 })() 10134 } 10135 }; 10136 10137 initiateTimer(jQuery('.login-form')); 10138 10139 // Login popup form 10140 xcart.microhandlers.add( 10141 'loginPopupForm', 10142 'form.login-form', 10143 function(event) { 10144 this.commonController.enableBackgroundSubmit(); 10145 var form = this.commonController.$form; 10146 var lockoutBase = form.find('.login-form'); 10147 10148 xcart.bind( 10149 'login.lockout', 10150 function(event, data) { 10151 lockoutBase.addClass('locked-out'); 10152 lockoutBase.data('time-left', data.time); 10153 initiateTimer(lockoutBase); 10154 } 10155 ); 10156 10157 initiateTimer(lockoutBase); 10158 10159 form.find('a.forgot').click( 10160 function(event) { 10161 loadDialogByLink( 10162 event.currentTarget, 10163 URLHandler.buildURL({ 10164 'target': 'recover_password', 10165 'widget': '\\XLite\\View\\RecoverPassword', 10166 'popup': 1, 10167 'fromURL': (self.location + ''), 10168 'email': form.find('#login').val() ? form.find('#login').val() : '' 10169 }), 10170 {width: 'auto'}, 10171 function() { 10172 xcart.trigger('PopupButtonForgotPasswordLoad'); 10173 }, 10174 this 10175 ); 10176 10177 return false; 10178 } 10179 ); 10180 10181 var f = this.commonController.getErrorPlace; 10182 this.commonController.getErrorPlace = function() 10183 { 10184 if (!this.errorPlace) { 10185 var box = f.apply(this); 10186 box 10187 .remove() 10188 .insertBefore(this.$form.find('button[type="submit"]').eq(0)); 10189 } 10190 10191 return this.errorPlace; 10192 } 10193 10194 xcart.bind( 10195 'recoverPasswordSent', 10196 function() { 10197 popup.close(); 10198 } 10199 ); 10200 } 10201 ); 10202 10203 // Recovery password popup form 10204 xcart.microhandlers.add( 10205 'recoverPasswordPopupForm', 10206 'form.recovery-form', 10207 function(event) { 10208 if (jQuery(this).parents('.popup-window-entry').length) { 10209 this.commonController.enableBackgroundSubmit(); 10210 } 10211 } 10212 ); 10213 } 10214);; 10215/* AUTOGENERATED: controller.js */ 10216/* vim: set ts=2 sw=2 sts=2 et: */ 10217 10218/** 10219 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 10220 * See https://www.x-cart.com/license-agreement.html for license details. 10221 */ 10222 10223var MESSAGE_INFO = 'info'; 10224var MESSAGE_WARNING = 'warning'; 10225var MESSAGE_ERROR = 'error'; 10226 10227/** 10228 * Controller 10229 */ 10230 10231// Constructor 10232function TopMessages(container) { 10233 if (!container) { 10234 return false; 10235 } 10236 10237 this.container = jQuery(container).eq(0); 10238 if (!this.container.length) { 10239 return false; 10240 } 10241 10242 this.messages = {}; 10243 10244 // Add listeners 10245 10246 // Close button 10247 jQuery('button.close', this.container).click( 10248 _.bind( 10249 function (event) { 10250 event.stopPropagation(); 10251 this.clearRecords(); 10252 10253 return false; 10254 }, 10255 this 10256 ) 10257 ).hover( 10258 function () { 10259 jQuery(this).addClass('close-hover'); 10260 }, 10261 function () { 10262 jQuery(this).removeClass('close-hover'); 10263 } 10264 ); 10265 10266 // Global event 10267 if ('undefined' != typeof (window.xcart)) { 10268 xcart.bind( 10269 'message', 10270 _.bind( 10271 function (event, data) { 10272 return this.messageHandler(data.message, data.type); 10273 }, 10274 this 10275 ) 10276 ); 10277 10278 xcart.bind( 10279 'messages', 10280 function (event, data) { 10281 for (var i in data) { 10282 xcart.trigger('message', data[i]); 10283 } 10284 } 10285 ); 10286 10287 xcart.bind( 10288 'clearMessages', 10289 _.bind( 10290 function (event) { 10291 this.clearRecords(); 10292 }, 10293 this 10294 ) 10295 ); 10296 } 10297 10298 // Remove dump items (W3C compatibility) 10299 jQuery('li.dump', this.container).remove(); 10300 10301 // Initial show 10302 if (!this.isVisible() && jQuery('li', this.container).length) { 10303 setTimeout( 10304 _.bind( 10305 function () { 10306 this.show(); 10307 10308 // Set initial timers 10309 jQuery('li.info', this.container).each( 10310 _.bind( 10311 function (idx, elm) { 10312 this.setTimer(elm); 10313 }, 10314 this 10315 ) 10316 ); 10317 }, 10318 this 10319 ), 10320 1000 10321 ); 10322 10323 } else { 10324 10325 // Set initial timers 10326 jQuery('li.info', this.container).each( 10327 _.bind( 10328 function (idx, elm) { 10329 this.setTimer(elm); 10330 }, 10331 this 10332 ) 10333 ); 10334 } 10335} 10336 10337/** 10338 * Properties 10339 */ 10340TopMessages.prototype.container = null; 10341TopMessages.prototype.to = null; 10342 10343TopMessages.prototype.ttl = 10000; 10344 10345/** 10346 * Methods 10347 */ 10348 10349// Check visibility 10350TopMessages.prototype.isVisible = function () { 10351 return this.container.css('display') != 'none'; 10352}; 10353 10354// Show widget 10355TopMessages.prototype.show = function () { 10356 this.container.slideDown(); 10357}; 10358 10359// Hide widget 10360TopMessages.prototype.hide = function (callback) { 10361 this.container.slideUp(callback); 10362}; 10363 10364TopMessages.prototype.getMessageFromText = function (element) { 10365 return element.find('.message').length > 0 10366 ? element.find('.message') 10367 : element; 10368}; 10369
10370TopMessages.prototype.getSameRecord = function (ul, text) { 10371 var self = this; 10372 10373 return ul.find('li').filter(function () { 10374 var htmlContent = jQuery('<div />').html(text); 10375 if (htmlContent.length > 0) { 10376 text = htmlContent.find('.message').length > 0 10377 ? htmlContent.find('.message').text() 10378 : text; 10379 } 10380 10381 if (text) { 10382 text = text.replace(/^[\s\n]+|[\s\n]+$/gm, ''); 10383 } 10384 10385 var realElement = self.getMessageFromText(jQuery(this)); 10386 var reg = new RegExp(text + ' \\\((\\\d*?)\\\)', 'i'); 10387 var realText = realElement.text().replace(/^[\s\n]+|[\s\n]+$/gm, ''); 10388 10389 return realText === text || realText.match(reg); 10390 }).get(0); 10391}; 10392 10393TopMessages.prototype.updateRecord = function (li) { 10394 var recordLi = jQuery(li).find('.message').length > 0 10395 ? jQuery(li).find('.message') 10396 : jQuery(li); 10397 var array = /(.*) \((\d*?)\)/i.exec(recordLi.text()); 10398 var oldText = array && array[1] 10399 ? array[1] 10400 : recordLi.text(); 10401 var oldIndex = array && array[2] 10402 ? array[2] 10403 : 0; 10404 10405 oldText = oldText.replace(/^[\s\n]+|[\s\n]+$/gm, ''); 10406 recordLi.text(oldText + ' (' + (intval(oldIndex) + 1) + ')'); 10407}; 10408 10409// Add record 10410TopMessages.prototype.addRecord = function (text, type) { 10411 if (!type 10412 || (MESSAGE_INFO != type && MESSAGE_WARNING != type && MESSAGE_ERROR != type) 10413 ) { 10414 type = MESSAGE_INFO; 10415 } 10416 10417 var ul = jQuery('ul', this.container).length 10418 ? jQuery('ul', this.container) 10419 : jQuery(document.createElement('UL')).appendTo(this.container); 10420 10421 var sameLi = this.getSameRecord(ul, text); 10422 var hash = objectHash.sha1({text: text, type: type}); 10423 10424 if (sameLi) { 10425 this.updateRecord(sameLi); 10426 li = sameLi; 10427 } else { 10428 var li = document.createElement('LI'); 10429 li.innerHTML = text; 10430 li.className = type; 10431 li.style.display = 'none'; 10432 10433 ul.append(li); 10434 } 10435 10436 li.hash = hash; 10437 this.messages[hash] = {text: text, type: type}; 10438 10439 if ( 10440 ul.find('li').length 10441 && !this.isVisible() 10442 ) { 10443 this.show(); 10444 } 10445 10446 jQuery(li).slideDown('fast'); 10447 10448 if (type == MESSAGE_INFO) { 10449 this.setTimer(li); 10450 } 10451}; 10452 10453// Clear record 10454TopMessages.prototype.hideRecord = function (li) { 10455 if (jQuery('li:not(.remove)', this.container).length == 1) { 10456 this.clearRecords(); 10457 10458 } else { 10459 jQuery(li).addClass('remove').slideUp( 10460 'fast', 10461 function () { 10462 jQuery(this).remove(); 10463 10464 if (this.messages && typeof li.hash !== 'undefined') { 10465 delete this.messages[li.hash]; 10466 } 10467 } 10468 ); 10469 } 10470}; 10471 10472// Clear all records 10473TopMessages.prototype.clearRecords = function () { 10474 var container = this.container; 10475 this.hide(function () { 10476 jQuery('li', container).remove(); 10477 this.messages = {}; 10478 }); 10479}; 10480 10481// Set record timer 10482TopMessages.prototype.setTimer = function (li) { 10483 li = jQuery(li).get(0); 10484 10485 if (li.timer) { 10486 clearTimeout(li.timer); 10487 li.timer = false; 10488 } 10489 10490 var o = this; 10491 li.timer = setTimeout( 10492 function () { 10493 o.hideRecord(li); 10494 }, 10495 this.ttl 10496 ); 10497}; 10498 10499TopMessages.prototype.hasVisibleMessages = function () { 10500 return Object.keys(this.messages).length > 0; 10501}; 10502 10503TopMessages.instance = null; 10504 10505// onmessage event handler 10506TopMessages.prototype.messageHandler = function (text, type) { 10507 this.addRecord(text, type); 10508}; 10509 10510jQuery(function () { 10511 TopMessages.instance = new TopMessages(jQuery('#status-messages')); 10512});; 10513/* AUTOGENERATED: ga-search.js */ 10514/* vim: set ts=2 sw=2 sts=2 et: */ 10515 10516/** 10517 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 10518 * See https://www.x-cart.com/license-agreement.html for license details. 10519 */ 10520 10521define('googleAnalytics/base/searchEvent', [ 'googleAnalytics/event' ], function(Event) { 10522 return Event.extend({ 10523 namespace: 'search', 10524 10525 processReady () { 10526 jQuery('.search-product-form button[type=\'submit\'], .simple-search-product-form button[type=\'submit\']').click(_.bind(this.registerSearchSubstring, this)) 10527 }, 10528 10529 registerSearchSubstring (event) { 10530 var substring = jQuery(event.currentTarget).closest('form').find('input[name="substring"]').val() 10531 if (substring) { 10532 this.sendSearchSubstringEvent(substring, event) 10533 } 10534 }, 10535 10536 sendSearchSubstringEvent (substring, event) { 10537 } 10538 }); 10539});; 10540/* AUTOGENERATED: ga-search.js */ 10541/* vim: set ts=2 sw=2 sts=2 et: */ 10542 10543/** 10544 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 10545 * See https://www.x-cart.com/license-agreement.html for license details. 10546 */ 10547 10548define('googleAnalytics/searchEvent', [ 'googleAnalytics/base/searchEvent', 'googleAnalytics/event' ], function(GASearchEventBase, Event) { 10549 let GASearchEvent = GASearchEventBase.extend({ 10550 sendSearchSubstringEvent (substring, event) { 10551 this.sendEvent('Search', substring, undefined, 'Product') 10552 } 10553 }) 10554 10555 GASearchEvent.instance = new GASearchEvent(); 10556 10557 return GASearchEvent; 10558});;
10559/* AUTOGENERATED: text.js */ 10560/* vim: set ts=2 sw=2 sts=2 et: */ 10561 10562/** 10563 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 10564 * See https://www.x-cart.com/license-agreement.html for license details. 10565 */ 10566 10567xcart.bind( 10568 'load', 10569 function(event) { 10570 jQuery('.input-field-wrapper').each(function () { 10571 var obj = jQuery(this); 10572 10573 var inputField = jQuery('input,textarea', obj); 10574 var defaultValue = xcart.getCommentedData(obj, 'defaultValue'); 10575 var type = inputField.attr('type'); 10576 10577 if ( 10578 '' !== defaultValue 10579 && null !== defaultValue 10580 && 'checkbox' != type 10581 && 'radio' != type 10582 && 'file' != type 10583 && 'image' != type 10584 && 'submit' != type 10585 && 'button' != type 10586 ) { 10587 10588 if ('' === inputField.val()) { 10589 inputField.val(defaultValue).addClass('default-value'); 10590 } 10591 10592 inputField.click( 10593 function () { 10594 if (defaultValue === inputField.val()) { 10595 inputField.removeClass('default-value').val(''); 10596 } 10597 } 10598 ).blur( 10599 function () { 10600 if ('' === inputField.val()) { 10601 inputField.addClass('default-value').val(defaultValue); 10602 } 10603 } 10604 ); 10605 10606 inputField 10607 .parents('form') 10608 .submit( 10609 function() { 10610 if (defaultValue === inputField.val()) { 10611 inputField.val(''); 10612 } 10613 10614 return true; 10615 } 10616 ); 10617 } 10618 }); 10619 } 10620);; 10621/* AUTOGENERATED: header_settings.js */ 10622/* vim: set ts=2 sw=2 sts=2 et: */ 10623 10624/** 10625 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 10626 * See https://www.x-cart.com/license-agreement.html for license details. 10627 */ 10628 10629function HeaderSettingsController(base) 10630{ 10631 this.callSupermethod('constructor', arguments); 10632 10633 if (this.base && this.base.length) { 10634 this.block = new HeaderSettingsView(this.base); 10635 xcart.bind('updateHeaderSettings', _.bind(this.handleUpdateHeaderSettings, this)); 10636 xcart.bind('checkHeaderSettingsRecentlyUpdated', _.bind(this.checkRecentlyUpdated, this)); 10637 } 10638} 10639 10640extend(HeaderSettingsController, AController); 10641 10642// Controller name 10643HeaderSettingsController.prototype.name = 'HeaderSettingsController'; 10644 10645// Find pattern 10646HeaderSettingsController.prototype.findPattern = '.header_settings'; 10647 10648// Initialize controller 10649HeaderSettingsController.prototype.initialize = function() 10650{ 10651 var o = this; 10652 10653 this.base.bind( 10654 'reload', 10655 function(event, box) { 10656 o.bind(box); 10657 } 10658 ); 10659}; 10660 10661HeaderSettingsController.prototype.handleUpdateHeaderSettings = function(event, data) 10662{ 10663 this.block.load(); 10664}; 10665 10666HeaderSettingsController.prototype.isRecentlyUpdated = function() 10667{ 10668 return false; 10669}; 10670 10671HeaderSettingsController.prototype.checkRecentlyUpdated = function(event, data) 10672{ 10673 if (this.isRecentlyUpdated()) { 10674 this.base.addClass('recently-updated'); 10675 } else { 10676 this.base.removeClass('recently-updated'); 10677 } 10678}; 10679 10680function HeaderSettingsView(base) 10681{ 10682 this.callSupermethod('constructor', arguments); 10683 10684 this.bind('local.preload', _.bind(this.handlePreload, this)); 10685 this.bind('local.loadingError', _.bind(this.handleLoaded, this)); 10686} 10687 10688extend(HeaderSettingsView, ALoadable); 10689// No shade widget 10690HeaderSettingsView.prototype.shadeWidget = false; 10691 10692// Widget target 10693HeaderSettingsView.prototype.widgetTarget = 'main'; 10694 10695// Widget class name 10696HeaderSettingsView.prototype.widgetClass = '\\XC\\CrispWhiteSkin\\View\\HeaderSettings'; 10697 10698HeaderSettingsView.prototype.handlePreload = function(event, state) 10699{ 10700 var box = this.base.find('.dropdown-menu'); 10701 10702 if (box.length) { 10703 var overlay = jQuery(document.createElement('div')); 10704 overlay 10705 .addClass('wait-overlay') 10706 .append('<div></div>'); 10707 box.append(overlay); 10708 } 10709}; 10710 10711HeaderSettingsView.prototype.handleLoaded = function(event, state) 10712{ 10713 this.base.find('.wait-overlay').remove(); 10714}; 10715 10716// Get event namespace (prefix) 10717HeaderSettingsView.prototype.getEventNamespace = function() 10718{ 10719 return 'header_settings'; 10720}; 10721 10722xcart.autoload(HeaderSettingsController);; 10723/* AUTOGENERATED: minicart.js */ 10724/* vim: set ts=2 sw=2 sts=2 et: */ 10725 10726/** 10727 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 10728 * See https://www.x-cart.com/license-agreement.html for license details. 10729 */ 10730 10731/** 10732 * Controller 10733 */ 10734 10735function MinicartController(base) 10736{ 10737 this.callSupermethod('constructor', arguments); 10738 10739 if (this.base && this.base.length) { 10740 this.block = new MinicartView(this.base); 10741 xcart.bind(['updateCart', 'updateMiniCart'], _.bind(this.handleUpdate
10741Cart, this)); 10742 } 10743} 10744 10745extend(MinicartController, AController); 10746 10747// Controller name 10748MinicartController.prototype.name = 'MinicartController'; 10749 10750// Find pattern 10751MinicartController.prototype.findPattern = '.lc-minicart'; 10752 10753// Controller associated widget 10754MinicartController.prototype.block = null; 10755 10756// Initialize controller 10757MinicartController.prototype.initialize = function() 10758{ 10759 var o = this; 10760 10761 this.base.bind( 10762 'reload', 10763 function(event, box) { 10764 o.bind(box); 10765 } 10766 ); 10767} 10768 10769MinicartController.prototype.handleUpdateCart = function(event, data) 10770{ 10771 if (data.items || data.total) { 10772 if ('undefined' != typeof(data.itemsCount)) { 10773 this.updateItemsCount(data.itemsCount); 10774 } 10775 10776 this.block.load(); 10777 } 10778} 10779 10780MinicartController.prototype.updateItemsCount = function(count) 10781{ 10782 this.base.find('.minicart-items-number').html(count); 10783 10784 if (0 < count) { 10785 this.base.removeClass('empty'); 10786 this.base.find('.items-list') 10787 .removeClass('empty-cart') 10788 .addClass('full-cart'); 10789 10790 } else { 10791 this.base.addClass('empty'); 10792 this.base.find('.items-list') 10793 .removeClass('full-cart') 10794 .addClass('empty-cart'); 10795 this.block.toggleViewMode(false); 10796 } 10797 10798} 10799 10800/** 10801 * Widget 10802 */ 10803 10804function MinicartView(base) 10805{ 10806 this.callSupermethod('constructor', arguments); 10807 10808 this.bind('local.preload', _.bind(this.handlePreload, this)); 10809 this.bind('local.loadingError', _.bind(this.handleLoaded, this)); 10810} 10811 10812extend(MinicartView, ALoadable); 10813 10814// No shade widget 10815MinicartView.prototype.shadeWidget = false; 10816 10817// Widget target 10818MinicartView.prototype.widgetTarget = 'cart'; 10819 10820// Widget class name 10821MinicartView.prototype.widgetClass = '\\XLite\\View\\Minicart'; 10822 10823// Expanded mode flag 10824MinicartView.prototype.isExpanded = false; 10825 10826// Body handler is binded or not 10827MinicartView.prototype.bodyHandlerBinded = false; 10828 10829// Postprocess widget 10830MinicartView.prototype.postprocess = function(isSuccess) 10831{ 10832 this.callSupermethod('postprocess', arguments); 10833 10834 if (isSuccess) { 10835 10836 // Get display mode 10837 var re = /lc-minicart-([^ ]+)/; 10838 if (!this.widgetParams && this.base.attr('class') && -1 != this.base.attr('class').search(re)) { 10839 if (!this.widgetParams) { 10840 this.widgetParams = {}; 10841 } 10842 10843 var m = this.base.attr('class').match(re); 10844 this.widgetParams.displayMode = m[1]; 10845 } 10846 10847 // Initialize view mode toggle mechanism 10848 this.base.click(_.bind( 10849 function(event) { 10850 this.toggleViewMode(); 10851 }, 10852 this 10853 )); 10854 10855 if (!this.bodyHandlerBinded) { 10856 jQuery('body').click(_.bind( 10857 function (event) { 10858 if (event.target !== this.base.get(0) 10859 && !jQuery.contains(this.base.get(0), event.target) 10860 ) { 10861 this.toggleViewMode(false); 10862 } 10863 }, 10864 this 10865 )); 10866 10867 this.bodyHandlerBinded = true; 10868 } 10869 10870 jQuery('.items-list', this.base).click( 10871 function(event) { 10872 event.stopPropagation(); 10873 } 10874 ); 10875 10876 if (this.isExpanded) { 10877 this.base.addClass('expanded').removeClass('collapsed'); 10878 } 10879 10880 jQuery('a.item-attribute-values', this.base).map(function() { 10881 attachTooltip(jQuery('span', this), jQuery(jQuery(this).attr('data-rel')).html(), 'bottom'); 10882 }); 10883 } 10884}; 10885 10886MinicartView.prototype.handlePreload = function(event, state) 10887{ 10888 var box = this.base.find('.items-list'); 10889 10890 if (box.length) { 10891 var overlay = jQuery(document.createElement('div')); 10892 overlay 10893 .addClass('wait-overlay') 10894 .append('<div></div>'); 10895 box.append(overlay); 10896 } 10897}; 10898 10899MinicartView.prototype.handleLoaded = function(event, state) 10900{ 10901 this.base.find('.wait-overlay').remove(); 10902}; 10903 10904// Toggle view mode 10905MinicartView.prototype.toggleViewMode = function(expand) 10906{ 10907 var old = this.isExpanded; 10908 10909 if (expand !== true && expand !== false) { 10910 expand = !this.base.hasClass('expanded'); 10911 } 10912 10913 if (expand && this.base.hasClass('empty')) { 10914 expand = false; 10915 } 10916 10917 this.isExpanded = expand; 10918 10919 if (expand) { 10920 this.base.addClass('expanded').removeClass('collapsed'); 10921 if (old != this.isExpanded) { 10922 this.triggerVent('opened', this); 10923 } 10924 10925 } else { 10926 this.base.removeClass('expanded').addClass('collapsed'); 10927 if (old != this.isExpanded) { 10928 this.triggerVent('closed', this); 10929 } 10930 } 10931}; 10932 10933// Get event namespace (prefix) 10934MinicartView.prototype.getEventNamespace = function() 10935{ 10936 return 'minicart'; 10937}; 10938 10939xcart.autoload(MinicartController);; 10940/* AUTOGENERATED: jquery.listItem.js */ 10941/* vim: set ts=2 sw=2 sts=2 et: */ 10942 10943/** 10944 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 10945 * See https://www.x-cart.com/license-agreement.html for license details. 10946 */ 10947 10948(function ($) { 10949 var undefined; 10950 10951 var options = { 10952 prefix: 'list-item__' 10953 }; 10954 10955 var focusAction = function (element) { 10956 let stickyElements = []; 10957 const additionalSpace = 20; 10958 const elem = element.get(0); 10959 const scrollStart = window.pageYOffset; 10960 let elemStartPosition = elem.getBoundingClientRect().top; 10961 let scrollBy = 0; 10962 let scrolledByOnPreviousStep = null; 10963 let elemTopOnPreviousStep = null; 10964 10965 const recalculateScrollCoords = function() { 10966 window.themeTweakerStickyElements = [ 10967 '.desktop-header', 10968 '.themetweaker-panel--header' 10969 ]; 10970 const evt = new CustomEvent('themeTweakerStickyElementsCollect'); 10971 window.dispatchEvent(evt); 10972 stickyElements = window.themeTweakerStickyElements.slice(0, window.themeTweakerStickyElements.length); 10973 const elemCurrentTop = elem.getBoundingClientRect().top; 10974 if ( 10975 scrolledByOnPreviousStep !== null 10976 && elemTopOnPreviousStep !== null 10977 && elemCurrentTop !== elemTopOnPreviousStep - scrolledByOnPreviousStep 10978 ) { 10979 elemStartPosition += (elemCurrentTop - elemTopOnPreviousStep + scrolledByOnPreviousStep); 10980 } 10981 scrollBy = elemStartPosition - additionalSpace;
10982 stickyElements.forEach(function(selector) { 10983 if (typeof selector === 'function') { 10984 scrollBy -= selector(); 10985 } else if (typeof selector === 'string') { 10986 document.querySelectorAll(selector).forEach(function(element) { 10987 scrollBy -= element.getBoundingClientRect().height; 10988 }); 10989 } else if (typeof selector === 'object' && typeof selector.getBoundingClientRect === 'function') { 10990 scrollBy -= selector.getBoundingClientRect().height; 10991 } 10992 }); 10993 elemTopOnPreviousStep = elemCurrentTop; 10994 } 10995 recalculateScrollCoords(); 10996 10997 const timeStart = Date.now(); 10998 const duration = 300; 10999 const frameStep = function() { 11000 const percentage = Math.min(((Date.now() - timeStart) / duration), 1); 11001 const step = 1 - ( 1 - percentage ) * ( 1 - percentage ); 11002 recalculateScrollCoords(); 11003 scrolledByOnPreviousStep = Math.round(scrollStart + scrollBy * step) - window.pageYOffset; 11004 window.scrollTo(0, Math.round(scrollStart + scrollBy * step)); 11005 if (percentage < 1) 11006 requestAnimationFrame(frameStep); 11007 } 11008 requestAnimationFrame(frameStep); 11009 } 11010 11011 var methods = { 11012 focus: function () { 11013 let element = $(this); 11014 $(this).on('animationend', _.once(function () { 11015 focusAction(element); 11016 })); 11017 }, 11018 selected: function () { 11019 focusAction($(this)); 11020 }, 11021 show: function () { 11022 this.each(function () { 11023 $(this).on('animationend', _.once(function () { 11024 $(this).removeClass(options.prefix + 'showing'); 11025 $(this).css('max-height', ''); 11026 })); 11027 $(this).css('max-height', $(this).data('height')); 11028 $(this).removeClass(options.prefix + 'hidden'); 11029 $(this).removeClass(options.prefix + 'sidebar-hidden'); 11030 $(this).addClass(options.prefix + 'showing'); 11031 }); 11032 }, 11033 hide: function () { 11034 this.each(function () { 11035 $(this).data('height', $(this).outerHeight()); 11036 $(this).css('max-height', $(this).outerHeight()); 11037 $(this).on('animationend', _.once(function () { 11038 $(this).removeClass(options.prefix + 'hiding'); 11039 $(this).addClass(options.prefix + 'hidden'); 11040 $(this).css('max-height', 0); 11041 })); 11042 $(this).addClass(options.prefix + 'hiding'); 11043 }); 11044 }, 11045 isHidden: function () { 11046 return this.hasClass(options.prefix + 'hidden') || this.hasClass(options.prefix + 'temporary'); 11047 }, 11048 isSidebarHidden: function() { 11049 return this.hasClass(options.prefix + 'sidebar-hidden'); 11050 }, 11051 }; 11052 11053 $.fn.listItem = function (method) { 11054 if (methods[method]) { 11055 return methods[method].apply(this, Array.prototype.slice.call(arguments, 1)); 11056 } else if (typeof method === 'object' || !method) { 11057 return methods.init.apply(this, arguments); 11058 } else { 11059 $.error('ÐеÑод Ñ Ð¸Ð¼ÐµÐ½ÐµÐ¼ ' + method + ' не опÑеделен Ð´Ð»Ñ jQuery.listItem'); 11060 } 11061 }; 11062})(jQuery);; 11063/* AUTOGENERATED: list_container.js */ 11064/* vim: set ts=2 sw=2 sts=2 et: */ 11065 11066/** 11067 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 11068 * See https://www.x-cart.com/license-agreement.html for license details. 11069 */ 11070 11071function ListContainer(element) { 11072 this.base = $(element); 11073 this.instances = []; 11074 11075 var self = this; 11076 var groups = $(this.base).find('.group-items.movable-group'); 11077 11078 $('.group-item').mouseenter(function () { 11079 if (!$(this).closest('.group-items').hasClass('group-items__on-move')) { 11080 $(this).removeClass('group-item__not-hoverable'); 11081 } 11082 }) 11083 11084 groups.each(function () { 11085 var instance = Sortable.create(this, { 11086 animation: 150, 11087 handle: '.themetweaker-panel-move', 11088 group: 'common', 11089 ghostClass: "sortable-ghost", // Class name for the drop placeholder 11090 chosenClass: "sortable-chosen", // Class name for the chosen item 11091 dragClass: "sortable-drag", 11092 onStart: _.bind(self.onStart, self), 11093 onEnd: _.bind(self.onEnd, self), 11094 onMove: _.bind(self.onMove, self), 11095 filter: ".group-item-hidden", 11096 }); 11097 11098 this.querySelectorAll('.themetweaker-panel-move').forEach((mover) => { 11099 mover.addEventListener("click", function(e) { 11100 e.stopPropagation(); 11101 }); 11102 }); 11103 11104 self.instances.push(instance); 11105 }); 11106} 11107 11108ListContainer.prototype.move = function (item) { 11109 var from = item.closest('.list-items-group'); 11110 var center = $('.list-items-group[data-list="center"]'); 11111 11112 if (center.length > 0) { 11113 center.append(item); 11114 var event = new Event('add'); 11115 event.from = from; 11116 event.to = center; 11117 event.item = item; 11118 this.onAdd(event); 11119 } else { 11120 console.error('Can\'t move item to center group, because it doesn\'t exist'); 11121 } 11122}; 11123 11124ListContainer.prototype.onStart = function (event) { 11125 xcart.trigger('layout.dragStart'); 11126 $('.group-item').addClass('group-item__not-hoverable'); 11127 $('.group-items').addClass('group-items__on-move'); 11128}; 11129 11130ListContainer.prototype.onEnd = function (event) { 11131 $('.group-items').removeClass('group-items__on-move'); 11132 xcart.trigger('layout.dragStop'); 11133}; 11134 11135ListContainer.prototype.onRemove = function (event) { 11136 11137}; 11138 11139 11140ListContainer.prototype.onFilter = function (event) { 11141 11142}; 11143 11144ListContainer.prototype.onMove = function (event) { 11145 xcart.trigger( 11146 'layout.listElemMoved', 11147 event 11148 ); 11149}; 11150 11151xcart.autoload(ListContainer, '.layout-editor-sidebar');; 11152/* AUTOGENERATED: layout_block_controller.js */ 11153/* vim: set ts=2 sw=2 sts=2 et: */ 11154 11155/** 11156 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 11157 * See https://www.x-cart.com/license-agreement.html for license details. 11158 */ 11159 11160if (_.isUndefined(jQuery.getQueryParameters)) { 11161 jQuery.extend({ 11162 getQueryParameters : function(str) { 11163 return (str || document.location.search).replace(/(^\?)/,'').split("&").map(function(n){return n = n.split("="),this[n[0]] = n[1],this}.bind({}))[0]; 11164 } 11165 }); 11166} 11167 11168function LayoutBlockWidget(base) 11169{ 11170 LayoutBlockWidget.superclass.constructor.apply(this, arguments); 11171 11172 this.widgetClass = this.base.data('widget'); 11173 11174 this.widgetTarget = xcart.getTarget(); 11175 11176 xcart.bind('layout.block.reload', _.bind(this.reload, this)); 11177 11178 this.base.data('controller', this); 11179} 11180 11181extend(LayoutBlockWidget, ALoadable); 11182 11183LayoutBlockWidget.prototype.reloadIfError = false;
11184 11185LayoutBlockWidget.prototype.shadeWidget = true; 11186 11187LayoutBlockWidget.prototype.defineWidgetParams = function() { 11188 return _.defaults( 11189 { 11190 'displayGroup': this.base.data('display') 11191 }, 11192 _.pick(jQuery.getQueryParameters(), (value, key, object) => { 11193 return key !== 'displayMode'; 11194 }) 11195 ); 11196}; 11197 11198LayoutBlockWidget.prototype.reload = function(event, args) { 11199 if (args.id === this.base.data('id') && this.base.data('is-reloaded-widget') === 1) { 11200 this.widgetParams = this.defineWidgetParams(); 11201 this.load(); 11202 } 11203}; 11204 11205// Place parsed request data into DOM 11206LayoutBlockWidget.prototype.insertIntoDOM = function(box) 11207{ 11208 this.base.find('.list-item-content').html(box); 11209 return this.base; 11210}; 11211 11212// Extract widget content 11213LayoutBlockWidget.prototype.extractContent = function(box) 11214{ 11215 box = jQuery(this.containerRequestPattern, box); 11216 return box.children(); 11217}; 11218 11219LayoutBlockWidget.autoload = function() { 11220 jQuery('.list-item[data-display]').each(function () { 11221 new LayoutBlockWidget(this); 11222 }); 11223}; 11224 11225xcart.autoload(LayoutBlockWidget);; 11226/* AUTOGENERATED: items_list.js */ 11227/* vim: set ts=2 sw=2 sts=2 et: */ 11228 11229/** 11230 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 11231 * See https://www.x-cart.com/license-agreement.html for license details. 11232 */ 11233 11234// Main class 11235function ListsController(base) 11236{ 11237 ListsController.superclass.constructor.apply(this, arguments); 11238 11239 if (this.base && this.base.length) { 11240 this.block = this.getListView(); 11241 } 11242} 11243 11244extend(ListsController, AController); 11245 11246ListsController.prototype.name = 'ItemsListController'; 11247 11248ListsController.prototype.findPattern = '.items-list'; 11249 11250ListsController.prototype.block = null; 11251 11252ListsController.prototype.selfUpdated = false; 11253 11254ListsController.prototype.getListView = function() 11255{ 11256 return new ListView(this.base); 11257}; 11258 11259// Initialize controller 11260ListsController.prototype.initialize = function() 11261{ 11262 var o = this; 11263 11264 this.base.bind( 11265 'reload', 11266 function(event, box) { 11267 o.bind(box); 11268 } 11269 ); 11270}; 11271 11272/** 11273 * Main widget (listView) 11274 */ 11275 11276function ListView(base) 11277{ 11278 this.widgetClass = xcart.getCommentedData(base, 'widget_class'); 11279 this.widgetTarget = xcart.getCommentedData(base, 'widget_target'); 11280 this.widgetParams = xcart.getCommentedData(base, 'widget_params'); 11281 this.replaceState = xcart.getCommentedData(base, 'replaceState'); 11282 this.replaceStatePrefix = xcart.getCommentedData(base, 'replaceStatePrefix'); 11283 this.listenToGetParams = xcart.getCommentedData(base, 'listenToGetParams'); 11284 11285 ListView.superclass.constructor.apply(this, arguments); 11286} 11287 11288extend(ListView, ALoadable); 11289 11290ListView.prototype.getCurrentPageIdParam = function() { 11291 const url = new URL(window.location); 11292 const urlParams = url.searchParams; 11293 11294 return urlParams.has('pageId') 11295 ? { 'pageId': parseInt(urlParams.get('pageId'), 10) } 11296 : {}; 11297}; 11298 11299ListView.prototype.load = function(params) 11300{ 11301 if (this.replaceState) { 11302 this.doReplaceState(params); 11303 } 11304 11305 if (this.listenToGetParams) { 11306 const url = new URL(window.location); 11307 const urlParams = url.searchParams; 11308 11309 _.mapObject(params, (value, key) => { 11310 if (key === 'pageId') { 11311 urlParams.set(key, value); 11312 } 11313 11314 if (key !== 'pageId' && key !== 'displayMode') { 11315 urlParams.delete('pageId'); 11316 } 11317 }); 11318 11319 11320 url.searchParams = urlParams.toString(); 11321 11322 history.pushState({}, null, url.toString()); 11323 } 11324 11325 if (!xcart.isRequesterEnabled) { 11326 return false; 11327 } 11328 11329 if (this.isLoading) { 11330 this.deferredLoad = true; 11331 return true; 11332 } 11333 11334 this.isLoading = true; 11335 this.deferredLoad = false; 11336 11337 this.lastLoadParams = params; 11338 11339 const newUrl = this.buildWidgetRequestURL(params); 11340 11341 if (this.base) { 11342 this.base.trigger('preload', [this, newUrl]); 11343 11344 if (typeof(this.preloadHandler) == 'function') { 11345 // Call preload event handler 11346 this.preloadHandler.call(this.base); 11347 } 11348 } 11349 11350 var state = { 'widget': this, 'url': newUrl, 'options': this.getLoaderOptions() } 11351 11352 this.triggerVent('preload', state); 11353 11354 this.saveState(); 11355 11356 this.shade(); 11357 11358 state.xhr = xcart.get(state.url, this.loadHandlerCallback, null, state.options); 11359 11360 this.triggerVent('afterload', state); 11361 11362 return state.xhr; 11363}; 11364 11365 11366ListView.prototype.shadeWidget = true; 11367 11368ListView.prototype.sessionCell = null; 11369 11370ListView.prototype.postprocess = function(isSuccess, initial) 11371{ 11372 ListView.superclass.postprocess.apply(this, arguments); 11373 11374 if (isSuccess) { 11375 11376 const o = this; 11377 11378 // Register page click handler 11379 jQuery('.pagination a', this.base).click( 11380 function() { 11381 // scroll page to list top 11382 jQuery('html, body').animate({scrollTop: o.base.offset().top}); 11383 11384 return !o.load({'pageId': xcart.getValueFromClass(this, 'page')}); 11385 } 11386 ); 11387 jQuery('input.page-length').validationEngine(); 11388 11389 // Register page count change handler 11390 jQuery('input.page-length', this.base).change( 11391 function() { 11392 if (!o.isLoading) {
11393 if(!jQuery(this).validationEngine('validate')) { 11394 count = parseInt(jQuery(this).val()); 11395 11396 if (isNaN(count)) { 11397 //TODO We must take it from the previous widget parameters ... 11398 count = 10; 11399 11400 } else if (count < 1) { 11401 count = 1; 11402 } 11403 11404 if (count != jQuery(this).val()) { 11405 jQuery(this).val(count); 11406 } 11407 11408 o.load({ 11409 'pageId': 1, 11410 'itemsPerPage': count 11411 }); 11412 } 11413 } 11414 } 11415 ); 11416 11417 jQuery('input.page-length', this.base).keypress( 11418 function(event) { 11419 if (event.keyCode == 13) { 11420 jQuery(event.currentTarget).change(); 11421 } 11422 } 11423 ); 11424 11425 window.addEventListener('popstate', function () { 11426 if (xcart.getCommentedData(o.base, 'listenToGetParams')) { 11427 location.reload(); 11428 } 11429 }); 11430 } 11431};; 11432/* AUTOGENERATED: items_list.js */ 11433/* vim: set ts=2 sw=2 sts=2 et: */ 11434 11435/** 11436 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 11437 * See https://www.x-cart.com/license-agreement.html for license details. 11438 */ 11439 11440decorate( 11441 'ListView', 11442 'postprocess', 11443 function(isSuccess, initial) 11444 { 11445 arguments.callee.previousMethod.apply(this, arguments); 11446 11447 if (isSuccess) { 11448 var o = this; 11449 11450 jQuery('.per-page-box .list-type-grid a', this.base).click(function () { 11451 jQuery('html, body').animate({scrollTop: o.base.offset().top}); 11452 return !o.load({ 11453 'pageId': 1, 11454 'itemsPerPage': jQuery(this).data('items-per-page') 11455 }); 11456 }); 11457 } 11458 } 11459);; 11460/* AUTOGENERATED: products_list.js */ 11461/* vim: set ts=2 sw=2 sts=2 et: */ 11462 11463/** 11464 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 11465 * See https://www.x-cart.com/license-agreement.html for license details. 11466 */ 11467 11468function ProductsListView(base) 11469{ 11470 ProductsListView.superclass.constructor.apply(this, arguments); 11471 11472 xcart.bind('popup.close', _.bind(this.handleCloseQuickLookPopup, this)); 11473 11474 this.requests = []; 11475} 11476 11477extend(ProductsListView, ListView); 11478 11479// Products list class 11480function ProductsListController(base) 11481{ 11482 ProductsListController.superclass.constructor.apply(this, arguments); 11483 11484 xcart.bind('updateCart', _.bind(this.updateCartHandler, this)); 11485} 11486 11487extend(ProductsListController, ListsController); 11488 11489ProductsListController.prototype.name = 'ProductsListController'; 11490 11491ProductsListController.prototype.findPattern += '.items-list-products'; 11492 11493ProductsListController.prototype.getListView = function() 11494{ 11495 return new ProductsListView(this.base); 11496}; 11497 11498ProductsListController.prototype.updateCartHandler = function(event, data) { 11499 if (_.isUndefined(data.items)) { 11500 return; 11501 } 11502 11503 for (let i = 0; i < data.items.length; i++) { 11504 if (data.items[i].object_type == 'product') { 11505 11506 // Added mark 11507 const productPattern = '.product.productid-' + data.items[i].object_id; 11508 const product = jQuery(productPattern, this.base); 11509 const oldQty = product.find('.qty-in-cart').val(); 11510 11511 if ( 11512 !oldQty 11513 || !data.items[i].quantity_change 11514 || !product.hasClass('qty-update-is-needed') 11515 ) { 11516 return; 11517 } 11518 11519 const newQty = parseInt(oldQty) + data.items[i].quantity_change; 11520 11521 if (newQty > 0) { 11522 product.addClass('product-added'); 11523 if (this.block) { 11524 this.block.triggerVent('item.addedToCart', {'view': this, 'item': product}); 11525 } 11526 11527 } else { 11528 product.removeClass('product-added'); 11529 if (this.block) { 11530 this.block.triggerVent('item.removedFromCart', {'view': this, 'item': product}); 11531 } 11532 } 11533 11534 if (product.hasClass('qty-update-is-needed')) { 11535 product 11536 .find('.qty-in-cart') 11537 .val(newQty); 11538 11539 product.removeClass('qty-update-is-needed'); 11540 } 11541 11542 // Check inventory limit 11543 if (data.items[i].is_limit) { 11544 product.addClass('out-of-stock'); 11545 11546 product 11547 .find('.increase-qty') 11548 .prop('disabled', true); 11549 11550 product 11551 .find('.add-to-cart') 11552 .prop('disabled', true); 11553 11554 if (this.block) { 11555 this.block.triggerVent('item.outOfStock', {'view': this, 'item': product}); 11556 } 11557 11558 } else { 11559 product.removeClass('out-of-stock all-stock-in-cart') 11560 11561 product 11562 .find('.increase-qty') 11563 .prop('disabled', false); 11564 11565 product 11566 .find('.add-to-cart') 11567 .prop('disabled', false); 11568 11569 if (this.block) { 11570 this.block.triggerVent('item.stockIncrease', {'view': this, 'item': product}); 11571 } 11572 } 11573 } 11574 } 11575}; 11576 11577ProductsListView.prototype.postprocess = function(isSuccess, initial) 11578{ 11579 ProductsListView.superclass.postprocess.apply(this, arguments); 11580 11581 const self = this; 11582 11583 if (isSuccess) { 11584 11585 // Column switcher for 'table' display mode 11586 jQuery('.products-table .column-switcher', this.base).commonController('markAsColumnSwitcher'); 11587 11588 const currentPageIdParam = self.getCurrentPageIdParam(); 11589 11590 // Register "Changing display mode" handler 11591 jQuery('.display-modes a', this.base).click( 11592 function() { 11593 return !self.load({ 11594 ...currentPageIdParam, 11595 'displayMode': jQuery(this).attr('class') 11596 }); 11597 } 11598 ); 11599 11600 // Register "Sort by" selector handler 11601 jQuery('.sort-crit a', this.base).click( 11602 function () { 11603 return !self.load({ 11604 'pageId': 1, 11605 'sortBy': jQuery(this).data('sort-by'), 11606 'sortOrder': jQuery(this).data('sort-order'), 11607 'mode': 'append' 11608 }); 11609 } 11610 ); 11611 11612 xcart.bind( 11613 'afterPopupPlace', 11614 function() { 11615 new ProductDetailsController(jQuery('.ui-dialog div.product-quicklook')); 11616 } 11617 ); 11618 11619 // Manual set cell's height 11620 this.base.find('table.products-grid tr').each( 11621 function () { 11622 let height = 0; 11623 jQuery('div.product', this).each( 11624 function() { 11625 height = Math.max(height, jQuery(this).height()); 11626 } 11627 ); 11628 } 11629 ); 11630 11631 // Process click on 'Add to cart' buttons by AJAX 11632 jQuery('.add-to-cart, .increase-qty', this.base).not('.link').each( 11633 function (index, elem) { 11634 jQuery(elem).click(function() { 11635 11636 let product = $(elem).closest('.product-cell').find('.product'); 11637 if (!product.length) { 11638 product = $(elem).closest('.product-cell'); 11639 } 11640 11641 const pid = xcart.getValueFromClass(product, 'productid'); 11642 const forceOptions = product.is('.need-choose-options'); 11643 const changeQuantityButtons = self.getChangeQuantityButtons(product); 11644 11645 if (pid && !self.isLoading) { 11646 changeQuantityButtons.forEach((button) => { 11647 button.element.prop('disabled', true); 11648 }); 11649 } 11650
11651 product.addClass('qty-update-is-needed'); 11652 11653 if (forceOptions) { 11654 changeQuantityButtons.forEach((button) => { 11655 button.element.prop('disabled', button.disabledState); 11656 }); 11657 self.openQuickLook(product); 11658 } else { 11659 xcart.trigger('addToCartViaClick', {productId: pid}); 11660 11661 self.addToCart(elem) 11662 .always(function() { 11663 changeQuantityButtons.forEach((button) => { 11664 button.element.prop('disabled', button.disabledState); 11665 }); 11666 }); 11667 } 11668 }); 11669 } 11670 ); 11671 11672 // Process click on 'Decrease quantity' button by AJAX 11673 jQuery('.decrease-qty', this.base).each( 11674 function (index, elem) { 11675 jQuery(elem).click(function() { 11676 let product = $(elem).closest('.product-cell').find('.product'); 11677 if (!product.length) { 11678 product = $(elem).closest('.product-cell'); 11679 } 11680 11681 const pid = xcart.getValueFromClass(product, 'productid'); 11682 const changeQuantityButtons = self.getChangeQuantityButtons(product); 11683 11684 if (pid && !self.isLoading) { 11685 changeQuantityButtons.forEach((button) => { 11686 button.element.prop('disabled', true); 11687 }); 11688 } 11689 11690 product.addClass('qty-update-is-needed'); 11691 11692 xcart.trigger('removeFromCartViaClick', {productId: pid}); 11693 11694 self.removeFromCart(elem) 11695 .always(function() { 11696 changeQuantityButtons.forEach((button) => { 11697 button.element.prop('disabled', button.disabledState); 11698 }); 11699 }); 11700 }); 11701 } 11702 ); 11703 } // if (isSuccess) 11704}; // ProductsListView.prototype.postprocess() 11705 11706 11707ProductsListView.prototype.productPattern = '.products-grid .product, .products-list .product, .products-sidebar .product'; 11708 11709 11710// Post AJAX request to add product to cart 11711ProductsListView.prototype.addToCart = function (elem) { 11712 const $elem = jQuery(elem); 11713 const pid = xcart.getValueFromClass($elem, 'productid'); 11714 11715 let xhr = new $.Deferred(); 11716 11717 if (pid && !this.isLoading) { 11718 if (this) { 11719 xhr = xcart.post( 11720 URLHandler.buildURL({ target: 'cart', action: 'add' }), 11721 _.bind(this.handleAddToCart, this),
11722 this.addToCartRequestParams($elem), 11723 { 11724 rpc: true 11725 } 11726 ); 11727 } 11728 } else { 11729 xhr.reject(); 11730 } 11731 11732 return xhr; 11733}; 11734 11735ProductsListView.prototype.addToCartRequestParams = function ($elem) { 11736 const pid = xcart.getValueFromClass($elem, 'productid'); 11737 const isProductAdded = ($elem.closest('.product-added').length > 0); 11738 11739 return { 11740 target: 'cart', 11741 action: 'add', 11742 product_id: pid, 11743 addLastUpdatedItem: isProductAdded 11744 } 11745} 11746 11747ProductsListView.prototype.handleAddToCart = function (XMLHttpRequest, textStatus, data, isValid) { 11748 if (!isValid) { 11749 xcart.trigger( 11750 'message', 11751 { 11752 text: 'An error occurred during adding the product to cart. Please refresh the page and try to add the product to cart again or contact the store administrator.', 11753 type: 'error' 11754 } 11755 ); 11756 } 11757}; 11758 11759// Post AJAX request to remove product from cart 11760ProductsListView.prototype.removeFromCart = function (elem) { 11761 const $elem = jQuery(elem); 11762 const pid = xcart.getValueFromClass($elem, 'productid'); 11763 11764 let xhr = new $.Deferred(); 11765 11766 if (pid && !this.isLoading) { 11767 if (this) { 11768 xhr = xcart.post( 11769 URLHandler.buildURL({ target: 'cart', action: 'remove' }), 11770 _.bind(this.handleRemoveFromCart, this),
11771 this.removeFormCartRequestParams($elem), 11772 { 11773 rpc: true 11774 } 11775 ); 11776 } 11777 } else { 11778 xhr.reject(); 11779 } 11780 11781 return xhr; 11782}; 11783 11784ProductsListView.prototype.removeFormCartRequestParams = function (elem) { 11785 const pid = xcart.getValueFromClass(elem, 'productid'); 11786 11787 return { 11788 target: 'cart', 11789 action: 'remove', 11790 product_id: pid 11791 } 11792} 11793 11794ProductsListView.prototype.handleRemoveFromCart = function (XMLHttpRequest, textStatus, data, isValid) { 11795 if (!isValid) { 11796 xcart.trigger( 11797 'message', 11798 { 11799 text: 'An error occurred during removing the product from cart. Please refresh the page and try to remove the product from cart again or contact the store administrator.', 11800 type: 'error' 11801 } 11802 ); 11803 } 11804}; 11805 11806ProductsListView.prototype.focusOnFirstOption = _.once(function() { 11807 xcart.bind('afterPopupPlace', function(event, data){ 11808 if (popup.currentPopup.box.hasClass('ctrl-customer-quicklook')) { 11809 const option = popup.currentPopup.box.find('.editable-attributes select, input').filter(':visible').first(); 11810 option.focus(); 11811 } 11812 }) 11813}); 11814 11815ProductsListView.prototype.openQuickLook = function(elem) { 11816 this.focusOnFirstOption(); 11817 return !popup.load( 11818 URLHandler.buildURL(this.openQuickLookParams(elem)), 11819 function () { 11820 jQuery('.formError').hide(); 11821 }, 11822 50000 11823 ); 11824}; 11825 11826ProductsListView.prototype.handleCloseQuickLookPopup = function(event, data) 11827{ 11828 if (data.box && data.box.find('.product-quicklook').length > 0 && jQuery('body').find(data.box).length > 0) { 11829 data.box.dialog('destroy'); 11830 data.box.remove(); 11831 } 11832}; 11833 11834ProductsListView.prototype.openQuickLookParams = function (elem) { 11835 const product_id = xcart.getValueFromClass(elem, 'productid'); 11836 11837 return { 11838 target: 'quick_look', 11839 action: '', 11840 product_id: product_id, 11841 only_center: 1 11842 } 11843} 11844 11845// Get event namespace (prefix) 11846ProductsListView.prototype.getEventNamespace = function () { 11847 return 'list.products'; 11848}; 11849 11850ProductsListView.prototype.getChangeQuantityButtons = function (product) { 11851 const result = []; 11852 const buttons = [ 11853 product.find('.add-to-cart'), 11854 product.find('.increase-qty'), 11855 product.find('.decrease-qty') 11856 ]; 11857 11858 buttons.forEach((button) => { 11859 result.push({ 11860 'element': button, 11861 'disabledState': button.prop('disabled') 11862 }) 11863 }); 11864 11865 return result; 11866} 11867 11868/** 11869 * Load product lists controller 11870 */ 11871xcart.autoload(ProductsListController);; 11872/* AUTOGENERATED: attributetoform.js */ 11873/* vim: set ts=2 sw=2 sts=2 et: */ 11874 11875/** 11876 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 11877 * See https://www.x-cart.com/license-agreement.html for license details. 11878 */ 11879 11880jQuery(function () { 11881 $(document).on('click', '.add2cart', function () { 11882 var form_id = $('form.product-details').attr('id'); 11883 $('.editable-attributes :input').each(function () { 11884 $(this).attr('form', form_id); 11885 }); 11886 }); 11887});; 11888/* AUTOGENERATED: script.js */ 11889/* vim: set ts=2 sw=2 sts=2 et: */ 11890 11891/** 11892 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 11893 * See https://www.x-cart.com/license-agreement.html for license details. 11894 */ 11895 11896jQuery(function() { 11897 xcart.bind('block.product.details.postprocess', function() { 11898 $('.product-details-tabs ul.tabs').tabCollapse({ 11899 tabsClass: 'hidden-xs', 11900 accordionClass: 'visible-xs' 11901 }); 11902 }); 11903 11904 xcart.registerTriggersBind('update-product-page', function () { 11905 var heightFixer = function () { 11906 jQuery(this).addClass('notransition'); 11907 11908 if (this.scrollHeight > this.clientHeight) { 11909 this.style.height = (this.scrollHeight + 10) + 'px'; 11910 } 11911 11912 jQuery(this).removeClass('notransition'); 11913 }; 11914 11915 jQuery('ul.attribute-values .form-control').floatingLabel(); 11916 jQuery('ul.attribute-values textarea.form-control').keyup(heightFixer).keyup(); 11917 }); 11918});; 11919/* AUTOGENERATED: controller.js */ 11920/* vim: set ts=2 sw=2 sts=2 et: */ 11921 11922/** 11923 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 11924 * See https://www.x-cart.com/license-agreement.html for license details. 11925 */ 11926 11927/** 11928 * Controller 11929 */ 11930 11931function ProductDetailsController(base) 11932{ 11933 var o = this; 11934 ProductDetailsController.superclass.constructor.apply(this, arguments); 11935 11936 if ( 11937 this.base 11938 && this.base.get(0) 11939 && ( 11940 xcart.getCommentedData(jQuery('body'), 'product_id') 11941 || ( 11942 jQuery('form.product-details', this.base).get(0) 11943 && jQuery('form.product-details', this.base).get(0).elements.namedItem('product_id') 11944 ) 11945 ) 11946 ) { 11947 this.productId = xcart.getCommentedData(jQuery('body'), 'product_id') 11948 ? xcart.getCommentedData(jQuery('body'), 'product_id') 11949 : jQuery('form.product-details', this.base).get(0).elements.namedItem('product_id').value; 11950 11951 this.block = new ProductDetailsView(this.base, this.productId); 11952 11953 xcart.bind( 11954 'updateCart', 11955 function(event, data) { 11956 var i; 11957 11958 if (!_.isUndefined(data.items)) { 11959 for (i = 0; i < data.items.length; i++) { 11960 if (data.items[i].object_type == 'product' && data.items[i].object_id == o.productId) { 11961 if (0 < data.items[i].quantity && !jQuery('body').hasClass('added-product')) { 11962 jQuery('body').addClass('added-product') 11963 .removeClass('non-added-product'); 11964 11965 } else if (0 == data.items[i].quantity && jQuery('body').hasClass('added-product')) { 11966 jQuery('body').addClass('non-added-product') 11967 .removeClass('added-product'); 11968 } 11969 } 11970 } 11971 11972 if (!o.selfAdded) { 11973 for (i = 0; i < data.items.length; i++) { 11974 if (data.items[i].object_type == 'product' && data.items[i].object_id == o.productId) { 11975 o.block.load(); 11976 } 11977 } 11978 } 11979 } 11980 } 11981 ); 11982 11983 var use = this.base.data('use-widgets-collection'); 11984 if ('undefined' == typeof(use) || use) { 11985 xcart.callTriggersBind('update-product-page'); 11986 } 11987 } 11988} 11989 11990extend(ProductDetailsController, AController); 11991 11992// Prodiuct id 11993ProductDetailsController.prototype.productId = null; 11994 11995// Controller name 11996ProductDetailsController.prototype.name = 'ProductDetailsController'; 11997 11998// Find pattern 11999ProductDetailsController.prototype.findPattern = 'div.product-details'; 12000 12001// Controller associated main widget 12002ProductDetailsController.prototype.block = null; 12003 12004// Controller associated buttons block widget 12005ProductDetailsController.prototype.buttonsBlock = null; 12006 12007ProductDetailsController.prototype.selfAdded = false;
12008 12009// Initialize controller 12010ProductDetailsController.prototype.initialize = function() 12011{ 12012 this.base.bind( 12013 'reload', 12014 _.bind( 12015 function(event, box) { 12016 this.bind(box); 12017 }, 12018 this 12019 ) 12020 ); 12021}; 12022 12023/** 12024 * Main widget 12025 */ 12026 12027function ProductDetailsView (base, productId) { 12028 this.callSupermethod('constructor', arguments); 12029 12030 this.productId = productId; 12031 12032 this.bind('local.loaded', function () { 12033 xcart.trigger('update-product-page', productId); 12034 }); 12035 12036 xcart.bind('mm-menu.created', function(event, api){ 12037 if (_.has(jQuery, 'colorbox')) { 12038 jQuery.colorbox.remove(); 12039 } 12040 }); 12041 xcart.bind('initialize-product-gallery', _.bind(this.initializeGallery, this)); 12042 12043 this.linkClickHandler = _.bind( 12044 function(event) 12045 { 12046 event.stopPropagation(); 12047 12048 this.showLightbox(); 12049 jQuery('.product-image-gallery li.selected a', this.base).eq(0).trigger('click'); 12050 12051 return false; 12052 }, 12053 this 12054 ); 12055} 12056 12057extend(ProductDetailsView, ALoadable); 12058 12059// Prodiuct id 12060ProductDetailsView.prototype.productId = null; 12061 12062ProductDetailsView.prototype.shadeClass = 'wait-progress overlay-blur-base'; 12063// Widget target 12064ProductDetailsView.prototype.widgetTarget = 'product'; 12065 12066// Widget class name 12067ProductDetailsView.prototype.widgetClass = '\\XLite\\View\\Product\\Details\\Customer\\Page\\Main'; 12068 12069// Imgaes gallery 12070ProductDetailsView.prototype.galleries = null; 12071 12072// Zoom layer max. width 12073ProductDetailsView.prototype.zoomMaxWidth = 460; 12074 12075// Width after which the zoom will be initialized 12076ProductDetailsView.prototype.zoomWidth = 991; 12077 12078// Zoom widget 12079ProductDetailsView.prototype.zoomWidget = false; 12080 12081// Zoom layer max. width 12082ProductDetailsView.prototype.kZoom = 1.3; 12083 12084ProductDetailsView.prototype.shadeWidget = function() 12085{ 12086 return 0 == this.base.parents('.ui-dialog').length; 12087}; 12088 12089ProductDetailsView.prototype.preloadHandler = function () 12090{ 12091 if (this.hasClass('product-quicklook')) { 12092 popup.close(); 12093 } 12094}; 12095 12096ProductDetailsView.prototype.initializeGallery = function () 12097{ 12098 var self = this; 12099 self.galleries = []; 12100 jQuery('.product-image-gallery', this.base).each(function () { 12101 self.galleries.push($(this).find('li')); 12102 }); 12103}; 12104 12105ProductDetailsView.prototype.applyToGalleries = function (callback) 12106{ 12107 if (this.galleries) { 12108 var self = this; 12109 this.galleries.forEach(function (gallery) { 12110 callback.apply(self, [gallery]); 12111 }) 12112 } 12113}; 12114 12115// Postprocess widget 12116ProductDetailsView.prototype.postprocess = function(isSuccess, initial) 12117{ 12118 this.callSupermethod('postprocess', arguments); 12119 12120 if (isSuccess) { 12121 // Hide popup title 12122 jQuery(this.base).parents('.ui-dialog').eq(0).addClass('no-title'); 12123 12124 this.initializeGallery(); 12125 12126 var o = this; 12127 12128 // Bind the cloud zoom triggering event. 12129 // The element initializes itself the cloud zoom widget 12130 jQuery('.cloud-zoom', this.base).bind( 12131 'cloud-zoom', 12132 function (event) { 12133 var rel; 12134 if (jQuery(window).width() > o.zoomWidth) { 12135 if (jQuery(this).data('zoom')) { 12136 jQuery(this).data('zoom').destroy(); 12137 } 12138 12139 var baseRel = _.object(_.map(jQuery(this).data('rel-base').split(','), function (value, key, list) { 12140 return _.map(_.trim(value).split(':'), function (value) {return _.trim(value);}); 12141 })); 12142 jQuery(this).attr('data-rel', jQuery(this).data('rel-base')); 12143 12144 // adjust zoom width and height for current image 12145 var img = jQuery('img', this); 12146 12147 if (typeof jQuery(this).CloudZoom !== "undefined") { 12148 jQuery(this).CloudZoom(); 12149 }; 12150 12151 rel = xcart.getRelArray(jQuery(this)); 12152 rel.zoomWidth = Math.min(img.width(), baseRel.zoomWidth); 12153 rel.zoomHeight = Math.min(img.height(), baseRel.zoomHeight); 12154 rel.adjustX = intval(img.offset().left - jQuery(this).offset().left); 12155 12156 if (rel.position !== "'inside'") { 12157 rel.adjustX += 10; 12158 jQuery(this).closest('.cloud-zoom-photo').addClass('cloud-zoom-outside').removeClass('cloud-zoom-inside'); 12159 } 12160 12161 12162 xcart.setRelArray(jQuery(this), rel); 12163 12164 if (typeof jQuery(this).CloudZoom !== "undefined") { 12165 jQuery(this).CloudZoom(); 12166 }; 12167 12168 jQuery('.image .product-photo img', o.base).css({width: '', height: ''}); 12169 } else { 12170 jQuery(this).closest('.cloud-zoom-photo').removeClass('cloud-zoom-outside').addClass('cloud-zoom-inside'); 12171 12172 jQuery(this).attr('data-rel', jQuery(this).data('rel-base')); 12173 12174 if (jQuery(this).data('zoom')) { 12175 jQuery(this).data('zoom').destroy(); 12176 } 12177 12178 rel = xcart.getRelArray(jQuery(this)); 12179 12180 var photo = jQuery('.image .product-photo', o.base); 12181 rel.position = "'inside'"; 12182 rel.adjustX = intval( 12183 photo.find('img').offset().left - photo.find('.cloud-zoom').offset().left 12184 ); 12185 12186 xcart.setRelArray(jQuery(this), rel); 12187 12188 jQuery(this).CloudZoom(); 12189 12190 jQuery('.image .product-photo img', o.base).css({width: 'auto', height: 'auto'}); 12191 } 12192 } 12193 ); 12194 12195 // Arrow-based image navigation 12196 jQuery('.image .left-arrow', this.base).click( 12197 function (event) { 12198 o.switchImage(-1); 12199 } 12200 ); 12201 12202 jQuery('.image .right-arrow', this.base).click( 12203 function (event) { 12204 o.switchImage(1); 12205 } 12206 ); 12207 12208 // Form AJAX-based submit 12209 var form = this.base.find('form.product-details').get(0); 12210 if (form) { 12211 form.commonController
12212 .enableBackgroundSubmit() 12213 .bind('local.beforeSubmit', _.bind(this.addProductToCart, this)) 12214 .bind('local.submitted', _.bind(this.postprocessAdd2Cart, this)) 12215 } 12216 12217 // Cloud zoom 12218 var cloud = jQuery('.cloud-zoom', this.base); 12219 12220 if (cloud.length) { 12221 // The zoom effect is removed from Quick look 12222 this.zoomWidget = !this.base.hasClass('product-quicklook'); 12223 12224 if (xcart.getCommentedData(cloud, 'kZoom')) { 12225 this.kZoom = xcart.getCommentedData(cloud, 'kZoom'); 12226 } 12227 12228 var imageWrapper = jQuery(document.createElement('div')).addClass('wrapper'); 12229 12230 cloud.wrap(imageWrapper); 12231 } 12232 12233 // Change Continue shopping button for QuickLook mode 12234 if (this.base.hasClass('product-quicklook') && 0 < this.base.parents('.blockUI').length) { 12235 jQuery('button.continue', this.base) 12236 .unbind('click') 12237 .removeAttr('onclick'); 12238 jQuery('button.continue', this.base).click( 12239 function() { 12240 popup.close(); 12241 return false; 12242 } 12243 ); 12244 } 12245 12246 // Show Lightbox on the image click 12247 cloud.click( 12248 function(event) { 12249 o.showLightbox(); 12250 jQuery('.product-image-gallery li.selected a').eq(0).trigger('click'); 12251 12252 return false; 12253 } 12254 ); 12255 12256 // Gallery 12257 if (typeof(window.lightBoxImagesDir) != 'undefined') { 12258 jQuery('.loupe', this.base).click( 12259 function(event) { 12260 o.showLightbox(); 12261 setTimeout( 12262 function() { 12263 jQuery('.product-image-gallery li.selected a').eq(0).trigger('click'); 12264 }, 12265 500 12266 ); 12267 12268 return false; 12269 } 12270 ); 12271 } 12272 12273 this.hideLightbox(); 12274 12275 // Tabs 12276 var tabsBase = jQuery('.product-details-tabs', this.base); 12277 var initialURL = document.location.toString().split('#')[0]; 12278 12279 tabsBase.find('.tabs li a').click( 12280 _.bind( 12281 function (event) { 12282 event.preventDefault(); 12283 12284 var link = jQuery(event.currentTarget); 12285 this.openTab(link); 12286 12287 if (history.replaceState) { 12288 history.replaceState(null, null, initialURL + '#' + link.data('id')); 12289 12290 } else { 12291 self.location.hash = link.data('id'); 12292 } 12293 }, 12294 this 12295 ) 12296 ); 12297 12298 this.checkLocation(); 12299 12300 if (jQuery('.product-image-gallery li a', this.base).length) { 12301 // TODO: improve to skip additional JS manipulations 12302 // like resizing etc when it is not needed 12303 jQuery('.product-image-gallery li a', o.base).first().click(); 12304 } else if (this.zoomWidget && !cloud.data('zoom')) { 12305 cloud.trigger('cloud-zoom'); 12306 } 12307 12308 jQuery('a.link-to-tab').click( 12309 _.bind( 12310 function (event) { 12311 self.location = event.currentTarget.href; 12312 this.checkLocation(); 12313 }, 12314 this 12315 ) 12316 ); 12317 } 12318}; 12319 12320ProductDetailsView.prototype.openTab = function(link) 12321{ 12322 var tabsBase = jQuery('.product-details-tabs', this.base); 12323 12324 link = jQuery(link); 12325 tabsBase.find('.tabs li').removeClass('active'); 12326 link.parent().addClass('active'); 12327 12328 tabsBase.find('.tabs-container .tab-container').hide(); 12329 tabsBase.find('.tabs-container #' + link.data('id')).show(); 12330 12331 this.triggerVent('tab.open', { widget: this, tab: link }); 12332 12333 if (link.closest('.panel').find('.panel-collapse').length) { 12334 var pane = link.closest('.panel').find('.panel-collapse').first(); 12335 pane.on('transitionend webkitTransitionEnd oTransitionEnd', function () { 12336 pane.unbind('transitionend webkitTransitionEnd oTransitionEnd'); 12337 $('html, body').animate({ 12338 scrollTop: (link.offset().top - $('#header-area').height()) 12339 },300); 12340 }); 12341 12342 if (pane.hasClass('in')) { 12343 setTimeout(function () { 12344 $('html, body').animate({ 12345 scrollTop: (link.offset().top - $('#header-area').height()) 12346 }, 300); 12347 }, 0); 12348 pane.unbind('transitionend webkitTransitionEnd oTransitionEnd'); 12349 } 12350 pane.collapse('show'); 12351 } 12352}; 12353 12354ProductDetailsView.prototype.checkLocation = function() 12355{ 12356 var hash = ((self.location.hash) + '').replace(/^#/, ''); 12357 if (hash) { 12358 var tabsBase = jQuery('.product-details-tabs', this.base); 12359 var found = null; 12360 12361 var state = { 12362 'widget': this, 12363 'hash': hash 12364 }; 12365 12366 this.triggerVent('tab.hash.resolve', state); 12367 hash = state.hash; 12368 12369 tabsBase.find('.tabs li a').each( 12370 function() { 12371 var link = jQuery(this); 12372 if (link.data('id') == hash) { 12373 found = link; 12374 } else if (link.data('alt-id') == hash) { 12375 found = link; 12376 } 12377 } 12378 ); 12379 12380 state = { 12381 'tab': found, 12382 'widget': this, 12383 'hash': hash 12384 }; 12385 12386 this.triggerVent('tab.detection', state); 12387 12388 if (state.tab) { 12389 this.openTab(state.tab); 12390 } else { 12391 tabsBase.find('a[data-id="' + hash + '"]').first().click(); 12392 } 12393 } else { 12394 var tabsBase = jQuery('.product-details-tabs', this.base); 12395 this.openTab(tabsBase.find('.tabs li a').first()); 12396 } 12397}; 12398 12399ProductDetailsView.prototype.showLightbox = function() 12400{ 12401 if (_.has(jQuery, 'colorbox')) { 12402 jQuery('.product-image-gallery a', this.base) 12403 .unbind('click') 12404 .colorbox(this.getColorboxOptions()); 12405 }; 12406}; 12407 12408ProductDetailsView.prototype.hideLightbox = function() 12409{ 12410 var o = this; 12411 12412 jQuery('.product-image-gallery a', this.base) 12413 .unbind('click') 12414 .bind( 12415 'click', 12416 function(event) { 12417 event.stopPropagation(); 12418 o.selectImage( 12419 jQuery.inArray(this, jQuery(this).parents('ul').eq(0).find('a').get()) 12420 ); 12421 12422 return false;
12423 } 12424 ); 12425}; 12426 12427ProductDetailsView.prototype.getColorboxOptions = function () { 12428 return { 12429 onComplete: function () { 12430 jQuery('#cboxCurrent').css('display', 'none'); 12431 jQuery('#cboxTitle').text(jQuery('img', this).attr('alt')); 12432 }, 12433 onClosed: _.bind(this.hideLightbox, this), 12434 maxWidth: jQuery(window).width(), 12435 maxHeight: jQuery(window).height(), 12436 title: jQuery('.product-photo img', this.base).attr('alt') 12437 }; 12438}; 12439 12440// Get base element for shade / unshade operation 12441ProductDetailsView.prototype.getShadeBase = function () { 12442 return jQuery('.shade-base', this.base).eq(0); 12443}; 12444 12445// Image gallery switcher 12446ProductDetailsView.prototype.switchImage = function (diff) { 12447 var next = -1; 12448 12449 this.applyToGalleries(function (gallery) { 12450 if (next !== -1) { 12451 return; 12452 } 12453 var selected = -1; 12454 var i = 0; 12455 12456 // Detect current index 12457 gallery.each(function () { 12458 if (selected === -1 && jQuery(this).hasClass('selected')) { 12459 selected = i; 12460 } 12461 i++; 12462 }); 12463 12464 if (selected === -1) { 12465 selected = 0; 12466 } 12467 12468 // Calculate new position 12469 next = selected + diff; 12470 12471 if (next < 0) { 12472 next = gallery.length - Math.abs(next) % gallery.length; 12473 } else if (next >= gallery.length) { 12474 next = next % gallery.length; 12475 } 12476 }); 12477 12478 this.selectImage(next); 12479}; 12480 12481// Select image from gallery 12482ProductDetailsView.prototype.selectImage = function (pos) { 12483 this.applyToGalleries(function (gallery) { 12484 gallery.removeClass('selected'); 12485 12486 // Refresh main image and another options + cloud zoom plugin restart 12487 var next = gallery.eq(pos); 12488 next.addClass('selected'); 12489 12490 if (this.zoomWidget) { 12491 var cloud = jQuery('.cloud-zoom', this.base); 12492 12493 if (cloud.data('zoom')) { 12494 cloud.data('zoom').destroy(); 12495 } else { 12496 cloud.unbind('click', this.linkClickHandler); 12497 } 12498 12499 cloud.attr('href', jQuery('a', next).attr('href')); 12500 } 12501 12502 var middle = jQuery('img.middle', next).eq(0); 12503 if (middle.length > 0) { 12504 var src = middle.attr('src') || null; 12505 var srcset = middle.attr('srcset') || null; 12506 var alt = middle.attr('alt') || null; 12507 jQuery('.image .product-photo img', this.base) 12508 .hide() 12509 .attr('src', src) 12510 .attr('srcset', srcset) 12511 .attr('alt', alt) 12512 .show(); 12513 } 12514 12515 if (jQuery('a', next).length) { 12516 var params = jQuery('a', next).attr('rev'); 12517 12518 if (this.zoomWidget && params) { 12519 var tmp = xcart.parseObjectString('{' + params + '}'); 12520 if ( 12521 tmp && 12522 (tmp.width > (middle.width() * this.kZoom) 12523 || tmp.height > (middle.width() * this.kZoom)) 12524 ) { 12525 cloud.trigger('cloud-zoom'); 12526 } else { 12527 cloud.click(this.linkClickHandler); 12528 } 12529 } 12530 } 12531 }) 12532}; 12533 12534// Get additional parameters 12535ProductDetailsView.prototype.getParams = function(params) 12536{ 12537 params = this.callSupermethod('getParams', arguments); 12538 12539 params.product_id = this.productId; 12540 params.added = 1; 12541 12542 return params; 12543}; 12544 12545// Form submit handler 12546ProductDetailsView.prototype.addProductToCart = function(event) 12547{ 12548 // We do not shade widgets collection after the product is added to cart 12549 xcart.doShadeWidgetsCollection = false; 12550 this.base.get(0).controller.selfAdded = true; 12551 this.gatherFormFields(); 12552}; 12553 12554ProductDetailsView.prototype.gatherFormFields = function() 12555{ 12556 var elements = jQuery('input:not(:checkbox,:radio),select,textarea,input:checkbox:checked,input:radio:checked', this.base); 12557 12558 for (i = 0; i < elements.length; i++) { 12559 if ( 12560 (jQuery(elements[i]).hasClass('form-control') 12561 || jQuery(elements[i]).parents('.attribute-values').length !== 0 12562 ) 12563 && 0 == jQuery(elements[i]).parents('form').length 12564 ) { 12565 jQuery('<input>').attr({ 12566 type: 'hidden', 12567 name: jQuery(elements[i]).prop('name'), 12568 value: jQuery(elements[i]).val() 12569 }).appendTo('form.product-details'); 12570 } 12571 } 12572} 12573 12574// Form POST processor 12575ProductDetailsView.prototype.postprocessAdd2Cart = function(event, data) 12576{ 12577 this.base.get(0).controller.selfAdded = false;
12578 12579 data.isValid ? this.load() : this.unshade(); 12580}; 12581 12582// Get event namespace (prefix) 12583ProductDetailsView.prototype.getEventNamespace = function() 12584{ 12585 return 'block.product.details'; 12586}; 12587 12588xcart.autoload(ProductDetailsController); 12589 12590xcart.bind('updateCart', (event, data) => { 12591 let isProductInCart = false; 12592 const productDetailsBlock = document.querySelector('.product-details.box-product'); 12593 if (data.items && productDetailsBlock) { 12594 const productId = parseInt(document.querySelector('input[name="product_id"]').value); 12595 data.items.forEach(item => { 12596 if (item.object_id === productId) { 12597 isProductInCart = true; 12598 } 12599 }); 12600 productDetailsBlock.classList.toggle('product-added', isProductInCart); 12601 } 12602}); 12603 12604xcart.bind( 12605 'update-product-page', 12606 function (event, productId) 12607 { 12608 xcart.processUpdateWidgetsCollection( 12609 'update-product-page', 12610 '\\XLite\\View\\ProductPageCollection', 12611 {product_id: productId}, 12612 '.product-info-' + productId 12613 ); 12614 } 12615); 12616 12617var resizerTimer; 12618 12619jQuery(window).resize( 12620 function (event) { 12621 clearTimeout(resizerTimer); 12622 resizerTimer = setTimeout( 12623 function () { 12624 jQuery('.cloud-zoom').trigger('cloud-zoom'); 12625 }, 12626 500 12627 ); 12628 } 12629); 12630 12631define("ProductDetails", function () {});; 12632/* AUTOGENERATED: controller_quicklook.js */ 12633/* vim: set ts=2 sw=2 sts=2 et: */ 12634 12635/** 12636 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 12637 * See https://www.x-cart.com/license-agreement.html for license details. 12638 */ 12639 12640window.ProductQuickLookVariantViewLoading = false; 12641 12642/** 12643 * Controller 12644 */ 12645function ProductQuickLookVariantView (base) { 12646 this.base = jQuery(base); 12647 const self = this; 12648 12649 xcart.bind( 12650 'update-product-page', 12651 function(event, productId) { 12652 self.loadVariantsImages(productId); 12653 } 12654 ); 12655} 12656 12657ProductQuickLookVariantView.autoload = function() 12658{ 12659 if (jQuery('.ui-dialog.ui-widget').length > 1) { 12660 const $dialogWidget = jQuery('.ui-dialog.ui-widget:not(:last)'); 12661 $dialogWidget.off(); 12662 $dialogWidget.remove(); 12663 } 12664 12665 jQuery('.widget-controller .product-quicklook .product-photo').each( 12666 function() { 12667 new ProductQuickLookVariantView(this); 12668 } 12669 ); 12670}; 12671 12672// Load variant image 12673ProductQuickLookVariantView.prototype.loadVariantsImages = function(productId, shade) 12674{ 12675 this.base = jQuery('.widget-controller .product-quicklook .product-photo'); 12676 if (this.base.parent().siblings('.has-variants-mark').length > 0 12677 && this.base.parent().siblings('.has-variants-mark').data('value') 12678 && window.ProductQuickLookVariantViewLoading === false 12679 ) { 12680 window.ProductQuickLookVariantViewLoading = true; 12681 if (shade) { 12682 this.base.find('.image').append('<div class="single-progress-mark"><div></div></div>'); 12683 } 12684 12685 this.loadVariantsImagesShade = shade; 12686 12687 // Request variant images info 12688 xcart.get( 12689 URLHandler.buildURL(this.getURLParametersForLoadVariantsImages(productId)), 12690 _.bind(this.handleLoadVariantsImages, this), 12691 null, 12692 {dataType: 'json'} 12693 ); 12694 } 12695}; 12696 12697// Get URL parameters for variant image loading routine 12698ProductQuickLookVariantView.prototype.getURLParametersForLoadVariantsImages = function(productId) 12699{ 12700 let params = {product_id: productId}; 12701 params = array_merge(params, xcart.getWidgetsParams('update-product-page', params)); 12702 12703 return array_merge({'target': 'product', 'action': 'get_variant_images'}, params); 12704}; 12705 12706// Load variant image handler 12707ProductQuickLookVariantView.prototype.handleLoadVariantsImages = function (XMLHttpRequest, textStatus, data) 12708{ 12709 if (data && _.isString(data)) { 12710 data = jQuery.parseJSON(data); 12711 } 12712 12713 if (this.base.closest('.product-quicklook').find('.product-image-gallery:visible').length > 0) { 12714 this.processVariantImageAsGallery(data); 12715 } else { 12716 this.processVariantImageAsImage(data); 12717 } 12718 12719 if (this.loadVariantsImagesShade) { 12720 this.base.find('.product-details-info .single-progress-mark').remove(); 12721 } 12722 12723 window.ProductQuickLookVariantViewLoading = false; 12724}; 12725 12726ProductQuickLookVariantView.prototype.processVariantImageAsGallery = function (data) { 12727 const self = this, 12728 galleries = this.base.closest('.product-quicklook').find('.product-image-gallery'); 12729 12730 let imageChanged = false;
12731 12732 galleries.each(function () { 12733 const $gallery = jQuery(this); 12734 12735 if (data && _.isObject(data)) { 12736 imageChanged = imageChanged || $gallery.find('li.variant-image a').attr('href') !== data.full.url; 12737 12738 if (imageChanged) { 12739 // Remove old variant image 12740 $gallery.find('li.variant-image').remove(); 12741 12742 // Change images 12743 const li = $gallery.find('li').eq(0).clone(true); 12744 let elm = li.find('a img'); 12745 12746 elm.attr('width', data.gallery.w) 12747 .attr('height', data.gallery.h) 12748 .attr('src', data.gallery.url) 12749 .attr('srcset', data.gallery.srcset) 12750 .attr('alt', data.gallery.alt) 12751 .css({ 12752 width: data.gallery.w + 'px', 12753 height: data.gallery.h + 'px' 12754 }); 12755 12756 elm = li.find('img.middle'); 12757 elm.attr('width', data.main.w) 12758 .attr('height', data.main.h) 12759 .attr('src', data.main.url) 12760 .attr('srcset', data.main.srcset) 12761 .attr('alt', data.main.alt) 12762 .css({ 12763 width: data.main.w + 'px', 12764 height: data.main.h + 'px' 12765 }); 12766 12767 // Change gallery link 12768 li.find('a') 12769 .attr('href', data.full.url) 12770 .attr('rev', 'width: ' + data.full.w + ', height: ' + data.full.h); 12771 12772 li.addClass('variant-image'); 12773 12774 $gallery.find('li').eq(0).before(li); 12775 12776 // Gallery icon vertical alignment 12777 const margin = (li.height() - li.find('a img').height()) / 2; 12778 12779 li.find('a img').css({ 12780 'margin-top': Math.ceil(margin) + 'px', 12781 'margin-bottom': Math.floor(margin) + 'px' 12782 }); 12783 } 12784 12785 } else if ($gallery.find('li.variant-image').length > 0) { 12786 imageChanged = true; 12787 12788 // Remove old variant image 12789 $gallery.find('li.variant-image').remove(); 12790 } 12791 }); 12792 if (imageChanged) { 12793 self.initializeGallery(); 12794 xcart.trigger('initialize-product-gallery'); 12795 12796 self.applyToGalleries(function (gallery) { 12797 if (gallery.get(0)) { 12798 $(gallery.get(0)).find('a').click(); 12799 } 12800 }); 12801 } 12802}; 12803 12804ProductQuickLookVariantView.prototype.initializeGallery = function () 12805{ 12806 const self = this; 12807 self.galleries = []; 12808 jQuery('.product-image-gallery', this.base.closest('.product-quicklook')).each(function () { 12809 self.galleries.push($(this).find('li')); 12810 }); 12811}; 12812 12813ProductQuickLookVariantView.prototype.applyToGalleries = function (callback) 12814{ 12815 if (this.galleries) { 12816 const self = this; 12817 this.galleries.forEach(function (gallery) { 12818 callback.apply(self, [gallery]); 12819 }); 12820 } 12821}; 12822 12823ProductQuickLookVariantView.prototype.processVariantImageAsImage = function(data) 12824{ 12825 if (data && _.isObject(data)) { 12826 const elm = this.base.find('img.product-thumbnail'); 12827 elm.attr('width', data.main.w) 12828 .attr('height', data.main.h) 12829 .attr('src', data.main.url) 12830 .attr('srcset', data.main.srcset) 12831 .attr('alt', data.main.alt) 12832 .css({ 12833 width: data.main.w + 'px', 12834 height: data.main.h + 'px' 12835 }); 12836 12837 this.base.find('a.cloud-zoom').attr('href', data.full.url); 12838 this.base.find('.cloud-zoom').trigger('cloud-zoom'); 12839 12840 } else { 12841 this.applyDefaultImage(); 12842 } 12843 12844}; 12845 12846ProductQuickLookVariantView.prototype.applyDefaultImage = function() 12847{ 12848 const img = this.base.siblings('.default-image').find('img'); 12849 const elm = this.base.find('img.product-thumbnail'); 12850 12851 elm.attr('src', img.attr('src')) 12852 .attr('width', img.attr('width')) 12853 .attr('height', img.attr('height')) 12854 .css({ 12855 'width': img.attr('width') + 'px', 12856 'height': img.attr('height') + 'px' 12857 }); 12858 12859 this.base.find('a.cloud-zoom').attr('href', img.attr('src')); 12860 12861 this.base.find('.loupe').hide(); 12862 12863 const zoom = this.base.find('a.cloud-zoom').data('zoom'); 12864 if (zoom) { 12865 zoom.destroy(); 12866 } 12867 this.base.find('a.cloud-zoom') 12868 .unbind('click') 12869 .click(function() { return false; }); 12870}; 12871 12872 12873xcart.autoload(ProductQuickLookVariantView); 12874 12875xcart.microhandlers.add( 12876 'ProductQuickLookVariantView', 12877 '.widget-controller .product-quicklook .product-photo', 12878 function () { 12879 ProductQuickLookVariantView.autoload(); 12880 } 12881);; 12882/* AUTOGENERATED: add_to_cart.js */ 12883/* vim: set ts=2 sw=2 sts=2 et: */ 12884 12885/** 12886 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 12887 * See https://www.x-cart.com/license-agreement.html for license details. 12888 */ 12889 12890(function(){ 12891 12892 function flyToCart(element) { 12893 var target = $('.lc-minicart:visible'); 12894 var item = getProductRepresentationFor(element); 12895 12896 if (target.length && item.element && item.element.length) {
12897 $(item.element).css('pointer-events', 'none'); 12898 $(item.element).fly(target, { 12899 view: item.view, 12900 callback: function () { 12901 $(item.element).css('pointer-events', ''); 12902 } 12903 }); 12904 } 12905 } 12906 12907 decorate( 12908 'ProductsListView', 12909 'addToCart', 12910 function(element) { 12911 flyToCart(element); 12912 return arguments.callee.previousMethod.apply(this, arguments); 12913 } 12914 ); 12915 12916 xcart.bind( 12917 'popup.open', 12918 function() { 12919 $('body > img.photo').remove(); 12920 } 12921 ); 12922 12923 decorate( 12924 'ProductDetailsView', 12925 'addProductToCart', 12926 function() { 12927 if (!this.base.hasClass('product-quicklook')) { 12928 flyToCart(this.base); 12929 } 12930 return arguments.callee.previousMethod.apply(this, arguments); 12931 } 12932 ); 12933})();; 12934/* AUTOGENERATED: details_gallery.js */ 12935/* vim: set ts=2 sw=2 sts=2 et: */ 12936 12937/** 12938 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 12939 * See https://www.x-cart.com/license-agreement.html for license details. 12940 */ 12941 12942xcart.bind('init-cycle-gallery', function () { 12943 var initGallery = function() { 12944 $(this).data(jQuery.extend({}, xcart.getCommentedData($(this)), $(this).data())); 12945 var count = $(this).data('cycle-carousel-visible'); 12946 12947 if (!$(this).find('.cycle-carousel-wrap').length) { 12948 if ($(this).find($(this).data('cycle-slides')).length <= count) { 12949 $($(this).data('cycle-next')).hide(); 12950 $($(this).data('cycle-prev')).hide(); 12951 } else { 12952 $($(this).data('cycle-next')).show(); 12953 $($(this).data('cycle-prev')).show(); 12954 $(this).cycle({ 12955 slideCss: '' 12956 }); 12957 } 12958 } 12959 }; 12960 12961 var changeVisibleElemsCount = function() { 12962 var elemCount = Math.floor($(this).closest('.slides').width() / $(this).find('li').first().outerWidth(true)); 12963 elemCount = Math.min(elemCount, $(this).find('li').length); 12964 var changed = false; 12965 12966 if ($(this).data('cycle-carousel-visible') != elemCount && !isNaN(elemCount)) { 12967 $(this).attr('data-cycle-carousel-visible', elemCount); 12968 $(this).data('cycle-carousel-visible', elemCount); 12969 if ($(this).data('cycle.opts') !== undefined) { 12970 $(this).cycle('destroy'); 12971 } 12972 changed = true; 12973 } 12974 12975 return changed; 12976 }; 12977 12978 $('.product-image-gallery .cycle-slideshow').each(function () { 12979 changeVisibleElemsCount.apply(this); 12980 12981 $(window).resize(_.debounce(_.bind(function () { 12982 if (changeVisibleElemsCount.apply(this)) { 12983 initGallery.apply(this); 12984 } 12985 },this), 50)); 12986 12987 initGallery.apply(this); 12988 }); 12989}); 12990 12991jQuery(function () { 12992 xcart.trigger('init-cycle-gallery'); 12993 12994 xcart.bind('block.product.details.postprocess', function () { 12995 xcart.trigger('init-cycle-gallery'); 12996 }); 12997 12998 $('.cycle-cloak.cycle-slideshow') 12999 .on('cycle-initialized', function (event, opts) { 13000 $(this).removeClass('.cycle-cloak'); 13001 }) 13002 .on('cycle-update-view', function () { 13003 $(this).height($(this).find('.cycle-carousel-wrap').outerHeight(true)); 13004 }); 13005});; 13006/* AUTOGENERATED: jquery.cycle2.min.js */ 13007/*! 13008* jQuery Cycle2; version: 2.1.6 build: 20141007 13009* http://jquery.malsup.com/cycle2/ 13010* Copyright (c) 2014 M. Alsup; Dual licensed: MIT/GPL 13011*/ 13012!function(a){"use strict";function b(a){return(a||"").toLowerCase()}var c="2.1.6";a.fn.cycle=function(c){var d;return 0!==this.length||a.isReady?this.each(function(){var d,e,f,g,h=a(this),i=a.fn.cycle.log;if(!h.data("cycle.opts")){(h.data("cycle-log")===!1||c&&c.log===!1||e&&e.log===!1)&&(i=a.noop),i("--c2 init--"),d=h.data();for(var j in d)d.hasOwnProperty(j)&&/^cycle[A-Z]+/.test(j)&&(g=d[j],f=j.match(/^cycle(.*)/)[1].replace(/^[A-Z]/,b),i(f+":",g,"("+typeof g+")"),d[f]=g);e=a.extend({},a.fn.cycle.defaults,d,c||{}),e.timeoutId=0,e.paused=e.paused||!1,e.container=h,e._maxZ=e.maxZ,e.API=a.extend({_container:h},a.fn.cycle.API),e.API.log=i,e.API.trigger=function(a,b){return e.container.trigger(a,b),e.API},h.data("cycle.opts",e),h.data("cycle.API",e.API),e.API.trigger("cycle-bootstrap",[e,e.API]),e.API.addInitialSlides(),e.API.preInitSlideshow(),e.slides.length&&e.API.initSlideshow()}}):(d={s:this.selector,c:this.context},a.fn.cycle.log("requeuing slideshow (dom not ready)"),a(function(){a(d.s,d.c).cycle(c)}),this)},a.fn.cycle.API={opts:function(){return this._container.data("cycle.opts")},addInitialSlides:function(){var b=this.opts(),c=b.slides;b.slideCount=0,b.slides=a(),c=c.jquery?c:b.container.find(c),b.random&&c.sort(function(){return Math.random()-.5}),b.API.add(c)},preInitSlideshow:function(){var b=this.opts();b.API.trigger("cycle-pre-initialize",[b]);var c=a.fn.cycle.transitions[b.fx];c&&a.isFunction(c.preInit)&&c.preInit(b),b._preInitialized=!0},postInitSlideshow:function(){var b=this.opts();b.API.trigger("cycle-post-initialize",[b]);var c=a.fn.cycle.transitions[b.fx];c&&a.isFunction(c.postInit)&&c.postInit(b)},initSlideshow:function(){var b,c=this.opts(),d=c.container;c.API.calcFirstSlide(),"static"==c.container.css("position")&&c.container.css("position","relative"),a(c.slides[c.currSlide]).css({opacity:1,display:"block",visibility:"visible"}),c.API.stackSlides(c.slides[c.currSlide],c.slides[c.nextSlide],!c.reverse),c.pauseOnHover&&(c.pauseOnHover!==!0&&(d=a(c.pauseOnHover)),d.hover(function(){c.API.pause(!0)},function(){c.API.resume(!0)}
vendor: 17,533 bytes, lines 13012-13019
13012)),c.timeout&&(b=c.API.getSlideOpts(c.currSlide),c.API.queueTransition(b,b.timeout+c.delay)),c._initialized=!0,c.API.updateView(!0),c.API.trigger("cycle-initialized",[c]),c.API.postInitSlideshow()},pause:function(b){var c=this.opts(),d=c.API.getSlideOpts(),e=c.hoverPaused||c.paused;b?c.hoverPaused=!0:c.paused=!0,e||(c.container.addClass("cycle-paused"),c.API.trigger("cycle-paused",[c]).log("cycle-paused"),d.timeout&&(clearTimeout(c.timeoutId),c.timeoutId=0,c._remainingTimeout-=a.now()-c._lastQueue,(c._remainingTimeout<0||isNaN(c._remainingTimeout))&&(c._remainingTimeout=void 0)))},resume:function(a){var b=this.opts(),c=!b.hoverPaused&&!b.paused;a?b.hoverPaused=!1:b.paused=!1,c||(b.container.removeClass("cycle-paused"),0===b.slides.filter(":animated").length&&b.API.queueTransition(b.API.getSlideOpts(),b._remainingTimeout),b.API.trigger("cycle-resumed",[b,b._remainingTimeout]).log("cycle-resumed"))},add:function(b,c){var d,e=this.opts(),f=e.slideCount,g=!1;"string"==a.type(b)&&(b=a.trim(b)),a(b).each(function(){var b,d=a(this);c?e.container.prepend(d):e.container.append(d),e.slideCount++,b=e.API.buildSlideOpts(d),e.slides=c?a(d).add(e.slides):e.slides.add(d),e.API.initSlide(b,d,--e._maxZ),d.data("cycle.opts",b),e.API.trigger("cycle-slide-added",[e,b,d])}),e.API.updateView(!0),g=e._preInitialized&&2>f&&e.slideCount>=1,g&&(e._initialized?e.timeout&&(d=e.slides.length,e.nextSlide=e.reverse?d-1:1,e.timeoutId||e.API.queueTransition(e)):e.API.initSlideshow())},calcFirstSlide:function(){var a,b=this.opts();a=parseInt(b.startingSlide||0,10),(a>=b.slides.length||0>a)&&(a=0),b.currSlide=a,b.reverse?(b.nextSlide=a-1,b.nextSlide<0&&(b.nextSlide=b.slides.length-1)):(b.nextSlide=a+1,b.nextSlide==b.slides.length&&(b.nextSlide=0))},calcNextSlide:function(){var a,b=this.opts();b.reverse?(a=b.nextSlide-1<0,b.nextSlide=a?b.slideCount-1:b.nextSlide-1,b.currSlide=a?0:b.nextSlide+1):(a=b.nextSlide+1==b.slides.length,b.nextSlide=a?0:b.nextSlide+1,b.currSlide=a?b.slides.length-1:b.nextSlide-1)},calcTx:function(b,c){var d,e=b;return e._tempFx?d=a.fn.cycle.transitions[e._tempFx]:c&&e.manualFx&&(d=a.fn.cycle.transitions[e.manualFx]),d||(d=a.fn.cycle.transitions[e.fx]),e._tempFx=null,this.opts()._tempFx=null,d||(d=a.fn.cycle.transitions.fade,e.API.log('Transition "'+e.fx+'" not found. Using fade.')),d},prepareTx:function(a,b){var c,d,e,f,g,h=this.opts();return h.slideCount<2?void(h.timeoutId=0):(!a||h.busy&&!h.manualTrump||(h.API.stopTransition(),h.busy=!1,clearTimeout(h.timeoutId),h.timeoutId=0),void(h.busy||(0!==h.timeoutId||a)&&(d=h.slides[h.currSlide],e=h.slides[h.nextSlide],f=h.API.getSlideOpts(h.nextSlide),g=h.API.calcTx(f,a),h._tx=g,a&&void 0!==f.manualSpeed&&(f.speed=f.manualSpeed),h.nextSlide!=h.currSlide&&(a||!h.paused&&!h.hoverPaused&&h.timeout)?(h.API.trigger("cycle-before",[f,d,e,b]),g.before&&g.before(f,d,e,b),c=function(){h.busy=!1,h.container.data("cycle.opts")&&(g.after&&g.after(f,d,e,b),h.API.trigger("cycle-after",[f,d,e,b]),h.API.queueTransition(f),h.API.updateView(!0))},h.busy=!0,g.transition?g.transition(f,d,e,b,c):h.API.doTransition(f,d,e,b,c),h.API.calcNextSlide(),h.API.updateView()):h.API.queueTransition(f))))},doTransition:function(b,c,d,e,f){var g=b,h=a(c),i=a(d),j=function(){i.animate(g.animIn||{opacity:1},g.speed,g.easeIn||g.easing,f)};i.css(g.cssBefore||{}),h.animate(g.animOut||{},g.speed,g.easeOut||g.easing,function(){h.css(g.cssAfter||{}),g.sync||j()}),g.sync&&j()},queueTransition:function(b,c){var d=this.opts(),e=void 0!==c?c:b.timeout;return 0===d.nextSlide&&0===--d.loop?(d.API.log("terminating; loop=0"),d.timeout=0,e?setTimeout(function(){d.API.trigger("cycle-finished",[d])},e):d.API.trigger("cycle-finished",[d]),void(d.nextSlide=d.currSlide)):void 0!==d.continueAuto&&(d.continueAuto===!1||a.isFunction(d.continueAuto)&&d.continueAuto()===!1)?(d.API.log("terminating automatic transitions"),d.timeout=0,void(d.timeoutId&&clearTimeout(d.timeoutId))):void(e&&(d._lastQueue=a.now(),void 0===c&&(d._remainingTimeout=b.timeout),d.paused||d.hoverPaused||(d.timeoutId=setTimeout(function(){d.API.prepareTx(!1,!d.reverse)},e))))},stopTransition:function(){var a=this.opts();a.slides.filter(":animated").length&&(a.slides.stop(!1,!0),a.API.trigger("cycle-transition-stopped",[a])),a._tx&&a._tx.stopTransition&&a._tx.stopTransition(a)},advanceSlide:function(a){var b=this.opts();return clearTimeout(b.timeoutId),b.timeoutId=0,b.nextSlide=b.currSlide+a,b.nextSlide<0?b.nextSlide=b.slides.length-1:b.nextSlide>=b.slides.length&&(b.nextSlide=0),b.API.prepareTx(!0,a>=0),!1},buildSlideOpts:function(c){var d,e,f=this.opts(),g=c.data()||{};for(var h in g)g.hasOwnProperty(h)&&/^cycle[A-Z]+/.test(h)&&(d=g[h],e=h.match(/^cycle(.*)/)[1].replace(/^[A-Z]/,b),f.API.log("["+(f.slideCount-1)+"]",e+":",d,"("+typeof d+")"),g[e]=d);g=a.extend({},a.fn.cycle.defaults,f,g),g.slideNum=f.slideCount;try{delete g.API,delete g.slideCount,delete g.currSlide,delete g.nextSlide,delete g.slides}catch(i){}return g},getSlideOpts:function(b){var c=this.opts();void 0===b&&(b=c.currSlide);var d=c.slides[b],e=a(d).data("cycle.opts");return a.extend({},c,e)},initSlide:function(b,c,d){var e=this.opts();c.css(b.slideCss||{}),d>0&&c.css("zIndex",d),isNaN(b.speed)&&(b.speed=a.fx.speeds[b.speed]||a.fx.speeds._default),b.sync||(b.speed=b.speed/2),c.addClass(e.slideClass)},updateView:function(a,b){var c=this.opts();if(c._initialized){var d=c.API.getSlideOpts(),e=c.slides[c.currSlide];!a&&b!==!0&&(c.API.trigger("cycle-update-view-before",[c,d,e]),c.updateView<0)||(c.slideActiveClass&&c.slides.removeClass(c.slideActiveClass).eq(c.currSlide).addClass(c.slideActiveClass),a&&c.hideNonActive&&c.slides.filter(":not(."+c.slideActiveClass+")").css("visibility","hidden"),0===c.updateView&&setTimeout(function(){c.API.trigger("cycle-update-view",[c,d,e,a])},d.speed/(c.sync?2:1)),0!==c.updateView&&c.API.trigger("cycle-update-view",[c,d,e,a]),a&&c.API.trigger("cycle-update-view-after",[c,d,e]))}},getComponent:function(b){var c=this.opts(),d=c[b];return"string"==typeof d?/^\s*[\>|\+|~]/.test(d)?c.container.find(d):a(d):d.jquery?d:a(d)},stackSlides:function(b,c,d){var e=this.opts();b||(b=e.slides[e.currSlide],c=e.slides[e.nextSlide],d=!e.reverse),a(b).css("zIndex",e.maxZ);var f,g=e.maxZ-2,h=e.slideCount;if(d){for(f=e.currSlide+1;h>f;f++)a(e.slides[f]).css("zIndex",g--);for(f=0;f<e.currSlide;f++)a(e.slides[f]).css("zIndex",g--)}else{for(f=e.currSlide-1;f>=0;f--)a(e.slides[f]).css("zIndex",g--);for(f=h-1;f>e.currSlide;f--)a(e.slides[f]).css("zIndex",g--)}a(c).css("zIndex",e.maxZ-1)},getSlideIndex:function(a){return this.opts().slides.index(a)}},a.fn.cycle.log=function(){window.console&&console.log&&console.log("[cycle2] "+Array.prototype.join.call(arguments," "))},a.fn.cycle.version=function(){return"Cycle2: "+c},a.fn.cycle.transitions={custom:{},none:{before:function(a,b,c,d){a.API.stackSlides(c,b,d),a.cssBefore={opacity:1,visibility:"visible",display:"block"}}},fade:{before:function(b,c,d,e){var f=b.API.getSlideOpts(b.nextSlide).slideCss||{};b.API.stackSlides(c,d,e),b.cssBefore=a.extend(f,{opacity:0,visibility:"visible",display:"block"}),b.animIn={opacity:1},b.animOut={opacity:0}}},fadeout:{before:function(b,c,d,e){var f=b.API.getSlideOpts(b.nextSlide).slideCss||{};b.API.stackSlides(c,d,e),b.cssBefore=a.extend(f,{opacity:1,visibility:"visible",display:"block"}),b.animOut={opacity:0}}},scrollHorz:{before:function(a,b,c,d){a.API.stackSlides(b,c,d);var e=a.container.css("overflow","hidden").width();a.cssBefore={left:d?e:-e,top:0,opacity:1,visibility:"visible",display:"block"},a.cssAfter={zIndex:a._maxZ-2,left:0},a.animIn={left:0},a.animOut={left:d?-e:e}}}},a.fn.cycle.defaults={allowWrap:!0,autoSelector:".cycle-slideshow[data-cycle-auto-init!=false]",delay:0,easing:null,fx:"fade",hideNonActive:!0,loop:0,manualFx:void 0,manualSpeed:void 0,manualTrump:!0,maxZ:100,pauseOnHover:!1,reverse:!1,slideActiveClass:"cycle-slide-active",slideClass:"cycle-slide",slideCss:{position:"absolute",top:0,left:0},slides:"> img",speed:500,startingSlide:0,sync:!0,timeout:4e3,updateView:0},a(document).ready(function(){a(a.fn.cycle.defaults.autoSelector).cycle()})}(jQuery),/*! Cycle2 autoheight plugin; Copyright (c) M.Alsup, 2012; version: 20130913 */ 13013function(a){"use strict";function b(b,d){var e,f,g,h=d.autoHeight;if("container"==h)f=a(d.slides[d.currSlide]).outerHeight(),d.container.height(f);else if(d._autoHeightRatio)d.container.height(d.container.width()/d._autoHeightRatio);else if("calc"===h||"number"==a.type(h)&&h>=0){if(g="calc"===h?c(b,d):h>=d.slides.length?0:h,g==d._sentinelIndex)return;d._sentinelIndex=g,d._sentinel&&d._sentinel.remove(),e=a(d.slides[g].cloneNode(!0)),e.removeAttr("id name rel").find("[id],[name],[rel]").removeAttr("id name rel"),e.css({position:"static",visibility:"hidden",display:"block"}).prependTo(d.container).addClass("cycle-sentinel cycle-slide").removeClass("cycle-slide-active"),e.find("*").css("visibility","hidden"),d._sentinel=e}}function c(b,c){var d=0,e=-1;return c.slides.each(function(b){var c=a(this).height();c>e&&(e=c,d=b)}),d}function d(b,c,d,e){var f=a(e).outerHeight();c.container.animate({height:f},c.autoHeightSpeed,c.autoHeightEasing)}function e(c,f){f._autoHeightOnResize&&(a(window).off("resize orientationchange",f._autoHeightOnResize),f._autoHeightOnResize=null),f.container.off("cycle-slide-added cycle-slide-removed",b),f.container.off("cycle-destroyed",e),f.container.off("cycle-before",d),f._sentinel&&(f._sentinel.remove(),f._sentinel=null)}a.extend(a.fn.cycle.defaults,{autoHeight:0,autoHeightSpeed:250,autoHeightEasing:null}),a(document).on("cycle-initialized",function(c,f){function g(){b(c,f)}var h,i=f.autoHeight,j=a.type(i),k=null;("string"===j||"number"===j)&&(f.container.on("cycle-slide-added cycle-slide-removed",b),f.container.on("cycle-destroyed",e),"container"==i?f.container.on("cycle-before",d):"string"===j&&/\d+\:\d+/.test(i)&&(h=i.match(/(\d+)\:(\d+)/),h=h[1]/h[2],f._autoHeightRatio=h),"number"!==j&&(f._autoHeightOnResize=function(){clearTimeout(k),k=setTimeout(g,50)},a(window).on("resize orientationchange",f._autoHeightOnResize)),setTimeout(g,30))})}(jQuery),/*! caption plugin for Cycle2; version: 20130306 */ 13014function(a){"use strict";a.extend(a.fn.cycle.defaults,{caption:"> .cycle-caption",captionTemplate:"{{slideNum}} / {{slideCount}}",overlay:"> .cycle-overlay",overlayTemplate:"<div>{{title}}</div><div>{{desc}}</div>",captionModule:"caption"}),a(document).on("cycle-update-view",function(b,c,d,e){if("caption"===c.captionModule){a.each(["caption","overlay"],function(){var a=this,b=d[a+"Template"],f=c.API.getComponent(a);f.length&&b?(f.html(c.API.tmpl(b,d,c,e)),f.show()):f.hide()})}}),a(document).on("cycle-destroyed",function(b,c){var d;a.each(["caption","overlay"],function(){var a=this,b=c[a+"Template"];c[a]&&b&&(d=c.API.getComponent("caption"),d.empty())})})}(jQuery),/*! command plugin for Cycle2; version: 20140415 */ 13015function(a){"use strict";var b=a.fn.cycle;a.fn.cycle=function(c){var d,e,f,g=a.makeArray(arguments);return"number"==a.type(c)?this.cycle("goto",c):"string"==a.type(c)?this.each(function(){var h;return d=c,f=a(this).data("cycle.opts"),void 0===f?void b.log('slideshow must be initialized before sending commands; "'+d+'" ignored'):(d="goto"==d?"jump":d,e=f.API[d],a.isFunction(e)?(h=a.makeArray(g),h.shift(),e.apply(f.API,h)):void b.log("unknown command: ",d))}):b.apply(this,arguments)},a.extend(a.fn.cycle,b),a.extend(b.API,{next:function(){var a=this.opts();if(!a.busy||a.manualTrump){var b=a.reverse?-1:1;a.allowWrap===!1&&a.currSlide+b>=a.slideCount||(a.API.advanceSlide(b),a.API.trigger("cycle-next",[a]).log("cycle-next"))}},prev:function(){var a=this.opts();if(!a.busy||a.manualTrump){var b=a.reverse?1:-1;a.allowWrap===!1&&a.currSlide+b<0||(a.API.advanceSlide(b),a.API.trigger("cycle-prev",[a]).log("cycle-prev"))}},destroy:function(){this.stop();var b=this.opts(),c=a.isFunction(a._data)?a._data:a.noop;clearTimeout(b.timeoutId),b.timeoutId=0,b.API.stop(),b.API.trigger("cycle-destroyed",[b]).log("cycle-destroyed"),b.container.removeData(),c(b.container[0],"parsedAttrs",!1),b.retainStylesOnDestroy||(b.container.removeAttr("style"),b.slides.removeAttr("style"),b.slides.removeClass(b.slideActiveClass)),b.slides.each(function(){var d=a(this);d.removeData(),d.removeClass(b.slideClass),c(this,"parsedAttrs",!1)})},jump:function(a,b){var c,d=this.opts();if(!d.busy||d.manualTrump){var e=parseInt(a,10);if(isNaN(e)||0>e||e>=d.slides.length)return void d.API.log("goto: invalid slide index: "+e);if(e==d.currSlide)return void d.API.log("goto: skipping, already on slide",e);d.nextSlide=e,clearTimeout(d.timeoutId),d.timeoutId=0,d.API.log("goto: ",e," (zero-index)"),c=d.currSlide<d.nextSlide,d._tempFx=b,d.API.prepareTx(!0,c)}},stop:function(){var b=this.opts(),c=b.container;clearTimeout(b.timeoutId),b.timeoutId=0,b.API.stopTransition(),b.pauseOnHover&&(b.pauseOnHover!==!0&&(c=a(b.pauseOnHover)),c.off("mouseenter mouseleave")),b.API.trigger("cycle-stopped",[b]).log("cycle-stopped")},reinit:function(){var a=this.opts();a.API.destroy(),a.container.cycle()},remove:function(b){for(var c,d,e=this.opts(),f=[],g=1,h=0;h<e.slides.length;h++)c=e.slides[h],h==b?d=c:(f.push(c),a(c).data("cycle.opts").slideNum=g,g++);d&&(e.slides=a(f),e.slideCount--,a(d).remove(),b==e.currSlide?e.API.advanceSlide(1):b<e.currSlide?e.currSlide--:e.currSlide++,e.API.trigger("cycle-slide-removed",[e,b,d]).log("cycle-slide-removed"),e.API.updateView())}}),a(document).on("click.cycle","[data-cycle-cmd]",function(b){b.preventDefault();var c=a(this),d=c.data("cycle-cmd"),e=c.data("cycle-context")||".cycle-slideshow";a(e).cycle(d,c.data("cycle-arg"))})}(jQuery),/*! hash plugin for Cycle2; version: 20130905 */ 13016function(a){"use strict";function b(b,c){var d;return b._hashFence?void(b._hashFence=!1):(d=window.location.hash.substring(1),void b.slides.each(function(e){if(a(this).data("cycle-hash")==d){if(c===!0)b.startingSlide=e;else{var f=b.currSlide<e;b.nextSlide=e,b.API.prepareTx(!0,f)}return!1}}))}a(document).on("cycle-pre-initialize",function(c,d){b(d,!0),d._onHashChange=function(){b(d,!1)},a(window).on("hashchange",d._onHashChange)}),a(document).on("cycle-update-view",function(a,b,c){c.hash&&"#"+c.hash!=window.location.hash&&(b._hashFence=!0,window.location.hash=c.hash)}),a(document).on("cycle-destroyed",function(b,c){c._onHashChange&&a(window).off("hashchange",c._onHashChange)})}(jQuery),/*! loader plugin for Cycle2; version: 20131121 */ 13017function(a){"use strict";a.extend(a.fn.cycle.defaults,{loader:!1}),a(document).on("cycle-bootstrap",function(b,c){function d(b,d){function f(b){var f;"wait"==c.loader?(h.push(b),0===j&&(h.sort(g),e.apply(c.API,[h,d]),c.container.removeClass("cycle-loading"))):(f=a(c.slides[c.currSlide]),e.apply(c.API,[b,d]),f.show(),c.container.removeClass("cycle-loading"))}function g(a,b){return a.data("index")-b.data("index")}var h=[];if("string"==a.type(b))b=a.trim(b);else if("array"===a.type(b))for(var i=0;i<b.length;i++)b[i]=a(b[i])[0];b=a(b);var j=b.length;j&&(b.css("visibility","hidden").appendTo("body").each(function(b){function g(){0===--i&&(--j,f(k))}var i=0,k=a(this),l=k.is("img")?k:k.find("img");return k.data("index",b),l=l.filter(":not(.cycle-loader-ignore)").filter(':not([src=""])'),l.length?(i=l.length,void l.each(function(){this.complete?g():a(this).load(function(){g()}).on("error",function(){0===--i&&(c.API.log("slide skipped; img not loaded:",this.src),0===--j&&"wait"==c.loader&&e.apply(c.API,[h,d]))})})):(--j,void h.push(k))}),j&&c.container.addClass("cycle-loading"))}var e;c.loader&&(e=c.API.add,c.API.add=d)})}(jQuery),/*! pager plugin for Cycle2; version: 20140415 */ 13018function(a){"use strict";function b(b,c,d){var e,f=b.API.getComponent("pager");f.each(function(){var f=a(this);if(c.pagerTemplate){var g=b.API.tmpl(c.pagerTemplate,c,b,d[0]);e=a(g).appendTo(f)}else e=f.children().eq(b.slideCount-1);e.on(b.pagerEvent,function(a){b.pagerEventBubble||a.preventDefault(),b.API.page(f,a.currentTarget)})})}function c(a,b){var c=this.opts();if(!c.busy||c.manualTrump){var d=a.children().index(b),e=d,f=c.currSlide<e;c.currSlide!=e&&(c.nextSlide=e,c._tempFx=c.pagerFx,c.API.prepareTx(!0,f),c.API.trigger("cycle-pager-activated",[c,a,b]))}}a.extend(a.fn.cycle.defaults,{pager:"> .cycle-pager",pagerActiveClass:"cycle-pager-active",pagerEvent:"click.cycle",pagerEventBubble:void 0,pagerTemplate:"<span>•</span>"}),a(document).on("cycle-bootstrap",function(a,c,d){d.buildPagerLink=b}),a(document).on("cycle-slide-added",function(a,b,d,e){b.pager&&(b.API.buildPagerLink(b,d,e),b.API.page=c)}),a(document).on("cycle-slide-removed",function(b,c,d){if(c.pager){var e=c.API.getComponent("pager");e.each(function(){var b=a(this);a(b.children()[d]).remove()})}}),a(document).on("cycle-update-view",function(b,c){var d;c.pager&&(d=c.API.getComponent("pager"),d.each(function(){a(this).children().removeClass(c.pagerActiveClass).eq(c.currSlide).addClass(c.pagerActiveClass)}))}),a(document).on("cycle-destroyed",function(a,b){var c=b.API.getComponent("pager");c&&(c.children().off(b.pagerEvent),b.pagerTemplate&&c.empty())})}(jQuery),/*! prevnext plugin for Cycle2; version: 20140408 */ 13019function(a){"use strict";a.extend(a.fn.cycle.defaults,{next:"> .cycle-next",nextEvent:"click.cycle",disabledClass:"disabled",prev:"> .cycle-prev",prevEvent:"click.cycle",swipe:!1}),a(document).on("cycle-initialized",function(a,b){if(b.API.getComponent("next").on(b.nextEvent,function(a){a.preventDefault(),b.API.next()}),b.API.getComponent("prev").on(b.prevEvent,function(a){a.preventDefault(),b.API.prev()}
vendor: 4,127 bytes, lines 13019-13024
13019),b.swipe){var c=b.swipeVert?"swipeUp.cycle":"swipeLeft.cycle swipeleft.cycle",d=b.swipeVert?"swipeDown.cycle":"swipeRight.cycle swiperight.cycle";b.container.on(c,function(){b._tempFx=b.swipeFx,b.API.next()}),b.container.on(d,function(){b._tempFx=b.swipeFx,b.API.prev()})}}),a(document).on("cycle-update-view",function(a,b){if(!b.allowWrap){var c=b.disabledClass,d=b.API.getComponent("next"),e=b.API.getComponent("prev"),f=b._prevBoundry||0,g=void 0!==b._nextBoundry?b._nextBoundry:b.slideCount-1;b.currSlide==g?d.addClass(c).prop("disabled",!0):d.removeClass(c).prop("disabled",!1),b.currSlide===f?e.addClass(c).prop("disabled",!0):e.removeClass(c).prop("disabled",!1)}}),a(document).on("cycle-destroyed",function(a,b){b.API.getComponent("prev").off(b.nextEvent),b.API.getComponent("next").off(b.prevEvent),b.container.off("swipeleft.cycle swiperight.cycle swipeLeft.cycle swipeRight.cycle swipeUp.cycle swipeDown.cycle")})}(jQuery),/*! progressive loader plugin for Cycle2; version: 20130315 */ 13020function(a){"use strict";a.extend(a.fn.cycle.defaults,{progressive:!1}),a(document).on("cycle-pre-initialize",function(b,c){if(c.progressive){var d,e,f=c.API,g=f.next,h=f.prev,i=f.prepareTx,j=a.type(c.progressive);if("array"==j)d=c.progressive;else if(a.isFunction(c.progressive))d=c.progressive(c);else if("string"==j){if(e=a(c.progressive),d=a.trim(e.html()),!d)return;if(/^(\[)/.test(d))try{d=a.parseJSON(d)}catch(k){return void f.log("error parsing progressive slides",k)}else d=d.split(new RegExp(e.data("cycle-split")||"\n")),d[d.length-1]||d.pop()}i&&(f.prepareTx=function(a,b){var e,f;return a||0===d.length?void i.apply(c.API,[a,b]):void(b&&c.currSlide==c.slideCount-1?(f=d[0],d=d.slice(1),c.container.one("cycle-slide-added",function(a,b){setTimeout(function(){b.API.advanceSlide(1)},50)}),c.API.add(f)):b||0!==c.currSlide?i.apply(c.API,[a,b]):(e=d.length-1,f=d[e],d=d.slice(0,e),c.container.one("cycle-slide-added",function(a,b){setTimeout(function(){b.currSlide=1,b.API.advanceSlide(-1)},50)}),c.API.add(f,!0)))}),g&&(f.next=function(){var a=this.opts();if(d.length&&a.currSlide==a.slideCount-1){var b=d[0];d=d.slice(1),a.container.one("cycle-slide-added",function(a,b){g.apply(b.API),b.container.removeClass("cycle-loading")}),a.container.addClass("cycle-loading"),a.API.add(b)}else g.apply(a.API)}),h&&(f.prev=function(){var a=this.opts();if(d.length&&0===a.currSlide){var b=d.length-1,c=d[b];d=d.slice(0,b),a.container.one("cycle-slide-added",function(a,b){b.currSlide=1,b.API.advanceSlide(-1),b.container.removeClass("cycle-loading")}),a.container.addClass("cycle-loading"),a.API.add(c,!0)}else h.apply(a.API)})}})}(jQuery),/*! tmpl plugin for Cycle2; version: 20121227 */ 13021function(a){"use strict";a.extend(a.fn.cycle.defaults,{tmplRegex:"{{((.)?.*?)}}"}),a.extend(a.fn.cycle.API,{tmpl:function(b,c){var d=new RegExp(c.tmplRegex||a.fn.cycle.defaults.tmplRegex,"g"),e=a.makeArray(arguments);return e.shift(),b.replace(d,function(b,c){var d,f,g,h,i=c.split(".");for(d=0;d<e.length;d++)if(g=e[d]){if(i.length>1)for(h=g,f=0;f<i.length;f++)g=h,h=h[i[f]]||c;else h=g[c];if(a.isFunction(h))return h.apply(g,e);if(void 0!==h&&null!==h&&h!=c)return h}return c})}})}(jQuery);; 13022/* AUTOGENERATED: jquery.cycle2.carousel.min.js */ 13023/* Plugin for Cycle2; Copyright (c) 2012 M. Alsup; v20141007 */ 13024!function(a){"use strict";a(document).on("cycle-bootstrap",function(a,b,c){"carousel"===b.fx&&(c.getSlideIndex=function(a){var b=this.opts()._carouselWrap.children(),c=b.index(a);return c%b.length},c.next=function(){var a=b.reverse?-1:1;b.allowWrap===!1&&b.currSlide+a>b.slideCount-b.carouselVisible||(b.API.advanceSlide(a),b.API.trigger("cycle-next",[b]).log("cycle-next"))})}),a.fn.cycle.transitions.carousel={preInit:function(b){b.hideNonActive=!1,b.container.on("cycle-destroyed",a.proxy(this.onDestroy,b.API)),b.API.stopTransition=this.stopTransition;for(var c=0;c<b.startingSlide;c++)b.container.append(b.slides[0])},postInit:function(b){var c,d,e,f,g=b.carouselVertical;b.carouselVisible&&b.carouselVisible>b.slideCount&&(b.carouselVisible=b.slideCount-1);var h=b.carouselVisible||b.slides.length,i={display:g?"block":"inl
13024ine-block",position:"static"};if(b.container.css({position:"relative",overflow:"hidden"}),b.slides.css(i),b._currSlide=b.currSlide,f=a('<div class="cycle-carousel-wrap"></div>').prependTo(b.container).css({margin:0,padding:0,top:0,left:0,position:"absolute"}).append(b.slides),b._carouselWrap=f,g||f.css("white-space","nowrap"),b.allowWrap!==!1){for(d=0;d<(void 0===b.carouselVisible?2:1);d++){for(c=0;c<b.slideCount;c++)f.append(b.slides[c].cloneNode(!0));for(c=b.slideCount;c--;)f.prepend(b.slides[c].cloneNode(!0))}f.find(".cycle-slide-active").removeClass("cycle-slide-active"),b.slides.eq(b.startingSlide).addClass("cycle-slide-active")}b.pager&&b.allowWrap===!1&&(e=b.slideCount-h,a(b.pager).children().filter(":gt("+e+")").hide()),b._nextBoundry=b.slideCount-b.carouselVisible,this.prepareDimensions(b)},prepareDimensions:function(b){var c,d,e,f,g=b.carouselVertical,h=b.carouselVisible||b.slides.length;if(b.carouselFluid&&b.carouselVisible?b._carouselResizeThrottle||this.fluidSlides(b):b.carouselVisible&&b.carouselSlideDimension?(c=h*b.carouselSlideDimension,b.container[g?"height":"width"](c)):b.carouselVisible&&(c=h*a(b.slides[0])[g?"outerHeight":"outerWidth"](!0),b.container[g?"height":"width"](c)),d=b.carouselOffset||0,b.allowWrap!==!1)if(b.carouselSlideDimension)d-=(b.slideCount+b.currSlide)*b.carouselSlideDimension;else for(e=b._carouselWrap.children(),f=0;f<b.slideCount+b.currSlide;f++)d-=a(e[f])[g?"outerHeight":"outerWidth"](!0);b._carouselWrap.css(g?"top":"left",d)},fluidSlides:function(b){function c(){clearTimeout(e),e=setTimeout(d,20)}function d(){b._carouselWrap.stop(!1,!0);var a=b.container.width()/b.carouselVisible;a=Math.ceil(a-g),b._carouselWrap.children().width(a),b._sentinel&&b._sentinel.width(a),h(b)}var e,f=b.slides.eq(0),g=f.outerWidth()-f.width(),h=this.prepareDimensions;a(window).on("resize",c),b._carouselResizeThrottle=c,d()},transition:function(b,c,d,e,f){var g,h={},i=b.nextSlide-b.currSlide,j=b.carouselVertical,k=b.speed;if(b.allowWrap===!1){e=i>0;var l=b._currSlide,m=b.slideCount-b.carouselVisible;i>0&&b.nextSlide>m&&l==m?i=0:i>0&&b.nextSlide>m?i=b.nextSlide-l-(b.nextSlide-m):0>i&&b.currSlide>m&&b.nextSlide>m?i=0:0>i&&b.currSlide>m?i+=b.currSlide-m:l=b.currSlide,g=this.getScroll(b,j,l,i),b.API.opts()._currSlide=b.nextSlide>m?m:b.nextSlide}else e&&0===b.nextSlide?(g=this.getDim(b,b.currSlide,j),f=this.genCallback(b,e,j,f)):e||b.nextSlide!=b.slideCount-1?g=this.getScroll(b,j,b.currSlide,i):(g=this.getDim(b,b.currSlide,j),f=this.genCallback(b,e,j,f));h[j?"top":"left"]=e?"-="+g:"+="+g,b.throttleSpeed&&(k=g/a(b.slides[0])[j?"height":"width"]()*b.speed),b._carouselWrap.animate(h,k,b.easing,f)},getDim:function(b,c,d){var e=a(b.slides[c]);return e[d?"outerHeight":"outerWidth"](!0)},getScroll:function(a,b,c,d){var e,f=0;if(d>0)for(e=c;c+d>e;e++)f+=this.getDim(a,e,b);else for(e=c;e>c+d;e--)f+=this.getDim(a,e,b);return f},genCallback:function(b,c,d,e){return function(){var c=a(b.slides[b.nextSlide]).position(),f=0-c[d?"top":"left"]+(b.carouselOffset||0);b._carouselWrap.css(b.carouselVertical?"top":"left",f),e()}},stopTransition:function(){var a=this.opts();a.slides.stop(!1,!0),a._carouselWrap.stop(!1,!0)},onDestroy:function(){var b=this.opts();b._carouselResizeThrottle&&a(window).off("resize",b._carouselResizeThrottle),b.slides.prependTo(b.container),b._carouselWrap.remove()}}}(jQuery);; 13025/* AUTOGENERATED: jquery.colorbox-min.js */ 13026/*! 13027 Colorbox 1.6.4 13028 license: MIT 13029 http://www.jacklmoore.com/colorbox 13030 */ 13031(function(t,e,i){function n(i,n,o){var r=e.createElement(i);return n&&(r.id=Z+n),o&&(r.style.cssText=o),t(r)}function o(){return i.innerHeight?i.innerHeight:t(i).height()}function r(e,i){i!==Object(i)&&(i={}),this.cache={},this.el=e,this.value=function(e){var n;return void 0===this.cache[e]&&(n=t(this.el).attr("data-cbox-"+e),void 0!==n?this.cache[e]=n:void 0!==i[e]?this.cache[e]=i[e]:void 0!==X[e]&&(this.cache[e]=X[e])),this.cache[e]},this.get=function(e){var i=this.value(e);return t.isFunction(i)?i.call(this.el,this):i}}function h(t){var e=W.length,i=(A+t)%e;return 0>i?e+i:i}function a(t,e){return Math.round((/%/.test(t)?("x"===e?E.width():o())/100:1)*parseInt(t,10))}function s(t,e){return t.get("photo")||t.get("photoRegex").test(e)}function l(t,e){return t.get("retinaUrl")&&i.devicePixelRatio>1?e.replace(t.get("photoRegex"),t.get("retinaSuffix")):e}
vendor: 2,233 bytes, line 13031
13031function d(t){"contains"in x[0]&&!x[0].contains(t.target)&&t.target!==v[0]&&(t.stopPropagation(),x.focus())}function c(t){c.str!==t&&(x.add(v).removeClass(c.str).addClass(t),c.str=t)}function g(e){A=0,e&&e!==!1&&"nofollow"!==e?(W=t("."+te).filter(function(){var i=t.data(this,Y),n=new r(this,i);return n.get("rel")===e}),A=W.index(_.el),-1===A&&(W=W.add(_.el),A=W.length-1)):W=t(_.el)}function u(i){t(e).trigger(i),ae.triggerHandler(i)}function f(i){var o;if(!G){if(o=t(i).data(Y),_=new r(i,o),g(_.get("rel")),!U){U=$=!0,c(_.get("className")),x.css({visibility:"hidden",display:"block",opacity:""}),I=n(se,"LoadedContent","width:0; height:0; overflow:hidden; visibility:hidden"),b.css({width:"",height:""}).append(I),j=T.height()+k.height()+b.outerHeight(!0)-b.height(),D=C.width()+H.width()+b.outerWidth(!0)-b.width(),N=I.outerHeight(!0),z=I.outerWidth(!0);var h=a(_.get("initialWidth"),"x"),s=a(_.get("initialHeight"),"y"),l=_.get("maxWidth"),f=_.get("maxHeight");_.w=Math.max((l!==!1?Math.min(h,a(l,"x")):h)-z-D,0),_.h=Math.max((f!==!1?Math.min(s,a(f,"y")):s)-N-j,0),I.css({width:"",height:_.h}),J.position(),u(ee),_.get("onOpen"),O.add(F).hide(),x.focus(),_.get("trapFocus")&&e.addEventListener&&(e.addEventListener("focus",d,!0),ae.one(re,function(){e.removeEventListener("focus",d,!0)})),_.get("returnFocus")&&ae.one(re,function(){t(_.el).focus()})}var p=parseFloat(_.get("opacity"));v.css({opacity:p===p?p:"",cursor:_.get("overlayClose")?"pointer":"",visibility:"visible"}).show(),_.get("closeButton")?B.html(_.get("close")).appendTo(b):B.appendTo("<div/>"),w()}}function p(){x||(V=!1,E=t(i),x=n(se).attr({id:Y,"class":t.support.opacity===!1?Z+"IE":"",role:"dialog",tabindex:"-1"}).hide(),v=n(se,"Overlay").hide(),L=t([n(se,"LoadingOverlay")[0],n(se,"LoadingGraphic")[0]]),y=n(se,"Wrapper"),b=n(se,"Content").append(F=n(se,"Title"),R=n(se,"Current"),P=t('<button type="button"/>').attr({id:Z+"Previous"}).html('<span class="visually-hidden">'+xcart.t('Previous slide')+'</span>'),K=t('<button type="button"/>').attr({id:Z+"Next"}).html('<span class="visually-hidden">'+xcart.t('Next slide')+'</span>'),S=t('<button type="button"/>').attr({id:Z+"Slideshow"}).html('<span class="visually-hidden">'+xcart.t('Slideshow')+'</span>'
vendor: 9,006 bytes, line 13031
13031),L),B=t('<button type="button"/>').attr({id:Z+"Close"}),y.append(n(se).append(n(se,"TopLeft"),T=n(se,"TopCenter"),n(se,"TopRight")),n(se,!1,"clear:left").append(C=n(se,"MiddleLeft"),b,H=n(se,"MiddleRight")),n(se,!1,"clear:left").append(n(se,"BottomLeft"),k=n(se,"BottomCenter"),n(se,"BottomRight"))).find("div div").css({"float":"left"}),M=n(se,!1,"position:absolute; width:9999px; visibility:hidden; display:none; max-width:none;"),O=K.add(P).add(R).add(S)),e.body&&!x.parent().length&&t(e.body).append(v,x.append(y,M))}function m(){function i(t){t.which>1||t.shiftKey||t.altKey||t.metaKey||t.ctrlKey||(t.preventDefault(),f(this))}return x?(V||(V=!0,K.click(function(){J.next()}),P.click(function(){J.prev()}),B.click(function(){J.close()}),v.click(function(){_.get("overlayClose")&&J.close()}),t(e).bind("keydown."+Z,function(t){var e=t.keyCode;U&&_.get("escKey")&&27===e&&(t.preventDefault(),J.close()),U&&_.get("arrowKey")&&W[1]&&!t.altKey&&(37===e?(t.preventDefault(),P.click()):39===e&&(t.preventDefault(),K.click()))}),t.isFunction(t.fn.on)?t(e).on("click."+Z,"."+te,i):t("."+te).live("click."+Z,i)),!0):!1}function w(){var e,o,r,h=J.prep,d=++le;if($=!0,q=!1,u(he),u(ie),_.get("onLoad"),_.h=_.get("height")?a(_.get("height"),"y")-N-j:_.get("innerHeight")&&a(_.get("innerHeight"),"y"),_.w=_.get("width")?a(_.get("width"),"x")-z-D:_.get("innerWidth")&&a(_.get("innerWidth"),"x"),_.mw=_.w,_.mh=_.h,_.get("maxWidth")&&(_.mw=a(_.get("maxWidth"),"x")-z-D,_.mw=_.w&&_.w<_.mw?_.w:_.mw),_.get("maxHeight")&&(_.mh=a(_.get("maxHeight"),"y")-N-j,_.mh=_.h&&_.h<_.mh?_.h:_.mh),e=_.get("href"),Q=setTimeout(function(){L.show()},100),_.get("inline")){var c=t(e).eq(0);r=t("<div>").hide().insertBefore(c),ae.one(he,function(){r.replaceWith(c)}),h(c)}else _.get("iframe")?h(" "):_.get("html")?h(_.get("html")):s(_,e)?(e=l(_,e),q=_.get("createImg"),t(q).addClass(Z+"Photo").bind("error."+Z,function(){h(n(se,"Error").html(_.get("imgError")))}).one("load",function(){d===le&&setTimeout(function(){var e;_.get("retinaImage")&&i.devicePixelRatio>1&&(q.height=q.height/i.devicePixelRatio,q.width=q.width/i.devicePixelRatio),_.get("scalePhotos")&&(o=function(){q.height-=q.height*e,q.width-=q.width*e},_.mw&&q.width>_.mw&&(e=(q.width-_.mw)/q.width,o()),_.mh&&q.height>_.mh&&(e=(q.height-_.mh)/q.height,o())),_.h&&(q.style.marginTop=Math.max(_.mh-q.height,0)/2+"px"),W[1]&&(_.get("loop")||W[A+1])&&(q.style.cursor="pointer",t(q).bind("click."+Z,function(){J.next()})),q.style.width=q.width+"px",q.style.height=q.height+"px",h(q)},1)}),q.src=e):e&&M.load(e,_.get("data"),function(e,i){d===le&&h("error"===i?n(se,"Error").html(_.get("xhrError")):t(this).contents())})}var v,x,y,b,T,C,H,k,W,E,I,M,L,F,R,S,K,P,B,O,_,j,D,N,z,A,q,U,$,G,Q,J,V,X={html:!1,photo:!1,iframe:!1,inline:!1,transition:"elastic",speed:300,fadeOut:300,width:!1,initialWidth:"600",innerWidth:!1,maxWidth:!1,height:!1,initialHeight:"450",innerHeight:!1,maxHeight:!1,scalePhotos:!0,scrolling:!0,opacity:.9,preloading:!0,className:!1,overlayClose:!0,escKey:!0,arrowKey:!0,top:!1,bottom:!1,left:!1,right:!1,fixed:!1,data:void 0,closeButton:!0,fastIframe:!0,open:!1,reposition:!0,loop:!0,slideshow:!1,slideshowAuto:!0,slideshowSpeed:2500,slideshowStart:"start slideshow",slideshowStop:"stop slideshow",photoRegex:/\.(gif|png|jp(e|g|eg)|bmp|ico|webp|jxr|svg)((#|\?).*)?$/i,retinaImage:!1,retinaUrl:!1,retinaSuffix:"@2x.$1",current:"image {current} of {total}",previous:"previous",next:"next",close:"close",xhrError:"This content failed to load.",imgError:"This image failed to load.",returnFocus:!0,trapFocus:!0,onOpen:!1,onLoad:!1,onComplete:!1,onCleanup:!1,onClosed:!1,rel:function(){return this.rel},href:function(){return t(this).attr("href")},title:function(){return this.title},createImg:function(){var e=new Image,i=t(this).data("cbox-img-attrs");return"object"==typeof i&&t.each(i,function(t,i){e[t]=i}),e},createIframe:function(){var i=e.createElement("iframe"),n=t(this).data("cbox-iframe-attrs");return"object"==typeof n&&t.each(n,function(t,e){i[t]=e}),"frameBorder"in i&&(i.frameBorder=0),"allowTransparency"in i&&(i.allowTransparency="true"),i.name=(new Date).getTime(),i.allowFullscreen=!0,i}},Y="colorbox",Z="cbox",te=Z+"Element",ee=Z+"_open",ie=Z+"_load",ne=Z+"_complete",oe=Z+"_cleanup",re=Z+"_closed",he=Z+"_purge",ae=t("<a/>"),se="div",le=0,de={},ce=function(){function t(){clearTimeout(h)}function e(){(_.get("loop")||W[A+1])&&(t(),h=setTimeout(J.next,_.get("slideshowSpeed")))}function i(){S.html(_.get("slideshowStop")).unbind(s).one(s,n),ae.bind(ne,e).bind(ie,t),x.removeClass(a+"off").addClass(a+"on")}function n(){t(),ae.unbind(ne,e).unbind(ie,t),S.html(_.get("slideshowStart")).unbind(s).one(s,function(){J.next(),i()}),x.removeClass(a+"on").addClass(a+"off")}function o(){r=!1,S.hide(),t(),ae.unbind(ne,e).unbind(ie,t),x.removeClass(a+"off "+a+"on")}var r,h,a=Z+"Slideshow_",s="click."+Z;return function(){r?_.get("slideshow")||(ae.unbind(oe,o),o()):_.get("slideshow")&&W[1]&&(r=!0,ae.one(oe,o),_.get("slideshowAuto")?i():n(),S.show())}}();t[Y]||(t(p),J=t.fn[Y]=t[Y]=function(e,i){var n,o=this;return e=e||{},t.isFunction(o)&&(o=t("<a/>"),e.open=!0),o[0]?(p(),m()&&(i&&(e.onComplete=i),o.each(function(){var i=t.data(this,Y)||{};t.data(this,Y,t.extend(i,e))}).addClass(te),n=new r(o[0],e),n.get("open")&&f(o[0])),o):o},J.position=function(e,i){function n(){T[0].style.width=k[0].style.width=b[0].style.width=parseInt(x[0].style.width,10)-D+"px",b[0].style.height=C[0].style.height=H[0].style.height=parseInt(x[0].style.height,10)-j+"px"}var r,h,s,l=0,d=0,c=x.offset();if(E.unbind("resize."+Z),x.css({top:-9e4,left:-9e4}),h=E.scrollTop(),s=E.scrollLeft(),_.get("fixed")?(c.top-=h,c.left-=s,x.css({position:"fixed"})):(l=h,d=s,x.css({position:"absolute"})),d+=_.get("right")!==!1?Math.max(E.width()-_.w-z-D-a(_.get("right"),"x"),0):_.get("left")!==!1?a(_.get("left"),"x"):Math.round(Math.max(E.width()-_.w-z-D,0)/2),l+=_.get("bottom")!==!1?Math.max(o()-_.h-N-j-a(_.get("bottom"),"y"),0):_.get("top")!==!1?a(_.get("top"),"y"):Math.round(Math.max(o()-_.h-N-j,0)/2),x.css({top:c.top,left:c.left,visibility:"visible"}),y[0].style.width=y[0].style.height="9999px",r={width:_.w+z+D,height:_.h+N+j,top:l,left:d},e){var g=0;t.each(r,function(t){return r[t]!==de[t]?(g=e,void 0):void 0}),e=g}de=r,e||x.css(r),x.dequeue().animate(r,{duration:e||0,complete:function(){n(),$=!1,y[0].style.width=_.w+z+D+"px",y[0].style.height=_.h+N+j+"px",_.get("reposition")&&setTimeout(function(){E.bind("resize."+Z,J.position)},1),t.isFunction(i)&&i()},step:n})},J.resize=function(t){var e;U&&(t=t||{},t.width&&(_.w=a(t.width,"x")-z-D),t.innerWidth&&(_.w=a(t.innerWidth,"x")),I.css({width:_.w}),t.height&&(_.h=a(t.height,"y")-N-j),t.innerHeight&&(_.h=a(t.innerHeight,"y")),t.innerHeight||t.height||(e=I.scrollTop(),I.css({height:"auto"}),_.h=I.height()),I.css({height:_.h}),e&&I.scrollTop(e),J.position("none"===_.get("transition")?0:_.get("speed")))},J.prep=function(i){function o(){return _.w=_.w||I.width(),_.w=_.mw&&_.mw<_.w?_.mw:_.w,_.w}function a(){return _.h=_.h||I.height(),_.h=_.mh&&_.mh<_.h?_.mh:_.h,_.h}if(U){var d,g="none"===_.get("transition")?0:_.get("speed");I.remove(),I=n(se,"LoadedContent").append(i),I.hide().appendTo(M.show()).css({width:o(),overflow:_.get("scrolling")?"auto":"hidden"}).css({height:a()}).prependTo(b),M.hide(),t(q).css({"float":"none"}),c(_.get("className")),d=function(){function i(){t.support.opacity===!1&&x[0].style.removeAttribute("filter")}var n,o,a=W.length;U&&(o=function(){clearTimeout(Q),L.hide(),u(ne),_.get("onComplete")},F.html(_.get("title")).show(),I.show(),a>1?("string"==typeof _.get("current")&&R.html(_.get("current").replace("{current}",A+1).replace("{total}",a)).show(),K[_.get("loop")||a-1>A?"show":"hide"]().html(_.get("next")),P[_.get("loop")||A?"show":"hide"]().html(_.get("previous")),ce(),_.get("preloading")&&t.each([h(-1),h(1)],function(){var i,n=W[this],o=new r(n,t.data(n,Y)),h=o.get("href");h&&s(o,h)&&(h=l(o,h),i=e.createElement("img"),i.src=h)})):O.hide(),_.get("iframe")?(n=_.get("createIframe"),_.get("scrolling")||(n.scrolling="no"),t(n).attr({src:_.get("href"),"class":Z+"Iframe"}).one("load",o).appendTo(I),ae.one(he,function(){n.src="//about:blank"}),_.get("fastIframe")&&t(n).trigger("load")):o(),"fade"===_.get("transition")?x.fadeTo(g,1,i):i())},"fade"===_.get("transition")?x.fadeTo(g,0,function(){J.position(0,d)}):J.position(g,d)}},J.next=function(){!$&&W[1]&&(_.get("loop")||W[A+1])&&(A=h(1),f(W[A]))},J.prev=function(){!$&&W[1]&&(_.get("loop")||A)&&(A=h(-1),f(W[A]))},J.close=function(){U&&!G&&(G=!0,U=!1,u(oe),_.get("onCleanup"),E.unbind("."+Z),v.fadeTo(_.get("fadeOut")||0,0),x.stop().fadeTo(_.get("fadeOut")||0,0,function(){x.hide(),v.hide(),u(he),I.remove(),setTimeout(function(){G=!1,u(re),_.get("onClosed")},1)}))},J.remove=function(){x&&(x.stop(),t[Y].close(),x.stop(!1,!0).remove(),v.remove(),G=!1,x=null,t("."+te).removeData(Y).removeClass(te),t(e).unbind("click."+Z).unbind("keydown."+Z))},J.element=function(){return t(_.el)},J.settings=X)})(jQuery,document,window);
13031; 13032/* AUTOGENERATED: cycle-gallery.js */ 13033/* vim: set ts=2 sw=2 sts=2 et: */ 13034 13035/** 13036 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 13037 * See https://www.x-cart.com/license-agreement.html for license details. 13038 */ 13039 13040jQuery(document).ready(function() { 13041 decorate( 13042 'ProductDetailsView', 13043 'processVariantImageAsGallery', 13044 function (data) { 13045 arguments.callee.previousMethod.apply(this, arguments); 13046 xcart.trigger('init-cycle-gallery'); 13047 } 13048 ); 13049 13050 decorate( 13051 'ProductQuickLookVariantView', 13052 'processVariantImageAsGallery', 13053 function (data) { 13054 arguments.callee.previousMethod.apply(this, arguments); 13055 xcart.trigger('init-cycle-gallery'); 13056 } 13057 ); 13058});; 13059/* AUTOGENERATED: controller.js */ 13060/* vim: set ts=2 sw=2 sts=2 et: */ 13061 13062/** 13063 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 13064 * See https://www.x-cart.com/license-agreement.html for license details. 13065 */ 13066 13067/** 13068 * Controller 13069 */ 13070 13071function ProductQuantityBoxView(base) 13072{ 13073 this.base = jQuery(base); 13074 13075 if (this.base && this.base.length && this.base.find('input.quantity').length > 0) { 13076 13077 this.block = this.base.find('input.quantity'); 13078 13079 var form = this.block.get(0).form; 13080 form.commonController.switchControlReadiness(true); 13081 13082 form.commonController 13083 .bind('local.ready', _.bind(this.handleFormReady, this)) 13084 .bind('local.unready', _.bind(this.handleFormUnready, this)); 13085 13086 this.block.on( 13087 'input', 13088 _.bind(this.handleQuantityChange, this) 13089 ); 13090 13091 this.isCartPage = jQuery('div#cart').length > 0; 13092 13093 if (!this.isCartPage) { 13094 13095 this.actionButton = jQuery(this.base) 13096 .parents('div.product-buttons') 13097 .find('button.add2cart, button.buy-more'); 13098 13099 } else { 13100 13101 this.actionButton = jQuery('ul.totals li.button button'); 13102 13103 } 13104 } 13105 13106 Base.apply(this, arguments); 13107 13108 this.initialize(); 13109} 13110 13111extend(ProductQuantityBoxView, Base); 13112 13113// Controller associated main widget 13114ProductQuantityBoxView.prototype.base = null; 13115 13116// Controller associated main widget 13117ProductQuantityBoxView.prototype.block = null; 13118 13119// Controller associated main widget 13120ProductQuantityBoxView.prototype.isCartPage = false; 13121 13122// Initialize controller 13123ProductQuantityBoxView.prototype.initialize = function() 13124{ 13125}; 13126 13127ProductQuantityBoxView.prototype.handleQuantityChange = function(event) 13128{ 13129 jQuery(event.currentTarget).change(); 13130} 13131 13132ProductQuantityBoxView.prototype.handleFormReady = function(event) 13133{ 13134 this.actionButton 13135 .removeAttr('disabled') 13136 .removeClass('disabled add2cart-disabled'); 13137} 13138 13139ProductQuantityBoxView.prototype.handleFormUnready = function(event) 13140{ 13141 this.actionButton 13142 .prop('disabled', 'disabled') 13143 .addClass('disabled add2cart-disabled'); 13144} 13145 13146// Get event namespace (prefix) 13147ProductQuantityBoxView.prototype.getEventNamespace = function() 13148{ 13149 return 'product.details.quantityBox'; 13150} 13151 13152xcart.registerTriggersBind( 13153 'update-product-page', 13154 function() 13155 { 13156 var container = jQuery('span.quantity-box-container'); 13157 13158 new ProductQuantityBoxView(container); 13159 if (container.parents('form').get(0) && container.parents('form').get(0).commonController) { 13160 container.parents('form').get(0).commonController.bindElements(); 13161 } 13162 } 13163); 13164 13165xcart.registerShadowWidgets( 13166 'update-product-page', 13167 function() 13168 { 13169 return '.widget-fingerprint-product-quantity, .widget-fingerprint-product-add-button'; 13170 } 13171);; 13172/* AUTOGENERATED: script.js */ 13173/* vim: set ts=2 sw=2 sts=2 et: */ 13174 13175/** 13176 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 13177 * See https://www.x-cart.com/license-agreement.html for license details. 13178 */ 13179 13180// Get product attribute element by name 13181function product_attribute(name_of_attribute) 13182{ 13183 var e = jQuery('form[name="add_to_cart"] :input').filter( 13184 function() { 13185 return this.name && this.name.search(name_of_attribute) !== -1; 13186 } 13187 ); 13188 13189 return e.get(0); 13190} 13191 13192let textAttrCache = []; 13193 13194function getAttributeValuesParams(product) 13195{ 13196 let activeAttributeValues = ''; 13197 let base = '.product-info-' + product.product_id; 13198 13199 jQuery("ul.attribute-values input[type=checkbox]", jQuery(base).last()).each(function(index, elem) { 13200 activeAttributeValues += jQuery(elem).data('attribute-id') + '_'; 13201 activeAttributeValues += jQuery(elem).is(":checked") ? jQuery(elem).val() : jQuery(elem).data('unchecked'); 13202 activeAttributeValues += ','; 13203 }); 13204 13205 jQuery("ul.attribute-values select", jQuery(base).last()).each(function(index, elem) { 13206 activeAttributeValues += jQuery(elem).data('attribute-id') + '_' + jQuery(elem).val() + ','; 13207 }); 13208 13209 jQuery("ul.attribute-values textarea", jQuery(base).last()).each(function(index, elem) { 13210 textAttrCache[jQuery(elem).data('attribute-id')] = jQuery(elem).val(); 13211 }); 13212 13213 jQuery("ul.attribute-values input.blocks-input", jQuery(base).last()).each(function(index, elem) { 13214 activeAttributeValues += jQuery(elem).data('attribute-id') + '_' + jQuery(elem).val() + ','; 13215 }); 13216 13217 return { 13218 attribute_values: activeAttributeValues 13219 }; 13220} 13221 13222/** 13223 * Product attributes triggers are inputs and selectors 13224 * of the attribute-values block 13225 * 13226 * @returns {String} 13227 */ 13228function getAttributeValuesTriggers() 13229{ 13230 return 'ul.attribute-values input, ul.attribute-values select'; 13231} 13232 13233function getAttributeValuesShadowWidgets() 13234{ 13235 return '.widget-fingerprint-product-price'; 13236} 13237 13238function bindAttributeValuesTriggers() 13239{ 13240 const handler = function (productId) { 13241 xcart.trigger('update-product-page', productId); 13242 }; 13243 13244 const obj = jQuery("ul.attribute-values").closest('.product-details-info').find('form.product-details'); 13245 if (obj.length > 0) { 13246 const productId = jQuery('input[name="product_id"]', obj).val(); 13247 13248 jQuery("ul.attribute-values input[type='checkbox']").unbind('change').bind('change', function () { handler(productId); }); 13249 jQuery("ul.attribute-values input.blocks-input").unbind('change').bind('change', function () { handler(productId); }); 13250 jQuery("ul.attribute-values select").unbind('change').bind('change', function () { handler(productId); }); 13251 13252 jQuery("ul.attribute-values textarea").each(function(index, elem) { 13253 if (textAttrCache[jQuery(elem).data('attribute-id')]) { 13254 jQuery(elem).val(textAttrCache[jQuery(elem).data('attribute-id')]); 13255 } 13256 }); 13257 } 13258} 13259 13260function BlocksSelector() 13261{ 13262 jQuery('.product-details-info').on( 13263 'click', 13264 '.block-value:not(.selected)', 13265 function () { 13266 const $blockValue = jQuery(this); 13267 const blockValueId = $blockValue.data('value'); 13268 const blockValueName = $blockValue.find('.block-value-name').html(); 13269 const blockValueModifiers = $blockValue.data('modifiers'); 13270 const blocksName = $blockValue.data('name'); 13271 13272 const $blocksSelector = $blockValue.closest('.blocks-selector'); 13273 const $blocksTitle = $blocksSelector.find('.blocks-title'); 13274 const $blocksInput = $blocksSelector.find('.blocks-input'); 13275 13276 $blocksTitle.removeClass('not-selected'); 13277 $blocksInput.val(blockValueId).change(); 13278 $blocksTitle.find('.attr-value-name').html(blockValueName); 13279 $blocksTitle.find('.attr-value-modifiers').html(blockValueModifiers); 13280 13281 unselectAllBlocks(blocksName); 13282 $blockValue.addClass('selected'); 13283 } 13284 ); 13285 13286 let timeout; 13287 let $tooltip; 13288 13289 setTimeout(() => { 13290 jQuery('.product-details-info, .change-attribute-values').on({ 13291 mouseenter: function () { 13292 $tooltip = jQuery(this).find('.unavailable-tooltip'); 13293 timeout = setTimeout(function () { 13294 $tooltip.show(100); 13295 }, 250); 13296 }, 13297 mouseleave: function () { 13298 clearTimeout(timeout); 13299 if ($tooltip !== undefined) { 13300 $tooltip.hide(100); 13301 } 13302 } 13303 }, '.block-value'); 13304 }, 1); 13305} 13306 13307function unselectAllBlocks(blocksName) { 13308 jQuery(`.block-value[data-name="${blocksName}"]`).removeClass('selected'); 13309} 13310 13311xcart.autoload(BlocksSelector);
13312xcart.bind('block.product.details.postprocess', BlocksSelector); 13313xcart.registerWidgetsParamsGetter('update-product-page', getAttributeValuesParams); 13314xcart.registerWidgetsTriggers('update-product-page', getAttributeValuesTriggers); 13315xcart.registerTriggersBind('update-product-page', bindAttributeValuesTriggers); 13316xcart.registerShadowWidgets('update-product-page', getAttributeValuesShadowWidgets); 13317xcart.registerShadowWidgets('update-product-page', function() { 13318 return '.widget-fingerprint-common-attributes'; 13319});; 13320/* AUTOGENERATED: products_list_touch_devices.js */ 13321/* vim: set ts=2 sw=2 sts=2 et: */ 13322 13323/** 13324 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 13325 * See https://www.x-cart.com/license-agreement.html for license details. 13326 */ 13327 13328function isTouchDevice () { 13329 var 13330 ua = navigator.userAgent, 13331 browser = /Edge\/\d+/.test(ua) ? 'ed' : /MSIE 9/.test(ua) ? 'ie9' : /MSIE 10/.test(ua) ? 'ie10' : /MSIE 11/.test(ua) ? 'ie11' : /MSIE\s\d/.test(ua) ? 'ie?' : /rv\:11/.test(ua) ? 'ie11' : /Firefox\W\d/.test(ua) ? 'ff' : /Chrome\W\d/.test(ua) ? 'gc' : /Chromium\W\d/.test(ua) ? 'oc' : /\bSafari\W\d/.test(ua) ? 'sa' : /\bOpera\W\d/.test(ua) ? 'op' : /\bOPR\W\d/i.test(ua) ? 'op' : typeof MSPointerEvent !== 'undefined' ? 'ie?' : '', 13332 os = /Windows NT 10/.test(ua) ? 'win10' : /Windows NT 6\.0/.test(ua) ? 'winvista' : /Windows NT 6\.1/.test(ua) ? 'win7' : /Windows NT 6\.\d/.test(ua) ? 'win8' : /Windows NT 5\.1/.test(ua) ? 'winxp' : /Windows NT [1-5]\./.test(ua) ? 'winnt' : /Mac/.test(ua) ? 'mac' : /Linux/.test(ua) ? 'linux' : /X11/.test(ua) ? 'nix' : '', 13333 mobile = /IEMobile|Windows Phone|Lumia/i.test(ua) ? 'w' : /iPhone|iP[oa]d/.test(ua) ? 'i' : /Android/.test(ua) ? 'a' : /BlackBerry|PlayBook|BB10/.test(ua) ? 'b' : /Mobile Safari/.test(ua) ? 's' : /webOS|Mobile|Tablet|Opera Mini|\bCrMo\/|Opera Mobi/i.test(ua) ? 1 : 0, 13334 tablet = /Tablet|iPad/i.test(ua), 13335 msGesture = window.navigator && window.navigator.msPointerEnabled && window.MSGesture, 13336 touch = (('ontouchstart' in window) || msGesture || window.DocumentTouch && document instanceof DocumentTouch) 13337 13338 return touch && (mobile || tablet) 13339} 13340 13341function switchProductToMobileView () { 13342 $('.items-list .products-grid .product-cell .product').addClass('prevent-hover') 13343} 13344 13345function switchProductToDesktopView () { 13346 $('.items-list .products-grid .product-cell .product').removeClass('prevent-hover') 13347} 13348 13349function switchProductView () { 13350 const smallScreenCond = $(window).width() < 768 13351 const largeScreenCond = $(window).width() > 767 13352 13353 if (smallScreenCond || isTouchDevice()) { 13354 switchProductToMobileView() 13355 } else if (largeScreenCond && !isTouchDevice()) { 13356 switchProductToDesktopView() 13357 } 13358} 13359 13360decorate( 13361 'ProductsListView', 13362 'postprocess', 13363 function (isSuccess, initial) { 13364 arguments.callee.previousMethod.apply(this, arguments) 13365 13366 if (isSuccess) { 13367 switchProductView() 13368 } 13369 } 13370) 13371 13372switchProductView() 13373 13374$(window).resize(function () { 13375 switchProductView() 13376});; 13377/* AUTOGENERATED: products_list.js */ 13378/* vim: set ts=2 sw=2 sts=2 et: */ 13379 13380/** 13381 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 13382 * See https://www.x-cart.com/license-agreement.html for license details. 13383 */ 13384 13385decorate( 13386 'ProductsListView', 13387 'postprocess', 13388 function (isSuccess, initial) { 13389 arguments.callee.previousMethod.apply(this, arguments); 13390 13391 if (isSuccess) { 13392 jQuery('.quicklook button.quicklook-link', this.base).click( 13393 function () { 13394 popup.openAsWait(); 13395 13396 return !popup.load( 13397 URLHandler.buildURL({ 13398 target: 'quick_look', 13399 action: '', 13400 product_id: xcart.getValueFromClass(this, 'quicklook-link'), 13401 only_center: 1 13402 }), 13403 function () { 13404 jQuery('.formError').hide(); 13405 }, 13406 50000 13407 ); 13408 } 13409 ); 13410 13411 xcart.bind('block.product.details.postprocess', function () { 13412 xcart.trigger('init-cycle-gallery'); 13413 }); 13414 } 13415 } 13416);; 13417/* AUTOGENERATED: products_list_part.js */ 13418/* vim: set ts=2 sw=2 sts=2 et: */ 13419 13420/** 13421 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 13422 * See https://www.x-cart.com/license-agreement.html for license details. 13423 */ 13424 13425decorate( 13426 'ProductsListView', 13427 'postprocess', 13428 function (isSuccess, initial) { 13429 arguments.callee.previousMethod.apply(this, arguments) 13430 13431 if (isSuccess) { 13432 $('.products-grid .product-cell > .product:not(.prevent-hover)').mouseenter(function () { 13433 let product = jQuery(this) 13434 13435 let productNameContainer = product.find('h4.product-name') 13436 let productNameContainerHeight = parseInt(productNameContainer.css('line-height'), 10) * 2 // 2 because of min 2 lines in product name 13437 13438 let productName = productNameContainer.children('a') 13439 let productNameHeight = parseInt(productName.css('height'), 10) 13440 13441 let productMargin = 0; 13442 let buttonsContainer = product.find('.buttons-container') 13443 13444 product.closest('.block.block-block').addClass('hover-within'); 13445 13446 if (buttonsContainer.length) { 13447 let buttonsContainerSize = parseInt(buttonsContainer.outerHeight(true), 10) 13448 productMargin = productMargin - buttonsContainerSize 13449 } 13450 13451 if (productNameHeight > productNameContainerHeight) { 13452 let productNameDelta = productNameContainerHeight - productNameHeight; 13453 product.css({'margin-bottom': productMargin + productNameDelta + 'px'}); 13454 } 13455 }).mouseleave(function () { 13456 const self = $(this); 13457 self.removeAttr('style'); 13458 self.closest('.block.block-block').removeClass('hover-within'); 13459 }) 13460 } 13461 } 13462);; 13463/* AUTOGENERATED: products_list.js */ 13464/* vim: set ts=2 sw=2 sts=2 et: */ 13465 13466/** 13467 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 13468 * See https://www.x-cart.com/license-agreement.html for license details. 13469 */ 13470 13471decorate( 13472 'ProductsListView',
13473 'addToCartRequestParams', 13474 function (elem) { 13475 var params = arguments.callee.previousMethod.apply(this, arguments); 13476 13477 var ecData = jQuery('*[data-ga-ec-action]', elem.closest('.add-to-cart-button')); 13478 if (!_.isUndefined(ecData) && ecData.length !== 0) { 13479 var context = ecData.data('ga-ec-action').context; 13480 13481 if (!_.isUndefined(context.list)) { 13482 params.ga_list = context.list; 13483 } 13484 } 13485 13486 return params; 13487 } 13488); 13489 13490decorate( 13491 'ProductsListView', 13492 'openQuickLookParams', 13493 function (elem) { 13494 var params = arguments.callee.previousMethod.apply(this, arguments); 13495 13496 var ecData = jQuery('*[data-ga-ec-action]', elem); 13497 if (!_.isUndefined(ecData) && ecData.length !== 0) { 13498 var context = ecData.data('ga-ec-action').context; 13499 13500 if (!_.isUndefined(context.list)) { 13501 params.ga_list = context.list; 13502 } 13503 } 13504 13505 return params; 13506 } 13507);; 13508/* AUTOGENERATED: subscribe.js */ 13509/* vim: set ts=2 sw=2 sts=2 et: */ 13510 13511/** 13512 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 13513 * See https://www.x-cart.com/license-agreement.html for license details. 13514 */ 13515 13516function SubscribeBlockView(base) 13517{ 13518 var args = Array.prototype.slice.call(arguments, 0); 13519 this.callSupermethod('constructor', args); 13520 var s = this; 13521 xcart.bind('changeSuccessMessage', function (event, data) { 13522 if (data && typeof data.message !== 'undefined') { 13523 s.changeSuccessMessage(data.message) 13524 } 13525 }); 13526 13527 // Form 13528 var form = this.base 13529 ? this.base.find('.subscription-form-block form').get(0) 13530 : null; 13531 if (form) { 13532 form.commonController.enableBackgroundSubmit( 13533 undefined, 13534 _.bind( 13535 function(event, result){ 13536 if (result.isValid && result.textStatus === 'success') { 13537 this.processSuccess(); 13538 } else { 13539 this.processError(); 13540 } 13541 }, 13542 this 13543 ) 13544 ); 13545 } 13546} 13547 13548extend(SubscribeBlockView, ALoadable); 13549 13550SubscribeBlockView.autoload = function() 13551{ 13552 jQuery('.subscription-block').each( 13553 function() { 13554 new SubscribeBlockView(this); 13555 } 13556 ); 13557}; 13558 13559// Widget target 13560SubscribeBlockView.prototype.widgetTarget = 'newsletter_subscriptions'; 13561 13562// Widget class name 13563SubscribeBlockView.prototype.widgetClass = '\\XC\\NewsletterSubscriptions\\View\\SubscribeBlock'; 13564 13565SubscribeBlockView.prototype.processSuccess = function() 13566{ 13567 this.base.find('.subscription-form-block').hide(); 13568 13569 this.base.find('.subscription-error-block').hide(); 13570 13571 this.base.find('.subscription-success-block').removeClass('hidden'); 13572 this.base.find('.subscription-success-block').show(); 13573} 13574 13575SubscribeBlockView.prototype.processError = function() 13576{ 13577 this.base.find('.subscription-error-block').removeClass('hidden'); 13578 this.base.find('.subscription-error-block').show(); 13579} 13580 13581// Get event namespace (prefix) 13582SubscribeBlockView.prototype.getEventNamespace = function() 13583{ 13584 return 'NewsletterSubscriptions'; 13585} 13586 13587SubscribeBlockView.prototype.changeSuccessMessage = function (message) { 13588 this.base.find('.subscription-success-block').html(message) 13589} 13590 13591xcart.autoload(SubscribeBlockView);; 13592/* AUTOGENERATED: jquery_footer.js */ 13593/* vim: set ts=2 sw=2 sts=2 et: */ 13594 13595/** 13596 * Copyright (c) 2001-present X-Cart Holdings LLC. All rights reserved. 13597 * See https://www.x-cart.com/license-agreement.html for license details. 13598 */ 13599 13600// function footer () { 13601// var fh = jQuery('#footer-area').height(); 13602// if (fh > 150) { 13603// jQuery('#page').css('padding-bottom', fh); 13604// } 13605// } 13606 13607function mobileDropdown () { 13608 if (jQuery('#top-menu.dropdown-menu').hasClass('scrollable') == true) { 13609 jQuery('#top-menu.dropdown-menu').removeClass('scrollable').removeAttr('style'); 13610 } 13611 var h1 = jQuery(window).height(); 13612 var h2 = jQuery('#top-menu.dropdown-menu').height(); 13613 var h3 = jQuery('.mobile_header ul.nav-pills').height(); 13614 if (h1 < h2+h3) { 13615 jQuery('#top-menu.dropdown-menu').addClass('scrollable').height(h1-h3); 13616 } 13617} 13618 13619jQuery(function () { 13620 mobileDropdown(); 13621 jQuery(window).resize(mobileDropdown); 13622 jQuery(function () { 13623 jQuery('.top-main-menu a, .top-main-menu .primary-title').on('touchstart', function (e) { 13624 if (jQuery(this).hasClass('tap') !== true && jQuery(this).parent().parent().hasClass('tap') !== true) { 13625 jQuery('ul.tap, a.tap, .primary-title.tap').removeClass('tap'); 13626 } 13627 if (jQuery(this).next('ul').length !== 0) { 13628 jQuery(this).toggleClass('tap'); 13629 if (jQuery(this).hasClass('tap') == true) { 13630 e.preventDefault(); 13631 } 13632 jQuery(this).next('ul').toggleClass('tap'); 13633 } 13634 jQuery(document).on('touchstart', function (e) { 13635 if (jQuery(e.target).closest('.tap').length == 0) { 13636 jQuery('ul.tap, a.tap, .primary-title.tap').removeClass('tap'); 13637 } 13638 }); 13639 }); 13640 }); 13641});;
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.