support either bootstrap modal or jquery-ui dialog, strict dependancy reduced to jquery and jquery-ui-widget