Gist
Search…
Lists / Grids
Fixed lists & grids used for different layout options.

Fixed List

The fixed list widget will take a number of components and display them in a vertical list.
The mainAxisAlignment property supports the following options: start, end, spaceBetween, spaceAround & spaceEvenly.
The crossAxisAlignment property supports the following options: start, end, center, stretch & baseline.
Both mainAxisAlignment & crossAxisAlignment are optional.
1
{
2
"type": "fixedListWidget",
3
"mainAxisAlignment": "start",
4
"crossAxisAlignment": "center",
5
"components": [{},{}]
6
}
Copied!

Fixed Horizontal List

The fixed horizontal list widget will take a number of components and display them in a horizontal list.
The mainAxisAlignment property supports the following options: start, end, spaceBetween, spaceAround & spaceEvenly.
The crossAxisAlignment property supports the following options: start, end, center, stretch & baseline.
Both mainAxisAlignment & crossAxisAlignment are optional.
1
{
2
"type": "fixedHorizontalListWidget",
3
"mainAxisAlignment": "start",
4
"crossAxisAlignment": "center",
5
"components": [{},{}]
6
}
Copied!

Fixed Horizontal Scroll List

The fixed horizontal list scroll widget will take a number of components and display them in a horizontal list with scrolling. All properties in this component are required.
1
{
2
"type": "fixedHorizontalListScrollWidget",
3
"height": 150,
4
"components": [{},{}]
5
}
Copied!

Fixed Grid

The fixed grid widget can be used to take a specified number of components and display them on a grid. The itemPadding property is used to add a padding between the items and is optional. childAspectRatio defaults to 1.0 when unspecified.
1
{
2
"type": "fixedGridWidget",
3
"itemPadding": "xs",
4
"columns": 2,
5
"childAspectRatio": 1.5,
6
"components": [{},{}]
7
}
Copied!
Last modified 6mo ago