1import{r as e,G as a,H as t,b as l,d as o}from"./element-plus.80abf16b.js";import{c1 as s,bK as n,bM as d,c2 as u,c7 as i,c8 as m,cn as r,ca as c,cg as p,ce as f,cc as v,cf as b,bP as g}from"./commonmodules.b9c1dd40.js";import{_ as j,u as y}from"./index.d3bd9396.js";import _ from"./Editor.55912a5f.js";import"./@progress.f46c2525.js";import"./lodash-es.480d1bd8.js";import"./axios.1263d4b1.js";import"./vue-router.5e13d197.js";import"./ImageSetting.fe71fb75.js";import"./model.b2b31a9c.js";import"./UploadImage.ce0d4033.js";import"./consts.99054894.js";import"./VideoSetting.32156b82.js";import"./Setting.4d5824df.js";import"./UploadFile.0c31b3c9.js";import"./FlagSetting.fe20b0e2.js";const V={class:"dialog-footer"};var S=j(s({__name:"TextFieldSetting",props:{domId:null,title:null,componentData:null,save:{type:Function}},setup(s,{expose:j}){const S=s,x=y(),D=n((()=>x.state.detail.metadata.filter((e=>0==e.type)).map((e=>e.name)))),U=d({content:"",style:""});S.componentData&&(U.value=JSON.parse(null==S?void 0:S.componentData));const k=d(!1),F=d(),I=async()=>{var e;k.value=!k.value,k.value&&(null==S?void 0:S.componentData)?U.value=JSON.parse(S.componentData):(null==(e=F.value)||e.setHtml(U.value.content),await r())},h=()=>{var e;U.value.content=null==(e=F.value)?void 0:e.getHtml(),S.save(U.value),I()};return j({toggleDialog:I}),(n,d)=>{const r=e,j=a,y=t,S=l,x=o;return u(),i(x,{modelValue:k.value,"onUpdate:modelValue":d[2]||(d[2]=e=>k.value=e),title:s.title,width:"80%",class:"camps-setting-dialog","close-on-click-modal":!1},{footer:m((()=>[c("span",V,[p(S,{type:"primary",onClick:h},{default:m((()=>[f("Save")])),_:1}),p(S,{onClick:I},{default:m((()=>[f("Cancel")])),_:1})])])),default:m((()=>[p(y,{"label-width":"auto"},{default:m((()=>[p(j,{label:"style"},{default:m((()=>[p(r,{type:"textarea",modelValue:U.value.style,"onUpdate:modelValue":d[0]||(d[0]=e=>U.value.style=e)},null,8,["modelValue"])])),_:1}),p(j,{label:"content"},{default:m((()=>[(u(),i(v("style"),null,{default:m((()=>[f(b(U.value.style||""),1)])),_:1})),p(_,{ref_key:"editorRef",ref:F,modelValue:U.value.content,"onUpdate:modelValue":d[1]||(d[1]=e=>U.value.content=e),"insert-field-names":g(D)},null,8,["modelValue","insert-field-names"])])),_:1})])),_:1})])),_:1},8,["modelValue","title"])}}}),[["__scopeId","data-v-8118d7c0"]]);export{S as default};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.