• Skip to main content
  • Skip to forum navigation

StudioPress

  • Shop for Themes
  • My StudioPress

Forum navigation

  • Home
  • General Genesis Discussions
  • StudioPress Themes
  • Genesis Blocks
    • Genesis Blocks
    • Genesis Custom Blocks
  • Retired Themes
  • FAQs
  • Forum Rules
  • Internationalization and Translations
  • Forum Bugs and Suggestions
  • Forum Log In

Are You Using The WordPress Block Editor?

Genesis now offers plugins that help you build better sites faster with the WordPress block editor (Gutenberg). Try the feature-rich free versions of each plugin for yourself!

Genesis Blocks Genesis Custom Blocks

Gutenberg Inline CSS

Welcome!

These forums are for general discussion on WordPress and Genesis. Official support for StudioPress themes is offered exclusively at My StudioPress. Responses in this forum are not guaranteed. Please note that this forum will require a new username, separate from the one used for My.StudioPress.

Log In
Register Lost Password

Community Forums › Forums › Archived Forums › Design Tips and Tricks › Gutenberg Inline CSS

This topic is: not resolved

Tagged: genesis sample, Gutenberg, inline css

  • This topic has 1 reply, 1 voice, and was last updated 6 years, 11 months ago by Steve.
Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • October 28, 2019 at 4:54 pm #494290
    Steve
    Participant

    Hello this is my first post!

    I've been reading the code for Genesis and like it a lot, but I am confused by this:

    <link rel='stylesheet' id='dddddd-gutenberg-css'  href='https://dddddd.com/wp-content/themes/divkid/lib/gutenberg/front-end.css?ver=3.1.0' type='text/css' media='all' />
    <style id='dddddd-gutenberg-inline-css' type='text/css'>
    .ab-block-post-grid .ab-post-grid-items h2 a:hover {
    	color: #0073e5;
    }
    
    .site-container .wp-block-button .wp-block-button__link {
    	background-color: #0073e5;
    }
    
    .wp-block-button .wp-block-button__link:not(.has-background),
    .wp-block-button .wp-block-button__link:not(.has-background):focus,
    .wp-block-button .wp-block-button__link:not(.has-background):hover {
    	color: #ffffff;
    }
    
    .site-container .wp-block-button.is-style-outline .wp-block-button__link {
    	color: #0073e5;
    }
    
    .site-container .wp-block-button.is-style-outline .wp-block-button__link:focus,
    .site-container .wp-block-button.is-style-outline .wp-block-button__link:hover {
    	color: #2396ff;
    }		.site-container .has-small-font-size {
    			font-size: 12px;
    		}		.site-container .has-normal-font-size {
    			font-size: 18px;
    		}		.site-container .has-large-font-size {
    			font-size: 20px;
    		}		.site-container .has-larger-font-size {
    			font-size: 24px;
    		}		.site-container .has-theme-primary-color,
    		.site-container .wp-block-button .wp-block-button__link.has-theme-primary-color,
    		.site-container .wp-block-button.is-style-outline .wp-block-button__link.has-theme-primary-color {
    			color: #0073e5;
    		}
    
    		.site-container .has-theme-primary-background-color,
    		.site-container .wp-block-button .wp-block-button__link.has-theme-primary-background-color,
    		.site-container .wp-block-pullquote.is-style-solid-color.has-theme-primary-background-color {
    			background-color: #0073e5;
    		}		.site-container .has-theme-secondary-color,
    		.site-container .wp-block-button .wp-block-button__link.has-theme-secondary-color,
    		.site-container .wp-block-button.is-style-outline .wp-block-button__link.has-theme-secondary-color {
    			color: #0073e5;
    		}
    
    		.site-container .has-theme-secondary-background-color,
    		.site-container .wp-block-button .wp-block-button__link.has-theme-secondary-background-color,
    		.site-container .wp-block-pullquote.is-style-solid-color.has-theme-secondary-background-color {
    			background-color: #0073e5;
    		}
    </style>

    Does anyone know if there is a good reason why there is a Gutenberg css file and Gutenberg inline css in the Genesis / Genesis Sample theme?

    Please be as technical as you like - thanks!!

    http://local
    October 29, 2019 at 7:39 am #494306
    Steve
    Participant

    So, digging deeper I have found:

    lib/gutenberg/inline-styles.php

    which as far as I have worked out seems to be taking admin theme config options and writing the css values to the head as inline styles.

    This is totally unnecessary for me, I don't need the config options from the admin panel, the values won't change once set and I would much rather do that in a theme code file. And preferably get some kind of css compiler running to generate one minified css file rather than all the little ones (but that's probably a different question).

    Has anyone already removed these inline styles and knows how to go about it?

    I would very much appreciate any thoughts on this matter. Again, please be as technical as you like, I will get there eventually, I just don't want to re-invent the wheel so to speak 🙂

    Thank you!

  • Author
    Posts
Viewing 2 posts - 1 through 2 (of 2 total)
  • The forum ‘Design Tips and Tricks’ is closed to new topics and replies.

CTA

Ready to get started? Create a site or shop for themes.

Create a site with WP EngineShop for Themes

Footer

StudioPress

© 2026 WPEngine, Inc.

Products
  • Create a Site with WP Engine
  • Shop for Themes
  • Theme Features
  • Get Started
  • Showcase
Company
  • Brand Assets
  • Terms of Service
  • Accptable Usse Policy
  • Privacy Policy
  • Refund Policy
  • Contact Us
Community
  • Find Developers
  • Forums
  • Facebook Group
  • #GenesisWP
  • Showcase
Resources
  • StudioPress Blog
  • Help & Documentation
  • FAQs
  • Code Snippets
  • Affiliates
Connect
  • StudioPress Live
  • StudioPress FM
  • Facebook
  • Twitter
  • Dribbble