tokens-studio / figma-plugin

Official repository of the plugin 'Tokens Studio for Figma' (Figma Tokens)
https://www.figma.com/community/plugin/843461159747178978
MIT License
1.35k stars 194 forks source link

fix: color swatches to show colors with gradients #2952

Closed cuserox closed 3 months ago

cuserox commented 3 months ago

Why does this PR exist?

Closes #2951

Colors with semicolons were not applying to the color swatches due to an error when the DOM CSS styling was attempting to be applied

What does this pull request do?

Testing this change

  1. Create a color token as a gradient (i.e. linear-gradient(to right,#dc573c,#247efc);)
  2. Create or edit another color token - search by name or alias
  3. See the gradient showing on the swatch
Before After
Screenshot 2024-07-02 at 12 04 03 Screenshot 2024-07-02 at 12 17 05
Screenshot 2024-07-02 at 12 04 14 Screenshot 2024-07-02 at 12 17 13
changeset-bot[bot] commented 3 months ago

⚠️ No Changeset found

Latest commit: 09b3428b1b2770cd30ccf2aa21ecb9a7d9d2ad5a

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR