import{u as L}from"./useFormEdit-fb8b8504-1782729249161v=1.0.0.js";import{g as B}from"./activityStyleApi-17b52feb-1782729249161v=1.0.0.js";import{b as I,a as R,D as h,_ as M}from"./index-b309bf9f-1782729249161v=1.0.0.js";import N from"./PreviewIframe-4aa0ca39-1782729249161v=1.0.0.js";import{E as q}from"./eleVendor-5008d1ec-1782729249161v=1.0.0.js";import{y as g,r as o,m as U,al as r,z as m,A as y,R as s,J as n,u as a,M as d,Q as V,a4 as O,I as v,F as T,O as H,P as J,k as Z}from"./vendor-1e24e3ad-1782729249161v=1.0.0.js";import"./keepAlive-20a782c5-1782729249161v=1.0.0.js";import"./useIframe-b1cfd5ff-1782729249161v=1.0.0.js";const z={class:"outerContainer"},Q=g({name:"activityStyleDetail"}),j=g({...Q,setup(G){const x=o({xs:24,sm:22,md:20,lg:14,xl:23}),F=o({xs:24,sm:24,md:12,lg:12,xl:12}),k=o({xs:24,sm:22,md:18,lg:16,xl:8});L(),I();const t=o({}),u=R(),b=o(""),C=o([{key:"title",col:1,label:"\u6807\u9898 "},{key:"tagsStr",col:1,label:"\u6807\u7B7E"},{key:"img",col:1,label:"\u98CE\u91C7\u56FE\u7247",type:"imgs"},{key:"description",col:1,label:"\u6587\u5B57\u63CF\u8FF0"}]),E=o({1:x,2:F,3:k}),w=()=>{window.open(t.value.liveUrl)},D=async p=>{var i;let e=await B(p);if(e.code!==0){q.error(e.msg);return}if(e.data,e.data.images){const c=JSON.parse(e.data.images||"[]");e.data.img=c.map(_=>_.url)}e.data.tagsStr=e.data.tags,e.data.tags=(i=e.data.tags)==null?void 0:i.split(","),t.value={...e.data}};return U(()=>{u.query.id&&(b.value=u.query.id,t.value.id=u.query.id,D(u.query.id))}),(p,e)=>{const i=r("PaCol"),c=r("PaRow"),_=r("el-link"),P=r("el-form-item"),S=r("el-form"),f=r("HZPageLayout");return m(),y("div",z,[s(f,{isBack:!0,title:a(u).meta.title,style:{flex:"4"}},{default:n(()=>[s(S,{model:a(t),ref:"ruleFormRef","label-width":"170px"},{default:n(()=>[d(' <div class="divider mt16 mb28">\u57FA\u672C\u4FE1\u606F</div> '),s(c,null,{default:n(()=>[(m(!0),y(V,null,O(a(C),(l,A)=>(m(),v(i,T({key:A},{ref_for:!0},a(E)[l.col]),{default:n(()=>[s(h,{label:l.label,value:a(t)[l.key],type:l.type,enum:l.enum},null,8,["label","value","type","enum"])]),_:2},1040))),128))]),_:1}),a(t).liveUrl?(m(),v(P,{key:0,label:"\u76F4\u64AD\u94FE\u63A5\uFF1A"},{default:n(()=>[s(_,{type:"primary",onClick:w},{default:n(()=>[H(J(a(t).liveUrl),1)]),_:1})]),_:1})):d("v-if",!0),d(` <el-form-item>\r
					<div class="pt20 mt30">\r
						<el-button @click="onCancel">\u8FD4\u56DE</el-button>\r
					</div>\r
				</el-form-item> `)]),_:1},8,["model"])]),_:1},8,["title"]),s(f,{title:"\u6548\u679C\u9884\u89C8",style:{flex:"2","min-width":"300px"}},{default:n(()=>[d(" {{ baseForm }} "),s(N,{value:a(t),"onUpdate:value":e[0]||(e[0]=l=>Z(t)?t.value=l:null),iframeMode:"EVENT_ADD",pageType:"add"},null,8,["value"])]),_:1})])}}});const le=M(j,[["__scopeId","data-v-1832277a"]]);export{le as default};
