Skip to content

Commit

Permalink
refactor: CategoryListScreenPreview 생성, 언어 한글로 적용(#196)
Browse files Browse the repository at this point in the history
  • Loading branch information
jay200333 committed Jan 9, 2025
1 parent c3d4139 commit bd7afe7
Showing 1 changed file with 46 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,9 @@ import androidx.compose.material3.HorizontalDivider
import androidx.compose.runtime.Composable
import androidx.compose.ui.Modifier
import androidx.compose.ui.res.stringResource
import androidx.compose.ui.tooling.preview.Preview
import androidx.compose.ui.unit.dp
import kr.boostcamp_2024.course.designsystem.ui.theme.WeQuizTheme
import kr.boostcamp_2024.course.domain.model.Category
import kr.boostcamp_2024.course.domain.model.StudyGroup
import kr.boostcamp_2024.course.domain.model.User
Expand Down Expand Up @@ -67,3 +69,47 @@ fun CategoryLazyColumn(
}
}
}

@Preview(showBackground = true, locale = "ko")
@Composable
fun CategoryListScreenPreview() {
WeQuizTheme {
CategoryListScreen(
owner = User(
id = "id",
email = "[email protected]",
name = "Ivy",
profileUrl = null,
studyGroups = listOf("id"),
),
currentGroup = StudyGroup(
id = "id",
name = "그룹이름",
studyGroupImageUrl = null,
description = null,
maxUserNum = 10,
ownerId = "id",
users = listOf("test1", "test2"),
categories = listOf(),
),
categories = listOf(
Category(
id = "id",
name = "카테고리 테스트1",
quizzes = listOf(),
description = null,
categoryImageUrl = null,
),
Category(
id = "id2",
name = "카테고리 테스트2",
quizzes = listOf(),
description = null,
categoryImageUrl = null,
),
),
createCategoryClick = { _, _ -> },
categoryItemClick = { _, _ -> },
)
}
}

0 comments on commit bd7afe7

Please sign in to comment.