f39d8b7943
* Add default Single Product HTML template * Fix style issues when adding blocks inside group/stack/columns blocks * Add Related Products to the default single product template HTML file * Remove !important statement from Product Image Gallery block css * Change width of Product Image Gallery block to initial instead of unset * Wrap up default single product html template (https://github.com/woocommerce/woocommerce-blocks/pull/8632) * Add minimum structure for Single Product Details block * Add Product Image Gallery woocommerce/woocommerce-blocks#8233 Add Product Image Gallery * Add tests for Single Product Details block * Add the initial basis for the Add to Cart button * Trigger the single product add to cart action for each product type. * wip: create block structure and add initial styles * Add block details to the SingleProductDetails.php file * Rename the block from add-to-cart-button to add-to-cart-form * Update to use the cart icon. * Implement the skeleton for the editor preview. * Render tabs title with empty content * Use woocommerce_output_product_data_tabs function to retrieve tabs data * Update styles and add Notice for the display in the Editor. * Update CSS. * Add base tests for the new Add to Cart Form component. * Add Product Image Gallery block * remove support global styles * remove support global styles * Update the button CSS. * Remove customizations for the Single Product Details block * Update styles for the cart form. * update td style. * Update divs and CSS. * Use conventional input instead of the experimental InputControl * address CSS feedback * add support for the custom classname * remove save function * Remove unnecessary console.log from the Edit.tsx file * Remove block classname from block wrapper * Remove unnecessary WooCommerce tabs filter from the BlockTemplatesController * Remove attributes property from the block registration * Remove isExperimental flag for the Single Product Details block * Remove get_classes_and_styles_by_attributes method from SingleProductDetails block * Prevent Single Product Details block from apppearing in Pages or Posts * add second parameter to the subscribe function * Implement the new design and copy provided for the editor. * Make the notice compatible with dark themes. * Some additional CSS tweaks * adjust the padding for the input * wrap the Single Product Template in a div with the product class * Fix PHP Coding Standards warnings * improve logic and increase coverage of unit test * improve logic and increase coverage of unit test * fix test * format HTML * fix edge case * update @types/wordpress__data package * update placeholder, icon and description * update tsconfig * update block name * fix SCSS linter error * address feedback * create SingleProductTemplateCompatibility class * Add Hooks compatibility * remove not used file * remove not used files * Add compatibility layer for the Single Product template * fix check * implement Product meta template header * Product Price Block: Add support Single Product Template * fix missing import * add comment * return a value * improve comment * fix import * Add Product Meta block * wrap up default single product html * fix: related products and grouped products result woocommerce/woocommerce-blocks#8589 * remove classname * fix crash * update template --------- Co-authored-by: Alexandre Lara <allexandrelara@gmail.com> Co-authored-by: Patricia Hillebrandt <patriciahillebrandt@gmail.com> * Fix images width in the Single Product page * Remove the !important attribute from the Product Image Gallery block * fix sku block * improve layout * fix header and footer template parts declaration --------- Co-authored-by: Luigi <gigitux@gmail.com> Co-authored-by: Patricia Hillebrandt <patriciahillebrandt@gmail.com> |
||
---|---|---|
.. | ||
.github | ||
.sources | ||
.vscode | ||
.wordpress-org | ||
assets | ||
bin | ||
docs | ||
images | ||
packages | ||
patches | ||
patterns | ||
src | ||
storybook | ||
templates | ||
tests | ||
.distignore | ||
.editorconfig | ||
.env | ||
.eslintignore | ||
.eslintrc.js | ||
.gitattributes | ||
.gitignore | ||
.markdownlint.json | ||
.markdownlintignore | ||
.nvmrc | ||
.prettierignore | ||
.prettierrc.js | ||
.stylelintrc.json | ||
.wp-env.json | ||
LICENSE | ||
README.md | ||
babel.config.js | ||
checkstyle.xml | ||
composer.json | ||
composer.lock | ||
docker-compose.yml | ||
global.d.ts | ||
package-lock.json | ||
package.json | ||
phpcs.xml | ||
phpunit.xml.dist | ||
postcss.config.js | ||
readme.txt | ||
tsconfig.base.json | ||
tsconfig.json | ||
webpack.config.js | ||
woocommerce-gutenberg-products-block.php |
README.md
WooCommerce Blocks
This is the feature plugin for WooCommerce + Gutenberg. This plugin serves as a space to iterate and explore new Blocks and updates to existing blocks for WooCommerce, and how WooCommerce might work with the block editor.
Use this plugin if you want access to the bleeding edge of available blocks for WooCommerce. However, stable blocks are bundled into WooCommerce, and can be added from the "WooCommerce" section in the block inserter.
Table of Contents
- Documentation
- Installing the plugin version
- Installing the development version
- Getting started with block development
- Long-term vision
Documentation
To find out more about the blocks and how to use them, check out the documentation on WooCommerce.com.
If you want to see what we're working on for future versions, or want to help out, read on.
Code Documentation
- Blocks - Documentation for specific Blocks.
- Editor Components - Shared components used in WooCommerce blocks for the editor (Gutenberg) UI.
- WooCommerce Blocks Handbook - Documentation for designers and developers on how to extend or contribute to blocks, and how internal developers should handle new releases.
- WooCommerce Blocks Storybook - Contains a list and demo of components used in the plugin.
Installing the plugin version
We release a new version of WooCommerce Blocks onto WordPress.org every few weeks, which can be used as an easier way to preview the features.
Note: The plugin follows a policy of supporting the "L0" strategy for version support. What this means is that the plugin will require the most recent version of WordPress, and the most recent version of WooCommerce core at the time of a release. You can read more about this policy here.
- Make sure you have the latest available versions of WordPress and WooCommerce on your site.
- The plugin version is available on WordPress.org. Download the plugin version here.
- Activate the plugin.
Installing the development version
- Make sure you have the latest versions of WordPress and WooCommerce on your site.
- Get a copy of this plugin using the green "Clone or download" button on the right.
- Make sure you're using Node.js v16.
npm install
to install the dependencies.composer install
to install core dependencies.- To compile the code, run any of the following commands
npm run build
(production build).npm run dev
(development build).npm start
(development build + watching for changes).
- Activate the plugin.
The source code is in the assets/
folder and the compiled code is built into build/
.
Getting started with block development
Run through the "Writing Your First Block Type" tutorial for a quick course in block-building.
For deeper dive, try looking at the core blocks code, or see what components are available.
To begin contributing to the WooCommerce Blocks plugin, see our getting started guide and developer handbook.
Other useful docs to explore:
Long-term vision
WooCommerce Blocks are the easiest, most flexible way to build your store user interface and showcase your products.