瀏覽代碼

Switch: Label with el-switch repeating event(fix #14959) (#15178)

lisheng 6 年之前
父節點
當前提交
208a78786f
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      packages/switch/src/component.vue

+ 1 - 1
packages/switch/src/component.vue

@@ -5,7 +5,7 @@
     role="switch"
     :aria-checked="checked"
     :aria-disabled="switchDisabled"
-    @click="switchValue"
+    @click.prevent="switchValue"
   >
     <input
       class="el-switch__input"