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

Create the Single Product Details block #8186

Closed
Tracked by #8054
nefeline opened this issue Jan 15, 2023 · 2 comments · Fixed by #8225
Closed
Tracked by #8054

Create the Single Product Details block #8186

nefeline opened this issue Jan 15, 2023 · 2 comments · Fixed by #8225
Assignees
Labels
focus: FSE Work related to prepare WooCommerce for FSE.

Comments

@nefeline
Copy link
Contributor

nefeline commented Jan 15, 2023

Create a block version of the product details (visible on the single product template), so merchants can add the product description, information, and reviews to their stores.

Property Value
Block title Product Details
Block description TBD
Block slug product-details
Block file location assets/js/blocks/product-details/
Block class location src/BlockTypes/ProductDetails.php
Style
  • Typography
  • Color
  • Spacing
Visibility Woocommerce Core

Tabs

Details:

Property Value
Equivalent template file woocommerce/templates/single-product/tabs/tabs.php
Equivalent template function woocommerce_default_product_tabs()

Screenshot:

Screenshot 2023-01-15 at 20 19 39

Description

Details:

Property Value
Equivalent template file woocommerce/templates/single-product/tabs/description.php
Equivalent template function the_content()

Screenshot:

Screenshot 2023-01-15 at 19 34 39

Additional information

Details:

Property Value
Equivalent template file woocommerce/templates/single-product/tabs/additional-information.php
Equivalent template function wc_display_product_attributes()

Screenshot:

Screenshot 2023-01-15 at 19 45 11

Reviews

Details:

Property Value
Equivalent template file woocommerce/templates/single-product-reviews.php
Equivalent template function (for listing existing reviews) wp_list_comments() and woocommerce_comments()
Equivalent template function (for submitting a new review) comment_form()

Screenshot:

Screenshot 2023-01-15 at 19 45 29

@nefeline nefeline changed the title Create a Single Product Details block Create the Single Product Details block Jan 15, 2023
@nefeline nefeline added the focus: FSE Work related to prepare WooCommerce for FSE. label Jan 15, 2023
@nefeline
Copy link
Contributor Author

Hey @vivialice ! Would you please update the Block Title & Description listed on the description of this issue with the expected copy? A few additional questions:

  • Did we decide on the appropriate placeholder for the editor view for this block?
  • Did we decide on whether we’ll re-utilize the existing classic template layout (including a tabbed container) or refresh with a new design that displays reviews separately outside of a tabbed container?

Thanks!

@tomxygen
Copy link

In my stores I use a PHP snippet to place reviews below product description instead of using the tab switcher.
I wish I could do the same with Blocks.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
focus: FSE Work related to prepare WooCommerce for FSE.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants