create_rectangle
Insert a rectangle into a Figma frame, auto-layout stack, or slot by specifying parent, size, order, and layout sizing; use x/y only for freeform frames or absolute overlays.
Instructions
Create a rectangle. Pass parentNodeId to insert into a frame, auto-layout stack, or slot. Inside auto layout, omit x/y and use index + layoutSizing; x/y only apply to freeform frames or ignoreAutoLayout overlays.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| x | No | Parent-relative x. Ignored inside auto layout unless ignoreAutoLayout is true. | |
| y | No | ||
| name | No | ||
| index | No | Child index inside the parent. Use this to order items in auto layout. | |
| width | No | ||
| height | No | ||
| parentNodeId | No | ||
| ignoreAutoLayout | No | If true, overlay with absolute x/y inside an auto-layout parent. | |
| layoutSizingVertical | No | FIXED | HUG | FILL | |
| layoutSizingHorizontal | No | FIXED | HUG | FILL |