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

Adds extensions to groups #202

Merged
merged 2 commits into from
Jul 16, 2023
Merged

Adds extensions to groups #202

merged 2 commits into from
Jul 16, 2023

Conversation

c1rrus
Copy link
Member

@c1rrus c1rrus commented Jan 4, 2023

Closes #106

There seems to be a consensus that allowing groups to have $extensions (just like design tokens can), so this updates the spec accordingly.

@netlify
Copy link

netlify bot commented Jan 4, 2023

Deploy Preview for dtcg-tr ready!

Name Link
🔨 Latest commit b3a004b
🔍 Latest deploy log https://app.netlify.com/sites/dtcg-tr/deploys/63e1773ce192d20008adaf05
😎 Deploy Preview https://deploy-preview-202--dtcg-tr.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site settings.

Copy link
Contributor

@lauthieb lauthieb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Completely agree 💯
Thanks @c1rrus

- The keys SHOULD be chosen such that they avoid the likelihood of a naming clash with another vendor's data. The [reverse domain name notation](https://en.wikipedia.org/wiki/Reverse_domain_name_notation) is recommended for this purpose.
- Tools that process design token files MUST preserve any extension data they do not themselves understand. For example, if a group contains extension data from tool A and the file containing that data is opened by tool B, then tool B MUST include the original tool A extension data whenever it saves a new design token file containing that group.

Note that, since a group's `$extensions` only relate to that group, they do not have any effect on nested groups or tokens.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm wondering whether this sentence is straightforward enough.

Some parts of #106 feels a bit more explicit (too much?)

Groups $extensions should not be inherited. i.e. tokens and groups within a group that has $extensions should not be treated as though they themselves had the same $extensions property.

@valhead valhead merged commit 321f925 into main Jul 16, 2023
@valhead valhead deleted the group-extensions branch July 16, 2023 15:44
github-actions bot added a commit that referenced this pull request Jul 16, 2023
SHA: 321f925
Reason: push, by valhead

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
github-actions bot added a commit that referenced this pull request Jul 16, 2023
SHA: 321f925
Reason: push, by valhead

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
github-actions bot added a commit that referenced this pull request Jul 16, 2023
SHA: 321f925
Reason: push, by valhead

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
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.

Can extensions be applied on the group level?
5 participants