add open and close feature