Skip to content

Commit

Permalink
Fix: Styles section does not moves stylebook to typography. (WordPres…
Browse files Browse the repository at this point in the history
…s#67423)

Co-authored-by: jorgefilipecosta <[email protected]>
Co-authored-by: ramonjd <[email protected]>
  • Loading branch information
3 people authored and im3dabasia committed Dec 4, 2024
1 parent e543e53 commit 52d31cb
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions packages/edit-site/src/components/style-book/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,11 @@ const scrollToSection = ( anchorId, iframe ) => {
*/
const getStyleBookNavigationFromPath = ( path ) => {
if ( path && typeof path === 'string' ) {
if ( path.startsWith( '/typography' ) ) {
return {
block: 'typography',
};
}
let block = path.includes( '/blocks/' )
? decodeURIComponent( path.split( '/blocks/' )[ 1 ] )
: null;
Expand Down

0 comments on commit 52d31cb

Please sign in to comment.