List Manager Forum

Stylesheet question

User Porter 2024-11-16 09:23:41

If I want/need to highlight what column is sorted e.g., with a bold font or a background color, how is this done? Don't really get it.

Moonsoft support 2024-11-18 09:29:35

Hi,
the current ordered column doesn't contain any specific style, the way to check the ordering is to see the arrows next to the header title (with the up/down sign) change from the 'order' icon to the 'up' or 'down' icon. However you could add some css to attach more specific styles to this header based on the arrow that is active, for ex, to style the header ordered descending (arrow down), you can use the new 'has' selector, to style 'the header that contains' a down arrow:

th:has(> span.fa-caret-down) {
color: #d90f0f;
background-color: #eeeeee !important;
}


It should work on modern browsers, but we share a page with full info in case you want to check compatibility:


https://developer.mozilla.org/es/docs/Web/CSS/:has#browser_compatibility

Hope this helps, regards

Silvia Martín
Moonsoft Team

User Porter 2024-11-18 19:32:36

Thank you, that helps somewhat.

...
Support/development 40 hours

With the peace of mind of having a professional team at your service (20% discount)

Buy now!
...
List Manager

Build different lists for your site

Buy now!