Add close button to details

resolves #4925