Senin, 16 Maret 2020

CSS: Margin

Remember ALPI: Auto, L

Yes, you can build or make a tag or an element lies in the middle horizontally of the parent tag, a.k.a a banner box using auto value.

Top first and clockwise.


What is the relation between margin and border?
Margin is space outside the border, while padding is space inside the border.

You can set margin with :
1. Specific property style or
2. Non-specific property style.

Remember that CSS is consist of property and values. So types of  properties of margin are:
1. Specific property: There are properties for each of side of element (top, right, bottom and left).
2. Non-specific property.

1. Specific property.
Specific propery:
margin-top
margin-right
margin-bottom
margin-left

2. Non-specific property
margin: 20px 20px 20px 20px

Where all the values

Tidak ada komentar:

Posting Komentar