-
Notifications
You must be signed in to change notification settings - Fork 2
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
홈과 보관함 폴더 생성/이름 변경 UI 및 navigation 추가 #67
Merged
Merged
Changes from all commits
Commits
Show all changes
23 commits
Select commit
Hold shift + click to select a range
98d27bd
[feat] 홈화면 폴더 생성 화면 추가
ddyeon 0f2dcb1
[feat] 폴더생성 navigation 생성
ddyeon fab70fa
[feat] 홈화면- 폴더생성 navigation 연결 및 bottomSheet 데이터 수정
ddyeon 59a9d3b
[feat] 보관함쪽 폴더 생성 UI 추가
ddyeon f7d407a
[feat] 보관함 폴더 생성 네비게이션 연결
ddyeon 4f4141e
[feat] 필요한 string 추가
ddyeon 5a5d642
[feat] 폴더관리 모델 및 타입 생성
ddyeon 47f7320
[feat] 보관함 dilaog, bottomsheet추가
ddyeon b0e0a0e
[feat] 보관함 dilaog, bottomsheet추가
ddyeon b39c6f8
[feat] 보관함에서 폴더관리 navigation 세팅
ddyeon 637e0e6
[fix] spotless 적용
ddyeon bcdb5b8
Merge branch 'develop' into feature/create-folder-ui
ddyeon fd66fbc
[fix] 홈 폴더생성 뒤로가기 추가
ddyeon 2f80adf
[fix] bottomsheet 닫힌 후 이동하도록 수정
ddyeon 776d6b6
[fix] 폴더 생성 페이지에서 뒤로가기 시 바텀 시트 노출되도록 수정
ddyeon b087a47
[fix] bottomsheet annotation 추가
ddyeon c749480
[fix] defaultvalue제거
ddyeon 2e35cb8
[fix] savestatehandler로 값 받기 수정
ddyeon af5835a
[fix] savestatehandle 찾는중,,
ddyeon ff0bd1a
[fix] savestatehandle을 위한,, viewmodel공유
ddyeon bb8d8ea
[fix] savestatehandle을 위한,, viewmodel공유
ddyeon a8dac49
[fix] bottomsheet 변경
ddyeon 66093bb
[fix] 홈 폴더 생성 naventry 변경
ddyeon 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 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 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 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 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 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
79 changes: 79 additions & 0 deletions
79
...re/home/src/main/java/com/mashup/dorabangs/feature/createfolder/HomeCreateFolderScreen.kt
This file contains 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 |
---|---|---|
@@ -0,0 +1,79 @@ | ||
package com.mashup.dorabangs.feature.createfolder | ||
|
||
import android.util.Log | ||
import androidx.compose.foundation.background | ||
import androidx.compose.foundation.layout.Column | ||
import androidx.compose.foundation.layout.Spacer | ||
import androidx.compose.foundation.layout.fillMaxSize | ||
import androidx.compose.foundation.layout.fillMaxWidth | ||
import androidx.compose.foundation.layout.height | ||
import androidx.compose.foundation.layout.padding | ||
import androidx.compose.runtime.Composable | ||
import androidx.compose.ui.Modifier | ||
import androidx.compose.ui.res.stringResource | ||
import androidx.compose.ui.unit.dp | ||
import androidx.hilt.navigation.compose.hiltViewModel | ||
import com.mashup.dorabangs.core.designsystem.component.buttons.DoraButtons | ||
import com.mashup.dorabangs.core.designsystem.component.textfield.DoraTextField | ||
import com.mashup.dorabangs.core.designsystem.component.topbar.DoraTopBar | ||
import com.mashup.dorabangs.core.designsystem.theme.LinkSaveColorTokens | ||
import com.mashup.dorabangs.feature.home.HomeViewModel | ||
import com.mashup.dorabangs.home.R | ||
|
||
@Composable | ||
fun HomeCreateFolderRoute( | ||
homeViewModel: HomeViewModel = hiltViewModel(), | ||
onClickBackIcon: () -> Unit, | ||
) { | ||
Log.d("DOAROA", "HomeCreateFolderRoute: $homeViewModel") | ||
HomeCreateFolderScreen( | ||
onClickBackIcon = onClickBackIcon, | ||
onClickSaveButton = {}, | ||
) | ||
} | ||
|
||
@Composable | ||
fun HomeCreateFolderScreen( | ||
onClickBackIcon: () -> Unit, | ||
onClickSaveButton: () -> Unit, | ||
modifier: Modifier = Modifier, | ||
) { | ||
Column( | ||
modifier = modifier | ||
.fillMaxSize() | ||
.background(color = LinkSaveColorTokens.ContainerColor), | ||
) { | ||
DoraTopBar.BackNavigationTopBar( | ||
modifier = Modifier, | ||
title = stringResource(id = R.string.home_create_folder_title), | ||
isTitleCenter = true, | ||
onClickBackIcon = onClickBackIcon, | ||
) | ||
Spacer(modifier = Modifier.height(height = 24.dp)) | ||
Column( | ||
modifier = modifier | ||
.fillMaxSize() | ||
.padding(horizontal = 20.dp), | ||
) { | ||
DoraTextField( | ||
text = "", | ||
hintText = stringResource(id = R.string.home_create_folder_hint), | ||
labelText = stringResource(id = R.string.home_create_folder_label), | ||
helperText = stringResource(id = R.string.home_create_folder_helper), | ||
helperEnabled = true, | ||
counterEnabled = true, | ||
onValueChanged = {}, | ||
) | ||
Spacer(modifier = Modifier.height(20.dp)) | ||
DoraButtons.DoraBtnMaxFull( | ||
modifier = Modifier | ||
.fillMaxWidth() | ||
.padding(vertical = 20.dp), | ||
buttonText = stringResource(id = R.string.home_create_folder_save), | ||
enabled = true, | ||
onClickButton = onClickSaveButton, | ||
) | ||
Spacer(modifier = Modifier.height(20.dp)) | ||
} | ||
} | ||
} |
This file contains 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 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 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
34 changes: 34 additions & 0 deletions
34
.../home/src/main/java/com/mashup/dorabangs/feature/navigation/HomeCreateFolderNavigation.kt
This file contains 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 |
---|---|---|
@@ -0,0 +1,34 @@ | ||
package com.mashup.dorabangs.feature.navigation | ||
|
||
import androidx.hilt.navigation.compose.hiltViewModel | ||
import androidx.navigation.NavController | ||
import androidx.navigation.NavGraphBuilder | ||
import androidx.navigation.NavOptions | ||
import androidx.navigation.compose.composable | ||
import com.mashup.core.navigation.NavigationRoute | ||
import com.mashup.dorabangs.feature.createfolder.HomeCreateFolderRoute | ||
import com.mashup.dorabangs.feature.home.HomeViewModel | ||
|
||
fun NavController.navigateToHomeCrateFolder(navOptions: NavOptions? = null) = | ||
navigate(NavigationRoute.HomeScreen.HomeCreateFolder.route, navOptions) | ||
|
||
fun NavGraphBuilder.homeCreateFolderNavigation( | ||
navController: NavController, | ||
onClickBackIcon: () -> Unit, | ||
) { | ||
composable( | ||
route = NavigationRoute.HomeScreen.HomeCreateFolder.route, | ||
) { | ||
navController.previousBackStackEntry?.let { backStackEntry -> | ||
val homeViewModel: HomeViewModel = hiltViewModel(backStackEntry) | ||
homeViewModel.savedStateHandle["isVisibleMovingBottomSheet"] = true | ||
|
||
HomeCreateFolderRoute( | ||
homeViewModel = homeViewModel, | ||
onClickBackIcon = onClickBackIcon, | ||
) | ||
} ?: HomeCreateFolderRoute( | ||
onClickBackIcon = onClickBackIcon, | ||
) | ||
} | ||
} |
Oops, something went wrong.
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.
@ddyeon
리소스 어노테이션 붙이면 더 좋을듯 ~~