File tree Expand file tree Collapse file tree 1 file changed +9
-2
lines changed
Expand file tree Collapse file tree 1 file changed +9
-2
lines changed Original file line number Diff line number Diff line change 319319 // Display caption, image number, and closing button.
320320 Lightbox . prototype . updateDetails = function ( ) {
321321 var self = this ;
322-
322+
323+ // Enable anchor clicks in the injected caption html.
324+ // Thanks Nate Wright for the fix. @https ://github.com/NateWr
323325 if ( typeof this . album [ this . currentImageIndex ] . title !== 'undefined' && this . album [ this . currentImageIndex ] . title !== "" ) {
324- this . $lightbox . find ( '.lb-caption' ) . html ( this . album [ this . currentImageIndex ] . title ) . fadeIn ( 'fast' ) ;
326+ this . $lightbox . find ( '.lb-caption' )
327+ . html ( this . album [ this . currentImageIndex ] . title )
328+ . fadeIn ( 'fast' )
329+ . find ( 'a' ) . on ( 'click' , function ( event ) {
330+ location . href = $ ( this ) . attr ( 'href' ) ;
331+ } ) ;
325332 }
326333
327334 if ( this . album . length > 1 && this . options . showImageNumberLabel ) {
You can’t perform that action at this time.
0 commit comments