Skip to content
This repository was archived by the owner on Feb 23, 2024. It is now read-only.

Commit 077a25d

Browse files
github-actions[bot]github-actionssenadirdanielwrobert
authored
Release: 9.4.3 (#8357)
* Empty commit for release pull request * update readme * Switch to select instead of resolveSelector (#8356) * Mini Cart block - Fix the drawer content height to allow checkout button to show. (#8351) * Add max-height to Mini Cart drawer. By giving the Mini Cart contents a max height with the -webkit-fill-available property, we can ensure that the browser chrome is accounted for on mobile devices. * Add `dvh` and keep `vh` as a fallback for height. By adding `dvh`, we also account for non-webkit mobile browsers that have the same hidden button issue. See #8351 (review) Keeping `vh` as a fallback, along with `-webkit-fill-available` gives us the widest range of support. * update readme with changelog * add testing steps * add pr links to readme * Bumping version strings to new version. --------- Co-authored-by: github-actions <[email protected]> Co-authored-by: Nadir Seghir <[email protected]> Co-authored-by: Daniel W. Robert <[email protected]>
1 parent 92911d1 commit 077a25d

File tree

8 files changed

+42
-13
lines changed

8 files changed

+42
-13
lines changed

assets/js/blocks/mini-cart/style.scss

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,8 @@
8888
.wp-block-woocommerce-mini-cart-contents {
8989
box-sizing: border-box;
9090
height: 100vh;
91+
height: 100dvh;
92+
max-height: -webkit-fill-available;
9193
padding: 0;
9294
justify-content: center;
9395
}
@@ -98,6 +100,8 @@
98100
.wp-block-woocommerce-empty-mini-cart-contents-block,
99101
.wp-block-woocommerce-filled-mini-cart-contents-block {
100102
height: 100vh;
103+
height: 100dvh;
104+
max-height: -webkit-fill-available;
101105
display: flex;
102106
flex-direction: column;
103107
}

assets/js/data/cart/actions.ts

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ import {
2222
import { ACTION_TYPES as types } from './action-types';
2323
import { apiFetchWithHeaders } from '../shared-controls';
2424
import { ReturnOrGeneratorYieldUnion } from '../mapped-types';
25-
import { CartDispatchFromMap, CartResolveSelectFromMap } from './index';
25+
import { CartDispatchFromMap, CartSelectFromMap } from './index';
2626

2727
// Thunks are functions that can be dispatched, similar to actions creators
2828
export * from './thunks';
@@ -183,7 +183,7 @@ export const shippingRatesBeingSelected = ( isResolving: boolean ) =>
183183
*/
184184
export const applyExtensionCartUpdate =
185185
( args: ExtensionCartUpdateArgs ) =>
186-
async ( { dispatch } ) => {
186+
async ( { dispatch }: { dispatch: CartDispatchFromMap } ) => {
187187
try {
188188
const { response } = await apiFetchWithHeaders( {
189189
path: '/wc/store/v1/cart/extensions',
@@ -214,7 +214,7 @@ export const applyExtensionCartUpdate =
214214
*/
215215
export const applyCoupon =
216216
( couponCode: string ) =>
217-
async ( { dispatch } ) => {
217+
async ( { dispatch }: { dispatch: CartDispatchFromMap } ) => {
218218
dispatch.receiveApplyingCoupon( couponCode );
219219
try {
220220
const { response } = await apiFetchWithHeaders( {
@@ -253,7 +253,7 @@ export const applyCoupon =
253253
*/
254254
export const removeCoupon =
255255
( couponCode: string ) =>
256-
async ( { dispatch } ) => {
256+
async ( { dispatch }: { dispatch: CartDispatchFromMap } ) => {
257257
dispatch.receiveRemovingCoupon( couponCode );
258258

259259
try {
@@ -296,7 +296,7 @@ export const removeCoupon =
296296
*/
297297
export const addItemToCart =
298298
( productId: number, quantity = 1 ) =>
299-
async ( { dispatch } ) => {
299+
async ( { dispatch }: { dispatch: CartDispatchFromMap } ) => {
300300
try {
301301
triggerAddingToCartEvent();
302302
const { response } = await apiFetchWithHeaders( {
@@ -378,12 +378,12 @@ export const changeCartItemQuantity =
378378
) =>
379379
async ( {
380380
dispatch,
381-
resolveSelect,
381+
select,
382382
}: {
383383
dispatch: CartDispatchFromMap;
384-
resolveSelect: CartResolveSelectFromMap;
384+
select: CartSelectFromMap;
385385
} ) => {
386-
const cartItem = await resolveSelect.getCartItem( cartItemKey );
386+
const cartItem = select.getCartItem( cartItemKey );
387387
if ( cartItem?.quantity === quantity ) {
388388
return;
389389
}
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
# Testing notes and ZIP for release 9.4.3
2+
3+
Zip file for testing: [woocommerce-gutenberg-products-block.zip](https://github.com/woocommerce/woocommerce-blocks/files/10567326/woocommerce-gutenberg-products-block.zip)
4+
5+
## Feature plugin and package inclusion in WooCommerce
6+
7+
### Mini Cart block - Fix the drawer content height to allow checkout button to show. ([8351](https://github.com/woocommerce/woocommerce-blocks/pull/8351))
8+
9+
1. Set up the Mini Cart in your global navigation, if you don't have it already.
10+
2. View the front end of your site from a mobile device (or Xcode Simulator).
11+
3. Add a product to your cart.
12+
4. Open the Mini Cart drawer.
13+
5. Confirm the checkout button is fully visible (see after screenshots above).
14+
15+
### Fix a bug in WordPress 5.9 in which changing quantity doesn't work inside Cart and Mini Cart blocks. ([8356](https://github.com/woocommerce/woocommerce-blocks/pull/8356))
16+
17+
1. In WordPress 5.9.x, go to Cart block.
18+
2. Try increasing the quantity, it should work.

docs/internal-developers/testing/releases/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ Every release includes specific testing instructions for new features and bug fi
117117
- [9.4.0](./940.md)
118118
- [9.4.1](./941.md)
119119
- [9.4.2](./942.md)
120-
120+
- [9.4.3](./943.md)
121121

122122
<!-- FEEDBACK -->
123123

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"name": "@woocommerce/block-library",
33
"title": "WooCommerce Blocks",
44
"author": "Automattic",
5-
"version": "9.4.2",
5+
"version": "9.4.3",
66
"description": "WooCommerce blocks for the Gutenberg editor.",
77
"homepage": "https://github.com/woocommerce/woocommerce-gutenberg-products-block/",
88
"keywords": [

readme.txt

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ Tags: gutenberg, woocommerce, woo commerce, products, blocks, woocommerce blocks
44
Requires at least: 6.1.1
55
Tested up to: 6.1.1
66
Requires PHP: 7.2
7-
Stable tag: 9.4.2
7+
Stable tag: 9.4.3
88
License: GPLv3
99
License URI: https://www.gnu.org/licenses/gpl-3.0.html
1010

@@ -80,6 +80,13 @@ Release and roadmap notes available on the [WooCommerce Developers Blog](https:/
8080

8181
== Changelog ==
8282

83+
= 9.4.3 - 2023-02-01 =
84+
85+
#### Bug Fixes
86+
87+
- Fix a bug in WordPress 5.9 in which changing quantity doesn't work inside Cart and Mini Cart blocks. ([8297](https://github.com/woocommerce/woocommerce-blocks/pull/8356))
88+
- Mini Cart block: Fix the drawer content height to allow the checkout button to be visible. ([8297](https://github.com/woocommerce/woocommerce-blocks/pull/8351))
89+
8390
= 9.4.2 - 2023-01-26 =
8491

8592
#### Bug Fixes

src/Package.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ public static function container( $reset = false ) {
109109
NewPackage::class,
110110
function ( $container ) {
111111
// leave for automated version bumping.
112-
$version = '9.4.2';
112+
$version = '9.4.3';
113113
return new NewPackage(
114114
$version,
115115
dirname( __DIR__ ),

woocommerce-gutenberg-products-block.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
* Plugin Name: WooCommerce Blocks
44
* Plugin URI: https://github.com/woocommerce/woocommerce-gutenberg-products-block
55
* Description: WooCommerce blocks for the Gutenberg editor.
6-
* Version: 9.4.2
6+
* Version: 9.4.3
77
* Author: Automattic
88
* Author URI: https://woocommerce.com
99
* Text Domain: woo-gutenberg-products-block

0 commit comments

Comments
 (0)