2019-02-19 11:42:05 +08:00
---
category: Components
type: General
title: Typography
cols: 1
---
2019-03-19 11:40:36 +08:00
Basic text writing, including headings, body text, lists, and more.
2019-02-19 11:42:05 +08:00
## When To Use
2019-10-25 09:56:30 +08:00
- When need to display a title or paragraph contents in Articles/Blogs/Notes.
2019-03-19 11:40:36 +08:00
- When you need copyable/editable/ellipsis texts.
2019-02-19 11:42:05 +08:00
## API
### Typography.Text
2019-07-11 14:14:33 +08:00
| Property | Description | Type | Default | Version |
| --- | --- | --- | --- | --- |
2019-11-22 10:33:34 +08:00
| code | Code style | boolean | false | |
| copyable | Config copy. Can set copy text and callback when is an object | boolean \| { text: string, onCopy: Function } | false | |
| delete | Deleted line style | boolean | false | |
| disabled | Disabled content | boolean | false | |
| editable | Editable. Can control edit state when is object | boolean \| { editing: boolean, onStart: Function, onChange: Function(string) } | false | |
| ellipsis | Display ellipsis when text overflows | boolean | false | |
| mark | Marked style | boolean | false | |
| underline | Underlined style | boolean | false | |
| onChange | Trigger when user edits the content | Function(string) | - | |
| strong | Bold style | boolean | false | |
| type | Content type | `secondary` , `warning` , `danger` | - | |
2019-02-19 11:42:05 +08:00
### Typography.Title
2019-07-11 14:14:33 +08:00
| Property | Description | Type | Default | Version |
| --- | --- | --- | --- | --- |
2019-11-22 10:33:34 +08:00
| code | Code style | boolean | false | |
| copyable | Config copy. Can set copy text and callback when is an object | boolean \| { text: string, onCopy: Function } | false | |
| delete | Deleted line style | boolean | false | |
| disabled | Disabled content | boolean | false | |
| editable | Editable. Can control edit state when is object | boolean \| { editing: boolean, onStart: Function, onChange: Function(string) } | false | |
| ellipsis | Display ellipsis when text overflows. Can configure rows and expandable by using object | boolean \| { rows: number, expandable: boolean, onExpand: Function } | false | |
| level | Set content importance. Match with `h1` , `h2` , `h3` , `h4` | number: `1` , `2` , `3` , `4` | 1 | |
| mark | Marked style | boolean | false | |
| underline | Underlined style | boolean | false | |
| onChange | Trigger when user edits the content | Function(string) | - | |
| type | Content type | `secondary` , `warning` , `danger` | - | |
2019-02-19 11:42:05 +08:00
### Typography.Paragraph
2019-07-11 14:14:33 +08:00
| Property | Description | Type | Default | Version |
| --- | --- | --- | --- | --- |
2019-11-22 10:33:34 +08:00
| code | Code style | boolean | false | |
| copyable | Config copy. Can set copy text and callback when is an object | boolean \| { text: string, onCopy: Function } | false | |
| delete | Deleted line style | boolean | false | |
| disabled | Disabled content | boolean | false | |
| editable | Editable. Can control edit state when is object | boolean \| { editing: boolean, onStart: Function, onChange: Function(string) } | false | |
2019-12-24 11:59:17 +08:00
| ellipsis | Display ellipsis when text overflows. Can configure rows expandable and suffix by using object | boolean \| { rows: number, expandable: boolean suffix: string, onExpand: Function } | false | |
2019-11-22 10:33:34 +08:00
| mark | Marked style | boolean | false | |
| underline | Underlined style | boolean | false | |
| onChange | Trigger when user edits the content | Function(string) | - | |
| strong | Bold style | boolean | false | |
| type | Content type | `secondary` , `warning` , `danger` | - | |