Skip to content

Commit

Permalink
[FEATURE] #82 : WappMainTopBar 파라미터 추가
Browse files Browse the repository at this point in the history
  • Loading branch information
tgyuuAn committed Jan 5, 2024
1 parent bb95bd7 commit 6fa6050
Show file tree
Hide file tree
Showing 7 changed files with 25 additions and 17 deletions.
Original file line number Diff line number Diff line change
@@ -1,4 +1,12 @@
package com.wap.designsystem.component

class MainTopBar {
}
import androidx.annotation.StringRes
import androidx.compose.runtime.Composable

@Composable
fun WappMainTopBar(
@StringRes titleRes: Int,
@StringRes contentRes: Int,
showSettingButton: Boolean = false,
onClickSettingButton: () -> Unit = {},
) {}
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ import com.wap.designsystem.WappTheme
import com.wap.wapp.core.designsystem.R

@Composable
fun WappTopBar(
fun WappSubTopBar(
@StringRes titleRes: Int,
modifier: Modifier = Modifier,
showLeftButton: Boolean = false,
Expand Down Expand Up @@ -80,7 +80,7 @@ fun WappTopBarWithoutButton() {
Surface(
color = WappTheme.colors.backgroundBlack,
) {
WappTopBar(
WappSubTopBar(
modifier = Modifier
.fillMaxWidth()
.padding(16.dp),
Expand All @@ -97,7 +97,7 @@ fun WappTopBarWithRightButton() {
Surface(
color = WappTheme.colors.backgroundBlack,
) {
WappTopBar(
WappSubTopBar(
modifier = Modifier
.fillMaxWidth()
.padding(16.dp),
Expand All @@ -115,7 +115,7 @@ fun WappTopBarWithLeftButton() {
Surface(
color = WappTheme.colors.backgroundBlack,
) {
WappTopBar(
WappSubTopBar(
modifier = Modifier
.fillMaxWidth()
.padding(16.dp),
Expand All @@ -133,7 +133,7 @@ fun WappTopBarWithBothButton() {
Surface(
color = WappTheme.colors.backgroundBlack,
) {
WappTopBar(
WappSubTopBar(
modifier = Modifier
.fillMaxWidth()
.padding(16.dp),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ import androidx.compose.ui.unit.dp
import androidx.compose.ui.unit.sp
import androidx.hilt.navigation.compose.hiltViewModel
import com.wap.designsystem.WappTheme
import com.wap.designsystem.component.WappTopBar
import com.wap.designsystem.component.WappSubTopBar
import com.wap.wapp.core.commmon.extensions.toSupportingText
import com.wap.wapp.core.designresource.R
import com.wap.wapp.feature.auth.R.drawable.ic_card
Expand Down Expand Up @@ -85,7 +85,7 @@ internal fun SignUpScreen(
.fillMaxSize()
.padding(horizontal = 16.dp),
) {
WappTopBar(
WappSubTopBar(
modifier = Modifier
.fillMaxWidth()
.padding(vertical = 16.dp),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ import androidx.compose.ui.unit.dp
import androidx.hilt.navigation.compose.hiltViewModel
import androidx.lifecycle.compose.collectAsStateWithLifecycle
import com.wap.designsystem.WappTheme
import com.wap.designsystem.component.WappTopBar
import com.wap.designsystem.component.WappSubTopBar
import com.wap.wapp.core.commmon.extensions.toSupportingText
import com.wap.wapp.feature.management.R
import com.wap.wapp.feature.management.registration.event.EventRegistrationContent
Expand Down Expand Up @@ -151,7 +151,7 @@ internal fun EventEditScreen(
.padding(paddingValues)
.padding(16.dp),
) {
WappTopBar(
WappSubTopBar(
titleRes = R.string.event_edit,
showLeftButton = true,
onClickLeftButton = onBackButtonClicked,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ import androidx.compose.ui.unit.dp
import androidx.hilt.navigation.compose.hiltViewModel
import androidx.lifecycle.compose.collectAsStateWithLifecycle
import com.wap.designsystem.WappTheme
import com.wap.designsystem.component.WappTopBar
import com.wap.designsystem.component.WappSubTopBar
import com.wap.wapp.core.commmon.extensions.toSupportingText
import com.wap.wapp.feature.management.R
import kotlinx.coroutines.flow.collectLatest
Expand Down Expand Up @@ -144,7 +144,7 @@ internal fun EventRegistrationScreen(
.padding(paddingValues) // paddingValue padding
.padding(16.dp), // dp value padding
) {
WappTopBar(
WappSubTopBar(
titleRes = R.string.event_registration,
showLeftButton = true,
onClickLeftButton = onBackButtonClicked,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ import androidx.compose.ui.res.stringResource
import androidx.compose.ui.unit.dp
import androidx.hilt.navigation.compose.hiltViewModel
import com.wap.designsystem.WappTheme
import com.wap.designsystem.component.WappTopBar
import com.wap.designsystem.component.WappSubTopBar
import com.wap.wapp.core.commmon.extensions.toSupportingText
import com.wap.wapp.core.model.event.Event
import com.wap.wapp.core.model.survey.QuestionType
Expand Down Expand Up @@ -129,7 +129,7 @@ internal fun SurveyRegistrationScreen(
Column(
verticalArrangement = Arrangement.spacedBy(16.dp),
) {
WappTopBar(
WappSubTopBar(
titleRes = R.string.survey_registeration,
showLeftButton = true,
onClickLeftButton = onBackButtonClicked,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ import androidx.core.net.toUri
import androidx.hilt.navigation.compose.hiltViewModel
import com.wap.designsystem.WappTheme
import com.wap.designsystem.component.WappRowBar
import com.wap.designsystem.component.WappTopBar
import com.wap.designsystem.component.WappSubTopBar
import com.wap.wapp.core.designresource.R
import com.wap.wapp.feature.profile.R.string

Expand Down Expand Up @@ -89,7 +89,7 @@ internal fun ProfileSettingScreen(
.fillMaxSize()
.background(color = WappTheme.colors.backgroundBlack),
) {
WappTopBar(
WappSubTopBar(
titleRes = string.more,
showLeftButton = true,
onClickLeftButton = navigateToProfile,
Expand Down

0 comments on commit 6fa6050

Please sign in to comment.