You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

2 lines
1.1 KiB
JavaScript

import{p as c,l as d,_ as l}from"./entry/index-C2Ijy48E-1723706691540.js";import{b as m}from"./index-DF_o0PAQ.js";import{d as p,c as u,_ as h,$ as f,a0 as C,a1 as g,k as b,ad as k,u as t,a2 as _}from"./vue-aEZWZQSa.js";import{a0 as y}from"./antd-BY-1PcYE.js";import"./createAsyncComponent-CCw68KNm.js";import"./index-BCWxk4Sz.js";import"./useContentViewHeight-BBd42TOY.js";import"./useWindowSizeFn-CjdUjzGl.js";import"./useSortable-Bra4jKJL.js";import"./index-C8bZxGin.js";const v=p({name:"SwitchItem",__name:"SwitchItem",props:{event:{type:Number},disabled:{type:Boolean},title:{type:String},def:{type:Boolean}},setup(a){const e=a,{prefixCls:o}=c("setting-switch-item"),{t:n}=d(),i=u(()=>e.def?{checked:e.def}:{}),r=s=>{e.event&&m(e.event,s)};return(s,B)=>(h(),f("div",{class:_(t(o))},[C("span",null,g(a.title),1),b(t(y),k(i.value,{onChange:r,disabled:a.disabled,checkedChildren:t(n)("layout.setting.on"),unCheckedChildren:t(n)("layout.setting.off")}),null,16,["disabled","checkedChildren","unCheckedChildren"])],2))}}),P=l(v,[["__scopeId","data-v-b47b0939"]]);export{P as default};