Modifying the script kernel is bad practice (let's say you update the script - you will lose your changes). In fact, itβs better to add a piece of code after loading the library and work:
document.id('lbImage').addEvent('click', function(){ document.id('lbCloseLink').fireEvent('click'); });
source share