equinor / fusion-workspace

MIT License
9 stars 2 forks source link

🐛 Search in Advanced Filter not working when selecting filter item #137

Open jaysencpp opened 2 years ago

jaysencpp commented 2 years ago

Expected Behavior

When using the search functionality in the advanced filter, the user should be able to select the filter item they searched for.

Current Behavior

After searching, and the user is about to select a filter item, the Filter Group component rerenders, and the user won't be able to select any items. Relevant issue

Possible Solution

Remove onBlur on the Search component. Introduce a useClickOutside hook. Attach a ref for the whole FilterGroup the hook listens to, and if the user clicks outside of the entire FilterGroup, search component will be closed and hidden.

Steps to Reproduce

  1. Go to PBI report/Work space
  2. Open Advanced filter
  3. Choose a filter group with search option
  4. Search for something, try to select a filter item.
Gustav-Eikaas commented 6 months ago

Confirmed to still be an issue. Low value in fixing but confirmed bug