fixing issue with overflow of modal dialogs