I think I may have narrowed down a taxonomy filter ordering bug?
(probably missing something obvi)
Environment:
-
Bricks v2-3-1
-
Tested in Brave (latest), Chrome on macOS (latest), and Chrome on Android (latest)
sorry i couldn’t figure out how to find the version numbers
-
WooCommerce archive template using one shared template for:
- main shop archive
- taxonomy archives for brand, product category & product tag such as Kitsch & Cult + King & Accessories
Setup:
-
Product loop uses is_archive_main_query = true
-
Taxonomy Filter Selects are set to:
-
Order by = count
-
Order = desc
-
-
Pagination AJAX is enabled
Expected behavior:
On every archive context, the Filter Select taxonomy options should be sorted by the current archive-specific counts in descending order.
Actual behavior:
-
On the main shop page, the Target filter appears correctly sorted by count descending.
-
On taxonomy archive pages like this one & this one, the counts themselves update correctly for that archive context.
-
However, the displayed term order does not re-sort by those updated archive-specific counts.
What it looks like:
It appears the taxonomy filter may be keeping the main shop term order, then replacing the counts for the current archive, without re-sorting after the counts change.
Example:
Main shop starts like this:
- curly hair (38)
- blonde hair (27)
- damaged hair (25)
- fine hair (19)
- thinning hair (17)
- natural styling (13)
On /brand/kitsch, the counts update, but the order appears preserved instead of being re-sorted by the new counts:
- curly hair (15)
- blonde hair (7)
- damaged hair (9)
- fine hair (7)
- thinning hair (5)
- natural styling (9)
So on the tax archive pages, the counts seem correct, but the list is not actually ordered by count descending.
Additional note:
When I compare the shared terms between /apothecary and /brand/kitsch, the relative order looks preserved from the main shop page, even though the archive-specific counts have changed. That is why I suspect the counts are being refreshed, but the sort order is not being recalculated.
I’m sure I’m missing something already explained (did try and find the answer for a while tho lol) and apologize in advance if it’s something obvious or a mis-set somewhere ![]()