[Resolved] Adding class to Mobile Typography options

Home Forums Support [Resolved] Adding class to Mobile Typography options

Home Forums Support Adding class to Mobile Typography options

Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #258523
    Jacob

    I’m trying to make some text responsive and it seems like the Mobile options for Typography is the best option. I have a custom class for the sections of text, but the fonts are within the google family, so there shouldn’t be any issue with compatibility there. Is there a way to add additional classes to the three that are included as standard (site title, h1, h2)?
    Thanks much!

    #258529
    Tom
    Lead Developer
    Lead Developer

    Hi there,

    There’s not an easy way to add additional classes to them, but you should be able to use the existing classes using media queries:

    @media (max-width: 768px) {
        .main-title {
            /* CSS for site title on mobile */
        }
        h1 {
            /* H1 styling etc.. */
        }
    }

    Let me know if that helps or not ๐Ÿ™‚

    #258534
    Jacob

    Thanks for the quick reply! That was my first thought, but it wasn’t working for me. Perhaps it’s a conflict with the Easy Google Fonts plugin. I’ll play around with it a bit. Thanks again.

    #258535
    Jacob

    Manual import of font family and styling + @media resize does the trick. More grunt work, but as long as it gets the job done, right?

    Thanks much for helping out!

    #258679
    Tom
    Lead Developer
    Lead Developer

    Glad you got it working ๐Ÿ™‚

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