Select to view content in your preferred language

Toggle Anchored Windows Using Buttons

798
3
10-08-2024 11:04 AM
Labels (1)
JuliaLax
Emerging Contributor

Hi, 

I am working in Experience Builder and have created a "drop-down list" that holds the map widgets where users can select a tool from. This drop-down list is an anchored window that is linked to a button in the header. However, I can only open the drop-down window by clicking the header button, and to close the window the user has to click outside the window or click an X button at the top of the window that I added to return to the map. This behavior is causing confusion for users, as it differs from the expected web standard where clicking the same button would toggle (open and close) the drop-down.

Is there a way to enhance the functionality of Experience Builder buttons so they can toggle the anchored window (i.e., both open and close it) when clicked?

Thank you!

3 Replies
JeffreyThompson2
MVP Frequent Contributor

It sounds like you've done something very interesting, but I can't fully visualize it from your description. Could you take some screenshots and maybe I can think of a way to help?

GIS Developer
City of Arlington, Texas
0 Kudos
JuliaLax
Emerging Contributor

Hi Jeffrey,

Thanks for your help! You can view the screenshot of the drop-down window I'm referring to here. Link to Example Image.

0 Kudos
JeffreyThompson2
MVP Frequent Contributor

I have done some experimentation and it does not appear possible to make a "single button" open and close a window. I found a very complicated setup that involves placing Button Widgets inside Section Widgets that can appear to be a single button and open and close widgets in a Sidebar Widget. It's a very lengthy setup and I'm not sure it would work in all cases. If you think it will be useful, it probably deserves a full write up on the Tips and Tricks Board.

If you are not satisfied with your current set up, you could put your widgets in a Widget Controller. You will lose some control over the appearance of your buttons, but the toggling feature will be built in.

GIS Developer
City of Arlington, Texas
0 Kudos