Commit 5bb01822dfe6b7b3434188a0334cdd75ddcccf0d

Authored by 梁灏
1 parent e7fa2799

Switch prevent space to scroll

examples/routers/form.vue
... ... @@ -479,6 +479,7 @@
479 479 <Button type="primary">Submit</Button>
480 480 <Button type="ghost" style="margin-left: 8px">Cancel</Button>
481 481 </FormItem>
  482 + <br><br><br><br><br><br><br><br><br><br><br><br><br><br>
482 483 </Form>
483 484 </template>
484 485 <script>
... ...
src/components/switch/switch.vue
... ... @@ -68,7 +68,8 @@
68 68 }
69 69 },
70 70 methods: {
71   - toggle () {
  71 + toggle (event) {
  72 + event.preventDefault();
72 73 if (this.disabled) {
73 74 return false;
74 75 }
... ...