From a6f015fc171ca764954be2cdc0ba9b99d9fb5346 Mon Sep 17 00:00:00 2001 From: jinukeu Date: Mon, 22 Jan 2024 15:36:29 +0900 Subject: [PATCH] chore: resolve conflict --- .../com/susu/feature/navigator/MainScreen.kt | 73 ++++++------------- 1 file changed, 24 insertions(+), 49 deletions(-) diff --git a/feature/navigator/src/main/java/com/susu/feature/navigator/MainScreen.kt b/feature/navigator/src/main/java/com/susu/feature/navigator/MainScreen.kt index c6270389..2c52a1c0 100644 --- a/feature/navigator/src/main/java/com/susu/feature/navigator/MainScreen.kt +++ b/feature/navigator/src/main/java/com/susu/feature/navigator/MainScreen.kt @@ -74,14 +74,15 @@ internal fun MainScreen( onShowToast = viewModel::onShowSnackbar, padding = innerPadding, ) - sentNavGraph( - padding = innerPadding, - popBackStack = navigator::popBackStackIfNotHome, - navigateSentEnvelope = navigator::navigateSentEnvelope, - navigateSentEnvelopeDetail = navigator::navigateSentEnvelopeDetail, - navigateSentEnvelopeEdit = navigator::navigateSentEnvelopeEdit, - navigateSentEnvelopeAdd = navigator::navigateSentEnvelopeAdd, - ) + + sentNavGraph( + padding = innerPadding, + popBackStack = navigator::popBackStackIfNotHome, + navigateSentEnvelope = navigator::navigateSentEnvelope, + navigateSentEnvelopeDetail = navigator::navigateSentEnvelopeDetail, + navigateSentEnvelopeEdit = navigator::navigateSentEnvelopeEdit, + navigateSentEnvelopeAdd = navigator::navigateSentEnvelopeAdd, + ) receivedNavGraph( padding = innerPadding, @@ -112,39 +113,13 @@ internal fun MainScreen( navigateLedgerEdit = navigator::navigateLedgerEdit, navigateLedgerFilter = navigator::navigateLedgerFilter, navigateLedgerAdd = navigator::navigateLedgerAdd, + navigateEnvelopAdd = navigator::navigateReceivedEnvelopeAdd, + navigateEnvelopeDetail = navigator::navigateReceivedEnvelopeDetail, + navigateEnvelopeEdit = navigator::navigateReceivedEnvelopeEdit, onShowSnackbar = viewModel::onShowSnackbar, onShowDialog = viewModel::onShowDialog, handleException = viewModel::handleException, ) - receivedNavGraph( - padding = innerPadding, - popBackStack = navigator::popBackStackIfNotHome, - popBackStackWithLedger = { ledger -> - navigator.navController.previousBackStackEntry?.savedStateHandle?.set( - ReceivedRoute.LEDGER_ARGUMENT_NAME, - ledger, - ) - navigator.popBackStackIfNotHome() - }, - popBackStackWithDeleteLedgerId = { ledgerId -> - navigator.navController.previousBackStackEntry?.savedStateHandle?.set( - ReceivedRoute.LEDGER_ID_ARGUMENT_NAME, - ledgerId, - ) - navigator.popBackStackIfNotHome() - }, - navigateLedgerSearch = navigator::navigateLedgerSearch, - navigateLedgerDetail = navigator::navigateLedgerDetail, - navigateLedgerEdit = navigator::navigateLedgerEdit, - navigateLedgerFilter = navigator::navigateLedgerFilter, - navigateLedgerAdd = navigator::navigateLedgerAdd, - navigateEnvelopAdd = navigator::navigateReceivedEnvelopeAdd, - navigateEnvelopeDetail = navigator::navigateReceivedEnvelopeDetail, - navigateEnvelopeEdit = navigator::navigateReceivedEnvelopeEdit, - onShowSnackbar = viewModel::onShowSnackbar, - onShowDialog = viewModel::onShowDialog, - handleException = viewModel::handleException, - ) statisticsNavGraph( padding = innerPadding, @@ -153,18 +128,18 @@ internal fun MainScreen( communityNavGraph( padding = innerPadding, ) - ) - myPageNavGraph( - padding = innerPadding, - navigateToLogin = navigator::navigateLogin, - navigateToInfo = navigator::navigateMyPageInfo, - navigateToSocial = navigator::navigateMyPageSocial, - popBackStack = navigator::popBackStackIfNotHome, - onShowSnackbar = viewModel::onShowSnackbar, - onShowDialog = viewModel::onShowDialog, - handleException = viewModel::handleException, - ) - } + + myPageNavGraph( + padding = innerPadding, + navigateToLogin = navigator::navigateLogin, + navigateToInfo = navigator::navigateMyPageInfo, + navigateToSocial = navigator::navigateMyPageSocial, + popBackStack = navigator::popBackStackIfNotHome, + onShowSnackbar = viewModel::onShowSnackbar, + onShowDialog = viewModel::onShowDialog, + handleException = viewModel::handleException, + ) + } with(uiState) { SusuSnackbar(