Jump to content

Is there a way to hide the check marks in a hierarchy type filter in the collapsed "dropdown-el" "pop" filter section?


Darshan Patel 5

Recommended Posts

Hi @Jose Leviaguirre​ , love this masthead. I recently was asked to update a checkbox filter to a hierarchy filter (2 columns/nodes if that makes a difference). The issue I am facing is that the hierarchy filter object's checkbox are visible even when the filter is collapsed under the dropdown. Any thoughts? see attached image for context. 2023-06-16_11-11-08.png.3852d620d83975ea0945954529367c9e.png

Link to comment
Share on other sites

Hi @Jose Leviaguirre​ ,

I appreciate your help. Please find attached dxp that's been limited to a few visualizations on single page with dummy data but maintaining masthead.js script and related elements. Let me know if this file displays same constant hierarchylistbox filter's checkmarks on your end. Thanks again.

Link to comment
Share on other sites

  • 3 weeks later...

@Jose Leviaguirre​  I know you have tremendous demands on your time, but would appreciate any help, Just checking in. with you in case you had an opportunity to look at the dxp I uploaded and leverage your wizardry to diagnose what ails my dashboard. 😀

side note - many thanks for your ongoing contributions. Where were you a decade ago? No matter how leisurely TIBCO plodded in finding or enabling you and the other (relatively?) new community experts, I am glad they did. To imagine I used to have to do an infinity scroll to occasionally arrive at a non answer or other users looking aimlessly to solve same question verses now: non-coding or low-coding user(s) easily incorporating these fancy examples' and even extending capabilities via mods subsequently users will voluntarily broadcast/share via exchange. All while minimizing FUBAR potential, This was a pipe dream not too long ago. Thanks again to you and the active SME's on the TIBCO community, you help people who are definitely fans of the Spotfire product .

Link to comment
Share on other sites

Thanks Darshan for your kind words and patience. I updated the code to hide those checkbox remains. If the article does not reflect the changes, I replace the hidden to zIndex as a work around:

/**popup filters*///bind eventsvar x=[...document.querySelectorAll(".dropdown-el.icon")]x.forEach(el=>{ el.addEventListener('click',(ev)=>{ let pop = el.parentNode.lastElementChild hideAll(pop) pop.style.zIndex=pop.style.zIndex=="-1"?"auto":"-1" //◄ here })}) //hides all except elfunction hideAll(el){ [...document.getElementsByClassName("pop")] .map((e,i)=>{ if(el!=e){ e.style.zIndex = "-1" //◄ and here } })}

Thanks for pointing that out!

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...