Cherry pick 50592 into release/9.2 (#50602)

* Fixed the order of elements on the Order Confirmation screen (#50592)

* Fixed the order of elements on the Order Confirmation screen

* Added changelog

* Linting.

* Add wrapper around account notices

---------

Co-authored-by: Mike Jolley <mike.jolley@me.com>

* Prep for cherry pick 50592

---------

Co-authored-by: Paulo Arromba <17236129+wavvves@users.noreply.github.com>
Co-authored-by: Mike Jolley <mike.jolley@me.com>
Co-authored-by: WooCommerce Bot <no-reply@woocommerce.com>
This commit is contained in:
github-actions[bot] 2024-08-13 09:59:29 -07:00 committed by GitHub
parent 58b59ff8e1
commit 8bd10b29ea
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 14 additions and 3 deletions

View File

@ -173,6 +173,7 @@ WooCommerce comes with some sample data you can use to see how products look; im
**WooCommerce**
* Fix - Resolved an issue that caused the page title and content text to display in the incorrect order on the Order Confirmation page. [#50592](https://github.com/woocommerce/woocommerce/pull/50592)
* Fix - Customer Account - Maintain the size of the icon in smaller screens. [#50410](https://github.com/woocommerce/woocommerce/pull/50410)
* Fix - Accessibility: Prevent shipping losing focus when making selections during checkout. [#48370](https://github.com/woocommerce/woocommerce/pull/48370)
* Fix - Add aria-label to mini-cart button on first render to improve accessibility [#48329](https://github.com/woocommerce/woocommerce/pull/48329)

View File

@ -40,14 +40,24 @@ class Status extends AbstractOrderConfirmationBlock {
return '';
}
$additional_content = $this->render_account_notice( $order ) . $this->render_confirmation_notice( $order );
$account_notice = $this->render_account_notice( $order );
if ( $account_notice ) {
$block = sprintf(
'<div class="wc-block-order-confirmation-status-notices %1$s">%2$s</div>',
esc_attr( trim( $classname ) ),
$account_notice
) . $block;
}
$additional_content = $this->render_confirmation_notice( $order );
if ( $additional_content ) {
return sprintf(
$block = $block . sprintf(
'<div class="wc-block-order-confirmation-status-description %1$s">%2$s</div>',
esc_attr( trim( $classname ) ),
$additional_content
) . $block;
);
}
return $block;