ant-design-vue/components/radio/demo/size.vue

61 lines
1.6 KiB
Vue
Raw Blame History

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

<docs>
---
order: 8
title:
zh-CN: 大小
en-US: Size
---
## zh-CN
大中小三种组合可以和表单输入框进行对应配合
## en-US
There are three sizes available: large, medium, and small. It can coordinate with input box.
</docs>
<template>
<div>
<div>
<a-radio-group v-model:value="value1" size="large">
<a-radio-button value="a">Hangzhou</a-radio-button>
<a-radio-button value="b">Shanghai</a-radio-button>
<a-radio-button value="c">Beijing</a-radio-button>
<a-radio-button value="d">Chengdu</a-radio-button>
</a-radio-group>
</div>
<div :style="{ marginTop: '16px' }">
<a-radio-group v-model:value="value2">
<a-radio-button value="a">Hangzhou</a-radio-button>
<a-radio-button value="b">Shanghai</a-radio-button>
<a-radio-button value="c">Beijing</a-radio-button>
<a-radio-button value="d">Chengdu</a-radio-button>
</a-radio-group>
</div>
<div :style="{ marginTop: '16px' }">
<a-radio-group v-model:value="value3" size="small">
<a-radio-button value="a">Hangzhou</a-radio-button>
<a-radio-button value="b">Shanghai</a-radio-button>
<a-radio-button value="c">Beijing</a-radio-button>
<a-radio-button value="d">Chengdu</a-radio-button>
</a-radio-group>
</div>
</div>
</template>
<script lang="ts">
import { defineComponent, ref } from 'vue';
export default defineComponent({
setup() {
const value1 = ref<string>('a');
const value2 = ref<string>('a');
const value3 = ref<string>('a');
return {
value1,
value2,
value3,
};
},
});
</script>