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

Introduce Variable Scopes for Tokens #2194

Closed
Tracked by #2106 ...
keeganedwin opened this issue Aug 28, 2023 · 7 comments
Closed
Tracked by #2106 ...

Introduce Variable Scopes for Tokens #2194

keeganedwin opened this issue Aug 28, 2023 · 7 comments
Labels
design Design is needed 🩵 Migrated to Featurebase Archive this issue and head to featurebase to follow variables-m2

Comments

@keeganedwin
Copy link
Collaborator

Is your feature request related to a problem? Please describe.
Currently, when creating tokens in Tokens Studio, there is a limitation in scoping options. Users are unable to specify the exact purpose of a token.

Describe the solution you'd like
An enhancement to Tokens Studio that introduces more granular scoping options.

@six7
Copy link
Collaborator

six7 commented Aug 28, 2023

@LukeFinch mind taking on design work for this for the upcoming Variables M2 work? Together with #2193

@six7 six7 added the design Design is needed label Sep 4, 2023
@six7 six7 moved this from 📥 Triage to 🧑‍🎨 Shaping in Tokens Studio for Figma Roadmap Sep 4, 2023
@LukeFinch
Copy link
Contributor

@six7 What do you think about having a setting to auto-scope variables?

Any time I create a border-radius token - it should by default only appear in the border-radius option in Figma

Image

@six7
Copy link
Collaborator

six7 commented Sep 4, 2023

I love it! Helps reduce complexity and i think most users will want that! We'd still want to show the input though, for those where we cant scope automatically? I guess if this is on and you edit a borderRadius token this could be disabled?

@LukeFinch
Copy link
Contributor

Yeah - either we could deactivate the input (maybe with a link to settings) or, this option could just tick the scope input by default, and still let users untick it

@six7 six7 changed the title Enhanced Scoping Options for Tokens Introduce Variable Scopes for Tokens Sep 5, 2023
@LukeFinch LukeFinch self-assigned this Sep 6, 2023
@LukeFinch LukeFinch moved this from 🧑‍🎨 Shaping to 🕜 In Progress in Tokens Studio for Figma Roadmap Sep 11, 2023
@six7
Copy link
Collaborator

six7 commented Sep 12, 2023

Recap from yesterday's discussion on this: Let's try to see if we can get away without a setting, and automatically scope tokens that are of type borderRadius to the corner radius scope silently. Only if a user changes this scope would we set it to something differently (if a variableScope property is present)

One thing we should still add to the shaping here is how this would look like in code. I imagine the $extensions property on each token could contain this information in our namespace, with a variableScope and values of an array matching Figma's scope values of the plugin api?

@six7 six7 added variables-m2 and removed enhancement Internal new feature or functionality labels Sep 13, 2023
@LukeFinch LukeFinch moved this from 🕜 In Progress to 📤 Ready for dev in Tokens Studio for Figma Roadmap Sep 29, 2023
@six7 six7 moved this from 📤 Ready for dev to 🧑‍🎨 Shaping in Tokens Studio for Figma Roadmap Oct 4, 2023
@esthercheran
Copy link
Collaborator

Closing this ticket as this is covered for individual tokens in #2300

@github-project-automation github-project-automation bot moved this from 🧑‍🎨 Shaping to ✅ Done in Tokens Studio for Figma Roadmap Oct 18, 2023
@SamIam4Hyma SamIam4Hyma added the 🩵 Migrated to Featurebase Archive this issue and head to featurebase to follow label May 7, 2024
@SamIam4Hyma
Copy link
Collaborator

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
design Design is needed 🩵 Migrated to Featurebase Archive this issue and head to featurebase to follow variables-m2
Projects
Status: ✅ Done
Development

No branches or pull requests

5 participants