NO BUG: WP Grid Builder facet issues with looped component

WP Grid Builder facet element, for category filtering, does not work properly with components. The posts get duplicated, when a category gets selected.

Setup

  • Archive template (any archive page should do)
  • Query looped Component (is main query active)
  • WP Grid Builder Facet to filtering post category with buttons

Result/Issues

  • Looped component query not selectable in WP Grid Builder Facet element
  • Workaround: Copying component ID and manually referencing ID in Bricks, leads to duplication of posts, when a category gets selected

Workaround: Don’t use components for filtered grids.

Hi @Maexxx,

It appears that this is related to WPGridBuilder integration, so it’s probably best to contact them because they are the one maintaining it.
But the components are new and still in the experimental phase, so some issues are expected. :crossed_fingers:

I will set this topic to no-bug for now, as it does not seem to be a bug on Bricks side.

Best regards,
Matej

I am not sure on which side it is. Thought the data that WP grid Builder works with, should be the same, no matter if it is a compknent or not. So I am not sure this is a WB GB issue.

Can you also reproduce the same with our filters? If yes, then we will absolutely have a look at it, and figure out what is happening.
But, if it’s only happening when using WPGB, then it’s very likely that WPGB is not yet compatible with the way components work, and only they can test, check their code and identify the issue.

Best regards,
Matej

With Bricks 2.0 beta, I don’t understand why plugin developers should need to adapt anything, when I use my Event card component with a query loop property.

I’d love to just create an Event card component put a query loop over it and it’s done.

The problem seems to be the “Select a grid or element to filter”, which expects the ID of the looped HTML element, which is not the component’s Bricks ID.

Hi @Maexxx,

like I explained above, components are a new way how the structure is handled and depending on how WP Grid Builder is integrated, they will need to adapt.
It will still work for normal elements like before.

Matej