Skip to main content
Solved

What is the tail in SolidPaint's boundVariables.color.id

  • August 7, 2024
  • 1 reply
  • 39 views

Aaron_Xu

I am develop a plugin that can apply variable colors by some rule.
I found I need to assign the value like this:


I know that “e1b04111db373f08ec909607224cbaf0ff8aa032” is the variable’s id, but what is the “/2671:40” , and how do I acquire it?

I am using

const tokensCollection = libraryVariableCollections.find(collection => collection.name === "Tokens");
  if (tokensCollection) {
    const libraryVariables = await figma.teamLibrary.getVariablesInLibraryCollectionAsync(tokensCollection.key);

    const hoverlibraryVariable = libraryVariables.find(variable => variable.name.includes("Hover"));
    console.log(hoverlibraryVariable.key)
}

but it only get “e1b04111db373f08ec909607224cbaf0ff8aa032” part

Best answer by tank666

figma.com
This topic has been closed for replies.

1 reply

tank666
  • 4873 replies
  • Answer
  • August 8, 2024