30 lines
788 B
Markdown
30 lines
788 B
Markdown
---
|
|
title: Text Indent
|
|
---
|
|
## Text Indent
|
|
|
|
This CSS property creates an indentation of the first line in a text block.
|
|
|
|
### Values:
|
|
The `text-indent` property can be specified using `%`, `px`, `em` or measurement units such as `cm` and `in`.
|
|
|
|
For example:
|
|
- `text-indent: 20%;`
|
|
- `text-indent: 15px;`
|
|
- `text-indent: 5em;`
|
|
- `text-indent: 2in;`
|
|
- 'text-indent: 35cm;'
|
|
|
|
The `text-indent` property can also inherit from its parent element using `inherit` value.
|
|
|
|
For example:
|
|
- `text-indent: inherit;`
|
|
|
|
The 'text-indent' property can be reset to its initial CSS property default value.
|
|
|
|
For example:
|
|
- 'text-indent: initial;'
|
|
|
|
#### More Information:
|
|
- <a href='https://developer.mozilla.org/en-US/docs/Web/CSS/text-indent' target='_blank' rel='nofollow'>MDN Web Docs - CSS text-indent</a>
|