Skip to content

Commit

Permalink
[FEAT] TeamNADA#218 - 아이디로 명함 추가 실패시 키보드가 내려가지 않게 하기
Browse files Browse the repository at this point in the history
  • Loading branch information
dlwns33 committed Dec 29, 2021
1 parent ad52a55 commit fb56a39
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -94,8 +94,6 @@ class AddWithIdBottomSheetViewController: CommonBottomSheetViewController, UITex

extension AddWithIdBottomSheetViewController {
func textFieldShouldReturn(_ textField: UITextField) -> Bool {
textField.resignFirstResponder()
// 서버 연결과 더불어... 검색 결과가 없으면 bottomsheet dismiss 하지 말고 hidden 풀어주기
cardDetailFetchWithAPI(cardID: textField.text ?? "")
return true
}
Expand All @@ -112,6 +110,7 @@ extension AddWithIdBottomSheetViewController {
self.explainLabel.isHidden = false
self.explainLabel.text = "자신의 명함은 추가할 수 없습니다."
} else {
self.addWithIdTextField.resignFirstResponder()
let nextVC = CardResultBottomSheetViewController()
nextVC.cardDataModel = card.card
self.hideBottomSheetAndPresent(nextBottomSheet: nextVC, title: card.card.name, height: 574)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -227,7 +227,7 @@ class CommonBottomSheetViewController: UIViewController {
guard let presentingVC = self.presentingViewController else { return }
self.dismiss(animated: false) {
let nextVC = nextViewController
nextVC.modalPresentationStyle = .overFullScreen
nextVC.modalPresentationStyle = .fullScreen
presentingVC.present(nextVC, animated: true, completion: nil)
}
}
Expand Down

0 comments on commit fb56a39

Please sign in to comment.