lcny-vue3-antd-admin/dist/assets/SwitchItem.b36bd82e.js

2 lines
1.5 KiB
JavaScript

import{J as s,a as p,b as d,c as m,f as l,aA as c,o as h,h as u,i as f,t as C,p as g,aB as _,n as v}from"./index.f8d077cb.js";import{S as y}from"./index.922a529f.js";import{b as S}from"./index.d65854c2.js";import"./index.e08cc923.js";import"./index.3b7f38d8.js";import"./ArrowLeftOutlined.19640b35.js";import"./index.b1599d71.js";import"./index.61a59a2b.js";import"./FullscreenOutlined.746f36db.js";import"./index.472a7f77.js";import"./useWindowSizeFn.fb758d0f.js";import"./useContentViewHeight.4905a33a.js";import"./uniqBy.b3344806.js";import"./_baseIteratee.e97204d9.js";import"./get.9967fe8a.js";import"./index.81bdb07c.js";import"./useRefs.5238691e.js";import"./PlusOutlined.ec1fd146.js";import"./RedoOutlined.401eb4e2.js";import"./index.78b74adc.js";import"./lock.7e7e08cd.js";const b=p({name:"SwitchItem",components:{Switch:y},props:{event:{type:Number},disabled:{type:Boolean},title:{type:String},def:{type:Boolean}},setup(e){const{prefixCls:t}=d("setting-switch-item"),{t:n}=m(),o=l(()=>e.def?{checked:e.def}:{});function i(a){e.event&&S(e.event,a)}return{prefixCls:t,t:n,handleChange:i,getBindValue:o}}});function B(e,t,n,o,i,a){const r=c("Switch");return h(),u("div",{class:v(e.prefixCls)},[f("span",null,C(e.title),1),g(r,_(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 Q=s(b,[["render",B],["__scopeId","data-v-fd7354e2"]]);export{Q as default};