Merge branch 'trunk' into spike/mini-cart-iapi
This commit is contained in:
commit
93954a5cde
|
@ -0,0 +1,4 @@
|
|||
Significance: minor
|
||||
Type: tweak
|
||||
|
||||
Fix typo in initCustomFieldsToogle variable name
|
|
@ -1,6 +1,6 @@
|
|||
export { init as initCatalogVisibility } from './product-fields/catalog-visibility';
|
||||
export { init as initCustomFields } from './product-fields/custom-fields';
|
||||
export { init as initCustomFieldsToogle } from './product-fields/custom-fields-toggle';
|
||||
export { init as initCustomFieldsToggle } from './product-fields/custom-fields-toggle';
|
||||
export { init as initCheckbox } from './generic/checkbox';
|
||||
export { init as initCollapsible } from './generic/collapsible';
|
||||
export { init as initConditional } from './generic/conditional';
|
||||
|
|
|
@ -6,7 +6,7 @@ import { store, getContext } from '@woocommerce/interactivity';
|
|||
/**
|
||||
* Internal dependencies
|
||||
*/
|
||||
import { navigate } from '../../frontend';
|
||||
import { navigate } from '../product-filter/frontend';
|
||||
|
||||
type ActiveFiltersContext = {
|
||||
queryId: number;
|
|
@ -8,7 +8,7 @@ import { HTMLElementEvent } from '@woocommerce/types';
|
|||
/**
|
||||
* Internal dependencies
|
||||
*/
|
||||
import { navigate } from '../../frontend';
|
||||
import { navigate } from '../product-filter/frontend';
|
||||
|
||||
type AttributeFilterContext = {
|
||||
attributeSlug: string;
|
|
@ -6,7 +6,7 @@ import { store, getContext } from '@woocommerce/interactivity';
|
|||
/**
|
||||
* Internal dependencies
|
||||
*/
|
||||
import { navigate } from '../../frontend';
|
||||
import { navigate } from '../product-filter/frontend';
|
||||
|
||||
const getQueryParams = ( e: Event ) => {
|
||||
const filterNavContainer = ( e.target as HTMLElement )?.closest(
|
|
@ -16,8 +16,8 @@ import type {
|
|||
BlockContext,
|
||||
BlockVariationTriggerType,
|
||||
} from './types';
|
||||
import { default as productFiltersIcon } from '../product-filters/icon';
|
||||
import { BlockOverlayAttribute as ProductFiltersBlockOverlayAttribute } from '../product-filters/constants';
|
||||
import { default as productFiltersIcon } from '../../icon';
|
||||
import { BlockOverlayAttribute as ProductFiltersBlockOverlayAttribute } from '../../constants';
|
||||
import './editor.scss';
|
||||
import { Inspector } from './inspector-controls';
|
||||
|
|
@ -1,7 +1,7 @@
|
|||
/**
|
||||
* Internal dependencies
|
||||
*/
|
||||
import { BlockOverlayAttributeOptions as ProductFiltersBlockOverlayAttributeOptions } from '../product-filters/types';
|
||||
import { BlockOverlayAttributeOptions as ProductFiltersBlockOverlayAttributeOptions } from '../../types';
|
||||
|
||||
type BorderRadius = {
|
||||
bottomLeft: string;
|
|
@ -9,7 +9,7 @@ import { debounce } from '@woocommerce/base-utils';
|
|||
/**
|
||||
* Internal dependencies
|
||||
*/
|
||||
import { navigate } from '../../frontend';
|
||||
import { navigate } from '../product-filter/frontend';
|
||||
import type { PriceFilterContext, PriceFilterStore } from './types';
|
||||
|
||||
const getUrl = ( context: PriceFilterContext ) => {
|
|
@ -8,7 +8,7 @@ import { DropdownContext } from '@woocommerce/interactivity-components/dropdown'
|
|||
/**
|
||||
* Internal dependencies
|
||||
*/
|
||||
import { navigate } from '../../frontend';
|
||||
import { navigate } from '../product-filter/frontend';
|
||||
|
||||
function getUrl( filters: Array< string | null > ) {
|
||||
filters = filters.filter( Boolean );
|
|
@ -9,7 +9,7 @@ import { CheckboxListContext } from '@woocommerce/interactivity-components/check
|
|||
/**
|
||||
* Internal dependencies
|
||||
*/
|
||||
import { navigate } from '../../frontend';
|
||||
import { navigate } from '../product-filter/frontend';
|
||||
|
||||
const getUrl = ( activeFilters: string ) => {
|
||||
const url = new URL( window.location.href );
|
|
@ -85,40 +85,43 @@ const blocks = {
|
|||
},
|
||||
'single-product': {},
|
||||
'stock-filter': {},
|
||||
'product-filter': {
|
||||
isExperimental: true,
|
||||
},
|
||||
'product-filters': {
|
||||
isExperimental: true,
|
||||
},
|
||||
'product-filter': {
|
||||
isExperimental: true,
|
||||
customDir: 'product-filters/inner-blocks/product-filter',
|
||||
},
|
||||
'product-filters-overlay': {
|
||||
isExperimental: true,
|
||||
customDir: 'product-filters/inner-blocks/overlay',
|
||||
},
|
||||
'product-filters-overlay-navigation': {
|
||||
isExperimental: true,
|
||||
customDir: 'product-filters/inner-blocks/overlay-navigation',
|
||||
},
|
||||
'product-filter-stock-status': {
|
||||
isExperimental: true,
|
||||
customDir: 'product-filter/inner-blocks/stock-filter',
|
||||
customDir: 'product-filters/inner-blocks/stock-filter',
|
||||
},
|
||||
'product-filter-price': {
|
||||
customDir: 'product-filter/inner-blocks/price-filter',
|
||||
customDir: 'product-filters/inner-blocks/price-filter',
|
||||
isExperimental: true,
|
||||
},
|
||||
'product-filter-attribute': {
|
||||
customDir: 'product-filter/inner-blocks/attribute-filter',
|
||||
customDir: 'product-filters/inner-blocks/attribute-filter',
|
||||
isExperimental: true,
|
||||
},
|
||||
'product-filter-rating': {
|
||||
customDir: 'product-filter/inner-blocks/rating-filter',
|
||||
customDir: 'product-filters/inner-blocks/rating-filter',
|
||||
isExperimental: true,
|
||||
},
|
||||
'product-filter-active': {
|
||||
customDir: 'product-filter/inner-blocks/active-filters',
|
||||
customDir: 'product-filters/inner-blocks/active-filters',
|
||||
isExperimental: true,
|
||||
},
|
||||
'product-filter-clear-button': {
|
||||
customDir: 'product-filter/inner-blocks/clear-button',
|
||||
customDir: 'product-filters/inner-blocks/clear-button',
|
||||
isExperimental: true,
|
||||
},
|
||||
'order-confirmation-summary': {
|
||||
|
|
|
@ -1,4 +0,0 @@
|
|||
Significance: minor
|
||||
Type: fix
|
||||
|
||||
CYS - Remove usage of `prepare_item_for_response` function in `Images` endpoint.
|
|
@ -0,0 +1,4 @@
|
|||
Significance: patch
|
||||
Type: update
|
||||
|
||||
Update /merchant tests (first five files), so they are passing against Pressable env.
|
|
@ -1,5 +0,0 @@
|
|||
Significance: patch
|
||||
Type: fix
|
||||
Comment: This is a further fix for #49583, which has not yet been released
|
||||
|
||||
|
|
@ -0,0 +1,5 @@
|
|||
Significance: patch
|
||||
Type: update
|
||||
Comment: Update the folder structure of new filter blocks.
|
||||
|
||||
|
|
@ -16,6 +16,11 @@ config = {
|
|||
'**/admin-marketing/**/*.spec.js',
|
||||
'**/admin-tasks/**/*.spec.js',
|
||||
'**/customize-store/**/*.spec.js',
|
||||
'**/merchant/command-palette.spec.js',
|
||||
'**/merchant/create-cart-block.spec.js',
|
||||
'**/merchant/create-checkout-block.spec.js',
|
||||
'**/merchant/create-coupon.spec.js',
|
||||
'**/merchant/create-order.spec.js',
|
||||
],
|
||||
grepInvert: /@skip-on-default-pressable/,
|
||||
},
|
||||
|
|
|
@ -5,6 +5,7 @@ const {
|
|||
insertBlock,
|
||||
transformIntoBlocks,
|
||||
publishPage,
|
||||
closeChoosePatternModal,
|
||||
} = require( '../../utils/editor' );
|
||||
const { getInstalledWordPressVersion } = require( '../../utils/wordpress' );
|
||||
|
||||
|
@ -23,6 +24,8 @@ test.describe(
|
|||
} ) => {
|
||||
await goToPageEditor( { page } );
|
||||
|
||||
await closeChoosePatternModal( { page } );
|
||||
|
||||
await fillPageTitle( page, testPage.title );
|
||||
const wordPressVersion = await getInstalledWordPressVersion();
|
||||
await insertBlock( page, 'Classic Cart', wordPressVersion );
|
||||
|
|
|
@ -7,6 +7,7 @@ const {
|
|||
transformIntoBlocks,
|
||||
publishPage,
|
||||
openEditorSettings,
|
||||
closeChoosePatternModal,
|
||||
} = require( '../../utils/editor' );
|
||||
const { getInstalledWordPressVersion } = require( '../../utils/wordpress' );
|
||||
|
||||
|
@ -74,6 +75,8 @@ test.describe(
|
|||
} ) => {
|
||||
await goToPageEditor( { page } );
|
||||
|
||||
await closeChoosePatternModal( { page } );
|
||||
|
||||
await fillPageTitle( page, testPage.title );
|
||||
const wordPressVersion = await getInstalledWordPressVersion();
|
||||
await insertBlock( page, 'Classic Checkout', wordPressVersion );
|
||||
|
|
|
@ -35,7 +35,15 @@ const test = baseTest.extend( {
|
|||
coupon: async ( { api }, use ) => {
|
||||
const coupon = {};
|
||||
await use( coupon );
|
||||
await api.delete( `coupons/${ coupon.id }`, { force: true } );
|
||||
await api
|
||||
.delete( `coupons/${ coupon.id }`, { force: true } )
|
||||
.then( ( response ) => {
|
||||
console.log( 'Delete successful:', response.data );
|
||||
} )
|
||||
.catch( ( error ) => {
|
||||
console.log( 'Error response data:', error.response.data );
|
||||
throw new Error( error.response.data );
|
||||
} );
|
||||
},
|
||||
} );
|
||||
|
||||
|
|
|
@ -299,10 +299,17 @@ test.describe(
|
|||
await page
|
||||
.getByRole( 'textbox', { name: 'Postcode' } )
|
||||
.fill( '12345' );
|
||||
await page
|
||||
.getByRole( 'textbox', { name: 'Select an option…' } )
|
||||
.click();
|
||||
await page.getByRole( 'option', { name: 'Florida' } ).click();
|
||||
// eslint-disable-next-line playwright/no-conditional-in-test
|
||||
if (
|
||||
await page
|
||||
.getByRole( 'textbox', { name: 'Select an option…' } )
|
||||
.isVisible()
|
||||
) {
|
||||
await page
|
||||
.getByRole( 'textbox', { name: 'Select an option…' } )
|
||||
.click();
|
||||
await page.getByRole( 'option', { name: 'Florida' } ).click();
|
||||
}
|
||||
await page
|
||||
.getByRole( 'textbox', { name: 'Email address' } )
|
||||
.fill( 'elbarto@example.com' );
|
||||
|
|
Loading…
Reference in New Issue