dismiss key while editing

shouldDismissOnTapOutside: check if keyboard is on screen then dismiss keyboard else dismiss view