From eea7fcc714c98fb26f710c0ac6bb9f4230c13bb4 Mon Sep 17 00:00:00 2001 From: Gibran Chevalley Date: Fri, 18 Oct 2024 09:36:20 +0200 Subject: [PATCH] Rename SmallFileTile into SmallFileItem --- .../ui/components/{SmallFileTile.kt => SmallFileItem.kt} | 8 ++++---- .../importfiles/components/ImportedFilesCard.kt | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) rename app/src/main/java/com/infomaniak/swisstransfer/ui/components/{SmallFileTile.kt => SmallFileItem.kt} (96%) diff --git a/app/src/main/java/com/infomaniak/swisstransfer/ui/components/SmallFileTile.kt b/app/src/main/java/com/infomaniak/swisstransfer/ui/components/SmallFileItem.kt similarity index 96% rename from app/src/main/java/com/infomaniak/swisstransfer/ui/components/SmallFileTile.kt rename to app/src/main/java/com/infomaniak/swisstransfer/ui/components/SmallFileItem.kt index 6ddadc336..1811567c7 100644 --- a/app/src/main/java/com/infomaniak/swisstransfer/ui/components/SmallFileTile.kt +++ b/app/src/main/java/com/infomaniak/swisstransfer/ui/components/SmallFileItem.kt @@ -33,7 +33,7 @@ import com.infomaniak.swisstransfer.ui.theme.CustomShapes import com.infomaniak.swisstransfer.ui.theme.SwissTransferTheme @Composable -fun SmallFileTile( +fun SmallFileItem( modifier: Modifier = Modifier, file: FileUiItem, smallFileTileSize: SmallFileTileSize, @@ -65,11 +65,11 @@ enum class SmallFileTileSize(val size: Dp, val shape: Shape) { @Preview(name = "Light") @Preview(name = "Dark", uiMode = Configuration.UI_MODE_NIGHT_YES or Configuration.UI_MODE_TYPE_NORMAL) @Composable -private fun SmallFileTilePreview() { +private fun SmallFileItemPreview() { SwissTransferTheme { Surface(color = SwissTransferTheme.materialColors.surfaceContainerHighest) { Column(Modifier.padding(16.dp)) { - SmallFileTile( + SmallFileItem( file = object : FileUiItem { override val fileName: String = "How to not get fired.pdf" override val uid: String = fileName @@ -83,7 +83,7 @@ private fun SmallFileTilePreview() { Spacer(modifier = Modifier.height(16.dp)) - SmallFileTile( + SmallFileItem( file = object : FileUiItem { override val fileName: String = "How to not get fired.pdf" override val uid: String = fileName diff --git a/app/src/main/java/com/infomaniak/swisstransfer/ui/screen/newtransfer/importfiles/components/ImportedFilesCard.kt b/app/src/main/java/com/infomaniak/swisstransfer/ui/screen/newtransfer/importfiles/components/ImportedFilesCard.kt index b62e2bf3a..91b59aab6 100644 --- a/app/src/main/java/com/infomaniak/swisstransfer/ui/screen/newtransfer/importfiles/components/ImportedFilesCard.kt +++ b/app/src/main/java/com/infomaniak/swisstransfer/ui/screen/newtransfer/importfiles/components/ImportedFilesCard.kt @@ -96,7 +96,7 @@ fun ImportedFilesCard( items = files().asReversed(), key = { TransferLazyRowKey(TransferLazyRowKey.Type.FILE, it.uid) }, ) { file -> - SmallFileTile( + SmallFileItem( modifier = Modifier.animateItem(), file = file, smallFileTileSize = SmallFileTileSize.LARGE,