Refactor mapState to properly handle buttons
Refactor popUp