import{h as e}from"./p-ee1e0eb4.js";const t=(()=>{let t=new Map,r={historyType:"browser",location:{pathname:"",query:{},key:""},titleSuffix:"",root:"/",routeViewsUpdated:()=>{}};const o=(e,t)=>{Array.isArray(e)?[...e].forEach((e=>{t[e]=r[e]})):t[e]=Object.assign({},r)},s=(e,r)=>(t.has(e)||(t.set(e,r),o(r,e)),()=>{t.has(e)&&t.delete(e)});return{Provider:({state:e},s)=>(r=e,t.forEach(o),s),Consumer:(t,r)=>((t,r)=>e("context-consumer",{subscribe:t,renderer:r}))(s,r[0]),injectProps:(e,r)=>{const o=e.prototype,n=o.connectedCallback,i=o.disconnectedCallback;o.connectedCallback=function(){if(s(this,r),n)return n.call(this)},o.disconnectedCallback=function(){t.delete(this),i&&i.call(this)}}}})();export{t as A}