x 로그인 버튼 제거, 언어에 관계없이 Line 로그인 버튼 보이도록 수정
This commit is contained in:
@@ -20,10 +20,6 @@ struct LoginView: View {
|
|||||||
@State private var isPasswordVisible: Bool = false
|
@State private var isPasswordVisible: Bool = false
|
||||||
@FocusState private var focusedField: FocusField?
|
@FocusState private var focusedField: FocusField?
|
||||||
|
|
||||||
private var isJapaneseLanguage: Bool {
|
|
||||||
locale.identifier.hasPrefix("ja")
|
|
||||||
}
|
|
||||||
|
|
||||||
var body: some View {
|
var body: some View {
|
||||||
BaseView(isLoading: $viewModel.isLoading) {
|
BaseView(isLoading: $viewModel.isLoading) {
|
||||||
ZStack {
|
ZStack {
|
||||||
@@ -134,36 +130,29 @@ struct LoginView: View {
|
|||||||
AppState.shared.setAppStep(step: .signUp)
|
AppState.shared.setAppStep(step: .signUp)
|
||||||
}
|
}
|
||||||
|
|
||||||
Image("ic_login_google")
|
|
||||||
.onTapGesture {
|
|
||||||
hideKeyboard()
|
|
||||||
viewModel.loginWithGoogle()
|
|
||||||
}
|
|
||||||
|
|
||||||
Image("ic_login_apple")
|
Image("ic_login_apple")
|
||||||
.onTapGesture {
|
.onTapGesture {
|
||||||
hideKeyboard()
|
hideKeyboard()
|
||||||
viewModel.loginWithApple()
|
viewModel.loginWithApple()
|
||||||
}
|
}
|
||||||
|
|
||||||
if isJapaneseLanguage {
|
Image("ic_login_google")
|
||||||
Image("ic_login_line")
|
.onTapGesture {
|
||||||
.onTapGesture {
|
hideKeyboard()
|
||||||
hideKeyboard()
|
viewModel.loginWithGoogle()
|
||||||
viewModel.loginWithLine()
|
}
|
||||||
}
|
|
||||||
|
|
||||||
Image("ic_login_x")
|
Image("ic_login_kakao")
|
||||||
.onTapGesture {
|
.onTapGesture {
|
||||||
hideKeyboard()
|
hideKeyboard()
|
||||||
}
|
viewModel.loginWithKakao()
|
||||||
} else {
|
}
|
||||||
Image("ic_login_kakao")
|
|
||||||
.onTapGesture {
|
Image("ic_login_line")
|
||||||
hideKeyboard()
|
.onTapGesture {
|
||||||
viewModel.loginWithKakao()
|
hideKeyboard()
|
||||||
}
|
viewModel.loginWithLine()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
.padding(.top, 20)
|
.padding(.top, 20)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user