Generate CSS grid

grid_layout(..., display = c("grid", "inline-grid"), grid = NULL,
  template = NULL, rows = template_rows, template_rows = NULL,
  cols = template_columns, template_columns = NULL,
  areas = template_areas, template_areas = NULL, flow = c("", "row",
  "column", "dense", "row dense", "column dense"), auto_flow = c("",
  "row", "column", "dense", "row dense", "column dense"),
  auto_rows = NULL, auto_cols = auto_columns, auto_columns = NULL,
  row_gap = NULL, column_gap = NULL, gap = NULL,
  justify_content = NULL, align_content = NULL, justify_items = NULL,
  align_items = NULL, style = NULL)

Arguments

...

Items in the container

display

Specifies the CSS's display property by "display", "inline-display". Partial matching is used.

template, auto_flow, auto_rows, auto_columns, row_gap, column_gap, gap, grid

CSS properties of gird-*, whereas grid- is abbreviated, and hyphens are replaced by underscores. Specify string that muches the style of a certain CSS property. For example, the template_rows argument is equivalent to the CSS's grid-template-rows property. An exception is the grid argument which is equivalent to the CSS's grid property. The auto_flow argument can be specified by "", "row", "column" or "dense". Partial matching is used and "" skip specifying grid-flow. For details, see documents of CSS properties of CSS Grid Layout by Mozilla. Default values are NULL or "".

rows, cols, areas, flow, auto_cols

Aliases of template_rows, template_columns, and template_areas, auto_columns, respectively`

template_rows, template_columns

A character vector to specify size of each rows and columns in the grid such as "100px 1fr" or c("100px", "1fr"). Default is NULL.

template_areas

A vector, a matrix, or a data frame. If a vector, separate names of each areas in a row by space, and separate columns by elements such as c("a b", "c d"). If a matrix or a data frame, names and positions of each elements indicate the name of area and the position of area, respectively. Default is NULL.

justify_content, align_content, justify_items, align_items

Arguments equivalent to the CSS's justify-content, align-content, justify-items, align_items properties, respectively.`

style

Additional values of the style attribute such as color: red;.

Details

Default values of NULL or "" indicate the corresponding CSS properties are not specified.