Change Site Icon Background Color in Fullscreen Mode

Home WordPress Change Site Icon Background Color in Fullscreen Mode

December 9, 2022

In this WordPress tutorial, I will show you how to change the black background color for the site icon button while in Fullscreen mode. For some reason WordPress has defaulted this background color to black. This can cause problems if your site icon is also dark.

Timestamps:

  • 0:00 Introduction
  • 1:23 WordPress Tutorial Begins

Code Credit:
https://rudrastyh.com/gutenberg/custom-logo-in-fullscreen-mode.html

Code Snippets Plugin:
https://wordpress.org/plugins/code-snippets/

PHP Code Snippet

				
					add_action( 'admin_head', 'site_icon_style' );

function site_icon_style(){	
	$screen = get_current_screen();
	if( ! $screen->is_block_editor ) {
		return;
	}
	echo '<style>
	.edit-post-fullscreen-mode-close.has-icon{background-color:#fff!important;border-bottom:1px solid #e0e0e0}
    .edit-post-fullscreen-mode-close.components-button:before{box-shadow:none;}
	</style>';

}
				
			

*Some of the links on this page are affiliate links, meaning we may receive a commission if you follow them. This allows us to continue providing free content and educational resources for you. Thank you for supporting our small business!

More Free Resources

Join Our Community

Wicky Design YouTube

Get our latest videos by subscribing for FREE to our YouTube channel. New videos are uploaded weekly!