Skip to content
This repository has been archived by the owner on Feb 17, 2025. It is now read-only.

Skatepark: full width image pattern #4396

Merged
merged 8 commits into from
Aug 13, 2021

Conversation

MaggieCabrera
Copy link
Contributor

Changes proposed in this Pull Request:

This PR creates a block pattern and a block style for a full-width image with an aside caption. Positioning the caption correctly was incredibly convoluted and brittle without an extra wrapper on the text inside the caption so I wrapped the text in a strong tag to make it simpler. I'm not sure how much I hate it. Any ideas to improve this are welcome.

Desktop Mobile
Screenshot 2021-08-12 at 10-53-19 aaaa – free Screenshot 2021-08-12 at 10-53-04 aaaa – free

(the wide group block on the screenshot is not part of the pattern, it's there for reference)

Related issue(s):

Part of #4308

@MaggieCabrera MaggieCabrera self-assigned this Aug 12, 2021
@MaggieCabrera MaggieCabrera added the [Theme] Skatepark Automatically generated label for Skatepark. label Aug 12, 2021
@MaggieCabrera MaggieCabrera requested a review from a team August 12, 2021 08:57
Comment on lines +232 to +239
"core/separator": {
"border": {
"width": "0 0 3px 0"
}
},
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

on a first pass, I was using columns and a separator but then changed to use the caption of the image. I'm leaving this here even though it's unrelated, because it may be needed elsewhere

@MaggieCabrera MaggieCabrera mentioned this pull request Aug 12, 2021
8 tasks
@MaggieCabrera
Copy link
Contributor Author

@melchoyce we need an alt text for this image

@scruffian
Copy link
Member

I wrapped the text in a strong tag to make it simpler.

The problem with this is it makes it hard for users to implement via the block style

@scruffian
Copy link
Member

I added a commit to update the approach for the aside caption, but I probably missed some cases...

@MaggieCabrera
Copy link
Contributor Author

I didn't think about the Block Styles flow for the user, so @scruffian is totally right, using strong is a bad idea. Though his commit doesn't make the caption align with the wide block below. I'm not sure we can actually manage to make it look like the design without the extra wrapper, do you think having it full width aligned is a good compromise @melchoyce?

Screenshot 2021-08-12 at 16 00 19

@melchoyce
Copy link
Contributor

I wonder if this should just be an image + column block instead of using a caption 😕

For alt text:

A skateboarder does a grab trick in a bowl-shaped skate park. In the background is a watching crowd, palm trees, and the ocean.

@MaggieCabrera MaggieCabrera force-pushed the skatepark-full-width-image-pattern branch from 153b030 to 6f0e184 Compare August 13, 2021 07:54
@MaggieCabrera MaggieCabrera merged commit 95efc3e into trunk Aug 13, 2021
@MaggieCabrera MaggieCabrera deleted the skatepark-full-width-image-pattern branch August 13, 2021 07:54
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
[Theme] Skatepark Automatically generated label for Skatepark.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants