Apply a class to searchPane if it's active but collapsed

Apply a class to searchPane if it's active but collapsed

Konstantin_SalKonstantin_Sal Posts: 5Questions: 3Answers: 0

Hi! Is there a way to see currently active search pane while it is in collapsed state?
When it's expanded, it's colored in blue by default, and you can easily tell which filter exactly is being used.
But when in collapsed mode, you can only guess or press Expand all.

I would like to make it visible which ones are active.

Answers

  • colincolin Posts: 15,143Questions: 1Answers: 2,586
    edited October 2022

    That's a good idea. I've raised it internally as an enhancement (DD-2582 for my reference), and we'll report back here when there's progress.

    In the meantime, you can add it into the _searchExtra() function as the end of the file. You need to add the class to the header too, something like:

            if (filters.length > 0) {
                container.addClass(this.classes.selected);
                $(container).prev('.dtsp-topRow').addClass(this.classes.selected);
            }
            else if (filters.length === 0) {
                container.removeClass(this.classes.selected);
                $(container).prev('.dtsp-topRow').removeClass(this.classes.selected);
            }
    
    

    Colin

Sign In or Register to comment.