Skip to content

Commit

Permalink
Use space left instead of files size in ImportFilesScreen
Browse files Browse the repository at this point in the history
  • Loading branch information
tevincent committed Oct 23, 2024
1 parent c57de0e commit fa550d1
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ import com.infomaniak.swisstransfer.ui.screen.newtransfer.importfiles.components
import com.infomaniak.swisstransfer.ui.theme.Margin
import com.infomaniak.swisstransfer.ui.theme.SwissTransferTheme
import com.infomaniak.swisstransfer.ui.utils.HumanReadableSizeUtils.getFilesSize
import com.infomaniak.swisstransfer.ui.utils.HumanReadableSizeUtils.getSpaceLeft
import com.infomaniak.swisstransfer.ui.utils.PreviewAllWindows

@Composable
Expand Down Expand Up @@ -66,7 +67,7 @@ private fun ImportFilesScreen(

val importedFiles = files()
val humanReadableSize = remember(importedFiles) {
context.getFilesSize(importedFiles)
context.getSpaceLeft(importedFiles)
}

val isSendButtonEnabled by remember { derivedStateOf { importedFiles.isNotEmpty() } }
Expand Down

0 comments on commit fa550d1

Please sign in to comment.