🥑 Developer Advocate 🥑
designed for laying out documents
designed for laying out text
designed for laying out 2D data in a tabular format
designed for very explicit positioning without much regard for other elements in the document
describes a CSS box model optimised for user interface design and designed for laying out more complex applications and webpages
Defines a two-dimensional grid-based layout system,
optimised for user interface design.
Grid works from the container in,
other layout methods start with the item
Rachel Andrew
inline-block
Item A
Item B
Item C
Item D
Item E
Item F
float
Item A
Item B
Item C
Item D
Item E
Item F
flex
Item A
Item B
Item C
Item D
Item E
Item F
Grid is the only layout technique that establishes a relationship between rows and columns of grid items.
to create a snapshot of the specification's current state and to solicit input from the W3C and the public
to announce that the specification will move toward Candidate Recommendation unless significant issues are brought up
to express that all known issues have been resolved, and is a call for implementations
needs a comprehensive test suite and implementation reports proving that every feature is interoperably implemented in at least two shipping implementations
finally, a standard
…it shouldn’t come as a shock that grid-based layouts have been a goal of CSS since the beginning.
The Story of CSS Grid, from Its Creators by Aaron Gustafson
gap
to solve the gutter problemDefine your grid.
Place items in the grid.
Same properties, more values
grid-template-columns: subgrid <line-name-list>?
grid-template-rows: subgrid <line-name-list>?
The subgrid
keyword indicates to the browser the nested grid will use the same sizing as its parent along the relevant axis.
.subgrid-container {
grid-columns: 2 / 5; /* placement for the subgrid container itself */
display: grid; /* you must still apply a display: grid to the subgrid */
grid-template-columns: subgrid;
grid-template-rows: subgrid;
}
Font is Red Hat Display by Jeremy Mickel.