getSectionClass()function
getSectionClass(variants: SectionProps): string
| Param | Type | |
|---|---|---|
variants | SectionProps | Colour, space, typography, and width variants. required |
.as | BlockElement | Element this <Section> renders as, e.g. "header" to output a "<header>" Defaults to "section" |
| Return | |
|---|---|
string | A space-separated className string combining the section class and resolved variant classes. |
Get the combined className string for a section from its styling variants.
Composes the base section class with the colour, space, typography, and width variant helpers, so anything that wants section-level styling can apply it.
Examples
getSectionClass({ space: "large" }) // "section …"