1681-engine / ui / wrapRow
Function: wrapRow() ​
ts
function wrapRow(
widths,
maxWidth,
gap?
): number[][];Defined in: src/ui/layout/wrapRow.ts:5
Breaks a row of items (tabs, chips, buttons) into lines no wider than maxWidth: each line holds the indices of its items in order. An item wider than the line still gets a line of its own rather than being dropped.
Parameters ​
| Parameter | Type | Default value |
|---|---|---|
widths | readonly number[] | undefined |
maxWidth | number | undefined |
gap | number | 0 |
Returns ​
number[][]