Site logo

Archived topic

Custom Right Sidebar width differently than the global setting.

23 replies · Started by Huseyin on September 21, 2020

Viewing posts 16–24 of 24

Try this CSS:

.right-sidebar.full-width-content #right-sidebar {
    max-width: 160px;
}
.right-sidebar.full-width-content .site-content .content-area {
    max-width: calc( 100% - 160px);
    width: unset;
}

Hi,

To clarify: are you trying to achieve something like this?
https://share.getcloudapp.com/2Nu0BX2D

If so, we can modify David's code a bit to achieve the same result.

Try this:

.right-sidebar.full-width-content #right-sidebar {
    max-width: 160px;
}
.right-sidebar.full-width-content .site-content .content-area {
    max-width: calc( 100% - 160px);
    width: 100%;
}

Perfect!! Thanks, Elvin

Glad it works for you. No problem. :)

You can use @media rule for that.

Example:

@media (max-width: 979px){
.right-sidebar.full-width-content #right-sidebar {
    display:none;
}
}

thanks

No problem. :)

This archived topic is closed to new replies.