Expected behavior of Multi-select with extendSelection
#4947
-
Hi, I wanted to ask about expected behavior of the extendSelection method. As a live example I will use this code sandbox. Reproduction steps:
Expected: "bootmgr" and "log.txt" will be selected More precisely, I think the question is whether the Wanted to know your thoughts about this and to know if there's a particular reason it works like this. Thanks! |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 3 replies
-
I agree, some work should be done here. I think the select + unselect then shift is a bug, if you don't mind opening an issue. This can be observed in our docs as well https://react-spectrum.adobe.com/react-spectrum/ListView.html#example I think the We accept PR's if you feel like making one. |
Beta Was this translation helpful? Give feedback.
I agree, some work should be done here. I think the select + unselect then shift is a bug, if you don't mind opening an issue. This can be observed in our docs as well https://react-spectrum.adobe.com/react-spectrum/ListView.html#example
I think the
anchorKey
should be set to thefocusedKey
when the shift key is pressed. I'm not sure about non-contiguous multi select, if shift should always add to the current selection. But we can at least address theanchorKey
.We accept PR's if you feel like making one.