set_layout_child
Configure child nodes inside an auto-layout parent by setting horizontal/vertical sizing, positioning, grow, align, and min/max dimensions, returning per-node results.
Instructions
Set how nodes behave inside their auto-layout parent: horizontal/vertical sizing (FILL needs an auto-layout parent; HUG needs the node itself to be auto layout or text), positioning AUTO|ABSOLUTE (ignore auto layout), grow (1 = fill along parent's direction), alignSelf STRETCH|INHERIT (fill across parent's direction), and min/max width/height (null clears). Returns per-node results ({id, ok, ...} or {id, error}); one failing node does not abort the batch.
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": {
"nodeIds": "<nodeIds>"
},
"name": "set_layout_child"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| file | No | Target file (fileKey, id or name). Defaults to the most recently active file. | |
| grow | No | layoutGrow: 0 or 1 | |
| nodeIds | Yes | Figma node ids, e.g. ['12:34'] | |
| maxWidth | No | ||
| minWidth | No | ||
| vertical | No | layoutSizingVertical | |
| alignSelf | No | layoutAlign | |
| maxHeight | No | ||
| minHeight | No | ||
| horizontal | No | layoutSizingHorizontal | |
| positioning | No | layoutPositioning |