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
Prev Previous commit
Restore global synced color
  • Loading branch information
youknowriad committed Dec 6, 2023
commit d1eb3131aacae984040f5708034e3e7a634bd727
7 changes: 7 additions & 0 deletions packages/editor/src/components/document-bar/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -109,6 +109,12 @@ function BaseDocumentActions( { postType, postId, onBack } ) {
const isTemplate = [ 'wp_template', 'wp_template_part' ].includes(
postType
);
const isGlobalEntity = [
'wp_template',
'wp_navigation',
'wp_template_part',
'wp_block',
].includes( postType );

useEffect( () => {
if ( ! isMounting.current ) {
Expand All @@ -124,6 +130,7 @@ function BaseDocumentActions( { postType, postId, onBack } ) {
className={ classnames( 'editor-document-bar', {
'has-back-button': !! onBack,
'is-animated': isAnimated,
'is-global': isGlobalEntity,
} ) }
>
{ onBack && (
Expand Down
4 changes: 4 additions & 0 deletions packages/editor/src/components/document-bar/style.scss
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,10 @@
color: var(--wp-block-synced-color);
}

.editor-document-bar.is-global & {
color: var(--wp-block-synced-color);
}

.block-editor-block-icon {
min-width: $grid-unit-30;
flex-shrink: 0;
Expand Down