diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml index 753b97e1..a692d1b1 100644 --- a/app/src/main/AndroidManifest.xml +++ b/app/src/main/AndroidManifest.xml @@ -56,7 +56,8 @@ + android:screenOrientation="portrait" + android:windowSoftInputMode="adjustResize" /> + android:screenOrientation="portrait" + android:windowSoftInputMode="adjustResize" /> + binding.btnDeleteText.isVisible = hasFocus && (state != EditTextState.EMPTY) + } + } + private fun checkTextAvailable() { binding.etEmojiCounterEtContent.doAfterTextChanged { text -> val len = text.toString().getGraphemeLength() diff --git a/presentation/src/main/java/com/going/presentation/onboarding/signup/SignUpActivity.kt b/presentation/src/main/java/com/going/presentation/onboarding/signup/SignUpActivity.kt index 17117ccc..6fc530f4 100644 --- a/presentation/src/main/java/com/going/presentation/onboarding/signup/SignUpActivity.kt +++ b/presentation/src/main/java/com/going/presentation/onboarding/signup/SignUpActivity.kt @@ -7,11 +7,9 @@ import androidx.lifecycle.flowWithLifecycle import androidx.lifecycle.lifecycleScope import com.going.domain.entity.AuthState import com.going.presentation.R -import com.going.presentation.dashboard.DashBoardActivity import com.going.presentation.databinding.ActivitySignUpBinding import com.going.presentation.tendency.splash.TendencySplashActivity import com.going.presentation.util.initOnBackPressedListener -import com.going.presentation.util.navigateToScreenClear import com.going.ui.base.BaseActivity import com.going.ui.extension.setOnSingleClickListener import com.going.ui.extension.toast @@ -83,8 +81,12 @@ class SignUpActivity : TendencySplashActivity.createIntent( this, TendencySplashActivity.TENDENCY - ).apply { startActivity(this) } + ).apply { + startActivity(this) + finish() + } } + AuthState.FAILURE -> toast(getString(R.string.server_error)) AuthState.OTHER_PAGE -> return@onEach } diff --git a/presentation/src/main/java/com/going/presentation/profile/edit/ProfileEditViewModel.kt b/presentation/src/main/java/com/going/presentation/profile/edit/ProfileEditViewModel.kt index 4ccb9a27..5735bff2 100644 --- a/presentation/src/main/java/com/going/presentation/profile/edit/ProfileEditViewModel.kt +++ b/presentation/src/main/java/com/going/presentation/profile/edit/ProfileEditViewModel.kt @@ -56,7 +56,7 @@ class ProfileEditViewModel @Inject constructor( private fun checkIsValueChanged() { _isValueChanged.value = - nowName.length <= getMaxNameLen() && nowInfo.length <= getMaxInfoLen() && (isInfoChanged || isNameChanged) + nowName.isNotBlank() && nowName.length <= getMaxNameLen() && nowInfo.isNotBlank() && nowInfo.length <= getMaxInfoLen() && (isInfoChanged || isNameChanged) } fun patchUserInfo() { diff --git a/presentation/src/main/java/com/going/presentation/profile/my/ProfileActivity.kt b/presentation/src/main/java/com/going/presentation/profile/my/ProfileActivity.kt index cc3af0af..04b97f6e 100644 --- a/presentation/src/main/java/com/going/presentation/profile/my/ProfileActivity.kt +++ b/presentation/src/main/java/com/going/presentation/profile/my/ProfileActivity.kt @@ -35,7 +35,6 @@ class ProfileActivity : override fun onCreate(savedInstanceState: Bundle?) { super.onCreate(savedInstanceState) - getUserInfo() observeUserInfoState() initBackBtnClickListener() initSaveImgBtnClickListener() @@ -46,6 +45,7 @@ class ProfileActivity : override fun onResume() { super.onResume() getUserInfo() + setFragmentHeight() scrollTop() } @@ -80,6 +80,7 @@ class ProfileActivity : if (profileViewModel.profileId.value != -1) { viewProfileEmpty.isVisible = false + viewProfile.isVisible = true UserTendencyResultList[number].apply { ivProfile.load(profileImage) { transformations(CircleCropTransformation()) diff --git a/presentation/src/main/java/com/going/presentation/profile/participant/ParticipantProfileActivity.kt b/presentation/src/main/java/com/going/presentation/profile/participant/ParticipantProfileActivity.kt index 4e7edf31..9c10e4ba 100644 --- a/presentation/src/main/java/com/going/presentation/profile/participant/ParticipantProfileActivity.kt +++ b/presentation/src/main/java/com/going/presentation/profile/participant/ParticipantProfileActivity.kt @@ -95,12 +95,7 @@ class ParticipantProfileActivity : btnTripProfileDownload.isVisible = this && profile.result != -1 btnProfileEdit.isVisible = this - if (!this) tvTripProfileTitle.setText( - getString( - R.string.participant_profile_friend_title, - profile.name - ) - ) + if (!this) tvTripProfileTitle.text = getString(R.string.participant_profile_friend_title) } } } diff --git a/presentation/src/main/java/com/going/presentation/profile/participant/profilecharacter/ParticipantProfileCharacterFragment.kt b/presentation/src/main/java/com/going/presentation/profile/participant/profilecharacter/ParticipantProfileCharacterFragment.kt index 1b458c3f..e25ad7da 100644 --- a/presentation/src/main/java/com/going/presentation/profile/participant/profilecharacter/ParticipantProfileCharacterFragment.kt +++ b/presentation/src/main/java/com/going/presentation/profile/participant/profilecharacter/ParticipantProfileCharacterFragment.kt @@ -13,8 +13,8 @@ import com.going.presentation.designsystem.textview.ChartTextView import com.going.presentation.profile.participant.ParticipantProfileViewModel import com.going.presentation.tendency.result.UserTendencyResultList import com.going.presentation.tendency.splash.TendencySplashActivity -import com.going.presentation.util.navigateToScreenClear import com.going.ui.base.BaseFragment +import com.going.ui.extension.setOnSingleClickListener import com.going.ui.extension.toast import dagger.hilt.android.AndroidEntryPoint import kotlinx.coroutines.flow.launchIn @@ -32,6 +32,7 @@ class ParticipantProfileCharacterFragment : setViewModel() btnParticipantProfileEmptyOwnerClickListener() + btnTripProfileRestartClickListener() } private fun setViewModel() { @@ -53,6 +54,9 @@ class ParticipantProfileCharacterFragment : UserTendencyResultList[result].run { ivTripProfileBig.load(resultImage) + tvTripProfileType.text = profileTitle + tvTripProfileSubType.text = profileSubTitle + tvTripProfileTag1.text = getString(R.string.tag, tags[0]) tvTripProfileTag2.text = getString(R.string.tag, tags[1]) tvTripProfileTag3.text = getString(R.string.tag, tags[2]) @@ -73,7 +77,19 @@ class ParticipantProfileCharacterFragment : private fun btnParticipantProfileEmptyOwnerClickListener() { binding.btnParticipantProfileEmptyOwner.setOnClickListener { - requireActivity().navigateToScreenClear() + TendencySplashActivity.createIntent( + requireActivity(), + TendencySplashActivity.PROFILE + ).apply { startActivity(this) } + } + } + + private fun btnTripProfileRestartClickListener() { + binding.btnTripProfileRestart.setOnSingleClickListener { + TendencySplashActivity.createIntent( + requireActivity(), + TendencySplashActivity.PROFILE + ).apply { startActivity(this) } } } diff --git a/presentation/src/main/java/com/going/presentation/todo/ourtodo/checkfriends/CheckFriendsViewHolder.kt b/presentation/src/main/java/com/going/presentation/todo/ourtodo/checkfriends/CheckFriendsViewHolder.kt index 712e26ef..f85b2f25 100644 --- a/presentation/src/main/java/com/going/presentation/todo/ourtodo/checkfriends/CheckFriendsViewHolder.kt +++ b/presentation/src/main/java/com/going/presentation/todo/ourtodo/checkfriends/CheckFriendsViewHolder.kt @@ -26,7 +26,8 @@ class CheckFriendsViewHolder( 4 -> R.drawable.img_profile_8 5 -> R.drawable.img_profile_5 6 -> R.drawable.img_profile_7 - else -> R.drawable.img_profile_3 + 7 -> R.drawable.img_profile_3 + else -> R.drawable.img_profile_guest } ivTodoFriend.load(profileImage) { transformations(CircleCropTransformation()) diff --git a/presentation/src/main/res/layout/activity_participant_profile.xml b/presentation/src/main/res/layout/activity_participant_profile.xml index 382f40a1..beef18c6 100644 --- a/presentation/src/main/res/layout/activity_participant_profile.xml +++ b/presentation/src/main/res/layout/activity_participant_profile.xml @@ -89,25 +89,25 @@ android:layout_width="wrap_content" android:layout_height="0dp" android:layout_marginStart="24dp" - android:layout_marginTop="23dp" android:src="@drawable/img_profile_guest" app:civ_border_color="@color/gray_100" app:civ_border_width="1dp" - app:layout_constraintBottom_toTopOf="@id/view_gray" app:layout_constraintDimensionRatio="1" app:layout_constraintStart_toStartOf="parent" - app:layout_constraintTop_toTopOf="parent" /> + app:layout_constraintTop_toTopOf="@id/tv_profile_name" + app:layout_constraintBottom_toBottomOf="@id/tv_profile_one_line"/> @@ -142,11 +141,12 @@ android:id="@+id/view_gray" android:layout_width="wrap_content" android:layout_height="8dp" - android:layout_marginTop="22dp" + android:layout_marginTop="26dp" android:background="@color/gray_50" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintStart_toStartOf="parent" - app:layout_constraintTop_toBottomOf="@id/iv_profile" /> + app:layout_constraintTop_toBottomOf="@id/tv_profile_one_line" + app:layout_constraintBottom_toBottomOf="parent"/> diff --git a/presentation/src/main/res/layout/activity_profile.xml b/presentation/src/main/res/layout/activity_profile.xml index 52f24fd7..db7a617d 100644 --- a/presentation/src/main/res/layout/activity_profile.xml +++ b/presentation/src/main/res/layout/activity_profile.xml @@ -82,25 +82,25 @@ android:layout_width="wrap_content" android:layout_height="0dp" android:layout_marginStart="24dp" - android:layout_marginTop="23dp" android:src="@drawable/img_profile_guest" app:civ_border_color="@color/gray_100" app:civ_border_width="1dp" - app:layout_constraintBottom_toTopOf="@id/view_gray" app:layout_constraintDimensionRatio="1" app:layout_constraintStart_toStartOf="parent" - app:layout_constraintTop_toTopOf="parent" /> + app:layout_constraintTop_toTopOf="@id/tv_profile_name" + app:layout_constraintBottom_toBottomOf="@id/tv_profile_one_line"/> + app:layout_constraintTop_toBottomOf="@id/tv_profile_one_line" + app:layout_constraintBottom_toBottomOf="parent"/> - - + - + - + + + diff --git a/presentation/src/main/res/values/strings.xml b/presentation/src/main/res/values/strings.xml index d651c56d..ca019eef 100644 --- a/presentation/src/main/res/values/strings.xml +++ b/presentation/src/main/res/values/strings.xml @@ -6,15 +6,15 @@ %s Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum. - 서버 통신에 실패했습니다 + 서버 통신에 실패했어요 닉네임에는 공백만 입력할 수 없어요 - 닉네임은 3자 이하여야 합니다 - 자기소개는 20자 이하여야 합니다 - 여행 이름은 15자 이하여야 합니다 - 할일은 15자 이하여야 합니다 + 닉네임은 3자 이하여야 해요 + 자기소개는 20자 이하여야 해요 + 여행 이름은 15자 이하여야 해요 + 할일은 15자 이하여야 해요 제목에는 공백만 입력할 수 없어요 - 메모는 1000자 이하여야 합니다 - 종료일이 시작일보다 빨라야합니다 + 메모는 1000자 이하여야 해요 + 종료일이 시작일보다 빨라야해요 해당 기능은 추후 업데이트 예정이에요 :) @@ -23,7 +23,7 @@ 개인정보처리방침 - 버튼을 한번 더 누르면 종료됩니다 + 버튼을 한번 더 누르면 종료돼요 #%s %1$d/%2$d @@ -181,10 +181,10 @@ 두릅이 나는 두릅이 좋다. 다시 해볼래요 - 존재하지 않는 여행입니다. + 존재하지 않는 여행이에요 프로필 수정 이미지가 저장되었어요\n친구들에게 공유해보세요! - 이미지를 저장할 수 없습니다\n안드로이드 버전을 확인해주세요 + 이미지를 저장할 수 없어요\n안드로이드 버전을 확인해주세요 나의 여행 캐릭터 여행 취향 태그 @@ -192,7 +192,7 @@ 여행 캐릭터 검사하러 가기 여행 캐릭터 검사를 아직 진행하지 않았어요 지금 바로 나를 대신 할 여행 캐릭터를 만나보세요! - %s의 여행 프로필 + 친구 여행 프로필 여행 입장하기 @@ -200,9 +200,9 @@ 친구에게 받은 초대코드 6자리를 입력해 주세요 잘못된 초대코드예요 초대코드 확인하기 - 존재하지 않는 여행입니다 - 입장할 수 있는 최대 인원은 6명입니다 - 이미 존재하는 참가자입니다 + 존재하지 않는 여행이에요 + 입장할 수 있는 최대 인원은 6명이에요 + 이미 존재하는 참가자에요 초대받은 여행이 맞는지\n 확인해 주세요 @@ -256,7 +256,7 @@ %1$d.%2$d.%3$d 시작일을 먼저 입력해 주세요 여행방 나가기 - 나가기를 하면 정보가 모두 삭제되고,\n 여행 목록에서도 삭제됩니다 + 나가기를 하면 정보가 모두 삭제되고,\n 여행 목록에서도 삭제돼요 나가기 취소 여행 이름에는 공백만 입력할 수 없어요