jQuery( function ( $ ) { 'use strict' ; try { $( document.body ).on( 'gtc-enhanced-lightcase' , function ( ) { var light_cases = $( '.gtc-popup-gift-card' ) ; if ( !light_cases.length ) { return ; } light_cases.each( function ( ) { $( this ).lightcase( { href : $( this ).data( 'popup' ) , onFinish : { foo : function ( ) { lightcase.resize( ) ; } } , } ) ; } ) ; } ) ; $( document.body ).trigger( 'gtc-enhanced-lightcase' ) ; } catch ( err ) { window.console.log( err ) ; } } ) ;