fixed: text is removed now when the last tab is closed