Adjusting click outside modal behaviour.