Feature Requests

Got an idea for a new feature or integration? We’d love to hear it! You can find our roadmap here.

9 votes

Bricks builder integration

It would be great if the Bricks builder could be considered for integration so that you can conditionally hide elements on a page as well as using the query option to show/hide posts, or pages someone has access to.

Completed Category: Core Feature Enhancements Robert shared this idea Updated: June 29, 2022

9 thoughts on “Bricks builder integration”

  1. This is complete, however we are waiting on two filters that need to be added to Bricks in order for the integration to work. Once Bricks releases an update with that change we will release the new integration.

  2. Hi Jack… what are the filters that are needed? I’ve looked in the Bricks Builder ideas board but I couldn’t find any posts. Any idea if Bricks is going to pick up on adding the filters?

    1. Below is the email I’d sent to Thomas back in February. Haven’t heard back yet despite following up, so I’m not sure if they’re working on it or not.

      —–

      We have the integration mostly done (https://i.wpfusion.com/J35VsZ ). Here’s the integration class https://gist.github.com/verygoodplugins/3ad6870966e5be34893e36a0f53656a1.

      We did run into two places where we’d need to have a filter added. Those are at

      /bricks/includes/elements/base.php, line 88
      $this->control_groups = apply_filters( 'bricks/elements/control_groups', $this->control_groups );
      https://i.wpfusion.com/lUhPgH

      And

      /bricks/includes/elements/base.php, line 1564
      if ( apply_filters( 'bricks/elements/render', true, $this ) ) {
      $this->render();
      }

      https://i.wpfusion.com/UuCEkd

      We couldn’t figure out a way to get the control group added and conditionally display the elements without those filters, but if we’ve overlooked something please let me know.

      The only other thing was the bricks/elements/{element}/controls filter. It’d be ideal if there were a filter that applied to every element. As a temporary workaround we’re using a list_files() to get all the element slugs (https://gist.github.com/verygoodplugins/3ad6870966e5be34893e36a0f53656a1#file-class-bricks-php-L281) but it’s not ideal.

      It’d be great if we could get a

      $this->controls = apply_filters( 'bricks/elements/controls', $this->controls );

      filter also around line 88 of the Element base class so we could add controls to all elements simultaneously.

    1. At the moment Bricks doesn’t have APIs for custom form integrations, and it also doesn’t have a field mapping UI element.

      Bricks also doesn’t have an API for the media player, so an integration isn’t possible.

      If they add APIs and documentation for these things we can revisit it.

Leave a Reply to Jack Arturo Cancel Reply

Your email address will not be published. Required fields are marked *

Powered by Simple feature Requests