update Switch style

This commit is contained in:
梁灏 2018-06-21 19:51:38 +08:00
parent 3f611f57ed
commit ac2f8493b1
2 changed files with 49 additions and 25 deletions

View file

@ -6,13 +6,39 @@
</i-switch>
{{ m1 }}
<div @click="m1 = 'no'">toggle</div>
<br><br>
<i-switch size="large"></i-switch>
<i-switch></i-switch>
<i-switch size="small"></i-switch>
<br><br>
<i-switch>
<span slot="open"></span>
<span slot="close"></span>
</i-switch>
<i-switch>
<Icon type="android-done" slot="open"></Icon>
<Icon type="android-close" slot="close"></Icon>
</i-switch>
<br><br>
<i-switch size="large">
<span slot="open">开启</span>
<span slot="close">关闭</span>
</i-switch>
<i-switch size="large">
<span slot="open">ON</span>
<span slot="close">OFF</span>
</i-switch>
<br><br>
<i-switch :disabled="disabled"></i-switch>
<Button type="primary" @click="disabled = !disabled">Toggle Disabled</Button>
</div>
</template>
<script>
export default {
data () {
return {
m1: 'yes'
m1: 'yes',
disabled: true
}
},
methods: {