-
Notifications
You must be signed in to change notification settings - Fork 43
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
Preprocessor to allow token overrides within one token definition mainly for component tokens #1092
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
🦋 Changeset detectedLatest commit: e5d5522 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
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 |
lukasoppermann
force-pushed
the
pre-processor
branch
from
November 25, 2024 13:01
630dd10
to
9326e3b
Compare
lukasoppermann
force-pushed
the
pre-processor
branch
from
November 25, 2024 15:13
faa6456
to
da8d159
Compare
lukasoppermann
changed the title
Pre processor
Preprocessor to allow token overrides within one token definition mainly for component tokens
Dec 4, 2024
lukasoppermann
force-pushed
the
pre-processor
branch
from
December 5, 2024 09:24
05efbd2
to
cff2cf7
Compare
lukasoppermann
temporarily deployed
to
github-pages
December 5, 2024 09:25 — with
GitHub Actions
Inactive
Design Token Diff (Figma)
|
lukasoppermann
force-pushed
the
pre-processor
branch
2 times, most recently
from
December 5, 2024 09:33
0cb917b
to
13c0189
Compare
lukasoppermann
temporarily deployed
to
github-pages
December 5, 2024 09:34 — with
GitHub Actions
Inactive
lukasoppermann
force-pushed
the
pre-processor
branch
from
December 5, 2024 09:40
13c0189
to
dae7eab
Compare
lukasoppermann
temporarily deployed
to
github-pages
December 5, 2024 09:41 — with
GitHub Actions
Inactive
lukasoppermann
temporarily deployed
to
github-pages
December 5, 2024 11:36 — with
GitHub Actions
Inactive
lukasoppermann
force-pushed
the
pre-processor
branch
from
December 5, 2024 12:45
9d87039
to
ce4d3a4
Compare
lukasoppermann
temporarily deployed
to
github-pages
December 5, 2024 12:47 — with
GitHub Actions
Inactive
lukasoppermann
force-pushed
the
pre-processor
branch
from
December 5, 2024 12:51
ce4d3a4
to
22d95da
Compare
lukasoppermann
temporarily deployed
to
github-pages
December 5, 2024 12:53 — with
GitHub Actions
Inactive
lukasoppermann
temporarily deployed
to
github-pages
December 5, 2024 12:59 — with
GitHub Actions
Inactive
lukasoppermann
force-pushed
the
pre-processor
branch
from
December 5, 2024 13:38
9850353
to
bedde36
Compare
lukasoppermann
temporarily deployed
to
github-pages
December 5, 2024 13:40 — with
GitHub Actions
Inactive
lukasoppermann
force-pushed
the
pre-processor
branch
from
December 5, 2024 13:42
bedde36
to
e5d5522
Compare
Merged
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
Using a pre-processor allows us to define value overwrites on a token using the
$extensions['org.primer.overrides']
property.Schema
When building the tokens we need to provide a
theme
to thePlatformConfig
options property, e.g.:If a value with this theme is defined on the token, it will be used, otherwise the "default"
$value
will be used.The benefit of using a pre-processor to other solutions is, that the token can still be transformed normally in the transformation flow. No custom code is required, contributors don't need to understand preprocessors or how this works, to add contributions to other parts.
List of notable changes: