diff --git a/packages/block-editor/src/components/global-styles/border-panel.js b/packages/block-editor/src/components/global-styles/border-panel.js index 960c19289157a..f8144f1545aeb 100644 --- a/packages/block-editor/src/components/global-styles/border-panel.js +++ b/packages/block-editor/src/components/global-styles/border-panel.js @@ -155,9 +155,7 @@ export default function BorderPanel( { // Shadow const shadow = decodeValue( inheritedValue?.shadow ); const shadowPresets = settings?.shadow?.presets ?? {}; - const overriddenShadowPresets = shadowPresets - ? overrideOrigins( shadowPresets ) - : []; + const overriddenShadowPresets = overrideOrigins( shadowPresets ) ?? []; const setShadow = ( newValue ) => { const slug = overriddenShadowPresets?.find( ( { shadow: shadowName } ) => shadowName === newValue diff --git a/packages/block-editor/src/components/global-styles/typography-panel.js b/packages/block-editor/src/components/global-styles/typography-panel.js index 6b09b146f9ea1..7fab783c4d0e7 100644 --- a/packages/block-editor/src/components/global-styles/typography-panel.js +++ b/packages/block-editor/src/components/global-styles/typography-panel.js @@ -106,7 +106,7 @@ function useHasTextColumnsControl( settings ) { function getUniqueFontSizesBySlug( settings ) { const fontSizes = settings?.typography?.fontSizes ?? {}; - const overriddenFontSizes = fontSizes ? overrideOrigins( fontSizes ) : []; + const overriddenFontSizes = overrideOrigins( fontSizes ) ?? []; const uniqueSizes = []; for ( const currentSize of overriddenFontSizes ) { if ( ! uniqueSizes.some( ( { slug } ) => slug === currentSize.slug ) ) {