import{inject as m,ref as f,onMounted as p,watch as v,createBlock as C,openBlock as _,resolveDynamicComponent as g,unref as h}from"/vue.js";import{F as y,m as i,f as j}from"./nc-main.DEgIQeOo.js";import"./service-worker.DGZzV4eE.js";const D=Object.assign({name:"NcInclude"},{__name:"nc-include",props:{id:{type:String,default:void 0},include:{type:String,default:()=>""}},setup(l){const e=l,c=m("state"),t={},o=f();function s(n){n.error?i.setError(c,n.error):n.name?(t[e.include]=n,j(n,!1),o.value=n.name):i.setError(c,`component${e.include} hass no name`)}function u(n){const r={error:n,name:""};t[e.include]=r,o.value=r.name}function d(){t[e.include]?o.value=t[e.include].name:y(e.include,!1,s,u,!1)}let a="";return p(()=>{v(()=>e.include,()=>{a!==e.include&&(a=e.include,d())},{immediate:!0})}),(n,r)=>(_(),C(g(h(o))))}});export{D as default};
