rectangle
A rectangular shape, the one shape type that also carries corner radius.
Path
component-api:anatomy.<element>.type: rectangle
Styles
Written on the element, not this anatomy entry — under a variant, slot content, or a composition. The style keys an element of this type may carry:
aspectRatio · backgroundColor · bottom · centerHorizontalOffset · centerVerticalOffset · cornerRadius · cornerSmoothing · effects · end · height · layoutSizingHorizontal · layoutSizingVertical · locked · maxHeight · maxWidth · minHeight · minWidth · opacity · position · rotation · start · strokeAlign · strokeDashPattern · strokeWeight · strokes · top · visible · width
Themes
Selected on the element, not this anatomy entry. Any element may select a theme for a token group, or inherit one from the nearest ancestor — deciding what its subtree’s token references resolve to.
Platform bindings
Figma
Disposition: bound · Realised by: RECTANGLE node
Rules: typeDetection — with text, glyph, vector, container, line, ellipse, polygon, star
Direct node-type mapping both ways; size, fills and corner radii carry the appearance.
CSS
Disposition: bound · Realised by: Css
Rules: elementSelectors — with text, glyph, vector, container, slot, instance, line, ellipse
The one shape CSS speaks natively — size, fills, corners, strokes all land directly.
React
Disposition: bound · Realised by: a styled div
The one shape the platform speaks natively.
Web Components
Disposition: bound · Realised by: a styled div
The one shape the platform speaks natively.
Decisions
None.
Source
| Format | File |
|---|---|
| JSON Schema | packages/schema/schema/component.schema.json |
| TypeScript | packages/schema/types/Element.ts |
| Specification | §2, §11 |