Hi @belyvolk,
You should be able to accomplish this with some custom JS to unbind the pass through clicks that occur on the caption. The below JS should accomplish this:
(function(_){
if (!_) return;
_.PortfolioTemplate.prototype.onParsedItem = _.PortfolioTemplate.prototype.onCreatedItem = function(event, template, item){
item.$el.find(".fg-caption").off("click.foogallery");
};
})(window.FooGallery);
That said it needs to be enqueued into your page to actually work. To do this you can add the following PHP snippet to your functions.php file or by using a plugin that includes snippets for you:
function foogallery_enqueue_custom_js(){ ?>
<script type="text/javascript">
(function(_){
if (!_) return;
_.PortfolioTemplate.prototype.onParsedItem = _.PortfolioTemplate.prototype.onCreatedItem = function(event, template, item){
item.$el.find(".fg-caption").off("click.foogallery");
};
})(window.FooGallery);
</script><?php
}
add_action( 'wp_footer', 'foogallery_enqueue_custom_js', 999 );
Thanks