Skip to main content

Version 1, Update 79

We're introducing an improved way to attach straight connectors to nodes in FigJam with a new CENTER magnet. Starting in 2024, straight connectors will only be able to attach to CENTER and NONE magnets. The magnets for elbowed connectors will remain unchanged.

Notice of breaking change:

caution

To support CENTER magnets as the improved way for straight connectors to attach to nodes, we are making a breaking change for plugins that set straight connector endpoint magnets to AUTO, TOP, LEFT, BOTTOM, or RIGHT.

Who is affected: Anyone with a plugin/widget that touches straight connectors and sets an endpoint magnet to AUTO, TOP, LEFT, BOTTOM, or RIGHT.

What you must do: Find and update the code that sets the endpoints of straight connectors to use the CENTER or NONE magnet.

What will happen now:

  • In-development plugins/widgets will see a non-blocking warning if a magnet other than CENTER or NONE is set for a straight connector.

What will happen starting October 25, 2023:

  • In-development plugins/widgets will always throw an error if a magnet other than CENTER or NONE is set for a straight connector.

What will happen in 2024:

  • Published plugins/widgets will always throw an error if a magnet other than CENTER or NONE is set for a straight connector.

Version 1, Update 77

New:

  • Add detachedInfo to detached instances to indicate if a node is detached from the main component, and to identify its original main component.
  • Add figma.constants.colors, which maps color palette names to ColorPalette. We provide figJamBase and figJamBaseLight, a set of official FigJam colors.
  • Each Reaction object has an actions array replacing the existing action property for executing multiple actions on the same trigger
  • The Action object supports two new action types:

See the reactions property page for more details and code samples.

Notice of breaking change:

caution

To support multiple actions per trigger in the Reaction object, we are making a breaking change for plugins that set the reactions property.

Who is affected: Anyone with a plugin/widget with code that sets the reactions property.

What you must do: Check and update your code to use the new actions property in each Reaction object.

What will happen now:

  • In-development plugins/widgets that set reactions with only the action object without the new actions array will always throw an error. This is to prevent data loss on nodes that already have reactions with multiple actions.
  • Code that sets reactions with both action and actions are fine. actions will take precedence and action will be ignored.

What will happen starting November 9:

  • Published plugins/widgets will always throw an error if the actions array is not present when setting reactions.

Version 1, Update 76

This update fixes a bug with the optional networkAccess key in the plugin manifest. Previously, we had an error where we would treat local worker scripts as well as blob: URLs as external resources. If you were affected by this, you can now update your networkAccess field.

New:

  • Figma will now return inferred variables when there are variables in the file that match the raw values used in your design.
  • Add openTypeFeatures property for text nodes to expose OpenType features that have been explicitly enabled or disabled.

Version 1, Update 75

The Variable object has been extended with with the ability to read and define a variable's code syntax field. Code syntax allows you to represent design variables in code using custom, syntactically correct variable names to support a seamless handoff experience. It can be configured for different contexts, including CSS, SwiftUI, and Compose. A variable's code syntax will appear in Dev Mode's code snippets when inspecting elements using the variable.

New:

Version 1, Update 74

This update contains a small change for users of the Variables API public beta.

When getting or assigning elements to the Variable.scopes array, please update your code to use 'STROKE_COLOR' instead of 'STROKE'. The meaning is the same. The value 'STROKE' is deprecated and will no longer be supported in our type definitions.

For a full list of possible values, see VariableScope.

Version 1, Update 72

This version introduces utility functions that allow you to set color properties using a variety of familiar encodings, including CSS hex strings and rgb()/hsl()-style function strings. The new functions include:

Examples:

const paint = {
type: 'SOLID',
color: figma.util.rgb('#FF0')
}
const layoutGrid = {
pattern: 'GRID',
sectionSize: 1,
color: figma.util.rgba('rgb(25% 25% 25%)')
}

You can alias these functions for more concise code:

const rgb = figma.util.rgb
const rgba = figma.util.rgba

const paint = {
type: 'SOLID',
color: rgb('#FF0')
}
const layoutGrid = {
pattern: 'GRID',
sectionSize: 1,
color: rgba('rgb(25% 25% 25%)')
}

A common use case is to set a node fill. Use the figma.util.solidPaint() function when you want to update the color of a fill while preserving other properties of the fill object:

if (node.fills[0].type === 'SOLID') {
node.fills = [
// Merge the original fill with a new color and opacity
figma.util.solidPaint("#FF00FF88", node.fills[0])
]
}

Other changes in this version:

  • Add new assignable values for ShapeWithTextNode.shapeTypes: TRAPEZOID, PREDEFINED_PROCESS, SHIELD, DOCUMENT_SINGLE, DOCUMENT_MULTIPLE, MANUAL_INPUT, HEXAGON, CHEVRON, PENTAGON, OCTAGON, STAR, PLUS, ARROW_LEFT, ARROW_RIGHT, SUMMING_JUNCTION, OR, SPEECH_BUBBLE, INTERNAL_STORAGE