-
Notifications
You must be signed in to change notification settings - Fork 69
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
Improve BNPL PMME and icon placement in shortcode checkout #9993
base: develop
Are you sure you want to change the base?
Conversation
7f7225a
to
18ce08a
Compare
Test the buildOption 1. Jetpack Beta
Option 2. Jurassic Ninja - available for logged-in A12s🚀 Launch a JN site with this branch 🚀 ℹ️ Install this Tampermonkey script to get more options. Build info:
Note: the build is updated when a new commit is pushed to this PR. |
Size Change: +1.02 kB (0%) Total Size: 1.39 MB
ℹ️ View Unchanged
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Very nice! I like the solution you have on the spacer 💯 very clever!
Although this is essentially reworking the label rendering with more JS, which is what @brettshumaker is spiking on in this ticket 😬 #9819
I don't know if this is going to be digging us in a trench or if the escape hatch is ez enough.
Despite the possible overlap (and performance implications), this seems to be working as expected 💯
|
||
let spacer = targetLabel.querySelector( 'span.spacer' ); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it would be helpful for our future selves to add a comment here to indicate that the spacer has been added because WC Core adds the
, and the spacer is useful to ensure all labels are vertically aligned properly
@gpressutto5 ope, sorry - this is Twenty Twenty Three: Without these changes this is how it looked without these changes - it just seems less "broken" (the labels aren't pushed up): Is there any chance we can improve on this? I'm just concerned that there might be other themes behaving differently |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
New changes look good, thank you for the added comment!
// Unfortunately, there is no direct way to detect the existence of pseudo-elements like ::before using CSS selectors, | ||
// so we use the theme class to add the necessary styles. | ||
.theme-storefront, | ||
.theme-twentytwentythree { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixes #9817
Changes proposed in this Pull Request
This PR enhances the alignment of the PMME, the logos, and the radio button in the shortcode checkout. It wraps the inner html of the label in a woopayments-inner-label so we can have the same behavior we had with the rich labels that were removed in #9800.
Storefront behaves different than most themes so we also added CSS specific for it.
Testing instructions
npm run changelog
to add a changelog file, choosepatch
to leave it empty if the change is not significant. You can add multiple changelog files in one PR by running this command a few times.Post merge