Skip to content

Commit

Permalink
enhance: (Result) title and description support ReactNode
Browse files Browse the repository at this point in the history
  • Loading branch information
awmleer committed Mar 17, 2022
1 parent f597f33 commit 789d019
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions src/components/result/index.en.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,6 @@
| Name | Description | Type | Default |
| ----------- | ----------------- | ---------------------------------------------------------- | ------- |
| status | Status types | `'success' \| 'error' \| 'info' \| 'waiting' \| 'warning'` | - |
| title | Title | `string` | - |
| description | Description | `string` | '' |
| title | Title | `ReactNode` | - |
| description | Description | `ReactNode` | '' |
| icon | Customized `icon` | `ReactNode` | - |
4 changes: 2 additions & 2 deletions src/components/result/index.zh.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,6 @@
| 属性 | 说明 | 类型 | 默认值 |
| ----------- | ------------- | ---------------------------------------------------------- | ------ |
| status | 状态类型 | `'success' \| 'error' \| 'info' \| 'waiting' \| 'warning'` | - |
| title | 标题 | `string` | - |
| description | 描述 | `string` | '' |
| title | 标题 | `ReactNode` | - |
| description | 描述 | `ReactNode` | '' |
| icon | 自定义 `icon` | `ReactNode` | - |
4 changes: 2 additions & 2 deletions src/components/result/result.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ const iconRecord = {

export type ResultProps = {
status: 'success' | 'error' | 'info' | 'waiting' | 'warning'
title: string
description?: string
title: ReactNode
description?: ReactNode
icon?: ReactNode
} & NativeProps

Expand Down

0 comments on commit 789d019

Please sign in to comment.