Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 9 additions & 6 deletions src/plugins/global-settings/editor-loader.js
Original file line number Diff line number Diff line change
Expand Up @@ -46,12 +46,15 @@ const GlobalSettingsLoader = () => {
useEffect( () => {
const editorBody = editorDom?.closest( 'body' )
if ( editorBody ) {
editorBody.appendChild( globalTypographyWrapper )
editorBody.appendChild( globalColorWrapper )
editorBody.appendChild( globalSpacingAndBorderWrapper )
editorBody.appendChild( globalButtonsAndIconsWrapper )
editorBody.appendChild( globalColorSchemesWrapper )
editorBody.appendChild( globalPresetControlsWrapper )
// No need to check for firstChild, since there will always be at least one
// e.g. the post title wrapper and the actual root container.
const firstChild = editorBody.firstChild
editorBody.insertBefore( globalTypographyWrapper, firstChild )
editorBody.insertBefore( globalColorWrapper, firstChild )
editorBody.insertBefore( globalSpacingAndBorderWrapper, firstChild )
editorBody.insertBefore( globalButtonsAndIconsWrapper, firstChild )
editorBody.insertBefore( globalColorSchemesWrapper, firstChild )
editorBody.insertBefore( globalPresetControlsWrapper, firstChild )
}
}, [ deviceType, editorDom ] )

Expand Down
2 changes: 1 addition & 1 deletion src/plugins/theme-block-size/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ export const ThemeBlockSize = () => {
useEffect( () => {
const editorBody = editorDom?.closest( 'body' )
if ( editorBody ) {
editorBody.appendChild( themeBlockSizeWrapper )
editorBody.insertBefore( themeBlockSizeWrapper, editorBody.firstChild )
}
}, [ deviceType, editorDom ] )

Expand Down
Loading