-
Notifications
You must be signed in to change notification settings - Fork 0
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
Feature/#13 seats screen UI #16
Conversation
โฆN-ANDROID-CGV into ui/#7-seats-screen-components
โฆN-ANDROID-CGV into UI/#7-seats-screen-components
โฆPT-all/35-COLLABORATION-ANDROID-CGV into feature/#13-seats-screen-ui
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์์ปคํค ํ๋๋ผ ๋ฐ์ ํ ๋ฐ.. ์ด๋ฌ๋ค ์ ๋ฌ๋ค ํ๋ ๋ฆฌ๋๋ผ ๋ฏธ์ํด...!๐
|
||
Box( | ||
modifier = modifier | ||
.size(width = 90.dp, height = 64.dp) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์ด๋ ๊ฒ ์ปดํฌ๋ํธ ์ฌ์ด์ฆ๋ฅผ ๊ณ ์ dp๋ก ์ฃผ๋ ๊ฒ์ด ์๋ ์ปดํฌ๋ํธ ์์๋ค์ ํจ๋ฉ ๊ฐ์ผ๋ก ์กฐ์ ํด์ค ํ ์คํฌ๋ฆฐ์ ๋ฃ์์ ๋, ์ ์ฒด ์คํฌ๋ฆฐ์์์ ๋ํผ๋ก ์กฐ์ ํด์ฃผ๋ฉด ๋ ์ข์ ๊ฑฐ ๊ฐ์์
startTime: LocalDateTime, | ||
endTime: LocalDateTime, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์์ง๋ฐ์ด์ผ... ๋ด๊ฐ ๋ฏธ์ํด...
์ค๋ ์๋ฒ ํต์ ์ ๋ฐฐ์ฐ๋ฉฐ ์๊ฐํ์๋๋ฐ,
์ด ๋ถ๋ถ string์ผ๋ก ์ฃผ๋ ๊ฒ์ด ๋ง๋ ๊ฒ ๊ฐ์ .. ๋๋ ๋ค ๊ณํ์ด ์์๊ตฌ๋..
๋ชป๋ ๋ฆฌ๋๋ผ ๋ฏธ์ํด....
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ใ ใ ใ ใ ๋ท๊ฑธ์์ ๋ต ...๐ซข ๊ด์ฐจ๋ ์ด๋ฌ๋ฉด์ ๋ ๋ฐฐ์ฐ๊ฒ ๋๋ ๊ฒ ๊ฐ๋น!!
val timeFormatter = DateTimeFormatter.ofPattern("HH:mm") | ||
val formattedStartTime = startTime.format(timeFormatter) | ||
val formattedEndTime = endTime.format(timeFormatter) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์ด ๋ถ๋ถ์ด ์๊ฐ ํฌ๋ฉงํ
๋ถ๋ถ์ด์ฌ์ ๋น์ฆ๋์ค ๋ก์ง์ ๊ฐ๊น๋ค๋ ์๊ฐ์ด ์ง๊ธ ๋ค์์ฌ์ต๋๋ค.. ์๋ฒ ํต์ ํ ๋ ๋ทฐ๋ชจ๋ธ ๋ถ๋ถ์์ ์๊ฐ ํฌ๋ฉงํ
์ ํด์ฃผ๋ฉด ๋ ๊ฒ ๊ฐ์ฌ์ต๋๋ค..
๋ฏธ์ํ์ต๋๋ค....๐ฅน
modifier: Modifier = Modifier, | ||
content: String | ||
){ | ||
|
||
Box( | ||
modifier = Modifier |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
modifier: Modifier = Modifier, | |
content: String | |
){ | |
Box( | |
modifier = Modifier | |
modifier: Modifier = Modifier, | |
content: String | |
){ | |
Box( | |
modifier = modifier |
|
||
Box( | ||
modifier = modifier | ||
.size(width = 66.dp, height = 24.dp) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์ฌ๊ธฐ๋ ์ด๋ ๊ฒ ์ ์ฒด ์ฌ์ด์ฆ๋ฅผ ํ์ ์ง์ด ์ฃผ๋ ๊ฒ์ด ์๋, ํจ๋ฉ์ผ๋ก ์กฐ์ ํ๋ฉด ์ข์ ๊ฑฐ ๊ฐ์์!
ํน์ฌ๋ ์ด๋ ๊ฒ ํ์ ์ด์ ๊ฐ ๋ฐ๋ก ์์๊น์?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ํ๋์ฝ๋ฉํ ๋ค๋ฅธ ์ด์ ๊ฐ ์๋ ๊ฑด ์๋๊ณ , ํจ๋ฉ๊ฐ์ ์ธ์๋ก ์ฃผ์ด์ ๋์ ์ผ๋ก ํฌ๊ธฐ๊ฐ ์กฐ์ ๋๋๋ก ํ๋ ๋ฐฉ์์ ๋ ์ผ๋ฐ์ ์ผ๋ก ์ฌ์ฉํ๋ค๋ ์ฌ์ค์ ์ ๋ชฐ๋์ด์..! ์ธ์์ฐ๊ฐ ๋ฒํผ ๊ตฌํํ ๊ฑฐ ๋ณด๊ณ ์๋ฒฝํ๊ฒ ์ดํดํด๊ฐ๋๋น.. ๐คฉ
Text( | ||
text = price, | ||
style = Typography.head8_b_20, | ||
color = Color.Black | ||
) | ||
Text( | ||
text = "์", | ||
style = Typography.head4_b_15, | ||
color = Color.Black |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์ฌ๊ธฐ ์ปฌ๋ฌ๋์!
Text( | ||
text = label, | ||
style = Typography.body4_m_15, | ||
color = Color.Black |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์ฌ๊ธฐ ์ปฌ๋ฌ ํ๋ฒ ๋ด์ฃผ์ธ์ฉ
contentAlignment = Alignment.Center | ||
) { | ||
Icon( | ||
painter = painterResource(id = R.drawable.ic_seats_minus), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์์ด์ฝ ํ์ธํฐ ๋ฆฌ์์ค ๋ง๊ณ ๋ฒกํฐ๋ก ์ฌ์ฉํด์ฃผ์ธ์!
ํน์ ic_seats_minus๊ฐ png๋ผ๋ฉด painterResource๋ก ํด์ฃผ์
์!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
๋๋ถ์ ์ปดํฌ์ฆ์์ ๋ฒกํฐ ์์ด์ฝ์ ์ฌ์ฉํ ๋๋ painterResoucre๋ณด๋ค vectorResource ์ฌ์ฉํ๋ ๊ฒ์ด ๋ ์ต์ ํ๋ ๋ฐฉ๋ฒ์ด๋ผ๋ ์ฌ์ค ์์๊ฐ๋๋น . .
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์ฌ์ค ์ด๋ฆ๋ถํฐ painterResource์ธ๋ฐ ๋ด๊ฐ ๋ ์์ฌ์์ด ์ฌ์ฉํ ๊ฒ ๊ฐ๋น. . ๋ฐ๋ณด
modifier = Modifier | ||
.padding(horizontal = 5.dp) | ||
.size(width = 34.dp, height = 28.dp) | ||
.background(Color.White, RoundedCornerShape(8.dp)), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์ฌ๊ธฐ๋ ์์ ํ๋ฒ๋ง ํ์ธํ๊ธฐ!!
Icon( | ||
painter = painterResource(id = R.drawable.ic_seats_plus), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์ฌ๊ธฐ๋ painterResource ํ์ธํด์ฃผ์ ์!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์ถ๊ฐ์ ์ผ๋ก seats ๋ถ๋ถ์์๋ง ์ฌ์ฉํ๋ component๋ component ํจํค์ง๋ฅผ ๋ฐ๋ก ๋ง๋ค์ด์ ๊ทธ ์์ ํ์ผ๋ค์ ๋ฃ์ด์ฃผ์ธ์!!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์งฑ์งฑ๋งจ ๋ฆฌ๋ทฐ ๋ต์ฅ ์ ํ์ธํ ๊ฒ~
){ | ||
//์๊ฐ ๋ถ๋ถ | ||
Row( | ||
modifier = modifier |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
modifier๋ฅผ ๊ณ์ ๋ฌผ๋ ค๋ฐ์ผ๋ฉด ๊ณ์ฐํ ๋ ์กฐ๊ธ ํ๋ค์ง ์๋์?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์ธ์์ด๊ฐ modifier: Modifier = Modifier, ์ด๊ฑฐ ๋ชจ๋ ์ปดํฌ๋ํธ์ ์ถ๊ฐํด์ฃผ๋ผ๊ณ ํด์ ๋ค ์ธ์๋ก ๋๊ฒจ๋ฐ์ modifier๋ฅผ ๋ฌผ๋ ค๋ฐ์ ์ฌ์ฉํ๋ ๊ฒ์ผ๋ก ํด๋๋๋ฐ, ์์์์ modifier๋ฅผ ์ธ์๋ก ๋๊ฒจ๋ฐ๊ธฐ๋ง ํ๊ตฌ ์ฌ์ฉํ์ง ์๋๊ฑด๊ฐ์ฉ??
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์ผ๋จ ์ ๋ ๋ค ์ถ๊ฐ๋ ํด๋๊ตฌ ๋ถ๋ชจ๊ณ์ธต(?)์ ์ํฅ์ ๋ฐ๋ ์์ด๋ค์ด ์์๋๋ง modifier๋ฅผ ์ฐ๊ธดํด์
์๋ฅผ ๋ค๋ฉด ๋ถ๋ชจ๊ฐ ํ ๋น๋ฐ์ width์ 1/4์ ๋ฐ๊ณ ์ถ์ผ๋ฉด ๋ถ๋ชจ ์ปดํฌ๋ํธ๋ก ๋ถํฐ Modifier.weight(0.25f) ๋ฅผ ๋ฌผ๋ ค๋ฐ์์ ์ฐ๋ ๋ฐฉ์์ผ๋ก??
์ธ์์ด ๋ฐฉ๋ฒ์ด ๋ ๋ง์ ์๋! ์ ๋ญ๊ฐ ์ ๊ฒฝ์ธ๊ฒ ๋ง์์ ธ์ ์์ฐ๊ฒ ๋๋๋ผ๊ตฌ์
){ | ||
Column( | ||
modifier = modifier.fillMaxSize(), | ||
verticalArrangement = Arrangement.SpaceBetween |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์ด ๋ถ๋ถ์ด ํ์ํ ๊น์?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์ง์ง ๋นผ๋ ๊ด์ฐฎ๋ค์..๐ซข ์์ง๋ ์ ๋ ฌ์ ์ต์ํ์ง ์์์ spacer๋ align์ ๋์ง๋์ง ๋ถ์ด์ง ์๊ณ ๋ ์์๊ณ ๊น๋ํ๊ฒ ๋ฐฐ์นํ๋ ๋ฒ์ ์ ๋ชจ๋ฅด๊ฒ ์ด์ใ ใ ..
verticalAlignment = Alignment.CenterVertically, | ||
horizontalArrangement = Arrangement.SpaceAround, | ||
){ | ||
if(isMorning){ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
๋๋ฌด ์ข๋ค์
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์ด ํ์ผ์ ์ ๊ฐ ๋ ๊ณ ์ณ๋๊ฒ ์ต๋๋ค ๋ซ๊ธฐ ์์ด์ฝ ์๋ ๋ฒ์ ์ผ๋ก
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์ธ์๋ ์ฝ๋๋ฆฌ๋ทฐ๋ ๋ฐ์ํด๋์ต๋๋น (cgvButton์ฒ๋ผ ์ธ์๋ก ํจ๋ฉ๊ฐ ๋ฐ์์ ๋์ ์ผ๋ก ์นฉ ํฌ๊ธฐ ๋ณ๊ฒฝ๋๋๋ก)
|
||
@OptIn(ExperimentalMaterial3Api::class) | ||
@Composable | ||
fun SeatConfirmationModal( |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
preview๋ฅผ ๋ณด๋ modal์ ์๋จ์ ๋น๊ธธ ์ ์๋ ํ์?๊ฐ ๋จ์์๋ ๊ฑฐ ๊ฐ์๋ฐ ์ ๊ฑฐํด ๋ณด์ฌ์ด ์ด๋ ์ ๊ฐ์!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
modalBottomSheet์ ์ธ์์ dragHandle = { } ์ ์ถ๊ฐํ๋๊น ์์ฒญ ๊ฐ๋จํ๊ฒ ์์ด์ง๋ค์!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
๋์ฐ๋ฏธ๊ฐ ๋ค๋ค ๋๋จํ๋ค์ ... ์ฌ๋ฏผ๋์ ์ง์ง ํด๋ผ์ ์์ง์ด ์์ผ์ ๊ฑฐ๊ฐ์์ ..
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์บฌ ํผ์ ์์๋ด์๋ค๋
๊ฐ์ฌํฉ๋๋ค ใ
isBack = true | ||
) | ||
|
||
Spacer(modifier = Modifier.width(16.dp)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์ด๋ฐ๊ฒ ๋ณด๋ฉด์ ๋์์ธ์ ์ฌ์ด ๊ฐ๊ฒฉ์ 12px์ด๋ผ๊ณ ๋์์๋๋ฐ 16dp๋ฅผ ์ฃผ๋ ์ด์ ๊ฐ ๊ถ๊ธํฉ๋๋ค! ์ง์ง ์ง๋ฌธ
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
px์ dp์ ์ฐจ์ด๋ฅผ ๊ณ ๋ คํด์ ๋ณํํ ๊ฑฐ์๋ค๋ฉด ์ ๋ง ๋ฉ์ง๋๋ต์ด์๊ฒ ์ง๋ง.. ์ค์๋ก ์๋ชป๋ฃ์๊ฑฐ๋ผ ์ฝ์ธ๊ฒ ์์ ํ์ต๋๋นใ
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ใ ใ ใ ใ ใ ใ ใ ใ ๋์ด์ค
) { | ||
Text( | ||
text = movieTitle, | ||
style = Typography.head6_b_17, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์ด๋จ๋๋ CGVTheme.typography.head6_b_17 ๋ก ์ ์ฉํ์๋ค๊ฐ ์ด์ฉ๋๋ ์ด๋ ๊ฒ ์ ์ฉํ์๋๋ฐ ํ๋๋ก ํต์ผ ํ์๋๊ฒ ์ข์ ๊ฒ ๊ฐ์์! ์ ๋ CGVTheme์ typography๋ฅผ ์ด๋ค๊ณ ๋ช ์ํ๋ฉด ์ข์ ๊ฒ ๊ฐ๊ธดํฉ๋๋ค
contents: List<String>, | ||
){ | ||
Row( | ||
horizontalArrangement = Arrangement.spacedBy(8.dp, Alignment.CenterHorizontally), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์ค์ฐ ์ด๊ฑด ์ด๋ค ๋ฌธ๋ฒ์ด์ฃต?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
spacedBy๋ ์ฐ๊ณ ์ถ๊ณ ์ค์์ ๋ ฌ๋ ํ๊ณ ์ถ์๋ฐ horizontalArrangment๋ฅผ ๋๋ฒ ์ฐ๋ฉด ์ค๋ฅ๊ฐ ๋๊ธธ๋ ์ฐพ์๋ณด๋๊น ์ด๋ ๊ฒ ํ๋ฒ์๋ ์ธ ์ ์๋๋ผ๊ณ ์! ๋ ๊ฐ๋จํ ๋ฐฉ๋ฒ์ผ๋ก ๊ฐ๋ ์ฑ ์ข๊ฒ ๊ณ ์น ๋ฐฉ๋ฒ์ด ์์๊น์??
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
๋ฐ๋ก ์๊ฐ๋๋ ๊ฑฐ๋ ์๋ค์? ์ข์ ๊ฒ ๋ฐฐ์ด๊ฑฐ๊ฐ์์
) { | ||
|
||
Row( | ||
modifier = Modifier, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์ด๋ฐ์ค์ ํ์ ์์ ๊ฒ ๊ฐ์์!
horizontalArrangement = Arrangement.Center | ||
) { | ||
CgvButton( | ||
text = "๋ค๋ก๊ฐ๊ธฐ", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
confirm์ฐฝ์๋ ๋ค๋ก๊ฐ๊ธฐ๊ฐ ์๋๋ฐ ํน์ ๋์์ธ์ด ๋ณ๊ฒฝ๋์๋์?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
๋ฐ๋ก ๊ณ ์ณค์ต๋๋คใ ใ ๊ผผ๊ผผํ ๋ด์ฃผ์ ์ ๋๋ฌด๋๋ฌด ๊ฐ์ฌํฉ๋๋ค.!!!!
onDismissRequest = { }, | ||
sheetState = rememberModalBottomSheetState(), | ||
shape = RoundedCornerShape(topStart = 16.dp, topEnd = 16.dp), | ||
containerColor = Color.White |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
๋ฐ๊ฒฌ!
์ด๋์ ์ ๋ ๋์ง ๋ถ๋ถ์ด ์์ ์ ์์ผ๋ ctrl+R์ ๋๋ฌ์ ๊ฒ์์ ํ๋ค์์ Replace๋ฅผ ํด์
๋ฌด์จ ๋ง์ธ์ง ๋ชจ๋ฅด๊ฒ ์ผ๋ฉด ์ฐ๋ฝํ์ธ์ฉ
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์ ์ฒด ํ๋ก์ ํธ์์ ๊ฒ์ํ ๋ ctrl + shift + R
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์์ ์๋ฃ!!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์ฐ์ ๋๋ฌด ์๊ณ ๋ง์ผ์
จ์ต๋๋ค~! ํจ์ฌ ๋ณด๊ธฐ ์ข์์ก๋ค์!
์ ๊ฐ ๋จ๊ธด ๋ฆฌ๋ทฐ๋ค ํ๋ฒ ํ์ธํด์ฃผ์๊ณ ์์ ํด์ฃผ์๋ฉด ์ข์ ๊ฑฐ ๊ฐ์์!
val backgroundColor = if (isActivated) White else Gray700 | ||
val backgroundColor2 = if (isActivated) Gray200 else Gray700 | ||
val leftSeatsColor = if (isActivated) PrimaryRed400 else Green |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์ ๋ถ๋ถ
val backgroundColor = if (isActivated) White else Gray700 | |
val backgroundColor2 = if (isActivated) Gray200 else Gray700 | |
val leftSeatsColor = if (isActivated) PrimaryRed400 else Green | |
.background(if (isActivated) White else Gray700) | |
.background(if (isActivated) Gray200 else Gray700), | |
์ด๋ ๊ฒ ์ฃผ๋ ๊ฑฐ ์ด๋ ์ค์ง์!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์ด๋ ๊ฒ ํ๋๊น ์ธ๋ฐ์๋ ๋ณ์ ์ ์ธ๋ ์ค์ผ ์ ์๊ณ , ๊ฐ๋ ์ฑ๋ ๋ ์ข์์ง๋ค์!
modifier = Modifier | ||
.fillMaxWidth() | ||
.padding(vertical = 4.dp) // ์์๋ ์ฌ๋ฐฑ ์กฐ์ | ||
.background(if (isActivated) Gray200 else Gray700), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์ฌ๊ธฐ์ฒ๋ผ์!
var _showBottomSheet by remember { mutableStateOf(showBottomSheet) } | ||
var showSeatConfirmBottomSheet by remember { mutableStateOf(false) } | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์ฌ๊ธฐ๋ ๋ทฐ๋ชจ๋ธ์์ ๊ด๋ฆฌํ๋ ๊ฒ์ ์ด๋ค๊ฐ์?
๊ผญ ์ฌ๊ธฐ์์ ๊ตฌํํด์ผ ํ๋ ๋ค๋ฅธ ์ด์ ๊ฐ ์์๊น์?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์ด๋ฒ์ ๋จ๊ฒจ์ฃผ์ ๋ฆฌ๋ทฐ ๋๋ถ์, ์ด๋ ํ ๋ณ์๋ค์ ๋ทฐ๋ชจ๋ธ๋ก ๋๊ฒจ ๊ด๋ฆฌํด์ผ ํ๋์ง ์กฐ๊ธ ๋ ๋ช ํํ ์ดํดํ ๊ฒ ๊ฐ์ต๋๋ค..!
(๊ทธ๋ฐ๋ฐ ์ฌ์ ํ ํ์ ์ปดํฌ๋ํธ์์ ํ์ํ ๋ทฐ๋ชจ๋ธ์ ์์ ์ปดํฌ๋ํธ๋ค์์ ๋ฌดํ(..) ์ธ์๋ก ๋ฐ์์ค์ผ ํ๋ ๊ฑด์ง?? <- ์ด ๋ถ๋ถ์ ์์ง ์ ํํ๊ฒ ์ดํดํ์ง ๋ชปํ ๊ฒ ๊ฐ์์ฉ..)
๊ทธ๋๋ ํ๋ํ๋ ์ค์ค๋ก ๋ถ๋ชํ๋ฉด์ ์์๊ฐ๊ณ ์ดํดํด๊ฐ๋ ๋ง์ด ์๋ ๊ฒ ๊ฐ์ต๋๋ค ....! ์ด๋ป๊ฒ ๋ณด๋ฉด ์ธ์์ด ์ ์ฅ์์๋ ๋๋ฌด ๋น์ฐํ ๊ฒ๋ค์ ํ๋ํ๋ ์ง์ ํ๋๋ผ ๋ต๋ตํ๊ณ ๊ณ ์์ค๋ฌ์ธ ์๋ ์์ ๊ฒ ๊ฐ์๋ฐ, ๋ ์ ์งํด์ ๋น ๋ฅด๊ฒ ๋ฐฐ์๊ฐ๊ฒ์ต๋๋น... ๊ผผ๊ผผํ๊ณ ์ ์ฑ์ค๋ฌ์ด ๋ฆฌ๋ทฐ ๋๋ฌด๋๋ฌด ๊ณ ๋ง์์ฉ
@Composable | ||
fun SeatSelectionConfirmRow( | ||
label: String, | ||
price: String, | ||
) { | ||
Row( | ||
modifier = Modifier.fillMaxWidth(), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์ฌ๊ธฐ์๋ modifier์ธ์๊ฐ ์์ ๋ ์ข์ ๊ฑฐ ๊ฐ์์!
import org.sopt.cgv.core.designsystem.theme.CGVTheme | ||
|
||
@Composable | ||
fun StepperRow(label: String) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์ฌ๊ธฐ๋ modifier์ธ์๊ฐ ์์ ๋ ์ข์ ๊ฑฐ ๊ฐ์จ๋น
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์ด๊ฒ๋ ์ฌ๋ฏผ์ค๋น ๊ฐ ๋จ๊ฒจ์ค ๋ฆฌ๋ทฐ ๊ธฐ๋ฐ์ผ๋ก ์์ ์ปดํฌ๋ํธ์์ ๋ฌผ๋ ค์ค (์ธ์๋ก ๋ฐ์) modifier๋ฅผ ๋๋์ฒด ์ด๋๊น์ง ์ ์ฉํด์ค์ผ ํ๋ ๊ฑด์ง ์ฝ๊ฐ ๋ ๊ณต๋ถํด๋ณผ ์ ์์ด์ ์ข์์์ฉ
contents: PersistentList<TimeCardContent>, | ||
modifier: Modifier = Modifier, | ||
) { | ||
var clickedCardIndex = remember { mutableStateOf(Int) } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์๋ฐ ์ํ๋ ๋ทฐ๋ชจ๋ธ์์ ๊ด๋ฆฌํ๋ ํธ์ด ๋ ์ข์ง ์์๊น์???
//์ํํ์์ค ์ฌ๋ฐฑ | ||
Spacer(modifier = Modifier.height(30.dp)) | ||
|
||
//TopBar ๋ถ๋ถ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
๋ชจ๋ ํ์ผ์์ ์ด๋ฐ ์ฃผ์ ๋ถ๋ถ์ ์ง์์ฃผ์๋ฉด ์ข์ ๊ฑฐ ๊ฐ์์!
initialValue: Int = 0, | ||
onValueChange: (Int) -> Unit | ||
) { | ||
var currentValue by remember { mutableStateOf(initialValue) } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์ด ๋ถ๋ถ๋ ์ํ๊ด๋ฆฌ๋ฅผ ๋ทฐ๋ชจ๋ธ์์ ํ๋ฉด ๋ ์ข์ ๊ฑฐ ๊ฐ์์!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์๊ณ ๋ง์ผ์
จ์ต๋๋ค~!
์ปดํฌ๋ํธ์ ๋ทฐ๋ชจ๋ธ์ ์ธ์๋ก ์ฃผ์ ๋ถ๋ถ๋ง ์ถ๊ฐ์ ์ผ๋ก ๋ ๊ณต๋ถํด๋ณด์๊ณ ๋ฐ์ํ๋ฉด ํจ์ฌ ์ข์ ๊ฑฐ ๊ฐ์์!!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
๋ทฐ๋ชจ๋ธ ํ์ผ์ ์ปดํฌ๋ํธ์ ์์ผ๋ฉด ์๋ฉ๋๋น
์ปดํฌ๋ํธ ํจํค์ง๋ ui๋ฅผ ์ฌ์ฌ์ฉํ ์ ์๋ ํ์ผ๋ค๋ก ์ด๋ค์ฃผ์ธ์!
@Composable | ||
fun SeatSelectionModal1( | ||
modifier: Modifier = Modifier, | ||
viewModel: SeatSelectViewModel, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
๋ทฐ๋ชจ๋ธ ์์กด์ฑ์ ์ ๊ฑฐํด์ฃผ์ธ์!
viewModel: SeatSelectViewModel, | |
stepperValues: Map<String, Int>, | |
onStepperIncrease: (String) -> Unit, | |
onStepperDecrease: (String) -> Unit, |
ViewModel์ ์ง์ ์ฃผ์
ํ๋ ๋์ ํ์ํ ๋ฐ์ดํฐ์ ์ด๋ฒคํธ ํธ๋ค๋ฌ๋ง ์ ๋ฌ๋ฐ๋๋ก ๋ณ๊ฒฝํด์ฃผ์ธ์!
์ด๋ ๊ฒ ๋ฐ๊พผ๋ค๋ฉด ์ปดํฌ์ ๋ธ์ ์ฌ์ฌ์ฉ์ฑ์ ๋์ผ ์ ์์ ๊ฑฐ ๊ฐ์ต๋๋น
@Composable | ||
fun StepperRow( | ||
modifier: Modifier = Modifier, | ||
viewModel: SeatSelectViewModel, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
viewModel: SeatSelectViewModel, | |
value: Int, | |
onIncrease: () -> Unit, | |
onDecrease: () -> Unit |
์ด ์ฝ๋์์๋ ViewModel ์ง์ ์ฐธ์กฐ ๋์ ํ์ํ ์ํ์ ์ด๋ฒคํธ๋ง ๋งค๊ฐ๋ณ์๋ก ๋ฐ๋๋ก ๋ณ๊ฒฝํด์ฃผ์ธ์! ์ด๋ ๊ฒ ๋ฐ๊พธ๋ฉด ์ปดํฌ๋ํธ๊ฐ ํน์ ViewModel์ ์ข ์๋์ง ์์ ๋ค์ํ ์ํฉ์์ ์ฌ์ฌ์ฉ์ด ๊ฐ๋ฅํ ๊ฑฐ ๊ฐ์์!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
๋ํ ์ด ์ปดํฌ๋ํธ ํจ์๋ช ์ ํ์ผ๋ช ๊ณผ ์ผ์น์ํค๋ฉด ์กฐ๊ธ ๋ ๋ณด๊ธฐ ์ฌ์ธ ๊ฑฐ ๊ฐ์์!
@Composable | ||
fun SeatSelectionTimeCardRow( | ||
contents: PersistentList<TimeCardContent>, | ||
viewModel: SeatSelectViewModel, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
viewModel: SeatSelectViewModel, | |
selectedIndex: Int, | |
onCardClick: (Int) -> Unit, |
์ฌ๊ธฐ์๋ ViewModel ์ง์ ์ฐธ์กฐ ๋์ ์ ํ๋ ์ธ๋ฑ์ค(selectedIndex)์ ํด๋ฆญ ์ด๋ฒคํธ ์ฝ๋ฐฑ(onCardClick)์ ๋งค๊ฐ๋ณ์๋ก ๋ฐ๋๋ก ๋ณ๊ฒฝํ์ฌ ์ํ ๊ด๋ฆฌ์ ์ฑ ์์ ์์ ์ปดํฌ๋ํธ๋ก ์ด๋์ํค๊ฒ ๋๋ค๋ฉด ์ปดํฌ๋ํธ์ ์ฌ์ฌ์ฉ์ฑ ํฅ์์ํฌ ์ ์์ ๊ฑฐ ๊ฐ์์! ๋ํ ์ปดํฌ๋ํธ๊ฐ ํน์ ViewModel์ ์ข ์๋์ง ์์ ๋ ๋ค์ํ๊ฒ ์ฌ์ฉ ๊ฐ๋ฅํ ๊ฑฐ ๊ฐ์ต๋๋น
@Composable | ||
fun SeatsScreenTopBar( | ||
modifier: Modifier = Modifier, | ||
viewModel: SeatSelectViewModel, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
viewModel: SeatSelectViewModel, | |
selectedTimeCardIndex: Int, | |
onTimeCardClick: (Int) -> Unit, | |
onBackClick: () -> Unit |
์ฌ๊ธฐ์๋ ViewModel ์์กด์ฑ์ ์ ๊ฑฐํ๊ณ ํ์ํ ์ํ์ ์ด๋ฒคํธ ์ฝ๋ฐฑ๋ง ๋งค๊ฐ๋ณ์๋ก ๋ฐ๋๋ก ๋ณ๊ฒฝํ๋ฉด ์ข์ ๊ฑฐ ๊ฐ์์! ์ด์ ๋ ์์ ๊ฐ์ต๋๋น
label: String, | ||
viewModel: SeatSelectViewModel |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
label: String, | |
viewModel: SeatSelectViewModel | |
value: Int, | |
onIncrease: () -> Unit, | |
onDecrease: () -> Unit |
์ฌ๊ธฐ์๋ ์ง๊ธ๊น์ง์ ๊ฐ์ ์ด์ ๋ก ์ด๋ ๊ฒ ๋ฐ๊พธ๋ฉด ์ข์ ๊ฑฐ ๊ฐ์์!
์ถ๊ฐ์ ์ผ๋ก label์ด ViewModel์ stepperValues Map์์ ํด๋น Stepper์ ๊ฐ์ ์ฐพ๋ ํค๋ก ์ฌ์ฉ๋๊ณ ์๋ ๊ฑฐ ๊ฐ์๋ฐ ๋ง์๊น์? ์์ ๊ฐ์ด ๋ฐ๊พธ๋ฉด value๋ฅผ ์ง์ ๋ฐ์์ค๋ฏ๋ก Map์์ ๊ฐ์ ์ฐพ์ ํ์๊ฐ ์์ด์ ธ์ ์๋ ์ฝ๋๊ฐ ํ์ ์์ด์ง๊ฒ ๋ ๊ฑฐ ๊ฐ์๋ฐ ํ๋ฒ ํ์ธํด์ฃผ์๋ฉด ๊ฐ์ฌํ๊ฒ ์ต๋๋ค!
if (showBottomSheet){ | ||
LaunchedEffect(showBottomSheet) { selectionBottomSheetState.expand() } | ||
SeatSelectionModal1( | ||
modifier = Modifier, | ||
viewModel = viewModel, | ||
movieTitle = movieTitle, | ||
chipContents = chipContents, | ||
onDismiss = { | ||
viewModel.toggleBottomSheet() | ||
focusManager.clearFocus() | ||
}, | ||
onBackClick = { viewModel.toggleBottomSheet() }, | ||
onSeatSelectionClick = { | ||
viewModel.toggleBottomSheet() | ||
viewModel.toggleSeatConfirmBottomSheet() | ||
}, | ||
bottomSheetState = selectionBottomSheetState | ||
) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์ ๊ฐ ๋จ ์ฝ๋๋ฆฌ๋ทฐ๋ฅผ ๋ฐ์ํ๋ฉด ์ด์ ์ฌ๊ธฐ ๋ถ๋ถ๊ณผ
SeatsScreenTopBar( | ||
modifier = Modifier, | ||
viewModel = viewModel, | ||
timeCardContent = sampleTimeCardData | ||
) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์ฌ๊ธฐ ๋ถ๋ถ๊น์ง ์์ ๋์ด์ผ ํฉ๋๋น
fun SeatSelectScreen( | ||
modifier: Modifier = Modifier, | ||
viewModel: SeatSelectViewModel = viewModel(), | ||
movieTitle: String, | ||
){ | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์ฌ๊ธฐ์
onNavigateBack: () -> Unit = {}
์ด๋ ๊ฒ ๋ค๋น๊ฒ์ด์
์ฝ๋ฐฑ์ ์ถ๊ฐํ๋ฉด
SeatsScreenTopBar์์ ๋ค๋ก๊ฐ๊ธฐ๋ฅผ ํ ๋
SeatsScreenTopBar(
onBackClick = onNavigateBack
)
์ด๋ ๊ฒ ์ฌ์ฉํ์ฌ ๋ค๋น๊ฒ์ด์ ๋ก์ง์ ์์ ์ปดํฌ๋ํธ๋ก ์ด๋์ํจ๋ค๋ฉด ํ๋ฉด ๊ฐ ์ด๋์ ๋ ์ ์ฐํ๊ฒ ์ฒ๋ฆฌํ ์ ์์ ๊ฑฐ ๊ฐ์์!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
์๊ณ ํ์ จ์ต๋๋ค~!!ใ ใ ์ฒด๊ณ !!
๐ Issue
๐ป Work Description
๐ธ Screenshot
https://github.com/user-attachments/assets/6c453100-438f-415b-addb-c8a6d1d0a5f2
-> ์๋ SeatScreen ์ฒ์์ ์ง์ ํ์๋ง์ ๋ชจ๋ฌ์ด ํ๋ ๋จ๋ ๊ฒ๊น์ง ๊ตฌํํ ์ํ์ธ๋ฐ (์ฝ๋์ ๋ค์ด๊ฐ ์์), ์๋ฎฌ๋ ์ดํฐ์์ ์๊พธ ์๋์ด ์ ๋ผ์ ์ฒซ ๋ฒ์งธ ๋ชจ๋ฌ ๋์ฐ๋ ๋ถ๋ถ๋ง ์ฃผ์์ฒ๋ฆฌํ๊ณ ์ฐ์ ์์์ ๋๋ค..! ๋ชจ๋ฌ ์ปดํฌ๋ํธ๋ง ๋ฐ๋ก ํ๋ฆฌ๋ทฐ๋ก ๋ณด๋ฉด ์ ๋์ํ๋๋ฐ ํน์ ํด๋ก ๋ฐ์์ ๋ ๊ฐ์ ๋ชจ๋ฌ์ด ๋ค ์ ๋จ๋์ง ํ์ธํด์ฃผ์๋ฉด.. ์ ๋ง ๊ฐ์ฌํ๊ฒ ์ต๋๋ค ใ ใ
https://github.com/user-attachments/assets/6127f952-0e9b-4b62-abb0-e5fc9b2a010b



https://github.com/user-attachments/assets/38679544-c42a-41c0-a64e-a37e39fcb3ef
๐ญ To Reviewers
-SeatSelectionModal1์์ ์ด ์ ํํ ์ธ์ ์๊ฐ 0๋ช ์ด์์ธ ๊ฒฝ์ฐ์ '์ข์ ์ ํ' ๋ฒํผ์ด ๋นจ๊ฐ๊ฒ ํ์ฑํ๋๋ ์ฝ๋๋ ๋น์ฆ๋์ค ๋ก์ง์ด๋ผ๊ณ ์๊ฐํด์ ์ฐ์ ์ ๋ด๋ฒ๋ ค ๋์ต๋๋ค! (TimeCompCard ํ์ฑํ๋ ๋ง์ฐฌ๊ฐ์ง) ์ฐจ์ฐจ ํด๋น ๋ถ๋ถ์ ๊ณ ์ณ๋ด๋ ๊ด์ฐฎ์ ๊ฒ ๊ฐ๋ค๋ฉด, ๋ฆฌ๋ทฐ ๋จ๊ฒจ์ฃผ์๋ฉด ๋ฐ๋ก๋ฐ๋ก ๋ฐ์ํ๊ฒ ์ต๋๋ค! ์ง๊ธ ์ฝ๋ ์ํฉ์์ ๊ณ ์ณ๊ฐ์ผ ํ ๋ถ๋ถ์ ์์ฐจ์ ์ผ๋ก ์๋ ค์ฃผ์๋ฉด ์กฐ๊ธ์ฉ ๋ฆฌํฉํ ๋งํด๋ณด๊ฒ ์ต๋๋ท