-
Notifications
You must be signed in to change notification settings - Fork 3.3k
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
Apply global theme styles to default blog posts #2727
Apply global theme styles to default blog posts #2727
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.
Works as expected 👍
Left a few comments for potential tweaks
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.
Looks good! The duplicate card markup of course isn't ideal, but doesn't look as bad as I thought. At least we get to remove the old placeholder styles. Let's just address the comments Ludo has up and I'll look to approve after. Also thank you for the helpful PR description/testing steps 👌
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'm happy to review it again if there are any larger code changes that need to be done, otherwise it LGTM. 🎉
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.
Looking good, just had one comment about the ratio value but otherwise looks good to go.
So feel free to adjust or ship as is if that was the intended height 👍
style=" {% if settings.blog_card_style == 'standard' %} --ratio-percent: 100%;{% elsif settings.blog_card_style == 'card' %} --ratio-percent: 0%;{% endif %}" | ||
> | ||
<div class="card__inner{% if settings.blog_card_style == 'standard' %} color-{{ settings.blog_card_color_scheme }} gradient{% endif %} ratio" | ||
style="--ratio-percent: 80%;" |
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.
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.
when I spoke with @Oliviammarcello, she preferred the 80 :)
* applied global theme settings * global theme settings applied, image sized to match other blog posts, preset settings work * fixed spacing for stylesheet * removing change to settings * applied changes suggested in code review * applied suggested changes from code review --------- Co-authored-by: Ludo <ludo.segura@shopify.com>
PR Summary:
Default blog cards are responsive to presets and can be altered by number of blog posts to show, number of columns, color scheme, section paddings and show featured image.
Blog posts theme settings can be applied to default blog posts.
The placeholder image's height and width on default blog posts match other blog posts.
Why are these changes introduced?
Fixes #2688
What approach did you take?
I used the article card and card class names to make the default blog cards responsive to the blog card theme settings and removed the blog placeholder specific classes that weren't responsive to the theme settings.
Other considerations
Visual impact on existing themes
This new change will not impact existing merchant stores but will improve the user experience when adding a featured blog.
Testing steps/scenarios
Blog card theme settings
Demo links
Checklist