Skip to content

Commit

Permalink
[EuiSelectable] Fix incorrect aria-posinset indices (#6571)
Browse files Browse the repository at this point in the history
* [setup/tech debt] Switch from Enzyme to RTL

- I'm doing this because I'll need RTL's `rerender` props setting in the future, which Enzyme's `render` does not support

* Fix incorrectly calculated calculate aria set attributes

- this new logic correctly accounts for group labels not at the start of the options array

+ perf bonus - this array iteration now only happens once per rerender, as opposed to happening on every single item/option render

- could likely be further optimized to only rerun when `visibleOptions` or `options` change, but I think this incremental improvement is fine for now

* [REVERT ME] Staging testing for inspecting `aria-posinset`

* changelog

* Revert "[REVERT ME] Staging testing for inspecting `aria-posinset`"

This reverts commit ad05c15.
  • Loading branch information
cee-chen authored Feb 2, 2023
1 parent 5c68ed9 commit f97cd0c
Show file tree
Hide file tree
Showing 4 changed files with 768 additions and 195 deletions.
Loading

0 comments on commit f97cd0c

Please sign in to comment.