Skip to content
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/#8] : 약속 확정 페이지 구현 #14

Merged
merged 20 commits into from
Jan 9, 2025
Merged
Show file tree
Hide file tree
Changes from 8 commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
117f78e
#8 [UI] 약속 홈 페이지 구현
gaeulzzang Dec 31, 2024
6fa92fe
Merge branch 'develop' of https://github.com/Noostak/Noostak_Android …
gaeulzzang Jan 2, 2025
72b76ae
#8 [UI] 진행 중 약속과 약속 확정 화면 연결
gaeulzzang Jan 2, 2025
5a45d3d
#8 [REFACTOR] string 추출
gaeulzzang Jan 2, 2025
68e6850
#8 [UI] 약속 확정 페이지 구현
gaeulzzang Jan 4, 2025
a2e0c29
#8 [UI] 실시간 현황 타임테이블 구현
gaeulzzang Jan 4, 2025
83e9a8c
#8 [UI] 시간 선택형 타임테이블 구현
gaeulzzang Jan 4, 2025
76b6237
#8 [REFACTOR] 스트링 추출
gaeulzzang Jan 4, 2025
49497a2
#8 [REFACTOR] 코드리뷰 반영
gaeulzzang Jan 6, 2025
304c0c0
#8 [ADD] 백스택 정리 코드 추가
gaeulzzang Jan 6, 2025
6375411
#8 [MOD] 그룹 상세 멤버 페이지 UI 수정
gaeulzzang Jan 6, 2025
91c9ee7
#8 [ADD] 약속 확정 페이지 전체 보기 클릭리스너 추가
gaeulzzang Jan 6, 2025
5a711b0
#8 [ADD] 타임테이블 예시 추가
gaeulzzang Jan 6, 2025
7c2409c
#8 [ADD] 시간 선택 뷰 백스택 로직 추가
gaeulzzang Jan 6, 2025
03dcfbb
#8 [MOD] 전체보기, 뒤로가기 로직 수정
gaeulzzang Jan 7, 2025
b9d33bd
Merge branch 'develop' of https://github.com/Noostak/Noostak_Android …
gaeulzzang Jan 7, 2025
bb816b1
#8 [REFACTOR] 하단 버튼 컴포넌트 통일
gaeulzzang Jan 7, 2025
60a1f17
#8 [RENAME] rename regex, image launcher file
gaeulzzang Jan 7, 2025
b8d30d0
#8 [REMOVE] LazyVerticalGrid border 제거
gaeulzzang Jan 9, 2025
726c1b4
#8 [REMOVE] 불필요한 임포트 제거
gaeulzzang Jan 9, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions core/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,8 @@ android {
}

dependencies {
implementation(project(":domain"))

implementation(libs.kotlin)
implementation(libs.core.ktx)
implementation(libs.material)
Expand All @@ -58,4 +60,5 @@ dependencies {
// Third Party
implementation(libs.coil.compose)
implementation(libs.lottie.compose)
implementation(libs.timber)
}
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,11 @@ import androidx.compose.material3.Text
import androidx.compose.runtime.Composable
import androidx.compose.runtime.CompositionLocalProvider
import androidx.compose.ui.Modifier
import androidx.compose.ui.graphics.Color
import androidx.compose.ui.graphics.Shape
import androidx.compose.ui.text.TextStyle
import androidx.compose.ui.unit.Dp
import androidx.compose.ui.unit.dp
import com.sopt.core.designsystem.theme.NoostakTheme
import com.sopt.core.util.NoRippleConfiguration

@OptIn(ExperimentalMaterial3Api::class)
Expand All @@ -33,7 +33,8 @@ fun BaseButton(
modifier = modifier,
shape = shape,
colors = ButtonDefaults.buttonColors(
containerColor = Color.Gray
containerColor = if (isEnabled) NoostakTheme.colors.black else NoostakTheme.colors.gray500,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P3: 여기 컬러 값도 받아와서 사용하는걸로 바꾸면 활용도가 높아질 것 같습니다!

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

컴포넌트 나중에 역할 분담해서 싹다 통일시켜봅시다 ㅠ

contentColor = NoostakTheme.colors.white
),
contentPadding = PaddingValues(
vertical = paddingVertical,
Expand All @@ -44,7 +45,7 @@ fun BaseButton(
) {
Text(
text = text,
color = Color.White,
color = NoostakTheme.colors.white,
style = style
)
}
Expand Down
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P3: 이 버튼 각자 다 만든걸로 알고있는데 뭘로 통일할까요??

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

나중에 다 통일해야될 것 같아유.. 😢

Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
package com.sopt.core.designsystem.component.button

import androidx.compose.foundation.layout.fillMaxWidth
import androidx.compose.foundation.shape.RoundedCornerShape
import androidx.compose.runtime.Composable
import androidx.compose.ui.Modifier
import androidx.compose.ui.unit.dp
import com.sopt.core.designsystem.theme.NoostakTheme

@Composable
fun NoostakButton(
modifier: Modifier = Modifier,
text: String,
onButtonClick: () -> Unit,
isEnabled: Boolean
) {
BaseButton(
modifier = modifier.fillMaxWidth(),
isEnabled = isEnabled,
shape = RoundedCornerShape(8.dp),
style = NoostakTheme.typography.t3Bold,
paddingVertical = 15.dp,
text = text,
onButtonClick = { onButtonClick() }
)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P3: 오 BaseButton 활용하는거 너무 좋습니다!!

}
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ package com.sopt.core.designsystem.component.chip
import androidx.compose.runtime.Composable
import androidx.compose.ui.graphics.Color
import androidx.compose.ui.res.dimensionResource
import androidx.compose.ui.unit.dp
import com.sopt.core.R
import com.sopt.core.designsystem.theme.NoostakTheme

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ package com.sopt.core.designsystem.component.chip
import androidx.compose.runtime.Composable
import androidx.compose.ui.graphics.Color
import androidx.compose.ui.res.dimensionResource
import androidx.compose.ui.unit.dp
import com.sopt.core.R
import com.sopt.core.designsystem.theme.NoostakTheme

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,82 @@
package com.sopt.core.designsystem.component.dialog

import androidx.compose.foundation.background
import androidx.compose.foundation.layout.Arrangement
import androidx.compose.foundation.layout.Box
import androidx.compose.foundation.layout.Column
import androidx.compose.foundation.layout.Spacer
import androidx.compose.foundation.layout.height
import androidx.compose.foundation.layout.padding
import androidx.compose.foundation.layout.size
import androidx.compose.foundation.shape.CircleShape
import androidx.compose.foundation.shape.RoundedCornerShape
import androidx.compose.material3.Button
import androidx.compose.material3.ButtonDefaults
import androidx.compose.material3.Text
import androidx.compose.runtime.Composable
import androidx.compose.ui.Alignment
import androidx.compose.ui.Modifier
import androidx.compose.ui.text.style.TextAlign
import androidx.compose.ui.unit.dp
import com.sopt.core.designsystem.theme.NoostakTheme
import com.sopt.core.extension.noRippleClickable
import com.sopt.core.util.NoRippleInteractionSource

@Composable
fun AppointmentDialog(
onDismissRequest: () -> Unit,
onConfirmButtonClick: () -> Unit,
description: String,
dismissText: String,
confirmButtonText: String
) {
BaseDialog(
onDismissRequest = onDismissRequest,
radius = 20.dp
) {
Column(
modifier = Modifier.padding(35.dp),
horizontalAlignment = Alignment.CenterHorizontally,
verticalArrangement = Arrangement.Center
) {
Box(
modifier = Modifier
.size(53.dp)
.background(
shape = CircleShape,
color = NoostakTheme.colors.gray200
)
)
Spacer(modifier = Modifier.height(16.dp))
Text(
text = description,
color = NoostakTheme.colors.gray900,
style = NoostakTheme.typography.b2Regular,
textAlign = TextAlign.Center
)
Spacer(modifier = Modifier.height(20.dp))
Button(
modifier = Modifier.padding(horizontal = 36.dp, vertical = 8.5.dp),
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P3: 소수는 사용을 지양하고 반올림하여 정수 단위를 사용하는 걸로 알고 있는데 디자인 측에 문의해볼까요??

정수 사용 이유
가독성, 유지보수성, 픽셀 정렬 문제 등의 문제 방지

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

요 부분 디자인 확정이 안나서 소수점 부분은 일단 패스해주세욥

colors = ButtonDefaults.buttonColors(
containerColor = NoostakTheme.colors.gray700
),
shape = RoundedCornerShape(6.dp),
onClick = onConfirmButtonClick,
interactionSource = NoRippleInteractionSource
) {
Text(
text = confirmButtonText,
color = NoostakTheme.colors.white,
textAlign = TextAlign.Center
)
}
Spacer(modifier = Modifier.height(6.5.dp))
Text(
modifier = Modifier.noRippleClickable { onDismissRequest() },
text = dismissText,
color = NoostakTheme.colors.gray700,
style = NoostakTheme.typography.b2Regular
)
}
}
}
Original file line number Diff line number Diff line change
@@ -1,25 +1,15 @@
package com.sopt.core.designsystem.component.dialog

import androidx.compose.foundation.background
import androidx.compose.foundation.clickable
import androidx.compose.foundation.layout.Arrangement
import androidx.compose.foundation.layout.Box
import androidx.compose.foundation.layout.Row
import androidx.compose.foundation.layout.fillMaxWidth
import androidx.compose.foundation.layout.padding
import androidx.compose.foundation.layout.wrapContentSize
import androidx.compose.foundation.shape.RoundedCornerShape
import androidx.compose.material3.Icon
import androidx.compose.runtime.Composable
import androidx.compose.ui.Modifier
import androidx.compose.ui.graphics.Color
import androidx.compose.ui.res.painterResource
import androidx.compose.ui.tooling.preview.Preview
import androidx.compose.ui.unit.dp
import androidx.compose.ui.unit.Dp
import androidx.compose.ui.window.Dialog
import androidx.compose.ui.window.DialogProperties
import com.sopt.core.R
import com.sopt.core.designsystem.theme.NoostakAndroidTheme

@Composable
fun BaseDialog(
Expand All @@ -30,6 +20,7 @@ fun BaseDialog(
dismissOnBackPress = true,
dismissOnClickOutside = true
),
radius: Dp,
content: @Composable () -> Unit
) {
Dialog(
Expand All @@ -38,40 +29,13 @@ fun BaseDialog(
) {
Box(
modifier = Modifier
.wrapContentSize()
.padding(horizontal = 30.dp)
.background(
color = Color.White,
shape = RoundedCornerShape(20.dp)
shape = RoundedCornerShape(radius)
)
.wrapContentSize()
) {
Row(
modifier = Modifier
.fillMaxWidth()
.padding(top = 18.dp, bottom = 16.dp)
.padding(horizontal = 16.dp),
horizontalArrangement = Arrangement.End
) {
Icon(
painter = painterResource(id = R.drawable.ic_back),
contentDescription = null,
tint = Color.Gray,
modifier = Modifier
.clickable { onDismissRequest() }
)
}
content()
}
}
}

@Preview
@Composable
fun BaseDialogPreview() {
NoostakAndroidTheme {
BaseDialog(
onDismissRequest = {},
content = {}
)
}
}
Loading
Loading