Architecting CSS by Martine Dowden & Michael Dowden

Architecting CSS by Martine Dowden & Michael Dowden

Author:Martine Dowden & Michael Dowden
Language: eng
Format: epub
ISBN: 9781484257500
Publisher: Apress


header, footer {

display: flex;

align-items: center;

justify-content: center;

}

header h2, footer h2 {

margin: 0;

}

Listing 4-27Grid CSS

Grid-row and grid-column can be defined using a single integer (grid-row: 1) or two integers separated by a / (grid-row: 1/3). When only one integer is used, the section will start that the line specified and span one column or row such as for the main element in the example earlier. When two integers separated by a / are used, the section will start at the line specified by the first integer and end at the line specified by the second, as seen on the footer’s grid-column value.

Similarly to flexbox or table, the placement of content within a section can be adjusted. The justify-items property can be used on the grid container to determine how content within sections or cells will align left to right. Its values are start, end, center, and stretch as illustrated in Figure 4-28. Stretch is the default value.

Figure 4-28Justify-Items Values



Download



Copyright Disclaimer:
This site does not store any files on its server. We only index and link to content provided by other sites. Please contact the content providers to delete copyright contents if any and email us, we'll remove relevant links or contents immediately.