set_layout_grids
Configure a frame's layout grids (columns, rows, or uniform squares) to define structure. Replaces existing grids; pass an empty array to clear.
Instructions
Set a frame's own layout grids — the responsive column/row scaffold laid over it (the 12-column grid, the 8pt baseline), distinct from auto-layout (set_auto_layout arranges children). Each grid is COLUMNS / ROWS (count + gutterSize + alignment, e.g. a 12-col grid) or GRID (uniform squares via sectionSize, a baseline). Replaces the frame's grids with the array given; pass [] to clear them. Only frames (and components/instances) carry layout grids. Returns { ok, nodeId }.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"nodeId": "<nodeId>",
"grids": "<grids>"
},
"name": "set_layout_grids"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| grids | Yes | Layout grids to set; [] clears all grids on the frame | |
| nodeId | Yes | Frame (or component/instance) node id |