WIP: 1.4 Button element

Bricks Version: 1.4-beta
Browser: Chrome 90

The beta update included an update to the button element that forces the element to always use the a tag. This appears to break containers that are also set as a link. The image below shows 2 containers: the one on the left set as a div, while the container on the right is set to a link. Both contain the same markup and the Learn More text is a button without a link.

image

Updating /includes/elements/button.php fixes the issue, around line 169 solves this issue:

$link_tag = isset($settings['link']) ? 'a' : 'span';
$output = "<" . esc_attr($link_tag) . " {$this->render_attributes('_root')}>";

And 186:

$output .= '</' . esc_attr($link_tag) . '>';

Hi Josh,
Thanks so much for the report! You’re absolutely right. Will be fixed in the final release :v:

Best regards,
timmse

@timmse Another one. Changelog – Bricks (bricksbuilder.io)