refactoring filter UI and header