[Resolved] Custom font not showing up in customizer on backend.

Home Forums Support [Resolved] Custom font not showing up in customizer on backend.

Home Forums Support Custom font not showing up in customizer on backend.

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #1642878
    Megan

    I downloaded a font from Myfonts and am currently trying to get it to show in the customizer typography dropdown options.

    I uploaded font to my child theme folder structure. I successfully placed those correctly because when the url is clicked on – the font files download and I can change the heading/body tags via css.

    However, the font wont show up in the customizer section drop-downs for typography. Any idea why?

    The font also seems to be loading on the front end, but not on the backend when editing in customizer. Any way to change that as well?

    CSS in Additional CSS

    @font-face {
        font-family: "NHaasGroteskDSPro75Bd";  
        src: url('http://tccrocksbuild.wpengine.com/wp-content/themes/generatepress_child/Fonts/NHaasGroteskDSPro75Bd.woff2') format('woff2'), url('http://tccrocksbuild.wpengine.com/wp-content/themes/generatepress_child/Fonts/NHaasGroteskDSPro75Bd.woff') format('woff');  
    }

    PHP in Functions.php in child theme

    add_filter( 'generate_typography_default_fonts', 'tu_add_system_fonts' );
    function tu_add_system_fonts( $fonts ) {
        $fonts[] = 'NHaasGroteskDSPro75Bd';
        return $fonts;
    }

    URL: https://tccrocksbuild.wpengine.com

    #1643342
    Leo
    Staff
    Customer Support

    Hi Megan,

    The function looks correct to me. Not sure why it’s not loading in the customizer either.

    Just to confirm, you’ve tried searching the font in the customizer like this?
    https://docs.generatepress.com/article/adding-local-fonts/#using-our-font

    #1644170
    Megan

    I installed a clean version of the child theme and all seems to work now! Thank you!

    #1644565
    Leo
    Staff
    Customer Support

    No problem 🙂

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.