Select to view content in your preferred language

Filter widget - toggle visibility, highlight, handling large amounts of feature data

1245
2
Jump to solution
12-27-2023 10:25 AM
Labels (1)
LindsayKindle
Emerging Contributor

Hello,

I'm attempting to recreate an app in Experience Builder and I have a few issues that I'm trying to work through, and any guidance would be appreciated - even if the answer is "you need Developer Edition to achieve this."

 

#1: Toggling Visibility

In the existing app, there are three filter buttons that toggle the visibility of the feature. I've replicated this in Experience Builder by using the Filter widget, with a Horizontal arrangement style and Button activation style. I'm using the SQL expression (OBJECTID = -1) to create the toggle effect, however this means that when the button is in the 'Active' state, the layer is hidden.

Default StateButton toggled on
LindsayKindle_3-1703700497728.png

 

LindsayKindle_2-1703700463842.png

 

 

Visually I would like the opposite to occur, or for the logic to be reversed. Is this possible?

 

#2: Highlighting feature data on hover

The existing app has a list of municipalities, and users could hover over a municipality to highlight it on the map. In Experience Builder, I'm using a filter with a customized SQL Expression; I use the clause (MUNI_NAME = ?) and selected 'Ask for values' so a dropdown appears.

I haven't been able to find a way to highlight the polygon on hover - is this possible?

The best I can do to focus on the municipality is to zoom into it when selecting the name in the dropdown. But this hides all other municipalities - I would like the visibility to remain unchanged, while the program zooms in on the selected municipality.

Is this possible?

 

#3: Filtering large amounts of data with user select

The Municipalities feature layer has over 100 municipalities. With the existing app, all municipalities are listed. I recreated this in Experience Builder with another Filter widget, and used the SQL Expression Builder to select 'Ask for values'. However, the values do not appear for municipalities as there appears to be a limit to how many values can exist within feature data. When the limit is met, it just turns into a text field:

LindsayKindle_0-1703700906416.png

Is there a way around this limit? Is this a bug?

0 Kudos
1 Solution

Accepted Solutions
JeffreyThompson2
MVP Regular Contributor

1. You could change your labeling on the filter to something like 'Hide Neighborhoods' so it makes more sense why it is highlighted when the neighborhoods are gone. Any better solutions will involve messing with Developer Edition.

2 & 3. You might be better served with a List Widget than the Filter Widget. Clicking on an item in a List Widget will highlight it on the map without filtering the layer (unless you specifically set up that action).  Making it work on hover would involve Developer Edition tinkering. Maybe you could make a list that is just the name of your features and then use this trick to turn a Sidebar into a dropdown menu.

GIS Developer
City of Arlington, Texas

View solution in original post

2 Replies
JeffreyThompson2
MVP Regular Contributor

1. You could change your labeling on the filter to something like 'Hide Neighborhoods' so it makes more sense why it is highlighted when the neighborhoods are gone. Any better solutions will involve messing with Developer Edition.

2 & 3. You might be better served with a List Widget than the Filter Widget. Clicking on an item in a List Widget will highlight it on the map without filtering the layer (unless you specifically set up that action).  Making it work on hover would involve Developer Edition tinkering. Maybe you could make a list that is just the name of your features and then use this trick to turn a Sidebar into a dropdown menu.

GIS Developer
City of Arlington, Texas
LindsayKindle
Emerging Contributor

Thank you Jeffrey, the List widget is exactly what I needed in that instance. Thank you for your help!

0 Kudos