-
Notifications
You must be signed in to change notification settings - Fork 221
Featured Product: Try using Button block for button #398
Conversation
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.
Ok, the alignment "issue" isn't a big deal after all - happy with that. I did notice one small quirk with the behaviour though:
If you justify the block text right, then align the button left, the appearance isn't correct when the button block is highlighted. It then also becomes difficult to hover the button block with that alignment configuration - you have to click on the button directly.
The bigger problem is the button URL not updating when switching products though. If it's not possible to do this then we'll have to remove the product switching feature. I'm sad that will mean lost work but I think button style editing is more important than product switching. It's easy to remove the block and add it again.
7d80806
to
0f7fe1a
Compare
@jameskoster I've fixed the alignment issue. I was also thinking the solution to the URL thing would be to remove the product switching feature, so if you're OK with that, I'll go ahead with it (but in another PR, we can merge this one first). |
Yep, works for me! Edit: Actually, the display is fixed, but the hover effect is missing. If the button is aligned left or right you have to click on the actual button to focus the block. Edit 2: That seems to be a core issue when buttons are nested inside other blocks. I'll open a core issue. |
@jameskoster If this PR is OK design-wise, can you dismiss or update your review? |
0f7fe1a
to
8c0e6dd
Compare
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.
Code LGTM. 👍
See #368 – Use the Button block to render the featured product's call to action button. We set up the block to use a template with the only button block. There are a few gotchas by using the template, though.
Bonuses we get from using the Button block:
Screenshots
It looks the same when inserted by default:
Since it's the button block, we can also use the different button styles:
How to test the changes in this Pull Request:
Given the issues above (and the fact that some were explicitly called out as "don't do this" in #368) I'm looking more for design feedback than dev feedback ATM.