mirror of
https://gitee.com/element-plus/element-plus.git
synced 2024-12-04 20:27:44 +08:00
fix(link): change default value of type to 'default' instead of ''
This commit is contained in:
parent
21382d2ee0
commit
2dbc7a4307
@ -10,7 +10,7 @@ export const BasicLinks = () => `
|
|||||||
<el-link ${commonProps} type="success">success link</el-link>
|
<el-link ${commonProps} type="success">success link</el-link>
|
||||||
<el-link ${commonProps} type="info">info link</el-link>
|
<el-link ${commonProps} type="info">info link</el-link>
|
||||||
<el-link ${commonProps} type="warning">warning link</el-link>
|
<el-link ${commonProps} type="warning">warning link</el-link>
|
||||||
<el-link ${commonProps} type="error">error link</el-link>
|
<el-link ${commonProps} type="danger">error link</el-link>
|
||||||
`
|
`
|
||||||
|
|
||||||
export const DisabledLinks = () => `
|
export const DisabledLinks = () => `
|
||||||
|
@ -22,16 +22,16 @@
|
|||||||
<script lang='ts'>
|
<script lang='ts'>
|
||||||
import { defineComponent, PropType } from 'vue'
|
import { defineComponent, PropType } from 'vue'
|
||||||
|
|
||||||
type ILinkType = PropType<'primary' | 'success' | 'warning' | 'info' | 'danger' | ''>
|
type ILinkType = PropType<'primary' | 'success' | 'warning' | 'info' | 'danger' | 'default'>
|
||||||
|
|
||||||
export default defineComponent({
|
export default defineComponent({
|
||||||
name: 'ElLink',
|
name: 'ElLink',
|
||||||
props: {
|
props: {
|
||||||
type: {
|
type: {
|
||||||
type: String as ILinkType,
|
type: String as ILinkType,
|
||||||
default: '',
|
default: 'default',
|
||||||
validator: (val: string) => {
|
validator: (val: string) => {
|
||||||
return ['', 'primary', 'success', 'warning', 'info', 'danger'].includes(val)
|
return ['default', 'primary', 'success', 'warning', 'info', 'danger'].includes(val)
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
underline: {
|
underline: {
|
||||||
|
Loading…
Reference in New Issue
Block a user