Site logo

Archived topic

full width line in sidebar while keeping widget padding

3 replies · Started by Johan on June 23, 2019

Viewing posts 1–4 of 4

Hello,

I have a css question.
How can i get a line under each widget title that spans the entire width of the sidebar?
When i use the widget title's border bottom it works...but only with setting widget padding to zero.
How can i have a full width border bottom while keeping the widget padding?
the same as on this site where you can see the grey line under each widget title.

thank you

Hi there,

Try this CSS:

.sidebar .widget-title {
    margin-left: -40px;
    margin-right: -40px;
    padding-left: 40px;
    padding-right: 40px;
    border-bottom: 1px solid #ddd;
}

You'll need to adjust the 40px value to whatever you sidebar padding is.

It works!
Thanks Tom!

You're welcome :)

This archived topic is closed to new replies.