import{i as O,c as w}from"./app-DckefXYL.js";import{_ as L}from"./app-DgsA44Do.js";import{_ as N}from"./app-MnSDCF4P.js";import{_ as S}from"./app-COct4tsy.js";import{r as C,o as c,g as f,a as s,u as e,b as l,w as n,c as m,h as b,d as _,e as v,f as u,F as I,D as $,t as d}from"./app-DnroACXc.js";import{_ as P,a as h}from"./app-DntYVxd7.js";import{_ as k}from"./app-DK4Xe9me.js";import{_ as B}from"./app-QoKhxVfv.js";import{_ as g}from"./app-BbRQPmFH.js";import{C as y}from"./app-Do8DhyKT.js";import{D}from"./app-Cx7ENVlu.js";import"./app-B2-Q9WJQ.js";import"./app-DAKlLAys.js";import"./app-xECxwo4T.js";import"./app-BBDtZW3a.js";import"./app-Co2SIBzr.js";import"./app-B0NrURRk.js";import"./app-LqsmzyUT.js";import"./app-BJhJ7lM8.js";import"./app-Dd07dUxy.js";import"./app-CYYQ_Zep.js";import"./app-Dpl5YSiv.js";import"./app-CF8nmC-F.js";import"./app-NVAx7Sc3.js";import"./app-CF0qXH5Q.js";import"./app-B4bUdtyo.js";import"./app-B8VsrFxM.js";import"./app-B09rlSqG.js";function G(){O(this),this.success=this.$NotifyReloadSuccess("保存成功")}const T=["value"],F=s("td",{class:"title"},"启用字符编码",-1),A=s("td",{class:"title"},"选择字符编码",-1),J=s("optgroup",{label:"常用字符编码"},null,-1),R=s("optgroup",{label:"全部字符编码"},null,-1),x=s("td",null,"强制替换",-1),E=s("p",{class:"comment"},"选中后，表示强制覆盖已经设置的字符集；不选中，表示如果源站已经设置了字符集，则保留不修改。",-1),H=s("td",null,"字符编码大写",-1),j={class:"comment"},q={__name:"HTTPCharsetsBox",props:["v-usual-charsets","v-all-charsets","v-charset-config","v-is-location","v-is-group"],setup(V){const r=V,{charsetConfig:t,advancedVisible:p}=function(){let o=r.vCharsetConfig;return o==null&&(o={isPrior:!1,isOn:!1,charset:"",isUpper:!1,force:!1}),{charsetConfig:C(o),advancedVisible:C(!1)}}(),U=function(o){p.value=o};return(o,i)=>(c(),f("div",null,[s("input",{type:"hidden",name:"charsetJSON",value:JSON.stringify(e(t))},null,8,T),l(D,null,{default:n(()=>[o.vIsLocation||o.vIsGroup?(c(),m(B,{key:0,"v-config":e(t)},null,8,["v-config"])):b("",!0),_(s("tbody",null,[s("tr",null,[F,s("td",null,[l(g,{modelValue:e(t).isOn,"onUpdate:modelValue":i[0]||(i[0]=a=>e(t).isOn=a)},null,8,["modelValue"])])])],512),[[v,!o.vIsLocation&&!o.vIsGroup||e(t).isPrior]]),_(s("tbody",null,[s("tr",null,[A,s("td",null,[l(P,{name:"charset",modelValue:e(t).charset,"onUpdate:modelValue":i[1]||(i[1]=a=>e(t).charset=a),filter:""},{default:n(()=>[l(h,{value:""},{default:n(()=>[u("[未选择]")]),_:1}),J,(c(!0),f(I,null,$(o.vUsualCharsets,a=>(c(),m(h,{value:a.charset},{default:n(()=>[u(d(a.charset)+"（"+d(a.name)+"）",1)]),_:2},1032,["value"]))),256)),R,(c(!0),f(I,null,$(o.vAllCharsets,a=>(c(),m(h,{value:a.charset},{default:n(()=>[u(d(a.charset)+"（"+d(a.name)+"）",1)]),_:2},1032,["value"]))),256))]),_:1},8,["modelValue"])])])],512),[[v,(!o.vIsLocation&&!o.vIsGroup||e(t).isPrior)&&e(t).isOn]]),(!o.vIsLocation&&!o.vIsGroup||e(t).isPrior)&&e(t).isOn?(c(),m(k,{key:1,onChange:U})):b("",!0),_(s("tbody",null,[s("tr",null,[x,s("td",null,[l(g,{modelValue:e(t).force,"onUpdate:modelValue":i[2]||(i[2]=a=>e(t).force=a)},null,8,["modelValue"]),E])]),s("tr",null,[H,s("td",null,[l(g,{modelValue:e(t).isUpper,"onUpdate:modelValue":i[3]||(i[3]=a=>e(t).isUpper=a)},null,8,["modelValue"]),s("p",j,[u("选中后将指定的字符编码转换为大写，比如默认为 "),l(y,null,{default:n(()=>[u("utf-8")]),_:1}),u(" ，选中后将改为 "),l(y,null,{default:n(()=>[u("UTF-8")]),_:1}),u(" 。 ")])])])],512),[[v,(!o.vIsLocation&&!o.vIsGroup||e(t).isPrior)&&e(t).isOn&&e(p)]])]),_:1})]))}},z=["value"],be={__name:"index",setup(V){const r=w(new G);return(t,p)=>(c(),m(L,{ctx:e(r)},{default:n(()=>[l(N,{action:"$",onSuccess:e(r).success},{default:n(()=>[s("input",{type:"hidden",name:"webId",value:e(r).webId},null,8,z),l(q,{"v-usual-charsets":e(r).usualCharsets,"v-all-charsets":e(r).allCharsets,"v-charset-config":e(r).charsetConfig},null,8,["v-usual-charsets","v-all-charsets","v-charset-config"]),l(S,{class:"mt-4"})]),_:1},8,["onSuccess"])]),_:1},8,["ctx"]))}};export{be as default};
