fixed the close button behavior on refresh to hide itself if the footer is closed