Fix stuttering close button

Close button was present even when the chat was closed and only the chat tab was present.  This caused a stuttering effect because the width was too small to contain the cat button.