figma_create_text
Add a text node outside components with mandatory DS text style and color variable. Name nodes semantically (e.g., 'Page Title').
Instructions
Creates a standalone text node bound to a DS text style (textStyleId — accepts style name or key) and DS color variable (fillVariable) — both are mandatory when the DS has them. Use for text OUTSIDE components; text inside a component instance uses figma_component_text instead. Strips hardcoded line breaks (container width controls wrapping). Name nodes after their HTML role ("Page Title", "Card: Revenue Label"). Params: parentId + content required. Phase 2+.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | No | Semantic name describing the HTML element role (e.g., "Page Title", "Card: Revenue Label", "Subtitle"). Never use generic names like "Text". | |
| width | No | Fixed width for the text node. | |
| content | Yes | Text content. | |
| parentId | Yes | Parent node ID. | |
| fillStyleId | No | DS fill style key for text color (from figma_list_ds (kind: "fill_styles")). Preferred over fillVariable when DS has fill styles but no variables. | |
| textStyleId | No | DS text style — accepts style name (e.g. "Text sm/Semibold") or style key. Names are resolved to keys automatically. | |
| fillVariable | No | DS variable path for text color. | |
| fontSizeVariable | No | DS variable path for font size (if no text style). | |
| layoutPositioning | No | Set to ABSOLUTE to overlay this text inside an auto-layout parent. | |
| lineHeightVariable | No | DS variable path for line height. | |
| textAlignHorizontal | No | Text alignment. | |
| layoutSizingHorizontal | No | Horizontal sizing mode. |