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

2754 20 trying to apply a composite token that is a reference to another token fails if the referenced token comes from another set #2784

Conversation

robinhoodie0823
Copy link
Contributor

Why does this PR exist?

Current plugin does not successfully affect token to figma if it has multiple level token references.

Closes #2754

What does this pull request do?

Added previous resolvedValueWithReferences to the token.

Testing this change

Additional Notes (if any)

20240521_032431.mp4

@robinhoodie0823 robinhoodie0823 requested a review from six7 May 21, 2024 07:34
Copy link

changeset-bot bot commented May 21, 2024

⚠️ No Changeset found

Latest commit: 3c0301f

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

@robinhoodie0823 robinhoodie0823 self-assigned this May 21, 2024
@robinhoodie0823 robinhoodie0823 changed the base branch from main to release-139 May 21, 2024 08:11
@@ -330,4 +331,4 @@ class TokenResolver {

const defaultTokenResolver = new TokenResolver([]);

export { defaultTokenResolver };
export { defaultTokenResolver };
Copy link
Collaborator

Choose a reason for hiding this comment

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

Linebreak

Comment on lines +189 to +191
if (resolvedTokenValue.resolvedValueWithReferences) {
resolvedValueWithReferences = resolvedTokenValue.resolvedValueWithReferences;
}
Copy link
Collaborator

Choose a reason for hiding this comment

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

Can you add a test case that covers this

@robinhoodie0823 robinhoodie0823 requested a review from six7 May 22, 2024 00:01
Copy link
Collaborator

@six7 six7 left a comment

Choose a reason for hiding this comment

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

🎉

@six7 six7 merged commit d03b0c9 into release-139 May 22, 2024
5 of 6 checks passed
@six7 six7 deleted the 2754-20-trying-to-apply-a-composite-token-that-is-a-reference-to-another-token-fails-if-the-referenced-token-comes-from-another-set branch May 22, 2024 06:05
@six7 six7 added the 2.0-rc7 label Jun 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
2 participants