Fixes #31599 - Simplify TaxonomySwitcher (#8242)
Move internals that depend on the taxonomy type into TaxonomyDropdowninstead of passing as a bunch of props.
Instead of using two states and an effect to handle filtering, using areducer lets us calculate the filtered taxonomies directly
This is inline with what we do on the server side, removes the need todo string comparisons and simplifies handling this case.
Fixes #31599 - Simplify TaxonomySwitcher (#8242)
Move internals that depend on the taxonomy type into TaxonomyDropdown
instead of passing as a bunch of props.
Instead of using two states and an effect to handle filtering, using a
reducer lets us calculate the filtered taxonomies directly
This is inline with what we do on the server side, removes the need to
do string comparisons and simplifies handling this case.