rotate_node
Rotate a specific Figma node by a defined angle around a chosen pivot point. Inputs include node ID, angle, and pivot type (e.g., center or custom coordinates). Returns rotated node details for precise design adjustments.
Instructions
Rotate a node in Figma.
Returns:
content: Array of objects. Each object contains a type: "text" and a text field with the rotated node's ID, angle, and pivot info.
Input Schema
Name | Required | Description | Default |
---|---|---|---|
angle | Yes | The rotation angle in degrees. Positive is clockwise. | |
nodeId | Yes | The unique Figma node ID to rotate. | |
pivot | No | The pivot point for rotation. Defaults to 'center'. | center |
pivotPoint | No | Custom pivot point coordinates. Required if pivot is 'custom'. |
Input Schema (JSON Schema)
{
"$schema": "http://json-schema.org/draft-07/schema#",
"additionalProperties": false,
"properties": {
"angle": {
"description": "The rotation angle in degrees. Positive is clockwise.",
"maximum": 360,
"minimum": -360,
"type": "number"
},
"nodeId": {
"description": "The unique Figma node ID to rotate.",
"type": "string"
},
"pivot": {
"default": "center",
"description": "The pivot point for rotation. Defaults to 'center'.",
"enum": [
"center",
"top-left",
"top-right",
"bottom-left",
"bottom-right",
"custom"
],
"type": "string"
},
"pivotPoint": {
"additionalProperties": false,
"description": "Custom pivot point coordinates. Required if pivot is 'custom'.",
"properties": {
"x": {
"description": "X coordinate of the custom pivot point (absolute coordinates).",
"type": "number"
},
"y": {
"description": "Y coordinate of the custom pivot point (absolute coordinates).",
"type": "number"
}
},
"required": [
"x",
"y"
],
"type": "object"
}
},
"required": [
"nodeId",
"angle"
],
"type": "object"
}