PageSourceSearch

https://pricee.com/static/js/desktop/min/plist_min_atf.js?v=20260812.01

js pricee.com collected 2026-09-29 12:08:25 UTC 924,512 bytes, 1 lines download raw bytes

1function check_webp_feature(e,i){var n=new Image;n.onload=function(){var t=0<n.width&&0<n.height;i(e,t)},n.onerror=function(){i(e,!1)},n.src="data:image/webp;base64,"+{lossy:"UklGRiIAAABXRUJQVlA4IBYAAAAwAQCdASoBAAEADsD+JaQAA3AAAAAA",lossless:"UklGRhoAAABXRUJQVlA4TA0AAAAvAAAAEAcQERGIiP4HAA==",alpha:"UklGRkoAAABXRUJQVlA4WAoAAAAQAAAAAAAAAAAAQUxQSAwAAAARBxAR/Q9ERP8DAABWUDggGAAAABQBAJ0BKgEAAQAAAP4AAA3AAP7mtQAAAA==",animation:"UklGRlIAAABXRUJQVlA4WAoAAAASAAAAAAAAAAAAQU5JTQYAAAD/////AABBTk1GJgAAAAAAAAAAAAAAAAAAAGQAAABWUDhMDQAAAC8AAAAQBxAREYiI/gcA"}[e]}function webEnabled(t,e){if(e)for(var i=document.getElementsByTagName("img"),n=0;n<i.length;n++)if(i[n].getAttribute("data-original")&&(-1!=i[n].getAttribute("data-original").search("i.gadgets360cdn.com")||-1!=i[n].getAttribute("data-original").search("assets.gadgets360cdn.com")||-1!=i[n].getAttribute("data-original").search("cdn.gadgets360.com"))&&-1!=i[n].getAttribute("data-original").search(".jpg")){var r=i[n].getAttribute("data-original").replace("output-format=jpg","output-format=webp");i[n].setAttribute("data-original",r)}}function imgLazyLoad(){check_webp_feature("lossy",webEnabled),$("img.lazy").lazyload({bind:"event",effect:"fadeIn",failure_limit:100,threshold:50,effectspeed:100,load:function(t,e){$(this).removeClass("lazy")}})}!function(t,e){"use strict";"object"==typeof module&&"object"==typeof module.exports?module.exports=t.document?e(t,!0):function(t){if(!t.document)throw new Error("jQuery requires a window with a document");return e(t)}:e(t)}("undefined"!=typeof window?window:this,function(T,t){"use strict";var e=[],n=Object.getPrototypeOf,a=e.slice,g=e.flat?function(t){return e.flat.call(t)}:function(t){return e.concat.apply([],t)},l=e.push,r=e.indexOf,i={},s=i.toString,m=i.hasOwnProperty,o=m.toString,u=o.call(Object),v={},y=function(t){return"function"==typeof t&&"number"!=typeof t.nodeType},b=function(t){return null!=t&&t===t.window},S=T.document,c={type:!0,src:!0,nonce:!0,noModule:!0};function w(t,e,i){var n,r,s=(i=i||S).createElement("script");if(s.text=t,e)for(n in c)(r=e[n]||e.getAttribute&&e.getAttribute(n))&&s.setAttribute(n,r);i.head.appendChild(s).parentNode.removeChild(s)}function _(t){return null==t?t+"":"object"==typeof t||"function"==typeof t?i[s.call(t)]||"object":typeof t}var h="3.5.1",C=function(t,e){return new C.fn.init(t,e)};function d(t){var e=!!t&&"length"in t&&t.length,i=_(t);return!y(t)&&!b(t)&&("array"===i||0===e||"number"==typeof e&&0<e&&e-1 in t)}C.fn=C.prototype={jquery:h,constructor:C,length:0,toArray:function(){return a.call(this)},get:function(t){return null==t?a.call(this):t<0?this[t+this.length]:this[t]}
vendor: 41,929 bytes, line 1
1,pushStack:function(t){var e=C.merge(this.constructor(),t);return e.prevObject=this,e},each:function(t){return C.each(this,t)},map:function(i){return this.pushStack(C.map(this,function(t,e){return i.call(t,e,t)}))},slice:function(){return this.pushStack(a.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},even:function(){return this.pushStack(C.grep(this,function(t,e){return(e+1)%2}))},odd:function(){return this.pushStack(C.grep(this,function(t,e){return e%2}))},eq:function(t){var e=this.length,i=+t+(t<0?e:0);return this.pushStack(0<=i&&i<e?[this[i]]:[])},end:function(){return this.prevObject||this.constructor()},push:l,sort:e.sort,splice:e.splice},C.extend=C.fn.extend=function(){var t,e,i,n,r,s,o=arguments[0]||{},a=1,l=arguments.length,u=!1;for("boolean"==typeof o&&(u=o,o=arguments[a]||{},a++),"object"==typeof o||y(o)||(o={}),a===l&&(o=this,a--);a<l;a++)if(null!=(t=arguments[a]))for(e in t)n=t[e],"__proto__"!==e&&o!==n&&(u&&n&&(C.isPlainObject(n)||(r=Array.isArray(n)))?(i=o[e],s=r&&!Array.isArray(i)?[]:r||C.isPlainObject(i)?i:{},r=!1,o[e]=C.extend(u,s,n)):void 0!==n&&(o[e]=n));return o},C.extend({expando:"jQuery"+(h+Math.random()).replace(/\D/g,""),isReady:!0,error:function(t){throw new Error(t)},noop:function(){},isPlainObject:function(t){var e,i;return!(!t||"[object Object]"!==s.call(t)||(e=n(t))&&("function"!=typeof(i=m.call(e,"constructor")&&e.constructor)||o.call(i)!==u))},isEmptyObject:function(t){var e;for(e in t)return!1;return!0},globalEval:function(t,e,i){w(t,{nonce:e&&e.nonce},i)},each:function(t,e){var i,n=0;if(d(t))for(i=t.length;n<i&&!1!==e.call(t[n],n,t[n]);n++);else for(n in t)if(!1===e.call(t[n],n,t[n]))break;return t},makeArray:function(t,e){var i=e||[];return null!=t&&(d(Object(t))?C.merge(i,"string"==typeof t?[t]:t):l.call(i,t)),i},inArray:function(t,e,i){return null==e?-1:r.call(e,t,i)},merge:function(t,e){for(var i=+e.length,n=0,r=t.length;n<i;n++)t[r++]=e[n];return t.length=r,t},grep:function(t,e,i){for(var n=[],r=0,s=t.length,o=!i;r<s;r++)!e(t[r],r)!==o&&n.push(t[r]);return n},map:function(t,e,i){var n,r,s=0,o=[];if(d(t))for(n=t.length;s<n;s++)null!=(r=e(t[s],s,i))&&o.push(r);else for(s in t)null!=(r=e(t[s],s,i))&&o.push(r);return g(o)},guid:1,support:v}),"function"==typeof Symbol&&(C.fn[Symbol.iterator]=e[Symbol.iterator]),C.each("Boolean Number String Function Array Date RegExp Object Error Symbol".split(" "),function(t,e){i["[object "+e+"]"]=e.toLowerCase()});var p=function(i){var t,p,w,s,r,f,h,g,_,l,u,x,T,o,S,m,a,c,v,C="sizzle"+1*new Date,d=i.document,E=0,n=0,y=lt(),b=lt(),k=lt(),I=lt(),D=function(t,e){return t===e&&(u=!0),0},A={}.hasOwnProperty,e=[],P=e.pop,M=e.push,N=e.push,O=e.slice,L=function(t,e){for(var i=0,n=t.length;i<n;i++)if(t[i]===e)return i;return-1},R="checked|selected|async|autofocus|autoplay|controls|defer|disabled|hidden|ismap|loop|multiple|open|readonly|required|scoped",F="[\\x20\\t\\r\\n\\f]",z="(?:\\\\[\\da-fA-F]{1,6}"+F+"?|\\\\[^\\r\\n\\f]|[\\w-]|[^\0-\\x7f])+",B="\\["+F+"*("+z+")(?:"+F+"*([*^$|!~]?=)"+F+"*(?:'((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\"|("+z+"))|)"+F+"*\\]",$=":("+z+")(?:\\((('((?:\\\\.|[^\\\\'])*)'|\"((?:\\\\.|[^\\\\\"])*)\")|((?:\\\\.|[^\\\\()[\\]]|"+B+")*)|.*)\\)|)",j=new RegExp(F+"+","g"),H=new RegExp("^"+F+"+|((?:^|[^\\\\])(?:\\\\.)*)"+F+"+$","g"),q=new RegExp("^"+F+"*,"+F+"*"),V=new RegExp("^"+F+"*([>+~]|"+F+")"+F+"*"),U=new RegExp(F+"|>"),W=new RegExp($),K=new RegExp("^"+z+"$"),G={ID:new RegExp("^#("+z+")"),CLASS:new RegExp("^\\.("+z+")"),TAG:new RegExp("^("+z+"|[*])"),ATTR:new RegExp("^"+B),PSEUDO:new RegExp("^"+$),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+F+"*(even|odd|(([+-]|)(\\d*)n|)"+F+"*(?:([+-]|)"+F+"*(\\d+)|))"+F+"*\\)|)","i"),bool:new RegExp("^(?:"+R+")$","i"),needsContext:new RegExp("^"+F+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+F+"*((?:-\\d)?\\d*)"+F+"*\\)|)(?=[^-]|$)","i")},Y=/HTML$/i,X=/^(?:input|select|textarea|button)$/i,Q=/^h\d$/i,J=/^[^{]+\{\s*\[native \w/,Z=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,tt=/[+~]/,et=new RegExp("\\\\[\\da-fA-F]{1,6}"+F+"?|\\\\([^\\r\\n\\f])","g"),it=function(t,e){var i="0x"+t.slice(1)-65536;return e||(i<0?String.fromCharCode(i+65536):String.fromCharCode(i>>10|55296,1023&i|56320))},nt=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\0-\x1f\x7f-\uFFFF\w-]/g,rt=function(t,e){return e?"\0"===t?"�":t.slice(0,-1)+"\\"+t.charCodeAt(t.length-1).toString(16)+" ":"\\"+t},st=function(){x()},ot=wt(function(t){return!0===t.disabled&&"fieldset"===t.nodeName.toLowerCase()},{dir:"parentNode",next:"legend"});try{N.apply(e=O.call(d.childNodes),d.childNodes),e[d.childNodes.length].nodeType}catch(t){N={apply:e.length?function(t,e){M.apply(t,O.call(e))}:function(t,e){for(var i=t.length,n=0;t[i++]=e[n++];);t.length=i-1}}}function at(t,e,i,n){var r,s,o,a,l,u,c,h=e&&e.ownerDocument,d=e?e.nodeType:9;if(i=i||[],"string"!=typeof t||!t||1!==d&&9!==d&&11!==d)return i;if(!n&&(x(e),e=e||T,S)){if(11!==d&&(l=Z.exec(t)))if(r=l[1]){if(9===d){if(!(o=e.getElementById(r)))return i;if(o.id===r)return i.push(o),i}else if(h&&(o=h.getElementById(r))&&v(e,o)&&o.id===r)return i.push(o),i}else{if(l[2])return N.apply(i,e.getElementsByTagName(t)),i;if((r=l[3])&&p.getElementsByClassName&&e.getElementsByClassName)return N.apply(i,e.getElementsByClassName(r)),i}if(p.qsa&&!I[t+" "]&&(!m||!m.test(t))&&(1!==d||"object"!==e.nodeName.toLowerCase())){if(c=t,h=e,1===d&&(U.test(t)||V.test(t))){for((h=tt.test(t)&&vt(e.parentNode)||e)===e&&p.scope||((a=e.getAttribute("id"))?a=a.replace(nt,rt):e.setAttribute("id",a=C)),s=(u=f(t)).length;s--;)u[s]=(a?"#"+a:":scope")+" "+bt(u[s]);c=u.join(",")}try{return N.apply(i,h.querySelectorAll(c)),i}catch(e){I(t,!0)}finally{a===C&&e.removeAttribute("id")}}}return g(t.replace(H,"$1"),e,i,n)}function lt(){var n=[];return function t(e,i){return n.push(e+" ")>w.cacheLength&&delete t[n.shift()],t[e+" "]=i}}function ut(t){return t[C]=!0,t}function ct(t){var e=T.createElement("fieldset");try{return!!t(e)}catch(t){return!1}finally{e.parentNode&&e.parentNode.removeChild(e),e=null}}function ht(t,e){for(var i=t.split("|"),n=i.length;n--;)w.attrHandle[i[n]]=e}function dt(t,e){var i=e&&t,n=i&&1===t.nodeType&&1===e.nodeType&&t.sourceIndex-e.sourceIndex;if(n)return n;if(i)for(;i=i.nextSibling;)if(i===e)return-1;return t?1:-1}function pt(e){return function(t){return"input"===t.nodeName.toLowerCase()&&t.type===e}}function ft(i){return function(t){var e=t.nodeName.toLowerCase();return("input"===e||"button"===e)&&t.type===i}}function gt(e){return function(t){return"form"in t?t.parentNode&&!1===t.disabled?"label"in t?"label"in t.parentNode?t.parentNode.disabled===e:t.disabled===e:t.isDisabled===e||t.isDisabled!==!e&&ot(t)===e:t.disabled===e:"label"in t&&t.disabled===e}}function mt(o){return ut(function(s){return s=+s,ut(function(t,e){for(var i,n=o([],t.length,s),r=n.length;r--;)t[i=n[r]]&&(t[i]=!(e[i]=t[i]))})})}function vt(t){return t&&void 0!==t.getElementsByTagName&&t}for(t in p=at.support={},r=at.isXML=function(t){var e=t.namespaceURI,i=(t.ownerDocument||t).documentElement;return!Y.test(e||i&&i.nodeName||"HTML")},x=at.setDocument=function(t){var e,i,n=t?t.ownerDocument||t:d;return n!=T&&9===n.nodeType&&n.documentElement&&(o=(T=n).documentElement,S=!r(T),d!=T&&(i=T.defaultView)&&i.top!==i&&(i.addEventListener?i.addEventListener("unload",st,!1):i.attachEvent&&i.attachEvent("onunload",st)),p.scope=ct(function(t){return o.appendChild(t).appendChild(T.createElement("div")),void 0!==t.querySelectorAll&&!t.querySelectorAll(":scope fieldset div").length}),p.attributes=ct(function(t){return t.className="i",!t.getAttribute("className")}),p.getElementsByTagName=ct(function(t){return t.appendChild(T.createComment("")),!t.getElementsByTagName("*").length}),p.getElementsByClassName=J.test(T.getElementsByClassName),p.getById=ct(function(t){return o.appendChild(t).id=C,!T.getElementsByName||!T.getElementsByName(C).length}),p.getById?(w.filter.ID=function(t){var e=t.replace(et,it);return function(t){return t.getAttribute("id")===e}},w.find.ID=function(t,e){if(void 0!==e.getElementById&&S){var i=e.getElementById(t);return i?[i]:[]}}):(w.filter.ID=function(t){var i=t.replace(et,it);return function(t){var e=void 0!==t.getAttributeNode&&t.getAttributeNode("id");return e&&e.value===i}},w.find.ID=function(t,e){if(void 0!==e.getElementById&&S){var i,n,r,s=e.getElementById(t);if(s){if((i=s.getAttributeNode("id"))&&i.value===t)return[s];for(r=e.getElementsByName(t),n=0;s=r[n++];)if((i=s.getAttributeNode("id"))&&i.value===t)return[s]}return[]}}),w.find.TAG=p.getElementsByTagName?function(t,e){return void 0!==e.getElementsByTagName?e.getElementsByTagName(t):p.qsa?e.querySelectorAll(t):void 0}:function(t,e){var i,n=[],r=0,s=e.getElementsByTagName(t);if("*"!==t)return s;for(;i=s[r++];)1===i.nodeType&&n.push(i);return n},w.find.CLASS=p.getElementsByClassName&&function(t,e){if(void 0!==e.getElementsByClassName&&S)return e.getElementsByClassName(t)},a=[],m=[],(p.qsa=J.test(T.querySelectorAll))&&(ct(function(t){var e;o.appendChild(t).innerHTML="<a id='"+C+"'></a><select id='"+C+"-\r\\' msallowcapture=''><option selected=''></option></select>",t.querySelectorAll("[msallowcapture^='']").length&&m.push("[*^$]="+F+"*(?:''|\"\")"),t.querySelectorAll("[selected]").length||m.push("\\["+F+"*(?:value|"+R+")"),t.querySelectorAll("[id~="+C+"-]").length||m.push("~="),(e=T.createElement("input")).setAttribute("name",""),t.appendChild(e),t.querySelectorAll("[name='']").length||m.push("\\["+F+"*name"+F+"*="+F+"*(?:''|\"\")"),t.querySelectorAll(":checked").length||m.push(":checked"),t.querySelectorAll("a#"+C+"+*").length||m.push(".#.+[+~]"),t.querySelectorAll("\\\f"),m.push("[\\r\\n\\f]")}),ct(function(t){t.innerHTML="<a href='' disabled='disabled'></a><select disabled='disabled'><option/></select>";var e=T.createElement("input");e.setAttribute("type","hidden"),t.appendChild(e).setAttribute("name","D"),t.querySelectorAll("[name=d]").length&&m.push("name"+F+"*[*^$|!~]?="),2!==t.querySelectorAll(":enabled").length&&m.push(":enabled",":disabled"),o.appendChild(t).disabled=!0,2!==t.querySelectorAll(":disabled").length&&m.push(":enabled",":disabled"),t.querySelectorAll("*,:x"),m.push(",.*:")})),(p.matchesSelector=J.test(c=o.matches||o.webkitMatchesSelector||o.mozMatchesSelector||o.oMatchesSelector||o.msMatchesSelector))&&ct(function(t){p.disconnectedMatch=c.call(t,"*"),c.call(t,"[s!='']:x"),a.push("!=",$)}),m=m.length&&new RegExp(m.join("|")),a=a.length&&new RegExp(a.join("|")),e=J.test(o.compareDocumentPosition),v=e||J.test(o.contains)?function(t,e){var i=9===t.nodeType?t.documentElement:t,n=e&&e.parentNode;return t===n||!(!n||1!==n.nodeType||!(i.contains?i.contains(n):t.compareDocumentPosition&&16&t.compareDocumentPosition(n)))}:function(t,e){if(e)for(;e=e.parentNode;)if(e===t)return!0;return!1},D=e?function(t,e){if(t===e)return u=!0,0;var i=!t.compareDocumentPosition-!e.compareDocumentPosition;return i||(1&(i=(t.ownerDocument||t)==(e.ownerDocument||e)?t.compareDocumentPosition(e):1)||!p.sortDetached&&e.compareDocumentPosition(t)===i?t==T||t.ownerDocument==d&&v(d,t)?-1:e==T||e.ownerDocument==d&&v(d,e)?1:l?L(l,t)-L(l,e):0:4&i?-1:1)}:function(t,e){if(t===e)return u=!0,0;var i,n=0,r=t.parentNode,s=e.parentNode,o=[t],a=[e];if(!r||!s)return t==T?-1:e==T?1:r?-1:s?1:l?L(l,t)-L(l,e):0;if(r===s)return dt(t,e);for(i=t;i=i.parentNode;)o.unshift(i);for(i=e;i=i.parentNode;)a.unshift(i);for(;o[n]===a[n];)n++;return n?dt(o[n],a[n]):o[n]==d?-1:a[n]==d?1:0}),T},at.matches=function(t,e){return at(t,null,null,e)},at.matchesSelector=function(t,e){if(x(t),p.matchesSelector&&S&&!I[e+" "]&&(!a||!a.test(e))&&(!m||!m.test(e)))try{var i=c.call(t,e);if(i||p.disconnectedMatch||t.document&&11!==t.document.nodeType)return i}catch(t){I(e,!0)}return 0<at(e,T,null,[t]).length},at.contains=function(t,e){return(t.ownerDocument||t)!=T&&x(t),v(t,e)},at.attr=function(t,e){(t.ownerDocument||t)!=T&&x(t);var i=w.attrHandle[e.toLowerCase()],n=i&&A.call(w.attrHandle,e.toLowerCase())?i(t,e,!S):void 0;return void 0!==n?n:p.attributes||!S?t.getAttribute(e):(n=t.getAttributeNode(e))&&n.specified?n.value:null},at.escape=function(t){return(t+"").replace(nt,rt)},at.error=function(t){throw new Error("Syntax error, unrecognized expression: "+t)},at.uniqueSort=function(t){var e,i=[],n=0,r=0;if(u=!p.detectDuplicates,l=!p.sortStable&&t.slice(0),t.sort(D),u){for(;e=t[r++];)e===t[r]&&(n=i.push(r));for(;n--;)t.splice(i[n],1)}return l=null,t},s=at.getText=function(t){var e,i="",n=0,r=t.nodeType;if(r){if(1===r||9===r||11===r){if("string"==typeof t.textContent)return t.textContent;for(t=t.firstChild;t;t=t.nextSibling)i+=s(t)}else if(3===r||4===r)return t.nodeValue}else for(;e=t[n++];)i+=s(e);return i},(w=at.selectors={cacheLength:50,createPseudo:ut,match:G,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(t){return t[1]=t[1].replace(et,it),t[3]=(t[3]||t[4]||t[5]||"").replace(et,it),"~="===t[2]&&(t[3]=" "+t[3]+" "),t.slice(0,4)},CHILD:function(t){return t[1]=t[1].toLowerCase(),"nth"===t[1].slice(0,3)?(t[3]||at.error(t[0]),t[4]=+(t[4]?t[5]+(t[6]||1):2*("even"===t[3]||"odd"===t[3])),t[5]=+(t[7]+t[8]||"odd"===t[3])):t[3]&&at.error(t[0]),t},PSEUDO:function(t){var e,i=!t[6]&&t[2];return G.CHILD.test(t[0])?null:(t[3]?t[2]=t[4]||t[5]||"":i&&W.test(i)&&(e=f(i,!0))&&(e=i.indexOf(")",i.length-e)-i.length)&&(t[0]=t[0].slice(0,e),t[2]=i.slice(0,e)),t.slice(0,3))}},filter:{TAG:function(t){var e=t.replace(et,it).toLowerCase();return"*"===t?function(){return!0}:function(t){return t.nodeName&&t.nodeName.toLowerCase()===e}},CLASS:function(t){var e=y[t+" "];return e||(e=new RegExp("(^|"+F+")"+t+"("+F+"|$)"))&&y(t,function(t){return e.test("string"==typeof t.className&&t.className||void 0!==t.getAttribute&&t.getAttribute("class")||"")})},ATTR:function(i,n,r){return function(t){var e=at.attr(t,i);return null==e?"!="===n:!n||(e+="","="===n?e===r:"!="===n?e!==r:"^="===n?r&&0===e.indexOf(r):"*="===n?r&&-1<e.indexOf(r):"$="===n?r&&e.slice(-r.length)===r:"~="===n?-1<(" "+e.replace(j," ")+" ").indexOf(r):"|="===n&&(e===r||e.slice(0,r.length+1)===r+"-"))}},CHILD:function(f,t,e,g,m){var v="nth"!==f.slice(0,3),y="last"!==f.slice(-4),b="of-type"===t;return 1===g&&0===m?function(t){return!!t.parentNode}:function(t,e,i){var n,r,s,o,a,l,u=v!==y?"nextSibling":"previousSibling",c=t.parentNode,h=b&&t.nodeName.toLowerCase(),d=!i&&!b,p=!1;if(c){if(v){for(;u;){for(o=t;o=o[u];)if(b?o.nodeName.toLowerCase()===h:1===o.nodeType)return!1;l=u="only"===f&&!l&&"nextSibling"}return!0}if(l=[y?c.firstChild:c.lastChild],y&&d){for(p=(a=(n=(r=(s=(o=c)[C]||(o[C]={}))[o.uniqueID]||(s[o.uniqueID]={}))[f]||[])[0]===E&&n[1])&&n[2],o=a&&c.childNodes[a];o=++a&&o&&o[u]||(p=a=0)||l.pop();)if(1===o.nodeType&&++p&&o===t){r[f]=[E,a,p];break}}else if(d&&(p=a=(n=(r=(s=(o=t)[C]||(o[C]={}))[o.uniqueID]||(s[o.uniqueID]={}))[f]||[])[0]===E&&n[1]),!1===p)for(;(o=++a&&o&&o[u]||(p=a=0)||l.pop())&&((b?o.nodeName.toLowerCase()!==h:1!==o.nodeType)||!++p||(d&&((r=(s=o[C]||(o[C]={}))[o.uniqueID]||(s[o.uniqueID]={}))[f]=[E,p]),o!==t)););return(p-=m)===g||p%g==0&&0<=p/g}}},PSEUDO:function(t,s){var e,o=w.pseudos[t]||w.setFilters[t.toLowerCase()]||at.error("unsupported pseudo: "+t);return o[C]?o(s):1<o.length?(e=[t,t,"",s],w.setFilters.hasOwnProperty(t.toLowerCase())?ut(function(t,e){for(var i,n=o(t,s),r=n.length;r--;)t[i=L(t,n[r])]=!(e[i]=n[r])}):function(t){return o(t,0,e)}):o}},pseudos:{not:ut(function(t){var n=[],r=[],a=h(t.replace(H,"$1"));return a[C]?ut(function(t,e,i,n){for(var r,s=a(t,null,n,[]),o=t.length;o--;)(r=s[o])&&(t[o]=!(e[o]=r))}):function(t,e,i){return n[0]=t,a(n,null,i,r),n[0]=null,!r.pop()}}),has:ut(function(e){return function(t){return 0<at(e,t).length}}),contains:ut(function(e){return e=e.replace(et,it),function(t){return-1<(t.textContent||s(t)).indexOf(e)}}),lang:ut(function(i){return K.test(i||"")||at.error("unsupported lang: "+i),i=i.replace(et,it).toLowerCase(),function(t){var e;do{if(e=S?t.lang:t.getAttribute("xml:lang")||t.getAttribute("lang"))return(e=e.toLowerCase())===i||0===e.indexOf(i+"-")}while((t=t.parentNode)&&1===t.nodeType);return!1}}),target:function(t){var e=i.location&&i.location.hash;return e&&e.slice(1)===t.id},root:function(t){return t===o},focus:function(t){return t===T.activeElement&&(!T.hasFocus||T.hasFocus())&&!!(t.type||t.href||~t.tabIndex)},enabled:gt(!1),disabled:gt(!0),checked:function(t){var e=t.nodeName.toLowerCase();return"input"===e&&!!t.checked||"option"===e&&!!t.selected},selected:function(t){return t.parentNode&&t.parentNode.selectedIndex,!0===t.selected},empty:function(t){for(t=t.firstChild;t;t=t.nextSibling)if(t.nodeType<6)return!1;return!0},parent:function(t){return!w.pseudos.empty(t)},header:function(t){return Q.test(t.nodeName)},input:function(t){return X.test(t.nodeName)},button:function(t){var e=t.nodeName.toLowerCase();return"input"===e&&"button"===t.type||"button"===e},text:function(t){var e;return"input"===t.nodeName.toLowerCase()&&"text"===t.type&&(null==(e=t.getAttribute("type"))||"text"===e.toLowerCase())},first:mt(function(){return[0]}),last:mt(function(t,e){return[e-1]}),eq:mt(function(t,e,i){return[i<0?i+e:i]}),even:mt(function(t,e){for(var i=0;i<e;i+=2)t.push(i);return t}),odd:mt(function(t,e){for(var i=1;i<e;i+=2)t.push(i);return t}),lt:mt(function(t,e,i){for(var n=i<0?i+e:e<i?e:i;0<=--n;)t.push(n);return t}),gt:mt(function(t,e,i){for(var n=i<0?i+e:i;++n<e;)t.push(n);return t})}}).pseudos.nth=w.pseudos.eq,{radio:!0,checkbox:!0,file:!0,password:!0,image:!0})w.pseudos[t]=pt(t);for(t in{submit:!0,reset:!0})w.pseudos[t]=ft(t);function yt(){}function bt(t){for(var e=0,i=t.length,n="";e<i;e++)n+=t[e].value;return n}function wt(a,t,e){var l=t.dir,u=t.next,c=u||l,h=e&&"parentNode"===c,d=n++;return t.first?function(t,e,i){for(;t=t[l];)if(1===t.nodeType||h)return a(t,e,i);return!1}:function(t,e,i){var n,r,s,o=[E,d];if(i){for(;t=t[l];)if((1===t.nodeType||h)&&a(t,e,i))return!0}else for(;t=t[l];)if(1===t.nodeType||h)if(r=(s=t[C]||(t[C]={}))[t.uniqueID]||(s[t.uniqueID]={}),u&&u===t.nodeName.toLowerCase())t=t[l]||t;else{if((n=r[c])&&n[0]===E&&n[1]===d)return o[2]=n[2];if((r[c]=o)[2]=a(t,e,i))return!0}return!1}}function _t(r){return 1<r.length?function(t,e,i){for(var n=r.length;n--;)if(!r[n](t,e,i))return!1;return!0}:r[0]}function xt(t,e,i,n,r){for(var s,o=[],a=0,l=t.length,u=null!=e;a<l;a++)(s=t[a])&&(i&&!i(s,n,r)||(o.push(s),u&&e.push(a)));return o}function Tt(p,f,g,m,v,t){return m&&!m[C]&&(m=Tt(m)),v&&!v[C]&&(v=Tt(v,t)),ut(function(t,e,i,n){var r,s,o,a=[],l=[],u=e.length,c=t||function(t,e,i){for(var n=0,r=e.length;n<r;n++)at(t,e[n],i);return i}(f||"*",i.nodeType?[i]:i,[]),h=!p||!t&&f?c:xt(c,a,p,i,n),d=g?v||(t?p:u||m)?[]:e:h;if(g&&g(h,d,i,n),m)for(r=xt(d,l),m(r,[],i,n),s=r.length;s--;)(o=r[s])&&(d[l[s]]=!(h[l[s]]=o));if(t){if(v||p){if(v){for(r=[],s=d.length;s--;)(o=d[s])&&r.push(h[s]=o);v(null,d=[],r,n)}for(s=d.length;s--;)(o=d[s])&&-1<(r=v?L(t,o):a[s])&&(t[r]=!(e[r]=o))}}else d=xt(d===e?d.splice(u,d.length):d),v?v(null,e,d,n):N.apply(e,d)})}function St(t){for(var r,e,i,n=t.length,s=w.relative[t[0].type],o=s||w.relative[" "],a=s?1:0,l=wt(function(t){return t===r},o,!0),u=wt(function(t){return-1<L(r,t)},o,!0),c=[function(t,e,i){var n=!s&&(i||e!==_)||((r=e).nodeType?l(t,e,i):u(t,e,i));return r=null,n}];a<n;a++)if(e=w.relative[t[a].type])c=[wt(_t(c),e)];else{if((e=w.filter[t[a].type].apply(null,t[a].matches))[C]){for(i=++a;i<n&&!w.relative[t[i].type];i++);return Tt(1<a&&_t(c),1<a&&bt(t.slice(0,a-1).concat({value:" "===t[a-2].type?"*":""})).replace(H,"$1"),e,a<i&&St(t.slice(a,i)),i<n&&St(t=t.slice(i)),i<n&&bt(t))}c.push(e)}return _t(c)}return yt.prototype=w.filters=w.pseudos,w.setFilters=new yt,f=at.tokenize=function(t,e){var i,n,r,s,o,a,l,u=b[t+" "];if(u)return e?0:u.slice(0);for(o=t,a=[],l=w.preFilter;o;){for(s in i&&!(n=q.exec(o))||(n&&(o=o.slice(n[0].length)||o),a.push(r=[])),i=!1,(n=V.exec(o))&&(i=n.shift(),r.push({value:i,type:n[0].replace(H," ")}),o=o.slice(i.length)),w.filter)!(n=G[s].exec(o))||l[s]&&!(n=l[s](n))||(i=n.shift(),r.push({value:i,type:s,matches:n}),o=o.slice(i.length));if(!i)break}return e?o.length:o?at.error(t):b(t,a).slice(0)},h=at.compile=function(t,e){var i,m,v,y,b,n,r=[],s=[],o=k[t+" "];if(!o){for(e||(e=f(t)),i=e.length;i--;)(o=St(e[i]))[C]?r.push(o):s.push(o);(o=k(t,(m=s,y=0<(v=r).length,b=0<m.length,n=function(t,e,i,n,r){var s,o,a,l=0,u="0",c=t&&[],h=[],d=_,p=t||b&&w.find.TAG("*",r),f=E+=null==d?1:Math.random()||.1,g=p.length;for(r&&(_=e==T||e||r);u!==g&&null!=(s=p[u]);u++){if(b&&s){for(o=0,e||s.ownerDocument==T||(x(s),i=!S);a=m[o++];)if(a(s,e||T,i)){n.push(s);break}r&&(E=f)}y&&((s=!a&&s)&&l--,t&&c.push(s))}if(l+=u,y&&u!==l){for(o=0;a=v[o++];)a(c,h,e,i);if(t){if(0<l)for(;u--;)c[u]||h[u]||(h[u]=P.call(n));h=xt(h)}N.apply(n,h),r&&!t&&0<h.length&&1<l+v.length&&at.uniqueSort(n)}return r&&(E=f,_=d),c},y?ut(n):n))).selector=t}return o},g=at.select=function(t,e,i,n){var r,s,o,a,l,u="function"==typeof t&&t,c=!n&&f(t=u.selector||t);if(i=i||[],1===c.length){if(2<(s=c[0]=c[0].slice(0)).length&&"ID"===(o=s[0]).type&&9===e.nodeType&&S&&w.relative[s[1].type]){if(!(e=(w.find.ID(o.matches[0].replace(et,it),e)||[])[0]))return i;u&&(e=e.parentNode),t=t.slice(s.shift().value.length)}for(r=G.needsContext.test(t)?0:s.length;r--&&(o=s[r],!w.relative[a=o.type]);)if((l=w.find[a])&&(n=l(o.matches[0].replace(et,it),tt.test(s[0].type)&&vt(e.parentNode)||e))){if(s.splice(r,1),!(t=n.length&&bt(s)))return N.apply(i,n),i;break}}return(u||h(t,c))(n,e,!S,i,!e||tt.test(t)&&vt(e.parentNode)||e),i},p.sortStable=C.split("").sort(D).join("")===C,p.detectDuplicates=!!u,x(),p.sortDetached=ct(function(t){return 1&t.compareDocumentPosition(T.createElement("fieldset"))}),ct(function(t){return t.innerHTML="<a href='#'></a>","#"===t.firstChild.getAttribute("href")})||ht("type|href|height|width",function(t,e,i){if(!i)return t.getAttribute(e,"type"===e.toLowerCase()?1:2)}),p.attributes&&ct(function(t){return t.innerHTML="<input/>",t.firstChild.setAttribute("value",""),""===t.firstChild.getAttribute("value")})||ht("value",function(t,e,i){if(!i&&"input"===t.nodeName.toLowerCase())return t.defaultValue}),ct(function(t){return null==t.getAttribute("disabled")})||ht(R,function(t,e,i){var n;if(!i)return!0===t[e]?e.toLowerCase():(n=t.getAttributeNode(e))&&n.specified?n.value:null}),at}(T);C.find=p,C.expr=p.selectors,C.expr[":"]=C.expr.pseudos,C.uniqueSort=C.unique=p.uniqueSort,C.text=p.getText,C.isXMLDoc=p.isXML,C.contains=p.contains,C.escapeSelector=p.escape;var f=function(t,e,i){for(var n=[],r=void 0!==i;(t=t[e])&&9!==t.nodeType;)if(1===t.nodeType){if(r&&C(t).is(i))break;n.push(t)}return n},x=function(t,e){for(var i=[];t;t=t.nextSibling)1===t.nodeType&&t!==e&&i.push(t);return i},E=C.expr.match.needsContext;function k(t,e){return t.nodeName&&t.nodeName.toLowerCase()===e.toLowerCase()}var I=/^<([a-z][^\/\0>:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;function D(t,i,n){return y(i)?C.grep(t,function(t,e){return!!i.call(t,e,t)!==n}):i.nodeType?C.grep(t,function(t){return t===i!==n}):"string"!=typeof i?C.grep(t,function(t){return-1<r.call(i,t)!==n}):C.filter(i,t,n)}C.filter=function(t,e,i){var n=e[0];return i&&(t=":not("+t+")"),1===e.length&&1===n.nodeType?C.find.matchesSelector(n,t)?[n]:[]:C.find.matches(t,C.grep(e,function(t){return 1===t.nodeType}))},C.fn.extend({find:function(t){var e,i,n=this.length,r=this;if("string"!=typeof t)return this.pushStack(C(t).filter(function(){for(e=0;e<n;e++)if(C.contains(r[e],this))return!0}));for(i=this.pushStack([]),e=0;e<n;e++)C.find(t,r[e],i);return 1<n?C.uniqueSort(i):i},filter:function(t){return this.pushStack(D(this,t||[],!1))},not:function(t){return this.pushStack(D(this,t||[],!0))},is:function(t){return!!D(this,"string"==typeof t&&E.test(t)?C(t):t||[],!1).length}});var A,P=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]+))$/;(C.fn.init=function(t,e,i){var n,r;if(!t)return this;if(i=i||A,"string"!=typeof t)return t.nodeType?(this[0]=t,this.length=1,this):y(t)?void 0!==i.ready?i.ready(t):t(C):C.makeArray(t,this);if(!(n="<"===t[0]&&">"===t[t.length-1]&&3<=t.length?[null,t,null]:P.exec(t))||!n[1]&&e)return!e||e.jquery?(e||i).find(t):this.constructor(e).find(t);if(n[1]){if(e=e instanceof C?e[0]:e,C.merge(this,C.parseHTML(n[1],e&&e.nodeType?e.ownerDocument||e:S,!0)),I.test(n[1])&&C.isPlainObject(e))for(n in e)y(this[n])?this[n](e[n]):this.attr(n,e[n]);return this}return(r=S.getElementById(n[2]))&&(this[0]=r,this.length=1),this}).prototype=C.fn,A=C(S);var M=/^(?:parents|prev(?:Until|All))/,N={children:!0,contents:!0,next:!0,prev:!0};function O(t,e){for(;(t=t[e])&&1!==t.nodeType;);return t}C.fn.extend({has:function(t){var e=C(t,this),i=e.length;return this.filter(function(){for(var t=0;t<i;t++)if(C.contains(this,e[t]))return!0})},closest:function(t,e){var i,n=0,r=this.length,s=[],o="string"!=typeof t&&C(t);if(!E.test(t))for(;n<r;n++)for(i=this[n];i&&i!==e;i=i.parentNode)if(i.nodeType<11&&(o?-1<o.index(i):1===i.nodeType&&C.find.matchesSelector(i,t))){s.push(i);break}return this.pushStack(1<s.length?C.uniqueSort(s):s)},index:function(t){return t?"string"==typeof t?r.call(C(t),this[0]):r.call(this,t.jquery?t[0]:t):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(t,e){return this.pushStack(C.uniqueSort(C.merge(this.get(),C(t,e))))},addBack:function(t){return this.add(null==t?this.prevObject:this.prevObject.filter(t))}}),C.each({parent:function(t){var e=t.parentNode;return e&&11!==e.nodeType?e:null},parents:function(t){return f(t,"parentNode")},parentsUntil:function(t,e,i){return f(t,"parentNode",i)},next:function(t){return O(t,"nextSibling")},prev:function(t){return O(t,"previousSibling")},nextAll:function(t){return f(t,"nextSibling")},prevAll:function(t){return f(t,"previousSibling")},nextUntil:function(t,e,i){return f(t,"nextSibling",i)},prevUntil:function(t,e,i){return f(t,"previousSibling",i)},siblings:function(t){return x((t.parentNode||{}).firstChild,t)},children:function(t){return x(t.firstChild)},contents:function(t){return null!=t.contentDocument&&n(t.contentDocument)?t.contentDocument:(k(t,"template")&&(t=t.content||t),C.merge([],t.childNodes))}},function(n,r){C.fn[n]=function(t,e){var i=C.map(this,r,t);return"Until"!==n.slice(-5)&&(e=t),e&&"string"==typeof e&&(i=C.filter(e,i)),1<this.length&&(N[n]||C.uniqueSort(i),M.test(n)&&i.reverse()),this.pushStack(i)}});var L=/[^\x20\t\r\n\f]+/g;function R(t){return t}function F(t){throw t}function z(t,e,i,n){var r;try{t&&y(r=t.promise)?r.call(t).done(e).fail(i):t&&y(r=t.then)?r.call(t,e,i):e.apply(void 0,[t].slice(n))}catch(t){i.apply(void 0,[t])}}C.Callbacks=function(n){var t,i;n="string"==typeof n?(t=n,i={},C.each(t.match(L)||[],function(t,e){i[e]=!0}),i):C.extend({},n);var r,e,s,o,a=[],l=[],u=-1,c=function(){for(o=o||n.once,s=r=!0;l.length;u=-1)for(e=l.shift();++u<a.length;)!1===a[u].apply(e[0],e[1])&&n.stopOnFalse&&(u=a.length,e=!1);n.memory||(e=!1),r=!1,o&&(a=e?[]:"")},h={add:function(){return a&&(e&&!r&&(u=a.length-1,l.push(e)),function i(t){C.each(t,function(t,e){y(e)?n.unique&&h.has(e)||a.push(e):e&&e.length&&"string"!==_(e)&&i(e)})}(arguments),e&&!r&&c()),this},remove:function(){return C.each(arguments,function(t,e){for(var i;-1<(i=C.inArray(e,a,i));)a.splice(i,1),i<=u&&u--}),this},has:function(t){return t?-1<C.inArray(t,a):0<a.length},empty:function(){return a&&(a=[]),this},disable:function(){return o=l=[],a=e="",this},disabled:function(){return!a},lock:function(){return o=l=[],e||r||(a=e=""),this},locked:function(){return!!o},fireWith:function(t,e){return o||(e=[t,(e=e||[]).slice?e.slice():e],l.push(e),r||c()),this},fire:function(){return h.fireWith(this,arguments),this},fired:function(){return!!s}};return h},C.extend({Deferred:function(t){var s=[["notify","progress",C.Callbacks("memory"),C.Callbacks("memory"),2],["resolve","done",C.Callbacks("once memory"),C.Callbacks("once memory"),0,"resolved"],["reject","fail",C.Callbacks("once memory"),C.Callbacks("once memory"),1,"rejected"]],r="pending",o={state:function(){return r},always:function(){return a.done(arguments).fail(arguments),this},catch:function(t){return o.then(null,t)},pipe:function(){var r=arguments;return C.Deferred(function(n){C.each(s,function(t,e){var i=y(r[e[4]])&&r[e[4]];a[e[1]](function(){var t=i&&i.apply(this,arguments);t&&y(t.promise)?t.promise().progress(n.notify).done(n.resolve).fail(n.reject):n[e[0]+"With"](this,i?[t]:arguments)})}),r=null}).promise()},then:function(e,i,n){var l=0;function u(r,s,o,a){return function(){var i=this,n=arguments,t=function(){var t,e;if(!(r<l)){if((t=o.apply(i,n))===s.promise())throw new TypeError("Thenable self-resolution");e=t&&("object"==typeof t||"function"==typeof t)&&t.then,y(e)?a?e.call(t,u(l,s,R,a),u(l,s,F,a)):(l++,e.call(t,u(l,s,R,a),u(l,s,F,a),u(l,s,R,s.notifyWith))):(o!==R&&(i=void 0,n=[t]),(a||s.resolveWith)(i,n))}},e=a?t:function(){try{t()}catch(t){C.Deferred.exceptionHook&&C.Deferred.exceptionHook(t,e.stackTrace),l<=r+1&&(o!==F&&(i=void 0,n=[t]),s.rejectWith(i,n))}};r?e():(C.Deferred.getStackHook&&(e.stackTrace=C.Deferred.getStackHook()),T.setTimeout(e))}}return C.Deferred(function(t){s[0][3].add(u(0,t,y(n)?n:R,t.notifyWith)),s[1][3].add(u(0,t,y(e)?e:R)),s[2][3].add(u(0,t,y(i)?i:F))}).promise()},promise:function(t){return null!=t?C.extend(t,o):o}},a={};return C.each(s,function(t,e){var i=e[2],n=e[5];o[e[1]]=i.add,n&&i.add(function(){r=n},s[3-t][2].disable,s[3-t][3].disable,s[0][2].lock,s[0][3].lock),i.add(e[3].fire),a[e[0]]=function(){return a[e[0]+"With"](this===a?void 0:this,arguments),this},a[e[0]+"With"]=i.fireWith}),o.promise(a),t&&t.call(a,a),a},when:function(t){var i=arguments.length,e=i,n=Array(e),r=a.call(arguments),s=C.Deferred(),o=function(e){return function(t){n[e]=this,r[e]=1<arguments.length?a.call(arguments):t,--i||s.resolveWith(n,r)}};if(i<=1&&(z(t,s.done(o(e)).resolve,s.reject,!i),"pending"===s.state()||y(r[e]&&r[e].then)))return s.then();for(;e--;)z(r[e],o(e),s.reject);return s.promise()}});var B=/^(Eval|Internal|Range|Reference|Syntax|Type|URI)Error$/;C.Deferred.exceptionHook=function(t,e){T.console&&T.console.warn&&t&&B.test(t.name)&&T.console.warn("jQuery.Deferred exception: "+t.message,t.stack,e)},C.readyException=function(t){T.setTimeout(function(){throw t})};var $=C.Deferred();function j(){S.removeEventListener("DOMContentLoaded",j),T.removeEventListener("load",j),C.ready()}C.fn.ready=function(t){return $.then(t).catch(function(t){C.readyException(t)}),this},C.extend({isReady:!1,readyWait:1,ready:function(t){(!0===t?--C.readyWait:C.isReady)||(C.isReady=!0)!==t&&0<--C.readyWait||$.resolveWith(S,[C])}}),C.ready.then=$.then,"complete"===S.readyState||"loading"!==S.readyState&&!S.documentElement.doScroll?T.setTimeout(C.ready):(S.addEventListener("DOMContentLoaded",j),T.addEventListener("load",j));var H=function(t,e,i,n,r,s,o){var a=0,l=t.length,u=null==i;if("object"===_(i))for(a in r=!0,i)H(t,e,a,i[a],!0,s,o);else if(void 0!==n&&(r=!0,y(n)||(o=!0),u&&(e=o?(e.call(t,n),null):(u=e,function(t,e,i){return u.call(C(t),i)})),e))for(;a<l;a++)e(t[a],i,o?n:n.call(t[a],a,e(t[a],i)));return r?t:u?e.call(t):l?e(t[0],i):s},q=/^-ms-/,V=/-([a-z])/g;function U(t,e){return e.toUpperCase()}function W(t){return t.replace(q,"ms-").replace(V,U)}var K=function(t){return 1===t.nodeType||9===t.nodeType||!+t.nodeType};function G(){this.expando=C.expando+G.uid++}G.uid=1,G.prototype={cache:function(t){var e=t[this.expando];return e||(e={},K(t)&&(t.nodeType?t[this.expando]=e:Object.defineProperty(t,this.expando,{value:e,configurable:!0}))),e},set:function(t,e,i){var n,r=this.cache(t);if("string"==typeof e)r[W(e)]=i;else for(n in e)r[W(n)]=e[n];return r},get:function(t,e){return void 0===e?this.cache(t):t[this.expando]&&t[this.expando][W(e)]},access:function(t,e,i){return void 0===e||e&&"string"==typeof e&&void 0===i?this.get(t,e):(this.set(t,e,i),void 0!==i?i:e)},remove:function(t,e){var i,n=t[this.expando];if(void 0!==n){if(void 0!==e){i=(e=Array.isArray(e)?e.map(W):(e=W(e))in n?[e]:e.match(L)||[]).length;for(;i--;)delete n[e[i]]}(void 0===e||C.isEmptyObject(n))&&(t.nodeType?t[this.expando]=void 0:delete t[this.expando])}},hasData:function(t){var e=t[this.expando];return void 0!==e&&!C.isEmptyObject(e)}};var Y=new G,X=new G,Q=/^(?:\{[\w\W]*\}|\[[\w\W]*\])$/,J=/[A-Z]/g;function Z(t,e,i){var n,r;if(void 0===i&&1===t.nodeType)if(n="data-"+e.replace(J,"-$&").toLowerCase(),"string"==typeof(i=t.getAttribute(n))){try{i="true"===(r=i)||"false"!==r&&("null"===r?null:r===+r+""?+r:Q.test(r)?JSON.parse(r):r)}catch(t){}X.set(t,e,i)}else i=void 0;return i}C.extend({hasData:function(t){return X.hasData(t)||Y.hasData(t)},data:function(t,e,i){return X.access(t,e,i)},removeData:function(t,e){X.remove(t,e)},_data:function(t,e,i){return Y.access(t,e,i)},_removeData:function(t,e){Y.remove(t,e)}}),C.fn.extend({data:function(i,t){var e,n,r,s=this[0],o=s&&s.attributes;if(void 0!==i)return"object"==typeof i?this.each(function(){X.set(this,i)}):H(this,function(t){var e;if(s&&void 0===t)return void 0!==(e=X.get(s,i))?e:void 0!==(e=Z(s,i))?e:void 0;this.each(function(){X.set(this,i,t)})},null,t,1<arguments.length,null,!0);if(this.length&&(r=X.get(s),1===s.nodeType&&!Y.get(s,"hasDataAttrs"))){for(e=o.length;e--;)o[e]&&0===(n=o[e].name).indexOf("data-")&&(n=W(n.slice(5)),Z(s,n,r[n]));Y.set(s,"hasDataAttrs",!0)}return r},removeData:function(t){return this.each(function(){X.remove(this,t)})}}),C.extend({queue:function(t,e,i){var n;if(t)return e=(e||"fx")+"queue",n=Y.get(t,e),i&&(!n||Array.isArray(i)?n=Y.access(t,e,C.makeArray(i)):n.push(i)),n||[]},dequeue:function(t,e){e=e||"fx";var i=C.queue(t,e),n=i.length,r=i.shift(),s=C._queueHooks(t,e);"inprogress"===r&&(r=i.shift(),n--),r&&("fx"===e&&i.unshift("inprogress"),delete s.stop,r.call(t,function(){C.dequeue(t,e)},s)),!n&&s&&s.empty.fire()},_queueHooks:function(t,e){var i=e+"queueHooks";return Y.get(t,i)||Y.access(t,i,{empty:C.Callbacks("once memory").add(function(){Y.remove(t,[e+"queue",i])})})}}),C.fn.extend({queue:function(e,i){var t=2;return"string"!=typeof e&&(i=e,e="fx",t--),arguments.length<t?C.queue(this[0],e):void 0===i?this:this.each(function(){var t=C.queue(this,e,i);C._queueHooks(this,e),"fx"===e&&"inprogress"!==t[0]&&C.dequeue(this,e)})},dequeue:function(t){return this.each(function(){C.dequeue(this,t)})},clearQueue:function(t){return this.queue(t||"fx",[])},promise:function(t,e){var i,n=1,r=C.Deferred(),s=this,o=this.length,a=function(){--n||r.resolveWith(s,[s])};for("string"!=typeof t&&(e=t,t=void 0),t=t||"fx";o--;)(i=Y.get(s[o],t+"queueHooks"))&&i.empty&&(n++,i.empty.add(a));return a(),r.promise(e)}});var tt=/[+-]?(?:\d*\.|)\d+(?:[eE][+-]?\d+|)/.source,et=new RegExp("^(?:([+-])=|)("+tt+")([a-z%]*)$","i"),it=["Top","Right","Bottom","Left"],nt=S.documentElement,rt=function(t){return C.contains(t.ownerDocument,t)},st={composed:!0};nt.getRootNode&&(rt=function(t){return C.contains(t.ownerDocument,t)||t.getRootNode(st)===t.ownerDocument});var ot=function(t,e){return"none"===(t=e||t).style.display||""===t.style.display&&rt(t)&&"none"===C.css(t,"display")};function at(t,e,i,n){var r,s,o=20,a=n?function(){return n.cur()}:function(){return C.css(t,e,"")},l=a(),u=i&&i[3]||(C.cssNumber[e]?"":"px"),c=t.nodeType&&(C.cssNumber[e]||"px"!==u&&+l)&&et.exec(C.css(t,e));if(c&&c[3]!==u){for(l/=2,u=u||c[3],c=+l||1;o--;)C.style(t,e,c+u),(1-s)*(1-(s=a()/l||.5))<=0&&(o=0),c/=s;c*=2,C.style(t,e,c+u),i=i||[]}return i&&(c=+c||+l||0,r=i[1]?c+(i[1]+1)*i[2]:+i[2],n&&(n.unit=u,n.start=c,n.end=r)),r}var lt={};function ut(t,e){for(var i,n,r,s,o,a,l,u=[],c=0,h=t.length;c<h;c++)(n=t[c]).style&&(i=n.style.display,e?("none"===i&&(u[c]=Y.get(n,"display")||null,u[c]||(n.style.display="")),""===n.style.display&&ot(n)&&(u[c]=(l=o=s=void 0,o=(r=n).ownerDocument,a=r.nodeName,(l=lt[a])||(s=o.body.appendChild(o.createElement(a)),l=C.css(s,"display"),s.parentNode.removeChild(s),"none"===l&&(l="block"),lt[a]=l)))):"none"!==i&&(u[c]="none",Y.set(n,"display",i)));for(c=0;c<h;c++)null!=u[c]&&(t[c].style.display=u[c]);return t}C.fn.extend({show:function(){return ut(this,!0)},hide:function(){return ut(this)},toggle:function(t){return"boolean"==typeof t?t?this.show():this.hide():this.each(function(){ot(this)?C(this).show():C(this).hide()})}});var ct,ht,dt=/^(?:checkbox|radio)$/i,pt=/<([a-z][^\/\0>\x20\t\r\n\f]*)/i,ft=/^$|^module$|\/(?:java|ecma)script/i;ct=S.createDocumentFragment().appendChild(S.createElement("div")),(ht=S.createElement("input")).setAttribute("type","radio"),ht.setAttribute("checked","checked"),ht.setAttribute("name","t"),ct.appendChild(ht),v.checkClone=ct.cloneNode(!0).cloneNode(!0).lastChild.checked,ct.innerHTML="<textarea>x</textarea>",v.noCloneChecked=!!ct.cloneNode(!0).lastChild.defaultValue,ct.innerHTML="<option></option>",v.option=!!ct.lastChild;var gt={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 mt(t,e){var i;return i=void 0!==t.getElementsByTagName?t.getElementsByTagName(e||"*"):void 0!==t.querySelectorAll?t.querySelectorAll(e||"*"):[],void 0===e||e&&k(t,e)?C.merge([t],i):i}function vt(t,e){for(var i=0,n=t.length;i<n;i++)Y.set(t[i],"globalEval",!e||Y.get(e[i],"globalEval"))}gt.tbody=gt.tfoot=gt.colgroup=gt.caption=gt.thead,gt.th=gt.td,v.option||(gt.optgroup=gt.option=[1,"<select multiple='multiple'>","</select>"]);var yt=/<|&#?\w+;/;function bt(t,e,i,n,r){for(var s,o,a,l,u,c,h=e.createDocumentFragment(),d=[],p=0,f=t.length;p<f;p++)if((s=t[p])||0===s)if("object"===_(s))C.merge(d,s.nodeType?[s]:s);else if(yt.test(s)){for(o=o||h.appendChild(e.createElement("div")),a=(pt.exec(s)||["",""])[1].toLowerCase(),l=gt[a]||gt._default,o.innerHTML=l[1]+C.htmlPrefilter(s)+l[2],c=l[0];c--;)o=o.lastChild;C.merge(d,o.childNodes),(o=h.firstChild).textContent=""}else d.push(e.createTextNode(s));for(h.textContent="",p=0;s=d[p++];)if(n&&-1<C.inArray(s,n))r&&r.push(s);else if(u=rt(s),o=mt(h.appendChild(s),"script"),u&&vt(o),i)for(c=0;s=o[c++];)ft.test(s.type||"")&&i.push(s);return h}var wt=/^key/,_t=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,xt=/^([^.]*)(?:\.(.+)|)/;function Tt(){return!0}function St(){return!1}function Ct(t,e){return t===function(){try{return S.activeElement}catch(t){}}()==("focus"===e)}function Et(t,e,i,n,r,s){var o,a;if("object"==typeof e){for(a in"string"!=typeof i&&(n=n||i,i=void 0),e)Et(t,a,i,n,e[a],s);return t}if(null==n&&null==r?(r=i,n=i=void 0):null==r&&("string"==typeof i?(r=n,n=void 0):(r=n,n=i,i=void 0)),!1===r)r=St;else if(!r)return t;return 1===s&&(o=r,(r=function(t){return C().off(t),o.apply(this,arguments)}).guid=o.guid||(o.guid=C.guid++)),t.each(function(){C.event.add(this,e,r,n,i)})}function kt(t,r,s){s?(Y.set(t,r,!1),C.event.add(t,r,{namespace:!1,handler:function(t){var e,i,n=Y.get(this,r);if(1&t.isTrigger&&this[r]){if(n.length)(C.event.special[r]||{}).delegateType&&t.stopPropagation();else if(n=a.call(arguments),Y.set(this,r,n),e=s(this,r),this[r](),n!==(i=Y.get(this,r))||e?Y.set(this,r,!1):i={},n!==i)return t.stopImmediatePropagation(),t.preventDefault(),i.value}else n.length&&(Y.set(this,r,{value:C.event.trigger(C.extend(n[0],C.Event.prototype),n.slice(1),this)}),t.stopImmediatePropagation())}})):void 0===Y.get(t,r)&&C.event.add(t,r,Tt)}C.event={global:{},add:function(e,t,i,n,r){var s,o,a,l,u,c,h,d,p,f,g,m=Y.get(e);if(K(e))for(i.handler&&(i=(s=i).handler,r=s.selector),r&&C.find.matchesSelector(nt,r),i.guid||(i.guid=C.guid++),(l=m.events)||(l=m.events=Object.create(null)),(o=m.handle)||(o=m.handle=function(t){return void 0!==C&&C.event.triggered!==t.type?C.event.dispatch.apply(e,arguments):void 0}),u=(t=(t||"").match(L)||[""]).length;u--;)p=g=(a=xt.exec(t[u])||[])[1],f=(a[2]||"").split(".").sort(),p&&(h=C.event.special[p]||{},p=(r?h.delegateType:h.bindType)||p,h=C.event.special[p]||{},c=C.extend({type:p,origType:g,data:n,handler:i,guid:i.guid,selector:r,needsContext:r&&C.expr.match.needsContext.test(r),namespace:f.join(".")},s),(d=l[p])||((d=l[p]=[]).delegateCount=0,h.setup&&!1!==h.setup.call(e,n,f,o)||e.addEventListener&&e.addEventListener(p,o)),h.add&&(h.add.call(e,c),c.handler.guid||(c.handler.guid=i.guid)),r?d.splice(d.delegateCount++,0,c):d.push(c),C.event.global[p]=!0)},remove:function(t,e,i,n,r){var s,o,a,l,u,c,h,d,p,f,g,m=Y.hasData(t)&&Y.get(t);if(m&&(l=m.events)){for(u=(e=(e||"").match(L)||[""]).length;u--;)if(p=g=(a=xt.exec(e[u])||[])[1],f=(a[2]||"").split(".").sort(),p){for(h=C.event.special[p]||{},d=l[p=(n?h.delegateType:h.bindType)||p]||[],a=a[2]&&new RegExp("(^|\\.)"+f.join("\\.(?:.*\\.|)")+"(\\.|$)"),o=s=d.length;s--;)c=d[s],!r&&g!==c.origType||i&&i.guid!==c.guid||a&&!a.test(c.namespace)||n&&n!==c.selector&&("**"!==n||!c.selector)||(d.splice(s,1),c.selector&&d.delegateCount--,h.remove&&h.remove.call(t,c));o&&!d.length&&(h.teardown&&!1!==h.teardown.call(t,f,m.handle)||C.removeEvent(t,p,m.handle),delete l[p])}else for(p in l)C.event.remove(t,p+e[u],i,n,!0);C.isEmptyObject(l)&&Y.remove(t,"handle events")}},dispatch:function(t){var e,i,n,r,s,o,a=new Array(arguments.length),l=C.event.fix(t),u=(Y.get(this,"events")||Object.create(null))[l.type]||[],c=C.event.special[l.type]||{};for(a[0]=l,e=1;e<arguments.length;e++)a[e]=arguments[e];if(l.delegateTarget=this,!c.preDispatch||!1!==c.preDispatch.call(this,l)){for(o=C.event.handlers.call(this,l,u),e=0;(r=o[e++])&&!l.isPropagationStopped();)for(l.currentTarget=r.elem,i=0;(s=r.handlers[i++])&&!l.isImmediatePropagationStopped();)l.rnamespace&&!1!==s.namespace&&!l.rnamespace.test(s.namespace)||(l.handleObj=s,l.data=s.data,void 0!==(n=((C.event.special[s.origType]||{}).handle||s.handler).apply(r.elem,a))&&!1===(l.result=n)&&(l.preventDefault(),l.stopPropagation()));return c.postDispatch&&c.postDispatch.call(this,l),l.result}},handlers:function(t,e){var i,n,r,s,o,a=[],l=e.delegateCount,u=t.target;if(l&&u.nodeType&&!("click"===t.type&&1<=t.button))for(;u!==this;u=u.parentNode||this)if(1===u.nodeType&&("click"!==t.type||!0!==u.disabled)){for(s=[],o={},i=0;i<l;
vendor: 2,895 bytes, line 1
1i++)void 0===o[r=(n=e[i]).selector+" "]&&(o[r]=n.needsContext?-1<C(r,this).index(u):C.find(r,this,null,[u]).length),o[r]&&s.push(n);s.length&&a.push({elem:u,handlers:s})}return u=this,l<e.length&&a.push({elem:u,handlers:e.slice(l)}),a},addProp:function(e,t){Object.defineProperty(C.Event.prototype,e,{enumerable:!0,configurable:!0,get:y(t)?function(){if(this.originalEvent)return t(this.originalEvent)}:function(){if(this.originalEvent)return this.originalEvent[e]},set:function(t){Object.defineProperty(this,e,{enumerable:!0,configurable:!0,writable:!0,value:t})}})},fix:function(t){return t[C.expando]?t:new C.Event(t)},special:{load:{noBubble:!0},click:{setup:function(t){var e=this||t;return dt.test(e.type)&&e.click&&k(e,"input")&&kt(e,"click",Tt),!1},trigger:function(t){var e=this||t;return dt.test(e.type)&&e.click&&k(e,"input")&&kt(e,"click"),!0},_default:function(t){var e=t.target;return dt.test(e.type)&&e.click&&k(e,"input")&&Y.get(e,"click")||k(e,"a")}},beforeunload:{postDispatch:function(t){void 0!==t.result&&t.originalEvent&&(t.originalEvent.returnValue=t.result)}}}},C.removeEvent=function(t,e,i){t.removeEventListener&&t.removeEventListener(e,i)},C.Event=function(t,e){if(!(this instanceof C.Event))return new C.Event(t,e);t&&t.type?(this.originalEvent=t,this.type=t.type,this.isDefaultPrevented=t.defaultPrevented||void 0===t.defaultPrevented&&!1===t.returnValue?Tt:St,this.target=t.target&&3===t.target.nodeType?t.target.parentNode:t.target,this.currentTarget=t.currentTarget,this.relatedTarget=t.relatedTarget):this.type=t,e&&C.extend(this,e),this.timeStamp=t&&t.timeStamp||Date.now(),this[C.expando]=!0},C.Event.prototype={constructor:C.Event,isDefaultPrevented:St,isPropagationStopped:St,isImmediatePropagationStopped:St,isSimulated:!1,preventDefault:function(){var t=this.originalEvent;this.isDefaultPrevented=Tt,t&&!this.isSimulated&&t.preventDefault()},stopPropagation:function(){var t=this.originalEvent;this.isPropagationStopped=Tt,t&&!this.isSimulated&&t.stopPropagation()},stopImmediatePropagation:function(){var t=this.originalEvent;this.isImmediatePropagationStopped=Tt,t&&!this.isSimulated&&t.stopImmediatePropagation(),this.stopPropagation()}},C.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(t){var e=t.button;return null==t.which&&wt.test(t.type)?null!=t.charCode?t.charCode:t.keyCode:!t.which&&void 0!==e&&_t.test(t.type)?1&e?1:2&e?3:4&e?2:0:t.which}},C.event.addProp),C.each({focus:"focusin",blur:"focusout"},function(t,e){C.event.special[t]={setup:function(){return kt(this,t,Ct),!1},trigger:function(){return kt(this,t),!0},delegateType:e}}
vendor: 4,527 bytes, line 1
1),C.each({mouseenter:"mouseover",mouseleave:"mouseout",pointerenter:"pointerover",pointerleave:"pointerout"},function(t,r){C.event.special[t]={delegateType:r,bindType:r,handle:function(t){var e,i=t.relatedTarget,n=t.handleObj;return i&&(i===this||C.contains(this,i))||(t.type=n.origType,e=n.handler.apply(this,arguments),t.type=r),e}}}),C.fn.extend({on:function(t,e,i,n){return Et(this,t,e,i,n)},one:function(t,e,i,n){return Et(this,t,e,i,n,1)},off:function(t,e,i){var n,r;if(t&&t.preventDefault&&t.handleObj)return n=t.handleObj,C(t.delegateTarget).off(n.namespace?n.origType+"."+n.namespace:n.origType,n.selector,n.handler),this;if("object"!=typeof t)return!1!==e&&"function"!=typeof e||(i=e,e=void 0),!1===i&&(i=St),this.each(function(){C.event.remove(this,t,i,e)});for(r in t)this.off(r,e,t[r]);return this}});var It=/<script|<style|<link/i,Dt=/checked\s*(?:[^=]|=\s*.checked.)/i,At=/^\s*<!(?:\[CDATA\[|--)|(?:\]\]|--)>\s*$/g;function Pt(t,e){return k(t,"table")&&k(11!==e.nodeType?e:e.firstChild,"tr")&&C(t).children("tbody")[0]||t}function Mt(t){return t.type=(null!==t.getAttribute("type"))+"/"+t.type,t}function Nt(t){return"true/"===(t.type||"").slice(0,5)?t.type=t.type.slice(5):t.removeAttribute("type"),t}function Ot(t,e){var i,n,r,s,o,a;if(1===e.nodeType){if(Y.hasData(t)&&(a=Y.get(t).events))for(r in Y.remove(e,"handle events"),a)for(i=0,n=a[r].length;i<n;i++)C.event.add(e,r,a[r][i]);X.hasData(t)&&(s=X.access(t),o=C.extend({},s),X.set(e,o))}}function Lt(i,n,r,s){n=g(n);var t,e,o,a,l,u,c=0,h=i.length,d=h-1,p=n[0],f=y(p);if(f||1<h&&"string"==typeof p&&!v.checkClone&&Dt.test(p))return i.each(function(t){var e=i.eq(t);f&&(n[0]=p.call(this,t,e.html())),Lt(e,n,r,s)});if(h&&(e=(t=bt(n,i[0].ownerDocument,!1,i,s)).firstChild,1===t.childNodes.length&&(t=e),e||s)){for(a=(o=C.map(mt(t,"script"),Mt)).length;c<h;c++)l=t,c!==d&&(l=C.clone(l,!0,!0),a&&C.merge(o,mt(l,"script"))),r.call(i[c],l,c);if(a)for(u=o[o.length-1].ownerDocument,C.map(o,Nt),c=0;c<a;c++)l=o[c],ft.test(l.type||"")&&!Y.access(l,"globalEval")&&C.contains(u,l)&&(l.src&&"module"!==(l.type||"").toLowerCase()?C._evalUrl&&!l.noModule&&C._evalUrl(l.src,{nonce:l.nonce||l.getAttribute("nonce")},u):w(l.textContent.replace(At,""),l,u))}return i}function Rt(t,e,i){for(var n,r=e?C.filter(e,t):t,s=0;null!=(n=r[s]);s++)i||1!==n.nodeType||C.cleanData(mt(n)),n.parentNode&&(i&&rt(n)&&vt(mt(n,"script")),n.parentNode.removeChild(n));return t}C.extend({htmlPrefilter:function(t){return t},clone:function(t,e,i){var n,r,s,o,a,l,u,c=t.cloneNode(!0),h=rt(t);if(!(v.noCloneChecked||1!==t.nodeType&&11!==t.nodeType||C.isXMLDoc(t)))for(o=mt(c),n=0,r=(s=mt(t)).length;n<r;n++)a=s[n],"input"===(u=(l=o[n]).nodeName.toLowerCase())&&dt.test(a.type)?l.checked=a.checked:"input"!==u&&"textarea"!==u||(l.defaultValue=a.defaultValue);if(e)if(i)for(s=s||mt(t),o=o||mt(c),n=0,r=s.length;n<r;n++)Ot(s[n],o[n]);else Ot(t,c);return 0<(o=mt(c,"script")).length&&vt(o,!h&&mt(t,"script")),c},cleanData:function(t){for(var e,i,n,r=C.event.special,s=0;void 0!==(i=t[s]);s++)if(K(i)){if(e=i[Y.expando]){if(e.events)for(n in e.events)r[n]?C.event.remove(i,n):C.removeEvent(i,n,e.handle);i[Y.expando]=void 0}i[X.expando]&&(i[X.expando]=void 0)}}}),C.fn.extend({detach:function(t){return Rt(this,t,!0)},remove:function(t){return Rt(this,t)},text:function(t){return H(this,function(t){return void 0===t?C.text(this):this.empty().each(function(){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||(this.textContent=t)})},null,t,arguments.length)},append:function(){return Lt(this,arguments,function(t){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||Pt(this,t).appendChild(t)})},prepend:function(){return Lt(this,arguments,function(t){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var e=Pt(this,t);e.insertBefore(t,e.firstChild)}})},before:function(){return Lt(this,arguments,function(t){this.parentNode&&this.parentNode.insertBefore(t,this)})},after:function(){return Lt(this,arguments,function(t){this.parentNode&&this.parentNode.insertBefore(t,this.nextSibling)})},empty:function(){for(var t,e=0;null!=(t=this[e]);e++)1===t.nodeType&&(C.cleanData(mt(t,!1)),t.textContent="");return this},clone:function(t,e){return t=null!=t&&t,e=null==e?t:e,this.map(function(){return C.clone(this,t,e)})},html:function(t){return H(this,function(t){var e=this[0]||{},i=0,n=this.length;if(void 0===t&&1===e.nodeType)return e.innerHTML;if("string"==typeof t&&!It.test(t)&&!gt[(pt.exec(t)||["",""])[1].toLowerCase()]){t=C.htmlPrefilter(t);try{for(;i<n;i++)1===(e=this[i]||{}
vendor: 2,432 bytes, line 1
1).nodeType&&(C.cleanData(mt(e,!1)),e.innerHTML=t);e=0}catch(t){}}e&&this.empty().append(t)},null,t,arguments.length)},replaceWith:function(){var i=[];return Lt(this,arguments,function(t){var e=this.parentNode;C.inArray(this,i)<0&&(C.cleanData(mt(this)),e&&e.replaceChild(t,this))},i)}}),C.each({appendTo:"append",prependTo:"prepend",insertBefore:"before",insertAfter:"after",replaceAll:"replaceWith"},function(t,o){C.fn[t]=function(t){for(var e,i=[],n=C(t),r=n.length-1,s=0;s<=r;s++)e=s===r?this:this.clone(!0),C(n[s])[o](e),l.apply(i,e.get());return this.pushStack(i)}});var Ft=new RegExp("^("+tt+")(?!px)[a-z%]+$","i"),zt=function(t){var e=t.ownerDocument.defaultView;return e&&e.opener||(e=T),e.getComputedStyle(t)},Bt=function(t,e,i){var n,r,s={};for(r in e)s[r]=t.style[r],t.style[r]=e[r];for(r in n=i.call(t),e)t.style[r]=s[r];return n},$t=new RegExp(it.join("|"),"i");function jt(t,e,i){var n,r,s,o,a=t.style;return(i=i||zt(t))&&(""!==(o=i.getPropertyValue(e)||i[e])||rt(t)||(o=C.style(t,e)),!v.pixelBoxStyles()&&Ft.test(o)&&$t.test(e)&&(n=a.width,r=a.minWidth,s=a.maxWidth,a.minWidth=a.maxWidth=a.width=o,o=i.width,a.width=n,a.minWidth=r,a.maxWidth=s)),void 0!==o?o+"":o}function Ht(t,e){return{get:function(){if(!t())return(this.get=e).apply(this,arguments);delete this.get}}}!function(){function t(){if(u){l.style.cssText="position:absolute;left:-11111px;width:60px;margin-top:1px;padding:0;border:0",u.style.cssText="position:relative;display:block;box-sizing:border-box;overflow:scroll;margin:auto;border:1px;padding:1px;width:60%;top:1%",nt.appendChild(l).appendChild(u);var t=T.getComputedStyle(u);i="1%"!==t.top,a=12===e(t.marginLeft),u.style.right="60%",s=36===e(t.right),n=36===e(t.width),u.style.position="absolute",r=12===e(u.offsetWidth/3),nt.removeChild(l),u=null}}function e(t){return Math.round(parseFloat(t))}var i,n,r,s,o,a,l=S.createElement("div"),u=S.createElement("div");u.style&&(u.style.backgroundClip="content-box",u.cloneNode(!0).style.backgroundClip="",v.clearCloneStyle="content-box"===u.style.backgroundClip,C.extend(v,{boxSizingReliable:function(){return t(),n},pixelBoxStyles:function(){return t(),s},pixelPosition:function(){return t(),i},reliableMarginLeft:function(){return t(),a},scrollboxSize:function(){return t(),r},reliableTrDimensions:function(){var t,e,i,n;return null==o&&(t=S.createElement("table"),e=S.createElement("tr"),i=S.createElement("div"),t.style.cssText="position:absolute;
1left:-11111px",e.style.height="1px",i.style.height="9px",nt.appendChild(t).appendChild(e).appendChild(i),n=T.getComputedStyle(e),o=3<parseInt(n.height),nt.removeChild(t)),o}}))}();var qt=["Webkit","Moz","ms"],Vt=S.createElement("div").style,Ut={};function Wt(t){return C.cssProps[t]||Ut[t]||(t in Vt?t:Ut[t]=function(t){for(var e=t[0].toUpperCase()+t.slice(1),i=qt.length;i--;)if((t=qt[i]+e)in Vt)return t}(t)||t)}var Kt=/^(none|table(?!-c[ea]).+)/,Gt=/^--/,Yt={position:"absolute",visibility:"hidden",display:"block"},Xt={letterSpacing:"0",fontWeight:"400"};function Qt(t,e,i){var n=et.exec(e);return n?Math.max(0,n[2]-(i||0))+(n[3]||"px"):e}function Jt(t,e,i,n,r,s){var o="width"===e?1:0,a=0,l=0;if(i===(n?"border":"content"))return 0;for(;o<4;o+=2)"margin"===i&&(l+=C.css(t,i+it[o],!0,r)),n?("content"===i&&(l-=C.css(t,"padding"+it[o],!0,r)),"margin"!==i&&(l-=C.css(t,"border"+it[o]+"Width",!0,r))):(l+=C.css(t,"padding"+it[o],!0,r),"padding"!==i?l+=C.css(t,"border"+it[o]+"Width",!0,r):a+=C.css(t,"border"+it[o]+"Width",!0,r));return!n&&0<=s&&(l+=Math.max(0,Math.ceil(t["offset"+e[0].toUpperCase()+e.slice(1)]-s-l-a-.5))||0),l}function Zt(t,e,i){var n=zt(t),r=(!v.boxSizingReliable()||i)&&"border-box"===C.css(t,"boxSizing",!1,n),s=r,o=jt(t,e,n),a="offset"+e[0].toUpperCase()+e.slice(1);if(Ft.test(o)){if(!i)return o;o="auto"}return(!v.boxSizingReliable()&&r||!v.reliableTrDimensions()&&k(t,"tr")||"auto"===o||!parseFloat(o)&&"inline"===C.css(t,"display",!1,n))&&t.getClientRects().length&&(r="border-box"===C.css(t,"boxSizing",!1,n),(s=a in t)&&(o=t[a])),(o=parseFloat(o)||0)+Jt(t,e,i||(r?"border":"content"),s,n,o)+"px"}function te(t,e,i,n,r){return new te.prototype.init(t,e,i,n,r)}C.extend({cssHooks:{opacity:{get:function(t,e){if(e){var i=jt(t,"opacity");return""===i?"1":i}}}},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(t,e,i,n){if(t&&3!==t.nodeType&&8!==t.nodeType&&t.style){var r,s,o,a=W(e),l=Gt.test(e),u=t.style;if(l||(e=Wt(a)),o=C.cssHooks[e]||C.cssHooks[a],void 0===i)return o&&"get"in o&&void 0!==(r=o.get(t,!1,n))?r:u[e];"string"==(s=typeof i)&&(r=et.exec(i))&&r[1]&&(i=at(t,e,r),s="number"),null!=i&&i==i&&("number"!==s||l||(i+=r&&r[3]||(C.cssNumber[a]?"":"px")),v.clearCloneStyle||""!==i||0!==e.indexOf("background")||(u[e]="inherit"),o&&"set"in o&&void 0===(i=o.set(t,i,n))||(l?u.setProperty(e,i):u[e]=i))}},css:function(t,e,i,n){var r,s,o,a=W(e);return Gt.test(e)||(e=Wt(a)),(o=C.cssHooks[e]||C.cssHooks[a])&&"get"in o&&(r=o.get(t,!0,i)),void 0===r&&(r=jt(t,e,n)),"normal"===r&&e in Xt&&(r=Xt[e]),""===i||i?(s=parseFloat(r),!0===i||isFinite(s)?s||0:r):r}}),C.each(["height","width"],function(t,l){C.cssHooks[l]={get:function(t,e,i){if(e)return!Kt.test(C.css(t,"display"))||t.getClientRects().length&&t.getBoundingClientRect().width?Zt(t,l,i):Bt(t,Yt,function(){return Zt(t,l,i)})},set:function(t,e,i){var n,r=zt(t),s=!v.scrollboxSize()&&"absolute"===r.position,o=(s||i)&&"border-box"===C.css(t,"boxSizing",!1,r),a=i?Jt(t,l,i,o,r):0;return o&&s&&(a-=Math.ceil(t["offset"+l[0].toUpperCase()+l.slice(1)]-parseFloat(r[l])-Jt(t,l,"border",!1,r)-.5)),a&&(n=et.exec(e))&&"px"!==(n[3]||"px")&&(t.style[l]=e,e=C.css(t,l)),Qt(0,e,a)}}}),C.cssHooks.marginLeft=Ht(v.reliableMarginLeft,function(t,e){if(e)return(parseFloat(jt(t,"marginLeft"))||t.getBoundingClientRect().left-Bt(t,{marginLeft:0},function(){return t.getBoundingClientRect().left}))+"px"}),C.each({margin:"",padding:"",border:"Width"},function(r,s){C.cssHooks[r+s]={expand:function(t){for(var e=0,i={},n="string"==typeof t?t.split(" "):[t];e<4;e++)i[r+it[e]+s]=n[e]||n[e-2]||n[0];return i}},"margin"!==r&&(C.cssHooks[r+s].set=Qt)}),C.fn.extend({css:function(t,e){return H(this,function(t,e,i){var n,r,s={},o=0;if(Array.isArray(e)){for(n=zt(t),r=e.length;o<r;o++)s[e[o]]=C.css(t,e[o],!1,n);return s}return void 0!==i?C.style(t,e,i):C.css(t,e)},t,e,1<arguments.length)}}
vendor: 22,552 bytes, line 1
1),((C.Tween=te).prototype={constructor:te,init:function(t,e,i,n,r,s){this.elem=t,this.prop=i,this.easing=r||C.easing._default,this.options=e,this.start=this.now=this.cur(),this.end=n,this.unit=s||(C.cssNumber[i]?"":"px")},cur:function(){var t=te.propHooks[this.prop];return t&&t.get?t.get(this):te.propHooks._default.get(this)},run:function(t){var e,i=te.propHooks[this.prop];return this.options.duration?this.pos=e=C.easing[this.easing](t,this.options.duration*t,0,1,this.options.duration):this.pos=e=t,this.now=(this.end-this.start)*e+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),i&&i.set?i.set(this):te.propHooks._default.set(this),this}}).init.prototype=te.prototype,(te.propHooks={_default:{get:function(t){var e;return 1!==t.elem.nodeType||null!=t.elem[t.prop]&&null==t.elem.style[t.prop]?t.elem[t.prop]:(e=C.css(t.elem,t.prop,""))&&"auto"!==e?e:0},set:function(t){C.fx.step[t.prop]?C.fx.step[t.prop](t):1!==t.elem.nodeType||!C.cssHooks[t.prop]&&null==t.elem.style[Wt(t.prop)]?t.elem[t.prop]=t.now:C.style(t.elem,t.prop,t.now+t.unit)}}}).scrollTop=te.propHooks.scrollLeft={set:function(t){t.elem.nodeType&&t.elem.parentNode&&(t.elem[t.prop]=t.now)}},C.easing={linear:function(t){return t},swing:function(t){return.5-Math.cos(t*Math.PI)/2},_default:"swing"},C.fx=te.prototype.init,C.fx.step={};var ee,ie,ne,re,se=/^(?:toggle|show|hide)$/,oe=/queueHooks$/;function ae(){ie&&(!1===S.hidden&&T.requestAnimationFrame?T.requestAnimationFrame(ae):T.setTimeout(ae,C.fx.interval),C.fx.tick())}function le(){return T.setTimeout(function(){ee=void 0}),ee=Date.now()}function ue(t,e){var i,n=0,r={height:t};for(e=e?1:0;n<4;n+=2-e)r["margin"+(i=it[n])]=r["padding"+i]=t;return e&&(r.opacity=r.width=t),r}function ce(t,e,i){for(var n,r=(he.tweeners[e]||[]).concat(he.tweeners["*"]),s=0,o=r.length;s<o;s++)if(n=r[s].call(i,e,t))return n}function he(s,t,e){var i,o,n=0,r=he.prefilters.length,a=C.Deferred().always(function(){delete l.elem}),l=function(){if(o)return!1;for(var t=ee||le(),e=Math.max(0,u.startTime+u.duration-t),i=1-(e/u.duration||0),n=0,r=u.tweens.length;n<r;n++)u.tweens[n].run(i);return a.notifyWith(s,[u,i,e]),i<1&&r?e:(r||a.notifyWith(s,[u,1,0]),a.resolveWith(s,[u]),!1)},u=a.promise({elem:s,props:C.extend({},t),opts:C.extend(!0,{specialEasing:{},easing:C.easing._default},e),originalProperties:t,originalOptions:e,startTime:ee||le(),duration:e.duration,tweens:[],createTween:function(t,e){var i=C.Tween(s,u.opts,t,e,u.opts.specialEasing[t]||u.opts.easing);return u.tweens.push(i),i},stop:function(t){var e=0,i=t?u.tweens.length:0;if(o)return this;for(o=!0;e<i;e++)u.tweens[e].run(1);return t?(a.notifyWith(s,[u,1,0]),a.resolveWith(s,[u,t])):a.rejectWith(s,[u,t]),this}}),c=u.props;for(function(t,e){var i,n,r,s,o;for(i in t)if(r=e[n=W(i)],s=t[i],Array.isArray(s)&&(r=s[1],s=t[i]=s[0]),i!==n&&(t[n]=s,delete t[i]),(o=C.cssHooks[n])&&"expand"in o)for(i in s=o.expand(s),delete t[n],s)i in t||(t[i]=s[i],e[i]=r);else e[n]=r}(c,u.opts.specialEasing);n<r;n++)if(i=he.prefilters[n].call(u,s,c,u.opts))return y(i.stop)&&(C._queueHooks(u.elem,u.opts.queue).stop=i.stop.bind(i)),i;return C.map(c,ce,u),y(u.opts.start)&&u.opts.start.call(s,u),u.progress(u.opts.progress).done(u.opts.done,u.opts.complete).fail(u.opts.fail).always(u.opts.always),C.fx.timer(C.extend(l,{elem:s,anim:u,queue:u.opts.queue})),u}C.Animation=C.extend(he,{tweeners:{"*":[function(t,e){var i=this.createTween(t,e);return at(i.elem,t,et.exec(e),i),i}]},tweener:function(t,e){for(var i,n=0,r=(t=y(t)?(e=t,["*"]):t.match(L)).length;n<r;n++)i=t[n],he.tweeners[i]=he.tweeners[i]||[],he.tweeners[i].unshift(e)},prefilters:[function(t,e,i){var n,r,s,o,a,l,u,c,h="width"in e||"height"in e,d=this,p={},f=t.style,g=t.nodeType&&ot(t),m=Y.get(t,"fxshow");for(n in i.queue||(null==(o=C._queueHooks(t,"fx")).unqueued&&(o.unqueued=0,a=o.empty.fire,o.empty.fire=function(){o.unqueued||a()}),o.unqueued++,d.always(function(){d.always(function(){o.unqueued--,C.queue(t,"fx").length||o.empty.fire()})})),e)if(r=e[n],se.test(r)){if(delete e[n],s=s||"toggle"===r,r===(g?"hide":"show")){if("show"!==r||!m||void 0===m[n])continue;g=!0}p[n]=m&&m[n]||C.style(t,n)}if((l=!C.isEmptyObject(e))||!C.isEmptyObject(p))for(n in h&&1===t.nodeType&&(i.overflow=[f.overflow,f.overflowX,f.overflowY],null==(u=m&&m.display)&&(u=Y.get(t,"display")),"none"===(c=C.css(t,"display"))&&(u?c=u:(ut([t],!0),u=t.style.display||u,c=C.css(t,"display"),ut([t]))),("inline"===c||"inline-block"===c&&null!=u)&&"none"===C.css(t,"float")&&(l||(d.done(function(){f.display=u}),null==u&&(c=f.display,u="none"===c?"":c)),f.display="inline-block")),i.overflow&&(f.overflow="hidden",d.always(function(){f.overflow=i.overflow[0],f.overflowX=i.overflow[1],f.overflowY=i.overflow[2]})),l=!1,p)l||(m?"hidden"in m&&(g=m.hidden):m=Y.access(t,"fxshow",{display:u}),s&&(m.hidden=!g),g&&ut([t],!0),d.done(function(){for(n in g||ut([t]),Y.remove(t,"fxshow"),p)C.style(t,n,p[n])})),l=ce(g?m[n]:0,n,d),n in m||(m[n]=l.start,g&&(l.end=l.start,l.start=0))}],prefilter:function(t,e){e?he.prefilters.unshift(t):he.prefilters.push(t)}}),C.speed=function(t,e,i){var n=t&&"object"==typeof t?C.extend({},t):{complete:i||!i&&e||y(t)&&t,duration:t,easing:i&&e||e&&!y(e)&&e};return C.fx.off?n.duration=0:"number"!=typeof n.duration&&(n.duration in C.fx.speeds?n.duration=C.fx.speeds[n.duration]:n.duration=C.fx.speeds._default),null!=n.queue&&!0!==n.queue||(n.queue="fx"),n.old=n.complete,n.complete=function(){y(n.old)&&n.old.call(this),n.queue&&C.dequeue(this,n.queue)},n},C.fn.extend({fadeTo:function(t,e,i,n){return this.filter(ot).css("opacity",0).show().end().animate({opacity:e},t,i,n)},animate:function(e,t,i,n){var r=C.isEmptyObject(e),s=C.speed(t,i,n),o=function(){var t=he(this,C.extend({},e),s);(r||Y.get(this,"finish"))&&t.stop(!0)};return o.finish=o,r||!1===s.queue?this.each(o):this.queue(s.queue,o)},stop:function(r,t,s){var o=function(t){var e=t.stop;delete t.stop,e(s)};return"string"!=typeof r&&(s=t,t=r,r=void 0),t&&this.queue(r||"fx",[]),this.each(function(){var t=!0,e=null!=r&&r+"queueHooks",i=C.timers,n=Y.get(this);if(e)n[e]&&n[e].stop&&o(n[e]);else for(e in n)n[e]&&n[e].stop&&oe.test(e)&&o(n[e]);for(e=i.length;e--;)i[e].elem!==this||null!=r&&i[e].queue!==r||(i[e].anim.stop(s),t=!1,i.splice(e,1));!t&&s||C.dequeue(this,r)})},finish:function(o){return!1!==o&&(o=o||"fx"),this.each(function(){var t,e=Y.get(this),i=e[o+"queue"],n=e[o+"queueHooks"],r=C.timers,s=i?i.length:0;for(e.finish=!0,C.queue(this,o,[]),n&&n.stop&&n.stop.call(this,!0),t=r.length;t--;)r[t].elem===this&&r[t].queue===o&&(r[t].anim.stop(!0),r.splice(t,1));for(t=0;t<s;t++)i[t]&&i[t].finish&&i[t].finish.call(this);delete e.finish})}}),C.each(["toggle","show","hide"],function(t,n){var r=C.fn[n];C.fn[n]=function(t,e,i){return null==t||"boolean"==typeof t?r.apply(this,arguments):this.animate(ue(n,!0),t,e,i)}}),C.each({slideDown:ue("show"),slideUp:ue("hide"),slideToggle:ue("toggle"),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"},fadeToggle:{opacity:"toggle"}},function(t,n){C.fn[t]=function(t,e,i){return this.animate(n,t,e,i)}}),C.timers=[],C.fx.tick=function(){var t,e=0,i=C.timers;for(ee=Date.now();e<i.length;e++)(t=i[e])()||i[e]!==t||i.splice(e--,1);i.length||C.fx.stop(),ee=void 0},C.fx.timer=function(t){C.timers.push(t),C.fx.start()},C.fx.interval=13,C.fx.start=function(){ie||(ie=!0,ae())},C.fx.stop=function(){ie=null},C.fx.speeds={slow:600,fast:200,_default:400},C.fn.delay=function(n,t){return n=C.fx&&C.fx.speeds[n]||n,t=t||"fx",this.queue(t,function(t,e){var i=T.setTimeout(t,n);e.stop=function(){T.clearTimeout(i)}})},ne=S.createElement("input"),re=S.createElement("select").appendChild(S.createElement("option")),ne.type="checkbox",v.checkOn=""!==ne.value,v.optSelected=re.selected,(ne=S.createElement("input")).value="t",ne.type="radio",v.radioValue="t"===ne.value;var de,pe=C.expr.attrHandle;C.fn.extend({attr:function(t,e){return H(this,C.attr,t,e,1<arguments.length)},removeAttr:function(t){return this.each(function(){C.removeAttr(this,t)})}}),C.extend({attr:function(t,e,i){var n,r,s=t.nodeType;if(3!==s&&8!==s&&2!==s)return void 0===t.getAttribute?C.prop(t,e,i):(1===s&&C.isXMLDoc(t)||(r=C.attrHooks[e.toLowerCase()]||(C.expr.match.bool.test(e)?de:void 0)),void 0!==i?null===i?void C.removeAttr(t,e):r&&"set"in r&&void 0!==(n=r.set(t,i,e))?n:(t.setAttribute(e,i+""),i):r&&"get"in r&&null!==(n=r.get(t,e))?n:null==(n=C.find.attr(t,e))?void 0:n)},attrHooks:{type:{set:function(t,e){if(!v.radioValue&&"radio"===e&&k(t,"input")){var i=t.value;return t.setAttribute("type",e),i&&(t.value=i),e}}}},removeAttr:function(t,e){var i,n=0,r=e&&e.match(L);if(r&&1===t.nodeType)for(;i=r[n++];)t.removeAttribute(i)}}),de={set:function(t,e,i){return!1===e?C.removeAttr(t,i):t.setAttribute(i,i),i}},C.each(C.expr.match.bool.source.match(/\w+/g),function(t,e){var o=pe[e]||C.find.attr;pe[e]=function(t,e,i){var n,r,s=e.toLowerCase();return i||(r=pe[s],pe[s]=n,n=null!=o(t,e,i)?s:null,pe[s]=r),n}});var fe=/^(?:input|select|textarea|button)$/i,ge=/^(?:a|area)$/i;function me(t){return(t.match(L)||[]).join(" ")}function ve(t){return t.getAttribute&&t.getAttribute("class")||""}function ye(t){return Array.isArray(t)?t:"string"==typeof t&&t.match(L)||[]}C.fn.extend({prop:function(t,e){return H(this,C.prop,t,e,1<arguments.length)},removeProp:function(t){return this.each(function(){delete this[C.propFix[t]||t]})}}),C.extend({prop:function(t,e,i){var n,r,s=t.nodeType;if(3!==s&&8!==s&&2!==s)return 1===s&&C.isXMLDoc(t)||(e=C.propFix[e]||e,r=C.propHooks[e]),void 0!==i?r&&"set"in r&&void 0!==(n=r.set(t,i,e))?n:t[e]=i:r&&"get"in r&&null!==(n=r.get(t,e))?n:t[e]},propHooks:{tabIndex:{get:function(t){var e=C.find.attr(t,"tabindex");return e?parseInt(e,10):fe.test(t.nodeName)||ge.test(t.nodeName)&&t.href?0:-1}}},propFix:{for:"htmlFor",class:"className"}}),v.optSelected||(C.propHooks.selected={get:function(t){var e=t.parentNode;return e&&e.parentNode&&e.parentNode.selectedIndex,null},set:function(t){var e=t.parentNode;e&&(e.selectedIndex,e.parentNode&&e.parentNode.selectedIndex)}}),C.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){C.propFix[this.toLowerCase()]=this}),C.fn.extend({addClass:function(e){var t,i,n,r,s,o,a,l=0;if(y(e))return this.each(function(t){C(this).addClass(e.call(this,t,ve(this)))});if((t=ye(e)).length)for(;i=this[l++];)if(r=ve(i),n=1===i.nodeType&&" "+me(r)+" "){for(o=0;s=t[o++];)n.indexOf(" "+s+" ")<0&&(n+=s+" ");r!==(a=me(n))&&i.setAttribute("class",a)}return this},removeClass:function(e){var t,i,n,r,s,o,a,l=0;if(y(e))return this.each(function(t){C(this).removeClass(e.call(this,t,ve(this)))});if(!arguments.length)return this.attr("class","");if((t=ye(e)).length)for(;i=this[l++];)if(r=ve(i),n=1===i.nodeType&&" "+me(r)+" "){for(o=0;s=t[o++];)for(;-1<n.indexOf(" "+s+" ");)n=n.replace(" "+s+" "," ");r!==(a=me(n))&&i.setAttribute("class",a)}return this},toggleClass:function(r,e){var s=typeof r,o="string"===s||Array.isArray(r);return"boolean"==typeof e&&o?e?this.addClass(r):this.removeClass(r):y(r)?this.each(function(t){C(this).toggleClass(r.call(this,t,ve(this),e),e)}):this.each(function(){var t,e,i,n;if(o)for(e=0,i=C(this),n=ye(r);t=n[e++];)i.hasClass(t)?i.removeClass(t):i.addClass(t);else void 0!==r&&"boolean"!==s||((t=ve(this))&&Y.set(this,"__className__",t),this.setAttribute&&this.setAttribute("class",t||!1===r?"":Y.get(this,"__className__")||""))})},hasClass:function(t){var e,i,n=0;for(e=" "+t+" ";i=this[n++];)if(1===i.nodeType&&-1<(" "+me(ve(i))+" ").indexOf(e))return!0;return!1}});var be=/\r/g;C.fn.extend({val:function(i){var n,t,r,e=this[0];return arguments.length?(r=y(i),this.each(function(t){var e;1===this.nodeType&&(null==(e=r?i.call(this,t,C(this).val()):i)?e="":"number"==typeof e?e+="":Array.isArray(e)&&(e=C.map(e,function(t){return null==t?"":t+""})),(n=C.valHooks[this.type]||C.valHooks[this.nodeName.toLowerCase()])&&"set"in n&&void 0!==n.set(this,e,"value")||(this.value=e))})):e?(n=C.valHooks[e.type]||C.valHooks[e.nodeName.toLowerCase()])&&"get"in n&&void 0!==(t=n.get(e,"value"))?t:"string"==typeof(t=e.value)?t.replace(be,""):null==t?"":t:void 0}}),C.extend({valHooks:{option:{get:function(t){var e=C.find.attr(t,"value");return null!=e?e:me(C.text(t))}},select:{get:function(t){var e,i,n,r=t.options,s=t.selectedIndex,o="select-one"===t.type,a=o?null:[],l=o?s+1:r.length;for(n=s<0?l:o?s:0;n<l;n++)if(((i=r[n]).selected||n===s)&&!i.disabled&&(!i.parentNode.disabled||!k(i.parentNode,"optgroup"))){if(e=C(i).val(),o)return e;a.push(e)}return a},set:function(t,e){for(var i,n,r=t.options,s=C.makeArray(e),o=r.length;o--;)((n=r[o]).selected=-1<C.inArray(C.valHooks.option.get(n),s))&&(i=!0);return i||(t.selectedIndex=-1),s}}}}),C.each(["radio","checkbox"],function(){C.valHooks[this]={set:function(t,e){if(Array.isArray(e))return t.checked=-1<C.inArray(C(t).val(),e)}},v.checkOn||(C.valHooks[this].get=function(t){return null===t.getAttribute("value")?"on":t.value})}),v.focusin="onfocusin"in T;var we=/^(?:focusinfocus|focusoutblur)$/,_e=function(t){t.stopPropagation()};C.extend(C.event,{trigger:function(t,e,i,n){var r,s,o,a,l,u,c,h,d=[i||S],p=m.call(t,"type")?t.type:t,f=m.call(t,"namespace")?t.namespace.split("."):[];if(s=h=o=i=i||S,3!==i.nodeType&&8!==i.nodeType&&!we.test(p+C.event.triggered)&&(-1<p.indexOf(".")&&(p=(f=p.split(".")).shift(),f.sort()),l=p.indexOf(":")<0&&"on"+p,(t=t[C.expando]?t:new C.Event(p,"object"==typeof t&&t)).isTrigger=n?2:3,t.namespace=f.join("."),t.rnamespace=t.namespace?new RegExp("(^|\\.)"+f.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,t.result=void 0,t.target||(t.target=i),e=null==e?[t]:C.makeArray(e,[t]),c=C.event.special[p]||{},n||!c.trigger||!1!==c.trigger.apply(i,e))){if(!n&&!c.noBubble&&!b(i)){for(a=c.delegateType||p,we.test(a+p)||(s=s.parentNode);s;s=s.parentNode)d.push(s),o=s;o===(i.ownerDocument||S)&&d.push(o.defaultView||o.parentWindow||T)}for(r=0;(s=d[r++])&&!t.isPropagationStopped();)h=s,t.type=1<r?a:c.bindType||p,(u=(Y.get(s,"events")||Object.create(null))[t.type]&&Y.get(s,"handle"))&&u.apply(s,e),(u=l&&s[l])&&u.apply&&K(s)&&(t.result=u.apply(s,e),!1===t.result&&t.preventDefault());return t.type=p,n||t.isDefaultPrevented()||c._default&&!1!==c._default.apply(d.pop(),e)||!K(i)||l&&y(i[p])&&!b(i)&&((o=i[l])&&(i[l]=null),C.event.triggered=p,t.isPropagationStopped()&&h.addEventListener(p,_e),i[p](),t.isPropagationStopped()&&h.removeEventListener(p,_e),C.event.triggered=void 0,o&&(i[l]=o)),t.result}},simulate:function(t,e,i){var n=C.extend(new C.Event,i,{type:t,isSimulated:!0});C.event.trigger(n,null,e)}}),C.fn.extend({trigger:function(t,e){return this.each(function(){C.event.trigger(t,e,this)})},triggerHandler:function(t,e){var i=this[0];if(i)return C.event.trigger(t,e,i,!0)}}),v.focusin||C.each({focus:"focusin",blur:"focusout"},function(i,n){var r=function(t){C.event.simulate(n,t.target,C.event.fix(t))};C.event.special[n]={setup:function(){var t=this.ownerDocument||this.document||this,e=Y.access(t,n);e||t.addEventListener(i,r,!0),Y.access(t,n,(e||0)+1)},teardown:function(){var t=this.ownerDocument||this.document||this,e=Y.access(t,n)-1;e?Y.access(t,n,e):(t.removeEventListener(i,r,!0),Y.remove(t,n))}}});var xe=T.location,Te={guid:Date.now()},Se=/\?/;C.parseXML=function(t){var e;if(!t||"string"!=typeof t)return null;try{e=(new T.DOMParser).parseFromString(t,"text/xml")}catch(t){e=void 0}return e&&!e.getElementsByTagName("parsererror").length||C.error("Invalid XML: "+t),e};var Ce=/\[\]$/,Ee=/\r?\n/g,ke=/^(?:submit|button|image|reset|file)$/i,Ie=/^(?:input|select|textarea|keygen)/i;function De(i,t,n,r){var e;if(Array.isArray(t))C.each(t,function(t,e){n||Ce.test(i)?r(i,e):De(i+"["+("object"==typeof e&&null!=e?t:"")+"]",e,n,r)});else if(n||"object"!==_(t))r(i,t);else for(e in t)De(i+"["+e+"]",t[e],n,r)}C.param=function(t,e){var i,n=[],r=function(t,e){var i=y(e)?e():e;n[n.length]=encodeURIComponent(t)+"="+encodeURIComponent(null==i?"":i)};if(null==t)return"";if(Array.isArray(t)||t.jquery&&!C.isPlainObject(t))C.each(t,function(){r(this.name,this.value)});else for(i in t)De(i,t[i],e,r);return n.join("&")},C.fn.extend({serialize:function(){return C.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var t=C.prop(this,"elements");return t?C.makeArray(t):this}).filter(function(){var t=this.type;return this.name&&!C(this).is(":disabled")&&Ie.test(this.nodeName)&&!ke.test(t)&&(this.checked||!dt.test(t))}).map(function(t,e){var i=C(this).val();return null==i?null:Array.isArray(i)?C.map(i,function(t){return{name:e.name,value:t.replace(Ee,"\r\n")}}):{name:e.name,value:i.replace(Ee,"\r\n")}}).get()}});var Ae=/%20/g,Pe=/#.*$/,Me=/([?&])_=[^&]*/,Ne=/^(.*?):[ \t]*([^\r\n]*)$/gm,Oe=/^(?:GET|HEAD)$/,Le=/^\/\//,Re={},Fe={},ze="*/".concat("*"),Be=S.createElement("a");function $e(s){return function(t,e){"string"!=typeof t&&(e=t,t="*");var i,n=0,r=t.toLowerCase().match(L)||[];if(y(e))for(;i=r[n++];)"+"===i[0]?(i=i.slice(1)||"*",(s[i]=s[i]||[]).unshift(e)):(s[i]=s[i]||[]).push(e)}}function je(e,r,s,o){var a={},l=e===Fe;function u(t){var n;return a[t]=!0,C.each(e[t]||[],function(t,e){var i=e(r,s,o);return"string"!=typeof i||l||a[i]?l?!(n=i):void 0:(r.dataTypes.unshift(i),u(i),!1)}),n}return u(r.dataTypes[0])||!a["*"]&&u("*")}function He(t,e){var i,n,r=C.ajaxSettings.flatOptions||{};for(i in e)void 0!==e[i]&&((r[i]?t:n||(n={}))[i]=e[i]);return n&&C.extend(!0,t,n),t}Be.href=xe.href,C.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:xe.href,type:"GET",isLocal:/^(?:about|app|app-storage|.+-extension|file|res|widget):$/.test(xe.protocol),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":ze,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":C.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(t,e){return e?He(He(t,C.ajaxSettings),e):He(C.ajaxSettings,t)},ajaxPrefilter:$e(Re),ajaxTransport:$e(Fe),ajax:function(t,e){"object"==typeof t&&(e=t,t=void 0),e=e||{};var c,h,d,i,p,n,f,g,r,s,m=C.ajaxSetup({},e),v=m.context||m,y=m.context&&(v.nodeType||v.jquery)?C(v):C.event,b=C.Deferred(),w=C.Callbacks("once memory"),_=m.statusCode||{},o={},a={},l="canceled",x={readyState:0,getResponseHeader:function(t){var e;if(f){if(!i)for(i={};e=Ne.exec(d);)i[e[1].toLowerCase()+" "]=(i[e[1].toLowerCase()+" "]||[]).concat(e[2]);e=i[t.toLowerCase()+" "]}return null==e?null:e.join(", ")},getAllResponseHeaders:function(){return f?d:null},setRequestHeader:function(t,e){return null==f&&(t=a[t.toLowerCase()]=a[t.toLowerCase()]||t,o[t]=e),this},overrideMimeType:function(t){return null==f&&(m.mimeType=t),this},statusCode:function(t){var e;if(t)if(f)x.always(t[x.status]);else for(e in t)_[e]=[_[e],t[e]];return this},abort:function(t){var e=t||l;return c&&c.abort(e),u(0,e),this}};if(b.promise(x),m.url=((t||m.url||xe.href)+"").replace(Le,xe.protocol+"//"),m.type=e.method||e.type||m.method||m.type,m.dataTypes=(m.dataType||"*").toLowerCase().match(L)||[""],null==m.crossDomain){n=S.createElement("a");try{n.href=m.url,n.href=n.href,m.crossDomain=Be.protocol+"//"+Be.host!=n.protocol+"//"+n.host}catch(t){m.crossDomain=!0}}if(m.data&&m.processData&&"string"!=typeof m.data&&(m.data=C.param(m.data,m.traditional)),je(Re,m,e,x),f)return x;for(r in(g=C.event&&m.global)&&0==C.active++&&C.event.trigger("ajaxStart"),m.type=m.type.toUpperCase(),m.hasContent=!Oe.test(m.type),h=m.url.replace(Pe,""),m.hasContent?m.data&&m.processData&&0===(m.contentType||"").indexOf("application/x-www-form-urlencoded")&&(m.data=m.data.replace(Ae,"+")):(s=m.url.slice(h.length),m.data&&(m.processData||"string"==typeof m.data)&&(h+=(Se.test(h)?"&":"?")+m.data,delete m.data),!1===m.cache&&(h=h.replace(Me,"$1"),s=(Se.test(h)?"&":"?")+"_="+Te.guid+++s),m.url=h+s),m.ifModified&&(C.lastModified[h]&&x.setRequestHeader("If-Modified-Since",C.lastModified[h]),C.etag[h]&&x.setRequestHeader("If-None-Match",C.etag[h])),(m.data&&m.hasContent&&!1!==m.contentType||e.contentType)&&x.setRequestHeader("Content-Type",m.contentType),x.setRequestHeader("Accept",m.dataTypes[0]&&m.accepts[m.dataTypes[0]]?m.accepts[m.dataTypes[0]]+("*"!==m.dataTypes[0]?", "+ze+"; q=0.01":""):m.accepts["*"]),m.headers)x.setRequestHeader(r,m.headers[r]);if(m.beforeSend&&(!1===m.beforeSend.call(v,x,m)||f))return x.abort();if(l="abort",w.add(m.complete),x.done(m.success),x.fail(m.error),c=je(Fe,m,e,x)){if(x.readyState=1,g&&y.trigger("ajaxSend",[x,m]),f)return x;m.async&&0<m.timeout&&(p=T.setTimeout(function(){x.abort("timeout")},m.timeout));try{f=!1,c.send(o,u)}catch(t){if(f)throw t;u(-1,t)}}else u(-1,"No Transport");function u(t,e,i,n){var r,s,o,a,l,u=e;f||(f=!0,p&&T.clearTimeout(p),c=void 0,d=n||"",x.readyState=0<t?4:0,r=200<=t&&t<300||304===t,i&&(a=function(t,e,i){for(var n,r,s,o,a=t.contents,l=t.dataTypes;"*"===l[0];)l.shift(),void 0===n&&(n=t.mimeType||e.getResponseHeader("Content-Type"));if(n)for(r in a)if(a[r]&&a[r].test(n)){l.unshift(r);break}if(l[0]in i)s=l[0];else{for(r in i){if(!l[0]||t.converters[r+" "+l[0]]){s=r;break}o||(o=r)}s=s||o}if(s)return s!==l[0]&&l.unshift(s),i[s]}(m,x,i)),!r&&-1<C.inArray("script",m.dataTypes)&&(m.converters["text script"]=function(){}),a=function(t,e,i,n){var r,s,o,a,l,u={},c=t.dataTypes.slice();if(c[1])for(o in t.converters)u[o.toLowerCase()]=t.converters[o];for(s=c.shift();s;)if(t.responseFields[s]&&(i[t.responseFields[s]]=e),!l&&n&&t.dataFilter&&(e=t.dataFilter(e,t.dataType)),l=s,s=c.shift())if("*"===s)s=l;else if("*"!==l&&l!==s){if(!(o=u[l+" "+s]||u["* "+s]))for(r in u)if((a=r.split(" "))[1]===s&&(o=u[l+" "+a[0]]||u["* "+a[0]])){!0===o?o=u[r]:!0!==u[r]&&(s=a[0],c.unshift(a[1]));break}if(!0!==o)if(o&&t.throws)e=o(e);else try{e=o(e)}catch(t){return{state:"parsererror",error:o?t:"No conversion from "+l+" to "+s}}}return{state:"success",data:e}}(m,a,x,r),r?(m.ifModified&&((l=x.getResponseHeader("Last-Modified"))&&(C.lastModified[h]=l),(l=x.getResponseHeader("etag"))&&(C.etag[h]=l)),204===t||"HEAD"===m.type?u="nocontent":304===t?u="notmodified":(u=a.state,s=a.data,r=!(o=a.error))):(o=u,!t&&u||(u="error",t<0&&(t=0))),x.status=t,x.statusText=(e||u)+"",r?b.resolveWith(v,[s,u,x]):b.rejectWith(v,[x,u,o]),x.statusCode(_),_=void 0,g&&y.trigger(r?"ajaxSuccess":"ajaxError",[x,m,r?s:o]),w.fireWith(v,[x,u]),g&&(y.trigger("ajaxComplete",[x,m]),--C.active||C.event.trigger("ajaxStop")))}return x}
vendor: 4,361 bytes, line 1
1,getJSON:function(t,e,i){return C.get(t,e,i,"json")},getScript:function(t,e){return C.get(t,void 0,e,"script")}}),C.each(["get","post"],function(t,r){C[r]=function(t,e,i,n){return y(e)&&(n=n||i,i=e,e=void 0),C.ajax(C.extend({url:t,type:r,dataType:n,data:e,success:i},C.isPlainObject(t)&&t))}}),C.ajaxPrefilter(function(t){var e;for(e in t.headers)"content-type"===e.toLowerCase()&&(t.contentType=t.headers[e]||"")}),C._evalUrl=function(t,e,i){return C.ajax({url:t,type:"GET",dataType:"script",cache:!0,async:!1,global:!1,converters:{"text script":function(){}},dataFilter:function(t){C.globalEval(t,e,i)}})},C.fn.extend({wrapAll:function(t){var e;return this[0]&&(y(t)&&(t=t.call(this[0])),e=C(t,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&e.insertBefore(this[0]),e.map(function(){for(var t=this;t.firstElementChild;)t=t.firstElementChild;return t}).append(this)),this},wrapInner:function(i){return y(i)?this.each(function(t){C(this).wrapInner(i.call(this,t))}):this.each(function(){var t=C(this),e=t.contents();e.length?e.wrapAll(i):t.append(i)})},wrap:function(e){var i=y(e);return this.each(function(t){C(this).wrapAll(i?e.call(this,t):e)})},unwrap:function(t){return this.parent(t).not("body").each(function(){C(this).replaceWith(this.childNodes)}),this}}),C.expr.pseudos.hidden=function(t){return!C.expr.pseudos.visible(t)},C.expr.pseudos.visible=function(t){return!!(t.offsetWidth||t.offsetHeight||t.getClientRects().length)},C.ajaxSettings.xhr=function(){try{return new T.XMLHttpRequest}catch(t){}};var qe={0:200,1223:204},Ve=C.ajaxSettings.xhr();v.cors=!!Ve&&"withCredentials"in Ve,v.ajax=Ve=!!Ve,C.ajaxTransport(function(r){var s,o;if(v.cors||Ve&&!r.crossDomain)return{send:function(t,e){var i,n=r.xhr();if(n.open(r.type,r.url,r.async,r.username,r.password),r.xhrFields)for(i in r.xhrFields)n[i]=r.xhrFields[i];for(i in r.mimeType&&n.overrideMimeType&&n.overrideMimeType(r.mimeType),r.crossDomain||t["X-Requested-With"]||(t["X-Requested-With"]="XMLHttpRequest"),t)n.setRequestHeader(i,t[i]);s=function(t){return function(){s&&(s=o=n.onload=n.onerror=n.onabort=n.ontimeout=n.onreadystatechange=null,"abort"===t?n.abort():"error"===t?"number"!=typeof n.status?e(0,"error"):e(n.status,n.statusText):e(qe[n.status]||n.status,n.statusText,"text"!==(n.responseType||"text")||"string"!=typeof n.responseText?{binary:n.response}:{text:n.responseText},n.getAllResponseHeaders()))}},n.onload=s(),o=n.onerror=n.ontimeout=s("error"),void 0!==n.onabort?n.onabort=o:n.onreadystatechange=function(){4===n.readyState&&T.setTimeout(function(){s&&o()})},s=s("abort");try{n.send(r.hasContent&&r.data||null)}catch(t){if(s)throw t}},abort:function(){s&&s()}}}),C.ajaxPrefilter(function(t){t.crossDomain&&(t.contents.script=!1)}),C.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/\b(?:java|ecma)script\b/},converters:{"text script":function(t){return C.globalEval(t),t}}}),C.ajaxPrefilter("script",function(t){void 0===t.cache&&(t.cache=!1),t.crossDomain&&(t.type="GET")}),C.ajaxTransport("script",function(i){var n,r;if(i.crossDomain||i.scriptAttrs)return{send:function(t,e){n=C("<script>").attr(i.scriptAttrs||{}).prop({charset:i.scriptCharset,src:i.url}).on("load error",r=function(t){n.remove(),r=null,t&&e("error"===t.type?404:200,t.type)}),S.head.appendChild(n[0])},abort:function(){r&&r()}}});var Ue,We=[],Ke=/(=)\?(?=&|$)|\?\?/;C.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var t=We.pop()||C.expando+"_"+Te.guid++;return this[t]=!0,t}}),C.ajaxPrefilter("json jsonp",function(t,e,i){var n,r,s,o=!1!==t.jsonp&&(Ke.test(t.url)?"url":"string"==typeof t.data&&0===(t.contentType||"").indexOf("application/x-www-form-urlencoded")&&Ke.test(t.data)&&"data");if(o||"jsonp"===t.dataTypes[0])return n=t.jsonpCallback=y(t.jsonpCallback)?t.jsonpCallback():t.jsonpCallback,o?t[o]=t[o].replace(Ke,"$1"+n):!1!==t.jsonp&&(t.url+=(Se.test(t.url)?"&":"?")+t.jsonp+"="+n),t.converters["script json"]=function(){return s||C.error(n+" was not called"),s[0]},t.dataTypes[0]="json",r=T[n],T[n]=function(){s=arguments},i.always(function(){void 0===r?C(T).removeProp(n):T[n]=r,t[n]&&(t.jsonpCallback=e.jsonpCallback,We.push(n)),s&&y(r)&&r(s[0]),s=r=void 0}),"script"}),v.createHTMLDocument=((Ue=S.implementation.createHTMLDocument("").body).innerHTML="<form></form><form></form>
1",2===Ue.childNodes.length),C.parseHTML=function(t,e,i){return"string"!=typeof t?[]:("boolean"==typeof e&&(i=e,e=!1),e||(v.createHTMLDocument?((n=(e=S.implementation.createHTMLDocument("")).createElement("base")).href=S.location.href,e.head.appendChild(n)):e=S),s=!i&&[],(r=I.exec(t))?[e.createElement(r[1])]:(r=bt([t],e,s),s&&s.length&&C(s).remove(),C.merge([],r.childNodes)));var n,r,s},C.fn.load=function(t,e,i){var n,r,s,o=this,a=t.indexOf(" ");return-1<a&&(n=me(t.slice(a)),t=t.slice(0,a)),y(e)?(i=e,e=void 0):e&&"object"==typeof e&&(r="POST"),0<o.length&&C.ajax({url:t,type:r||"GET",dataType:"html",data:e}).done(function(t){s=arguments,o.html(n?C("<div>").append(C.parseHTML(t)).find(n):t)}).always(i&&function(t,e){o.each(function(){i.apply(this,s||[t.responseText,e,t])})}),this},C.expr.pseudos.animated=function(e){return C.grep(C.timers,function(t){return e===t.elem}).length},C.offset={setOffset:function(t,e,i){var n,r,s,o,a,l,u=C.css(t,"position"),c=C(t),h={};"static"===u&&(t.style.position="relative"),a=c.offset(),s=C.css(t,"top"),l=C.css(t,"left"),r=("absolute"===u||"fixed"===u)&&-1<(s+l).indexOf("auto")?(o=(n=c.position()).top,n.left):(o=parseFloat(s)||0,parseFloat(l)||0),y(e)&&(e=e.call(t,i,C.extend({},a))),null!=e.top&&(h.top=e.top-a.top+o),null!=e.left&&(h.left=e.left-a.left+r),"using"in e?e.using.call(t,h):("number"==typeof h.top&&(h.top+="px"),"number"==typeof h.left&&(h.left+="px"),c.css(h))}},C.fn.extend({offset:function(e){if(arguments.length)return void 0===e?this:this.each(function(t){C.offset.setOffset(this,e,t)});var t,i,n=this[0];return n?n.getClientRects().length?(t=n.getBoundingClientRect(),i=n.ownerDocument.defaultView,{top:t.top+i.pageYOffset,left:t.left+i.pageXOffset}):{top:0,left:0}:void 0},position:function(){if(this[0]){var t,e,i,n=this[0],r={top:0,left:0};if("fixed"===C.css(n,"position"))e=n.getBoundingClientRect();else{for(e=this.offset(),i=n.ownerDocument,t=n.offsetParent||i.documentElement;t&&(t===i.body||t===i.documentElement)&&"static"===C.css(t,"position");)t=t.parentNode;t&&t!==n&&1===t.nodeType&&((r=C(t).offset()).top+=C.css(t,"borderTopWidth",!0),r.left+=C.css(t,"borderLeftWidth",!0))}return{top:e.top-r.top-C.css(n,"marginTop",!0),left:e.left-r.left-C.css(n,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){for(var t=this.offsetParent;t&&"static"===C.css(t,"position");)t=t.offsetParent;return t||nt})}}),C.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(e,r){var s="pageYOffset"===r;C.fn[e]=function(t){return H(this,function(t,e,i){var n;if(b(t)?n=t:9===t.nodeType&&(n=t.defaultView),void 0===i)return n?n[r]:t[e];n?n.scrollTo(s?n.pageXOffset:i,s?i:n.pageYOffset):t[e]=i},e,t,arguments.length)}}),C.each(["top","left"],function(t,i){C.cssHooks[i]=Ht(v.pixelPosition,function(t,e){if(e)return e=jt(t,i),Ft.test(e)?C(t).position()[i]+"px":e})}),C.each({Height:"height",Width:"width"},function(o,a){C.each({padding:"inner"+o,content:a,"":"outer"+o},function(n,s){C.fn[s]=function(t,e){var i=arguments.length&&(n||"boolean"!=typeof t),r=n||(!0===t||!0===e?"margin":"border");return H(this,function(t,e,i){var n;return b(t)?0===s.indexOf("outer")?t["inner"+o]:t.document.documentElement["client"+o]:9===t.nodeType?(n=t.documentElement,Math.max(t.body["scroll"+o],n["scroll"+o],t.body["offset"+o],n["offset"+o],n["client"+o])):void 0===i?C.css(t,e,r):C.style(t,e,i,r)},a,i?t:void 0,i)}})}),C.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(t,e){C.fn[e]=function(t){return this.on(e,t)}}),C.fn.extend({bind:function(t,e,i){return this.on(t,null,e,i)},unbind:function(t,e){return this.off(t,null,e)},delegate:function(t,e,i,n){return this.on(e,t,i,n)},undelegate:function(t,e,i){return 1===arguments.length?this.off(t,"**"):this.off(e,t||"**",i)},hover:function(t,e){return this.mouseenter(t).mouseleave(e||t)}}),C.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(t,i){C.fn[i]=function(t,e){return 0<arguments.length?this.on(i,null,t,e):this.trigger(i)}});var Ge=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g;C.proxy=function(t,e){var i,n,r;if("string"==typeof e&&(i=t[e],e=t,t=i),y(t))return n=a.call(arguments,2),(r=function(){return t.apply(e||this,n.concat(a.call(arguments)))}).guid=t.guid=t.guid||C.guid++,r},C.holdReady=function(t){t?C.readyWait++:C.ready(!0)},C.isArray=Array.isArray,C.parseJSON=JSON.parse,C.nodeName=k,C.isFunction=y,C.isWindow=b,C.camel
1Case=W,C.type=_,C.now=Date.now,C.isNumeric=function(t){var e=C.type(t);return("number"===e||"string"===e)&&!isNaN(t-parseFloat(t))},C.trim=function(t){return null==t?"":(t+"").replace(Ge,"")},"function"==typeof define&&define.amd&&define("jquery",[],function(){return C});var Ye=T.jQuery,Xe=T.$;return C.noConflict=function(t){return T.$===C&&(T.$=Xe),t&&T.jQuery===C&&(T.jQuery=Ye),C},void 0===t&&(T.jQuery=T.$=C),C}),function(o,n){var a=o(n);o.fn.lazyload=function(t){function e(){var e=0;r.each(function(){var t=o(this);if((!s.skip_invisible||t.is(":visible"))&&!o.abovethetop(this,s)&&!o.leftofbegin(this,s))if(o.belowthefold(this,s)||o.rightoffold(this,s)){if(++e>s.failure_limit)return!1}else t.trigger("appear"),e=0})}var i,r=this,s={threshold:0,failure_limit:0,event:"scroll",effect:"show",container:n,data_attribute:"original",skip_invisible:!0,appear:null,load:null};return t&&(void 0!==t.failurelimit&&(t.failure_limit=t.failurelimit,delete t.failurelimit),void 0!==t.effectspeed&&(t.effect_speed=t.effectspeed,delete t.effectspeed),o.extend(s,t)),i=void 0===s.container||s.container===n?a:o(s.container),0===s.event.indexOf("scroll")&&i.bind(s.event,function(t){return e()}),this.each(function(){var i=this,n=o(i);i.loaded=!1,n.one("appear",function(){if(!this.loaded){if(s.appear){var t=r.length;s.appear.call(i,t,s)}o("<img />").bind("load",function(){n.hide().attr("src",n.data(s.data_attribute))[s.effect](s.effect_speed),i.loaded=!0;var t=o.grep(r,function(t){return!t.loaded});if(r=o(t),s.load){var e=r.length;s.load.call(i,e,s)}}).attr("src",n.data(s.data_attribute))}}),0!==s.event.indexOf("scroll")&&n.bind(s.event,function(t){i.loaded||n.trigger("appear")})}),a.bind("resize",function(t){e()}),o(document).ready(function(){e()}),this},o.belowthefold=function(t,e){return(void 0===e.container||e.container===n?a.height()+a.scrollTop():o(e.container).offset().top+o(e.container).height())<=o(t).offset().top-e.threshold},o.rightoffold=function(t,e){return(void 0===e.container||e.container===n?a.width()+a.scrollLeft():o(e.container).offset().left+o(e.container).width())<=o(t).offset().left-e.threshold},o.abovethetop=function(t,e){return(void 0===e.container||e.container===n?a.scrollTop():o(e.container).offset().top)>=o(t).offset().top+e.threshold+o(t).height()},o.leftofbegin=function(t,e){return(void 0===e.container||e.container===n?a.scrollLeft():o(e.container).offset().left)>=o(t).offset().left+e.threshold+o(t).width()},o.inviewport=function(t,e){return!(o.rightofscreen(t,e)||o.leftofscreen(t,e)||o.belowthefold(t,e)||o.abovethetop(t,e))},o.extend(o.expr[":"],{"below-the-fold":function(t){return o.belowthefold(t,{threshold:0})},"above-the-top":function(t){return!o.belowthefold(t,{threshold:0})},"right-of-screen":function(t){return o.rightoffold(t,{threshold:0})},"left-of-screen":function(t){return!o.rightoffold(t,{threshold:0})},"in-viewport":function(t){return!o.inviewport(t,{threshold:0})},"above-the-fold":function(t){return!o.belowthefold(t,{threshold:0})},"right-of-fold":function(t){return o.rightoffold(t,{threshold:0})},"left-of-fold":function(t){return!o.rightoffold(t,{threshold:0})}})}(jQuery,window),$(function(){check_webp_feature("lossy",webEnabled),$("img.lazy").lazyload({effect:"fadeIn",failure_limit:100,threshold:50,effectspeed:100,load:function(t,e){$(this).removeClass("lazy")}}),0<$(".slazy").length&&$(".slazy").map(function(){$("#"+$(this).attr("id")+" img.lazy").lazyload({container:$("#"+$(this).attr("id")),effect:"fadeIn",failure_limit:10,skip_invisible:!1,effectspeed:300})})});var hash=window.location.hash,reply_post_id=0,modal_btn_bind=!1,loaderhtml='<div id="_lodr" class="_lodr">                    <div class="_ldrimg">                        <span class="_rdthldr">                            <i class="_redt"></i>                        </span>                        <i class="_ldrlogo">ee</i>                    </div>                    <span class="_ldrtext">Loading ...</span>                </div>',_arMPHTML='<div class="__ar_ovrly"></div>                <div id="__arModal" class="__ar_modal">                    <div class="__ar_modal-content">
1                        <span class="__ar_modal-close"></span>                        <div class="__ar_modal-body"></div>                    </div>                </div>',_device={};function _rrCodeRun(t){for(;t.length;){(0,t.splice(0,1)[0])()}}function redAffUrl(t){window.open(t,"_blank")}function appendCSS(t){if(void 0===t||""===t)return!1;var e=document.getElementsByTagName("body").item(0),i=document.createElement("link");i.type="text/css",i.rel="stylesheet",i.media="all",i.href=t,e.appendChild(i)}function appendJS(t){if(void 0===t||""===t)return!1;var e=document.getElementsByTagName("head").item(0),i=document.createElement("script");i.type="text/javascript",i.async=!0,i.src=t,e.appendChild(i)}function onShareClick(){void 0!==navigator.share&&(canonicalElement=document.querySelector("link[rel=canonical]"),link=window.location.href.split("?")[0],null!==canonicalElement&&(link=canonicalElement.href),navigator.share({title:"Share",text:"",url:link}))}function get_browser_info(){var t,e=navigator.userAgent,i=e.match(/(opera|chrome|safari|firefox|msie|trident(?=\/))\/?\s*(\d+)/i)||[],n="desktop";return/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(e)&&(n="mobile"),/trident/i.test(i[1])?{name:"ie",version:(t=/\brv[ :]+(\d+)/g.exec(e)||[])[1]||"",device:n}:"Chrome"===i[1]&&null!=(t=e.match(/\bOPR\/(\d+)/))?{name:"opera",version:t[1],device:n}:(i=i[2]?[i[1],i[2]]:[navigator.appName,navigator.appVersion,"-?"],null!=(t=e.match(/version\/(\d+)/i))&&i.splice(1,1,t[1]),{name:i[0].toLowerCase(),version:i[1],device:n})}function isLocalStorageSupported(){try{return localStorage.setItem("testlocal","1"),localStorage.removeItem("testlocal"),!0}catch(t){return!1}}function getLocalStorage(t){if(isLocalStorageSupported())return localStorage.getItem(t)}function setLocalStorage(t,e){isLocalStorageSupported()&&localStorage.setItem(t,e)}function deleteLocalStorage(t){isLocalStorageSupported()&&localStorage.removeItem(t)}function updateViaAppLinks(t){baseUrl=BASE_URL.slice(0,-1),0<$('a[href^="'+baseUrl+'"]').length&&""!=(t="app"==t?"via=app":"")&&$('a[href^="'+baseUrl+'"]').each(function(){href=$(this).attr("href"),-1==href.indexOf(t)&&(-1!=href.indexOf("?")?href+="&"+t:href+="?"+t,$(this).attr("href",href))})}function startDictation(){if(window.hasOwnProperty("webkitSpeechRecognition")){$("._voicesrc").addClass("_voicesearch");var e=new webkitSpeechRecognition;e.continuous=!1,e.interimResults=!1,e.lang="en-US",e.start(),e.onresult=function(t){$("#txtTopSearch").val(t.results[0][0].transcript),$("._voicesrc").removeClass("_voicesearch"),e.stop(),$("#searchFrm").submit()},e.onerror=function(t){$("._voicesrc").removeClass("_voicesearch"),e.stop()},e.onend=function(t){$("._voicesrc").removeClass("_voicesearch"),e.stop()}}}function socialShareDataLayerPush(t){window.dataLayer=window.dataLayer||[],pushData={event:t.event,eventCategory:t.eventCategory,eventAction:t.eventAction,eventLabel:t.eventLabel,PageType:t.PageType,SiteName:t.SiteName,URL:t.URL},void 0!==t.ArticleCategory&&""!=t.ArticleCategory&&(articleCategoryData={"Article Category":t.ArticleCategory},pushData=Object.assign({},pushData,articleCategoryData)),console.table(t),dataLayer.push(pushData)}function rrCodeFn(){_rrCodeSt||(_rrCodeSt=1,_rrCodeRun(_rrCode))}function sliderRange(){$("#slider-range").slider({range:!0,orientation:"horizontal",min:parseInt($("#min_price").attr("min")),max:parseInt($("#max_price").attr("max")),values:[parseInt($("#min_price").val()),parseInt($("#max_price").val())],step:1,slide:function(t,e){if(e.values[0]==e.values[1])return!1;$("#min_price").val(e.values[0]),$("#max_price").val(e.values[1])}})}function getFilterUrl(t){var e=new Array;if(t&&($("ul#openflfltr input:checkbox:checked").each(function(){void 0!==e[$(this).attr("name")]&&null!==e[$(this).attr("name")]?e[$(this).attr("name")]=e[$(this).attr("name")]+","+$(this).val():e[$(this).attr("name")]=$(this).val()}),$("ul.brand-list").find("input:checkbox").attr("checked",!1)),$(".select_filter:checkbox:checked").each(function(){void 0!==e[$(this).attr("name")]&&null!==e[$(this).attr("name")]?e[$(this).attr("name")]=e[$(this).attr("name")]+","+encodeURIComponent($(this).val()):e[$(this).attr("name")]=encodeURIComponent($(this).val())}),$("#min_price").length&&$("#max_price").length){var i=parseInt($("#min_price").attr("min")),n=parseInt($("#max_price").attr("max")),r=parseInt($("#min_price").val()),s=parseInt($("#max_price").val()),o=i,a=n;i===r&&n===s||(i<=r&&r<=n&&(o=r),i<=s&&s<=n&&(a=s),e.instock_price=o+"-"+a)}orderBy="desc",sortByName="popularity",$(".psortby.active").each(function(){sortByName=$(this).attr("data-sort"),changeSort=$(this).attr("changeSort"),"undefined"!=typeof changeSort&&(orderBy="asc")});var l="?",u=$("#psearch").val();for(var c in void 0!==u&&""!==u&&null!=u&&(l+="query="+encodeURIComponent(u)+"&"),e)l+="facet["+c+"]="+e[c]+"&";return l+="sort="+sortByName+"&order="+orderBy,{url:location.protocol+"//"+location.host+location.pathname+l,facet:e,q:u}}function getProductListData(t,e){$.ajax({type:"GET",url:t,beforeSend:function(){IS_MOBILE||2==e?showPageLoading(1,"no"):(disableScrolling(),showPageLoading(1,"yes"))},success:function(t){1==e?(""==t?($(".clear-all").show(),$("#allplist").html("<div class='box-bg notfound'>No result Found</div>"),$("li.psortby").css({"pointer-events":"none",opacity:.6}),$(".load-more").parent("._lpdmr").remove()):void 0!==(t=$.parseJSON(t))&&(void 0!==t.response&&$("#allplist").html(t.response),void 0!==t.filters&&$("#filterlistdetail").html(t.filters),void 0!==t.totalCountMsg&&$("._pdrt").html(t.totalCountMsg),void 0!==t.totalCount&&showLoadMore(t.totalCount)),IS_MOBILE||($("#filterlist").prependTo("._lpdcntr"),$("._lsrtby").prependTo("._lpdlst"),$(".filter-str").insertAfter("._lsrtby")),sliderRange(),updateFiltersPosition()):2==e?void 0!==(t=$.parseJSON(t))&&(void 0!==t.response&&$("#allplist").append(t.response),void 0!==t.totalCount&&showLoadMore(t.totalCount)):3==e&&void 0!==(t=$.parseJSON(t))&&(void 0!==t.response&&$("#allplist").html(t.response),void 0!==t.totalCount&&showLoadMore(t.totalCount)),$("#pagecount").val(t.pageCount),$("#totalcount").val(t.totalCount),showPageLoading(0,""),enableScrolling(),IS_MOBILE||(1==e?updateListingPosition():2==e&&updateListingHeight())}
1,error:function(t,e,i){showPageLoading(0,""),enableScrolling()}})}function disableScrolling(){$("body").css({"overflow-y":"hidden"}),$("html").css({"overflow-y":"hidden"})}function enableScrolling(){$("body").css({"overflow-y":"",position:""}),$("html").css({"overflow-y":"",position:""}),$("body").find(".open-fltrpp").removeClass("open-fltrpp")}function scrollPageById(t){scrollTop=$("#"+t).offset().top-$(".header").height(),scrollTop=IS_MOBILE?scrollTop-40:scrollTop,$("html, body").animate({scrollTop:scrollTop},800)}function sliderRange(){$("#slider-range").slider({range:!0,orientation:"horizontal",min:parseInt($("#min_price").attr("min")),max:parseInt($("#max_price").attr("max")),values:[parseInt($("#min_price").val()),parseInt($("#max_price").val())],step:1,slide:function(t,e){if(e.values[0]==e.values[1])return!1;$("#min_price").val(e.values[0]),$("#max_price").val(e.values[1])}})}function updateFiltersPosition(){$("ul.ftl").each(function(){var i=$(this);$(this).find(".select_filter").each(function(){if($(this).prop("checked"))(e=(t=$(this).closest("li")).eq(0).clone()).attr("style",""),$(i).prepend(e),t.remove();else if($(this).closest("li").hasClass("_ldactv")){var t,e=(t=$(this).closest("li")).eq(0).clone();$(i).append(e),t.remove()}}),$(".fltrinputkeywords").trigger("change")}),updateFilterCount(),IS_MOBILE||getFilterRow()}function updateFilterCount(){filter_count=0<$(".select_filter:checkbox:checked").length?$(".select_filter:checkbox:checked").length:"",filter_count?$(".filter-count").addClass("_lfbdg"):$(".filter-count").removeClass("_lfbdg"),$(".filter-count").text(filter_count)}function openBrandPopup(){0<$("#openflfltr-nav").length&&$("#openflfltr-nav").remove(),$("#openflfltr").listnav({showCounts:!1}),$("#openflfltr-nav").insertBefore(".flfltr-list .closepup")}function changeFilterListing(t,e){var i=t.val(),n=e?t.closest("._lfgrp").find("ul#openflfltr"):t.closest("._lfgrp").find("ul._lftdlst"),r=t.closest("._lfgrp").attr("data-label-id"),s=n.attr("data-limit"),o=n.attr("data-exceed-limit");if($("."+r+"_notFound").remove(),$(n).find("li").removeAttr("data-class"),$("#"+r).removeAttr("data-count-temp").text("").hide(),""!=i){i=i.toLowerCase();var a=0,l=totalCnt=0;$(n).find("li").each(function(){void 0!==$(this).attr("title")&&-1==$(this).attr("title").toLowerCase().indexOf(i)?$(this).attr("style","display:none"):(totalCnt++,a<s&&!$(this).hasClass("_ldactv")?(a++,$(this).attr("style","display:flex"),$(this).attr("data-class","show_li")):(l++,$(this).attr("style","display:none"),$(this).attr("data-class","hide_li")))}),0<l&&(n.hasClass("brand-list")&&totalCnt<50&&$("#brand").hasClass("showpopup")&&$("#brand").removeClass("showpopup").addClass("showlist"),$("#"+r).text(l+" More").attr("data-count-temp",l).show()),0==a&&$(n).append('<li class="'+r+'_notFound" style="color:red;font-size:14px;">No Match Found</li>')}else{a=0;var u=$(n).find("li").length>o?0:1;$(n).find("li").each(function(){a++,!u&&s<a?$(this).attr("style","display:none"):$(this).attr("style","display:flex")}),$("#"+r).text($("#"+r).attr("data-count")+" More").show(),t.closest("._lfgrp").removeClass("showfull")}return!1}function showPageLoading(t,e){1==t&&"yes"==e?($(".overlay").remove(),$("._lpdcntr").append('<div class="overlay"></div>'+loaderhtml)):1==t&&"no"==e?(cntnr=IS_MOBILE?"._lpdinfo":"._lpdcntr",$(cntnr).append(loaderhtml)):($(".overlay").fadeOut("slow"),$("#_lodr").fadeOut("slow"),$("._lodr").remove())}function getFilterRow(){html="",min_price=parseInt($("#min_price").attr("min")),max_price=parseInt($("#min_price").attr("max")),show_price_filter=parseInt($("#min_price").val())>min_price||parseInt($("#max_price").val())<max_price,show_filter=show_price_filter||0<$(".select_filter:checkbox:checked").length,show_filter&&(html+='<div class="filter-str _flx">'),$("._lfgrp").each(function(){label=$(this).find("._lfhdctg").text(),1==$(this).find("#slider-range").length&&show_price_filter&&(html+='<div class="_flx"><span>'+label+':</span><span data-key="instock_price" class="search-fltr-cnt"> &#8377; '+$("#min_price").val()+" - "+$("#max_price").val()+"</span></div>"),0<$(this).find(".select_filter:checkbox:checked").length&&(html+='<div class="_flx"><span class="_fsrtxt">'+label+":</span>",$(this).find(".select_filter:checkbox:checked").each(function(){html+='<sp
1an data-key="'+$(this).attr("id")+'" class="search-fltr-cnt">'+$(this).next("label").text()+"</span>"}),html+="</div>")}),show_filter&&(html+='<span class="clear-all" data-url="'+$(".clear-all").data("url")+'">Clear All</span></div>'),""!=html?($(".filter-str").remove(),$(html).insertAfter("._lsrtby")):$(".filter-str").remove()}function showLoadMore(t){$(".load-more").parent("._lpdmr").remove(),currentCnt=$("._lpdw").length,t>currentCnt&&$("#allplist").append('<div class="_lpdmr"><a href="javascript:void(0)" class="load-more _btn">Load More</a></div>')}_device.browser="",window._rrCodeSt=0,window._rrCode=window._rrCode||[],navigator.userAgent.match(/iPhone/i)?(_device.name="iphone",_device.type="mobile",navigator.userAgent.match(/WebKit/i)&&!navigator.userAgent.match(/CriOS/i)&&(_device.browser="safari")):navigator.userAgent.match(/android/i)?(_device.name="android",_device.type="mobile"):(_device.name="",_device.type="desktop"),$("html").addClass(_device.name).addClass(_device.type).addClass(_device.browser),$(document).ready(function(){("undefined"!=typeof querySt&&"app"==querySt("via")||""!=getCookie("viapriceeapp"))&&navigator.userAgent.match(/iPhone|iPad|iPod/i)&&updateViaAppLinks("app"),0<$(".sharemovejs").length&&0<$(".sharemovejsup").length&&($(".sharemovejsup").insertBefore(".sharemovejs"),$(".sharemovejs").remove()),0<$("._ctd ._shrinkjs").length&&$("._ctd ._shrinkjs").each(function(){if($(this).find("[data-shrink]").length>$(this).find("[data-shrink]").attr("data-shrink")){var t=$(this).find("[data-shrink]").length-$(this).find("[data-shrink]").attr("data-shrink");$(this).find("[data-shrink]:nth-last-child(-n+"+t+")").hide(),$(this).after('<div class="_flx _semr"><span class="_rmbtn">see more</span></div>')}else $(this).removeClass("_shrinkjs")}),$("._semr ._rmbtn").on("click",function(){$(this).parent().prev().each(function(){if(0<$(this).find("[data-shrink]").length){var t=$(this).find("[data-shrink]").length-$(this).find("[data-shrink]").attr("data-shrink");$(this).find("[data-shrink]:nth-last-child(-n+"+t+")").show()}}),$(this).parent().prev().removeClass("_shrinkjs"),$(this).parent().remove(),imgLazyLoad()}),$.getCleanVal=function(t){return(t=$.trim(t)).replace(/<script[^>]*?>.*?<\/script>/gi,"").replace(/<[\/\!]*?[^<>]*?>/gi,"").replace(/<style[^>]*?>.*?<\/style>/gi,"").replace(/<![\s\S]*?--[ \t\n\r]*>/gi,"")},$(document).on("click",".daffUrl,.noredaffUrl",function(t){var e=$.trim($(this).attr("data-id")),i=$.trim($(this).attr("data-clicked")),n=$.trim($(this).attr("data-url")),r="https://pricee.com/api/redirect/t.php?itemid="+e+"&clicked_on="+i;"undefined"!=typeof pageStore&&"Amazon"==pageStore&&"undefined"!=typeof pagetype&&"store-list"==pagetype&&(r+="&utm_source=DEALS-SECTION"),"undefined"!=typeof pagetype&&"deal-sale"==pagetype&&(r+="&utm_source=DEALS-OFTHE-DAY"),void 0!==n&&""!=n&&(r=n),redAffUrl(r),$(this).hasClass("noredaffUrl")||(window.location.href=hrefUrl)}),200<=window.pageYOffset&&window.scrollBy(0,1);var t=!0;$(document).one("click scroll mouseover",function(){t&&("undefined"!=typeof FONT_BTF&&""!=FONT_BTF&&(appendCSS(FONT_BTF),FONT_BTF=""),"undefined"!=typeof CSS_BTF&&""!=CSS_BTF&&(appendCSS(CSS_BTF),CSS_BTF=""),"undefined"!=typeof JS_BTF&&""!=JS_BTF&&(appendJS(JS_BTF),JS_BTF=""),"undefined"!=typeof JS_Sales&&""!=JS_Sales&&(appendJS(JS_Sales),JS_Sales=""),_rrCodeSt||(_rrCodeSt=1,_rrCode.length&&_rrCodeRun(_rrCode)),i&&rrCodeFn(),"undefined"!=typeof JS_TABOOLA&&""!=JS_TABOOLA&&i&&(appendJS(JS_TABOOLA),JS_TABOOLA="",_taboolaPerformance&&window.performance&&"function"==typeof window.performance.mark&&window.performance.mark("tbl_ic")),t=!1)});var e=get_browser_info();if(($("._sshrl").length&&"opera"==e.name&&26<=e.version||"chrome"==e.name&&32<=e.version||"mobile"!=e.device&&"firefox"==e.name&&44<=e.version)&&("firefox"==e.name||"chrome"==e.name||"opera"==e.name)){$("._sshrl").append('<li class="bnotification bnfshow"><span onclick="showSubscribeDiv();" class="_bellicon _icn" id="notifbell" aria-label="notify"></span></li>')}0<$("._sshric").length&&(IS_MOBILE?$("._sshric").click(function(){$(this).parent().toggleClass("open"),$(".bnfpopover").hide()}):($("._sshric").offset().left<$(window).width()/2&&$("._sshric").parent().addClass("_opright"),$("._sshric").parent().hover(function(){$(".bnfpopover").hide()}))),$(document).on("click",function(t){IS_MOBILE&&0<$("._sshric").length&&!t.target.classList.contains("_sshric")&&!t.target.classList.contains("_bellicon")&&$("._sshric").parent().removeClass("open")}),IS_MOBILE&&void 0!==navigator.share&&$("._sshrl").append('<li><span class="_nativeicn _icn" onclick="onShareClick()">Share</span></li>'),$(document).on("keyup","#txtTopSearch",function(t){var e=$.trim($(this).val());1<e.length?$.ajax({type:"GET",url:"https://pricee.com/api/v1/suggest.php?q="+e,beforeSend:function(){},success:function(t){if($("#autosuggest").css("display","block"),""==t)$("#autosuggest").html("<div class='_nf'>No result Found</div>");else if(void 0!==t)if(void 0!==t.data&&""!=t.data){var i="<ul>";$.each(t.data,function(t,e){void 0!==e[1]&&""!=e[1]?i+='<li><a class="ellipsis" href="https://pricee.com/?q='+e[0]+"&category="+e[1]+'"><span>'+e[0]+"</span> in <strong>"+e[1]+"</strong></a></li>":"<a"===e[0].slice(0,2).trim()?i+="<li>"+e[0]+"</li>":i+='<li><a class="ellipsis" href="https://pricee.com/?q='+e[0]+'">'+e[0]+"</a></li>"}),i+="</ul>",$("#autosuggest").html(i),$("#autosuggest").show(),$("#autosuggest a").mousedown(function(t){t.preventDefault()})}else $("#autosuggest").html("<div class='_nf'>No result Found</div>"),$("#autosuggest").show()}
1,error:function(t,e,i){}}):$("#autosuggest").html("")}),$(document).on("focusout","#txtTopSearch",function(){$("#autosuggest").css("display","none")}),$("._sshrl a, ._sshrl span").click(function(){void 0!==$(this).data("platform")&&(dataLayerIndex="undefined"!=typeof IS_MOBILE?0:1,pageType=void 0!==dataLayer[dataLayerIndex].PageType?dataLayer[dataLayerIndex].PageType:"others",siteName=void 0!==dataLayer[dataLayerIndex].SiteName?dataLayer[dataLayerIndex].SiteName:"pricee.com",articleCategory=void 0!==dataLayer[dataLayerIndex].articlecategory?dataLayer[dataLayerIndex].articlecategory:"",stickyShareParams={event:"top_stickey",eventCategory:"top stickey",eventAction:"top stickey clicked"},nonStickyShareParams={event:"social_icon_top",eventCategory:"social icon top",eventAction:"top icon clicked"},params={eventLabel:$(this).data("platform"),PageType:pageType,SiteName:siteName,URL:window.location.href,ArticleCategory:articleCategory},!IS_MOBILE&&$("._fxdiv").length&&$("._fxdiv").hasClass("_stky")?params=Object.assign({},params,stickyShareParams):params=Object.assign({},params,nonStickyShareParams),socialShareDataLayerPush(params))});var i=!0;rrCodeFn(),"undefined"!=typeof JS_TABOOLA&&""!=JS_TABOOLA&&(appendJS(JS_TABOOLA),JS_TABOOLA="",_taboolaPerformance&&window.performance&&"function"==typeof window.performance.mark&&window.performance.mark("tbl_ic")),i=!1}),function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):(t=t||self).Swiper=e()}(this,function(){"use strict";function n(t){return null!==t&&"object"==typeof t&&"constructor"in t&&t.constructor===Object}function r(e,i){void 0===e&&(e={}),void 0===i&&(i={}
1),Object.keys(i).forEach(function(t){void 0===e[t]?e[t]=i[t]:n(i[t])&&n(e[t])&&0<Object.keys(i[t]).length&&r(e[t],i[t])})}var g="undefined"!=typeof document?document:{},t={body:{},addEventListener:function(){},removeEventListener:function(){},activeElement:{blur:function(){},nodeName:""},querySelector:function(){return null},querySelectorAll:function(){return[]},getElementById:function(){return null},createEvent:function(){return{initEvent:function(){}}},createElement:function(){return{children:[],childNodes:[],style:{},setAttribute:function(){},getElementsByTagName:function(){return[]}}},createElementNS:function(){return{}},importNode:function(){return null},location:{hash:"",host:"",hostname:"",href:"",origin:"",pathname:"",protocol:"",search:""}};r(g,t);var rt="undefined"!=typeof window?window:{};r(rt,{document:t,navigator:{userAgent:""},location:{hash:"",host:"",hostname:"",href:"",origin:"",pathname:"",protocol:"",search:""},history:{replaceState:function(){},pushState:function(){},go:function(){},back:function(){}},CustomEvent:function(){return this},addEventListener:function(){},removeEventListener:function(){},getComputedStyle:function(){return{getPropertyValue:function(){return""}}},Image:function(){},Date:function(){},screen:{},setTimeout:function(){},clearTimeout:function(){},matchMedia:function(){return{}}});var l=function(t){for(var e=0;e<t.length;e+=1)this[e]=t[e];return this.length=t.length,this};function A(t,e){var i=[],n=0;if(t&&!e&&t instanceof l)return t;if(t)if("string"==typeof t){var r,s,o=t.trim();if(0<=o.indexOf("<")&&0<=o.indexOf(">")){var a="div";for(0===o.indexOf("<li")&&(a="ul"),0===o.indexOf("<tr")&&(a="tbody"),0!==o.indexOf("<td")&&0!==o.indexOf("<th")||(a="tr"),0===o.indexOf("<tbody")&&(a="table"),0===o.indexOf("<option")&&(a="select"),(s=g.createElement(a)).innerHTML=o,n=0;n<s.childNodes.length;n+=1)i.push(s.childNodes[n])}else for(r=e||"#"!==t[0]||t.match(/[ .<>:~]/)?(e||g).querySelectorAll(t.trim()):[g.getElementById(t.trim().split("#")[1])],n=0;n<r.length;n+=1)r[n]&&i.push(r[n])}else if(t.nodeType||t===rt||t===g)i.push(t);else if(0<t.length&&t[0].nodeType)for(n=0;n<t.length;n+=1)i.push(t[n]);return new l(i)}function s(t){for(var e=[],i=0;i<t.length;i+=1)-1===e.indexOf(t[i])&&e.push(t[i]);return e}A.fn=l.prototype,A.Class=l,A.Dom7=l;var e={addClass:function(t){if(void 0===t)return this;for(var e=t.split(" "),i=0;i<e.length;i+=1)for(var n=0;n<this.length;n+=1)void 0!==this[n]&&void 0!==this[n].classList&&this[n].classList.add(e[i]);return this},removeClass:function(t){for(var e=t.split(" "),i=0;i<e.length;i+=1)for(var n=0;n<this.length;n+=1)void 0!==this[n]&&void 0!==this[n].classList&&this[n].classList.remove(e[i]);return this},hasClass:function(t){return!!this[0]&&this[0].classList.contains(t)},toggleClass:function(t){for(var e=t.split(" "),i=0;i<e.length;i+=1)for(var n=0;n<this.length;n+=1)void 0!==this[n]&&void 0!==this[n].classList&&this[n].classList.toggle(e[i]);return this},attr:function(t,e){var i=arguments;if(1===arguments.length&&"string"==typeof t)return this[0]?this[0].getAttribute(t):void 0;for(var n=0;n<this.length;n+=1)if(2===i.length)this[n].setAttribute(t,e);else for(var r in t)this[n][r]=t[r],this[n].setAttribute(r,t[r]);return this},removeAttr:function(t){for(var e=0;e<this.length;e+=1)this[e].removeAttribute(t);return this},data:function(t,e){var i;if(void 0!==e){for(var n=0;n<this.length;n+=1)(i=this[n]).dom7ElementDataStorage||(i.dom7ElementDataStorage={}),i.dom7ElementDataStorage[t]=e;return this}
vendor: 10,076 bytes, line 1
1if(i=this[0])return i.dom7ElementDataStorage&&t in i.dom7ElementDataStorage?i.dom7ElementDataStorage[t]:i.getAttribute("data-"+t)||void 0},transform:function(t){for(var e=0;e<this.length;e+=1){var i=this[e].style;i.webkitTransform=t,i.transform=t}return this},transition:function(t){"string"!=typeof t&&(t+="ms");for(var e=0;e<this.length;e+=1){var i=this[e].style;i.webkitTransitionDuration=t,i.transitionDuration=t}return this},on:function(){for(var t,e=[],i=arguments.length;i--;)e[i]=arguments[i];var n=e[0],s=e[1],o=e[2],r=e[3];function a(t){var e=t.target;if(e){var i=t.target.dom7EventData||[];if(i.indexOf(t)<0&&i.unshift(t),A(e).is(s))o.apply(e,i);else for(var n=A(e).parents(),r=0;r<n.length;r+=1)A(n[r]).is(s)&&o.apply(n[r],i)}}function l(t){var e=t&&t.target&&t.target.dom7EventData||[];e.indexOf(t)<0&&e.unshift(t),o.apply(this,e)}"function"==typeof e[1]&&(n=(t=e)[0],o=t[1],r=t[2],s=void 0),r||(r=!1);for(var u,c=n.split(" "),h=0;h<this.length;h+=1){var d=this[h];if(s)for(u=0;u<c.length;u+=1){var p=c[u];d.dom7LiveListeners||(d.dom7LiveListeners={}),d.dom7LiveListeners[p]||(d.dom7LiveListeners[p]=[]),d.dom7LiveListeners[p].push({listener:o,proxyListener:a}),d.addEventListener(p,a,r)}else for(u=0;u<c.length;u+=1){var f=c[u];d.dom7Listeners||(d.dom7Listeners={}),d.dom7Listeners[f]||(d.dom7Listeners[f]=[]),d.dom7Listeners[f].push({listener:o,proxyListener:l}),d.addEventListener(f,l,r)}}return this},off:function(){for(var t,e=[],i=arguments.length;i--;)e[i]=arguments[i];var n=e[0],r=e[1],s=e[2],o=e[3];"function"==typeof e[1]&&(n=(t=e)[0],s=t[1],o=t[2],r=void 0),o||(o=!1);for(var a=n.split(" "),l=0;l<a.length;l+=1)for(var u=a[l],c=0;c<this.length;c+=1){var h=this[c],d=void 0;if(!r&&h.dom7Listeners?d=h.dom7Listeners[u]:r&&h.dom7LiveListeners&&(d=h.dom7LiveListeners[u]),d&&d.length)for(var p=d.length-1;0<=p;p-=1){var f=d[p];s&&f.listener===s||s&&f.listener&&f.listener.dom7proxy&&f.listener.dom7proxy===s?(h.removeEventListener(u,f.proxyListener,o),d.splice(p,1)):s||(h.removeEventListener(u,f.proxyListener,o),d.splice(p,1))}}return this},trigger:function(){for(var t=[],e=arguments.length;e--;)t[e]=arguments[e];for(var i=t[0].split(" "),n=t[1],r=0;r<i.length;r+=1)for(var s=i[r],o=0;o<this.length;o+=1){var a=this[o],l=void 0;try{l=new rt.CustomEvent(s,{detail:n,bubbles:!0,cancelable:!0})}catch(t){(l=g.createEvent("Event")).initEvent(s,!0,!0),l.detail=n}a.dom7EventData=t.filter(function(t,e){return 0<e}),a.dispatchEvent(l),a.dom7EventData=[],delete a.dom7EventData}return this},transitionEnd:function(e){var i,n=["webkitTransitionEnd","transitionend"],r=this;function s(t){if(t.target===this)for(e.call(this,t),i=0;i<n.length;i+=1)r.off(n[i],s)}if(e)for(i=0;i<n.length;i+=1)r.on(n[i],s);return this},outerWidth:function(t){if(0<this.length){if(t){var e=this.styles();return this[0].offsetWidth+parseFloat(e.getPropertyValue("margin-right"))+parseFloat(e.getPropertyValue("margin-left"))}return this[0].offsetWidth}return null},outerHeight:function(t){if(0<this.length){if(t){var e=this.styles();return this[0].offsetHeight+parseFloat(e.getPropertyValue("margin-top"))+parseFloat(e.getPropertyValue("margin-bottom"))}return this[0].offsetHeight}return null},offset:function(){if(0<this.length){var t=this[0],e=t.getBoundingClientRect(),i=g.body,n=t.clientTop||i.clientTop||0,r=t.clientLeft||i.clientLeft||0,s=t===rt?rt.scrollY:t.scrollTop,o=t===rt?rt.scrollX:t.scrollLeft;return{top:e.top+s-n,left:e.left+o-r}}return null},css:function(t,e){var i;if(1===arguments.length){if("string"!=typeof t){for(i=0;i<this.length;i+=1)for(var n in t)this[i].style[n]=t[n];return this}if(this[0])return rt.getComputedStyle(this[0],null).getPropertyValue(t)}if(2!==arguments.length||"string"!=typeof t)return this;for(i=0;i<this.length;i+=1)this[i].style[t]=e;return this},each:function(t){if(!t)return this;for(var e=0;e<this.length;e+=1)if(!1===t.call(this[e],e,this[e]))return this;return this},html:function(t){if(void 0===t)return this[0]?this[0].innerHTML:void 0;for(var e=0;e<this.length;e+=1)this[e].innerHTML=t;return this},text:function(t){if(void 0===t)return this[0]?this[0].textContent.trim():null;for(var e=0;e<this.length;e+=1)this[e].textContent=t;return this},is:function(t){var e,i,n=this[0];if(!n||void 0===t)return!1;if("string"==typeof t){if(n.matches)return n.matches(t);if(n.webkitMatchesSelector)return n.webkitMatchesSelector(t);if(n.msMatchesSelector)return n.msMatchesSelector(t);for(e=A(t),i=0;i<e.length;i+=1)if(e[i]===n)return!0;return!1}if(t===g)return n===g;if(t===rt)return n===rt;if(t.nodeType||t instanceof l){for(e=t.nodeType?[t]:t,i=0;i<e.length;i+=1)if(e[i]===n)return!0;return!1}return!1},index:function(){var t,e=this[0];if(e){for(t=0;null!==(e=e.previousSibling);)1===e.nodeType&&(t+=1);return t}},eq:function(t){if(void 0===t)return this;var e,i=this.length;return new l(i-1<t?[]:t<0?(e=i+t)<0?[]:[this[e]]:[this[t]])},append:function(){for(var t,e=[],i=arguments.length;i--;)e[i]=arguments[i];for(var n=0;n<e.length;n+=1){t=e[n];for(var r=0;r<this.length;r+=1)if("string"==typeof t){var s=g.createElement("div");for(s.innerHTML=t;s.firstChild;)this[r].appendChild(s.firstChild)}else if(t instanceof l)for(var o=0;o<t.length;o+=1)this[r].appendChild(t[o]);else this[r].appendChild(t)}return this},prepend:function(t){var e,i;for(e=0;e<this.length;e+=1)if("string"==typeof t){var n=g.createElement("div");for(n.innerHTML=t,i=n.childNodes.length-1;0<=i;i-=1)this[e].insertBefore(n.childNodes[i],this[e].childNodes[0])}else if(t instanceof l)for(i=0;i<t.length;i+=1)this[e].insertBefore(t[i],this[e].childNodes[0]);else this[e].insertBefore(t,this[e].childNodes[0]);return this},next:function(t){return 0<this.length?t?this[0].nextElementSibling&&A(this[0].nextElementSibling).is(t)?new l([this[0].nextElementSibling]):new l([]):this[0].nextElementSibling?new l([this[0].nextElementSibling]):new l([]):new l([])},nextAll:function(t){var e=[],i=this[0];if(!i)return new l([]);for(;i.nextElementSibling;){var n=i.nextElementSibling;t?A(n).is(t)&&e.push(n):e.push(n),i=n}return new l(e)},prev:function(t){if(0<this.length){var e=this[0];return t?e.previousElementSibling&&A(e.previousElementSibling).is(t)?new l([e.previousElementSibling]):new l([]):e.previousElementSibling?new l([e.previousElementSibling]):new l([])}return new l([])},prevAll:function(t){var e=[],i=this[0];if(!i)return new l([]);for(;i.previousElementSibling;){var n=i.previousElementSibling;t?A(n).is(t)&&e.push(n):e.push(n),i=n}return new l(e)},parent:function(t){for(var e=[],i=0;i<this.length;i+=1)null!==this[i].parentNode&&(t?A(this[i].parentNode).is(t)&&e.push(this[i].parentNode):e.push(this[i].parentNode));return A(s(e))},parents:function(t){for(var e=[],i=0;i<this.length;i+=1)for(var n=this[i].parentNode;n;)t?A(n).is(t)&&e.push(n):e.push(n),n=n.parentNode;return A(s(e))},closest:function(t){var e=this;return void 0===t?new l([]):(e.is(t)||(e=e.parents(t).eq(0)),e)},find:function(t){for(var e=[],i=0;i<this.length;i+=1)for(var n=this[i].querySelectorAll(t),r=0;r<n.length;r+=1)e.push(n[r]);return new l(e)},children:function(t){for(var e=[],i=0;i<this.length;i+=1)for(var n=this[i].childNodes,r=0;r<n.length;r+=1)t?1===n[r].nodeType&&A(n[r]).is(t)&&e.push(n[r]):1===n[r].nodeType&&e.push(n[r]);return new l(s(e))},filter:function(t){for(var e=[],i=0;i<this.length;i+=1)t.call(this[i],i,this[i])&&e.push(this[i]);return new l(e)},remove:function(){for(var t=0;t<this.length;t+=1)this[t].parentNode&&this[t].parentNode.removeChild(this[t]);return this},add:function(){for(var t=[],e=arguments.length;e--;)t[e]=arguments[e];var i,n;for(i=0;i<t.length;i+=1){var r=A(t[i]);for(n=0;n<r.length;n+=1)this[this.length]=r[n],this.length+=1}return this},styles:function(){return this[0]?rt.getComputedStyle(this[0],null):{}}};Object.keys(e).forEach(function(t){A.fn[t]=A.fn[t]||e[t]});var st={deleteProps:function(t){var e=t;Object.keys(e).forEach(function(t){try{e[t]=null}catch(t){}try{delete e[t]}catch(t){}})},nextTick:function(t,e){return void 0===e&&(e=0),setTimeout(t,e)},now:function(){return Date.now()},getTranslate:function(t,e){var i,n,r;void 0===e&&(e="x");var s=rt.getComputedStyle(t,null);return rt.WebKitCSSMatrix?(6<(n=s.transform||s.webkitTransform).split(",").length&&(n=n.split(", ").map(function(t){return t.replace(",",".")}).join(", ")),r=new rt.WebKitCSSMatrix("none"===n?"":n)):i=(r=s.MozTransform||s.OTransform||s.MsTransform||s.msTransform||s.transform||s.getPropertyValue("transform").replace("translate(","matrix(1, 0, 0, 1,")).toString().split(","),"x"===e&&(n=rt.WebKitCSSMatrix?r.m41:16===i.length?parseFloat(i[12]):parseFloat(i[4])),"y"===e&&(n=rt.WebKitCSSMatrix?r.m42:16===i.length?parseFloat(i[13]):parseFloat(i[5])),n||0},parseUrlQuery:function(t){var e,i,n,r,s={},o=t||rt.location.href;if("string"==typeof o&&o.length)for(r=(i=(o=-1<o.indexOf("?")?o.replace(/\S*\?/,""):"").split("&").filter(function(t){return""!==t})).length,e=0;e<r;e+=1)n=i[e].replace(/#\S+/g,"").split("="),s[decodeURIComponent(n[0])]=void 0===n[1]?void 0:decodeURIComponent(n[1])||"";return s},isObject:function(t){return"object"==typeof t&&null!==t&&t.constructor&&t.constructor===Object},extend:function(){for(var t=[],e=arguments.length;e--;)t[e]=arguments[e];for(var i=Object(t[0]),n=1;n<t.length;n+=1){var r=t[n];if(null!=r)for(var s=Object.keys(Object(r)),o=0,a=s.length;o<a;o+=1){var l=s[o],u=Object.getOwnPropertyDescriptor(r,l);void 0!==u&&u.enumerable&&(st.isObject(i[l])&&st.isObject(r[l])?st.extend(i[l],r[l]):!st.isObject(i[l])&&st.isObject(r[l])?(i[l]={},st.extend(i[l],r[l])):i[l]=r[l])}}return i}},C={touch:!!("ontouchstart"in rt||rt.DocumentTouch&&g instanceof rt.DocumentTouch),pointerEvents:!!rt.PointerEvent&&"maxTouchPoints"in rt.navigator&&0<=rt.navigator.maxTouchPoints,observer:"MutationObserver"in rt||"WebkitMutationObserver"in rt,passiveListener:function(){var t=!1;try{var e=Object.defineProperty({},"passive",{get:function(){t=!0}});rt.addEventListener("testPassiveListener",null,e)}catch(t){}return t}(),gestures:"ongesturestart"in rt},i=function(t){void 0===t&&(t={});var e=this;e.params=t,e.eventsListeners={}
1,e.params&&e.params.on&&Object.keys(e.params.on).forEach(function(t){e.on(t,e.params.on[t])})},o={components:{configurable:!0}};i.prototype.on=function(t,e,i){var n=this;if("function"!=typeof e)return n;var r=i?"unshift":"push";return t.split(" ").forEach(function(t){n.eventsListeners[t]||(n.eventsListeners[t]=[]),n.eventsListeners[t][r](e)}),n},i.prototype.once=function(i,n,t){var r=this;if("function"!=typeof n)return r;function s(){for(var t=[],e=arguments.length;e--;)t[e]=arguments[e];r.off(i,s),s.f7proxy&&delete s.f7proxy,n.apply(r,t)}return s.f7proxy=n,r.on(i,s,t)},i.prototype.off=function(t,n){var r=this;return r.eventsListeners&&t.split(" ").forEach(function(i){void 0===n?r.eventsListeners[i]=[]:r.eventsListeners[i]&&r.eventsListeners[i].length&&r.eventsListeners[i].forEach(function(t,e){(t===n||t.f7proxy&&t.f7proxy===n)&&r.eventsListeners[i].splice(e,1)})}),r},i.prototype.emit=function(){for(var t=[],e=arguments.length;e--;)t[e]=arguments[e];var i,n,r,s=this;return s.eventsListeners&&(r="string"==typeof t[0]||Array.isArray(t[0])?(i=t[0],n=t.slice(1,t.length),s):(i=t[0].events,n=t[0].data,t[0].context||s),(Array.isArray(i)?i:i.split(" ")).forEach(function(t){if(s.eventsListeners&&s.eventsListeners[t]){var e=[];s.eventsListeners[t].forEach(function(t){e.push(t)}),e.forEach(function(t){t.apply(r,n)})}})),s},i.prototype.useModulesParams=function(i){var n=this;n.modules&&Object.keys(n.modules).forEach(function(t){var e=n.modules[t];e.params&&st.extend(i,e.params)})},i.prototype.useModules=function(n){void 0===n&&(n={});var r=this;r.modules&&Object.keys(r.modules).forEach(function(t){var i=r.modules[t],e=n[t]||{};i.instance&&Object.keys(i.instance).forEach(function(t){var e=i.instance[t];r[t]="function"==typeof e?e.bind(r):e}),i.on&&r.on&&Object.keys(i.on).forEach(function(t){r.on(t,i.on[t])}),i.create&&i.create.bind(r)(e)})},o.components.set=function(t){this.use&&this.use(t)},i.installModule=function(e){for(var t=[],i=arguments.length-1;0<i--;)t[i]=arguments[i+1];var n=this;n.prototype.modules||(n.prototype.modules={});var r=e.name||Object.keys(n.prototype.modules).length+"_"+st.now();return(n.prototype.modules[r]=e).proto&&Object.keys(e.proto).forEach(function(t){n.prototype[t]=e.proto[t]}),e.static&&Object.keys(e.static).forEach(function(t){n[t]=e.static[t]}),e.install&&e.install.apply(n,t),n},i.use=function(t){for(var e=[],i=arguments.length-1;0<i--;)e[i]=arguments[i+1];var n=this;return Array.isArray(t)?(t.forEach(function(t){return n.installModule(t)}),n):n.installModule.apply(n,[t].concat(e))},Object.defineProperties(i,o);var a,u,c,h,d,p,f,m,v,y,b,w,_,x,T,S={updateSize:function(){var t,e,i=this.$el;t=void 0!==this.params.width?this.params.width:i[0].clientWidth,e=void 0!==this.params.height?this.params.height:i[0].clientHeight,0===t&&this.isHorizontal()||0===e&&this.isVertical()||(t=t-parseInt(i.css("padding-left"),10)-parseInt(i.css("padding-right"),10),e=e-parseInt(i.css("padding-top"),10)-parseInt(i.css("padding-bottom"),10),st.extend(this,{width:t,height:e,size:this.isHorizontal()?t:e}))},updateSlides:function(){var e=this.params,t=this.$wrapperEl,i=this.size,n=this.rtlTranslate,r=this.wrongRTL,s=this.virtual&&e.virtual.enabled,o=s?this.virtual.slides.length:this.slides.length,a=t.children("."+this.params.slideClass),l=s?this.virtual.slides.length:a.length,u=[],c=[],h=[];function d(t){return!e.cssMode||t!==a.length-1}var p=e.slidesOffsetBefore;"function"==typeof p&&(p=e.slidesOffsetBefore.call(this));var f=e.slidesOffsetAfter;"function"==typeof f&&(f=e.slidesOffsetAfter.call(this));var g=this.snapGrid.length,m=this.snapGrid.length,v=e.spaceBetween,y=-p,b=0,w=0;if(void 0!==i){var _,x;"string"==typeof v&&0<=v.indexOf("%")&&(v=parseFloat(v.replace("%",""))/100*i),this.virtualSize=-v,n?a.css({marginLeft:"",marginTop:""}):a.css({marginRight:"",marginBottom:""}),1<e.slidesPerColumn&&(_=Math.floor(l/e.slidesPerColumn)===l/this.params.slidesPerColumn?l:Math.ceil(l/e.slidesPerColumn)*e.slidesPerColumn,"auto"!==e.slidesPerView&&"row"===e.slidesPerColumnFill&&(_=Math.max(_,e.slidesPerView*e.slidesPerColumn)));for(var T,S=e.slidesPerColumn,C=_/S,E=Math.floor(l/e.slidesPerColumn),k=0;k<l;k+=1){x=0;var I=a.eq(k);if(1<e.slidesPerColumn){var D=void 0,A=void 0,P=void 0;if("row"===e.slidesPerColumnFill&&1<e.slidesPerGroup){var M=Math.floor(k/(e.slidesPerGroup*e.slidesPerColumn)),N=k-e.slidesPerColumn*e.slidesPerGroup*M,O=0===M?e.slidesPerGroup:Math.min(Math.ceil((l-M*S*e.slidesPerGroup)/S),e.slidesPerGroup);D=(A=N-(P=Math.floor(N/O))*O+M*e.slidesPerGroup)+P*_/S,I.css({"-webkit-box-ordinal-group":D,"-moz-box-ordinal-group":D,"-ms-flex-order":D,"-webkit-order":D,order:D})}else"column"===e.slidesPerColumnFill?(P=k-(A=Math.floor(k/S))*S,(E<A||A===E&&P===S-1)&&(P+=1)>=S&&(P=0,A+=1)):A=k-(P=Math.floor(k/C))*C;
1I.css("margin-"+(this.isHorizontal()?"top":"left"),0!==P&&e.spaceBetween&&e.spaceBetween+"px")}if("none"!==I.css("display")){if("auto"===e.slidesPerView){var L=rt.getComputedStyle(I[0],null),R=I[0].style.transform,F=I[0].style.webkitTransform;if(R&&(I[0].style.transform="none"),F&&(I[0].style.webkitTransform="none"),e.roundLengths)x=this.isHorizontal()?I.outerWidth(!0):I.outerHeight(!0);else if(this.isHorizontal()){var z=parseFloat(L.getPropertyValue("width")),B=parseFloat(L.getPropertyValue("padding-left")),$=parseFloat(L.getPropertyValue("padding-right")),j=parseFloat(L.getPropertyValue("margin-left")),H=parseFloat(L.getPropertyValue("margin-right")),q=L.getPropertyValue("box-sizing");x=q&&"border-box"===q?z+j+H:z+B+$+j+H}else{var V=parseFloat(L.getPropertyValue("height")),U=parseFloat(L.getPropertyValue("padding-top")),W=parseFloat(L.getPropertyValue("padding-bottom")),K=parseFloat(L.getPropertyValue("margin-top")),G=parseFloat(L.getPropertyValue("margin-bottom")),Y=L.getPropertyValue("box-sizing");x=Y&&"border-box"===Y?V+K+G:V+U+W+K+G}R&&(I[0].style.transform=R),F&&(I[0].style.webkitTransform=F),e.roundLengths&&(x=Math.floor(x))}else x=(i-(e.slidesPerView-1)*v)/e.slidesPerView,e.roundLengths&&(x=Math.floor(x)),a[k]&&(this.isHorizontal()?a[k].style.width=x+"px":a[k].style.height=x+"px");a[k]&&(a[k].swiperSlideSize=x),h.push(x),e.centeredSlides?(y=y+x/2+b/2+v,0===b&&0!==k&&(y=y-i/2-v),0===k&&(y=y-i/2-v),Math.abs(y)<.001&&(y=0),e.roundLengths&&(y=Math.floor(y)),w%e.slidesPerGroup==0&&u.push(y),c.push(y)):(e.roundLengths&&(y=Math.floor(y)),(w-Math.min(this.params.slidesPerGroupSkip,w))%this.params.slidesPerGroup==0&&u.push(y),c.push(y),y=y+x+v),this.virtualSize+=x+v,b=x,w+=1}}if(this.virtualSize=Math.max(this.virtualSize,i)+f,n&&r&&("slide"===e.effect||"coverflow"===e.effect)&&t.css({width:this.virtualSize+e.spaceBetween+"px"}),e.setWrapperSize&&(this.isHorizontal()?t.css({width:this.virtualSize+e.spaceBetween+"px"}):t.css({height:this.virtualSize+e.spaceBetween+"px"})),1<e.slidesPerColumn&&(this.virtualSize=(x+e.spaceBetween)*_,this.virtualSize=Math.ceil(this.virtualSize/e.slidesPerColumn)-e.spaceBetween,this.isHorizontal()?t.css({width:this.virtualSize+e.spaceBetween+"px"}):t.css({height:this.virtualSize+e.spaceBetween+"px"}),e.centeredSlides)){T=[];for(var X=0;X<u.length;X+=1){var Q=u[X];e.roundLengths&&(Q=Math.floor(Q)),u[X]<this.virtualSize+u[0]&&T.push(Q)}u=T}if(!e.centeredSlides){T=[];for(var J=0;J<u.length;J+=1){var Z=u[J];e.roundLengths&&(Z=Math.floor(Z)),u[J]<=this.virtualSize-i&&T.push(Z)}u=T,1<Math.floor(this.virtualSize-i)-Math.floor(u[u.length-1])&&u.push(this.virtualSize-i)}if(0===u.length&&(u=[0]),0!==e.spaceBetween&&(this.isHorizontal()?n?a.filter(d).css({marginLeft:v+"px"}):a.filter(d).css({marginRight:v+"px"}):a.filter(d).css({marginBottom:v+"px"})),e.centeredSlides&&e.centeredSlidesBounds){var tt=0;h.forEach(function(t){tt+=t+(e.spaceBetween?e.spaceBetween:0)});var et=(tt-=e.spaceBetween)-i;u=u.map(function(t){return t<0?-p:et<t?et+f:t})}if(e.centerInsufficientSlides){var it=0;if(h.forEach(function(t){it+=t+(e.spaceBetween?e.spaceBetween:0)}),(it-=e.spaceBetween)<i){var nt=(i-it)/2;u.forEach(function(t,e){u[e]=t-nt}),c.forEach(function(t,e){c[e]=t+nt})}}st.extend(this,{slides:a,snapGrid:u,slidesGrid:c,slidesSizesGrid:h}),l!==o&&this.emit("slidesLengthChange"),u.length!==g&&(this.params.watchOverflow&&this.checkOverflow(),this.emit("snapGridLengthChange")),c.length!==m&&this.emit("slidesGridLengthChange"),(e.watchSlidesProgress||e.watchSlidesVisibility)&&this.updateSlidesOffset()}},updateAutoHeight:function(t){var e,i=[],n=0;if("number"==typeof t?this.setTransition(t):!0===t&&this.setTransition(this.params.speed),"auto"!==this.params.slidesPerView&&1<this.params.slidesPerView)if(this.params.centeredSlides)this.visibleSlides.each(function(t,e){i.push(e)});else for(e=0;e<Math.ceil(this.params.slidesPerView);e+=1){var r=this.activeIndex+e;if(r>this.slides.length)break;i.push(this.slides.eq(r)[0])}else i.push(this.slides.eq(this.activeIndex)[0]);for(e=0;e<i.length;e+=1)if(void 0!==i[e]){var s=i[e].offsetHeight;n=n<s?s:n}n&&this.$wrapperEl.css("height",n+"px")},updateSlidesOffset:function(){for(var t=this.slides,e=0;e<t.length;e+=1)t[e].swiperSlideOffset=this.isHorizontal()?t[e].offsetLeft:t[e].offsetTop},updateSlidesProgress:function(t){void 0===t&&(t=this&&this.translate||0);var e=this.params,i=this.slides,n=this.rtlTranslate;if(0!==i.length){void 0===i[0].swiperSlideOffset&&this.updateSlidesOffset();var r=-t;n&&(r=t),i.removeClass(e.slideVisibleClass),this.visibleSlidesIndexes=[],this.visibleSlides=[];for(var s=0;s<i.length;s+=1){var o=i[s],a=(r+(e.centeredSlides?this.minTranslate():0)-o.swiperSlideOffset)/(o.swiperSlideSize+e.spaceBetween);if(e.watchSlidesVisibility||e.centeredSlides&&e.autoHeight){var l=-(r-o.swiperSlideOffset),u=l+this.slidesSizesGrid[s];(0<=l&&l<this.size-1||1<u&&u<=this.size||l<=0&&u>=this.size)&&(this.visibleSlides.push(o),this.visibleSlidesIndexes.push(s),i.eq(s).addClass(e.slideVisibleClass))}o.progress=n?-a:a}this.visibleSlides=A(this.visibleSlides)}},updateProgress:function(t){if(void 0===t){var e=this.rtlTranslate?-1:1;t=this&&this.translate&&this.translate*e||0}var i=this.params,n=this.maxTranslate()-this.minTranslate(),r=this.progress,s=this.isBeg
1inning,o=this.isEnd,a=s,l=o;o=0===n?s=!(r=0):(s=(r=(t-this.minTranslate())/n)<=0,1<=r),st.extend(this,{progress:r,isBeginning:s,isEnd:o}),(i.watchSlidesProgress||i.watchSlidesVisibility||i.centeredSlides&&i.autoHeight)&&this.updateSlidesProgress(t),s&&!a&&this.emit("reachBeginning toEdge"),o&&!l&&this.emit("reachEnd toEdge"),(a&&!s||l&&!o)&&this.emit("fromEdge"),this.emit("progress",r)},updateSlidesClasses:function(){var t,e=this.slides,i=this.params,n=this.$wrapperEl,r=this.activeIndex,s=this.realIndex,o=this.virtual&&i.virtual.enabled;e.removeClass(i.slideActiveClass+" "+i.slideNextClass+" "+i.slidePrevClass+" "+i.slideDuplicateActiveClass+" "+i.slideDuplicateNextClass+" "+i.slideDuplicatePrevClass),(t=o?this.$wrapperEl.find("."+i.slideClass+'[data-swiper-slide-index="'+r+'"]'):e.eq(r)).addClass(i.slideActiveClass),i.loop&&(t.hasClass(i.slideDuplicateClass)?n.children("."+i.slideClass+":not(."+i.slideDuplicateClass+')[data-swiper-slide-index="'+s+'"]').addClass(i.slideDuplicateActiveClass):n.children("."+i.slideClass+"."+i.slideDuplicateClass+'[data-swiper-slide-index="'+s+'"]').addClass(i.slideDuplicateActiveClass));var a=t.nextAll("."+i.slideClass).eq(0).addClass(i.slideNextClass);i.loop&&0===a.length&&(a=e.eq(0)).addClass(i.slideNextClass);var l=t.prevAll("."+i.slideClass).eq(0).addClass(i.slidePrevClass);i.loop&&0===l.length&&(l=e.eq(-1)).addClass(i.slidePrevClass),i.loop&&(a.hasClass(i.slideDuplicateClass)?n.children("."+i.slideClass+":not(."+i.slideDuplicateClass+')[data-swiper-slide-index="'+a.attr("data-swiper-slide-index")+'"]').addClass(i.slideDuplicateNextClass):n.children("."+i.slideClass+"."+i.slideDuplicateClass+'[data-swiper-slide-index="'+a.attr("data-swiper-slide-index")+'"]').addClass(i.slideDuplicateNextClass),l.hasClass(i.slideDuplicateClass)?n.children("."+i.slideClass+":not(."+i.slideDuplicateClass+')[data-swiper-slide-index="'+l.attr("data-swiper-slide-index")+'"]').addClass(i.slideDuplicatePrevClass):n.children("."+i.slideClass+"."+i.slideDuplicateClass+'[data-swiper-slide-index="'+l.attr("data-swiper-slide-index")+'"]').addClass(i.slideDuplicatePrevClass))},updateActiveIndex:function(t){var e,i=this.rtlTranslate?this.translate:-this.translate,n=this.slidesGrid,r=this.snapGrid,s=this.params,o=this.activeIndex,a=this.realIndex,l=this.snapIndex,u=t;if(void 0===u){for(var c=0;c<n.length;c+=1)void 0!==n[c+1]?i>=n[c]&&i<n[c+1]-(n[c+1]-n[c])/2?u=c:i>=n[c]&&i<n[c+1]&&(u=c+1):i>=n[c]&&(u=c);s.normalizeSlideIndex&&(u<0||void 0===u)&&(u=0)}if(0<=r.indexOf(i))e=r.indexOf(i);else{var h=Math.min(s.slidesPerGroupSkip,u);e=h+Math.floor((u-h)/s.slidesPerGroup)}if(e>=r.length&&(e=r.length-1),u!==o){var d=parseInt(this.slides.eq(u).attr("data-swiper-slide-index")||u,10);st.extend(this,{snapIndex:e,realIndex:d,previousIndex:o,activeIndex:u}),this.emit("activeIndexChange"),this.emit("snapIndexChange"),a!==d&&this.emit("realIndexChange"),(this.initialized||this.params.runCallbacksOnInit)&&this.emit("slideChange")}else e!==l&&(this.snapIndex=e,this.emit("snapIndexChange"))},updateClickedSlide:function(t){var e=this.params,i=A(t.target).closest("."+e.slideClass)[0],n=!1;if(i)for(var r=0;r<this.slides.length;r+=1)this.slides[r]===i&&(n=!0);if(!i||!n)return this.clickedSlide=void 0,void(this.clickedIndex=void 0);this.clickedSlide=i,this.virtual&&this.params.virtual.enabled?this.clickedIndex=parseInt(A(i).attr("data-swiper-slide-index"),10):this.clickedIndex=A(i).index(),e.slideToClickedSlide&&void 0!==this.clickedIndex&&this.clickedIndex!==this.activeIndex&&this.slideToClickedSlide()}},E={getTranslate:function(t){void 0===t&&(t=this.isHorizontal()?"x":"y");var e=this.params,i=this.rtlTranslate,n=this.translate,r=this.$wrapperEl;if(e.virtualTranslate)return i?-n:n;if(e.cssMode)return n;var s=st.getTranslate(r[0],t);return i&&(s=-s),s||0},setTranslate:function(t,e){var i=this.rtlTranslate,n=this.params,r=this.$wrapperEl,s=this.wrapperEl,o=this.progress,a=0,l=0;this.isHorizontal()?a=i?-t:t:l=t,n.roundLengths&&(a=Math.floor(a),l=Math.floor(l)),n.cssMode?s[this.isHorizontal()?"scrollLeft":"scrollTop"]=this.isHorizontal()?-a:-l:n.virtualTranslate||r.transform("translate3d("+a+"px, "+l+"px, 0px)"),this.previousTranslate=this.translate,this.translate=this.isHorizontal()?a:l;var u=this.maxTranslate()-this.minTranslate();(0===u?0:(t-this.minTranslate())/u)!==o&&this.updateProgress(t),this.emit
1("setTranslate",this.translate,e)},minTranslate:function(){return-this.snapGrid[0]},maxTranslate:function(){return-this.snapGrid[this.snapGrid.length-1]},translateTo:function(t,e,i,n,r){var s;void 0===t&&(t=0),void 0===e&&(e=this.params.speed),void 0===i&&(i=!0),void 0===n&&(n=!0);var o=this,a=o.params,l=o.wrapperEl;if(o.animating&&a.preventInteractionOnTransition)return!1;var u,c=o.minTranslate(),h=o.maxTranslate();if(u=n&&c<t?c:n&&t<h?h:t,o.updateProgress(u),a.cssMode){var d=o.isHorizontal();return 0===e?l[d?"scrollLeft":"scrollTop"]=-u:l.scrollTo?l.scrollTo(((s={})[d?"left":"top"]=-u,s.behavior="smooth",s)):l[d?"scrollLeft":"scrollTop"]=-u,!0}return 0===e?(o.setTransition(0),o.setTranslate(u),i&&(o.emit("beforeTransitionStart",e,r),o.emit("transitionEnd"))):(o.setTransition(e),o.setTranslate(u),i&&(o.emit("beforeTransitionStart",e,r),o.emit("transitionStart")),o.animating||(o.animating=!0,o.onTranslateToWrapperTransitionEnd||(o.onTranslateToWrapperTransitionEnd=function(t){o&&!o.destroyed&&t.target===this&&(o.$wrapperEl[0].removeEventListener("transitionend",o.onTranslateToWrapperTransitionEnd),o.$wrapperEl[0].removeEventListener("webkitTransitionEnd",o.onTranslateToWrapperTransitionEnd),o.onTranslateToWrapperTransitionEnd=null,delete o.onTranslateToWrapperTransitionEnd,i&&o.emit("transitionEnd"))}),o.$wrapperEl[0].addEventListener("transitionend",o.onTranslateToWrapperTransitionEnd),o.$wrapperEl[0].addEventListener("webkitTransitionEnd",o.onTranslateToWrapperTransitionEnd))),!0}},k={slideTo:function(t,e,i,n){var r;void 0===t&&(t=0),void 0===e&&(e=this.params.speed),void 0===i&&(i=!0);var s=this,o=t;o<0&&(o=0);var a=s.params,l=s.snapGrid,u=s.slidesGrid,c=s.previousIndex,h=s.activeIndex,d=s.rtlTranslate,p=s.wrapperEl;if(s.animating&&a.preventInteractionOnTransition)return!1;var f=Math.min(s.params.slidesPerGroupSkip,o),g=f+Math.floor((o-f)/s.params.slidesPerGroup);g>=l.length&&(g=l.length-1),(h||a.initialSlide||0)===(c||0)&&i&&s.emit("beforeSlideChangeStart");var m,v=-l[g];if(s.updateProgress(v),a.normalizeSlideIndex)for(var y=0;y<u.length;y+=1)-Math.floor(100*v)>=Math.floor(100*u[y])&&(o=y);if(s.initialized&&o!==h){if(!s.allowSlideNext&&v<s.translate&&v<s.minTranslate())return!1;if(!s.allowSlidePrev&&v>s.translate&&v>s.maxTranslate()&&(h||0)!==o)return!1}if(m=h<o?"next":o<h?"prev":"reset",d&&-v===s.translate||!d&&v===s.translate)return s.updateActiveIndex(o),a.autoHeight&&s.updateAutoHeight(),s.updateSlidesClasses(),"slide"!==a.effect&&s.setTranslate(v),"reset"!==m&&(s.transitionStart(i,m),s.transitionEnd(i,m)),!1;if(a.cssMode){var b=s.isHorizontal(),w=-v;return d&&(w=p.scrollWidth-p.offsetWidth-w),0===e?p[b?"scrollLeft":"scrollTop"]=w:p.scrollTo?p.scrollTo(((r={})[b?"left":"top"]=w,r.behavior="smooth",r)):p[b?"scrollLeft":"scrollTop"]=w,!0}return 0===e?(s.setTransition(0),s.setTranslate(v),s.updateActiveIndex(o),s.updateSlidesClasses(),s.emit("beforeTransitionStart",e,n),s.transitionStart(i,m),s.transitionEnd(i,m)):(s.setTransition(e),s.setTranslate(v),s.updateActiveIndex(o),s.updateSlidesClasses(),s.emit("beforeTransitionStart",e,n),s.transitionStart(i,m),s.animating||(s.animating=!0,s.onSlideToWrapperTransitionEnd||(s.onSlideToWrapperTransitionEnd=function(t){s&&!s.destroyed&&t.target===this&&(s.$wrapperEl[0].removeEventListener("transitionend",s.onSlideToWrapperTransitionEnd),s.$wrapperEl[0].removeEventListener("webkitTransitionEnd",s.onSlideToWrapperTransitionEnd),s.onSlideToWrapperTransitionEnd=null,delete s.onSlideToWrapperTransitionEnd,s.transitionEnd(i,m))}),s.$wrapperEl[0].addEventListener("transitionend",s.onSlideToWrapperTransitionEnd),s.$wrapperEl[0].addEventListener("webkitTransitionEnd",s.onSlideToWrapperTransitionEnd))),!0},slideToLoop:function(t,e,i,n){void 0===t&&(t=0),void 0===e&&(e=this.params.speed),void 0===i&&(i=!0);var r=t;return this.params.loop&&(r+=this.loopedSlides),this.slideTo(r,e,i,n)},slideNext:function(t,e,i){void 0===t&&(t=this.params.speed),void 0===e&&(e=!0);var n=this.params,r=this.animating,s=this.activeIndex<n.slidesPerGroupSkip?1:n.slidesPerGroup;if(n.loop){if(r)return!1;this.loopFix(),this._clientLeft=this.$wrapperEl[0].clientLeft}return this.slideTo(this.activeIndex+s,t,e,i)}
1,slidePrev:function(t,e,i){void 0===t&&(t=this.params.speed),void 0===e&&(e=!0);var n=this.params,r=this.animating,s=this.snapGrid,o=this.slidesGrid,a=this.rtlTranslate;if(n.loop){if(r)return!1;this.loopFix(),this._clientLeft=this.$wrapperEl[0].clientLeft}function l(t){return t<0?-Math.floor(Math.abs(t)):Math.floor(t)}var u,c=l(a?this.translate:-this.translate),h=s.map(function(t){return l(t)}),d=(o.map(function(t){return l(t)}),s[h.indexOf(c)],s[h.indexOf(c)-1]);return void 0===d&&n.cssMode&&s.forEach(function(t){!d&&t<=c&&(d=t)}),void 0!==d&&(u=o.indexOf(d))<0&&(u=this.activeIndex-1),this.slideTo(u,t,e,i)},slideReset:function(t,e,i){return void 0===t&&(t=this.params.speed),void 0===e&&(e=!0),this.slideTo(this.activeIndex,t,e,i)},slideToClosest:function(t,e,i,n){void 0===t&&(t=this.params.speed),void 0===e&&(e=!0),void 0===n&&(n=.5);var r=this.activeIndex,s=Math.min(this.params.slidesPerGroupSkip,r),o=s+Math.floor((r-s)/this.params.slidesPerGroup),a=this.rtlTranslate?this.translate:-this.translate;if(a>=this.snapGrid[o]){var l=this.snapGrid[o];a-l>(this.snapGrid[o+1]-l)*n&&(r+=this.params.slidesPerGroup)}else{var u=this.snapGrid[o-1];a-u<=(this.snapGrid[o]-u)*n&&(r-=this.params.slidesPerGroup)}return r=Math.max(r,0),r=Math.min(r,this.slidesGrid.length-1),this.slideTo(r,t,e,i)},slideToClickedSlide:function(){var t,e=this,i=e.params,n=e.$wrapperEl,r="auto"===i.slidesPerView?e.slidesPerViewDynamic():i.slidesPerView,s=e.clickedIndex;if(i.loop){if(e.animating)return;t=parseInt(A(e.clickedSlide).attr("data-swiper-slide-index"),10),i.centeredSlides?s<e.loopedSlides-r/2||s>e.slides.length-e.loopedSlides+r/2?(e.loopFix(),s=n.children("."+i.slideClass+'[data-swiper-slide-index="'+t+'"]:not(.'+i.slideDuplicateClass+")").eq(0).index(),st.nextTick(function(){e.slideTo(s)})):e.slideTo(s):s>e.slides.length-r?(e.loopFix(),s=n.children("."+i.slideClass+'[data-swiper-slide-index="'+t+'"]:not(.'+i.slideDuplicateClass+")").eq(0).index(),st.nextTick(function(){e.slideTo(s)})):e.slideTo(s)}else e.slideTo(s)}},I={loopCreate:function(){var n=this,t=n.params,e=n.$wrapperEl;e.children("."+t.slideClass+"."+t.slideDuplicateClass).remove();var r=e.children("."+t.slideClass);if(t.loopFillGroupWithBlank){var i=t.slidesPerGroup-r.length%t.slidesPerGroup;if(i!==t.slidesPerGroup){for(var s=0;s<i;s+=1){var o=A(g.createElement("div")).addClass(t.slideClass+" "+t.slideBlankClass);e.append(o)}r=e.children("."+t.slideClass)}}"auto"!==t.slidesPerView||t.loopedSlides||(t.loopedSlides=r.length),n.loopedSlides=Math.ceil(parseFloat(t.loopedSlides||t.slidesPerView,10)),n.loopedSlides+=t.loopAdditionalSlides,n.loopedSlides>r.length&&(n.loopedSlides=r.length);var a=[],l=[];r.each(function(t,e){var i=A(e);t<n.loopedSlides&&l.push(e),t<r.length&&t>=r.length-n.loopedSlides&&a.push(e),i.attr("data-swiper-slide-index",t)});for(var u=0;u<l.length;u+=1)e.append(A(l[u].cloneNode(!0)).addClass(t.slideDuplicateClass));for(var c=a.length-1;0<=c;c-=1)e.prepend(A(a[c].cloneNode(!0)).addClass(t.slideDuplicateClass))},loopFix:function(){this.emit("beforeLoopFix");var t,e=this.activeIndex,i=this.slides,n=this.loopedSlides,r=this.allowSlidePrev,s=this.allowSlideNext,o=this.snapGrid,a=this.rtlTranslate;this.allowSlidePrev=!0,this.allowSlideNext=!0;var l=-o[e]-this.getTranslate();e<n?(t=i.length-3*n+e,t+=n,this.slideTo(t,0,!1,!0)&&0!==l&&this.setTranslate((a?-this.translate:this.translate)-l)):e>=i.length-n&&(t=-i.length+e+n,t+=n,this.slideTo(t,0,!1,!0)&&0!==l&&this.setTranslate((a?-this.translate:this.translate)-l)),this.allowSlidePrev=r,this.allowSlideNext=s,this.emit("loopFix")},loopDestroy:function(){var t=this.$wrapperEl,e=this.params,i=this.slides;t.children("."+e.slideClass+"."+e.slideDuplicateClass+",."+e.slideClass+"."+e.slideBlankClass).remove(),i.removeAttr("data-swiper-slide-index")}},D={setGrabCursor:function(t){if(!(C.touch||!this.params.simulateTouch||this.params.watchOverflow&&this.isLocked||this.params.cssMode)){var e=this.el;e.style.cursor="move",e.style.cursor=t?"-webkit-grabbing":"-webkit-grab",e.style.cursor=t?"-moz-grabbin":"-moz-grab",e.style.cursor=t?"grabbing":"grab"}},unsetGrabCursor:function(){C.touch||this.params.watchOverflow&&this.isLocked||this.params.cssMode||(this.el.style.cursor="")}},P={appendSlide:function(t){var e=this.$wrapperEl,i=this.params;if(i.loop&&this.loopDestroy(),"object"==typeof t&&"length"in t)for(var n=0;n<t.length;n+=1)t[n]&&e.append(t[n]);else e.append(t);i.loop&&this.loopCreate(),i.observer&&C.observer||this.update()},prependSlide:function(t){var e=this.params,i=this.$wrapperEl,n=this.activeIndex;e.loop&&this.loopDestroy();var r=n+1;if("object"==typeof t&&"length"in t){for(var s=0;s<t.length;s+=1)t[s]&&i.prepend(t[s]);r=n+t.length}else i.prepend(t);e.loop&&this.loopCreate(),e.observer&&C.observer||this.update(),this.slideTo(r,0,!1)},addSlide:function(t,e){var i=this.$wrapperEl,n=this.params,r=this.activeIndex;n.loop&&(r-=this.loopedSlides,this.loopDestroy(),this.slides=i.children("."+n.slideClass));var s=this.slides.length;if(t<=0)this.prependSlide(e);else if(s<=t)this.appendSlide(e);else{for(var o=t<r?r+1:r,a=[],l=s-1;t<=l;l-=1){var u=this.slides.eq(l);u.remove(),a.unshift(u)}if("object"==typeof e&&"length"in e){for(var c=0;c<e.length;c+=1)e[c]&&i.append(e[c]);o=t<r?r+e.length:r}else i.append(e);for(var h=0;h<a.length;h+=1)i.append(a[h]);n.loop&&this.loopCreate(),n.observer&&C.observer||this.update(),n.loop?this.slideTo(o+this.loopedSlides,0,!1):this.slideTo(o,0,!1)}},removeSlide:function(t){var e=this.params,i=this.$wrapperEl,n=this.activeIndex;e.loop&&(n-=this.loopedSlides,this.loopDestroy(),this.slides=i.children("."+e.slideClass));var r,s=n;if("object"==typeof t&&"length"in t){for(var o=0;o<t.length;o+=1)r=t[o],this.slides[r]&&this.slides.eq(r).remove(),r<s&&(s-=1);s=Math.max(s,0)}else r=t,this.slides[r]&&this.slides.eq(r).remove(),r<s&&(s-=1),s=Math.max(s,0);e.loop&&this.loopCreate(),e.observer&&C.observer||this.update(),e.loop?this.slideTo(s+this.loopedSlides,0,!1):this.slideTo(s,0,!1)},removeAllSlides:function(){for(var t=[],e=0;e<this.slides.length;e+=1)t.push(e);this.removeSlide(t)}},M=(a=rt.navigator.platform,u=rt.navigator.userAgent,c={ios:!1,android:!1,androidChrome:!1,desktop:!1,iphone:!1,ipod:!1,ipad:!1,edge:!1,ie:!1,firefox:!1,macos:!1,windows:!1,cordova:!(!rt.cordova&&!rt.phonegap),phonegap:!(!rt.cordova&&!rt.phonegap),electron:!1},h=rt.screen.width,d=rt.screen.height,p=u.match(/(Android);?[\s\/]+([\d.]+)?/),f=u.match(/(iPad).*OS\s([\d_]+)/),m=u.match(/(iPod)(.*OS\s([\d_]+))?/),v=!f&&u.match(/(iPhone\sOS|iOS)\s([\d_]+)/),y=0<=u.indexOf("MSIE ")||0<=u.indexOf("Trident/"),b=0<=u.indexOf("Edge/"),w=0<=u.indexOf("Gecko/")&&0<=u.indexOf("Firefox/"),_="Win32"===a,x=0<=u.toLowerCase().indexOf("electron"),T="MacIntel"===a,!f&&T&&C.touch&&(1024===h&&1366===d||834===h&&1194===d||834===h&&1112===d||768===h&&1024===d)&&(f=u.match(/(Version)\/([\d.]+)/),T=!1),c.ie=y,c.edge=b,c.firefox=w,p&&!_&&(c.os="android",c.osVersion=p[2],c.android=!0,c.androidChrome=0<=u.toLowerCase().indexOf("chrome")),(f||v||m)&&(c.os="ios",c.ios=!0),v&&!m&&(c.osVersion=v[2].replace(/_/g,"."),c.iphone=!0),f&&(c.osVersion=f[2].replace(/_/g,"."),c.ipad=!0),m&&(c.osVersion=m[3]?m[3].replace(/_/g,"."):null,c.ipod=!0),c.ios&&c.osVersion&&0<=u.indexOf("Version/")&&"10"===c.osVersion.split(".")[0]&&(c.osVersion=u.toLowerCase().split("version/")[1].split(" ")[0]),c.webView=!(!(v||f||m)||!u.match(/.*AppleWeb
1Kit(?!.*Safari)/i)&&!rt.navigator.standalone)||rt.matchMedia&&rt.matchMedia("(display-mode: standalone)").matches,c.webview=c.webView,c.standalone=c.webView,c.desktop=!(c.ios||c.android)||x,c.desktop&&(c.electron=x,c.macos=T,c.windows=_,c.macos&&(c.os="macos"),c.windows&&(c.os="windows")),c.pixelRatio=rt.devicePixelRatio||1,c);function N(){var t=this.params,e=this.el;if(!e||0!==e.offsetWidth){t.breakpoints&&this.setBreakpoint();var i=this.allowSlideNext,n=this.allowSlidePrev,r=this.snapGrid;this.allowSlideNext=!0,this.allowSlidePrev=!0,this.updateSize(),this.updateSlides(),this.updateSlidesClasses(),("auto"===t.slidesPerView||1<t.slidesPerView)&&this.isEnd&&!this.params.centeredSlides?this.slideTo(this.slides.length-1,0,!1,!0):this.slideTo(this.activeIndex,0,!1,!0),this.autoplay&&this.autoplay.running&&this.autoplay.paused&&this.autoplay.run(),this.allowSlidePrev=n,this.allowSlideNext=i,this.params.watchOverflow&&r!==this.snapGrid&&this.checkOverflow()}}var O=!1;function L(){}var R,F={init:!0,direction:"horizontal",touchEventsTarget:"container",initialSlide:0,speed:300,cssMode:!1,updateOnWindowResize:!0,preventInteractionOnTransition:!1,edgeSwipeDetection:!1,edgeSwipeThreshold:20,freeMode:!1,freeModeMomentum:!0,freeModeMomentumRatio:1,freeModeMomentumBounce:!0,freeModeMomentumBounceRatio:1,freeModeMomentumVelocityRatio:1,freeModeSticky:!1,freeModeMinimumVelocity:.02,autoHeight:!1,setWrapperSize:!1,virtualTranslate:!1,effect:"slide",breakpoints:void 0,spaceBetween:0,slidesPerView:1,slidesPerColumn:1,slidesPerColumnFill:"column",slidesPerGroup:1,slidesPerGroupSkip:0,centeredSlides:!1,centeredSlidesBounds:!1,slidesOffsetBefore:0,slidesOffsetAfter:0,normalizeSlideIndex:!0,centerInsufficientSlides:!1,watchOverflow:!1,roundLengths:!1,touchRatio:1,touchAngle:45,simulateTouch:!0,shortSwipes:!0,longSwipes:!0,longSwipesRatio:.5,longSwipesMs:300,followFinger:!0,allowTouchMove:!0,threshold:0,touchMoveStopPropagation:!1,touchStartPreventDefault:!0,touchStartForcePreventDefault:!1,touchReleaseOnEdges:!1,uniqueNavElements:!0,resistance:!0,resistanceRatio:.85,watchSlidesProgress:!1,watchSlidesVisibility:!1,grabCursor:!1,preventClicks:!0,preventClicksPropagation:!0,slideToClickedSlide:!1,preloadImages:!0,updateOnImagesReady:!0,loop:!1,loopAdditionalSlides:0,loopedSlides:null,loopFillGroupWithBlank:!1,allowSlidePrev:!0,allowSlideNext:!0,swipeHandler:null,noSwiping:!0,noSwipingClass:"swiper-no-swiping",noSwipingSelector:null,passiveListeners:!0,containerModifierClass:"swiper-container-",slideClass:"swiper-slide",slideBlankClass:"swiper-slide-invisible-blank",slideActiveClass:"swiper-slide-active",slideDuplicateActiveClass:"swiper-slide-duplicate-active",slideVisibleClass:"swiper-slide-visible",slideDuplicateClass:"swiper-slide-duplicate",slideNextClass:"swiper-slide-next",slideDuplicateNextClass:"swiper-slide-duplicate-next",slidePrevClass:"swiper-slide-prev",slideDuplicatePrevClass:"swiper-slide-duplicate-prev",wrapperClass:"swiper-wrapper",runCallbacksOnInit:!0},z={update:S,translate:E,transition:{setTransition:function(t,e){this.params.cssMode||this.$wrapperEl.transition(t),this.emit("setTransition",t,e)},transitionStart:function(t,e){void 0===t&&(t=!0);var i=this.activeIndex,n=this.params,r=this.previousIndex;if(!n.cssMode){n.autoHeight&&this.updateAutoHeight();var s=e;if(s||(s=r<i?"next":i<r?"prev":"reset"),this.emit("transitionStart"),t&&i!==r){if("reset"===s)return void this.emit("slideResetTransitionStart");this.emit("slideChangeTransitionStart"),"next"===s?this.emit("slideNextTransitionStart"):this.emit("slidePrevTransitionStart")}}},transitionEnd:function(t,e){void 0===t&&(t=!0);var i=this.activeIndex,n=this.previousIndex,r=this.params;if(this.animating=!1,!r.cssMode){this.setTransition(0);var s=e;if(s||(s=n<i?"next":i<n?"prev":"reset"),this.emit("transitionEnd"),t&&i!==n){if("reset"===s)return void this.emit("slideResetTransitionEnd");this.emit("slideChangeTransitionEnd"),"next"===s?this.emit("slideNextTransitionEnd"):this.emit("slidePrevTransitionEnd")}}}},slide:k,loop:I,grabCursor:D,manipulation:P,events:{attachEvents:function(){var t=this.params,e=this.touchEvents,i=this.el,n=this.wrapperEl;this.onTouchStart=function(t){var e=this.touchEventsData,i=this.params,n=this.touches;if(!this.animating||!i.preventInteractionOnTransition){var r=t;r.originalEvent&&(r=r.originalEvent);var s=A(r.target);if(("wrapper"!==i.touchEventsTarget||s.closest(this.wrapperEl).length)&&(e.isTouchEvent="touchstart"===r.type,(e.isTouchEvent||!("which"in r)||3!==r.which)&&!(!e.isTouchEvent&&"button"in r&&0<r.button||e.isTouched&&e.isMoved)))if(i.noSwiping&&s.closest(i.noSwipingSelector?i.noSwipingSelector:"."+i.noSwipingClass)[0])this.allowClick=!0;else if(!i.swipeHandler||s.closest(i.swipeHandler)[0]){n.currentX="touchstart"===r.type?r.targetTouches[0].pageX:r.pageX,n.currentY="touchstart"===r.type?r.targetTouches[0].pageY:r.pageY;var o=n.currentX,a=n.currentY,l=i.edgeSwipeDetection||i.iOSEdgeSwipeDetection,u=i.edgeSwipeThreshold||i.iOSEdgeSwipeThreshold;if(!l||!(o<=u||o>=rt.screen.width-u)){if(st.extend(e,{isTouched:!0,isMoved:!1,allowTouchCallbacks:!0,isScrolling:void 0,startMoving:void 0}),n.startX=o,n.startY=a,e.touchStartTime=st.now(),this.allowClick=!0,this.updateSize(),this.swipeDirection=void 0,0<i.threshold&&(e.allowThresholdMove=!1),"touchstart"!==r.type){var c=!0;s.is(e.formElements)&&(c=!1),g.activeElement&&A(g.activeElement).is(e.formElements)&&g.activeElement!==s[0]&&g.activeElement.blur();var h=c&&this.allowTouchMove&&i.touchStartPreventDefault;(i.touchStartForcePreventDefault||h)&&r.preventDefault()}
1this.emit("touchStart",r)}}}}.bind(this),this.onTouchMove=function(t){var e=this.touchEventsData,i=this.params,n=this.touches,r=this.rtlTranslate,s=t;if(s.originalEvent&&(s=s.originalEvent),e.isTouched){if(!e.isTouchEvent||"touchmove"===s.type){var o="touchmove"===s.type&&s.targetTouches&&(s.targetTouches[0]||s.changedTouches[0]),a="touchmove"===s.type?o.pageX:s.pageX,l="touchmove"===s.type?o.pageY:s.pageY;if(s.preventedByNestedSwiper)return n.startX=a,void(n.startY=l);if(!this.allowTouchMove)return this.allowClick=!1,void(e.isTouched&&(st.extend(n,{startX:a,startY:l,currentX:a,currentY:l}),e.touchStartTime=st.now()));if(e.isTouchEvent&&i.touchReleaseOnEdges&&!i.loop)if(this.isVertical()){if(l<n.startY&&this.translate<=this.maxTranslate()||l>n.startY&&this.translate>=this.minTranslate())return e.isTouched=!1,void(e.isMoved=!1)}else if(a<n.startX&&this.translate<=this.maxTranslate()||a>n.startX&&this.translate>=this.minTranslate())return;if(e.isTouchEvent&&g.activeElement&&s.target===g.activeElement&&A(s.target).is(e.formElements))return e.isMoved=!0,void(this.allowClick=!1);if(e.allowTouchCallbacks&&this.emit("touchMove",s),!(s.targetTouches&&1<s.targetTouches.length)){n.currentX=a,n.currentY=l;var u,c=n.currentX-n.startX,h=n.currentY-n.startY;if(!(this.params.threshold&&Math.sqrt(Math.pow(c,2)+Math.pow(h,2))<this.params.threshold))if(void 0===e.isScrolling&&(this.isHorizontal()&&n.currentY===n.startY||this.isVertical()&&n.currentX===n.startX?e.isScrolling=!1:25<=c*c+h*h&&(u=180*Math.atan2(Math.abs(h),Math.abs(c))/Math.PI,e.isScrolling=this.isHorizontal()?u>i.touchAngle:90-u>i.touchAngle)),e.isScrolling&&this.emit("touchMoveOpposite",s),void 0===e.startMoving&&(n.currentX===n.startX&&n.currentY===n.startY||(e.startMoving=!0)),e.isScrolling)e.isTouched=!1;else if(e.startMoving){this.allowClick=!1,!i.cssMode&&s.cancelable&&s.preventDefault(),i.touchMoveStopPropagation&&!i.nested&&s.stopPropagation(),e.isMoved||(i.loop&&this.loopFix(),e.startTranslate=this.getTranslate(),this.setTransition(0),this.animating&&this.$wrapperEl.trigger("webkitTransitionEnd transitionend"),e.allowMomentumBounce=!1,!i.grabCursor||!0!==this.allowSlideNext&&!0!==this.allowSlidePrev||this.setGrabCursor(!0),this.emit("sliderFirstMove",s)),this.emit("sliderMove",s),e.isMoved=!0;var d=this.isHorizontal()?c:h;n.diff=d,d*=i.touchRatio,r&&(d=-d),this.swipeDirection=0<d?"prev":"next",e.currentTranslate=d+e.startTranslate;var p=!0,f=i.resistanceRatio;if(i.touchReleaseOnEdges&&(f=0),0<d&&e.currentTranslate>this.minTranslate()?(p=!1,i.resistance&&(e.currentTranslate=this.minTranslate()-1+Math.pow(-this.minTranslate()+e.startTranslate+d,f))):d<0&&e.currentTranslate<this.maxTranslate()&&(p=!1,i.resistance&&(e.currentTranslate=this.maxTranslate()+1-Math.pow(this.maxTranslate()-e.startTranslate-d,f))),p&&(s.preventedByNestedSwiper=!0),!this.allowSlideNext&&"next"===this.swipeDirection&&e.currentTranslate<e.startTranslate&&(e.currentTranslate=e.startTranslate),!this.allowSlidePrev&&"prev"===this.swipeDirection&&e.currentTranslate>e.startTranslate&&(e.currentTranslate=e.startTranslate),0<i.threshold){if(!(Math.abs(d)>i.threshold||e.allowThresholdMove))return void(e.currentTranslate=e.startTranslate);
1if(!e.allowThresholdMove)return e.allowThresholdMove=!0,n.startX=n.currentX,n.startY=n.currentY,e.currentTranslate=e.startTranslate,void(n.diff=this.isHorizontal()?n.currentX-n.startX:n.currentY-n.startY)}i.followFinger&&!i.cssMode&&((i.freeMode||i.watchSlidesProgress||i.watchSlidesVisibility)&&(this.updateActiveIndex(),this.updateSlidesClasses()),i.freeMode&&(0===e.velocities.length&&e.velocities.push({position:n[this.isHorizontal()?"startX":"startY"],time:e.touchStartTime}),e.velocities.push({position:n[this.isHorizontal()?"currentX":"currentY"],time:st.now()})),this.updateProgress(e.currentTranslate),this.setTranslate(e.currentTranslate))}}}}else e.startMoving&&e.isScrolling&&this.emit("touchMoveOpposite",s)}.bind(this),this.onTouchEnd=function(t){var e=this,i=e.touchEventsData,n=e.params,r=e.touches,s=e.rtlTranslate,o=e.$wrapperEl,a=e.slidesGrid,l=e.snapGrid,u=t;if(u.originalEvent&&(u=u.originalEvent),i.allowTouchCallbacks&&e.emit("touchEnd",u),i.allowTouchCallbacks=!1,!i.isTouched)return i.isMoved&&n.grabCursor&&e.setGrabCursor(!1),i.isMoved=!1,void(i.startMoving=!1);n.grabCursor&&i.isMoved&&i.isTouched&&(!0===e.allowSlideNext||!0===e.allowSlidePrev)&&e.setGrabCursor(!1);var c,h=st.now(),d=h-i.touchStartTime;if(e.allowClick&&(e.updateClickedSlide(u),e.emit("tap click",u),d<300&&h-i.lastClickTime<300&&e.emit("doubleTap doubleClick",u)),i.lastClickTime=st.now(),st.nextTick(function(){e.destroyed||(e.allowClick=!0)}),!i.isTouched||!i.isMoved||!e.swipeDirection||0===r.diff||i.currentTranslate===i.startTranslate)return i.isTouched=!1,i.isMoved=!1,void(i.startMoving=!1);if(i.isTouched=!1,i.isMoved=!1,i.startMoving=!1,c=n.followFinger?s?e.translate:-e.translate:-i.currentTranslate,!n.cssMode)if(n.freeMode){if(c<-e.minTranslate())return void e.slideTo(e.activeIndex);if(c>-e.maxTranslate())return void(e.slides.length<l.length?e.slideTo(l.length-1):e.slideTo(e.slides.length-1));if(n.freeModeMomentum){if(1<i.velocities.length){var p=i.velocities.pop(),f=i.velocities.pop(),g=p.position-f.position,m=p.time-f.time;e.velocity=g/m,e.velocity/=2,Math.abs(e.velocity)<n.freeModeMinimumVelocity&&(e.velocity=0),(150<m||300<st.now()-p.time)&&(e.velocity=0)}else e.velocity=0;e.velocity*=n.freeModeMomentumVelocityRatio,i.velocities.length=0;var v=1e3*n.freeModeMomentumRatio,y=e.velocity*v,b=e.translate+y;s&&(b=-b);var w,_,x=!1,T=20*Math.abs(e.velocity)*n.freeModeMomentumBounceRatio;if(b<e.maxTranslate())n.freeModeMomentumBounce?(b+e.maxTranslate()<-T&&(b=e.maxTranslate()-T),w=e.maxTranslate(),x=!0,i.allowMomentumBounce=!0):b=e.maxTranslate(),n.loop&&n.centeredSlides&&(_=!0);else if(b>e.minTranslate())n.freeModeMomentumBounce?(b-e.minTranslate()>T&&(b=e.minTranslate()+T),w=e.minTranslate(),x=!0,i.allowMomentumBounce=!0):b=e.minTranslate(),n.loop&&n.centeredSlides&&(_=!0);else if(n.freeModeSticky){for(var S,C=0;C<l.length;C+=1)if(l[C]>-b){S=C;break}b=-(b=Math.abs(l[S]-b)<Math.abs(l[S-1]-b)||"next"===e.swipeDirection?l[S]:l[S-1])}if(_&&e.once("transitionEnd",function(){e.loopFix()}),0!==e.velocity){if(v=s?Math.abs((-b-e.translate)/e.velocity):Math.abs((b-e.translate)/e.velocity),n.freeModeSticky){var E=Math.abs((s?-b:b)-e.translate),k=e.slidesSizesGrid[e.activeIndex];v=E<k?n.speed:E<2*k?1.5*n.speed:2.5*n.speed}}else if(n.freeModeSticky)return void e.slideToClosest();n.freeModeMomentumBounce&&x?(e.updateProgress(w),e.setTransition(v),e.setTranslate(b),e.transitionStart(!0,e.swipeDirection),e.animating=!0,o.transitionEnd(function(){e&&!e.destroyed&&i.allowMomentumBounce&&(e.emit("momentumBounce"),e.setTransition(n.speed),setTimeout(function(){e.setTranslate(w),o.transitionEnd(function(){e&&!e.destroyed&&e.transitionEnd()})},0))})):e.velocity?(e.updateProgress(b),e.setTransition(v),e.setTranslate(b),e.transitionStart(!0,e.swipeDirection),e.animating||(e.animating=!0,o.transitionEnd(function(){e&&!e.destroyed&&e.transitionEnd()}))):e.updateProgress(b),e.updateActiveIndex(),e.updateSlidesClasses()}else if(n.freeModeSticky)return void e.slideToClosest();(!n.freeModeMomentum||d>=n.longSwipesMs)&&(e.updateProgress(),e.updateActiveIndex(),e.updateSlidesClasses())}else{for(var I=0,D=e.slidesSizesGrid[0],A=0;A<a.length;A+=A<n.slidesPerGroupSkip?1:n.slidesPerGroup){var P=A<n.slidesPerGroupSkip-1?1:n.slidesPerGroup;void 0!==a[A+P]?c>=a[A]&&c<a[A+P]&&(D=a[(I=A)+P]-a[A]):c>=a[A]&&(I=A,D=a[a.length-1]-a[a.length-2])}var M=(c-a[I])/D,N=I<n.slidesPerGroupSkip-1?1:n.slidesPerGroup;if(d>n.longSwipesMs){if(!n.longSwipes)return void e.slideTo(e.activeIndex);"next"===e.swipeDirection&&(M>=n.longSwipesRatio?e.slideTo(I+N):e.slideTo(I)),"prev"===e.swipeDirection&&(M>1-n.longSwipesRatio?e.slideTo(I+N):e.slideTo(I))}else{if(!n.shortSwipes)return void e.slideTo(e.activeIndex);
1!e.navigation||u.target!==e.navigation.nextEl&&u.target!==e.navigation.prevEl?("next"===e.swipeDirection&&e.slideTo(I+N),"prev"===e.swipeDirection&&e.slideTo(I)):u.target===e.navigation.nextEl?e.slideTo(I+N):e.slideTo(I)}}}.bind(this),t.cssMode&&(this.onScroll=function(){var t=this.wrapperEl,e=this.rtlTranslate;this.previousTranslate=this.translate,this.isHorizontal()?this.translate=e?t.scrollWidth-t.offsetWidth-t.scrollLeft:-t.scrollLeft:this.translate=-t.scrollTop,-0===this.translate&&(this.translate=0),this.updateActiveIndex(),this.updateSlidesClasses();var i=this.maxTranslate()-this.minTranslate();(0===i?0:(this.translate-this.minTranslate())/i)!==this.progress&&this.updateProgress(e?-this.translate:this.translate),this.emit("setTranslate",this.translate,!1)}.bind(this)),this.onClick=function(t){this.allowClick||(this.params.preventClicks&&t.preventDefault(),this.params.preventClicksPropagation&&this.animating&&(t.stopPropagation(),t.stopImmediatePropagation()))}.bind(this);var r=!!t.nested;if(!C.touch&&C.pointerEvents)i.addEventListener(e.start,this.onTouchStart,!1),g.addEventListener(e.move,this.onTouchMove,r),g.addEventListener(e.end,this.onTouchEnd,!1);else{if(C.touch){var s=!("touchstart"!==e.start||!C.passiveListener||!t.passiveListeners)&&{passive:!0,capture:!1};i.addEventListener(e.start,this.onTouchStart,s),i.addEventListener(e.move,this.onTouchMove,C.passiveListener?{passive:!1,capture:r}:r),i.addEventListener(e.end,this.onTouchEnd,s),e.cancel&&i.addEventListener(e.cancel,this.onTouchEnd,s),O||(g.addEventListener("touchstart",L),O=!0)}(t.simulateTouch&&!M.ios&&!M.android||t.simulateTouch&&!C.touch&&M.ios)&&(i.addEventListener("mousedown",this.onTouchStart,!1),g.addEventListener("mousemove",this.onTouchMove,r),g.addEventListener("mouseup",this.onTouchEnd,!1))}(t.preventClicks||t.preventClicksPropagation)&&i.addEventListener("click",this.onClick,!0),t.cssMode&&n.addEventListener("scroll",this.onScroll),t.updateOnWindowResize?this.on(M.ios||M.android?"resize orientationchange observerUpdate":"resize observerUpdate",N,!0):this.on("observerUpdate",N,!0)},detachEvents:function(){var t=this.params,e=this.touchEvents,i=this.el,n=this.wrapperEl,r=!!t.nested;if(!C.touch&&C.pointerEvents)i.removeEventListener(e.start,this.onTouchStart,!1),g.removeEventListener(e.move,this.onTouchMove,r),g.removeEventListener(e.end,this.onTouchEnd,!1);else{if(C.touch){var s=!("onTouchStart"!==e.start||!C.passiveListener||!t.passiveListeners)&&{passive:!0,capture:!1};i.removeEventListener(e.start,this.onTouchStart,s),i.removeEventListener(e.move,this.onTouchMove,r),i.removeEventListener(e.end,this.onTouchEnd,s),e.cancel&&i.removeEventListener(e.cancel,this.onTouchEnd,s)}(t.simulateTouch&&!M.ios&&!M.android||t.simulateTouch&&!C.touch&&M.ios)&&(i.removeEventListener("mousedown",this.onTouchStart,!1),g.removeEventListener("mousemove",this.onTouchMove,r),g.removeEventListener("mouseup",this.onTouchEnd,!1))}(t.preventClicks||t.preventClicksPropagation)&&i.removeEventListener("click",this.onClick,!0),t.cssMode&&n.removeEventListener("scroll",this.onScroll),this.off(M.ios||M.android?"resize orientationchange observerUpdate":"resize observerUpdate",N)}},breakpoints:{setBreakpoint:function(){var t=this.activeIndex,e=this.initialized,i=this.loopedSlides;void 0===i&&(i=0);var n=this.params,r=this.$el,s=n.breakpoints;if(s&&(!s||0!==Object.keys(s).length)){var o=this.getBreakpoint(s);if(o&&this.currentBreakpoint!==o){var a=o in s?s[o]:void 0;a&&["slidesPerView","spaceBetween","slidesPerGroup","slidesPerGroupSkip","slidesPerColumn"].forEach(function(t){var e=a[t];void 0!==e&&(a[t]="slidesPerView"!==t||"AUTO"!==e&&"auto"!==e?"slidesPerView"===t?parseFloat(e):parseInt(e,10):"auto")});var l=a||this.originalParams,u=1<n.slidesPerColumn,c=1<l.slidesPerColumn;u&&!c?r.removeClass(n.containerModifierClass+"multirow "+n.containerModifierClass+"multirow-column"):!u&&c&&(r.addClass(n.containerModifierClass+"multirow"),"column"===l.slidesPerColumnFill&&r.addClass(n.containerModifierClass+"multirow-column"));var h=l.direction&&l.direction!==n.direction,d=n.loop&&(l.slidesPerView!==n.slidesPerView||h);h&&e&&this.changeDirection(),st.extend(this.params,l),st.extend(this,{allowTouchMove:this.params.allowTouchMove,allowSlideNext:this.params.allowSlideNext,allowSlidePrev:this.params.allowSlidePrev}),this.currentBreakpoint=o,d&&e&&(this.loopDestroy(),this.loopCreate(),this.updateSlides(),this.slideTo(t-i+this.loopedSlides,0,!1)),this.emit
1("breakpoint",l)}}},getBreakpoint:function(t){if(t){var e=!1,i=Object.keys(t).map(function(t){if("string"!=typeof t||0!==t.indexOf("@"))return{value:t,point:t};var e=parseFloat(t.substr(1));return{value:rt.innerHeight*e,point:t}});i.sort(function(t,e){return parseInt(t.value,10)-parseInt(e.value,10)});for(var n=0;n<i.length;n+=1){var r=i[n],s=r.point;r.value<=rt.innerWidth&&(e=s)}return e||"max"}}},checkOverflow:{checkOverflow:function(){var t=this.params,e=this.isLocked,i=0<this.slides.length&&t.slidesOffsetBefore+t.spaceBetween*(this.slides.length-1)+this.slides[0].offsetWidth*this.slides.length;t.slidesOffsetBefore&&t.slidesOffsetAfter&&i?this.isLocked=i<=this.size:this.isLocked=1===this.snapGrid.length,this.allowSlideNext=!this.isLocked,this.allowSlidePrev=!this.isLocked,e!==this.isLocked&&this.emit(this.isLocked?"lock":"unlock"),e&&e!==this.isLocked&&(this.isEnd=!1,this.navigation.update())}},classes:{addClasses:function(){var e=this.classNames,i=this.params,t=this.rtl,n=this.$el,r=[];r.push("initialized"),r.push(i.direction),i.freeMode&&r.push("free-mode"),i.autoHeight&&r.push("autoheight"),t&&r.push("rtl"),1<i.slidesPerColumn&&(r.push("multirow"),"column"===i.slidesPerColumnFill&&r.push("multirow-column")),M.android&&r.push("android"),M.ios&&r.push("ios"),i.cssMode&&r.push("css-mode"),r.forEach(function(t){e.push(i.containerModifierClass+t)}),n.addClass(e.join(" "))},removeClasses:function(){var t=this.$el,e=this.classNames;t.removeClass(e.join(" "))}},images:{loadImage:function(t,e,i,n,r,s){var o;function a(){s&&s()}A(t).parent("picture")[0]||t.complete&&r?a():e?((o=new rt.Image).onload=a,o.onerror=a,n&&(o.sizes=n),i&&(o.srcset=i),e&&(o.src=e)):a()},preloadImages:function(){var t=this;function e(){null!=t&&t&&!t.destroyed&&(void 0!==t.imagesLoaded&&(t.imagesLoaded+=1),t.imagesLoaded===t.imagesToLoad.length&&(t.params.updateOnImagesReady&&t.update(),t.emit("imagesReady")))}t.imagesToLoad=t.$el.find("img");for(var i=0;i<t.imagesToLoad.length;i+=1){var n=t.imagesToLoad[i];t.loadImage(n,n.currentSrc||n.getAttribute("src"),n.srcset||n.getAttribute("srcset"),n.sizes||n.getAttribute("sizes"),!0,e)}}}},B={},$=function(d){function p(){for(var t,e,r,i=[],n=arguments.length;n--;)i[n]=arguments[n];(r=1===i.length&&i[0].constructor&&i[0].constructor===Object?i[0]:(e=(t=i)[0],t[1]))||(r={}),r=st.extend({},r),e&&!r.el&&(r.el=e),d.call(this,r),Object.keys(z).forEach(function(e){Object.keys(z[e]).forEach(function(t){p.prototype[t]||(p.prototype[t]=z[e][t])})});var s=this;void 0===s.modules&&(s.modules={}),Object.keys(s.modules).forEach(function(t){var e=s.modules[t];if(e.params){var i=Object.keys(e.params)[0],n=e.params[i];if("object"!=typeof n||null===n)return;if(!(i in r&&"enabled"in n))return;!0===r[i]&&(r[i]={enabled:!0}),"object"!=typeof r[i]||"enabled"in r[i]||(r[i].enabled=!0),r[i]||(r[i]={enabled:!1})}});var o=st.extend({},F);s.useModulesParams(o),s.params=st.extend({},o,B,r),s.originalParams=st.extend({},s.params),s.passedParams=st.extend({},r);var a=(s.$=A)(s.params.el);if(e=a[0]){if(1<a.length){var l=[];return a.each(function(t,e){var i=st.extend({},r,{el:e});l.push(new p(i))}),l}var u,c,h;return e.swiper=s,a.data("swiper",s),e&&e.shadowRoot&&e.shadowRoot.querySelector?(u=A(e.shadowRoot.querySelector("."+s.params.wrapperClass))).children=function(t){return a.children(t)}:u=a.children("."+s.params.wrapperClass),st.extend(s,{$el:a,el:e,$wrapperEl:u,wrapperEl:u[0],classNames:[],slides:A(),slidesGrid:[],snapGrid:[],slidesSizesGrid:[],isHorizontal:function(){return"horizontal"===s.params.direction},isVertical:function(){return"vertical"===s.params.direction},rtl:"rtl"===e.dir.toLowerCase()||"rtl"===a.css("direction"),rtlTranslate:"horizontal"===s.params.direction&&("rtl"===e.dir.toLowerCase()||"rtl"===a.css("direction")),wrongRTL:"-webkit-box"===u.css("display"),activeIndex:0,realIndex:0,isBeginning:!0,isEnd:!1,translate:0,previousTranslate:0,progress:0,velocity:0,animating:!1,allowSlideNext:s.params.allowSlideNext,allowSlidePrev:s.params.allowSlidePrev,touchEvents:(c=["touchstart","touchmove","touchend","touchcancel"],h=["mousedown","mousemove","mouseup"],C.pointerEvents&&(h=["pointerdown","pointermove","pointerup"]),s.touchEventsTouch={start:c[0],move:c[1],end:c[2],cancel:c[3]},s.touchEventsDesktop={start:h[0],move:h[1],end:h[2]},C.touch||!s.params.simulateTouch?s.touchEventsTouch:s.touchEventsDesktop),touchEventsData:{isTouched:void 0,isMoved:void 0,allowTouchCallbacks:void 0,touchStartTime:void 0,isScrolling:void 0,currentTranslate:void 0,startTranslate:void 0,allowThresholdMove:void 0,formElements:"input, select, option, textarea, button, video, label",lastClickTime:st.now(),clickTimeout:void 0,velocities:[],allowMomentumBounce:void 0,isTouchEvent:void 0,startMoving:void 0},allowClick:!0,allowTouchMove:s.params.allowTouchMove,touches:{startX:0,startY:0,currentX:0,currentY:0,diff:0},imagesToLoad:[],imagesLoaded:0}),s.useModules(),s.params.init&&s.init(),s}}d&&(p.__proto__=d);var t={extendedDefaults:{configurable:!0},defaults:{configurable:!0},Class:{configurable:!0},$:{configurable:!0}};return((p.prototype=Object.create(d&&d.prototype)).constructor=p).prototype.slidesPerViewDynamic=function(){var t=this.params,e=this.slides,i=this.slidesGrid,n=this.size,r=this.activeIndex,s=1;if(t.centeredSlides){for(var o,a=e[r].swiperSlideSize,l=r+1;l<e.length;
1l+=1)e[l]&&!o&&(s+=1,(a+=e[l].swiperSlideSize)>n&&(o=!0));for(var u=r-1;0<=u;u-=1)e[u]&&!o&&(s+=1,(a+=e[u].swiperSlideSize)>n&&(o=!0))}else for(var c=r+1;c<e.length;c+=1)i[c]-i[r]<n&&(s+=1);return s},p.prototype.update=function(){var i=this;if(i&&!i.destroyed){var t=i.snapGrid,e=i.params;e.breakpoints&&i.setBreakpoint(),i.updateSize(),i.updateSlides(),i.updateProgress(),i.updateSlidesClasses(),i.params.freeMode?(n(),i.params.autoHeight&&i.updateAutoHeight()):(("auto"===i.params.slidesPerView||1<i.params.slidesPerView)&&i.isEnd&&!i.params.centeredSlides?i.slideTo(i.slides.length-1,0,!1,!0):i.slideTo(i.activeIndex,0,!1,!0))||n(),e.watchOverflow&&t!==i.snapGrid&&i.checkOverflow(),i.emit("update")}function n(){var t=i.rtlTranslate?-1*i.translate:i.translate,e=Math.min(Math.max(t,i.maxTranslate()),i.minTranslate());i.setTranslate(e),i.updateActiveIndex(),i.updateSlidesClasses()}},p.prototype.changeDirection=function(i,t){void 0===t&&(t=!0);var e=this.params.direction;return i||(i="horizontal"===e?"vertical":"horizontal"),i===e||"horizontal"!==i&&"vertical"!==i||(this.$el.removeClass(""+this.params.containerModifierClass+e).addClass(""+this.params.containerModifierClass+i),this.params.direction=i,this.slides.each(function(t,e){"vertical"===i?e.style.width="":e.style.height=""}),this.emit("changeDirection"),t&&this.update()),this},p.prototype.init=function(){this.initialized||(this.emit("beforeInit"),this.params.breakpoints&&this.setBreakpoint(),this.addClasses(),this.params.loop&&this.loopCreate(),this.updateSize(),this.updateSlides(),this.params.watchOverflow&&this.checkOverflow(),this.params.grabCursor&&this.setGrabCursor(),this.params.preloadImages&&this.preloadImages(),this.params.loop?this.slideTo(this.params.initialSlide+this.loopedSlides,0,this.params.runCallbacksOnInit):this.slideTo(this.params.initialSlide,0,this.params.runCallbacksOnInit),this.attachEvents(),this.initialized=!0,this.emit("init"))},p.prototype.destroy=function(t,e){void 0===t&&(t=!0),void 0===e&&(e=!0);var i=this,n=i.params,r=i.$el,s=i.$wrapperEl,o=i.slides;return void 0===i.params||i.destroyed||(i.emit("beforeDestroy"),i.initialized=!1,i.detachEvents(),n.loop&&i.loopDestroy(),e&&(i.removeClasses(),r.removeAttr("style"),s.removeAttr("style"),o&&o.length&&o.removeClass([n.slideVisibleClass,n.slideActiveClass,n.slideNextClass,n.slidePrevClass].join(" ")).removeAttr("style").removeAttr("data-swiper-slide-index")),i.emit("destroy"),Object.keys(i.eventsListeners).forEach(function(t){i.off(t)}),!1!==t&&(i.$el[0].swiper=null,i.$el.data("swiper",null),st.deleteProps(i)),i.destroyed=!0),null},p.extendDefaults=function(t){st.extend(B,t)},t.extendedDefaults.get=function(){return B},t.defaults.get=function(){return F},t.Class.get=function(){return d},t.$.get=function(){return A},Object.defineProperties(p,t),p}(i),j={name:"device",proto:{device:M},static:{device:M}},H={name:"support",proto:{support:C},static:{support:C}},q={isEdge:!!rt.navigator.userAgent.match(/Edge/g),isSafari:(R=rt.navigator.userAgent.toLowerCase(),0<=R.indexOf("safari")&&R.indexOf("chrome")<0&&R.indexOf("android")<0),isUiWebView:/(iPhone|iPod|iPad).*AppleWebKit(?!.*Safari)/i.test(rt.navigator.userAgent)},V={name:"browser",proto:{browser:q},static:{browser:q}},U={name:"resize",create:function(){var t=this;st.extend(t,{resize:{resizeHandler:function(){t&&!t.destroyed&&t.initialized&&(t.emit("beforeResize"),t.emit("resize"))},orientationChangeHandler:function(){t&&!t.destroyed&&t.initialized&&t.emit("orientationchange")}}})},on:{init:function(){rt.addEventListener("resize",this.resize.resizeHandler),rt.addEventListener("orientationchange",this.resize.orientationChangeHandler)},destroy:function(){rt.removeEventListener("resize",this.resize.resizeHandler),rt.removeEventListener("orientationchange",this.resize.orientationChangeHandler)}}},W={func:rt.MutationObserver||rt.WebkitMutationObserver,attach:function(t,e){void 0===e&&(e={});var i=this,n=new W.func(function(t){if(1!==t.length){var e=function(){i.emit("observerUpdate",t[0])};rt.requestAnimationFrame?rt.requestAnimationFrame(e):rt.setTimeout(e,0)}else i.emit("observerUpdate",t[0])});n.observe(t,{attributes:void 0===e.attributes||e.attributes,childList:void 0===e.childList||e.childList,characterData:void 0===e.characterData||e.characterData}),i.observer.observers.push(n)},init:function(){if(C.observer&&this.params.observer){if(this.params.observeParents)for(var t=this.$el.parents(),e=0;e<t.length;e+=1)this.observer.attach(t[e]);this.observer.attach(this.$el[0],{childList:this.params.observeSlideChildren}),this.observer.attach(this.$wrapperEl[0],{attributes:!1})}}
vendor: 1,699 bytes, line 1
1,destroy:function(){this.observer.observers.forEach(function(t){t.disconnect()}),this.observer.observers=[]}},K={name:"observer",params:{observer:!1,observeParents:!1,observeSlideChildren:!1},create:function(){st.extend(this,{observer:{init:W.init.bind(this),attach:W.attach.bind(this),destroy:W.destroy.bind(this),observers:[]}})},on:{init:function(){this.observer.init()},destroy:function(){this.observer.destroy()}}},G={update:function(t){var e=this,i=e.params,n=i.slidesPerView,r=i.slidesPerGroup,s=i.centeredSlides,o=e.params.virtual,a=o.addSlidesBefore,l=o.addSlidesAfter,u=e.virtual,c=u.from,h=u.to,d=u.slides,p=u.slidesGrid,f=u.renderSlide,g=u.offset;e.updateActiveIndex();var m,v,y,b=e.activeIndex||0;m=e.rtlTranslate?"right":e.isHorizontal()?"left":"top",y=s?(v=Math.floor(n/2)+r+a,Math.floor(n/2)+r+l):(v=n+(r-1)+a,r+l);var w=Math.max((b||0)-y,0),_=Math.min((b||0)+v,d.length-1),x=(e.slidesGrid[w]||0)-(e.slidesGrid[0]||0);function T(){e.updateSlides(),e.updateProgress(),e.updateSlidesClasses(),e.lazy&&e.params.lazy.enabled&&e.lazy.load()}if(st.extend(e.virtual,{from:w,to:_,offset:x,slidesGrid:e.slidesGrid}),c===w&&h===_&&!t)return e.slidesGrid!==p&&x!==g&&e.slides.css(m,x+"px"),void e.updateProgress();if(e.params.virtual.renderExternal)return e.params.virtual.renderExternal.call(e,{offset:x,from:w,to:_,slides:function(){for(var t=[],e=w;e<=_;e+=1)t.push(d[e]);return t}()}),void T();var S=[],C=[];if(t)e.$wrapperEl.find("."+e.params.slideClass).remove();else for(var E=c;E<=h;E+=1)(E<w||_<E)&&e.$wrapperEl.find("."+e.params.slideClass+'[data-swiper-slide-index="'+E+'"]').remove();for(var k=0;k<d.length;k+=1)w<=k&&k<=_&&(void 0===h||t?C.push(k):(h<k&&C.push(k),k<c&&S.push(k)));
1C.forEach(function(t){e.$wrapperEl.append(f(d[t],t))}),S.sort(function(t,e){return e-t}).forEach(function(t){e.$wrapperEl.prepend(f(d[t],t))}),e.$wrapperEl.children(".swiper-slide").css(m,x+"px"),T()},renderSlide:function(t,e){var i=this.params.virtual;if(i.cache&&this.virtual.cache[e])return this.virtual.cache[e];var n=i.renderSlide?A(i.renderSlide.call(this,t,e)):A('<div class="'+this.params.slideClass+'" data-swiper-slide-index="'+e+'">'+t+"</div>");return n.attr("data-swiper-slide-index")||n.attr("data-swiper-slide-index",e),i.cache&&(this.virtual.cache[e]=n),n},appendSlide:function(t){if("object"==typeof t&&"length"in t)for(var e=0;e<t.length;e+=1)t[e]&&this.virtual.slides.push(t[e]);else this.virtual.slides.push(t);this.virtual.update(!0)},prependSlide:function(t){var e=this.activeIndex,i=e+1,n=1;if(Array.isArray(t)){for(var r=0;r<t.length;r+=1)t[r]&&this.virtual.slides.unshift(t[r]);i=e+t.length,n=t.length}else this.virtual.slides.unshift(t);if(this.params.virtual.cache){var s=this.virtual.cache,o={};Object.keys(s).forEach(function(t){var e=s[t],i=e.attr("data-swiper-slide-index");i&&e.attr("data-swiper-slide-index",parseInt(i,10)+1),o[parseInt(t,10)+n]=e}),this.virtual.cache=o}this.virtual.update(!0),this.slideTo(i,0)},removeSlide:function(t){if(null!=t){var e=this.activeIndex;if(Array.isArray(t))for(var i=t.length-1;0<=i;i-=1)this.virtual.slides.splice(t[i],1),this.params.virtual.cache&&delete this.virtual.cache[t[i]],t[i]<e&&(e-=1),e=Math.max(e,0);else this.virtual.slides.splice(t,1),this.params.virtual.cache&&delete this.virtual.cache[t],t<e&&(e-=1),e=Math.max(e,0);this.virtual.update(!0),this.slideTo(e,0)}},removeAllSlides:function(){this.virtual.slides=[],this.params.virtual.cache&&(this.virtual.cache={}),this.virtual.update(!0),this.slideTo(0,0)}},Y={name:"virtual",params:{virtual:{enabled:!1,slides:[],cache:!0,renderSlide:null,renderExternal:null,addSlidesBefore:0,addSlidesAfter:0}},create:function(){st.extend(this,{virtual:{update:G.update.bind(this),appendSlide:G.appendSlide.bind(this),prependSlide:G.prependSlide.bind(this),removeSlide:G.removeSlide.bind(this),removeAllSlides:G.removeAllSlides.bind(this),renderSlide:G.renderSlide.bind(this),slides:this.params.virtual.slides,cache:{}}})},on:{beforeInit:function(){if(this.params.virtual.enabled){this.classNames.push(this.params.containerModifierClass+"virtual");var t={watchSlidesProgress:!0};st.extend(this.params,t),st.extend(this.originalParams,t),this.params.initialSlide||this.virtual.update(
1)}},setTranslate:function(){this.params.virtual.enabled&&this.virtual.update()}}},X={handle:function(t){var e=this.rtlTranslate,i=t;i.originalEvent&&(i=i.originalEvent);var n=i.keyCode||i.charCode;if(!this.allowSlideNext&&(this.isHorizontal()&&39===n||this.isVertical()&&40===n||34===n))return!1;if(!this.allowSlidePrev&&(this.isHorizontal()&&37===n||this.isVertical()&&38===n||33===n))return!1;if(!(i.shiftKey||i.altKey||i.ctrlKey||i.metaKey||g.activeElement&&g.activeElement.nodeName&&("input"===g.activeElement.nodeName.toLowerCase()||"textarea"===g.activeElement.nodeName.toLowerCase()))){if(this.params.keyboard.onlyInViewport&&(33===n||34===n||37===n||39===n||38===n||40===n)){var r=!1;if(0<this.$el.parents("."+this.params.slideClass).length&&0===this.$el.parents("."+this.params.slideActiveClass).length)return;var s=rt.innerWidth,o=rt.innerHeight,a=this.$el.offset();e&&(a.left-=this.$el[0].scrollLeft);for(var l=[[a.left,a.top],[a.left+this.width,a.top],[a.left,a.top+this.height],[a.left+this.width,a.top+this.height]],u=0;u<l.length;u+=1){var c=l[u];0<=c[0]&&c[0]<=s&&0<=c[1]&&c[1]<=o&&(r=!0)}if(!r)return}this.isHorizontal()?(33!==n&&34!==n&&37!==n&&39!==n||(i.preventDefault?i.preventDefault():i.returnValue=!1),(34!==n&&39!==n||e)&&(33!==n&&37!==n||!e)||this.slideNext(),(33!==n&&37!==n||e)&&(34!==n&&39!==n||!e)||this.slidePrev()):(33!==n&&34!==n&&38!==n&&40!==n||(i.preventDefault?i.preventDefault():i.returnValue=!1),34!==n&&40!==n||this.slideNext(),33!==n&&38!==n||this.slidePrev()),this.emit("keyPress",n)}},enable:function(){this.keyboard.enabled||(A(g).on("keydown",this.keyboard.handle),this.keyboard.enabled=!0)},disable:function(){this.keyboard.enabled&&(A(g).off("keydown",this.keyboard.handle),this.keyboard.enabled=!1)}},Q={name:"keyboard",params:{keyboard:{enabled:!1,onlyInViewport:!0}},create:function(){st.extend(this,{keyboard:{enabled:!1,enable:X.enable.bind(this),disable:X.disable.bind(this),handle:X.handle.bind(this)}})},on:{init:function(){this.params.keyboard.enabled&&this.keyboard.enable()},destroy:function(){this.keyboard.enabled&&this.keyboard.disable()}}},J={lastScrollTime:st.now(),lastEventBeforeSnap:void 0,recentWheelEvents:[],event:function(){return-1<rt.navigator.userAgent.indexOf("firefox")?"DOMMouseScroll":function(){var t="onwheel"in g;if(!t){var e=g.createElement("div");e.setAttribute("onwheel","return;"),t="function"==typeof e.onwheel}return!t&&g.implementation&&g.implementation.hasFeature&&!0!==g.implementation.hasFeature("","")&&(t=g.implementation.hasFeature("Events.wheel","3.0")),t}()?"wheel":"mousewheel"},normalize:function(t){var e=0,i=0,n=0,r=0;return"detail"in t&&(i=t.detail),"wheelDelta"in t&&(i=-t.wheelDelta/120),"wheelDeltaY"in t&&(i=-t.wheelDeltaY/120),"wheelDeltaX"in t&&(e=-t.wheelDeltaX/120),"axis"in t&&t.axis===t.HORIZONTAL_AXIS&&(e=i,i=0),n=10*e,r=10*i,"deltaY"in t&&(r=t.deltaY),"deltaX"in t&&(n=t.deltaX),t.shiftKey&&!n&&(n=r,r=0),(n||r)&&t.deltaMode&&(1===t.deltaMode?(n*=40,r*=40):(n*=800,r*=800)),n&&!e&&(e=n<1?-1:1),r&&!i&&(i=r<1?-1:1),{spinX:e,spinY:i,pixelX:n,pixelY:r}},handleMouseEnter:function(){this.mouseEntered=!0},handleMouseLeave:function(){this.mouseEntered=!1},handle:function(t){var e=t,i=this,n=i.params.mousewheel;i.params.cssMode&&e.preventDefault();var r=i.$el;if("container"!==i.params.mousewheel.eventsTarged&&(r=A(i.params.mousewheel.eventsTarged)),!i.mouseEntered&&!r[0].contains(e.target)&&!n.releaseOnEdges)return!0;e.originalEvent&&(e=e.originalEvent);var s=0,o=i.rtlTranslate?-1:1,a=J.normalize(e);if(n.forceToAxis)if(i.isHorizontal()){if(!(Math.abs(a.pixelX)>Math.abs(a.pixelY)))return!0;s=a.pixelX*o}else{if(!(Math.abs(a.pixelY)>Math.abs(a.pixelX)))return!0;s=a.pixelY}else s=Math.abs(a.pixelX)>Math.abs(a.pixelY)?-a.pixelX*o:-a.pixelY;if(0===s)return!0;if(n.invert&&(s=-s),i.params.freeMode){var l={time:st.now(),delta:Math.abs(s),direction:Math.sign(s)},u=i.mousewheel.lastEventBeforeSnap,c=u&&l.time<u.time+500&&l.delta<=u.delta&&l.direction===u.direction;if(!c){i.mousewheel.lastEventBeforeSnap=void 0,i.params.loop&&i.loopFix();
1var h=i.getTranslate()+s*n.sensitivity,d=i.isBeginning,p=i.isEnd;if(h>=i.minTranslate()&&(h=i.minTranslate()),h<=i.maxTranslate()&&(h=i.maxTranslate()),i.setTransition(0),i.setTranslate(h),i.updateProgress(),i.updateActiveIndex(),i.updateSlidesClasses(),(!d&&i.isBeginning||!p&&i.isEnd)&&i.updateSlidesClasses(),i.params.freeModeSticky){clearTimeout(i.mousewheel.timeout),i.mousewheel.timeout=void 0;var f=i.mousewheel.recentWheelEvents;15<=f.length&&f.shift();var g=f.length?f[f.length-1]:void 0,m=f[0];if(f.push(l),g&&(l.delta>g.delta||l.direction!==g.direction))f.splice(0);else if(15<=f.length&&l.time-m.time<500&&1<=m.delta-l.delta&&l.delta<=6){var v=0<s?.8:.2;i.mousewheel.lastEventBeforeSnap=l,f.splice(0),i.mousewheel.timeout=st.nextTick(function(){i.slideToClosest(i.params.speed,!0,void 0,v)},0)}i.mousewheel.timeout||(i.mousewheel.timeout=st.nextTick(function(){i.mousewheel.lastEventBeforeSnap=l,f.splice(0),i.slideToClosest(i.params.speed,!0,void 0,.5)},500))}if(c||i.emit("scroll",e),i.params.autoplay&&i.params.autoplayDisableOnInteraction&&i.autoplay.stop(),h===i.minTranslate()||h===i.maxTranslate())return!0}}else{var y={time:st.now(),delta:Math.abs(s),direction:Math.sign(s),raw:t},b=i.mousewheel.recentWheelEvents;2<=b.length&&b.shift();var w=b.length?b[b.length-1]:void 0;if(b.push(y),w?(y.direction!==w.direction||y.delta>w.delta||y.time>w.time+150)&&i.mousewheel.animateSlider(y):i.mousewheel.animateSlider(y),i.mousewheel.releaseScroll(y))return!0}return e.preventDefault?e.preventDefault():e.returnValue=!1,!1},animateSlider:function(t){return 6<=t.delta&&st.now()-this.mousewheel.lastScrollTime<60||(t.direction<0?this.isEnd&&!this.params.loop||this.animating||(this.slideNext(),this.emit("scroll",t.raw)):this.isBeginning&&!this.params.loop||this.animating||(this.slidePrev(),this.emit("scroll",t.raw)),this.mousewheel.lastScrollTime=(new rt.Date).getTime(),!1)},releaseScroll:function(t){var e=this.params.mousewheel;if(t.direction<0){if(this.isEnd&&!this.params.loop&&e.releaseOnEdges)return!0}else if(this.isBeginning&&!this.params.loop&&e.releaseOnEdges)return!0;return!1},enable:function(){var t=J.event();if(this.params.cssMode)return this.wrapperEl.removeEventListener(t,this.mousewheel.handle),!0;if(!t)return!1;if(this.mousewheel.enabled)return!1;var e=this.$el;return"container"!==this.params.mousewheel.eventsTarged&&(e=A(this.params.mousewheel.eventsTarged)),e.on("mouseenter",this.mousewheel.handleMouseEnter),e.on("mouseleave",this.mousewheel.handleMouseLeave),e.on(t,this.mousewheel.handle),this.mousewheel.enabled=!0},disable:function(){var t=J.event();if(this.params.cssMode)return this.wrapperEl.addEventListener(t,this.mousewheel.handle),!0;if(!t)return!1;if(!this.mousewheel.enabled)return!1;var e=this.$el;return"container"!==this.params.mousewheel.eventsTarged&&(e=A(this.params.mousewheel.eventsTarged)),e.off(t,this.mousewheel.handle),!(this.mousewheel.enabled=!1)}},Z={update:function(){var t=this.params.navigation;if(!this.params.loop){var e=this.navigation,i=e.$nextEl,n=e.$prevEl;n&&0<n.length&&(this.isBeginning?n.addClass(t.disabledClass):n.removeClass(t.disabledClass),n[this.params.watchOverflow&&this.isLocked?"addClass":"removeClass"](t.lockClass)),i&&0<i.length&&(this.isEnd?i.addClass(t.disabledClass):i.removeClass(t.disabledClass),i[this.params.watchOverflow&&this.isLocked?"addClass":"removeClass"](t.lockClass))}},onPrevClick:function(t){t.preventDefault(),this.isBeginning&&!this.params.loop||this.slidePrev()},onNextClick:function(t){t.preventDefault(),this.isEnd&&!this.params.loop||this.slideNext()},init:function(){var t,e,i=this.params.navigation;(i.nextEl||i.prevEl)&&(i.nextEl&&(t=A(i.nextEl),this.params.uniqueNavElements&&"string"==typeof i.nextEl&&1<t.length&&1===this.$el.find(i.nextEl).length&&(t=this.$el.find(i.nextEl))),i.prevEl&&(e=A(i.prevEl),this.params.uniqueNavElements&&"string"==typeof i.prevEl&&1<e.length&&1===this.$el.find(i.prevEl).length&&(e=this.$el.find(i.prevEl))),t&&0<t.length&&t.on("click",this.navigation.onNextClick),e&&0<e.length&&e.on("click",this.navigation.onPrevClick),st.extend(this.navigation,{$nextEl:t,nextEl:t&&t[0],$prevEl:e,prevEl:e&&e[0]}))},destroy:function(){var t=this.navigation,e=t.$nextEl,i=t.$prevEl;e&&e.length&&(e.off("click",this.navigation.onNextClick),e.removeClass(this.params.navigation.disabledClass)),i&&i.length&&(i.off("
1click",this.navigation.onPrevClick),i.removeClass(this.params.navigation.disabledClass))}},tt={update:function(){var t=this.rtl,r=this.params.pagination;if(r.el&&this.pagination.el&&this.pagination.$el&&0!==this.pagination.$el.length){var s,e=this.virtual&&this.params.virtual.enabled?this.virtual.slides.length:this.slides.length,i=this.pagination.$el,n=this.params.loop?Math.ceil((e-2*this.loopedSlides)/this.params.slidesPerGroup):this.snapGrid.length;if(this.params.loop?((s=Math.ceil((this.activeIndex-this.loopedSlides)/this.params.slidesPerGroup))>e-1-2*this.loopedSlides&&(s-=e-2*this.loopedSlides),n-1<s&&(s-=n),s<0&&"bullets"!==this.params.paginationType&&(s=n+s)):s=void 0!==this.snapIndex?this.snapIndex:this.activeIndex||0,"bullets"===r.type&&this.pagination.bullets&&0<this.pagination.bullets.length){var o,a,l,u=this.pagination.bullets;if(r.dynamicBullets&&(this.pagination.bulletSize=u.eq(0)[this.isHorizontal()?"outerWidth":"outerHeight"](!0),i.css(this.isHorizontal()?"width":"height",this.pagination.bulletSize*(r.dynamicMainBullets+4)+"px"),1<r.dynamicMainBullets&&void 0!==this.previousIndex&&(this.pagination.dynamicBulletIndex+=s-this.previousIndex,this.pagination.dynamicBulletIndex>r.dynamicMainBullets-1?this.pagination.dynamicBulletIndex=r.dynamicMainBullets-1:this.pagination.dynamicBulletIndex<0&&(this.pagination.dynamicBulletIndex=0)),o=s-this.pagination.dynamicBulletIndex,l=((a=o+(Math.min(u.length,r.dynamicMainBullets)-1))+o)/2),u.removeClass(r.bulletActiveClass+" "+r.bulletActiveClass+"-next "+r.bulletActiveClass+"-next-next "+r.bulletActiveClass+"-prev "+r.bulletActiveClass+"-prev-prev "+r.bulletActiveClass+"-main"),1<i.length)u.each(function(t,e){var i=A(e),n=i.index();n===s&&i.addClass(r.bulletActiveClass),r.dynamicBullets&&(o<=n&&n<=a&&i.addClass(r.bulletActiveClass+"-main"),n===o&&i.prev().addClass(r.bulletActiveClass+"-prev").prev().addClass(r.bulletActiveClass+"-prev-prev"),n===a&&i.next().addClass(r.bulletActiveClass+"-next").next().addClass(r.bulletActiveClass+"-next-next"))});else{var c=u.eq(s),h=c.index();if(c.addClass(r.bulletActiveClass),r.dynamicBullets){for(var d=u.eq(o),p=u.eq(a),f=o;f<=a;f+=1)u.eq(f).addClass(r.bulletActiveClass+"-main");if(this.params.loop)if(h>=u.length-r.dynamicMainBullets){for(var g=r.dynamicMainBullets;0<=g;g-=1)u.eq(u.length-g).addClass(r.bulletActiveClass+"-main");u.eq(u.length-r.dynamicMainBullets-1).addClass(r.bulletActiveClass+"-prev")}else d.prev().addClass(r.bulletActiveClass+"-prev").prev().addClass(r.bulletActiveClass+"-prev-prev"),p.next().addClass(r.bulletActiveClass+"-next").next().addClass(r.bulletActiveClass+"-next-next");else d.prev().addClass(r.bulletActiveClass+"-prev").prev().addClass(r.bulletActiveClass+"-prev-prev"),p.next().addClass(r.bulletActiveClass+"-next").next().addClass(r.bulletActiveClass+"-next-next")}}if(r.dynamicBullets){var m=Math.min(u.length,r.dynamicMainBullets+4),v=(this.pagination.bulletSize*m-this.pagination.bulletSize)/2-l*this.pagination.bulletSize,y=t?"right":"left";u.css(this.isHorizontal()?y:"top",v+"px")}}if("fraction"===r.type&&(i.find("."+r.currentClass).text(r.formatFractionCurrent(s+1)),i.find("."+r.totalClass).text(r.formatFractionTotal(n))),"progressbar"===r.type){var b;b=r.progressbarOpposite?this.isHorizontal()?"vertical":"horizontal":this.isHorizontal()?"horizontal":"vertical";var w=(s+1)/n,_=1,x=1;"horizontal"===b?_=w:x=w,i.find("."+r.progressbarFillClass).transform("translate3d(0,0,0) scaleX("+_+") scaleY("+x+")").transition(this.params.speed)}"custom"===r.type&&r.renderCustom?(i.html(r.renderCustom(this,s+1,n)),this.emit("paginationRender",this,i[0])):this.emit("paginationUpdate",this,i[0]),i[this.params.watchOverflow&&this.isLocked?"addClass":"removeClass"](r.lockClass)}},render:function(){var t=this.params.pagination;if(t.el&&this.pagination.el&&this.pagination.$el&&0!==this.pagination.$el.length){var e=this.virtual&&this.params.virtual.enabled?this.virtual.slides.length:this.slides.length,i=this.pagination.$el,n="";if("bullets"===t.type){for(var r=this.params.loop?Math.ceil((e-2*this.loopedSlides)/this.params.slidesPerGroup):this.snapGrid.length,s=0;s<r;s+=1)t.renderBullet?n+=t.renderBullet.call(this,s,t.bulletClass):n+="<"+t.bulletElement+' class="'+t.bulletClass+'"></'+t.bulletElement+">";i.html(n),this.pagination.bullets=i.find("."+t.bulletClass)}"fraction"===t.type&&(n=t.renderFraction?t.renderFraction.call(this,t.currentClass,t.totalClass):'<span class="'+t.currentClass+'"></span> / <span class="'+t.totalClass+'"></span>',i.html(n)),"progressbar"===t.type&&(n=t.renderProgressbar?t.renderProgressbar.call(this,t.progressbarFillClass):'<span class="'+t.progressbarFillClass+'"></span>
1',i.html(n)),"custom"!==t.type&&this.emit("paginationRender",this.pagination.$el[0])}},init:function(){var i=this,t=i.params.pagination;if(t.el){var e=A(t.el);0!==e.length&&(i.params.uniqueNavElements&&"string"==typeof t.el&&1<e.length&&1===i.$el.find(t.el).length&&(e=i.$el.find(t.el)),"bullets"===t.type&&t.clickable&&e.addClass(t.clickableClass),e.addClass(t.modifierClass+t.type),"bullets"===t.type&&t.dynamicBullets&&(e.addClass(""+t.modifierClass+t.type+"-dynamic"),i.pagination.dynamicBulletIndex=0,t.dynamicMainBullets<1&&(t.dynamicMainBullets=1)),"progressbar"===t.type&&t.progressbarOpposite&&e.addClass(t.progressbarOppositeClass),t.clickable&&e.on("click","."+t.bulletClass,function(t){t.preventDefault();var e=A(this).index()*i.params.slidesPerGroup;i.params.loop&&(e+=i.loopedSlides),i.slideTo(e)}),st.extend(i.pagination,{$el:e,el:e[0]}))}},destroy:function(){var t=this.params.pagination;if(t.el&&this.pagination.el&&this.pagination.$el&&0!==this.pagination.$el.length){var e=this.pagination.$el;e.removeClass(t.hiddenClass),e.removeClass(t.modifierClass+t.type),this.pagination.bullets&&this.pagination.bullets.removeClass(t.bulletActiveClass),t.clickable&&e.off("click","."+t.bulletClass)}}},et={setTranslate:function(){if(this.params.scrollbar.el&&this.scrollbar.el){var t=this.scrollbar,e=this.rtlTranslate,i=this.progress,n=t.dragSize,r=t.trackSize,s=t.$dragEl,o=t.$el,a=this.params.scrollbar,l=n,u=(r-n)*i;e?0<(u=-u)?(l=n-u,u=0):r<-u+n&&(l=r+u):u<0?(l=n+u,u=0):r<u+n&&(l=r-u),this.isHorizontal()?(s.transform("translate3d("+u+"px, 0, 0)"),s[0].style.width=l+"px"):(s.transform("translate3d(0px, "+u+"px, 0)"),s[0].style.height=l+"px"),a.hide&&(clearTimeout(this.scrollbar.timeout),o[0].style.opacity=1,this.scrollbar.timeout=setTimeout(function(){o[0].style.opacity=0,o.transition(400)},1e3))}},setTransition:function(t){this.params.scrollbar.el&&this.scrollbar.el&&this.scrollbar.$dragEl.transition(t)},updateSize:function(){if(this.params.scrollbar.el&&this.scrollbar.el){var t=this.scrollbar,e=t.$dragEl,i=t.$el;e[0].style.width="",e[0].style.height="";var n,r=this.isHorizontal()?i[0].offsetWidth:i[0].offsetHeight,s=this.size/this.virtualSize,o=s*(r/this.size);n="auto"===this.params.scrollbar.dragSize?r*s:parseInt(this.params.scrollbar.dragSize,10),this.isHorizontal()?e[0].style.width=n+"px":e[0].style.height=n+"px",i[0].style.display=1<=s?"none":"",this.params.scrollbar.hide&&(i[0].style.opacity=0),st.extend(t,{trackSize:r,divider:s,moveDivider:o,dragSize:n}),t.$el[this.params.watchOverflow&&this.isLocked?"addClass":"removeClass"](this.params.scrollbar.lockClass)}},getPointerPosition:function(t){return this.isHorizontal()?"touchstart"===t.type||"touchmove"===t.type?t.targetTouches[0].clientX:t.clientX:"touchstart"===t.type||"touchmove"===t.type?t.targetTouches[0].clientY:t.clientY},setDragPosition:function(t){var e,i=this.scrollbar,n=this.rtlTranslate,r=i.$el,s=i.dragSize,o=i.trackSize,a=i.dragStartPos;e=(i.getPointerPosition(t)-r.offset()[this.isHorizontal()?"left":"top"]-(null!==a?a:s/2))/(o-s),e=Math.max(Math.min(e,1),0),n&&(e=1-e);var l=this.minTranslate()+(this.maxTranslate()-this.minTranslate())*e;this.updateProgress(l),this.setTranslate(l),this.updateActiveIndex(),this.updateSlidesClasses()},onDragStart:function(t){var e=this.params.scrollbar,i=this.scrollbar,n=this.$wrapperEl,r=i.$el,s=i.$dragEl;this.scrollbar.isTouched=!0,this.scrollbar.dragStartPos=t.target===s[0]||t.target===s?i.getPointerPosition(t)-t.target.getBoundingClientRect()[this.isHorizontal()?"left":"top"]:null,t.preventDefault(),t.stopPropagation(),n.transition(100),s.transition(100),i.setDragPosition(t),clearTimeout(this.scrollbar.dragTimeout),r.transition(0),e.hide&&r.css("opacity",1),this.params.cssMode&&this.$wrapperEl.css("scroll-snap-type","none"),this.emit("scrollbarDragStart",t)},onDragMove:function(t){var e=this.scrollbar,i=this.$wrapperEl,n=e.$el,r=e.$dragEl;this.scrollbar.isTouched&&(t.preventDefault?t.preventDefault():t.returnValue=!1,e.setDragPosition(t),i.transition(0),n.transition(0),r.transition(0),this.emit("scrollbarDragMove",t))}
1,onDragEnd:function(t){var e=this.params.scrollbar,i=this.scrollbar,n=this.$wrapperEl,r=i.$el;this.scrollbar.isTouched&&(this.scrollbar.isTouched=!1,this.params.cssMode&&(this.$wrapperEl.css("scroll-snap-type",""),n.transition("")),e.hide&&(clearTimeout(this.scrollbar.dragTimeout),this.scrollbar.dragTimeout=st.nextTick(function(){r.css("opacity",0),r.transition(400)},1e3)),this.emit("scrollbarDragEnd",t),e.snapOnRelease&&this.slideToClosest())},enableDraggable:function(){if(this.params.scrollbar.el){var t=this.scrollbar,e=this.touchEventsTouch,i=this.touchEventsDesktop,n=this.params,r=t.$el[0],s=!(!C.passiveListener||!n.passiveListeners)&&{passive:!1,capture:!1},o=!(!C.passiveListener||!n.passiveListeners)&&{passive:!0,capture:!1};C.touch?(r.addEventListener(e.start,this.scrollbar.onDragStart,s),r.addEventListener(e.move,this.scrollbar.onDragMove,s),r.addEventListener(e.end,this.scrollbar.onDragEnd,o)):(r.addEventListener(i.start,this.scrollbar.onDragStart,s),g.addEventListener(i.move,this.scrollbar.onDragMove,s),g.addEventListener(i.end,this.scrollbar.onDragEnd,o))}},disableDraggable:function(){if(this.params.scrollbar.el){var t=this.scrollbar,e=this.touchEventsTouch,i=this.touchEventsDesktop,n=this.params,r=t.$el[0],s=!(!C.passiveListener||!n.passiveListeners)&&{passive:!1,capture:!1},o=!(!C.passiveListener||!n.passiveListeners)&&{passive:!0,capture:!1};C.touch?(r.removeEventListener(e.start,this.scrollbar.onDragStart,s),r.removeEventListener(e.move,this.scrollbar.onDragMove,s),r.removeEventListener(e.end,this.scrollbar.onDragEnd,o)):(r.removeEventListener(i.start,this.scrollbar.onDragStart,s),g.removeEventListener(i.move,this.scrollbar.onDragMove,s),g.removeEventListener(i.end,this.scrollbar.onDragEnd,o))}},init:function(){if(this.params.scrollbar.el){var t=this.scrollbar,e=this.$el,i=this.params.scrollbar,n=A(i.el);this.params.uniqueNavElements&&"string"==typeof i.el&&1<n.length&&1===e.find(i.el).length&&(n=e.find(i.el));var r=n.find("."+this.params.scrollbar.dragClass);0===r.length&&(r=A('<div class="'+this.params.scrollbar.dragClass+'"></div>'),n.append(r)),st.extend(t,{$el:n,el:n[0],$dragEl:r,dragEl:r[0]}),i.draggable&&t.enableDraggable()}},destroy:function(){this.scrollbar.disableDraggable()}},it={setTransform:function(t,e){var i=this.rtl,n=A(t),r=i?-1:1,s=n.attr("data-swiper-parallax")||"0",o=n.attr("data-swiper-parallax-x"),a=n.attr("data-swiper-parallax-y"),l=n.attr("data-swiper-parallax-scale"),u=n.attr("data-swiper-parallax-opacity");if(o||a?(o=o||"0",a=a||"0"):this.isHorizontal()?(o=s,a="0"):(a=s,o="0"),o=0<=o.indexOf("%")?parseInt(o,10)*e*r+"%":o*e*r+"px",a=0<=a.indexOf("%")?parseInt(a,10)*e+"%":a*e+"px",null!=u){var c=u-(u-1)*(1-Math.abs(e));n[0].style.opacity=c}if(null==l)n.transform("translate3d("+o+", "+a+", 0px)");else{var h=l-(l-1)*(1-Math.abs(e));n.transform("translate3d("+o+", "+a+", 0px) scale("+h+")")}},setTranslate:function(){var n=this,t=n.$el,e=n.slides,r=n.progress,s=n.snapGrid;t.children("[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y], [data-swiper-parallax-opacity], [data-swiper-parallax-scale]").each(function(t,e){n.parallax.setTransform(e,r)}),e.each(function(t,e){var i=e.progress;1<n.params.slidesPerGroup&&"auto"!==n.params.slidesPerView&&(i+=Math.ceil(t/2)-r*(s.length-1)),i=Math.min(Math.max(i,-1),1),A(e).find("[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y], [data-swiper-parallax-opacity], [data-swiper-parallax-scale]").each(function(t,e){n.parallax.setTransform(e,i)})})},setTransition:function(r){void 0===r&&(r=this.params.speed),this.$el.find("[data-swiper-parallax], [data-swiper-parallax-x], [data-swiper-parallax-y], [data-swiper-parallax-opacity], [data-swiper-parallax-scale]").each(function(t,e){var i=A(e),n=parseInt(i.attr("data-swiper-parallax-duration"),10)||r;0===r&&(n=0),i.transition(n)})}},nt={getDistanceBetweenTouches:function(t){if(t.targetTouches.length<2)return 1;var e=t.targetTouches[0].pageX,i=t.targetTouches[0].pageY,n=t.targetTouches[1].pageX,r=t.targetTouches[1].pageY;return Math.sqrt(Math.pow(n-e,2)+Math.pow(r-i,2))},onGestureStart:function(t){var e=this.params.zoom,i=this.zoom,n=i.gesture;if(i.fakeGestureTouched=!1,i.fakeGestureMoved=!1,!C.gestures){if("touchstart"!==t.type||"touchstart"===t.type&&t.targetTouches.length<2)return;i.fakeGestureTouched=!0,n.scaleStart=nt.getDistanceBetweenTouches(t)}n.$slideEl&&n.$slideEl.length||(n.$slideEl=A(t.target).closest("."+this.params.slideClass),0===n.$slideEl.length&&(n.$slideEl=this.slides.eq(this.activeIndex)),n.$imageEl=n.$slideEl.find("img, svg, canvas, picture, .swiper-zoom-target"),n.$imageWrapEl=n.$imageEl.parent("."+e.containerClass),n.maxRatio=n.$imageWrapEl.attr("data-swiper-zoom")||e.maxRatio,0!==n.$imageWrapEl.length)?(n.$imageEl&&n.$imageEl.transition(0),this.zoom.isScaling=!0):n.$imageEl=void 0},onGestureChange:function(t){var e=this.params.zoom,i=this.zoom,n=i.gesture;if(!C.gestures){if("touchmove"!==t.type||"touchmove"===t.type&&t.targetTouches.length<2)return;i.fakeGestureMoved=!0,n.scaleMove=nt.getDistanceBetweenTouches(t)}n.$imageEl&&0!==n.$imageEl.length&&(i.scale=C.gestures?t.scale*i.currentScale:n.scaleMove/n.scaleStart*i.currentScale,i.scale>n.maxRatio&&(i.scale=n.maxRatio-1+Math.pow(i.scale-n.maxRatio+1,.5)),i.scale<e.minRatio&&(i.scale=e.minRatio+1-Math.pow(e.minRatio-i.scale+1,.5)),n.$imageEl.transform("translate3d(0,
10,0) scale("+i.scale+")"))},onGestureEnd:function(t){var e=this.params.zoom,i=this.zoom,n=i.gesture;if(!C.gestures){if(!i.fakeGestureTouched||!i.fakeGestureMoved)return;if("touchend"!==t.type||"touchend"===t.type&&t.changedTouches.length<2&&!M.android)return;i.fakeGestureTouched=!1,i.fakeGestureMoved=!1}n.$imageEl&&0!==n.$imageEl.length&&(i.scale=Math.max(Math.min(i.scale,n.maxRatio),e.minRatio),n.$imageEl.transition(this.params.speed).transform("translate3d(0,0,0) scale("+i.scale+")"),i.currentScale=i.scale,i.isScaling=!1,1===i.scale&&(n.$slideEl=void 0))},onTouchStart:function(t){var e=this.zoom,i=e.gesture,n=e.image;i.$imageEl&&0!==i.$imageEl.length&&(n.isTouched||(M.android&&t.cancelable&&t.preventDefault(),n.isTouched=!0,n.touchesStart.x="touchstart"===t.type?t.targetTouches[0].pageX:t.pageX,n.touchesStart.y="touchstart"===t.type?t.targetTouches[0].pageY:t.pageY))},onTouchMove:function(t){var e=this.zoom,i=e.gesture,n=e.image,r=e.velocity;if(i.$imageEl&&0!==i.$imageEl.length&&(this.allowClick=!1,n.isTouched&&i.$slideEl)){n.isMoved||(n.width=i.$imageEl[0].offsetWidth,n.height=i.$imageEl[0].offsetHeight,n.startX=st.getTranslate(i.$imageWrapEl[0],"x")||0,n.startY=st.getTranslate(i.$imageWrapEl[0],"y")||0,i.slideWidth=i.$slideEl[0].offsetWidth,i.slideHeight=i.$slideEl[0].offsetHeight,i.$imageWrapEl.transition(0),this.rtl&&(n.startX=-n.startX,n.startY=-n.startY));var s=n.width*e.scale,o=n.height*e.scale;if(!(s<i.slideWidth&&o<i.slideHeight)){if(n.minX=Math.min(i.slideWidth/2-s/2,0),n.maxX=-n.minX,n.minY=Math.min(i.slideHeight/2-o/2,0),n.maxY=-n.minY,n.touchesCurrent.x="touchmove"===t.type?t.targetTouches[0].pageX:t.pageX,n.touchesCurrent.y="touchmove"===t.type?t.targetTouches[0].pageY:t.pageY,!n.isMoved&&!e.isScaling){if(this.isHorizontal()&&(Math.floor(n.minX)===Math.floor(n.startX)&&n.touchesCurrent.x<n.touchesStart.x||Math.floor(n.maxX)===Math.floor(n.startX)&&n.touchesCurrent.x>n.touchesStart.x))return void(n.isTouched=!1);if(!this.isHorizontal()&&(Math.floor(n.minY)===Math.floor(n.startY)&&n.touchesCurrent.y<n.touchesStart.y||Math.floor(n.maxY)===Math.floor(n.startY)&&n.touchesCurrent.y>n.touchesStart.y))return void(n.isTouched=!1)}t.cancelable&&t.preventDefault(),t.stopPropagation(),n.isMoved=!0,n.currentX=n.touchesCurrent.x-n.touchesStart.x+n.startX,n.currentY=n.touchesCurrent.y-n.touchesStart.y+n.startY,n.currentX<n.minX&&(n.currentX=n.minX+1-Math.pow(n.minX-n.currentX+1,.8)),n.currentX>n.maxX&&(n.currentX=n.maxX-1+Math.pow(n.currentX-n.maxX+1,.8)),n.currentY<n.minY&&(n.currentY=n.minY+1-Math.pow(n.minY-n.currentY+1,.8)),n.currentY>n.maxY&&(n.currentY=n.maxY-1+Math.pow(n.currentY-n.maxY+1,.8)),r.prevPositionX||(r.prevPositionX=n.touchesCurrent.x),r.prevPositionY||(r.prevPositionY=n.touchesCurrent.y),r.prevTime||(r.prevTime=Date.now()),r.x=(n.touchesCurrent.x-r.prevPositionX)/(Date.now()-r.prevTime)/2,r.y=(n.touchesCurrent.y-r.prevPositionY)/(Date.now()-r.prevTime)/2,Math.abs(n.touchesCurrent.x-r.prevPositionX)<2&&(r.x=0),Math.abs(n.touchesCurrent.y-r.prevPositionY)<2&&(r.y=0),r.prevPositionX=n.touchesCurrent.x,r.prevPositionY=n.touchesCurrent.y,r.prevTime=Date.now(),i.$imageWrapEl.transform("translate3d("+n.currentX+"px, "+n.currentY+"px,0)")}}},onTouchEnd:function(){var t=this.zoom,e=t.gesture,i=t.image,n=t.velocity;if(e.$imageEl&&0!==e.$imageEl.length){if(!i.isTouched||!i.isMoved)return i.isTouched=!1,void(i.isMoved=!1);i.isTouched=!1,i.isMoved=!1;var r=300,s=300,o=n.x*r,a=i.currentX+o,l=n.y*s,u=i.currentY+l;0!==n.x&&(r=Math.abs((a-i.currentX)/n.x)),0!==n.y&&(s=Math.abs((u-i.currentY)/n.y));var c=Math.max(r,s);i.currentX=a,i.currentY=u;var h=i.width*t.scale,d=i.height*t.scale;i.minX=Math.min(e.slideWidth/2-h/2,0),i.maxX=-i.minX,i.minY=Math.min(e.slideHeight/2-d/2,0),i.maxY=-i.minY,i.currentX=Math.max(Math.min(i.currentX,i.maxX),i.minX),i.currentY=Math.max(Math.min(i.currentY,i.maxY),i.minY),e.$imageWrapEl.transition(c).transform("translate3d("+i.currentX+"px, "+i.currentY+"px,0)")}},onTransitionEnd:function(){var t=this.zoom,e=t.gesture;e.$slideEl&&this.previousIndex!==this.activeIndex&&(e.$imageEl&&e.$imageEl.transform("translate3d(0,
10,0) scale(1)"),e.$imageWrapEl&&e.$imageWrapEl.transform("translate3d(0,0,0)"),t.scale=1,t.currentScale=1,e.$slideEl=void 0,e.$imageEl=void 0,e.$imageWrapEl=void 0)},toggle:function(t){var e=this.zoom;e.scale&&1!==e.scale?e.out():e.in(t)},in:function(t){var e,i,n,r,s,o,a,l,u,c,h,d,p,f,g,m,v=this.zoom,y=this.params.zoom,b=v.gesture,w=v.image;b.$slideEl||(this.params.virtual&&this.params.virtual.enabled&&this.virtual?b.$slideEl=this.$wrapperEl.children("."+this.params.slideActiveClass):b.$slideEl=this.slides.eq(this.activeIndex),b.$imageEl=b.$slideEl.find("img, svg, canvas, picture, .swiper-zoom-target"),b.$imageWrapEl=b.$imageEl.parent("."+y.containerClass)),b.$imageEl&&0!==b.$imageEl.length&&(b.$slideEl.addClass(""+y.zoomedSlideClass),i=void 0===w.touchesStart.x&&t?(e="touchend"===t.type?t.changedTouches[0].pageX:t.pageX,"touchend"===t.type?t.changedTouches[0].pageY:t.pageY):(e=w.touchesStart.x,w.touchesStart.y),v.scale=b.$imageWrapEl.attr("data-swiper-zoom")||y.maxRatio,v.currentScale=b.$imageWrapEl.attr("data-swiper-zoom")||y.maxRatio,t?(g=b.$slideEl[0].offsetWidth,m=b.$slideEl[0].offsetHeight,n=b.$slideEl.offset().left+g/2-e,r=b.$slideEl.offset().top+m/2-i,a=b.$imageEl[0].offsetWidth,l=b.$imageEl[0].offsetHeight,u=a*v.scale,c=l*v.scale,p=-(h=Math.min(g/2-u/2,0)),f=-(d=Math.min(m/2-c/2,0)),(s=n*v.scale)<h&&(s=h),p<s&&(s=p),(o=r*v.scale)<d&&(o=d),f<o&&(o=f)):o=s=0,b.$imageWrapEl.transition(300).transform("translate3d("+s+"px, "+o+"px,0)"),b.$imageEl.transition(300).transform("translate3d(0,0,0) scale("+v.scale+")"))},out:function(){var t=this.zoom,e=this.params.zoom,i=t.gesture;i.$slideEl||(this.params.virtual&&this.params.virtual.enabled&&this.virtual?i.$slideEl=this.$wrapperEl.children("."+this.params.slideActiveClass):i.$slideEl=this.slides.eq(this.activeIndex),i.$imageEl=i.$slideEl.find("img, svg, canvas, picture, .swiper-zoom-target"),i.$imageWrapEl=i.$imageEl.parent("."+e.containerClass)),i.$imageEl&&0!==i.$imageEl.length&&(t.scale=1,t.currentScale=1,i.$imageWrapEl.transition(300).transform("translate3d(0,0,0)"),i.$imageEl.transition(300).transform("translate3d(0,0,0) scale(1)"),i.$slideEl.removeClass(""+e.zoomedSlideClass),i.$slideEl=void 0)},enable:function(){var t=this.zoom;if(!t.enabled){t.enabled=!0;var e=!("touchstart"!==this.touchEvents.start||!C.passiveListener||!this.params.passiveListeners)&&{passive:!0,capture:!1},i=!C.passiveListener||{passive:!1,capture:!0},n="."+this.params.slideClass;C.gestures?(this.$wrapperEl.on("gesturestart",n,t.onGestureStart,e),this.$wrapperEl.on("gesturechange",n,t.onGestureChange,e),this.$wrapperEl.on("gestureend",n,t.onGestureEnd,e)):"touchstart"===this.touchEvents.start&&(this.$wrapperEl.on(this.touchEvents.start,n,t.onGestureStart,e),this.$wrapperEl.on(this.touchEvents.move,n,t.onGestureChange,i),this.$wrapperEl.on(this.touchEvents.end,n,t.onGestureEnd,e),this.touchEvents.cancel&&this.$wrapperEl.on(this.touchEvents.cancel,n,t.onGestureEnd,e)),this.$wrapperEl.on(this.touchEvents.move,"."+this.params.zoom.containerClass,t.onTouchMove,i)}},disable:function(){var t=this.zoom;if(t.enabled){this.zoom.enabled=!1;var e=!("touchstart"!==this.touchEvents.start||!C.passiveListener||!this.params.passiveListeners)&&{passive:!0,capture:!1},i=!C.passiveListener||{passive:!1,capture:!0},n="."+this.params.slideClass;C.gestures?(this.$wrapperEl.off("gesturestart",n,t.onGestureStart,e),this.$wrapperEl.off("gesturechange",n,t.onGestureChange,e),this.$wrapperEl.off("gestureend",n,t.onGestureEnd,e)):"touchstart"===this.touchEvents.start&&(this.$wrapperEl.off(this.touchEvents.start,n,t.onGestureStart,e),this.$wrapperEl.off(this.touchEvents.move,n,t.onGestureChange,i),this.$wrapperEl.off(this.touchEvents.end,n,t.onGestureEnd,e),this.touchEvents.cancel&&this.$wrapperEl.off(this.touchEvents.cancel,n,t.onGestureEnd,e)),this.$wrapperEl.off(this.touchEvents.move,"."+this.params.zoom.containerClass,t.onTouchMove,i)}}},ot={loadInSlide:function(t,u){void 0===u&&(u=!0);var c=this,h=c.params.lazy;if(void 0!==t&&0!==c.slides.length){var d=c.virtual&&c.params.virtual.enabled?c.$wrapperEl.children("."+c.params.slideClass+'[data-swiper-slide-index="'+t+'"]'):c.slides.eq(t),e=d.find("."+h.elementClass+":not(."+h.loadedClass+"):not(."+h.loadingClass+")");!d.hasClass(h.elementClass)||d.hasClass(h.loadedClass)||d.hasClass(h.loadingClass)||(e=e.add(d[0])),0!==e.length&&e.each(function(t,e){var n=A(e);n.addClass(h.loadingClass);var r=n.attr("data-background"),s=n.attr("data-src"),o=n.attr("data-srcset"),a=n.attr("data-sizes"),l=n.parent("picture");c.loadImage(n[0],s||r,o,a,!1,function(){if(null!=c&&c&&(!c||c.params)&&!c.destroyed){
1if(r?(n.css("background-image",'url("'+r+'")'),n.removeAttr("data-background")):(o&&(n.attr("srcset",o),n.removeAttr("data-srcset")),a&&(n.attr("sizes",a),n.removeAttr("data-sizes")),l.length&&l.children("source").each(function(t,e){var i=A(e);i.attr("data-srcset")&&(i.attr("srcset",i.attr("data-srcset")),i.removeAttr("data-srcset"))}),s&&(n.attr("src",s),n.removeAttr("data-src"))),n.addClass(h.loadedClass).removeClass(h.loadingClass),d.find("."+h.preloaderClass).remove(),c.params.loop&&u){var t=d.attr("data-swiper-slide-index");if(d.hasClass(c.params.slideDuplicateClass)){var e=c.$wrapperEl.children('[data-swiper-slide-index="'+t+'"]:not(.'+c.params.slideDuplicateClass+")");c.lazy.loadInSlide(e.index(),!1)}else{var i=c.$wrapperEl.children("."+c.params.slideDuplicateClass+'[data-swiper-slide-index="'+t+'"]');c.lazy.loadInSlide(i.index(),!1)}}c.emit("lazyImageReady",d[0],n[0]),c.params.autoHeight&&c.updateAutoHeight()}}),c.emit("lazyImageLoad",d[0],n[0])})}},load:function(){var n=this,e=n.$wrapperEl,i=n.params,r=n.slides,t=n.activeIndex,s=n.virtual&&i.virtual.enabled,o=i.lazy,a=i.slidesPerView;function l(t){if(s){if(e.children("."+i.slideClass+'[data-swiper-slide-index="'+t+'"]').length)return!0}else if(r[t])return!0;return!1}function u(t){return s?A(t).attr("data-swiper-slide-index"):A(t).index()}if("auto"===a&&(a=0),n.lazy.initialImageLoaded||(n.lazy.initialImageLoaded=!0),n.params.watchSlidesVisibility)e.children("."+i.slideVisibleClass).each(function(t,e){var i=s?A(e).attr("data-swiper-slide-index"):A(e).index();n.lazy.loadInSlide(i)});else if(1<a)for(var c=t;c<t+a;c+=1)l(c)&&n.lazy.loadInSlide(c);else n.lazy.loadInSlide(t);if(o.loadPrevNext)if(1<a||o.loadPrevNextAmount&&1<o.loadPrevNextAmount){for(var h=o.loadPrevNextAmount,d=a,p=Math.min(t+d+Math.max(h,d),r.length),f=Math.max(t-Math.max(d,h),0),g=t+a;g<p;g+=1)l(g)&&n.lazy.loadInSlide(g);for(var m=f;m<t;m+=1)l(m)&&n.lazy.loadInSlide(m)}else{var v=e.children("."+i.slideNextClass);0<v.length&&n.lazy.loadInSlide(u(v));var y=e.children("."+i.slidePrevClass);0<y.length&&n.lazy.loadInSlide(u(y))}}},at={LinearSpline:function(t,e){var i,n,r,s,o;return this.x=t,this.y=e,this.lastIndex=t.length-1,this.interpolate=function(t){return t?(o=function(t,e){for(n=-1,i=t.length;1<i-n;)t[r=i+n>>1]<=e?n=r:i=r;return i}(this.x,t),s=o-1,(t-this.x[s])*(this.y[o]-this.y[s])/(this.x[o]-this.x[s])+this.y[s]):0},this},getInterpolateFunction:function(t){this.controller.spline||(this.controller.spline=this.params.loop?new at.LinearSpline(this.slidesGrid,t.slidesGrid):new at.LinearSpline(this.snapGrid,t.snapGrid))},setTranslate:function(t,e){var i,n,r=this,s=r.controller.control;function o(t){var e=r.rtlTranslate?-r.translate:r.translate;"slide"===r.params.controller.by&&(r.controller.getInterpolateFunction(t),n=-r.controller.spline.interpolate(-e)),n&&"container"!==r.params.controller.by||(i=(t.maxTranslate()-t.minTranslate())/(r.maxTranslate()-r.minTranslate()),n=(e-r.minTranslate())*i+t.minTranslate()),r.params.controller.inverse&&(n=t.maxTranslate()-n),t.updateProgress(n),t.setTranslate(n,r),t.updateActiveIndex(),t.updateSlidesClasses()}if(Array.isArray(s))for(var a=0;a<s.length;a+=1)s[a]!==e&&s[a]instanceof $&&o(s[a]);else s instanceof $&&e!==s&&o(s)},setTransition:function(e,t){var i,n=this,r=n.controller.control;function s(t){t.setTransition(e,n),0!==e&&(t.transitionStart(),t.params.autoHeight&&st.nextTick(function(){t.updateAutoHeight()}),t.$wrapperEl.transitionEnd(function(){r&&(t.params.loop&&"slide"===n.params.controller.by&&t.loopFix(),t.transitionEnd())}))}if(Array.isArray(r))for(i=0;i<r.length;i+=1)r[i]!==t&&r[i]instanceof $&&s(r[i]);else r instanceof $&&t!==r&&s(r)}},lt={makeElFocusable:function(t){return t.attr("tabIndex","0"),t},makeElNotFocusable:function(t){return t.attr("tabIndex","-1"),t},addElRole:function(t,e){return t.attr("role",e),t},addElLabel:function(t,e){return t.attr("aria-label",e),t},disableEl:function(t){return t.attr("aria-disabled",!0),t},enableEl:function(t){return t.attr("aria-disabled",!1),t},onEnterKey:function(t){var e=this.params.a11y;if(13===t.keyCode){var i=A(t.target);this.navigation&&this.navigation.$nextEl&&i.is(this.navigation.$nextEl)&&(this.isEnd&&!this.params.loop||this.slideNext(),this.isEnd?this.a11y.notify(e.lastSlideMessage):this.a11y.notify(e.nextSlideMessage)),this.navigation&&this.navigation.$prevEl&&i.is(this.navigation.$prevEl)&&(this.isBeg
1inning&&!this.params.loop||this.slidePrev(),this.isBeginning?this.a11y.notify(e.firstSlideMessage):this.a11y.notify(e.prevSlideMessage)),this.pagination&&i.is("."+this.params.pagination.bulletClass)&&i[0].click()}},notify:function(t){var e=this.a11y.liveRegion;0!==e.length&&(e.html(""),e.html(t))},updateNavigation:function(){if(!this.params.loop&&this.navigation){var t=this.navigation,e=t.$nextEl,i=t.$prevEl;i&&0<i.length&&(this.isBeginning?(this.a11y.disableEl(i),this.a11y.makeElNotFocusable(i)):(this.a11y.enableEl(i),this.a11y.makeElFocusable(i))),e&&0<e.length&&(this.isEnd?(this.a11y.disableEl(e),this.a11y.makeElNotFocusable(e)):(this.a11y.enableEl(e),this.a11y.makeElFocusable(e)))}},updatePagination:function(){var n=this,r=n.params.a11y;n.pagination&&n.params.pagination.clickable&&n.pagination.bullets&&n.pagination.bullets.length&&n.pagination.bullets.each(function(t,e){var i=A(e);n.a11y.makeElFocusable(i),n.a11y.addElRole(i,"button"),n.a11y.addElLabel(i,r.paginationBulletMessage.replace(/\{\{index\}\}/,i.index()+1))})},init:function(){this.$el.append(this.a11y.liveRegion);var t,e,i=this.params.a11y;this.navigation&&this.navigation.$nextEl&&(t=this.navigation.$nextEl),this.navigation&&this.navigation.$prevEl&&(e=this.navigation.$prevEl),t&&(this.a11y.makeElFocusable(t),this.a11y.addElRole(t,"button"),this.a11y.addElLabel(t,i.nextSlideMessage),t.on("keydown",this.a11y.onEnterKey)),e&&(this.a11y.makeElFocusable(e),this.a11y.addElRole(e,"button"),this.a11y.addElLabel(e,i.prevSlideMessage),e.on("keydown",this.a11y.onEnterKey)),this.pagination&&this.params.pagination.clickable&&this.pagination.bullets&&this.pagination.bullets.length&&this.pagination.$el.on("keydown","."+this.params.pagination.bulletClass,this.a11y.onEnterKey)},destroy:function(){var t,e;this.a11y.liveRegion&&0<this.a11y.liveRegion.length&&this.a11y.liveRegion.remove(),this.navigation&&this.navigation.$nextEl&&(t=this.navigation.$nextEl),this.navigation&&this.navigation.$prevEl&&(e=this.navigation.$prevEl),t&&t.off("keydown",this.a11y.onEnterKey),e&&e.off("keydown",this.a11y.onEnterKey),this.pagination&&this.params.pagination.clickable&&this.pagination.bullets&&this.pagination.bullets.length&&this.pagination.$el.off("keydown","."+this.params.pagination.bulletClass,this.a11y.onEnterKey)}},ut={init:function(){if(this.params.history){if(!rt.history||!rt.history.pushState)return this.params.history.enabled=!1,void(this.params.hashNavigation.enabled=!0);var t=this.history;t.initialized=!0,t.paths=ut.getPathValues(),(t.paths.key||t.paths.value)&&(t.scrollToSlide(0,t.paths.value,this.params.runCallbacksOnInit),this.params.history.replaceState||rt.addEventListener("popstate",this.history.setHistoryPopState))}},destroy:function(){this.params.history.replaceState||rt.removeEventListener("popstate",this.history.setHistoryPopState)},setHistoryPopState:function(){this.history.paths=ut.getPathValues(),this.history.scrollToSlide(this.params.speed,this.history.paths.value,!1)},getPathValues:function(){var t=rt.location.pathname.slice(1).split("/").filter(function(t){return""!==t}),e=t.length;return{key:t[e-2],value:t[e-1]}},setHistory:function(t,e){if(this.history.initialized&&this.params.history.enabled){var i=this.slides.eq(e),n=ut.slugify(i.attr("data-history"));rt.location.pathname.includes(t)||(n=t+"/"+n);var r=rt.history.state;r&&r.value===n||(this.params.history.replaceState?rt.history.replaceState({value:n},null,n):rt.history.pushState({value:n},null,n))}},slugify:function(t){return t.toString().replace(/\s+/g,"-").replace(/[^\w-]+/g,"").replace(/--+/g,"-").replace(/^-+/,"").replace(/-+$/,"")},scrollToSlide:function(t,e,i){if(e)for(var n=0,r=this.slides.length;n<r;n+=1){var s=this.slides.eq(n);if(ut.slugify(s.attr("data-history"))===e&&!s.hasClass(this.params.slideDuplicateClass)){var o=s.index();this.slideTo(o,t,i)}}else this.slideTo(0,t,i)}},ct={onHashCange:function(){this.emit("hashChange");var t=g.location.hash.replace("#","");if(t!==this.slides.eq(this.activeIndex).attr("data-hash")){var e=this.$wrapperEl.children("."+this.params.slideClass+'[data-hash="'+t+'"]').index();if(void 0===e)return;this.slideTo(e)}},setHash:function(){if(this.hashNavigation.initialized&&this.params.hashNavigation.enabled)if(this.params.hashNavigation.replaceState&&rt.history&&rt.history.replaceState)rt.history.replaceState(null,null,"#"+this.slides.eq(this.activeIndex).attr("data-hash")||""),this.emit
1("hashSet");else{var t=this.slides.eq(this.activeIndex),e=t.attr("data-hash")||t.attr("data-history");g.location.hash=e||"",this.emit("hashSet")}},init:function(){if(!(!this.params.hashNavigation.enabled||this.params.history&&this.params.history.enabled)){this.hashNavigation.initialized=!0;var t=g.location.hash.replace("#","");if(t)for(var e=0,i=this.slides.length;e<i;e+=1){var n=this.slides.eq(e);if((n.attr("data-hash")||n.attr("data-history"))===t&&!n.hasClass(this.params.slideDuplicateClass)){var r=n.index();this.slideTo(r,0,this.params.runCallbacksOnInit,!0)}}this.params.hashNavigation.watchState&&A(rt).on("hashchange",this.hashNavigation.onHashCange)}},destroy:function(){this.params.hashNavigation.watchState&&A(rt).off("hashchange",this.hashNavigation.onHashCange)}},ht={run:function(){var t=this,e=t.slides.eq(t.activeIndex),i=t.params.autoplay.delay;e.attr("data-swiper-autoplay")&&(i=e.attr("data-swiper-autoplay")||t.params.autoplay.delay),clearTimeout(t.autoplay.timeout),t.autoplay.timeout=st.nextTick(function(){t.params.autoplay.reverseDirection?t.params.loop?(t.loopFix(),t.slidePrev(t.params.speed,!0,!0),t.emit("autoplay")):t.isBeginning?t.params.autoplay.stopOnLastSlide?t.autoplay.stop():(t.slideTo(t.slides.length-1,t.params.speed,!0,!0),t.emit("autoplay")):(t.slidePrev(t.params.speed,!0,!0),t.emit("autoplay")):t.params.loop?(t.loopFix(),t.slideNext(t.params.speed,!0,!0),t.emit("autoplay")):t.isEnd?t.params.autoplay.stopOnLastSlide?t.autoplay.stop():(t.slideTo(0,t.params.speed,!0,!0),t.emit("autoplay")):(t.slideNext(t.params.speed,!0,!0),t.emit("autoplay")),t.params.cssMode&&t.autoplay.running&&t.autoplay.run()},i)},start:function(){return void 0===this.autoplay.timeout&&!this.autoplay.running&&(this.autoplay.running=!0,this.emit("autoplayStart"),this.autoplay.run(),!0)},stop:function(){return!!this.autoplay.running&&void 0!==this.autoplay.timeout&&(this.autoplay.timeout&&(clearTimeout(this.autoplay.timeout),this.autoplay.timeout=void 0),this.autoplay.running=!1,this.emit("autoplayStop"),!0)},pause:function(t){this.autoplay.running&&(this.autoplay.paused||(this.autoplay.timeout&&clearTimeout(this.autoplay.timeout),this.autoplay.paused=!0,0!==t&&this.params.autoplay.waitForTransition?(this.$wrapperEl[0].addEventListener("transitionend",this.autoplay.onTransitionEnd),this.$wrapperEl[0].addEventListener("webkitTransitionEnd",this.autoplay.onTransitionEnd)):(this.autoplay.paused=!1,this.autoplay.run())))}},dt={setTranslate:function(){for(var t=this.slides,e=0;e<t.length;e+=1){var i=this.slides.eq(e),n=-i[0].swiperSlideOffset;this.params.virtualTranslate||(n-=this.translate);var r=0;this.isHorizontal()||(r=n,n=0);var s=this.params.fadeEffect.crossFade?Math.max(1-Math.abs(i[0].progress),0):1+Math.min(Math.max(i[0].progress,-1),0);i.css({opacity:s}).transform("translate3d("+n+"px, "+r+"px, 0px)")}},setTransition:function(t){var i=this,e=i.slides,n=i.$wrapperEl;if(e.transition(t),i.params.virtualTranslate&&0!==t){var r=!1;e.transitionEnd(function(){if(!r&&i&&!i.destroyed){r=!0,i.animating=!1;for(var t=["webkitTransitionEnd","transitionend"],e=0;e<t.length;e+=1)n.trigger(t[e])}})}}},pt={setTranslate:function(){var t,e=this.$el,i=this.$wrapperEl,n=this.slides,r=this.width,s=this.height,o=this.rtlTranslate,a=this.size,l=this.params.cubeEffect,u=this.isHorizontal(),c=this.virtual&&this.params.virtual.enabled,h=0;l.shadow&&(u?(0===(t=i.find(".swiper-cube-shadow")).length&&(t=A('<div class="swiper-cube-shadow"></div>'),i.append(t)),t.css({height:r+"px"})):0===(t=e.find(".swiper-cube-shadow")).length&&(t=A('<div class="swiper-cube-shadow"></div>'),e.append(t)));for(var d=0;d<n.length;d+=1){var p=n.eq(d),f=d;c&&(f=parseInt(p.attr("data-swiper-slide-index"),10));var g=90*f,m=Math.floor(g/360);o&&(g=-g,m=Math.floor(-g/360));var v=Math.max(Math.min(p[0].progress,1),-1),y=0,b=0,w=0;f%4==0?(y=4*-m*a,w=0):(f-1)%4==0?(y=0,w=4*-m*a):(f-2)%4==0?(y=a+4*m*a,w=a):(f-3)%4==0&&(y=-a,w=3*a+4*a*m),o&&(y=-y),u||(b=y,y=0);var _="rotateX("+(u?0:-g)+"deg) rotateY("+(u?g:0)+"deg) translate3d("+y+"px, "+b+"px, "+w+"px)";if(v<=1&&-1<v&&(h=90*f+90*v,o&&(h=90*-f-90*v)),p.transform(_),l.slideShadows){var x=u?p.find(".swiper-slide-shadow-left"):p.find(".swiper-slide-shadow-top"),T=u?p.find(".swiper-slide-shadow-right"):p.find(".swiper-slide-shadow-bottom");
10===x.length&&(x=A('<div class="swiper-slide-shadow-'+(u?"left":"top")+'"></div>'),p.append(x)),0===T.length&&(T=A('<div class="swiper-slide-shadow-'+(u?"right":"bottom")+'"></div>'),p.append(T)),x.length&&(x[0].style.opacity=Math.max(-v,0)),T.length&&(T[0].style.opacity=Math.max(v,0))}}if(i.css({"-webkit-transform-origin":"50% 50% -"+a/2+"px","-moz-transform-origin":"50% 50% -"+a/2+"px","-ms-transform-origin":"50% 50% -"+a/2+"px","transform-origin":"50% 50% -"+a/2+"px"}),l.shadow)if(u)t.transform("translate3d(0px, "+(r/2+l.shadowOffset)+"px, "+-r/2+"px) rotateX(90deg) rotateZ(0deg) scale("+l.shadowScale+")");else{var S=Math.abs(h)-90*Math.floor(Math.abs(h)/90),C=1.5-(Math.sin(2*S*Math.PI/360)/2+Math.cos(2*S*Math.PI/360)/2),E=l.shadowScale,k=l.shadowScale/C,I=l.shadowOffset;t.transform("scale3d("+E+", 1, "+k+") translate3d(0px, "+(s/2+I)+"px, "+-s/2/k+"px) rotateX(-90deg)")}var D=q.isSafari||q.isUiWebView?-a/2:0;i.transform("translate3d(0px,0,"+D+"px) rotateX("+(this.isHorizontal()?0:h)+"deg) rotateY("+(this.isHorizontal()?-h:0)+"deg)")},setTransition:function(t){var e=this.$el;this.slides.transition(t).find(".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left").transition(t),this.params.cubeEffect.shadow&&!this.isHorizontal()&&e.find(".swiper-cube-shadow").transition(t)}},ft={setTranslate:function(){for(var t=this.slides,e=this.rtlTranslate,i=0;i<t.length;i+=1){var n=t.eq(i),r=n[0].progress;this.params.flipEffect.limitRotation&&(r=Math.max(Math.min(n[0].progress,1),-1));var s=-180*r,o=0,a=-n[0].swiperSlideOffset,l=0;if(this.isHorizontal()?e&&(s=-s):(l=a,o=-s,s=a=0),n[0].style.zIndex=-Math.abs(Math.round(r))+t.length,this.params.flipEffect.slideShadows){var u=this.isHorizontal()?n.find(".swiper-slide-shadow-left"):n.find(".swiper-slide-shadow-top"),c=this.isHorizontal()?n.find(".swiper-slide-shadow-right"):n.find(".swiper-slide-shadow-bottom");0===u.length&&(u=A('<div class="swiper-slide-shadow-'+(this.isHorizontal()?"left":"top")+'"></div>'),n.append(u)),0===c.length&&(c=A('<div class="swiper-slide-shadow-'+(this.isHorizontal()?"right":"bottom")+'"></div>'),n.append(c)),u.length&&(u[0].style.opacity=Math.max(-r,0)),c.length&&(c[0].style.opacity=Math.max(r,0))}n.transform("translate3d("+a+"px, "+l+"px, 0px) rotateX("+o+"deg) rotateY("+s+"deg)")}},setTransition:function(t){var i=this,e=i.slides,n=i.activeIndex,r=i.$wrapperEl;if(e.transition(t).find(".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left").transition(t),i.params.virtualTranslate&&0!==t){var s=!1;e.eq(n).transitionEnd(function(){if(!s&&i&&!i.destroyed){s=!0,i.animating=!1;for(var t=["webkitTransitionEnd","transitionend"],e=0;e<t.length;e+=1)r.trigger(t[e])}})}}},gt={setTranslate:function(){for(var t=this.width,e=this.height,i=this.slides,n=this.$wrapperEl,r=this.slidesSizesGrid,s=this.params.coverflowEffect,o=this.isHorizontal(),a=this.translate,l=o?t/2-a:e/2-a,u=o?s.rotate:-s.rotate,c=s.depth,h=0,d=i.length;h<d;h+=1){var p=i.eq(h),f=r[h],g=(l-p[0].swiperSlideOffset-f/2)/f*s.modifier,m=o?u*g:0,v=o?0:u*g,y=-c*Math.abs(g),b=s.stretch;"string"==typeof b&&-1!==b.indexOf("%")&&(b=parseFloat(s.stretch)/100*f);var w=o?0:b*g,_=o?b*g:0;Math.abs(_)<.001&&(_=0),Math.abs(w)<.001&&(w=0),Math.abs(y)<.001&&(y=0),Math.abs(m)<.001&&(m=0),Math.abs(v)<.001&&(v=0);var x="translate3d("+_+"px,"+w+"px,"+y+"px)  rotateX("+v+"deg) rotateY("+m+"deg)";if(p.transform(x),p[0].style.zIndex=1-Math.abs(Math.round(g)),s.slideShadows){var T=o?p.find(".swiper-slide-shadow-left"):p.find(".swiper-slide-shadow-top"),S=o?p.find(".swiper-slide-shadow-right"):p.find(".swiper-slide-shadow-bottom");0===T.length&&(T=A('<div class="swiper-slide-shadow-'+(o?"left":"top")+'"></div>'),p.append(T)),0===S.length&&(S=A('<div class="swiper-slide-shadow-'+(o?"right":"bottom")+'"></div>'),p.append(S)),T.length&&(T[0].style.opacity=0<g?g:0),S.length&&(S[0].style.opacity=0<-g?-g:0)}}(C.pointerEvents||C.prefixedPointerEvents)&&(n[0].style.perspectiveOrigin=l+"px 50%")},setTransition:function(t){this.slides.transition(t).find(".swiper-slide-shadow-top, .swiper-slide-shadow-right, .swiper-slide-shadow-bottom, .swiper-slide-shadow-left").transition(t)}},mt={init:function(){var t=this.params.thumbs,e=this.constructor;t.swiper instanceof e?(this.thumbs.swiper=t.swiper,st.extend(this.thumbs.swiper.originalParams,{watchSlidesProgress:!0,slideToClickedSlide:!1}),st.extend(this.thumbs.swiper.params,{watchSlidesProgress:!0,slideToClickedSlide:!1})):st.isObject(t.swiper)&&(this.thumbs.swiper=new e(st.extend({},t.swiper,{watchSlidesVisibility:!0,watchSlidesProgress:!0,slideToClickedSlide:!1})),this.thumbs.swiperCreated=!0),this.thumbs.swiper.$el.addClass(this.params.thumbs.thumbsContainerClass),this.thumbs.swiper.on("tap",this.thumbs.onThumbClick)},onThumbClick:function(){var t=this.thumbs.swiper;if(t){var e=t.clickedIndex,i=t.clickedSlide;if(!(i&&A(i).hasClass(this.params.thumbs.slideThumbActiveClass)||null==e)){var n;if(n=t.params.loop?parseInt(A(t.clickedSlide).attr("data-swiper-slide-index"),10):e,this.params.loop){var r=this.activeIndex;this.slides.eq(r).hasClass(this.params.slideDuplicateClass)&&(this.loopFix(),this._clientLeft=this.$wrapperEl[0].clientLeft,r=this.activeIndex);var s=this.slides.eq(r).prevAll('[data-swiper-slide-index="'+n+'"]').eq(0).index(),o=this.slides.eq(r).nextAll('[data-swiper-slide-index="'+n+'"]').eq(0).index();n=void 0===s?o:void 0===o?s:o-r<r-s?o:s}this.slideTo(n)}}},update:function(t){var e=this.thumbs.swiper;if(e){var i="auto"===e.params.slidesPerView?e.slidesPerViewDynamic():e.params.slidesPerView,n=this.params.thumbs.autoScrollOffset,r=n&&!e.params.loop;if(this.realIndex!==e.realIndex||r){var s,o,a=e.activeIndex;if(e.params.loop){e.slides.eq(a).hasClass(e.params.slideDuplicateClass)&&(e.loopFix(),e._clientLeft=e.$wrapperEl[0].clientLeft,a=e.activeIndex);var l=e.slides.eq(a).prevAll('[data-swiper-slide-index="'+this.realIndex+'"]').eq(0).index(),u=e.slides.eq(a).nextAll('[data-swiper-slide-index="'+this.realIndex+'"]').eq(0).index();s=void 0===l?u:void 0===u?l:u-a==a-l?a:u-a<a-l?u:l,o=this.activeIndex>this.previousIndex?"next":"prev"}else o=(s=this.realIndex)>this.previousIndex?"next":"prev";r&&(s+="next"===o?n:-1*n),e.visibleSlidesIndexes&&e.visibleSlidesIndexes.indexOf(s)<0&&(e.params.centeredSlides?s=a<s?s-Math.floor(i/2)+1:s+Math.floor(i/2)-1:a<s&&(s=s-i+1),e.slideTo(s,t?0:void 0))}var c=1,h=this.params.thumbs.slideThumbActiveClass;if(1<this.params.slidesPerView&&!this.params.centeredSlides&&(c=this.params.slidesPerView),this.params.thumbs.multipleActiveThumbs||(c=1),c=Math.floor(c),e.slides.removeClass(h),e.params.loop||e.params.virtual&&e.params.virtual.enabled)for(var d=0;d<c;d+=1)e.$wrapperEl.children('[data-swiper-slide-index="'+(this.realIndex+d)+'"]').addClass(h);else for(var p=0;p<c;p+=1)e.slides.eq(this.realIndex+p).addClass(h)}}},vt=[j,H,V,U,K,Y,Q,{name:"mousewheel",params:{mousewheel:{enabled:!1,releaseOnEdges:!1,invert:!1,forceToAxis:!1,sensitivity:1,eventsTarged:"container"}},create:function(){st.extend(this,{mousewheel:{enabled:!1,enable:J.enable.bind(this),disable:J.disable.bind(this),handle:J.handle.bind(this),handleMouseEnter:J.handleMouseEnter.bind(this),handleMouseLeave:J.handleMouseLeave.bind(this),animateSlider:J.animateSlider.bind(this),releaseScroll:J.releaseScroll.bind(this),lastScrollTime:st.now(),lastEventBeforeSnap:void 0,recentWheelEvents:[]}})},on:{init:function(){!this.params.mousewheel.enabled&&this.params.cssMode&&this.mousewheel.disable(),this.params.mousewheel.enabled&&this.mousewheel.enable()},destroy:function(){this.params.cssMode&&this.mousewheel.enable(),this.mousewheel.enabled&&this.mousewheel.disable()}}},{name:"navigation",params:{navigation:{nextEl:null,prevEl:null,hideOnClick:!1,disabledClass:"swiper-button-disabled",hiddenClass:"swiper-button-hidden",lockClass:"swiper-button-lock"}},create:function(){st.extend(this,{navigation:{init:Z.init.bind(this),update:Z.update.bind(this),destroy:Z.destroy.bind(this),onNextClick:Z.onNextClick.bind(this),onPrevClick:Z.onPrevClick.bind(this)}})},on:{init:function(){this.navigation.init(),this.navigation.update()},toEdge:function(){this.navigation.update()},fromEdge:function(){this.navigation.update()},destroy:function(){this.navigation.destroy()},click:function(t){var e,i=this.navigation,n=i.$nextEl,r=i.$prevEl;!this.params.navigation.hideOnClick||A(t.target).is(r)||A(t.target).is(n)||(n?e=n.hasClass(this.params.navigation.hiddenClass):r&&(e=r.hasClass(this.params.navigation.hiddenClass)),!0===e?this.emit
1("navigationShow",this):this.emit("navigationHide",this),n&&n.toggleClass(this.params.navigation.hiddenClass),r&&r.toggleClass(this.params.navigation.hiddenClass))}}},{name:"pagination",params:{pagination:{el:null,bulletElement:"span",clickable:!1,hideOnClick:!1,renderBullet:null,renderProgressbar:null,renderFraction:null,renderCustom:null,progressbarOpposite:!1,type:"bullets",dynamicBullets:!1,dynamicMainBullets:1,formatFractionCurrent:function(t){return t},formatFractionTotal:function(t){return t},bulletClass:"swiper-pagination-bullet",bulletActiveClass:"swiper-pagination-bullet-active",modifierClass:"swiper-pagination-",currentClass:"swiper-pagination-current",totalClass:"swiper-pagination-total",hiddenClass:"swiper-pagination-hidden",progressbarFillClass:"swiper-pagination-progressbar-fill",progressbarOppositeClass:"swiper-pagination-progressbar-opposite",clickableClass:"swiper-pagination-clickable",lockClass:"swiper-pagination-lock"}},create:function(){st.extend(this,{pagination:{init:tt.init.bind(this),render:tt.render.bind(this),update:tt.update.bind(this),destroy:tt.destroy.bind(this),dynamicBulletIndex:0}})},on:{init:function(){this.pagination.init(),this.pagination.render(),this.pagination.update()},activeIndexChange:function(){(this.params.loop||void 0===this.snapIndex)&&this.pagination.update()},snapIndexChange:function(){this.params.loop||this.pagination.update()},slidesLengthChange:function(){this.params.loop&&(this.pagination.render(),this.pagination.update())},snapGridLengthChange:function(){this.params.loop||(this.pagination.render(),this.pagination.update())},destroy:function(){this.pagination.destroy()},click:function(t){this.params.pagination.el&&this.params.pagination.hideOnClick&&0<this.pagination.$el.length&&!A(t.target).hasClass(this.params.pagination.bulletClass)&&(!0===this.pagination.$el.hasClass(this.params.pagination.hiddenClass)?this.emit("paginationShow",this):this.emit("paginationHide",this),this.pagination.$el.toggleClass(this.params.pagination.hiddenClass))}}},{name:"scrollbar",params:{scrollbar:{el:null,dragSize:"auto",hide:!1,draggable:!1,snapOnRelease:!0,lockClass:"swiper-scrollbar-lock",dragClass:"swiper-scrollbar-drag"}},create:function(){st.extend(this,{scrollbar:{init:et.init.bind(this),destroy:et.destroy.bind(this),updateSize:et.updateSize.bind(this),setTranslate:et.setTranslate.bind(this),setTransition:et.setTransition.bind(this),enableDraggable:et.enableDraggable.bind(this),disableDraggable:et.disableDraggable.bind(this),setDragPosition:et.setDragPosition.bind(this),getPointerPosition:et.getPointerPosition.bind(this),onDragStart:et.onDragStart.bind(this),onDragMove:et.onDragMove.bind(this),onDragEnd:et.onDragEnd.bind(this),isTouched:!1,timeout:null,dragTimeout:null}})},on:{init:function(){this.scrollbar.init(),this.scrollbar.updateSize(),this.scrollbar.setTranslate()},update:function(){this.scrollbar.updateSize()},resize:function(){this.scrollbar.updateSize()},observerUpdate:function(){this.scrollbar.updateSize()},setTranslate:function(){this.scrollbar.setTranslate()},setTransition:function(t){this.scrollbar.setTransition(t)},destroy:function(){this.scrollbar.destroy()}}},{name:"parallax",params:{parallax:{enabled:!1}},create:function(){st.extend(this,{parallax:{setTransform:it.setTransform.bind(this),setTranslate:it.setTranslate.bind(this),setTransition:it.setTransition.bind(this)}})},on:{beforeInit:function(){this.params.parallax.enabled&&(this.params.watchSlidesProgress=!0,this.originalParams.watchSlidesProgress=!0)},init:function(){this.params.parallax.enabled&&this.parallax.setTranslate()},setTranslate:function(){this.params.parallax.enabled&&this.parallax.setTranslate()},setTransition:function(t){this.params.parallax.enabled&&this.parallax.setTransition(t)}}},{name:"zoom",params:{zoom:{enabled:!1,maxRatio:3,minRatio:1,toggle:!0,containerClass:"swiper-zoom-container",zoomedSlideClass:"swiper-slide-zoomed"}},create:function(){var n=this,e={enabled:!1,scale:1,currentScale:1,isScaling:!1,gesture:{$slideEl:void 0,slideWidth:void 0,slideHeight:void 0,$imageEl:void 0,$imageWrapEl:void 0,maxRatio:3},image:{isTouched:void 0,isMoved:void 0,currentX:void 0,currentY:void 0,minX:void 0,minY:void 0,maxX:void 0,maxY:void 0,width:void 0,height:void 0,startX:void 0,startY:void 0,touchesStart:{},touchesCurrent:{}},velocity:{x:void 0,y:void 0,prevPositionX:void 0,prevPositionY:void 0,prevTime:void 0}};"onGestureStart onGestureChange onGestureEnd onTouchStart onTouchMove onTouchEnd onTransitionEnd toggle enable disable in out".split(" ").forEach(function(t){e[t]=nt[t].bind(n)}),st.extend(n,{zoom:e});var r=1;Object.defineProperty(n.zoom,"scale",{get:function(){return r},set:function(t){if(r!==t){var e=n.zoom.gesture.$imageEl?n.zoom.gesture.$imageEl[0]:void 0,i=n.zoom.gesture.$slideEl?n.zoom.gesture.$slideEl[0]:void 0;n.emit("zoomChange",t,e,i)}r=t}})},on:{init:function(){this.params.zoom.enabled&&this.zoom.enable()},destroy:function(){this.zoom.disable()},touchStart:function(t){this.zoom.enabled&&this.zoom.onTouchStart(t)},touchEnd:function(t){this.zoom.enabled&&this.zoom.onTouchEnd(t)},doubleTap:function(t){this.params.zoom.enabled&&this.zoom.enabled&&this.params.zoom.toggle&&this.zoom.toggle(t)},transitionEnd:function(){this.zoom.enabled&&this.params.zoom.enabled&&this.zoom.onTransitionEnd()},slideChange:function(){this.zoom.enabled&&this.params.zoom.enabled&&this.params.cssMode&&this.zoom.onTransitionEnd()}}},{name:"lazy",params:{lazy:{enabled:!1,loadPrevNext:!1,loadPrevNextAmount:1,loadOnTransitionStart:!1,elementClass:"swiper-lazy",loadingClass:"swiper-lazy-loading",loadedClass:"swiper-lazy-loaded",preloaderClass:"swiper-lazy-preloader"}},create:function(){st.extend(this,{lazy:{initialImageLoaded:!1,load:ot.load.bind(this),loadInSlide:ot.loadInSlide.bind(this)}})},on:{beforeInit:function(){this.params.lazy.enabled&&this.params.preloadImages&&(this.params.preloadImages=!1)},init:function(){this.params.lazy.enabled&&!this.params.loop&&0===this.params.initialSlide&&this.lazy.load()},scroll:function(){this.params.freeMode&&!this.params.freeModeSticky&&this.lazy.load()},resize:function(){this.params.lazy.enabled&&this.lazy.load()},scrollbarDragMove:function(){this.params.lazy.enabled&&this.lazy.load()},transitionStart:function(){this.params.lazy.enabled&&(this.params.lazy.loadOnTransitionStart||!this.params.lazy.loadOnTransitionStart&&!this.lazy.initialImageLoaded)&&this.lazy.load()},transitionEnd:function(){this.params.lazy.enabled&&!this.params.lazy.loadOnTransitionStart&&this.lazy.load()},slideChange:function(){this.params.lazy.enabled&&this.params.cssMode&&this.lazy.load()}}},{name:"controller",params:{controller:{control:void 0,inverse:!1,by:"slide"}},create:function(){st.extend(this,{controller:{control:this.params.controller.control,getInterpolateFunction:at.getInterpolateFunction.bind(this),setTranslate:at.setTranslate.bind(this),setTransition:at.setTransition.bind(this)}})},on:{update:function(){this.controller.control&&this.controller.spline&&(this.controller.spline=void 0,delete this.controller.spline)},resize:function(){this.controller.control&&this.controller.spline&&(this.controller.spline=void 0,delete this.controller.spline)},observerUpdate:function(){this.controller.control&&this.controller.spline&&(this.controller.spline=void 0,delete this.controller.spline)},setTranslate:function(t,e){this.controller.control&&this.controller.setTranslate(t,e)},setTransition:function(t,e){this.controller.control&&this.controller.setTransition(t,e)}}},{name:"a11y",params:{a11y:{enabled:!0,notificationClass:"swiper-notification",prevSlideMessage:"Previous slide",nextSlideMessage:"Next slide",firstSlideMessage:"This is the first slide",lastSlideMessage:"This is the last slide",paginationBulletMessage:"Go to slide {{index}}"}},create:function(){var e=this;st.extend(e,{a11y:{liveRegion:A('<span class="'+e.params.a11y.notificationClass+'" aria-live="assertive" aria-atomic="true"></span>')}}),Object.keys(lt).forEach(function(t){e.a11y[t]=lt[t].bind(e)})},on:{init:function(){this.params.a11y.enabled&&(this.a11y.init(),this.a11y.updateNavigation())},toEdge:function(){this.params.a11y.enabled&&this.a11y.updateNavigation()},fromEdge:function(){this.params.a11y.enabled&&this.a11y.updateNavigation()},paginationUpdate:function(){this.params.a11y.enabled&&this.a11y.updatePagination()},destroy:function(){this.params.a11y.enabled&&this.a11y.destroy()}}},{name:"history",params:{history:{enabled:!1,replaceState:!1,key:"slides"}},create:function(){st.extend(this,{history:{init:ut.init.bind(this),setHistory:ut.setHistory.bind(this),setHistoryPopState:ut.setHistoryPopState.bind(this),scrollToSlide:ut.scrollToSlide.bind(this),destroy:ut.destroy.bind(this)}})},on:{init:function(){this.params.history.enabled&&this.history.init()},destroy:function(){this.params.history.enabled&&this.history.destroy()},transitionEnd:function(){this.history.initialized&&this.history.setHistory(this.params.history.key,this.activeIndex)},slideChange:function(){this.history.initialized&&this.params.cssMode&&this.history.setHistory(this.params.history.key,this.activeIndex)}}},{name:"hash-navigation",params:{hashNavigation:{enabled:!1,replaceState:!1,watchState:!1}},create:function(){st.extend(this,{hashNavigation:{initialized:!1,init:ct.init.bind(this),destroy:ct.destroy.bind(this),setHash:ct.setHash.bind(this),onHashCange:ct.onHashCange.bind(this)}})},on:{init:function(){this.params.hashNavigation.enabled&&this.hashNavigation.init()},destroy:function(){this.params.hashNavigation.enabled&&this.hashNavigation.destroy()},transitionEnd:function(){this.hashNavigation.initialized&&this.hashNavigation.setHash()},slideChange:function(){this.hashNavigation.initialized&&this.params.cssMode&&this.hashNavigation.setHash()}}},{name:"autoplay",params:{autoplay:{enabled:!1,delay:3e3,waitForTransition:!0,disableOnInteraction:!0,stopOnLastSlide:!1,reverseDirection:!1}},create:function(){var e=this;st.extend(e,{autoplay:{running:!1,paused:!1,run:ht.run.bind(e),start:ht.start.bind(e),stop:ht.stop.bind(e),pause:ht.pause.bind(e),onVisibilityChange:function(){"hidden"===document.visibilityState&&e.autoplay.running&&e.autoplay.pause(),"visible"===document.visibilityState&&e.autoplay.paused&&(e.autoplay.run(),e.autoplay.paused=!1)},onTransitionEnd:function(t){e&&!e.destroyed&&e.$wrapperEl&&t.target===this&&(e.$wrapperEl[0].removeEventListener("transitionend",e.autoplay.onTransitionEnd),e.$wrapperEl[0].removeEventListener("webkitTransitionEnd",e.autoplay.onTransitionEnd),e.autoplay.paused=!1,e.autoplay.running?e.autoplay.run():e.autoplay.stop())}}})},on:{init:function(){this.params.autoplay.enabled&&(this.autoplay.start(),document.addEventListener("visibilitychange",this.autoplay.onVisibilityChange))},beforeTransitionStart:function(t,e){this.autoplay.running&&(e||!this.params.autoplay.disableOnInteraction?this.autoplay.pause(t):this.autoplay.stop())},sliderFirstMove:function(){this.autoplay.running&&(this.params.autoplay.disableOnInteraction?this.autoplay.stop():this.autoplay.pause())},touchEnd:function(){this.params.cssMode&&this.autoplay.paused&&!this.params.autoplay.disableOnInteraction&&this.autoplay.run()},destroy:function(){this.autoplay.running&&this.autoplay.stop(),document.removeEventListener("visibilitychange",this.autoplay.onVisibilityChange)}}},{name:"effect-fade",params:{fadeEffect:{crossFade:!1}},create:function(){st.extend(this,{fadeEffect:{setTranslate:dt.setTranslate.bind(this),setTransition:dt.setTransition.bind(this)}})},on:{beforeInit:function(){if("fade"===this.params.effect){this.classNames.push(this.params.containerModifierClass+"fade");var t={slidesPerView:1,slidesPerColumn:1,slidesPerGroup:1,watchSlidesProgress:!0,spaceBetween:0,virtualTranslate:!0};st.extend(this.params,t),st.extend(this.originalParams,t)}},setTranslate:function(){"fade"===this.params.effect&&this.fadeEffect.setTranslate()},setTransition:function(t){"fade"===this.params.effect&&this.fadeEffect.setTransition(t)}}},{name:"effect-cube",params:{cubeEffect:{slideShadows:!0,shadow:!0,shadowOffset:20,shadowScale:.94}},create:function(){st.extend(this,{cubeEffect:{setTranslate:pt.setTranslate.bind(this),setTransition:pt.setTransition.bind(this)}})},on:{beforeInit:function(){if("cube"===this.params.effect){this.classNames.push(this.params.containerModifierClass+"cube"),this.classNames.push(this.params.containerModifierClass+"3d");var t={slidesPerView:1,slidesPerColumn:1,slidesPerGroup:1,watchSlidesProgress:!0,resistanceRatio:0,spaceBetween:0,centeredSlides:!1,virtualTranslate:!0};st.extend(this.params,t),st.extend(this.originalParams,t)}},setTranslate:function(){"cube"===this.params.effect&&this.cubeEffect.setTranslate()},setTransition:function(t){"cube"===this.params.effect&&this.cubeEffect.setTransition(t)}}},{name:"effect-flip",params:{flipEffect:{slideShadows:!0,limitRotation:!0}},create:function(){st.extend(this,{flipEffect:{setTranslate:ft.setTranslate.bind(this),setTransition:ft.setTransition.bind(this)}})},on:{beforeInit:function(){if("flip"===this.params.effect){this.classNames.push(this.params.containerModifierClass+"flip"),this.classNames.push(this.params.containerModifierClass+"3d");var t={slidesPerView:1,slidesPerColumn:1,slidesPerGroup:1,watchSlidesProgress:!0,spaceBetween:0,virtualTranslate:!0};st.extend(this.params,t),st.extend(this.originalParams,t)}},setTranslate:function(){"flip"===this.params.effect&&this.flipEffect.setTranslate()},setTransition:function(t){"flip"===this.params.effect&&this.flipEffect.setTransition(t)}}},{name:"effect-coverflow",params:{coverflowEffect:{rotate:50,stretch:0,depth:100,modifier:1,slideShadows:!0}},create:function(){st.extend(this,{coverflowEffect:{setTranslate:gt.setTranslate.bind(this),setTransition:gt.setTransition.bind(this)}})},on:{beforeInit:function(){"coverflow"===this.params.effect&&(this.classNames.push(this.params.containerModifierClass+"coverflow"),this.classNames.push(this.params.containerModifierClass+"3d"),this.params.watchSlidesProgress=!0,this.originalParams.watchSlidesProgress=!0)},setTranslate:function(){"coverflow"===this.params.effect&&this.coverflowEffect.setTranslate()},setTransition:function(t){"coverflow"===this.params.effect&&this.coverflowEffect.setTransition(t)}}},{name:"thumbs",params:{thumbs:{swiper:null,multipleActiveThumbs:!0,autoScrollOffset:0,slideThumbActiveClass:"swiper-slide-thumb-active",thumbsContainerClass:"swiper-container-thumbs"}},create:function(){st.extend(this,{thumbs:{swiper:null,init:mt.init.bind(this),update:mt.update.bind(this),onThumbClick:mt.onThumbClick.bind(this)}})},on:{beforeInit:function(){var t=this.params.thumbs;t&&t.swiper&&(this.thumbs.init(),this.thumbs.update(!0))},slideChange:function(){this.thumbs.swiper&&this.thumbs.update()},update:function(){this.thumbs.swiper&&this.thumbs.update()},resize:function(){this.thumbs.swiper&&this.thumbs.update()},observerUpdate:function(){this.thumbs.swiper&&this.thumbs.update()},setTransition:function(t){var e=this.thumbs.swiper;e&&e.setTransition(t)},beforeDestroy:function(){var t=this.thumbs.swiper;t&&this.thumbs.swiperCreated&&t&&t.destroy()}}}];return void 0===$.use&&($.use=$.Class.use,$.installModule=$.Class.installModule),$.use(vt),$}),$(document).ready(function(){0<$("._nv").length&&$("._nv").insertAfter(".header>._cntnr>._dlgo"),0<$(".hrt").length&&$(".hrt").insertAfter(".header>._cntnr>._nv"),$("._ddovly").hover(function(){0<$(this).find("._nvdd").length&&0==$(".overlay").length&&$("body").append('<div class="overlay"></div>')},function(){$("body").find(".overlay").remove()})}),function(t){"function"==typeof define&&define.amd?define(["jquery"],t):t(jQuery)}(function(E){function t(){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","Octob
1er","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},E.extend(this._defaults,this.regional[""]),this.regional.en=E.extend(!0,{},this.regional[""]),this.regional["en-US"]=E.extend(!0,{},this.regional.en),this.dpDiv=i(E("<div id='"+this._mainDivId+"' class='ui-datepicker ui-widget ui-widget-content ui-helper-clearfix ui-corner-all'></div>"))}function i(t){var e="button, .ui-datepicker-prev, .ui-datepicker-next, .ui-datepicker-calendar td a";return t.on("mouseout",e,function(){E(this).removeClass("ui-state-hover"),-1!==this.className.indexOf("ui-datepicker-prev")&&E(this).removeClass("ui-datepicker-prev-hover"),-1!==this.className.indexOf("ui-datepicker-next")&&E(this).removeClass("ui-datepicker-next-hover")}).on("mouseover",e,s)}function s(){E.datepicker._isDisabledDatepicker(v.inline?v.dpDiv.parent()[0]:v.input[0])||(E(this).parents(".ui-datepicker-calendar").find("a").removeClass("ui-state-hover"),E(this).addClass("ui-state-hover"),-1!==this.className.indexOf("ui-datepicker-prev")&&E(this).addClass("ui-datepicker-prev-hover"),-1!==this.className.indexOf("ui-datepicker-next")&&E(this).addClass("ui-datepicker-next-hover"))}function h(t,e){for(var i in E.extend(t,e),e)null==e[i]&&(t[i]=e[i]);return t}function e(e){return function(){var t=this.element.val();e.apply(this,arguments),this._refresh(),t!==this.element.val()&&this._trigger("change")}}E.ui=E.ui||{},E.ui.version="1.12.1";var n,r,o=0,a=Array.prototype.slice;E.cleanData=(r=E.cleanData,function(t){var e,i,n;for(n=0;null!=(i=t[n]);n++)try{(e=E._data(i,"events"))&&e.remove&&E(i).triggerHandler("remove")}catch(t){}r(t)}),E.widget=function(t,i,e){var n,r,s,o={},a=t.split(".")[0],l=a+"-"+(t=t.split(".")[1]);return e||(e=i,i=E.Widget),E.isArray(e)&&(e=E.extend.apply(null,[{}].concat(e))),E.expr[":"][l.toLowerCase()]=function(t){return!!E.data(t,l)},E[a]=E[a]||{},n=E[a][t],r=E[a][t]=function(t,e){return this._createWidget?void(arguments.length&&this._createWidget(t,e)):new r(t,e)},E.extend(r,n,{version:e.version,_proto:E.extend({},e),_childConstructors:[]}),(s=new i).options=E.widget.extend({},s.options),E.each(e,function(e,s){return E.isFunction(s)?void(o[e]=function(){function n(){return i.prototype[e].apply(this,arguments)}function r(t){return i.prototype[e].apply(this,t)}return function(){var t,e=this._super,i=this._superApply;return this._super=n,this._superApply=r,t=s.apply(this,arguments),this._super=e,this._superApply=i,t}}()):void(o[e]=s)}),r.prototype=E.widget.extend(s,{widgetEventPrefix:n&&s.widgetEventPrefix||t},o,{constructor:r,namespace:a,widgetName:t,widgetFullName:l}),n?(E.each(n._childConstructors,function(t,e){var i=e.prototype;E.widget(i.namespace+"."+i.widgetName,r,e._proto)}),delete n._childConstructors):i._childConstructors.push(r),E.widget.bridge(t,r),r},E.widget.extend=function(t){for(var e,i,n=a.call(arguments,1),r=0,s=n.length;r<s;r++)for(e in n[r])i=n[r][e],n[r].hasOwnProperty(e)&&void 0!==i&&(t[e]=E.isPlainObject(i)?E.isPlainObject(t[e])?E.widget.extend({},t[e],i):E.widget.extend({},i):i);return t},E.widget.bridge=function(s,e){var o=e.prototype.widgetFullName||s;E.fn[s]=function(i){var t="string"==typeof i,n=a.call(arguments,1
vendor: 5,495 bytes, line 1
1),r=this;return t?this.length||"instance"!==i?this.each(function(){var t,e=E.data(this,o);return"instance"===i?(r=e,!1):e?E.isFunction(e[i])&&"_"!==i.charAt(0)?(t=e[i].apply(e,n))!==e&&void 0!==t?(r=t&&t.jquery?r.pushStack(t.get()):t,!1):void 0:E.error("no such method '"+i+"' for "+s+" widget instance"):E.error("cannot call methods on "+s+" prior to initialization; attempted to call method '"+i+"'")}):r=void 0:(n.length&&(i=E.widget.extend.apply(null,[i].concat(n))),this.each(function(){var t=E.data(this,o);t?(t.option(i||{}),t._init&&t._init()):E.data(this,o,new e(i,this))})),r}},E.Widget=function(){},E.Widget._childConstructors=[],E.Widget.prototype={widgetName:"widget",widgetEventPrefix:"",defaultElement:"<div>",options:{classes:{},disabled:!1,create:null},_createWidget:function(t,e){e=E(e||this.defaultElement||this)[0],this.element=E(e),this.uuid=o++,this.eventNamespace="."+this.widgetName+this.uuid,this.bindings=E(),this.hoverable=E(),this.focusable=E(),this.classesElementLookup={},e!==this&&(E.data(e,this.widgetFullName,this),this._on(!0,this.element,{remove:function(t){t.target===e&&this.destroy()}}),this.document=E(e.style?e.ownerDocument:e.document||e),this.window=E(this.document[0].defaultView||this.document[0].parentWindow)),this.options=E.widget.extend({},this.options,this._getCreateOptions(),t),this._create(),this.options.disabled&&this._setOptionDisabled(this.options.disabled),this._trigger("create",null,this._getCreateEventData()),this._init()},_getCreateOptions:function(){return{}},_getCreateEventData:E.noop,_create:E.noop,_init:E.noop,destroy:function(){var i=this;this._destroy(),E.each(this.classesElementLookup,function(t,e){i._removeClass(e,t)}),this.element.off(this.eventNamespace).removeData(this.widgetFullName),this.widget().off(this.eventNamespace).removeAttr("aria-disabled"),this.bindings.off(this.eventNamespace)},_destroy:E.noop,widget:function(){return this.element},option:function(t,e){var i,n,r,s=t;if(0===arguments.length)return E.widget.extend({},this.options);if("string"==typeof t)if(s={},t=(i=t.split(".")).shift(),i.length){for(n=s[t]=E.widget.extend({},this.options[t]),r=0;i.length-1>r;r++)n[i[r]]=n[i[r]]||{},n=n[i[r]];if(t=i.pop(),1===arguments.length)return void 0===n[t]?null:n[t];n[t]=e}else{if(1===arguments.length)return void 0===this.options[t]?null:this.options[t];s[t]=e}return this._setOptions(s),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(t){var e,i,n;for(e in t)n=this.classesElementLookup[e],t[e]!==this.options.classes[e]&&n&&n.length&&(i=E(n.get()),this._removeClass(n,e),i.addClass(this._classes({element:i,keys:e,classes:t,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(r){function t(t,e){var i,n;for(n=0;t.length>n;n++)i=o.classesElementLookup[t[n]]||E(),i=r.add?E(E.unique(i.get().concat(r.element.get()))):E(i.not(r.element).get()),o.classesElementLookup[t[n]]=i,s.push(t[n]),e&&r.classes[t[n]]&&s.push(r.classes[t[n]])}var s=[],o=this;return r=E.extend({element:this.element,classes:this.options.classes||{}},r),this._on(r.element,{remove:"_untrackClassesElement"}),r.keys&&t(r.keys.match(/\S+/g)||[],!0),r.extra&&t(r.extra.match(/\S+/g)||[]),s.join(" ")},_untrackClassesElement:function(i){var n=this;E.each(n.classesElementLookup,function(t,e){-1!==E.inArray(i.target,e)&&(n.classesElementLookup[t]=E(e.not(i.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,n){n="boolean"==typeof n?n:i;var r="string"==typeof t||null===t,s={extra:r?e:i,keys:r?t:e,element:r?this.element:t,add:n};return s.element.toggleClass(this._classes(s),n),this},_on:function(o,a,t){var l,u=this;"boolean"!=typeof o&&(t=a,a=o,o=!1),t?(a=l=E(a),this.bindings=this.bindings.add(a)):(t=a,a=this.element,l=this.widget()),E.each(t,function(t,e){function i(){return o||!0!==u.options.disabled&&!E(this).hasClass("ui-state-disabled")?("string"==typeof e?u[e]:e).apply(u,arguments):void 0}"string"!=typeof e&&(i.guid=e.guid=e.guid||i.guid||E.guid++);var n=t.match(/^([\w:-]*)\s*(.*)$/),r=n[1]+u.eventNamespace,s=n[2];s?l.on(r,s,i):a.on(r,i)})},_off:function(t,e){e=(e||"").split(" ").join(this.eventNamespace+" ")+this.eventNamespace,t.off(e).off(e),this.bindings=E(this.bindings.not(t).get()),this.focusable=E(this.focusable.not(t).get()),this.hoverable=E(this.hoverable.not(t).get())},_delay:function(t,e){var i=this;return setTimeout(function(){return("string"==typeof t?i[t]:t).apply(i,arguments)},e||0)},_hoverable:function(t){this.hoverable=this.hoverable.add(t),this._on(t,{mouseenter:function(t){this._addClass(E(t.currentTarget),null,"ui-state-hover")},mouseleave:function(t){this._removeClass(E(t.currentTarget),null,"ui-state-hover")}})},_focusable:function(t){this.focusable=this.focusable.add(t),this._on(t,{focusin:function(t){this._addClass(E(t.currentTarget),null,"ui-state-focus")},focusout:function(t){this._removeClass(E(t.currentTarget),null,"ui-state-focus")}})}
1,_trigger:function(t,e,i){var n,r,s=this.options[t];if(i=i||{},(e=E.Event(e)).type=(t===this.widgetEventPrefix?t:this.widgetEventPrefix+t).toLowerCase(),e.target=this.element[0],r=e.originalEvent)for(n in r)n in e||(e[n]=r[n]);return this.element.trigger(e,i),!(E.isFunction(s)&&!1===s.apply(this.element[0],[e].concat(i))||e.isDefaultPrevented())}},E.each({show:"fadeIn",hide:"fadeOut"},function(s,o){E.Widget.prototype["_"+s]=function(e,t,i){"string"==typeof t&&(t={effect:t});var n,r=t?!0===t||"number"==typeof t?o:t.effect||o:s;"number"==typeof(t=t||{})&&(t={duration:t}),n=!E.isEmptyObject(t),t.complete=i,t.delay&&e.delay(t.delay),n&&E.effects&&E.effects.effect[r]?e[s](t):r!==s&&e[r]?e[r](t.duration,t.easing,i):e.queue(function(t){E(this)[s](),i&&i.call(e[0]),t()})}}),E.widget,function(){function x(t,e,i){return[parseFloat(t[0])*(l.test(t[0])?e/100:1),parseFloat(t[1])*(l.test(t[1])?i/100:1)]}function T(t,e){return parseInt(E.css(t,e),10)||0}var r,S=Math.max,C=Math.abs,n=/left|center|right/,s=/top|center|bottom/,o=/[\+\-]\d+(\.[\d]+)?%?/,a=/^\w+/,l=/%$/,u=E.fn.position;E.position={scrollbarWidth:function(){if(void 0!==r)return r;var t,e,i=E("<div style='display:block;position:absolute;width:50px;height:50px;overflow:hidden;'><div style='height:100px;width:auto;'></div></div>"),n=i.children()[0];return E("body").append(i),t=n.offsetWidth,i.css("overflow","scroll"),t===(e=n.offsetWidth)&&(e=i[0].clientWidth),i.remove(),r=t-e},getScrollInfo:function(t){var e=t.isWindow||t.isDocument?"":t.element.css("overflow-x"),i=t.isWindow||t.isDocument?"":t.element.css("overflow-y"),n="scroll"===e||"auto"===e&&t.width<t.element[0].scrollWidth;return{width:"scroll"===i||"auto"===i&&t.height<t.element[0].scrollHeight?E.position.scrollbarWidth():0,height:n?E.position.scrollbarWidth():0}},getWithinInfo:function(t){var e=E(t||window),i=E.isWindow(e[0]),n=!!e[0]&&9===e[0].nodeType;return{element:e,isWindow:i,isDocument:n,offset:!i&&!n?E(t).offset():{left:0,top:0},scrollLeft:e.scrollLeft(),scrollTop:e.scrollTop(),width:e.outerWidth(),height:e.outerHeight()}}},E.fn.position=function(h){if(!h||!h.of)return u.apply(this,arguments);h=E.extend({},h);var d,p,f,g,m,t,e,i,v=E(h.of),y=E.position.getWithinInfo(h.within),b=E.position.getScrollInfo(y),w=(h.collision||"flip").split(" "),_={};return t=9===(i=(e=v)[0]).nodeType?{width:e.width(),height:e.height(),offset:{top:0,left:0}}:E.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()},v[0].preventDefault&&(h.at="left top"),p=t.width,f=t.height,g=t.offset,m=E.extend({},g),E.each(["my","at"],function(){var t,e,i=(h[this]||"").split(" ");1===i.length&&(i=n.test(i[0])?i.concat(["center"]):s.test(i[0])?["center"].concat(i):["center","center"]),i[0]=n.test(i[0])?i[0]:"center",i[1]=s.test(i[1])?i[1]:"center",t=o.exec(i[0]),e=o.exec(i[1]),_[this]=[t?t[0]:0,e?e[0]:0],h[this]=[a.exec(i[0])[0],a.exec(i[1])[0]]}),1===w.length&&(w[1]=w[0]),"right"===h.at[0]?m.left+=p:"center"===h.at[0]&&(m.left+=p/2),"bottom"===h.at[1]?m.top+=f:"center"===h.at[1]&&(m.top+=f/2),d=x(_.at,p,f),m.left+=d[0],m.top+=d[1],this.each(function(){var i,t,o=E(this),a=o.outerWidth(),l=o.outerHeight(),e=T(this,"marginLeft"),n=T(this,"marginTop"),r=a+e+T(this,"marginRight")+b.width,s=l+n+T(this,"marginBottom")+b.height,u=E.extend({},m),c=x(_.my,o.outerWidth(),o.outerHeight());"right"===h.my[0]?u.left-=a:"center"===h.my[0]&&(u.left-=a/2),"bottom"===h.my[1]?u.top-=l:"center"===h.my[1]&&(u.top-=l/2),u.left+=c[0],u.top+=c[1],i={marginLeft:e,marginTop:n},E.each(["left","top"],function(t,e){E.ui.position[w[t]]&&E.ui.position[w[t]][e](u,{targetWidth:p,targetHeight:f,elemWidth:a,elemHeight:l,collisionPosition:i,collisionWidth:r,collisionHeight:s,offset:[d[0]+c[0],d[1]+c[1]],my:h.my,at:h.at,within:y,elem:o})}),h.using&&(t=function(t){var e=g.left-u.left,i=e+p-a,n=g.top-u.top,r=n+f-l,s={target:{element:v,left:g.left,top:g.top,width:p,height:f},element:{element:o,left:u.left,top:u.top,width:a,height:l},horizontal:i<0?"left":0<e?"right":"center",vertical:r<0?"top":0<n?"bottom":"middle"};p<a&&p>C(e+i)&&(s.horizontal="center"),f<l&&f>C(n+r)&&(s.vertical="middle"),s.important=S(C(e),C(i))>S(C(n),C(r))?"horizontal":"vertical",h.using.call(this,t,s)}),o.offset(E.extend(u,{using:t}))})},E.ui.position={fit:{left:function(t,e){var i,n=e.within,r=n.isWindow?n.scrollLeft:n.offset.left,s=n.width,o=t.left-e.collisionPosition.marginLeft,a=r-o,l=o+e.collisionWidth-s-r;e.collisionWidth>s?0<a&&l<=0?(i=t.left+a+e.collisionWidth-s-r,t.left+=a-i):t.left=0<l&&a<=0?r:l<a?r+s-e.collisionWidth:r:0<a?t.left+=a:0<l?t.left-=l:t.left=S(t.left-o,t.left)},top:function(t,e){var i,n=e.within,r=n.isWindow?n.scrollTop:n.offset.top,s=e.within.height,o=t.top-e.collisionPosition.marginTop,a=r-o,l=o+e.collisionHeight-s-r;e.collisionHeight>s?0<a&&l<=0?(i=t.top+a+e.collisionHeight-s-r,t.top+=a-i):t.top=0<l&&a<=0?r:l<a?r+s-e.collisionHeight:r:0<a?t.top+=a:0<l?t.top-=l:t.top=S(t.top-o,t.top)}},flip:{left:function(t,e){var i,n,r=e.within,s=r.offset.left+r.scrollLeft,o=r.width,a=r.isWindow?r.scrollLeft:r.offset.left,l=t.left-e.collisionPosition.marginLeft,u=l-a,c=l+e.collisionWidth-o-a,h="left"===e.my[0]?-e.elemWidth:"right"===e.my[0]?e.elemWidth:0,d="left"===e.at[0]?e.targetWidth:"right"===e.at[0]?-e.targetWidth:0,p=-2*e.offset[0];u<0?((i=t.left+h+d+p+e.collisionWidth-o-s)<0||C(u)>i)&&(t.left+=h+d+p):0<c&&((0<(n=t.left-e.collisionPosition.marginLeft+h+d+p-a)||c>C(n))&&(t.left+=h+d+p))},top:function(t,e){var i,n,r=e.within,s=r.offset.top+r.scrollTop,o=r.height,a=r.isWindow?r.scrollTop:r.offset.top,l=t.top-e.collisionPosition.marginTop,u=l-a,c=l+e.collisionHeight-o-a,h="top"===e.my[1]?-e.elemHeight:"bottom"===e.my[1]?e.elemHeight:0,d="top"===e.at[1]?e.targetHeight:"bottom"===e.at[1]?-e.targetHeight:0,p=-2*e.offset[1];u<0?((n=t.top+h+d+p+e.collisionHeight-o-s)<0||C(u)>n)&&(t.top+=h+d+p):0<c&&((0<(i=t.top-e.collisionPosition.marginTop+h+d+p-a)||c>C(i))&&(t.top+=h+d+p))}},flipfit:{left:function(){E.ui.position.flip.left.apply(this,arguments),E.ui.position.fit.left.apply(this,arguments)},top:function(){E.ui.position.flip.top.apply(this,arguments),E.ui.position.fit.top.apply(this,arguments)}}}}(),E.ui.position,E.extend(E.expr[":"],{data:E.expr.createPseudo?E.expr.createPseudo(function(e){return function(t){return!!E.data(t,e)}}
1):function(t,e,i){return!!E.data(t,i[3])}}),E.fn.extend({disableSelection:(n="onselectstart"in document.createElement("div")?"selectstart":"mousedown",function(){return this.on(n+".ui-disableSelection",function(t){t.preventDefault()})}),enableSelection:function(){return this.off(".ui-disableSelection")}});var l,u="ui-effects-",d="ui-effects-style",p="ui-effects-animated",c=E;E.effects={effect:{}},function(c,h){function d(t,e,i){var n=m[e.type]||{};return null==t?i||!e.def?null:e.def:(t=n.floor?~~t:parseFloat(t),isNaN(t)?e.def:n.mod?(t+n.mod)%n.mod:t<0?0:t>n.max?n.max:t)}function a(o){var a=f(),l=a._rgba=[];return o=o.toLowerCase(),v(t,function(t,e){var i,n=e.re.exec(o),r=n&&e.parse(n),s=e.space||"rgba";return r?(i=a[s](r),a[g[s].cache]=i[g[s].cache],l=a._rgba=i._rgba,!1):h}),l.length?("0,0,0,0"===l.join()&&c.extend(l,u.transparent),a):u[o]}function l(t,e,i){return 6*(i=(i+1)%1)<1?t+6*(e-t)*i:2*i<1?e:3*i<2?t+6*(e-t)*(2/3-i):t}var u,p=/^([\-+])=\s*(\d+\.?\d*)/,t=[{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]]}}],f=c.Color=function(t,e,i,n){return new c.Color.fn.parse(t,e,i,n)},g={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"}}}},m={byte:{floor:!0,max:255},percent:{max:1},degrees:{mod:360,floor:!0}},o=f.support={},e=c("<p>")[0],v=c.each;e.style.cssText="background-color:rgba(1,1,1,.5)",o.rgba=-1<e.style.backgroundColor.indexOf("rgba"),v(g,function(t,e){e.cache="_"+t,e.props.alpha={idx:3,type:"percent",def:1}}),f.fn=c.extend(f.prototype,{parse:function(r,t,e,i){if(r===h)return this._rgba=[null,null,null,null],this;(r.jquery||r.nodeType)&&(r=c(r).css(t),t=h);var s=this,n=c.type(r),o=this._rgba=[];return t!==h&&(r=[r,t,e,i],n="array"),"string"===n?this.parse(a(r)||u._default):"array"===n?(v(g.rgba.props,function(t,e){o[e.idx]=d(r[e.idx],e)}),this):"object"===n?(v(g,r instanceof f?function(t,e){r[e.cache]&&(s[e.cache]=r[e.cache].slice())}:function(t,i){var n=i.cache;v(i.props,function(t,e){if(!s[n]&&i.to){if("alpha"===t||null==r[t])return;s[n]=i.to(s._rgba)}s[n][e.idx]=d(r[t],e,!0)}),s[n]&&c.inArray(null,s[n].slice(0,3))<0&&(s[n][3]=1,i.from&&(s._rgba=i.from(s[n])))}),this):h},is:function(t){var r=f(t),s=!0,o=this;return v(g,function(t,e){var i,n=r[e.cache];return n&&(i=o[e.cache]||e.to&&e.to(o._rgba)||[],v(e.props,function(t,e){return null!=n[e.idx]?s=n[e.idx]===i[e.idx]:h})),s}),s},_space:function(){var i=[],n=this;return v(g,function(t,e){n[e.cache]&&i.push(t)}),i.pop()},transition:function(t,o){var a=f(t),e=a._space(),i=g[e],n=0===this.alpha()?f("transparent"):this,l=n[i.cache]||i.to(n._rgba),u=l.slice();return a=a[i.cache],v(i.props,function(t,e){var i=e.idx,n=l[i],r=a[i],s=m[e.type]||{};null!==r&&(null===n?u[i]=r:(s.mod&&(r-n>s.mod/2?n+=s.mod:n-r>s.mod/2&&(n-=s.mod)),u[i]=d((r-n)*o+n,e)))}),this[e](u)},blend:function(t){if(1===this._rgba[3])return this;var e=this._rgba.slice(),i=e.pop(),n=f(t)._rgba;return f(c.map(e,function(t,e){return(1-i)*n[e]+i*t}))},toRgbaString:function(){var t="rgba(",e=c.map(this._rgba,function(t,e){return null==t?2<e?1:0:t});return 1===e[3]&&(e.pop(),t="rgb("),t+e.join()+")"},toHslaString:function(){var t="hsla(",e=c.map(this.hsla(),function(t,e){return null==t&&(t=2<e?1:0),e&&e<3&&(t=Math.round(100*t)+"%"),t});return 1===e[3]&&(e.pop(),t="hsl("),t+e.join()+")"},toHexString:function(t){var e=this._rgba.slice(),i=e.pop();return t&&e.push(~~(255*i)),"#"+c.map(e,function(t){return 1===(t=(t||0).toString(16)).length?"0"+t:t}).join("")},toString:function(){return 0===this._rgba[3]?"transparent":this.toRgbaString()}}),f.fn.parse.prototype=f.fn,g.hsla.to=function(t){if(null==t[0]||null==t[1]||null==t[2])return[null,
vendor: 39,447 bytes, line 1
1null,null,t[3]];var e,i,n=t[0]/255,r=t[1]/255,s=t[2]/255,o=t[3],a=Math.max(n,r,s),l=Math.min(n,r,s),u=a-l,c=a+l,h=.5*c;return e=l===a?0:n===a?60*(r-s)/u+360:r===a?60*(s-n)/u+120:60*(n-r)/u+240,i=0===u?0:h<=.5?u/c:u/(2-c),[Math.round(e)%360,i,h,null==o?1:o]},g.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],n=t[2],r=t[3],s=n<=.5?n*(1+i):n+i-n*i,o=2*n-s;return[Math.round(255*l(o,s,e+1/3)),Math.round(255*l(o,s,e)),Math.round(255*l(o,s,e-1/3)),r]},v(g,function(l,t){var i=t.props,o=t.cache,a=t.to,u=t.from;f.fn[l]=function(t){if(a&&!this[o]&&(this[o]=a(this._rgba)),t===h)return this[o].slice();var e,n=c.type(t),r="array"===n||"object"===n?t:arguments,s=this[o].slice();return v(i,function(t,e){var i=r["object"===n?t:e.idx];null==i&&(i=s[e.idx]),s[e.idx]=d(i,e)}),u?((e=f(u(s)))[o]=s,e):f(s)},v(i,function(o,a){f.fn[o]||(f.fn[o]=function(t){var e,i=c.type(t),n="alpha"===o?this._hsla?"hsla":"rgba":l,r=this[n](),s=r[a.idx];return"undefined"===i?s:("function"===i&&(t=t.call(this,s),i=c.type(t)),null==t&&a.empty?this:("string"===i&&((e=p.exec(t))&&(t=s+parseFloat(e[2])*("+"===e[1]?1:-1))),r[a.idx]=t,this[n](r)))})})}),f.hook=function(t){var e=t.split(" ");v(e,function(t,s){c.cssHooks[s]={set:function(t,e){var i,n,r="";if("transparent"!==e&&("string"!==c.type(e)||(i=a(e)))){if(e=f(i||e),!o.rgba&&1!==e._rgba[3]){for(n="backgroundColor"===s?t.parentNode:t;(""===r||"transparent"===r)&&n&&n.style;)try{r=c.css(n,"backgroundColor"),n=n.parentNode}catch(t){}e=e.blend(r&&"transparent"!==r?r:"_default")}e=e.toRgbaString()}try{t.style[s]=e}catch(t){}}},c.fx.step[s]=function(t){t.colorInit||(t.start=f(t.elem,s),t.end=f(t.end),t.colorInit=!0),c.cssHooks[s].set(t.elem,t.start.transition(t.end,t.pos))}})},f.hook("backgroundColor borderBottomColor borderLeftColor borderRightColor borderTopColor color columnRuleColor outlineColor textDecorationColor textEmphasisColor"),c.cssHooks.borderColor={expand:function(i){var n={};return v(["Top","Right","Bottom","Left"],function(t,e){n["border"+e+"Color"]=i}),n}},u=c.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"}}(c),function(){function o(t){var e,i,n=t.ownerDocument.defaultView?t.ownerDocument.defaultView.getComputedStyle(t,null):t.currentStyle,r={};if(n&&n.length&&n[0]&&n[n[0]])for(i=n.length;i--;)"string"==typeof n[e=n[i]]&&(r[E.camelCase(e)]=n[e]);else for(e in n)"string"==typeof n[e]&&(r[e]=n[e]);return r}var s,r,a,l=["add","remove","toggle"],u={border:1,borderBottom:1,borderColor:1,borderLeft:1,borderRight:1,borderTop:1,borderWidth:1,margin:1,padding:1};E.each(["borderLeftStyle","borderRightStyle","borderBottomStyle","borderTopStyle"],function(t,e){E.fx.step[e]=function(t){("none"!==t.end&&!t.setAttr||1===t.pos&&!t.setAttr)&&(c.style(t.elem,e,t.end),t.setAttr=!0)}}),E.fn.addBack||(E.fn.addBack=function(t){return this.add(null==t?this.prevObject:this.prevObject.filter(t))}),E.effects.animateClass=function(r,t,e,i){var s=E.speed(t,e,i);return this.queue(function(){var t,i=E(this),e=i.attr("class")||"",n=s.children?i.find("*").addBack():i;n=n.map(function(){return{el:E(this),start:o(this)}}),(t=function(){E.each(l,function(t,e){r[e]&&i[e+"Class"](r[e])})})(),n=n.map(function(){return this.end=o(this.el[0]),this.diff=function(t,e){var i,n,r={};for(i in e)n=e[i],t[i]!==n&&(u[i]||(E.fx.step[i]||!isNaN(parseFloat(n)))&&(r[i]=n));return r}(this.start,this.end),this}),i.attr("class",e),n=n.map(function(){var t=this,e=E.Deferred(),i=E.extend({},s,{queue:!1,complete:function(){e.resolve(t)}});return this.el.animate(this.diff,i),e.promise()}),E.when.apply(E,n.get()).done(function(){t(),E.each(arguments,function(){var e=this.el;E.each(this.diff,function(t){e.css(t,"")})}),s.complete.call(i[0])})})},E.fn.extend({addClass:(a=E.fn.addClass,function(t,e,i,n){return e?E.effects.animateClass.call(this,{add:t},e,i,n):a.apply(this,arguments)}),removeClass:(r=E.fn.removeClass,function(t,e,i,n){return 1<arguments.length?E.effects.animateClass.call(this,{remove:t},e,i,n):r.apply(this,arguments)}),toggleClass:(s=E.fn.toggleClass,function(t,e,i,n,r){return"boolean"==typeof e||void 0===e?i?E.effects.animateClass.call(this,e?{add:t}:{remove:t},i,n,r):s.apply(this,arguments):E.effects.animateClass.call(this,{toggle:t},e,i,n)}),switchClass:function(t,e,i,n,r){return E.effects.animateClass.call(this,{add:e,remove:t},i,n,r)}})}(),function(){function c(t,e,i,n){return E.isPlainObject(t)&&(t=(e=t).effect),t={effect:t},null==e&&(e={}),E.isFunction(e)&&(n=e,i=null,e={}),("number"==typeof e||E.fx.speeds[e])&&(n=i,i=e,e={}),E.isFunction(i)&&(n=i,i=null),e&&E.extend(t,e),i=i||e.duration,t.duration=E.fx.off?0:"number"==typeof i?i:i in E.fx.speeds?E.fx.speeds[i]:E.fx.speeds._default,t.complete=n||e.complete,t}function i(t){return!(t&&"number"!=typeof t&&!E.fx.speeds[t])||("string"==typeof t&&!E.effects.effect[t]||(!!E.isFunction(t)||"object"==typeof t&&!t.effect))}function e(t,e){var i=e.outerWidth(),n=e.outerHeight(),r=/^rect\((-?\d*\.?\d*px|-?\d+%|auto),?\s*(-?\d*\.?\d*px|-?\d+%|auto),?\s*(-?\d*\.?\d*px|-?\d+%|auto),?\s*(-?\d*\.?\d*px|-?\d+%|auto)\)$/.exec(t)||["",0,i,n,0];return{top:parseFloat(r[1])||0,right:"auto"===r[2]?i:parseFloat(r[2]),bottom:"auto"===r[3]?n:parseFloat(r[3]),left:parseFloat(r[4])||0}}var n,r,s,o;E.expr&&E.expr.filters&&E.expr.filters.animated&&(E.expr.filters.animated=(o=E.expr.filters.animated,function(t){return!!E(t).data(p)||o(t)})),!1!==E.uiBackCompat&&E.extend(E.effects,{save:function(t,e){for(var i=0,n=e.length;i<n;i++)null!==e[i]&&t.data(u+e[i],t[0].style[e[i]])},restore:function(t,e){for(var i,n=0,r=e.length;n<r;n++)null!==e[n]&&(i=t.data(u+e[n]),t.css(e[n],i))},setMode:function(t,e){return"toggle"===e&&(e=t.is(":hidden")?"show":"hide"),e},createWrapper:function(i){if(i.parent().is(".ui-effects-wrapper"))return i.parent();var n={width:i.outerWidth(!0),height:i.outerHeight(!0),float:i.css("float")},t=E("<div></div>").addClass("ui-effects-wrapper").css({fontSize:"100%",background:"transparent",border:"none",margin:0,padding:0}),e={width:i.width(),height:i.height()},r=document.activeElement;try{r.id}catch(t){r=document.body}return i.wrap(t),(i[0]===r||E.contains(i[0],r))&&E(r).trigger("focus"),t=i.parent(),"static"===i.css("position")?(t.css({position:"relative"}),i.css({position:"relative"})):(E.extend(n,{position:i.css("position"),zIndex:i.css("z-index")}),E.each(["top","left","bottom","right"],function(t,e){n[e]=i.css(e),isNaN(parseInt(n[e],10))&&(n[e]="auto")}),i.css({position:"relative",top:0,left:0,right:"auto",bottom:"auto"})),i.css(e),t.css(n).show()},removeWrapper:function(t){var e=document.activeElement;return t.parent().is(".ui-effects-wrapper")&&(t.parent().replaceWith(t),(t[0]===e||E.contains(t[0],e))&&E(e).trigger("focus")),t}}),E.extend(E.effects,{version:"1.12.1",define:function(t,e,i){return i||(i=e,e="effect"),E.effects.effect[t]=i,E.effects.effect[t].mode=e,i},scaledDimensions:function(t,e,i){if(0===e)return{height:0,width:0,outerHeight:0,outerWidth:0};var n="horizontal"!==i?(e||100)/100:1,r="vertical"!==i?(e||100)/100:1;return{height:t.height()*r,width:t.width()*n,outerHeight:t.outerHeight()*r,outerWidth:t.outerWidth()*n}},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 n=t.queue();1<e&&n.splice.apply(n,[1,0].concat(n.splice(e,i))),t.dequeue()},saveStyle:function(t){t.data(d,t[0].style.cssText)},restoreStyle:function(t){t[0].style.cssText=t.data(d)||"",t.removeData(d)},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,n;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":n=0;break;case"center":n=.5;break;case"right":n=1;break;default:n=t[1]/e.width}return{x:n,y:i}},createPlaceholder:function(t){var e,i=t.css("position"),n=t.position();return t.css({marginTop:t.css("marginTop"),marginBottom:t.css("marginBottom"),marginLeft:t.css("marginLeft"),marginRight:t.css("marginRight")}).outerWidth(t.outerWidth()).outerHeight(t.outerHeight()),/^(static|relative)/.test(i)&&(i="absolute",e=E("<"+t[0].nodeName+">").insertAfter(t).css({display:/^(inline|ruby)/.test(t.css("display"))?"inline-block":"block",visibility:"hidden",marginTop:t.css("marginTop"),marginBottom:t.css("marginBottom"),marginLeft:t.css("marginLeft"),marginRight:t.css("marginRight"),float:t.css("float")}).outerWidth(t.outerWidth()).outerHeight(t.outerHeight()).addClass("ui-effects-placeholder"),t.data(u+"placeholder",e)),t.css({position:i,left:n.left,top:n.top}),e},removePlaceholder:function(t){var e=u+"placeholder",i=t.data(e);i&&(i.remove(),t.removeData(e))},cleanUp:function(t){E.effects.restoreStyle(t),E.effects.removePlaceholder(t)},setTransition:function(n,t,r,s){return s=s||{},E.each(t,function(t,e){var i=n.cssUnit(e);0<i[0]&&(s[e]=i[0]*r+i[1])}),s}}),E.fn.extend({effect:function(){function t(t){function e(){E.isFunction(o)&&o.call(i[0]),E.isFunction(t)&&t()}var i=E(this);n.mode=l.shift(),!1===E.uiBackCompat||s?"none"===n.mode?(i[a](),e()):r.call(i[0],n,function(){i.removeData(p),E.effects.cleanUp(i),"hide"===n.mode&&i.hide(),e()}):(i.is(":hidden")?"hide"===a:"show"===a)?(i[a](),e()):r.call(i[0],n,e)}var n=c.apply(this,arguments),r=E.effects.effect[n.effect],s=r.mode,e=n.queue,i=e||"fx",o=n.complete,a=n.mode,l=[],u=function(t){var e=E(this),i=E.effects.mode(e,a)||s;e.data(p,!0),l.push(i),s&&("show"===i||i===s&&"hide"===i)&&e.show(),s&&"none"===i||E.effects.saveStyle(e),E.isFunction(t)&&t()};return E.fx.off||!r?a?this[a](n.duration,o):this.each(function(){o&&o.call(this)}):!1===e?this.each(u).each(t):this.queue(i,u).queue(i,t)},show:(s=E.fn.show,function(t){if(i(t))return s.apply(this,arguments);var e=c.apply(this,arguments);return e.mode="show",this.effect.call(this,e)}),hide:(r=E.fn.hide,function(t){if(i(t))return r.apply(this,arguments);var e=c.apply(this,arguments);return e.mode="hide",this.effect.call(this,e)}),toggle:(n=E.fn.toggle,function(t){if(i(t)||"boolean"==typeof t)return n.apply(this,arguments);var e=c.apply(this,arguments);return e.mode="toggle",this.effect.call(this,e)}),cssUnit:function(t){var i=this.css(t),n=[];return E.each(["em","px","%","pt"],function(t,e){0<i.indexOf(e)&&(n=[parseFloat(i),e])}),n},cssClip:function(t){return t?this.css("clip","rect("+t.top+"px "+t.right+"px "+t.bottom+"px "+t.left+"px)"):e(this.css("clip"),this)},transfer:function(t,e){var i=E(this),n=E(t.to),r="fixed"===n.css("position"),s=E("body"),o=r?s.scrollTop():0,a=r?s.scrollLeft():0,l=n.offset(),u={top:l.top-o,left:l.left-a,height:n.innerHeight(),width:n.innerWidth()},c=i.offset(),h=E("<div class='ui-effects-transfer'></div>").appendTo("body").addClass(t.className).css({top:c.top-o,left:c.left-a,height:i.innerHeight(),width:i.innerWidth(),position:r?"fixed":"absolute"}).animate(u,t.duration,t.easing,function(){h.remove(),E.isFunction(e)&&e()})}}),E.fx.step.clip=function(t){t.clipInit||(t.start=E(t.elem).cssClip(),"string"==typeof t.end&&(t.end=e(t.end,t.elem)),t.clipInit=!0),E(t.elem).cssClip({top:t.pos*(t.end.top-t.start.top)+t.start.top,right:t.pos*(t.end.right-t.start.right)+t.start.right,bottom:t.pos*(t.end.bottom-t.start.bottom)+t.start.bottom,left:t.pos*(t.end.left-t.start.left)+t.start.left})}}(),l={},E.each(["Quad","Cubic","Quart","Quint","Expo"],function(e,t){l[t]=function(t){return Math.pow(t,e+2)}}),E.extend(l,{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)}}),E.each(l,function(t,e){E.easing["easeIn"+t]=e,E.easing["easeOut"+t]=function(t){return 1-e(1-t)},E.easing["easeInOut"+t]=function(t){return t<.5?e(2*t)/2:1-e(-2*t+2)/2}});var f,g;E.effects;E.effects.define("blind","hide",function(t,e){var i={up:["bottom","top"],vertical:["bottom","top"],down:["top","bottom"],left:["right","left"],horizontal:["right","left"],right:["left","right"]},n=E(this),r=t.direction||"up",s=n.cssClip(),o={clip:E.extend({},s)},a=E.effects.createPlaceholder(n);o.clip[i[r][0]]=o.clip[i[r][1]],"show"===t.mode&&(n.cssClip(o.clip),a&&a.css(E.effects.clipToBox(o)),o.clip=s),a&&a.animate(E.effects.clipToBox(o),t.duration,t.easing),n.animate(o,{queue:!1,duration:t.duration,easing:t.easing,complete:e})}),E.effects.define("bounce",function(t,e){var i,n,r,s=E(this),o=t.mode,a="hide"===o,l="show"===o,u=t.direction||"up",c=t.distance,h=t.times||5,d=2*h+(l||a?1:0),p=t.duration/d,f=t.easing,g="up"===u||"down"===u?"top":"left",m="up"===u||"left"===u,v=0,y=s.queue().length;for(E.effects.createPlaceholder(s),r=s.css(g),c||(c=s["top"===g?"outerHeight":"outerWidth"]()/3),l&&((n={opacity:1})[g]=r,s.css("opacity",0).css(g,m?2*-c:2*c).animate(n,p,f)),a&&(c/=Math.pow(2,h-1)),(n={})[g]=r;v<h;v++)(i={})[g]=(m?"-=":"+=")+c,s.animate(i,p,f).animate(n,p,f),c=a?2*c:c/2;a&&((i={opacity:0})[g]=(m?"-=":"+=")+c,s.animate(i,p,f)),s.queue(e),E.effects.unshift(s,y,d+1)}),E.effects.define("clip","hide",function(t,e){var i,n={},r=E(this),s=t.direction||"vertical",o="both"===s,a=o||"horizontal"===s,l=o||"vertical"===s;i=r.cssClip(),n.clip={top:l?(i.bottom-i.top)/2:i.top,right:a?(i.right-i.left)/2:i.right,bottom:l?(i.bottom-i.top)/2:i.bottom,left:a?(i.right-i.left)/2:i.left},E.effects.createPlaceholder(r),"show"===t.mode&&(r.cssClip(n.clip),n.clip=i),r.animate(n,{queue:!1,duration:t.duration,easing:t.easing,complete:e})}),E.effects.define("drop","hide",function(t,e){var i,n=E(this),r="show"===t.mode,s=t.direction||"left",o="up"===s||"down"===s?"top":"left",a="up"===s||"left"===s?"-=":"+=",l="+="===a?"-=":"+=",u={opacity:0};E.effects.createPlaceholder(n),i=t.distance||n["top"===o?"outerHeight":"outerWidth"](!0)/2,u[o]=a+i,r&&(n.css(u),u[o]=l+i,u.opacity=1),n.animate(u,{queue:!1,duration:t.duration,easing:t.easing,complete:e})}),E.effects.define("explode","hide",function(t,e){function i(){m.push(this),m.length===u*c&&(h.css({visibility:"visible"}),E(m).remove(),e())}var n,r,s,o,a,l,u=t.pieces?Math.round(Math.sqrt(t.pieces)):3,c=u,h=E(this),d="show"===t.mode,p=h.show().css("visibility","hidden").offset(),f=Math.ceil(h.outerWidth()/c),g=Math.ceil(h.outerHeight()/u),m=[];for(n=0;n<u;n++)for(o=p.top+n*g,l=n-(u-1)/2,r=0;r<c;r++)s=p.left+r*f,a=r-(c-1)/2,h.clone().appendTo("body").wrap("<div></div>").css({position:"absolute",visibility:"visible",left:-r*f,top:-n*g}).parent().addClass("ui-effects-explode").css({position:"absolute",overflow:"hidden",width:f,height:g,left:s+(d?a*f:0),top:o+(d?l*g:0),opacity:d?0:1}).animate({left:s+(d?0:a*f),top:o+(d?0:l*g),opacity:d?1:0},t.duration||500,t.easing,i)}),E.effects.define("fade","toggle",function(t,e){var i="show"===t.mode;E(this).css("opacity",i?0:1).animate({opacity:i?1:0},{queue:!1,duration:t.duration,easing:t.easing,complete:e})}),E.effects.define("fold","hide",function(e,t){var i=E(this),n=e.mode,r="show"===n,s="hide"===n,o=e.size||15,a=/([0-9]+)%/.exec(o),l=!!e.horizFirst?["right","bottom"]:["bottom","right"],u=e.duration/2,c=E.effects.createPlaceholder(i),h=i.cssClip(),d={clip:E.extend({},h)},p={clip:E.extend({},h)},f=[h[l[0]],h[l[1]]],g=i.queue().length;a&&(o=parseInt(a[1],10)/100*f[s?0:1]),d.clip[l[0]]=o,p.clip[l[0]]=o,p.clip[l[1]]=0,r&&(i.cssClip(p.clip),c&&c.css(E.effects.clipToBox(p)),p.clip=h),i.queue(function(t){c&&c.animate(E.effects.clipToBox(d),u,e.easing).animate(E.effects.clipToBox(p),u,e.easing),t()}).animate(d,u,e.easing).animate(p,u,e.easing).queue(t),E.effects.unshift(i,g,4)}),E.effects.define("highlight","show",function(t,e){var i=E(this),n={backgroundColor:i.css("backgroundColor")};"hide"===t.mode&&(n.opacity=0),E.effects.saveStyle(i),i.css({backgroundImage:"none",backgroundColor:t.color||"#ffff99"}).animate(n,{queue:!1,duration:t.duration,easing:t.easing,complete:e})}),E.effects.define("size",function(r,e){var t,s,i,n=E(this),o=["fontSize"],a=["borderTopWidth","borderBottomWidth","paddingTop","paddingBottom"],l=["borderLeftWidth","borderRightWidth","paddingLeft","paddingRight"],u=r.mode,c="effect"!==u,h=r.scale||"both",d=r.origin||["middle","center"],p=n.css("position"),f=n.position(),g=E.effects.scaledDimensions(n),m=r.from||g,v=r.to||E.effects.scaledDimensions(n,0);E.effects.createPlaceholder(n),"show"===u&&(i=m,m=v,v=i),s={from:{y:m.height/g.height,x:m.width/g.width},to:{y:v.height/g.height,x:v.width/g.width}},("box"===h||"both"===h)&&(s.from.y!==s.to.y&&(m=E.effects.setTransition(n,a,s.from.y,m),v=E.effects.setTransition(n,a,s.to.y,v)),s.from.x!==s.to.x&&(m=E.effects.setTransition(n,l,s.from.x,m),v=E.effects.setTransition(n,l,s.to.x,v))),("content"===h||"both"===h)&&s.from.y!==s.to.y&&(m=E.effects.setTransition(n,o,s.from.y,m),v=E.effects.setTransition(n,o,s.to.y,v)),d&&(t=E.effects.getBaseline(d,g),m.top=(g.outerHeight-m.outerHeight)*t.y+f.top,m.left=(g.outerWidth-m.outerWidth)*t.x+f.left,v.top=(g.outerHeight-v.outerHeight)*t.y+f.top,v.left=(g.outerWidth-v.outerWidth)*t.x+f.left),n.css(m),("content"===h||"both"===h)&&(a=a.concat(["marginTop","marginBottom"]).concat(o),l=l.concat(["marginLeft","marginRight"]),n.find("*[width]").each(function(){var t=E(this),e=E.effects.scaledDimensions(t),i={height:e.height*s.from.y,width:e.width*s.from.x,outerHeight:e.outerHeight*s.from.y,outerWidth:e.outerWidth*s.from.x},n={height:e.height*s.to.y,width:e.width*s.to.x,outerHeight:e.height*s.to.y,outerWidth:e.width*s.to.x};s.from.y!==s.to.y&&(i=E.effects.setTransition(t,a,s.from.y,i),n=E.effects.setTransition(t,a,s.to.y,n)),s.from.x!==s.to.x&&(i=E.effects.setTransition(t,l,s.from.x,i),n=E.effects.setTransition(t,l,s.to.x,n)),c&&E.effects.saveStyle(t),t.css(i),t.animate(n,r.duration,r.easing,function(){c&&E.effects.restoreStyle(t)})})),n.animate(v,{queue:!1,duration:r.duration,easing:r.easing,complete:function(){var t=n.offset();0===v.opacity&&n.css("opacity",m.opacity),c||(n.css("position","static"===p?"relative":p).offset(t),E.effects.saveStyle(n)),e()}})}),E.effects.define("scale",function(t,e){var i=E(this),n=t.mode,r=parseInt(t.percent,10)||(0===parseInt(t.percent,10)?0:"effect"!==n?0:100),s=E.extend(!0,{from:E.effects.scaledDimensions(i),to:E.effects.scaledDimensions(i,r,t.direction||"both"),origin:t.origin||["middle","center"]},t);t.fade&&(s.from.opacity=1,s.to.opacity=0),E.effects.effect.size.call(this,s,e)}),E.effects.define("puff","hide",function(t,e){var i=E.extend(!0,{},t,{fade:!0,percent:parseInt(t.percent,10)||150});E.effects.effect.scale.call(this,i,e)}),E.effects.define("pulsate","show",function(t,e){var i=E(this),n=t.mode,r="show"===n,s=r||"hide"===n,o=2*(t.times||5)+(s?1:0),a=t.duration/o,l=0,u=1,c=i.queue().length;for((r||!i.is(":visible"))&&(i.css("opacity",0).show(),l=1);u<o;u++)i.animate({opacity:l},a,t.easing),l=1-l;i.animate({opacity:l},a,t.easing),i.queue(e),E.effects.unshift(i,c,o+1)}),E.effects.define("shake",function(t,e){var i=1,n=E(this),r=t.direction||"left",s=t.distance||20,o=t.times||3,a=2*o+1,l=Math.round(t.duration/a),u="up"===r||"down"===r?"top":"left",c="up"===r||"left"===r,h={},d={},p={},f=n.queue().length;for(E.effects.createPlaceholder(n),h[u]=(c?"-=":"+=")+s,d[u]=(c?"+=":"-=")+2*s,p[u]=(c?"-=":"+=")+2*s,n.animate(h,l,t.easing);i<o;i++)n.animate(d,l,t.easing).animate(p,l,t.easing);n.animate(d,l,t.easing).animate(h,l/2,t.easing).queue(e),E.effects.unshift(n,f,a+1)}),E.effects.define("slide","show",function(t,e){var i,n,r=E(this),s={up:["bottom","top"],down:["top","bottom"],left:["right","left"],right:["left","right"]},o=t.mode,a=t.direction||"left",l="up"===a||"down"===a?"top":"left",u="up"===a||"left"===a,c=t.distance||r["top"===l?"outerHeight":"outerWidth"](!0),h={};E.effects.createPlaceholder(r),i=r.cssClip(),n=r.position()[l],h[l]=(u?-1:1)*c+n,h.clip=r.cssClip(),h.clip[s[a][1]]=h.clip[s[a][0]],"show"===o&&(r.cssClip(h.clip),r.css(l,h[l]),h.clip=i,h[l]=n),r.animate(h,{queue:!1,duration:t.duration,easing:t.easing,complete:e})}),!1!==E.uiBackCompat&&E.effects.define("transfer",function(t,e){E(this).transfer(t,e)}),E.ui.focusable=function(t,e){var i,n,r,s,o,a=t.nodeName.toLowerCase();return"area"===a?(n=(i=t.parentNode).name,!(!t.href||!n||"map"!==i.nodeName.toLowerCase())&&(0<(r=E("img[usemap='#"+n+"']")).length&&r.is(":visible"))):(/^(input|select|textarea|button|object)$/.test(a)?(s=!t.disabled)&&((o=E(t).closest("fieldset")[0])&&(s=!o.disabled)):s="a"===a&&t.href||e,s&&E(t).is(":visible")&&function(t){for(var e=t.css("visibility");"inherit"===e;)e=(t=t.parent()).css("visibility");return"hidden"!==e}(E(t)))},E.extend(E.expr[":"],{focusable:function(t){return E.ui.focusable(t,null!=E.attr(t,"tabindex"))}}),E.ui.focusable,E.fn.form=function(){return"string"==typeof this[0].form?this.closest("form"):E(this[0].form)},E.ui.formResetMixin={_formResetHandler:function(){var e=E(this);setTimeout(function(){var t=e.data("ui-form-reset-instances");E.each(t,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 t=this.form.data("ui-form-reset-instances");t.splice(E.inArray(this,t),1),t.length?this.form.data("ui-form-reset-instances",t):this.form.removeData("ui-form-reset-instances").off("reset.ui-form-reset")}}},"1.7"===E.fn.jquery.substring(0,3)&&(E.each(["Width","Height"],function(t,i){function n(t,e,i,n){return E.each(r,function(){e-=parseFloat(E.css(t,"padding"+this))||0,i&&(e-=parseFloat(E.css(t,"border"+this+"Width"))||0),n&&(e-=parseFloat(E.css(t,"margin"+this))||0)}),e}var r="Width"===i?["Left","Right"]:["Top","Bottom"],s=i.toLowerCase(),o={innerWidth:E.fn.innerWidth,innerHeight:E.fn.innerHeight,outerWidth:E.fn.outerWidth,outerHeight:E.fn.outerHeight};E.fn["inner"+i]=function(t){return void 0===t?o["inner"+i].call(this):this.each(function(){E(this).css(s,n(this,t)+"px")})},E.fn["outer"+i]=function(t,e){return"number"!=typeof t?o["outer"+i].call(this,t):this.each(function(){E(this).css(s,n(this,t,!0,e)+"px")})}}),E.fn.addBack=function(t){return this.add(null==t?this.prevObject:this.prevObject.filter(t))}),E.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},E.ui.escapeSelector=(g=/([!"#$%&'()*+,.\/:;<=>?@[\]^`{|}~])/g,function(t){return t.replace(g,"\\$1")}),E.fn.labels=function(){var t,e,i,n,r;return this[0].labels&&this[0].labels.length?this.pushStack(this[0].labels):(n=this.eq(0).parents("label"),(i=this.attr("id"))&&(r=(t=this.eq(0).parents().last()).add(t.length?t.siblings():this.siblings()),e="label[for='"+E.ui.escapeSelector(i)+"']",n=n.add(r.find(e).addBack(e))),this.pushStack(n))},E.fn.scrollParent=function(t){var e=this.css("position"),i="absolute"===e,n=t?/(auto|scroll|hidden)/:/(auto|scroll)/,r=this.parents().filter(function(){var t=E(this);return(!i||"static"!==t.css("position"))&&n.test(t.css("overflow")+t.css("overflow-y")+t.css("overflow-x"))}).eq(0);return"fixed"!==e&&r.length?r:E(this[0].ownerDocument||document)},E.extend(E.expr[":"],{tabbable:function(t){var e=E.attr(t,"tabindex"),i=null!=e;return(!i||0<=e)&&E.ui.focusable(t,i)}}),E.fn.extend({uniqueId:(f=0,function(){return this.each(function(){this.id||(this.id="ui-id-"+ ++f)})}),removeUniqueId:function(){return this.each(function(){/^ui-id-\d+$/.test(this.id)&&E(this).removeAttr("id")})}}),E.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 t=this.options;this.prevShow=this.prevHide=E(),this._addClass("ui-accordion","ui-widget ui-helper-reset"),this.element.attr("role","tablist"),t.collapsible||!1!==t.active&&null!=t.active||(t.active=0),this._processPanels(),t.active<0&&(t.active+=this.headers.length),this._refresh()},_getCreateEventData:function(){return{header:this.active,panel:this.active.length?this.active.next():E()}},_createIcons:function(){var t,e,i=this.options.icons;i&&(t=E("<span>"),this._addClass(t,"ui-accordion-header-icon","ui-icon "+i.header),t.prependTo(this.headers),e=this.active.children(".ui-accordion-header-icon"),this._removeClass(e,i.header)._addClass(e,null,i.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?void this._activate(e):("event"===t&&(this.options.event&&this._off(this.headers,this.options.event),this._setupEvents(e)),this._super(t,e),"collapsible"!==t||e||!1!==this.options.active||this._activate(0),void("icons"===t&&(this._destroyIcons(),e&&this._createIcons())))},_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(t){if(!t.altKey&&!t.ctrlKey){var e=E.ui.keyCode,i=this.headers.length,n=this.headers.index(t.target),r=!1;switch(t.keyCode){case e.RIGHT:case e.DOWN:r=this.headers[(n+1)%i];break;case e.LEFT:case e.UP:r=this.headers[(n-1+i)%i];break;case e.SPACE:case e.ENTER:this._eventHandler(t);break;case e.HOME:r=this.headers[0];break;case e.END:r=this.headers[i-1]}r&&(E(t.target).attr("tabIndex",-1),E(r).attr("tabIndex",0),E(r).trigger("focus"),t.preventDefault())}},_panelKeyDown:function(t){t.keyCode===E.ui.keyCode.UP&&t.ctrlKey&&E(t.currentTarget).prev().trigger("focus")},refresh:function(){var t=this.options;this._processPanels(),!1===t.active&&!0===t.collapsible||!this.headers.length?(t.active=!1,this.active=E()):!1===t.active?this._activate(0):this.active.length&&!E.contains(this.element[0],this.active[0])?this.headers.length===this.headers.find(".ui-state-disabled").length?(t.active=!1,this.active=E()):this._activate(Math.max(0,t.active-1)):t.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 i,t=this.options,e=t.heightStyle,n=this.element.parent();this.active=this._findActive(t.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 t=E(this),e=t.uniqueId().attr("id"),i=t.next(),n=i.uniqueId().attr("id");t.attr("aria-controls",n),i.attr("aria-labelledby",e)}).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(t.event),"fill"===e?(i=n.height(),this.element.siblings(":visible").each(function(){var t=E(this),e=t.css("position");"absolute"!==e&&"fixed"!==e&&(i-=t.outerHeight(!0))}),this.headers.each(function(){i-=E(this).outerHeight(!0)}),this.headers.next().each(function(){E(this).height(Math.max(0,i-E(this).innerHeight()+E(this).height()))}).css("overflow","auto")):"auto"===e&&(i=0,this.headers.next().each(function(){var t=E(this).is(":visible");t||E(this).show(),i=Math.max(i,E(this).css("height","").height()),t||E(this).hide()}).height(i))},_activate:function(t){var e=this._findActive(t)[0];e!==this.active[0]&&(e=e||this.active[0],this._eventHandler({target:e,currentTarget:e,preventDefault:E.noop}))},_findActive:function(t){return"number"==typeof t?this.headers.eq(t):E()},_setupEvents:function(t){var i={keydown:"_keydown"};t&&E.each(t.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(t){var e,i,n=this.options,r=this.active,s=E(t.currentTarget),o=s[0]===r[0],a=o&&n.collapsible,l=a?E():s.next(),u=r.next(),c={oldHeader:r,oldPanel:u,newHeader:a?E():s,newPanel:l};t.preventDefault(),o&&!n.collapsible||!1===this._trigger("beforeActivate",t,c)||(n.active=!a&&this.headers.index(s),this.active=o?E():s,this._toggle(c),this._removeClass(r,"ui-accordion-header-active","ui-state-active"),n.icons&&(e=r.children(".ui-accordion-header-icon"),this._removeClass(e,null,n.icons.activeHeader)._addClass(e,null,n.icons.header)),o||(this._removeClass(s,"ui-accordion-header-collapsed")._addClass(s,"ui-accordion-header-active","ui-state-active"),n.icons&&(i=s.children(".ui-accordion-header-icon"),this._removeClass(i,null,n.icons.header)._addClass(i,null,n.icons.activeHeader)),this._addClass(s.next(),"ui-accordion-content-active")))},_toggle:function(t){var e=t.newPanel,i=this.prevShow.length?this.prevShow:t.oldPanel;this.prevShow.add(this.prevHide).stop(!0,!0),this.prevShow=e,this.prevHide=i,this.options.animate?this._animate(e,i,t):(i.hide(),e.show(),this._toggleComplete(t)),i.attr({"aria-hidden":"true"}),i.prev().attr({"aria-selected":"false","aria-expanded":"false"}),e.length&&i.length?i.prev().attr({tabIndex:-1,"aria-expanded":"false"}):e.length&&this.headers.filter(function(){return 0===parseInt(E(this).attr("tabIndex"),10)}).attr("tabIndex",-1),e.attr("aria-hidden","false").prev().attr({"aria-selected":"true","aria-expanded":"true",tabIndex:0})},_animate:function(t,i,e){var n,r,s,o=this,a=0,l=t.css("box-sizing"),u=t.length&&(!i.length||t.index()<i.index()),c=this.options.animate||{},h=u&&c.down||c,d=function(){o._toggleComplete(e)};return"number"==typeof h&&(s=h),"string"==typeof h&&(r=h),r=r||h.easing||c.easing,s=s||h.duration||c.duration,i.length?t.length?(n=t.show().outerHeight(),i.animate(this.hideProps,{duration:s,easing:r,step:function(t,e){e.now=Math.round(t)}}),void t.hide().animate(this.showProps,{duration:s,easing:r,complete:d,step:function(t,e){e.now=Math.round(t),"height"!==e.prop?"content-box"===l&&(a+=e.now):"content"!==o.options.heightStyle&&(e.now=Math.round(n-i.outerHeight()-a),a=0)}})):i.animate(this.hideProps,s,r,d):t.animate(this.showProps,s,r,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)}}),E.ui.safeActiveElement=function(e){var i;try{i=e.activeElement}catch(t){i=e.body}return i||(i=e.body),i.nodeName||(i=e.body),i},E.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(t){var e=E(t.target),i=E(E.ui.safeActiveElement(this.document[0]));!this.mouseHandled&&e.not(".ui-state-disabled").length&&(this.select(t),t.isPropagationStopped()||(this.mouseHandled=!0),e.has(".ui-menu").length?this.expand(t):!this.element.is(":focus")&&i.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(t){if(!this.previousFilter){var e=E(t.target).closest(".ui-menu-item"),i=E(t.currentTarget);e[0]===i[0]&&(this._removeClass(i.siblings().children(".ui-state-active"),null,"ui-state-active"),this.focus(t,i))}},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(t){this._delay(function(){!E.contains(this.element[0],E.ui.safeActiveElement(this.document[0]))&&this.collapseAll(t)})},keydown:"_keydown"}),this.refresh(),this._on(this.document,{click:function(t){this._closeOnDocumentClick(t)&&this.collapseAll(t),this.mouseHandled=!1}})},_destroy:function(){var t=this.element.find(".ui-menu-item").removeAttr("role aria-disabled").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(),t.children().each(function(){var t=E(this);t.data("ui-menu-submenu-caret")&&t.remove()})},_keydown:function(t){var e,i,n,r,s=!0;switch(t.keyCode){case E.ui.keyCode.PAGE_UP:this.previousPage(t);break;case E.ui.keyCode.PAGE_DOWN:this.nextPage(t);break;case E.ui.keyCode.HOME:this._move("first","first",t);break;case E.ui.keyCode.END:this._move("last","last",t);break;case E.ui.keyCode.UP:this.previous(t);break;case E.ui.keyCode.DOWN:this.next(t);break;case E.ui.keyCode.LEFT:this.collapse(t);break;case E.ui.keyCode.RIGHT:this.active&&!this.active.is(".ui-state-disabled")&&this.expand(t);break;case E.ui.keyCode.ENTER:case E.ui.keyCode.SPACE:this._activate(t);break;case E.ui.keyCode.ESCAPE:this.collapse(t);break;default:s=!1,i=this.previousFilter||"",r=!1,n=96<=t.keyCode&&t.keyCode<=105?""+(t.keyCode-96):String.fromCharCode(t.keyCode),clearTimeout(this.filterTimer),n===i?r=!0:n=i+n,e=this._filterMenuItems(n),(e=r&&-1!==e.index(this.active.next())?this.active.nextAll(".ui-menu-item"):e).length||(n=String.fromCharCode(t.keyCode),e=this._filterMenuItems(n)),e.length?(this.focus(t,e),this.previousFilter=n,this.filterTimer=this._delay(function(){delete this.previousFilter},1e3)):delete this.previousFilter}s&&t.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 t,e,i,n,r=this,s=this.options.icons.submenu,o=this.element.find(this.options.menus);this._toggleClass("ui-menu-icons",null,!!this.element.find(".ui-icon").length),e=o.filter(":not(.ui-menu)").hide().attr({role:this.options.role,"aria-hidden":"true","aria-expanded":"false"}).each(function(){var t=E(this),e=t.prev(),i=E("<span>").data("ui-menu-submenu-caret",!0);r._addClass(i,"ui-menu-icon","ui-icon "+s),e.attr("aria-haspopup","true").prepend(i),t.attr("aria-labelledby",e.attr("id"))}),this._addClass(e,"ui-menu","ui-widget ui-widget-content ui-front"),(t=o.add(this.element).find(this.options.items)).not(".ui-menu-item").each(function(){var t=E(this);r._isDivider(t)&&r._addClass(t,"ui-menu-divider","ui-widget-content")}),n=(i=t.not(".ui-menu-item, .ui-menu-divider")).children().not(".ui-menu").uniqueId().attr({tabIndex:-1,role:this._itemRole()}),this._addClass(i,"ui-menu-item")._addClass(n,"ui-menu-item-wrapper"),t.filter(".ui-state-disabled").attr("aria-disabled","true"),this.active&&!E.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,n,r;this.blur(t,t&&"focus"===t.type),this._scrollIntoView(e),this.active=e.first(),n=this.active.children(".ui-menu-item-wrapper"),this._addClass(n,null,"ui-state-active"),this.options.role&&this.element.attr("aria-activedescendant",n.attr("id")),r=this.active.parent().closest(".ui-menu-item").children(".ui-menu-item-wrapper"),this._addClass(r,null,"ui-state-active"),t&&"keydown"===t.type?this._close():this.timer=this._delay(function(){this._close()},this.delay),(i=e.children(".ui-menu")).length&&t&&/^mouse/.test(t.type)&&this._startOpening(i),this.activeMenu=e.parent(),this._trigger("focus",t,{item:e})},_scrollIntoView:function(t){var e,i,n,r,s,o;this._hasScroll()&&(e=parseFloat(E.css(this.activeMenu[0],"borderTopWidth"))||0,i=parseFloat(E.css(this.activeMenu[0],"paddingTop"))||0,n=t.offset().top-this.activeMenu.offset().top-e-i,r=this.activeMenu.scrollTop(),s=this.activeMenu.height(),o=t.outerHeight(),n<0?this.activeMenu.scrollTop(r+n):s<n+o&&this.activeMenu.scrollTop(r+n-s+o))},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(t){var e=E.extend({of:this.active},this.options.position);clearTimeout(this.timer),this.element.find(".ui-menu").not(t.parents(".ui-menu")).hide().attr("aria-hidden","true"),t.show().removeAttr("aria-hidden").attr("aria-expanded","true").position(e)},collapseAll:function(e,i){clearTimeout(this.timer),this.timer=this._delay(function(){var t=i?this.element:E(e&&e.target).closest(this.element.find(".ui-menu"));t.length||(t=this.element),this._close(t),this.blur(e),this._removeClass(t.find(".ui-state-active"),null,"ui-state-active"),this.activeMenu=t},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","fal
1se")},_closeOnDocumentClick:function(t){return!E(t.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 n;this.active&&(n="first"===t||"last"===t?this.active["first"===t?"prevAll":"nextAll"](".ui-menu-item").eq(-1):this.active[t+"All"](".ui-menu-item").eq(0)),n&&n.length&&this.active||(n=this.activeMenu.find(this.options.items)[e]()),this.focus(i,n)},nextPage:function(t){var e,i,n;return this.active?void(this.isLastItem()||(this._hasScroll()?(i=this.active.offset().top,n=this.element.height(),this.active.nextAll(".ui-menu-item").each(function(){return(e=E(this)).offset().top-i-n<0}),this.focus(t,e)):this.focus(t,this.activeMenu.find(this.options.items)[this.active?"last":"first"]()))):void this.next(t)},previousPage:function(t){var e,i,n;return this.active?void(this.isFirstItem()||(this._hasScroll()?(i=this.active.offset().top,n=this.element.height(),this.active.prevAll(".ui-menu-item").each(function(){return 0<(e=E(this)).offset().top-i+n}),this.focus(t,e)):this.focus(t,this.activeMenu.find(this.options.items).first()))):void this.next(t)},_hasScroll:function(){return this.element.outerHeight()<this.element.prop("scrollHeight")},select:function(t){this.active=this.active||E(t.target).closest(".ui-menu-item");var e={item:this.active};this.active.has(".ui-menu").length||this.collapseAll(t,!0),this._trigger("select",t,e)},_filterMenuItems:function(t){var e=t.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&"),i=RegExp("^"+e,"i");return this.activeMenu.find(this.options.items).filter(".ui-menu-item").filter(function(){return i.test(E.trim(E(this).children(".ui-menu-item-wrapper").text()))})}}),E.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 i,n,r,t=this.element[0].nodeName.toLowerCase(),e="textarea"===t,s="input"===t;this.isMultiLine=e||!s&&this._isContentEditable(this.element),this.valueMethod=this.element[e||s?"val":"text"],this.isNewMenu=!0,this._addClass("ui-autocomplete-input"),this.element.attr("autocomplete","off"),this._on(this.element,{keydown:function(t){if(this.element.prop("readOnly"))n=r=i=!0;else{n=r=i=!1;var e=E.ui.keyCode;switch(t.keyCode){case e.PAGE_UP:i=!0,this._move("previousPage",t);break;case e.PAGE_DOWN:i=!0,this._move("nextPage",t);break;case e.UP:i=!0,this._keyEvent("previous",t);break;case e.DOWN:i=!0,this._keyEvent("next",t);break;case e.ENTER:this.menu.active&&(i=!0,t.preventDefault(),this.menu.select(t));break;case e.TAB:this.menu.active&&this.menu.select(t);break;case e.ESCAPE:this.menu.element.is(":visible")&&(this.isMultiLine||this._value(this.term),this.close(t),t.preventDefault());break;default:n=!0,this._searchTimeout(t)}}},keypress:function(t){if(i)return i=!1,void((!this.isMultiLine||this.menu.element.is(":visible"))&&t.preventDefault());if(!n){var e=E.ui.keyCode;switch(t.keyCode){case e.PAGE_UP:this._move("previousPage",t);break;case e.PAGE_DOWN:this._move("nextPage",t);break;case e.UP:this._keyEvent("previous",t);break;case e.DOWN:this._keyEvent("next",t)}}},input:function(t){return r?(r=!1,void t.preventDefault()):void this._searchTimeout(t)},focus:function(){this.selectedItem=null,this.previous=this._value()},blur:function(t){return this.cancelBlur?void delete this.cancelBlur:(clearTimeout(this.searching),this.close(t),void this._change(t))}}),this._initSource(),this.menu=E("<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(t){t.preventDefault(),this.cancelBlur=!0,this._delay(function(){delete this.cancelBlur,this.element[0]!==E.ui.safeActiveElement(this.document[0])&&this.element.trigger("focus")})},menufocus:function(t,e){var i,n;return this.isNewMenu&&(this.isNewMenu=!1,t.originalEvent&&/^mouse/.test(t.originalEvent.type))?(this.menu.blur(),void this.document.one("mousemove",function(){E(t.target).trigger(t.originalEvent)})):(n=e.item.data("ui-autocomplete-item"),!1!==this._trigger("focus",t,{item:n}
vendor: 11,429 bytes, line 1
1)&&t.originalEvent&&/^key/.test(t.originalEvent.type)&&this._value(n.value),void((i=e.item.attr("aria-label")||n.value)&&E.trim(i).length&&(this.liveRegion.children().hide(),E("<div>").text(i).appendTo(this.liveRegion))))},menuselect:function(t,e){var i=e.item.data("ui-autocomplete-item"),n=this.previous;this.element[0]!==E.ui.safeActiveElement(this.document[0])&&(this.element.trigger("focus"),this.previous=n,this._delay(function(){this.previous=n,this.selectedItem=i})),!1!==this._trigger("select",t,{item:i})&&this._value(i.value),this.term=this._value(),this.close(t),this.selectedItem=i}}),this.liveRegion=E("<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(t){var e=this.menu.element[0];return t.target===this.element[0]||t.target===e||E.contains(e,t.target)},_closeOnClickOutside:function(t){this._isEventTargetInWidget(t)||this.close()},_appendTo:function(){var t=this.options.appendTo;return t&&(t=t.jquery||t.nodeType?E(t):this.document.find(t).eq(0)),t&&t[0]||(t=this.element.closest(".ui-front, dialog")),t.length||(t=this.document[0].body),t},_initSource:function(){var i,n,r=this;E.isArray(this.options.source)?(i=this.options.source,this.source=function(t,e){e(E.ui.autocomplete.filter(i,t.term))}):"string"==typeof this.options.source?(n=this.options.source,this.source=function(t,e){r.xhr&&r.xhr.abort(),r.xhr=E.ajax({url:n,data:t,dataType:"json",success:function(t){e(t)},error:function(){e([])}})}):this.source=this.options.source},_searchTimeout:function(n){clearTimeout(this.searching),this.searching=this._delay(function(){var t=this.term===this._value(),e=this.menu.element.is(":visible"),i=n.altKey||n.ctrlKey||n.metaKey||n.shiftKey;(!t||t&&!e&&!i)&&(this.selectedItem=null,this.search(null,n))},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):!1!==this._trigger("search",e)?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 E.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))},_change:function(t){this.previous!==this._value()&&this._trigger("change",t,{item:this.selectedItem})},_normalize:function(t){return t.length&&t[0].label&&t[0].value?t:E.map(t,function(t){return"string"==typeof t?{label:t,value:t}:E.extend({},t,{label:t.label||t.value,value:t.value||t.label})})},_suggest:function(t){var e=this.menu.element.empty();this._renderMenu(e,t),this.isNewMenu=!0,this.menu.refresh(),e.show(),this._resizeMenu(),e.position(E.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(i,t){var n=this;E.each(t,function(t,e){n._renderItemData(i,e)})},_renderItemData:function(t,e){return this._renderItem(t,e).data("ui-autocomplete-item",e)},_renderItem:function(t,e){return E("<li>").append(E("<div>").text(e.label)).appendTo(t)},_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),void this.menu.blur()):void this.menu[t](e):void this.search(null,e)},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}}),E.extend(E.ui.autocomplete,{escapeRegex:function(t){return t.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&")},filter:function(t,e){var i=RegExp(E.ui.autocomplete.escapeRegex(e),"i");return E.grep(t,function(t){return i.test(t.label||t.value||t)})}}),E.widget("ui.autocomplete",E.ui.autocomplete,{options:{messages:{noResults:"No search results.",results:function(t){return t+(1<t?" results are":" result is")+" available, use up and down arrow keys to navigate."}}},__response:function(t){var e;this._superApply(arguments),this.options.disabled||this.cancelSearch||(e=t&&t.length?this.options.messages.results(t.length):this.options.messages.noResults,this.liveRegion.children().hide(),E("<div>").text(e).appendTo(this.liveRegion))}}),E.ui.autocomplete;var m,v,y=/ui-corner-([a-z]){2,6}/g;E.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 o=this,a=[];E.each(this.options.items,function(r,t){var e,s={};return t?"controlgroupLabel"===r?((e=o.element.find(t)).each(function(){var t=E(this);t.children(".ui-controlgroup-label-contents").length||t.contents().wrapAll("<span class='ui-controlgroup-label-contents'></span>")}),o._addClass(e,null,"ui-widget ui-widget-content ui-state-default"),void(a=a.concat(e.get()))):void(E.fn[r]&&(s=o["_"+r+"Options"]?o["_"+r+"Options"]("middle"):{classes:{}},o.element.find(t).each(function(){var t=E(this),e=t[r]("instance"),i=E.widget.extend({},s);if("button"!==r||!t.parent(".ui-spinner").length){e||(e=t[r]()[r]("instance")),e&&(i.classes=o._resolveClassesValues(i.classes,e)),t[r](i);var n=t[r]("widget");E.data(n[0],"ui-controlgroup-data",e||t[r]("instance")),a.push(n[0])}}))):void 0}),this.childWidgets=E(E.unique(a)),this._addClass(this.childWidgets,"ui-controlgroup-item")},_callChildMethod:function(e){this.childWidgets.each(function(){var t=E(this).data("ui-controlgroup-data");t&&t[e]&&t[e]()})},_updateCornerClass:function(t,e){var i=this._buildSimpleOptions(e,"label").classes.label;this._removeClass(t,null,"ui-corner-top ui-corner-bottom ui-corner-left ui-corner-right ui-corner-all"),this._addClass(t,null,i)},_buildSimpleOptions:function(t,e){var i="vertical"===this.options.direction,n={classes:{}};return n.classes[e]={middle:"",first:"ui-corner-"+(i?"top":"left"),last:"ui-corner-"+(i?"bottom":"right"),only:"ui-corner-all"}[t],n},_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",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(i,n){var r={};return E.each(i,function(t){var e=n.options.classes[t]||"";e=E.trim(e.replace(y,"")),r[t]=(e+" "+i[t]).replace(/\s+/g," ")}),r},_setOption:function(t,e){return"direction"===t&&this._removeClass("ui-controlgroup-"+this.options.direction),this._super(t,e),"disabled"===t?void this._callChildMethod(e?"disable":"enable"):void this.refresh()},refresh:function(){var r,s=this;this._addClass("ui-controlgroup ui-controlgroup-"+this.options.direction),"horizontal"===this.options.direction&&this._addClass(null,"ui-helper-clearfix"),this._initWidgets(),r=this.childWidgets,this.options.onlyVisible&&(r=r.filter(":visible")),r.length&&(E.each(["first","last"],function(t,e){var i=r[e]().data("ui-controlgroup-data");if(i&&s["_"+i.widgetName+"Options"]){var n=s["_"+i.widgetName+"Options"](1===r.length?"only":e);n.classes=s._resolveClassesValues(n.classes,i),i.element[i.widgetName](n)}else s._updateCornerClass(r[e](),e)}),this._callChildMethod("refresh"))}}),E.widget("ui.checkboxradio",[E.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 t,e,i=this,n=this._super()||{};return this._readType(),e=this.element.labels(),this.label=E(e[e.length-1]),this.label.length||E.error("No label found for checkboxradio widget"),this.originalLabel="",this.label.contents().not(this.element[0]).each(function(){i.originalLabel+=3===this.nodeType?E(this).text():this.outerHTML}),this.originalLabel&&(n.label=this.originalLabel),null!=(t=this.element[0].disabled)&&(n.disabled=t),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 t=this.element[0].nodeName.toLowerCase();
1this.type=this.element[0].type,"input"===t&&/radio|checkbox/.test(this.type)||E.error("Can't create checkboxradio on element.nodeName="+t+" and element.type="+this.type)},_enhance:function(){this._updateIcon(this.element[0].checked)},widget:function(){return this.label},_getRadioGroup:function(){var t=this.element[0].name,e="input[name='"+E.ui.escapeSelector(t)+"']";return t?(this.form.length?E(this.form[0].elements).filter(e):E(e).filter(function(){return 0===E(this).form().length})).not(this.element):E([])},_toggleClasses:function(){var t=this.element[0].checked;this._toggleClass(this.label,"ui-checkboxradio-checked","ui-state-active",t),this.options.icon&&"checkbox"===this.type&&this._toggleClass(this.icon,null,"ui-icon-check ui-state-checked",t)._toggleClass(this.icon,null,"ui-icon-blank",!t),"radio"===this.type&&this._getRadioGroup().each(function(){var t=E(this).checkboxradio("instance");t&&t._removeClass(t.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),void(this.element[0].disabled=e)):void this.refresh()):void 0},_updateIcon:function(t){var e="ui-icon ui-icon-background ";this.options.icon?(this.icon||(this.icon=E("<span>"),this.iconSpace=E("<span> </span>
1"),this._addClass(this.iconSpace,"ui-checkboxradio-icon-space")),"checkbox"===this.type?(e+=t?"ui-icon-check ui-state-checked":"ui-icon-blank",this._removeClass(this.icon,null,t?"ui-icon-blank":"ui-icon-check")):e+="ui-icon-blank",this._addClass(this.icon,"ui-checkboxradio-icon",e),t||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})}}]),E.ui.checkboxradio,E.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"),null!=(t=this.element[0].disabled)&&(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(t){t.keyCode===E.ui.keyCode.SPACE&&(t.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(t,e){var i="iconPosition"!==t,n=i?this.options.iconPosition:e,r="top"===n||"bottom"===n;this.icon?i&&this._removeClass(this.icon,null,this.options.icon):(this.icon=E("<span>"),this._addClass(this.icon,"ui-button-icon","ui-icon"),this.options.showLabel||this._addClass("ui-button-icon-only")),i&&this._addClass(this.icon,null,e),this._attachIcon(n),r?(this._addClass(this.icon,null,"ui-widget-icon-block"),this.iconSpace&&this.iconSpace.remove()):(this.iconS
vendor: 6,247 bytes, line 1
1pace||(this.iconSpace=E("<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)&&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()}}),!1!==E.uiBackCompat&&(E.widget("ui.button",E.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?void this._super("showLabel",e):("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"))),void this._superApply(arguments))}}),E.fn.button=(m=E.fn.button,function(){return!this.length||this.length&&"INPUT"!==this[0].tagName||this.length&&"INPUT"===this[0].tagName&&"checkbox"!==this.attr("type")&&"radio"!==this.attr("type")?m.apply(this,arguments):(E.ui.checkboxradio||E.error("Checkboxradio widget missing"),0===arguments.length?this.checkboxradio({icon:!1}):this.checkboxradio.apply(this,arguments))}),E.fn.buttonset=function(){return E.ui.controlgroup||E.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))}),E.ui.button,E.extend(E.ui,{datepicker:{version:"1.12.1"}}),E.extend(t.prototype,{markerClassName:"hasDatepicker",maxRows:4,_widgetDatepicker:function(){return this.dpDiv},setDefaults:function(t){return h(this._defaults,t||{}),this},_attachDatepicker:function(t,e){var i,n,r;n="div"===(i=t.nodeName.toLowerCase())||"span"===i,t.id||(this.uuid+=1,t.id="dp"+this.uuid),(r=this._newInst(E(t),n)).settings=E.extend({},e||{}),"input"===i?this._connectDatepicker(t,r):n&&this._inlineDatepicker(t,r)},_newInst:function(t,e){return{id:t[0].id.replace(/([^A-Za-z0-9_\-])/g,"\\\\$1"),input:t,selectedDay:0,selectedMonth:0,selectedYear:0,drawMonth:0,drawYear:0,inline:e,dpDiv:e?i(E("<div class='"+this._inlineClass+" ui-datepicker ui-widget ui-widget-content ui-helper-clearfix ui-corner-all'></div>")):this.dpDiv}},_connectDatepicker:function(t,e){var i=E(t);e.append=E([]),e.trigger=E([]),i.hasClass(this.markerClassName)||(this._attachments(i,e),i.addClass(this.markerClassName).on("keydown",this._doKeyDown).on("keypress",this._doKeyPress).on("keyup",this._doKeyUp),this._autoSize(e),E.data(t,"datepicker",e),e.settings.disabled&&this._disableDatepicker(t))},_attachments:function(t,e){var i,n,r,s=this._get(e,"appendText"),o=this._get(e,"isRTL");e.append&&e.append.remove(),s&&(e.append=E("<span class='"+this._appendClass+"'>"+s+"</span>"),t[o?"before":"after"](e.append)),t.off("focus",this._showDatepicker),e.trigger&&e.trigger.remove(),("focus"===(i=this._get(e,"showOn"))||"both"===i)&&t.on("focus",this._showDatepicker),("button"===i||"both"===i)&&(n=this._get(e,"buttonText"),r=this._get(e,"buttonImage"),e.trigger=E(this._get(e,"buttonImageOnly")?E("<img/>").addClass(this._triggerClass).attr({src:r,alt:n,title:n}):E("<button type='button'></button>").addClass(this._triggerClass).html(r?E("<img/>").attr({src:r,alt:n,title:n}):n)),t[o?"before":"after"](e.trigger),e.trigger.on("click",function(){return E.datepicker._datepickerShowing&&E.datepicker._lastInput===t[0]?E.datepicker._hideDatepicker():(E.datepicker._datepickerShowing&&E.datepicker._lastInput!==t[0]&&E.datepicker._hideDatepicker(),E.datepicker._showDatepicker(t[0])),!1}))},_autoSize:function(t){if(this._get(t,"autoSize")&&!t.inline){var e,i,n,r,s=new Date(2009,11,20),o=this._get(t,"dateFormat");o.match(/[DM]/)&&(e=function(t){for(r=n=i=0;t.length>r;r++)t[r].length>i&&(i=t[r].length,n=r);return n},s.setMonth(e(this._get(t,o.match(/MM/)?"monthNames":"monthNamesShort"))),s.setDate(e(this._get(t,o.match(/DD/)?"dayNames":"dayNamesShort"))+20-s.getDay())),t.input.attr("size",this._formatDate(t,s).length)}},_inlineDatepicker:function(t,e){var i=E(t);i.hasClass(this.markerClassName)||(i.addClass(this.markerClassName).append(e.dpDiv),E.data(t,"datepicker",e),this._setDate(e,this._getDefaultDate(e),!0),this._updateDatepicker(e),this._updateAlternate(e),e.settings.disabled&&this._disableDatepicker(t),e.dpDiv.css("display","block"))}
vendor: 4,698 bytes, line 1
1,_dialogDatepicker:function(t,e,i,n,r){var s,o,a,l,u,c=this._dialogInst;return c||(this.uuid+=1,s="dp"+this.uuid,this._dialogInput=E("<input type='text' id='"+s+"' style='position: absolute; top: -100px; width: 0px;'/>"),this._dialogInput.on("keydown",this._doKeyDown),E("body").append(this._dialogInput),(c=this._dialogInst=this._newInst(this._dialogInput,!1)).settings={},E.data(this._dialogInput[0],"datepicker",c)),h(c.settings,n||{}),e=e&&e.constructor===Date?this._formatDate(c,e):e,this._dialogInput.val(e),this._pos=r?r.length?r:[r.pageX,r.pageY]:null,this._pos||(o=document.documentElement.clientWidth,a=document.documentElement.clientHeight,l=document.documentElement.scrollLeft||document.body.scrollLeft,u=document.documentElement.scrollTop||document.body.scrollTop,this._pos=[o/2-100+l,a/2-150+u]),this._dialogInput.css("left",this._pos[0]+20+"px").css("top",this._pos[1]+"px"),c.settings.onSelect=i,this._inDialog=!0,this.dpDiv.addClass(this._dialogClass),this._showDatepicker(this._dialogInput[0]),E.blockUI&&E.blockUI(this.dpDiv),E.data(this._dialogInput[0],"datepicker",c),this},_destroyDatepicker:function(t){var e,i=E(t),n=E.data(t,"datepicker");i.hasClass(this.markerClassName)&&(e=t.nodeName.toLowerCase(),E.removeData(t,"datepicker"),"input"===e?(n.append.remove(),n.trigger.remove(),i.removeClass(this.markerClassName).off("focus",this._showDatepicker).off("keydown",this._doKeyDown).off("keypress",this._doKeyPress).off("keyup",this._doKeyUp)):("div"===e||"span"===e)&&i.removeClass(this.markerClassName).empty(),v===n&&(v=null))},_enableDatepicker:function(e){var t,i,n=E(e),r=E.data(e,"datepicker");n.hasClass(this.markerClassName)&&("input"===(t=e.nodeName.toLowerCase())?(e.disabled=!1,r.trigger.filter("button").each(function(){this.disabled=!1}).end().filter("img").css({opacity:"1.0",cursor:""})):("div"===t||"span"===t)&&((i=n.children("."+this._inlineClass)).children().removeClass("ui-state-disabled"),i.find("select.ui-datepicker-month, select.ui-datepicker-year").prop("disabled",!1)),this._disabledInputs=E.map(this._disabledInputs,function(t){return t===e?null:t}))},_disableDatepicker:function(e){var t,i,n=E(e),r=E.data(e,"datepicker");n.hasClass(this.markerClassName)&&("input"===(t=e.nodeName.toLowerCase())?(e.disabled=!0,r.trigger.filter("button").each(function(){this.disabled=!0}).end().filter("img").css({opacity:"0.5",cursor:"default"})):("div"===t||"span"===t)&&((i=n.children("."+this._inlineClass)).children().addClass("ui-state-disabled"),i.find("select.ui-datepicker-month, select.ui-datepicker-year").prop("disabled",!0)),this._disabledInputs=E.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(t){try{return E.data(t,"datepicker")}catch(t){throw"Missing instance data for this datepicker"}},_optionDatepicker:function(t,e,i){var n,r,s,o,a=this._getInst(t);return 2===arguments.length&&"string"==typeof e?"defaults"===e?E.extend({},E.datepicker._defaults):a?"all"===e?E.extend({},a.settings):this._get(a,e):null:(n=e||{},"string"==typeof e&&((n={})[e]=i),void(a&&(this._curInst===a&&this._hideDatepicker(),r=this._getDateDatepicker(t,!0),s=this._getMinMaxDate(a,"min"),o=this._getMinMaxDate(a,"max"),h(a.settings,n),null!==s&&void 0!==n.dateFormat&&void 0===n.minDate&&(a.settings.minDate=this._formatDate(a,s)),null!==o&&void 0!==n.dateFormat&&void 0===n.maxDate&&(a.settings.maxDate=this._formatDate(a,o)),"disabled"in n&&(n.disabled?this._disableDatepicker(t):this._enableDatepicker(t)),this._attachments(E(t),a),this._autoSize(a),this._setDate(a,r),this._updateAlternate(a),this._updateDatepicker(a))))},_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(t){var e,i,n,r=E.datepicker._getInst(t.target),s=!0,o=r.dpDiv.is(".ui-datepicker-rtl");if(r._keyEvent=!0,E.datepicker._datepickerShowing)switch(t.keyCode){case 9:E.datepicker._hideDatepicker(),s=!1;break;case 13:return(n=E("td."+E.datepicker._dayOverClass+":not(."+E.datepicker._currentClass+")",r.dpDiv))[0]&&E.datepicker._selectDay(t.target,r.selectedMonth,r.selectedYear,n[0]),(e=E.datepicker._get(r,"onSelect"))?(i=E.datepicker._formatDate(r),e.apply(r.input?r.input[0]:null,[
vendor: 4,493 bytes, line 1
1i,r])):E.datepicker._hideDatepicker(),!1;case 27:E.datepicker._hideDatepicker();break;case 33:E.datepicker._adjustDate(t.target,t.ctrlKey?-E.datepicker._get(r,"stepBigMonths"):-E.datepicker._get(r,"stepMonths"),"M");break;case 34:E.datepicker._adjustDate(t.target,t.ctrlKey?+E.datepicker._get(r,"stepBigMonths"):+E.datepicker._get(r,"stepMonths"),"M");break;case 35:(t.ctrlKey||t.metaKey)&&E.datepicker._clearDate(t.target),s=t.ctrlKey||t.metaKey;break;case 36:(t.ctrlKey||t.metaKey)&&E.datepicker._gotoToday(t.target),s=t.ctrlKey||t.metaKey;break;case 37:(t.ctrlKey||t.metaKey)&&E.datepicker._adjustDate(t.target,o?1:-1,"D"),s=t.ctrlKey||t.metaKey,t.originalEvent.altKey&&E.datepicker._adjustDate(t.target,t.ctrlKey?-E.datepicker._get(r,"stepBigMonths"):-E.datepicker._get(r,"stepMonths"),"M");break;case 38:(t.ctrlKey||t.metaKey)&&E.datepicker._adjustDate(t.target,-7,"D"),s=t.ctrlKey||t.metaKey;break;case 39:(t.ctrlKey||t.metaKey)&&E.datepicker._adjustDate(t.target,o?-1:1,"D"),s=t.ctrlKey||t.metaKey,t.originalEvent.altKey&&E.datepicker._adjustDate(t.target,t.ctrlKey?+E.datepicker._get(r,"stepBigMonths"):+E.datepicker._get(r,"stepMonths"),"M");break;case 40:(t.ctrlKey||t.metaKey)&&E.datepicker._adjustDate(t.target,7,"D"),s=t.ctrlKey||t.metaKey;break;default:s=!1}else 36===t.keyCode&&t.ctrlKey?E.datepicker._showDatepicker(this):s=!1;s&&(t.preventDefault(),t.stopPropagation())},_doKeyPress:function(t){var e,i,n=E.datepicker._getInst(t.target);return E.datepicker._get(n,"constrainInput")?(e=E.datepicker._possibleChars(E.datepicker._get(n,"dateFormat")),i=String.fromCharCode(null==t.charCode?t.keyCode:t.charCode),t.ctrlKey||t.metaKey||i<" "||!e||-1<e.indexOf(i)):void 0},_doKeyUp:function(t){var e=E.datepicker._getInst(t.target);if(e.input.val()!==e.lastVal)try{E.datepicker.parseDate(E.datepicker._get(e,"dateFormat"),e.input?e.input.val():null,E.datepicker._getFormatConfig(e))&&(E.datepicker._setDateFromField(e),E.datepicker._updateAlternate(e),E.datepicker._updateDatepicker(e))}catch(t){}return!0},_showDatepicker:function(t){var e,i,n,r,s,o,a;("input"!==(t=t.target||t).nodeName.toLowerCase()&&(t=E("input",t.parentNode)[0]),E.datepicker._isDisabledDatepicker(t)||E.datepicker._lastInput===t)||(e=E.datepicker._getInst(t),E.datepicker._curInst&&E.datepicker._curInst!==e&&(E.datepicker._curInst.dpDiv.stop(!0,!0),e&&E.datepicker._datepickerShowing&&E.datepicker._hideDatepicker(E.datepicker._curInst.input[0])),!1!==(n=(i=E.datepicker._get(e,"beforeShow"))?i.apply(t,[t,e]):{})&&(h(e.settings,n),e.lastVal=null,E.datepicker._lastInput=t,E.datepicker._setDateFromField(e),E.datepicker._inDialog&&(t.value=""),E.datepicker._pos||(E.datepicker._pos=E.datepicker._findPos(t),E.datepicker._pos[1]+=t.offsetHeight),r=!1,E(t).parents().each(function(){return!(r|="fixed"===E(this).css("position"))}),s={left:E.datepicker._pos[0],top:E.datepicker._pos[1]},E.datepicker._pos=null,e.dpDiv.empty(),e.dpDiv.css({position:"absolute",display:"block",top:"-1000px"}),E.datepicker._updateDatepicker(e),s=E.datepicker._checkOffset(e,s,r),e.dpDiv.css({position:E.datepicker._inDialog&&E.blockUI?"static":r?"fixed":"absolute",display:"none",left:s.left+"px",top:s.top+"px"}),e.inline||(o=E.datepicker._get(e,"showAnim"),a=E.datepicker._get(e,"duration"),e.dpDiv.css("z-index",function(t){for(var e,i;t.length&&t[0]!==document;){if(("absolute"===(e=t.css("position"))||"relative"===e||"fixed"===e)&&(i=parseInt(t.css("zIndex"),10),!isNaN(i)&&0!==i))return i;t=t.parent()}return 0}(E(t))+1),E.datepicker._datepickerShowing=!0,E.effects&&E.effects.effect[o]?e.dpDiv.show(o,E.datepicker._get(e,"showOptions"),a):e.dpDiv[o||"show"](o?a:null),E.datepicker._shouldFocusInput(e)&&e.input.trigger("focus"),E.datepicker._curInst=e)))},_updateDatepicker:function(t){this.maxRows=4,(v=t).dpDiv.empty().append(this._generateHTML(t)),this._attachHandlers(t);var e,i=this._getNumberOfMonths(t),n=i[1],r=t.dpDiv.find("."+this._dayOverClass+" a");0<r.length&&s.apply(r.get(0)),t.dpDiv.removeClass("ui-datepicker-multi-2 ui-datepicker-multi-3 ui-datepicker-multi-4").width(""),1<n&&t.dpDiv.addClass("ui-datepicker-multi-"+n).css("width",17*n+"em"),t.dpDiv[(1!==i[0]||1!==i[1]?"add":"remove")+"Class"]("ui-datepicker-multi"),t.dpDiv[(this._get(t,"isRTL")?"add":"remove")+"Class"]("ui-datepicker-rtl"),t===E.datepicker._curInst&&E.datepicker._datepickerShowing&&E.datepicker._shouldFocusInput(t)&&t.input.trigger("focus"),t.yearshtml&&(e=t.yearshtml,setTimeout(function(){e===t.yearshtml&&t.yearshtml&&t.dpDiv.f
1ind("select.ui-datepicker-year:first").replaceWith(t.yearshtml),e=t.yearshtml=null},0))},_shouldFocusInput:function(t){return t.input&&t.input.is(":visible")&&!t.input.is(":disabled")&&!t.input.is(":focus")},_checkOffset:function(t,e,i){var n=t.dpDiv.outerWidth(),r=t.dpDiv.outerHeight(),s=t.input?t.input.outerWidth():0,o=t.input?t.input.outerHeight():0,a=document.documentElement.clientWidth+(i?0:E(document).scrollLeft()),l=document.documentElement.clientHeight+(i?0:E(document).scrollTop());return e.left-=this._get(t,"isRTL")?n-s:0,e.left-=i&&e.left===t.input.offset().left?E(document).scrollLeft():0,e.top-=i&&e.top===t.input.offset().top+o?E(document).scrollTop():0,e.left-=Math.min(e.left,e.left+n>a&&n<a?Math.abs(e.left+n-a):0),e.top-=Math.min(e.top,e.top+r>l&&r<l?Math.abs(r+o):0),e},_findPos:function(t){for(var e,i=this._getInst(t),n=this._get(i,"isRTL");t&&("hidden"===t.type||1!==t.nodeType||E.expr.filters.hidden(t));)t=t[n?"previousSibling":"nextSibling"];return[(e=E(t).offset()).left,e.top]},_hideDatepicker:function(t){var e,i,n,r,s=this._curInst;!s||t&&s!==E.data(t,"datepicker")||this._datepickerShowing&&(e=this._get(s,"showAnim"),i=this._get(s,"duration"),n=function(){E.datepicker._tidyDialog(s)},E.effects&&(E.effects.effect[e]||E.effects[e])?s.dpDiv.hide(e,E.datepicker._get(s,"showOptions"),i,n):s.dpDiv["slideDown"===e?"slideUp":"fadeIn"===e?"fadeOut":"hide"](e?i:null,n),e||n(),this._datepickerShowing=!1,(r=this._get(s,"onClose"))&&r.apply(s.input?s.input[0]:null,[s.input?s.input.val():"",s]),this._lastInput=null,this._inDialog&&(this._dialogInput.css({position:"absolute",left:"0",top:"-100px"}),E.blockUI&&(E.unblockUI(),E("body").append(this.dpDiv))),this._inDialog=!1)},_tidyDialog:function(t){t.dpDiv.removeClass(this._dialogClass).off(".ui-datepicker-calendar")},_checkExternalClick:function(t){if(E.datepicker._curInst){var e=E(t.target),i=E.datepicker._getInst(e[0]);(e[0].id!==E.datepicker._mainDivId&&0===e.parents("#"+E.datepicker._mainDivId).length&&!e.hasClass(E.datepicker.markerClassName)&&!e.closest("."+E.datepicker._triggerClass).length&&E.datepicker._datepickerShowing&&(!E.datepicker._inDialog||!E.blockUI)||e.hasClass(E.datepicker.markerClassName)&&E.datepicker._curInst!==i)&&E.datepicker._hideDatepicker()}},_adjustDate:function(t,e,i){var n=E(t),r=this._getInst(n[0]);this._isDisabledDatepicker(n[0])||(this._adjustInstDate(r,e+("M"===i?this._get(r,"showCurrentAtPos"):0),i),this._updateDatepicker(r))},_gotoToday:function(t){var e,i=E(t),n=this._getInst(i[0]);this._get(n,"gotoCurrent")&&n.currentDay?(n.selectedDay=n.currentDay,n.drawMonth=n.selectedMonth=n.currentMonth,n.drawYear=n.selectedYear=n.currentYear):(e=new Date,n.selectedDay=e.getDate(),n.drawMonth=n.selectedMonth=e.getMonth(),n.drawYear=n.selectedYear=e.getFullYear()),this._notifyChange(n),this._adjustDate(i)},_selectMonthYear:function(t,e,i){var n=E(t),r=this._getInst(n[0]);r["selected"+("M"===i?"Month":"Year")]=r["draw"+("M"===i?"Month":"Year")]=parseInt(e.options[e.selectedIndex].value,10),this._notifyChange(r),this._adjustDate(n)},_selectDay:function(t,e,i,n){var r,s=E(t);E(n).hasClass(this._unselectableClass)||this._isDisabledDatepicker(s[0])||((r=this._getInst(s[0])).selectedDay=r.currentDay=E("a",n).html(),r.selectedMonth=r.currentMonth=e,r.selectedYear=r.currentYear=i,this._selectDate(t,this._formatDate(r,r.currentDay,r.currentMonth,r.currentYear)))},_clearDate:function(t){var e=E(t);this._selectDate(e,"")},_selectDate:function(t,e){var i,n=E(t),r=this._getInst(n[0]);e=null!=e?e:this._formatDate(r),r.input&&r.input.val(e),this._updateAlternate(r),(i=this._get(r,"onSelect"))?i.apply(r.input?r.input[0]:null,[e,r]):r.input&&r.input.trigger("change"),r.inline?this._updateDatepicker(r):(this._hideDatepicker(),this._lastInput=r.input[0],"object"!=typeof r.input[0]&&r.input.trigger("focus"),this._lastInput=null)},_updateAlternate:function(t){var e,i,n,r=this._get(t,"altField");r&&(e=this._get(t,"altFormat")||this._get(t,"dateFormat"),i=this._getDate(t),n=this.formatDate(e,i,this._getFormatConfig(t)),E(r).val(n))},noWeekends:function(t){var e=t.getDay();return[0<e&&e<6,""]},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(i,s,t){if(null==i||null==s)throw"Invalid arguments";if(""===(s="object"==typeof s?""+s:s+""))return null;var n,e,r,o,a=0,l=(t?t.shortYearCutoff:null)||this._defaults.shortYearCutoff,u="string"!=typeof l?l:(new Date).getFullYear()%100+parseInt(l,10),c=(t?t.dayNamesShort:null)||this._defaults.dayNamesShort,h=(t?t.dayNames:null)||this._defaults.dayNames,d=(t?t.monthNamesShort:null)||this._defaults.monthNamesShort,p=(t?t.monthNames:null)||this._defaults.monthNames,f=-1,g=-1,m=-1,v=-1,y=!1,b=function(t){var e=i.length>n+1&&i.charAt(n+1)===t;return e&&n++,e},w=function(t){var e=b(t),i="@"===t?14:"!"===t?20:"y"===t&&e?4:"o"===t?3:2,n=RegExp("^\\d{"+("y"===t?i:1)+","+i+"}"),r=s.substring(a).match(n);if(!r)throw"Missing number at position "+a;return a+=r[0].length,parseInt(r[0],10)}
1,_=function(t,e,i){var n=-1,r=E.map(b(t)?i:e,function(t,e){return[[e,t]]}).sort(function(t,e){return-(t[1].length-e[1].length)});if(E.each(r,function(t,e){var i=e[1];return s.substr(a,i.length).toLowerCase()===i.toLowerCase()?(n=e[0],a+=i.length,!1):void 0}),-1!==n)return n+1;throw"Unknown name at position "+a},x=function(){if(s.charAt(a)!==i.charAt(n))throw"Unexpected literal at position "+a;a++};for(n=0;i.length>n;n++)if(y)"'"!==i.charAt(n)||b("'")?x():y=!1;else switch(i.charAt(n)){case"d":m=w("d");break;case"D":_("D",c,h);break;case"o":v=w("o");break;case"m":g=w("m");break;case"M":g=_("M",d,p);break;case"y":f=w("y");break;case"@":f=(o=new Date(w("@"))).getFullYear(),g=o.getMonth()+1,m=o.getDate();break;case"!":f=(o=new Date((w("!")-this._ticksTo1970)/1e4)).getFullYear(),g=o.getMonth()+1,m=o.getDate();break;case"'":b("'")?x():y=!0;break;default:x()}if(s.length>a&&(r=s.substr(a),!/^\s+/.test(r)))throw"Extra/unparsed characters found in date: "+r;if(-1===f?f=(new Date).getFullYear():f<100&&(f+=(new Date).getFullYear()-(new Date).getFullYear()%100+(f<=u?0:-100)),-1<v)for(g=1,m=v;!(m<=(e=this._getDaysInMonth(f,g-1)));)g++,m-=e;if((o=this._daylightSavingAdjust(new Date(f,g-1,m))).getFullYear()!==f||o.getMonth()+1!==g||o.getDate()!==m)throw"Invalid date";return o},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:864e9*(718685+Math.floor(492.5)-Math.floor(19.7)+Math.floor(4.925)),formatDate:function(i,t,e){if(!t)return"";var n,r=(e?e.dayNamesShort:null)||this._defaults.dayNamesShort,s=(e?e.dayNames:null)||this._defaults.dayNames,o=(e?e.monthNamesShort:null)||this._defaults.monthNamesShort,a=(e?e.monthNames:null)||this._defaults.monthNames,l=function(t){var e=i.length>n+1&&i.charAt(n+1)===t;return e&&n++,e},u=function(t,e,i){var n=""+e;if(l(t))for(;i>n.length;)n="0"+n;return n},c=function(t,e,i,n){return l(t)?n[e]:i[e]},h="",d=!1;if(t)for(n=0;i.length>n;n++)if(d)"'"!==i.charAt(n)||l("'")?h+=i.charAt(n):d=!1;else switch(i.charAt(n)){case"d":h+=u("d",t.getDate(),2);break;case"D":h+=c("D",t.getDay(),r,s);break;case"o":h+=u("o",Math.round((new Date(t.getFullYear(),t.getMonth(),t.getDate()).getTime()-new Date(t.getFullYear(),0,0).getTime())/864e5),3);break;case"m":h+=u("m",t.getMonth()+1,2);break;case"M":h+=c("M",t.getMonth(),o,a);break;case"y":h+=l("y")?t.getFullYear():(t.getFullYear()%100<10?"0":"")+t.getFullYear()%100;break;case"@":h+=t.getTime();break;case"!":h+=1e4*t.getTime()+this._ticksTo1970;break;case"'":l("'")?h+="'":d=!0;break;default:h+=i.charAt(n)}return h},_possibleChars:function(i){var n,t="",e=!1,r=function(t){var e=i.length>n+1&&i.charAt(n+1)===t;return e&&n++,e};for(n=0;i.length>n;n++)if(e)"'"!==i.charAt(n)||r("'")?t+=i.charAt(n):e=!1;else switch(i.charAt(n)){case"d":case"m":case"y":case"@":t+="0123456789";break;case"D":case"M":return null;case"'":r("'")?t+="'":e=!0;break;default:t+=i.charAt(n)}return t},_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"),n=t.lastVal=t.input?t.input.val():null,r=this._getDefaultDate(t),s=r,o=this._getFormatConfig(t);try{s=this.parseDate(i,n,o)||r}catch(t){n=e?"":n}t.selectedDay=s.getDate(),t.drawMonth=t.selectedMonth=s.getMonth(),t.drawYear=t.selectedYear=s.getFullYear(),t.currentDay=n?s.getDate():0,t.currentMonth=n?s.getMonth():0,t.currentYear=n?s.getFullYear():0,this._adjustInstDate(t)}},_getDefaultDate:function(t){return this._restrictMinMax(t,this._determineDate(t,this._get(t,"defaultDate"),new Date))},_determineDate:function(a,t,e){var i,n,r=null==t||""===t?e:"string"==typeof t?function(t){try{return E.datepicker.parseDate(E.datepicker._get(a,"dateFormat"),t,E.datepicker._getFormatConfig(a))}catch(t){}for(var e=(t.toLowerCase().match(/^c/)?E.datepicker._getDate(a):null)||new Date,i=e.getFullYear(),n=e.getMonth(),r=e.getDate(),s=/([+\-]?[0-9]+)\s*(d|D|w|W|m|M|y|Y)?/g,o=s.exec(t);o;){switch(o[2]||"d"){case"d":case"D":r+=parseInt(o[1],10);break;case"w":case"W":r+=7*parseInt(o[1],10);break;case"m":case"M":n+=parseInt(o[1],10),r=Math.min(r,E.datepicker._getDaysInMonth(i,n));break;case"y":case"Y":i+=parseInt(o[1],10),r=Math.min(r,E.datepicker._getDaysInMonth(i,n))}o=s.exec(t)}return new Date(i,n,r)}(t):"number"==typeof t?isNaN(t)?e:(i=t,(n=new Date).setDate(n.getDate()+i),n):new Date(t.getTime());return(r=r&&"Invalid Date"==""+r?e:r)&&(r.setHours(0),r.setMinutes(0),r.setSeconds(0),r.setMilliseconds(0)),this._daylightSavingAdjust(r)},_daylightSavingAdjust:function(t){return t?(t.setHours(12<t.getHours()?t.getHours()+2:0),t):null}
vendor: 6,648 bytes, line 1
1,_setDate:function(t,e,i){var n=!e,r=t.selectedMonth,s=t.selectedYear,o=this._restrictMinMax(t,this._determineDate(t,e,new Date));t.selectedDay=t.currentDay=o.getDate(),t.drawMonth=t.selectedMonth=t.currentMonth=o.getMonth(),t.drawYear=t.selectedYear=t.currentYear=o.getFullYear(),r===t.selectedMonth&&s===t.selectedYear||i||this._notifyChange(t),this._adjustInstDate(t),t.input&&t.input.val(n?"":this._formatDate(t))},_getDate:function(t){return!t.currentYear||t.input&&""===t.input.val()?null:this._daylightSavingAdjust(new Date(t.currentYear,t.currentMonth,t.currentDay))},_attachHandlers:function(t){var e=this._get(t,"stepMonths"),i="#"+t.id.replace(/\\\\/g,"\\");t.dpDiv.find("[data-handler]").map(function(){var t={prev:function(){E.datepicker._adjustDate(i,-e,"M")},next:function(){E.datepicker._adjustDate(i,+e,"M")},hide:function(){E.datepicker._hideDatepicker()},today:function(){E.datepicker._gotoToday(i)},selectDay:function(){return E.datepicker._selectDay(i,+this.getAttribute("data-month"),+this.getAttribute("data-year"),this),!1},selectMonth:function(){return E.datepicker._selectMonthYear(i,this,"M"),!1},selectYear:function(){return E.datepicker._selectMonthYear(i,this,"Y"),!1}};E(this).on(this.getAttribute("data-event"),t[this.getAttribute("data-handler")])})},_generateHTML:function(t){var e,i,n,r,s,o,a,l,u,c,h,d,p,f,g,m,v,y,b,w,_,x,T,S,C,E,k,I,D,A,P,M,N,O,L,R,F,z,B,$=new Date,j=this._daylightSavingAdjust(new Date($.getFullYear(),$.getMonth(),$.getDate())),H=this._get(t,"isRTL"),q=this._get(t,"showButtonPanel"),V=this._get(t,"hideIfNoPrevNext"),U=this._get(t,"navigationAsDateFormat"),W=this._getNumberOfMonths(t),K=this._get(t,"showCurrentAtPos"),G=this._get(t,"stepMonths"),Y=1!==W[0]||1!==W[1],X=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-K,tt=t.drawYear;if(Z<0&&(Z+=12,tt--),J)for(e=this._daylightSavingAdjust(new Date(J.getFullYear(),J.getMonth()-W[0]*W[1]+1,J.getDate())),e=Q&&e<Q?Q:e;this._daylightSavingAdjust(new Date(tt,Z,1))>e;)--Z<0&&(Z=11,tt--);for(t.drawMonth=Z,t.drawYear=tt,i=this._get(t,"prevText"),i=U?this.formatDate(i,this._daylightSavingAdjust(new Date(tt,Z-G,1)),this._getFormatConfig(t)):i,n=this._canAdjustMonth(t,-1,tt,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-"+(H?"e":"w")+"'>"+i+"</span></a>":V?"":"<a class='ui-datepicker-prev ui-corner-all ui-state-disabled' title='"+i+"'><span class='ui-icon ui-icon-circle-triangle-"+(H?"e":"w")+"'>"+i+"</span></a>",r=this._get(t,"nextText"),r=U?this.formatDate(r,this._daylightSavingAdjust(new Date(tt,Z+G,1)),this._getFormatConfig(t)):r,s=this._canAdjustMonth(t,1,tt,Z)?"<a class='ui-datepicker-next ui-corner-all' data-handler='next' data-event='click' title='"+r+"'><span class='ui-icon ui-icon-circle-triangle-"+(H?"w":"e")+"'>"+r+"</span></a>":V?"":"<a class='ui-datepicker-next ui-corner-all ui-state-disabled' title='"+r+"'><span class='ui-icon ui-icon-circle-triangle-"+(H?"w":"e")+"'>"+r+"</span></a>",o=this._get(t,"currentText"),a=this._get(t,"gotoCurrent")&&t.currentDay?X:j,o=U?this.formatDate(o,a,this._getFormatConfig(t)):o,l=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>",u=q?"<div class='ui-datepicker-buttonpane ui-widget-content'>"+(H?l:"")+(this._isInRange(t,a)?"<button type='button' class='ui-datepicker-current ui-state-default ui-priority-secondary ui-corner-all' data-handler='today' data-event='click'>"+o+"</button>":"")+(H?"":l)+"</div>":"",c=parseInt(this._get(t,"firstDay"),10),c=isNaN(c)?0:c,h=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"),v=this._get(t,"showOtherMonths"),y=this._get(t,"selectOtherMonths"),b=this._getDefaultDate(t),w="",x=0;W[0]>x;x++){for(T="",this.maxRows=4,S=0;W[1]>S;S++){if(C=this._daylightSavingAdjust(new Date(tt,Z,t.selectedDay)),E=" ui-corner-all",k="",Y){if(k+="<div class='ui-datepicker-group",1<W[1])switch(S){case 0:k+=" ui-datepicker-group-first",E=" ui-corner-"+(H?"right":"left");break;case W[1]-1:k+=" ui-datepicker-group-last",E=" ui-corner-"+(H?"left":"right");break;default:k+=" ui-datepicker-group-middle",E=""}k+="'>"}for(k+="<div class='ui-datepicker-header ui-widget-header ui-helper-clearfix"+E+"'>"+(/all|left/.test(E)&&0===x?H?s:n:"")+(/all|right/.test(E)&&0===x?H?n:s:"")+this._generateMonthYearHeader(t,Z,tt,Q,J,0<x||0<S,f,g)+"</div><table class='ui-datepicker-calendar'><thead><tr>",I=h?"<th class='ui-datepicker-week-col'>"+this._get(t,"weekHeader")+"</th>":"",_=0;_<7;_++)I+="<th scope='col'"+(5<=(_+c+6)%7?" class='ui-datepicker-week-end'":"")+"><span title='"+d[D=(_+c)%7]+"'>"+p[D]+"</span></th>";for(k+=I+"</tr></thead><tbody>",A=this._getDaysInMonth(tt,Z),tt===t.selectedYear&&Z===t.selectedMonth&&(t.selectedDay=Math.min(t.selectedDay,A)),P=(this._getFirstDayOfMonth(tt,Z)-c+7)%7,M=Math.ceil((P+A)/7),N=Y&&this.maxRows>M?this.maxRows:M,this.maxRows=N,O=this._daylightSavingAdjust(new Date(tt,Z,1-P)),L=0;L<N;L++){for(k+="<tr>",R=h?"<td class='ui-datepicker-week-col'>"+this._get(t,"calculateWeek")(O)+"</td>":"",_=0;_<7;_++)F=m?m.apply(t.input?t.input[0]:null,[O]):[!0,""],B=(z=O.getMonth()!==Z)&&!y||!F[0]||Q&&O<Q||J&&J<O,R+="<td class='"+(5<=(_+c+6)%7?" ui-datepicker-week-end":"")+(z?" ui-datepicker-other-month":"")+(O.getTime()===C.getTime()&&Z===t.selectedMonth&&t._keyEvent||b.getTime()===O.getTime()&&b.getTime()===C.getTime()?" "+this._dayOverClass:"")+(B?" "+this._unselectableClass+" ui-state-disabled":"")+(z&&!v?"":" "+F[1]+(O.getTime()===X.getTime()?" "+this._currentClass:"")+(O.getTime()===j.getTime()?" ui-datepicker-today":""))+"'"+(z&&!v||!F[2]?"":" title='"+F[2].replace(/'/g,"&#39;")+"'")+(B?"":" data-handler='selectDay' data-event='click' data-month='"+O.getMonth()+"' data-year='"+O.getFullYear()+"'")+">"+(z&&!v?"&#xa0;":B?"<span class='ui-state-default'>"+O.getDate()+"</span>":"<a class='ui-state-default"+(O.getTime()===j.getTime()?" ui-state-highlight":"")+(O.getTime()===X.getTime()?" ui-state-active":"")+(z?" ui-priority-secondary":"")+"' href='#'>"+O.getDate()+"</a>")+"</td>",O.setDate(O.getDate()+1),O=this._daylightSavingAdjust(O);k+=R+"</tr>"}11<++Z&&(Z=0,tt++),T+=k+="</tbody></table>"+(Y?"</div>"+(0<W[0]&&S===W[1]-1?"<div class='ui-datepicker-row-break'></div>":""):"")}w+=T}return w+=u,t._keyEvent=!1,w}
vendor: 13,461 bytes, line 1
1,_generateMonthYearHeader:function(t,e,i,n,r,s,o,a){var l,u,c,h,d,p,f,g,m=this._get(t,"changeMonth"),v=this._get(t,"changeYear"),y=this._get(t,"showMonthAfterYear"),b="<div class='ui-datepicker-title'>",w="";if(s||!m)w+="<span class='ui-datepicker-month'>"+o[e]+"</span>";else{for(l=n&&n.getFullYear()===i,u=r&&r.getFullYear()===i,w+="<select class='ui-datepicker-month' data-handler='selectMonth' data-event='change'>",c=0;c<12;c++)(!l||c>=n.getMonth())&&(!u||r.getMonth()>=c)&&(w+="<option value='"+c+"'"+(c===e?" selected='selected'":"")+">"+a[c]+"</option>");w+="</select>"}if(y||(b+=w+(!s&&m&&v?"":"&#xa0;")),!t.yearshtml)if(t.yearshtml="",s||!v)b+="<span class='ui-datepicker-year'>"+i+"</span>";else{for(h=this._get(t,"yearRange").split(":"),d=(new Date).getFullYear(),f=(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})(h[0]),g=Math.max(f,p(h[1]||"")),f=n?Math.max(f,n.getFullYear()):f,g=r?Math.min(g,r.getFullYear()):g,t.yearshtml+="<select class='ui-datepicker-year' data-handler='selectYear' data-event='change'>";f<=g;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"),y&&(b+=(!s&&m&&v?"":"&#xa0;")+w),b+"</div>"},_adjustInstDate:function(t,e,i){var n=t.selectedYear+("Y"===i?e:0),r=t.selectedMonth+("M"===i?e:0),s=Math.min(t.selectedDay,this._getDaysInMonth(n,r))+("D"===i?e:0),o=this._restrictMinMax(t,this._daylightSavingAdjust(new Date(n,r,s)));t.selectedDay=o.getDate(),t.drawMonth=t.selectedMonth=o.getMonth(),t.drawYear=t.selectedYear=o.getFullYear(),("M"===i||"Y"===i)&&this._notifyChange(t)},_restrictMinMax:function(t,e){var i=this._getMinMaxDate(t,"min"),n=this._getMinMaxDate(t,"max"),r=i&&e<i?i:e;return n&&n<r?n:r},_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,n){var r=this._getNumberOfMonths(t),s=this._daylightSavingAdjust(new Date(i,n+(e<0?e:r[0]*r[1]),1));return e<0&&s.setDate(this._getDaysInMonth(s.getFullYear(),s.getMonth())),this._isInRange(t,s)},_isInRange:function(t,e){var i,n,r=this._getMinMaxDate(t,"min"),s=this._getMinMaxDate(t,"max"),o=null,a=null,l=this._get(t,"yearRange");return l&&(i=l.split(":"),n=(new Date).getFullYear(),o=parseInt(i[0],10),a=parseInt(i[1],10),i[0].match(/[+\-].*/)&&(o+=n),i[1].match(/[+\-].*/)&&(a+=n)),(!r||e.getTime()>=r.getTime())&&(!s||e.getTime()<=s.getTime())&&(!o||e.getFullYear()>=o)&&(!a||a>=e.getFullYear())},_getFormatConfig:function(t){var e=this._get(t,"shortYearCutoff");return{shortYearCutoff:e="string"!=typeof e?e:(new Date).getFullYear()%100+parseInt(e,10),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,n){e||(t.currentDay=t.selectedDay,t.currentMonth=t.selectedMonth,t.currentYear=t.selectedYear);var r=e?"object"==typeof e?e:this._daylightSavingAdjust(new Date(n,i,e)):this._daylightSavingAdjust(new Date(t.currentYear,t.currentMonth,t.currentDay));return this.formatDate(this._get(t,"dateFormat"),r,this._getFormatConfig(t))}}),E.fn.datepicker=function(t){if(!this.length)return this;E.datepicker.initialized||(E(document).on("mousedown",E.datepicker._checkExternalClick),E.datepicker.initialized=!0),0===E("#"+E.datepicker._mainDivId).length&&E("body").append(E.datepicker.dpDiv);var e=Array.prototype.slice.call(arguments,1);return"string"!=typeof t||"isDisabled"!==t&&"getDate"!==t&&"widget"!==t?"option"===t&&2===arguments.length&&"string"==typeof arguments[1]?E.datepicker["_"+t+"Datepicker"].apply(E.datepicker,[this[0]].concat(e)):this.each(function(){"string"==typeof t?E.datepicker["_"+t+"Datepicker"].apply(E.datepicker,[this].concat(e)):E.datepicker._attachDatepicker(this,t)}):E.datepicker["_"+t+"Datepicker"].apply(E.datepicker,[this[0]].concat(e))},E.datepicker=new t,E.datepicker.initialized=!1,E.datepicker.uuid=(new Date).getTime(),E.datepicker.version="1.12.1",E.datepicker,E.ui.ie=!!/msie [\w.]+/.exec(navigator.userAgent.toLowerCase());var b=!1;E(document).on("mouseup",function(){b=!1}),E.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(t){return!0===E.data(t.target,e.widgetName+".preventClickEvent")?(E.removeData(t.target,e.widgetName+".preventClickEvent"),t.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(t){if(!b){this._mouseMoved=!1,this._mouseStarted&&this._mouseUp(t),this._mouseDownEvent=t;var e=this,i=1===t.which,n=!("string"!=typeof this.options.cancel||!t.target.nodeName)&&E(t.target).closest(this.options.cancel).length;return i&&!n&&this._mouseCapture(t)&&(this.mouseDelayMet=!this.options.delay,this.mouseDelayMet||(this._mouseDelayTimer=setTimeout(function(){e.mouseDelayMet=!0},this.options.delay)),this._mouseDistanceMet(t)&&this._mouseDelayMet(t)&&(this._mouseStarted=!1!==this._mouseStart(t),!this._mouseStarted)?t.preventDefault():(!0===E.data(t.target,this.widgetName+".preventClickEvent")&&E.removeData(t.target,this.widgetName+".preventClickEvent"),this._mouseMoveDelegate=function(t){return e._mouseMove(t)},this._mouseUpDelegate=function(t){return e._mouseUp(t)},this.document.on("mousemove."+this.widgetName,this._mouseMoveDelegate).on("mouseup."+this.widgetName,this._mouseUpDelegate),t.preventDefault(),b=!0)),!0}},_mouseMove:function(t){if(this._mouseMoved){if(E.ui.ie&&(!document.documentMode||document.documentMode<9)&&!t.button)return this._mouseUp(t);if(!t.which)if(t.originalEvent.altKey||t.originalEvent.ctrlKey||t.originalEvent.metaKey||t.originalEvent.shiftKey)this.ignoreMissingWhich=!0;else if(!this.ignoreMissingWhich)return this._mouseUp(t)}return(t.which||t.button)&&(this._mouseMoved=!0),this._mouseStarted?(this._mouseDrag(t),t.preventDefault()):(this._mouseDistanceMet(t)&&this._mouseDelayMet(t)&&(this._mouseStarted=!1!==this._mouseStart(this._mouseDownEvent,t),this._mouseStarted?this._mouseDrag(t):this._mouseUp(t)),!this._mouseStarted)},_mouseUp:function(t){this.document.off("mousemove."+this.widgetName,this._mouseMoveDelegate).off("mouseup."+this.widgetName,this._mouseUpDelegate),this._mouseStarted&&(this._mouseStarted=!1,t.target===this._mouseDownEvent.target&&E.data(t.target,this.widgetName+".preventClickEvent",!0),this._mouseStop(t)),this._mouseDelayTimer&&(clearTimeout(this._mouseDelayTimer),delete this._mouseDelayTimer),this.ignoreMissingWhich=!1,b=!1,t.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}}),E.ui.plugin={add:function(t,e,i){var n,r=E.ui[t].prototype;for(n in i)r.plugins[n]=r.plugins[n]||[],r.plugins[n].push([e,i[n]])},call:function(t,e,i,n){var r,s=t.plugins[e];if(s&&(n||t.element[0].parentNode&&11!==t.element[0].parentNode.nodeType))for(r=0;s.length>r;r++)t.options[s[r][0]]&&s[r][1].apply(t.element,i)}},E.ui.safeBlur=function(t){t&&"body"!==t.nodeName.toLowerCase()&&E(t).trigger("blur")},E.widget("ui.draggable",E.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")?void(this.destroyOnClear=!0):(this._removeHandleClassName(),void this._mouseDestroy())},_mouseCapture:function(t){var e=this.options;return!(this.helper||e.disabled||0<E(t.target).closest(".ui-resizable-handle").length)&&(this.handle=this._getHandle(t),!!this.handle&&(this._blurActiveElement(t),this._blockFrames(!0===e.iframeFix?"iframe":e.iframeFix),!0))},_blockFrames:function(t){this.iframeBlocks=this.document.find(t).map(function(){var t=E(this);return E("<div>").css("position","absolute").appendTo(t.parent()).outerWidth(t.outerWidth()).outerHeight(t.outerHeight()).offset(t.offset())[0]})},_unblockFrames:function(){this.iframeBlocks&&(this.iframeBlocks.remove(),delete this.iframeBlocks)},_blurActiveElement:function(t){var e=E.ui.safeActiveElement(this.document[0]);E(t.target).closest(e).length||E.ui.safeBlur(e)},_mouseStart:function(t){var e=this.options;return this.helper=this._createHelper(t),this._addClass(this.helper,"ui-draggable-dragging"),this._cacheHelperProportions(),E.ui.ddmanager&&(E.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=0<this.helper.parents().filter(function(){return"fixed"===E(this).css("position")}).length,this.positionAbs=this.element.offset(),this._refreshOffsets(t),this.originalPosition=this.position=this._generatePosition(t,!1),this.originalPageX=t.pageX,this.originalPageY=t.pageY,e.cursorAt&&this._adjustOffsetFromHelper(e.cursorAt),this._setContainment(),!1===this._trigger("start",t)?(this._clear(),!1):(this._cacheHelperProportions(),E.ui.ddmanager&&!e.dropBehaviour&&E.ui.ddmanager.prepareOffsets(this,t),this._mouseDrag(t,!0),E.ui.ddmanager&&E.ui.ddmanager.dragStart(this,t),!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(t,e){if(this.hasFixedAncestor&&(this.offset.parent=this._getParentOffset()),this.position=this._generatePosition(t,!0),this.positionAbs=this._convertPositionTo("absolute"),!e){var i=this._uiHash();if(!1===this._trigger("drag",t,i))return this._mouseUp(new E.Event("mouseup",t)),!1;this.position=i.position}return this.helper[0].style.left=this.position.left+"px",this.helper[0].style.top=this.position.top+"px",E.ui.ddmanager&&E.ui.ddmanager.drag(this,t),!1},_mouseStop:function(t){var e=this,i=!1;return E.ui.ddmanager&&!this.options.dropBehaviour&&(i=E.ui.ddmanager.drop(this,t)),this.dropped&&(i=this.dropped,this.dropped=!1),"invalid"===this.options.revert&&!i||"valid"===this.options.revert&&i||!0===this.options.revert||E.isFunction(this.options.revert)&&this.options.revert.call(this.element,i)?E(this.helper).animate(this.originalPosition,parseInt(this.options.revertDuration,10),function(){!1!==e._trigger("stop",t)&&e._clear()}):!1!==this._trigger("stop",t)&&this._clear(),!1},_mouseUp:function(t){return this._unblockFrames(),E.ui.ddmanager&&E.ui.ddmanager.dragStop(this,t),this.handleElement.is(t.target)&&this.element.trigger("focus"),E.ui.mouse.prototype._mouseUp.call(this,t)},cancel:function(){return this.helper.is(".ui-draggable-dragging")?this._mouseUp(new E.Event("mouseup",{target:this.element[0]})):this._clear(),this},_getHandle:function(t){return!this.options.handle||!!E(t.target).closest(this.element.find(this.options.handle)).length},_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(t){var e=this.options,i=E.isFunction(e.helper),n=i?E(e.helper.apply(this.element[0],[t])):"clone"===e.helper?this.element.clone().removeAttr("id"):this.element;return n.parents("body").length||n.appendTo("parent"===e.appendTo?this.element[0].parentNode:e.appendTo),i&&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(t){"string"==typeof t&&(t=t.split(" ")),E.isArray(t)&&(t={left:+t[0],top:+t[1]||0}
1),"left"in t&&(this.offset.click.left=t.left+this.margins.left),"right"in t&&(this.offset.click.left=this.helperProportions.width-t.right+this.margins.left),"top"in t&&(this.offset.click.top=t.top+this.margins.top),"bottom"in t&&(this.offset.click.top=this.helperProportions.height-t.bottom+this.margins.top)},_isRootNode:function(t){return/(html|body)/i.test(t.tagName)||t===this.document[0]},_getParentOffset:function(){var t=this.offsetParent.offset(),e=this.document[0];return"absolute"===this.cssPosition&&this.scrollParent[0]!==e&&E.contains(this.scrollParent[0],this.offsetParent[0])&&(t.left+=this.scrollParent.scrollLeft(),t.top+=this.scrollParent.scrollTop()),this._isRootNode(this.offsetParent[0])&&(t={top:0,left:0}),{top:t.top+(parseInt(this.offsetParent.css("borderTopWidth"),10)||0),left:t.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())}},_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 t,e,i,n=this.options,r=this.document[0];return this.relativeContainer=null,n.containment?"window"===n.containment?void(this.containment=[E(window).scrollLeft()-this.offset.relative.left-this.offset.parent.left,E(window).scrollTop()-this.offset.relative.top-this.offset.parent.top,E(window).scrollLeft()+E(window).width()-this.helperProportions.width-this.margins.left,E(window).scrollTop()+(E(window).height()||r.body.parentNode.scrollHeight)-this.helperProportions.height-this.margins.top]):"document"===n.containment?void(this.containment=[0,0,E(r).width()-this.helperProportions.width-this.margins.left,(E(r).height()||r.body.parentNode.scrollHeight)-this.helperProportions.height-this.margins.top]):n.containment.constructor===Array?void(this.containment=n.containment):("parent"===n.containment&&(n.containment=this.helper[0].parentNode),void((i=(e=E(n.containment))[0])&&(t=/(scroll|auto)/.test(e.css("overflow")),this.containment=[(parseInt(e.css("borderLeftWidth"),10)||0)+(parseInt(e.css("paddingLeft"),10)||0),(parseInt(e.css("borderTopWidth"),10)||0)+(parseInt(e.css("paddingTop"),10)||0),(t?Math.max(i.scrollWidth,i.offsetWidth):i.offsetWidth)-(parseInt(e.css("borderRightWidth"),10)||0)-(parseInt(e.css("paddingRight"),10)||0)-this.helperProportions.width-this.margins.left-this.margins.right,(t?Math.max(i.scrollHeight,i.offsetHeight):i.offsetHeight)-(parseInt(e.css("borderBottomWidth"),10)||0)-(parseInt(e.css("paddingBottom"),10)||0)-this.helperProportions.height-this.margins.top-this.margins.bottom],this.relativeContainer=e))):void(this.containment=null)},_convertPositionTo:function(t,e){e||(e=this.position);var i="absolute"===t?1:-1,n=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:n?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:n?0:this.offset.scroll.left)*i}},_generatePosition:function(t,e){var i,n,r,s,o=this.options,a=this._isRootNode(this.scrollParent[0]),l=t.pageX,u=t.pageY;return a&&this.offset.scroll||(this.offset.scroll={top:this.scrollParent.scrollTop(),left:this.scrollParent.scrollLeft()}),e&&(this.containment&&(i=this.relativeContainer?(n=this.relativeContainer.offset(),[this.containment[0]+n.left,this.containment[1]+n.top,this.containment[2]+n.left,this.containment[3]+n.top]):this.containment,t.pageX-this.offset.click.left<i[0]&&(l=i[0]+this.offset.click.left),t.pageY-this.offset.click.top<i[1]&&(u=i[1]+this.offset.click.top),t.pageX-this.offset.click.left>i[2]&&(l=i[2]+this.offset.click.left),t.pageY-this.offset.click.top>i[3]&&(u=i[3]+this.offset.click.top)),o.grid&&(r=o.grid[1]?this.originalPageY+Math.round((u-this.originalPageY)/o.grid[1])*o.grid[1]:this.originalPageY,u=i?r-this.offset.click.top>=i[1]||r-this.offset.click.top>i[3]?r:r-this.offset.click.top>=i[1]?r-o.grid[1]:r+o.grid[1]:r,s=o.grid[0]?this.originalPageX+Math.round((l-this.originalPageX)
vendor: 4,289 bytes, line 1
1/o.grid[0])*o.grid[0]:this.originalPageX,l=i?s-this.offset.click.left>=i[0]||s-this.offset.click.left>i[2]?s:s-this.offset.click.left>=i[0]?s-o.grid[0]:s+o.grid[0]:s),"y"===o.axis&&(l=this.originalPageX),"x"===o.axis&&(u=this.originalPageY)),{top:u-this.offset.click.top-this.offset.relative.top-this.offset.parent.top+("fixed"===this.cssPosition?-this.offset.scroll.top:a?0:this.offset.scroll.top),left:l-this.offset.click.left-this.offset.relative.left-this.offset.parent.left+("fixed"===this.cssPosition?-this.offset.scroll.left:a?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(t,e,i){return i=i||this._uiHash(),E.ui.plugin.call(this,t,[e,i,this],!0),/^(drag|start|stop)/.test(t)&&(this.positionAbs=this._convertPositionTo("absolute"),i.offset=this.positionAbs),E.Widget.prototype._trigger.call(this,t,e,i)},plugins:{},_uiHash:function(){return{helper:this.helper,position:this.position,originalPosition:this.originalPosition,offset:this.positionAbs}}}),E.ui.plugin.add("draggable","connectToSortable",{start:function(e,t,i){var n=E.extend({},t,{item:i.element});i.sortables=[],E(i.options.connectToSortable).each(function(){var t=E(this).sortable("instance");t&&!t.options.disabled&&(i.sortables.push(t),t.refreshPositions(),t._trigger("activate",e,n))})},stop:function(e,t,i){var n=E.extend({},t,{item:i.element});i.cancelHelperRemoval=!1,E.each(i.sortables,function(){var t=this;t.isOver?(t.isOver=0,i.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(i,n,r){E.each(r.sortables,function(){var t=!1,e=this;e.positionAbs=r.positionAbs,e.helperProportions=r.helperProportions,e.offset.click=r.offset.click,e._intersectsWith(e.containerCache)&&(t=!0,E.each(r.sortables,function(){return this.positionAbs=r.positionAbs,this.helperProportions=r.helperProportions,this.offset.click=r.offset.click,this!==e&&this._intersectsWith(this.containerCache)&&E.contains(e.element[0],this.element[0])&&(t=!1),t})),t?(e.isOver||(e.isOver=1,r._parent=n.helper.parent(),e.currentItem=n.helper.appendTo(e.element).data("ui-sortable-item",!0),e.options._helper=e.options.helper,e.options.helper=function(){return n.helper[0]},i.target=e.currentItem[0],e._mouseCapture(i,!0),e._mouseStart(i,!0,!0),e.offset.click.top=r.offset.click.top,e.offset.click.left=r.offset.click.left,e.offset.parent.left-=r.offset.parent.left-e.offset.parent.left,e.offset.parent.top-=r.offset.parent.top-e.offset.parent.top,r._trigger("toSortable",i),r.dropped=e.element,E.each(r.sortables,function(){this.refreshPositions()}),r.currentItem=r.element,e.fromOutside=r),e.currentItem&&(e._mouseDrag(i),n.position=e.position)):e.isOver&&(e.isOver=0,e.cancelHelperRemoval=!0,e.options._revert=e.options.revert,e.options.revert=!1,e._trigger("out",i,e._uiHash(e)),e._mouseStop(i,!0),e.options.revert=e.options._revert,e.options.helper=e.options._helper,e.placeholder&&e.placeholder.remove(),n.helper.appendTo(r._parent),r._refreshOffsets(i),n.position=r._generatePosition(i,!0),r._trigger("fromSortable",i),r.dropped=!1,E.each(r.sortables,function(){this.refreshPositions()}))})}}),E.ui.plugin.add("draggable","cursor",{start:function(t,e,i){var n=E("body"),r=i.options;n.css("cursor")&&(r._cursor=n.css("cursor")),n.css("cursor",r.cursor)},stop:function(t,e,i){var n=i.options;n._cursor&&E("body").css("cursor",n._cursor)}}),E.ui.plugin.add("draggable","opacity",{start:function(t,e,i){var n=E(e.helper),r=i.options;n.css("opacity")&&(r._opacity=n.css("opacity")),n.css("opacity",r.opacity)},stop:function(t,e,i){var n=i.options;n._opacity&&E(e.helper).css("opacity",n._opacity)}}),E.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())}
vendor: 12,161 bytes, line 1
1,drag:function(t,e,i){var n=i.options,r=!1,s=i.scrollParentNotHidden[0],o=i.document[0];s!==o&&"HTML"!==s.tagName?(n.axis&&"x"===n.axis||(i.overflowOffset.top+s.offsetHeight-t.pageY<n.scrollSensitivity?s.scrollTop=r=s.scrollTop+n.scrollSpeed:t.pageY-i.overflowOffset.top<n.scrollSensitivity&&(s.scrollTop=r=s.scrollTop-n.scrollSpeed)),n.axis&&"y"===n.axis||(i.overflowOffset.left+s.offsetWidth-t.pageX<n.scrollSensitivity?s.scrollLeft=r=s.scrollLeft+n.scrollSpeed:t.pageX-i.overflowOffset.left<n.scrollSensitivity&&(s.scrollLeft=r=s.scrollLeft-n.scrollSpeed))):(n.axis&&"x"===n.axis||(t.pageY-E(o).scrollTop()<n.scrollSensitivity?r=E(o).scrollTop(E(o).scrollTop()-n.scrollSpeed):E(window).height()-(t.pageY-E(o).scrollTop())<n.scrollSensitivity&&(r=E(o).scrollTop(E(o).scrollTop()+n.scrollSpeed))),n.axis&&"y"===n.axis||(t.pageX-E(o).scrollLeft()<n.scrollSensitivity?r=E(o).scrollLeft(E(o).scrollLeft()-n.scrollSpeed):E(window).width()-(t.pageX-E(o).scrollLeft())<n.scrollSensitivity&&(r=E(o).scrollLeft(E(o).scrollLeft()+n.scrollSpeed)))),!1!==r&&E.ui.ddmanager&&!n.dropBehaviour&&E.ui.ddmanager.prepareOffsets(i,t)}}),E.ui.plugin.add("draggable","snap",{start:function(t,e,i){var n=i.options;i.snapElements=[],E(n.snap.constructor!==String?n.snap.items||":data(ui-draggable)":n.snap).each(function(){var t=E(this),e=t.offset();this!==i.element[0]&&i.snapElements.push({item:this,width:t.outerWidth(),height:t.outerHeight(),top:e.top,left:e.left})})},drag:function(t,e,i){var n,r,s,o,a,l,u,c,h,d,p=i.options,f=p.snapTolerance,g=e.offset.left,m=g+i.helperProportions.width,v=e.offset.top,y=v+i.helperProportions.height;for(h=i.snapElements.length-1;0<=h;h--)l=(a=i.snapElements[h].left-i.margins.left)+i.snapElements[h].width,c=(u=i.snapElements[h].top-i.margins.top)+i.snapElements[h].height,m<a-f||l+f<g||y<u-f||c+f<v||!E.contains(i.snapElements[h].item.ownerDocument,i.snapElements[h].item)?(i.snapElements[h].snapping&&i.options.snap.release&&i.options.snap.release.call(i.element,t,E.extend(i._uiHash(),{snapItem:i.snapElements[h].item})),i.snapElements[h].snapping=!1):("inner"!==p.snapMode&&(n=f>=Math.abs(u-y),r=f>=Math.abs(c-v),s=f>=Math.abs(a-m),o=f>=Math.abs(l-g),n&&(e.position.top=i._convertPositionTo("relative",{top:u-i.helperProportions.height,left:0}).top),r&&(e.position.top=i._convertPositionTo("relative",{top:c,left:0}).top),s&&(e.position.left=i._convertPositionTo("relative",{top:0,left:a-i.helperProportions.width}).left),o&&(e.position.left=i._convertPositionTo("relative",{top:0,left:l}).left)),d=n||r||s||o,"outer"!==p.snapMode&&(n=f>=Math.abs(u-v),r=f>=Math.abs(c-y),s=f>=Math.abs(a-g),o=f>=Math.abs(l-m),n&&(e.position.top=i._convertPositionTo("relative",{top:u,left:0}).top),r&&(e.position.top=i._convertPositionTo("relative",{top:c-i.helperProportions.height,left:0}).top),s&&(e.position.left=i._convertPositionTo("relative",{top:0,left:a}).left),o&&(e.position.left=i._convertPositionTo("relative",{top:0,left:l-i.helperProportions.width}).left)),!i.snapElements[h].snapping&&(n||r||s||o||d)&&i.options.snap.snap&&i.options.snap.snap.call(i.element,t,E.extend(i._uiHash(),{snapItem:i.snapElements[h].item})),i.snapElements[h].snapping=n||r||s||o||d)}}),E.ui.plugin.add("draggable","stack",{start:function(t,e,i){var n,r=i.options,s=E.makeArray(E(r.stack)).sort(function(t,e){return(parseInt(E(t).css("zIndex"),10)||0)-(parseInt(E(e).css("zIndex"),10)||0)});s.length&&(n=parseInt(E(s[0]).css("zIndex"),10)||0,E(s).each(function(t){E(this).css("zIndex",n+t)}),this.css("zIndex",n+s.length))}}),E.ui.plugin.add("draggable","zIndex",{start:function(t,e,i){var n=E(e.helper),r=i.options;n.css("zIndex")&&(r._zIndex=n.css("zIndex")),n.css("zIndex",r.zIndex)},stop:function(t,e,i){var n=i.options;n._zIndex&&E(e.helper).css("zIndex",n._zIndex)}}),E.ui.draggable,E.widget("ui.resizable",E.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(t,e){if("hidden"===E(t).css("overflow"))return!1;var i=e&&"left"===e?"scrollLeft":"scrollTop",n=!1;return 0<t[i]||(t[i]=1,n=0<t[i],t[i]=0,n)},_create:function(){var t,e=this.options,i=this;this._addClass("ui-resizable"),E.extend(this,{_aspectRatio:!!e.aspectRatio,aspectRatio:e.aspectRatio,originalElement:this.element,_proportionallyResizeElements:[],_helper:e.helper||e.ghost||e.animate?e.helper||"ui-resizable-helper":null}),this.element[0].nodeName.match(/^(canvas|textarea|input|select|button|img)$/i)&&(this.element.wrap(E("<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,t={marginTop:this.originalElement.css("marginTop"),marginRight:this.originalElement.css("marginRight"),marginBottom:this.originalElement.css("marginBottom"),marginLeft:this.originalElement.css("marginLeft")},this.element.css(t),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(t),this._proportionallyResize()),this._setupHandles(),e.autoHide&&E(this.element).on("mouseenter",function(){e.disabled||(i._removeClass("ui-resizable-autohide"),i._handles.show())}).on("mouseleave",function(){e.disabled||i.resizing||(i._addClass("ui-resizable-autohide"),i._handles.hide())}),this._mouseInit()},_destroy:function(){this._mouseDestroy();var t,e=function(t){E(t).removeData("resizable").removeData("ui-resizable").off(".resizable").find(".ui-resizable-handle").remove()};return this.elementIsWrapper&&(e(this.element),t=this.element,this.originalElement.css({position:t.css("position"),width:t.outerWidth(),height:t.outerHeight(),top:t.css("top"),left:t.css("left")}).insertAfter(t),t.remove()),this.originalElement.css("resize",this.originalResizeStyle),e(this.originalElement),this},_setOption:function(t,e){switch(this._super(t,e),t){case"handles":this._removeHandles(),this._setupHandles()}},_setupHandles:function(){var t,e,i,n,r,s=this.options,o=this;if(this.handles=s.handles||(E(".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=E(),this.handles.constructor===String)for("all"===this.handles&&(this.handles="n,e,s,w,se,sw,ne,nw"),i=this.handles.split(","),this.handles={},e=0;i.length>e;e++)n="ui-resizable-"+(t=E.trim(i[e])),r=E("<div>"),this._addClass(r,"ui-resizable-handle "+n),r.css({zIndex:s.zIndex}),this.handles[t]=".ui-resizable-"+t,this.element.append(r);this._renderAxis=function(t){var e,i,n,r;for(e in t=t||this.element,this.handles)this.handles[e].constructor===String?this.handles[e]=this.element.children(this.handles[e]).first().show():(this.handles[e].jquery||this.handles[e].nodeType)&&(this.handles[e]=E(this.handles[e]),this._on(this.handles[e],{mousedown:o._mouseDown})),this.elementIsWrapper&&this.originalElement[0].nodeName.match(/^(textarea|input|select|button)$/i)&&(i=E(this.handles[e],this.element),r=/sw|ne|nw|se|n|s/.test(e)?i.outerHeight():i.outerWidth(),n=["padding",/ne|nw|n/.test(e)?"Top":/se|sw|s/.test(e)?"Bottom":/^e$/.test(e)?"Right":"Left"].join(""),t.css(n,r),this._proportionallyResize()),this._handles=this._handles.add(this.handles[e])},this._renderAxis(this.element),this._handles=this._handles.add(this.element.find(".ui-resizable-handle")),this._handles.disableSelection(),this._handles.on("mouseover",function(){o.resizing||(this.className&&(r=this.className.match(/ui-resizable-(se|sw|ne|nw|n|e|s|w)/i)),o.axis=r&&r[1]?r[1]:"se")}),s.autoHide&&(this._handles.hide(),this._addClass("ui-resizable-autohide"))},_removeHandles:function(){this._handles.remove()},_mouseCapture:function(t){var e,i,n=!1;for(e in this.handles)((i=E(this.handles[e])[0])===t.target||E.contains(i,t.target))&&(n=!0);return!this.options.disabled&&n},_mouseStart:function(t){var e,i,n,r=this.options,s=this.element;return this.resizing=!0,this._renderProxy(),e=this._num(this.helper.css("left")),i=this._num(this.helper.css("top")),r.containment&&(e+=E(r.containment).scrollLeft()||0,i+=E(r.containment).scrollTop()||0),this.offset=this.helper.offset(),this.position={left:e,top:i},this.size=this._helper?{width:this.helper.width(),height:this.helper.height()}:{width:s.width(),height:s.height()},this.originalSize=this._helper?{width:s.outerWidth(),height:s.outerHeight()}:{width:s.width(),height:s.height()},this.sizeDiff={width:s.outerWidth()-s.width(),height:s.outerHeight()-s.height()},this.originalPosition={left:e,top:i},this.originalMousePosition={left:t.pageX,top:t.pageY},this.aspectRatio="number"==typeof r.aspectRatio?r.aspectRatio:this.originalSize.width/this.originalSize.height||1,n=E(".ui-resizable-"+this.axis).css("cursor"),E("body").css("cursor","auto"===n?this.axis+"-resize":n),this._addClass("ui-resizable-resizing"),this._propagate("start",t),!0},_mouseDrag:function(t){var e,i,n=this.originalMousePosition,r=this.axis,s=t.pageX-n.left||0,o=t.pageY-n.top||0,a=this._change[r];return this._updatePrevProperties(),a&&(e=a.apply(this,[t,s,o]),this._updateVirtualBoundaries(t.shiftKey),(this._aspectRatio||t.shiftKey)&&(e=this._updateRatio(e,t)),e=this._respectSize(e,t),this._updateCache(e),this._propagate("resize",t),i=this._applyChanges(),!this._helper&&this._proportionallyResizeElements.length&&this._proportionallyResize(),E.isEmptyObject(i)||(this._updatePrevProperties(),this._trigger("resize",t,this.ui()),this._applyChanges())),!1},_mouseStop:function(t){this.resizing=!1;var e,i,n,r,s,o,a,l=this.options,u=this;return this._helper&&(n=(i=(e=this._proportionallyResizeElements).length&&/textarea/i.test(e[0].nodeName))&&this._hasScroll(e[0],"left")?0:u.sizeDiff.height,r=i?0:u.sizeDiff.width,s={width:u.helper.width()-r,height:u.helper.height()-n},o=parseFloat(u.element.css("left"))+(u.position.left-u.originalPosition.left)||null,a=parseFloat(u.element.css("top"))+(u.position.top-u.originalPosition.top)||null,l.animate||this.element.css(E.extend(s,{top:a,left:o})),u.helper.height(u.size.height),u.helper.width(u.size.width),this._helper&&!l.animate&&this._proportionallyResize()),E("body").css("cursor","auto"),this._removeClass("ui-resizable-resizing"),this._propagate("stop",t),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,n,r,s,o=this.options;s={minWidth:this._isNumber(o.minWidth)?o.minWidth:0,maxWidth:this._isNumber(o.maxWidth)?o.maxWidth:1/0,minHeight:this._isNumber(o.minHeight)?o.minHeight:0,maxHeight:this._isNumber(o.maxHeight)?o.maxHeight:1/0},(this._aspectRatio||t)&&(e=s.minHeight*this.aspectRatio,n=s.minWidth/this.aspectRatio,i=s.maxHeight*this.aspectRatio,r=s.maxWidth/this.aspectRatio,e>s.minWidth&&(s.minWidth=e),n>s.minHeight&&(s.minHeight=n),s.maxWidth>i&&(s.maxWidth=i),s.maxHeight>r&&(s.maxHeight=r)),this._vBoundaries=s},_updateCache:function(t){this.offset=this.helper.offset(),this._isNumber(t.left)&&(this.position.left
vendor: 5,793 bytes, line 1
1=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,n=this.axis;return this._isNumber(t.height)?t.width=t.height*this.aspectRatio:this._isNumber(t.width)&&(t.height=t.width/this.aspectRatio),"sw"===n&&(t.left=e.left+(i.width-t.width),t.top=null),"nw"===n&&(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,n=this._isNumber(t.width)&&e.maxWidth&&e.maxWidth<t.width,r=this._isNumber(t.height)&&e.maxHeight&&e.maxHeight<t.height,s=this._isNumber(t.width)&&e.minWidth&&e.minWidth>t.width,o=this._isNumber(t.height)&&e.minHeight&&e.minHeight>t.height,a=this.originalPosition.left+this.originalSize.width,l=this.originalPosition.top+this.originalSize.height,u=/sw|nw|w/.test(i),c=/nw|ne|n/.test(i);return s&&(t.width=e.minWidth),o&&(t.height=e.minHeight),n&&(t.width=e.maxWidth),r&&(t.height=e.maxHeight),s&&u&&(t.left=a-e.minWidth),n&&u&&(t.left=a-e.maxWidth),o&&c&&(t.top=l-e.minHeight),r&&c&&(t.top=l-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=[],n=[t.css("borderTopWidth"),t.css("borderRightWidth"),t.css("borderBottomWidth"),t.css("borderLeftWidth")],r=[t.css("paddingTop"),t.css("paddingRight"),t.css("paddingBottom"),t.css("paddingLeft")];e<4;e++)i[e]=parseFloat(n[e])||0,i[e]+=parseFloat(r[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 t=this.element,e=this.options;this.elementOffset=t.offset(),this._helper?(this.helper=this.helper||E("<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:++e.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;return{left:this.originalPosition.left+e,width:i.width-e}},n:function(t,e,i){var n=this.originalSize;return{top:this.originalPosition.top+i,height:n.height-i}},s:function(t,e,i){return{height:this.originalSize.height+i}},se:function(t,e,i){return E.extend(this._change.s.apply(this,arguments),this._change.e.apply(this,[t,e,i]))},sw:function(t,e,i){return E.extend(this._change.s.apply(this,arguments),this._change.w.apply(this,[t,e,i]))},ne:function(t,e,i){return E.extend(this._change.n.apply(this,arguments),this._change.e.apply(this,[t,e,i]))},nw:function(t,e,i){return E.extend(this._change.n.apply(this,arguments),this._change.w.apply(this,[t,e,i]))}},_propagate:function(t,e){E.ui.plugin.call(this,t,[e,this.ui()]),"resize"!==t&&this._trigger(t,e,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}}}),E.ui.plugin.add("resizable","animate",{stop:function(e){var i=E(this).resizable("instance"),t=i.options,n=i._proportionallyResizeElements,r=n.length&&/textarea/i.test(n[0].nodeName),s=r&&i._hasScroll(n[0],"left")?0:i.sizeDiff.height,o=r?0:i.sizeDiff.width,a={width:i.size.width-o,height:i.size.height-s},l=parseFloat(i.element.css("left"))+(i.position.left-i.originalPosition.left)||null,u=parseFloat(i.element.css("top"))+(i.position.top-i.originalPosition.top)||null;i.element.animate(E.extend(a,u&&l?{top:u,left:l}:{}),{duration:t.animateDuration,easing:t.animateEasing,step:function(){var t={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&&E(n[0]).css({width:t.width,height:t.height}),i._updateCache(t),i._propagate("resize",e)}})}}),E.ui.plugin.add("resizable","containment",{start:function(){var i,n,t,e,r,s,o,a=E(this).resizable("instance"),l=a.options,u=a.element,c=l.containment,h=c instanceof E?c.get(0):/parent/.test(c)?u.parent().get(0):c;h&&(a.containerElement=E(h),/document/.test(c)||c===document?(a.containerOffset={left:0,top:0},a.containerPosition={left:0,top:0},a.parentData={element:E(document),left:0,top:0,width:E(document).width(),height:E(document).height()||document.body.parentNode.scrollHeight}):(i=E(h),n=[],E(["Top","Right","Left","Bottom"]).each(function(t,e){n[t]=a._num(i.css("padding"+e))}),a.containerOffset=i.offset(),a.containerPosition=i.position(),a.containerSize={height:i.innerHeight()-n[3],width:i.innerWidth()-n[1]},t=a.containerOffset,e=a.containerSize.height,r=a.containerSize.width,s=a._hasScroll(h,"left")?h.scrollWidth:r,o=a._hasScroll(h)?h.scrollHeight:e,a.parentData={element:h,left:t.left,top:t.top,width:s,height:o}))},resize:function(t){var e,i,n,r,s=E(this).resizable("instance"),o=s.options,a=s.containerOffset,l=s.position,u=s._aspectRatio||t.shiftKey,c={top:0,left:0},h=s.containerElement,d=!0;h[0]!==document&&/static/.test(h.css("position"))&&(c=a),l.left<(s._helper?a.left:0)&&(s.size.width=s.size.width+(s._helper?s.position.left-a.left:s.position.left-c.left),u&&(s.size.height=s.size.width/s.aspectRatio,d=!1),s.position.left
vendor: 2,025 bytes, line 1
1=o.helper?a.left:0),l.top<(s._helper?a.top:0)&&(s.size.height=s.size.height+(s._helper?s.position.top-a.top:s.position.top),u&&(s.size.width=s.size.height*s.aspectRatio,d=!1),s.position.top=s._helper?a.top:0),n=s.containerElement.get(0)===s.element.parent().get(0),r=/relative|absolute/.test(s.containerElement.css("position")),n&&r?(s.offset.left=s.parentData.left+s.position.left,s.offset.top=s.parentData.top+s.position.top):(s.offset.left=s.element.offset().left,s.offset.top=s.element.offset().top),e=Math.abs(s.sizeDiff.width+(s._helper?s.offset.left-c.left:s.offset.left-a.left)),i=Math.abs(s.sizeDiff.height+(s._helper?s.offset.top-c.top:s.offset.top-a.top)),e+s.size.width>=s.parentData.width&&(s.size.width=s.parentData.width-e,u&&(s.size.height=s.size.width/s.aspectRatio,d=!1)),i+s.size.height>=s.parentData.height&&(s.size.height=s.parentData.height-i,u&&(s.size.width=s.size.height*s.aspectRatio,d=!1)),d||(s.position.left=s.prevPosition.left,s.position.top=s.prevPosition.top,s.size.width=s.prevSize.width,s.size.height=s.prevSize.height)},stop:function(){var t=E(this).resizable("instance"),e=t.options,i=t.containerOffset,n=t.containerPosition,r=t.containerElement,s=E(t.helper),o=s.offset(),a=s.outerWidth()-t.sizeDiff.width,l=s.outerHeight()-t.sizeDiff.height;t._helper&&!e.animate&&/relative/.test(r.css("position"))&&E(this).css({left:o.left-n.left-i.left,width:a,height:l}),t._helper&&!e.animate&&/static/.test(r.css("position"))&&E(this).css({left:o.left-n.left-i.left,width:a,height:l})}}),E.ui.plugin.add("resizable","alsoResize",{start:function(){var t=E(this).resizable("instance").options;E(t.alsoResize).each(function(){var t=E(this);t.data("ui-resizable-alsoresize",{width:parseFloat(t.width()),height:parseFloat(t.height()),left:parseFloat(t.css("left")),top:parseFloat(t.css("top"))})})},resize:function(t,i){var e=E(this).resizable("instance"),n=e.options,r=e.originalSize,s=e.originalPosition,o={height:e.size.height-r.height||0,width:e.size.width-r.width||0,top:e.position.top-s.top||0,left
vendor: 14,576 bytes, line 1
1:e.position.left-s.left||0};E(n.alsoResize).each(function(){var t=E(this),n=E(this).data("ui-resizable-alsoresize"),r={},e=t.parents(i.originalElement[0]).length?["width","height"]:["width","height","top","left"];E.each(e,function(t,e){var i=(n[e]||0)+(o[e]||0);i&&0<=i&&(r[e]=i||null)}),t.css(r)})},stop:function(){E(this).removeData("ui-resizable-alsoresize")}}),E.ui.plugin.add("resizable","ghost",{start:function(){var t=E(this).resizable("instance"),e=t.size;t.ghost=t.originalElement.clone(),t.ghost.css({opacity:.25,display:"block",position:"relative",height:e.height,width:e.width,margin:0,left:0,top:0}),t._addClass(t.ghost,"ui-resizable-ghost"),!1!==E.uiBackCompat&&"string"==typeof t.options.ghost&&t.ghost.addClass(this.options.ghost),t.ghost.appendTo(t.helper)},resize:function(){var t=E(this).resizable("instance");t.ghost&&t.ghost.css({position:"relative",height:t.size.height,width:t.size.width})},stop:function(){var t=E(this).resizable("instance");t.ghost&&t.helper&&t.helper.get(0).removeChild(t.ghost.get(0))}}),E.ui.plugin.add("resizable","grid",{resize:function(){var t,e=E(this).resizable("instance"),i=e.options,n=e.size,r=e.originalSize,s=e.originalPosition,o=e.axis,a="number"==typeof i.grid?[i.grid,i.grid]:i.grid,l=a[0]||1,u=a[1]||1,c=Math.round((n.width-r.width)/l)*l,h=Math.round((n.height-r.height)/u)*u,d=r.width+c,p=r.height+h,f=i.maxWidth&&d>i.maxWidth,g=i.maxHeight&&p>i.maxHeight,m=i.minWidth&&i.minWidth>d,v=i.minHeight&&i.minHeight>p;i.grid=a,m&&(d+=l),v&&(p+=u),f&&(d-=l),g&&(p-=u),/^(se|s|e)$/.test(o)?(e.size.width=d,e.size.height=p):/^(ne)$/.test(o)?(e.size.width=d,e.size.height=p,e.position.top=s.top-h):/^(sw)$/.test(o)?(e.size.width=d,e.size.height=p,e.position.left=s.left-c):((p-u<=0||d-l<=0)&&(t=e._getPaddingPlusBorderDimensions(this)),0<p-u?(e.size.height=p,e.position.top=s.top-h):(p=u-t.height,e.size.height=p,e.position.top=s.top+r.height-p),0<d-l?(e.size.width=d,e.position.left=s.left-c):(d=l-t.width,e.size.width=d,e.position.left=s.left+r.width-d))}}),E.ui.resizable,E.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(t){var e=E(this).css(t).offset().top;e<0&&E(this).css("top",t.top-e)}},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&&E.fn.draggable&&this._makeDraggable(),this.options.resizable&&E.fn.resizable&&this._makeResizable(),this._isOpen=!1,this._trackFocus()},_init:function(){this.options.autoOpen&&this.open()},_appendTo:function(){var t=this.options.appendTo;return t&&(t.jquery||t.nodeType)?E(t):this.document.find(t||"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)).length&&t[0]!==this.element[0]?t.before(this.element):e.parent.append(this.element)},widget:function(){return this.uiDialog},disable:E.noop,enable:E.noop,close:function(t){var e=this;this._isOpen&&!1!==this._trigger("beforeClose",t)&&(this._isOpen=!1,this._focusedElement=null,this._destroyOverlay(),this._untrackInstance(),this.opener.filter(":focusable").trigger("focus").length||E.ui.safeBlur(E.ui.safeActiveElement(this.document[0])),this._hide(this.uiDialog,this.options.hide,function(){e._trigger("close",t)}))},isOpen:function(){return this._isOpen},moveToTop:function(){this._moveToTop()},_moveToTop:function(t,e){var i=!1,n=this.uiDialog.siblings(".ui-front:visible").map(function(){return+E(this).css("z-index")}).get(),r=Math.max.apply(null,n);return r>=+this.uiDialog.css("z-index")&&(this.uiDialog.css("z-index",r+1),i=!0),i&&!e&&this._trigger("focus",t),i},open:function(){var t=this;return this._isOpen?void(this._moveToTop()&&this._focusTabbable()):(this._isOpen=!0,this.opener=E(E.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(){t._focusTabbable(),t._trigger("focus")}),this._makeFocusTarget(),void this._trigger("open"))},_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(t){function e(){var t=E.ui.safeActiveElement(this.document[0]);this.uiDialog[0]===t||E.contains(this.uiDialog[0],t)||this._focusTabbable()}t.preventDefault(),e.call(this),this._delay(e)},_createWrapper:function(){this.uiDialog=E("<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(t){if(this.options.closeOnEscape&&!t.isDefaultPrevented()&&t.keyCode&&t.keyCode===E.ui.keyCode.ESCAPE)return t.preventDefault(),void this.close(t);if(t.keyCode===E.ui.keyCode.TAB&&!t.isDefaultPrevented()){var e=this.uiDialog.find(":tabbable"),i=e.filter(":first"),n=e.filter(":last");t.target!==n[0]&&t.target!==this.uiDialog[0]||t.shiftKey?t.target!==i[0]&&t.target!==this.uiDialog[0]||!t.shiftKey||(this._delay(function(){n.trigger("focus")}),t.preventDefault()):(this._delay(function(){i.trigger("focus")}),t.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 t;this.uiDialogTitlebar=E("<div>"),this._addClass(this.uiDialogTitlebar,"ui-dialog-titlebar","ui-widget-header ui-helper-clearfix"),this._on(this.uiDialogTitlebar,{mousedown:function(t){E(t.target).closest(".ui-dialog-titlebar-close")||this.uiDialog.trigger("focus")}}),this.uiDialogTitlebarClose=E("<button type='button'></button>").button({label:E("<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)}}),t=E("<span>").uniqueId().prependTo(this.uiDialogTitlebar),this._addClass(t,"ui-dialog-title"),this._title(t),this.uiDialogTitlebar.prependTo(this.uiDialog),this.uiDialog.attr({"aria-labelledby":t.attr("id")})},_title:function(t){this.options.title?t.text(this.options.title):t.html("&#160;")},_createButtonPane:function(){this.uiDialogButtonPane=E("<div>"),this._addClass(this.uiDialogButtonPane,"ui-dialog-buttonpane","ui-widget-content ui-helper-clearfix"),this.uiButtonSet=E("<div>").appendTo(this.uiDialogButtonPane),this._addClass(this.uiButtonSet,"ui-dialog-buttonset"),this._createButtons()},_createButtons:function(){var r=this,t=this.options.buttons;return this.uiDialogButtonPane.remove(),this.uiButtonSet.empty(),E.isEmptyObject(t)||E.isArray(t)&&!t.length?void this._removeClass(this.uiDialog,"ui-dialog-buttons"):(E.each(t,function(t,e){var i,n;e=E.isFunction(e)?{click:e,text:t}:e,e=E.extend({type:"button"},e),i=e.click,n={icon:e.icon,iconPosition:e.iconPosition,showLabel:e.showLabel,icons:e.icons,text:e.text},delete e.click,delete e.icon,delete e.iconPosition,delete e.showLabel,delete e.icons,"boolean"==typeof e.text&&delete e.text,E("<button></button>",e).button(n).appendTo(r.uiButtonSet).on("click",function(){i.apply(r.element[0],arguments)})}),this._addClass(this.uiDialog,"ui-dialog-buttons"),void this.uiDialogButtonPane.appendTo(this.uiDialog))},_makeDraggable:function(){function r(t){return{position:t.position,offset:t.offset}}var s=this,o=this.options;this.uiDialog.draggable({cancel:".ui-dialog-content, .ui-dialog-titlebar-close",handle:".ui-dialog-titlebar",containment:"document",start:function(t,e){s._addClass(E(this),"ui-dialog-dragging"),s._blockFrames(),s._trigger("dragStart",t,r(e))},drag:function(t,e){s._trigger("drag",t,r(e))},stop:function(t,e){var i=e.offset.left-s.document.scrollLeft(),n=e.offset.top-s.document.scrollTop();o.position={my:"left top",at:"left"+(0<=i?"+":"")+i+" top"+(0<=n?"+":"")+n,of:s.window},s._removeClass(E(this),"ui-dialog-dragging"),s._unblockFrames(),s._trigger("dragStop",t,r(e))}})},_makeResizable:function(){function s(t){return{originalPosition:t.originalPosition,originalSize:t.originalSize,position:t.position,size:t.size}}var o=this,a=this.options,t=a.resizable,e=this.uiDialog.css("position"),i="string"==typeof t?t:"n,e,s,w,se,sw,ne,nw";this.uiDialog.resizable({cancel:".ui-dialog-content",containment:"document",alsoResize:this.element,maxWidth:a.maxWidth,maxHeight:a.maxHeight,minWidth:a.minWidth,minHeight:this._minHeight(),handles:i,start:function(t,e){o._addClass(E(this),"ui-dialog-resizing"),o._blockFrames(),o._trigger("resizeStart",t,s(e))},resize:function(t,e){o._trigger("resize",t,s(e))},stop:function(t,e){var i=o.uiDialog.offset(),n=i.left-o.document.scrollLeft(),r=i.top-o.document.scrollTop();a.height=o.uiDialog.height(),a.width=o.uiDialog.width(),a.position={my:"left top",at:"left"+(0<=n?"+":"")+n+" top"+(0<=r?"+":"")+r,of:o.window},o._removeClass(E(this),"ui-dialog-resizing"),o._unblockFrames(),o._trigger("resizeStop",t,s(e))}}).css("position",e)},_trackFocus:function(){this._on(this.widget(),{focusin:function(t){this._makeFocusTarget(),this._focusedElement=E(t.target)}})},_makeFocusTarget:function(){this._untrackInstance(),this._trackingInstances().unshift(this)},_untrackInstance:function(){var t=this._trackingInstances(),e=E.inArray(this,t);-1!==e&&t.splice(e,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(t){var i=this,n=!1,r={};E.each(t,function(t,e){i._setOption(t,e),t in i.sizeRelatedOptions&&(n=!0),t in i.resizableRelatedOptions&&(r[t]=e)}),n&&(this._size(),this._position()),this.uiDialog.is(":data(ui-resizable)")&&this.uiDialog.resizable("option",r)},_setOption:function(t,e){var i,n,r=this.uiDialog;"disabled"!==t&&(this._super(t,e),"appendTo"===t&&this.uiDialog.appendTo(this._appendTo()),"buttons"===t&&this._createButtons(),"closeText"===t&&this.uiDialogTitlebarClose.button({label:E("<a>").text(""+this.options.closeText).html()}),"draggable"===t&&((i=r.is(":data(ui-draggable)"))&&!e&&r.draggable("destroy"),!i&&e&&this._makeDraggable()),"position"===t&&this._position(),"resizable"===t&&((n=r.is(":data(ui-resizable)"))&&!e&&r.resizable("destroy"),n&&"string"==typeof e&&r.resizable("option","handles",e),n||!1===e||this._makeResizable()),"title"===t&&this._title(this.uiDialogTitlebar.find(".ui-dialog-title")))},_size:function(){var t,e,i,n=this.options;this.element.show().css({width:"auto",minHeight:0,maxHeight:"none",height:0}),n.minWidth>n.width&&(n.width=n.minWidth),t=this.uiDialog.css({height:"auto",width:n.width}).outerHeight(),e=Math.max(0,n.minHeight-t),i="number"==typeof n.maxHeight?Math.max(0,n.maxHeight-t):"none","auto"===n.height?this.element.css({minHeight:e,maxHeight:i,height:"auto"}):this.element.height(Math.max(0,n.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 t=E(this);return E("<div>").css({position:"absolute",width:t.outerWidth(),height:t.outerHeight()}).appendTo(t.parent()).offset(t.offset())[0]})},_unblockFrames:function(){this.iframeBlocks&&(this.iframeBlocks.remove(),delete this.iframeBlocks)},_allowInteraction:function(t){return!!E(t.target).closest(".ui-dialog").length||!!E(t.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=E("<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}}}),!1!==E.uiBackCompat&&E.widget("ui.dialog",E.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)}}),E.ui.dialog,E.widget("ui.droppable",{version:"1.12.1",widgetEventPrefix:"drop",o
1ptions:{accept:"*",addClasses:!0,greedy:!1,scope:"default",tolerance:"intersect",activate:null,deactivate:null,drop:null,out:null,over:null},_create:function(){var t,e=this.options,i=e.accept;this.isover=!1,this.isout=!0,this.accept=E.isFunction(i)?i:function(t){return t.is(i)},this.proportions=function(){return arguments.length?void(t=arguments[0]):t||(t={width:this.element[0].offsetWidth,height:this.element[0].offsetHeight})},this._addToManager(e.scope),e.addClasses&&this._addClass("ui-droppable")},_addToManager:function(t){E.ui.ddmanager.droppables[t]=E.ui.ddmanager.droppables[t]||[],E.ui.ddmanager.droppables[t].push(this)},_splice:function(t){for(var e=0;t.length>e;e++)t[e]===this&&t.splice(e,1)},_destroy:function(){var t=E.ui.ddmanager.droppables[this.options.scope];this._splice(t)},_setOption:function(t,e){if("accept"===t)this.accept=E.isFunction(e)?e:function(t){return t.is(e)};else if("scope"===t){var i=E.ui.ddmanager.droppables[this.options.scope];this._splice(i),this._addToManager(e)}this._super(t,e)},_activate:function(t){var e=E.ui.ddmanager.current;this._addActiveClass(),e&&this._trigger("activate",t,this.ui(e))},_deactivate:function(t){var e=E.ui.ddmanager.current;this._removeActiveClass(),e&&this._trigger("deactivate",t,this.ui(e))},_over:function(t){var e=E.ui.ddmanager.current;e&&(e.currentItem||e.element)[0]!==this.element[0]&&this.accept.call(this.element[0],e.currentItem||e.element)&&(this._addHoverClass(),this._trigger("over",t,this.ui(e)))},_out:function(t){var e=E.ui.ddmanager.current;e&&(e.currentItem||e.element)[0]!==this.element[0]&&this.accept.call(this.element[0],e.currentItem||e.element)&&(this._removeHoverClass(),this._trigger("out",t,this.ui(e)))},_drop:function(e,t){var i=t||E.ui.ddmanager.current,n=!1;return!(!i||(i.currentItem||i.element)[0]===this.element[0])&&(this.element.find(":data(ui-droppable)").not(".ui-draggable-dragging").each(function(){var t=E(this).droppable("instance");return t.options.greedy&&!t.options.disabled&&t.options.scope===i.options.scope&&t.accept.call(t.element[0],i.currentItem||i.element)&&_(i,E.extend(t,{offset:t.element.offset()}),t.options.tolerance,e)?!(n=!0):void 0}),!n&&(!!this.accept.call(this.element[0],i.currentItem||i.element)&&(this._removeActiveClass(),this._removeHoverClass(),this._trigger("drop",e,this.ui(i)),this.element)))},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 w,_=E.ui.intersect=function(){function d(t,e,i){return e<=t&&t<e+i}return function(t,e,i,n){if(!e.offset)return!1;var r=(t.positionAbs||t.position.absolute).left+t.margins.left,s=(t.positionAbs||t.position.absolute).top+t.margins.top,o=r+t.helperProportions.width,a=s+t.helperProportions.height,l=e.offset.left,u=e.offset.top,c=l+e.proportions().width,h=u+e.proportions().height;switch(i){case"fit":return l<=r&&o<=c&&u<=s&&a<=h;case"intersect":return r+t.helperProportions.width/2>l&&c>o-t.helperProportions.width/2&&s+t.helperProportions.height/2>u&&h>a-t.helperProportions.height/2;case"pointer":return d(n.pageY,u,e.proportions().height)&&d(n.pageX,l,e.proportions().width);case"touch":return(u<=s&&s<=h||u<=a&&a<=h||s<u&&h<a)&&(l<=r&&r<=c||l<=o&&o<=c||r<l&&c<o);default:return!1}}}();!(E.ui.ddmanager={current:null,droppables:{default:[]},prepareOffsets:function(t,e){var i,n,r=E.ui.ddmanager.droppables[t.options.scope]||[],s=e?e.type:null,o=(t.currentItem||t.element).find(":data(ui-droppable)").addBack();t:for(i=0;r.length>i;i++)if(!(r[i].options.disabled||t&&!r[i].accept.call(r[i].element[0],t.currentItem||t.element))){for(n=0;o.length>n;n++)if(o[n]===r[i].element[0]){r[i].proportions().height=0;continue t}r[i].visible="none"!==r[i].element.css("display"),r[i].visible&&("mousedown"===s&&r[i]._activate.call(r[i],e),r[i].offset=r[i].element.offset(),r[i].proportions({width:r[i].element[0].offsetWidth,height:r[i].element[0].offsetHeight}))}},drop:function(t,e){var i=!1;return E.each((E.ui.ddmanager.droppables[t.options.scope]||[]).slice(),function(){this.options&&(!this.options.disabled&&this.visible&&_(t,this,this.options.tolerance,e)&&(i=this._drop.call(this,e)||i),!this.options.disabled&&this.visible&&this.accept.call(this.element[0],t.currentItem||t.element)&&(this.isout=!0,this.isover=!1,this._deactivate.call(this,e)))}),i},dragStart:function(t,e){t.element.parentsUntil("body").on("scroll.droppable",function(){t.options.refreshPositions||E.ui.ddmanager.prepareOffsets(t,e)})},drag:function(s,o){s.options.refreshPositions&&E.ui.ddmanager.prepareOffsets(s,o),E.each(E.ui.ddmanager.droppables[s.options.scope]||[],function(){if(!this.options.disabled&&!this.greedyChild&&this.visible){var t,e,i,n=_(s,this,this.options.tolerance,o),r=!n&&this.isover?"isout":n&&!this.isover?"isover":null;r&&(this.options.greedy&&(e=this.options.scope,(i=this.element.parents(":data(ui-droppable)").filter(function(){return E(this).droppable("instance").options.scope===e})).length&&((t=E(i[0]).droppable("instance")).greedyChild="isover"===r)),t&&"isover"===r&&(t.isover=!1,t.isout=!0,t._out.call(t,o)),this[r]=!0,this["isout"===r?"isover":"isout"]=!1,this["isover"===r?"_over":"_out"].call(this,o),t&&"isout"===r&&(t.isout=!1,t.isover=!0,t._over.call(t,o)))}})},dragStop:function(t,e){t.element.parentsUntil("body").off("scroll.droppable"),t.options.refreshPositions||E.ui.ddmanager.prepareOffsets(t,e)}})!==E.uiBackCompat&&E.widget("ui.droppable",E.ui.droppable,{options:{hoverClass:!1,activeClass:!1}
vendor: 11,898 bytes, line 1
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)}}),E.ui.droppable,E.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=E("<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),void this._refreshValue())},_constrainedValue:function(t){return void 0===t&&(t=this.options.value),this.indeterminate=!1===t,"number"!=typeof t&&(t=0),!this.indeterminate&&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 t=this.options.value,e=this._percentage();this.valueDiv.toggle(this.indeterminate||t>this.min).width(e.toFixed(0)+"%"),this._toggleClass(this.valueDiv,"ui-progressbar-complete",null,t===this.options.max)._toggleClass("ui-progressbar-indeterminate",null,this.indeterminate),this.indeterminate?(this.element.removeAttr("aria-valuenow"),this.overlayDiv||(this.overlayDiv=E("<div>").appendTo(this.valueDiv),this._addClass(this.overlayDiv,"ui-progressbar-overlay"))):(this.element.attr({"aria-valuemax":this.options.max,"aria-valuenow":t}),this.overlayDiv&&(this.overlayDiv.remove(),this.overlayDiv=null)),this.oldValue!==t&&(this.oldValue=t,this._trigger("change")),t===this.options.max&&this._trigger("complete")}}),E.widget("ui.selectable",E.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 n=this;this._addClass("ui-selectable"),this.dragged=!1,this.refresh=function(){n.elementPos=E(n.element[0]).offset(),n.selectees=E(n.options.filter,n.element[0]),n._addClass(n.selectees,"ui-selectee"),n.selectees.each(function(){var t=E(this),e=t.offset(),i={left:e.left-n.elementPos.left,top:e.top-n.elementPos.top};E.data(this,"selectable-item",{element:this,$element:t,left:i.left,top:i.top,right:i.left+t.outerWidth(),bottom:i.top+t.outerHeight(),startselected:!1,selected:t.hasClass("ui-selected"),selecting:t.hasClass("ui-selecting"),unselecting:t.hasClass("ui-unselecting")})})},this.refresh(),this._mouseInit(),this.helper=E("<div>"),this._addClass(this.helper,"ui-selectable-helper")},_destroy:function(){this.selectees.removeData("selectable-item"),this._mouseDestroy()},_mouseStart:function(i){var n=this,t=this.options;this.opos=[i.pageX,i.pageY],this.elementPos=E(this.element[0]).offset(),this.options.disabled||(this.selectees=E(t.filter,this.element[0]),this._trigger("start",i),E(t.appendTo).append(this.helper),this.helper.css({left:i.pageX,top:i.pageY,width:0,height:0}),t.autoRefresh&&this.refresh(),this.selectees.filter(".ui-selected").each(function(){var t=E.data(this,"selectable-item");t.startselected=!0,i.metaKey||i.ctrlKey||(n._removeClass(t.$element,"ui-selected"),t.selected=!1,n._addClass(t.$element,"ui-unselecting"),t.unselecting=!0,n._trigger("unselecting",i,{unselecting:t.element}))}),E(i.target).parents().addBack().each(function(){var t,e=E.data(this,"selectable-item");return e?(t=!i.metaKey&&!i.ctrlKey||!e.$element.hasClass("ui-selected"),n._removeClass(e.$element,t?"ui-unselecting":"ui-selected")._addClass(e.$element,t?"ui-selecting":"ui-unselecting"),e.unselecting=!t,e.selecting=t,(e.selected=t)?n._trigger("selecting",i,{selecting:e.element}):n._trigger("unselecting",i,{unselecting:e.element}),!1):void 0}))},_mouseDrag:function(n){if(this.dragged=!0,!this.options.disabled){var t,r=this,s=this.options,o=this.opos[0],a=this.opos[1],l=n.pageX,u=n.pageY;return l<o&&(t=l,l=o,o=t),u<a&&(t=u,u=a,a=t),this.helper.css({left:o,top:a,width:l-o,height:u-a}),this.selectees.each(function(){var t=E.data(this,"selectable-item"),e=!1,i={};t&&t.element!==r.element[0]&&(i.left=t.left+r.elementPos.left,i.right=t.right+r.elementPos.left,i.top=t.top+r.elementPos.top,i.bottom=t.bottom+r.elementPos.top,"touch"===s.tolerance?e=!(i.left>l||o>i.right||i.top>u||a>i.bottom):"fit"===s.tolerance&&(e=i.left>o&&l>i.right&&i.top>a&&u>i.bottom),e?(t.selected&&(r._removeClass(t.$element,"ui-selected"),t.selected=!1),t.unselecting&&(r._removeClass(t.$element,"ui-unselecting"),t.unselecting=!1),t.selecting||(r._addClass(t.$element,"ui-selecting"),t.selecting=!0,r._trigger("selecting",n,{selecting:t.element}))):(t.selecting&&((n.metaKey||n.ctrlKey)&&t.startselected?(r._removeClass(t.$element,"ui-selecting"),t.selecting=!1,r._addClass(t.$element,"ui-selected"),t.selected=!0):(r._removeClass(t.$element,"ui-selecting"),t.selecting=!1,t.startselected&&(r._addClass(t.$element,"ui-unselecting"),t.unselecting=!0),r._trigger("unselecting",n,{unselecting:t.element}))),t.selected&&(n.metaKey||n.ctrlKey||t.startselected||(r._removeClass(t.$element,"ui-selected"),t.selected=!1,r._addClass(t.$element,"ui-unselecting"),t.unselecting=!0,r._trigger("unselecting",n,{unselecting:t.element})))))}),!1}},_mouseStop:function(e){var i=this;return this.dragged=!1,E(".ui-unselecting",this.element[0]).each(function(){var t=E.data(this,"selectable-item");i._removeClass(t.$element,"ui-unselecting"),t.unselecting=!1,t.startselected=!1,i._trigger("unselected",e,{unselected:t.element})}),E(".ui-selecting",this.element[0]).each(function(){var t=E.data(this,"selectable-item");i._removeClass(t.$element,"ui-selecting")._addClass(t.$element,"ui-selected"),t.selecting=!1,t.selected=!0,t.startselected=!0,i._trigger("selected",e,{selected:t.element})}),this._trigger("stop",e),this.helper.remove(),!1}}),E.widget("ui.selectmenu",[E.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"},width:!1,change:null,close:null,focus:null,open:null,select:null},_create:function(){var t=this.element.uniqueId().attr("id");this.ids={element:t,button:t+"-button",menu:t+"-menu"},this._drawButton(),this._drawMenu(),this._bindFormResetHandler(),this._rendered=!1,this.menuItems=E()},_drawButton:function(){var t,e=this,i=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=E("<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"),t=E("<span>").appendTo(this.button),this._addClass(t,"ui-selectmenu-icon","ui-icon "+this.options.icons.button),this.buttonItem=this._renderButtonItem(i).appendTo(this.button),!1!==this.options.width&&this._resizeButton(),this._on(this.button,this._buttonEvents),this.button.one("focusin",function(){e._rendered||e._refreshMenu()})},_drawMenu:function(){var n=this;this.menu=E("<ul>",{"aria-hidden":"true","aria-labelledby":this.ids.button,id:this.ids.menu}),this.menuWrap=E("<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,e){t.preventDefault(),n._setSelection(),n._select(e.item.data("ui-selectmenu-item"),t)},focus:function(t,e){var i=e.item.data("ui-selectmenu-item");null!=n.focusIndex&&i.index!==n.focusIndex&&(n._trigger("focus",t,{item:i}),n.isOpen||n._select(i,t)),n.focusIndex=i.index,n.button.attr("aria-activedescendant",n.menuItems.eq(i.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(E.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(t){var e=E("<span>");return this._setText(e,t.label),this._addClass(e,"ui-selectmenu-text"),e},_renderMenu:function(n,t){var r=this,s="";E.each(t,function(t,e){var i;e.optgroup!==s&&(i=E("<li>",{text:e.optgroup}),r._addClass(i,"ui-selectmenu-optgroup","ui-menu-divider"+(e.element.parent("optgroup").prop("disabled")?" ui-state-disabled":"")),i.appendTo(n),s=e.optgroup),r._renderItemData(n,e)})},_renderItemData:function(t,e){return this._renderItem(t,e).data("ui-selectmenu-item",e)},_renderItem:function(t,e){var i=E("<li>"),n=E("<div>",{title:e.element.attr("title")});return e.disabled&&this._addClass(i,null,"ui-state-disabled"),this._setText(n,e.label),i.append(n).appendTo(t)},_setText:function(t,e){e?t.text(e):t.html("&#160;")},_move:function(t,e){var i,n,r=".ui-menu-item";this.isOpen?i=this.menuItems.eq(this.focusIndex).parent("li"):(i=this.menuItems.eq(this.element[0].selectedIndex).parent("li"),r+=":not(.ui-state-disabled)"),(n="first"===t||"last"===t?i["first"===t?"prevAll":"nextAll"](r).eq(-1):i[t+"All"](r).eq(0)).length&&this.menuInstance.focus(e,n)},_getSelectedItem:function(){return this.menuItems.eq(this.element[0].selectedIndex).parent("li")}
vendor: 4,340 bytes, line 1
1,_toggle:function(t){this[this.isOpen?"close":"open"](t)},_setSelection:function(){var t;this.range&&(window.getSelection?((t=window.getSelection()).removeAllRanges(),t.addRange(this.range)):this.range.select(),this.button.focus())},_documentClick:{mousedown:function(t){this.isOpen&&(E(t.target).closest(".ui-selectmenu-menu, #"+E.ui.escapeSelector(this.ids.button)).length||this.close(t))}},_buttonEvents:{mousedown:function(){var t;window.getSelection?(t=window.getSelection()).rangeCount&&(this.range=t.getRangeAt(0)):this.range=document.selection.createRange()},click:function(t){this._setSelection(),this._toggle(t)},keydown:function(t){var e=!0;switch(t.keyCode){case E.ui.keyCode.TAB:case E.ui.keyCode.ESCAPE:this.close(t),e=!1;break;case E.ui.keyCode.ENTER:this.isOpen&&this._selectFocusedItem(t);break;case E.ui.keyCode.UP:t.altKey?this._toggle(t):this._move("prev",t);break;case E.ui.keyCode.DOWN:t.altKey?this._toggle(t):this._move("next",t);break;case E.ui.keyCode.SPACE:this.isOpen?this._selectFocusedItem(t):this._toggle(t);break;case E.ui.keyCode.LEFT:this._move("prev",t);break;case E.ui.keyCode.RIGHT:this._move("next",t);break;case E.ui.keyCode.HOME:case E.ui.keyCode.PAGE_UP:this._move("first",t);break;case E.ui.keyCode.END:case E.ui.keyCode.PAGE_DOWN:this._move("last",t);break;default:this.menu.trigger(t),e=!1}e&&t.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 t=this.options.appendTo;return t&&(t=t.jquery||t.nodeType?E(t):this.document.find(t).eq(0)),t&&t[0]||(t=this.element.closest(".ui-front, dialog")),t.length||(t=this.document[0].body),t},_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!1===t?void this.button.css("width",""):(null===t&&(t=this.element.show().outerWidth(),this.element.hide()),void this.button.outerWidth(t))},_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(t){var i=this,n=[];t.each(function(t,e){n.push(i._parseOption(E(e),t))}),this.items=n},_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)}}]),E.widget("ui.slider",E.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}
vendor: 4,699 bytes, line 1
1,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},_refresh:function(){this._createRange(),this._createHandles(),this._setupEvents(),this._refreshValue()},_createHandles:function(){var t,e,i=this.options,n=this.element.find(".ui-slider-handle"),r=[];for(e=i.values&&i.values.length||1,n.length>e&&(n.slice(e).remove(),n=n.slice(0,e)),t=n.length;t<e;t++)r.push("<span tabindex='0'></span>");this.handles=n.add(E(r.join("")).appendTo(this.element)),this._addClass(this.handles,"ui-slider-handle","ui-state-default"),this.handle=this.handles.eq(0),this.handles.each(function(t){E(this).data("ui-slider-handle-index",t).attr("tabIndex",0)})},_createRange:function(){var t=this.options;t.range?(!0===t.range&&(t.values?t.values.length&&2!==t.values.length?t.values=[t.values[0],t.values[0]]:E.isArray(t.values)&&(t.values=t.values.slice(0)):t.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=E("<div>").appendTo(this.element),this._addClass(this.range,"ui-slider-range")),("min"===t.range||"max"===t.range)&&this._addClass(this.range,"ui-slider-range-"+t.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(t){var e,i,n,r,s,o,a,l=this,u=this.options;return!u.disabled&&(this.elementSize={width:this.element.outerWidth(),height:this.element.outerHeight()},this.elementOffset=this.element.offset(),e={x:t.pageX,y:t.pageY},i=this._normValueFromMouse(e),n=this._valueMax()-this._valueMin()+1,this.handles.each(function(t){var e=Math.abs(i-l.values(t));(e<n||n===e&&(t===l._lastChangedValue||l.values(t)===u.min))&&(n=e,r=E(this),s=t)}),!1!==this._start(t,s)&&(this._mouseSliding=!0,this._handleIndex=s,this._addClass(r,null,"ui-state-active"),r.trigger("focus"),o=r.offset(),a=!E(t.target).parents().addBack().is(".ui-slider-handle"),this._clickOffset=a?{left:0,top:0}:{left:t.pageX-o.left-r.width()/2,top:t.pageY-o.top-r.height()/2-(parseInt(r.css("borderTopWidth"),10)||0)-(parseInt(r.css("borderBottomWidth"),10)||0)+(parseInt(r.css("marginTop"),10)||0)},this.handles.hasClass("ui-state-hover")||this._slide(t,s,i),this._animateOff=!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},_detectOrientation:function(){this.orientation="vertical"===this.options.orientation?"vertical":"horizontal"},_normValueFromMouse:function(t){var e,i,n,r;return 1<(i=("horizontal"===this.orientation?(e=this.elementSize.width,t.x-this.elementOffset.left-(this._clickOffset?this._clickOffset.left:0)):(e=this.elementSize.height,t.y-this.elementOffset.top-(this._clickOffset?this._clickOffset.top:0)))/e)&&(i=1),i<0&&(i=0),"vertical"===this.orientation&&(i=1-i),n=this._valueMax()-this._valueMin(),r=this._valueMin()+i*n,this._trimAlignValue(r)},_uiHash:function(t,e,i){var n={handle:this.handles[t],handleIndex:t,value:void 0!==e?e:this.value()};return this._hasMultipleValues()&&(n.value=void 0!==e?e:this.values(t),n.values=i||this.values()),n},_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 n,r=this.value(),s=this.values();this._hasMultipleValues()&&(n=this.values(e?0:1),r=this.values(e),2===this.options.values.length&&!0===this.options.range&&(i=0===e?Math.min(n,i):Math.max(n,i)),s[e]=i),i!==r&&(!1!==this._trigger("slide",t,this._uiHash(e,i,s))&&(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(),void this._change(null,0)):this._value(
vendor: 4,824 bytes, line 1
1)},values:function(t,e){var i,n,r;if(1<arguments.length)return this.options.values[t]=this._trimAlignValue(e),this._refreshValue(),void this._change(null,t);if(!arguments.length)return this._values();if(!E.isArray(t))return this._hasMultipleValues()?this._values(t):this.value();for(i=this.options.values,n=t,r=0;i.length>r;r+=1)i[r]=this._trimAlignValue(n[r]),this._change(null,r);this._refreshValue()},_setOption:function(t,e){var i,n=0;switch("range"===t&&!0===this.options.range&&("min"===e?(this.options.value=this._values(0),this.options.values=null):"max"===e&&(this.options.value=this._values(this.options.values.length-1),this.options.values=null)),E.isArray(this.options.values)&&(n=this.options.values.length),this._super(t,e),t){case"orientation":this._detectOrientation(),this._removeClass("ui-slider-horizontal ui-slider-vertical")._addClass("ui-slider-"+this.orientation),this._refreshValue(),this.options.range&&this._refreshRange(e),this.handles.css("horizontal"===e?"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(),i=n-1;0<=i;i--)this._change(null,i);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 this._trimAlignValue(t)},_values:function(t){var e,i,n;if(arguments.length)return e=this.options.values[t],this._trimAlignValue(e);if(this._hasMultipleValues()){for(i=this.options.values.slice(),n=0;i.length>n;n+=1)i[n]=this._trimAlignValue(i[n]);return i}return[]},_trimAlignValue:function(t){if(this._valueMin()>=t)return this._valueMin();if(t>=this._valueMax())return this._valueMax();var e=0<this.options.step?this.options.step:1,i=(t-this._valueMin())%e,n=t-i;return 2*Math.abs(i)>=e&&(n+=0<i?e:-e),parseFloat(n.toFixed(5))},_calculateNewMax:function(){var t=this.options.max,e=this._valueMin(),i=this.options.step;(t=Math.round((t-e)/i)*i+e)>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,t,n,r,s=this.options.range,o=this.options,a=this,l=!this._animateOff&&o.animate,u={};this._hasMultipleValues()?this.handles.each(function(t){i=(a.values(t)-a._valueMin())/(a._valueMax()-a._valueMin())*100,u["horizontal"===a.orientation?"left":"bottom"]=i+"%",E(this).stop(1,1)[l?"animate":"css"](u,o.animate),!0===a.options.range&&("horizontal"===a.orientation?(0===t&&a.range.stop(1,1)[l?"animate":"css"]({left:i+"%"},o.animate),1===t&&a.range[l?"animate":"css"]({width:i-e+"%"},{queue:!1,duration:o.animate})):(0===t&&a.range.stop(1,1)[l?"animate":"css"]({bottom:i+"%"},o.animate),1===t&&a.range[l?"animate":"css"]({height:i-e+"%"},{queue:!1,duration:o.animate}))),e=i}):(t=this.value(),n=this._valueMin(),r=this._valueMax(),i=r!==n?(t-n)/(r-n)*100:0,u["horizontal"===this.orientation?"left":"bottom"]=i+"%",this.handle.stop(1,1)[l?"animate":"css"](u,o.animate),"min"===s&&"horizontal"===this.orientation&&this.range.stop(1,1)[l?"animate":"css"]({width:i+"%"},o.animate),"max"===s&&"horizontal"===this.orientation&&this.range.stop(1,1)[l?"animate":"css"]({width:100-i+"%"},o.animate),"min"===s&&"vertical"===this.orientation&&this.range.stop(1,1)[l?"animate":"css"]({height:i+"%"},o.animate),"max"===s&&"vertical"===this.orientation&&this.range.stop(1,1)[l?"animate":"css"]({height:100-i+"%"},o.animate))},_handleEvents:{keydown:function(t){var e,i,n,r=E(t.target).data("ui-slider-handle-index");switch(t.keyCode){case E.ui.keyCode.HOME:case E.ui.keyCode.END:case E.ui.keyCode.PAGE_UP:case E.ui.keyCode.PAGE_DOWN:case E.ui.keyCode.UP:case E.ui.keyCode.RIGHT:case E.ui.keyCode.DOWN:case E.ui.keyCode.LEFT:if(t.preventDefault(),!this._keySliding&&(this._keySliding=!0,this._addClass(E(t.target),null,"ui-state-active"),!1===this._start(t,r)))return}switch(n=this.options.step,e=i=this._hasMultipleValues()?this.values(r):this.value(),t.keyCode){case E.ui.keyCode.HOME:i=this._valueMin();break;case E.ui.keyCode.END:i=this._valueMax();break;case E.ui.keyCode.PAGE_UP:i=this._trimAlignValue(e+(this._valueMax()-this._valueMin())/this.numPages);break;
vendor: 7,055 bytes, line 1
1case E.ui.keyCode.PAGE_DOWN:i=this._trimAlignValue(e-(this._valueMax()-this._valueMin())/this.numPages);break;case E.ui.keyCode.UP:case E.ui.keyCode.RIGHT:if(e===this._valueMax())return;i=this._trimAlignValue(e+n);break;case E.ui.keyCode.DOWN:case E.ui.keyCode.LEFT:if(e===this._valueMin())return;i=this._trimAlignValue(e-n)}this._slide(t,r,i)},keyup:function(t){var e=E(t.target).data("ui-slider-handle-index");this._keySliding&&(this._keySliding=!1,this._stop(t,e),this._change(t,e),this._removeClass(E(t.target),null,"ui-state-active"))}}}),E.widget("ui.sortable",E.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},_isOverAxis:function(t,e,i){return e<=t&&t<e+i},_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 t=this;this._removeClass(this.element.find(".ui-sortable-handle"),"ui-sortable-handle"),E.each(this.items,function(){t._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;0<=t;t--)this.items[t].item.removeData(this.widgetName+"-item");return this},_mouseCapture:function(t,e){var i=null,n=!1,r=this;return!this.reverting&&(!this.options.disabled&&"static"!==this.options.type&&(this._refreshItems(t),E(t.target).parents().each(function(){return E.data(this,r.widgetName+"-item")===r?(i=E(this),!1):void 0}),E.data(t.target,r.widgetName+"-item")===r&&(i=E(t.target)),!!i&&(!(this.options.handle&&!e&&(E(this.options.handle,i).find("*").addBack().each(function(){this===t.target&&(n=!0)}),!n))&&(this.currentItem=i,this._removeCurrentsFromItems(),!0))))},_mouseStart:function(t,e,i){var n,r,s=this.options;if((this.currentContainer=this).refreshPositions(),this.helper=this._createHelper(t),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},E.extend(this.offset,{click:{left:t.pageX-this.offset.left,top:t.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(t),this.originalPageX=t.pageX,this.originalPageY=t.pageY,s.cursorAt&&this._adjustOffsetFromHelper(s.cursorAt),this.domPosition={prev:this.currentItem.prev()[0],parent:this.currentItem.parent()[0]},this.helper[0]!==this.currentItem[0]&&this.currentItem.hide(),this._createPlaceholder(),s.containment&&this._setContainment(),s.cursor&&"auto"!==s.cursor&&(r=this.document.find("body"),this.storedCursor=r.css("cursor"),r.css("cursor",s.cursor),this.storedStylesheet=E("<style>*{ cursor: "+s.cursor+" !important; }</style>").appendTo(r)),s.opacity&&(this.helper.css("opacity")&&(this._storedOpacity=this.helper.css("opacity")),this.helper.css("opacity",s.opacity)),s.zIndex&&(this.helper.css("zIndex")&&(this._storedZIndex=this.helper.css("zIndex")),this.helper.css("zIndex",s.zIndex)),this.scrollParent[0]!==this.document[0]&&"HTML"!==this.scrollParent[0].tagName&&(this.overflowOffset=this.scrollParent.offset()),this._trigger("start",t,this._uiHash()),this._preserveHelperProportions||this._cacheHelperProportions(),!i)for(n=this.containers.length-1;0<=n;n--)this.containers[n]._trigger("activate",t,this._uiHash(this));return E.ui.ddmanager&&(E.ui.ddmanager.current=this),E.ui.ddmanager&&!s.dropBehaviour&&E.ui.ddmanager.prepareOffsets(this,t),this.dragging=!0,this._addClass(this.helper,"ui-sortable-helper"),this._mouseDrag(t),!0},_mouseDrag:function(t){var e,i,n,r,s=this.options,o=!1;for(this.position=this._generatePosition(t),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-t.pageY<s.scrollSensitivity?this.scrollParent[0].scrollTop=o=this.scrollParent[0].scrollTop+s.scrollSpeed:t.pageY-this.overflowOffset.top<s.scrollSensitivity&&(this.scrollParent[0].scrollTop=o=this.scrollParent[0].scrollTop-s.scrollSpeed),this.overflowOffset.left+this.scrollParent[0].offsetWidth-t.pageX<s.scrollSensitivity?this.scrollParent[0].scrollLeft=o=this.scrollParent[0].scrollLeft+s.scrollSpeed:t.pageX-this.overflowOffset.left<s.scrollSensitivity&&(this.scrollParent[0].scrollLeft=o=this.scrollParent[0].scrollLeft-s.scrollSpeed)):(t.pageY-this.document.scrollTop()<s.scrollSensitivity?o=this.document.scrollTop(this.document.scrollTop()-s.scrollSpeed):this.window.height()-(t.pageY-this.document.scrollTop())<s.scrollSensitivity&&(o=this.document.scrollTop(this.document.scrollTop()+s.scrollSpeed)),t.pageX-this.document.scrollLeft()<s.scrollSensitivity?o=this.document.scrollLeft(this.document.scrollLeft()-s.scrollSpeed):this.window.width()-(t.pageX-this.document.scrollLeft())<s.scrollSensitivity&&(o=this.document.scrollLeft(this.document.scrollLeft()+s.scrollSpeed))),!1!==o&&E.ui.ddmanager&&!s.dropBehaviour&&E.ui.ddmanager.prepareOffsets(this,t)),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"),e=this.items.length-1;0<=e;e--)if(n=(i=this.items[e]).item[0],(r=this._intersectsWithPointer(i))&&i.instance===this.currentContainer&&n!==this.currentItem[0]&&this.placeholder[1===r?"next":"prev"]()[0]!==n&&!E.contains(this.placeholder[0],n)&&("semi-dynamic"!==this.options.type||!E.contains(this.element[0],n))){if(this.direction=1===r?"down":"up","pointer"!==this.options.tolerance&&!this._intersectsWithSides(i))break;this._rearrange(t,i),this._trigger("change",t,this._uiHash());break}return this._contactContainers(t),E.ui.ddmanager&&E.ui.ddmanager.drag(this,t),this._trigger("sort",t,this._uiHash()),this.lastPositionAbs=this.positionAbs,!1},_mouseStop:function(t,e){if(t){if(E.ui.ddmanager&&!this.options.dropBehaviour&&E.ui.ddmanager.drop(this,t),this.options.revert){var i=this,n=this.placeholder.offset(),r=this.options.axis,s={};
1r&&"x"!==r||(s.left=n.left-this.offset.parent.left-this.margins.left+(this.offsetParent[0]===this.document[0].body?0:this.offsetParent[0].scrollLeft)),r&&"y"!==r||(s.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,E(this.helper).animate(s,parseInt(this.options.revert,10)||500,function(){i._clear(t)})}else this._clear(t,e);return!1}},cancel:function(){if(this.dragging){this._mouseUp(new E.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 t=this.containers.length-1;0<=t;t--)this.containers[t]._trigger("deactivate",null,this._uiHash(this)),this.containers[t].containerCache.over&&(this.containers[t]._trigger("out",null,this._uiHash(this)),this.containers[t].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(),E.extend(this,{helper:null,dragging:!1,reverting:!1,_noFinalSort:null}),this.domPosition.prev?E(this.domPosition.prev).after(this.currentItem):E(this.domPosition.parent).prepend(this.currentItem)),this},serialize:function(e){var t=this._getItemsAsjQuery(e&&e.connected),i=[];return e=e||{},E(t).each(function(){var t=(E(e.item||this).attr(e.attribute||"id")||"").match(e.expression||/(.+)[\-=_](.+)/);t&&i.push((e.key||t[1]+"[]")+"="+(e.key&&e.expression?t[1]:t[2]))}),!i.length&&e.key&&i.push(e.key+"="),i.join("&")},toArray:function(t){var e=this._getItemsAsjQuery(t&&t.connected),i=[];return t=t||{},e.each(function(){i.push(E(t.item||this).attr(t.attribute||"id")||"")}),i},_intersectsWith:function(t){var e=this.positionAbs.left,i=e+this.helperProportions.width,n=this.positionAbs.top,r=n+this.helperProportions.height,s=t.left,o=s+t.width,a=t.top,l=a+t.height,u=this.offset.click.top,c=this.offset.click.left,h="x"===this.options.axis||a<n+u&&n+u<l,d="y"===this.options.axis||s<e+c&&e+c<o,p=h&&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>s&&o>i-this.helperProportions.width/2&&n+this.helperProportions.height/2>a&&l>r-this.helperProportions.height/2},_intersectsWithPointer:function(t){var e,i,n="x"===this.options.axis||this._isOverAxis(this.positionAbs.top+this.offset.click.top,t.top,t.height),r="y"===this.options.axis||this._isOverAxis(this.positionAbs.left+this.offset.click.left,t.left,t.width);return!!(n&&r)&&(e=this._getDragVerticalDirection(),i=this._getDragHorizontalDirection(),this.floating?"right"===i||"down"===e?2:1:e&&("down"===e?2: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),n=this._getDragVerticalDirection(),r=this._getDragHorizontalDirection();return this.floating&&r?"right"===r&&i||"left"===r&&!i:n&&("down"===n&&e||"up"===n&&!e)},_getDragVerticalDirection:function(){var t=this.positionAbs.top-this.lastPositionAbs.top;return 0!==t&&(0<t?"down":"up")},_getDragHorizontalDirection:function(){var t=this.positionAbs.left-this.lastPositionAbs.left;return 0!==t&&(0<t?"right":"left")},refresh:function(t){return this._refreshItems(t),this._setHandleClassName(),this.refreshPositions(),this},_connectWith:function(){var t=this.options;return t.connectWith.constructor===String?[t.connectWith]:t.connectWith},_getItemsAsjQuery:function(t){function e(){o.push(this)}var i,n,r,s,o=[],a=[],l=this._connectWith();if(l&&t)for(i=l.length-1;0<=i;i--)for(n=(r=E(l[i],this.document[0])).length-1;0<=n;n--)(s=E.data(r[n],this.widgetFullName))&&s!==this&&!s.options.disabled&&a.push([E.isFunction(s.options.items)?s.options.items.call(s.element):E(s.options.items,s.element).not(".ui-sortable-helper").not(".ui-sortable-placeholder"),s]);for(a.push([E.isFunction(this.options.items)?this.options.items.call(this.element,null,{options:this.options,item:this.currentItem}):E(this.options.items,this.element).not(".ui-sortable-helper").not(".ui-sortable-placeholder"),this]),i=a.length-1;0<=i;i--)a[i][0].each(e);return E(o)},_removeCurrentsFromItems:function(){var i=this.currentItem.find(":data("+this.widgetName+"-item)");this.items=E.grep(this.items,function(t){for(var e=0;i.length>e;e++)if(i[e]===t.item[0])return!1;return!0})},_refreshItems:function(t){this.items=[],this.containers=[this];var e,i,n,r,s,o,a,l,u=this.items,c=[[E.isFunction(this.options.items)?this.options.items.call(this.element[0],t,{item:this.currentItem}):E(this.options.items,this.element),this]],h=this._connectWith();if(h&&this.ready)for(e=h.length-1;0<=e;e--)for(i=(n=E(h[e],this.document[0])).length-1;0<=i;i--)(r=E.data(n[i],this.widgetFullName))&&r!==this&&!r.options.disabled&&(c.push([E.isFunction(r.options.items)?r.options.items.call(r.element[0],t,{item:this.currentItem}):E(r.options.items,r.element),r]),this.containers.push(r));for(e=c.length-1;0<=e;e--)for(s=c[e][1],i=0,l=(o=c[e][0]).length;i<l;i++)(a=E(o[i])).data(this.widgetName+"-item",s),u.push({item:a,instance:s,width:0,height:0,left:0,top:0})},refreshPositions:function(t){var e,i,n,r;for(this.floating=!!this.items.length&&("x"===this.options.axis||this._isFloating(this.items[0].item)),this.offsetParent&&this.helper&&(this.offset.parent=this._getParentOffset()),e=this.items.length-1;0<=e;e--)(i=this.items[e]).instance!==this.currentContainer&&this.currentContainer&&i.item[0]!==this.currentItem[0]||(n=this.options.toleranceElement?E(this.options.toleranceElement,i.item):i.item,t||(i.width=n.outerWidth(),i.height=n.outerHeight()),r=n.offset(),i.left=r.left,i.top=r.top);
vendor: 1,142 bytes, line 1
1if(this.options.custom&&this.options.custom.refreshContainers)this.options.custom.refreshContainers.call(this);else for(e=this.containers.length-1;0<=e;e--)r=this.containers[e].element.offset(),this.containers[e].containerCache.left=r.left,this.containers[e].containerCache.top=r.top,this.containers[e].containerCache.width=this.containers[e].element.outerWidth(),this.containers[e].containerCache.height=this.containers[e].element.outerHeight();return this},_createPlaceholder:function(i){var n,r=(i=i||this).options;r.placeholder&&r.placeholder.constructor!==String||(n=r.placeholder,r.placeholder={element:function(){var t=i.currentItem[0].nodeName.toLowerCase(),e=E("<"+t+">",i.document[0]);return i._addClass(e,"ui-sortable-placeholder",n||i.currentItem[0].className)._removeClass(e,"ui-sortable-helper"),"tbody"===t?i._createTrPlaceholder(i.currentItem.find("tr").eq(0),E("<tr>",i.document[0]).appendTo(e)):"tr"===t?i._createTrPlaceholder(i.currentItem,e):"img"===t&&e.attr("src",i.currentItem.attr("src")),n||e.css("visibility","hidden"),e},update:function(t,e){(!n||r.forcePlaceholderSize)&&(e.height()||e.height(i.currentItem.innerHe
vendor: 11,832 bytes, line 1
1ight()-parseInt(i.currentItem.css("paddingTop")||0,10)-parseInt(i.currentItem.css("paddingBottom")||0,10)),e.width()||e.width(i.currentItem.innerWidth()-parseInt(i.currentItem.css("paddingLeft")||0,10)-parseInt(i.currentItem.css("paddingRight")||0,10)))}}),i.placeholder=E(r.placeholder.element.call(i.element,i.currentItem)),i.currentItem.after(i.placeholder),r.placeholder.update(i,i.placeholder)},_createTrPlaceholder:function(t,e){var i=this;t.children().each(function(){E("<td>&#160;</td>",i.document[0]).attr("colspan",E(this).attr("colspan")||1).appendTo(e)})},_contactContainers:function(t){var e,i,n,r,s,o,a,l,u,c,h=null,d=null;for(e=this.containers.length-1;0<=e;e--)if(!E.contains(this.currentItem[0],this.containers[e].element[0]))if(this._intersectsWith(this.containers[e].containerCache)){if(h&&E.contains(this.containers[e].element[0],h.element[0]))continue;h=this.containers[e],d=e}else this.containers[e].containerCache.over&&(this.containers[e]._trigger("out",t,this._uiHash(this)),this.containers[e].containerCache.over=0);if(h)if(1===this.containers.length)this.containers[d].containerCache.over||(this.containers[d]._trigger("over",t,this._uiHash(this)),this.containers[d].containerCache.over=1);else{for(n=1e4,r=null,s=(u=h.floating||this._isFloating(this.currentItem))?"left":"top",o=u?"width":"height",c=u?"pageX":"pageY",i=this.items.length-1;0<=i;i--)E.contains(this.containers[d].element[0],this.items[i].item[0])&&this.items[i].item[0]!==this.currentItem[0]&&(a=this.items[i].item.offset()[s],l=!1,t[c]-a>this.items[i][o]/2&&(l=!0),n>Math.abs(t[c]-a)&&(n=Math.abs(t[c]-a),r=this.items[i],this.direction=l?"up":"down"));if(!r&&!this.options.dropOnEmpty)return;if(this.currentContainer===this.containers[d])return void(this.currentContainer.containerCache.over||(this.containers[d]._trigger("over",t,this._uiHash()),this.currentContainer.containerCache.over=1));r?this._rearrange(t,r,null,!0):this._rearrange(t,null,this.containers[d].element,!0),this._trigger("change",t,this._uiHash()),this.containers[d]._trigger("change",t,this._uiHash(this)),this.currentContainer=this.containers[d],this.options.placeholder.update(this.currentContainer,this.placeholder),this.containers[d]._trigger("over",t,this._uiHash(this)),this.containers[d].containerCache.over=1}},_createHelper:function(t){var e=this.options,i=E.isFunction(e.helper)?E(e.helper.apply(this.element[0],[t,this.currentItem])):"clone"===e.helper?this.currentItem.clone():this.currentItem;return i.parents("body").length||E("parent"!==e.appendTo?e.appendTo:this.currentItem[0].parentNode)[0].appendChild(i[0]),i[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")}),(!i[0].style.width||e.forceHelperSize)&&i.width(this.currentItem.width()),(!i[0].style.height||e.forceHelperSize)&&i.height(this.currentItem.height()),i},_adjustOffsetFromHelper:function(t){"string"==typeof t&&(t=t.split(" ")),E.isArray(t)&&(t={left:+t[0],top:+t[1]||0}),"left"in t&&(this.offset.click.left=t.left+this.margins.left),"right"in t&&(this.offset.click.left=this.helperProportions.width-t.right+this.margins.left),"top"in t&&(this.offset.click.top=t.top+this.margins.top),"bottom"in t&&(this.offset.click.top=this.helperProportions.height-t.bottom+this.margins.top)},_getParentOffset:function(){this.offsetParent=this.helper.offsetParent();var t=this.offsetParent.offset();return"absolute"===this.cssPosition&&this.scrollParent[0]!==this.document[0]&&E.contains(this.scrollParent[0],this.offsetParent[0])&&(t.left+=this.scrollParent.scrollLeft(),t.top+=this.scrollParent.scrollTop()),(this.offsetParent[0]===this.document[0].body||this.offsetParent[0].tagName&&"html"===this.offsetParent[0].tagName.toLowerCase()&&E.ui.ie)&&(t={top:0,left:0}),{top:t.top+(parseInt(this.offsetParent.css("borderTopWidth"),10)||0),left:t.left+(parseInt(this.offsetParent.css("borderLeftWidth"),10)||0)}},_getRelativeOffset:function(){if("relative"!==this.cssPosition)return{top:0,left:0};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()}},_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 t,e,i,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)||(t=E(n.containment)[0],e=E(n.containment).offset(),i="hidden"!==E(t).css("overflow"),this.containment=[e.left+(parseInt(E(t).css("borderLeftWidth"),10)||0)+(parseInt(E(t).css("paddingLeft"),10)||0)-this.margins.left,e.top+(parseInt(E(t).css("borderTopWidth"),10)||0)+(parseInt(E(t).css("paddingTop"),10)||0)-this.margins.top,e.left+(i?Math.max(t.scrollWidth,t.offsetWidth):t.offsetWidth)-(parseInt(E(t).css("borderLeftWidth"),10)||0)-(parseInt(E(t).css("paddingRight"),10)||0)-this.helperProportions.width-this.margins.left,e.top+(i?Math.max(t.scrollHeight,t.offsetHeight):t.offsetHeight)-(parseInt(E(t).css("borderTopWidth"),10)||0)-(parseInt(E(t).css("paddingBottom"),10)||0)-this.helperProportions.height-this.margins.top])},_convertPositionTo:function(t,e){e||(e=this.position);var i="absolute"===t?1:-1,n="absolute"!==this.cssPosition||this.scrollParent[0]!==this.document[0]&&E.contains(this.scrollParent[0],this.offsetParent[0])?this.scrollParent:this.offsetParent,r=/(html|body)/i.test(n[0].tagName);return{top:e.top+this.offset.relative.top*i+this.offset.parent.top*i-("fixed"===this.cssPosition?-this.scrollParent.scrollTop():r?0:n.scrollTop())*i,left:e.left+this.offset.relative.left*i+this.offset.parent.left*i-("fixed"===this.cssPosition?-this.scrollParent.scrollLeft():r?0:n.scrollLeft())*i}},_generatePosition:function(t){var e,i,n=this.options,r=t.pageX,s=t.pageY,o="absolute"!==this.cssPosition||this.scrollParent[0]!==this.document[0]&&E.contains(this.scrollParent[0],this.offsetParent[0])?this.scrollParent:this.offsetParent,a=/(html|body)/i.test(o[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&&(t.pageX-this.offset.click.left<this.containment[0]&&(r=this.containment[0]+this.offset.click.left),t.pageY-this.offset.click.top<this.containment[1]&&(s=this.containment[1]+this.offset.click.top),t.pageX-this.offset.click.left>this.containment[2]&&(r=this.containment[2]+this.offset.click.left),t.pageY-this.offset.click.top>this.containment[3]&&(s=this.containment[3]+this.offset.click.top)),n.grid&&(e=this.originalPageY+Math.round((s-this.originalPageY)/n.grid[1])*n.grid[1],s=this.containment?e-this.offset.click.top>=this.containment[1]&&e-this.offset.click.top<=this.containment[3]?e:e-this.offset.click.top>=this.containment[1]?e-n.grid[1]:e+n.grid[1]:e,i=this.originalPageX+Math.round((r-this.originalPageX)/n.grid[0])*n.grid[0],r=this.containment?i-this.offset.click.left>=this.containment[0]&&i-this.offset.click.left<=this.containment[2]?i:i-this.offset.click.left>=this.containment[0]?i-n.grid[0]:i+n.grid[0]:i)),{top:s-this.offset.click.top-this.offset.relative.top-this.offset.parent.top+("fixed"===this.cssPosition?-this.scrollParent.scrollTop():a?0:o.scrollTop()),left:r-this.offset.click.left-this.offset.relative.left-this.offset.parent.left+("fixed"===this.cssPosition?-this.scrollParent.scrollLeft():a?0:o.scrollLeft())}},_rearrange:function(t,e,i,n){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 r=this.counter;this._delay(function(){r===this.counter&&this.refreshPositions(!n)})},_clear:function(t,e){function i(e,i,n){return function(t){n._trigger(e,t,i._uiHash(i))}}this.reverting=!1;var n,r=[];if(!this._noFinalSort&&this.currentItem.parent().length&&this.placeholder.before(this.currentItem),this._noFinalSort=null,this.helper[0]===this.currentItem[0]){for(n in this._storedCSS)("auto"===this._storedCSS[n]||"static"===this._storedCSS[n])&&(this._storedCSS[n]="");this.currentItem.css(this._storedCSS),this._removeClass(this.currentItem,"ui-sortable-helper")}else this.currentItem.show();for(this.fromOutside&&!e&&r.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||r.push(function(t){this._trigger("update",t,this._uiHash())}),this!==this.currentContainer&&(e||(r.push(function(t){this._trigger("remove",t,this._uiHash())}),r.push(function(e){return function(t){e._trigger("receive",t,this._uiHash(this))}}.call(this,this.currentContainer)),r.push(function(e){return function(t){e._trigger("update",t,this._uiHash(this))}}.call(this,this.currentContainer)))),n=this.containers.length-1;0<=n;n--)e||r.push(i("deactivate",this,this.containers[n])),this.containers[n].containerCache.over&&(r.push(i("out",this,this.containers[n])),this.containers[n].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(n=0;r.length>n;n++)r[n].call(this,t);this._trigger("stop",t,this._uiHash())}return this.fromOutside=!1,!this.cancelHelperRemoval},_trigger:function(){!1===E.Widget.prototype._trigger.apply(this,arguments)&&this.cancel()},_uiHash:function(t){var e=t||this;return{helper:e.helper,placeholder:e.placeholder||E([]),position:e.position,originalPosition:e.originalPosition,offset:e.positionAbs,item:e.currentItem,sender:t?t.element:null}}}),E.widget("ui.spinner",{version:"1.12.1",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 n=this._super(),r=this.element;return E.each(["min","max","step"],function(t,e){var i=r.attr(e);null!=i&&i.length&&(n[e]=i)}),n}
1,_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?void delete this.cancelBlur:(this._stop(),this._refresh(),void(this.previous!==this.element.val()&&this._trigger("change",t)))},mousewheel:function(t,e){if(e){if(!this.spinning&&!this._start(t))return!1;this._spin((0<e?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(t){function e(){this.element[0]===E.ui.safeActiveElement(this.document[0])||(this.element.trigger("focus"),this.previous=i,this._delay(function(){this.previous=i}))}var i;i=this.element[0]===E.ui.safeActiveElement(this.document[0])?this.previous:this.element.val(),t.preventDefault(),e.call(this),this.cancelBlur=!0,this._delay(function(){delete this.cancelBlur,e.call(this)}),!1!==this._start(t)&&this._repeat(null,E(t.currentTarget).hasClass("ui-spinner-up")?1:-1,t)},"mouseup .ui-spinner-button":"_stop","mouseenter .ui-spinner-button":function(t){return E(t.currentTarget).hasClass("ui-state-active")?!1!==this._start(t)&&void this._repeat(null,E(t.currentTarget).hasClass("ui-spinner-up")?1:-1,t):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())&&0<this.uiSpinner.height()&&this.uiSpinner.height(this.uiSpinner.height())},_keydown:function(t){var e=this.options,i=E.ui.keyCode;switch(t.keyCode){case i.UP:return this._repeat(null,1,t),!0;case i.DOWN:return this._repeat(null,-1,t),!0;case i.PAGE_UP:return this._repeat(null,e.page,t),!0;case i.PAGE_DOWN:return this._repeat(null,-e.page,t),!0}return!1},_start:function(t){return!(!this.spinning&&!1===this._trigger("start",t))&&(this.counter||(this.counter=1),this.spinning=!0)},_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&&!1===this._trigger("spin",e,{value:i})||(this._value(i),this.counter++)},_increment:function(t){var e=this.options.incremental;return e?E.isFunction(e)?e(t):Math.floor(t*t*t/5e4-t*t/500+17*t/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,n=this.options;return i=t-(e=null!==n.min?n.min:0),t=e+(i=Math.round(i/n.step)*n.step),t=parseFloat(t.toFixed(this._precision())),null!==n.max&&t>n.max?n.max:null!==n.min&&n.min>t?n.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,n,r;return"culture"===t||"numberFormat"===t?(i=this._parse(this.element.val()),this.options[t]=e,void this.element.val(this._format(i))):(("max"===t||"min"===t||"step"===t)&&"string"==typeof e&&(e=this._parse(e)),"icons"===t&&(n=this.buttons.first().find(".ui-icon"),this._removeClass(n,null,this.options.icons.up),this._addClass(n,null,e.up),r=this.buttons.last().find(".ui-icon"),this._removeClass(r,null,this.options.icons.down),this._addClass(r,null,e.down)),void this._super(t,e))},_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:e(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&&t===this._adjustValue(t)},_value:function(t,e){var i;""!==t&&(null!==(i=this._parse(t))&&(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:e(function(t){this._stepUp(t)}),_stepUp:function(t){this._start()&&(this._spin((t||1)*this.options.step),this._stop())},stepDown:e(function(t){this._stepDown(t)}),_stepDown:function(t){this._start()&&(this._spin((t||1)*-this.options.step),this._stop())},pageUp:e(function(t){this._stepUp((t||1)*this.options.page)}),pageDown:e(function(t){this._stepDown((t||1)*this.options.page)}),value:function(t){return arguments.length?void e(this._value).call(this,t):this._parse(this.element.val())},widget:function(){return this.uiSpinner}}
1),!1!==E.uiBackCompat&&E.widget("ui.spinner",E.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>"}}),E.ui.spinner,E.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:(w=/#.*$/,function(t){var e,i;e=t.href.replace(w,""),i=location.href.replace(w,"");try{e=decodeURIComponent(e)}catch(t){}try{i=decodeURIComponent(i)}catch(t){}return 1<t.hash.length&&e===i}),_create:function(){var e=this,t=this.options;this.running=!1,this._addClass("ui-tabs","ui-widget ui-widget-content"),this._toggleClass("ui-tabs-collapsible",null,t.collapsible),this._processTabs(),t.active=this._initialActive(),E.isArray(t.disabled)&&(t.disabled=E.unique(t.disabled.concat(E.map(this.tabs.filter(".ui-state-disabled"),function(t){return e.tabs.index(t)}))).sort()),this.active=!1!==this.options.active&&this.anchors.length?this._findActive(t.active):E(),this._refresh(),this.active.length&&this.load(t.active)},_initialActive:function(){var i=this.options.active,t=this.options.collapsible,n=location.hash.substring(1);return null===i&&(n&&this.tabs.each(function(t,e){return E(e).attr("aria-controls")===n?(i=t,!1):void 0}),null===i&&(i=this.tabs.index(this.tabs.filter(".ui-tabs-active"))),(null===i||-1===i)&&(i=!!this.tabs.length&&0)),!1!==i&&(-1===(i=this.tabs.index(this.tabs.eq(i)))&&(i=!t&&0)),!t&&!1===i&&this.anchors.length&&(i=0),i},_getCreateEventData:function(){return{tab:this.active,panel:this.active.length?this._getPanelForTab(this.active):E()}},_tabKeydown:function(t){var e=E(E.ui.safeActiveElement(this.document[0])).closest("li"),i=this.tabs.index(e),n=!0;if(!this._handlePageNav(t)){switch(t.keyCode){case E.ui.keyCode.RIGHT:case E.ui.keyCode.DOWN:i++;break;case E.ui.keyCode.UP:case E.ui.keyCode.LEFT:n=!1,i--;break;case E.ui.keyCode.END:i=this.anchors.length-1;break;case E.ui.keyCode.HOME:i=0;break;case E.ui.keyCode.SPACE:return t.preventDefault(),clearTimeout(this.activating),void this._activate(i);case E.ui.keyCode.ENTER:return t.preventDefault(),clearTimeout(this.activating),void this._activate(i!==this.options.active&&i);default:return}t.preventDefault(),clearTimeout(this.activating),i=this._focusNextTab(i,n),t.ctrlKey||t.metaKey||(e.attr("aria-selected","false"),this.tabs.eq(i).attr("aria-selected","true"),this.activating=this._delay(function(){this.option("active",i)},this.delay))}},_panelKeydown:function(t){this._handlePageNav(t)||t.ctrlKey&&t.keyCode===E.ui.keyCode.UP&&(t.preventDefault(),this.active.trigger("focus"))},_handlePageNav:function(t){return t.altKey&&t.keyCode===E.ui.keyCode.PAGE_UP?(this._activate(this._focusNextTab(this.options.active-1,!1)),!0):t.altKey&&t.keyCode===E.ui.keyCode.PAGE_DOWN?(this._activate(this._focusNextTab(this.options.active+1,!0)),!0):void 0},_findNextTab:function(t,e){for(var i=this.tabs.length-1;-1!==E.inArray((i<t&&(t=0),t<0&&(t=i),t),this.options.disabled);)t=e?t+1:t-1;return t},_focusNextTab:function(t,e){return t=this._findNextTab(t,e),this.tabs.eq(t).trigger("focus"),t},_setOption:function(t,e){return"active"===t?void this._activate(e):(this._super(t,e),"collapsible"===t&&(this._toggleClass("ui-tabs-collapsible",null,e),e||!1!==this.options.active||this._activate(0)),"event"===t&&this._setupEvents(e),void("heightStyle"===t&&this._setupHeightStyle(e)))},_sanitizeSelector:function(t){return t?t.replace(/[!"$%&'()*+,.\/:;<=>?@\[\]\^`{|}~]/g,"\\$&"):""},refresh:function(){var t=this.options,e=this.tablist.children(":has(a[href])");t.disabled=E.map(e.filter(".ui-state-disabled"),function(t){return e.index(t)}),this._processTabs(),!1!==t.active&&this.anchors.length?this.active.length&&!E.contains(this.tablist[0],this.active[0])?this.tabs.length===t.disabled.length?(t.active=!1,this.active=E()):this._activate(this._findNextTab(Math.max(0,t.active-1),!1)):t.active=this.tabs.index(this.active):(t.active=!1,this.active=E()),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 l=this,t=this.tabs,e=this.anchors,i=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(t){E(this).is(".ui-state-disabled")&&t.preventDefault()}).on("focus"+this.eventNamespace,".ui-tabs-anchor",function(){E(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 E("a",this)[0]}).attr({role:"presentation",tabIndex:-1}),this._addClass(this.anchors,"ui-tabs-anchor"),this.panels=E(),this.anchors.each(function(t,e){var i,n,r,s=E(e).uniqueId().attr("id"),o=E(e).closest("li"),a=o.attr("aria-controls");l._isLocal(e)?(r=(i=e.hash).substring(1),n=l.element.find(l._sanitizeSelector(i))):(i="#"+(r=o.attr("aria-controls")||E({}).uniqueId()[0].id),(n=l.element.find(i)).length||(n=l._createPanel(r)).insertAfter(l.panels[t-1]||l.tablist),n.attr("aria-live","polite")),n.length&&(l.panels=l.panels.add(n)),a&&o.data("ui-tabs-aria-controls",a),o.attr({"aria-controls":r,"aria-labelledby":s}),n.attr("aria-labelledby",s)}),this.panels.attr("role","tabpanel"),this._addClass(this.panels,"ui-tabs-panel","ui-widget-content"),t&&(this._off(t.not(this.tabs)
vendor: 9,273 bytes, line 1
1),this._off(e.not(this.anchors)),this._off(i.not(this.panels)))},_getList:function(){return this.tablist||this.element.find("ol, ul").eq(0)},_createPanel:function(t){return E("<div>").attr("id",t).data("ui-tabs-destroy",!0)},_setOptionDisabled:function(t){var e,i,n;for(E.isArray(t)&&(t.length?t.length===this.anchors.length&&(t=!0):t=!1),n=0;i=this.tabs[n];n++)e=E(i),!0===t||-1!==E.inArray(n,t)?(e.attr("aria-disabled","true"),this._addClass(e,null,"ui-state-disabled")):(e.removeAttr("aria-disabled"),this._removeClass(e,null,"ui-state-disabled"));this.options.disabled=t,this._toggleClass(this.widget(),this.widgetFullName+"-disabled",null,!0===t)},_setupEvents:function(t){var i={};t&&E.each(t.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(t){var i,e=this.element.parent();"fill"===t?(i=e.height(),i-=this.element.outerHeight()-this.element.height(),this.element.siblings(":visible").each(function(){var t=E(this),e=t.css("position");"absolute"!==e&&"fixed"!==e&&(i-=t.outerHeight(!0))}),this.element.children().not(this.panels).each(function(){i-=E(this).outerHeight(!0)}),this.panels.each(function(){E(this).height(Math.max(0,i-E(this).innerHeight()+E(this).height()))}).css("overflow","auto")):"auto"===t&&(i=0,this.panels.each(function(){i=Math.max(i,E(this).height("").height())}).height(i))},_eventHandler:function(t){var e=this.options,i=this.active,n=E(t.currentTarget).closest("li"),r=n[0]===i[0],s=r&&e.collapsible,o=s?E():this._getPanelForTab(n),a=i.length?this._getPanelForTab(i):E(),l={oldTab:i,oldPanel:a,newTab:s?E():n,newPanel:o};t.preventDefault(),n.hasClass("ui-state-disabled")||n.hasClass("ui-tabs-loading")||this.running||r&&!e.collapsible||!1===this._trigger("beforeActivate",t,l)||(e.active=!s&&this.tabs.index(n),this.active=r?E():n,this.xhr&&this.xhr.abort(),a.length||o.length||E.error("jQuery UI Tabs: Mismatching fragment identifier."),o.length&&this.load(this.tabs.index(n),t),this._toggle(t,l))},_toggle:function(t,e){function i(){r.running=!1,r._trigger("activate",t,e)}function n(){r._addClass(e.newTab.closest("li"),"ui-tabs-active","ui-state-active"),s.length&&r.options.show?r._show(s,r.options.show,i):(s.show(),i())}var r=this,s=e.newPanel,o=e.oldPanel;this.running=!0,o.length&&this.options.hide?this._hide(o,this.options.hide,function(){r._removeClass(e.oldTab.closest("li"),"ui-tabs-active","ui-state-active"),n()}):(this._removeClass(e.oldTab.closest("li"),"ui-tabs-active","ui-state-active"),o.hide(),n()),o.attr("aria-hidden","true"),e.oldTab.attr({"aria-selected":"false","aria-expanded":"false"}),s.length&&o.length?e.oldTab.attr("tabIndex",-1):s.length&&this.tabs.filter(function(){return 0===E(this).attr("tabIndex")}).attr("tabIndex",-1),s.attr("aria-hidden","false"),e.newTab.attr({"aria-selected":"true","aria-expanded":"true",tabIndex:0})},_activate:function(t){var e,i=this._findActive(t);i[0]!==this.active[0]&&(i.length||(i=this.active),e=i.find(".ui-tabs-anchor")[0],this._eventHandler({target:e,currentTarget:e,preventDefault:E.noop}))},_findActive:function(t){return!1===t?E():this.tabs.eq(t)},_getIndex:function(t){return"string"==typeof t&&(t=this.anchors.index(this.anchors.filter("[href$='"+E.ui.escapeSelector(t)+"']"))),t},_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(){E.data(this,"ui-tabs-destroy")?E(this).remove():E(this).removeAttr("role tabIndex aria-live aria-busy aria-selected aria-labelledby aria-hidden aria-expanded")}),this.tabs.each(function(){var t=E(this),e=t.data("ui-tabs-aria-controls");e?t.attr("aria-controls",e).removeData("ui-tabs-aria-controls"):t.removeAttr("aria-controls")}),this.panels.show(),"content"!==this.options.heightStyle&&this.panels.css("height","")},enable:function(i){var t=this.options.disabled;!1!==t&&(t=void 0!==i&&(i=this._getIndex(i),E.isArray(t)?E.map(t,function(t){return t!==i?t:null}):E.map(this.tabs,function(t,e){return e!==i?e:null})),this._setOptionDisabled(t))},disable:function(t){var e=this.options.disabled;if(!0!==e){if(void 0===t)e=!0;else{if(t=this._getIndex(t),-1!==E.inArray(t,e))return;e=E.isArray(e)?E.merge([t],e).sort():[t]}this._setOptionDisabled(e)}},load:function(t,n){t=this._getIndex(t);var r=this,i=this.tabs.eq(t),e=i.find(".ui-tabs-anchor"),s=this._getPanelForTab(i),o={tab:i,panel:s},a=function(t,e){"abort"===e&&r.panels.stop(!1,!0),r._removeClass(i,"ui-tabs-loading"),s.removeAttr("aria-busy"),t===r.xhr&&delete r.xhr};this._isLocal(e[0])||(this.xhr=E.ajax(this._ajaxSettings(e,n,o)),this.xhr&&"canceled"!==this.xhr.statusText&&(this._addClass(i,"ui-tabs-loading"),s.attr("aria-busy","true"),this.xhr.done(function(t,e,i){setTimeout(function(){s.html(t),r._trigger("load",n,o),a(i,e)},1)}).fail(function(t,e){setTimeout(function(){a(t,e)},1)})))},_ajaxSettings:function(t,i,n){var r=this;return{url:t.attr("href").replace(/#.*$/,""),beforeSend:function(t,e){return r._trigger("beforeLoad",i,E.extend({jqXHR:t,ajaxSettings:e},n))}}},_getPanelForTab:function(t){var e=E(t).attr("aria-controls");return this.element.find(this._sanitizeSelector("#"+e))}}),!1!==E.uiBackCompat&&E.widget("ui.tabs",E.ui.tabs,{_processTabs:function(){this._superApply(arguments),this._addClass(this.tabs,"ui-tab")}}),E.ui.tabs,E.widget("ui.tooltip",{version:"1.12.1",options:{classes:{"ui-tooltip":"ui-corner-all ui-widget-shadow"},content:function(){var t=E(this).attr("title")||"";return E("<a>").text(t).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(t,e){var i=(t.attr("aria-describedby")||"").split(/\s+/);i.push(e),t.data("ui-tooltip-id",e).attr("aria-describedby",E.trim(i.join(" ")))},_removeDescribedBy:function(t){var e=t.data("ui-tooltip-id"),i=(t.attr("aria-describedby")||"").split(/\s+/),n=E.inArray(e,i);-1!==n&&i.splice(n,1),t.removeData("ui-tooltip-id"),(i=E.trim(i.join(" ")))?t.attr("aria-describedby",i):t.removeAttr("aria-describedby")},_create:function(){this._on({mouseover:"open",focusin:"open"}),this.tooltips={},this.parents={},this.liveRegion=E("<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=E([])},_setOption:function(t,e){var i=this;this._super(t,e),"content"===t&&E.each(this.tooltips,function(t,e){i._updateContent(e.element)})},_setOptionDisabled:function(t){this[t?"_disable":"_enable"]()},_disable:function(){var n=this;E.each(this.tooltips,function(t,e){var i=E.Event("blur");i.target=i.currentTarget=e.element[0],n.close(i,!0)}),this.disabledTitles=this.disabledTitles.add(this.element.find(this.options.items).addBack().filter(function(){var t=E(this);return t.is("[title]")?t.data("ui-tooltip-title",t.attr("title")).removeAttr("title"):void 0}))},_enable:function(){this.disabledTitles.each(function(){var t=E(this);t.data("ui-tooltip-title")&&t.attr("title",t.data("ui-tooltip-title"))}),this.disabledTitles=E([])},open:function(t){var i=this,e=E(t?t.target:this.element).closest(this.options.items);e.length&&!e.data("ui-tooltip-id")&&(e.attr("title")&&e.data("ui-tooltip-title",e.attr("title")),e.data("ui-tooltip-open",!0),t&&"mouseover"===t.type&&e.parents().each(function(){var t,e=E(this);e.data("ui-tooltip-open")&&((t=E.Event("blur")).target=t.currentTarget=this,i.close(t,!0)),e.attr("title")&&(e.uniqueId(),i.parents[this.id]={element:this,title:e.attr("title")},e.attr("title",""))}),this._registerCloseHandlers(t,e),this._updateContent(e,t))},_updateContent:function(e,i){var t,n=this.options.content,r=this,s=i?i.type:null;return"string"==typeof n||n.nodeType||n.jquery?this._open(i,e,n):void((t=n.call(e[0],function(t){r._delay(function(){e.data("ui-tooltip-open")&&(i&&(i.type=s),this._open(i,e,t))})}))&&this._open(i,e,t))},_open:function(t,e,i){function n(t){l.of=t,s.is(":hidden")||s.position(l)}var r,s,o,a,l=E.extend({},this.options.position);if(i){if(r=this._find(e))return void r.tooltip.find(".ui-tooltip-content").html(i);e.is("[title]")&&(t&&"mouseover"===t.type?e.attr("title",""):e.removeAttr("title")),r=this._tooltip(e),s=r.tooltip,this._addDescribedBy(e,s.attr("id")),s.find(".ui-tooltip-content").html(i),this.liveRegion.children().hide(),(a=E("<div>").html(s.find(".ui-tooltip-content").html())).removeAttr("name").find("[name]").removeAttr("name"),a.removeAttr("id").find("[id]").removeAttr("id"),a.appendTo(this.liveRegion),this.options.track&&t&&/^mouse/.test(t.type)?(this._on(this.document,{mousemove:n}),n(t)):s.position(E.extend({of:e},this.options.position)),s.hide(),this._show(s,this.options.show),this.options.track&&this.options.show&&this.options.show.delay&&(o=this.delayedShow=setInterval(function(){s.is(":visible")&&(n(l.of),clearInterval(o))},E.fx.interval)),this._trigger("open",t,{tooltip:s}
1)}},_registerCloseHandlers:function(t,i){var e={keyup:function(t){if(t.keyCode===E.ui.keyCode.ESCAPE){var e=E.Event(t);e.currentTarget=i[0],this.close(e,!0)}}};i[0]!==this.element[0]&&(e.remove=function(){this._removeTooltip(this._find(i).tooltip)}),t&&"mouseover"!==t.type||(e.mouseleave="close"),t&&"focusin"!==t.type||(e.focusout="close"),this._on(!0,i,e)},close:function(t){var e,i=this,n=E(t?t.currentTarget:this.element),r=this._find(n);return r?(e=r.tooltip,void(r.closing||(clearInterval(this.delayedShow),n.data("ui-tooltip-title")&&!n.attr("title")&&n.attr("title",n.data("ui-tooltip-title")),this._removeDescribedBy(n),r.hiding=!0,e.stop(!0),this._hide(e,this.options.hide,function(){i._removeTooltip(E(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"),t&&"mouseleave"===t.type&&E.each(this.parents,function(t,e){E(e.element).attr("title",e.title),delete i.parents[t]}),r.closing=!0,this._trigger("close",t,{tooltip:e}),r.hiding||(r.closing=!1)))):void n.removeData("ui-tooltip-open")},_tooltip:function(t){var e=E("<div>").attr("role","tooltip"),i=E("<div>").appendTo(e),n=e.uniqueId().attr("id");return this._addClass(i,"ui-tooltip-content"),this._addClass(e,"ui-tooltip","ui-widget ui-widget-content"),e.appendTo(this._appendTo(t)),this.tooltips[n]={element:t,tooltip:e}},_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 r=this;E.each(this.tooltips,function(t,e){var i=E.Event("blur"),n=e.element;i.target=i.currentTarget=n[0],r.close(i,!0),E("#"+t).remove(),n.data("ui-tooltip-title")&&(n.attr("title")||n.attr("title",n.data("ui-tooltip-title")),n.removeData("ui-tooltip-title"))}),this.liveRegion.remove()}}),!1!==E.uiBackCompat&&E.widget("ui.tooltip",E.ui.tooltip,{options:{tooltipClass:null},_tooltip:function(){var t=this._superApply(arguments);return this.options.tooltipClass&&t.tooltip.addClass(this.options.tooltipClass),t}}),E.ui.tooltip}),function(t){function e(t,e){if(!(1<t.originalEvent.touches.length)){t.preventDefault();var i=t.originalEvent.changedTouches[0],n=document.createEvent("MouseEvents");n.initMouseEvent(e,!0,!0,window,1,i.screenX,i.screenY,i.clientX,i.clientY,!1,!1,!1,!1,0,null),t.target.dispatchEvent(n)}}if(t.support.touch="ontouchend"in document,t.support.touch){var i,n=t.ui.mouse.prototype,r=n._mouseInit,s=n._mouseDestroy;n._touchStart=function(t){!i&&this._mouseCapture(t.originalEvent.changedTouches[0])&&(i=!0,this._touchMoved=!1,e(t,"mouseover"),e(t,"mousemove"),e(t,"mousedown"))},n._touchMove=function(t){i&&(this._touchMoved=!0,e(t,"mousemove"))},n._touchEnd=function(t){i&&(e(t,"mouseup"),e(t,"mouseout"),this._touchMoved||e(t,"click"),i=!1)},n._mouseInit=function(){this.element.bind({touchstart:t.proxy(this,"_touchStart"),touchmove:t.proxy(this,"_touchMove"),touchend:t.proxy(this,"_touchEnd")}),r.call(this)},n._mouseDestroy=function(){this.element.unbind({touchstart:t.proxy(this,"_touchStart"),touchmove:t.proxy(this,"_touchMove"),touchend:t.proxy(this,"_touchEnd")}),s.call(this)}}}(jQuery),sliderRange(),updateFiltersPosition(),$(document).ready(function(){$(document).on("click","._lfgrp ._lfhdctg",function(){$(this).parent().toggleClass("open")}),$(document).on("click",".select_filter, #price-range-submit, #page-search",function(t){var e=getFilterUrl(0);if($(this).hasClass("price-range-search")?(minPrice=$("#min_price").val(),maxPrice=$("#max_price").val()):$(this).is(":checkbox")&&$(this).is(":checked")&&$(this).hasClass("select_filter")&&(filterLabel=$(this).parent().parent().parent().find("._lfhdctg").text(),filterValue=$(this).next().text()),$(this).attr("is-mobile"))return $(".filter_count").text("("+$(".select_filter:checkbox:checked").length+")"),!0;getProductListData(e.url+"&is_ajax=1&v=1",1),$(".clear-all").show(),window.history.pushState({},"",e.url),IS_MOBILE&&scrollPageById("allplist")}
1),$(document).on("keyup","#psearch",function(t){var e=$(this).val(),i=$(this).attr("data-lval");0<e.length?e!==i&&($(this).siblings(".clear-icon").show(),$(this).siblings("#page-search").hide(),13===t.keyCode&&($(this).attr("data-lval",e),$("#page-search").click())):($(this).attr("data-lval",""),$(this).siblings("#page-search").show(),$(this).siblings(".clear-icon").hide(),13!==t.keyCode&&$("#page-search").click())}),$(document).on("click",".showlist",function(){if($(this).parent().hasClass("showfull")){$(this).parent().removeClass("showfull");var t=$(this).prev().attr("data-limit");$(this).change().text($(this).attr("data-count")+" More");var e=0;$(this).prev().children().each(function(){t<++e&&$(this).css({display:"none"})})}else $(this).prev().children().css({display:""}),$(this).text("Show Less"),$(this).attr("data-target",$(this).parent().attr("data-label-id")),$(this).parent().addClass("showfull")}),$(document).on("click",".showpopup",function(){openBrandPopup(),$(".flfltr-list").show()}),$(document).on("click",".flfltr-list .closepup",function(){$(".flfltr-list").hide(),$("#openflfltr").stop().animate({scrollLeft:0},1e3)}),$(document).on("click","#brand-filter",function(){var t=getFilterUrl(1);$(".flfltr-list").hide(),getProductListData(t.url+"&is_ajax=1&v=1",1),$(".clear-all").show(),window.history.pushState({},"",t.url),IS_MOBILE&&scrollPageById("allplist")}),$(document).on("click",".clear_single",function(t){$(this).closest("._lfgrp").find(".select_filter").attr("checked",!1);var e=getFilterUrl(0);getProductListData(e.url+"&is_ajax=1&v=1",1),window.history.pushState({},"",e.url),IS_MOBILE&&scrollPageById("allplist"),$(this).remove()}),$(document).on("keyup change",".fltrinputkeywords",function(){changeFilterListing($(this),0),""!=$(this).val()?($(this).parent().addClass("open_filter"),$(this).prev().focus()):($(this).prev().val("").trigger("change"),$(this).parent().removeClass("open_filter"))}),$(document).on("click",".fltr-search-icon",function(){$(this).parent().hasClass("open_filter")&&($(this).closest(".open_filter").find(".fltrinputkeywords").val("").trigger("change"),$(this).parent().removeClass("open_filter"))}),$(document).on("keyup change",".fltrpopinputkeywords",function(){changeFilterListing($(this),1),$(".openflfltr").find(".fltr-alpha").each(function(){!1===$(this).next().is("li.checkb:visible")&&$(this).hide()})}),$(document).on("click",".psortby",function(t){if($(this).hasClass("active"))return!1;$(".psortby").removeClass("active"),$(this).addClass("active");var e=getFilterUrl(0);getProductListData(e.url+"&is_ajax=3&v=1",3),window.history.pushState({},"",e.url),IS_MOBILE&&($(".srtpopup .close").click(),scrollPageById("allplist"))}),$(document).on("click",".clear-all",function(t){$(".psortby").removeClass("active");var e=$(this).attr("data-url");getProductListData(e+"?is_ajax=1&v=1",1),window.history.pushState({},"",e),$('.psortby[data-sort="popularity"]').addClass("active"),$(".filter-str").remove(),$(".clear-all").hide()}),$(document).on("click",".search-fltr-cnt",function(t){var e=$(this).attr("data-key");"query"==e?($("#psearch").val(""),$("#price-range-submit").click()):"instock_price"==e?($("#min_price").val($("#min_price").attr("min")),$("#max_price").val($("#max_price").attr("max")),$("#price-range-submit").click()):$("#"+e).click(),$(this).parent().remove(),0==$(".filter-str").find(".search-fltr-cnt").length&&$(".filter-str").remove()}),$(document).on("click",".load-more",function(t){var e=$("#totalcount").val(),i=$("._lpdw").length;if(i<e){var n=$("#pagecount").val(),r=i/n+1,s="?";-1<window.location.href.indexOf("?")&&(s="&"),getProductListData(window.location.href.replace(/#.*/,"")+s+"is_ajax=2&v=1&size="+n+"&page="+r,2)}}),$(document).on("click","._lfsicon",function(){$(this).parent().hasClass("open_filter")&&($(this).closest(".open_filter").find(".fltrinputkeywords").val("").trigger("change"),$(this).parent().removeClass("open_filter"))}),$(document).on("click",".clear-icon",function(){$("#psearch").val(""),$(".clear-icon").hide(),$(".search-btn").show(),$(".search-btn").click()}),0<$("._shrinkjs").length&&85<$("._shrinkjs").height()&&($("._smry ._shrinkjs").height((IS_MOBILE?"94":"85")+"px"),$("._smry ._shrinkjs").append('<div class="_fdr _fdrw"><span class="_flx _rmbtn _smlbtn _shrinkOpen">read more</span></div>')),0<$("._shrinkjs").length&&$("._fdr ._shrinkOpen").click(function(){$(this).parent().parent().css({height:""}).removeClass("_shrink _shrinkjs"),$(this).parent().remove()})}),$(document).ready(function(){if(0<$("._qlnk .swiper-container").length)new Swiper("._qlnk .swiper-container",{slidesPerView:"auto",spaceBetween:10,autoHeight:!1,navigation:{nextEl:".swiper-button-next",prevEl:".swiper-button-prev"}});$("#filterlist").prependTo("._lpdcntr"),$("._lsrtby").prependTo("._lpdlst"),$("._lpmid").css({"margin-top":"0"}),$(".filter-str").insertAfter("._lsrtby")}),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).firebase=e()}(this,function(){"use strict";
1var n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&(t[i]=e[i])})(t,e)},i=function(){return(i=Object.assign||function(t){for(var e,i=1,n=arguments.length;i<n;i++)for(var r in e=arguments[i])Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}).apply(this,arguments)};function h(t){var e="function"==typeof Symbol&&Symbol.iterator,i=e&&t[e],n=0;if(i)return i.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")}function d(t,e){var i="function"==typeof Symbol&&t[Symbol.iterator];if(!i)return t;var n,r,s=i.call(t),o=[];try{for(;(void 0===e||0<e--)&&!(n=s.next()).done;)o.push(n.value)}catch(t){r={error:t}}finally{try{n&&!n.done&&(i=s.return)&&i.call(s)}finally{if(r)throw r.error}}return o}function u(t,e){for(var i=0,n=e.length,r=t.length;i<n;i++,r++)t[r]=e[i];return t}function p(t,e){if(!(e instanceof Object))return e;switch(e.constructor){case Date:return new Date(e.getTime());case Object:void 0===t&&(t={});break;case Array:t=[];break;default:return e}for(var i in e)e.hasOwnProperty(i)&&"__proto__"!==i&&(t[i]=p(t[i],e[i]));return t}var r=(t.prototype.wrapCallback=function(i){var n=this;return function(t,e){t?n.reject(t):n.resolve(e),"function"==typeof i&&(n.promise.catch(function(){}),1===i.length?i(t):i(t,e))}},t);function t(){var i=this;this.reject=function(){},this.resolve=function(){},this.promise=new Promise(function(t,e){i.resolve=t,i.reject=e})}var s,o="FirebaseError",a=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}(l,s=Error),l);function l(t,e,i){return(e=s.call(this,e)||this).code=t,e.customData=i,e.name=o,Object.setPrototypeOf(e,l.prototype),Error.captureStackTrace&&Error.captureStackTrace(e,c.prototype.create),e}var c=(e.prototype.create=function(t){for(var e=[],i=1;i<arguments.length;i++)e[i-1]=arguments[i];var n,r=e[0]||{},s=this.service+"/"+t;t=(t=this.errors[t])?(n=r,t.replace(f,function(t,e){var i=n[e];return null!=i?String(i):"<"+e+"?>"})):"Error",t=this.serviceName+": "+t+" ("+s+").";return new a(s,t,r)},e);function e(t,e,i){this.service=t,this.serviceName=e,this.errors=i}var f=/\{\$([^}]+)}/g;function g(t,e){return Object.prototype.hasOwnProperty.call(t,e)}function m(t,e){return(e=new v(t,e)).subscribe.bind(e)}var v=(y.prototype.next=function(e){this.forEachObserver(function(t){t.next(e)})},y.prototype.error=function(e){this.forEachObserver(function(t){t.error(e)}),this.close(e)},y.prototype.complete=function(){this.forEachObserver(function(t){t.complete()}),this.close()},y.prototype.subscribe=function(t,e,i){var n,r=this;if(void 0===t&&void 0===e&&void 0===i)throw new Error("Missing Observer.");return void 0===(n=function(t,e){if("object"!=typeof t||null===t)return!1;for(var i=0,n=["next","error","complete"];i<n.length;i++){var r=n[i];if(r in t&&"function"==typeof t[r])return!0}return!1}(t)?t:{next:t,error:e,complete:i}).next&&(n.next=b),void 0===n.error&&(n.error=b),void 0===n.complete&&(n.complete=b),i=this.unsubscribeOne.bind(this,this.observers.length),this.finalized&&this.task.then(function(){try{r.finalError?n.error(r.finalError):n.complete()}catch(t){}}),this.observers.push(n),i},y.prototype.unsubscribeOne=function(t){void 0!==this.observers&&void 0!==this.observers[t]&&(delete this.observers[t],--this.observerCount,0===this.observerCount&&void 0!==this.onNoObservers&&this.onNoObservers(this))},y.prototype.forEachObserver=function(t){if(!this.finalized)for(var e=0;e<this.observers.length;e++)this.sendOne(e,t)},y.prototype.sendOne=function(t,e){var i=this;this.task.then(function(){if(void 0!==i.observers&&void 0!==i.observers[t])try{e(i.observers[t])}catch(t){"undefined"!=typeof console&&console.error&&console.error(t)}})},y.prototype.close=function(t){var e=this;this.finalized||(this.finalized=!0,void 0!==t&&(this.finalError=t),this.task.then(function(){e.observers=void 0,e.onNoObservers=void 0}))},y);function y(t,e){var i=this;this.observers=[],this.unsubscribes=[],this.observerCount=0,this.task=Prom
1ise.resolve(),this.finalized=!1,this.onNoObservers=e,this.task.then(function(){t(i)}).catch(function(t){i.error(t)})}function b(){}var w=(_.prototype.setInstantiationMode=function(t){return this.instantiationMode=t,this},_.prototype.setMultipleInstances=function(t){return this.multipleInstances=t,this},_.prototype.setServiceProps=function(t){return this.serviceProps=t,this},_.prototype.setInstanceCreatedCallback=function(t){return this.onInstanceCreated=t,this},_);function _(t,e,i){this.name=t,this.instanceFactory=e,this.type=i,this.multipleInstances=!1,this.serviceProps={},this.instantiationMode="LAZY",this.onInstanceCreated=null}var x="[DEFAULT]",T=(S.prototype.get=function(t){var e=this.normalizeInstanceIdentifier(t);if(!this.instancesDeferred.has(e)&&(t=new r,this.instancesDeferred.set(e,t),this.isInitialized(e)||this.shouldAutoInitialize()))try{var i=this.getOrInitializeService({instanceIdentifier:e});i&&t.resolve(i)}catch(t){}return this.instancesDeferred.get(e).promise},S.prototype.getImmediate=function(t){var e=this.normalizeInstanceIdentifier(null==t?void 0:t.identifier);t=null!==(t=null==t?void 0:t.optional)&&void 0!==t&&t;if(!this.isInitialized(e)&&!this.shouldAutoInitialize()){if(t)return null;throw Error("Service "+this.name+" is not available")}try{return this.getOrInitializeService({instanceIdentifier:e})}catch(e){if(t)return null;throw e}},S.prototype.getComponent=function(){return this.component},S.prototype.setComponent=function(t){var e,i;if(t.name!==this.name)throw Error("Mismatching Component "+t.name+" for Provider "+this.name+".");if(this.component)throw Error("Component for "+this.name+" has already been provided");if(this.component=t,this.shouldAutoInitialize()){if("EAGER"===t.instantiationMode)try{this.getOrInitializeService({instanceIdentifier:x})}catch(t){}try{for(var n=h(this.instancesDeferred.entries()),r=n.next();!r.done;r=n.next()){var s=d(r.value,2),o=s[0],a=s[1],l=this.normalizeInstanceIdentifier(o);try{var u=this.getOrInitializeService({instanceIdentifier:l});a.resolve(u)}catch(t){}}}catch(t){e={error:t}}finally{try{r&&!r.done&&(i=n.return)&&i.call(n)}finally{if(e)throw e.error}}}},S.prototype.clearInstance=function(t){this.instancesDeferred.delete(t=void 0===t?x:t),this.instancesOptions.delete(t),this.instances.delete(t)},S.prototype.delete=function(){return t=this,l=function(){var e;return function(i,n){var r,s,o,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]},t={next:e(0),throw:e(1),return:e(2)};return"function"==typeof Symbol&&(t[Symbol.iterator]=function(){return this}),t;function e(e){return function(t){return function(e){if(r)throw new TypeError("Generator is already executing.");for(;a;)try{if(r=1,s&&(o=2&e[0]?s.return:e[0]?s.throw||((o=s.return)&&o.call(s),0):s.next)&&!(o=o.call(s,e[1])).done)return o;switch(s=0,(e=o?[2&e[0],o.value]:e)[0]){case 0:case 1:o=e;break;case 4:return a.label++,{value:e[1],done:!1};case 5:a.label++,s=e[1],e=[0];continue;case 7:e=a.ops.pop(),a.trys.pop();continue;default:if(!(o=0<(o=a.trys).length&&o[o.length-1])&&(6===e[0]||2===e[0])){a=0;continue}if(3===e[0]&&(!o||e[1]>o[0]&&e[1]<o[3])){a.label=e[1];break}if(6===e[0]&&a.label<o[1]){a.label=o[1],o=e;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(e);break}o[2]&&a.ops.pop(),a.trys.pop();continue}e=n.call(i,a)}catch(t){e=[6,t],s=0}finally{r=o=0}if(5&e[0])throw e[1];return{value:e[0]?e[1]:void 0,done:!0}}([e,t])}}}(this,function(t){switch(t.label){case 0:return e=Array.from(this.instances.values()),[4,Promise.all(u(u([],d(e.filter(function(t){return"INTERNAL"in t}).map(function(t){return t.INTERNAL.delete()}))),d(e.filter(function(t){return"_delete"in t}).map(function(t){return t._delete()}))))];case 1:return t.sent(),[2]}})},new(a=(a=o=void 0)||Promise)(function(i,e){function n(t){try{s(l.next(t))}catch(t){e(t)}}function r(t){try{s(l.throw(t))}catch(t){e(t)}}function s(t){var e;t.done?i(t.value):((e=t.value)instanceof a?e:new a(function(t){t(e)})).then(n,r)}s((l=l.apply(t,o||[])).next())});var t,o,a,l},S.prototype.isComponentSet=function(){return null!=this.component},S.prototype.isInitialized=function(t){return this.instances.has(t=void 0===t?x:t)},S.prototype.getOptions=function(t){return this.instancesOptions.get(t=void 0===t?x:t)||{}},S.prototype.initialize=function(t){var e,i,n=void 0===(n=(t=void 0===t?{}:t).options)?{}:n,r=this.normalizeInstanceIdentifier(t.instanceIdentifier);if(this.isInitialized(r))throw Error(this.name+"("+r+") has already been initialized");if(!this.isComponentSet())throw Error("Component "+this.name+" has not been registered yet");var s=this.getOrInitializeService({instanceIdentifier:r,options:n});try{for(var o=h(this.instancesDeferred.entries()),a=o.next();!a.done;a=o.next()){var l=d(a.value,2),u=l[0],c=l[1];r===this.normalizeInstanceIdentifier(u)&&c.resolve(s)}}catch(t){e={error:t}}finally{try{a&&!a.done&&(i=o.return)&&i.call(o)}finally{if(e)throw e.error}}return s},S.prototype.onInit=function(t,e){var i=this.normalizeInstanceIdentifier(e),n=null!==(e=this.onInitCallbacks.get(i))&&void 0!==e?e:new Set;return n.add(t),this.onInitCallbacks.set(i,n),(e=this.instances.get(i))&&t(e,i),function(){n.delete(t)}},S.prototype.invokeOnInitCallbacks=function(t,e){var i,n,r=this.onInitCallbacks.get(e);if(r)try{for(var s=h(r),o=s.next();!o.done;o=s.next()){var a=o.value;try{a(t,e)}catch(t){}}}catch(t){i={error:t}}finally{try{o&&!o.done&&(n=s.return)&&n.call(s)}finally{if(i)throw i.error}}},S.prototype.getOrInitializeService=function(t){var e=t.instanceIdentifier,i=t.options,n=void 0===i?{}:i;if(!(t=this.instances.get(e))&&this.component&&(t=this.component.instanceFactory(this.container,{instanceIdentifier:(i=e)===x?void 0:i,options:n}),this.instances.set(e,t),this.instancesOptions.set(e,n),this.invokeOnInitCallbacks(t,e),this.component.onInstanceCreated))try{this.component.onInstanceCreated(this.container,e,t)}catch(t){}return t||null},S.prototype.normalizeInstanceIdentifier=function(t){return void 0===t&&(t=x),!this.component||this.component.multipleInstances?t:x},S.prototype.shouldAutoInitialize=function(){return!!this.component&&"EXPLICIT"!==this.component.instantiationMode},S);function S(t,e){this.name=t,this.container=e,this.component=null,this.instances=new Map,this.instancesDeferred=new Map,this.instancesOptions=new Map,this.onInitCallbacks=new Map}var C=(E.prototype.addComponent=function(t){var e=this.getProvider(t.name);if(e.isComponentSet())throw new Error("Component "+t.name+" has already been registered with "+this.name);e.setComponent(t)},E.prototype.addOrOverwriteComponent=function(t){this.getProvider(t.name).isComponentSet()&&this.providers.delete(t.name),this.addComponent(t)},E.prototype.getProvider=function(t){if(this.providers.has(t))return this.providers.get(t);var e=new T(t,this);return this.providers.set(t,e),e},E.prototype.getProviders=function(){return Array.from(this.providers.values())},E);function E(t){this.name=t,this.providers=new Map}var k,I=[];function D(t,e){for(var i=[],n=2;n<arguments.length;n++)i[n-2]=arguments[n];if(!(e<t.logLevel)){var r=(new Date).toISOString(),s=M[e];if(!s)throw new Error("Attempted to log a message with an invali
1d logType (value: "+e+")");console[s].apply(console,u(["["+r+"]  "+t.name+":"],i))}}(N=k=k||{})[N.DEBUG=0]="DEBUG",N[N.VERBOSE=1]="VERBOSE",N[N.INFO=2]="INFO",N[N.WARN=3]="WARN",N[N.ERROR=4]="ERROR",N[N.SILENT=5]="SILENT";var A={debug:k.DEBUG,verbose:k.VERBOSE,info:k.INFO,warn:k.WARN,error:k.ERROR,silent:k.SILENT},P=k.INFO,M=((R={})[k.DEBUG]="log",R[k.VERBOSE]="log",R[k.INFO]="info",R[k.WARN]="warn",R[k.ERROR]="error",R),N=(Object.defineProperty(O.prototype,"logLevel",{get:function(){return this._logLevel},set:function(t){if(!(t in k))throw new TypeError('Invalid value "'+t+'" assigned to `logLevel`');this._logLevel=t},enumerable:!1,configurable:!0}),O.prototype.setLogLevel=function(t){this._logLevel="string"==typeof t?A[t]:t},Object.defineProperty(O.prototype,"logHandler",{get:function(){return this._logHandler},set:function(t){if("function"!=typeof t)throw new TypeError("Value assigned to `logHandler` must be a function");this._logHandler=t},enumerable:!1,configurable:!0}),Object.defineProperty(O.prototype,"userLogHandler",{get:function(){return this._userLogHandler},set:function(t){this._userLogHandler=t},enumerable:!1,configurable:!0}),O.prototype.debug=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];this._userLogHandler&&this._userLogHandler.apply(this,u([this,k.DEBUG],t)),this._logHandler.apply(this,u([this,k.DEBUG],t))},O.prototype.log=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];this._userLogHandler&&this._userLogHandler.apply(this,u([this,k.VERBOSE],t)),this._logHandler.apply(this,u([this,k.VERBOSE],t))},O.prototype.info=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];this._userLogHandler&&this._userLogHandler.apply(this,u([this,k.INFO],t)),this._logHandler.apply(this,u([this,k.INFO],t))},O.prototype.warn=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];this._userLogHandler&&this._userLogHandler.apply(this,u([this,k.WARN],t)),this._logHandler.apply(this,u([this,k.WARN],t))},O.prototype.error=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];this._userLogHandler&&this._userLogHandler.apply(this,u([this,k.ERROR],t)),this._logHandler.apply(this,u([this,k.ERROR],t))},O);function O(t){this.name=t,this._logLevel=P,this._logHandler=D,this._userLogHandler=null,I.push(this)}function L(e){I.forEach(function(t){t.setLogLevel(e)})}var R=((R={})["no-app"]="No Firebase App '{$appName}' has been created - call Firebase App.initializeApp()",R["bad-app-name"]="Illegal App name: '{$appName}",R["duplicate-app"]="Firebase App named '{$appName}' already exists",R["app-deleted"]="Firebase App named '{$appName}' already deleted",R["invalid-app-argument"]="firebase.{$appName}() takes either no argument or a Firebase App instance.",R["invalid-log-argument"]="First argument to `onLog` must be null or a function.",R),F=new c("app","Firebase",R),z="@firebase/app",B="[DEFAULT]",$=((R={})[z]="fire-core",R["@firebase/analytics"]="fire-analytics",R["@firebase/app-check"]="fire-app-check",R["@firebase/auth"]="fire-auth",R["@firebase/database"]="fire-rtdb",R["@firebase/functions"]="fire-fn",R["@firebase/installations"]="fire-iid",R["@firebase/messaging"]="fire-fcm",R["@firebase/performance"]="fire-perf",R["@firebase/remote-config"]="fire-rc",R["@firebase/storage"]="fire-gcs",R["@firebase/firestore"]="fire-fst",R["fire-js"]="fire-js",R["firebase-wrapper"]="fire-js-all",R),j=new N("@firebase/app"),H=(Object.defineProperty(q.prototype,"automaticDataCollectionEnabled",{get:function(){return this.checkDestroyed_(),this.automaticDataCollectionEnabled_},set:function(t){this.checkDestroyed_(),this.automaticDataCollectionEnabled_=t},enumerable:!1,configurable:!0}),Object.defineProperty(q.prototype,"name",{get:function(){return this.checkDestroyed_(),this.name_},enumerable:!1,configurable:!0}),Object.defineProperty(q.prototype,"options",{get:function(){return this.checkDestroyed_(),this.options_},enumerable:!1,configurable:!0}),q.prototype.delete=function(){var e=this;return new Promise(function(t){e.checkDestroyed_(),t()}).then(function(){return e.firebase_.INTERNAL.removeApp(e.name_),Promise.all(e.container.getProviders().map(function(t){return t.delete()}))}).then(function(){e.isDeleted_=!0})},q.prototype._getService=function(t,e){void 0===e&&(e=B),this.checkDestroyed_();var i=this.container.getProvider(t);return i.isInitialized()||"EXPLICIT"!==(null===(t=i.getComponent())||void 0===t?void 0:t.instantiationMode)||i.initialize(),i.getImmediate({identifier:e})},q.prototype._removeServiceInstance=function(t,e){void 0===e&&(e=B),this.container.getProvider(t).clearInstance(e)},q.prototype._addComponent=function(e){try{this.container.addComponent(e)}catch(t){j.debug("Component "+e.name+" failed to register with FirebaseApp "+this.name,t)}},q.prototype._addOrOverwriteComponent=function(t){this.container.addOrOverwriteComponent(t)},q.prototype.toJSON=function(){return{name:this.name,automaticDataCollectionEnabled:this.automaticDataCollectionEnabled,options:this.options}},q.prototype.checkDestroyed_=function(){if(this.isDeleted_)throw F.create("app-deleted",{appName:this.name_})},q);function q(t,e,i){var n=this;this.firebase_=i,this.isDeleted_=!1,this.name_=e.name,this.automaticDataCollectionEnabled_=e.automaticDataCollectionEnabled||!1,this.options_=p(void 0,t),this.container=new C(e.name),this._addComponent(new w("app",function(){return n}
1,"PUBLIC")),this.firebase_.INTERNAL.components.forEach(function(t){return n._addComponent(t)})}H.prototype.name&&H.prototype.options||H.prototype.delete||console.log("dc");function V(o){var a={},l=new Map,u={__esModule:!0,initializeApp:function(t,e){void 0===e&&(e={}),"object"==typeof e&&null!==e||(e={name:e});var i=e;if(void 0===i.name&&(i.name=B),"string"!=typeof(e=i.name)||!e)throw F.create("bad-app-name",{appName:String(e)});if(g(a,e))throw F.create("duplicate-app",{appName:e});return i=new o(t,i,u),a[e]=i},app:c,registerVersion:function(t,e,i){var n=null!==(r=$[t])&&void 0!==r?r:t;i&&(n+="-"+i);var r=n.match(/\s|\//);t=e.match(/\s|\//);r||t?(i=['Unable to register library "'+n+'" with version "'+e+'":'],r&&i.push('library name "'+n+'" contains illegal characters (whitespace or "/")'),r&&t&&i.push("and"),t&&i.push('version name "'+e+'" contains illegal characters (whitespace or "/")'),j.warn(i.join(" "))):s(new w(n+"-version",function(){return{library:n,version:e}},"VERSION"))},setLogLevel:L,onLog:function(t,e){if(null!==t&&"function"!=typeof t)throw F.create("invalid-log-argument");!function(o,e){for(var t=0,i=I;t<i.length;t++)!function(t){var s=null;e&&e.level&&(s=A[e.level]),t.userLogHandler=null===o?null:function(t,e){for(var i=[],n=2;n<arguments.length;n++)i[n-2]=arguments[n];var r=i.map(function(t){if(null==t)return null;if("string"==typeof t)return t;if("number"==typeof t||"boolean"==typeof t)return t.toString();if(t instanceof Error)return t.message;try{return JSON.stringify(t)}catch(t){return null}}).filter(function(t){return t}).join(" ");e>=(null!=s?s:t.logLevel)&&o({level:k[e].toLowerCase(),message:r,args:i,type:t.name})}}(i[t])}(t,e)},apps:null,SDK_VERSION:"8.10.0",INTERNAL:{registerComponent:s,removeApp:function(t){delete a[t]},components:l,useAsService:function(t,e){return"serverAuth"!==e?e:null}}};function c(t){if(!g(a,t=t||B))throw F.create("no-app",{appName:t});return a[t]}function s(i){var t,n=i.name;if(l.has(n))return j.debug("There were multiple attempts to register component "+n+"."),"PUBLIC"===i.type?u[n]:null;l.set(n,i),"PUBLIC"===i.type&&(t=function(t){if("function"!=typeof(t=void 0===t?c():t)[n])throw F.create("invalid-app-argument",{appName:n});return t[n]()},void 0!==i.serviceProps&&p(t,i.serviceProps),u[n]=t,o.prototype[n]=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return this._getService.bind(this,n).apply(this,i.multipleInstances?t:[])});for(var e=0,r=Object.keys(a);e<r.length;e++){var s=r[e];a[s]._addComponent(i)}return"PUBLIC"===i.type?u[n]:null}return u.default=u,Object.defineProperty(u,"apps",{get:function(){return Object.keys(a).map(function(t){return a[t]})}}),c.App=o,u}R=function t(){var e=V(H);return e.INTERNAL=i(i({},e.INTERNAL),{createFirebaseNamespace:t,extendNamespace:function(t){p(e,t)},createSubscribe:m,ErrorFactory:c,deepExtend:p}),e}();var U=(W.prototype.getPlatformInfoString=function(){return this.container.getProviders().map(function(t){return"VERSION"===(null==(e=(e=t).getComponent())?void 0:e.type)?(t=t.getImmediate()).library+"/"+t.version:null;var e}).filter(function(t){return t}).join(" ")},W);function W(t){this.container=t}"object"==typeof self&&self.self===self&&void 0!==self.firebase&&(j.warn("\n    Warning: Firebase is already defined in the global scope. Please make sure\n    Firebase library is only loaded once.\n  "),(N=self.firebase.SDK_VERSION)&&0<=N.indexOf("LITE")&&j.warn("\n    Warning: You are trying to load Firebase while using Firebase Performance standalone script.\n    You should load Firebase Performance with this instance of Firebase to avoid loading duplicate code.\n    "));var K=R.initializeApp;R.initializeApp=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return function(){try{return"[object process]"===Object.prototype.toString.call(global.process)}catch(t){return}}()&&j.warn('\n      Warning: This is a browser-targeted Firebase bundle but it appears it is being\n      run in a Node environment.  If running in a Node environment, make sure you\n      are using the bundle specified by the "main" field in package.json.\n      \n      If you are using Webpack, you can specify "main" as the first item in\n      "resolve.mainFields":\n      https://webpack.js.org/configuration/resolve/#resolvemainfields\n      \n      If using Rollup, use the @rollup/plugin-node-resolve plugin and specify "main"\n      as the first item in "mainFields", e.g. [\'main\', \'module\'].\n      https://github.com/rollup/@rollup/plugin-node-resolve\n      '),K.apply(void 0,t)};var G,Y=R;return(G=Y).INTERNAL.registerComponent(new w("platform-logger",function(t){return new U(t)},"PRIVATE")),G.registerVersion(z,"0.6.30",void 0),G.registerVersion("fire-js",""),Y.registerVersion("firebase","8.10.0","app"),Y.SDK_VERSION="8.10.0",Y}),function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(require("@firebase/app")):"function"==typeof define&&define.amd?define(["@firebase/app"],e):e((t="undefined"!=typeof globalThis?globalThis:t||self).firebase)}(this,function(nv){"use strict";try{(function(){var t,e=(t=nv)&&"object"==typeof t&&"default"in t?t:{default:t}
1,n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&(t[i]=e[i])})(t,e)};function i(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}var a=function(){return(a=Object.assign||function(t){for(var e,i=1,n=arguments.length;i<n;i++)for(var r in e=arguments[i])Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}).apply(this,arguments)};function g(t,o,a,l){return new(a=a||Promise)(function(i,e){function n(t){try{s(l.next(t))}catch(t){e(t)}}function r(t){try{s(l.throw(t))}catch(t){e(t)}}function s(t){var e;t.done?i(t.value):((e=t.value)instanceof a?e:new a(function(t){t(e)})).then(n,r)}s((l=l.apply(t,o||[])).next())})}function m(i,n){var r,s,o,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]},t={next:e(0),throw:e(1),return:e(2)};return"function"==typeof Symbol&&(t[Symbol.iterator]=function(){return this}),t;function e(e){return function(t){return function(e){if(r)throw new TypeError("Generator is already executing.");for(;a;)try{if(r=1,s&&(o=2&e[0]?s.return:e[0]?s.throw||((o=s.return)&&o.call(s),0):s.next)&&!(o=o.call(s,e[1])).done)return o;switch(s=0,(e=o?[2&e[0],o.value]:e)[0]){case 0:case 1:o=e;break;case 4:return a.label++,{value:e[1],done:!1};case 5:a.label++,s=e[1],e=[0];continue;case 7:e=a.ops.pop(),a.trys.pop();continue;default:if(!(o=0<(o=a.trys).length&&o[o.length-1])&&(6===e[0]||2===e[0])){a=0;continue}if(3===e[0]&&(!o||e[1]>o[0]&&e[1]<o[3])){a.label=e[1];break}if(6===e[0]&&a.label<o[1]){a.label=o[1],o=e;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(e);break}o[2]&&a.ops.pop(),a.trys.pop();continue}e=n.call(i,a)}catch(t){e=[6,t],s=0}finally{r=o=0}if(5&e[0])throw e[1];return{value:e[0]?e[1]:void 0,done:!0}}([e,t])}}}function o(t,e){for(var i=0,n=e.length,r=t.length;i<n;i++,r++)t[r]=e[i];return t}function r(t){for(var e=[],i=0,n=0;n<t.length;n++){var r=t.charCodeAt(n);r<128?e[i++]=r:(r<2048?e[i++]=r>>6|192:(55296==(64512&r)&&n+1<t.length&&56320==(64512&t.charCodeAt(n+1))?(r=65536+((1023&r)<<10)+(1023&t.charCodeAt(++n)),e[i++]=r>>18|240,e[i++]=r>>12&63|128):e[i++]=r>>12|224,e[i++]=r>>6&63|128),e[i++]=63&r|128)}return e}function l(t){return(e=t,e=r(e),s.encodeByteArray(e,!0)).replace(/\./g,"");var e}var s={byteToCharMap_:null,charToByteMap_:null,byteToCharMapWebSafe_:null,charToByteMapWebSafe_:null,ENCODED_VALS_BASE:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",get ENCODED_VALS(){return this.ENCODED_VALS_BASE+"+/="},get ENCODED_VALS_WEBSAFE(){return this.ENCODED_VALS_BASE+"-_."},HAS_NATIVE_SUPPORT:"function"==typeof atob,encodeByteArray:function(t,e){if(!Array.isArray(t))throw Error("encodeByteArray takes an array as a parameter");this.init_();for(var i=e?this.byteToCharMapWebSafe_:this.byteToCharMap_,n=[],r=0;r<t.length;r+=3){var s=t[r],o=r+1<t.length,a=o?t[r+1]:0,l=r+2<t.length,u=(15&a)<<2|(c=l?t[r+2]:0)>>6,c=63&c;l||(c=64,o||(u=64)),n.push(i[s>>2],i[(3&s)<<4|a>>4],i[u],i[c])}return n.join("")},encodeString:function(t,e){return this.HAS_NATIVE_SUPPORT&&!e?btoa(t):this.encodeByteArray(r(t),e)},decodeString:function(t,e){return this.HAS_NATIVE_SUPPORT&&!e?atob(t):function(t){for(var e=[],i=0,n=0;i<t.length;){var r,s,o,a=t[i++];a<128?e[n++]=String.fromCharCode(a):191<a&&a<224?(s=t[i++],e[n++]=String.fromCharCode((31&a)<<6|63&s)):239<a&&a<365?(r=((7&a)<<18|(63&(s=t[i++]))<<12|(63&(o=t[i++]))<<6|63&t[i++])-65536,e[n++]=String.fromCharCode(55296+(r>>10)),e[n++]=String.fromCharCode(56320+(1023&r))):(s=t[i++],o=t[i++],e[n++]=String.fromCharCode((15&a)<<12|(63&s)<<6|63&o))}return e.join("")}(this.decodeStringToByteArray(t,e))},decodeStringToByteArray:function(t,e){this.init_();for(var i=e?this.charToByteMapWebSafe_:this.charToByteMap_,n=[],r=0;r<t.length;){var s=i[t.charAt(r++)],o=r<t.length?i[t.charAt(r)]:0,a=++r<t.length?i[t.charAt(r)]:64,l=++r<t.length?i[t.charAt(r)]:64;if(++r,null==s||null==o||null==a||null==l)throw Error();n.push(s<<2|o>>4),64!==a&&(n.push(o<<4&240|a>>2),64!==l&&n.push(a<<6&192|l))}return n},init_:function(){if(!this.byteToCharMap_){this.byteToCharMap_={},this.charToByteMap_={},this.byteToCharMapWebSafe_={},this.charToByteMapWebSafe_={};for(var t=0;t<this.ENCODED_VALS.length;t++)this.byteToCharMap_[t]=this.ENCODED_VALS.charAt(t),this.charToByteMap_[this.byteToCharMap_[t]]=t,this.byteToCharMapWebSafe_[t]=this.ENCODED_VALS_WEBSAFE.charAt(t),(this.charToByteMapWebSafe_[this.byteToCharMapWebSafe_[t]]=t)>=this.ENCODED_VALS_BASE.length&&(this.charToByteMap_[this.ENCODED_VALS_WEBSAFE.charAt(t)]=t,this.charToByteMapWebSafe_[this.ENCODED_VALS.charAt(t)]=t)}}};function c(){return"undefined"!=typeof navigator&&"string"==typeof navigator.userAgent?navigator.userAgent:""}var u,h="FirebaseError",d=(i(p,u=Error),p);
1function p(t,e,i){return(e=u.call(this,e)||this).code=t,e.customData=i,e.name=h,Object.setPrototypeOf(e,p.prototype),Error.captureStackTrace&&Error.captureStackTrace(e,f.prototype.create),e}var f=(v.prototype.create=function(t){for(var e=[],i=1;i<arguments.length;i++)e[i-1]=arguments[i];var n,r=e[0]||{},s=this.service+"/"+t;t=(t=this.errors[t])?(n=r,t.replace(b,function(t,e){var i=n[e];return null!=i?String(i):"<"+e+"?>"})):"Error",t=this.serviceName+": "+t+" ("+s+").";return new d(s,t,r)},v);function v(t,e,i){this.service=t,this.serviceName=e,this.errors=i}var y,b=/\{\$([^}]+)}/g;function w(t){return t&&t._delegate?t._delegate:t}function _(t,e){for(var i=[],n=2;n<arguments.length;n++)i[n-2]=arguments[n];if(!(e<t.logLevel)){var r=(new Date).toISOString(),s=S[e];if(!s)throw new Error("Attempted to log a message with an invalid logType (value: "+e+")");console[s].apply(console,o(["["+r+"]  "+t.name+":"],i))}}(D=y=y||{})[D.DEBUG=0]="DEBUG",D[D.VERBOSE=1]="VERBOSE",D[D.INFO=2]="INFO",D[D.WARN=3]="WARN",D[D.ERROR=4]="ERROR",D[D.SILENT=5]="SILENT";var x={debug:y.DEBUG,verbose:y.VERBOSE,info:y.INFO,warn:y.WARN,error:y.ERROR,silent:y.SILENT},T=y.INFO,S=((_e={})[y.DEBUG]="log",_e[y.VERBOSE]="log",_e[y.INFO]="info",_e[y.WARN]="warn",_e[y.ERROR]="error",_e),C=(Object.defineProperty(E.prototype,"logLevel",{get:function(){return this._logLevel},set:function(t){if(!(t in y))throw new TypeError('Invalid value "'+t+'" assigned to `logLevel`');this._logLevel=t},enumerable:!1,configurable:!0}),E.prototype.setLogLevel=function(t){this._logLevel="string"==typeof t?x[t]:t},Object.defineProperty(E.prototype,"logHandler",{get:function(){return this._logHandler},set:function(t){if("function"!=typeof t)throw new TypeError("Value assigned to `logHandler` must be a function");this._logHandler=t},enumerable:!1,configurable:!0}),Object.defineProperty(E.prototype,"userLogHandler",{get:function(){return this._userLogHandler},set:function(t){this._userLogHandler=t},enumerable:!1,configurable:!0}),E.prototype.debug=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];this._userLogHandler&&this._userLogHandler.apply(this,o([this,y.DEBUG],t)),this._logHandler.apply(this,o([this,y.DEBUG],t))},E.prototype.log=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];this._userLogHandler&&this._userLogHandler.apply(this,o([this,y.VERBOSE],t)),this._logHandler.apply(this,o([this,y.VERBOSE],t))},E.prototype.info=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];this._userLogHandler&&this._userLogHandler.apply(this,o([this,y.INFO],t)),this._logHandler.apply(this,o([this,y.INFO],t))},E.prototype.warn=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];this._userLogHandler&&this._userLogHandler.apply(this,o([this,y.WARN],t)),this._logHandler.apply(this,o([this,y.WARN],t))},E.prototype.error=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];this._userLogHandler&&this._userLogHandler.apply(this,o([this,y.ERROR],t)),this._logHandler.apply(this,o([this,y.ERROR],t))},E);function E(t){this.name=t,this._logLevel=T,this._logHandler=_,this._userLogHandler=null}var k=function(t,e){return(k=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&(t[i]=e[i])})(t,e)};function I(t){var e="function"==typeof Symbol&&Symbol.iterator,i=e&&t[e],n=0;if(i)return i.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")}var D,A="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},P={},M=A||self;function N(){}function O(t){var e=typeof t;return"array"==(e="object"!=e?e:t?Array.isArray(t)?"array":e:"null")||"object"==e&&"number"==typeof t.length}function L(t){var e=typeof t;return"object"==e&&null!=t||"function"==e}var R="closure_uid_"+(1e9*Math.random()>>>0),F=0;function z(t,e,i){return t.call.apply(t.bind,arguments)}function B(e,i,t){if(!e)throw Error();if(2<arguments.length){var n=Array.prototype.slice.call(arguments,2);return function(){var t=Array.prototype.slice.call(arguments);return Array.prototype.unshift.apply(t,n),e.apply(i,t)}}return function(){return e.apply(i,arguments)}}function $(t,e,i){return($=Function.prototype.bind&&-1!=Function.prototype.bind.toString().indexOf("native code")?z:B).apply(null,arguments)}
1function j(e){var i=Array.prototype.slice.call(arguments,1);return function(){var t=i.slice();return t.push.apply(t,arguments),e.apply(this,t)}}function H(t,s){function e(){}e.prototype=s.prototype,t.Z=s.prototype,t.prototype=new e,(t.prototype.constructor=t).Vb=function(t,e,i){for(var n=Array(arguments.length-2),r=2;r<arguments.length;r++)n[r-2]=arguments[r];return s.prototype[e].apply(t,n)}}function q(){this.s=this.s,this.o=this.o}var V={};q.prototype.s=!1,q.prototype.na=function(){var t;!this.s&&(this.s=!0,this.M(),0)&&(t=this,t=Object.prototype.hasOwnProperty.call(t,R)&&t[R]||(t[R]=++F),delete V[t])},q.prototype.M=function(){if(this.o)for(;this.o.length;)this.o.shift()()};var U=Array.prototype.indexOf?function(t,e){return Array.prototype.indexOf.call(t,e,void 0)}:function(t,e){if("string"==typeof t)return"string"!=typeof e||1!=e.length?-1:t.indexOf(e,0);for(var i=0;i<t.length;i++)if(i in t&&t[i]===e)return i;return-1},W=Array.prototype.forEach?function(t,e,i){Array.prototype.forEach.call(t,e,i)}:function(t,e,i){for(var n=t.length,r="string"==typeof t?t.split(""):t,s=0;s<n;s++)s in r&&e.call(i,r[s],s,t)};function K(){return Array.prototype.concat.apply([],arguments)}function G(t){var e=t.length;if(0<e){for(var i=Array(e),n=0;n<e;n++)i[n]=t[n];return i}return[]}function Y(t){return/^[\s\xa0]*$/.test(t)}var X,Q=String.prototype.trim?function(t){return t.trim()}:function(t){return/^[\s\xa0]*([\s\S]*?)[\s\xa0]*$/.exec(t)[1]};function J(t,e){return-1!=t.indexOf(e)}function Z(t,e){return t<e?-1:e<t?1:0}var tt=M.navigator;function et(t,e,i){for(var n in t)e.call(i,t[n],n,t)}function it(t){var e,i={};for(e in t)i[e]=t[e];return i}X=tt&&(tt=tt.userAgent)?tt:"";var nt="constructor hasOwnProperty isPrototypeOf propertyIsEnumerable toLocaleString toString valueOf".split(" ");function rt(t){for(var e,i,n=1;n<arguments.length;n++){for(e in i=arguments[n])t[e]=i[e];for(var r=0;r<nt.length;r++)e=nt[r],Object.prototype.hasOwnProperty.call(i,e)&&(t[e]=i[e])}}function st(t){return st[" "](t),t}st[" "]=N;var ot,at=J(X,"Opera"),lt=J(X,"Trident")||J(X,"MSIE"),ut=J(X,"Edge"),ct=ut||lt,ht=J(X,"Gecko")&&!(J(X.toLowerCase(),"webkit")&&!J(X,"Edge"))&&!(J(X,"Trident")||J(X,"MSIE"))&&!J(X,"Edge"),dt=J(X.toLowerCase(),"webkit")&&!J(X,"Edge");function pt(){var t=M.document;return t?t.documentMode:void 0}var ft="",gt=(gt=X,ht?/rv:([^\);]+)(\)|;)/.exec(gt):ut?/Edge\/([\d\.]+)/.exec(gt):lt?/\b(?:MSIE|rv)[: ]([^\);]+)(\)|;)/.exec(gt):dt?/WebKit\/(\S+)/.exec(gt):at?/(?:Version)[ \/]?(\S+)/.exec(gt):void 0);gt&&(ft=gt?gt[1]:""),ot=lt&&null!=(gt=pt())&&gt>parseFloat(ft)?String(gt):ft;var mt={};var vt=M.document&&lt&&(pt()||parseInt(ot,10))||void 0,yt=function(){if(!M.addEventListener||!Object.defineProperty)return!1;var t=!1,e=Object.defineProperty({},"passive",{get:function(){t=!0}});try{M.addEventListener("test",N,e),M.removeEventListener("test",N,e)}catch(t){}return t}();function bt(t,e){this.type=t,this.g=this.target=e,this.defaultPrevented=!1}function wt(t,e){if(bt.call(this,t?t.type:""),this.relatedTarget=this.g=this.target=null,this.button=this.screenY=this.screenX=this.clientY=this.clientX=0,this.key="",this.metaKey=this.shiftKey=this.altKey=this.ctrlKey=!1,this.state=null,this.pointerId=0,this.pointerType="",this.i=null,t){var i=this.type=t.type,n=t.changedTouches&&t.changedTouches.length?t.changedTouches[0]:null;if(this.target=t.target||t.srcElement,this.g=e,e=t.relatedTarget){if(ht){t:{try{st(e.nodeName);var r=!0;break t}catch(t){}r=!1}r||(e=null)}}else"mouseover"==i?e=t.fromElement:"mouseout"==i&&(e=t.toElement);this.relatedTarget=e,n?(this.clientX=void 0!==n.clientX?n.clientX:n.pageX,this.clientY=void 0!==n.clientY?n.clientY:n.pageY,this.screenX=n.screenX||0,this.screenY=n.screenY||0):(this.clientX=void 0!==t.clientX?t.clientX:t.pageX,this.clientY=void 0!==t.clientY?t.clientY:t.pageY,this.screenX=t.screenX||0,this.screenY=t.screenY||0),this.button=t.button,this.key=t.key||"",this.ctrlKey=t.ctrlKey,this.altKey=t.altKey,this.shiftKey=t.shiftKey,this.metaKey=t.metaKey,this.pointerId=t.pointerId||0,this.pointerType="string"==typeof t.pointerType?t.pointerType:_t[t.pointerType]||"",this.state=t.state,(this.i=t).defaultPrevented&&wt.Z.h.call(this)}}bt.prototype.h=function(){this.defaultPrevented=!0},H(wt,bt);var _t={2:"touch",3:"pen",4:"mouse"};
1wt.prototype.h=function(){wt.Z.h.call(this);var t=this.i;t.preventDefault?t.preventDefault():t.returnValue=!1};var xt="closure_listenable_"+(1e6*Math.random()|0),Tt=0;function St(t,e,i,n,r){this.listener=t,this.proxy=null,this.src=e,this.type=i,this.capture=!!n,this.ia=r,this.key=++Tt,this.ca=this.fa=!1}function Ct(t){t.ca=!0,t.listener=null,t.proxy=null,t.src=null,t.ia=null}function Et(t){this.src=t,this.g={},this.h=0}function kt(t,e){var i,n,r,s=e.type;s in t.g&&(i=t.g[s],(r=0<=(n=U(i,e)))&&Array.prototype.splice.call(i,n,1),r&&(Ct(e),0==t.g[s].length&&(delete t.g[s],t.h--)))}function It(t,e,i,n){for(var r=0;r<t.length;++r){var s=t[r];if(!s.ca&&s.listener==e&&s.capture==!!i&&s.ia==n)return r}return-1}Et.prototype.add=function(t,e,i,n,r){var s=t.toString();(t=this.g[s])||(t=this.g[s]=[],this.h++);var o=It(t,e,n,r);return-1<o?(e=t[o],i||(e.fa=!1)):((e=new St(e,this.src,s,!!n,r)).fa=i,t.push(e)),e};var Dt="closure_lm_"+(1e6*Math.random()|0),At={};function Pt(t,e,i,n,r){if(n&&n.once)return function t(e,i,n,r,s){if(Array.isArray(i)){for(var o=0;o<i.length;o++)t(e,i[o],n,r,s);return null}return n=zt(n),e&&e[xt]?e.O(i,n,L(r)?!!r.capture:!!r,s):Mt(e,i,n,!0,r,s)}(t,e,i,n,r);if(Array.isArray(e)){for(var s=0;s<e.length;s++)Pt(t,e[s],i,n,r);return null}return i=zt(i),t&&t[xt]?t.N(e,i,L(n)?!!n.capture:!!n,r):Mt(t,e,i,!1,n,r)}function Mt(t,e,i,n,r,s){if(!e)throw Error("Invalid event type");var o,a=L(r)?!!r.capture:!!r,l=Rt(t);if(l||(t[Dt]=l=new Et(t)),(i=l.add(e,i,n,a,s)).proxy)return i;if(o=Lt,(i.proxy=n=function t(e){return o.call(t.src,t.listener,e)}).src=t,n.listener=i,t.addEventListener)void 0===(r=yt?r:a)&&(r=!1),t.addEventListener(e.toString(),n,r);else if(t.attachEvent)t.attachEvent(Ot(e.toString()),n);else{if(!t.addListener||!t.removeListener)throw Error("addEventListener and attachEvent are unavailable.");t.addListener(n)}return i}function Nt(t){var e,i,n;"number"!=typeof t&&t&&!t.ca&&((e=t.src)&&e[xt]?kt(e.i,t):(i=t.type,n=t.proxy,e.removeEventListener?e.removeEventListener(i,n,t.capture):e.detachEvent?e.detachEvent(Ot(i),n):e.addListener&&e.removeListener&&e.removeListener(n),(i=Rt(e))?(kt(i,t),0==i.h&&(i.src=null,e[Dt]=null)):Ct(t)))}function Ot(t){return t in At?At[t]:At[t]="on"+t}function Lt(t,e){var i,n;return!!t.ca||(e=new wt(e,this),i=t.listener,n=t.ia||t.src,t.fa&&Nt(t),i.call(n,e))}function Rt(t){return(t=t[Dt])instanceof Et?t:null}var Ft="__closure_events_fn_"+(1e9*Math.random()>>>0);function zt(e){return"function"==typeof e?e:(e[Ft]||(e[Ft]=function(t){return e.handleEvent(t)}),e[Ft])}function Bt(){q.call(this),this.i=new Et(this),(this.P=this).I=null}function $t(t,e){var i,n=t.I;if(n)for(i=[];n;n=n.I)i.push(n);if(t=t.P,n=e.type||e,"string"==typeof e?e=new bt(e,t):e instanceof bt?e.target=e.target||t:(o=e,rt(e=new bt(n,t),o)),o=!0,i)for(var r=i.length-1;0<=r;r--)var s=e.g=i[r],o=jt(s,n,!0,e)&&o;if(o=jt(s=e.g=t,n,!0,e)&&o,o=jt(s,n,!1,e)&&o,i)for(r=0;r<i.length;r++)o=jt(s=e.g=i[r],n,!1,e)&&o}function jt(t,e,i,n){if(!(e=t.i.g[String(e)]))return!0;e=e.concat();for(var r=!0,s=0;s<e.length;++s){var o,a,l=e[s];l&&!l.ca&&l.capture==i&&(o=l.listener,a=l.ia||l.src,l.fa&&kt(t.i,l),r=!1!==o.call(a,n)&&r)}return r&&!n.defaultPrevented}H(Bt,q),Bt.prototype[xt]=!0,Bt.prototype.removeEventListener=function(t,e,i,n){!function t(e,i,n,r,s){if(Array.isArray(i))for(var o=0;o<i.length;o++)t(e,i[o],n,r,s);else r=L(r)?!!r.capture:!!r,n=zt(n),e&&e[xt]?(e=e.i,(i=String(i).toString())in e.g&&-1<(n=It(o=e.g[i],n,r,s))&&(Ct(o[n]),Array.prototype.splice.call(o,n,1),0==o.length&&(delete e.g[i],e.h--))):(e=e&&Rt(e))&&(i=e.g[i.toString()],(n=(e=-1)<(e=i?It(i,n,r,s):e)?i[e]:null)&&Nt(n))}(this,t,e,i,n)},Bt.prototype.M=function(){if(Bt.Z.M.call(this),this.i){var t,e=this.i;for(t in e.g){for(var i=e.g[t],n=0;n<i.length;n++)Ct(i[n]);delete e.g[t],e.h--}}this.I=null},Bt.prototype.N=function(t,e,i,n){return this.i.add(String(t),e,!1,i,n)},Bt.prototype.O=function(t,e,i,n){return this.i.add(String(t),e,!0,i,n)};var Ht=M.JSON.stringify,qt=(Vt.prototype.add=function(t,e){var i=Ut.get();i.set(t,e),this.h?this.h.next=i:this.g=i,this.h=i},Vt);function Vt(){this.h=this.g=null}var Ut=(Wt.prototype.get=function(){var t;return 0<this.h?(this.h--,t=this.g,this.g=t.next,t.next=null):t=this.i(),t},new Wt(function(){return new Gt},function(t){return t.reset()}));function Wt(t,e){this.i=t,this.j=e,this.h=0,this.g=null}var Kt,Gt=(Yt.prototype.set=function(t,e){this.h=t,this.g=e,this.next=null},Yt.prototype.reset=function(){this.next=this.g=this.h=null},Yt);function Yt(){this.next=this.g=this.h=null}function Xt(t,e){var i;
1Kt||(i=M.Promise.resolve(void 0),Kt=function(){i.then(Zt)}),Qt||(Kt(),Qt=!0),Jt.add(t,e)}var Qt=!1,Jt=new qt;function Zt(){for(var t;e=t=void 0,e=null,(t=Jt).g&&(e=t.g,t.g=t.g.next,t.g||(t.h=null),e.next=null),t=e;){try{t.h.call(t.g)}catch(t){!function(t){M.setTimeout(function(){throw t},0)}(t)}var e=Ut;e.j(t),e.h<100&&(e.h++,t.next=e.g,e.g=t)}Qt=!1}function te(t,e){Bt.call(this),this.h=t||1,this.g=e||M,this.j=$(this.kb,this),this.l=Date.now()}function ee(t){t.da=!1,t.S&&(t.g.clearTimeout(t.S),t.S=null)}function ie(t,e,i){if("function"==typeof t)i&&(t=$(t,i));else{if(!t||"function"!=typeof t.handleEvent)throw Error("Invalid listener argument");t=$(t.handleEvent,t)}return 2147483647<Number(e)?-1:M.setTimeout(t,e||0)}H(te,Bt),(D=te.prototype).da=!1,D.S=null,D.kb=function(){var t;this.da&&(0<(t=Date.now()-this.l)&&t<.8*this.h?this.S=this.g.setTimeout(this.j,this.h-t):(this.S&&(this.g.clearTimeout(this.S),this.S=null),$t(this,"tick"),this.da&&(ee(this),this.start())))},D.start=function(){this.da=!0,this.S||(this.S=this.g.setTimeout(this.j,this.h),this.l=Date.now())},D.M=function(){te.Z.M.call(this),ee(this),delete this.g};var ne,re=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function i(){this.constructor=t}k(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}(se,ne=q),se.prototype.l=function(t){this.h=arguments,this.g?this.i=!0:function t(e){e.g=ie(function(){e.g=null,e.i&&(e.i=!1,t(e))},e.j);var i=e.h;e.h=null,e.m.apply(null,i)}(this)},se.prototype.M=function(){ne.prototype.M.call(this),this.g&&(M.clearTimeout(this.g),this.g=null,this.i=!1,this.h=null)},se);function se(t,e){var i=ne.call(this)||this;return i.m=t,i.j=e,i.h=null,i.i=!1,i.g=null,i}function oe(t){q.call(this),this.h=t,this.g={}}H(oe,q);var ae=[];function le(t,e,i,n){Array.isArray(i)||(i&&(ae[0]=i.toString()),i=ae);for(var r=0;r<i.length;r++){var s=Pt(e,i[r],n||t.handleEvent,!1,t.h||t);if(!s)break;t.g[s.key]=s}}function ue(t){et(t.g,function(t,e){this.g.hasOwnProperty(e)&&Nt(t)},t),t.g={}}function ce(){this.g=!0}function he(t,e,i,n){t.info(function(){return"XMLHTTP TEXT ("+e+"): "+function(t,e){if(!t.g)return e;if(!e)return null;try{var i=JSON.parse(e);if(i)for(t=0;t<i.length;t++)if(Array.isArray(i[t])){var n=i[t];if(!(n.length<2)){var r=n[1];if(Array.isArray(r)&&!(r.length<1)){var s=r[0];if("noop"!=s&&"stop"!=s&&"close"!=s)for(var o=1;o<r.length;o++)r[o]=""}}}return Ht(i)}catch(t){return e}}(t,i)+(n?" "+n:"")})}oe.prototype.M=function(){oe.Z.M.call(this),ue(this)},oe.prototype.handleEvent=function(){throw Error("EventHandler.handleEvent not implemented")},ce.prototype.Aa=function(){this.g=!1},ce.prototype.info=function(){};var de={},pe=null;function fe(){return pe=pe||new Bt}function ge(t){bt.call(this,de.Ma,t)}function me(){var t=fe();$t(t,new ge(t))}function ve(t,e){bt.call(this,de.STAT_EVENT,t),this.stat=e}function ye(t){var e=fe();$t(e,new ve(e,t))}function be(t,e){bt.call(this,de.Na,t),this.size=e}function we(t,e){if("function"!=typeof t)throw Error("Fn must not be null and must be a function");return M.setTimeout(function(){t()},e)}de.Ma="serverreachability",H(ge,bt),de.STAT_EVENT="statevent",H(ve,bt),de.Na="timingevent",H(be,bt);var _e={NO_ERROR:0,lb:1,yb:2,xb:3,sb:4,wb:5,zb:6,Ja:7,TIMEOUT:8,Cb:9};A={qb:"complete",Mb:"success",Ka:"error",Ja:"abort",Eb:"ready",Fb:"readystatechange",TIMEOUT:"timeout",Ab:"incrementaldata",Db:"progress",tb:"downloadprogress",Ub:"uploadprogress"};function xe(){}function Te(t){return t.h||(t.h=t.i())}function Se(){}function Ce(){bt.call(this,"d")}function Ee(){bt.call(this,"c")}function ke(){}function Ie(t,e,i,n){this.l=t,this.j=e,this.m=i,this.X=n||1,this.V=new oe(this),this.P=Pe,this.W=new te(t=ct?125:void 0),this.H=null,this.i=!1,this.s=this.A=this.v=this.K=this.F=this.Y=this.B=null,this.D=[],this.g=null,this.C=0,this.o=this.u=null,this.N=-1,this.I=!1,this.O=0,this.L=null,this.aa=this.J=this.$=this.U=!1,this.h=new De}function De(){this.i=null,this.g="",this.h=!1}xe.prototype.h=null,qt={OPEN:"a",pb:"b",Ka:"c",Bb:"d"},H(Ce,bt),H(Ee,bt),H(ke,xe),ke.prototype.g=function(){return new XMLHttpRequest},ke.prototype.i=function(){return{}};var Ae=new ke,Pe=45e3,Me={},Ne={};function Oe(t,e,i){t.K=1,t.v=ii(Xe(e)),t.s=i,t.U=!0,Le(t,null)}function Le(t,e){t.F=Date.now(),ze(t),t.A=Xe(t.v);var o,a,l,u,c,h,i=t.A,n=t.X;Array.isArray(n)||(n=[String(n)]),gi(i.h,"t",n),t.C=0,i=t.l.H,t.h=new De,t.g=vn(t.l,i?e:null,!t.s),0<t.O&&(t.L=new re($(t.Ia,t,t.g),t.O)),le(t.V,t.g,"readystatechange",t.gb),e=t.H?it(t.H):{},t.s?(t.u||(t.u="POST"),e["Content-Type"]="application/x-www-form-urlencoded",t.g.ea(t.A,t.u,t.s,e)):(t.u="GET",t.g.ea(t.A,t.u,null,e)),me(),o=t.j,a=t.u,l=t.A,u=t.m,c=t.X,h=t.s,o.info(function(){if(o.g)if(h)for(var t="",e=h.split("&"),i=0;i<e.length;i++){var n,r,s=e[i].split("=");1<s.length&&(n=s[0],s=s[1],t=2<=(r=n.split("_")).length&&"type"==r[1]?t+(n+"=")+s+"&":t+(n+"=redacted&"))}else t=null;else t=h;return"XMLHTTP REQ ("+u+") [attempt "+c+"]: "+a+"\n"+l+"\n"+t})}function Re(t){return t.g&&"GET"==t.u&&2!=t.K&&t.l.Ba}function Fe(t,e,i){for(var n,r,s,o,a,l=!0;!t.I&&t.C<i.length;){if(s=i,a=o=void 0,o=(r=t).C,(n=-1==(a=s.indexOf("\n",o))?Ne:(o=Number(s.substring(o,a)),isNaN(o)?Me:(a+=1)+o>s.length?Ne:(s=s.substr(a,o),r.C=a+o,s)))==Ne){4==e&&(t.o=4,ye(14),l=!1),he(t.j,t.m,null,"[Incomplete Response]");break}if(n==Me){t.o=4,ye(15),he(t.j,t.m,i,"[Invalid Chunk]"),l=!1;break}he(t.j,t.m,n,null),qe(t,n)}Re(t)&&n!=Ne&&n!=Me&&(t.h.g="",t.C=0),4!=e||0!=i.length||t.h.h||(t.o=1,ye(16),l=!1),t.i=t.i&&l,l?0<i.length&&!t.aa&&(t.aa=!0,(e=t.l).g==t&&e.$&&!e.L&&(e.h.info("Great, no buffering proxy detected. Bytes received: "+i.length),un(e),e.L=!0,ye(11))):(he(t.j,t.m,i,"[Invalid Chunked Response]"),He(t),je(t))}function ze(t){t.Y=Date.now()+t.P,Be(t,t.P)}function Be(t,e){if(null!=t.B)throw Error("WatchDog timer not null");t.B=we($(t.eb,t),e)}function $e(t){t.B&&(M.clearTimeout(t.B),t.B=null)}function je(t){0==t.l.G||t.I||dn(t.l,t)}function He(t){$e(t);var e=t.L;e&&"function"==typeof e.na&&e.na(),t.L=null,ee(t.W),ue(t.V),t.g&&(e=t.g,t.g=null,e.abort(),e.na())}function qe(t,e){try{var i=t.l;if(0!=i.G&&(i.g==t||Ti(i.i,t)))if(i.I=t.N,!t.J&&Ti(i.i,t)&&3==i.G){try{var n=i.Ca.g.parse(e)}catch(g){n=null}if(Array.isArray(n)&&3==n.length){var r=n;if(0==r[0]){t:if(!i.u){if(i.g){if(!(i.g.F+3e3<t.F))break t;hn(i),Zi(i)}ln(i),ye(18)}}else i.ta=r[1],0<i.ta-i.U&&r[2]<37500&&i.N&&0==i.A&&!i.v&&(i.v=we($(i.ab,i),6e3));if(xi(i.i)<=1&&i.ka){try{i.ka()}catch(g){}i.ka=void 0}}else fn(i,11)}else if(!t.J&&i.g!=t||hn(i),!Y(e))for(r=i.Ca.g.parse(e),e=0;e<r.length;e++){var s,o,a,l,u,c,h,d,p,f,g=r[e];i.U=g[0],g=g[1],2==i.G?"c"==g[0]?(i.J=g[1],i.la=g[2],null!=(s=g[3])&&(i.ma=s,i.h.info("VER="+i.ma)),null!=(o=g[4])&&(i.za=o,i.h.info("SVER="+i.za)),null!=(a=g[5])&&"number"==typeof a&&0<a&&(n=1.5*a,i.K=n,i.h.info("backChannelRequestTimeoutMs_="+n)),n=i,(l=t.g)&&(!(u=l.g?l.g.getResponseHeader("X-Client-Wire-Protocol"):null)||!(c=n.i).g&&(J(u,"spdy")||J(u,"quic")||J(u,"h2"))&&(c.j=c.l,c.g=new Set,c.h&&(Si(c,c.h),c.h=null)),!n.D||(h=l.g?l.g.getResponseHeader("X-HTTP-Session-Id"):null)&&(n.sa=h,ei(n.F,n.D,h))),i.G=3,i.j&&i.j.xa(),i.$&&(i.O=Date.now()-t.F,i.h.info("Handshake RTT: "+i.O+"ms")),d=t,(n=i).oa=mn(n,n.H?n.la:null,n.W),d.J?(Ci(n.i,d),p=d,(f=n.K)&&p.setTimeout(f),p.B&&($e(p),ze(p)),n.g=d):an(n),0<i.l.length&&nn(i)):"stop"
1!=g[0]&&"close"!=g[0]||fn(i,7):3==i.G&&("stop"==g[0]||"close"==g[0]?"stop"==g[0]?fn(i,7):Ji(i):"noop"!=g[0]&&i.j&&i.j.wa(g),i.A=0)}me()}catch(g){}}function Ve(t,e){if(t.forEach&&"function"==typeof t.forEach)t.forEach(e,void 0);else if(O(t)||"string"==typeof t)W(t,e,void 0);else{if(t.T&&"function"==typeof t.T)var i=t.T();else if(t.R&&"function"==typeof t.R)i=void 0;else if(O(t)||"string"==typeof t){i=[];for(var n=t.length,r=0;r<n;r++)i.push(r)}else for(r in i=[],n=0,t)i[n++]=r;r=(n=function(t){if(t.R&&"function"==typeof t.R)return t.R();if("string"==typeof t)return t.split("");if(O(t)){for(var e=[],i=t.length,n=0;n<i;n++)e.push(t[n]);return e}for(n in e=[],i=0,t)e[i++]=t[n];return e}(t)).length;for(var s=0;s<r;s++)e.call(void 0,n[s],i&&i[s],t)}}function Ue(t,e){this.h={},this.g=[],this.i=0;var i=arguments.length;if(1<i){if(i%2)throw Error("Uneven number of arguments");for(var n=0;n<i;n+=2)this.set(arguments[n],arguments[n+1])}else if(t)if(t instanceof Ue)for(i=t.T(),n=0;n<i.length;n++)this.set(i[n],t.get(i[n]));else for(n in t)this.set(n,t[n])}function We(t){if(t.i!=t.g.length){for(var e=0,i=0;e<t.g.length;){var n=t.g[e];Ke(t.h,n)&&(t.g[i++]=n),e++}t.g.length=i}if(t.i!=t.g.length){var r={};for(i=e=0;e<t.g.length;)Ke(r,n=t.g[e])||(r[t.g[i++]=n]=1),e++;t.g.length=i}}function Ke(t,e){return Object.prototype.hasOwnProperty.call(t,e)}(D=Ie.prototype).setTimeout=function(t){this.P=t},D.gb=function(t){t=t.target;var e=this.L;e&&3==Ki(t)?e.l():this.Ia(t)},D.Ia=function(t){try{if(t==this.g)t:{var e=Ki(this.g),i=this.g.Da();if(this.g.ba(),!(e<3)&&(3!=e||ct||this.g&&(this.h.h||this.g.ga()||Gi(this.g)))){this.I||4!=e||7==i||me(),$e(this);var n=this.g.ba();this.N=n;e:if(Re(this)){var r=Gi(this.g);t="";var s=r.length,o=4==Ki(this.g);if(!this.h.i){if("undefined"==typeof TextDecoder){He(this),je(this);var a="";break e}this.h.i=new M.TextDecoder}for(i=0;i<s;i++)this.h.h=!0,t+=this.h.i.decode(r[i],{stream:o&&i==s-1});r.splice(0,s),this.h.g+=t,this.C=0,a=this.h.g}else a=this.g.ga();if(this.i=200==n,h=this.j,d=this.u,p=this.A,f=this.m,g=this.X,m=e,v=n,h.info(function(){return"XMLHTTP RESP ("+f+") [ attempt "+g+"]: "+d+"\n"+p+"\n"+m+" "+v}),this.i){if(this.$&&!this.J){e:{if(this.g){var l,u=this.g;if((l=u.g?u.g.getResponseHeader("X-HTTP-Initial-Response"):null)&&!Y(l)){var c=l;break e}}c=null}if(!(n=c)){this.i=!1,this.o=3,ye(12),He(this),je(this);break t}he(this.j,this.m,n,"Initial handshake response via X-HTTP-Initial-Response"),this.J=!0,qe(this,n)}this.U?(Fe(this,e,a),ct&&this.i&&3==e&&(le(this.V,this.W,"tick",this.fb),this.W.start())):(he(this.j,this.m,a,null),qe(this,a)),4==e&&He(this),this.i&&!this.I&&(4==e?dn(this.l,this):(this.i=!1,ze(this)))}else 400==n&&0<a.indexOf("Unknown SID")?(this.o=3,ye(12)):(this.o=0,ye(13)),He(this),je(this)}}}catch(e){}var h,d,p,f,g,m,v},D.fb=function(){var t,e;this.g&&(t=Ki(this.g),e=this.g.ga(),this.C<e.length&&($e(this),Fe(this,t,e),this.i&&4!=t&&ze(this)))},D.cancel=function(){this.I=!0,He(this)},D.eb=function(){this.B=null;var t,e,i=Date.now();0<=i-this.Y?(t=this.j,e=this.A,t.info(function(){return"TIMEOUT: "+e}),2!=this.K&&(me(),ye(17)),He(this),this.o=2,je(this)):Be(this,this.Y-i)},(D=Ue.prototype).R=function(){We(this);for(var t=[],e=0;e<this.g.length;e++)t.push(this.h[this.g[e]]);return t},D.T=function(){return We(this),this.g.concat()},D.get=function(t,e){return Ke(this.h,t)?this.h[t]:e},D.set=function(t,e){Ke(this.h,t)||(this.i++,this.g.push(t)),this.h[t]=e},D.forEach=function(t,e){for(var i=this.T(),n=0;n<i.length;n++){var r=i[n],s=this.get(r);t.call(e,s,r,this)}};var Ge=/^(?:([^:/?#.]+):)?(?:\/\/(?:([^\\/?#]*)@)?([^\\/?#]*?)(?::([0-9]+))?(?=[\\/?#]|$))?([^?#]+)?(?:\?([^#]*))?(?:#([\s\S]*))?$/;function Ye(t,e){var i;this.i=this.s=this.j="",this.m=null,this.o=this.l="",this.g=!1,t instanceof Ye?(this.g=void 0!==e?e:t.g,Qe(this,t.j),this.s=t.s,Je(this,t.i),Ze(this,t.m),this.l=t.l,e=t.h,(i=new hi).i=e.i,e.g&&(i.g=new Ue(e.g),i.h=e.h),ti(this,i),this.o=t.o):t&&(i=String(t).match(Ge))?(this.g=!!e,Qe(this,i[1]||"",!0),this.s=ni(i[2]||""),Je(this,i[3]||"",!0),Ze(this,i[4]),this.l=ni(i[5]||"",!0),ti(this,i[6]||"",!0),this.o=ni(i[7]||"")):(this.g=!!e,this.h=new hi(null,this.g))}function Xe(t){return new Ye(t)}function Qe(t,e,i){t.j=i?ni(e,!0):e,t.j&&(t.j=t.j.replace(/:$/,""))}function Je(t,e,i){t.i=i?ni(e,!0):e}function Ze(t,e){if(e){if(e=Number(e),isNaN(e)||e<0)throw Error("Bad port number "+e);t.m=e}else t.m=null}function ti(t,e,i){var n,r;e instanceof hi?(t.h=e,n=t.h,(r=t.g)&&!n.j&&(di(n),n.i=null,n.g.forEach(function(t,e){var i=e.toLowerCase();e!=i&&(pi(this,e),gi(this,i,t))},n)),n.j=r):(i||(e=ri(e,ui)),t.h=new hi(e,t.g))}function ei(t,e,i){t.h.set(e,i)}function ii(t){return ei(t,"zx",Math.floor(2147483648*Math.random()).toString(36)+Math.abs(Math.floor(2147483648*Math.random())^Date.now()).toString(36)),t}function ni(t,e){return t?e?decodeURI(t.replace(/%25/g,"%2525")):decodeURIComponent(t):""}function ri(t,e,i){return"string"==typeof t?(t=encodeURI(t).replace(e,si),t=i?t.replace(/%25([0-9a-fA-F]{2})/g,"%$1"):t):null}function si(t){return"%"+((t=t.charCodeAt(0))>>4&15).toString(16)+(15&t).toString(16)}Ye.prototype.toString=function(){var t=[],e=this.j;e&&t.push(ri(e,oi,!0),":");var i=this.i;
1return!i&&"file"!=e||(t.push("//"),(e=this.s)&&t.push(ri(e,oi,!0),"@"),t.push(encodeURIComponent(String(i)).replace(/%25([0-9a-fA-F]{2})/g,"%$1")),null!=(i=this.m)&&t.push(":",String(i))),(i=this.l)&&(this.i&&"/"!=i.charAt(0)&&t.push("/"),t.push(ri(i,"/"==i.charAt(0)?li:ai,!0))),(i=this.h.toString())&&t.push("?",i),(i=this.o)&&t.push("#",ri(i,ci)),t.join("")};var oi=/[#\/\?@]/g,ai=/[#\?:]/g,li=/[#\?]/g,ui=/[#\?@]/g,ci=/#/g;function hi(t,e){this.h=this.g=null,this.i=t||null,this.j=!!e}function di(l){l.g||(l.g=new Ue,l.h=0,l.i&&function(t,e){if(t){t=t.split("&");for(var i=0;i<t.length;i++){var n,r=t[i].indexOf("="),s=null;0<=r?(n=t[i].substring(0,r),s=t[i].substring(r+1)):n=t[i],o=n,a=s?decodeURIComponent(s.replace(/\+/g," ")):"",l.add(decodeURIComponent(o.replace(/\+/g," ")),a)}}var o,a}(l.i))}function pi(t,e){di(t),e=mi(t,e),Ke(t.g.h,e)&&(t.i=null,t.h-=t.g.get(e).length,Ke((t=t.g).h,e)&&(delete t.h[e],t.i--,t.g.length>2*t.i&&We(t)))}function fi(t,e){return di(t),e=mi(t,e),Ke(t.g.h,e)}function gi(t,e,i){pi(t,e),0<i.length&&(t.i=null,t.g.set(mi(t,e),G(i)),t.h+=i.length)}function mi(t,e){return e=String(e),t.j?e.toLowerCase():e}(D=hi.prototype).add=function(t,e){di(this),this.i=null,t=mi(this,t);var i=this.g.get(t);return i||this.g.set(t,i=[]),i.push(e),this.h+=1,this},D.forEach=function(i,n){di(this),this.g.forEach(function(t,e){W(t,function(t){i.call(n,t,e,this)},this)},this)},D.T=function(){di(this);for(var t=this.g.R(),e=this.g.T(),i=[],n=0;n<e.length;n++)for(var r=t[n],s=0;s<r.length;s++)i.push(e[n]);return i},D.R=function(t){di(this);var e=[];if("string"==typeof t)fi(this,t)&&(e=K(e,this.g.get(mi(this,t))));else{t=this.g.R();for(var i=0;i<t.length;i++)e=K(e,t[i])}return e},D.set=function(t,e){return di(this),this.i=null,fi(this,t=mi(this,t))&&(this.h-=this.g.get(t).length),this.g.set(t,[e]),this.h+=1,this},D.get=function(t,e){return t&&0<(t=this.R(t)).length?String(t[0]):e},D.toString=function(){if(this.i)return this.i;if(!this.g)return"";for(var t=[],e=this.g.T(),i=0;i<e.length;i++)for(var n=e[i],r=encodeURIComponent(String(n)),s=(n=this.R(n),0);s<n.length;s++){var o=r;""!==n[s]&&(o+="="+encodeURIComponent(String(n[s]))),t.push(o)}return this.i=t.join("&")};var vi=function(t,e){this.h=t,this.g=e};function yi(t){this.l=t||wi,t=M.PerformanceNavigationTiming?0<(t=M.performance.getEntriesByType("navigation")).length&&("hq"==t[0].nextHopProtocol||"h2"==t[0].nextHopProtocol):!!(M.g&&M.g.Ea&&M.g.Ea()&&M.g.Ea().Zb),this.j=t?this.l:1,this.g=null,1<this.j&&(this.g=new Set),this.h=null,this.i=[]}var bi,wi=10;function _i(t){return t.h||t.g&&t.g.size>=t.j}function xi(t){return t.h?1:t.g?t.g.size:0}function Ti(t,e){return t.h?t.h==e:t.g&&t.g.has(e)}function Si(t,e){t.g?t.g.add(e):t.h=e}function Ci(t,e){t.h&&t.h==e?t.h=null:t.g&&t.g.has(e)&&t.g.delete(e)}function Ei(t){var e,i;if(null!=t.h)return t.i.concat(t.h.D);if(null==t.g||0===t.g.size)return G(t.i);var n=t.i;try{for(var r=I(t.g.values()),s=r.next();!s.done;s=r.next()){var o=s.value;n=n.concat(o.D)}}catch(t){e={error:t}}finally{try{s&&!s.done&&(i=r.return)&&i.call(r)}finally{if(e)throw e.error}}return n}function ki(){}function Ii(){this.g=new ki}function Di(t,e,i,n,r){try{e.onload=null,e.onerror=null,e.onabort=null,e.ontimeout=null,r(n)}catch(t){}}function Ai(t){this.l=t.$b||null,this.j=t.ib||!1}function Pi(t,e){Bt.call(this),this.D=t,this.u=e,this.m=void 0,this.readyState=Mi,this.status=0,this.responseType=this.responseText=this.response=this.statusText="",this.onreadystatechange=null,this.v=new Headers,this.h=null,this.C="GET",this.B="",this.g=!1,this.A=this.j=this.l=null}yi.prototype.cancel=function(){var t,e;if(this.i=Ei(this),this.h)this.h.cancel(),this.h=null;else if(this.g&&0!==this.g.size){try{for(var i=I(this.g.values()),n=i.next();!n.done;n=i.next())n.value.cancel()}catch(e){t={error:e}}finally{try{n&&!n.done&&(e=i.return)&&e.call(i)}finally{if(t)throw t.error}}this.g.clear()}},ki.prototype.stringify=function(t){return M.JSON.stringify(t,void 0)},ki.prototype.parse=function(t){return M.JSON.parse(t,void 0)},H(Ai,xe),Ai.prototype.g=function(){return new Pi(this.l,this.j)},Ai.prototype.i=(bi={},function(){return bi}),H(Pi,Bt);var Mi=0;function Ni(t){t.j.read().then(t.Sa.bind(t)).catch(t.ha.bind(t))}function Oi(t){t.readyState=4,t.l=null,t.j=null,t.A=null,Li(t)}function Li(t){t.onreadystatechange&&t.onreadystatechange.call(t)}(D=Pi.prototype).open=function(t,e){if(this.readyState!=Mi)throw this.abort(),Error("Error reopening a connection");this.C=t,this.B=e,this.readyState=1,Li(this)},D.send=function(t){if(1!=this.readyState)throw this.abort(),Error("need to call open() first. ");this.g=!0;var e={headers:this.v,method:this.C,credentials:this.m,cache:void 0};
1t&&(e.body=t),(this.D||M).fetch(new Request(this.B,e)).then(this.Va.bind(this),this.ha.bind(this))},D.abort=function(){this.response=this.responseText="",this.v=new Headers,this.status=0,this.j&&this.j.cancel("Request was aborted."),1<=this.readyState&&this.g&&4!=this.readyState&&(this.g=!1,Oi(this)),this.readyState=Mi},D.Va=function(t){if(this.g&&(this.l=t,this.h||(this.status=this.l.status,this.statusText=this.l.statusText,this.h=t.headers,this.readyState=2,Li(this)),this.g&&(this.readyState=3,Li(this),this.g)))if("arraybuffer"===this.responseType)t.arrayBuffer().then(this.Ta.bind(this),this.ha.bind(this));else if(void 0!==M.ReadableStream&&"body"in t){if(this.j=t.body.getReader(),this.u){if(this.responseType)throw Error('responseType must be empty for "streamBinaryChunks" mode responses.');this.response=[]}else this.response=this.responseText="",this.A=new TextDecoder;Ni(this)}else t.text().then(this.Ua.bind(this),this.ha.bind(this))},D.Sa=function(t){var e;this.g&&(this.u&&t.value?this.response.push(t.value):this.u||(e=t.value||new Uint8Array(0),(e=this.A.decode(e,{stream:!t.done}))&&(this.response=this.responseText+=e)),(t.done?Oi:Li)(this),3==this.readyState&&Ni(this))},D.Ua=function(t){this.g&&(this.response=this.responseText=t,Oi(this))},D.Ta=function(t){this.g&&(this.response=t,Oi(this))},D.ha=function(){this.g&&Oi(this)},D.setRequestHeader=function(t,e){this.v.append(t,e)},D.getResponseHeader=function(t){return this.h&&this.h.get(t.toLowerCase())||""},D.getAllResponseHeaders=function(){if(!this.h)return"";for(var t=[],e=this.h.entries(),i=e.next();!i.done;)i=i.value,t.push(i[0]+": "+i[1]),i=e.next();return t.join("\r\n")},Object.defineProperty(Pi.prototype,"withCredentials",{get:function(){return"include"===this.m},set:function(t){this.m=t?"include":"same-origin"}});var Ri=M.JSON.parse;function Fi(t){Bt.call(this),this.headers=new Ue,this.u=t||null,this.h=!1,this.C=this.g=null,this.H="",this.m=0,this.j="",this.l=this.F=this.v=this.D=!1,this.B=0,this.A=null,this.J=zi,this.K=this.L=!1}H(Fi,Bt);var zi="",Bi=/^https?$/i,$i=["POST","PUT"];function ji(t){return"content-type"==t.toLowerCase()}function Hi(t,e){t.h=!1,t.g&&(t.l=!0,t.g.abort(),t.l=!1),t.j=e,t.m=5,qi(t),Ui(t)}function qi(t){t.D||(t.D=!0,$t(t,"complete"),$t(t,"error"))}function Vi(t){if(t.h&&void 0!==P&&(!t.C[1]||4!=Ki(t)||2!=t.ba()))if(t.v&&4==Ki(t))ie(t.Fa,0,t);else if($t(t,"readystatechange"),4==Ki(t)){t.h=!1;try{var e,i,n,r,s=t.ba();t:switch(s){case 200:case 201:case 202:case 204:case 206:case 304:case 1223:var o=!0;break t;default:o=!1}if((e=o)||((i=0===s)&&(!(r=String(t.H).match(Ge)[1]||null)&&M.self&&M.self.location&&(r=(n=M.self.location.protocol).substr(0,n.length-1)),i=!Bi.test(r?r.toLowerCase():"")),e=i),e)$t(t,"complete"),$t(t,"success");else{t.m=6;try{var a=2<Ki(t)?t.g.statusText:""}catch(t){a=""}t.j=a+" ["+t.ba()+"]",qi(t)}}finally{Ui(t)}}}function Ui(t,e){if(t.g){Wi(t);var i=t.g,n=t.C[0]?N:null;t.g=null,t.C=null,e||$t(t,"ready");try{i.onreadystatechange=n}catch(t){}}}function Wi(t){t.g&&t.K&&(t.g.ontimeout=null),t.A&&(M.clearTimeout(t.A),t.A=null)}function Ki(t){return t.g?t.g.readyState:0}function Gi(t){try{if(!t.g)return null;if("response"in t.g)return t.g.response;switch(t.J){case zi:case"text":return t.g.responseText;case"arraybuffer":if("mozResponseArrayBuffer"in t.g)return t.g.mozResponseArrayBuffer}return null}catch(t){return null}}function Yi(t,e,i){t:{for(n in i){var n=!1;break t}n=!0}var r;n||(r="",et(i,function(t,e){r+=e,r+=":",r+=t,r+="\r\n"}),i=r,"string"==typeof t?null!=i&&encodeURIComponent(String(i)):ei(t,e,i))}function Xi(t,e,i){return i&&i.internalChannelParams&&i.internalChannelParams[t]||e}function Qi(t){this.za=0,this.l=[],this.h=new ce,this.la=this.oa=this.F=this.W=this.g=this.sa=this.D=this.aa=this.o=this.P=this.s=null,this.Za=this.V=0,this.Xa=Xi("failFast",!1,t),this.N=this.v=this.u=this.m=this.j=null,this.X=!0,this.I=this.ta=this.U=-1,this.Y=this.A=this.C=0,this.Pa=Xi("baseRetryDelayMs",5e3,t),this.$a=Xi("retryDelaySeedMs",1e4,t),this.Ya=Xi("forwardChannelMaxRetries",2,t),this.ra=Xi("forwardChannelRequestTimeoutMs",2e4,t),this.qa=t&&t.xmlHttpFactory||void 0,this.Ba=t&&t.Yb||!1,this.K=void 0,this.H=t&&t.supportsCrossDomainXhr||!1,this.J="",this.i=new yi(t&&t.concurrentRequestLimit),this.Ca=new Ii,this.ja=t&&t.fastHandshake||!1,this.Ra=t&&t.Wb||!1,t&&t.Aa&&this.h.Aa(),t&&t.forceLongPolling&&(this.X=!1),this.$=!this.ja&&this.X&&t&&t.detectBufferingProxy||!1,this.ka=void 0,this.O=0,this.L=!1,this.B=null,this.Wa=!t||!1!==t.Xb}function Ji(t){var e,i;tn(t),3==t.G&&(e=t.V++,ei(i=Xe(t.F),"SID",t.J),ei(i,"RID",e),ei(i,"TYPE","terminate"),sn(t,i),(e=new Ie(t,t.h,e,void 0)).K=2,e.v=ii(Xe(i)),i=!1,!(i=M.navigator&&M.navigator.sendBeacon?M.navigator.sendBeacon(e.v.toString(),""):i)&&M.Image&&((new Image).src=e.v,i=!0),i||(e.g=vn(e.l,null),e.g.ea(e.v)),e.F=Date.now(),ze(e)),gn(t)}function Zi(t){t.g&&(un(t),t.g.cancel(),t.g=null)}function tn(t){Zi(t),t.u&&(M.clearTimeout(t.u),t.u=null),hn(t),t.i.cancel(),t.m&&("number"==typeof t.m&&M.clearTimeout(t.m),t.m=null)}function en(t,e){t.l.push(new vi(t.Za++,e)),3==t.G&&nn(t)}function nn(t){_i(t.i)||t.m||(t.m=!0,Xt(t.Ha,t),t.C=0)}function rn(t,e){var i=e?e.m:t.V++,n=Xe(t.F);ei(n,"SID",t.J),ei(n,"RID",i),ei(n,"AID",t.U),sn(t,n),t.o&&t.s&&Yi(n,t.o,t.s),i=new Ie(t,t.h,i,t.C+1),null===t.o&&(i.H=t.s),e&&(t.l=e.D.concat(t.l)),e=on(t,i,1e3),i.setTimeout(
1Math.round(.5*t.ra)+Math.round(.5*t.ra*Math.random())),Si(t.i,i),Oe(i,n,e)}function sn(t,i){t.j&&Ve({},function(t,e){ei(i,e,t)})}function on(t,e,i){i=Math.min(t.l.length,i);var n=t.j?$(t.j.Oa,t.j,t):null;t:for(var r=t.l,s=-1;;){var o=["count="+i];-1==s?0<i?(s=r[0].h,o.push("ofs="+s)):s=0:o.push("ofs="+s);for(var a=!0,l=0;l<i;l++){var u=r[l].h,c=r[l].g;if((u-=s)<0)s=Math.max(0,r[l].h-100),a=!1;else try{!function(t,n,e){var r="req"+u+"_"||"";try{Ve(t,function(t,e){var i=t;L(t)&&(i=Ht(t)),n.push(r+e+"="+encodeURIComponent(i))})}catch(t){throw n.push(r+"type="+encodeURIComponent("_badmap")),t}}(c,o)}catch(t){n&&n(c)}}if(a){n=o.join("&");break t}}return t=t.l.splice(0,i),e.D=t,n}function an(t){t.g||t.u||(t.Y=1,Xt(t.Ga,t),t.A=0)}function ln(t){return!(t.g||t.u||3<=t.A)&&(t.Y++,t.u=we($(t.Ga,t),pn(t,t.A)),t.A++,1)}function un(t){null!=t.B&&(M.clearTimeout(t.B),t.B=null)}function cn(t){t.g=new Ie(t,t.h,"rpc",t.Y),null===t.o&&(t.g.H=t.s),t.g.O=0;var e=Xe(t.oa);ei(e,"RID","rpc"),ei(e,"SID",t.J),ei(e,"CI",t.N?"0":"1"),ei(e,"AID",t.U),sn(t,e),ei(e,"TYPE","xmlhttp"),t.o&&t.s&&Yi(e,t.o,t.s),t.K&&t.g.setTimeout(t.K);var i=t.g;t=t.la,i.K=1,i.v=ii(Xe(e)),i.s=null,i.U=!0,Le(i,t)}function hn(t){null!=t.v&&(M.clearTimeout(t.v),t.v=null)}function dn(t,e){var i,n,r,s=null;if(t.g==e){hn(t),un(t),t.g=null;var o=2}else{if(!Ti(t.i,e))return;s=e.D,Ci(t.i,e),o=1}if(t.I=e.N,0!=t.G)if(e.i)1==o?(s=e.s?e.s.length:0,e=Date.now()-e.F,i=t.C,$t(o=fe(),new be(o,s)),nn(t)):an(t);else if(3==(i=e.o)||0==i&&0<t.I||(1!=o||(r=e,xi((n=t).i)>=n.i.j-(n.m?1:0)||(n.m?(n.l=r.D.concat(n.l),0):1==n.G||2==n.G||n.C>=(n.Xa?0:n.Ya)||(n.m=we($(n.Ha,n,r),pn(n,n.C)),n.C++,0))))&&(2!=o||!ln(t)))switch(s&&0<s.length&&(e=t.i,e.i=e.i.concat(s)),i){case 1:fn(t,5);break;case 4:fn(t,10);break;case 3:fn(t,6);break;default:fn(t,2)}}function pn(t,e){var i=t.Pa+Math.floor(Math.random()*t.$a);return t.j||(i*=2),i*e}function fn(t,e){var i,n,r,s;t.h.info("Error code "+e),2==e?(n=null,t.j&&(n=null),s=$(t.jb,t),n||(n=new Ye("//www.google.com/images/cleardot.gif"),M.location&&"http"==M.location.protocol||Qe(n,"https"),ii(n)),i=n.toString(),n=s,s=new ce,M.Image?((r=new Image).onload=j(Di,s,r,"TestLoadImage: loaded",!0,n),r.onerror=j(Di,s,r,"TestLoadImage: error",!1,n),r.onabort=j(Di,s,r,"TestLoadImage: abort",!1,n),r.ontimeout=j(Di,s,r,"TestLoadImage: timeout",!1,n),M.setTimeout(function(){r.ontimeout&&r.ontimeout()},1e4),r.src=i):n(!1)):ye(2),t.G=0,t.j&&t.j.va(e),gn(t),tn(t)}function gn(t){t.G=0,t.I=-1,t.j&&(0==Ei(t.i).length&&0==t.l.length||(t.i.i.length=0,G(t.l),t.l.length=0),t.j.ua())}function mn(t,e,i){var n,r,s,o,a,l=(o=i)instanceof Ye?Xe(o):new Ye(o,void 0);return""!=l.i?(e&&Je(l,e+"."+l.i),Ze(l,l.m)):(n=(a=M.location).protocol,r=e?e+"."+a.hostname:a.hostname,s=+a.port,o=i,a=new Ye(null,void 0),n&&Qe(a,n),r&&Je(a,r),s&&Ze(a,s),o&&(a.l=o),l=a),t.aa&&et(t.aa,function(t,e){ei(l,e,t)}),e=t.D,i=t.sa,e&&i&&ei(l,e,i),ei(l,"VER",t.ma),sn(t,l),l}function vn(t,e,i){if(e&&!t.H)throw Error("Can't create secondary domain capable XhrIo object.");return(e=i&&t.Ba&&!t.qa?new Fi(new Ai({ib:!0})):new Fi(t.qa)).L=t.H,e}function yn(){}function bn(){if(lt&&!(10<=Number(vt)))throw Error("Environmental error: no available transport.")}function wn(t,e){Bt.call(this),this.g=new Qi(e),this.l=t,this.h=e&&e.messageUrlParams||null,t=e&&e.messageHeaders||null,e&&e.clientProtocolHeaderRequired&&(t?t["X-Client-Protocol"]="webchannel":t={"X-Client-Protocol":"webchannel"}),this.g.s=t,t=e&&e.initMessageHeaders||null,e&&e.messageContentType&&(t?t["X-WebChannel-Content-Type"]=e.messageContentType:t={"X-WebChannel-Content-Type":e.messageContentType}),e&&e.ya&&(t?t["X-WebChannel-Client-Profile"]=e.ya:t={"X-WebChannel-Client-Profile":e.ya}),this.g.P=t,(t=e&&e.httpHeadersOverwriteParam)&&!Y(t)&&(this.g.o=t),this.A=e&&e.supportsCrossDomainXhr||!1,this.v=e&&e.sendRawJson||!1,(e=e&&e.httpSessionIdParam)&&!Y(e)&&(this.g.D=e,null!==(t=this.h)&&e in t&&e in(t=this.h)&&delete t[e]),this.j=new Tn(this)}function _n(t){Ce.call(this);var e=t.__sm__;if(e){t:{for(var i in e){t=i;break t}t=void 0}(this.i=t)&&(t=this.i,e=null!==e&&t in e?e[t]:void 0),this.data=e}else this.data=t}function xn(){Ee.call(this),this.status=1}function Tn(t){this.g=t}
1(D=Fi.prototype).ea=function(t,e,i,n){if(this.g)throw Error("[goog.net.XhrIo] Object is active with another request="+this.H+"; newUri="+t);e=e?e.toUpperCase():"GET",this.H=t,this.j="",this.m=0,this.D=!1,this.h=!0,this.g=(this.u||Ae).g(),this.C=this.u?Te(this.u):Te(Ae),this.g.onreadystatechange=$(this.Fa,this);try{this.F=!0,this.g.open(e,String(t),!0),this.F=!1}catch(t){return void Hi(this,t)}t=i||"";var r,s,o,a=new Ue(this.headers);n&&Ve(n,function(t,e){a.set(e,t)}),n=function(t){t:{for(var e=ji,i=t.length,n="string"==typeof t?t.split(""):t,r=0;r<i;r++)if(r in n&&e.call(void 0,n[r],r,t)){e=r;break t}e=-1}return e<0?null:"string"==typeof t?t.charAt(e):t[e]}(a.T()),i=M.FormData&&t instanceof M.FormData,0<=U($i,e)&&!n&&!i&&a.set("Content-Type","application/x-www-form-urlencoded;charset=utf-8"),a.forEach(function(t,e){this.g.setRequestHeader(e,t)},this),this.J&&(this.g.responseType=this.J),"withCredentials"in this.g&&this.g.withCredentials!==this.L&&(this.g.withCredentials=this.L);try{Wi(this),0<this.B&&((this.K=(r=this.g,lt&&(s=function(){for(var t=0,e=Q(String(ot)).split("."),i=Q("9").split("."),n=Math.max(e.length,i.length),r=0;0==t&&r<n;r++)for(var s=e[r]||"",o=i[r]||"";s=/(\d*)(\D*)(.*)/.exec(s)||["","","",""],o=/(\d*)(\D*)(.*)/.exec(o)||["","","",""],(0!=s[0].length||0!=o[0].length)&&(t=Z(0==s[1].length?0:parseInt(s[1],10),0==o[1].length?0:parseInt(o[1],10))||Z(0==s[2].length,0==o[2].length)||Z(s[2],o[2]),s=s[3],o=o[3],0==t););return 0<=t},o=mt,Object.prototype.hasOwnProperty.call(o,9)?o[9]:o[9]=s())&&"number"==typeof r.timeout&&void 0!==r.ontimeout))?(this.g.timeout=this.B,this.g.ontimeout=$(this.pa,this)):this.A=ie(this.pa,this.B,this)),this.v=!0,this.g.send(t),this.v=!1}catch(t){Hi(this,t)}},D.pa=function(){void 0!==P&&this.g&&(this.j="Timed out after "+this.B+"ms, aborting",this.m=8,$t(this,"timeout"),this.abort(8))},D.abort=function(t){this.g&&this.h&&(this.h=!1,this.l=!0,this.g.abort(),this.l=!1,this.m=t||7,$t(this,"complete"),$t(this,"abort"),Ui(this))},D.M=function(){this.g&&(this.h&&(this.h=!1,this.l=!0,this.g.abort(),this.l=!1),Ui(this,!0)),Fi.Z.M.call(this)},D.Fa=function(){this.s||(this.F||this.v||this.l?Vi(this):this.cb())},D.cb=function(){Vi(this)},D.ba=function(){try{return 2<Ki(this)?this.g.status:-1}catch(t){return-1}},D.ga=function(){try{return this.g?this.g.responseText:""}catch(t){return""}},D.Qa=function(t){if(this.g){var e=this.g.responseText;return t&&0==e.indexOf(t)&&(e=e.substring(t.length)),Ri(e)}},D.Da=function(){return this.m},D.La=function(){return"string"==typeof this.j?this.j:String(this.j)},(D=Qi.prototype).ma=8,D.G=1,D.hb=function(t){try{this.h.info("Origin Trials invoked: "+t)}catch(t){}},D.Ha=function(t){if(this.m)if(this.m=null,1==this.G){if(!t){this.V=Math.floor(1e5*Math.random()),t=this.V++;var e=new Ie(this,this.h,t,void 0),i=this.s;if(this.P&&(i?rt(i=it(i),this.P):i=this.P),null===this.o&&(e.H=i),this.ja)t:{for(var n=0,r=0;r<this.l.length;r++){var s=this.l[r];if(void 0===(s="__data__"in s.g&&"string"==typeof(s=s.g.__data__)?s.length:void 0))break;if(4096<(n+=s)){n=r;break t}if(4096===n||r===this.l.length-1){n=r+1;break t}}n=1e3}else n=1e3;n=on(this,e,n),ei(r=Xe(this.F),"RID",t),ei(r,"CVER",22),this.D&&ei(r,"X-HTTP-Session-Id",this.D),sn(this,r),this.o&&i&&Yi(r,this.o,i),Si(this.i,e),this.Ra&&ei(r,"TYPE","init"),this.ja?(ei(r,"$req",n),ei(r,"SID","null"),e.$=!0,Oe(e,r,null)):Oe(e,r,n),this.G=2}}else 3==this.G&&(t?rn(this,t):0==this.l.length||_i(this.i)||rn(this))},D.Ga=function(){var t;this.u=null,cn(this),this.$&&!(this.L||null==this.g||this.O<=0)&&(t=2*this.O,this.h.info("BP detection timer enabled: "+t),this.B=we($(this.bb,this),t))},D.bb=function(){this.B&&(this.B=null,this.h.info("BP detection timeout reached."),this.h.info("Buffering proxy detected and switch to long-polling!"),this.N=!1,this.L=!0,ye(10),Zi(this),cn(this))},D.ab=function(){null!=this.v&&(this.v=null,Zi(this),ln(this),ye(19))},D.jb=function(t){t?(this.h.info("Successfully pinged google.com"),ye(2)):(this.h.info("Failed to ping google.com"),ye(1))},(D=yn.prototype).xa=function(){},D.wa=function(){},D.va=function(){},D.ua=function(){},D.Oa=function(){},bn.prototype.g=function(t,e){return new wn(t,e)},H(wn,Bt),wn.prototype.m=function(){this.g.j=this.j,this.A&&(this.g.H=!0);var t=this.g,e=this.l,i=this.h||void 0;t.Wa&&(t.h.info("Origin Trials enabled."),Xt($(t.hb,t,e))),ye(0),t.W=e,t.aa=i||{},t.N=t.X,t.F=mn(t,null,t.W),nn(t)},wn.prototype.close=function(){Ji(this.g)},wn.prototype.u=function(t){var e;"string"==typeof t?((e={}).__data__=t,en(this.g,e)):this.v?((e={}).__data__=Ht(t),en(this.g,e)):en(this.g,t)},wn.prototype.M=function(){this.g.j=null,delete this.j,Ji(this.g),delete this.g,wn.Z.M.call(this)},H(_n,Ce),H(xn,Ee),H(Tn,yn),Tn.prototype.xa=function(){$t(this.g,"a")},Tn.prototype.wa=function(t){$t(this.g,new _n(t))},Tn.prototype.va=function(t){$t(this.g,new xn)},Tn.prototype.ua=function(){$t(this.g,"b")},bn.prototype.createWebChannel=bn.prototype.g,wn.prototype.send=wn.prototype.u,wn.prototype.open=wn.prototype.m,_e.NO_ERROR=0,_e.TIMEOUT=8,_e.HTTP_ERROR=6,A.COMPLETE="complete",(Se.EventType=qt).OP
1EN="a",qt.CLOSE="b",qt.ERROR="c",qt.MESSAGE="d",Bt.prototype.listen=Bt.prototype.N,Fi.prototype.listenOnce=Fi.prototype.O,Fi.prototype.getLastError=Fi.prototype.La,Fi.prototype.getLastErrorCode=Fi.prototype.Da,Fi.prototype.getStatus=Fi.prototype.ba,Fi.prototype.getResponseJson=Fi.prototype.Qa,Fi.prototype.getResponseText=Fi.prototype.ga,Fi.prototype.send=Fi.prototype.ea;var Sn=fe,Cn=_e,En=A,kn=de,In=Ai,Dn=Se,An=Fi,Pn=(Mn.prototype.t=function(t){return this.previousValue=Math.max(t,this.previousValue),this.previousValue},Mn.prototype.next=function(){var t=++this.previousValue;return this.i&&this.i(t),t},Mn);function Mn(t,e){var i=this;this.previousValue=t,e&&(e.sequenceNumberHandler=function(t){return i.t(t)},this.i=function(t){return e.writeSequenceNumber(t)})}Pn.o=-1;var Nn,On={OK:"ok",CANCELLED:"cancelled",UNKNOWN:"unknown",INVALID_ARGUMENT:"invalid-argument",DEADLINE_EXCEEDED:"deadline-exceeded",NOT_FOUND:"not-found",ALREADY_EXISTS:"already-exists",PERMISSION_DENIED:"permission-denied",UNAUTHENTICATED:"unauthenticated",RESOURCE_EXHAUSTED:"resource-exhausted",FAILED_PRECONDITION:"failed-precondition",ABORTED:"aborted",OUT_OF_RANGE:"out-of-range",UNIMPLEMENTED:"unimplemented",INTERNAL:"internal",UNAVAILABLE:"unavailable",DATA_LOSS:"data-loss"},Ln=(i(Fn,Nn=Error),Fn),Rn=new C("@firebase/firestore");function Fn(t,e){var i=this;return(i=Nn.call(this,e)||this).code=t,i.message=e,i.name="FirebaseError",i.toString=function(){return i.name+": [code="+i.code+"]: "+i.message},i}function zn(){return Rn.logLevel}function Bn(t){for(var e,i=[],n=1;n<arguments.length;n++)i[n-1]=arguments[n];Rn.logLevel<=y.DEBUG&&(e=i.map(Hn),Rn.debug.apply(Rn,o(["Firestore (8.10.0): "+t],e)))}function $n(t){for(var e,i=[],n=1;n<arguments.length;n++)i[n-1]=arguments[n];Rn.logLevel<=y.ERROR&&(e=i.map(Hn),Rn.error.apply(Rn,o(["Firestore (8.10.0): "+t],e)))}function jn(t){for(var e,i=[],n=1;n<arguments.length;n++)i[n-1]=arguments[n];Rn.logLevel<=y.WARN&&(e=i.map(Hn),Rn.warn.apply(Rn,o(["Firestore (8.10.0): "+t],e)))}function Hn(e){if("string"==typeof e)return e;try{return JSON.stringify(e)}catch(t){return e}}function qn(t){throw $n(t="FIRESTORE (8.10.0) INTERNAL ASSERTION FAILED: "+(t=void 0===t?"Unexpected state":t)),new Error(t)}function Vn(t){t||qn()}var Un=(Wn.u=function(){for(var t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",e=Math.floor(256/t.length)*t.length,i="";i.length<20;)for(var n=function(t){var e="undefined"!=typeof self&&(self.crypto||self.msCrypto),i=new Uint8Array(40);if(e&&"function"==typeof e.getRandomValues)e.getRandomValues(i);else for(var n=0;n<40;n++)i[n]=Math.floor(256*Math.random());return i}(),r=0;r<n.length;++r)i.length<20&&n[r]<e&&(i+=t.charAt(n[r]%t.length));return i},Wn);function Wn(){}function Kn(t,e){return t<e?-1:e<t?1:0}function Gn(t,i,n){return t.length===i.length&&t.every(function(t,e){return n(t,i[e])})}function Yn(t){return t+"\0"}var Xn=(Zn.now=function(){return Zn.fromMillis(Date.now())},Zn.fromDate=function(t){return Zn.fromMillis(t.getTime())},Zn.fromMillis=function(t){var e=Math.floor(t/1e3);return new Zn(e,Math.floor(1e6*(t-1e3*e)))},Zn.prototype.toDate=function(){return new Date(this.toMillis())},Zn.prototype.toMillis=function(){return 1e3*this.seconds+this.nanoseconds/1e6},Zn.prototype._compareTo=function(t){return this.seconds===t.seconds?Kn(this.nanoseconds,t.nanoseconds):Kn(this.seconds,t.seconds)},Zn.prototype.isEqual=function(t){return t.seconds===this.seconds&&t.nanoseconds===this.nanoseconds},Zn.prototype.toString=function(){return"Timestamp(seconds="+this.seconds+", nanoseconds="+this.nanoseconds+")"},Zn.prototype.toJSON=function(){return{seconds:this.seconds,nanoseconds:this.nanoseconds}},Zn.prototype.valueOf=function(){var t=this.seconds- -62135596800;return String(t).padStart(12,"0")+"."+String(this.nanoseconds).padStart(9,"0")},Zn),Qn=(Jn.fromTimestamp=function(t){return new Jn(t)},Jn.min=function(){return new Jn(new Xn(0,0))},Jn.prototype.compareTo=function(t){return this.timestamp._compareTo(t.timestamp)},Jn.prototype.isEqual=function(t){return this.timestamp.isEqual(t.timestamp)},Jn.prototype.toMicroseconds=function(){return 1e6*this.timestamp.seconds+this.timestamp.nanoseconds/1e3},Jn.prototype.toString=function(){return"SnapshotVersion("+this.timestamp.toString()+")"},Jn.prototype.toTimestamp=function(){return this.timestamp},Jn);function Jn(t){this.timestamp=t}function Zn(t,e){if(this.seconds=t,(this.nanoseconds=e)<0)throw new Ln(On.INVALID_ARGUMENT,"Timestamp nanoseconds out of range: "+e);if(1e9<=e)throw new Ln(On.INVALID_ARGUMENT,"Timestamp nanoseconds out of range: "+e);if(t<-62135596800)throw new Ln(On.INVALID_ARGUMENT,"Timestamp seconds out of range: "+t);if(253402300800<=t)throw new Ln(On.INVALID_ARGUMENT,"Timestamp seconds out of range: "+t)}function tr(t){var e,i=0;for(e in t)Object.prototype.hasOwnProperty.call(t,e)&&i++;return i}function er(t,e){for(var i in t)Object.prototype.hasOwnProperty.call(t,i)&&e(i,t[i])}function ir(t){for(var e in t)if(Object.prototype.hasOwnProperty.call(t,e))return!1;return!0}Object.defineProperty(fr.prototype,"length",{get:function(){return this.len}
1,enumerable:!1,configurable:!0}),fr.prototype.isEqual=function(t){return 0===fr.comparator(this,t)},fr.prototype.child=function(t){var e=this.segments.slice(this.offset,this.limit());return t instanceof fr?t.forEach(function(t){e.push(t)}):e.push(t),this.construct(e)},fr.prototype.limit=function(){return this.offset+this.length},fr.prototype.popFirst=function(t){return this.construct(this.segments,this.offset+(t=void 0===t?1:t),this.length-t)},fr.prototype.popLast=function(){return this.construct(this.segments,this.offset,this.length-1)},fr.prototype.firstSegment=function(){return this.segments[this.offset]},fr.prototype.lastSegment=function(){return this.get(this.length-1)},fr.prototype.get=function(t){return this.segments[this.offset+t]},fr.prototype.isEmpty=function(){return 0===this.length},fr.prototype.isPrefixOf=function(t){if(t.length<this.length)return!1;for(var e=0;e<this.length;e++)if(this.get(e)!==t.get(e))return!1;return!0},fr.prototype.isImmediateParentOf=function(t){if(this.length+1!==t.length)return!1;for(var e=0;e<this.length;e++)if(this.get(e)!==t.get(e))return!1;return!0},fr.prototype.forEach=function(t){for(var e=this.offset,i=this.limit();e<i;e++)t(this.segments[e])},fr.prototype.toArray=function(){return this.segments.slice(this.offset,this.limit())},fr.comparator=function(t,e){for(var i=Math.min(t.length,e.length),n=0;n<i;n++){var r=t.get(n),s=e.get(n);if(r<s)return-1;if(s<r)return 1}return t.length<e.length?-1:t.length>e.length?1:0},A=fr;var nr,rr,sr=(i(pr,rr=A),pr.prototype.construct=function(t,e,i){return new pr(t,e,i)},pr.prototype.canonicalString=function(){return this.toArray().join("/")},pr.prototype.toString=function(){return this.canonicalString()},pr.fromString=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];for(var i=[],n=0,r=t;n<r.length;n++){var s=r[n];if(0<=s.indexOf("//"))throw new Ln(On.INVALID_ARGUMENT,"Invalid segment ("+s+"). Paths must not contain // in them.");i.push.apply(i,s.split("/").filter(function(t){return 0<t.length}))}return new pr(i)},pr.emptyPath=function(){return new pr([])},pr),or=/^[_a-zA-Z][_a-zA-Z0-9]*$/,ar=(i(dr,nr=A),dr.prototype.construct=function(t,e,i){return new dr(t,e,i)},dr.isValidIdentifier=function(t){return or.test(t)},dr.prototype.canonicalString=function(){return this.toArray().map(function(t){return t=t.replace(/\\/g,"\\\\").replace(/`/g,"\\`"),dr.isValidIdentifier(t)?t:"`"+t+"`"}).join(".")},dr.prototype.toString=function(){return this.canonicalString()},dr.prototype.isKeyField=function(){return 1===this.length&&"__name__"===this.get(0)},dr.keyField=function(){return new dr(["__name__"])},dr.fromServerFormat=function(t){for(var e=[],i="",n=0,r=function(){if(0===i.length)throw new Ln(On.INVALID_ARGUMENT,"Invalid field path ("+t+"). Paths must not be empty, begin with '.', end with '.', or contain '..'");e.push(i),i=""},s=!1;n<t.length;){var o=t[n];if("\\"===o){if(n+1===t.length)throw new Ln(On.INVALID_ARGUMENT,"Path has trailing escape character: "+t);var a=t[n+1];if("\\"!==a&&"."!==a&&"`"!==a)throw new Ln(On.INVALID_ARGUMENT,"Path has invalid escape sequence: "+t);i+=a,n+=2}else"`"===o?s=!s:"."!==o||s?i+=o:r(),n++}if(r(),s)throw new Ln(On.INVALID_ARGUMENT,"Unterminated ` in path: "+t);return new dr(e)},dr.emptyPath=function(){return new dr([])},dr),lr=(hr.prototype.covers=function(t){for(var e=0,i=this.fields;e<i.length;e++)if(i[e].isPrefixOf(t))return!0;return!1},hr.prototype.isEqual=function(t){return Gn(this.fields,t.fields,function(t,e){return t.isEqual(e)})},hr),ur=(cr.fromBase64String=function(t){return new cr(atob(t))},cr.fromUint8Array=function(t){return new cr(function(t){for(var e="",i=0;i<t.length;++i)e+=String.fromCharCode(t[i]);return e}(t))},cr.prototype.toBase64=function(){return t=this.binaryString,btoa(t);var t},cr.prototype.toUint8Array=function(){return function(t){for(var e=new Uint8Array(t.length),i=0;i<t.length;i++)e[i]=t.charCodeAt(i);return e}(this.binaryString)},cr.prototype.approximateByteSize=function(){return 2*this.binaryString.length},cr.prototype.compareTo=function(t){return Kn(this.binaryString,t.binaryString)},cr.prototype.isEqual=function(t){return this.binaryString===t.binaryString},cr);function cr(t){this.binaryString=t}function hr(t){(this.fields=t).sort(ar.comparator)}function dr(){return null!==nr&&nr.apply(this,arguments)||this}function pr(){return null!==rr&&rr.apply(this,arguments)||this}function fr(t,e,i){void 0===e?e=0:e>t.length&&qn(),void 0===i?i=t.length-e:i>t.length-e&&qn(),this.segments=t,this.offset=e,this.len=i}ur.EMPTY_BYTE_STRING=new ur("");var gr=new RegExp(/^\d{4}-\d\d-\d\dT\d\d:\d\d:\d\d(?:\.(\d+))?Z$/);function mr(t){if(Vn(!!t),"string"!=typeof t)return{seconds:vr(t.seconds),nanos:vr(t.nanos)};var e=0,i=gr.exec(t);return Vn(!!i),i[1]&&(i=((i=i[1])+"000000000").substr(0,9),e=Number(i)),t=new Date(t),{seconds:Math.floor(t.getTime()/1e3),nanos:e}}function vr(t){return"number"==typeof t?t:"string"==typeof t?Number(t):0}function yr(t){return"string"==typeof t?ur.fromBase64String(t):ur.fromUint8Array(t)}function br(t){return"server_timestamp"===(null===(t=((null===(t=null==t?void 0:t.mapValue)||void 0===t?void 0:t.fields)||{}).__type__)||void 0===t?void 0:t.stringValue)}function wr(t){return t=mr(t.mapValue.fields.__local_write_time__.timestampValue),new Xn(t.seconds,t.nanos)}function _r(t){return null==t}function xr(t){return 0===t&&1/t==-1/0}function Tr(t){return"number"==typeof t&&Number.isInteger(t)&&!xr(t)&&t<=Number.MAX_SAFE_INTEGER&&t>=Number.MIN_SAFE_INTEGER}var Sr=(Cr.fromPath=function(t){return new Cr(sr.fromString(t))},Cr.fromName=function(t){return new Cr(sr.fromString(t).popFirst(5))},Cr.prototype.hasCollectionId=function(t){return 2<=this.path.length&&this.path.get(this.path.length-2)===t},Cr.prototype.isEqual=function(t){return null!==t&&0===sr.comparator(this.path,t.path)},Cr.prototype.toString=function(){return this.path.toString()},Cr.comparator=function(t,e){return sr.comparator(t.path,e.path)},Cr.isDocumentKey=function(t){return t.length%2==0},Cr.fromSegments=function(t){return new Cr(new sr(t.slice()))},Cr);function Cr(t){this.path=t}function Er(t){return"nullValue"in t?0:"booleanValue"in t?1:"integerValue"in t||"doubleValue"in t?2:"timestampValue"in t?3:"stringValue"in t?5:"bytesValue"in t?6:"referenceValue"in t?7:"geoPointValue"in t?8:"arrayValue"in t?9:"mapValue"in t?br(t)?4:10:qn()}function kr(n,r){var t,e,i,s,o=Er(n);if(o!==Er(r))return!1;switch(o){case 0:return!0;case 1:return n.booleanValue===r.booleanValue;case 4:return wr(n).isEqual(wr(r));case 3:return function(t){if("string"==typeof n.timestampValue&&"string"==typeof t.timestampValue&&n.timestampValue.length===t.timestampValue.length)return n.timestampValue===t.timestampValue;var e=mr(n.timestampValue);t=mr(t.timestampValue);return e.seconds===t.seconds&&e.nanos===t.nanos}(r);case 5:return n.stringValue===r.stringValue;case 6:return e=r,yr(n.bytesValue).isEqual(yr(e.bytesValue));case 7:return n.referenceValue===r.referenceValue;case 8:return t=r,vr((e=n).geoPointValue.latitude)===vr(t.geoPointValue.latitude)&&vr(e.geoPointValue.longitude)===vr(t.geoPointValue.longitude);case 2:return s=r,"integerValue"in(i=n)&&"integerValue"in s?vr(i.integerValue)===vr(s.integerValue):"doubleValue"in i&&"doubleValue"in s&&((i=vr(i.doubleValue))===(s=vr(s.doubleValue))?xr(i)===xr(s):isNaN(i)&&isNaN(s));case 9:return Gn(n.arrayValue.values||[],r.arrayValue.values||[],kr);case 10:return function(){var t,e=n.mapValue.fields||{},i=r.mapValue.fields||{};if(tr(e)!==tr(i))return!1;
1for(t in e)if(e.hasOwnProperty(t)&&(void 0===i[t]||!kr(e[t],i[t])))return!1;return!0}();default:return qn()}}function Ir(t,e){return void 0!==(t.values||[]).find(function(t){return kr(t,e)})}function Dr(t,e){var i,n,r,s,o,a=Er(t),l=Er(e);if(a!==l)return Kn(a,l);switch(a){case 0:return 0;case 1:return Kn(t.booleanValue,e.booleanValue);case 2:return n=e,(r=vr(t.integerValue||t.doubleValue))<(n=vr(n.integerValue||n.doubleValue))?-1:n<r?1:r===n?0:isNaN(r)?isNaN(n)?0:-1:1;case 3:return Ar(t.timestampValue,e.timestampValue);case 4:return Ar(wr(t),wr(e));case 5:return Kn(t.stringValue,e.stringValue);case 6:return s=t.bytesValue,o=e.bytesValue,s=yr(s),o=yr(o),s.compareTo(o);case 7:return function(t,e){for(var i=t.split("/"),n=e.split("/"),r=0;r<i.length&&r<n.length;r++){var s=Kn(i[r],n[r]);if(0!==s)return s}return Kn(i.length,n.length)}(t.referenceValue,e.referenceValue);case 8:return i=t.geoPointValue,r=e.geoPointValue,0!==(n=Kn(vr(i.latitude),vr(r.latitude)))?n:Kn(vr(i.longitude),vr(r.longitude));case 9:return function(t,e){for(var i=t.values||[],n=e.values||[],r=0;r<i.length&&r<n.length;++r){var s=Dr(i[r],n[r]);if(s)return s}return Kn(i.length,n.length)}(t.arrayValue,e.arrayValue);case 10:return function(t,e){var i=t.fields||{},n=Object.keys(i),r=e.fields||{},s=Object.keys(r);n.sort(),s.sort();for(var o=0;o<n.length&&o<s.length;++o){var a=Kn(n[o],s[o]);if(0!==a)return a;if(0!==(a=Dr(i[n[o]],r[s[o]])))return a}return Kn(n.length,s.length)}(t.mapValue,e.mapValue);default:throw qn()}}function Ar(t,e){if("string"==typeof t&&"string"==typeof e&&t.length===e.length)return Kn(t,e);var i=mr(t);t=mr(e);return 0!==(e=Kn(i.seconds,t.seconds))?e:Kn(i.nanos,t.nanos)}function Pr(t){return function o(s){return"nullValue"in s?"null":"booleanValue"in s?""+s.booleanValue:"integerValue"in s?""+s.integerValue:"doubleValue"in s?""+s.doubleValue:"timestampValue"in s?"time("+(t=mr(t=s.timestampValue)).seconds+","+t.nanos+")":"stringValue"in s?s.stringValue:"bytesValue"in s?yr(s.bytesValue).toBase64():"referenceValue"in s?(e=s.referenceValue,Sr.fromName(e).toString()):"geoPointValue"in s?"geo("+(e=s.geoPointValue).latitude+","+e.longitude+")":"arrayValue"in s?function(t){for(var e="[",i=!0,n=0,r=s.arrayValue.values||[];n<r.length;n++)i?i=!1:e+=",",e+=o(r[n]);return e+"]"}():"mapValue"in s?function(t){for(var e="{",i=!0,n=0,r=Object.keys(t.fields||{}).sort();n<r.length;n++){var s=r[n];i?i=!1:e+=",",e+=s+":"+o(t.fields[s])}return e+"}"}(s.mapValue):qn();var t,e}(t)}function Mr(t,e){return{referenceValue:"projects/"+t.projectId+"/databases/"+t.database+"/documents/"+e.path.canonicalString()}}function Nr(t){return t&&"integerValue"in t}function Or(t){return!!t&&"arrayValue"in t}function Lr(t){return t&&"nullValue"in t}function Rr(t){return t&&"doubleValue"in t&&isNaN(Number(t.doubleValue))}function Fr(t){return t&&"mapValue"in t}function zr(t){if(t.geoPointValue)return{geoPointValue:Object.assign({},t.geoPointValue)};if(t.timestampValue&&"object"==typeof t.timestampValue)return{timestampValue:Object.assign({},t.timestampValue)};if(t.mapValue){var i={mapValue:{fields:{}}};return er(t.mapValue.fields,function(t,e){return i.mapValue.fields[t]=zr(e)}),i}if(t.arrayValue){for(var e={arrayValue:{values:[]}},n=0;n<(t.arrayValue.values||[]).length;++n)e.arrayValue.values[n]=zr(t.arrayValue.values[n]);return e}return Object.assign({},t)}var Br=($r.empty=function(){return new $r({mapValue:{}})},$r.prototype.field=function(t){if(t.isEmpty())return this.value;for(var e=this.value,i=0;i<t.length-1;++i)if(!Fr(e=(e.mapValue.fields||{})[t.get(i)]))return null;return(e=(e.mapValue.fields||{})[t.lastSegment()])||null},$r.prototype.set=function(t,e){this.getFieldsMap(t.popLast())[t.lastSegment()]=zr(e)},$r.prototype.setAll=function(t){var n=this,r=ar.emptyPath(),s={},o=[];t.forEach(function(t,e){var i;r.isImmediateParentOf(e)||(i=n.getFieldsMap(r),n.applyChanges(i,s,o),s={},o=[],r=e.popLast()),t?s[e.lastSegment()]=zr(t):o.push(e.lastSegment())}),t=this.getFieldsMap(r),this.applyChanges(t,s,o)},$r.prototype.delete=function(t){var e=this.field(t.popLast());Fr(e)&&e.mapValue.fields&&delete e.mapValue.fields[t.lastSegment()]},$r.prototype.isEqual=function(t){return kr(this.value,t.value)},$r.prototype.getFieldsMap=function(t){var e=this.value;e.mapValue.fields||(e.mapValue={fields:{}});for(var i=0;i<t.length;++i){var n=e.mapValue.fields[t.get(i)];Fr(n)&&n.mapValue.fields||(n={mapValue:{fields:{}}},e.mapValue.fields[t.get(i)]=n),e=n}return e.mapValue.fields},$r.prototype.applyChanges=function(i,t,e){er(t,function(t,e){return i[t]=e});for(var n=0,r=e;n<r.length;n++){var s=r[n];delete i[s]}},$r.prototype.clone=function(){return new $r(zr(this.value))},$r);function $r(t){this.value=t}var jr=(qr.newInvalidDocument=function(t){return new qr(t,0,Qn.min(),Br.empty(),0)}
1,qr.newFoundDocument=function(t,e,i){return new qr(t,1,e,i,0)},qr.newNoDocument=function(t,e){return new qr(t,2,e,Br.empty(),0)},qr.newUnknownDocument=function(t,e){return new qr(t,3,e,Br.empty(),2)},qr.prototype.convertToFoundDocument=function(t,e){return this.version=t,this.documentType=1,this.data=e,this.documentState=0,this},qr.prototype.convertToNoDocument=function(t){return this.version=t,this.documentType=2,this.data=Br.empty(),this.documentState=0,this},qr.prototype.convertToUnknownDocument=function(t){return this.version=t,this.documentType=3,this.data=Br.empty(),this.documentState=2,this},qr.prototype.setHasCommittedMutations=function(){return this.documentState=2,this},qr.prototype.setHasLocalMutations=function(){return this.documentState=1,this},Object.defineProperty(qr.prototype,"hasLocalMutations",{get:function(){return 1===this.documentState},enumerable:!1,configurable:!0}),Object.defineProperty(qr.prototype,"hasCommittedMutations",{get:function(){return 2===this.documentState},enumerable:!1,configurable:!0}),Object.defineProperty(qr.prototype,"hasPendingWrites",{get:function(){return this.hasLocalMutations||this.hasCommittedMutations},enumerable:!1,configurable:!0}),qr.prototype.isValidDocument=function(){return 0!==this.documentType},qr.prototype.isFoundDocument=function(){return 1===this.documentType},qr.prototype.isNoDocument=function(){return 2===this.documentType},qr.prototype.isUnknownDocument=function(){return 3===this.documentType},qr.prototype.isEqual=function(t){return t instanceof qr&&this.key.isEqual(t.key)&&this.version.isEqual(t.version)&&this.documentType===t.documentType&&this.documentState===t.documentState&&this.data.isEqual(t.data)},qr.prototype.clone=function(){return new qr(this.key,this.documentType,this.version,this.data.clone(),this.documentState)},qr.prototype.toString=function(){return"Document("+this.key+", "+this.version+", "+JSON.stringify(this.data.value)+", {documentType: "+this.documentType+"}), {documentState: "+this.documentState+"})"},qr),Hr=function(t,e,i,n,r,s,o){void 0===e&&(e=null),void 0===i&&(i=[]),void 0===n&&(n=[]),void 0===r&&(r=null),void 0===s&&(s=null),void 0===o&&(o=null),this.path=t,this.collectionGroup=e,this.orderBy=i,this.filters=n,this.limit=r,this.startAt=s,this.endAt=o,this.h=null};function qr(t,e,i,n,r){this.key=t,this.documentType=e,this.version=i,this.data=n,this.documentState=r}function Vr(t,e,i,n,r,s,o){return new Hr(t,e=void 0===e?null:e,i=void 0===i?[]:i,n=void 0===n?[]:n,r=void 0===r?null:r,s=void 0===s?null:s,o=void 0===o?null:o)}function Ur(t){var e=t;return null===e.h&&(t=e.path.canonicalString(),null!==e.collectionGroup&&(t+="|cg:"+e.collectionGroup),t+="|f:",t+=e.filters.map(function(t){return(t=t).field.canonicalString()+t.op.toString()+Pr(t.value)}).join(","),t+="|ob:",t+=e.orderBy.map(function(t){return(t=t).field.canonicalString()+t.dir}).join(","),_r(e.limit)||(t+="|l:",t+=e.limit),e.startAt&&(t+="|lb:",t+=ws(e.startAt)),e.endAt&&(t+="|ub:",t+=ws(e.endAt)),e.h=t),e.h}function Wr(t,e){if(t.limit!==e.limit)return!1;if(t.orderBy.length!==e.orderBy.length)return!1;for(var i,n,r=0;r<t.orderBy.length;r++)if(i=t.orderBy[r],n=e.orderBy[r],i.dir!==n.dir||!i.field.isEqual(n.field))return!1;if(t.filters.length!==e.filters.length)return!1;for(var s,o,a=0;a<t.filters.length;a++)if(s=t.filters[a],o=e.filters[a],s.op!==o.op||!s.field.isEqual(o.field)||!kr(s.value,o.value))return!1;return t.collectionGroup===e.collectionGroup&&!!t.path.isEqual(e.path)&&!!Ts(t.startAt,e.startAt)&&Ts(t.endAt,e.endAt)}function Kr(t){return Sr.isDocumentKey(t.path)&&null===t.collectionGroup&&0===t.filters.length}var Gr,Yr=(i(Xr,Gr=function(){}),Xr.create=function(t,e,i){return t.isKeyField()?"in"===e||"not-in"===e?this.l(t,e,i):new ts(t,e,i):"array-contains"===e?new hs(t,i):"in"===e?new ds(t,i):"not-in"===e?new ps(t,i):"array-contains-any"===e?new fs(t,i):new Xr(t,e,i)},Xr.l=function(t,e,i){return new("in"===e?es:is)(t,i)},Xr.prototype.matches=function(t){return t=t.data.field(this.field),"!="===this.op?null!==t&&this.m(Dr(t,this.value)):null!==t&&Er(this.value)===Er(t)&&this.m(Dr(t,this.value))},Xr.prototype.m=function(t){switch(this.op){case"<":return t<0;case"<=":return t<=0;case"==":return 0===t;case"!=":return 0!==t;case">":return 0<t;case">=":return 0<=t;default:return qn()}},Xr.prototype.g=function(){return 0<=["<","<=",">",">=","!=","not-in"].indexOf(this.op)},Xr);function Xr(t,e,i){var n=this;return(n=Gr.call(this)||this).field=t,n.op=e,n.value=i,n}var Qr,Jr,Zr,ts=(i(ss,Zr=Yr),ss.prototype.matches=function(t){return t=Sr.comparator(t.key,this.key),this.m(t)}
1,ss),es=(i(rs,Jr=Yr),rs.prototype.matches=function(e){return this.keys.some(function(t){return t.isEqual(e.key)})},rs),is=(i(ns,Qr=Yr),ns.prototype.matches=function(e){return!this.keys.some(function(t){return t.isEqual(e.key)})},ns);function ns(t,e){var i=this;return(i=Qr.call(this,t,"not-in",e)||this).keys=os(0,e),i}function rs(t,e){var i=this;return(i=Jr.call(this,t,"in",e)||this).keys=os(0,e),i}function ss(t,e,i){var n=this;return(n=Zr.call(this,t,e,i)||this).key=Sr.fromName(i.referenceValue),n}function os(t,e){return((null===(e=e.arrayValue)||void 0===e?void 0:e.values)||[]).map(function(t){return Sr.fromName(t.referenceValue)})}var as,ls,us,cs,hs=(i(bs,cs=Yr),bs.prototype.matches=function(t){return Or(t=t.data.field(this.field))&&Ir(t.arrayValue,this.value)},bs),ds=(i(ys,us=Yr),ys.prototype.matches=function(t){return null!==(t=t.data.field(this.field))&&Ir(this.value.arrayValue,t)},ys),ps=(i(vs,ls=Yr),vs.prototype.matches=function(t){return!Ir(this.value.arrayValue,{nullValue:"NULL_VALUE"})&&(null!==(t=t.data.field(this.field))&&!Ir(this.value.arrayValue,t))},vs),fs=(i(ms,as=Yr),ms.prototype.matches=function(t){var e=this;return!(!Or(t=t.data.field(this.field))||!t.arrayValue.values)&&t.arrayValue.values.some(function(t){return Ir(e.value.arrayValue,t)})},ms),gs=function(t,e){this.position=t,this.before=e};function ms(t,e){return as.call(this,t,"array-contains-any",e)||this}function vs(t,e){return ls.call(this,t,"not-in",e)||this}function ys(t,e){return us.call(this,t,"in",e)||this}function bs(t,e){return cs.call(this,t,"array-contains",e)||this}function ws(t){return(t.before?"b":"a")+":"+t.position.map(Pr).join(",")}var _s=function(t,e){void 0===e&&(e="asc"),this.field=t,this.dir=e};function xs(t,e,i){for(var n=0,r=0;r<t.position.length;r++){var s=e[r],o=t.position[r];n=s.field.isKeyField()?Sr.comparator(Sr.fromName(o.referenceValue),i.key):Dr(o,i.data.field(s.field));if("desc"===s.dir&&(n*=-1),0!==n)break}return t.before?n<=0:n<0}function Ts(t,e){if(null===t)return null===e;if(null===e)return!1;if(t.before!==e.before||t.position.length!==e.position.length)return!1;for(var i=0;i<t.position.length;i++)if(!kr(t.position[i],e.position[i]))return!1;return!0}var Ss=function(t,e,i,n,r,s,o,a){void 0===e&&(e=null),void 0===i&&(i=[]),void 0===n&&(n=[]),void 0===r&&(r=null),void 0===s&&(s="F"),void 0===o&&(o=null),void 0===a&&(a=null),this.path=t,this.collectionGroup=e,this.explicitOrderBy=i,this.filters=n,this.limit=r,this.limitType=s,this.startAt=o,this.endAt=a,this.p=null,this.T=null,this.startAt,this.endAt};function Cs(t,e,i,n,r,s,o,a){return new Ss(t,e,i,n,r,s,o,a)}function Es(t){return new Ss(t)}function ks(t){return!_r(t.limit)&&"F"===t.limitType}function Is(t){return!_r(t.limit)&&"L"===t.limitType}function Ds(t){return 0<t.explicitOrderBy.length?t.explicitOrderBy[0].field:null}function As(t){for(var e=0,i=t.filters;e<i.length;e++){var n=i[e];if(n.g())return n.field}return null}function Ps(t){return null!==t.collectionGroup}function Ms(t){var e=t;if(null===e.p){e.p=[];var i=As(e);t=Ds(e);if(null!==i&&null===t)i.isKeyField()||e.p.push(new _s(i)),e.p.push(new _s(ar.keyField(),"asc"));else{for(var n=!1,r=0,s=e.explicitOrderBy;r<s.length;r++){var o=s[r];e.p.push(o),o.field.isKeyField()&&(n=!0)}n||(i=0<e.explicitOrderBy.length?e.explicitOrderBy[e.explicitOrderBy.length-1].dir:"asc",e.p.push(new _s(ar.keyField(),i)))}}return e.p}function Ns(t){var e=t;if(!e.T)if("F"===e.limitType)e.T=Vr(e.path,e.collectionGroup,Ms(e),e.filters,e.limit,e.startAt,e.endAt);else{for(var i=[],n=0,r=Ms(e);n<r.length;n++){var s=r[n],o="desc"===s.dir?"asc":"desc";i.push(new _s(s.field,o))}var a=e.endAt?new gs(e.endAt.position,!e.endAt.before):null;t=e.startAt?new gs(e.startAt.position,!e.startAt.before):null;e.T=Vr(e.path,e.collectionGroup,i,e.filters,e.limit,a,t)}return e.T}function Os(t,e,i){return new Ss(t.path,t.collectionGroup,t.explicitOrderBy.slice(),t.filters.slice(),e,i,t.startAt,t.endAt)}function Ls(t,e){return Wr(Ns(t),Ns(e))&&t.limitType===e.limitType}function Rs(t){return Ur(Ns(t))+"|lt:"+t.limitType}function Fs(t){return"Query(target="+(i=(e=Ns(t)).path.canonicalString(),null!==e.collectionGroup&&(i+=" collectionGroup="+e.collectionGroup),0<e.filters.length&&(i+=", filters: ["+e.filters.map(function(t){return(t=t).field.canonicalString()+" "+t.op+" "+Pr(t.value)}).join(", ")+"]"),_r(e.limit)||(i+=", limit: "+e.limit),0<e.orderBy.length&&(i+=", orderBy: ["+e.orderBy.map(function(t){return(t=t).field.canonicalString()+" ("+t.dir+")"}).join(", ")+"]"),e.startAt&&(i+=", startAt: "+ws(e.startAt)),e.endAt&&(i+=", endAt: "+ws(e.endAt)),"Target("+i+")")+"; limitType="+t.limitType+")";var e,i}
1function zs(r,t){return t.isFoundDocument()&&(e=r,i=t.key.path,null!==e.collectionGroup?t.key.hasCollectionId(e.collectionGroup)&&e.path.isPrefixOf(i):Sr.isDocumentKey(e.path)?e.path.isEqual(i):e.path.isImmediateParentOf(i))&&function(t){for(var e=0,i=r.explicitOrderBy;e<i.length;e++){var n=i[e];if(!n.field.isKeyField()&&null===t.data.field(n.field))return}return 1}(t)&&function(t){for(var e=0,i=r.filters;e<i.length;e++)if(!i[e].matches(t))return;return 1}(t)&&(i=t,(!(t=r).startAt||xs(t.startAt,Ms(t),i))&&(!t.endAt||!xs(t.endAt,Ms(t),i)));var e,i}function Bs(a){return function(t,e){for(var i=!1,n=0,r=Ms(a);n<r.length;n++){var s=r[n],o=function(t,n,e){var i=t.field.isKeyField()?Sr.comparator(n.key,e.key):function(t,e){var i=n.data.field(t);t=e.data.field(t);return null!==i&&null!==t?Dr(i,t):qn()}(t.field,e);switch(t.dir){case"asc":return i;case"desc":return-1*i;default:return qn()}}(s,t,e);if(0!==o)return o;i=i||s.field.isKeyField()}return 0}}function $s(t,e){if(t.I){if(isNaN(e))return{doubleValue:"NaN"};if(e===1/0)return{doubleValue:"Infinity"};if(e===-1/0)return{doubleValue:"-Infinity"}}return{doubleValue:xr(e)?"-0":e}}function js(t){return{integerValue:""+t}}function Hs(t,e){return Tr(e)?js(e):$s(t,e)}function qs(t,e){return t instanceof io?Nr(t=e)||t&&"doubleValue"in t?e:{integerValue:0}:null}var Vs,Us,Ws=(i(Ys,Us=C=function(){this._=void 0}),Ys),Ks=(i(Gs,Vs=C),Gs);function Gs(t){var e=this;return(e=Vs.call(this)||this).elements=t,e}function Ys(){return null!==Us&&Us.apply(this,arguments)||this}function Xs(t,e){for(var i=so(e),n=0,r=t.elements;n<r.length;n++)!function(e){i.some(function(t){return kr(t,e)})||i.push(e)}(r[n]);return{arrayValue:{values:i}}}var Qs,Js=(i(Zs,Qs=C),Zs);function Zs(t){var e=this;return(e=Qs.call(this)||this).elements=t,e}function to(t,e){for(var i=so(e),n=0,r=t.elements;n<r.length;n++)!function(e){i=i.filter(function(t){return!kr(t,e)})}(r[n]);return{arrayValue:{values:i}}}var eo,io=(i(no,eo=C),no);function no(t,e){var i=this;return(i=eo.call(this)||this).R=t,i.A=e,i}function ro(t){return vr(t.integerValue||t.doubleValue)}function so(t){return Or(t)&&t.arrayValue.values?t.arrayValue.values.slice():[]}function oo(t,e){this.version=t,this.transformResults=e}var ao=function(t,e){this.field=t,this.transform=e},lo=(uo.none=function(){return new uo},uo.exists=function(t){return new uo(void 0,t)},uo.updateTime=function(t){return new uo(t)},Object.defineProperty(uo.prototype,"isNone",{get:function(){return void 0===this.updateTime&&void 0===this.exists},enumerable:!1,configurable:!0}),uo.prototype.isEqual=function(t){return this.exists===t.exists&&(this.updateTime?!!t.updateTime&&this.updateTime.isEqual(t.updateTime):!t.updateTime)},uo);function uo(t,e){this.updateTime=t,this.exists=e}function co(t,e){return void 0!==t.updateTime?e.isFoundDocument()&&e.version.isEqual(t.updateTime):void 0===t.exists||t.exists===e.isFoundDocument()}function ho(t,e,i){var n,r,s,o;t instanceof vo?(r=e,s=i,co((n=t).precondition,r)&&(o=n.value.clone(),s=To(n.fieldTransforms,s,r),o.setAll(s),r.convertToFoundDocument(fo(r),o).setHasLocalMutations())):t instanceof yo?(s=e,r=i,co((o=t).precondition,s)&&(i=To(o.fieldTransforms,r,s),(r=s.data).setAll(_o(o)),r.setAll(i),s.convertToFoundDocument(fo(s),r).setHasLocalMutations())):(e=e,co(t.precondition,e)&&e.convertToNoDocument(Qn.min()))}function po(t,e){return t.type===e.type&&!!t.key.isEqual(e.key)&&!!t.precondition.isEqual(e.precondition)&&(i=t.fieldTransforms,n=e.fieldTransforms,!!(void 0===i&&void 0===n||i&&n&&Gn(i,n,function(t,e){return e=e,(t=t).field.isEqual(e.field)&&(t=t.transform,e=e.transform,t instanceof Ks&&e instanceof Ks||t instanceof Js&&e instanceof Js?Gn(t.elements,e.elements,kr):t instanceof io&&e instanceof io?kr(t.A,e.A):t instanceof Ws&&e instanceof Ws)})))&&(0===t.type?t.value.isEqual(e.value):1!==t.type||t.data.isEqual(e.data)&&t.fieldMask.isEqual(e.fieldMask));var i,n}function fo(t){return t.isFoundDocument()?t.version:Qn.min()}var go,mo,vo=(i(wo,mo=A=function(){}),wo),yo=(i(bo,go=A),bo);function bo(t,e,i,n,r){void 0===r&&(r=[]);var s=this;return(s=go.call(this)||this).key=t,s.data=e,s.fieldMask=i,s.precondition=n,s.fieldTransforms=r,s.type=1,s}function wo(t,e,i,n){void 0===n&&(n=[]);var r=this;return(r=mo.call(this)||this).key=t,r.value=e,r.precondition=i,r.fieldTransforms=n,r.type=0,r}function _o(i){var n=new Map;return i.fieldMask.fields.forEach(function(t){var e;t.isEmpty()||(e=i.data.field(t),n.set(t,e))}),n}function xo(t,e,i){var n=new Map;Vn(t.length===i.length);for(var r=0;r<i.length;r++){var s=t[r],o=s.transform,a=e.data.field(s.field);n.set(s.field,(s=o,o=a,a=i[r],s instanceof Ks?Xs(s,o):s instanceof Js?to(s,o):a))}return n}
1function To(t,e,i){for(var n,r=new Map,s=0,o=t;s<o.length;s++){var a=o[s],l=a.transform,u=i.data.field(a.field);r.set(a.field,(n=u,a=e,u=void 0,(l=l)instanceof Ws?(u={fields:{__type__:{stringValue:"server_timestamp"},__local_write_time__:{timestampValue:{seconds:a.seconds,nanos:a.nanoseconds}}}},n&&(u.fields.__previous_value__=n),{mapValue:u}):l instanceof Ks?Xs(l,n):l instanceof Js?to(l,n):(n=ro(l=qs(u=l,n))+ro(u.A),Nr(l)&&Nr(u.A)?js(n):$s(u.R,n))))}return r}function So(t){this.count=t}var Co,Eo,ko,Io=(i(Po,ko=A),Po),Do=(i(Ao,Eo=A),Ao);function Ao(t,e){var i=this;return(i=Eo.call(this)||this).key=t,i.precondition=e,i.type=3,i.fieldTransforms=[],i}function Po(t,e){var i=this;return(i=ko.call(this)||this).key=t,i.precondition=e,i.type=2,i.fieldTransforms=[],i}function Mo(t){switch(t){case On.OK:return qn(),0;case On.CANCELLED:case On.UNKNOWN:case On.DEADLINE_EXCEEDED:case On.RESOURCE_EXHAUSTED:case On.INTERNAL:case On.UNAVAILABLE:case On.UNAUTHENTICATED:return;case On.INVALID_ARGUMENT:case On.NOT_FOUND:case On.ALREADY_EXISTS:case On.PERMISSION_DENIED:case On.FAILED_PRECONDITION:case On.ABORTED:case On.OUT_OF_RANGE:case On.UNIMPLEMENTED:case On.DATA_LOSS:return 1;default:return qn(),0}}function No(t){if(void 0===t)return $n("GRPC error has no .code"),On.UNKNOWN;switch(t){case Co.OK:return On.OK;case Co.CANCELLED:return On.CANCELLED;case Co.UNKNOWN:return On.UNKNOWN;case Co.DEADLINE_EXCEEDED:return On.DEADLINE_EXCEEDED;case Co.RESOURCE_EXHAUSTED:return On.RESOURCE_EXHAUSTED;case Co.INTERNAL:return On.INTERNAL;case Co.UNAVAILABLE:return On.UNAVAILABLE;case Co.UNAUTHENTICATED:return On.UNAUTHENTICATED;case Co.INVALID_ARGUMENT:return On.INVALID_ARGUMENT;case Co.NOT_FOUND:return On.NOT_FOUND;case Co.ALREADY_EXISTS:return On.ALREADY_EXISTS;case Co.PERMISSION_DENIED:return On.PERMISSION_DENIED;case Co.FAILED_PRECONDITION:return On.FAILED_PRECONDITION;case Co.ABORTED:return On.ABORTED;case Co.OUT_OF_RANGE:return On.OUT_OF_RANGE;case Co.UNIMPLEMENTED:return On.UNIMPLEMENTED;case Co.DATA_LOSS:return On.DATA_LOSS;default:return qn()}}(C=Co=Co||{})[C.OK=0]="OK",C[C.CANCELLED=1]="CANCELLED",C[C.UNKNOWN=2]="UNKNOWN",C[C.INVALID_ARGUMENT=3]="INVALID_ARGUMENT",C[C.DEADLINE_EXCEEDED=4]="DEADLINE_EXCEEDED",C[C.NOT_FOUND=5]="NOT_FOUND",C[C.ALREADY_EXISTS=6]="ALREADY_EXISTS",C[C.PERMISSION_DENIED=7]="PERMISSION_DENIED",C[C.UNAUTHENTICATED=16]="UNAUTHENTICATED",C[C.RESOURCE_EXHAUSTED=8]="RESOURCE_EXHAUSTED",C[C.FAILED_PRECONDITION=9]="FAILED_PRECONDITION",C[C.ABORTED=10]="ABORTED",C[C.OUT_OF_RANGE=11]="OUT_OF_RANGE",C[C.UNIMPLEMENTED=12]="UNIMPLEMENTED",C[C.INTERNAL=13]="INTERNAL",C[C.UNAVAILABLE=14]="UNAVAILABLE",C[C.DATA_LOSS=15]="DATA_LOSS";var Oo=(Bo.prototype.insert=function(t,e){return new Bo(this.comparator,this.root.insert(t,e,this.comparator).copy(null,null,Ro.BLACK,null,null))},Bo.prototype.remove=function(t){return new Bo(this.comparator,this.root.remove(t,this.comparator).copy(null,null,Ro.BLACK,null,null))},Bo.prototype.get=function(t){for(var e=this.root;!e.isEmpty();){var i=this.comparator(t,e.key);if(0===i)return e.value;i<0?e=e.left:0<i&&(e=e.right)}return null},Bo.prototype.indexOf=function(t){for(var e=0,i=this.root;!i.isEmpty();){var n=this.comparator(t,i.key);if(0===n)return e+i.left.size;i=n<0?i.left:(e+=i.left.size+1,i.right)}return-1},Bo.prototype.isEmpty=function(){return this.root.isEmpty()},Object.defineProperty(Bo.prototype,"size",{get:function(){return this.root.size},enumerable:!1,configurable:!0}),Bo.prototype.minKey=function(){return this.root.minKey()},Bo.prototype.maxKey=function(){return this.root.maxKey()},Bo.prototype.inorderTraversal=function(t){return this.root.inorderTraversal(t)},Bo.prototype.forEach=function(i){this.inorderTraversal(function(t,e){return i(t,e),!1})},Bo.prototype.toString=function(){var i=[];return this.inorderTraversal(function(t,e){return i.push(t+":"+e),!1}),"{"+i.join(", ")+"}"},Bo.prototype.reverseTraversal=function(t){return this.root.reverseTraversal(t)},Bo.prototype.getIterator=function(){return new Lo(this.root,null,this.comparator,!1)},Bo.prototype.getIteratorFrom=function(t){return new Lo(this.root,t,this.comparator,!1)},Bo.prototype.getReverseIterator=function(){return new Lo(this.root,null,this.comparator,!0)}
1,Bo.prototype.getReverseIteratorFrom=function(t){return new Lo(this.root,t,this.comparator,!0)},Bo),Lo=(zo.prototype.getNext=function(){var t=this.nodeStack.pop(),e={key:t.key,value:t.value};if(this.isReverse)for(t=t.left;!t.isEmpty();)this.nodeStack.push(t),t=t.right;else for(t=t.right;!t.isEmpty();)this.nodeStack.push(t),t=t.left;return e},zo.prototype.hasNext=function(){return 0<this.nodeStack.length},zo.prototype.peek=function(){if(0===this.nodeStack.length)return null;var t=this.nodeStack[this.nodeStack.length-1];return{key:t.key,value:t.value}},zo),Ro=(Fo.prototype.copy=function(t,e,i,n,r){return new Fo(null!=t?t:this.key,null!=e?e:this.value,null!=i?i:this.color,null!=n?n:this.left,null!=r?r:this.right)},Fo.prototype.isEmpty=function(){return!1},Fo.prototype.inorderTraversal=function(t){return this.left.inorderTraversal(t)||t(this.key,this.value)||this.right.inorderTraversal(t)},Fo.prototype.reverseTraversal=function(t){return this.right.reverseTraversal(t)||t(this.key,this.value)||this.left.reverseTraversal(t)},Fo.prototype.min=function(){return this.left.isEmpty()?this:this.left.min()},Fo.prototype.minKey=function(){return this.min().key},Fo.prototype.maxKey=function(){return this.right.isEmpty()?this.key:this.right.maxKey()},Fo.prototype.insert=function(t,e,i){var n=this,r=i(t,n.key);return(n=r<0?n.copy(null,null,null,n.left.insert(t,e,i),null):0===r?n.copy(null,e,null,null,null):n.copy(null,null,null,null,n.right.insert(t,e,i))).fixUp()},Fo.prototype.removeMin=function(){if(this.left.isEmpty())return Fo.EMPTY;var t=this;return(t=(t=t.left.isRed()||t.left.left.isRed()?t:t.moveRedLeft()).copy(null,null,null,t.left.removeMin(),null)).fixUp()},Fo.prototype.remove=function(t,e){var i,n=this;if(e(t,n.key)<0)n=(n=n.left.isEmpty()||n.left.isRed()||n.left.left.isRed()?n:n.moveRedLeft()).copy(null,null,null,n.left.remove(t,e),null);else{if(0===e(t,(n=(n=n.left.isRed()?n.rotateRight():n).right.isEmpty()||n.right.isRed()||n.right.left.isRed()?n:n.moveRedRight()).key)){if(n.right.isEmpty())return Fo.EMPTY;i=n.right.min(),n=n.copy(i.key,i.value,null,null,n.right.removeMin())}n=n.copy(null,null,null,null,n.right.remove(t,e))}return n.fixUp()},Fo.prototype.isRed=function(){return this.color},Fo.prototype.fixUp=function(){var t=this;return(t=(t=t.right.isRed()&&!t.left.isRed()?t.rotateLeft():t).left.isRed()&&t.left.left.isRed()?t.rotateRight():t).left.isRed()&&t.right.isRed()?t.colorFlip():t},Fo.prototype.moveRedLeft=function(){var t=this.colorFlip();return t.right.left.isRed()?(t=(t=t.copy(null,null,null,null,t.right.rotateRight())).rotateLeft()).colorFlip():t},Fo.prototype.moveRedRight=function(){var t=this.colorFlip();return t.left.left.isRed()?(t=t.rotateRight()).colorFlip():t},Fo.prototype.rotateLeft=function(){var t=this.copy(null,null,Fo.RED,null,this.right.left);return this.right.copy(null,null,this.color,t,null)},Fo.prototype.rotateRight=function(){var t=this.copy(null,null,Fo.RED,this.left.right,null);return this.left.copy(null,null,this.color,null,t)},Fo.prototype.colorFlip=function(){var t=this.left.copy(null,null,!this.left.color,null,null),e=this.right.copy(null,null,!this.right.color,null,null);return this.copy(null,null,!this.color,t,e)},Fo.prototype.checkMaxDepth=function(){var t=this.check();return Math.pow(2,t)<=this.size+1},Fo.prototype.check=function(){if(this.isRed()&&this.left.isRed())throw qn();if(this.right.isRed())throw qn();var t=this.left.check();if(t!==this.right.check())throw qn();return t+(this.isRed()?0:1)},Fo);function Fo(t,e,i,n,r){this.key=t,this.value=e,this.color=null!=i?i:Fo.RED,this.left=null!=n?n:Fo.EMPTY,this.right=null!=r?r:Fo.EMPTY,this.size=this.left.size+1+this.right.size}function zo(t,e,i,n){this.isReverse=n,this.nodeStack=[];for(var r=1;!t.isEmpty();)if(r=e?i(t.key,e):1,n&&(r*=-1),r<0)t=this.isReverse?t.left:t.right;else{if(0===r){this.nodeStack.push(t);break}this.nodeStack.push(t),t=this.isReverse?t.right:t.left}}function Bo(t,e){this.comparator=t,this.root=e||Ro.EMPTY}function $o(){this.size=0}Ro.EMPTY=null,Ro.RED=!0,Ro.BLACK=!1,Ro.EMPTY=(Object.defineProperty($o.prototype,"key",{get:function(){throw qn()}
1,enumerable:!1,configurable:!0}),Object.defineProperty($o.prototype,"value",{get:function(){throw qn()},enumerable:!1,configurable:!0}),Object.defineProperty($o.prototype,"color",{get:function(){throw qn()},enumerable:!1,configurable:!0}),Object.defineProperty($o.prototype,"left",{get:function(){throw qn()},enumerable:!1,configurable:!0}),Object.defineProperty($o.prototype,"right",{get:function(){throw qn()},enumerable:!1,configurable:!0}),$o.prototype.copy=function(t,e,i,n,r){return this},$o.prototype.insert=function(t,e,i){return new Ro(t,e)},$o.prototype.remove=function(t,e){return this},$o.prototype.isEmpty=function(){return!0},$o.prototype.inorderTraversal=function(t){return!1},$o.prototype.reverseTraversal=function(t){return!1},$o.prototype.minKey=function(){return null},$o.prototype.maxKey=function(){return null},$o.prototype.isRed=function(){return!1},$o.prototype.checkMaxDepth=function(){return!0},$o.prototype.check=function(){return 0},new $o);var jo=(Uo.prototype.has=function(t){return null!==this.data.get(t)},Uo.prototype.first=function(){return this.data.minKey()},Uo.prototype.last=function(){return this.data.maxKey()},Object.defineProperty(Uo.prototype,"size",{get:function(){return this.data.size},enumerable:!1,configurable:!0}),Uo.prototype.indexOf=function(t){return this.data.indexOf(t)},Uo.prototype.forEach=function(i){this.data.inorderTraversal(function(t,e){return i(t),!1})},Uo.prototype.forEachInRange=function(t,e){for(var i=this.data.getIteratorFrom(t[0]);i.hasNext();){var n=i.getNext();if(0<=this.comparator(n.key,t[1]))return;e(n.key)}},Uo.prototype.forEachWhile=function(t,e){for(var i=void 0!==e?this.data.getIteratorFrom(e):this.data.getIterator();i.hasNext();)if(!t(i.getNext().key))return},Uo.prototype.firstAfterOrEqual=function(t){return(t=this.data.getIteratorFrom(t)).hasNext()?t.getNext().key:null},Uo.prototype.getIterator=function(){return new Ho(this.data.getIterator())},Uo.prototype.getIteratorFrom=function(t){return new Ho(this.data.getIteratorFrom(t))},Uo.prototype.add=function(t){return this.copy(this.data.remove(t).insert(t,!0))},Uo.prototype.delete=function(t){return this.has(t)?this.copy(this.data.remove(t)):this},Uo.prototype.isEmpty=function(){return this.data.isEmpty()},Uo.prototype.unionWith=function(t){var e=this;return e.size<t.size&&(e=t,t=this),t.forEach(function(t){e=e.add(t)}),e},Uo.prototype.isEqual=function(t){if(!(t instanceof Uo))return!1;if(this.size!==t.size)return!1;for(var e=this.data.getIterator(),i=t.data.getIterator();e.hasNext();){var n=e.getNext().key,r=i.getNext().key;if(0!==this.comparator(n,r))return!1}return!0},Uo.prototype.toArray=function(){var e=[];return this.forEach(function(t){e.push(t)}),e},Uo.prototype.toString=function(){var e=[];return this.forEach(function(t){return e.push(t)}),"SortedSet("+e.toString()+")"},Uo.prototype.copy=function(t){var e=new Uo(this.comparator);return e.data=t,e},Uo),Ho=(Vo.prototype.getNext=function(){return this.iter.getNext().key},Vo.prototype.hasNext=function(){return this.iter.hasNext()},Vo),qo=new Oo(Sr.comparator);function Vo(t){this.iter=t}function Uo(t){this.comparator=t,this.data=new Oo(this.comparator)}var Wo=new Oo(Sr.comparator),Ko=new Oo(Sr.comparator),Go=new jo(Sr.comparator);function Yo(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];for(var i=Go,n=0,r=t;n<r.length;n++){var s=r[n];i=i.add(s)}return i}var Xo=new jo(Kn),Qo=(aa.createSynthesizedRemoteEventForCurrentChange=function(t,e){var i=new Map;return i.set(t,Jo.createSynthesizedTargetChangeForCurrentChange(t,e)),new aa(Qn.min(),i,Xo,qo,Yo())},aa),Jo=(oa.createSynthesizedTargetChangeForCurrentChange=function(t,e){return new oa(ur.EMPTY_BYTE_STRING,e,Yo(),Yo(),Yo())},oa),Zo=function(t,e,i,n){this.v=t,this.removedTargetIds=e,this.key=i,this.P=n},ta=function(t,e){this.targetId=t,this.V=e},ea=function(t,e,i,n){void 0===i&&(i=ur.EMPTY_BYTE_STRING),void 0===n&&(n=null),this.state=t,this.targetIds=e,this.resumeToken=i,this.cause=n},ia=(Object.defineProperty(sa.prototype,"current",{get:function(){return this.N},enumerable:!1,configurable:!0}),Object.defineProperty(sa.prototype,"resumeToken",{get:function(){return this.C}
1,enumerable:!1,configurable:!0}),Object.defineProperty(sa.prototype,"F",{get:function(){return 0!==this.S},enumerable:!1,configurable:!0}),Object.defineProperty(sa.prototype,"$",{get:function(){return this.k},enumerable:!1,configurable:!0}),sa.prototype.O=function(t){0<t.approximateByteSize()&&(this.k=!0,this.C=t)},sa.prototype.M=function(){var i=Yo(),n=Yo(),r=Yo();return this.D.forEach(function(t,e){switch(e){case 0:i=i.add(t);break;case 2:n=n.add(t);break;case 1:r=r.add(t);break;default:qn()}}),new Jo(this.C,this.N,i,n,r)},sa.prototype.L=function(){this.k=!1,this.D=ua()},sa.prototype.B=function(t,e){this.k=!0,this.D=this.D.insert(t,e)},sa.prototype.q=function(t){this.k=!0,this.D=this.D.remove(t)},sa.prototype.U=function(){this.S+=1},sa.prototype.K=function(){--this.S},sa.prototype.j=function(){this.k=!0,this.N=!0},sa),na=(ra.prototype.X=function(t){for(var e=0,i=t.v;e<i.length;e++){var n=i[e];t.P&&t.P.isFoundDocument()?this.Z(n,t.P):this.tt(n,t.key,t.P)}for(var r=0,s=t.removedTargetIds;r<s.length;r++)n=s[r],this.tt(n,t.key,t.P)},ra.prototype.et=function(i){var n=this;this.forEachTarget(i,function(t){var e=n.nt(t);switch(i.state){case 0:n.st(t)&&e.O(i.resumeToken);break;case 1:e.K(),e.F||e.L(),e.O(i.resumeToken);break;case 2:e.K(),e.F||n.removeTarget(t);break;case 3:n.st(t)&&(e.j(),e.O(i.resumeToken));break;case 4:n.st(t)&&(n.it(t),e.O(i.resumeToken));break;default:qn()}})},ra.prototype.forEachTarget=function(t,i){var n=this;0<t.targetIds.length?t.targetIds.forEach(i):this.G.forEach(function(t,e){n.st(e)&&i(e)})},ra.prototype.rt=function(t){var e=t.targetId,i=t.V.count;(t=this.ot(e))&&(Kr(t=t.target)?0===i?(t=new Sr(t.path),this.tt(e,t,jr.newNoDocument(t,Qn.min()))):Vn(1===i):this.ct(e)!==i&&(this.it(e),this.Y=this.Y.add(e)))},ra.prototype.ut=function(n){var r=this,s=new Map;this.G.forEach(function(t,e){var i=r.ot(e);i&&(t.current&&Kr(i.target)&&(i=new Sr(i.target.path),null!==r.H.get(i)||r.at(e,i)||r.tt(e,i,jr.newNoDocument(i,n))),t.$&&(s.set(e,t.M()),t.L()))});var o=Yo();this.J.forEach(function(t,e){var i=!0;e.forEachWhile(function(t){return!(t=r.ot(t))||2===t.purpose||(i=!1)}),i&&(o=o.add(t))});var t=new Qo(n,s,this.Y,this.H,o);return this.H=qo,this.J=la(),this.Y=new jo(Kn),t},ra.prototype.Z=function(t,e){var i;this.st(t)&&(i=this.at(t,e.key)?2:0,this.nt(t).B(e.key,i),this.H=this.H.insert(e.key,e),this.J=this.J.insert(e.key,this.ht(e.key).add(t)))},ra.prototype.tt=function(t,e,i){var n;this.st(t)&&(n=this.nt(t),this.at(t,e)?n.B(e,1):n.q(e),this.J=this.J.insert(e,this.ht(e).delete(t)),i&&(this.H=this.H.insert(e,i)))},ra.prototype.removeTarget=function(t){this.G.delete(t)},ra.prototype.ct=function(t){var e=this.nt(t).M();return this.W.getRemoteKeysForTarget(t).size+e.addedDocuments.size-e.removedDocuments.size},ra.prototype.U=function(t){this.nt(t).U()},ra.prototype.nt=function(t){var e=this.G.get(t);return e||(e=new ia,this.G.set(t,e)),e},ra.prototype.ht=function(t){var e=this.J.get(t);return e||(e=new jo(Kn),this.J=this.J.insert(t,e)),e},ra.prototype.st=function(t){var e=null!==this.ot(t);return e||Bn("WatchChangeAggregator","Detected inactive target",t),e},ra.prototype.ot=function(t){var e=this.G.get(t);return e&&e.F?null:this.W.lt(t)},ra.prototype.it=function(e){var i=this;this.G.set(e,new ia),this.W.getRemoteKeysForTarget(e).forEach(function(t){i.tt(e,t,null)})},ra.prototype.at=function(t,e){return this.W.getRemoteKeysForTarget(t).has(e)},ra);function ra(t){this.W=t,this.G=new Map,this.H=qo,this.J=la(),this.Y=new jo(Kn)}function sa(){this.S=0,this.D=ua(),this.C=ur.EMPTY_BYTE_STRING,this.N=!1,this.k=!0}function oa(t,e,i,n,r){this.resumeToken=t,this.current=e,this.addedDocuments=i,this.modifiedDocuments=n,this.removedDocuments=r}function aa(t,e,i,n,r){this.snapshotVersion=t,this.targetChanges=e,this.targetMismatches=i,this.documentUpdates=n,this.resolvedLimboDocuments=r}function la(){return new Oo(Sr.comparator)}function ua(){return new Oo(Sr.comparator)}var ca={asc:"ASCENDING",desc:"DESCENDING"},ha={"<":"LESS_THAN","<=":"LESS_THAN_OR_EQUAL",">":"GREATER_THAN",">=":"GREATER_THAN_OR_EQUAL","==":"EQUAL","!=":"NOT_EQUAL","array-contains":"ARRAY_CONTAINS",in:"IN","not-in":"NOT_IN","array-contains-any":"ARRAY_CONTAINS_ANY"},da=function(t,e){this.databaseId=t,this.I=e};function pa(t,e){return t.I?new Date(1e3*e.seconds).toISOString().replace(/\.\d*/,"").replace("Z","")+"."+("000000000"+e.nanoseconds).slice(-9)+"Z":{seconds:""+e.seconds,nanos:e.nanoseconds}}function fa(t,e){return t.I?e.toBase64():e.toUint8Array()}function ga(t){return Vn(!!t),Qn.fromTimestamp((t=mr(t),new Xn(t.seconds,t.nanos)))}function ma(t,e){return new sr(["projects",t.projectId,"databases",t.database]).child("documents").child(e).canonicalString()}function va(t){return Vn(La(t=sr.fromString(t))),t}function ya(t,e){return ma(t.databaseId,e.path)}function ba(t,e){if((e=va(e)).get(1)!==t.databaseId.projectId)throw new Ln(On.INVALID_ARGUMENT,"Tried to deserialize key from different project: "+e.get(1)+" vs "+t.databaseId.projectId);if(e.get(3)!==t.databaseId.database)throw new Ln(On.INVALID_ARGUMENT,"Tried to deserialize key from different database: "+e.get(3)+" vs "+t.databaseId.database);return new Sr(Ta(e))}function wa(t,e){return ma(t.databaseId,e)}function _a(t){return 4===(t=va(t)).length?sr.emptyPath():Ta(t)}function xa(t){return new sr(["projects",t.databaseId.projectId,"databases",t.databaseId.database]).canonicalString()}function Ta(t){return Vn(4<t.length&&"documents"===t.get(4)),t.popFirst(5)}function Sa(t,e,i){return{name:ya(t,e),fields:i.value.mapValue.fields}}function Ca(t,e,i){var n=ba(t,e.name);t=ga(e.updateTime),e=new Br({mapValue:{fields:e.fields}}),e=jr.newFoundDocument(n,t,e);return i&&e.setHasCommittedMutations(),i?e.setHasCommittedMutations():e}function Ea(t,e){var i,n,r;if(e instanceof vo)i={update:Sa(t,e.key,e.value)};else if(e instanceof Io)i={delete:ya(t,e.key)};else if(e instanceof yo)i={update:Sa(t,e.key,e.data),updateMask:(n=e.fieldMask,r=[],n.fields.forEach(function(t){return r.push(t.canonicalString())}),{fieldPaths:r})};else{if(!(e instanceof Do))return qn();i={verify:ya(t,e.key)}}return 0<e.fieldTransforms.length&&(i.updateTransforms=e.fieldTransforms.map(function(t){var e=t.transform;if(e instanceof Ws)return{fieldPath:t.field.canonicalString(),setToServerValue:"REQUEST_TIME"};if(e instanceof Ks)return{fieldPath:t.field.canonicalString(),appendMissingElements:{values:e.elements}};if(e instanceof Js)return{fieldPath:t.field.canonicalString(),removeAllFromArray:{values:e.elements}};if(e instanceof io)return{fieldPath:t.field.canonicalString(),increment:e.A};throw qn()})),e.precondition.isNone||(i.currentDocument=void 0!==(e=e.precondition).updateTime?{updateTime:pa(t,e.updateTime.toTimestamp())}:void 0!==e.exists?{exists:e.exists}:qn()),i}function ka(s,t){var e=t.currentDocument?void 0!==(o=t.currentDocument).updateTime?lo.updateTime(ga(o.updateTime)):void 0!==o.exists?lo.exists(o.exists):lo.none():lo.none(),i=t.updateTransforms?t.updateTransforms.map(function(t){return e=s,r=null,"setToServerValue"in(i=t)?(Vn("REQUEST_TIME"===i.setToServerValue),r=new Ws):"appendMissingElements"in 
1i?(n=i.appendMissingElements.values||[],r=new Ks(n)):"removeAllFromArray"in i?(n=i.removeAllFromArray.values||[],r=new Js(n)):"increment"in i?r=new io(e,i.increment):qn(),i=ar.fromServerFormat(i.fieldPath),new ao(i,r);var e,i,n,r}):[];if(t.update){t.update.name;var n=ba(s,t.update.name),r=new Br({mapValue:{fields:t.update.fields}});if(t.updateMask){var o=(o=t.updateMask.fieldPaths||[],new lr(o.map(function(t){return ar.fromServerFormat(t)})));return new yo(n,r,o,e,i)}return new vo(n,r,e,i)}return t.delete?(i=ba(s,t.delete),new Io(i,e)):t.verify?(t=ba(s,t.verify),new Do(t,e)):qn()}function Ia(t,e){return{documents:[wa(t,e.path)]}}function Da(t,e){var i={structuredQuery:{}},n=e.path;return null!==e.collectionGroup?(i.parent=wa(t,n),i.structuredQuery.from=[{collectionId:e.collectionGroup,allDescendants:!0}]):(i.parent=wa(t,n.popLast()),i.structuredQuery.from=[{collectionId:n.lastSegment()}]),(n=function(t){if(0!==t.length)return 1===(t=t.map(function(t){if("=="===t.op){if(Rr(t.value))return{unaryFilter:{field:Na(t.field),op:"IS_NAN"}};if(Lr(t.value))return{unaryFilter:{field:Na(t.field),op:"IS_NULL"}}}else if("!="===t.op){if(Rr(t.value))return{unaryFilter:{field:Na(t.field),op:"IS_NOT_NAN"}};if(Lr(t.value))return{unaryFilter:{field:Na(t.field),op:"IS_NOT_NULL"}}}return{fieldFilter:{field:Na(t.field),op:(e=t.op,ha[e]),value:t.value}};var e})).length?t[0]:{compositeFilter:{op:"AND",filters:t}}}(e.filters))&&(i.structuredQuery.where=n),(n=function(t){if(0!==t.length)return t.map(function(t){return{field:Na((t=t).field),direction:(t=t.dir,ca[t])}})}(e.orderBy))&&(i.structuredQuery.orderBy=n),n=e.limit,null!==(n=t.I||_r(n)?n:{value:n})&&(i.structuredQuery.limit=n),e.startAt&&(i.structuredQuery.startAt=Pa(e.startAt)),e.endAt&&(i.structuredQuery.endAt=Pa(e.endAt)),i}function Aa(t){var e=_a(t.parent),i=t.structuredQuery,n=null;0<(o=i.from?i.from.length:0)&&(Vn(1===o),(a=i.from[0]).allDescendants?n=a.collectionId:e=e.child(a.collectionId));var r=[];i.where&&(r=function e(t){return t?void 0!==t.unaryFilter?[function(t){switch(t.unaryFilter.op){case"IS_NAN":var e=Oa(t.unaryFilter.field);return Yr.create(e,"==",{doubleValue:NaN});case"IS_NULL":return e=Oa(t.unaryFilter.field),Yr.create(e,"==",{nullValue:"NULL_VALUE"});case"IS_NOT_NAN":var i=Oa(t.unaryFilter.field);return Yr.create(i,"!=",{doubleValue:NaN});case"IS_NOT_NULL":return i=Oa(t.unaryFilter.field),Yr.create(i,"!=",{nullValue:"NULL_VALUE"});case"OPERATOR_UNSPECIFIED":default:return qn()}}(t)]:void 0!==t.fieldFilter?[(i=t,Yr.create(Oa(i.fieldFilter.field),function(){switch(i.fieldFilter.op){case"EQUAL":return"==";case"NOT_EQUAL":return"!=";case"GREATER_THAN":return">";case"GREATER_THAN_OR_EQUAL":return">=";case"LESS_THAN":return"<";case"LESS_THAN_OR_EQUAL":return"<=";case"ARRAY_CONTAINS":return"array-contains";case"IN":return"in";case"NOT_IN":return"not-in";case"ARRAY_CONTAINS_ANY":return"array-contains-any";case"OPERATOR_UNSPECIFIED":default:return qn()}}(),i.fieldFilter.value))]:void 0!==t.compositeFilter?t.compositeFilter.filters.map(function(t){return e(t)}).reduce(function(t,e){return t.concat(e)}):qn():[];var i}(i.where));var s=[],o=(t=null,null),a=null;return Cs(e,n,s=i.orderBy?i.orderBy.map(function(t){return new _s(Oa((e=t).field),function(){switch(e.direction){case"ASCENDING":return"asc";case"DESCENDING":return"desc";default:return}}());var e}):s,r,t=i.limit?_r(r="object"==typeof(r=i.limit)?r.value:r)?null:r:t,"F",o=i.startAt?Ma(i.startAt):o,a=i.endAt?Ma(i.endAt):a)}function Pa(t){return{before:t.before,values:t.position}}function Ma(t){var e=!!t.before;t=t.values||[];return new gs(t,e)}function Na(t){return{fieldPath:t.canonicalString()}}function Oa(t){return ar.fromServerFormat(t.fieldPath)}function La(t){return 4<=t.length&&"projects"===t.get(0)&&"databases"===t.get(2)}function Ra(t){for(var o="",e=0;e<t.length;e++)0<o.length&&(o=Fa(o)),o=function(t,e){for(var i=o,n=t.length,r=0;r<n;r++){var s=t.charAt(r);switch(s){case"\0":i+="��";break;case"�":i+="��";break;default:i+=s}}return i}(t.get(e));return Fa(o)}function Fa(t){return t+"��"}function za(t){var e=t.length;if(Vn(2<=e),2===e)return Vn("�"===t.charAt(0)&&"�"===t.charAt(1)),sr.emptyPath();for(var i=e-2,n=[],r="",s=0;s<e;){var o=t.indexOf("�",s);switch((o<0||i<o)&&qn(),t.charAt(o+1)){case"�":var a=t.substring(s,o),l=void 0;0===r.length?l=a:(l=r+=a,r=""),n.push(l);break;case"�":r+=t.substring(s,o),r+="\0";break;case"�":r+=t.substring(s,o+1);break;default:qn()}s=o+2}return new sr(n)}function Ba(t,e,i){this.ownerId=t,this.allowTabSynchronization=e,this.leaseTimestampMs=i}var $a=function(t,e){this.seconds=t,this.nanoseconds=e};function ja(t,e,i){this.userId=t,this.lastAcknowledgedBatchId=e,this.lastStreamToken=i}function Ha(t,e,i,n,r){this.userId=t,this.batchId=e,this.localWriteTimeMs=i,this.baseMutations=n,this.mutations=r}
1Ba.store="owner",Ba.key="owner",ja.store="mutationQueues",ja.keyPath="userId",Ha.store="mutations",Ha.keyPath="batchId",Ha.userMutationsIndex="userMutationsIndex",Ha.userMutationsKeyPath=["userId","batchId"];var qa=(Va.prefixForUser=function(t){return[t]},Va.prefixForPath=function(t,e){return[t,Ra(e)]},Va.key=function(t,e,i){return[t,Ra(e),i]},Va);function Va(){}function Ua(t,e){this.path=t,this.readTime=e}function Wa(t,e){this.path=t,this.version=e}qa.store="documentMutations",qa.PLACEHOLDER=new qa;var Ka=function(t,e,i,n,r,s){this.unknownDocument=t,this.noDocument=e,this.document=i,this.hasCommittedMutations=n,this.readTime=r,this.parentPath=s};function Ga(t){this.byteSize=t}function Ya(t,e,i,n,r,s,o){this.targetId=t,this.canonicalId=e,this.readTime=i,this.resumeToken=n,this.lastListenSequenceNumber=r,this.lastLimboFreeSnapshotVersion=s,this.query=o}Ka.store="remoteDocuments",Ka.readTimeIndex="readTimeIndex",Ka.readTimeIndexPath="readTime",Ka.collectionReadTimeIndex="collectionReadTimeIndex",Ka.collectionReadTimeIndexPath=["parentPath","readTime"],Ga.store="remoteDocumentGlobal",Ga.key="remoteDocumentGlobalKey",Ya.store="targets",Ya.keyPath="targetId",Ya.queryTargetsIndexName="queryTargetsIndex",Ya.queryTargetsKeyPath=["canonicalId","targetId"];var Xa=function(t,e,i){this.targetId=t,this.path=e,this.sequenceNumber=i};function Qa(t,e,i,n){this.highestTargetId=t,this.highestListenSequenceNumber=e,this.lastRemoteSnapshotVersion=i,this.targetCount=n}function Ja(t,e){this.collectionId=t,this.parent=e}function Za(t,e,i,n){this.clientId=t,this.updateTimeMs=e,this.networkEnabled=i,this.inForeground=n}function tl(t,e,i){this.bundleId=t,this.createTime=e,this.version=i}function el(t,e,i){this.name=t,this.readTime=e,this.bundledQuery=i}Xa.store="targetDocuments",Xa.keyPath=["targetId","path"],Xa.documentTargetsIndex="documentTargetsIndex",Xa.documentTargetsKeyPath=["path","targetId"],Qa.key="targetGlobalKey",Qa.store="targetGlobal",Ja.store="collectionParents",Ja.keyPath=["collectionId","parent"],Za.store="clientMetadata",Za.keyPath="clientId",tl.store="bundles",tl.keyPath="bundleId",el.store="namedQueries",el.keyPath="name";var il,nl=o(o([],o(o([],o(o([],o(o([],[ja.store,Ha.store,qa.store,Ka.store,Ya.store,Ba.store,Qa.store,Xa.store]),[Za.store])),[Ga.store])),[Ja.store])),[tl.store,el.store]),rl="The current tab is not in the required state to perform this operation. It might be necessary to refresh the browser tab.",sl=(A=(ml.prototype.addOnCommittedListener=function(t){this.onCommittedListeners.push(t)},ml.prototype.raiseOnCommittedEvent=function(){this.onCommittedListeners.forEach(function(t){return t()})},ml),function(){var i=this;this.promise=new Promise(function(t,e){i.resolve=t,i.reject=e})}),ol=(gl.prototype.catch=function(t){return this.next(void 0,t)},gl.prototype.next=function(n,r){var s=this;return this.callbackAttached&&qn(),this.callbackAttached=!0,this.isDone?this.error?this.wrapFailure(r,this.error):this.wrapSuccess(n,this.result):new gl(function(e,i){s.nextCallback=function(t){s.wrapSuccess(n,t).next(e,i)},s.catchCallback=function(t){s.wrapFailure(r,t).next(e,i)}})},gl.prototype.toPromise=function(){var i=this;return new Promise(function(t,e){i.next(t,e)})},gl.prototype.wrapUserFunction=function(t){try{var e=t();return e instanceof gl?e:gl.resolve(e)}catch(t){return gl.reject(t)}},gl.prototype.wrapSuccess=function(t,e){return t?this.wrapUserFunction(function(){return t(e)}):gl.resolve(e)},gl.prototype.wrapFailure=function(t,e){return t?this.wrapUserFunction(function(){return t(e)}):gl.reject(e)},gl.resolve=function(i){return new gl(function(t,e){t(i)})},gl.reject=function(i){return new gl(function(t,e){e(i)})},gl.waitFor=function(t){return new gl(function(e,i){var n=0,r=0,s=!1;t.forEach(function(t){++n,t.next(function(){++r,s&&r===n&&e()},function(t){return i(t)})}),s=!0,r===n&&e()})},gl.or=function(t){for(var i=gl.resolve(!1),e=0,n=t;e<n.length;e++)!function(e){i=i.next(function(t){return t?gl.resolve(t):e()})}(n[e]);return i},gl.forEach=function(t,i){var n=this,r=[];return t.forEach(function(t,e){r.push(i.call(n,t,e))}),this.waitFor(r)}
1,gl),al=(fl.open=function(t,e,i,n){try{return new fl(e,t.transaction(n,i))}catch(t){throw new cl(e,t)}},Object.defineProperty(fl.prototype,"dt",{get:function(){return this.ft.promise},enumerable:!1,configurable:!0}),fl.prototype.abort=function(t){t&&this.ft.reject(t),this.aborted||(Bn("SimpleDb","Aborting transaction:",t?t.message:"Client-initiated abort"),this.aborted=!0,this.transaction.abort())},fl.prototype.store=function(t){return t=this.transaction.objectStore(t),new yl(t)},fl),ll=(pl.delete=function(t){return Bn("SimpleDb","Removing database:",t),wl(window.indexedDB.deleteDatabase(t)).toPromise()},pl.yt=function(){if("undefined"==typeof indexedDB)return!1;if(pl.gt())return!0;var t=c(),e=0<(i=pl._t(t))&&i<10,i=0<(i=pl.Et(t))&&i<4.5;return!(0<t.indexOf("MSIE ")||0<t.indexOf("Trident/")||0<t.indexOf("Edge/")||e||i)},pl.gt=function(){var t;return"undefined"!=typeof process&&"YES"===(null===(t=process.env)||void 0===t?void 0:t.Tt)},pl.It=function(t,e){return t.store(e)},pl._t=function(t){return t=(t=t.match(/i(?:phone|pad|pod) os ([\d_]+)/i))?t[1].split("_").slice(0,2).join("."):"-1",Number(t)},pl.Et=function(t){return t=(t=t.match(/Android ([\d.]+)/i))?t[1].split(".").slice(0,2).join("."):"-1",Number(t)},pl.prototype.At=function(s){return g(this,void 0,void 0,function(){var e,r=this;return m(this,function(t){switch(t.label){case 0:return this.db?[3,2]:(Bn("SimpleDb","Opening database:",this.name),e=this,[4,new Promise(function(e,i){var n=indexedDB.open(r.name,r.version);n.onsuccess=function(t){t=t.target.result,e(t)},n.onblocked=function(){i(new cl(s,"Cannot upgrade IndexedDB schema while another tab is open. Close all tabs that access Firestore and reload this page to proceed."))},n.onerror=function(t){"VersionError"===(t=t.target.error).name?i(new Ln(On.FAILED_PRECONDITION,"A newer version of the Firestore SDK was previously used and so the persisted data is not compatible with the version of the SDK you are now using. The SDK will operate with persistence disabled. If you need persistence, please re-upgrade to a newer version of the SDK or else clear the persisted IndexedDB data for your app to start fresh.")):i(new cl(s,t))},n.onupgradeneeded=function(t){Bn("SimpleDb",'Database "'+r.name+'" requires upgrade from version:',t.oldVersion);var e=t.target.result;r.wt.Rt(e,n.transaction,t.oldVersion,r.version).next(function(){Bn("SimpleDb","Database upgrade to version "+r.version+" complete")})}})]);case 1:e.db=t.sent(),t.label=2;case 2:return[2,(this.bt&&(this.db.onversionchange=function(t){return r.bt(t)}),this.db)]}})})},pl.prototype.vt=function(e){this.bt=e,this.db&&(this.db.onversionchange=function(t){return e(t)})},pl.prototype.runTransaction=function(a,i,l,u){return g(this,void 0,void 0,function(){var r,s,o,e;return m(this,function(t){switch(t.label){case 0:r="readonly"===i,s=0,e=function(){var e,i,n;return m(this,function(t){switch(t.label){case 0:++s,t.label=1;case 1:return t.trys.push([1,4,,5]),[4,o.At(a)];case 2:return o.db=t.sent(),e=al.open(o.db,a,r?"readonly":"readwrite",l),i=u(e).catch(function(t){return e.abort(t),ol.reject(t)}).toPromise(),n={},i.catch(function(){}),[4,e.dt];case 3:return[2,(n.value=(t.sent(),i),n)];case 4:return i=t.sent(),n="FirebaseError"!==i.name&&s<3,Bn("SimpleDb","Transaction failed with error:",i.message,"Retrying:",n),o.close(),n?[3,5]:[2,{value:Promise.reject(i)}];case 5:return[2]}})},o=this,t.label=1;case 1:return[5,e()];case 2:if("object"==typeof(e=t.sent()))return[2,e.value];t.label=3;case 3:return[3,1];case 4:return[2]}})})},pl.prototype.close=function(){this.db&&this.db.close(),this.db=void 0},pl),ul=(Object.defineProperty(dl.prototype,"isDone",{get:function(){return this.Vt},enumerable:!1,configurable:!0}),Object.defineProperty(dl.prototype,"Dt",{get:function(){return this.St},enumerable:!1,configurable:!0}),Object.defineProperty(dl.prototype,"cursor",{set:function(t){this.Pt=t},enumerable:!1,configurable:!0}),dl.prototype.done=function(){this.Vt=!0},dl.prototype.Ct=function(t){this.St=t},dl.prototype.delete=function(){return wl(this.Pt.delete())},dl),cl=(i(hl,il=Ln),hl);function hl(t,e){var i=this;return(i=il.call(this,On.UNAVAILABLE,"IndexedDB transaction '"+t+"' failed: "+e)||this).name="IndexedDbTransactionError",i}function dl(t){this.Pt=t,this.Vt=!1,this.St=null}function pl(t,e,i){this.name=t,this.version=e,this.wt=i,12.2===pl._t(c())&&$n("Firestore persistence suffers from a bug in 
1iOS 12.2 Safari that may cause your app to stop working. See https://stackoverflow.com/q/56496296/110915 for details and a potential workaround.")}function fl(e,t){var i=this;this.action=e,this.transaction=t,this.aborted=!1,this.ft=new sl,this.transaction.oncomplete=function(){i.ft.resolve()},this.transaction.onabort=function(){t.error?i.ft.reject(new cl(e,t.error)):i.ft.resolve()},this.transaction.onerror=function(t){t=xl(t.target.error),i.ft.reject(new cl(e,t))}}function gl(t){var e=this;this.nextCallback=null,this.catchCallback=null,this.result=void 0,this.error=void 0,this.isDone=!1,this.callbackAttached=!1,t(function(t){e.isDone=!0,e.result=t,e.nextCallback&&e.nextCallback(t)},function(t){e.isDone=!0,e.error=t,e.catchCallback&&e.catchCallback(t)})}function ml(){this.onCommittedListeners=[]}function vl(t){return"IndexedDbTransactionError"===t.name}var yl=(bl.prototype.put=function(t,e){return wl(t=void 0!==e?(Bn("SimpleDb","PUT",this.store.name,t,e),this.store.put(e,t)):(Bn("SimpleDb","PUT",this.store.name,"<auto-key>",t),this.store.put(t)))},bl.prototype.add=function(t){return Bn("SimpleDb","ADD",this.store.name,t,t),wl(this.store.add(t))},bl.prototype.get=function(e){var i=this;return wl(this.store.get(e)).next(function(t){return Bn("SimpleDb","GET",i.store.name,e,t=void 0===t?null:t),t})},bl.prototype.delete=function(t){return Bn("SimpleDb","DELETE",this.store.name,t),wl(this.store.delete(t))},bl.prototype.count=function(){return Bn("SimpleDb","COUNT",this.store.name),wl(this.store.count())},bl.prototype.Nt=function(t,e){e=this.cursor(this.options(t,e));var i=[];return this.xt(e,function(t,e){i.push(e)}).next(function(){return i})},bl.prototype.kt=function(t,e){return Bn("SimpleDb","DELETE ALL",this.store.name),(e=this.options(t,e)).Ft=!1,e=this.cursor(e),this.xt(e,function(t,e,i){return i.delete()})},bl.prototype.$t=function(t,e){e?i=t:(i={},e=t);var i=this.cursor(i);return this.xt(i,e)},bl.prototype.Ot=function(n){var t=this.cursor({});return new ol(function(i,e){t.onerror=function(t){t=xl(t.target.error),e(t)},t.onsuccess=function(t){var e=t.target.result;e?n(e.primaryKey,e.value).next(function(t){t?e.continue():i()}):i()}})},bl.prototype.xt=function(t,r){var s=[];return new ol(function(n,e){t.onerror=function(t){e(t.target.error)},t.onsuccess=function(t){var e,i=t.target.result;i?(e=new ul(i),(t=r(i.primaryKey,i.value,e))instanceof ol&&(t=t.catch(function(t){return e.done(),ol.reject(t)}),s.push(t)),e.isDone?n():null===e.Dt?i.continue():i.continue(e.Dt)):n()}}).next(function(){return ol.waitFor(s)})},bl.prototype.options=function(t,e){var i;return void 0!==t&&("string"==typeof t?i=t:e=t),{index:i,range:e}},bl.prototype.cursor=function(t){var e="next";if(t.reverse&&(e="prev"),t.index){var i=this.store.index(t.index);return t.Ft?i.openKeyCursor(t.range,e):i.openCursor(t.range,e)}return this.store.openCursor(t.range,e)},bl);function bl(t){this.store=t}function wl(t){return new ol(function(e,i){t.onsuccess=function(t){t=t.target.result,e(t)},t.onerror=function(t){t=xl(t.target.error),i(t)}})}var _l=!1;function xl(t){var e=ll._t(c());if(12.2<=e&&e<13&&(e="An internal error was encountered in the Indexed Database server",0<=t.message.indexOf(e))){var i=new Ln("internal","IOS_INDEXEDDB_BUG1: IndexedDb has thrown '"+e+"'. This is likely due to an unavoidable bug in iOS. See https://stackoverflow.com/q/56496296/110915 for details and a potential workaround.");return _l||(_l=!0,setTimeout(function(){throw i},0)),i}return t}var Tl,Sl=(i(Cl,Tl=A),Cl);function Cl(t,e){var i=this;return(i=Tl.call(this)||this).Mt=t,i.currentSequenceNumber=e,i}function El(t,e){return ll.It(t.Mt,e)}var kl=(Nl.prototype.applyToRemoteDocument=function(t,e){for(var i,n,r,s,o,a,l=e.mutationResults,u=0;u<this.mutations.length;u++){var c=this.mutations[u];c.key.isEqual(t.key)&&(i=c,n=t,r=l[u],c=a=o=s=void 0,i instanceof vo?(o=n,a=r,c=(s=i).value.clone(),s=xo(s.fieldTransforms,o,a.transformResults),c.setAll(s),o.convertToFoundDocument(a.version,c).setHasCommittedMutations()):i instanceof yo?(s=n,o=r,co((a=i).precondition,s)?(c=xo(a.fieldTransforms,s,o.transformResults),(i=s.data).setAll(_o(a)),i.setAll(c),s.convertToFoundDocument(o.version,i).setHasCommittedMutations()):s.convertToUnknownDocument(o.version)):n.convertToNoDocument(r.version).setHasCommittedMutations())}},Nl.prototype.applyToLocalView=function(t){for(var e=0,i=this.baseMutations;e<i.length;e++)(n=i[e]).key.isEqual(t.key)&&ho(n,t,this.localWriteTime);for(var n,r=0,s=this.mutations;r<s.length;r++)(n=s[r]).key.isEqual(t.key)&&ho(n,t,this.localWriteTime)},Nl.prototype.applyToLocalDocumentSet=function(i){var n=this;this.mutations.forEach(function(t){var e=i.get(t.key);t=e;n.applyToLocalView(t),e.isValidDocument()||t.convertToNoDocument(Qn.min())})},Nl.prototype.keys=function(){return this.mutations.reduce(function(t,e){return t.add(e.key)},Yo())},Nl.prototype.isEqual=function(t){return this.batchId===t.batchId&&Gn(this.mutations,t.mutations,po)&&Gn(this.baseMutations,t.baseMutations,po)}
1,Nl),Il=(Ml.from=function(t,e,i){Vn(t.mutations.length===i.length);for(var n=Ko,r=t.mutations,s=0;s<r.length;s++)n=n.insert(r[s].key,i[s].version);return new Ml(t,e,i,n)},Ml),Dl=(Pl.prototype.withSequenceNumber=function(t){return new Pl(this.target,this.targetId,this.purpose,t,this.snapshotVersion,this.lastLimboFreeSnapshotVersion,this.resumeToken)},Pl.prototype.withResumeToken=function(t,e){return new Pl(this.target,this.targetId,this.purpose,this.sequenceNumber,e,this.lastLimboFreeSnapshotVersion,t)},Pl.prototype.withLastLimboFreeSnapshotVersion=function(t){return new Pl(this.target,this.targetId,this.purpose,this.sequenceNumber,this.snapshotVersion,t,this.resumeToken)},Pl),Al=function(t){this.Lt=t};function Pl(t,e,i,n,r,s,o){void 0===r&&(r=Qn.min()),void 0===s&&(s=Qn.min()),void 0===o&&(o=ur.EMPTY_BYTE_STRING),this.target=t,this.targetId=e,this.purpose=i,this.sequenceNumber=n,this.snapshotVersion=r,this.lastLimboFreeSnapshotVersion=s,this.resumeToken=o}function Ml(t,e,i,n){this.batch=t,this.commitVersion=e,this.mutationResults=i,this.docVersions=n}function Nl(t,e,i,n){this.batchId=t,this.localWriteTime=e,this.baseMutations=i,this.mutations=n}function Ol(t,e){if(e.document)return Ca(t.Lt,e.document,!!e.hasCommittedMutations);if(e.noDocument){var i=Sr.fromSegments(e.noDocument.path),n=Bl(e.noDocument.readTime);i=jr.newNoDocument(i,n);return e.hasCommittedMutations?i.setHasCommittedMutations():i}return e.unknownDocument?(i=Sr.fromSegments(e.unknownDocument.path),n=Bl(e.unknownDocument.version),jr.newUnknownDocument(i,n)):qn()}function Ll(t,e,i){var n=Rl(i);i=e.key.path.popLast().toArray();if(e.isFoundDocument()){var r={name:ya(s=t.Lt,(o=e).key),fields:o.data.value.mapValue.fields,updateTime:pa(s,o.version.toTimestamp())},s=e.hasCommittedMutations;return new Ka(null,null,r,s,n,i)}if(e.isNoDocument()){var o=e.key.path.toArray();r=zl(e.version),s=e.hasCommittedMutations;return new Ka(null,new Ua(o,r),null,s,n,i)}return e.isUnknownDocument()?(s=e.key.path.toArray(),e=zl(e.version),new Ka(new Wa(s,e),null,null,!0,n,i)):qn()}function Rl(t){return[(t=t.toTimestamp()).seconds,t.nanoseconds]}function Fl(t){return t=new Xn(t[0],t[1]),Qn.fromTimestamp(t)}function zl(t){return t=t.toTimestamp(),new $a(t.seconds,t.nanoseconds)}function Bl(t){return t=new Xn(t.seconds,t.nanoseconds),Qn.fromTimestamp(t)}function $l(e,t){for(var i=(t.baseMutations||[]).map(function(t){return ka(e.Lt,t)}),n=0;n<t.mutations.length-1;++n){var r,s=t.mutations[n];n+1<t.mutations.length&&void 0!==t.mutations[n+1].transform&&(r=t.mutations[n+1],s.updateTransforms=r.transform.fieldTransforms,t.mutations.splice(n+1,1),++n)}var o=t.mutations.map(function(t){return ka(e.Lt,t)}),a=Xn.fromMillis(t.localWriteTimeMs);return new kl(t.batchId,a,i,o)}function jl(t){var e=Bl(t.readTime),i=void 0!==t.lastLimboFreeSnapshotVersion?Bl(t.lastLimboFreeSnapshotVersion):Qn.min(),n=void 0!==t.query.documents?(Vn(1===(n=t.query).documents.length),Ns(Es(_a(n.documents[0])))):Ns(Aa(t.query));return new Dl(n,t.targetId,0,t.lastListenSequenceNumber,e,i,ur.fromBase64String(t.resumeToken))}function Hl(t,e){var i=zl(e.snapshotVersion),n=zl(e.lastLimboFreeSnapshotVersion),r=(Kr(e.target)?Ia:Da)(t.Lt,e.target);t=e.resumeToken.toBase64();return new Ya(e.targetId,Ur(e.target),i,t,e.sequenceNumber,n,r)}function ql(t){var e=Aa({parent:t.parent,structuredQuery:t.structuredQuery});return"LAST"===t.limitType?Os(e,e.limit,"L"):e}var Vl=(Ul.prototype.getBundleMetadata=function(t,e){return Wl(t).get(e).next(function(t){if(t)return{id:(t=t).bundleId,createTime:Bl(t.createTime),version:t.version}})},Ul.prototype.saveBundleMetadata=function(t,e){return Wl(t).put({bundleId:(e=e).id,createTime:zl(ga(e.createTime)),version:e.version})},Ul.prototype.getNamedQuery=function(t,e){return Kl(t).get(e).next(function(t){if(t)return{name:(t=t).name,query:ql(t.bundledQuery),readTime:Bl(t.readTime)}})},Ul.prototype.saveNamedQuery=function(t,e){return Kl(t).put({name:(e=e).name,readTime:zl(ga(e.readTime)),bundledQuery:e.bundledQuery})},Ul);function Ul(){}function Wl(t){return El(t,tl.store)}function Kl(t){return El(t,el.store)}var Gl=(Zl.prototype.addToCollectionParentIndex=function(t,e){return this.Bt.add(e),ol.resolve()},Zl.prototype.getCollectionParents=function(t,e){return ol.resolve(this.Bt.getEntries(e))},Zl),Yl=(Jl.prototype.add=function(t){var e=t.lastSegment(),i=t.popLast(),n=this.index[e]||new jo(sr.comparator);t=!n.has(i);return this.index[e]=n.add(i),t},Jl.prototype.has=function(t){var e=t.lastSegment();t=t.popLast();return(e=this.index[e])&&e.has(t)},Jl.prototype.getEntries=function(t){return(this.index[t]||new jo(sr.comparator)).toArray()},Jl),Xl=(Ql.prototype.addToCollectionParentIndex=function(t,e){var i=this;if(this.qt.has(e))return ol.resolve();var n=e.lastSegment(),r=e.popLast();return t.addOnCommittedListener(function(){i.qt.add(e)}),r={collectionId:n,parent:Ra(r)},tu(t).put(r)},Ql.prototype.getCollectionParents=function(t,r){var s=[],e=IDBKeyRange.bound([r,""],[Yn(r),""],!1,!0);return tu(t).Nt(e).next(function(t){for(var e=0,i=t;e<i.length;e++){var n=i[e];if(n.collectionId!==r)break;s.push(za(n.parent))}return s})},Ql);function Ql(){this.qt=new Yl}function Jl(){this.index={}}function Zl(){this.Bt=new Yl}function tu(t){return El(t,Ja.store)}var eu={didRun:!1,sequenceNumbersCollected:0,targetsRemoved:0,documentsRemoved:0},iu=(nu.withCacheSize=function(t){return new nu(t,nu.DEFAULT_COLLECTION_PE
1RCENTILE,nu.DEFAULT_MAX_SEQUENCE_NUMBERS_TO_COLLECT)},nu);function nu(t,e,i){this.cacheSizeCollectionThreshold=t,this.percentileToCollect=e,this.maximumSequenceNumbersToCollect=i}function ru(t,e,i){var n=t.store(Ha.store),r=t.store(qa.store),s=[],o=(t=IDBKeyRange.only(i.batchId),0);t=n.$t({range:t},function(t,e,i){return o++,i.delete()});s.push(t.next(function(){Vn(1===o)}));for(var a=[],l=0,u=i.mutations;l<u.length;l++){var c=u[l],h=qa.key(e,c.key.path,i.batchId);s.push(r.delete(h)),a.push(c.key)}return ol.waitFor(s).next(function(){return a})}function su(t){if(!t)return 0;var e;if(t.document)e=t.document;else if(t.unknownDocument)e=t.unknownDocument;else{if(!t.noDocument)throw qn();e=t.noDocument}return JSON.stringify(e).length}iu.DEFAULT_COLLECTION_PERCENTILE=10,iu.DEFAULT_MAX_SEQUENCE_NUMBERS_TO_COLLECT=1e3,iu.DEFAULT=new iu(41943040,iu.DEFAULT_COLLECTION_PERCENTILE,iu.DEFAULT_MAX_SEQUENCE_NUMBERS_TO_COLLECT),iu.DISABLED=new iu(-1,0,0);var ou=(au.Qt=function(t,e,i,n){return Vn(""!==t.uid),new au(t.isAuthenticated()?t.uid:"",e,i,n)},au.prototype.checkEmpty=function(t){var n=!0,e=IDBKeyRange.bound([this.userId,Number.NEGATIVE_INFINITY],[this.userId,Number.POSITIVE_INFINITY]);return uu(t).$t({index:Ha.userMutationsIndex,range:e},function(t,e,i){n=!1,i.done()}).next(function(){return n})},au.prototype.addMutationBatch=function(f,g,m,v){var y=this,b=cu(f),w=uu(f);return w.add({}).next(function(t){Vn("number"==typeof t);for(var e,i,n,r,s,o=new kl(t,g,m,v),a=(e=y.R,i=y.userId,r=(n=o).baseMutations.map(function(t){return Ea(e.Lt,t)}),s=n.mutations.map(function(t){return Ea(e.Lt,t)}),new Ha(i,n.batchId,n.localWriteTime.toMillis(),r,s)),l=[],u=new jo(function(t,e){return Kn(t.canonicalString(),e.canonicalString())}),c=0,h=v;c<h.length;c++){var d=h[c],p=qa.key(y.userId,d.key.path,t);u=u.add(d.key.path.popLast());l.push(w.put(a)),l.push(b.put(p,qa.PLACEHOLDER))}return u.forEach(function(t){l.push(y.Ut.addToCollectionParentIndex(f,t))}),f.addOnCommittedListener(function(){y.Kt[t]=o.keys()}),ol.waitFor(l).next(function(){return o})})},au.prototype.lookupMutationBatch=function(t,e){var i=this;return uu(t).get(e).next(function(t){return t?(Vn(t.userId===i.userId),$l(i.R,t)):null})},au.prototype.jt=function(t,e){var i=this;return this.Kt[e]?ol.resolve(this.Kt[e]):this.lookupMutationBatch(t,e).next(function(t){return t?(t=t.keys(),i.Kt[e]=t):null})},au.prototype.getNextMutationBatchAfterBatchId=function(t,e){var n=this,r=e+1,s=(e=IDBKeyRange.lowerBound([this.userId,r]),null);return uu(t).$t({index:Ha.userMutationsIndex,range:e},function(t,e,i){e.userId===n.userId&&(Vn(e.batchId>=r),s=$l(n.R,e)),i.done()}).next(function(){return s})},au.prototype.getHighestUnacknowledgedBatchId=function(t){var e=IDBKeyRange.upperBound([this.userId,Number.POSITIVE_INFINITY]),n=-1;return uu(t).$t({index:Ha.userMutationsIndex,range:e,reverse:!0},function(t,e,i){n=e.batchId,i.done()}).next(function(){return n})},au.prototype.getAllMutationBatches=function(t){var e=this,i=IDBKeyRange.bound([this.userId,-1],[this.userId,Number.POSITIVE_INFINITY]);return uu(t).Nt(Ha.userMutationsIndex,i).next(function(t){return t.map(function(t){return $l(e.R,t)})})},au.prototype.getAllMutationBatchesAffectingDocumentKey=function(s,o){var a=this,t=qa.prefixForPath(this.userId,o.path),l=(t=IDBKeyRange.lowerBound(t),[]);return cu(s).$t({range:t},function(t,e,i){var n=t[0],r=t[1];t=t[2],r=za(r);if(n===a.userId&&o.path.isEqual(r))return uu(s).get(t).next(function(t){if(!t)throw qn();Vn(t.userId===a.userId),l.push($l(a.R,t))});i.done()}).next(function(){return l})},au.prototype.getAllMutationBatchesAffectingDocumentKeys=function(e,t){var o=this,a=new jo(Kn),i=[];return t.forEach(function(s){var t=qa.prefixForPath(o.userId,s.path);t=IDBKeyRange.lowerBound(t),t=cu(e).$t({range:t},function(t,e,i){var n=t[0],r=t[1];t=t[2],r=za(r);n===o.userId&&s.path.isEqual(r)?a=a.add(t):i.done()});i.push(t)}),ol.waitFor(i).next(function(){return o.Wt(e,a)})},au.prototype.getAllMutationBatchesAffectingQuery=function(t,e){var s=this,o=e.path,a=o.length+1,l=(e=qa.prefixForPath(this.userId,o),e=IDBKeyRange.lowerBound(e),new jo(Kn));return cu(t).$t({range:e}
1,function(t,e,i){var n=t[0],r=t[1];t=t[2],r=za(r);n===s.userId&&o.isPrefixOf(r)?r.length===a&&(l=l.add(t)):i.done()}).next(function(){return s.Wt(t,l)})},au.prototype.Wt=function(e,t){var i=this,n=[],r=[];return t.forEach(function(t){r.push(uu(e).get(t).next(function(t){if(null===t)throw qn();Vn(t.userId===i.userId),n.push($l(i.R,t))}))}),ol.waitFor(r).next(function(){return n})},au.prototype.removeMutationBatch=function(e,i){var n=this;return ru(e.Mt,this.userId,i).next(function(t){return e.addOnCommittedListener(function(){n.Gt(i.batchId)}),ol.forEach(t,function(t){return n.referenceDelegate.markPotentiallyOrphaned(e,t)})})},au.prototype.Gt=function(t){delete this.Kt[t]},au.prototype.performConsistencyCheck=function(e){var r=this;return this.checkEmpty(e).next(function(t){if(!t)return ol.resolve();t=IDBKeyRange.lowerBound(qa.prefixForUser(r.userId));var n=[];return cu(e).$t({range:t},function(t,e,i){t[0]===r.userId?(t=za(t[1]),n.push(t)):i.done()}).next(function(){Vn(0===n.length)})})},au.prototype.containsKey=function(t,e){return lu(t,this.userId,e)},au.prototype.zt=function(t){var e=this;return hu(t).get(this.userId).next(function(t){return t||new ja(e.userId,-1,"")})},au);function au(t,e,i,n){this.userId=t,this.R=e,this.Ut=i,this.referenceDelegate=n,this.Kt={}}function lu(t,s,e){var o=(e=qa.prefixForPath(s,e.path))[1],a=(e=IDBKeyRange.lowerBound(e),!1);return cu(t).$t({range:e,Ft:!0},function(t,e,i){var n=t[0],r=t[1];t[2],n===s&&r===o&&(a=!0),i.done()}).next(function(){return a})}function uu(t){return El(t,Ha.store)}function cu(t){return El(t,qa.store)}function hu(t){return El(t,ja.store)}var du=(gu.prototype.next=function(){return this.Ht+=2,this.Ht},gu.Jt=function(){return new gu(0)},gu.Yt=function(){return new gu(-1)},gu),pu=(fu.prototype.allocateTargetId=function(i){var n=this;return this.Xt(i).next(function(t){var e=new du(t.highestTargetId);return t.highestTargetId=e.next(),n.Zt(i,t).next(function(){return t.highestTargetId})})},fu.prototype.getLastRemoteSnapshotVersion=function(t){return this.Xt(t).next(function(t){return Qn.fromTimestamp(new Xn(t.lastRemoteSnapshotVersion.seconds,t.lastRemoteSnapshotVersion.nanoseconds))})},fu.prototype.getHighestSequenceNumber=function(t){return this.Xt(t).next(function(t){return t.highestListenSequenceNumber})},fu.prototype.setTargetsMetadata=function(e,i,n){var r=this;return this.Xt(e).next(function(t){return t.highestListenSequenceNumber=i,n&&(t.lastRemoteSnapshotVersion=n.toTimestamp()),i>t.highestListenSequenceNumber&&(t.highestListenSequenceNumber=i),r.Zt(e,t)})},fu.prototype.addTargetData=function(e,i){var n=this;return this.te(e,i).next(function(){return n.Xt(e).next(function(t){return t.targetCount+=1,n.ee(i,t),n.Zt(e,t)})})},fu.prototype.updateTargetData=function(t,e){return this.te(t,e)},fu.prototype.removeTargetData=function(e,t){var i=this;return this.removeMatchingKeysForTargetId(e,t.targetId).next(function(){return mu(e).delete(t.targetId)}).next(function(){return i.Xt(e)}).next(function(t){return Vn(0<t.targetCount),--t.targetCount,i.Zt(e,t)})},fu.prototype.removeTargets=function(i,n,r){var s=this,o=0,a=[];return mu(i).$t(function(t,e){(e=jl(e)).sequenceNumber<=n&&null===r.get(e.targetId)&&(o++,a.push(s.removeTargetData(i,e)))}).next(function(){return ol.waitFor(a)}).next(function(){return o})},fu.prototype.forEachTarget=function(t,i){return mu(t).$t(function(t,e){e=jl(e),i(e)})},fu.prototype.Xt=function(t){return vu(t).get(Qa.key).next(function(t){return Vn(null!==t),t})},fu.prototype.Zt=function(t,e){return vu(t).put(Qa.key,e)},fu.prototype.te=function(t,e){return mu(t).put(Hl(this.R,e))},fu.prototype.ee=function(t,e){var i=!1;return t.targetId>e.highestTargetId&&(e.highestTargetId=t.targetId,i=!0),t.sequenceNumber>e.highestListenSequenceNumber&&(e.highestListenSequenceNumber=t.sequenceNumber,i=!0),i},fu.prototype.getTargetCount=function(t){return this.Xt(t).next(function(t){return t.targetCount})},fu.prototype.getTargetData=function(t,n){var e=Ur(n),r=(e=IDBKeyRange.bound([e,Number.NEGATIVE_INFINITY],[e,Number.POSITIVE_INFINITY]),null);return mu(t).$t({range:e,index:Ya.queryTargetsIndexName}
1,function(t,e,i){e=jl(e),Wr(n,e.target)&&(r=e,i.done())}).next(function(){return r})},fu.prototype.addMatchingKeys=function(i,t,n){var r=this,s=[],o=yu(i);return t.forEach(function(t){var e=Ra(t.path);s.push(o.put(new Xa(n,e))),s.push(r.referenceDelegate.addReference(i,n,t))}),ol.waitFor(s)},fu.prototype.removeMatchingKeys=function(i,t,n){var r=this,s=yu(i);return ol.forEach(t,function(t){var e=Ra(t.path);return ol.waitFor([s.delete([n,e]),r.referenceDelegate.removeReference(i,n,t)])})},fu.prototype.removeMatchingKeysForTargetId=function(t,e){return t=yu(t),e=IDBKeyRange.bound([e],[e+1],!1,!0),t.delete(e)},fu.prototype.getMatchingKeysForTargetId=function(t,e){e=IDBKeyRange.bound([e],[e+1],!1,!0),t=yu(t);var n=Yo();return t.$t({range:e,Ft:!0},function(t,e,i){t=za(t[1]),t=new Sr(t),n=n.add(t)}).next(function(){return n})},fu.prototype.containsKey=function(t,e){e=Ra(e.path),e=IDBKeyRange.bound([e],[Yn(e)],!1,!0);var r=0;return yu(t).$t({index:Xa.documentTargetsIndex,Ft:!0,range:e},function(t,e,i){var n=t[0];t[1],0!==n&&(r++,i.done())}).next(function(){return 0<r})},fu.prototype.lt=function(t,e){return mu(t).get(e).next(function(t){return t?jl(t):null})},fu);function fu(t,e){this.referenceDelegate=t,this.R=e}function gu(t){this.Ht=t}function mu(t){return El(t,Ya.store)}function vu(t){return El(t,Qa.store)}function yu(t){return El(t,Xa.store)}function bu(e){return g(this,void 0,void 0,function(){return m(this,function(t){if(e.code!==On.FAILED_PRECONDITION||e.message!==rl)throw e;return Bn("LocalStore","Unexpectedly lost primary lease"),[2]})})}function wu(t,e){var i=t[0],n=t[1];t=e[0],e=e[1];return 0===(t=Kn(i,t))?Kn(n,e):t}var _u=(Iu.prototype.ie=function(){return++this.se},Iu.prototype.re=function(t){var e=[t,this.ie()];this.buffer.size<this.ne?this.buffer=this.buffer.add(e):wu(e,t=this.buffer.last())<0&&(this.buffer=this.buffer.delete(t).add(e))},Object.defineProperty(Iu.prototype,"maxValue",{get:function(){return this.buffer.last()[0]},enumerable:!1,configurable:!0}),Iu),xu=(ku.prototype.start=function(t){-1!==this.garbageCollector.params.cacheSizeCollectionThreshold&&this.ue(t)},ku.prototype.stop=function(){this.ce&&(this.ce.cancel(),this.ce=null)},Object.defineProperty(ku.prototype,"started",{get:function(){return null!==this.ce},enumerable:!1,configurable:!0}),ku.prototype.ue=function(i){var t=this,e=this.oe?3e5:6e4;Bn("LruGarbageCollector","Garbage collection scheduled in "+e+"ms"),this.ce=this.asyncQueue.enqueueAfterDelay("lru_garbage_collection",e,function(){return g(t,void 0,void 0,function(){var e;return m(this,function(t){switch(t.label){case 0:this.ce=null,this.oe=!0,t.label=1;case 1:return t.trys.push([1,3,,7]),[4,i.collectGarbage(this.garbageCollector)];case 2:return t.sent(),[3,7];case 3:return vl(e=t.sent())?(Bn("LruGarbageCollector","Ignoring IndexedDB error during garbage collection: ",e),[3,6]):[3,4];case 4:return[4,bu(e)];case 5:t.sent(),t.label=6;case 6:return[3,7];case 7:return[4,this.ue(i)];case 8:return t.sent(),[2]}})})})},ku),Tu=(Eu.prototype.calculateTargetCount=function(t,e){return this.ae.he(t).next(function(t){return Math.floor(e/100*t)})},Eu.prototype.nthSequenceNumber=function(t,e){var i=this;if(0===e)return ol.resolve(Pn.o);var n=new _u(e);return this.ae.forEachTarget(t,function(t){return n.re(t.sequenceNumber)}).next(function(){return i.ae.le(t,function(t){return n.re(t)})}).next(function(){return n.maxValue})},Eu.prototype.removeTargets=function(t,e,i){return this.ae.removeTargets(t,e,i)},Eu.prototype.removeOrphanedDocuments=function(t,e){return this.ae.removeOrphanedDocuments(t,e)},Eu.prototype.collect=function(e,i){var n=this;return-1===this.params.cacheSizeCollectionThreshold?(Bn("LruGarbageCollector","Garbage collection skipped; disabled"),ol.resolve(eu)):this.getCacheSize(e).next(function(t){return t<n.params.cacheSizeCollectionThreshold?(Bn("LruGarbageCollector","Garbage collection skipped; Cache size "+t+" is lower than threshold "+n.params.cacheSizeCollectionThreshold),eu):n.fe(e,i)})},Eu.prototype.getCacheSize=function(t){return this.ae.getCacheSize(t)},Eu.prototype.fe=function(e,i){var n,r,s,o,a,l,u,c=this,h=Date.now();return this.calculateTargetCount(e,this.params.percentileToCollect).next(function(t){return r=t>c.params.maximumSequenceNumbersToCollect?(Bn("LruGarbageCollector","Capping sequence numbers to collect down to the maximum of "+c.params.maximumSequenceNumbersToCollect+" from "+t),c.params.maximumSequenceNumbersToCollect):t,o=Date.now(),c.nthSequenceNumber(e,r)}).next(function(t){return n=t,a=Date.now(),c.removeTargets(e,n,i)}).next(function(t){return s=t,l=Date.now(),c.removeOrphanedDocuments(e,n)}).next(function(t){return u=Date.now(),zn()<=y.DEBUG&&Bn("LruGarbageCollector","LRU Garbage Collection\n\tCounted targets in "+(o-h)+"ms\n\tDetermined least recently used "+r+" in "+(a-o)+"ms\n\tRemoved "+s+" targets in "+(l-a)+"ms\n\tRemoved "+t+" documents in "+(u-l)+"ms\nTotal Duration: "+(u-h)+"ms"),ol.resolve({didRun:!0,sequenceNumbersCollected:r,targetsRemoved:s,documentsRemoved:t})})},Eu),Su=(Cu.prototype.he=function(t){var i=this.de(t);return this.db.getTargetCache().getTargetCount(t).next(function(e){return i.next(function(t){return e+t})})},Cu.prototype.de=function(t){var e=0;return this.le(t,function(t){e++}).next(function(){return e})},Cu.prototype.forEachTarget=function(t,e){return this.db.getTargetCache().forEac
1hTarget(t,e)},Cu.prototype.le=function(t,i){return this.we(t,function(t,e){return i(e)})},Cu.prototype.addReference=function(t,e,i){return Du(t,i)},Cu.prototype.removeReference=function(t,e,i){return Du(t,i)},Cu.prototype.removeTargets=function(t,e,i){return this.db.getTargetCache().removeTargets(t,e,i)},Cu.prototype.markPotentiallyOrphaned=Du,Cu.prototype._e=function(t,e){return n=e,r=!1,hu(i=t).Ot(function(t){return lu(i,t,n).next(function(t){return t&&(r=!0),ol.resolve(!t)})}).next(function(){return r});var i,n,r},Cu.prototype.removeOrphanedDocuments=function(i,n){var r=this,s=this.db.getRemoteDocumentCache().newChangeBuffer(),o=[],a=0;return this.we(i,function(e,t){t<=n&&(t=r._e(i,e).next(function(t){if(!t)return a++,s.getEntry(i,e).next(function(){return s.removeEntry(e),yu(i).delete([0,Ra(e.path)])})}),o.push(t))}).next(function(){return ol.waitFor(o)}).next(function(){return s.apply(i)}).next(function(){return a})},Cu.prototype.removeTarget=function(t,e){return e=e.withSequenceNumber(t.currentSequenceNumber),this.db.getTargetCache().updateTargetData(t,e)},Cu.prototype.updateLimboDocument=Du,Cu.prototype.we=function(t,n){t=yu(t);var r,s=Pn.o;return t.$t({index:Xa.documentTargetsIndex},function(t,e){var i=t[0];t[1],t=e.path,e=e.sequenceNumber,0===i?(s!==Pn.o&&n(new Sr(za(r)),s),s=e,r=t):s=Pn.o}).next(function(){s!==Pn.o&&n(new Sr(za(r)),s)})},Cu.prototype.getCacheSize=function(t){return this.db.getRemoteDocumentCache().getSize(t)},Cu);function Cu(t,e){this.db=t,this.garbageCollector=new Tu(this,e)}function Eu(t,e){this.ae=t,this.params=e}function ku(t,e){this.garbageCollector=t,this.asyncQueue=e,this.oe=!1,this.ce=null}function Iu(t){this.ne=t,this.buffer=new jo(wu),this.se=0}function Du(t,e){return yu(t).put((t=t.currentSequenceNumber,new Xa(0,Ra(e.path),t)))}var Au,Pu=(Fu.prototype.get=function(t){var e=this.mapKeyFn(t);if(void 0!==(e=this.inner[e]))for(var i=0,n=e;i<n.length;i++){var r=(s=n[i])[0],s=s[1];if(this.equalsFn(r,t))return s}},Fu.prototype.has=function(t){return void 0!==this.get(t)},Fu.prototype.set=function(t,e){var i=this.mapKeyFn(t),n=this.inner[i];if(void 0!==n){for(var r=0;r<n.length;r++)if(this.equalsFn(n[r][0],t))return void(n[r]=[t,e]);n.push([t,e])}else this.inner[i]=[[t,e]]},Fu.prototype.delete=function(t){var e=this.mapKeyFn(t),i=this.inner[e];if(void 0===i)return!1;for(var n=0;n<i.length;n++)if(this.equalsFn(i[n][0],t))return 1===i.length?delete this.inner[e]:i.splice(n,1),!0;return!1},Fu.prototype.forEach=function(o){er(this.inner,function(t,e){for(var i=0,n=e;i<n.length;i++){var r=(s=n[i])[0],s=s[1];o(r,s)}})},Fu.prototype.isEmpty=function(){return ir(this.inner)},Fu),Mu=(C=(Ru.prototype.getReadTime=function(t){return(t=this.changes.get(t))?t.readTime:Qn.min()},Ru.prototype.addEntry=function(t,e){this.assertNotApplied(),this.changes.set(t.key,{document:t,readTime:e})},Ru.prototype.removeEntry=function(t,e){void 0===e&&(e=null),this.assertNotApplied(),this.changes.set(t,{document:jr.newInvalidDocument(t),readTime:e})},Ru.prototype.getEntry=function(t,e){this.assertNotApplied();var i=this.changes.get(e);return void 0!==i?ol.resolve(i.document):this.getFromCache(t,e)},Ru.prototype.getEntries=function(t,e){return this.getAllFromCache(t,e)},Ru.prototype.apply=function(t){return this.assertNotApplied(),this.changesApplied=!0,this.applyChanges(t)},Ru.prototype.assertNotApplied=function(){},Ru),Lu.prototype.addEntry=function(t,e,i){return Bu(t).put($u(e),i)},Lu.prototype.removeEntry=function(t,e){return t=Bu(t),e=$u(e),t.delete(e)},Lu.prototype.updateMetadata=function(e,i){var n=this;return this.getMetadata(e).next(function(t){return t.byteSize+=i,n.me(e,t)})},Lu.prototype.getEntry=function(t,e){var i=this;return Bu(t).get($u(e)).next(function(t){return i.ye(e,t)})},Lu.prototype.ge=function(t,e){var i=this;return Bu(t).get($u(e)).next(function(t){return{document:i.ye(e,t),size:su(t)}})},Lu.prototype.getEntries=function(t,e){var i=this,n=qo;return this.pe(t,e,function(t,e){e=i.ye(t,e),n=n.insert(t,e)}).next(function(){return n})},Lu.prototype.Ee=function(t,e){var n=this,r=qo,s=new Oo(Sr.comparator);return this.pe(t,e,function(t,e){var i=n.ye(t,e);r=r.insert(t,i),s=s.insert(t,su(e))}).next(function(){return{documents:r,Te:s}})},Lu.prototype.pe=function(t,e,r){if(e.isEmpty())return ol.resolve();var i=IDBKeyRange.bound(e.first().path.toArray(),e.last().path.toArray()),s=e.getIterator(),o=s.getNext();return Bu(t).$t({range:i}
1,function(t,e,i){for(var n=Sr.fromSegments(t);o&&Sr.comparator(o,n)<0;)r(o,null),o=s.getNext();o&&o.isEqual(n)&&(r(o,e),o=s.hasNext()?s.getNext():null),o?i.Ct(o.path.toArray()):i.done()}).next(function(){for(;o;)r(o,null),o=s.hasNext()?s.getNext():null})},Lu.prototype.getDocumentsMatchingQuery=function(t,n,e){var i,r=this,s=qo,o=n.path.length+1,a={};return e.isEqual(Qn.min())?(i=n.path.toArray(),a.range=IDBKeyRange.lowerBound(i)):(i=n.path.toArray(),e=Rl(e),a.range=IDBKeyRange.lowerBound([i,e],!0),a.index=Ka.collectionReadTimeIndex),Bu(t).$t(a,function(t,e,i){t.length===o&&(e=Ol(r.R,e),n.path.isPrefixOf(e.key.path)?zs(n,e)&&(s=s.insert(e.key,e)):i.done())}).next(function(){return s})},Lu.prototype.newChangeBuffer=function(t){return new Nu(this,!!t&&t.trackRemovals)},Lu.prototype.getSize=function(t){return this.getMetadata(t).next(function(t){return t.byteSize})},Lu.prototype.getMetadata=function(t){return zu(t).get(Ga.key).next(function(t){return Vn(!!t),t})},Lu.prototype.me=function(t,e){return zu(t).put(Ga.key,e)},Lu.prototype.ye=function(t,e){return!e||(e=Ol(this.R,e)).isNoDocument()&&e.version.isEqual(Qn.min())?jr.newInvalidDocument(t):e},Lu),Nu=(i(Ou,Au=C),Ou.prototype.applyChanges=function(r){var s=this,o=[],a=0,l=new jo(function(t,e){return Kn(t.canonicalString(),e.canonicalString())});
1return this.changes.forEach(function(t,e){var i,n=s.Ae.get(t);e.document.isValidDocument()?(i=Ll(s.Ie.R,e.document,s.getReadTime(t)),l=l.add(t.path.popLast()),e=su(i),a+=e-n,o.push(s.Ie.addEntry(r,t,i))):(a-=n,s.trackRemovals?(n=Ll(s.Ie.R,jr.newNoDocument(t,Qn.min()),s.getReadTime(t)),o.push(s.Ie.addEntry(r,t,n))):o.push(s.Ie.removeEntry(r,t)))}),l.forEach(function(t){o.push(s.Ie.Ut.addToCollectionParentIndex(r,t))}),o.push(this.Ie.updateMetadata(r,a)),ol.waitFor(o)},Ou.prototype.getFromCache=function(t,e){var i=this;return this.Ie.ge(t,e).next(function(t){return i.Ae.set(e,t.size),t.document})},Ou.prototype.getAllFromCache=function(t,e){var i=this;return this.Ie.Ee(t,e).next(function(t){var e=t.documents;return t.Te.forEach(function(t,e){i.Ae.set(t,e)}),e})},Ou);function Ou(t,e){var i=this;return(i=Au.call(this)||this).Ie=t,i.trackRemovals=e,i.Ae=new Pu(function(t){return t.toString()},function(t,e){return t.isEqual(e)}),i}function Lu(t,e){this.R=t,this.Ut=e}function Ru(){this.changes=new Pu(function(t){return t.toString()},function(t,e){return t.isEqual(e)}),this.changesApplied=!1}function Fu(t,e){this.mapKeyFn=t,this.equalsFn=e,this.inner={}}function zu(t){return El(t,Ga.store)}function Bu(t){return El(t,Ka.store)}function $u(t){return t.path.toArray()}var ju=(Hu.prototype.Rt=function(e,i,t,n){var r=this;Vn(t<n&&0<=t&&n<=11);var s=new al("createOrUpgrade",i);t<1&&1<=n&&(e.createObjectStore(Ba.store),(o=e).createObjectStore(ja.store,{keyPath:ja.keyPath}),o.createObjectStore(Ha.store,{keyPath:Ha.keyPath,autoIncrement:!0}).createIndex(Ha.userMutationsIndex,Ha.userMutationsKeyPath,{unique:!0}),o.createObjectStore(qa.store),qu(e),e.createObjectStore(Ka.store));var o,a=ol.resolve();return t<3&&3<=n&&(0!==t&&((o=e).deleteObjectStore(Xa.store),o.deleteObjectStore(Ya.store),o.deleteObjectStore(Qa.store),qu(e)),a=a.next(function(){return t=s.store(Qa.store),e=new Qa(0,0,Qn.min().toTimestamp(),0),t.put(Qa.key,e);var t,e})),t<4&&4<=n&&(a=(a=0!==t?a.next(function(){return i=e,(n=s).store(Ha.store).Nt().next(function(t){i.deleteObjectStore(Ha.store),i.createObjectStore(Ha.store,{keyPath:Ha.keyPath,autoIncrement:!0}).createIndex(Ha.userMutationsIndex,Ha.userMutationsKeyPath,{unique:!0});var e=n.store(Ha.store);t=t.map(function(t){return e.put(t)});return ol.waitFor(t)});var i,n}):a).next(function(){e.createObjectStore(Za.store,{keyPath:Za.keyPath})})),t<5&&5<=n&&(a=a.next(function(){return r.Re(s)})),t<6&&6<=n&&(a=a.next(function(){return e.createObjectStore(Ga.store),r.be(s)})),t<7&&7<=n&&(a=a.next(function(){return r.ve(s)})),t<8&&8<=n&&(a=a.next(function(){return r.Pe(e,s)})),t<9&&9<=n&&(a=a.next(function(){var t;(t=e).objectStoreNames.contains("remoteDocumentChanges")&&t.deleteObjectStore("remoteDocumentChanges"),(t=i.objectStore(Ka.store)).createIndex(Ka.readTimeIndex,Ka.readTimeIndexPath,{unique:!1}),t.createIndex(Ka.collectionReadTimeIndex,Ka.collectionReadTimeIndexPath,{unique:!1})})),t<10&&10<=n&&(a=a.next(function(){return r.Ve(s)})),t<11&&11<=n?a.next(function(){e.createObjectStore(tl.store,{keyPath:tl.keyPath}),e.createObjectStore(el.store,{keyPath:el.keyPath})}):a},Hu.prototype.be=function(e){var i=0;return e.store(Ka.store).$t(function(t,e){i+=su(e)}).next(function(){var t=new Ga(i);return e.store(Ga.store).put(Ga.key,t)})},Hu.prototype.Re=function(i){var n=this,t=i.store(ja.store),r=i.store(Ha.store);return t.Nt().next(function(t){return ol.forEach(t,function(e){var t=IDBKeyRange.bound([e.userId,-1],[e.userId,e.lastAcknowledgedBatchId]);return r.Nt(Ha.userMutationsIndex,t).next(function(t){return ol.forEach(t,function(t){return Vn(t.userId===e.userId),t=$l(n.R,t),ru(i,e.userId,t).next(function(){})})})})})},Hu.prototype.ve=function(t){var s=t.store(Xa.store),e=t.store(Ka.store);return t.store(Qa.store).get(Qa.key).next(function(n){var r=[];return e.$t(function(t,e){var i=new sr(t);t=[0,Ra(i)];r.push(s.get(t).next(function(t){return t?ol.resolve():s.put(new Xa(0,Ra(i),n.highestListenSequenceNumber))}))}).next(function(){return ol.waitFor(r)})})},Hu.prototype.Pe=function(t,e){function n(t){if(r.add(t)){var e=t.lastSegment();t=t.popLast();return i.put({collectionId:e,parent:Ra(t)})}}t.createObjectStore(Ja.store,{keyPath:Ja.keyPath});var i=e.store(Ja.store),r=new Yl;return e.store(Ka.store).$t({Ft:!0},function(t,e){return n((t=new sr(t)).popLast())}).next(function(){return e.store(qa.store).$t({Ft:!0},function(t,e){t[0];var i=t[1];return t[2],n((i=za(i)).popLast())})})},Hu.prototype.Ve=function(t){var i=this,n=t.store(Ya.store);return n.$t(function(t,e){return e=jl(e),e=Hl(i.R,e),n.put(e)})},Hu);function Hu(t){this.R=t}function qu(t){t.createObjectStore(Xa.store,{keyPath:Xa.keyPath}).createIndex(Xa.documentTargetsIndex,Xa.documentTargetsKeyPath,{unique:!0}),t.createObjectStore(Ya.store,{keyPath:Ya.keyPath}).createIndex(Ya.queryTargetsIndexName,Ya.queryTargetsKeyPath,{unique:!0}),t.createObjectStore(Qa.store)}var Vu="Failed to obtain exclusive access to the persistence layer. To allow shared access, multi-tab synchronization has to be enabled in all tabs. If you are using `experimentalForceOwningTab:true`, make sure that only one tab has persistence enabled at any given time.",Uu=(Wu.prototype.start=function(){var e=this;return this.je().then(function(){if(!e.isPrimary&&!e.allowTabSynchronization)throw new Ln(On.FAILED_PRECONDITION,Vu);return e.We(),e.Ge(),e.ze(),e.runTransaction("getHighestListenSequenceNumber","readonly",function(t){return e.qe.getHighestSequenceNumber(t)})}).then(function(t){e.Ne=new Pn(t,e.De)}).then(function(){e.xe=!0}).catch(function(t){return e.Be&&e.Be.close(),Promise.reject(t)})},Wu.prototype.He=function(i){var t=this;return this.Me=function(e){return g(t,void 0,void 0,function(){return m(this,function(t){return this.started?[2,i(e)]:[2]})})},i(this.isPrimary)},Wu.prototype.setDatabaseDeletedListener=function(i){var t=this;this.Be.vt(function(e){return g(t,void 0,void 0,function(){return m(this,function(t){switch(t.label){case 0:return null===e.newVersion?[4,i()]:[3,2];case 1:t.sent(),t.label=2;case 2:return[2]}})})})},Wu.prototype.setNetworkEnabled=function(t){var e=this;this.networkEnabled!==t&&(this.networkEnabled=t,this.Se.enqueueAndForget(function(){return g(e,void 0,void 0,function(){return m(this,function(t){switch(t.label){case 0:return this.started?[4,this.je()]:[3,2];case 1:t.sent(),t.label=2;case 2:return[2]}})})}))},Wu.prototype.je=function(){var i=this;return this.runTransaction("updateClientMetadataAndTryBecomePrimary","readwrite",function(e){return Gu(e).put(new Za(i.clientId,Date.now(),i.networkEnabled,i.inForeground)).next(function(){if(i.isPrimary)return i.Je(e).next(function(t){t||(i.isPrimary=!1,i.Se.enqueueRetryable(function(){return i.Me(!1)}))})}).next(function(){return i.Ye(e)}).next(function(t){return i.isPrimary&&!t?i.Xe(e).next(function(){return!1}):!!t&&i.Ze(e).next(function(){return!0})})}).catch(function(t){if(vl(t))return Bn("IndexedDbPersistence","Failed to extend owner lease: ",t),i.isPrimary;if(!i.allowTabSynchronization)throw t;return Bn("IndexedDbPersistence","Releasing owner lease after error during lease refresh",t),!1}).then(function(t){i.isPrimary!==t&&i.Se.enqueueRetryable(function(){return i.Me(t)}),i.isPrimary=t})},Wu.prototype.Je=function(t){var e=this;return Ku(t).get(Ba.key).next(function(t){return ol.resolve(e.tn(t))})},Wu.prototype.en=function(t){return Gu(t).delete(this.clientId)},Wu.prototype.nn=function(){return g(this,void 0,void 0,function(){var e,i,n,r,s=this;return m(this,function(t){switch(t.label){case 0:return!this.isPrimary||this.sn(this.Oe,18e5)?[3,2]:(this.Oe=Date.now(),[4,this.runTransaction("maybeGarbageCollectMultiClientState","readwrite-primary",function(t){var n=El(t,Za.store);return n.Nt().next(function(t){var e=s.rn(t,18e5),i=t.filter(function(t){return-1===e.indexOf(t)});return ol.forEach(i,function(t){return n.delete(t.clientId)}).next(function(){return i})})}).catch(function(){return[]})]);case 1:if(e=t.sent(),this.Qe)for(i=0,n=e;i<n.length;i++)r=n[i],this.Qe.removeItem(this.on(r.clientId));t.label=2;case 2:return[2]}})})},Wu.prototype.ze=function(){var t=this;this.$e=this.Se.enqueueAfterDelay("client_metadata_refresh",4e3,function(){return t.je().then(function(){return t.nn()}).then(function(){return t.ze()})})},Wu.prototype.tn=function(t){return!!t&&t.ownerId===this.clientId},Wu.prototype.Ye=function(e){var n=this;return this.Ce?ol.resolve(!0):Ku(e).get(Ba.key).next(function(t){if(null!==t&&n.sn(t.leaseTimestampMs,5e3)&&!n.cn(t.ownerId)){if(n.tn(t)&&n.networkEnabled)return!0;
1if(!n.tn(t)){if(!t.allowTabSynchronization)throw new Ln(On.FAILED_PRECONDITION,Vu);return!1}}return!(!n.networkEnabled||!n.inForeground)||Gu(e).Nt().next(function(t){return void 0===n.rn(t,5e3).find(function(t){if(n.clientId!==t.clientId){var e=!n.networkEnabled&&t.networkEnabled,i=!n.inForeground&&t.inForeground;t=n.networkEnabled===t.networkEnabled;if(e||i&&t)return!0}return!1})})}).next(function(t){return n.isPrimary!==t&&Bn("IndexedDbPersistence","Client "+(t?"is":"is not")+" eligible for a primary lease."),t})},Wu.prototype.shutdown=function(){return g(this,void 0,void 0,function(){var i=this;return m(this,function(t){switch(t.label){case 0:return this.xe=!1,this.un(),this.$e&&(this.$e.cancel(),this.$e=null),this.an(),this.hn(),[4,this.Be.runTransaction("shutdown","readwrite",[Ba.store,Za.store],function(t){var e=new Sl(t,Pn.o);return i.Xe(e).next(function(){return i.en(e)})})];case 1:return t.sent(),this.Be.close(),this.ln(),[2]}})})},Wu.prototype.rn=function(t,e){var i=this;return t.filter(function(t){return i.sn(t.updateTimeMs,e)&&!i.cn(t.clientId)})},Wu.prototype.fn=function(){var e=this;return this.runTransaction("getActiveClients","readonly",function(t){return Gu(t).Nt().next(function(t){return e.rn(t,18e5).map(function(t){return t.clientId})})})},Object.defineProperty(Wu.prototype,"started",{get:function(){return this.xe},enumerable:!1,configurable:!0}),Wu.prototype.getMutationQueue=function(t){return ou.Qt(t,this.R,this.Ut,this.referenceDelegate)},Wu.prototype.getTargetCache=function(){return this.qe},Wu.prototype.getRemoteDocumentCache=function(){return this.Ue},Wu.prototype.getIndexManager=function(){return this.Ut},Wu.prototype.getBundleCache=function(){return this.Ke},Wu.prototype.runTransaction=function(e,i,n){var r,s=this;return Bn("IndexedDbPersistence","Starting transaction:",e),this.Be.runTransaction(e,"readonly"===i?"readonly":"readwrite",nl,function(t){return r=new Sl(t,s.Ne?s.Ne.next():Pn.o),"readwrite-primary"===i?s.Je(r).next(function(t){return!!t||s.Ye(r)}).next(function(t){if(!t)throw $n("Failed to obtain primary lease for action '"+e+"'."),s.isPrimary=!1,s.Se.enqueueRetryable(function(){return s.Me(!1)}),new Ln(On.FAILED_PRECONDITION,rl);return n(r)}).next(function(t){return s.Ze(r).next(function(){return t})}):s.dn(r).next(function(){return n(r)})}).then(function(t){return r.raiseOnCommittedEvent(),t})},Wu.prototype.dn=function(t){var e=this;return Ku(t).get(Ba.key).next(function(t){if(null!==t&&e.sn(t.leaseTimestampMs,5e3)&&!e.cn(t.ownerId)&&!e.tn(t)&&!(e.Ce||e.allowTabSynchronization&&t.allowTabSynchronization))throw new Ln(On.FAILED_PRECONDITION,Vu)})},Wu.prototype.Ze=function(t){var e=new Ba(this.clientId,this.allowTabSynchronization,Date.now());return Ku(t).put(Ba.key,e)},Wu.yt=function(){return ll.yt()},Wu.prototype.Xe=function(t){var e=this,i=Ku(t);return i.get(Ba.key).next(function(t){return e.tn(t)?(Bn("IndexedDbPersistence","Releasing primary lease."),i.delete(Ba.key)):ol.resolve()})},Wu.prototype.sn=function(t,e){var i=Date.now();return!(t<i-e||i<t&&($n("Detected an update time that is in the future: "+t+" > "+i),1))},Wu.prototype.We=function(){var t=this;null!==this.document&&"function"==typeof this.document.addEventListener&&(this.Fe=function(){t.Se.enqueueAndForget(function(){return t.inForeground="visible"===t.document.visibilityState,t.je()})},this.document.addEventListener("visibilitychange",this.Fe),this.inForeground="visible"===this.document.visibilityState)},Wu.prototype.an=function(){this.Fe&&(this.document.removeEventListener("visibilitychange",this.Fe),this.Fe=null)},Wu.prototype.Ge=function(){var t,e=this;"function"==typeof(null===(t=this.window)||void 0===t?void 0:t.addEventListener)&&(this.ke=function(){e.un(),!function(){try{return"[object process]"===Object.prototype.toString.call(global.process)}catch(t){return}}()&&navigator.userAgent.includes("Safari")&&!navigator.userAgent.includes("Chrome")&&navigator.appVersion.match("Version/14")&&e.Se.enterRestrictedMode(!0),e.Se.enqueueAndForget(function(){return e.shutdown()})},this.window.addEventListener("pagehide",this.ke))},Wu.prototype.hn=function(){this.ke&&(this.window.removeEventListener("pagehide",this.ke),this.ke=null)},Wu.prototype.cn=function(t){var e;try{var i=null!==(null===(e=this.Qe)||void 0===e?void 0:e.getItem(this.on(t)));return Bn("IndexedDbPersistence","Client '"+t+"' "+(i?"is":"is not")+" zombied in LocalStorage"),i}catch(t){return $n("IndexedDbPersistence","Failed to get zombied client id.",t),!1}},Wu.prototype.un=function(){if(this.Qe)try{this.Qe.setItem(this.on(this.clientId),String(Date.now()))}catch(t){$n("Failed to set zombie client id.",t)}},Wu.prototype.ln=function(){if(this.Qe)try{this.Qe.removeItem(this.on(this.clientId))}catch(t){}},Wu.prototype.on=function(t){return"firestore_zombie_"+this.persistenceKey+"_"+t},Wu);function Wu(t,e,i,n,r,s,o,a,l,u){if(this.allowTabSynchronization=t,this.persistenceKey=e,this.clientId=i,this.Se=r,this.window=s,this.document=o,this.De=l,this.Ce=u,this.Ne=null,this.xe=!1,this.isPrimary=!1,this.networkEnabled=!0,this.ke=null,this.inForeground=!1,this.Fe=null,this.$e=null,this.Oe=Number.NEGATIVE_INFINITY,this.Me=function(t){return Promise.resolve()}
1,!Wu.yt())throw new Ln(On.UNIMPLEMENTED,"This platform is either missing IndexedDB or is known to have an incomplete implementation. Offline persistence has been disabled.");this.referenceDelegate=new Su(this,n),this.Le=e+"main",this.R=new Al(a),this.Be=new ll(this.Le,11,new ju(this.R)),this.qe=new pu(this.referenceDelegate,this.R),this.Ut=new Xl,this.Ue=(e=this.R,a=this.Ut,new Mu(e,a)),this.Ke=new Vl,this.window&&this.window.localStorage?this.Qe=this.window.localStorage:(this.Qe=null,!1===u&&$n("IndexedDbPersistence","LocalStorage is unavailable. As a result, persistence may not work reliably. In particular enablePersistence() could fail immediately after refreshing the page."))}function Ku(t){return El(t,Ba.store)}function Gu(t){return El(t,Za.store)}function Yu(t,e){var i=t.projectId;return t.isDefaultDatabase||(i+="."+t.database),"firestore/"+e+"/"+i+"/"}function Xu(t,e){this.progress=t,this.wn=e}var Qu=(rc.prototype.mn=function(e,i){var n=this;return this._n.getAllMutationBatchesAffectingDocumentKey(e,i).next(function(t){return n.yn(e,i,t)})},rc.prototype.yn=function(t,e,n){return this.Ue.getEntry(t,e).next(function(t){for(var e=0,i=n;e<i.length;e++)i[e].applyToLocalView(t);return t})},rc.prototype.gn=function(t,r){t.forEach(function(t,e){for(var i=0,n=r;i<n.length;i++)n[i].applyToLocalView(e)})},rc.prototype.pn=function(e,t){var i=this;return this.Ue.getEntries(e,t).next(function(t){return i.En(e,t).next(function(){return t})})},rc.prototype.En=function(t,e){var i=this;return this._n.getAllMutationBatchesAffectingDocumentKeys(t,e).next(function(t){return i.gn(e,t)})},rc.prototype.getDocumentsMatchingQuery=function(t,e,i){return n=e,Sr.isDocumentKey(n.path)&&null===n.collectionGroup&&0===n.filters.length?this.Tn(t,e.path):Ps(e)?this.In(t,e,i):this.An(t,e,i);var n},rc.prototype.Tn=function(t,e){return this.mn(t,new Sr(e)).next(function(t){var e=Wo;return t.isFoundDocument()?e.insert(t.key,t):e})},rc.prototype.In=function(i,n,r){var s=this,o=n.collectionGroup,a=Wo;return this.Ut.getCollectionParents(i,o).next(function(t){return ol.forEach(t,function(t){var e=(e=n,t=t.child(o),new Ss(t,null,e.explicitOrderBy.slice(),e.filters.slice(),e.limit,e.limitType,e.startAt,e.endAt));return s.An(i,e,r).next(function(t){t.forEach(function(t,e){a=a.insert(t,e)})})}).next(function(){return a})})},rc.prototype.An=function(e,i,t){var u,c,n=this;return this.Ue.getDocumentsMatchingQuery(e,i,t).next(function(t){return u=t,n._n.getAllMutationBatchesAffectingQuery(e,i)}).next(function(t){return c=t,n.Rn(e,c,u).next(function(t){u=t;for(var e=0,i=c;e<i.length;e++)for(var n=i[e],r=0,s=n.mutations;r<s.length;r++){var o=s[r],a=o.key,l=u.get(a);null==l&&(l=jr.newInvalidDocument(a),u=u.insert(a,l)),ho(o,l,n.localWriteTime),l.isFoundDocument()||(u=u.remove(a))}})}).next(function(){return u.forEach(function(t,e){zs(i,e)||(u=u.remove(t))}),u})},rc.prototype.Rn=function(t,e,i){for(var n=Yo(),r=0,s=e;r<s.length;r++)for(var o=0,a=s[r].mutations;o<a.length;o++){var l=a[o];l instanceof yo&&null===i.get(l.key)&&(n=n.add(l.key))}var u=i;return this.Ue.getEntries(t,n).next(function(t){return t.forEach(function(t,e){e.isFoundDocument()&&(u=u.insert(t,e))}),u})},rc),Ju=(nc.Pn=function(t,e){for(var i=Yo(),n=Yo(),r=0,s=e.docChanges;r<s.length;r++){var o=s[r];switch(o.type){case 0:i=i.add(o.doc.key);break;case 1:n=n.add(o.doc.key)}}return new nc(t,e.fromCache,i,n)},nc),Zu=(ic.prototype.Vn=function(t){this.Sn=t},ic.prototype.getDocumentsMatchingQuery=function(e,n,r,s){var o=this;return 0===n.filters.length&&null===n.limit&&null==n.startAt&&null==n.endAt&&(0===n.explicitOrderBy.length||1===n.explicitOrderBy.length&&n.explicitOrderBy[0].field.isKeyField())||r.isEqual(Qn.min())?this.Dn(e,n):this.Sn.pn(e,s).next(function(t){var i=o.Cn(n,t);return(ks(n)||Is(n))&&o.Nn(n.limitType,i,s,r)?o.Dn(e,n):(zn()<=y.DEBUG&&Bn("QueryEngine","Re-using previous result from %s to execute query: %s",r.toString(),Fs(n)),o.Sn.getDocumentsMatchingQuery(e,n,r).next(function(e){return i.forEach(function(t){e=e.insert(t.key,t)}),e}))})},ic.prototype.Cn=function(i,t){var n=new jo(Bs(i));return t.forEach(function(t,e){zs(i,e)&&(n=n.add(e))}),n}
1,ic.prototype.Nn=function(t,e,i,n){return i.size!==e.size||!!(e="F"===t?e.last():e.first())&&(e.hasPendingWrites||0<e.version.compareTo(n))},ic.prototype.Dn=function(t,e){return zn()<=y.DEBUG&&Bn("QueryEngine","Using full collection scan to execute query:",Fs(e)),this.Sn.getDocumentsMatchingQuery(t,e,Qn.min())},ic),tc=(ec.prototype.collectGarbage=function(e){var i=this;return this.persistence.runTransaction("Collect garbage","readwrite-primary",function(t){return e.collect(t,i.kn)})},ec);function ec(t,e,i,n){this.persistence=t,this.xn=e,this.R=n,this.kn=new Oo(Kn),this.Fn=new Pu(Ur,Wr),this.$n=Qn.min(),this._n=t.getMutationQueue(i),this.On=t.getRemoteDocumentCache(),this.qe=t.getTargetCache(),this.Mn=new Qu(this.On,this._n,this.persistence.getIndexManager()),this.Ke=t.getBundleCache(),this.xn.Vn(this.Mn)}function ic(){}function nc(t,e,i,n){this.targetId=t,this.fromCache=e,this.bn=i,this.vn=n}function rc(t,e,i){this.Ue=t,this._n=e,this.Ut=i}function sc(t,e,i,n){return new tc(t,e,i,n)}function oc(r,s){return g(this,void 0,void 0,function(){var e,i,y,n;return m(this,function(t){switch(t.label){case 0:return i=(e=r)._n,y=e.Mn,[4,e.persistence.runTransaction("Handle user change","readonly",function(m){var v;return e._n.getAllMutationBatches(m).next(function(t){return v=t,i=e.persistence.getMutationQueue(s),y=new Qu(e.On,i,e.persistence.getIndexManager()),i.getAllMutationBatches(m)}).next(function(t){for(var e=[],i=[],n=Yo(),r=0,s=v;r<s.length;r++){var o=s[r];e.push(o.batchId);for(var a=0,l=o.mutations;a<l.length;a++){var u=l[a];n=n.add(u.key)}}for(var c=0,h=t;c<h.length;c++){var d=h[c];i.push(d.batchId);for(var p=0,f=d.mutations;p<f.length;p++){var g=f[p];n=n.add(g.key)}}return y.pn(m,n).next(function(t){return{Ln:t,removedBatchIds:e,addedBatchIds:i}})})})];case 1:return n=t.sent(),[2,(e._n=i,e.Mn=y,e.xn.Vn(e.Mn),n)]}})})}function ac(t){var e=t;return e.persistence.runTransaction("Get last remote snapshot version","readonly",function(t){return e.qe.getLastRemoteSnapshotVersion(t)})}function lc(t,o,e,a,l){var i=Yo();return e.forEach(function(t){return i=i.add(t)}),o.getEntries(t,i).next(function(r){var s=qo;return e.forEach(function(t,e){var i=r.get(t),n=(null==l?void 0:l.get(t))||a;e.isNoDocument()&&e.version.isEqual(Qn.min())?(o.removeEntry(t,n),s=s.insert(t,e)):!i.isValidDocument()||0<e.version.compareTo(i.version)||0===e.version.compareTo(i.version)&&i.hasPendingWrites?(o.addEntry(e,n),s=s.insert(t,e)):Bn("LocalStore","Ignoring outdated watch update for ",t,". Current version:",i.version," Watch version:",e.version)}),s})}function uc(t,n){var r=t;return r.persistence.runTransaction("Allocate target","readwrite",function(e){var i;return r.qe.getTargetData(e,n).next(function(t){return t?(i=t,ol.resolve(i)):r.qe.allocateTargetId(e).next(function(t){return i=new Dl(n,t,0,e.currentSequenceNumber),r.qe.addTargetData(e,i).next(function(){return i})})})}).then(function(t){var e=r.kn.get(t.targetId);return(null===e||0<t.snapshotVersion.compareTo(e.snapshotVersion))&&(r.kn=r.kn.insert(t.targetId,t),r.Fn.set(n,t.targetId)),t})}function cc(r,s,o){return g(this,void 0,void 0,function(){var e,i,n;return m(this,function(t){switch(t.label){case 0:i=(e=r).kn.get(s),n=o?"readwrite":"readwrite-primary",t.label=1;case 1:return t.trys.push([1,4,,5]),o?[3,3]:[4,e.persistence.runTransaction("Release target",n,function(t){return e.persistence.referenceDelegate.removeTarget(t,i)})];case 2:t.sent(),t.label=3;case 3:return[3,5];case 4:if(!vl(n=t.sent()))throw n;return Bn("LocalStore","Failed to update sequence numbers for target "+s+": "+n),[3,5];case 5:return e.kn=e.kn.remove(s),e.Fn.delete(i.target),[2]}})})}function hc(t,s,o){var a=t,l=Qn.min(),u=Yo();return a.persistence.runTransaction("Execute query","readonly",function(e){return t=a,i=e,n=Ns(s),(void 0!==(t=(r=t).Fn.get(n))?ol.resolve(r.kn.get(t)):r.qe.getTargetData(i,n)).next(function(t){if(t)return l=t.lastLimboFreeSnapshotVersion,a.qe.getMatchingKeysForTargetId(e,t.targetId).next(function(t){u=t})}).next(function(){return a.xn.getDocumentsMatchingQuery(e,s,o?l:Qn.min(),o?u:Yo())}).next(function(t){return{documents:t,Bn:u}});var t,i,n,r})}function dc(t,e){var i=t,n=i.qe;return(t=i.kn.get(e))?Promise.resolve(t.target):i.persistence.runTransaction("Get target data","readonly",function(t){return n.lt(t,e).next(function(t){return t?t.target:null})})}function pc(t){var o=t;return o.persistence.runTransaction("Get new document changes","readonly",function(t){return e=o.On,i=t,t=o.$n,n=e,r=qo,s=Rl(t),t=Bu(i),i=IDBKeyRange.lowerBound(s,!0),t.$t({index:Ka.readTimeIndex,range:i},function(t,e){var i=Ol(n.R,e);r=r.insert(i.key,i),s=e.readTime}).next(function(){return{wn:r,readTime:Fl(s)}});var e,i,n,r,s}).then(function(t){var e=t.wn;t=t.readTime;return o.$n=t,e})}var fc,gc,mc=(Fc.prototype.getBundleMetadata=function(t,e){return ol.resolve(this.Qn.get(e))},Fc.prototype.saveBundleMetadata=function(t,e){return this.Qn.set(e.id,{id:e.id,version:e.version,createTime:ga(e.createTime)}),ol.resolve()}
1,Fc.prototype.getNamedQuery=function(t,e){return ol.resolve(this.jn.get(e))},Fc.prototype.saveNamedQuery=function(t,e){return this.jn.set(e.name,{name:(e=e).name,query:ql(e.bundledQuery),readTime:ga(e.readTime)}),ol.resolve()},Fc),vc=(Rc.prototype.isEmpty=function(){return this.Wn.isEmpty()},Rc.prototype.addReference=function(t,e){e=new yc(t,e),this.Wn=this.Wn.add(e),this.zn=this.zn.add(e)},Rc.prototype.Jn=function(t,e){var i=this;t.forEach(function(t){return i.addReference(t,e)})},Rc.prototype.removeReference=function(t,e){this.Yn(new yc(t,e))},Rc.prototype.Xn=function(t,e){var i=this;t.forEach(function(t){return i.removeReference(t,e)})},Rc.prototype.Zn=function(t){var e=this,i=new Sr(new sr([])),n=new yc(i,t),r=(t=new yc(i,t+1),[]);return this.zn.forEachInRange([n,t],function(t){e.Yn(t),r.push(t.key)}),r},Rc.prototype.ts=function(){var e=this;this.Wn.forEach(function(t){return e.Yn(t)})},Rc.prototype.Yn=function(t){this.Wn=this.Wn.delete(t),this.zn=this.zn.delete(t)},Rc.prototype.es=function(t){var e=new Sr(new sr([])),i=new yc(e,t),n=(t=new yc(e,t+1),Yo());return this.zn.forEachInRange([i,t],function(t){n=n.add(t.key)}),n},Rc.prototype.containsKey=function(t){var e=new yc(t,0);return null!==(e=this.Wn.firstAfterOrEqual(e))&&t.isEqual(e.key)},Rc),yc=(Lc.Gn=function(t,e){return Sr.comparator(t.key,e.key)||Kn(t.ns,e.ns)},Lc.Hn=function(t,e){return Kn(t.ns,e.ns)||Sr.comparator(t.key,e.key)},Lc),bc=(Oc.prototype.checkEmpty=function(t){return ol.resolve(0===this._n.length)},Oc.prototype.addMutationBatch=function(t,e,i,n){var r=this.ss;this.ss++,0<this._n.length&&this._n[this._n.length-1],i=new kl(r,e,i,n),this._n.push(i);for(var s=0,o=n;s<o.length;s++){var a=o[s];this.rs=this.rs.add(new yc(a.key,r)),this.Ut.addToCollectionParentIndex(t,a.key.path.popLast())}return ol.resolve(i)},Oc.prototype.lookupMutationBatch=function(t,e){return ol.resolve(this.os(e))},Oc.prototype.getNextMutationBatchAfterBatchId=function(t,e){return e=(e=this.cs(e+1))<0?0:e,ol.resolve(this._n.length>e?this._n[e]:null)},Oc.prototype.getHighestUnacknowledgedBatchId=function(){return ol.resolve(0===this._n.length?-1:this.ss-1)},Oc.prototype.getAllMutationBatches=function(t){return ol.resolve(this._n.slice())},Oc.prototype.getAllMutationBatchesAffectingDocumentKey=function(t,e){var i=this,n=new yc(e,0),r=(e=new yc(e,Number.POSITIVE_INFINITY),[]);return this.rs.forEachInRange([n,e],function(t){t=i.os(t.ns),r.push(t)}),ol.resolve(r)},Oc.prototype.getAllMutationBatchesAffectingDocumentKeys=function(t,e){var i=this,n=new jo(Kn);return e.forEach(function(t){var e=new yc(t,0);t=new yc(t,Number.POSITIVE_INFINITY);i.rs.forEachInRange([e,t],function(t){n=n.add(t.ns)})}),ol.resolve(this.us(n))},Oc.prototype.getAllMutationBatchesAffectingQuery=function(t,e){var i=e.path,n=i.length+1;e=i;Sr.isDocumentKey(e)||(e=e.child(""));e=new yc(new Sr(e),0);var r=new jo(Kn);return this.rs.forEachWhile(function(t){var e=t.key.path;return!!i.isPrefixOf(e)&&(e.length===n&&(r=r.add(t.ns)),!0)},e),ol.resolve(this.us(r))},Oc.prototype.us=function(t){var e=this,i=[];return t.forEach(function(t){null!==(t=e.os(t))&&i.push(t)}),i},Oc.prototype.removeMutationBatch=function(i,n){var r=this;Vn(0===this.hs(n.batchId,"removed")),this._n.shift();var s=this.rs;return ol.forEach(n.mutations,function(t){var e=new yc(t.key,n.batchId);return s=s.delete(e),r.referenceDelegate.markPotentiallyOrphaned(i,t.key)}).next(function(){r.rs=s})},Oc.prototype.Gt=function(t){},Oc.prototype.containsKey=function(t,e){var i=new yc(e,0);i=this.rs.firstAfterOrEqual(i);return ol.resolve(e.isEqual(i&&i.key))},Oc.prototype.performConsistencyCheck=function(t){return this._n.length,ol.resolve()},Oc.prototype.hs=function(t,e){return this.cs(t)},Oc.prototype.cs=function(t){return 0===this._n.length?0:t-this._n[0].batchId},Oc.prototype.os=function(t){return(t=this.cs(t))<0||t>=this._n.length?null:this._n[t]},Oc),wc=(Nc.prototype.addEntry=function(t,e,i){var n=e.key,r=(s=this.docs.get(n))?s.size:0,s=this.ls(e);return this.docs=this.docs.insert(n,{document:e.clone(),size:s,readTime:i}),this.size+=s-r,this.Ut.addToCollectionParentIndex(t,n.path.popLast())},Nc.prototype.removeEntry=function(t){var e=this.docs.get(t);e&&(this.docs=this.docs.remove(t),this.size-=e.size)},Nc.prototype.getEntry=function(t,e){var i=this.docs.get(e);return ol.resolve(i?i.document.clone():jr.newInvalidDocument(e))},Nc.prototype.getEntries=function(t,e){var i=this,n=qo;return e.forEach(function(t){var e=i.docs.get(t);n=n.insert(t,e?e.document.clone():jr.newInvalidDocument(t))}),ol.resolve(n)}
1,Nc.prototype.getDocumentsMatchingQuery=function(t,e,i){for(var n=qo,r=new Sr(e.path.child("")),s=this.docs.getIteratorFrom(r);s.hasNext();){var o=(a=s.getNext()).key,a=(l=a.value).document,l=l.readTime;if(!e.path.isPrefixOf(o.path))break;l.compareTo(i)<=0||zs(e,a)&&(n=n.insert(a.key,a.clone()))}return ol.resolve(n)},Nc.prototype.fs=function(t,e){return ol.forEach(this.docs,function(t){return e(t)})},Nc.prototype.newChangeBuffer=function(t){return new _c(this)},Nc.prototype.getSize=function(t){return ol.resolve(this.size)},Nc),_c=(i(Mc,gc=C),Mc.prototype.applyChanges=function(i){var n=this,r=[];return this.changes.forEach(function(t,e){e.document.isValidDocument()?r.push(n.Ie.addEntry(i,e.document,n.getReadTime(t))):n.Ie.removeEntry(t)}),ol.waitFor(r)},Mc.prototype.getFromCache=function(t,e){return this.Ie.getEntry(t,e)},Mc.prototype.getAllFromCache=function(t,e){return this.Ie.getEntries(t,e)},Mc),xc=(Pc.prototype.forEachTarget=function(t,i){return this.ds.forEach(function(t,e){return i(e)}),ol.resolve()},Pc.prototype.getLastRemoteSnapshotVersion=function(t){return ol.resolve(this.lastRemoteSnapshotVersion)},Pc.prototype.getHighestSequenceNumber=function(t){return ol.resolve(this.ws)},Pc.prototype.allocateTargetId=function(t){return this.highestTargetId=this.ys.next(),ol.resolve(this.highestTargetId)},Pc.prototype.setTargetsMetadata=function(t,e,i){return i&&(this.lastRemoteSnapshotVersion=i),e>this.ws&&(this.ws=e),ol.resolve()},Pc.prototype.te=function(t){this.ds.set(t.target,t);var e=t.targetId;e>this.highestTargetId&&(this.ys=new du(e),this.highestTargetId=e),t.sequenceNumber>this.ws&&(this.ws=t.sequenceNumber)},Pc.prototype.addTargetData=function(t,e){return this.te(e),this.targetCount+=1,ol.resolve()},Pc.prototype.updateTargetData=function(t,e){return this.te(e),ol.resolve()},Pc.prototype.removeTargetData=function(t,e){return this.ds.delete(e.target),this._s.Zn(e.targetId),--this.targetCount,ol.resolve()},Pc.prototype.removeTargets=function(i,n,r){var s=this,o=0,a=[];return this.ds.forEach(function(t,e){e.sequenceNumber<=n&&null===r.get(e.targetId)&&(s.ds.delete(t),a.push(s.removeMatchingKeysForTargetId(i,e.targetId)),o++)}),ol.waitFor(a).next(function(){return o})},Pc.prototype.getTargetCount=function(t){return ol.resolve(this.targetCount)},Pc.prototype.getTargetData=function(t,e){return e=this.ds.get(e)||null,ol.resolve(e)},Pc.prototype.addMatchingKeys=function(t,e,i){return this._s.Jn(e,i),ol.resolve()},Pc.prototype.removeMatchingKeys=function(e,t,i){this._s.Xn(t,i);var n=this.persistence.referenceDelegate,r=[];return n&&t.forEach(function(t){r.push(n.markPotentiallyOrphaned(e,t))}),ol.waitFor(r)},Pc.prototype.removeMatchingKeysForTargetId=function(t,e){return this._s.Zn(e),ol.resolve()},Pc.prototype.getMatchingKeysForTargetId=function(t,e){return e=this._s.es(e),ol.resolve(e)},Pc.prototype.containsKey=function(t,e){return ol.resolve(this._s.containsKey(e))},Pc),Tc=(Ac.prototype.start=function(){return Promise.resolve()},Ac.prototype.shutdown=function(){return this.xe=!1,Promise.resolve()},Object.defineProperty(Ac.prototype,"started",{get:function(){return this.xe},enumerable:!1,configurable:!0}),Ac.prototype.setDatabaseDeletedListener=function(){},Ac.prototype.setNetworkEnabled=function(){},Ac.prototype.getIndexManager=function(){return this.Ut},Ac.prototype.getMutationQueue=function(t){var e=this.gs[t.toKey()];return e||(e=new bc(this.Ut,this.referenceDelegate),this.gs[t.toKey()]=e),e},Ac.prototype.getTargetCache=function(){return this.qe},Ac.prototype.getRemoteDocumentCache=function(){return this.Ue},Ac.prototype.getBundleCache=function(){return this.Ke},Ac.prototype.runTransaction=function(t,e,i){var n=this;Bn("MemoryPersistence","Starting transaction:",t);var r=new Sc(this.Ne.next());return this.referenceDelegate.Es(),i(r).next(function(t){return n.referenceDelegate.Ts(r).next(function(){return t})}).toPromise().then(function(t){return r.raiseOnCommittedEvent(),t})},Ac.prototype.Is=function(e,i){return ol.or(Object.values(this.gs).map(function(t){return function(){return t.containsKey(e,i)}}))},Ac),Sc=(i(Dc,fc=A),Dc),Cc=(Ic.bs=function(t){return new Ic(t)},Object.defineProperty(Ic.prototype,"vs",{get:function(){if(this.Rs)return this.Rs;throw qn()}
1,enumerable:!1,configurable:!0}),Ic.prototype.addReference=function(t,e,i){return this.As.addReference(i,e),this.vs.delete(i.toString()),ol.resolve()},Ic.prototype.removeReference=function(t,e,i){return this.As.removeReference(i,e),this.vs.add(i.toString()),ol.resolve()},Ic.prototype.markPotentiallyOrphaned=function(t,e){return this.vs.add(e.toString()),ol.resolve()},Ic.prototype.removeTarget=function(t,e){var i=this;this.As.Zn(e.targetId).forEach(function(t){return i.vs.add(t.toString())});var n=this.persistence.getTargetCache();return n.getMatchingKeysForTargetId(t,e.targetId).next(function(t){t.forEach(function(t){return i.vs.add(t.toString())})}).next(function(){return n.removeTargetData(t,e)})},Ic.prototype.Es=function(){this.Rs=new Set},Ic.prototype.Ts=function(i){var n=this,r=this.persistence.getRemoteDocumentCache().newChangeBuffer();return ol.forEach(this.vs,function(t){var e=Sr.fromPath(t);return n.Ps(i,e).next(function(t){t||r.removeEntry(e)})}).next(function(){return n.Rs=null,r.apply(i)})},Ic.prototype.updateLimboDocument=function(t,e){var i=this;return this.Ps(t,e).next(function(t){t?i.vs.delete(e.toString()):i.vs.add(e.toString())})},Ic.prototype.ps=function(t){return 0},Ic.prototype.Ps=function(t,e){var i=this;return ol.or([function(){return ol.resolve(i.As.containsKey(e))},function(){return i.persistence.getTargetCache().containsKey(t,e)},function(){return i.persistence.Is(t,e)}])},Ic),Ec=(kc.prototype.isAuthenticated=function(){return null!=this.uid},kc.prototype.toKey=function(){return this.isAuthenticated()?"uid:"+this.uid:"anonymous-user"},kc.prototype.isEqual=function(t){return t.uid===this.uid},kc);function kc(t){this.uid=t}function Ic(t){this.persistence=t,this.As=new vc,this.Rs=null}function Dc(t){var e=this;return(e=fc.call(this)||this).currentSequenceNumber=t,e}function Ac(t,e){var i=this;this.gs={},this.Ne=new Pn(0),this.xe=!1,this.xe=!0,this.referenceDelegate=t(this),this.qe=new xc(this),this.Ut=new Gl,this.Ue=(t=this.Ut,new wc(t,function(t){return i.referenceDelegate.ps(t)})),this.R=new Al(e),this.Ke=new mc(this.R)}function Pc(t){this.persistence=t,this.ds=new Pu(Ur,Wr),this.lastRemoteSnapshotVersion=Qn.min(),this.highestTargetId=0,this.ws=0,this._s=new vc,this.targetCount=0,this.ys=du.Jt()}function Mc(t){var e=this;return(e=gc.call(this)||this).Ie=t,e}function Nc(t,e){this.Ut=t,this.ls=e,this.docs=new Oo(Sr.comparator),this.size=0}function Oc(t,e){this.Ut=t,this.referenceDelegate=e,this._n=[],this.ss=1,this.rs=new jo(yc.Gn)}function Lc(t,e){this.key=t,this.ns=e}function Rc(){this.Wn=new jo(yc.Gn),this.zn=new jo(yc.Hn)}function Fc(t){this.R=t,this.Qn=new Map,this.jn=new Map}function zc(t,e){return"firestore_clients_"+t+"_"+e}function Bc(t,e,i){return i="firestore_mutations_"+t+"_"+i,e.isAuthenticated()&&(i+="_"+e.uid),i}function $c(t,e){return"firestore_targets_"+t+"_"+e}Ec.UNAUTHENTICATED=new Ec(null),Ec.GOOGLE_CREDENTIALS=new Ec("google-credentials-uid"),Ec.FIRST_PARTY=new Ec("first-party-uid"),Ec.MOCK_USER=new Ec("mock-user");var jc,Hc=(hh.Vs=function(t,e,i){var n,r=JSON.parse(i),s="object"==typeof r&&-1!==["pending","acknowledged","rejected"].indexOf(r.state)&&(void 0===r.error||"object"==typeof r.error);return s&&r.error&&(s="string"==typeof r.error.message&&"string"==typeof r.error.code)&&(n=new Ln(r.error.code,r.error.message)),s?new hh(t,e,r.state,n):($n("SharedClientState","Failed to parse mutation state for ID '"+e+"': "+i),null)},hh.prototype.Ss=function(){var t={state:this.state,updateTimeMs:Date.now()};return this.error&&(t.error={code:this.error.code,message:this.error.message}),JSON.stringify(t)},hh),qc=(ch.Vs=function(t,e){var i,n=JSON.parse(e),r="object"==typeof n&&-1!==["not-current","current","rejected"].indexOf(n.state)&&(void 0===n.error||"object"==typeof n.error);return r&&n.error&&(r="string"==typeof n.error.message&&"string"==typeof n.error.code)&&(i=new Ln(n.error.code,n.error.message)),r?new ch(t,n.state,i):($n("SharedClientState","Failed to parse target state for ID '"+t+"': "+e),null)},ch.prototype.Ss=function(){var t={state:this.state,updateTimeMs:Date.now()};return this.error&&(t.error={code:this.error.code,message:this.error.message}),JSON.stringify(t)},ch),Vc=(uh.Vs=function(t,e){for(var i=JSON.parse(e),n="object"==typeof i&&i.activeTargetIds instanceof Array,r=Xo,s=0;n&&s<i.activeTargetIds.length;++s)n=Tr(i.activeTargetIds[s]),r=r.add(i.activeTargetIds[s]);
1return n?new uh(t,r):($n("SharedClientState","Failed to parse client data for instance '"+t+"': "+e),null)},uh),Uc=(lh.Vs=function(t){var e=JSON.parse(t);return"object"==typeof e&&-1!==["Unknown","Online","Offline"].indexOf(e.onlineState)&&"string"==typeof e.clientId?new lh(e.clientId,e.onlineState):($n("SharedClientState","Failed to parse online state: "+t),null)},lh),Wc=(ah.prototype.Ds=function(t){this.activeTargetIds=this.activeTargetIds.add(t)},ah.prototype.Cs=function(t){this.activeTargetIds=this.activeTargetIds.delete(t)},ah.prototype.Ss=function(){var t={activeTargetIds:this.activeTargetIds.toArray(),updateTimeMs:Date.now()};return JSON.stringify(t)},ah),Kc=(oh.yt=function(t){return!(!t||!t.localStorage)},oh.prototype.start=function(){return g(this,void 0,void 0,function(){var e,i,n,r,s,o,a,l,u,c,h=this;return m(this,function(t){switch(t.label){case 0:return[4,this.syncEngine.fn()];case 1:for(o=t.sent(),e=0,i=o;e<i.length;e++)(n=i[e])!==this.Ns&&(r=this.getItem(zc(this.persistenceKey,n)))&&(s=Vc.Vs(n,r))&&(this.Fs=this.Fs.insert(s.clientId,s));for(this.Qs(),(o=this.storage.getItem(this.Us))&&(a=this.js(o))&&this.Ws(a),l=0,u=this.$s;l<u.length;l++)c=u[l],this.ks(c);return this.$s=[],this.window.addEventListener("pagehide",function(){return h.shutdown()}),this.started=!0,[2]}})})},oh.prototype.writeSequenceNumber=function(t){this.setItem(this.Ms,JSON.stringify(t))},oh.prototype.getAllActiveQueryTargets=function(){return this.Gs(this.Fs)},oh.prototype.isActiveQueryTarget=function(i){var n=!1;return this.Fs.forEach(function(t,e){e.activeTargetIds.has(i)&&(n=!0)}),n},oh.prototype.addPendingMutation=function(t){this.zs(t,"pending")},oh.prototype.updateMutationState=function(t,e,i){this.zs(t,e,i),this.Hs(t)},oh.prototype.addLocalQueryTarget=function(t){var e,i="not-current";return this.isActiveQueryTarget(t)&&(!(e=this.storage.getItem($c(this.persistenceKey,t)))||(e=qc.Vs(t,e))&&(i=e.state)),this.Js.Ds(t),this.Qs(),i},oh.prototype.removeLocalQueryTarget=function(t){this.Js.Cs(t),this.Qs()},oh.prototype.isLocalQueryTarget=function(t){return this.Js.activeTargetIds.has(t)},oh.prototype.clearQueryState=function(t){this.removeItem($c(this.persistenceKey,t))},oh.prototype.updateQueryState=function(t,e,i){this.Ys(t,e,i)},oh.prototype.handleUserChange=function(t,e,i){var n=this;e.forEach(function(t){n.Hs(t)}),this.currentUser=t,i.forEach(function(t){n.addPendingMutation(t)})},oh.prototype.setOnlineState=function(t){this.Xs(t)},oh.prototype.notifyBundleLoaded=function(){this.Zs()},oh.prototype.shutdown=function(){this.started&&(this.window.removeEventListener("storage",this.xs),this.removeItem(this.Os),this.started=!1)},oh.prototype.getItem=function(t){var e=this.storage.getItem(t);return Bn("SharedClientState","READ",t,e),e},oh.prototype.setItem=function(t,e){Bn("SharedClientState","SET",t,e),this.storage.setItem(t,e)},oh.prototype.removeItem=function(t){Bn("SharedClientState","REMOVE",t),this.storage.removeItem(t)},oh.prototype.ks=function(t){var e=this,s=t;s.storageArea===this.storage&&(Bn("SharedClientState","EVENT",s.key,s.newValue),s.key!==this.Os?this.Se.enqueueRetryable(function(){return g(e,void 0,void 0,function(){var e,i,n,r;return m(this,function(t){if(this.started){if(null!==s.key)if(this.Ls.test(s.key)){if(null==s.newValue)return e=this.ti(s.key),[2,this.ei(e,null)];if(e=this.ni(s.key,s.newValue))return[2,this.ei(e.clientId,e)]}else if(this.Bs.test(s.key)){if(null!==s.newValue&&(i=this.si(s.key,s.newValue)))return[2,this.ii(i)]}else if(this.qs.test(s.key)){if(null!==s.newValue&&(n=this.ri(s.key,s.newValue)))return[2,this.oi(n)]}else if(s.key===this.Us){if(null!==s.newValue&&(r=this.js(s.newValue)))return[2,this.Ws(r)]}else if(s.key===this.Ms)(r=function(t){var e=Pn.o;if(null!=t)try{var i=JSON.parse(t);Vn("number"==typeof i),e=i}catch(t){$n("SharedClientState","Failed to read sequence number from WebStorage",t)}return e}(s.newValue))!==Pn.o&&this.sequenceNumberHandler(r);else if(s.key===this.Ks)return[2,this.syncEngine.ci()]}else this.$s.push(s);return[2]})})}):$n("Received WebStorage notification for local change. Another client might have garbage-collected our state"))},Object.defineProperty(oh.prototype,"Js",{get:function(){return this.Fs.get(this.Ns)}
1,enumerable:!1,configurable:!0}),oh.prototype.Qs=function(){this.setItem(this.Os,this.Js.Ss())},oh.prototype.zs=function(t,e,i){i=new Hc(this.currentUser,t,e,i),t=Bc(this.persistenceKey,this.currentUser,t),this.setItem(t,i.Ss())},oh.prototype.Hs=function(t){t=Bc(this.persistenceKey,this.currentUser,t),this.removeItem(t)},oh.prototype.Xs=function(t){t={clientId:this.Ns,onlineState:t},this.storage.setItem(this.Us,JSON.stringify(t))},oh.prototype.Ys=function(t,e,i){var n=$c(this.persistenceKey,t);i=new qc(t,e,i);this.setItem(n,i.Ss())},oh.prototype.Zs=function(){this.setItem(this.Ks,"value-not-used")},oh.prototype.ti=function(t){return(t=this.Ls.exec(t))?t[1]:null},oh.prototype.ni=function(t,e){return t=this.ti(t),Vc.Vs(t,e)},oh.prototype.si=function(t,e){var i=this.Bs.exec(t);t=Number(i[1]),i=void 0!==i[2]?i[2]:null;return Hc.Vs(new Ec(i),t,e)},oh.prototype.ri=function(t,e){return t=this.qs.exec(t),t=Number(t[1]),qc.Vs(t,e)},oh.prototype.js=function(t){return Uc.Vs(t)},oh.prototype.ii=function(e){return g(this,void 0,void 0,function(){return m(this,function(t){return e.user.uid===this.currentUser.uid?[2,this.syncEngine.ui(e.batchId,e.state,e.error)]:(Bn("SharedClientState","Ignoring mutation for non-active user "+e.user.uid),[2])})})},oh.prototype.oi=function(t){return this.syncEngine.ai(t.targetId,t.state,t.error)},oh.prototype.ei=function(t,e){var i=this,n=e?this.Fs.insert(t,e):this.Fs.remove(t),r=this.Gs(this.Fs),s=this.Gs(n),o=[],a=[];return s.forEach(function(t){r.has(t)||o.push(t)}),r.forEach(function(t){s.has(t)||a.push(t)}),this.syncEngine.hi(o,a).then(function(){i.Fs=n})},oh.prototype.Ws=function(t){this.Fs.get(t.clientId)&&this.onlineStateHandler(t.onlineState)},oh.prototype.Gs=function(t){var i=Xo;return t.forEach(function(t,e){i=i.unionWith(e.activeTargetIds)}),i},oh),Gc=(sh.prototype.addPendingMutation=function(t){},sh.prototype.updateMutationState=function(t,e,i){},sh.prototype.addLocalQueryTarget=function(t){return this.li.Ds(t),this.fi[t]||"not-current"},sh.prototype.updateQueryState=function(t,e,i){this.fi[t]=e},sh.prototype.removeLocalQueryTarget=function(t){this.li.Cs(t)},sh.prototype.isLocalQueryTarget=function(t){return this.li.activeTargetIds.has(t)},sh.prototype.clearQueryState=function(t){delete this.fi[t]},sh.prototype.getAllActiveQueryTargets=function(){return this.li.activeTargetIds},sh.prototype.isActiveQueryTarget=function(t){return this.li.activeTargetIds.has(t)},sh.prototype.start=function(){return this.li=new Wc,Promise.resolve()},sh.prototype.handleUserChange=function(t,e,i){},sh.prototype.setOnlineState=function(t){},sh.prototype.shutdown=function(){},sh.prototype.writeSequenceNumber=function(t){},sh.prototype.notifyBundleLoaded=function(){},sh),Yc=(rh.prototype.di=function(t){},rh.prototype.shutdown=function(){},rh),Xc=(nh.prototype.di=function(t){this.gi.push(t)},nh.prototype.shutdown=function(){window.removeEventListener("online",this.wi),window.removeEventListener("offline",this.mi)},nh.prototype.pi=function(){window.addEventListener("online",this.wi),window.addEventListener("offline",this.mi)},nh.prototype._i=function(){Bn("ConnectivityMonitor","Network connectivity changed: AVAILABLE");for(var t=0,e=this.gi;t<e.length;t++)(0,e[t])(0)},nh.prototype.yi=function(){Bn("ConnectivityMonitor","Network connectivity changed: UNAVAILABLE");for(var t=0,e=this.gi;t<e.length;t++)(0,e[t])(1)},nh.yt=function(){return"undefined"!=typeof window&&void 0!==window.addEventListener&&void 0!==window.removeEventListener},nh),Qc={BatchGetDocuments:"batchGet",Commit:"commit",RunQuery:"runQuery"},Jc=(ih.prototype.Ii=function(t){this.Ai=t},ih.prototype.Ri=function(t){this.bi=t},ih.prototype.onMessage=function(t){this.vi=t},ih.prototype.close=function(){this.Ti()},ih.prototype.send=function(t){this.Ei(t)},ih.prototype.Pi=function(){this.Ai()},ih.prototype.Vi=function(t){this.bi(t)},ih.prototype.Si=function(t){this.vi(t)},ih),Zc=(eh.prototype.Ni=function(e,t,i,n){var r=this.xi(e,t);return Bn("RestConnection","Sending: ",r,i),t={},this.ki(t,n),this.Fi(e,r,t,i).then(function(t){return Bn("RestConnection","Received: ",t),t},function(t){throw jn("RestConnection",e+" failed with error: ",t,"url: ",r,"request:",i),t})}
1,eh.prototype.$i=function(t,e,i,n){return this.Ni(t,e,i,n)},eh.prototype.ki=function(t,e){if(t["X-Goog-Api-Client"]="gl-js/ fire/8.10.0",t["Content-Type"]="text/plain",this.databaseInfo.appId&&(t["X-Firebase-GMPID"]=this.databaseInfo.appId),e)for(var i in e.authHeaders)e.authHeaders.hasOwnProperty(i)&&(t[i]=e.authHeaders[i])},eh.prototype.xi=function(t,e){return this.Di+"/v1/"+e+":"+Qc[t]},i(th,jc=eh),th.prototype.Fi=function(l,e,i,n){return new Promise(function(s,o){var a=new An;a.listenOnce(En.COMPLETE,function(){try{switch(a.getLastErrorCode()){case Cn.NO_ERROR:var t=a.getResponseJson();Bn("Connection","XHR received:",JSON.stringify(t)),s(t);break;case Cn.TIMEOUT:Bn("Connection",'RPC "'+l+'" timed out'),o(new Ln(On.DEADLINE_EXCEEDED,"Request time out"));break;case Cn.HTTP_ERROR:var e,i,n=a.getStatus();Bn("Connection",'RPC "'+l+'" failed with status:',n,"response text:",a.getResponseText()),0<n?(e=a.getResponseJson().error)&&e.status&&e.message?(r=e.status.toLowerCase().replace(/_/g,"-"),i=0<=Object.values(On).indexOf(r)?r:On.UNKNOWN,o(new Ln(i,e.message))):o(new Ln(On.UNKNOWN,"Server responded with status "+a.getStatus())):o(new Ln(On.UNAVAILABLE,"Connection failed."));break;default:qn()}}finally{Bn("Connection",'RPC "'+l+'" completed.')}var r});var t=JSON.stringify(n);a.send(e,"POST",t,i,15)})},th.prototype.Oi=function(t,e){var i,n=[this.Di,"/","google.firestore.v1.Firestore","/",t,"/channel"],r=new bn,s=Sn();t={httpSessionIdParam:"gsessionid",initMessageHeaders:{},messageUrlParams:{database:"projects/"+this.databaseId.projectId+"/databases/"+this.databaseId.database},sendRawJson:!0,supportsCrossDomainXhr:!0,internalChannelParams:{forwardChannelRequestTimeoutMs:6e5},forceLongPolling:this.forceLongPolling,detectBufferingProxy:this.autoDetectLongPolling};this.useFetchStreams&&(t.xmlHttpFactory=new In({})),this.ki(t.initMessageHeaders,e),"undefined"!=typeof window&&(window.cordova||window.phonegap||window.PhoneGap)&&/ios|iphone|ipod|ipad|android|blackberry|iemobile/i.test(c())||"object"==typeof navigator&&"ReactNative"===navigator.product||0<=c().indexOf("Electron/")||0<=(i=c()).indexOf("MSIE ")||0<=i.indexOf("Trident/")||0<=c().indexOf("MSAppHost/")||"object"==typeof(i="object"==typeof chrome?chrome.runtime:"object"==typeof browser?browser.runtime:void 0)&&void 0!==i.id||(t.httpHeadersOverwriteParam="$httpHeaders"),Bn("Connection","Creating WebChannel: "+(n=n.join("")),t);var o=r.createWebChannel(n,t),a=!1,l=!1,u=new Jc({Ei:function(t){l?Bn("Connection","Not sending because WebChannel is closed:",t):(a||(Bn("Connection","Opening WebChannel transport."),o.open(),a=!0),Bn("Connection","WebChannel sending:",t),o.send(t))},Ti:function(){return o.close()}});return(t=function(t,e,i){t.listen(e,function(t){try{i(t)}catch(t){setTimeout(function(){throw t},0)}})})(o,Dn.EventType.OPEN,function(){l||Bn("Connection","WebChannel transport opened.")}),t(o,Dn.EventType.CLOSE,function(){l||(l=!0,Bn("Connection","WebChannel transport closed"),u.Vi())}),t(o,Dn.EventType.ERROR,function(t){l||(l=!0,jn("Connection","WebChannel transport errored:",t),u.Vi(new Ln(On.UNAVAILABLE,"The operation could not be completed")))}),t(o,Dn.EventType.MESSAGE,function(t){var e,i,n,r;l||(Vn(!!(e=t.data[0])),(i=e.error||(null===(r=e[0])||void 0===r?void 0:r.error))?(Bn("Connection","WebChannel received error:",i),n=i.status,t=function(){var t=Co[n];if(void 0!==t)return No(t)}(),r=i.message,void 0===t&&(t=On.INTERNAL,r="Unknown error status: "+n+" with message "+i.message),l=!0,u.Vi(new Ln(t,r)),o.close()):(Bn("Connection","WebChannel received:",e),u.Si(e)))}),t(s,kn.STAT_EVENT,function(t){10===t.stat?Bn("Connection","Detected buffering proxy"):11===t.stat&&Bn("Connection","Detected no buffering proxy")}),setTimeout(function(){u.Pi()},0),u},th);function th(t){var e=this;return(e=jc.call(this,t)||this).forceLongPolling=t.forceLongPolling,e.autoDetectLongPolling=t.autoDetectLongPolling,e.useFetchStreams=t.useFetchStreams,e}function eh(t){this.databaseInfo=t,this.databaseId=t.databaseId;var e=t.ssl?"https":"http";this.Di=e+"://"+t.host,this.Ci="projects/"+this.databaseId.projectId+"/databases/"+this.databaseId.database+"/documents"}function ih(t){this.Ei=t.Ei,this.Ti=t.Ti}function nh(){var t=this;this.wi=function(){return t._i()},this.mi=function(){return t.yi()},this.gi=[],this.pi()}function rh(){}function sh(){this.li=new Wc,this.fi={},this.onlineStateHandler=null,this.sequenceNumberHandler=null}function oh(t,e,i,n,r){this.window=t,this.Se=e,this.persistenceKey=i,this.Ns=n,this.syncEngine=null,this.onlineStateHandler=null,this.sequenceNumberHandler=null,this.xs=this.ks.bind(this),this.Fs=new Oo(Kn),this.started=!1,this.$s=[],i=i.replace(/[.*+?^${}()|[\]\\]/g,"\\$&"),this.storage=this.window.localStorage,this.currentUser=r,this.Os=zc(this.persistenceKey,this.Ns),this.Ms="firestore_sequence_number_"+this.persistenceKey,this.Fs=this.Fs.insert(this.Ns,new Wc),this.Ls=new RegExp("^firestore_clients_"+i+"_([^_]*)$"),this.Bs=new RegExp("^firestore_mutations_"+i+"_(\\d+)(?:_(.*))?$"),this.qs=new RegExp("^firestore_targets_"+i+"_(\\d+)$"),this.Us="firestore_online_state_"+this.persistenceKey,this.Ks="firestore_bundle_loaded_"+this.persistenceKey,this.window.addEventListener("storage",this.xs)}function ah(){this.activeTargetIds=Xo}function lh(t,e){this.clientId=t,this.onlineState=e}function uh(t,e){this.clientId=t,this.activeTargetIds=e}function ch(t,e,i){this.targetId=t,this.state=e,this.error=i}function hh(t,e,i,n){this.user=t,this.batchId=e,this.state=i,this.error=n}function dh(){return"undefined"!=typeof window?window:null}function ph(){return"undefined"!=typeof document?document:null}function fh(t){return new da(t,!0)}
1function gh(t,e,i,n,r){var s=this;this.localStore=t,this.datastore=e,this.asyncQueue=i,this.remoteSyncer={},this.Fr=[],this.$r=new Map,this.Or=new Set,this.Mr=[],this.Lr=r,this.Lr.di(function(t){i.enqueueAndForget(function(){return g(s,void 0,void 0,function(){return m(this,function(t){switch(t.label){case 0:return zh(this)?(Bn("RemoteStore","Restarting streams for network reachability change."),[4,function(i){return g(this,void 0,void 0,function(){var e;return m(this,function(t){switch(t.label){case 0:return(e=i).Or.add(4),[4,Ph(e)];case 1:return t.sent(),e.Br.set("Unknown"),e.Or.delete(4),[4,Ah(e)];case 2:return t.sent(),[2]}})})}(this)]):[3,2];case 1:t.sent(),t.label=2;case 2:return[2]}})})})}),this.Br=new Th(i,n)}var mh,vh,yh,bh=(Dh.prototype.reset=function(){this.qi=0},Dh.prototype.Qi=function(){this.qi=this.Bi},Dh.prototype.ji=function(t){var e=this;this.cancel();var i=Math.floor(this.qi+this.Wi()),n=Math.max(0,Date.now()-this.Ki),r=Math.max(0,i-n);0<r&&Bn("ExponentialBackoff","Backing off for "+r+" ms (base delay: "+this.qi+" ms, delay with jitter: "+i+" ms, last attempt: "+n+" ms ago)"),this.Ui=this.Se.enqueueAfterDelay(this.timerId,r,function(){return e.Ki=Date.now(),t()}),this.qi*=this.Li,this.qi<this.Mi&&(this.qi=this.Mi),this.qi>this.Bi&&(this.qi=this.Bi)},Dh.prototype.Gi=function(){null!==this.Ui&&(this.Ui.skipDelay(),this.Ui=null)},Dh.prototype.cancel=function(){null!==this.Ui&&(this.Ui.cancel(),this.Ui=null)},Dh.prototype.Wi=function(){return(Math.random()-.5)*this.qi},Dh),wh=(C=(Ih.prototype.tr=function(){return 1===this.state||2===this.state||4===this.state},Ih.prototype.er=function(){return 2===this.state},Ih.prototype.start=function(){3!==this.state?this.auth():this.nr()},Ih.prototype.stop=function(){return g(this,void 0,void 0,function(){return m(this,function(t){switch(t.label){case 0:return this.tr()?[4,this.close(0)]:[3,2];case 1:t.sent(),t.label=2;case 2:return[2]}})})},Ih.prototype.sr=function(){this.state=0,this.Zi.reset()},Ih.prototype.ir=function(){var t=this;this.er()&&null===this.Xi&&(this.Xi=this.Se.enqueueAfterDelay(this.zi,6e4,function(){return t.rr()}))},Ih.prototype.cr=function(t){this.ur(),this.stream.send(t)},Ih.prototype.rr=function(){return g(this,void 0,void 0,function(){return m(this,function(t){return this.er()?[2,this.close(0)]:[2]})})},Ih.prototype.ur=function(){this.Xi&&(this.Xi.cancel(),this.Xi=null)},Ih.prototype.close=function(e,i){return g(this,void 0,void 0,function(){return m(this,function(t){switch(t.label){case 0:return this.ur(),this.Zi.cancel(),this.Yi++,3!==e?this.Zi.reset():i&&i.code===On.RESOURCE_EXHAUSTED?($n(i.toString()),$n("Using maximum backoff delay to prevent overloading the backend."),this.Zi.Qi()):i&&i.code===On.UNAUTHENTICATED&&this.Ji.invalidateToken(),null!==this.stream&&(this.ar(),this.stream.close(),this.stream=null),this.state=e,[4,this.listener.Ri(i)];case 1:return t.sent(),[2]}})})},Ih.prototype.ar=function(){},Ih.prototype.auth=function(){var i=this;this.state=1;var t=this.hr(this.Yi),e=this.Yi;this.Ji.getToken().then(function(t){i.Yi===e&&i.lr(t)},function(e){t(function(){var t=new Ln(On.UNKNOWN,"Fetching auth token failed: "+e.message);return i.dr(t)})})},Ih.prototype.lr=function(t){var e=this,i=this.hr(this.Yi);this.stream=this.wr(t),this.stream.Ii(function(){i(function(){return e.state=2,e.listener.Ii()})}),this.stream.Ri(function(t){i(function(){return e.dr(t)})}),this.stream.onMessage(function(t){i(function(){return e.onMessage(t)})})},Ih.prototype.nr=function(){var t=this;this.state=4,this.Zi.ji(function(){return g(t,void 0,void 0,function(){return m(this,function(t){return this.state=0,this.start(),[2]})})})},Ih.prototype.dr=function(t){return Bn("PersistentStream","close with error: "+t),this.stream=null,this.close(3,t)},Ih.prototype.hr=function(e){var i=this;return function(t){i.Se.enqueueAndForget(function(){return i.Yi===e?t():(Bn("PersistentStream","stream callback skipped by getCloseGuardedDispatcher."),Promise.resolve())})}},Ih),i(kh,yh=C),kh.prototype.wr=function(t){return this.Hi.Oi("Listen",t)},kh.prototype.onMessage=function(t){this.Zi.reset();var e,i=function(t,e){if("targetChange"in e){e.targetChange;var i="NO_CHANGE"===(s=e.targetChange.targetChangeType||"NO_CHANGE")?0:"ADD"===s?1:"REMOVE"===s?2:"CURRENT"===s?3:"RESET"===s?4:qn(),n=e.targetChange.targetIds||[],r=(o=e.targetChange.resumeToken,t.I?(Vn(void 0===o||"string"==typeof o),ur.fromBase64String(o||"")):(Vn(void 0===o||o instanceof Uint8Array),ur.fromUint8Array(o||new Uint8Array))),s=(a=e.targetChange.cause)&&(l=void 0===(u=a).code?On.UNKNOWN:No(u.code),new Ln(l,u.message||"")),o=new ea(i,n,r,s||null)}else if("documentChange"in e){e.documentChange,(i=e.documentChange).document,i.document.name,i.document.updateTime;n=ba(t,i.document.name),r=ga(i.document.updateTime);var a=new Br({mapValue:{fields:i.document.fields}}),l=(s=jr.newFoundDocument(n,r,a),i.targetIds||[]),u=i.removedTargetIds||[];o=new Zo(l,u,s.key,s)}else if("documentDelete"in e)e.documentDelete,(i=e.documentDelete).document,n=ba(t,i.document),r=i.readTime?ga(i.readTime):Qn.min(),a=jr.newNoDocument(n,r),s=i.removedTargetIds||[],o=new Zo([],s,a.key,a);else if("documentRemove"in e)e.documentRemove,(i=e.documentRemove).document,n=ba(t,i.document),r=i.removedTargetIds||[],o=new Zo([],r,n,null);else{if(!("filter"in e))return qn();e.filter,(e=e.filter).targetId,n=new So(i=e.count||0),r=e.targetId,o=new ta(r,n)}return o}(this.R,t);t="targetChange"in(e=t)?(e=e.targetChange).targetIds&&e.targetIds.length||!e.readTime?Qn.min():ga(e.readTime):Qn.min();return this.listener._r(i,t)},kh.prototype.mr=function(t){var e,i,n,r,s={};s.database=xa(this.R),s.addTarget=(e=this.R,(n=Kr(n=(i=t).target)?{documents:Ia(e,n)}:{query:Da(e,n)}).targetId=i.targetId,0<i.resumeToken.approximateByteSize()?n.resumeToken=fa(e,i.resumeToken):0<i.snapshotVersion.compareTo(Qn.min())&&(n.readTime=pa(e,i.snapshotVersion.toTimestamp())),n),(t=(this.R,r=t,null==(t=function(){switch(r.purpose){case 0:return null;case 1:return"existence-filter-mismatch";case 2:return"limbo-document";default:return qn()}}())?null:{"goog-listen-tags":t}))&&(s.labels=t),this.cr(s)},kh.prototype.yr=function(t){var e={};e.database=xa(this.R),e.removeTarget=t,this.cr(e)},kh),_h=(i(Eh,vh=C),Object.defineProperty(Eh.prototype,"pr",{get:function(){return this.gr}
1,enumerable:!1,configurable:!0}),Eh.prototype.start=function(){this.gr=!1,this.lastStreamToken=void 0,vh.prototype.start.call(this)},Eh.prototype.ar=function(){this.gr&&this.Er([])},Eh.prototype.wr=function(t){return this.Hi.Oi("Write",t)},Eh.prototype.onMessage=function(t){if(Vn(!!t.streamToken),this.lastStreamToken=t.streamToken,this.gr){this.Zi.reset();var e=(i=t.writeResults,n=t.commitTime,i&&0<i.length?(Vn(void 0!==n),i.map(function(t){return i=n,(t=(e=t).updateTime?ga(e.updateTime):ga(i)).isEqual(Qn.min())&&(t=ga(i)),new oo(t,e.transformResults||[]);var e,i})):[]),i=ga(t.commitTime);return this.listener.Tr(i,e)}var n;return Vn(!t.writeResults||0===t.writeResults.length),this.gr=!0,this.listener.Ir()},Eh.prototype.Ar=function(){var t={};t.database=xa(this.R),this.cr(t)},Eh.prototype.Er=function(t){var e=this;t={streamToken:this.lastStreamToken,writes:t.map(function(t){return Ea(e.R,t)})};this.cr(t)},Eh),xh=(i(Ch,mh=function(){}),Ch.prototype.br=function(){if(this.Rr)throw new Ln(On.FAILED_PRECONDITION,"The client has already been terminated.")},Ch.prototype.Ni=function(e,i,n){var r=this;return this.br(),this.credentials.getToken().then(function(t){return r.Hi.Ni(e,i,n,t)}).catch(function(t){throw"FirebaseError"===t.name?(t.code===On.UNAUTHENTICATED&&r.credentials.invalidateToken(),t):new Ln(On.UNKNOWN,t.toString())})},Ch.prototype.$i=function(e,i,n){var r=this;return this.br(),this.credentials.getToken().then(function(t){return r.Hi.$i(e,i,n,t)}).catch(function(t){throw"FirebaseError"===t.name?(t.code===On.UNAUTHENTICATED&&r.credentials.invalidateToken(),t):new Ln(On.UNKNOWN,t.toString())})},Ch.prototype.terminate=function(){this.Rr=!0},Ch),Th=(Sh.prototype.Sr=function(){var t=this;0===this.vr&&(this.Dr("Unknown"),this.Pr=this.asyncQueue.enqueueAfterDelay("online_state_timeout",1e4,function(){return t.Pr=null,t.Cr("Backend didn't respond within 10 seconds."),t.Dr("Offline"),Promise.resolve()}))},Sh.prototype.Nr=function(t){"Online"===this.state?this.Dr("Unknown"):(this.vr++,1<=this.vr&&(this.kr(),this.Cr("Connection failed 1 times. Most recent error: "+t.toString()),this.Dr("Offline")))},Sh.prototype.set=function(t){this.kr(),this.vr=0,"Online"===t&&(this.Vr=!1),this.Dr(t)},Sh.prototype.Dr=function(t){t!==this.state&&(this.state=t,this.onlineStateHandler(t))},Sh.prototype.Cr=function(t){t="Could not reach Cloud Firestore backend. "+t+"\nThis typically indicates that your device does not have a healthy Internet connection at the moment. The client will operate in offline mode until it is able to successfully connect to the backend.",this.Vr?($n(t),this.Vr=!1):Bn("OnlineStateTracker",t)},Sh.prototype.kr=function(){null!==this.Pr&&(this.Pr.cancel(),this.Pr=null)},Sh);function Sh(t,e){this.asyncQueue=t,this.onlineStateHandler=e,this.state="Unknown",this.vr=0,this.Pr=null,this.Vr=!0}function Ch(t,e,i){var n=this;return(n=mh.call(this)||this).credentials=t,n.Hi=e,n.R=i,n.Rr=!1,n}function Eh(t,e,i,n,r){var s=this;return(s=vh.call(this,t,"write_stream_connection_backoff","write_stream_idle",e,i,r)||this).R=n,s.gr=!1,s}function kh(t,e,i,n,r){var s=this;return(s=yh.call(this,t,"listen_stream_connection_backoff","listen_stream_idle",e,i,r)||this).R=n,s}function Ih(t,e,i,n,r,s){this.Se=t,this.zi=i,this.Hi=n,this.Ji=r,this.listener=s,this.state=0,this.Yi=0,this.Xi=null,this.stream=null,this.Zi=new bh(t,e)}function Dh(t,e,i,n,r){void 0===i&&(i=1e3),void 0===n&&(n=1.5),void 0===r&&(r=6e4),this.Se=t,this.timerId=e,this.Mi=i,this.Li=n,this.Bi=r,this.qi=0,this.Ui=null,this.Ki=Date.now(),this.reset()}function Ah(n){return g(this,void 0,void 0,function(){var e,i;return m(this,function(t){switch(t.label){case 0:if(!zh(n))return[3,4];e=0,i=n.Mr,t.label=1;case 1:return e<i.length?[4,(0,i[e])(!0)]:[3,4];case 2:t.sent(),t.label=3;case 3:return e++,[3,1];case 4:return[2]}})})}function Ph(n){return g(this,void 0,void 0,function(){var e,i;return m(this,function(t){switch(t.label){case 0:e=0,i=n.Mr,t.label=1;case 1:return e<i.length?[4,(0,i[e])(!1)]:[3,4];case 2:t.sent(),t.label=3;case 3:return e++,[3,1];case 4:return[2]}})})}function Mh(t,e){t.$r.has(e.targetId)||(t.$r.set(e.targetId,e),Fh(t)?Rh(t):Wh(t).er()&&Oh(t,e))}function Nh(t,e){var i=t;t=Wh(i);i.$r.delete(e),t.er()&&Lh(i,e),0===i.$r.size&&(t.er()?t.ir():zh(i)&&i.Br.set("Unknown"))}function Oh(t,e){t.qr.U(e.targetId),Wh(t).mr(e)}function Lh(t,e){t.qr.U(e),Wh(t).yr(e)}function Rh(e){e.qr=new na({getRemoteKeysForTarget:function(t){return e.remoteSyncer.getRemoteKeysForTarget(t)},lt:function(t){return e.$r.get(t)||null}}),Wh(e).start(),e.Br.Sr()}function Fh(t){return zh(t)&&!Wh(t).tr()&&0<t.$r.size}function zh(t){return 0===t.Or.size}function Bh(t){t.qr=void 0}function $h(i,n,r){return g(this,void 0,void 0,function(){var e=this;return m(this,function(t){switch(t.label){case 0:if(!vl(n))throw n;return i.Or.add(1),[4,Ph(i)];case 1:return t.sent(),i.Br.set("Offline"),r=r||function(){return ac(i.localStore)},i.asyncQueue.enqueueRetryable(function(){return g(e,void 0,void 0,function(){return m(this,function(t){switch(t.label){case 0:return Bn("RemoteStore","Retrying IndexedDB access"),[4,r()];case 1:return t.sent(),i.Or.delete(1),[4,Ah(i)];case 2:return t.sent(),[2]}})})}),[2]}})})}function jh(e,i){return i().catch(function(t){return $h(e,t,i)})}function Hh(c){return g(this,void 0,void 0,function(){var o,a,l,u;return m(this,function(t){switch(t.label){case 0:a=Kh(o=c),l=0<o.Fr.length?o.Fr[o.Fr.length-1].batchId:-1,t.label=1;case 1:if(!(zh(o)&&o.Fr.length<10))return[3,7];t.label=2;case 2:return t.trys.push([2,4,,6]),[4,(n=o.localStore,r=l,(s=n).persistence.runTransaction("Get next mutation batch","readonly",function(t){return void 0===r&&(r=-1),s._n.getNextMutationBatchAfterBatchId(t,r)}
1))];case 3:return null===(u=t.sent())?(0===o.Fr.length&&a.ir(),[3,7]):(l=u.batchId,i=u,(e=o).Fr.push(i),(e=Kh(e)).er()&&e.pr&&e.Er(i.mutations),[3,6]);case 4:return u=t.sent(),[4,$h(o,u)];case 5:return t.sent(),[3,6];case 6:return[3,1];case 7:return qh(o)&&Vh(o),[2]}var e,i,n,r,s})})}function qh(t){return zh(t)&&!Kh(t).tr()&&0<t.Fr.length}function Vh(t){Kh(t).start()}function Uh(i,n){return g(this,void 0,void 0,function(){var e;return m(this,function(t){switch(t.label){case 0:return e=i,n?(e.Or.delete(2),[4,Ah(e)]):[3,2];case 1:return t.sent(),[3,5];case 2:return n?[3,4]:(e.Or.add(2),[4,Ph(e)]);case 3:t.sent(),e.Br.set("Unknown"),t.label=4;case 4:t.label=5;case 5:return[2]}})})}function Wh(i){var t,e,n,r=this;return i.Ur||(i.Ur=(t=i.datastore,e=i.asyncQueue,n={Ii:function(i){return g(this,void 0,void 0,function(){return m(this,function(t){return i.$r.forEach(function(t,e){Oh(i,t)}),[2]})})}.bind(null,i),Ri:function(e,i){return g(this,void 0,void 0,function(){return m(this,function(t){return Bh(e),Fh(e)?(e.Br.Nr(i),Rh(e)):e.Br.set("Unknown"),[2]})})}.bind(null,i),_r:function(o,a,l){return g(this,void 0,void 0,function(){var i,s;return m(this,function(t){switch(t.label){case 0:if(o.Br.set("Online"),!(a instanceof ea&&2===a.state&&a.cause))return[3,6];t.label=1;case 1:return t.trys.push([1,3,,5]),[4,function(s,o){return g(this,void 0,void 0,function(){var e,i,n,r;return m(this,function(t){switch(t.label){case 0:e=o.cause,i=0,n=o.targetIds,t.label=1;case 1:return i<n.length?(r=n[i],s.$r.has(r)?[4,s.remoteSyncer.rejectListen(r,e)]:[3,3]):[3,5];case 2:t.sent(),s.$r.delete(r),s.qr.removeTarget(r),t.label=3;case 3:t.label=4;case 4:return i++,[3,1];case 5:return[2]}})})}(o,a)];case 2:return t.sent(),[3,5];case 3:return i=t.sent(),Bn("RemoteStore","Failed to remove targets %s: %s ",a.targetIds.join(","),i),[4,$h(o,i)];case 4:return t.sent(),[3,5];case 5:return[3,13];case 6:if(a instanceof Zo?o.qr.X(a):a instanceof ta?o.qr.rt(a):o.qr.et(a),l.isEqual(Qn.min()))return[3,13];t.label=7;case 7:return t.trys.push([7,11,,13]),[4,ac(o.localStore)];case 8:return s=t.sent(),0<=l.compareTo(s)?[4,(r=l,(e=(n=o).qr.ut(r)).targetChanges.forEac
1h(function(t,e){var i;0<t.resumeToken.approximateByteSize()&&(i=n.$r.get(e))&&n.$r.set(e,i.withResumeToken(t.resumeToken,r))}),e.targetMismatches.forEach(function(t){var e=n.$r.get(t);e&&(n.$r.set(t,e.withResumeToken(ur.EMPTY_BYTE_STRING,e.snapshotVersion)),Lh(n,t),e=new Dl(e.target,t,1,e.sequenceNumber),Oh(n,e))}),n.remoteSyncer.applyRemoteEvent(e))]:[3,10];case 9:t.sent(),t.label=10;case 10:return[3,13];case 11:return Bn("RemoteStore","Failed to raise snapshot:",s=t.sent()),[4,$h(o,s)];case 12:return t.sent(),[3,13];case 13:return[2]}var n,r,e})})}.bind(null,i)},t.br(),new wh(e,t.Hi,t.credentials,t.R,n)),i.Mr.push(function(e){return g(r,void 0,void 0,function(){return m(this,function(t){switch(t.label){case 0:return e?(i.Ur.sr(),Fh(i)?Rh(i):i.Br.set("Unknown"),[3,3]):[3,1];case 1:return[4,i.Ur.stop()];case 2:t.sent(),Bh(i),t.label=3;case 3:return[2]}})})})),i.Ur}function Kh(i){var t,e,n,r=this;return i.Kr||(i.Kr=(t=i.datastore,e=i.asyncQueue,n={Ii:function(e){return g(this,void 0,void 0,function(){return m(this,function(t){return Kh(e).Ar(),[2]})})}.bind(null,i),Ri:function(e,i){return g(this,void 0,void 0,function(){return m(this,function(t){switch(t.label){case 0:return i&&Kh(e).pr?[4,function(n,r){return g(this,void 0,void 0,function(){var e,i;return m(this,function(t){switch(t.label){case 0:return Mo(i=r.code)&&i!==On.ABORTED?(e=n.Fr.shift(),Kh(n).sr(),[4,jh(n,function(){return n.remoteSyncer.rejectFailedWrite(e.batchId,r)})]):[3,3];case 1:return t.sent(),[4,Hh(n)];case 2:t.sent(),t.label=3;case 3:return[2]}})})}(e,i)]:[3,2];case 1:t.sent(),t.label=2;case 2:return qh(e)&&Vh(e),[2]}})})}.bind(null,i),Ir:function(s){return g(this,void 0,void 0,function(){var e,i,n,r;return m(this,function(t){for(e=Kh(s),i=0,n=s.Fr;i<n.length;i++)r=n[i],e.Er(r.mutations);return[2]})})}.bind(null,i),Tr:function(n,r,s){return g(this,void 0,void 0,function(){var e,i;return m(this,function(t){switch(t.label){case 0:return e=n.Fr.shift(),i=Il.from(e,r,s),[4,jh(n,function(){return n.remoteSyncer.applySuccessfulWrite(i)})];case 1:return t.sent(),[4,Hh(n)];case 2:return t.sent(),[2]}})})}.bind(null,i)},t.br(),new _h(e,t.Hi,t.credentials,t.R,n)),i.Mr.push(function(e){return g(r,void 0,void 0,function(){return m(this,function(t){switch(t.label){case 0:return e?(i.Kr.sr(),[4,Hh(i)]):[3,2];case 1:return t.sent(),[3,4];case 2:return[4,i.Kr.stop()];case 3:t.sent(),0<i.Fr.length&&(Bn("RemoteStore","Stopping write stream with "+i.Fr.length+" pending writes"),i.Fr=[]),t.label=4;case 4:return[2]}})})})),i.Kr}var Gh=(Yh.createAndSchedule=function(t,e,i,n,r){return(r=new Yh(t,e,Date.now()+i,n,r)).start(i),r},Yh.prototype.start=function(t){var e=this;this.timerHandle=setTimeout(function(){return e.handleDelayElapsed()},t)},Yh.prototype.skipDelay=function(){return this.handleDelayElapsed()},Yh.prototype.cancel=function(t){null!==this.timerHandle&&(this.clearTimeout(),this.deferred.reject(new Ln(On.CANCELLED,"Operation cancelled"+(t?": "+t:"")))
1)},Yh.prototype.handleDelayElapsed=function(){var e=this;this.asyncQueue.enqueueAndForget(function(){return null!==e.timerHandle?(e.clearTimeout(),e.op().then(function(t){return e.deferred.resolve(t)})):Promise.resolve()})},Yh.prototype.clearTimeout=function(){null!==this.timerHandle&&(this.removalCallback(this),clearTimeout(this.timerHandle),this.timerHandle=null)},Yh);function Yh(t,e,i,n,r){this.asyncQueue=t,this.timerId=e,this.targetTimeMs=i,this.op=n,this.removalCallback=r,this.deferred=new sl,this.then=this.deferred.promise.then.bind(this.deferred.promise),this.deferred.promise.catch(function(t){})}function Xh(t,e){if($n("AsyncQueue",e+": "+t),vl(t))return new Ln(On.UNAVAILABLE,e+": "+t);throw t}function Qh(){this.queries=new Pu(Rs,Ls),this.onlineState="Unknown",this.Gr=new Set}var Jh=(rd.emptySet=function(t){return new rd(t.comparator)},rd.prototype.has=function(t){return null!=this.keyedMap.get(t)},rd.prototype.get=function(t){return this.keyedMap.get(t)},rd.prototype.first=function(){return this.sortedSet.minKey()},rd.prototype.last=function(){return this.sortedSet.maxKey()},rd.prototype.isEmpty=function(){return this.sortedSet.isEmpty()},rd.prototype.indexOf=function(t){return(t=this.keyedMap.get(t))?this.sortedSet.indexOf(t):-1},Object.defineProperty(rd.prototype,"size",{get:function(){return this.sortedSet.size},enumerable:!1,configurable:!0}),rd.prototype.forEach=function(i){this.sortedSet.inorderTraversal(function(t,e){return i(t),!1})},rd.prototype.add=function(t){var e=this.delete(t.key);return e.copy(e.keyedMap.insert(t.key,t),e.sortedSet.insert(t,null))},rd.prototype.delete=function(t){var e=this.get(t);return e?this.copy(this.keyedMap.remove(t),this.sortedSet.remove(e)):this},rd.prototype.isEqual=function(t){if(!(t instanceof rd))return!1;if(this.size!==t.size)return!1;for(var e=this.sortedSet.getIterator(),i=t.sortedSet.getIterator();e.hasNext();){var n=e.getNext().key,r=i.getNext().key;if(!n.isEqual(r))return!1}return!0},rd.prototype.toString=function(){var e=[];return this.forEach(function(t){e.push(t.toString())}),0===e.length?"DocumentSet ()":"DocumentSet (\n  "+e.join("  \n")+"\n)"},rd.prototype.copy=function(t,e){var i=new rd;return i.comparator=this.comparator,i.keyedMap=t,i.sortedSet=e,i},rd),Zh=(nd.prototype.track=function(t){var e=t.doc.key,i=this.Qr.get(e);!i||0!==t.type&&3===i.type?this.Qr=this.Qr.insert(e,t):3===t.type&&1!==i.type?this.Qr=this.Qr.insert(e,{type:i.type,doc:t.doc}):2===t.type&&2===i.type?this.Qr=this.Qr.insert(e,{type:2,doc:t.doc}):2===t.type&&0===i.type?this.Qr=this.Qr.insert(e,{type:0,doc:t.doc}):1===t.type&&0===i.type?this.Qr=this.Qr.remove(e):1===t.type&&2===i.type?this.Qr=this.Qr.insert(e,{type:1,doc:i.doc}):0===t.type&&1===i.type?this.Qr=this.Qr.insert(e,{type:2,doc:t.doc}):qn()},nd.prototype.jr=function(){var i=[];return this.Qr.inorderTraversal(function(t,e){i.push(e)}),i},nd),td=(id.fromInitialDocuments=function(t,e,i,n){var r=[];return e.forEach(function(t){r.push({type:0,doc:t})}),new id(t,e,Jh.emptySet(e),r,i,n,!0,!1)},Object.defineProperty(id.prototype,"hasPendingWrites",{get:function(){return!this.mutatedKeys.isEmpty()},enumerable:!1,configurable:!0}),id.prototype.isEqual=function(t){if(!(this.fromCache===t.fromCache&&this.syncStateChanged===t.syncStateChanged&&this.mutatedKeys.isEqual(t.mutatedKeys)&&Ls(this.query,t.query)&&this.docs.isEqual(t.docs)&&this.oldDocs.isEqual(t.oldDocs)))return!1;var e=this.docChanges,i=t.docChanges;if(e.length!==i.length)return!1;for(var n=0;n<e.length;n++)if(e[n].type!==i[n].type||!e[n].doc.isEqual(i[n].doc))return!1;return!0},id),ed=function(){this.Wr=void 0,this.listeners=[]};function id(t,e,i,n,r,s,o,a){this.query=t,this.docs=e,this.oldDocs=i,this.docChanges=n,this.mutatedKeys=r,this.fromCache=s,this.syncStateChanged=o,this.excludesMetadataChanges=a}function nd(){this.Qr=new Oo(Sr.comparator)}function rd(i){this.comparator=i?function(t,e){return i(t,e)||Sr.comparator(t.key,e.key)}:function(t,e){return Sr.comparator(t.key,e.key)},this.keyedMap=Wo,this.sortedSet=new Oo(this.comparator)}function sd(o,a){return g(this,void 0,void 0,function(){var e,i,n,r,s;return m(this,function(t){switch(t.label){case 0:if(e=o,i=a.query,n=!1,(r=e.queries.get(i))||(n=!0,r=new ed),!n)return[3,4];t.label=1;case 1:return t.trys.push([1,3,,4]),s=r,[4,e.onListen(i)];case 2:return s.Wr=t.sent(),[3,4];case 3:return s=Xh(s=t.sent(),"Initialization of query '"+Fs(a.query)+"' failed"),[2,void a.onError(s)];case 4:return e.queries.set(i,r),r.listeners.push(a),a.zr(e.onlineState),r.Wr&&a.Hr(r.Wr)&&ad(e),[2]}})})}function od(o,a){return g(this,void 0,void 0,function(){var e,i,n,r,s;return m(this,function(t){return e=o,i=a.query,n=!1,(r=e.queries.get(i))&&0<=(s=r.listeners.indexOf(a))&&(r.listeners.splice(s,1),n=0===r.listeners.length),n?[2,(e.queries.delete(i),e.onUnlisten(i))]:[2]})})}function ad(t){t.Gr.forEach(function(t){t.next()})}var ld=(gd.prototype.Hr=function(t){if(!this.options.includeMetadataChanges){for(var e=[],i=0,n=t.docChanges;i<n.length;i++){var r=n[i];3!==r.type&&e.push(r)}t=new td(t.query,t.docs,t.oldDocs,e,t.mutatedKeys,t.fromCache,t.syncStateChanged,!0)}var s=!1;return this.Yr?this.Zr(t)&&(this.Jr.next(t),s=!0):this.eo(t,this.onlineState)&&(this.no(t),s=!0),this.Xr=t,s},gd.prototype.onError=function(t){this.Jr.error(t)},gd.prototype.zr=function(t){this.onlineState=t;var e=!1;return this.Xr&&!this.Yr&&this.eo(this.Xr,t)&&(this.no(this.Xr),e=!0),e},gd.prototype.eo=function(t,e){return!t.fromCache||!(this.options.so&&"Offline"!==e||t.docs.isEmpty()&&"Offline"!==e)},gd.prototype.Zr=function(t){if(0<t.docChanges.length)return!0;var e=this.Xr&&this.Xr.hasPendingWrites!==t.hasPendingWrites;return!(!t.syncStateChanged&&!e)&&!0===this.options.includeMetadataChanges},gd.prototype.no=function(t){t=td.fromInitialDocuments(t.query,t.docs,t.mutatedKeys,t.fromCache),this.Yr=!0,this.Jr.next(t)},gd),ud=(fd.prototype.io=function(){return"metadata"in this.payload},fd),cd=(pd.prototype.qn=function(t){return ba(this.R,t)},pd.prototype.Un=function(t){return t.metadata.exists?Ca(this.R,t.document,!1):jr.
1newNoDocument(this.qn(t.metadata.name),this.Kn(t.metadata.readTime))},pd.prototype.Kn=ga,pd),hd=(dd.prototype.oo=function(t){this.progress.bytesLoaded+=t.byteLength;var e=this.progress.documentsLoaded;return t.payload.namedQuery?this.queries.push(t.payload.namedQuery):t.payload.documentMetadata?(this.documents.push({metadata:t.payload.documentMetadata}),t.payload.documentMetadata.exists||++e):t.payload.document&&(this.documents[this.documents.length-1].document=t.payload.document,++e),e!==this.progress.documentsLoaded?(this.progress.documentsLoaded=e,Object.assign({},this.progress)):null},dd.prototype.co=function(t){for(var e=new Map,i=new cd(this.R),n=0,r=t;n<r.length;n++){var s=r[n];if(s.metadata.queries)for(var o=i.qn(s.metadata.name),a=0,l=s.metadata.queries;a<l.length;a++){var u=l[a],c=(e.get(u)||Yo()).add(o);e.set(u,c)}}return e},dd.prototype.complete=function(){return g(this,void 0,void 0,function(){var e,i,n,r;return m(this,function(t){switch(t.label){case 0:return[4,function(h,d,p,f){return g(this,void 0,void 0,function(){var i,n,r,s,e,o,a,l,u,c;return m(this,function(t){switch(t.label){case 0:for(i=h,n=Yo(),r=qo,s=Ko,e=0,o=p;e<o.length;e++)a=o[e],l=d.qn(a.metadata.name),a.document&&(n=n.add(l)),r=r.insert(l,d.Un(a)),s=s.insert(l,d.Kn(a.metadata.readTime));return u=i.On.newChangeBuffer({trackRemovals:!0}),[4,uc(i,Ns(Es(sr.fromString("__bundle__/docs/"+f))))];case 1:return c=t.sent(),[2,i.persistence.runTransaction("Apply bundle documents","readwrite",function(e){return lc(e,u,r,Qn.min(),s).next(function(t){return u.apply(e),t}).next(function(t){return i.qe.removeMatchingKeysForTargetId(e,c.targetId).next(function(){return i.qe.addMatchingKeys(e,n,c.targetId)}).next(function(){return i.Mn.En(e,t)}).next(function(){return t})})})]}})})}(this.localStore,new cd(this.R),this.documents,this.ro.id)];case 1:e=t.sent(),i=this.co(this.documents),n=0,r=this.queries,t.label=2;case 2:return n<r.length?(r=r[n],[4,function(e,r,s){return void 0===s&&(s=Yo()),g(this,void 0,void 0,function(){var i,n;return m(this,function(t){switch(t.label){case 0:return[4,uc(e,Ns(ql(r.bundledQuery)))];case 1:return i=t.sent(),[2,(n=e).persistence.runTransaction("Save named query","readwrite",function(t){var e=ga(r.readTime);return 0<=i.snapshotVersion.compareTo(e)?n.Ke.saveNamedQuery(t,r):(e=i.withResumeToken(ur.EMPTY_BYTE_STRING,e),n.kn=n.kn.insert(e.targetId,e),n.qe.updateTargetData(t,e).next(function(){return n.qe.removeMatchingKeysForTargetId(t,i.targetId)}).next(function(){return n.qe.addMatchingKeys(t,s,i.targetId)}).next(function(){return n.Ke.saveNamedQuery(t,r)}))})]}})})}(this.localStore,r,i.get(r.name))]):[3,5];case 3:t.sent(),t.label=4;case 4:return n++,[3,2];case 5:return[2,(this.progress.taskState="Success",new Xu(Object.assign({},this.progress),e))]}})})},dd);function dd(t,e,i){this.ro=t,this.localStore=e,this.R=i,this.queries=[],this.documents=[],this.progress=md(t)}function pd(t){this.R=t}function fd(t,e){this.payload=t,this.byteLength=e}function gd(t,e,i){this.query=t,this.Jr=e,this.Yr=!1,this.Xr=null,this.onlineState="Unknown",this.options=i||{}}function md(t){return{taskState:"Running",documentsLoaded:0,bytesLoaded:0,totalDocuments:t.totalDocuments,totalBytes:t.totalBytes}}var vd=function(t){this.key=t},yd=function(t){this.key=t},bd=(Object.defineProperty(Sd.prototype,"wo",{get:function(){return this.uo},enumerable:!1,configurable:!0}),Sd.prototype._o=function(t,e){var o=this,a=e?e.mo:new Zh,l=(e||this).fo,u=(e||this).mutatedKeys,c=l,h=!1,d=ks(this.query)&&l.size===this.query.limit?l.last():null,p=Is(this.query)&&l.size===this.query.limit?l.first():null;if(t.inorderTraversal(function(t,e){var i=l.get(t),n=zs(o.query,e)?e:null,r=!!i&&o.mutatedKeys.has(i.key),s=!!n&&(n.hasLocalMutations||o.mutatedKeys.has(n.key)&&n.hasCommittedMutations);e=!1;i&&n?i.data.isEqual(n.data)?r!==s&&(a.track({type:3,doc:n}),e=!0):o.yo(i,n)||(a.track({type:2,doc:n}),e=!0,(d&&0<o.lo(n,d)||p&&o.lo(n,p)<0)&&(h=!0)):!i&&n?(a.track({type:0,doc:n}),e=!0):i&&!n&&(a.track({type:1,doc:i}),e=!0,(d||p)&&(h=!0)),e&&(u=n?(c=c.add(n),s?u.add(t):u.delete(t)):(c=c.delete(t),u.delete(t)))}),ks(this.query)||Is(this.query))for(;c.size>this.query.limit;
1){var i=ks(this.query)?c.last():c.first();c=c.delete(i.key),u=u.delete(i.key);a.track({type:1,doc:i})}return{fo:c,mo:a,Nn:h,mutatedKeys:u}},Sd.prototype.yo=function(t,e){return t.hasLocalMutations&&e.hasCommittedMutations&&!e.hasLocalMutations},Sd.prototype.applyChanges=function(t,e,i){var s=this,n=this.fo;this.fo=t.fo,this.mutatedKeys=t.mutatedKeys;var r=t.mo.jr();r.sort(function(t,e){return n=t.type,r=e.type,i(n)-i(r)||s.lo(t.doc,e.doc);function i(t){switch(t){case 0:return 1;case 2:case 3:return 2;case 1:return 0;default:return qn()}}var n,r}),this.po(i);var o=e?this.Eo():[];e=(i=0===this.ho.size&&this.current?1:0)!==this.ao;return this.ao=i,0!==r.length||e?{snapshot:new td(this.query,t.fo,n,r,t.mutatedKeys,0==i,e,!1),To:o}:{To:o}},Sd.prototype.zr=function(t){return this.current&&"Offline"===t?(this.current=!1,this.applyChanges({fo:this.fo,mo:new Zh,mutatedKeys:this.mutatedKeys,Nn:!1},!1)):{To:[]}},Sd.prototype.Io=function(t){return!this.uo.has(t)&&!!this.fo.has(t)&&!this.fo.get(t).hasLocalMutations},Sd.prototype.po=function(t){var e=this;t&&(t.addedDocuments.forEach(function(t){return e.uo=e.uo.add(t)}),t.modifiedDocuments.forEach(function(t){}),t.removedDocuments.forEach(function(t){return e.uo=e.uo.delete(t)}),this.current=t.current)},Sd.prototype.Eo=function(){var e=this;if(!this.current)return[];var i=this.ho;this.ho=Yo(),this.fo.forEach(function(t){e.Io(t.key)&&(e.ho=e.ho.add(t.key))});var n=[];return i.forEach(function(t){e.ho.has(t)||n.push(new yd(t))}),this.ho.forEach(function(t){i.has(t)||n.push(new vd(t))}),n},Sd.prototype.Ao=function(t){return this.uo=t.Bn,this.ho=Yo(),t=this._o(t.documents),this.applyChanges(t,!0)},Sd.prototype.Ro=function(){return td.fromInitialDocuments(this.query,this.fo,this.mutatedKeys,0===this.ao)},Sd),wd=function(t,e,i){this.query=t,this.targetId=e,this.view=i},_d=function(t){this.key=t,this.bo=!1},xd=(Object.defineProperty(Td.prototype,"isPrimaryClient",{get:function(){return!0===this.$o},enumerable:!1,configurable:!0}),Td);function Td(t,e,i,n,r,s){this.localStore=t,this.remoteStore=e,this.eventManager=i,this.sharedClientState=n,this.currentUser=r,this.maxConcurrentLimboResolutions=s,this.vo={},this.Po=new Pu(Rs,Ls),this.Vo=new Map,this.So=new Set,this.Do=new Oo(Sr.comparator),this.Co=new Map,this.No=new vc,this.xo={},this.ko=new Map,this.Fo=du.Yt(),this.onlineState="Unknown",this.$o=void 0}function Sd(t,e){this.query=t,this.uo=e,this.ao=null,this.current=!1,this.ho=Yo(),this.mutatedKeys=Yo(),this.lo=Bs(t),this.fo=new Jh(this.lo)}function Cd(r,s,o,a){return g(this,void 0,void 0,function(){var e,i,n;return m(this,function(t){switch(t.label){case 0:return r.Oo=function(t,e,i){return function(n,r,s,o){return g(this,void 0,void 0,function(){var e,i;return m(this,function(t){switch(t.label){case 0:return(e=r.view._o(s)).Nn?[4,hc(n.localStore,r.query,!1).then(function(t){return t=t.documents,r.view._o(t,e)})]:[3,2];case 1:e=t.sent(),t.label=2;case 2:return i=o&&o.targetChanges.get(r.targetId),i=r.view.applyChanges(e,n.isPrimaryClient,i),[2,(Od(n,r.targetId,i.To),i.snapshot)]}})})}(r,t,e,i)},[4,hc(r.localStore,s,!0)];case 1:return i=t.sent(),n=new bd(s,i.Bn),e=n._o(i.documents),i=Jo.createSynthesizedTargetChangeForCurrentChange(o,a&&"Offline"!==r.onlineState),i=n.applyChanges(e,r.isPrimaryClient,i),Od(r,o,i.To),n=new wd(s,o,n),[2,(r.Po.set(s,n),r.Vo.has(o)?r.Vo.get(o).push(s):r.Vo.set(o,[s]),i.snapshot)]}})})}function Ed(d,p,f){return g(this,void 0,void 0,function(){var o,h;return m(this,function(t){switch(t.label){case 0:h=$d(d),t.label=1;case 1:return t.trys.push([1,5,,6]),[4,(r=h.localStore,a=p,u=r,c=Xn.now(),s=a.reduce(function(t,e){return t.add(e.key)},Yo()),u.persistence.runTransaction("Locally write mutations","readwrite",function(o){return u.Mn.pn(o,s).next(function(t){l=t;for(var e=[],i=0,n=a;i<n.length;i++){var r=n[i],s=function(t,e){for(var i=null,n=0,r=t.fieldTransforms;n<r.length;n++){var s=r[n],o=e.data.field(s.field);null!=(o=qs(s.transform,o||null))&&(i=null==i?Br.empty():i).set(s.field,o)}return i||null}(r,l.get(r.key));null!=s&&e.push(new yo(r.key,s,function o(t){var a=[];return er(t.fields,function(t,e){var i=new ar([t]);if(Fr(e))if(0===(e=o(e.mapValue).fields).length)a.push(i);else for(var n=0,r=e;n<r.length;n++){var s=r[n];a.push(i.child(s))}else a.push(i)}),new lr(a)}(s.value.mapValue),lo.exists(!0)))}return u._n.addMutationBatch(o,c,e,a)})}).then(function(t){return t.applyToLocalDocumentSet(l),{batchId:t.batchId,changes:l}}))];
1case 2:return o=t.sent(),h.sharedClientState.addPendingMutation(o.batchId),e=h,i=o.batchId,n=f,r=(r=(r=e.xo[e.currentUser.toKey()])||new Oo(Kn)).insert(i,n),e.xo[e.currentUser.toKey()]=r,[4,Rd(h,o.changes)];case 3:return t.sent(),[4,Hh(h.remoteStore)];case 4:return t.sent(),[3,6];case 5:return h=Xh(h=t.sent(),"Failed to persist write"),f.reject(h),[3,6];case 6:return[2]}var e,i,n,r,a,l,u,c,s})})}function kd(s,o){return g(this,void 0,void 0,function(){var i,r;return m(this,function(t){switch(t.label){case 0:i=s,t.label=1;case 1:return t.trys.push([1,4,,6]),[4,(e=i.localStore,n=o,l=e,u=n.snapshotVersion,c=l.kn,l.persistence.runTransaction("Apply remote event","readwrite-primary",function(o){var t=l.On.newChangeBuffer({trackRemovals:!0});c=l.kn;var a=[];n.targetChanges.forEach(function(t,e){var i,n,r,s=c.get(e);s&&(a.push(l.qe.removeMatchingKeys(o,t.removedDocuments,e).next(function(){return l.qe.addMatchingKeys(o,t.addedDocuments,e)})),0<(r=t.resumeToken).approximateByteSize()&&(i=s.withResumeToken(r,u).withSequenceNumber(o.currentSequenceNumber),c=c.insert(e,i),n=s,r=t,Vn(0<(s=i).resumeToken.approximateByteSize()),(0===n.resumeToken.approximateByteSize()||3e8<=s.snapshotVersion.toMicroseconds()-n.snapshotVersion.toMicroseconds()||0<r.addedDocuments.size+r.modifiedDocuments.size+r.removedDocuments.size)&&a.push(l.qe.updateTargetData(o,i))))});var e,i=qo;return n.documentUpdates.forEach(function(t,e){n.resolvedLimboDocuments.has(t)&&a.push(l.persistence.referenceDelegate.updateLimboDocument(o,t))}),a.push(lc(o,t,n.documentUpdates,u,void 0).next(function(t){i=t})),u.isEqual(Qn.min())||(e=l.qe.getLastRemoteSnapshotVersion(o).next(function(t){return l.qe.setTargetsMetadata(o,o.currentSequenceNumber,u)}),a.push(e)),ol.waitFor(a).next(function(){return t.apply(o)}).next(function(){return l.Mn.En(o,i)}).next(function(){return i})}).then(function(t){return l.kn=c,t}))];
1case 2:return r=t.sent(),o.targetChanges.forEach(function(t,e){(e=i.Co.get(e))&&(Vn(t.addedDocuments.size+t.modifiedDocuments.size+t.removedDocuments.size<=1),0<t.addedDocuments.size?e.bo=!0:0<t.modifiedDocuments.size?Vn(e.bo):0<t.removedDocuments.size&&(Vn(e.bo),e.bo=!1))}),[4,Rd(i,r,o)];case 3:return t.sent(),[3,6];case 4:return[4,bu(t.sent())];case 5:return t.sent(),[3,6];case 6:return[2]}var e,n,l,u,c})})}function Id(t,i,e){var n;((t=t).isPrimaryClient&&0===e||!t.isPrimaryClient&&1===e)&&(n=[],t.Po.forEach(function(t,e){(e=e.view.zr(i)).snapshot&&n.push(e.snapshot)}),function(t,r){t.onlineState=r;var s=!1;t.queries.forEach(function(t,e){for(var i=0,n=e.listeners;i<n.length;i++)n[i].zr(r)&&(s=!0)}),s&&ad(t)}(t.eventManager,i),n.length&&t.vo._r(n),t.onlineState=i,t.isPrimaryClient&&t.sharedClientState.setOnlineState(i))}function Dd(s,o){return g(this,void 0,void 0,function(){var i,n,r;return m(this,function(t){switch(t.label){case 0:zh((i=s).remoteStore)||Bn("SyncEngine","The network is disabled. The task returned by 'awaitPendingWrites()' will not complete until the network is enabled."),t.label=1;case 1:return t.trys.push([1,3,,4]),[4,(e=i.localStore).persistence.runTransaction("Get highest unacknowledged batch id","readonly",function(t){return e._n.getHighestUnacknowledgedBatchId(t)})];case 2:return-1===(n=t.sent())?[2,void o.resolve()]:((r=i.ko.get(n)||[]).push(o),i.ko.set(n,r),[3,4]);case 3:return r=Xh(r=t.sent(),"Initialization of waitForPendingWrites() operation failed"),o.reject(r),[3,4];case 4:return[2]}var e})})}function Ad(t,e){(t.ko.get(e)||[]).forEach(function(t){t.resolve()}),t.ko.delete(e)}function Pd(t,e,i){var n=t,r=n.xo[n.currentUser.toKey()];r&&((t=r.get(e))&&(i?t.reject(i):t.resolve(),r=r.remove(e)),n.xo[n.currentUser.toKey()]=r)}function Md(e,t,i){void 0===i&&(i=null),e.sharedClientState.removeLocalQueryTarget(t);for(var n=0,r=e.Vo.get(t);n<r.length;n++){var s=r[n];e.Po.delete(s),i&&e.vo.Mo(s,i)}e.Vo.delete(t),e.isPrimaryClient&&e.No.Zn(t).forEach(function(t){e.No.containsKey(t)||Nd(e,t)})}function Nd(t,e){t.So.delete(e.path.canonicalString());var i=t.Do.get(e);null!==i&&(Nh(t.remoteStore,i),t.Do=t.Do.remove(e),t.Co.delete(i),Ld(t))}function Od(t,e,i){for(var n,r,s,o=0,a=i;o<a.length;o++){var l=a[o];l instanceof vd?(t.No.addReference(l.key,e),n=t,s=void 0,r=(s=(r=l).key).path.canonicalString(),n.Do.get(s)||n.So.has(r)||(Bn("SyncEngine","New document in limbo: "+s),n.So.add(r),Ld(n))):l instanceof yd?(Bn("SyncEngine","Document no longer in limbo: "+l.key),t.No.removeReference(l.key,e),t.No.containsKey(l.key)||Nd(t,l.key)):qn()}}function Ld(t){for(;0<t.So.size&&t.Do.size<t.maxConcurrentLimboResolutions;){var e=t.So.values().next().value;t.So.delete(e);var i=new Sr(sr.fromString(e));e=t.Fo.next();t.Co.set(e,new _d(i)),t.Do=t.Do.insert(i,e),Mh(t.remoteStore,new Dl(Ns(Es(i.path)),e,2,Pn.o))}}function Rd(e,o,a){return g(this,void 0,void 0,function(){var i,n,r,s;return m(this,function(t){switch(t.label){case 0:return n=[],r=[],s=[],(i=e).Po.isEmpty()?[3,3]:(i.Po.forEach(function(t,e){s.push(i.Oo(e,o,a).then(function(t){t&&(i.isPrimaryClient&&i.sharedClientState.updateQueryState(e.targetId,t.fromCache?"not-current":"current"),n.push(t),t=Ju.Pn(e.targetId,t),r.push(t))}))}),[4,Promise.all(s)]);case 1:return t.sent(),i.vo._r(n),[4,function(l,u){return g(this,void 0,void 0,function(){var n,e,i,r,s,o,a;return m(this,function(t){switch(t.label){case 0:n=l,t.label=1;case 1:return t.trys.push([1,3,,4]),[4,n.persistence.runTransaction("notifyLocalViewChanges","readwrite",function(i){return ol.forEach(u,function(e){return ol.forEach(e.bn,function(t){return n.persistence.referenceDelegate.addReference(i,e.targetId,t)}).next(function(){return ol.forEach(e.vn,function(t){return n.persistence.referenceDelegate.removeReference(i,e.targetId,t)})})})})];case 2:return t.sent(),[3,4];case 3:if(!vl(e=t.sent()))throw e;return Bn("LocalStore","Failed to update sequence numbers: "+e),[3,4];case 4:for(i=0,r=u;i<r.length;i++)a=r[i],s=a.targetId,a.fromCache||(o=n.kn.get(s),a=o.snapshotVersion,a=o.withLastLimboFreeSnapshotVersion(a),n.kn=n.kn.insert(s,a));return[2]}})})}(i.localStore,r)];case 2:t.sent(),t.label=3;case 3:return[2]}})})}function Fd(p,f){return g(this,void 0,void 0,function(){var e,i,n,r,s,o,a,l,u,c,h,d;return m(this,function(t){switch(t.label){case 0:e=p,i=[],n=[],r=0,s=f,t.label=1;case 1:return r<s.length?(o=s[r],a=void 0,(l=e.Vo.get(o))&&0!==l.length?[4,uc(e.localStore,Ns(l[0]))]:[3,7]):[3,13];case 2:a=t.sent(),u=0,c=l,t.label=3;case 3:return u<c.length?(h=c[u],h=e.Po.get(h),[4,function(n,r){return g(this,void 0,void 0,function(){var e,i;return m(this,function(t){switch(t.label){case 0:return[4,hc((e=n).localStore,r.query,!0)];case 1:return i=t.sent(),i=r.view.Ao(i),[2,(e.isPrimaryClient&&Od(e,r.targetId,i.To),i)]}})})}(e,h)]):[3,6];case 4:(h=t.sent()).snapshot&&n.push(h.snapshot),t.label=5;case 5:return u++,[3,3];case 6:return[3,11];case 7:return[4,dc(e.localStore,o)];case 8:return d=t.sent(),[4,uc(e.localStore,d)];case 9:return a=t.sent(),[4,Cd(e,zd(d),o,!1)];case 10:t.sent(),t.label=11;case 11:i.push(a),t.label=12;case 12:return r++,[3,1];case 13:return[2,(e.vo._r(n),i)]}})})}function zd(t){return Cs(t.path,t.collectionGroup,t.orderBy,t.filters,t.limit,"F",t.startAt,t.endAt)}function Bd(t){return t.remoteStore.remoteSyncer.applyRemoteEvent=kd.bind(null,t),t.remoteStore.remoteSyncer.getRemoteKeysForTarget=function(t,e){var i=t;if((t=i.Co.get(e))&&t.bo)return Yo().add(t.key);var n=Yo();if(!(e=i.Vo.get(e)))return n;for(var r=0,s=e;r<s.length;r++){var o=s[r];
1o=i.Po.get(o),n=n.unionWith(o.view.wo)}return n}.bind(null,t),t.remoteStore.remoteSyncer.rejectListen=function(s,o,a){return g(this,void 0,void 0,function(){var e,i,n,r;return m(this,function(t){switch(t.label){case 0:return(e=s).sharedClientState.updateQueryState(o,"rejected",a),r=e.Co.get(o),(i=r&&r.key)?(n=(n=new Oo(Sr.comparator)).insert(i,jr.newNoDocument(i,Qn.min())),r=Yo().add(i),r=new Qo(Qn.min(),new Map,new jo(Kn),n,r),[4,kd(e,r)]):[3,2];case 1:return t.sent(),e.Do=e.Do.remove(i),e.Co.delete(o),Ld(e),[3,4];case 2:return[4,cc(e.localStore,o,!1).then(function(){return Md(e,o,a)}).catch(bu)];case 3:t.sent(),t.label=4;case 4:return[2]}})})}.bind(null,t),t.vo._r=function(t,e){for(var i=t,n=!1,r=0,s=e;r<s.length;r++){var o=s[r],a=o.query;if(a=i.queries.get(a)){for(var l=0,u=a.listeners;l<u.length;l++)u[l].Hr(o)&&(n=!0);a.Wr=o}}n&&ad(i)}.bind(null,t.eventManager),t.vo.Mo=function(t,e,i){var n=t;if(t=n.queries.get(e))for(var r=0,s=t.listeners;r<s.length;r++)s[r].onError(i);n.queries.delete(e)}.bind(null,t.eventManager),t}function $d(t){return t.remoteStore.remoteSyncer.applySuccessfulWrite=function(s,o){return g(this,void 0,void 0,function(){var i,n,r;return m(this,function(t){switch(t.label){case 0:i=s,n=o.batch.batchId,t.label=1;case 1:return t.trys.push([1,4,,6]),[4,(e=i.localStore,c=o,h=e,h.persistence.runTransaction("Acknowledge batch","readwrite-primary",function(t){var e,n,r,s,o,i,a,l=c.batch.keys(),u=h.On.newChangeBuffer({trackRemovals:!0});return e=h,n=t,s=u,i=(o=(r=c).batch).keys(),a=ol.resolve(),i.forEach(function(i){a=a.next(function(){return s.getEntry(n,i)}).next(function(t){var e=r.docVersions.get(i);Vn(null!==e),t.version.compareTo(e)<0&&(o.applyToRemoteDocument(t,r),t.isValidDocument()&&s.addEntry(t,r.commitVersion))})}),a.next(function(){return e._n.removeMutationBatch(n,o)}).next(function(){return u.apply(t)}).next(function(){return h._n.performConsistencyCheck(t)}).next(function(){return h.Mn.pn(t,l)})}))];case 2:return r=t.sent(),Pd(i,n,null),Ad(i,n),i.sharedClientState.updateMutationState(n,"acknowledged"),[4,Rd(i,r)];case 3:return t.sent(),[3,6];case 4:return[4,bu(t.sent())];case 5:return t.sent(),[3,6];case 6:return[2]}var e,c,h})})}.bind(null,t),t.remoteStore.remoteSyncer.rejectFailedWrite=function(o,a,l){return g(this,void 0,void 0,function(){var i,s;return m(this,function(t){switch(t.label){case 0:i=o,t.label=1;case 1:return t.trys.push([1,4,,6]),[4,(e=i.localStore,n=a,(r=e).persistence.runTransaction("Reject batch","readwrite-primary",function(e){var i;return r._n.lookupMutationBatch(e,n).next(function(t){return Vn(null!==t),i=t.keys(),r._n.removeMutationBatch(e,t)}).next(function(){return r._n.performConsistencyCheck(e)}).next(function(){return r.Mn.pn(e,i)})}))];case 2:return s=t.sent(),Pd(i,a,l),Ad(i,a),i.sharedClientState.updateMutationState(a,"rejected",l),[4,Rd(i,s)];case 3:return t.sent(),[3,6];case 4:return[4,bu(t.sent())];case 5:return t.sent(),[3,6];case 6:return[2]}var e,n,r})})}.bind(null,t),t}function jd(t,e,i){var n=t;(function(d,p,f){return g(this,void 0,void 0,function(){var a,l,u,c,h;return m(this,function(t){switch(t.label){case 0:return t.trys.push([0,14,,15]),[4,p.getMetadata()];case 1:return a=t.sent(),[4,(n=d.localStore,s=n,o=ga((r=a).createTime),s.persistence.runTransaction("hasNewerBundle","readonly",function(t){return s.Ke.getBundleMetadata(t,r.id)}).then(function(t){return!!t&&0<=t.createTime.compareTo(o)}))];case 2:return t.sent()?[4,p.close()]:[3,4];case 3:return[2,(t.sent(),void f._completeWith({taskState:"Success",documentsLoaded:a.totalDocuments,bytesLoaded:a.totalBytes,totalDocuments:a.totalDocuments,totalBytes:a.totalBytes}))];case 4:return f._updateProgress(md(a)),l=new hd(a,d.localStore,p.R),[4,p.Lo()];case 5:u=t.sent(),t.label=6;case 6:return u?[4,l.oo(u)]:[3,10];case 7:return(c=t.sent())&&f._updateProgress(c),[4,p.Lo()];case 8:u=t.sent(),t.label=9;case 9:return[3,6];case 10:return[4,l.complete()];case 11:return h=t.sent(),[4,Rd(d,h.wn,void 0)];case 12:return t.sent(),[4,(n=d.localStore,e=a,(i=n).persistence.runTransaction("Save bundle","readwrite",function(t){return i.Ke.saveBundleMetadata(t,e)}))];case 13:return t.sent(),f._completeWith(h.progress),[3,15];case 14:return jn("SyncEngine","Loading bundle failed with "+(h=t.sent())),f._failWith(h),[3,15];case 15:return[2]}var e,i,n,r,s,o})})}
1)(n,e,i).then(function(){n.sharedClientState.notifyBundleLoaded()})}var Hd,qd,Vd=(Qd.prototype.initialize=function(e){return g(this,void 0,void 0,function(){return m(this,function(t){switch(t.label){case 0:return this.R=fh(e.databaseInfo.databaseId),this.sharedClientState=this.Bo(e),this.persistence=this.qo(e),[4,this.persistence.start()];case 1:return t.sent(),this.gcScheduler=this.Uo(e),this.localStore=this.Ko(e),[2]}})})},Qd.prototype.Uo=function(t){return null},Qd.prototype.Ko=function(t){return sc(this.persistence,new Zu,t.initialUser,this.R)},Qd.prototype.qo=function(t){return new Tc(Cc.bs,this.R)},Qd.prototype.Bo=function(t){return new Gc},Qd.prototype.terminate=function(){return g(this,void 0,void 0,function(){return m(this,function(t){switch(t.label){case 0:return this.gcScheduler&&this.gcScheduler.stop(),[4,this.sharedClientState.shutdown()];case 1:return t.sent(),[4,this.persistence.shutdown()];case 2:return t.sent(),[2]}})})},Qd),Ud=(i(Xd,qd=Vd),Xd.prototype.initialize=function(i){return g(this,void 0,void 0,function(){var e=this;return m(this,function(t){switch(t.label){case 0:return[4,qd.prototype.initialize.call(this,i)];case 1:return t.sent(),[4,function(i){return g(this,void 0,void 0,function(){var e;return m(this,function(t){return[2,(e=i).persistence.runTransaction("Synchronize last document change read time","readonly",function(t){return t=Bu(t),n=Qn.min(),t.$t({index:Ka.readTimeIndex,reverse:!0},function(t,e,i){e.readTime&&(n=Fl(e.readTime)),i.done()}).next(function(){return n});var n}).then(function(t){e.$n=t})]})})}(this.localStore)];case 2:return t.sent(),[4,this.Qo.initialize(this,i)];case 3:return t.sent(),[4,$d(this.Qo.syncEngine)];case 4:return t.sent(),[4,Hh(this.Qo.remoteStore)];case 5:return t.sent(),[4,this.persistence.He(function(){return e.gcScheduler&&!e.gcScheduler.started&&e.gcScheduler.start(e.localStore),Promise.resolve()})];case 6:return t.sent(),[2]}})})},Xd.prototype.Ko=function(t){return sc(this.persistence,new Zu,t.initialUser,this.R)},Xd.prototype.Uo=function(t){var e=this.persistence.referenceDelegate.garbageCollector;return new xu(e,t.asyncQueue)},Xd.prototype.qo=function(t){var e=Yu(t.databaseInfo.databaseId,t.databaseInfo.persistenceKey),i=void 0!==this.cacheSizeBytes?iu.withCacheSize(this.cacheSizeBytes):iu.DEFAULT;return new Uu(this.synchronizeTabs,e,t.clientId,i,t.asyncQueue,dh(),ph(),this.R,this.sharedClientState,!!this.forceOwnership)},Xd.prototype.Bo=function(t){return new Gc},Xd),Wd=(i(Yd,Hd=Ud),Yd.prototype.initialize=function(n){return g(this,void 0,void 0,function(){var e,i=this;return m(this,function(t){switch(t.label){case 0:return[4,Hd.prototype.initialize.call(this,n)];case 1:return t.sent(),e=this.Qo.syncEngine,this.sharedClientState instanceof Kc?(this.sharedClientState.syncEngine={ui:function(a,l,u,c){return g(this,void 0,void 0,function(){var s,o;return m(this,function(t){switch(t.label){case 0:return[4,(e=(s=a).localStore,i=l,r=(n=e)._n,n.persistence.runTransaction("Lookup mutation documents","readonly",function(e){return r.jt(e,i).next(function(t){return t?n.Mn.pn(e,t):ol.resolve(null)})}))];case 1:return null===(o=t.sent())?[3,6]:"pending"!==u?[3,3]:[4,Hh(s.remoteStore)];case 2:return t.sent(),[3,4];case 3:"acknowledged"===u||"rejected"===u?(Pd(s,l,c||null),Ad(s,l),s.localStore._n.Gt(l)):qn(),t.label=4;case 4:return[4,Rd(s,o)];case 5:return t.sent(),[3,7];case 6:Bn("SyncEngine","Cannot apply mutation batch with id: "+l),t.label=7;case 7:return[2]}var e,i,n,r})})}.bind(null,e),ai:function(r,s,o,a){return g(this,void 0,void 0,function(){var e,i,n;return m(this,function(t){switch(t.label){case 0:return(e=r).$o?(Bn("SyncEngine","Ignoring unexpected query state notification."),[3,8]):[3,1];case 1:if(!e.Vo.has(s))return[3,8];switch(o){case"current":case"not-current":return[3,2];case"rejected":return[3,5]}return[3,7];case 2:return[4,pc(e.localStore)];case 3:return i=t.sent(),n=Qo.createSynthesizedRemoteEventForCurrentChange(s,"current"===o),[4,Rd(e,i,n)];case 4:return t.sent(),[3,8];case 5:return[4,cc(e.localStore,s,!0)];case 6:return t.sent(),Md(e,s,a),[3,8];case 7:qn(),t.label=8;case 8:return[2]}})})}.bind(null,e),hi:function(u,c,h){return g(this,void 0,void 0,function(){var i,e,n,r,s,o,a,l;return m(this,function(t){switch(t.label){case 0:if(!(i=Bd(u)).$o)return[3,10];e=0,n=c,t.label=1;case 1:return e<n.length?(n=n[e],i.Vo.has(n)?(Bn("SyncEngine","Adding an already active target "+n),[3,5]):[4,dc(i.localStore,n)]):[3,6];case 2:return r=t.sent(),[4,uc(i.localStore,r)];case 3:return s=t.sent(),[4,Cd(i,zd(r),s.targetId,!1)];case 4:t.sent(),Mh(i.remoteStore,s),t.label=5;case 5:return e++,[3,1];case 6:o=function(e){return m(this,function(t){switch(t.label){case 0:return i.Vo.has(e)?[4,cc(i.localStore,e,!1).then(function(){Nh(i.remoteStore,e),Md(i,e)}
1).catch(bu)]:[3,2];case 1:t.sent(),t.label=2;case 2:return[2]}})},a=0,l=h,t.label=7;case 7:return a<l.length?(l=l[a],[5,o(l)]):[3,10];case 8:t.sent(),t.label=9;case 9:return a++,[3,7];case 10:return[2]}})})}.bind(null,e),fn:function(t){return t.localStore.persistence.fn()}.bind(null,e),ci:function(i){return g(this,void 0,void 0,function(){var e;return m(this,function(t){return[2,pc((e=i).localStore).then(function(t){return Rd(e,t)})]})})}.bind(null,e)},[4,this.sharedClientState.start()]):[3,3];case 2:t.sent(),t.label=3;case 3:return[4,this.persistence.He(function(e){return g(i,void 0,void 0,function(){return m(this,function(t){switch(t.label){case 0:return[4,function(c,h){return g(this,void 0,void 0,function(){var n,e,r,s,o,a,l,u;return m(this,function(t){switch(t.label){case 0:return Bd(n=c),$d(n),!0!==h||!0===n.$o?[3,3]:(e=n.sharedClientState.getAllActiveQueryTargets(),[4,Fd(n,e.toArray())]);case 1:return r=t.sent(),n.$o=!0,[4,Uh(n.remoteStore,!0)];case 2:for(t.sent(),s=0,o=r;s<o.length;s++)a=o[s],Mh(n.remoteStore,a);return[3,7];case 3:return!1!==h||!1===n.$o?[3,7]:(l=[],u=Promise.resolve(),n.Vo.forEach(function(t,e){n.sharedClientState.isLocalQueryTarget(e)?l.push(e):u=u.then(function(){return Md(n,e),cc(n.localStore,e,!0)}),Nh(n.remoteStore,e)}),[4,u]);case 4:return t.sent(),[4,Fd(n,l)];case 5:return t.sent(),(i=n).Co.forEach(function(t,e){Nh(i.remoteStore,e)}),i.No.ts(),i.Co=new Map,i.Do=new Oo(Sr.comparator),n.$o=!1,[4,Uh(n.remoteStore,!1)];case 6:t.sent(),t.label=7;case 7:return[2]}var i})})}(this.Qo.syncEngine,e)];case 1:return t.sent(),this.gcScheduler&&(e&&!this.gcScheduler.started?this.gcScheduler.start(this.localStore):e||this.gcScheduler.stop()),[2]}})})})];case 4:return t.sent(),[2]}})})},Yd.prototype.Bo=function(t){var e=dh();if(!Kc.yt(e))throw new Ln(On.UNIMPLEMENTED,"IndexedDB persistence is only available on platforms that support LocalStorage.");var i=Yu(t.databaseInfo.databaseId,t.databaseInfo.persistenceKey);return new Kc(e,t.asyncQueue,i,t.clientId,t.initialUser)},Yd),Kd=(Gd.prototype.initialize=function(i,n){return g(this,void 0,void 0,function(){var e=this;return m(this,function(t){switch(t.label){case 0:return this.localStore?[3,2]:(this.localStore=i.localStore,this.sharedClientState=i.sharedClientState,this.datastore=this.createDatastore(n),this.remoteStore=this.createRemoteStore(n),this.eventManager=this.createEventManager(n),this.syncEngine=this.createSyncEngine(n,!i.synchronizeTabs),this.sharedClientState.onlineStateHandler=function(t){return Id(e.syncEngine,t,1)},this.remoteStore.remoteSyncer.handleCredentialChange=function(r,s){return g(this,void 0,void 0,function(){var i,n;return m(this,function(t){switch(t.label){case 0:return(i=r).currentUser.isEqual(s)?[3,3]:(Bn("SyncEngine","User change. New user:",s.toKey()),[4,oc(i.localStore,s)]);case 1:return n=t.sent(),i.currentUser=s,(e=i).ko.forEach(function(t){t.forEach(function(t){t.reject(new Ln(On.CANCELLED,"'waitForPendingWrites' promise is rejected due to a user change."))})}),e.ko.clear(),i.sharedClientState.handleUserChange(s,n.removedBatchIds,n.addedBatchIds),[4,Rd(i,n.Ln)];case 2:t.sent(),t.label=3;case 3:return[2]}var e})})}.bind(null,this.syncEngine),[4,Uh(this.remoteStore,this.syncEngine.isPrimaryClient)]);case 1:t.sent(),t.label=2;case 2:return[2]}})})},Gd.prototype.createEventManager=function(t){return new Qh},Gd.prototype.createDatastore=function(t){var e=fh(t.databaseInfo.databaseId),i=(i=t.databaseInfo,new Zc(i));return t=t.credentials,new xh(t,i,e)},Gd.prototype.createRemoteStore=function(t){var e=this;return new gh(this.localStore,this.datastore,t.asyncQueue,function(t){return Id(e.syncEngine,t,0)},t=new(Xc.yt()?Xc:Yc))},Gd.prototype.createSyncEngine=function(t,e){return i=this.localStore,n=this.remoteStore,r=this.eventManager,s=this.sharedClientState,o=t.initialUser,a=t.maxConcurrentLimboResolutions,l=e,a=new xd(i,n,r,s,o,a),l&&(a.$o=!0),a;var i,n,r,s,o,a,l},Gd.prototype.terminate=function(){return function(i){return g(this,void 0,void 0,function(){var e;return m(this,function(t){switch(t.label){case 0:return e=i,Bn("RemoteStore","RemoteStore shutting down."),e.Or.add(5),[4,Ph(e)];case 1:return t.sent(),e.Lr.shutdown(),e.Br.set("Unknown"),[2]}})})}(this.remoteStore)},Gd);function Gd(){}function Yd(t,e){var i=this;return(i=Hd.call(this,t,e,!1)||this).Qo=t,i.cacheSizeBytes=e,i.synchronizeTabs=!0,i}function Xd(t,e,i){var n=this;return(n=qd.call(this)||this).Qo=t,n.cacheSizeBytes=e,n.forceOwnership=i,n.synchronizeTabs=!1,n}function Qd(){this.synchronizeTabs=!1}function Jd(i,n){void 0===n&&(n=10240);var r=0;return{read:function(){return g(this,void 0,void 0,function(){var e;return m(this,function(t){return r<i.byteLength?(e={value:i.slice(r,r+n),done:!1},[2,(r+=n,e)]):[2,{done:!0}]})})},cancel:function(){return g(this,void 0,void 0,function(){return m(this,function(t){return[2]})})},releaseLock:function(){},closed:Promise.reject("unimplemented")}}var Zd=(lp.prototype.next=function(t){this.observer.next&&this.jo(this.observer.next,t)},lp.prototype.error=function(t){this.observer.error?this.jo(this.observer.error,t):console.error("Uncaught Error in snapshot listener:",t)},lp.prototype.Wo=function(){this.muted=!0}
1,lp.prototype.jo=function(t,e){var i=this;this.muted||setTimeout(function(){i.muted||t(e)},0)},lp),tp=(ap.prototype.close=function(){return this.Go.cancel()},ap.prototype.getMetadata=function(){return g(this,void 0,void 0,function(){return m(this,function(t){return[2,this.metadata.promise]})})},ap.prototype.Lo=function(){return g(this,void 0,void 0,function(){return m(this,function(t){switch(t.label){case 0:return[4,this.getMetadata()];case 1:return[2,(t.sent(),this.Ho())]}})})},ap.prototype.Ho=function(){return g(this,void 0,void 0,function(){var e,i,n;return m(this,function(t){switch(t.label){case 0:return[4,this.Jo()];case 1:return null===(e=t.sent())?[2,null]:(n=this.zo.decode(e),i=Number(n),isNaN(i)&&this.Yo("length string ("+n+") is not valid number"),[4,this.Xo(i)]);case 2:return n=t.sent(),[2,new ud(JSON.parse(n),e.length+i)]}})})},ap.prototype.Zo=function(){return this.buffer.findIndex(function(t){return t==="{".charCodeAt(0)})},ap.prototype.Jo=function(){return g(this,void 0,void 0,function(){var e,i;return m(this,function(t){switch(t.label){case 0:return this.Zo()<0?[4,this.tc()]:[3,3];case 1:if(t.sent())return[3,3];t.label=2;case 2:return[3,0];case 3:return 0===this.buffer.length?[2,null]:((e=this.Zo())<0&&this.Yo("Reached the end of bundle when a length string is expected."),i=this.buffer.slice(0,e),[2,(this.buffer=this.buffer.slice(e),i)])}})})},ap.prototype.Xo=function(i){return g(this,void 0,void 0,function(){var e;return m(this,function(t){switch(t.label){case 0:return this.buffer.length<i?[4,this.tc()]:[3,3];case 1:t.sent()&&this.Yo("Reached the end of bundle when more is expected."),t.label=2;case 2:return[3,0];case 3:return e=this.zo.decode(this.buffer.slice(0,i)),[2,(this.buffer=this.buffer.slice(i),e)]}})})},ap.prototype.Yo=function(t){throw this.Go.cancel(),new Error("Invalid bundle format: "+t)},ap.prototype.tc=function(){return g(this,void 0,void 0,function(){var e,i;return m(this,function(t){switch(t.label){case 0:return[4,this.Go.read()];case 1:return(e=t.sent()).done||((i=new Uint8Array(this.buffer.length+e.value.length)).set(this.buffer),i.set(e.value,this.buffer.length),this.buffer=i),[2,e.done]}})})},ap),ep=(op.prototype.lookup=function(n){return g(this,void 0,void 0,function(){var e,i=this;return m(this,function(t){switch(t.label){case 0:if(this.ensureCommitNotCalled(),0<this.mutations.length)throw new Ln(On.INVALID_ARGUMENT,"Firestore transactions require all reads to be executed before all writes.");return[4,function(o,a){return g(this,void 0,void 0,function(){var r,e,i,s,n;return m(this,function(t){switch(t.label){case 0:return e=xa((r=o).R)+"/documents",i={documents:a.map(function(t){return ya(r.R,t)})},[4,r.$i("BatchGetDocuments",e,i)];case 1:return i=t.sent(),s=new Map,i.forEach(function(t){var e,i,n;e=r.R,t="found"in(t=t)?function(t,e){Vn(!!e.found),e.found.name,e.found.updateTime;var i=ba(t,e.found.name);t=ga(e.found.updateTime),e=new Br({mapValue:{fields:e.found.fields}});return jr.newFoundDocument(i,t,e)}(e,t):"missing"in t?(i=e,Vn(!!(n=t).missing),Vn(!!n.readTime),i=ba(i,n.missing),n=ga(n.readTime),jr.newNoDocument(i,n)):qn();s.set(t.key.toString(),t)}),n=[],[2,(a.forEach(function(t){Vn(!!(t=s.get(t.toString()))),n.push(t)}),n)]}})})}(this.datastore,n)];case 1:return[2,((e=t.sent()).forEach(function(t){return i.recordVersion(t)}),e)]}})})},op.prototype.set=function(t,e){this.write(e.toMutation(t,this.precondition(t))),this.writtenDocs.add(t.toString())},op.prototype.update=function(t,e){try{this.write(e.toMutation(t,this.preconditionForUpdate(t)))}catch(t){this.lastWriteError=t}this.writtenDocs.add(t.toString())},op.prototype.delete=function(t){this.write(new Io(t,this.precondition(t))),this.writtenDocs.add(t.toString())},op.prototype.commit=function(){return g(this,void 0,void 0,function(){var e,i=this;return m(this,function(t){switch(t.label){case 0:if(this.ensureCommitNotCalled(),this.lastWriteError)throw this.lastWriteError;return e=this.readVersions,this.mutations.forEach(function(t){e.delete(t.key.toString())}),e.forEach(function(t,e){e=Sr.fromPath(e),i.mutations.push(new Do(e,i.precondition(e)))}),[4,function(r,s){return g(this,void 0,void 0,function(){var e,i,n;return m(this,function(t){switch(t.label){case 0:return i=xa((e=r).R)+"/documents",n={writes:s.map(function(t){return Ea(e.R,t)})},[4,e.Ni("Commit",i,n)];case 1:return t.sent(),[2]}})})}(this.datastore,this.mutations)];case 1:return t.sent(),this.committed=!0,[2]}})})},op.prototype.recordVersion=function(t){var e;if(t.isFoundDocument())e=t.version;else{if(!t.isNoDocument())throw qn();e=Qn.min()}var i=this.readVersions.get(t.key.toString());if(i){if(!e.isEqual(i))throw new Ln(On.ABORTED,"Document version changed between two reads.")}else this.readVersions.set(t.key.toString(),e)},op.prototype.precondition=function(t){var e=this.readVersions.get(t.toString());return!this.writtenDocs.has(t.toString())&&e?lo.updateTime(e):lo.none()},op.prototype.preconditionForUpdate=function(t){var e=this.readVersions.get(t.toString());if(this.writtenDocs.has(t.toString())||!e)return lo.exists(!0);if(e.isEqual(Qn.min()))throw new Ln(On.INVALID_ARGUMENT,"Can't update a document that doesn't exist.");return lo.updateTime(e)},op.prototype.write=function(t){this.ensureCommitNotCalled(),this.mutations.push(t)},op.prototype.ensureCommitNotCalled=function(){},op),ip=(sp.prototype.run=function(){--this.ec,this.nc()},sp.prototype.nc=function(){var t=this;this.Zi.ji(function(){return g(t,void 0,void 0,function(){var e,i,n=this;return m(this,function(t){return e=new ep(this.datastore),(i=this.sc(e))&&i.then(function(t){n.asyncQueue.enqueueAndForget(function(){return e.commit().then(function(){n.deferred.resolve(t)}).catch(function(t){n.ic(t)})})}).catch(function(t){n.ic(t)}),[2]})})})},sp.prototype.sc=function(t){try{var e=this.updateFunction(t);return!_r(e)&&e.catch&&e.then?e:(this.deferred.reject(Error("Transaction callback must return a Promise")),null)}catch(t){return this.deferred.reject(t),null}},sp.prototype.ic=function(t){var e=this;0<this.ec&&this.rc(t)?(--this.ec,this.asyncQueue.enqueueAndForget(function(){return e.nc(),Promise.resolve()})):this.deferred.reject(t)},sp.prototype.rc=function(t){return"FirebaseError"===t.name&&("aborted"===(t=t.code)||"failed-precondition"===t||!Mo(t))},sp),np=(rp.prototype.getConfiguration=function(){return g(this,void 0,void 0,function(){return m(this,function(t){return[2,{asyncQueue:this.asyncQueue,databaseInfo:this.databaseInfo,clientId:this.clientId,credentials:this.credentials,initialUser:this.user,maxConcurrentLimboResolutions:100}]})})},rp.prototype.setCredentialChangeListener=function(t){this.credentialListener=t},rp.prototype.verifyNotTerminated=function(){if(this.asyncQueue.isShuttingDown)throw new Ln(On.FAILED_PRECONDITION,"The client has already been terminated.")},rp.prototype.terminate=function(){var t=this;this.asyncQueue.enterRestrictedMode();var i=new sl;return this.asyncQueue.enqueueAndForgetEvenWhileRestricted(function(){return g(t,void 0,void 0,function(){var e;return m(this,function(t){switch(t.label){case 0:return t.trys.push([0,5,,6]),this.onlineComponents?[4,this.onlineComponents.terminate()]:[3,2];case 1:t.sent(),t.label=2;case 2:return this.offlineComponents?[4,this.offlineComponents.terminate()]:[3,4];case 3:t.sent(),t.label=4;case 4:return this.credentials.removeChangeListener(),i.resolve(),[3,6];case 5:return e=Xh(e=t.sent(),"Failed to shutdown persistence"),i.reject(e),[3,6];case 6:return[2]}})})}),i.promise},rp);function rp(t,e,i){var n=this;this.credentials=t,this.asyncQueue=e,this.databaseInfo=i,this.user=Ec.UNAUTHENTICATED,this.clientId=Un.u(),this.credentialListener=function(){return Promise.resolve()},this.credentials.setChangeListener(e,function(e){return g(n,void 0,void 0,function(){return m(this,function(t){switch(t.label){case 0:return Bn("FirestoreClient","Received user=",e.uid),[4,this.credentialListener(e)];case 1:return t.sent(),this.user=e,[2]}})})})}function sp(t,e,i,n){this.asyncQueue=t,this.datastore=e,this.updateFunction=i,this.deferred=n,this.ec=5,this.Zi=new bh(this.asyncQueue,"transaction_retry")}function op(t){this.datastore=t,this.readVersions=new Map,this.mutations=[],this.committed=!1,this.lastWriteError=null,this.writtenDocs=new Set}function ap(t,e){var i=this;this.Go=t,this.R=e,this.metadata=new sl,this.buffer=new Uint8Array,this.zo=new TextDecoder("utf-8"),this.Ho().then(function(t){t&&t.io()?i.metadata.resolve(t.payload.metadata):i.metadata.reject(new Error("The first element of the bundle is not a metadata, it is\n             "+JSON.stringify(null==t?void 0:t.payload)))},function(t){return i.metadata.reject(t)})}function lp(t){this.observer=t,this.muted=!1}function up(r,s){return g(this,void 0,void 0,function(){var e,i,n=this;return m(this,function(t){switch(t.label){case 0:return r.asyncQueue.verifyOperationInProgress(),Bn("FirestoreClient","Initializing OfflineComponentProvider"),[4,r.getConfiguration()];case 1:return e=t.sent(),[4,s.initialize(e)];case 2:return t.sent(),i=e.initialUser,r.setCredentialChangeListener(function(e){return g(n,void 0,void 0,function(){return m(this,function(t){switch(t.label){case 0:return i.isEqual(e)?[3,2]:[4,oc(s.localStore,e)];case 1:t.sent(),i=e,t.label=2;case 2:return[2]}})})}),s.persistence.setDatabaseDeletedListener(function(){return r.terminate()}),r.offlineComponents=s,[2]}})})}function cp(n,r){return g(this,void 0,void 0,function(){var e,i;return m(this,function(t){switch(t.label){case 0:return n.asyncQueue.verifyOperationInProgress(),[4,hp(n)];case 1:return e=t.sent(),Bn("FirestoreClient","Initializing OnlineComponentProvider"),[4,n.getConfiguration()];case 2:return i=t.sent(),[4,r.initialize(e,i)];case 3:return t.sent(),n.setCredentialChangeListener(function(t){return function(n,r){return g(this,void 0,void 0,function(){var e,i;return m(this,function(t){switch(t.label){case 0:return(e=n).asyncQueue.verifyOperationInProgress(),Bn("RemoteStore","RemoteStore received new credentials"),i=zh(e),e.Or.add(3),[4,Ph(e)];case 1:return t.sent(),i&&e.Br.set("Unknown"),[4,e.remoteSyncer.handleCredentialChange(r)];case 2:return t.sent(),e.Or.delete(3),[4,Ah(e)];case 3:return t.sent(),[2]}})})}(r.remoteStore,t)}),n.onlineComponents=r,[2]}})})}function hp(e){return g(this,void 0,void 0,function(){return m(this,function(t){switch(t.label){case 0:return e.offlineComponents?[3,2]:(Bn("FirestoreClient","Using default OfflineComponentProvider"),[4,up(e,new Vd)]);case 1:t.sent(),t.label=2;case 2:return[2,e.offlineComponents]}})})}function dp(e){return g(this,void 0,void 0,function(){return m(this,function(t){switch(t.label){case 0:return e.onlineComponents?[3,2]:(Bn("FirestoreClient","Using default OnlineComponentProvider"),[4,cp(e,new Kd)]);case 1:t.sent(),t.label=2;case 2:return[2,e.onlineComponents]}})})}function pp(t){return hp(t).then(function(t){return t.persistence})}function fp(t){return hp(t).then(function(t){return t.localStore})}function gp(t){return dp(t).then(function(t){return t.remoteStore})}function mp(t){return dp(t).then(function(t){return t.syncEngine})}function vp(n){return g(this,void 0,void 0,function(){var e,i;return m(this,function(t){switch(t.label){case 0:return[4,dp(n)];case 1:return e=t.sent(),[2,((i=e.eventManager).onListen=function(o,a){return g(this,void 0,void 0,function(){var e,i,n,r,s;return m(this,function(t){switch(t.label){case 0:return e=Bd(o),(s=e.Po.get(a))?(i=s.targetId,e.sharedCl
1ientState.addLocalQueryTarget(i),n=s.view.Ro(),[3,4]):[3,1];case 1:return[4,uc(e.localStore,Ns(a))];case 2:return r=t.sent(),s=e.sharedClientState.addLocalQueryTarget(r.targetId),i=r.targetId,[4,Cd(e,a,i,"current"===s)];case 3:n=t.sent(),e.isPrimaryClient&&Mh(e.remoteStore,r),t.label=4;case 4:return[2,n]}})})}.bind(null,e.syncEngine),i.onUnlisten=function(r,s){return g(this,void 0,void 0,function(){var e,i,n;return m(this,function(t){switch(t.label){case 0:return i=(e=r).Po.get(s),1<(n=e.Vo.get(i.targetId)).length?[2,(e.Vo.set(i.targetId,n.filter(function(t){return!Ls(t,s)})),void e.Po.delete(s))]:e.isPrimaryClient?(e.sharedClientState.removeLocalQueryTarget(i.targetId),e.sharedClientState.isActiveQueryTarget(i.targetId)?[3,2]:[4,cc(e.localStore,i.targetId,!1).then(function(){e.sharedClientState.clearQueryState(i.targetId),Nh(e.remoteStore,i.targetId),Md(e,i.targetId)}).catch(bu)]):[3,3];case 1:t.sent(),t.label=2;case 2:return[3,5];case 3:return Md(e,i.targetId),[4,cc(e.localStore,i.targetId,!0)];case 4:t.sent(),t.label=5;case 5:return[2]}})})}.bind(null,e.syncEngine),i)]}})})}function yp(i,n,r){var t=this;void 0===r&&(r={});var s=new sl;return i.asyncQueue.enqueueAndForget(function(){return g(t,void 0,void 0,function(){var e;return m(this,function(t){switch(t.label){case 0:return e=function(i,n,r,s,o){var t=new Zd({next:function(t){n.enqueueAndForget(function(){return od(i,a)});var e=t.docs.has(r);!e&&t.fromCache?o.reject(new Ln(On.UNAVAILABLE,"Failed to get document because the client is offline.")):e&&t.fromCache&&s&&"server"===s.source?o.reject(new Ln(On.UNAVAILABLE,'Failed to get document from server. (However, this document does exist in the local cache. Run again without setting source to "server" to retrieve the cached document.)')):o.resolve(t)},error:function(t){return o.reject(t)}}),a=new ld(Es(r.path),t,{includeMetadataChanges:!0,so:!0});return sd(i,a)},[4,vp(i)];case 1:return[2,e.apply(void 0,[t.sent(),i.asyncQueue,n,r,s])]}})})}),s.promise}function bp(i,n,r){var t=this;void 0===r&&(r={});var s=new sl;return i.asyncQueue.enqueueAndForget(function(){return g(t,void 0,void 0,function(){var e;return m(this,function(t){switch(t.label){case 0:return e=function(e,i,t,n,r){var s=new Zd({next:function(t){i.enqueueAndForget(function(){return od(e,o)}),t.fromCache&&"server"===n.source?r.reject(new Ln(On.UNAVAILABLE,'Failed to get documents from server. (However, these documents may exist in the local cache. Run again without setting source to "server" to retrieve the cached documents.)')):r.resolve(t)},error:function(t){return r.reject(t)}}),o=new ld(t,s,{includeMetadataChanges:!0,so:!0});return sd(e,o)},[4,vp(i)];case 1:return[2,e.apply(void 0,[t.sent(),i.asyncQueue,n,r,s])]}})})}),s.promise}function wp(t,e){this.user=e,this.type="OAuth",this.authHeaders={},this.authHeaders.Authorization="Bearer "+t}var _p=function(t,e,i,n,r,s,o,a){this.databaseId=t,this.appId=e,this.persistenceKey=i,this.host=n,this.ssl=r,this.forceLongPolling=s,this.autoDetectLongPolling=o,this.useFetchStreams=a},xp=(Object.defineProperty(Op.prototype,"isDefaultDatabase",{get:function(){return"(default)"===this.database},enumerable:!1,configurable:!0}),Op.prototype.isEqual=function(t){return t instanceof Op&&t.projectId===this.projectId&&t.database===this.database},Op),Tp=new Map,Sp=(Np.prototype.getToken=function(){return Promise.resolve(null)},Np.prototype.invalidateToken=function(){},Np.prototype.setChangeListener=function(t,e){this.changeListener=e,t.enqueueRetryable(function(){return e(Ec.UNAUTHENTICATED)})},Np.prototype.removeChangeListener=function(){this.changeListener=null},Np),Cp=(Mp.prototype.getToken=function(){return Promise.resolve(this.token)},Mp.prototype.invalidateToken=function(){},Mp.prototype.setChangeListener=function(t,e){var i=this;this.changeListener=e,t.enqueueRetryable(function(){return e(i.token.user)})},Mp.prototype.removeChangeListener=function(){this.changeListener=null},Mp),Ep=(Pp.prototype.getToken=function(){var e=this,i=this.cc,t=this.forceRefresh;return this.forceRefresh=!1,this.auth?this.auth.getToken(t).then(function(t){return e.cc!==i?(Bn("FirebaseCredentialsProvider","getToken aborted due to token change."),e.getToken()):t?(Vn("string"==typeof t.accessToken),new wp(t.accessToken,e.currentUser)):null}):Promise.resolve(null)},Pp.prototype.invalidateToken=function(){this.forceRefresh=!0},Pp.prototype.setChangeListener=function(t,e){var i=this;this.asyncQueue=t,this.asyncQueue.enqueueRetryable(function(){return g(i,void 0,void 0,function(){return m(this,function(t){switch(t.label){case 0:return[4,this.oc.promise];case 1:return t.sent(),[4,e(this.currentUser)];case 2:return t.sent(),this.changeListener=e,[2]}})})})},Pp.prototype.removeChangeListener=function(){this.auth&&this.auth.removeAuthTokenListener(this.uc),this.changeListener=function(){return Promise.resolve()}},Pp.prototype.ac=function(){var t=this.auth&&this.auth.getUid();return Vn(null===t||"string"==typeof t),new Ec(t)},Pp),kp=(Object.defineProperty(Ap.prototype,"authHeaders",{get:function(){var t={"X-Goog-AuthUser":this.lc},e=this.hc.auth.getAuthHeaderValueForFirstParty([]);
1return e&&(t.Authorization=e),this.fc&&(t["X-Goog-Iam-Authorization-Token"]=this.fc),t},enumerable:!1,configurable:!0}),Ap),Ip=(Dp.prototype.getToken=function(){return Promise.resolve(new kp(this.hc,this.lc,this.fc))},Dp.prototype.setChangeListener=function(t,e){t.enqueueRetryable(function(){return e(Ec.FIRST_PARTY)})},Dp.prototype.removeChangeListener=function(){},Dp.prototype.invalidateToken=function(){},Dp);function Dp(t,e,i){this.hc=t,this.lc=e,this.fc=i}function Ap(t,e,i){this.hc=t,this.lc=e,this.fc=i,this.type="FirstParty",this.user=Ec.FIRST_PARTY}function Pp(e){var i=this;function n(t){Bn("FirebaseCredentialsProvider","Auth detected"),i.auth=t,i.auth.addAuthTokenListener(i.uc)}this.currentUser=Ec.UNAUTHENTICATED,this.oc=new sl,this.cc=0,this.forceRefresh=!1,this.auth=null,this.asyncQueue=null,this.uc=function(){i.cc++,i.currentUser=i.ac(),i.oc.resolve(),i.changeListener&&i.asyncQueue.enqueueRetryable(function(){return i.changeListener(i.currentUser)})},e.onInit(n),setTimeout(function(){var t;i.auth||((t=e.getImmediate({optional:!0}))?n(t):(Bn("FirebaseCredentialsProvider","Auth not yet detected"),i.oc.resolve()))},0)}function Mp(t){this.token=t,this.changeListener=null}function Np(){this.changeListener=null}function Op(t,e){this.projectId=t,this.database=e||"(default)"}function Lp(t,e,i){if(!i)throw new Ln(On.INVALID_ARGUMENT,"Function "+t+"() cannot be called with an empty "+e+".")}function Rp(t,e){if(void 0===e)return{merge:!1};if(void 0!==e.mergeFields&&void 0!==e.merge)throw new Ln(On.INVALID_ARGUMENT,"Invalid options passed to function "+t+'(): You cannot specify both "merge" and "mergeFields".');return e}function Fp(t,e,i,n){if(!0===e&&!0===n)throw new Ln(On.INVALID_ARGUMENT,t+" and "+i+" cannot be used together.")}function zp(t){if(!Sr.isDocumentKey(t))throw new Ln(On.INVALID_ARGUMENT,"Invalid document reference. Document references must have an even number of segments, but "+t+" has "+t.length+".")}function Bp(t){if(Sr.isDocumentKey(t))throw new Ln(On.INVALID_ARGUMENT,"Invalid collection reference. Collection references must have an odd number of segments, but "+t+" has "+t.length+".")}function $p(e){if(void 0===e)return"undefined";if(null===e)return"null";if("string"==typeof e)return 20<e.length&&(e=e.substring(0,20)+"..."),JSON.stringify(e);if("number"==typeof e||"boolean"==typeof e)return""+e;if("object"!=typeof e)return"function"==typeof e?"a function":qn();if(e instanceof Array)return"an array";var t=function(){if(e.constructor){var t=/function\s+([^\s(]+)\s*\(/.exec(e.constructor.toString());if(t&&1<t.length)return t[1]}return null}();return t?"a custom "+t+" object":"an object"}function jp(t,e){if((t="_delegate"in t?t._delegate:t)instanceof e)return t;if(e.name===t.constructor.name)throw new Ln(On.INVALID_ARGUMENT,"Type does not match the expected instance. Did you pass a reference from a different Firestore SDK?");throw t=$p(t),new Ln(On.INVALID_ARGUMENT,"Expected type '"+e.name+"', but it was: "+t)}function Hp(t,e){if(e<=0)throw new Ln(On.INVALID_ARGUMENT,"Function "+t+"() requires a positive number, but it was: "+e+".")}var qp,Vp=(Zp.prototype.isEqual=function(t){return this.host===t.host&&this.ssl===t.ssl&&this.credentials===t.credentials&&this.cacheSizeBytes===t.cacheSizeBytes&&this.experimentalForceLongPolling===t.experimentalForceLongPolling&&this.experimentalAutoDetectLongPolling===t.experimentalAutoDetectLongPolling&&this.ignoreUndefinedProperties===t.ignoreUndefinedProperties&&this.useFetchStreams===t.useFetchStreams},Zp),Up=(Object.defineProperty(Jp.prototype,"app",{get:function(){if(!this._app)throw new Ln(On.FAILED_PRECONDITION,"Firestore was not initialized using the Firebase SDK. 'app' is not available");return this._app},enumerable:!1,configurable:!0}),Object.defineProperty(Jp.prototype,"_initialized",{get:function(){return this._settingsFrozen},enumerable:!1,configurable:!0}),Object.defineProperty(Jp.prototype,"_terminated",{get:function(){return void 0!==this._terminateTask},enumerable:!1,configurable:!0}),Jp.prototype._setSettings=function(t){if(this._settingsFrozen)throw new Ln(On.FAILED_PRECONDITION,"Firestore has already been started and its settings can no longer be changed. You can only modify settings before calling any other methods on a Firestore object.");this._settings=new Vp(t),void 0!==t.credentials&&(this._credentials=function(t){if(!t)return new Sp;switch(t.type){case"gapi":var e=t.client;return Vn(!("object"!=typeof e||null===e||!e.auth||!e.auth.getAuthHeaderValueForFirstParty)),new Ip(e,t.sessionIndex||"0",t.i
1amToken||null);case"provider":return t.client;default:throw new Ln(On.INVALID_ARGUMENT,"makeCredentialsProvider failed due to invalid credential type")}}(t.credentials))},Jp.prototype._getSettings=function(){return this._settings},Jp.prototype._freezeSettings=function(){return this._settingsFrozen=!0,this._settings},Jp.prototype._delete=function(){return this._terminateTask||(this._terminateTask=this._terminate()),this._terminateTask},Jp.prototype.toJSON=function(){return{app:this._app,databaseId:this._databaseId,settings:this._settings}},Jp.prototype._terminate=function(){return(t=Tp.get(this))&&(Bn("ComponentProvider","Removing Datastore"),Tp.delete(this),t.terminate()),Promise.resolve();var t},Jp),Wp=(Object.defineProperty(Qp.prototype,"_path",{get:function(){return this._key.path},enumerable:!1,configurable:!0}),Object.defineProperty(Qp.prototype,"id",{get:function(){return this._key.path.lastSegment()},enumerable:!1,configurable:!0}),Object.defineProperty(Qp.prototype,"path",{get:function(){return this._key.path.canonicalString()},enumerable:!1,configurable:!0}),Object.defineProperty(Qp.prototype,"parent",{get:function(){return new Gp(this.firestore,this.converter,this._key.path.popLast())},enumerable:!1,configurable:!0}),Qp.prototype.withConverter=function(t){return new Qp(this.firestore,t,this._key)},Qp),Kp=(Xp.prototype.withConverter=function(t){return new Xp(this.firestore,t,this._query)},Xp),Gp=(i(Yp,qp=Kp),Object.defineProperty(Yp.prototype,"id",{get:function(){return this._query.path.lastSegment()},enumerable:!1,configurable:!0}),Object.defineProperty(Yp.prototype,"path",{get:function(){return this._query.path.canonicalString()},enumerable:!1,configurable:!0}),Object.defineProperty(Yp.prototype,"parent",{get:function(){var t=this._path.popLast();return t.isEmpty()?null:new Wp(this.firestore,null,new Sr(t))},enumerable:!1,configurable:!0}),Yp.prototype.withConverter=function(t){return new Yp(this.firestore,t,this._path)},Yp);function Yp(t,e,i){var n=this;return(n=qp.call(this,t,e,Es(i))||this)._path=i,n.type="collection",n}function Xp(t,e,i){this.converter=e,this._query=i,this.type="query",this.firestore=t}function Qp(t,e,i){this.converter=e,this._key=i,this.type="document",this.firestore=t}function Jp(t,e){this.type="firestore-lite",this._persistenceKey="(lite)",this._settings=new Vp({}),this._settingsFrozen=!1,t instanceof xp?(this._databaseId=t,this._credentials=new Sp):(this._app=t,this._databaseId=function(t){if(!Object.prototype.hasOwnProperty.apply(t.options,["projectId"]))throw new Ln(On.INVALID_ARGUMENT,'"projectId" not provided in firebase.initializeApp.');return new xp(t.options.projectId)}(t),this._credentials=new Ep(e))}function Zp(t){var e;if(void 0===t.host){if(void 0!==t.ssl)throw new Ln(On.INVALID_ARGUMENT,"Can't provide ssl option if host option is not set");this.host="firestore.googleapis.com",this.ssl=!0}else this.host=t.host,this.ssl=null===(e=t.ssl)||void 0===e||e;if(this.credentials=t.credentials,this.ignoreUndefinedProperties=!!t.ignoreUndefinedProperties,void 0===t.cacheSizeBytes)this.cacheSizeBytes=41943040;else{if(-1!==t.cacheSizeBytes&&t.cacheSizeBytes<1048576)throw new Ln(On.INVALID_ARGUMENT,"cacheSizeBytes must be at least 1048576");this.cacheSizeBytes=t.cacheSizeBytes}this.experimentalForceLongPolling=!!t.experimentalForceLongPolling,this.experimentalAutoDetectLongPolling=!!t.experimentalAutoDetectLongPolling,this.useFetchStreams=!!t.useFetchStreams,Fp("experimentalForceLongPolling",t.experimentalForceLongPolling,"experimentalAutoDetectLongPolling",t.experimentalAutoDetectLongPolling)}function tf(t,e){for(var i,n=[],r=2;r<arguments.length;r++)n[r-2]=arguments[r];if(t=w(t),Lp("collection","path",e),t instanceof Up)return Bp(i=sr.fromString.apply(sr,o([e],n))),new Gp(t,null,i);if(!(t instanceof Wp||t instanceof Gp))throw new Ln(On.INVALID_ARGUMENT,"Expected first argument to collection() to be a CollectionReference, a DocumentReference or FirebaseFirestore");return Bp(i=sr.fromString.apply(sr,o([t.path],n)).child(sr.fromString(e))),new Gp(t.firestore,null,i)}function ef(t,e){for(var i,n=[],r=2;r<arguments.length;r++)n[r-2]=arguments[r];if(t=w(t),Lp("doc","path",e=1===arguments.length?Un.u():e),t instanceof Up)return zp(i=sr.fromString.apply(sr,o([e],n))),new Wp(t,null,new Sr(i));if(!(t instanceof Wp||t instanceof Gp))throw new Ln(On.INVALID_ARGUMENT,"Expected first argument to collection() to be a CollectionReference, a DocumentReference or FirebaseFirestore");return zp(i=t._path.child(sr.fromString.apply(sr,o([e],n)))),new Wp(t.firestore,t instanceof Gp?t.converter:null,new Sr(i))}function nf(t,e){return t=w(t),e=w(e),(t instanceof Wp||t instanceof Gp)&&(e instanceof Wp||e instanceof Gp)&&t.firestore===e.firestore&&t.path===e.path&&t.converter===e.converter}function rf(t,e){return t=w(t),e=w(e),t instanceof Kp&&e instanceof Kp&&t.firestore===e.firestore&&Ls(t._query,e._query)&&t.converter===e.converter}var sf=(Object.defineProperty(of.prototype,"isShuttingDown",{get:function(){return this._c}
1,enumerable:!1,configurable:!0}),of.prototype.enqueueAndForget=function(t){this.enqueue(t)},of.prototype.enqueueAndForgetEvenWhileRestricted=function(t){this.Ac(),this.Rc(t)},of.prototype.enterRestrictedMode=function(t){this._c||(this._c=!0,this.Ec=t||!1,(t=ph())&&"function"==typeof t.removeEventListener&&t.removeEventListener("visibilitychange",this.Ic))},of.prototype.enqueue=function(t){var e=this;if(this.Ac(),this._c)return new Promise(function(){});var i=new sl;return this.Rc(function(){return e._c&&e.Ec?Promise.resolve():(t().then(i.resolve,i.reject),i.promise)}).then(function(){return i.promise})},of.prototype.enqueueRetryable=function(t){var e=this;this.enqueueAndForget(function(){return e.wc.push(t),e.bc()})},of.prototype.bc=function(){return g(this,void 0,void 0,function(){var e,i=this;return m(this,function(t){switch(t.label){case 0:if(0===this.wc.length)return[3,5];t.label=1;case 1:return t.trys.push([1,3,,4]),[4,this.wc[0]()];case 2:return t.sent(),this.wc.shift(),this.Zi.reset(),[3,4];case 3:if(!vl(e=t.sent()))throw e;return Bn("AsyncQueue","Operation failed with retryable error: "+e),[3,4];case 4:0<this.wc.length&&this.Zi.ji(function(){return i.bc()}),t.label=5;case 5:return[2]}})})},of.prototype.Rc=function(t){var n=this,e=this.dc.then(function(){return n.gc=!0,t().catch(function(t){throw n.yc=t,n.gc=!1,$n("INTERNAL UNHANDLED ERROR: ",(i=(e=t).message||"",i=e.stack?e.stack.includes(e.message)?e.stack:e.message+"\n"+e.stack:i)),t;var e,i}).then(function(t){return n.gc=!1,t})});return this.dc=e},of.prototype.enqueueAfterDelay=function(t,e,i){var n=this;return this.Ac(),-1<this.Tc.indexOf(t)&&(e=0),i=Gh.createAndSchedule(this,t,e,i,function(t){return n.vc(t)}),this.mc.push(i),i},of.prototype.Ac=function(){this.yc&&qn()},of.prototype.verifyOperationInProgress=function(){},of.prototype.Pc=function(){return g(this,void 0,void 0,function(){var e;return m(this,function(t){switch(t.label){case 0:return[4,e=this.dc];case 1:t.sent(),t.label=2;case 2:if(e!==this.dc)return[3,0];t.label=3;case 3:return[2]}})})},of.prototype.Vc=function(t){for(var e=0,i=this.mc;e<i.length;e++)if(i[e].timerId===t)return!0;return!1},of.prototype.Sc=function(n){var r=this;return this.Pc().then(function(){r.mc.sort(function(t,e){return t.targetTimeMs-e.targetTimeMs});for(var t=0,e=r.mc;t<e.length;t++){var i=e[t];if(i.skipDelay(),"all"!==n&&i.timerId===n)break}return r.Pc()})},of.prototype.Dc=function(t){this.Tc.push(t)},of.prototype.vc=function(t){t=this.mc.indexOf(t),this.mc.splice(t,1)},of);function of(){var e=this;this.dc=Promise.resolve(),this.wc=[],this._c=!1,this.mc=[],this.yc=null,this.gc=!1,this.Ec=!1,this.Tc=[],this.Zi=new bh(this,"async_queue_retry"),this.Ic=function(){var t=ph();t&&Bn("AsyncQueue","Visibility state changed to "+t.visibilityState),e.Zi.Gi()};var t=ph();t&&"function"==typeof t.addEventListener&&t.addEventListener("visibilitychange",this.Ic)}function af(r){return function(){if("object"==typeof r&&null!==r)for(var t=r,e=0,i=["next","error","complete"];e<i.length;e++){var n=i[e];if(n in t&&"function"==typeof t[n])return 1}}()}var lf,uf=(df.prototype.onProgress=function(t,e,i){this._progressObserver={next:t,error:e,complete:i}},df.prototype.catch=function(t){return this._taskCompletionResolver.promise.catch(t)},df.prototype.then=function(t,e){return this._taskCompletionResolver.promise.then(t,e)},df.prototype._completeWith=function(t){this._updateProgress(t),this._progressObserver.complete&&this._progressObserver.complete(),this._taskCompletionResolver.resolve(t)},df.prototype._failWith=function(t){this._lastProgress.taskState="Error",this._progressObserver.next&&this._progressObserver.next(this._lastProgress),this._progressObserver.error&&this._progressObserver.error(t),this._taskCompletionResolver.reject(t)},df.prototype._updateProgress=function(t){this._lastProgress=t,this._progressObserver.next&&this._progressObserver.next(t)},df),cf=(i(hf,lf=Up),hf.prototype._terminate=function(){return this._firestoreClient||ff(this),this._firestoreClient.terminate()},hf);function hf(t,e){var i=this;return(i=lf.call(this,t,e)||this).type="firestore",i._queue=new sf,i._persistenceKey="name"in t?t.name:"[DEFAULT]",i}function df(){this._progressObserver={},this._taskCompletionResolver=new sl,this._lastProgress={taskState:"Running",totalBytes:0,totalDocuments:0,bytesLoaded:0,documentsLoaded:0}}function pf(t){return t._firestoreClient||ff(t),t._firestoreClient.verifyNotTerminated(),t._firestoreClient}function ff(t){var e,i,n,r=t._freezeSettings();e=t._databaseId,i=(null===(n=t._app)||void 0===n?void 0:n.options.appId)||"",n=t._persistenceKey,r=new _p(e,i,n,r.host,r.ssl,r.experimentalForceLongPolling,r.experimentalAutoDetectLongPolling,r.useFetchStreams);t._firestoreClient=new np(t._credentials,t._queue,r)}function gf(i,n,r){var t=this,s=new sl;return i.asyncQueue.enqueue(function(){return g(t,void 0,void 0,function(){var e;return m(this,function(t){switch(t.label){case 0:return t.trys.push([0,3,,4]),[4,up(i,r)];case 1:return t.sent(),[4,cp(i,n)];case 2:return t.sent(),s.resolve(),[3,4];case 3:if(!("FirebaseError"===(e=t.sent()).name?e.code===On.FAILED_PRECONDITION||e.code===On.UNIMPLEMENT
1ED:!("undefined"!=typeof DOMException&&e instanceof DOMException)||22===e.code||20===e.code||11===e.code))throw e;return console.warn("Error enabling offline persistence. Falling back to persistence disabled: "+e),s.reject(e),[3,4];case 4:return[2]}})})}).then(function(){return s.promise})}function mf(t){if(t._initialized||t._terminated)throw new Ln(On.FAILED_PRECONDITION,"Firestore has already been started and persistence can no longer be enabled. You can only enable persistence before calling any other methods on a Firestore object.")}var vf=(If.prototype.isEqual=function(t){return this._internalPath.isEqual(t._internalPath)},If),yf=(kf.fromBase64String=function(t){try{return new kf(ur.fromBase64String(t))}catch(t){throw new Ln(On.INVALID_ARGUMENT,"Failed to construct data from Base64 string: "+t)}},kf.fromUint8Array=function(t){return new kf(ur.fromUint8Array(t))},kf.prototype.toBase64=function(){return this._byteString.toBase64()},kf.prototype.toUint8Array=function(){return this._byteString.toUint8Array()},kf.prototype.toString=function(){return"Bytes(base64: "+this.toBase64()+")"},kf.prototype.isEqual=function(t){return this._byteString.isEqual(t._byteString)},kf),bf=function(t){this._methodName=t},wf=(Object.defineProperty(Ef.prototype,"latitude",{get:function(){return this._lat},enumerable:!1,configurable:!0}),Object.defineProperty(Ef.prototype,"longitude",{get:function(){return this._long},enumerable:!1,configurable:!0}),Ef.prototype.isEqual=function(t){return this._lat===t._lat&&this._long===t._long},Ef.prototype.toJSON=function(){return{latitude:this._lat,longitude:this._long}},Ef.prototype._compareTo=function(t){return Kn(this._lat,t._lat)||Kn(this._long,t._long)},Ef),_f=/^__.*__$/,xf=(Cf.prototype.toMutation=function(t,e){return null!==this.fieldMask?new yo(t,this.data,this.fieldMask,e,this.fieldTransforms):new vo(t,this.data,e,this.fieldTransforms)},Cf),Tf=(Sf.prototype.toMutation=function(t,e){return new yo(t,this.data,this.fieldMask,e,this.fieldTransforms)},Sf);function Sf(t,e,i){this.data=t,this.fieldMask=e,this.fieldTransforms=i}function Cf(t,e,i){this.data=t,this.fieldMask=e,this.fieldTransforms=i}function Ef(t,e){if(!isFinite(t)||t<-90||90<t)throw new Ln(On.INVALID_ARGUMENT,"Latitude must be a number between -90 and 90, but was: "+t);if(!isFinite(e)||e<-180||180<e)throw new Ln(On.INVALID_ARGUMENT,"Longitude must be a number between -180 and 180, but was: "+e);this._lat=t,this._long=e}function kf(t){this._byteString=t}function If(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];for(var i=0;i<t.length;++i)if(0===t[i].length)throw new Ln(On.INVALID_ARGUMENT,"Invalid field name at argument $(i + 1). Field names must not be empty.");this._internalPath=new ar(t)}function Df(t){switch(t){case 0:case 2:case 1:return 1;case 3:case 4:return;default:throw qn()}}var Af=(Object.defineProperty(Nf.prototype,"path",{get:function(){return this.settings.path},enumerable:!1,configurable:!0}),Object.defineProperty(Nf.prototype,"Nc",{get:function(){return this.settings.Nc},enumerable:!1,configurable:!0}),Nf.prototype.xc=function(t){return new Nf(Object.assign(Object.assign({},this.settings),t),this.databaseId,this.R,this.ignoreUndefinedProperties,this.fieldTransforms,this.fieldMask)},Nf.prototype.kc=function(t){var e=null===(e=this.path)||void 0===e?void 0:e.child(t);return(e=this.xc({path:e,Fc:!1})).$c(t),e},Nf.prototype.Oc=function(t){var e;t=null===(e=this.path)||void 0===e?void 0:e.child(t);return(t=this.xc({path:t,Fc:!1})).Cc(),t},Nf.prototype.Mc=function(t){return this.xc({path:void 0,Fc:!0})},Nf.prototype.Lc=function(t){return lg(t,this.settings.methodName,this.settings.Bc||!1,this.path,this.settings.qc)},Nf.prototype.contains=function(e){return void 0!==this.fieldMask.find(function(t){return e.isPrefixOf(t)})||void 0!==this.fieldTransforms.find(function(t){return e.isPrefixOf(t.field)})},Nf.prototype.Cc=function(){if(this.path)for(var t=0;t<this.path.length;t++)this.$c(this.path.get(t))},Nf.prototype.$c=function(t){if(0===t.length)throw this.Lc("Document fields must not be empty");if(Df(this.Nc)&&_f.test(t))throw this.Lc('Document fields cannot begin and end with "__"')}
1,Nf),Pf=(Mf.prototype.Uc=function(t,e,i,n){return void 0===n&&(n=!1),new Af({Nc:t,methodName:e,qc:i,path:ar.emptyPath(),Fc:!1,Bc:n},this.databaseId,this.R,this.ignoreUndefinedProperties)},Mf);function Mf(t,e,i){this.databaseId=t,this.ignoreUndefinedProperties=e,this.R=i||fh(t)}function Nf(t,e,i,n,r,s){this.settings=t,this.databaseId=e,this.R=i,this.ignoreUndefinedProperties=n,void 0===r&&this.Cc(),this.fieldTransforms=r||[],this.fieldMask=s||[]}function Of(t){var e=t._freezeSettings(),i=fh(t._databaseId);return new Pf(t._databaseId,!!e.ignoreUndefinedProperties,i)}function Lf(t,e,i,n,r,s){var o=t.Uc((s=void 0===s?{}:s).merge||s.mergeFields?2:0,e,i,r);rg("Data must be an object, but it was:",o,n);var a,l;n=ig(n,o);if(s.merge)a=new lr(o.fieldMask),l=o.fieldTransforms;else if(s.mergeFields){for(var u=[],c=0,h=s.mergeFields;c<h.length;c++){var d=sg(e,h[c],i);if(!o.contains(d))throw new Ln(On.INVALID_ARGUMENT,"Field '"+d+"' is specified in your field mask but missing from your input data.");ug(u,d)||u.push(d)}a=new lr(u),l=o.fieldTransforms.filter(function(t){return a.covers(t.field)})}else a=null,l=o.fieldTransforms;return new xf(new Br(n),a,l)}var Rf,Ff=(i(zf,Rf=bf),zf.prototype._toFieldTransform=function(t){if(2!==t.Nc)throw 1===t.Nc?t.Lc(this._methodName+"() can only appear at the top level of your update data"):t.Lc(this._methodName+"() cannot be used with set() unless you pass {merge:true}");return t.fieldMask.push(t.path),null},zf.prototype.isEqual=function(t){return t instanceof zf},zf);function zf(){return null!==Rf&&Rf.apply(this,arguments)||this}function Bf(t,e,i){return new Af({Nc:3,qc:e.settings.qc,methodName:t._methodName,Fc:i},e.databaseId,e.R,e.ignoreUndefinedProperties)}var $f,jf,Hf,qf,Vf=(i(Qf,qf=bf),Qf.prototype._toFieldTransform=function(t){return new ao(t.path,new Ws)},Qf.prototype.isEqual=function(t){return t instanceof Qf},Qf),Uf=(i(Xf,Hf=bf),Xf.prototype._toFieldTransform=function(t){var e=Bf(this,t,!0),i=this.Kc.map(function(t){return eg(t,e)});i=new Ks(i);return new ao(t.path,i)},Xf.prototype.isEqual=function(t){return this===t},Xf),Wf=(i(Yf,jf=bf),Yf.prototype._toFieldTransform=function(t){var e=Bf(this,t,!0),i=this.Kc.map(function(t){return eg(t,e)});i=new Js(i);return new ao(t.path,i)},Yf.prototype.isEqual=function(t){return this===t},Yf),Kf=(i(Gf,$f=bf),Gf.prototype._toFieldTransform=function(t){var e=new io(t.R,Hs(t.R,this.Qc));return new ao(t.path,e)},Gf.prototype.isEqual=function(t){return this===t},Gf);function Gf(t,e){var i=this;return(i=$f.call(this,t)||this).Qc=e,i}function Yf(t,e){var i=this;return(i=jf.call(this,t)||this).Kc=e,i}function Xf(t,e){var i=this;return(i=Hf.call(this,t)||this).Kc=e,i}function Qf(){return null!==qf&&qf.apply(this,arguments)||this}function Jf(t,n,r,e){var s=t.Uc(1,n,r);rg("Data must be an object, but it was:",s,e);var o=[],a=Br.empty();return er(e,function(t,e){var i=ag(n,t,r);e=w(e),t=s.Oc(i),e instanceof Ff?o.push(i):null!=(t=eg(e,t))&&(o.push(i),a.set(i,t))}),e=new lr(o),new Tf(a,e,s.fieldTransforms)}function Zf(t,e,i,n,r,s){var o=t.Uc(1,e,i),a=[sg(e,n,i)],l=[r];if(s.length%2!=0)throw new Ln(On.INVALID_ARGUMENT,"Function "+e+"() needs to be called with an even number of arguments that alternate between field names and values.");for(var u=0;u<s.length;u+=2)a.push(sg(e,s[u])),l.push(s[u+1]);for(var c,h,d,p=[],f=Br.empty(),g=a.length-1;0<=g;--g)ug(p,a[g])||(c=a[g],h=w(h=l[g]),d=o.Oc(c),h instanceof Ff?p.push(c):null!=(d=eg(h,d))&&(p.push(c),f.set(c,d)));return r=new lr(p),new Tf(f,r,o.fieldTransforms)}function tg(t,e,i,n){return eg(i,t.Uc((n=void 0!==n&&n)?4:3,e))}function eg(o,t){if(ng(o=w(o)))return rg("Unsupported field value:",t,o),ig(o,t);if(o instanceof bf)return function(t,e){if(!Df(e.Nc))throw e.Lc(t._methodName+"() can only be used with update() and set()");if(!e.path)throw e.Lc(t._methodName+"() is not currently supported inside arrays");(t=t._toFieldTransform(e))&&e.fieldTransforms.push(t)}(o,t),null;if(void 0===o&&t.ignoreUndefinedProperties)return null;if(t.path&&t.fieldMask.push(t.path),o instanceof Array){if(t.settings.Fc&&4!==t.Nc)throw t.Lc("Nested arrays are not supported");return function(t){for(var e=[],i=0,n=0,r=o;n<r.length;n++){var s=eg(r[n],t.Mc(i));null==s&&(s={nullValue:"NULL_VALUE"}),e.push(s),i++}return{arrayValue:{values:e}}}(t)}return function(t,e){if(null===(t=w(o)))return{nullValue:"NULL_VALUE"};if("number"==typeof t)return Hs(e.R,t);if("boolean"==typeof t)return{booleanValue:t};if("string"==typeof t)return{stringValue:t};if(t instanceof Date){var i=Xn.fromDate(t);return{timestampValue:pa(e.R,i)}}if(t instanceof Xn)return i=new Xn(t.seconds,1e3*Math.floor(t.nanoseconds/1e3)),{timestampValue:pa(e.R,i)};if(t instanceof wf)return{geoPointValue:{latitude:t.latitude,longitude:t.longitude}};if(t instanceof yf)return{bytesValue:fa(e.R,t._byteString)};if(t instanceof Wp){i=e.databaseId;var n=t.firestore._databaseId;if(!n.isEqual(i))throw e.Lc("Document reference is for database "+n.projectId+"/"+n.database+" but should be for database "+i.projectId+"/"+i.database);return{referenceValue:ma(t.firestore._databaseId||e.databaseId,t._key.path)}}throw e.Lc("Unsupported field value: "+$p(t))}(0,t)}function ig(t,i){var n={};return ir(t)?i.path&&0<i.path.length&&i.fieldMask.push(i.path):er(t,function(t,e){null!=(e=eg(e,i.kc(t)))&&(n[t]=e)}),{mapValue:{fields:n}}}function ng(t){return!("object"!=typeof t||null===t||t instanceof Array||t instanceof Date||t instanceof Xn||t instanceof wf||t instanceof yf||t instanceof Wp||t instanceof bf)}function rg(t,e,i){if(!ng(i)||"object"!=typeof(n=i)||null===n||Object.getPrototypeOf(n)!==Object.prototype&&null!==Object.getPrototypeOf(n))throw"an object"===(i=$p(i))?e.Lc(t+" a custom object"):e.Lc(t+" "+i);var n}
1function sg(t,e,i){if((e=w(e))instanceof vf)return e._internalPath;if("string"==typeof e)return ag(t,e);throw lg("Field path arguments must be of type string or FieldPath.",t,!1,void 0,i)}var og=new RegExp("[~\\*/\\[\\]]");function ag(e,i,n){if(0<=i.search(og))throw lg("Invalid field path ("+i+"). Paths must not contain '~', '*', '/', '[', or ']'",e,!1,void 0,n);try{return(new(vf.bind.apply(vf,o([void 0],i.split(".")))))._internalPath}catch(t){throw lg("Invalid field path ("+i+"). Paths must not be empty, begin with '.', end with '.', or contain '..'",e,!1,void 0,n)}}function lg(t,e,i,n,r){var s=n&&!n.isEmpty(),o=void 0!==r;e="Function "+e+"() called with invalid data";return i&&(e+=" (via `toFirestore()`)"),i="",(s||o)&&(i+=" (found",s&&(i+=" in field "+n),o&&(i+=" in document "+r),i+=")"),new Ln(On.INVALID_ARGUMENT,(e+=". ")+t+i)}function ug(t,e){return t.some(function(t){return t.isEqual(e)})}var cg,hg=(Object.defineProperty(fg.prototype,"id",{get:function(){return this._key.path.lastSegment()},enumerable:!1,configurable:!0}),Object.defineProperty(fg.prototype,"ref",{get:function(){return new Wp(this._firestore,this._converter,this._key)},enumerable:!1,configurable:!0}),fg.prototype.exists=function(){return null!==this._document},fg.prototype.data=function(){if(this._document){if(this._converter){var t=new dg(this._firestore,this._userDataWriter,this._key,this._document,null);return this._converter.fromFirestore(t)}return this._userDataWriter.convertValue(this._document.data.value)}},fg.prototype.get=function(t){if(this._document&&null!==(t=this._document.data.field(gg("DocumentSnapshot.get",t))))return this._userDataWriter.convertValue(t)},fg),dg=(i(pg,cg=hg),pg.prototype.data=function(){return cg.prototype.data.call(this)},pg);function pg(){return null!==cg&&cg.apply(this,arguments)||this}function fg(t,e,i,n,r){this._firestore=t,this._userDataWriter=e,this._key=i,this._document=n,this._converter=r}function gg(t,e){return"string"==typeof e?ag(t,e):(e instanceof vf?e:e._delegate)._internalPath}var mg,vg,yg=(Cg.prototype.isEqual=function(t){return this.hasPendingWrites===t.hasPendingWrites&&this.fromCache===t.fromCache},Cg),bg=(i(Sg,vg=hg),Sg.prototype.exists=function(){return vg.prototype.exists.call(this)},Sg.prototype.data=function(t){if(void 0===t&&(t={}),this._document){if(this._converter){var e=new wg(this._firestore,this._userDataWriter,this._key,this._document,this.metadata,null);return this._converter.fromFirestore(e,t)}return this._userDataWriter.convertValue(this._document.data.value,t.serverTimestamps)}},Sg.prototype.get=function(t,e){if(void 0===e&&(e={}),this._document&&null!==(t=this._document.data.field(gg("DocumentSnapshot.get",t))))return this._userDataWriter.convertValue(t,e.serverTimestamps)},Sg),wg=(i(Tg,mg=bg),Tg.prototype.data=function(t){return mg.prototype.data.call(this,t=void 0===t?{}:t)},Tg),_g=(Object.defineProperty(xg.prototype,"docs",{get:function(){var e=[];return this.forEach(function(t){return e.push(t)}),e},enumerable:!1,configurable:!0}),Object.defineProperty(xg.prototype,"size",{get:function(){return this._snapshot.docs.size},enumerable:!1,configurable:!0}),Object.defineProperty(xg.prototype,"empty",{get:function(){return 0===this.size},enumerable:!1,configurable:!0}),xg.prototype.forEach=function(e,i){var n=this;this._snapshot.docs.forEach(function(t){e.call(i,new wg(n._firestore,n._userDataWriter,t.key,t,new yg(n._snapshot.mutatedKeys.has(t.key),n._snapshot.fromCache),n.query.converter))})},xg.prototype.docChanges=function(t){if((t=!!(t=void 0===t?{}:t).includeMetadataChanges)&&this._snapshot.excludesMetadataChanges)throw new Ln(On.INVALID_ARGUMENT,"To include metadata changes with your document changes, you must also pass { includeMetadataChanges:true } to onSnapshot().");return this._cachedChanges&&this._cachedChangesIncludeMetadataChanges===t||(this._cachedChanges=function(r,e){if(r._snapshot.oldDocs.isEmpty()){var i=0;return r._snapshot.docChanges.map(function(t){return{type:"added",doc:new wg(r._firestore,r._userDataWriter,t.doc.key,t.doc,new yg(r._snapshot.mutatedKeys.has(t.doc.key),r._snapshot.fromCache),r.query.converter),oldIndex:-1,newIndex:i++}})}var s=r._snapshot.oldDocs;return r._snapshot.docChanges.filter(function(t){return e||3!==t.type}).map(function(e){var t=new wg(r._firestore,r._userDataWriter,e.doc.key,e.doc,new yg(r._snapshot.mutatedKeys.has(e.doc.key),r._snapshot.fromCache),r.query.converter),i=-1,n=-1;return 0!==e.type&&(i=s.indexOf(e.doc.key),s=s.delete(e.doc.key)),1!==e.type&&(n=(s=s.add(e.doc)).indexOf(e.doc.key)),{type:function(t){switch(e.type){case 0:return"added";case 2:case 3:return"modified";case 1:return"removed";default:return qn()}}(),doc:t,oldIndex:i,newIndex:n}})}(this,t),this._cachedChangesIncludeMetadataChanges=t),this._cachedChanges},xg);function xg(t,e,i,n){this._firestore=t,this._userDataWriter=e,this._snapshot=n,this.metadata=new yg(n.hasPendingWrites,n.fromCache),this.query=i}function Tg(){return null!==mg&&mg.apply(this,arguments)||this}function Sg(t,e,i,n,r,s){var o=this;return(o=vg.call(this,t,e,i,n,s)||this)._firestore=t,o._firestoreImpl=t,o.metadata=r,o}function Cg(t,e){this.hasPendingWrites=t,this.fromCache=e}function Eg(t,e){return t instanceof bg&&e instanceof bg?t._firestore===e._firestore&&t._key.isEqual(e._key)&&(null===t._document?null===e._document:t._document.isEqual(e._document))&&t._
1converter===e._converter:t instanceof _g&&e instanceof _g&&t._firestore===e._firestore&&rf(t.query,e.query)&&t.metadata.isEqual(e.metadata)&&t._snapshot.isEqual(e._snapshot)}function kg(t){if(Is(t)&&0===t.explicitOrderBy.length)throw new Ln(On.UNIMPLEMENTED,"limitToLast() queries require specifying at least one orderBy() clause")}function Ig(t){for(var e=[],i=1;i<arguments.length;i++)e[i-1]=arguments[i];for(var n=0,r=e;n<r.length;n++)t=r[n]._apply(t);return t}var Dg,Ag,Pg,Mg,Ng,Og=(i(qg,Ng=A=function(){}),qg.prototype._apply=function(t){var e=Of(t.firestore);e=function(t,e,i,n,r,s){if(n.isKeyField()){if("array-contains"===r||"array-contains-any"===r)throw new Ln(On.INVALID_ARGUMENT,"Invalid Query. You can't perform '"+r+"' queries on FieldPath.documentId().");if("in"===r||"not-in"===r){Wg(s,r);for(var o=[],a=0,l=s;a<l.length;a++){var u=l[a];o.push(Ug(i,t,u))}c={arrayValue:{values:o}}}else c=Ug(i,t,s)}else"in"!==r&&"not-in"!==r&&"array-contains-any"!==r||Wg(s,r),c=tg(e,"where",s,"in"===r||"not-in"===r);var c=Yr.create(n,r,c);return function(t,e){if(e.g()){var i=As(t);if(null!==i&&!i.isEqual(e.field))throw new Ln(On.INVALID_ARGUMENT,"Invalid query. All where filters with an inequality (<, <=, !=, not-in, >, or >=) must be on the same field. But you have inequality filters on '"+i.toString()+"' and '"+e.field.toString()+"'");null!==(i=Ds(t))&&Kg(0,e.field,i)}if(null!==(t=function(t,e){for(var i=0,n=t.filters;i<n.length;i++){var r=n[i];if(0<=e.indexOf(r.op))return r.op}return null}(t,function(){switch(e.op){case"!=":return["!=","not-in"];case"array-contains":return["array-contains","array-contains-any","not-in"];case"in":return["array-contains-any","in","not-in"];case"array-contains-any":return["array-contains","array-contains-any","in","not-in"];case"not-in":return["array-contains","array-contains-any","in","not-in","!="];default:return[]}}())))throw t===e.op?new Ln(On.INVALID_ARGUMENT,"Invalid query. You cannot use more than one '"+e.op.toString()+"' filter."):new Ln(On.INVALID_ARGUMENT,"Invalid query. You cannot use '"+e.op.toString()+"' filters with '"+t.toString()+"' filters.")}(t,c),c}(t._query,e,t.firestore._databaseId,this.jc,this.Wc,this.Gc);return new Kp(t.firestore,t.converter,(e=(t=t._query).filters.concat([e]),new Ss(t.path,t.collectionGroup,t.explicitOrderBy.slice(),e,t.limit,t.limitType,t.startAt,t.endAt)))},qg),Lg=(i(Hg,Mg=A),Hg.prototype._apply=function(t){var e=function(t,e,i){if(null!==t.startAt)throw new Ln(On.INVALID_ARGUMENT,"Invalid query. You must not call startAt() or startAfter() before calling orderBy().");if(null!==t.endAt)throw new Ln(On.INVALID_ARGUMENT,"Invalid query. You must not call endAt() or endBefore() before calling orderBy().");var n=new _s(e,i);return e=n,null!==Ds(i=t)||null!==(t=As(i))&&Kg(0,t,e.field),n}(t._query,this.jc,this.zc);return new Kp(t.firestore,t.converter,(e=(t=t._query).explicitOrderBy.concat([e]),new Ss(t.path,t.collectionGroup,e,t.filters.slice(),t.limit,t.limitType,t.startAt,t.endAt)))},Hg),Rg=(i(jg,Pg=A),jg.prototype._apply=function(t){return new Kp(t.firestore,t.converter,Os(t._query,this.Hc,this.Jc))},jg),Fg=(i($g,Ag=A),$g.prototype._apply=function(t){var e=Vg(t,this.type,this.Yc,this.Xc);return new Kp(t.firestore,t.converter,(t=t._query,e=e,new Ss(t.path,t.collectionGroup,t.explicitOrderBy.slice(),t.filters.slice(),t.limit,t.limitType,e,t.endAt)))},$g),zg=(i(Bg,Dg=A),Bg.prototype._apply=function(t){var e=Vg(t,this.type,this.Yc,this.Xc);return new Kp(t.firestore,t.converter,(t=t._query,e=e,new Ss(t.path,t.collectionGroup,t.explicitOrderBy.slice(),t.filters.slice(),t.limit,t.limitType,t.startAt,e)))},Bg);function Bg(t,e,i){var n=this;return(n=Dg.call(this)||this).type=t,n.Yc=e,n.Xc=i,n}function $g(t,e,i){var n=this;return(n=Ag.call(this)||this).type=t,n.Yc=e,n.Xc=i,n}function jg(t,e,i){var n=this;return(n=Pg.call(this)||this).type=t,n.Hc=e,n.Jc=i,n}function Hg(t,e){var i=this;return(i=Mg.call(this)||this).jc=t,i.zc=e,i.type="orderBy",i}function qg(t,e,i){var n=this;return(n=Ng.call(this)||this).jc=t,n.Wc=e,n.Gc=i,n.type="where",n}function Vg(t,u,e,i){if(e[0]=w(e[0]),e[0]instanceof hg)return function(t,e,
1i,n){if(!i)throw new Ln(On.NOT_FOUND,"Can't use a DocumentSnapshot that doesn't exist for "+u+"().");for(var r=[],s=0,o=Ms(t);s<o.length;s++){var a=o[s];if(a.field.isKeyField())r.push(Mr(e,i.key));else{var l=i.data.field(a.field);if(br(l))throw new Ln(On.INVALID_ARGUMENT,'Invalid query. You are trying to start or end a query using a document for which the field "'+a.field+'" is an uncommitted server timestamp. (Since the value of this field is unknown, you cannot start/end a query with it.)');if(null===l)throw a=a.field.canonicalString(),new Ln(On.INVALID_ARGUMENT,"Invalid query. You are trying to start or end a query using a document for which the field '"+a+"' (used as the orderBy) does not exist.");r.push(l)}}return new gs(r,n)}(t._query,t.firestore._databaseId,e[0]._document,i);var n=Of(t.firestore);return function(t,e,i,n,r,s){var o=t.explicitOrderBy;if(r.length>o.length)throw new Ln(On.INVALID_ARGUMENT,"Too many arguments provided to "+n+"(). The number of arguments must be less than or equal to the number of orderBy() clauses");for(var a=[],l=0;l<r.length;l++){var u=r[l];if(o[l].field.isKeyField()){if("string"!=typeof u)throw new Ln(On.INVALID_ARGUMENT,"Invalid query. Expected a string for document ID in "+n+"(), but got a "+typeof u);if(!Ps(t)&&-1!==u.indexOf("/"))throw new Ln(On.INVALID_ARGUMENT,"Invalid query. When querying a collection and ordering by FieldPath.documentId(), the value passed to "+n+"() must be a plain document ID, but '"+u+"' contains a slash.");var c=t.path.child(sr.fromString(u));if(!Sr.isDocumentKey(c))throw new Ln(On.INVALID_ARGUMENT,"Invalid query. When querying a collection group and ordering by FieldPath.documentId(), the value passed to "+n+"() must result in a valid document path, but '"+c+"' is not because it contains an odd number of segments.");c=new Sr(c),a.push(Mr(e,c))}else u=tg(i,n,u),a.push(u)}return new gs(a,s)}(t._query,t.firestore._databaseId,n,u,e,i)}function Ug(t,e,i){if("string"==typeof(i=w(i))){if(""===i)throw new Ln(On.INVALID_ARGUMENT,"Invalid query. When querying with FieldPath.documentId(), you must provide a valid document ID, but it was an empty string.");if(!Ps(e)&&-1!==i.indexOf("/"))throw new Ln(On.INVALID_ARGUMENT,"Invalid query. When querying a collection by FieldPath.documentId(), you must provide a plain document ID, but '"+i+"' contains a '/' character.");if(e=e.path.child(sr.fromString(i)),!Sr.isDocumentKey(e))throw new Ln(On.INVALID_ARGUMENT,"Invalid query. When querying a collection group by FieldPath.documentId(), the value provided must result in a valid document path, but '"+e+"' is not because it has an odd number of segments ("+e.length+").");return Mr(t,new Sr(e))}if(i instanceof Wp)return Mr(t,i._key);throw new Ln(On.INVALID_ARGUMENT,"Invalid query. When querying with FieldPath.documentId(), you must provide a valid string or a DocumentReference, but it was: "+$p(i)+".")}function Wg(t,e){if(!Array.isArray(t)||0===t.length)throw new Ln(On.INVALID_ARGUMENT,"Invalid Query. A non-empty array is required for '"+e.toString()+"' filters.");if(10<t.length)throw new Ln(On.INVALID_ARGUMENT,"Invalid Query. '"+e.toString()+"' filters support a maximum of 10 elements in the value array.")}function Kg(t,e,i){if(!i.isEqual(e))throw new Ln(On.INVALID_ARGUMENT,"Invalid query. You have a where filter with an inequality (<, <=, !=, not-in, >, or >=) on field '"+e.toString()+"' and so you must also use '"+e.toString()+"' as your first argument to orderBy(), but your first orderBy() is on field '"+i.toString()+"' instead.")}function Gg(){}function Yg(t,e,i){return t?i&&(i.merge||i.mergeFields)?t.toFirestore(e,i):t.toFirestore(e):e}Gg.prototype.convertValue=function(t,e){switch(void 0===e&&(e="none"),Er(t)){case 0:return null;case 1:return t.booleanValue;case 2:return vr(t.integerValue||t.doubleValue);case 3:return this.convertTimestamp(t.timestampValue);case 4:return this.convertServerTimestamp(t,e);case 5:return t.stringValue;case 6:return this.convertBytes(yr(t.bytesValue));case 7:return this.convertReference(t.referenceValue);case 8:return this.convertGeoPoint(t.geoPointValue);case 9:return this.convertArray(t.arrayValue,e);case 10:return this.convertObject(t.mapValue,e);default:throw qn()}},Gg.prototype.convertObject=function(t,i){var n=this,r={};return er(t.fields,function(t,e){r[t]=n.convertValue(e,i)}),r},Gg.prototype.convertGeoPoint=function(t){return new wf(vr(t.latitude),vr(t.longitude))},Gg.prototype.convertArray=function(t,e){var i=this;return(t.values||[]).map(function(t){return i.convertValue(t,e)})},Gg.prototype.convertServerTimestamp=function(t,e){switch(e){case"previous":var i=function t(e){return br(e=e.mapValue.fields.__previous_value__)?t(e):e}(t);return null==i?null:this.convertValue(i,e);case"estimate":return this.convertTimestamp(wr(t));default:return null}},Gg.prototype.convertTimestamp=function(t){return t=mr(t),new Xn(t.seconds,t.nanos)},Gg.prototype.convertDocumentKey=function(t,e){var i=sr.fromString(t);return Vn(La(i)),t=new xp(i.get(1),i.get(3)),i=new Sr(i.popFirst(5)),t.isEqual(e)||$n("Document "+i+" contains a document reference within a different database ("+t.projectId+"/"+t.database+") which is not supported. It will be treated as a reference in the current database ("+e.projectId+"/"+e.database+") instead."),i};var Xg,Qg=(i(tm,Xg=C=Gg),tm.prototype.convertBytes=function(t){return new yf
1(t)},tm.prototype.convertReference=function(t){return t=this.convertDocumentKey(t,this.firestore._databaseId),new Wp(this.firestore,null,t)},tm),Jg=(Zg.prototype.set=function(t,e,i){return this._verifyNotCommitted(),e=Yg((t=em(t,this._firestore)).converter,e,i),i=Lf(this._dataReader,"WriteBatch.set",t._key,e,null!==t.converter,i),this._mutations.push(i.toMutation(t._key,lo.none())),this},Zg.prototype.update=function(t,e,i){for(var n=[],r=3;r<arguments.length;r++)n[r-3]=arguments[r];return this._verifyNotCommitted(),t=em(t,this._firestore),e="string"==typeof(e=w(e))||e instanceof vf?Zf(this._dataReader,"WriteBatch.update",t._key,e,i,n):Jf(this._dataReader,"WriteBatch.update",t._key,e),this._mutations.push(e.toMutation(t._key,lo.exists(!0))),this},Zg.prototype.delete=function(t){return this._verifyNotCommitted(),t=em(t,this._firestore),this._mutations=this._mutations.concat(new Io(t._key,lo.none())),this},Zg.prototype.commit=function(){return this._verifyNotCommitted(),this._committed=!0,0<this._mutations.length?this._commitHandler(this._mutations):Promise.resolve()},Zg.prototype._verifyNotCommitted=function(){if(this._committed)throw new Ln(On.FAILED_PRECONDITION,"A write batch can no longer be used after commit() has been called.")},Zg);function Zg(t,e){this._firestore=t,this._commitHandler=e,this._mutations=[],this._committed=!1,this._dataReader=Of(t)}function tm(t){var e=this;return(e=Xg.call(this)||this).firestore=t,e}function em(t,e){if((t=w(t)).firestore!==e)throw new Ln(On.INVALID_ARGUMENT,"Provided document reference is from a different Firestore instance.");return t}var im,nm=(i(rm,im=C),rm.prototype.convertBytes=function(t){return new yf(t)},rm.prototype.convertReference=function(t){return t=this.convertDocumentKey(t,this.firestore._databaseId),new Wp(this.firestore,null,t)},rm);function rm(t){var e=this;return(e=im.call(this)||this).firestore=t,e}function sm(t,e,i){for(var n=[],r=3;r<arguments.length;r++)n[r-3]=arguments[r];var s=jp((t=jp(t,Wp)).firestore,cf),o=Of(s);return am(s,[("string"==typeof(e=w(e))||e instanceof vf?Zf(o,"updateDoc",t._key,e,i,n):Jf(o,"updateDoc",t._key,e)).toMutation(t._key,lo.exists(!0))])}function om(e){for(var i=[],t=1;t<arguments.length;t++)i[t-1]=arguments[t];e=w(e);var n={includeMetadataChanges:!1},r=0;"object"!=typeof i[r]||af(i[r])||(n=i[r],r++);var s,o,a,l,u,c,h={includeMetadataChanges:n.includeMetadataChanges};return af(i[r])&&(s=i[r],i[r]=null===(n=s.next)||void 0===n?void 0:n.bind(s),i[r+1]=null===(n=s.error)||void 0===n?void 0:n.bind(s),i[r+2]=null===(n=s.complete)||void 0===n?void 0:n.bind(s)),e instanceof Wp?(a=jp(e.firestore,cf),l=Es(e._key.path),c={next:function(t){i[r]&&i[r](lm(a,e,t))},error:i[r+1],complete:i[r+2]}):(o=jp(e,Kp),a=jp(o.firestore,cf),l=o._query,u=new nm(a),c={next:function(t){i[r]&&i[r](new _g(a,u,o,t))},error:i[r+1],complete:i[r+2]},kg(e._query)),function(i,t,e){var n=this,r=new Zd(c),s=new ld(t,r,e);return i.asyncQueue.enqueueAndForget(function(){return g(n,void 0,void 0,function(){var e;return m(this,function(t){switch(t.label){case 0:return e=sd,[4,vp(i)];case 1:return[2,e.apply(void 0,[t.sent(),s])]}})})}),function(){r.Wo(),i.asyncQueue.enqueueAndForget(function(){return g(n,void 0,void 0,function(){var e;return m(this,function(t){switch(t.label){case 0:return e=od,[4,vp(i)];case 1:return[2,e.apply(void 0,[t.sent(),s])]}})})})}}(pf(a),l,h)}function am(t,e){return function(i,n){var t=this,r=new sl;return i.asyncQueue.enqueueAndForget(function(){return g(t,void 0,void 0,function(){var e;return m(this,function(t){switch(t.label){case 0:return e=Ed,[4,mp(i)];case 1:return[2,e.apply(void 0,[t.sent(),n,r])]}})})}),r.promise}(pf(t),e)}function lm(t,e,i){var n=i.docs.get(e._key),r=new nm(t);return new bg(t,r,e._key,n,new yg(i.hasPendingWrites,i.fromCache),e.converter)}var um,cm=(dm.prototype.get=function(t){var e=this,i=em(t,this._firestore),n=new Qg(this._firestore);return this._transaction.lookup([i._key]).then(function(t){if(!t||1!==t.length)return qn();if((t=t[0]).isFoundDocument())return new hg(e._firestore,n,t.key,t,i.converter);
1if(t.isNoDocument())return new hg(e._firestore,n,i._key,null,i.converter);throw qn()})},dm.prototype.set=function(t,e,i){return e=Yg((t=em(t,this._firestore)).converter,e,i),i=Lf(this._dataReader,"Transaction.set",t._key,e,null!==t.converter,i),this._transaction.set(t._key,i),this},dm.prototype.update=function(t,e,i){for(var n=[],r=3;r<arguments.length;r++)n[r-3]=arguments[r];return t=em(t,this._firestore),e="string"==typeof(e=w(e))||e instanceof vf?Zf(this._dataReader,"Transaction.update",t._key,e,i,n):Jf(this._dataReader,"Transaction.update",t._key,e),this._transaction.update(t._key,e),this},dm.prototype.delete=function(t){return t=em(t,this._firestore),this._transaction.delete(t._key),this},i(hm,um=dm),hm.prototype.get=function(t){var e=this,i=em(t,this._firestore),n=new nm(this._firestore);return um.prototype.get.call(this,t).then(function(t){return new bg(e._firestore,n,i._key,t._document,new yg(!1,!1),i.converter)})},hm);function hm(t,e){var i=this;return(i=um.call(this,t,e)||this)._firestore=t,i}function dm(t,e){this._firestore=t,this._transaction=e,this._dataReader=Of(t)}function pm(){if("undefined"==typeof Uint8Array)throw new Ln(On.UNIMPLEMENTED,"Uint8Arrays are not available in this environment.")}function fm(){if("undefined"==typeof atob)throw new Ln(On.UNIMPLEMENTED,"Blobs are unavailable in Firestore in this environment.")}var gm,mm=(Tm.fromBase64String=function(t){return fm(),new Tm(yf.fromBase64String(t))},Tm.fromUint8Array=function(t){return pm(),new Tm(yf.fromUint8Array(t))},Tm.prototype.toBase64=function(){return fm(),this._delegate.toBase64()},Tm.prototype.toUint8Array=function(){return pm(),this._delegate.toUint8Array()},Tm.prototype.isEqual=function(t){return this._delegate.isEqual(t._delegate)},Tm.prototype.toString=function(){return"Blob(base64: "+this.toBase64()+")"},Tm),vm=(xm.prototype.enableIndexedDbPersistence=function(t,e){return function(t,e){mf(t=jp(t,cf));var i=pf(t),n=t._freezeSettings();return gf(i,t=new Kd,new Ud(t,n.cacheSizeBytes,null==e?void 0:e.forceOwnership))}(t._delegate,{forceOwnership:e})},xm.prototype.enableMultiTabIndexedDbPersistence=function(t){return function(t){mf(t=jp(t,cf));var e=pf(t),i=t._freezeSettings();return gf(e,t=new Kd,new Wd(t,i.cacheSizeBytes))}(t._delegate)},xm.prototype.clearIndexedDbPersistence=function(t){return function(i){var t=this;if(i._initialized&&!i._terminated)throw new Ln(On.FAILED_PRECONDITION,"Persistence can only be cleared before a Firestore instance is initialized or after it is terminated.");var n=new sl;return i._queue.enqueueAndForgetEvenWhileRestricted(function(){return g(t,void 0,void 0,function(){var e;return m(this,function(t){switch(t.label){case 0:return t.trys.push([0,2,,3]),[4,function(i){return g(this,void 0,void 0,function(){var e;return m(this,function(t){switch(t.label){case 0:return ll.yt()?(e=i+"main",[4,ll.delete(e)]):[2,Promise.resolve()];case 1:return t.sent(),[2]}})})}(Yu(i._databaseId,i._persistenceKey))];case 1:return t.sent(),n.resolve(),[3,3];case 2:return e=t.sent(),n.reject(e),[3,3];case 3:return[2]}})})}),n.promise}(t._delegate)},xm),ym=(Object.defineProperty(_m.prototype,"_databaseId",{get:function(){return this._delegate._databaseId},enumerable:!1,configurable:!0}),_m.prototype.settings=function(t){var e=this._delegate._getSettings();t.merge||e.host===t.host||jn("You are overriding the original host. If you did not intend to override your settings, use {merge: true}."),t.merge&&delete(t=Object.assign(Object.assign({},e),t)).merge,this._delegate._setSettings(t)},_m.prototype.useEmulator=function(t,e,i){!function(t,e,i,n){void 0===n&&(n={});var r,s=(t=jp(t,Up))._getSettings();if("firestore.googleapis.com"!==s.host&&s.host!==e&&jn("Host has been set in both settings() and useEmulator(), emulator host will be used"),t._setSettings(Object.assign(Object.assign({},s),{host:e+":"+i,ssl:!1})),n.mockUserToken){if("string"==typeof n.mockUserToken)o=n.mockUserToken,r=Ec.MOCK_USER;else{var o=function(t,e){if(t.uid)throw new Error('The "uid" field is no longer supported by mockUserToken. Please use "sub" instead for Firebase Auth User ID.');var i=e||"demo-project",n=t.iat||0;if(!(e=t.sub||t.user_id))throw new Error("mockUserToken must contain 'sub' or 'user_id' field!");return t=a({iss:"https://securetoken.google.com/"+i,aud:i,iat:n,exp:n+3600,auth_time:n,sub:e,user_id:e,firebase:{sign_in_provider:"custom",identities:{}}},t),[l(JSON.stringify({alg:"none",type:"JWT"})),l(JSON.stringify(t)),""].join(".")}(n.mockUserToken,null===(i=t._app)||void 0===i?void 0:i.options.projectId);
1if(!(n=n.mockUserToken.sub||n.mockUserToken.user_id))throw new Ln(On.INVALID_ARGUMENT,"mockUserToken must contain 'sub' or 'user_id' field!");r=new Ec(n)}t._credentials=new Cp(new wp(o,r))}}(this._delegate,t,e,i=void 0===i?{}:i)},_m.prototype.enableNetwork=function(){return function(r){var t=this;return r.asyncQueue.enqueue(function(){return g(t,void 0,void 0,function(){var i,n;return m(this,function(t){switch(t.label){case 0:return[4,pp(r)];case 1:return i=t.sent(),[4,gp(r)];case 2:return n=t.sent(),[2,(i.setNetworkEnabled(!0),(e=n).Or.delete(0),Ah(e))]}var e})})})}(pf(jp(this._delegate,cf)))},_m.prototype.disableNetwork=function(){return function(n){var t=this;return n.asyncQueue.enqueue(function(){return g(t,void 0,void 0,function(){var e,i;return m(this,function(t){switch(t.label){case 0:return[4,pp(n)];case 1:return e=t.sent(),[4,gp(n)];case 2:return i=t.sent(),[2,(e.setNetworkEnabled(!1),function(i){return g(this,void 0,void 0,function(){var e;return m(this,function(t){switch(t.label){case 0:return(e=i).Or.add(0),[4,Ph(e)];case 1:return t.sent(),e.Br.set("Offline"),[2]}})})}(i))]}})})})}(pf(jp(this._delegate,cf)))},_m.prototype.enablePersistence=function(t){var e=!1,i=!1;return t&&Fp("synchronizeTabs",e=!!t.synchronizeTabs,"experimentalForceOwningTab",i=!!t.experimentalForceOwningTab),e?this.Zc.enableMultiTabIndexedDbPersistence(this):this.Zc.enableIndexedDbPersistence(this,i)},_m.prototype.clearPersistence=function(){return this.Zc.clearIndexedDbPersistence(this)},_m.prototype.terminate=function(){return this.tu&&(this.tu._removeServiceInstance("firestore"),this.tu._removeServiceInstance("firestore-exp")),this._delegate._delete()},_m.prototype.waitForPendingWrites=function(){return function(i){var t=this,n=new sl;return i.asyncQueue.enqueueAndForget(function(){return g(t,void 0,void 0,function(){var e;return m(this,function(t){switch(t.label){case 0:return e=Dd,[4,mp(i)];case 1:return[2,e.apply(void 0,[t.sent(),n])]}})})}),n.promise}(pf(jp(this._delegate,cf)))},_m.prototype.onSnapshotsInSync=function(t){return t=t,function(i,t){var e=this,n=new Zd(t);return i.asyncQueue.enqueueAndForget(function(){return g(e,void 0,void 0,function(){var e;return m(this,function(t){switch(t.label){case 0:return e=function(t,e){t.Gr.add(e),e.next()},[4,vp(i)];case 1:return[2,e.apply(void 0,[t.sent(),n])]}})})}),function(){n.Wo(),i.asyncQueue.enqueueAndForget(function(){return g(e,void 0,void 0,function(){var e;return m(this,function(t){switch(t.label){case 0:return e=function(t,e){t.Gr.delete(e)},[4,vp(i)];case 1:return[2,e.apply(void 0,[t.sent(),n])]}})})})}}(pf(jp(this._delegate,cf)),af(t)?t:{next:t})},Object.defineProperty(_m.prototype,"app",{get:function(){if(!this.tu)throw new Ln(On.FAILED_PRECONDITION,"Firestore was not initialized using the Firebase SDK. 'app' is not available");return this.tu},enumerable:!1,configurable:!0}),_m.prototype.collection=function(t){try{return new Hm(this,tf(this._delegate,t))}catch(t){throw Mm(t,"collection()","Firestore.collection()")}},_m.prototype.doc=function(t){try{return new Am(this,ef(this._delegate,t))}catch(t){throw Mm(t,"doc()","Firestore.doc()")}},_m.prototype.collectionGroup=function(t){try{return new Bm(this,function(t,e){if(t=jp(t,Up),Lp("collectionGroup","collection id",e),0<=e.indexOf("/"))throw new Ln(On.INVALID_ARGUMENT,"Invalid collection ID '"+e+"' passed to function collectionGroup(). Collection IDs must not contain '/'.");return new Kp(t,null,(e=e,new Ss(sr.emptyPath(),e)))}(this._delegate,t))}catch(t){throw Mm(t,"collectionGroup()","Firestore.collectionGroup()")}},_m.prototype.runTransaction=function(e){var i,n=this;return function(i,n){var t=this,r=new sl;return i.asyncQueue.enqueueAndForget(function(){return g(t,void 0,void 0,function(){var e;return m(this,function(t){switch(t.label){case 0:return[4,dp(i).then(function(t){return t.datastore})];case 1:return e=t.sent(),new ip(i.asyncQueue,e,n,r).run(),[2]}})})}),r.promise}(pf(i=this._delegate),function(t){return t=new cm(i,t),e(new Sm(n,t))})},_m.prototype.batch=function(){var e=this;return pf(this._delegate),new Cm(new Jg(this._delegate,function(t){return am(e._delegate,t)}))},_m.prototype.loadBundle=function(t){throw new Ln(On.FAILED_PRECONDITION,'"loadBundle()" does not exist, have you imported "firebase/firestore/bundle"?')},_m.prototype.namedQuery=function(t){throw new Ln(On.FAILED_PRECONDITION,'"named
1Query()" does not exist, have you imported "firebase/firestore/bundle"?')},_m),bm=(i(wm,gm=C),wm.prototype.convertBytes=function(t){return new mm(new yf(t))},wm.prototype.convertReference=function(t){return t=this.convertDocumentKey(t,this.firestore._databaseId),Am.eu(t,this.firestore,null)},wm);function wm(t){var e=this;return(e=gm.call(this)||this).firestore=t,e}function _m(t,e,i){var n=this;this._delegate=e,this.Zc=i,this.INTERNAL={delete:function(){return n.terminate()}},t instanceof xp||(this.tu=t)}function xm(){}function Tm(t){this._delegate=t}var Sm=(Dm.prototype.get=function(t){var e=this,i=Ym(t);return this._delegate.get(i).then(function(t){return new Fm(e._firestore,new bg(e._firestore._delegate,e._userDataWriter,t._key,t._document,t.metadata,i.converter))})},Dm.prototype.set=function(t,e,i){return t=Ym(t),i?(Rp("Transaction.set",i),this._delegate.set(t,e,i)):this._delegate.set(t,e),this},Dm.prototype.update=function(t,e,i){for(var n=[],r=3;r<arguments.length;r++)n[r-3]=arguments[r];var s=Ym(t);return 2===arguments.length?this._delegate.update(s,e):(t=this._delegate).update.apply(t,o([s,e,i],n)),this},Dm.prototype.delete=function(t){return t=Ym(t),this._delegate.delete(t),this},Dm),Cm=(Im.prototype.set=function(t,e,i){return t=Ym(t),i?(Rp("WriteBatch.set",i),this._delegate.set(t,e,i)):this._delegate.set(t,e),this},Im.prototype.update=function(t,e,i){for(var n=[],r=3;r<arguments.length;r++)n[r-3]=arguments[r];var s=Ym(t);return 2===arguments.length?this._delegate.update(s,e):(t=this._delegate).update.apply(t,o([s,e,i],n)),this},Im.prototype.delete=function(t){return t=Ym(t),this._delegate.delete(t),this},Im.prototype.commit=function(){return this._delegate.commit()},Im),Em=(km.prototype.fromFirestore=function(t,e){return t=new wg(this._firestore._delegate,this._userDataWriter,t._key,t._document,t.metadata,null),this._delegate.fromFirestore(new zm(this._firestore,t),null!=e?e:{})},km.prototype.toFirestore=function(t,e){return e?this._delegate.toFirestore(t,e):this._delegate.toFirestore(t)},km.nu=function(t,e){var i=km.su,n=i.get(t);return n||(n=new WeakMap,i.set(t,n)),(i=n.get(e))||(i=new km(t,new bm(t),e),n.set(e,i)),i},km);function km(t,e,i){this._firestore=t,this._userDataWriter=e,this._delegate=i}function Im(t){this._delegate=t}function Dm(t,e){this._firestore=t,this._delegate=e,this._userDataWriter=new bm(t)}Em.su=new WeakMap;var Am=(Pm.iu=function(t,e,i){if(t.length%2!=0)throw new Ln(On.INVALID_ARGUMENT,"Invalid document reference. Document references must have an even number of segments, but "+t.canonicalString()+" has "+t.length);return new Pm(e,new Wp(e._delegate,i,new Sr(t)))},Pm.eu=function(t,e,i){return new Pm(e,new Wp(e._delegate,i,t))},Object.defineProperty(Pm.prototype,"id",{get:function(){return this._delegate.id},enumerable:!1,configurable:!0}),Object.defineProperty(Pm.prototype,"parent",{get:function(){return new Hm(this.firestore,this._delegate.parent)},enumerable:!1,configurable:!0}),Object.defineProperty(Pm.prototype,"path",{get:function(){return this._delegate.path},enumerable:!1,configurable:!0}),Pm.prototype.collection=function(t){try{return new Hm(this.firestore,tf(this._delegate,t))}catch(t){throw Mm(t,"collection()","DocumentReference.collection()")}},Pm.prototype.isEqual=function(t){return(t=w(t))instanceof Wp&&nf(this._delegate,t)},Pm.prototype.set=function(t,e){e=Rp("DocumentReference.set",e);try{return function(t,e,i){var n=jp((t=jp(t,Wp)).firestore,cf);e=Yg(t.converter,e,i);return am(n,[Lf(Of(n),"setDoc",t._key,e,null!==t.converter,i).toMutation(t._key,lo.none())])}(this._delegate,t,e)}catch(t){throw Mm(t,"setDoc()","DocumentReference.set()")}},Pm.prototype.update=function(t,e){for(var i=[],n=2;n<arguments.length;n++)i[n-2]=arguments[n];try{return 1===arguments.length?sm(this._delegate,t):sm.apply(void 0,o([this._delegate,t,e],i))}catch(t){throw Mm(t,"updateDoc()","DocumentReference.update()")}},Pm.prototype.delete=function(){return am(jp((t=this._delegate).firestore,cf),[new Io(t._key,lo.none())]);var t},Pm.prototype.onSnapshot=function(){for(var e=this,t=[],i=0;i<arguments.length;i++)t[i]=arguments[i];
1var n=Nm(t),r=Om(t,function(t){return new Fm(e.firestore,new bg(e.firestore._delegate,e._userDataWriter,t._key,t._document,t.metadata,e._delegate.converter))});return om(this._delegate,n,r)},Pm.prototype.get=function(t){var e=this;return("cache"===(null==t?void 0:t.source)?function(e){var i=jp((e=jp(e,Wp)).firestore,cf),t=pf(i),n=new nm(i);return function(i,n){var t=this,r=new sl;return i.asyncQueue.enqueueAndForget(function(){return g(t,void 0,void 0,function(){var e;return m(this,function(t){switch(t.label){case 0:return e=function(s,o,a){return g(this,void 0,void 0,function(){var n,r;return m(this,function(t){switch(t.label){case 0:return t.trys.push([0,2,,3]),[4,(e=o,(i=s).persistence.runTransaction("read document","readonly",function(t){return i.Mn.mn(t,e)}))];case 1:return(r=t.sent()).isFoundDocument()?a.resolve(r):r.isNoDocument()?a.resolve(null):a.reject(new Ln(On.UNAVAILABLE,"Failed to get document from cache. (However, this document may exist on the server. Run again without setting 'source' in the GetOptions to attempt to retrieve the document from the server.)")),[3,3];case 2:return n=t.sent(),r=Xh(n,"Failed to get document '"+o+" from cache"),a.reject(r),[3,3];case 3:return[2]}var e,i})})},[4,fp(i)];case 1:return[2,e.apply(void 0,[t.sent(),n,r])]}})})}),r.promise}(t,e._key).then(function(t){return new bg(i,n,e._key,t,new yg(null!==t&&t.hasLocalMutations,!0),e.converter)})}:"server"===(null==t?void 0:t.source)?function(e){var i=jp((e=jp(e,Wp)).firestore,cf);return yp(pf(i),e._key,{source:"server"}).then(function(t){return lm(i,e,t)})}:function(e){var i=jp((e=jp(e,Wp)).firestore,cf);return yp(pf(i),e._key).then(function(t){return lm(i,e,t)})})(this._delegate).then(function(t){return new Fm(e.firestore,new bg(e.firestore._delegate,e._userDataWriter,t._key,t._document,t.metadata,e._delegate.converter))})},Pm.prototype.withConverter=function(t){return new Pm(this.firestore,t?this._delegate.withConverter(Em.nu(this.firestore,t)):this._delegate.withConverter(null))},Pm);function Pm(t,e){this.firestore=t,this._delegate=e,this._userDataWriter=new bm(t)}function Mm(t,e,i){return t.message=t.message.replace(e,i),t}function Nm(t){for(var e=0,i=t;e<i.length;e++){var n=i[e];if("object"==typeof n&&!af(n))return n}return{}}function Om(t,e){var i;return{next:function(t){i.next&&i.next(e(t))},error:null===(t=(i=af(t[0])?t[0]:af(t[1])?t[1]:"function"==typeof t[0]?{next:t[0],error:t[1],complete:t[2]}:{next:t[1],error:t[2],complete:t[3]}).error)||void 0===t?void 0:t.bind(i),complete:null===(t=i.complete)||void 0===t?void 0:t.bind(i)}}var Lm,Rm,Fm=(Object.defineProperty(Gm.prototype,"ref",{get:function(){return new Am(this._firestore,this._delegate.ref)},enumerable:!1,configurable:!0}),Object.defineProperty(Gm.prototype,"id",{get:function(){return this._delegate.id},enumerable:!1,configurable:!0}),Object.defineProperty(Gm.prototype,"metadata",{get:function(){return this._delegate.metadata},enumerable:!1,configurable:!0}),Object.defineProperty(Gm.prototype,"exists",{get:function(){return this._delegate.exists()},enumerable:!1,configurable:!0}),Gm.prototype.data=function(t){return this._delegate.data(t)},Gm.prototype.get=function(t,e){return this._delegate.get(t,e)},Gm.prototype.isEqual=function(t){return Eg(this._delegate,t._delegate)},Gm),zm=(i(Km,Rm=Fm),Km.prototype.data=function(t){return this._delegate.data(t)},Km),Bm=(Wm.prototype.where=function(t,e,i){try{return new Wm(this.firestore,Ig(this._delegate,(n=i,r=e,s=gg("where",t),new Og(s,r,n))))}catch(t){throw Mm(t,/(orderBy|where)\(\)/,"Query.$1()")}var n,r,s},Wm.prototype.orderBy=function(t,e){try{return new Wm(this.firestore,Ig(this._delegate,(i=void 0===e?"asc":e,n=gg("orderBy",t),new Lg(n,i))))}catch(t){throw Mm(t,/(orderBy|where)\(\)/,"Query.$1()")}var i,n},Wm.prototype.limit=function(t){try{return new Wm(this.firestore,Ig(this._delegate,(Hp("limit",e=t),new Rg("limit",e,"F"))))}catch(t){throw Mm(t,"limit()","Query.limit()")}var e},Wm.prototype.limitToLast=function(t){try{return new Wm(this.firestore,Ig(this._delegate,(Hp("limitToLast",e=t),new Rg("limitToLast",e,"L"))))}catch(t){throw Mm(t,"limitToLast()","Query.limitToLast()")}var e},Wm.prototype.startAt=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];try{return new Wm(this.firestore,Ig(this._delegate,function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return new Fg("startAt",t,!0)}.apply(void 0,t)))}catch(t){throw Mm(t,"startAt()","Query.startAt()")}},Wm.prototype.startAfter=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];try{return new Wm(this.firestore,Ig(this._delegate,function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return new Fg("startAfter",t,!1)}.apply(void 0,t)))}catch(t){throw Mm(t,"startAfter()","Query.startAfter()")}},Wm.prototype.endBefore=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];try{return new Wm(this.firestore,Ig(this._delegate,function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return new zg("endBefore",t,!0)}.apply(void 0,t)))}catch(t){throw Mm(t,"endBefore()","Query.endBefore()")}},Wm.prototype.endAt=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];try{return new Wm(this.firestore,Ig(this._delegate,function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return new zg("endAt",t,!1)}.apply(void 0,t)))}catch(t){throw Mm(t,"endAt()","Query.endAt()")}},Wm.prototype.isEqual=function(t){return rf(this._delegate,t._delegate)},Wm.prototype.get=function(t){var e=this;
1return("cache"===(null==t?void 0:t.source)?function(e){var i=jp((e=jp(e,Kp)).firestore,cf),t=pf(i),n=new nm(i);return function(i,n){var t=this,r=new sl;return i.asyncQueue.enqueueAndForget(function(){return g(t,void 0,void 0,function(){var e;return m(this,function(t){switch(t.label){case 0:return e=function(r,s,o){return g(this,void 0,void 0,function(){var e,i,n;return m(this,function(t){switch(t.label){case 0:return t.trys.push([0,2,,3]),[4,hc(r,s,!0)];case 1:return n=t.sent(),e=new bd(s,n.Bn),i=e._o(n.documents),i=e.applyChanges(i,!1),o.resolve(i.snapshot),[3,3];case 2:return i=t.sent(),n=Xh(i,"Failed to execute query '"+s+" against cache"),o.reject(n),[3,3];case 3:return[2]}})})},[4,fp(i)];case 1:return[2,e.apply(void 0,[t.sent(),n,r])]}})})}),r.promise}(t,e._query).then(function(t){return new _g(i,n,e,t)})}:"server"===(null==t?void 0:t.source)?function(e){var i=jp((e=jp(e,Kp)).firestore,cf),t=pf(i),n=new nm(i);return bp(t,e._query,{source:"server"}).then(function(t){return new _g(i,n,e,t)})}:function(e){var i=jp((e=jp(e,Kp)).firestore,cf),t=pf(i),n=new nm(i);return kg(e._query),bp(t,e._query).then(function(t){return new _g(i,n,e,t)})})(this._delegate).then(function(t){return new jm(e.firestore,new _g(e.firestore._delegate,e._userDataWriter,e._delegate,t._snapshot))})},Wm.prototype.onSnapshot=function(){for(var e=this,t=[],i=0;i<arguments.length;i++)t[i]=arguments[i];var n=Nm(t),r=Om(t,function(t){return new jm(e.firestore,new _g(e.firestore._delegate,e._userDataWriter,e._delegate,t._snapshot))});return om(this._delegate,n,r)},Wm.prototype.withConverter=function(t){return new Wm(this.firestore,t?this._delegate.withConverter(Em.nu(this.firestore,t)):this._delegate.withConverter(null))},Wm),$m=(Object.defineProperty(Um.prototype,"type",{get:function(){return this._delegate.type},enumerable:!1,configurable:!0}),Object.defineProperty(Um.prototype,"doc",{get:function(){return new zm(this._firestore,this._delegate.doc)},enumerable:!1,configurable:!0}),Object.defineProperty(Um.prototype,"oldIndex",{get:function(){return this._delegate.oldIndex},enumerable:!1,configurable:!0}),Object.defineProperty(Um.prototype,"newIndex",{get:function(){return this._delegate.newIndex},enumerable:!1,configurable:!0}),Um),jm=(Object.defineProperty(Vm.prototype,"query",{get:function(){return new Bm(this._firestore,this._delegate.query)},enumerable:!1,configurable:!0}),Object.defineProperty(Vm.prototype,"metadata",{get:function(){return this._delegate.metadata},enumerable:!1,configurable:!0}),Object.defineProperty(Vm.prototype,"size",{get:function(){return this._delegate.size},enumerable:!1,configurable:!0}),Object.defineProperty(Vm.prototype,"empty",{get:function(){return this._delegate.empty},enumerable:!1,configurable:!0}),Object.defineProperty(Vm.prototype,"docs",{get:function(){var e=this;return this._delegate.docs.map(function(t){return new zm(e._firestore,t)})},enumerable:!1,configurable:!0}),Vm.prototype.docChanges=function(t){var e=this;return this._delegate.docChanges(t).map(function(t){return new $m(e._firestore,t)})},Vm.prototype.forEach=function(e,i){var n=this;this._delegate.forEach(function(t){e.call(i,new zm(n._firestore,t))})},Vm.prototype.isEqual=function(t){return Eg(this._delegate,t._delegate)},Vm),Hm=(i(qm,Lm=Bm),Object.defineProperty(qm.prototype,"id",{get:function(){return this._delegate.id},enumerable:!1,configurable:!0}),Object.defineProperty(qm.prototype,"path",{get:function(){return this._delegate.path},enumerable:!1,configurable:!0}),Object.defineProperty(qm.prototype,"parent",{get:function(){var t=this._delegate.parent;return t?new Am(this.firestore,t):null},enumerable:!1,configurable:!0}),qm.prototype.doc=function(t){try{return new Am(this.firestore,void 0===t?ef(this._delegate):ef(this._delegate,t))}catch(t){throw Mm(t,"doc()","CollectionReference.doc()")}},qm.prototype.add=function(t){var e,i,n,r=this;return i=t,t=jp((e=this._delegate).firestore,cf),n=ef(e),i=Yg(e.converter,i),am(t,[Lf(Of(e.firestore),"addDoc",n._key,i,null!==e.converter,{}).toMutation(n._key,lo.exists(!1))]).then(function(){return n}).then(function(t){return new Am(r.firestore,t)})},qm.prototype.isEqual=function(t){return nf(this._delegate,t._delegate)},qm.prototype.withConverter=function(t){return new qm(this.firestore,t?this._delegate.withConverter(Em.nu(this.firestore,t)):this._delegate.withConverter(null))},qm);function qm(t,e){var i=this;return(i=Lm.call(this,t,e)||this).firestore=t,i._delegate=e,i}function Vm(t,e){this._firestore=t,this._delegate=e}function Um(t,e){this._firestore=t,this._delegate=e}function Wm(t,e){this.firestore=t,this._delegate=e,this._userDataWriter=new bm(t)}function Km(){return null!==Rm&&Rm.apply(this,arguments)||this}function Gm(t,e){this._firestore=t,this._delegate=e}function Ym(t){return jp(t,Wp)}function Xm(t){this._delegate=t}function Qm(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];this._delegate=new(vf.bind.apply(vf,o([void 0],t)))}Qm.documentId=function(){return new Qm(ar.keyField().canonicalString())},Qm.prototype.isEqual=function(t){return(t=w(t))instanceof vf&&this._delegate._internalPath.isEqual(t._internalPath)},A=Qm,Xm.serverTimestamp=function(){var t=new Vf("serverTimestamp");return t._methodName="FieldValue.serverTimestamp",new Xm(t)},Xm.delete=function(){var t=new Ff("deleteField");return t._methodName="FieldValue.delete",new Xm(t)},Xm.arrayUnion=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];var i=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return new Uf("arrayUnion",t)}.apply(void 0,t);return i._methodName="FieldValue.arrayUnion",new Xm(i)},Xm.arrayRemove=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];var i=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return new Wf("arrayRemove",t)}.apply(void 0,t);return i._methodName="FieldValue.arrayRemove",new Xm(i)},Xm.increment=function(t){return(t=new Kf("increment",t))._methodName="FieldValue.increment",new Xm(t)},Xm.prototype.isEqual=function(t){return this._delegate.isEqual(t._delegate)},C=Xm;var Jm=(Zm.prototype.setInstantiationMode=function(t){return this.instantiationMode=t,this},Zm.prototype.setMultipleInstances=function(t){return this.multipleInstances=t,this},Zm.prototype.setServiceProps=function(t){return this.serviceProps=t,this},Zm.prototype.setInstanceCreatedCallback=function(t){return this.onInstanceCreated=t,this},Zm);function Zm(t,e,i){this.name=t,this.instanceFactory=e,this.type=i,this.multipleInstances=!1,this.serviceProps={},this.instantiationMode="LAZY",this.onInstanceCreated=null}var tv,ev,iv={Firestore:ym,GeoPoint:wf,Timestamp:Xn,Blob:mm,Transaction:Sm,WriteBatch:Cm,DocumentReference:Am,DocumentSnapshot:Fm,Query:Bm,QueryDocumentSnapshot:zm,QuerySnapsh
1ot:jm,CollectionReference:Hm,FieldPath:A,FieldValue:C,setLogLevel:function(t){Rn.setLogLevel(t)},CACHE_SIZE_UNLIMITED:-1};(tv=e.default).INTERNAL.registerComponent(new Jm("firestore",function(t){var e=t.getProvider("app").getImmediate();return e=e,t=t.getProvider("auth-internal"),new ym(e,new cf(e,t),new vm)},"PUBLIC").setServiceProps(Object.assign({},iv))),tv.registerVersion("@firebase/firestore","2.4.0"),(ev=ym).prototype.loadBundle=function(t){return e=this._delegate,o=t,i=pf(e=jp(e,cf)),t=new uf,function(i,t,n){var e,r=this,s=(e=o,t=fh(t),e=function(t){if(t instanceof Uint8Array)return Jd(t,void 0);if(t instanceof ArrayBuffer)return Jd(new Uint8Array(t),void 0);if(t instanceof ReadableStream)return t.getReader();throw new Error("Source of `toByteStreamReader` has to be a ArrayBuffer or ReadableStream")}("string"==typeof e?(new TextEncoder).encode(e):e),new tp(e,t));i.asyncQueue.enqueueAndForget(function(){return g(r,void 0,void 0,function(){var e;return m(this,function(t){switch(t.label){case 0:return e=jd,[4,mp(i)];case 1:return e.apply(void 0,[t.sent(),s,n]),[2]}})})})}(i,e._databaseId,t),t;var e,o,i},ev.prototype.namedQuery=function(t){var e=this,i=this._delegate;return t=t,function(i,n){var t=this;return i.asyncQueue.enqueue(function(){return g(t,void 0,void 0,function(){var e;return m(this,function(t){switch(t.label){case 0:return e=function(t,e){var i=t;return i.persistence.runTransaction("Get named query","readonly",function(t){return i.Ke.getNamedQuery(t,e)})},[4,fp(i)];case 1:return[2,e.apply(void 0,[t.sent(),n])]}})})})}(pf(i=jp(i,cf)),t).then(function(t){return t?new Kp(i,null,t.query):null}).then(function(t){return t?new Bm(e,t):null})}}).apply(this,arguments)}catch(t){throw console.error(t),new Error("Cannot instantiate firebase-firestore.js - be sure to load firebase-app.js first.")}}),function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(require("@firebase/app")):"function"==typeof define&&define.amd?define(["@firebase/app"],e):e((t="undefined"!=typeof globalThis?globalThis:t||self).firebase)}(this,function(Qt){"use strict";try{(function(){var t,e=(t=Qt)&&"object"==typeof t&&"default"in t?t:{default:t},n=function(t,e){return(n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,e){t.__proto__=e}||function(t,e){for(var i in e)Object.prototype.hasOwnProperty.call(e,i)&&(t[i]=e[i])})(t,e)},p=function(){return(p=Object.assign||function(t){for(var e,i=1,n=arguments.length;i<n;i++)for(var r in e=arguments[i])Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}).apply(this,arguments)};function h(t,o,a,l){return new(a=a||Promise)(function(i,e){function n(t){try{s(l.next(t))}catch(t){e(t)}}function r(t){try{s(l.throw(t))}catch(t){e(t)}}function s(t){var e;t.done?i(t.value):((e=t.value)instanceof a?e:new a(function(t){t(e)})).then(n,r)}s((l=l.apply(t,o||[])).next())})}function f(i,n){var r,s,o,a={label:0,sent:function(){if(1&o[0])throw o[1];return o[1]},trys:[],ops:[]},t={next:e(0),throw:e(1),return:e(2)};return"function"==typeof Symbol&&(t[Symbol.iterator]=function(){return this}),t;function e(e){return function(t){return function(e){if(r)throw new TypeError("Generator is already executing.");for(;a;)try{if(r=1,s&&(o=2&e[0]?s.return:e[0]?s.throw||((o=s.return)&&o.call(s),0):s.next)&&!(o=o.call(s,e[1])).done)return o;switch(s=0,(e=o?[2&e[0],o.value]:e)[0]){case 0:case 1:o=e;break;case 4:return a.label++,{value:e[1],done:!1};case 5:a.label++,s=e[1],e=[0];continue;case 7:e=a.ops.pop(),a.trys.pop();continue;default:if(!(o=0<(o=a.trys).length&&o[o.length-1])&&(6===e[0]||2===e[0])){a=0;continue}if(3===e[0]&&(!o||e[1]>o[0]&&e[1]<o[3])){a.label=e[1];break}if(6===e[0]&&a.label<o[1]){a.label=o[1],o=e;break}if(o&&a.label<o[2]){a.label=o[2],a.ops.push(e);break}o[2]&&a.ops.pop(),a.trys.pop();continue}e=n.call(i,a)}catch(t){e=[6,t],s=0}finally{r=o=0}if(5&e[0])throw e[1];return{value:e[0]?e[1]:void 0,done:!0}}([e,t])}}}function g(t){var e="function"==typeof Symbol&&Symbol.iterator,i=e&&t[e],n=0;if(i)return i.call(t);if(t&&"number"==typeof t.length)return{next:function(){return{value:(t=t&&n>=t.length?void 0:t)&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")}function s(t,e){var i="function"==typeof Symbol&&t[Symbol.iterator];if(!i)return t;var n,r,s=i.call(t),o=[];try{for(;(void 0===e||0<e--)&&!(n=s.next()).done;)o.push(n.value)}catch(t){r={error:t}}finally{try{n&&!n.done&&(i=s.return)&&i.call(s)}finally{if(r)throw r.error}}return o}function o(t,e){for(var i=0,n=e.length,r=t.length;i<n;i++,r++)t[r]=e[i];return t}var r,a="FirebaseError",l=(function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Class extends value "+String(e)+" is not a constructor or null");function i(){this.constructor=t}n(t,e),t.prototype=null===e?Object.create(e):(i.prototype=e.prototype,new i)}(u,r=Error),u);function u(t,e,i){return(e=r.call(this,e)||this).code=t,e.customData=i,e.name=a,Object.setPrototypeOf(e,u.prototype),Error.captureStackTrace&&Error.captureStackTrace(e,c.prototype.create),e}var c=(i.prototype.create=function(t){for(var e=[],i=1;i<arguments.length;i++)e[i-1]=arguments[i];var n,r=e[0]||{},s=this.service+"/"+t;t=(t=this.errors[t])?(n=r,t.replace(d,function(t,e){var i=n[e];return null!=i?String(i):"<"+e+"?>"})):"Error",t=this.serviceName+": "+t+" ("+s+").";return new l(s,t,r)},i);function i(t,e,i){this.service=t,this.serviceName=e,this.errors=i}var d=/\{\$([^}]+)}/g,m=(v.prototype.setInstantiationMode=function(t){return this.instantiationMode=t,this},v.prototype.setMultipleInstances=function(t){return this.multipleInstances=t,this},v.prototype.setServiceProps=function(t){return this.serviceProps=t,this},v.prototype.setInstanceCreatedCallback=function(t){return this.onInstanceCreated=t,this},v);function v(t,e,i){this.name=t,this.instanceFactory=e,this.type=i,this.multipleInstances=!1,this.serviceProps={},this.instantiationMode="LAZY",this.onInstanceCreated=null}function y(i){return new Promise(function(t,e){i.onsuccess=function(){t(i.result)},i.onerror=function(){e(i.error)}})}function b(i,n,r){var s,t=new Promise(function(t,e){y(s=i[n].apply(i,r)).then(t,e)});return t.request=s,t}function w(t,i,e){e.forEach(function(e){Object.defineProperty(t.prototype,e,{get:function(){return this[i][e]},set:function(t){this[i][e]=t}})})}function _(e,i,n,t){t.forEach(function(t){t in n.prototype&&(e.prototype[t]=function(){return b(this[i],t,arguments)})})}function x(e,i,n,t){t.forEach(function(t){t in n.prototype&&(e.prototype[t]=function(){return this[i][t].apply(this[i],arguments)})})}
1function T(t,n,e,i){i.forEach(function(i){i in e.prototype&&(t.prototype[i]=function(){return t=this[n],(e=b(t,i,arguments)).then(function(t){if(t)return new C(t,e.request)});var t,e})})}function S(t){this._index=t}function C(t,e){this._cursor=t,this._request=e}function E(t){this._store=t}function k(i){this._tx=i,this.complete=new Promise(function(t,e){i.oncomplete=function(){t()},i.onerror=function(){e(i.error)},i.onabort=function(){e(i.error)}})}function I(t,e,i){this._db=t,this.oldVersion=e,this.transaction=new k(i)}function D(t){this._db=t}function A(t,e,i){var n=(e=b(indexedDB,"open",[t,e])).request;return n&&(n.onupgradeneeded=function(t){i&&i(new I(n.result,t.oldVersion,n.transaction))}),e.then(function(t){return new D(t)})}function P(t){return b(indexedDB,"deleteDatabase",[t])}w(S,"_index",["name","keyPath","multiEntry","unique"]),_(S,"_index",IDBIndex,["get","getKey","getAll","getAllKeys","count"]),T(S,"_index",IDBIndex,["openCursor","openKeyCursor"]),w(C,"_cursor",["direction","key","primaryKey","value"]),_(C,"_cursor",IDBCursor,["update","delete"]),["advance","continue","continuePrimaryKey"].forEach(function(i){i in IDBCursor.prototype&&(C.prototype[i]=function(){var e=this,t=arguments;return Promise.resolve().then(function(){return e._cursor[i].apply(e._cursor,t),y(e._request).then(function(t){if(t)return new C(t,e._request)})})})}),E.prototype.createIndex=function(){return new S(this._store.createIndex.apply(this._store,arguments))},E.prototype.index=function(){return new S(this._store.index.apply(this._store,arguments))},w(E,"_store",["name","keyPath","indexNames","autoIncrement"]),_(E,"_store",IDBObjectStore,["put","add","delete","clear","get","getAll","getKey","getAllKeys","count"]),T(E,"_store",IDBObjectStore,["openCursor","o
1penKeyCursor"]),x(E,"_store",IDBObjectStore,["deleteIndex"]),k.prototype.objectStore=function(){return new E(this._tx.objectStore.apply(this._tx,arguments))},w(k,"_tx",["objectStoreNames","mode"]),x(k,"_tx",IDBTransaction,["abort"]),I.prototype.createObjectStore=function(){return new E(this._db.createObjectStore.apply(this._db,arguments))},w(I,"_db",["name","version","objectStoreNames"]),x(I,"_db",IDBDatabase,["deleteObjectStore","close"]),D.prototype.transaction=function(){return new k(this._db.transaction.apply(this._db,arguments))},w(D,"_db",["name","version","objectStoreNames"]),x(D,"_db",IDBDatabase,["close"]),["openCursor","openKeyCursor"].forEach(function(r){[E,S].forEach(function(t){r in t.prototype&&(t.prototype[r.replace("open","iterate")]=function(){var t=(i=arguments,Array.prototype.slice.call(i)),e=t[t.length-1],i=this._store||this._index,n=i[r].apply(i,t.slice(0,-1));n.onsuccess=function(){e(n.result)}})})}),[S,E].forEach(function(t){t.prototype.getAll||(t.prototype.getAll=function(t,i){var n=this,r=[];return new Promise(function(e){n.iterateCursor(t,function(t){t?(r.push(t.value),void 0===i||r.length!=i?t.continue():e(r)):e(r)})})})});var M=1e4,N="w:0.4.32",O="FIS_v2",L="https://firebaseinstallations.googleapis.com/v1",R=36e5,F=((F={})["missing-app-config-values"]='Missing App configuration value: "{$valueName}"',F["not-registered"]="Firebase Installation is not registered.",F["installation-not-found"]="Firebase Installation not found.",F["request-failed"]='{$requestName} request failed with error "{$serverCode} {$serverStatus}: {$serverMessage}"',F["app-offline"]="Could not process request. Application offline.",F["delete-pending-registration"]="Can't delete installation while there is a pending registration request.",F),z=new c("installations","Installations",F);function B(t){return t instanceof l&&t.code.includes("request-failed")}function $(t){return t=t.projectId,L+"/projects/"+t+"/installations"}function j(t){return{token:t.token,requestStatus:2,expiresIn:(t=t.expiresIn,Number(t.replace("s","000"))),creationTime:Date.now()}}function H(i,n){return h(this,void 0,void 0,function(){var e;return f(this,function(t){switch(t.label){case 0:return[4,n.json()];case 1:return e=(e=t.sent()).error,[2,z.create("request-failed",{requestName:i,serverCode:e.code,serverMessage:e.message,serverStatus:e.status})]}})})}function q(t){return t=t.apiKey,new Headers({"Content-Type":"application/json",Accept:"application/json","x-goog-api-key":t})}function V(t,e){return e=e.refreshToken,(t=q(t)).append("Authorization",O+" "+e),t}function U(i){return h(this,void 0,void 0,function(){var e;return f(this,function(t){switch(t.label){case 0:return[4,i()];case 1:return 500<=(e=t.sent()).status&&e.status<600?[2,i()]:[2,e]}})})}function W(e){return new Promise(function(t){setTimeout(t,e)})}var K=/^[cdef][\w-]{21}$/,G="";function Y(t){return t.appName+"!"+t.appId}var X=new Map;function Q(t,e){var i,n,r;J(t=Y(t),e),i=t,n=e,(r=tt())&&r.postMessage({key:i,fid:n}),et()}function J(t,e){var i,n;if(t=X.get(t))try{for(var r=g(t),s=r.next();!s.done;s=r.next())(0,s.value)(e)}catch(t){i={error:t}}finally{try{s&&!s.done&&(n=r.return)&&n.call(r)}finally{if(i)throw i.error}}}var Z=null;function tt(){return!Z&&"BroadcastChannel"in self&&((Z=new BroadcastChannel("[Firebase] FID Change")).onmessage=function(t){J(t.data.key,t.data.fid)}),Z}function et(){0===X.size&&Z&&(Z.close(),Z=null)}var it,nt="firebase-installations-database",rt=1,st="firebase-installations-store",ot=null;function at(){return ot=ot||A(nt,rt,function(t){0===t.oldVersion&&t.createObjectStore(st)})}function lt(s,o){return h(this,void 0,void 0,function(){var e,i,n,r;return f(this,function(t){switch(t.label){case 0:return e=Y(s),[4,at()];case 1:return n=t.sent(),[4,(n=(i=n.transaction(st,"readwrite")).objectStore(st)).get(e)];case 2:return r=t.sent(),[4,n.put(o,e)];case 3:return t.sent(),[4,i.complete];case 4:return t.sent(),r&&r.fid===o.fid||Q(s,o.fid),[2,o]}})})}function ut(n){return h(this,void 0,void 0,function(){var e,i;return f(this,function(t){switch(t.label){case 0:return e=Y(n),[4,at()];case 1:return[4,(i=(i=t.sent()).transaction(st,"readwrite")).objectStore(st).delete(e)];case 2:return t.sent(),[4,i.complete];case 3:return t.sent(),[2]}})})}function ct(o,a){return h(this,void 0,void 0,function(){var e,i,n,r,s;return f(this,function(t){switch(t.label){case 0:return e=Y(o),[4,at()];case 1:return n=t.sent(),[4,(n=(i=n.transaction(st,"readwrite")).objectStore(st)).get(e)];case 2:return r=t.sent(),void 0!==(s=a(r))?[3,4]:[4,n.delete(e)];case 3:return t.sent(),[3,6];case 4:return[4,n.put(s,e)];case 5:t.sent(),t.label=6;case 6:return[4,i.complete];case 7:return t.sent(),!s||r&&r.fid===s.fid||Q(o,s.fid),[2,s]}})})}function ht(r){return h(this,void 0,void 0,function(){var n,e,i;return f(this,function(t){switch(t.label){case 0:return[4,ct(r,function(t){var e,i;return t=pt(t||{fid:function(){try{var t=new Uint8Array(17);(self.crypto||self.msCrypto).getRandomValues(t),t[0]=112+t[0]%16;var e=(i=t,btoa(String.fromCharCode.apply(String,o([],s(i)))).replace(/\+/g,"-").replace(/\//g,"_")).substr(0,22);return K.test(e)?e:G}catch(t){return G}var i}(),registrationStatus:0}),e=r,t=0!==(i=t).registrationStatus?1===i.registrationStatus?{installationEntry:i,registrationPromise:function(r){return h(this,void 0,void 0,function(){var e,i,n;return f(this,function(t){switch(t.label){case 0:return[4,dt(r)];case 1:e=t.sent(),t.label=2;case 2:return 1!==e.registrationStatus?[3,5]:[4,W(100)];case 3:return t.sent(),[4,dt(r)];case 4:return e=t.sent(),[3,2];case 5:return 0!==e.registrationStatus?[3,7]:[4,ht(r)];case 6:return n=t.sent(),i=n.installationEntry,(n=n.registrationPromise)?[2,n]:[2,i];case 7:return[2,e]}})})}(e)}:{installationEntry:i}:navigator.onLine?{installationEntry:i={fid:i.fid,registrationStatus:1,registrationTime:Date.now()},registrationPromise:e=function(n,r){return h(this,void 0,void 0,function(){var e,i;return f(this,function(t){switch(t.label){case 0:return t.trys.push([0,2,,7]),[4,function(o,t){var a=r.fid;return h(this,void 0,void 0,function(){var e,i,n,r,s;return f(this,function(t){switch(t.label){case 0:return e=$(o),i=q(o),s={fid:a,authVersion:O,appId:o.appId,sdkVersion:N},n={method:"POST",headers:i,body:JSON.stringify(s)}
1,[4,U(function(){return fetch(e,n)})];case 1:return(r=t.sent()).ok?[4,r.json()]:[3,3];case 2:return[2,{fid:(s=t.sent()).fid||a,registrationStatus:2,refreshToken:s.refreshToken,authToken:j(s.authToken)}];case 3:return[4,H("Create Installation",r)];case 4:throw t.sent()}})})}(n)];case 1:return e=t.sent(),[2,lt(n,e)];case 2:return B(i=t.sent())&&409===i.customData.serverCode?[4,ut(n)]:[3,4];case 3:return t.sent(),[3,6];case 4:return[4,lt(n,{fid:r.fid,registrationStatus:0})];case 5:t.sent(),t.label=6;case 6:throw i;case 7:return[2]}})})}(e,i)}:{installationEntry:i,registrationPromise:Promise.reject(z.create("app-offline"))},n=t.registrationPromise,t.installationEntry})];case 1:return(e=t.sent()).fid!==G?[3,3]:(i={},[4,n]);case 2:return[2,(i.installationEntry=t.sent(),i)];case 3:return[2,{installationEntry:e,registrationPromise:n}]}})})}function dt(t){return ct(t,function(t){if(!t)throw z.create("installation-not-found");return pt(t)})}function pt(t){return 1===(e=t).registrationStatus&&e.registrationTime+M<Date.now()?{fid:t.fid,registrationStatus:0}:t;var e}function ft(o,a){return void 0===a&&(a=!1),h(this,void 0,void 0,function(){var s,e,i;return f(this,function(t){switch(t.label){case 0:return[4,ct(o.appConfig,function(t){if(!mt(t))throw z.create("not-registered");var e,i,n,r=t.authToken;if(a||2!==(e=r).requestStatus||(i=e,(n=Date.now())<i.creationTime||i.creationTime+i.expiresIn<n+R)){if(1===r.requestStatus)return s=function(i,n){return h(this,void 0,void 0,function(){var e;return f(this,function(t){switch(t.label){case 0:return[4,gt(i.appConfig)];case 1:e=t.sent(),t.label=2;case 2:return 1!==e.authToken.requestStatus?[3,5]:[4,W(100)];case 3:return t.sent(),[4,gt(i.appConfig)];case 4:return e=t.sent(),[3,2];case 5:return 0===(e=e.authToken).requestStatus?[2,ft(i,n)]:[2,e]}})})}(o,a),t;if(!navigator.onLine)throw z.create("app-offline");return e=t,r={requestStatus:1,requestTime:Date.now()},r=p(p({},e),{authToken:r}),s=function(r,s){return h(this,void 0,void 0,function(){var e,i,n;return f(this,function(t){switch(t.label){case 0:return t.trys.push([0,3,,8]),[4,function(t,l){var u=t.appConfig,c=t.platformLoggerProvider;return h(this,void 0,void 0,function(){var n,r,s,o,a;return f(this,function(t){switch(t.label){case 0:return e=u,i=(i=l).fid,n=$(e)+"/"+i+"/authTokens:generate",r=V(u,l),(a=c.getImmediate({optional:!0}))&&r.append("x-firebase-client",a.getPlatformInfoString()),a={installation:{sdkVersion:N}},s={method:"POST",headers:r,body:JSON.stringify(a)},[4,U(function(){return fetch(n,s)})];case 1:return(o=t.sent()).ok?[4,o.json()]:[3,3];case 2:return[2,j(a=t.sent())];case 3:return[4,H("Generate Auth Token",o)];case 4:throw t.sent()}var e,i})})}(r,s)];case 1:return e=t.sent(),n=p(p({},s),{authToken:e}),[4,lt(r.appConfig,n)];case 2:return t.sent(),[2,e];case 3:return!B(i=t.sent())||401!==i.customData.serverCode&&404!==i.customData.serverCode?[3,5]:[4,ut(r.appConfig)];case 4:return t.sent(),[3,7];case 5:return n=p(p({},s),{authToken:{requestStatus:0}}),[4,lt(r.appConfig,n)];case 6:t.sent(),t.label=7;case 7:throw i;case 8:return[2]}})})}(o,r),r}return t})];case 1:return e=t.sent(),s?[4,s]:[3,3];case 2:return i=t.sent(),[3,4];case 3:i=e.authToken,t.label=4;case 4:return[2,i]}})})}function gt(t){return ct(t,function(t){if(!mt(t))throw z.create("not-registered");var e=t.authToken;return 1===(e=e).requestStatus&&e.requestTime+M<Date.now()?p(p({},t),{authToken:{requestStatus:0}}):t})}function mt(t){return void 0!==t&&2===t.registrationStatus}function vt(t){return z.create("missing-app-config-values",{valueName:t})}(it=e.default).INTERNAL.registerComponent(new m("installations",function(t){var e=t.getProvider("app").getImmediate(),i={appConfig:function(t){var e,i;if(!t||!t.options)throw vt("App Configuration");if(!t.name)throw vt("App Name");try{for(var n=g(["projectId","apiKey","appId"]),r=n.next();!r.done;r=n.next()){var s=r.value;if(!t.options[s])throw vt(s)}}catch(t){e={error:t}}finally{try{r&&!r.done&&(i=n.return)&&i.call(n)}finally{if(e)throw e.error}}return{appName:t.name,projectId:t.options.projectId,apiKey:t.options.apiKey,appId:t.options.appId}}(e),platformLoggerProvider:t.getProvider("platform-logger")};return{app:e,getId:function(){return function(n){return h(this,void 0,void 0,function(){var e,i;return f(this,function(t){switch(t.label){case 0:return[4,ht(n.appConfig)];case 1:return e=t.sent(),i=e.installationEntry,(e.registrationPromise||ft(n)).catch(console.error),[2,i.fid]}})})}(i)},getToken:function(t){return function(e,i){return void 0===i&&(i=!1),h(this,void 0,void 0,function(){return f(this,function(t){switch(t.label){case 0:return[4,function(i){return h(this,void 0,void 0,function(){var e;return f(this,function(t){switch(t.label){case 0:return[4,ht(i)];case 1:return(e=t.sent().registrationPromise)?[4,e]:[3,3];case 2:t.sent(),t.label=3;case 3:return[2]}})})}(e.appConfig)];case 1:return t.sent(),[4,ft(e,i)];case 2:return[2,t.sent().token]}})})}(i,t)},delete:function(){return function(n){return h(this,void 0,void 0,function(){var e,i;return f(this,function(t){switch(t.label){case 0:return[4,ct(e=n.appConfig,function(t){if(!t||0!==t.registrationStatus)return t})];case 1:if(!(i=t.sent()))return[3,6];if(1!==i.registrationStatus)return[3,2];throw z.create("delete-pending-registration");case 2:if(2!==i.registrationStatus)return[3,6];if(navigator.onLine)return[3,3];throw z.create("app-offline");case 3:return[4,function(o,a){return h(this,void 0,void 0,function(){var n,r,s;return f(this,function(t){switch(t.label){case 0:return e=o,i=(i=a).fid,n=$(e)+"/"+i,s=V(o,a),r={method:"DELETE",headers:s},[4,U(function(){return fetch(n,r)})];case 1:return(s=t.sent()).ok?[3,3]:[4,H("Delete Installation",s)];case 2:throw t.sent();case 3:return[2]}var e,i})})}(e,i)];case 4:return t.sent(),[4,ut(e)];case 5:t.sent(),t.label=6;case 6:return[2]}})})}(i)},onIdChange:function(t){return function(t,e){tt();var i=Y(t);(t=X.get(i))||(t=new Set,X.set(i,t)),t.add(e)}(r=i.appConfig,n=t),function(){var t,e,i;e=n,i=Y(t=r),(t=X.get(i))&&(t.delete(e),0===t.size&&X.delete(i),et())};var n,r}}},"PUBLIC")),it.registerVersion("@firebase/installations","0.4.32");(F={})["missing-app-config-values"]='Missing App configuration value: "{$valueName}"',F["only-available-in-window"]="This method is available in a Window context.",F["only-available-in-sw"]="This method is available in a service worker context.",F["permission-default"]="The notification permission was not granted and dismissed instead.",F["permission-blocked"]="The notification permission was not granted and blocked instead.",F["unsupported-browser"]="This browser doesn't support the API's required to use the firebase SDK.",F["failed-service-worker-registration"]="We are unable to register the default service worker. {$browserErrorMessage}",F["token-subscribe-failed"]="A problem occurred while subscribing the user to FCM: {$errorInfo}",F["token-subscribe-no-token"]="FCM returned no token when subscribing the user to push.",F["token-unsubscribe-failed"]="A problem occurred while unsubscribing the user from FCM: {$errorInfo}",F["token-update-failed"]="A problem occurred while updating the user from FCM: {$errorInfo}",F["token-update-no-token"]="FCM returned no token when updating the user to push.",F["use-sw-after-get-token"]="The useServiceWorker() method may only be called once and must be called before calling getToken() to ensure your service worker is used.",F["invalid-sw-registration"]="The input to useServiceWorker() must be a ServiceWorkerRegistration.",F["invalid-bg-handler"]="The input to setBackgroun
1dMessageHandler() must be a function.",F["invalid-vapid-key"]="The public VAPID key must be a string.",F["use-vapid-key-after-get-token"]="The usePublicVapidKey() method may only be called once and must be called before calling getToken() to ensure your VAPID key is used.",F=F;var yt,bt=new c("messaging","Messaging",F),wt="BDOU99-h67HcA6JeFXHbSNMu7e2yNNu3RzoMj8TM4W88jITfq7ZmPvIM1Iv-4_l2LxQcYwhqby2xGpWwzjfAnG4",_t="https://fcmregistrations.googleapis.com/v1",xt="google.c.a.c_id";function Tt(t){return t=new Uint8Array(t),btoa(String.fromCharCode.apply(String,o([],s(t)))).replace(/=/g,"").replace(/\+/g,"-").replace(/\//g,"_")}(F=yt=yt||{}).PUSH_RECEIVED="push-received",F.NOTIFICATION_CLICKED="notification-clicked";var St="fcm_token_details_db",Ct=5,Et="fcm_token_object_Store";var kt="firebase-messaging-database",It=1,Dt="firebase-messaging-store",At=null;function Pt(){return At=At||A(kt,It,function(t){0===t.oldVersion&&t.createObjectStore(Dt)})}function Mt(n){return h(this,void 0,void 0,function(){var e,i;return f(this,function(t){switch(t.label){case 0:return e=Ot(n),[4,Pt()];case 1:return[4,t.sent().transaction(Dt).objectStore(Dt).get(e)];case 2:return(e=t.sent())?[2,e]:[3,3];case 3:return[4,function(o){return h(this,void 0,void 0,function(){var s,e=this;return f(this,function(t){switch(t.label){case 0:return"databases"in indexedDB?[4,indexedDB.databases()]:[3,2];case 1:if(!t.sent().map(function(t){return t.name}).includes(St))return[2,null];t.label=2;case 2:return s=null,[4,A(St,Ct,function(r){return h(e,void 0,void 0,function(){var e,i,n;return f(this,function(t){switch(t.label){case 0:return r.oldVersion<2?[2]:r.objectStoreNames.contains(Et)?[4,(n=r.transaction.objectStore(Et)).index("fcmSenderId").get(o)]:[2];case 1:return e=t.sent(),[4,n.clear()];case 2:if(t.sent(),!e)return[2];if(2===r.oldVersion){if(!(i=e).auth||!i.p256dh||!i.endpoint)return[2];s={token:i.fcmToken,createTime:null!==(n=i.createTime)&&void 0!==n?n:Date.now(),subscriptionOptions:{auth:i.auth,p256dh:i.p256dh,endpoint:i.endpoint,swScope:i.swScope,vapidKey:"string"==typeof i.vapidKey?i.vapidKey:Tt(i.vapidKey)}}}else(3===r.oldVersion||4===r.oldVersion)&&(s={token:(i=e).fcmToken,createTime:i.createTime,subscriptionOptions:{auth:Tt(i.auth),p256dh:Tt(i.p256dh),endpoint:i.endpoint,swScope:i.swScope,vapidKey:Tt(i.vapidKey)}});return[2]}})})})];case 3:return t.sent().close(),[4,P(St)];case 4:return t.sent(),[4,P("fcm_vapid_details_db")];case 5:return t.sent(),[4,P("undefined")];case 6:return t.sent(),[2,function(t){if(!t||!t.subscriptionOptions)return!1;var e=t.subscriptionOptions;return"number"==typeof t.createTime&&0<t.createTime&&"string"==typeof t.token&&0<t.token.length&&"string"==typeof e.auth&&0<e.auth.length&&"string"==typeof e.p256dh&&0<e.p256dh.length&&"string"==typeof e.endpoint&&0<e.endpoint.length&&"string"==typeof e.swScope&&0<e.swScope.length&&"string"==typeof e.vapidKey&&0<e.vapidKey.length}(s)?s:null]}})})}(n.appConfig.senderId)];case 4:return(i=t.sent())?[4,Nt(n,i)]:[3,6];case 5:return t.sent(),[2,i];case 6:return[2]}})})}function Nt(n,r){return h(this,void 0,void 0,function(){var e,i;return f(this,function(t){switch(t.label){case 0:return e=Ot(n),[4,Pt()];case 1:return[4,(i=(i=t.sent()).transaction(Dt,"readwrite")).objectStore(Dt).put(r,e)];case 2:return t.sent(),[4,i.complete];case 3:return t.sent(),[2,r]}})})}function Ot(t){return t.appConfig.appId}function Lt(n,r){return h(this,void 0,void 0,function(){var e,i;return f(this,function(t){switch(t.label){case 0:return[4,Ft(n)];case 1:e={method:"DELETE",headers:e=t.sent()},t.label=2;case 2:return t.trys.push([2,5,,6]),[4,fetch(Rt(n.appConfig)+"/"+r,e)];case 3:return[4,t.sent().json()];case 4:if((e=t.sent()).error)throw i=e.error.message,bt.create("token-unsubscribe-failed",{errorInfo:i});return[3,6];case 5:throw i=t.sent(),bt.create("token-unsubscribe-failed",{errorInfo:i});case 6:return[2]}})})}function Rt(t){return t=t.projectId,_t+"/projects/"+t+"/registrations"}function Ft(t){var i=t.appConfig,n=t.installations;return h(this,void 0,void 0,function(){var e;return f(this,function(t){switch(t.label){case 0:return[4,n.getToken()];case 1:return e=t.sent(),[2,new Headers({"Content-Type":"application/json",Accept:"application/json","x-goog-api-key":i.apiKey,"x-goog-firebase-installations-auth":"FIS "+e})]}})})}function zt(t){var e=t.p256dh,i=t.auth;e={web:{endpoint:t.endpoint,auth:i,p256dh:e}};return(t=t.vapidKey)!==wt&&(e.web.applicationPubKey=t),e}function Bt(l,u,c){return h(this,void 0,void 0,function(){var s,o,a;return f(this,function(t){switch(t.label){case 0:if("granted"!==Notification.permission)throw bt.create("permission-blocked");return[4,function(i,n){return h(this,void 0,void 0,function(){var e;return f(this,function(t){switch(t.label){case 0:return[4,i.pushManager.getSubscription()];case 1:return(e=t.sent())?[2,e]:[2,i.pushManager.subscribe({userVisibleOnly:!0,applicationServerKey:function(t){t=(t+"=".repeat((4-t.length%4)%4)).replace(/\-/g,"+").replace(/_/g,"/");for(var e=atob(t),i=new Uint8Array(e.length),n=0;n<e.length;++n)i[n]=e.charCodeAt(n);return i}(n)})]}})})}(u,c)];case 1:return a=t.sent(),[4,Mt(l)];case 2:return s=t.sent(),o={vapidKey:c,swScope:u.scope,endpoint:a.endpoint,auth:Tt(a.getKey("auth")),p256dh:Tt(a.getKey("p256dh"))},s?[3,3]:[2,jt(l,o)];case 3:if(e=s.subscriptionOptions,i=o.vapidKey===e.vapidKey,n=o.endpoint===e.endpoint,r=o.auth===e.auth,e=o.p256dh===e.p256dh,i&&n&&r&&e)return[3,8];t.label=4;case 4:return t.trys.push([4,6,,7]),[4,Lt(l,s.token)];case 5:return t.sent(),[3,7];case 6:return a=t.sent(),console.warn(a),[3,7];case 7:return[2,jt(l,o)];case 8:return Date.now()>=s.createTime+6048e5?[2,function(r,s,o){return h(this,void 0,void 0,function(){var e,i,n;return f(this,function(t){switch(t.label){case 0:return t.trys.push([0,3,,5]),[4,function(s,o){return h(this,void 0,void 0,function(){var e,i,n,r;return f(this,function(t){switch(t.label){case 0:return[4,Ft(s)];case 1:e=t.sent(),i=zt(o.subscriptionOptions),i={method:"PATCH",headers:e,body:JSON.stringify(i)},t.label=2;case 2:return t.trys.push([2,5,,6]),[4,fetch(Rt(s.appConfig)+"/"+o.token,i)];case 3:return[4,t.sent().json()];case 4:return n=t.sent(),[3,6];case 5:throw r=t.sent(),bt.create("token-update-failed",{errorInfo:r});case 6:if(n.error)throw r=n.error.message,bt.create("token-update-failed",{errorInfo:r});if(!n.token)throw bt.create("token-update-no-token");return[2,n.token]}})})}(s,r)];case 1:return e=t.sent(),i=p(p({},r),{token:e,createTime:Date.now()}),[4,Nt(s,i)];case 2:return t.sent(),[2,e];case 3:return n=t.sent(),[4,$t(s,o)];case 4:throw t.sent(),n;case 5:return[2]}})})}({token:s.token,createTime:Date.now(),subscriptionOptions:o},l,u)]:[2,s.token];case 9:return[2]}var e,i,n,r})})}function $t(i,n){return h(this,void 0,void 0,function(){var e;return f(this,function(t){switch(t.label){case 0:return[4,Mt(i)];case 1:return(e=t.sent())?[4,Lt(i,e.token)]:[3,4];case 2:return t.sent(),[4,function(n){return h(this,void 0,void 0,function(){var e,i;return f(this,function(t){switch(t.label){case 0:return e=Ot(n),[4,Pt()];case 1:return[4,(i=(i=t.sent()).transaction(Dt,"readwrite")).objectStore(Dt).delete(e)];case 2:return t.sent(),[4,i.complete];case 3:return t.sent(),[2]}})})}(i)];case 3:t.sent(),t.label=4;case 4:return[4,n.pushManager.getSubscription()];case 5:return(e=t.sent())?[2,e.unsubscribe()]:[2,!0]}})})}function jt(i,n){return h(this,void 0,void 0,function(){var e;return f(this,function(t){switch(t.label){case 0:return[4,function(s,o){return h(this,void 0,void 0,function(){var e,i,n,r;return f(this,function(t){switch(t.label){case 0:return[4,Ft(s)];case 1:e=t.sent(),i=zt(o),i={method:"POST",headers:e,body:JSON.stringify(i)},t.label=2;case 2:return t.trys.push([2,5,,6]),[4,fetch(Rt(s.appConfig),i)];case 3:return[4,t.sent().json()];case 4:return n=t.sent(),[3,6];case 5:throw r=t.sent(),bt.create("token-subscribe-failed",{errorInfo:r});case 6:if(n.error)throw r=n.error.message,bt.create("token-subscribe-failed",{errorInfo:r});if(!n.token)throw bt.create("token-subscribe-no-token");return[2,n.token]}})})}(i,n)];case 1:return e={token:e=t.sent(),createTime:Date.now(),subscriptionOptions:n},[4,Nt(i,e)];case 2:return t.sent(),[2,e.token]}})})}function Ht(t){return"object"==typeof t&&t&&xt in t}function qt(e){return new Promise(function(t){setTimeout(t,e)})}var Vt=(Object.defineProperty(Ut.prototype,"app",{get:function(){return this.firebaseDependencies.app}
1,enumerable:!1,configurable:!0}),Ut.prototype.setBackgroundMessageHandler=function(t){if(this.isOnBackgroundMessageUsed=!1,!t||"function"!=typeof t)throw bt.create("invalid-bg-handler");this.bgMessageHandler=t},Ut.prototype.onBackgroundMessage=function(t){var e=this;return this.isOnBackgroundMessageUsed=!0,this.bgMessageHandler=t,function(){e.bgMessageHandler=null}},Ut.prototype.getToken=function(){var i;return h(this,void 0,void 0,function(){var e;return f(this,function(t){switch(t.label){case 0:return this.vapidKey?[3,2]:[4,Mt(this.firebaseDependencies)];case 1:e=t.sent(),this.vapidKey=null!==(i=null===(i=null==e?void 0:e.subscriptionOptions)||void 0===i?void 0:i.vapidKey)&&void 0!==i?i:wt,t.label=2;case 2:return[2,Bt(this.firebaseDependencies,self.registration,this.vapidKey)]}})})},Ut.prototype.deleteToken=function(){return $t(this.firebaseDependencies,self.registration)},Ut.prototype.requestPermission=function(){throw bt.create("only-available-in-window")},Ut.prototype.usePublicVapidKey=function(t){if(null!==this.vapidKey)throw bt.create("use-vapid-key-after-get-token");if("string"!=typeof t||0===t.length)throw bt.create("invalid-vapid-key");this.vapidKey=t},Ut.prototype.useServiceWorker=function(){throw bt.create("only-available-in-window")},Ut.prototype.onMessage=function(){throw bt.create("only-available-in-window")},Ut.prototype.onTokenRefresh=function(){throw bt.create("only-available-in-window")},Ut.prototype.onPush=function(d){return h(this,void 0,void 0,function(){var u,c,h;return f(this,function(t){switch(t.label){case 0:return(h=function(t){if(!(t=t.data))return null;try{return t.json()}catch(t){return null}}(d))?[4,Wt()]:(console.debug("FirebaseMessaging: failed to get parsed MessagePayload from the PushEvent. Skip handling the push."),[2]);case 1:return(u=t.sent()).some(function(t){return"visible"===t.visibilityState&&!t.url.startsWith("chrome-extension://")})?[2,function(t,e){var i,n;e.isFirebaseMessaging=!0,e.messageType=yt.PUSH_RECEIVED;try{for(var r=g(t),s=r.next();!s.done;s=r.next())s.value.postMessage(e)}catch(t){i={error:t}}finally{try{s&&!s.done&&(n=r.return)&&n.call(r)}finally{if(i)throw i.error}}}(u,h)]:(c=!1,h.notification?[4,((l=p({},(o=h).notification)).data=((a={}).FCM_MSG=o,a),e=l,i=e.actions,n=Notification.maxActions,i&&n&&i.length>n&&console.warn("This browser only supports "+n+" actions. The remaining actions will not be displayed."),self.registration.showNotification(null!==(n=e.title)&&void 0!==n?n:"",e))]:[3,3]);case 2:t.sent(),c=!0,t.label=3;case 3:return!0===c&&!1===this.isOnBackgroundMessageUsed?[2]:(this.bgMessageHandler&&(o=s={from:(r=h).from,collapseKey:r.collapse_key,messageId:r.fcm_message_id},(a=r).notification&&(o.notification={},(l=a.notification.title)&&(o.notification.title=l),(l=a.notification.body)&&(o.notification.body=l),(a=a.notification.image)&&(o.notification.image=a)),o=s,(a=r).data&&(o.data=a.data),o=s,(a=r).fcmOptions&&(o.fcmOptions={},(r=a.fcmOptions.link)&&(o.fcmOptions.link=r),(a=a.fcmOptions.analytics_label)&&(o.fcmOptions.analyticsLabel=a)),h=s,"function"==typeof this.bgMessageHandler?this.bgMessageHandler(h):this.bgMessageHandler.next(h)),[4,qt(1e3)]);case 4:return t.sent(),[2]}var e,i,n,r,s,o,a,l})})},Ut.prototype.onSubChange=function(i){var n;return h(this,void 0,void 0,function(){var e;return f(this,function(t){switch(t.label){case 0:return i.newSubscription?[3,2]:[4,$t(this.firebaseDependencies,self.registration)];case 1:return t.sent(),[2];case 2:return[4,Mt(this.firebaseDependencies)];case 3:return e=t.sent(),[4,$t(this.firebaseDependencies,self.registration)];case 4:return t.sent(),[4,Bt(this.firebaseDependencies,self.registration,null!==(n=null===(n=null==e?void 0:e.subscriptionOptions)||void 0===n?void 0:n.vapidKey)&&void 0!==n?n:wt)];case 5:return t.sent(),[2]}})})},Ut.prototype.onNotificationClick=function(u){var c;return h(this,void 0,void 0,function(){var r,s,o,a,l;return f(this,function(t){switch(t.label){case 0:return(r=null===(c=null===(c=u.notification)||void 0===c?void 0:c.data)||void 0===c?void 0:c.FCM_MSG)?u.action?[2]:(u.stopImmediatePropagation(),u.notification.close(),n=null!==(i=null===(i=(e=r).fcmOptions)||void 0===i?void 0:i.link)&&void 0!==i?i:null===(n=e.notification)||void 0===n?void 0:n.click_action,(s=n||(Ht(e.data)?self.location.origin:null))?(o=new URL(s,self.location.href),a=new URL(self.location.origin),o.host!==a.host?[2]:[4,function(l){return h(this,void 0,void 0,function(){var e,i,n,r,s,o,a;return f(this,function(t){switch(t.label){case 0:return[4,Wt()];case 1:e=t.sent();try{for(i=g(e),n=i.next();!n.done;n=i.next())if(r=n.value,s=new URL(r.url,self.location.href),l.host===s.host)return[2,r]}catch(t){o={error:t}}finally{try{n&&!n.done&&(a=i.return)&&a.call(i)}finally{if(o)throw o.error}}return[2,null]}})})}(o)]):[2]):[2];case 1:return(l=t.sent())?[3,4]:[4,self.clients.openWindow(s)];
1case 2:return l=t.sent(),[4,qt(3e3)];case 3:return t.sent(),[3,6];case 4:return[4,l.focus()];case 5:l=t.sent(),t.label=6;case 6:return l?(r.messageType=yt.NOTIFICATION_CLICKED,r.isFirebaseMessaging=!0,[2,l.postMessage(r)]):[2]}var e,i,n})})},Ut);function Ut(t){var e=this;this.firebaseDependencies=t,this.isOnBackgroundMessageUsed=null,this.vapidKey=null,this.bgMessageHandler=null,self.addEventListener("push",function(t){t.waitUntil(e.onPush(t))}),self.addEventListener("pushsubscriptionchange",function(t){t.waitUntil(e.onSubChange(t))}),self.addEventListener("notificationclick",function(t){t.waitUntil(e.onNotificationClick(t))})}function Wt(){return self.clients.matchAll({type:"window",includeUncontrolled:!0})}var Kt=(Object.defineProperty(Gt.prototype,"app",{get:function(){return this.firebaseDependencies.app},enumerable:!1,configurable:!0}),Gt.prototype.messageEventListener=function(r){return h(this,void 0,void 0,function(){var i,n;return f(this,function(t){switch(t.label){case 0:return(i=r.data).isFirebaseMessaging?(this.onMessageCallback&&i.messageType===yt.PUSH_RECEIVED&&("function"==typeof this.onMessageCallback?this.onMessageCallback((delete(e=Object.assign({},i)).messageType,delete e.isFirebaseMessaging,e)):this.onMessageCallback.next(Object.assign({},i))),Ht(n=i.data)&&"1"===n["google.c.a.e"]?[4,this.logEvent(i.messageType,n)]:[3,2]):[2];case 1:t.sent(),t.label=2;case 2:return[2]}var e})})},Gt.prototype.getVapidKey=function(){return this.vapidKey},Gt.prototype.getSwReg=function(){return this.swRegistration},Gt.prototype.getToken=function(e){return h(this,void 0,void 0,function(){return f(this,function(t){switch(t.label){case 0:return"default"!==Notification.permission?[3,2]:[4,Notification.requestPermission()];case 1:t.sent(),t.label=2;case 2:if("granted"!==Notification.permission)throw bt.create("permission-blocked");return[4,this.updateVapidKey(null==e?void 0:e.vapidKey)];case 3:return t.sent(),[4,this.updateSwReg(null==e?void 0:e.serviceWorkerRegistration)];case 4:return t.sent(),[2,Bt(this.firebaseDependencies,this.swRegistration,this.vapidKey)]}})})},Gt.prototype.updateVapidKey=function(e){return h(this,void 0,void 0,function(){return f(this,function(t){return e?this.vapidKey=e:this.vapidKey||(this.vapidKey=wt),[2]})})},Gt.prototype.updateSwReg=function(e){return h(this,void 0,void 0,function(){return f(this,function(t){switch(t.label){case 0:return e||this.swRegistration?[3,2]:[4,this.registerDefaultSw()];case 1:t.sent(),t.label=2;case 2:if(!e&&this.swRegistration)return[2];if(!(e instanceof ServiceWorkerRegistration))throw bt.create("invalid-sw-registration");return this.swRegistration=e,[2]}})})},Gt.prototype.registerDefaultSw=function(){return h(this,void 0,void 0,function(){var e;return f(this,function(t){switch(t.label){case 0:return t.trys.push([0,2,,3]),e=this,[4,navigator.serviceWorker.register(serviceWorkerPath,{scope:BASE_URL})];case 1:return e.swRegistration=t.sent(),this.swRegistration.update().catch(function(){}),[3,3];case 2:throw e=t.sent(),bt.create("failed-service-worker-registration",{browserErrorMessage:e.message});case 3:return[2]}})})},Gt.prototype.deleteToken=function(){return h(this,void 0,void 0,function(){return f(this,function(t){switch(t.label){case 0:return this.swRegistration?[3,2]:[4,this.registerDefaultSw()];case 1:t.sent(),t.label=2;case 2:return[2,$t(this.firebaseDependencies,this.swRegistration)]}})})},Gt.prototype.requestPermission=function(){return h(this,void 0,void 0,function(){var e;return f(this,function(t){switch(t.label){case 0:return"granted"===Notification.permission?[2]:[4,Notification.requestPermission()];case 1:if("granted"===(e=t.sent()))return[2];throw"denied"===e?bt.create("permission-blocked"):bt.create("permission-default")}})})},Gt.prototype.usePublicVapidKey=function(t){if(null!==this.vapidKey)throw bt.create("use-vapid-key-after-get-token");if("string"!=typeof t||0===t.length)throw bt.create("invalid-vapid-key");this.vapidKey=t},Gt.prototype.useServiceWorker=function(t){if(!(t instanceof ServiceWorkerRegistration))throw bt.create("invalid-sw-registration");if(this.swRegistration)throw bt.create("use-sw-after-get-token");this.swRegistration=t},Gt.prototype.onMessage=function(t){var e=this;return this.onMessageCallback=t,function(){e.onMessageCallback=null}}
1,Gt.prototype.setBackgroundMessageHandler=function(){throw bt.create("only-available-in-sw")},Gt.prototype.onBackgroundMessage=function(){throw bt.create("only-available-in-sw")},Gt.prototype.onTokenRefresh=function(){return function(){}},Gt.prototype.logEvent=function(i,n){return h(this,void 0,void 0,function(){var e;return f(this,function(t){switch(t.label){case 0:return e=function(t){switch(i){case yt.NOTIFICATION_CLICKED:return"notification_open";case yt.PUSH_RECEIVED:return"notification_foreground";default:throw new Error}}(),[4,this.firebaseDependencies.analyticsProvider.get()];case 1:return t.sent().logEvent(e,{message_id:n[xt],message_name:n["google.c.a.c_l"],message_time:n["google.c.a.ts"],message_device_time:Math.floor(Date.now()/1e3)}),[2]}})})},Gt);function Gt(t){var e=this;this.firebaseDependencies=t,this.vapidKey=null,this.onMessageCallback=null,navigator.serviceWorker.addEventListener("message",function(t){return e.messageEventListener(t)})}function Yt(t){return bt.create("missing-app-config-values",{valueName:t})}function Xt(){return self&&"ServiceWorkerGlobalScope"in self?"indexedDB"in self&&null!==indexedDB&&"PushManager"in self&&"Notification"in self&&ServiceWorkerRegistration.prototype.hasOwnProperty("showNotification")&&PushSubscription.prototype.hasOwnProperty("getKey"):"indexedDB"in window&&null!==indexedDB&&navigator.cookieEnabled&&"serviceWorker"in navigator&&"PushManager"in window&&"Notification"in window&&"fetch"in window&&ServiceWorkerRegistration.prototype.hasOwnProperty("showNotification")&&PushSubscription.prototype.hasOwnProperty("getKey")}F={isSupported:Xt},e.default.INTERNAL.registerComponent(new m("messaging",function(t){var e=t.getProvider("app").getImmediate();t={app:e,appConfig:function(t){var e,i;if(!t||!t.options)throw Yt("App Configuration Object");if(!t.name)throw Yt("App Name");var n=t.options;try{for(var r=g(["projectId","apiKey","appId","messagingSenderId"]),s=r.next();!s.done;s=r.next()){var o=s.value;if(!n[o])throw Yt(o)}}catch(t){e={error:t}}finally{try{s&&!s.done&&(i=r.return)&&i.call(r)}finally{if(e)throw e.error}}return{appName:t.name,projectId:n.projectId,apiKey:n.apiKey,appId:n.appId,senderId:n.messagingSenderId}}(e),installations:t.getProvider("installations").getImmediate(),analyticsProvider:t.getProvider("analytics-internal")};if(!Xt())throw bt.create("unsupported-browser");return new(self&&"ServiceWorkerGlobalScope"in self?Vt:Kt)(t)},"PUBLIC").setServiceProps(F))}).apply(this,arguments)}catch(t){throw console.error(t),new Error("Cannot instantiate firebase-messaging.js - be sure to load firebase-app.js first.")}});var site="pricee",__cname="_notifystfcm_"+site,__indexDBcname="_notifycheckindb_"+site,popupShow=!1,setupDone=!1;("undefined"!=typeof querySt&&"app"==querySt("via")||""!=getCookie("viapriceeapp"))&&navigator.userAgent.match(/iPhone|iPad|iPod/i)&&(setupDone=!0),apiUrlbasePath="https://pricee.com/"==BASE_URL?"https://apis.kostprice.com/":"https://stage.pricee.com/";var breakingNewsCollection="https://pricee.com/"==BASE_URL?"breaking_news":"breaking_news_dev",subscribeApi=apiUrlbasePath+"api/v1/subscribe.php",waitForNotifyAction=!1,oneDaySeconds=864e5;function isSupportedNotification(){return"serviceWorker"in navigator&&"PushManager"in window}function get_browser_info(){var t,e=navigator.userAgent,i=e.match(/(opera|chrome|safari|firefox|msie|trident(?=\/))\/?\s*(\d+)/i)||[],n="desktop",r="unknown-os";return-1!=e.indexOf("Edge/")&&(i=e.match(/(edge(?=\/))\/?\s*(\d+)/i)),/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(e)&&(n="mobile"),-1!=navigator.appVersion.indexOf("Win")&&(r="windows"),-1!=navigator.appVersion.indexOf("Mac")&&(r="mac"),-1!=navigator.appVersion.indexOf("X11")&&(r="unix"),-1!=navigator.appVersion.indexOf("Linux")&&(r="linux"),-1!=e.indexOf("Android")&&(r="android"),/trident/i.test(i[1])?{name:"ie",version:(t=/\brv[ :]+(\d+)/g.exec(e)||[])[1]||"",device:n,os:r}:"Chrome"===i[1]&&null!=(t=e.match(/\bOPR\/(\d+)/))?{name:"opera",version:t[1],device:n,os:r}:(i=i[2]?[i[1],i[2]]:[navigator.appName,navigator.appVersion,"-?"],null!=(t=e.match(/version\/(\d+)/i))&&i.splice(1,1,t[1]),{name:i[0].toLowerCase(),version:i[1],device:n,os:r})}function setCookieVal(t,e,i){var n=new Date,r=new Date(n.getTime()+864e5*i),s=escape(e)+"|"+r.getTime()+(null==i?"":"; expires="+r.toUTCString()+";path=/;");document.cookie=t+"="+s}function getCookieVal(t){var e,i,n=document.cookie.split(";");for(e=0;e<n.length;e++)if(n[e].substr(0,n[e].indexOf("=")).replace(/^\s+|\s+$/g,"")==t)return i=n[e].substr(n[e].indexOf("=")+1),val=i,val=i.substring(0,1),unescape(val);return""}var binfo=get_browser_info();function checkSetup(t){if(isSupportedNotification())if("Y"==getCookieVal("_notifyst_"+site+"_")||t)requestPermission();else if(isLocalStorageSupported()&&null!=localStorage.getItem(site+"_ntf_id")){if(null==getLocalStorageWithExpiry(site+"_fcm_token_updated_till_date"))getSubscription(),setLocalStorageWithExpiry(site+"_fcm_token_updated_till_date",1,2*oneDaySeconds);else if(window.indexedDB)try{var e=window.indexedDB.open("firebase-messaging-database");e.onupgradeneeded=function(){(db=e.result).objectStoreNames.contains("firebase-messaging-store")||(indexedDB.deleteDatabase("firebase-messaging-database"),db.close(),setTimeout(function(){getSubscription()},100))},e.onsuccess=function(){if((db=e.result).objectStoreNames.contains("firebase-messaging-store")){var t=db.transaction(["firebase-messaging-store"]).objectStore("firebase-messaging-store").getAllKeys();t.onsuccess=function(){0==t.result.length&&(indexedDB.deleteDatabase("firebase-messaging-database"),db.close(),setTimeout(function(){getSubscription()},100))}}}}catch(t){}}else window.indexedDB?checkExpiryDate():checkShowPopup()}function checkShowPopup(){""==((isLocalStorageSupported()&&null!=localStorage.getItem(__cname)?localStorage.getItem(__cname):getCookieVal(__cname))||"")&&(timeout=waitForNotifyAction?0:1e3,setTimeout(function(){__showSubscribePopup()},timeout))}function __showSubscribePopup(){var t=document.getElementById("__notify");
1if(t){var e="mobile"==binfo.device?".web_dialognotify{width:100%}":"";t.innerHTML="<style>.web_dialog_overlayproductshop,.web_dialognotify{display:none;position:fixed;z-index:99999999;left:0;right:0;-webkit-font-smoothing: antialiased;-moz-osx-font-smoothing: grayscale;}.clear{clear:both}.web_dialog_overlayproductshop{height:100%;opacity:.8;bottom:0;margin:0;padding:0}.web_dialognotify{background-color:#fff;height:auto;opacity:1;text-align:center;font-family:Arial,sans-serif;width:400px;margin:auto;top:0;min-height:100px;border-radius:0 0 5px 5px;box-shadow:0 0 10px #999;padding:15px 10px;cursor:auto}.web_dialognotify .bn_wrp{text-align:left}.web_dialognotify .bn_wrp .logo{margin:-3px 10px 10px 0;float:left;width:65px}.web_dialognotify .bn_wrp .heading{margin:0 0 8px;font-size:15px;font-weight:600;line-height:18px}.web_dialognotify .bn_wrp p{margin:0 10px;font-size:14px}.web_dialognotify .bn_wrp .bn_buttons{margin:20px 0 0}.bn_wrp .bn_notnow,.web_dialognotify .bn_wrp .bn_close{float:right;padding:4px 20px;margin:0 5px;font-size:12px;border:none;cursor:pointer}.web_dialognotify .bn_wrp .bn_close:hover{background:#4FACEF;border:1px solid #4B84AD;color:#FFF}.web_dialognotify .bn_wrp .bn_notnow{text-decoration:underline;background:none;}.web_dialognotify .bn_wrp .bn_close{border:1px solid #999;text-transform:uppercase;border-radius:4px}"+e+"                        @-webkit-keyframes bounceInRight{0%,60%,75%,90%,to{-webkit-animation-timing-function:cubic-bezier(.215,.61,.355,1);animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;-webkit-transform:translate3d(3000px,0,0);transform:translate3d(3000px,0,0)}60%{opacity:1;-webkit-transform:translate3d(-25px,0,0);transform:translate3d(-25px,0,0)}75%{-webkit-transform:translate3d(10px,0,0);transform:translate3d(10px,0,0)}90%{-webkit-transform:translate3d(-5px,0,0);transform:translate3d(-5px,0,0)}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}@keyframes bounceInRight{0%,60%,75%,90%,to{-webkit-animation-timing-function:cubic-bezier(.215,.61,.355,1);animation-timing-function:cubic-bezier(.215,.61,.355,1)}0%{opacity:0;-webkit-transform:translate3d(3000px,0,0);transform:translate3d(3000px,0,0)}60%{opacity:1;-webkit-transform:translate3d(-25px,0,0);transform:translate3d(-25px,0,0)}75%{-webkit-transform:translate3d(10px,0,0);transform:translate3d(10px,0,0)}90%{-webkit-transform:translate3d(-5px,0,0);transform:translate3d(-5px,0,0)}to{-webkit-transform:translateZ(0);transform:translateZ(0)}}.bounceInRight{-webkit-animation-name:bounceInRight;animation-name:bounceInRight}                        .animated{-webkit-animation-duration:1s;animation-duration:1s;-webkit-animation-fill-mode:both;animation-fill-mode:both}                        </style>",t.innerHTML+='<div id="overlaynotify_cnt"></div><div id="bnotify" class="web_dialog web_dialognotify web_dialogproduct animated bounceInRight" style="display:none"><div class="web_dialog_content"><div class="bn_wrp"><img class="logo" src="https://pricee.com/src/assets/images/pricee_icon.png" width="60"/><span class="heading">Subscribe to Pricee alerts</span><p>Compare and check prices from Amazon, Flipkart, Tata CliQ, Paytm and more.</p><div class="bn_buttons"><button id="btnallow" class="bn_close">Yes</button><button id="btnClosenotify" class="bn_notnow">No</button><div class="clear"></div></div></div></div></div>',popupShow=!0,ShowDialogProductpopup()}}function ShowDialogProductpopup(){$("#overlaynotify_cnt").show(),$("#bnotify").fadeIn(300),$("#overlaynotify_cnt").click(function(t){HideDialogProductpopup()})}function HideDialogProductpopup(){$("#bnotify").fadeOut(300),$("#overlaynotify_cnt").hide()}function hideNotifyPopup(t){setNotifyStatusCookie(t),HideDialogProductpopup()}function setNotifyStatusCookie(t){"Y"==t?(isLocalStorageSupported()?setLocalStorageWithExpiry(__cname,"Y",30*oneDaySeconds):setCookieVal(__cname,"Y",30),popupShow=!1):isLocalStorageSupported()?setLocalStorageWithExpiry(__cname,"N",30*oneDaySeconds):setCookieVal(__cname,"N",30)}function getSubscription(){messaging.getToken().then(function(t){t&&(lastToken=localStorage.getItem(site+"_fcm_token"),null!=lastToken&&lastToken==t||subscribeNow(t,""),flag="Y"!=getCookieVal("_notifyst_"+site+"_")&&!waitForNotifyAction,flag=(!isLocalStorageSupported()||null==localStorage.getItem(site+"_ntf_id"))&&flag,flag&&onRegisterNotify(),isLocalStorageSupported()&&localStorage.setItem(site+"_fcm_token",t))}).catch(function(t){console.log("An error occurred while retrieving token. ",t.message)})}function requestPermission(){Notification.requestPermission().then(function(t){"granted"===t?getSubscription():(console.log("Unable to get permission to notify."),"function"==typeof savePriceDrop&&waitForNotifyAction&&(savePriceDrop(),waitForNotifyAction=!1))})}function subscribeNow(e,i){platform=IS_MOBILE?"mobile":"desktop",dtid=isLocalStorageSupported()&&null!=localStorage.getItem(site+"_ntf_id")?localStorage.getItem(site+"_ntf_id"):0,$.ajax({url:subscribeApi,type:"POST",data:{token:e,browser:binfo.name,unregister:i,platform:platform,os:binfo.os,dtid:dtid},success:function(t){hideNotifyPopup(i?"N":"Y"),isLocalStorageSupported()&&void 0!==t.dtid&&localStorage.setItem(site+"_ntf_id",t.dtid),"function"==typeof savePriceDrop&&waitForNotifyAction&&(fcmToken=e,savePriceDrop(),waitForNotifyAction=!1)}})}function unSubscribe(){isLocalStorageSupported()?setLocalStorageWithExpiry(__cname,"N",30*oneDaySeconds):setCookieVal(__cname,"N",30),isLocalStorageSupported()&&null!=localStorage.getItem(site+"_ntf_id")&&messaging.getToken().then(function(t){messaging.deleteToken(t).then(function(){subscribeNow(t,1)}).catch(function(t){console.log("Unable to delete token. ",t)})}).catch(function(t){console.log("Error retrieving Instance ID token. ",t)})}function onRegisterNotify(){navigator.serviceWorker.getRegistration().then(function(t){try{t.showNotification("Pricee",{body:"Thank y
1ou for subscribing to Pricee alerts.",icon:"https://pricee.com/src/assets/images/pricee_icon.png",vibrate:[300,100,400],tag:"pricee-welcome",data:{url:"https://pricee.com/?notify"}}).onclick=function(t){t.target.close(),window.location.href=t.target.data.url}}catch(t){}})}"undefined"!=typeof IS_HOMEPAGE&&1==IS_HOMEPAGE?(setupDone=!0,setTimeout(function(){checkSetup(0)},0)):$(window).scroll(function(){setupDone||(setupDone=!0,checkSetup(0))}),$("body").on("click","#btnClosenotify",function(t){hideNotifyPopup("N"),t.preventDefault(),window.indexedDB&&(isLocalStorageSupported()?setLocalStorageWithExpiry(__indexDBcname,"Y",1*oneDaySeconds):setCookieVal(__indexDBcname,"Y",1))}),$("body").on("click","#btnallow",function(t){hideNotifyPopup("Y"),requestPermission(),t.preventDefault()});var serviceWorkerPath=BASE_URL+"sw.js?ver=v"+(new Date).getUTCFullYear()+(new Date).getUTCMonth()+(new Date).getUTCDate();function registerServiceWorker(){if(!isSupportedNotification())return!1;navigator.serviceWorker.register(serviceWorkerPath,{scope:BASE_URL}).then(function(t){console.log("Service Worker registration successful")}).catch(function(t){console.log("Service Worker registration failed",t.message)})}function isLocalStorageSupported(){try{return localStorage.setItem("testlocal","1"),localStorage.removeItem("testlocal"),!0}catch(t){return!1}}function checkExpiryDate(){try{var t=(isLocalStorageSupported()&&null!=getLocalStorageWithExpiry(__indexDBcname)?getLocalStorageWithExpiry(__indexDBcname):getCookieVal(__indexDBcname))||"";isLocalStorageSupported()&&""!=getCookieVal(__indexDBcname)&&(val=getCookieVal(__indexDBcname),-1!=val.indexOf("|")&&(val=val.substring(0,val.indexOf("|"))),setLocalStorageWithExpiry(__indexDBcname,val,1*oneDaySeconds),deleteCookie(__indexDBcname)),window.indexedDB&&""==t&&(console.log("checking indexedDB"),openRequest=indexedDB.open("pricee_settings",1),openRequest.onupgradeneeded=function(t){openRequest.result.createObjectStore("settings",{keyPath:"type"}).createIndex("type","type",{unique:!0})},openRequest.onsuccess=function(t){if(allowNotification=isLocalStorageSupported()&&null!=getLocalStorageWithExpiry(__cname)?getLocalStorageWithExpiry(__cname):getCookieVal(__cname).substring(0,1),""!=allowNotification&&(isLocalStorageSupported()?setLocalStorageWithExpiry(__indexDBcname,"Y",1*oneDaySeconds):setCookieVal(__indexDBcname,"Y",1)),(db=openRequest.result).objectStoreNames.contains("settings")){var e=db.transaction("settings").objectStore("settings").get("notify");e.onsuccess=function(t){void 0!==e.result&&(currentDate=new Date,currentTs=currentDate.getTime(),lastNotificationTs=e.result.data.last_notification_ts,1e12<lastNotificationTs&&"Y"==allowNotification&&(remainingDaysTs=lastNotificationTs+2592e6,remainingDays=0<remainingDaysTs-currentTs?Math.round((remainingDaysTs-currentTs)/864e5):0,isLocalStorageSupported()?setLocalStorageWithExpiry(__cname,"Y",oneDaySeconds*remainingDays):setCookieVal(__cname,"Y",remainingDays))),checkShowPopup()}}})}catch(t){console.log("Error reading indexedDB")}}registerServiceWorker(),$(document).on("click",function(t){popupShow&&"notifysubclick"!=t.target.id&&"btnallow"!=t.target.id&&"overlaynotify_cnt"!=t.target.id&&"notifbell"!=t.target.id&&(setNotifyStatusCookie("N"),HideDialogProductpopup(),popupShow=!1)}),firebase.initializeApp({apiKey:"AIzaSyAhVo9Qu8vNKRG-zLVSEyJLhYo0199GMkI",projectId:"pricee-web-notifications",messagingSenderId:"773802887631",appId:"1:773802887631:web:d787c225bd8beb84136aba",databaseURL:"https://pricee-web-notifications.firebaseio.com",storageBucket:"pricee-web-notifications.appspot.com"});var messaging=firebase.messaging();messaging.usePublicVapidKey("BDN7S0Z6KC9HrnDhRRNATCsbkFFLaFuT7GafRg1nregMDZZNg84uhcFISEjxqZuT7R_EzC1znglTzc1yugl-TTA"),messaging.onTokenRefresh(function(){messaging.getToken().then(function(t){subscribeNow(t,"")}).catch(function(t){console.log("Unable to retrieve refreshed token ",t.message)})});var dbCollection=breakingNewsCollection,db=firebase.firestore(),newsId="1";function setLocalStorageWithExpiry(t,e,i){var n=new Date;item={value:e,expiry:n.getTime()+i},localStorage.setItem(t,JSON.stringify(item))}function getLocalStorageWithExpiry(t){var e=localStorage.getItem(t);return e?(item=JSON.parse(e),(new Date).getTime()>item.expiry?(localStorage.removeItem(t),null):item.value):null}function deleteCookie(t){document.cookie=t+"=; Path=/; Expires=Thu, 01 Jan 1970 00:00:01 GMT;"}db.collection(dbCollection).doc(newsId).onSnapshot(function(t){var e=t.data();void 0!==e&&"pricee.com"==e.domain&&""!=e&&""!=e.title&&1==e.status&&(url=e.url,hash=url.substring(url.indexOf("#")+1),storyId=hash.replace("pfrom=webpush-",""),ga("send","event","BreakingNews","Loa
1d",storyId),$("#breakingnewshtml").html(""),html="",html+='<div class="_gflshw gelatine">',html+='<i class="_gflc" aria-label="close"></i>',html+='<div class="_hd">News Flash</div>',html+='<div class="_gflnw">',html+='<a href="'+e.url+'" class="_flx">',html+='<span class="_thmb">',html+='<img src="'+e.image+'" alt="'+e.title+'" title="'+e.title+'" width="120" height="120" loading="lazy">',html+="</span>",html+='<span class="_gfntl">'+e.title+"</span>",html+="</a>",html+="</div>",html+='<a href="'+e.url+'" class="_gfrm">Read more</a>',html+="</div>",document.getElementById("breakingnewshtml").innerHTML=html)}),$(document).ready(function(){$(document).on("click","._gflc",function(t){$("#breakingnewshtml").html("")})});

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.