fix(components): fix more size prop checks (#4975)

This commit is contained in:
Herrington Darkholme 2021-12-26 02:45:58 -05:00 committed by GitHub
parent 343b7e333f
commit 0057fbfadc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 4 additions and 4 deletions

View File

@ -187,7 +187,7 @@ const useSelect = (props: ExtractPropTypes<typeof SelectProps>, emit) => {
const selectSize = useSize()
const collapseTagSize = computed(() =>
'small' === selectSize.value ? 'small' : ''
'small' === selectSize.value ? 'small' : 'default'
)
const tagMaxWidth = computed(() => {

View File

@ -148,7 +148,7 @@ export const useSelect = (props, states: States, ctx) => {
const selectSize = useSize()
const collapseTagSize = computed(() =>
['small'].indexOf(selectSize.value) > -1 ? 'small' : ''
['small'].indexOf(selectSize.value) > -1 ? 'small' : 'default'
)
const dropMenuVisible = computed(

View File

@ -109,9 +109,9 @@ export default defineComponent({
},
size: {
type: String as PropType<ComponentSize>,
default: '',
default: 'default',
validator: (value: string) =>
!value || ['large', 'small'].indexOf(value) !== -1,
!value || ['large', 'default', 'small'].indexOf(value) !== -1,
},
placeholder: {
type: String,