refactored
made so that when filter clicked post form hides