From 8b0614bf88061807230f8c460ccdfcc28f4b1a61 Mon Sep 17 00:00:00 2001 From: github-actions Date: Mon, 6 Nov 2023 16:30:17 +0000 Subject: [PATCH 01/20] Empty commit for release pull request From f0a5e4cf93edcac0102c088a1dde66b49f3525bd Mon Sep 17 00:00:00 2001 From: github-actions Date: Tue, 7 Nov 2023 17:01:03 +0000 Subject: [PATCH 02/20] Empty commit for release pull request From 890f480c13a96bf93fc63e215a4b67974ce30c4c Mon Sep 17 00:00:00 2001 From: github-actions Date: Wed, 8 Nov 2023 08:05:44 +0000 Subject: [PATCH 03/20] Empty commit for release pull request From cbf3a13339eca8a63b8023a74181e64b56824d26 Mon Sep 17 00:00:00 2001 From: github-actions Date: Thu, 9 Nov 2023 11:53:58 +0000 Subject: [PATCH 04/20] Empty commit for release pull request From a0df00faa267680363ae23b9a69ed99138d0a0ef Mon Sep 17 00:00:00 2001 From: Thomas Roberts <5656702+opr@users.noreply.github.com> Date: Thu, 9 Nov 2023 11:34:17 +0000 Subject: [PATCH 05/20] Update Jetpack WooCommerce Analytics module integration to check for changed template names (#11707) --- .../Services/JetpackWooCommerceAnalytics.php | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/src/Domain/Services/JetpackWooCommerceAnalytics.php b/src/Domain/Services/JetpackWooCommerceAnalytics.php index 0908813b64e..4b0e320a3db 100644 --- a/src/Domain/Services/JetpackWooCommerceAnalytics.php +++ b/src/Domain/Services/JetpackWooCommerceAnalytics.php @@ -249,16 +249,16 @@ public function get_cart_checkout_info() { $checkout_template = null; $cart_template_id = null; $checkout_template_id = null; - $templates = $this->block_templates_controller->get_block_templates( array( 'cart', 'checkout' ) ); + $templates = $this->block_templates_controller->get_block_templates( array( 'cart', 'checkout', 'page-checkout', 'page-cart' ) ); $guest_checkout = ucfirst( get_option( 'woocommerce_enable_guest_checkout', 'No' ) ); $create_account = ucfirst( get_option( 'woocommerce_enable_signup_and_login_from_checkout', 'No' ) ); foreach ( $templates as $template ) { - if ( 'cart' === $template->slug ) { + if ( 'cart' === $template->slug || 'page-cart' === $template->slug ) { $cart_template_id = ( $template->id ); continue; } - if ( 'checkout' === $template->slug ) { + if ( 'checkout' === $template->slug || 'page-checkout' === $template->slug ) { $checkout_template_id = ( $template->id ); } } @@ -274,6 +274,16 @@ public function get_cart_checkout_info() { $checkout_template = get_block_template( $checkout_template_id ); } + // Something failed with the template retrieval, return early with 0 values rather than let a warning appear. + if ( ! $cart_template || ! $checkout_template ) { + return array( + 'cart_page_contains_cart_block' => 0, + 'cart_page_contains_cart_shortcode' => 0, + 'checkout_page_contains_checkout_block' => 0, + 'checkout_page_contains_checkout_shortcode' => 0, + ); + } + // Update the info transient with data we got from the templates, if the site isn't using WC Blocks we // won't be doing this so no concern about overwriting. // Sites that load this code will be loading it on a page using the relevant block, but we still need to check From d8db2cf0bef878e5ec3bf8ed01973b78c647dac7 Mon Sep 17 00:00:00 2001 From: Thomas Roberts Date: Thu, 9 Nov 2023 12:24:15 +0000 Subject: [PATCH 06/20] Bump versions to 11.4.6 --- composer.json | 2 +- package-lock.json | 4 ++-- package.json | 2 +- readme.txt | 8 +++++++- src/Package.php | 2 +- woocommerce-gutenberg-products-block.php | 2 +- 6 files changed, 13 insertions(+), 7 deletions(-) diff --git a/composer.json b/composer.json index 294b2621c35..d2e37bea593 100644 --- a/composer.json +++ b/composer.json @@ -3,7 +3,7 @@ "description": "WooCommerce blocks for the Gutenberg editor.", "homepage": "https://woocommerce.com/", "type": "wordpress-plugin", - "version": "11.4.5", + "version": "11.4.6", "keywords": [ "gutenberg", "woocommerce", diff --git a/package-lock.json b/package-lock.json index fa182ec177c..02e8b92d868 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "@woocommerce/block-library", - "version": "11.4.5", + "version": "11.4.6", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "@woocommerce/block-library", - "version": "11.4.5", + "version": "11.4.6", "hasInstallScript": true, "license": "GPL-3.0+", "dependencies": { diff --git a/package.json b/package.json index fd54b5f6c20..d205a924471 100644 --- a/package.json +++ b/package.json @@ -2,7 +2,7 @@ "name": "@woocommerce/block-library", "title": "WooCommerce Blocks", "author": "Automattic", - "version": "11.4.5", + "version": "11.4.6", "description": "WooCommerce blocks for the Gutenberg editor.", "homepage": "https://github.com/woocommerce/woocommerce-gutenberg-products-block/", "keywords": [ diff --git a/readme.txt b/readme.txt index 6d50f1030ae..5c814bfec47 100644 --- a/readme.txt +++ b/readme.txt @@ -4,7 +4,7 @@ Tags: gutenberg, woocommerce, woo commerce, products, blocks, woocommerce blocks Requires at least: 6.3.2 Tested up to: 6.3.2 Requires PHP: 7.4 -Stable tag: 11.4.5 +Stable tag: 11.4.6 License: GPLv3 License URI: https://www.gnu.org/licenses/gpl-3.0.html @@ -81,6 +81,12 @@ Release and roadmap notes available on the [WooCommerce Developers Blog](https:/ == Changelog == += 11.4.6 - 2023-11-09 = + +#### Bug Fixes + +- Prevent PHP warnings when using Jetpack WooCommerce Analytics module. [#11707](https://github.com/woocommerce/woocommerce-blocks/pull/11707) + = 11.4.5 - 2023-11-07 = #### Bug Fixes diff --git a/src/Package.php b/src/Package.php index 66d9ff438eb..7ed705e2e13 100644 --- a/src/Package.php +++ b/src/Package.php @@ -109,7 +109,7 @@ public static function container( $reset = false ) { NewPackage::class, function ( $container ) { // leave for automated version bumping. - $version = '11.4.5'; + $version = '11.4.6'; return new NewPackage( $version, dirname( __DIR__ ), diff --git a/woocommerce-gutenberg-products-block.php b/woocommerce-gutenberg-products-block.php index 04e9105adb7..72f3df3dbe1 100644 --- a/woocommerce-gutenberg-products-block.php +++ b/woocommerce-gutenberg-products-block.php @@ -3,7 +3,7 @@ * Plugin Name: WooCommerce Blocks * Plugin URI: https://github.com/woocommerce/woocommerce-gutenberg-products-block * Description: WooCommerce blocks for the Gutenberg editor. - * Version: 11.4.5 + * Version: 11.4.6 * Author: Automattic * Author URI: https://woocommerce.com * Text Domain: woo-gutenberg-products-block From 295cf275be1047024c13aeda630aac12d7cb0c26 Mon Sep 17 00:00:00 2001 From: Thomas Roberts Date: Thu, 9 Nov 2023 12:37:25 +0000 Subject: [PATCH 07/20] Add testing notes --- docs/internal-developers/testing/releases/1146.md | 13 +++++++++++++ docs/internal-developers/testing/releases/README.md | 1 + 2 files changed, 14 insertions(+) create mode 100644 docs/internal-developers/testing/releases/1146.md diff --git a/docs/internal-developers/testing/releases/1146.md b/docs/internal-developers/testing/releases/1146.md new file mode 100644 index 00000000000..cb773652d23 --- /dev/null +++ b/docs/internal-developers/testing/releases/1146.md @@ -0,0 +1,13 @@ +# Testing notes and ZIP for release 11.4.6 + +Zip file for testing: [woocommerce-gutenberg-products-block.zip](https://github.com/woocommerce/woocommerce-blocks/files/13308120/woocommerce-gutenberg-products-block.zip) + +## WooCommerce Core + +### Bug Fixes + +#### Update Jetpack WooCommerce Analytics module integration to check for changed template names ([#11707](https://github.com/woocommerce/woocommerce-blocks/pull/11707)) + +1. Enable Jetpack and ensure the WooCommerce Analytics module is set up and enabled. +2. Install [Query Monitor](https://wordpress.org/plugins/query-monitor/). +3. Go to the Cart and Checkout blocks and ensure no PHP warnings are logged. diff --git a/docs/internal-developers/testing/releases/README.md b/docs/internal-developers/testing/releases/README.md index 07d10eca63a..2ab10b0a142 100644 --- a/docs/internal-developers/testing/releases/README.md +++ b/docs/internal-developers/testing/releases/README.md @@ -187,6 +187,7 @@ Every release includes specific testing instructions for new features and bug fi - [11.4.3](./1143.md) - [11.4.4](./1144.md) - [11.4.5](./1145.md) + - [11.4.6](./1146.md) From 3280e3435482a0478afa0e13bb7ce64dc80eaedd Mon Sep 17 00:00:00 2001 From: Thomas Roberts Date: Thu, 9 Nov 2023 13:03:28 +0000 Subject: [PATCH 08/20] Update testing zip --- docs/internal-developers/testing/releases/1146.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/internal-developers/testing/releases/1146.md b/docs/internal-developers/testing/releases/1146.md index cb773652d23..273c22ba273 100644 --- a/docs/internal-developers/testing/releases/1146.md +++ b/docs/internal-developers/testing/releases/1146.md @@ -1,6 +1,6 @@ # Testing notes and ZIP for release 11.4.6 -Zip file for testing: [woocommerce-gutenberg-products-block.zip](https://github.com/woocommerce/woocommerce-blocks/files/13308120/woocommerce-gutenberg-products-block.zip) +Zip file for testing: [woocommerce-gutenberg-products-block.zip](https://github.com/woocommerce/woocommerce-blocks/files/13308368/woocommerce-gutenberg-products-block.zip) ## WooCommerce Core From 61b49368abb7b01f3c832787b4b2e9de091ee25d Mon Sep 17 00:00:00 2001 From: Saad Tarhi Date: Wed, 8 Nov 2023 16:35:45 +0100 Subject: [PATCH 09/20] Skip template related E2E tests (#11700) --- tests/e2e/tests/templates/cart-template.block_theme.spec.ts | 4 +++- .../e2e/tests/templates/checkout-template.block_theme.spec.ts | 4 +++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/tests/e2e/tests/templates/cart-template.block_theme.spec.ts b/tests/e2e/tests/templates/cart-template.block_theme.spec.ts index b713f3cdc3b..9c5fbba8d83 100644 --- a/tests/e2e/tests/templates/cart-template.block_theme.spec.ts +++ b/tests/e2e/tests/templates/cart-template.block_theme.spec.ts @@ -26,7 +26,9 @@ test.describe( 'Test the cart template', async () => { ).toBeVisible(); } ); - test( 'Template can be accessed from the page editor', async ( { + // Remove the skip once this ticket is resolved: https://github.com/woocommerce/woocommerce-blocks/issues/11671 + // eslint-disable-next-line playwright/no-skipped-test + test.skip( 'Template can be accessed from the page editor', async ( { admin, editor, page, diff --git a/tests/e2e/tests/templates/checkout-template.block_theme.spec.ts b/tests/e2e/tests/templates/checkout-template.block_theme.spec.ts index 32890422726..262b4f86d93 100644 --- a/tests/e2e/tests/templates/checkout-template.block_theme.spec.ts +++ b/tests/e2e/tests/templates/checkout-template.block_theme.spec.ts @@ -26,7 +26,9 @@ test.describe( 'Test the checkout template', async () => { ).toBeVisible(); } ); - test( 'Template can be accessed from the page editor', async ( { + // Remove the skip once this ticket is resolved: https://github.com/woocommerce/woocommerce-blocks/issues/11671 + // eslint-disable-next-line playwright/no-skipped-test + test.skip( 'Template can be accessed from the page editor', async ( { admin, editor, page, From 207660fdd90bfdb87e30f195789a184cf3b0941a Mon Sep 17 00:00:00 2001 From: github-actions Date: Thu, 9 Nov 2023 18:43:57 +0000 Subject: [PATCH 10/20] Empty commit for release pull request From 2cc0ae0e2b4d9577a7296b5895d8d2b88d20f8c0 Mon Sep 17 00:00:00 2001 From: Mike Jolley Date: Thu, 9 Nov 2023 16:25:28 +0000 Subject: [PATCH 11/20] Fix address block invalidations in the editor and address card display in Firefox (#11714) * Add checks to see if getCartData finished before rendering address * Prevent block error due to excessive updates of customValidation * Do not condense address in admin and handle phone field * Add missing showPhoneField for billing --------- Co-authored-by: Thomas Roberts --- .../address-form/address-form.tsx | 9 ++++--- .../cart-checkout/address-form/types.ts | 2 -- .../js/blocks/checkout/address-card/index.tsx | 4 ++- .../checkout-billing-address-block/block.tsx | 22 +++++++++++----- .../customer-address.tsx | 3 ++- .../checkout-shipping-address-block/block.tsx | 21 ++++++++++++---- .../customer-address.tsx | 14 ++++++++--- .../checkout/components/text-input/types.ts | 2 ++ .../text-input/validated-text-input.tsx | 25 +++++++++++-------- 9 files changed, 69 insertions(+), 33 deletions(-) diff --git a/assets/js/base/components/cart-checkout/address-form/address-form.tsx b/assets/js/base/components/cart-checkout/address-form/address-form.tsx index 3f1a0b3b66c..481b6b1a46e 100644 --- a/assets/js/base/components/cart-checkout/address-form/address-form.tsx +++ b/assets/js/base/components/cart-checkout/address-form/address-form.tsx @@ -15,7 +15,7 @@ import { ShippingStateInput, } from '@woocommerce/base-components/state-input'; import { useEffect, useMemo, useRef } from '@wordpress/element'; -import { withInstanceId } from '@wordpress/compose'; +import { useInstanceId } from '@wordpress/compose'; import { useShallowEqual } from '@woocommerce/base-hooks'; import { defaultAddressFields } from '@woocommerce/settings'; import isShallowEqual from '@wordpress/is-shallow-equal'; @@ -44,11 +44,12 @@ const AddressForm = ( { id = '', fields = defaultFields, fieldConfig = {} as FieldConfig, - instanceId, onChange, type = 'shipping', values, }: AddressFormProps ): JSX.Element => { + const instanceId = useInstanceId( AddressForm ); + // Track incoming props. const currentFields = useShallowEqual( fields ); const currentFieldConfig = useShallowEqual( fieldConfig ); @@ -99,7 +100,7 @@ const AddressForm = ( { fieldsRef.current?.postcode?.revalidate(); }, [ currentCountry ] ); - id = id || instanceId; + id = id || `${ instanceId }`; return (
@@ -206,4 +207,4 @@ const AddressForm = ( { ); }; -export default withInstanceId( AddressForm ); +export default AddressForm; diff --git a/assets/js/base/components/cart-checkout/address-form/types.ts b/assets/js/base/components/cart-checkout/address-form/types.ts index ece3ef7e79f..b9187efba05 100644 --- a/assets/js/base/components/cart-checkout/address-form/types.ts +++ b/assets/js/base/components/cart-checkout/address-form/types.ts @@ -26,8 +26,6 @@ export type AddressFormFields = { export interface AddressFormProps { // Id for component. id?: string; - // Unique id for form. - instanceId: string; // Type of form (billing or shipping). type?: AddressType; // Array of fields in form. diff --git a/assets/js/blocks/checkout/address-card/index.tsx b/assets/js/blocks/checkout/address-card/index.tsx index 8c7621de93f..363b4f2c5c0 100644 --- a/assets/js/blocks/checkout/address-card/index.tsx +++ b/assets/js/blocks/checkout/address-card/index.tsx @@ -17,10 +17,12 @@ const AddressCard = ( { address, onEdit, target, + showPhoneField, }: { address: CartShippingAddress | CartBillingAddress; onEdit: () => void; target: string; + showPhoneField: boolean; } ): JSX.Element | null => { return (
@@ -44,7 +46,7 @@ const AddressCard = ( { { field } ) ) }
- { address.phone ? ( + { address.phone && showPhoneField ? (
{ + const store = select( CART_STORE_KEY ); + return { + cartDataLoaded: store.hasFinishedResolution( 'getCartData' ), + }; + } ); return ( <> - + { cartDataLoaded ? ( + + ) : null } ); diff --git a/assets/js/blocks/checkout/inner-blocks/checkout-billing-address-block/customer-address.tsx b/assets/js/blocks/checkout/inner-blocks/checkout-billing-address-block/customer-address.tsx index e4dafcf40a1..4916b90bc6f 100644 --- a/assets/js/blocks/checkout/inner-blocks/checkout-billing-address-block/customer-address.tsx +++ b/assets/js/blocks/checkout/inner-blocks/checkout-billing-address-block/customer-address.tsx @@ -97,9 +97,10 @@ const CustomerAddress = ( { onEdit={ () => { setEditing( true ); } } + showPhoneField={ showPhoneField } /> ), - [ billingAddress ] + [ billingAddress, showPhoneField ] ); const renderAddressFormComponent = useCallback( diff --git a/assets/js/blocks/checkout/inner-blocks/checkout-shipping-address-block/block.tsx b/assets/js/blocks/checkout/inner-blocks/checkout-shipping-address-block/block.tsx index 3b8dc12871f..1ee5785fba5 100644 --- a/assets/js/blocks/checkout/inner-blocks/checkout-shipping-address-block/block.tsx +++ b/assets/js/blocks/checkout/inner-blocks/checkout-shipping-address-block/block.tsx @@ -19,6 +19,8 @@ import type { AddressField, AddressFields, } from '@woocommerce/settings'; +import { useSelect } from '@wordpress/data'; +import { CART_STORE_KEY } from '@woocommerce/block-data'; /** * Internal dependencies @@ -96,15 +98,24 @@ const Block = ( { ( shippingAddress.first_name || shippingAddress.last_name ) ); + const { cartDataLoaded } = useSelect( ( select ) => { + const store = select( CART_STORE_KEY ); + return { + cartDataLoaded: store.hasFinishedResolution( 'getCartData' ), + }; + } ); + return ( <> - + { cartDataLoaded ? ( + + ) : null } { hasAddress && ( { @@ -103,9 +108,10 @@ const CustomerAddress = ( { onEdit={ () => { setEditing( true ); } } + showPhoneField={ showPhoneField } /> ), - [ shippingAddress ] + [ shippingAddress, showPhoneField ] ); const renderAddressFormComponent = useCallback( @@ -147,9 +153,11 @@ const CustomerAddress = ( { dispatchCheckoutEvent, onChangeAddress, requirePhoneField, + setBillingPhone, setShippingPhone, shippingAddress, showPhoneField, + useShippingAsBilling, ] ); diff --git a/packages/checkout/components/text-input/types.ts b/packages/checkout/components/text-input/types.ts index 263ff18cd4d..24e5d5587d1 100644 --- a/packages/checkout/components/text-input/types.ts +++ b/packages/checkout/components/text-input/types.ts @@ -26,6 +26,8 @@ export interface ValidatedTextInputProps label?: string | undefined; // Field value. value: string; + // Other sibling fields that should be validated together. + values: string[]; // If true, validation errors will be shown. showError?: boolean; // Error message to display alongside the field regardless of validation. diff --git a/packages/checkout/components/text-input/validated-text-input.tsx b/packages/checkout/components/text-input/validated-text-input.tsx index d1d4fd0d575..29295adaaa0 100644 --- a/packages/checkout/components/text-input/validated-text-input.tsx +++ b/packages/checkout/components/text-input/validated-text-input.tsx @@ -51,7 +51,7 @@ const ValidatedTextInput = forwardRef< customFormatter = ( newValue: string ) => newValue, label, validateOnMount = true, - instanceId: preferredInstanceId, + instanceId: preferredInstanceId = '', ...rest }, forwardedRef @@ -80,6 +80,14 @@ const ValidatedTextInput = forwardRef< clearValidationError, } = useDispatch( VALIDATION_STORE_KEY ); + // Ref for validation callback. + const customValidationRef = useRef( customValidation ); + + // Update ref when validation callback changes. + useEffect( () => { + customValidationRef.current = customValidation; + }, [ customValidation ] ); + const { validationError, validationErrorId } = useSelect( ( select ) => { const store = select( VALIDATION_STORE_KEY ); @@ -105,7 +113,7 @@ const ValidatedTextInput = forwardRef< if ( inputObject.checkValidity() && - customValidation( inputObject ) + customValidationRef.current( inputObject ) ) { clearValidationError( errorIdString ); return; @@ -120,13 +128,7 @@ const ValidatedTextInput = forwardRef< }, } ); }, - [ - clearValidationError, - customValidation, - errorIdString, - setValidationErrors, - label, - ] + [ clearValidationError, errorIdString, setValidationErrors, label ] ); // Allows parent to trigger revalidation. @@ -184,6 +186,9 @@ const ValidatedTextInput = forwardRef< if ( ! isPristine ) { return; } + + setIsPristine( false ); + if ( focusOnMount ) { inputRef.current?.focus(); } @@ -192,8 +197,6 @@ const ValidatedTextInput = forwardRef< if ( validateOnMount || ! focusOnMount ) { validateInput( true ); } - - setIsPristine( false ); }, [ validateOnMount, focusOnMount, From 4492479c5edf04a1868a8e7d94beda40b83c42b1 Mon Sep 17 00:00:00 2001 From: Saad Tarhi Date: Thu, 9 Nov 2023 19:58:11 +0100 Subject: [PATCH 12/20] Add changelog in "readme.txt" --- readme.txt | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/readme.txt b/readme.txt index 5c814bfec47..358d6ad77d7 100644 --- a/readme.txt +++ b/readme.txt @@ -81,6 +81,12 @@ Release and roadmap notes available on the [WooCommerce Developers Blog](https:/ == Changelog == += 11.4.7 - 2023-11-09 = + +#### Bug Fixes + +- Fixed address components in Firefox, and editing of address form in the editor. [#11714](https://github.com/woocommerce/woocommerce-blocks/pull/11714) + = 11.4.6 - 2023-11-09 = #### Bug Fixes From 3e8a0392e1a1903f6308651b5ac28e428f908a68 Mon Sep 17 00:00:00 2001 From: Saad Tarhi Date: Thu, 9 Nov 2023 20:02:36 +0100 Subject: [PATCH 13/20] Run change version npm script --- composer.json | 2 +- package-lock.json | 4 ++-- package.json | 2 +- readme.txt | 2 +- src/Package.php | 2 +- woocommerce-gutenberg-products-block.php | 2 +- 6 files changed, 7 insertions(+), 7 deletions(-) diff --git a/composer.json b/composer.json index d2e37bea593..7f4806a8bad 100644 --- a/composer.json +++ b/composer.json @@ -3,7 +3,7 @@ "description": "WooCommerce blocks for the Gutenberg editor.", "homepage": "https://woocommerce.com/", "type": "wordpress-plugin", - "version": "11.4.6", + "version": "11.4.7", "keywords": [ "gutenberg", "woocommerce", diff --git a/package-lock.json b/package-lock.json index 02e8b92d868..7e9d5544682 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "@woocommerce/block-library", - "version": "11.4.6", + "version": "11.4.7", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "@woocommerce/block-library", - "version": "11.4.6", + "version": "11.4.7", "hasInstallScript": true, "license": "GPL-3.0+", "dependencies": { diff --git a/package.json b/package.json index d205a924471..2e788e84753 100644 --- a/package.json +++ b/package.json @@ -2,7 +2,7 @@ "name": "@woocommerce/block-library", "title": "WooCommerce Blocks", "author": "Automattic", - "version": "11.4.6", + "version": "11.4.7", "description": "WooCommerce blocks for the Gutenberg editor.", "homepage": "https://github.com/woocommerce/woocommerce-gutenberg-products-block/", "keywords": [ diff --git a/readme.txt b/readme.txt index 358d6ad77d7..61c40eef635 100644 --- a/readme.txt +++ b/readme.txt @@ -4,7 +4,7 @@ Tags: gutenberg, woocommerce, woo commerce, products, blocks, woocommerce blocks Requires at least: 6.3.2 Tested up to: 6.3.2 Requires PHP: 7.4 -Stable tag: 11.4.6 +Stable tag: 11.4.7 License: GPLv3 License URI: https://www.gnu.org/licenses/gpl-3.0.html diff --git a/src/Package.php b/src/Package.php index 7ed705e2e13..5e3571adf50 100644 --- a/src/Package.php +++ b/src/Package.php @@ -109,7 +109,7 @@ public static function container( $reset = false ) { NewPackage::class, function ( $container ) { // leave for automated version bumping. - $version = '11.4.6'; + $version = '11.4.7'; return new NewPackage( $version, dirname( __DIR__ ), diff --git a/woocommerce-gutenberg-products-block.php b/woocommerce-gutenberg-products-block.php index 72f3df3dbe1..30aed8cc731 100644 --- a/woocommerce-gutenberg-products-block.php +++ b/woocommerce-gutenberg-products-block.php @@ -3,7 +3,7 @@ * Plugin Name: WooCommerce Blocks * Plugin URI: https://github.com/woocommerce/woocommerce-gutenberg-products-block * Description: WooCommerce blocks for the Gutenberg editor. - * Version: 11.4.6 + * Version: 11.4.7 * Author: Automattic * Author URI: https://woocommerce.com * Text Domain: woo-gutenberg-products-block From 729182933d3f3b046fcb58fc5eb3eb820a274957 Mon Sep 17 00:00:00 2001 From: Saad Tarhi Date: Thu, 9 Nov 2023 20:13:43 +0100 Subject: [PATCH 14/20] Add testing notes --- .../testing/releases/1147.md | 24 +++++++++++++++++++ .../testing/releases/README.md | 1 + 2 files changed, 25 insertions(+) create mode 100644 docs/internal-developers/testing/releases/1147.md diff --git a/docs/internal-developers/testing/releases/1147.md b/docs/internal-developers/testing/releases/1147.md new file mode 100644 index 00000000000..a900c0729b1 --- /dev/null +++ b/docs/internal-developers/testing/releases/1147.md @@ -0,0 +1,24 @@ +# Testing notes and ZIP for release 11.4.7 + +Zip file for testing: [woocommerce-gutenberg-products-block.zip](https://github.com/woocommerce/woocommerce-blocks/files/13311913/woocommerce-gutenberg-products-block.zip) + +## WooCommerce Core + +### Bug Fixes + +#### Fixed address components in Firefox, and editing of address form in the editor ([#11714](https://github.com/woocommerce/woocommerce-blocks/pull/11714)) + +1. Edit the checkout page +2. Address form should not be condensed +3. Toggle company/phone. Leave phone on. There should be no block errors. +4. Save changes and visit the checkout on the frontend (add something to cart if needed) +5. As a logged in user the address form should be condensed and phone should be visible. If no, fill out the form and place an order. +6. After placing the order go back to checkout and repeat the previous step. Phone should be visible in the condensed address component. +7. Go back to the editor and turn off the phone field. Save and go back to the frontend checkout. Ensure phone is hidden from the condensed address component. + +##### Firefox testing + +1. Add an item to the cart and go to checkout using Firefox +2. Fill out the form, then refresh the page. +3. The condensed address component is shown. +4. Edit the address. Ensure fields are populated with correct values. diff --git a/docs/internal-developers/testing/releases/README.md b/docs/internal-developers/testing/releases/README.md index 2ab10b0a142..68c4c9a4896 100644 --- a/docs/internal-developers/testing/releases/README.md +++ b/docs/internal-developers/testing/releases/README.md @@ -188,6 +188,7 @@ Every release includes specific testing instructions for new features and bug fi - [11.4.4](./1144.md) - [11.4.5](./1145.md) - [11.4.6](./1146.md) + - [11.4.7](./1147.md) From 8c3eab2e9a3f1bf2c70613991d9e55c43c2a5c8c Mon Sep 17 00:00:00 2001 From: github-actions Date: Fri, 10 Nov 2023 20:54:31 +0000 Subject: [PATCH 15/20] Empty commit for release pull request From a327e1d6ffa6f7ef11518d97f0e335a5a1a9da10 Mon Sep 17 00:00:00 2001 From: Saad Tarhi Date: Fri, 10 Nov 2023 22:00:30 +0100 Subject: [PATCH 16/20] Add changelog in "readme.txt" --- readme.txt | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/readme.txt b/readme.txt index 61c40eef635..987341faf60 100644 --- a/readme.txt +++ b/readme.txt @@ -81,6 +81,12 @@ Release and roadmap notes available on the [WooCommerce Developers Blog](https:/ == Changelog == += 11.4.8 - 2023-11-10 = + +#### Bug Fixes + +- Ensure that incompatible notices are displayed in Safari. [11736](https://github.com/woocommerce/woocommerce-blocks/pull/11736) + = 11.4.7 - 2023-11-09 = #### Bug Fixes From 37531f9b29f0d7c84c668caadb44f6eab0aab186 Mon Sep 17 00:00:00 2001 From: Saad Tarhi Date: Fri, 10 Nov 2023 22:02:49 +0100 Subject: [PATCH 17/20] Add version numbers --- composer.json | 2 +- package-lock.json | 4 ++-- package.json | 2 +- readme.txt | 2 +- src/Package.php | 2 +- woocommerce-gutenberg-products-block.php | 2 +- 6 files changed, 7 insertions(+), 7 deletions(-) diff --git a/composer.json b/composer.json index 7f4806a8bad..d99c1077ed1 100644 --- a/composer.json +++ b/composer.json @@ -3,7 +3,7 @@ "description": "WooCommerce blocks for the Gutenberg editor.", "homepage": "https://woocommerce.com/", "type": "wordpress-plugin", - "version": "11.4.7", + "version": "11.4.8", "keywords": [ "gutenberg", "woocommerce", diff --git a/package-lock.json b/package-lock.json index 7e9d5544682..e1e309486b6 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "@woocommerce/block-library", - "version": "11.4.7", + "version": "11.4.8", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "@woocommerce/block-library", - "version": "11.4.7", + "version": "11.4.8", "hasInstallScript": true, "license": "GPL-3.0+", "dependencies": { diff --git a/package.json b/package.json index 2e788e84753..e5ae66c8ce5 100644 --- a/package.json +++ b/package.json @@ -2,7 +2,7 @@ "name": "@woocommerce/block-library", "title": "WooCommerce Blocks", "author": "Automattic", - "version": "11.4.7", + "version": "11.4.8", "description": "WooCommerce blocks for the Gutenberg editor.", "homepage": "https://github.com/woocommerce/woocommerce-gutenberg-products-block/", "keywords": [ diff --git a/readme.txt b/readme.txt index 987341faf60..e4a251d3e3a 100644 --- a/readme.txt +++ b/readme.txt @@ -4,7 +4,7 @@ Tags: gutenberg, woocommerce, woo commerce, products, blocks, woocommerce blocks Requires at least: 6.3.2 Tested up to: 6.3.2 Requires PHP: 7.4 -Stable tag: 11.4.7 +Stable tag: 11.4.8 License: GPLv3 License URI: https://www.gnu.org/licenses/gpl-3.0.html diff --git a/src/Package.php b/src/Package.php index 5e3571adf50..e5110549243 100644 --- a/src/Package.php +++ b/src/Package.php @@ -109,7 +109,7 @@ public static function container( $reset = false ) { NewPackage::class, function ( $container ) { // leave for automated version bumping. - $version = '11.4.7'; + $version = '11.4.8'; return new NewPackage( $version, dirname( __DIR__ ), diff --git a/woocommerce-gutenberg-products-block.php b/woocommerce-gutenberg-products-block.php index 30aed8cc731..f30790ecf23 100644 --- a/woocommerce-gutenberg-products-block.php +++ b/woocommerce-gutenberg-products-block.php @@ -3,7 +3,7 @@ * Plugin Name: WooCommerce Blocks * Plugin URI: https://github.com/woocommerce/woocommerce-gutenberg-products-block * Description: WooCommerce blocks for the Gutenberg editor. - * Version: 11.4.7 + * Version: 11.4.8 * Author: Automattic * Author URI: https://woocommerce.com * Text Domain: woo-gutenberg-products-block From e12c25f46d80567b80583378199c5048157dda08 Mon Sep 17 00:00:00 2001 From: Niels Lange Date: Sat, 11 Nov 2023 03:52:50 +0700 Subject: [PATCH 18/20] Ensure that incompatible notices are displayed in Safari. (#11736) --- .../incompatible-extension-notice/editor.scss | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/assets/js/editor-components/incompatible-extension-notice/editor.scss b/assets/js/editor-components/incompatible-extension-notice/editor.scss index b506493b48d..1b181517407 100644 --- a/assets/js/editor-components/incompatible-extension-notice/editor.scss +++ b/assets/js/editor-components/incompatible-extension-notice/editor.scss @@ -18,11 +18,11 @@ width: 24px; height: 24px; margin-right: 6px; - min-width: max-content; + min-width: 24px; // Ensure that notice is visible in Safari. See https://github.com/woocommerce/woocommerce-blocks/issues/11734 } } ul { - margin: 0 0 1em 1.5em; + margin: 0 0 1em 1.2em; padding: 0; list-style: disc outside; } From 99e419f281d9430619a009c8edca6bbe1aaf9a0f Mon Sep 17 00:00:00 2001 From: Saad Tarhi Date: Fri, 10 Nov 2023 22:18:42 +0100 Subject: [PATCH 19/20] Add the testing docs --- .../testing/releases/1148.md | 29 +++++++++++++++++++ .../testing/releases/README.md | 1 + 2 files changed, 30 insertions(+) create mode 100644 docs/internal-developers/testing/releases/1148.md diff --git a/docs/internal-developers/testing/releases/1148.md b/docs/internal-developers/testing/releases/1148.md new file mode 100644 index 00000000000..df59e9580ca --- /dev/null +++ b/docs/internal-developers/testing/releases/1148.md @@ -0,0 +1,29 @@ +# Testing notes and ZIP for release 11.4.7 + +Zip file for testing: [woocommerce-gutenberg-products-block.zip](https://github.com/woocommerce/woocommerce-blocks/files/13323235/woocommerce-gutenberg-products-block.zip) + +## WooCommerce Core + +### Bug Fixes + +#### Ensure that incompatible notices are displayed in Safari ([11736](https://github.com/woocommerce/woocommerce-blocks/pull/11736)) + +1. Install and activate [helper-plugin-1.zip](https://github.com/woocommerce/woocommerce-blocks/files/12701036/helper-plugin-1.zip) +2. Create a test page and add the Cart block. +3. Create a test page and add the Checkout block. +4. Open both test pages using Safari. +5. Click on the Cart block resp. the Checkout block and verify that the incompatible extension notice is visible. +6. Repeat the previous step using Chrome, Firefox and Opera. + + + + + + +
Before: +

+Screenshot 2023-11-10 at 21 43 01 +
After: +

+Screenshot 2023-11-10 at 21 42 18 +
diff --git a/docs/internal-developers/testing/releases/README.md b/docs/internal-developers/testing/releases/README.md index 68c4c9a4896..b02d627b51a 100644 --- a/docs/internal-developers/testing/releases/README.md +++ b/docs/internal-developers/testing/releases/README.md @@ -189,6 +189,7 @@ Every release includes specific testing instructions for new features and bug fi - [11.4.5](./1145.md) - [11.4.6](./1146.md) - [11.4.7](./1147.md) + - [11.4.8](./1148.md) From fb7616abbedd129d57008978b6e689b6488e8470 Mon Sep 17 00:00:00 2001 From: Saad Tarhi Date: Fri, 10 Nov 2023 23:25:27 +0100 Subject: [PATCH 20/20] Update testing notes title of 11.4.8 --- docs/internal-developers/testing/releases/1148.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/internal-developers/testing/releases/1148.md b/docs/internal-developers/testing/releases/1148.md index df59e9580ca..7385318f874 100644 --- a/docs/internal-developers/testing/releases/1148.md +++ b/docs/internal-developers/testing/releases/1148.md @@ -1,4 +1,4 @@ -# Testing notes and ZIP for release 11.4.7 +# Testing notes and ZIP for release 11.4.8 Zip file for testing: [woocommerce-gutenberg-products-block.zip](https://github.com/woocommerce/woocommerce-blocks/files/13323235/woocommerce-gutenberg-products-block.zip)