-
Notifications
You must be signed in to change notification settings - Fork 2
[Mod/#52] SignUp 뷰 GUI 적용 및 오류 수정 #55
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
Merged
Merged
Changes from all commits
Commits
Show all changes
7 commits
Select commit
Hold shift + click to select a range
100194f
mod/#52: 불필요한 의존성,파일 제거
vvan2 93d785c
mod/#52: navigation 수정 및 충돌 해결
vvan2 196f4ce
mod/#52: signup component 수정
vvan2 eac1c23
mod/#52: signup navigation 및 state 수정
vvan2 da6197c
mod/#52: signup view,logic 수정
vvan2 3914497
mod/#52: home view 수정
vvan2 01964a2
Merge branch 'develop' into mod/#52-signup-gui
vvan2 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -6,13 +6,13 @@ import androidx.compose.foundation.layout.fillMaxSize | |
| import androidx.compose.foundation.layout.height | ||
| import androidx.compose.foundation.layout.padding | ||
| import androidx.compose.runtime.Composable | ||
| import androidx.compose.runtime.collectAsState | ||
| import androidx.compose.runtime.getValue | ||
| 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 androidx.hilt.navigation.compose.hiltViewModel | ||
| import androidx.lifecycle.compose.collectAsStateWithLifecycle | ||
| import com.paw.key.R | ||
| import com.paw.key.core.designsystem.component.PawkeyButton | ||
| import com.paw.key.core.designsystem.theme.PawKeyTheme | ||
|
|
@@ -27,7 +27,7 @@ import com.paw.key.presentation.ui.signup.viewmodel.SignUpViewModel | |
| private fun PreviewSignUpActivityScreen() { | ||
| PawKeyTheme { | ||
| SignUpActivityScreen( | ||
| step = 0.25F, | ||
| step = 0.5F, | ||
| navigateSignUpDog = {}, | ||
| ) | ||
| } | ||
|
|
@@ -52,64 +52,68 @@ fun SignUpActivityScreen( | |
| modifier: Modifier = Modifier, | ||
| viewModel: SignUpViewModel = hiltViewModel(), | ||
| ) { | ||
| val state by viewModel.state.collectAsState() | ||
| val state by viewModel.state.collectAsStateWithLifecycle() | ||
|
|
||
| Column( | ||
| modifier = modifier | ||
| .fillMaxSize() | ||
| .padding(horizontal = 16.dp) | ||
| ) { | ||
| SignUpHeader( | ||
| title = stringResource(R.string.ic_onboarding_signup), | ||
| subtitle = stringResource(id = R.string.ic_onboarding_signup_subtitle_step2), | ||
| progress = step, | ||
| ) | ||
| Column( | ||
| modifier = Modifier | ||
| .fillMaxSize() | ||
| .padding(horizontal = 16.dp) | ||
| ) { | ||
|
Comment on lines
+66
to
+70
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 여기도 마찬가지로 상위에 fillmaxsize인데 여기서 flllmaxsize 인 이유? |
||
| Spacer(modifier = Modifier.height(27.dp)) | ||
|
|
||
| Spacer(modifier = Modifier.height(27.dp)) | ||
|
|
||
| FormField( | ||
| label = stringResource(id = R.string.ic_onboarding_signup_main_location), | ||
| content = { | ||
| LocationButton( | ||
| isEnable = true, | ||
| location = "강남구", | ||
| onClick = { viewModel.toggleLocationMenu() } | ||
| ) | ||
| } | ||
| ) | ||
| FormField( | ||
| label = stringResource(id = R.string.ic_onboarding_signup_main_location), | ||
| content = { | ||
| LocationButton( | ||
| isEnable = state.isLocationMenuVisible, | ||
| location = "강남구", | ||
| onClick = { viewModel.toggleLocationMenu() } | ||
| ) | ||
| } | ||
| ) | ||
|
|
||
| Spacer(modifier = Modifier.height(46.dp)) | ||
| Spacer(modifier = Modifier.height(46.dp)) | ||
|
|
||
| FormField( | ||
| label = stringResource(id = R.string.ic_onboarding_signup_sub_location), | ||
| content = { | ||
| if (state.isLocationMenuVisible) { | ||
| LocationList( | ||
| selected = state.selectedLocation, | ||
| locations = listOf("개포동", "논현동", "뭔동", "동동동", "스꾸삐", "4글자유"), | ||
| onLocationSelected = { location -> | ||
| viewModel.selectLocation(location) | ||
| } | ||
| ) | ||
| FormField( | ||
| label = stringResource(id = R.string.ic_onboarding_signup_sub_location), | ||
| content = { | ||
| if (state.isLocationMenuVisible) { | ||
| LocationList( | ||
| selected = state.selectedLocation, | ||
| locations = listOf("개포동", "논현동", "뭔동", "동동동", "스꾸삐", "4글자유"), | ||
| onLocationSelected = { location -> | ||
| viewModel.selectLocation(location) | ||
| } | ||
| ) | ||
| } | ||
| } | ||
| } | ||
| ) | ||
| ) | ||
|
|
||
| Spacer(modifier = Modifier.weight(1f)) | ||
| Spacer(modifier = Modifier.weight(1f)) | ||
|
|
||
| val isFormValid = state.selectedLocation.isNotEmpty() | ||
| val isFormValid = state.selectedLocation.isNotEmpty() | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 폼 판별 변수는 상태로 뷰모델에서 map과 statein으로 관리해보아용 |
||
|
|
||
| PawkeyButton( | ||
| text = stringResource(id = R.string.ic_onboarding_signup_button), | ||
| enabled = isFormValid, | ||
| onClick = { | ||
| if (isFormValid) { | ||
| navigateSignUpDog() | ||
| PawkeyButton( | ||
| text = stringResource(id = R.string.ic_onboarding_signup_button), | ||
| enabled = isFormValid, | ||
| onClick = { | ||
| if (isFormValid) { | ||
| navigateSignUpDog() | ||
| } | ||
| } | ||
| } | ||
| ) | ||
|
|
||
| Spacer(modifier = Modifier.height(46.dp)) | ||
| ) | ||
|
|
||
| Spacer(modifier = Modifier.height(46.dp)) | ||
| } | ||
| } | ||
| } | ||
|
|
||
| } | ||
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
item ㅎㅎ 수정~