add delay for close button event (for leaving lab) (untested)