Repository navigation
Conversation
|
Size Change: 0 B Total Size: 7.52 MB |
|
Flaky tests detected in 152ba72. 🔍 Workflow run URL: https://github.com/WordPress/gutenberg/actions/runs/28083481924
|
|
The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message. To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook. |
ciampo
left a comment
There was a problem hiding this comment.
Nice, the new import path also feels cleaner 🚀
| @@ -0,0 +1 @@ | |||
| @forward "./src/prebuilt/scss/design-token-fallbacks"; | |||
| "sass": "./design-token-fallbacks.scss", | ||
| "style": "./design-token-fallbacks.scss", | ||
| "default": "./design-token-fallbacks.scss" |
There was a problem hiding this comment.
I looked into this a bit more, and I've concluded that we want either:
sasscondition only (supports both legacy and modern setups)- No conditionals at all (supports only the legacy setup, but matches the rest of the repo)
The sass condition seems to be the recommended way for the modern NodePackageImporter setup. So I guess it's good to start supporting that, too.
fda0164
into
revert/reapply-wpds-sass-fallbacks
* Reapply "Base Styles: Add wpds-var Sass helper for design token fallbacks (#78698)" (#79429) This reverts commit 3031bb0. * Theme: Add Sass fallback helper root entrypoint (#79471) * Theme: Add Sass fallback helper shim * Theme: Fix Sass fallback helper imports * Theme: Remove fallback Sass export conditions Co-authored-by: mirka <0mirka00@git.wordpress.org> Co-authored-by: ciampo <mciampini@git.wordpress.org> Co-authored-by: aduth <aduth@git.wordpress.org> * Fix focus ring docblock formatting * Update Sass token utility entrypoint * Add changelog --------- Co-authored-by: ciampo <mciampini@git.wordpress.org> Co-authored-by: aduth <aduth@git.wordpress.org> Co-authored-by: mirka <0mirka00@git.wordpress.org> Co-authored-by: simison <simison@git.wordpress.org>
* Reapply "Base Styles: Add wpds-var Sass helper for design token fallbacks (WordPress#78698)" (WordPress#79429) This reverts commit 3031bb0. * Theme: Add Sass fallback helper root entrypoint (WordPress#79471) * Theme: Add Sass fallback helper shim * Theme: Fix Sass fallback helper imports * Theme: Remove fallback Sass export conditions Co-authored-by: mirka <0mirka00@git.wordpress.org> Co-authored-by: ciampo <mciampini@git.wordpress.org> Co-authored-by: aduth <aduth@git.wordpress.org> * Fix focus ring docblock formatting * Update Sass token utility entrypoint * Add changelog --------- Co-authored-by: ciampo <mciampini@git.wordpress.org> Co-authored-by: aduth <aduth@git.wordpress.org> Co-authored-by: mirka <0mirka00@git.wordpress.org> Co-authored-by: simison <simison@git.wordpress.org>
What?
Stacked on #79470
Adds a package-root Sass shim for
@wordpress/theme/design-token-fallbacksand points the package export at that stable entry point.Why?
The Sass fallback helper needs to work in both package-export-aware build tools and older Sass setups that resolve packages from
node_moduleswith a load path. Exporting or documenting a generatedsrc/prebuiltpath would make package internals part of the public API.This should unblock us to reinstall the changes that we reverted in #79429.
How?
Adds
packages/theme/design-token-fallbacks.scssas a public shim that forwards to the generated helper. The package export now points to that shim with Sass/style/default conditions, and the docs use the same public@wordpress/theme/design-token-fallbacksimport for both package importer and load-path Sass setups.Testing Instructions
npm run storybook:build.