aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authortaehoon <th.dev91@gmail.com>2019-04-06 13:24:28 -0400
committertaehoon <th.dev91@gmail.com>2019-04-17 11:32:49 -0400
commit988849116d75ab02ae6da5998c751133ea13f531 (patch)
treee03849a5ca0fd5e797e7ad17856986b558909a87 /src
parent8088043a0c811a2e215e12715029ca8563ac2304 (diff)
update model and props properties
Diffstat (limited to 'src')
-rw-r--r--src/components/checkbox/checkbox.vue8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/components/checkbox/checkbox.vue b/src/components/checkbox/checkbox.vue
index b821a4f6..84bea53e 100644
--- a/src/components/checkbox/checkbox.vue
+++ b/src/components/checkbox/checkbox.vue
@@ -1,6 +1,6 @@
<template>
<label class="checkbox">
- <input type="checkbox" :checked="value" @change="$emit('input', $event.target.checked)">
+ <input type="checkbox" :checked="checked" @change="$emit('change', $event.target.checked)">
<i class="checkbox-indicator" />
<span><slot></slot></span>
</label>
@@ -8,7 +8,11 @@
<script>
export default {
- props: ['value']
+ model: {
+ prop: 'checked',
+ event: 'change'
+ },
+ props: ['checked']
}
</script>