From 0e0a9aac5b54ca2d9bcd09d997d7bba5bfcdbc3d Mon Sep 17 00:00:00 2001 From: imkunet Date: Thu, 19 Sep 2024 03:12:00 -0400 Subject: [PATCH] Make spotless --- .../presentation/manga/components/MangaNotesTextArea.kt | 8 ++++---- .../kanade/presentation/manga/components/MangaToolbar.kt | 2 +- .../kanade/tachiyomi/ui/manga/notes/MangaNotesScreen.kt | 2 +- .../main/java/tachiyomi/data/manga/MangaRepositoryImpl.kt | 2 +- 4 files changed, 7 insertions(+), 7 deletions(-) diff --git a/app/src/main/java/eu/kanade/presentation/manga/components/MangaNotesTextArea.kt b/app/src/main/java/eu/kanade/presentation/manga/components/MangaNotesTextArea.kt index 43bb1b8cf..7737f08ac 100644 --- a/app/src/main/java/eu/kanade/presentation/manga/components/MangaNotesTextArea.kt +++ b/app/src/main/java/eu/kanade/presentation/manga/components/MangaNotesTextArea.kt @@ -22,7 +22,7 @@ import androidx.compose.ui.text.TextRange import androidx.compose.ui.text.input.TextFieldValue import eu.kanade.tachiyomi.ui.manga.notes.MangaNotesScreenState -private const val MaxLength = 10_000 +private const val MAX_LENGTH = 10_000 @Composable fun MangaNotesTextArea( @@ -41,12 +41,12 @@ fun MangaNotesTextArea( ) { OutlinedTextField( value = text, - onValueChange = { if (it.text.length <= MaxLength) text = it }, + onValueChange = { if (it.text.length <= MAX_LENGTH) text = it }, modifier = Modifier .fillMaxSize() .focusRequester(focusRequester), supportingText = { - val displayWarning = text.text.length > MaxLength / 10 * 9 + val displayWarning = text.text.length > MAX_LENGTH / 10 * 9 if (!displayWarning) { Text( text = "0", @@ -59,7 +59,7 @@ fun MangaNotesTextArea( exit = fadeOut(), ) { Text( - text = "${text.text.length} / $MaxLength", + text = "${text.text.length} / $MAX_LENGTH", ) } }, diff --git a/app/src/main/java/eu/kanade/presentation/manga/components/MangaToolbar.kt b/app/src/main/java/eu/kanade/presentation/manga/components/MangaToolbar.kt index 919e15957..94b06fd90 100644 --- a/app/src/main/java/eu/kanade/presentation/manga/components/MangaToolbar.kt +++ b/app/src/main/java/eu/kanade/presentation/manga/components/MangaToolbar.kt @@ -155,7 +155,7 @@ fun MangaToolbar( AppBar.OverflowAction( title = stringResource(MR.strings.action_notes), onClick = onClickNotes, - ) + ), ) } .build(), diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/manga/notes/MangaNotesScreen.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/manga/notes/MangaNotesScreen.kt index 1c3fce925..ea7f88db4 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/manga/notes/MangaNotesScreen.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/manga/notes/MangaNotesScreen.kt @@ -51,7 +51,7 @@ class MangaNotesScreen( navigateUp = navigator::pop, beginEditing = { screenModel.beginEditing() }, endEditing = { screenModel.endEditing() }, - onSave = { screenModel.saveText(it) } + onSave = { screenModel.saveText(it) }, ) } } diff --git a/data/src/main/java/tachiyomi/data/manga/MangaRepositoryImpl.kt b/data/src/main/java/tachiyomi/data/manga/MangaRepositoryImpl.kt index 98cd877ae..0e804dd52 100644 --- a/data/src/main/java/tachiyomi/data/manga/MangaRepositoryImpl.kt +++ b/data/src/main/java/tachiyomi/data/manga/MangaRepositoryImpl.kt @@ -167,7 +167,7 @@ class MangaRepositoryImpl( updateStrategy = value.updateStrategy?.let(UpdateStrategyColumnAdapter::encode), version = value.version, isSyncing = 0, - notes = value.notes + notes = value.notes, ) } }