mirror of
https://github.com/antd-tiny-vue/antd-tiny-vue.git
synced 2025-07-03 10:33:11 +08:00
feat: add space
This commit is contained in:
@ -53,9 +53,13 @@ const Button = defineComponent({
|
||||
direction
|
||||
)
|
||||
const sizeCls = computed(() => {
|
||||
const sizeClassNameMap = { large: 'lg', small: 'sm', middle: undefined }
|
||||
const sizeClassNameMap: Record<string, any> = {
|
||||
large: 'lg',
|
||||
small: 'sm',
|
||||
middle: undefined
|
||||
}
|
||||
const sizeFullname = compactSize?.value || size.value
|
||||
return sizeClassNameMap[sizeFullname!]
|
||||
return sizeClassNameMap[sizeFullname]
|
||||
})
|
||||
const disabled = useDisabled(props)
|
||||
const buttonRef = shallowRef<HTMLButtonElement | null>(null)
|
||||
|
@ -14,12 +14,12 @@ title: Type
|
||||
There are `primary` button, `default` button, `dashed` button, `text` button and `link` button in antd.
|
||||
</docs>
|
||||
|
||||
<script setup lang="ts"></script>
|
||||
|
||||
<template>
|
||||
<a-button type="primary">Primary Button</a-button>
|
||||
<a-button>Default Button</a-button>
|
||||
<a-button type="dashed">Dashed Button</a-button>
|
||||
<a-button type="text">Text Button</a-button>
|
||||
<a-button type="link">Link Button</a-button>
|
||||
<a-space wrap>
|
||||
<a-button type="primary">Primary Button</a-button>
|
||||
<a-button>Default Button</a-button>
|
||||
<a-button type="dashed">Dashed Button</a-button>
|
||||
<a-button type="text">Text Button</a-button>
|
||||
<a-button type="link">Link Button</a-button>
|
||||
</a-space>
|
||||
</template>
|
||||
|
@ -49,7 +49,6 @@ It accepts all props which native buttons support.
|
||||
|
||||
## Design Token
|
||||
|
||||
<ComponentTokenTable component="Button"></ComponentTokenTable>
|
||||
|
||||
## FAQ
|
||||
|
||||
|
@ -54,7 +54,6 @@
|
||||
|
||||
## Design Token
|
||||
|
||||
<ComponentTokenTable component="Button"></ComponentTokenTable>
|
||||
|
||||
## FAQ
|
||||
|
||||
|
Reference in New Issue
Block a user