import{d,e as _,a as y,w as C,f as h,i as v,n as x}from"./vendor-vue-runtime-core-DwK6Ry68.js";import{t as S,r as A,u as k}from"./vendor-vue-reactivity-CheHbvBM.js";import{a as w}from"./vendor-vue-shared-DrzsEcag.js";const E=["innerHTML"],B=d({__name:"Html",props:{field:{}},setup(l){const i=l,{field:r}=S(i),u=_(()=>{var t;return((t=r.value)==null?void 0:t.additionalStyles)||""}),o=A(null);function f(t){var c;const a=Array.from(t.querySelectorAll("script"));for(const e of a){const n=document.createElement("script");for(const{name:p,value:m}of Array.from(e.attributes))try{n.setAttribute(p,m)}catch{}e.src?n.src=e.src:n.textContent=e.textContent||"",(c=e.parentNode)==null||c.replaceChild(n,e)}}async function s(){o.value&&(await x(),f(o.value))}return y(()=>{s()}),C(()=>{var t;return(t=r.value)==null?void 0:t.htmlContent},()=>{s()}),(t,a)=>(v(),h("div",{class:w(["ccb-field",{[u.value]:!0}]),ref_key:"rootEl",ref:o,innerHTML:k(r).htmlContent},null,10,E))}});export{B as default};
//# sourceMappingURL=index-B4sbTxdE.js.map
