Automattic / blockpatterns

Repo of block patterns to work with
7 stars 2 forks source link

Two column food menu #274

Closed alaczek closed 2 years ago

alaczek commented 2 years ago

This pattern is from the Munchies theme. I changed the colors to use the default color palette.

Screenshot:

image
<!-- wp:columns {"align":"wide"} -->
<div class="wp-block-columns alignwide"><!-- wp:column {"width":"50%","style":{"spacing":{"padding":{"right":"12px"}}}} -->
<div class="wp-block-column" style="padding-right:12px;flex-basis:50%"><!-- wp:group {"style":{"border":{"radius":"0px","width":"2px"},"spacing":{"padding":{"top":"0px","right":"0px","bottom":"0px","left":"0px"}}},"borderColor":"secondary"} -->
<div class="wp-block-group has-border-color has-secondary-border-color" style="border-width:2px;border-radius:0px;padding-top:0px;padding-right:0px;padding-bottom:0px;padding-left:0px"><!-- wp:group {"layout":{"type":"flex","flexWrap":"nowrap","justifyContent":"left"},"style":{"spacing":{"padding":{"top":"30px","bottom":"30px"}},"elements":{"link":{"color":{"text":"var:preset|color|background"}}}},"backgroundColor":"tertiary","textColor":"primary"} -->
<div class="wp-block-group has-primary-color has-tertiary-background-color has-text-color has-background has-link-color" style="padding-top:30px;padding-bottom:30px"><!-- wp:image {"id":6719,"width":50,"sizeSlug":"large","linkDestination":"none"} -->
<figure class="wp-block-image size-large is-resized"><img src="https://dotcompatterns.files.wordpress.com/2022/09/burger_icon.png?w=602" alt="" class="wp-image-6719" width="50"/></figure>
<!-- /wp:image -->

<!-- wp:heading -->
<h2>Burgers </h2>
<!-- /wp:heading --></div>
<!-- /wp:group -->

<!-- wp:columns {"style":{"spacing":{"padding":{"top":"0px","right":"30px","left":"30px"}}}} -->
<div class="wp-block-columns" style="padding-top:0px;padding-right:30px;padding-left:30px"><!-- wp:column {"width":"70%"} -->
<div class="wp-block-column" style="flex-basis:70%"><!-- wp:group {"style":{"spacing":{"blockGap":"2px"}}} -->
<div class="wp-block-group"><!-- wp:paragraph -->
<p><strong>The Burger</strong></p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p>1/3 lb. Patty, Caramelized Onions, Bleu Cheese, Bacon</p>
<!-- /wp:paragraph --></div>
<!-- /wp:group --></div>
<!-- /wp:column -->

<!-- wp:column {"width":"30%"} -->
<div class="wp-block-column" style="flex-basis:30%"><!-- wp:paragraph {"align":"right"} -->
<p class="has-text-align-right">$8</p>
<!-- /wp:paragraph --></div>
<!-- /wp:column --></div>
<!-- /wp:columns -->

<!-- wp:separator {"backgroundColor":"custom-color-1","className":"is-style-wide"} -->
<hr class="wp-block-separator has-text-color has-custom-color-1-color has-alpha-channel-opacity has-custom-color-1-background-color has-background is-style-wide"/>
<!-- /wp:separator -->

<!-- wp:columns {"style":{"spacing":{"padding":{"top":"0px","right":"30px","left":"30px"}}}} -->
<div class="wp-block-columns" style="padding-top:0px;padding-right:30px;padding-left:30px"><!-- wp:column {"width":"70%"} -->
<div class="wp-block-column" style="flex-basis:70%"><!-- wp:group {"style":{"spacing":{"blockGap":"2px"}}} -->
<div class="wp-block-group"><!-- wp:paragraph -->
<p><strong>Bacon Belly Burger</strong></p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p>1/3 lb. Patty, Caramelized Onions, Bleu Cheese, Bacon, Pork Belly</p>
<!-- /wp:paragraph --></div>
<!-- /wp:group --></div>
<!-- /wp:column -->

<!-- wp:column {"width":"30%"} -->
<div class="wp-block-column" style="flex-basis:30%"><!-- wp:paragraph {"align":"right"} -->
<p class="has-text-align-right">$13</p>
<!-- /wp:paragraph --></div>
<!-- /wp:column --></div>
<!-- /wp:columns -->

<!-- wp:separator {"backgroundColor":"custom-color-1","className":"is-style-wide"} -->
<hr class="wp-block-separator has-text-color has-custom-color-1-color has-alpha-channel-opacity has-custom-color-1-background-color has-background is-style-wide"/>
<!-- /wp:separator -->

<!-- wp:columns {"style":{"spacing":{"padding":{"top":"0px","right":"30px","left":"30px","bottom":"30px"}}}} -->
<div class="wp-block-columns" style="padding-top:0px;padding-right:30px;padding-bottom:30px;padding-left:30px"><!-- wp:column {"width":"70%"} -->
<div class="wp-block-column" style="flex-basis:70%"><!-- wp:group {"style":{"spacing":{"blockGap":"2px"}}} -->
<div class="wp-block-group"><!-- wp:paragraph -->
<p><strong>Steak Burger</strong></p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p>1/2 lb. Ground Sirloin Patty, Caramelized Onions, and Rosemary Mushrooms</p>
<!-- /wp:paragraph --></div>
<!-- /wp:group --></div>
<!-- /wp:column -->

<!-- wp:column {"width":"30%"} -->
<div class="wp-block-column" style="flex-basis:30%"><!-- wp:paragraph {"align":"right"} -->
<p class="has-text-align-right">$14</p>
<!-- /wp:paragraph --></div>
<!-- /wp:column --></div>
<!-- /wp:columns --></div>
<!-- /wp:group --></div>
<!-- /wp:column -->

<!-- wp:column {"width":"50%","style":{"spacing":{"padding":{"right":"12px"}}}} -->
<div class="wp-block-column" style="padding-right:12px;flex-basis:50%"><!-- wp:group {"style":{"border":{"radius":"0px","width":"2px"},"spacing":{"padding":{"top":"0px","right":"0px","bottom":"0px","left":"0px"}}},"borderColor":"secondary"} -->
<div class="wp-block-group has-border-color has-secondary-border-color" style="border-width:2px;border-radius:0px;padding-top:0px;padding-right:0px;padding-bottom:0px;padding-left:0px"><!-- wp:group {"layout":{"type":"flex","flexWrap":"nowrap"},"style":{"spacing":{"padding":{"top":"30px","bottom":"30px"}}},"backgroundColor":"tertiary","textColor":"primary"} -->
<div class="wp-block-group has-primary-color has-tertiary-background-color has-text-color has-background" style="padding-top:30px;padding-bottom:30px"><!-- wp:image {"id":6718,"width":50,"sizeSlug":"large","linkDestination":"none"} -->
<figure class="wp-block-image size-large is-resized"><img src="https://dotcompatterns.files.wordpress.com/2022/09/salad_icon.png?w=602" alt="" class="wp-image-6718" width="50"/></figure>
<!-- /wp:image -->

<!-- wp:heading -->
<h2>Salads</h2>
<!-- /wp:heading --></div>
<!-- /wp:group -->

<!-- wp:columns {"style":{"spacing":{"padding":{"top":"0px","right":"30px","left":"30px"}}}} -->
<div class="wp-block-columns" style="padding-top:0px;padding-right:30px;padding-left:30px"><!-- wp:column {"width":"70%"} -->
<div class="wp-block-column" style="flex-basis:70%"><!-- wp:group {"style":{"spacing":{"blockGap":"2px"}}} -->
<div class="wp-block-group"><!-- wp:paragraph -->
<p><strong>House Salad</strong></p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p>Mixed Greens, Tomato, Cucumber, Red Onion</p>
<!-- /wp:paragraph --></div>
<!-- /wp:group --></div>
<!-- /wp:column -->

<!-- wp:column {"width":"30%"} -->
<div class="wp-block-column" style="flex-basis:30%"><!-- wp:paragraph {"align":"right"} -->
<p class="has-text-align-right">$7</p>
<!-- /wp:paragraph --></div>
<!-- /wp:column --></div>
<!-- /wp:columns -->

<!-- wp:separator {"backgroundColor":"custom-color-1","className":"is-style-wide"} -->
<hr class="wp-block-separator has-text-color has-custom-color-1-color has-alpha-channel-opacity has-custom-color-1-background-color has-background is-style-wide"/>
<!-- /wp:separator -->

<!-- wp:columns {"style":{"spacing":{"padding":{"top":"0px","right":"30px","left":"30px"}}}} -->
<div class="wp-block-columns" style="padding-top:0px;padding-right:30px;padding-left:30px"><!-- wp:column {"width":"70%"} -->
<div class="wp-block-column" style="flex-basis:70%"><!-- wp:group {"style":{"spacing":{"blockGap":"2px"}}} -->
<div class="wp-block-group"><!-- wp:paragraph -->
<p><strong>South West Salad</strong></p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p>Mixed Greens, Tomato, Cucumber, Red Onion, Balsamic Vinaigrette </p>
<!-- /wp:paragraph --></div>
<!-- /wp:group --></div>
<!-- /wp:column -->

<!-- wp:column {"width":"30%"} -->
<div class="wp-block-column" style="flex-basis:30%"><!-- wp:paragraph {"align":"right"} -->
<p class="has-text-align-right">$7</p>
<!-- /wp:paragraph --></div>
<!-- /wp:column --></div>
<!-- /wp:columns -->

<!-- wp:separator {"backgroundColor":"custom-color-1","className":"is-style-wide"} -->
<hr class="wp-block-separator has-text-color has-custom-color-1-color has-alpha-channel-opacity has-custom-color-1-background-color has-background is-style-wide"/>
<!-- /wp:separator -->

<!-- wp:columns {"style":{"spacing":{"padding":{"top":"0px","right":"30px","left":"30px","bottom":"30px"}}}} -->
<div class="wp-block-columns" style="padding-top:0px;padding-right:30px;padding-bottom:30px;padding-left:30px"><!-- wp:column {"width":"70%"} -->
<div class="wp-block-column" style="flex-basis:70%"><!-- wp:group {"style":{"spacing":{"blockGap":"2px"}}} -->
<div class="wp-block-group"><!-- wp:paragraph -->
<p><strong>Chopped Salad</strong></p>
<!-- /wp:paragraph -->

<!-- wp:paragraph -->
<p>Mixed Greens, Tomato, Cucumber, Red Onion, Balsamic Vinaigrette</p>
<!-- /wp:paragraph --></div>
<!-- /wp:group --></div>
<!-- /wp:column -->

<!-- wp:column {"width":"30%"} -->
<div class="wp-block-column" style="flex-basis:30%"><!-- wp:paragraph {"align":"right"} -->
<p class="has-text-align-right">$7</p>
<!-- /wp:paragraph --></div>
<!-- /wp:column --></div>
<!-- /wp:columns --></div>
<!-- /wp:group --></div>
<!-- /wp:column --></div>
<!-- /wp:columns -->

Preview: https://dotcompatterns.wordpress.com/?p=6715

cc @onuro @iamtakashi

onuro commented 2 years ago

Pretty cool @alaczek! Nothing serious and very small thing but testing w TT2 theme, theme has it's own group/row block left/right paddings applied and it may get weird in large resolutions:

image

For that, not super necessarily but maybe it could be useful defining left/right padding to the title groups as well?

iamtakashi commented 2 years ago

Looks good on the preview. Maybe, we could make the prices in bold or with some colour?

alaczek commented 2 years ago

I limited the amount of description, made the prices bold, and adjusted spacing in table headings:

image
iamtakashi commented 2 years ago

Nice. It looks fine to me. Let's publish it in Shop category for now.

onuro commented 2 years ago

Indeed, looking much better!

alaczek commented 2 years ago

Published!

The Shop doesn't feel like the most intuitive category, but I guess none of the others do either 😬 Maybe if we get more food/restaurant-specific patterns we can re-introduce it later.