From a5516fc0a511ff0477e8991e7873ebc4447eaf59 Mon Sep 17 00:00:00 2001 From: easyhooon Date: Sun, 1 Sep 2024 18:58:09 +0900 Subject: [PATCH] =?UTF-8?q?[refactor]=20preview=20theme=20=EC=B6=94?= =?UTF-8?q?=EA=B0=80=20=EB=B0=8F=20persistentList=20->=20immutableList?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit allGenderAgeGroups 는 변경되지 않음 --- .../component/MateRecruitCheckBox.kt | 19 +++++++++++-------- .../viewmodel/MateRecruitUiState.kt | 5 +++-- 2 files changed, 14 insertions(+), 10 deletions(-) rename feature/mate-recruit/src/main/kotlin/com/tripmate/android/feature/{recruit => mate_recruit}/component/MateRecruitCheckBox.kt (80%) rename feature/mate-recruit/src/main/kotlin/com/tripmate/android/feature/{recruit => mate_recruit}/viewmodel/MateRecruitUiState.kt (88%) diff --git a/feature/mate-recruit/src/main/kotlin/com/tripmate/android/feature/recruit/component/MateRecruitCheckBox.kt b/feature/mate-recruit/src/main/kotlin/com/tripmate/android/feature/mate_recruit/component/MateRecruitCheckBox.kt similarity index 80% rename from feature/mate-recruit/src/main/kotlin/com/tripmate/android/feature/recruit/component/MateRecruitCheckBox.kt rename to feature/mate-recruit/src/main/kotlin/com/tripmate/android/feature/mate_recruit/component/MateRecruitCheckBox.kt index d4960a47..271b4a59 100644 --- a/feature/mate-recruit/src/main/kotlin/com/tripmate/android/feature/recruit/component/MateRecruitCheckBox.kt +++ b/feature/mate-recruit/src/main/kotlin/com/tripmate/android/feature/mate_recruit/component/MateRecruitCheckBox.kt @@ -1,4 +1,4 @@ -package com.tripmate.android.feature.recruit.component +package com.tripmate.android.feature.mate_recruit.component import androidx.compose.foundation.clickable import androidx.compose.foundation.layout.Row @@ -16,6 +16,7 @@ import androidx.compose.ui.res.vectorResource import androidx.compose.ui.unit.dp import com.tripmate.android.core.designsystem.ComponentPreview import com.tripmate.android.core.designsystem.theme.Medium16_Reg +import com.tripmate.android.core.designsystem.theme.TripmateTheme import com.tripmate.android.feature.mate_recruit.R @Composable @@ -58,11 +59,13 @@ fun MateRecruitCheckBox( @ComponentPreview @Composable fun MateRecruitCheckBoxPreview() { - MateRecruitCheckBox( - text = "니와 비슷한 유형의 동행 찾기", - isSelected = false, - onSelectedChange = {}, - iconRes = R.drawable.ic_mate_type_checked, - checkedIconRes = R.drawable.ic_mate_type, - ) + TripmateTheme { + MateRecruitCheckBox( + text = "니와 비슷한 유형의 동행 찾기", + isSelected = false, + onSelectedChange = {}, + iconRes = R.drawable.ic_mate_type_checked, + checkedIconRes = R.drawable.ic_mate_type, + ) + } } diff --git a/feature/mate-recruit/src/main/kotlin/com/tripmate/android/feature/recruit/viewmodel/MateRecruitUiState.kt b/feature/mate-recruit/src/main/kotlin/com/tripmate/android/feature/mate_recruit/viewmodel/MateRecruitUiState.kt similarity index 88% rename from feature/mate-recruit/src/main/kotlin/com/tripmate/android/feature/recruit/viewmodel/MateRecruitUiState.kt rename to feature/mate-recruit/src/main/kotlin/com/tripmate/android/feature/mate_recruit/viewmodel/MateRecruitUiState.kt index 7f5a8cb9..35842ca4 100644 --- a/feature/mate-recruit/src/main/kotlin/com/tripmate/android/feature/recruit/viewmodel/MateRecruitUiState.kt +++ b/feature/mate-recruit/src/main/kotlin/com/tripmate/android/feature/mate_recruit/viewmodel/MateRecruitUiState.kt @@ -1,9 +1,10 @@ -package com.tripmate.android.feature.recruit.viewmodel +package com.tripmate.android.feature.mate_recruit.viewmodel import com.tripmate.android.core.common.extension.formatToDate import com.tripmate.android.core.common.extension.formatToTime import com.tripmate.android.domain.entity.GenderAgeGroupEntity import com.tripmate.android.feature.mate_recruit.R +import kotlinx.collections.immutable.ImmutableList import kotlinx.collections.immutable.PersistentList import kotlinx.collections.immutable.persistentListOf import java.time.LocalDate @@ -20,7 +21,7 @@ data class MateRecruitUiState( val mateRecruitTime: String = LocalTime.now(ZoneId.of("Asia/Seoul")).formatToTime(), val isMateRecruitTimeUpdated: Boolean = false, val selectedMateType: MateType = MateType.ALL, - val allGenderAgeGroups: PersistentList = persistentListOf( + val allGenderAgeGroups: ImmutableList = persistentListOf( GenderAgeGroupEntity(id = 1, textResId = R.string.same_gender, isSelected = false), GenderAgeGroupEntity(id = 2, textResId = R.string.same_age, isSelected = false), GenderAgeGroupEntity(id = 3, textResId = R.string.no_matter, isSelected = false),