import{_ as F}from"./index.c07b6f9e.js";import{C as U,D,F as A,M as k,w as P}from"./element-plus.7e54903f.js";import{T as R,E as N}from"./@wangeditor.2af95eac.js";import{_ as T}from"./picker.559eb78f.js";import{w}from"./index.aacc8c66.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 M,a0 as O,ap as j,a as b,L as n,M as z,K as G,R as H,T as K}from"./@vue.76ce7aa3.js";import{c as L,d as S}from"./website.42f7c218.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.bd8f165a.js";import"./index.vue_vue_type_style_index_0_scoped_d380c88d_lang.cf0d972e.js";import"./index.204f9361.js";import"./index.vue_vue_type_script_setup_true_lang.7f121250.js";import"./index.5eedca20.js";import"./usePaging.f8c888e4.js";import"./vuedraggable.9cbba807.js";import"./vue.1f30e2e1.js";import"./sortablejs.8430e608.js";import"./lodash.905d29aa.js";import"./axios.74873e41.js";import"./jspdf.9e946b0e.js";import"./fflate.0418c72f.js";import"./vue-router.10bd5b90.js";import"./pinia.f3529286.js";import"./css-color-function.5dec0992.js";import"./color.f3e3a53f.js";import"./clone.8eedf8fa.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:O(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=>M(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"},Ge=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=j("perms");return g(),E(K,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})]),z((g(),G(v,null,{default:n(()=>[a(_,{type:"primary",onClick:f},{default:n(()=>e[6]||(e[6]=[H("\u4FDD\u5B58")])),_:1})]),_:1})),[[o,["setting.web.web_setting/setAgreement"]]])],64)}}});export{Ge as default};