GridAreaContext

@ExperimentalCoroutinesApi()
class GridAreaContext(styleParams: StyleParams, target: StringBuilder) : StyleParams

This context class is responsible for defining the grid area layout as comfortable and safe as possible.

It contains only one function: row. This function has the purpose to create exactly one row of the grid area. It takes an arbitrary amount of Property parameters, which represent one cell by its name.

One can pass in string literals directly of course, but for good reasons consider an approach, where you manage the string based cell names within a type of container like a Map, List or an `object`.

example call

areas { /* it == GridAreaContext.() */
row("HEADER", "HEADER", "HEADER")
row("MENU", "CONTENT", "CONTENT")
row("FOOTER", "FOOTER", "FOOTER")
}

See also

Constructors

GridAreaContext
Link copied to clipboard
fun GridAreaContext(styleParams: StyleParams, target: StringBuilder)

Functions

row
Link copied to clipboard
fun row(vararg values: AreaName): StringBuilder
This functions creates a single definitions of a row with named cells for the grid template area.

Properties

lgProperties
Link copied to clipboard
open override val lgProperties: StringBuilder
collects the properties for large screens
mdProperties
Link copied to clipboard
open override val mdProperties: StringBuilder
collects the properties for middle-sized screens
smProperties
Link copied to clipboard
open override val smProperties: StringBuilder
collects the properties for small screens
target
Link copied to clipboard
val target: StringBuilder
xlProperties
Link copied to clipboard
open override val xlProperties: StringBuilder
collects the properties for extra-large screens