Close functionality added