System.register(["./index-legacy.DjPCm-Xr.js","./index-legacy.sLMPZLm9.js"],(function(e,t){"use strict";var a,n,o,r,c,l,d,i,u;return{setters:[e=>{a=e.i,n=e._,o=e.b,r=e.d,c=e.P},e=>{l=e.d,d=e.e,i=e.w,u=e.l}],execute:function(){var t=function(e,t){var a={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(a[n]=e[n]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(n=Object.getOwnPropertySymbols(e);o<n.length;o++)t.indexOf(n[o])<0&&Object.prototype.propertyIsEnumerable.call(e,n[o])&&(a[n[o]]=e[n[o]])}return a};const s={prefixCls:String,name:String,id:String,type:String,defaultChecked:{type:[Boolean,Number],default:void 0},checked:{type:[Boolean,Number],default:void 0},disabled:Boolean,tabindex:{type:[Number,String]},readonly:Boolean,autofocus:Boolean,value:c.any,required:Boolean};e("V",l({compatConfig:{MODE:3},name:"Checkbox",inheritAttrs:!1,props:a(s,{prefixCls:"rc-checkbox",type:"checkbox",defaultChecked:!1}),emits:["click","change"],setup(e,a){let{attrs:c,emit:l,expose:s}=a;const p=d(void 0===e.checked?e.defaultChecked:e.checked),y=d();i((()=>e.checked),(()=>{p.value=e.checked})),s({focus(){var e;null===(e=y.value)||void 0===e||e.focus()},blur(){var e;null===(e=y.value)||void 0===e||e.blur()}});const f=d(),v=t=>{if(e.disabled)return;void 0===e.checked&&(p.value=t.target.checked),t.shiftKey=f.value;const a={target:n(n({},e),{checked:t.target.checked}),stopPropagation(){t.stopPropagation()},preventDefault(){t.preventDefault()},nativeEvent:t};void 0!==e.checked&&(y.value.checked=!!e.checked),l("change",a),f.value=!1},h=e=>{l("click",e),f.value=e.shiftKey};return()=>{const{prefixCls:a,name:l,id:d,type:i,disabled:s,readonly:f,tabindex:b,autofocus:k,value:g,required:x}=e,m=t(e,["prefixCls","name","id","type","disabled","readonly","tabindex","autofocus","value","required"]),{class:C,onFocus:O,onBlur:S,onKeydown:B,onKeypress:K,onKeyup:j}=c,w=n(n({},m),c),P=Object.keys(w).reduce(((e,t)=>((t.startsWith("data-")||t.startsWith("aria-")||"role"===t)&&(e[t]=w[t]),e)),{}),q=o(a,C,{[`${a}-checked`]:p.value,[`${a}-disabled`]:s}),$=n(n({name:l,id:d,type:i,readonly:f,disabled:s,tabindex:b,class:`${a}-input`,checked:!!p.value,autofocus:k,value:g},P),{onChange:v,onClick:h,onFocus:O,onBlur:S,onKeydown:B,onKeypress:K,onKeyup:j,required:x});return u("span",{class:q},[u("input",r({ref:y},$),null),u("span",{class:`${a}-inner`},null)])}}}))}}}));
