XF 2.0 alternate background color on widget

  • Thread starter Thread starter Deleted member 184953
  • Start date Start date
D

Deleted member 184953

Guest
Hello,

How to get alternative background color on New Posts and New Threads widget ?
I mean to get each message row or thread row with an alternate background color.

Is it possible ?
 
Last edited by a moderator:
Hi @Steve F
Is there a way to do the same thing for node list ? in home page ?
And remove the border between each node too ?

like this
Capture d’écran 2018-11-01 à 23.52.54.webp

many thanks !
Hope you're hungry, pizza is in oven ;)
 
I found for the border !
CSS:
.node+.node {border-top: none;}

But i can't do anything for the alternate background...
 
Yeah same concept pretty much, this should work,

Less:
[data-template="forum_list"]
{
    .block-container .node:nth-child(odd)
    {
        background: #e9f5fd;
        border-top: none;
    }
    .block-container .node:nth-child(even)
    {
        background: #fff;
        border-top: none;
    }

}
 
Hey @Steve F, it's me, again ! ✌

What is the code for alternate background for new-post widget but used in what's new page ? Widget with plain thread infos
Each line is not made with block-row anymore but with structItem-cell

I tried all possibilities but... :(
Thanks in advance
 
Yeah same concept pretty much, this should work,

Less:
[data-template="forum_list"]
{
    .block-container .node:nth-child(odd)
    {
        background: #e9f5fd;
        border-top: none;
    }
    .block-container .node:nth-child(even)
    {
        background: #fff;
        border-top: none;
    }

}

Copied this to extra.css and it works great. What's the code for doing the same thing to the thread list within a sub-forum?
 
Back
Top Bottom