Skip to content

Instantly share code, notes, and snippets.

@carlosonweb
Last active December 21, 2023 19:38
Show Gist options
  • Star 5 You must be signed in to star a gist
  • Fork 3 You must be signed in to fork a gist
  • Save carlosonweb/58559f7821f1a79a106b9d264b8a2071 to your computer and use it in GitHub Desktop.
Save carlosonweb/58559f7821f1a79a106b9d264b8a2071 to your computer and use it in GitHub Desktop.
Make a BB Column Clickable
/**
* Makes a BB Column clickable.
* Pre-requisite: There must be an A Tag contained within the column element.
*/
(function($){
// Exit if BB layout is in edit mode.
if ( 'undefined' != typeof window.FLBuilderConfig ) {
return;
}
$('.clickable-col').css('cursor', 'pointer');
$('.clickable-col').on('click', function(event){
$(this).find('a')[0].click();
});
$('.clickable-col a').on('click', function(event){
event.stopPropagation();
});
})(jQuery);
@carlosonweb
Copy link
Author

@zackpyle Awesome code! Thanks for sharing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment