import{r as t,h as o,H as e,c as i,d as n}from"./p-38dcedc4.js";import{g as s,c as r,a}from"./p-202e7480.js";import{g as c}from"./p-8f72be08.js";import{b as h,c as u,d as l}from"./p-5a5a5c96.js";import{l as d,t as f,s as p,L as m,a as w,b as v}from"./p-a5c39d62.js";import{a as b}from"./p-285477f2.js";const g=class{constructor(o){t(this,o)}componentWillLoad(){as.store.data.appLoaded=!0}render(){return o("ion-app",null,o("ion-router",null,o("ion-route",{url:"/",component:"app-home"}),o("ion-route",{url:"/*",component:"app-home"})),o("ion-nav",null))}};g.style="";const y=class{constructor(o){t(this,o)}componentDidLoad(){j((async()=>{const t=a(window,"hybrid");r.getBoolean("_testing")||import("./p-233637dc.js").then((t=>t.startTapClick(r))),r.getBoolean("statusTap",t)&&import("./p-a4558baf.js").then((t=>t.startStatusTap())),r.getBoolean("inputShims",C())&&import("./p-c62f7f74.js").then((t=>t.startInputShims(r)));const o=await import("./p-f2660943.js");r.getBoolean("hardwareBackButton",t)?o.startHardwareBackButton():o.blockHardwareBackButton(),"undefined"!=typeof window&&import("./p-2e4e8117.js").then((t=>t.startKeyboardAssist(window))),import("./p-aef0bba0.js").then((t=>t.startFocusVisible()))}))}render(){const t=s(this);return o(e,{class:{[t]:!0,"ion-page":!0,"force-statusbar-padding":r.getBoolean("_forceStatusbarPadding")}})}get el(){return i(this)}},C=()=>a(window,"ios")&&a(window,"mobile"),j=t=>{"requestIdleCallback"in window?window.requestIdleCallback(t):setTimeout(t,32)};y.style="html.plt-mobile ion-app{user-select:none}html.plt-mobile ion-app [contenteditable]{user-select:text}ion-app.force-statusbar-padding{--ion-safe-area-top:20px}";class P{constructor(t,o){this.component=t,this.params=o,this.state=1}async init(t){if(this.state=2,!this.element){const o=this.component;this.element=await b(this.delegate,t,o,["ion-page","ion-page-invisible"],this.params)}}_destroy(){h(3!==this.state,"view state must be ATTACHED");const t=this.element;t&&(this.delegate?this.delegate.removeViewFromDom(t.parentElement,t):t.remove()),this.nav=void 0,this.state=3}}const R=(t,o,e)=>{if(!t)return!1;if(t.component!==o)return!1;const i=t.params;if(i===e)return!0;if(!i&&!e)return!0;if(!i||!e)return!1;const n=Object.keys(i),s=Object.keys(e);if(n.length!==s.length)return!1;for(const t of n)if(i[t]!==e[t])return!1;return!0},k=(t,o)=>t?t instanceof P?t:new P(t,o):null,E=class{constructor(o){t(this,o),this.ionNavWillLoad=n(this,"ionNavWillLoad",7),this.ionNavWillChange=n(this,"ionNavWillChange",3),this.ionNavDidChange=n(this,"ionNavDidChange",3),this.transInstr=[],this.animationEnabled=!0,this.useRouter=!1,this.isTransitioning=!1,this.destroyed=!1,this.views=[],this.animated=!0}swipeGestureChanged(){this.gesture&&this.gesture.enable(!0===this.swipeGesture)}rootChanged(){void 0!==this.root&&(this.useRouter||this.setRoot(this.root,this.rootParams))}componentWillLoad(){if(this.useRouter=!!document.querySelector("ion-router")&&!this.el.closest("[no-router]"),void 0===this.swipeGesture){const t=s(this);this.swipeGesture=r.getBoolean("swipeBackEnabled","ios"===t)}this.ionNavWillLoad.emit()}async componentDidLoad(){this.rootChanged(),this.gesture=(await import("./p-7d99f5f4.js")).createSwipeBackGesture(this.el,this.canStart.bind(this),this.onStart.bind(this),this.onMove.bind(this),this.onEnd.bind(this)),this.swipeGestureChanged()}disconnectedCallback(){for(const t of this.views)d(t.element,m),t._destroy();this.gesture&&(this.gesture.destroy(),this.gesture=void 0),this.transInstr.length=this.views.length=0,this.destroyed=!0}push(t,o,e,i){return this.queueTrns({insertStart:-1,insertViews:[{component:t,componentProps:o}],opts:e},i)}insert(t,o,e,i,n){return this.queueTrns({insertStart:t,insertViews:[{component:o,componentProps:e}],opts:i},n)}insertPages(t,o,e,i){return this.queueTrns({insertStart:t,insertViews:o,opts:e},i)}pop(t,o){return this.queueTrns({removeStart:-1,removeCount:1,opts:t},o)}popTo(t,o,e){const i={removeStart:-1,removeCount:-1,opts:o};return"object"==typeof t&&t.component?(i.removeView=t,i.removeStart=1):"number"==typeof t&&(i.removeStart=t+1),this.queueTrns(i,e)}popToRoot(t,o){return this.queueTrns({removeStart:1,removeCount:-1,opts:t},o)}removeIndex(t,o=1,e,i){return this.queueTrns({removeStart:t,removeCount:o,opts:e},i)}setRoot(t,o,e,i){return this.setPages([{component:t,componentProps:o}],e,i)}setPages(t,o,e){return null==o&&(o={}),!0!==o.animated&&(o.animated=!1),this.queueTrns({insertStart:0,insertViews:t,removeStart:0,removeCount:-1,opts:o},e)}setRouteId(t,o,e,i){const n=this.getActiveSync();if(R(n,t,o))return Promise.resolve({changed:!1,element:n.element});let s;const r=new Promise((t=>s=t));let a;const c={updateURL:!1,viewIsReady:t=>{let o;const e=new Promise((t=>o=t));return s({changed:!0,element:t,markVisible:async()=>{o(),await a}}),e}};if("root"===e)a=this.setRoot(t,o,c);else{const n=this.views.find((e=>R(e,t,o)));n?a=this.popTo(n,Object.assign(Object.assign({},c),{direction:"back",animationBuilder:i})):"forward"===e?a=this.push(t,o,Object.assign(Object.assign({},c),{animationBuilder:i})):"back"===e&&(a=this.setRoot(t,o,Object.assign(Object.assign({},c),{direction:"back",animated:!0,animationBuilder:i})))}return r}async getRouteId(){const t=this.getActiveSync();return t?{id:t.element.tagName,params:t.params,element:t.element}:void 0}getActive(){return Promise.resolve(this.getActiveSync())}getByIndex(t){return Promise.resolve(this.views[t])}canGoBack(t){return Promise.resolve(this.canGoBackSync(t))}getPrevious(t){return Promise.resolve(this.getPreviousSync(t))}getLength(){return this.views.length}getActiveSync(){return this.views[this.views.length-1]}canGoBackSync(t=this.getActiveSync()){return!(!t||!this.getPreviousSync(t))}getPreviousSync(t=this.getActiveSync()){if(!t)return;const o=this.views,e=o.indexOf(t);return e>0?o[e-1]:void 0}async queueTrns(t,o){if(this.isTransitioning&&null!=t.opts&&t.opts.skipIfBusy)return Promise.resolve(!1);const e=new Promise(((o,e)=>{t.resolve=o,t.reject=e}));if(t.done=o,t.opts&&!1!==t.opts.updateURL&&this.useRouter){const o=document.querySelector("ion-router");if(o){const e=await o.canTransition();if(!1===e)return Promise.resolve(!1);if("string"==typeof e)return o.push(e,t.opts.direction||"back"),Promise.resolve(!1)}}return t.insertViews&&0===t.insertViews.length&&(t.insertViews=void 0),this.transInstr.push(t),this.nextTrns(),e}success(t,o){if(this.destroyed)this.fireError("nav controller was destroyed",o);else if(o.done&&o.done(t.hasCompleted,t.requiresTransition,t.enteringView,t.leavingView,t.direction),o.resolve(t.hasCompleted),!1!==o.opts.updateURL&&this.useRouter){const o=document.querySelector("ion-router");o&&o.navChanged("back"===t.direction?"back":"forward")}}failed(t,o){this.destroyed?this.fireError("nav controller was destroyed",o):(this.transInstr.length=0,this.fireError(t,o))}fireError(t,o){o.done&&o.done(!1,!1,t),o.reject&&!this.destroyed?o.reject(t):o.resolve(!1)}nextTrns(){if(this.isTransitioning)return!1;const t=this.transInstr.shift();return!!t&&(this.runTransition(t),!0)}async runTransition(t){try{this.ionNavWillChange.emit(),this.isTransitioning=!0,this.prepareTI(t);const o=this.getActiveSync(),e=this.getEnteringView(t,o);if(!o&&!e)throw new Error("no views in the stack to be removed");e&&1===e.state&&await e.init(this.el),this.postViewInit(e,o,t);const i=(t.enteringRequiresTransition||t.leavingRequiresTransition)&&e!==o;i&&t.opts&&o&&("back"===t.opts.direction&&(t.opts.animationBuilder=t.opts.animationBuilder||e&&e.animationBuilder),o.animationBuilder=t.opts.animationBuilder);const n=i?await this.transition(e,o,t):{hasCompleted:!0,requiresTransition:!1};this.success(n,t),this.ionNavDidChange.emit()}catch(o){this.failed(o,t)}this.isTransitioning=!1,this.nextTrns()}prepareTI(t){const o=this.views.length;if(t.opts=t.opts||{},void 0===t.opts.delegate&&(t.opts.delegate=this.delegate),void 0!==t.removeView){h(void 0!==t.removeStart,"removeView needs removeStart"),h(void 0!==t.removeCount,"removeView needs removeCount");const o=this.views.indexOf(t.removeView);if(o<0)throw new Error("removeView was not found");t.removeStart+=o}void 0!==t.removeStart&&(t.removeStart<0&&(t.removeStart=o-1),t.removeCount<0&&(t.removeCount=o-t.removeStart),t.leavingRequiresTransition=t.removeCount>0&&t.removeStart+t.removeCount===o),t.insertViews&&((t.insertStart<0||t.insertStart>o)&&(t.insertStart=o),t.enteringRequiresTransition=t.insertStart===o);const e=t.insertViews;if(!e)return;h(e.length>0,"length can not be zero");const i=e.map((t=>t instanceof P?t:"component"in t?k(t.component,null===t.componentProps?void 0:t.componentProps):k(t,void 0))).filter((t=>null!==t));if(0===i.length)throw new Error("invalid views to insert");for(const o of i){o.delegate=t.opts.delegate;const e=o.nav;if(e&&e!==this)throw new Error("inserted view was already inserted");if(3===o.state)throw new Error("inserted view was already destroyed")}t.insertViews=i}getEnteringView(t,o){const e=t.insertViews;if(void 0!==e)return e[e.length-1];const i=t.removeStart;if(void 0!==i){const e=this.views,n=i+t.removeCount;for(let t=e.length-1;t>=0;t--){const s=e[t];if((t<i||t>=n)&&s!==o)return s}}}postViewInit(t,o,e){h(o||t,"Both leavingView and enteringView are null"),h(e.resolve,"resolve must be valid"),h(e.reject,"reject must be valid");const i=e.opts,n=e.insertViews,s=e.removeStart,r=e.removeCount;let a;if(void 0!==s&&void 0!==r){h(s>=0,"removeStart can not be negative"),h(r>=0,"removeCount can not be negative"),a=[];for(let e=0;e<r;e++){const i=this.views[e+s];i&&i!==t&&i!==o&&a.push(i)}i.direction=i.direction||"back"}const c=this.views.length+(void 0!==n?n.length:0)-(void 0!==r?r:0);if(h(c>=0,"final balance can not be negative"),0===c)throw console.warn("You can't remove all the pages in the navigation stack. nav.pop() is probably called too many times.",this,this.el),new Error("navigation stack needs at least one root page");if(n){let t=e.insertStart;for(const o of n)this.insertViewAt(o,t),t++;e.enteringRequiresTransition&&(i.direction=i.direction||"forward")}if(a&&a.length>0){for(const t of a)d(t.element,w),d(t.element,v),d(t.element,m);for(const t of a)this.destroyView(t)}}async transition(t,o,e){const i=e.opts,n=i.progressAnimation?t=>this.sbAni=t:void 0,a=s(this),c=t.element,h=o&&o.element,u=Object.assign({mode:a,showGoBack:this.canGoBackSync(t),baseEl:this.el,animationBuilder:this.animation||i.animationBuilder||r.get("navAnimation"),progressCallback:n,animated:this.animated&&r.getBoolean("animated",!0),enteringEl:c,leavingEl:h},i),{hasCompleted:l}=await f(u);return this.transitionFinish(l,t,o,i)}transitionFinish(t,o,e,i){const n=t?o:e;return n&&this.cleanup(n),{hasCompleted:t,requiresTransition:!0,enteringView:o,leavingView:e,direction:i.direction}}insertViewAt(t,o){const e=this.views,i=e.indexOf(t);i>-1?(h(t.nav===this,"view is not part of the nav"),e.splice(o,0,e.splice(i,1)[0])):(h(!t.nav,"nav is used"),t.nav=this,e.splice(o,0,t))}removeView(t){h(2===t.state||3===t.state,"view state should be loaded or destroyed");const o=this.views,e=o.indexOf(t);h(e>-1,"view must be part of the stack"),e>=0&&o.splice(e,1)}destroyView(t){t._destroy(),this.removeView(t)}cleanup(t){if(this.destroyed)return;const o=this.views,e=o.indexOf(t);for(let t=o.length-1;t>=0;t--){const i=o[t],n=i.element;n&&(t>e?(d(n,m),this.destroyView(i)):t<e&&p(n,!0))}}canStart(){return!!this.swipeGesture&&!this.isTransitioning&&0===this.transInstr.length&&this.animationEnabled&&this.canGoBackSync()}onStart(){this.queueTrns({removeStart:-1,removeCount:1,opts:{direction:"back",progressAnimation:!0}},void 0)}onMove(t){this.sbAni&&this.sbAni.progressStep(t)}onEnd(t,o,e){if(this.sbAni){this.animationEnabled=!1,this.sbAni.onFinish((()=>{this.animationEnabled=!0}),{oneTimeCallback:!0});let i=t?-.001:.001;t?i+=c([0,0],[.32,.72],[0,1],[1,1],o)[0]:(this.sbAni.easing("cubic-bezier(1, 0, 0.68, 0.28)"),i+=c([0,0],[1,0],[.68,.28],[1,1],o)[0]),this.sbAni.progressEnd(t?1:0,i,e)}}render(){return o("slot",null)}get el(){return i(this)}static get watchers(){return{swipeGesture:["swipeGestureChanged"],root:["rootChanged"]}}};E.style=":host{left:0;right:0;top:0;bottom:0;position:absolute;contain:layout size style;overflow:hidden;z-index:0}";const S=class{constructor(o){t(this,o),this.ionRouteDataChanged=n(this,"ionRouteDataChanged",7),this.url=""}onUpdate(t){this.ionRouteDataChanged.emit(t)}onComponentProps(t,o){if(t===o)return;const e=t?Object.keys(t):[],i=o?Object.keys(o):[];if(e.length===i.length){for(const i of e)if(t[i]!==o[i])return void this.onUpdate(t)}else this.onUpdate(t)}connectedCallback(){this.ionRouteDataChanged.emit()}static get watchers(){return{url:["onUpdate"],component:["onUpdate"],componentProps:["onComponentProps"]}}},T=t=>"/"+t.filter((t=>t.length>0)).join("/"),O=t=>{if(null==t)return[""];const o=t.split("?")[0].split("/").map((t=>t.trim())).filter((t=>t.length>0));return 0===o.length?[""]:o},L=async(t,o,e,i,n=!1,s)=>{try{const r=U(t);if(i>=o.length||!r)return n;await new Promise((t=>u(r,t)));const a=o[i],c=await r.setRouteId(a.id,a.params,e,s);return c.changed&&(e="root",n=!0),n=await L(c.element,o,e,i+1,n,s),c.markVisible&&await c.markVisible(),n}catch(t){return console.error(t),!1}},V=":not([no-router]) ion-nav, :not([no-router]) ion-tabs, :not([no-router]) ion-router-outlet",U=t=>{if(!t)return;if(t.matches(V))return t;return t.querySelector(V)||void 0},B=(t,o)=>o.find((o=>((t,o)=>{const{from:e,to:i}=o;if(void 0===i)return!1;if(e.length>t.length)return!1;for(let o=0;o<e.length;o++){const i=e[o];if("*"===i)return!0;if(i!==t[o])return!1}return e.length===t.length})(t,o))),I=(t,o)=>{const e=Math.min(t.length,o.length);let i=0;for(;i<e&&t[i].toLowerCase()===o[i].id;i++);return i},D=(t,o)=>{const e=new W(t);let i,n=!1;for(let t=0;t<o.length;t++){const s=o[t].path;if(""===s[0])n=!0;else{for(const o of s){const n=e.next();if(":"===o[0]){if(""===n)return null;i=i||[],(i[t]||(i[t]={}))[o.slice(1)]=n}else if(n!==o)return null}n=!1}}return n&&n!==(""===e.next())?null:i?o.map(((t,o)=>({id:t.id,path:t.path,params:A(t.params,i[o]),beforeEnter:t.beforeEnter,beforeLeave:t.beforeLeave}))):o},A=(t,o)=>t||o?Object.assign(Object.assign({},t),o):void 0,N=(t,o)=>{let e=null,i=0;for(const n of o){const o=D(t,n);if(null!==o){const t=x(o);t>i&&(i=t,e=o)}}return e},x=t=>{let o=1,e=1;for(const i of t)for(const t of i.path)":"===t[0]?o+=Math.pow(1,e):""!==t&&(o+=Math.pow(2,e)),e++;return o};class W{constructor(t){this.path=t.slice()}next(){return this.path.length>0?this.path.shift():""}}const $=t=>Array.from(t.children).filter((t=>"ION-ROUTE-REDIRECT"===t.tagName)).map((t=>{const o=q(t,"to");return{from:O(q(t,"from")),to:null==o?void 0:O(o)}})),_=t=>M(G(t)),G=(t,o=t)=>Array.from(o.children).filter((t=>"ION-ROUTE"===t.tagName&&t.component)).map((o=>{const e=q(o,"component");if(null==e)throw new Error("component missing in ion-route");return{path:O(q(o,"url")),id:e.toLowerCase(),params:o.componentProps,beforeLeave:o.beforeLeave,beforeEnter:o.beforeEnter,children:G(t,o)}})),q=(t,o)=>o in t?t[o]:t.hasAttribute(o)?t.getAttribute(o):null,M=t=>{const o=[];for(const e of t)z([],o,e);return o},z=(t,o,e)=>{const i=t.slice();if(i.push({id:e.id,path:e.path,params:e.params,beforeLeave:e.beforeLeave,beforeEnter:e.beforeEnter}),0!==e.children.length)for(const t of e.children)z(i,o,t);else o.push(i)},H=class{constructor(o){t(this,o),this.ionRouteWillChange=n(this,"ionRouteWillChange",7),this.ionRouteDidChange=n(this,"ionRouteDidChange",7),this.previousPath=null,this.busy=!1,this.state=0,this.lastState=0,this.root="/",this.useHash=!0}async componentWillLoad(){console.debug("[ion-router] router will load"),await(U(document.body)?Promise.resolve():new Promise((t=>{window.addEventListener("ionNavWillLoad",t,{once:!0})}))),console.debug("[ion-router] found nav"),await this.onRoutesChanged()}componentDidLoad(){window.addEventListener("ionRouteRedirectChanged",l(this.onRedirectChanged.bind(this),10)),window.addEventListener("ionRouteDataChanged",l(this.onRoutesChanged.bind(this),100))}async onPopState(){const t=this.historyDirection();let o=this.getPath();const e=await this.runGuards(o);return!0!==e?("object"==typeof e&&(o=O(e.redirect)),!1):(console.debug("[ion-router] URL changed -> update nav",o,t),this.writeNavStateRoot(o,t))}onBackButton(t){t.detail.register(0,(t=>{this.back(),t()}))}async canTransition(){const t=await this.runGuards();return!0===t||"object"==typeof t&&t.redirect}async push(t,o="forward",e){t.startsWith(".")&&(t=new URL(t,window.location.href).pathname),console.debug("[ion-router] URL pushed -> updating nav",t,o);let i=O(t),n=t.split("?")[1];const s=await this.runGuards(i);if(!0!==s){if("object"!=typeof s)return!1;i=O(s.redirect),n=s.redirect.split("?")[1]}return this.setPath(i,o,n),this.writeNavStateRoot(i,o,e)}back(){return window.history.back(),Promise.resolve(this.waitPromise)}async printDebug(){console.debug("CURRENT PATH",this.getPath()),console.debug("PREVIOUS PATH",this.previousPath),(t=>{console.group(`[ion-core] ROUTES[${t.length}]`);for(const o of t){const t=[];o.forEach((o=>t.push(...o.path)));const e=o.map((t=>t.id));console.debug(`%c ${T(t)}`,"font-weight: bold; padding-left: 20px","=>\t",`(${e.join(", ")})`)}console.groupEnd()})(_(this.el)),(t=>{console.group(`[ion-core] REDIRECTS[${t.length}]`);for(const o of t)o.to&&console.debug("FROM: ",`$c ${T(o.from)}`,"font-weight: bold"," TO: ",`$c ${T(o.to)}`,"font-weight: bold");console.groupEnd()})($(this.el))}async navChanged(t){if(this.busy)return console.warn("[ion-router] router is busy, navChanged was cancelled"),!1;const{ids:o,outlet:e}=await(async()=>{const t=[];let o,e=window.document.body;for(;o=U(e),o;){const i=await o.getRouteId();if(!i)break;e=i.element,i.element=void 0,t.push(i)}return{ids:t,outlet:o}})(),i=((t,o)=>{let e=null,i=0;const n=t.map((t=>t.id));for(const t of o){const o=I(n,t);o>i&&(e=t,i=o)}return e?e.map(((o,e)=>({id:o.id,path:o.path,params:A(o.params,t[e]&&t[e].params)}))):null})(o,_(this.el));if(!i)return console.warn("[ion-router] no matching URL for ",o.map((t=>t.id))),!1;const n=(t=>{const o=[];for(const e of t)for(const t of e.path)if(":"===t[0]){const i=e.params&&e.params[t.slice(1)];if(!i)return null;o.push(i)}else""!==t&&o.push(t);return o})(i);return n?(console.debug("[ion-router] nav changed -> update URL",o,n),this.setPath(n,t),await this.safeWriteNavState(e,i,"root",n,null,o.length),!0):(console.warn("[ion-router] router could not match path because some required param is missing"),!1)}onRedirectChanged(){const t=this.getPath();t&&B(t,$(this.el))&&this.writeNavStateRoot(t,"root")}onRoutesChanged(){return this.writeNavStateRoot(this.getPath(),"root")}historyDirection(){const t=window;null===t.history.state&&(this.state++,t.history.replaceState(this.state,t.document.title,t.document.location&&t.document.location.href));const o=t.history.state,e=this.lastState;return this.lastState=o,o>e||o>=e&&e>0?"forward":o<e?"back":"root"}async writeNavStateRoot(t,o,e){if(!t)return console.error("[ion-router] URL is not part of the routing set"),!1;const i=$(this.el),n=B(t,i);let s=null;n&&(this.setPath(n.to,o),s=n.from,t=n.to);const r=_(this.el),a=N(t,r);return a?this.safeWriteNavState(document.body,a,o,t,s,0,e):(console.error("[ion-router] the path does not match any route"),!1)}async safeWriteNavState(t,o,e,i,n,s=0,r){const a=await this.lock();let c=!1;try{c=await this.writeNavState(t,o,e,i,n,s,r)}catch(t){console.error(t)}return a(),c}async lock(){const t=this.waitPromise;let o;return this.waitPromise=new Promise((t=>o=t)),void 0!==t&&await t,o}async runGuards(t=this.getPath(),o=O(this.previousPath)){if(!t||!o)return!0;const e=_(this.el),i=N(t,e),n=N(o,e),s=i&&i[i.length-1].beforeEnter,r=n&&n[n.length-1].beforeLeave,a=!r||await r();if(!1===a||"object"==typeof a)return a;const c=!s||await s();return!1!==c&&"object"!=typeof c||c}async writeNavState(t,o,e,i,n,s=0,r){if(this.busy)return console.warn("[ion-router] router is busy, transition was cancelled"),!1;this.busy=!0;const a=this.routeChangeEvent(i,n);a&&this.ionRouteWillChange.emit(a);const c=await L(t,o,e,s,!1,r);return this.busy=!1,c&&console.debug("[ion-router] route changed",i),a&&this.ionRouteDidChange.emit(a),c}setPath(t,o,e){this.state++,((t,o,e,i,n,s,r)=>{let a=T([...O(this.root),...i]);e&&(a="#"+a),void 0!==r&&(a=a+"?"+r),"forward"===n?t.pushState(s,"",a):t.replaceState(s,"",a)})(window.history,0,this.useHash,t,o,this.state,e)}getPath(){return((t,o)=>{let e=t.pathname;if(this.useHash){const o=t.hash;e="#"===o[0]?o.slice(1):""}return((t,o)=>{if(t.length>o.length)return null;if(t.length<=1&&""===t[0])return o;for(let e=0;e<t.length;e++)if(t[e].length>0&&t[e]!==o[e])return null;return o.length===t.length?[""]:o.slice(t.length)})(O(o),O(e))})(window.location,this.root)}routeChangeEvent(t,o){const e=this.previousPath,i=T(t);return this.previousPath=i,i===e?null:{from:e,redirectedFrom:o?T(o):null,to:i}}get el(){return i(this)}};export{g as app_root,y as ion_app,E as ion_nav,S as ion_route,H as ion_router}