[CSS] Day 7: Grid: parent and child
How to use the grid now?
First, I want to use selector a, h1, and ol's margin and paddings
then, use<div></div> for two groups to put in columns: title and the content
first group is under content <div></div> --> child
second group is ol and first <div> --> Parent
and then I will give id to parent <div id="grid">
and then in #grid{}, I will give condition: column size
The nice thing about this is you can always modify border, padding, and margin size by right click --> inspect (Don't be afraid to try!)
* What I learn from this so far
- giving id="" is important when it comes to inspect
- it gives freedom to add/substrate
- i.e. parent <div></div> give <div id="grid"></div> and under #gird, display:gird; give columns and padding
- id="" comes with #NAME {}
Now, I'm going to give id under child to id = "article"
Also, the important part is to understand parent and child, it is necessary to group the child together under the same parent.
** Child ol and #article is under parent #grid **
The result