import{_ as F}from"./index.b3c8a5bf.js";import{C as U,D,F as A,K as k,w as P}from"./element-plus.8e273e86.js";import{T as R,E as N}from"./@wangeditor.2af95eac.js";import{_ as T}from"./picker.0c49888f.js";import{w}from"./index.2078eb25.js";import{d as h,s as y,r as x,b as C,C as I,o as g,c as E,U as a,u as l,j as K,a0 as M,ap as O,a as b,L as n,M as j,K as z,R as G,T as H}from"./@vue.76ce7aa3.js";import{c as L,d as S}from"./website.7b068910.js";import"./lodash-es.f52bd8b1.js";import"./async-validator.fb49d0f5.js";import"./@vueuse.9ffef7f8.js";import"./@element-plus.73235148.js";import"./dayjs.0112e2c7.js";import"./@babel.80d29b7b.js";import"./@ctrl.b082b0c1.js";import"./normalize-wheel-es.8aeb3683.js";import"./@popperjs.36402333.js";import"./index.8afed1db.js";import"./index.vue_vue_type_style_index_0_scoped_d380c88d_lang.cf0d972e.js";import"./index.38997ec5.js";import"./index.vue_vue_type_script_setup_true_lang.d6032bc4.js";import"./index.1767ceca.js";import"./usePaging.f8c888e4.js";import"./vuedraggable.1d6c5910.js";import"./vue.6c4d4a7c.js";import"./sortablejs.a0474a26.js";import"./lodash.41b9567d.js";import"./axios.b4cbdbc9.js";import"./jspdf.75308076.js";import"./fflate.0418c72f.js";import"./vue-router.10bd5b90.js";import"./pinia.f3529286.js";import"./css-color-function.f23177ae.js";import"./color.a6ad6672.js";import"./clone.954ba32c.js";import"./color-convert.755d189f.js";import"./color-name.e7a4e1d3.js";import"./color-string.e356f5de.js";import"./balanced-match.d2a36341.js";import"./ms.564e106c.js";import"./nprogress.b502f541.js";import"./vue-clipboard3.e775fc74.js";import"./clipboard.6417898a.js";import"./echarts.5016c48c.js";import"./zrender.58d022a1.js";import"./tslib.60310f1a.js";import"./highlight.js.31cd7941.js";import"./@highlightjs.8d65305c.js";const $=h({__name:"index",props:{modelValue:{default:""},mode:{default:"default"},height:{default:"100%"},width:{default:"auto"},toolbarConfig:{default:()=>({})}},emits:["update:modelValue"],setup(V,{emit:r}){const i=V,f=r,u=y(),e=y(),m=x("");let s;const p={MENU_CONF:{uploadImage:{customBrowseAndUpload(o){var t;m.value="image",(t=e.value)==null||t.showPopup(-1),s=o}},uploadVideo:{customBrowseAndUpload(o){var t;m.value="video",(t=e.value)==null||t.showPopup(-1),s=o}}}},c=C(()=>({height:w(i.height),width:w(i.width)})),d=C({get(){return i.modelValue},set(o){f("update:modelValue",o)}}),_=o=>{o.forEach(t=>{s(t)})};I(()=>{const o=u.value;o!=null&&o.destroy()});const v=o=>{u.value=o};return(o,t)=>(g(),E("div",{class:"border border-br flex flex-col",style:M(l(c))},[a(l(R),{class:"border-b border-br",editor:l(u),defaultConfig:o.toolbarConfig,mode:o.mode},null,8,["editor","defaultConfig","mode"]),a(l(N),{class:"overflow-y-auto flex-1",modelValue:l(d),"onUpdate:modelValue":t[0]||(t[0]=B=>K(d)?d.value=B:null),defaultConfig:p,mode:o.mode,onOnCreated:v},null,8,["modelValue","mode"]),a(T,{ref_key:"materialPickerRef",ref:e,type:l(m),limit:-1,"hidden-upload":"",onChange:_},null,8,["type"])],4))}});const q={class:"xl:flex"},ze=h({__name:"protocol",setup(V){const r=x({service_title:"",service_content:"",privacy_title:"",privacy_content:""}),i=async()=>{r.value=await L()},f=async()=>{await S({...r.value}),i()};return i(),(u,e)=>{const m=U,s=D,p=A,c=$,d=k,_=P,v=F,o=O("perms");return g(),E(H,null,[b("div",q,[a(d,{class:"!border-none flex-1 xl:mr-4 mb-4",shadow:"never"},{header:n(()=>e[4]||(e[4]=[b("span",{class:"font-medium"},"\u670D\u52A1\u534F\u8BAE",-1)])),default:n(()=>[a(p,{model:l(r),"label-width":"80px"},{default:n(()=>[a(s,{label:"\u534F\u8BAE\u540D\u79F0"},{default:n(()=>[a(m,{modelValue:l(r).service_title,"onUpdate:modelValue":e[0]||(e[0]=t=>l(r).service_title=t)},null,8,["modelValue"])]),_:1})]),_:1},8,["model"]),a(c,{class:"mb-10",modelValue:l(r).service_content,"onUpdate:modelValue":e[1]||(e[1]=t=>l(r).service_content=t),height:"500"},null,8,["modelValue"])]),_:1}),a(d,{class:"!border-none flex-1 mb-4",shadow:"never"},{header:n(()=>e[5]||(e[5]=[b("span",{class:"font-medium"},"\u9690\u79C1\u534F\u8BAE",-1)])),default:n(()=>[a(p,{model:l(r),"label-width":"80px"},{default:n(()=>[a(s,{label:"\u534F\u8BAE\u540D\u79F0"},{default:n(()=>[a(m,{modelValue:l(r).privacy_title,"onUpdate:modelValue":e[2]||(e[2]=t=>l(r).privacy_title=t)},null,8,["modelValue"])]),_:1})]),_:1},8,["model"]),a(c,{class:"mb-10",modelValue:l(r).privacy_content,"onUpdate:modelValue":e[3]||(e[3]=t=>l(r).privacy_content=t),height:"500"},null,8,["modelValue"])]),_:1})]),j((g(),z(v,null,{default:n(()=>[a(_,{type:"primary",onClick:f},{default:n(()=>e[6]||(e[6]=[G("\u4FDD\u5B58")])),_:1})]),_:1})),[[o,["setting.web.web_setting/setAgreement"]]])],64)}}});export{ze as default};
