From 2d429aa11949756f8938eb35450628f8d02be7fa Mon Sep 17 00:00:00 2001 From: Gibran Chevalley Date: Mon, 19 Aug 2024 09:49:35 +0200 Subject: [PATCH] Rename upload source choice bottom sheet for coherence --- .../importfiles/ImportFilesScreen.kt | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/app/src/main/java/com/infomaniak/swisstransfer/ui/screen/newtransfer/importfiles/ImportFilesScreen.kt b/app/src/main/java/com/infomaniak/swisstransfer/ui/screen/newtransfer/importfiles/ImportFilesScreen.kt index b498c7266..e185cb160 100644 --- a/app/src/main/java/com/infomaniak/swisstransfer/ui/screen/newtransfer/importfiles/ImportFilesScreen.kt +++ b/app/src/main/java/com/infomaniak/swisstransfer/ui/screen/newtransfer/importfiles/ImportFilesScreen.kt @@ -38,7 +38,7 @@ import com.infomaniak.swisstransfer.ui.utils.PreviewTablet @Composable fun ImportFilesScreen() { - var showImportChoiceBottomSheet by remember { mutableStateOf(false) } + var showUploadSourceChoiceBottomSheet by remember { mutableStateOf(false) } BottomStickyButtonScaffold( topBar = { SwissTransferTobAppBar() }, @@ -48,7 +48,7 @@ fun ImportFilesScreen() { titleRes = R.string.buttonAddFiles, imageVector = AppIcons.Add, style = ButtonType.TERTIARY, - onClick = { showImportChoiceBottomSheet = true }, + onClick = { showUploadSourceChoiceBottomSheet = true }, ) }, bottomButton = { modifier -> @@ -60,20 +60,20 @@ fun ImportFilesScreen() { }, ) { Column { - ImportChoiceBottomSheet( - showImportChoiceBottomSheet = { showImportChoiceBottomSheet }, - onDismissRequest = { showImportChoiceBottomSheet = false }, + UploadSourceChoiceBottomSheet( + showUploadSourceChoiceBottomSheet = { showUploadSourceChoiceBottomSheet }, + onDismissRequest = { showUploadSourceChoiceBottomSheet = false }, ) } } } @Composable -private fun ImportChoiceBottomSheet( - showImportChoiceBottomSheet: () -> Boolean, +private fun UploadSourceChoiceBottomSheet( + showUploadSourceChoiceBottomSheet: () -> Boolean, onDismissRequest: () -> Unit, ) { - if (showImportChoiceBottomSheet()) { + if (showUploadSourceChoiceBottomSheet()) { SwissTransferBottomSheet( onDismissRequest = onDismissRequest, titleRes = R.string.transferUploadSourceChoiceTitle, @@ -105,7 +105,7 @@ private fun ImportFilesScreenPreview() { private fun ImportChoiceBottomSheetPreview() { SwissTransferTheme { Surface { - ImportChoiceBottomSheet({ true }, {}) + UploadSourceChoiceBottomSheet({ true }, {}) } } }