Move context menu blocking to javascript file instead