diff --git a/packages/global-styles/src/gutenberg-bridge/index.tsx b/packages/global-styles/src/gutenberg-bridge/index.tsx index b3d93d02fdc3c..97c79891d5975 100644 --- a/packages/global-styles/src/gutenberg-bridge/index.tsx +++ b/packages/global-styles/src/gutenberg-bridge/index.tsx @@ -107,10 +107,10 @@ const filterObjectByProperties = ( object: Record< string, any >, properties: st * @returns {boolean} Whether the variation contains only the specified properties. */ const isVariationWithProperties = ( variation: GlobalStylesObject, properties: string[] ) => { - const variationWithProperties = filterObjectByProperties( - window.structuredClone( variation ), - properties - ); + const clonedVariation = window.structuredClone + ? window.structuredClone( variation ) + : JSON.parse( JSON.stringify( variation ) ); + const variationWithProperties = filterObjectByProperties( clonedVariation, properties ); return areGlobalStyleConfigsEqual( variationWithProperties, variation ); };