Commit 00d0194186d for woocommerce
commit 00d0194186d2c5de25d4a589faa5de0cab9dcea1
Author: Albert Juhé Lluveras <contact@albertjuhe.com>
Date: Wed Aug 26 16:07:49 2026 +0200
Add support for text and background color styles in the Product Quantity block (#68040)
* Add changelog
* Add support for text and background color styles in the Product Quantity block
diff --git a/docs/block-development/reference/block-references.md b/docs/block-development/reference/block-references.md
index 3b771d040e6..6e51888ba05 100644
--- a/docs/block-development/reference/block-references.md
+++ b/docs/block-development/reference/block-references.md
@@ -262,7 +262,7 @@ Display an input field customers can use to select the number of products to add
- **Name:** woocommerce/add-to-cart-with-options-quantity-selector
- **Category:** woocommerce-product-elements
- **Ancestor:** woocommerce/add-to-cart-with-options
-- **Supports:** interactivity
+- **Supports:** color (background, text), interactivity
## Variation Description (Beta) - woocommerce/add-to-cart-with-options-variation-description
diff --git a/plugins/woocommerce/changelog/add-quantity-selector-background-color b/plugins/woocommerce/changelog/add-quantity-selector-background-color
new file mode 100644
index 00000000000..3a82ab3efd8
--- /dev/null
+++ b/plugins/woocommerce/changelog/add-quantity-selector-background-color
@@ -0,0 +1,4 @@
+Significance: minor
+Type: add
+
+Add support for text and background color styles in the Product Quantity block
diff --git a/plugins/woocommerce/client/blocks/assets/js/blocks/add-to-cart-with-options/quantity-selector/block.json b/plugins/woocommerce/client/blocks/assets/js/blocks/add-to-cart-with-options/quantity-selector/block.json
index 9c7439f4a8e..3a20af53589 100644
--- a/plugins/woocommerce/client/blocks/assets/js/blocks/add-to-cart-with-options/quantity-selector/block.json
+++ b/plugins/woocommerce/client/blocks/assets/js/blocks/add-to-cart-with-options/quantity-selector/block.json
@@ -10,12 +10,16 @@
"apiVersion": 3,
"supports": {
"interactivity": true,
+ "color": {
+ "background": true,
+ "text": true
+ },
"__experimentalBorder": {
"radius": true
}
},
"selectors": {
- "border": ".wp-block-woocommerce-add-to-cart-with-options-quantity-selector, .wc-block-add-to-cart-with-options-grouped-product-item-selector .wc-block-components-quantity-selector"
+ "root": ".wp-block-woocommerce-add-to-cart-with-options-quantity-selector, .wc-block-add-to-cart-with-options-grouped-product-item-selector .wc-block-components-quantity-selector"
},
"$schema": "https://schemas.wp.org/trunk/block.json",
"viewScriptModule": "woocommerce/add-to-cart-with-options-quantity-selector"