API reference
Text
Place a title, body copy, label, or number as an editable text layer.
presentation.tsx
<Text id="headline" role="title" x={8} y={8} w={70} h={14} color="#171717" fontFamily="Arial" fontSize={42} fontWeight={700} lineHeight={1.1}>
A clear headline
</Text>Props reference
Keep these values literal and serializable so Canvas, Inspector, validation, and export can process them reliably.
| API | Property | Type / values | Required | Description |
|---|---|---|---|---|
| Shared native-layer props | id | string | Yes | Stable, unique layer identifier. Required for every visible native layer. |
| x | number | Yes | Left position as a percentage of the slide canvas. | |
| y | number | Yes | Top position as a percentage of the slide canvas. | |
| w | number | Yes | Frame width as a percentage of the slide canvas. | |
| h | number | Yes | Frame height as a percentage of the slide canvas. | |
| groupId | string | — | Groups native children without adding a wrapper element. | |
| groupName | string | — | Human-readable name for a group in Workbench. | |
| sharedId | string | — | Matches the same layer type across adjacent Morph slides; unique within each slide. | |
| rotation | number | — | Clockwise rotation in degrees. | |
| opacity | number | — | Layer opacity from 0 to 1. | |
| motion | JSON string | — | Versioned declarative action sequence. Keep a complete static final frame. | |
| interaction | JSON string | — | Versioned click interaction for slide navigation or a link. | |
| Text | children | ReactNode | Yes | Text content for the layer. |
| role | "title" | string | — | Use title for the primary slide title. | |
| fontFamily | string | — | Font family name. | |
| fontSize | number | — | Font size in points when Slide uses fontSizeUnit="pt". | |
| fontWeight | number | string | — | Font weight, such as 400 or 700. | |
| fontStyle | "italic" | — | Italic text style. | |
| color | color string | — | Text color. | |
| background | color string | — | Text-frame background color. | |
| radius | number | — | Corner radius for the text frame. | |
| lineHeight | number | — | Line-height multiplier. | |
| letterSpacing | number | — | Letter spacing in points. | |
| textAlign | left | center | right | — | Horizontal text alignment. | |
| textVerticalAlign | top | middle | bottom | — | Vertical text alignment in the frame. | |
| listType | bullet | ordered | — | Optional list formatting. | |
| listStart | number | — | Starting number for an ordered list. |
Required syntax
Text uses children for its content and needs id plus x, y, w, and h. Use role="title" for the primary title of a slide.
Common styling
Use color, fontFamily, fontSize, fontWeight, lineHeight, letterSpacing, and textAlign as literal values. With fontSizeUnit="pt" on Slide, fontSize is in points.