Create Frame
create_frameCreate a frame container at specified position and size, with optional fill and stroke, and full auto-layout settings including padding, alignment, and sizing.
Instructions
Create a frame (container) with optional fill/stroke and full auto-layout configuration.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| x | Yes | X position | |
| y | Yes | Y position | |
| width | Yes | Width of the frame | |
| height | Yes | Height of the frame | |
| name | No | Optional name for the frame | |
| parentId | Yes | Parent node ID to append the frame to | |
| parentNodeName | No | Name of the parent node to verify against | |
| fillColor | No | Fill color in RGBA format | |
| strokeColor | No | Stroke color in RGBA format | |
| strokeWeight | No | Stroke weight | |
| layoutMode | No | Auto-layout mode for the frame | |
| layoutWrap | No | Whether the auto-layout frame wraps its children | |
| paddingTop | No | Top padding for auto-layout frame | |
| paddingRight | No | Right padding for auto-layout frame | |
| paddingBottom | No | Bottom padding for auto-layout frame | |
| paddingLeft | No | Left padding for auto-layout frame | |
| primaryAxisAlignItems | No | Primary axis alignment for auto-layout frame. Note: When set to SPACE_BETWEEN, itemSpacing will be ignored as children will be evenly spaced. | |
| counterAxisAlignItems | No | Counter axis alignment for auto-layout frame | |
| layoutSizingHorizontal | No | Horizontal sizing mode for auto-layout frame | |
| layoutSizingVertical | No | Vertical sizing mode for auto-layout frame | |
| itemSpacing | No | Distance between children in auto-layout frame. Note: This value will be ignored if primaryAxisAlignItems is set to SPACE_BETWEEN. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | ID of the created frame | |
| name | Yes | Name of the created frame |