Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[WIP] DevMode - Add shared token-data to styles & variables #2127

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

LukeFinch
Copy link
Contributor

@LukeFinch LukeFinch commented Aug 2, 2023

If we add sharedPluginData to styles & variables we create through the plugin, we can look up which token it is if users apply them natively without the plugin.

Currently, as a proof of concept needs refining to be production-ready.

  • support typography & effect styles
  • handle "mixed" styles. e.g text with segments of different styles (stretch goal)
  • handle layers where users an apply multiple variables. (This could perhaps be avoided if we propose variables in styles)

Figma's API has been updated to support setting sharedPluginData on a variable however it is undocumented at this time.

@LukeFinch LukeFinch added the do not merge Not ready for merging yet label Aug 2, 2023
@changeset-bot
Copy link

changeset-bot bot commented Aug 2, 2023

⚠️ No Changeset found

Latest commit: 969c089

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

@LukeFinch LukeFinch changed the title [WIP] DevMode - Add shared token-data to styles [WIP] DevMode - Add shared token-data to styles & variables Oct 19, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
do not merge Not ready for merging yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant