Checking the mouse click event on the main wrapper so that I can divert to main node