[Resolved] Adding Lines to Widget Title

Home Forums Support [Resolved] Adding Lines to Widget Title

Home Forums Support Adding Lines to Widget Title

Viewing 6 posts - 1 through 6 (of 6 total)
  • Author
    Posts
  • #502145
    Clare

    I want to add lines on either side of the widget title.
    It would look something like this:

    —— WIDGET TITLE ——

    Thank you so much for your help!

    #502263
    Leo
    Staff
    Customer Support

    Hi there,

    What you typed above should work in widget title field. Does it not?

    #502266
    Clare

    I don’t want to add dashes, but a line, similar to the widget titles of this blog:
    http://www.kwernerdesign.com

    #502485
    Tom
    Lead Developer
    Lead Developer

    Hi Clare,

    Give this a shot:

    .widget-title {
        position: relative;
        z-index: 1;
        overflow: hidden;
        text-align: center;
    }
    
    .widget-title:before, 
    .widget-title:after {
        position: absolute;
        top: 51%;
        overflow: hidden;
        width: 50%;
        height: 1px;
        content: '';
        background-color: red;
        margin-left: 10px;
    }
    
    .widget-title:before {
        margin-left: calc(-50% - 10px);
        text-align: right;
    }
    #502919
    Clare

    Like a charm! Thanks Tom!

    #503101
    Tom
    Lead Developer
    Lead Developer

    You’re welcome! 🙂

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