Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FIX] #124 - 온보딩 카드 간격, 바운스 수정 #125

Merged
merged 2 commits into from
Dec 10, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,18 @@ extension BackCardCreationCollectionViewCell {
private func setNotification() {
NotificationCenter.default.addObserver(self, selector: #selector(textFieldDidChange(_:)), name: UITextField.textDidChangeNotification, object: nil)
}
private func checkBackCardStatus() {
backCardCreationDelegate?.backCardCreation(withRequired: [
"isMincho": isMinchoCollectionView.indexPathsForSelectedItems == [[0, 0]] ? true: false,
"isSoju": isSojuCollectionView.indexPathsForSelectedItems == [[0, 0]] ? true: false,
"isBoomuk": isBoomukCollectionView.indexPathsForSelectedItems == [[0, 0]] ? true: false,
"isSauced": isSaucedCollectionView.indexPathsForSelectedItems == [[0, 0]] ? true: false
], withOptional: [
"firstTMI": firstTMITextField.text ?? "",
"secondTMI": secondTMITextField.text ?? "",
"thirdTMI": thirdTMITextField.text ?? ""
])
}
static func nib() -> UINib {
return UINib(nibName: Const.Xib.backCardCreationCollectionViewCell, bundle: Bundle(for: BackCardCreationCollectionViewCell.self))
}
Expand Down Expand Up @@ -170,26 +182,7 @@ extension BackCardCreationCollectionViewCell: UICollectionViewDelegate {
} else {
backCardCreationDelegate?.backCardCreation(requiredInfo: false)
}
backCardCreationDelegate?.backCardCreation(withRequired: [
"isMincho": isMinchoCollectionView.indexPathsForSelectedItems == [[0, 0]] ? true: false,
"isSoju": isSojuCollectionView.indexPathsForSelectedItems == [[0, 0]] ? true: false,
"isBoomuk": isBoomukCollectionView.indexPathsForSelectedItems == [[0, 0]] ? true: false,
"isSauced": isSaucedCollectionView.indexPathsForSelectedItems == [[0, 0]] ? true: false
], withOptional: [
"firstTMI": firstTMITextField.text ?? "",
"secondTMI": secondTMITextField.text ?? "",
"thirdTMI": thirdTMITextField.text ?? ""
])
}
static func nib() -> UINib {
return UINib(nibName: Const.Xib.backCardCreationCollectionViewCell, bundle: Bundle(for: BackCardCreationCollectionViewCell.self))
}
}

// MARK: - UICollectionViewDelegate
extension BackCardCreationCollectionViewCell: UICollectionViewDelegate {
func collectionView(_ collectionView: UICollectionView, didSelectItemAt indexPath: IndexPath) {
checkBackCradStatus()
checkBackCardStatus()
}
}

Expand Down Expand Up @@ -247,7 +240,7 @@ extension BackCardCreationCollectionViewCell: UITextFieldDelegate {
}
func textFieldDidEndEditing(_ textField: UITextField) {
backCardCreationDelegate?.backCardCreation(endEditing: true)
checkBackCradStatus()
checkBackCardStatus()
textField.borderWidth = 0
}
func textFieldShouldReturn(_ textField: UITextField) -> Bool {
Expand Down
1 change: 0 additions & 1 deletion NADA-iOS-forRelease/Sources/SceneDelegate.swift
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ class SceneDelegate: UIResponder, UIWindowSceneDelegate {
window = UIWindow(frame: windowScene.coordinateSpace.bounds)
window?.windowScene = windowScene
window?.rootViewController = UIStoryboard(name: Const.Storyboard.Name.tabBar, bundle: nil).instantiateViewController(withIdentifier: Const.ViewController.Identifier.tabBarViewController)
// window?.rootViewController = UIStoryboard(name: Const.Storyboard.Name.login, bundle: nil).instantiateViewController(withIdentifier: Const.ViewController.Identifier.loginViewController)
Comment on lines 25 to -26
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

탭바 탭바 탭바 탭바로~ 가네요~

window?.makeKeyAndVisible()

IQKeyboardManager.shared.enable = true
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,12 @@ class OnboardingViewController: UIViewController {

private var currentIndex: CGFloat = 0
private let onboardingList = ["onboarding01", "onboarding02", "onboarding03", "onboarding04"]
// TODO: - 🪓 선배륌들 이런 방법도있어서 써봤어여 사이즈같은 쓰이는 숫자들 여기서 다뤄도 좋을거 같아여..
private enum Size {
static let cellWidth: CGFloat = 327
static let cellHeigth: CGFloat = 327
static let cellTopInset: CGFloat = 198
static let cellBottomInset: CGFloat = 208
// TODO: - 나커톤 때 라이브코딩 쇼쇼쇼
static let cellLineSpacing: CGFloat = 85
// TODO: - 기기대응응 필요.
static let topSafeArea: CGFloat = 44
Comment on lines 16 to 22
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

사이즈 사이즈 사이즈~ 사이즈~ 사이즈 조정~ 이거 저번에 했던 그 방식에서 숫자만 변경된건가요!!! !!! !! !! ! ! !

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

숫자 변경도 없습니닷!

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

감사 감사 감사 감사합니다 ~

}

Expand Down