Skip to content

Latest commit

 

History

History
22 lines (17 loc) · 563 Bytes

margin.md

File metadata and controls

22 lines (17 loc) · 563 Bytes

margin

The margin CSS shorthand property sets the margin area on all four sides of an element.

Values

<length>
The size of the margin as a fixed value.
<percentage>
The size of the margin as a percentage, relative to the width of the containing block.
auto
The browser selects a suitable margin to use. For example, in certain cases this value can be used to center an element.

Examples

margin="3rem 0 0 -3rem"
margin="auto"
margin="20px 0px"