Adding to optionaly $compile a dialog