Hey all, I’ve run into a frustrating issue and I’m hoping someone has either a workaround or an insight into what I’m missing.
I’m using a custom query in a Bricks Query Loop to pull a specific set of media attachments from an ACF Gallery field. Everything works great with infinite scroll until I apply a filter.
Here’s what I’ve got going on:
• I’m querying images using post__in to limit to those in the ACF field.
• I’m randomizing the results with shuffle() before passing them into the query.
• I’m displaying the results with Bricks’ native filter UI, which is set to “button” style and tied to a custom taxonomy on attachments.
• I’m using Bricks’ built-in Infinite Scroll setting.
Here’s the issue:
1. Without a filter applied, infinite scroll loads additional images as expected.
2. As soon as I apply a filter (which works correctly and shows the right subset), infinite scroll stops working entirely. It might sometimes load a few more results, but it stops well short of all of them.
3. However, if I reload the page directly into the filter (e.g. by clicking a pre-filtered URL), infinite scroll works again within the filtered subset.
So it seems like after filtering, Bricks fails to recognize that more results exist and never triggers the next page load. I tried manually dispatching a scroll event after filtering with no luck.
Is this a bug, or am I missing a step to reinitialize the infinite scroll observer after filtering?
Thanks in advance.