Skip to content
This repository was archived by the owner on Feb 23, 2024. It is now read-only.

Commit 00d7e64

Browse files
authored
Add Product Details: product listing pattern (#9383)
* Add the skeleton for the Product Details: product listing pattern * Update the wp-block-woocommerce-single-product class. * Update the product details pattern for usage with core blocks. * Update margins for the product reviews. * Update the styles and spacing for ratings. * Additional changes to the editor preview for product ratings. * update spacing between ratings and text. * Update content padding. * Adjust the pricing * Make adjustments to the button * Update styles. * Update styles for the star ratings. * Extra fine-tunning for reviews and font size * Add the product details image.
1 parent 6faf322 commit 00d7e64

File tree

2 files changed

+48
-0
lines changed

2 files changed

+48
-0
lines changed
462 KB
Loading
Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
<?php
2+
/**
3+
* Title: Product Details: product listing
4+
* Slug: woocommerce-blocks/product-details-listing
5+
* Categories: WooCommerce
6+
*/
7+
?>
8+
<!-- wp:columns {"style":{"spacing":{"padding":"0px","blockGap":{"top":"0","left":"0"}}}} -->
9+
<div class="wp-block-columns" style="padding:0">
10+
<!-- wp:column {"style":{"spacing":{"blockGap":"0","padding":"0px"}}} -->
11+
<div class="wp-block-column" style="padding:0">
12+
<!-- wp:image {"sizeSlug":"full","linkDestination":"none"} -->
13+
<figure class="wp-block-image size-full">
14+
<img src="<?php echo esc_url( plugins_url( 'images/pattern-placeholders/product-details-product-listing.jpg', dirname( __FILE__ ) ) ); ?>" alt="" />
15+
</figure>
16+
<!-- /wp:image -->
17+
<!-- wp:group {"style":{"spacing":{"padding":"0px","blockGap":"0px","margin":{"top":"30px","bottom":"20px","left":"31%"}}},"layout":{"type":"flex","flexWrap":"nowrap","verticalAlignment":"center"}} -->
18+
<div class="wp-block-group is-content-justification-center" style="margin-top:30px;margin-bottom:20px;margin-left:31%;padding:0">
19+
<!-- wp:paragraph {"style":{"typography":{"fontSize":"24px","textColor":"#fda700"}} -->
20+
<p class="has-text-color" style="color:#fda700;font-size:24px">★★★★</p>
21+
<!-- /wp:paragraph -->
22+
<!-- wp:paragraph {"style":{"typography":{"fontSize":"24px"},"textColor":"#ffe8a4","spacing":{"margin":{"right":"8px"}}} -->
23+
<p class="has-text-color" style="color:#ffe8a4;margin-right:8px;font-size:24px">★</p>
24+
<!-- /wp:paragraph -->
25+
<!-- wp:paragraph {"style":{"typography":{"fontSize":"13px"},"textColor":"foreground"} -->
26+
<p class="has-foreground-color has-text-color" style="font-size:13px"><strong>4.2 </strong>(1,079 reviews)</p>
27+
<!-- /wp:paragraph -->
28+
</div>
29+
<!-- /wp:group -->
30+
<!-- wp:heading {"style":{"spacing":{"margin":{"bottom":"20px"}},"typography":{"fontSize":"48px","fontStyle":"normal","fontWeight":"700","lineHeight":"120%"}},"textColor":"black","fontSize":"x-large"} -->
31+
<h2 class="wp-block-heading has-black-color has-text-color has-text-align-center has-x-large-font-size" style="font-size:48px;font-style:normal;font-weight:700;line-height:120%;margin-bottom:20px;">Bella Pro Series - 1.6-qt. Deep Fryer - Stainless Steel</h2>
32+
<!-- /wp:heading -->
33+
<!-- wp:paragraph {"style":{"spacing":{"margin":{"bottom":"40px"}},"padding":"0px","blockGap":"0px","margin":{"bottom":"20px"}},"typography":{"fontSize":"28px","fontWeight":"700"}},"textColor":"foreground"} -->
34+
<p class="has-foreground-color has-text-color has-text-align-center" style="font-size:28px;margin-bottom:40px;">
35+
<strong><sup><sub>$</sub></sup>37.49 </strong><s style="color:lightgrey;font-weight:400;">$47.49</s>
36+
</p>
37+
<!-- /wp:paragraph -->
38+
<!-- wp:buttons {"style":{"spacing":{"blockGap":"0px"}}} -->
39+
<div class="wp-block-buttons is-content-justification-center">
40+
<!-- wp:button {"backgroundColor":"black","textColor":"white","className":"is-style-fill","fontSize":"medium","style":{"spacing":{"padding":{"left":"94px","right":"94px","top":"20px","bottom":"20px"}}}} -->
41+
<div class="wp-block-button has-custom-font-size is-style-fill has-medium-font-size"><a class="wp-block-button__link has-white-color has-black-background-color has-text-color has-background wp-element-button" style="padding-right:94px;padding-left:94px;padding-top:20px;padding-bottom:20px;"><strong>Add to cart</strong></a></div>
42+
<!-- /wp:button -->
43+
</div>
44+
<!-- /wp:buttons -->
45+
</div>
46+
<!-- /wp:column -->
47+
</div>
48+
<!-- /wp:columns -->

0 commit comments

Comments
 (0)