refactor buttons pt1