import{d as g,o as t,e as s,a as c,b as e,t as v,f as l,F as x,g as b,c as d,w as h,A as y,n as C,aa as V}from"./BvNnk7SS.js";import F from"./BqNcruSh.js";import{u as w}from"./CIaRsw82.js";import"./CYKwSea8.js";import"./BOtdTvFK.js";import"./9QyWfnsF.js";import"./eQq4h1B_.js";const B=V(F),D=["id"],E={contenteditable:"false",mt2:"",rounded:"","bg-active":"","px1.5":""},O={key:0,py1:"","text-xs":"","text-orange":""},U={key:1,flex:"","items-center":"",gap2:""},I=g({__name:"GenericComponentEditor",props:{contentRef:{type:[String,Object,Function]},view:{},getPos:{type:Function},setAttrs:{type:Function},node:{},selected:{},decorations:{},innerDecorations:{}},setup(p){const a=p,{getComponentProps:m}=w(),{componentName:r,mdcAttrs:n,model:i}=m(a,{}),u=!1;return(j,k)=>{const _=B;return t(),s("div",{id:e(i).id,relative:"",class:C(["group",e(i).class])},[c("div",E,[e(u)?(t(),s("div",O,v(`Unable to find editor for this component "${e(r)}". Dev only notice. `),1)):l("",!0),Object.keys(e(n)).length?(t(),s("div",U,[(t(!0),s(x,null,b(Object.keys(e(n)),o=>(t(),d(_,{key:o,modelValue:e(n)[o],"onUpdate:modelValue":f=>e(n)[o]=f,tooltip:o,label:o},null,8,["modelValue","onUpdate:modelValue","tooltip","label"]))),128))])):l("",!0)]),(t(),d(y(e(r)),null,{default:h(()=>[c("div",{ref:a.contentRef},null,512)]),_:1}))],10,D)}}});export{I as default};
