1const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["javascript/chunks/google-analytics-adapter.05aef2c3.js","javascript/chunks/consent.cea05f21.js","javascript/chunks/matomo-adapter.9a80b705.js","javascript/chunks/smartocto-adapter.8afbaa90.js"])))=>i.map(i=>d[i]); 2var cT=Object.defineProperty;var Sd=r=>{throw TypeError(r)};var uT=(r,e,t)=>e in r?cT(r,e,{enumerable:!0,configurable:!0,writable:!0,value:t}):r[e]=t;var y=(r,e,t)=>uT(r,typeof e!="symbol"?e+"":e,t),Za=(r,e,t)=>e.has(r)||Sd("Cannot "+t);var K=(r,e,t)=>(Za(r,e,"read from private field"),t?t.call(r):e.get(r)),le=(r,e,t)=>e.has(r)?Sd("Cannot add the same private member more than once"):e instanceof WeakSet?e.add(r):e.set(r,t),ve=(r,e,t,i)=>(Za(r,e,"write to private field"),i?i.call(r,t):e.set(r,t),t),Q=(r,e,t)=>(Za(r,e,"access private method"),t);const hT="modulepreload",dT=function(r){return"/app/themes/hopp/assets/"+r},Ad={},nt=function(e,t,i){let o=Promise.resolve();if(t&&t.length>0){document.getElementsByTagName("link");const l=document.querySelector("meta[property=csp-nonce]"),u=(l==null?void 0:l.nonce)||(l==null?void 0:l.getAttribute("nonce"));o=Promise.all(t.map(d=>{if(d=dT(d),d in Ad)return;Ad[d]=!0;const p=d.endsWith(".css"),v=p?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${d}"]${v}`))return;const S=document.createElement("link");if(S.rel=p?"stylesheet":hT,p||(S.as="script",S.crossOrigin=""),S.href=d,u&&S.setAttribute("nonce",u),document.head.appendChild(S),p)return new Promise((O,k)=>{S.addEventListener("load",O),S.addEventListener("error",()=>k(new Error(`Unable to preload CSS for ${d}`)))})}))}return o.then(()=>e()).catch(l=>{const u=new Event("vite:preloadError",{cancelable:!0});if(u.payload=l,window.dispatchEvent(u),!u.defaultPrevented)throw l})};class fT{constructor(e,t,i){this.eventTarget=e,this.eventName=t,this.eventOptions=i,this.unorderedBindings=new Set}connect(){this.eventTarget.addEventListener(this.eventName,this,this.eventOptions)}disconnect(){this.eventTarget.removeEventListener(this.eventName,this,this.eventOptions)}bindingConnected(e){this.unorderedBindings.add(e)}bindingDisconnected(e){this.unorderedBindings.delete(e)}handleEvent(e){const t=gT(e);for(const i of this.bindings){if(t.immediatePropagationStopped)break;i.handleEvent(t)}}hasBindings(){return this.unorderedBindings.size>0}get bindings(){return Array.from(this.unorderedBindings).sort((e,t)=>{const i=e.index,o=t.index;return i<o?-1:i>o?1:0})}}function gT(r){if("immediatePropagationStopped"in r)return r;{const{stopImmediatePropagation:e}=r;return Object.assign(r,{immediatePropagationStopped:!1,stopImmediatePropagation(){this.immediatePropagationStopped=!0,e.call(this)}})}}class pT{constructor(e){this.application=e,this.eventListenerMaps=new Map,this.started=!1}start(){this.started||(this.started=!0,this.eventListeners.forEach(e=>e.connect()))}stop(){this.started&&(this.started=!1,this.eventListeners.forEach(e=>e.disconnect()))}get eventListeners(){return Array.from(this.eventListenerMaps.values()).reduce((e,t)=>e.concat(Array.from(t.values())),[])}bindingConnected(e){this.fetchEventListenerForBinding(e).bindingConnected(e)}bindingDisconnected(e,t=!1){this.fetchEventListenerForBinding(e).bindingDisconnected(e),t&&this.clearEventListenersForBinding(e)}handleError(e,t,i={}){this.application.handleError(e,`Error ${t}`,i)}clearEventListenersForBinding(e){const t=this.fetchEventListenerForBinding(e);t.hasBindings()||(t.disconnect(),this.removeMappedEventListenerFor(e))}removeMappedEventListenerFor(e){const{eventTarget:t,eventName:i,eventOptions:o}=e,l=this.fetchEventListenerMapForEventTarget(t),u=this.cacheKey(i,o);l.delete(u),l.size==0&&this.eventListenerMaps.delete(t)}fetchEventListenerForBinding(e){const{eventTarget:t,eventName:i,eventOptions:o}=e;return this.fetchEventListener(t,i,o)}fetchEventListener(e,t,i){const o=this.fetchEventListenerMapForEventTarget(e),l=this.cacheKey(t,i);let u=o.get(l);return u||(u=this.createEventListener(e,t,i),o.set(l,u)),u}createEventListener(e,t,i){const o=new fT(e,t,i);return this.started&&o.connect(),o}fetchEventListenerMapForEventTarget(e){let t=this.eventListenerMaps.get(e);return t||(t=new Map,this.eventListenerMaps.set(e,t)),t}cacheKey(e,t){const i=[e];
2return Object.keys(t).sort().forEach(o=>{i.push(`${t[o]?"":"!"}${o}`)}),i.join(":")}}const mT={stop({event:r,value:e}){return e&&r.stopPropagation(),!0},prevent({event:r,value:e}){return e&&r.preventDefault(),!0},self({event:r,value:e,element:t}){return e?t===r.target:!0}},vT=/^(?:(?:([^.]+?)\+)?(.+?)(?:\.(.+?))?(?:@(window|document))?->)?(.+?)(?:#([^:]+?))(?::(.+))?$/;function bT(r){const t=r.trim().match(vT)||[];let i=t[2],o=t[3];return o&&!["keydown","keyup","keypress"].includes(i)&&(i+=`.${o}`,o=""),{eventTarget:_T(t[4]),eventName:i,eventOptions:t[7]?wT(t[7]):{},identifier:t[5],methodName:t[6],keyFilter:t[1]||o}}function _T(r){if(r=="window")return window;if(r=="document")return document}function wT(r){return r.split(":").reduce((e,t)=>Object.assign(e,{[t.replace(/^!/,"")]:!/^!/.test(t)}),{})}function yT(r){if(r==window)return"window";if(r==document)return"document"}function oc(r){return r.replace(/(?:[_-])([a-z0-9])/g,(e,t)=>t.toUpperCase())}function pl(r){return oc(r.replace(/--/g,"-").replace(/__/g,"_"))}function Hi(r){return r.charAt(0).toUpperCase()+r.slice(1)}function ug(r){return r.replace(/([A-Z])/g,(e,t)=>`-${t.toLowerCase()}`)}function ET(r){return r.match(/[^\s]+/g)||[]}function Td(r){return r!=null}function ml(r,e){return Object.prototype.hasOwnProperty.call(r,e)}const Od=["meta","ctrl","alt","shift"];class ST{constructor(e,t,i,o){this.element=e,this.index=t,this.eventTarget=i.eventTarget||e,this.eventName=i.eventName||AT(e)||Bs("missing event name"),this.eventOptions=i.eventOptions||{},this.identifier=i.identifier||Bs("missing identifier"),this.methodName=i.methodName||Bs("missing method name"),this.keyFilter=i.keyFilter||"",this.schema=o}static forToken(e,t){return new this(e.element,e.index,bT(e.content),t)}toString(){const e=this.keyFilter?`.${this.keyFilter}`:"",t=this.eventTargetName?`@${this.eventTargetName}`:"";return`${this.eventName}${e}${t}->${this.identifier}#${this.methodName}`}shouldIgnoreKeyboardEvent(e){if(!this.keyFilter)return!1;const t=this.keyFilter.split("+");if(this.keyFilterDissatisfied(e,t))return!0;const i=t.filter(o=>!Od.includes(o))[0];return i?(ml(this.keyMappings,i)||Bs(`contains unknown key filter: ${this.keyFilter}`),this.keyMappings[i].toLowerCase()!==e.key.toLowerCase()):!1}shouldIgnoreMouseEvent(e){if(!this.keyFilter)return!1;const t=[this.keyFilter];return!!this.keyFilterDissatisfied(e,t)}get params(){const e={},t=new RegExp(`^data-${this.identifier}-(.+)-param$`,"i");for(const{name:i,value:o}of Array.from(this.element.attributes)){const l=i.match(t),u=l&&l[1];u&&(e[oc(u)]=TT(o))}return e}get eventTargetName(){return yT(this.eventTarget)}get keyMappings(){return this.schema.keyMappings}keyFilterDissatisfied(e,t){const[i,o,l,u]=Od.map(d=>t.includes(d));return e.metaKey!==i||e.ctrlKey!==o||e.altKey!==l||e.shiftKey!==u}}const Cd={a:()=>"click",button:()=>"click",form:()=>"submit",details:()=>"toggle",input:r=>r.getAttribute("type")=="submit"?"click":"input",select:()=>"change",textarea:()=>"input"};function AT(r){const e=r.tagName.toLowerCase();if(e in Cd)return Cd[e](r)}function Bs(r){throw new Error(r)}function TT(r){try{return JSON.parse(r)}catch{return r}}class OT{constructor(e,t){this.context=e,this.action=t}get index(){return this.action.index}get eventTarget(){return this.action.eventTarget}get eventOptions(){return this.action.eventOptions}get identifier(){return this.context.identifier}handleEvent(e){const t=this.prepareActionEvent(e);this.willBeInvokedByEvent(e)&&this.applyEventModifiers(t)&&this.invokeWithEvent(t)}get eventName(){return this.action.eventName}get method(){const e=this.controller[this.methodName];if(typeof e=="function")return e;throw new Error(`Action "${this.action}" references undefined method "${this.methodName}"`)}applyEventModifiers(e){const{element:t}=this.action,{actionDescriptorFilters:i}=this.context.application,{controller:o}=this.context;let l=!0;for(const[u,d]of Object.entries(this.eventOptions))if(u in i){const p=i[u];l=l&&p({name:u,value:d,event:e,element:t,controller:o})}else continue;return l}prepareActionEvent(e){return Object.assign(e,{params:this.action.params})}invokeWithEvent(e){const{target:t,currentTarget:i}=e;try{this.method.call(this.controller,e),this.context.logDebugActivity(this.methodName,{event:e,target:t,currentTarget:i,action:this.methodName})}catch(o){const{identifier:l,controller:u,element:d,index:p}=this,v={identifier:l,controller:u,element:d,index:p,event:e};this.context.handleError(o,`invoking action "${this.action}"`,v)}}willBeInvokedByEvent(e){const t=e.target;return e instanceof KeyboardEvent&&this.action.shouldIgnoreKeyboardEvent(e)||e instanceof MouseEvent&&this.action.shouldIgnoreMouseEvent(e)?!1:this.element===t?!0:t instanceof Element&&this.element.contains(t)?this.scope.containsElement(t):this.scope.containsElement(this.action.element)}get controller(){return this.context.controller}get methodName(){return this.action.methodName}
2get element(){return this.scope.element}get scope(){return this.context.scope}}class hg{constructor(e,t){this.mutationObserverInit={attributes:!0,childList:!0,subtree:!0},this.element=e,this.started=!1,this.delegate=t,this.elements=new Set,this.mutationObserver=new MutationObserver(i=>this.processMutations(i))}start(){this.started||(this.started=!0,this.mutationObserver.observe(this.element,this.mutationObserverInit),this.refresh())}pause(e){this.started&&(this.mutationObserver.disconnect(),this.started=!1),e(),this.started||(this.mutationObserver.observe(this.element,this.mutationObserverInit),this.started=!0)}stop(){this.started&&(this.mutationObserver.takeRecords(),this.mutationObserver.disconnect(),this.started=!1)}refresh(){if(this.started){const e=new Set(this.matchElementsInTree());for(const t of Array.from(this.elements))e.has(t)||this.removeElement(t);for(const t of Array.from(e))this.addElement(t)}}processMutations(e){if(this.started)for(const t of e)this.processMutation(t)}processMutation(e){e.type=="attributes"?this.processAttributeChange(e.target,e.attributeName):e.type=="childList"&&(this.processRemovedNodes(e.removedNodes),this.processAddedNodes(e.addedNodes))}processAttributeChange(e,t){this.elements.has(e)?this.delegate.elementAttributeChanged&&this.matchElement(e)?this.delegate.elementAttributeChanged(e,t):this.removeElement(e):this.matchElement(e)&&this.addElement(e)}processRemovedNodes(e){for(const t of Array.from(e)){const i=this.elementFromNode(t);i&&this.processTree(i,this.removeElement)}}processAddedNodes(e){for(const t of Array.from(e)){const i=this.elementFromNode(t);i&&this.elementIsActive(i)&&this.processTree(i,this.addElement)}}matchElement(e){return this.delegate.matchElement(e)}matchElementsInTree(e=this.element){return this.delegate.matchElementsInTree(e)}processTree(e,t){for(const i of this.matchElementsInTree(e))t.call(this,i)}elementFromNode(e){if(e.nodeType==Node.ELEMENT_NODE)return e}elementIsActive(e){return e.isConnected!=this.element.isConnected?!1:this.element.contains(e)}addElement(e){this.elements.has(e)||this.elementIsActive(e)&&(this.elements.add(e),this.delegate.elementMatched&&this.delegate.elementMatched(e))}removeElement(e){this.elements.has(e)&&(this.elements.delete(e),this.delegate.elementUnmatched&&this.delegate.elementUnmatched(e))}}class dg{constructor(e,t,i){this.attributeName=t,this.delegate=i,this.elementObserver=new hg(e,this)}get element(){return this.elementObserver.element}get selector(){return`[${this.attributeName}]`}start(){this.elementObserver.start()}pause(e){this.elementObserver.pause(e)}stop(){this.elementObserver.stop()}refresh(){this.elementObserver.refresh()}get started(){return this.elementObserver.started}matchElement(e){return e.hasAttribute(this.attributeName)}matchElementsInTree(e){const t=this.matchElement(e)?[e]:[],i=Array.from(e.querySelectorAll(this.selector));return t.concat(i)}elementMatched(e){this.delegate.elementMatchedAttribute&&this.delegate.elementMatchedAttribute(e,this.attributeName)}elementUnmatched(e){this.delegate.elementUnmatchedAttribute&&this.delegate.elementUnmatchedAttribute(e,this.attributeName)}elementAttributeChanged(e,t){this.delegate.elementAttributeValueChanged&&this.attributeName==t&&this.delegate.elementAttributeValueChanged(e,t)}}function CT(r,e,t){fg(r,e).add(t)}function IT(r,e,t){fg(r,e).delete(t),LT(r,e)}function fg(r,e){let t=r.get(e);return t||(t=new Set,r.set(e,t)),t}function LT(r,e){const t=r.get(e);t!=null&&t.size==0&&r.delete(e)}class qr{constructor(){this.valuesByKey=new Map}get keys(){return Array.from(this.valuesByKey.keys())}get values(){return Array.from(this.valuesByKey.values()).reduce((t,i)=>t.concat(Array.from(i)),[])}get size(){return Array.from(this.valuesByKey.values()).reduce((t,i)=>t+i.size,0)}add(e,t){CT(this.valuesByKey,e,t)}delete(e,t){IT(this.valuesByKey,e,t)}has(e,t){const i=this.valuesByKey.get(e);return i!=null&&i.has(t)}hasKey(e){return this.valuesByKey.has(e)}hasValue(e){return Array.from(this.valuesByKey.values()).some(i=>i.has(e))}getValuesForKey(e){const t=this.valuesByKey.get(e);return t?Array.from(t):[]}getKeysForValue(e){return Array.from(this.valuesByKey).filter(([t,i])=>i.has(e)).map(([t,i])=>t)}}class RT{constructor(e,t,i,o){this._selector=t,this.details=o,this.elementObserver=new hg(e,this),this.delegate=i,this.matchesByElement=new qr}get started(){return this.elementObserver.started}get selector(){return this._selector}set selector(e){this._selector=e,this.refresh()}start(){this.elementObserver.start()}pause(e){this.elementObserver.pause(e)}stop(){this.elementObserver.stop()}refresh(){this.elementObserver.refresh()}
2get element(){return this.elementObserver.element}matchElement(e){const{selector:t}=this;if(t){const i=e.matches(t);return this.delegate.selectorMatchElement?i&&this.delegate.selectorMatchElement(e,this.details):i}else return!1}matchElementsInTree(e){const{selector:t}=this;if(t){const i=this.matchElement(e)?[e]:[],o=Array.from(e.querySelectorAll(t)).filter(l=>this.matchElement(l));return i.concat(o)}else return[]}elementMatched(e){const{selector:t}=this;t&&this.selectorMatched(e,t)}elementUnmatched(e){const t=this.matchesByElement.getKeysForValue(e);for(const i of t)this.selectorUnmatched(e,i)}elementAttributeChanged(e,t){const{selector:i}=this;if(i){const o=this.matchElement(e),l=this.matchesByElement.has(i,e);o&&!l?this.selectorMatched(e,i):!o&&l&&this.selectorUnmatched(e,i)}}selectorMatched(e,t){this.delegate.selectorMatched(e,t,this.details),this.matchesByElement.add(t,e)}selectorUnmatched(e,t){this.delegate.selectorUnmatched(e,t,this.details),this.matchesByElement.delete(t,e)}}class PT{constructor(e,t){this.element=e,this.delegate=t,this.started=!1,this.stringMap=new Map,this.mutationObserver=new MutationObserver(i=>this.processMutations(i))}start(){this.started||(this.started=!0,this.mutationObserver.observe(this.element,{attributes:!0,attributeOldValue:!0}),this.refresh())}stop(){this.started&&(this.mutationObserver.takeRecords(),this.mutationObserver.disconnect(),this.started=!1)}refresh(){if(this.started)for(const e of this.knownAttributeNames)this.refreshAttribute(e,null)}processMutations(e){if(this.started)for(const t of e)this.processMutation(t)}processMutation(e){const t=e.attributeName;t&&this.refreshAttribute(t,e.oldValue)}refreshAttribute(e,t){const i=this.delegate.getStringMapKeyForAttribute(e);if(i!=null){this.stringMap.has(e)||this.stringMapKeyAdded(i,e);const o=this.element.getAttribute(e);if(this.stringMap.get(e)!=o&&this.stringMapValueChanged(o,i,t),o==null){const l=this.stringMap.get(e);this.stringMap.delete(e),l&&this.stringMapKeyRemoved(i,e,l)}else this.stringMap.set(e,o)}}stringMapKeyAdded(e,t){this.delegate.stringMapKeyAdded&&this.delegate.stringMapKeyAdded(e,t)}stringMapValueChanged(e,t,i){this.delegate.stringMapValueChanged&&this.delegate.stringMapValueChanged(e,t,i)}stringMapKeyRemoved(e,t,i){this.delegate.stringMapKeyRemoved&&this.delegate.stringMapKeyRemoved(e,t,i)}get knownAttributeNames(){return Array.from(new Set(this.currentAttributeNames.concat(this.recordedAttributeNames)))}get currentAttributeNames(){return Array.from(this.element.attributes).map(e=>e.name)}get recordedAttributeNames(){return Array.from(this.stringMap.keys())}}class gg{constructor(e,t,i){this.attributeObserver=new dg(e,t,this),this.delegate=i,this.tokensByElement=new qr}get started(){return this.attributeObserver.started}start(){this.attributeObserver.start()}pause(e){this.attributeObserver.pause(e)}stop(){this.attributeObserver.stop()}refresh(){this.attributeObserver.refresh()}get element(){return this.attributeObserver.element}get attributeName(){return this.attributeObserver.attributeName}elementMatchedAttribute(e){this.tokensMatched(this.readTokensForElement(e))}elementAttributeValueChanged(e){const[t,i]=this.refreshTokensForElement(e);this.tokensUnmatched(t),this.tokensMatched(i)}elementUnmatchedAttribute(e){this.tokensUnmatched(this.tokensByElement.getValuesForKey(e))}tokensMatched(e){e.forEach(t=>this.tokenMatched(t))}tokensUnmatched(e){e.forEach(t=>this.tokenUnmatched(t))}tokenMatched(e){this.delegate.tokenMatched(e),this.tokensByElement.add(e.element,e)}tokenUnmatched(e){this.delegate.tokenUnmatched(e),this.tokensByElement.delete(e.element,e)}refreshTokensForElement(e){const t=this.tokensByElement.getValuesForKey(e),i=this.readTokensForElement(e),o=kT(t,i).findIndex(([l,u])=>!MT(l,u));return o==-1?[[],[]]:[t.slice(o),i.slice(o)]}readTokensForElement(e){const t=this.attributeName,i=e.getAttribute(t)||"";return xT(i,e,t)}}function xT(r,e,t){return r.trim().split(/\s+/).filter(i=>i.length).map((i,o)=>({element:e,attributeName:t,content:i,index:o}))}function kT(r,e){const t=Math.max(r.length,e.length);return Array.from({length:t},(i,o)=>
vendor: 2,074 bytes, line 2
2[r[o],e[o]])}function MT(r,e){return r&&e&&r.index==e.index&&r.content==e.content}class pg{constructor(e,t,i){this.tokenListObserver=new gg(e,t,this),this.delegate=i,this.parseResultsByToken=new WeakMap,this.valuesByTokenByElement=new WeakMap}get started(){return this.tokenListObserver.started}start(){this.tokenListObserver.start()}stop(){this.tokenListObserver.stop()}refresh(){this.tokenListObserver.refresh()}get element(){return this.tokenListObserver.element}get attributeName(){return this.tokenListObserver.attributeName}tokenMatched(e){const{element:t}=e,{value:i}=this.fetchParseResultForToken(e);i&&(this.fetchValuesByTokenForElement(t).set(e,i),this.delegate.elementMatchedValue(t,i))}tokenUnmatched(e){const{element:t}=e,{value:i}=this.fetchParseResultForToken(e);i&&(this.fetchValuesByTokenForElement(t).delete(e),this.delegate.elementUnmatchedValue(t,i))}fetchParseResultForToken(e){let t=this.parseResultsByToken.get(e);return t||(t=this.parseToken(e),this.parseResultsByToken.set(e,t)),t}fetchValuesByTokenForElement(e){let t=this.valuesByTokenByElement.get(e);return t||(t=new Map,this.valuesByTokenByElement.set(e,t)),t}parseToken(e){try{return{value:this.delegate.parseValueForToken(e)}}catch(t){return{error:t}}}}class DT{constructor(e,t){this.context=e,this.delegate=t,this.bindingsByAction=new Map}start(){this.valueListObserver||(this.valueListObserver=new pg(this.element,this.actionAttribute,this),this.valueListObserver.start())}stop(){this.valueListObserver&&(this.valueListObserver.stop(),delete this.valueListObserver,this.disconnectAllActions())}get element(){return this.context.element}get identifier(){return this.context.identifier}get actionAttribute(){return this.schema.actionAttribute}get schema(){return this.context.schema}get bindings(){return Array.from(this.bindingsByAction.values())}connectAction(e){const t=new OT(this.context,e);this.bindingsByAction.set(e,t),this.delegate.bindingConnected(t)}disconnectAction(e){const t=this.bindingsByAction.get(e);t&&(this.bindingsByAction.delete(e),this.delegate.bindingDisconnected(t))}
2disconnectAllActions(){this.bindings.forEach(e=>this.delegate.bindingDisconnected(e,!0)),this.bindingsByAction.clear()}parseValueForToken(e){const t=ST.forToken(e,this.schema);if(t.identifier==this.identifier)return t}elementMatchedValue(e,t){this.connectAction(t)}elementUnmatchedValue(e,t){this.disconnectAction(t)}}class $T{constructor(e,t){this.context=e,this.receiver=t,this.stringMapObserver=new PT(this.element,this),this.valueDescriptorMap=this.controller.valueDescriptorMap}start(){this.stringMapObserver.start(),this.invokeChangedCallbacksForDefaultValues()}stop(){this.stringMapObserver.stop()}get element(){return this.context.element}get controller(){return this.context.controller}getStringMapKeyForAttribute(e){if(e in this.valueDescriptorMap)return this.valueDescriptorMap[e].name}stringMapKeyAdded(e,t){const i=this.valueDescriptorMap[t];this.hasValue(e)||this.invokeChangedCallback(e,i.writer(this.receiver[e]),i.writer(i.defaultValue))}stringMapValueChanged(e,t,i){const o=this.valueDescriptorNameMap[t];e!==null&&(i===null&&(i=o.writer(o.defaultValue)),this.invokeChangedCallback(t,e,i))}stringMapKeyRemoved(e,t,i){const o=this.valueDescriptorNameMap[e];this.hasValue(e)?this.invokeChangedCallback(e,o.writer(this.receiver[e]),i):this.invokeChangedCallback(e,o.writer(o.defaultValue),i)}invokeChangedCallbacksForDefaultValues(){for(const{key:e,name:t,defaultValue:i,writer:o}of this.valueDescriptors)i!=null&&!this.controller.data.has(e)&&this.invokeChangedCallback(t,o(i),void 0)}invokeChangedCallback(e,t,i){const o=`${e}Changed`,l=this.receiver[o];if(typeof l=="function"){const u=this.valueDescriptorNameMap[e];try{const d=u.reader(t);let p=i;i&&(p=u.reader(i)),l.call(this.receiver,d,p)}catch(d){throw d instanceof TypeError&&(d.message=`Stimulus Value "${this.context.identifier}.${u.name}" - ${d.message}`),d}}}get valueDescriptors(){const{valueDescriptorMap:e}=this;return Object.keys(e).map(t=>e[t])}get valueDescriptorNameMap(){const e={};return Object.keys(this.valueDescriptorMap).forEach(t=>{const i=this.valueDescriptorMap[t];e[i.name]=i}),e}hasValue(e){const t=this.valueDescriptorNameMap[e],i=`has${Hi(t.name)}`;return this.receiver[i]}}class FT{constructor(e,t){this.context=e,this.delegate=t,this.targetsByName=new qr}start(){this.tokenListObserver||(this.tokenListObserver=new gg(this.element,this.attributeName,this),this.tokenListObserver.start())}stop(){this.tokenListObserver&&(this.disconnectAllTargets(),this.tokenListObserver.stop(),delete this.tokenListObserver)}tokenMatched({element:e,content:t}){this.scope.containsElement(e)&&this.connectTarget(e,t)}tokenUnmatched({element:e,content:t}){this.disconnectTarget(e,t)}connectTarget(e,t){var i;this.targetsByName.has(t,e)||(this.targetsByName.add(t,e),(i=this.tokenListObserver)===null||i===void 0||i.pause(()=>this.delegate.targetConnected(e,t)))}disconnectTarget(e,t){var i;this.targetsByName.has(t,e)&&(this.targetsByName.delete(t,e),(i=this.tokenListObserver)===null||i===void 0||i.pause(()=>this.delegate.targetDisconnected(e,t)))}disconnectAllTargets(){for(const e of this.targetsByName.keys)for(const t of this.targetsByName.getValuesForKey(e))this.disconnectTarget(t,e)}get attributeName(){return`data-${this.context.identifier}-target`}get element(){return this.context.element}get scope(){return this.context.scope}}function qi(r,e){const t=mg(r);return Array.from(t.reduce((i,o)=>(BT(o,e).forEach(l=>i.add(l)),i),new Set))}function NT(r,e){return mg(r).reduce((i,o)=>(i.push(...UT(o,e)),i),[])}function mg(r){const e=[];for(;r;)e.push(r),r=Object.getPrototypeOf(r);return e.reverse()}function BT(r,e){const t=r[e];return Array.isArray(t)?t:[]}function UT(r,e){const t=r[e];return t?Object.keys(t).map(i=>[i,t[i]]):[]}class HT{constructor(e,t){this.started=!1,this.context=e,this.delegate=t,this.outletsByName=new qr,this.outletElementsByName=new qr,this.selectorObserverMap=new Map,this.attributeObserverMap=new Map}start(){this.started||(this.outletDefinitions.forEach(e=>{this.setupSelectorObserverForOutlet(e),this.setupAttributeObserverForOutlet(e)}
vendor: 5,000 bytes, line 2
2),this.started=!0,this.dependentContexts.forEach(e=>e.refresh()))}refresh(){this.selectorObserverMap.forEach(e=>e.refresh()),this.attributeObserverMap.forEach(e=>e.refresh())}stop(){this.started&&(this.started=!1,this.disconnectAllOutlets(),this.stopSelectorObservers(),this.stopAttributeObservers())}stopSelectorObservers(){this.selectorObserverMap.size>0&&(this.selectorObserverMap.forEach(e=>e.stop()),this.selectorObserverMap.clear())}stopAttributeObservers(){this.attributeObserverMap.size>0&&(this.attributeObserverMap.forEach(e=>e.stop()),this.attributeObserverMap.clear())}selectorMatched(e,t,{outletName:i}){const o=this.getOutlet(e,i);o&&this.connectOutlet(o,e,i)}selectorUnmatched(e,t,{outletName:i}){const o=this.getOutletFromMap(e,i);o&&this.disconnectOutlet(o,e,i)}selectorMatchElement(e,{outletName:t}){const i=this.selector(t),o=this.hasOutlet(e,t),l=e.matches(`[${this.schema.controllerAttribute}~=${t}]`);return i?o&&l&&e.matches(i):!1}elementMatchedAttribute(e,t){const i=this.getOutletNameFromOutletAttributeName(t);i&&this.updateSelectorObserverForOutlet(i)}elementAttributeValueChanged(e,t){const i=this.getOutletNameFromOutletAttributeName(t);i&&this.updateSelectorObserverForOutlet(i)}elementUnmatchedAttribute(e,t){const i=this.getOutletNameFromOutletAttributeName(t);i&&this.updateSelectorObserverForOutlet(i)}connectOutlet(e,t,i){var o;this.outletElementsByName.has(i,t)||(this.outletsByName.add(i,e),this.outletElementsByName.add(i,t),(o=this.selectorObserverMap.get(i))===null||o===void 0||o.pause(()=>this.delegate.outletConnected(e,t,i)))}disconnectOutlet(e,t,i){var o;this.outletElementsByName.has(i,t)&&(this.outletsByName.delete(i,e),this.outletElementsByName.delete(i,t),(o=this.selectorObserverMap.get(i))===null||o===void 0||o.pause(()=>this.delegate.outletDisconnected(e,t,i)))}disconnectAllOutlets(){for(const e of this.outletElementsByName.keys)for(const t of this.outletElementsByName.getValuesForKey(e))for(const i of this.outletsByName.getValuesForKey(e))this.disconnectOutlet(i,t,e)}updateSelectorObserverForOutlet(e){const t=this.selectorObserverMap.get(e);t&&(t.selector=this.selector(e))}setupSelectorObserverForOutlet(e){const t=this.selector(e),i=new RT(document.body,t,this,{outletName:e});this.selectorObserverMap.set(e,i),i.start()}setupAttributeObserverForOutlet(e){const t=this.attributeNameForOutletName(e),i=new dg(this.scope.element,t,this);this.attributeObserverMap.set(e,i),i.start()}selector(e){return this.scope.outlets.getSelectorForOutletName(e)}attributeNameForOutletName(e){return this.scope.schema.outletAttributeForScope(this.identifier,e)}getOutletNameFromOutletAttributeName(e){return this.outletDefinitions.find(t=>this.attributeNameForOutletName(t)===e)}get outletDependencies(){const e=new qr;return this.router.modules.forEach(t=>{const i=t.definition.controllerConstructor;qi(i,"outlets").forEach(l=>e.add(l,t.identifier))}),e}get outletDefinitions(){return this.outletDependencies.getKeysForValue(this.identifier)}get dependentControllerIdentifiers(){return this.outletDependencies.getValuesForKey(this.identifier)}get dependentContexts(){const e=this.dependentControllerIdentifiers;return this.router.contexts.filter(t=>e.includes(t.identifier))}hasOutlet(e,t){return!!this.getOutlet(e,t)||!!this.getOutletFromMap(e,t)}getOutlet(e,t){return this.application.getControllerForElementAndIdentifier(e,t)}getOutletFromMap(e,t){return this.outletsByName.getValuesForKey(t).find(i=>i.element===e)}get scope(){return this.context.scope}get schema(){return this.context.schema}get identifier(){return this.context.identifier}get application(){return this.context.application}get router(){return this.application.router}}class qT{constructor(e,t){this.logDebugActivity=(i,o={})=>{const{identifier:l,controller:u,element:d}=this;o=Object.assign({identifier:l,controller:u,element:d},o),this.application.logDebugActivity(this.identifier,i,o)},this.module=e,this.scope=t,this.controller=new e.controllerConstructor(this),this.bindingObserver=new DT(this,this.dispatcher),this.valueObserver=new $T(this,this.controller),this.targetObserver=new FT(this,this),this.outletObserver=new HT(this,this);try{this.controller.initialize(),this.logDebugActivity("initialize")}catch(i){this.handleError(i,"initializing controller")}}connect(){this.bindingObserver.start(),this.valueObserver.start(),this.targetObserver.start(),this.outletObserver.start();try{this.controller.connect(),this.logDebugActivity("connect")}catch(e){this.handleError(e,"connecting controller")}}refresh(){this.outletObserver.refresh()}disconnect(){try{this.controller.disconnect(),this.logDebugActivity("disconnect")}catch(e){this.handleError(e,"disconnecting controller")}this.outletObserver.stop(),this.targetObserver.stop(),this.valueObserver.stop(),this.bindingObserver.stop()}get application(){return this.module.application}get identifier(){return this.module.identifier}get schema(){return this.application.schema}get dispatcher(){return this.application.dispatcher}
2get element(){return this.scope.element}get parentElement(){return this.element.parentElement}handleError(e,t,i={}){const{identifier:o,controller:l,element:u}=this;i=Object.assign({identifier:o,controller:l,element:u},i),this.application.handleError(e,`Error ${t}`,i)}targetConnected(e,t){this.invokeControllerMethod(`${t}TargetConnected`,e)}targetDisconnected(e,t){this.invokeControllerMethod(`${t}TargetDisconnected`,e)}outletConnected(e,t,i){this.invokeControllerMethod(`${pl(i)}OutletConnected`,e,t)}outletDisconnected(e,t,i){this.invokeControllerMethod(`${pl(i)}OutletDisconnected`,e,t)}invokeControllerMethod(e,...t){const i=this.controller;typeof i[e]=="function"&&i[e](...t)}}function VT(r){return jT(r,WT(r))}function jT(r,e){const t=XT(r),i=zT(r.prototype,e);return Object.defineProperties(t.prototype,i),t}function WT(r){return qi(r,"blessings").reduce((t,i)=>{const o=i(r);for(const l in o){const u=t[l]||{};t[l]=Object.assign(u,o[l])}return t},{})}function zT(r,e){return GT(e).reduce((t,i)=>{const o=KT(r,e,i);return o&&Object.assign(t,{[i]:o}),t},{})}function KT(r,e,t){const i=Object.getOwnPropertyDescriptor(r,t);if(!(i&&"value"in i)){const l=Object.getOwnPropertyDescriptor(e,t).value;return i&&(l.get=i.get||l.get,l.set=i.set||l.set),l}}const GT=typeof Object.getOwnPropertySymbols=="function"?r=>[...Object.getOwnPropertyNames(r),...Object.getOwnPropertySymbols(r)]:Object.getOwnPropertyNames,XT=(()=>{function r(t){function i(){return Reflect.construct(t,arguments,new.target)}return i.prototype=Object.create(t.prototype,{constructor:{value:i}}),Reflect.setPrototypeOf(i,t),i}function e(){const i=r(function(){this.a.call(this)});return i.prototype.a=function(){},new i}try{return e(),r}catch{return i=>class extends i{}}})();function YT(r){return{identifier:r.identifier,controllerConstructor:VT(r.controllerConstructor)}}class QT{constructor(e,t){this.application=e,this.definition=YT(t),this.contextsByScope=new WeakMap,this.connectedContexts=new Set}get identifier(){return this.definition.identifier}get controllerConstructor(){return this.definition.controllerConstructor}get contexts(){return Array.from(this.connectedContexts)}connectContextForScope(e){const t=this.fetchContextForScope(e);this.connectedContexts.add(t),t.connect()}disconnectContextForScope(e){const t=this.contextsByScope.get(e);t&&(this.connectedContexts.delete(t),t.disconnect())}fetchContextForScope(e){let t=this.contextsByScope.get(e);return t||(t=new qT(this,e),this.contextsByScope.set(e,t)),t}}class ZT{constructor(e){this.scope=e}has(e){return this.data.has(this.getDataKey(e))}get(e){return this.getAll(e)[0]}getAll(e){const t=this.data.get(this.getDataKey(e))||"";return ET(t)}getAttributeName(e){return this.data.getAttributeNameForKey(this.getDataKey(e))}getDataKey(e){return`${e}-class`}get data(){return this.scope.data}}class JT{constructor(e){this.scope=e}get element(){return this.scope.element}get identifier(){return this.scope.identifier}get(e){const t=this.getAttributeNameForKey(e);return this.element.getAttribute(t)}set(e,t){const i=this.getAttributeNameForKey(e);return this.element.setAttribute(i,t),this.get(e)}has(e){const t=this.getAttributeNameForKey(e);return this.element.hasAttribute(t)}delete(e){if(this.has(e)){const t=this.getAttributeNameForKey(e);return this.element.removeAttribute(t),!0}else return!1}getAttributeNameForKey(e){return`data-${this.identifier}-${ug(e)}`}}class eO{constructor(e){this.warnedKeysByObject=new WeakMap,this.logger=e}warn(e,t,i){let o=this.warnedKeysByObject.get(e);o||(o=new Set,this.warnedKeysByObject.set(e,o)),o.has(t)||(o.add(t),this.logger.warn(i,e))}}function vl(r,e){return`[${r}~="${e}"]`}class tO{constructor(e){this.scope=e}get element(){return this.scope.element}get identifier(){return this.scope.identifier}get schema(){return this.scope.schema}has(e){return this.find(e)!=null}find(...e){return e.reduce((t,i)=>t||this.findTarget(i)||this.findLegacyTarget(i),void 0)}findAll(...e){return e.reduce((t,i)=>[...t,...this.findAllTargets(i),...this.findAllLegacyTargets(i)],[])}findTarget(e){const t=this.getSelectorForTargetName(e);return this.scope.findElement(t)}findAllTargets(e){const t=this.getSelectorForTargetName(e);return this.scope.findAllElements(t)}getSelectorForTargetName(e){const t=this.schema.targetAttributeForScope(this.identifier);return vl(t,e)}findLegacyTarget(e){const t=this.getLegacySelectorForTargetName(e);return this.deprecate(this.scope.findElement(t),e)}findAllLegacyTargets(e){const t=this.getLegacySelectorForTargetName(e);return this.scope.findAllElements(t).map(i=>this.deprecate(i,e))}getLegacySelectorForTargetName(e){const t=`${this.identifier}.${e}`;return vl(this.schema.targetAttribute,t)}deprecate(e,t){if(e){const{identifier:i}=this,o=this.schema.targetAttribute,l=this.schema.targetAttributeForScope(i);this.guide.warn(e,`target:${t}`,`Please replace ${o}="${i}.${t}" with ${l}="${t}". The ${o} attribute is deprecated and will be removed in a future version of Stimulus.`)}return e}get guide(){return this.scope.guide}}class rO{constructor(e,t){this.scope=e,this.controllerElement=t}
vendor: 4,742 bytes, line 2
2get element(){return this.scope.element}get identifier(){return this.scope.identifier}get schema(){return this.scope.schema}has(e){return this.find(e)!=null}find(...e){return e.reduce((t,i)=>t||this.findOutlet(i),void 0)}findAll(...e){return e.reduce((t,i)=>[...t,...this.findAllOutlets(i)],[])}getSelectorForOutletName(e){const t=this.schema.outletAttributeForScope(this.identifier,e);return this.controllerElement.getAttribute(t)}findOutlet(e){const t=this.getSelectorForOutletName(e);if(t)return this.findElement(t,e)}findAllOutlets(e){const t=this.getSelectorForOutletName(e);return t?this.findAllElements(t,e):[]}findElement(e,t){return this.scope.queryElements(e).filter(o=>this.matchesElement(o,e,t))[0]}findAllElements(e,t){return this.scope.queryElements(e).filter(o=>this.matchesElement(o,e,t))}matchesElement(e,t,i){const o=e.getAttribute(this.scope.schema.controllerAttribute)||"";return e.matches(t)&&o.split(" ").includes(i)}}class ac{constructor(e,t,i,o){this.targets=new tO(this),this.classes=new ZT(this),this.data=new JT(this),this.containsElement=l=>l.closest(this.controllerSelector)===this.element,this.schema=e,this.element=t,this.identifier=i,this.guide=new eO(o),this.outlets=new rO(this.documentScope,t)}findElement(e){return this.element.matches(e)?this.element:this.queryElements(e).find(this.containsElement)}findAllElements(e){return[...this.element.matches(e)?[this.element]:[],...this.queryElements(e).filter(this.containsElement)]}queryElements(e){return Array.from(this.element.querySelectorAll(e))}get controllerSelector(){return vl(this.schema.controllerAttribute,this.identifier)}get isDocumentScope(){return this.element===document.documentElement}get documentScope(){return this.isDocumentScope?this:new ac(this.schema,document.documentElement,this.identifier,this.guide.logger)}}class nO{constructor(e,t,i){this.element=e,this.schema=t,this.delegate=i,this.valueListObserver=new pg(this.element,this.controllerAttribute,this),this.scopesByIdentifierByElement=new WeakMap,this.scopeReferenceCounts=new WeakMap}start(){this.valueListObserver.start()}stop(){this.valueListObserver.stop()}get controllerAttribute(){return this.schema.controllerAttribute}parseValueForToken(e){const{element:t,content:i}=e;return this.parseValueForElementAndIdentifier(t,i)}parseValueForElementAndIdentifier(e,t){const i=this.fetchScopesByIdentifierForElement(e);let o=i.get(t);return o||(o=this.delegate.createScopeForElementAndIdentifier(e,t),i.set(t,o)),o}elementMatchedValue(e,t){const i=(this.scopeReferenceCounts.get(t)||0)+1;this.scopeReferenceCounts.set(t,i),i==1&&this.delegate.scopeConnected(t)}elementUnmatchedValue(e,t){const i=this.scopeReferenceCounts.get(t);i&&(this.scopeReferenceCounts.set(t,i-1),i==1&&this.delegate.scopeDisconnected(t))}fetchScopesByIdentifierForElement(e){let t=this.scopesByIdentifierByElement.get(e);return t||(t=new Map,this.scopesByIdentifierByElement.set(e,t)),t}}class iO{constructor(e){this.application=e,this.scopeObserver=new nO(this.element,this.schema,this),this.scopesByIdentifier=new qr,this.modulesByIdentifier=new Map}get element(){return this.application.element}get schema(){return this.application.schema}get logger(){return this.application.logger}get controllerAttribute(){return this.schema.controllerAttribute}get modules(){return Array.from(this.modulesByIdentifier.values())}get contexts(){return this.modules.reduce((e,t)=>e.concat(t.contexts),[])}start(){this.scopeObserver.start()}stop(){this.scopeObserver.stop()}loadDefinition(e){this.unloadIdentifier(e.identifier);const t=new QT(this.application,e);this.connectModule(t);const i=e.controllerConstructor.afterLoad;i&&i.call(e.controllerConstructor,e.identifier,this.application)}unloadIdentifier(e){const t=this.modulesByIdentifier.get(e);t&&this.disconnectModule(t)}getContextForElementAndIdentifier(e,t){const i=this.modulesByIdentifier.get(t);if(i)return i.contexts.find(o=>o.element==e)}proposeToConnectScopeForElementAndIdentifier(e,t){const i=this.scopeObserver.parseValueForElementAndIdentifier(e,t);i?this.scopeObserver.elementMatchedValue(i.element,i):console.error(`Couldn't find or create scope for identifier: "${t}" and element:`,e)}handleError(e,t,i){this.application.handleError(e,t,i)}createScopeForElementAndIdentifier(e,t){return new ac(this.schema,e,t,this.logger)}scopeConnected(e){this.scopesByIdentifier.add(e.identifier,e);const t=this.modulesByIdentifier.get(e.identifier);t&&t.connectContextForScope(e)}scopeDisconnected(e){this.scopesByIdentifier.delete(e.identifier,e);const t=this.modulesByIdentifier.get(e.identifier);t&&t.disconnectContextForScope(e)}connectModule(e){this.modulesByIdentifier.set(e.identifier,e),this.scopesByIdentifier.getValuesForKey(e.identifier).forEach(i=>
2e.connectContextForScope(i))}disconnectModule(e){this.modulesByIdentifier.delete(e.identifier),this.scopesByIdentifier.getValuesForKey(e.identifier).forEach(i=>e.disconnectContextForScope(i))}}const sO={controllerAttribute:"data-controller",actionAttribute:"data-action",targetAttribute:"data-target",targetAttributeForScope:r=>`data-${r}-target`,outletAttributeForScope:(r,e)=>`data-${r}-${e}-outlet`,keyMappings:Object.assign(Object.assign({enter:"Enter",tab:"Tab",esc:"Escape",space:" ",up:"ArrowUp",down:"ArrowDown",left:"ArrowLeft",right:"ArrowRight",home:"Home",end:"End",page_up:"PageUp",page_down:"PageDown"},Id("abcdefghijklmnopqrstuvwxyz".split("").map(r=>[r,r]))),Id("0123456789".split("").map(r=>[r,r])))};function Id(r){return r.reduce((e,[t,i])=>Object.assign(Object.assign({},e),{[t]:i}),{})}class oO{constructor(e=document.documentElement,t=sO){this.logger=console,this.debug=!1,this.logDebugActivity=(i,o,l={})=>{this.debug&&this.logFormattedMessage(i,o,l)},this.element=e,this.schema=t,this.dispatcher=new pT(this),this.router=new iO(this),this.actionDescriptorFilters=Object.assign({},mT)}static start(e,t){const i=new this(e,t);return i.start(),i}async start(){await aO(),this.logDebugActivity("application","starting"),this.dispatcher.start(),this.router.start(),this.logDebugActivity("application","start")}stop(){this.logDebugActivity("application","stopping"),this.dispatcher.stop(),this.router.stop(),this.logDebugActivity("application","stop")}register(e,t){this.load({identifier:e,controllerConstructor:t})}registerActionOption(e,t){this.actionDescriptorFilters[e]=t}load(e,...t){(Array.isArray(e)?e:[e,...t]).forEach(o=>{o.controllerConstructor.shouldLoad&&this.router.loadDefinition(o)})}unload(e,...t){(Array.isArray(e)?e:[e,...t]).forEach(o=>this.router.unloadIdentifier(o))}get controllers(){return this.router.contexts.map(e=>e.controller)}getControllerForElementAndIdentifier(e,t){const i=this.router.getContextForElementAndIdentifier(e,t);return i?i.controller:null}handleError(e,t,i){var o;this.logger.error(`%s 3 4%o 5 6%o`,t,e,i),(o=window.onerror)===null||o===void 0||o.call(window,t,"",0,0,e)}logFormattedMessage(e,t,i={}){i=Object.assign({application:this},i),this.logger.groupCollapsed(`${e} #${t}`),this.logger.log("details:",Object.assign({},i)),this.logger.groupEnd()}}function aO(){return new Promise(r=>{document.readyState=="loading"?document.addEventListener("DOMContentLoaded",()=>r()):r()})}function lO(r){return qi(r,"classes").reduce((t,i)=>Object.assign(t,cO(i)),{})}function cO(r){return{[`${r}Class`]:{get(){const{classes:e}=this;if(e.has(r))return e.get(r);{const t=e.getAttributeName(r);throw new Error(`Missing attribute "${t}"`)}}},[`${r}Classes`]:{get(){return this.classes.getAll(r)}},[`has${Hi(r)}Class`]:{get(){return this.classes.has(r)}}}}function uO(r){return qi(r,"outlets").reduce((t,i)=>Object.assign(t,hO(i)),{})}function Ld(r,e,t){return r.application.getControllerForElementAndIdentifier(e,t)}function Rd(r,e,t){let i=Ld(r,e,t);if(i||(r.application.router.proposeToConnectScopeForElementAndIdentifier(e,t),i=Ld(r,e,t),i))return i}function hO(r){const e=pl(r);return{[`${e}Outlet`]:{get(){const t=this.outlets.find(r),i=this.outlets.getSelectorForOutletName(r);if(t){const o=Rd(this,t,r);if(o)return o;throw new Error(`The provided outlet element is missing an outlet controller "${r}" instance for host controller "${this.identifier}"`)}throw new Error(`Missing outlet element "${r}" for host controller "${this.identifier}". Stimulus couldn't find a matching outlet element using selector "${i}".`)}},[`${e}Outlets`]:{get(){const t=this.outlets.findAll(r);return t.length>0?t.map(i=>{const o=Rd(this,i,r);if(o)return o;console.warn(`The provided outlet element is missing an outlet controller "${r}" instance for host controller "${this.identifier}"`,i)}).filter(i=>i):[]}},[`${e}OutletElement`]:{get(){const t=this.outlets.find(r),i=this.outlets.getSelectorForOutletName(r);if(t)return t;throw new Error(`Missing outlet element "${r}" for host controller "${this.identifier}". Stimulus couldn't find a matching outlet element using selector "${i}".`)}},[`${e}OutletElements`]:{get(){return this.outlets.findAll(r)}},[`has${Hi(e)}Outlet`]:{get(){return this.outlets.has(r)}}}}function dO(r){return qi(r,"targets").reduce((t,i)=>Object.assign(t,fO(i)),{})}function fO(r){return{[`${r}Target`]:{get(){const e=this.targets.find(r);if(e)return e;throw new Error(`Missing target element "${r}" for "${this.identifier}" controller`)}},[`${r}Targets`]:{get(){return this.targets.findAll(r)}},[`has${Hi(r)}Target`]:{get(){return this.targets.has(r)}}}}function gO(r){const e=NT(r,"values"),t={valueDescriptorMap:{get(){return e.reduce((i,o)=>{const l=vg(o,this.identifier),u=this.data.getAttributeNameForKey(l.key);return Object.assign(i,{[u]:l})},{})}}};return e.reduce((i,o)=>Object.assign(i,pO(o)),t)}function pO(r,e){const t=vg(r,e),{key:i,name:o,reader:l,writer:u}=t;return{[o]:{get(){const d=this.data.get(i);return d!==null?l(d):t.defaultValue},set(d){d===void 0?this.data.delete(i):this.data.set(i,u(d))}},[`has${Hi(o)}
6`]:{get(){return this.data.has(i)||t.hasCustomDefaultValue}}}}function vg([r,e],t){return _O({controller:t,token:r,typeDefinition:e})}function Js(r){switch(r){case Array:return"array";case Boolean:return"boolean";case Number:return"number";case Object:return"object";case String:return"string"}}function yi(r){switch(typeof r){case"boolean":return"boolean";case"number":return"number";case"string":return"string"}if(Array.isArray(r))return"array";if(Object.prototype.toString.call(r)==="[object Object]")return"object"}function mO(r){const{controller:e,token:t,typeObject:i}=r,o=Td(i.type),l=Td(i.default),u=o&&l,d=o&&!l,p=!o&&l,v=Js(i.type),S=yi(r.typeObject.default);if(d)return v;if(p)return S;if(v!==S){const O=e?`${e}.${t}`:t;throw new Error(`The specified default value for the Stimulus Value "${O}" must match the defined type "${v}". The provided default value of "${i.default}" is of type "${S}".`)}if(u)return v}function vO(r){const{controller:e,token:t,typeDefinition:i}=r,l=mO({controller:e,token:t,typeObject:i}),u=yi(i),d=Js(i),p=l||u||d;if(p)return p;const v=e?`${e}.${i}`:t;throw new Error(`Unknown value type "${v}" for "${t}" value`)}function bO(r){const e=Js(r);if(e)return Pd[e];const t=ml(r,"default"),i=ml(r,"type"),o=r;if(t)return o.default;if(i){const{type:l}=o,u=Js(l);if(u)return Pd[u]}return r}function _O(r){const{token:e,typeDefinition:t}=r,i=`${ug(e)}-value`,o=vO(r);return{type:o,key:i,name:oc(i),get defaultValue(){return bO(t)},get hasCustomDefaultValue(){return yi(t)!==void 0},reader:wO[o],writer:xd[o]||xd.default}}const Pd={get array(){return[]},boolean:!1,number:0,get object(){return{}},string:""},wO={array(r){const e=JSON.parse(r);if(!Array.isArray(e))throw new TypeError(`expected value of type "array" but instead got value "${r}" of type "${yi(e)}"`);return e},boolean(r){return!(r=="0"||String(r).toLowerCase()=="false")},number(r){return Number(r.replace(/_/g,""))},object(r){const e=JSON.parse(r);if(e===null||typeof e!="object"||Array.isArray(e))throw new TypeError(`expected value of type "object" but instead got value "${r}" of type "${yi(e)}"`);return e},string(r){return r}},xd={default:yO,array:kd,object:kd};function kd(r){return JSON.stringify(r)}function yO(r){return`${r}`}class he{constructor(e){this.context=e}static get shouldLoad(){return!0}static afterLoad(e,t){}get application(){return this.context.application}get scope(){return this.context.scope}get element(){return this.scope.element}get identifier(){return this.scope.identifier}get targets(){return this.scope.targets}get outlets(){return this.scope.outlets}get classes(){return this.scope.classes}get data(){return this.scope.data}initialize(){}connect(){}disconnect(){}dispatch(e,{target:t=this.element,detail:i={},prefix:o=this.identifier,bubbles:l=!0,cancelable:u=!0}={}){const d=o?`${o}:${e}`:e,p=new CustomEvent(d,{detail:i,bubbles:l,cancelable:u});return t.dispatchEvent(p),p}}he.blessings=[lO,dO,gO,uO];he.targets=[];he.outlets=[];he.values={};/*! 7Turbo 8.0.23 8Copyright © 2026 37signals LLC 9 */const wn={eager:"eager",lazy:"lazy"},mo=class mo extends HTMLElement{constructor(){super();y(this,"loaded",Promise.resolve());this.delegate=new mo.delegateConstructor(this)}static get observedAttributes(){return["disabled","loading","src"]}connectedCallback(){this.delegate.connect()}disconnectedCallback(){this.delegate.disconnect()}reload(){return this.delegate.sourceURLReloaded()}attributeChangedCallback(t){t=="loading"?this.delegate.loadingStyleChanged():t=="src"?this.delegate.sourceURLChanged():t=="disabled"&&this.delegate.disabledChanged()}get src(){return this.getAttribute("src")}set src(t){t?this.setAttribute("src",t):this.removeAttribute("src")}get refresh(){return this.getAttribute("refresh")}set refresh(t){t?this.setAttribute("refresh",t):this.removeAttribute("refresh")}get shouldReloadWithMorph(){return this.src&&this.refresh==="morph"}get loading(){return EO(this.getAttribute("loading")||"")}set loading(t){t?this.setAttribute("loading",t):this.removeAttribute("loading")}get disabled(){return this.hasAttribute("disabled")}set disabled(t){t?this.setAttribute("disabled",""):this.removeAttribute("disabled")}get autoscroll(){return this.hasAttribute("autoscroll")}set autoscroll(t){t?this.setAttribute("autoscroll",""):this.removeAttribute("autoscroll")}get complete(){return!this.delegate.isLoading}get isActive(){return this.ownerDocument===document&&!this.isPreview}get isPreview(){var t,i;return(i=(t=this.ownerDocument)==null?void 0:t.documentElement)==null?void 0:i.hasAttribute("data-turbo-preview")}};y(mo,"delegateConstructor");let pt=mo;function EO(r){switch(r.toLowerCase()){case"lazy":return wn.lazy;default:return wn.eager}}const SO={enabled:!0,progressBarDelay:500,unvisitableExtensions:new Set([".7z",".aac",".apk",".avi",".bmp",".bz2",".css",".csv",".deb",".dmg",".doc",".docx",".exe",".gif",".gz",".heic",".heif",".ico",".iso",".jpeg",".jpg",".js",".json",".m4a",".mkv",".mov",".mp3",".mp4",".mpeg",".mpg",".msi",".ogg",".ogv",".pdf",".pkg",".png",".ppt",".pptx",".rar",".rtf",".svg",".tar",".tif",".tiff",".txt",".wav",".webm",".webp",".wma",".wmv",".xls",".xlsx",".xml",".zip"])};function Ei(r){if(r.getAttribute("data-turbo-eval")=="false")return r;{const e=document.createElement("script"),t=Sg();return t&&(e.nonce=t),e.textContent=r.textContent,e.async=!1,AO(e,r),e}}function AO(r,e){for(const{name:t,value:i}of e.attributes)r.setAttribute(t,i)}function TO(r){const e=document.createElement("template");return e.innerHTML=r,e.content}
9function Te(r,{target:e,cancelable:t,detail:i}={}){const o=new CustomEvent(r,{cancelable:t,bubbles:!0,composed:!0,detail:i});return e&&e.isConnected?e.dispatchEvent(o):document.documentElement.dispatchEvent(o),o}function Md(r){r.preventDefault(),r.stopImmediatePropagation()}function vi(){return document.visibilityState==="hidden"?_g():bg()}function bg(){return new Promise(r=>requestAnimationFrame(()=>r()))}function _g(){return new Promise(r=>setTimeout(()=>r(),0))}function wg(r=""){return new DOMParser().parseFromString(r,"text/html")}function yg(r,...e){const t=OO(r,e).replace(/^\n/,"").split(` 10`),i=t[0].match(/^\s+/),o=i?i[0].length:0;return t.map(l=>l.slice(o)).join(` 11`)}function OO(r,e){return r.reduce((t,i,o)=>{const l=e[o]==null?"":e[o];return t+i+l},"")}function yr(){return Array.from({length:36}).map((r,e)=>e==8||e==13||e==18||e==23?"-":e==14?"4":e==19?(Math.floor(Math.random()*4)+8).toString(16):Math.floor(Math.random()*16).toString(16)).join("")}function eo(r,...e){for(const t of e.map(i=>i==null?void 0:i.getAttribute(r)))if(typeof t=="string")return t;return null}function CO(r,...e){return e.some(t=>t&&t.hasAttribute(r))}function to(...r){for(const e of r)e.localName=="turbo-frame"&&e.setAttribute("busy",""),e.setAttribute("aria-busy","true")}function ro(...r){for(const e of r)e.localName=="turbo-frame"&&e.removeAttribute("busy"),e.removeAttribute("aria-busy")}function IO(r,e=2e3){return new Promise(t=>{const i=()=>{r.removeEventListener("error",i),r.removeEventListener("load",i),t()};r.addEventListener("load",i,{once:!0}),r.addEventListener("error",i,{once:!0}),setTimeout(t,e)})}function Eg(r){switch(r){case"replace":return history.replaceState;case"advance":case"restore":return history.pushState}}function LO(r){return r=="advance"||r=="replace"||r=="restore"}function Vr(...r){const e=eo("data-turbo-action",...r);return LO(e)?e:null}function lc(r){return document.querySelector(`meta[name="${r}"]`)}function no(r){const e=lc(r);return e&&e.content}function Sg(){const r=lc("csp-nonce");if(r){const{nonce:e,content:t}=r;return e==""?t:e}}
11function RO(r,e){let t=lc(r);return t||(t=document.createElement("meta"),t.setAttribute("name",r),document.head.appendChild(t)),t.setAttribute("content",e),t}function An(r,e){var t;if(r instanceof Element)return r.closest(e)||An(r.assignedSlot||((t=r.getRootNode())==null?void 0:t.host),e)}function cc(r){return!!r&&r.closest("[inert], :disabled, [hidden], details:not([open]), dialog:not([open])")==null&&typeof r.focus=="function"}function Ag(r){return Array.from(r.querySelectorAll("[autofocus]")).find(cc)}async function PO(r,e){const t=e();r(),await bg();const i=e();return[t,i]}function Tg(r){if(r==="_blank")return!1;if(r){for(const e of document.getElementsByName(r))if(e instanceof HTMLIFrameElement)return!1;return!0}else return!0}function Og(r){const e=An(r,"a[href], a[xlink\\:href]");if(!e||e.href.startsWith("#")||e.hasAttribute("download"))return null;const t=e.getAttribute("target");return t&&t!=="_self"?null:e}function xO(r,e){let t=null;return(...i)=>{const o=()=>r.apply(this,i);clearTimeout(t),t=setTimeout(o,e)}}const kO={"aria-disabled":{beforeSubmit:r=>{r.setAttribute("aria-disabled","true"),r.addEventListener("click",Md)},afterSubmit:r=>{r.removeAttribute("aria-disabled"),r.removeEventListener("click",Md)}},disabled:{beforeSubmit:r=>r.disabled=!0,afterSubmit:r=>r.disabled=!1}};var Ii;class MO{constructor(e){le(this,Ii,null);Object.assign(this,e)}get submitter(){return K(this,Ii)}set submitter(e){ve(this,Ii,kO[e]||e)}}Ii=new WeakMap;const DO=new MO({mode:"on",submitter:"disabled"}),ke={drive:SO,forms:DO};function $e(r){return new URL(r.toString(),document.baseURI)}function bi(r){let e;if(r.hash)return r.hash.slice(1);if(e=r.href.match(/#(.*)$/))return e[1]}function uc(r,e){const t=(e==null?void 0:e.getAttribute("formaction"))||r.getAttribute("action")||r.action;return $e(t)}function $O(r){return(UO(r).match(/\.[^.]*$/)||[])[0]||""}function FO(r,e){const t=Dd(e.origin+e.pathname);return Dd(r.href)===t||r.href.startsWith(t)}function dr(r,e){return FO(r,e)&&!ke.drive.unvisitableExtensions.has($O(r))}function Cg(r){return $e(r.getAttribute("href")||"")}function NO(r){const e=bi(r);return e!=null?r.href.slice(0,-(e.length+1)):r.href}function js(r){return NO(r)}function Ig(r,e){return $e(r).href==$e(e).href}function BO(r){return r.pathname.split("/").slice(1)}function UO(r){return BO(r).slice(-1)[0]}function Dd(r){return r.endsWith("/")?r:r+"/"}class hc{constructor(e){this.response=e}get succeeded(){return this.response.ok}get failed(){return!this.succeeded}get clientError(){return this.statusCode>=400&&this.statusCode<=499}get serverError(){return this.statusCode>=500&&this.statusCode<=599}get redirected(){return this.response.redirected}get location(){return $e(this.response.url)}get isHTML(){return this.contentType&&this.contentType.match(/^(?:text\/([^\s;,]+\b)?html|application\/xhtml\+xml)\b/)}get statusCode(){return this.response.status}get contentType(){return this.header("Content-Type")}get responseText(){return this.response.clone().text()}get responseHTML(){return this.isHTML?this.response.clone().text():Promise.resolve(void 0)}header(e){return this.response.headers.get(e)}}class HO extends Set{constructor(e){super(),this.maxSize=e}add(e){if(this.size>=this.maxSize){const i=this.values().next().value;this.delete(i)}super.add(e)}}const Lg=new HO(20);function Rg(r,e={}){const t=new Headers(e.headers||{}),i=yr();return Lg.add(i),t.append("X-Turbo-Request-Id",i),window.fetch(r,{...e,headers:t})}function dc(r){switch(r.toLowerCase()){case"get":return gt.get;case"post":return gt.post;case"put":return gt.put;case"patch":return gt.patch;case"delete":return gt.delete}}const gt={get:"get",post:"post",put:"put",patch:"patch",delete:"delete"};function qO(r){switch(r.toLowerCase()){case Br.multipart:return Br.multipart;case Br.plain:return Br.plain;default:return Br.urlEncoded}}const Br={urlEncoded:"application/x-www-form-urlencoded",multipart:"multipart/form-data",plain:"text/plain"};var Li,Dn,Pg,xg;class Vi{constructor(e,t,i,o=new URLSearchParams,l=null,u=Br.urlEncoded){le(this,Dn);y(this,"abortController",new AbortController);le(this,Li,e=>{});var v;const[d,p]=$d($e(i),t,o,u);this.delegate=e,this.url=d,this.target=l,this.fetchOptions={credentials:"same-origin",redirect:"follow",method:t.toUpperCase(),headers:{...this.defaultHeaders}
11,body:p,signal:this.abortSignal,referrer:(v=this.delegate.referrer)==null?void 0:v.href},this.enctype=u}get method(){return this.fetchOptions.method}set method(e){const t=this.isSafe?this.url.searchParams:this.fetchOptions.body||new FormData,i=dc(e)||gt.get;this.url.search="";const[o,l]=$d(this.url,i,t,this.enctype);this.url=o,this.fetchOptions.body=l,this.fetchOptions.method=i.toUpperCase()}get headers(){return this.fetchOptions.headers}set headers(e){this.fetchOptions.headers=e}get body(){return this.isSafe?this.url.searchParams:this.fetchOptions.body}set body(e){this.fetchOptions.body=e}get location(){return this.url}get params(){return this.url.searchParams}get entries(){return this.body?Array.from(this.body.entries()):[]}cancel(){this.abortController.abort()}async perform(){const{fetchOptions:e}=this;this.delegate.prepareRequest(this);const t=await Q(this,Dn,Pg).call(this,e);try{this.delegate.requestStarted(this),t.detail.fetchRequest?this.response=t.detail.fetchRequest.response:this.response=Rg(this.url.href,e);const i=await this.response;return await this.receive(i)}catch(i){if(i.name!=="AbortError")throw Q(this,Dn,xg).call(this,i)&&this.delegate.requestErrored(this,i),i}finally{this.delegate.requestFinished(this)}}async receive(e){const t=new hc(e);return Te("turbo:before-fetch-response",{cancelable:!0,detail:{fetchResponse:t},target:this.target}).defaultPrevented?this.delegate.requestPreventedHandlingResponse(this,t):t.succeeded?this.delegate.requestSucceededWithResponse(this,t):this.delegate.requestFailedWithResponse(this,t),t}get defaultHeaders(){return{Accept:"text/html, application/xhtml+xml"}}get isSafe(){return fc(this.method)}get abortSignal(){return this.abortController.signal}acceptResponseType(e){this.headers.Accept=[e,this.headers.Accept].join(", ")}}Li=new WeakMap,Dn=new WeakSet,Pg=async function(e){const t=new Promise(o=>ve(this,Li,o)),i=Te("turbo:before-fetch-request",{cancelable:!0,detail:{fetchOptions:e,url:this.url,resume:K(this,Li)},target:this.target});return this.url=i.detail.url,i.defaultPrevented&&await t,i},xg=function(e){return!Te("turbo:fetch-request-error",{target:this.target,cancelable:!0,detail:{request:this,error:e}}).defaultPrevented};function fc(r){return dc(r)==gt.get}function $d(r,e,t,i){const o=Array.from(t).length>0?new URLSearchParams(kg(t)):r.searchParams;return fc(e)?[VO(r,o),null]:i==Br.urlEncoded?[r,o]:[r,t]}function kg(r){const e=[];for(const[t,i]of r)i instanceof File||e.push([t,i]);return e}function VO(r,e){const t=new URLSearchParams(kg(e));return r.search=t.toString(),r}class jO{constructor(e,t){y(this,"started",!1);y(this,"intersect",e=>{const t=e.slice(-1)[0];t!=null&&t.isIntersecting&&this.delegate.elementAppearedInViewport(this.element)});this.delegate=e,this.element=t,this.intersectionObserver=new IntersectionObserver(this.intersect)}start(){this.started||(this.started=!0,this.intersectionObserver.observe(this.element))}stop(){this.started&&(this.started=!1,this.intersectionObserver.unobserve(this.element))}}class Gr{static wrap(e){return typeof e=="string"?new this(TO(e)):e}constructor(e){this.fragment=WO(e)}}y(Gr,"contentType","text/vnd.turbo-stream.html");function WO(r){for(const e of r.querySelectorAll("turbo-stream")){const t=document.importNode(e,!0);for(const i of t.templateElement.content.querySelectorAll("script"))i.replaceWith(Ei(i));e.replaceWith(t)}return r}const zO=r=>r;var fr;class Mg{constructor(e,t=zO){y(this,"keys",[]);y(this,"entries",{});le(this,fr);this.size=e,ve(this,fr,t)}has(e){return K(this,fr).call(this,e)in this.entries}get(e){if(this.has(e)){const t=this.read(e);return this.touch(e),t}}put(e,t){return this.write(e,t),this.touch(e),t}clear(){for(const e of Object.keys(this.entries))this.evict(e)}read(e){return this.entries[K(this,fr).call(this,e)]}write(e,t){this.entries[K(this,fr).call(this,e)]=t}touch(e){e=K(this,fr).call(this,e);const t=this.keys.indexOf(e);t>-1&&this.keys.splice(t,1),this.keys.unshift(e),this.trim()}trim(){for(const e of this.keys.splice(this.size))this.evict(e)}evict(e){delete this.entries[e]}}fr=new WeakMap;const KO=100;var Ur,Cn;class GO extends Mg{constructor(t=1,i=KO){super(t,js);le(this,Ur,null);le(this,Cn,{});this.prefetchDelay=i}putLater(t,i,o){ve(this,Ur,setTimeout(()=>{i.perform(),this.put(t,i,o),ve(this,Ur,null)},this.prefetchDelay))}
11put(t,i,o=Dg){super.put(t,i),K(this,Cn)[js(t)]=new Date(new Date().getTime()+o)}clear(){super.clear(),K(this,Ur)&&clearTimeout(K(this,Ur))}evict(t){super.evict(t),delete K(this,Cn)[t]}has(t){if(super.has(t)){const i=K(this,Cn)[js(t)];return i&&i>Date.now()}else return!1}}Ur=new WeakMap,Cn=new WeakMap;const Dg=10*1e3,yn=new GO,gn={initialized:"initialized",requesting:"requesting",waiting:"waiting",receiving:"receiving",stopping:"stopping",stopped:"stopped"};class _o{constructor(e,t,i,o=!1){y(this,"state",gn.initialized);const l=e0(t,i),u=JO(ZO(t,i),l),d=XO(t,i),p=t0(t,i);this.delegate=e,this.formElement=t,this.submitter=i,this.fetchRequest=new Vi(this,l,u,d,t,p),this.mustRedirect=o}static confirmMethod(e){return Promise.resolve(confirm(e))}get method(){return this.fetchRequest.method}set method(e){this.fetchRequest.method=e}get action(){return this.fetchRequest.url.toString()}set action(e){this.fetchRequest.url=$e(e)}get body(){return this.fetchRequest.body}get enctype(){return this.fetchRequest.enctype}get isSafe(){return this.fetchRequest.isSafe}get location(){return this.fetchRequest.url}async start(){const{initialized:e,requesting:t}=gn,i=eo("data-turbo-confirm",this.submitter,this.formElement);if(!(typeof i=="string"&&!await(typeof ke.forms.confirm=="function"?ke.forms.confirm:_o.confirmMethod)(i,this.formElement,this.submitter))&&this.state==e)return this.state=t,this.fetchRequest.perform()}stop(){const{stopping:e,stopped:t}=gn;if(this.state!=e&&this.state!=t)return this.state=e,this.fetchRequest.cancel(),!0}prepareRequest(e){if(!e.isSafe){const t=YO(no("csrf-param"))||no("csrf-token");t&&(e.headers["X-CSRF-Token"]=t)}this.requestAcceptsTurboStreamResponse(e)&&e.acceptResponseType(Gr.contentType)}requestStarted(e){this.state=gn.waiting,this.submitter&&ke.forms.submitter.beforeSubmit(this.submitter),this.setSubmitsWith(),to(this.formElement),Te("turbo:submit-start",{target:this.formElement,detail:{formSubmission:this}}),this.delegate.formSubmissionStarted(this)}requestPreventedHandlingResponse(e,t){yn.clear(),this.result={success:t.succeeded,fetchResponse:t}}requestSucceededWithResponse(e,t){if(t.clientError||t.serverError){this.delegate.formSubmissionFailedWithResponse(this,t);return}if(yn.clear(),this.requestMustRedirect(e)&&QO(t)){const i=new Error("Form responses must redirect to another location");this.delegate.formSubmissionErrored(this,i)}else this.state=gn.receiving,this.result={success:!0,fetchResponse:t},this.delegate.formSubmissionSucceededWithResponse(this,t)}requestFailedWithResponse(e,t){this.result={success:!1,fetchResponse:t},this.delegate.formSubmissionFailedWithResponse(this,t)}requestErrored(e,t){this.result={success:!1,error:t},this.delegate.formSubmissionErrored(this,t)}requestFinished(e){this.state=gn.stopped,this.submitter&&ke.forms.submitter.afterSubmit(this.submitter),this.resetSubmitterText(),ro(this.formElement),Te("turbo:submit-end",{target:this.formElement,detail:{formSubmission:this,...this.result}}),this.delegate.formSubmissionFinished(this)}setSubmitsWith(){if(!(!this.submitter||!this.submitsWith)){if(this.submitter.matches("button"))this.originalSubmitText=this.submitter.innerHTML,this.submitter.innerHTML=this.submitsWith;else if(this.submitter.matches("input")){const e=this.submitter;this.originalSubmitText=e.value,e.value=this.submitsWith}}}resetSubmitterText(){if(!(!this.submitter||!this.originalSubmitText)){if(this.submitter.matches("button"))this.submitter.innerHTML=this.originalSubmitText;else if(this.submitter.matches("input")){const e=this.submitter;e.value=this.originalSubmitText}}}requestMustRedirect(e){return!e.isSafe&&this.mustRedirect}requestAcceptsTurboStreamResponse(e){return!e.isSafe||CO("data-turbo-stream",this.submitter,this.formElement)}get submitsWith(){var e;return(e=this.submitter)==null?void 0:e.getAttribute("data-turbo-submits-with")}}function XO(r,e){const t=new FormData(r),i=e==null?void 0:e.getAttribute("name"),o=e==null?void 0:e.getAttribute("value");return i&&t.append(i,o||""),t}function YO(r){if(r!=null){const t=(document.cookie?document.cookie.split("; "):[]).find(i=>i.startsWith(r));if(t){const i=t.split("=").slice(1).join("=");return i?decodeURIComponent(i):void 0}}}function QO(r){return r.statusCode==200&&!r.redirected}
11function ZO(r,e){const t=typeof r.action=="string"?r.action:null;return e!=null&&e.hasAttribute("formaction")?e.getAttribute("formaction")||"":r.getAttribute("action")||t||""}function JO(r,e){const t=$e(r);return fc(e)&&(t.search=""),t}function e0(r,e){const t=(e==null?void 0:e.getAttribute("formmethod"))||r.getAttribute("method")||"";return dc(t.toLowerCase())||gt.get}function t0(r,e){return qO((e==null?void 0:e.getAttribute("formenctype"))||r.enctype)}class wo{constructor(e){this.element=e}get activeElement(){return this.element.ownerDocument.activeElement}get children(){return[...this.element.children]}hasAnchor(e){return this.getElementForAnchor(e)!=null}getElementForAnchor(e){return e?this.element.querySelector(`[id='${e}'], a[name='${e}']`):null}get isConnected(){return this.element.isConnected}get firstAutofocusableElement(){return Ag(this.element)}get permanentElements(){return Fg(this.element)}getPermanentElementById(e){return $g(this.element,e)}getPermanentElementMapForSnapshot(e){const t={};for(const i of this.permanentElements){const{id:o}=i,l=e.getPermanentElementById(o);l&&(t[o]=[i,l])}return t}}function $g(r,e){return r.querySelector(`#${e}[data-turbo-permanent]`)}function Fg(r){return r.querySelectorAll("[id][data-turbo-permanent]")}class gc{constructor(e,t){y(this,"started",!1);y(this,"submitCaptured",()=>{this.eventTarget.removeEventListener("submit",this.submitBubbled,!1),this.eventTarget.addEventListener("submit",this.submitBubbled,!1)});y(this,"submitBubbled",e=>{if(!e.defaultPrevented){const t=e.target instanceof HTMLFormElement?e.target:void 0,i=e.submitter||void 0;t&&r0(t,i)&&n0(t,i)&&this.delegate.willSubmitForm(t,i)&&(e.preventDefault(),e.stopImmediatePropagation(),this.delegate.formSubmitted(t,i))}});this.delegate=e,this.eventTarget=t}start(){this.started||(this.eventTarget.addEventListener("submit",this.submitCaptured,!0),this.started=!0)}stop(){this.started&&(this.eventTarget.removeEventListener("submit",this.submitCaptured,!0),this.started=!1)}}function r0(r,e){return((e==null?void 0:e.getAttribute("formmethod"))||r.getAttribute("method"))!="dialog"}function n0(r,e){const t=(e==null?void 0:e.getAttribute("formtarget"))||r.getAttribute("target");return Tg(t)}var Ri,Pi;class Ng{constructor(e,t){le(this,Ri,e=>{});le(this,Pi,e=>{});this.delegate=e,this.element=t}scrollToAnchor(e){const t=this.snapshot.getElementForAnchor(e);t?(this.focusElement(t),this.scrollToElement(t)):this.scrollToPosition({x:0,y:0})}scrollToAnchorFromLocation(e){this.scrollToAnchor(bi(e))}scrollToElement(e){e.scrollIntoView()}focusElement(e){e instanceof HTMLElement&&(e.hasAttribute("tabindex")?e.focus():(e.setAttribute("tabindex","-1"),e.focus(),e.removeAttribute("tabindex")))}scrollToPosition({x:e,y:t}){this.scrollRoot.scrollTo(e,t)}scrollToTop(){this.scrollToPosition({x:0,y:0})}get scrollRoot(){return window}async render(e){const{isPreview:t,shouldRender:i,willRender:o,newSnapshot:l}=e,u=o;if(i)try{this.renderPromise=new Promise(S=>ve(this,Ri,S)),this.renderer=e,await this.prepareToRenderSnapshot(e);const d=new Promise(S=>ve(this,Pi,S)),p={resume:K(this,Pi),render:this.renderer.renderElement,renderMethod:this.renderer.renderMethod};this.delegate.allowsImmediateRender(l,p)||await d,await this.renderSnapshot(e),this.delegate.viewRenderedSnapshot(l,t,this.renderer.renderMethod),this.delegate.preloadOnLoadLinksForView(this.element),this.finishRenderingSnapshot(e)}finally{delete this.renderer,K(this,Ri).call(this,void 0),delete this.renderPromise}else u&&this.invalidate(e.reloadReason)}invalidate(e){this.delegate.viewInvalidated(e)}async prepareToRenderSnapshot(e){this.markAsPreview(e.isPreview),await e.prepareToRender()}markAsPreview(e){e?this.element.setAttribute("data-turbo-preview",""):this.element.removeAttribute("data-turbo-preview")}markVisitDirection(e){this.element.setAttribute("data-turbo-visit-direction",e)}unmarkVisitDirection(){this.element.removeAttribute("data-turbo-visit-direction")}async renderSnapshot(e){await e.render()}finishRenderingSnapshot(e){e.finishRendering()}}Ri=new WeakMap,Pi=new WeakMap;class i0 extends Ng{missing(){this.element.innerHTML='<strong class="turbo-frame-error">Content missing</strong>'}get snapshot(){return new wo(this.element)}}class Bg{constructor(e,t){y(this,"clickBubbled",e=>{this.clickEventIsSignificant(e)?this.clickEvent=e:delete this.clickEvent});
11y(this,"linkClicked",e=>{this.clickEvent&&this.clickEventIsSignificant(e)&&this.delegate.shouldInterceptLinkClick(e.target,e.detail.url,e.detail.originalEvent)&&(this.clickEvent.preventDefault(),e.preventDefault(),this.delegate.linkClickIntercepted(e.target,e.detail.url,e.detail.originalEvent)),delete this.clickEvent});y(this,"willVisit",e=>{delete this.clickEvent});this.delegate=e,this.element=t}start(){this.element.addEventListener("click",this.clickBubbled),document.addEventListener("turbo:click",this.linkClicked),document.addEventListener("turbo:before-visit",this.willVisit)}stop(){this.element.removeEventListener("click",this.clickBubbled),document.removeEventListener("turbo:click",this.linkClicked),document.removeEventListener("turbo:before-visit",this.willVisit)}clickEventIsSignificant(e){var o;const t=e.composed?(o=e.target)==null?void 0:o.parentElement:e.target,i=Og(t)||t;return i instanceof Element&&i.closest("turbo-frame, html")==this.element}}class Ug{constructor(e,t){y(this,"started",!1);y(this,"clickCaptured",()=>{this.eventTarget.removeEventListener("click",this.clickBubbled,!1),this.eventTarget.addEventListener("click",this.clickBubbled,!1)});y(this,"clickBubbled",e=>{if(e instanceof MouseEvent&&this.clickEventIsSignificant(e)){const t=e.composedPath&&e.composedPath()[0]||e.target,i=Og(t);if(i&&Tg(i.target)){const o=Cg(i);this.delegate.willFollowLinkToLocation(i,o,e)&&(e.preventDefault(),this.delegate.followedLinkToLocation(i,o))}}});this.delegate=e,this.eventTarget=t}start(){this.started||(this.eventTarget.addEventListener("click",this.clickCaptured,!0),this.started=!0)}stop(){this.started&&(this.eventTarget.removeEventListener("click",this.clickCaptured,!0),this.started=!1)}clickEventIsSignificant(e){return!(e.target&&e.target.isContentEditable||e.defaultPrevented||e.which>1||e.altKey||e.ctrlKey||e.metaKey||e.shiftKey)}}class Hg{constructor(e,t){this.delegate=e,this.linkInterceptor=new Ug(this,t)}start(){this.linkInterceptor.start()}stop(){this.linkInterceptor.stop()}canPrefetchRequestToLocation(e,t){return!1}prefetchAndCacheRequestToLocation(e,t){}willFollowLinkToLocation(e,t,i){return this.delegate.willSubmitFormLinkToLocation(e,t,i)&&(e.hasAttribute("data-turbo-method")||e.hasAttribute("data-turbo-stream"))}followedLinkToLocation(e,t){const i=document.createElement("form"),o="hidden";for(const[O,k]of t.searchParams)i.append(Object.assign(document.createElement("input"),{type:o,name:O,value:k}));const l=Object.assign(t,{search:""});i.setAttribute("data-turbo","true"),i.setAttribute("action",l.href),i.setAttribute("hidden","");const u=e.getAttribute("data-turbo-method");u&&i.setAttribute("method",u);const d=e.getAttribute("data-turbo-frame");d&&i.setAttribute("data-turbo-frame",d);const p=Vr(e);p&&i.setAttribute("data-turbo-action",p);const v=e.getAttribute("data-turbo-confirm");v&&i.setAttribute("data-turbo-confirm",v),e.hasAttribute("data-turbo-stream")&&i.setAttribute("data-turbo-stream",""),this.delegate.submittedFormLinkToLocation(e,t,i),document.body.appendChild(i),i.addEventListener("turbo:submit-end",()=>i.remove(),{once:!0}),requestAnimationFrame(()=>i.requestSubmit())}}class qg{static async preservingPermanentElements(e,t,i){const o=new this(e,t);o.enter(),await i(),o.leave()}constructor(e,t){this.delegate=e,this.permanentElementMap=t}enter(){for(const e in this.permanentElementMap){const[t,i]=this.permanentElementMap[e];this.delegate.enteringBardo(t,i),this.replaceNewPermanentElementWithPlaceholder(i)}}leave(){for(const e in this.permanentElementMap){const[t]=this.permanentElementMap[e];this.replaceCurrentPermanentElementWithClone(t),this.replacePlaceholderWithPermanentElement(t),this.delegate.leavingBardo(t)}}replaceNewPermanentElementWithPlaceholder(e){const t=s0(e);e.replaceWith(t)}replaceCurrentPermanentElementWithClone(e){const t=e.cloneNode(!0);e.replaceWith(t)}replacePlaceholderWithPermanentElement(e){const t=this.getPlaceholderById(e.id);t==null||t.replaceWith(e)}getPlaceholderById(e){return this.placeholders.find(t=>t.content==e)}get placeholders(){return[...document.querySelectorAll("meta[name=turbo-permanent-placeholder][content]")]}}function s0(r){const e=document.createElement("meta");return e.setAttribute("name","turbo-permanent-placeholder"),e.setAttribute("content",r.id),e}var Gt;class pc{constructor(e,t,i,o=!0){le(this,Gt,null);
11this.currentSnapshot=e,this.newSnapshot=t,this.isPreview=i,this.willRender=o,this.renderElement=this.constructor.renderElement,this.promise=new Promise((l,u)=>this.resolvingFunctions={resolve:l,reject:u})}static renderElement(e,t){}get shouldRender(){return!0}get shouldAutofocus(){return!0}get reloadReason(){}prepareToRender(){}render(){}finishRendering(){this.resolvingFunctions&&(this.resolvingFunctions.resolve(),delete this.resolvingFunctions)}async preservingPermanentElements(e){await qg.preservingPermanentElements(this,this.permanentElementMap,e)}focusFirstAutofocusableElement(){if(this.shouldAutofocus){const e=this.connectedSnapshot.firstAutofocusableElement;e&&e.focus()}}enteringBardo(e){K(this,Gt)||e.contains(this.currentSnapshot.activeElement)&&ve(this,Gt,this.currentSnapshot.activeElement)}leavingBardo(e){e.contains(K(this,Gt))&&K(this,Gt)instanceof HTMLElement&&(K(this,Gt).focus(),ve(this,Gt,null))}get connectedSnapshot(){return this.newSnapshot.isConnected?this.newSnapshot:this.currentSnapshot}get currentElement(){return this.currentSnapshot.element}get newElement(){return this.newSnapshot.element}get permanentElementMap(){return this.currentSnapshot.getPermanentElementMapForSnapshot(this.newSnapshot)}get renderMethod(){return"replace"}}Gt=new WeakMap;class mc extends pc{static renderElement(e,t){var u;const i=document.createRange();i.selectNodeContents(e),i.deleteContents();const o=t,l=(u=o.ownerDocument)==null?void 0:u.createRange();l&&(l.selectNodeContents(o),e.appendChild(l.extractContents()))}constructor(e,t,i,o,l,u=!0){super(t,i,o,l,u),this.delegate=e}get shouldRender(){return!0}async render(){await vi(),this.preservingPermanentElements(()=>{this.loadFrameElement()}),this.scrollFrameIntoView(),await vi(),this.focusFirstAutofocusableElement(),await vi(),this.activateScriptElements()}loadFrameElement(){this.delegate.willRenderFrame(this.currentElement,this.newElement),this.renderElement(this.currentElement,this.newElement)}scrollFrameIntoView(){if(this.currentElement.autoscroll||this.newElement.autoscroll){const e=this.currentElement.firstElementChild,t=o0(this.currentElement.getAttribute("data-autoscroll-block"),"end"),i=a0(this.currentElement.getAttribute("data-autoscroll-behavior"),"auto");if(e)return e.scrollIntoView({block:t,behavior:i}),!0}return!1}activateScriptElements(){for(const e of this.newScriptElements){const t=Ei(e);e.replaceWith(t)}}get newScriptElements(){return this.currentElement.querySelectorAll("script")}}function o0(r,e){return r=="end"||r=="start"||r=="center"||r=="nearest"?r:e}function a0(r,e){return r=="auto"||r=="smooth"?r:e}var l0=function(){const r=()=>{},e={morphStyle:"outerHTML",callbacks:{beforeNodeAdded:r,afterNodeAdded:r,beforeNodeMorphed:r,afterNodeMorphed:r,beforeNodeRemoved:r,afterNodeRemoved:r,beforeAttributeUpdated:r},head:{style:"merge",shouldPreserve:k=>k.getAttribute("im-preserve")==="true",shouldReAppend:k=>k.getAttribute("im-re-append")==="true",shouldRemove:r,afterHeadMorphed:r},restoreFocus:!0};function t(k,D,N={}){k=S(k);const B=O(D),V=v(k,B,N),H=o(V,()=>d(V,k,B,x=>x.morphStyle==="innerHTML"?(l(x,k,B),Array.from(k.childNodes)):i(x,k,B)));return V.pantry.remove(),H}function i(k,D,N){const B=O(D);return l(k,B,N,D,D.nextSibling),Array.from(B.childNodes)}function o(k,D){var M;if(!k.config.restoreFocus)return D();let N=document.activeElement;if(!(N instanceof HTMLInputElement||N instanceof HTMLTextAreaElement))return D();const{id:B,selectionStart:V,selectionEnd:H}=N,x=D();return B&&B!==((M=document.activeElement)==null?void 0:M.getAttribute("id"))&&(N=k.target.querySelector(`[id="${B}"]`),N==null||N.focus()),N&&!N.selectionEnd&&H&&N.setSelectionRange(V,H),x}const l=function(){function k(E,A,L,$=null,q=null){A instanceof HTMLTemplateElement&&L instanceof HTMLTemplateElement&&(A=A.content,L=L.content),$||($=A.firstChild);for(const W of L.childNodes){if($&&$!=q){const ce=N(E,W,$,q);if(ce){ce!==$&&V(E,$,ce),u(ce,W,E),$=ce.nextSibling;continue}}if(W instanceof Element){const ce=W.getAttribute("id");if(E.persistentIds.has(ce)){const Fe=H(A,ce,$,E);u(Fe,W,E),$=Fe.nextSibling;continue}}const Z=D(A,W,$,E);Z&&($=Z.nextSibling)}for(;$&&$!=q;){const W=$;$=$.nextSibling,B(E,W)}}function D(E,A,L,$){if($.callbacks.beforeNodeAdded(A)===!1)return null;if($.idMap.has(A)){const q=document.createElement(A.tagName);return E.insertBefore(q,L),u(q,A,$),$.callbacks.afterNodeAdded(q),q}else{const q=document.importNode(A,!0);return E.insertBefore(q,L),$.callbacks.afterNodeAdded(q),q}}const N=function(){function E($,q,W,Z){let ce=null,Fe=q.nextSibling,Dt=0,Ne=W;for(;Ne&&Ne!=Z;){if(L(Ne,q)){if(A($,Ne,q))return Ne;ce===null&&($.idMap.has(Ne)||(ce=Ne))}
11if(ce===null&&Fe&&L(Ne,Fe)&&(Dt++,Fe=Fe.nextSibling,Dt>=2&&(ce=void 0)),$.activeElementAndParents.includes(Ne))break;Ne=Ne.nextSibling}return ce||null}function A($,q,W){let Z=$.idMap.get(q),ce=$.idMap.get(W);if(!ce||!Z)return!1;for(const Fe of Z)if(ce.has(Fe))return!0;return!1}function L($,q){var ce,Fe,Dt;const W=$,Z=q;return W.nodeType===Z.nodeType&&W.tagName===Z.tagName&&(!((ce=W.getAttribute)!=null&&ce.call(W,"id"))||((Fe=W.getAttribute)==null?void 0:Fe.call(W,"id"))===((Dt=Z.getAttribute)==null?void 0:Dt.call(Z,"id")))}return E}();function B(E,A){var L;if(E.idMap.has(A))M(E.pantry,A,null);else{if(E.callbacks.beforeNodeRemoved(A)===!1)return;(L=A.parentNode)==null||L.removeChild(A),E.callbacks.afterNodeRemoved(A)}}function V(E,A,L){let $=A;for(;$&&$!==L;){let q=$;$=$.nextSibling,B(E,q)}return $}function H(E,A,L,$){var W,Z;const q=((Z=(W=$.target).getAttribute)==null?void 0:Z.call(W,"id"))===A&&$.target||$.target.querySelector(`[id="${A}"]`)||$.pantry.querySelector(`[id="${A}"]`);return x(q,$),M(E,q,L),q}function x(E,A){const L=E.getAttribute("id");for(;E=E.parentNode;){let $=A.idMap.get(E);$&&($.delete(L),$.size||A.idMap.delete(E))}}function M(E,A,L){if(E.moveBefore)try{E.moveBefore(A,L)}catch{E.insertBefore(A,L)}else E.insertBefore(A,L)}return k}(),u=function(){function k(x,M,E){return E.ignoreActive&&x===document.activeElement?null:(E.callbacks.beforeNodeMorphed(x,M)===!1||(x instanceof HTMLHeadElement&&E.head.ignore||(x instanceof HTMLHeadElement&&E.head.style!=="morph"?p(x,M,E):(D(x,M,E),H(x,E)||l(E,x,M))),E.callbacks.afterNodeMorphed(x,M)),x)}function D(x,M,E){let A=M.nodeType;if(A===1){const L=x,$=M,q=L.attributes,W=$.attributes;for(const Z of W)V(Z.name,L,"update",E)||L.getAttribute(Z.name)!==Z.value&&L.setAttribute(Z.name,Z.value);for(let Z=q.length-1;0<=Z;Z--){const ce=q[Z];if(ce&&!$.hasAttribute(ce.name)){if(V(ce.name,L,"remove",E))continue;L.removeAttribute(ce.name)}}H(L,E)||N(L,$,E)}(A===8||A===3)&&x.nodeValue!==M.nodeValue&&(x.nodeValue=M.nodeValue)}function N(x,M,E){if(x instanceof HTMLInputElement&&M instanceof HTMLInputElement&&M.type!=="file"){let A=M.value,L=x.value;B(x,M,"checked",E),B(x,M,"disabled",E),M.hasAttribute("value")?L!==A&&(V("value",x,"update",E)||(x.setAttribute("value",A),x.value=A)):V("value",x,"remove",E)||(x.value="",x.removeAttribute("value"))}else if(x instanceof HTMLOptionElement&&M instanceof HTMLOptionElement)B(x,M,"selected",E);else if(x instanceof HTMLTextAreaElement&&M instanceof HTMLTextAreaElement){let A=M.value,L=x.value;if(V("value",x,"update",E))return;A!==L&&(x.value=A),x.firstChild&&x.firstChild.nodeValue!==A&&(x.firstChild.nodeValue=A)}}function B(x,M,E,A){const L=M[E],$=x[E];if(L!==$){const q=V(E,x,"update",A);q||(x[E]=M[E]),L?q||x.setAttribute(E,""):V(E,x,"remove",A)||x.removeAttribute(E)}}function V(x,M,E,A){return x==="value"&&A.ignoreActiveValue&&M===document.activeElement?!0:A.callbacks.beforeAttributeUpdated(x,M,E)===!1}function H(x,M){return!!M.ignoreActiveValue&&x===document.activeElement&&x!==document.body}return k}();function d(k,D,N,B){if(k.head.block){const V=D.querySelector("head"),H=N.querySelector("head");if(V&&H){const x=p(V,H,k);return Promise.all(x).then(()=>{const M=Object.assign(k,{head:{block:!1,ignore:!0}});return B(M)})}}return B(k)}function p(k,D,N){let B=[],V=[],H=[],x=[],M=new Map;for(const A of D.children)M.set(A.outerHTML,A);for(const A of k.children){let L=M.has(A.outerHTML),$=N.head.shouldReAppend(A),q=N.head.shouldPreserve(A);L||q?$?V.push(A):(M.delete(A.outerHTML),H.push(A)):N.head.style==="append"?$&&(V.push(A),x.push(A)):N.head.shouldRemove(A)!==!1&&V.push(A)}x.push(...M.values());let E=[];for(const A of x){let L=document.createRange().createContextualFragment(A.outerHTML).firstChild;if(N.callbacks.beforeNodeAdded(L)!==!1){if("href"in L&&L.href||"src"in L&&L.src){let $,q=new Promise(function(W){$=W});L.addEventListener("load",function(){$()}),E.push(q)}k.appendChild(L),N.callbacks.afterNodeAdded(L),B.push(L)}}for(const A of V)N.callbacks.beforeNodeRemoved(A)!==!1&&(k.removeChild(A),N.callbacks.afterNodeRemoved(A));return N.head.afterHeadMorphed(k,{added:B,kept:H,removed:V}),E}const v=function(){function k(E,A,L){const{persistentIds:$,idMap:q}=x(E,A),W=D(L),Z=W.morphStyle||"outerHTML";if(!["innerHTML","outerHTML"].includes(Z))throw`Do not understand how to morph style ${Z}`;return{target:E,newContent:A,config:W,morphStyle:Z,ignoreActive:W.ignoreActive,ignoreActiveValue:W.ignoreActiveValue,restoreFocus:W.restoreFocus,idMap:q,persistentIds:$,pantry:N(),activeElementAndParents:B(E),callbacks:W.callbacks,head:W.head}}function D(E){let A=Object.assign({},e);return Object.assign(A,E),A.callbacks=Object.assign({},e.callbacks,E.callbacks),A.head=Object.assign({},e.head,E.head),A}function N(){const E=document.createElement("div");return E.hidden=!0,document.body.insertAdjacentElement("afterend",E),E}function B(E){let A=[],L=document.activeElement;if((L==null?void 0:L.tagName)!=="BODY"&&E.contains(L))for(;L&&(A.push(L),L!==E);)L=L.parentElement;return A}function V(E){var L;let A=Array.from(E.querySelectorAll("[id]"));return(L=E.getAttribute)!=null&&L.call(E,"id")&&A.push(E),A}function H(E,A,L,$){for(const q of $){const W=q.getAttribute("id");if(A.has(W)){let Z=q;for(;Z;){let ce=E.get(Z);if(ce==null&&(ce=new Set,E.set(Z,ce)),ce.add(W),Z===L)break;Z=Z.parentElement}}}}function x(E,A){const L=V(E),$=V(A),q=M(L,$);let W=new Map;H(W,q,E,L);const Z=A.__idiomorphRoot||A;return H(W,q,Z,$),{persistentIds:q,idMap:W}}function M(E,A){let L=new Set,$=new Map;for(const{id:W,tagName:Z}of E)$.has(W)?L.add(W):$.set(W,Z);let q=new Set;for(const{id:W,tagName:Z}of A)q.has(W)?L.add(W):$.get(W)===Z&&q.add(W);for(const W of L)q.delete(W);return q}return k}(),{normalizeElement:S,normalizeParent:O}=function(){const k=new WeakSet;function D(H){return H instanceof Document?H.documentElement:H}function N(H){if(H==null)return document.createElement("div");if(typeof H=="string")return N(V(H));if(k.has(H))return H;if(H instanceof Node){if(H.parentNode)return new B(H);{const x=document.createElement("div");return x.append(H),x}}else{const x=document.createElement("div");for(const M of[...H])x.append(M);return x}}
11class B{constructor(x){this.originalNode=x,this.realParentNode=x.parentNode,this.previousSibling=x.previousSibling,this.nextSibling=x.nextSibling}get childNodes(){const x=[];let M=this.previousSibling?this.previousSibling.nextSibling:this.realParentNode.firstChild;for(;M&&M!=this.nextSibling;)x.push(M),M=M.nextSibling;return x}querySelectorAll(x){return this.childNodes.reduce((M,E)=>{if(E instanceof Element){E.matches(x)&&M.push(E);const A=E.querySelectorAll(x);for(let L=0;L<A.length;L++)M.push(A[L])}return M},[])}insertBefore(x,M){return this.realParentNode.insertBefore(x,M)}moveBefore(x,M){return this.realParentNode.moveBefore(x,M)}get __idiomorphRoot(){return this.originalNode}}function V(H){let x=new DOMParser,M=H.replace(/<svg(\s[^>]*>|>)([\s\S]*?)<\/svg>/gim,"");if(M.match(/<\/html>/)||M.match(/<\/head>/)||M.match(/<\/body>/)){let E=x.parseFromString(H,"text/html");if(M.match(/<\/html>/))return k.add(E),E;{let A=E.firstChild;return A&&k.add(A),A}}else{let A=x.parseFromString("<body><template>"+H+"</template></body>","text/html").body.querySelector("template").content;return k.add(A),A}}return{normalizeElement:D,normalizeParent:N}}();return{morph:t,defaults:e}}();function yo(r,e,{callbacks:t,...i}={}){l0.morph(r,e,{...i,callbacks:new u0(t)})}function vc(r,e,t={}){yo(r,e.childNodes,{...t,morphStyle:"innerHTML"})}function Vg(r,e){return r instanceof pt&&r.shouldReloadWithMorph&&(!e||c0(r,e))&&!r.closest("[data-turbo-permanent]")}function c0(r,e){return e instanceof Element&&e.nodeName==="TURBO-FRAME"&&r.id===e.id&&(!e.getAttribute("src")||Ig(r.src,e.getAttribute("src")))}function jg(r){return r.parentElement.closest("turbo-frame[src][refresh=morph]")}var xi;class u0{constructor({beforeNodeMorphed:e}={}){le(this,xi);y(this,"beforeNodeAdded",e=>!(e.id&&e.hasAttribute("data-turbo-permanent")&&document.getElementById(e.id)));y(this,"beforeNodeMorphed",(e,t)=>{if(e instanceof Element)return!e.hasAttribute("data-turbo-permanent")&&K(this,xi).call(this,e,t)?!Te("turbo:before-morph-element",{cancelable:!0,target:e,detail:{currentElement:e,newElement:t}}).defaultPrevented:!1});y(this,"beforeAttributeUpdated",(e,t,i)=>!Te("turbo:before-morph-attribute",{cancelable:!0,target:t,detail:{attributeName:e,mutationType:i}}).defaultPrevented);y(this,"beforeNodeRemoved",e=>this.beforeNodeMorphed(e));y(this,"afterNodeMorphed",(e,t)=>{e instanceof Element&&Te("turbo:morph-element",{target:e,detail:{currentElement:e,newElement:t}})});ve(this,xi,e||(()=>!0))}}xi=new WeakMap;class Wg extends mc{static renderElement(e,t){Te("turbo:before-frame-morph",{target:e,detail:{currentElement:e,newElement:t}}),vc(e,t,{callbacks:{beforeNodeMorphed:(i,o)=>Vg(i,o)&&jg(i)===e?(i.reload(),!1):!0}})}async preservingPermanentElements(e){return await e()}}const Kt=class Kt{constructor(){y(this,"hiding",!1);y(this,"value",0);y(this,"visible",!1);y(this,"trickle",()=>{this.setValue(this.value+Math.random()/100)});this.stylesheetElement=this.createStylesheetElement(),this.progressElement=this.createProgressElement(),this.installStylesheetElement(),this.setValue(0)}static get defaultCSS(){return yg` 12 .turbo-progress-bar { 13 position: fixed; 14 display: block; 15 top: 0; 16 left: 0; 17 height: 3px; 18 background: #0076ff; 19 z-index: 2147483647; 20 transition: 21 width ${Kt.animationDuration}ms ease-out, 22 opacity ${Kt.animationDuration/2}ms ${Kt.animationDuration/2}ms ease-in; 23 transform: translate3d(0, 0, 0); 24 } 25 `}show(){this.visible||(this.visible=!0,this.installProgressElement(),this.startTrickling())}hide(){this.visible&&!this.hiding&&(this.hiding=!0,this.fadeProgressElement(()=>{this.uninstallProgressElement(),this.stopTrickling(),this.visible=!1,this.hiding=!1}))}setValue(e){this.value=e,this.refresh()}installStylesheetElement(){document.head.insertBefore(this.stylesheetElement,document.head.firstChild)}installProgressElement(){this.progressElement.style.width="0",this.progressElement.style.opacity="1",document.documentElement.insertBefore(this.progressElement,document.body),this.refresh()}fadeProgressElement(e){this.progressElement.style.opacity="0",setTimeout(e,Kt.animationDuration*1.5)}uninstallProgressElement(){this.progressElement.parentNode&&document.documentElement.removeChild(this.progressElement)}startTrickling(){this.trickleInterval||(this.trickleInterval=window.setInterval(this.trickle,Kt.animationDuration))}stopTrickling(){window.clearInterval(this.trickleInterval),delete this.trickleInterval}refresh(){requestAnimationFrame(()=>{this.progressElement.style.width=`${10+this.value*90}%`})}createStylesheetElement(){const e=document.createElement("style");e.type="text/css",e.textContent=Kt.defaultCSS;const t=Sg();return t&&(e.nonce=t),e}createProgressElement(){const e=document.createElement("div");return e.className="turbo-progress-bar",e}};y(Kt,"animationDuration",300);let bl=Kt;class h0 extends wo{constructor(){super(...arguments);y(this,"detailsByOuterHTML",this.children.filter(t=>!p0(t)).map(t=>
25b0(t)).reduce((t,i)=>{const{outerHTML:o}=i,l=o in t?t[o]:{type:d0(i),tracked:f0(i),elements:[]};return{...t,[o]:{...l,elements:[...l.elements,i]}}},{}))}get trackedElementSignature(){return Object.keys(this.detailsByOuterHTML).filter(t=>this.detailsByOuterHTML[t].tracked).join("")}getScriptElementsNotInSnapshot(t){return this.getElementsMatchingTypeNotInSnapshot("script",t)}getStylesheetElementsNotInSnapshot(t){return this.getElementsMatchingTypeNotInSnapshot("stylesheet",t)}getElementsMatchingTypeNotInSnapshot(t,i){return Object.keys(this.detailsByOuterHTML).filter(o=>!(o in i.detailsByOuterHTML)).map(o=>this.detailsByOuterHTML[o]).filter(({type:o})=>o==t).map(({elements:[o]})=>o)}get provisionalElements(){return Object.keys(this.detailsByOuterHTML).reduce((t,i)=>{const{type:o,tracked:l,elements:u}=this.detailsByOuterHTML[i];return o==null&&!l?[...t,...u]:u.length>1?[...t,...u.slice(1)]:t},[])}getMetaValue(t){const i=this.findMetaElementByName(t);return i?i.getAttribute("content"):null}findMetaElementByName(t){return Object.keys(this.detailsByOuterHTML).reduce((i,o)=>{const{elements:[l]}=this.detailsByOuterHTML[o];return v0(l,t)?l:i},void 0|void 0)}}function d0(r){if(g0(r))return"script";if(m0(r))return"stylesheet"}function f0(r){return r.getAttribute("data-turbo-track")=="reload"}function g0(r){return r.localName=="script"}function p0(r){return r.localName=="noscript"}function m0(r){const e=r.localName;return e=="style"||e=="link"&&r.getAttribute("rel")=="stylesheet"}function v0(r,e){return r.localName=="meta"&&r.getAttribute("name")==e}function b0(r){return r.hasAttribute("nonce")&&r.setAttribute("nonce",""),r}class St extends wo{static fromHTMLString(e=""){return this.fromDocument(wg(e))}static fromElement(e){return this.fromDocument(e.ownerDocument)}static fromDocument({documentElement:e,body:t,head:i}){return new this(e,t,new h0(i))}constructor(e,t,i){super(t),this.documentElement=e,this.headSnapshot=i}clone(){const e=this.element.cloneNode(!0),t=this.element.querySelectorAll("select"),i=e.querySelectorAll("select");for(const[o,l]of t.entries()){const u=i[o];for(const d of u.selectedOptions)d.selected=!1;for(const d of l.selectedOptions)u.options[d.index].selected=!0}for(const o of e.querySelectorAll('input[type="password"]'))o.value="";for(const o of e.querySelectorAll("noscript"))o.remove();return new St(this.documentElement,e,this.headSnapshot)}get lang(){return this.documentElement.getAttribute("lang")}get dir(){return this.documentElement.getAttribute("dir")}get headElement(){return this.headSnapshot.element}get rootLocation(){const e=this.getSetting("root")??"/";return $e(e)}get cacheControlValue(){return this.getSetting("cache-control")}get isPreviewable(){return this.cacheControlValue!="no-preview"}get isCacheable(){return this.cacheControlValue!="no-cache"}get isVisitable(){return this.getSetting("visit-control")!="reload"}get prefersViewTransitions(){return(this.getSetting("view-transition")==="true"||this.headSnapshot.getMetaValue("view-transition")==="same-origin")&&!window.matchMedia("(prefers-reduced-motion: reduce)").matches}get refreshMethod(){return this.getSetting("refresh-method")}get refreshScroll(){return this.getSetting("refresh-scroll")}getSetting(e){return this.headSnapshot.getMetaValue(`turbo-${e}`)}}var ki,gr;class _0{constructor(){le(this,ki,!1);le(this,gr,Promise.resolve())}renderChange(e,t){return e&&this.viewTransitionsAvailable&&!K(this,ki)?(ve(this,ki,!0),ve(this,gr,K(this,gr).then(async()=>{await document.startViewTransition(t).finished}))):ve(this,gr,K(this,gr).then(t)),K(this,gr)}get viewTransitionsAvailable(){return document.startViewTransition}}ki=new WeakMap,gr=new WeakMap;const w0={action:"advance",historyChanged:!1,visitCachedSnapshot:()=>{},willRender:!0,updateHistory:!0,shouldCacheSnapshot:!0,acceptsStreamResponse:!1,refresh:{}},Us={visitStart:"visitStart",requestStart:"requestStart",requestEnd:"requestEnd",visitEnd:"visitEnd"},zt={initialized:"initialized",started:"started",canceled:"canceled",failed:"failed",completed:"completed"},Tn={networkFailure:0,timeoutFailure:-1,contentTypeMismatch:-2},y0={advance:"forward",restore:"back",replace:"none"};class E0{constructor(e,t,i,o={}){y(this,"identifier",yr());y(this,"timingMetrics",{});y(this,"followedRedirect",!1);y(this,"historyChanged",!1);y(this,"scrolled",!1);y(this,"shouldCacheSnapshot",!0);y(this,"acceptsStreamResponse",!1);y(this,"snapshotCached",!1);y(this,"state",zt.initialized);y(this,"viewTransitioner",new _0);this.delegate=e,this.location=t,this.restorationIdentifier=i||yr();const{action:l,historyChanged:u,referrer:d,snapshot:p,snapshotHTML:v,response:S,visitCachedSnapshot:O,willRender:k,updateHistory:D,shouldCacheSnapshot:N,acceptsStreamResponse:B,direction:V,refresh:H}={...w0,...o};this.action=l,this.historyChanged=u,this.referrer=d,this.snapshot=p,this.snapshotHTML=v,this.response=S,this.isPageRefresh=this.view.isPageRefresh(this),this.visitCachedSnapshot=O,this.willRender=k,this.updateHistory=D,this.scrolled=!k,this.shouldCacheSnapshot=N,this.acceptsStreamResponse=B,this.direction=V||y0[l],this.refresh=H}get adapter(){return this.delegate.adapter}get view(){return this.delegate.view}get history(){return this.delegate.history}get restorationData(){return this.history.getRestorationDataForIdentifier(this.restorationIdentifier)}start(){this.state==zt.initialized&&(this.recordTimingMetric(Us.visitStart),this.state=zt.started,this.adapter.visitStarted(this),this.delegate.visitStarted(this))}cancel(){this.state==zt.started&&(this.request&&this.request.cancel(),this.cancelRender(),this.state=zt.canceled)}complete(){this.state==zt.started&&(this.recordTimingMetric(Us.visitEnd),this.adapter.visitCompleted(this),this.state=zt.completed,this.followRedirect(),this.followedRedirect||this.delegate.visitCompleted(this))}fail(){this.state==zt.started&&(this.state=zt.failed,this.adapter.visitFailed(this),this.delegate.visitCompleted(this))}changeHistory(){var e;if(!this.historyChanged&&this.updateHistory){const t=this.location.href===((e=this.referrer)==null?void 0:e.href)?"replace":this.action,i=Eg(t);this.history.update(i,this.location,this.restorationIdentifier),this.historyChanged=!0}}issueRequest(){this.hasPreloadedResponse()?this.simulateRequest():this.shouldIssueRequest()&&!this.request&&(this.request=new Vi(this,gt.get,this.location),this.request.perform())}
25simulateRequest(){this.response&&(this.startRequest(),this.recordResponse(),this.finishRequest())}startRequest(){this.recordTimingMetric(Us.requestStart),this.adapter.visitRequestStarted(this)}recordResponse(e=this.response){if(this.response=e,e){const{statusCode:t}=e;Fd(t)?this.adapter.visitRequestCompleted(this):this.adapter.visitRequestFailedWithStatusCode(this,t)}}finishRequest(){this.recordTimingMetric(Us.requestEnd),this.adapter.visitRequestFinished(this)}loadResponse(){if(this.response){const{statusCode:e,responseHTML:t}=this.response;this.render(async()=>{if(this.shouldCacheSnapshot&&this.cacheSnapshot(),this.view.renderPromise&&await this.view.renderPromise,Fd(e)&&t!=null){const i=St.fromHTMLString(t);await this.renderPageSnapshot(i,!1),this.adapter.visitRendered(this),this.complete()}else await this.view.renderError(St.fromHTMLString(t),this),this.adapter.visitRendered(this),this.fail()})}}getCachedSnapshot(){const e=this.view.getCachedSnapshotForLocation(this.location)||this.getPreloadedSnapshot();if(e&&(!bi(this.location)||e.hasAnchor(bi(this.location)))&&(this.action=="restore"||e.isPreviewable))return e}getPreloadedSnapshot(){if(this.snapshotHTML)return St.fromHTMLString(this.snapshotHTML)}hasCachedSnapshot(){return this.getCachedSnapshot()!=null}loadCachedSnapshot(){const e=this.getCachedSnapshot();if(e){const t=this.shouldIssueRequest();this.render(async()=>{this.cacheSnapshot(),this.isPageRefresh?this.adapter.visitRendered(this):(this.view.renderPromise&&await this.view.renderPromise,await this.renderPageSnapshot(e,t),this.adapter.visitRendered(this),t||this.complete())})}}followRedirect(){var e;this.redirectedToLocation&&!this.followedRedirect&&((e=this.response)!=null&&e.redirected)&&(this.adapter.visitProposedToLocation(this.redirectedToLocation,{action:"replace",response:this.response,shouldCacheSnapshot:!1,willRender:!1}),this.followedRedirect=!0)}prepareRequest(e){this.acceptsStreamResponse&&e.acceptResponseType(Gr.contentType)}requestStarted(){this.startRequest()}requestPreventedHandlingResponse(e,t){}async requestSucceededWithResponse(e,t){const i=await t.responseHTML,{redirected:o,statusCode:l}=t;i==null?this.recordResponse({statusCode:Tn.contentTypeMismatch,redirected:o}):(this.redirectedToLocation=t.redirected?t.location:void 0,this.recordResponse({statusCode:l,responseHTML:i,redirected:o}))}async requestFailedWithResponse(e,t){const i=await t.responseHTML,{redirected:o,statusCode:l}=t;i==null?this.recordResponse({statusCode:Tn.contentTypeMismatch,redirected:o}):this.recordResponse({statusCode:l,responseHTML:i,redirected:o})}requestErrored(e,t){this.recordResponse({statusCode:Tn.networkFailure,redirected:!1})}requestFinished(){this.finishRequest()}performScroll(){!this.scrolled&&!this.view.forceReloaded&&!this.view.shouldPreserveScrollPosition(this)&&(this.action=="restore"?this.scrollToRestoredPosition()||this.scrollToAnchor()||this.view.scrollToTop():this.scrollToAnchor()||this.view.scrollToTop(),this.scrolled=!0)}scrollToRestoredPosition(){const{scrollPosition:e}=this.restorationData;if(e)return this.view.scrollToPosition(e),!0}scrollToAnchor(){const e=bi(this.location);if(e!=null)return this.view.scrollToAnchor(e),!0}recordTimingMetric(e){this.timingMetrics[e]=new Date().getTime()}getTimingMetrics(){return{...this.timingMetrics}}hasPreloadedResponse(){return typeof this.response=="object"}shouldIssueRequest(){return this.action=="restore"?!this.hasCachedSnapshot():this.willRender}cacheSnapshot(){this.snapshotCached||(this.view.cacheSnapshot(this.snapshot).then(e=>e&&this.visitCachedSnapshot(e)),this.snapshotCached=!0)}async render(e){this.cancelRender(),await new Promise(t=>{this.frame=document.visibilityState==="hidden"?setTimeout(()=>t(),0):requestAnimationFrame(()=>t())}),await e(),delete this.frame}async renderPageSnapshot(e,t){await this.viewTransitioner.renderChange(this.view.shouldTransitionTo(e),async()=>{await this.view.renderPage(e,t,this.willRender,this),this.performScroll()})}cancelRender(){this.frame&&(cancelAnimationFrame(this.frame),delete this.frame)}}function Fd(r){return r>=200&&r<300}class S0{constructor(e){y(this,"progressBar",new bl);y(this,"showProgressBar",()=>{this.progressBar.show()});this.session=e}visitProposedToLocation(e,t){dr(e,this.navigator.rootLocation)?this.navigator.startVisit(e,(t==null?void 0:t.restorationIdentifier)||yr(),t):window.location.href=e.toString()}visitStarted(e){this.location=e.location,this.redirectedToLocation=null,e.loadCachedSnapshot(),e.issueRequest()}visitRequestStarted(e){this.progressBar.setValue(0),e.hasCachedSnapshot()||e.action!="restore"?this.showVisitProgressBarAfterDelay():this.showProgressBar()}visitRequestCompleted(e){e.loadResponse(),e.response.redirected&&(this.redirectedToLocation=e.redirectedToLocation)}visitRequestFailedWithStatusCode(e,t){switch(t){case Tn.networkFailure:case Tn.timeoutFailure:case Tn.contentTypeMismatch:return this.reload({reason:"request_failed",context:{statusCode:t}});default:return e.loadResponse()}}visitRequestFinished(e){}visitCompleted(e){this.progressBar.setValue(1),this.hideVisitProgressBar()}pageInvalidated(e){this.reload(e)}visitFailed(e){this.progressBar.setValue(1),this.hideVisitProgressBar()}visitRendered(e){}linkPrefetchingIsEnabledForLocation(e){return!0}
25formSubmissionStarted(e){this.progressBar.setValue(0),this.showFormProgressBarAfterDelay()}formSubmissionFinished(e){this.progressBar.setValue(1),this.hideFormProgressBar()}showVisitProgressBarAfterDelay(){this.visitProgressBarTimeout=window.setTimeout(this.showProgressBar,this.session.progressBarDelay)}hideVisitProgressBar(){this.progressBar.hide(),this.visitProgressBarTimeout!=null&&(window.clearTimeout(this.visitProgressBarTimeout),delete this.visitProgressBarTimeout)}showFormProgressBarAfterDelay(){this.formProgressBarTimeout==null&&(this.formProgressBarTimeout=window.setTimeout(this.showProgressBar,this.session.progressBarDelay))}hideFormProgressBar(){this.progressBar.hide(),this.formProgressBarTimeout!=null&&(window.clearTimeout(this.formProgressBarTimeout),delete this.formProgressBarTimeout)}reload(e){var t;Te("turbo:reload",{detail:e}),window.location.href=((t=this.redirectedToLocation||this.location)==null?void 0:t.toString())||window.location.href}get navigator(){return this.session.navigator}}class A0{constructor(){y(this,"selector","[data-turbo-temporary]");y(this,"started",!1);y(this,"removeTemporaryElements",e=>{for(const t of this.temporaryElements)t.remove()})}start(){this.started||(this.started=!0,addEventListener("turbo:before-cache",this.removeTemporaryElements,!1))}stop(){this.started&&(this.started=!1,removeEventListener("turbo:before-cache",this.removeTemporaryElements,!1))}get temporaryElements(){return[...document.querySelectorAll(this.selector)]}}var mt,zg,Ws,zs;class T0{constructor(e,t){le(this,mt);this.session=e,this.element=t,this.linkInterceptor=new Bg(this,t),this.formSubmitObserver=new gc(this,t)}start(){this.linkInterceptor.start(),this.formSubmitObserver.start()}stop(){this.linkInterceptor.stop(),this.formSubmitObserver.stop()}shouldInterceptLinkClick(e,t,i){return Q(this,mt,Ws).call(this,e)}linkClickIntercepted(e,t,i){const o=Q(this,mt,zs).call(this,e);o&&o.delegate.linkClickIntercepted(e,t,i)}willSubmitForm(e,t){return e.closest("turbo-frame")==null&&Q(this,mt,zg).call(this,e,t)&&Q(this,mt,Ws).call(this,e,t)}formSubmitted(e,t){const i=Q(this,mt,zs).call(this,e,t);i&&i.delegate.formSubmitted(e,t)}}mt=new WeakSet,zg=function(e,t){const i=uc(e,t),o=this.element.ownerDocument.querySelector('meta[name="turbo-root"]'),l=$e((o==null?void 0:o.content)??"/");return Q(this,mt,Ws).call(this,e,t)&&dr(i,l)},Ws=function(e,t){if(e instanceof HTMLFormElement?this.session.submissionIsNavigatable(e,t):this.session.elementIsNavigatable(e)){const o=Q(this,mt,zs).call(this,e,t);return o?o!=e.closest("turbo-frame"):!1}else return!1},zs=function(e,t){const i=(t==null?void 0:t.getAttribute("data-turbo-frame"))||e.getAttribute("data-turbo-frame");if(i&&i!="_top"){const o=this.element.querySelector(`#${i}:not([disabled])`);if(o instanceof pt)return o}};class O0{constructor(e){y(this,"location");y(this,"restorationIdentifier",yr());y(this,"restorationData",{});y(this,"started",!1);y(this,"currentIndex",0);y(this,"onPopState",e=>{const{turbo:t}=e.state||{};if(this.location=new URL(window.location.href),t){const{restorationIdentifier:i,restorationIndex:o}=t;this.restorationIdentifier=i;const l=o>this.currentIndex?"forward":"back";this.delegate.historyPoppedToLocationWithRestorationIdentifierAndDirection(this.location,i,l),this.currentIndex=o}else this.currentIndex++,this.delegate.historyPoppedWithEmptyState(this.location)});this.delegate=e}start(){var e,t;this.started||(addEventListener("popstate",this.onPopState,!1),this.currentIndex=((t=(e=history.state)==null?void 0:e.turbo)==null?void 0:t.restorationIndex)||0,this.started=!0,this.replace(new URL(window.location.href)))}stop(){this.started&&(removeEventListener("popstate",this.onPopState,!1),this.started=!1)}push(e,t){this.update(history.pushState,e,t)}replace(e,t){this.update(history.replaceState,e,t)}update(e,t,i=yr()){e===history.pushState&&++this.currentIndex;const o={turbo:{restorationIdentifier:i,restorationIndex:this.currentIndex}};e.call(history,o,"",t.href),this.location=t,this.restorationIdentifier=i}getRestorationDataForIdentifier(e){return this.restorationData[e]||{}}updateRestorationData(e){const{restorationIdentifier:t}=this,i=this.restorationData[t];this.restorationData[t]={...i,...e}}assumeControlOfScrollRestoration(){this.previousScrollRestoration||(this.previousScrollRestoration=history.scrollRestoration??"auto",history.scrollRestoration="manual")}relinquishControlOfScrollRestoration(){this.previousScrollRestoration&&(history.scrollRestoration=this.previousScrollRestoration,delete this.previousScrollRestoration)}}var In,Mi,Di,$i,vo,Fi,$n,Kg,Gg;class C0{constructor(e,t){le(this,$n);y(this,"started",!1);le(this,In,null);le(this,Mi,()=>{this.eventTarget.addEventListener("mouseenter",K(this,Di),{capture:!0,passive:!0}),this.eventTarget.addEventListener("mouseleave",K(this,$i),{capture:!0,passive:!0}),this.eventTarget.addEventListener("turbo:before-fetch-request",K(this,Fi),!0),this.started=!0});le(this,Di,e=>{if(no("turbo-prefetch")==="false")return;const t=e.target;if(t.matches&&t.matches("a[href]:not([target^=_]):not([download])")&&Q(this,$n,Gg).call(this,t)){const o=t,l=Cg(o);if(this.delegate.canPrefetchRequestToLocation(o,l)){ve(this,In,o);const u=new Vi(this,gt.get,l,new URLSearchParams,t);u.fetchOptions.priority="low",yn.putLater(l,u,K(this,$n,Kg))}}});le(this,$i,e=>{e.target===K(this,In)&&K(this,vo).call(this)});le(this,vo,()=>{yn.clear(),ve(this,In,null)});le(this,Fi,e=>{if(e.target.tagName!=="FORM"&&e.detail.fetchOptions.method==="GET"){const t=yn.get(e.detail.url);t&&(e.detail.fetchRequest=t),yn.clear()}});this.delegate=e,this.eventTarget=t}start(){this.started||(this.eventTarget.readyState==="loading"?this.eventTarget.addEventListener("DOMContentLoaded",K(this,Mi),{once:!0}):K(this,Mi).call(this))}stop(){this.started&&(this.eventTarget.removeEventListener("mouseenter",K(this,Di),{capture:!0,passive:!0}),this.eventTarget.removeEventListener("mouseleave",K(this,$i),{capture:!0,passive:!0}),this.eventTarget.removeEventListener("turbo:before-fetch-request",K(this,Fi),!0),this.started=!1)}prepareRequest(e){const t=e.target;e.headers["X-Sec-Purpose"]="prefetch";const i=t.closest("turbo-frame"),o=t.getAttribute("data-turbo-frame")||(i==null?void 0:i.getAttribute("target"))||(i==null?void 0:i.id);o&&o!=="_top"&&(e.headers["Turbo-Frame"]=o)}requestSucceededWithResponse(){}requestStarted(e){}requestErrored(e){}requestFinished(e){}requestPreventedHandlingResponse(e,t){}requestFailedWithResponse(e,t){}}In=new WeakMap,Mi=new WeakMap,Di=new WeakMap,$i=new WeakMap,vo=new WeakMap,Fi=new WeakMap,$n=new WeakSet,Kg=function(){return Number(no("turbo-prefetch-cache-time"))||Dg},Gg=function(e){return!(!e.getAttribute("href")||I0(e)||L0(e)||R0(e)||P0(e)||k0(e))};const I0=r=>r.origin!==document.location.origin||!["http:","https:"].includes(r.protocol)||r.hasAttribute("target"),L0=r=>r.pathname+r.search===document.location.pathname+document.location.search||r.href.startsWith("#"),R0=r=>{if(r.getAttribute("data-turbo-prefetch")==="false"||r.getAttribute("data-turbo")==="false")return!0;const e=An(r,"[data-turbo-prefetch]");return!!(e&&e.getAttribute("data-turbo-prefetch")==="false")},P0=r=>{const e=r.getAttribute("data-turbo-method");return!!(e&&e.toLowerCase()!=="get"||x0(r)||r.hasAttribute("data-turbo-confirm")||r.hasAttribute("data-turbo-stream"))},x0=r=>r.hasAttribute("data-remote")||r.hasAttribute("data-behavior")||r.hasAttribute("data-confirm")||r.hasAttribute("data-method"),k0=r=>Te("turbo:before-prefetch",{target:r,cancelable:!0}).defaultPrevented;var Fn,Xg,Yg;class M0{constructor(e){le(this,Fn);this.delegate=e}proposeVisit(e,t={}){this.delegate.allowsVisitingLocationWithAction(e,t.action)&&this.delegate.visitProposedToLocation(e,t)}startVisit(e,t,i={}){this.stop(),this.currentVisit=new E0(this,$e(e),t,{referrer:this.location,...i}),this.currentVisit.start()}submitForm(e,t){this.stop(),this.formSubmission=new _o(this,e,t,!0),this.formSubmission.start()}stop(){this.formSubmission&&(this.formSubmission.stop(),delete this.formSubmission),this.currentVisit&&(this.currentVisit.cancel(),delete this.currentVisit)}get adapter(){return this.delegate.adapter}get view(){return this.delegate.view}get rootLocation(){return this.view.snapshot.rootLocation}get history(){return this.delegate.history}formSubmissionStarted(e){typeof this.adapter.formSubmissionStarted=="function"&&this.adapter.formSubmissionStarted(e)}async formSubmissionSucceededWithResponse(e,t){if(e==this.formSubmission){const i=await t.responseHTML;if(i){const o=e.isSafe;o||this.view.clearSnapshotCache();const{statusCode:l,redirected:u}=t,p={action:Q(this,Fn,Xg).call(this,e,t),shouldCacheSnapshot:o,response:{statusCode:l,responseHTML:i,redirected:u}};this.proposeVisit(t.location,p)}}}async formSubmissionFailedWithResponse(e,t){const i=await t.responseHTML;if(i){const o=St.fromHTMLString(i);t.serverError?await this.view.renderError(o,this.currentVisit):await this.view.renderPage(o,!1,!0,this.currentVisit),o.refreshScroll!=="preserve"&&this.view.scrollToTop(),this.view.clearSnapshotCache()}}formSubmissionErrored(e,t){console.error(t)}formSubmissionFinished(e){typeof this.adapter.formSubmissionFinished=="function"&&this.adapter.formSubmissionFinished(e)}linkPrefetchingIsEnabledForLocation(e){return typeof this.adapter.linkPrefetchingIsEnabledForLocation=="function"?this.adapter.linkPrefetchingIsEnabledForLocation(e):!0}visitStarted(e){this.delegate.visitStarted(e)}visitCompleted(e){this.delegate.visitCompleted(e),delete this.currentVisit}locationWithActionIsSamePage(e,t){return!1}get location(){return this.history.location}get restorationIdentifier(){return this.history.restorationIdentifier}}Fn=new WeakSet,Xg=function(e,t){const{submitter:i,formElement:o}=e;return Vr(i,o)||Q(this,Fn,Yg).call(this,t)},Yg=function(e){var i;return e.redirected&&e.location.href===((i=this.location)==null?void 0:i.href)?"replace":"advance"};const Dr={initial:0,loading:1,interactive:2,complete:3};class D0{constructor(e){y(this,"stage",Dr.initial);y(this,"started",!1);y(this,"interpretReadyState",()=>{const{readyState:e}=this;
25e=="interactive"?this.pageIsInteractive():e=="complete"&&this.pageIsComplete()});y(this,"pageWillUnload",()=>{this.delegate.pageWillUnload()});this.delegate=e}start(){this.started||(this.stage==Dr.initial&&(this.stage=Dr.loading),document.addEventListener("readystatechange",this.interpretReadyState,!1),addEventListener("pagehide",this.pageWillUnload,!1),this.started=!0)}stop(){this.started&&(document.removeEventListener("readystatechange",this.interpretReadyState,!1),removeEventListener("pagehide",this.pageWillUnload,!1),this.started=!1)}pageIsInteractive(){this.stage==Dr.loading&&(this.stage=Dr.interactive,this.delegate.pageBecameInteractive())}pageIsComplete(){this.pageIsInteractive(),this.stage==Dr.interactive&&(this.stage=Dr.complete,this.delegate.pageLoaded())}get readyState(){return document.readyState}}class $0{constructor(e){y(this,"started",!1);y(this,"onScroll",()=>{this.updatePosition({x:window.pageXOffset,y:window.pageYOffset})});this.delegate=e}start(){this.started||(addEventListener("scroll",this.onScroll,!1),this.onScroll(),this.started=!0)}stop(){this.started&&(removeEventListener("scroll",this.onScroll,!1),this.started=!1)}updatePosition(e){this.delegate.scrollPositionChanged(e)}}class F0{render({fragment:e}){qg.preservingPermanentElements(this,N0(e),()=>{B0(e,()=>{U0(()=>{document.documentElement.appendChild(e)})})})}enteringBardo(e,t){t.replaceWith(e.cloneNode(!0))}leavingBardo(){}}function N0(r){const e=Fg(document.documentElement),t={};for(const i of e){const{id:o}=i;for(const l of r.querySelectorAll("turbo-stream")){const u=$g(l.templateElement.content,o);u&&(t[o]=[i,u])}}return t}async function B0(r,e){const t=`turbo-stream-autofocus-${yr()}`,i=r.querySelectorAll("turbo-stream"),o=H0(i);let l=null;if(o&&(o.id?l=o.id:l=t,o.id=l),e(),await vi(),(document.activeElement==null||document.activeElement==document.body)&&l){const d=document.getElementById(l);cc(d)&&d.focus(),d&&d.id==t&&d.removeAttribute("id")}}async function U0(r){const[e,t]=await PO(r,()=>document.activeElement),i=e&&e.id;if(i){const o=document.getElementById(i);cc(o)&&o!=t&&o.focus()}}function H0(r){for(const e of r){const t=Ag(e.templateElement.content);if(t)return t}return null}var pr;class q0{constructor(e){y(this,"sources",new Set);le(this,pr,!1);y(this,"inspectFetchResponse",e=>{const t=V0(e);t&&j0(t)&&(e.preventDefault(),this.receiveMessageResponse(t))});y(this,"receiveMessageEvent",e=>{K(this,pr)&&typeof e.data=="string"&&this.receiveMessageHTML(e.data)});this.delegate=e}start(){K(this,pr)||(ve(this,pr,!0),addEventListener("turbo:before-fetch-response",this.inspectFetchResponse,!1))}stop(){K(this,pr)&&(ve(this,pr,!1),removeEventListener("turbo:before-fetch-response",this.inspectFetchResponse,!1))}connectStreamSource(e){this.streamSourceIsConnected(e)||(this.sources.add(e),e.addEventListener("message",this.receiveMessageEvent,!1))}disconnectStreamSource(e){this.streamSourceIsConnected(e)&&(this.sources.delete(e),e.removeEventListener("message",this.receiveMessageEvent,!1))}streamSourceIsConnected(e){return this.sources.has(e)}async receiveMessageResponse(e){const t=await e.responseHTML;t&&this.receiveMessageHTML(t)}receiveMessageHTML(e){this.delegate.receivedMessageFromStream(Gr.wrap(e))}}pr=new WeakMap;function V0(r){var t;const e=(t=r.detail)==null?void 0:t.fetchResponse;if(e instanceof hc)return e}function j0(r){return(r.contentType??"").startsWith(Gr.contentType)}class W0 extends pc{static renderElement(e,t){const{documentElement:i,body:o}=document;i.replaceChild(t,o)}async render(){this.replaceHeadAndBody(),this.activateScriptElements()}replaceHeadAndBody(){const{documentElement:e,head:t}=document;e.replaceChild(this.newHead,t),this.renderElement(this.currentElement,this.newElement)}activateScriptElements(){for(const e of this.scriptElements){const t=e.parentNode;if(t){const i=Ei(e);t.replaceChild(i,e)}}}get newHead(){return this.newSnapshot.headSnapshot.element}get scriptElements(){return document.documentElement.querySelectorAll("script")}}var bo,Qg;class bc extends pc{constructor(){super(...arguments);le(this,bo)}static renderElement(t,i){document.body&&i instanceof HTMLBodyElement?document.body.replaceWith(i):document.documentElement.appendChild(i)}
25get shouldRender(){return this.newSnapshot.isVisitable&&this.trackedElementsAreIdentical}get reloadReason(){if(!this.newSnapshot.isVisitable)return{reason:"turbo_visit_control_is_reload"};if(!this.trackedElementsAreIdentical)return{reason:"tracked_element_mismatch"}}async prepareToRender(){Q(this,bo,Qg).call(this),await this.mergeHead()}async render(){this.willRender&&await this.replaceBody()}finishRendering(){super.finishRendering(),this.isPreview||this.focusFirstAutofocusableElement()}get currentHeadSnapshot(){return this.currentSnapshot.headSnapshot}get newHeadSnapshot(){return this.newSnapshot.headSnapshot}get newElement(){return this.newSnapshot.element}async mergeHead(){const t=this.mergeProvisionalElements(),i=this.copyNewHeadStylesheetElements();this.copyNewHeadScriptElements(),await t,await i,this.willRender&&this.removeUnusedDynamicStylesheetElements()}async replaceBody(){await this.preservingPermanentElements(async()=>{this.activateNewBody(),await this.assignNewBody()})}get trackedElementsAreIdentical(){return this.currentHeadSnapshot.trackedElementSignature==this.newHeadSnapshot.trackedElementSignature}async copyNewHeadStylesheetElements(){const t=[];for(const i of this.newHeadStylesheetElements)t.push(IO(i)),document.head.appendChild(i);await Promise.all(t)}copyNewHeadScriptElements(){for(const t of this.newHeadScriptElements)document.head.appendChild(Ei(t))}removeUnusedDynamicStylesheetElements(){for(const t of this.unusedDynamicStylesheetElements)document.head.removeChild(t)}async mergeProvisionalElements(){const t=[...this.newHeadProvisionalElements];for(const i of this.currentHeadProvisionalElements)this.isCurrentElementInElementList(i,t)||document.head.removeChild(i);for(const i of t)document.head.appendChild(i)}isCurrentElementInElementList(t,i){for(const[o,l]of i.entries()){if(t.tagName=="TITLE"){if(l.tagName!="TITLE")continue;if(t.innerHTML==l.innerHTML)return i.splice(o,1),!0}if(l.isEqualNode(t))return i.splice(o,1),!0}return!1}removeCurrentHeadProvisionalElements(){for(const t of this.currentHeadProvisionalElements)document.head.removeChild(t)}copyNewHeadProvisionalElements(){for(const t of this.newHeadProvisionalElements)document.head.appendChild(t)}activateNewBody(){document.adoptNode(this.newElement),this.removeNoscriptElements(),this.activateNewBodyScriptElements()}removeNoscriptElements(){for(const t of this.newElement.querySelectorAll("noscript"))t.remove()}activateNewBodyScriptElements(){for(const t of this.newBodyScriptElements){const i=Ei(t);t.replaceWith(i)}}async assignNewBody(){await this.renderElement(this.currentElement,this.newElement)}get unusedDynamicStylesheetElements(){return this.oldHeadStylesheetElements.filter(t=>t.getAttribute("data-turbo-track")==="dynamic")}get oldHeadStylesheetElements(){return this.currentHeadSnapshot.getStylesheetElementsNotInSnapshot(this.newHeadSnapshot)}get newHeadStylesheetElements(){return this.newHeadSnapshot.getStylesheetElementsNotInSnapshot(this.currentHeadSnapshot)}get newHeadScriptElements(){return this.newHeadSnapshot.getScriptElementsNotInSnapshot(this.currentHeadSnapshot)}get currentHeadProvisionalElements(){return this.currentHeadSnapshot.provisionalElements}get newHeadProvisionalElements(){return this.newHeadSnapshot.provisionalElements}get newBodyScriptElements(){return this.newElement.querySelectorAll("script")}}bo=new WeakSet,Qg=function(){const{documentElement:t}=this.currentSnapshot,{dir:i,lang:o}=this.newSnapshot;o?t.setAttribute("lang",o):t.removeAttribute("lang"),i?t.setAttribute("dir",i):t.removeAttribute("dir")};class Zg extends bc{static renderElement(e,t){yo(e,t,{callbacks:{beforeNodeMorphed:(i,o)=>Vg(i,o)&&!jg(i)?(i.reload(),!1):!0}}),Te("turbo:morph",{detail:{currentElement:e,newElement:t}})}async preservingPermanentElements(e){return await e()}get renderMethod(){return"morph"}get shouldAutofocus(){return!1}}class z0 extends Mg{constructor(e){super(e,js)}get snapshots(){return this.entries}}class K0 extends Ng{constructor(){super(...arguments);y(this,"snapshotCache",new z0(10));y(this,"lastRenderedLocation",new URL(location.href));y(this,"forceReloaded",!1)}shouldTransitionTo(t){return this.snapshot.prefersViewTransitions&&t.prefersViewTransitions}renderPage(t,i=!1,o=!0,l){var v;const d=this.isPageRefresh(l)&&(((v=l==null?void 0:l.refresh)==null?void 0:v.method)||this.snapshot.refreshMethod)==="morph"?Zg:bc,p=new d(this.snapshot,t,i,o);return p.shouldRender?l==null||l.changeHistory():this.forceReloaded=!0,this.render(p)}renderError(t,i){i==null||i.changeHistory();const o=new W0(this.snapshot,t,!1);return this.render(o)}clearSnapshotCache(){this.snapshotCache.clear()}async cacheSnapshot(t=this.snapshot){if(t.isCacheable){this.delegate.viewWillCacheSnapshot();const{lastRenderedLocation:i}=this;await _g();const o=t.clone();return this.snapshotCache.put(i,o),o}}getCachedSnapshotForLocation(t){return this.snapshotCache.get(t)}isPageRefresh(t){return!t||this.lastRenderedLocation.pathname===t.location.pathname&&t.action==="replace"}shouldPreserveScrollPosition(t){var i;return this.isPageRefresh(t)&&(((i=t==null?void 0:t.refresh)==null?void 0:i.scroll)||this.snapshot.refreshScroll)==="preserve"}get snapshot(){return St.fromElement(this.element)}}var Ni;class G0{constructor(e,t){y(this,"selector","a[data-turbo-preload]");le(this,Ni,()=>{this.preloadOnLoadLinksForView(document.body)});this.delegate=e,this.snapshotCache=t}start(){document.readyState==="loading"?document.addEventListener("DOMContentLoaded",K(this,Ni)):this.preloadOnLoadLinksForView(document.body)}stop(){document.removeEventListener("DOMContentLoaded",K(this,Ni))}preloadOnLoadLinksForView(e){for(const t of e.querySelectorAll(this.selector))this.delegate.shouldPreloadLink(t)&&this.preloadURL(t)}async preloadURL(e){const t=new URL(e.href);if(this.snapshotCache.has(t))return;await new Vi(this,gt.get,t,new URLSearchParams,e).perform()}prepareRequest(e){e.headers["X-Sec-Purpose"]="prefetch"}async requestSucceededWithResponse(e,t){try{const i=await t.responseHTML,o=St.fromHTMLString(i);this.snapshotCache.put(e.url,o)}catch{}}requestStarted(e){}requestErrored(e){}requestFinished(e){}requestPreventedHandlingResponse(e,t){}requestFailedWithResponse(e,t){}}Ni=new WeakMap;var Ln,Ks;class X0{constructor(e){le(this,Ln);this.session=e}clear(){this.session.clearCache()}resetCacheControl(){Q(this,Ln,Ks).call(this,"")}exemptPageFromCache(){Q(this,Ln,Ks).call(this,"no-cache")}exemptPageFromPreview(){Q(this,Ln,Ks).call(this,"no-preview")}}Ln=new WeakSet,Ks=function(e){RO("turbo-cache-control",e)};var Bi;class Y0{constructor(e){y(this,"navigator",new M0(this));y(this,"history",new O0(this));y(this,"view",new K0(this,document.documentElement));y(this,"adapter",new S0(this));
25y(this,"pageObserver",new D0(this));y(this,"cacheObserver",new A0);y(this,"linkPrefetchObserver",new C0(this,document));y(this,"linkClickObserver",new Ug(this,window));y(this,"formSubmitObserver",new gc(this,document));y(this,"scrollObserver",new $0(this));y(this,"streamObserver",new q0(this));y(this,"formLinkClickObserver",new Hg(this,document.documentElement));y(this,"frameRedirector",new T0(this,document.documentElement));y(this,"streamMessageRenderer",new F0);y(this,"cache",new X0(this));y(this,"enabled",!0);y(this,"started",!1);le(this,Bi,150);this.recentRequests=e,this.preloader=new G0(this,this.view.snapshotCache),this.debouncedRefresh=this.refresh,this.pageRefreshDebouncePeriod=this.pageRefreshDebouncePeriod}start(){this.started||(this.pageObserver.start(),this.cacheObserver.start(),this.linkPrefetchObserver.start(),this.formLinkClickObserver.start(),this.linkClickObserver.start(),this.formSubmitObserver.start(),this.scrollObserver.start(),this.streamObserver.start(),this.frameRedirector.start(),this.history.start(),this.preloader.start(),this.started=!0,this.enabled=!0)}disable(){this.enabled=!1}stop(){this.started&&(this.pageObserver.stop(),this.cacheObserver.stop(),this.linkPrefetchObserver.stop(),this.formLinkClickObserver.stop(),this.linkClickObserver.stop(),this.formSubmitObserver.stop(),this.scrollObserver.stop(),this.streamObserver.stop(),this.frameRedirector.stop(),this.history.stop(),this.preloader.stop(),this.started=!1)}registerAdapter(e){this.adapter=e}visit(e,t={}){const i=t.frame?document.getElementById(t.frame):null;if(i instanceof pt){const o=t.action||Vr(i);i.delegate.proposeVisitIfNavigatedWithAction(i,o),i.src=e.toString()}else this.navigator.proposeVisit($e(e),t)}refresh(e,t={}){t=typeof t=="string"?{requestId:t}:t;const{method:i,requestId:o,scroll:l}=t,u=o&&this.recentRequests.has(o),d=e===document.baseURI;!u&&!this.navigator.currentVisit&&d&&this.visit(e,{action:"replace",shouldCacheSnapshot:!1,refresh:{method:i,scroll:l}})}connectStreamSource(e){this.streamObserver.connectStreamSource(e)}disconnectStreamSource(e){this.streamObserver.disconnectStreamSource(e)}renderStreamMessage(e){this.streamMessageRenderer.render(Gr.wrap(e))}clearCache(){this.view.clearSnapshotCache()}setProgressBarDelay(e){console.warn("Please replace `session.setProgressBarDelay(delay)` with `session.progressBarDelay = delay`. The function is deprecated and will be removed in a future version of Turbo.`"),this.progressBarDelay=e}set progressBarDelay(e){ke.drive.progressBarDelay=e}get progressBarDelay(){return ke.drive.progressBarDelay}set drive(e){ke.drive.enabled=e}get drive(){return ke.drive.enabled}set formMode(e){ke.forms.mode=e}get formMode(){return ke.forms.mode}get location(){return this.history.location}get restorationIdentifier(){return this.history.restorationIdentifier}get pageRefreshDebouncePeriod(){return K(this,Bi)}set pageRefreshDebouncePeriod(e){this.refresh=xO(this.debouncedRefresh.bind(this),e),ve(this,Bi,e)}shouldPreloadLink(e){const t=e.hasAttribute("data-turbo-method"),i=e.hasAttribute("data-turbo-stream"),o=e.getAttribute("data-turbo-frame"),l=o=="_top"?null:document.getElementById(o)||An(e,"turbo-frame:not([disabled])");if(t||i||l instanceof pt)return!1;{const u=new URL(e.href);return this.elementIsNavigatable(e)&&dr(u,this.snapshot.rootLocation)}}historyPoppedToLocationWithRestorationIdentifierAndDirection(e,t,i){this.enabled?this.navigator.startVisit(e,t,{action:"restore",historyChanged:!0,direction:i}):this.adapter.pageInvalidated({reason:"turbo_disabled"})}historyPoppedWithEmptyState(e){this.history.replace(e),this.view.lastRenderedLocation=e,this.view.cacheSnapshot()}scrollPositionChanged(e){this.history.updateRestorationData({scrollPosition:e})}willSubmitFormLinkToLocation(e,t){return this.elementIsNavigatable(e)&&dr(t,this.snapshot.rootLocation)}submittedFormLinkToLocation(){}canPrefetchRequestToLocation(e,t){return this.elementIsNavigatable(e)&&dr(t,this.snapshot.rootLocation)&&this.navigator.linkPrefetchingIsEnabledForLocation(t)}willFollowLinkToLocation(e,t,i){return this.elementIsNavigatable(e)&&dr(t,this.snapshot.rootLocation)&&this.applicationAllowsFollowingLinkToLocation(e,t,i)}followedLinkToLocation(e,t){const i=this.getActionForLink(e),o=e.hasAttribute("data-turbo-stream");this.visit(t.href,{action:i,acceptsStreamResponse:o})}allowsVisitingLocationWithAction(e,t){return this.applicationAllowsVisitingLocation(e)}visitProposedToLocation(e,t){Nd(e),this.adapter.visitProposedToLocation(e,t)}visitStarted(e){e.acceptsStreamResponse||(to(document.documentElement),this.view.markVisitDirection(e.direction)),Nd(e.location),this.notifyApplicationAfterVisitingLocation(e.location,e.action)}visitCompleted(e){this.view.unmarkVisitDirection(),ro(document.documentElement),this.notifyApplicationAfterPageLoad(e.getTimingMetrics())}willSubmitForm(e,t){const i=uc(e,t);return this.submissionIsNavigatable(e,t)&&dr($e(i),this.snapshot.rootLocation)}formSubmitted(e,t){this.navigator.submitForm(e,t)}pageBecameInteractive(){this.view.lastRenderedLocation=this.location,this.notifyApplicationAfterPageLoad()}
25pageLoaded(){this.history.assumeControlOfScrollRestoration()}pageWillUnload(){this.history.relinquishControlOfScrollRestoration()}receivedMessageFromStream(e){this.renderStreamMessage(e)}viewWillCacheSnapshot(){this.notifyApplicationBeforeCachingSnapshot()}allowsImmediateRender({element:e},t){const i=this.notifyApplicationBeforeRender(e,t),{defaultPrevented:o,detail:{render:l}}=i;return this.view.renderer&&l&&(this.view.renderer.renderElement=l),!o}viewRenderedSnapshot(e,t,i){this.view.lastRenderedLocation=this.history.location,this.notifyApplicationAfterRender(i)}preloadOnLoadLinksForView(e){this.preloader.preloadOnLoadLinksForView(e)}viewInvalidated(e){this.adapter.pageInvalidated(e)}frameLoaded(e){this.notifyApplicationAfterFrameLoad(e)}frameRendered(e,t){this.notifyApplicationAfterFrameRender(e,t)}applicationAllowsFollowingLinkToLocation(e,t,i){return!this.notifyApplicationAfterClickingLinkToLocation(e,t,i).defaultPrevented}applicationAllowsVisitingLocation(e){return!this.notifyApplicationBeforeVisitingLocation(e).defaultPrevented}notifyApplicationAfterClickingLinkToLocation(e,t,i){return Te("turbo:click",{target:e,detail:{url:t.href,originalEvent:i},cancelable:!0})}notifyApplicationBeforeVisitingLocation(e){return Te("turbo:before-visit",{detail:{url:e.href},cancelable:!0})}notifyApplicationAfterVisitingLocation(e,t){return Te("turbo:visit",{detail:{url:e.href,action:t}})}notifyApplicationBeforeCachingSnapshot(){return Te("turbo:before-cache")}notifyApplicationBeforeRender(e,t){return Te("turbo:before-render",{detail:{newBody:e,...t},cancelable:!0})}notifyApplicationAfterRender(e){return Te("turbo:render",{detail:{renderMethod:e}})}notifyApplicationAfterPageLoad(e={}){return Te("turbo:load",{detail:{url:this.location.href,timing:e}})}notifyApplicationAfterFrameLoad(e){return Te("turbo:frame-load",{target:e})}notifyApplicationAfterFrameRender(e,t){return Te("turbo:frame-render",{detail:{fetchResponse:e},target:t,cancelable:!0})}submissionIsNavigatable(e,t){if(ke.forms.mode=="off")return!1;{const i=t?this.elementIsNavigatable(t):!0;return ke.forms.mode=="optin"?i&&e.closest('[data-turbo="true"]')!=null:i&&this.elementIsNavigatable(e)}}elementIsNavigatable(e){const t=An(e,"[data-turbo]"),i=An(e,"turbo-frame");return ke.drive.enabled||i?t?t.getAttribute("data-turbo")!="false":!0:t?t.getAttribute("data-turbo")=="true":!1}getActionForLink(e){return Vr(e)||"advance"}get snapshot(){return this.view.snapshot}}Bi=new WeakMap;function Nd(r){Object.defineProperties(r,Q0)}const Q0={absoluteURL:{get(){return this.toString()}}},Le=new Y0(Lg),{cache:Z0,navigator:J0}=Le;function Jg(){Le.start()}function eC(r){Le.registerAdapter(r)}function Eo(r,e){Le.visit(r,e)}function ep(r){Le.connectStreamSource(r)}function tp(r){Le.disconnectStreamSource(r)}function tC(r){Le.renderStreamMessage(r)}function rC(r){console.warn("Please replace `Turbo.setProgressBarDelay(delay)` with `Turbo.config.drive.progressBarDelay = delay`. The top-level function is deprecated and will be removed in a future version of Turbo.`"),ke.drive.progressBarDelay=r}function nC(r){console.warn("Please replace `Turbo.setConfirmMethod(confirmMethod)` with `Turbo.config.forms.confirm = confirmMethod`. The top-level function is deprecated and will be removed in a future version of Turbo.`"),ke.forms.confirm=r}function iC(r){console.warn("Please replace `Turbo.setFormMode(mode)` with `Turbo.config.forms.mode = mode`. The top-level function is deprecated and will be removed in a future version of Turbo.`"),ke.forms.mode=r}function sC(r,e){Zg.renderElement(r,e)}function oC(r,e){Wg.renderElement(r,e)}var aC=Object.freeze({__proto__:null,PageRenderer:bc,PageSnapshot:St,FrameRenderer:mc,fetch:Rg,config:ke,session:Le,cache:Z0,navigator:J0,start:Jg,registerAdapter:eC,visit:Eo,connectStreamSource:ep,disconnectStreamSource:tp,renderStreamMessage:tC,setProgressBarDelay:rC,setConfirmMethod:nC,setFormMode:iC,morphBodyElements:sC,morphTurboFrameElements:oC,morphChildren:vc,morphElements:yo});class lC extends Error{}var Xt,Pt,mr,Ui,Rn,Pn,J,bn,rp,np,ip,sp,op,ap,lp,_l,Fr,cp,Gs,up,hp,dp,wl;class cC{constructor(e){le(this,J);y(this,"fetchResponseLoaded",e=>Promise.resolve());le(this,Xt,null);le(this,Pt,()=>{});le(this,mr,!1);le(this,Ui,!1);le(this,Rn,new Set);le(this,Pn,!1);y(this,"action",null);y(this,"visitCachedSnapshot",({element:e})=>
25{const t=e.querySelector("#"+this.element.id);t&&this.previousFrameElement&&t.replaceChildren(...this.previousFrameElement.children),delete this.previousFrameElement});this.element=e,this.view=new i0(this,this.element),this.appearanceObserver=new jO(this,this.element),this.formLinkClickObserver=new Hg(this,this.element),this.linkInterceptor=new Bg(this,this.element),this.restorationIdentifier=yr(),this.formSubmitObserver=new gc(this,this.element)}connect(){K(this,mr)||(ve(this,mr,!0),this.loadingStyle==wn.lazy?this.appearanceObserver.start():Q(this,J,bn).call(this),this.formLinkClickObserver.start(),this.linkInterceptor.start(),this.formSubmitObserver.start())}disconnect(){var e;K(this,mr)&&(ve(this,mr,!1),this.appearanceObserver.stop(),this.formLinkClickObserver.stop(),this.linkInterceptor.stop(),this.formSubmitObserver.stop(),this.element.hasAttribute("recurse")||(e=K(this,Xt))==null||e.cancel())}disabledChanged(){var e;this.disabled?(e=K(this,Xt))==null||e.cancel():this.loadingStyle==wn.eager&&Q(this,J,bn).call(this)}sourceURLChanged(){var e;Q(this,J,up).call(this,"src")||(this.sourceURL||(e=K(this,Xt))==null||e.cancel(),this.element.isConnected&&(this.complete=!1),(this.loadingStyle==wn.eager||K(this,Ui))&&Q(this,J,bn).call(this))}sourceURLReloaded(){const{refresh:e,src:t}=this.element;return ve(this,Pn,t&&e==="morph"),this.element.removeAttribute("complete"),this.element.src=null,this.element.src=t,this.element.loaded}loadingStyleChanged(){this.loadingStyle==wn.lazy?this.appearanceObserver.start():(this.appearanceObserver.stop(),Q(this,J,bn).call(this))}async loadResponse(e){(e.redirected||e.succeeded&&e.isHTML)&&(this.sourceURL=e.response.url);try{const t=await e.responseHTML;if(t){const i=wg(t);St.fromDocument(i).isVisitable?await Q(this,J,rp).call(this,e,i):await Q(this,J,sp).call(this,e)}}finally{ve(this,Pn,!1),this.fetchResponseLoaded=()=>Promise.resolve()}}elementAppearedInViewport(e){this.proposeVisitIfNavigatedWithAction(e,Vr(e)),Q(this,J,bn).call(this)}willSubmitFormLinkToLocation(e){return Q(this,J,Gs).call(this,e)}submittedFormLinkToLocation(e,t,i){const o=Q(this,J,Fr).call(this,e);o&&i.setAttribute("data-turbo-frame",o.id)}shouldInterceptLinkClick(e,t,i){return Q(this,J,Gs).call(this,e)}linkClickIntercepted(e,t){Q(this,J,ip).call(this,e,t)}willSubmitForm(e,t){return e.closest("turbo-frame")==this.element&&Q(this,J,Gs).call(this,e,t)}formSubmitted(e,t){this.formSubmission&&this.formSubmission.stop(),this.formSubmission=new _o(this,e,t);const{fetchRequest:i}=this.formSubmission,o=Q(this,J,Fr).call(this,e,t);this.prepareRequest(i,o),this.formSubmission.start()}prepareRequest(e,t=this){var i;e.headers["Turbo-Frame"]=t.id,(i=this.currentNavigationElement)!=null&&i.hasAttribute("data-turbo-stream")&&e.acceptResponseType(Gr.contentType)}requestStarted(e){to(this.element)}requestPreventedHandlingResponse(e,t){K(this,Pt).call(this)}async requestSucceededWithResponse(e,t){await this.loadResponse(t),K(this,Pt).call(this)}async requestFailedWithResponse(e,t){await this.loadResponse(t),K(this,Pt).call(this)}requestErrored(e,t){console.error(t),K(this,Pt).call(this)}requestFinished(e){ro(this.element)}formSubmissionStarted({formElement:e}){to(e,Q(this,J,Fr).call(this,e))}formSubmissionSucceededWithResponse(e,t){const i=Q(this,J,Fr).call(this,e.formElement,e.submitter);i.delegate.proposeVisitIfNavigatedWithAction(i,Vr(e.submitter,e.formElement,i)),i.delegate.loadResponse(t),e.isSafe||Le.clearCache()}formSubmissionFailedWithResponse(e,t){this.element.delegate.loadResponse(t),Le.clearCache()}formSubmissionErrored(e,t){console.error(t)}formSubmissionFinished({formElement:e}){ro(e,Q(this,J,Fr).call(this,e))}allowsImmediateRender({element:e},t){const i=Te("turbo:before-frame-render",{target:this.element,detail:{newFrame:e,...t},cancelable:!0}),{defaultPrevented:o,detail:{render:l}}=i;return this.view.renderer&&l&&(this.view.renderer.renderElement=l),!o}viewRenderedSnapshot(e,t,i){}preloadOnLoadLinksForView(e){Le.preloadOnLoadLinksForView(e)}viewInvalidated(){}willRenderFrame(e,t){this.previousFrameElement=e.cloneNode(!0)}proposeVisitIfNavigatedWithAction(e,t=null){if(this.action=t,this.action){const i=St.from
25Element(e).clone(),{visitCachedSnapshot:o}=e.delegate;e.delegate.fetchResponseLoaded=async l=>{if(e.src){const{statusCode:u,redirected:d}=l,p=await l.responseHTML,S={response:{statusCode:u,redirected:d,responseHTML:p},visitCachedSnapshot:o,willRender:!1,updateHistory:!1,restorationIdentifier:this.restorationIdentifier,snapshot:i};this.action&&(S.action=this.action),Le.visit(e.src,S)}}}}changeHistory(){if(this.action){const e=Eg(this.action);Le.history.update(e,$e(this.element.src||""),this.restorationIdentifier)}}async extractForeignFrameElement(e){let t;const i=CSS.escape(this.id);try{if(t=Bd(e.querySelector(`turbo-frame#${i}`),this.sourceURL),t)return t;if(t=Bd(e.querySelector(`turbo-frame[src][recurse~=${i}]`),this.sourceURL),t)return await t.loaded,await this.extractForeignFrameElement(t)}catch(o){return console.error(o),new pt}return null}get id(){return this.element.id}get disabled(){return this.element.disabled}get enabled(){return!this.disabled}get sourceURL(){if(this.element.src)return this.element.src}set sourceURL(e){Q(this,J,hp).call(this,"src",()=>{this.element.src=e??null})}get loadingStyle(){return this.element.loading}get isLoading(){return this.formSubmission!==void 0||K(this,Pt).call(this)!==void 0}get complete(){return this.element.hasAttribute("complete")}set complete(e){e?this.element.setAttribute("complete",""):this.element.removeAttribute("complete")}get isActive(){return this.element.isActive&&K(this,mr)}get rootLocation(){const e=this.element.ownerDocument.querySelector('meta[name="turbo-root"]'),t=(e==null?void 0:e.content)??"/";return $e(t)}}Xt=new WeakMap,Pt=new WeakMap,mr=new WeakMap,Ui=new WeakMap,Rn=new WeakMap,Pn=new WeakMap,J=new WeakSet,bn=async function(){this.enabled&&this.isActive&&!this.complete&&this.sourceURL&&(this.element.loaded=Q(this,J,np).call(this,$e(this.sourceURL)),this.appearanceObserver.stop(),await this.element.loaded,ve(this,Ui,!0))},rp=async function(e,t){const i=await this.extractForeignFrameElement(t.body),o=K(this,Pn)?Wg:mc;if(i){const l=new wo(i),u=new o(this,this.view.snapshot,l,!1,!1);this.view.renderPromise&&await this.view.renderPromise,this.changeHistory(),await this.view.render(u),this.complete=!0,Le.frameRendered(e,this.element),Le.frameLoaded(this.element),await this.fetchResponseLoaded(e)}else Q(this,J,op).call(this,e)&&Q(this,J,ap).call(this,e)},np=async function(e){var i;const t=new Vi(this,gt.get,e,new URLSearchParams,this.element);return(i=K(this,Xt))==null||i.cancel(),ve(this,Xt,t),new Promise(o=>{ve(this,Pt,()=>{ve(this,Pt,()=>{}),ve(this,Xt,null),o()}),t.perform()})},ip=function(e,t,i){const o=Q(this,J,Fr).call(this,e,i);o.delegate.proposeVisitIfNavigatedWithAction(o,Vr(i,e,o)),Q(this,J,dp).call(this,e,()=>{o.src=t})},sp=async function(e){console.warn(`The response (${e.statusCode}) from <turbo-frame id="${this.element.id}"> is performing a full page visit due to turbo-visit-control.`),await Q(this,J,_l).call(this,e.response)},op=function(e){this.element.setAttribute("complete","");const t=e.response,i=async(l,u)=>{l instanceof Response?Q(this,J,_l).call(this,l):Le.visit(l,u)};return!Te("turbo:frame-missing",{target:this.element,detail:{response:t,visit:i},cancelable:!0}).defaultPrevented},ap=function(e){this.view.missing(),Q(this,J,lp).call(this,e)},lp=function(e){const t=`The response (${e.statusCode}) did not contain the expected <turbo-frame id="${this.element.id}"> and will be ignored. To perform a full page visit instead, set turbo-visit-control to reload.`;throw new lC(t)},_l=async function(e){const t=new hc(e),i=await t.responseHTML,{location:o,redirected:l,statusCode:u}=t;return Le.visit(o,{response:{redirected:l,statusCode:u,responseHTML:i}})},Fr=function(e,t){const i=eo("data-turbo-frame",t,e)||this.element.getAttribute("target"),o=Q(this,J,wl).call(this,i);return o instanceof pt?o:this.element},cp=function(e,t){const i=uc(e,t);return dr($e(i),this.rootLocation)},Gs=function(e,t){const i=eo("data-turbo-frame",t,e)||this.element.getAttribute("target");if(e instanceof HTMLFormElement&&!Q(this,J,cp).call(this,e,t)||!this.enabled||i=="_top")return!1;if(i){const o=Q(this,J,wl).call(this,i);if(o)return!o.disabled;if(i=="_parent")return!1}return!(!Le.elementIsNavigatable(e)||t&&!Le.elementIsNavigatable(t))},up=function(e){return K(this,Rn).has(e)},hp=function(e,t){K(this,Rn).add(e),t(),K(this,Rn).delete(e)},dp=function(e,t){this.currentNavigationElement=e,t(),delete this.currentNavigationElement},wl=function(e){if(e!=null){const t=e==="_parent"?this.element.parentElement.closest("turbo-frame"):document.getElementById(e);if(t instanceof pt)return t}};function Bd(r,e){if(r){const t=r.getAttribute("src");if(t!=null&&e!=null&&Ig(t,e))throw new Error(`Matching <turbo-frame id="${r.id}"> element has a source URL which references itself`);if(r.ownerDocument!==document&&(r=document.importNode(r,!0)),r instanceof pt)return r.connectedCallback(),r.disconnectedCallback(),r}}const fp={after(){this.removeDuplicateTargetSiblings(),this.targetElements.forEac
25h(r=>{var e;return(e=r.parentElement)==null?void 0:e.insertBefore(this.templateContent,r.nextSibling)})},append(){this.removeDuplicateTargetChildren(),this.targetElements.forEach(r=>r.append(this.templateContent))},before(){this.removeDuplicateTargetSiblings(),this.targetElements.forEach(r=>{var e;return(e=r.parentElement)==null?void 0:e.insertBefore(this.templateContent,r)})},prepend(){this.removeDuplicateTargetChildren(),this.targetElements.forEach(r=>r.prepend(this.templateContent))},remove(){this.targetElements.forEach(r=>r.remove())},replace(){const r=this.getAttribute("method");this.targetElements.forEach(e=>{r==="morph"?yo(e,this.templateContent):e.replaceWith(this.templateContent)})},update(){const r=this.getAttribute("method");this.targetElements.forEach(e=>{r==="morph"?vc(e,this.templateContent):(e.innerHTML="",e.append(this.templateContent))})},refresh(){const r=this.getAttribute("method"),e=this.requestId,t=this.getAttribute("scroll");Le.refresh(this.baseURI,{method:r,requestId:e,scroll:t})}};var Hr,di;const Wc=class Wc extends HTMLElement{constructor(){super(...arguments);le(this,Hr)}static async renderElement(t){await t.performAction()}async connectedCallback(){try{await this.render()}catch(t){console.error(t)}finally{this.disconnect()}}async render(){return this.renderPromise??(this.renderPromise=(async()=>{const t=this.beforeRenderEvent;this.dispatchEvent(t)&&(await vi(),await t.detail.render(this))})())}disconnect(){try{this.remove()}catch{}}removeDuplicateTargetChildren(){this.duplicateChildren.forEach(t=>t.remove())}get duplicateChildren(){var o;const t=this.targetElements.flatMap(l=>[...l.children]).filter(l=>!!l.getAttribute("id")),i=[...((o=this.templateContent)==null?void 0:o.children)||[]].filter(l=>!!l.getAttribute("id")).map(l=>l.getAttribute("id"));return t.filter(l=>i.includes(l.getAttribute("id")))}removeDuplicateTargetSiblings(){this.duplicateSiblings.forEach(t=>t.remove())}get duplicateSiblings(){var o;const t=this.targetElements.flatMap(l=>[...l.parentElement.children]).filter(l=>!!l.id),i=[...((o=this.templateContent)==null?void 0:o.children)||[]].filter(l=>!!l.id).map(l=>l.id);return t.filter(l=>i.includes(l.id))}get performAction(){if(this.action){const t=fp[this.action];if(t)return t;Q(this,Hr,di).call(this,"unknown action")}Q(this,Hr,di).call(this,"action attribute is missing")}get targetElements(){if(this.target)return this.targetElementsById;if(this.targets)return this.targetElementsByQuery;Q(this,Hr,di).call(this,"target or targets attribute is missing")}get templateContent(){return this.templateElement.content.cloneNode(!0)}get templateElement(){if(this.firstElementChild===null){const t=this.ownerDocument.createElement("template");return this.appendChild(t),t}else if(this.firstElementChild instanceof HTMLTemplateElement)return this.firstElementChild;Q(this,Hr,di).call(this,"first child element must be a <template> element")}get action(){return this.getAttribute("action")}get target(){return this.getAttribute("target")}get targets(){return this.getAttribute("targets")}get requestId(){return this.getAttribute("request-id")}get description(){return(this.outerHTML.match(/<[^>]+>/)??[])[0]??"<turbo-stream>"}get beforeRenderEvent(){return new CustomEvent("turbo:before-stream-render",{bubbles:!0,cancelable:!0,detail:{newStream:this,render:Wc.renderElement}})}get targetElementsById(){var i;const t=(i=this.ownerDocument)==null?void 0:i.getElementById(this.target);return t!==null?[t]:[]}get targetElementsByQuery(){var i;const t=(i=this.ownerDocument)==null?void 0:i.querySelectorAll(this.targets);return t.length!==0?Array.prototype.slice.call(t):[]}};Hr=new WeakSet,di=function(t){throw new Error(`${this.description}: ${t}`)};let yl=Wc;class uC extends HTMLElement{constructor(){super(...arguments);y(this,"streamSource",null)}connectedCallback(){this.streamSource=this.src.match(/^ws{1,2}:/)?new WebSocket(this.src):new EventSource(this.src),ep(this.streamSource)}disconnectedCallback(){this.streamSource&&(this.streamSource.close(),tp(this.streamSource))}get src(){return this.getAttribute("src")||""}}pt.delegateConstructor=cC;customElements.get("turbo-frame")===void 0&&customElements.define("turbo-frame",pt);customElements.get("turbo-stream")===void 0&&customElements.define("turbo-stream",yl);customElements.get("turbo-stream-source")===void 0&&customElements.define("turbo-stream-source",uC);(()=>{const r=document.currentScript;if(!r||r.hasAttribute("data-turbo-suppress-warning"))return;let e=r.parentElement;for(;e;){if(e==document.body)return console.warn(yg` 26 You are loading Turbo from a <script> element inside the <body> element. This is probably not what you meant to do! 27 28 Load your applicationâs JavaScript bundle inside the <head> element instead. <script> elements in <body> are evaluated with each page change. 29 30 For more information, see: https://turbo.hotwired.dev/handbook/building#working-with-script-elements 31 32 ââ 33 Suppress this warning by adding a "data-turbo-suppress-warning" attribute to: %s 34 `,r.outerHTML);e=e.parentElement}})();window.Turbo={...aC,StreamActions:fp};Jg();var Yt=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function So(r){return r&&r.__esModule&&Object.prototype.hasOwnProperty.call(r,"default")?r.default:r}function hC(r){var e=typeof r;return r!=null&&(e=="object"||e=="function")}var Xr=hC,dC=typeof Yt=="object"&&Yt&&Yt.Object===Object&&Yt,gp=dC,fC=gp,gC=typeof self=="object"&&self&&self.Object===Object&&self,pC=fC||gC||Function("return this")(),Ao=pC,mC=Ao,vC=function(){return mC.Date.now()},bC=vC,_C=/\s/;function wC(r){for(var e=r.length;e--&&_C.test(r.charAt(e)););return e}var yC=wC,EC=yC,SC=/^\s+/;function AC(r){return r&&r.slice(0,EC(r)+1).replace(SC,"")}
34var TC=AC,OC=Ao,CC=OC.Symbol,_c=CC,Ud=_c,pp=Object.prototype,IC=pp.hasOwnProperty,LC=pp.toString,ui=Ud?Ud.toStringTag:void 0;function RC(r){var e=IC.call(r,ui),t=r[ui];try{r[ui]=void 0;var i=!0}catch{}var o=LC.call(r);return i&&(e?r[ui]=t:delete r[ui]),o}var PC=RC,xC=Object.prototype,kC=xC.toString;function MC(r){return kC.call(r)}var DC=MC,Hd=_c,$C=PC,FC=DC,NC="[object Null]",BC="[object Undefined]",qd=Hd?Hd.toStringTag:void 0;function UC(r){return r==null?r===void 0?BC:NC:qd&&qd in Object(r)?$C(r):FC(r)}var Nn=UC;function HC(r){return r!=null&&typeof r=="object"}var Bn=HC,qC=Nn,VC=Bn,jC="[object Symbol]";function WC(r){return typeof r=="symbol"||VC(r)&&qC(r)==jC}var mp=WC,zC=TC,Vd=Xr,KC=mp,jd=NaN,GC=/^[-+]0x[0-9a-f]+$/i,XC=/^0b[01]+$/i,YC=/^0o[0-7]+$/i,QC=parseInt;function ZC(r){if(typeof r=="number")return r;if(KC(r))return jd;if(Vd(r)){var e=typeof r.valueOf=="function"?r.valueOf():r;r=Vd(e)?e+"":e}if(typeof r!="string")return r===0?r:+r;r=zC(r);var t=XC.test(r);return t||YC.test(r)?QC(r.slice(2),t?2:8):GC.test(r)?jd:+r}var JC=ZC,eI=Xr,Ja=bC,Wd=JC,tI="Expected a function",rI=Math.max,nI=Math.min;function iI(r,e,t){var i,o,l,u,d,p,v=0,S=!1,O=!1,k=!0;if(typeof r!="function")throw new TypeError(tI);e=Wd(e)||0,eI(t)&&(S=!!t.leading,O="maxWait"in t,l=O?rI(Wd(t.maxWait)||0,e):l,k="trailing"in t?!!t.trailing:k);function D(L){var $=i,q=o;return i=o=void 0,v=L,u=r.apply(q,$),u}function N(L){return v=L,d=setTimeout(H,e),S?D(L):u}function B(L){var $=L-p,q=L-v,W=e-$;return O?nI(W,l-q):W}function V(L){var $=L-p,q=L-v;return p===void 0||$>=e||$<0||O&&q>=l}function H(){var L=Ja();if(V(L))return x(L);d=setTimeout(H,B(L))}function x(L){return d=void 0,k&&i?D(L):(i=o=void 0,u)}function M(){d!==void 0&&clearTimeout(d),v=0,i=p=o=d=void 0}function E(){return d===void 0?u:x(Ja())}function A(){var L=Ja(),$=V(L);if(i=arguments,o=this,p=L,$){if(d===void 0)return N(p);if(O)return clearTimeout(d),d=setTimeout(H,e),D(p)}return d===void 0&&(d=setTimeout(H,e)),u}return A.cancel=M,A.flush=E,A}var vp=iI;const xn=So(vp);var sI=Nn,oI=Xr,aI="[object AsyncFunction]",lI="[object Function]",cI="[object GeneratorFunction]",uI="[object Proxy]";function hI(r){if(!oI(r))return!1;var e=sI(r);return e==lI||e==cI||e==aI||e==uI}var bp=hI,dI=Ao,fI=dI["__core-js_shared__"],gI=fI,el=gI,zd=function(){var r=
vendor: 4,100 bytes, line 34
34/[^.]+$/.exec(el&&el.keys&&el.keys.IE_PROTO||"");return r?"Symbol(src)_1."+r:""}();function pI(r){return!!zd&&zd in r}var mI=pI,vI=Function.prototype,bI=vI.toString;function _I(r){if(r!=null){try{return bI.call(r)}catch{}try{return r+""}catch{}}return""}var wI=_I,yI=bp,EI=mI,SI=Xr,AI=wI,TI=/[\\^$.*+?()[\]{}|]/g,OI=/^\[object .+?Constructor\]$/,CI=Function.prototype,II=Object.prototype,LI=CI.toString,RI=II.hasOwnProperty,PI=RegExp("^"+LI.call(RI).replace(TI,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function xI(r){if(!SI(r)||EI(r))return!1;var e=yI(r)?PI:OI;return e.test(AI(r))}var kI=xI;function MI(r,e){return r==null?void 0:r[e]}var DI=MI,$I=kI,FI=DI;function NI(r,e){var t=FI(r,e);return $I(t)?t:void 0}var BI=NI,UI=BI,HI=function(){try{var r=UI(Object,"defineProperty");return r({},"",{}),r}catch{}}(),_p=HI,Kd=_p;function qI(r,e,t){e=="__proto__"&&Kd?Kd(r,e,{configurable:!0,enumerable:!0,value:t,writable:!0}):r[e]=t}var wp=qI;function VI(r,e){return r===e||r!==r&&e!==e}var wc=VI,jI=wp,WI=wc,zI=Object.prototype,KI=zI.hasOwnProperty;function GI(r,e,t){var i=r[e];(!(KI.call(r,e)&&WI(i,t))||t===void 0&&!(e in r))&&jI(r,e,t)}var XI=GI,YI=XI,QI=wp;function ZI(r,e,t,i){var o=!t;t||(t={});for(var l=-1,u=e.length;++l<u;){var d=e[l],p=i?i(t[d],r[d],d,t,r):void 0;p===void 0&&(p=r[d]),o?QI(t,d,p):YI(t,d,p)}return t}var JI=ZI;function eL(r){return r}var yp=eL;function tL(r,e,t){switch(t.length){case 0:return r.call(e);case 1:return r.call(e,t[0]);case 2:return r.call(e,t[0],t[1]);case 3:return r.call(e,t[0],t[1],t[2])}return r.apply(e,t)}var Ep=tL,rL=Ep,Gd=Math.max;function nL(r,e,t){return e=Gd(e===void 0?r.length-1:e,0),function(){for(var i=arguments,o=-1,l=Gd(i.length-e,0),u=Array(l);++o<l;)u[o]=i[e+o];o=-1;for(var d=Array(e+1);++o<e;)d[o]=i[o];return d[e]=t(u),rL(r,this,d)}}var iL=nL;function sL(r){return function(){return r}}var oL=sL,aL=oL,Xd=_p,lL=yp,cL=Xd?function(r,e){return Xd(r,"toString",{configurable:!0,enumerable:!1,value:aL(e),writable:!0})}:lL,uL=cL,hL=800,dL=16,fL=Date.now;function gL(r){var e=0,t=0;return function(){var i=fL(),o=dL-(i-t);if(t=i,o>0){if(++e>=hL)return arguments[0]}else e=0;return r.apply(void 0,arguments)}}var pL=gL,mL=uL,vL=pL,bL=vL(mL),_L=bL,wL=yp,yL=iL,EL=_L;function SL(r,e){return EL(yL(r,e,wL),r+"")}var Sp=SL,AL=9007199254740991;function TL(r){return typeof r=="number"&&r>-1&&r%1==0&&r<=AL}var Ap=TL,OL=bp,CL=Ap;function IL(r){return r!=null&&CL(r.length)&&!OL(r)}var yc=IL,LL=9007199254740991,RL=/^(?:0|[1-9]\d*)$/;function PL(r,e){var t=typeof r;return e=e??LL,!!e&&(t=="number"||t!="symbol"&&RL.test(r))&&r>-1&&r%1==0&&r<e}var Tp=PL,xL=wc,kL=yc,ML=Tp,DL=Xr;function $L(r,e,t){if(!DL(t))return!1;var i=typeof e;return(i=="number"?kL(t)&&ML(e,t.length):i=="string"&&e in t)?xL(t[e],r):!1}var Op=$L,FL=Sp,NL=Op;function BL(r){return FL(function(e,t){var i=-1,o=t.length,l=o>1?t[o-1]:void 0,u=o>2?t[2]:void 0;for(l=r.length>3&&typeof l=="function"?(o--,l):void 0,u&&NL(t[0],t[1],u)&&(l=o<3?void 0:l,o=1),e=Object(e);++i<o;){var d=t[i];d&&r(e,d,i,l)}return e})}var UL=BL;function HL(r,e){for(var t=-1,i=Array(r);++t<r;)i[t]=e(t);return i}var qL=HL,VL=Nn,jL=Bn,WL="[object Arguments]";function zL(r){return jL(r)&&VL(r)==WL}var KL=zL,Yd=KL,GL=Bn,Cp=Object.prototype,XL=Cp.hasOwnProperty,YL=Cp.propertyIsEnumerable,QL=Yd(function(){return arguments}())?Yd:function(r){return GL(r)&&XL.call(r,"callee")&&!YL.call(r,"callee")},ZL=QL,JL=Array.isArray,Ip=JL,io={exports:{}};function eR(){return!1}var tR=eR;io.exports;(function(r,e){var t=Ao,i=tR,o=e&&!e.nodeType&&e,l=o&&!0&&r&&!r.nodeType&&r,u=l&&l.exports===o,d=u?t.Buffer:void 0,p=d?d.isBuffer:void 0,v=p||i;r.exports=v})(io,io.exports);var rR=io.exports,nR=Nn,iR=Ap,sR=Bn,oR="[object Arguments]",aR="[object Array]",lR="[object Boolean]",cR="[object Date]",uR="[object Error]",hR="[object Function]",dR="[object Map]",fR="[object Number]",gR="[object Object]",pR="[object RegExp]",mR="[object Set]",vR="[object String]",bR="[object WeakMap]",_R="[object ArrayBuffer]",wR="[object DataView]",yR="[object Float32Array]",ER="[object Float64Array
34]",SR="[object Int8Array]",AR="[object Int16Array]",TR="[object Int32Array]",OR="[object Uint8Array]",CR="[object Uint8ClampedArray]",IR="[object Uint16Array]",LR="[object Uint32Array]",Ee={};Ee[yR]=Ee[ER]=Ee[SR]=Ee[AR]=Ee[TR]=Ee[OR]=Ee[CR]=Ee[IR]=Ee[LR]=!0;Ee[oR]=Ee[aR]=Ee[_R]=Ee[lR]=Ee[wR]=Ee[cR]=Ee[uR]=Ee[hR]=Ee[dR]=Ee[fR]=Ee[gR]=Ee[pR]=Ee[mR]=Ee[vR]=Ee[bR]=!1;function RR(r){return sR(r)&&iR(r.length)&&!!Ee[nR(r)]}var PR=RR;function xR(r){return function(e){return r(e)}}var kR=xR,so={exports:{}};so.exports;(function(r,e){var t=gp,i=e&&!e.nodeType&&e,o=i&&!0&&r&&!r.nodeType&&r,l=o&&o.exports===i,u=l&&t.process,d=function(){try{var p=o&&o.require&&o.require("util").types;return p||u&&u.binding&&u.binding("util")}catch{}}();r.exports=d})(so,so.exports);var MR=so.exports,DR=PR,$R=kR,Qd=MR,Zd=Qd&&Qd.isTypedArray,FR=Zd?$R(Zd):DR,NR=FR,BR=qL,UR=ZL,HR=Ip,qR=rR,VR=Tp,jR=NR,WR=Object.prototype,zR=WR.hasOwnProperty;function KR(r,e){var t=HR(r),i=!t&&UR(r),o=!t&&!i&&qR(r),l=!t&&!i&&!o&&jR(r),u=t||i||o||l,d=u?BR(r.length,String):[],p=d.length;for(var v in r)(e||zR.call(r,v))&&!(u&&(v=="length"||o&&(v=="offset"||v=="parent")||l&&(v=="buffer"||v=="byteLength"||v=="byteOffset")||VR(v,p)))&&d.push(v);return d}var Lp=KR,GR=Object.prototype;function XR(r){var e=r&&r.constructor,t=typeof e=="function"&&e.prototype||GR;return r===t}var Rp=XR;function YR(r){var e=[];if(r!=null)for(var t in Object(r))e.push(t);return e}var QR=YR,ZR=Xr,JR=Rp,eP=QR,tP=Object.prototype,rP=tP.hasOwnProperty;function nP(r){if(!ZR(r))return eP(r);var e=JR(r),t=[];for(var i in r)i=="constructor"&&(e||!rP.call(r,i))||t.push(i);return t}var iP=nP,sP=Lp,oP=iP,aP=yc;function lP(r){return aP(r)?sP(r,!0):oP(r)}var cP=lP,uP=JI,hP=UL,dP=cP,fP=hP(function(r,e,t,i){uP(e,dP(e),r,i)}),gP=fP;function pP(r,e){return function(t){return r(e(t))}}var Pp=pP,mP=Pp,vP=mP(Object.getPrototypeOf,Object),bP=vP,_P=Nn,wP=bP,yP=Bn,EP="[object Object]",SP=Function.prototype,AP=Object.prototype,xp=SP.toString,TP=AP.hasOwnProperty,OP=xp.call(Object);function CP(r){if(!yP(r)||_P(r)!=EP)return!1;var e=wP(r);if(e===null)return!0;var t=TP.call(e,"constructor")&&e.constructor;return typeof t=="function"&&t instanceof t&&xp.call(t)==OP}var IP=CP,LP=Nn,RP=Bn,PP=IP,xP="[object DOMException]",kP="[object Error]";function MP(r){if(!RP(r))return!1;var e=LP(r);return e==kP||e==xP||typeof r.message=="string"&&typeof r.name=="string"&&!PP(r)}var kp=MP,DP=Ep,$P=Sp,FP=kp,NP=$P(function(r,e){try{return DP(r,void 0,e)}catch(t){return FP(t)?t:new Error(t)}}),BP=NP;function UP(r,e){for(var t=-1,i=r==null?0:r.length,o=Array(i);++t<i;)o[t]=e(r[t],t,r);return o}var Mp=UP,HP=Mp;function qP(r,e){return HP(e,function(t){return r[t]})}var VP=qP,jP=wc,Dp=Object.prototype,WP=Dp.hasOwnProperty;function zP(r,e,t,i){return r===void 0||jP(r,Dp[t])&&!WP.call(i,t)?e:r}var KP=zP,GP={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"};function XP(r){return"\\"+GP[r]}var YP=XP,QP=Pp,ZP=QP(Object.keys,Object),JP=ZP,ex=Rp,tx=JP,rx=Object.prototype,nx=rx.hasOwnProperty;function ix(r){if(!ex(r))return tx(r);var e=[];for(var t in Object(r))nx.call(r,t)&&t!="constructor"&&e.push(t);return e}var sx=ix,ox=Lp,ax=sx,lx=yc;function cx(r){return lx(r)?ox(r):ax(r)}var ux=cx,hx=/<%=([\s\S]+?)%>/g,$p=hx;function dx(r){return function(e){return r==null?void 0:r[e]}}var fx=dx,gx=fx,px={"&":"&","<":"<",">":">",'"':""","'":"'"},mx=gx(px),vx=mx,Jd=_c,bx=Mp,_x=Ip,wx=mp,yx=1/0,ef=Jd?Jd.prototype:void 0,tf=ef?ef.toString:void 0;function Fp(r){if(typeof r=="string")return r;if(_x(r))return bx(r,Fp)+"";if(wx(r))return tf?tf.call(r):"";var e=r+"";return e=="0"&&1/r==-yx?"-0":e}var Ex=Fp,Sx=Ex;function Ax(r){return r==null?"":Sx(r)}var Np=Ax,Tx=vx,Ox=Np,Bp=/[&<>"']/g,Cx=RegExp(Bp.source);function Ix(r){return r=Ox(r),r&&Cx.test(r)?r.replace(Bp,Tx):r}var Lx=Ix,Rx=/<%-([\s\S]+?)%>/g,Px=Rx,xx=/<%([\s\S]+?)%>/g,kx=xx,Mx=Lx,Dx=Px,$x=kx,Fx=$p,Nx={escape:Dx,evaluate:$x,interpolate:Fx,variable:"",imports:{_:{escape:Mx}}},Bx=Nx,rf=gP,Ux=BP,Hx=VP,nf=KP,qx=YP,Vx=kp,jx=Op,Wx=ux,zx=$p,sf=Bx,Kx=Np,Gx="Invalid `variable` option passed into `_.template`",Xx=/\b__p \+= '';/g,Yx=/\b(__p \+=) '' \+/g,Qx=/(__e\(.*?\)|\b__t\)) \+\n'';/g,Zx=/[()=,{}\[\]\/\s]/,Jx=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,Hs=/($^)/,ek=/['\n\r\u2028\u2029\\]/g,tk=Object.prototype,of=tk.hasOwnProperty;function rk(r,e,t){var i=sf.imports._.templateSettings||sf;t&&jx(r,e,t)&&(e=void 0),r=Kx(r),e=rf({},e,i,nf);var o=rf({},e.imports,i.imports,nf),l=Wx(o),u=Hx(o,l),d,p,v=0,S=e.interpolate||Hs,O="__p += '",k=RegExp((e.escape||Hs).source+"|"+S.source+"|"+(S===zx?Jx:Hs).source+"|"+(e.evaluate||Hs).source+"|$","g"),D=of.call(e,"sourceURL")?"//# sourceURL="+(e.s
34ourceURL+"").replace(/\s/g," ")+` 35`:"";r.replace(k,function(V,H,x,M,E,A){return x||(x=M),O+=r.slice(v,A).replace(ek,qx),H&&(d=!0,O+=`' + 36__e(`+H+`) + 37'`),E&&(p=!0,O+=`'; 38`+E+`; 39__p += '`),x&&(O+=`' + 40((__t = (`+x+`)) == null ? '' : __t) + 41'`),v=A+V.length,V}),O+=`'; 42`;var N=of.call(e,"variable")&&e.variable;if(!N)O=`with (obj) { 43`+O+` 44} 45`;else if(Zx.test(N))throw new Error(Gx);O=(p?O.replace(Xx,""):O).replace(Yx,"$1").replace(Qx,"$1;"),O="function("+(N||"obj")+`) { 46`+(N?"":`obj || (obj = {}); 47`)+"var __t, __p = ''"+(d?", __e = _.escape":"")+(p?`, __j = Array.prototype.join; 48function print() { __p += __j.call(arguments, '') } 49`:`; 50`)+O+`return __p 51}`;var B=Ux(function(){return Function(l,D+"return "+O).apply(void 0,u)});if(B.source=O,Vx(B))throw B;return B}var nk=rk;const El=So(nk);var ik=function(){function r(e,t){for(var i=0;i<t.length;i++){var o=t[i];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(e,t,i){return t&&r(e.prototype,t),i&&r(e,i),e}}(),sk=ok(["",""],["",""]);function ok(r,e){return Object.freeze(Object.defineProperties(r,{raw:{value:Object.freeze(e)}}))}function ak(r,e){if(!(r instanceof e))throw new TypeError("Cannot call a class as a function")}var Xe=function(){function r(){for(var e=this,t=arguments.length,i=Array(t),o=0;o<t;o++)i[o]=arguments[o];return ak(this,r),this.tag=function(l){for(var u=arguments.length,d=Array(u>1?u-1:0),p=1;p<u;p++)d[p-1]=arguments[p];return typeof l=="function"?e.interimTag.bind(e,l):typeof l=="string"?e.transformEndResult(l):(l=l.map(e.transformString.bind(e)),e.transformEndResult(l.reduce(e.processSubstitutions.bind(e,d))))},i.length>0&&Array.isArray(i[0])&&(i=i[0]),this.transformers=i.map(function(l){return typeof l=="function"?l():l}),this.tag}return ik(r,[{key:"interimTag",value:function(t,i){for(var o=arguments.length,l=Array(o>2?o-2:0),u=2;u<o;u++)l[u-2]=arguments[u];return this.tag(sk,t.apply(void 0,[i].concat(l)))}},{key:"processSubstitutions",value:function(t,i,o){var l=this.transformSubstitution(t.shift(),i);return"".concat(i,l,o)}},{key:"transformString",value:function(t){var i=function(l,u){return u.onString?u.onString(l):l};return this.transformers.reduce(i,t)}},{key:"transformSubstitution",value:function(t,i){var o=function(u,d){return d.onSubstitution?d.onSubstitution(u,i):u};return this.transformers.reduce(o,t)}},{key:"transformEndResult",value:function(t){var i=function(l,u){return u.onEndResult?u.onEndResult(l):l};return this.transformers.reduce(i,t)}}]),r}(),Ye=function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"";return{onEndResult:function(i){if(e==="")return i.trim();if(e=e.toLowerCase(),e==="start"||e==="left")return i.replace(/^\s*/,"");if(e==="end"||e==="right")return i.replace(/\s*$/,"");throw new Error("Side not supported: "+e)}}};function lk(r){if(Array.isArray(r)){for(var e=0,t=Array(r.length);e<r.length;e++)t[e]=r[e];return t}else return Array.from(r)}var Er=function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"initial";return{onEndResult:function(i){if(e==="initial"){var o=i.match(/^[^\S\n]*(?=\S)/gm),l=o&&Math.min.apply(Math,lk(o.map(function(d){return d.length})));if(l){var u=new RegExp("^.{"+l+"}","gm");return i.replace(u,"")}return i}if(e==="all")return i.replace(/^[^\S\n]+/gm,"");throw new Error("Unknown type: "+e)}}},Un=function(e,t){return{onEndResult:function(o){if(e==null||t==null)throw new Error("replaceResultTransformer requires at least 2 arguments.");return o.replace(e,t)}}},pn=function(e,t){return{onSubstitution:function(o,l){if(e==null||t==null)throw new Error("replaceSubstitutionTransformer requires at least 2 arguments.");return o==null?o:o.toString().replace(e,t)}}},ck={separator:"",conjunction:"",serial:!1},Mt=function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:ck;return{onSubstitution:function(i,o){if(Array.isArray(i)){var l=i.length,u=e.separator,d=e.conjunction,p=e.serial,v=o.match(/(\n?[^\S\n]+)$/);if(v?i=i.join(u+v[1]):i=i.join(u+" "),d&&l>1){var S=i.lastIndexOf(u);i=i.slice(0,S)+(p?u:"")+" "+d+i.slice(S+1)}}return i}}},Up=function(e){return{onSubstitution:function(i,o){return typeof i=="string"&&i.includes(e)&&(i=i.split(e)),i}}},af=function(e){return e!=null&&!Number.isNaN(e)&&typeof e!="boolean"},uk=function(){return{onSubstitution:function(t){return Array.isArray(t)?t.filter(af):af(t)?t:""}}};new Xe(Mt({separator:","}),Er,Ye);new Xe(Mt({separator:",",conjunction:"and"}),Er,Ye);new Xe(Mt({separator:",",conjunction:"or"}),Er,Ye);var Hp=new Xe(Up(` 52`),uk,Mt,Er,Ye);new Xe(Up(` 53`),Mt,Er,Ye,pn(/&/g,"&"),pn(/</g,"<"),pn(/>/g,">"),pn(/"/g,"""),pn(/'/g,"'"),pn(/`/g,"`"));new Xe(Un(/(?:\n(?:\s*))+/g," "),Ye);new Xe(Un(/(?:\n\s*)/g,""),Ye);new Xe(Mt({separator:","}),Un(/(?:\s+)/g," "),Ye);new Xe(Mt({separator:",",conjunction:"or"}),Un(/(?:\s+)/g," "),Ye);new Xe(Mt({separator:",",conjunction:"and"}),Un(/(?:\s+)/g," "),Ye);new Xe(Mt,Er,Ye);new Xe(Mt,Un(/(?:\s+)/g," "),Ye);new Xe(Er,Ye);new Xe(Er("all"),Ye);function Sl(r){let e;return Array.isArray(r)?e=r.map(Sl):typeof r=="string"?e=r.split(/\s+/):e=[r],e.flat().filter(t=>![null,void 0,""].includes(t)).map(t=>`${t}`)}function qp(r,e=[],t=[]){const i=Sl(e).map(l=>`${r}--${l}`),o=Sl(t);return[r,...i,...o].join(" ")}const lf=/[-_]stroke[d]?$/;function hk(r="",{spritesheet:e=null,className:t=null,width:i=24,height:o=null}={}){var v;let l=e,u=r;e||([l,u]=r.split("/"));
53const d=`${((v=window.hopp)==null?void 0:v.icons)&&window.hopp.icons[l]||""}#${u}`,p=[];return(l.match(lf)||u.match(lf))&&p.push("stroke"),Hp` 54 <svg 55 class="${qp("Icon",p,t)}" 56 role="presentation" 57 width="${i}" 58 height="${o||i}" 59 > 60 <use xlink:href="${d}"></use> 61 </svg> 62 `}const Vp="get_user_callback",Al="user-state-changed",Tl="google-ad-slot-rendered",Ol="embed-allowed",Xs="dialog_opened",jp="dialog_closed",Ys="consent_updated",dk="consent_interacted",RF="turbo:render",cf="message",uf="content-item:appear",hf="content-item:disappear",Wp="pwa_install_initiated",fk=(r,e,t)=>{const i=r[e];return i?typeof i=="function"?i():Promise.resolve(i):new Promise((o,l)=>{(typeof queueMicrotask=="function"?queueMicrotask:setTimeout)(l.bind(null,new Error("Unknown variable dynamic import: "+e+(e.split("/").length!==t?". Note that variables only represent file names one level deep.":""))))})};var oo={exports:{}};/** 63 * @license 64 * Lodash <https://lodash.com/> 65 * Copyright OpenJS Foundation and other contributors <https://openjsf.org/> 66 * Released under MIT license <https://lodash.com/license> 67 * Based on Underscore.js 1.8.3 <http://underscorejs.org/LICENSE> 68 * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors 69 */oo.exports;(function(r,e){(function(){var t,i="4.17.21",o=200,l="Unsupported core-js use. Try https://npms.io/search?q=ponyfill.",u="Expected a function",d="Invalid `variable` option passed into `_.template`",p="__lodash_hash_undefined__",v=500,S="__lodash_placeholder__",O=1,k=2,D=4,N=1,B=2,V=1,H=2,x=4,M=8,E=16,A=32,L=64,$=128,q=256,W=512,Z=30,ce="...",Fe=800,Dt=16,Ne=1,Ro=2,_v=3,Tr=1/0,er=9007199254740991,wv=17976931348623157e292,zi=NaN,At=4294967295,yv=At-1,Ev=At>>>1,Sv=[["ary",$],["bind",V],["bindKey",H],["curry",M],["curryRight",E],["flip",W],["partial",A],["partialRight",L],["rearg",q]],Qr="[object Arguments]",Ki="[object Array]",Av="[object AsyncFunction]",qn="[object Boolean]",Vn="[object Date]",Tv="[object DOMException]",Gi="[object Error]",Xi="[object Function]",zc="[object GeneratorFunction]",vt="[object Map]",jn="[object Number]",Ov="[object Null]",$t="[object Object]",Kc="[object Promise]",Cv="[object Proxy]",Wn="[object RegExp]",bt="[object Set]",zn="[object String]",Yi="[object Symbol]",Iv="[object Undefined]",Kn="[object WeakMap]",Lv="[object WeakSet]",Gn="[object ArrayBuffer]",Zr="[object DataView]",Po="[object Float32Array]",xo="[object Float64Array]",ko="[object Int8Array]",Mo="[object Int16Array]",Do="[object Int32Array]",$o="[object Uint8Array]",Fo="[object Uint8ClampedArray]",No="[object Uint16Array]",Bo="[object Uint32Array]",Rv=/\b__p \+= '';/g,Pv=/\b(__p \+=) '' \+/g,xv=/(__e\(.*?\)|\b__t\)) \+\n'';/g,Gc=/&(?:amp|lt|gt|quot|#39);/g,Xc=/[&<>"']/g,kv=RegExp(Gc.source),Mv=RegExp(Xc.source),Dv=/<%-([\s\S]+?)%>/g,$v=/<%([\s\S]+?)%>/g,Yc=/<%=([\s\S]+?)%>/g,Fv=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Nv=/^\w*$/,Bv=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Uo=/[\\^$.*+?()[\]{}|]/g,Uv=RegExp(Uo.source),Ho=/^\s+/,Hv=/\s/,qv=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,Vv=/\{\n\/\* \[wrapped with (.+)\] \*/,jv=/,? & /,Wv=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,zv=/[()=,{}\[\]\/\s]/,Kv=/\\(\\)?/g,Gv=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,Qc=/\w*$/,Xv=/^[-+]0x[0-9a-f]+$/i,Yv=/^0b[01]+$/i,Qv=/^\[object .+?Constructor\]$/,Zv=/^0o[0-7]+$/i,Jv=/^(?:0|[1-9]\d*)$/,eb=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u01
vendor: 70,000 bytes, lines 69-88
697f]/g,Qi=/($^)/,tb=/['\n\r\u2028\u2029\\]/g,Zi="\\ud800-\\udfff",rb="\\u0300-\\u036f",nb="\\ufe20-\\ufe2f",ib="\\u20d0-\\u20ff",Zc=rb+nb+ib,Jc="\\u2700-\\u27bf",eu="a-z\\xdf-\\xf6\\xf8-\\xff",sb="\\xac\\xb1\\xd7\\xf7",ob="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",ab="\\u2000-\\u206f",lb=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",tu="A-Z\\xc0-\\xd6\\xd8-\\xde",ru="\\ufe0e\\ufe0f",nu=sb+ob+ab+lb,qo="['â]",cb="["+Zi+"]",iu="["+nu+"]",Ji="["+Zc+"]",su="\\d+",ub="["+Jc+"]",ou="["+eu+"]",au="[^"+Zi+nu+su+Jc+eu+tu+"]",Vo="\\ud83c[\\udffb-\\udfff]",hb="(?:"+Ji+"|"+Vo+")",lu="[^"+Zi+"]",jo="(?:\\ud83c[\\udde6-\\uddff]){2}",Wo="[\\ud800-\\udbff][\\udc00-\\udfff]",Jr="["+tu+"]",cu="\\u200d",uu="(?:"+ou+"|"+au+")",db="(?:"+Jr+"|"+au+")",hu="(?:"+qo+"(?:d|ll|m|re|s|t|ve))?",du="(?:"+qo+"(?:D|LL|M|RE|S|T|VE))?",fu=hb+"?",gu="["+ru+"]?",fb="(?:"+cu+"(?:"+[lu,jo,Wo].join("|")+")"+gu+fu+")*",gb="\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",pb="\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])",pu=gu+fu+fb,mb="(?:"+[ub,jo,Wo].join("|")+")"+pu,vb="(?:"+[lu+Ji+"?",Ji,jo,Wo,cb].join("|")+")",bb=RegExp(qo,"g"),_b=RegExp(Ji,"g"),zo=RegExp(Vo+"(?="+Vo+")|"+vb+pu,"g"),wb=RegExp([Jr+"?"+ou+"+"+hu+"(?="+[iu,Jr,"$"].join("|")+")",db+"+"+du+"(?="+[iu,Jr+uu,"$"].join("|")+")",Jr+"?"+uu+"+"+hu,Jr+"+"+du,pb,gb,su,mb].join("|"),"g"),yb=RegExp("["+cu+Zi+Zc+ru+"]"),Eb=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,Sb=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],Ab=-1,ye={};ye[Po]=ye[xo]=ye[ko]=ye[Mo]=ye[Do]=ye[$o]=ye[Fo]=ye[No]=ye[Bo]=!0,ye[Qr]=ye[Ki]=ye[Gn]=ye[qn]=ye[Zr]=ye[Vn]=ye[Gi]=ye[Xi]=ye[vt]=ye[jn]=ye[$t]=ye[Wn]=ye[bt]=ye[zn]=ye[Kn]=!1;var we={};we[Qr]=we[Ki]=we[Gn]=we[Zr]=we[qn]=we[Vn]=we[Po]=we[xo]=we[ko]=we[Mo]=we[Do]=we[vt]=we[jn]=we[$t]=we[Wn]=we[bt]=we[zn]=we[Yi]=we[$o]=we[Fo]=we[No]=we[Bo]=!0,we[Gi]=we[Xi]=we[Kn]=!1;var Tb={Ã:"A",Ã:"A",Ã:"A",Ã:"A",Ã:"A",à :"A",à :"a",á:"a",â:"a",ã:"a",ä:"a",Ã¥:"a",Ã:"C",ç:"c",Ã:"D",ð:"d",Ã:"E",Ã:"E",Ã:"E",Ã:"E",è:"e",é:"e",ê:"e",ë:"e",Ã:"I",Ã:"I",Ã:"I",Ã:"I",ì:"i",Ã:"i",î:"i",ï:"i",Ã:"N",ñ:"n",Ã:"O",Ã:"O",Ã:"O",Ã:"O",Ã:"O",Ã:"O",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",Ã:"U",Ã:"U",Ã:"U",Ã:"U",ù:"u",ú:"u",û:"u",ü:"u",Ã:"Y",ý:"y",ÿ:"y",Ã:"Ae",æ:"ae",Ã:"Th",þ:"th",Ã:"ss",Ä:"A",Ä:"A",Ä:"A",Ä:"a",Ä:"a",Ä :"a",Ä:"C",Ä:"C",Ä:"C",Ä:"C",Ä:"c",Ä:"c",Ä:"c",Ä:"c",Ä:"D",Ä:"D",Ä:"d",Ä:"d",Ä:"E",Ä:"E",Ä:"E",Ä:"E",Ä:"E",Ä:"e",Ä:"e",Ä:"e",Ä:"e",Ä:"e",Ä:"G",Ä:"G",Ä :"G",Ä¢:"G",Ä:"g",Ä:"g",Ä¡:"g",Ä£:"g",Ĥ:"H",Ħ:"H",Ä¥:"h",ħ:"h",Ĩ:"I",Ī:"I",Ĭ:"I",Ä®:"I",İ:"I",Ä©:"i",Ä«:"i",Ä:"i",į:"i",ı:"i",Ä´:"J",ĵ:"j",Ķ:"K",Ä·:"k",ĸ:"k",Ĺ:"L",Ä»:"L",Ľ:"L",Ä¿:"L",Å:"L",ĺ:"l",ļ:"l",ľ:"l",Å:"l",Å:"l",Å:"N",Å :"N",Å:"N",Å:"N",Å:"n",Å:"n",Å:"n",Å:"n",Å:"O",Å:"O",Å:"O",Å:"o",Å:"o",Å:"o",Å:"R",Å:"R",Å:"R",Å:"r",Å:"r",Å:"r",Å:"S",Å:"S",Å:"S",Å :"S",Å:"s",Å:"s",Å:"s",Å¡:"s",Å¢:"T",Ť:"T",Ŧ:"T",Å£:"t",Å¥:"t",ŧ:"t",Ũ:"U",Ū:"U",Ŭ:"U",Å®:"U",Ű:"U",Ų:"U",Å©:"u",Å«:"u",Å:"u",ů:"u",ű:"u",ų:"u",Å´:"W",ŵ:"w",Ŷ:"Y",Å·:"y",Ÿ:"Y",Ź:"Z",Å»:"Z",Ž:"Z",ź:"z",ż:"z",ž:"z",IJ:"IJ",ij:"ij",Å:"Oe",Å:"oe",Å:"'n",Å¿:"s"},Ob={"&":"&","<":"<",">":">",'"':""","'":"'"},Cb={"&":"&","<":"<",">":">",""":'"',"'":"'"},Ib={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},Lb=parseFloat,Rb=parseInt,mu=typeof Yt=="object"&&Yt&&Yt.Object===Object&&Yt,Pb=typeof self=="object"&&self&&self.Object===Object&&self,Me=mu||Pb||Function("return this")(),Ko=e&&!e.nodeType&&e,Or=Ko&&!0&&r&&!r.nodeType&&r,vu=Or&&Or.exports===Ko,Go=vu&&mu.process,st=function(){try{var _=Or&&Or.require&&Or.require("util").types;return _||Go&&Go.binding&&Go.binding("util")}catch{}}(),bu=st&&st.isArrayBuffer,_u=st&&st.isDate,wu=st&&st.isMap,yu=st&&st.isRegExp,Eu=st&&st.isSet,Su=st&&st.isTypedArray;function Qe(_,I,T){switch(T.length){case 0:return _.call(I);case 1:return _.call(I,T[0]);case 2:return _.call(I,T[0],T[1]);case 3:return _.call(I,T[0],T[1],T[2])}return _.apply(I,T)}function xb(_,I,T,j){for(var ee=-1,fe=_==null?0:_.length;++ee<fe;){var Re=_[ee];I(j,Re,T(Re),_)}return j}function ot(_,I){for(var T=-1,j=_==null?0:_.length;++T<j&&I(_[T],T,_)!==!1;);return _}function kb(_,I){for(var T=_==null?0:_.length;T--&&I(_[T],T,_)!==!1;);return _}function Au(_,I){for(var T=-1,j=_==null?0:_.length;++T<j;)if(!I(_[T],T,_))return!1;return!0}function tr(_,I){for(var T=-1,j=_==null?0:_.length,ee=0,fe=[];++T<j;){var Re=_[T];I(Re,T,_)&&(fe[ee++]=Re)}return fe}function es(_,I){var T=_==null?0:_.length;return!!T&&en(_,I,0)>-1}function Xo(_,I,T){for(var j=-1,ee=_==null?0:_.length;++j<ee;)if(T(I,_[j]))return!0;return!1}function Se(_,I){for(var T=-1,j=_==null?0:_.length,ee=Array(j);++T<j;)ee[T]=I(_[T],T,_);return ee}function rr(_,I){for(var T=-1,j=I.length,ee=_.length;++T<j;)_[ee+T]=I[T];return _}function Yo(_,I,T,j){var ee=-1,fe=_==null?0:_.length;for(j&&fe&&(T=_[++ee]);++ee<fe;)T=I(T,_[ee],ee,_);return T}function Mb(_,I,T,j){var ee=_==null?0:_.length;for(j&&ee&&(T=_[--ee]);ee--;)T=I(T,_[ee],ee,_);return T}function Qo(_,I){for(var T=-1,j=_==null?0:_.length;++T<j;)if(I(_[T],T,_))return!0;return!1}var Db=Zo("length");function $b(_){return _.split("")}function Fb(_){return _.match(Wv)||[]}function Tu(_,I,T){var j;return T(_,function(ee,fe,Re){if(I(ee,fe,Re))return j=fe,!1}),j}function ts(_,I,T,j){for(var ee=_.length,fe=T+(j?1:-1);j?fe--:++fe<ee;)if(I(_[fe],fe,_))return fe;return-1}function en(_,I,T){return I===I?Xb(_,I,T):ts(_,Ou,T)}function Nb(_,I,T,j){for(var ee=T-1,fe=_.length;++ee<fe;)if(j(_[ee],I))return ee;return-1}function Ou(_){return _!==_}function Cu(_,I){var T=_==null?0:_.length;return T?ea(_,I)/T:zi}function Zo(_){return function(I){return I==null?t:I[_]}}function Jo(_){return function(I){return _==null?t:_[I]}}function Iu(_,I,T,j,ee){return ee(_,function(fe,Re,_e){T=j?(j=!1,fe):I(T,fe,Re,_e)}),T}function Bb(_,I){var T=_.length;for(_.sort(I);T--;)_[T]=_[T].value;return _}function ea(_,I){for(var T,j=-1,ee=_.length;++j<ee;){var fe=I(_[j]);fe!==t&&(T=T===t?fe:T+fe)}return T}function ta(_,I){for(var T=-1,j=Array(_);++T<_;)j[T]=I(T);return j}function Ub(_,I){return Se(I,function(T){return[T,_[T]]})}function Lu(_){return _&&_.slice(0,ku(_)+1).replace(Ho,"")}function Ze(_){return function(I){return _(I)}}function ra(_,I){return Se(I,function(T){return _[T]})}function Xn(_,I){return _.has(I)}function Ru(_,I){for(var T=-1,j=_.length;++T<j&&en(I,_[T],0)>-1;);return T}function Pu(_,I){for(var T=_.length;T--&&en(I,_[T],0)>-1;);return T}function Hb(_,I){for(var T=_.length,j=0;T--;)_[T]===I&&++j;return j}var qb=Jo(Tb),Vb=Jo(Ob);function jb(_){return"\\"+Ib[_]}function Wb(_,I){return _==null?t:_[I]}function tn(_){return yb.test(_)}function zb(_){return Eb.test(_)}function Kb(_){for(var I,T=[];!(I=_.next()).done;)T.push(I.value);return T}function na(_){var I=-1,T=Array(_.size);return _.forEach(function(j,ee){T[++I]=[ee,j]}),T}function xu(_,I){return function(T){return _(I(T))}}function nr(_,I){for(var T=-1,j=_.length,ee=0,fe=[];++T<j;){var Re=_[T];(Re===I||Re===S)&&(_[T]=S,fe[ee++]=T)}return fe}function rs(_){var I=-1,T=Array(_.size);return _.forEach(function(j){T[++I]=j}),T}function Gb(_){var I=-1,T=Array(_.size);return _.forEach(function(j){T[++I]=[j,j]}),T}function Xb(_,I,T){for(var j=T-1,ee=_.length;++j<ee;)if(_[j]===I)return j;return-1}function Yb(_,I,T){for(var j=T+1;j--;)if(_[j]===I)return j;return j}function rn(_){return tn(_)?Zb(_):Db(_)}function _t(_){return tn(_)?Jb(_):$b(_)}function ku(_){for(var I=_.length;I--&&Hv.test(_.charAt(I)););return I}var Qb=Jo(Cb);function Zb(_){for(var I=zo.lastIndex=0;zo.test(_);)++I;return I}function Jb(_){return _.match(zo)||[]}function e_(_){return _.match(wb)||[]}var t_=function _(I){I=I==null?Me:nn.defaults(Me.Object(),I,nn.pick(Me,Sb));var T=I.Array,j=I.Date,ee=I.Error,fe=I.Function,Re=I.Math,_e=I.Object,ia=I.RegExp,r_=I.String,at=I.TypeError,ns=T.prototype,n_=fe.prototype,sn=_e.prototype,is=I["__core-js_shared__"],ss=n_.toString,pe=sn.hasOwnProperty,i_=0,Mu=function(){var n=/[^.]+$/.exec(is&&is.keys&&is.keys.IE_PROTO||"");return n?"Symbol(src)_1."+n:""}(),os=sn.toString,s_=ss.call(_e),o_=Me._,a_=ia("^"+ss.call(pe).replace(Uo,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),as=vu?I.Buffer:t,ir=I.Symbol,ls=I.Uint8Array,Du=as?as.allocUnsafe:t,cs=xu(_e.getPrototypeOf,_e),$u=_e.create,Fu=sn.propertyIsEnumerable,us=ns.splice,Nu=ir?ir.isConcatSpreadable:t,Yn=ir?ir.iterator:t,Cr=ir?ir.toStringTag:t,hs=function(){try{var n=xr(_e,"defineProperty");return n({},"",{}),n}catch{}}(),l_=I.clearTimeout!==Me.clearTimeout&&I.clearTimeout,c_=j&&j.now!==Me.Date.now&&j.now,u_=I.setTimeout!==Me.setTimeout&&I.setTimeout,ds=Re.ceil,fs=Re.floor,sa=_e.getOwnPropertySymbols,h_=as?as.isBuffer:t,Bu=I.isFinite,d_=ns.join,f_=xu(_e.keys,_e),Pe=Re.max,Be=Re.min,g_=j.now,p_=I.parseInt,Uu=Re.random,m_=ns.reverse,oa=xr(I,"DataView"),Qn=xr(I,"Map"),aa=xr(I,"Promise"),on=xr(I,"Set"),Zn=xr(I,"WeakMap"),Jn=xr(_e,"create"),gs=Zn&&new Zn,an={},v_=kr(oa),b_=kr(Qn),__=kr(aa),w_=kr(on),y_=kr(Zn),ps=ir?ir.prototype:t,ei=ps?ps.valueOf:t,Hu=ps?ps.toString:t;function f(n){if(Oe(n)&&!te(n)&&!(n instanceof oe)){if(n instanceof lt)return n;if(pe.call(n,"__wrapped__"))return qh(n)}return new lt(n)}var ln=function(){function n(){}return function(s){if(!Ae(s))return{};if($u)return $u(s);n.prototype=s;var a=new n;return n.prototype=t,a}}();function ms(){}function lt(n,s){this.__wrapped__=n,this.__actions__=[],this.__chain__=!!s,this.__index__=0,this.__values__=t}f.templateSettings={escape:Dv,evaluate:$v,interpolate:Yc,variable:"",imports:{_:f}},f.prototype=ms.prototype,f.prototype.constructor=f,lt.prototype=ln(ms.prototype),lt.prototype.constructor=lt;function oe(n){this.__wrapped__=n,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=At,this.__views__=[]}function E_(){var n=new oe(this.__wrapped__);return n.__actions__=je(this.__actions__),n.__dir__=this.__dir__,n.__filtered__=this.__filtered__,n.__iteratees__=je(this.__iteratees__),n.__takeCount__=this.__takeCount__,n.__views__=je(this.__views__),n}function S_(){if(this.__filtered__){var n=new oe(this);n.__dir__=-1,n.__filtered__=!0}else n=this.clone(),n.__dir__*=-1;return n}function A_(){var n=this.__wrapped__.value(),s=this.__dir__,a=te(n),c=s<0,h=a?n.length:0,g=$w(0,h,this.__views__),m=g.start,b=g.end,w=b-m,R=c?b:m-1,P=this.__iteratees__,F=P.length,U=0,z=Be(w,this.__takeCount__);if(!a||!c&&h==w&&z==w)return hh(n,this.__actions__);var X=[];e:for(;w--&&U<z;){R+=s;for(var ne=-1,Y=n[R];++ne<F;){var se=P[ne],ae=se.iteratee,tt=se.type,Ve=ae(Y);if(tt==Ro)Y=Ve;else if(!Ve){if(tt==Ne)continue e;break e}}X[U++]=Y}return X}oe.prototype=ln(ms.prototype),oe.prototype.constructor=oe;function Ir(n){var s=-1,a=n==null?0:n.length;for(this.clear();++s<a;){var c=n[s];this.set(c[0],c[1])}}function T_(){this.__data__=Jn?Jn(null):{},this.size=0}function O_(n){var s=this.has(n)&&delete this.__data__[n];return this.size-=s?1:0,s}function C_(n){var s=this.__data__;if(Jn){var a=s[n];return a===p?t:a}return pe.call(s,n)?s[n]:t}function I_(n){var s=this.__data__;return Jn?s[n]!==t:pe.call(s,n)}function L_(n,s){var a=this.__data__;return this.size+=this.has(n)?0:1,a[n]=Jn&&s===t?p:s,this}Ir.prototype.clear=T_,Ir.prototype.delete=O_,Ir.prototype.get=C_,Ir.prototype.has=I_,Ir.prototype.set=L_;function Ft(n){var s=-1,a=n==null?0:n.length;for(this.clear();++s<a;){var c=n[s];this.set(c[0],c[1])}}function R_(){this.__data__=[],this.size=0}function P_(n){var s=this.__data__,a=vs(s,n);if(a<0)return!1;var c=s.length-1;return a==c?s.pop():us.call(s,a,1),--this.size,!0}function x_(n){var s=this.__data__,a=vs(s,n);return a<0?t:s[a][1]}function k_(n){return vs(this.__data__,n)>-1}function M_(n,s){var a=this.__data__,c=vs(a,n);return c<0?(++this.size,a.push([n,s])):a[c][1]=s,this}Ft.prototype.clear=R_,Ft.prototype.delete=P_,Ft.prototype.get=x_,Ft.prototype.has=k_,Ft.prototype.set=M_;function Nt(n){var s=-1,a=n==null?0:n.length;for(this.clear();++s<a;){var c=n[s];this.set(c[0],c[1])}}function D_(){this.size=0,this.__data__={hash:new Ir,map:new(Qn||Ft),string:new Ir}}function $_(n){var s=Ls(this,n).delete(n);return this.size-=s?1:0,s}function F_(n){return Ls(this,n).get(n)}function N_(n){return Ls(this,n).has(n)}function B_(n,s){var a=Ls(this,n),c=a.size;return a.set(n,s),this.size+=a.size==c?0:1,this}Nt.prototype.clear=D_,Nt.prototype.delete=$_,Nt.prototype.get=F_,Nt.prototype.has=N_,Nt.prototype.set=B_;function Lr(n){var s=-1,a=n==null?0:n.length;for(this.__data__=new Nt;++s<a;)this.add(n[s])}function U_(n){return this.__data__.set(n,p),this}function H_(n){return this.__data__.has(n)}Lr.prototype.add=Lr.prototype.push=U_,Lr.prototype.has=H_;function wt(n){var s=this.__data__=new Ft(n);this.size=s.size}function q_(){this.__data__=new Ft,this.size=0}function V_(n){var s=this.__data__,a=s.delete(n);return this.size=s.size,a}function j_(n){return this.__data__.get(n)}function W_(n){return this.__data__.has(n)}function z_(n,s){var a=this.__data__;if(a instanceof Ft){var c=a.__data__;if(!Qn||c.length<o-1)return c.push([n,s]),this.size=++a.size,this;a=this.__data__=new Nt(c)}return a.set(n,s),this.size=a.size,this}wt.prototype.clear=q_,wt.prototype.delete=V_,wt.prototype.get=j_,wt.prototype.has=W_,wt.prototype.set=z_;function qu(n,s){var a=te(n),c=!a&&Mr(n),h=!a&&!c&&cr(n),g=!a&&!c&&!h&&dn(n),m=a||c||h||g,b=m?ta(n.length,r_):[],w=b.length;for(var R in n)(s||pe.call(n,R))&&!(m&&(R=="length"||h&&(R=="offset"||R=="parent")||g&&(R=="buffer"||R=="byteLength"||R=="byteOffset")||qt(R,w)))&&b.push(R);return b}function Vu(n){var s=n.length;return s?n[ba(0,s-1)]:t}function K_(n,s){return Rs(je(n),Rr(s,0,n.length))}function G_(n){return Rs(je(n))}function la(n,s,a){(a!==t&&!yt(n[s],a)||a===t&&!(s in n))&&Bt(n,s,a)}function ti(n,s,a){var c=n[s];(!(pe.call(n,s)&&yt(c,a))||a===t&&!(s in n))&&Bt(n,s,a)}function vs(n,s){for(var a=n.length;a--;)if(yt(n[a][0],s))return a;return-1}function X_(n,s,a,c){return sr(n,function(h,g,m){s(c,h,a(h),m)}),c}function ju(n,s){return n&&Ot(s,xe(s),n)}function Y_(n,s){return n&&Ot(s,ze(s),n)}function Bt(n,s,a){s=="__proto__"&&hs?hs(n,s,{configurable:!0,enumerable:!0,value:a,writable:!0}):n[s]=a}function ca(n,s){for(var a=-1,c=s.length,h=T(c),g=n==null;++a<c;)h[a]=g?t:Va(n,s[a]);return h}function Rr(n,s,a){return n===n&&(a!==t&&(n=n<=a?n:a),s!==t&&(n=n>=s?n:s)),n}function ct(n,s,a,c,h,g){var m,b=s&O,w=s&k,R=s&D;if(a&&(m=h?a(n,c,h,g):a(n)),m!==t)return m;if(!Ae(n))return n;var P=te(n);if(P){if(m=Nw(n),!b)return je(n,m)}else{var F=Ue(n),U=F==Xi||F==zc;if(cr(n))return gh(n,b);if(F==$t||F==Qr||U&&!h){if(m=w||U?{}:kh(n),!b)return w?Cw(n,Y_(m,n)):Ow(n,ju(m,n))}else{if(!we[F])return h?n:{};m=Bw(n,F,b)}}g||(g=new wt);var z=g.get(n);if(z)return z;g.set(n,m),ld(n)?n.forEach(function(Y){m.add(ct(Y,s,a,Y,n,g))}):od(n)&&n.forEach(function(Y,se){m.set(se,ct(Y,s,a,se,n,g))});var X=R?w?La:Ia:w?ze:xe,ne=P?t:X(n);return ot(ne||n,function(Y,se){ne&&(se=Y,Y=n[se]),ti(m,se,ct(Y,s,a,se,n,g))}),m}function Q_(n){var s=xe(n);return function(a){return Wu(a,n,s)}}function Wu(n,s,a){var c=a.length;if(n==null)return!c;for(n=_e(n);c--;){var h=a[c],g=s[h],m=n[h];if(m===t&&!(h in n)||!g(m))return!1}return!0}function zu(n,s,a){if(typeof n!="function")throw new at(u);return li(function(){n.apply(t,a)},s)}function ri(n,s,a,c){var h=-1,g=es,m=!0,b=n.length,w=[],R=s.length;if(!b)return w;a&&(s=Se(s,Ze(a))),c?(g=Xo,m=!1):s.length>=o&&(g=Xn,m=!1,s=new Lr(s));e:for(;++h<b;){var P=n[h],F=a==null?P:a(P);if(P=c||P!==0?P:0,m&&F===F){for(var U=R;U--;)if(s[U]===F)continue e;w.push(P)}else g(s,F,c)||w.push(P)}return w}var sr=_h(Tt),Ku=_h(ha,!0);function Z_(n,s){var a=!0;return sr(n,function(c,h,g){return a=!!s(c,h,g),a}),a}function bs(n,s,a){for(var c=-1,h=n.length;++c<h;){var g=n[c],m=s(g);if(m!=null&&(b===t?m===m&&!et(m):a(m,b)))var b=m,w=g}return w}function J_(n,s,a,c){var h=n.length;for(a=re(a),a<0&&(a=-a>h?0:h+a),c=c===t||c>h?h:re(c),c<0&&(c+=h),c=a>c?0:ud(c);a<c;)n[a++]=s;return n}function Gu(n,s){var a=[];return sr(n,function(c,h,g){s(c,h,g)&&a.push(c)}),a}function De(n,s,a,c,h){var g=-1,m=n.length;for(a||(a=Hw),h||(h=[]);++g<m;){var b=n[g];s>0&&a(b)?s>1?De(b,s-1,a,c,h):rr(h,b):c||(h[h.length]=b)}return h}var ua=wh(),Xu=wh(!0);function Tt(n,s){return n&&ua(n,s,xe)}function ha(n,s){return n&&Xu(n,s,xe)}function _s(n,s){return tr(s,function(a){return Vt(n[a])})}function Pr(n,s){s=ar(s,n);for(var a=0,c=s.length;n!=null&&a<c;)n=n[Ct(s[a++])];return a&&a==c?n:t}function Yu(n,s,a){var c=s(n);return te(n)?c:rr(c,a(n))}function He(n){return n==null?n===t?Iv:Ov:Cr&&Cr in _e(n)?Dw(n):Gw(n)}function da(n,s){return n>s}function ew(n,s){return n!=null&&pe.call(n,s)}function tw(n,s){return n!=null&&s in _e(n)}function rw(n,s,a){return n>=Be(s,a)&&n<Pe(s,a)}function fa(n,s,a){for(var c=a?Xo:es,h=n[0].length,g=n.length,m=g,b=T(g),w=1/0,R=[];m--;){var P=n[m];m&&s&&(P=Se(P,Ze(s))),w=Be(P.length,w),b[m]=!a&&(s||h>=120&&P.length>=120)?new Lr(m&&P):t}P=n[0];var F=-1,U=b[0];e:for(;++F<h&&R.length<w;){var z=P[F],X=s?s(z):z;if(z=a||z!==0?z:0,!(U?Xn(U,X):c(R,X,a))){for(m=g;--m;){var ne=b[m];if(!(ne?Xn(ne,X):c(n[m],X,a)))continue e}U&&U.push(X),R.push(z)}}return R}function nw(n,s,a,c){return Tt(n,function(h,g,m){s(c,a(h),g,m)}),c}function ni(n,s,a){s=ar(s,n),n=Fh(n,s);var c=n==null?n:n[Ct(ht(s))];return c==null?t:Qe(c,n,a)}function Qu(n){return Oe(n)&&He(n)==Qr}function iw(n){return Oe(n)&&He(n)==Gn}function sw(n){return Oe(n)&&He(n)==Vn}function ii(n,s,a,c,h){return n===s?!0:n==null||s==null||!Oe(n)&&!Oe(s)?n!==n&&s!==s:ow(n,s,a,c,ii,h)}function ow(n,s,a,c,h,g){var m=te(n),b=te(s),w=m?Ki:Ue(n),R=b?Ki:Ue(s);w=w==Qr?$t:w,R=R==Qr?$t:R;var P=w==$t,F=R==$t,U=w==R;if(U&&cr(n)){if(!cr(s))return!1;m=!0,P=!1}if(U&&!P)return g||(g=new wt),m||dn(n)?Rh(n,s,a,c,h,g):kw(n,s,w,a,c,h,g);if(!(a&N)){var z=P&&pe.call(n,"__wrapped__"),X=F&&pe.call(s,"__wrapped__");if(z||X){var ne=z?n.value():n,Y=X?s.value():s;return g||(g=new wt),h(ne,Y,a,c,g)}}return U?(g||(g=new wt),Mw(n,s,a,c,h,g)):!1}function aw(n){return Oe(n)&&Ue(n)==vt}function ga(n,s,a,c){var h=a.length,g=h,m=!c;if(n==null)return!g;for(n=_e(n);h--;){var b=a[h];if(m&&b[2]?b[1]!==n[b[0]]:!(b[0]in n))return!1}for(;++h<g;){b=a[h];var w=b[0],R=n[w],P=b[1];if(m&&b[2]){if(R===t&&!(w in n))return!1}else{var F=new wt;if(c)var U=c(R,P,w,n,s,F);if(!(U===t?ii(P,R,N|B,c,F):U))return!1}}return!0}function Zu(n){if(!Ae(n)||Vw(n))return!1;var s=Vt(n)?a_:Qv;return s.test(kr(n))}function lw(n){return Oe(n)&&He(n)==Wn}function cw(n){return Oe(n)&&Ue(n)==bt}function uw(n){return Oe(n)&&$s(n.length)&&!!ye[He(n)]}function Ju(n){return typeof n=="function"?n:n==null?Ke:typeof n=="object"?te(n)?rh(n[0],n[1]):th(n):yd(n)}function pa(n){if(!ai(n))return f_(n);var s=[];for(var a in _e(n))pe.call(n,a)&&a!="constructor"&&s.push(a);return s}function hw(n){if(!Ae(n))return Kw(n);var s=ai(n),a=[];for(var c in n)c=="constructor"&&(s||!pe.call(n,c))||a.push(c);return a}function ma(n,s){return n<s}function eh(n,s){var a=-1,c=We(n)?T(n.length):[];return sr(n,function(h,g,m){c[++a]=s(h,g,m)}),c}function th(n){var s=Pa(n);return s.length==1&&s[0][2]?Dh(s[0][0],s[0][1]):function(a){return a===n||ga(a,n,s)}}function rh(n,s){return ka(n)&&Mh(s)?Dh(Ct(n),s):function(a){var c=Va(a,n);return c===t&&c===s?ja(a,n):ii(s,c,N|B)}}function ws(n,s,a,c,h){n!==s&&ua(s,function(g,m){if(h||(h=new wt),Ae(g))dw(n,s,m,a,ws,c,h);else{var b=c?c(Da(n,m),g,m+"",n,s,h):t;b===t&&(b=g),la(n,m,b)}},ze)}function dw(n,s,a,c,h,g,m){var b=Da(n,a),w=Da(s,a),R=m.get(w);if(R){la(n,a,R);return}var P=g?g(b,w,a+"",n,s,m):t,F=P===t;if(F){var U=te(w),z=!U&&cr(w),X=!U&&!z&&dn(w);P=w,U||z||X?te(b)?P=b:Ce(b)?P=je(b):z?(F=!1,P=gh(w,!0)):X?(F=!1,P=ph(w,!0)):P=[]:ci(w)||Mr(w)?(P=b,Mr(b)?P=hd(b):(!Ae(b)||Vt(b))&&(P=kh(w))):F=!1}F&&(m.set(w,P),h(P,w,c,g,m),m.delete(w)),la(n,a,P)}function nh(n,s){var a=n.length;if(a)return s+=s<0?a:0,qt(s,a)?n[s]:t}function ih(n,s,a){s.length?s=Se(s,function(g){return te(g)?function(m){return Pr(m,g.length===1?g[0]:g)}:g}):s=[Ke];var c=-1;s=Se(s,Ze(G()));var h=eh(n,function(g,m,b){var w=Se(s,function(R){return R(g)});return{criteria:w,index:++c,value:g}});return Bb(h,function(g,m){return Tw(g,m,a)})}function fw(n,s){return sh(n,s,function(a,c){return ja(n,c)})}function sh(n,s,a){for(var c=-1,h=s.length,g={};++c<h;){var m=s[c],b=Pr(n,m);a(b,m)&&si(g,ar(m,n),b)}return g}function gw(n){return function(s){return Pr(s,n)}}function va(n,s,a,c){var h=c?Nb:en,g=-1,m=s.length,b=n;for(n===s&&(s=je(s)),a&&(b=Se(n,Ze(a)));++g<m;)for(var w=0,R=s[g],P=a?a(R):R;(w=h(b,P,w,c))>-1;)b!==n&&us.call(b,w,1),us.call(n,w,1);return n}function oh(n,s){for(var a=n?s.length:0,c=a-1;a--;){var h=s[a];if(a==c||h!==g){var g=h;qt(h)?us.call(n,h,1):ya(n,h)}}return n}function ba(n,s){return n+fs(Uu()*(s-n+1))}function pw(n,s,a,c){for(var h=-1,g=Pe(ds((s-n)/(a||1)),0),m=T(g);g--;)m[c?g:++h]=n,n+=a;return m}function _a(n,s){var a="";if(!n||s<1||s>er)return a;do s%2&&(a+=n),s=fs(s/2),s&&(n+=n);while(s);return a}function ie(n,s){return $a($h(n,s,Ke),n+"")}function mw(n){return Vu(fn(n))}function vw(n,s){var a=fn(n);return Rs(a,Rr(s,0,a.length))}function si(n,s,a,c){if(!Ae(n))return n;s=ar(s,n);for(var h=-1,g=s.length,m=g-1,b=n;b!=null&&++h<g;){var w=Ct(s[h]),R=a;if(w==="__proto__"||w==="constructor"||w==="prototype")return n;if(h!=m){var P=b[w];R=c?c(P,w,b):t,R===t&&(R=Ae(P)?P:qt(s[h+1])?[]:{})}ti(b,w,R),b=b[w]}return n}var ah=gs?function(n,s){return gs.set(n,s),n}:Ke,bw=hs?function(n,s){return hs(n,"toString",{configurable:!0,enumerable:!1,value:za(s),writable:!0})}:Ke;function _w(n){return Rs(fn(n))}function ut(n,s,a){var c=-1,h=n.length;s<0&&(s=-s>h?0:h+s),a=a>h?h:a,a<0&&(a+=h),h=s>a?0:a-s>>>0,s>>>=0;for(var g=T(h);++c<h;)g[c]=n[c+s];return g}function ww(n,s){var a;return sr(n,function(c,h,g){return a=s(c,h,g),!a}),!!a}function ys(n,s,a){var c=0,h=n==null?c:n.length;if(typeof s=="number"&&s===s&&h<=Ev){for(;c<h;){var g=c+h>>>1,m=n[g];m!==null&&!et(m)&&(a?m<=s:m<s)?c=g+1:h=g}return h}return wa(n,s,Ke,a)}function wa(n,s,a,c){var h=0,g=n==null?0:n.length;if(g===0)return 0;s=a(s);for(var m=s!==s,b=s===null,w=et(s),R=s===t;h<g;){var P=fs((h+g)/2),F=a(n[P]),U=F!==t,z=F===null,X=F===F,ne=et(F);if(m)var Y=c||X;else R?Y=X&&(c||U):b?Y=X&&U&&(c||!z):w?Y=X&&U&&!z&&(c||!ne):z||ne?Y=!1:Y=c?F<=s:F<s;Y?h=P+1:g=P}return Be(g,yv)}function lh(n,s){for(var a=-1,c=n.length,h=0,g=[];++a<c;){var m=n[a],b=s?s(m):m;if(!a||!yt(b,w)){var w=b;g[h++]=m===0?0:m}}return g}function ch(n){return typeof n=="number"?n:et(n)?zi:+n}function Je(n){if(typeof n=="string")return n;if(te(n))return Se(n,Je)+"";if(et(n))return Hu?Hu.call(n):"";var s=n+"";return s=="0"&&1/n==-Tr?"-0":s}function or(n,s,a){var c=-1,h=es,g=n.length,m=!0,b=[],w=b;if(a)m=!1,h=Xo;else if(g>=o){var R=s?null:Pw(n);if(R)return rs(R);m=!1,h=Xn,w=new Lr}else w=s?[]:b;e:for(;++c<g;){var P=n[c],F=s?s(P):P;if(P=a||P!==0?P:0,m&&F===F){for(var U=w.length;U--;)if(w[U]===F)continue e;s&&w.push(F),b.push(P)}else h(w,F,a)||(w!==b&&w.push(F),b.push(P))}return b}function ya(n,s){return s=ar(s,n),n=Fh(n,s),n==null||delete n[Ct(ht(s))]}function uh(n,s,a,c){return si(n,s,a(Pr(n,s)),c)}function Es(n,s,a,c){for(var h=n.length,g=c?h:-1;(c?g--:++g<h)&&s(n[g],g,n););return a?ut(n,c?0:g,c?g+1:h):ut(n,c?g+1:0,c?h:g)}function hh(n,s){var a=n;return a instanceof oe&&(a=a.value()),Yo(s,function(c,h){return h.func.apply(h.thisArg,rr([c],h.args))},a)}function Ea(n,s,a){var c=n.length;if(c<2)return c?or(n[0]):[];for(var h=-1,g=T(c);++h<c;)for(var m=n[h],b=-1;++b<c;)b!=h&&(g[h]=ri(g[h]||m,n[b],s,a));return or(De(g,1),s,a)}function dh(n,s,a){for(var c=-1,h=n.length,g=s.length,m={};++c<h;){var b=c<g?s[c]:t;a(m,n[c],b)}return m}function Sa(n){return Ce(n)?n:[]}function Aa(n){return typeof n=="function"?n:Ke}function ar(n,s){return te(n)?n:ka(n,s)?[n]:Hh(ge(n))}var yw=ie;function lr(n,s,a){var c=n.length;return a=a===t?c:a,!s&&a>=c?n:ut(n,s,a)}var fh=l_||function(n){return Me.clearTimeout(n)};function gh(n,s){if(s)return n.slice();var a=n.length,c=Du?Du(a):new n.constructor(a);return n.copy(c),c}function Ta(n){var s=new n.constructor(n.byteLength);return new ls(s).set(new ls(n)),s}function Ew(n,s){var a=s?Ta(n.buffer):n.buffer;return new n.constructor(a,n.byteOffset,n.byteLength)}function Sw(n){var s=new n.constructor(n.source,Qc.exec(n));return s.lastIndex=n.lastIndex,s}function Aw(n){return ei?_e(ei.call(n)):{}}function ph(n,s){var a=s?Ta(n.buffer):n.buffer;return new n.constructor(a,n.byteOffset,n.length)}function mh(n,s){if(n!==s){var a=n!==t,c=n===null,h=n===n,g=et(n),m=s!==t,b=s===null,w=s===s,R=et(s);if(!b&&!R&&!g&&n>s||g&&m&&w&&!b&&!R||c&&m&&w||!a&&w||!h)return 1;if(!c&&!g&&!R&&n<s||R&&a&&h&&!c&&!g||b&&a&&h||!m&&h||!w)return-1}return 0}function Tw(n,s,a){for(var c=-1,h=n.criteria,g=s.criteria,m=h.length,b=a.length;++c<m;){var w=mh(h[c],g[c]);if(w){if(c>=b)return w;var R=a[c];return w*(R=="desc"?-1:1)}}return n.index-s.index}function vh(n,s,a,c){for(var h=-1,g=n.length,m=a.length,b=-1,w=s.length,R=Pe(g-m,0),P=T(w+R),F=!c;++b<w;)P[b]=s[b];for(;++h<m;)(F||h<g)&&(P[a[h]]=n[h]);for(;R--;)P[b++]=n[h++];return P}function bh(n,s,a,c){for(var h=-1,g=n.length,m=-1,b=a.length,w=-1,R=s.length,P=Pe(g-b,0),F=T(P+R),U=!c;++h<P;)F[h]=n[h];for(var z=h;++w<R;)F[z+w]=s[w];for(;++m<b;)(U||h<g)&&(F[z+a[m]]=n[h++]);return F}function je(n,s){var a=-1,c=n.length;for(s||(s=T(c));++a<c;)s[a]=n[a];return s}function Ot(n,s,a,c){var h=!a;a||(a={});for(var g=-1,m=s.length;++g<m;){var b=s[g],w=c?c(a[b],n[b],b,a,n):t;w===t&&(w=n[b]),h?Bt(a,b,w):ti(a,b,w)}return a}function Ow(n,s){return Ot(n,xa(n),s)}function Cw(n,s){return Ot(n,Ph(n),s)}function Ss(n,s){return function(a,c){var h=te(a)?xb:X_,g=s?s():{};return h(a,n,G(c,2),g)}}function cn(n){return ie(function(s,a){var c=-1,h=a.length,g=h>1?a[h-1]:t,m=h>2?a[2]:t;for(g=n.length>3&&typeof g=="function"?(h--,g):t,m&&qe(a[0],a[1],m)&&(g=h<3?t:g,h=1),s=_e(s);++c<h;){var b=a[c];b&&n(s,b,c,g)}return s})}function _h(n,s){return function(a,c){if(a==null)return a;if(!We(a))return n(a,c);for(var h=a.length,g=s?h:-1,m=_e(a);(s?g--:++g<h)&&c(m[g],g,m)!==!1;);return a}}function wh(n){return function(s,a,c){for(var h=-1,g=_e(s),m=c(s),b=m.length;b--;){var w=m[n?b:++h];if(a(g[w],w,g)===!1)break}return s}}function Iw(n,s,a){var c=s&V,h=oi(n);function g(){var m=this&&this!==Me&&this instanceof g?h:n;return m.apply(c?a:this,arguments)}return g}function yh(n){return function(s){s=ge(s);var a=tn(s)?_t(s):t,c=a?a[0]:s.charAt(0),h=a?lr(a,1).join(""):s.slice(1);return c[n]()+h}}function un(n){return function(s){return Yo(_d(bd(s).replace(bb,"")),n,"")}}function oi(n){return function(){var s=arguments;switch(s.length){case 0:return new n;case 1:return new n(s[0]);case 2:return new n(s[0],s[1]);case 3:return new n(s[0],s[1],s[2]);case 4:return new n(s[0],s[1],s[2],s[3]);case 5:return new n(s[0],s[1],s[2],s[3],s[4]);case 6:return new n(s[0],s[1],s[2],s[3],s[4],s[5]);case 7:return new n(s[0],s[1],s[2],s[3],s[4],s[5],s[6])}var a=ln(n.prototype),c=n.apply(a,s);return Ae(c)?c:a}}function Lw(n,s,a){var c=oi(n);function h(){for(var g=arguments.length,m=T(g),b=g,w=hn(h);b--;)m[b]=arguments[b];var R=g<3&&m[0]!==w&&m[g-1]!==w?[]:nr(m,w);if(g-=R.length,g<a)return Oh(n,s,As,h.placeholder,t,m,R,t,t,a-g);var P=this&&this!==Me&&this instanceof h?c:n;return Qe(P,this,m)}return h}function Eh(n){return function(s,a,c){var h=_e(s);if(!We(s)){var g=G(a,3);s=xe(s),a=function(b){return g(h[b],b,h)}}var m=n(s,a,c);return m>-1?h[g?s[m]:m]:t}}function Sh(n){return Ht(function(s){var a=s.length,c=a,h=lt.prototype.thru;for(n&&s.reverse();c--;){var g=s[c];if(typeof g!="function")throw new at(u);if(h&&!m&&Is(g)=="wrapper")var m=new lt([],!0)}for(c=m?c:a;++c<a;){g=s[c];var b=Is(g),w=b=="wrapper"?Ra(g):t;w&&Ma(w[0])&&w[1]==($|M|A|q)&&!w[4].length&&w[9]==1?m=m[Is(w[0])].apply(m,w[3]):m=g.length==1&&Ma(g)?m[b]():m.thru(g)}return function(){var R=arguments,P=R[0];if(m&&R.length==1&&te(P))return m.plant(P).value();for(var F=0,U=a?s[F].apply(this,R):P;++F<a;)U=s[F].call(this,U);return U}})}function As(n,s,a,c,h,g,m,b,w,R){var P=s&$,F=s&V,U=s&H,z=s&(M|E),X=s&W,ne=U?t:oi(n);function Y(){for(var se=arguments.length,ae=T(se),tt=se;tt--;)ae[tt]=arguments[tt];if(z)var Ve=hn(Y),rt=Hb(ae,Ve);if(c&&(ae=vh(ae,c,h,z)),g&&(ae=bh(ae,g,m,z)),se-=rt,z&&se<R){var Ie=nr(ae,Ve);return Oh(n,s,As,Y.placeholder,a,ae,Ie,b,w,R-se)}var Et=F?a:this,Wt=U?Et[n]:n;return se=ae.length,b?ae=Xw(ae,b):X&&se>1&&ae.reverse(),P&&w<se&&(ae.length=w),this&&this!==Me&&this instanceof Y&&(Wt=ne||oi(Wt)),Wt.apply(Et,ae)}return Y}function Ah(n,s){return function(a,c){return nw(a,n,s(c),{})}}function Ts(n,s){return function(a,c){var h;if(a===t&&c===t)return s;if(a!==t&&(h=a),c!==t){if(h===t)return c;typeof a=="string"||typeof c=="string"?(a=Je(a),c=Je(c)):(a=ch(a),c=ch(c)),h=n(a,c)}return h}}function Oa(n){return Ht(function(s){return s=Se(s,Ze(G())),ie(function(a){var c=this;return n(s,function(h){return Qe(h,c,a)})})})}function Os(n,s){s=s===t?" ":Je(s);var a=s.length;if(a<2)return a?_a(s,n):s;var c=_a(s,ds(n/rn(s)));return tn(s)?lr(_t(c),0,n).join(""):c.slice(0,n)}function Rw(n,s,a,c){var h=s&V,g=oi(n);function m(){for(var b=-1,w=arguments.length,R=-1,P=c.length,F=T(P+w),U=this&&this!==Me&&this instanceof m?g:n;++R<P;)F[R]=c[R];for(;w--;)F[R++]=arguments[++b];return Qe(U,h?a:this,F)}return m}function Th(n){return function(s,a,c){return c&&typeof c!="number"&&qe(s,a,c)&&(a=c=t),s=jt(s),a===t?(a=s,s=0):a=jt(a),c=c===t?s<a?1:-1:jt(c),pw(s,a,c,n)}}function Cs(n){return function(s,a){return typeof s=="string"&&typeof a=="string"||(s=dt(s),a=dt(a)),n(s,a)}}function Oh(n,s,a,c,h,g,m,b,w,R){var P=s&M,F=P?m:t,U=P?t:m,z=P?g:t,X=P?t:g;s|=P?A:L,s&=~(P?L:A),s&x||(s&=~(V|H));var ne=[n,s,h,z,F,X,U,b,w,R],Y=a.apply(t,ne);return Ma(n)&&Nh(Y,ne),Y.placeholder=c,Bh(Y,n,s)}function Ca(n){var s=Re[n];return function(a,c){if(a=dt(a),c=c==null?0:Be(re(c),292),c&&Bu(a)){var h=(ge(a)+"e").split("e"),g=s(h[0]+"e"+(+h[1]+c));return h=(ge(g)+"e").split("e"),+(h[0]+"e"+(+h[1]-c))}return s(a)}}var Pw=on&&1/rs(new on([,-0]))[1]==Tr?function(n){return new on(n)}:Xa;function Ch(n){return function(s){var a=Ue(s);return a==vt?na(s):a==bt?Gb(s):Ub(s,n(s))}}function Ut(n,s,a,c,h,g,m,b){var w=s&H;if(!w&&typeof n!="function")throw new at(u);var R=c?c.length:0;if(R||(s&=~(A|L),c=h=t),m=m===t?m:Pe(re(m),0),b=b===t?b:re(b),R-=h?h.length:0,s&L){var P=c,F=h;c=h=t}var U=w?t:Ra(n),z=[n,s,a,c,h,P,F,g,m,b];if(U&&zw(z,U),n=z[0],s=z[1],a=z[2],c=z[3],h=z[4],b=z[9]=z[9]===t?w?0:n.length:Pe(z[9]-R,0),!b&&s&(M|E)&&(s&=~(M|E)),!s||s==V)var X=Iw(n,s,a);else s==M||s==E?X=Lw(n,s,b):(s==A||s==(V|A))&&!h.length?X=Rw(n,s,a,c):X=As.apply(t,z);var ne=U?ah:Nh;return Bh(ne(X,z),n,s)}function Ih(n,s,a,c){return n===t||yt(n,sn[a])&&!pe.call(c,a)?s:n}function Lh(n,s,a,c,h,g){return Ae(n)&&Ae(s)&&(g.set(s,n),ws(n,s,t,Lh,g),g.delete(s)),n}function xw(n){return ci(n)?t:n}function Rh(n,s,a,c,h,g){var m=a&N,b=n.length,w=s.length;if(b!=w&&!(m&&w>b))return!1;var R=g.get(n),P=g.get(s);if(R&&P)return R==s&&P==n;var F=-1,U=!0,z=a&B?new Lr:t;for(g.set(n,s),g.set(s,n);++F<b;){var X=n[F],ne=s[F];if(c)var Y=m?c(ne,X,F,s,n,g):c(X,ne,F,n,s,g);if(Y!==t){if(Y)continue;U=!1;break}if(z){if(!Qo(s,function(se,ae){if(!Xn(z,ae)&&(X===se||h(X,se,a,c,g)))return z.push(ae)})){U=!1;break}}else if(!(X===ne||h(X,ne,a,c,g))){U=!1;break}}return g.delete(n),g.delete(s),U}function kw(n,s,a,c,h,g,m){switch(a){case Zr:if(n.byteLength!=s.byteLength||n.byteOffset!=s.byteOffset)return!1;n=n.buffer,s=s.buffer;case Gn:return!(n.byteLength!=s.byteLength||!g(new ls(n),new ls(s)));case qn:case Vn:case jn:return yt(+n,+s);case Gi:return n.name==s.name&&n.message==s.message;case Wn:case zn:return n==s+"";case vt:var b=na;case bt:var w=c&N;if(b||(b=rs),n.size!=s.size&&!w)return!1;var R=m.get(n);if(R)return R==s;c|=B,m.set(n,s);var P=Rh(b(n),b(s),c,h,g,m);return m.delete(n),P;case Yi:if(ei)return ei.call(n)==ei.call(s)}return!1}function Mw(n,s,a,c,h,g){var m=a&N,b=Ia(n),w=b.length,R=Ia(s),P=R.length;if(w!=P&&!m)return!1;for(var F=w;F--;){var U=b[F];if(!(m?U in s:pe.call(s,U)))return!1}var z=g.get(n),X=g.get(s);if(z&&X)return z==s&&X==n;var ne=!0;g.set(n,s),g.set(s,n);for(var Y=m;++F<w;){U=b[F];var se=n[U],ae=s[U];if(c)var tt=m?c(ae,se,U,s,n,g):c(se,ae,U,n,s,g);if(!(tt===t?se===ae||h(se,ae,a,c,g):tt)){ne=!1;break}Y||(Y=U=="constructor")}if(ne&&!Y){var Ve=n.constructor,rt=s.constructor;Ve!=rt&&"constructor"in n&&"constructor"in s&&!(typeof Ve=="function"&&Ve instanceof Ve&&typeof rt=="function"&&rt instanceof rt)&&(ne=!1)}return g.delete(n),g.delete(s),ne}function Ht(n){return $a($h(n,t,Wh),n+"")}function Ia(n){return Yu(n,xe,xa)}function La(n){return Yu(n,ze,Ph)}var Ra=gs?function(n){return gs.get(n)}:Xa;function Is(n){for(var s=n.name+"",a=an[s],c=pe.call(an,s)?a.length:0;c--;){var h=a[c],g=h.func;if(g==null||g==n)return h.name}return s}function hn(n){var s=pe.call(f,"placeholder")?f:n;return s.placeholder}function G(){var n=f.iteratee||Ka;return n=n===Ka?Ju:n,arguments.length?n(arguments[0],arguments[1]):n}function Ls(n,s){var a=n.__data__;return qw(s)?a[typeof s=="string"?"string":"hash"]:a.map}function Pa(n){for(var s=xe(n),a=s.length;a--;){var c=s[a],h=n[c];s[a]=[c,h,Mh(h)]}return s}function xr(n,s){var a=Wb(n,s);return Zu(a)?a:t}function Dw(n){var s=pe.call(n,Cr),a=n[Cr];try{n[Cr]=t;var c=!0}catch{}var h=os.call(n);return c&&(s?n[Cr]=a:delete n[Cr]),h}var xa=sa?function(n){return n==null?[]:(n=_e(n),tr(sa(n),function(s){return Fu.call(n,s)}))}:Ya,Ph=sa?function(n){for(var s=[];n;)rr(s,xa(n)),n=cs(n);return s}:Ya,Ue=He;(oa&&Ue(new oa(new ArrayBuffer(1)))!=Zr||Qn&&Ue(new Qn)!=vt||aa&&Ue(aa.resolve())!=Kc||on&&Ue(new on)!=bt||Zn&&Ue(new Zn)!=Kn)&&(Ue=function(n){var s=He(n),a=s==$t?n.constructor:t,c=a?kr(a):"";if(c)switch(c){case v_:return Zr;case b_:return vt;case __:return Kc;case w_:return bt;case y_:return Kn}return s});function $w(n,s,a){for(var c=-1,h=a.length;++c<h;){var g=a[c],m=g.size;switch(g.type){case"drop":n+=m;break;case"dropRight":s-=m;break;case"take":s=Be(s,n+m);break;case"takeRight":n=Pe(n,s-m);break}}return{start:n,end:s}}function Fw(n){var s=n.match(Vv);return s?s[1].split(jv):[]}function xh(n,s,a){s=ar(s,n);for(var c=-1,h=s.length,g=!1;++c<h;){var m=Ct(s[c]);if(!(g=n!=null&&a(n,m)))break;n=n[m]}return g||++c!=h?g:(h=n==null?0:n.length,!!h&&$s(h)&&qt(m,h)&&(te(n)||Mr(n)))}function Nw(n){var s=n.length,a=new n.constructor(s);return s&&typeof n[0]=="string"&&pe.call(n,"index")&&(a.index=n.index,a.input=n.input),a}function kh(n){return typeof n.constructor=="function"&&!ai(n)?ln(cs(n)):{}}function Bw(n,s,a){var c=n.constructor;switch(s){case Gn:return Ta(n);case qn:case Vn:return new c(+n);case Zr:return Ew(n,a);case Po:case xo:case ko:case Mo:case Do:case $o:case Fo:case No:case Bo:return ph(n,a);case vt:return new c;case jn:case zn:return new c(n);case Wn:return Sw(n);case bt:return new c;case Yi:return Aw(n)}}function Uw(n,s){var a=s.length;if(!a)return n;var c=a-1;return s[c]=(a>1?"& ":"")+s[c],s=s.join(a>2?", ":" "),n.replace(qv,`{ 70/* [wrapped with `+s+`] */ 71`)}function Hw(n){return te(n)||Mr(n)||!!(Nu&&n&&n[Nu])}function qt(n,s){var a=typeof n;return s=s??er,!!s&&(a=="number"||a!="symbol"&&Jv.test(n))&&n>-1&&n%1==0&&n<s}function qe(n,s,a){if(!Ae(a))return!1;var c=typeof s;return(c=="number"?We(a)&&qt(s,a.length):c=="string"&&s in a)?yt(a[s],n):!1}function ka(n,s){if(te(n))return!1;var a=typeof n;return a=="number"||a=="symbol"||a=="boolean"||n==null||et(n)?!0:Nv.test(n)||!Fv.test(n)||s!=null&&n in _e(s)}function qw(n){var s=typeof n;return s=="string"||s=="number"||s=="symbol"||s=="boolean"?n!=="__proto__":n===null}function Ma(n){var s=Is(n),a=f[s];if(typeof a!="function"||!(s in oe.prototype))return!1;if(n===a)return!0;var c=Ra(a);return!!c&&n===c[0]}function Vw(n){return!!Mu&&Mu in n}var jw=is?Vt:Qa;function ai(n){var s=n&&n.constructor,a=typeof s=="function"&&s.prototype||sn;return n===a}function Mh(n){return n===n&&!Ae(n)}function Dh(n,s){return function(a){return a==null?!1:a[n]===s&&(s!==t||n in _e(a))}}function Ww(n){var s=Ms(n,function(c){return a.size===v&&a.clear(),c}),a=s.cache;return s}function zw(n,s){var a=n[1],c=s[1],h=a|c,g=h<(V|H|$),m=c==$&&a==M||c==$&&a==q&&n[7].length<=s[8]||c==($|q)&&s[7].length<=s[8]&&a==M;if(!(g||m))return n;c&V&&(n[2]=s[2],h|=a&V?0:x);var b=s[3];if(b){var w=n[3];n[3]=w?vh(w,b,s[4]):b,n[4]=w?nr(n[3],S):s[4]}return b=s[5],b&&(w=n[5],n[5]=w?bh(w,b,s[6]):b,n[6]=w?nr(n[5],S):s[6]),b=s[7],b&&(n[7]=b),c&$&&(n[8]=n[8]==null?s[8]:Be(n[8],s[8])),n[9]==null&&(n[9]=s[9]),n[0]=s[0],n[1]=h,n}function Kw(n){var s=[];if(n!=null)for(var a in _e(n))s.push(a);return s}function Gw(n){return os.call(n)}function $h(n,s,a){return s=Pe(s===t?n.length-1:s,0),function(){for(var c=arguments,h=-1,g=Pe(c.length-s,0),m=T(g);++h<g;)m[h]=c[s+h];h=-1;for(var b=T(s+1);++h<s;)b[h]=c[h];return b[s]=a(m),Qe(n,this,b)}}function Fh(n,s){return s.length<2?n:Pr(n,ut(s,0,-1))}function Xw(n,s){for(var a=n.length,c=Be(s.length,a),h=je(n);c--;){var g=s[c];n[c]=qt(g,a)?h[g]:t}return n}function Da(n,s){if(!(s==="constructor"&&typeof n[s]=="function")&&s!="__proto__")return n[s]}var Nh=Uh(ah),li=u_||function(n,s){return Me.setTimeout(n,s)},$a=Uh(bw);function Bh(n,s,a){var c=s+"";return $a(n,Uw(c,Yw(Fw(c),a)))}function Uh(n){var s=0,a=0;return function(){var c=g_(),h=Dt-(c-a);if(a=c,h>0){if(++s>=Fe)return arguments[0]}else s=0;return n.apply(t,arguments)}}function Rs(n,s){var a=-1,c=n.length,h=c-1;for(s=s===t?c:s;++a<s;){var g=ba(a,h),m=n[g];n[g]=n[a],n[a]=m}return n.length=s,n}var Hh=Ww(function(n){var s=[];return n.charCodeAt(0)===46&&s.push(""),n.replace(Bv,function(a,c,h,g){s.push(h?g.replace(Kv,"$1"):c||a)}),s});function Ct(n){if(typeof n=="string"||et(n))return n;var s=n+"";return s=="0"&&1/n==-Tr?"-0":s}function kr(n){if(n!=null){try{return ss.call(n)}catch{}try{return n+""}catch{}}return""}function Yw(n,s){return ot(Sv,function(a){var c="_."+a[0];s&a[1]&&!es(n,c)&&n.push(c)}),n.sort()}function qh(n){if(n instanceof oe)return n.clone();var s=new lt(n.__wrapped__,n.__chain__);return s.__actions__=je(n.__actions__),s.__index__=n.__index__,s.__values__=n.__values__,s}function Qw(n,s,a){(a?qe(n,s,a):s===t)?s=1:s=Pe(re(s),0);var c=n==null?0:n.length;if(!c||s<1)return[];for(var h=0,g=0,m=T(ds(c/s));h<c;)m[g++]=ut(n,h,h+=s);return m}function Zw(n){for(var s=-1,a=n==null?0:n.length,c=0,h=[];++s<a;){var g=n[s];g&&(h[c++]=g)}return h}function Jw(){var n=arguments.length;if(!n)return[];for(var s=T(n-1),a=arguments[0],c=n;c--;)s[c-1]=arguments[c];return rr(te(a)?je(a):[a],De(s,1))}var ey=ie(function(n,s){return Ce(n)?ri(n,De(s,1,Ce,!0)):[]}),ty=ie(function(n,s){var a=ht(s);return Ce(a)&&(a=t),Ce(n)?ri(n,De(s,1,Ce,!0),G(a,2)):[]}),ry=ie(function(n,s){var a=ht(s);return Ce(a)&&(a=t),Ce(n)?ri(n,De(s,1,Ce,!0),t,a):[]});function ny(n,s,a){var c=n==null?0:n.length;return c?(s=a||s===t?1:re(s),ut(n,s<0?0:s,c)):[]}function iy(n,s,a){var c=n==null?0:n.length;return c?(s=a||s===t?1:re(s),s=c-s,ut(n,0,s<0?0:s)):[]}function sy(n,s){return n&&n.length?Es(n,G(s,3),!0,!0):[]}function oy(n,s){return n&&n.length?Es(n,G(s,3),!0):[]}function ay(n,s,a,c){var h=n==null?0:n.length;return h?(a&&typeof a!="number"&&qe(n,s,a)&&(a=0,c=h),J_(n,s,a,c)):[]}function Vh(n,s,a){var c=n==null?0:n.length;if(!c)return-1;var h=a==null?0:re(a);return h<0&&(h=Pe(c+h,0)),ts(n,G(s,3),h)}function jh(n,s,a){var c=n==null?0:n.length;if(!c)return-1;var h=c-1;return a!==t&&(h=re(a),h=a<0?Pe(c+h,0):Be(h,c-1)),ts(n,G(s,3),h,!0)}function Wh(n){var s=n==null?0:n.length;return s?De(n,1):[]}function ly(n){var s=n==null?0:n.length;return s?De(n,Tr):[]}function cy(n,s){var a=n==null?0:n.length;return a?(s=s===t?1:re(s),De(n,s)):[]}function uy(n){for(var s=-1,a=n==null?0:n.length,c={};++s<a;){var h=n[s];c[h[0]]=h[1]}return c}function zh(n){return n&&n.length?n[0]:t}function hy(n,s,a){var c=n==null?0:n.length;if(!c)return-1;var h=a==null?0:re(a);return h<0&&(h=Pe(c+h,0)),en(n,s,h)}function dy(n){var s=n==null?0:n.length;return s?ut(n,0,-1):[]}var fy=ie(function(n){var s=Se(n,Sa);return s.length&&s[0]===n[0]?fa(s):[]}),gy=ie(function(n){var s=ht(n),a=Se(n,Sa);return s===ht(a)?s=t:a.pop(),a.length&&a[0]===n[0]?fa(a,G(s,2)):[]}),py=ie(function(n){var s=ht(n),a=Se(n,Sa);return s=typeof s=="function"?s:t,s&&a.pop(),a.length&&a[0]===n[0]?fa(a,t,s):[]});function my(n,s){return n==null?"":d_.call(n,s)}function ht(n){var s=n==null?0:n.length;return s?n[s-1]:t}function vy(n,s,a){var c=n==null?0:n.length;if(!c)return-1;var h=c;return a!==t&&(h=re(a),h=h<0?Pe(c+h,0):Be(h,c-1)),s===s?Yb(n,s,h):ts(n,Ou,h,!0)}function by(n,s){return n&&n.length?nh(n,re(s)):t}var _y=ie(Kh);function Kh(n,s){return n&&n.length&&s&&s.length?va(n,s):n}function wy(n,s,a){return n&&n.length&&s&&s.length?va(n,s,G(a,2)):n}function yy(n,s,a){return n&&n.length&&s&&s.length?va(n,s,t,a):n}var Ey=Ht(function(n,s){var a=n==null?0:n.length,c=ca(n,s);return oh(n,Se(s,function(h){return qt(h,a)?+h:h}).sort(mh)),c});function Sy(n,s){var a=[];if(!(n&&n.length))return a;var c=-1,h=[],g=n.length;for(s=G(s,3);++c<g;){var m=n[c];s(m,c,n)&&(a.push(m),h.push(c))}return oh(n,h),a}function Fa(n){return n==null?n:m_.call(n)}function Ay(n,s,a){var c=n==null?0:n.length;return c?(a&&typeof a!="number"&&qe(n,s,a)?(s=0,a=c):(s=s==null?0:re(s),a=a===t?c:re(a)),ut(n,s,a)):[]}function Ty(n,s){return ys(n,s)}function Oy(n,s,a){return wa(n,s,G(a,2))}function Cy(n,s){var a=n==null?0:n.length;if(a){var c=ys(n,s);if(c<a&&yt(n[c],s))return c}return-1}function Iy(n,s){return ys(n,s,!0)}function Ly(n,s,a){return wa(n,s,G(a,2),!0)}function Ry(n,s){var a=n==null?0:n.length;if(a){var c=ys(n,s,!0)-1;if(yt(n[c],s))return c}return-1}function Py(n){return n&&n.length?lh(n):[]}function xy(n,s){return n&&n.length?lh(n,G(s,2)):[]}function ky(n){var s=n==null?0:n.length;return s?ut(n,1,s):[]}function My(n,s,a){return n&&n.length?(s=a||s===t?1:re(s),ut(n,0,s<0?0:s)):[]}function Dy(n,s,a){var c=n==null?0:n.length;return c?(s=a||s===t?1:re(s),s=c-s,ut(n,s<0?0:s,c)):[]}function $y(n,s){return n&&n.length?Es(n,G(s,3),!1,!0):[]}function Fy(n,s){return n&&n.length?Es(n,G(s,3)):[]}var Ny=ie(function(n){return or(De(n,1,Ce,!0))}),By=ie(function(n){var s=ht(n);return Ce(s)&&(s=t),or(De(n,1,Ce,!0),G(s,2))}),Uy=ie(function(n){var s=ht(n);return s=typeof s=="function"?s:t,or(De(n,1,Ce,!0),t,s)});function Hy(n){return n&&n.length?or(n):[]}function qy(n,s){return n&&n.length?or(n,G(s,2)):[]}function Vy(n,s){return s=typeof s=="function"?s:t,n&&n.length?or(n,t,s):[]}function Na(n){if(!(n&&n.length))return[];var s=0;return n=tr(n,function(a){if(Ce(a))return s=Pe(a.length,s),!0}),ta(s,function(a){return Se(n,Zo(a))})}function Gh(n,s){if(!(n&&n.length))return[];var a=Na(n);return s==null?a:Se(a,function(c){return Qe(s,t,c)})}var jy=ie(function(n,s){return Ce(n)?ri(n,s):[]}),Wy=ie(function(n){return Ea(tr(n,Ce))}),zy=ie(function(n){var s=ht(n);return Ce(s)&&(s=t),Ea(tr(n,Ce),G(s,2))}),Ky=ie(function(n){var s=ht(n);return s=typeof s=="function"?s:t,Ea(tr(n,Ce),t,s)}),Gy=ie(Na);function Xy(n,s){return dh(n||[],s||[],ti)}function Yy(n,s){return dh(n||[],s||[],si)}var Qy=ie(function(n){var s=n.length,a=s>1?n[s-1]:t;return a=typeof a=="function"?(n.pop(),a):t,Gh(n,a)});function Xh(n){var s=f(n);return s.__chain__=!0,s}function Zy(n,s){return s(n),n}function Ps(n,s){return s(n)}var Jy=Ht(function(n){var s=n.length,a=s?n[0]:0,c=this.__wrapped__,h=function(g){return ca(g,n)};return s>1||this.__actions__.length||!(c instanceof oe)||!qt(a)?this.thru(h):(c=c.slice(a,+a+(s?1:0)),c.__actions__.push({func:Ps,args:[h],thisArg:t}),new lt(c,this.__chain__).thru(function(g){return s&&!g.length&&g.push(t),g}))});function eE(){return Xh(this)}function tE(){return new lt(this.value(),this.__chain__)}function rE(){this.__values__===t&&(this.__values__=cd(this.value()));var n=this.__index__>=this.__values__.length,s=n?t:this.__values__[this.__index__++];return{done:n,value:s}}function nE(){return this}function iE(n){for(var s,a=this;a instanceof ms;){var c=qh(a);c.__index__=0,c.__values__=t,s?h.__wrapped__=c:s=c;var h=c;a=a.__wrapped__}return h.__wrapped__=n,s}function sE(){var n=this.__wrapped__;if(n instanceof oe){var s=n;return this.__actions__.length&&(s=new oe(this)),s=s.reverse(),s.__actions__.push({func:Ps,args:[Fa],thisArg:t}),new lt(s,this.__chain__)}return this.thru(Fa)}function oE(){return hh(this.__wrapped__,this.__actions__)}var aE=Ss(function(n,s,a){pe.call(n,a)?++n[a]:Bt(n,a,1)});function lE(n,s,a){var c=te(n)?Au:Z_;return a&&qe(n,s,a)&&(s=t),c(n,G(s,3))}function cE(n,s){var a=te(n)?tr:Gu;return a(n,G(s,3))}var uE=Eh(Vh),hE=Eh(jh);function dE(n,s){return De(xs(n,s),1)}function fE(n,s){return De(xs(n,s),Tr)}function gE(n,s,a){return a=a===t?1:re(a),De(xs(n,s),a)}function Yh(n,s){var a=te(n)?ot:sr;return a(n,G(s,3))}function Qh(n,s){var a=te(n)?kb:Ku;return a(n,G(s,3))}var pE=Ss(function(n,s,a){pe.call(n,a)?n[a].push(s):Bt(n,a,[s])});function mE(n,s,a,c){n=We(n)?n:fn(n),a=a&&!c?re(a):0;var h=n.length;return a<0&&(a=Pe(h+a,0)),Fs(n)?a<=h&&n.indexOf(s,a)>-1:!!h&&en(n,s,a)>-1}var vE=ie(function(n,s,a){var c=-1,h=typeof s=="function",g=We(n)?T(n.length):[];return sr(n,function(m){g[++c]=h?Qe(s,m,a):ni(m,s,a)}),g}),bE=Ss(function(n,s,a){Bt(n,a,s)});function xs(n,s){var a=te(n)?Se:eh;return a(n,G(s,3))}function _E(n,s,a,c){return n==null?[]:(te(s)||(s=s==null?[]:[s]),a=c?t:a,te(a)||(a=a==null?[]:[a]),ih(n,s,a))}var wE=Ss(function(n,s,a){n[a?0:1].push(s)},function(){return[[],[]]});function yE(n,s,a){var c=te(n)?Yo:Iu,h=arguments.length<3;return c(n,G(s,4),a,h,sr)}function EE(n,s,a){var c=te(n)?Mb:Iu,h=arguments.length<3;return c(n,G(s,4),a,h,Ku)}function SE(n,s){var a=te(n)?tr:Gu;return a(n,Ds(G(s,3)))}function AE(n){var s=te(n)?Vu:mw;return s(n)}function TE(n,s,a){(a?qe(n,s,a):s===t)?s=1:s=re(s);var c=te(n)?K_:vw;return c(n,s)}function OE(n){var s=te(n)?G_:_w;return s(n)}function CE(n){if(n==null)return 0;if(We(n))return Fs(n)?rn(n):n.length;var s=Ue(n);return s==vt||s==bt?n.size:pa(n).length}function IE(n,s,a){var c=te(n)?Qo:ww;return a&&qe(n,s,a)&&(s=t),c(n,G(s,3))}var LE=ie(function(n,s){if(n==null)return[];var a=s.length;return a>1&&qe(n,s[0],s[1])?s=[]:a>2&&qe(s[0],s[1],s[2])&&(s=[s[0]]),ih(n,De(s,1),[])}),ks=c_||function(){return Me.Date.now()};function RE(n,s){if(typeof s!="function")throw new at(u);return n=re(n),function(){if(--n<1)return s.apply(this,arguments)}}function Zh(n,s,a){return s=a?t:s,s=n&&s==null?n.length:s,Ut(n,$,t,t,t,t,s)}function Jh(n,s){var a;if(typeof s!="function")throw new at(u);return n=re(n),function(){return--n>0&&(a=s.apply(this,arguments)),n<=1&&(s=t),a}}var Ba=ie(function(n,s,a){var c=V;if(a.length){var h=nr(a,hn(Ba));c|=A}return Ut(n,c,s,a,h)}),ed=ie(function(n,s,a){var c=V|H;if(a.length){var h=nr(a,hn(ed));c|=A}return Ut(s,c,n,a,h)});function td(n,s,a){s=a?t:s;var c=Ut(n,M,t,t,t,t,t,s);return c.placeholder=td.placeholder,c}function rd(n,s,a){s=a?t:s;var c=Ut(n,E,t,t,t,t,t,s);return c.placeholder=rd.placeholder,c}function nd(n,s,a){var c,h,g,m,b,w,R=0,P=!1,F=!1,U=!0;if(typeof n!="function")throw new at(u);s=dt(s)||0,Ae(a)&&(P=!!a.leading,F="maxWait"in a,g=F?Pe(dt(a.maxWait)||0,s):g,U="trailing"in a?!!a.trailing:U);function z(Ie){var Et=c,Wt=h;return c=h=t,R=Ie,m=n.apply(Wt,Et),m}function X(Ie){return R=Ie,b=li(se,s),P?z(Ie):m}function ne(Ie){var Et=Ie-w,Wt=Ie-R,Ed=s-Et;return F?Be(Ed,g-Wt):Ed}function Y(Ie){var Et=Ie-w,Wt=Ie-R;return w===t||Et>=s||Et<0||F&&Wt>=g}function se(){var Ie=ks();if(Y(Ie))return ae(Ie);b=li(se,ne(Ie))}function ae(Ie){return b=t,U&&c?z(Ie):(c=h=t,m)}function tt(){b!==t&&fh(b),R=0,c=w=h=b=t}function Ve(){return b===t?m:ae(ks())}function rt(){var Ie=ks(),Et=Y(Ie);if(c=arguments,h=this,w=Ie,Et){if(b===t)return X(w);if(F)return fh(b),b=li(se,s),z(w)}return b===t&&(b=li(se,s)),m}return rt.cancel=tt,rt.flush=Ve,rt}var PE=ie(function(n,s){return zu(n,1,s)}),xE=ie(function(n,s,a){return zu(n,dt(s)||0,a)});function kE(n){return Ut(n,W)}function Ms(n,s){if(typeof n!="function"||s!=null&&typeof s!="function")throw new at(u);var a=function(){var c=arguments,h=s?s.apply(this,c):c[0],g=a.cache;if(g.has(h))return g.get(h);var m=n.apply(this,c);return a.cache=g.set(h,m)||g,m};return a.cache=new(Ms.Cache||Nt),a}Ms.Cache=Nt;function Ds(n){if(typeof n!="function")throw new at(u);return function(){var s=arguments;switch(s.length){case 0:return!n.call(this);case 1:return!n.call(this,s[0]);case 2:return!n.call(this,s[0],s[1]);case 3:return!n.call(this,s[0],s[1],s[2])}return!n.apply(this,s)}}function ME(n){return Jh(2,n)}var DE=yw(function(n,s){s=s.length==1&&te(s[0])?Se(s[0],Ze(G())):Se(De(s,1),Ze(G()));var a=s.length;return ie(function(c){for(var h=-1,g=Be(c.length,a);++h<g;)c[h]=s[h].call(this,c[h]);return Qe(n,this,c)})}),Ua=ie(function(n,s){var a=nr(s,hn(Ua));return Ut(n,A,t,s,a)}),id=ie(function(n,s){var a=nr(s,hn(id));return Ut(n,L,t,s,a)}),$E=Ht(function(n,s){return Ut(n,q,t,t,t,s)});function FE(n,s){if(typeof n!="function")throw new at(u);return s=s===t?s:re(s),ie(n,s)}function NE(n,s){if(typeof n!="function")throw new at(u);return s=s==null?0:Pe(re(s),0),ie(function(a){var c=a[s],h=lr(a,0,s);return c&&rr(h,c),Qe(n,this,h)})}function BE(n,s,a){var c=!0,h=!0;if(typeof n!="function")throw new at(u);return Ae(a)&&(c="leading"in a?!!a.leading:c,h="trailing"in a?!!a.trailing:h),nd(n,s,{leading:c,maxWait:s,trailing:h})}function UE(n){return Zh(n,1)}function HE(n,s){return Ua(Aa(s),n)}function qE(){if(!arguments.length)return[];var n=arguments[0];return te(n)?n:[n]}function VE(n){return ct(n,D)}function jE(n,s){return s=typeof s=="function"?s:t,ct(n,D,s)}function WE(n){return ct(n,O|D)}function zE(n,s){return s=typeof s=="function"?s:t,ct(n,O|D,s)}function KE(n,s){return s==null||Wu(n,s,xe(s))}function yt(n,s){return n===s||n!==n&&s!==s}var GE=Cs(da),XE=Cs(function(n,s){return n>=s}),Mr=Qu(function(){return arguments}())?Qu:function(n){return Oe(n)&&pe.call(n,"callee")&&!Fu.call(n,"callee")},te=T.isArray,YE=bu?Ze(bu):iw;function We(n){return n!=null&&$s(n.length)&&!Vt(n)}function Ce(n){return Oe(n)&&We(n)}function QE(n){return n===!0||n===!1||Oe(n)&&He(n)==qn}var cr=h_||Qa,ZE=_u?Ze(_u):sw;function JE(n){return Oe(n)&&n.nodeType===1&&!ci(n)}function eS(n){if(n==null)return!0;if(We(n)&&(te(n)||typeof n=="string"||typeof n.splice=="function"||cr(n)||dn(n)||Mr(n)))return!n.length;var s=Ue(n);if(s==vt||s==bt)return!n.size;if(ai(n))return!pa(n).length;for(var a in n)if(pe.call(n,a))return!1;return!0}function tS(n,s){return ii(n,s)}function rS(n,s,a){a=typeof a=="function"?a:t;var c=a?a(n,s):t;return c===t?ii(n,s,t,a):!!c}function Ha(n){if(!Oe(n))return!1;var s=He(n);return s==Gi||s==Tv||typeof n.message=="string"&&typeof n.name=="string"&&!ci(n)}function nS(n){return typeof n=="number"&&Bu(n)}function Vt(n){if(!Ae(n))return!1;var s=He(n);return s==Xi||s==zc||s==Av||s==Cv}function sd(n){return typeof n=="number"&&n==re(n)}function $s(n){return typeof n=="number"&&n>-1&&n%1==0&&n<=er}function Ae(n){var s=typeof n;return n!=null&&(s=="object"||s=="function")}function Oe(n){return n!=null&&typeof n=="object"}var od=wu?Ze(wu):aw;function iS(n,s){return n===s||ga(n,s,Pa(s))}function sS(n,s,a){return a=typeof a=="function"?a:t,ga(n,s,Pa(s),a)}function oS(n){return ad(n)&&n!=+n}function aS(n){if(jw(n))throw new ee(l);return Zu(n)}function lS(n){return n===null}function cS(n){return n==null}function ad(n){return typeof n=="number"||Oe(n)&&He(n)==jn}function ci(n){if(!Oe(n)||He(n)!=$t)return!1;var s=cs(n);if(s===null)return!0;var a=pe.call(s,"constructor")&&s.constructor;return typeof a=="function"&&a instanceof a&&ss.call(a)==s_}var qa=yu?Ze(yu):lw;function uS(n){return sd(n)&&n>=-er&&n<=er}var ld=Eu?Ze(Eu):cw;function Fs(n){return typeof n=="string"||!te(n)&&Oe(n)&&He(n)==zn}function et(n){return typeof n=="symbol"||Oe(n)&&He(n)==Yi}var dn=Su?Ze(Su):uw;function hS(n){return n===t}function dS(n){return Oe(n)&&Ue(n)==Kn}function fS(n){return Oe(n)&&He(n)==Lv}var gS=Cs(ma),pS=Cs(function(n,s){return n<=s});function cd(n){if(!n)return[];if(We(n))return Fs(n)?_t(n):je(n);if(Yn&&n[Yn])return Kb(n[Yn]());var s=Ue(n),a=s==vt?na:s==bt?rs:fn;return a(n)}function jt(n){if(!n)return n===0?n:0;if(n=dt(n),n===Tr||n===-Tr){var s=n<0?-1:1;return s*wv}return n===n?n:0}function re(n){var s=jt(n),a=s%1;return s===s?a?s-a:s:0}function ud(n){return n?Rr(re(n),0,At):0}function dt(n){if(typeof n=="number")return n;if(et(n))return zi;if(Ae(n)){var s=typeof n.valueOf=="function"?n.valueOf():n;n=Ae(s)?s+"":s}if(typeof n!="string")return n===0?n:+n;n=Lu(n);var a=Yv.test(n);return a||Zv.test(n)?Rb(n.slice(2),a?2:8):Xv.test(n)?zi:+n}function hd(n){return Ot(n,ze(n))}function mS(n){return n?Rr(re(n),-er,er):n===0?n:0}function ge(n){return n==null?"":Je(n)}var vS=cn(function(n,s){if(ai(s)||We(s)){Ot(s,xe(s),n);return}for(var a in s)pe.call(s,a)&&ti(n,a,s[a])}),dd=cn(function(n,s){Ot(s,ze(s),n)}),Ns=cn(function(n,s,a,c){Ot(s,ze(s),n,c)}),bS=cn(function(n,s,a,c){Ot(s,xe(s),n,c)}),_S=Ht(ca);function wS(n,s){var a=ln(n);return s==null?a:ju(a,s)}var yS=ie(function(n,s){n=_e(n);var a=-1,c=s.length,h=c>2?s[2]:t;for(h&&qe(s[0],s[1],h)&&(c=1);++a<c;)for(var g=s[a],m=ze(g),b=-1,w=m.length;++b<w;){var R=m[b],P=n[R];(P===t||yt(P,sn[R])&&!pe.call(n,R))&&(n[R]=g[R])}return n}),ES=ie(function(n){return n.push(t,Lh),Qe(fd,t,n)});function SS(n,s){return Tu(n,G(s,3),Tt)}function AS(n,s){return Tu(n,G(s,3),ha)}function TS(n,s){return n==null?n:ua(n,G(s,3),ze)}function OS(n,s){return n==null?n:Xu(n,G(s,3),ze)}function CS(n,s){return n&&Tt(n,G(s,3))}function IS(n,s){return n&&ha(n,G(s,3))}function LS(n){return n==null?[]:_s(n,xe(n))}function RS(n){return n==null?[]:_s(n,ze(n))}function Va(n,s,a){var c=n==null?t:Pr(n,s);return c===t?a:c}function PS(n,s){return n!=null&&xh(n,s,ew)}function ja(n,s){return n!=null&&xh(n,s,tw)}var xS=Ah(function(n,s,a){s!=null&&typeof s.toString!="function"&&(s=os.call(s)),n[s]=a},za(Ke)),kS=Ah(function(n,s,a){s!=null&&typeof s.toString!="function"&&(s=os.call(s)),pe.call(n,s)?n[s].push(a):n[s]=[a]},G),MS=ie(ni);function xe(n){return We(n)?qu(n):pa(n)}function ze(n){return We(n)?qu(n,!0):hw(n)}function DS(n,s){var a={};return s=G(s,3),Tt(n,function(c,h,g){Bt(a,s(c,h,g),c)}),a}function $S(n,s){var a={};return s=G(s,3),Tt(n,function(c,h,g){Bt(a,h,s(c,h,g))}),a}var FS=cn(function(n,s,a){ws(n,s,a)}),fd=cn(function(n,s,a,c){ws(n,s,a,c)}),NS=Ht(function(n,s){var a={};if(n==null)return a;var c=!1;s=Se(s,function(g){return g=ar(g,n),c||(c=g.length>1),g}),Ot(n,La(n),a),c&&(a=ct(a,O|k|D,xw));for(var h=s.length;h--;)ya(a,s[h]);return a});function BS(n,s){return gd(n,Ds(G(s)))}var US=Ht(function(n,s){return n==null?{}:fw(n,s)});function gd(n,s){if(n==null)return{};var a=Se(La(n),function(c){return[c]});return s=G(s),sh(n,a,function(c,h){return s(c,h[0])})}function HS(n,s,a){s=ar(s,n);var c=-1,h=s.length;for(h||(h=1,n=t);++c<h;){var g=n==null?t:n[Ct(s[c])];g===t&&(c=h,g=a),n=Vt(g)?g.call(n):g}return n}function qS(n,s,a){return n==null?n:si(n,s,a)}function VS(n,s,a,c){return c=typeof c=="function"?c:t,n==null?n:si(n,s,a,c)}var pd=Ch(xe),md=Ch(ze);function jS(n,s,a){var c=te(n),h=c||cr(n)||dn(n);if(s=G(s,4),a==null){var g=n&&n.constructor;h?a=c?new g:[]:Ae(n)?a=Vt(g)?ln(cs(n)):{}:a={}}return(h?ot:Tt)(n,function(m,b,w){return s(a,m,b,w)}),a}function WS(n,s){return n==null?!0:ya(n,s)}function zS(n,s,a){return n==null?n:uh(n,s,Aa(a))}function KS(n,s,a,c){return c=typeof c=="function"?c:t,n==null?n:uh(n,s,Aa(a),c)}function fn(n){return n==null?[]:ra(n,xe(n))}function GS(n){return n==null?[]:ra(n,ze(n))}function XS(n,s,a){return a===t&&(a=s,s=t),a!==t&&(a=dt(a),a=a===a?a:0),s!==t&&(s=dt(s),s=s===s?s:0),Rr(dt(n),s,a)}function YS(n,s,a){return s=jt(s),a===t?(a=s,s=0):a=jt(a),n=dt(n),rw(n,s,a)}function QS(n,s,a){if(a&&typeof a!="boolean"&&qe(n,s,a)&&(s=a=t),a===t&&(typeof s=="boolean"?(a=s,s=t):typeof n=="boolean"&&(a=n,n=t)),n===t&&s===t?(n=0,s=1):(n=jt(n),s===t?(s=n,n=0):s=jt(s)),n>s){var c=n;n=s,s=c}if(a||n%1||s%1){var h=Uu();return Be(n+h*(s-n+Lb("1e-"+((h+"").length-1))),s)}return ba(n,s)}var ZS=un(function(n,s,a){return s=s.toLowerCase(),n+(a?vd(s):s)});function vd(n){return Wa(ge(n).toLowerCase())}function bd(n){return n=ge(n),n&&n.replace(eb,qb).replace(_b,"")}function JS(n,s,a){n=ge(n),s=Je(s);var c=n.length;a=a===t?c:Rr(re(a),0,c);var h=a;return a-=s.length,a>=0&&n.slice(a,h)==s}function eA(n){return n=ge(n),n&&Mv.test(n)?n.replace(Xc,Vb):n}function tA(n){return n=ge(n),n&&Uv.test(n)?n.replace(Uo,"\\$&"):n}var rA=un(function(n,s,a){return n+(a?"-":"")+s.toLowerCase()}),nA=un(function(n,s,a){return n+(a?" ":"")+s.toLowerCase()}),iA=yh("toLowerCase");function sA(n,s,a){n=ge(n),s=re(s);var c=s?rn(n):0;if(!s||c>=s)return n;var h=(s-c)/2;return Os(fs(h),a)+n+Os(ds(h),a)}function oA(n,s,a){n=ge(n),s=re(s);var c=s?rn(n):0;return s&&c<s?n+Os(s-c,a):n}function aA(n,s,a){n=ge(n),s=re(s);var c=s?rn(n):0;return s&&c<s?Os(s-c,a)+n:n}function lA(n,s,a){return a||s==null?s=0:s&&(s=+s),p_(ge(n).replace(Ho,""),s||0)}function cA(n,s,a){return(a?qe(n,s,a):s===t)?s=1:s=re(s),_a(ge(n),s)}function uA(){var n=arguments,s=ge(n[0]);return n.length<3?s:s.replace(n[1],n[2])}var hA=un(function(n,s,a){return n+(a?"_":"")+s.toLowerCase()});function dA(n,s,a){return a&&typeof a!="number"&&qe(n,s,a)&&(s=a=t),a=a===t?At:a>>>0,a?(n=ge(n),n&&(typeof s=="string"||s!=null&&!qa(s))&&(s=Je(s),!s&&tn(n))?lr(_t(n),0,a):n.split(s,a)):[]}var fA=un(function(n,s,a){return n+(a?" ":"")+Wa(s)});function gA(n,s,a){return n=ge(n),a=a==null?0:Rr(re(a),0,n.length),s=Je(s),n.slice(a,a+s.length)==s}function pA(n,s,a){var c=f.templateSettings;a&&qe(n,s,a)&&(s=t),n=ge(n),s=Ns({},s,c,Ih);var h=Ns({},s.imports,c.imports,Ih),g=xe(h),m=ra(h,g),b,w,R=0,P=s.interpolate||Qi,F="__p += '",U=ia((s.escape||Qi).source+"|"+P.source+"|"+(P===Yc?Gv:Qi).source+"|"+(s.evaluate||Qi).source+"|$","g"),z="//# sourceURL="+(pe.call(s,"sourceURL")?(s.sourceURL+"").replace(/\s/g," "):"lodash.templateSources["+ ++Ab+"]")+` 72`;n.replace(U,function(Y,se,ae,tt,Ve,rt){return ae||(ae=tt),F+=n.slice(R,rt).replace(tb,jb),se&&(b=!0,F+=`' + 73__e(`+se+`) + 74'`),Ve&&(w=!0,F+=`'; 75`+Ve+`; 76__p += '`),ae&&(F+=`' + 77((__t = (`+ae+`)) == null ? '' : __t) + 78'`),R=rt+Y.length,Y}),F+=`'; 79`;var X=pe.call(s,"variable")&&s.variable;if(!X)F=`with (obj) { 80`+F+` 81} 82`;else if(zv.test(X))throw new ee(d);F=(w?F.replace(Rv,""):F).replace(Pv,"$1").replace(xv,"$1;"),F="function("+(X||"obj")+`) { 83`+(X?"":`obj || (obj = {}); 84`)+"var __t, __p = ''"+(b?", __e = _.escape":"")+(w?`, __j = Array.prototype.join; 85function print() { __p += __j.call(arguments, '') } 86`:`; 87`)+F+`return __p 88}`;var ne=wd(function(){return fe(g,z+"return "+F).apply(t,m)});if(ne.source=F,Ha(ne))throw ne;return ne}function mA(n){return ge(n).toLowerCase()}function vA(n){return ge(n).toUpperCase()}function bA(n,s,a){if(n=ge(n),n&&(a||s===t))return Lu(n);if(!n||!(s=Je(s)))return n;var c=_t(n),h=_t(s),g=Ru(c,h),m=Pu(c,h)+1;return lr(c,g,m).join("")}function _A(n,s,a){if(n=ge(n),n&&(a||s===t))return n.slice(0,ku(n)+1);if(!n||!(s=Je(s)))return n;var c=_t(n),h=Pu(c,_t(s))+1;return lr(c,0,h).join("")}function wA(n,s,a){if(n=ge(n),n&&(a||s===t))return n.replace(Ho,"");if(!n||!(s=Je(s)))return n;var c=_t(n),h=Ru(c,_t(s));return lr(c,h).join("")}function yA(n,s){var a=Z,c=ce;if(Ae(s)){var h="separator"in s?s.separator:h;a="length"in s?re(s.length):a,c="omission"in s?Je(s.omission):c}n=ge(n);var g=n.length;if(tn(n)){var m=_t(n);g=m.length}if(a>=g)return n;var b=a-rn(c);if(b<1)return c;var w=m?lr(m,0,b).join(""):n.slice(0,b);if(h===t)return w+c;if(m&&(b+=w.length-b),qa(h)){if(n.slice(b).search(h)){var R,P=w;for(h.global||(h=ia(h.source,ge(Qc.exec(h))+"g")),h.lastIndex=0;R=h.exec(P);)var F=R.index;w=w.slice(0,F===t?b:F)}}else if(n.indexOf(Je(h),b)!=b){var U=w.lastIndexOf(h);U>-1&&(w=w.slice(0,U))}return w+c}function EA(n){return n=ge(n),n&&kv.test(n)?n.replace(Gc,Qb):n}var SA=un(function(n,s,a){return n+(a?" ":"")+s.toUpperCase()}),Wa=yh("toUpperCase");function _d(n,s,a){return n=ge(n),s=a?t:s,s===t?zb(n)?e_(n):Fb(n):n.match(s)||[]}var wd=ie(function(n,s){try{return Qe(n,t,s)}catch(a){return Ha(a)?a:new ee(a)}}),AA=Ht(function(n,s){return ot(s,function(a){a=Ct(a),Bt(n,a,Ba(n[a],n))}),n});function TA(n){var s=n==null?0:n.length,a=G();return n=s?Se(n,function(c){if(typeof c[1]!="function")throw new at(u);return[a(c[0]),c[1]]}):[],ie(function(c){for(var h=-1;++h<s;){var g=n[h];if(Qe(g[0],this,c))return Qe(g[1],this,c)}})}function OA(n){return Q_(ct(n,O))}function za(n){return function(){return n}}function CA(n,s){return n==null||n!==n?s:n}var IA=Sh(),LA=Sh(!0);function Ke(n){return n}function Ka(n){return Ju(typeof n=="function"?n:ct(n,O))}function RA(n){return th(ct(n,O))}function PA(n,s){return rh(n,ct(s,O))}var xA=ie(function(n,s){return function(a){return ni(a,n,s)}}),kA=ie(function(n,s){return function(a){return ni(n,a,s)}});function Ga(n,s,a){var c=xe(s),h=_s(s,c);a==null&&!(Ae(s)&&(h.length||!c.length))&&(a=s,s=n,n=this,h=_s(s,xe(s)));var g=!(Ae(a)&&"chain"in a)||!!a.chain,m=Vt(n);return ot(h,function(b){var w=s[b];n[b]=w,m&&(n.prototype[b]=function(){var R=this.__chain__;if(g||R){var P=n(this.__wrapped__),F=P.__actions__=je(this.__actions__);return F.push({func:w,args:arguments,thisArg:n}),P.__chain__=R,P}return w.apply(n,rr([this.value()],arguments))})}),n}function MA(){return Me._===this&&(Me._=o_),this}function Xa(){}function DA(n){return n=re(n),ie(function(s){return nh(s,n)})}var $A=Oa(Se),FA=Oa(Au),NA=Oa(Qo);function yd(n){return ka(n)?Zo(Ct(n)):gw(n)}function BA(n){return function(s){return n==null?t:Pr(n,s)}}var UA=Th(),HA=Th(!0);function Ya(){return[]}function Qa(){return!1}function qA(){return{}}function VA(){return""}function jA(){return!0}function WA(n,s){if(n=re(n),n<1||n>er)return[];var a=At,c=Be(n,At);s=G(s),n-=At;for(var h=ta(c,s);++a<n;)s(a);return h}function zA(n){return te(n)?Se(n,Ct):et(n)?[n]:je(Hh(ge(n)))}function KA(n){var s=++i_;return ge(n)+s}var GA=Ts(function(n,s){return n+s},0),XA=Ca("ceil"),YA=Ts(function(n,s){return n/s},1),QA=Ca("floor");function ZA(n){return n&&n.length?bs(n,Ke,da):t}function JA(n,s){return n&&n.length?bs(n,G(s,2),da):t}function eT(n){return Cu(n,Ke)}function tT(n,s){return Cu(n,G(s,2))}function rT(n){return n&&n.length?bs(n,Ke,ma):t}function nT(n,s){return n&&n.length?bs(n,G(s,2),ma):t}var iT=Ts(function(n,s){return n*s},1),sT=Ca("round"),oT=Ts(function(n,s){return n-s},0);function aT(n){return n&&n.length?ea(n,Ke):0}function lT(n,s){return n&&n.length?ea(n,G(s,2)):0}return f.after=RE,f.ary=Zh,f.assign=vS,f.assignIn=dd,f.assignInWith=Ns,f.assignWith=bS,f.at=_S,f.before=Jh,f.bind=Ba,f.bindAll=AA,f.bindKey=ed,f.castArray=qE,f.chain=Xh,f.chunk=Qw,f.compact=Zw,f.concat=Jw,f.cond=TA,f.conforms=OA,f.constant=za,f.countBy=aE,f.create=wS,f.curry=td,f.curryRight=rd,f.debounce=nd,f.defaults=yS,f.defaultsDeep=ES,f.defer=PE,f.delay=xE,f.difference=ey,f.differenceBy=ty,f.differenceWith=ry,f.drop=ny,f.dropRight=iy,f.dropRightWhile=sy,f.dropWhile=oy,f.fill=ay,f.filter=cE,f.flatMap=dE,f.flatMapDeep=fE,f.flatMapDepth=gE,f.flatten=Wh,f.flattenDeep=ly,f.flattenDepth=cy,f.flip=kE,f.flow=IA,f.flowRight=LA,f.fromPairs=uy,f.functions=LS,f.functionsIn=RS,f.groupBy=pE,f.initial=dy,f.intersection=fy,f.intersectionBy=gy,f.intersectionWith=py,f.invert=xS,f.invertBy=kS,f.invokeMap=vE,f.iteratee=Ka,f.keyBy=bE,f.keys=xe,f.keysIn=ze,f.map=xs,f.mapKeys=DS,f.mapValues=$S,f.matches=RA,f.matchesProperty=PA,f.memoize=Ms,f.merge=FS,f.mergeWith=fd,f.method=xA,f.methodOf=kA,f.mixin=Ga,f.negate=Ds,f.nthArg=DA,f.omit=NS,f.omitBy=BS,f.once=ME,f.orderBy=_E,f.over=$A,f.overArgs=DE,f.overEvery=FA,f.overSome=NA,f.partial=Ua,f.partialRight=id,f.partition=wE,f.pick=US,f.pickBy=gd,f.property=yd,f.propertyOf=BA,f.pull=_y,f.pullAll=Kh,f.pullAllBy=wy,f.pullAllWith=yy,f.pullAt=Ey,f.range=UA,f.rangeRight=HA,f.rearg=$E,f.reject=SE,f.remove=Sy,f.rest=FE,f.reverse=Fa,f.sampleSize=TE,f.set=qS,f.setWith=VS,f.shuffle=OE,f.slice=Ay,f.sortBy=LE,f.sortedUniq=Py,f.sortedUniqBy=xy,f.split=dA,f.spread=NE,f.tail=ky,f.take=My,f.takeRight=Dy,f.takeRightWhile=$y,f.takeWhile=Fy,f.tap=Zy,f.throttle=BE,f.thru=Ps,f.toArray=cd,f.toPairs=pd,f.toPairsIn=md,f.toPath=zA,f.toPlainObject=hd,f.transform=jS,f.unary=UE,f.union=Ny,f.unionBy=By,f.unionWith=Uy,f.uniq=Hy,f.uniqBy=qy,f.uniqWith=Vy,f.unset=WS,f.unzip=Na,f.unzipWith=Gh,f.update=zS,f.updateWith=KS,f.values=fn,f.valuesIn=GS,f.without=jy,f.words=_d,f.wrap=HE,f.xor=Wy,f.xorBy=zy,f.xorWith=Ky,f.zip=Gy,f.zipObject=Xy,f.zipObjectDeep=Yy,f.zipWith=Qy,f.entries=pd,f.entriesIn=md,f.extend=dd,f.extendWith=Ns,Ga(f,f),f.add=GA,f.attempt=wd,f.camelCase=ZS,f.capitalize=vd,f.ceil=XA,f.clamp=XS,f.clone=VE,f.cloneDeep=WE,f.cloneDeepWith=zE,f.cloneWith=jE,f.conformsTo=KE,f.deburr=bd,f.defaultTo=CA,f.divide=YA,f.endsWith=JS,f.eq=yt,f.escape=eA,f.escapeRegExp=tA,f.every=lE,f.find=uE,f.findIndex=Vh,f.findKey=SS,f.findLast=hE,f.findLastIndex=jh,f.findLastKey=AS,f.floor=QA,f.forEach=Yh,f.forEachRight=Qh,f.forIn=TS,f.forInRight=OS,f.forOwn=CS,f.forOwnRight=IS,f.get=Va,f.gt=GE,f.gte=XE,f.has=PS,f.hasIn=ja,f.head=zh,f.identity=Ke,f.includes=mE,f.indexOf=hy,f.inRange=YS,f.invoke=MS,f.isArguments=Mr,f.isArray=te,f.isArrayBuffer=YE,f.isArrayLike=We,f.isArrayLikeObject=Ce,f.isBoolean=QE,f.isBuffer=cr,f.isDate=ZE,f.isElement=JE,f.isEmpty=eS,f.isEqual=tS,f.isEqualWith=rS,f.isError=Ha,f.isFinite=nS,f.isFunction=Vt,f.isInteger=sd,f.isLength=$s,f.isMap=od,f.isMatch=iS,f.isMatchWith=sS,f.isNaN=oS,f.isNative=aS,f.isNil=cS,f.isNull=lS,f.isNumber=ad,f.isObject=Ae,f.isObjectLike=Oe,f.isPlainObject=ci,f.isRegExp=qa,f.isSafeInteger=uS,f.isSet=ld,f.isString=Fs,f.isSymbol=et,f.isTypedArray=dn,f.isUndefined=hS,f.isWeakMap=dS,f.isWeakSet=fS,f.join=my,f.kebabCase=rA,f.last=ht,f.lastIndexOf=vy,f.lowerCase=nA,f.lowerFirst=iA,f.lt=gS,f.lte=pS,f.max=ZA,f.maxBy=JA,f.mean=eT,f.meanBy=tT,f.min=rT,f.minBy=nT,f.stubArray=Ya,f.stubFalse=Qa,f.stubObject=qA,f.stubString=VA,f.stubTrue=jA,f.multiply=iT,f.nth=by,f.noConflict=MA,f.noop=Xa,f.now=ks,f.pad=sA,f.padEnd=oA,f.padStart=aA,f.parseInt=lA,f.random=QS,f.reduce=yE,f.reduceRight=EE,f.repeat=cA,f.replace=uA,f.result=HS,f.round=sT,f.runInContext=_,f.sample=AE,f.size=CE,f.snakeCase=hA,f.some=IE,f.sortedIndex=Ty,f.sortedIndexBy=Oy,f.sortedIndexOf=Cy,f.sortedLastIndex=Iy,f.sortedLastIndexBy=Ly,f.sortedLastIndexOf=Ry,f.startCase=fA,f.startsWith=gA,f.subtract=oT,f.sum=aT,f.sumBy=lT,f.template=pA,f.times=WA,f.toFinite=jt,f.toInteger=re,f.toLength=ud,f.toLower=mA,f.toNumber=dt,f.toSafeInteger=mS,f.toString=ge,f.toUpper=vA,f.trim=bA,f.trimEnd=_A,f.trimStart=wA,f.truncate=yA,f.unescape=EA,f.uniqueId=KA,f.upperCase=SA,f.upperFirst=Wa,f.each=Yh,f.eachRight=Qh,f.first=zh,Ga(f,function(){var n={};return Tt(f,function(s,a){pe.call(f.prototype,a)||(n[a]=s)}),n}(),{chain:!1}),f.VERSION=i,ot(["bind","bindKey","curry","curryRight","partial","partialRight"],function(n){f[n].placeholder=f}),ot(["drop","take"],function(n,s){oe.prototype[n]=function(a){a=a===t?1:Pe(re(a),0);var c=this.__filtered__&&!s?new oe(this):this.clone();return c.__filtered__?c.__takeCount__=Be(a,c.__takeCount__):c.__views__.push({size:Be(a,At),type:n+(c.__dir__<0?"Right":"")}),c},oe.prototype[n+"Right"]=function(a){return this.reverse()[n](a).reverse()}}),ot(["filter","map","takeWhile"],function(n,s){var a=s+1,c=a==Ne||a==_v;oe.prototype[n]=function(h){var g=this.clone();return g.__iteratees__.push({iteratee:G(h,3),type:a}),g.__filtered__=g.__filtered__||c,g}}),ot(["head","last"],function(n,s){var a="take"+(s?"Right":"");oe.prototype[n]=function(){return this[a](1).value()[0]}}),ot(["initial","tail"],function(n,s){var a="drop"+(s?"":"Right");oe.prototype[n]=function(){return this.__filtered__?new oe(this):this[a](1)}}),oe.prototype.compact=function(){return this.filter(Ke)},oe.prototype.find=function(n){return this.filter(n).head()},oe.prototype.findLast=function(n){return this.reverse().find(n)},oe.prototype.invokeMap=ie(function(n,s){return typeof n=="function"?new oe(this):this.map(function(a){return ni(a,n,s)})}),oe.prototype.reject=function(n){return this.filter(Ds(G(n)))},oe.prototype.slice=function(n,s){n=re(n);var a=this;return a.__filtered__&&(n>0||s<0)?new oe(a):(n<0?a=a.takeRight(-n):n&&(a=a.drop(n)),s!==t&&(s=re(s),a=s<0?a.dropRight(-s):a.take(s-n)),a)},oe.prototype.takeRightWhile=function(n){return this.reverse().takeWhile(n).reverse()},oe.prototype.toArray=function(){return this.take(At)},Tt(oe.prototype,function(n,s){var a=/^(?:filter|find|map|reject)|While$/.test(s),c=/^(?:head|last)$/.test(s),h=f[c?"take"+(s=="last"?"Right":""):s],g=c||/^find/.test(s);h&&(f.prototype[s]=function(){var m=this.__wrapped__,b=c?[1]:arguments,w=m instanceof oe,R=b[0],P=w||te(m),F=function(se){var ae=h.apply(f,rr([se],b));return c&&U?ae[0]:ae};P&&a&&typeof R=="function"&&R.length!=1&&(w=P=!1);var U=this.__chain__,z=!!this.__actions__.length,X=g&&!U,ne=w&&!z;if(!g&&P){m=ne?m:new oe(this);var Y=n.apply(m,b);return Y.__actions__.push({func:Ps,args:[F],thisArg:t}),new lt(Y,U)}return X&&ne?n.apply(this,b):(Y=this.thru(F),X?c?Y.value()[0]:Y.value():Y)})}),ot(["pop","push","shift","sort","splice","unshift"],function(n){var s=ns[n],a=/^(?:push|sort|unshift)$/.test(n)?"tap":"thru",c=/^(?:pop|shift)$/.test(n);f.prototype[n]=function(){var h=arguments;if(c&&!this.__chain__){var g=this.value();return s.apply(te(g)?g:[],h)}return this[a](function(m){return s.apply(te(m)?m:[],h)})}}),Tt(oe.prototype,function(n,s){var a=f[s];if(a){var c=a.name+"";pe.call(an,c)||(an[c]=[]),an[c].push({name:s,func:a})}}),an[As(t,H).name]=[{name:"wrapper",func:t}],oe.prototype.clone=E_,oe.prototype.reverse=S_,oe.prototype.value=A_,f.prototype.at=Jy,f.prototype.chain=eE,f.prototype.commit=tE,f.prototype.next=rE,f.prototype.plant=iE,f.prototype.reverse=sE,f.prototype.toJSON=f.prototype.valueOf=f.prototype.value=oE,f.prototype.first=f.prototype.head,Yn&&(f.prototype[Yn]=nE),f},nn=t_();Or?((Or.exports=nn)._=nn,Ko._=nn):Me._=nn}).call(Yt)}
88)(oo,oo.exports);var gk=oo.exports;const zp=".";let Ec,tl;async function pk(r){var e;if(!tl){const t=(await fk(Object.assign({
88"../config/locales/de.json":()=>nt(()=>import("./chunks/de.6ba98182.js"),[]),
88"../config/locales/en.json":()=>nt(()=>import("./chunks/en.82dda69b.js"),[]),
88"../config/locales/sv.json":()=>nt(()=>import("./chunks/sv.0be45d90.js"),[])}),`../config/locales/${r}.json`,4)).default,i=((e=window.hopp)==null?void 0:e.strings)||{};tl=gk.merge(t,i)}return tl}function mk(r,e){let t,i,o=r;for(t=0;t<e.length;t+=1)if(i=e[t],o=o[i],!o)return;return o}function vk(r,e=zp){let t;if(Array.isArray(r))t=r;else if(typeof r=="string")t=r.split(e);else return;return t}function bk(r){Ec=r}function _k(){return Ec}async function _i(r,e=void 0,{locale:t=Ec,pathSeparator:i=zp}={}){const o=await pk(t),l=vk(r,i);return mk(o,l)||e||l.join(i)}/*! 89 * dashify <https://github.com/jonschlinkert/dashify> 90 * 91 * Copyright (c) 2015-2017, Jon Schlinkert. 92 * Released under the MIT License. 93 */var wk=(r,e)=>{if(typeof r!="string")throw new TypeError("expected a string");return r.trim().replace(/([a-z])([A-Z])/g,"$1-$2").replace(/\W/g,t=>/[Ã-ž]/.test(t)?t:"-").replace(/^-+|-+$/g,"").replace(/-{2,}/g,t=>e&&e.condense?"-":t).toLowerCase()};const yk=So(wk);function rl(r,e){const t=yk(r.replace(/_/g,"-")).replace(/^(?:data-)?/,"data-");let i=e;return e===!0&&(i=t),[t,i]}function Ek(r={},e={}){const{data:t={}}=e,i=Object.keys(e).filter(p=>p.indexOf("data_")===0).map(p=>rl(p,e[p])),o=Object.keys(t).map(p=>rl(p,t[p])),l=Object.keys(r).map(p=>rl(p,r[p])),u=[...i,...o,...l].reduce((p,[v,S])=>{if(S==null)return p;const O=p[v]?[p[v],S].join(" "):S;return{...p,[v]:O}},{}),d=Object.entries(u).map(([p,v])=>v?`${p}="${v}"`:p).join(" ");return d?` ${d}`:""}function Si(r){let e="";const t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz",i=t.length;for(let o=0;o<r;o+=1)e+=t.charAt(Math.floor(Math.random()*i));return e}async function Sk({content:r="",label:e,variants:t,remember:i,rememberCookieName:o,rememberCookieExpires:l,autoOpen:u,skipAutoOpenForSubscriber:d,modal:p,onClose:v}={}){const S=`dialog-${Si(10)}`,O=await _i("dialog.close");v&&window.addEventListener(jp,D=>{D.detail.id===S&&setTimeout(()=>{v()},500)},{once:!0});const k=[t];return p===!1&&k.push("nonModal"),Hp` 94 <div 95 class="${qp("Dialog",k)}" 96 tabindex="-1" 97 role="dialog" 98 hidden 99 ${Ek({controller:"dialog",dialog_remember_value:i,dialog_remember_cookie_name_value:o,dialog_remember_cookie_expires_value:l,dialog_auto_open_value:u==null?void 0:u.toString(),dialog_skip_auto_open_for_subscriber_value:d,dialog_id_value:S,dialog_modal_value:p})} 100 aria-label="${e}" 101 > 102 <div class="Dialog-wrapper"> 103 <div class="Dialog-window"> 104 <button 105 type="button" 106 class="Dialog-closeButton" 107 title="${O}" 108 data-action="dialog#close" 109 > 110 <span class="Dialog-closeButtonLabel">${O}</span> 111 ${hk("default/close_stroke",{className:"Dialog-closeButtonIcon"})} 112 </button> 113 114 <div class="Dialog-content" role="document">${r}</div> 115 </div> 116 </div> 117 </div> 118 `}const Sc="https://plausible.io/api/event",Ac=200,Ak="https://plausible.io/api/event";class Kp{constructor(e={}){y(this,"domain");y(this,"endpoint");y(this,"debug");const{domain:t,endpoint:i=Ak,debug:o=!1}=e;if(!t)throw TypeError("default domain needs to be specicifed");this.domain=t,this.endpoint=i,this.debug=o,this.log("constructor",{domain:this.domain,endpoint:this.endpoint,debug:this.debug})}log(...e){this.debug&&console.log("[PlausibleEventTracker]",...e)}async trackEvent(e,t){const i={n:e,d:(t==null?void 0:t.domain)||this.domain,u:(t==null?void 0:t.url)||location.href,p:t==null?void 0:t.props,r:t==null?void 0:t.referrer,i:t==null?void 0:t.interactive};this.log("trackEvent",e,t),await fetch(this.endpoint,{method:"POST",headers:this.requestHeaders,body:JSON.stringify(i)}).catch(o=>{this.log("error during trackEvent"),console.error(o)}),this.log("finished trackEvent")}get requestHeaders(){if(this.debug)return{"X-Debug-Request":"true"}}}let Cl;var tg;const Tk=((tg=window.hopp)==null?void 0:tg.id)||"unknown";var rg,ng,ig,sg;(ng=(rg=window.hopp)==null?void 0:rg.tracking)!=null&&ng.adsPlausibleDomain&&(Cl=new Kp({endpoint:((sg=(ig=window.hopp)==null?void 0:ig.tracking)==null?void 0:sg.plausibleEndpoint)??Sc,domain:window.hopp.tracking.adsPlausibleDomain}));function df(r,e,t){Cl&&Cl.trackEvent(`${Tk}_${r}`,{interactive:t,props:e})}function Tc(r){return r?r.origin===window.location.origin:!1}var Ok=vp,Ck=Xr,Ik="Expected a function";function Lk(r,e,t){var i=!0,o=!0;if(typeof r!="function")throw new TypeError(Ik);return Ck(t)&&(i="leading"in t?!!t.leading:i,o="trailing"in t?!!t.trailing:o),Ok(r,e,{leading:i,maxWait:e,trailing:o})}var Rk=Lk;const Pk=So(Rk);function Gp(r,e,t){let i="";if(t){const o=new Date;o.setTime(o.getTime()+t*24*60*60*1e3),i=`; expires=${o.toGMTString()}`}document.cookie=`${r}=${e}${i}; path=/; SameSite=Strict`}function xk(r){const e=`${r}=`,t=document.cookie.split(";");for(let i=0;i<t.length;i+=1){let o=t[i];for(;o.charAt(0)===" ";)o=o.substring(1,o.length);if(o.indexOf(e)===0)return o.substring(e.length,o.length)}return null}function kk(r){Gp(r,"",-1)}const ft={set:Gp,get:xk,remove:kk}
118,Mk='button, [href], input, select, textarea, [tabindex]:not([tabindex="-1"])',Dk='[aria-hidden="true"], [hidden]';class fi extends Error{}fi.prototype.name="InvalidTokenError";function $k(r){return decodeURIComponent(atob(r).replace(/(.)/g,(e,t)=>{let i=t.charCodeAt(0).toString(16).toUpperCase();return i.length<2&&(i="0"+i),"%"+i}))}function Fk(r){let e=r.replace(/-/g,"+").replace(/_/g,"/");switch(e.length%4){case 0:break;case 2:e+="==";break;case 3:e+="=";break;default:throw new Error("base64 string is not of the correct length")}try{return $k(e)}catch{return atob(e)}}function Nk(r,e){if(typeof r!="string")throw new fi("Invalid token specified: must be a string");e||(e={});const t=e.header===!0?0:1,i=r.split(".")[t];if(typeof i!="string")throw new fi(`Invalid token specified: missing part #${t+1}`);let o;try{o=Fk(i)}catch(l){throw new fi(`Invalid token specified: invalid base64 for part #${t+1} (${l.message})`)}try{return JSON.parse(o)}catch(l){throw new fi(`Invalid token specified: invalid json for part #${t+1} (${l.message})`)}}var Bk={debug:()=>{},info:()=>{},warn:()=>{},error:()=>{}},Lt,Rt,ao=(r=>(r[r.NONE=0]="NONE",r[r.ERROR=1]="ERROR",r[r.WARN=2]="WARN",r[r.INFO=3]="INFO",r[r.DEBUG=4]="DEBUG",r))(ao||{});(r=>{function e(){Lt=3,Rt=Bk}r.reset=e;function t(o){if(!(0<=o&&o<=4))throw new Error("Invalid log level");Lt=o}r.setLevel=t;function i(o){Rt=o}r.setLogger=i})(ao||(ao={}));var ue=class It{constructor(e){this._name=e}debug(...e){Lt>=4&&Rt.debug(It._format(this._name,this._method),...e)}info(...e){Lt>=3&&Rt.info(It._format(this._name,this._method),...e)}warn(...e){Lt>=2&&Rt.warn(It._format(this._name,this._method),...e)}error(...e){Lt>=1&&Rt.error(It._format(this._name,this._method),...e)}throw(e){throw this.error(e),e}create(e){const t=Object.create(this);return t._method=e,t.debug("begin"),t}static createStatic(e,t){const i=new It(`${e}.${t}`);return i.debug("begin"),i}static _format(e,t){const i=`[${e}]`;return t?`${i} ${t}:`:i}static debug(e,...t){Lt>=4&&Rt.debug(It._format(e),...t)}static info(e,...t){Lt>=3&&Rt.info(It._format(e),...t)}static warn(e,...t){Lt>=2&&Rt.warn(It._format(e),...t)}static error(e,...t){Lt>=1&&Rt.error(It._format(e),...t)}};ao.reset();var Uk="10000000-1000-4000-8000-100000000000",ff=r=>btoa([...new Uint8Array(r)].map(e=>String.fromCharCode(e)).join("")),On=class gi{static _randomWord(){const e=new Uint32Array(1);return crypto.getRandomValues(e),e[0]}static generateUUIDv4(){return Uk.replace(/[018]/g,t=>(+t^gi._randomWord()&15>>+t/4).toString(16)).replace(/-/g,"")}static generateCodeVerifier(){return gi.generateUUIDv4()+gi.generateUUIDv4()+gi.generateUUIDv4()}static async generateCodeChallenge(e){if(!crypto.subtle)throw new Error("Crypto.subtle is available only in secure contexts (HTTPS).");try{const i=new TextEncoder().encode(e),o=await crypto.subtle.digest("SHA-256",i);return ff(o).replace(/\+/g,"-").replace(/\//g,"_").replace(/=+$/,"")}catch(t){throw ue.error("CryptoUtils.generateCodeChallenge",t),t}}static generateBasicAuth(e,t){const o=new TextEncoder().encode([e,t].join(":"));return ff(o)}},hr=class{constructor(e){this._name=e,this._logger=new ue(`Event('${this._name}')`),this._callbacks=[]}addHandler(e){return this._callbacks.push(e),()=>this.removeHandler(e)}removeHandler(e){const t=this._callbacks.lastIndexOf(e);t>=0&&this._callbacks.splice(t,1)}async raise(...e){this._logger.debug("raise:",...e);for(const t of this._callbacks)await t(...e)}},Il=class{static decode(r){try{return Nk(r)}catch(e){throw ue.error("JwtUtils.decode",e),e}}},gf=class{static center({...r}){var e,t,i;return r.width==null&&(r.width=(e=[800,720,600,480].find(o=>o<=window.outerWidth/1.618))!=null?e:360),(t=r.left)!=null||(r.left=Math.max(0,Math.round(window.screenX+(window.outerWidth-r.width)/2))),r.height!=null&&((i=r.top)!=null||(r.top=Math.max(0,Math.round(window.screenY+(window.outerHeight-r.height)/2)))),r}static serialize(r){return Object.entries(r).filter(([,e])=>e!=null).map(([e,t])=>`${e}=${typeof t!="boolean"?t:t?"yes":"no"}`).join(",")}},Zt=class Qs extends hr{constructor(){super(...arguments),this._logger=new ue(`Timer('${this._name}')`),this._timerHandle=null,this._expiration=0,this._callback=()=>{const e=this._expiration-Qs.getEpochTime();this._logger.debug("timer completes in",e),this._expiration<=Qs.getEpochTime()&&(this.cancel(),super.raise())}}static getEpochTime(){return Math.floor(Date.now()/1e3)}init(e){const t=this._logger.create("init");e=Math.max(Math.floor(e),1);const i=Qs.getEpochTime()+e;if(this.expiration===i&&this._timerHandle){t.debug("skipping since already initialized for expiration at",this.expiration);return}this.cancel(),t.debug("using duration",e),this._expiration=i;const o=Math.min(e,5);this._timerHandle=setInterval(this._callback,o*1e3)}get expiration(){return this._expiration}cancel(){this._logger.create("cancel"),this._timerHandle&&(clearInterval(this._timerHandle),this._timerHandle=null)}},Ll=class{static readParams(r,e="query"){if(!r)throw new TypeError("Invalid URL");const i=new URL(r,"http://127.0.0.1")[e==="fragment"?"hash":"search"];return new URLSearchParams(i.slice(1))}},Rl=";
118",zr=class extends Error{constructor(r,e){var t,i,o;if(super(r.error_description||r.error||""),this.form=e,this.name="ErrorResponse",!r.error)throw ue.error("ErrorResponse","No error passed"),new Error("No error passed");this.error=r.error,this.error_description=(t=r.error_description)!=null?t:null,this.error_uri=(i=r.error_uri)!=null?i:null,this.state=r.userState,this.session_state=(o=r.session_state)!=null?o:null,this.url_state=r.url_state}},Oc=class extends Error{constructor(r){super(r),this.name="ErrorTimeout"}},Hk=class{constructor(r){this._logger=new ue("AccessTokenEvents"),this._expiringTimer=new Zt("Access token expiring"),this._expiredTimer=new Zt("Access token expired"),this._expiringNotificationTimeInSeconds=r.expiringNotificationTimeInSeconds}load(r){const e=this._logger.create("load");if(r.access_token&&r.expires_in!==void 0){const t=r.expires_in;if(e.debug("access token present, remaining duration:",t),t>0){let o=t-this._expiringNotificationTimeInSeconds;o<=0&&(o=1),e.debug("registering expiring timer, raising in",o,"seconds"),this._expiringTimer.init(o)}else e.debug("canceling existing expiring timer because we're past expiration."),this._expiringTimer.cancel();const i=t+1;e.debug("registering expired timer, raising in",i,"seconds"),this._expiredTimer.init(i)}else this._expiringTimer.cancel(),this._expiredTimer.cancel()}unload(){this._logger.debug("unload: canceling existing access token timers"),this._expiringTimer.cancel(),this._expiredTimer.cancel()}addAccessTokenExpiring(r){return this._expiringTimer.addHandler(r)}removeAccessTokenExpiring(r){this._expiringTimer.removeHandler(r)}addAccessTokenExpired(r){return this._expiredTimer.addHandler(r)}removeAccessTokenExpired(r){this._expiredTimer.removeHandler(r)}},qk=class{constructor(r,e,t,i,o){this._callback=r,this._client_id=e,this._intervalInSeconds=i,this._stopOnError=o,this._logger=new ue("CheckSessionIFrame"),this._timer=null,this._session_state=null,this._message=u=>{u.origin===this._frame_origin&&u.source===this._frame.contentWindow&&(u.data==="error"?(this._logger.error("error message from check session op iframe"),this._stopOnError&&this.stop()):u.data==="changed"?(this._logger.debug("changed message from check session op iframe"),this.stop(),this._callback()):this._logger.debug(u.data+" message from check session op iframe"))};const l=new URL(t);this._frame_origin=l.origin,this._frame=window.document.createElement("iframe"),this._frame.style.visibility="hidden",this._frame.style.position="fixed",this._frame.style.left="-1000px",this._frame.style.top="0",this._frame.width="0",this._frame.height="0",this._frame.src=l.href}load(){return new Promise(r=>{this._frame.onload=()=>{r()},window.document.body.appendChild(this._frame),window.addEventListener("message",this._message,!1)})}start(r){if(this._session_state===r)return;this._logger.create("start"),this.stop(),this._session_state=r;const e=()=>{!this._frame.contentWindow||!this._session_state||this._frame.contentWindow.postMessage(this._client_id+" "+this._session_state,this._frame_origin)};e(),this._timer=setInterval(e,this._intervalInSeconds*1e3)}stop(){this._logger.create("stop"),this._session_state=null,this._timer&&(clearInterval(this._timer),this._timer=null)}},Xp=class{constructor(){this._logger=new ue("InMemoryWebStorage"),this._data={}}clear(){this._logger.create("clear"),this._data={}}getItem(r){return this._logger.create(`getItem('${r}')`),this._data[r]}setItem(r,e){this._logger.create(`setItem('${r}')`),this._data[r]=e}removeItem(r){this._logger.create(`removeItem('${r}')`),delete this._data[r]}get length(){return Object.getOwnPropertyNames(this._data).length}key(r){return Object.getOwnPropertyNames(this._data)[r]}},Cc=class{constructor(r=[],e=null,t={}){this._jwtHandler=e,this._extraHeaders=t,this._logger=new ue("JsonService"),this._contentTypes=[],this._contentTypes.push(...r,"application/json"),e&&this._contentTypes.push("application/jwt")}async fetchWithTimeout(r,e={}){const{timeoutInSeconds:t,...i}=e;if(!t)return await fetch(r,i);const o=new AbortController,l=setTimeout(()=>o.abort(),t*1e3);try{return await fetch(r,{...e,signal:o.signal})}catch(u){throw u instanceof DOMException&&u.name==="AbortError"?new Oc("Network timed out"):u}finally{clearTimeout(l)}}async getJson(r,{token:e,credentials:t}={}){const i=this._logger.create("getJson"),o={Accept:this._contentTypes.join(", ")};e&&(i.debug("token passed, setting Authorization header"),o.Authorization="Bearer "+e),this.appendExtraHeaders(o);let l;try{i.debug("url:",r),l=await this.fetchWithTimeout(r,{method:"GET",headers:o,credentials:t})}catch(p){throw i.error("Network Error"),p}i.debug("HTTP response received, status",l.status);const u=l.headers.get("Content-Type");if(u&&!this._contentTypes.find(p=>u.startsWith(p))&&i.throw(new Error(`Invalid response Content-Type: ${u??"undefined"}, from URL: ${r}`)),l.ok&&this._jwtHandler&&(u!=null&&u.startsWith("application/jwt")))return await this._jwtHandler(await l.text());let d;try{d=await l.json()}catch(p){throw i.error("Error parsing JSON response",p),l.ok?p:new Error(`${l.statusText} (${l.status})`)}if(!l.ok)throw i.error("Error from server:",d),d.error?new zr(d):new Error(`${l.statusText} (${l.status}): ${JSON.stringify(d)}`);return d}async postForm(r,{body:e,basicAuth:t,timeoutInSeconds:i,initCredentials:o}){const l=this._logger.create("postForm"),u={Accept:this._contentTypes.join(", "),"Content-Type":"application/x-www-form-urlencoded"};t!==void 0&&(u.Authorization="Basic "+t),this.appendExtraHeaders(u);let d;try{l.debug("url:",r),d=await this.fetchWithTimeout(r,{method:"POST",headers:u,body:e,timeoutInSeconds:i,credentials:o})}catch(O){throw l.error("Network error"),O}l.debug("HTTP response received, status",d.status);const p=d.headers.get("Content-Type");if(p&&!this._contentTypes.find(O=>p.startsWith(O)))throw new Error(`Invalid response Content-Type: ${p??"undefined"}, from URL: ${r}`);const v=await d.text();let S={};if(v)try{S=JSON.parse(v)}catch(O){throw l.error("Error parsing JSON response",O),d.ok?O:new Error(`${d.statusText} (${d.status})`)}if(!d.ok)throw l.error("Error from server:",S),S.error?new zr(S,e):new Error(`${d.statusText} (${d.status}): ${JSON.stringify(S)}`);return S}appendExtraHeaders(r){const e=this._logger.create("appendExtraHeaders"),t=Object.keys(this._extraHeaders),i=["authorization","accept","content-type"];t.length!==0&&t.forEach(o=>{if(i.includes(o.toLocaleLowerCase())){e.warn("Protected header could not be overridden",o,i);return}const l=typeof this._extraHeaders[o]=="function"?this._extraHeaders[o]():this._extraHeaders[o];l&&l!==""&&(r[o]=l)})}},Vk=class{constructor(r){this._settings=r,this._logger=new ue("MetadataService"),this._signingKeys=null,this._metadata=null,this._metadataUrl=this._settings.metadataUrl,this._jsonService=new Cc(["application/jwk-set+json"],null,this._settings.extraHeaders),this._settings.signingKeys&&(this._logger.debug("using signingKeys from settings"),this._signingKeys=this._settings.signingKeys),this._settings.metadata&&(this._logger.debug("using metadata from settings"),this._metadata=this._settings.metadata),this._settings.fetchRequestCredentials&&(this._logger.debug("using fetchRequestCredentials from settings"),this._fetchRequestCredentials=this._settings.fetchRequestCredentials)}resetSigningKeys(){this._signingKeys=null}async getMetadata(){const r=this._logger.create("getMetadata");if(this._metadata)return r.debug("using cached values"),this._metadata;if(!this._metadataUrl)throw r.throw(new Error("No authority or metadataUrl configured on settings")),null;r.debug("getting metadata from",this._metadataUrl);const e=await this._jsonService.getJson(this._metadataUrl,{credentials:this._fetchRequestCredentials});return r.debug("merging remote JSON with seed metadata"),this._metadata=Object.assign({},this._settings.metadataSeed,e),this._metadata}getIssuer(){return this._getMetadataProperty("issuer")}getAuthorizationEndpoint(){return this._getMetadataProperty("authorization_endpoint")}getUserInfoEndpoint(){return this._getMetadataProperty("userinfo_endpoint")}getTokenEndpoint(r=!0){return this._getMetadataProperty("token_endpoint",r)}getCheckSessionIframe(){return this._getMetadataProperty("check_session_iframe",!0)}getEndSessionEndpoint(){return this._getMetadataProperty("end_session_endpoint",!0)}getRevocationEndpoint(r=!0){return this._getMetadataProperty("revocation_endpoint",r)}getKeysEndpoint(r=!0){return this._getMetadataProperty("jwks_uri",r)}async _getMetadataProperty(r,e=!1){const t=this._logger.create(`_getMetadataProperty('${r}')`),i=await this.getMetadata();if(t.debug("resolved"),i[r]===void 0){if(e===!0){t.warn("Metadata does not contain optional property");return}t.throw(new Error("Metadata does not contain property "+r))}return i[r]}async getSigningKeys(){const r=this._logger.create("getSigningKeys");if(this._signingKeys)return r.debug("returning signingKeys from cache"),this._signingKeys;const e=await this.getKeysEndpoint(!1);r.debug("got jwks_uri",e);const t=await this._jsonService.getJson(e);if(r.debug("got key set",t),!Array.isArray(t.keys))throw r.throw(new Error("Missing keys on keyset")),null;return this._signingKeys=t.keys,this._signingKeys}},Ic=class{constructor({prefix:r="oidc.",store:e=localStorage}={}){this._logger=new ue("WebStorageStateStore"),this._store=e,this._prefix=r}async set(r,e){this._logger.create(`set('${r}')`),r=this._prefix+r,await this._store.setItem(r,e)}async get(r){return this._logger.create(`get('${r}')`),r=this._prefix+r,await this._store.getItem(r)}async remove(r){this._logger.create(`remove('${r}')`),r=this._prefix+r;const e=await this._store.getItem(r);return await this._store.removeItem(r),e}async getAllKeys(){this._logger.create("getAllKeys");const r=await this._store.length,e=[];for(let t=0;t<r;t++){const i=await this._store.key(t);i&&i.indexOf(this._prefix)===0&&e.push(i.substr(this._prefix.length))}return e}},jk="code",Wk="openid",zk="client_secret_post",Kk=60*15,Pl=class{constructor({authority:r,metadataUrl:e,metadata:t,signingKeys:i,metadataSeed:o,client_id:l,client_secret:u,response_type:d=jk,scope:p=Wk,redirect_uri:v,post_logout_redirect_uri:S,client_authentication:O=zk,prompt:k,display:D,max_age:N,ui_locales:B,acr_values:V,resource:H,response_mode:x,filterProtocolClaims:M=!0,loadUserInfo:E=!1,staleStateAgeInSeconds:A=Kk,mergeClaimsStrategy:L={array:"replace"},disablePKCE:$=!1,stateStore:q,revokeTokenAdditionalContentTypes:W,fetchRequestCredentials:Z,refreshTokenAllowedScope:ce,extraQueryParams:Fe={},extraTokenParams:Dt={},extraHeaders:Ne={}}){if(this.authority=r,e?this.metadataUrl=e:(this.metadataUrl=r,r&&(this.metadataUrl.endsWith("/")||(this.metadataUrl+="/"),this.metadataUrl+=".well-known/openid-configuration")),this.metadata=t,this.metadataSeed=o,this.signingKeys=i,this.client_id=l,this.client_secret=u,this.response_type=d,this.scope=p,this.redirect_uri=v,this.post_logout_redirect_uri=S,this.client_authentication=O,this.prompt=k,this.display=D,this.max_age=N,this.ui_locales=B,this.acr_values=V,this.resource=H,this.response_mode=x,this.filterProtocolClaims=M??!0,this.loadUserInfo=!!E,this.staleStateAgeInSeconds=A,this.mergeClaimsStrategy=L,this.disablePKCE=!!$,this.revokeTokenAdditionalContentTypes=W,this.fetchRequestCredentials=Z||"same-origin",q)this.stateStore=q;else{const Ro=typeof window<"u"?window.localStorage:new Xp;this.stateStore=new Ic({store:Ro})}this.refreshTokenAllowedScope=ce,this.extraQueryParams=Fe,this.extraTokenParams=Dt,this.extraHeaders=Ne}},Gk=class{constructor(r,e){this._settings=r,this._metadataService=e,this._logger=new ue("UserInfoService"),this._getClaimsFromJwt=async t=>{const i=this._logger.create("_getClaimsFromJwt");try{const o=Il.decode(t);return i.debug("JWT decoding successful"),o}catch(o){throw i.error("Error parsing JWT response"),o}},this._jsonService=new Cc(void 0,this._getClaimsFromJwt,this._settings.extraHeaders)}async getClaims(r){const e=this._logger.create("getClaims");r||this._logger.throw(new Error("No token passed"));const t=await this._metadataService.getUserInfoEndpoint();e.debug("got userinfo url",t);const i=await this._jsonService.getJson(t,{token:r,credentials:this._settings.fetchRequestCredentials});return e.debug("got claims",i),i}},Yp=class{constructor(r,e){this._settings=r,this._metadataService=e,this._logger=new ue("TokenClient"),this._jsonService=new Cc(this._settings.revokeTokenAdditionalContentTypes,null,this._settings.extraHeaders)}async exchangeCode({grant_type:r="authorization_code",redirect_uri:e=this._settings.redirect_uri,client_id:t=this._settings.client_id,client_secret:i=this._settings.client_secret,...o}){const l=this._logger.create("exchangeCode");t||l.throw(new Error("A client_id is required")),e||l.throw(new Error("A redirect_uri is required")),o.code||l.throw(new Error("A code is required"));const u=new URLSearchParams({grant_type:r,redirect_uri:e});for(const[S,O]of Object.entries(o))O!=null&&u.set(S,O);let d;switch(this._settings.client_authentication){case"client_secret_basic":if(!i)throw l.throw(new Error("A client_secret is required")),null;d=On.generateBasicAuth(t,i);break;case"client_secret_post":u.append("client_id",t),i&&u.append("client_secret",i);break}const p=await this._metadataService.getTokenEndpoint(!1);l.debug("got token endpoint");const v=await this._jsonService.postForm(p,{body:u,basicAuth:d,init
118Credentials:this._settings.fetchRequestCredentials});return l.debug("got response"),v}async exchangeCredentials({grant_type:r="password",client_id:e=this._settings.client_id,client_secret:t=this._settings.client_secret,scope:i=this._settings.scope,...o}){const l=this._logger.create("exchangeCredentials");e||l.throw(new Error("A client_id is required"));const u=new URLSearchParams({grant_type:r,scope:i});for(const[S,O]of Object.entries(o))O!=null&&u.set(S,O);let d;switch(this._settings.client_authentication){case"client_secret_basic":if(!t)throw l.throw(new Error("A client_secret is required")),null;d=On.generateBasicAuth(e,t);break;case"client_secret_post":u.append("client_id",e),t&&u.append("client_secret",t);break}const p=await this._metadataService.getTokenEndpoint(!1);l.debug("got token endpoint");const v=await this._jsonService.postForm(p,{body:u,basicAuth:d,initCredentials:this._settings.fetchRequestCredentials});return l.debug("got response"),v}async exchangeRefreshToken({grant_type:r="refresh_token",client_id:e=this._settings.client_id,client_secret:t=this._settings.client_secret,timeoutInSeconds:i,...o}){const l=this._logger.create("exchangeRefreshToken");e||l.throw(new Error("A client_id is required")),o.refresh_token||l.throw(new Error("A refresh_token is required"));const u=new URLSearchParams({grant_type:r});for(const[S,O]of Object.entries(o))Array.isArray(O)?O.forEach(k=>u.append(S,k)):O!=null&&u.set(S,O);let d;switch(this._settings.client_authentication){case"client_secret_basic":if(!t)throw l.throw(new Error("A client_secret is required")),null;d=On.generateBasicAuth(e,t);break;case"client_secret_post":u.append("client_id",e),t&&u.append("client_secret",t);break}const p=await this._metadataService.getTokenEndpoint(!1);l.debug("got token endpoint");const v=await this._jsonService.postForm(p,{body:u,basicAuth:d,timeoutInSeconds:i,initCredentials:this._settings.fetchRequestCredentials});return l.debug("got response"),v}async revoke(r){var e;const t=this._logger.create("revoke");r.token||t.throw(new Error("A token is required"));const i=await this._metadataService.getRevocationEndpoint(!1);t.debug(`got revocation endpoint, revoking ${(e=r.token_type_hint)!=null?e:"default token type"}`);const o=new URLSearchParams;for(const[l,u]of Object.entries(r))u!=null&&o.set(l,u);o.set("client_id",this._settings.client_id),this._settings.client_secret&&o.set("client_secret",this._settings.client_secret),await this._jsonService.postForm(i,{body:o}),t.debug("got response")}},Xk=class{constructor(r,e,t){this._settings=r,this._metadataService=e,this._claimsService=t,this._logger=new ue("ResponseValidator"),this._userInfoService=new Gk(this._settings,this._metadataService),this._tokenClient=new Yp(this._settings,this._metadataService)}async validateSigninResponse(r,e){const t=this._logger.create("validateSigninResponse");this._processSigninState(r,e),t.debug("state processed"),await this._processCode(r,e),t.debug("code processed"),r.isOpenId&&this._validateIdTokenAttributes(r),t.debug("tokens validated"),await this._processClaims(r,e==null?void 0:e.skipUserInfo,r.isOpenId),t.debug("claims processed")}async validateCredentialsResponse(r,e){const t=this._logger.create("validateCredentialsResponse");r.isOpenId&&r.id_token&&this._validateIdTokenAttributes(r),t.debug("tokens validated"),await this._processClaims(r,e,r.isOpenId),t.debug("claims processed")}async validateRefreshResponse(r,e){var t,i;const o=this._logger.create("validateRefreshResponse");r.userState=e.data,(t=r.session_state)!=null||(r.session_state=e.session_state),(i=r.scope)!=null||(r.scope=e.scope),r.isOpenId&&r.id_token&&(this._validateIdTokenAttributes(r,e.id_token),o.debug("ID Token validated")),r.id_token||(r.id_token=e.id_token,r.profile=e.profile);const l=r.isOpenId&&!!r.id_token;await this._processClaims(r,!1,l),o.debug("claims processed")}validateSignoutResponse(r,e){const t=this._logger.create("validateSignoutResponse");if(e.id!==r.state&&t.throw(new Error("State does not match")),t.debug("state validated"),r.userState=e.data,r.error)throw t.warn("Response was error",r.error),new zr(r)}_processSigninState(r,e){var t;const i=this._logger.create("_processSigninState");
118if(e.id!==r.state&&i.throw(new Error("State does not match")),e.client_id||i.throw(new Error("No client_id on state")),e.authority||i.throw(new Error("No authority on state")),this._settings.authority!==e.authority&&i.throw(new Error("authority mismatch on settings vs. signin state")),this._settings.client_id&&this._settings.client_id!==e.client_id&&i.throw(new Error("client_id mismatch on settings vs. signin state")),i.debug("state validated"),r.userState=e.data,r.url_state=e.url_state,(t=r.scope)!=null||(r.scope=e.scope),r.error)throw i.warn("Response was error",r.error),new zr(r);e.code_verifier&&!r.code&&i.throw(new Error("Expected code in response"))}async _processClaims(r,e=!1,t=!0){const i=this._logger.create("_processClaims");if(r.profile=this._claimsService.filterProtocolClaims(r.profile),e||!this._settings.loadUserInfo||!r.access_token){i.debug("not loading user info");return}i.debug("loading user info");const o=await this._userInfoService.getClaims(r.access_token);i.debug("user info claims received from user info endpoint"),t&&o.sub!==r.profile.sub&&i.throw(new Error("subject from UserInfo response does not match subject in ID Token")),r.profile=this._claimsService.mergeClaims(r.profile,this._claimsService.filterProtocolClaims(o)),i.debug("user info claims received, updated profile:",r.profile)}async _processCode(r,e){const t=this._logger.create("_processCode");if(r.code){t.debug("Validating code");const i=await this._tokenClient.exchangeCode({client_id:e.client_id,client_secret:e.client_secret,code:r.code,redirect_uri:e.redirect_uri,code_verifier:e.code_verifier,...e.extraTokenParams});Object.assign(r,i)}else t.debug("No code to process")}_validateIdTokenAttributes(r,e){var t;const i=this._logger.create("_validateIdTokenAttributes");i.debug("decoding ID Token JWT");const o=Il.decode((t=r.id_token)!=null?t:"");if(o.sub||i.throw(new Error("ID Token is missing a subject claim")),e){const l=Il.decode(e);o.sub!==l.sub&&i.throw(new Error("sub in id_token does not match current sub")),o.auth_time&&o.auth_time!==l.auth_time&&i.throw(new Error("auth_time in id_token does not match original auth_time")),o.azp&&o.azp!==l.azp&&i.throw(new Error("azp in id_token does not match original azp")),!o.azp&&l.azp&&i.throw(new Error("azp not in id_token, but present in original id_token"))}r.profile=o}},lo=class xl{constructor(e){this.id=e.id||On.generateUUIDv4(),this.data=e.data,e.created&&e.created>0?this.created=e.created:this.created=Zt.getEpochTime(),this.request_type=e.request_type,this.url_state=e.url_state}toStorageString(){return new ue("State").create("toStorageString"),JSON.stringify({id:this.id,data:this.data,created:this.created,request_type:this.request_type,url_state:this.url_state})}static fromStorageString(e){return ue.createStatic("State","fromStorageString"),Promise.resolve(new xl(JSON.parse(e)))}static async clearStaleState(e,t){const i=ue.createStatic("State","clearStaleState"),o=Zt.getEpochTime()-t,l=await e.getAllKeys();i.debug("got keys",l);for(let u=0;u<l.length;u++){const d=l[u],p=await e.get(d);let v=!1;if(p)try{const S=await xl.fromStorageString(p);i.debug("got item from key:",d,S.created),S.created<=o&&(v=!0)}catch(S){i.error("Error parsing state for key:",d,S),v=!0}else i.debug("no item in storage for key:",d),v=!0;v&&(i.debug("removed item for key:",d),e.remove(d))}}},Qp=class kl extends lo{constructor(e){super(e),this.code_verifier=e.code_verifier,this.code_challenge=e.code_challenge,this.authority=e.authority,this.client_id=e.client_id,this.redirect_uri=e.redirect_uri,this.scope=e.scope,this.client_secret=e.client_secret,this.extraTokenParams=e.extraTokenParams,this.response_mode=e.response_mode,this.skipUserInfo=e.skipUserInfo}static async create(e){const t=e.code_verifier===!0?On.generateCodeVerifier():e.code_verifier||void 0,i=t?await On.generateCodeChallenge(t):void 0;return new kl({...e,code_verifier:t,code_challenge:i})}toStorageString(){return new ue("SigninState").create("toStorageString"),JSON.stringify({id:this.id,data:this.data,created:this.created,request_type:this.request_type,url_state:this.url_state,code_verifier:this.code_verifier,authority:this.authority,client_id:this.client_id,redirect_uri:this.redirect_uri,scope:this.scope,client_secret:this.client_secret,extraTokenParams:this.extraTokenParams,response_mode:this.response_mode,skipUserInfo:this.skipUserInfo})}static fromStorageString(e){ue.createStatic("SigninState","fromStorageString");const t=JSON.parse(e);return kl.create(t)}},Zp=class Jp{constructor(e){this.url=e.url,this.state=e.state}static async create({url:e,authority:t,client_id:i,redirect_uri:o,response_type:l,scope:u,state_data:d,response_mode:p,request_type:v,client_secret:S,nonce:O,url_state:k,resource:D,skipUserInfo:N,extraQueryParams:B,extraTokenParams:V,disablePKCE:H,...x}){if(!e)throw this._logger.error("create: No url passed"),new Error("url");
118if(!i)throw this._logger.error("create: No client_id passed"),new Error("client_id");if(!o)throw this._logger.error("create: No redirect_uri passed"),new Error("redirect_uri");if(!l)throw this._logger.error("create: No response_type passed"),new Error("response_type");if(!u)throw this._logger.error("create: No scope passed"),new Error("scope");if(!t)throw this._logger.error("create: No authority passed"),new Error("authority");const M=await Qp.create({data:d,request_type:v,url_state:k,code_verifier:!H,client_id:i,authority:t,redirect_uri:o,response_mode:p,client_secret:S,scope:u,extraTokenParams:V,skipUserInfo:N}),E=new URL(e);E.searchParams.append("client_id",i),E.searchParams.append("redirect_uri",o),E.searchParams.append("response_type",l),E.searchParams.append("scope",u),O&&E.searchParams.append("nonce",O);let A=M.id;k&&(A=`${A}${Rl}${k}`),E.searchParams.append("state",A),M.code_challenge&&(E.searchParams.append("code_challenge",M.code_challenge),E.searchParams.append("code_challenge_method","S256")),D&&(Array.isArray(D)?D:[D]).forEach($=>E.searchParams.append("resource",$));for(const[L,$]of Object.entries({response_mode:p,...x,...B}))$!=null&&E.searchParams.append(L,$.toString());return new Jp({url:E.href,state:M})}};Zp._logger=new ue("SigninRequest");var Yk=Zp,Qk="openid",nl=class{constructor(r){if(this.access_token="",this.token_type="",this.profile={},this.state=r.get("state"),this.session_state=r.get("session_state"),this.state){const e=decodeURIComponent(this.state).split(Rl);this.state=e[0],e.length>1&&(this.url_state=e.slice(1).join(Rl))}this.error=r.get("error"),this.error_description=r.get("error_description"),this.error_uri=r.get("error_uri"),this.code=r.get("code")}get expires_in(){if(this.expires_at!==void 0)return this.expires_at-Zt.getEpochTime()}set expires_in(r){typeof r=="string"&&(r=Number(r)),r!==void 0&&r>=0&&(this.expires_at=Math.floor(r)+Zt.getEpochTime())}get isOpenId(){var r;return((r=this.scope)==null?void 0:r.split(" ").includes(Qk))||!!this.id_token}},Zk=class{constructor({url:r,state_data:e,id_token_hint:t,post_logout_redirect_uri:i,extraQueryParams:o,request_type:l,client_id:u}){if(this._logger=new ue("SignoutRequest"),!r)throw this._logger.error("ctor: No url passed"),new Error("url");const d=new URL(r);t&&d.searchParams.append("id_token_hint",t),u&&d.searchParams.append("client_id",u),i&&(d.searchParams.append("post_logout_redirect_uri",i),e&&(this.state=new lo({data:e,request_type:l}),d.searchParams.append("state",this.state.id)));for(const[p,v]of Object.entries({...o}))v!=null&&d.searchParams.append(p,v.toString());this.url=d.href}},Jk=class{constructor(r){this.state=r.get("state"),this.error=r.get("error"),this.error_description=r.get("error_description"),this.error_uri=r.get("error_uri")}},e1=["nbf","jti","auth_time","nonce","acr","amr","azp","at_hash"],t1=["sub","iss","aud","exp","iat"],r1=class{constructor(r){this._settings=r,this._logger=new ue("ClaimsService")}filterProtocolClaims(r){const e={...r};if(this._settings.filterProtocolClaims){let t;Array.isArray(this._settings.filterProtocolClaims)?t=this._settings.filterProtocolClaims:t=e1;for(const i of t)t1.includes(i)||delete e[i]}return e}mergeClaims(r,e){const t={...r};for(const[i,o]of Object.entries(e))if(t[i]!==o)if(Array.isArray(t[i])||Array.isArray(o))if(this._settings.mergeClaimsStrategy.array=="replace")t[i]=o;else{const l=Array.isArray(t[i])?t[i]:[t[i]];for(const u of Array.isArray(o)?o:[o])l.includes(u)||l.push(u);t[i]=l}else typeof t[i]=="object"&&typeof o=="object"?t[i]=this.mergeClaims(t[i],o):t[i]=o;return t}},n1=class{constructor(r,e){this._logger=new ue("OidcClient"),this.settings=r instanceof Pl?r:new Pl(r),this.metadataService=e??new Vk(this.settings),this._claimsService=new r1(this.settings),this._validator=new Xk(this.settings,this.metadataService,this._claimsService),this._tokenClient=new Yp(this.settings,this.metadataService)}async createSigninRequest({state:r,request:e,request_uri:t,request_type:i,id_token_hint:o,login_hint:l,skipUserInfo:u,nonce:d,url_state:p,response_type:v=this.settings.response_type,scope:S=this.settings.scope,redirect_uri:O=this.settings.redirect_uri,prompt:k=this.settings.prompt,display:D=this.settings.display,max_age:N=this.settings.max_age,ui_locales:B=this.settings.ui_locales,acr_values:V=this.settings.acr_values,resource:H=this.settings.resource,response_mode:x=this.settings.response_mode,extraQueryParams:M=this.settings.extraQueryParams,extraTokenParams:E=this.settings.extraTokenParams}){const A=this._logger.create("createSigninRequest");
118if(v!=="code")throw new Error("Only the Authorization Code flow (with PKCE) is supported");const L=await this.metadataService.getAuthorizationEndpoint();A.debug("Received authorization endpoint",L);const $=await Yk.create({url:L,authority:this.settings.authority,client_id:this.settings.client_id,redirect_uri:O,response_type:v,scope:S,state_data:r,url_state:p,prompt:k,display:D,max_age:N,ui_locales:B,id_token_hint:o,login_hint:l,acr_values:V,resource:H,request:e,request_uri:t,extraQueryParams:M,extraTokenParams:E,request_type:i,response_mode:x,client_secret:this.settings.client_secret,skipUserInfo:u,nonce:d,disablePKCE:this.settings.disablePKCE});await this.clearStaleState();const q=$.state;return await this.settings.stateStore.set(q.id,q.toStorageString()),$}async readSigninResponseState(r,e=!1){const t=this._logger.create("readSigninResponseState"),i=new nl(Ll.readParams(r,this.settings.response_mode));if(!i.state)throw t.throw(new Error("No state in response")),null;const o=await this.settings.stateStore[e?"remove":"get"](i.state);if(!o)throw t.throw(new Error("No matching state found in storage")),null;return{state:await Qp.fromStorageString(o),response:i}}async processSigninResponse(r){const e=this._logger.create("processSigninResponse"),{state:t,response:i}=await this.readSigninResponseState(r,!0);return e.debug("received state from storage; validating response"),await this._validator.validateSigninResponse(i,t),i}async processResourceOwnerPasswordCredentials({username:r,password:e,skipUserInfo:t=!1,extraTokenParams:i={}}){const o=await this._tokenClient.exchangeCredentials({username:r,password:e,...i}),l=new nl(new URLSearchParams);return Object.assign(l,o),await this._validator.validateCredentialsResponse(l,t),l}async useRefreshToken({state:r,redirect_uri:e,resource:t,timeoutInSeconds:i,extraTokenParams:o}){var l;const u=this._logger.create("useRefreshToken");let d;if(this.settings.refreshTokenAllowedScope===void 0)d=r.scope;else{const S=this.settings.refreshTokenAllowedScope.split(" ");d=(((l=r.scope)==null?void 0:l.split(" "))||[]).filter(k=>S.includes(k)).join(" ")}const p=await this._tokenClient.exchangeRefreshToken({refresh_token:r.refresh_token,scope:d,redirect_uri:e,resource:t,timeoutInSeconds:i,...o}),v=new nl(new URLSearchParams);return Object.assign(v,p),u.debug("validating response",v),await this._validator.validateRefreshResponse(v,{...r,scope:d}),v}async createSignoutRequest({state:r,id_token_hint:e,client_id:t,request_type:i,post_logout_redirect_uri:o=this.settings.post_logout_redirect_uri,extraQueryParams:l=this.settings.extraQueryParams}={}){const u=this._logger.create("createSignoutRequest"),d=await this.metadataService.getEndSessionEndpoint();if(!d)throw u.throw(new Error("No end session endpoint")),null;u.debug("Received end session endpoint",d),!t&&o&&!e&&(t=this.settings.client_id);const p=new Zk({url:d,id_token_hint:e,client_id:t,post_logout_redirect_uri:o,state_data:r,extraQueryParams:l,request_type:i});await this.clearStaleState();const v=p.state;return v&&(u.debug("Signout request has state to persist"),await this.settings.stateStore.set(v.id,v.toStorageString())),p}async readSignoutResponseState(r,e=!1){const t=this._logger.create("readSignoutResponseState"),i=new Jk(Ll.readParams(r,this.settings.response_mode));if(!i.state){if(t.debug("No state in response"),i.error)throw t.warn("Response was error:",i.error),new zr(i);return{state:void 0,response:i}}const o=await this.settings.stateStore[e?"remove":"get"](i.state);if(!o)throw t.throw(new Error("No matching state found in storage")),null;return{state:await lo.fromStorageString(o),response:i}}async processSignoutResponse(r){const e=this._logger.create("processSignoutResponse"),{state:t,response:i}=await this.readSignoutResponseState(r,!0);return t?(e.debug("Received state from storage; validating response"),this._validator.validateSignoutResponse(i,t)):e.debug("No state from storage; skipping response validation"),i}clearStaleState(){return this._logger.create("clearStaleState"),lo.clearStaleState(this.settings.stateStore,this.settings.staleStateAgeInSeconds)}async revokeToken(r,e){return this._logger.create("revokeToken"),await this._tokenClient.revoke({token:r,token_type_hint:e})}},i1=class{constructor(r){this._userManager=r,this._logger=new ue("SessionMonitor"),this._start=async e=>{const t=e.session_state;if(!t)return;const i=this._logger.create("_start");if(e.profile?(this._sub=e.profile.sub,i.debug("session_state",t,", sub",this._sub)):(this._sub=void 0,i.debug("session_state",t,", anonymous user")),this._checkSessionIFrame){this._checkSessionIFrame.start(t);return}try{const o=await this._userManager.metadataService.getCheckSessionIframe();if(o){i.debug("initializing check session iframe");const l=this._userManager.settings.client_id,u=this._userManager.settings.checkSessionIntervalInSeconds,d=this._userManager.settings.stopCheckSessionOnError,p=new qk(this._callback,l,o,u,d);await p.load(),this._checkSessionIFrame=p,p.start(t)}else i.warn("no check session iframe found in the metadata")}catch(o){i.error("Error from getCheckSessionIframe:",o instanceof Error?o.message:o)}},this._stop=()=>{const e=this._logger.create("_stop");if(this._sub=void 0,this._checkSessionIFrame&&this._checkSessionIFrame.stop(),this._userManager.settings.monitorAnonymousSession){const t=setInterval(async()=>{clearInterval(t);try{const i=await this._userManager.querySessionStatus();if(i){const o={session_state:i.session_state,profile:i.sub?{sub:i.sub}:null};this._start(o)}}catch(i){e.error("error from querySessionStatus",i instanceof Error?i.message:i)}},1e3)}},this._callback=async()=>{const e=this._logger.create("_callback");try{const t=await this._userManager.querySessionStatus();let i=!0;t&&this._checkSessionIFrame?t.sub===this._sub?(i=!1,this._checkSessionIFrame.start(t.session_state),e.debug("same sub still logged in at OP, session state has changed, restarting check session iframe; session_state",t.session_state),await this._userManager.events._raiseUserSessionChanged()):e.debug("different subject signed into OP",t.sub):e.debug("subject no longer signed into OP"),i?this._sub?await this._userManager.events._raiseUserSignedOut():await this._userManager.events._raiseUserSignedIn():e.debug("no change in session detected, no event to raise")}catch(t){this._sub&&(e.debug("Error calling queryCurrentSigninSession; raising signed out event",t),await this._userManager.events._raiseUserSignedOut())}},r||this._logger.throw(new Error("No user manager passed")),this._userManager.events.addUserLoaded(this._start),this._userManager.events.addUserUnloaded(this._stop),this._init().catch(e=>{this._logger.error(e)})}async _init(){this._logger.create("_init");const r=await this._userManager.getUser();if(r)this._start(r);else if(this._userManager.settings.monitorAnonymousSession){const e=await this._userManager.querySessionStatus();if(e){const t={session_state:e.session_state,profile:e.sub?{sub:e.sub}:null};this._start(t)}}}},il=class em{constructor(e){var t;this.id_token=e.id_token,this.session_state=(t=e.session_state)!=null?t:null,this.access_token=e.access_token,this.refresh_token=e.refresh_token,this.token_type=e.token_type,this.scope=e.scope,this.profile=e.profile,this.expires_at=e.expires_at,this.state=e.userState,this.url_state=e.url_state}get expires_in(){if(this.expires_at!==void 0)return this.expires_at-Zt.getEpochTime()}set expires_in(e){e!==void 0&&(this.expires_at=Math.floor(e)+Zt.getEpochTime())}get expired(){const e=this.expires_in;if(e!==void 0)return e<=0}get scopes(){var e,t;return(t=(e=this.scope)==null?void 0:e.split(" "))!=null?t:[]}toStorageString(){return new ue("User").create("toStorageString"),JSON.stringify({id_token:this.id_token,session_state:this.session_state,access_token:this.access_token,refresh_token:this.refresh_token,token_type:this.token_type,scope:this.scope,profile:this.profile,expires_at:this.expires_at})}static fromStorageString(e){return ue.createStatic("User","fromStorageString"),new em(JSON.parse(e))}},pf="oidc-client",tm=class{constructor(){this._abort=new hr("Window navigation aborted"),this._disposeHandlers=new Set,this._window=null}async navigate(r){const e=this._logger.create("navigate");if(!this._window)throw new Error("Attempted to navigate on a disposed window");e.debug("setting URL in window"),this._window.location.replace(r.url);const{url:t,keepOpen:i}=await new Promise((o,l)=>{const u=d=>{var p;const v=d.data,S=(p=r.scriptOrigin)!=null?p:window.location.origin;if(!(d.origin!==S||(v==null?void 0:v.source)!==pf)){try{const O=Ll.readParams(v.url,r.response_mode).get("state");if(O||e.warn("no state found in response url"),d.source!==this._window&&O!==r.state)return}catch{this._dispose(),l(new Error("Invalid response from window"))}o(v)}};window.addEventListener("message",u,!1),this._disposeHandlers.add(()=>window.removeEventListener("message",u,!1)),this._disposeHandlers.add(this._abort.addHandler(d=>{this._dispose(),l(d)}))});return e.debug("got response from window"),this._dispose(),i||this.close(),{url:t}}_dispose(){this._logger.create("_dispose");for(const r of this._disposeHandlers)r();this._disposeHandlers.clear()}static _notifyParent(r,e,t=!1,i=window.location.origin){r.postMessage({source:pf,url:e,keepOpen:t},i)}},rm={location:!1,toolbar:!1,height:640,closePopupWindowAfterInSeconds:-1},nm="_blank",s1=60,o1=2,im=10,a1=class extends Pl{constructor(r){const{popup_redirect_uri:e=r.redirect_uri,popup_post_logout_redirect_uri:t=r.post_logout_redirect_uri,popupWindowFeatures:i=rm,popupWindowTarget:o=nm,redirectMethod:l="assign",redirectTarget:u="self",iframeNotifyParentOrigin:d=r.iframeNotifyParentOrigin,iframeScriptOrigin:p=r.iframeScriptOrigin,silent_redirect_uri:v=r.redirect_uri,silentRequestTimeoutInSeconds:S=im,automaticSilentRenew:O=!0,validateSubOnSilentRenew:k=!0,includeIdTokenInSilentRenew:D=!1,monitorSession:N=!1,monitorAnonymousSession:B=!1,checkSessionIntervalInSeconds:V=o1,query_status_response_type:H="code",stopCheckSessionOnError:x=!0,revokeTokenTypes:M=["access_token","refresh_token"],revokeTokensOnSignout:E=!1,includeIdTokenInSilentSignout:A=!1,accessTokenExpiringNotificationTimeInSeconds:L=s1,userStore:$}=r;if(super(r),this.popup_redirect_uri=e,this.popup_post_logout_redirect_uri=t,this.popupWindowFeatures=i,this.popupWindowTarget=
118o,this.redirectMethod=l,this.redirectTarget=u,this.iframeNotifyParentOrigin=d,this.iframeScriptOrigin=p,this.silent_redirect_uri=v,this.silentRequestTimeoutInSeconds=S,this.automaticSilentRenew=O,this.validateSubOnSilentRenew=k,this.includeIdTokenInSilentRenew=D,this.monitorSession=N,this.monitorAnonymousSession=B,this.checkSessionIntervalInSeconds=V,this.stopCheckSessionOnError=x,this.query_status_response_type=H,this.revokeTokenTypes=M,this.revokeTokensOnSignout=E,this.includeIdTokenInSilentSignout=A,this.accessTokenExpiringNotificationTimeInSeconds=L,$)this.userStore=$;else{const q=typeof window<"u"?window.sessionStorage:new Xp;this.userStore=new Ic({store:q})}}},mf=class sm extends tm{constructor({silentRequestTimeoutInSeconds:e=im}){super(),this._logger=new ue("IFrameWindow"),this._timeoutInSeconds=e,this._frame=sm.createHiddenIframe(),this._window=this._frame.contentWindow}static createHiddenIframe(){const e=window.document.createElement("iframe");return e.style.visibility="hidden",e.style.position="fixed",e.style.left="-1000px",e.style.top="0",e.width="0",e.height="0",window.document.body.appendChild(e),e}async navigate(e){this._logger.debug("navigate: Using timeout of:",this._timeoutInSeconds);const t=setTimeout(()=>void this._abort.raise(new Oc("IFrame timed out without a response")),this._timeoutInSeconds*1e3);return this._disposeHandlers.add(()=>clearTimeout(t)),await super.navigate(e)}close(){var e;this._frame&&(this._frame.parentNode&&(this._frame.addEventListener("load",t=>{var i;const o=t.target;(i=o.parentNode)==null||i.removeChild(o),this._abort.raise(new Error("IFrame removed from DOM"))},!0),(e=this._frame.contentWindow)==null||e.location.replace("about:blank")),this._frame=null),this._window=null}static notifyParent(e,t){return super._notifyParent(window.parent,e,!1,t)}},l1=class{constructor(r){this._settings=r,this._logger=new ue("IFrameNavigator")}async prepare({silentRequestTimeoutInSeconds:r=this._settings.silentRequestTimeoutInSeconds}){return new mf({silentRequestTimeoutInSeconds:r})}async callback(r){this._logger.create("callback"),mf.notifyParent(r,this._settings.iframeNotifyParentOrigin)}},c1=500,u1=1e3,vf=class extends tm{constructor({popupWindowTarget:r=nm,popupWindowFeatures:e={}}){super(),this._logger=new ue("PopupWindow");const t=gf.center({...rm,...e});this._window=window.open(void 0,r,gf.serialize(t)),e.closePopupWindowAfterInSeconds&&e.closePopupWindowAfterInSeconds>0&&setTimeout(()=>{if(!this._window||typeof this._window.closed!="boolean"||this._window.closed){this._abort.raise(new Error("Popup blocked by user"));return}this.close()},e.closePopupWindowAfterInSeconds*u1)}async navigate(r){var e;(e=this._window)==null||e.focus();const t=setInterval(()=>{(!this._window||this._window.closed)&&this._abort.raise(new Error("Popup closed by user"))},c1);return this._disposeHandlers.add(()=>clearInterval(t)),await super.navigate(r)}close(){this._window&&(this._window.closed||(this._window.close(),this._abort.raise(new Error("Popup closed")))),this._window=null}static notifyOpener(r,e){if(!window.opener)throw new Error("No window.opener. Can't complete notification.");return super._notifyParent(window.opener,r,e)}},h1=class{constructor(r){this._settings=r,this._logger=new ue("PopupNavigator")}async prepare({popupWindowFeatures:r=this._settings.popupWindowFeatures,popupWindowTarget:e=this._settings.popupWindowTarget}){return new vf({popupWindowFeatures:r,popupWindowTarget:e})}async callback(r,{keepOpen:e=!1}){this._logger.create("callback"),vf.notifyOpener(r,e)}},d1=class{constructor(r){this._settings=r,this._logger=new ue("RedirectNavigator")}async prepare({redirectMethod:r=this._settings.redirectMethod,redirectTarget:e=this._settings.redirectTarget}){var t;this._logger.create("prepare");let i=window.self;e==="top"&&(i=(t=window.top)!=null?t:window.self);const o=i.location[r].bind(i.location);let l;return{navigate:async u=>{this._logger.create("navigate");const d=new Promise((p,v)=>{l=v});return o(u.url),await d},close:()=>{this._logger.create("close"),l==null||l(new Error("Redirect aborted")),i.stop()}}}async callback(){}},f1=class extends Hk{constructor(r){super({expiringNotificationTimeInSeconds:r.accessTokenExpiringNotificationTimeInSeconds}),this._logger=new ue("UserManagerEvents"),this._userLoaded=new hr("User loaded"),this._userUnloaded=new hr("User unloaded"),this._silentRenewError=ne
118w hr("Silent renew error"),this._userSignedIn=new hr("User signed in"),this._userSignedOut=new hr("User signed out"),this._userSessionChanged=new hr("User session changed")}async load(r,e=!0){super.load(r),e&&await this._userLoaded.raise(r)}async unload(){super.unload(),await this._userUnloaded.raise()}addUserLoaded(r){return this._userLoaded.addHandler(r)}removeUserLoaded(r){return this._userLoaded.removeHandler(r)}addUserUnloaded(r){return this._userUnloaded.addHandler(r)}removeUserUnloaded(r){return this._userUnloaded.removeHandler(r)}addSilentRenewError(r){return this._silentRenewError.addHandler(r)}removeSilentRenewError(r){return this._silentRenewError.removeHandler(r)}async _raiseSilentRenewError(r){await this._silentRenewError.raise(r)}addUserSignedIn(r){return this._userSignedIn.addHandler(r)}removeUserSignedIn(r){this._userSignedIn.removeHandler(r)}async _raiseUserSignedIn(){await this._userSignedIn.raise()}addUserSignedOut(r){return this._userSignedOut.addHandler(r)}removeUserSignedOut(r){this._userSignedOut.removeHandler(r)}async _raiseUserSignedOut(){await this._userSignedOut.raise()}addUserSessionChanged(r){return this._userSessionChanged.addHandler(r)}removeUserSessionChanged(r){this._userSessionChanged.removeHandler(r)}async _raiseUserSessionChanged(){await this._userSessionChanged.raise()}},g1=class{constructor(r){this._userManager=r,this._logger=new ue("SilentRenewService"),this._isStarted=!1,this._retryTimer=new Zt("Retry Silent Renew"),this._tokenExpiring=async()=>{const e=this._logger.create("_tokenExpiring");try{await this._userManager.signinSilent(),e.debug("silent token renewal successful")}catch(t){if(t instanceof Oc){e.warn("ErrorTimeout from signinSilent:",t,"retry in 5s"),this._retryTimer.init(5);return}e.error("Error from signinSilent:",t),await this._userManager.events._raiseSilentRenewError(t)}}}async start(){const r=this._logger.create("start");if(!this._isStarted){this._isStarted=!0,this._userManager.events.addAccessTokenExpiring(this._tokenExpiring),this._retryTimer.addHandler(this._tokenExpiring);try{await this._userManager.getUser()}catch(e){r.error("getUser error",e)}}}stop(){this._isStarted&&(this._retryTimer.cancel(),this._retryTimer.removeHandler(this._tokenExpiring),this._userManager.events.removeAccessTokenExpiring(this._tokenExpiring),this._isStarted=!1)}},p1=class{constructor(r){this.refresh_token=r.refresh_token,this.id_token=r.id_token,this.session_state=r.session_state,this.scope=r.scope,this.profile=r.profile,this.data=r.state}},m1=class{constructor(r,e,t,i){this._logger=new ue("UserManager"),this.settings=new a1(r),this._client=new n1(r),this._redirectNavigator=e??new d1(this.settings),this._popupNavigator=t??new h1(this.settings),this._iframeNavigator=i??new l1(this.settings),this._events=new f1(this.settings),this._silentRenewService=new g1(this),this.settings.automaticSilentRenew&&this.startSilentRenew(),this._sessionMonitor=null,this.settings.monitorSession&&(this._sessionMonitor=new i1(this))}get events(){return this._events}get metadataService(){return this._client.metadataService}async getUser(){const r=this._logger.create("getUser"),e=await this._loadUser();return e?(r.info("user loaded"),await this._events.load(e,!1),e):(r.info("user not found in storage"),null)}async removeUser(){const r=this._logger.create("removeUser");await this.storeUser(null),r.info("user removed from storage"),await this._events.unload()}async signinRedirect(r={}){this._logger.create("signinRedirect");const{redirectMethod:e,...t}=r,i=await this._redirectNavigator.prepare({redirectMethod:e});await this._signinStart({request_type:"si:r",...t},i)}async signinRedirectCallback(r=window.location.href){const e=this._logger.create("signinRedirectCallback"),t=await this._signinEnd(r);return t.profile&&t.profile.sub?e.info("success, signed in subject",t.profile.sub):e.info("no subject"),t}async signinResourceOwnerCredentials({username:r,password:e,skipUserInfo:t=!1}){const i=this._logger.create("signinResourceOwnerCredential"),o=await this._client.processResourceOwnerPasswordCredentials({username:r,password:e,skipUserInfo:t,extraTokenParams:this.settings.extraTokenParams});i.debug("got signin response");const l=await this._buildUser(o);return l.profile&&l.profile.sub?i.info("success, signed in subject",l.profile.sub):i.info("no subject"),l}async signinPopup(r={}){const e=this._logger.create("signinPopup"),{popupWindowFeatures:t,popupWindowTarget:i,...o}=r,l=this.settings.popup_redirect_uri;l||e.throw(new Error("No popup_redirect_uri configured"));const u=await this._popupNavigator.prepare({popupWindowFeatures:t,popupWindowTarget:i}
118),d=await this._signin({request_type:"si:p",redirect_uri:l,display:"popup",...o},u);return d&&(d.profile&&d.profile.sub?e.info("success, signed in subject",d.profile.sub):e.info("no subject")),d}async signinPopupCallback(r=window.location.href,e=!1){const t=this._logger.create("signinPopupCallback");await this._popupNavigator.callback(r,{keepOpen:e}),t.info("success")}async signinSilent(r={}){var e;const t=this._logger.create("signinSilent"),{silentRequestTimeoutInSeconds:i,...o}=r;let l=await this._loadUser();if(l!=null&&l.refresh_token){t.debug("using refresh token");const v=new p1(l);return await this._useRefreshToken({state:v,redirect_uri:o.redirect_uri,resource:o.resource,extraTokenParams:o.extraTokenParams,timeoutInSeconds:i})}const u=this.settings.silent_redirect_uri;u||t.throw(new Error("No silent_redirect_uri configured"));let d;l&&this.settings.validateSubOnSilentRenew&&(t.debug("subject prior to silent renew:",l.profile.sub),d=l.profile.sub);const p=await this._iframeNavigator.prepare({silentRequestTimeoutInSeconds:i});return l=await this._signin({request_type:"si:s",redirect_uri:u,prompt:"none",id_token_hint:this.settings.includeIdTokenInSilentRenew?l==null?void 0:l.id_token:void 0,...o},p,d),l&&((e=l.profile)!=null&&e.sub?t.info("success, signed in subject",l.profile.sub):t.info("no subject")),l}async _useRefreshToken(r){const e=await this._client.useRefreshToken({...r,timeoutInSeconds:this.settings.silentRequestTimeoutInSeconds}),t=new il({...r.state,...e});return await this.storeUser(t),await this._events.load(t),t}async signinSilentCallback(r=window.location.href){const e=this._logger.create("signinSilentCallback");await this._iframeNavigator.callback(r),e.info("success")}async signinCallback(r=window.location.href){const{state:e}=await this._client.readSigninResponseState(r);switch(e.request_type){case"si:r":return await this.signinRedirectCallback(r);case"si:p":return await this.signinPopupCallback(r);case"si:s":return await this.signinSilentCallback(r);default:throw new Error("invalid response_type in state")}}async signoutCallback(r=window.location.href,e=!1){const{state:t}=await this._client.readSignoutResponseState(r);if(t)switch(t.request_type){case"so:r":await this.signoutRedirectCallback(r);break;case"so:p":await this.signoutPopupCallback(r,e);break;case"so:s":await this.signoutSilentCallback(r);break;default:throw new Error("invalid response_type in state")}}async querySessionStatus(r={}){const e=this._logger.create("querySessionStatus"),{silentRequestTimeoutInSeconds:t,...i}=r,o=this.settings.silent_redirect_uri;o||e.throw(new Error("No silent_redirect_uri configured"));const l=await this._loadUser(),u=await this._iframeNavigator.prepare({silentRequestTimeoutInSeconds:t}),d=await this._signinStart({request_type:"si:s",redirect_uri:o,prompt:"none",id_token_hint:this.settings.includeIdTokenInSilentRenew?l==null?void 0:l.id_token:void 0,response_type:this.settings.query_status_response_type,scope:"openid",skipUserInfo:!0,...i},u);try{const p=await this._client.processSigninResponse(d.url);return e.debug("got signin response"),p.session_state&&p.profile.sub?(e.info("success for subject",p.profile.sub),{session_state:p.session_state,sub:p.profile.sub}):(e.info("success, user not authenticated"),null)}catch(p){if(this.settings.monitorAnonymousSession&&p instanceof zr)switch(p.error){case"login_required":case"consent_required":case"interaction_required":case"account_selection_required":return e.info("success for anonymous user"),{session_state:p.session_state}}throw p}}async _signin(r,e,t){const i=await this._signinStart(r,e);return await this._signinEnd(i.url,t)}async _signinStart(r,e){const t=this._logger.create("_signinStart");try{const i=await this._client.createSigninRequest(r);return t.debug("got signin request"),await e.navigate({url:i.url,state:i.state.id,response_mode:i.state.response_mode,scriptOrigin:this.settings.iframeScriptOrigin})}catch(i){throw t.debug("error after preparing navigator, closing navigator window"),e.close(),i}}async _signinEnd(r,e){const t=this._logger.create("_signinEnd"),i=await this._client.processSigninResponse(r);return t.debug("got signin response"),await this._buildUser(i,e)}async _buildUser(r,e){const t=this._logger.create("_buildUser"),i=new il(r);if(e){if(e!==i.profile.sub)throw t.debug("current user does not match user returned from signin. sub from signin:",i.profile.sub),new zr({...r,error:"login_required"});t.debug("current user matches user returned from signin")}return await this.storeUser(i),t.debug("user stored"),await this._events.load(i),i}async signoutRedirect(r={}){const e=this._logger.create("signoutRedirect"),{redirectMethod:t,...i}=r,o=await this._redirectNavigator.prepare({redirectMethod:t});await this._signoutStart({request_type:"so:r",post_logout_redirect_uri:this.settings.post_logout_redirect_uri,...i},o),e.info("success")}async signoutRedirectCallback(r=window.location.href){const e=this._logger.create("signoutRedirectCallback"),t=await this._signoutEnd(r);return e.info("success"),t}async signoutPopup(r={}){const e=this._logger.create("signoutPopup"),{popupWindowFeatures:t,popupWindowTarget:i,...o}=r,l=this.settings.popup_post_logout_redirect_uri,u=await this._popupNavigator.prepare({popupWindowFeatures:t,popupWindowTarget:i});await this._signout({request_type:"so:p",post_logout_redirect_uri:l,state:l==null?void 0:{},...o},u),e.info("success")}async signoutPopupCallback(r=window.location.href,e=!1){const t=this._logger.create("signoutPopupCallback");await this._popupNavigator.callback(r,{keepOpen:e}),t.info("success")}async _signout(r,e){const t=await this._signoutStart(r,e);return await this._signoutEnd(t.url)}async _signoutStart(r={},e){var t;const i=this._logger.create("_signoutStart");try{const o=await this._loadUser();i.debug("loaded current user from storage"),this.settings.revokeTokensOnSignout&&await this._revokeInternal(o);const l=r.id_token_hint||o&&o.id_token;l&&(i.debug("setting id_token_hint in signout request"),r.id_token_hint=l),await this.removeUser(),i.debug("user removed, creating signout request");
118const u=await this._client.createSignoutRequest(r);return i.debug("got signout request"),await e.navigate({url:u.url,state:(t=u.state)==null?void 0:t.id,scriptOrigin:this.settings.iframeScriptOrigin})}catch(o){throw i.debug("error after preparing navigator, closing navigator window"),e.close(),o}}async _signoutEnd(r){const e=this._logger.create("_signoutEnd"),t=await this._client.processSignoutResponse(r);return e.debug("got signout response"),t}async signoutSilent(r={}){var e;const t=this._logger.create("signoutSilent"),{silentRequestTimeoutInSeconds:i,...o}=r,l=this.settings.includeIdTokenInSilentSignout?(e=await this._loadUser())==null?void 0:e.id_token:void 0,u=this.settings.popup_post_logout_redirect_uri,d=await this._iframeNavigator.prepare({silentRequestTimeoutInSeconds:i});await this._signout({request_type:"so:s",post_logout_redirect_uri:u,id_token_hint:l,...o},d),t.info("success")}async signoutSilentCallback(r=window.location.href){const e=this._logger.create("signoutSilentCallback");await this._iframeNavigator.callback(r),e.info("success")}async revokeTokens(r){const e=await this._loadUser();await this._revokeInternal(e,r)}async _revokeInternal(r,e=this.settings.revokeTokenTypes){const t=this._logger.create("_revokeInternal");if(!r)return;const i=e.filter(o=>typeof r[o]=="string");if(!i.length){t.debug("no need to revoke due to no token(s)");return}for(const o of i)await this._client.revokeToken(r[o],o),t.info(`${o} revoked successfully`),o!=="access_token"&&(r[o]=null);await this.storeUser(r),t.debug("user stored"),await this._events.load(r)}startSilentRenew(){this._logger.create("startSilentRenew"),this._silentRenewService.start()}stopSilentRenew(){this._silentRenewService.stop()}get _userStoreKey(){return`user:${this.settings.authority}:${this.settings.client_id}`}async _loadUser(){const r=this._logger.create("_loadUser"),e=await this.settings.userStore.get(this._userStoreKey);return e?(r.debug("user storageString loaded"),il.fromStorageString(e)):(r.debug("no user storageString"),null)}async storeUser(r){const e=this._logger.create("storeUser");if(r){e.debug("storing user");const t=r.toStorageString();await this.settings.userStore.set(this._userStoreKey,t)}else this._logger.debug("removing user"),await this.settings.userStore.remove(this._userStoreKey)}async clearStaleState(){await this._client.clearStaleState()}};function hi(r,e){return e.reduce((t,i)=>t&&t[i]?t[i]:null,r)}class v1{add(e,t,i){if(typeof arguments[0]!="string")for(let o in arguments[0])this.add(o,arguments[0][o],arguments[1]);else(Array.isArray(e)?e:[e]).forEach(function(o){this[o]=this[o]||[],t&&this[o][i?"unshift":"push"](t)},this)}run(e,t){this[e]=this[e]||[],this[e].forEach(function(i){i.call(t&&t.context?t.context:t,t)})}}class b1{constructor(e){this.jsep=e,this.registered={}}register(){for(var e=arguments.length,t=new Array(e),i=0;i<e;i++)t[i]=arguments[i];t.forEach(o=>{if(typeof o!="object"||!o.name||!o.init)throw new Error("Invalid JSEP plugin format");this.registered[o.name]||(o.init(this.jsep),this.registered[o.name]=o)})}}class C{static get version(){return"1.4.0"}static toString(){return"JavaScript Expression Parser (JSEP) v"+C.version}static addUnaryOp(e){return C.max_unop_len=Math.max(e.length,C.max_unop_len),C.unary_ops[e]=1,C}static addBinaryOp(e,t,i){return C.max_binop_len=Math.max(e.length,C.max_binop_len),C.binary_ops[e]=t,i?C.right_associative.add(e):C.right_associative.delete(e),C}static addIdentifierChar(e){return C.additional_identifier_chars.add(e),C}static addLiteral(e,t){return C.literals[e]=t,C}static removeUnaryOp(e){return delete C.unary_ops[e],e.length===C.max_unop_len&&(C.max_unop_len=C.getMaxKeyLen(C.unary_ops)),C}static removeAllUnaryOps(){return C.unary_ops={},C.max_unop_len=0,C}static removeIdentifierChar(e){return C.additional_identifier_chars.delete(e),C}static removeBinaryOp(e){return delete C.binary_ops[e],e.length===C.max_binop_len&&(C.max_binop_len=C.getMaxKeyLen(C.binary_ops)),C.right_associative.delete(e),C}static removeAllBinaryOps(){return C.binary_ops={},C.max_binop_len=0,C}static removeLiteral(e){return delete C.literals[e],C}static removeAllLiterals(){return C.literals={},C}get char(){return this.expr.charAt(this.index)}get code(){return this.expr.charCodeAt(this.index)}constructor(e){this.expr=e,this.index=0}static parse(e){return new C(e).parse()}static getMaxKeyLen(e){return Math.max(0,...Object.keys(e).map(t=>t.length))}static isDecimalDigit(e){return e>=48&&e<=57}static binaryPrecedence(e){return C.binary_ops[e]||0}static isIdentifierStart(e){return e>=65&&e<=90||e>=97&&e<=122||e>=128&&!C.binary_ops[String.fromCharCode(e)]||C.additional_identifier_chars.has(String.fromCharCode(e))}static isIdentifierPart(e){return C.isIdentifierStart(e)||C.isDecimalDigit(e)}throwError(e){const t=new Error(e+" at character "+this.index);throw t.index=this.index,t.description=e,t}runHook(e,t){if(C.hooks[e]){const i={context:this,node:t};return C.hooks.run(e,i),i.node}return t}searchHook(e){if(C.hooks[e]){const t={context:this};return C.hooks[e].find(function(i){return i.call(t.context,t),t.node}),t.node}}gobbleSpaces(){let e=this.code;for(;e===C.SPACE_CODE||e===C.TAB_CODE||e===C.LF_CODE||e===C.CR_CODE;)e=this.expr.charCodeAt(++this.index);this.runHook("gobble-spaces")}parse(){this.runHook("before-all");const e=this.gobbleExpressions(),t=e.length===1?e[0]:{type:C.COMPOUND,body:e};return this.runHook("after-all",t)}gobbleExpressions(e){let t=[],i,o;for(;this.index<this.expr.length;)if(i=this.code,i===C.SEMCOL_CODE||i===C.COMMA_CODE)this.index++;else if(o=this.gobbleExpression())t.push(o);else if(this.index<this.expr.length){if(i===e)break;this.throwError('Unexpected "'+this.char+'"')}return t}gobbleExpression(){const e=this.searchHook("gobble-expression")||this.gobbleBinaryExpression();return this.gobbleSpaces(),this.runHook("after-expression",e)}gobbleBinaryOp(){this.gobbleSpaces();let e=this.expr.substr(this.index,C.max_binop_len),t=e.length;for(;t>0;){if(C.binary_ops.hasOwnProperty(e)&&(!C.isIdentifierStart(this.code)||this.index+e.length<this.expr.length&&!C.isIdentifierPart(this.expr.charCodeAt(this.index+e.length))))return this.index+=t,e;e=e.substr(0,--t)}return!1}gobbleBinaryExpression(){let e,t,i,o,l,u,d,p,v;if(u=this.gobbleToken(),!u||(t=this.gobbleBinaryOp(),!t))return u;for(l={value:t,prec:C.binaryPrecedence(t),right_a:C.right_associative.has(t)},d=this.gobbleToken(),d||this.throwError("Expected expression after "+t),o=[u,l,d];t=this.gobbleBinaryOp();){if(i=C.binaryPrecedence(t),i===0){this.index-=t.length;break}l={value:t,prec:i,right_a:C.right_associative.has(t)},v=t;const S=O=>l.right_a&&O.right_a?i>O.prec:i<=O.prec;for(;o.length>2&&S(o[o.length-2]);)d=o.pop(),t=o.pop().value,u=o.pop(),e={type:C.BINARY_EXP,operator:t,left:u,right:d},o.push(e);e=this.gobbleToken(),e||this.throwError("Expected expression after "+v),o.push(l,e)}for(p=o.length-1,e=o[p];p>1;)e={type:C.BINARY_EXP,operator:o[p-1].value,left:o[p-2],right:e},p-=2;return e}gobbleToken(){let e,t,i,o;if(this.gobbleSpaces(),o=this.searchHook("gobble-token"),o)return this.runHook("after-token",o);if(e=this.code,C.isDecimalDigit(e)||e===C.PERIOD_CODE)return this.gobbleNumericLiteral();if(e===C.SQUOTE_CODE||e===C.DQUOTE_CODE)o=this.gobbleStringLiteral();else if(e===C.OBRACK_CODE)o=this.gobbleArray();else{for(t=this.expr.substr(this.index,C.max_unop_len),i=t.length;i>0;){if(C.unary_ops.hasOwnProperty(t)&&(!C.isIdentifierStart(this.code)||this.index+t.length<this.expr.length&&!C.isIdentifierPart(this.expr.charCodeAt(this.index+t.length)))){this.index+=i;const l=this.gobbleToken();return l||this.throwError("missing unaryOp argument"),this.runHook("after-token",{type:C.UNARY_EXP,operator:t,argument:l,prefix:!0})}t=t.substr(0,--i)}C.isIdentifierStart(e)?(o=this.gobbleIdentifier(),C.literals.hasOwnProperty(o.name)?o={type:C.LITERAL,value:C.literals[o.name],raw:o.name}:o.name===C.this_str&&(o={type:C.THIS_EXP})):e===C.OPAREN_CODE&&(o=this.gobbleGroup())}return o?(o=this.gobbleTokenProperty(o),this.runHook("after-token",o)):this.runHook("after-token",!1)}gobbleTokenProperty(e){this.gobbleSpaces();let t=this.code;for(;t===C.PERIOD_CODE||t===C.OBRACK_CODE||t===C.OPAREN_CODE||t===C.QUMARK_CODE;){let i;if(t===C.QUMARK_CODE){if(this.expr.charCodeAt(this.index+1)!==C.PERIOD_CODE)break;i=!0,this.index+=2,this.gobbleSpaces(),t=this.code}this.index++,t===C.OBRACK_CODE?(e={type:C.MEMBER_EXP,computed:!0,object:e,property:this.gobbleExpression()},e.property||this.throwError('Unexpected "'+this.char+'"'),this.gobbleSpaces(),t=this.code,t!==C.CBRACK_CODE&&this.throwError("Unclosed ["),this.index++):t===C.OPAREN_CODE?e={type:C.CALL_EXP,arguments:this.gobbleArguments(C.CPAREN_CODE),callee:e}:(t===C.PERIOD_CODE||i)&&(i&&this.index--,this.gobbleSpaces(),e={type:C.MEMBER_EXP,computed:!1,object:e,property:this.gobbleIdentifier()}),i&&(e.optional=!0),this.gobbleSpaces(),t=this.code}return e}gobbleNumericLiteral(){let e="",t,i;for(;C.isDecimalDigit(this.code);)e+=this.expr.charAt(this.index++);if(this.code===C.PERIOD_CODE)for(e+=this.expr.charAt(this.index++);C.isDecimalDigit(this.code);)e+=this.expr.charAt(this.index++);if(t=this.char,t==="e"||t==="E"){for(e+=this.expr.charAt(this.index++),t=this.char,(t==="+"||t==="-")&&(e+=this.expr.charAt(this.index++));C.isDecimalDigit(this.code);)e+=this.expr.charAt(this.index++);C.isDecimalDigit(this.expr.charCodeAt(this.index-1))||this.throwError("Expected exponent ("+e+this.char+")")}return i=this.code,C.isIdentifierStart(i)?this.throwError("Variable names cannot start with a number ("+e+this.char+")"):(i===C.PERIOD_CODE||e.length===1&&e.charCodeAt(0)===C.PERIOD_CODE)&&this.throwError("Unexpected period"),{type:C.LITERAL,value:parseFloat(e),raw:e}}gobbleStringLiteral(){let e="";const t=this.index,i=this.expr.charAt(this.index++);let o=!1;for(;this.index<this.expr.length;){let l=this.expr.charAt(this.index++);if(l===i){o=!0;break}else if(l==="\\")switch(l=this.expr.charAt(this.index++),l){case"n":e+=` 119`;break;case"r":e+="\r";break;case"t":e+=" ";break;case"b":e+="\b";break;case"f":e+="\f";break;case"v":e+="\v";break;default:e+=l}else e+=l}return o||this.throwError('Unclosed quote after "'+e+'"'),{type:C.LITERAL,value:e,raw:this.expr.substring(t,this.index)}}
119gobbleIdentifier(){let e=this.code,t=this.index;for(C.isIdentifierStart(e)?this.index++:this.throwError("Unexpected "+this.char);this.index<this.expr.length&&(e=this.code,C.isIdentifierPart(e));)this.index++;return{type:C.IDENTIFIER,name:this.expr.slice(t,this.index)}}gobbleArguments(e){const t=[];let i=!1,o=0;for(;this.index<this.expr.length;){this.gobbleSpaces();let l=this.code;if(l===e){i=!0,this.index++,e===C.CPAREN_CODE&&o&&o>=t.length&&this.throwError("Unexpected token "+String.fromCharCode(e));break}else if(l===C.COMMA_CODE){if(this.index++,o++,o!==t.length){if(e===C.CPAREN_CODE)this.throwError("Unexpected token ,");else if(e===C.CBRACK_CODE)for(let u=t.length;u<o;u++)t.push(null)}}else if(t.length!==o&&o!==0)this.throwError("Expected comma");else{const u=this.gobbleExpression();(!u||u.type===C.COMPOUND)&&this.throwError("Expected comma"),t.push(u)}}return i||this.throwError("Expected "+String.fromCharCode(e)),t}gobbleGroup(){this.index++;let e=this.gobbleExpressions(C.CPAREN_CODE);if(this.code===C.CPAREN_CODE)return this.index++,e.length===1?e[0]:e.length?{type:C.SEQUENCE_EXP,expressions:e}:!1;this.throwError("Unclosed (")}gobbleArray(){return this.index++,{type:C.ARRAY_EXP,elements:this.gobbleArguments(C.CBRACK_CODE)}}}const _1=new v1;Object.assign(C,{hooks:_1,plugins:new b1(C),COMPOUND:"Compound",SEQUENCE_EXP:"SequenceExpression",IDENTIFIER:"Identifier",MEMBER_EXP:"MemberExpression",LITERAL:"Literal",THIS_EXP:"ThisExpression",CALL_EXP:"CallExpression",UNARY_EXP:"UnaryExpression",BINARY_EXP:"BinaryExpression",ARRAY_EXP:"ArrayExpression",TAB_CODE:9,LF_CODE:10,CR_CODE:13,SPACE_CODE:32,PERIOD_CODE:46,COMMA_CODE:44,SQUOTE_CODE:39,DQUOTE_CODE:34,OPAREN_CODE:40,CPAREN_CODE:41,OBRACK_CODE:91,CBRACK_CODE:93,QUMARK_CODE:63,SEMCOL_CODE:59,COLON_CODE:58,unary_ops:{"-":1,"!":1,"~":1,"+":1},binary_ops:{"||":1,"??":1,"&&":2,"|":3,"^":4,"&":5,"==":6,"!=":6,"===":6,"!==":6,"<":7,">":7,"<=":7,">=":7,"<<":8,">>":8,">>>":8,"+":9,"-":9,"*":10,"/":10,"%":10,"**":11},right_associative:new Set(["**"]),additional_identifier_chars:new Set(["$","_"]),literals:{true:!0,false:!1,null:null},this_str:"this"});C.max_unop_len=C.getMaxKeyLen(C.unary_ops);C.max_binop_len=C.getMaxKeyLen(C.binary_ops);const kt=r=>new C(r).parse(),w1=Object.getOwnPropertyNames(class{});Object.getOwnPropertyNames(C).filter(r=>!w1.includes(r)&&kt[r]===void 0).forEach(r=>{kt[r]=C[r]});kt.Jsep=C;const y1="ConditionalExpression";var E1={name:"ternary",init(r){r.hooks.add("after-expression",function(t){if(t.node&&this.code===r.QUMARK_CODE){this.index++;const i=t.node,o=this.gobbleExpression();if(o||this.throwError("Expected expression"),this.gobbleSpaces(),this.code===r.COLON_CODE){this.index++;const l=this.gobbleExpression();if(l||this.throwError("Expected expression"),t.node={type:y1,test:i,consequent:o,alternate:l},i.operator&&r.binary_ops[i.operator]<=.9){let u=i;for(;u.right.operator&&r.binary_ops[u.right.operator]<=.9;)u=u.right;t.node.test=u.right,u.right=t.node,t.node=i}}else this.throwError("Expected :")}})}};kt.plugins.register(E1);const bf=47,S1=92;var A1={name:"regex",init(r){r.hooks.add("gobble-token",function(t){if(this.code===bf){const i=++this.index;let o=!1;for(;this.index<this.expr.length;){if(this.code===bf&&!o){const l=this.expr.slice(i,this.index);let u="";for(;++this.index<this.expr.length;){const p=this.code;if(p>=97&&p<=122||p>=65&&p<=90||p>=48&&p<=57)u+=this.char;else break}let d;try{d=new RegExp(l,u)}catch(p){this.throwError(p.message)}return t.node={type:r.LITERAL,value:d,raw:this.expr.slice(i-1,this.index)},t.node=this.gobbleTokenProperty(t.node),t.node}this.code===r.OBRACK_CODE?o=!0:o&&this.code===r.CBRACK_CODE&&(o=!1),this.index+=this.code===S1?2:1}this.throwError("Unclosed Regex")}})}};const sl=43,T1=45,_n={name:"assignment",assignmentOperators:new Set(["=","*=","**=","/=","%=","+=","-=","<<=",">>=",">>>=","&=","^=","|=","||=","&&=","??="]),updateOperators:[sl,T1],assignmentPrecedence:.9,init(r){const e=[r.IDENTIFIER,r.MEMBER_EXP];_n.assignmentOperators.forEach(i=>r.addBinaryOp(i,_n.assignmentPrecedence,!0)),r.hooks.add("gobble-token",function(o){const l=this.code;_n.updateOperators.some(u=>u===l&&u===this.expr.charCodeAt(this.index+1))&&(this.index+=2,o.node={type:"UpdateExpression",operator:l===sl?"++":"--",argument:this.gobbleTokenProperty(this.gobbleIdentifier()),prefix:!0},(!o.node.argument||!e.includes(o.node.argument.type))&&this.throwError(`Unexpected ${o.node.operator}`))}
119),r.hooks.add("after-token",function(o){if(o.node){const l=this.code;_n.updateOperators.some(u=>u===l&&u===this.expr.charCodeAt(this.index+1))&&(e.includes(o.node.type)||this.throwError(`Unexpected ${o.node.operator}`),this.index+=2,o.node={type:"UpdateExpression",operator:l===sl?"++":"--",argument:o.node,prefix:!1})}}),r.hooks.add("after-expression",function(o){o.node&&t(o.node)});function t(i){_n.assignmentOperators.has(i.operator)?(i.type="AssignmentExpression",t(i.left),t(i.right)):i.operator||Object.values(i).forEach(o=>{o&&typeof o=="object"&&t(o)})}}};kt.plugins.register(A1,_n);kt.addUnaryOp("typeof");kt.addUnaryOp("void");kt.addLiteral("null",null);kt.addLiteral("undefined",void 0);const O1=new Set(["constructor","__proto__","__defineGetter__","__defineSetter__","__lookupGetter__","__lookupSetter__"]),me={evalAst(r,e){switch(r.type){case"BinaryExpression":case"LogicalExpression":return me.evalBinaryExpression(r,e);case"Compound":return me.evalCompound(r,e);case"ConditionalExpression":return me.evalConditionalExpression(r,e);case"Identifier":return me.evalIdentifier(r,e);case"Literal":return me.evalLiteral(r,e);case"MemberExpression":return me.evalMemberExpression(r,e);case"UnaryExpression":return me.evalUnaryExpression(r,e);case"ArrayExpression":return me.evalArrayExpression(r,e);case"CallExpression":return me.evalCallExpression(r,e);case"AssignmentExpression":return me.evalAssignmentExpression(r,e);default:throw SyntaxError("Unexpected expression",r)}},evalBinaryExpression(r,e){return{"||":(i,o)=>i||o(),"&&":(i,o)=>i&&o(),"|":(i,o)=>i|o(),"^":(i,o)=>i^o(),"&":(i,o)=>i&o(),"==":(i,o)=>i==o(),"!=":(i,o)=>i!=o(),"===":(i,o)=>i===o(),"!==":(i,o)=>i!==o(),"<":(i,o)=>i<o(),">":(i,o)=>i>o(),"<=":(i,o)=>i<=o(),">=":(i,o)=>i>=o(),"<<":(i,o)=>i<<o(),">>":(i,o)=>i>>o(),">>>":(i,o)=>i>>>o(),"+":(i,o)=>i+o(),"-":(i,o)=>i-o(),"*":(i,o)=>i*o(),"/":(i,o)=>i/o(),"%":(i,o)=>i%o()}[r.operator](me.evalAst(r.left,e),()=>me.evalAst(r.right,e))},evalCompound(r,e){let t;for(let i=0;i<r.body.length;i++){r.body[i].type==="Identifier"&&["var","let","const"].includes(r.body[i].name)&&r.body[i+1]&&r.body[i+1].type==="AssignmentExpression"&&(i+=1);const o=r.body[i];t=me.evalAst(o,e)}return t},evalConditionalExpression(r,e){return me.evalAst(r.test,e)?me.evalAst(r.consequent,e):me.evalAst(r.alternate,e)},evalIdentifier(r,e){if(Object.hasOwn(e,r.name))return e[r.name];throw ReferenceError(`${r.name} is not defined`)},evalLiteral(r){return r.value},evalMemberExpression(r,e){const t=String(r.computed?me.evalAst(r.property):r.property.name),i=me.evalAst(r.object,e);if(i==null)throw TypeError(`Cannot read properties of ${i} (reading '${t}')`);if(!Object.hasOwn(i,t)&&O1.has(t))throw TypeError(`Cannot read properties of ${i} (reading '${t}')`);const o=i[t];return typeof o=="function"?o.bind(i):o},evalUnaryExpression(r,e){return{"-":i=>-me.evalAst(i,e),"!":i=>!me.evalAst(i,e),"~":i=>~me.evalAst(i,e),"+":i=>+me.evalAst(i,e),typeof:i=>typeof me.evalAst(i,e),void:i=>void me.evalAst(i,e)}[r.operator](r.argument)},evalArrayExpression(r,e){return r.elements.map(t=>me.evalAst(t,e))},evalCallExpression(r,e){const t=r.arguments.map(o=>me.evalAst(o,e)),i=me.evalAst(r.callee,e);if(i===Function)throw new Error("Function constructor is disabled");return i(...t)},evalAssignmentExpression(r,e){if(r.left.type!=="Identifier")throw SyntaxError("Invalid left-hand side in assignment");const t=r.left.name,i=me.evalAst(r.right,e);return e[t]=i,e[t]}};class C1{constructor(e){this.code=e,this.ast=kt(this.code)}runInNewContext(e){const t=Object.assign(Object.create(null),e);return me.evalAst(this.ast,t)}}function ur(r,e){return r=r.slice(),r.push(e),r}function Ml(r,e){return e=e.slice(),e.unshift(r),e}class I1 extends Error{constructor(e){super('JSONPath should not be called with "new" (it prevents return of (unwrapped) scalar values)'),this.avoidNew=!0,this.value=e,this.name="NewError"}}function de(r,e,t,i,o){if(!(this instanceof de))try{return new de(r,e,t,i,o)}catch(u){if(!u.avoidNew)throw u;return u.value}typeof r=="string"&&(o=i,i=t,t=e,e=r,r=null);const l=r&&typeof r=="object";if(r=r||{},this.json=r.json||t,this.path=r.path||e,this.resultType=r.resultType||"value",this.flatten=r.flatten||!1,this.wrap=Object.hasOwn(r,"wrap")?r.wrap:!0,this.sandbox=r.sandbox||{},this.eval=r.eval===void 0?"safe":r.eval,this.ignoreEvalErrors=typeof r.ignoreEvalErrors>"u"?!1:r.ignoreEvalErrors,this.parent=r.parent||null,this.parentProperty=r.parentProperty||null,this.callback=r.callback||i||null,this.otherTypeCallback=r.otherTypeCallback||o||function(){throw new TypeError("You must supply an otherTypeCallback callback option with the @other() operator.")},r.autostart!==!1){const u={path:l?r.path:e};l?"json"in r&&(u.json=r.json):u.json=t;const d=this.evaluate(u);if(!d||typeof d!="object")throw new I1(d);return d}}de.prototype.evaluate=function(r,e,t,i){let o=this.parent,l=this.parentProperty,{flatten:u,wrap:d}=this;if(this.currResultType=this.resultType,this.currEval=this.eval,this.currSandbox=this.sandbox,t=t||this.callback,this.currOtherTypeCallback=i||this.otherTypeCallback,e=e||this.json,r=r||this.path,r&&typeof r=="object"&&!Array.isArray(r)){if(!r.path&&r.path!=="")throw new TypeError('You must supply a "path" property when providing an object argument to JSONPath.evaluate().');if(!Object.hasOwn(r,"json"))throw new TypeError('You must supply a "json" property when providing an object argument to JSONPath.evaluate().');({json:e}=r),u=Object.hasOwn(r,"flatten")?r.flatten:u,this.currResultType=Object.hasOwn(r,"resultType")?r.resultType:this.currResultType,this.currSandbox=Object.hasOwn(r,"sandbox")?r.sandbox:this.currSandbox,d=Object.hasOwn(r,"wrap")?r.wrap:d,this.currEval=Object.hasOwn(r,"eval")?r.eval:this.currEval,t=Object.hasOwn(r,"callback")?r.callback:t,this.currOtherTypeCallback=Object.hasOwn(r,"otherTypeCallback")?r.otherTypeCallback:this.currOtherTypeCallback,o=Object.hasOwn(r,"parent")?r.parent:o,l=Object.hasOwn(r,"parentProperty")?r.parentProperty:l,r=r.path}if(o=o||null,l=l||null,Array.isArray(r)&&(r=de.toPathString(r)),!r&&r!==""||!e)return;const p=de.toPathArray(r);p[0]==="$"&&p.length>1&&p.shift(),this._hasParentSelector=null;const v=this._trace(p,e,["$"],o,l,t).filter(function(S){return S&&!S.isParentSelector});return v.length?!d&&v.length===1&&!v[0].hasArrExpr?this._getPreferredOutput(v[0]):v.reduce((S,O)=>{const k=this._getPreferredOutput(O);return u&&Array.isArray(k)?S=S.concat(k):S.push(k),S},[]):d?[]:void 0};de.prototype._getPreferredOutput=function(r){const e=this.currResultType;switch(e){case"all":{const t=Array.isArray(r.path)?r.path:de.toPathArray(r.path);return r.pointer=de.toPointer(t),r.path=typeof r.path=="string"?r.path:de.toPathString(r.path),r}case"value":case"parent":case"parentProperty":return r[e];case"path":return de.toPathString(r[e]);case"pointer":return de.toPointer(r.path);default:throw new TypeError("Unknown result type")}};de.prototype._handleCallback=function(r,e,t){if(e){const i=this._getPreferredOutput(r);r.path=typeof r.path=="string"?r.path:de.toPathString(r.path),e(i,t,r)}};de.prototype._trace=function(r,e,t,i,o,l,u,d){let p;if(!r.length)return p={path:t,value:e,parent:i,parentProperty:o,hasArrExpr:u},this._handleCallback(p,l,"value"),p;const v=r[0],S=r.slice(1),O=[];function k(D){Array.isArray(D)?D.forEach(N=>{O.push(N)}):O.push(D)}if((typeof v!="string"||d)&&e&&Object.hasOwn(e,v))k(this._trace(S,e[v],ur(t,v),e,v,l,u));else if(v==="*")this._walk(e,D=>{k(this._trace(S,e[D],ur(t,D),e,D,l,!0,!0))});else if(v==="..")k(this._trace(S,e,t,i,o,l,u)),this._walk(e,D=>{typeof e[D]=="object"&&k(this._trace(r.slice(),e[D],ur(t,D),e,D,l,!0))});else{if(v==="^")return this._hasParentSelector=!0,{path:t.slice(0,-1),expr:S,isParentSelector:!0};if(v==="~")return p={path:ur(t,v),value:o,parent:i,parentProperty:null},this._handleCallback(p,l,"property"),p;
119if(v==="$")k(this._trace(S,e,t,null,null,l,u));else if(/^(-?\d*):(-?\d*):?(\d*)$/u.test(v))k(this._slice(v,S,e,t,i,o,l));else if(v.indexOf("?(")===0){if(this.currEval===!1)throw new Error("Eval [?(expr)] prevented in JSONPath expression.");const D=v.replace(/^\?\((.*?)\)$/u,"$1"),N=/@.?([^?]*)[['](\??\(.*?\))(?!.\)\])[\]']/gu.exec(D);N?this._walk(e,B=>{const V=[N[2]],H=N[1]?e[B][N[1]]:e[B];this._trace(V,H,t,i,o,l,!0).length>0&&k(this._trace(S,e[B],ur(t,B),e,B,l,!0))}):this._walk(e,B=>{this._eval(D,e[B],B,t,i,o)&&k(this._trace(S,e[B],ur(t,B),e,B,l,!0))})}else if(v[0]==="("){if(this.currEval===!1)throw new Error("Eval [(expr)] prevented in JSONPath expression.");k(this._trace(Ml(this._eval(v,e,t.at(-1),t.slice(0,-1),i,o),S),e,t,i,o,l,u))}else if(v[0]==="@"){let D=!1;const N=v.slice(1,-2);switch(N){case"scalar":(!e||!["object","function"].includes(typeof e))&&(D=!0);break;case"boolean":case"string":case"undefined":case"function":typeof e===N&&(D=!0);break;case"integer":Number.isFinite(e)&&!(e%1)&&(D=!0);break;case"number":Number.isFinite(e)&&(D=!0);break;case"nonFinite":typeof e=="number"&&!Number.isFinite(e)&&(D=!0);break;case"object":e&&typeof e===N&&(D=!0);break;case"array":Array.isArray(e)&&(D=!0);break;case"other":D=this.currOtherTypeCallback(e,t,i,o);break;case"null":e===null&&(D=!0);break;default:throw new TypeError("Unknown value type "+N)}if(D)return p={path:t,value:e,parent:i,parentProperty:o},this._handleCallback(p,l,"value"),p}else if(v[0]==="`"&&e&&Object.hasOwn(e,v.slice(1))){const D=v.slice(1);k(this._trace(S,e[D],ur(t,D),e,D,l,u,!0))}else if(v.includes(",")){const D=v.split(",");for(const N of D)k(this._trace(Ml(N,S),e,t,i,o,l,!0))}else!d&&e&&Object.hasOwn(e,v)&&k(this._trace(S,e[v],ur(t,v),e,v,l,u,!0))}if(this._hasParentSelector)for(let D=0;D<O.length;D++){const N=O[D];if(N&&N.isParentSelector){const B=this._trace(N.expr,e,N.path,i,o,l,u);if(Array.isArray(B)){O[D]=B[0];const V=B.length;for(let H=1;H<V;H++)D++,O.splice(D,0,B[H])}else O[D]=B}}return O};de.prototype._walk=function(r,e){if(Array.isArray(r)){const t=r.length;for(let i=0;i<t;i++)e(i)}else r&&typeof r=="object"&&Object.keys(r).forEach(t=>{e(t)})};de.prototype._slice=function(r,e,t,i,o,l,u){if(!Array.isArray(t))return;const d=t.length,p=r.split(":"),v=p[2]&&Number.parseInt(p[2])||1;let S=p[0]&&Number.parseInt(p[0])||0,O=p[1]&&Number.parseInt(p[1])||d;S=S<0?Math.max(0,S+d):Math.min(d,S),O=O<0?Math.max(0,O+d):Math.min(d,O);const k=[];for(let D=S;D<O;D+=v)this._trace(Ml(D,e),t,i,o,l,u,!0).forEach(B=>{k.push(B)});return k};de.prototype._eval=function(r,e,t,i,o,l){this.currSandbox._$_parentProperty=l,this.currSandbox._$_parent=o,this.currSandbox._$_property=t,this.currSandbox._$_root=this.json,this.currSandbox._$_v=e;const u=r.includes("@path");u&&(this.currSandbox._$_path=de.toPathString(i.concat([t])));const d=this.currEval+"Script:"+r;if(!de.cache[d]){let p=r.replaceAll("@parentProperty","_$_parentProperty").replaceAll("@parent","_$_parent").replaceAll("@property","_$_property").replaceAll("@root","_$_root").replaceAll(/@([.\s)[])/gu,"_$_v$1");if(u&&(p=p.replaceAll("@path","_$_path")),this.currEval==="safe"||this.currEval===!0||this.currEval===void 0)de.cache[d]=new this.safeVm.Script(p);else if(this.currEval==="native")de.cache[d]=new this.vm.Script(p);else if(typeof this.currEval=="function"&&this.currEval.prototype&&Object.hasOwn(this.currEval.prototype,"runInNewContext")){const v=this.currEval;de.cache[d]=new v(p)}else if(typeof this.currEval=="function")de.cache[d]={runInNewContext:v=>this.currEval(p,v)};else throw new TypeError(`Unknown "eval" property "${this.currEval}"`)}try{return de.cache[d].runInNewContext(this.currSandbox)}catch(p){if(this.ignoreEvalErrors)return!1;throw new Error("jsonPath: "+p.message+": "+r)}};de.cache={};de.toPathString=function(r){const e=r,t=e.length;let i="$";for(let o=1;o<t;o++)/^(~|\^|@.*?\(\))$/u.test(e[o])||(i+=/^[0-9*]+$/u.test(e[o])?"["+e[o]+"]":"['"+e[o]+"']");return i};de.toPointer=function(r){const e=r,t=e.length;let i="";for(let o=1;o<t;o++)/^(~|\^|@.*?\(\))$/u.test(e[o])||(i+="/"+e[o].toString().replaceAll("~","~0").replaceAll("/","~1"));return i};de.toPathArray=function(r){const{cache:e}=de;if(e[r])return e[r].concat();const t=[],o=r.replaceAll(/@(?:null|boolean|number|string|integer|undefined|non
119Finite|scalar|array|object|function|other)\(\)/gu,";$&;").replaceAll(/[['](\??\(.*?\))[\]'](?!.\])/gu,function(l,u){return"[#"+(t.push(u)-1)+"]"}).replaceAll(/\[['"]([^'\]]*)['"]\]/gu,function(l,u){return"['"+u.replaceAll(".","%@%").replaceAll("~","%%@@%%")+"']"}).replaceAll("~",";~;").replaceAll(/['"]?\.['"]?(?![^[]*\])|\[['"]?/gu,";").replaceAll("%@%",".").replaceAll("%%@@%%","~").replaceAll(/(?:;)?(\^+)(?:;)?/gu,function(l,u){return";"+u.split("").join(";")+";"}).replaceAll(/;;;|;;/gu,";..;").replaceAll(/;$|'?\]|'$/gu,"").split(";").map(function(l){const u=l.match(/#(\d+)/u);return!u||!u[1]?l:t[u[1]]});return e[r]=o,e[r].concat()};de.prototype.safeVm={Script:C1};const L1=function(r,e,t){const i=r.length;for(let o=0;o<i;o++){const l=r[o];t(l)&&e.push(r.splice(o--,1)[0])}};class R1{constructor(e){this.code=e}runInNewContext(e){let t=this.code;const i=Object.keys(e),o=[];L1(i,o,v=>typeof e[v]=="function");const l=i.map(v=>e[v]);t=o.reduce((v,S)=>{let O=e[S].toString();return/function/u.test(O)||(O="function "+O),"var "+S+"="+O+";"+v},"")+t,!/(['"])use strict\1/u.test(t)&&!i.includes("arguments")&&(t="var arguments = undefined;"+t),t=t.replace(/;\s*$/u,"");const d=t.lastIndexOf(";"),p=d!==-1?t.slice(0,d+1)+" return "+t.slice(d+1):" return "+t;return new Function(...i,p)(...l)}}de.prototype.vm={Script:R1};var og;const P1={property:"profile.product_subscriptions",assert:"includes",value:((og=window.hopp)==null?void 0:og.id)||null},Dl="includes",$l="equals",x1=[Dl,$l];class Fl{constructor(e,t=(i=>(i=window.hopp)==null?void 0:i.subscriptionVerification)()||P1){if(!t.property||typeof t.property!="string"||!t.assert||!x1.includes(t.assert)||t.assert===$l&&!t.value)throw new Error("Invalid subscription verification configuration");this.user=e,this.subscriptionVerification=t}hasSubscription(e=this.subscriptionVerification.value){const{user:t}=this;if(!t)return!1;const{property:i,assert:o}=this.subscriptionVerification,l=i.substr(0,1)!=="$"?`$.${i}`:i;let u=Array.isArray(e)?e:(e==null?void 0:e.split(/\s*,\s*/))||[],d=de({path:l,json:this.user});return Array.isArray(d)&&d.length===1&&Array.isArray(d[0])&&(d=d[0]),o===Dl&&u.length?Array.isArray(d)&&d.some(p=>u.includes(p)):o===Dl?Array.isArray(d)&&d.length!==0:o===$l?u&&u.includes(d):!1}hasSimpleSubscription(){return!!this.subscriptionVerification.value&&this.hasSubscription()}get signedIn(){return!!this.user}get subscriptions(){return hi(this.user,["profile","product_subscriptions"])||[]}get subscriber(){return this.hasSubscription()}get name(){return hi(this.user,["profile","name"])||hi(this.user,["profile","email"])}get accessToken(){return hi(this.user,["access_token"])}get sub(){return hi(this.user,["profile","sub"])}}const k1={response_type:"code",scope:"openid profile email",accessTokenExpiringNotificationTimeInSeconds:60,filterProtocolClaims:!1,monitorSession:!1,loadUserInfo:!0,userStore:new Ic({store:window.localStorage})};var ag;const Qt=new m1({...k1,...(ag=window.hopp)==null?void 0:ag.userManager});Qt.events.addUserLoaded(()=>{om()});async function kn(){const r=await Qt.getUser();return new Fl(r)}let _f=null,ol=null;async function om(){var u,d;const r=await kn(),{accessToken:e,sub:t}=_f||{},{accessToken:i,sub:o}=r,l=(d=(u=window.hopp)==null?void 0:u.userManager)==null?void 0:d.store_token_uri;return!i||!o?Promise.reject():l?((!ol||i!==e||o!==t)&&(_f={accessToken:i,sub:o},ol=new Promise(async(p,v)=>{try{const S=new URL(l,window.location);S.searchParams.set("token",i),S.searchParams.set("sub",o);const O=await fetch(S,{credentials:"same-origin",mode:"same-origin",method:"post"});if(!O.ok)throw new Error(`${O.status} ${O.statusText}`);p()}catch(S){v(S)}})),ol):Promise.resolve()}const al="hidden",M1=3e3,D1=1,wf=365,mn="true",$1="Escape",F1="Tab",N1=80;let $r=null,yf=null,Ef=null;const pi=[],am="dialog",lm='[data-controller~="dialog"]';function Nl(r){clearTimeout(yf),yf=setTimeout(B1,r?0:1e3)}function B1(){if(pi.length){const r=pi.sort((i,o)=>i.delay-o.delay);if($r&&($r.controller.isOpen||$r.delay<=r[0].delay)){Nl();return}clearTimeout(Ef),$r=r[0];const{controller:e,delay:t}=$r;Ef=setTimeout(()=>{pi.splice(pi.indexOf($r),1),e.open({onClose(){$r=null,Nl()}})},t)}}function U1(r,e){pi.push({controller:r,delay:e}),Nl(!0)}class cm extends he{constructor(){super(...arguments);y(this,"initialScrollPosition",0)}initialize(){this.keydownHandler=this.keydownHandler.bind(this),this.scrollHandler=Pk(this.scrollHandler.bind(this),100)}connect(){this.rememberSetting=this.rememberValue,this.rememberCookieName=this.rememberCookieNameValue,this.rememberCookieExpires=this.rememberCookieExpiresValue,this.rememberMaxDismissals=this.rememberMaxDismissalsValue;const t=this.autoOpenValue;let i=M1;t&&t.match(/^[0-9]+$/)&&(i=parseInt(t,10)),this.autoOpenSetting=t,this.autoOpenDelay=i,this.skipAutoOpenForSubscriber=this.skipAutoOpenForSubscriberValue,this.skipAutoOpenForUtmSource=this.skipAutoOpenForUtmSourceValue,this.closeOnScroll=this.closeOnScrollValue,this.modal=this.modalValue,window.addEventListener("keydown",this.keydownHandler,!0),this.closeOnScroll&&window.addEventListener("scroll",this.scrollHandler),this.prepareAutoOpen(),this.openOnBeforeInstallPromptValue&&this.prepareBeforeInstallPrompt()}disconnect(){window.removeEventListener("keydown",this.keydownHandler,!0),window.removeEventListener("scroll",this.scrollHandler),this.autoOpenReference&&clearTimeout(this.autoOpenReference),this.beforeInstallPromptHandler&&window.removeEventListener("beforeinstallprompt",this.beforeInstallPromptHandler)}keydownHandler(t){if(!this.isOpen)return;const{element:i,modal:o}=this,{key:l,shiftKey:u}=t,{activeElement:d}=document,p=Array.from(i.querySelectorAll(Mk)).filter(O=>!O.closest(Dk)),v=p[0],S=p[p.length-1];l===$1?(t.preventDefault(),this.close()):l===F1&&o&&(u?d===v&&(S.focus(),t.preventDefault()):d===S?(v.focu
119s(),t.preventDefault()):i.contains(d)||(v.focus(),t.preventDefault()))}scrollHandler(){const{initialScrollPosition:t,isOpen:i}=this;if(!i)return;Math.abs(window.scrollY-t)/window.innerHeight*100>=N1&&this.close()}async prepareBeforeInstallPrompt(){const{skipAutoOpenForSubscriber:t,rememberSetting:i,rememberCookieName:o}=this;if(t){const{subscriber:l}=await kn();if(l)return}i&&o&&ft.get(o)===mn||(this.beforeInstallPromptHandler=l=>{this.rememberSetting&&this.rememberCookieName&&ft.get(this.rememberCookieName)===mn||(l.preventDefault(),this.deferredInstallPrompt=l,this.open())},window.addEventListener("beforeinstallprompt",this.beforeInstallPromptHandler))}async prepareAutoOpen(){const{autoOpenSetting:t,autoOpenDelay:i,skipAutoOpenForSubscriber:o,skipAutoOpenForUtmSource:l,rememberSetting:u,rememberCookieName:d}=this;if(!(!t||this.openOnBeforeInstallPromptValue)){if(o){const{subscriber:p}=await kn();if(p)return}if(l){const p=new RegExp(`\\butm_source=${l}\\b`,"i");if(window.location.search.match(p)){this.remember();return}}u&&d&&ft.get(d)===mn||U1(this,i)}}autoOpen(){const{autoOpenDelay:t}=this;this.autoOpenReference=setTimeout(()=>{this.open()},t)}open({onClose:t}={}){const{element:i}=this;if(this.initialScrollPosition=window.scrollY,i.removeAttribute(al),i.focus(),this.hasIdValue){const o=new CustomEvent(Xs,{detail:{id:this.idValue}});window.dispatchEvent(o)}this.onClose=t}close(){const{element:t}=this;if(this.setCookie(),t.setAttribute(al,!0),this.hasIdValue){const i=new CustomEvent(jp,{detail:{id:this.idValue}});window.dispatchEvent(i)}this.onClose&&(this.onClose(),delete this.onClose)}remember(){this.setCookie()}rememberPermanently(){const{rememberSetting:t,rememberCookieName:i}=this;t&&i&&ft.set(i,mn,wf)}async installPwa(){this.deferredInstallPrompt&&(window.dispatchEvent(new CustomEvent(Wp)),await this.deferredInstallPrompt.prompt(),this.deferredInstallPrompt=null,this.close())}setCookie(){const{rememberSetting:t,rememberCookieName:i,rememberCookieExpires:o,rememberMaxDismissals:l}=this;if(!t||!i)return;if(!l){ft.set(i,mn,o);return}const u=`${i}-count`,d=(parseInt(ft.get(u),10)||0)+1;d>=l?this.rememberPermanently():(ft.set(u,String(d),wf),ft.set(i,mn,o))}get isOpen(){return!this.element.hasAttribute(al)}}y(cm,"values",{autoOpen:String,remember:Boolean,rememberCookieName:String,rememberCookieExpires:{type:Number,default:D1},rememberMaxDismissals:{type:Number,default:0},skipAutoOpenForSubscriber:Boolean,skipAutoOpenForUtmSource:String,closeOnScroll:Boolean,id:String,modal:{type:Boolean,default:!0},openOnBeforeInstallPrompt:Boolean});const H1=Object.freeze(Object.defineProperty({__proto__:null,DIALOG_IDENTIFIER:am,DIALOG_SELECTOR:lm,default:cm},Symbol.toStringTag,{value:"Module"}));class co extends he{constructor(){super(...arguments);y(this,"impressionEventName","ad_impression");y(this,"clickEventName","ad_click");y(this,"openLinkInNewWindow",!0);y(this,"positionParentAttribute","data-ad-position");y(this,"adIdEventKey","adId");y(this,"adPositionEventKey","adPosition");y(this,"breakpointMatch",null);y(this,"originalHref",null);y(this,"dialog",null)}initialize(){this.dialogOpenedHandler=this.dialogOpenedHandler.bind(this),this.clickHandler=this.clickHandler.bind(this),this.observeHandler=this.observeHandler.bind(this),this.resizeHandler=this.resizeHandler.bind(this),this.debouncedRender=xn(()=>requestAnimationFrame(()=>this.render()),100)}connect(){if(this.element.addEventListener("click",this.clickHandler,!1),!this.linkTargets.find(o=>o.offsetParent!==null))return;const i=this.element.closest(lm);this.dialog=this.application.getControllerForElementAndIdentifier(i,am),this.dialog&&(this.dialog.isOpen?this.trackImpression():window.addEventListener(Xs,this.dialogOpenedHandler)),this.dialog||(this.observer=new IntersectionObserver(this.observeHandler),this.observer.observe(this.element)),this.hasBreakpointValue&&window.addEventListener("resize",this.resizeHandler,!1),this.mobileHrefValue&&(this.originalHref=this.linkTarget.getAttribute("href")),this.render()}disconnect(){this.element.removeEventListener("click",this.clickHandler,!1),window.removeEventListener("resize",this.resizeHandler,!1),window.removeEventListener(Xs,this.dialogOpenedHandler)}
119dialogOpenedHandler({detail:t}){this.dialog&&this.dialog.idValue===t.id&&(this.trackImpression(),window.removeEventListener(Xs,this.dialogOpenedHandler))}observeHandler([t]){t.isIntersecting&&(this.observer.disconnect(),this.observer=null,this.trackImpression())}clickHandler(t){const i=t.target.closest("a");if(!i)return;const o=i.getAttribute("href"),l=Tc(i)?0:Ac;t.preventDefault(),df(this.clickEventName,this.eventData),this.openLinkInNewWindow?window.open(o):setTimeout(()=>{Eo(o)},l)}resizeHandler(){this.hasBreakpointValue&&this.debouncedRender()}processEventKey(t){return t.replace(/{{\s*id\s*}}/,this.idValue)}trackImpression(){df(this.impressionEventName,this.eventData,!1)}render(){const t=this.hasBreakpointValue&&window.matchMedia(this.breakpointValue).matches;if(this.breakpointMatch!==t&&(this.breakpointMatch=t,this.hasLinkTarget&&this.hasMobileHrefValue)){const{linkTarget:i,originalHref:o,mobileHrefValue:l}=this;t&&o?i.setAttribute("href",o):t||i.setAttribute("href",l)}}async openAdInfoDialog(t){const{adTargetTemplateId:i,adDialogLabel:o}=t.currentTarget.dataset,l=El(document.querySelector(`[data-ad-template-id="${i}"]`).innerHTML),u=document.createElement("div");u.innerHTML=await Sk({content:l(),label:o,variants:["narrow","ad","negative"],autoOpen:1,onClose:()=>{u.parentNode&&document.body.removeChild(u)}}),document.body.appendChild(u)}get eventData(){var u;const t=this.idValue,i=this.positionValue||((u=this.element.closest(`[${this.positionParentAttribute}]`))==null?void 0:u.getAttribute(this.positionParentAttribute)),o=this.processEventKey(this.adIdEventKey),l=this.processEventKey(this.adPositionEventKey);return{[o]:t,[l]:i}}}y(co,"targets",["link"]),y(co,"values",{id:String,position:String,mobileHref:String,breakpoint:String});const q1=Object.freeze(Object.defineProperty({__proto__:null,default:co},Symbol.toStringTag,{value:"Module"}));class um extends he{connect(){if(new URLSearchParams(window.location.search).get("_silent")==="true"){Qt.signinSilentCallback();return}Qt.signinRedirectCallback().then(t=>{const i=new CustomEvent(Vp,{detail:{userInfo:t}});window.dispatchEvent(i),Eo(t.state.origin)}).catch(t=>{throw this.processingTarget.setAttribute("hidden",""),this.errorTarget.removeAttribute("hidden"),new Error(t)})}}y(um,"targets",["processing","error"]);const V1=Object.freeze(Object.defineProperty({__proto__:null,default:um},Symbol.toStringTag,{value:"Module"})),Sf=(r,e)=>{const t=r[e];return typeof t=="function"?t:(...i)=>{}},Af=(r,e,t)=>{let i=r;return t===!0?i=`${e.identifier}:${r}`:typeof t=="string"&&(i=`${t}:${r}`),i},Tf=(r,e,t)=>{const{bubbles:i,cancelable:o,composed:l}={bubbles:!0,cancelable:!0,composed:!0};return new CustomEvent(r,{bubbles:i,cancelable:o,composed:l,detail:t})};function ll(r){return r.replace(/(?:[_-])([a-z0-9])/g,(e,t)=>t.toUpperCase())}function j1(r,e){var t={};for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&e.indexOf(i)<0&&(t[i]=r[i]);if(r!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,i=Object.getOwnPropertySymbols(r);o<i.length;o++)e.indexOf(i[o])<0&&Object.prototype.propertyIsEnumerable.call(r,i[o])&&(t[i[o]]=r[i[o]]);return t}const cl={debug:!1,logger:console,dispatchEvent:!0,eventPrefix:!0};class W1{constructor(e,t={}){var i,o,l;this.log=(p,v)=>{this.debug&&(this.logger.groupCollapsed(`%c${this.controller.identifier} %c#${p}`,"color: #3B82F6","color: unset"),this.logger.log(Object.assign({controllerId:this.controllerId},v)),this.logger.groupEnd())},this.warn=p=>{this.logger.warn(`%c${this.controller.identifier} %c${p}`,"color: #3B82F6; font-weight: bold","color: unset")},this.dispatch=(p,v={})=>{if(this.dispatchEvent){const{event:S}=v,O=j1(v,["event"]),k=this.extendedEvent(p,S||null,O);this.targetElement.dispatchEvent(k),this.log("dispatchEvent",Object.assign({eventName:k.type},O))}},this.call=(p,v={})=>{const S=this.controller[p];if(typeof S=="function")return S.call(this.controller,v)},this.extendedEvent=(p,v,S)=>{const{bubbles:O,cancelable:k,composed:D}=v||{bubbles:!0,cancelable:!0,composed:!0};return v&&Object.assign(S,{originalEvent:v}),new CustomEvent(this.composeEventName(p),{bubbles:O,cancelable:k,composed:D,detail:S})},this.composeEventName=p=>{let v=p;return this.eventPrefix===!0?v=`${this.controller.identifier}:${p}`:typeof this.eventPrefix=="string"&&(v=`${this.eventPrefix}:${p}`),v},this.debug=(o=(i=t==null?void 0:t.debug)!==null&&i!==void 0?i:e.application.stimulusUseDebug)!==null&&o!==void 0?o:cl.debug,this.logger=(l=t==null?void 0:t.logger)!==null&&l!==void 0?l:cl.logger,this.controller=e,this.controllerId=e.element.i
119d||e.element.dataset.id,this.targetElement=(t==null?void 0:t.element)||e.element;const{dispatchEvent:u,eventPrefix:d}=Object.assign({},cl,t);Object.assign(this,{dispatchEvent:u,eventPrefix:d}),this.controllerInitialize=e.initialize.bind(e),this.controllerConnect=e.connect.bind(e),this.controllerDisconnect=e.disconnect.bind(e)}}class z1 extends he{}z1.debounces=[];const K1={dispatchEvent:!0,eventPrefix:!0,visibleAttribute:"isVisible"},hm=(r,e={})=>{const t=r,{dispatchEvent:i,eventPrefix:o,visibleAttribute:l}=Object.assign({},K1,e),u=(e==null?void 0:e.element)||t.element;t.intersectionElements||(t.intersectionElements=[]),t.intersectionElements.push(u);const d=E=>{const[A]=E;A.isIntersecting?v(A):u.hasAttribute(l)&&S(A)},p=new IntersectionObserver(d,e),v=E=>{if(u.setAttribute(l,"true"),Sf(t,"appear").call(t,E,p),i){const A=Af("appear",t,o),L=Tf(A,null,{controller:t,entry:E,observer:p});u.dispatchEvent(L)}},S=E=>{if(u.removeAttribute(l),Sf(t,"disappear").call(t,E,p),i){const A=Af("disappear",t,o),L=Tf(A,null,{controller:t,entry:E,observer:p});u.dispatchEvent(L)}},O=t.disconnect.bind(t),k=()=>{N(),O()},D=()=>{p.observe(u)},N=()=>{p.unobserve(u)},B=()=>t.intersectionElements.filter(E=>E.hasAttribute(l)).length===0,V=()=>t.intersectionElements.filter(E=>E.hasAttribute(l)).length===1,H=()=>t.intersectionElements.some(E=>E.hasAttribute(l)),x=()=>t.intersectionElements.every(E=>E.hasAttribute(l));return Object.assign(t,{isVisible:x,noneVisible:B,oneVisible:V,atLeastOneVisible:H,allVisible:x,disconnect:k}),D(),[D,N]},qs={mediaQueries:{},dispatchEvent:!0,eventPrefix:!0,debug:!1};class G1 extends W1{constructor(e,t={}){var i,o,l,u;if(super(e,t),this.matches=[],this.callback=d=>{const p=Object.keys(this.mediaQueries).find(O=>this.mediaQueries[O]===d.media);if(!p)return;const{media:v,matches:S}=d;this.changed({name:p,media:v,matches:S,event:d})},this.changed=d=>{const{name:p}=d;d.event&&(this.call(ll(`${p}_changed`),d),this.dispatch(`${p}:changed`,d),this.log(`media query "${p}" changed`,d)),d.matches?(this.call(ll(`is_${p}`),d),this.dispatch(`is:${p}`,d)):(this.call(ll(`not_${p}`),d),this.dispatch(`not:${p}`,d))},this.observe=()=>{Object.keys(this.mediaQueries).forEach(d=>{const p=this.mediaQueries[d],v=window.matchMedia(p);v.addListener(this.callback),this.matches.push(v),this.changed({name:d,media:p,matches:v.matches})})},this.unobserve=()=>{this.matches.forEach(d=>d.removeListener(this.callback))},this.controller=e,this.mediaQueries=(i=t.mediaQueries)!==null&&i!==void 0?i:qs.mediaQueries,this.dispatchEvent=(o=t.dispatchEvent)!==null&&o!==void 0?o:qs.dispatchEvent,this.eventPrefix=(l=t.eventPrefix)!==null&&l!==void 0?l:qs.eventPrefix,this.debug=(u=t.debug)!==null&&u!==void 0?u:qs.debug,!window.matchMedia){console.error("window.matchMedia() is not available");return}this.enhanceController(),this.observe()}enhanceController(){const e=this.controller.disconnect.bind(this.controller),t=()=>{this.unobserve(),e()};Object.assign(this.controller,{disconnect:t})}}const X1=(r,e={})=>{const t=new G1(r,e);return[t.observe,t.unobserve]};class Y1 extends he{}Y1.throttles=[];class dm extends he{constructor(){super(...arguments);y(this,"hasPlayed",!1);y(this,"intersecting",!1);y(this,"reducedMotion",!1)}initialize(){this.handleLoadedData=this.handleLoadedData.bind(this)}connect(){hm(this,{rootMargin:this.rootMarginValue}),X1(this,{mediaQueries:{reducedMotion:"(prefers-reduced-motion: reduce)"}})}disconnect(){this.element.removeEventListener("loadeddata",this.handleLoadedData)}isReducedMotion(){this.reducedMotion=!0,this.element.controls=!0,this.element.pause()}appear(){this.intersecting=!0,!this.reducedMotion&&(this.hasPlayed&&!this.element.loop||this.play())}disappear(){this.intersecting=!1,this.element.removeEventListener("loadeddata",this.handleLoadedData),this.element.pause()}play(){if(this.element.readyState>=HTMLMediaElement.HAVE_CURRENT_DATA){this.startPlayback();return}this.element.addEventListener("loadeddata",this.handleLoadedData,{once:!0})}handleLoadedData(){this.intersecting&&this.startPlayback()}startPlayback(){var t;this.hasPlayed=!0,(t=this.element.play())==null||t.catch(()=>{})}}y(dm,"values",{rootMargin:{type:String,default:"0px"}});const Q1=Object.freeze(Object.defineProperty({__proto__:null,default:dm},Symbol.toStringTag,{value:"Module"}));var Lc,vr,jr,be={};function Z1(r){return Object.assign(r,{autoCapturePageviews:r.autoCapturePageviews!==!1,logging:r.logging!==!1,bindToWindow:r.bindToWindow!==!1})}
119function J1(r){if(be.isInitialized)throw Error("plausible.init() can only be called once");if(!r||!r.domain)throw Error("plausible.init(): domain argument is required");r.endpoint||(r.endpoint="https://plausible.io/api/event"),Object.assign(be,r),be.isInitialized=!0}function fm(r,e,t){window.fetch&&fetch(r,{method:"POST",headers:{"Content-Type":"text/plain"},keepalive:!0,body:JSON.stringify(e)}).then(function(i){t&&t.callback&&t.callback({status:i.status})}).catch(function(i){t&&t.callback&&t.callback({error:i})})}var Bl=!1,gm=location.href,pm={},Ul=-1,Wr=0,Ai=0;function eM(){Bl&&(mm(),vr=mi(),jr=Hl())}function tM(r){Lc=!1,gm=r.u,pm=r.p,Ul=-1,Ai=0,Wr=Date.now(),nM()}function rM(){Lc=!0}function mm(){var r=vm();if(!Lc&&(Ul<jr||r>=3e3)){Ul=jr;var e={n:"engagement",sd:Math.round(jr/vr*100),d:be.domain,u:gm,p:pm,e:r,v:33};Wr=0,Ai=0,be.hashBasedRouting&&(e.h=1),fm(be.endpoint,e)}}function ul(){document.visibilityState==="visible"&&document.hasFocus()&&Wr===0?Wr=Date.now():document.visibilityState!=="hidden"&&document.hasFocus()||(Ai=vm(),Wr=0,mm())}function nM(){Bl||(document.addEventListener("visibilitychange",ul),window.addEventListener("blur",ul),window.addEventListener("focus",ul),Bl=!0)}function vm(){return Wr?Ai+(Date.now()-Wr):Ai}function mi(){var r=document.body||{},e=document.documentElement||{};return Math.max(r.scrollHeight||0,r.offsetHeight||0,r.clientHeight||0,e.scrollHeight||0,e.offsetHeight||0,e.clientHeight||0)}function Hl(){var r=document.body||{},e=document.documentElement||{},t=window.innerHeight||e.clientHeight||0,i=window.scrollY||e.scrollTop||r.scrollTop||0;return vr<=t?vr:i+t}function iM(){vr=mi(),jr=Hl(),window.addEventListener("load",function(){vr=mi();var r=0,e=setInterval(function(){vr=mi(),++r==15&&clearInterval(e)},200)}),document.addEventListener("scroll",function(){vr=mi();var r=Hl();r>jr&&(jr=r)})}function br(r,e){if(!be.isInitialized)throw Error("plausible.track() can only be called after plausible.init()");var t,i=r==="pageview";if(i&&eM(),!be.captureOnLocalhost){if(/^localhost$|^127(\.[0-9]+){0,2}\.[0-9]+$|^\[::1?\]$/.test(location.hostname)||location.protocol==="file:")return Vs(r,e,"localhost");if((window._phantom||window.__nightmare||window.navigator.webdriver||window.Cypress)&&!window.__plausible)return Vs(r,e)}
119try{if(window.localStorage.plausible_ignore==="true")return Vs(r,e,"localStorage flag")}catch{}var o={};o.n=r,o.v=33;var l=e&&(e.u||e.url);if(o.u=l||location.href,o.d=be.domain,o.r=document.referrer||null,e&&e.props&&(o.p=e.props),e&&e.interactive===!1&&(o.i=!1),e&&e.revenue&&(o.$=e.revenue),be.customProperties){var t=be.customProperties;typeof t=="function"&&(t=be.customProperties(r)),typeof t=="object"&&(o.p=Object.assign({},t,o.p))}if(be.hashBasedRouting&&(o.h=1),typeof be.transformRequest=="function"&&!(o=be.transformRequest(o)))return Vs(r,e,"transformRequest");i&&tM(o),fm(be.endpoint,o,e)}function Vs(r,e,t){t&&be.logging&&console.warn("Ignoring Event: "+t),e&&e.callback&&e.callback(),r==="pageview"&&rM()}var sM=["pdf","xlsx","docx","txt","rtf","csv","exe","key","pps","ppt","pptx","7z","pkg","rar","gz","zip","avi","mov","mp4","mpeg","wmv","midi","mp3","wav","wma","dmg"],bm=1,_m=3,wm=sM;function oM(r){for(;r&&(r.tagName===void 0||!ym(r)||!r.href);)r=r.parentNode;return r}function ym(r){return r&&r.tagName&&r.tagName.toLowerCase()==="a"}function Of(r){if(r.type!=="auxclick"||r.button===bm){var e=oM(r.target),t=e&&typeof e.href=="string"&&e.href.split("?")[0];if(!Pc(e,0)){if(be.outboundLinks&&aM(e))return ql(r,e,{name:"Outbound Link: Click",props:{url:e.href}});if(be.fileDownloads&&lM(t))return ql(r,e,{name:"File Download",props:{url:t}})}}}function ql(r,e,t){var i;(i={props:t.props}).revenue=t.revenue,br(t.name,i)}function aM(r){return r&&typeof r.href=="string"&&r.host&&r.host!==location.host}function lM(r){if(!r)return!1;var e=r.split(".").pop();return wm.some(function(t){return t===e})}function Rc(r){var e=r&&r.classList;if(e){for(var t=0;t<e.length;t++)if(e.item(t).match(/plausible-event-name(=|--)(.+)/))return!0}return!1}function Pc(r,e){return!!r&&!(e>_m)&&(!!Rc(r)||Pc(r.parentNode,e+1))}function Cf(r){var e=Rc(r)?r:r&&r.parentNode,t={name:null,props:{}};t.revenue={};var i=e&&e.classList;if(!i)return t;for(var o=0;o<i.length;o++){var l,u,d=i.item(o),p=d.match(/plausible-event-(.+)(=|--)(.+)/);p&&(l=p[1],u=p[3].replace(/\+/g," "),l.toLowerCase()=="name"?t.name=u:t.props[l]=u);var v=d.match(/plausible-revenue-(.+)(=|--)(.+)/);v&&(l=v[1],u=v[3],t.revenue[l]=u)}return t}function cM(){function r(e){if(e.type!=="auxclick"||e.button===bm){for(var t,i,o,l=e.target,u=0;u<=_m&&l;u++){if((t=l)&&t.tagName&&t.tagName.toLowerCase()==="form")return;ym(l)&&(i=l),Rc(l)&&(o=l),l=l.parentNode}if(o){var d=Cf(o);if(i)d.props.url=i.href,ql(e,i,d);else{var p={};p.props=d.props,p.revenue=d.revenue,br(d.name,p)}}}}document.addEventListener("click",Of),document.addEventListener("auxclick",Of),be.fileDownloads&&typeof be.fileDownloads=="object"&&Array.isArray(be.fileDownloads.fileExtensions)&&(wm=be.fileDownloads.fileExtensions),be.formSubmissions&&document.addEventListener("submit",function(e){(e.target.hasAttribute("novalidate")||e.target.checkValidity())&&(Pc(e.target,0)||br("Form: Submission"))},!0),document.addEventListener("submit",function(e){var t,i=Cf(e.target);i.name&&((t={props:i.props}).revenue=i.revenue,br(i.name,t))}),document.addEventListener("click",r),document.addEventListener("auxclick",r)}function uM(r){function e(u){(be.hashBasedRouting||!u||t!==location.pathname)&&(t=location.pathname,r("pageview"))}var t,i=function(){e(!0)};if(be.hashBasedRouting)window.addEventListener("hashchange",i);else{var o=window.history;if(o.pushState){var l=o.pushState;o.pushState=function(){l.apply(this,arguments),i()},window.addEventListener("popstate",i)}}document.visibilityState==="hidden"||document.visibilityState==="prerender"?document.addEventListener("visibilitychange",function(){t||document.visibilityState!=="visible"||e()}):e(),window.addEventListener("pageshow",function(u){u.persisted&&e()})}function hM(r){J1(Z1(r||{})),iM(),be.autoCapturePageviews&&uM(br),cM(),be.bindToWindow&&typeof window<"u"&&(window.plausible=br,window.plausible.s="npm",window.plausible.v=33,window.plausible.l=!0)}class dM{constructor(){y(this,"enabled",!1);var i,o,l,u;let e=null;(o=(i=window.hopp)==null?void 0:i.tracking)!=null&&o.plausibleDomain&&(e=window.hopp.tracking.plausibleDomain);const t=((u=(l=window.hopp)==null?void 0:l.tracking)==null?void 0:u.plausibleEndpoint)??Sc;this.plausibleDomain=e,this.plausibleEndpoint=t,e&&(this.enabled=!0)}initialize(){hM({domain:this.plausibleDomain,endpoint:this.plausibleEndpoint,autoCapturePageviews:!1,bindToWindow:!0})}trackPageView({pageUrl:e,pageType:t,pageId:i,pagePublicationDate:o,signedIn:l,subscriber:u,...d}){br("pageview",{url:e,props:{pageType:t,pageId:i,pagePublicationDate:o,signedIn:l,subscriber:u,...d}})}trackEvent({name:e,params:t}={}){br(e,{props:t})}}const fM="contentItem";function Em(r){return r?Object.keys(r.dataset).reduce((e,t)=>
119{if(!t.startsWith(fM))return e;const i=r.dataset[t];return i?{...e,[t]:i}:e},{}):{}}const Sm="arto-consent";let _r={signature:null};function gM(r){return r?1:0}function pM(r){return!!parseInt(r,10)}const To=(()=>{let r;return()=>{if(r)return r;r=[];const e=document.documentElement.dataset.consentCookieCategoriesValue;return e&&(r=e.split(/\s*,\s*/)),r}})();function mM(){return To().reduce((r,e)=>({...r,[e]:!1}),{})}function Am(){return!!To().length}function vM(r){if(!r)return{};try{return r.split(/\s*,\s*/).reduce((e,t)=>{const[i,o]=t.split(/\s*=\s*/);return{...e,[i]:o.match(/^\d+$/)?pM(o):o}},{})}catch{return{}}}function bM(){_r={..._r,...mM(),...vM(ft.get(Sm))},Tm()}function kF(r){const e={..._r};let t=!1;const i=Cm(Object.keys(r));_r={...e,...r,signature:i},Object.entries(_r).forEach(([o,l])=>{o!=="signature"&&l!==e[o]&&(t=!0)}),t&&Tm(),_M()}function Tm(){const r=new CustomEvent(Ys);window.dispatchEvent(r)}function _M(){const r=Object.entries(_r).reduce((e,[t,i])=>[...e,`${t}=${typeof i=="boolean"?gM(i):i}`],[]).join(",");ft.set(Sm,r,365)}function Om(){return _r.signature===Cm(To())}function Cm(r){return r.sort().reduce((e,t)=>`${e}${t[0]}${t.length}`,"")}function xc(r){return!!_r[r]}function wM(){return!Am()||Om()?Promise.resolve():new Promise(r=>{window.addEventListener(dk,()=>r(),{once:!0})})}window.artoConsentForCategory=xc;bM();const yM={plausible:{adapterModule:dM},ga:{loadAdapterModule:()=>nt(()=>import("./chunks/google-analytics-adapter.05aef2c3.js"),__vite__mapDeps([0,1])).then(r=>r.default)},matomo:{loadAdapterModule:()=>nt(()=>import("./chunks/matomo-adapter.9a80b705.js"),__vite__mapDeps([2,1])).then(r=>r.default)},smartocto:{loadAdapterModule:()=>nt(()=>import("./chunks/smartocto-adapter.8afbaa90.js"),__vite__mapDeps([3,1])).then(r=>r.default)}},EM=["/auth","/auth/*"],If="data-event-page-context",SM="[data-content-item-id]",Lf='[data-controller~="content-item"]',AM="browser",Rf="pwa",Pf={plausible:function(){var r,e;return!!((e=(r=window.hopp)==null?void 0:r.tracking)!=null&&e.plausibleDomain)},ga:function(){var r,e;return!!((e=(r=window.hopp)==null?void 0:r.tracking)!=null&&e.gaMeasurementId)},matomo:function(){var r,e,t,i;return!!((e=(r=window.hopp)==null?void 0:r.tracking)!=null&&e.matomoDomain&&((i=(t=window.hopp)==null?void 0:t.tracking)!=null&&i.matomoSiteId))},smartocto:function(){var r,e;return!!((e=(r=window.hopp)==null?void 0:r.tracking)!=null&&e.smartoctoDomainId)}},TM=(()=>{const t=EM.map(i=>{let o,l;return i.indexOf("*")!==-1?([o]=i.split("*"),l=1):(o=i,l=1),[o,l]});return i=>t.reduce((o,[l,u])=>o||(u===1?i.indexOf(l)===0:i===l),!1)})();function OM(){if(!Am())return null;const r=To().reduce((e,t)=>({...e,[`${t}Consent`]:xc(t)}),{});return{madeConsentChoice:Om(),...r}}function CM(){let r=AM;return(window.matchMedia("(display-mode: standalone)").matches||window.matchMedia("(display-mode: minimal-ui)").matches)&&(r=Rf),{displayContext:r}}function IM(r){let e;try{e=JSON.parse(r)}catch{e={}}return e}function LM(r){const{eventName:e,eventDomain:t,eventUrl:i}=r.dataset;let o=!1,l={},u={};if({includeContentItemData:o=!1,...l}=IM(r.dataset.eventData),o){const p=r.closest(SM);u=Em(p)}r instanceof HTMLMediaElement&&(l.mediaPlaybackProgress=`${Math.round(r.currentTime/r.duration*100)}%`);const d=r.closest(`[${If}]`);return d&&(l={...l,pageContext:d.getAttribute(If)}),{eventName:e,eventDomain:t,eventUrl:i,eventData:{...l,...u}}}async function Im(r=document.body){const e=(r==null?void 0:r.closest("[data-page-type]"))||r||document.body;await wM();const{signedIn:t,subscriber:i}=await kn(),o=`${window.location.pathname}${window.location.search}`,l=`${window.location.protocol}//${window.location.hostname}${o}`,u=e.getAttribute("data-page-type"),d=e.getAttribute("data-page-id"),p=e.getAttribute("data-page-publication-date"),v=r.closest(Lf)||document.querySelector(Lf);return{pagePath:o,pageUrl:l,pageType:u,pageId:d,pagePublicationDate:p,signedIn:t,subscriber:i,...OM(),...CM(),...Em(v)}}class RM{constructor(){y(this,"adaptersPromise",null);var e,t,i,o;this.plausibleEventTracker=new Kp({domain:((t=(e=window.hopp)==null?void 0:e.tracking)==null?void 0:t.plausibleDomain)??location.hostname,endpoint:((o=(i=window.hopp)==null?void 0:i.tracking)==null?void 0:o.plausibleEndpoint)??Sc}),this.adapters=Object.entries(yM).reduce((l,[u,{adapterModule:d,loadAdapterModule:p}])=>{let v;return typeof Pf[u]=="function"&&Pf[u]()===!0?(d?v=Promise.resolve(d):p&&(v=p()),[...l,v]):l},[])}async getAdapters(){return this.adaptersPromise||(this.adaptersPromise=Promise.all(this.adapters).then(e=>{const t=e.map(i=>new i);return t.forEach(i=>
119i.initialize()),t})),this.adaptersPromise}start(){["interactive","loaded","complete"].includes(window.document.readyState)?this.enablePageViewTracking():window.addEventListener("DOMContentLoaded",this.enablePageViewTracking.bind(this)),this.enableAppInstalledTracking()}enablePageViewTracking(){let e=!1;document.addEventListener("turbo:before-fetch-response",t=>{e=t.detail.fetchResponse.redirected}),document.addEventListener("turbo:load",t=>{var i;if(e||!((i=t.detail.timing)!=null&&i.visitStart)){e=!1;return}this.trackPageView()}),this.trackPageView()}enableAppInstalledTracking(){let e="native",t=!1;window.addEventListener(Wp,()=>{e="dialog"}),window.addEventListener("appinstalled",()=>{if(t){t=!1;return}this.trackEvent("appInstalled",{source:e}),e==="dialog"&&(t=!0),e="native"})}async trackPageView(e=document.body){const t=await this.getAdapters(),i=await Im(e);TM(i.pagePath)||t.forEach(o=>{o.trackPageView(i)})}async trackEvent(e,t,i={}){(await this.getAdapters()).forEach(l=>{l.trackEvent({name:e,params:t,pageDetails:i})})}}const Ti=new RM;async function Nr(r,e){let{eventName:t,eventDomain:i,eventUrl:o,eventData:l}=LM(r);if(e&&(t=e),!t)return;const u=await Im(r);if(i){Ti.plausibleEventTracker.trackEvent(t,{domain:i,url:o,referrer:location.href,props:l});return}Ti.trackEvent(t,l,u)}function PM(r,e){const t=r.target.closest("a");Tc(t)||e(t)===!1||!t.target&&!t.target.match(/^_(self|parent|top)$/i)&&!r.ctrlKey&&!r.metaKey&&!r.shiftKey&&(setTimeout(()=>{window.location.href=t.href},Ac),r.preventDefault())}const xM="data-requires-subscription",Lm="requiresSubscription",Vl="userHasAccess",kM="data-premium-content",MM="data-premium-content-uri",DM="premiumContentUri",xf="premiumProcessed";async function $M(r){const e=r.dataset[Lm];return e==null?!0:(await kn()).hasSubscription(e||null)}async function FM(r,e){e?r.dataset[Vl]="":delete r.dataset[Vl]}async function jl(r,e){if(!e&&(r.dataset[Lm]==null||r.dataset[xf]!=null))return;r.dataset[xf]="";const t=await $M(r);await FM(r,t);const i=r.querySelector(`[${MM}]`);t&&i&&await NM(i,t)}async function NM(r,e){if(!e)return;const t=r.dataset[DM];if(!t)return;const i=await kn(),{accessToken:o,sub:l}=i;if(!(!o||!l))try{await om();const u=new URL(t,window.location);u.searchParams.set("token",o),u.searchParams.set("sub",l);const d=await fetch(u,{credentials:"same-origin",mode:"same-origin"});if(!d.ok)throw new Error(`${d.status} ${d.statusText}`);const p=await d.text(),S=new DOMParser().parseFromString(p,"text/html").querySelector(`[${kM}]`);r.replaceWith(S)}catch(u){console.error(u),window.alert(await _i("premium.fetch_error"))}}async function BM(r){const{detail:{newBody:e,resume:t}}=r,i=e.querySelector(`[${xM}]`);i&&(r.preventDefault(),await jl(i),t())}function UM(){document.addEventListener("turbo:before-render",BM)}const MF='[data-controller~="content-item"]',HM="continuous-scroll",qM="nativeAd",VM="[data-content-item-click-ignore]";function jM(r){Oi.visibleContentItems.add(r)}function kf(r){Oi.visibleContentItems.delete(r)}const Sn=class Sn extends he{constructor(){super(...arguments);y(this,"turboRestorationIdentifier",null);y(this,"didVisit",!0);y(this,"inContinousScroll",!1)}initialize(){this.globalAppearHandler=this.globalAppearHandler.bind(this),this.globalDisappearHandler=this.globalDisappearHandler.bind(this),this.userStateChangedHandler=this.userStateChangedHandler.bind(this),this.nativeAdClickHandler=this.nativeAdClickHandler.bind(this)}connect(){const t=this.data.get("context");this.inContinousScroll=t===HM,this.inContinousScroll?this.didVisit=!1:(this.data.set("title",document.title),this.data.set("href",document.location.href)),document.addEventListener(uf,this.globalAppearHandler),document.addEventListener(hf,this.globalDisappearHandler),document.addEventListener(Al,this.userStateChangedHandler),hm(this,{rootMargin:this.rootMarginValue}),this.data.get("type")===qM&&this.element.addEventListener("click",this.nativeAdClickHandler,!1),jl(this.element)}disconnect(){var i,o,l;kf(this),document.removeEventListener(uf,this.globalAppearHandler),document.removeEventListener(hf,this.globalDisappearHandler),document.removeEventListener(Al,this.userStateChangedHandler),this.element.removeEventListener("click",this.nativeAdClickHandler,!1);const t=(l=(o=(i=Turbo==null?void 0:Turbo.navigator)==null?void 0:i.history)==null?void 0:o.restorationData)==null?void 0:l[this.turboRestorationIdentifier];this.inContinousScroll&&t&&delete t.scrollPosition}globalAppearHandler(){!this.inContinousScroll&&!this.isVisible()&&this.setAsInactive()}globalDisappearHandler(){!this.inContinousScroll&&!Sn.anyVisibleContentItems()&&document.contains(this.element)&&this.setAsActive()}userStateChangedHandler(t){const{userState:i,previousUserState:o}=t.detail;!i.loggedIn&&o.loggedIn&&jl(this.element,!0)}appear(){jM(this),this.setAsActive()}disappear(){kf(this),this.setAsInactive()}setAsActive(){var l,u;const t=(l=Turbo==null?void 0:Turbo.navigator)==null?void 0:l.history,i=this.data.get("title"),o=this.data.get("href");
119t&&o&&(document.title=i,t.replace({href:o}),this.turboRestorationIdentifier=(u=history.state.turbo)==null?void 0:u.restorationIdentifier),this.element.classList.remove(this.hidePrintClassNameValue),!this.didVisit&&(this.didVisit=!0,Ti.trackPageView(this.element))}setAsInactive(){this.element.classList.add(this.hidePrintClassNameValue)}nativeAdClickHandler(t){PM(t,i=>{if(i.closest(VM))return!1;Ti.trackEvent("native_ad_click",{nativeAdId:this.idValue,[`href_${this.idValue}`]:i.href})})}get idValue(){return this.data.get("id")}};y(Sn,"visibleContentItems",new Set),y(Sn,"values",{rootMargin:{type:String,default:"-50% 0px"},hidePrintClassName:{type:String,default:"u-hidePrint"}}),y(Sn,"anyVisibleContentItems",function(){return this.visibleContentItems!==0});let Oi=Sn;const WM=Object.freeze(Object.defineProperty({__proto__:null,default:Oi},Symbol.toStringTag,{value:"Module"}));class Rm extends he{initialize(){this.messageHandler=this.messageHandler.bind(this)}connect(){window.addEventListener(cf,this.messageHandler)}disconnect(){window.removeEventListener(cf,this.messageHandler)}messageHandler(e){const{data:{"datawrapper-height":t},source:i}=e;let o;this.hasIframeTarget&&(o=this.iframeTarget),t&&o&&o.contentWindow===i&&requestAnimationFrame(()=>{o.style.height=`${Object.values(t)[0]}px`})}}y(Rm,"targets",["iframe"]);const zM=Object.freeze(Object.defineProperty({__proto__:null,default:Rm},Symbol.toStringTag,{value:"Module"}));function KM(r,e){let t=document.createElement("script");Array.from(r.attributes).forEach(({name:i,value:o})=>{i!=="type"&&t.setAttribute(i,o)}),t.innerHTML=r.innerHTML,typeof e=="function"&&(t=e(t)),r.insertAdjacentElement("beforebegin",t),r.parentNode.removeChild(r)}const GM="is-embed-loaded",Pm="arto-allowed-embed-providers",xm="|",XM=30,YM="iframe[data-src]",QM='script[type="text/plain"]',ZM=[[/\byoutube\.com/,"youtube-nocookie.com"]];let uo=[];function JM(r){return ZM.reduce((e,[t,i])=>e.replace(t,i),r)}function eD(){const r=ft.get(Pm);return r?r.split(xm):[]}function tD(r){ft.set(Pm,r.join(xm),XM)}function km(r){return uo.includes(r)}function rD(r){if(!km(r)){uo.push(r),tD(uo);const e=new CustomEvent(Ol,{detail:{provider:r}});window.dispatchEvent(e)}}uo=eD();class Wl extends he{constructor(){super(...arguments);y(this,"loaded",!1)}initialize(){this.embedAllowedHandler=this.embedAllowedHandler.bind(this),this.consentUpdatedHandler=this.consentUpdatedHandler.bind(this)}connect(){if(this.hasProviderValue){const{providerValue:t}=this;if(km(t)){this.loadEmbed();return}}if(this.hasConsentCategoriesValue){if(this.hasUserConsent()){this.loadEmbed();return}window.addEventListener(Ys,this.consentUpdatedHandler)}window.addEventListener(Ol,this.embedAllowedHandler)}disconnect(){window.addEventListener(Ol,this.embedAllowedHandler),window.removeEventListener(Ys,this.consentUpdatedHandler)}embedAllowedHandler({detail:{provider:t}}){this.hasProviderValue&&this.providerValue===t&&this.loadEmbed()}consentUpdatedHandler(){this.hasUserConsent()&&(this.loadEmbed(),window.removeEventListener(Ys,this.consentUpdatedHandler))}allow(){this.hasProviderValue&&rD(this.providerValue),this.loadEmbed()}loadEmbed(){if(this.loaded)return;this.loaded=!0;const{element:t,placeholderTarget:i}=this,o=Array.from(t.querySelectorAll(YM)),l=Array.from(t.querySelectorAll(QM));requestAnimationFrame(()=>{o.forEach(u=>{u.setAttribute("src",JM(u.getAttribute("data-src")))}),l.forEach(KM),i.hidden=!0,this.element.classList.add(GM)})}hasUserConsent(){return this.hasConsentCategoriesValue?this.consentCategoriesValue.split(/\s*,\s*/).every(i=>xc(i)):!1}}y(Wl,"targets",["placeholder"]),y(Wl,"values",{provider:String,consentCategories:String});const nD=Object.freeze(Object.defineProperty({__proto__:null,default:Wl},Symbol.toStringTag,{value:"Module"})),iD=["popup","ad","native-ad"],sD=["noopener","noreferrer"];class Mm extends he{appearanceTargetConnected(e){Nr(e)}click(e){const{currentTarget:t}=e,{href:i}=t,{controller:o}=t.dataset,l=(o==null?void 0:o.split(/\s+/))||[],u=t.getAttribute("target"),d=(t.getAttribute("rel")||"").split(/\s+/).filter(p=>sD.includes(p)).join(",");if(Nr(t),!l.some(p=>iD.includes(p))&&i){e.preventDefault();const p=Tc(t)?0:Ac;u?window.open(i,u,d):setTimeout(()=>{Eo(i)},p)}}media_play(e){Nr(e.currentTarget,"media_play")}media_pause(e){const{currentTarget:t}=e;t.ended||Nr(t,"media_pause")}media_ended(e){Nr(e.currentTarget,"media_ended")}submit(e){const{currentTarget:t}=e;Nr(t),e.preventDefault(),setTimeout(()=>{t.submit()},100)}}y(Mm,"targets",["appearance"]);const oD=Object.freeze(Object.defineProperty({__proto__:null,default:Mm},Symbol.toStringTag,{value:"Module"})),aD="is-loading",lD="Something went wrong!",cD={mode:"same-origin",credentials:"same-origin",headers:{Accept:"application/json","X-Requested-With":"XMLHttpRequest"}};class zl extends he{initialize(){this.submitHandler=this.submitHandler.bind(this),this.state={loading:!1}}connect(){this.element.addEventListener("submit",this.submitHandler,!1),this.responseTemplate=this.hasResponseTemplateTarget?El(this.responseTemplateTarget.innerHTML):({message:e})=>e,this.errorTemplate=this.haserrorTemplateTarget?El(this.errorTemplateTarget.innerHTML):({message:e})=>e,this.render()}disconnect(){this.element.removeEventListener("submit",this.submitHandler,!1)}setState(e){const{state:t}=this;this.state={...t,...e},e.loading!==t.loading&&requestAnimationFrame(()=>this.render())}async submitHandler(e){const{element:{action:t,method:i}}=this;e.preventDefault(),this.setState({loading:!0}),Nr(this.element);const o=new FormData(this.element),l=await fetch(t,{...cD,method:i.toUpperCase(),body:o});let u;
119try{u=await l.json()}catch{}if(this.setState({loading:!1}),u){const{message:d}=u;l.ok?requestAnimationFrame(()=>this.renderResponse(d)):requestAnimationFrame(()=>this.renderError(d||this.genericErrorMessageValue))}else requestAnimationFrame(()=>this.renderError(this.genericErrorMessageValue))}render(){const{state:{loading:e},interactiveElements:t}=this;t.forEach(i=>{e?i.setAttribute("disabled",!0):i.removeAttribute("disabled")}),this.loadingStateRecipientTargets.forEach(i=>{i.classList[e?"add":"remove"](aD)})}renderResponse(e){this.hasResponseTarget&&(this.responseTarget.innerHTML=this.responseTemplate({message:e}))}renderError(e){this.hasErrorTarget&&(this.errorTarget.innerHTML=this.errorTemplate({message:e}))}get interactiveElements(){return Array.from(this.element.querySelectorAll("input, select, button"))}}y(zl,"targets",["response","error","loadingStateRecipient","responseTemplate","errorTemplate"]),y(zl,"values",{genericErrorMessage:{type:String,default:lD}});const uD=Object.freeze(Object.defineProperty({__proto__:null,default:zl},Symbol.toStringTag,{value:"Module"})),Mf="disabled",hD="is-loading",dD=1e3;class Kl extends he{initialize(){this.submit=xn(this.submit,dD)}connect(){this.formElement=this.element.closest("form")}update(e){const t=e.target.closest('[data-form-filter-target="group"]'),i=t.querySelector('[data-form-filter-target="clear"]'),o=Array.from(t.querySelectorAll('[data-form-filter-target="option"]')),l=e.target===i;let u=!1;l&&o.forEach(d=>{d.checked=!1}),u=!!o.filter(d=>d.checked).length,i&&(u?i.checked=!1:i.checked=!0),this.submit()}submit(){this.formElement.submit(),this.setLoadingState(!0)}setLoadingState(e){const t=Array.prototype.slice.call(this.clearTargets),i=Array.prototype.slice.call(this.optionTargets);t.concat(i).forEach(l=>{e?l.setAttribute(Mf,!0):l.removeAttribute(Mf)}),this.formElement.classList.toggle(hD,e)}}y(Kl,"targets",["clear","option"]);const fD=Object.freeze(Object.defineProperty({__proto__:null,FormFilterController:Kl,default:Kl},Symbol.toStringTag,{value:"Module"})),Df=[980,240],$f=[320,80],Ff=[320,160],Nf=[320,240],Bf=[320,320],gD=[468,240],Zs={sizes:[$f,Ff,Nf,Bf,Df],sizeMapping:[[[1006,0],[Df]],[[0,0],[$f,Ff,Nf,Bf]]]},Gl={sizes:[gD]},pD={page_start:Zs,below_intro:Zs,page_end:Zs,in_content:Gl,after_content:Gl},mD={panorama:Zs,module:Gl},vD="module";window.googletag=window.googletag||{};const{googletag:it}=window;it.cmd=it.cmd||[];const bD={initialize:()=>{it.cmd.push(()=>{it.pubads().addEventListener("slotRenderEnded",r=>{const e=new CustomEvent(Tl,{detail:{event:r}});window.dispatchEvent(e)}),it.pubads().enableLazyLoad(),it.enableServices()})}};class ho extends he{initialize(){this.onSlotRendered=this.onSlotRendered.bind(this),this.onWindowResize=xn(this.onWindowResize.bind(this),10),this.renderPlaceholderAd=xn(this.renderPlaceholderAd.bind(this),10)}connect(){if(this.pagePosition=this.pagePositionValue,this.position=window.hopp.adPositions.find(e=>e.pagePosition===this.pagePosition),this.placeholderValue){window.addEventListener("resize",this.renderPlaceholderAd,!1),this.renderPlaceholderAd();return}this.scaleValue&&window.addEventListener("resize",this.onWindowResize,!1),window.addEventListener(Tl,this.onSlotRendered,!1),it.cmd.push(()=>{const{adFormat:e}=this;this.slot=it.defineSlot(this.position.adUnitPath,e.sizes).addService(it.pubads()),e.sizeMapping&&this.slot.defineSizeMapping(e.sizeMapping),this.slot.updateTargetingFromMap(this.targetingValue),it.enableServices(),this.slotElementId=this.slot.getSlotElementId(),this.slotTarget.id=this.slotElementId,it.display(this.slot)})}disconnect(){window.removeEventListener(Tl,this.onSlotRendered),window.removeEventListener("resize",this.onWindowResize,!1),it.cmd.push(()=>{it.destroySlots([this.slot])})}adjustScale(){const{containerTarget:e,slotTarget:t}=this;if(this.slotIsEmpty())return;const{width:i}=e.getBoundingClientRect(),{width:o,height:l}=this.currentAdDimensions,u=l/o*i;if(!o||!l)return;const d=Math.min(i/o,u/l);e.style.height=`${u}px`,t.style.transformOrigin="top left",t.style.transform=`scale(${d})`}onSlotRendered(e){const{event:t}=e.detail;t.slot===this.slot&&(this.slotIsEmpty()?requestAnimationFrame(()=>this.element.setAttribute("hidden","")):requestAnimationFrame(()=>this.adjustScale()))}onWindowResize(){requestAnimationFrame(()=>this.adjustScale())}renderPlaceholderAd(){const{adFormat:e}=this,t=window.innerWidth;let i;e.sizeMapping?e.sizeMapping.forEach(d=>{!i&&t>=d[0][0]&&([,i]=d)}):i=e.sizes;const o=JSON.stringify(i);if(o===this.previouslyMatchingFormatsString){requestAnimationFrame(()=>this.adjustScale());return}const l=i[Math.floor(Math.random()*i.length)],u=`<iframe width="${l[0]}" height="${l[1]}" src="/placeholder-ad/${l.join("x")}" frameborder="0" style="max-width: none;"></iframe>`;requestAnimationFrame(()=>{this.slotTarget.innerHTML=u,this.adjustScale()}),this.previouslyMatchingFormatsString=o}slotIsEmpty(){return this.slot&&typeof this.slot.getResponseInformation=="function"&&!this.slot.getResponseInformation()}get adFormat(){return pD[this.pagePosition]||mD[this.position.format||vD]}get currentAdDimensions(){const e=this.element.querySelector("iframe");return e?{width:parseInt(e.getAttribute("width"),10),height:parseInt(e.getAttribute("height"),10)}:{width:null,height:null}}}y(ho,"targets",["slot","container"]),y(ho,"values",{pagePosition:String,placeholder:Boolean,scale:Boolean,targeting:Object});const _D=Object.freeze(Object.defineProperty({__proto__:null,AdController:ho,default:ho},Symbol.toStringTag,{value:"Module"})),wD="> *",yD=0;class Dm extends he{connect(){Array.from(this.element.querySelectorAll(this.selectorValue)).slice(0,this.countValue).forEach(e
119=>{e.setAttribute("hidden",!0)})}}y(Dm,"values",{selector:{type:String,default:wD},count:{type:Number,default:yD}});const ED=Object.freeze(Object.defineProperty({__proto__:null,default:Dm},Symbol.toStringTag,{value:"Module"}));class SD extends he{initialize(){this.messageHandler=this.messageHandler.bind(this)}connect(){window.addEventListener("message",this.messageHandler,!1)}disconnect(){window.removeEventListener("message",this.messageHandler,!1)}messageHandler({source:e,data:{height:t,scrollTop:i}}){e===this.element.contentWindow&&(t&&this.resize(t),i&&this.scrollIntoView())}resize(e){this.element.style.height=`${e}px`}scrollIntoView(){const{element:e}=this,{top:t}=e.getBoundingClientRect();t<0&&e.scrollIntoView()}}const AD=Object.freeze(Object.defineProperty({__proto__:null,default:SD},Symbol.toStringTag,{value:"Module"})),kc="every-time",$m="once",Uf=kc,TD=[kc,$m];class Xl extends he{initialize(){this.observeHandler=this.observeHandler.bind(this),this.scrollHandler=this.scrollHandler.bind(this)}connect(){const e=this.frequencyValue;this.frequency=TD.includes(e)?e:Uf,this.threshold=this.thresholdValue,this.rootMargin="0px",this.eagerValue&&this.frequency===$m&&this.setupEagerScroll(),this.setupObserver()}setupObserver(){const e={threshold:this.threshold,rootMargin:this.rootMargin};this.observer=new IntersectionObserver(this.observeHandler,e),this.observer.observe(this.element)}teardownObserver(){this.observer&&(this.observer.unobserve(this.element),this.observer.disconnect(),this.observer=null)}setupEagerScroll(){const e=document.createElement("div");e.ariaHidden=!0,e.style.position="absolute",e.style.top="-1px",e.style.left="-1px",e.style.width="1px",e.style.height="1px",e.style.opacity="0",e.style.overflow="hidden",document.body.appendChild(e),this.eagerTempElement=e,window.addEventListener("scroll",this.scrollHandler)}teardownEagerScroll(){this.eagerTempElement&&(document.body.removeChild(this.eagerTempElement),this.eagerTempElement=null),window.removeEventListener("scroll",this.scrollHandler)}observeHandler(e){e[0].isIntersecting?this.enterViewportHandler():this.exitViewportHandler()}scrollHandler(){this.eagerTempElement&&(this.scrollAnimationFrameId&&cancelAnimationFrame(this.scrollAnimationFrameId),this.scrollAnimationFrameId=requestAnimationFrame(()=>{this.eagerTempElement.innerText=window.scrollY}))}enterViewportHandler(){this.enterViewportAnimationFrameId&&cancelAnimationFrame(this.enterViewportAnimationFrameId),this.enterViewportAnimationFrameId=requestAnimationFrame(()=>{const{addClass:e,removeClass:t}=this;e&&this.element.classList.add(e),t&&this.element.classList.remove(t)}),this.frequency!==kc&&(this.teardownEagerScroll(),this.teardownObserver())}exitViewportHandler(){this.exitViewportAnimationFrameId&&cancelAnimationFrame(this.exitViewportAnimationFrameId),this.exitViewportAnimationFrameId=requestAnimationFrame(()=>{const{addClass:e,removeClass:t}=this;e&&this.element.classList.remove(e),t&&this.element.classList.add(t)})}}y(Xl,"values",{frequency:{type:String,default:Uf},threshold:Number,eager:Boolean}),y(Xl,"classes",["add","remove"]);const OD=Object.freeze(Object.defineProperty({__proto__:null,default:Xl},Symbol.toStringTag,{value:"Module"})),Sr=typeof window<"u",Fm=Sr&&!("onscroll"in window)||typeof navigator<"u"&&/(gle|ing|ro)bot|crawl|spider/i.test(navigator.userAgent),Nm=Sr&&window.devicePixelRatio>1,CD={elements_selector:".lazy",container:Fm||Sr?document:null,threshold:300,thresholds:null,data_src:"src",data_srcset:"srcset",data_sizes:"sizes",data_bg:"bg",data_bg_hidpi:"bg-hidpi",data_bg_multi:"bg-multi",data_bg_multi_hidpi:"bg-multi-hidpi",data_bg_set:"bg-set",data_poster:"poster",class_applied:"applied",class_loading:"loading",class_loaded:"loaded",class_error:"error",class_entered:"entered",class_exited:"exited",unobserve_completed:!0,unobserve_entered:!1,cancel_on_exit:!0,callback_enter:null,callback_exit:null,callback_applied:null,callback_loading:null,callback_loaded:null,callback_error:null,callback_finish:null,callback_cancel:null,use_native:!1,restore_on_error:!1},Bm=r=>Object.assign({},CD,r),Hf=function(r,e){let t;const i="LazyLoad::Initialized",o=new r(e);try{t=new CustomEvent(i,{detail:{instance:o}})}catch{t=document.createEvent("CustomEvent"),t.initCustomEvent(i,!1,!1,{instance:o})}window.dispatchEvent(t)},ID=(r,e)=>{if(e)if(e.length)for(let t,i=0;t=e[i];i+=1)Hf(r,t);else Hf(r,e)},Jt="src",Mc="srcset",Dc="sizes",Um="poster",ji="llOriginalAttrs",Hm="data",$c="loading",qm="loaded",Vm="applied",LD="entered",Fc="error",jm="native",Wm="data-",zm="ll-status",Ge=(r,e)=>r.getAttribute(Wm+e),RD=(r,e,t)=>{const i=Wm+e;t!==null?r.setAttribute(i,t):r.removeAttribute(i)},Wi=r=>Ge(r,zm),Yr=(r,e)=>RD(r,zm,e),Oo=r=>Yr(r,null),Nc=r=>Wi(r)===null,PD=r=>Wi(r)===$c,xD=r=>Wi(r)===Fc,Bc=r=>Wi(r)===jm,kD=[$c,qm,Vm,Fc],MD=r=>kD.indexOf(Wi(r))>=0,Ar=(r,e,t,i)=>{r&&typeof r=="function"&&(i===void 0?t===void 0?r(e):r(e,t):r(e,t,i))},Hn=(r,e)=>{Sr&&e!==""&&r.classList.add(e)},xt=(r,e)=>{Sr&&e!==""&&r.classList.remove(e)},DD=r=>{r.llTempImage=document.createElement("IMG")},$D=r=>{delete r.llTempImage},Km=r=>r.llTempImage,Co=(r,e)=>{if(!e)return;const t=e._observer;t&&t.unobserve(r)},FD=r=>{r.disconnect()},ND=(r,e,t)=>{e.unobserve_entered&&Co(r,t)},Uc=(r,e)=>{r&&(r.loadingCount+=e)},BD=r=>{r&&(r.toLoadCount-=1)},Gm=(r,e)=>{r&&(r.toLoadCount=e)},UD=r=>r.loadingCount>0,HD=r=>r.toLoadCount>0,Xm=r=>{let e=[];for(let t,i=0;t=r.children[i];i+=1)t.tagName==="SOURCE"&&e.push(t);return e},Hc=(r,e)=>{const t=r.parentNode;t&&t.tagName==="PICTURE"&&Xm(t).forEach(e)},Ym=(r,e)=>{Xm(r).forEach(e)},Io=[Jt],Qm=[Jt,Um],Ci=[Jt,Mc,Dc],Zm=[Hm],Lo=r=>!!r[ji],Jm=r=>r[ji],ev=r=>delete r[ji],Mn=(r,e)=>{if(Lo(r))return;const t={};e.forEach(i=>
119{t[i]=r.getAttribute(i)}),r[ji]=t},qD=r=>{Lo(r)||(r[ji]={backgroundImage:r.style.backgroundImage})},Kr=(r,e)=>{if(!Lo(r))return;const t=Jm(r);e.forEach(i=>{((o,l,u)=>{u?o.setAttribute(l,u):o.removeAttribute(l)})(r,i,t[i])})},VD=r=>{if(!Lo(r))return;const e=Jm(r);r.style.backgroundImage=e.backgroundImage},tv=(r,e,t)=>{Hn(r,e.class_applied),Yr(r,Vm),t&&(e.unobserve_completed&&Co(r,e),Ar(e.callback_applied,r,t))},rv=(r,e,t)=>{Hn(r,e.class_loading),Yr(r,$c),t&&(Uc(t,1),Ar(e.callback_loading,r,t))},wr=(r,e,t)=>{t&&r.setAttribute(e,t)},qf=(r,e)=>{wr(r,Dc,Ge(r,e.data_sizes)),wr(r,Mc,Ge(r,e.data_srcset)),wr(r,Jt,Ge(r,e.data_src))},jD=(r,e)=>{Hc(r,t=>{Mn(t,Ci),qf(t,e)}),Mn(r,Ci),qf(r,e)},WD=(r,e)=>{Mn(r,Io),wr(r,Jt,Ge(r,e.data_src))},zD=(r,e)=>{Ym(r,t=>{Mn(t,Io),wr(t,Jt,Ge(t,e.data_src))}),Mn(r,Qm),wr(r,Um,Ge(r,e.data_poster)),wr(r,Jt,Ge(r,e.data_src)),r.load()},KD=(r,e)=>{Mn(r,Zm),wr(r,Hm,Ge(r,e.data_src))},GD=(r,e,t)=>{const i=Ge(r,e.data_bg),o=Ge(r,e.data_bg_hidpi),l=Nm&&o?o:i;l&&(r.style.backgroundImage=`url("${l}")`,Km(r).setAttribute(Jt,l),rv(r,e,t))},XD=(r,e,t)=>{const i=Ge(r,e.data_bg_multi),o=Ge(r,e.data_bg_multi_hidpi),l=Nm&&o?o:i;l&&(r.style.backgroundImage=l,tv(r,e,t))},YD=(r,e,t)=>{const i=Ge(r,e.data_bg_set);if(!i)return;let o=i.split("|").map(l=>`image-set(${l})`);r.style.backgroundImage=o.join(),tv(r,e,t)},nv={IMG:jD,IFRAME:WD,VIDEO:zD,OBJECT:KD},QD=(r,e)=>{const t=nv[r.tagName];t&&t(r,e)},ZD=(r,e,t)=>{const i=nv[r.tagName];i&&(i(r,e),rv(r,e,t))},JD=["IMG","IFRAME","VIDEO","OBJECT"],e$=r=>JD.indexOf(r.tagName)>-1,iv=(r,e)=>{!e||UD(e)||HD(e)||Ar(r.callback_finish,e)},Vf=(r,e,t)=>{r.addEventListener(e,t),r.llEvLisnrs[e]=t},t$=(r,e,t)=>{r.removeEventListener(e,t)},qc=r=>!!r.llEvLisnrs,r$=(r,e,t)=>{qc(r)||(r.llEvLisnrs={});const i=r.tagName==="VIDEO"?"loadeddata":"load";Vf(r,i,e),Vf(r,"error",t)},Yl=r=>{if(!qc(r))return;const e=r.llEvLisnrs;for(let t in e){const i=e[t];t$(r,t,i)}delete r.llEvLisnrs},sv=(r,e,t)=>{$D(r),Uc(t,-1),BD(t),xt(r,e.class_loading),e.unobserve_completed&&Co(r,t)},n$=(r,e,t,i)=>{const o=Bc(e);sv(e,t,i),Hn(e,t.class_loaded),Yr(e,qm),Ar(t.callback_loaded,e,i),o||iv(t,i)},i$=(r,e,t,i)=>{const o=Bc(e);sv(e,t,i),Hn(e,t.class_error),Yr(e,Fc),Ar(t.callback_error,e,i),t.restore_on_error&&Kr(e,Ci),o||iv(t,i)},Ql=(r,e,t)=>{const i=Km(r)||r;qc(i)||r$(i,o=>{n$(0,r,e,t),Yl(i)},o=>{i$(0,r,e,t),Yl(i)})},Zl=(r,e,t)=>{e$(r)?((i,o,l)=>{Ql(i,o,l),ZD(i,o,l)})(r,e,t):((i,o,l)=>{DD(i),Ql(i,o,l),qD(i),GD(i,o,l),XD(i,o,l),YD(i,o,l)})(r,e,t)},s$=(r,e,t)=>{r.setAttribute("loading","lazy"),Ql(r,e,t),QD(r,e),Yr(r,jm)},jf=r=>{r.removeAttribute(Jt),r.removeAttribute(Mc),r.removeAttribute(Dc)},o$=r=>{Hc(r,e=>{jf(e)}),jf(r)},ov=r=>{Hc(r,e=>{Kr(e,Ci)}),Kr(r,Ci)},a$=r=>{Ym(r,e=>{Kr(e,Io)}),Kr(r,Qm),r.load()},l$=r=>{Kr(r,Io)},c$=r=>{Kr(r,Zm)},u$={IMG:ov,IFRAME:l$,VIDEO:a$,OBJECT:c$},h$=(r,e)=>{(t=>{const i=u$[t.tagName];i?i(t):VD(t)})(r),((t,i)=>{Nc(t)||Bc(t)||(xt(t,i.class_entered),xt(t,i.class_exited),xt(t,i.class_applied),xt(t,i.class_loading),xt(t,i.class_loaded),xt(t,i.class_error))})(r,e),Oo(r),ev(r)},d$=(r,e,t,i)=>{t.cancel_on_exit&&PD(r)&&r.tagName==="IMG"&&(Yl(r),o$(r),ov(r),xt(r,t.class_loading),Uc(i,-1),Oo(r),Ar(t.callback_cancel,r,e,i))},f$=(r,e,t,i)=>{const o=MD(r);Yr(r,LD),Hn(r,t.class_entered),xt(r,t.class_exited),ND(r,t,i),Ar(t.callback_enter,r,e,i),o||Zl(r,t,i)},g$=(r,e,t,i)=>{Nc(r)||(Hn(r,t.class_exited),d$(r,e,t,i),Ar(t.callback_exit,r,e,i))},p$=["IMG","IFRAME","VIDEO"],av=r=>r.use_native&&"loading"in HTMLImageElement.prototype,m$=(r,e,t)=>{r.forEach(i=>{p$.indexOf(i.tagName)!==-1&&s$(i,e,t)}),Gm(t,0)},v$=r=>r.isIntersecting||r.intersectionRatio>0,b$=(r,e)=>{e.forEach(t=>{r.observe(t)})},_$=(r,e)=>{FD(r),b$(r,e)},w$=(r,e)=>{av(r)||(e._observer=new IntersectionObserver(t=>{((i,o,l)=>{i.forEach(u=>v$(u)?f$(u.target,u,o,l):g$(u.target,u,o,l))})(t,r,e)},(t=>({root:t.container===document?null:t.container,rootMargin:t.thresholds||t.threshold+"px"}))(r)))},lv=r=>Array.prototype.slice.call(r),fo=r=>r.container.querySelectorAll(r.elements_selector),y$=r=>lv(r).filter(Nc),E$=r=>xD(r),S$=r=>lv(r).filter(E$),Wf=(r,e)=>y$(r||fo(e)),A$=(r,e)=>
119{S$(fo(r)).forEach(t=>{xt(t,r.class_error),Oo(t)}),e.update()},T$=(r,e)=>{Sr&&(e._onlineHandler=()=>{A$(r,e)},window.addEventListener("online",e._onlineHandler))},O$=r=>{Sr&&window.removeEventListener("online",r._onlineHandler)},En=function(r,e){const t=Bm(r);this._settings=t,this.loadingCount=0,w$(t,this),T$(t,this),this.update(e)};En.prototype={update:function(r){const e=this._settings,t=Wf(r,e);Gm(this,t.length),Fm?this.loadAll(t):av(e)?m$(t,e,this):_$(this._observer,t)},destroy:function(){this._observer&&this._observer.disconnect(),O$(this),fo(this._settings).forEach(r=>{ev(r)}),delete this._observer,delete this._settings,delete this._onlineHandler,delete this.loadingCount,delete this.toLoadCount},loadAll:function(r){const e=this._settings;Wf(r,e).forEach(t=>{Co(t,this),Zl(t,e,this)})},restoreAll:function(){const r=this._settings;fo(r).forEach(e=>{h$(e,r)})}},En.load=(r,e)=>{const t=Bm(e);Zl(r,t)},En.resetStatus=r=>{Oo(r)},Sr&&ID(En,window.lazyLoadOptions);const zf="in-viewport",C$="loaded",cv='[data-lazy-load-target="content"]:not([loading])',I$=`${cv}:is(video)`,L$=`${cv}:not(video)`;class uv extends he{initialize(){this.update=xn(this.update,10)}connect(){this.loader||this.videoLoader||(this.loader=new En({elements_selector:L$,class_entered:zf,use_native:!0}),this.videoLoader=new En({elements_selector:I$,class_entered:zf}))}disconnect(){this.loader.destroy(),this.videoLoader.destroy(),this.loader=null,this.videoLoader=null}update(){this.loader&&this.loader.update(),this.videoLoader&&this.videoLoader.update()}contentTargetConnected(e){if(e.getAttribute("loading")){if(e.complete){this.onLoad({target:e});return}e.addEventListener("load",this.onLoad,{once:!0});return}this.update()}onLoad({target:e}){requestAnimationFrame(()=>e.classList.add(C$))}}y(uv,"targets",["content"]);const R$=Object.freeze(Object.defineProperty({__proto__:null,default:uv},Symbol.toStringTag,{value:"Module"})),P$="is-open",x$='[data-multi-select-target~="input"]',k$='[data-multi-select-target~="inputLabel"]';class Jl extends he{constructor(){super(...arguments);y(this,"state",{open:!1,values:[],defaultLabel:""})}setState(t={},{quiet:i=!1}={}){const o=this.state;this.state={...o,...t},!i&&this.render(this.state,o)}initialize(){this.handleChange=this.handleChange.bind(this),this.handleKeyupOutside=this.handleKeyupOutside.bind(this),this.handleClickOutside=this.handleClickOutside.bind(this)}connect(){this.element.addEventListener("change",this.handleChange),window.addEventListener("keyup",this.handleKeyupOutside),document.addEventListener("click",this.handleClickOutside);const{toggleButtonTarget:t,optionsTarget:i,labelTarget:o}=this,l=Si(10),u=Si(10);t.id=l,t.setAttribute("aria-controls",u),i.id=u,i.setAttribute("aria-labelledby",l),this.setState({values:this.getValues(),defaultLabel:o.textContent.trim()},{quiet:!0}),this.render()}disconnect(){this.element.removeEventListener("change",this.handleChange),window.removeEventListener("keyup",this.handleKeyupOutside),document.removeEventListener("click",this.handleClickOutside)}render(t=this.state,i={}){const{element:o,toggleButtonTarget:l,optionsTarget:u,inputTargets:d,clearInputTarget:p,labelTarget:v}=this,{values:S}=t;if(d.forEach(O=>{O.checked=S.includes(O.value)}),t.open&&!i.open){const O=o.getBoundingClientRect().width;o.style.width=`${O}px`}else!t.open&&i.open&&(o.style.width="");p.checked=!S.length,v.innerText=this.getLabel(S),l.setAttribute("aria-haspopup",!0),l.setAttribute("aria-expanded",t.open),u.hidden=!t.open,o.classList.toggle(P$,t.open)}toggle(){this.setState({open:!this.state.open})}handleChange({target:t}){if(t===this.clearInputTarget){this.setState({values:[]});return}this.inputTargets.includes(t)&&this.setState({values:this.getValues()})}handleKeyupOutside({key:t}){t!=="Escape"||!this.state.open||this.setState({open:!1})}handleClickOutside({target:t}){!this.state.open||this.element.contains(t)||this.setState({open:!1})}getValues(){return this.inputTargets.filter(t=>t.checked).map(t=>t.value)}
119getLabel(t){const{labelSingleTemplateValue:i,labelMultipleTemplateValue:o}=this,l=this.optionTargets.reduce((u,d)=>{const p=d.querySelector(x$),v=d.querySelector(k$);return!p||!v?u:t.includes(p.value)?[...u,v.textContent.trim()]:u},[]);return t.length?(l.length===1?i:o).replace("%{count}",t.length).replace("%{value}",l.join(", ")):this.state.defaultLabel}}y(Jl,"targets",["label","toggleButton","options","option","clearInput","input"]),y(Jl,"values",{labelSingleTemplate:String,labelMultipleTemplate:String});const M$=Object.freeze(Object.defineProperty({__proto__:null,default:Jl},Symbol.toStringTag,{value:"Module"}));class D$ extends co{constructor(){super(...arguments);y(this,"impressionEventName","native_ad_teaser_impression");y(this,"clickEventName","native_ad_teaser_click");y(this,"positionParentAttribute","data-native-ad-position");y(this,"adPositionEventKey","adPosition_{{id}}");y(this,"openLinkInNewWindow",!1)}}const $$=Object.freeze(Object.defineProperty({__proto__:null,default:D$},Symbol.toStringTag,{value:"Module"}));class ec extends he{initialize(){this.isPlaying=!1,this.rewindStep=15,this.forwardStep=30,this.touchStartX=null,this.hasDragged=!1}connect(){this.audioTarget.addEventListener("loadedmetadata",this.handleLoadedMetadata.bind(this)),this.audioTarget.addEventListener("timeupdate",this.handleTimeUpdate.bind(this)),this.audioTarget.addEventListener("ended",this.handleEnded.bind(this)),this.audioTarget.addEventListener("play",this.handlePlay.bind(this)),this.audioTarget.addEventListener("pause",this.handlePause.bind(this)),this.progressBarTarget.addEventListener("click",this.handleProgressBarClick.bind(this)),this.progressBarTarget.addEventListener("mousedown",this.handleProgressBarMouseDown.bind(this)),this.progressBarTarget.addEventListener("touchstart",this.handleProgressBarTouchStart.bind(this)),this.progressBarTarget.addEventListener("touchend",this.handleProgressBarTouchEnd.bind(this)),this.progressHandleWrapperTarget.addEventListener("keydown",this.handleProgressBarKeyDown.bind(this)),this.rewindButtonTarget.addEventListener("click",this.rewind.bind(this)),this.forwardButtonTarget.addEventListener("click",this.forward.bind(this)),this.playButtonTarget.addEventListener("click",this.togglePlay.bind(this)),this.updateTimeDisplay(),this.progressHandleWidth=this.progressHandleTarget.offsetWidth}togglePlay(){this.isPlaying?this.pause():this.play()}play(){this.audioTarget.play()}pause(){this.audioTarget.pause()}rewind(){this.audioTarget.currentTime=Math.max(0,this.audioTarget.currentTime-this.rewindStep)}forward(){this.audioTarget.currentTime=Math.min(this.audioTarget.duration,this.audioTarget.currentTime+this.forwardStep)}handleProgressBarClick(e){const t=this.progressHandleWrapperTarget.getBoundingClientRect(),o=(e.clientX-t.left)/t.width;this.audioTarget.currentTime=o*this.audioTarget.duration}handleProgressBarMouseDown(e){this.startScrubbing("mouse",e)}handleProgressBarTouchStart(e){e.preventDefault(),this.touchStartX=e.touches[0].clientX,this.hasDragged=!1,this.startScrubbing("touch",e)}handleProgressBarTouchEnd(e){if(!this.hasDragged&&this.touchStartX!==null){const t=e.changedTouches[0],i=this.progressHandleWrapperTarget.getBoundingClientRect(),o=t.clientX-i.left,l=Math.max(0,Math.min(1,o/i.width));this.audioTarget.currentTime=l*this.audioTarget.duration}this.touchStartX=null,this.hasDragged=!1}startScrubbing(e,t){let i=!1;this.isPlaying&&(i=!0,this.pause()),document.body.style.userSelect="none";const o=p=>e==="touch"?p.touches[0].clientX:p.clientX,l=p=>{const v=this.progressHandleWrapperTarget.getBoundingClientRect(),S=o(p),O=Math.max(0,Math.min(1,(S-v.left)/v.width));this.audioTarget.currentTime=O*this.audioTarget.duration};l(t);const u=p=>{e==="touch"&&(p.preventDefault(),this.hasDragged=!0),l(p)},d=()=>{e==="touch"?(document.removeEventListener("touchmove",u),document.removeEventListener("touchend",d),document.removeEventListener("touchcancel",d)):(document.removeEventListener("mousemove",u),document.removeEventListener("mouseup",d)),this.progressBarTarget.classList.remove("Podcast-progressBar--scrubbing"),document.body.style.userSelect="auto",i&&this.play()};e==="touch"?(document.addEventListener("touchmove",u,{passive:!1}),document.addEventListener("touchend",d),document.addEventListener("touchcancel",d)):(document.addEventListener("mousemove",u),document.addEventListener("mouseup",d)),this.progressBarTarget.classList.add("Podcast-progressBar--scrubbing")}handleLoadedMetadata(){this.updateTimeDisplay()}handleTimeUpdate(){this.updateProgress(),this.updateTimeDisplay()}handlePlay(){this.isPlaying=!0,this.updatePlayButton()}handlePause(){this.isPlaying=!1,this.updatePlayButton()}handleEnded(){this.isPlaying=!1,this.updatePlayButton()}updateProgress(){if(this.audioTarget.duration){const e=this.audioTarget.currentTime/this.audioTarget.duration;this.progressHandleTarget.style.left=`${e*100}%`,this.progressBarFillTarget.style.clipPath=`inset(0 ${100-e*100}% 0 0)`,this.progressHandleWrapperTarget.setAttribute("aria-valuenow",this.audioTarget.currentTime),this.progressHandleWrapperTarget.setAttribute("aria-valuemax",this.audioTarget.duration),this.progressHandleWrapperTarget.setAttribute("aria-valuetext",this.formatTimeForScreenReader(this.audioTarget.currentTime))}}updateTimeDisplay(){this.audioTarget.duration&&(this.currentTimeTarget.textContent=this.formatTime(this.audioTarget.currentTime),this.durationTarget.textContent="â"+this.formatTime(this.audioTarget.duration-this.audioTarget.currentTime))}updatePlayButton(){this.isPlaying?(this.playButtonTarget.classList.add("is-playing"),this.playButtonTarget.classList.remove("is-paused"),this.playButtonTarget.setAttribute("aria-label",this.pauseL
119abelValue)):(this.playButtonTarget.classList.add("is-paused"),this.playButtonTarget.classList.remove("is-playing"),this.playButtonTarget.setAttribute("aria-label",this.playLabelValue))}formatTime(e){if(isNaN(e))return"0:00";const t=Math.floor(e/3600),i=Math.floor(e/60),o=Math.floor(e%60);return t>0?`${t}:${i.toString().padStart(2,"0")}:${o.toString().padStart(2,"0")}`:`${i}:${o.toString().padStart(2,"0")}`}formatTimeForScreenReader(e){if(isNaN(e))return`0 ${this.timeFormatMinutesOtherValue.replace("%{count}",0)} 0 ${this.timeFormatSecondsOtherValue.replace("%{count}",0)}`;const t=Math.floor(e/3600),i=Math.floor(e/60),o=Math.floor(e%60);let l="";if(t>0){const u=t===1?this.timeFormatHoursValue.replace("%{count}",t):this.timeFormatHoursOtherValue.replace("%{count}",t);l+=u}if(i>0){l&&(l+=" ");const u=i===1?this.timeFormatMinutesValue.replace("%{count}",i):this.timeFormatMinutesOtherValue.replace("%{count}",i);l+=u}if(o>0||!l){l&&(l+=" ");const u=o===1?this.timeFormatSecondsValue.replace("%{count}",o):this.timeFormatSecondsOtherValue.replace("%{count}",o);l+=u}return l}handleProgressBarKeyDown(e){const{key:t}=e;let i=this.audioTarget.currentTime;switch(t){case"ArrowLeft":e.preventDefault(),i=Math.max(0,this.audioTarget.currentTime-5);break;case"ArrowRight":e.preventDefault(),i=Math.min(this.audioTarget.duration,this.audioTarget.currentTime+5);break;case"Home":e.preventDefault(),i=0;break;case"End":e.preventDefault(),i=this.audioTarget.duration;break;case"PageUp":e.preventDefault(),i=Math.min(this.audioTarget.duration,this.audioTarget.currentTime+30);break;case"PageDown":e.preventDefault(),i=Math.max(0,this.audioTarget.currentTime-30);break;default:return}this.audioTarget.currentTime=i}}y(ec,"targets",["audio","playButton","rewindButton","forwardButton","progressBar","progressHandle","progressHandleWrapper","progressBarFill","currentTime","duration"]),y(ec,"values",{playLabel:String,pauseLabel:String,timeFormatHours:String,timeFormatHoursOther:String,timeFormatMinutes:String,timeFormatMinutesOther:String,timeFormatSeconds:String,timeFormatSecondsOther:String});const F$=Object.freeze(Object.defineProperty({__proto__:null,default:ec},Symbol.toStringTag,{value:"Module"}));class tc extends he{initialize(){this.onClick=this.onClick.bind(this)}connect(){this.element.addEventListener("click",this.onClick,!1)}onClick(e){const t=this.windowFeatures(),i=window.open(this.element.href,null,t);e.preventDefault(),i.focus()}windowFeatures(){return[`width=${this.widthValue}`,`height=${this.heightValue}`,"centerscreen=true","chrome=yes","menubar=false","toolbar=false","location=false","personalbar=false","status=false"].join(",")}}y(tc,"values",{width:Number,height:Number});const N$=Object.freeze(Object.defineProperty({__proto__:null,PopupController:tc,default:tc},Symbol.toStringTag,{value:"Module"})),go="numeric",hv="short",B$="long",U$={sv:!0},H$=60*1e3,q$=H$*60,hl=q$*24,Vc={hour:go,minute:go},V$={weekday:B$},j$={weekday:hv,...Vc},jc={day:go,month:hv},W$={...jc,...Vc},z$={...jc,year:go};function vn(r,e,t){return new Intl.DateTimeFormat(e,t).format(r)}function K$(r){const e=new Date(r)-new Date(r).setHours(0,0,0,0);return r-e}function G$(r,e,{locale:t=void 0,todayString:i=void 0,yesterdayString:o=void 0,timeSeparatorString:l=void 0,includeTime:u=!0}={}){if(!("Intl"in window)||!("DateTimeFormat"in window.Intl))return null;const p=K$(r)-e,v=new Date(r),S=new Date(e),O=vn(S,t,Vc),k=vn(S,t,V$),D=vn(S,t,j$),N=vn(S,t,W$),B=vn(S,t,jc),V=vn(S,t,z$),H=S.getFullYear(),x=v.getFullYear();let M="";return e>r?M=V:i&&p<0?u?M=`${i} ${O}`:M=i:o&&p<hl?u?M=`${o} ${O}`:M=o:p<hl*6?u?M=D:M=k:x!==H?M=V:p<hl*89?u?M=N:M=B:M=V,U$[t]&&(M=M.replace(/\./g,"")),l&&(M=M.replace(/:/g,l)),M}class rc extends he{async connect(){const e=await _i("datetime.today"),t=await _i("datetime.yesterday"),i=await _i("datetime.timeSeparator"),o=this.element.getAttribute("datetime").split(/[^0-9]/).map(p=>parseInt(p,10)),l=Date.now(),u=new Date(o[0],o[1]-1||0,o[2]||1,o[3]||0,o[4]||0,o[5]||0,o[6]||0).getTime();let d;u&&(d=G$(l,u,{locale:_k(),todayString:e,yesterdayString:t,timeSeparatorString:i,includeTime:this.timeValue})),d&&(this.capitalizeValue&&(d=d.charAt(0).toUpperCase()+d.slice(1)),this.element.innerHTML=d)}}y(rc,"values",{time:{type:Boolean,default:!0},capitalize:{type:Boolean,default:!0}});const X$=Object.freeze(Object.defineProperty({__proto__:null,RelativeTimeController:rc,default:rc},Symbol.toStringTag,{value:"Module"})),Y$='input[type="checkbox"]';class Q$ extends he{initialize(){this.changedHandler=this.changedHandler.bind(this)}connect(){this.render(),this.element.addEventListener("change",this.changedHandler,!0)}disconnect(){this.element.removeEventListener("change",this.changedHandler,!0)}render(){const e=Array.from(this.element.querySelectorAll(Y$)),t=e.some(i=>i.checked);e.forEach(i=>
119i.required=!t)}changedHandler(){this.render()}}const Z$=Object.freeze(Object.defineProperty({__proto__:null,default:Q$},Symbol.toStringTag,{value:"Module"})),Kf=10;class dv extends he{initialize(){this.resizeHandler=xn(this.resizeHandler.bind(this),100)}connect(){this.setScrollState(),window.addEventListener("scroll",this.resizeHandler)}disconnect(){window.removeEventListener("scroll",this.resizeHandler)}resizeHandler(){this.setScrollState()}setScrollState(){const{scrollWidth:e,scrollLeft:t}=this.innerTarget,i=Math.round(this.innerTarget.getBoundingClientRect().width);let o=!0,l=!1;t>Kf&&(o=!1),t>e-i-Kf&&(l=!0),o?this.element.classList.add("is-end-left"):this.element.classList.remove("is-end-left"),l?this.element.classList.add("is-end-right"):this.element.classList.remove("is-end-right")}onScroll(){this.setScrollState()}}y(dv,"targets",["inner"]);const J$=Object.freeze(Object.defineProperty({__proto__:null,default:dv},Symbol.toStringTag,{value:"Module"})),Gf="resize",eF="--scrollbar-width";function dl(){document.documentElement.style.setProperty(eF,`${window.innerWidth-document.documentElement.clientWidth}px`)}class tF extends he{connect(){window.addEventListener(Gf,dl),dl()}disconnect(){window.removeEventListener(Gf,dl)}}const rF=Object.freeze(Object.defineProperty({__proto__:null,default:tF},Symbol.toStringTag,{value:"Module"}));class nc extends he{constructor(){super(...arguments);y(this,"resetTimer",null)}initialize(){this.clickHandler=this.clickHandler.bind(this)}connect(){this.buttonTarget.addEventListener("click",this.clickHandler),this.originalLabelText=this.labelTarget.textContent}disconnect(){this.buttonTarget.removeEventListener("click",this.clickHandler)}async clickHandler(t){const i=this.titleValue??document.title,o=this.urlValue??document.location.href,l=this.shareTextValue;if(t.preventDefault(),clearTimeout(this.resetTimer),navigator.canShare&&navigator.canShare({title:i,url:o}))try{await navigator.share({title:i,url:o,text:l}),this.setLabel(this.successTextValue)}catch{}else navigator.clipboard&&(await navigator.clipboard.writeText(o),this.setLabel(this.successFallbackTextValue))}setLabel(t,{resetAfter:i=!0}={}){this.labelTarget.textContent=t,i&&this.resetAfterDelay()}resetAfterDelay(){const{resetDelayValue:t,originalLabelText:i}=this;this.resetTimer=setTimeout(()=>{this.setLabel(i,{resetAfter:!1})},t)}}y(nc,"values",{successText:{type:String,default:"shared"},successFallbackText:{type:String,default:"copied"},shareText:{type:String,default:""},url:{type:String,default:null},title:{type:String,default:null},resetDelay:{type:Number,default:5e3}}),y(nc,"targets",["button","label"]);const nF=Object.freeze(Object.defineProperty({__proto__:null,default:nc},Symbol.toStringTag,{value:"Module"}));class ic extends he{connect(){this.hasLatValue&&this.hasLngValue&&this.updateLinks()}updateLinks(){const{latValue:e,lngValue:t}=this,i=window.navigator.userAgent.toLowerCase(),o=!!i.match(/\b(iphone|ipad|ipod)\b/),l=!!i.match(/\b(android)\b/);let u;switch(!0){case o:u=`https://maps.apple.com/?ll=${e},${t}`;break;case l:u=`https://www.google.com/maps/@${e},${t},10z`;break}u&&this.linkTargets.forEach(d=>{d.setAttribute("href",u)})}}y(ic,"targets",["link"]),y(ic,"values",{lat:Number,lng:Number});const iF=Object.freeze(Object.defineProperty({__proto__:null,default:ic},Symbol.toStringTag,{value:"Module"})),Xf=100,Yf=Symbol("scroll-cancelled"),Qf="--sticky-header-height";class fv extends he{constructor(){super(...arguments);y(this,"state",{sticky:!1});y(this,"cancelScrollWatch",null);y(this,"onIntersection",t=>{var i;this.setState({sticky:!((i=t[0])!=null&&i.isIntersecting)})})}initialize(){this.observer=new IntersectionObserver(this.onIntersection)}setState(t){const i=this.state;this.state={...this.state,...t},i.sticky!==this.state.sticky&&this.render()}originalTargetConnected(t){this.observer.observe(t)}originalTargetDisconnected(t){this.observer.unobserve(t)}render(){const{stickyTarget:t}=this,i=document.documentElement;t.hidden=!this.state.sticky,this.state.sticky?i.style.setProperty(Qf,Math.floor(t.getBoundingClientRect().height)+"px"):i.style.removeProperty(Qf)}async scrollIntoView(t){var i;if(this.hasOriginalTarget){(i=this.cancelScrollWatch)==null||i.call(this);try{await this.waitForScrollEnd(),t==null||t()}catch(o){if(o!==Yf)throw o}}}waitForScrollEnd(){return new Promise((t,i)=>{let o;const l=(d,p)=>{window.removeEventListener("scroll",u),clearTimeout(o),this.cancelScrollWatch=null,d(p)},u=()=>{clearTimeout(o),o=setTimeout(()=>l(t),Xf)};if(this.cancelScrollWatch=()=>l(i,Yf),window.scrollY===0){l(t);return}window.addEventListener("scroll",u,{passive:!0}),o=setTimeout(()=>l(t),Xf),window.scrollTo({top:0,behavior:"smooth"})})}siteHeadToggle(t){const{toggle:i}=t.params;!this.hasOriginalTarget||!i||this.scrollIntoView(()=>{const o=this.application.getControllerForElementAndIdentifier(this.originalTarget,"toggle");o&&o.toggleByIds(i,!0)})}}y(fv,"targets",["original","sticky"]);const sF=Object.freeze(Object.defineProperty({__proto__:null,default:fv},Symbol.toStringTag,{value:"Module"}));class Zf extends he{initialize(){this.changeHandler=this.changeHandler.bind(this)}connect(){this.element.addEventListener("change",this.changeHandler,!1)}disconnect(){this.element.removeEventListener("change",this.changeHandler,!1)}changeHandler(){this.element.submit()}}const oF=Object.freeze(Object.defineProperty({__proto__:null,SubmitOnChangeController:Zf,default:Zf},Symbol.toStringTag,{value:"Module"}));function aF(){const r=document.createElement("input");return r.setAttribute("type","text"),r.style.position="fixed",r.style.top=0,r.style.left=0,r.style.fontSize="16px",r}const lF='[data-toggle-target="focus"]',cF='[data-action~="toggle#toggle"]',uF="data-toggle-active-class-name";class sc extends he{connect(){const{elementThresholdValue:e,countElementValue:t,textThresholdValue:i}=this;for(const o of this.targetTargets){const l=[],u=o.id||`toggle-${Si(10)}`;let d=o.getAttribute("aria-hidden")==="true"||o.getAttribute("data-toggle-hidden")==="true";const p=t?o.querySelector(t):o;let v=0;const S=p.innerText.trim().length||0;if(e)try{v=p.querySelectorAll(":scope > *:not(ul, ol), :scope > ul > *, :scope > ol > *, :scope tbody > tr").length}catch{v=0}(e&&v>e||i&&S>i)&&(d=!0),o.id||(o.id=u);const O=this.triggerTargets.filter(k=>!k.dataset.toggleTargetValue||k.dataset.toggleTargetValue===u);for(const k of O){const D=k.id||`toggle-${Si(10)}
119`,N=(k.getAttribute("aria-controls")||"").split(/\s+/).filter(B=>B);N.push(u),k.id||(k.id=D),k.setAttribute("aria-controls",N.join(" ")),k.setAttribute("aria-expanded",!d),l.push(D)}o.setAttribute("aria-labelledby",l.join(" ")),this.toggleTarget(o,!d)}this.element.addEventListener("TOGGLE_REQUEST_EXPAND",()=>{for(const o of this.targetTargets)this.toggleTarget(o,!0)})}toggle(e){const i=e.target.closest(cF).getAttribute("aria-controls");e.preventDefault(),this.toggleByIds(i)}toggleByIds(e,t=void 0){const i=e.split(/\s+/),o=this.targetTargets.filter(p=>i.includes(p.id)),l=this.targetTargets.filter(p=>!o.includes(p)),u=o[0].querySelector(lF);let d;u&&(d=aF(),document.body.prepend(d),d.focus()),requestAnimationFrame(()=>{for(const p of l)this.toggleTarget(p,!1);for(const p of o)this.toggleTarget(p,t);u&&(u.focus(),d.remove())})}toggleTarget(e,t){const{element:i}=this,o=e.id,l=e.getAttribute(uF),u=this.triggerTargets.filter(O=>O.getAttribute("aria-controls")===o),d=t!==void 0?t:e.getAttribute("aria-hidden")==="true",p=d?"false":"true",v=d?"true":"false",S=d?"add":"remove";e.setAttribute("aria-hidden",p),l&&i.classList[S](l),this.setInertValue&&(e.inert=!d);for(const O of u)O.setAttribute("aria-expanded",v)}}y(sc,"targets",["trigger","target"]),y(sc,"values",{setInert:{type:Boolean,default:!1},textThreshold:{type:Number,default:0},elementThreshold:{type:Number,default:0},countElement:{type:String,default:null}});const hF=Object.freeze(Object.defineProperty({__proto__:null,default:sc},Symbol.toStringTag,{value:"Module"})),fl="isLoggedIn",Jf="isLoggedOut",gl="hasSubscription",eg="noSubscription";class po extends he{constructor(){super(...arguments);y(this,"userState",{loggedIn:!!this.element.dataset[fl],hasSubscription:!!this.element.dataset[gl],userInfo:null})}initialize(){this.setupEventListeners(),!this.waitValue&&Qt.getUser().then(t=>{this.setUserState(t,{fromCache:!0})}).catch(t=>{throw new Error(t)}).finally(()=>{this.signinSilent()})}signinSilent(){Qt.signinSilent().then(t=>{this.setUserState(t)}).catch(t=>{switch(this.setUserState(),t.error){case"login_required":case"interaction_required":case"account_selection_required":case"consent_required":break;default:throw new Error(t)}})}setupEventListeners(){window.addEventListener(Vp,t=>{this.setUserState(t.detail.userInfo)},!1)}async setUserState(t,{fromCache:i=!1}={}){const{userState:o}=this,l=new Fl(t),u={loggedIn:(l==null?void 0:l.signedIn)||!1,hasSubscription:(l==null?void 0:l.subscriber)||!1,userInfo:t||null};if(u.loggedIn!==o.loggedIn||u.hasSubscription!==o.hasSubscription||u.userInfo!==o.userInfo){t||await Qt.removeUser();const p=new CustomEvent(Al,{detail:{userState:u,previousUserState:o}});document.dispatchEvent(p),this.userState={...o,...u},this.render()}}render(){const{element:{dataset:t},userState:i}=this,o=new Fl(i.userInfo);i.loggedIn?(t[fl]="",delete t[Jf]):(t[Jf]="",delete t[fl]),i.hasSubscription?(t[gl]="",delete t[eg]):(t[eg]="",delete t[gl]),o.hasSimpleSubscription()&&(t[Vl]=""),this.renderNameTargets(o.name)}login(t){t.preventDefault();const i=new URL(window.hopp.userManager.redirect_uri).pathname,o=window.location.pathname===i?"/":window.location.pathname;Qt.signinRedirect({state:{origin:o}})}logout(){Qt.signoutRedirect()}renderNameTargets(t){this.nameTargets.forEach(i=>{i.innerText=t||""})}}y(po,"values",{wait:{type:Boolean,default:!1}}),y(po,"targets",["name"]);const dF=Object.freeze(Object.defineProperty({__proto__:null,UserManagerController:po,default:po},Symbol.toStringTag,{value:"Module"}));(function(){const e=document.createElement("link").relList;if(e&&e.supports&&e.supports("modulepreload"))return;for(const o of document.querySelectorAll('link[rel="modulepreload"]'))i(o);new MutationObserver(o=>{for(const l of o)if(l.type==="childList")for(const u of l.addedNodes)u.tagName==="LINK"&&u.rel==="modulepreload"&&i(u)}).observe(document,{childList:!0,subtree:!0});function t(o){const l={};return o.integrity&&(l.integrity=o.integrity),o.referrerPolicy&&(l.referrerPolicy=o.referrerPolicy),o.crossOrigin==="use-credentials"?l.credentials="include":o.crossOrigin==="anonymous"?l.credentials="omit":l.credentials="same-origin",l}function i(o){if(o.ep)return;o.ep=!0;const l=t(o);fetch(o.href,l)}})();var fF=/^(?:.*?(?:controllers|components)\/|\.?\.\/)?(.+)(?:[/_-]controller\..+?)$/;function gF(r,e){r.load(pF(e))}function pF(r){return Object.entries(r).map(mF).filter(e=>e)}function mF([r,e]){var t;const i=vF(r),o=(t=e.default)!=null?t:e;if(i&&typeof o=="function")return{identifier:i,controllerConstructor:o}}function vF(r){const e=(r.match(fF)||[])[1];if(e)return e.replace(/_/g,"-").replace(/\//g,"--")}/*! adapted from: https://github.com/hotwired/stimulus-rails/blob/main/app/assets/javascripts/stimulus-loading.js */const wi="data-controller";function bF(r,e,t=document){gv(r,e,t),_F(r,e,t)}
119function gv(r,e,t){wF(t).forEach(i=>mv(i,r,e))}function _F(r,e,t){new MutationObserver(i=>{i.forEach(({attributeName:o,target:l,type:u})=>{switch(u){case"attributes":{o===wi&&l.getAttribute(wi)&&pv(l).forEach(d=>mv(d,r,e));break}case"childList":{gv(r,e,l);break}}})}).observe(t,{attributeFilter:[wi],subtree:!0,childList:!0})}function wF(r){return Array.from(r.querySelectorAll(`[${wi}]`)).map(pv).flat()}function pv(r){return r.getAttribute(wi).split(/\s+/).filter(e=>e.length)}function mv(r,e,t){vv(r,e)&&Object.entries(t).forEach(([i,o])=>{yF(i)===r&&o().then(u=>EF(r,u,e)).catch(u=>console.error(`Failed to autoload controller: ${r}`,u))})}function yF(r){return r.split("/").pop().replace(/\.[jt]s[x]?$/,"").replace(/[_-]controller/,"")}function EF(r,e,t){vv(r,t)&&t.register(r,e.default)}function vv(r,e){return!e.router.modulesByIdentifier.has(r)}const bv=oO.start();function SF(r){!(r.detail.timing.visitStart===void 0)&&document.querySelector("#fb-root")&&typeof window.FB=="object"&&typeof window.FB.XFBML=="object"&&typeof window.FB.XFBML.parse=="function"&&window.FB.XFBML.parse()}document.addEventListener("turbo:load",SF);function AF(r){!(r.detail.timing.visitStart===void 0)&&document.querySelector("[data-instgrm-permalink]")&&typeof window.instgrm=="object"&&typeof window.instgrm.Embeds=="object"&&typeof window.instgrm.Embeds.process=="function"&&window.instgrm.Embeds.process()}document.addEventListener("turbo:load",AF);const TF=Object.assign({"./controllers/ad-controller.js":q1,"./controllers/auth-callback-controller.js":V1,"./controllers/autoplay-controller.js":Q1,"./controllers/content-item-controller.js":WM,"./controllers/datawrapper-embed-controller.js":zM,"./controllers/dialog-controller.js":H1,"./controllers/embed-controller.js":nD,"./controllers/event-controller.js":oD,"./controllers/form-controller.js":uD,"./controllers/form-filter-controller.js":fD,"./controllers/google-ad-controller.js":_D,"./controllers/hide-items-controller.js":ED,"./controllers/iframe-autosize-controller.js":AD,"./controllers/in-viewport-controller.js":OD,"./controllers/lazy-load-controller.js":R$,"./controllers/multi-select-controller.js":M$,"./controllers/native-ad-controller.js":$$,"./controllers/podcast-controller.js":F$,"./controllers/popup-controller.js":N$,"./controllers/relative-time-controller.js":X$,"./controllers/required-checkbox-group-controller.js":Z$,"./controllers/scrollable-container-controller.js":J$,"./controllers/scrollbar-width-controller.js":rF,"./controllers/share-controller.js":nF,"./controllers/static-map-controller.js":iF,"./controllers/sticky-header-controller.js":sF,"./controllers/submit-on-change-controller.js":oF,"./controllers/toggle-controller.js":hF,"./controllers/user-manager-controller.js":dF}),OF=Object.assign({
119"./controllers/lazy/adform-ad-controller.js":()=>nt(()=>import("./chunks/adform-ad-controller.0f43a5d8.js"),[]),
119"./controllers/lazy/comments-controller.js":()=>nt(()=>import("./chunks/comments-controller.d79b4073.js"),[]),
119"./controllers/lazy/consent-controller.js":()=>nt(()=>import("./chunks/consent-controller.e5eae83e.js"),[]),
119"./controllers/lazy/consent-manager-controller.js":()=>nt(()=>import("./chunks/consent-manager-controller.0390cac4.js"),[]),
119"./controllers/lazy/continuous-scroll-controller.js":()=>nt(()=>import("./chunks/continuous-scroll-controller.2ed0d421.js"),[]),
119"./controllers/lazy/interactive-table-controller.js":()=>nt(()=>import("./chunks/interactive-table-controller.33a056ff.js"),[]),
119"./controllers/lazy/private-captcha-controller.js":()=>nt(()=>import("./chunks/private-captcha-controller.1849b8ad.js"),[])
119}),CF=window.document.documentElement.getAttribute("lang");bk(CF);gF(bv,TF);bF(bv,OF);Ti.start();UM();var lg,cg;(cg=(lg=window.hopp)==null?void 0:lg.adPositions)!=null&&cg.length&&bD.initialize();export{he as C,Sk as D,RF as T,nt as _,bv as a,Ys as b,aF as c,xn as d,xc as e,KM as f,To as g,dk as h,Ti as i,hm as j,Rg as k,MF as l,Om as m,HM as n,_i as o,jl as p,Hp as q,Si as r,El as t,kF as u};
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.