diff --git a/src/OnboardingSPA/components/App/index.js b/src/OnboardingSPA/components/App/index.js index 0bd68d32d..fe9efbd73 100644 --- a/src/OnboardingSPA/components/App/index.js +++ b/src/OnboardingSPA/components/App/index.js @@ -158,7 +158,7 @@ const App = () => { function handleConditionalDesignStepsRoutes() { if ( location?.pathname.includes( 'colors' ) || - location?.pathname.includes( 'fonts' ) + location?.pathname.includes( 'typography' ) ) { const updates = injectInAllSteps( allSteps, diff --git a/src/OnboardingSPA/components/Drawer/DrawerPanel/DesignFonts.js b/src/OnboardingSPA/components/Drawer/DrawerPanel/DesignFonts.js index 1b90783a9..41d672a3a 100644 --- a/src/OnboardingSPA/components/Drawer/DrawerPanel/DesignFonts.js +++ b/src/OnboardingSPA/components/Drawer/DrawerPanel/DesignFonts.js @@ -85,17 +85,17 @@ const DesignFonts = () => { if ( globalStylesCopy?.styles?.typography?.fontFamily && - globalStylesCopy?.styles?.blocks[ 'core/heading' ]?.typography - ?.fontFamily + globalStylesCopy?.styles?.blocks[ 'core/heading' ] ) { globalStylesCopy.styles.typography.fontFamily = fontPalettesCopy[ fontStyle ]?.styles?.typography?.fontFamily; - globalStylesCopy.styles.blocks[ - 'core/heading' - ].typography.fontFamily = - fontPalettesCopy[ fontStyle ]?.styles.blocks[ - 'core/heading' - ].typography.fontFamily; + globalStylesCopy.styles.blocks[ 'core/heading' ] = { + ...globalStylesCopy.styles.blocks[ 'core/heading' ], + typography: + fontPalettesCopy[ fontStyle ]?.styles.blocks[ + 'core/heading' + ].typography, + }; } if (