-
Notifications
You must be signed in to change notification settings - Fork 215
Add single product block #8610
Add single product block #8610
Conversation
|
The release ZIP for this PR is accessible via: Script Dependencies ReportThe
This comment was automatically generated by the TypeScript Errors Report
assets/js/blocks/single-product/edit/shared-product-control.tsx
|
|
Size Change: +39.6 kB (+4%) Total Size: 1.1 MB
ℹ️ View Unchanged
|
This attribute is used to determine if the product image should be rendered on the server side or not. This is needed because the product image is not rendered on the server side by default, but we want to render it on the server side when it is inside the Single Product block.
Aljullu
left a comment
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.
From my side, I think we can merge this PR as-is and work in the other issues in follow-ups. Good job, @thealexandrelara, this is an exciting achievement! 👏 Leaving it to @nefeline to do the final approval, though.
Only a heads-up that I'm still able to reproduce this one: Not sure if it needs to be part of this PR, but mentioning in case it's not known: the Product Meta block doesn't seem to work on the Single Product block. I think there is no issue for it, so it might be good to create one so we don't forget.
Unfortunately I can't reproduce it, I tried different scenarios: on the Home template, on the Single Product template, on a post and on a Page, and all of them are rendering the product title when I move the Product Summary bellow it
This only happens to me when GB is disabled and in WP 6.2. But if that's only occurring to me, feel free to merge and I can investigate it later.
nefeline
left a comment
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.
Thanks for addressing all feedback! I did another round of tests; there's only one problem that surfaced that I would recommend fixing before merging, as it is a regression when using the post excerpt block outside of the single product block. The following example is when adding this block to the single product template. On the editor, the following error is triggered:
The Product Meta block is being fixed by Luigi in this PR. I'll investigate more about this issue that you commented Thank you so much for the reviews, insights and suggestions 🙌 |
Thank you for raising this @nefeline, this is an error that was occurring in Gutenberg, but they solved it last week: WordPress/gutenberg#48730 |
nefeline
left a comment
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.
Thank you for raising this @nefeline, this is an error that was occurring in Gutenberg, but they solved it last week: WordPress/gutenberg#48730
Gotcha! Thanks for sharing this info. The curious thing is that the error only occurs when the excerpt is used outside of the single product block; perhaps something to explore later on.
Thanks again for all your work here! I'm a-ok with merging this PR as-is and working on other issues in follow-ups as well. It's fantastic to see this block in place: keep it up! 🚢
Thank you so much for providing detailed reviews and suggestions! Looking forward to see your PR getting merged on Gutenberg, so we can remove this temporary solution and replace it with the suggestion that you made! |
|
@thealexandrelara I have added the correct labels to this PR. |
|
I am skipping adding this to the testing notes as it is experimental. I will check the box in the PR body. |
|
I'm not seeing the block in the released package version 10.0.0 from the .org repo. |
|
Hey there @easilyamused, sorry for the confusion, this block is still marked as experimental and hasn't been released for public use yet. There are still some improvements and fixes we would like to introduce before making the Single Product block available to everybody. If you want to test it now, you can do so downloading one of our nightly builds. However, keep in mind it's experimental so it's not recommended to use it on production sites. We have updated the changelog to make sure this block isn't mentioned there. Hopefully, in the following weeks we will be able to graduate it and make it available in the plugin. 🙂 |

Fixes #8568
Accessibility
prefers-reduced-motionOther Checks
Testing
Automated Tests
User Facing Testing
WooCommerce Visibility
Changelog