Social logos: prefix token names & use as dependency around the repo#50413
Social logos: prefix token names & use as dependency around the repo#50413simison wants to merge 8 commits into
Conversation
| &.share-print { | ||
| background: #c5c2c2; | ||
| } | ||
|
|
||
| &.share-mail { | ||
| background: #c5c2c2; |
There was a problem hiding this comment.
Simply moved these down to group selectors using tokens from the rest.
|
Are you an Automattician? Please test your changes on all WordPress.com environments to help mitigate accidental explosions.
Interested in more tips and information?
|
| &.share-x { | ||
| background: #000; | ||
| } |
There was a problem hiding this comment.
Replaced #000 with --jetpack-social-logo-color-x for X.
|
Thank you for your PR! When contributing to Jetpack, we have a few suggestions that can help us test and review your patch:
This comment will be updated as you work on your PR and make changes. If you think that some of those checks are not needed for your PR, please explain why you think so. Thanks for cooperation 🤖 Follow this PR Review Process:
If you have questions about anything, reach out in #jetpack-developers for guidance! Jetpack plugin: No scheduled milestone found for this plugin. If you have any questions about the release process, please ask in the #jetpack-releases channel on Slack. Social plugin: No scheduled milestone found for this plugin. If you have any questions about the release process, please ask in the #jetpack-releases channel on Slack. |
|
|
||
| .whatsapp { | ||
| background-color: $whatsapp; | ||
| background-color: var(--jetpack-social-logo-color-whatsapp); |
There was a problem hiding this comment.
Using shared --jetpack-social-logo-color-whatsapp instead of fixed $whatsapp
Code Coverage SummaryThis PR did not change code coverage! That could be good or bad, depending on the situation. Everything covered before, and still is? Great! Nothing was covered before? Not so great. 🤷 |
Prep work for removing inlining
var()tokens in #50108Proposed changes
--color-bluesky→--jetpack-social-logo-color-blueskyetcCurrently, in the webpack build pipeline (excluding
wp-buildpages) we inline tokens (color: var( --color-foo )becomescolor: #000), and the tokens are added from@automattic/calypso-color-schemesas part of the build process:jetpack/projects/packages/publicize/postcss.config.js
Lines 3 to 18 in 6e1fbd2
This was mostly done for backwards compatibility with old browsers. When switching to use WPDS tokens, we should preserve
var()in the CSS and add fallbacks instead as part of the build-process, resulting in:color: var( --color-foo, #000 )This PR will do a couple of things in preparation for the above:
@automattic/calypso-color-schemesand explicitly import these colors only fromsocial-logospackage everywhere.--color-*in WP admin context is a bit too generic and risks conflicting with other plugins; hence new prefix.I'm also:
$whatsappsass variable to use the CSS token instead.share-xclass in sharing buttons block styleRelated product discussion/links
Does this pull request change what data or activity we track or use?
Testing instructions
Smoke test affected UIs: