SwitchItem.17bd20bb.js 1.5 KB

1
  1. import{av as s,a as p,b as m,c as d,f as l,a_ as c,o as h,h as u,m as f,t as C,n as _,b0 as g,q as v}from"./index.3f97cc33.js";import{S as b}from"./index.ade181eb.js";import{b as y}from"./index.432261d4.js";import"./index.57748f4c.js";import"./index.fb0ad110.js";import"./ArrowLeftOutlined.5c21fff9.js";import"./index.222f0459.js";import"./index.3e181a91.js";import"./FullscreenOutlined.79df86c0.js";import"./index.8e28a80a.js";import"./useWindowSizeFn.63c1b6a0.js";import"./useContentViewHeight.1983ed20.js";import"./uniqBy.66af1ece.js";import"./_baseIteratee.74621dd5.js";import"./get.7e5a4802.js";import"./index.8c14bde9.js";import"./useRefs.428779fe.js";import"./PlusOutlined.f1f3bd13.js";import"./RedoOutlined.fe1eaec0.js";import"./index.f74085c4.js";import"./TabPane.2340d2dc.js";import"./lock.b909ef7b.js";const S=p({name:"SwitchItem",components:{Switch:b},props:{event:{type:Number},disabled:{type:Boolean},title:{type:String},def:{type:Boolean}},setup(e){const{prefixCls:t}=m("setting-switch-item"),{t:o}=d(),n=l(()=>e.def?{checked:e.def}:{});function i(a){e.event&&y(e.event,a)}return{prefixCls:t,t:o,handleChange:i,getBindValue:n}}});function k(e,t,o,n,i,a){const r=c("Switch");return h(),u("div",{class:v(e.prefixCls)},[f("span",null,C(e.title),1),_(r,g(e.getBindValue,{onChange:e.handleChange,disabled:e.disabled,checkedChildren:e.t("layout.setting.on"),unCheckedChildren:e.t("layout.setting.off")}),null,16,["onChange","disabled","checkedChildren","unCheckedChildren"])],2)}var R=s(S,[["render",k],["__scopeId","data-v-fd7354e2"]]);export{R as default};