Skip to content

Conversation

Copilot
Copy link
Contributor

@Copilot Copilot AI commented Sep 20, 2025

Add Figma Variable Scopes, Code Syntax, and Publishing Control Support

This feature gives token designers full control over how their design tokens translate to Figma variables. Users can now define variable scopes to control which UI elements can use each token (text, fills, effects, etc.), specify custom code syntax for different platforms in developer handoff, and control publishing visibility.

Key improvements:

  • New Figma section in token editor with scope selection (checkboxes) and code syntax inputs for Web, Android, and iOS platforms
  • Publishing control: New dropdown to control hiddenFromPublishing metadata with three states: inherit from collection (undefined), show in publishing (false), and hide from publishing (true)
  • Intelligent scope filtering: Only relevant scopes are shown for each token type (e.g., color tokens show fill-related scopes, spacing tokens show gap/sizing scopes)
  • Bi-directional sync: scopes, code syntax, and publishing settings are preserved when importing variables from Figma and applied when creating variables from tokens
  • Opt-in behavior: only tokens with explicitly defined metadata will have them applied, maintaining backward compatibility
  • Comprehensive test coverage: Added unit tests for import/export functionality and Cypress tests for UI interactions

This enhancement bridges the gap between design system specifications and Figma's variable capabilities, ensuring tokens work exactly as intended across design and development workflows while providing granular control over publishing behavior.


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

Copy link

changeset-bot bot commented Sep 20, 2025

🦋 Changeset detected

Latest commit: 0cdb50c

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@tokens-studio/figma-plugin Patch

Not sure what this means? Click here to learn what changesets are.

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

Copilot AI and others added 2 commits September 20, 2025 09:50
Co-authored-by: six7 <4548309+six7@users.noreply.github.com>
Co-authored-by: six7 <4548309+six7@users.noreply.github.com>
@Copilot Copilot AI changed the title [WIP] Address feedback: Add tests and support for Figma's hiddenFromPublishing metadata Add support for variable scopes, code syntax, and hiddenFromPublishing metadata Sep 20, 2025
@Copilot Copilot AI requested a review from six7 September 20, 2025 10:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants