Unable to change Blask site title font size

  • Unknown's avatar

    My site title does not fit within the box, and so there is a break in the middle of my name. (It looks fine in mobile.)

    I can change the font family, the font weight, the color, etc., in “customize theme” or by editing the style.css file. I am able to change them by customizing the CSS for h1 or site-title.

    But no matter what I do, the font size does not change.
    Looking at the page using Chrome developer tools, it always says this:

    <h1 class=”site-title” style=”line-height: 54.6px;”>
    Susan Timberlake
    </h1>

    So I tried changing the font using

    .site-title a,
    .site-title a:hover {
    font-size: 30px;
    }

    Again, I can change the font family, the weight, the color, but not the size.

    I am wondering if there might be something wrong with this function in blask.js:

    // Adjust website title font-size to fit its container
    function resizeTitle( el ) {

    var $el = $( el ),
    $parent = $( el ).parent(),
    $parentWidth = $el.parent().width(),
    fontSize = parseInt( $( el ).css( 'font-size' ), 10 );

    if ( $el.width() > $parentWidth ) {

    while ( $el.width() > $parentWidth && fontSize > 18 ) {
    $el.css( 'font-size', --fontSize + 'px' );
    $parent.css( 'line-height', fontSize * 1.5 + 'px' );
    }

    } else {

    while ( $el.width() < 0.8 * $parentWidth && fontSize < 42 ) {
    $el.css( 'font-size', ++fontSize + 'px');
    $parent.css( 'line-height', fontSize * 1.3 + 'px' );
    }

    }
    }

    Please let me know if you have any suggestions.

    Thanks!

    The blog I need help with is: (visible only to logged in users)

  • Unknown's avatar

    It turned some of the code into a link automatically. Here is what the page HTML looks like:
    <h1 class="site-title" style="line-height: 54.6px;">
    Susan Timberlake
    </h1>

  • Unknown's avatar

    Even with code tags it is still turning it into a link. Maybe if I leave the brackets off…

    a href=”https://www.susantimberlake.com/” rel=”home” style=”font-size: 42px; opacity: 1;”>Susan Timberlake</a

  • The topic ‘Unable to change Blask site title font size’ is closed to new replies.