"use strict";(self["webpackChunkmi_wifi_agent"]=self["webpackChunkmi_wifi_agent"]||[]).push([[4948],{7788:function(e,l,t){t.r(l),t.d(l,{default:function(){return u}});var r=t(641),i=t(2644);function o(e,l,t,o,s,n){const a=(0,r.g2)("el-alert"),d=(0,r.g2)("sc-icon-select"),u=(0,r.g2)("el-form-item"),c=(0,r.g2)("el-button"),m=(0,r.g2)("el-form"),f=(0,r.g2)("el-card"),b=(0,r.g2)("el-main");return(0,r.uX)(),(0,r.Wv)(b,null,{default:(0,r.k6)((()=>[(0,r.bF)(a,{title:"支持扩展的图标选择器,除了默认的图标组还可以在 @/config/iconSelect 中定义更多的图标组",type:"success",style:{"margin-bottom":"20px"}}),(0,r.bF)(f,{shadow:"never"},{default:(0,r.k6)((()=>[(0,r.bF)(m,{ref:"ruleForm",model:s.form,rules:s.rules,"label-width":"100px"},{default:(0,r.k6)((()=>[(0,r.bF)(u,{label:"图标",prop:"icon"},{default:(0,r.k6)((()=>[(0,r.bF)(d,{modelValue:s.form.icon,"onUpdate:modelValue":l[0]||(l[0]=e=>s.form.icon=e),disabled:s.disabled},null,8,["modelValue","disabled"])])),_:1}),(0,r.bF)(u,null,{default:(0,r.k6)((()=>[(0,r.bF)(c,{type:"primary",onClick:n.submitForm},{default:(0,r.k6)((()=>[(0,r.eW)("保存")])),_:1},8,["onClick"]),(0,r.bF)(c,{onClick:n.resetForm},{default:(0,r.k6)((()=>[(0,r.eW)("重置")])),_:1},8,["onClick"]),(0,r.bF)(c,{onClick:n.setdisabled},{default:(0,r.k6)((()=>[(0,r.eW)((0,i.v_)(s.disabled?"移除禁用":"设为禁用"),1)])),_:1},8,["onClick"])])),_:1})])),_:1},8,["model","rules"])])),_:1})])),_:1})}var s=t(7978),n={name:"iconSelect",components:{scIconSelect:s.A},data(){return{form:{icon:"el-icon-apple"},rules:{icon:[{required:!0,message:"请选择图标",trigger:"change"}]},disabled:!1}},methods:{submitForm(){this.$refs.ruleForm.validate((e=>{if(!e)return!1;alert("请看控制台输出"),console.log(this.form)}))},resetForm(){this.$refs.ruleForm.resetFields()},setdisabled(){this.disabled=!this.disabled}}},a=t(6262);const d=(0,a.A)(n,[["render",o]]);var u=d}}]);