Choosing sub values in Cascader

So I'm working in this cascader list.

This list displays real estate info.

I can't figure out how to click on the purple choices and get the path.

This seems to only work in child choices (the green ones).

It would be incredibly useful to have it work on all the choices (and also have a properties for all selected choices)

Is there a workaround for this component?

Screenshot 2023-12-14 at 08.50.59

Hi, welcome to the forums

I don't think that component would work as you want it to - it's used to display categories and structures of data to select an individual item, not for selecting the higher level categories. So in this case hovering on a purple item isn't making a choice it's showing the actual choices (green)
I think of it like a file picker - it'll show you the folders but you can't pick a folder, only a file.

You could write your own nested set of listpicker components and dynamically drive the data through that - not a trivial amount of work but it'd be possible

Might be easier to understand if you can share your use case and why the purple items should be selectable?

The example is actually from a specific case.

I want to be able to choose e.g Aursnes, which is a real estate brand -> Sykkylven is therefore an office under that brand.

Further on, if I can pick Aurnes or Sykkylven I have information that I want to show for each brand or office. Maybe I want to show the name of the brand or employees for the office, but in another component.

So if it's a multi-stage selection then having multiple components might be a better option, something like this maybe?

forum.json (11.7 KB)

2 Likes

That is true :thinking: Thanks for the example! :blush:

This probably got me one step closer to the finish line!

I really appreciate the fast response here :pray:

1 Like