dkebler
(D Kebler)
January 25, 2022, 4:15pm
1
This information about the post (links, pins, etc) is visibile for all users.
I don’t see a setting to hide it for all but say staff.
The “topic map” is ok but where it is linked and pinned it is distracting (for noobs espcecially) and not really relevant for non staff.
I’ve hidden them via css but now staff will not see them.
One suggestion is a new setting minimize post distractions . Would apply to all but staff.
so far it would include
.post-links-container,
.post-notice.new-user,
.small-action.onscreen-post
2 Likes
You could hide them, and then display them only for staff using something like this:
.small-action.onscreen-post {
Display:none;
}
.staff .small-action.onscreen-post {
Display :initial;
}
2 Likes
Heliosurge
(Dan DeMontmorency)
January 25, 2022, 9:20pm
3
Could you also add TL 4 to see small-action?
Does this just hide pins? If not what other details does this hide?
All that little snippet does is hide the small action posts for everyone, and then make them visible to staff users. To be honest, I find the small action posts quite useful (especially the ‘closed’ one), so I wouldn’t advocate hiding them - though deleting some can help clear some noise.
Staff users get a ‘staff’ class added to the page when viewing, so it’s easier to target them. If you wanted to add others I think that would require something more complicated. There’s an example of how to add a specific ‘admin’ class in this post which you may be able to adapt?
Discourse adds a staff class to the body tag when a staff user is viewing the site. If you are ok with the button being visible to admins and moderators, you could hide the button with CSS and then make it visible when the staff class is present.
If only having the button visible to admins is a requirement, you will need to use some javascript to determine that the user is an admin. The easiest approach to that would be to add an admin class to the body and then make the button visible when the…
1 Like
Heliosurge
(Dan DeMontmorency)
January 25, 2022, 10:23pm
5
Okay indeed. Plus need to have Closed Topic visible for all. Simply hiding though could be useful.
I presume though you could target just new user to hide the small actions until they acheive a higher trust level?
system
(system)
Closed
February 24, 2022, 10:23pm
6
This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.