GUIDE XF2 | TEMPLATE MODIFICATION | Highlighting threads user participated in

CONSTANZE

Member
Direct
Member
This, basically, highlights every thread the current user has posted in in a different color that the rest of threads where he never participated in.




To get this you need to make changes in two different places:

1) Add the following to EXTRA.css:

CSS:
.memberParticipatedThread {
    background-color: #C4E599 !important;
}
2) Find the following in template (thread_list_macros):

HTML:
<div class="structItem structItem--thread{{ $thread.prefix_id ? ' is-prefix' . $thread.prefix_id : '' }}{{ $thread.isIgnored() ? ' is-ignored' : '' }}{{ ($thread.isUnread() AND !$forceRead) ? ' is-unread' : '' }}{{ $thread.discussion_state == 'moderated' ? ' is-moderated' : '' }}{{ $thread.discussion_state == 'deleted' ? ' is-deleted' : '' }} js-inlineModContainer js-threadListItem-{$thread.thread_id}" data-author="{{ $thread.User.username ?: $thread.username }}">
Replace with the following:

HTML:
<div class="structItem structItem--thread{{ $thread.prefix_id ? ' is-prefix' . $thread.prefix_id : '' }}{{ $thread.isIgnored() ? ' is-ignored' : '' }}{{ ($thread.isUnread() AND !$forceRead) ? ' is-unread' : '' }}{{ $thread.discussion_state == 'moderated' ? ' is-moderated' : '' }}{{ $thread.discussion_state == 'deleted' ? ' is-deleted' : '' }}{{ $thread.getUserPostCount() ? ' memberParticipatedThread' : '' }} js-inlineModContainer js-threadListItem-{$thread.thread_id}" data-author="{{ $thread.User.username ?: $thread.username }}">
That's it.
 

Latest profile posts

I recovered most of my maps :smile:
JesusX0 wrote on patatino2000's profile.
Hey you have discord?
JesusX0 wrote on Churchill VII's profile.
Hey you have discord?
JesusX0 wrote on Ochinche's profile.
Hey, you have discord?
Ultimate 2.28USD? lol

Forum statistics

Threads
935
Messages
2,233
Members
26,572
Latest member
munited

Online statistics

Members online
0
Guests online
89
Total visitors
89
Top