SubGrid
The SubGrid component (ion-subgrid) creates a nested row inside a parent Grid section, allowing further column subdivision without introducing a new full-width section. It wraps its children in a <div class="row ..."> inside a column-width <div class="col-...">, enabling complex multi-column layouts within a single section.
SubGrid inherits the full set of Row, Column, and Section rendering parameters—including Row Columns (Small/Medium/Large), Gutter control, Vertical Alignment, Background Image/Video, and a Title with configurable Heading Size. Its inner bs-section placeholder accepts any child renderings (Rich Text, Cards, Images, etc.), which are laid out as columns within the SubGrid’s row.
Use SubGrid when you need an additional level of column structure inside an existing section rather than creating a separate top-level section.
Examples
Live Example
Below is a liveion-subgrid rendering placed inside the Examples section. The SubGrid is configured as a 2-column row at medium breakpoint, containing two Rich Text paragraphs that occupy equal columns. This demonstrates how a SubGrid creates an additional level of column structure nested within the parent section’s row.
Column A
Left Column
This Rich Text paragraph sits in the first column of the SubGrid. The SubGrid’s RowColumnsMedium is set to 2, so this content occupies 50% width at the medium breakpoint and above.
Column B
Right Column
This Rich Text paragraph sits in the second column of the SubGrid. Both columns stack vertically on smaller viewports because no Small column class is specified—only RowColumnsMedium=2 applies.
Usage Notes
Usage Notes
- SubGrid must be placed inside a parent Grid section’s placeholder. It cannot function as a top-level section.
- The SubGrid wraps its children in a
<div class="col-..."><div class="row ...">structure, so its Column parameters control how wide the SubGrid itself is within the parent row, and its Row parameters control how children are arranged inside. - Set
RowColumnsMediumto define how many equal-width columns child renderings occupy at the medium breakpoint. Leave it blank for default Bootstrap auto-layout. - Use
GridGutterXandGridGutterYto control horizontal and vertical spacing between child columns within the SubGrid. - The optional
Titleparameter renders a heading above the SubGrid’s children. UseHeadingSizeto control its visual size andLowerHeadingImportanceto push the heading level down in the document outline. BackgroundImageandBackgroundVideoLinkallow decorative backgrounds on the SubGrid wrapper. The image usesbackground-size: coverand respects theImagePositionparameter for alignment.- SubGrid supports all standard column parameters (
Small,Medium,Large,OffsetSmall, etc.) for controlling its own width within the parent row. - Any rendering can be placed inside the SubGrid’s
bs-sectionplaceholder: Rich Text, Cards, Images, or even another SubGrid for deeper nesting.
Control Properties
Control Properties
Standard Values / Defaults
The SubGrid rendering parameters template inherits from three base templates (Row, Column, and Section). The __Standard Values item explicitly sets the following defaults:
| Property | Default Value | Notes |
|---|---|---|
| GridPaddingTop | (empty) | No top padding by default. |
| GridPaddingBottom | (empty) | No bottom padding by default. |
| BorderBottom | (empty) | No bottom border by default. |
| ImagePosition | center-center | Code-level fallback when no dictionary phrase is set. |
| All other parameters | (empty / not set) | Inherited blank from base templates. No row-columns, gutters, margins, colors, or overlays are applied unless explicitly configured. |
Column Parameters (SubGrid’s own width)
| Property | Type | Description |
|---|---|---|
| Small | Column Width | Bootstrap column class at the small breakpoint for the SubGrid wrapper. |
| Medium | Column Width | Bootstrap column class at the medium breakpoint for the SubGrid wrapper. |
| Large | Column Width | Bootstrap column class at the large breakpoint for the SubGrid wrapper. |
| OffsetSmall / OffsetMedium / OffsetLarge | Column Offset | Column offset at each breakpoint. |
| VerticalAlignment | Dictionary Phrase | Vertical alignment of the SubGrid column itself within the parent row (e.g. align-self-center). |
| TextAlignment | Dictionary Phrase | Text alignment within the SubGrid column. |
| PaddingTop / PaddingBottom / PaddingStart / PaddingEnd | Dictionary Phrase | Padding on the SubGrid column wrapper. |
Row Parameters (child layout inside SubGrid)
| Property | Type | Description |
|---|---|---|
| RowColumnsSmall | Dictionary Phrase | Number of equal-width columns for children at the small breakpoint (e.g. row-cols-1). Also adds row-cols-1 as a base class when set. |
| RowColumnsMedium | Dictionary Phrase | Number of equal-width columns for children at the medium breakpoint (e.g. row-cols-md-2). |
| RowColumnsLarge | Dictionary Phrase | Number of equal-width columns for children at the large breakpoint (e.g. row-cols-lg-3). |
| GridGutterX | Dictionary Phrase | Horizontal gutter between child columns (e.g. gx-3). |
| GridGutterY | Dictionary Phrase | Vertical gutter between child rows (e.g. gy-3). |
| GridVerticalAlignment | Dictionary Phrase | Vertical alignment of children within the row (e.g. align-items-center). |
| GridHorizontalAlignment | Dictionary Phrase | Horizontal alignment of children within the row (e.g. justify-content-center). |
| GridTextAlignment | Dictionary Phrase | Text alignment applied at the row level. |
Section / Display Parameters
| Property | Type | Description |
|---|---|---|
| Color | Dictionary Phrase | Background colour name (combined with Shade to produce mkl-bg-{color}-{shade}). |
| Shade | Dictionary Phrase | Colour shade suffix (defaults to 500 in code when Color is set). |
| UseLightText | Checkbox | Adds light-text class for light-on-dark text. |
| GridPaddingTop | Dictionary Phrase | Top padding on the row/section wrapper (e.g. pt-3). |
| GridPaddingBottom | Dictionary Phrase | Bottom padding on the row/section wrapper (e.g. pb-3). |
| GridMarginTop | Dictionary Phrase | Top margin on the row/section wrapper. |
| GridMarginBottom | Dictionary Phrase | Bottom margin on the row/section wrapper. |
| GridBorderLeft / GridBorderRight / GridBorderTop / GridBorderBottom | Checkbox | Adds section-border-* class when checked. |
| Title | Single-Line Text | Optional heading rendered above child content. |
| HeadingSize | Dictionary Phrase | Visual size class for the title heading element. |
| LowerHeadingImportance | Checkbox | When checked, pushes the heading level down in the document outline hierarchy. |
| BackgroundImage | Image | Background image applied to the SubGrid wrapper with background-size: cover. |
| ImagePosition | Dictionary Phrase | CSS background-position value (code default: center-center). |
| BackgroundVideoLink | General Link | URL to a background video (MP4) displayed behind the SubGrid content. |
| OverlaySmall / OverlayMedium / OverlayLarge | Dictionary Phrase | Background image overlay class at each breakpoint. |
| AddClass | Single-Line Text | Additional CSS classes appended to the SubGrid wrapper. |