diff --git a/.github/workflows/build_check.yml b/.github/workflows/build_check.yml index c19f80c4d8..77bdc35a21 100644 --- a/.github/workflows/build_check.yml +++ b/.github/workflows/build_check.yml @@ -33,8 +33,7 @@ jobs: cp .github/runner-files/ci-gradle.properties ~/.gradle/gradle.properties - name: Build and run tests - if: startsWith(env.VERSION_TAG, 'r') != true && startsWith(env.VERSION_TAG, 'v') != true - run: ./gradlew assembleDevDebug testDevDebugUnitTest assembleStandardRelease + run: ./gradlew assembleStandardRelease testStandardReleaseUnitTest - name: Publish test report uses: mikepenz/action-junit-report@v4 @@ -44,15 +43,6 @@ jobs: detailed_summary: true report_paths: '**/build/test-results/test*/TEST-*.xml' - - name: Run tests against release variant - if: startsWith(env.VERSION_TAG, 'r') != true && startsWith(env.VERSION_TAG, 'v') != true - run: ./gradlew testStandardReleaseUnitTest - - - name: Upload debug APK to artifact - uses: actions/upload-artifact@v4 - with: - path: app/build/outputs/apk/dev/debug/app*-arm64-v8a-*.apk - - name: Upload R8 APK to artifact uses: actions/upload-artifact@v4 with: diff --git a/.gitignore b/.gitignore index 900ee93b33..7902976010 100644 --- a/.gitignore +++ b/.gitignore @@ -8,3 +8,4 @@ *.iml */build */*/build +.kotlin/ diff --git a/app/src/main/java/eu/kanade/tachiyomi/App.kt b/app/src/main/java/eu/kanade/tachiyomi/App.kt index 8dfe4020ca..2ad12158af 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/App.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/App.kt @@ -67,6 +67,8 @@ import yokai.core.di.PreferenceModule import yokai.core.migration.Migrator import yokai.core.migration.migrations.migrations import yokai.domain.base.BasePreferences +import yokai.i18n.MR +import yokai.util.lang.getString import java.security.Security open class App : Application(), DefaultLifecycleObserver, SingletonImageLoader.Factory { @@ -130,9 +132,9 @@ open class App : Application(), DefaultLifecycleObserver, SingletonImageLoader.F disableIncognitoReceiver.register() val nContext = localeContext val notification = nContext.notification(Notifications.CHANNEL_INCOGNITO_MODE) { - val incogText = nContext.getString(R.string.incognito_mode) + val incogText = nContext.getString(MR.strings.incognito_mode) setContentTitle(incogText) - setContentText(nContext.getString(R.string.turn_off_, incogText)) + setContentText(nContext.getString(MR.strings.turn_off_, incogText)) setSmallIcon(R.drawable.ic_incognito_24dp) setOngoing(true) diff --git a/app/src/main/java/eu/kanade/tachiyomi/appwidget/UpdatesGridGlanceWidget.kt b/app/src/main/java/eu/kanade/tachiyomi/appwidget/UpdatesGridGlanceWidget.kt index fab24c4a8c..ec7ca94445 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/appwidget/UpdatesGridGlanceWidget.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/appwidget/UpdatesGridGlanceWidget.kt @@ -25,6 +25,8 @@ import coil3.size.Precision import coil3.size.Scale import coil3.transform.RoundedCornersTransformation import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString import eu.kanade.tachiyomi.appwidget.components.CoverHeight import eu.kanade.tachiyomi.appwidget.components.CoverWidth import eu.kanade.tachiyomi.appwidget.components.LockedWidget diff --git a/app/src/main/java/eu/kanade/tachiyomi/appwidget/components/LockedWidget.kt b/app/src/main/java/eu/kanade/tachiyomi/appwidget/components/LockedWidget.kt index 8911445446..7b89f51a37 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/appwidget/components/LockedWidget.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/appwidget/components/LockedWidget.kt @@ -2,6 +2,7 @@ package eu.kanade.tachiyomi.appwidget.components import android.content.Intent import androidx.compose.runtime.Composable +import androidx.compose.ui.graphics.Color import androidx.compose.ui.unit.dp import androidx.compose.ui.unit.sp import androidx.glance.GlanceModifier @@ -16,12 +17,14 @@ import androidx.glance.text.TextAlign import androidx.glance.text.TextStyle import androidx.glance.unit.ColorProvider import eu.kanade.tachiyomi.R +import yokai.i18n.MR import eu.kanade.tachiyomi.appwidget.ContainerModifier import eu.kanade.tachiyomi.appwidget.util.stringResource import eu.kanade.tachiyomi.ui.main.MainActivity @Composable fun LockedWidget() { + val context = LocalContext.current val intent = Intent(LocalContext.current, Class.forName(MainActivity.MAIN_ACTIVITY)).apply { addFlags(Intent.FLAG_ACTIVITY_NEW_TASK) } @@ -33,9 +36,9 @@ fun LockedWidget() { contentAlignment = Alignment.Center, ) { Text( - text = stringResource(R.string.appwidget_unavailable_locked), + text = stringResource(MR.strings.appwidget_unavailable_locked), style = TextStyle( - color = ColorProvider(R.color.appwidget_on_secondary_container), + color = ColorProvider(Color(context.getColor(R.color.appwidget_on_secondary_container))), fontSize = 12.sp, textAlign = TextAlign.Center, ), diff --git a/app/src/main/java/eu/kanade/tachiyomi/appwidget/components/UpdatesMangaCover.kt b/app/src/main/java/eu/kanade/tachiyomi/appwidget/components/UpdatesMangaCover.kt index a9aa232d08..6856ddb787 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/appwidget/components/UpdatesMangaCover.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/appwidget/components/UpdatesMangaCover.kt @@ -11,6 +11,8 @@ import androidx.glance.layout.ContentScale import androidx.glance.layout.fillMaxSize import androidx.glance.layout.size import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString import eu.kanade.tachiyomi.appwidget.util.appWidgetInnerRadius val CoverWidth = 58.dp diff --git a/app/src/main/java/eu/kanade/tachiyomi/appwidget/components/UpdatesWidget.kt b/app/src/main/java/eu/kanade/tachiyomi/appwidget/components/UpdatesWidget.kt index 75ca31bb62..d9786f70ad 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/appwidget/components/UpdatesWidget.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/appwidget/components/UpdatesWidget.kt @@ -18,6 +18,8 @@ import androidx.glance.layout.fillMaxWidth import androidx.glance.layout.padding import androidx.glance.text.Text import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString import eu.kanade.tachiyomi.appwidget.ContainerModifier import eu.kanade.tachiyomi.appwidget.util.calculateRowAndColumnCount import eu.kanade.tachiyomi.appwidget.util.stringResource @@ -37,7 +39,7 @@ fun UpdatesWidget(data: List>?) { if (data == null) { CircularProgressIndicator() } else if (data.isEmpty()) { - Text(text = stringResource(R.string.no_recent_read_updated_manga)) + Text(text = stringResource(MR.strings.no_recent_read_updated_manga)) } else { (0 until rowCount).forEach { i -> val coverRow = (0 until columnCount).mapNotNull { j -> diff --git a/app/src/main/java/eu/kanade/tachiyomi/appwidget/util/GlanceUtils.kt b/app/src/main/java/eu/kanade/tachiyomi/appwidget/util/GlanceUtils.kt index 5f56877211..7348a85c5c 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/appwidget/util/GlanceUtils.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/appwidget/util/GlanceUtils.kt @@ -6,7 +6,9 @@ import androidx.compose.ui.unit.DpSize import androidx.glance.GlanceModifier import androidx.glance.LocalContext import androidx.glance.appwidget.cornerRadius +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.R +import yokai.util.lang.getString fun GlanceModifier.appWidgetBackgroundRadius(): GlanceModifier { return this.cornerRadius(R.dimen.appwidget_background_radius) @@ -16,6 +18,11 @@ fun GlanceModifier.appWidgetInnerRadius(): GlanceModifier { return this.cornerRadius(R.dimen.appwidget_inner_radius) } +@Composable +fun stringResource(id: StringResource): String { + return LocalContext.current.getString(id) +} + @Composable fun stringResource(@StringRes id: Int): String { return LocalContext.current.getString(id) diff --git a/app/src/main/java/eu/kanade/tachiyomi/core/storage/AndroidStorageFolderProvider.kt b/app/src/main/java/eu/kanade/tachiyomi/core/storage/AndroidStorageFolderProvider.kt index 4fe299b16f..d8c5c55148 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/core/storage/AndroidStorageFolderProvider.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/core/storage/AndroidStorageFolderProvider.kt @@ -3,7 +3,8 @@ package eu.kanade.tachiyomi.core.storage import android.content.Context import android.os.Environment import androidx.core.net.toUri -import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString import java.io.File class AndroidStorageFolderProvider( @@ -13,7 +14,7 @@ class AndroidStorageFolderProvider( override fun directory(): File { return File( Environment.getExternalStorageDirectory().absolutePath + File.separator + - context.getString(R.string.app_normalized_name), + context.getString(MR.strings.app_normalized_name), ) } diff --git a/app/src/main/java/eu/kanade/tachiyomi/data/backup/BackupFileValidator.kt b/app/src/main/java/eu/kanade/tachiyomi/data/backup/BackupFileValidator.kt index b4c7306074..f59e46d30a 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/data/backup/BackupFileValidator.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/data/backup/BackupFileValidator.kt @@ -2,12 +2,13 @@ package eu.kanade.tachiyomi.data.backup import android.content.Context import android.net.Uri -import eu.kanade.tachiyomi.R import eu.kanade.tachiyomi.data.track.TrackManager import eu.kanade.tachiyomi.source.SourceManager import eu.kanade.tachiyomi.util.BackupUtil import uy.kohesive.injekt.Injekt import uy.kohesive.injekt.api.get +import yokai.i18n.MR +import yokai.util.lang.getString class BackupFileValidator( private val sourceManager: SourceManager = Injekt.get(), @@ -28,7 +29,7 @@ class BackupFileValidator( } if (backup.backupManga.isEmpty()) { - throw IllegalStateException(context.getString(R.string.backup_has_no_manga)) + throw IllegalStateException(context.getString(MR.strings.backup_has_no_manga)) } val sources = backup.backupSources.map { it.sourceId to it.name }.toMap() diff --git a/app/src/main/java/eu/kanade/tachiyomi/data/backup/BackupNotifier.kt b/app/src/main/java/eu/kanade/tachiyomi/data/backup/BackupNotifier.kt index 62ede7b291..ce64b1772b 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/data/backup/BackupNotifier.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/data/backup/BackupNotifier.kt @@ -12,6 +12,8 @@ import eu.kanade.tachiyomi.util.storage.getUriCompat import eu.kanade.tachiyomi.util.system.notificationBuilder import eu.kanade.tachiyomi.util.system.notificationManager import uy.kohesive.injekt.injectLazy +import yokai.i18n.MR +import yokai.util.lang.getString import java.io.File import java.util.concurrent.* @@ -38,7 +40,7 @@ class BackupNotifier(private val context: Context) { fun showBackupProgress() { val builder = with(progressNotificationBuilder) { - setContentTitle(context.getString(R.string.creating_backup)) + setContentTitle(context.getString(MR.strings.creating_backup)) setProgress(0, 0, true) setOnlyAlertOnce(true) @@ -51,7 +53,7 @@ class BackupNotifier(private val context: Context) { context.notificationManager.cancel(Notifications.ID_BACKUP_PROGRESS) with(completeNotificationBuilder) { - setContentTitle(context.getString(R.string.backup_failed)) + setContentTitle(context.getString(MR.strings.backup_failed)) setContentText(error) show(Notifications.ID_BACKUP_COMPLETE) @@ -62,7 +64,7 @@ class BackupNotifier(private val context: Context) { context.notificationManager.cancel(Notifications.ID_BACKUP_PROGRESS) with(completeNotificationBuilder) { - setContentTitle(context.getString(R.string.backup_created)) + setContentTitle(context.getString(MR.strings.backup_created)) setContentText(unifile.filePath ?: unifile.name) // Clear old actions if they exist @@ -70,7 +72,7 @@ class BackupNotifier(private val context: Context) { addAction( R.drawable.ic_share_24dp, - context.getString(R.string.share), + context.getString(MR.strings.share), NotificationReceiver.shareBackupPendingBroadcast(context, unifile.uri, Notifications.ID_BACKUP_COMPLETE), ) @@ -80,7 +82,7 @@ class BackupNotifier(private val context: Context) { fun showRestoreProgress(content: String = "", progress: Int = 0, maxAmount: Int = 100): NotificationCompat.Builder { val builder = with(progressNotificationBuilder) { - setContentTitle(context.getString(R.string.restoring_backup)) + setContentTitle(context.getString(MR.strings.restoring_backup)) if (!preferences.hideNotificationContent().get()) { setContentText(content) @@ -94,7 +96,7 @@ class BackupNotifier(private val context: Context) { addAction( R.drawable.ic_close_24dp, - context.getString(R.string.stop), + context.getString(MR.strings.stop), NotificationReceiver.cancelRestorePendingBroadcast(context, Notifications.ID_RESTORE_PROGRESS), ) } @@ -110,7 +112,7 @@ class BackupNotifier(private val context: Context) { context.notificationManager.cancel(Notifications.ID_RESTORE_PROGRESS) with(completeNotificationBuilder) { - setContentTitle(context.getString(R.string.restore_error)) + setContentTitle(context.getString(MR.strings.restore_error)) setContentText(error) show(Notifications.ID_RESTORE_COMPLETE) @@ -121,7 +123,7 @@ class BackupNotifier(private val context: Context) { context.notificationManager.cancel(Notifications.ID_RESTORE_PROGRESS) val timeString = context.getString( - R.string.restore_duration, + MR.strings.restore_duration, TimeUnit.MILLISECONDS.toMinutes(time), TimeUnit.MILLISECONDS.toSeconds(time) - TimeUnit.MINUTES.toSeconds( TimeUnit.MILLISECONDS.toMinutes(time), @@ -129,8 +131,8 @@ class BackupNotifier(private val context: Context) { ) with(completeNotificationBuilder) { - setContentTitle(context.getString(R.string.restore_completed)) - setContentText(context.resources.getQuantityString(R.plurals.restore_completed_message, errorCount, timeString, errorCount)) + setContentTitle(context.getString(MR.strings.restore_completed)) + setContentText(context.getString(MR.plurals.restore_completed_message, errorCount, timeString, errorCount)) // Clear old actions if they exist clearActions() @@ -141,7 +143,7 @@ class BackupNotifier(private val context: Context) { addAction( R.drawable.ic_eye_24dp, - context.getString(R.string.open_log), + context.getString(MR.strings.open_log), NotificationReceiver.openErrorOrSkippedLogPendingActivity(context, uri), ) } diff --git a/app/src/main/java/eu/kanade/tachiyomi/data/backup/create/BackupCreator.kt b/app/src/main/java/eu/kanade/tachiyomi/data/backup/create/BackupCreator.kt index 1d5cfad071..173bc97fcc 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/data/backup/create/BackupCreator.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/data/backup/create/BackupCreator.kt @@ -4,7 +4,6 @@ import android.content.Context import android.net.Uri import co.touchlab.kermit.Logger import com.hippo.unifile.UniFile -import eu.kanade.tachiyomi.R import eu.kanade.tachiyomi.data.backup.BackupFileValidator import eu.kanade.tachiyomi.data.backup.create.creators.CategoriesBackupCreator import eu.kanade.tachiyomi.data.backup.create.creators.MangaBackupCreator @@ -22,6 +21,8 @@ import uy.kohesive.injekt.Injekt import uy.kohesive.injekt.api.get import uy.kohesive.injekt.injectLazy import yokai.domain.storage.StorageManager +import yokai.i18n.MR +import yokai.util.lang.getString import java.io.FileOutputStream class BackupCreator( @@ -95,7 +96,7 @@ class BackupCreator( val byteArray = parser.encodeToByteArray(Backup.serializer(), backup!!) if (byteArray.isEmpty()) { - throw IllegalStateException(context.getString(R.string.empty_backup_error)) + throw IllegalStateException(context.getString(MR.strings.empty_backup_error)) } file.openOutputStream().also { diff --git a/app/src/main/java/eu/kanade/tachiyomi/data/backup/create/BackupOptions.kt b/app/src/main/java/eu/kanade/tachiyomi/data/backup/create/BackupOptions.kt index d6cbd820c7..322c4516bc 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/data/backup/create/BackupOptions.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/data/backup/create/BackupOptions.kt @@ -1,8 +1,8 @@ package eu.kanade.tachiyomi.data.backup.create -import androidx.annotation.StringRes -import eu.kanade.tachiyomi.R +import dev.icerock.moko.resources.StringResource import kotlinx.collections.immutable.persistentListOf +import yokai.i18n.MR data class BackupOptions( val libraryEntries: Boolean = true, @@ -31,72 +31,72 @@ data class BackupOptions( companion object { fun getOptions() = persistentListOf( - R.string.library_entries, - R.string.categories, - R.string.chapters, - R.string.tracking, - R.string.history, - R.string.app_settings, - R.string.source_settings, - R.string.custom_manga_info, - R.string.all_read_manga, - R.string.backup_private_pref, + MR.strings.library_entries, + MR.strings.categories, + MR.strings.chapters, + MR.strings.tracking, + MR.strings.history, + MR.strings.app_settings, + MR.strings.source_settings, + MR.strings.custom_manga_info, + MR.strings.all_read_manga, + MR.strings.backup_private_pref, ) fun getEntries() = persistentListOf( Entry( - label = R.string.library_entries, + label = MR.strings.library_entries, getter = BackupOptions::libraryEntries, setter = { options, enabled -> options.copy(libraryEntries = enabled) }, ), Entry( - label = R.string.categories, + label = MR.strings.categories, getter = BackupOptions::categories, setter = { options, enabled -> options.copy(categories = enabled) }, enabled = { it.libraryEntries }, ), Entry( - label = R.string.chapters, + label = MR.strings.chapters, getter = BackupOptions::chapters, setter = { options, enabled -> options.copy(chapters = enabled) }, enabled = { it.libraryEntries }, ), Entry( - label = R.string.tracking, + label = MR.strings.tracking, getter = BackupOptions::tracking, setter = { options, enabled -> options.copy(tracking = enabled) }, enabled = { it.libraryEntries }, ), Entry( - label = R.string.history, + label = MR.strings.history, getter = BackupOptions::history, setter = { options, enabled -> options.copy(history = enabled) }, enabled = { it.libraryEntries }, ), Entry( - label = R.string.custom_manga_info, + label = MR.strings.custom_manga_info, getter = BackupOptions::customInfo, setter = { options, enabled -> options.copy(customInfo = enabled) }, enabled = { it.libraryEntries }, ), Entry( - label = R.string.all_read_manga, + label = MR.strings.all_read_manga, getter = BackupOptions::readManga, setter = { options, enabled -> options.copy(readManga = enabled) }, enabled = { it.libraryEntries }, ), Entry( - label = R.string.app_settings, + label = MR.strings.app_settings, getter = BackupOptions::appPrefs, setter = { options, enabled -> options.copy(appPrefs = enabled) }, ), Entry( - label = R.string.source_settings, + label = MR.strings.source_settings, getter = BackupOptions::sourcePrefs, setter = { options, enabled -> options.copy(sourcePrefs = enabled) }, ), Entry( - label = R.string.backup_private_pref, + label = MR.strings.backup_private_pref, getter = BackupOptions::includePrivate, setter = { options, enabled -> options.copy(includePrivate = enabled) }, ), @@ -117,7 +117,7 @@ data class BackupOptions( } data class Entry( - @StringRes val label: Int, + val label: StringResource, val getter: (BackupOptions) -> Boolean, val setter: (BackupOptions, Boolean) -> BackupOptions, val enabled: (BackupOptions) -> Boolean = { true }, diff --git a/app/src/main/java/eu/kanade/tachiyomi/data/backup/restore/BackupRestoreJob.kt b/app/src/main/java/eu/kanade/tachiyomi/data/backup/restore/BackupRestoreJob.kt index adb75ae6de..f5777de392 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/data/backup/restore/BackupRestoreJob.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/data/backup/restore/BackupRestoreJob.kt @@ -12,7 +12,6 @@ import androidx.work.OutOfQuotaPolicy import androidx.work.WorkManager import androidx.work.WorkerParameters import androidx.work.workDataOf -import eu.kanade.tachiyomi.R import eu.kanade.tachiyomi.data.backup.BackupConst import eu.kanade.tachiyomi.data.backup.BackupNotifier import eu.kanade.tachiyomi.data.notification.Notifications @@ -21,6 +20,8 @@ import eu.kanade.tachiyomi.util.system.localeContext import eu.kanade.tachiyomi.util.system.tryToSetForeground import eu.kanade.tachiyomi.util.system.withIOContext import kotlinx.coroutines.CancellationException +import yokai.i18n.MR +import yokai.util.lang.getString class BackupRestoreJob(val context: Context, workerParams: WorkerParameters) : CoroutineWorker(context, workerParams) { @@ -47,11 +48,11 @@ class BackupRestoreJob(val context: Context, workerParams: WorkerParameters) : C withIOContext { try { if (!restorer.restoreBackup(uri)) { - notifier.showRestoreError(context.getString(R.string.restoring_backup_canceled)) + notifier.showRestoreError(context.getString(MR.strings.restoring_backup_canceled)) } } catch (exception: Exception) { if (exception is CancellationException) { - notifier.showRestoreError(context.getString(R.string.restoring_backup_canceled)) + notifier.showRestoreError(context.getString(MR.strings.restoring_backup_canceled)) } else { restorer.writeErrorLog() notifier.showRestoreError(exception.message) diff --git a/app/src/main/java/eu/kanade/tachiyomi/data/backup/restore/BackupRestorer.kt b/app/src/main/java/eu/kanade/tachiyomi/data/backup/restore/BackupRestorer.kt index 3147d0dde4..05b33caa93 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/data/backup/restore/BackupRestorer.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/data/backup/restore/BackupRestorer.kt @@ -2,7 +2,6 @@ package eu.kanade.tachiyomi.data.backup.restore import android.content.Context import android.net.Uri -import eu.kanade.tachiyomi.R import eu.kanade.tachiyomi.data.backup.BackupNotifier import eu.kanade.tachiyomi.data.backup.models.BackupSource import eu.kanade.tachiyomi.data.backup.restore.restorers.CategoriesBackupRestorer @@ -12,6 +11,8 @@ import eu.kanade.tachiyomi.util.BackupUtil import eu.kanade.tachiyomi.util.system.createFileInCacheDir import kotlinx.coroutines.coroutineScope import kotlinx.coroutines.isActive +import yokai.i18n.MR +import yokai.util.lang.getString import java.io.File import java.text.SimpleDateFormat import java.util.* @@ -65,17 +66,17 @@ class BackupRestorer( if (backup.backupCategories.isNotEmpty()) { categoriesBackupRestorer.restoreCategories(backup.backupCategories) { restoreProgress += 1 - showRestoreProgress(restoreProgress, restoreAmount, context.getString(R.string.categories)) + showRestoreProgress(restoreProgress, restoreAmount, context.getString(MR.strings.categories)) } } preferenceBackupRestorer.restoreAppPreferences(backup.backupPreferences) { restoreProgress += 1 - showRestoreProgress(restoreProgress, restoreAmount, context.getString(R.string.app_settings)) + showRestoreProgress(restoreProgress, restoreAmount, context.getString(MR.strings.app_settings)) } preferenceBackupRestorer.restoreSourcePreferences(backup.backupSourcePreferences) { restoreProgress += 1 - showRestoreProgress(restoreProgress, restoreAmount, context.getString(R.string.source_settings)) + showRestoreProgress(restoreProgress, restoreAmount, context.getString(MR.strings.source_settings)) } // Restore individual manga diff --git a/app/src/main/java/eu/kanade/tachiyomi/data/cache/CoverCache.kt b/app/src/main/java/eu/kanade/tachiyomi/data/cache/CoverCache.kt index dba239d351..869a183916 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/data/cache/CoverCache.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/data/cache/CoverCache.kt @@ -5,7 +5,6 @@ import android.text.format.Formatter import co.touchlab.kermit.Logger import coil3.imageLoader import coil3.memory.MemoryCache -import eu.kanade.tachiyomi.R import eu.kanade.tachiyomi.data.database.DatabaseHelper import eu.kanade.tachiyomi.data.database.models.Manga import eu.kanade.tachiyomi.data.database.models.MangaImpl @@ -19,10 +18,12 @@ import kotlinx.coroutines.Dispatchers import kotlinx.coroutines.withContext import uy.kohesive.injekt.Injekt import uy.kohesive.injekt.api.get +import yokai.i18n.MR +import yokai.util.lang.getString import java.io.File import java.io.IOException import java.io.InputStream -import java.util.concurrent.TimeUnit +import java.util.concurrent.* /** * Class used to create cover cache. @@ -85,7 +86,7 @@ class CoverCache(val context: Context) { withUIContext { context.toast( context.getString( - R.string.deleted_, + MR.strings.deleted_, Formatter.formatFileSize(context, deletedSize), ), ) @@ -108,7 +109,7 @@ class CoverCache(val context: Context) { withContext(Dispatchers.Main) { context.toast( context.getString( - R.string.deleted_, + MR.strings.deleted_, Formatter.formatFileSize(context, deletedSize), ), ) diff --git a/app/src/main/java/eu/kanade/tachiyomi/data/database/models/Category.kt b/app/src/main/java/eu/kanade/tachiyomi/data/database/models/Category.kt index 59c411db23..0e5eb31de8 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/data/database/models/Category.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/data/database/models/Category.kt @@ -1,9 +1,10 @@ package eu.kanade.tachiyomi.data.database.models import android.content.Context -import androidx.annotation.StringRes -import eu.kanade.tachiyomi.R +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.ui.library.LibrarySort +import yokai.i18n.MR +import yokai.util.lang.getString import java.io.Serializable interface Category : Serializable { @@ -45,8 +46,7 @@ interface Category : Serializable { mangaSort == LibrarySort.DragAndDrop.categoryValue ) && !isDynamic - @StringRes - fun sortRes(): Int = + fun sortRes(): StringResource = (LibrarySort.valueOf(mangaSort) ?: LibrarySort.DragAndDrop).stringRes(isDynamic) fun changeSortTo(sort: Int) { @@ -61,7 +61,7 @@ interface Category : Serializable { } fun createDefault(context: Context): Category = - create(context.getString(R.string.default_value)).apply { + create(context.getString(MR.strings.default_value)).apply { id = 0 isSystem = true } @@ -77,7 +77,7 @@ interface Category : Serializable { } fun createAll(context: Context, libSort: Int, ascending: Boolean): Category = - createCustom(context.getString(R.string.all), libSort, ascending).apply { + createCustom(context.getString(MR.strings.all), libSort, ascending).apply { id = -1 order = -1 isAlone = true diff --git a/app/src/main/java/eu/kanade/tachiyomi/data/database/models/Manga.kt b/app/src/main/java/eu/kanade/tachiyomi/data/database/models/Manga.kt index 3de8914a36..d0e691b5e6 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/data/database/models/Manga.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/data/database/models/Manga.kt @@ -2,6 +2,9 @@ package eu.kanade.tachiyomi.data.database.models import android.content.Context import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.database.DatabaseHelper import eu.kanade.tachiyomi.data.preference.PreferencesHelper import eu.kanade.tachiyomi.source.SourceManager @@ -138,11 +141,11 @@ interface Manga : SManga { fun seriesType(context: Context, sourceManager: SourceManager? = null): String { return context.getString( when (seriesType(sourceManager = sourceManager)) { - TYPE_WEBTOON -> R.string.webtoon - TYPE_MANHWA -> R.string.manhwa - TYPE_MANHUA -> R.string.manhua - TYPE_COMIC -> R.string.comic - else -> R.string.manga + TYPE_WEBTOON -> MR.strings.webtoon + TYPE_MANHWA -> MR.strings.manhwa + TYPE_MANHUA -> MR.strings.manhua + TYPE_COMIC -> MR.strings.comic + else -> MR.strings.manga }, ).lowercase(Locale.getDefault()) } diff --git a/app/src/main/java/eu/kanade/tachiyomi/data/download/DownloadJob.kt b/app/src/main/java/eu/kanade/tachiyomi/data/download/DownloadJob.kt index 3296c64647..4627af8e44 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/data/download/DownloadJob.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/data/download/DownloadJob.kt @@ -13,7 +13,6 @@ import androidx.work.WorkInfo import androidx.work.WorkManager import androidx.work.WorkerParameters import androidx.work.workDataOf -import eu.kanade.tachiyomi.R import eu.kanade.tachiyomi.data.notification.Notifications import eu.kanade.tachiyomi.data.preference.PreferencesHelper import eu.kanade.tachiyomi.extension.ExtensionUpdateJob @@ -27,6 +26,8 @@ import kotlinx.coroutines.flow.MutableSharedFlow import kotlinx.coroutines.flow.asSharedFlow import uy.kohesive.injekt.Injekt import uy.kohesive.injekt.api.get +import yokai.i18n.MR +import yokai.util.lang.getString /** * This worker is used to manage the downloader. The system can decide to stop the worker, in @@ -81,11 +82,11 @@ class DownloadJob(val context: Context, workerParams: WorkerParameters) : Corout if (isOnline()) { val noWifi = preferences.downloadOnlyOverWifi().get() && !isConnectedToWifi() if (noWifi) { - downloadManager.stopDownloads(applicationContext.getString(R.string.no_wifi_connection)) + downloadManager.stopDownloads(applicationContext.getString(MR.strings.no_wifi_connection)) } !noWifi } else { - downloadManager.stopDownloads(applicationContext.getString(R.string.no_network_connection)) + downloadManager.stopDownloads(applicationContext.getString(MR.strings.no_network_connection)) false } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/data/download/DownloadManager.kt b/app/src/main/java/eu/kanade/tachiyomi/data/download/DownloadManager.kt index d95f4aaf36..b7b83d1349 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/data/download/DownloadManager.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/data/download/DownloadManager.kt @@ -3,7 +3,6 @@ package eu.kanade.tachiyomi.data.download import android.content.Context import co.touchlab.kermit.Logger import com.hippo.unifile.UniFile -import eu.kanade.tachiyomi.R import eu.kanade.tachiyomi.data.database.models.Chapter import eu.kanade.tachiyomi.data.database.models.Manga import eu.kanade.tachiyomi.data.download.model.Download @@ -18,6 +17,8 @@ import kotlinx.coroutines.GlobalScope import kotlinx.coroutines.launch import uy.kohesive.injekt.injectLazy import yokai.domain.download.DownloadPreferences +import yokai.i18n.MR +import yokai.util.lang.getString /** * This class is used to manage chapter downloads in the application. It must be instantiated once @@ -182,7 +183,7 @@ class DownloadManager(val context: Context) { .filter { "image" in it.type.orEmpty() } if (files.isEmpty()) { - throw Exception(context.getString(R.string.no_pages_found)) + throw Exception(context.getString(MR.strings.no_pages_found)) } return files.sortedBy { it.name } diff --git a/app/src/main/java/eu/kanade/tachiyomi/data/download/DownloadNotifier.kt b/app/src/main/java/eu/kanade/tachiyomi/data/download/DownloadNotifier.kt index 99a0ea7cc2..ae8260b386 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/data/download/DownloadNotifier.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/data/download/DownloadNotifier.kt @@ -19,6 +19,8 @@ import eu.kanade.tachiyomi.util.system.localeContext import eu.kanade.tachiyomi.util.system.notificationBuilder import eu.kanade.tachiyomi.util.system.notificationManager import uy.kohesive.injekt.injectLazy +import yokai.i18n.MR +import yokai.util.lang.getString import java.util.regex.* import android.R as AR @@ -82,7 +84,7 @@ internal class DownloadNotifier(private val context: Context) { // Pause action addAction( R.drawable.ic_pause_24dp, - context.getString(R.string.pause), + context.getString(MR.strings.pause), NotificationReceiver.pauseDownloadsPendingBroadcast(context), ) } @@ -97,9 +99,9 @@ internal class DownloadNotifier(private val context: Context) { "", ) setContentTitle("$title - $chapter".chop(30)) - setContentText(context.getString(R.string.downloading)) + setContentText(context.getString(MR.strings.downloading)) } else { - setContentTitle(context.getString(R.string.downloading)) + setContentTitle(context.getString(MR.strings.downloading)) setContentText(null) } setProgress(0, 0, true) @@ -129,13 +131,13 @@ internal class DownloadNotifier(private val context: Context) { // Pause action addAction( R.drawable.ic_pause_24dp, - context.getString(R.string.pause), + context.getString(MR.strings.pause), NotificationReceiver.pauseDownloadsPendingBroadcast(context), ) } val downloadingProgressText = - context.localeContext.getString(R.string.downloading_progress) + context.localeContext.getString(MR.strings.downloading_progress) .format(download.downloadedImages, download.pages!!.size) if (preferences.hideNotificationContent().get()) { @@ -164,8 +166,8 @@ internal class DownloadNotifier(private val context: Context) { fun onDownloadPaused() { val context = context.localeContext with(notification) { - setContentTitle(context.getString(R.string.paused)) - setContentText(context.getString(R.string.download_paused)) + setContentTitle(context.getString(MR.strings.paused)) + setContentText(context.getString(MR.strings.download_paused)) setSmallIcon(R.drawable.ic_pause_24dp) setAutoCancel(false) setOngoing(false) @@ -177,13 +179,13 @@ internal class DownloadNotifier(private val context: Context) { // Resume action addAction( R.drawable.ic_play_arrow_24dp, - context.getString(R.string.resume), + context.getString(MR.strings.resume), NotificationReceiver.resumeDownloadsPendingBroadcast(context), ) // Clear action addAction( R.drawable.ic_close_24dp, - context.getString(R.string.cancel_all), + context.getString(MR.strings.cancel_all), NotificationReceiver.clearDownloadsPendingBroadcast(context), ) show() @@ -201,7 +203,7 @@ internal class DownloadNotifier(private val context: Context) { fun onWarning(reason: String) { val context = context.localeContext with(notification) { - setContentTitle(context.getString(R.string.downloads)) + setContentTitle(context.getString(MR.strings.downloads)) setContentText(reason) color = ContextCompat.getColor(context, R.color.secondaryTachiyomi) setSmallIcon(R.drawable.ic_warning_white_24dp) @@ -223,11 +225,11 @@ internal class DownloadNotifier(private val context: Context) { fun massDownloadWarning() { val context = context.localeContext val notification = context.notificationBuilder(Notifications.CHANNEL_DOWNLOADER) { - setContentTitle(context.getString(R.string.warning)) + setContentTitle(context.getString(MR.strings.warning)) setSmallIcon(R.drawable.ic_warning_white_24dp) setStyle( NotificationCompat.BigTextStyle() - .bigText(context.getString(R.string.download_queue_size_warning)), + .bigText(context.getString(MR.strings.download_queue_size_warning)), ) setContentIntent( NotificationHandler.openUrl( @@ -262,12 +264,12 @@ internal class DownloadNotifier(private val context: Context) { val context = context.localeContext with(notification) { setContentTitle( - mangaTitle?.plus(": $chapter") ?: context.getString(R.string.download_error), + mangaTitle?.plus(": $chapter") ?: context.getString(MR.strings.download_error), ) - setContentText(error ?: context.getString(R.string.could_not_download_unexpected_error)) + setContentText(error ?: context.getString(MR.strings.could_not_download_unexpected_error)) setStyle( NotificationCompat.BigTextStyle().bigText( - error ?: context.getString(R.string.could_not_download_unexpected_error), + error ?: context.getString(MR.strings.could_not_download_unexpected_error), ), ) setSmallIcon(AR.drawable.stat_sys_warning) diff --git a/app/src/main/java/eu/kanade/tachiyomi/data/download/DownloadProvider.kt b/app/src/main/java/eu/kanade/tachiyomi/data/download/DownloadProvider.kt index 365bb00b2b..caee7e5dae 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/data/download/DownloadProvider.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/data/download/DownloadProvider.kt @@ -2,7 +2,6 @@ package eu.kanade.tachiyomi.data.download import android.content.Context import com.hippo.unifile.UniFile -import eu.kanade.tachiyomi.R import eu.kanade.tachiyomi.data.database.DatabaseHelper import eu.kanade.tachiyomi.data.database.models.Chapter import eu.kanade.tachiyomi.data.database.models.Manga @@ -17,6 +16,8 @@ import kotlinx.coroutines.flow.onEach import uy.kohesive.injekt.injectLazy import yokai.domain.download.DownloadPreferences import yokai.domain.storage.StorageManager +import yokai.i18n.MR +import yokai.util.lang.getString /** * This class is used to provide the directories where the downloads should be saved. @@ -56,7 +57,7 @@ class DownloadProvider(private val context: Context) { return downloadsDir?.createDirectory(getSourceDirName(source))!! .createDirectory(getMangaDirName(manga))!! } catch (e: NullPointerException) { - throw Exception(context.getString(R.string.invalid_download_location)) + throw Exception(context.getString(MR.strings.invalid_download_location)) } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/data/download/Downloader.kt b/app/src/main/java/eu/kanade/tachiyomi/data/download/Downloader.kt index cb933673c0..a5f5fec7e6 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/data/download/Downloader.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/data/download/Downloader.kt @@ -6,7 +6,6 @@ import android.os.Looper import co.touchlab.kermit.Logger import com.hippo.unifile.UniFile import com.jakewharton.rxrelay.PublishRelay -import eu.kanade.tachiyomi.R import eu.kanade.tachiyomi.data.cache.ChapterCache import eu.kanade.tachiyomi.data.database.DatabaseHelper import eu.kanade.tachiyomi.data.database.models.Chapter @@ -52,6 +51,8 @@ import yokai.core.metadata.COMIC_INFO_FILE import yokai.core.metadata.ComicInfo import yokai.core.metadata.getComicInfo import yokai.domain.download.DownloadPreferences +import yokai.i18n.MR +import yokai.util.lang.getString import java.io.BufferedOutputStream import java.io.File import java.util.zip.* @@ -336,7 +337,7 @@ class Downloader( val chapName = download.chapter.preferredChapterName(context, download.manga, preferences) if (availSpace != -1L && availSpace < MIN_DISK_SPACE) { download.status = Download.State.ERROR - notifier.onError(context.getString(R.string.couldnt_download_low_space), chapName) + notifier.onError(context.getString(MR.strings.couldnt_download_low_space), chapName) return } val chapterDirname = provider.getChapterDirName(download.chapter, includeId = downloadPreferences.downloadWithId().get()) @@ -349,7 +350,7 @@ class Downloader( val pages = download.source.getPageList(download.chapter) if (pages.isEmpty()) { - throw Exception(context.getString(R.string.no_pages_found)) + throw Exception(context.getString(MR.strings.no_pages_found)) } // Don't trust index from source val reIndexedPages = pages.mapIndexed { index, page -> @@ -549,9 +550,9 @@ class Downloader( val filename = String.format("%03d", page.number) val imageFile = tmpDir.listFiles()?.find { it.name.orEmpty().startsWith(filename) } - ?: throw Error(context.getString(R.string.download_notifier_split_page_not_found, page.number)) + ?: throw Error(context.getString(MR.strings.download_notifier_split_page_not_found, page.number)) val imageFilePath = imageFile.filePath - ?: throw Error(context.getString(R.string.download_notifier_split_page_not_found, page.number)) + ?: throw Error(context.getString(MR.strings.download_notifier_split_page_not_found, page.number)) // check if the original page was previously split before then skip. if (imageFile.name.orEmpty().contains("__")) return true diff --git a/app/src/main/java/eu/kanade/tachiyomi/data/library/LibraryUpdateJob.kt b/app/src/main/java/eu/kanade/tachiyomi/data/library/LibraryUpdateJob.kt index 49c4de2e51..b25a481256 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/data/library/LibraryUpdateJob.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/data/library/LibraryUpdateJob.kt @@ -21,6 +21,9 @@ import coil3.imageLoader import coil3.request.CachePolicy import coil3.request.ImageRequest import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.cache.CoverCache import eu.kanade.tachiyomi.data.database.DatabaseHelper import eu.kanade.tachiyomi.data.database.models.Category @@ -349,7 +352,7 @@ class LibraryUpdateJob(private val context: Context, workerParams: WorkerParamet val skippedFile = writeErrorFile( skippedUpdates, "skipped", - context.getString(R.string.learn_why) + " - " + LibraryUpdateNotifier.HELP_SKIPPED_URL, + context.getString(MR.strings.learn_why) + " - " + LibraryUpdateNotifier.HELP_SKIPPED_URL, ).getUriCompat(context) notifier.showUpdateSkippedNotification(skippedUpdates.map { it.key.title }, skippedFile) } @@ -454,16 +457,16 @@ class LibraryUpdateJob(private val context: Context, workerParams: WorkerParamet return mangaToAdd.filter { manga -> when { MANGA_NON_COMPLETED in restrictions && manga.status == SManga.COMPLETED -> { - skippedUpdates[manga] = context.getString(R.string.skipped_reason_completed) + skippedUpdates[manga] = context.getString(MR.strings.skipped_reason_completed) } MANGA_HAS_UNREAD in restrictions && manga.unread != 0 -> { - skippedUpdates[manga] = context.getString(R.string.skipped_reason_not_caught_up) + skippedUpdates[manga] = context.getString(MR.strings.skipped_reason_not_caught_up) } MANGA_NON_READ in restrictions && manga.totalChapters > 0 && !manga.hasRead -> { - skippedUpdates[manga] = context.getString(R.string.skipped_reason_not_started) + skippedUpdates[manga] = context.getString(MR.strings.skipped_reason_not_started) } manga.update_strategy != UpdateStrategy.ALWAYS_UPDATE -> { - skippedUpdates[manga] = context.getString(R.string.skipped_reason_not_always_update) + skippedUpdates[manga] = context.getString(MR.strings.skipped_reason_not_always_update) } else -> { return@filter true diff --git a/app/src/main/java/eu/kanade/tachiyomi/data/library/LibraryUpdateNotifier.kt b/app/src/main/java/eu/kanade/tachiyomi/data/library/LibraryUpdateNotifier.kt index aa58b46cd8..52bac14c8a 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/data/library/LibraryUpdateNotifier.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/data/library/LibraryUpdateNotifier.kt @@ -19,6 +19,9 @@ import coil3.request.ImageRequest import coil3.request.transformations import coil3.transform.CircleCropTransformation import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.database.models.Chapter import eu.kanade.tachiyomi.data.database.models.LibraryManga import eu.kanade.tachiyomi.data.database.models.Manga @@ -61,7 +64,7 @@ class LibraryUpdateNotifier(private val context: Context) { */ val progressNotificationBuilder by lazy { context.notificationBuilder(Notifications.CHANNEL_LIBRARY_PROGRESS) { - setContentTitle(context.getString(R.string.updating_library)) + setContentTitle(context.getString(MR.strings.updating_library)) setSmallIcon(R.drawable.ic_refresh_24dp) setLargeIcon(notificationBitmap) setOngoing(true) @@ -83,7 +86,7 @@ class LibraryUpdateNotifier(private val context: Context) { context.notificationManager.notify( Notifications.ID_LIBRARY_PROGRESS, progressNotificationBuilder - .setContentTitle("${context.getString(R.string.updating_library)} (${current + 1}/$total)") + .setContentTitle("${context.getString(MR.strings.updating_library)} (${current + 1}/$total)") .setContentText(if (preferences.hideNotificationContent().get()) null else manga.title) .setProgress(total, current, false) .build(), @@ -104,8 +107,8 @@ class LibraryUpdateNotifier(private val context: Context) { context.notificationManager.notify( Notifications.ID_LIBRARY_ERROR, context.notificationBuilder(Notifications.CHANNEL_LIBRARY_ERROR) { - setContentTitle(context.getString(R.string.notification_update_error, errors.size)) - setContentText(context.getString(R.string.tap_to_see_details)) + setContentTitle(context.getString(MR.strings.notification_update_error, errors.size)) + setContentText(context.getString(MR.strings.tap_to_see_details)) setStyle( NotificationCompat.BigTextStyle().bigText( errors.joinToString("\n") { @@ -117,7 +120,7 @@ class LibraryUpdateNotifier(private val context: Context) { setSmallIcon(R.drawable.ic_yokai) addAction( R.drawable.ic_file_open_24dp, - context.getString(R.string.open_log), + context.getString(MR.strings.open_log), pendingIntent, ) } @@ -139,8 +142,8 @@ class LibraryUpdateNotifier(private val context: Context) { context.notificationManager.notify( Notifications.ID_LIBRARY_SKIPPED, context.notificationBuilder(Notifications.CHANNEL_LIBRARY_SKIPPED) { - setContentTitle(context.getString(R.string.notification_update_skipped, skips.size)) - setContentText(context.getString(R.string.tap_to_learn_more)) + setContentTitle(context.getString(MR.strings.notification_update_skipped, skips.size)) + setContentText(context.getString(MR.strings.tap_to_learn_more)) setStyle( NotificationCompat.BigTextStyle().bigText( skips.joinToString("\n") { @@ -152,12 +155,12 @@ class LibraryUpdateNotifier(private val context: Context) { setSmallIcon(R.drawable.ic_yokai) addAction( R.drawable.ic_file_open_24dp, - context.getString(R.string.open_log), + context.getString(MR.strings.open_log), NotificationReceiver.openErrorOrSkippedLogPendingActivity(context, uri), ) addAction( R.drawable.ic_help_outline_24dp, - context.getString(R.string.learn_why), + context.getString(MR.strings.learn_why), NotificationHandler.openUrl(context, HELP_SKIPPED_URL), ) } @@ -205,8 +208,8 @@ class LibraryUpdateNotifier(private val context: Context) { color = ContextCompat.getColor(context, R.color.secondaryTachiyomi) val chaptersNames = if (chapterNames.size > MAX_CHAPTERS) { "${chapterNames.take(MAX_CHAPTERS - 1).joinToString(", ")}, " + - context.resources.getQuantityString( - R.plurals.notification_and_n_more, + context.getString( + MR.plurals.notification_and_n_more, (chapterNames.size - (MAX_CHAPTERS - 1)), (chapterNames.size - (MAX_CHAPTERS - 1)), ) @@ -226,7 +229,7 @@ class LibraryUpdateNotifier(private val context: Context) { ) addAction( R.drawable.ic_eye_24dp, - context.getString(R.string.mark_as_read), + context.getString(MR.strings.mark_as_read), NotificationReceiver.markAsReadPendingBroadcast( context, manga, @@ -236,7 +239,7 @@ class LibraryUpdateNotifier(private val context: Context) { ) addAction( R.drawable.ic_book_24dp, - context.getString(R.string.view_chapters), + context.getString(MR.strings.view_chapters), NotificationReceiver.openChapterPendingActivity( context, manga, @@ -262,12 +265,12 @@ class LibraryUpdateNotifier(private val context: Context) { context.notification(Notifications.CHANNEL_NEW_CHAPTERS) { setSmallIcon(R.drawable.ic_yokai) setLargeIcon(notificationBitmap) - setContentTitle(context.getString(R.string.new_chapters_found)) + setContentTitle(context.getString(MR.strings.new_chapters_found)) color = ContextCompat.getColor(context, R.color.secondaryTachiyomi) if (updates.size > 1) { setContentText( - context.resources.getQuantityString( - R.plurals.for_n_titles, + context.getString( + MR.plurals.for_n_titles, updates.size, updates.size, ), @@ -303,9 +306,9 @@ class LibraryUpdateNotifier(private val context: Context) { fun showQueueSizeWarningNotification() { val notification = context.notificationBuilder(Notifications.CHANNEL_LIBRARY_PROGRESS) { - setContentTitle(context.getString(R.string.warning)) + setContentTitle(context.getString(MR.strings.warning)) setSmallIcon(R.drawable.ic_warning_white_24dp) - setStyle(NotificationCompat.BigTextStyle().bigText(context.getString(R.string.notification_size_warning))) + setStyle(NotificationCompat.BigTextStyle().bigText(context.getString(MR.strings.notification_size_warning))) setContentIntent(NotificationHandler.openUrl(context, HELP_WARNING_URL)) setTimeoutAfter(30000) } diff --git a/app/src/main/java/eu/kanade/tachiyomi/data/notification/Notifications.kt b/app/src/main/java/eu/kanade/tachiyomi/data/notification/Notifications.kt index 70293dd6aa..902c9b90ec 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/data/notification/Notifications.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/data/notification/Notifications.kt @@ -8,6 +8,9 @@ import android.content.Context import android.os.Build import androidx.core.app.NotificationManagerCompat import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.util.system.notificationManager /** @@ -105,25 +108,25 @@ object Notifications { listOf( NotificationChannelGroup( GROUP_BACKUP_RESTORE, - context.getString(R.string.backup_and_restore), + context.getString(MR.strings.backup_and_restore), ), NotificationChannelGroup( GROUP_EXTENSION_UPDATES, - context.getString(R.string.extension_updates), + context.getString(MR.strings.extension_updates), ), - NotificationChannelGroup(GROUP_APP_UPDATES, context.getString(R.string.app_updates)), - NotificationChannelGroup(GROUP_LIBRARY, context.getString(R.string.library)), + NotificationChannelGroup(GROUP_APP_UPDATES, context.getString(MR.strings.app_updates)), + NotificationChannelGroup(GROUP_LIBRARY, context.getString(MR.strings.library)), ).forEach(context.notificationManager::createNotificationChannelGroup) val channels = listOf( NotificationChannel( CHANNEL_COMMON, - context.getString(R.string.common), + context.getString(MR.strings.common), NotificationManager.IMPORTANCE_LOW, ), NotificationChannel( CHANNEL_LIBRARY_PROGRESS, - context.getString(R.string.updating_library), + context.getString(MR.strings.updating_library), NotificationManager.IMPORTANCE_LOW, ).apply { group = GROUP_LIBRARY @@ -131,7 +134,7 @@ object Notifications { }, NotificationChannel( CHANNEL_LIBRARY_ERROR, - context.getString(R.string.channel_errors), + context.getString(MR.strings.channel_errors), NotificationManager.IMPORTANCE_LOW, ).apply { group = GROUP_LIBRARY @@ -139,7 +142,7 @@ object Notifications { }, NotificationChannel( CHANNEL_LIBRARY_SKIPPED, - context.getString(R.string.channel_skipped), + context.getString(MR.strings.channel_skipped), NotificationManager.IMPORTANCE_LOW, ).apply { group = GROUP_LIBRARY @@ -147,28 +150,28 @@ object Notifications { }, NotificationChannel( CHANNEL_DOWNLOADER, - context.getString(R.string.downloads), + context.getString(MR.strings.downloads), NotificationManager.IMPORTANCE_LOW, ).apply { setShowBadge(false) }, NotificationChannel( CHANNEL_UPDATES_TO_EXTS, - context.getString(R.string.extension_updates_pending), + context.getString(MR.strings.extension_updates_pending), NotificationManager.IMPORTANCE_DEFAULT, ).apply { group = GROUP_EXTENSION_UPDATES }, NotificationChannel( CHANNEL_NEW_CHAPTERS, - context.getString(R.string.new_chapters), + context.getString(MR.strings.new_chapters), NotificationManager.IMPORTANCE_DEFAULT, ).apply { group = GROUP_LIBRARY }, NotificationChannel( CHANNEL_BACKUP_RESTORE_PROGRESS, - context.getString(R.string.progress), + context.getString(MR.strings.progress), NotificationManager.IMPORTANCE_LOW, ).apply { group = GROUP_BACKUP_RESTORE @@ -176,7 +179,7 @@ object Notifications { }, NotificationChannel( CHANNEL_BACKUP_RESTORE_COMPLETE, - context.getString(R.string.complete), + context.getString(MR.strings.complete), NotificationManager.IMPORTANCE_HIGH, ).apply { group = GROUP_BACKUP_RESTORE @@ -185,19 +188,19 @@ object Notifications { }, NotificationChannel( CHANNEL_CRASH_LOGS, - context.getString(R.string.crash_logs), + context.getString(MR.strings.crash_logs), NotificationManager.IMPORTANCE_HIGH, ), NotificationChannel( CHANNEL_INCOGNITO_MODE, - context.getString(R.string.incognito_mode), + context.getString(MR.strings.incognito_mode), NotificationManager.IMPORTANCE_LOW, ).apply { lockscreenVisibility = Notification.VISIBILITY_SECRET }, NotificationChannel( CHANNEL_EXT_PROGRESS, - context.getString(R.string.updating_extensions), + context.getString(MR.strings.updating_extensions), NotificationManager.IMPORTANCE_LOW, ).apply { group = GROUP_EXTENSION_UPDATES @@ -206,14 +209,14 @@ object Notifications { }, NotificationChannel( CHANNEL_EXT_UPDATED, - context.getString(R.string.extensions_updated), + context.getString(MR.strings.extensions_updated), NotificationManager.IMPORTANCE_DEFAULT, ).apply { group = GROUP_EXTENSION_UPDATES }, NotificationChannel( CHANNEL_INSTALLING, - context.getString(R.string.installing), + context.getString(MR.strings.installing), NotificationManager.IMPORTANCE_HIGH, ).apply { setShowBadge(false) @@ -223,7 +226,7 @@ object Notifications { }, NotificationChannel( CHANNEL_UPDATED, - context.getString(R.string.update_completed), + context.getString(MR.strings.update_completed), NotificationManager.IMPORTANCE_HIGH, ).apply { setShowBadge(false) diff --git a/app/src/main/java/eu/kanade/tachiyomi/data/preference/PreferenceValues.kt b/app/src/main/java/eu/kanade/tachiyomi/data/preference/PreferenceValues.kt index 8c3a44eace..b3a162a913 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/data/preference/PreferenceValues.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/data/preference/PreferenceValues.kt @@ -1,7 +1,11 @@ package eu.kanade.tachiyomi.data.preference import androidx.annotation.StringRes +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource // Library const val MANGA_NON_COMPLETED = "manga_ongoing" @@ -14,23 +18,23 @@ const val DEVICE_CHARGING = "ac" const val DEVICE_BATTERY_NOT_LOW = "battery_not_low" object PreferenceValues { - enum class SecureScreenMode(val titleResId: Int) { - ALWAYS(R.string.always), - INCOGNITO(R.string.incognito_mode), - NEVER(R.string.never), + enum class SecureScreenMode(val titleResId: StringResource) { + ALWAYS(MR.strings.always), + INCOGNITO(MR.strings.incognito_mode), + NEVER(MR.strings.never), } - enum class ReaderHideThreshold(val titleResId: Int, val threshold: Int) { - HIGHEST(R.string.pref_highest, 5), - HIGH(R.string.pref_high, 13), - LOW(R.string.pref_low, 31), - LOWEST(R.string.pref_lowest, 47), + enum class ReaderHideThreshold(val titleResId: StringResource, val threshold: Int) { + HIGHEST(MR.strings.pref_highest, 5), + HIGH(MR.strings.pref_high, 13), + LOW(MR.strings.pref_low, 31), + LOWEST(MR.strings.pref_lowest, 47), } - enum class MigrationSourceOrder(val value: Int, @StringRes val titleResId: Int) { - Alphabetically(0, R.string.alphabetically), - MostEntries(1, R.string.most_entries), - Obsolete(2, R.string.obsolete), + enum class MigrationSourceOrder(val value: Int, val titleResId: StringResource) { + Alphabetically(0, MR.strings.alphabetically), + MostEntries(1, MR.strings.most_entries), + Obsolete(2, MR.strings.obsolete), ; companion object { diff --git a/app/src/main/java/eu/kanade/tachiyomi/data/track/TrackService.kt b/app/src/main/java/eu/kanade/tachiyomi/data/track/TrackService.kt index a6636d4bd9..d5777eb058 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/data/track/TrackService.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/data/track/TrackService.kt @@ -3,6 +3,7 @@ package eu.kanade.tachiyomi.data.track import androidx.annotation.CallSuper import androidx.annotation.DrawableRes import androidx.annotation.StringRes +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.data.database.DatabaseHelper import eu.kanade.tachiyomi.data.database.models.Track import eu.kanade.tachiyomi.data.track.model.TrackSearch @@ -21,8 +22,7 @@ abstract class TrackService(val id: Int) { get() = networkService.client // Name of the manga sync service to display - @StringRes - abstract fun nameRes(): Int + abstract fun nameRes(): StringResource // Application and remote support for reading dates open val supportsReadingDates: Boolean = false diff --git a/app/src/main/java/eu/kanade/tachiyomi/data/track/anilist/Anilist.kt b/app/src/main/java/eu/kanade/tachiyomi/data/track/anilist/Anilist.kt index b1e11d1729..e46b89991a 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/data/track/anilist/Anilist.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/data/track/anilist/Anilist.kt @@ -2,7 +2,6 @@ package eu.kanade.tachiyomi.data.track.anilist import android.content.Context import android.graphics.Color -import androidx.annotation.StringRes import co.touchlab.kermit.Logger import eu.kanade.tachiyomi.R import eu.kanade.tachiyomi.data.database.models.Track @@ -12,6 +11,8 @@ import eu.kanade.tachiyomi.util.system.e import kotlinx.serialization.encodeToString import kotlinx.serialization.json.Json import uy.kohesive.injekt.injectLazy +import yokai.i18n.MR +import yokai.util.lang.getString class Anilist(private val context: Context, id: Int) : TrackService(id) { @@ -53,8 +54,7 @@ class Anilist(private val context: Context, id: Int) : TrackService(id) { } } - @StringRes - override fun nameRes() = R.string.anilist + override fun nameRes() = MR.strings.anilist override fun getLogo() = R.drawable.ic_tracker_anilist @@ -72,24 +72,24 @@ class Anilist(private val context: Context, id: Int) : TrackService(id) { override fun getStatus(status: Int): String = with(context) { when (status) { - READING -> getString(R.string.reading) - PLAN_TO_READ -> getString(R.string.plan_to_read) - COMPLETED -> getString(R.string.completed) - PAUSED -> getString(R.string.paused) - DROPPED -> getString(R.string.dropped) - REREADING -> getString(R.string.rereading) + READING -> getString(MR.strings.reading) + PLAN_TO_READ -> getString(MR.strings.plan_to_read) + COMPLETED -> getString(MR.strings.completed) + PAUSED -> getString(MR.strings.paused) + DROPPED -> getString(MR.strings.dropped) + REREADING -> getString(MR.strings.rereading) else -> "" } } override fun getGlobalStatus(status: Int): String = with(context) { when (status) { - READING -> getString(R.string.reading) - PLAN_TO_READ -> getString(R.string.plan_to_read) - COMPLETED -> getString(R.string.completed) - PAUSED -> getString(R.string.on_hold) - DROPPED -> getString(R.string.dropped) - REREADING -> getString(R.string.rereading) + READING -> getString(MR.strings.reading) + PLAN_TO_READ -> getString(MR.strings.plan_to_read) + COMPLETED -> getString(MR.strings.completed) + PAUSED -> getString(MR.strings.on_hold) + DROPPED -> getString(MR.strings.dropped) + REREADING -> getString(MR.strings.rereading) else -> "" } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/data/track/bangumi/Bangumi.kt b/app/src/main/java/eu/kanade/tachiyomi/data/track/bangumi/Bangumi.kt index f4c5ac3c3d..76424b9109 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/data/track/bangumi/Bangumi.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/data/track/bangumi/Bangumi.kt @@ -2,7 +2,6 @@ package eu.kanade.tachiyomi.data.track.bangumi import android.content.Context import android.graphics.Color -import androidx.annotation.StringRes import co.touchlab.kermit.Logger import eu.kanade.tachiyomi.R import eu.kanade.tachiyomi.data.database.models.Track @@ -13,11 +12,12 @@ import eu.kanade.tachiyomi.util.system.e import kotlinx.serialization.encodeToString import kotlinx.serialization.json.Json import uy.kohesive.injekt.injectLazy +import yokai.i18n.MR +import yokai.util.lang.getString class Bangumi(private val context: Context, id: Int) : TrackService(id) { - @StringRes - override fun nameRes() = R.string.bangumi + override fun nameRes() = MR.strings.bangumi private val json: Json by injectLazy() @@ -93,22 +93,22 @@ class Bangumi(private val context: Context, id: Int) : TrackService(id) { override fun getStatus(status: Int): String = with(context) { when (status) { - READING -> getString(R.string.reading) - PLAN_TO_READ -> getString(R.string.plan_to_read) - COMPLETED -> getString(R.string.completed) - ON_HOLD -> getString(R.string.on_hold) - DROPPED -> getString(R.string.dropped) + READING -> getString(MR.strings.reading) + PLAN_TO_READ -> getString(MR.strings.plan_to_read) + COMPLETED -> getString(MR.strings.completed) + ON_HOLD -> getString(MR.strings.on_hold) + DROPPED -> getString(MR.strings.dropped) else -> "" } } override fun getGlobalStatus(status: Int): String = with(context) { when (status) { - READING -> getString(R.string.reading) - PLAN_TO_READ -> getString(R.string.plan_to_read) - COMPLETED -> getString(R.string.completed) - ON_HOLD -> getString(R.string.on_hold) - DROPPED -> getString(R.string.dropped) + READING -> getString(MR.strings.reading) + PLAN_TO_READ -> getString(MR.strings.plan_to_read) + COMPLETED -> getString(MR.strings.completed) + ON_HOLD -> getString(MR.strings.on_hold) + DROPPED -> getString(MR.strings.dropped) else -> "" } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/data/track/kavita/Kavita.kt b/app/src/main/java/eu/kanade/tachiyomi/data/track/kavita/Kavita.kt index d5be00f3ac..613cd90600 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/data/track/kavita/Kavita.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/data/track/kavita/Kavita.kt @@ -4,6 +4,9 @@ import android.content.Context import android.graphics.Color import androidx.annotation.StringRes import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.database.models.Manga import eu.kanade.tachiyomi.data.database.models.Track import eu.kanade.tachiyomi.data.track.EnhancedTrackService @@ -32,8 +35,7 @@ class Kavita(private val context: Context, id: Int) : TrackService(id), Enhanced private val sourceManager: SourceManager by injectLazy() - @StringRes - override fun nameRes() = R.string.kavita + override fun nameRes() = MR.strings.kavita override fun getLogo(): Int = R.drawable.ic_tracker_kavita @@ -47,18 +49,18 @@ class Kavita(private val context: Context, id: Int) : TrackService(id), Enhanced override fun getStatus(status: Int): String = with(context) { when (status) { - UNREAD -> getString(R.string.unread) - READING -> getString(R.string.reading) - COMPLETED -> getString(R.string.completed) + UNREAD -> getString(MR.strings.unread) + READING -> getString(MR.strings.reading) + COMPLETED -> getString(MR.strings.completed) else -> "" } } override fun getGlobalStatus(status: Int): String = with(context) { when (status) { - UNREAD -> getString(R.string.plan_to_read) - READING -> getString(R.string.reading) - COMPLETED -> getString(R.string.completed) + UNREAD -> getString(MR.strings.plan_to_read) + READING -> getString(MR.strings.reading) + COMPLETED -> getString(MR.strings.completed) else -> "" } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/data/track/kitsu/Kitsu.kt b/app/src/main/java/eu/kanade/tachiyomi/data/track/kitsu/Kitsu.kt index 6480f801f9..053f5c7922 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/data/track/kitsu/Kitsu.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/data/track/kitsu/Kitsu.kt @@ -5,6 +5,9 @@ import android.graphics.Color import androidx.annotation.StringRes import co.touchlab.kermit.Logger import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.database.models.Track import eu.kanade.tachiyomi.data.track.TrackService import eu.kanade.tachiyomi.data.track.model.TrackSearch @@ -28,8 +31,7 @@ class Kitsu(private val context: Context, id: Int) : TrackService(id) { const val DEFAULT_SCORE = 0f } - @StringRes - override fun nameRes() = R.string.kitsu + override fun nameRes() = MR.strings.kitsu override val supportsReadingDates: Boolean = true @@ -57,22 +59,22 @@ class Kitsu(private val context: Context, id: Int) : TrackService(id) { override fun getStatus(status: Int): String = with(context) { when (status) { - READING -> getString(R.string.currently_reading) - PLAN_TO_READ -> getString(R.string.want_to_read) - COMPLETED -> getString(R.string.completed) - ON_HOLD -> getString(R.string.on_hold) - DROPPED -> getString(R.string.dropped) + READING -> getString(MR.strings.currently_reading) + PLAN_TO_READ -> getString(MR.strings.want_to_read) + COMPLETED -> getString(MR.strings.completed) + ON_HOLD -> getString(MR.strings.on_hold) + DROPPED -> getString(MR.strings.dropped) else -> "" } } override fun getGlobalStatus(status: Int): String = with(context) { when (status) { - READING -> getString(R.string.reading) - PLAN_TO_READ -> getString(R.string.plan_to_read) - COMPLETED -> getString(R.string.completed) - ON_HOLD -> getString(R.string.on_hold) - DROPPED -> getString(R.string.dropped) + READING -> getString(MR.strings.reading) + PLAN_TO_READ -> getString(MR.strings.plan_to_read) + COMPLETED -> getString(MR.strings.completed) + ON_HOLD -> getString(MR.strings.on_hold) + DROPPED -> getString(MR.strings.dropped) else -> "" } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/data/track/komga/Komga.kt b/app/src/main/java/eu/kanade/tachiyomi/data/track/komga/Komga.kt index c5080ecd85..866839ad80 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/data/track/komga/Komga.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/data/track/komga/Komga.kt @@ -4,6 +4,9 @@ import android.content.Context import android.graphics.Color import androidx.annotation.StringRes import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.database.models.Manga import eu.kanade.tachiyomi.data.database.models.Track import eu.kanade.tachiyomi.data.track.EnhancedTrackService @@ -28,8 +31,7 @@ class Komga(private val context: Context, id: Int) : TrackService(id), EnhancedT val api by lazy { KomgaApi(client) } - @StringRes - override fun nameRes() = R.string.komga + override fun nameRes() = MR.strings.komga override fun getLogo() = R.drawable.ic_tracker_komga @@ -43,18 +45,18 @@ class Komga(private val context: Context, id: Int) : TrackService(id), EnhancedT override fun getStatus(status: Int): String = with(context) { when (status) { - UNREAD -> getString(R.string.unread) - READING -> getString(R.string.currently_reading) - COMPLETED -> getString(R.string.completed) + UNREAD -> getString(MR.strings.unread) + READING -> getString(MR.strings.currently_reading) + COMPLETED -> getString(MR.strings.completed) else -> "" } } override fun getGlobalStatus(status: Int): String = with(context) { when (status) { - UNREAD -> getString(R.string.plan_to_read) - READING -> getString(R.string.reading) - COMPLETED -> getString(R.string.completed) + UNREAD -> getString(MR.strings.plan_to_read) + READING -> getString(MR.strings.reading) + COMPLETED -> getString(MR.strings.completed) else -> "" } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/data/track/mangaupdates/MangaUpdates.kt b/app/src/main/java/eu/kanade/tachiyomi/data/track/mangaupdates/MangaUpdates.kt index af9a935783..bfaca93127 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/data/track/mangaupdates/MangaUpdates.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/data/track/mangaupdates/MangaUpdates.kt @@ -4,6 +4,9 @@ import android.content.Context import android.graphics.Color import androidx.annotation.StringRes import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.database.models.Track import eu.kanade.tachiyomi.data.track.TrackService import eu.kanade.tachiyomi.data.track.mangaupdates.dto.ListItem @@ -31,10 +34,9 @@ class MangaUpdates(private val context: Context, id: Int) : TrackService(id) { private val api by lazy { MangaUpdatesApi(interceptor, client) } - @StringRes - override fun nameRes(): Int = R.string.manga_updates + override fun nameRes() = MR.strings.manga_updates - override fun getLogo(): Int = R.drawable.ic_tracker_manga_updates + override fun getLogo() = R.drawable.ic_tracker_manga_updates override fun getTrackerColor() = Color.rgb(251, 148, 46) @@ -52,22 +54,22 @@ class MangaUpdates(private val context: Context, id: Int) : TrackService(id) { override fun getStatus(status: Int): String = with(context) { when (status) { - READING_LIST -> getString(R.string.reading_list) - WISH_LIST -> getString(R.string.wish_list) - COMPLETE_LIST -> getString(R.string.complete_list) - ON_HOLD_LIST -> getString(R.string.on_hold_list) - UNFINISHED_LIST -> getString(R.string.unfinished_list) + READING_LIST -> getString(MR.strings.reading_list) + WISH_LIST -> getString(MR.strings.wish_list) + COMPLETE_LIST -> getString(MR.strings.complete_list) + ON_HOLD_LIST -> getString(MR.strings.on_hold_list) + UNFINISHED_LIST -> getString(MR.strings.unfinished_list) else -> "" } } override fun getGlobalStatus(status: Int) = with(context) { when (status) { - READING_LIST -> getString(R.string.reading) - COMPLETE_LIST -> getString(R.string.completed) - ON_HOLD_LIST -> getString(R.string.on_hold) - UNFINISHED_LIST -> getString(R.string.dropped) - WISH_LIST -> getString(R.string.plan_to_read) + READING_LIST -> getString(MR.strings.reading) + COMPLETE_LIST -> getString(MR.strings.completed) + ON_HOLD_LIST -> getString(MR.strings.on_hold) + UNFINISHED_LIST -> getString(MR.strings.dropped) + WISH_LIST -> getString(MR.strings.plan_to_read) else -> "" } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/data/track/myanimelist/MyAnimeList.kt b/app/src/main/java/eu/kanade/tachiyomi/data/track/myanimelist/MyAnimeList.kt index 66ab46aa1a..253cb592e4 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/data/track/myanimelist/MyAnimeList.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/data/track/myanimelist/MyAnimeList.kt @@ -5,6 +5,9 @@ import android.graphics.Color import androidx.annotation.StringRes import co.touchlab.kermit.Logger import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.database.models.Track import eu.kanade.tachiyomi.data.track.TrackService import eu.kanade.tachiyomi.data.track.model.TrackSearch @@ -20,8 +23,7 @@ class MyAnimeList(private val context: Context, id: Int) : TrackService(id) { private val interceptor by lazy { MyAnimeListInterceptor(this) } private val api by lazy { MyAnimeListApi(client, interceptor) } - @StringRes - override fun nameRes() = R.string.myanimelist + override fun nameRes() = MR.strings.myanimelist override val supportsReadingDates: Boolean = true @@ -33,22 +35,22 @@ class MyAnimeList(private val context: Context, id: Int) : TrackService(id) { override fun getStatus(status: Int): String = with(context) { when (status) { - READING -> getString(R.string.reading) - COMPLETED -> getString(R.string.completed) - ON_HOLD -> getString(R.string.on_hold) - DROPPED -> getString(R.string.dropped) - PLAN_TO_READ -> getString(R.string.plan_to_read) + READING -> getString(MR.strings.reading) + COMPLETED -> getString(MR.strings.completed) + ON_HOLD -> getString(MR.strings.on_hold) + DROPPED -> getString(MR.strings.dropped) + PLAN_TO_READ -> getString(MR.strings.plan_to_read) else -> "" } } override fun getGlobalStatus(status: Int): String = with(context) { when (status) { - READING -> getString(R.string.reading) - PLAN_TO_READ -> getString(R.string.plan_to_read) - COMPLETED -> getString(R.string.completed) - ON_HOLD -> getString(R.string.on_hold) - DROPPED -> getString(R.string.dropped) + READING -> getString(MR.strings.reading) + PLAN_TO_READ -> getString(MR.strings.plan_to_read) + COMPLETED -> getString(MR.strings.completed) + ON_HOLD -> getString(MR.strings.on_hold) + DROPPED -> getString(MR.strings.dropped) else -> "" } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/data/track/shikimori/Shikimori.kt b/app/src/main/java/eu/kanade/tachiyomi/data/track/shikimori/Shikimori.kt index dfb92d937c..b519cdb537 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/data/track/shikimori/Shikimori.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/data/track/shikimori/Shikimori.kt @@ -5,6 +5,9 @@ import android.graphics.Color import androidx.annotation.StringRes import co.touchlab.kermit.Logger import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.database.models.Track import eu.kanade.tachiyomi.data.track.TrackService import eu.kanade.tachiyomi.data.track.updateNewTrackInfo @@ -27,8 +30,7 @@ class Shikimori(private val context: Context, id: Int) : TrackService(id) { const val DEFAULT_SCORE = 0 } - @StringRes - override fun nameRes() = R.string.shikimori + override fun nameRes() = MR.strings.shikimori private val json: Json by injectLazy() @@ -54,12 +56,12 @@ class Shikimori(private val context: Context, id: Int) : TrackService(id) { override fun getStatus(status: Int): String = with(context) { when (status) { - READING -> getString(R.string.reading) - COMPLETED -> getString(R.string.completed) - ON_HOLD -> getString(R.string.on_hold) - DROPPED -> getString(R.string.dropped) - PLAN_TO_READ -> getString(R.string.plan_to_read) - REREADING -> getString(R.string.rereading) + READING -> getString(MR.strings.reading) + COMPLETED -> getString(MR.strings.completed) + ON_HOLD -> getString(MR.strings.on_hold) + DROPPED -> getString(MR.strings.dropped) + PLAN_TO_READ -> getString(MR.strings.plan_to_read) + REREADING -> getString(MR.strings.rereading) else -> "" } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/data/track/suwayomi/Suwayomi.kt b/app/src/main/java/eu/kanade/tachiyomi/data/track/suwayomi/Suwayomi.kt index 43009fd994..a7b968a69d 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/data/track/suwayomi/Suwayomi.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/data/track/suwayomi/Suwayomi.kt @@ -4,6 +4,9 @@ import android.content.Context import android.graphics.Color import androidx.annotation.StringRes import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.database.models.Manga import eu.kanade.tachiyomi.data.database.models.Track import eu.kanade.tachiyomi.data.track.EnhancedTrackService @@ -14,8 +17,7 @@ import eu.kanade.tachiyomi.data.track.updateNewTrackInfo class Suwayomi(private val context: Context, id: Int) : TrackService(id), EnhancedTrackService { val api by lazy { TachideskApi() } - @StringRes - override fun nameRes() = R.string.suwayomi + override fun nameRes() = MR.strings.suwayomi override fun getLogo() = R.drawable.ic_tracker_suwayomi @@ -35,18 +37,18 @@ class Suwayomi(private val context: Context, id: Int) : TrackService(id), Enhanc override fun getStatus(status: Int): String = with(context) { when (status) { - UNREAD -> getString(R.string.unread) - READING -> getString(R.string.reading) - COMPLETED -> getString(R.string.completed) + UNREAD -> getString(MR.strings.unread) + READING -> getString(MR.strings.reading) + COMPLETED -> getString(MR.strings.completed) else -> "" } } override fun getGlobalStatus(status: Int): String = with(context) { when (status) { - UNREAD -> getString(R.string.plan_to_read) - READING -> getString(R.string.reading) - COMPLETED -> getString(R.string.completed) + UNREAD -> getString(MR.strings.plan_to_read) + READING -> getString(MR.strings.reading) + COMPLETED -> getString(MR.strings.completed) else -> "" } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/data/updater/AppUpdateBroadcast.kt b/app/src/main/java/eu/kanade/tachiyomi/data/updater/AppUpdateBroadcast.kt index 13e0cfaefe..d38a258d31 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/data/updater/AppUpdateBroadcast.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/data/updater/AppUpdateBroadcast.kt @@ -7,10 +7,10 @@ import android.content.pm.PackageInstaller import androidx.core.content.edit import androidx.core.net.toUri import androidx.preference.PreferenceManager -import eu.kanade.tachiyomi.R import eu.kanade.tachiyomi.util.system.getParcelableCompat import eu.kanade.tachiyomi.util.system.localeContext import eu.kanade.tachiyomi.util.system.toast +import yokai.i18n.MR class AppUpdateBroadcast : BroadcastReceiver() { override fun onReceive(context: Context, intent: Intent) { @@ -37,7 +37,7 @@ class AppUpdateBroadcast : BroadcastReceiver() { } PackageInstaller.STATUS_FAILURE, PackageInstaller.STATUS_FAILURE_ABORTED, PackageInstaller.STATUS_FAILURE_BLOCKED, PackageInstaller.STATUS_FAILURE_CONFLICT, PackageInstaller.STATUS_FAILURE_INCOMPATIBLE, PackageInstaller.STATUS_FAILURE_INVALID, PackageInstaller.STATUS_FAILURE_STORAGE -> { if (status != PackageInstaller.STATUS_FAILURE_ABORTED) { - context.toast(R.string.could_not_install_update) + context.toast(MR.strings.could_not_install_update) val uri = intent.getStringExtra(AppDownloadInstallJob.EXTRA_FILE_URI) ?: return val appUpdateNotifier = AppUpdateNotifier(context.localeContext) appUpdateNotifier.cancelInstallNotification() diff --git a/app/src/main/java/eu/kanade/tachiyomi/data/updater/AppUpdateNotifier.kt b/app/src/main/java/eu/kanade/tachiyomi/data/updater/AppUpdateNotifier.kt index 3a004d09d9..ae27c97537 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/data/updater/AppUpdateNotifier.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/data/updater/AppUpdateNotifier.kt @@ -15,6 +15,8 @@ import eu.kanade.tachiyomi.data.notification.NotificationReceiver import eu.kanade.tachiyomi.data.notification.Notifications import eu.kanade.tachiyomi.util.system.getResourceColor import eu.kanade.tachiyomi.util.system.notificationManager +import yokai.i18n.MR +import yokai.util.lang.getString import android.R as AR /** @@ -30,7 +32,7 @@ internal class AppUpdateNotifier(private val context: Context) { val notificationBuilder by lazy { NotificationCompat.Builder(context, Notifications.CHANNEL_COMMON).apply { setSmallIcon(AR.drawable.stat_sys_download) - setContentTitle(context.getString(R.string.app_name)) + setContentTitle(context.getString(MR.strings.app_name)) } } @@ -56,13 +58,13 @@ internal class AppUpdateNotifier(private val context: Context) { val pendingIntent = NotificationReceiver.openUpdatePendingActivity(context, body, url) releasePageUrl = releaseUrl with(notificationBuilder) { - setContentTitle(context.getString(R.string.app_name)) + setContentTitle(context.getString(MR.strings.app_name)) setContentText( context.getString( if (isBeta) { - R.string.new_beta_version_available + MR.strings.new_beta_version_available } else { - R.string.new_version_available + MR.strings.new_version_available }, ), ) @@ -75,7 +77,7 @@ internal class AppUpdateNotifier(private val context: Context) { // Download action addAction( AR.drawable.stat_sys_download_done, - context.getString(if (isOnA12) R.string.update else R.string.download), + context.getString(if (isOnA12) MR.strings.update else MR.strings.download), NotificationReceiver.startAppUpdatePendingJob(context, url, true), ) addReleasePageAction() @@ -90,7 +92,7 @@ internal class AppUpdateNotifier(private val context: Context) { } addAction( R.drawable.ic_new_releases_24dp, - context.getString(R.string.release_page), + context.getString(MR.strings.release_page), PendingIntent.getActivity(context, releaseUrl.hashCode(), releaseIntent, PendingIntent.FLAG_UPDATE_CURRENT or PendingIntent.FLAG_IMMUTABLE), ) } @@ -103,8 +105,8 @@ internal class AppUpdateNotifier(private val context: Context) { */ fun onDownloadStarted(): NotificationCompat.Builder { with(notificationBuilder) { - setContentTitle(context.getString(R.string.app_name)) - setContentText(context.getString(R.string.downloading)) + setContentTitle(context.getString(MR.strings.app_name)) + setContentText(context.getString(MR.strings.downloading)) setSmallIcon(AR.drawable.stat_sys_download) setProgress(0, 0, true) setAutoCancel(false) @@ -112,7 +114,7 @@ internal class AppUpdateNotifier(private val context: Context) { clearActions() addAction( R.drawable.ic_close_24dp, - context.getString(R.string.cancel), + context.getString(MR.strings.cancel), NotificationReceiver.cancelUpdateDownloadPendingBroadcast(context), ) addReleasePageAction() @@ -128,15 +130,15 @@ internal class AppUpdateNotifier(private val context: Context) { */ fun onProgressChange(progress: Int) { with(notificationBuilder) { - setContentTitle(context.getString(R.string.app_name)) - setContentText(context.getString(R.string.downloading)) + setContentTitle(context.getString(MR.strings.app_name)) + setContentText(context.getString(MR.strings.downloading)) setSmallIcon(AR.drawable.stat_sys_download) setProgress(100, progress, false) setOnlyAlertOnce(true) clearActions() addAction( R.drawable.ic_close_24dp, - context.getString(R.string.cancel), + context.getString(MR.strings.cancel), NotificationReceiver.cancelUpdateDownloadPendingBroadcast(context), ) } @@ -145,7 +147,7 @@ internal class AppUpdateNotifier(private val context: Context) { fun onInstalling() { with(NotificationCompat.Builder(context, Notifications.CHANNEL_INSTALLING)) { - setContentTitle(context.getString(R.string.installing)) + setContentTitle(context.getString(MR.strings.installing)) setSmallIcon(AR.drawable.stat_sys_download) setProgress(0, 0, true) setOnlyAlertOnce(true) @@ -161,7 +163,7 @@ internal class AppUpdateNotifier(private val context: Context) { */ fun onDownloadFinished(uri: Uri) { with(notificationBuilder) { - setContentText(context.getString(R.string.download_complete)) + setContentText(context.getString(MR.strings.download_complete)) setSmallIcon(AR.drawable.stat_sys_download_done) setAutoCancel(false) setOnlyAlertOnce(false) @@ -171,13 +173,13 @@ internal class AppUpdateNotifier(private val context: Context) { clearActions() addAction( R.drawable.ic_system_update_24dp, - context.getString(R.string.install), + context.getString(MR.strings.install), NotificationHandler.installApkPendingActivity(context, uri), ) // Cancel action addAction( R.drawable.ic_close_24dp, - context.getString(R.string.cancel), + context.getString(MR.strings.cancel), NotificationReceiver.dismissNotificationPendingBroadcast(context, Notifications.ID_INSTALL), ) addReleasePageAction() @@ -188,8 +190,8 @@ internal class AppUpdateNotifier(private val context: Context) { /** Call when apk download is finished. */ fun onInstallFinished() { with(NotificationCompat.Builder(context, Notifications.CHANNEL_UPDATED)) { - setContentTitle(context.getString(R.string.update_completed)) - setContentText(context.getString(R.string.updated_to_, BuildConfig.VERSION_NAME)) + setContentTitle(context.getString(MR.strings.update_completed)) + setContentText(context.getString(MR.strings.updated_to_, BuildConfig.VERSION_NAME)) setSmallIcon(R.drawable.ic_yokai) setAutoCancel(true) setOngoing(false) @@ -204,7 +206,7 @@ internal class AppUpdateNotifier(private val context: Context) { clearActions() addAction( R.drawable.ic_system_update_24dp, - context.getString(R.string.open), + context.getString(MR.strings.open), pendingIntent, ) addReleasePageAction() @@ -219,7 +221,7 @@ internal class AppUpdateNotifier(private val context: Context) { */ fun onDownloadError(url: String) { with(notificationBuilder) { - setContentText(context.getString(R.string.download_error)) + setContentText(context.getString(MR.strings.download_error)) setSmallIcon(AR.drawable.stat_sys_warning) setOnlyAlertOnce(false) setAutoCancel(false) @@ -229,13 +231,13 @@ internal class AppUpdateNotifier(private val context: Context) { // Retry action addAction( R.drawable.ic_refresh_24dp, - context.getString(R.string.retry), + context.getString(MR.strings.retry), NotificationReceiver.startAppUpdatePendingJob(context, url), ) // Cancel action addAction( R.drawable.ic_close_24dp, - context.getString(R.string.cancel), + context.getString(MR.strings.cancel), NotificationReceiver.dismissNotificationPendingBroadcast(context, Notifications.ID_UPDATER), ) addReleasePageAction() @@ -245,8 +247,8 @@ internal class AppUpdateNotifier(private val context: Context) { fun onInstallError(uri: Uri) { with(notificationBuilder) { - setContentTitle(context.getString(R.string.app_name)) - setContentText(context.getString(R.string.could_not_install_update)) + setContentTitle(context.getString(MR.strings.app_name)) + setContentText(context.getString(MR.strings.could_not_install_update)) setSmallIcon(AR.drawable.stat_sys_warning) setOnlyAlertOnce(false) setAutoCancel(false) @@ -256,13 +258,13 @@ internal class AppUpdateNotifier(private val context: Context) { // Retry action addAction( R.drawable.ic_refresh_24dp, - context.getString(R.string.retry), + context.getString(MR.strings.retry), NotificationHandler.installApkPendingActivity(context, uri), ) // Cancel action addAction( R.drawable.ic_close_24dp, - context.getString(R.string.cancel), + context.getString(MR.strings.cancel), NotificationReceiver.dismissNotificationPendingBroadcast(context, Notifications.ID_UPDATER), ) addReleasePageAction() diff --git a/app/src/main/java/eu/kanade/tachiyomi/extension/ExtensionInstallNotifier.kt b/app/src/main/java/eu/kanade/tachiyomi/extension/ExtensionInstallNotifier.kt index d6fbc9bf68..13bf54e7c8 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/extension/ExtensionInstallNotifier.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/extension/ExtensionInstallNotifier.kt @@ -8,6 +8,8 @@ import eu.kanade.tachiyomi.data.notification.NotificationReceiver import eu.kanade.tachiyomi.data.notification.Notifications import eu.kanade.tachiyomi.util.system.notificationBuilder import eu.kanade.tachiyomi.util.system.notificationManager +import yokai.i18n.MR +import yokai.util.lang.getString import android.R as AR class ExtensionInstallNotifier(private val context: Context) { @@ -31,10 +33,10 @@ class ExtensionInstallNotifier(private val context: Context) { */ val progressNotificationBuilder by lazy { context.notificationBuilder(Notifications.CHANNEL_EXT_PROGRESS) { - setContentTitle(context.getString(R.string.app_name)) + setContentTitle(context.getString(MR.strings.app_name)) setSmallIcon(AR.drawable.stat_sys_download) setLargeIcon(notificationBitmap) - setContentTitle(context.getString(R.string.updating_extensions)) + setContentTitle(context.getString(MR.strings.updating_extensions)) setProgress(0, 0, true) setOngoing(true) setSilent(true) @@ -56,7 +58,7 @@ class ExtensionInstallNotifier(private val context: Context) { Notifications.ID_EXTENSION_PROGRESS, progressNotificationBuilder .setChannelId(Notifications.CHANNEL_EXT_PROGRESS) - .setContentTitle(context.getString(R.string.updating_extensions)) + .setContentTitle(context.getString(MR.strings.updating_extensions)) .setProgress(max, progress, progress == 0) .build(), ) @@ -68,8 +70,8 @@ class ExtensionInstallNotifier(private val context: Context) { progressNotificationBuilder .setChannelId(Notifications.CHANNEL_EXT_UPDATED) .setContentTitle( - context.resources.getQuantityString( - R.plurals.extensions_updated_plural, + context.getString( + MR.plurals.extensions_updated_plural, extensions.size, extensions.size, ), diff --git a/app/src/main/java/eu/kanade/tachiyomi/extension/ExtensionInstallerJob.kt b/app/src/main/java/eu/kanade/tachiyomi/extension/ExtensionInstallerJob.kt index ba02302aca..a1476ed537 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/extension/ExtensionInstallerJob.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/extension/ExtensionInstallerJob.kt @@ -14,7 +14,6 @@ import androidx.work.WorkManager import androidx.work.WorkerParameters import androidx.work.workDataOf import co.touchlab.kermit.Logger -import eu.kanade.tachiyomi.R import eu.kanade.tachiyomi.data.notification.Notifications import eu.kanade.tachiyomi.data.preference.PreferencesHelper import eu.kanade.tachiyomi.extension.model.Extension @@ -40,6 +39,7 @@ import kotlinx.serialization.encodeToString import kotlinx.serialization.json.Json import uy.kohesive.injekt.Injekt import uy.kohesive.injekt.api.get +import yokai.i18n.MR import java.lang.ref.WeakReference import kotlin.math.max @@ -78,7 +78,7 @@ class ExtensionInstallerJob(val context: Context, workerParams: WorkerParameters val reRunUpdateCheck = showUpdated > 0 if (!showUpdatedNotification && !preferences.hasPromptedBeforeUpdateAll().get()) { - context.toast(R.string.some_extensions_may_prompt) + context.toast(MR.strings.some_extensions_may_prompt) preferences.hasPromptedBeforeUpdateAll().set(true) } diff --git a/app/src/main/java/eu/kanade/tachiyomi/extension/ExtensionUpdateJob.kt b/app/src/main/java/eu/kanade/tachiyomi/extension/ExtensionUpdateJob.kt index 695020163e..35db6fe4de 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/extension/ExtensionUpdateJob.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/extension/ExtensionUpdateJob.kt @@ -39,6 +39,8 @@ import uy.kohesive.injekt.api.get import uy.kohesive.injekt.injectLazy import yokai.domain.base.BasePreferences import yokai.domain.base.BasePreferences.ExtensionInstaller +import yokai.i18n.MR +import yokai.util.lang.getString import java.util.concurrent.* class ExtensionUpdateJob(private val context: Context, workerParams: WorkerParameters) : @@ -121,8 +123,8 @@ class ExtensionUpdateJob(private val context: Context, workerParams: WorkerParam context.notification(Notifications.CHANNEL_UPDATES_TO_EXTS) { val context = context.localeContext setContentTitle( - context.resources.getQuantityString( - R.plurals.extension_updates_available, + context.getString( + MR.plurals.extension_updates_available, extensions.size, extensions.size, ), @@ -144,7 +146,7 @@ class ExtensionUpdateJob(private val context: Context, workerParams: WorkerParam NotificationReceiver.startExtensionUpdatePendingJob(context, extensions) addAction( R.drawable.ic_file_download_24dp, - context.getString(R.string.update_all), + context.getString(MR.strings.update_all), pendingIntent, ) } diff --git a/app/src/main/java/eu/kanade/tachiyomi/extension/ShizukuInstaller.kt b/app/src/main/java/eu/kanade/tachiyomi/extension/ShizukuInstaller.kt index 6c0b548c6c..e1abdca969 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/extension/ShizukuInstaller.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/extension/ShizukuInstaller.kt @@ -9,6 +9,9 @@ import android.os.Build import androidx.localbroadcastmanager.content.LocalBroadcastManager import co.touchlab.kermit.Logger import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.extension.util.ExtensionInstaller.Companion.EXTRA_DOWNLOAD_ID import eu.kanade.tachiyomi.util.system.getUriSize import eu.kanade.tachiyomi.util.system.isPackageInstalled @@ -69,7 +72,7 @@ class ShizukuInstaller(private val context: Context, val finishedQueue: (Shizuku Shizuku.addBinderDeadListener(shizukuDeadListener) require(Shizuku.pingBinder() && (context.isPackageInstalled(shizukuPkgName) || Sui.isSui())) { finishedQueue(this) - context.getString(R.string.ext_installer_shizuku_stopped) + context.getString(MR.strings.ext_installer_shizuku_stopped) } ready = if (Shizuku.checkSelfPermission() == PackageManager.PERMISSION_GRANTED) { true diff --git a/app/src/main/java/eu/kanade/tachiyomi/extension/model/InstalledExtensionsOrder.kt b/app/src/main/java/eu/kanade/tachiyomi/extension/model/InstalledExtensionsOrder.kt index 809110c3dd..2e9f10e4b8 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/extension/model/InstalledExtensionsOrder.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/extension/model/InstalledExtensionsOrder.kt @@ -1,14 +1,14 @@ package eu.kanade.tachiyomi.extension.model -import androidx.annotation.StringRes -import eu.kanade.tachiyomi.R +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.data.preference.PreferencesHelper +import yokai.i18n.MR -enum class InstalledExtensionsOrder(val value: Int, @StringRes val nameRes: Int) { - Name(0, R.string.name), - RecentlyUpdated(1, R.string.recently_updated), - RecentlyInstalled(2, R.string.recently_installed), - Language(3, R.string.language), +enum class InstalledExtensionsOrder(val value: Int, val nameRes: StringResource) { + Name(0, MR.strings.name), + RecentlyUpdated(1, MR.strings.recently_updated), + RecentlyInstalled(2, MR.strings.recently_installed), + Language(3, MR.strings.language), ; companion object { diff --git a/app/src/main/java/eu/kanade/tachiyomi/extension/util/ExtensionInstallBroadcast.kt b/app/src/main/java/eu/kanade/tachiyomi/extension/util/ExtensionInstallBroadcast.kt index 9d57c60ad6..ae2eb86f65 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/extension/util/ExtensionInstallBroadcast.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/extension/util/ExtensionInstallBroadcast.kt @@ -13,7 +13,6 @@ import android.os.Build import android.os.Bundle import android.widget.Toast import com.hippo.unifile.UniFile -import eu.kanade.tachiyomi.R import eu.kanade.tachiyomi.extension.ExtensionManager import eu.kanade.tachiyomi.extension.util.ExtensionInstallBroadcast.Companion.EXTRA_SESSION_ID import eu.kanade.tachiyomi.extension.util.ExtensionInstallBroadcast.Companion.PACKAGE_INSTALLED_ACTION @@ -22,6 +21,7 @@ import eu.kanade.tachiyomi.util.system.DeviceUtil import eu.kanade.tachiyomi.util.system.getParcelableCompat import eu.kanade.tachiyomi.util.system.toast import uy.kohesive.injekt.injectLazy +import yokai.i18n.MR /** * Broadcast used to install extensions, that receives callbacks from package installer. @@ -103,9 +103,9 @@ class ExtensionInstallBroadcast : BroadcastReceiver() { extensionManager.setInstallationResult(downloadId, false) if (status != PackageInstaller.STATUS_FAILURE_ABORTED) { if (DeviceUtil.isMiui) { - context.toast(R.string.extensions_miui_warning, Toast.LENGTH_LONG) + context.toast(MR.strings.extensions_miui_warning, Toast.LENGTH_LONG) } else { - context.toast(R.string.could_not_install_extension) + context.toast(MR.strings.could_not_install_extension) } } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/source/LocalSource.kt b/app/src/main/java/eu/kanade/tachiyomi/source/LocalSource.kt index d90d7b729d..5ac2eaf88e 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/source/LocalSource.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/source/LocalSource.kt @@ -6,6 +6,9 @@ import co.touchlab.kermit.Logger import com.github.junrar.Archive import com.hippo.unifile.UniFile import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.source.model.Filter import eu.kanade.tachiyomi.source.model.FilterList import eu.kanade.tachiyomi.source.model.MangasPage @@ -117,7 +120,7 @@ class LocalSource(private val context: Context) : CatalogueSource, UnmeteredSour private val xml: XML by injectLazy() override val id = ID - override val name = context.getString(R.string.local_source) + override val name = context.getString(MR.strings.local_source) override val lang = "other" override val supportsLatest = true @@ -329,7 +332,7 @@ class LocalSource(private val context: Context) : CatalogueSource, UnmeteredSour ?.findFile(mangaDirName) ?.findFile(chapterName) if (chapFile == null || !chapFile.exists()) - throw Exception(context.getString(R.string.chapter_not_found)) + throw Exception(context.getString(MR.strings.chapter_not_found)) return getFormat(chapFile) } @@ -340,7 +343,7 @@ class LocalSource(private val context: Context) : CatalogueSource, UnmeteredSour extension.equals("zip", true) || extension.equals("cbz", true) -> Format.Zip(this) extension.equals("rar", true) || extension.equals("cbr", true) -> Format.Rar(this) extension.equals("epub", true) -> Format.Epub(this) - else -> throw Exception(context.getString(R.string.local_invalid_format)) + else -> throw Exception(context.getString(MR.strings.local_invalid_format)) } } @@ -432,8 +435,8 @@ class LocalSource(private val context: Context) : CatalogueSource, UnmeteredSour private val latestFilters = FilterList(OrderBy(context).apply { state = Filter.Sort.Selection(1, false) }) private class OrderBy(context: Context) : Filter.Sort( - context.getString(R.string.order_by), - arrayOf(context.getString(R.string.title), context.getString(R.string.date)), + context.getString(MR.strings.order_by), + arrayOf(context.getString(MR.strings.title), context.getString(MR.strings.date)), Selection(0, true), ) diff --git a/app/src/main/java/eu/kanade/tachiyomi/source/SourceManager.kt b/app/src/main/java/eu/kanade/tachiyomi/source/SourceManager.kt index e4f7464e5f..407aa4a491 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/source/SourceManager.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/source/SourceManager.kt @@ -2,6 +2,9 @@ package eu.kanade.tachiyomi.source import android.content.Context import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.extension.ExtensionManager import eu.kanade.tachiyomi.source.model.Page import eu.kanade.tachiyomi.source.model.SChapter @@ -131,7 +134,7 @@ class SourceManager( private fun getSourceNotInstalledException(): Exception { return SourceNotFoundException( context.getString( - R.string.source_not_installed_, + MR.strings.source_not_installed_, extensionManager.getStubSource(id)?.name ?: id.toString(), ), id, diff --git a/app/src/main/java/eu/kanade/tachiyomi/source/online/all/Cubari.kt b/app/src/main/java/eu/kanade/tachiyomi/source/online/all/Cubari.kt index fa460c9e87..8944b9b3f8 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/source/online/all/Cubari.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/source/online/all/Cubari.kt @@ -1,7 +1,6 @@ package eu.kanade.tachiyomi.source.online.all import android.net.Uri -import eu.kanade.tachiyomi.R import eu.kanade.tachiyomi.data.database.models.Chapter import eu.kanade.tachiyomi.data.database.models.Manga import eu.kanade.tachiyomi.data.database.models.toChapter @@ -14,6 +13,8 @@ import kotlinx.coroutines.async import kotlinx.coroutines.withContext import uy.kohesive.injekt.Injekt import uy.kohesive.injekt.api.get +import yokai.i18n.MR +import yokai.util.lang.getString import java.util.* class Cubari : DelegatedHttpSource() { @@ -48,7 +49,7 @@ class Cubari : DelegatedHttpSource() { val context = Injekt.get().context val trueChapter = findChapter(chapters, cubariType, chapterNumber)?.toChapter() ?: error( - context.getString(R.string.chapter_not_found), + context.getString(MR.strings.chapter_not_found), ) if (manga != null) { Triple(trueChapter, manga, chapters.orEmpty()) diff --git a/app/src/main/java/eu/kanade/tachiyomi/source/online/all/MangaDex.kt b/app/src/main/java/eu/kanade/tachiyomi/source/online/all/MangaDex.kt index 0f80b5b601..8ba31be2da 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/source/online/all/MangaDex.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/source/online/all/MangaDex.kt @@ -2,6 +2,9 @@ package eu.kanade.tachiyomi.source.online.all import android.net.Uri import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.database.models.Chapter import eu.kanade.tachiyomi.data.database.models.Manga import eu.kanade.tachiyomi.data.database.models.toChapter @@ -70,7 +73,7 @@ class MangaDex : DelegatedHttpSource() { val chapters = deferredChapters.await() val context = Injekt.get().context val trueChapter = chapters?.find { it.url == "/api$url" }?.toChapter() ?: error( - context.getString(R.string.chapter_not_found), + context.getString(MR.strings.chapter_not_found), ) if (manga != null) { Triple(trueChapter, manga, chapters.orEmpty()) diff --git a/app/src/main/java/eu/kanade/tachiyomi/source/online/english/FoolSlide.kt b/app/src/main/java/eu/kanade/tachiyomi/source/online/english/FoolSlide.kt index 0f006897af..d26e48a9f1 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/source/online/english/FoolSlide.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/source/online/english/FoolSlide.kt @@ -1,7 +1,6 @@ package eu.kanade.tachiyomi.source.online.english import android.net.Uri -import eu.kanade.tachiyomi.R import eu.kanade.tachiyomi.data.database.models.Chapter import eu.kanade.tachiyomi.data.database.models.Manga import eu.kanade.tachiyomi.data.database.models.MangaImpl @@ -20,6 +19,8 @@ import okhttp3.FormBody import okhttp3.Request import uy.kohesive.injekt.Injekt import uy.kohesive.injekt.api.get +import yokai.i18n.MR +import yokai.util.lang.getString open class FoolSlide(override val domainName: String, private val urlModifier: String = "") : DelegatedHttpSource @@ -72,7 +73,7 @@ open class FoolSlide(override val domainName: String, private val urlModifier: S val chapters = deferredChapters.await() val context = Injekt.get().context val trueChapter = chapters?.find { it.url == chapterUrl }?.toChapter() ?: error( - context.getString(R.string.chapter_not_found), + context.getString(MR.strings.chapter_not_found), ) if (manga != null) Triple(trueChapter, manga, chapters) else null } diff --git a/app/src/main/java/eu/kanade/tachiyomi/source/online/english/MangaPlus.kt b/app/src/main/java/eu/kanade/tachiyomi/source/online/english/MangaPlus.kt index 7a03655487..cffdb9355e 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/source/online/english/MangaPlus.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/source/online/english/MangaPlus.kt @@ -2,6 +2,9 @@ package eu.kanade.tachiyomi.source.online.english import android.net.Uri import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.database.models.Chapter import eu.kanade.tachiyomi.data.database.models.Manga import eu.kanade.tachiyomi.data.database.models.toChapter @@ -59,7 +62,7 @@ class MangaPlus : DelegatedHttpSource() { val chapters = deferredChapters.await() val context = Injekt.get().context val trueChapter = chapters?.find { it.url == url }?.toChapter() ?: error( - context.getString(R.string.chapter_not_found), + context.getString(MR.strings.chapter_not_found), ) if (manga != null) { Triple( diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/base/MaterialFastScroll.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/base/MaterialFastScroll.kt index ca461de744..6b29176f67 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/base/MaterialFastScroll.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/base/MaterialFastScroll.kt @@ -9,6 +9,9 @@ import androidx.recyclerview.widget.RecyclerView import androidx.recyclerview.widget.StaggeredGridLayoutManager import eu.davidea.fastscroller.FastScroller import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.ui.base.controller.BaseLegacyController import eu.kanade.tachiyomi.util.system.dpToPx import eu.kanade.tachiyomi.util.system.dpToPxEnd diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/base/MaterialMenuSheet.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/base/MaterialMenuSheet.kt index 1699ab5509..eda5c26e65 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/base/MaterialMenuSheet.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/base/MaterialMenuSheet.kt @@ -14,7 +14,11 @@ import androidx.recyclerview.widget.LinearLayoutManager import androidx.recyclerview.widget.RecyclerView import com.mikepenz.fastadapter.FastAdapter import com.mikepenz.fastadapter.adapters.ItemAdapter +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.databinding.BottomMenuSheetBinding import eu.kanade.tachiyomi.util.system.dpToPx import eu.kanade.tachiyomi.util.system.getResourceColor @@ -149,7 +153,7 @@ class MaterialMenuSheet( data class MenuSheetItem( val id: Int, @DrawableRes val drawable: Int = 0, - @StringRes val textRes: Int = 0, + val textRes: StringResource = StringResource(0), val text: String? = null, var endDrawableRes: Int = 0, ) diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/base/MaterialMenuSheetItem.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/base/MaterialMenuSheetItem.kt index 72ad289e14..693592d99c 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/base/MaterialMenuSheetItem.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/base/MaterialMenuSheetItem.kt @@ -4,6 +4,9 @@ import android.view.View import com.mikepenz.fastadapter.FastAdapter import com.mikepenz.fastadapter.items.AbstractItem import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.databinding.MenuSheetItemBinding class MaterialMenuSheetItem(val sheetItem: MaterialMenuSheet.MenuSheetItem) : AbstractItem() { diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/base/MiniSearchView.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/base/MiniSearchView.kt index 25f6be4e41..0a2539ccb5 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/base/MiniSearchView.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/base/MiniSearchView.kt @@ -12,6 +12,9 @@ import android.widget.LinearLayout import androidx.appcompat.widget.SearchView import androidx.core.graphics.ColorUtils import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.util.system.getResourceColor import eu.kanade.tachiyomi.widget.TachiyomiTextInputEditText.Companion.setIncognito import kotlinx.coroutines.CoroutineScope diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/category/CategoryController.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/category/CategoryController.kt index 8b3cc48fd8..1e72e0243f 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/category/CategoryController.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/category/CategoryController.kt @@ -8,7 +8,6 @@ import androidx.recyclerview.widget.RecyclerView import com.google.android.material.snackbar.BaseTransientBottomBar import com.google.android.material.snackbar.Snackbar import eu.davidea.flexibleadapter.FlexibleAdapter -import eu.kanade.tachiyomi.R import eu.kanade.tachiyomi.databinding.CategoriesControllerBinding import eu.kanade.tachiyomi.ui.base.SmallToolbarInterface import eu.kanade.tachiyomi.ui.base.controller.BaseLegacyController @@ -17,7 +16,13 @@ import eu.kanade.tachiyomi.ui.main.MainActivity import eu.kanade.tachiyomi.util.system.materialAlertDialog import eu.kanade.tachiyomi.util.system.toast import eu.kanade.tachiyomi.util.view.liftAppbarWith +import eu.kanade.tachiyomi.util.view.setAction +import eu.kanade.tachiyomi.util.view.setMessage +import eu.kanade.tachiyomi.util.view.setPositiveButton +import eu.kanade.tachiyomi.util.view.setTitle import eu.kanade.tachiyomi.util.view.snack +import yokai.i18n.MR +import yokai.util.lang.getString import android.R as AR /** @@ -49,7 +54,7 @@ class CategoryController(bundle: Bundle? = null) : * Returns the toolbar title to show when this controller is attached. */ override fun getTitle(): String? { - return resources?.getString(R.string.edit_categories) + return view?.context?.getString(MR.strings.edit_categories) } override fun createBinding(inflater: LayoutInflater) = CategoriesControllerBinding.inflate(inflater) @@ -117,7 +122,7 @@ class CategoryController(bundle: Bundle? = null) : override fun onCategoryRename(position: Int, newName: String): Boolean { val category = adapter?.getItem(position)?.category ?: return false if (newName.isBlank()) { - activity?.toast(R.string.category_cannot_be_blank) + activity?.toast(MR.strings.category_cannot_be_blank) return false } if (category.order == CREATE_CATEGORY_ORDER) { @@ -128,9 +133,9 @@ class CategoryController(bundle: Bundle? = null) : override fun onItemDelete(position: Int) { activity!!.materialAlertDialog() - .setTitle(R.string.confirm_category_deletion) - .setMessage(R.string.confirm_category_deletion_message) - .setPositiveButton(R.string.delete) { _, _ -> + .setTitle(MR.strings.confirm_category_deletion) + .setMessage(MR.strings.confirm_category_deletion_message) + .setPositiveButton(MR.strings.delete) { _, _ -> deleteCategory(position) } .setNegativeButton(AR.string.cancel, null) @@ -141,9 +146,9 @@ class CategoryController(bundle: Bundle? = null) : confirmDelete() adapter?.removeItem(position) snack = - view?.snack(R.string.category_deleted, Snackbar.LENGTH_INDEFINITE) { + view?.snack(MR.strings.category_deleted, Snackbar.LENGTH_INDEFINITE) { var undoing = false - setAction(R.string.undo) { + setAction(MR.strings.undo) { adapter?.restoreDeletedItems() undoing = true } @@ -189,6 +194,6 @@ class CategoryController(bundle: Bundle? = null) : * Called from the presenter when a category with the given name already exists. */ fun onCategoryExistsError() { - activity?.toast(R.string.category_with_name_exists) + activity?.toast(MR.strings.category_with_name_exists) } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/category/CategoryHolder.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/category/CategoryHolder.kt index 23c21ecadc..830d3e9fe2 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/category/CategoryHolder.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/category/CategoryHolder.kt @@ -16,7 +16,7 @@ import eu.kanade.tachiyomi.databinding.CategoriesItemBinding import eu.kanade.tachiyomi.ui.base.holder.BaseFlexibleViewHolder import eu.kanade.tachiyomi.ui.category.CategoryPresenter.Companion.CREATE_CATEGORY_ORDER import eu.kanade.tachiyomi.util.system.getResourceColor -import java.util.Locale +import java.util.* /** * Holder used to display category items. diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/category/CategoryPresenter.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/category/CategoryPresenter.kt index f4e881a62d..14a69ae274 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/category/CategoryPresenter.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/category/CategoryPresenter.kt @@ -1,6 +1,5 @@ package eu.kanade.tachiyomi.ui.category -import eu.kanade.tachiyomi.R import eu.kanade.tachiyomi.data.database.DatabaseHelper import eu.kanade.tachiyomi.data.database.models.Category import eu.kanade.tachiyomi.ui.library.LibrarySort @@ -12,6 +11,8 @@ import kotlinx.coroutines.launch import kotlinx.coroutines.withContext import uy.kohesive.injekt.Injekt import uy.kohesive.injekt.api.get +import yokai.i18n.MR +import yokai.util.lang.getString /** * Presenter of [CategoryController]. Used to manage the categories of the library. @@ -48,7 +49,7 @@ class CategoryPresenter( private fun newCategory(): Category { val default = - Category.create(controller.view?.context?.getString(R.string.create_new_category) ?: "") + Category.create(controller.view?.context?.getString(MR.strings.create_new_category) ?: "") default.order = CREATE_CATEGORY_ORDER default.id = Int.MIN_VALUE return default diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/category/ManageCategoryDialog.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/category/ManageCategoryDialog.kt index 344bbbd57d..1fae7457a3 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/category/ManageCategoryDialog.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/category/ManageCategoryDialog.kt @@ -8,6 +8,9 @@ import androidx.core.view.isVisible import androidx.core.widget.addTextChangedListener import com.google.android.material.dialog.MaterialAlertDialogBuilder import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.core.preference.Preference import eu.kanade.tachiyomi.data.database.DatabaseHelper import eu.kanade.tachiyomi.data.database.models.Category @@ -17,6 +20,8 @@ import eu.kanade.tachiyomi.databinding.MangaCategoryDialogBinding import eu.kanade.tachiyomi.ui.base.controller.DialogController import eu.kanade.tachiyomi.ui.library.LibrarySort import eu.kanade.tachiyomi.util.system.materialAlertDialog +import eu.kanade.tachiyomi.util.view.setPositiveButton +import eu.kanade.tachiyomi.util.view.setTitle import eu.kanade.tachiyomi.util.view.withFadeTransaction import eu.kanade.tachiyomi.widget.TriStateCheckBox import uy.kohesive.injekt.injectLazy @@ -52,11 +57,11 @@ class ManageCategoryDialog(bundle: Bundle? = null) : fun dialog(activity: Activity): MaterialAlertDialogBuilder { return activity.materialAlertDialog().apply { - setTitle(if (category == null) R.string.new_category else R.string.manage_category) + setTitle(if (category == null) MR.strings.new_category else MR.strings.manage_category) binding = MangaCategoryDialogBinding.inflate(activity.layoutInflater) setView(binding.root) setNegativeButton(AR.string.cancel, null) - setPositiveButton(R.string.save) { dialog, _ -> + setPositiveButton(MR.strings.save) { dialog, _ -> if (onPositiveButtonClick()) { dialog.dismiss() } @@ -94,11 +99,11 @@ class ManageCategoryDialog(bundle: Bundle? = null) : } } else if (categoryExists) { binding.categoryTextLayout.error = - binding.categoryTextLayout.context.getString(R.string.category_with_name_exists) + binding.categoryTextLayout.context.getString(MR.strings.category_with_name_exists) return false } else if (text.isBlank()) { binding.categoryTextLayout.error = - binding.categoryTextLayout.context.getString(R.string.category_cannot_be_blank) + binding.categoryTextLayout.context.getString(MR.strings.category_cannot_be_blank) return false } } @@ -149,7 +154,7 @@ class ManageCategoryDialog(bundle: Bundle? = null) : binding.categoryTextLayout.error = null } binding.title.hint = - category?.name ?: binding.editCategories.context.getString(R.string.category) + category?.name ?: binding.editCategories.context.getString(MR.strings.category) binding.title.append(category?.name ?: "") val downloadNew = preferences.downloadNewChapters().get() setCheckbox( diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/category/addtolibrary/SetCategoriesSheet.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/category/addtolibrary/SetCategoriesSheet.kt index 4c11549d73..de40e58a3a 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/category/addtolibrary/SetCategoriesSheet.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/category/addtolibrary/SetCategoriesSheet.kt @@ -14,6 +14,9 @@ import com.google.android.material.bottomsheet.BottomSheetBehavior import com.mikepenz.fastadapter.FastAdapter import com.mikepenz.fastadapter.adapters.ItemAdapter import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.database.DatabaseHelper import eu.kanade.tachiyomi.data.database.models.Category import eu.kanade.tachiyomi.data.database.models.Manga @@ -96,11 +99,11 @@ class SetCategoriesSheet( init { binding.toolbarTitle.text = context.getString( - if (addingToLibrary) R.string.add_x_to else R.string.move_x_to, + if (addingToLibrary) MR.strings.add_x_to else MR.strings.move_x_to, if (listManga.size == 1) { listManga.first().seriesType(context) } else { - context.getString(R.string.selection).lowercase(Locale.ROOT) + context.getString(MR.strings.selection).lowercase(Locale.ROOT) }, ) @@ -186,16 +189,16 @@ class SetCategoriesSheet( } binding.addToCategoriesButton.text = context.getString( when { - addingToLibrary || (addingMore && !nothingChanged) -> R.string.add_to_ - removing -> R.string.remove_from_ - nothingChanged -> R.string.keep_in_ - else -> R.string.move_to_ + addingToLibrary || (addingMore && !nothingChanged) -> MR.strings.add_to_ + removing -> MR.strings.remove_from_ + nothingChanged -> MR.strings.keep_in_ + else -> MR.strings.move_to_ }, when (items.size) { - 0 -> context.getString(R.string.default_category).lowercase(Locale.ROOT) + 0 -> context.getString(MR.strings.default_category).lowercase(Locale.ROOT) 1 -> items.firstOrNull()?.name ?: "" - else -> context.resources.getQuantityString( - R.plurals.category_plural, + else -> context.getString( + MR.plurals.category_plural, items.size, items.size, ) diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/crash/CrashActivity.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/crash/CrashActivity.kt index 151c82120a..7616e6e855 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/crash/CrashActivity.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/crash/CrashActivity.kt @@ -16,14 +16,14 @@ import androidx.compose.runtime.rememberCoroutineScope import androidx.compose.ui.Modifier import androidx.compose.ui.draw.clip import androidx.compose.ui.platform.LocalContext -import androidx.compose.ui.res.stringResource -import eu.kanade.tachiyomi.R +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.preference.PreferencesHelper import eu.kanade.tachiyomi.ui.main.MainActivity import eu.kanade.tachiyomi.util.CrashLogUtil import eu.kanade.tachiyomi.util.system.setThemeByPref import kotlinx.coroutines.launch import uy.kohesive.injekt.injectLazy +import yokai.i18n.MR import yokai.presentation.onboarding.InfoScreen import yokai.presentation.theme.Size import yokai.presentation.theme.YokaiTheme @@ -43,16 +43,16 @@ class CrashActivity : AppCompatActivity() { YokaiTheme { InfoScreen( icon = Icons.Outlined.BugReport, - headingText = stringResource(R.string.crash_screen_title), - subtitleText = stringResource(R.string.crash_screen_description, stringResource(id = R.string.app_name)), - acceptText = stringResource(id = R.string.dump_crash_logs), + headingText = stringResource(MR.strings.crash_screen_title), + subtitleText = stringResource(MR.strings.crash_screen_description, stringResource(MR.strings.app_name)), + acceptText = stringResource(MR.strings.dump_crash_logs), onAcceptClick = { scope.launch { CrashLogUtil(context).dumpLogs() } }, canAccept = true, - rejectText = stringResource(R.string.crash_screen_restart_application), + rejectText = stringResource(MR.strings.crash_screen_restart_application), onRejectClick = { finishAffinity() startActivity(Intent(this@CrashActivity, MainActivity::class.java)) diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/download/DownloadBottomSheet.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/download/DownloadBottomSheet.kt index b8ad6267dc..b0e354cbb3 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/download/DownloadBottomSheet.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/download/DownloadBottomSheet.kt @@ -30,6 +30,8 @@ import eu.kanade.tachiyomi.util.view.isExpanded import eu.kanade.tachiyomi.util.view.isHidden import eu.kanade.tachiyomi.util.view.toolbarHeight import uy.kohesive.injekt.injectLazy +import yokai.i18n.MR +import yokai.util.lang.getString class DownloadBottomSheet @JvmOverloads constructor( context: Context, @@ -124,8 +126,8 @@ class DownloadBottomSheet @JvmOverloads constructor( private fun updateDLTitle() { val extCount = presenter.downloadQueue.firstOrNull() binding.titleText.text = if (extCount != null) { - resources.getString( - R.string.downloading_, + context.getString( + MR.strings.downloading_, extCount.chapter.preferredChapterName(context, extCount.manga, preferences), ) } else { @@ -211,7 +213,7 @@ class DownloadBottomSheet @JvmOverloads constructor( if (presenter.downloadQueue.isEmpty()) { binding.emptyView.show( R.drawable.ic_download_off_24dp, - R.string.nothing_is_downloading, + MR.strings.nothing_is_downloading, ) } else { binding.emptyView.hide() @@ -229,7 +231,7 @@ class DownloadBottomSheet @JvmOverloads constructor( } private fun updateFab() { - binding.downloadFab.text = context.getString(if (isRunning) R.string.pause else R.string.resume) + binding.downloadFab.text = context.getString(if (isRunning) MR.strings.pause else MR.strings.resume) binding.downloadFab.setIconResource(if (isRunning) R.drawable.ic_pause_24dp else R.drawable.ic_play_arrow_24dp) } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/download/DownloadHolder.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/download/DownloadHolder.kt index ddd4114a83..27c42fdb2b 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/download/DownloadHolder.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/download/DownloadHolder.kt @@ -2,7 +2,6 @@ package eu.kanade.tachiyomi.ui.download import android.view.View import androidx.appcompat.widget.PopupMenu -import androidx.core.view.isVisible import androidx.recyclerview.widget.ItemTouchHelper import eu.kanade.tachiyomi.R import eu.kanade.tachiyomi.data.download.model.Download diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/extension/ExtensionBottomPresenter.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/extension/ExtensionBottomPresenter.kt index 18a79d8fed..b55158122e 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/extension/ExtensionBottomPresenter.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/extension/ExtensionBottomPresenter.kt @@ -1,7 +1,6 @@ package eu.kanade.tachiyomi.ui.extension import android.content.pm.PackageInstaller -import eu.kanade.tachiyomi.R import eu.kanade.tachiyomi.data.download.DownloadManager import eu.kanade.tachiyomi.data.download.model.Download import eu.kanade.tachiyomi.data.download.model.DownloadQueue @@ -22,6 +21,8 @@ import kotlinx.coroutines.launch import kotlinx.coroutines.withContext import uy.kohesive.injekt.Injekt import uy.kohesive.injekt.api.get +import yokai.i18n.MR +import yokai.util.lang.getString typealias ExtensionTuple = Triple, List, List> @@ -158,8 +159,8 @@ class ExtensionBottomPresenter : BaseMigrationPresenter(), if (updatesSorted.isNotEmpty()) { val header = ExtensionGroupItem( - context.resources.getQuantityString( - R.plurals._updates_pending, + context.getString( + MR.plurals._updates_pending, updatesSorted.size, updatesSorted.size, ), @@ -171,7 +172,7 @@ class ExtensionBottomPresenter : BaseMigrationPresenter(), } } if (installedSorted.isNotEmpty() || untrustedSorted.isNotEmpty()) { - val header = ExtensionGroupItem(context.getString(R.string.installed), installedSorted.size + untrustedSorted.size, installedSorting = preferences.installedExtensionsOrder().get()) + val header = ExtensionGroupItem(context.getString(MR.strings.installed), installedSorted.size + untrustedSorted.size, installedSorting = preferences.installedExtensionsOrder().get()) items += installedSorted.map { extension -> ExtensionItem(extension, header, currentDownloads[extension.pkgName]) } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/extension/ExtensionBottomSheet.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/extension/ExtensionBottomSheet.kt index d284c38f84..cda08da10c 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/extension/ExtensionBottomSheet.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/extension/ExtensionBottomSheet.kt @@ -14,7 +14,6 @@ import com.google.android.material.bottomsheet.BottomSheetBehavior import com.google.android.material.tabs.TabLayout import eu.davidea.flexibleadapter.FlexibleAdapter import eu.davidea.flexibleadapter.items.IFlexible -import eu.kanade.tachiyomi.R import eu.kanade.tachiyomi.data.preference.PreferencesHelper import eu.kanade.tachiyomi.databinding.ExtensionsBottomSheetBinding import eu.kanade.tachiyomi.databinding.RecyclerWithScrollerBinding @@ -39,6 +38,11 @@ import eu.kanade.tachiyomi.util.view.doOnApplyWindowInsetsCompat import eu.kanade.tachiyomi.util.view.expand import eu.kanade.tachiyomi.util.view.isExpanded import eu.kanade.tachiyomi.util.view.popupMenu +import eu.kanade.tachiyomi.util.view.setMessage +import eu.kanade.tachiyomi.util.view.setNegativeButton +import eu.kanade.tachiyomi.util.view.setPositiveButton +import eu.kanade.tachiyomi.util.view.setText +import eu.kanade.tachiyomi.util.view.setTitle import eu.kanade.tachiyomi.util.view.smoothScrollToTop import eu.kanade.tachiyomi.util.view.withFadeTransaction import uy.kohesive.injekt.Injekt @@ -46,6 +50,8 @@ import uy.kohesive.injekt.api.get import uy.kohesive.injekt.injectLazy import yokai.domain.base.BasePreferences import yokai.domain.base.BasePreferences.ExtensionInstaller +import yokai.i18n.MR +import yokai.util.lang.getString import android.R as AR class ExtensionBottomSheet @JvmOverloads constructor(context: Context, attrs: AttributeSet? = null) : @@ -230,8 +236,8 @@ class ExtensionBottomSheet @JvmOverloads constructor(context: Context, attrs: At !presenter.preferences.hasPromptedBeforeUpdateAll().get() ) { controller.activity!!.materialAlertDialog() - .setTitle(R.string.update_all) - .setMessage(R.string.some_extensions_may_prompt) + .setTitle(MR.strings.update_all) + .setMessage(MR.strings.some_extensions_may_prompt) .setPositiveButton(AR.string.ok) { _, _ -> presenter.preferences.hasPromptedBeforeUpdateAll().set(true) updateAllExtensions(position) @@ -329,12 +335,12 @@ class ExtensionBottomSheet @JvmOverloads constructor(context: Context, attrs: At private fun openTrustDialog(extension: Extension.Untrusted) { val activity = controller.activity ?: return activity.materialAlertDialog() - .setTitle(R.string.untrusted_extension) - .setMessage(R.string.untrusted_extension_message) - .setPositiveButton(R.string.trust) { _, _ -> + .setTitle(MR.strings.untrusted_extension) + .setMessage(MR.strings.untrusted_extension_message) + .setPositiveButton(MR.strings.trust) { _, _ -> trustExtension(extension.pkgName, extension.versionCode, extension.signatureHash) } - .setNegativeButton(R.string.uninstall) { _, _ -> + .setNegativeButton(MR.strings.uninstall) { _, _ -> uninstallExtension(extension.pkgName) }.show() } @@ -433,7 +439,7 @@ class ExtensionBottomSheet @JvmOverloads constructor(context: Context, attrs: At } else { controller.activity!!.materialAlertDialog() .setTitle(extName) - .setPositiveButton(R.string.remove) { _, _ -> + .setPositiveButton(MR.strings.remove) { _, _ -> presenter.uninstallExtension(pkgName) } .setNegativeButton(AR.string.cancel, null) @@ -458,8 +464,8 @@ class ExtensionBottomSheet @JvmOverloads constructor(context: Context, attrs: At override fun getPageTitle(position: Int): CharSequence { return context.getString( when (position) { - 0 -> R.string.extensions - else -> R.string.migration + 0 -> MR.strings.extensions + else -> MR.strings.migration }, ) } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/extension/ExtensionFilterController.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/extension/ExtensionFilterController.kt index 40d532f6ed..0abcb0befd 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/extension/ExtensionFilterController.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/extension/ExtensionFilterController.kt @@ -2,22 +2,22 @@ package eu.kanade.tachiyomi.ui.extension import androidx.preference.PreferenceScreen import androidx.preference.SwitchPreferenceCompat -import eu.kanade.tachiyomi.R import eu.kanade.tachiyomi.core.preference.minusAssign import eu.kanade.tachiyomi.core.preference.plusAssign import eu.kanade.tachiyomi.extension.ExtensionManager import eu.kanade.tachiyomi.ui.setting.SettingsLegacyController import eu.kanade.tachiyomi.ui.setting.onChange -import eu.kanade.tachiyomi.ui.setting.titleRes +import eu.kanade.tachiyomi.ui.setting.titleMRes import eu.kanade.tachiyomi.util.system.LocaleHelper import uy.kohesive.injekt.injectLazy +import yokai.i18n.MR class ExtensionFilterController : SettingsLegacyController() { private val extensionManager: ExtensionManager by injectLazy() override fun setupPreferenceScreen(screen: PreferenceScreen) = screen.apply { - titleRes = R.string.extensions + titleMRes = MR.strings.extensions val activeLangs = preferences.enabledLanguages().get() diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/extension/ExtensionGroupHolder.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/extension/ExtensionGroupHolder.kt index cbda01dab2..334259459a 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/extension/ExtensionGroupHolder.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/extension/ExtensionGroupHolder.kt @@ -9,6 +9,7 @@ import eu.davidea.flexibleadapter.items.IFlexible import eu.kanade.tachiyomi.databinding.ExtensionCardHeaderBinding import eu.kanade.tachiyomi.extension.model.InstalledExtensionsOrder import eu.kanade.tachiyomi.ui.base.holder.BaseFlexibleViewHolder +import eu.kanade.tachiyomi.util.view.setText class ExtensionGroupHolder(view: View, adapter: FlexibleAdapter>) : BaseFlexibleViewHolder(view, adapter) { diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/extension/ExtensionHolder.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/extension/ExtensionHolder.kt index 193207ee9e..612be89f1d 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/extension/ExtensionHolder.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/extension/ExtensionHolder.kt @@ -24,6 +24,9 @@ import eu.kanade.tachiyomi.util.system.contextCompatDrawable import eu.kanade.tachiyomi.util.system.getResourceColor import eu.kanade.tachiyomi.util.system.timeSpanFromNow import eu.kanade.tachiyomi.util.view.resetStrokeColor +import eu.kanade.tachiyomi.util.view.setText +import yokai.i18n.MR +import yokai.util.lang.getString import java.util.* import android.R as AR @@ -54,7 +57,7 @@ class ExtensionHolder(view: View, val adapter: ExtensionAdapter) : ExtensionLoader.extensionUpdateDate(itemView.context, extension) .takeUnless { it == 0L }?.let { binding.date.isVisible = true - binding.date.text = itemView.context.timeSpanFromNow(R.string.updated_, it) + binding.date.text = itemView.context.timeSpanFromNow(MR.strings.updated_, it) infoText.add("") } } @@ -65,9 +68,9 @@ class ExtensionHolder(view: View, val adapter: ExtensionAdapter) : binding.date.text = itemView.context.timeSpanFromNow( if (extension.isShared) { - R.string.installed_ + MR.strings.installed_ } else { - R.string.added_ + MR.strings.added_ }, it, ) @@ -96,7 +99,7 @@ class ExtensionHolder(view: View, val adapter: ExtensionAdapter) : binding.version.text = infoText.joinToString(" • ") binding.lang.text = LocaleHelper.getDisplayName(extension.lang) binding.warning.text = when { - extension.isNsfw -> itemView.context.getString(R.string.nsfw_short) + extension.isNsfw -> itemView.context.getString(MR.strings.nsfw_short) else -> "" }.plusRepo(extension).uppercase(Locale.ROOT) binding.installProgress.progress = item.sessionProgress ?: 0 @@ -125,8 +128,8 @@ class ExtensionHolder(view: View, val adapter: ExtensionAdapter) : private fun String.plusRepo(extension: Extension): String { val repoText = when { - extension is Extension.Untrusted -> itemView.context.getString(R.string.untrusted) - extension is Extension.Installed && extension.isObsolete -> itemView.context.getString(R.string.obsolete) + extension is Extension.Untrusted -> itemView.context.getString(MR.strings.untrusted) + extension is Extension.Installed && extension.isObsolete -> itemView.context.getString(MR.strings.obsolete) else -> "" } @@ -157,12 +160,12 @@ class ExtensionHolder(view: View, val adapter: ExtensionAdapter) : if (installStep != null) { setText( when (installStep) { - InstallStep.Pending -> R.string.pending - InstallStep.Downloading -> R.string.downloading - InstallStep.Loading -> R.string.loading - InstallStep.Installing -> R.string.installing - InstallStep.Installed -> R.string.installed - InstallStep.Error -> R.string.retry + InstallStep.Pending -> MR.strings.pending + InstallStep.Downloading -> MR.strings.downloading + InstallStep.Loading -> MR.strings.loading + InstallStep.Installing -> MR.strings.installing + InstallStep.Installed -> MR.strings.installed + InstallStep.Error -> MR.strings.retry else -> return@with }, ) @@ -176,18 +179,18 @@ class ExtensionHolder(view: View, val adapter: ExtensionAdapter) : isActivated = true stateListAnimator = AnimatorInflater.loadStateListAnimator(context, R.animator.icon_btn_state_list_anim) rippleColor = ColorStateList.valueOf(context.getColor(R.color.on_secondary_highlight)) - setText(R.string.update) + setText(MR.strings.update) } else -> { - setText(R.string.settings) + setText(MR.strings.settings) } } } else if (extension is Extension.Untrusted) { resetStrokeColor() - setText(R.string.trust) + setText(MR.strings.trust) } else { resetStrokeColor() - setText(if (adapter.installPrivately) R.string.add else R.string.install) + setText(if (adapter.installPrivately) MR.strings.add else MR.strings.install) } } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/extension/details/ExtensionDetailsController.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/extension/details/ExtensionDetailsController.kt index fd246032ce..89c41cfdf3 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/extension/details/ExtensionDetailsController.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/extension/details/ExtensionDetailsController.kt @@ -43,6 +43,7 @@ import eu.kanade.tachiyomi.ui.setting.switchPreference import eu.kanade.tachiyomi.util.system.LocaleHelper import eu.kanade.tachiyomi.util.view.openInBrowser import eu.kanade.tachiyomi.util.view.scrollViewWith +import eu.kanade.tachiyomi.util.view.setAction import eu.kanade.tachiyomi.util.view.snack import eu.kanade.tachiyomi.widget.LinearLayoutManagerAccurateOffset import eu.kanade.tachiyomi.widget.TachiyomiTextInputEditText.Companion.setIncognito @@ -55,6 +56,8 @@ import okhttp3.HttpUrl.Companion.toHttpUrl import uy.kohesive.injekt.Injekt import uy.kohesive.injekt.api.get import uy.kohesive.injekt.injectLazy +import yokai.i18n.MR +import yokai.util.lang.getString @SuppressLint("RestrictedApi") class ExtensionDetailsController(bundle: Bundle? = null) : @@ -85,7 +88,7 @@ class ExtensionDetailsController(bundle: Bundle? = null) : override val presenter = ExtensionDetailsPresenter(args.getString(PKGNAME_KEY)!!) override fun getTitle(): String? { - return resources?.getString(R.string.extension_info) + return view?.context?.getString(MR.strings.extension_info) } @SuppressLint("PrivateResource") @@ -193,7 +196,7 @@ class ExtensionDetailsController(bundle: Bundle? = null) : Logger.d { "Cleared $cleared cookies for: ${urls.joinToString()}" } val context = view?.context ?: return - binding.coordinator.snack(context.getString(R.string.cookies_cleared)) + binding.coordinator.snack(context.getString(MR.strings.cookies_cleared)) } private fun addPreferencesForSource(screen: PreferenceScreen, source: Source, isMultiSource: Boolean, isMultiLangSingleSource: Boolean) { @@ -218,12 +221,12 @@ class ExtensionDetailsController(bundle: Bundle? = null) : } else { binding.coordinator.snack( context.getString( - R.string._must_be_enabled_first, - title, + MR.strings._must_be_enabled_first, + title?.toString() ?: "", ), Snackbar.LENGTH_LONG, ) { - setAction(R.string.enable) { + setAction(MR.strings.enable) { preferences.enabledLanguages() += source.lang isChecked = true toggleSource(source, true) diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/extension/details/ExtensionDetailsHeaderAdapter.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/extension/details/ExtensionDetailsHeaderAdapter.kt index aa08bb258c..85f2327d3c 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/extension/details/ExtensionDetailsHeaderAdapter.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/extension/details/ExtensionDetailsHeaderAdapter.kt @@ -13,6 +13,10 @@ import eu.kanade.tachiyomi.ui.extension.getApplicationIcon import eu.kanade.tachiyomi.util.system.LocaleHelper import eu.kanade.tachiyomi.util.system.materialAlertDialog import eu.kanade.tachiyomi.util.view.inflate +import eu.kanade.tachiyomi.util.view.setPositiveButton +import eu.kanade.tachiyomi.util.view.setText +import yokai.i18n.MR +import yokai.util.lang.getString import android.R as AR class ExtensionDetailsHeaderAdapter(private val presenter: ExtensionDetailsPresenter) : @@ -45,8 +49,8 @@ class ExtensionDetailsHeaderAdapter(private val presenter: ExtensionDetailsPrese extension.getApplicationIcon(context)?.let { binding.extensionIcon.setImageDrawable(it) } binding.extensionTitle.text = extension.name - binding.extensionVersion.text = context.getString(R.string.version_, extension.versionName) - binding.extensionLang.text = context.getString(R.string.language_, LocaleHelper.getSourceDisplayName(extension.lang, context)) + binding.extensionVersion.text = context.getString(MR.strings.version_, extension.versionName) + binding.extensionLang.text = context.getString(MR.strings.language_, LocaleHelper.getSourceDisplayName(extension.lang, context)) binding.extensionNsfw.isVisible = extension.isNsfw binding.extensionPkg.text = extension.pkgName @@ -56,7 +60,7 @@ class ExtensionDetailsHeaderAdapter(private val presenter: ExtensionDetailsPrese } else { context.materialAlertDialog() .setTitle(extension.name) - .setPositiveButton(R.string.remove) { _, _ -> + .setPositiveButton(MR.strings.remove) { _, _ -> presenter.uninstallExtension() } .setNegativeButton(AR.string.cancel, null) @@ -73,12 +77,12 @@ class ExtensionDetailsHeaderAdapter(private val presenter: ExtensionDetailsPrese binding.extensionAppInfoButton.isVisible = extension.isShared if (!extension.isShared) { - binding.extensionUninstallButton.text = context.getString(R.string.remove) + binding.extensionUninstallButton.text = context.getString(MR.strings.remove) } if (extension.isObsolete) { binding.extensionWarningBanner.isVisible = true - binding.extensionWarningBanner.setText(R.string.obsolete_extension_message) + binding.extensionWarningBanner.setText(MR.strings.obsolete_extension_message) } } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryBadge.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryBadge.kt index 365fc3848a..2ab97ef6e1 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryBadge.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryBadge.kt @@ -10,6 +10,9 @@ import com.google.android.material.card.MaterialCardView import com.google.android.material.imageview.ShapeableImageView import com.google.android.material.shape.MaterialShapeDrawable import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.databinding.UnreadDownloadBadgeBinding import eu.kanade.tachiyomi.util.system.contextCompatColor import eu.kanade.tachiyomi.util.system.dpToPx @@ -67,7 +70,7 @@ class LibraryBadge @JvmOverloads constructor(context: Context, attrs: AttributeS return@with } text = if (downloads == -2) { - resources.getString(R.string.local) + context.getString(MR.strings.local) } else { downloads.toString() } @@ -171,7 +174,7 @@ class LibraryBadge @JvmOverloads constructor(context: Context, attrs: AttributeS binding.unreadAngle.isVisible = false binding.unreadText.updatePaddingRelative(start = 5.dpToPx) binding.unreadText.isVisible = inLibrary - binding.unreadText.text = resources.getText(R.string.in_library) + binding.unreadText.text = context.getString(MR.strings.in_library) binding.unreadText.background = MaterialShapeDrawable(makeShapeCorners(radius, radius)).apply { this.fillColor = diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryCategoryAdapter.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryCategoryAdapter.kt index a424533e29..56724ec453 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryCategoryAdapter.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryCategoryAdapter.kt @@ -6,6 +6,9 @@ import android.view.View import eu.davidea.flexibleadapter.FlexibleAdapter import eu.davidea.flexibleadapter.items.IFlexible import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.database.DatabaseHelper import eu.kanade.tachiyomi.data.database.models.Manga import eu.kanade.tachiyomi.data.preference.PreferencesHelper @@ -191,7 +194,7 @@ class LibraryCategoryAdapter(val controller: LibraryController?) : val preferences: PreferencesHelper by injectLazy() val db: DatabaseHelper by injectLazy() val context = recyclerView.context - if (position == itemCount - 1) return context.getString(R.string.bottom) + if (position == itemCount - 1) return context.getString(MR.strings.bottom) return when (val item: IFlexible<*>? = getItem(position)) { is LibraryHeaderItem -> { vibrateOnCategoryChange(item.category.name) @@ -205,7 +208,7 @@ class LibraryCategoryAdapter(val controller: LibraryController?) : LibrarySort.DragAndDrop -> { if (item.header.category.isDynamic) { val category = db.getCategoriesForManga(item.manga).executeAsBlocking().firstOrNull()?.name - category ?: context.getString(R.string.default_value) + category ?: context.getString(MR.strings.default_value) } else { val title = item.manga.title if (preferences.removeArticles().get()) { @@ -219,27 +222,27 @@ class LibraryCategoryAdapter(val controller: LibraryController?) : val id = item.manga.id ?: return "" val history = db.getChapters(id).executeAsBlocking() val last = history.maxOfOrNull { it.date_fetch } - context.timeSpanFromNow(R.string.fetched_, last ?: 0) + context.timeSpanFromNow(MR.strings.fetched_, last ?: 0) } LibrarySort.LastRead -> { val id = item.manga.id ?: return "" val history = db.getHistoryByMangaId(id).executeAsBlocking() val last = history.maxOfOrNull { it.last_read } - context.timeSpanFromNow(R.string.read_, last ?: 0) + context.timeSpanFromNow(MR.strings.read_, last ?: 0) } LibrarySort.Unread -> { val unread = item.manga.unread if (unread > 0) { - context.getString(R.string._unread, unread) + context.getString(MR.strings._unread, unread) } else { - context.getString(R.string.read) + context.getString(MR.strings.read) } } LibrarySort.TotalChapters -> { val total = item.manga.totalChapters if (total > 0) { - recyclerView.resources.getQuantityString( - R.plurals.chapters_plural, + recyclerView.context.getString( + MR.plurals.chapters_plural, total, total, ) @@ -248,10 +251,10 @@ class LibraryCategoryAdapter(val controller: LibraryController?) : } } LibrarySort.LatestChapter -> { - context.timeSpanFromNow(R.string.updated_, item.manga.last_update) + context.timeSpanFromNow(MR.strings.updated_, item.manga.last_update) } LibrarySort.DateAdded -> { - context.timeSpanFromNow(R.string.added_, item.manga.date_added) + context.timeSpanFromNow(MR.strings.added_, item.manga.date_added) } LibrarySort.Title -> { val title = if (preferences.removeArticles().get()) { diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryController.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryController.kt index c2f1941378..3750daaa1a 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryController.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryController.kt @@ -51,12 +51,16 @@ import com.bluelinelabs.conductor.ControllerChangeType import com.github.florent37.viewtooltip.ViewTooltip import com.google.android.material.snackbar.BaseTransientBottomBar import com.google.android.material.snackbar.Snackbar +import dev.icerock.moko.resources.StringResource import eu.davidea.flexibleadapter.FlexibleAdapter import eu.davidea.flexibleadapter.SelectableAdapter import eu.davidea.flexibleadapter.items.IFlexible import eu.davidea.flexibleadapter.items.IHeader import eu.davidea.flexibleadapter.items.ISectionable import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.core.preference.Preference import eu.kanade.tachiyomi.data.database.models.Category import eu.kanade.tachiyomi.data.database.models.LibraryManga @@ -116,10 +120,15 @@ import eu.kanade.tachiyomi.util.view.isExpanded import eu.kanade.tachiyomi.util.view.isHidden import eu.kanade.tachiyomi.util.view.isSettling import eu.kanade.tachiyomi.util.view.scrollViewWith +import eu.kanade.tachiyomi.util.view.setAction +import eu.kanade.tachiyomi.util.view.setMessage import eu.kanade.tachiyomi.util.view.setOnQueryTextChangeListener +import eu.kanade.tachiyomi.util.view.setPositiveButton import eu.kanade.tachiyomi.util.view.setStyle +import eu.kanade.tachiyomi.util.view.setTitle import eu.kanade.tachiyomi.util.view.smoothScrollToTop import eu.kanade.tachiyomi.util.view.snack +import eu.kanade.tachiyomi.util.view.text import eu.kanade.tachiyomi.util.view.withFadeTransaction import eu.kanade.tachiyomi.widget.EmptyView import kotlinx.coroutines.delay @@ -259,7 +268,7 @@ open class LibraryController( private var showAllCategoriesView: ImageView? = null override fun getTitle(): String? { setSubtitle() - return view?.context?.getString(R.string.library) + return view?.context?.getString(MR.strings.library) } override fun getSearchTitle(): String? { @@ -270,7 +279,7 @@ open class LibraryController( ) { "\"${preferences.librarySearchSuggestion().get()}\"" } else { - view?.context?.getString(R.string.your_library)?.lowercase(Locale.ROOT) + view?.context?.getString(MR.strings.your_library)?.lowercase(Locale.ROOT) }, ) } @@ -501,7 +510,7 @@ open class LibraryController( filterTooltip = ViewTooltip.on(activity, icon).autoHide(false, 0L).align(ViewTooltip.ALIGN.START) .position(ViewTooltip.Position.TOP) - .text(R.string.tap_library_to_show_filters) + .text(MR.strings.tap_library_to_show_filters) .textColor(activity.getResourceColor(R.attr.colorOnSecondary)) .color(activity.getResourceColor(R.attr.colorSecondary)) .textSize(TypedValue.COMPLEX_UNIT_SP, 15f).withShadow(false) @@ -537,7 +546,7 @@ open class LibraryController( MaterialMenuSheet( activity!!, items, - activity!!.getString(R.string.group_library_by), + activity!!.getString(MR.strings.group_library_by), presenter.groupType, ) { _, item -> if (!isSubClass) { @@ -742,7 +751,7 @@ open class LibraryController( MaterialMenuSheet( activity!!, items, - it.context.getString(R.string.jump_to_category), + it.context.getString(MR.strings.jump_to_category), activeCategory, 300.dpToPx, ) { _, item -> @@ -948,10 +957,10 @@ open class LibraryController( private fun updateLibrary(category: Category? = null) { val view = view ?: return LibraryUpdateJob.startNow(view.context, category) - snack = view.snack(R.string.updating_library) { + snack = view.snack(MR.strings.updating_library) { anchorView = anchorView() this.view.elevation = 15f.dpToPx - setAction(R.string.cancel) { + setAction(MR.strings.cancel) { LibraryUpdateJob.stop(context) viewScope.launchUI { NotificationReceiver.dismissNotification( @@ -1116,13 +1125,13 @@ open class LibraryController( binding.emptyView.show( R.drawable.ic_heart_off_24dp, if (hasActiveFilters) { - R.string.no_matches_for_filters + MR.strings.no_matches_for_filters } else { - R.string.library_is_empty_add_from_browse + MR.strings.library_is_empty_add_from_browse }, if (!hasActiveFilters) { listOf( - EmptyView.Action(R.string.getting_started_guide) { + EmptyView.Action(MR.strings.getting_started_guide) { activity?.openInBrowser("https://tachiyomi.org/docs/guides/getting-started#_2-adding-sources") }, ) @@ -1681,7 +1690,7 @@ open class LibraryController( } else { if (presenter.mangaIsInCategory(item.manga, newHeader?.category?.id)) { adapter.moveItem(position, lastItemPosition!!) - snack = view?.snack(R.string.already_in_category) { + snack = view?.snack(MR.strings.already_in_category) { anchorView = anchorView() view.elevation = 15f.dpToPx } @@ -1719,11 +1728,11 @@ open class LibraryController( presenter.moveMangaToCategory(manga, category.id, mangaIds) snack?.dismiss() snack = view?.snack( - resources!!.getString(R.string.moved_to_, category.name), + view!!.context!!.getString(MR.strings.moved_to_, category.name), ) { anchorView = anchorView() view.elevation = 15f.dpToPx - setAction(R.string.undo) { + setAction(MR.strings.undo) { manga.category = category.id!! presenter.moveMangaToCategory(manga, oldCatId, mangaIds) } @@ -1735,11 +1744,11 @@ open class LibraryController( val inQueue = LibraryUpdateJob.categoryInQueue(category.id) snack?.dismiss() snack = view?.snack( - resources!!.getString( + view!!.context!!.getString( when { - inQueue -> R.string._already_in_queue - LibraryUpdateJob.isRunning(view!!.context) -> R.string.adding_category_to_queue - else -> R.string.updating_ + inQueue -> MR.strings._already_in_queue + LibraryUpdateJob.isRunning(view!!.context) -> MR.strings.adding_category_to_queue + else -> MR.strings.updating_ }, category.name, ), @@ -1747,7 +1756,7 @@ open class LibraryController( ) { anchorView = anchorView() view.elevation = 15f.dpToPx - setAction(R.string.cancel) { + setAction(MR.strings.cancel) { LibraryUpdateJob.stop(context) viewScope.launchUI { NotificationReceiver.dismissNotification( @@ -1882,7 +1891,7 @@ open class LibraryController( val searchItem = activityBinding?.searchToolbar?.searchItem val searchView = activityBinding?.searchToolbar?.searchView - activityBinding?.searchToolbar?.setQueryHint(resources?.getString(R.string.library_search_hint), query.isEmpty()) + activityBinding?.searchToolbar?.setQueryHint(view?.context?.getString(MR.strings.library_search_hint), query.isEmpty()) showAllCategoriesView = showAllCategoriesView ?: (searchView as? MiniSearchView)?.addSearchModifierIcon { context -> ImageView(context).apply { @@ -1898,7 +1907,7 @@ open class LibraryController( setImageResource(R.drawable.ic_show_all_categories_24dp) background = context.getResourceDrawable(R.attr.selectableItemBackgroundBorderless) imageTintList = ColorStateList.valueOf(context.getResourceColor(R.attr.actionBarTintColor)) - compatToolTipText = resources?.getText(R.string.show_all_categories) + compatToolTipText = view?.context?.getString(MR.strings.show_all_categories) } }!! @@ -2014,7 +2023,7 @@ open class LibraryController( if (count == 0) { destroyActionModeIfNeeded() } else { - mode.title = resources?.getString(R.string.selected_, count) + mode.title = view?.context?.getString(MR.strings.selected_, count) } return false } @@ -2026,12 +2035,12 @@ open class LibraryController( R.id.action_share -> shareManga() R.id.action_delete -> { val options = arrayOf( - R.string.remove_downloads, - R.string.remove_from_library, + MR.strings.remove_downloads, + MR.strings.remove_from_library, ) .map { activity!!.getString(it) } activity!!.materialAlertDialog() - .setTitle(R.string.remove) + .setTitle(MR.strings.remove) .setMultiChoiceItems( options.toTypedArray(), options.map { true }.toBooleanArray(), @@ -2041,7 +2050,7 @@ open class LibraryController( listView.setItemChecked(position, true) } } - .setPositiveButton(R.string.remove) { dialog, _ -> + .setPositiveButton(MR.strings.remove) { dialog, _ -> val listView = (dialog as AlertDialog).listView if (listView.isItemChecked(1)) { deleteMangasFromLibrary() @@ -2060,18 +2069,18 @@ open class LibraryController( } R.id.action_mark_as_read -> { activity!!.materialAlertDialog() - .setMessage(R.string.mark_all_chapters_as_read) - .setPositiveButton(R.string.mark_as_read) { _, _ -> - markReadStatus(R.string.marked_as_read, true) + .setMessage(MR.strings.mark_all_chapters_as_read) + .setPositiveButton(MR.strings.mark_as_read) { _, _ -> + markReadStatus(MR.strings.marked_as_read, true) } .setNegativeButton(AR.string.cancel, null) .show() } R.id.action_mark_as_unread -> { activity!!.materialAlertDialog() - .setMessage(R.string.mark_all_chapters_as_unread) - .setPositiveButton(R.string.mark_as_unread) { _, _ -> - markReadStatus(R.string.marked_as_unread, false) + .setMessage(MR.strings.mark_all_chapters_as_unread) + .setPositiveButton(MR.strings.mark_as_unread) { _, _ -> + markReadStatus(MR.strings.marked_as_unread, false) } .setNegativeButton(AR.string.cancel, null) .show() @@ -2090,7 +2099,7 @@ open class LibraryController( return true } - private fun markReadStatus(resource: Int, markRead: Boolean) { + private fun markReadStatus(resource: StringResource, markRead: Boolean) { val mapMangaChapters = presenter.markReadStatus(selectedMangas.toList(), markRead) destroyActionModeIfNeeded() snack?.dismiss() @@ -2098,7 +2107,7 @@ open class LibraryController( anchorView = anchorView() view.elevation = 15f.dpToPx var undoing = false - setAction(R.string.undo) { + setAction(MR.strings.undo) { presenter.undoMarkReadStatus(mapMangaChapters) undoing = true } @@ -2132,7 +2141,7 @@ open class LibraryController( type = "text/*" putExtra(Intent.EXTRA_TEXT, urls) } - startActivity(Intent.createChooser(intent, context.getString(R.string.share))) + startActivity(Intent.createChooser(intent, context.getString(MR.strings.share))) } open fun deleteMangasFromLibrary() { @@ -2141,13 +2150,13 @@ open class LibraryController( destroyActionModeIfNeeded() snack?.dismiss() snack = view?.snack( - activity?.getString(R.string.removed_from_library) ?: "", + activity?.getString(MR.strings.removed_from_library) ?: "", Snackbar.LENGTH_INDEFINITE, ) { anchorView = anchorView() view.elevation = 15f.dpToPx var undoing = false - setAction(R.string.undo) { + setAction(MR.strings.undo) { presenter.reAddMangas(mangas) undoing = true } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryGridHolder.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryGridHolder.kt index 814c7ca5fc..a58f82a45e 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryGridHolder.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryGridHolder.kt @@ -14,6 +14,9 @@ import coil3.dispose import coil3.size.Precision import coil3.size.Scale import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.database.models.Manga import eu.kanade.tachiyomi.data.coil.loadManga import eu.kanade.tachiyomi.databinding.MangaGridItemBinding diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryGroup.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryGroup.kt index 780d1ca913..28040e853a 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryGroup.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryGroup.kt @@ -1,6 +1,10 @@ package eu.kanade.tachiyomi.ui.library +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource object LibraryGroup { @@ -13,16 +17,16 @@ object LibraryGroup { const val BY_LANGUAGE = 7 const val UNGROUPED = 5 - fun groupTypeStringRes(type: Int, hasCategories: Boolean = true): Int { + fun groupTypeStringRes(type: Int, hasCategories: Boolean = true): StringResource { return when (type) { - BY_STATUS -> R.string.status - BY_TAG -> R.string.tag - BY_SOURCE -> R.string.sources - BY_TRACK_STATUS -> R.string.tracking_status - BY_AUTHOR -> R.string.author - BY_LANGUAGE -> R.string.language - UNGROUPED -> R.string.ungrouped - else -> if (hasCategories) R.string.categories else R.string.ungrouped + BY_STATUS -> MR.strings.status + BY_TAG -> MR.strings.tag + BY_SOURCE -> MR.strings.sources + BY_TRACK_STATUS -> MR.strings.tracking_status + BY_AUTHOR -> MR.strings.author + BY_LANGUAGE -> MR.strings.language + UNGROUPED -> MR.strings.ungrouped + else -> if (hasCategories) MR.strings.categories else MR.strings.ungrouped } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryHeaderHolder.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryHeaderHolder.kt index bd515d6e67..a024b5afa8 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryHeaderHolder.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryHeaderHolder.kt @@ -18,6 +18,9 @@ import androidx.swiperefreshlayout.widget.CircularProgressDrawable import com.github.florent37.viewtooltip.ViewTooltip import eu.davidea.flexibleadapter.SelectableAdapter import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.database.models.Category import eu.kanade.tachiyomi.data.library.LibraryUpdateJob import eu.kanade.tachiyomi.data.preference.PreferencesHelper @@ -29,6 +32,8 @@ import eu.kanade.tachiyomi.util.system.contextCompatDrawable import eu.kanade.tachiyomi.util.system.dpToPx import eu.kanade.tachiyomi.util.system.getResourceColor import eu.kanade.tachiyomi.util.view.compatToolTipText +import eu.kanade.tachiyomi.util.view.setText +import eu.kanade.tachiyomi.util.view.text import uy.kohesive.injekt.Injekt import uy.kohesive.injekt.api.get @@ -60,7 +65,7 @@ class LibraryHeaderHolder(val view: View, val adapter: LibraryCategoryAdapter) : } } binding.categorySort.setOnClickListener { it.post { showCatSortOptions() } } - binding.categorySort.compatToolTipText = view.context.getString(R.string.sort) + binding.categorySort.compatToolTipText = view.context.getString(MR.strings.sort) binding.checkbox.setOnClickListener { selectAll() } runningDrawable.setStyle(CircularProgressDrawable.DEFAULT) @@ -128,7 +133,7 @@ class LibraryHeaderHolder(val view: View, val adapter: LibraryCategoryAdapter) : if (!tutorial.get()) { ViewTooltip.on(itemView.context as? Activity, binding.categoryTitle).autoHide(true, 5000L) .align(ViewTooltip.ALIGN.START).position(ViewTooltip.Position.TOP) - .text(R.string.long_press_category) + .text(MR.strings.long_press_category) .color(itemView.context.getResourceColor(R.attr.colorSecondary)) .textSize(TypedValue.COMPLEX_UNIT_SP, 15f).textColor(Color.WHITE) .withShadow(false).corner(30).arrowWidth(15).arrowHeight(15).distanceWithView(0) @@ -282,7 +287,7 @@ class LibraryHeaderHolder(val view: View, val adapter: LibraryCategoryAdapter) : val sheet = MaterialMenuSheet( activity, items, - activity.getString(R.string.sort_by), + activity.getString(MR.strings.sort_by), sortingMode?.mainValue, ) { sheet, item -> onCatSortClicked(category, item) diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryHeaderItem.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryHeaderItem.kt index 21f383613d..70cb4fcc1c 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryHeaderItem.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryHeaderItem.kt @@ -7,6 +7,9 @@ import eu.davidea.flexibleadapter.FlexibleAdapter import eu.davidea.flexibleadapter.items.AbstractHeaderItem import eu.davidea.flexibleadapter.items.IFlexible import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.database.models.Category class LibraryHeaderItem( diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryHolder.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryHolder.kt index 372f98c676..b9c721637b 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryHolder.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryHolder.kt @@ -5,6 +5,9 @@ import androidx.core.graphics.ColorUtils import androidx.core.view.isVisible import com.google.android.material.card.MaterialCardView import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.ui.base.holder.BaseFlexibleViewHolder import eu.kanade.tachiyomi.util.isLocal import eu.kanade.tachiyomi.util.system.getResourceColor diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryItem.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryItem.kt index 4f90d3d102..25eb47383b 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryItem.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryItem.kt @@ -16,6 +16,9 @@ import eu.davidea.flexibleadapter.items.AbstractSectionableItem import eu.davidea.flexibleadapter.items.IFilterable import eu.davidea.flexibleadapter.items.IFlexible import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.database.models.LibraryManga import eu.kanade.tachiyomi.data.preference.PreferencesHelper import eu.kanade.tachiyomi.databinding.MangaGridItemBinding diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryListHolder.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryListHolder.kt index 2f43d4b496..43036c8a25 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryListHolder.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryListHolder.kt @@ -6,6 +6,9 @@ import androidx.core.view.isVisible import androidx.core.view.updateLayoutParams import coil3.dispose import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.coil.loadManga import eu.kanade.tachiyomi.databinding.MangaListItemBinding import eu.kanade.tachiyomi.util.lang.highlightText @@ -49,9 +52,9 @@ class LibraryListHolder( } else { binding.title.text = itemView.context.getString( if (adapter.hasActiveFilters && item.manga.realMangaCount >= 1) { - R.string.no_matches_for_filters_short + MR.strings.no_matches_for_filters_short } else { - R.string.category_is_empty + MR.strings.category_is_empty }, ) } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryPresenter.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryPresenter.kt index 7c55e5d5d8..8073392e5c 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryPresenter.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibraryPresenter.kt @@ -1,6 +1,9 @@ package eu.kanade.tachiyomi.ui.library import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.core.preference.minusAssign import eu.kanade.tachiyomi.core.preference.plusAssign import eu.kanade.tachiyomi.data.cache.CoverCache @@ -809,7 +812,7 @@ class LibraryPresenter( return headerItem } - val unknown = context.getString(R.string.unknown) + val unknown = context.getString(MR.strings.unknown) val removedManga = mutableListOf() val items = libraryMangaList.mapNotNull map@ { manga -> when (groupType) { @@ -845,7 +848,7 @@ class LibraryPresenter( service.getStatus(track.status) } } else { - view?.view?.context?.getString(R.string.not_tracked) ?: "" + view?.view?.context?.getString(MR.strings.not_tracked) ?: "" } val header = makeOrGetHeader(status) val item = LibraryItem(manga, header, viewContext) @@ -1167,7 +1170,7 @@ class LibraryPresenter( return headerItem } - val unknown = context.getString(R.string.unknown) + val unknown = context.getString(MR.strings.unknown) val items = libraryManga.map { manga -> when (groupType) { BY_TAG -> { @@ -1196,7 +1199,7 @@ class LibraryPresenter( service.getStatus(track.status) } } else { - view?.view?.context?.getString(R.string.not_tracked) ?: "" + view?.view?.context?.getString(MR.strings.not_tracked) ?: "" } listOf(LibraryItem(manga, makeOrGetHeader(status), viewContext)) } @@ -1320,12 +1323,12 @@ class LibraryPresenter( private fun mapTrackingOrder(status: String): String { with(context) { return when (status) { - getString(R.string.reading), getString(R.string.currently_reading) -> "1" - getString(R.string.rereading) -> "2" - getString(R.string.plan_to_read), getString(R.string.want_to_read) -> "3" - getString(R.string.on_hold), getString(R.string.paused) -> "4" - getString(R.string.completed) -> "5" - getString(R.string.dropped) -> "6" + getString(MR.strings.reading), getString(MR.strings.currently_reading) -> "1" + getString(MR.strings.rereading) -> "2" + getString(MR.strings.plan_to_read), getString(MR.strings.want_to_read) -> "3" + getString(MR.strings.on_hold), getString(MR.strings.paused) -> "4" + getString(MR.strings.completed) -> "5" + getString(MR.strings.dropped) -> "6" else -> "7" } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibrarySort.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibrarySort.kt index baae2ac11c..0d5ae1dd7d 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibrarySort.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/library/LibrarySort.kt @@ -2,31 +2,35 @@ package eu.kanade.tachiyomi.ui.library import androidx.annotation.DrawableRes import androidx.annotation.StringRes +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.ui.base.MaterialMenuSheet enum class LibrarySort( val mainValue: Int, - @StringRes private val stringRes: Int, + private val stringRes: StringResource, @DrawableRes private val iconRes: Int, private val catValue: Int = mainValue, - @StringRes private val dynamicStringRes: Int = stringRes, + private val dynamicStringRes: StringResource = stringRes, @DrawableRes private val dynamicIconRes: Int = iconRes, ) { - Title(0, R.string.title, R.drawable.ic_sort_by_alpha_24dp), - LastRead(1, R.string.last_read, R.drawable.ic_recent_read_outline_24dp, 3), - LatestChapter(2, R.string.latest_chapter, R.drawable.ic_new_releases_24dp, 1), - Unread(3, R.string.unread, R.drawable.ic_eye_24dp, 2), - TotalChapters(4, R.string.total_chapters, R.drawable.ic_sort_by_numeric_24dp), - DateAdded(5, R.string.date_added, R.drawable.ic_heart_outline_24dp), - DateFetched(6, R.string.date_fetched, R.drawable.ic_calendar_text_outline_24dp), + Title(0, MR.strings.title, R.drawable.ic_sort_by_alpha_24dp), + LastRead(1, MR.strings.last_read, R.drawable.ic_recent_read_outline_24dp, 3), + LatestChapter(2, MR.strings.latest_chapter, R.drawable.ic_new_releases_24dp, 1), + Unread(3, MR.strings.unread, R.drawable.ic_eye_24dp, 2), + TotalChapters(4, MR.strings.total_chapters, R.drawable.ic_sort_by_numeric_24dp), + DateAdded(5, MR.strings.date_added, R.drawable.ic_heart_outline_24dp), + DateFetched(6, MR.strings.date_fetched, R.drawable.ic_calendar_text_outline_24dp), DragAndDrop( 7, - R.string.drag_and_drop, + MR.strings.drag_and_drop, R.drawable.ic_swap_vert_24dp, 7, - R.string.category, + MR.strings.category, R.drawable.ic_label_outline_24dp, ), @@ -51,7 +55,6 @@ enum class LibrarySort( return "$type,ASCENDING" } - @StringRes fun stringRes(isDynamic: Boolean) = if (isDynamic) dynamicStringRes else stringRes @DrawableRes diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/library/SearchGlobalItem.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/library/SearchGlobalItem.kt index 13db896062..28297e25f8 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/library/SearchGlobalItem.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/library/SearchGlobalItem.kt @@ -10,6 +10,9 @@ import eu.davidea.flexibleadapter.FlexibleAdapter import eu.davidea.flexibleadapter.items.AbstractFlexibleItem import eu.davidea.flexibleadapter.items.IFlexible import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.databinding.MaterialTextButtonBinding import eu.kanade.tachiyomi.ui.base.holder.BaseFlexibleViewHolder @@ -77,7 +80,7 @@ class SearchGlobalItem : AbstractFlexibleItem() { } fun bind(string: String) { - binding.button.text = view.context.getString(R.string.search_globally, string) + binding.button.text = view.context.getString(MR.strings.search_globally, string) } override fun onLongClick(view: View?): Boolean { diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/library/display/LibraryCategoryView.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/library/display/LibraryCategoryView.kt index 953aadf25b..b409856977 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/library/display/LibraryCategoryView.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/library/display/LibraryCategoryView.kt @@ -3,6 +3,9 @@ package eu.kanade.tachiyomi.ui.library.display import android.content.Context import android.util.AttributeSet import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.databinding.LibraryCategoryLayoutBinding import eu.kanade.tachiyomi.util.bindToPreference import eu.kanade.tachiyomi.util.lang.withSubtitle @@ -24,8 +27,8 @@ class LibraryCategoryView @JvmOverloads constructor(context: Context, attrs: Att categoryShow.bindToPreference(preferences.showCategoryInTitle()) { controller?.showMiniBar() } - dynamicToBottom.text = context.getString(R.string.move_dynamic_to_bottom) - .withSubtitle(context, R.string.when_grouping_by_sources_tags) + dynamicToBottom.text = context.getString(MR.strings.move_dynamic_to_bottom) + .withSubtitle(context, MR.strings.when_grouping_by_sources_tags) dynamicToBottom.bindToPreference(preferences.collapsedDynamicAtBottom()) { controller?.presenter?.getLibrary() } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/library/display/LibraryDisplayView.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/library/display/LibraryDisplayView.kt index f7dc640616..0d7f6cdb35 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/library/display/LibraryDisplayView.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/library/display/LibraryDisplayView.kt @@ -5,6 +5,9 @@ import android.util.AttributeSet import android.view.View import com.google.android.material.slider.Slider import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.databinding.LibraryDisplayLayoutBinding import eu.kanade.tachiyomi.util.bindToPreference import eu.kanade.tachiyomi.util.lang.addBetaTag @@ -30,7 +33,7 @@ class LibraryDisplayView @JvmOverloads constructor(context: Context, attrs: Attr binding.staggeredGrid.isEnabled = !it } binding.outlineOnCovers.bindToPreference(uiPreferences.outlineOnCovers()) - binding.staggeredGrid.text = context.getString(R.string.use_staggered_grid).addBetaTag(context) + binding.staggeredGrid.text = context.getString(MR.strings.use_staggered_grid).addBetaTag(context) binding.staggeredGrid.isEnabled = !uiPreferences.uniformGrid().get() binding.staggeredGrid.bindToPreference(preferences.useStaggeredGrid()) binding.gridSeekbar.value = ((preferences.gridSize().get() + .5f) * 2f).roundToInt().toFloat() @@ -43,9 +46,9 @@ class LibraryDisplayView @JvmOverloads constructor(context: Context, attrs: Attr val mainText = (mainView ?: this@LibraryDisplayView).rowsForValue(it).toString() val mainOrientation = context.getString( if (context.isLandscape()) { - R.string.landscape + MR.strings.landscape } else { - R.string.portrait + MR.strings.portrait }, ) val alt = ( @@ -60,9 +63,9 @@ class LibraryDisplayView @JvmOverloads constructor(context: Context, attrs: Attr val altText = alt.numberOfRowsForValue(it).toString() val altOrientation = context.getString( if (context.isLandscape()) { - R.string.portrait + MR.strings.portrait } else { - R.string.landscape + MR.strings.landscape }, ) "$mainOrientation: $mainText • $altOrientation: $altText" @@ -95,8 +98,8 @@ class LibraryDisplayView @JvmOverloads constructor(context: Context, attrs: Attr private fun setGridText(progress: Float) { with(binding.gridSizeText) { val rows = (mainView ?: this@LibraryDisplayView).rowsForValue(progress) - val titleText = context.getString(R.string.grid_size) - val subtitleText = context.getString(R.string._per_row, rows) + val titleText = context.getString(MR.strings.grid_size) + val subtitleText = context.getString(MR.strings._per_row, rows) text = titleText.withSubtitle(context, subtitleText) } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/library/display/TabbedLibraryDisplaySheet.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/library/display/TabbedLibraryDisplaySheet.kt index 9a074d119a..1703a6203a 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/library/display/TabbedLibraryDisplaySheet.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/library/display/TabbedLibraryDisplaySheet.kt @@ -4,7 +4,11 @@ import android.view.View import android.view.View.inflate import androidx.core.view.isVisible import com.bluelinelabs.conductor.Controller +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.ui.library.LibraryController import eu.kanade.tachiyomi.ui.setting.controllers.SettingsLibraryController import eu.kanade.tachiyomi.util.system.contextCompatDrawable @@ -27,7 +31,7 @@ open class TabbedLibraryDisplaySheet(val controller: Controller) : } displayView.mainView = controller.view binding.menu.isVisible = controller !is SettingsLibraryController - binding.menu.compatToolTipText = context.getString(R.string.more_library_settings) + binding.menu.compatToolTipText = context.getString(MR.strings.more_library_settings) binding.menu.setImageDrawable(context.contextCompatDrawable(R.drawable.ic_outline_settings_24dp)) binding.menu.setOnClickListener { controller.router.pushController(SettingsLibraryController().withFadeTransaction()) @@ -47,9 +51,9 @@ open class TabbedLibraryDisplaySheet(val controller: Controller) : categoryView, ) - override fun getTabTitles(): List = listOf( - R.string.display, - R.string.badges, - R.string.categories, + override fun getTabTitles(): List = listOf( + MR.strings.display, + MR.strings.badges, + MR.strings.categories, ) } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/library/filter/ExpandedFilterItem.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/library/filter/ExpandedFilterItem.kt index 891256b274..0873fa7b37 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/library/filter/ExpandedFilterItem.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/library/filter/ExpandedFilterItem.kt @@ -14,6 +14,8 @@ import eu.kanade.tachiyomi.R import eu.kanade.tachiyomi.databinding.ExpandedFilterItemBinding import eu.kanade.tachiyomi.databinding.ExpandedFilterItemTextViewBinding import eu.kanade.tachiyomi.util.system.dpToPx +import yokai.i18n.MR +import yokai.util.lang.getString class ExpandedFilterItem(val filter: LibraryFilter) : AbstractItem>() { @@ -43,7 +45,7 @@ class ExpandedFilterItem(val filter: LibraryFilter) : AbstractItem { + context.getString(MR.strings.tracking) -> { if (index == 0 && trackerItem != null && itemAdapter.adapterItems.contains( trackerItem, ) @@ -121,13 +124,13 @@ class ExpandedFilterSheet( } } - context.getString(R.string.read_progress), context.getString(R.string.unread) -> { + context.getString(MR.strings.read_progress), context.getString(MR.strings.unread) -> { if (index != 0) { val otherName = - if (filters[position].headerName == context.getString(R.string.read_progress)) { - context.getString(R.string.unread) + if (filters[position].headerName == context.getString(MR.strings.read_progress)) { + context.getString(MR.strings.unread) } else { - context.getString(R.string.read_progress) + context.getString(MR.strings.read_progress) } val otherFilter = filters.find { it.headerName == otherName } ?: return @@ -146,7 +149,7 @@ class ExpandedFilterSheet( }, ) itemAdapter.set(filters.map(::ExpandedFilterItem)) - val trackingFilter = filters.find { it.headerName == context.getString(R.string.tracking) } + val trackingFilter = filters.find { it.headerName == context.getString(MR.strings.tracking) } if ((trackingFilter?.activeFilter ?: 0) > 0 && trackerItem != null) { itemAdapter.add(filters.indexOf(trackingFilter) + 1, trackerItem) } @@ -176,10 +179,10 @@ class ExpandedFilterSheet( adapter.isHandleDragEnabled = true adapter.isLongPressDragEnabled = true context.materialAlertDialog() - .setTitle(R.string.reorder_filters) + .setTitle(MR.strings.reorder_filters) .setView(recycler) .setNegativeButton(AR.string.cancel, null) - .setPositiveButton(R.string.reorder) { _, _ -> + .setPositiveButton(MR.strings.reorder) { _, _ -> val order = adapter.currentItems.map { it.char }.joinToString("") preferences.filterOrder().set(order) recycler.adapter = null @@ -234,7 +237,7 @@ class ExpandedFilterSheet( clearFilterCallback() } private fun applyFilters() { - val trackingFilter = filters.find { it.headerName == context.getString(R.string.tracking) } + val trackingFilter = filters.find { it.headerName == context.getString(MR.strings.tracking) } if (trackingFilter?.activeFilter == 0 && trackerItem != null) { trackerItem.filter.activeFilter = 0 } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/library/filter/FilterBottomSheet.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/library/filter/FilterBottomSheet.kt index 96e6711dbc..40b5b09a96 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/library/filter/FilterBottomSheet.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/library/filter/FilterBottomSheet.kt @@ -7,12 +7,12 @@ import android.view.View import android.widget.Button import android.widget.ImageView import android.widget.LinearLayout -import androidx.annotation.StringRes import androidx.core.view.WindowInsetsCompat.Type.systemBars import androidx.core.view.isVisible import androidx.core.view.updatePaddingRelative import androidx.vectordrawable.graphics.drawable.AnimatedVectorDrawableCompat import com.google.android.material.bottomsheet.BottomSheetBehavior +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.R import eu.kanade.tachiyomi.data.database.models.Manga import eu.kanade.tachiyomi.data.preference.PreferencesHelper @@ -34,6 +34,7 @@ import eu.kanade.tachiyomi.util.view.inflate import eu.kanade.tachiyomi.util.view.isCollapsed import eu.kanade.tachiyomi.util.view.isExpanded import eu.kanade.tachiyomi.util.view.isHidden +import eu.kanade.tachiyomi.util.view.setText import kotlinx.coroutines.Dispatchers import kotlinx.coroutines.delay import kotlinx.coroutines.flow.drop @@ -44,6 +45,8 @@ import kotlinx.coroutines.withContext import uy.kohesive.injekt.Injekt import uy.kohesive.injekt.api.get import uy.kohesive.injekt.injectLazy +import yokai.i18n.MR +import yokai.util.lang.getString import kotlin.math.max import kotlin.math.roundToInt @@ -236,7 +239,7 @@ class FilterBottomSheet @JvmOverloads constructor(context: Context, attrs: Attri }, trackers?.let { LibraryFilter( - activity.getString(R.string.trackers), + activity.getString(MR.strings.trackers), it.items, it, it.state + 1, @@ -291,9 +294,9 @@ class FilterBottomSheet @JvmOverloads constructor(context: Context, attrs: Attri allExpanded ?: return binding.expandCategories.setText( if (!allExpanded) { - R.string.expand_all_categories + MR.strings.expand_all_categories } else { - R.string.collapse_all_categories + MR.strings.collapse_all_categories }, ) if (animated) { @@ -331,27 +334,27 @@ class FilterBottomSheet @JvmOverloads constructor(context: Context, attrs: Attri private fun createTags() { downloaded = inflate(R.layout.filter_tag_group) as FilterTagGroup - downloaded.setup(this, R.string.downloaded, R.string.not_downloaded) + downloaded.setup(this, MR.strings.downloaded, MR.strings.not_downloaded) completed = inflate(R.layout.filter_tag_group) as FilterTagGroup - completed.setup(this, R.string.completed, R.string.ongoing) + completed.setup(this, MR.strings.completed, MR.strings.ongoing) unreadProgress = inflate(R.layout.filter_tag_group) as FilterTagGroup - unreadProgress.setup(this, R.string.not_started, R.string.in_progress) + unreadProgress.setup(this, MR.strings.not_started, MR.strings.in_progress) unread = inflate(R.layout.filter_tag_group) as FilterTagGroup - unread.setup(this, R.string.unread, R.string.read) + unread.setup(this, MR.strings.unread, MR.strings.read) bookmarked = inflate(R.layout.filter_tag_group) as FilterTagGroup - bookmarked.setup(this, R.string.bookmarked, R.string.not_bookmarked) + bookmarked.setup(this, MR.strings.bookmarked, MR.strings.not_bookmarked) if (hasTracking) { tracked = inflate(R.layout.filter_tag_group) as FilterTagGroup - tracked?.setup(this, R.string.tracked, R.string.not_tracked) + tracked?.setup(this, MR.strings.tracked, MR.strings.not_tracked) } contentType = inflate(R.layout.filter_tag_group) as FilterTagGroup - contentType.setup(this, R.string.sfw, R.string.nsfw) + contentType.setup(this, MR.strings.sfw, MR.strings.nsfw) reSortViews() @@ -366,23 +369,23 @@ class FilterBottomSheet @JvmOverloads constructor(context: Context, attrs: Attri withIOContext { val libraryManga = controller?.presenter?.allLibraryItems ?: return@withIOContext checked = true - var types = mutableSetOf() + var types = mutableSetOf() libraryManga.forEach { when (it.manga.seriesType(sourceManager = sourceManager)) { - Manga.TYPE_MANHWA, Manga.TYPE_WEBTOON -> types.add(R.string.manhwa) - Manga.TYPE_MANHUA -> types.add(R.string.manhua) - Manga.TYPE_COMIC -> types.add(R.string.comic) + Manga.TYPE_MANHWA, Manga.TYPE_WEBTOON -> types.add(MR.strings.manhwa) + Manga.TYPE_MANHUA -> types.add(MR.strings.manhua) + Manga.TYPE_COMIC -> types.add(MR.strings.comic) } if (types.size == 3) return@forEach } - val sortedTypes = arrayOf(R.string.manhwa, R.string.manhua, R.string.comic) + val sortedTypes = arrayOf(MR.strings.manhwa, MR.strings.manhua, MR.strings.comic) types = types.sortedBy { sortedTypes.indexOf(it) }.toMutableSet() if (types.isNotEmpty()) { launchUI { val mangaType = inflate(R.layout.filter_tag_group) as FilterTagGroup mangaType.setup( this@FilterBottomSheet, - R.string.manga, + MR.strings.manga, *types.toTypedArray(), ) this@FilterBottomSheet.mangaType = mangaType @@ -393,10 +396,10 @@ class FilterBottomSheet @JvmOverloads constructor(context: Context, attrs: Attri withUIContext { mangaType?.setState( when (preferences.filterMangaType().get()) { - Manga.TYPE_MANGA -> context.getString(R.string.manga) - Manga.TYPE_MANHUA -> context.getString(R.string.manhua) - Manga.TYPE_MANHWA -> context.getString(R.string.manhwa) - Manga.TYPE_COMIC -> context.getString(R.string.comic) + Manga.TYPE_MANGA -> context.getString(MR.strings.manga) + Manga.TYPE_MANHUA -> context.getString(MR.strings.manhua) + Manga.TYPE_MANHWA -> context.getString(MR.strings.manhwa) + Manga.TYPE_COMIC -> context.getString(MR.strings.comic) else -> "" }, ) @@ -530,10 +533,10 @@ class FilterBottomSheet @JvmOverloads constructor(context: Context, attrs: Attri tracked -> preferences.filterTracked() mangaType -> { val newIndex = when (view.nameOf(index)) { - context.getString(R.string.manga) -> Manga.TYPE_MANGA - context.getString(R.string.manhua) -> Manga.TYPE_MANHUA - context.getString(R.string.manhwa) -> Manga.TYPE_MANHWA - context.getString(R.string.comic) -> Manga.TYPE_COMIC + context.getString(MR.strings.manga) -> Manga.TYPE_MANGA + context.getString(MR.strings.manhua) -> Manga.TYPE_MANHUA + context.getString(MR.strings.manhwa) -> Manga.TYPE_MANHWA + context.getString(MR.strings.comic) -> Manga.TYPE_COMIC else -> 0 } preferences.filterMangaType().set(newIndex) @@ -625,15 +628,15 @@ class FilterBottomSheet @JvmOverloads constructor(context: Context, attrs: Attri var FILTER_TRACKER = "" } - enum class Filters(val value: Char, @StringRes val stringRes: Int) { - UnreadProgress('u', R.string.read_progress), - Unread('r', R.string.unread), - Downloaded('d', R.string.downloaded), - Completed('c', R.string.status), - SeriesType('m', R.string.series_type), - Bookmarked('b', R.string.bookmarked), - Tracked('t', R.string.tracking), - ContentType('s', R.string.content_type); + enum class Filters(val value: Char, val stringRes: StringResource) { + UnreadProgress('u', MR.strings.read_progress), + Unread('r', MR.strings.unread), + Downloaded('d', MR.strings.downloaded), + Completed('c', MR.strings.status), + SeriesType('m', MR.strings.series_type), + Bookmarked('b', MR.strings.bookmarked), + Tracked('t', MR.strings.tracking), + ContentType('s', MR.strings.content_type); ; companion object { diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/library/filter/FilterTagGroup.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/library/filter/FilterTagGroup.kt index 9126ec367d..dc415383a5 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/library/filter/FilterTagGroup.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/library/filter/FilterTagGroup.kt @@ -6,11 +6,13 @@ import android.view.View import android.view.ViewGroup import android.widget.LinearLayout import androidx.core.view.isVisible +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.R import eu.kanade.tachiyomi.core.preference.Preference import eu.kanade.tachiyomi.databinding.FilterTagGroupBinding import eu.kanade.tachiyomi.util.system.dpToPx import eu.kanade.tachiyomi.util.system.getResourceColor +import yokai.util.lang.getString class FilterTagGroup@JvmOverloads constructor(context: Context, attrs: AttributeSet? = null) : LinearLayout (context, attrs) { @@ -57,6 +59,12 @@ class FilterTagGroup@JvmOverloads constructor(context: Context, attrs: Attribute fun nameOf(index: Int): String? = buttons.getOrNull(index)?.text as? String + fun setup(root: ViewGroup, firstText: StringResource, vararg extra: StringResource?) { + val text1 = context.getString(firstText) + val strings = extra.mapNotNull { if (it != null) context.getString(it) else null } + setup(root, text1, extra = strings.toTypedArray()) + } + fun setup(root: ViewGroup, firstText: Int, vararg extra: Int?) { val text1 = context.getString(firstText) val strings = extra.mapNotNull { if (it != null) context.getString(it) else null } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/library/filter/ManageFilterItem.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/library/filter/ManageFilterItem.kt index 6e985929f4..fc038f0f85 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/library/filter/ManageFilterItem.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/library/filter/ManageFilterItem.kt @@ -7,8 +7,12 @@ import eu.davidea.flexibleadapter.FlexibleAdapter import eu.davidea.flexibleadapter.items.AbstractFlexibleItem import eu.davidea.flexibleadapter.items.IFlexible import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.databinding.CategoriesItemBinding import eu.kanade.tachiyomi.ui.base.holder.BaseFlexibleViewHolder +import eu.kanade.tachiyomi.util.view.setText /** * Category item for a recycler view. @@ -83,7 +87,9 @@ class ManageFilterItem(val char: Char) : AbstractFlexibleItem() { registerForActivityResult(ActivityResultContracts.RequestPermission()) { isGranted -> if (!isGranted) { materialAlertDialog() - .setTitle(R.string.warning) - .setMessage(R.string.allow_notifications_recommended) + .setTitle(MR.strings.warning) + .setMessage(MR.strings.allow_notifications_recommended) .setPositiveButton(AR.string.ok, null) .show() } @@ -376,9 +382,9 @@ open class MainActivity : BaseActivity() { nav.getItemView(R.id.nav_library)?.setOnLongClickListener { if (!LibraryUpdateJob.isRunning(this)) { LibraryUpdateJob.startNow(this) - binding.mainContent.snack(R.string.updating_library) { + binding.mainContent.snack(MR.strings.updating_library) { anchorView = binding.bottomNav - setAction(R.string.cancel) { + setAction(MR.strings.cancel) { LibraryUpdateJob.stop(context) lifecycleScope.launchUI { NotificationReceiver.dismissNotification( @@ -960,8 +966,8 @@ open class MainActivity : BaseActivity() { this, TapTarget.forView( recentsItem, - getString(R.string.manage_whats_downloading), - getString(R.string.visit_recents_for_download_queue), + getString(MR.strings.manage_whats_downloading), + getString(MR.strings.visit_recents_for_download_queue), ).outerCircleColorInt(getResourceColor(R.attr.colorSecondary)).outerCircleAlpha(0.95f) .titleTextSize( 20, @@ -1520,16 +1526,16 @@ open class MainActivity : BaseActivity() { listOf( MaterialMenuSheet.MenuSheetItem( 0, - textRes = R.string.whats_new_this_release, + textRes = MR.strings.whats_new_this_release, drawable = R.drawable.ic_new_releases_24dp, ), MaterialMenuSheet.MenuSheetItem( 1, - textRes = R.string.close, + textRes = MR.strings.close, drawable = R.drawable.ic_close_24dp, ), ), - title = getString(R.string.updated_to_, BuildConfig.VERSION_NAME), + title = getString(MR.strings.updated_to_, BuildConfig.VERSION_NAME), showDivider = true, selectedId = 0, onMenuItemClicked = { _, item -> @@ -1650,7 +1656,7 @@ interface SearchControllerInterface : FloatingSearchInterface, SmallToolbarInter interface FloatingSearchInterface { fun searchTitle(title: String?): String? { if (this is Controller) { - return activity?.getString(R.string.search_, title) + return activity?.getString(MR.strings.search_, title ?: "") } return title } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/main/SearchActivity.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/main/SearchActivity.kt index 994ced682e..c529b7c4d5 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/main/SearchActivity.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/main/SearchActivity.kt @@ -9,6 +9,9 @@ import com.bluelinelabs.conductor.Controller import com.bluelinelabs.conductor.RouterTransaction import com.bluelinelabs.conductor.changehandler.SimpleSwapChangeHandler import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.database.DatabaseHelper import eu.kanade.tachiyomi.data.notification.NotificationReceiver import eu.kanade.tachiyomi.ui.base.SmallToolbarInterface diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/manga/EditMangaDialog.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/manga/EditMangaDialog.kt index 15b090fc29..5db32e3a2f 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/manga/EditMangaDialog.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/manga/EditMangaDialog.kt @@ -35,10 +35,13 @@ import eu.kanade.tachiyomi.util.system.dpToPx import eu.kanade.tachiyomi.util.system.getResourceColor import eu.kanade.tachiyomi.util.system.isInNightMode import eu.kanade.tachiyomi.util.system.materialAlertDialog +import eu.kanade.tachiyomi.util.view.setPositiveButton import eu.kanade.tachiyomi.widget.TachiyomiTextInputEditText import uy.kohesive.injekt.Injekt import uy.kohesive.injekt.api.get import uy.kohesive.injekt.injectLazy +import yokai.i18n.MR +import yokai.util.lang.getString import android.R as AR class EditMangaDialog : DialogController { @@ -76,7 +79,7 @@ class EditMangaDialog : DialogController { val dialog = activity!!.materialAlertDialog().apply { setView(binding.root) setNegativeButton(AR.string.cancel, null) - setPositiveButton(R.string.save) { _, _ -> onPositiveButtonClick() } + setPositiveButton(MR.strings.save) { _, _ -> onPositiveButtonClick() } } onViewCreated() val updateScrollIndicators = { @@ -92,6 +95,8 @@ class EditMangaDialog : DialogController { } fun onViewCreated() { + val context = binding.root.context + binding.mangaCover.loadManga(manga) val isLocal = manga.isLocal() @@ -100,7 +105,7 @@ class EditMangaDialog : DialogController { if (manga.title != manga.url) { binding.title.append(manga.title) } - binding.title.hint = "${resources?.getString(R.string.title)}: ${manga.url}" + binding.title.hint = "${context.getString(MR.strings.title)}: ${manga.url}" binding.mangaAuthor.append(manga.author ?: "") binding.mangaArtist.append(manga.artist ?: "") binding.mangaDescription.append(manga.description ?: "") @@ -145,16 +150,16 @@ class EditMangaDialog : DialogController { binding.mangaAuthor.appendOriginalTextOnLongClick(manga.originalAuthor) binding.mangaArtist.appendOriginalTextOnLongClick(manga.originalArtist) binding.mangaDescription.appendOriginalTextOnLongClick(manga.originalDescription) - binding.title.hint = "${resources?.getString(R.string.title)}: ${manga.originalTitle}" + binding.title.hint = "${context.getString(MR.strings.title)}: ${manga.originalTitle}" if (manga.originalAuthor != null) { - binding.mangaAuthor.hint = "${resources?.getString(R.string.author)}: ${manga.originalAuthor}" + binding.mangaAuthor.hint = "${context.getString(MR.strings.author)}: ${manga.originalAuthor}" } if (manga.originalArtist != null) { - binding.mangaArtist.hint = "${resources?.getString(R.string.artist)}: ${manga.originalArtist}" + binding.mangaArtist.hint = "${context.getString(MR.strings.artist)}: ${manga.originalArtist}" } if (manga.originalDescription != null) { binding.mangaDescription.hint = - "${resources?.getString(R.string.description)}: ${manga.originalDescription?.replace( + "${context.getString(MR.strings.description)}: ${manga.originalDescription?.replace( "\n", " ", )?.chop(20)}" @@ -181,11 +186,11 @@ class EditMangaDialog : DialogController { infoController.changeCover() } binding.resetTags.setOnClickListener { resetTags() } - binding.resetTags.text = resources?.getString( + binding.resetTags.text = context.getString( if (manga.originalGenre.isNullOrBlank() || isLocal) { - R.string.clear_tags + MR.strings.clear_tags } else { - R.string.reset_tags + MR.strings.reset_tags }, ) binding.addTagChip.setOnClickListener { diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/manga/FullCoverDialog.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/manga/FullCoverDialog.kt index 9728a80de3..468f9c670f 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/manga/FullCoverDialog.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/manga/FullCoverDialog.kt @@ -35,6 +35,9 @@ import androidx.transition.TransitionManager import androidx.transition.TransitionSet import com.google.android.material.shape.CornerFamily import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.preference.PreferencesHelper import eu.kanade.tachiyomi.databinding.FullCoverDialogBinding import eu.kanade.tachiyomi.util.system.dpToPx diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/manga/MangaDetailsAdapter.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/manga/MangaDetailsAdapter.kt index a87647d863..0b95234433 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/manga/MangaDetailsAdapter.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/manga/MangaDetailsAdapter.kt @@ -4,8 +4,12 @@ import android.view.ActionMode import android.view.View import android.widget.TextView import androidx.recyclerview.widget.ItemTouchHelper +import dev.icerock.moko.resources.StringResource import eu.davidea.flexibleadapter.items.IFlexible import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.preference.PreferencesHelper import eu.kanade.tachiyomi.ui.manga.chapter.BaseChapterAdapter import eu.kanade.tachiyomi.ui.manga.chapter.ChapterItem @@ -78,16 +82,16 @@ class MangaDetailsAdapter( override fun onCreateBubbleText(position: Int): String { val chapter = - getItem(position) as? ChapterItem ?: return recyclerView.context.getString(R.string.top) + getItem(position) as? ChapterItem ?: return recyclerView.context.getString(MR.strings.top) return when (val scrollType = presenter.scrollType) { MangaDetailsPresenter.MULTIPLE_VOLUMES, MangaDetailsPresenter.MULTIPLE_SEASONS -> { val volume = ChapterUtil.getGroupNumber(chapter) if (volume != null) { recyclerView.context.getString( if (scrollType == MangaDetailsPresenter.MULTIPLE_SEASONS) { - R.string.season_ + MR.strings.season_ } else { - R.string.volume_ + MR.strings.volume_ }, volume, ) @@ -96,7 +100,7 @@ class MangaDetailsAdapter( } } MangaDetailsPresenter.TENS_OF_CHAPTERS -> recyclerView.context.getString( - R.string.chapters_, + MR.strings.chapters_, get10sRange(chapter.chapter_number), ) else -> getChapterName(chapter) @@ -106,7 +110,7 @@ class MangaDetailsAdapter( private fun getChapterName(item: ChapterItem): String { return if (item.chapter_number > 0) { recyclerView.context.getString( - R.string.chapter_, + MR.strings.chapter_, decimalFormat.format(item.chapter_number), ) } else { @@ -138,6 +142,7 @@ class MangaDetailsAdapter( fun showFloatingActionMode(view: TextView, content: String? = null, isTag: Boolean = false) fun showChapterFilter() fun favoriteManga(longPress: Boolean) + fun copyContentToClipboard(content: String, label: StringResource, useToast: Boolean = false) fun copyContentToClipboard(content: String, label: Int, useToast: Boolean = false) fun customActionMode(view: TextView): ActionMode.Callback fun copyContentToClipboard(content: String, label: String?, useToast: Boolean = false) diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/manga/MangaDetailsController.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/manga/MangaDetailsController.kt index 50119916d8..4422ec6f65 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/manga/MangaDetailsController.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/manga/MangaDetailsController.kt @@ -51,9 +51,13 @@ import com.bluelinelabs.conductor.ControllerChangeType import com.google.android.material.chip.Chip import com.google.android.material.snackbar.BaseTransientBottomBar import com.google.android.material.snackbar.Snackbar +import dev.icerock.moko.resources.StringResource import eu.davidea.flexibleadapter.FlexibleAdapter import eu.davidea.flexibleadapter.SelectableAdapter import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.coil.getBestColor import eu.kanade.tachiyomi.data.database.DatabaseHelper import eu.kanade.tachiyomi.data.database.models.Category @@ -122,7 +126,11 @@ import eu.kanade.tachiyomi.util.view.getText import eu.kanade.tachiyomi.util.view.isControllerVisible import eu.kanade.tachiyomi.util.view.previousController import eu.kanade.tachiyomi.util.view.scrollViewWith +import eu.kanade.tachiyomi.util.view.setAction +import eu.kanade.tachiyomi.util.view.setMessage +import eu.kanade.tachiyomi.util.view.setNegativeButton import eu.kanade.tachiyomi.util.view.setOnQueryTextChangeListener +import eu.kanade.tachiyomi.util.view.setPositiveButton import eu.kanade.tachiyomi.util.view.setStyle import eu.kanade.tachiyomi.util.view.setTextColorAlpha import eu.kanade.tachiyomi.util.view.snack @@ -726,7 +734,7 @@ class MangaDetailsController : fun isNotOnline(showSnackbar: Boolean = true): Boolean { if (activity == null || !activity!!.isOnline()) { - if (showSnackbar) view?.snack(R.string.no_network_connection) + if (showSnackbar) view?.snack(MR.strings.no_network_connection) return true } return false @@ -750,15 +758,15 @@ class MangaDetailsController : val chapterNames = deletedChapters.map { it.name } context.materialAlertDialog() .setCustomTitleAndMessage( - R.string.chapters_removed, - context.resources.getQuantityString( - R.plurals.deleted_chapters, + MR.strings.chapters_removed, + context.getString( + MR.plurals.deleted_chapters, deletedChapters.size, deletedChapters.size, if (deletedChapters.size > 5) { "${chapterNames.take(5 - 1).joinToString(", ")}, " + - context.resources.getQuantityString( - R.plurals.notification_and_n_more, + context.getString( + MR.plurals.notification_and_n_more, (chapterNames.size - (4 - 1)), (chapterNames.size - (4 - 1)), ) @@ -767,15 +775,15 @@ class MangaDetailsController : }, ), ) - .setPositiveButton(R.string.delete) { dialog, _ -> + .addCheckBoxPrompt(MR.strings.remember_this_choice) + .setPositiveButton(MR.strings.delete) { dialog, _ -> presenter.deleteChapters(deletedChapters, false) if (dialog.isPromptChecked) deleteRemovedPref.set(2) } - .setNegativeButton(R.string.keep) { dialog, _ -> + .setNegativeButton(MR.strings.keep) { dialog, _ -> if (dialog.isPromptChecked) deleteRemovedPref.set(1) } .setCancelable(false) - .addCheckBoxPrompt(R.string.remember_this_choice) .show() } } @@ -898,22 +906,22 @@ class MangaDetailsController : MaterialMenuSheet.MenuSheetItem( 0, if (descending) R.drawable.ic_eye_down_24dp else R.drawable.ic_eye_up_24dp, - R.string.mark_previous_as_read, + MR.strings.mark_previous_as_read, ), MaterialMenuSheet.MenuSheetItem( 1, if (descending) R.drawable.ic_eye_off_down_24dp else R.drawable.ic_eye_off_up_24dp, - R.string.mark_previous_as_unread, + MR.strings.mark_previous_as_unread, ), MaterialMenuSheet.MenuSheetItem( 2, R.drawable.ic_eye_range_24dp, - R.string.mark_range_as_read, + MR.strings.mark_range_as_read, ), MaterialMenuSheet.MenuSheetItem( 3, R.drawable.ic_eye_off_range_24dp, - R.string.mark_range_as_unread, + MR.strings.mark_range_as_unread, ), ) if (presenter.getChapterUrl(item.chapter) != null) { @@ -922,12 +930,12 @@ class MangaDetailsController : MaterialMenuSheet.MenuSheetItem( 4, R.drawable.ic_open_in_webview_24dp, - R.string.open_in_webview, + MR.strings.open_in_webview, ), ) } val lastRead = presenter.allHistory.find { it.chapter_id == item.id }?.let { - activity?.timeSpanFromNow(R.string.read_, it.last_read) + "\n" + activity?.timeSpanFromNow(MR.strings.read_, it.last_read) + "\n" } val menuSheet = MaterialMenuSheet(activity!!, items, item.name, subtitle = lastRead) { _, itemPos -> @@ -982,13 +990,13 @@ class MangaDetailsController : snack?.dismiss() snack = view?.snack( if (bookmarked) { - R.string.removed_bookmark + MR.strings.removed_bookmark } else { - R.string.bookmarked + MR.strings.bookmarked }, Snackbar.LENGTH_INDEFINITE, ) { - setAction(R.string.undo) { + setAction(MR.strings.undo) { bookmarkChapters(listOf(item), bookmarked) } } @@ -1007,14 +1015,14 @@ class MangaDetailsController : snack?.dismiss() snack = view?.snack( if (read) { - R.string.marked_as_unread + MR.strings.marked_as_unread } else { - R.string.marked_as_read + MR.strings.marked_as_read }, Snackbar.LENGTH_INDEFINITE, ) { var undoing = false - setAction(R.string.undo) { + setAction(MR.strings.undo) { presenter.markChaptersRead(listOf(item), read, true, lastRead, pagesLeft) undoing = true } @@ -1078,17 +1086,17 @@ class MangaDetailsController : colorToolbar(binding.recycler.canScrollVertically(-1)) updateMenuVisibility(menu) menu.findItem(R.id.action_migrate).title = view?.context?.getString( - R.string.migrate_, + MR.strings.migrate_, presenter.manga.seriesType(view!!.context), ) menu.findItem(R.id.download_next).title = - view?.resources?.getQuantityString(R.plurals.next_unread_chapters, 1, 1) + view?.context?.getString(MR.plurals.next_unread_chapters, 1, 1) menu.findItem(R.id.download_next_5).title = - view?.resources?.getQuantityString(R.plurals.next_unread_chapters, 5, 5) + view?.context?.getString(MR.plurals.next_unread_chapters, 5, 5) val searchItem = menu.findItem(R.id.action_search) val searchView = searchItem.actionView as SearchView - searchView.queryHint = resources?.getString(R.string.search_chapters) + searchView.queryHint = activity?.getString(MR.strings.search_chapters) if (query.isNotEmpty() && (!searchItem.isActionViewExpanded || searchView.query != query)) { searchItem.expandActionView() setSearchViewListener(searchView) @@ -1158,8 +1166,8 @@ class MangaDetailsController : } R.id.action_mark_all_as_read -> { activity!!.materialAlertDialog() - .setMessage(R.string.mark_all_chapters_as_read) - .setPositiveButton(R.string.mark_as_read) { _, _ -> + .setMessage(MR.strings.mark_all_chapters_as_read) + .setPositiveButton(MR.strings.mark_as_read) { _, _ -> markAsRead(presenter.chapters) } .setNegativeButton(AR.string.cancel, null) @@ -1168,8 +1176,8 @@ class MangaDetailsController : R.id.remove_all, R.id.remove_read, R.id.remove_non_bookmarked, R.id.remove_custom -> massDeleteChapters(item.itemId) R.id.action_mark_all_as_unread -> { activity!!.materialAlertDialog() - .setMessage(R.string.mark_all_chapters_as_unread) - .setPositiveButton(R.string.mark_as_unread) { _, _ -> + .setMessage(MR.strings.mark_all_chapters_as_unread) + .setPositiveButton(MR.strings.mark_as_unread) { _, _ -> markAsUnread(presenter.chapters) } .setNegativeButton(AR.string.cancel, null) @@ -1186,9 +1194,9 @@ class MangaDetailsController : fun saveCover() { if (presenter.saveCover()) { - activity?.toast(R.string.cover_saved) + activity?.toast(MR.strings.cover_saved) } else { - activity?.toast(R.string.error_saving_cover) + activity?.toast(MR.strings.error_saving_cover) } } @@ -1202,9 +1210,9 @@ class MangaDetailsController : clipData = ClipData.newRawUri(null, stream) type = "image/*" } - startActivity(Intent.createChooser(intent, activity?.getString(R.string.share))) + startActivity(Intent.createChooser(intent, activity?.getString(MR.strings.share))) } else { - activity?.toast(R.string.error_sharing_cover) + activity?.toast(MR.strings.error_sharing_cover) } } @@ -1233,7 +1241,7 @@ class MangaDetailsController : } } startActivity( - Intent.createChooser(intent, context.getString(R.string.share)).apply { + Intent.createChooser(intent, context.getString(MR.strings.share)).apply { if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.UPSIDE_DOWN_CAKE && stream != null) { val shareCoverIntent = Intent(Intent.ACTION_SEND).apply { putExtra(Intent.EXTRA_STREAM, stream) @@ -1244,12 +1252,12 @@ class MangaDetailsController : val pendingIntent = PendingIntent.getActivity( context, manga?.id?.hashCode() ?: 0, - Intent.createChooser(shareCoverIntent, context.getString(R.string.share)), + Intent.createChooser(shareCoverIntent, context.getString(MR.strings.share)), PendingIntent.FLAG_IMMUTABLE, ) val action = ChooserAction.Builder( Icon.createWithResource(context, R.drawable.ic_photo_24dp), - context.getString(R.string.share_cover), + context.getString(MR.strings.share_cover), pendingIntent, ).build() putExtra(Intent.EXTRA_CHOOSER_CUSTOM_ACTIONS, arrayOf(action)) @@ -1313,7 +1321,7 @@ class MangaDetailsController : massDeleteChapters(chaptersToDelete, choice == R.id.remove_all) } else { snack?.dismiss() - snack = view?.snack(R.string.no_chapters_to_delete) + snack = view?.snack(MR.strings.no_chapters_to_delete) } } @@ -1322,16 +1330,16 @@ class MangaDetailsController : context.materialAlertDialog() .setMessage( if (isEverything) { - context.getString(R.string.remove_all_downloads) + context.getString(MR.strings.remove_all_downloads) } else { - context.resources.getQuantityString( - R.plurals.remove_n_chapters, + context.getString( + MR.plurals.remove_n_chapters, chapters.size, chapters.size, ) }, ) - .setPositiveButton(R.string.remove) { _, _ -> + .setPositiveButton(MR.strings.remove) { _, _ -> presenter.deleteChapters(chapters, isEverything = isEverything) } .setNegativeButton(AR.string.cancel, null) @@ -1415,7 +1423,7 @@ class MangaDetailsController : val view = view ?: return presenter.downloadChapters(chapters) val text = view.context.getString( - R.string.add_x_to_library, + MR.strings.add_x_to_library, presenter.manga.seriesType(view.context).lowercase(Locale.ROOT), ) if (!presenter.manga.favorite && ( @@ -1424,7 +1432,7 @@ class MangaDetailsController : ) ) { snack = view.snack(text, Snackbar.LENGTH_INDEFINITE) { - setAction(R.string.add) { + setAction(MR.strings.add) { if (!presenter.manga.favorite) { toggleMangaFavorite() } @@ -1468,9 +1476,9 @@ class MangaDetailsController : if (item != null) { openChapter(item.chapter, readingButton) } else if (snack == null || - snack?.getText() != view?.context?.getString(R.string.next_chapter_not_found) + snack?.getText() != view?.context?.getString(MR.strings.next_chapter_not_found) ) { - snack = view?.snack(R.string.next_chapter_not_found, Snackbar.LENGTH_LONG) { + snack = view?.snack(MR.strings.next_chapter_not_found, Snackbar.LENGTH_LONG) { addCallback( object : BaseTransientBottomBar.BaseCallback() { override fun onDismissed(transientBottomBar: Snackbar?, event: Int) { @@ -1610,9 +1618,9 @@ class MangaDetailsController : private fun makeFavPopup(popupView: View, categories: List): PopupMenu? { val view = view ?: return null val popup = PopupMenu(view.context, popupView) - popup.menu.add(0, 1, 0, R.string.remove_from_library) + popup.menu.add(0, 1, 0, view.context.getString(MR.strings.remove_from_library)) if (categories.isNotEmpty()) { - popup.menu.add(0, 0, 1, R.string.edit_categories) + popup.menu.add(0, 0, 1, view.context.getString(MR.strings.edit_categories)) } // Set a listener so we are notified if a menu item is clicked @@ -1670,11 +1678,23 @@ class MangaDetailsController : private fun showAddedSnack() { val view = view ?: return snack?.dismiss() - snack = view.snack(view.context.getString(R.string.added_to_library)) + snack = view.snack(view.context.getString(MR.strings.added_to_library)) } override fun mangaPresenter(): MangaDetailsPresenter = presenter + /** + * Copies a string to clipboard + * + * @param content the actual text to copy to the board + * @param label Label to show to the user describing the content + */ + override fun copyContentToClipboard(content: String, label: StringResource, useToast: Boolean) { + val view = view ?: return + val contentType = if (label.resourceId != 0) view.context.getString(label) else null + copyContentToClipboard(content, contentType, useToast) + } + /** * Copies a string to clipboard * @@ -1764,9 +1784,9 @@ class MangaDetailsController : override fun onPrepareActionMode(mode: ActionMode?, menu: Menu?): Boolean { mode?.title = view?.context?.getString( if (startingRangeChapterPos == null) { - R.string.select_starting_chapter + MR.strings.select_starting_chapter } else { - R.string.select_ending_chapter + MR.strings.select_ending_chapter }, ) return false @@ -1798,12 +1818,12 @@ class MangaDetailsController : startActivityForResult( Intent.createChooser( intent, - resources?.getString(R.string.select_cover_image), + activity?.getString(MR.strings.select_cover_image), ), 101, ) } else { - activity?.toast(R.string.must_be_in_library_to_edit) + activity?.toast(MR.strings.must_be_in_library_to_edit) } } @@ -1819,7 +1839,7 @@ class MangaDetailsController : presenter.editCoverWithStream(uri) } } catch (error: IOException) { - activity.toast(R.string.failed_to_update_cover) + activity.toast(MR.strings.failed_to_update_cover) Logger.e(error) } } @@ -1895,16 +1915,16 @@ class MangaDetailsController : val context = view?.context ?: return false val localItem = menu?.findItem(R.id.action_local_search) ?: return true localItem.isVisible = previousController !is FilteredLibraryController - val library = context.getString(R.string.library).lowercase(Locale.getDefault()) - localItem.title = context.getString(R.string.search_, library) - sourceMenuItem?.title = context.getString(R.string.search_, presenter.source.name) + val library = context.getString(MR.strings.library).lowercase(Locale.getDefault()) + localItem.title = context.getString(MR.strings.search_, library) + sourceMenuItem?.title = context.getString(MR.strings.search_, presenter.source.name) menu.findItem(R.id.action_search_author)?.title = context.getString( - R.string.search_, - context.getString(R.string.author).lowercase(Locale.getDefault()), + MR.strings.search_, + context.getString(MR.strings.author).lowercase(Locale.getDefault()), ) menu.findItem(R.id.action_search_artist)?.title = context.getString( - R.string.search_, - context.getString(R.string.artist).lowercase(Locale.getDefault()), + MR.strings.search_, + context.getString(MR.strings.artist).lowercase(Locale.getDefault()), ) if (isTag) { if (previousController is BrowseSourceController) { diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/manga/MangaDetailsPresenter.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/manga/MangaDetailsPresenter.kt index 44977b8df2..0d73501253 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/manga/MangaDetailsPresenter.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/manga/MangaDetailsPresenter.kt @@ -10,8 +10,12 @@ import coil3.request.CachePolicy import coil3.request.ImageRequest import coil3.request.SuccessResult import com.hippo.unifile.UniFile +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.BuildConfig import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.cache.CoverCache import eu.kanade.tachiyomi.data.database.DatabaseHelper import eu.kanade.tachiyomi.data.database.models.Category @@ -497,7 +501,7 @@ class MangaDetailsPresenter( } else { e.message } - ) ?: view?.view?.context?.getString(R.string.unknown_error) ?: "" + ) ?: view?.view?.context?.getString(MR.strings.unknown_error) ?: "" } /** @@ -678,14 +682,14 @@ class MangaDetailsPresenter( private fun isScanlatorFiltered() = manga.filtered_scanlators?.isNotEmpty() == true fun currentFilters(): String { - val filtersId = mutableListOf() - filtersId.add(if (manga.readFilter(preferences) == Manga.CHAPTER_SHOW_READ) R.string.read else null) - filtersId.add(if (manga.readFilter(preferences) == Manga.CHAPTER_SHOW_UNREAD) R.string.unread else null) - filtersId.add(if (manga.downloadedFilter(preferences) == Manga.CHAPTER_SHOW_DOWNLOADED) R.string.downloaded else null) - filtersId.add(if (manga.downloadedFilter(preferences) == Manga.CHAPTER_SHOW_NOT_DOWNLOADED) R.string.not_downloaded else null) - filtersId.add(if (manga.bookmarkedFilter(preferences) == Manga.CHAPTER_SHOW_BOOKMARKED) R.string.bookmarked else null) - filtersId.add(if (manga.bookmarkedFilter(preferences) == Manga.CHAPTER_SHOW_NOT_BOOKMARKED) R.string.not_bookmarked else null) - filtersId.add(if (isScanlatorFiltered()) R.string.scanlators else null) + val filtersId = mutableListOf() + filtersId.add(if (manga.readFilter(preferences) == Manga.CHAPTER_SHOW_READ) MR.strings.read else null) + filtersId.add(if (manga.readFilter(preferences) == Manga.CHAPTER_SHOW_UNREAD) MR.strings.unread else null) + filtersId.add(if (manga.downloadedFilter(preferences) == Manga.CHAPTER_SHOW_DOWNLOADED) MR.strings.downloaded else null) + filtersId.add(if (manga.downloadedFilter(preferences) == Manga.CHAPTER_SHOW_NOT_DOWNLOADED) MR.strings.not_downloaded else null) + filtersId.add(if (manga.bookmarkedFilter(preferences) == Manga.CHAPTER_SHOW_BOOKMARKED) MR.strings.bookmarked else null) + filtersId.add(if (manga.bookmarkedFilter(preferences) == Manga.CHAPTER_SHOW_NOT_BOOKMARKED) MR.strings.not_bookmarked else null) + filtersId.add(if (isScanlatorFiltered()) MR.strings.scanlators else null) return filtersId.filterNotNull() .joinToString(", ") { view?.view?.context?.getString(it) ?: "" } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/manga/MangaHeaderHolder.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/manga/MangaHeaderHolder.kt index 505ea780a9..2327538327 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/manga/MangaHeaderHolder.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/manga/MangaHeaderHolder.kt @@ -31,6 +31,9 @@ import coil3.request.placeholder import com.google.android.material.button.MaterialButton import com.google.android.material.chip.Chip import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.coil.loadManga import eu.kanade.tachiyomi.data.database.models.Manga import eu.kanade.tachiyomi.databinding.ChapterHeaderItemBinding @@ -143,7 +146,7 @@ class MangaHeaderHolder( } title.setOnLongClickListener { title.text?.toString()?.toNormalized()?.let { - adapter.delegate.copyContentToClipboard(it, R.string.title) + adapter.delegate.copyContentToClipboard(it, MR.strings.title) } true } @@ -154,7 +157,7 @@ class MangaHeaderHolder( } mangaAuthor.setOnLongClickListener { mangaAuthor.text?.toString()?.let { - adapter.delegate.copyContentToClipboard(it, R.string.author) + adapter.delegate.copyContentToClipboard(it, MR.strings.author) } true } @@ -266,7 +269,7 @@ class MangaHeaderHolder( if (binding != null) { val desc = adapter.controller.mangaPresenter().manga.description binding.mangaSummary.text = when { - desc.isNullOrBlank() -> itemView.context.getString(R.string.no_description) + desc.isNullOrBlank() -> itemView.context.getString(MR.strings.no_description) binding.mangaSummary.maxLines != Int.MAX_VALUE -> desc.replace( Regex( "[\\r\\n\\s*]{2,}", @@ -284,11 +287,11 @@ class MangaHeaderHolder( val count = presenter.chapters.size if (binding != null) { binding.chaptersTitle.text = - itemView.resources.getQuantityString(R.plurals.chapters_plural, count, count) + itemView.context.getString(MR.plurals.chapters_plural, count, count) binding.filtersText.text = presenter.currentFilters() } else if (chapterBinding != null) { chapterBinding.chaptersTitle.text = - itemView.resources.getQuantityString(R.plurals.chapters_plural, count, count) + itemView.context.getString(MR.plurals.chapters_plural, count, count) chapterBinding.filtersText.text = presenter.currentFilters() } } @@ -300,7 +303,7 @@ class MangaHeaderHolder( if (chapterBinding != null) { val count = presenter.chapters.size chapterBinding.chaptersTitle.text = - itemView.resources.getQuantityString(R.plurals.chapters_plural, count, count) + itemView.context.getString(MR.plurals.chapters_plural, count, count) chapterBinding.filtersText.text = presenter.currentFilters() if (adapter.preferences.themeMangaDetails().get()) { val accentColor = adapter.delegate.accentColor() ?: return @@ -338,7 +341,7 @@ class MangaHeaderHolder( } } binding.mangaSummaryLabel.text = itemView.context.getString( - R.string.about_this_, + MR.strings.about_this_, manga.seriesType(itemView.context), ) with(binding.favoriteButton) { @@ -350,11 +353,11 @@ class MangaHeaderHolder( else -> R.drawable.ic_heart_outline_24dp }, ) - text = itemView.resources.getString( + text = itemView.context.getString( when { - item.isLocked -> R.string.unlock - manga.favorite -> R.string.in_library - else -> R.string.add_to_library + item.isLocked -> MR.strings.unlock + manga.favorite -> MR.strings.in_library + else -> MR.strings.add_to_library }, ) checked(!item.isLocked && manga.favorite) @@ -371,9 +374,9 @@ class MangaHeaderHolder( isVisible = presenter.hasTrackers() text = itemView.context.getString( if (tracked) { - R.string.tracked + MR.strings.tracked } else { - R.string.tracking + MR.strings.tracking }, ) @@ -392,30 +395,30 @@ class MangaHeaderHolder( text = if (nextChapter != null) { val number = adapter.decimalFormat.format(nextChapter.chapter_number.toDouble()) if (nextChapter.chapter_number > 0) { - resources.getString( + context.getString( if (nextChapter.last_page_read > 0) { - R.string.continue_reading_chapter_ + MR.strings.continue_reading_chapter_ } else { - R.string.start_reading_chapter_ + MR.strings.start_reading_chapter_ }, number, ) } else { - resources.getString( + context.getString( if (nextChapter.last_page_read > 0) { - R.string.continue_reading + MR.strings.continue_reading } else { - R.string.start_reading + MR.strings.start_reading }, ) } } else { - resources.getString(R.string.all_chapters_read) + context.getString(MR.strings.all_chapters_read) } } val count = presenter.chapters.size - binding.chaptersTitle.text = itemView.resources.getQuantityString(R.plurals.chapters_plural, count, count) + binding.chaptersTitle.text = itemView.context.getString(MR.plurals.chapters_plural, count, count) binding.topView.updateLayoutParams { height = adapter.delegate.topCoverHeight() @@ -425,13 +428,13 @@ class MangaHeaderHolder( binding.mangaStatus.text = ( itemView.context.getString( when (manga.status) { - SManga.ONGOING -> R.string.ongoing - SManga.COMPLETED -> R.string.completed - SManga.LICENSED -> R.string.licensed - SManga.PUBLISHING_FINISHED -> R.string.publishing_finished - SManga.CANCELLED -> R.string.cancelled - SManga.ON_HIATUS -> R.string.on_hiatus - else -> R.string.unknown_status + SManga.ONGOING -> MR.strings.ongoing + SManga.COMPLETED -> MR.strings.completed + SManga.LICENSED -> MR.strings.licensed + SManga.PUBLISHING_FINISHED -> MR.strings.publishing_finished + SManga.CANCELLED -> MR.strings.cancelled + SManga.ON_HIATUS -> MR.strings.on_hiatus + else -> MR.strings.unknown_status }, ) ) @@ -444,7 +447,7 @@ class MangaHeaderHolder( presenter.source.name != presenter.source.id.toString() ) { scale(0.9f) { - append(" (${context.getString(R.string.source_not_installed)})") + append(" (${context.getString(MR.strings.source_not_installed)})") } } } @@ -630,9 +633,9 @@ class MangaHeaderHolder( with(binding.trackButton) { text = itemView.context.getString( if (tracked) { - R.string.tracked + MR.strings.tracked } else { - R.string.tracking + MR.strings.tracking }, ) diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/manga/MangaHeaderItem.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/manga/MangaHeaderItem.kt index e1cc09fddf..349e8ebf7f 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/manga/MangaHeaderItem.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/manga/MangaHeaderItem.kt @@ -6,6 +6,9 @@ import eu.davidea.flexibleadapter.FlexibleAdapter import eu.davidea.flexibleadapter.items.AbstractFlexibleItem import eu.davidea.flexibleadapter.items.IFlexible import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.database.models.Manga class MangaHeaderItem(val manga: Manga, var startExpanded: Boolean) : diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/manga/chapter/BaseChapterHolder.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/manga/chapter/BaseChapterHolder.kt index c7db39c0eb..c215591b4c 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/manga/chapter/BaseChapterHolder.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/manga/chapter/BaseChapterHolder.kt @@ -6,6 +6,8 @@ import eu.kanade.tachiyomi.R import eu.kanade.tachiyomi.data.database.models.Chapter import eu.kanade.tachiyomi.data.download.model.Download import eu.kanade.tachiyomi.ui.base.holder.BaseFlexibleViewHolder +import yokai.i18n.MR +import yokai.util.lang.getString open class BaseChapterHolder( view: View, @@ -40,7 +42,7 @@ open class BaseChapterHolder( // Hide download and show delete if the chapter is downloaded if (chapterStatus != Download.State.DOWNLOADED) { popup.menu.findItem(R.id.action_delete).title = downloadButton.context.getString( - R.string.cancel, + MR.strings.cancel, ) } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/manga/chapter/ChapterHolder.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/manga/chapter/ChapterHolder.kt index 743a8e322d..144710e688 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/manga/chapter/ChapterHolder.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/manga/chapter/ChapterHolder.kt @@ -18,6 +18,8 @@ import eu.kanade.tachiyomi.util.chapter.ChapterUtil.Companion.preferredChapterNa import eu.kanade.tachiyomi.util.isLocal import eu.kanade.tachiyomi.util.system.dpToPx import eu.kanade.tachiyomi.util.system.getResourceColor +import yokai.i18n.MR +import yokai.util.lang.getString import android.R as AR class ChapterHolder( @@ -55,8 +57,8 @@ class ChapterHolder( if (showPagesLeft && chapter.pages_left > 0) { statuses.add( - itemView.resources.getQuantityString( - R.plurals.pages_left, + itemView.context.getString( + MR.plurals.pages_left, chapter.pages_left, chapter.pages_left, ), @@ -64,7 +66,7 @@ class ChapterHolder( } else if (showPagesLeft) { statuses.add( itemView.context.getString( - R.string.page_, + MR.strings.page_, chapter.last_page_read + 1, ), ) diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/manga/chapter/ChaptersSortBottomSheet.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/manga/chapter/ChaptersSortBottomSheet.kt index 916285a8ae..7e68acb265 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/manga/chapter/ChaptersSortBottomSheet.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/manga/chapter/ChaptersSortBottomSheet.kt @@ -8,7 +8,6 @@ import androidx.core.view.WindowInsetsCompat.Type.systemBars import androidx.core.view.isInvisible import androidx.core.view.isVisible import com.google.android.material.bottomsheet.BottomSheetBehavior -import eu.kanade.tachiyomi.R import eu.kanade.tachiyomi.data.database.models.Manga import eu.kanade.tachiyomi.databinding.ChapterSortBottomSheetBinding import eu.kanade.tachiyomi.ui.manga.MangaDetailsController @@ -19,8 +18,12 @@ import eu.kanade.tachiyomi.util.system.rootWindowInsetsCompat import eu.kanade.tachiyomi.util.system.setNegativeStateItems import eu.kanade.tachiyomi.util.view.checkHeightThen import eu.kanade.tachiyomi.util.view.setBottomEdge +import eu.kanade.tachiyomi.util.view.setNeutralButton +import eu.kanade.tachiyomi.util.view.setPositiveButton +import eu.kanade.tachiyomi.util.view.setTitle import eu.kanade.tachiyomi.widget.E2EBottomSheetDialog import eu.kanade.tachiyomi.widget.SortTextView +import yokai.i18n.MR import kotlin.math.max import android.R as AR @@ -170,7 +173,6 @@ class ChaptersSortBottomSheet(controller: MangaDetailsController) : val preselected = scanlators.map { it in filteredScanlators }.toBooleanArray() var alertDialog: AlertDialog? = null activity.materialAlertDialog() - .setTitle(R.string.filter_groups) .setNegativeStateItems(scanlators, preselected) { _, pos, checked -> if (checked) { filteredScanlators.add(scanlators[pos]) @@ -180,11 +182,12 @@ class ChaptersSortBottomSheet(controller: MangaDetailsController) : alertDialog?.getButton(BUTTON_POSITIVE)?.isEnabled = scanlators.size != filteredScanlators.size } + .setTitle(MR.strings.filter_groups) .setNegativeButton(AR.string.cancel, null) - .setPositiveButton(R.string.filter) { _, _ -> + .setPositiveButton(MR.strings.filter) { _, _ -> presenter.setScanlatorFilter(filteredScanlators) } - .setNeutralButton(R.string.reset) { _, _ -> + .setNeutralButton(MR.strings.reset) { _, _ -> presenter.setScanlatorFilter(emptySet()) } .show().apply { diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/manga/track/TrackAdapter.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/manga/track/TrackAdapter.kt index dd8ae8a84d..d2c21ad66c 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/manga/track/TrackAdapter.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/manga/track/TrackAdapter.kt @@ -4,6 +4,9 @@ import android.view.View import android.view.ViewGroup import androidx.recyclerview.widget.RecyclerView import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.track.TrackService import eu.kanade.tachiyomi.util.view.inflate diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/manga/track/TrackHolder.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/manga/track/TrackHolder.kt index b5c30b6188..2035646dac 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/manga/track/TrackHolder.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/manga/track/TrackHolder.kt @@ -9,11 +9,15 @@ import androidx.core.view.isVisible import androidx.core.view.updateLayoutParams import androidx.core.widget.TextViewCompat import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.database.models.Track import eu.kanade.tachiyomi.data.preference.PreferencesHelper import eu.kanade.tachiyomi.databinding.TrackItemBinding import eu.kanade.tachiyomi.ui.base.holder.BaseViewHolder import eu.kanade.tachiyomi.util.system.getResourceColor +import eu.kanade.tachiyomi.util.view.setText import uy.kohesive.injekt.injectLazy import java.text.DateFormat import android.R as AR @@ -61,25 +65,25 @@ class TrackHolder(view: View, adapter: TrackAdapter) : BaseViewHolder(view) { with(binding.trackChapters) { text = when { track.total_chapters > 0 && track.last_chapter_read.toInt() == track.total_chapters -> context.getString( - R.string.all_chapters_read, + MR.strings.all_chapters_read, ) track.total_chapters > 0 -> context.getString( - R.string.chapter_x_of_y, + MR.strings.chapter_x_of_y, track.last_chapter_read.toInt(), track.total_chapters, ) track.last_chapter_read > 0 -> context.getString( - R.string.chapter_, + MR.strings.chapter_, track.last_chapter_read.toInt().toString(), ) - else -> context.getString(R.string.not_started) + else -> context.getString(MR.strings.not_started) } setTextColor(enabledTextColor(true)) } val status = item.service.getStatus(track.status) with(binding.trackStatus) { if (status.isEmpty()) { - setText(R.string.unknown_status) + setText(MR.strings.unknown_status) } else { text = item.service.getStatus(track.status) } @@ -90,7 +94,7 @@ class TrackHolder(view: View, adapter: TrackAdapter) : BaseViewHolder(view) { with(binding.trackScore) { text = if (track.score == 0f) { - binding.trackScore.context.getString(R.string.score) + binding.trackScore.context.getString(MR.strings.score) } else { item.service.displayScore(track) } @@ -114,7 +118,7 @@ class TrackHolder(view: View, adapter: TrackAdapter) : BaseViewHolder(view) { if (track.started_reading_date != 0L) { dateFormat.format(track.started_reading_date) } else { - context.getString(R.string.started_reading_date) + context.getString(MR.strings.started_reading_date) } setTextColor(enabledTextColor(track.started_reading_date != 0L)) } @@ -123,7 +127,7 @@ class TrackHolder(view: View, adapter: TrackAdapter) : BaseViewHolder(view) { if (track.finished_reading_date != 0L) { dateFormat.format(track.finished_reading_date) } else { - context.getString(R.string.finished_reading_date) + context.getString(MR.strings.finished_reading_date) } setTextColor(enabledTextColor(track.finished_reading_date != 0L)) } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/manga/track/TrackSearchItem.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/manga/track/TrackSearchItem.kt index 102da326bf..e9c1bf2ea4 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/manga/track/TrackSearchItem.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/manga/track/TrackSearchItem.kt @@ -9,6 +9,9 @@ import com.google.android.material.shape.CornerFamily import com.mikepenz.fastadapter.FastAdapter import com.mikepenz.fastadapter.items.AbstractItem import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.track.model.TrackSearch import eu.kanade.tachiyomi.databinding.TrackSearchItemBinding import eu.kanade.tachiyomi.util.system.dpToPx diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/manga/track/TrackingBottomSheet.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/manga/track/TrackingBottomSheet.kt index a4491ff660..59e67a4f5f 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/manga/track/TrackingBottomSheet.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/manga/track/TrackingBottomSheet.kt @@ -32,6 +32,9 @@ import com.mikepenz.fastadapter.FastAdapter import com.mikepenz.fastadapter.adapters.ItemAdapter import com.mikepenz.fastadapter.listeners.addClickListener import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.track.EnhancedTrackService import eu.kanade.tachiyomi.data.track.TrackService import eu.kanade.tachiyomi.data.track.model.TrackSearch @@ -57,6 +60,9 @@ import eu.kanade.tachiyomi.util.system.withUIContext import eu.kanade.tachiyomi.util.view.RecyclerWindowInsetsListener import eu.kanade.tachiyomi.util.view.checkHeightThen import eu.kanade.tachiyomi.util.view.expand +import eu.kanade.tachiyomi.util.view.setPositiveButton +import eu.kanade.tachiyomi.util.view.setTitle +import eu.kanade.tachiyomi.util.view.setTitleText import eu.kanade.tachiyomi.widget.E2EBottomSheetDialog import java.text.DateFormat import java.util.* @@ -222,7 +228,7 @@ class TrackingBottomSheet(private val controller: MangaDetailsController) : } if (!item.service.accept(controller.presenter.source)) { - controller.view?.context?.toast(R.string.source_unsupported) + controller.view?.context?.toast(MR.strings.source_unsupported) return } @@ -231,9 +237,9 @@ class TrackingBottomSheet(private val controller: MangaDetailsController) : item.service.match(controller.presenter.manga)?.let { track -> controller.presenter.registerTracking(track, item.service) } - ?: withUIContext { controller.view?.context?.toast(R.string.no_match_found) } + ?: withUIContext { controller.view?.context?.toast(MR.strings.no_match_found) } } catch (e: Exception) { - withUIContext { controller.view?.context?.toast(R.string.no_match_found) } + withUIContext { controller.view?.context?.toast(MR.strings.no_match_found) } } } } else { @@ -243,7 +249,7 @@ class TrackingBottomSheet(private val controller: MangaDetailsController) : override fun onTitleLongClick(position: Int) { val title = adapter?.getItem(position)?.track?.title ?: return - controller.copyContentToClipboard(title, R.string.title, true) + controller.copyContentToClipboard(title, MR.strings.title, true) } private fun startTransition(duration: Long = 100) { @@ -313,7 +319,7 @@ class TrackingBottomSheet(private val controller: MangaDetailsController) : setMiddleTrackView(binding.searchEmptyView.id) binding.searchEmptyView.show( R.drawable.ic_search_off_24dp, - R.string.no_results_found, + MR.strings.no_results_found, ) } else { setMiddleTrackView(binding.trackSearchRecycler.id) @@ -349,7 +355,7 @@ class TrackingBottomSheet(private val controller: MangaDetailsController) : val newTitle = selectedItem.title val text = activity.getString( - R.string.remove_x_from_service_and_add_y, + MR.strings.remove_x_from_service_and_add_y, ogTitle, activity.getString( searchingItem.service.nameRes(), @@ -366,13 +372,13 @@ class TrackingBottomSheet(private val controller: MangaDetailsController) : } val text2 = activity.getString( - R.string.keep_both_on_service, + MR.strings.keep_both_on_service, activity.getString( searchingItem.service.nameRes(), ), ) activity.materialAlertDialog() - .setTitle(R.string.remove_previous_tracker) + .setTitle(MR.strings.remove_previous_tracker) .setItems(arrayOf(wordToSpan, text2)) { dialog, i -> if (i == 0) { removeTracker(searchingItem, true) @@ -413,7 +419,7 @@ class TrackingBottomSheet(private val controller: MangaDetailsController) : val selectedIndex = statusList.indexOf(item.track.status) activity.materialAlertDialog() - .setTitle(R.string.status) + .setTitle(MR.strings.status) .setNegativeButton(AR.string.cancel, null) .setSingleChoiceItems( statusString.toTypedArray(), @@ -430,7 +436,6 @@ class TrackingBottomSheet(private val controller: MangaDetailsController) : if (item.track == null) return val dialog = activity.materialAlertDialog() - .setTitle(R.string.remove_tracking) .setNegativeButton(AR.string.cancel, null) if (item.service.canRemoveFromService()) { @@ -438,28 +443,29 @@ class TrackingBottomSheet(private val controller: MangaDetailsController) : if (!activity.isOnline()) { dialog.setMessage( activity.getString( - R.string.cannot_remove_tracking_while_offline, + MR.strings.cannot_remove_tracking_while_offline, serviceName, ), ) - .setPositiveButton(R.string.remove) { _, _ -> + .setPositiveButton(MR.strings.remove) { _, _ -> removeTracker(item, false) } } else { dialog.addCheckBoxPrompt( - activity.getString(R.string.remove_tracking_from_, serviceName), + activity.getString(MR.strings.remove_tracking_from_, serviceName), true, ) - .setPositiveButton(R.string.remove) { dialogI, _ -> + .setPositiveButton(MR.strings.remove) { dialogI, _ -> removeTracker(item, dialogI.isPromptChecked) } } } else { - dialog.setPositiveButton(R.string.remove) { _, _ -> + dialog.setPositiveButton(MR.strings.remove) { _, _ -> removeTracker(item, false) } } - dialog.show() + dialog.setTitle(MR.strings.remove_tracking) + .show() } override fun onChaptersClick(position: Int) { @@ -472,7 +478,7 @@ class TrackingBottomSheet(private val controller: MangaDetailsController) : val binding = TrackChaptersDialogBinding.inflate(activity.layoutInflater) val dialog = activity.materialAlertDialog() - .setTitle(R.string.chapters) + .setTitle(MR.strings.chapters) .setView(binding.root) .setNegativeButton(AR.string.cancel, null) .setPositiveButton(AR.string.ok) { _, _ -> @@ -506,7 +512,7 @@ class TrackingBottomSheet(private val controller: MangaDetailsController) : val scores = item.service.getScoreList().toTypedArray() val binding = TrackScoreDialogBinding.inflate(activity.layoutInflater) val dialog = activity.materialAlertDialog() - .setTitle(R.string.score) + .setTitle(MR.strings.score) .setView(binding.root) .setNegativeButton(AR.string.cancel, null) .setPositiveButton(AR.string.ok) { _, _ -> @@ -555,12 +561,12 @@ class TrackingBottomSheet(private val controller: MangaDetailsController) : return } val popup = PopupMenu(activity, view, Gravity.NO_GRAVITY) - popup.menu.add(0, 0, 0, R.string.edit) + popup.menu.add(0, 0, 0, activity.getString(MR.strings.edit)) getSuggestedDate(trackItem, readingDate, suggestedDate)?.let { - val subMenu = popup.menu.addSubMenu(0, 1, 0, R.string.use_suggested_date) + val subMenu = popup.menu.addSubMenu(0, 1, 0, activity.getString(MR.strings.use_suggested_date)) subMenu.add(0, 2, 0, it) } - popup.menu.add(0, 3, 0, R.string.remove) + popup.menu.add(0, 3, 0, activity.getString(MR.strings.remove)) popup.setOnMenuItemClickListener { when (it.itemId) { @@ -583,8 +589,8 @@ class TrackingBottomSheet(private val controller: MangaDetailsController) : val dialog = MaterialDatePicker.Builder.datePicker() .setTitleText( when (readingDate) { - ReadingDate.Start -> R.string.started_reading_date - ReadingDate.Finish -> R.string.finished_reading_date + ReadingDate.Start -> MR.strings.started_reading_date + ReadingDate.Finish -> MR.strings.finished_reading_date }, ) .setSelection(getCurrentDate(trackItem, readingDate, suggestedDate)?.timeInMillis).apply { diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/migration/MangaItem.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/migration/MangaItem.kt index 8f02ad9a71..c01553ebe4 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/migration/MangaItem.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/migration/MangaItem.kt @@ -6,6 +6,9 @@ import eu.davidea.flexibleadapter.FlexibleAdapter import eu.davidea.flexibleadapter.items.AbstractFlexibleItem import eu.davidea.flexibleadapter.items.IFlexible import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.database.models.Manga class MangaItem(val manga: Manga) : AbstractFlexibleItem() { diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/migration/MigrationController.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/migration/MigrationController.kt index 330d8c3fd2..6d8ee5816a 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/migration/MigrationController.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/migration/MigrationController.kt @@ -9,6 +9,9 @@ import androidx.core.view.doOnNextLayout import eu.davidea.flexibleadapter.FlexibleAdapter import eu.davidea.flexibleadapter.items.IFlexible import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.database.DatabaseHelper import eu.kanade.tachiyomi.data.preference.PreferenceValues import eu.kanade.tachiyomi.data.preference.PreferencesHelper @@ -149,7 +152,7 @@ class MigrationController : } override fun setMigrationSources(sources: List) { - title = resources?.getString(R.string.source_migration) + title = activity?.getString(MR.strings.source_migration) if (adapter !is SourceAdapter) { adapter = SourceAdapter(this) binding.migrationRecycler.adapter = adapter diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/migration/MigrationFlags.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/migration/MigrationFlags.kt index 33f10028d0..dba071ae05 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/migration/MigrationFlags.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/migration/MigrationFlags.kt @@ -1,7 +1,11 @@ package eu.kanade.tachiyomi.ui.migration import android.content.Context +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.cache.CoverCache import eu.kanade.tachiyomi.data.database.DatabaseHelper import eu.kanade.tachiyomi.data.database.models.Manga @@ -21,7 +25,7 @@ object MigrationFlags { private val db: DatabaseHelper by injectLazy() private val customMangaManager: CustomMangaManager by injectLazy() - val titles get() = arrayOf(R.string.chapters, R.string.categories, R.string.tracking, R.string.custom_manga_info) + val titles get() = arrayOf(MR.strings.chapters, MR.strings.categories, MR.strings.tracking, MR.strings.custom_manga_info) val flags get() = arrayOf(CHAPTERS, CATEGORIES, TRACK, CUSTOM_MANGA_INFO) fun hasChapters(value: Int): Boolean { @@ -71,13 +75,13 @@ object MigrationFlags { return flags.toTypedArray() } - private fun titleForFlag(flag: Int): Int { + private fun titleForFlag(flag: Int): StringResource { return when (flag) { - CHAPTERS -> R.string.chapters - CATEGORIES -> R.string.categories - TRACK -> R.string.tracking - CUSTOM_MANGA_INFO -> R.string.custom_manga_info - else -> 0 + CHAPTERS -> MR.strings.chapters + CATEGORIES -> MR.strings.categories + TRACK -> MR.strings.tracking + CUSTOM_MANGA_INFO -> MR.strings.custom_manga_info + else -> throw IllegalStateException("Invalid flag") } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/migration/SearchController.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/migration/SearchController.kt index 27dbe21972..e648050363 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/migration/SearchController.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/migration/SearchController.kt @@ -5,6 +5,9 @@ import android.view.Menu import android.view.MenuInflater import androidx.core.os.bundleOf import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.database.DatabaseHelper import eu.kanade.tachiyomi.data.database.models.Manga import eu.kanade.tachiyomi.source.CatalogueSource diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/migration/SelectionHeader.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/migration/SelectionHeader.kt index f0e26d74b8..5f91ff334f 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/migration/SelectionHeader.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/migration/SelectionHeader.kt @@ -6,6 +6,9 @@ import eu.davidea.flexibleadapter.FlexibleAdapter import eu.davidea.flexibleadapter.items.AbstractHeaderItem import eu.davidea.flexibleadapter.items.IFlexible import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.databinding.SourceHeaderItemBinding import eu.kanade.tachiyomi.ui.base.holder.BaseFlexibleViewHolder @@ -43,7 +46,7 @@ class SelectionHeader : AbstractHeaderItem() { class Holder(view: View, adapter: FlexibleAdapter>) : BaseFlexibleViewHolder(view, adapter) { init { val binding = SourceHeaderItemBinding.bind(view) - binding.title.text = view.context.getString(R.string.select_a_source_then_item_to_migrate) + binding.title.text = view.context.getString(MR.strings.select_a_source_then_item_to_migrate) } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/migration/SourceHolder.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/migration/SourceHolder.kt index 59898042dc..cef162f00f 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/migration/SourceHolder.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/migration/SourceHolder.kt @@ -4,6 +4,9 @@ import android.view.View import androidx.core.text.buildSpannedString import androidx.core.text.color import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.databinding.MigrationCardItemBinding import eu.kanade.tachiyomi.source.icon import eu.kanade.tachiyomi.ui.base.holder.BaseFlexibleViewHolder @@ -29,13 +32,13 @@ class SourceHolder(view: View, val adapter: SourceAdapter) : val sourceName = source.name.replaceFirstChar { it.titlecase(Locale.getDefault()) } + " (${item.numberOfItems})" binding.title.text = sourceName binding.lang.text = when { - item.isUninstalled -> itemView.context.getString(R.string.source_not_installed) + item.isUninstalled -> itemView.context.getString(MR.strings.source_not_installed) .withColor(itemView.context.getResourceColor(R.attr.colorError)) item.isObsolete -> buildSpannedString { append(LocaleHelper.getSourceDisplayName(source.lang, itemView.context)) append(" ") color(itemView.context.getResourceColor(R.attr.colorError)) { - append(itemView.context.getString(R.string.obsolete).uppercase()) + append(itemView.context.getString(MR.strings.obsolete).uppercase()) } } else -> LocaleHelper.getSourceDisplayName(source.lang, itemView.context) diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/migration/SourceItem.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/migration/SourceItem.kt index 9758c5ac1c..a9b0d0f5c8 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/migration/SourceItem.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/migration/SourceItem.kt @@ -6,6 +6,9 @@ import eu.davidea.flexibleadapter.FlexibleAdapter import eu.davidea.flexibleadapter.items.AbstractSectionableItem import eu.davidea.flexibleadapter.items.IFlexible import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.source.Source /** diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/migration/manga/design/MigrationBottomSheetDialog.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/migration/manga/design/MigrationBottomSheetDialog.kt index d534ec6198..63f4fdfdf3 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/migration/manga/design/MigrationBottomSheetDialog.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/migration/manga/design/MigrationBottomSheetDialog.kt @@ -19,6 +19,9 @@ import androidx.core.view.isVisible import androidx.core.view.updateLayoutParams import com.bluelinelabs.conductor.Controller import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.core.preference.Preference import eu.kanade.tachiyomi.data.preference.PreferencesHelper import eu.kanade.tachiyomi.databinding.MigrationBottomSheetBinding @@ -130,7 +133,7 @@ class MigrationBottomSheetDialog( binding.skipStep.setOnCheckedChangeListener { _, isChecked -> if (isChecked) { (listener as? Controller)?.activity?.toast( - R.string.to_show_again_setting_sources, + MR.strings.to_show_again_setting_sources, Toast.LENGTH_LONG, ) } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/migration/manga/design/MigrationSourceItem.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/migration/manga/design/MigrationSourceItem.kt index 5bf50f3eb7..aeabf822cd 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/migration/manga/design/MigrationSourceItem.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/migration/manga/design/MigrationSourceItem.kt @@ -7,6 +7,9 @@ import eu.davidea.flexibleadapter.FlexibleAdapter import eu.davidea.flexibleadapter.items.AbstractFlexibleItem import eu.davidea.flexibleadapter.items.IFlexible import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.source.SourceManager import eu.kanade.tachiyomi.source.online.HttpSource import kotlinx.parcelize.Parcelize diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/migration/manga/design/PreMigrationController.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/migration/manga/design/PreMigrationController.kt index 7dfbdbde25..42ea18c78c 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/migration/manga/design/PreMigrationController.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/migration/manga/design/PreMigrationController.kt @@ -18,6 +18,9 @@ import com.google.android.material.bottomsheet.BottomSheetBehavior import com.google.android.material.bottomsheet.BottomSheetDialog import eu.davidea.flexibleadapter.FlexibleAdapter import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.preference.PreferencesHelper import eu.kanade.tachiyomi.databinding.PreMigrationControllerBinding import eu.kanade.tachiyomi.source.SourceManager @@ -48,7 +51,7 @@ class PreMigrationController(bundle: Bundle? = null) : private var dialog: BottomSheetDialog? = null - override fun getTitle() = view?.context?.getString(R.string.select_sources) + override fun getTitle() = view?.context?.getString(MR.strings.select_sources) override fun createBinding(inflater: LayoutInflater) = PreMigrationControllerBinding.inflate(inflater) override fun onViewCreated(view: View) { diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/migration/manga/process/MigrationListController.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/migration/manga/process/MigrationListController.kt index cc4233869a..fdd26005c2 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/migration/manga/process/MigrationListController.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/migration/manga/process/MigrationListController.kt @@ -19,6 +19,9 @@ import androidx.recyclerview.widget.LinearLayoutManager import androidx.vectordrawable.graphics.drawable.VectorDrawableCompat import co.touchlab.kermit.Logger import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.database.DatabaseHelper import eu.kanade.tachiyomi.data.database.models.Manga import eu.kanade.tachiyomi.data.preference.PreferencesHelper @@ -49,7 +52,9 @@ import eu.kanade.tachiyomi.util.view.RecyclerWindowInsetsListener import eu.kanade.tachiyomi.util.view.activityBinding import eu.kanade.tachiyomi.util.view.isControllerVisible import eu.kanade.tachiyomi.util.view.liftAppbarWith +import eu.kanade.tachiyomi.util.view.setPositiveButton import eu.kanade.tachiyomi.util.view.setTextColorAlpha +import eu.kanade.tachiyomi.util.view.setTitle import eu.kanade.tachiyomi.util.view.withFadeTransaction import kotlinx.coroutines.CancellationException import kotlinx.coroutines.CoroutineScope @@ -98,7 +103,7 @@ class MigrationListController(bundle: Bundle? = null) : override fun createBinding(inflater: LayoutInflater) = MigrationListControllerBinding.inflate(inflater) override fun getTitle(): String { val progress = adapter?.items?.count { it.manga.migrationStatus != MigrationStatus.RUNNUNG } - return resources?.getString(R.string.migration) + " ($progress/${adapter?.itemCount})" + return activity?.getString(MR.strings.migration) + " ($progress/${adapter?.itemCount})" } override fun onViewCreated(view: View) { @@ -312,11 +317,10 @@ class MigrationListController(bundle: Bundle? = null) : override fun noMigration() { launchUI { - val res = resources - if (res != null) { - activity?.toast( - res.getQuantityString( - R.plurals.manga_migrated, + if (activity != null) { + activity!!.toast( + activity!!.getString( + MR.plurals.manga_migrated, manaulMigrations, manaulMigrations, ), @@ -394,7 +398,7 @@ class MigrationListController(bundle: Bundle? = null) : adapter?.notifyItemChanged(firstIndex) } else { migratingManga.manga.migrationStatus = MigrationStatus.MANGA_NOT_FOUND - activity?.toast(R.string.no_chapters_found_for_migration, Toast.LENGTH_LONG) + activity?.toast(MR.strings.no_chapters_found_for_migration, Toast.LENGTH_LONG) adapter?.notifyItemChanged(firstIndex) } } @@ -460,8 +464,8 @@ class MigrationListController(bundle: Bundle? = null) : } } activity?.materialAlertDialog() - ?.setTitle(R.string.stop_migrating) - ?.setPositiveButton(R.string.stop) { _, _ -> + ?.setTitle(MR.strings.stop_migrating) + ?.setPositiveButton(MR.strings.stop) { _, _ -> router.popCurrentController() migrationsJob?.cancel() } @@ -517,10 +521,10 @@ class MigrationListController(bundle: Bundle? = null) : private fun showCopyMigrateDialog(copy: Boolean, totalManga: Int, mangaSkipped: Int) { val activity = activity ?: return - val confirmRes = if (copy) R.plurals.copy_manga else R.plurals.migrate_manga - val skipping by lazy { activity.getString(R.string.skipping_, mangaSkipped) } + val confirmRes = if (copy) MR.plurals.copy_manga else MR.plurals.migrate_manga + val skipping by lazy { activity.getString(MR.strings.skipping_, mangaSkipped) } val additionalString = if (mangaSkipped > 0) " $skipping" else "" - val confirmString = activity.resources.getQuantityString( + val confirmString = activity.getString( confirmRes, totalManga, totalManga, @@ -528,7 +532,7 @@ class MigrationListController(bundle: Bundle? = null) : ) activity.materialAlertDialog() .setMessage(confirmString) - .setPositiveButton(if (copy) R.string.copy_value else R.string.migrate) { _, _ -> + .setPositiveButton(if (copy) MR.strings.copy_value else MR.strings.migrate) { _, _ -> if (copy) { copyMangas() } else { @@ -542,8 +546,8 @@ class MigrationListController(bundle: Bundle? = null) : override fun canChangeTabs(block: () -> Unit): Boolean { if (migrationsJob?.isCancelled == false || adapter?.allMangasDone() == true) { activity?.materialAlertDialog() - ?.setTitle(R.string.stop_migrating) - ?.setPositiveButton(R.string.stop) { _, _ -> + ?.setTitle(MR.strings.stop_migrating) + ?.setPositiveButton(MR.strings.stop) { _, _ -> block() migrationsJob?.cancel() } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/migration/manga/process/MigrationProcessHolder.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/migration/manga/process/MigrationProcessHolder.kt index d5733827ac..450c11f23c 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/migration/manga/process/MigrationProcessHolder.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/migration/manga/process/MigrationProcessHolder.kt @@ -8,6 +8,9 @@ import androidx.core.view.isVisible import coil3.imageLoader import coil3.request.ImageRequest import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.database.DatabaseHelper import eu.kanade.tachiyomi.data.database.models.Manga import eu.kanade.tachiyomi.data.coil.CoverViewTarget @@ -120,7 +123,7 @@ class MigrationProcessHolder( binding.migrationMangaCardTo.coverThumbnail.setImageDrawable(null) binding.migrationMangaCardTo.progress.isVisible = false binding.migrationMangaCardTo.title.text = - view.context.getString(R.string.no_alternatives_found) + view.context.getString(MR.strings.no_alternatives_found) } binding.migrationMenu.isVisible = true binding.skipManga.isVisible = false @@ -155,7 +158,7 @@ class MigrationProcessHolder( compactTitle.isVisible = true gradient.isVisible = true compactTitle.text = if (manga.title.isBlank()) { - view.context.getString(R.string.unknown) + view.context.getString(MR.strings.unknown) } else { manga.title } @@ -169,13 +172,13 @@ class MigrationProcessHolder( if (latestChapter > 0f) { subtitle.text = root.context.getString( - R.string.latest_, + MR.strings.latest_, DecimalFormat("#.#").format(latestChapter), ) } else { subtitle.text = root.context.getString( - R.string.latest_, - root.context.getString(R.string.unknown), + MR.strings.latest_, + root.context.getString(MR.strings.unknown), ) } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/migration/manga/process/MigrationProcessItem.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/migration/manga/process/MigrationProcessItem.kt index 2ada43d23b..3875d112d3 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/migration/manga/process/MigrationProcessItem.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/migration/manga/process/MigrationProcessItem.kt @@ -6,6 +6,9 @@ import eu.davidea.flexibleadapter.FlexibleAdapter import eu.davidea.flexibleadapter.items.AbstractFlexibleItem import eu.davidea.flexibleadapter.items.IFlexible import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource class MigrationProcessItem(val manga: MigratingManga) : AbstractFlexibleItem() { diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/more/AboutController.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/more/AboutController.kt index c72c221adc..61779c8eca 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/more/AboutController.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/more/AboutController.kt @@ -15,7 +15,6 @@ import androidx.preference.PreferenceScreen import co.touchlab.kermit.Logger import com.google.android.gms.oss.licenses.OssLicensesMenuActivity import eu.kanade.tachiyomi.BuildConfig -import eu.kanade.tachiyomi.R import eu.kanade.tachiyomi.data.updater.AppDownloadInstallJob import eu.kanade.tachiyomi.data.updater.AppUpdateChecker import eu.kanade.tachiyomi.data.updater.AppUpdateNotifier @@ -27,18 +26,23 @@ import eu.kanade.tachiyomi.ui.setting.add import eu.kanade.tachiyomi.ui.setting.onClick import eu.kanade.tachiyomi.ui.setting.preference import eu.kanade.tachiyomi.ui.setting.preferenceCategory -import eu.kanade.tachiyomi.ui.setting.titleRes +import eu.kanade.tachiyomi.ui.setting.titleMRes import eu.kanade.tachiyomi.util.CrashLogUtil import eu.kanade.tachiyomi.util.lang.toTimestampString import eu.kanade.tachiyomi.util.system.isOnline import eu.kanade.tachiyomi.util.system.localeContext import eu.kanade.tachiyomi.util.system.materialAlertDialog import eu.kanade.tachiyomi.util.system.toast +import eu.kanade.tachiyomi.util.view.setNegativeButton +import eu.kanade.tachiyomi.util.view.setPositiveButton +import eu.kanade.tachiyomi.util.view.setTitle import eu.kanade.tachiyomi.util.view.snack import io.noties.markwon.Markwon import kotlinx.coroutines.Dispatchers import kotlinx.coroutines.launch import kotlinx.coroutines.withContext +import yokai.i18n.MR +import yokai.util.lang.getString import java.text.DateFormat import java.text.ParseException import java.text.SimpleDateFormat @@ -59,11 +63,11 @@ class AboutController : SettingsLegacyController() { private val isUpdaterEnabled = BuildConfig.INCLUDE_UPDATER override fun setupPreferenceScreen(screen: PreferenceScreen) = screen.apply { - titleRes = R.string.about + titleMRes = MR.strings.about preference { key = "pref_whats_new" - titleRes = R.string.whats_new_this_release + titleMRes = MR.strings.whats_new_this_release onClick { val intent = Intent( Intent.ACTION_VIEW, @@ -79,19 +83,19 @@ class AboutController : SettingsLegacyController() { if (isUpdaterEnabled) { preference { key = "pref_check_for_updates" - titleRes = R.string.check_for_updates + titleMRes = MR.strings.check_for_updates onClick { if (activity!!.isOnline()) { checkVersion() } else { - activity!!.toast(R.string.no_network_connection) + activity!!.toast(MR.strings.no_network_connection) } } } } preference { key = "pref_version" - titleRes = R.string.version + titleMRes = MR.strings.version summary = if (BuildConfig.DEBUG || BuildConfig.BETA) { "r" + BuildConfig.COMMIT_COUNT } else { @@ -102,24 +106,24 @@ class AboutController : SettingsLegacyController() { activity?.let { val deviceInfo = CrashLogUtil(it.localeContext).getDebugInfo() val clipboard = it.getSystemService()!! - val appInfo = it.getString(R.string.app_info) + val appInfo = it.getString(MR.strings.app_info) clipboard.setPrimaryClip(ClipData.newPlainText(appInfo, deviceInfo)) if (Build.VERSION.SDK_INT < Build.VERSION_CODES.TIRAMISU) { - view?.snack(context.getString(R.string._copied_to_clipboard, appInfo)) + view?.snack(context.getString(MR.strings._copied_to_clipboard, appInfo)) } } } } preference { key = "pref_build_time" - titleRes = R.string.build_time + titleMRes = MR.strings.build_time summary = getFormattedBuildTime(dateFormat) } preferenceCategory { preference { key = "pref_oss" - titleRes = R.string.open_source_licenses + titleMRes = MR.strings.open_source_licenses onClick { startActivity(Intent(activity, OssLicensesMenuActivity::class.java)) @@ -135,7 +139,7 @@ class AboutController : SettingsLegacyController() { private fun checkVersion() { val activity = activity ?: return - activity.toast(R.string.searching_for_updates) + activity.toast(MR.strings.searching_for_updates) viewScope.launch { val result = try { updateChecker.checkForUpdate(activity, true) @@ -159,7 +163,7 @@ class AboutController : SettingsLegacyController() { } is AppUpdateResult.NoNewUpdate -> { withContext(Dispatchers.Main) { - activity.toast(R.string.no_new_updates_available) + activity.toast(MR.strings.no_new_updates_available) } } } @@ -186,13 +190,13 @@ class AboutController : SettingsLegacyController() { return activity!!.materialAlertDialog() .setTitle( if (isBeta) { - R.string.new_beta_version_available + MR.strings.new_beta_version_available } else { - R.string.new_version_available + MR.strings.new_version_available }, ) .setMessage(info) - .setPositiveButton(if (isOnA12) R.string.update else R.string.download) { _, _ -> + .setPositiveButton(if (isOnA12) MR.strings.update else MR.strings.download) { _, _ -> val appContext = applicationContext if (appContext != null) { // Start download @@ -200,7 +204,7 @@ class AboutController : SettingsLegacyController() { AppDownloadInstallJob.start(appContext, url, true) } } - .setNegativeButton(R.string.ignore, null) + .setNegativeButton(MR.strings.ignore, null) .create() } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/more/OverflowDialog.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/more/OverflowDialog.kt index 4f4993c0ee..4cf921b95b 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/more/OverflowDialog.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/more/OverflowDialog.kt @@ -12,6 +12,9 @@ import androidx.core.view.updateLayoutParams import androidx.vectordrawable.graphics.drawable.AnimatedVectorDrawableCompat import eu.kanade.tachiyomi.BuildConfig import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.core.preference.toggle import eu.kanade.tachiyomi.data.preference.PreferencesHelper import eu.kanade.tachiyomi.databinding.TachiOverflowLayoutBinding @@ -42,17 +45,17 @@ class OverflowDialog(activity: MainActivity) : Dialog(activity, R.style.Overflow binding.touchOutside.setOnClickListener { cancel() } - val incogText = context.getString(R.string.incognito_mode) + val incogText = context.getString(MR.strings.incognito_mode) with(binding.incognitoModeItem) { val titleText = context.getString( if (preferences.incognitoMode().get()) { - R.string.turn_off_ + MR.strings.turn_off_ } else { - R.string.turn_on_ + MR.strings.turn_on_ }, incogText, ) - val subtitleText = context.getString(R.string.pauses_reading_history) + val subtitleText = context.getString(MR.strings.pauses_reading_history) text = titleText.withSubtitle(context, subtitleText) setIcon( if (preferences.incognitoMode().get()) { @@ -66,9 +69,9 @@ class OverflowDialog(activity: MainActivity) : Dialog(activity, R.style.Overflow val incog = preferences.incognitoMode().get() val newTitle = context.getString( if (incog) { - R.string.turn_off_ + MR.strings.turn_off_ } else { - R.string.turn_on_ + MR.strings.turn_on_ }, incogText, ) @@ -105,7 +108,7 @@ class OverflowDialog(activity: MainActivity) : Dialog(activity, R.style.Overflow } } - binding.aboutItem.text = context.getString(R.string.about).withSubtitle(newVName) + binding.aboutItem.text = context.getString(MR.strings.about).withSubtitle(newVName) binding.aboutItem.setOnClickListener { activity.showAbout() diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/more/stats/StatsController.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/more/stats/StatsController.kt index 15cb64f27b..c001a32a2d 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/more/stats/StatsController.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/more/stats/StatsController.kt @@ -14,6 +14,9 @@ import com.github.mikephil.charting.data.PieDataSet import com.github.mikephil.charting.data.PieEntry import com.github.mikephil.charting.formatter.ValueFormatter import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.database.models.LibraryManga import eu.kanade.tachiyomi.data.database.models.Manga import eu.kanade.tachiyomi.data.database.models.Track @@ -41,7 +44,7 @@ class StatsController : BaseLegacyController() { /** * Returns the toolbar title to show when this controller is attached. */ - override fun getTitle() = resources?.getString(R.string.statistics) + override fun getTitle() = activity?.getString(MR.strings.statistics) override fun createBinding(inflater: LayoutInflater) = StatsControllerBinding.inflate(inflater) @@ -68,7 +71,7 @@ class StatsController : BaseLegacyController() { statsChaptersReadText.text = mangaDistinct.sumOf { it.read }.toString() statsMangaMeanScoreText.text = if (scoresList.isEmpty()) { statsMangaMeanScoreText.setCompoundDrawablesWithIntrinsicBounds(0, 0, 0, 0) - activity?.getString(R.string.none) + activity?.getString(MR.strings.none) } else { scoresList.average().roundToTwoDecimal().toString() } @@ -80,7 +83,7 @@ class StatsController : BaseLegacyController() { statsSourcesText.text = presenter.getSources().count().toString() statsTrackersText.text = presenter.getLoggedTrackers().count().toString() statsReadDurationText.text = presenter.getReadDuration() - statsReadDurationLayout.compatToolTipText = activity?.getString(R.string.read_duration_info) + statsReadDurationLayout.compatToolTipText = activity?.getString(MR.strings.read_duration_info) } } @@ -109,7 +112,7 @@ class StatsController : BaseLegacyController() { StatusDistributionItem(activity!!.mapStatus(status), libraryCount, color) } - val pieDataSet = PieDataSet(pieEntries, activity!!.getString(R.string.manga_status_distribution)) + val pieDataSet = PieDataSet(pieEntries, activity!!.getString(MR.strings.manga_status_distribution)) pieDataSet.colors = mangaStatusDistributionList.map { it.color } showMangaStatsStatusChart(pieDataSet) binding.mangaStatsStatusRecyclerView.adapter = @@ -144,7 +147,7 @@ class StatsController : BaseLegacyController() { val barEntries = scoreMap.map { (score, _) -> BarEntry(score.toFloat(), userScoreList[score]?.toFloat() ?: 0f) } - val barDataSet = BarDataSet(barEntries, activity!!.getString(R.string.manga_score_distribution)) + val barDataSet = BarDataSet(barEntries, activity!!.getString(MR.strings.manga_score_distribution)) barDataSet.colors = scoreMap.values.toList() showMangaStatsScoreChart(barDataSet) } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/more/stats/StatsLegendAdapter.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/more/stats/StatsLegendAdapter.kt index f8bcf44454..819c011030 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/more/stats/StatsLegendAdapter.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/more/stats/StatsLegendAdapter.kt @@ -6,6 +6,9 @@ import android.view.View import android.view.ViewGroup import androidx.recyclerview.widget.RecyclerView import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.databinding.ListChartLegendBinding class StatsLegendAdapter( diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/more/stats/StatsPresenter.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/more/stats/StatsPresenter.kt index 7f11e17272..0fc5156415 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/more/stats/StatsPresenter.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/more/stats/StatsPresenter.kt @@ -1,6 +1,9 @@ package eu.kanade.tachiyomi.ui.more.stats import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.database.DatabaseHelper import eu.kanade.tachiyomi.data.database.models.LibraryManga import eu.kanade.tachiyomi.data.database.models.Manga @@ -83,6 +86,6 @@ class StatsPresenter( fun getReadDuration(): String { val chaptersTime = db.getTotalReadDuration() - return chaptersTime.getReadDuration(prefs.context.getString(R.string.none)) + return chaptersTime.getReadDuration(prefs.context.getString(MR.strings.none)) } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/more/stats/details/HeaderStatsDetailsAdapter.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/more/stats/details/HeaderStatsDetailsAdapter.kt index d74eeb2466..528a62b6cd 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/more/stats/details/HeaderStatsDetailsAdapter.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/more/stats/details/HeaderStatsDetailsAdapter.kt @@ -5,6 +5,9 @@ import android.view.View import android.view.ViewGroup import androidx.recyclerview.widget.RecyclerView import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.databinding.StatsDetailsChartBinding class HeaderStatsDetailsAdapter( diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/more/stats/details/StatsDetailsAdapter.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/more/stats/details/StatsDetailsAdapter.kt index a142f605ad..c467f37542 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/more/stats/details/StatsDetailsAdapter.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/more/stats/details/StatsDetailsAdapter.kt @@ -11,6 +11,9 @@ import androidx.core.view.isVisible import androidx.core.view.setPadding import androidx.recyclerview.widget.RecyclerView import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.databinding.ListStatsDetailsBinding import eu.kanade.tachiyomi.ui.more.stats.StatsHelper.getReadDuration import eu.kanade.tachiyomi.ui.more.stats.details.StatsDetailsPresenter.Stats @@ -84,7 +87,7 @@ class StatsDetailsAdapter( val label = item.label?.let { if (stat == Stats.LENGTH) { val max = item.id?.toInt() ?: 0 - root.resources.getQuantityString(R.plurals.chapters_plural, max, it) + root.context.getString(MR.plurals.chapters_plural, max, it) } else { it } @@ -108,7 +111,7 @@ class StatsDetailsAdapter( statsMeanScoreLayout.isVisible = score.isNotBlank() statsScoreText.text = score statsReadDurationText.text = - item.readDuration.getReadDuration(context.getString(R.string.none)) + item.readDuration.getReadDuration(context.getString(MR.strings.none)) } } @@ -132,7 +135,7 @@ class StatsDetailsAdapter( statsProgressText.text = getProgressText(item) statsProgressPercentageText.text = getProgressPercentageString(item) statsReadDurationText.text = - item.readDuration.getReadDuration(context.getString(R.string.none)) + item.readDuration.getReadDuration(context.getString(MR.strings.none)) } } @@ -166,7 +169,7 @@ class StatsDetailsAdapter( statsMeanScoreLayout.isVisible = score.isNotBlank() statsScoreText.text = score statsReadDurationText.text = - item.readDuration.getReadDuration(context.getString(R.string.none)) + item.readDuration.getReadDuration(context.getString(MR.strings.none)) } } @@ -185,7 +188,7 @@ class StatsDetailsAdapter( ) statsLabelText.text = item.label?.uppercase() statsScoreText.text = - item.readDuration.getReadDuration(context.getString(R.string.none)) + item.readDuration.getReadDuration(context.getString(MR.strings.none)) statsSublabelText.isVisible = !item.subLabel.isNullOrBlank() statsSublabelText.text = item.subLabel } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/more/stats/details/StatsDetailsChartLayout.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/more/stats/details/StatsDetailsChartLayout.kt index b338ce5a0b..56e952d639 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/more/stats/details/StatsDetailsChartLayout.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/more/stats/details/StatsDetailsChartLayout.kt @@ -24,6 +24,9 @@ import com.github.mikephil.charting.highlight.Highlight import com.github.mikephil.charting.listener.OnChartValueSelectedListener import com.github.mikephil.charting.utils.MPPointF import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.databinding.StatsDetailsChartBinding import eu.kanade.tachiyomi.ui.more.stats.StatsHelper import eu.kanade.tachiyomi.ui.more.stats.StatsHelper.getReadDuration diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/more/stats/details/StatsDetailsController.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/more/stats/details/StatsDetailsController.kt index 3e333fd08d..ce23a6447a 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/more/stats/details/StatsDetailsController.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/more/stats/details/StatsDetailsController.kt @@ -27,7 +27,12 @@ import com.github.mikephil.charting.data.Entry import com.github.mikephil.charting.highlight.Highlight import com.google.android.material.chip.Chip import com.google.android.material.datepicker.MaterialDatePicker +import dev.icerock.moko.resources.PluralsResource +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.database.models.Category import eu.kanade.tachiyomi.databinding.StatsDetailsChartBinding import eu.kanade.tachiyomi.databinding.StatsDetailsControllerBinding @@ -56,7 +61,10 @@ import eu.kanade.tachiyomi.util.view.compatToolTipText import eu.kanade.tachiyomi.util.view.doOnApplyWindowInsetsCompat import eu.kanade.tachiyomi.util.view.isControllerVisible import eu.kanade.tachiyomi.util.view.liftAppbarWith +import eu.kanade.tachiyomi.util.view.setNegativeButton import eu.kanade.tachiyomi.util.view.setOnQueryTextChangeListener +import eu.kanade.tachiyomi.util.view.setTitle +import eu.kanade.tachiyomi.util.view.setTitleText import eu.kanade.tachiyomi.util.view.withFadeTransaction import kotlinx.coroutines.Job import kotlinx.coroutines.launch @@ -91,7 +99,7 @@ class StatsDetailsController : /** * Returns the toolbar title to show when this controller is attached. */ - override fun getTitle() = resources?.getString(R.string.statistics_details) + override fun getTitle() = activity?.getString(MR.strings.statistics_details) override fun createBinding(inflater: LayoutInflater) = StatsDetailsControllerBinding.inflate(inflater) @@ -114,7 +122,7 @@ class StatsDetailsController : } chartLinearLayout?.statSort?.isVisible = false - statsClearButtonContainer.compatToolTipText = activity?.getString(R.string.clear_filters) + statsClearButtonContainer.compatToolTipText = activity?.getString(MR.strings.clear_filters) statsClearButtonContainer.setOnClickListener { resetFilters() searchView.clearFocus() @@ -126,7 +134,7 @@ class StatsDetailsController : chipStat.setOnClickListener { searchView.clearFocus() activity?.materialAlertDialog() - ?.setTitle(R.string.stat) + ?.setTitle(MR.strings.stat) ?.setSingleChoiceItems( presenter.getStatsArray(), Stats.entries.indexOf(presenter.selectedStat), @@ -151,14 +159,14 @@ class StatsDetailsController : (it as Chip).setMultiChoiceItemsDialog( presenter.seriesTypeStats, presenter.selectedSeriesType, - R.string.series_type, - R.plurals._series_types, + MR.strings.series_type, + MR.plurals._series_types, ) } chipSeriesType.setOnCloseIconClickListener { if (presenter.selectedSeriesType.isNotEmpty()) { presenter.selectedSeriesType = mutableSetOf() - chipSeriesType.reset(R.string.series_type) + chipSeriesType.reset(MR.strings.series_type) } else { chipSeriesType.callOnClick() } @@ -167,14 +175,14 @@ class StatsDetailsController : (it as Chip).setMultiChoiceItemsDialog( presenter.sources.toTypedArray(), presenter.selectedSource, - R.string.source, - R.plurals._sources, + MR.strings.source, + MR.plurals._sources, ) } chipSource.setOnCloseIconClickListener { if (presenter.selectedSource.isNotEmpty()) { presenter.selectedSource = mutableSetOf() - chipSource.reset(R.string.source) + chipSource.reset(MR.strings.source) } else { chipSource.callOnClick() } @@ -183,14 +191,14 @@ class StatsDetailsController : (it as Chip).setMultiChoiceItemsDialog( presenter.statusStats, presenter.selectedStatus, - R.string.status, - R.plurals._statuses, + MR.strings.status, + MR.plurals._statuses, ) } chipStatus.setOnCloseIconClickListener { if (presenter.selectedStatus.isNotEmpty()) { presenter.selectedStatus = mutableSetOf() - chipStatus.reset(R.string.status) + chipStatus.reset(MR.strings.status) } else { chipStatus.callOnClick() } @@ -199,14 +207,14 @@ class StatsDetailsController : (it as Chip).setMultiChoiceItemsDialog( presenter.languagesStats.values.toTypedArray(), presenter.selectedLanguage, - R.string.language, - R.plurals._languages, + MR.strings.language, + MR.plurals._languages, ) } chipLanguage.setOnCloseIconClickListener { if (presenter.selectedLanguage.isNotEmpty()) { presenter.selectedLanguage = mutableSetOf() - chipLanguage.reset(R.string.language) + chipLanguage.reset(MR.strings.language) } else { chipLanguage.callOnClick() } @@ -215,14 +223,14 @@ class StatsDetailsController : (it as Chip).setMultiChoiceItemsDialog( presenter.categoriesStats, presenter.selectedCategory, - R.string.category, - R.plurals.category_plural, + MR.strings.category, + MR.plurals.category_plural, ) } chipCategory.setOnCloseIconClickListener { if (presenter.selectedCategory.isNotEmpty()) { presenter.selectedCategory = mutableSetOf() - chipCategory.reset(R.string.category) + chipCategory.reset(MR.strings.category) } else { chipCategory.callOnClick() } @@ -278,20 +286,20 @@ class StatsDetailsController : chipStat.setColors((presenter.selectedStat != defaultStat).toInt()) chipSeriesType.setState( presenter.selectedSeriesType, - R.string.series_type, - R.plurals._series_types, + MR.strings.series_type, + MR.plurals._series_types, ) - chipSource.setState(presenter.selectedSource, R.string.source, R.plurals._sources) - chipStatus.setState(presenter.selectedStatus, R.string.status, R.plurals._statuses) + chipSource.setState(presenter.selectedSource, MR.strings.source, MR.plurals._sources) + chipStatus.setState(presenter.selectedStatus, MR.strings.status, MR.plurals._statuses) chipLanguage.setState( presenter.selectedLanguage, - R.string.language, - R.plurals._languages, + MR.strings.language, + MR.plurals._languages, ) chipCategory.setState( presenter.selectedCategory, - R.string.category, - R.plurals.category_plural, + MR.strings.category, + MR.plurals.category_plural, ) statsSortTextView?.text = activity?.getString( presenter.selectedStatsSort?.resourceId ?: defaultSort.resourceId, @@ -336,7 +344,7 @@ class StatsDetailsController : inflater.inflate(R.menu.stats_bar, menu) searchItem = menu.findItem(R.id.action_search) searchView = searchItem.actionView as SearchView - searchView.queryHint = activity?.getString(R.string.search_, activity?.getString(R.string.statistics)?.lowercase(Locale.ROOT)) + searchView.queryHint = activity?.getString(MR.strings.search_, activity?.getString(MR.strings.statistics)?.lowercase(Locale.ROOT) ?: "") if (query.isNotBlank() && (!searchItem.isActionViewExpanded || searchView.query != query)) { searchItem.expandActionView() setSearchViewListener(searchView) @@ -370,8 +378,8 @@ class StatsDetailsController : private fun Chip.setMultiChoiceItemsDialog( statsList: Array, selectedValues: MutableSet, - resourceId: Int, - @PluralsRes resourceIdPlural: Int, + resourceId: StringResource, + resourceIdPlural: PluralsResource, ) { val tempValues = selectedValues.toMutableSet() val items = statsList.map { @@ -425,7 +433,7 @@ class StatsDetailsController : * Reset the text of the chip selected and reset layout * @param resourceId string resource of the stat name */ - private fun Chip.reset(resourceId: Int) { + private fun Chip.reset(resourceId: StringResource) { resetAndSetup(keepAdapter = true) this.setColors(0) this.text = activity?.getString(resourceId) @@ -454,7 +462,7 @@ class StatsDetailsController : with(binding ?: headerBinding) { val hasNoData = currentStats.isNullOrEmpty() || currentStats.all { it.count == 0 } if (hasNoData) { - this@StatsDetailsController.binding.noChartData.show(R.drawable.ic_heart_off_24dp, R.string.no_data_for_filters) + this@StatsDetailsController.binding.noChartData.show(R.drawable.ic_heart_off_24dp, MR.strings.no_data_for_filters) presenter.currentStats?.removeAll { it.count == 0 } handleNoChartLayout() this?.statsPieChart?.isVisible = false @@ -509,9 +517,8 @@ class StatsDetailsController : */ private fun Chip.setState( selectedValues: MutableSet, - resourceId: Int, - @PluralsRes - resourceIdPlural: Int, + resourceId: StringResource, + resourceIdPlural: PluralsResource, ) { this.setColors(selectedValues.size) this.text = when (selectedValues.size) { @@ -526,7 +533,7 @@ class StatsDetailsController : else -> firstValue.toString() } } - else -> activity?.resources?.getQuantityString(resourceIdPlural, selectedValues.size, selectedValues.size) + else -> activity?.getString(resourceIdPlural, selectedValues.size, selectedValues.size) } } @@ -542,15 +549,15 @@ class StatsDetailsController : statsSortTextView?.text = activity?.getString(defaultSort.resourceId) } presenter.selectedSeriesType = mutableSetOf() - chipSeriesType.text = activity?.getString(R.string.series_type) + chipSeriesType.text = activity?.getString(MR.strings.series_type) presenter.selectedSource = mutableSetOf() - chipSource.text = activity?.getString(R.string.source) + chipSource.text = activity?.getString(MR.strings.source) presenter.selectedStatus = mutableSetOf() - chipStatus.text = activity?.getString(R.string.status) + chipStatus.text = activity?.getString(MR.strings.status) presenter.selectedLanguage = mutableSetOf() - chipLanguage.text = activity?.getString(R.string.language) + chipLanguage.text = activity?.getString(MR.strings.language) presenter.selectedCategory = mutableSetOf() - chipCategory.text = activity?.getString(R.string.category) + chipCategory.text = activity?.getString(MR.strings.category) } } @@ -710,7 +717,7 @@ class StatsDetailsController : } router.pushController( FilteredLibraryController( - binding.root.resources.getQuantityString(R.plurals.chapters_plural, range.last, name), + binding.root.context.getString(MR.plurals.chapters_plural, range.last, name), filterMangaType = seriesTypes, filterStatus = statuses, filterSources = sources, @@ -773,7 +780,7 @@ class StatsDetailsController : override fun onSortClicked(binding: StatsDetailsChartBinding?) { searchView.clearFocus() activity!!.materialAlertDialog() - .setTitle(R.string.sort_by) + .setTitle(MR.strings.sort_by) .setSingleChoiceItems( presenter.getSortDataArray(), StatsSort.entries.indexOf(presenter.selectedStatsSort), @@ -794,7 +801,7 @@ class StatsDetailsController : override fun onDateTextClicked(statsDateText: TextView, barChart: BarChart) { val dialog = MaterialDatePicker.Builder.dateRangePicker() - .setTitleText(R.string.read_duration) + .setTitleText(MR.strings.read_duration) .setSelection( Pair( presenter.startDate.timeInMillis.toUtcCalendar()?.timeInMillis, @@ -818,7 +825,7 @@ class StatsDetailsController : presenter.getStatisticData() } } - dialog.show((activity as AppCompatActivity).supportFragmentManager, activity?.getString(R.string.read_duration)) + dialog.show((activity as AppCompatActivity).supportFragmentManager, activity?.getString(MR.strings.read_duration)) } /** diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/more/stats/details/StatsDetailsPresenter.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/more/stats/details/StatsDetailsPresenter.kt index 4426f2bda1..c34df10f83 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/more/stats/details/StatsDetailsPresenter.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/more/stats/details/StatsDetailsPresenter.kt @@ -3,7 +3,11 @@ package eu.kanade.tachiyomi.ui.more.stats.details import android.graphics.drawable.Drawable import android.text.format.DateUtils import androidx.annotation.DrawableRes +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.database.DatabaseHelper import eu.kanade.tachiyomi.data.database.models.Category import eu.kanade.tachiyomi.data.database.models.History @@ -83,21 +87,21 @@ class StatsDetailsPresenter( var currentStats: ArrayList? = null val seriesTypeStats by lazy { arrayOf( - context.getString(R.string.manga), - context.getString(R.string.manhwa), - context.getString(R.string.manhua), - context.getString(R.string.comic), - context.getString(R.string.webtoon), + context.getString(MR.strings.manga), + context.getString(MR.strings.manhwa), + context.getString(MR.strings.manhua), + context.getString(MR.strings.comic), + context.getString(MR.strings.webtoon), ) } val statusStats by lazy { arrayOf( - context.getString(R.string.ongoing), - context.getString(R.string.completed), - context.getString(R.string.licensed), - context.getString(R.string.publishing_finished), - context.getString(R.string.cancelled), - context.getString(R.string.on_hiatus), + context.getString(MR.strings.ongoing), + context.getString(MR.strings.completed), + context.getString(MR.strings.licensed), + context.getString(MR.strings.publishing_finished), + context.getString(MR.strings.cancelled), + context.getString(MR.strings.on_hiatus), ) } private val defaultCategory by lazy { @@ -192,7 +196,7 @@ class StatsDetailsPresenter( meanScore = score?.toDouble() ?: 0.0, chaptersRead = mangaList?.sumOf { it.read } ?: 0, totalChapters = mangaList?.sumOf { it.totalChapters } ?: 0, - label = score?.toString() ?: context.getString(R.string.not_rated), + label = score?.toString() ?: context.getString(MR.strings.not_rated), readDuration = mangaList?.getReadDuration() ?: 0L, id = score?.toLong(), ), @@ -258,7 +262,7 @@ class StatsDetailsPresenter( serviceWithTrackedManga.forEach { (serviceId, mangaAndTrack) -> val service = loggedServices.find { it.id == serviceId } - val label = context.getString(service?.nameRes() ?: R.string.not_tracked) + val label = context.getString(service?.nameRes() ?: MR.strings.not_tracked) currentStats?.add( StatsData( color = service?.getTrackerColor() ?: pieColorList.first(), @@ -306,7 +310,7 @@ class StatsDetailsPresenter( val categories = getCategories() libraryFormat.forEach { (category, mangaList) -> - val label = categories.find { it.id == category }?.name ?: context.getString(R.string.default_value) + val label = categories.find { it.id == category }?.name ?: context.getString(MR.strings.default_value) currentStats?.add( StatsData( color = pieColorList[currentStats?.size!! % pieColorList.size], @@ -362,7 +366,7 @@ class StatsDetailsPresenter( meanScore = mangaList.getMeanScoreRounded(), chaptersRead = mangaList.sumOf { it.read }, totalChapters = mangaList.sumOf { it.totalChapters }, - label = year?.toString() ?: context.getString(R.string.not_started), + label = year?.toString() ?: context.getString(MR.strings.not_started), readDuration = mangaList.getReadDuration(), id = year?.toLong(), ), @@ -489,7 +493,7 @@ class StatsDetailsPresenter( LocalSource.getMangaLang(this) } else { sourceManager.get(source)?.lang - } ?: return context.getString(R.string.unknown) + } ?: return context.getString(MR.strings.unknown) return LocaleHelper.getDisplayName(code) } @@ -596,7 +600,7 @@ class StatsDetailsPresenter( Calendar.SHORT, Locale.getDefault(), ) - } ?: context.getString(R.string.unknown) + } ?: context.getString(MR.strings.unknown) } fun changeReadDurationPeriod(toAdd: Int) { @@ -657,24 +661,24 @@ class StatsDetailsPresenter( return "$startDateString - $endDateString" } - enum class Stats(val resourceId: Int) { - SERIES_TYPE(R.string.series_type), - STATUS(R.string.status), - READ_DURATION(R.string.read_duration), - SCORE(R.string.score), - LENGTH(R.string.length), - LANGUAGE(R.string.language), - SOURCE(R.string.source), - TRACKER(R.string.tracker), - CATEGORY(R.string.category), - TAG(R.string.tag), - START_YEAR(R.string.start_year), - } - - enum class StatsSort(val resourceId: Int) { - COUNT_DESC(R.string.most_entries), - PROGRESS_DESC(R.string.chapters_read), - MEAN_SCORE_DESC(R.string.mean_tracking_score), + enum class Stats(val resourceId: StringResource) { + SERIES_TYPE(MR.strings.series_type), + STATUS(MR.strings.status), + READ_DURATION(MR.strings.read_duration), + SCORE(MR.strings.score), + LENGTH(MR.strings.length), + LANGUAGE(MR.strings.language), + SOURCE(MR.strings.source), + TRACKER(MR.strings.tracker), + CATEGORY(MR.strings.category), + TAG(MR.strings.tag), + START_YEAR(MR.strings.start_year), + } + + enum class StatsSort(val resourceId: StringResource) { + COUNT_DESC(MR.strings.most_entries), + PROGRESS_DESC(MR.strings.chapters_read), + MEAN_SCORE_DESC(MR.strings.mean_tracking_score), } class StatsData( diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/ReaderActivity.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/ReaderActivity.kt index 2a755eb28e..83e5e30aee 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/ReaderActivity.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/ReaderActivity.kt @@ -77,6 +77,9 @@ import com.google.android.material.transition.platform.MaterialContainerTransfor import com.hippo.unifile.UniFile import eu.kanade.tachiyomi.BuildConfig import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.core.preference.toggle import eu.kanade.tachiyomi.data.coil.TachiyomiImageDecoder import eu.kanade.tachiyomi.data.database.models.Chapter @@ -141,6 +144,8 @@ import eu.kanade.tachiyomi.util.view.hide import eu.kanade.tachiyomi.util.view.isCollapsed import eu.kanade.tachiyomi.util.view.isExpanded import eu.kanade.tachiyomi.util.view.popupMenu +import eu.kanade.tachiyomi.util.view.setAction +import eu.kanade.tachiyomi.util.view.setMessage import eu.kanade.tachiyomi.util.view.snack import eu.kanade.tachiyomi.widget.doOnEnd import eu.kanade.tachiyomi.widget.doOnStart @@ -599,9 +604,9 @@ class ReaderActivity : BaseActivity() { compatToolTipText = getString( if (enabled) { - R.string.remove_crop + MR.strings.remove_crop } else { - R.string.crop_borders + MR.strings.crop_borders }, ) } @@ -788,7 +793,7 @@ class ReaderActivity : BaseActivity() { with(binding.chaptersSheet) { with(doublePage) { - compatToolTipText = getString(R.string.page_layout) + compatToolTipText = getString(MR.strings.page_layout) setOnClickListener { if (preferences.pageLayout().get() == PageLayout.AUTOMATIC.value) { (viewer as? PagerViewer)?.config?.let { config -> @@ -817,7 +822,7 @@ class ReaderActivity : BaseActivity() { } with(rotationSheetButton) { - compatToolTipText = getString(R.string.rotation) + compatToolTipText = getString(MR.strings.rotation) setOnClickListener { popupMenu( @@ -1052,9 +1057,9 @@ class ReaderActivity : BaseActivity() { } else { toast( if (getNextChapter) { - R.string.theres_no_next_chapter + MR.strings.theres_no_next_chapter } else { - R.string.theres_no_previous_chapter + MR.strings.theres_no_previous_chapter }, ) } @@ -1228,19 +1233,19 @@ class ReaderActivity : BaseActivity() { ) { snackbar = binding.readerLayout.snack( getString( - R.string.reading_, + MR.strings.reading_, getString( when (mangaViewer) { - ReadingModeType.RIGHT_TO_LEFT.flagValue -> R.string.right_to_left_viewer - ReadingModeType.VERTICAL.flagValue -> R.string.vertical_viewer - ReadingModeType.LONG_STRIP.flagValue -> R.string.long_strip - else -> R.string.left_to_right_viewer + ReadingModeType.RIGHT_TO_LEFT.flagValue -> MR.strings.right_to_left_viewer + ReadingModeType.VERTICAL.flagValue -> MR.strings.vertical_viewer + ReadingModeType.LONG_STRIP.flagValue -> MR.strings.long_strip + else -> MR.strings.left_to_right_viewer }, ).lowercase(Locale.getDefault()), ), 4000, ) { - setAction(R.string.use_default) { + setAction(MR.strings.use_default) { viewModel.setMangaReadingMode(0) } } @@ -1266,11 +1271,11 @@ class ReaderActivity : BaseActivity() { binding.viewerContainer.addView(newViewer.getView()) if (newViewer is R2LPagerViewer) { - binding.readerNav.leftChapter.compatToolTipText = getString(R.string.next_chapter) - binding.readerNav.rightChapter.compatToolTipText = getString(R.string.previous_chapter) + binding.readerNav.leftChapter.compatToolTipText = getString(MR.strings.next_chapter) + binding.readerNav.rightChapter.compatToolTipText = getString(MR.strings.previous_chapter) } else { - binding.readerNav.leftChapter.compatToolTipText = getString(R.string.previous_chapter) - binding.readerNav.rightChapter.compatToolTipText = getString(R.string.next_chapter) + binding.readerNav.leftChapter.compatToolTipText = getString(MR.strings.previous_chapter) + binding.readerNav.rightChapter.compatToolTipText = getString(MR.strings.next_chapter) } if (newViewer is PagerViewer) { @@ -1536,42 +1541,42 @@ class ReaderActivity : BaseActivity() { MaterialMenuSheet.MenuSheetItem( 3, R.drawable.ic_outline_share_24dp, - R.string.share_second_page, + MR.strings.share_second_page, ), MaterialMenuSheet.MenuSheetItem( 4, R.drawable.ic_outline_save_24dp, - R.string.save_second_page, + MR.strings.save_second_page, ), MaterialMenuSheet.MenuSheetItem( 5, R.drawable.ic_outline_photo_24dp, - R.string.set_second_page_as_cover, + MR.strings.set_second_page_as_cover, ), MaterialMenuSheet.MenuSheetItem( 0, R.drawable.ic_share_24dp, - R.string.share_first_page, + MR.strings.share_first_page, ), MaterialMenuSheet.MenuSheetItem( 1, R.drawable.ic_save_24dp, - R.string.save_first_page, + MR.strings.save_first_page, ), MaterialMenuSheet.MenuSheetItem( 2, R.drawable.ic_photo_24dp, - R.string.set_first_page_as_cover, + MR.strings.set_first_page_as_cover, ), MaterialMenuSheet.MenuSheetItem( 6, R.drawable.ic_share_all_outline_24dp, - R.string.share_combined_pages, + MR.strings.share_combined_pages, ), MaterialMenuSheet.MenuSheetItem( 7, R.drawable.ic_save_all_outline_24dp, - R.string.save_combined_pages, + MR.strings.save_combined_pages, ), ) } else { @@ -1579,17 +1584,17 @@ class ReaderActivity : BaseActivity() { MaterialMenuSheet.MenuSheetItem( 0, R.drawable.ic_share_24dp, - R.string.share, + MR.strings.share, ), MaterialMenuSheet.MenuSheetItem( 1, R.drawable.ic_save_24dp, - R.string.save, + MR.strings.save, ), MaterialMenuSheet.MenuSheetItem( 2, R.drawable.ic_photo_24dp, - R.string.set_as_cover, + MR.strings.set_as_cover, ), ) } @@ -1659,7 +1664,7 @@ class ReaderActivity : BaseActivity() { if (page.status != Page.State.READY) return materialAlertDialog() - .setMessage(R.string.use_image_as_cover) + .setMessage(MR.strings.use_image_as_cover) .setPositiveButton(AR.string.ok) { _, _ -> setAsCover(page) } @@ -1679,12 +1684,12 @@ class ReaderActivity : BaseActivity() { DecimalFormat("#.###", DecimalFormatSymbols().apply { decimalSeparator = '.' }) val pageNumber = if (secondPage != null) { - getString(R.string.pages_, if (resources.isLTR) "${page.number}-${page.number + 1}" else "${page.number + 1}-${page.number}") + getString(MR.strings.pages_, if (resources.isLTR) "${page.number}-${page.number + 1}" else "${page.number + 1}-${page.number}") } else { - getString(R.string.page_, page.number) + getString(MR.strings.page_, page.number) } val text = "${manga.title}: ${if (chapter.isRecognizedNumber) { - getString(R.string.chapter_, decimalFormat.format(chapter.chapter_number)) + getString(MR.strings.chapter_, decimalFormat.format(chapter.chapter_number)) } else { chapter.preferredChapterName(this, manga, preferences) } @@ -1698,7 +1703,7 @@ class ReaderActivity : BaseActivity() { clipData = ClipData.newRawUri(null, stream) type = "image/*" } - startActivity(Intent.createChooser(intent, getString(R.string.share))) + startActivity(Intent.createChooser(intent, getString(MR.strings.share))) } override fun onProvideAssistContent(outContent: AssistContent) { @@ -1722,7 +1727,7 @@ class ReaderActivity : BaseActivity() { private fun onSaveImageResult(result: ReaderViewModel.SaveImageResult) { when (result) { is ReaderViewModel.SaveImageResult.Success -> { - toast(R.string.picture_saved) + toast(MR.strings.picture_saved) } is ReaderViewModel.SaveImageResult.Error -> { Logger.e(result.error) @@ -1745,9 +1750,9 @@ class ReaderActivity : BaseActivity() { private fun onSetAsCoverResult(result: ReaderViewModel.SetAsCoverResult) { toast( when (result) { - Success -> R.string.cover_updated - AddToLibraryFirst -> R.string.must_be_in_library_to_edit - Error -> R.string.failed_to_update_cover + Success -> MR.strings.cover_updated + AddToLibraryFirst -> MR.strings.must_be_in_library_to_edit + Error -> MR.strings.failed_to_update_cover }, ) } @@ -1756,7 +1761,7 @@ class ReaderActivity : BaseActivity() { if (errors.isEmpty()) return snackbar?.dismiss() val errorText = if (errors.size > 1) { - getString(R.string.failed_to_update_, errors.joinToString(", ") { getString(it.first.nameRes()) }) + getString(MR.strings.failed_to_update_, errors.joinToString(", ") { getString(it.first.nameRes()) }) } else { val (service, errorMessage) = errors.first() buildSpannedString { diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/ReaderNavigationOverlayView.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/ReaderNavigationOverlayView.kt index a81c471a76..46a99976db 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/ReaderNavigationOverlayView.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/ReaderNavigationOverlayView.kt @@ -12,6 +12,7 @@ import androidx.core.content.ContextCompat import androidx.core.view.isVisible import eu.kanade.tachiyomi.ui.reader.viewer.ViewerNavigation import eu.kanade.tachiyomi.ui.reader.viewer.navigation.DisabledNavigation +import yokai.util.lang.getString import kotlin.math.abs class ReaderNavigationOverlayView(context: Context, attributeSet: AttributeSet) : View(context, attributeSet) { diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/ReaderViewModel.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/ReaderViewModel.kt index b190042d40..303d59d070 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/ReaderViewModel.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/ReaderViewModel.kt @@ -10,6 +10,9 @@ import androidx.lifecycle.viewModelScope import co.touchlab.kermit.Logger import com.hippo.unifile.UniFile import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.cache.CoverCache import eu.kanade.tachiyomi.data.database.DatabaseHelper import eu.kanade.tachiyomi.data.database.models.Chapter @@ -290,7 +293,7 @@ class ReaderViewModel( fun intentPageNumber(url: Uri): Int? { val host = url.host ?: return null val delegatedSource = sourceManager.getDelegatedSource(host) ?: error( - preferences.context.getString(R.string.source_not_installed), + preferences.context.getString(MR.strings.source_not_installed), ) return delegatedSource.pageNumber(url)?.minus(1) } @@ -299,11 +302,11 @@ class ReaderViewModel( val host = url.host ?: return val context = Injekt.get() val delegatedSource = sourceManager.getDelegatedSource(host) ?: error( - context.getString(R.string.source_not_installed), + context.getString(MR.strings.source_not_installed), ) val chapterUrl = delegatedSource.chapterUrl(url) val sourceId = delegatedSource.delegate?.id ?: error( - context.getString(R.string.source_not_installed), + context.getString(MR.strings.source_not_installed), ) if (chapterUrl != null) { val dbChapter = db.getChapters(chapterUrl).executeOnIO().find { @@ -341,11 +344,11 @@ class ReaderViewModel( delegatedSource.delegate!!, ).first chapterId = newChapters.find { it.url == chapter.url }?.id - ?: error(context.getString(R.string.chapter_not_found)) + ?: error(context.getString(MR.strings.chapter_not_found)) } else { chapter.date_fetch = Date().time chapterId = db.insertChapter(chapter).executeOnIO().insertedId() ?: error( - context.getString(R.string.unknown_error), + context.getString(MR.strings.unknown_error), ) } withContext(Dispatchers.Main) { @@ -353,7 +356,7 @@ class ReaderViewModel( } } } else { - error(context.getString(R.string.unknown_error)) + error(context.getString(MR.strings.unknown_error)) } } @@ -918,7 +921,7 @@ class ReaderViewModel( val context = Injekt.get() coverCache.deleteFromCache(manga) LocalSource.updateCover(manga, stream()) - R.string.cover_updated + MR.strings.cover_updated SetAsCoverResult.Success } else { if (manga.favorite) { diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/SaveImageNotifier.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/SaveImageNotifier.kt index f95356536f..831efa94b8 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/SaveImageNotifier.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/SaveImageNotifier.kt @@ -10,6 +10,9 @@ import coil3.request.CachePolicy import coil3.request.ImageRequest import com.hippo.unifile.UniFile import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.notification.NotificationHandler import eu.kanade.tachiyomi.data.notification.NotificationReceiver import eu.kanade.tachiyomi.data.notification.Notifications @@ -57,7 +60,7 @@ class SaveImageNotifier(private val context: Context) { private fun showCompleteNotification(file: UniFile, image: Bitmap) { with(notificationBuilder) { - setContentTitle(context.getString(R.string.picture_saved)) + setContentTitle(context.getString(MR.strings.picture_saved)) setSmallIcon(R.drawable.ic_photo_24dp) setStyle(NotificationCompat.BigPictureStyle().bigPicture(image)) setLargeIcon(image) @@ -70,13 +73,13 @@ class SaveImageNotifier(private val context: Context) { // Share action addAction( R.drawable.ic_share_24dp, - context.getString(R.string.share), + context.getString(MR.strings.share), NotificationReceiver.shareImagePendingBroadcast(context, file.filePath!!, notificationId), ) // Delete action addAction( R.drawable.ic_delete_24dp, - context.getString(R.string.delete), + context.getString(MR.strings.delete), NotificationReceiver.deleteImagePendingBroadcast(context, file.filePath!!, notificationId), ) @@ -103,8 +106,8 @@ class SaveImageNotifier(private val context: Context) { fun onError(error: String?) { // Create notification with(notificationBuilder) { - setContentTitle(context.getString(R.string.download_error)) - setContentText(error ?: context.getString(R.string.unknown_error)) + setContentTitle(context.getString(MR.strings.download_error)) + setContentText(error ?: context.getString(MR.strings.unknown_error)) setSmallIcon(AR.drawable.ic_menu_report_image) } updateNotification() diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/chapter/ReaderChapterItem.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/chapter/ReaderChapterItem.kt index e7874a4487..aa36934038 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/chapter/ReaderChapterItem.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/chapter/ReaderChapterItem.kt @@ -6,6 +6,9 @@ import androidx.core.graphics.drawable.DrawableCompat import com.mikepenz.fastadapter.FastAdapter import com.mikepenz.fastadapter.items.AbstractItem import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.database.models.Chapter import eu.kanade.tachiyomi.data.database.models.Manga import eu.kanade.tachiyomi.data.preference.PreferencesHelper diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/chapter/ReaderChapterSheet.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/chapter/ReaderChapterSheet.kt index 756c4cdc6f..b09731822d 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/chapter/ReaderChapterSheet.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/chapter/ReaderChapterSheet.kt @@ -18,6 +18,9 @@ import com.mikepenz.fastadapter.FastAdapter import com.mikepenz.fastadapter.adapters.ItemAdapter import com.mikepenz.fastadapter.listeners.ClickEventHook import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.databinding.ReaderChaptersSheetBinding import eu.kanade.tachiyomi.ui.reader.ReaderActivity import eu.kanade.tachiyomi.ui.reader.ReaderViewModel diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/loader/ChapterLoader.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/loader/ChapterLoader.kt index f4962aacbc..944258916c 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/loader/ChapterLoader.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/loader/ChapterLoader.kt @@ -3,7 +3,6 @@ package eu.kanade.tachiyomi.ui.reader.loader import android.content.Context import co.touchlab.kermit.Logger import com.github.junrar.exception.UnsupportedRarV5Exception -import eu.kanade.tachiyomi.R import eu.kanade.tachiyomi.data.database.models.Manga import eu.kanade.tachiyomi.data.download.DownloadManager import eu.kanade.tachiyomi.data.download.DownloadProvider @@ -13,6 +12,8 @@ import eu.kanade.tachiyomi.source.online.HttpSource import eu.kanade.tachiyomi.ui.reader.model.ReaderChapter import eu.kanade.tachiyomi.util.system.openReadOnlyChannel import eu.kanade.tachiyomi.util.system.withIOContext +import yokai.i18n.MR +import yokai.util.lang.getString /** * Loader used to retrieve the [PageLoader] for a given chapter. @@ -45,7 +46,7 @@ class ChapterLoader( .onEach { it.chapter = chapter } if (pages.isEmpty()) { - throw Exception(context.getString(R.string.no_pages_found)) + throw Exception(context.getString(MR.strings.no_pages_found)) } // If the chapter is partially read, set the starting page to the last the user read @@ -85,12 +86,12 @@ class ChapterLoader( is LocalSource.Format.Rar -> try { RarPageLoader(format.file.openInputStream()) } catch (e: UnsupportedRarV5Exception) { - error(context.getString(R.string.loader_rar5_error)) + error(context.getString(MR.strings.loader_rar5_error)) } is LocalSource.Format.Epub -> EpubPageLoader(format.file.openReadOnlyChannel(context)) } } - else -> error(context.getString(R.string.source_not_installed)) + else -> error(context.getString(MR.strings.source_not_installed)) } } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/settings/OrientationType.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/settings/OrientationType.kt index aa402a037a..9fd7618e9c 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/settings/OrientationType.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/settings/OrientationType.kt @@ -3,17 +3,21 @@ package eu.kanade.tachiyomi.ui.reader.settings import android.content.pm.ActivityInfo import androidx.annotation.DrawableRes import androidx.annotation.StringRes +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource private const val SHIFT = 0x00000003 -enum class OrientationType(val prefValue: Int, val flag: Int, @StringRes val stringRes: Int, @DrawableRes val iconRes: Int) { - DEFAULT(0, ActivityInfo.SCREEN_ORIENTATION_UNSPECIFIED, R.string.default_value, R.drawable.ic_screen_rotation_24dp), - FREE(1, ActivityInfo.SCREEN_ORIENTATION_UNSPECIFIED, R.string.free, R.drawable.ic_screen_rotation_24dp), - PORTRAIT(2, ActivityInfo.SCREEN_ORIENTATION_SENSOR_PORTRAIT, R.string.portrait, R.drawable.ic_stay_current_portrait_24dp), - LANDSCAPE(3, ActivityInfo.SCREEN_ORIENTATION_SENSOR_LANDSCAPE, R.string.landscape, R.drawable.ic_stay_current_landscape_24dp), - LOCKED_PORTRAIT(4, ActivityInfo.SCREEN_ORIENTATION_PORTRAIT, R.string.locked_portrait, R.drawable.ic_screen_lock_portrait_24dp), - LOCKED_LANDSCAPE(5, ActivityInfo.SCREEN_ORIENTATION_LANDSCAPE, R.string.locked_landscape, R.drawable.ic_screen_lock_landscape_24dp), +enum class OrientationType(val prefValue: Int, val flag: Int, val stringRes: StringResource, @DrawableRes val iconRes: Int) { + DEFAULT(0, ActivityInfo.SCREEN_ORIENTATION_UNSPECIFIED, MR.strings.default_value, R.drawable.ic_screen_rotation_24dp), + FREE(1, ActivityInfo.SCREEN_ORIENTATION_UNSPECIFIED, MR.strings.free, R.drawable.ic_screen_rotation_24dp), + PORTRAIT(2, ActivityInfo.SCREEN_ORIENTATION_SENSOR_PORTRAIT, MR.strings.portrait, R.drawable.ic_stay_current_portrait_24dp), + LANDSCAPE(3, ActivityInfo.SCREEN_ORIENTATION_SENSOR_LANDSCAPE, MR.strings.landscape, R.drawable.ic_stay_current_landscape_24dp), + LOCKED_PORTRAIT(4, ActivityInfo.SCREEN_ORIENTATION_PORTRAIT, MR.strings.locked_portrait, R.drawable.ic_screen_lock_portrait_24dp), + LOCKED_LANDSCAPE(5, ActivityInfo.SCREEN_ORIENTATION_LANDSCAPE, MR.strings.locked_landscape, R.drawable.ic_screen_lock_landscape_24dp), ; val flagValue = prefValue shl SHIFT diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/settings/PageLayout.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/settings/PageLayout.kt index b8ce3427a5..0573fb1851 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/settings/PageLayout.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/settings/PageLayout.kt @@ -1,22 +1,24 @@ package eu.kanade.tachiyomi.ui.reader.settings import androidx.annotation.StringRes +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource enum class PageLayout( val value: Int, val webtoonValue: Int, - @StringRes val stringRes: Int, - @StringRes private val _fullStringRes: Int? = null, + val stringRes: StringResource, + private val _fullStringRes: StringResource? = null, ) { - SINGLE_PAGE(0, 0, R.string.single_page), - DOUBLE_PAGES(1, 2, R.string.double_pages), - AUTOMATIC(2, 3, R.string.automatic, R.string.automatic_orientation), - SPLIT_PAGES(3, 1, R.string.split_double_pages), - + SINGLE_PAGE(0, 0, MR.strings.single_page), + DOUBLE_PAGES(1, 2, MR.strings.double_pages), + AUTOMATIC(2, 3, MR.strings.automatic, MR.strings.automatic_orientation), + SPLIT_PAGES(3, 1, MR.strings.split_double_pages), ; - @StringRes val fullStringRes = _fullStringRes ?: stringRes companion object { diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/settings/ReaderBackgroundColor.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/settings/ReaderBackgroundColor.kt index 460fcf1645..c6576ce9f6 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/settings/ReaderBackgroundColor.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/settings/ReaderBackgroundColor.kt @@ -1,14 +1,18 @@ package eu.kanade.tachiyomi.ui.reader.settings import androidx.annotation.StringRes +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource -enum class ReaderBackgroundColor(val prefValue: Int, @StringRes val stringRes: Int, @StringRes val longStringRes: Int? = null) { - WHITE(0, R.string.white), - GRAY(4, R.string.gray_background), - BLACK(1, R.string.black), - SMART_PAGE(2, R.string.smart_by_page, R.string.smart_based_on_page), - SMART_THEME(3, R.string.smart_by_theme, R.string.smart_based_on_page_and_theme), +enum class ReaderBackgroundColor(val prefValue: Int, val stringRes: StringResource, val longStringRes: StringResource? = null) { + WHITE(0, MR.strings.white), + GRAY(4, MR.strings.gray_background), + BLACK(1, MR.strings.black), + SMART_PAGE(2, MR.strings.smart_by_page, MR.strings.smart_based_on_page), + SMART_THEME(3, MR.strings.smart_by_theme, MR.strings.smart_based_on_page_and_theme), ; val isSmartColor get() = this == SMART_PAGE || this == SMART_THEME diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/settings/ReaderBottomButton.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/settings/ReaderBottomButton.kt index a60f60253b..c8b88fbf2a 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/settings/ReaderBottomButton.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/settings/ReaderBottomButton.kt @@ -1,17 +1,21 @@ package eu.kanade.tachiyomi.ui.reader.settings import androidx.annotation.StringRes +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource -enum class ReaderBottomButton(val value: String, @StringRes val stringRes: Int) { - ViewChapters("vc", R.string.view_chapters), - WebView("wb", R.string.open_in_webview), - ReadingMode("rm", R.string.reading_mode), - Rotation("rot", R.string.rotation), - CropBordersPaged("cbp", R.string.crop_borders_paged), - CropBordersWebtoon("cbw", R.string.crop_borders_long_strip), - PageLayout("pl", R.string.page_layout), - ShiftDoublePage("sdp", R.string.shift_double_pages), +enum class ReaderBottomButton(val value: String, val stringRes: StringResource) { + ViewChapters("vc", MR.strings.view_chapters), + WebView("wb", MR.strings.open_in_webview), + ReadingMode("rm", MR.strings.reading_mode), + Rotation("rot", MR.strings.rotation), + CropBordersPaged("cbp", MR.strings.crop_borders_paged), + CropBordersWebtoon("cbw", MR.strings.crop_borders_long_strip), + PageLayout("pl", MR.strings.page_layout), + ShiftDoublePage("sdp", MR.strings.shift_double_pages), ; diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/settings/ReaderGeneralView.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/settings/ReaderGeneralView.kt index 85f9a4cbf9..add6f8c5d0 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/settings/ReaderGeneralView.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/settings/ReaderGeneralView.kt @@ -9,6 +9,7 @@ import eu.kanade.tachiyomi.util.bindToPreference import eu.kanade.tachiyomi.util.lang.addBetaTag import eu.kanade.tachiyomi.util.system.DeviceUtil import eu.kanade.tachiyomi.widget.BaseReaderSettingsView +import yokai.util.lang.getString class ReaderGeneralView @JvmOverloads constructor(context: Context, attrs: AttributeSet? = null) : BaseReaderSettingsView(context, attrs) { diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/settings/ReaderPagedView.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/settings/ReaderPagedView.kt index 05525d6573..cbeed00cc1 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/settings/ReaderPagedView.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/settings/ReaderPagedView.kt @@ -7,6 +7,9 @@ import android.util.AttributeSet import androidx.core.view.isVisible import com.davemorrissey.labs.subscaleview.SubsamplingScaleImageView import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.databinding.ReaderPagedLayoutBinding import eu.kanade.tachiyomi.ui.reader.ReaderActivity import eu.kanade.tachiyomi.util.bindToPreference @@ -35,7 +38,7 @@ class ReaderPagedView @JvmOverloads constructor(context: Context, attrs: Attribu pagerNav.bindToPreference(preferences.navigationModePager()) pagerInvert.bindToPreference(preferences.pagerNavInverted()) extendPastCutout.bindToPreference(readerPreferences.pagerCutoutBehavior()) - extendPastCutoutLandscape.title = binding.extendPastCutoutLandscape.title.toString() + "(${context.getString(R.string.landscape)})" + extendPastCutoutLandscape.title = binding.extendPastCutoutLandscape.title.toString() + "(${context.getString(MR.strings.landscape)})" extendPastCutoutLandscape.bindToPreference(readerPreferences.landscapeCutoutBehavior()) { needsActivityRecreate = true } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/settings/ReadingModeType.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/settings/ReadingModeType.kt index da3b6b5377..94e4b400e3 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/settings/ReadingModeType.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/settings/ReadingModeType.kt @@ -2,18 +2,22 @@ package eu.kanade.tachiyomi.ui.reader.settings import androidx.annotation.DrawableRes import androidx.annotation.StringRes +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.util.lang.next private const val SHIFT = 0x00000000 -enum class ReadingModeType(val prefValue: Int, @StringRes val stringRes: Int, @DrawableRes val iconRes: Int) { - DEFAULT(0, R.string.default_value, R.drawable.ic_reader_default_24dp), - LEFT_TO_RIGHT(1, R.string.left_to_right_viewer, R.drawable.ic_reader_ltr_24dp), - RIGHT_TO_LEFT(2, R.string.right_to_left_viewer, R.drawable.ic_reader_rtl_24dp), - VERTICAL(3, R.string.vertical_viewer, R.drawable.ic_reader_vertical_24dp), - LONG_STRIP(4, R.string.long_strip, R.drawable.ic_reader_webtoon_24dp), - CONTINUOUS_VERTICAL(5, R.string.continuous_vertical, R.drawable.ic_reader_continuous_vertical_24dp), +enum class ReadingModeType(val prefValue: Int, val stringRes: StringResource, @DrawableRes val iconRes: Int) { + DEFAULT(0, MR.strings.default_value, R.drawable.ic_reader_default_24dp), + LEFT_TO_RIGHT(1, MR.strings.left_to_right_viewer, R.drawable.ic_reader_ltr_24dp), + RIGHT_TO_LEFT(2, MR.strings.right_to_left_viewer, R.drawable.ic_reader_rtl_24dp), + VERTICAL(3, MR.strings.vertical_viewer, R.drawable.ic_reader_vertical_24dp), + LONG_STRIP(4, MR.strings.long_strip, R.drawable.ic_reader_webtoon_24dp), + CONTINUOUS_VERTICAL(5, MR.strings.continuous_vertical, R.drawable.ic_reader_continuous_vertical_24dp), ; val flagValue = prefValue shl SHIFT diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/settings/TabbedReaderSettingsSheet.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/settings/TabbedReaderSettingsSheet.kt index 06bd203774..ec54040fa8 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/settings/TabbedReaderSettingsSheet.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/settings/TabbedReaderSettingsSheet.kt @@ -7,7 +7,11 @@ import androidx.core.content.ContextCompat import androidx.core.view.isInvisible import androidx.core.view.isVisible import com.google.android.material.tabs.TabLayout +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.databinding.ReaderColorFilterBinding import eu.kanade.tachiyomi.ui.main.SearchActivity import eu.kanade.tachiyomi.ui.reader.ReaderActivity @@ -60,10 +64,10 @@ class TabbedReaderSettingsSheet( filterView, ) - override fun getTabTitles(): List = listOf( - R.string.general, - if (showWebtoonView) R.string.long_strip else R.string.paged, - R.string.filter, + override fun getTabTitles(): List = listOf( + MR.strings.general, + if (showWebtoonView) MR.strings.long_strip else MR.strings.paged, + MR.strings.filter, ) init { @@ -83,7 +87,7 @@ class TabbedReaderSettingsSheet( binding.menu.isVisible = true if (android.os.Build.VERSION.SDK_INT >= android.os.Build.VERSION_CODES.O) { - binding.menu.tooltipText = context.getString(R.string.reader_settings) + binding.menu.tooltipText = context.getString(MR.strings.reader_settings) } binding.menu.setImageDrawable( ContextCompat.getDrawable( diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/viewer/ReaderButton.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/viewer/ReaderButton.kt index 81505098d4..1b0f914dcf 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/viewer/ReaderButton.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/viewer/ReaderButton.kt @@ -6,6 +6,9 @@ import android.util.AttributeSet import android.view.MotionEvent import com.google.android.material.button.MaterialButton import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.ui.reader.viewer.pager.PagerViewer /** diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/viewer/ReaderTransitionView.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/viewer/ReaderTransitionView.kt index 6a1befb0cc..232591e828 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/viewer/ReaderTransitionView.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/viewer/ReaderTransitionView.kt @@ -12,6 +12,9 @@ import androidx.core.text.buildSpannedString import androidx.core.text.inSpans import androidx.core.view.isVisible import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.database.models.Manga import eu.kanade.tachiyomi.data.download.DownloadManager import eu.kanade.tachiyomi.data.preference.PreferencesHelper @@ -61,18 +64,18 @@ class ReaderTransitionView @JvmOverloads constructor(context: Context, attrs: At val isPrevDownloaded = downloadManager.isChapterDownloaded(prevChapter.chapter, manga) val isCurrentDownloaded = downloadManager.isChapterDownloaded(transition.from.chapter, manga) binding.upperText.text = buildSpannedString { - bold { append(context.getString(R.string.previous_title)) } + bold { append(context.getString(MR.strings.previous_title)) } append("\n${prevChapter.chapter.preferredChapterName(context, manga, preferences)}") if (isPrevDownloaded != isCurrentDownloaded) addDLImageSpan(isPrevDownloaded) } binding.lowerText.text = buildSpannedString { - bold { append(context.getString(R.string.current_chapter)) } + bold { append(context.getString(MR.strings.current_chapter)) } val name = transition.from.chapter.preferredChapterName(context, manga, preferences) append("\n$name") } } else { binding.upperText.textAlignment = TEXT_ALIGNMENT_CENTER - binding.upperText.text = context.getString(R.string.theres_no_previous_chapter) + binding.upperText.text = context.getString(MR.strings.theres_no_previous_chapter) } } @@ -92,18 +95,18 @@ class ReaderTransitionView @JvmOverloads constructor(context: Context, attrs: At val isCurrentDownloaded = downloadManager.isChapterDownloaded(transition.from.chapter, manga) val isNextDownloaded = downloadManager.isChapterDownloaded(nextChapter.chapter, manga) binding.upperText.text = buildSpannedString { - bold { append(context.getString(R.string.finished_chapter)) } + bold { append(context.getString(MR.strings.finished_chapter)) } val name = transition.from.chapter.preferredChapterName(context, manga, preferences) append("\n$name") } binding.lowerText.text = buildSpannedString { - bold { append(context.getString(R.string.next_title)) } + bold { append(context.getString(MR.strings.next_title)) } append("\n${nextChapter.chapter.preferredChapterName(context, manga, preferences)}") if (isNextDownloaded != isCurrentDownloaded) addDLImageSpan(isNextDownloaded) } } else { binding.upperText.textAlignment = TEXT_ALIGNMENT_CENTER - binding.upperText.text = context.getString(R.string.theres_no_next_chapter) + binding.upperText.text = context.getString(MR.strings.theres_no_next_chapter) } } @@ -148,7 +151,7 @@ class ReaderTransitionView @JvmOverloads constructor(context: Context, attrs: At is ChapterTransition.Next -> calculateChapterDifference(transition.to, transition.from) } - binding.warningText.text = resources.getQuantityString(R.plurals.missing_chapters_warning, chapterDifference.toInt(), chapterDifference.toInt()) + binding.warningText.text = context.getString(MR.plurals.missing_chapters_warning, chapterDifference.toInt(), chapterDifference.toInt()) binding.warning.isVisible = true } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/viewer/ViewerNavigation.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/viewer/ViewerNavigation.kt index 3ca5761f11..b25dfaa6d5 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/viewer/ViewerNavigation.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/viewer/ViewerNavigation.kt @@ -3,16 +3,20 @@ package eu.kanade.tachiyomi.ui.reader.viewer import android.graphics.PointF import android.graphics.RectF import androidx.annotation.StringRes +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource abstract class ViewerNavigation { - sealed class NavigationRegion(@StringRes val nameRes: Int, val colorRes: Int) { - object MENU : NavigationRegion(R.string.menu, R.color.navigation_menu) - object PREV : NavigationRegion(R.string.previous, R.color.navigation_prev) - object NEXT : NavigationRegion(R.string.next, R.color.navigation_next) - object LEFT : NavigationRegion(R.string.left, R.color.navigation_next) - object RIGHT : NavigationRegion(R.string.right, R.color.navigation_prev) + sealed class NavigationRegion(val nameRes: StringResource, val colorRes: Int) { + object MENU : NavigationRegion(MR.strings.menu, R.color.navigation_menu) + object PREV : NavigationRegion(MR.strings.previous, R.color.navigation_prev) + object NEXT : NavigationRegion(MR.strings.next, R.color.navigation_next) + object LEFT : NavigationRegion(MR.strings.left, R.color.navigation_next) + object RIGHT : NavigationRegion(MR.strings.right, R.color.navigation_prev) fun directionalRegion(LTR: Boolean): NavigationRegion { return if (this === LEFT || this === RIGHT) { diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/viewer/pager/PagerTransitionHolder.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/viewer/pager/PagerTransitionHolder.kt index f234446a44..de714da331 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/viewer/pager/PagerTransitionHolder.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/viewer/pager/PagerTransitionHolder.kt @@ -13,11 +13,15 @@ import androidx.compose.material3.CircularProgressIndicator import androidx.compose.ui.platform.ComposeView import androidx.core.view.updatePaddingRelative import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.ui.reader.model.ChapterTransition import eu.kanade.tachiyomi.ui.reader.model.ReaderChapter import eu.kanade.tachiyomi.ui.reader.viewer.ReaderButton import eu.kanade.tachiyomi.ui.reader.viewer.ReaderTransitionView import eu.kanade.tachiyomi.util.system.dpToPx +import eu.kanade.tachiyomi.util.view.setText import eu.kanade.tachiyomi.widget.ViewPagerAdapter import kotlinx.coroutines.Job import kotlinx.coroutines.MainScope @@ -115,7 +119,7 @@ class PagerTransitionHolder( val textView = AppCompatTextView(context).apply { wrapContent() - setText(R.string.loading_pages) + setText(MR.strings.loading_pages) } pagesContainer.addView(progress) @@ -128,13 +132,13 @@ class PagerTransitionHolder( private fun setError(error: Throwable) { val textView = AppCompatTextView(context).apply { wrapContent() - text = context.getString(R.string.failed_to_load_pages_, error.message) + text = context.getString(MR.strings.failed_to_load_pages_, error.message ?: "") } val retryBtn = ReaderButton(context).apply { viewer = this@PagerTransitionHolder.viewer wrapContent() - setText(R.string.retry) + setText(MR.strings.retry) setOnClickListener { val toChapter = transition.to if (toChapter != null) { diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/viewer/pager/PagerViewer.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/viewer/pager/PagerViewer.kt index 7ba94dfa07..9e37de45fc 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/viewer/pager/PagerViewer.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/viewer/pager/PagerViewer.kt @@ -11,6 +11,9 @@ import androidx.core.view.isVisible import androidx.viewpager.widget.ViewPager import co.touchlab.kermit.Logger import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.download.DownloadManager import eu.kanade.tachiyomi.ui.reader.ReaderActivity import eu.kanade.tachiyomi.ui.reader.model.ChapterTransition diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/viewer/webtoon/WebtoonTransitionHolder.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/viewer/webtoon/WebtoonTransitionHolder.kt index c508a1c506..2f37d4dffd 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/reader/viewer/webtoon/WebtoonTransitionHolder.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/reader/viewer/webtoon/WebtoonTransitionHolder.kt @@ -12,10 +12,14 @@ import androidx.compose.ui.platform.ComposeView import androidx.core.view.isNotEmpty import androidx.core.view.isVisible import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.ui.reader.model.ChapterTransition import eu.kanade.tachiyomi.ui.reader.model.ReaderChapter import eu.kanade.tachiyomi.ui.reader.viewer.ReaderTransitionView import eu.kanade.tachiyomi.util.system.dpToPx +import eu.kanade.tachiyomi.util.view.setText import kotlinx.coroutines.Job import kotlinx.coroutines.MainScope import kotlinx.coroutines.flow.collectLatest @@ -113,7 +117,7 @@ class WebtoonTransitionHolder( val textView = AppCompatTextView(context).apply { wrapContent() - setText(R.string.loading_pages) + setText(MR.strings.loading_pages) } pagesContainer.addView(progress) @@ -133,12 +137,12 @@ class WebtoonTransitionHolder( private fun setError(error: Throwable, transition: ChapterTransition) { val textView = AppCompatTextView(context).apply { wrapContent() - text = context.getString(R.string.failed_to_load_pages_, error.message) + text = context.getString(MR.strings.failed_to_load_pages_, error.message ?: "") } val retryBtn = AppCompatButton(context).apply { wrapContent() - setText(R.string.retry) + setText(MR.strings.retry) setOnClickListener { val toChapter = transition.to if (toChapter != null) { diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/recents/DateItem.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/recents/DateItem.kt index d7db5dd654..444520f7e9 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/recents/DateItem.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/recents/DateItem.kt @@ -14,7 +14,9 @@ import eu.kanade.tachiyomi.R import eu.kanade.tachiyomi.util.system.dpToPx import eu.kanade.tachiyomi.util.system.spToPx import eu.kanade.tachiyomi.util.system.timeSpanFromNow -import java.util.Date +import yokai.i18n.MR +import yokai.util.lang.getString +import java.util.* class DateItem(val date: Date, val addedString: Boolean = false) : AbstractHeaderItem() { @@ -56,14 +58,14 @@ class DateItem(val date: Date, val addedString: Boolean = false) : AbstractHeade fun bind(item: DateItem) { val dateString = DateUtils.getRelativeTimeSpanString(item.date.time, now, DateUtils.DAY_IN_MILLIS) sectionText.text = - if (item.addedString) itemView.context.getString(R.string.fetched_, dateString) else dateString + if (item.addedString) itemView.context.getString(MR.strings.fetched_, dateString) else dateString lastUpdatedText.isVisible = false if (bindingAdapterPosition == 0) { sectionText.updatePadding( top = if (adapter.lastUpdatedTime > 0L) { lastUpdatedText.isVisible = true lastUpdatedText.text = lastUpdatedText.context.timeSpanFromNow( - R.string.updates_last_update_info, + MR.strings.updates_last_update_info, adapter.lastUpdatedTime, ) 18.spToPx + 8.dpToPx diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/recents/RecentMangaFooterHolder.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/recents/RecentMangaFooterHolder.kt index 049e546624..ed1841b746 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/recents/RecentMangaFooterHolder.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/recents/RecentMangaFooterHolder.kt @@ -2,8 +2,12 @@ package eu.kanade.tachiyomi.ui.recents import android.view.View import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.databinding.RecentsFooterItemBinding import eu.kanade.tachiyomi.ui.manga.chapter.BaseChapterHolder +import eu.kanade.tachiyomi.util.view.setText class RecentMangaFooterHolder( view: View, @@ -14,10 +18,10 @@ class RecentMangaFooterHolder( fun bind(recentsType: Int) { when (recentsType) { RecentMangaHeaderItem.CONTINUE_READING -> { - binding.title.setText(R.string.view_history) + binding.title.setText(MR.strings.view_history) } RecentMangaHeaderItem.NEW_CHAPTERS -> { - binding.title.setText(R.string.view_all_updates) + binding.title.setText(MR.strings.view_all_updates) } } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/recents/RecentMangaHeaderItem.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/recents/RecentMangaHeaderItem.kt index 02b0ab84ed..b638e7bbaf 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/recents/RecentMangaHeaderItem.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/recents/RecentMangaHeaderItem.kt @@ -6,9 +6,13 @@ import eu.davidea.flexibleadapter.FlexibleAdapter import eu.davidea.flexibleadapter.items.AbstractHeaderItem import eu.davidea.flexibleadapter.items.IFlexible import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.databinding.RecentsHeaderItemBinding import eu.kanade.tachiyomi.ui.base.holder.BaseFlexibleViewHolder import eu.kanade.tachiyomi.ui.library.LibraryHeaderItem +import eu.kanade.tachiyomi.util.view.setText class RecentMangaHeaderItem(val recentsType: Int) : AbstractHeaderItem() { @@ -64,10 +68,10 @@ class RecentMangaHeaderItem(val recentsType: Int) : fun bind(recentsType: Int) { binding.title.setText( when (recentsType) { - CONTINUE_READING -> R.string.continue_reading - NEW_CHAPTERS -> R.string.new_chapters - NEWLY_ADDED -> R.string.newly_added - else -> R.string.continue_reading + CONTINUE_READING -> MR.strings.continue_reading + NEW_CHAPTERS -> MR.strings.new_chapters + NEWLY_ADDED -> MR.strings.newly_added + else -> MR.strings.continue_reading }, ) } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/recents/RecentMangaHolder.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/recents/RecentMangaHolder.kt index e2cf91adf4..5fae0db110 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/recents/RecentMangaHolder.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/recents/RecentMangaHolder.kt @@ -16,6 +16,9 @@ import androidx.core.view.updatePaddingRelative import androidx.transition.TransitionManager import androidx.transition.TransitionSet import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.coil.loadManga import eu.kanade.tachiyomi.data.database.models.Chapter import eu.kanade.tachiyomi.data.database.models.ChapterHistory @@ -186,28 +189,28 @@ class RecentMangaHolder( binding.body.isVisible = !isSmallUpdates binding.body.text = when { - item.mch.chapter.id == null -> context.timeSpanFromNow(R.string.added_, item.mch.manga.date_added) + item.mch.chapter.id == null -> context.timeSpanFromNow(MR.strings.added_, item.mch.manga.date_added) isSmallUpdates -> "" item.mch.history.id == null -> { if (isUpdates) { if (adapter.sortByFetched) { - context.timeSpanFromNow(R.string.fetched_, item.chapter.date_fetch) + context.timeSpanFromNow(MR.strings.fetched_, item.chapter.date_fetch) } else { - context.timeSpanFromNow(R.string.updated_, item.chapter.date_upload) + context.timeSpanFromNow(MR.strings.updated_, item.chapter.date_upload) } } else { - context.timeSpanFromNow(R.string.fetched_, item.chapter.date_fetch) + "\n" + - context.timeSpanFromNow(R.string.updated_, item.chapter.date_upload) + context.timeSpanFromNow(MR.strings.fetched_, item.chapter.date_fetch) + "\n" + + context.timeSpanFromNow(MR.strings.updated_, item.chapter.date_upload) } } item.chapter.id != item.mch.chapter.id -> readLastText(!moreVisible) - item.chapter.pages_left > 0 && !item.chapter.read -> context.timeSpanFromNow(R.string.read_, item.mch.history.last_read) + - "\n" + itemView.resources.getQuantityString( - R.plurals.pages_left, + item.chapter.pages_left > 0 && !item.chapter.read -> context.timeSpanFromNow(MR.strings.read_, item.mch.history.last_read) + + "\n" + itemView.context.getString( + MR.plurals.pages_left, item.chapter.pages_left, item.chapter.pages_left, ) - else -> context.timeSpanFromNow(R.string.read_, item.mch.history.last_read) + else -> context.timeSpanFromNow(MR.strings.read_, item.mch.history.last_read) } if ((context as? Activity)?.isDestroyed != true) { binding.coverThumbnail.loadManga(item.mch.manga) @@ -283,8 +286,8 @@ class RecentMangaHolder( private fun addMoreUpdatesText(add: Boolean, originalItem: RecentMangaItem? = null) { val item = originalItem ?: adapter.getItem(bindingAdapterPosition) as? RecentMangaItem ?: return val originalText = binding.body.text.toString() - val andMoreText = itemView.context.resources.getQuantityString( - R.plurals.notification_and_n_more, + val andMoreText = itemView.context.getString( + MR.plurals.notification_and_n_more, (item.mch.extraChapters.size), (item.mch.extraChapters.size), ) @@ -303,11 +306,11 @@ class RecentMangaHolder( val notValidNum = item.mch.chapter.chapter_number <= 0 return if (item.chapter.id != item.mch.chapter.id) { if (show) { - itemView.context.timeSpanFromNow(R.string.read_, item.mch.history.last_read) + "\n" + itemView.context.timeSpanFromNow(MR.strings.read_, item.mch.history.last_read) + "\n" } else { "" } + itemView.context.getString( - if (notValidNum) R.string.last_read_ else R.string.last_read_chapter_, + if (notValidNum) MR.strings.last_read_ else MR.strings.last_read_chapter_, if (notValidNum) item.mch.chapter.name else adapter.decimalFormat.format(item.mch.chapter.chapter_number), ) } else { "" } @@ -344,7 +347,7 @@ class RecentMangaHolder( private fun RecentSubChapterItemBinding.configureBlankView(count: Int) { val context = itemView.context title.text = - context.resources.getQuantityString(R.plurals.notification_and_n_more, count, count) + context.getString(MR.plurals.notification_and_n_more, count, count) downloadButton.root.isVisible = false downloadButton.root.tag = null title.textSize = 13f @@ -377,7 +380,7 @@ class RecentMangaHolder( ChapterUtil.setTextViewForChapter(title, chapter) val notReadYet = item.chapter.id != item.mch.chapter.id && item.mch.history.id != null subtitle.text = chapter.history?.let { history -> - context.timeSpanFromNow(R.string.read_, history.last_read) + context.timeSpanFromNow(MR.strings.read_, history.last_read) .takeIf { Date().time - history.last_read < TimeUnit.DAYS.toMillis(1) || notReadYet || adapter.dateFormat.run { diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/recents/RecentMangaItem.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/recents/RecentMangaItem.kt index 054a0edd01..e48f891c5c 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/recents/RecentMangaItem.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/recents/RecentMangaItem.kt @@ -6,6 +6,9 @@ import eu.davidea.flexibleadapter.FlexibleAdapter import eu.davidea.flexibleadapter.items.AbstractHeaderItem import eu.davidea.flexibleadapter.items.IFlexible import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.database.models.Chapter import eu.kanade.tachiyomi.data.database.models.ChapterImpl import eu.kanade.tachiyomi.data.database.models.MangaChapterHistory diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/recents/RecentsController.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/recents/RecentsController.kt index 7e4b851f8f..e2b53e6516 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/recents/RecentsController.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/recents/RecentsController.kt @@ -30,6 +30,9 @@ import com.google.android.material.snackbar.Snackbar import com.google.android.material.tabs.TabLayout import eu.davidea.flexibleadapter.FlexibleAdapter import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.backup.restore.BackupRestoreJob import eu.kanade.tachiyomi.data.database.models.Chapter import eu.kanade.tachiyomi.data.database.models.ChapterHistory @@ -80,7 +83,9 @@ import eu.kanade.tachiyomi.util.view.isHidden import eu.kanade.tachiyomi.util.view.moveRecyclerViewUp import eu.kanade.tachiyomi.util.view.onAnimationsFinished import eu.kanade.tachiyomi.util.view.scrollViewWith +import eu.kanade.tachiyomi.util.view.setAction import eu.kanade.tachiyomi.util.view.setOnQueryTextChangeListener +import eu.kanade.tachiyomi.util.view.setPositiveButton import eu.kanade.tachiyomi.util.view.setStyle import eu.kanade.tachiyomi.util.view.smoothScrollToTop import eu.kanade.tachiyomi.util.view.snack @@ -139,16 +144,16 @@ class RecentsController(bundle: Bundle? = null) : get() = binding.recycler override fun getTitle(): String? { - return view?.context?.getString(R.string.recents) + return view?.context?.getString(MR.strings.recents) } override fun getSearchTitle(): String? { return searchTitle( view?.context?.getString( when (presenter.viewType) { - RecentsViewType.History -> R.string.history - RecentsViewType.Updates -> R.string.updates - else -> R.string.updates_and_history + RecentsViewType.History -> MR.strings.history + RecentsViewType.Updates -> MR.strings.updates + else -> MR.strings.updates_and_history }, )?.lowercase(Locale.ROOT), ) @@ -392,14 +397,14 @@ class RecentsController(bundle: Bundle? = null) : binding.swipeRefresh.setOnRefreshListener { if (!LibraryUpdateJob.isRunning(view.context)) { snack?.dismiss() - snack = view.snack(R.string.updating_library) { + snack = view.snack(MR.strings.updating_library) { anchorView = if (binding.downloadBottomSheet.root.sheetBehavior.isCollapsed()) { binding.downloadBottomSheet.root } else { activityBinding?.bottomNav ?: binding.downloadBottomSheet.root } - setAction(R.string.cancel) { + setAction(MR.strings.cancel) { LibraryUpdateJob.stop(context) viewScope.launchUI { NotificationReceiver.dismissNotification( @@ -423,7 +428,7 @@ class RecentsController(bundle: Bundle? = null) : } private fun setSheetToolbar() { - binding.downloadBottomSheet.sheetToolbar.title = view?.context?.getString(R.string.download_queue) + binding.downloadBottomSheet.sheetToolbar.title = view?.context?.getString(MR.strings.download_queue) binding.downloadBottomSheet.sheetToolbar.overflowIcon?.setTint(view?.context?.getResourceColor(R.attr.actionBarTintColor) ?: Color.BLACK) binding.downloadBottomSheet.sheetToolbar.setOnMenuItemClickListener { item -> return@setOnMenuItemClickListener binding.downloadBottomSheet.dlBottomSheet.onOptionsItemSelected(item) @@ -596,12 +601,12 @@ class RecentsController(bundle: Bundle? = null) : R.drawable.ic_search_off_24dp }, if (isSearching()) { - R.string.no_results_found + MR.strings.no_results_found } else { when (presenter.viewType) { - RecentsViewType.Updates -> R.string.no_recent_chapters - RecentsViewType.History -> R.string.no_recently_read_manga - else -> R.string.no_recent_read_updated_manga + RecentsViewType.Updates -> MR.strings.no_recent_chapters + RecentsViewType.History -> MR.strings.no_recently_read_manga + else -> MR.strings.no_recent_read_updated_manga } }, ) @@ -801,20 +806,20 @@ class RecentsController(bundle: Bundle? = null) : if (history.id != null) { activity.materialAlertDialog() .setCustomTitleAndMessage( - R.string.reset_chapter_question, + MR.strings.reset_chapter_question, activity.getString( - R.string.this_will_remove_the_read_date_for_x_question, + MR.strings.this_will_remove_the_read_date_for_x_question, chapter.name, ), ) .addCheckBoxPrompt( activity.getString( - R.string.reset_all_chapters_for_this_, + MR.strings.reset_all_chapters_for_this_, manga.seriesType(activity), ), ) .setNegativeButton(AR.string.cancel, null) - .setPositiveButton(R.string.reset) { dialog, _ -> + .setPositiveButton(MR.strings.reset) { dialog, _ -> removeHistory(manga, history, dialog.isPromptChecked) } .show() @@ -853,15 +858,15 @@ class RecentsController(bundle: Bundle? = null) : presenter.markChapterRead(chapter, !wasRead) snack = view?.snack( if (wasRead) { - R.string.marked_as_unread + MR.strings.marked_as_unread } else { - R.string.marked_as_read + MR.strings.marked_as_read }, Snackbar.LENGTH_INDEFINITE, ) { anchorView = activityBinding?.bottomNav var undoing = false - setAction(R.string.undo) { + setAction(MR.strings.undo) { presenter.markChapterRead(chapter, wasRead, lastRead, pagesLeft) undoing = true } @@ -894,7 +899,7 @@ class RecentsController(bundle: Bundle? = null) : val searchItem = activityBinding?.searchToolbar?.searchItem val searchView = activityBinding?.searchToolbar?.searchView - activityBinding?.searchToolbar?.setQueryHint(view?.context?.getString(R.string.search_recents), !isSearching()) + activityBinding?.searchToolbar?.setQueryHint(view?.context?.getString(MR.strings.search_recents), !isSearching()) if (isSearching()) { searchItem?.expandActionView() searchView?.setQuery(query, true) @@ -922,7 +927,7 @@ class RecentsController(bundle: Bundle? = null) : val selectedTab = presenter.viewType RecentsViewType.entries.forEach { viewType -> tabs.addTab( - tabs.newTab().setText(viewType.stringRes).also { tab -> + tabs.newTab().setText(activity?.getString(viewType.stringRes)).also { tab -> tab.view.compatToolTipText = null }, viewType == selectedTab, diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/recents/RecentsPresenter.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/recents/RecentsPresenter.kt index 710ac27497..3951402a85 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/recents/RecentsPresenter.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/recents/RecentsPresenter.kt @@ -1,6 +1,9 @@ package eu.kanade.tachiyomi.ui.recents import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.database.DatabaseHelper import eu.kanade.tachiyomi.data.database.models.Chapter import eu.kanade.tachiyomi.data.database.models.ChapterHistory @@ -675,7 +678,7 @@ class RecentsPresenter( presenterScope.launchIO { db.deleteHistory().executeAsBlocking() withUIContext { - view?.activity?.toast(R.string.clear_history_completed) + view?.activity?.toast(MR.strings.clear_history_completed) getRecents() } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/recents/RecentsViewType.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/recents/RecentsViewType.kt index f4dee965db..d44cfea69e 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/recents/RecentsViewType.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/recents/RecentsViewType.kt @@ -1,13 +1,17 @@ package eu.kanade.tachiyomi.ui.recents import androidx.annotation.StringRes +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource -enum class RecentsViewType(val mainValue: Int, @StringRes val stringRes: Int) { - GroupedAll(0, R.string.grouped), - UngroupedAll(1, R.string.all), - History(2, R.string.history), - Updates(3, R.string.updates), +enum class RecentsViewType(val mainValue: Int, val stringRes: StringResource) { + GroupedAll(0, MR.strings.grouped), + UngroupedAll(1, MR.strings.all), + History(2, MR.strings.history), + Updates(3, MR.strings.updates), ; val isAll get() = this == GroupedAll || this == UngroupedAll diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/recents/options/RecentsGeneralView.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/recents/options/RecentsGeneralView.kt index 67abd9db1d..245aea3966 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/recents/options/RecentsGeneralView.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/recents/options/RecentsGeneralView.kt @@ -3,6 +3,9 @@ package eu.kanade.tachiyomi.ui.recents.options import android.content.Context import android.util.AttributeSet import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.databinding.RecentsGeneralViewBinding import eu.kanade.tachiyomi.util.bindToPreference import eu.kanade.tachiyomi.util.lang.withSubtitle @@ -13,12 +16,12 @@ class RecentsGeneralView @JvmOverloads constructor(context: Context, attrs: Attr override fun inflateBinding() = RecentsGeneralViewBinding.bind(this) override fun initGeneralPreferences() { - val titleText = context.getString(R.string.show_reset_history_button) - val uniformText = context.getString(R.string.uniform_covers) + val titleText = context.getString(MR.strings.show_reset_history_button) + val uniformText = context.getString(MR.strings.uniform_covers) binding.showRemoveHistory.text = titleText - .withSubtitle(binding.showRemoveHistory.context, R.string.press_and_hold_to_also_reset) + .withSubtitle(binding.showRemoveHistory.context, MR.strings.press_and_hold_to_also_reset) binding.uniformCovers.text = uniformText - .withSubtitle(binding.uniformCovers.context, R.string.affects_library_grid) + .withSubtitle(binding.uniformCovers.context, MR.strings.affects_library_grid) binding.showRecentsDownload.bindToPreference(recentsPreferences.showRecentsDownloads()) binding.showRemoveHistory.bindToPreference(recentsPreferences.showRecentsRemHistory()) binding.showReadInAll.bindToPreference(recentsPreferences.showReadInAllRecents()) diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/recents/options/RecentsHistoryView.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/recents/options/RecentsHistoryView.kt index 20fd4578f8..c024bc099a 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/recents/options/RecentsHistoryView.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/recents/options/RecentsHistoryView.kt @@ -3,9 +3,14 @@ package eu.kanade.tachiyomi.ui.recents.options import android.content.Context import android.util.AttributeSet import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.databinding.RecentsHistoryViewBinding import eu.kanade.tachiyomi.util.bindToPreference import eu.kanade.tachiyomi.util.system.materialAlertDialog +import eu.kanade.tachiyomi.util.view.setMessage +import eu.kanade.tachiyomi.util.view.setPositiveButton import eu.kanade.tachiyomi.widget.BaseRecentsDisplayView import android.R as AR @@ -21,8 +26,8 @@ class RecentsHistoryView @JvmOverloads constructor(context: Context, attrs: Attr binding.clearHistory.setOnClickListener { val activity = controller?.activity ?: return@setOnClickListener activity.materialAlertDialog() - .setMessage(R.string.clear_history_confirmation) - .setPositiveButton(R.string.clear) { _, _ -> + .setMessage(MR.strings.clear_history_confirmation) + .setPositiveButton(MR.strings.clear) { _, _ -> controller?.presenter?.deleteAllHistory() } .setNegativeButton(AR.string.cancel, null) diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/recents/options/TabbedRecentsOptionsSheet.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/recents/options/TabbedRecentsOptionsSheet.kt index d7a9cf0f2c..b5cd49909b 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/recents/options/TabbedRecentsOptionsSheet.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/recents/options/TabbedRecentsOptionsSheet.kt @@ -4,7 +4,11 @@ import android.view.View import android.view.View.inflate import androidx.annotation.IntRange import androidx.core.view.isVisible +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.ui.recents.RecentsController import eu.kanade.tachiyomi.widget.TabbedBottomSheetDialog @@ -35,9 +39,9 @@ class TabbedRecentsOptionsSheet(val controller: RecentsController, @IntRange(fro updatesView, ) - override fun getTabTitles(): List = listOf( - R.string.general, - R.string.history, - R.string.updates, + override fun getTabTitles(): List = listOf( + MR.strings.general, + MR.strings.history, + MR.strings.updates, ) } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/security/BiometricActivity.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/security/BiometricActivity.kt index 723f7c3817..d545ffdd4e 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/security/BiometricActivity.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/security/BiometricActivity.kt @@ -3,12 +3,12 @@ package eu.kanade.tachiyomi.ui.security import android.os.Bundle import androidx.biometric.BiometricManager import androidx.biometric.BiometricPrompt -import eu.kanade.tachiyomi.R import eu.kanade.tachiyomi.ui.base.activity.BaseThemedActivity import eu.kanade.tachiyomi.util.system.AuthenticatorUtil -import java.util.Date -import java.util.concurrent.ExecutorService -import java.util.concurrent.Executors +import yokai.i18n.MR +import yokai.util.lang.getString +import java.util.* +import java.util.concurrent.* class BiometricActivity : BaseThemedActivity() { private val executor: ExecutorService = Executors.newSingleThreadExecutor() @@ -44,7 +44,7 @@ class BiometricActivity : BaseThemedActivity() { ) val promptInfo = BiometricPrompt.PromptInfo.Builder() - .setTitle(getString(R.string.unlock_library)) + .setTitle(getString(MR.strings.unlock_library)) .setAllowedAuthenticators(BiometricManager.Authenticators.DEVICE_CREDENTIAL or BiometricManager.Authenticators.BIOMETRIC_WEAK) .build() diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/PreferenceDSL.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/PreferenceDSL.kt index d33423a776..dab01e1497 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/PreferenceDSL.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/PreferenceDSL.kt @@ -16,7 +16,11 @@ import androidx.preference.PreferenceGroup import androidx.preference.PreferenceManager import androidx.preference.PreferenceScreen import androidx.preference.SwitchPreferenceCompat +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.util.system.AuthenticatorUtil import eu.kanade.tachiyomi.util.system.AuthenticatorUtil.isAuthenticationSupported import eu.kanade.tachiyomi.util.system.AuthenticatorUtil.startAuthentication @@ -103,6 +107,18 @@ inline fun PreferenceScreen.switchPreference(block: (@DSL SwitchPreferenceCompat return initThenAdd(SwitchPreferenceCompat(context), block) } +fun PreferenceGroup.infoPreference(infoRes: StringResource): Preference { + return initThenAdd( + Preference(context), + ) { + iconRes = R.drawable.ic_info_outline_24dp + iconTint = context.getResourceColor(AR.attr.textColorSecondary) + summaryMRes = infoRes + isSelectable = false + } +} + +@Deprecated("Use moko-resources instead!") fun PreferenceGroup.infoPreference(@StringRes infoRes: Int): Preference { return initThenAdd( Preference(context), @@ -242,16 +258,30 @@ var Preference.defaultValue: Any? get() = null // set only set(value) { setDefaultValue(value) } +var Preference.titleMRes: StringResource + get() = throw UnsupportedOperationException("Set only!") + set(value) { + title = context.getString(value) + } + +@Deprecated("Use moko-resources instead!") var Preference.titleRes: Int - get() = 0 // set only + get() = throw UnsupportedOperationException("Set only!") set(value) { setTitle(value) } var Preference.iconRes: Int get() = 0 // set only set(value) { icon = AppCompatResources.getDrawable(context, value) } +var Preference.summaryMRes: StringResource + get() = throw UnsupportedOperationException("Set only!") + set(value) { + summary = context.getString(value) + } + +@Deprecated("Use moko-resources instead!") var Preference.summaryRes: Int - get() = 0 // set only + get() = throw UnsupportedOperationException("Set only!") set(value) { setSummary(value) } var Preference.iconTint: Int diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/SettingsControllerInterface.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/SettingsControllerInterface.kt index f4d970449f..788b4576e5 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/SettingsControllerInterface.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/SettingsControllerInterface.kt @@ -5,13 +5,14 @@ import androidx.annotation.StringRes import androidx.appcompat.app.AppCompatActivity import androidx.core.view.isVisible import com.bluelinelabs.conductor.Controller +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.ui.base.controller.BaseLegacyController import eu.kanade.tachiyomi.ui.main.MainActivity import eu.kanade.tachiyomi.util.view.activityBinding +import yokai.util.lang.getString interface SettingsControllerInterface { - @StringRes - fun getTitleRes(): Int? = null + fun getTitleRes(): StringResource? = null fun getTitle(): String? @@ -33,5 +34,5 @@ interface SettingsControllerInterface { } @Suppress("FunctionName") - fun Controller.__getTitle(): String? = getTitleRes()?.let { resources?.getString(it) } + fun Controller.__getTitle(): String? = getTitleRes()?.let { activity?.getString(it) } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/SettingsLegacyController.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/SettingsLegacyController.kt index 0bc0b95ad9..1ba80ed336 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/SettingsLegacyController.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/SettingsLegacyController.kt @@ -17,6 +17,9 @@ import androidx.preference.PreferenceScreen import com.bluelinelabs.conductor.ControllerChangeHandler import com.bluelinelabs.conductor.ControllerChangeType import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.preference.PreferencesHelper import eu.kanade.tachiyomi.data.preference.changesIn import eu.kanade.tachiyomi.ui.base.controller.BaseControllerPreferenceControllerCommonInterface diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/ThemePreference.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/ThemePreference.kt index 5da89350cc..7c664ffbd1 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/ThemePreference.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/ThemePreference.kt @@ -24,6 +24,9 @@ import com.mikepenz.fastadapter.items.AbstractItem import com.mikepenz.fastadapter.select.SelectExtension import com.mikepenz.fastadapter.select.getSelectExtension import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.preference.PreferencesHelper import eu.kanade.tachiyomi.databinding.ThemeItemBinding import eu.kanade.tachiyomi.databinding.ThemesPreferenceBinding @@ -33,6 +36,7 @@ import eu.kanade.tachiyomi.util.system.appDelegateNightMode import eu.kanade.tachiyomi.util.system.dpToPx import eu.kanade.tachiyomi.util.system.getResourceColor import eu.kanade.tachiyomi.util.system.isInNightMode +import eu.kanade.tachiyomi.util.view.setText import uy.kohesive.injekt.injectLazy import kotlin.math.max import android.R as AR diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsAdvancedController.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsAdvancedController.kt index d523be37e9..5236d6aa74 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsAdvancedController.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsAdvancedController.kt @@ -18,6 +18,9 @@ import co.touchlab.kermit.Logger import com.hippo.unifile.UniFile import eu.kanade.tachiyomi.BuildConfig import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.database.DatabaseHelper import eu.kanade.tachiyomi.data.download.DownloadManager import eu.kanade.tachiyomi.data.download.DownloadProvider @@ -51,9 +54,9 @@ import eu.kanade.tachiyomi.ui.setting.onChange import eu.kanade.tachiyomi.ui.setting.onClick import eu.kanade.tachiyomi.ui.setting.preference import eu.kanade.tachiyomi.ui.setting.preferenceCategory -import eu.kanade.tachiyomi.ui.setting.summaryRes +import eu.kanade.tachiyomi.ui.setting.summaryMRes as summaryRes import eu.kanade.tachiyomi.ui.setting.switchPreference -import eu.kanade.tachiyomi.ui.setting.titleRes +import eu.kanade.tachiyomi.ui.setting.titleMRes as titleRes import eu.kanade.tachiyomi.util.CrashLogUtil import eu.kanade.tachiyomi.util.system.disableItems import eu.kanade.tachiyomi.util.system.e @@ -65,6 +68,9 @@ import eu.kanade.tachiyomi.util.system.materialAlertDialog import eu.kanade.tachiyomi.util.system.setDefaultSettings import eu.kanade.tachiyomi.util.system.toast import eu.kanade.tachiyomi.util.view.openInBrowser +import eu.kanade.tachiyomi.util.view.setMessage +import eu.kanade.tachiyomi.util.view.setPositiveButton +import eu.kanade.tachiyomi.util.view.setTitle import eu.kanade.tachiyomi.util.view.withFadeTransaction import kotlinx.coroutines.CoroutineStart import kotlinx.coroutines.DelicateCoroutinesApi @@ -100,18 +106,18 @@ class SettingsAdvancedController : SettingsLegacyController() { @SuppressLint("BatteryLife") override fun setupPreferenceScreen(screen: PreferenceScreen) = screen.apply { - titleRes = R.string.advanced + titleRes = MR.strings.advanced switchPreference { bindTo(basePreferences.crashReport()) - titleRes = R.string.send_crash_report - summaryRes = R.string.helps_fix_bugs + titleRes = MR.strings.send_crash_report + summaryRes = MR.strings.helps_fix_bugs } preference { key = "dump_crash_logs" - titleRes = R.string.dump_crash_logs - summaryRes = R.string.saves_error_logs + titleRes = MR.strings.dump_crash_logs + summaryRes = MR.strings.saves_error_logs onClick { (activity as? AppCompatActivity)?.lifecycleScope?.launchIO { @@ -122,7 +128,7 @@ class SettingsAdvancedController : SettingsLegacyController() { preference { key = "debug_info" - titleRes = R.string.pref_debug_info + titleRes = MR.strings.pref_debug_info onClick { router.pushController(DebugController().withFadeTransaction()) @@ -130,13 +136,13 @@ class SettingsAdvancedController : SettingsLegacyController() { } preferenceCategory { - titleRes = R.string.label_background_activity + titleRes = MR.strings.label_background_activity val pm = context.getSystemService(Context.POWER_SERVICE) as? PowerManager? if (pm != null) { preference { key = "disable_batt_opt" - titleRes = R.string.disable_battery_optimization - summaryRes = R.string.disable_if_issues_with_updating + titleRes = MR.strings.disable_battery_optimization + summaryRes = MR.strings.disable_if_issues_with_updating onClick { val packageName: String = context.packageName @@ -147,7 +153,7 @@ class SettingsAdvancedController : SettingsLegacyController() { } startActivity(intent) } else { - context.toast(R.string.battery_optimization_disabled) + context.toast(MR.strings.battery_optimization_disabled) } } } @@ -156,7 +162,7 @@ class SettingsAdvancedController : SettingsLegacyController() { preference { key = "pref_dont_kill_my_app" title = "Don't kill my app!" - summaryRes = R.string.about_dont_kill_my_app + summaryRes = MR.strings.about_dont_kill_my_app onClick { openInBrowser("https://dontkillmyapp.com/") @@ -166,16 +172,16 @@ class SettingsAdvancedController : SettingsLegacyController() { if (isUpdaterEnabled) { switchPreference { - titleRes = R.string.check_for_beta_releases - summaryRes = R.string.try_new_features + titleRes = MR.strings.check_for_beta_releases + summaryRes = MR.strings.try_new_features bindTo(preferences.checkForBetas()) onChange { it as Boolean if (it != BuildConfig.BETA) { activity!!.materialAlertDialog() - .setTitle(R.string.warning) - .setMessage(if (it) R.string.warning_enroll_into_beta else R.string.warning_unenroll_from_beta) + .setTitle(MR.strings.warning) + .setMessage(if (it) MR.strings.warning_enroll_into_beta else MR.strings.warning_unenroll_from_beta) .setPositiveButton(AR.string.ok) { _, _ -> isChecked = it } .setNegativeButton(AR.string.cancel, null) .show() @@ -188,23 +194,23 @@ class SettingsAdvancedController : SettingsLegacyController() { } preferenceCategory { - titleRes = R.string.data_management + titleRes = MR.strings.data_management preference { - titleRes = R.string.force_download_cache_refresh - summaryRes = R.string.force_download_cache_refresh_summary + titleRes = MR.strings.force_download_cache_refresh + summaryRes = MR.strings.force_download_cache_refresh_summary onClick { downloadManager.refreshCache() } } preference { key = "clean_downloaded_chapters" - titleRes = R.string.clean_up_downloaded_chapters + titleRes = MR.strings.clean_up_downloaded_chapters - summaryRes = R.string.delete_unused_chapters + summaryRes = MR.strings.delete_unused_chapters onClick { activity!!.materialAlertDialog() - .setTitle(R.string.clean_up_downloaded_chapters) + .setTitle(MR.strings.clean_up_downloaded_chapters) .setMultiChoiceItems( R.array.clean_up_downloads, booleanArrayOf(true, true, true), @@ -222,48 +228,48 @@ class SettingsAdvancedController : SettingsLegacyController() { } .setNegativeButton(AR.string.cancel, null) .show().apply { - disableItems(arrayOf(activity!!.getString(R.string.clean_orphaned_downloads))) + disableItems(arrayOf(activity!!.getString(MR.strings.clean_orphaned_downloads))) } } } preference { key = "pref_clear_webview_data" - titleRes = R.string.pref_clear_webview_data + titleRes = MR.strings.pref_clear_webview_data onClick { clearWebViewData() } } preference { key = "clear_database" - titleRes = R.string.clear_database - summaryRes = R.string.clear_database_summary + titleRes = MR.strings.clear_database + summaryRes = MR.strings.clear_database_summary onClick { router.pushController(ClearDatabaseController().withFadeTransaction()) } } } preferenceCategory { - titleRes = R.string.network + titleRes = MR.strings.network preference { key = "clear_cookies" - titleRes = R.string.clear_cookies + titleRes = MR.strings.clear_cookies onClick { network.cookieJar.removeAll() - activity?.toast(R.string.cookies_cleared) + activity?.toast(MR.strings.cookies_cleared) } } intListPreference(activity) { key = PreferenceKeys.dohProvider - titleRes = R.string.doh + titleRes = MR.strings.doh entriesRes = arrayOf( - R.string.disabled, - R.string.cloudflare, - R.string.google, - R.string.ad_guard, - R.string.quad9, - R.string.aliDNS, - R.string.dnsPod, - R.string.dns_360, - R.string.quad_101, + MR.strings.disabled, + MR.strings.cloudflare, + MR.strings.google, + MR.strings.ad_guard, + MR.strings.quad9, + MR.strings.aliDNS, + MR.strings.dnsPod, + MR.strings.dns_360, + MR.strings.quad_101, ) entryValues = listOf( -1, @@ -279,13 +285,13 @@ class SettingsAdvancedController : SettingsLegacyController() { defaultValue = -1 onChange { - activity?.toast(R.string.requires_app_restart) + activity?.toast(MR.strings.requires_app_restart) true } } editTextPreference(activity) { bindTo(networkPreferences.defaultUserAgent()) - titleRes = R.string.user_agent_string + titleRes = MR.strings.user_agent_string onChange { it as String @@ -293,7 +299,7 @@ class SettingsAdvancedController : SettingsLegacyController() { // OkHttp checks for valid values internally Headers.Builder().add("User-Agent", it) } catch (_: IllegalArgumentException) { - context.toast(R.string.error_user_agent_string_invalid) + context.toast(MR.strings.error_user_agent_string_invalid) return@onChange false } true @@ -302,11 +308,11 @@ class SettingsAdvancedController : SettingsLegacyController() { } preferenceCategory { - titleRes = R.string.extensions + titleRes = MR.strings.extensions listPreference(activity) { bindTo(basePreferences.extensionInstaller()) - titleRes = R.string.ext_installer_pref + titleRes = MR.strings.ext_installer_pref val values = ExtensionInstaller.entries.toList() entriesRes = values.map { it.titleResId }.toTypedArray() @@ -316,9 +322,9 @@ class SettingsAdvancedController : SettingsLegacyController() { if (it == ExtensionInstaller.SHIZUKU) { return@onChange if (!context.isPackageInstalled(ShizukuInstaller.shizukuPkgName) && !Sui.isSui()) { context.materialAlertDialog() - .setTitle(R.string.ext_installer_shizuku) - .setMessage(R.string.ext_installer_shizuku_unavailable_dialog) - .setPositiveButton(R.string.download) { _, _ -> + .setTitle(MR.strings.ext_installer_shizuku) + .setMessage(MR.strings.ext_installer_shizuku_unavailable_dialog) + .setPositiveButton(MR.strings.download) { _, _ -> openInBrowser(ShizukuInstaller.downloadLink) } .setNegativeButton(AR.string.cancel, null) @@ -331,21 +337,21 @@ class SettingsAdvancedController : SettingsLegacyController() { true } } - infoPreference(R.string.ext_installer_summary).apply { + infoPreference(MR.strings.ext_installer_summary).apply { basePreferences.extensionInstaller().changesIn(viewScope) { isVisible = it != ExtensionInstaller.PACKAGEINSTALLER && Build.VERSION.SDK_INT < Build.VERSION_CODES.S } } preference { - titleRes = R.string.action_revoke_all_extensions + titleRes = MR.strings.action_revoke_all_extensions onClick { activity?.materialAlertDialog() - ?.setTitle(R.string.confirm_revoke_all_extensions) + ?.setTitle(MR.strings.confirm_revoke_all_extensions) ?.setPositiveButton(AR.string.ok) { _, _ -> trustExtension.revokeAll() - activity?.toast(R.string.requires_app_restart) + activity?.toast(MR.strings.requires_app_restart) } ?.setNegativeButton(AR.string.cancel, null)?.show() } @@ -353,18 +359,18 @@ class SettingsAdvancedController : SettingsLegacyController() { } preferenceCategory { - titleRes = R.string.library + titleRes = MR.strings.library preference { key = "refresh_lib_meta" - titleRes = R.string.refresh_library_metadata - summaryRes = R.string.updates_covers_genres_desc + titleRes = MR.strings.refresh_library_metadata + summaryRes = MR.strings.updates_covers_genres_desc onClick { LibraryUpdateJob.startNow(context, target = Target.DETAILS) } } preference { key = "refresh_teacking_meta" - titleRes = R.string.refresh_tracking_metadata - summaryRes = R.string.updates_tracking_details + titleRes = MR.strings.refresh_tracking_metadata + summaryRes = MR.strings.updates_tracking_details onClick { LibraryUpdateJob.startNow(context, target = Target.TRACKING) } } @@ -372,11 +378,11 @@ class SettingsAdvancedController : SettingsLegacyController() { if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) { preferenceCategory { - titleRes = R.string.reader + titleRes = MR.strings.reader preference { key = "pref_display_profile" - titleRes = R.string.pref_display_profile + titleRes = MR.strings.pref_display_profile onClick { (activity as? MainActivity)?.showColourProfilePicker() } @@ -394,7 +400,7 @@ class SettingsAdvancedController : SettingsLegacyController() { summary = "To test crashes" onClick { activity!!.materialAlertDialog() - .setTitle(R.string.warning) + .setTitle(MR.strings.warning) .setMessage("I told you this would crash the app, why would you want that?") .setPositiveButton("Crash it anyway") { _, _ -> throw RuntimeException("Fell into the void") } .setNegativeButton("Nevermind", null) @@ -406,7 +412,7 @@ class SettingsAdvancedController : SettingsLegacyController() { @OptIn(DelicateCoroutinesApi::class) private fun cleanupDownloads(removeRead: Boolean, removeNonFavorite: Boolean) { if (job?.isActive == true) return - activity?.toast(R.string.starting_cleanup) + activity?.toast(MR.strings.starting_cleanup) job = GlobalScope.launch(Dispatchers.IO, CoroutineStart.DEFAULT) { val mangaList = getManga.awaitAll() val sourceManager: SourceManager = Injekt.get() @@ -436,10 +442,10 @@ class SettingsAdvancedController : SettingsLegacyController() { val activity = activity ?: return@launchUI val cleanupString = if (foldersCleared == 0) { - activity.getString(R.string.no_folders_to_cleanup) + activity.getString(MR.strings.no_folders_to_cleanup) } else { - resources!!.getQuantityString( - R.plurals.cleanup_done, + activity.getString( + MR.plurals.cleanup_done, foldersCleared, foldersCleared, ) @@ -460,10 +466,10 @@ class SettingsAdvancedController : SettingsLegacyController() { webview.clearSslPreferences() WebStorage.getInstance().deleteAllData() activity?.applicationInfo?.dataDir?.let { File("$it/app_webview/").deleteRecursively() } - activity?.toast(R.string.webview_data_deleted) + activity?.toast(MR.strings.webview_data_deleted) } catch (e: Throwable) { Logger.e(e) - activity?.toast(R.string.cache_delete_error) + activity?.toast(MR.strings.cache_delete_error) } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsAppearanceController.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsAppearanceController.kt index a77d0edbd6..2a25ad20e3 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsAppearanceController.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsAppearanceController.kt @@ -8,6 +8,9 @@ import androidx.core.view.doOnNextLayout import androidx.core.view.isVisible import androidx.preference.PreferenceScreen import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.preference.changesIn import eu.kanade.tachiyomi.ui.setting.SettingsLegacyController import eu.kanade.tachiyomi.ui.setting.ThemePreference @@ -17,10 +20,10 @@ import eu.kanade.tachiyomi.ui.setting.infoPreference import eu.kanade.tachiyomi.ui.setting.intListPreference import eu.kanade.tachiyomi.ui.setting.onChange import eu.kanade.tachiyomi.ui.setting.preferenceCategory -import eu.kanade.tachiyomi.ui.setting.summaryRes +import eu.kanade.tachiyomi.ui.setting.summaryMRes as summaryRes import eu.kanade.tachiyomi.ui.setting.switchPreference import eu.kanade.tachiyomi.ui.setting.themePreference -import eu.kanade.tachiyomi.ui.setting.titleRes +import eu.kanade.tachiyomi.ui.setting.titleMRes as titleRes import eu.kanade.tachiyomi.util.system.SideNavMode import eu.kanade.tachiyomi.util.system.appDelegateNightMode import eu.kanade.tachiyomi.util.system.dpToPx @@ -41,14 +44,14 @@ class SettingsAppearanceController : SettingsLegacyController() { @SuppressLint("NotifyDataSetChanged") override fun setupPreferenceScreen(screen: PreferenceScreen) = screen.apply { - titleRes = R.string.appearance + titleRes = MR.strings.appearance preferenceCategory { - titleRes = R.string.app_theme + titleRes = MR.strings.app_theme themePreference = themePreference { key = "theme_preference" - titleRes = R.string.app_theme + titleRes = MR.strings.app_theme lastScrollPostionLight = lastThemeXLight lastScrollPostionDark = lastThemeXDark summary = context.getString(context.getPrefTheme(preferences).nameRes) @@ -58,7 +61,7 @@ class SettingsAppearanceController : SettingsLegacyController() { switchPreference { key = "night_mode_switch" isPersistent = false - titleRes = R.string.follow_system_theme + titleRes = MR.strings.follow_system_theme isChecked = preferences.nightMode().get() == AppCompatDelegate.MODE_NIGHT_FOLLOW_SYSTEM @@ -80,7 +83,7 @@ class SettingsAppearanceController : SettingsLegacyController() { switchPreference { key = Keys.themeDarkAmoled - titleRes = R.string.pure_black_dark_mode + titleRes = MR.strings.pure_black_dark_mode defaultValue = false preferences.nightMode().changesIn(viewScope) { mode -> @@ -101,8 +104,8 @@ class SettingsAppearanceController : SettingsLegacyController() { preferenceCategory { switchPreference { bindTo(preferences.useLargeToolbar()) - titleRes = R.string.expanded_toolbar - summaryRes = R.string.show_larger_toolbar + titleRes = MR.strings.expanded_toolbar + summaryRes = MR.strings.show_larger_toolbar onChange { val useLarge = it as Boolean @@ -127,28 +130,28 @@ class SettingsAppearanceController : SettingsLegacyController() { } preferenceCategory { - titleRes = R.string.details_page + titleRes = MR.strings.details_page switchPreference { key = Keys.themeMangaDetails - titleRes = R.string.theme_buttons_based_on_cover + titleRes = MR.strings.theme_buttons_based_on_cover defaultValue = true } } preferenceCategory { - titleRes = R.string.navigation + titleRes = MR.strings.navigation switchPreference { key = Keys.hideBottomNavOnScroll - titleRes = R.string.hide_bottom_nav - summaryRes = R.string.hides_on_scroll + titleRes = MR.strings.hide_bottom_nav + summaryRes = MR.strings.hides_on_scroll defaultValue = true } intListPreference(activity) { key = Keys.sideNavIconAlignment - titleRes = R.string.side_nav_icon_alignment - entriesRes = arrayOf(R.string.top, R.string.center, R.string.bottom) + titleRes = MR.strings.side_nav_icon_alignment + entriesRes = arrayOf(MR.strings.top, MR.strings.center, MR.strings.bottom) entryRange = 0..2 defaultValue = 1 isVisible = max( @@ -159,7 +162,7 @@ class SettingsAppearanceController : SettingsLegacyController() { intListPreference(activity) { key = Keys.sideNavMode - titleRes = R.string.use_side_navigation + titleRes = MR.strings.use_side_navigation val values = SideNavMode.entries entriesRes = values.map { it.stringRes }.toTypedArray() entryValues = values.map { it.prefValue } @@ -171,7 +174,7 @@ class SettingsAppearanceController : SettingsLegacyController() { } } - infoPreference(R.string.by_default_side_nav_info) + infoPreference(MR.strings.by_default_side_nav_info) } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsBrowseController.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsBrowseController.kt index 7fe8ecb483..56f4d08b87 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsBrowseController.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsBrowseController.kt @@ -8,6 +8,9 @@ import androidx.preference.PreferenceScreen import androidx.preference.SwitchPreferenceCompat import eu.kanade.tachiyomi.BuildConfig import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.notification.Notifications import eu.kanade.tachiyomi.data.preference.PreferenceKeys import eu.kanade.tachiyomi.data.preference.changesIn @@ -26,10 +29,11 @@ import eu.kanade.tachiyomi.ui.setting.onChange import eu.kanade.tachiyomi.ui.setting.onClick import eu.kanade.tachiyomi.ui.setting.preference import eu.kanade.tachiyomi.ui.setting.preferenceCategory -import eu.kanade.tachiyomi.ui.setting.summaryRes +import eu.kanade.tachiyomi.ui.setting.summaryMRes as summaryRes import eu.kanade.tachiyomi.ui.setting.switchPreference -import eu.kanade.tachiyomi.ui.setting.titleRes +import eu.kanade.tachiyomi.ui.setting.titleMRes as titleRes import eu.kanade.tachiyomi.util.lang.addBetaTag +import eu.kanade.tachiyomi.util.view.setAction import eu.kanade.tachiyomi.util.view.snack import eu.kanade.tachiyomi.util.view.withFadeTransaction import uy.kohesive.injekt.injectLazy @@ -42,24 +46,24 @@ class SettingsBrowseController : SettingsLegacyController() { var updatedExtNotifPref: SwitchPreferenceCompat? = null override fun setupPreferenceScreen(screen: PreferenceScreen) = screen.apply { - titleRes = R.string.browse + titleRes = MR.strings.browse preferenceCategory { switchPreference { bindTo(preferences.hideInLibraryItems()) - titleRes = R.string.hide_in_library_items + titleRes = MR.strings.hide_in_library_items } } preferenceCategory { - titleRes = R.string.extensions + titleRes = MR.strings.extensions preference { - title = context.getString(R.string.source_repos).addBetaTag(context) + title = context.getString(MR.strings.source_repos).addBetaTag(context) onClick { router.pushController(ExtensionRepoController().withFadeTransaction()) } } switchPreference { key = PreferenceKeys.automaticExtUpdates - titleRes = R.string.check_for_extension_updates + titleRes = MR.strings.check_for_extension_updates defaultValue = true onChange { @@ -71,17 +75,17 @@ class SettingsBrowseController : SettingsLegacyController() { if (ExtensionManager.canAutoInstallUpdates()) { val intPref = intListPreference(activity) { key = PreferenceKeys.autoUpdateExtensions - titleRes = R.string.auto_update_extensions + titleRes = MR.strings.auto_update_extensions entryRange = 0..2 entriesRes = arrayOf( - R.string.over_any_network, - R.string.over_wifi_only, - R.string.dont_auto_update, + MR.strings.over_any_network, + MR.strings.over_wifi_only, + MR.strings.dont_auto_update, ) defaultValue = AppDownloadInstallJob.ONLY_ON_UNMETERED } val infoPref = if (basePreferences.extensionInstaller().get() != ExtensionInstaller.SHIZUKU) { - infoPreference(R.string.some_extensions_may_not_update) + infoPreference(MR.strings.some_extensions_may_not_update) } else { null } @@ -89,7 +93,7 @@ class SettingsBrowseController : SettingsLegacyController() { switchPreference { key = "notify_ext_updated" isPersistent = false - titleRes = R.string.notify_extension_updated + titleRes = MR.strings.notify_extension_updated isChecked = Notifications.isNotificationChannelEnabled( context, Notifications.CHANNEL_EXT_UPDATED, @@ -120,19 +124,19 @@ class SettingsBrowseController : SettingsLegacyController() { } preferenceCategory { - titleRes = R.string.pref_global_search + titleRes = MR.strings.pref_global_search switchPreference { key = PreferenceKeys.onlySearchPinned - titleRes = R.string.only_search_pinned_when + titleRes = MR.strings.only_search_pinned_when } } preferenceCategory { - titleRes = R.string.migration + titleRes = MR.strings.migration // Only show this if someone has mass migrated manga once preference { - titleRes = R.string.source_migration + titleRes = MR.strings.source_migration onClick { router.pushController(MigrationController().withFadeTransaction()) } } if (preferences.skipPreMigration().get() || preferences.migrationSources() @@ -140,15 +144,15 @@ class SettingsBrowseController : SettingsLegacyController() { ) { switchPreference { key = PreferenceKeys.skipPreMigration - titleRes = R.string.skip_pre_migration - summaryRes = R.string.use_last_saved_migration_preferences + titleRes = MR.strings.skip_pre_migration + summaryRes = MR.strings.use_last_saved_migration_preferences defaultValue = false } } preference { key = "match_pinned_sources" - titleRes = R.string.match_pinned_sources - summaryRes = R.string.only_enable_pinned_for_migration + titleRes = MR.strings.match_pinned_sources + summaryRes = MR.strings.only_enable_pinned_for_migration onClick { val ogSources = preferences.migrationSources().get() val pinnedSources = @@ -156,9 +160,9 @@ class SettingsBrowseController : SettingsLegacyController() { preferences.migrationSources().set(pinnedSources) (activity as? MainActivity)?.setUndoSnackBar( view?.snack( - R.string.migration_sources_changed, + MR.strings.migration_sources_changed, ) { - setAction(R.string.undo) { + setAction(MR.strings.undo) { preferences.migrationSources().set(ogSources) } }, @@ -168,8 +172,8 @@ class SettingsBrowseController : SettingsLegacyController() { preference { key = "match_enabled_sources" - titleRes = R.string.match_enabled_sources - summaryRes = R.string.only_enable_enabled_for_migration + titleRes = MR.strings.match_enabled_sources + summaryRes = MR.strings.only_enable_enabled_for_migration onClick { val ogSources = preferences.migrationSources().get() val languages = preferences.enabledLanguages().get() @@ -182,9 +186,9 @@ class SettingsBrowseController : SettingsLegacyController() { preferences.migrationSources().set(enabledSources) (activity as? MainActivity)?.setUndoSnackBar( view?.snack( - R.string.migration_sources_changed, + MR.strings.migration_sources_changed, ) { - setAction(R.string.undo) { + setAction(MR.strings.undo) { preferences.migrationSources().set(ogSources) } }, @@ -192,19 +196,19 @@ class SettingsBrowseController : SettingsLegacyController() { } } - infoPreference(R.string.you_can_migrate_in_library) + infoPreference(MR.strings.you_can_migrate_in_library) } preferenceCategory { - titleRes = R.string.nsfw_sources + titleRes = MR.strings.nsfw_sources switchPreference { key = PreferenceKeys.showNsfwSource - titleRes = R.string.show_in_sources_and_extensions - summaryRes = R.string.requires_app_restart + titleRes = MR.strings.show_in_sources_and_extensions + summaryRes = MR.strings.requires_app_restart defaultValue = true } - infoPreference(R.string.does_not_prevent_unofficial_nsfw) + infoPreference(MR.strings.does_not_prevent_unofficial_nsfw) } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsDownloadController.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsDownloadController.kt index 8bc8edbea3..267349b9d1 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsDownloadController.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsDownloadController.kt @@ -4,6 +4,9 @@ import android.content.Intent import androidx.preference.PreferenceScreen import com.bluelinelabs.conductor.Controller import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.database.DatabaseHelper import eu.kanade.tachiyomi.data.database.models.Category import eu.kanade.tachiyomi.data.preference.changesIn @@ -14,9 +17,9 @@ import eu.kanade.tachiyomi.ui.setting.infoPreference import eu.kanade.tachiyomi.ui.setting.intListPreference import eu.kanade.tachiyomi.ui.setting.multiSelectListPreferenceMat import eu.kanade.tachiyomi.ui.setting.preferenceCategory -import eu.kanade.tachiyomi.ui.setting.summaryRes +import eu.kanade.tachiyomi.ui.setting.summaryMRes as summaryRes import eu.kanade.tachiyomi.ui.setting.switchPreference -import eu.kanade.tachiyomi.ui.setting.titleRes +import eu.kanade.tachiyomi.ui.setting.titleMRes as titleRes import eu.kanade.tachiyomi.ui.setting.triStateListPreference import eu.kanade.tachiyomi.util.lang.addBetaTag import eu.kanade.tachiyomi.util.view.withFadeTransaction @@ -30,116 +33,116 @@ class SettingsDownloadController : SettingsLegacyController() { private val downloadPreferences: DownloadPreferences by injectLazy() override fun setupPreferenceScreen(screen: PreferenceScreen) = screen.apply { - titleRes = R.string.downloads + titleRes = MR.strings.downloads switchPreference { key = Keys.downloadOnlyOverWifi - titleRes = R.string.only_download_over_wifi + titleRes = MR.strings.only_download_over_wifi defaultValue = true } switchPreference { bindTo(preferences.saveChaptersAsCBZ()) - titleRes = R.string.save_chapters_as_cbz + titleRes = MR.strings.save_chapters_as_cbz } switchPreference { bindTo(preferences.splitTallImages()) - titleRes = R.string.split_tall_images - summaryRes = R.string.split_tall_images_summary + titleRes = MR.strings.split_tall_images + summaryRes = MR.strings.split_tall_images_summary } switchPreference { bindTo(downloadPreferences.downloadWithId()) - title = context.getString(R.string.download_with_id).addBetaTag(context) - summaryRes = R.string.download_with_id_details + title = context.getString(MR.strings.download_with_id).addBetaTag(context) + summaryRes = MR.strings.download_with_id_details } val dbCategories = db.getCategories().executeAsBlocking() val categories = listOf(Category.createDefault(context)) + dbCategories preferenceCategory { - titleRes = R.string.remove_after_read + titleRes = MR.strings.remove_after_read switchPreference { key = Keys.removeAfterMarkedAsRead - titleRes = R.string.remove_when_marked_as_read + titleRes = MR.strings.remove_when_marked_as_read defaultValue = false } intListPreference(activity) { bindTo(preferences.removeAfterReadSlots()) - titleRes = R.string.remove_after_read + titleRes = MR.strings.remove_after_read entriesRes = arrayOf( - R.string.never, - R.string.last_read_chapter, - R.string.second_to_last, - R.string.third_to_last, - R.string.fourth_to_last, - R.string.fifth_to_last, + MR.strings.never, + MR.strings.last_read_chapter, + MR.strings.second_to_last, + MR.strings.third_to_last, + MR.strings.fourth_to_last, + MR.strings.fifth_to_last, ) entryRange = -1..4 defaultValue = -1 } multiSelectListPreferenceMat(activity) { bindTo(preferences.removeExcludeCategories()) - titleRes = R.string.pref_remove_exclude_categories + titleRes = MR.strings.pref_remove_exclude_categories entries = categories.map { it.name } entryValues = categories.map { it.id.toString() } - noSelectionRes = R.string.none + noSelectionRes = MR.strings.none preferences.removeAfterReadSlots().changesIn(viewScope) { isVisible = it != -1 } } switchPreference { bindTo(preferences.removeBookmarkedChapters()) - titleRes = R.string.allow_deleting_bookmarked_chapters + titleRes = MR.strings.allow_deleting_bookmarked_chapters } } preferenceCategory { - titleRes = R.string.download_new_chapters + titleRes = MR.strings.download_new_chapters switchPreference { bindTo(preferences.downloadNewChapters()) - titleRes = R.string.download_new_chapters + titleRes = MR.strings.download_new_chapters } triStateListPreference(activity) { preferences.apply { bindTo(downloadNewChaptersInCategories(), excludeCategoriesInDownloadNew()) } - titleRes = R.string.categories + titleRes = MR.strings.categories entries = categories.map { it.name } entryValues = categories.map { it.id.toString() } - allSelectionRes = R.string.all + allSelectionRes = MR.strings.all preferences.downloadNewChapters().changesIn(viewScope) { isVisible = it } } } preferenceCategory { - titleRes = R.string.download_ahead + titleRes = MR.strings.download_ahead intListPreference(activity) { bindTo(preferences.autoDownloadWhileReading()) - titleRes = R.string.auto_download_while_reading + titleRes = MR.strings.auto_download_while_reading entries = listOf( - context.getString(R.string.never), - context.resources.getQuantityString(R.plurals.next_unread_chapters, 2, 2), - context.resources.getQuantityString(R.plurals.next_unread_chapters, 3, 3), - context.resources.getQuantityString(R.plurals.next_unread_chapters, 5, 5), - context.resources.getQuantityString(R.plurals.next_unread_chapters, 10, 10), + context.getString(MR.strings.never), + context.getString(MR.plurals.next_unread_chapters, 2, 2), + context.getString(MR.plurals.next_unread_chapters, 3, 3), + context.getString(MR.plurals.next_unread_chapters, 5, 5), + context.getString(MR.plurals.next_unread_chapters, 10, 10), ) entryValues = listOf(0, 2, 3, 5, 10) } - infoPreference(R.string.download_ahead_info) + infoPreference(MR.strings.download_ahead_info) } preferenceCategory { - titleRes = R.string.automatic_removal + titleRes = MR.strings.automatic_removal intListPreference(activity) { bindTo(preferences.deleteRemovedChapters()) - titleRes = R.string.delete_removed_chapters - summary = activity?.getString(R.string.delete_downloaded_if_removed_online) + titleRes = MR.strings.delete_removed_chapters + summary = activity?.getString(MR.strings.delete_downloaded_if_removed_online) entriesRes = arrayOf( - R.string.ask_on_chapters_page, - R.string.always_keep, - R.string.always_delete, + MR.strings.ask_on_chapters_page, + MR.strings.always_keep, + MR.strings.always_delete, ) entryRange = 0..2 } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsGeneralController.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsGeneralController.kt index a68f8f3ef3..dd6f854712 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsGeneralController.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsGeneralController.kt @@ -11,6 +11,9 @@ import androidx.core.os.LocaleListCompat import androidx.preference.PreferenceScreen import eu.kanade.tachiyomi.BuildConfig import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.updater.AppDownloadInstallJob import eu.kanade.tachiyomi.ui.setting.SettingsLegacyController import eu.kanade.tachiyomi.ui.setting.ThemePreference @@ -23,9 +26,9 @@ import eu.kanade.tachiyomi.ui.setting.onChange import eu.kanade.tachiyomi.ui.setting.onClick import eu.kanade.tachiyomi.ui.setting.preference import eu.kanade.tachiyomi.ui.setting.preferenceCategory -import eu.kanade.tachiyomi.ui.setting.summaryRes +import eu.kanade.tachiyomi.ui.setting.summaryMRes as summaryRes import eu.kanade.tachiyomi.ui.setting.switchPreference -import eu.kanade.tachiyomi.ui.setting.titleRes +import eu.kanade.tachiyomi.ui.setting.titleMRes as titleRes import eu.kanade.tachiyomi.util.lang.addBetaTag import eu.kanade.tachiyomi.util.lang.compareToCaseInsensitiveNaturalOrder import eu.kanade.tachiyomi.util.system.systemLangContext @@ -42,22 +45,22 @@ class SettingsGeneralController : SettingsLegacyController() { var themePreference: ThemePreference? = null override fun setupPreferenceScreen(screen: PreferenceScreen) = screen.apply { - titleRes = R.string.general + titleRes = MR.strings.general intListPreference(activity) { key = Keys.startingTab - titleRes = R.string.starting_screen + titleRes = MR.strings.starting_screen summaryRes = when (preferences.startingTab().get()) { - -1 -> R.string.library - -2 -> R.string.recents - -3 -> R.string.browse - else -> R.string.last_used_library_recents + -1 -> MR.strings.library + -2 -> MR.strings.recents + -3 -> MR.strings.browse + else -> MR.strings.last_used_library_recents } entriesRes = arrayOf( - R.string.last_used_library_recents, - R.string.library, - R.string.recents, - R.string.browse, + MR.strings.last_used_library_recents, + MR.strings.library, + MR.strings.recents, + MR.strings.browse, ) entryValues = (0 downTo -3).toList() defaultValue = 0 @@ -68,11 +71,11 @@ class SettingsGeneralController : SettingsLegacyController() { onChange { newValue -> summaryRes = when (newValue) { - 0, 1 -> R.string.last_used_library_recents - -1 -> R.string.library - -2 -> R.string.recents - -3 -> R.string.browse - else -> R.string.last_used_library_recents + 0, 1 -> MR.strings.last_used_library_recents + -1 -> MR.strings.library + -2 -> MR.strings.recents + -3 -> MR.strings.browse + else -> MR.strings.last_used_library_recents } customSelectedValue = when (newValue) { in -3..-1 -> newValue as Int @@ -84,14 +87,14 @@ class SettingsGeneralController : SettingsLegacyController() { switchPreference { key = Keys.backToStart - titleRes = R.string.back_to_start - summaryRes = R.string.pressing_back_to_start + titleRes = MR.strings.back_to_start + summaryRes = MR.strings.pressing_back_to_start defaultValue = true } if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O) { preference { key = "pref_manage_notifications" - titleRes = R.string.pref_manage_notifications + titleRes = MR.strings.pref_manage_notifications onClick { val intent = Intent(Settings.ACTION_APP_NOTIFICATION_SETTINGS).apply { putExtra(Settings.EXTRA_APP_PACKAGE, context.packageName) @@ -102,52 +105,52 @@ class SettingsGeneralController : SettingsLegacyController() { } preferenceCategory { - titleRes = R.string.app_shortcuts + titleRes = MR.strings.app_shortcuts switchPreference { key = Keys.showSeriesInShortcuts - titleRes = R.string.show_recent_series - summaryRes = R.string.includes_recently_read_updated_added + titleRes = MR.strings.show_recent_series + summaryRes = MR.strings.includes_recently_read_updated_added defaultValue = true } switchPreference { key = Keys.showSourcesInShortcuts - titleRes = R.string.show_recent_sources + titleRes = MR.strings.show_recent_sources defaultValue = true } switchPreference { key = Keys.openChapterInShortcuts - titleRes = R.string.series_opens_new_chapters - summaryRes = R.string.no_new_chapters_open_details + titleRes = MR.strings.series_opens_new_chapters + summaryRes = MR.strings.no_new_chapters_open_details defaultValue = true } } if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.S && isUpdaterEnabled) { preferenceCategory { - titleRes = R.string.auto_updates + titleRes = MR.strings.auto_updates intListPreference(activity) { key = Keys.shouldAutoUpdate - titleRes = R.string.auto_update_app + titleRes = MR.strings.auto_update_app entryRange = 0..2 - entriesRes = arrayOf(R.string.over_any_network, R.string.over_wifi_only, R.string.dont_auto_update) + entriesRes = arrayOf(MR.strings.over_any_network, MR.strings.over_wifi_only, MR.strings.dont_auto_update) defaultValue = AppDownloadInstallJob.ONLY_ON_UNMETERED } } } preferenceCategory { - titleRes = R.string.locale + titleRes = MR.strings.locale listPreference(activity) { key = Keys.dateFormat - titleRes = R.string.date_format + titleRes = MR.strings.date_format entryValues = listOf("", "MM/dd/yy", "dd/MM/yy", "yyyy-MM-dd") entries = entryValues.map { value -> if (value == "") { - context.getString(R.string.system_default) + context.getString(MR.strings.system_default) } else { value } @@ -158,14 +161,14 @@ class SettingsGeneralController : SettingsLegacyController() { listPreference(activity) { key = "language" isPersistent = false - title = context.getString(R.string.language).let { + title = context.getString(MR.strings.language).let { if (Build.VERSION.SDK_INT < Build.VERSION_CODES.TIRAMISU) { it.addBetaTag(context) } else { it } } - dialogTitleRes = R.string.language + dialogTitleRes = MR.strings.language val locales = mutableListOf() val availLocales = Locale.getAvailableLocales() resources?.getXml(R.xml.locales_config).use { parser -> @@ -192,7 +195,7 @@ class SettingsGeneralController : SettingsLegacyController() { } val localArray = localesMap.keys.filterNotNull().toTypedArray() val localeList = LocaleListCompat.create(*localArray) - val sysDef = context.systemLangContext.getString(R.string.system_default) + val sysDef = context.systemLangContext.getString(MR.strings.system_default) entries = listOf(sysDef) + localesMap.keys.map { locale -> locale.getDisplayName(locale).replaceFirstChar { it.uppercase(locale) } } @@ -228,17 +231,17 @@ class SettingsGeneralController : SettingsLegacyController() { } } if (Build.VERSION.SDK_INT < Build.VERSION_CODES.TIRAMISU) { - infoPreference(R.string.language_requires_app_restart) + infoPreference(MR.strings.language_requires_app_restart) } } } preferenceCategory { - titleRes = R.string.navigation + titleRes = MR.strings.navigation listPreference(activity) { bindTo(basePreferences.longTapRecentsNavBehaviour()) - titleRes = R.string.recents_long_tap + titleRes = MR.strings.recents_long_tap val values = BasePreferences.LongTapRecents.entries.toList() entriesRes = values.map { it.titleResId }.toTypedArray() @@ -247,7 +250,7 @@ class SettingsGeneralController : SettingsLegacyController() { listPreference(activity) { bindTo(basePreferences.longTapBrowseNavBehaviour()) - titleRes = R.string.browse_long_tap + titleRes = MR.strings.browse_long_tap val values = BasePreferences.LongTapBrowse.entries.toList() entriesRes = values.map { it.titleResId }.toTypedArray() diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsLibraryController.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsLibraryController.kt index 539c91bc02..663c4e8b8d 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsLibraryController.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsLibraryController.kt @@ -2,6 +2,9 @@ package eu.kanade.tachiyomi.ui.setting.controllers import androidx.preference.PreferenceScreen import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.database.DatabaseHelper import eu.kanade.tachiyomi.data.database.models.Category import eu.kanade.tachiyomi.data.library.LibraryUpdateJob @@ -26,9 +29,9 @@ import eu.kanade.tachiyomi.ui.setting.onChange import eu.kanade.tachiyomi.ui.setting.onClick import eu.kanade.tachiyomi.ui.setting.preference import eu.kanade.tachiyomi.ui.setting.preferenceCategory -import eu.kanade.tachiyomi.ui.setting.summaryRes +import eu.kanade.tachiyomi.ui.setting.summaryMRes as summaryRes import eu.kanade.tachiyomi.ui.setting.switchPreference -import eu.kanade.tachiyomi.ui.setting.titleRes +import eu.kanade.tachiyomi.ui.setting.titleMRes as titleRes import eu.kanade.tachiyomi.ui.setting.triStateListPreference import eu.kanade.tachiyomi.util.system.launchIO import eu.kanade.tachiyomi.util.system.launchUI @@ -45,20 +48,20 @@ class SettingsLibraryController : SettingsLegacyController() { private val getLibraryManga: GetLibraryManga by injectLazy() override fun setupPreferenceScreen(screen: PreferenceScreen) = screen.apply { - titleRes = R.string.library + titleRes = MR.strings.library preferenceCategory { - titleRes = R.string.general + titleRes = MR.strings.general switchPreference { key = Keys.removeArticles - titleRes = R.string.sort_by_ignoring_articles - summaryRes = R.string.when_sorting_ignore_articles + titleRes = MR.strings.sort_by_ignoring_articles + summaryRes = MR.strings.when_sorting_ignore_articles defaultValue = false } switchPreference { key = Keys.showLibrarySearchSuggestions - titleRes = R.string.search_suggestions - summaryRes = R.string.search_tips_show_periodically + titleRes = MR.strings.search_suggestions + summaryRes = MR.strings.search_tips_show_periodically onChange { it as Boolean @@ -77,8 +80,8 @@ class SettingsLibraryController : SettingsLegacyController() { preference { key = "library_display_options" isPersistent = false - titleRes = R.string.display_options - summaryRes = R.string.can_be_found_in_library_filters + titleRes = MR.strings.display_options + summaryRes = MR.strings.can_be_found_in_library_filters onClick { TabbedLibraryDisplaySheet(this@SettingsLibraryController).show() @@ -89,32 +92,32 @@ class SettingsLibraryController : SettingsLegacyController() { val dbCategories = db.getCategories().executeAsBlocking() preferenceCategory { - titleRes = R.string.categories + titleRes = MR.strings.categories preference { key = "edit_categories" isPersistent = false val catCount = db.getCategories().executeAsBlocking().size - titleRes = if (catCount > 0) R.string.edit_categories else R.string.add_categories - if (catCount > 0) summary = context.resources.getQuantityString(R.plurals.category_plural, catCount, catCount) + titleRes = if (catCount > 0) MR.strings.edit_categories else MR.strings.add_categories + if (catCount > 0) summary = context.getString(MR.plurals.category_plural, catCount, catCount) onClick { router.pushController(CategoryController().withFadeTransaction()) } } intListPreference(activity) { key = Keys.defaultCategory - titleRes = R.string.default_category + titleRes = MR.strings.default_category val categories = listOf(Category.createDefault(context)) + dbCategories entries = - listOf(context.getString(R.string.last_used), context.getString(R.string.always_ask)) + + listOf(context.getString(MR.strings.last_used), context.getString(MR.strings.always_ask)) + categories.map { it.name }.toTypedArray() entryValues = listOf(-2, -1) + categories.mapNotNull { it.id }.toList() defaultValue = "-2" val categoryName: (Int) -> String = { catId -> when (catId) { - -2 -> context.getString(R.string.last_used) - -1 -> context.getString(R.string.always_ask) + -2 -> context.getString(MR.strings.last_used) + -1 -> context.getString(MR.strings.always_ask) else -> categories.find { it.id == preferences.defaultCategory().get() }?.name - ?: context.getString(R.string.last_used) + ?: context.getString(MR.strings.last_used) } } summary = categoryName(preferences.defaultCategory().get()) @@ -126,17 +129,17 @@ class SettingsLibraryController : SettingsLegacyController() { } preferenceCategory { - titleRes = R.string.global_updates + titleRes = MR.strings.global_updates intListPreference(activity) { key = Keys.libraryUpdateInterval - titleRes = R.string.library_update_frequency + titleRes = MR.strings.library_update_frequency entriesRes = arrayOf( - R.string.manual, - R.string.every_12_hours, - R.string.daily, - R.string.every_2_days, - R.string.every_3_days, - R.string.weekly, + MR.strings.manual, + MR.strings.every_12_hours, + MR.strings.daily, + MR.strings.every_2_days, + MR.strings.every_3_days, + MR.strings.weekly, ) entryValues = listOf(0, 12, 24, 48, 72, 168) defaultValue = 24 @@ -155,11 +158,11 @@ class SettingsLibraryController : SettingsLegacyController() { } multiSelectListPreferenceMat(activity) { bindTo(preferences.libraryUpdateDeviceRestriction()) - titleRes = R.string.library_update_restriction - entriesRes = arrayOf(R.string.wifi, R.string.charging, R.string.battery_not_low) + titleRes = MR.strings.library_update_restriction + entriesRes = arrayOf(MR.strings.wifi, MR.strings.charging, MR.strings.battery_not_low) entryValues = listOf(DEVICE_ONLY_ON_WIFI, DEVICE_CHARGING, DEVICE_BATTERY_NOT_LOW) - preSummaryRes = R.string.restrictions_ - noSelectionRes = R.string.none + preSummaryRes = MR.strings.restrictions_ + noSelectionRes = MR.strings.none preferences.libraryUpdateInterval().changesIn(viewScope) { isVisible = it > 0 @@ -174,33 +177,33 @@ class SettingsLibraryController : SettingsLegacyController() { multiSelectListPreferenceMat(activity) { bindTo(preferences.libraryUpdateMangaRestriction()) - titleRes = R.string.pref_library_update_manga_restriction + titleRes = MR.strings.pref_library_update_manga_restriction entriesRes = arrayOf( - R.string.pref_update_only_completely_read, - R.string.pref_update_only_started, - R.string.pref_update_only_non_completed, + MR.strings.pref_update_only_completely_read, + MR.strings.pref_update_only_started, + MR.strings.pref_update_only_non_completed, ) entryValues = listOf(MANGA_HAS_UNREAD, MANGA_NON_READ, MANGA_NON_COMPLETED) - noSelectionRes = R.string.none + noSelectionRes = MR.strings.none } triStateListPreference(activity) { preferences.apply { bindTo(libraryUpdateCategories(), libraryUpdateCategoriesExclude()) } - titleRes = R.string.categories + titleRes = MR.strings.categories val categories = listOf(Category.createDefault(context)) + dbCategories entries = categories.map { it.name } entryValues = categories.map { it.id.toString() } - allSelectionRes = R.string.all + allSelectionRes = MR.strings.all } switchPreference { key = Keys.refreshCoversToo - titleRes = R.string.auto_refresh_covers - summaryRes = R.string.auto_refresh_covers_summary + titleRes = MR.strings.auto_refresh_covers + summaryRes = MR.strings.auto_refresh_covers_summary defaultValue = true } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsMainController.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsMainController.kt index 60214ab02b..ec7b0dd12d 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsMainController.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsMainController.kt @@ -10,6 +10,9 @@ import com.bluelinelabs.conductor.Controller import com.bluelinelabs.conductor.RouterTransaction import com.bluelinelabs.conductor.changehandler.SimpleSwapChangeHandler import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.ui.main.FloatingSearchInterface import eu.kanade.tachiyomi.ui.more.AboutController import eu.kanade.tachiyomi.ui.setting.SettingsLegacyController @@ -21,7 +24,7 @@ import eu.kanade.tachiyomi.ui.setting.onClick import eu.kanade.tachiyomi.ui.setting.onLongClick import eu.kanade.tachiyomi.ui.setting.preference import eu.kanade.tachiyomi.ui.setting.preferenceLongClickable -import eu.kanade.tachiyomi.ui.setting.titleRes +import eu.kanade.tachiyomi.ui.setting.titleMRes as titleRes import eu.kanade.tachiyomi.util.system.getResourceColor import eu.kanade.tachiyomi.util.system.toast import eu.kanade.tachiyomi.util.view.activityBinding @@ -36,56 +39,56 @@ class SettingsMainController : SettingsLegacyController(), FloatingSearchInterfa } override fun setupPreferenceScreen(screen: PreferenceScreen) = with(screen) { - titleRes = R.string.settings + titleRes = MR.strings.settings val tintColor = context.getResourceColor(R.attr.colorSecondary) preference { iconRes = R.drawable.ic_tune_24dp iconTint = tintColor - titleRes = R.string.general + titleRes = MR.strings.general onClick { navigateTo(SettingsGeneralController()) } } preference { iconRes = R.drawable.ic_appearance_outline_24dp iconTint = tintColor - titleRes = R.string.appearance + titleRes = MR.strings.appearance onClick { navigateTo(SettingsAppearanceController()) } } preference { iconRes = R.drawable.ic_library_outline_24dp iconTint = tintColor - titleRes = R.string.library + titleRes = MR.strings.library onClick { navigateTo(SettingsLibraryController()) } } preference { iconRes = R.drawable.ic_read_outline_24dp iconTint = tintColor - titleRes = R.string.reader + titleRes = MR.strings.reader onClick { navigateTo(SettingsReaderController()) } } preference { iconRes = R.drawable.ic_file_download_24dp iconTint = tintColor - titleRes = R.string.downloads + titleRes = MR.strings.downloads onClick { navigateTo(SettingsDownloadController()) } } preference { iconRes = R.drawable.ic_browse_outline_24dp iconTint = tintColor - titleRes = R.string.browse + titleRes = MR.strings.browse onClick { navigateTo(SettingsBrowseController()) } } preference { iconRes = R.drawable.ic_sync_24dp iconTint = tintColor - titleRes = R.string.tracking + titleRes = MR.strings.tracking onClick { navigateTo(SettingsTrackingController()) } } preferenceLongClickable { iconRes = R.drawable.ic_storage_24dp iconTint = tintColor - titleRes = R.string.data_and_storage + titleRes = MR.strings.data_and_storage onClick { navigateTo(SettingsDataLegacyController()) } onLongClick { navigateTo(SettingsDataController()) @@ -95,19 +98,19 @@ class SettingsMainController : SettingsLegacyController(), FloatingSearchInterfa preference { iconRes = R.drawable.ic_security_24dp iconTint = tintColor - titleRes = R.string.security + titleRes = MR.strings.security onClick { navigateTo(SettingsSecurityController()) } } preference { iconRes = R.drawable.ic_code_24dp iconTint = tintColor - titleRes = R.string.advanced + titleRes = MR.strings.advanced onClick { navigateTo(SettingsAdvancedController()) } } preference { iconRes = R.drawable.ic_info_outline_24dp iconTint = tintColor - titleRes = R.string.about + titleRes = MR.strings.about onClick { navigateTo(AboutController()) } } this @@ -115,7 +118,7 @@ class SettingsMainController : SettingsLegacyController(), FloatingSearchInterfa override fun onCreateOptionsMenu(menu: Menu, inflater: MenuInflater) { inflater.inflate(R.menu.settings_main, menu) // Change hint to show global search. - activityBinding?.searchToolbar?.searchQueryHint = applicationContext?.getString(R.string.search_settings) + activityBinding?.searchToolbar?.searchQueryHint = applicationContext?.getString(MR.strings.search_settings) } override fun onOptionsItemSelected(item: MenuItem): Boolean { diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsReaderController.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsReaderController.kt index c03b434d07..3a1c4af87f 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsReaderController.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsReaderController.kt @@ -4,6 +4,9 @@ import android.content.ComponentName import android.content.Intent import androidx.preference.PreferenceScreen import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.preference.PreferenceValues import eu.kanade.tachiyomi.data.preference.changesIn import eu.kanade.tachiyomi.ui.reader.settings.OrientationType @@ -22,9 +25,9 @@ import eu.kanade.tachiyomi.ui.setting.multiSelectListPreferenceMat import eu.kanade.tachiyomi.ui.setting.onClick import eu.kanade.tachiyomi.ui.setting.preference import eu.kanade.tachiyomi.ui.setting.preferenceCategory -import eu.kanade.tachiyomi.ui.setting.summaryRes +import eu.kanade.tachiyomi.ui.setting.summaryMRes as summaryRes import eu.kanade.tachiyomi.ui.setting.switchPreference -import eu.kanade.tachiyomi.ui.setting.titleRes +import eu.kanade.tachiyomi.ui.setting.titleMRes as titleRes import eu.kanade.tachiyomi.util.lang.addBetaTag import eu.kanade.tachiyomi.util.system.DeviceUtil import eu.kanade.tachiyomi.util.system.isTablet @@ -40,13 +43,13 @@ class SettingsReaderController : SettingsLegacyController() { private val readerPreferences: ReaderPreferences by injectLazy() override fun setupPreferenceScreen(screen: PreferenceScreen) = screen.apply { - titleRes = R.string.reader + titleRes = MR.strings.reader preferenceCategory { - titleRes = R.string.general + titleRes = MR.strings.general intListPreference(activity) { key = Keys.defaultReadingMode - titleRes = R.string.default_reading_mode + titleRes = MR.strings.default_reading_mode entriesRes = ReadingModeType.entries.drop(1) .map { value -> value.stringRes }.toTypedArray() entryValues = ReadingModeType.entries.drop(1) @@ -55,13 +58,13 @@ class SettingsReaderController : SettingsLegacyController() { } intListPreference(activity) { key = Keys.doubleTapAnimationSpeed - titleRes = R.string.double_tap_anim_speed + titleRes = MR.strings.double_tap_anim_speed entries = listOf( - context.getString(R.string.no_animation), + context.getString(MR.strings.no_animation), context.getString( - R.string.fast, + MR.strings.fast, ), - context.getString(R.string.normal), + context.getString(MR.strings.normal), ) entryValues = listOf(1, 250, 500) // using a value of 0 breaks the image viewer, so // min is 1 @@ -69,24 +72,24 @@ class SettingsReaderController : SettingsLegacyController() { } switchPreference { key = Keys.enableTransitions - titleRes = R.string.animate_page_transitions + titleRes = MR.strings.animate_page_transitions defaultValue = true } intListPreference(activity) { key = Keys.preloadSize - titleRes = R.string.page_preload_amount + titleRes = MR.strings.page_preload_amount entryValues = listOf(4, 6, 8, 10, 12, 14, 16, 20) - entries = entryValues.map { context.resources.getQuantityString(R.plurals.pages_plural, it, it) } + entries = entryValues.map { context.getString(MR.plurals.pages_plural, it, it) } defaultValue = 6 - summaryRes = R.string.amount_of_pages_to_preload + summaryRes = MR.strings.amount_of_pages_to_preload } multiSelectListPreferenceMat(activity) { key = Keys.readerBottomButtons - titleRes = R.string.display_buttons_bottom_reader + titleRes = MR.strings.display_buttons_bottom_reader val enumConstants = ReaderBottomButton.entries entriesRes = ReaderBottomButton.entries.map { it.stringRes }.toTypedArray() entryValues = enumConstants.map { it.value } - allSelectionRes = R.string.display_options + allSelectionRes = MR.strings.display_options allIsAlwaysSelected = true showAllLast = true val defaults = ReaderBottomButton.BUTTONS_DEFAULTS.toMutableList() @@ -95,15 +98,15 @@ class SettingsReaderController : SettingsLegacyController() { } defaultValue = defaults } - infoPreference(R.string.certain_buttons_can_be_found) + infoPreference(MR.strings.certain_buttons_can_be_found) } preferenceCategory { - titleRes = R.string.display + titleRes = MR.strings.display intListPreference(activity) { key = Keys.defaultOrientationType - titleRes = R.string.default_orientation + titleRes = MR.strings.default_orientation val enumConstants = OrientationType.entries.drop(1) entriesRes = enumConstants.map { it.stringRes }.toTypedArray() entryValues = enumConstants.map { value -> value.flagValue } @@ -111,7 +114,7 @@ class SettingsReaderController : SettingsLegacyController() { } intListPreference(activity) { key = Keys.readerTheme - titleRes = R.string.background_color + titleRes = MR.strings.background_color val enumConstants = ReaderBackgroundColor.entries entriesRes = enumConstants.map { it.longStringRes ?: it.stringRes }.toTypedArray() entryValues = enumConstants.map { it.prefValue } @@ -119,13 +122,13 @@ class SettingsReaderController : SettingsLegacyController() { } switchPreference { key = Keys.fullscreen - titleRes = R.string.fullscreen + titleRes = MR.strings.fullscreen defaultValue = true } switchPreference { bindTo(readerPreferences.cutoutShort()) // FIXME: Transition from reader to homepage is broken when cutout short is disabled - title = context.getString(R.string.pref_cutout_short).addBetaTag(context) + title = context.getString(MR.strings.pref_cutout_short).addBetaTag(context) preferences.fullscreen().changesIn(viewScope) { isVisible = DeviceUtil.hasCutout(activity).ordinal >= DeviceUtil.CutoutSupport.MODERN.ordinal && it @@ -133,8 +136,8 @@ class SettingsReaderController : SettingsLegacyController() { } if (DeviceUtil.isVivo && DeviceUtil.hasCutout(activity) == DeviceUtil.CutoutSupport.LEGACY) { preference { - title = context.getString(R.string.pref_legacy_cutout).addBetaTag(context) - summaryRes = R.string.pref_legacy_cutout_info + title = context.getString(MR.strings.pref_legacy_cutout).addBetaTag(context) + summaryRes = MR.strings.pref_legacy_cutout_info onClick { val intent = Intent().apply { @@ -146,7 +149,7 @@ class SettingsReaderController : SettingsLegacyController() { } listPreference(activity) { bindTo(readerPreferences.landscapeCutoutBehavior()) - title = "${context.getString(R.string.cutout_area_behavior)} (${context.getString(R.string.landscape)})" + title = "${context.getString(MR.strings.cutout_area_behavior)} (${context.getString(MR.strings.landscape)})" val values = LandscapeCutoutBehaviour.entries entriesRes = values.map { it.titleResId }.toTypedArray() entryValues = values.map { it.name } @@ -157,47 +160,47 @@ class SettingsReaderController : SettingsLegacyController() { } switchPreference { key = Keys.keepScreenOn - titleRes = R.string.keep_screen_on + titleRes = MR.strings.keep_screen_on defaultValue = true } switchPreference { key = Keys.showPageNumber - titleRes = R.string.show_page_number + titleRes = MR.strings.show_page_number defaultValue = true } } preferenceCategory { - titleRes = R.string.reading + titleRes = MR.strings.reading switchPreference { key = Keys.skipRead - titleRes = R.string.skip_read_chapters + titleRes = MR.strings.skip_read_chapters defaultValue = false } switchPreference { key = Keys.skipFiltered - titleRes = R.string.skip_filtered_chapters + titleRes = MR.strings.skip_filtered_chapters defaultValue = true } switchPreference { bindTo(preferences.skipDupe()) - titleRes = R.string.skip_dupe_chapters + titleRes = MR.strings.skip_dupe_chapters } switchPreference { key = Keys.alwaysShowChapterTransition - titleRes = R.string.always_show_chapter_transition - summaryRes = R.string.if_disabled_transition_will_skip + titleRes = MR.strings.always_show_chapter_transition + summaryRes = MR.strings.if_disabled_transition_will_skip defaultValue = true } } preferenceCategory { - titleRes = R.string.paged + titleRes = MR.strings.paged intListPreference(activity) { key = Keys.navigationModePager - titleRes = R.string.tap_zones + titleRes = MR.strings.tap_zones entries = context.resources.getStringArray(R.array.reader_nav).also { values -> entryRange = 0..values.size }.toList() @@ -205,12 +208,12 @@ class SettingsReaderController : SettingsLegacyController() { } listPreference(activity) { key = Keys.pagerNavInverted - titleRes = R.string.invert_tapping + titleRes = MR.strings.invert_tapping entriesRes = arrayOf( - R.string.none, - R.string.horizontally, - R.string.vertically, - R.string.both_axes, + MR.strings.none, + MR.strings.horizontally, + MR.strings.vertically, + MR.strings.both_axes, ) entryValues = listOf( ViewerNavigation.TappingInvertMode.NONE.name, @@ -223,14 +226,14 @@ class SettingsReaderController : SettingsLegacyController() { intListPreference(activity) { key = Keys.imageScaleType - titleRes = R.string.scale_type + titleRes = MR.strings.scale_type entriesRes = arrayOf( - R.string.fit_screen, - R.string.stretch, - R.string.fit_width, - R.string.fit_height, - R.string.original_size, - R.string.smart_fit, + MR.strings.fit_screen, + MR.strings.stretch, + MR.strings.fit_width, + MR.strings.fit_height, + MR.strings.original_size, + MR.strings.smart_fit, ) entryRange = 1..6 defaultValue = 1 @@ -238,7 +241,7 @@ class SettingsReaderController : SettingsLegacyController() { listPreference(activity) { bindTo(readerPreferences.pagerCutoutBehavior()) - titleRes = R.string.cutout_area_behavior + titleRes = MR.strings.cutout_area_behavior val values = CutoutBehaviour.entries entriesRes = values.map { it.titleResId }.toTypedArray() entryValues = values.map { it.name } @@ -256,61 +259,61 @@ class SettingsReaderController : SettingsLegacyController() { switchPreference { bindTo(preferences.landscapeZoom()) - titleRes = R.string.zoom_double_page_spreads + titleRes = MR.strings.zoom_double_page_spreads visibleIf(preferences.imageScaleType()) { it == 1 } } intListPreference(activity) { key = Keys.zoomStart - titleRes = R.string.zoom_start_position + titleRes = MR.strings.zoom_start_position entriesRes = arrayOf( - R.string.automatic, - R.string.left, - R.string.right, - R.string.center, + MR.strings.automatic, + MR.strings.left, + MR.strings.right, + MR.strings.center, ) entryRange = 1..4 defaultValue = 1 } switchPreference { key = Keys.cropBorders - titleRes = R.string.crop_borders + titleRes = MR.strings.crop_borders defaultValue = false } switchPreference { bindTo(preferences.navigateToPan()) - titleRes = R.string.navigate_pan + titleRes = MR.strings.navigate_pan } intListPreference(activity) { key = Keys.pageLayout - title = context.getString(R.string.page_layout).addBetaTag(context) - dialogTitleRes = R.string.page_layout + title = context.getString(MR.strings.page_layout).addBetaTag(context) + dialogTitleRes = MR.strings.page_layout val enumConstants = PageLayout.entries entriesRes = enumConstants.map { it.fullStringRes }.toTypedArray() entryValues = enumConstants.map { it.value } defaultValue = PageLayout.AUTOMATIC.value } - infoPreference(R.string.automatic_can_still_switch).apply { + infoPreference(MR.strings.automatic_can_still_switch).apply { preferences.pageLayout().changesIn(viewScope) { isVisible = it == PageLayout.AUTOMATIC.value } } switchPreference { key = Keys.automaticSplitsPage - titleRes = R.string.split_double_pages_portrait + titleRes = MR.strings.split_double_pages_portrait defaultValue = false preferences.pageLayout().changesIn(viewScope) { isVisible = it == PageLayout.AUTOMATIC.value } } switchPreference { key = Keys.invertDoublePages - titleRes = R.string.invert_double_pages + titleRes = MR.strings.invert_double_pages defaultValue = false preferences.pageLayout().changesIn(viewScope) { isVisible = it != PageLayout.SINGLE_PAGE.value } } } preferenceCategory { - titleRes = R.string.long_strip + titleRes = MR.strings.long_strip intListPreference(activity) { key = Keys.navigationModeWebtoon - titleRes = R.string.tap_zones + titleRes = MR.strings.tap_zones entries = context.resources.getStringArray(R.array.reader_nav).also { values -> entryRange = 0..values.size }.toList() @@ -318,12 +321,12 @@ class SettingsReaderController : SettingsLegacyController() { } listPreference(activity) { key = Keys.webtoonNavInverted - titleRes = R.string.invert_tapping + titleRes = MR.strings.invert_tapping entriesRes = arrayOf( - R.string.none, - R.string.horizontally, - R.string.vertically, - R.string.both_axes, + MR.strings.none, + MR.strings.horizontally, + MR.strings.vertically, + MR.strings.both_axes, ) entryValues = listOf( ViewerNavigation.TappingInvertMode.NONE.name, @@ -335,27 +338,27 @@ class SettingsReaderController : SettingsLegacyController() { } listPreference(activity) { bindTo(preferences.webtoonReaderHideThreshold()) - titleRes = R.string.pref_hide_threshold + titleRes = MR.strings.pref_hide_threshold val enumValues = PreferenceValues.ReaderHideThreshold.entries entriesRes = enumValues.map { it.titleResId }.toTypedArray() entryValues = enumValues.map { it.name } } switchPreference { key = Keys.cropBordersWebtoon - titleRes = R.string.crop_borders + titleRes = MR.strings.crop_borders defaultValue = false } intListPreference(activity) { key = Keys.webtoonSidePadding - titleRes = R.string.pref_long_strip_side_padding + titleRes = MR.strings.pref_long_strip_side_padding entriesRes = arrayOf( - R.string.long_strip_side_padding_0, - R.string.long_strip_side_padding_5, - R.string.long_strip_side_padding_10, - R.string.long_strip_side_padding_15, - R.string.long_strip_side_padding_20, - R.string.long_strip_side_padding_25, + MR.strings.long_strip_side_padding_0, + MR.strings.long_strip_side_padding_5, + MR.strings.long_strip_side_padding_10, + MR.strings.long_strip_side_padding_15, + MR.strings.long_strip_side_padding_20, + MR.strings.long_strip_side_padding_25, ) entryValues = listOf(0, 5, 10, 15, 20, 25) defaultValue = "0" @@ -363,8 +366,8 @@ class SettingsReaderController : SettingsLegacyController() { intListPreference(activity) { key = Keys.webtoonPageLayout - title = context.getString(R.string.page_layout) - dialogTitleRes = R.string.page_layout + title = context.getString(MR.strings.page_layout) + dialogTitleRes = MR.strings.page_layout val enumConstants = arrayOf(PageLayout.SINGLE_PAGE, PageLayout.SPLIT_PAGES) entriesRes = enumConstants.map { it.fullStringRes }.toTypedArray() entryValues = enumConstants.map { it.webtoonValue } @@ -373,27 +376,27 @@ class SettingsReaderController : SettingsLegacyController() { switchPreference { key = Keys.webtoonInvertDoublePages - titleRes = R.string.invert_double_pages + titleRes = MR.strings.invert_double_pages defaultValue = false } switchPreference { key = Keys.webtoonEnableZoomOut - titleRes = R.string.enable_zoom_out + titleRes = MR.strings.enable_zoom_out defaultValue = false } } preferenceCategory { - titleRes = R.string.navigation + titleRes = MR.strings.navigation switchPreference { key = Keys.readWithVolumeKeys - titleRes = R.string.volume_keys + titleRes = MR.strings.volume_keys defaultValue = false } switchPreference { key = Keys.readWithVolumeKeysInverted - titleRes = R.string.invert_volume_keys + titleRes = MR.strings.invert_volume_keys defaultValue = false preferences.readWithVolumeKeys().changesIn(viewScope) { isVisible = it } @@ -401,17 +404,17 @@ class SettingsReaderController : SettingsLegacyController() { } preferenceCategory { - titleRes = R.string.actions + titleRes = MR.strings.actions switchPreference { key = Keys.readWithLongTap - titleRes = R.string.show_on_long_press + titleRes = MR.strings.show_on_long_press defaultValue = true } switchPreference { bindTo(preferences.folderPerManga()) - titleRes = R.string.save_pages_separately - summaryRes = R.string.create_folders_by_manga_title + titleRes = MR.strings.save_pages_separately + summaryRes = MR.strings.create_folders_by_manga_title } } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsSecurityController.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsSecurityController.kt index 280fc9f0a0..f0fca64512 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsSecurityController.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsSecurityController.kt @@ -3,6 +3,9 @@ package eu.kanade.tachiyomi.ui.setting.controllers import androidx.fragment.app.FragmentActivity import androidx.preference.PreferenceScreen import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.core.security.SecurityPreferences import eu.kanade.tachiyomi.data.preference.PreferenceKeys import eu.kanade.tachiyomi.data.preference.PreferenceValues @@ -17,7 +20,7 @@ import eu.kanade.tachiyomi.ui.setting.listPreference import eu.kanade.tachiyomi.ui.setting.onChange import eu.kanade.tachiyomi.ui.setting.requireAuthentication import eu.kanade.tachiyomi.ui.setting.switchPreference -import eu.kanade.tachiyomi.ui.setting.titleRes +import eu.kanade.tachiyomi.ui.setting.titleMRes as titleRes import eu.kanade.tachiyomi.util.system.AuthenticatorUtil.isAuthenticationSupported import uy.kohesive.injekt.injectLazy @@ -25,30 +28,30 @@ class SettingsSecurityController : SettingsLegacyController() { private val securityPreferences: SecurityPreferences by injectLazy() override fun setupPreferenceScreen(screen: PreferenceScreen) = screen.apply { - titleRes = R.string.security + titleRes = MR.strings.security if (context.isAuthenticationSupported()) { switchPreference { bindTo(securityPreferences.useBiometrics()) - titleRes = R.string.lock_with_biometrics + titleRes = MR.strings.lock_with_biometrics defaultValue = false requireAuthentication( activity as? FragmentActivity, - context.getString(R.string.lock_with_biometrics), + context.getString(MR.strings.lock_with_biometrics), confirmationRequired = false, ) } intListPreference(activity) { key = PreferenceKeys.lockAfter - titleRes = R.string.lock_when_idle + titleRes = MR.strings.lock_when_idle val values = listOf(0, 2, 5, 10, 20, 30, 60, 90, 120, -1) - entries = values.mapNotNull { + entries = values.map { when (it) { - 0 -> context.getString(R.string.always) - -1 -> context.getString(R.string.never) - else -> resources?.getQuantityString( - R.plurals.after_minutes, + 0 -> context.getString(MR.strings.always) + -1 -> context.getString(MR.strings.never) + else -> context.getString( + MR.plurals.after_minutes, it, it, ) @@ -63,13 +66,13 @@ class SettingsSecurityController : SettingsLegacyController() { switchPreference { key = PreferenceKeys.hideNotificationContent - titleRes = R.string.hide_notification_content + titleRes = MR.strings.hide_notification_content defaultValue = false } listPreference(activity) { bindTo(preferences.secureScreen()) - titleRes = R.string.secure_screen + titleRes = MR.strings.secure_screen entriesRes = PreferenceValues.SecureScreenMode.entries.map { it.titleResId }.toTypedArray() entryValues = PreferenceValues.SecureScreenMode.entries.map { it.name } @@ -80,6 +83,6 @@ class SettingsSecurityController : SettingsLegacyController() { } } - infoPreference(R.string.secure_screen_summary) + infoPreference(MR.strings.secure_screen_summary) } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsSourcesController.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsSourcesController.kt index 513f52bb03..4b9d9ac9f7 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsSourcesController.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsSourcesController.kt @@ -9,6 +9,9 @@ import androidx.preference.CheckBoxPreference import androidx.preference.PreferenceGroup import androidx.preference.PreferenceScreen import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.core.preference.minusAssign import eu.kanade.tachiyomi.core.preference.plusAssign import eu.kanade.tachiyomi.source.SourceManager @@ -18,7 +21,7 @@ import eu.kanade.tachiyomi.ui.main.FloatingSearchInterface import eu.kanade.tachiyomi.ui.main.MainActivity import eu.kanade.tachiyomi.ui.setting.SettingsLegacyController import eu.kanade.tachiyomi.ui.setting.onChange -import eu.kanade.tachiyomi.ui.setting.titleRes +import eu.kanade.tachiyomi.ui.setting.titleMRes as titleRes import eu.kanade.tachiyomi.util.system.LocaleHelper import eu.kanade.tachiyomi.util.view.activityBinding import eu.kanade.tachiyomi.util.view.setOnQueryTextChangeListener @@ -42,11 +45,11 @@ class SettingsSourcesController : SettingsLegacyController(), FloatingSearchInte private var sorting = SourcesSort.Alpha override fun getSearchTitle(): String? { - return view?.context?.getString(R.string.search) + return view?.context?.getString(MR.strings.search) } override fun setupPreferenceScreen(screen: PreferenceScreen) = screen.apply { - titleRes = R.string.filter + titleRes = MR.strings.filter sorting = SourcesSort.from(preferences.sourceSorting().get()) ?: SourcesSort.Alpha activity?.invalidateOptionsMenu() // Get the list of active language codes. @@ -103,7 +106,7 @@ class SettingsSourcesController : SettingsLegacyController(), FloatingSearchInte val hiddenCatalogues = preferences.hiddenSources().get() val selectAllPreference = CheckBoxPreference(group.context).apply { - title = "\t\t${context.getString(R.string.all_sources)}" + title = "\t\t${context.getString(MR.strings.all_sources)}" key = "all_${sources.first().lang}" isPersistent = false isChecked = sources.all { it.id.toString() !in hiddenCatalogues } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsTrackingController.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsTrackingController.kt index e05abda2b7..fe97eebedc 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsTrackingController.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/SettingsTrackingController.kt @@ -4,6 +4,9 @@ import android.app.Activity import androidx.preference.PreferenceGroup import androidx.preference.PreferenceScreen import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.preference.changesIn import eu.kanade.tachiyomi.data.track.EnhancedTrackService import eu.kanade.tachiyomi.data.track.TrackManager @@ -23,7 +26,7 @@ import eu.kanade.tachiyomi.ui.setting.onClick import eu.kanade.tachiyomi.ui.setting.preference import eu.kanade.tachiyomi.ui.setting.preferenceCategory import eu.kanade.tachiyomi.ui.setting.switchPreference -import eu.kanade.tachiyomi.ui.setting.titleRes +import eu.kanade.tachiyomi.ui.setting.titleMRes as titleRes import eu.kanade.tachiyomi.util.system.launchIO import eu.kanade.tachiyomi.util.system.openInBrowser import eu.kanade.tachiyomi.util.view.snack @@ -44,20 +47,20 @@ class SettingsTrackingController : val trackPreferences: TrackPreferences by injectLazy() override fun setupPreferenceScreen(screen: PreferenceScreen) = screen.apply { - titleRes = R.string.tracking + titleRes = MR.strings.tracking switchPreference { key = Keys.autoUpdateTrack - titleRes = R.string.update_tracking_after_reading + titleRes = MR.strings.update_tracking_after_reading defaultValue = true } switchPreference { key = Keys.trackMarkedAsRead - titleRes = R.string.update_tracking_marked_read + titleRes = MR.strings.update_tracking_marked_read defaultValue = false } preferenceCategory { - titleRes = R.string.services + titleRes = MR.strings.services trackPreference(trackManager.myAnimeList) { activity?.openInBrowser(MyAnimeListApi.authUrl(), trackManager.myAnimeList.getLogoColor(), true) @@ -69,7 +72,7 @@ class SettingsTrackingController : key = "update_anilist_scoring" isPersistent = false isIconSpaceReserved = true - title = context.getString(R.string.update_tracking_scoring_type, context.getString(R.string.anilist)) + title = context.getString(MR.strings.update_tracking_scoring_type, context.getString(MR.strings.anilist)) preferences.getStringPref(trackManager.aniList.getUsername()) .changesIn(viewScope) { @@ -80,11 +83,11 @@ class SettingsTrackingController : viewScope.launchIO { val (result, error) = trackManager.aniList.updatingScoring() if (result) { - view?.snack(R.string.scoring_type_updated) + view?.snack(MR.strings.scoring_type_updated) } else { view?.snack( context.getString( - R.string.could_not_update_scoring_, + MR.strings.could_not_update_scoring_, error?.localizedMessage.orEmpty(), ), ) @@ -93,12 +96,12 @@ class SettingsTrackingController : } } trackPreference(trackManager.kitsu) { - val dialog = TrackLoginDialog(trackManager.kitsu, R.string.email) + val dialog = TrackLoginDialog(trackManager.kitsu, MR.strings.email) dialog.targetController = this@SettingsTrackingController dialog.showDialog(router) } trackPreference(trackManager.mangaUpdates) { - val dialog = TrackLoginDialog(trackManager.mangaUpdates, R.string.username) + val dialog = TrackLoginDialog(trackManager.mangaUpdates, MR.strings.username) dialog.targetController = this@SettingsTrackingController dialog.showDialog(router) } @@ -108,10 +111,10 @@ class SettingsTrackingController : trackPreference(trackManager.bangumi) { activity?.openInBrowser(BangumiApi.authUrl(), trackManager.bangumi.getLogoColor(), true) } - infoPreference(R.string.tracking_info) + infoPreference(MR.strings.tracking_info) } preferenceCategory { - titleRes = R.string.enhanced_services + titleRes = MR.strings.enhanced_services val sourceManager = Injekt.get() val enhancedTrackers = trackManager.services .filter { service -> @@ -119,7 +122,7 @@ class SettingsTrackingController : sourceManager.getCatalogueSources().any { service.accept(it) } } enhancedTrackers.forEach { trackPreference(it) } - infoPreference(R.string.enhanced_tracking_info) + infoPreference(MR.strings.enhanced_tracking_info) } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/database/ClearDatabaseController.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/database/ClearDatabaseController.kt index 19a3d9d053..62b9753bd6 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/database/ClearDatabaseController.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/database/ClearDatabaseController.kt @@ -29,6 +29,8 @@ import eu.kanade.tachiyomi.util.view.activityBinding import eu.kanade.tachiyomi.util.view.fullAppBarHeight import eu.kanade.tachiyomi.util.view.scrollViewWith import eu.kanade.tachiyomi.util.view.snack +import yokai.i18n.MR +import yokai.util.lang.getString import kotlin.math.max import kotlin.math.roundToInt import android.R as AR @@ -48,7 +50,7 @@ class ClearDatabaseController : override val presenter = ClearDatabasePresenter() override fun getTitle(): String? { - return activity?.getString(R.string.clear_database) + return activity?.getString(MR.strings.clear_database) } override fun onViewCreated(view: View) { @@ -116,10 +118,10 @@ class ClearDatabaseController : binding.fab.isInvisible = true binding.fab.setOnClickListener { if (adapter!!.selectedItemCount > 0) { - val item = arrayOf(activity!!.getString(R.string.clear_db_exclude_read)) + val item = arrayOf(activity!!.getString(MR.strings.clear_db_exclude_read)) val selected = booleanArrayOf(true) activity!!.materialAlertDialog() - .setCustomTitleAndMessage(0, activity!!.getString(R.string.clear_database_confirmation)) + .setCustomTitleAndMessage(0, activity!!.getString(MR.strings.clear_database_confirmation)) .setMultiChoiceItems(item, selected) { _, which, checked -> selected[which] = checked } @@ -192,7 +194,7 @@ class ClearDatabaseController : } else { binding.emptyView.show( R.drawable.ic_book_24dp, - R.string.database_clean, + MR.strings.database_clean, ) } menu?.forEach { menuItem -> menuItem.isVisible = size > 0 } @@ -246,6 +248,6 @@ class ClearDatabaseController : binding.fab.isVisible = false adapter.clearSelection() adapter.notifyDataSetChanged() - view?.snack(R.string.clear_database_completed) + view?.snack(MR.strings.clear_database_completed) } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/database/ClearDatabaseSourceItem.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/database/ClearDatabaseSourceItem.kt index 9a5cba5212..e3646b9350 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/database/ClearDatabaseSourceItem.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/database/ClearDatabaseSourceItem.kt @@ -12,6 +12,8 @@ import eu.kanade.tachiyomi.source.LocalSource import eu.kanade.tachiyomi.source.Source import eu.kanade.tachiyomi.source.SourceManager import eu.kanade.tachiyomi.source.icon +import yokai.i18n.MR +import yokai.util.lang.getString data class ClearDatabaseSourceItem(val source: Source, val mangaCount: Int) : AbstractFlexibleItem() { @@ -35,7 +37,7 @@ data class ClearDatabaseSourceItem(val source: Source, val mangaCount: Int) : Ab fun bind(source: Source, count: Int) { binding.title.text = source.toString() - binding.description.text = itemView.context.getString(R.string.clear_database_source_item_count, count) + binding.description.text = itemView.context.getString(MR.strings.clear_database_source_item_count, count) itemView.post { when { diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/debug/DebugController.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/debug/DebugController.kt index a24f9b8cb1..c2c23d9bee 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/debug/DebugController.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/debug/DebugController.kt @@ -4,7 +4,6 @@ import android.os.Build import androidx.preference.PreferenceScreen import androidx.webkit.WebViewCompat import eu.kanade.tachiyomi.BuildConfig -import eu.kanade.tachiyomi.R import eu.kanade.tachiyomi.ui.more.AboutController import eu.kanade.tachiyomi.ui.setting.SettingsLegacyController import eu.kanade.tachiyomi.ui.setting.onClick @@ -12,11 +11,12 @@ import eu.kanade.tachiyomi.ui.setting.preference import eu.kanade.tachiyomi.ui.setting.preferenceCategory import eu.kanade.tachiyomi.util.system.DeviceUtil import eu.kanade.tachiyomi.util.view.withFadeTransaction +import yokai.i18n.MR import java.text.DateFormat class DebugController : SettingsLegacyController() { - override fun getTitleRes() = R.string.pref_debug_info + override fun getTitleRes() = MR.strings.pref_debug_info private val dateFormat: DateFormat by lazy { preferences.dateFormat() diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/debug/WorkerInfoController.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/debug/WorkerInfoController.kt index 42b5dc30e5..5fba42a62d 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/debug/WorkerInfoController.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/debug/WorkerInfoController.kt @@ -9,6 +9,9 @@ import androidx.recyclerview.widget.LinearLayoutManager import com.mikepenz.fastadapter.FastAdapter import com.mikepenz.fastadapter.adapters.ItemAdapter import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.databinding.SubDebugControllerBinding import eu.kanade.tachiyomi.ui.base.controller.BaseCoroutineController import eu.kanade.tachiyomi.util.system.launchUI diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/legacy/SettingsDataLegacyController.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/legacy/SettingsDataLegacyController.kt index ca4e142dcb..5e9cf86c29 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/legacy/SettingsDataLegacyController.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/legacy/SettingsDataLegacyController.kt @@ -15,6 +15,9 @@ import androidx.lifecycle.lifecycleScope import androidx.preference.PreferenceScreen import com.hippo.unifile.UniFile import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.backup.BackupFileValidator import eu.kanade.tachiyomi.data.backup.create.BackupCreatorJob import eu.kanade.tachiyomi.data.backup.create.BackupOptions @@ -32,8 +35,8 @@ import eu.kanade.tachiyomi.ui.setting.onChange import eu.kanade.tachiyomi.ui.setting.onClick import eu.kanade.tachiyomi.ui.setting.preference import eu.kanade.tachiyomi.ui.setting.preferenceCategory -import eu.kanade.tachiyomi.ui.setting.summaryRes -import eu.kanade.tachiyomi.ui.setting.titleRes +import eu.kanade.tachiyomi.ui.setting.summaryMRes as summaryRes +import eu.kanade.tachiyomi.ui.setting.titleMRes as titleRes import eu.kanade.tachiyomi.util.system.DeviceUtil import eu.kanade.tachiyomi.util.system.disableItems import eu.kanade.tachiyomi.util.system.launchIO @@ -42,6 +45,8 @@ import eu.kanade.tachiyomi.util.system.openInBrowser import eu.kanade.tachiyomi.util.system.toast import eu.kanade.tachiyomi.util.system.tryTakePersistableUriPermission import eu.kanade.tachiyomi.util.system.withUIContext +import eu.kanade.tachiyomi.util.view.setPositiveButton +import eu.kanade.tachiyomi.util.view.setTitle import kotlinx.coroutines.flow.launchIn import kotlinx.coroutines.flow.onEach import uy.kohesive.injekt.injectLazy @@ -64,56 +69,56 @@ class SettingsDataLegacyController : SettingsLegacyController() { private val chapterCache: ChapterCache by injectLazy() override fun setupPreferenceScreen(screen: PreferenceScreen) = screen.apply { - titleRes = R.string.data_and_storage + titleRes = MR.strings.data_and_storage preference { key = "pref_storage_location" bindTo(storagePreferences.baseStorageDirectory()) - titleRes = R.string.storage_location + titleRes = MR.strings.storage_location onClick { try { val intent = Intent(Intent.ACTION_OPEN_DOCUMENT_TREE) startActivityForResult(intent, CODE_DATA_DIR) } catch (e: ActivityNotFoundException) { - activity?.toast(R.string.file_picker_error) + activity?.toast(MR.strings.file_picker_error) } } storagePreferences.baseStorageDirectory().changes() .onEach { path -> summary = UniFile.fromUri(context, path.toUri())?.let { dir -> - dir.filePath ?: context.getString(R.string.invalid_location, dir.uri) - } ?: context.getString(R.string.invalid_location_generic) + dir.filePath ?: context.getString(MR.strings.invalid_location, dir.uri) + } ?: context.getString(MR.strings.invalid_location_generic) } .launchIn(viewScope) } preference { key = "pref_create_backup" - titleRes = R.string.create_backup - summaryRes = R.string.can_be_used_to_restore + titleRes = MR.strings.create_backup + summaryRes = MR.strings.can_be_used_to_restore onClick { if (DeviceUtil.isMiui && DeviceUtil.isMiuiOptimizationDisabled()) { - context.toast(R.string.restore_miui_warning, Toast.LENGTH_LONG) + context.toast(MR.strings.restore_miui_warning, Toast.LENGTH_LONG) } if (!BackupCreatorJob.isManualJobRunning(context)) { showBackupCreateDialog() } else { - context.toast(R.string.backup_in_progress) + context.toast(MR.strings.backup_in_progress) } } } preference { key = "pref_restore_backup" - titleRes = R.string.restore_backup - summaryRes = R.string.restore_from_backup_file + titleRes = MR.strings.restore_backup + summaryRes = MR.strings.restore_from_backup_file onClick { if (DeviceUtil.isMiui && DeviceUtil.isMiuiOptimizationDisabled()) { - context.toast(R.string.restore_miui_warning, Toast.LENGTH_LONG) + context.toast(MR.strings.restore_miui_warning, Toast.LENGTH_LONG) } if (!BackupRestoreJob.isRunning(context)) { @@ -125,28 +130,28 @@ class SettingsDataLegacyController : SettingsLegacyController() { storageManager.getBackupsDirectory()?.let { intent.setDataAndType(it.uri, "*/*") } - val title = resources?.getString(R.string.select_backup_file) + val title = activity?.getString(MR.strings.select_backup_file) val chooser = Intent.createChooser(intent, title) startActivityForResult(chooser, CODE_BACKUP_RESTORE) } else { - context.toast(R.string.restore_in_progress) + context.toast(MR.strings.restore_in_progress) } } } preferenceCategory { - titleRes = R.string.automatic_backups + titleRes = MR.strings.automatic_backups intListPreference(activity) { bindTo(preferences.backupInterval()) - titleRes = R.string.backup_frequency + titleRes = MR.strings.backup_frequency entriesRes = arrayOf( - R.string.manual, - R.string.every_6_hours, - R.string.every_12_hours, - R.string.daily, - R.string.every_2_days, - R.string.weekly, + MR.strings.manual, + MR.strings.every_6_hours, + MR.strings.every_12_hours, + MR.strings.daily, + MR.strings.every_2_days, + MR.strings.weekly, ) entryValues = listOf(0, 6, 12, 24, 48, 168) @@ -158,7 +163,7 @@ class SettingsDataLegacyController : SettingsLegacyController() { } intListPreference(activity) { bindTo(preferences.numberOfBackups()) - titleRes = R.string.max_auto_backups + titleRes = MR.strings.max_auto_backups entries = (1..5).map(Int::toString) entryRange = 1..5 @@ -166,29 +171,29 @@ class SettingsDataLegacyController : SettingsLegacyController() { } } - infoPreference(R.string.backup_info) + infoPreference(MR.strings.backup_info) preferenceCategory { - titleRes = R.string.storage_usage + titleRes = MR.strings.storage_usage preference { key = CLEAR_CACHE_KEY - titleRes = R.string.clear_chapter_cache - summary = context.getString(R.string.used_, chapterCache.readableSize) + titleRes = MR.strings.clear_chapter_cache + summary = context.getString(MR.strings.used_, chapterCache.readableSize) onClick { clearChapterCache() } } preference { key = "clear_cached_not_library" - titleRes = R.string.clear_cached_covers_non_library + titleRes = MR.strings.clear_cached_covers_non_library summary = context.getString( - R.string.delete_all_covers__not_in_library_used_, + MR.strings.delete_all_covers__not_in_library_used_, coverCache.getOnlineCoverCacheSize(), ) onClick { - context.toast(R.string.starting_cleanup) + context.toast(MR.strings.starting_cleanup) (activity as? AppCompatActivity)?.lifecycleScope?.launchIO { coverCache.deleteAllCachedCovers() } @@ -197,14 +202,14 @@ class SettingsDataLegacyController : SettingsLegacyController() { preference { key = "clean_cached_covers" - titleRes = R.string.clean_up_cached_covers + titleRes = MR.strings.clean_up_cached_covers summary = context.getString( - R.string.delete_old_covers_in_library_used_, + MR.strings.delete_old_covers_in_library_used_, coverCache.getChapterCacheSize(), ) onClick { - context.toast(R.string.starting_cleanup) + context.toast(MR.strings.starting_cleanup) (activity as? AppCompatActivity)?.lifecycleScope?.launchIO { coverCache.deleteOldCovers() } @@ -230,7 +235,7 @@ class SettingsDataLegacyController : SettingsLegacyController() { val uri = data.data if (uri == null) { - activity.toast(R.string.backup_restore_invalid_uri) + activity.toast(MR.strings.backup_restore_invalid_uri) return } @@ -270,7 +275,7 @@ class SettingsDataLegacyController : SettingsLegacyController() { } else { UniFile.fromUri(activity, uri)?.createFile(Backup.getBackupFilename())?.uri } ?: return - activity.toast(R.string.creating_backup) + activity.toast(MR.strings.creating_backup) BackupCreatorJob.startNow(activity, actualUri, options) } @@ -279,7 +284,7 @@ class SettingsDataLegacyController : SettingsLegacyController() { val dir = storageManager.getBackupsDirectory() if (dir == null) { - activity?.toast(R.string.invalid_location_generic) + activity?.toast(MR.strings.invalid_location_generic) return } @@ -297,7 +302,7 @@ class SettingsDataLegacyController : SettingsLegacyController() { startActivityForResult(intent, CODE_BACKUP_CREATE) } catch (e: ActivityNotFoundException) { - activity?.toast(R.string.file_picker_error) + activity?.toast(MR.strings.file_picker_error) } } @@ -306,7 +311,7 @@ class SettingsDataLegacyController : SettingsLegacyController() { val options = BackupOptions.getOptions().map { activity.getString(it) } activity.materialAlertDialog() - .setTitle(R.string.what_should_backup) + .setTitle(MR.strings.what_should_backup) .setMultiChoiceItems( options.toTypedArray(), BackupOptions().asBooleanArray(), @@ -316,7 +321,7 @@ class SettingsDataLegacyController : SettingsLegacyController() { listView.setItemChecked(position, true) } } - .setPositiveButton(R.string.create) { dialog, _ -> + .setPositiveButton(MR.strings.create) { dialog, _ -> val listView = (dialog as AlertDialog).listView val booleanArrayList = arrayListOf(true) // TODO: Allow library_entries to be disabled @@ -337,16 +342,16 @@ class SettingsDataLegacyController : SettingsLegacyController() { try { val results = BackupFileValidator().validate(activity, uri) - var message = activity.getString(R.string.restore_content_full) + var message = activity.getString(MR.strings.restore_content_full) if (results.missingSources.isNotEmpty()) { - message += "\n\n${activity.getString(R.string.restore_missing_sources)}\n${ + message += "\n\n${activity.getString(MR.strings.restore_missing_sources)}\n${ results.missingSources.joinToString( "\n", ) { "- $it" } }" } if (results.missingTrackers.isNotEmpty()) { - message += "\n\n${activity.getString(R.string.restore_missing_trackers)}\n${ + message += "\n\n${activity.getString(MR.strings.restore_missing_trackers)}\n${ results.missingTrackers.joinToString( "\n", ) { "- $it" } @@ -354,18 +359,18 @@ class SettingsDataLegacyController : SettingsLegacyController() { } activity.materialAlertDialog() - .setTitle(R.string.restore_backup) + .setTitle(MR.strings.restore_backup) .setMessage(message) - .setPositiveButton(R.string.restore) { _, _ -> + .setPositiveButton(MR.strings.restore) { _, _ -> val context = applicationContext if (context != null) { - activity.toast(R.string.restoring_backup) + activity.toast(MR.strings.restoring_backup) BackupRestoreJob.start(context, uri) } }.show() } catch (e: Exception) { activity.materialAlertDialog() - .setTitle(R.string.invalid_backup_file) + .setTitle(MR.strings.invalid_backup_file) .setMessage(e.message) .setPositiveButton(AR.string.cancel, null) .show() @@ -379,18 +384,18 @@ class SettingsDataLegacyController : SettingsLegacyController() { val deletedFiles = chapterCache.clear() withUIContext { activity?.toast( - resources?.getQuantityString( - R.plurals.cache_cleared, + activity?.getString( + MR.plurals.cache_cleared, deletedFiles, deletedFiles, ), ) findPreference(CLEAR_CACHE_KEY)?.summary = - resources?.getString(R.string.used_, chapterCache.readableSize) + activity?.getString(MR.strings.used_, chapterCache.readableSize) } } catch (_: Exception) { withUIContext { - activity?.toast(R.string.cache_delete_error) + activity?.toast(MR.strings.cache_delete_error) } } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/search/SettingsSearchController.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/search/SettingsSearchController.kt index 7c034051ca..bf8bd300e9 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/search/SettingsSearchController.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/search/SettingsSearchController.kt @@ -9,6 +9,9 @@ import android.view.View import androidx.appcompat.widget.SearchView import androidx.recyclerview.widget.LinearLayoutManager import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.databinding.SettingsSearchControllerBinding import eu.kanade.tachiyomi.ui.base.controller.BaseLegacyController import eu.kanade.tachiyomi.ui.main.SearchControllerInterface @@ -54,7 +57,7 @@ class SettingsSearchController : val searchItem = activityBinding?.searchToolbar?.searchItem searchView = activityBinding?.searchToolbar?.searchView - activityBinding?.searchToolbar?.setQueryHint(applicationContext?.getString(R.string.search_settings), false) + activityBinding?.searchToolbar?.setQueryHint(applicationContext?.getString(MR.strings.search_settings), false) searchItem?.expandActionView() setItems(getResultSet()) diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/search/SettingsSearchHolder.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/search/SettingsSearchHolder.kt index dc3eb5de7f..300a8e8ae4 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/search/SettingsSearchHolder.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/search/SettingsSearchHolder.kt @@ -4,6 +4,9 @@ import android.view.View import androidx.core.graphics.ColorUtils import eu.davidea.viewholders.FlexibleViewHolder import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.databinding.SettingsSearchControllerCardBinding import eu.kanade.tachiyomi.ui.setting.SettingsLegacyController import eu.kanade.tachiyomi.util.lang.highlightText diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/search/SettingsSearchItem.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/search/SettingsSearchItem.kt index 9e5d6b08b4..c62300eedc 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/search/SettingsSearchItem.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/setting/controllers/search/SettingsSearchItem.kt @@ -6,6 +6,9 @@ import eu.davidea.flexibleadapter.FlexibleAdapter import eu.davidea.flexibleadapter.items.AbstractFlexibleItem import eu.davidea.flexibleadapter.items.IFlexible import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource /** * Item that contains search result information. diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/source/BrowseController.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/source/BrowseController.kt index 6ae7b0be1f..30f5a8c239 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/source/BrowseController.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/source/BrowseController.kt @@ -57,6 +57,7 @@ import eu.kanade.tachiyomi.util.view.isCompose import eu.kanade.tachiyomi.util.view.isControllerVisible import eu.kanade.tachiyomi.util.view.onAnimationsFinished import eu.kanade.tachiyomi.util.view.scrollViewWith +import eu.kanade.tachiyomi.util.view.setAction import eu.kanade.tachiyomi.util.view.setOnQueryTextChangeListener import eu.kanade.tachiyomi.util.view.snack import eu.kanade.tachiyomi.util.view.toolbarHeight @@ -70,7 +71,9 @@ import kotlinx.parcelize.Parcelize import uy.kohesive.injekt.injectLazy import yokai.domain.base.BasePreferences import yokai.domain.base.BasePreferences.ExtensionInstaller +import yokai.i18n.MR import yokai.presentation.extension.repo.ExtensionRepoController +import yokai.util.lang.getString import java.util.* import kotlin.math.max @@ -122,10 +125,10 @@ class BrowseController : setHasOptionsMenu(true) } - override fun getTitle(): String? = view?.context?.getString(R.string.browse) + override fun getTitle(): String? = view?.context?.getString(MR.strings.browse) override fun getSearchTitle(): String? { - return searchTitle(view?.context?.getString(R.string.sources)?.lowercase(Locale.ROOT)) + return searchTitle(view?.context?.getString(MR.strings.sources)?.lowercase(Locale.ROOT)) } val presenter = SourcePresenter(this) @@ -292,9 +295,9 @@ class BrowseController : binding.bottomSheet.sheetToolbar.title = if (binding.bottomSheet.tabs.selectedTabPosition != 0) { binding.bottomSheet.root.currentSourceTitle - ?: view?.context?.getString(R.string.source_migration) + ?: view?.context?.getString(MR.strings.source_migration) } else { - view?.context?.getString(R.string.extensions) + view?.context?.getString(MR.strings.extensions) } val onExtensionTab = binding.bottomSheet.tabs.selectedTabPosition == 0 if (binding.bottomSheet.sheetToolbar.menu.findItem(if (onExtensionTab) R.id.action_search else R.id.action_migration_guide) != null) { @@ -323,7 +326,7 @@ class BrowseController : val searchView = searchItem.actionView as SearchView // Change hint to show global search. - searchView.queryHint = view?.context?.getString(R.string.search_extensions) + searchView.queryHint = view?.context?.getString(MR.strings.search_extensions) if (extQuery.isNotEmpty()) { searchView.setOnQueryTextListener(null) searchItem.expandActionView() @@ -594,9 +597,9 @@ class BrowseController : presenter.updateSources() - snackbar = view?.snack(R.string.source_hidden, Snackbar.LENGTH_INDEFINITE) { + snackbar = view?.snack(MR.strings.source_hidden, Snackbar.LENGTH_INDEFINITE) { anchorView = binding.bottomSheet.root - setAction(R.string.undo) { + setAction(MR.strings.undo) { val newCurrent = preferences.hiddenSources().get() preferences.hiddenSources().set(newCurrent - source.id.toString()) presenter.updateSources() @@ -675,7 +678,7 @@ class BrowseController : val searchView = activityBinding?.searchToolbar?.searchView // Change hint to show global search. - activityBinding?.searchToolbar?.searchQueryHint = view?.context?.getString(R.string.global_search) + activityBinding?.searchToolbar?.searchQueryHint = view?.context?.getString(MR.strings.global_search) // Create query listener which opens the global search view. setOnQueryTextChangeListener(searchView, true) { diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/source/LangItem.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/source/LangItem.kt index 888809f805..0eff2bf90a 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/source/LangItem.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/source/LangItem.kt @@ -6,6 +6,9 @@ import eu.davidea.flexibleadapter.FlexibleAdapter import eu.davidea.flexibleadapter.items.AbstractHeaderItem import eu.davidea.flexibleadapter.items.IFlexible import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource /** * Item that contains the language header. diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/source/SourceHolder.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/source/SourceHolder.kt index 26ecaadb12..69ae66b733 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/source/SourceHolder.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/source/SourceHolder.kt @@ -4,6 +4,9 @@ import android.content.res.ColorStateList import android.view.View import androidx.core.view.isVisible import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.databinding.SourceItemBinding import eu.kanade.tachiyomi.source.LocalSource import eu.kanade.tachiyomi.source.icon @@ -48,7 +51,7 @@ class SourceHolder(view: View, val adapter: SourceAdapter) : }, ), ) - compatToolTipText = context.getString(if (isPinned) R.string.unpin else R.string.pin) + compatToolTipText = context.getString(if (isPinned) MR.strings.unpin else MR.strings.pin) setImageResource( if (isPinned) { R.drawable.ic_pin_24dp diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/source/SourceItem.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/source/SourceItem.kt index a2eb13bfe6..14d1d58722 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/source/SourceItem.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/source/SourceItem.kt @@ -6,6 +6,9 @@ import eu.davidea.flexibleadapter.FlexibleAdapter import eu.davidea.flexibleadapter.items.AbstractSectionableItem import eu.davidea.flexibleadapter.items.IFlexible import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.source.CatalogueSource import eu.kanade.tachiyomi.source.LocalSource diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/source/browse/BrowseSourceController.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/source/browse/BrowseSourceController.kt index 65a7b1876e..6f235102a6 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/source/browse/BrowseSourceController.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/source/browse/BrowseSourceController.kt @@ -51,6 +51,7 @@ import eu.kanade.tachiyomi.util.view.fullAppBarHeight import eu.kanade.tachiyomi.util.view.inflate import eu.kanade.tachiyomi.util.view.isControllerVisible import eu.kanade.tachiyomi.util.view.scrollViewWith +import eu.kanade.tachiyomi.util.view.setAction import eu.kanade.tachiyomi.util.view.setOnQueryTextChangeListener import eu.kanade.tachiyomi.util.view.snack import eu.kanade.tachiyomi.util.view.withFadeTransaction @@ -58,6 +59,8 @@ import eu.kanade.tachiyomi.widget.AutofitRecyclerView import eu.kanade.tachiyomi.widget.EmptyView import eu.kanade.tachiyomi.widget.LinearLayoutManagerAccurateOffset import uy.kohesive.injekt.injectLazy +import yokai.i18n.MR +import yokai.util.lang.getString import kotlin.math.roundToInt /** @@ -169,7 +172,7 @@ open class BrowseSourceController(bundle: Bundle) : activityBinding?.appBar?.updateAppBarAfterY(recycler) activityBinding?.appBar?.lockYPos = true if (!presenter.sourceIsInitialized) { - activity?.toast(R.string.source_not_installed) + activity?.toast(MR.strings.source_not_installed) if (activity is SearchActivity) { activity?.finish() } else { @@ -308,12 +311,11 @@ open class BrowseSourceController(bundle: Bundle) : R.drawable.ic_heart_24dp } setIcon(icon) - val titleRes = if (!presenter.useLatest) { - R.string.latest + title = activity?.getString(if (!presenter.useLatest) { + MR.strings.latest } else { - R.string.popular - } - setTitle(titleRes) + MR.strings.popular + }) } } @@ -579,15 +581,15 @@ open class BrowseSourceController(bundle: Bundle) : actions += if (presenter.source is LocalSource) { EmptyView.Action( - R.string.local_source_help_guide, + MR.strings.local_source_help_guide, ) { openLocalSourceHelpGuide() } } else { - EmptyView.Action(R.string.retry, retryAction) + EmptyView.Action(MR.strings.retry, retryAction) } if (presenter.source is HttpSource) { actions += EmptyView.Action( - R.string.open_in_webview, + MR.strings.open_in_webview, ) { openInWebView() } } @@ -602,7 +604,7 @@ open class BrowseSourceController(bundle: Bundle) : ) } else { snack = binding.sourceLayout.snack(message, Snackbar.LENGTH_INDEFINITE) { - setAction(R.string.retry, retryAction) + setAction(MR.strings.retry, retryAction) } } if (isControllerVisible) { @@ -612,12 +614,12 @@ open class BrowseSourceController(bundle: Bundle) : private fun getErrorMessage(error: Throwable): String { if (error is NoResultsException) { - return activity!!.getString(R.string.no_results_found) + return activity!!.getString(MR.strings.no_results_found) } return when { error.message == null -> "" - error.message!!.startsWith("HTTP error") -> "${error.message}: ${activity!!.getString(R.string.check_site_in_web)}" + error.message!!.startsWith("HTTP error") -> "${error.message}: ${activity!!.getString(MR.strings.check_site_in_web)}" else -> error.message!! } } @@ -775,7 +777,7 @@ open class BrowseSourceController(bundle: Bundle) : this, onMangaAdded = { adapter?.notifyItemChanged(position) - snack = view.snack(R.string.added_to_library) + snack = view.snack(MR.strings.added_to_library) }, onMangaMoved = { adapter?.notifyItemChanged(position) }, onMangaDeleted = { presenter.confirmDeletion(manga) }, diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/source/browse/ProgressItem.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/source/browse/ProgressItem.kt index 6849c9b5ae..3abad83958 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/source/browse/ProgressItem.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/source/browse/ProgressItem.kt @@ -9,6 +9,9 @@ import eu.davidea.flexibleadapter.items.AbstractFlexibleItem import eu.davidea.flexibleadapter.items.IFlexible import eu.davidea.viewholders.FlexibleViewHolder import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource class ProgressItem : AbstractFlexibleItem() { diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/source/filter/GroupItem.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/source/filter/GroupItem.kt index 089dce1df3..feae31d43a 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/source/filter/GroupItem.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/source/filter/GroupItem.kt @@ -10,6 +10,9 @@ import eu.davidea.flexibleadapter.items.IFlexible import eu.davidea.flexibleadapter.items.ISectionable import eu.davidea.viewholders.ExpandableViewHolder import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.source.model.Filter import eu.kanade.tachiyomi.util.view.setAnimVectorCompat diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/source/filter/HeaderItem.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/source/filter/HeaderItem.kt index 22c72b8f97..2ef22b48c7 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/source/filter/HeaderItem.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/source/filter/HeaderItem.kt @@ -9,6 +9,9 @@ import eu.davidea.flexibleadapter.items.AbstractHeaderItem import eu.davidea.flexibleadapter.items.IFlexible import eu.davidea.viewholders.FlexibleViewHolder import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.source.model.Filter import eu.kanade.tachiyomi.util.system.getResourceColor diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/source/filter/SelectItem.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/source/filter/SelectItem.kt index 5afe787893..1a7fc00afb 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/source/filter/SelectItem.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/source/filter/SelectItem.kt @@ -7,6 +7,9 @@ import eu.davidea.flexibleadapter.items.AbstractFlexibleItem import eu.davidea.flexibleadapter.items.IFlexible import eu.davidea.viewholders.FlexibleViewHolder import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.source.model.Filter import eu.kanade.tachiyomi.widget.MaterialSpinnerView diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/source/filter/SortGroup.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/source/filter/SortGroup.kt index 54babb37e3..5288f1c766 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/source/filter/SortGroup.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/source/filter/SortGroup.kt @@ -7,6 +7,9 @@ import eu.davidea.flexibleadapter.items.AbstractExpandableHeaderItem import eu.davidea.flexibleadapter.items.IFlexible import eu.davidea.flexibleadapter.items.ISectionable import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.source.model.Filter import eu.kanade.tachiyomi.util.view.setAnimVectorCompat diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/source/filter/SortItem.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/source/filter/SortItem.kt index 3b53f4ed8a..fa7b9deb2b 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/source/filter/SortItem.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/source/filter/SortItem.kt @@ -7,6 +7,9 @@ import eu.davidea.flexibleadapter.items.AbstractSectionableItem import eu.davidea.flexibleadapter.items.IFlexible import eu.davidea.viewholders.FlexibleViewHolder import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.source.model.Filter import eu.kanade.tachiyomi.widget.SortTextView diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/source/filter/TextItem.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/source/filter/TextItem.kt index edd1822cd3..7666ee2246 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/source/filter/TextItem.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/source/filter/TextItem.kt @@ -9,6 +9,9 @@ import eu.davidea.flexibleadapter.items.AbstractFlexibleItem import eu.davidea.flexibleadapter.items.IFlexible import eu.davidea.viewholders.FlexibleViewHolder import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.source.model.Filter import eu.kanade.tachiyomi.widget.SimpleTextWatcher diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/source/filter/TriStateItem.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/source/filter/TriStateItem.kt index 0310453682..567d1ddc2e 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/source/filter/TriStateItem.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/source/filter/TriStateItem.kt @@ -9,6 +9,9 @@ import eu.davidea.viewholders.FlexibleViewHolder import eu.kanade.tachiyomi.source.model.Filter import eu.kanade.tachiyomi.widget.TriStateCheckBox import eu.kanade.tachiyomi.R as TR +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource open class TriStateItem(val filter: Filter.TriState) : AbstractFlexibleItem() { diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/source/globalsearch/GlobalSearchController.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/source/globalsearch/GlobalSearchController.kt index 1245263ee3..348db8a735 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/source/globalsearch/GlobalSearchController.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/source/globalsearch/GlobalSearchController.kt @@ -12,6 +12,9 @@ import com.bluelinelabs.conductor.ControllerChangeHandler import com.bluelinelabs.conductor.ControllerChangeType import com.google.android.material.snackbar.Snackbar import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.database.models.Manga import eu.kanade.tachiyomi.data.preference.PreferencesHelper import eu.kanade.tachiyomi.databinding.SourceGlobalSearchControllerBinding @@ -134,7 +137,7 @@ open class GlobalSearchController( holder?.updateManga(oldMangaIndex) } adapter.notifyItemChanged(position) - snack = view.snack(R.string.added_to_library) + snack = view.snack(MR.strings.added_to_library) }, onMangaMoved = { adapter.notifyItemChanged(position) }, onMangaDeleted = { presenter.confirmDeletion(manga) }, @@ -160,7 +163,7 @@ open class GlobalSearchController( inflater.inflate(R.menu.catalogue_new_list, menu) // Initialize search menu - activityBinding?.searchToolbar?.setQueryHint(view?.context?.getString(R.string.global_search), false) + activityBinding?.searchToolbar?.setQueryHint(view?.context?.getString(MR.strings.global_search), false) activityBinding?.searchToolbar?.searchItem?.expandActionView() activityBinding?.searchToolbar?.searchView?.setQuery(presenter.query, false) @@ -229,7 +232,7 @@ open class GlobalSearchController( binding.recycler.adapter = adapter scrollViewWith(binding.recycler, padBottom = true) if (extensionFilter != null) { - customTitle = view.context?.getString(R.string.loading) + customTitle = view.context?.getString(MR.strings.loading) setTitle() } diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/source/globalsearch/GlobalSearchItem.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/source/globalsearch/GlobalSearchItem.kt index 4d8d261049..2b86be234b 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/source/globalsearch/GlobalSearchItem.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/source/globalsearch/GlobalSearchItem.kt @@ -6,6 +6,9 @@ import eu.davidea.flexibleadapter.FlexibleAdapter import eu.davidea.flexibleadapter.items.AbstractFlexibleItem import eu.davidea.flexibleadapter.items.IFlexible import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.source.CatalogueSource /** diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/source/globalsearch/GlobalSearchMangaItem.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/source/globalsearch/GlobalSearchMangaItem.kt index 090f5808e0..a02fd571e8 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/source/globalsearch/GlobalSearchMangaItem.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/source/globalsearch/GlobalSearchMangaItem.kt @@ -6,6 +6,9 @@ import eu.davidea.flexibleadapter.FlexibleAdapter import eu.davidea.flexibleadapter.items.AbstractFlexibleItem import eu.davidea.flexibleadapter.items.IFlexible import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.database.models.Manga class GlobalSearchMangaItem(val manga: Manga) : AbstractFlexibleItem() { diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/webview/WebViewActivity.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/webview/WebViewActivity.kt index 0010155ad3..469fd012ba 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/webview/WebViewActivity.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/webview/WebViewActivity.kt @@ -13,6 +13,9 @@ import androidx.activity.addCallback import androidx.core.graphics.ColorUtils import co.touchlab.kermit.Logger import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.network.NetworkHelper import eu.kanade.tachiyomi.source.SourceManager import eu.kanade.tachiyomi.source.online.HttpSource @@ -197,7 +200,7 @@ open class WebViewActivity : BaseWebViewActivity() { type = "text/plain" putExtra(Intent.EXTRA_TEXT, binding.webview.url) } - startActivity(Intent.createChooser(intent, getString(R.string.share))) + startActivity(Intent.createChooser(intent, getString(MR.strings.share))) } catch (e: Exception) { toast(e.message) } diff --git a/app/src/main/java/eu/kanade/tachiyomi/util/CrashLogUtil.kt b/app/src/main/java/eu/kanade/tachiyomi/util/CrashLogUtil.kt index 0947ba2090..8fe488841a 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/util/CrashLogUtil.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/util/CrashLogUtil.kt @@ -17,6 +17,8 @@ import eu.kanade.tachiyomi.util.system.withNonCancellableContext import eu.kanade.tachiyomi.util.system.withUIContext import uy.kohesive.injekt.Injekt import uy.kohesive.injekt.api.get +import yokai.i18n.MR +import yokai.util.lang.getString import java.io.IOException class CrashLogUtil(private val context: Context) { @@ -79,20 +81,20 @@ class CrashLogUtil(private val context: Context) { private fun showNotification(uri: Uri) { context.notificationManager.cancel(Notifications.ID_CRASH_LOGS) with(notificationBuilder) { - setContentTitle(context.getString(R.string.crash_log_saved)) + setContentTitle(context.getString(MR.strings.crash_log_saved)) // Clear old actions if they exist clearActions() addAction( R.drawable.ic_bug_report_24dp, - context.getString(R.string.open_log), + context.getString(MR.strings.open_log), NotificationReceiver.openErrorOrSkippedLogPendingActivity(context, uri), ) addAction( R.drawable.ic_share_24dp, - context.getString(R.string.share), + context.getString(MR.strings.share), NotificationReceiver.shareCrashLogPendingBroadcast(context, uri, Notifications.ID_CRASH_LOGS), ) diff --git a/app/src/main/java/eu/kanade/tachiyomi/util/MangaExtensions.kt b/app/src/main/java/eu/kanade/tachiyomi/util/MangaExtensions.kt index 54a4ae2052..35fedc7440 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/util/MangaExtensions.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/util/MangaExtensions.kt @@ -11,6 +11,9 @@ import com.bluelinelabs.conductor.Controller import com.google.android.material.snackbar.BaseTransientBottomBar import com.google.android.material.snackbar.Snackbar import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.database.DatabaseHelper import eu.kanade.tachiyomi.data.database.models.Category import eu.kanade.tachiyomi.data.database.models.Manga @@ -34,6 +37,10 @@ import eu.kanade.tachiyomi.util.system.materialAlertDialog import eu.kanade.tachiyomi.util.system.setCustomTitleAndMessage import eu.kanade.tachiyomi.util.system.toast import eu.kanade.tachiyomi.util.system.withUIContext +import eu.kanade.tachiyomi.util.view.setAction +import eu.kanade.tachiyomi.util.view.setNegativeButton +import eu.kanade.tachiyomi.util.view.setPositiveButton +import eu.kanade.tachiyomi.util.view.setTitle import eu.kanade.tachiyomi.util.view.snack import eu.kanade.tachiyomi.util.view.withFadeTransaction import eu.kanade.tachiyomi.widget.TriStateCheckBox @@ -197,8 +204,8 @@ fun Manga.addOrRemoveToFavorites( db.setMangaCategories(listOf(mc), listOf(this)) (activity as? MainActivity)?.showNotificationPermissionPrompt() onMangaMoved() - return view.snack(activity.getString(R.string.added_to_, defaultCategory.name)) { - setAction(R.string.change) { + return view.snack(activity.getString(MR.strings.added_to_, defaultCategory.name)) { + setAction(MR.strings.change) { moveCategories(db, activity, onMangaMoved) } } @@ -219,19 +226,19 @@ fun Manga.addOrRemoveToFavorites( onMangaMoved() return view.snack( activity.getString( - R.string.added_to_, + MR.strings.added_to_, when (lastUsedCategories.size) { - 0 -> activity.getString(R.string.default_category).lowercase(Locale.ROOT) + 0 -> activity.getString(MR.strings.default_category).lowercase(Locale.ROOT) 1 -> lastUsedCategories.firstOrNull()?.name ?: "" - else -> activity.resources.getQuantityString( - R.plurals.category_plural, + else -> activity.getString( + MR.plurals.category_plural, lastUsedCategories.size, lastUsedCategories.size, ) }, ), ) { - setAction(R.string.change) { + setAction(MR.strings.change) { moveCategories(db, activity, onMangaMoved) } } @@ -245,13 +252,13 @@ fun Manga.addOrRemoveToFavorites( onMangaMoved() (activity as? MainActivity)?.showNotificationPermissionPrompt() return if (categories.isNotEmpty()) { - view.snack(activity.getString(R.string.added_to_, activity.getString(R.string.default_value))) { - setAction(R.string.change) { + view.snack(activity.getString(MR.strings.added_to_, activity.getString(MR.strings.default_value))) { + setAction(MR.strings.change) { moveCategories(db, activity, onMangaMoved) } } } else { - view.snack(R.string.added_to_library) + view.snack(MR.strings.added_to_library) } } else -> { // Always ask @@ -264,8 +271,8 @@ fun Manga.addOrRemoveToFavorites( date_added = 0 db.insertManga(this).executeAsBlocking() onMangaMoved() - return view.snack(view.context.getString(R.string.removed_from_library), Snackbar.LENGTH_INDEFINITE) { - setAction(R.string.undo) { + return view.snack(view.context.getString(MR.strings.removed_from_library), Snackbar.LENGTH_INDEFINITE) { + setAction(MR.strings.undo) { favorite = true date_added = lastAddedDate db.insertManga(this@addOrRemoveToFavorites).executeAsBlocking() @@ -343,12 +350,12 @@ private fun showAddDuplicateDialog( } activity.materialAlertDialog().apply { - setCustomTitleAndMessage(0, activity.getString(R.string.confirm_manga_add_duplicate, source.name)) + setCustomTitleAndMessage(0, activity.getString(MR.strings.confirm_manga_add_duplicate, source.name)) setItems( arrayOf( - activity.getString(R.string.show_, libraryManga.seriesType(activity, sourceManager)).asButton(activity), - activity.getString(R.string.add_to_library).asButton(activity), - activity.getString(R.string.migrate).asButton(activity, !newManga.initialized), + activity.getString(MR.strings.show_, libraryManga.seriesType(activity, sourceManager)).asButton(activity), + activity.getString(MR.strings.add_to_library).asButton(activity), + activity.getString(MR.strings.migrate).asButton(activity, !newManga.initialized), ), ) { dialog, i -> when (i) { @@ -359,20 +366,20 @@ private fun showAddDuplicateDialog( 1 -> addManga() 2 -> { if (!newManga.initialized) { - activity.toast(R.string.must_view_details_before_migration, Toast.LENGTH_LONG) + activity.toast(MR.strings.must_view_details_before_migration, Toast.LENGTH_LONG) return@setItems } activity.materialAlertDialog().apply { - setTitle(R.string.migration) + setTitle(MR.strings.migration) setMultiChoiceItems( titles, titles.map { true }.toBooleanArray(), null, ) - setPositiveButton(R.string.migrate) { mDialog, _ -> + setPositiveButton(MR.strings.migrate) { mDialog, _ -> migrateManga(mDialog, true) } - setNegativeButton(R.string.copy) { mDialog, _ -> + setNegativeButton(AR.string.copy) { mDialog, _ -> migrateManga(mDialog, false) } setNeutralButton(AR.string.cancel, null) @@ -393,7 +400,7 @@ private fun showAddDuplicateDialog( view?.setOnClickListener { if (!newManga.initialized) { activity.toast( - R.string.must_view_details_before_migration, + MR.strings.must_view_details_before_migration, Toast.LENGTH_LONG, ) } @@ -432,13 +439,13 @@ fun Manga.autoAddTrack(db: DatabaseHelper, onMangaMoved: () -> Unit) { fun Context.mapStatus(status: Int): String { return getString( when (status) { - SManga.ONGOING -> R.string.ongoing - SManga.COMPLETED -> R.string.completed - SManga.LICENSED -> R.string.licensed - SManga.PUBLISHING_FINISHED -> R.string.publishing_finished - SManga.CANCELLED -> R.string.cancelled - SManga.ON_HIATUS -> R.string.on_hiatus - else -> R.string.unknown + SManga.ONGOING -> MR.strings.ongoing + SManga.COMPLETED -> MR.strings.completed + SManga.LICENSED -> MR.strings.licensed + SManga.PUBLISHING_FINISHED -> MR.strings.publishing_finished + SManga.CANCELLED -> MR.strings.cancelled + SManga.ON_HIATUS -> MR.strings.on_hiatus + else -> MR.strings.unknown }, ) } @@ -446,12 +453,12 @@ fun Context.mapStatus(status: Int): String { fun Context.mapSeriesType(seriesType: Int): String { return getString( when (seriesType) { - Manga.TYPE_MANGA -> R.string.manga - Manga.TYPE_MANHWA -> R.string.manhwa - Manga.TYPE_MANHUA -> R.string.manhua - Manga.TYPE_COMIC -> R.string.comic - Manga.TYPE_WEBTOON -> R.string.webtoon - else -> R.string.unknown + Manga.TYPE_MANGA -> MR.strings.manga + Manga.TYPE_MANHWA -> MR.strings.manhwa + Manga.TYPE_MANHUA -> MR.strings.manhua + Manga.TYPE_COMIC -> MR.strings.comic + Manga.TYPE_WEBTOON -> MR.strings.webtoon + else -> MR.strings.unknown }, ) } diff --git a/app/src/main/java/eu/kanade/tachiyomi/util/TimeUtil.kt b/app/src/main/java/eu/kanade/tachiyomi/util/TimeUtil.kt index fb8f512c93..5857750006 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/util/TimeUtil.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/util/TimeUtil.kt @@ -5,17 +5,19 @@ import androidx.compose.runtime.Composable import androidx.compose.runtime.ReadOnlyComposable import androidx.compose.ui.res.stringResource import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import java.time.Instant import kotlin.time.Duration.Companion.minutes @Composable -@ReadOnlyComposable fun relativeTimeSpanString(epochMillis: Long): String { val now = Instant.now().toEpochMilli() return when { - epochMillis <= 0L -> stringResource(R.string.never) + epochMillis <= 0L -> stringResource(MR.strings.never) now - epochMillis < 1.minutes.inWholeMilliseconds -> stringResource( - R.string.just_now, + MR.strings.just_now, ) else -> DateUtils.getRelativeTimeSpanString(epochMillis, now, DateUtils.MINUTE_IN_MILLIS).toString() } diff --git a/app/src/main/java/eu/kanade/tachiyomi/util/chapter/ChapterUtil.kt b/app/src/main/java/eu/kanade/tachiyomi/util/chapter/ChapterUtil.kt index 49de8c28a8..ee32a6a9f1 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/util/chapter/ChapterUtil.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/util/chapter/ChapterUtil.kt @@ -15,6 +15,8 @@ import eu.kanade.tachiyomi.util.system.dpToPx import eu.kanade.tachiyomi.util.system.dpToPxEnd import eu.kanade.tachiyomi.util.system.getResourceColor import eu.kanade.tachiyomi.util.system.timeSpanFromNow +import yokai.i18n.MR +import yokai.util.lang.getString import java.text.DecimalFormat import java.text.DecimalFormatSymbols @@ -167,7 +169,7 @@ class ChapterUtil { fun Chapter.preferredChapterName(context: Context, manga: Manga, preferences: PreferencesHelper): String { return if (manga.hideChapterTitle(preferences) && isRecognizedNumber) { val number = decimalFormat.format(chapter_number.toDouble()) - context.getString(R.string.chapter_, number) + context.getString(MR.strings.chapter_, number) } else { name } diff --git a/app/src/main/java/eu/kanade/tachiyomi/util/lang/StringExtensions.kt b/app/src/main/java/eu/kanade/tachiyomi/util/lang/StringExtensions.kt index 47232fe731..cd431fc9dd 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/util/lang/StringExtensions.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/util/lang/StringExtensions.kt @@ -18,7 +18,11 @@ import androidx.core.text.inSpans import androidx.core.text.parseAsHtml import androidx.core.text.scale import androidx.core.text.superscript +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.util.system.getResourceColor import net.greypanther.natsort.CaseInsensitiveSimpleNaturalComparator import java.net.URI @@ -158,6 +162,9 @@ fun String.indexesOf(substr: String, ignoreCase: Boolean = true): List { fun String.withColor(@ColorInt colorInt: Int) = buildSpannedString { color(colorInt) { append(this@withColor) } } +fun String.withSubtitle(context: Context, subtitleRes: StringResource) = + withSubtitle(context, context.getString(subtitleRes)) + fun String.withSubtitle(context: Context, @StringRes subtitleRes: Int) = withSubtitle(context, context.getString(subtitleRes)) @@ -176,7 +183,7 @@ fun String.withSubtitle(context: Context, subtitle: String): Spanned { } fun String.addBetaTag(context: Context, useSuperScript: Boolean = true): Spanned { - val betaText = context.getString(R.string.beta) + val betaText = context.getString(MR.strings.beta) val colorS = context.getResourceColor(R.attr.colorSecondary) return buildSpannedString { append(this@addBetaTag) diff --git a/app/src/main/java/eu/kanade/tachiyomi/util/manga/MangaShortcutManager.kt b/app/src/main/java/eu/kanade/tachiyomi/util/manga/MangaShortcutManager.kt index 644cb676a7..77341c0534 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/util/manga/MangaShortcutManager.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/util/manga/MangaShortcutManager.kt @@ -11,6 +11,9 @@ import co.touchlab.kermit.Logger import coil3.imageLoader import coil3.request.ImageRequest import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.appwidget.TachiyomiWidgetManager import eu.kanade.tachiyomi.data.cache.CoverCache import eu.kanade.tachiyomi.data.database.DatabaseHelper @@ -82,11 +85,11 @@ class MangaShortcutManager( ) .setShortLabel( item.title.takeUnless { it.isBlank() } - ?: context.getString(R.string.manga), + ?: context.getString(MR.strings.manga), ) .setLongLabel( item.title.takeUnless { it.isBlank() } - ?: context.getString(R.string.manga), + ?: context.getString(MR.strings.manga), ) .setIcon( if (bitmap != null) if (android.os.Build.VERSION.SDK_INT >= android.os.Build.VERSION_CODES.O) { diff --git a/app/src/main/java/eu/kanade/tachiyomi/util/system/ContextExtensions.kt b/app/src/main/java/eu/kanade/tachiyomi/util/system/ContextExtensions.kt index b6f85365cb..73923e92db 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/util/system/ContextExtensions.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/util/system/ContextExtensions.kt @@ -45,6 +45,7 @@ import kotlinx.coroutines.NonCancellable import kotlinx.coroutines.withContext import uy.kohesive.injekt.Injekt import uy.kohesive.injekt.api.get +import yokai.i18n.MR import java.io.File import java.util.* import kotlin.math.max @@ -440,5 +441,5 @@ fun Context.tryTakePersistableUriPermission(uri: Uri, flags: Int) = try { contentResolver.takePersistableUriPermission(uri, flags) } catch (e: SecurityException) { Logger.e(e) - toast(R.string.file_picker_uri_permission_unsupported) + toast(MR.strings.file_picker_uri_permission_unsupported) } diff --git a/app/src/main/java/eu/kanade/tachiyomi/util/system/DateExtensions.kt b/app/src/main/java/eu/kanade/tachiyomi/util/system/DateExtensions.kt index b400272889..0d80ccf53f 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/util/system/DateExtensions.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/util/system/DateExtensions.kt @@ -2,22 +2,23 @@ package eu.kanade.tachiyomi.util.system import android.content.Context import android.text.format.DateUtils -import eu.kanade.tachiyomi.R -import java.util.Calendar -import java.util.Locale -import java.util.TimeZone +import dev.icerock.moko.resources.StringResource +import yokai.i18n.MR +import yokai.util.lang.getString +import java.util.* val Long.timeSpanFromNow: String get() = DateUtils.getRelativeTimeSpanString(this).toString() fun Long.timeSpanFromNow(context: Context): String { return if (this == 0L) { - context.getString(R.string.a_while_ago).lowercase(Locale.ROOT) + context.getString(MR.strings.a_while_ago).lowercase(Locale.ROOT) } else { DateUtils.getRelativeTimeSpanString(this).toString() } } +fun Context.timeSpanFromNow(res: StringResource, time: Long) = getString(res, time.timeSpanFromNow(this)) fun Context.timeSpanFromNow(res: Int, time: Long) = getString(res, time.timeSpanFromNow(this)) /** diff --git a/app/src/main/java/eu/kanade/tachiyomi/util/system/ImageUtil.kt b/app/src/main/java/eu/kanade/tachiyomi/util/system/ImageUtil.kt index 4011776002..2daafcdda7 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/util/system/ImageUtil.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/util/system/ImageUtil.kt @@ -26,6 +26,9 @@ import androidx.core.graphics.scale import co.touchlab.kermit.Logger import com.hippo.unifile.UniFile import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import okio.Buffer import okio.BufferedSource import tachiyomi.decoder.Format diff --git a/app/src/main/java/eu/kanade/tachiyomi/util/system/LocaleHelper.kt b/app/src/main/java/eu/kanade/tachiyomi/util/system/LocaleHelper.kt index 3861c9721d..be6f0fd5b5 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/util/system/LocaleHelper.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/util/system/LocaleHelper.kt @@ -3,6 +3,9 @@ package eu.kanade.tachiyomi.util.system import android.content.Context import androidx.core.os.LocaleListCompat import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.ui.source.SourcePresenter import java.util.Locale @@ -16,10 +19,10 @@ object LocaleHelper { */ fun getSourceDisplayName(lang: String?, context: Context): String { return when (lang) { - "", "other" -> context.getString(R.string.other) - SourcePresenter.LAST_USED_KEY -> context.getString(R.string.last_used) - SourcePresenter.PINNED_KEY -> context.getString(R.string.pinned) - "all" -> context.getString(R.string.all) + "", "other" -> context.getString(MR.strings.other) + SourcePresenter.LAST_USED_KEY -> context.getString(MR.strings.last_used) + SourcePresenter.PINNED_KEY -> context.getString(MR.strings.pinned) + "all" -> context.getString(MR.strings.all) else -> getDisplayName(lang) } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/util/system/MaterialAlertDialogExtensions.kt b/app/src/main/java/eu/kanade/tachiyomi/util/system/MaterialAlertDialogExtensions.kt index ba64e81ac4..a855434180 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/util/system/MaterialAlertDialogExtensions.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/util/system/MaterialAlertDialogExtensions.kt @@ -12,16 +12,18 @@ import androidx.appcompat.widget.AppCompatCheckedTextView import androidx.core.view.isVisible import androidx.recyclerview.widget.LinearLayoutManager import com.google.android.material.dialog.MaterialAlertDialogBuilder +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.databinding.CustomDialogTitleMessageBinding import eu.kanade.tachiyomi.databinding.DialogQuadstateBinding import eu.kanade.tachiyomi.widget.TriStateCheckBox import eu.kanade.tachiyomi.widget.materialdialogs.TriStateMultiChoiceDialogAdapter import eu.kanade.tachiyomi.widget.materialdialogs.TriStateMultiChoiceListener +import yokai.util.lang.getString fun Context.materialAlertDialog() = MaterialAlertDialogBuilder(withOriginalWidth()) fun MaterialAlertDialogBuilder.addCheckBoxPrompt( - @StringRes stringRes: Int, + stringRes: StringResource, isChecked: Boolean = false, listener: MaterialAlertDialogBuilderOnCheckClickListener? = null, ): MaterialAlertDialogBuilder { @@ -60,6 +62,19 @@ fun AlertDialog.disableItems(items: Array) { ) } +fun MaterialAlertDialogBuilder.setCustomTitleAndMessage(title: StringResource, message: String): MaterialAlertDialogBuilder { + return setCustomTitle( + (CustomDialogTitleMessageBinding.inflate(LayoutInflater.from(context))).apply { + if (title.resourceId != 0) { + alertTitle.text = context.getString(title) + } else { + alertTitle.isVisible = false + } + this.message.text = message + }.root, + ) +} + fun MaterialAlertDialogBuilder.setCustomTitleAndMessage(title: Int, message: String): MaterialAlertDialogBuilder { return setCustomTitle( (CustomDialogTitleMessageBinding.inflate(LayoutInflater.from(context))).apply { diff --git a/app/src/main/java/eu/kanade/tachiyomi/util/system/SideNavMode.kt b/app/src/main/java/eu/kanade/tachiyomi/util/system/SideNavMode.kt index 76a65c9783..a556cd219e 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/util/system/SideNavMode.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/util/system/SideNavMode.kt @@ -1,10 +1,14 @@ package eu.kanade.tachiyomi.util.system import androidx.annotation.StringRes +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource -enum class SideNavMode(val prefValue: Int, @StringRes val stringRes: Int) { - DEFAULT(0, R.string.default_behavior), - NEVER(1, R.string.never), - ALWAYS(2, R.string.always), +enum class SideNavMode(val prefValue: Int, val stringRes: StringResource) { + DEFAULT(0, MR.strings.default_behavior), + NEVER(1, MR.strings.never), + ALWAYS(2, MR.strings.always), } diff --git a/app/src/main/java/eu/kanade/tachiyomi/util/system/ThemeUtil.kt b/app/src/main/java/eu/kanade/tachiyomi/util/system/ThemeUtil.kt index 42279d327c..f846ec909f 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/util/system/ThemeUtil.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/util/system/ThemeUtil.kt @@ -9,6 +9,9 @@ import androidx.core.content.edit import androidx.core.view.WindowInsetsControllerCompat import androidx.preference.PreferenceManager import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.preference.PreferenceKeys import eu.kanade.tachiyomi.data.preference.PreferencesHelper import eu.kanade.tachiyomi.ui.reader.settings.ReaderBackgroundColor diff --git a/app/src/main/java/eu/kanade/tachiyomi/util/system/Themes.kt b/app/src/main/java/eu/kanade/tachiyomi/util/system/Themes.kt index 82e6e58ad0..a421fb9c59 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/util/system/Themes.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/util/system/Themes.kt @@ -3,78 +3,81 @@ package eu.kanade.tachiyomi.util.system import androidx.annotation.StringRes import androidx.annotation.StyleRes import androidx.appcompat.app.AppCompatDelegate +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource @Suppress("unused") -enum class Themes(@StyleRes val styleRes: Int, val nightMode: Int, @StringRes val nameRes: Int, @StringRes altNameRes: Int? = null) { +enum class Themes(@StyleRes val styleRes: Int, val nightMode: Int, val nameRes: StringResource, altNameRes: StringResource? = null) { MONET( R.style.Theme_Tachiyomi_Monet, AppCompatDelegate.MODE_NIGHT_FOLLOW_SYSTEM, - R.string.a_brighter_you, - R.string.a_calmer_you, + MR.strings.a_brighter_you, + MR.strings.a_calmer_you, ), DEFAULT( R.style.Theme_Tachiyomi, AppCompatDelegate.MODE_NIGHT_FOLLOW_SYSTEM, - R.string.white_theme, - R.string.dark, + MR.strings.white_theme, + MR.strings.dark, ), SPRING_AND_DUSK( R.style.Theme_Tachiyomi_MidnightDusk, AppCompatDelegate.MODE_NIGHT_FOLLOW_SYSTEM, - R.string.spring_blossom, - R.string.midnight_dusk, + MR.strings.spring_blossom, + MR.strings.midnight_dusk, ), STRAWBERRIES( R.style.Theme_Tachiyomi_Strawberries, AppCompatDelegate.MODE_NIGHT_FOLLOW_SYSTEM, - R.string.strawberry_daiquiri, - R.string.chocolate_strawberries, + MR.strings.strawberry_daiquiri, + MR.strings.chocolate_strawberries, ), TEAL_AND_SAPPHIRE( R.style.Theme_Tachiyomi_SapphireDusk, AppCompatDelegate.MODE_NIGHT_FOLLOW_SYSTEM, - R.string.teal_ocean, - R.string.sapphire_dusk, + MR.strings.teal_ocean, + MR.strings.sapphire_dusk, ), LAVENDER( R.style.Theme_Tachiyomi_Lavender, AppCompatDelegate.MODE_NIGHT_FOLLOW_SYSTEM, - R.string.lavender, - R.string.violet, + MR.strings.lavender, + MR.strings.violet, ), TAKO( R.style.Theme_Tachiyomi_Tako, AppCompatDelegate.MODE_NIGHT_FOLLOW_SYSTEM, - R.string.tako, + MR.strings.tako, ), YIN_AND_YANG( R.style.Theme_Tachiyomi_YinYang, AppCompatDelegate.MODE_NIGHT_FOLLOW_SYSTEM, - R.string.yang, - R.string.yin, + MR.strings.yang, + MR.strings.yin, ), LIME( R.style.Theme_Tachiyomi_FlatLime, AppCompatDelegate.MODE_NIGHT_FOLLOW_SYSTEM, - R.string.lime_time, - R.string.flat_lime, + MR.strings.lime_time, + MR.strings.flat_lime, ), YOTSUBA( R.style.Theme_Tachiyomi_Yotsuba, AppCompatDelegate.MODE_NIGHT_NO, - R.string.yotsuba, + MR.strings.yotsuba, ), DOKI( R.style.Theme_Tachiyomi_Doki, AppCompatDelegate.MODE_NIGHT_YES, - R.string.doki, + MR.strings.doki, ) ; val isDarkTheme = nightMode == AppCompatDelegate.MODE_NIGHT_YES val followsSystem = nightMode == AppCompatDelegate.MODE_NIGHT_FOLLOW_SYSTEM - @StringRes - val darkNameRes: Int = altNameRes ?: nameRes + val darkNameRes: StringResource = altNameRes ?: nameRes } diff --git a/app/src/main/java/eu/kanade/tachiyomi/util/view/ControllerExtensions.kt b/app/src/main/java/eu/kanade/tachiyomi/util/view/ControllerExtensions.kt index d1831a8928..5ce9ebb58e 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/util/view/ControllerExtensions.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/util/view/ControllerExtensions.kt @@ -72,6 +72,8 @@ import eu.kanade.tachiyomi.util.system.toInt import eu.kanade.tachiyomi.util.system.toast import eu.kanade.tachiyomi.widget.StatefulNestedScrollView import uy.kohesive.injekt.injectLazy +import yokai.i18n.MR +import yokai.util.lang.getString import kotlin.math.abs import kotlin.math.max import kotlin.math.pow @@ -797,7 +799,7 @@ fun Controller.withFadeInTransaction(): RouterTransaction { fun Controller.openInBrowser(url: String?) { if (url == null) { - activity?.toast(R.string.open_in_browser_fail) + activity?.toast(MR.strings.open_in_browser_fail) return } @@ -821,10 +823,10 @@ fun Controller.copyToClipboard(content: String, label: String?, useToast: Boolea label ?: return null if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.TIRAMISU) return null return if (useToast) { - activity.toast(view.context.getString(R.string._copied_to_clipboard, label)) + activity.toast(view.context.getString(MR.strings._copied_to_clipboard, label)) null } else { - view.snack(view.context.getString(R.string._copied_to_clipboard, label)) + view.snack(view.context.getString(MR.strings._copied_to_clipboard, label)) } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/util/view/ViewExtensions.kt b/app/src/main/java/eu/kanade/tachiyomi/util/view/ViewExtensions.kt index 010f32ecef..ba20546c8d 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/util/view/ViewExtensions.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/util/view/ViewExtensions.kt @@ -36,6 +36,7 @@ import androidx.annotation.Dimension import androidx.annotation.FloatRange import androidx.annotation.IdRes import androidx.annotation.RequiresApi +import androidx.appcompat.app.AlertDialog import androidx.appcompat.view.menu.MenuBuilder import androidx.appcompat.widget.PopupMenu import androidx.core.animation.addListener @@ -59,8 +60,11 @@ import androidx.recyclerview.widget.LinearSmoothScroller import androidx.recyclerview.widget.RecyclerView import androidx.recyclerview.widget.RecyclerView.SmoothScroller import androidx.swiperefreshlayout.widget.SwipeRefreshLayout +import com.github.florent37.viewtooltip.ViewTooltip import com.google.android.material.button.MaterialButton import com.google.android.material.card.MaterialCardView +import com.google.android.material.datepicker.MaterialDatePicker +import com.google.android.material.dialog.MaterialAlertDialogBuilder import com.google.android.material.math.MathUtils import com.google.android.material.navigation.NavigationBarItemView import com.google.android.material.navigation.NavigationBarMenuView @@ -68,7 +72,11 @@ import com.google.android.material.navigation.NavigationBarView import com.google.android.material.shape.CornerFamily import com.google.android.material.shape.ShapeAppearanceModel import com.google.android.material.snackbar.Snackbar +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.util.lang.tintText import eu.kanade.tachiyomi.util.system.ThemeUtil import eu.kanade.tachiyomi.util.system.dpToPx @@ -128,6 +136,17 @@ fun View.snack( return snack(context.getString(resource), length, f) } +fun View.snack( + resource: StringResource, + length: Int = Snackbar.LENGTH_SHORT, + f: (Snackbar.() -> Unit)? = null, +): Snackbar { + return snack(context.getString(resource), length, f) +} + +fun Snackbar.setAction(resource: StringResource, listener: View.OnClickListener?) = + setAction(context.getString(resource), listener) + fun Snackbar.getText(): CharSequence { val textView: TextView = view.findViewById(com.google.android.material.R.id.snackbar_text) return textView.text @@ -353,15 +372,18 @@ var View.compatToolTipText: CharSequence? ViewCompat.setTooltipText(this, value) } +fun TextView.setText(id: StringResource) = + setText(context.getString(id)) + @SuppressLint("RestrictedApi") inline fun View.popupMenu( - items: List>, + items: List>, selectedItemId: Int? = null, noinline onMenuItemClick: MenuItem.() -> Unit, ): PopupMenu { val popup = PopupMenu(context, this, Gravity.NO_GRAVITY) items.forEach { (id, stringRes) -> - popup.menu.add(0, id, 0, stringRes) + popup.menu.add(0, id, 0, context.getString(stringRes)) } if (selectedItemId != null) { @@ -445,6 +467,21 @@ inline fun ViewGroup.findDescendant(): T? { return descendants.find { it is T } as? T } +fun AlertDialog.Builder.setTitle(id: StringResource) = + setTitle(context.getString(id)) + +fun AlertDialog.Builder.setMessage(id: StringResource) = + setMessage(context.getString(id)) + +fun AlertDialog.Builder.setNeutralButton(id: StringResource, listener: DialogInterface.OnClickListener?) = + setNeutralButton(context.getString(id), listener) + +fun AlertDialog.Builder.setNegativeButton(id: StringResource, listener: DialogInterface.OnClickListener?) = + setNegativeButton(context.getString(id), listener) + +fun AlertDialog.Builder.setPositiveButton(id: StringResource, listener: DialogInterface.OnClickListener?) = + setPositiveButton(context.getString(id), listener) + fun Dialog.blurBehindWindow( window: Window?, blurAmount: Float = 20f, @@ -603,3 +640,10 @@ fun RecyclerView.onAnimationsFinished(callback: (RecyclerView) -> Unit) = post( } } ) + +// FIXME: Replace ViewTooltip with KMM compatible one, compose hopefully +fun ViewTooltip.text(id: StringResource) = text(id.resourceId) + +// FIXME: Replace with KMM compatible, hopefully compose +fun MaterialDatePicker.Builder.setTitleText(id: StringResource) = + setTitleText(id.resourceId) diff --git a/app/src/main/java/eu/kanade/tachiyomi/widget/EmptyView.kt b/app/src/main/java/eu/kanade/tachiyomi/widget/EmptyView.kt index 28adfc9b8e..6bbaa86939 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/widget/EmptyView.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/widget/EmptyView.kt @@ -11,9 +11,12 @@ import androidx.annotation.StringRes import androidx.core.view.isVisible import androidx.core.view.updateLayoutParams import com.google.android.material.button.MaterialButton +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.R import eu.kanade.tachiyomi.databinding.CommonViewEmptyBinding +import eu.kanade.tachiyomi.util.view.setText import eu.kanade.tachiyomi.util.view.setVectorCompat +import yokai.util.lang.getString import android.R as AR class EmptyView @JvmOverloads constructor(context: Context, attrs: AttributeSet? = null) : @@ -29,6 +32,14 @@ class EmptyView @JvmOverloads constructor(context: Context, attrs: AttributeSet? this.isVisible = false } + /** + * Show the information view + * @param textResource text of information view + */ + fun show(@DrawableRes drawable: Int, textResource: StringResource, actions: List? = null) { + show(drawable, context.getString(textResource), actions) + } + /** * Show the information view * @param textResource text of information view @@ -71,7 +82,7 @@ class EmptyView @JvmOverloads constructor(context: Context, attrs: AttributeSet? } data class Action( - @StringRes val resId: Int, + val resId: StringResource, val listener: OnClickListener, ) } diff --git a/app/src/main/java/eu/kanade/tachiyomi/widget/GridLayoutManagerAccurateOffset.kt b/app/src/main/java/eu/kanade/tachiyomi/widget/GridLayoutManagerAccurateOffset.kt index 3c0e750b52..a9b308afff 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/widget/GridLayoutManagerAccurateOffset.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/widget/GridLayoutManagerAccurateOffset.kt @@ -4,6 +4,9 @@ import android.content.Context import androidx.recyclerview.widget.GridLayoutManager import androidx.recyclerview.widget.RecyclerView import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource class GridLayoutManagerAccurateOffset(context: Context?, spanCount: Int) : GridLayoutManager(context, spanCount) { diff --git a/app/src/main/java/eu/kanade/tachiyomi/widget/LinearLayoutManagerAccurateOffset.kt b/app/src/main/java/eu/kanade/tachiyomi/widget/LinearLayoutManagerAccurateOffset.kt index 16c8caaee8..9498fda21e 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/widget/LinearLayoutManagerAccurateOffset.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/widget/LinearLayoutManagerAccurateOffset.kt @@ -7,6 +7,9 @@ import androidx.core.view.marginTop import androidx.recyclerview.widget.LinearLayoutManager import androidx.recyclerview.widget.RecyclerView import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.util.system.rootWindowInsetsCompat import kotlin.math.roundToInt diff --git a/app/src/main/java/eu/kanade/tachiyomi/widget/MaterialSpinnerView.kt b/app/src/main/java/eu/kanade/tachiyomi/widget/MaterialSpinnerView.kt index ada0f1cd85..bb994c7aa6 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/widget/MaterialSpinnerView.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/widget/MaterialSpinnerView.kt @@ -17,6 +17,9 @@ import androidx.core.graphics.ColorUtils import androidx.core.view.forEach import androidx.core.view.get import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.core.preference.Preference import eu.kanade.tachiyomi.databinding.MaterialSpinnerViewBinding import eu.kanade.tachiyomi.util.lang.tintText diff --git a/app/src/main/java/eu/kanade/tachiyomi/widget/MenuSheetItemView.kt b/app/src/main/java/eu/kanade/tachiyomi/widget/MenuSheetItemView.kt index 313579a8bf..7a186d812e 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/widget/MenuSheetItemView.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/widget/MenuSheetItemView.kt @@ -11,7 +11,11 @@ import androidx.annotation.DrawableRes import androidx.annotation.StringRes import androidx.core.view.isGone import androidx.core.widget.TextViewCompat +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.databinding.MenuSheetItemBinding import eu.kanade.tachiyomi.util.system.getResourceColor @@ -67,6 +71,10 @@ class MenuSheetItemView constructor(context: Context, attrs: AttributeSet?) : binding?.itemTextView?.textSize = value } + fun setText(res: StringResource) { + text = context.getString(res) + } + fun setText(@StringRes res: Int) { text = context.getString(res) } diff --git a/app/src/main/java/eu/kanade/tachiyomi/widget/MinMaxNumberPicker.kt b/app/src/main/java/eu/kanade/tachiyomi/widget/MinMaxNumberPicker.kt index 3ac8bb50e1..5388d5491e 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/widget/MinMaxNumberPicker.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/widget/MinMaxNumberPicker.kt @@ -7,6 +7,9 @@ import android.widget.EditText import android.widget.NumberPicker import androidx.core.view.doOnLayout import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.util.view.findDescendant class MinMaxNumberPicker @JvmOverloads constructor(context: Context, attrs: AttributeSet? = null) : diff --git a/app/src/main/java/eu/kanade/tachiyomi/widget/SimpleNavigationView.kt b/app/src/main/java/eu/kanade/tachiyomi/widget/SimpleNavigationView.kt index fd5649d118..7746b5d849 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/widget/SimpleNavigationView.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/widget/SimpleNavigationView.kt @@ -17,6 +17,9 @@ import com.google.android.material.textfield.TextInputLayout import eu.kanade.tachiyomi.util.view.inflate import kotlin.math.min import eu.kanade.tachiyomi.R as TR +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource @Suppress("LeakingThis") @SuppressLint("PrivateResource", "RestrictedApi") diff --git a/app/src/main/java/eu/kanade/tachiyomi/widget/SortTextView.kt b/app/src/main/java/eu/kanade/tachiyomi/widget/SortTextView.kt index 5994ce9862..92ff6bbc25 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/widget/SortTextView.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/widget/SortTextView.kt @@ -6,6 +6,9 @@ import android.view.LayoutInflater import android.widget.FrameLayout import androidx.core.view.updateLayoutParams import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.databinding.SortTextViewBinding import eu.kanade.tachiyomi.util.view.setVectorCompat diff --git a/app/src/main/java/eu/kanade/tachiyomi/widget/StaggeredGridLayoutManagerAccurateOffset.kt b/app/src/main/java/eu/kanade/tachiyomi/widget/StaggeredGridLayoutManagerAccurateOffset.kt index 2c4b277fe5..dc8f360187 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/widget/StaggeredGridLayoutManagerAccurateOffset.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/widget/StaggeredGridLayoutManagerAccurateOffset.kt @@ -5,6 +5,9 @@ import android.util.AttributeSet import androidx.recyclerview.widget.RecyclerView import androidx.recyclerview.widget.StaggeredGridLayoutManager import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource class StaggeredGridLayoutManagerAccurateOffset(context: Context?, attr: AttributeSet?, spanCount: Int, orientation: Int) : StaggeredGridLayoutManager(context, attr, spanCount, orientation) { diff --git a/app/src/main/java/eu/kanade/tachiyomi/widget/TabbedBottomSheet.kt b/app/src/main/java/eu/kanade/tachiyomi/widget/TabbedBottomSheet.kt index da62c1bf9f..c27ac163ca 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/widget/TabbedBottomSheet.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/widget/TabbedBottomSheet.kt @@ -10,10 +10,12 @@ import androidx.core.view.WindowInsetsCompat.Type.systemBars import androidx.core.widget.NestedScrollView import androidx.viewpager.widget.ViewPager import com.google.android.material.tabs.TabLayout +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.databinding.TabbedBottomSheetBinding import eu.kanade.tachiyomi.util.system.dpToPx import eu.kanade.tachiyomi.util.system.rootWindowInsetsCompat import eu.kanade.tachiyomi.util.view.expand +import yokai.util.lang.getString import kotlin.math.max abstract class TabbedBottomSheetDialog(private val activity: Activity) : @@ -66,7 +68,7 @@ abstract class TabbedBottomSheetDialog(private val activity: Activity) : abstract fun getTabViews(): List - abstract fun getTabTitles(): List + abstract fun getTabTitles(): List private inner class TabbedSheetAdapter : ViewPagerAdapter() { @@ -79,7 +81,7 @@ abstract class TabbedBottomSheetDialog(private val activity: Activity) : } override fun getPageTitle(position: Int): CharSequence { - return activity.resources!!.getString(getTabTitles()[position]) + return activity.getString(getTabTitles()[position]) } } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/widget/TachiyomiTextInputEditText.kt b/app/src/main/java/eu/kanade/tachiyomi/widget/TachiyomiTextInputEditText.kt index 1deaa32997..b24eea1166 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/widget/TachiyomiTextInputEditText.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/widget/TachiyomiTextInputEditText.kt @@ -6,6 +6,9 @@ import android.widget.EditText import androidx.core.view.inputmethod.EditorInfoCompat import com.google.android.material.textfield.TextInputEditText import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.preference.PreferencesHelper import eu.kanade.tachiyomi.data.preference.changesIn import kotlinx.coroutines.CoroutineScope diff --git a/app/src/main/java/eu/kanade/tachiyomi/widget/TriStateCheckBox.kt b/app/src/main/java/eu/kanade/tachiyomi/widget/TriStateCheckBox.kt index eedbc9698b..a89f128419 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/widget/TriStateCheckBox.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/widget/TriStateCheckBox.kt @@ -9,6 +9,9 @@ import android.widget.FrameLayout import androidx.core.graphics.ColorUtils import androidx.core.view.updateLayoutParams import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.databinding.TriStateCheckBoxBinding import eu.kanade.tachiyomi.util.system.getResourceColor import eu.kanade.tachiyomi.util.view.setAnimVectorCompat diff --git a/app/src/main/java/eu/kanade/tachiyomi/widget/materialdialogs/TriStateMultiChoiceViewHolder.kt b/app/src/main/java/eu/kanade/tachiyomi/widget/materialdialogs/TriStateMultiChoiceViewHolder.kt index 6be777ee37..77c408b402 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/widget/materialdialogs/TriStateMultiChoiceViewHolder.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/widget/materialdialogs/TriStateMultiChoiceViewHolder.kt @@ -3,6 +3,9 @@ package eu.kanade.tachiyomi.widget.materialdialogs import android.view.View import androidx.recyclerview.widget.RecyclerView import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.widget.TriStateCheckBox internal class TriStateMultiChoiceViewHolder( diff --git a/app/src/main/java/eu/kanade/tachiyomi/widget/preference/EditTextResetPreference.kt b/app/src/main/java/eu/kanade/tachiyomi/widget/preference/EditTextResetPreference.kt index 66ec4d24cb..add0922d17 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/widget/preference/EditTextResetPreference.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/widget/preference/EditTextResetPreference.kt @@ -15,6 +15,8 @@ import androidx.core.view.isVisible import androidx.preference.Preference.SummaryProvider import com.google.android.material.dialog.MaterialAlertDialogBuilder import eu.kanade.tachiyomi.R +import eu.kanade.tachiyomi.util.view.setNeutralButton +import yokai.i18n.MR import android.R as AR class EditTextResetPreference @JvmOverloads constructor( @@ -66,7 +68,7 @@ class EditTextResetPreference @JvmOverloads constructor( // Place cursor at the end textView.setSelection(textView.text.length) this.setView(view) - this.setNeutralButton(R.string.reset) { _, _ -> + this.setNeutralButton(MR.strings.reset) { _, _ -> if (callChangeListener(defValue)) { if (preferenceDataStore != null) { preferenceDataStore?.putString(key, null) diff --git a/app/src/main/java/eu/kanade/tachiyomi/widget/preference/IntListMatPreference.kt b/app/src/main/java/eu/kanade/tachiyomi/widget/preference/IntListMatPreference.kt index 709dba5474..ff3696cc63 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/widget/preference/IntListMatPreference.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/widget/preference/IntListMatPreference.kt @@ -5,6 +5,8 @@ import android.content.Context import android.util.AttributeSet import androidx.core.content.edit import com.google.android.material.dialog.MaterialAlertDialogBuilder +import dev.icerock.moko.resources.StringResource +import yokai.util.lang.getString class IntListMatPreference @JvmOverloads constructor( activity: Activity?, @@ -16,7 +18,7 @@ class IntListMatPreference @JvmOverloads constructor( var entryRange: IntRange get() = 0..0 set(value) { entryValues = value.toList() } - var entriesRes: Array + var entriesRes: Array get() = emptyArray() set(value) { entries = value.map { context.getString(it) } } private var defValue: Int = 0 diff --git a/app/src/main/java/eu/kanade/tachiyomi/widget/preference/ListMatPreference.kt b/app/src/main/java/eu/kanade/tachiyomi/widget/preference/ListMatPreference.kt index ff7855e4c3..a3bba3a987 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/widget/preference/ListMatPreference.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/widget/preference/ListMatPreference.kt @@ -6,6 +6,8 @@ import android.content.Context import android.util.AttributeSet import androidx.core.content.edit import com.google.android.material.dialog.MaterialAlertDialogBuilder +import dev.icerock.moko.resources.StringResource +import yokai.util.lang.getString open class ListMatPreference @JvmOverloads constructor( activity: Activity?, @@ -16,7 +18,7 @@ open class ListMatPreference @JvmOverloads constructor( MatPreference(activity, context, attrs) { var entryValues: List = emptyList() - var entriesRes: Array + var entriesRes: Array get() = emptyArray() set(value) { entries = value.map { context.getString(it) } } private var defValue: String = "" diff --git a/app/src/main/java/eu/kanade/tachiyomi/widget/preference/LoginDialogPreference.kt b/app/src/main/java/eu/kanade/tachiyomi/widget/preference/LoginDialogPreference.kt index d20fb6e2f2..ec94a99b03 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/widget/preference/LoginDialogPreference.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/widget/preference/LoginDialogPreference.kt @@ -6,6 +6,7 @@ import android.view.View import androidx.annotation.StringRes import com.bluelinelabs.conductor.ControllerChangeHandler import com.bluelinelabs.conductor.ControllerChangeType +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.data.preference.PreferencesHelper import eu.kanade.tachiyomi.databinding.PrefAccountLoginBinding import eu.kanade.tachiyomi.ui.base.controller.DialogController @@ -16,9 +17,10 @@ import kotlinx.coroutines.Job import kotlinx.coroutines.cancel import rx.Subscription import uy.kohesive.injekt.injectLazy +import yokai.util.lang.getString abstract class LoginDialogPreference( - @StringRes private val usernameLabelRes: Int? = null, + private val usernameLabelRes: StringResource? = null, bundle: Bundle? = null, ) : DialogController(bundle) { diff --git a/app/src/main/java/eu/kanade/tachiyomi/widget/preference/MatPreference.kt b/app/src/main/java/eu/kanade/tachiyomi/widget/preference/MatPreference.kt index ff9dcf590a..c1e739cb15 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/widget/preference/MatPreference.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/widget/preference/MatPreference.kt @@ -8,10 +8,13 @@ import androidx.annotation.StringRes import androidx.appcompat.app.AlertDialog import androidx.preference.Preference import com.google.android.material.dialog.MaterialAlertDialogBuilder +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.data.preference.PreferencesHelper import eu.kanade.tachiyomi.util.system.materialAlertDialog +import eu.kanade.tachiyomi.util.view.setTitle import uy.kohesive.injekt.Injekt import uy.kohesive.injekt.api.get +import yokai.util.lang.getString import android.R as AR open class MatPreference @JvmOverloads constructor( @@ -24,14 +27,14 @@ open class MatPreference @JvmOverloads constructor( protected val prefs: PreferencesHelper = Injekt.get() - @StringRes var preSummaryRes: Int? = null + var preSummaryRes: StringResource? = null set(value) { field = value notifyChanged() } private var isShowing = false - @StringRes var dialogTitleRes: Int? = null + var dialogTitleRes: StringResource? = null override fun onClick() { if (!isShowing) { @@ -60,7 +63,7 @@ open class MatPreference @JvmOverloads constructor( customSummaryProvider?.let { val preSummaryRes = preSummaryRes return if (preSummaryRes != null) { - context.getString(preSummaryRes, it.provideSummary(this)) + context.getString(preSummaryRes, it.provideSummary(this) ?: "") } else { it.provideSummary(this) } diff --git a/app/src/main/java/eu/kanade/tachiyomi/widget/preference/MultiListMatPreference.kt b/app/src/main/java/eu/kanade/tachiyomi/widget/preference/MultiListMatPreference.kt index 454e4fbef9..98db82c089 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/widget/preference/MultiListMatPreference.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/widget/preference/MultiListMatPreference.kt @@ -10,7 +10,9 @@ import androidx.core.content.edit import androidx.core.view.children import androidx.preference.Preference.SummaryProvider import com.google.android.material.dialog.MaterialAlertDialogBuilder +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.util.system.disableItems +import yokai.util.lang.getString import android.R as AR class MultiListMatPreference @JvmOverloads constructor( @@ -21,8 +23,8 @@ class MultiListMatPreference @JvmOverloads constructor( ) : ListMatPreference(activity, context, attrs) { - var allSelectionRes: Int? = null - var noSelectionRes: Int? = null + var allSelectionRes: StringResource? = null + var noSelectionRes: StringResource? = null /** All item is always selected and uncheckabele */ var allIsAlwaysSelected = false diff --git a/app/src/main/java/eu/kanade/tachiyomi/widget/preference/SwitchPreferenceCategory.kt b/app/src/main/java/eu/kanade/tachiyomi/widget/preference/SwitchPreferenceCategory.kt index c73e206cb4..a364324447 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/widget/preference/SwitchPreferenceCategory.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/widget/preference/SwitchPreferenceCategory.kt @@ -11,6 +11,9 @@ import androidx.appcompat.widget.SwitchCompat import androidx.preference.PreferenceCategory import androidx.preference.PreferenceViewHolder import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.util.system.getResourceColor import android.R as AR diff --git a/app/src/main/java/eu/kanade/tachiyomi/widget/preference/TrackLoginDialog.kt b/app/src/main/java/eu/kanade/tachiyomi/widget/preference/TrackLoginDialog.kt index c797f3586b..3ce1c6a5df 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/widget/preference/TrackLoginDialog.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/widget/preference/TrackLoginDialog.kt @@ -4,7 +4,11 @@ import android.os.Bundle import android.view.View import androidx.annotation.StringRes import br.com.simplepass.loadingbutton.animatedDrawables.ProgressType +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.track.TrackManager import eu.kanade.tachiyomi.data.track.TrackService import eu.kanade.tachiyomi.util.system.toast @@ -13,19 +17,19 @@ import kotlinx.coroutines.launch import uy.kohesive.injekt.Injekt import uy.kohesive.injekt.api.get -class TrackLoginDialog(@StringRes usernameLabelRes: Int? = null, bundle: Bundle? = null) : +class TrackLoginDialog(usernameLabelRes: StringResource? = null, bundle: Bundle? = null) : LoginDialogPreference(usernameLabelRes, bundle) { private val service = Injekt.get().getService(args.getInt("key"))!! override var canLogout = true - constructor(service: TrackService, @StringRes usernameLabelRes: Int?) : + constructor(service: TrackService, usernameLabelRes: StringResource?) : this(usernameLabelRes, Bundle().apply { putInt("key", service.id) }) override fun setCredentialsOnView(view: View) = with(view) { val serviceName = context.getString(service.nameRes()) - binding.dialogTitle.text = context.getString(R.string.log_in_to_, serviceName) + binding.dialogTitle.text = context.getString(MR.strings.log_in_to_, serviceName) binding.username.setText(service.getUsername()) binding.password.setText(service.getPassword()) } @@ -38,7 +42,7 @@ class TrackLoginDialog(@StringRes usernameLabelRes: Int? = null, bundle: Bundle? } if (binding.username.text.isNullOrBlank() || binding.password.text.isNullOrBlank()) { errorResult() - context.toast(R.string.username_must_not_be_blank) + context.toast(MR.strings.username_must_not_be_blank) return } @@ -51,7 +55,7 @@ class TrackLoginDialog(@StringRes usernameLabelRes: Int? = null, bundle: Bundle? val result = withIOContext { service.login(user, pass) } if (result) { dialog?.dismiss() - context.toast(R.string.successfully_logged_in) + context.toast(MR.strings.successfully_logged_in) } else { errorResult() } @@ -68,7 +72,7 @@ class TrackLoginDialog(@StringRes usernameLabelRes: Int? = null, bundle: Bundle? dialog?.setCancelable(true) dialog?.setCanceledOnTouchOutside(true) binding.login.revertAnimation { - binding.login.text = activity!!.getText(R.string.unknown_error) + binding.login.text = activity!!.getString(MR.strings.unknown_error) } } } diff --git a/app/src/main/java/eu/kanade/tachiyomi/widget/preference/TrackLogoutDialog.kt b/app/src/main/java/eu/kanade/tachiyomi/widget/preference/TrackLogoutDialog.kt index 5929e1b700..d0ed760313 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/widget/preference/TrackLogoutDialog.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/widget/preference/TrackLogoutDialog.kt @@ -3,11 +3,16 @@ package eu.kanade.tachiyomi.widget.preference import android.app.Dialog import android.os.Bundle import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.track.TrackManager import eu.kanade.tachiyomi.data.track.TrackService import eu.kanade.tachiyomi.ui.base.controller.DialogController import eu.kanade.tachiyomi.util.system.materialAlertDialog import eu.kanade.tachiyomi.util.system.toast +import eu.kanade.tachiyomi.util.view.setNegativeButton +import eu.kanade.tachiyomi.util.view.setPositiveButton import uy.kohesive.injekt.Injekt import uy.kohesive.injekt.api.get @@ -20,12 +25,12 @@ class TrackLogoutDialog(bundle: Bundle? = null) : DialogController(bundle) { override fun onCreateDialog(savedViewState: Bundle?): Dialog { val serviceName = activity!!.getString(service.nameRes()) return activity!!.materialAlertDialog() - .setTitle(activity!!.getString(R.string.log_out_from_, serviceName)) - .setNegativeButton(R.string.cancel, null) - .setPositiveButton(R.string.log_out) { _, _ -> + .setTitle(activity!!.getString(MR.strings.log_out_from_, serviceName)) + .setNegativeButton(MR.strings.cancel, null) + .setPositiveButton(MR.strings.log_out) { _, _ -> service.logout() (targetController as? Listener)?.trackLogoutDialogClosed(service) - activity!!.toast(R.string.successfully_logged_out) + activity!!.toast(MR.strings.successfully_logged_out) }.create() } diff --git a/app/src/main/java/eu/kanade/tachiyomi/widget/preference/TrackerPreference.kt b/app/src/main/java/eu/kanade/tachiyomi/widget/preference/TrackerPreference.kt index cc4b8305c0..4197d52c60 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/widget/preference/TrackerPreference.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/widget/preference/TrackerPreference.kt @@ -11,6 +11,9 @@ import androidx.preference.Preference import androidx.preference.PreferenceViewHolder import com.google.android.material.card.MaterialCardView import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.util.system.dpToPx import android.R as AR diff --git a/app/src/main/java/eu/kanade/tachiyomi/widget/preference/TriStateListPreference.kt b/app/src/main/java/eu/kanade/tachiyomi/widget/preference/TriStateListPreference.kt index ede659a2cc..0644e6a5ba 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/widget/preference/TriStateListPreference.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/widget/preference/TriStateListPreference.kt @@ -8,7 +8,11 @@ import androidx.core.content.edit import androidx.core.text.buildSpannedString import androidx.preference.Preference.SummaryProvider import com.google.android.material.dialog.MaterialAlertDialogBuilder +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.util.system.setTriStateItems import eu.kanade.tachiyomi.widget.TriStateCheckBox import android.R as AR @@ -21,7 +25,7 @@ class TriStateListPreference @JvmOverloads constructor( ) : ListMatPreference(activity, context, attrs) { - var allSelectionRes: Int? = null + var allSelectionRes: StringResource? = null var excludeKey: String? = null /** All item is always selected and uncheckabele */ @@ -71,11 +75,11 @@ class TriStateListPreference @JvmOverloads constructor( entryValues.indexOf(value).takeUnless { it == -1 } } }?.toIntArray()?.sorted()?.map { entries[it] }?.takeIf { it.isNotEmpty() } - ?: listOf(context.getString(R.string.none)) + ?: listOf(context.getString(MR.strings.none)) buildSpannedString { - append(context.getString(R.string.include_, includedStrings.joinToString())) + append(context.getString(MR.strings.include_, includedStrings.joinToString())) appendLine() - append(context.getString(R.string.exclude_, excludedStrings.joinToString())) + append(context.getString(MR.strings.exclude_, excludedStrings.joinToString())) } } diff --git a/app/src/main/java/yokai/core/migration/migrations/MyAnimeListMigration.kt b/app/src/main/java/yokai/core/migration/migrations/MyAnimeListMigration.kt index c299c511c1..966d1dc95b 100644 --- a/app/src/main/java/yokai/core/migration/migrations/MyAnimeListMigration.kt +++ b/app/src/main/java/yokai/core/migration/migrations/MyAnimeListMigration.kt @@ -2,6 +2,9 @@ package yokai.core.migration.migrations import eu.kanade.tachiyomi.App import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.track.TrackManager import eu.kanade.tachiyomi.util.system.toast import yokai.core.migration.Migration @@ -21,7 +24,7 @@ class MyAnimeListMigration : Migration { if (trackManager.myAnimeList.isLogged) { trackManager.myAnimeList.logout() - context.toast(R.string.myanimelist_relogin) + context.toast(MR.strings.myanimelist_relogin) } return true } diff --git a/app/src/main/java/yokai/domain/base/BasePreferences.kt b/app/src/main/java/yokai/domain/base/BasePreferences.kt index 2d2754d087..65793faffd 100644 --- a/app/src/main/java/yokai/domain/base/BasePreferences.kt +++ b/app/src/main/java/yokai/domain/base/BasePreferences.kt @@ -1,20 +1,20 @@ package yokai.domain.base -import androidx.annotation.StringRes -import eu.kanade.tachiyomi.R +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.core.preference.Preference import eu.kanade.tachiyomi.core.preference.PreferenceStore import eu.kanade.tachiyomi.core.preference.getEnum import eu.kanade.tachiyomi.extension.util.ExtensionInstaller +import yokai.i18n.MR class BasePreferences(private val preferenceStore: PreferenceStore) { fun extensionInstaller() = preferenceStore.getEnum("extension_installer", ExtensionInstaller.PACKAGEINSTALLER) - enum class ExtensionInstaller(@StringRes val titleResId: Int, val requiresSystemPermission: Boolean) { - PACKAGEINSTALLER(R.string.ext_installer_packageinstaller, true), - SHIZUKU(R.string.ext_installer_shizuku, false), - PRIVATE(R.string.ext_installer_private, false), - LEGACY(R.string.ext_installer_legacy, true), // Technically useless, but just in case it being missing crashes the app + enum class ExtensionInstaller(val titleResId: StringResource, val requiresSystemPermission: Boolean) { + PACKAGEINSTALLER(MR.strings.ext_installer_packageinstaller, true), + SHIZUKU(MR.strings.ext_installer_shizuku, false), + PRIVATE(MR.strings.ext_installer_private, false), + LEGACY(MR.strings.ext_installer_legacy, true), // Technically useless, but just in case it being missing crashes the app } fun displayProfile() = preferenceStore.getString("pref_display_profile_key", "") @@ -25,15 +25,15 @@ class BasePreferences(private val preferenceStore: PreferenceStore) { fun longTapBrowseNavBehaviour() = preferenceStore.getEnum("pref_browser_long_tap", LongTapBrowse.DEFAULT) - enum class LongTapBrowse(@StringRes val titleResId: Int) { - DEFAULT(R.string.browse_long_tap_default), - SEARCH(R.string.browse_long_tap_search), + enum class LongTapBrowse(val titleResId: StringResource) { + DEFAULT(MR.strings.browse_long_tap_default), + SEARCH(MR.strings.browse_long_tap_search), } fun longTapRecentsNavBehaviour() = preferenceStore.getEnum("pref_recents_long_tap", LongTapRecents.DEFAULT) - enum class LongTapRecents(@StringRes val titleResId: Int) { - DEFAULT(R.string.recents_long_tap_default), - LAST_READ(R.string.recents_long_tap_last_read) + enum class LongTapRecents(val titleResId: StringResource) { + DEFAULT(MR.strings.recents_long_tap_default), + LAST_READ(MR.strings.recents_long_tap_last_read) } } diff --git a/app/src/main/java/yokai/domain/ui/settings/ReaderPreferences.kt b/app/src/main/java/yokai/domain/ui/settings/ReaderPreferences.kt index 74a87e464f..5c587881cd 100644 --- a/app/src/main/java/yokai/domain/ui/settings/ReaderPreferences.kt +++ b/app/src/main/java/yokai/domain/ui/settings/ReaderPreferences.kt @@ -1,7 +1,11 @@ package yokai.domain.ui.settings import androidx.annotation.StringRes +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.core.preference.PreferenceStore import eu.kanade.tachiyomi.core.preference.getEnum import eu.kanade.tachiyomi.data.preference.PreferenceKeys @@ -13,14 +17,14 @@ class ReaderPreferences(private val preferenceStore: PreferenceStore) { fun landscapeCutoutBehavior() = preferenceStore.getEnum("landscape_cutout_behavior", LandscapeCutoutBehaviour.HIDE) - enum class CutoutBehaviour(@StringRes val titleResId: Int) { - HIDE(R.string.pad_cutout_areas), // Similar to CUTOUT_MODE_NEVER / J2K's pad - SHOW(R.string.start_past_cutout), // Similar to CUTOUT_MODE_SHORT_EDGES / J2K's start past - IGNORE(R.string.cutout_ignore), // Similar to CUTOUT_MODE_DEFAULT / J2K's ignore + enum class CutoutBehaviour(val titleResId: StringResource) { + HIDE(MR.strings.pad_cutout_areas), // Similar to CUTOUT_MODE_NEVER / J2K's pad + SHOW(MR.strings.start_past_cutout), // Similar to CUTOUT_MODE_SHORT_EDGES / J2K's start past + IGNORE(MR.strings.cutout_ignore), // Similar to CUTOUT_MODE_DEFAULT / J2K's ignore } - enum class LandscapeCutoutBehaviour(@StringRes val titleResId: Int) { - HIDE(R.string.pad_cutout_areas), // Similar to CUTOUT_MODE_NEVER / J2K's pad - DEFAULT(R.string.cutout_ignore), // Similar to CUTOUT_MODE_SHORT_EDGES / J2K's ignore + enum class LandscapeCutoutBehaviour(val titleResId: StringResource) { + HIDE(MR.strings.pad_cutout_areas), // Similar to CUTOUT_MODE_NEVER / J2K's pad + DEFAULT(MR.strings.cutout_ignore), // Similar to CUTOUT_MODE_SHORT_EDGES / J2K's ignore } } diff --git a/app/src/main/java/yokai/presentation/Scaffold.kt b/app/src/main/java/yokai/presentation/Scaffold.kt index 29169a7a5f..133cba8e5f 100644 --- a/app/src/main/java/yokai/presentation/Scaffold.kt +++ b/app/src/main/java/yokai/presentation/Scaffold.kt @@ -28,6 +28,9 @@ import androidx.compose.ui.platform.LocalView import androidx.compose.ui.res.stringResource import androidx.core.view.WindowInsetsControllerCompat import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import yokai.presentation.component.ToolTipButton @Composable @@ -38,7 +41,7 @@ fun YokaiScaffold( scrollBehavior: TopAppBarScrollBehavior = TopAppBarDefaults.enterAlwaysScrollBehavior(state = rememberTopAppBarState()), fab: @Composable () -> Unit = {}, navigationIcon: ImageVector = Icons.AutoMirrored.Filled.ArrowBack, - navigationIconLabel: String = stringResource(id = R.string.back), + navigationIconLabel: String = stringResource(MR.strings.back), actions: @Composable RowScope.() -> Unit = {}, appBarType: AppBarType = AppBarType.LARGE, content: @Composable (PaddingValues) -> Unit, diff --git a/app/src/main/java/yokai/presentation/component/ThemeItem.kt b/app/src/main/java/yokai/presentation/component/ThemeItem.kt index c2619f75c6..25b47641c0 100644 --- a/app/src/main/java/yokai/presentation/component/ThemeItem.kt +++ b/app/src/main/java/yokai/presentation/component/ThemeItem.kt @@ -1,5 +1,6 @@ package yokai.presentation.component +import android.R as AR import android.content.Context import android.content.res.Configuration import androidx.compose.foundation.BorderStroke @@ -38,6 +39,9 @@ import androidx.compose.ui.unit.LayoutDirection import androidx.compose.ui.unit.dp import com.google.accompanist.themeadapter.material3.createMdc3Theme import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.util.system.Themes import eu.kanade.tachiyomi.util.system.isInNightMode import yokai.presentation.theme.HalfAlpha @@ -97,7 +101,7 @@ private fun ThemeItemNaive(contextTheme: ContextTheme, selected: Boolean, onClic ) Text( - text = stringResource(id = if (contextTheme.isDarkTheme) contextTheme.theme.darkNameRes else contextTheme.theme.nameRes), + text = stringResource(if (contextTheme.isDarkTheme) contextTheme.theme.darkNameRes else contextTheme.theme.nameRes), textAlign = TextAlign.Center, style = MaterialTheme.typography.bodySmall ) @@ -163,8 +167,8 @@ fun ThemePreviewItem( if (selected) { Icon( imageVector = Icons.Filled.CheckCircle, - contentDescription = stringResource(R.string.selected), - tint = selectedColor, + contentDescription = stringResource(MR.strings.selected), + tint = selectedColor ) } } diff --git a/app/src/main/java/yokai/presentation/component/TrackLogoIcon.kt b/app/src/main/java/yokai/presentation/component/TrackLogoIcon.kt index b08c66a54a..ca75eb8d7b 100644 --- a/app/src/main/java/yokai/presentation/component/TrackLogoIcon.kt +++ b/app/src/main/java/yokai/presentation/component/TrackLogoIcon.kt @@ -15,6 +15,7 @@ import androidx.compose.ui.graphics.Color import androidx.compose.ui.res.painterResource import androidx.compose.ui.res.stringResource import androidx.compose.ui.unit.dp +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.track.TrackService import yokai.presentation.core.util.clickableNoIndication @@ -43,7 +44,7 @@ fun TrackLogoIcon( ) { Image( painter = painterResource(tracker.getLogo()), - contentDescription = stringResource(id = tracker.nameRes()), + contentDescription = stringResource(tracker.nameRes()), ) } } diff --git a/app/src/main/java/yokai/presentation/component/preference/Preference.kt b/app/src/main/java/yokai/presentation/component/preference/Preference.kt index f0b09b06fd..5868d0e053 100644 --- a/app/src/main/java/yokai/presentation/component/preference/Preference.kt +++ b/app/src/main/java/yokai/presentation/component/preference/Preference.kt @@ -5,6 +5,9 @@ import androidx.compose.runtime.remember import androidx.compose.ui.graphics.vector.ImageVector import androidx.compose.ui.res.stringResource import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.track.TrackService import kotlinx.collections.immutable.ImmutableList import kotlinx.collections.immutable.ImmutableMap @@ -114,7 +117,7 @@ sealed class Preference { v.map { e[it] } .takeIf { it.isNotEmpty() } ?.joinToString() - } ?: stringResource(R.string.none) + } ?: stringResource(MR.strings.none) subtitle?.format(combined) }, override val icon: ImageVector? = null, diff --git a/app/src/main/java/yokai/presentation/component/preference/PreferenceCommon.kt b/app/src/main/java/yokai/presentation/component/preference/PreferenceCommon.kt index 5eb2c83b80..de75aff14b 100644 --- a/app/src/main/java/yokai/presentation/component/preference/PreferenceCommon.kt +++ b/app/src/main/java/yokai/presentation/component/preference/PreferenceCommon.kt @@ -8,6 +8,9 @@ import androidx.compose.ui.res.stringResource import androidx.core.net.toUri import com.hippo.unifile.UniFile import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.core.storage.preference.collectAsState @Composable @@ -18,11 +21,11 @@ fun storageLocationText( val storageDir by storageDirPref.collectAsState() if (storageDir == storageDirPref.defaultValue()) { - return stringResource(R.string.no_location_set) + return stringResource(MR.strings.no_location_set) } return remember(storageDir) { val file = UniFile.fromUri(context, storageDir.toUri()) file?.filePath - } ?: stringResource(R.string.invalid_location, storageDir) + } ?: stringResource(MR.strings.invalid_location, storageDir) } diff --git a/app/src/main/java/yokai/presentation/component/preference/widget/TrackingPreferenceWidget.kt b/app/src/main/java/yokai/presentation/component/preference/widget/TrackingPreferenceWidget.kt index a902ee89df..5111d1dbf9 100644 --- a/app/src/main/java/yokai/presentation/component/preference/widget/TrackingPreferenceWidget.kt +++ b/app/src/main/java/yokai/presentation/component/preference/widget/TrackingPreferenceWidget.kt @@ -17,7 +17,9 @@ import androidx.compose.ui.Modifier import androidx.compose.ui.graphics.Color import androidx.compose.ui.unit.dp import eu.kanade.tachiyomi.R -import eu.kanade.tachiyomi.appwidget.util.stringResource +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.track.TrackService import yokai.presentation.component.TrackLogoIcon import yokai.presentation.component.preference.LocalPreferenceHighlighted @@ -40,7 +42,7 @@ fun TrackingPreferenceWidget( ) { TrackLogoIcon(tracker) Text( - text = stringResource(id = tracker.nameRes()), + text = stringResource(tracker.nameRes()), modifier = Modifier .weight(1f) .padding(horizontal = 16.dp), @@ -55,7 +57,7 @@ fun TrackingPreferenceWidget( .padding(4.dp) .size(32.dp), tint = Color(0xFF4CAF50), - contentDescription = stringResource(R.string.successfully_logged_in), + contentDescription = stringResource(MR.strings.successfully_logged_in), ) } } diff --git a/app/src/main/java/yokai/presentation/component/preference/widget/TriStateListDialog.kt b/app/src/main/java/yokai/presentation/component/preference/widget/TriStateListDialog.kt index 2feefbb53b..86302741a5 100644 --- a/app/src/main/java/yokai/presentation/component/preference/widget/TriStateListDialog.kt +++ b/app/src/main/java/yokai/presentation/component/preference/widget/TriStateListDialog.kt @@ -30,6 +30,9 @@ import androidx.compose.ui.draw.clip import androidx.compose.ui.res.stringResource import androidx.compose.ui.unit.dp import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import android.R as AR private enum class State { @@ -103,9 +106,9 @@ fun TriStateListDialog( }, contentDescription = stringResource( when (state) { - State.UNCHECKED -> R.string.not_selected - State.CHECKED -> R.string.selected - State.INVERSED -> R.string.disabled + State.UNCHECKED -> MR.strings.not_selected + State.CHECKED -> MR.strings.selected + State.INVERSED -> MR.strings.disabled }, ), ) diff --git a/app/src/main/java/yokai/presentation/extension/repo/ExtensionRepoScreen.kt b/app/src/main/java/yokai/presentation/extension/repo/ExtensionRepoScreen.kt index aacbb8cea1..47a756a7bb 100644 --- a/app/src/main/java/yokai/presentation/extension/repo/ExtensionRepoScreen.kt +++ b/app/src/main/java/yokai/presentation/extension/repo/ExtensionRepoScreen.kt @@ -25,7 +25,7 @@ import androidx.compose.ui.platform.LocalContext import androidx.compose.ui.res.stringResource import androidx.compose.ui.unit.sp import androidx.lifecycle.viewmodel.compose.viewModel -import eu.kanade.tachiyomi.R +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.util.compose.LocalAlertDialog import eu.kanade.tachiyomi.util.compose.LocalBackPress import eu.kanade.tachiyomi.util.compose.currentOrThrow @@ -33,6 +33,7 @@ import eu.kanade.tachiyomi.util.system.toast import kotlinx.coroutines.flow.collectLatest import yokai.domain.ComposableAlertDialog import yokai.domain.extension.repo.model.ExtensionRepo +import yokai.i18n.MR import yokai.presentation.AppBarType import yokai.presentation.YokaiScaffold import yokai.presentation.component.EmptyScreen @@ -64,7 +65,7 @@ fun ExtensionRepoScreen( ), actions = { ToolTipButton( - toolTipLabel = stringResource(R.string.refresh), + toolTipLabel = stringResource(MR.strings.refresh), icon = Icons.Outlined.Refresh, buttonClicked = { context.toast("Refreshing...") // TODO: Should be loading animation instead @@ -88,7 +89,7 @@ fun ExtensionRepoScreen( item { ExtensionRepoInput( inputText = inputText, - inputHint = stringResource(R.string.label_add_repo), + inputHint = stringResource(MR.strings.label_add_repo), onInputChange = { inputText = it }, onAddClick = { viewModel.addRepo(it) }, ) @@ -99,7 +100,7 @@ fun ExtensionRepoScreen( EmptyScreen( modifier = Modifier.fillParentMaxSize(), image = Icons.Filled.ExtensionOff, - message = stringResource(R.string.information_empty_repos), + message = stringResource(MR.strings.information_empty_repos), ) } return@LazyColumn @@ -159,7 +160,7 @@ fun ExtensionRepoReplacePrompt( onDismissRequest() }, ) { - Text(text = stringResource(R.string.action_replace_repo)) + Text(text = stringResource(MR.strings.action_replace_repo)) } }, dismissButton = { @@ -168,10 +169,10 @@ fun ExtensionRepoReplacePrompt( } }, title = { - Text(text = stringResource(R.string.action_replace_repo_title)) + Text(text = stringResource(MR.strings.action_replace_repo_title)) }, text = { - Text(text = stringResource(R.string.action_replace_repo_message, newRepo.name, oldRepo.name)) + Text(text = stringResource(MR.strings.action_replace_repo_message, newRepo.name, oldRepo.name)) }, ) } @@ -182,7 +183,7 @@ fun ExtensionRepoDeletePrompt(repoToDelete: String, alertDialog: ComposableAlert containerColor = MaterialTheme.colorScheme.surface, title = { Text( - text = stringResource(R.string.confirm_delete_repo_title), + text = stringResource(MR.strings.confirm_delete_repo_title), fontStyle = MaterialTheme.typography.titleMedium.fontStyle, color = MaterialTheme.colorScheme.onSurface, fontSize = 24.sp, @@ -190,7 +191,7 @@ fun ExtensionRepoDeletePrompt(repoToDelete: String, alertDialog: ComposableAlert }, text = { Text( - text = stringResource(R.string.confirm_delete_repo, repoToDelete), + text = stringResource(MR.strings.confirm_delete_repo, repoToDelete), fontStyle = MaterialTheme.typography.bodyMedium.fontStyle, color = MaterialTheme.colorScheme.onSurfaceVariant, fontSize = 14.sp, @@ -205,7 +206,7 @@ fun ExtensionRepoDeletePrompt(repoToDelete: String, alertDialog: ComposableAlert } ) { Text( - text = stringResource(R.string.delete), + text = stringResource(MR.strings.delete), color = MaterialTheme.colorScheme.primary, fontSize = 14.sp, ) @@ -214,7 +215,7 @@ fun ExtensionRepoDeletePrompt(repoToDelete: String, alertDialog: ComposableAlert dismissButton = { TextButton(onClick = { alertDialog.content = null }) { Text( - text = stringResource(R.string.cancel), + text = stringResource(MR.strings.cancel), color = MaterialTheme.colorScheme.primary, fontSize = 14.sp, ) diff --git a/app/src/main/java/yokai/presentation/extension/repo/ExtensionRepoViewModel.kt b/app/src/main/java/yokai/presentation/extension/repo/ExtensionRepoViewModel.kt index dad43d22f9..58f3a6518a 100644 --- a/app/src/main/java/yokai/presentation/extension/repo/ExtensionRepoViewModel.kt +++ b/app/src/main/java/yokai/presentation/extension/repo/ExtensionRepoViewModel.kt @@ -1,10 +1,9 @@ package yokai.presentation.extension.repo -import androidx.annotation.StringRes import androidx.compose.runtime.Immutable import androidx.lifecycle.ViewModel import androidx.lifecycle.viewModelScope -import eu.kanade.tachiyomi.R +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.extension.ExtensionManager import eu.kanade.tachiyomi.util.system.launchIO import kotlinx.collections.immutable.ImmutableList @@ -21,6 +20,7 @@ import yokai.domain.extension.repo.interactor.GetExtensionRepo import yokai.domain.extension.repo.interactor.ReplaceExtensionRepo import yokai.domain.extension.repo.interactor.UpdateExtensionRepo import yokai.domain.extension.repo.model.ExtensionRepo +import yokai.i18n.MR class ExtensionRepoViewModel : ViewModel() { @@ -90,9 +90,9 @@ sealed class RepoDialog { } sealed class ExtensionRepoEvent { - sealed class LocalizedMessage(@StringRes val stringRes: Int) : ExtensionRepoEvent() - data object InvalidUrl : LocalizedMessage(R.string.invalid_repo_url) - data object RepoAlreadyExists : LocalizedMessage(R.string.repo_already_exists) + sealed class LocalizedMessage(val stringRes: StringResource) : ExtensionRepoEvent() + data object InvalidUrl : LocalizedMessage(MR.strings.invalid_repo_url) + data object RepoAlreadyExists : LocalizedMessage(MR.strings.repo_already_exists) data class ShowDialog(val dialog: RepoDialog) : ExtensionRepoEvent() data object NoOp : ExtensionRepoEvent() data object Success : ExtensionRepoEvent() diff --git a/app/src/main/java/yokai/presentation/onboarding/OnboardingScreen.kt b/app/src/main/java/yokai/presentation/onboarding/OnboardingScreen.kt index 8c1ccd7353..28885cf41d 100644 --- a/app/src/main/java/yokai/presentation/onboarding/OnboardingScreen.kt +++ b/app/src/main/java/yokai/presentation/onboarding/OnboardingScreen.kt @@ -19,6 +19,9 @@ import androidx.compose.ui.Modifier import androidx.compose.ui.draw.clip import androidx.compose.ui.res.stringResource import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import soup.compose.material.motion.animation.materialSharedAxisX import soup.compose.material.motion.animation.rememberSlideDistance import yokai.presentation.onboarding.steps.PermissionStep @@ -46,14 +49,14 @@ fun OnboardingScreen( InfoScreen( icon = Icons.Outlined.RocketLaunch, - headingText = stringResource(R.string.onboarding_heading), - subtitleText = stringResource(R.string.onboarding_description), + headingText = stringResource(MR.strings.onboarding_heading), + subtitleText = stringResource(MR.strings.onboarding_description), tint = MaterialTheme.colorScheme.primary, acceptText = stringResource( if (isLastStep) - R.string.onboarding_finish + MR.strings.onboarding_finish else { - R.string.next + MR.strings.next } ), canAccept = steps[currentStep].isComplete, diff --git a/app/src/main/java/yokai/presentation/onboarding/steps/PermissionStep.kt b/app/src/main/java/yokai/presentation/onboarding/steps/PermissionStep.kt index 78d76190d7..056660af2e 100644 --- a/app/src/main/java/yokai/presentation/onboarding/steps/PermissionStep.kt +++ b/app/src/main/java/yokai/presentation/onboarding/steps/PermissionStep.kt @@ -34,6 +34,9 @@ import androidx.lifecycle.DefaultLifecycleObserver import androidx.lifecycle.LifecycleOwner import androidx.lifecycle.compose.LocalLifecycleOwner import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import yokai.presentation.component.Gap import yokai.presentation.theme.Size @@ -83,11 +86,11 @@ internal class PermissionStep : OnboardingStep { Column( modifier = Modifier.padding(vertical = Size.medium), ) { - SectionHeader(stringResource(R.string.onboarding_permission_type_required)) + SectionHeader(stringResource(MR.strings.onboarding_permission_type_required)) PermissionItem( - title = stringResource(R.string.onboarding_permission_install_apps), - subtitle = stringResource(R.string.onboarding_permission_install_apps_description), + title = stringResource(MR.strings.onboarding_permission_install_apps), + subtitle = stringResource(MR.strings.onboarding_permission_install_apps_description), granted = installGranted, onButtonClick = { val intent = @@ -104,7 +107,7 @@ internal class PermissionStep : OnboardingStep { Gap(Size.medium) - SectionHeader(stringResource(R.string.onboarding_permission_type_optional)) + SectionHeader(stringResource(MR.strings.onboarding_permission_type_optional)) if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.TIRAMISU) { val permissionRequester = @@ -113,9 +116,9 @@ internal class PermissionStep : OnboardingStep { onResult = { /* No-op, handled on resume */ }, ) PermissionItem( - title = stringResource(R.string.onboarding_permission_notifications), + title = stringResource(MR.strings.onboarding_permission_notifications), subtitle = - stringResource(R.string.onboarding_permission_notifications_description), + stringResource(MR.strings.onboarding_permission_notifications_description), granted = notificationGranted, onButtonClick = { permissionRequester.launch(Manifest.permission.POST_NOTIFICATIONS) @@ -124,9 +127,9 @@ internal class PermissionStep : OnboardingStep { } PermissionItem( - title = stringResource(R.string.onboarding_permission_ignore_battery_opts), + title = stringResource(MR.strings.onboarding_permission_ignore_battery_opts), subtitle = - stringResource(R.string.onboarding_permission_ignore_battery_opts_description), + stringResource(MR.strings.onboarding_permission_ignore_battery_opts_description), granted = batteryGranted, onButtonClick = { @SuppressLint("BatteryLife") @@ -176,7 +179,7 @@ internal class PermissionStep : OnboardingStep { tint = MaterialTheme.colorScheme.primary, ) } else { - Text(stringResource(R.string.onboarding_permission_action_grant)) + Text(stringResource(MR.strings.onboarding_permission_action_grant)) } } }, diff --git a/app/src/main/java/yokai/presentation/onboarding/steps/StorageStep.kt b/app/src/main/java/yokai/presentation/onboarding/steps/StorageStep.kt index 70e27d8933..1b840b24fc 100644 --- a/app/src/main/java/yokai/presentation/onboarding/steps/StorageStep.kt +++ b/app/src/main/java/yokai/presentation/onboarding/steps/StorageStep.kt @@ -19,6 +19,9 @@ import androidx.compose.ui.platform.LocalContext import androidx.compose.ui.platform.LocalUriHandler import androidx.compose.ui.res.stringResource import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.util.system.toast import kotlinx.coroutines.flow.collectLatest import uy.kohesive.injekt.injectLazy @@ -49,8 +52,8 @@ internal class StorageStep : OnboardingStep { ) { Text( stringResource( - R.string.onboarding_storage_info, - stringResource(R.string.app_name), + MR.strings.onboarding_storage_info, + stringResource(MR.strings.app_name), storageLocationText(storagePref.baseStorageDirectory()), ), ) @@ -61,11 +64,11 @@ internal class StorageStep : OnboardingStep { try { pickStorageLocation.launch(null) } catch (e: ActivityNotFoundException) { - context.toast(R.string.file_picker_error) + context.toast(MR.strings.file_picker_error) } }, ) { - Text(stringResource(R.string.onboarding_storage_action_select)) + Text(stringResource(MR.strings.onboarding_storage_action_select)) } HorizontalDivider( @@ -73,7 +76,7 @@ internal class StorageStep : OnboardingStep { color = MaterialTheme.colorScheme.onPrimaryContainer ) - Text(stringResource(R.string.onboarding_storage_help_info)) + Text(stringResource(MR.strings.onboarding_storage_help_info)) Button( modifier = Modifier.fillMaxWidth(), onClick = { @@ -82,7 +85,7 @@ internal class StorageStep : OnboardingStep { ) }, ) { - Text(stringResource(R.string.onboarding_storage_help_action)) + Text(stringResource(MR.strings.onboarding_storage_help_action)) } } diff --git a/app/src/main/java/yokai/presentation/onboarding/steps/ThemeStep.kt b/app/src/main/java/yokai/presentation/onboarding/steps/ThemeStep.kt index 08377ee5d1..e0c1698848 100644 --- a/app/src/main/java/yokai/presentation/onboarding/steps/ThemeStep.kt +++ b/app/src/main/java/yokai/presentation/onboarding/steps/ThemeStep.kt @@ -25,6 +25,9 @@ import androidx.compose.ui.res.stringResource import androidx.core.app.ActivityCompat import com.google.android.material.color.DynamicColors import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.core.storage.preference.collectAsState import eu.kanade.tachiyomi.data.preference.PreferencesHelper import eu.kanade.tachiyomi.util.system.Themes @@ -92,7 +95,7 @@ internal class ThemeStep : OnboardingStep { horizontalArrangement = Arrangement.SpaceBetween, verticalAlignment = Alignment.CenterVertically ) { - Text(text = stringResource(id = R.string.follow_system_theme)) + Text(text = stringResource(MR.strings.follow_system_theme)) Switch( checked = nightMode == AppCompatDelegate.MODE_NIGHT_FOLLOW_SYSTEM, colors = SwitchDefaults.colors( diff --git a/app/src/main/java/yokai/presentation/settings/ComposableSettings.kt b/app/src/main/java/yokai/presentation/settings/ComposableSettings.kt index 74e96a7337..3a52f75692 100644 --- a/app/src/main/java/yokai/presentation/settings/ComposableSettings.kt +++ b/app/src/main/java/yokai/presentation/settings/ComposableSettings.kt @@ -1,17 +1,16 @@ package yokai.presentation.settings -import androidx.annotation.StringRes import androidx.compose.foundation.layout.RowScope import androidx.compose.runtime.Composable import androidx.compose.runtime.ReadOnlyComposable -import androidx.compose.ui.res.stringResource +import dev.icerock.moko.resources.StringResource +import dev.icerock.moko.resources.compose.stringResource import yokai.presentation.component.preference.Preference interface ComposableSettings { @Composable @ReadOnlyComposable - @StringRes - fun getTitleRes(): Int + fun getTitleRes(): StringResource @Composable fun getPreferences(): List diff --git a/app/src/main/java/yokai/presentation/settings/screen/SettingsDataScreen.kt b/app/src/main/java/yokai/presentation/settings/screen/SettingsDataScreen.kt index f03993fab0..2c950685fa 100644 --- a/app/src/main/java/yokai/presentation/settings/screen/SettingsDataScreen.kt +++ b/app/src/main/java/yokai/presentation/settings/screen/SettingsDataScreen.kt @@ -25,7 +25,11 @@ import androidx.compose.ui.Modifier import androidx.compose.ui.platform.LocalContext import androidx.compose.ui.res.stringResource import co.touchlab.kermit.Logger +import dev.icerock.moko.resources.StringResource import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.backup.BackupFileValidator import eu.kanade.tachiyomi.data.backup.create.BackupCreatorJob import eu.kanade.tachiyomi.data.backup.restore.BackupRestoreJob @@ -60,7 +64,7 @@ import yokai.presentation.settings.screen.data.storageLocationPicker object SettingsDataScreen : ComposableSettings { @Composable - override fun getTitleRes(): Int = R.string.data_and_storage + override fun getTitleRes(): StringResource = MR.strings.data_and_storage @Composable override fun getPreferences(): List { @@ -80,13 +84,13 @@ object SettingsDataScreen : ComposableSettings { val pickStoragePicker = storageLocationPicker(storagePreferences.baseStorageDirectory()) return Preference.PreferenceItem.TextPreference( - title = stringResource(R.string.storage_location), + title = stringResource(MR.strings.storage_location), subtitle = storageLocationText(storagePreferences.baseStorageDirectory()), onClick = { try { pickStoragePicker.launch(null) } catch (e: ActivityNotFoundException) { - context.toast(R.string.file_picker_error) + context.toast(MR.strings.file_picker_error) } } ) @@ -105,7 +109,7 @@ object SettingsDataScreen : ComposableSettings { override fun createIntent(context: Context, input: String): Intent { val intent = super.createIntent(context, input) intent.addCategory(Intent.CATEGORY_OPENABLE) - return Intent.createChooser(intent, context.getString(R.string.select_backup_file)) + return Intent.createChooser(intent, context.getString(MR.strings.select_backup_file)) } }, ) { @@ -130,10 +134,10 @@ object SettingsDataScreen : ComposableSettings { } return Preference.PreferenceGroup( - title = stringResource(R.string.backup_and_restore), + title = stringResource(MR.strings.backup_and_restore), preferenceItems = persistentListOf( Preference.PreferenceItem.CustomPreference( - title = stringResource(R.string.backup_and_restore), + title = stringResource(MR.strings.backup_and_restore), ) { BasePreferenceWidget( subcomponent = { @@ -149,12 +153,12 @@ object SettingsDataScreen : ComposableSettings { onCheckedChange = { if (!BackupRestoreJob.isRunning(context)) { if (DeviceUtil.isMiui && DeviceUtil.isMiuiOptimizationDisabled()) { - context.toast(R.string.restore_miui_warning, Toast.LENGTH_LONG) + context.toast(MR.strings.restore_miui_warning, Toast.LENGTH_LONG) } val dir = storageManager.getBackupsDirectory() if (dir == null) { - context.toast(R.string.invalid_location_generic) + context.toast(MR.strings.invalid_location_generic) return@SegmentedButton } @@ -166,12 +170,12 @@ object SettingsDataScreen : ComposableSettings { ) } } else { - context.toast(R.string.backup_in_progress) + context.toast(MR.strings.backup_in_progress) } }, shape = SegmentedButtonDefaults.itemShape(0, 2), ) { - Text(stringResource(R.string.create_backup)) + Text(stringResource(MR.strings.create_backup)) } SegmentedButton( modifier = Modifier.fillMaxHeight(), @@ -179,18 +183,18 @@ object SettingsDataScreen : ComposableSettings { onCheckedChange = { if (!BackupRestoreJob.isRunning(context)) { if (DeviceUtil.isMiui && DeviceUtil.isMiuiOptimizationDisabled()) { - context.toast(R.string.restore_miui_warning, Toast.LENGTH_LONG) + context.toast(MR.strings.restore_miui_warning, Toast.LENGTH_LONG) } scope.launch { extensionManager.getExtensionUpdates(true) } chooseBackup.launch("*/*") } else { - context.toast(R.string.restore_in_progress) + context.toast(MR.strings.restore_in_progress) } }, shape = SegmentedButtonDefaults.itemShape(1, 2), ) { - Text(stringResource(R.string.restore_backup)) + Text(stringResource(MR.strings.restore_backup)) } } }, @@ -200,14 +204,14 @@ object SettingsDataScreen : ComposableSettings { // Automatic backups Preference.PreferenceItem.ListPreference( pref = preferences.backupInterval(), - title = stringResource(R.string.backup_frequency), + title = stringResource(MR.strings.backup_frequency), entries = persistentMapOf( - 0 to stringResource(R.string.manual), - 6 to stringResource(R.string.every_6_hours), - 12 to stringResource(R.string.every_12_hours), - 24 to stringResource(R.string.daily), - 48 to stringResource(R.string.every_2_days), - 168 to stringResource(R.string.weekly), + 0 to stringResource(MR.strings.manual), + 6 to stringResource(MR.strings.every_6_hours), + 12 to stringResource(MR.strings.every_12_hours), + 24 to stringResource(MR.strings.daily), + 48 to stringResource(MR.strings.every_2_days), + 168 to stringResource(MR.strings.weekly), ), onValueChanged = { BackupCreatorJob.setupTask(context, it) @@ -215,8 +219,8 @@ object SettingsDataScreen : ComposableSettings { }, ), Preference.PreferenceItem.InfoPreference( - stringResource(R.string.backup_info) - /*+ "\n\n" + stringResource(R.string.last_auto_backup_info, relativeTimeSpanString(lastAutoBackup))*/, + stringResource(MR.strings.backup_info) + /*+ "\n\n" + stringResource(MR.strings.last_auto_backup_info, relativeTimeSpanString(lastAutoBackup))*/, ), ), ) @@ -235,10 +239,10 @@ object SettingsDataScreen : ComposableSettings { val cacheReadableSize = remember(cacheReadableSizeSema) { chapterCache.readableSize } return Preference.PreferenceGroup( - title = stringResource(R.string.storage_usage), + title = stringResource(MR.strings.storage_usage), preferenceItems = persistentListOf( Preference.PreferenceItem.CustomPreference( - title = stringResource(R.string.storage_usage), + title = stringResource(MR.strings.storage_usage), ) { BasePreferenceWidget( subcomponent = { @@ -250,15 +254,15 @@ object SettingsDataScreen : ComposableSettings { }, Preference.PreferenceItem.TextPreference( - title = stringResource(R.string.clear_chapter_cache), - subtitle = stringResource(R.string.used_, cacheReadableSize), + title = stringResource(MR.strings.clear_chapter_cache), + subtitle = stringResource(MR.strings.used_, cacheReadableSize), onClick = { scope.launchNonCancellableIO { try { val deletedFiles = chapterCache.clear() withUIContext { - context.toast(context.resources?.getQuantityString( - R.plurals.cache_cleared, + context.toast(context.getString( + MR.plurals.cache_cleared, deletedFiles, deletedFiles, )) @@ -266,32 +270,32 @@ object SettingsDataScreen : ComposableSettings { } } catch (e: Throwable) { Logger.e(e) - withUIContext { context.toast(R.string.cache_delete_error) } + withUIContext { context.toast(MR.strings.cache_delete_error) } } } }, ), Preference.PreferenceItem.TextPreference( - title = stringResource(R.string.clear_cached_covers_non_library), + title = stringResource(MR.strings.clear_cached_covers_non_library), subtitle = stringResource( - R.string.delete_all_covers__not_in_library_used_, + MR.strings.delete_all_covers__not_in_library_used_, coverCache.getOnlineCoverCacheSize(), ), onClick = { - context.toast(R.string.starting_cleanup) + context.toast(MR.strings.starting_cleanup) scope.launchNonCancellableIO { coverCache.deleteAllCachedCovers() } } ), Preference.PreferenceItem.TextPreference( - title = stringResource(R.string.clean_up_cached_covers), + title = stringResource(MR.strings.clean_up_cached_covers), subtitle = stringResource( - R.string.delete_old_covers_in_library_used_, + MR.strings.delete_old_covers_in_library_used_, coverCache.getChapterCacheSize(), ), onClick = { - context.toast(R.string.starting_cleanup) + context.toast(MR.strings.starting_cleanup) scope.launchNonCancellableIO { coverCache.deleteOldCovers() } diff --git a/app/src/main/java/yokai/presentation/settings/screen/data/AlertDialogs.kt b/app/src/main/java/yokai/presentation/settings/screen/data/AlertDialogs.kt index bf13ca8127..29b62334a6 100644 --- a/app/src/main/java/yokai/presentation/settings/screen/data/AlertDialogs.kt +++ b/app/src/main/java/yokai/presentation/settings/screen/data/AlertDialogs.kt @@ -15,13 +15,14 @@ import androidx.compose.runtime.remember import androidx.compose.runtime.setValue import androidx.compose.ui.res.stringResource import com.hippo.unifile.UniFile -import eu.kanade.tachiyomi.R +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.data.backup.BackupFileValidator.Results import eu.kanade.tachiyomi.data.backup.create.BackupCreatorJob import eu.kanade.tachiyomi.data.backup.create.BackupOptions import eu.kanade.tachiyomi.data.backup.models.Backup import eu.kanade.tachiyomi.data.backup.restore.BackupRestoreJob import eu.kanade.tachiyomi.util.system.toast +import yokai.i18n.MR import yokai.presentation.component.LabeledCheckbox import android.R as AR @@ -34,16 +35,16 @@ fun RestoreBackup( ) { val (results, e) = pair if (results != null) { - var message = stringResource(R.string.restore_content_full) + var message = stringResource(MR.strings.restore_content_full) if (results.missingSources.isNotEmpty()) { - message += "\n\n${stringResource(R.string.restore_missing_sources)}\n${ + message += "\n\n${stringResource(MR.strings.restore_missing_sources)}\n${ results.missingSources.joinToString( "\n", ) { "- $it" } }" } if (results.missingTrackers.isNotEmpty()) { - message += "\n\n${stringResource(R.string.restore_missing_trackers)}\n${ + message += "\n\n${stringResource(MR.strings.restore_missing_trackers)}\n${ results.missingTrackers.joinToString( "\n", ) { "- $it" } @@ -55,12 +56,12 @@ fun RestoreBackup( confirmButton = { TextButton( onClick = { - context.toast(R.string.restoring_backup) + context.toast(MR.strings.restoring_backup) BackupRestoreJob.start(context, uri) onDismissRequest() }, ) { - Text(text = stringResource(R.string.restore)) + Text(text = stringResource(MR.strings.restore)) } }, dismissButton = { @@ -68,7 +69,7 @@ fun RestoreBackup( Text(text = stringResource(AR.string.cancel)) } }, - title = { Text(text = stringResource(R.string.restore_backup)) }, + title = { Text(text = stringResource(MR.strings.restore_backup)) }, text = { Text(text = message) }, ) } else { @@ -79,7 +80,7 @@ fun RestoreBackup( Text(text = stringResource(AR.string.cancel)) } }, - title = { Text(text = stringResource(R.string.invalid_backup_file)) }, + title = { Text(text = stringResource(MR.strings.invalid_backup_file)) }, text = { e?.message?.let { Text(text = it) } } ) } @@ -99,19 +100,19 @@ fun CreateBackup( TextButton(onClick = { val actualUri = UniFile.fromUri(context, uri)?.createFile(Backup.getBackupFilename())?.uri ?: return@TextButton - context.toast(R.string.creating_backup) + context.toast(MR.strings.creating_backup) BackupCreatorJob.startNow(context, actualUri, options) onDismissRequest() }) { - Text(stringResource(R.string.create)) + Text(stringResource(MR.strings.create)) } }, dismissButton = { TextButton(onClick = { onDismissRequest() }) { - Text(stringResource(R.string.cancel)) + Text(stringResource(MR.strings.cancel)) } }, - title = { Text(text = stringResource(R.string.create_backup)) }, + title = { Text(text = stringResource(MR.strings.create_backup)) }, text = { Box { val state = rememberLazyListState() diff --git a/app/src/main/java/yokai/presentation/settings/screen/data/StorageInfo.kt b/app/src/main/java/yokai/presentation/settings/screen/data/StorageInfo.kt index 2eaad2078d..827764ee5f 100644 --- a/app/src/main/java/yokai/presentation/settings/screen/data/StorageInfo.kt +++ b/app/src/main/java/yokai/presentation/settings/screen/data/StorageInfo.kt @@ -14,6 +14,9 @@ import androidx.compose.ui.draw.clip import androidx.compose.ui.platform.LocalContext import androidx.compose.ui.res.stringResource import eu.kanade.tachiyomi.R +import yokai.i18n.MR +import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource import eu.kanade.tachiyomi.util.storage.DiskUtil import yokai.presentation.core.util.secondaryItemAlpha import yokai.presentation.theme.Size @@ -57,7 +60,7 @@ private fun StorageInfo( ) Text( - text = stringResource(R.string.available_disk_space_info, availableText, totalText), + text = stringResource(MR.strings.available_disk_space_info, availableText, totalText), modifier = Modifier.secondaryItemAlpha(), style = MaterialTheme.typography.bodySmall, ) diff --git a/app/src/main/res/values-ml/strings.xml b/app/src/main/res/values-ml/strings.xml deleted file mode 100644 index 2d9c148302..0000000000 --- a/app/src/main/res/values-ml/strings.xml +++ /dev/null @@ -1,8 +0,0 @@ - - - ചാപ്റ്ററുകൾ ഡൗൺലോഡ് ചെയ്യാനും സ്വയമേവയുള്ള ബാക്കപ്പുകൾ സൃഷ്‌ടിക്കാനും പ്രാദേശിക മാംഗ വായിക്കാനും TachiyomiJ2K-ന് Android 11-ലെ എല്ലാ ഫയലുകളിലേക്കും ആക്‌സസ് ആവശ്യമാണ്. -\n -\nഅടുത്ത സ്ക്രീനിൽ, \"എല്ലാ ഫയലുകളും നിയന്ത്രിക്കാൻ ആക്സസ് അനുവദിക്കുക\" പ്രവർത്തനക്ഷമമാക്കുക. - ചാപ്റ്ററുകൾ ഡൗൺലോഡ് ചെയ്യുന്നതിന് TachiyomiJ2K-ന് എല്ലാ ഫയലുകളിലേക്കും ആക്‌സസ് ആവശ്യമാണ്. ഇവിടെ ടാപ്പ് ചെയ്യുക, തുടർന്ന് \"എല്ലാ ഫയലുകളും മാനേജ് ചെയ്യാൻ ആക്സസ് അനുവദിക്കുക\" പ്രവർത്തനക്ഷമമാക്കുക. - ഫയൽ അനുമതികൾ ആവശ്യമാണ് - \ No newline at end of file diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml deleted file mode 100644 index c05e49c91b..0000000000 --- a/app/src/main/res/values/strings.xml +++ /dev/null @@ -1,1259 +0,0 @@ - - - Yōkai - Yōkai - Yokai - - File permissions required - TachiyomiJ2K requires access to all files in Android 11 to download chapters, create automatic backups, and read local series. \n\nOn the next screen, enable \"Allow access to manage all files.\" - TachiyomiJ2K requires access to all files to download chapters. Tap here, then enable \"Allow access to manage all files.\" - - Welcome! - Let\'s pick some defaults. You can always change these things later in the settings. - Get started - Select a folder where %1$s will store chapter downloads, backups, and more.\n\nA dedicated folder is recommended.\n\nSelected folder: %2$s - Select a folder - Updating from an older version and not sure what to select? Refer to the Tachiyomi upgrade section on the Mihon storage guide for more information. - Storage guide - Required - Optional but recommended - Install apps permission - To install the app on updates. - Notification permission - Get notified for library updates and more. - Background battery usage - Avoid interruptions to long-running library updates, downloads, and backup restores. - Grant - - No storage location set - Invalid location: %s - Invalid location - - - - - Manga - Manhwa - Manhua - Comic - - - Library entries - Not started - In progress - Read - Title - Author - Artist - Description - Move %1$s to… - Add %1$s to… - - - Ongoing - Unknown - Unknown Status - Licensed - Completed - Publishing finished - Cancelled - On hiatus - - - Unlock to access Library - Unlock - Require unlock - Lock when idle - - - Chapters - New chapters - Unread - Last read Chapter %1$s - Chapter %1$s - Chapter %1$d of %2$d - All chapters read - Bookmarked - Not bookmarked - Marked as read - Marked as unread - Removed bookmark - Chapters removed. - Chapter not found - Invalid chapter format - Order by - No chapters found - No pages found - RARv5 format is not supported - Remove all downloads? - No chapters to delete - By source\'s order - By chapter number - By upload date - Scanlators - - - Remove %1$d downloaded chapter? - Remove %1$d downloaded chapters? - - - %1$s chapter - %1$s chapters - - - %1$d page left - %1$d pages left - - - - Category - Categories - Adding %1$s to update queue - %1$s is already in queue - Create new category - New category - Category is empty - Show empty categories while filtering - No matches for your filters - Default category - Delete category? - Entries in this category will moved into the - default category. - Entry already in category - Add categories - Add/Edit categories - Edit categories - Manage category - Move to categories - - %d category - %d categories - - A category with that name already exists! - Category name cannot be blank - Category deleted - Press and hold to edit a category - Jump to category - - - Update - Updating %1$s - Update available - New version available! - New beta version available! - No new updates available - Searching for updates… - Release page - Could not install update - Update completed - - - - - Library - Your library - Updating library - Selected: %1$d - Local - Search title, tags, source - Your library is empty, add series to your - library from the browse tab. - No matches found for your current filters - Getting started guide - Show all categories - Move collapsed dynamic categories to bottom - Show number of items - When grouping library by sources, status, etc. - Always show current category - Category hopper long-press action - Expand/collapse all categories - Open a random series - Expand all categories - Collapse all categories - Reorder filters - %d unread - Search \"%1$s\" globally - - Read progress - Series type - Series - Group library by… - Tracking status - Ungrouped - - - Sort by - Total chapters - Date added - Last read - Date fetched - Latest chapter - Drag & Drop - - - Display options - Can also be found by expanding library filters - List - Comfortable Grid - Cover-only grid - Compact Grid - Download badges - Language badges - Hide start reading button - Badges - Uniform grid covers - Use staggered grid - Show outline around covers - Grid size - %d per row - Hide unread badges - Show unread badges - Show unread count - Tap the Library icon to show filters - Display as - Hide category hopper - More library settings - Shift one page over - Shift double pages - - - Allowing notifications is recommended to keep your library and app up to date. - New chapters found - Large updates may lead to increased battery usage and sources becoming slower. Tap to learn more. - Warning: large bulk downloads may lead to sources becoming slower and/or blocking Tachiyomi. Tap to learn more. - - For %d title - For %d titles - - - and %1$d more chapter - and %1$d more chapters - - %1$d update(s) failed - %1$d update(s) skipped - Skipped because series is complete - Skipped because there are unread chapters - Skipped because no chapters are read - Skipped because series does not require updates - Errors - Skipped - - - Library update frequency - Skip updating titles - With unread chapter(s) - With \"Completed\" status - That haven\'t been started - Only update series if there is no unread chapter (completely read) - Device restrictions - Update only when the conditions are met - Restrictions: %1$s - Sort by ignoring articles - When sorting alphabetically, sort ignoring - articles (a, an, the) at the start of a series\' title - Categories to include in global update - Include in global update - Automatically refresh covers - Refresh covers in library as well - when updating library - Global updates - Buttons at bottom of reader - Certain buttons can be found in other places if disabled here - Search suggestions - Search tips will show up periodically. Long press the suggestion to search it. - - - Recents - Updates & history - Updates - Newly added - History - Reset chapter history - Recent updates - This will remove the read date of - \"%1$s\". Are you sure? - Reset all chapters for this %1$s - Last read %1$s - Read %1$s - Updated %1$s - Added %1$s - Fetched %1$s - Library last updated: %s - View history - View all updates - Show more chapters - Collapse grouped chapters - Search recents… - No recently read or updated series - No recent chapters - No recently read series - Grouped - Reset chapter? - Press and hold can also reset chapter history - Show download button - History deleted - Are you sure? All history will be lost. - - - Show reset history button - Show read chapters in Grouped and All - Show title first - A while ago - Show updated time - Sort by fetched time - Group chapters together - By series - By week - By day - Uniform covers - Affects library grid covers - Only unread - Only downloaded - Unread or downloaded - Clear history - Show download queue - Open last read chapter - Long tap Recents behaviour - - - Search filters - No more results - No results found - Local source - Other - Global search… - Global search - Latest - Popular - Browse - In Library - Search extensions… - All sources - Sources - Source hidden - Last used - Local source guide - Check website in WebView - Open extensions / migration menu - Open global search - Long tap Browse behaviour - - - - - Extensions - Extension updates - Extension updates pending - Extension info - Filter Languages - Obsolete - Pending - Installing - Installed - Trust - Untrusted - Uninstall - Shizuku is not running - Install and start Shizuku to use Shizuku as extension installer. - Installer - Shizuku - Private - Default - Legacy - Allows extensions to be installed without user prompts and enables automatic updates for devices under Android 12 - Untrusted extension - Malicious extensions can read any stored login credentials or execute arbitrary code.\n\nBy trusting this extension you accept these risks. - This extension is no longer available. - This extension is not from the official Tachiyomi extensions list. - Version: %1$s - Language: %1$s - 18+ - Installed %1$s - Unofficial - MIUI Optimization must be disabled to install extensions. - May contain NSFW (18+) content - App info - %1$s must be enabled first - Could not install extension - Update all - Some extensions may still prompt to be installed first. - Updating extensions - - %d update pending - %d updates pending - - Extensions updated - - Extension updated - %d extensions updated - - - Extension update available - %d extension updates available - - Revoke all trusted extensions - Revoke all trusted extensions? - - - Set as cover - Reader settings - Set as default for all - Cover updated - Page %1$d - Pages %1$s - Next chapter not found - The image couldn\'t be loaded - Use this image as cover art? - Reading mode - Changing this will reset the reading mode for this series - Finished: - Current: - Next: - Previous: - There\'s no next chapter - There\'s no previous chapter - Loading pages… - Failed to load pages: %1$s - Reading %1$s - Long strip - Next page - Previous page - Next chapter - Previous chapter - - Set first page as cover - Share first page - Save first page - - Set second page as cover - Share second page - Save second page - - Share combined pages - Save combined pages - - - Fullscreen - Animate page transitions - Enable zoom out - Double tap animation speed - Show page number - 32-bit color - Page preload amount - The amount of pages to preload when reading. Higher values will result in a smoother reading experience, at the cost of higher cache and network usage. - Reduces banding, but may impact - performance - Invert double pages - Zoom into double page spreads - Navigate to pan - Split double pages in portrait - Crop borders - Crop borders (Paged) - Crop borders (Long strip) - Remove crop - Use custom brightness - Grayscale - Inverted - Use custom color filter - Color filter blend mode - Overlay - Multiply - Screen - Dodge / Lighten - Burn / Darken - Keep screen on - Skip chapters marked read - Skip filtered chapters - Skip duplicate chapters - Navigation - Volume keys - Invert volume keys - Background color - White - Gray - Black - Smart (by page) - Smart (by theme) - Default reading mode - Left to right - Right to left - Vertical - Continuous vertical - Paged - Scale type - Tap zones - Fit screen - Stretch - Fit width - Fit height - Original size - Smart fit - Zoom start position - Split double pages - Double pages - Single page - Switch to double pages - Switch to single page - Portrait - Landscape - Locked portrait - Locked landscape - R - G - B - A - Smart (based on page) - Smart (based on page and theme) - Always show chapter transition - If disabled, the transition page will be - skipped if the next chapter is loaded - Side padding - None - 5% - 10% - 15% - 20% - 25% - L shaped - Kindle-ish - Edge - Right and Left - Invert tap zones - None - Horizontally - Vertically - Both Axes - Cutout area behavior - Pad cutout areas - Start past cutout - Cutout area behavior only applies in portrait mode with certain scale types - Open legacy cutout settings - On devices older than Android 9.0, there\'s no way to modify cutout setting other than setting it manually through to your system settings - Show content in cutout area - Ignore cutout areas - Page layout - While using automatic page layout, you can still switch between layouts while reading without overriding this setting - Automatic (based on orientation) - Actions - Show on long press - Save pages in separate folders - Creates folders according to manga title - Sensitivity for hiding menu on scroll - Highest - High - Low - Lowest - - %1$d page - %1$d pages - - - Skipping %d chapter, either the source is missing it or it has been filtered out - Skipping %d chapters, either the source is missing them or they have been filtered out - - Custom display profile - - - About this %1$s - Start reading - Start reading Chapter %1$s - Continue reading Chapter %1$s - Continue reading - Chapters %1$s - Volume %1$d - Season %1$d - Added to library - Add to Library - Removed from library - Show %1$s - This entry\'s details page must be viewed before being able to migrate - You have an entry in your library with the same name but from a different source (%1$s).\n\nDo you still wish to continue? - %1$s copied to clipboard - Source not installed: %1$s - No description - Mark all chapters as read? - Mark all chapters as unread? - Remove from library - Select starting chapter - Select ending chapter - Search chapters - - Next unread chapter - Next %d unread chapters - - Custom range - All chapters - All unread chapters - All read chapters - All but bookmarked chapters - Add %1$s to library? - Show All - Show bookmarked chapters - Show downloaded chapters - Show unread chapters - Show read chapters - Hide chapter titles - Sort by source\'s order - Sort by chapter number - Newest to oldest - Oldest to newest - Add tag - Clear tags - Reset tags - Reset cover - Failed to update cover - Series must be in your library to edit - Remember this choice - Source not installed - Cover saved - Share cover - Error saving cover - Error sharing cover - App settings - Source settings - Custom series info - All read series - Set as default - Filter scanlator groups - - A chapter has been removed from the source:\n%2$s\nDelete - its download? - %1$s chapters have been removed from the source:\n%2$s\n\nDelete - their downloads? - - - - Tracking - Tracked - Not tracked - Services - One-way sync to update the chapter progress in tracking services. Set up tracking for individual entries from their tracking button. - Enhanced services - Services that provide enhanced features for specific sources. Entries are automatically tracked when added to your library. - Update tracking after reading - Update tracking when marked as read - Reading - Currently Reading - Dropped - On hold - Plan to read - Want to Read - Paused - Rereading - Reading List - Wish List - Complete List - On Hold List - Unfinished List - Score - Status - Started - Type - Refresh tracking - Add tracking - Select an entry - Source is not supported - No match found - Remove tracking from app - Tracker cannot be removed from %1$s while offline - Also remove from %1$s - Remove previous tracker? - Remove %1$s from %2$s and add %3$s - Keep both on %1$s and only replace locally - AniList - MyAnimeList - Kitsu - Bangumi - Shikimori - MangaUpdates - Komga - Kavita - Suwayomi - Update %1$s\'s scoring type - Scoring type updated - Could not update scoring type: %1$s - Started reading date - Finished reading date - Please log in to MAL again - Use suggested date - Failed to update %1$s - - - Select sources - Source migration - Migration - Skip pre-migration - Select a source, then select an item to - migrate - Data to include in migration - Search parameter (e.g. language:english) - Include extra search parameter when searching - Use source with the most chapters (slower) - Use first source with alternative - Skip this step next time - To show this screen again, go to Settings -> - Sources. - Latest: %1$s - migrating to - Don\'t migrate - Search manually - Migrate now - Copy now - Migrate - Migrate %1$s - Copy - No chapters found, this series cannot be used for - migration - No Alternatives Found - Stop migrating? - - Migrate %1$d%2$s series? - Migrate %1$d%2$s series? - - - Copy %1$d%2$s series? - Copy %1$d%2$s series? - - (skipping %1$d) - - %d series migrated - %d series migrated - - - - Settings - General - Reader - Appearance - Advanced - About - Help - Search settings - - Turn on %s - Turn off %s - Incognito mode - Pauses reading history - - - App theme - Light theme - Dark theme - Dark - AMOLED Black - Classic Blue - Midnight Dusk - Spring Blossom - Strawberry Daiquiri - A Brighter You (Dynamic) - A Calmer You (Dynamic) - Yotsuba - Tako - Yin - Yang - Chocolate Strawberries - Teal Ocean - Sapphire Dusk - Lavender - Violet - Hot Pink - Lime Time - Flat Lime - Pure White - Doki - Locale - Last used (Library or Recents) - System default - Date format - Check for updates - App updates - Updated to v%1$s - Secure screen - Secure screen hides app contents when switching apps and block screenshots - Auto-hide bottom navigation - Side navigation icon alignment - Use side navigation - Default behavior - By default, side navigation is used for certain phones and small tablets when in landscape, and always shows on larger tablets - Follow system theme - Pure black dark mode - Details page - Theme buttons based on cover - Expanded toolbar - Show a larger, expanded toolbar at the top of most pages (does not show on smaller devices regardless of setting) - Hides when scrolling - Hide notification content - Security - Starting screen - Back to start - Manage notifications - Pressing back to starting screen - Auto-updates - Auto-update app - Over Wi-Fi only - Over any network - Don\'t auto-update - Some languages may require an app relaunch to display correctly - - App shortcuts - Show recently used sources - Show recent series - Includes recently read, updated, and added series - Series shortcuts opens new chapters - When there\'s no new chapters, the series\' details will open instead - - - Data and storage - Storage location - Storage usage - Available: %1$s / Total: %2$s - - - Backup - Backup and restore - Create backup - Can be used to restore current library - Restore backup - Restore library from backup file - Restore already in progress - Backup already in progress - Backup location - Automatic backups - Backup frequency - Max automatic backups - Invalid backup file - Invalid backup file type: %1$s\nIt should end with ".proto.gz" or ".json". - Backup does not contain any entries. - Backup failed - No library entries to back up - Backup created - Restore completed - Failed to restore backup - Missing sources: - Trackers not logged into: - Data from the backup file will be restored.\n\nYou will need to install any missing extensions and log in to tracking services afterwards to use them. - Canceled restore - Error: empty URI - Creating backup - Automatic backups are highly recommended. You should keep copies in other places as well. - What do you want to backup? - Restoring backup - %02d min, %02d sec - Backup/restore may not function properly if MIUI Optimization is disabled. - Progress - Complete - - Done in %1$s with %2$s error - Done in %1$s with %2$s errors - - Not logged into %1$s - Include sensitive settings (e.g. tracker login tokens) - Last automatically backed up: %s - - - Clear chapter cache - Refresh the download cache - This will force the download cache to recalculate. Useful if you modified downloads outside of this app and want the app to pick them up - - Data Management - Check for beta releases - Try new features before they\'re officially released. Beta releases may be unstable and are provided to give feedback to the developer. - Rolling back to the previous production version may cause issues and could require clearing app data. - Beta releases may be unstable and could require clearing app data. - Crash logs - Dump crash logs - Saves error logs to a file for sharing with the developers - Some manufacturers have additional app restrictions that kill background services. This website has more info on how to fix it. - Crash logs saved - Network - DNS over HTTPS - Default user agent string - Invalid user agent string - Disabled - Cloudflare - Google - AdGuard - Quad9 - AliDNS - DNSPod - 360 - Quad 101 - Requires app restart to take effect - Used: %1$s - - Cache cleared. %d file has been deleted - Cache cleared. %d files have been deleted - - Error occurred while clearing - Clear cookies - Cookies cleared - Clear WebView data - WebView data cleared - Clear database - %1$d non-library entries in database - Delete history for entries that are not saved in your library - Are you sure? Read chapters and progress of non-library entries will be lost - Keep entries with read chapters - Entries deleted - Database clean - Refresh library metadata - Updates covers, genres, description and entries status information - Refresh tracking metadata - Updates status, score and last chapter read from the tracking services - Clean up downloaded chapters - Delete non-existent, partially downloaded, - and read chapter folders - Clean orphaned - Clean read - Clean entries not in library - Starting cleanup - No folders to cleanup - Disable battery optimization - Disable this if you are experiencing issues - with updating or restoring your library - Battery optimization is already disabled - - Cleanup done. Removed %d folder - Cleanup done. Removed %d folders - - Clean up cached covers - Delete old and unused cached covers of - entries in your library that has been updated.\nCurrently using: %1$s - Clear cached covers not in library - Delete all covers cached that are - not in your library \nCurrently using: %1$s - Most entries - Select uninstalled sources - Debug info - Background activity - - - Global search - Check for extension updates - Auto-update extensions - Notify extension has been updated - Some extensions may not be auto-updated if they were installed outside this app - Only search pinned sources - Hide entries already in library - Match pinned sources - Match enabled sources - Only enable your pinned sources for - migration - Only enable your currently enabled sources for - migration - Use last saved pre-migration preferences - and sources to mass migrate - Migration sources changed - You can also migrate by selecting entries in your - library - Source migration guide - NSFW (18+) sources - Show in sources and extensions lists - This does not prevent unofficial or potentially incorrectly flagged extensions from surfacing NSFW (18+) content within the app. - - - Extension Repos - Add new repo - Add repo - Invalid repo url - Repo already exists! - You haven\'t added any repos yet. - Delete repo? - Are you sure you wish to delete the repo \"%s\"? - Replace - Signing Key Fingerprint Already Exists - Repository %1$s has the same Signing Key Fingerprint as %2$s.\nIf this is expected, %2$s will be replaced, otherwise contact your repo maintainer. - - - Version - Build time - Send crash reports - Helps fix any bugs. No sensitive data will be sent - What\'s new - FAQ and Guides - What\'s new in this release - Help translate - Helpful translation links - Website - Open source licenses - Open source repo - Unable to open url - - - Log in to %1$s - Username - Email address - Password - Log in - Log out - Log out from %1$s? - - Successfully logged in - Username or password cannot be blank - - You are now logged out - - - Downloads - Download queue - Downloading: %1$s - Cancel all - Move series to top - Move series to bottom - Downloads can be cancelled by swiping them away\nSwipe this tip to dismiss it - Cancel all for this series - Downloaded - Not downloaded - Downloading - Download - Start downloading now - Remove download - Remove downloads - Downloading (%1$d/%2$d) - Invalid download location - Download paused - Nothing is currently downloading - Download complete - Download error - Manage what\'s downloading - Visit the recents tab to access the download - queue. You can also double tap or press and hold for quicker access - Couldn\'t download chapters due to low disk space - Page %d not found while splitting - Couldn\'t split downloaded image - Auto-append ID - May fix issue with downloaded chapters conflicts with one another when they have the same name - - - Could not download chapter due to unexpected error - No Wi-Fi connection available - No network connection available - - - Download location - Only download over Wi-Fi - Remove when marked as read - Allow deleting bookmarked chapters - Remove after read - Excluded categories - Custom location - Last read chapter - Second to last chapter - Third to last chapter - Fourth to last chapter - Fifth to last chapter - Download ahead - Auto download while reading - Only works on entries in library and if the current chapter plus the next one are already downloaded - Download new chapters - Categories to include in download - Delete removed chapters - Delete downloaded chapters if the source - has removed the chapter online - Delete during global updates, ask on chapters page - Always keep - Always delete - Automatic removal - Save as CBZ archive - Split tall images - Improves reader performance - - - Stat - Stats - Statistics - Statistics details - Titles in library - Read chapters - Mean tracking score - Tracked titles - Downloaded chapters - Tags - Local titles - Titles in global update - Trackers - Read duration - Time spent in the reader, based on chapter history - Status distribution - Score distribution - View detailed statistics - Count - Not rated - Source - Tracker - Length - Start year - No data found for your current filters - - %d series types - - - %d sources - - - %d statuses - - - %d languages - - - - Manual - Every 6 hours - Every 12 hours - Daily - Every 2 days - Every 3 days - Weekly - - After %1$s minute - After %1$s minutes - - - - Select cover image - Select backup file - No file picker app found - Failed to acquire persistent folder access. The app may behave unexpectedly. - - - See your recently updated library entries - Widget not available when app lock is enabled - - - Add - Apply - Add to %1$s - Added to %1$s - All - Alphabetically - Always - Always ask - Ascending - Automatic - Back - BETA - Bottom - Cancel - Center - Change - Charging - Battery not low - Clear - Clear filters - Close - Common - Cover of series - Create - Date - Descending - Default - Delete - Deleted: %1$s - Display - Download unread - Drag handle - Edit - Enable - Enabled - Exclude: %s - Fast - Filter - Forward - Free - Hide - Ignore - Include: %s - Install - Keep - Keep in %1$s - Learn why - Left - Less - Loading… - Lock - Mark all as read - Mark all as unread - Mark as read - Mark as unread - Mark a range of chapters as read - Mark a range of chapters as unread - Mark previous chapters as read - Mark previous chapters as unread - menu - More - Move to bottom - Move to top - Move to %1$s - Moved to %1$s - Name - Recently updated - Recently installed - Language - Never - Just now - Newest - Next - No animation - Normal - Oldest - Open - Open in app - Open in browser - Open log - Open in WebView - Options - Pause - Picture saved - Pin - Pinned - Preview - Previous - Remove - Remove from %1$s - Reorder - Reset - Restore - Resume - Retry - Right - Rotation - Default orientation - Orientation - Save - Search - Search %1$s - Select all - Select none - Select inverse - Selection - Share - Sort - Sort & Filter - Start - Stop - Tag - Tap to see details - Tap to learn more - Top - Undo - Unknown error - Unpin - Use default - View all - View chapters - Warning - Wi-Fi - Webtoon - Internal error: %s - SFW - NSFW - Content type - - - An Unexpected Error Occurred - %s ran into an unexpected error. We suggest you screenshot this message, dump the crash logs, and then share it to a GitHub Issue. - Restart the application - - Refresh - diff --git a/core/src/androidMain/kotlin/eu/kanade/tachiyomi/util/system/ToastExtensions.kt b/core/src/androidMain/kotlin/eu/kanade/tachiyomi/util/system/ToastExtensions.kt index d2eccb8e30..2b674180e0 100644 --- a/core/src/androidMain/kotlin/eu/kanade/tachiyomi/util/system/ToastExtensions.kt +++ b/core/src/androidMain/kotlin/eu/kanade/tachiyomi/util/system/ToastExtensions.kt @@ -5,6 +5,7 @@ import android.widget.Toast import androidx.annotation.StringRes import dev.icerock.moko.resources.StringResource import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource /** * Display a toast in this context. diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index 74ab31e5fc..5d413728f9 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -3,7 +3,7 @@ chucker = "3.5.2" coil3 = "3.0.0-alpha06" flexible-adapter = "c8013533" fast_adapter = "5.6.0" -moko = "0.24.0" +moko = "0.24.1" nucleus = "3.0.0" okhttp = "5.0.0-alpha.14" shizuku = "12.1.0" diff --git a/i18n/build.gradle.kts b/i18n/build.gradle.kts index 20a91f85ee..9188586bba 100644 --- a/i18n/build.gradle.kts +++ b/i18n/build.gradle.kts @@ -12,14 +12,13 @@ kotlin { applyDefaultHierarchyTemplate() sourceSets { - val commonMain by getting { + commonMain { dependencies { api(libs.moko.resources) api(libs.moko.resources.compose) } } - val androidMain by getting { - dependsOn(commonMain) + androidMain { } } } diff --git a/i18n/src/androidMain/kotlin/yokai/util/lang/MokoExtensions.kt b/i18n/src/androidMain/kotlin/yokai/util/lang/MokoExtensions.kt index 30368d819a..85fcacae59 100644 --- a/i18n/src/androidMain/kotlin/yokai/util/lang/MokoExtensions.kt +++ b/i18n/src/androidMain/kotlin/yokai/util/lang/MokoExtensions.kt @@ -1,8 +1,22 @@ package yokai.util.lang import android.content.Context +import dev.icerock.moko.resources.PluralsResource import dev.icerock.moko.resources.StringResource +import dev.icerock.moko.resources.desc.Plural +import dev.icerock.moko.resources.desc.PluralFormatted import dev.icerock.moko.resources.desc.Resource +import dev.icerock.moko.resources.desc.ResourceFormatted import dev.icerock.moko.resources.desc.StringDesc -fun Context.getString(stringRes: StringResource): String = StringDesc.Resource(stringRes).toString(this) +fun Context.getString(stringRes: StringResource) = + StringDesc.Resource(stringRes).toString(this) + +fun Context.getString(stringRes: StringResource, vararg args: Any) = + StringDesc.ResourceFormatted(stringRes, *args).toString(this) + +fun Context.getString(stringPlural: PluralsResource, quantity: Int) = + StringDesc.Plural(stringPlural, quantity).toString(this) + +fun Context.getString(stringPlural: PluralsResource, quantity: Int, vararg args: Any) = + StringDesc.PluralFormatted(stringPlural, quantity, *args).toString(this) diff --git a/i18n/src/commonMain/moko-resources/ar/plurals.xml b/i18n/src/commonMain/moko-resources/ar/plurals.xml new file mode 100644 index 0000000000..2bdf73bcba --- /dev/null +++ b/i18n/src/commonMain/moko-resources/ar/plurals.xml @@ -0,0 +1,230 @@ + + + + لا توجد تحديثات للإضافات + يتوفَّر تحديث لإضافة + يتوفَّر تحديثات لإضافتين + تتوفَّر %d تحديثات للإضافات + يتوفَّر %d تحديثًا للإضافات + يتوفَّر %d تحديث للإضافات + + + + لا توجد فئات + فئة + فئتان + %d فئات + %d فئةً + %d فئة + + + + انتهت الصفحات + تبقَّت صفحة + تبقَّت صفحتان + تبقَّت %1$d صفحات + تبقَّت %1$d صفحةً + تبقَّت %1$d صفحة + + + + لم يُزل أيُّ فصل من المصدر: + \n%2$s + \nأأحذف تنزيلاته؟ + أُزيل فصل من المصدر: + \n%2$s + \nأأحذف تنزيلاته؟ + أُزيل فصلان من المصدر: + \n%2$s + \nأأحذف تنزيلاتهما؟ + أُزيلت %1$s فصول من المصدر: + \n%2$s + \nأأحذف تنزيلاتهم؟ + أُزيل %1$s فصلًا من المصدر: + \n%2$s + \nأأحذف تنزيلاتهم؟ + أُزيل %1$s فصل من المصدر: + \n%2$s + \nأأحذف تنزيلاتهم؟ + + + + ألا أزيل أيَّ فصل؟ + أأزيل فصلًا منزَّلًا؟ + أأزيل فصلين المنزَّلين؟ + أأزيل %1$d فصول منزَّلة؟ + أأزيل %1$d فصلًا منزَّلًا؟ + أأزيل %1$d فصل منزَّل؟ + + + + بعد %1$s دقيقة + بعد %1$s دقيقة + بعد %1$s دقيقتين + بعد %1$s دقائق + بعد %1$s دقائق + بعد %1$s دقائق + + + + تم التنظيف. تمت إزالة %d مجلد + تم التنظيف. تمت إزالة %d مجلد + تم التنظيف. تمت إزالة %d مجلدين + تم التنظيف. تمت إزالة %d مجلدات + تم التنظيف. تمت إزالة %d مجلدات + تم التنظيف. تمت إزالة %d مجلدات + + + + لصفر عنوان + لعنوان + لعنوانين + ل‍ %d عناوين + ل‍ %d عنوانًا + ل‍ %d عنوان + + + + ولا أيِّ فصل + وفصل + وفصلين + و %1$d فصول + و %1$d فصلًا + و %1$d فصل + + + + تمَّ في %1$s وبدون أخطاء + تمَّ في %1$s وفيه خطأ + تمَّ في %1$s وفيه خطآن + تمَّ في %1$s وفيه %2$s أخطاء + تمَّ في %1$s وفيه %2$s خطأً + تمَّ في %1$s وفيه %2$s خطأ + + + + لا يوجد أيُّ فصل + فصل واحد + فصلان + %1$s فصول + %1$s فصلًا + %1$s فصل + + + + لم تُرحَّل أيُّ سلسلة + رُحِّلت السلسلة + رُحِّلت سلسلتان + رُحِّلت %d سلسلات + رُحِّلت %d سلسلةً + رُحِّلت %d سلسلةٍ + + + + ألا أنسخ أيَّ سلسلة؟ + أأنسخ السلسلة؟ + أأنسخ السلسلتين؟ + أأنسخ %1$d (بتخطي %2$s) سلاسل؟ + أأنسخ %1$d (بتخطي %2$s) سلسلةً؟ + أأنسخ %1$d (بتخطي %2$s) سلسلةٍ؟ + + + + ألا أرحِّل أيَّ سلسلة؟ + أأرحِّل السلسلة؟ + أأرحِّل السلسلتين؟ + أأرحِّل %1$d (بتخطِّي %2$s) سلسلات؟ + أأرحِّل %1$d (بتخطِّي %2$s) سلسلةً؟ + أأرحِّل %1$d (بتخطِّي %2$s) سلسلةٍ؟ + + + + لا توجد صفحات + صفحة + صفحتان + %1$d صفحات + %1$d صفحةً + %1$d صفحة + + + + لا يوجد تحديث معلَّق + يوجد تحديث معلَّق + يوجد تحديثان معلَّقان + توجد %d تحديثات معلَّقات + يوجد %d تحديثًا معلَّقًا + يوجد %d تحديث معلَّق + + + + لم تُحدَّث أيُّ إضافة + حُدِّثت إضافة + حُدِّثت إضافتان + حُدِّثت %d إضافات + حُدِّثت %d إضافةً + حُدِّثت %d إضافة + + + + لا يُتخطَّى أيُّ فصل + يُتخطَّى فصل، وذلك إما لأن المصدر مفقود أو لأنه مصفًّى + يُتخطَّى فصلان، وذلك إما لأن المصدر مفقود أو لأنهما مصفَّان + تُتخطَّى %d فصول، وذلك إما لأن المصدر مفقود أو لأنهم مصفَّون + يُتخطَّى %d فصلًا، وذلك إما لأن المصدر مفقود أو لأنهم مصفَّون + يُتخطَّى %d فصل، وذلك إما لأن المصدر مفقود أو لأنهم مصفَّون + + + + تم تنظيف الملفات المؤقتة. تم حذف %d من الملفات + تم تنظيف الملفات المؤقتة. تم حذف %d من الملفات + تم تنظيف الملفات المؤقتة. تم حذف %d من الملفات + تم تنظيف الملفات المؤقتة. تم حذف %d من الملفات + تم تنظيف الملفات المؤقتة. تم حذف %d من الملفات + تم تنظيف الملفات المؤقتة. تم حذف %d من الملفات + + + + لا يوجد فصل تالٍ لم يُقرأ + الفصل غير المقروء التالي + الفصلان غير المقروءين التاليان + %d فصول تالية لم تُقرأ + %d فصلًا تاليًا لم يُقرؤوا + %d فصل تالٍ لم يُقرؤوا + + + + %d انواع المسلسلات + %d انواع المسلسلات + %d نوعين من المسلسلات + %d انواع قليلة من السلسلات + %d عدة انواع من المسلسلات + %d انواع من المسلسلات + + + + %d مصدر + %d مصدر + %d مصدران + %d مصادر + %d مصادر + %d مصادر + + + + %d لغة + %d لغة + %d لغتان + %d لغات + %d لغات + %d لغات + + + + %d وضع + %d وضع + %d وضعان + %d اوضاع + %d اوضاع + %d اوضاع + + diff --git a/app/src/main/res/values-ar/strings.xml b/i18n/src/commonMain/moko-resources/ar/strings.xml similarity index 86% rename from app/src/main/res/values-ar/strings.xml rename to i18n/src/commonMain/moko-resources/ar/strings.xml index cebea6cbb9..dae24365fe 100644 --- a/app/src/main/res/values-ar/strings.xml +++ b/i18n/src/commonMain/moko-resources/ar/strings.xml @@ -274,14 +274,6 @@ التحقق من الموقع الإلكتروني في WebView متروك باتت هذه الإضافة لا تتوفَّر. - - لا توجد تحديثات للإضافات - يتوفَّر تحديث لإضافة - يتوفَّر تحديثات لإضافتين - تتوفَّر %d تحديثات للإضافات - يتوفَّر %d تحديثًا للإضافات - يتوفَّر %d تحديث للإضافات - يزيد من سلاسة تدرج الألوان بالصور، ولكنه قد يؤثر على الأداء تخطَّ الفصول المصفَّاة عموديٌّ مستمرٌّ @@ -336,14 +328,6 @@ أنشئ فئةً جديدةً «%1$s» موجود في قائمة الانتظار بالفعل أضف «%1$s» إلى قائمة انتظار التحديثات - - لا توجد فئات - فئة - فئتان - %d فئات - %d فئةً - %d فئة - لم يُعثر على الفصل أٌزيلت الفصول. أُزيلت العلامة @@ -376,44 +360,8 @@ أضف فئات يوجد العنصر في الفئة سوف تنقل عناصر هذه الفئة إلى الفئة المبدئية. - - انتهت الصفحات - تبقَّت صفحة - تبقَّت صفحتان - تبقَّت %1$d صفحات - تبقَّت %1$d صفحةً - تبقَّت %1$d صفحة - احتفظ دائما - - لم يُزل أيُّ فصل من المصدر: -\n%2$s -\nأأحذف تنزيلاته؟ - أُزيل فصل من المصدر: -\n%2$s -\nأأحذف تنزيلاته؟ - أُزيل فصلان من المصدر: -\n%2$s -\nأأحذف تنزيلاتهما؟ - أُزيلت %1$s فصول من المصدر: -\n%2$s -\nأأحذف تنزيلاتهم؟ - أُزيل %1$s فصلًا من المصدر: -\n%2$s -\nأأحذف تنزيلاتهم؟ - أُزيل %1$s فصل من المصدر: -\n%2$s -\nأأحذف تنزيلاتهم؟ - الأخيرة - - ألا أزيل أيَّ فصل؟ - أأزيل فصلًا منزَّلًا؟ - أأزيل فصلين المنزَّلين؟ - أأزيل %1$d فصول منزَّلة؟ - أأزيل %1$d فصلًا منزَّلًا؟ - أأزيل %1$d فصل منزَّل؟ - الأعلى استخدم الافتراضيّ وسم @@ -428,25 +376,9 @@ مقبض السحب تم الحذف: %1$s الأسفل - - بعد %1$s دقيقة - بعد %1$s دقيقة - بعد %1$s دقيقتين - بعد %1$s دقائق - بعد %1$s دقائق - بعد %1$s دقائق - إحذف دائما حذف أثناء التحديثات الشاملة، اسأل في صفحة الفصول حذف الفصول التي تمت إزالتها - - تم التنظيف. تمت إزالة %d مجلد - تم التنظيف. تمت إزالة %d مجلد - تم التنظيف. تمت إزالة %d مجلدين - تم التنظيف. تمت إزالة %d مجلدات - تم التنظيف. تمت إزالة %d مجلدات - تم التنظيف. تمت إزالة %d مجلدات - تنزيل غير المقروءة حذف الفصول التي تم تنزيلها إذا كان المصدر قد أزالها عبر الإنترنت لا شيء يتم تنزيله حاليا @@ -562,10 +494,10 @@ قرئ أخيرًا %1$s المضافة حديثًا حذف كافة الأغلفة المخزنة مؤقتاً غير الموجودة في مكتبتك -\nحاليا يتم استخدام: %1$s + \nحاليا يتم استخدام: %1$s مسح الأغلفة المخزنة مؤقتًا غير الموجودة في المكتبة احذف الغُلُف القديمة للمدخلات التي حُدِّثت غُلُفها. -\nيُستخدَم الآن: %1$s + \nيُستخدَم الآن: %1$s تنظيف الأغلفة المخزنة مؤقتًا فشلت مشاركة الغلاف خطأ في حفظ الغلاف @@ -577,22 +509,6 @@ ضمِّنه في التحديث الشامل تجاهل البوادئ (a، an، the) في بداية عناوين السلاسل في حال فرزها حسب ترتيب الحروف افرز حسب تجاهل المواضيع - - لصفر عنوان - لعنوان - لعنوانين - ل‍ %d عناوين - ل‍ %d عنوانًا - ل‍ %d عنوان - - - ولا أيِّ فصل - وفصل - وفصلين - و %1$d فصول - و %1$d فصلًا - و %1$d فصل - المزيد من إعدادات المكتبة أخف قافز الفئات اعرضه @@ -640,20 +556,12 @@ النسخ الاحتياطيُّ التلقائيُّ ملفُّ النسخ الاحتياطيِّ غير صالح نوع ملفِّ النسخ الاحتياطي غير صالح: %1$s -\nيجب أن ينتهي ب‍ .proto.gz أو .json. + \nيجب أن ينتهي ب‍ .proto.gz أو .json. ليس في النسخة الاحتياطية أيُّ سلسلة. المصادر المفقودة: المتتبِّعات التي لم يسجَّل الدخول فيها: أُلغيت الاستعادة %02d دقيقة و %02d ثانية - - تمَّ في %1$s وبدون أخطاء - تمَّ في %1$s وفيه خطأ - تمَّ في %1$s وفيه خطآن - تمَّ في %1$s وفيه %2$s أخطاء - تمَّ في %1$s وفيه %2$s خطأً - تمَّ في %1$s وفيه %2$s خطأ - دليل ترحيل المصدر محتوى +18 هذا لا يمنع الإضافات غير الرسمية أو التي تم وضع علامة عليها بشكل غير صحيح من إظهار محتوى غير لائق داخل التطبيق. @@ -667,20 +575,12 @@ حُدِّث إلى الإصدار v%1$s التالي سوف تُستعاد البيانات من ملفِّ النسخ الاحتياطيِّ. -\n -\nعليك تثبيت أيِّ إضافة مفقودة وتسجيل دخولك في خدمات التتبع لتستخدمهم. + \n + \nعليك تثبيت أيِّ إضافة مفقودة وتسجيل دخولك في خدمات التتبع لتستخدمهم. بحث شامل معطل عرضيٌّ طوليٌّ - - لا يوجد أيُّ فصل - فصل واحد - فصلان - %1$s فصول - %1$s فصلًا - %1$s فصل - الفئة فئة جديدة لا توجد أيُّ فصول للتحذف @@ -728,14 +628,6 @@ ليمون أخضر مسطَّح احفظ الصفحات المجمَّعة شارك الصفحات المجمَّعة - - لم تُرحَّل أيُّ سلسلة - رُحِّلت السلسلة - رُحِّلت سلسلتان - رُحِّلت %d سلسلات - رُحِّلت %d سلسلةً - رُحِّلت %d سلسلةٍ - الحذف التلقائي ضغط «عد لشاشة البداية» تغيير هذا يعيد يصفِّر وضع القراءة لهذه السلسلة @@ -755,35 +647,11 @@ الصفحات %1$s صفِّ اللغات أظهر الفصول المقروءة في «مجمَّع» و «الكلُّ» - - ألا أنسخ أيَّ سلسلة؟ - أأنسخ السلسلة؟ - أأنسخ السلسلتين؟ - أأنسخ %1$d (بتخطي %2$s) سلاسل؟ - أأنسخ %1$d (بتخطي %2$s) سلسلةً؟ - أأنسخ %1$d (بتخطي %2$s) سلسلةٍ؟ - - - ألا أرحِّل أيَّ سلسلة؟ - أأرحِّل السلسلة؟ - أأرحِّل السلسلتين؟ - أأرحِّل %1$d (بتخطِّي %2$s) سلسلات؟ - أأرحِّل %1$d (بتخطِّي %2$s) سلسلةً؟ - أأرحِّل %1$d (بتخطِّي %2$s) سلسلةٍ؟ - معلومات التطبيق أخفِ أزرار التنقُّل تلقائيًّا عطِّل %s تخصيص معلومات السلسلة لك التبديل بين النُّسُق بينما تقرأ دون تجاوز هذا الإعداد، وذلك عند استخدامك تنسيق الصفحة التلقائيَّ - - لا توجد صفحات - صفحة - صفحتان - %1$d صفحات - %1$d صفحةً - %1$d صفحة - إجراءات تلقائيٌّ (حسب الاتِّجاه) أظهر عند الضغط مطوَّلًا @@ -866,14 +734,6 @@ قسِّم الصفحات المزدوجة قسِّم الصفحات المزدوجة في الوضع الطولي حُدِّثت الإضافات - - لا يوجد تحديث معلَّق - يوجد تحديث معلَّق - يوجد تحديثان معلَّقان - توجد %d تحديثات معلَّقات - يوجد %d تحديثًا معلَّقًا - يوجد %d تحديث معلَّق - أخفِ محتوى الإشعارات تُحدَّث الإضافات قد لا تزال بعض الإضافات تطالب بتثبيتها أولًا. @@ -895,8 +755,8 @@ لم يعلَّم يتطلب TachiyomiJ2K الوصول إلى جميع الملفات لينزِّل الفصول. اضغط هنا ثم مكِّن «السماح بالوصول لإدارة جميع الملفات.» يحتاج TachiyomiJ2K للوصول إلى كلِّ الملفَّات في أندرويد ١١، فبذلك ينزِّل الفصول ويحتاط ويقرأ السلاسل المنزَّلة. -\n -\nمكِّن «اسمح بإدارة كافة الملفات.» عندما تراها في الشاشة التالية + \n + \nمكِّن «اسمح بإدارة كافة الملفات.» عندما تراها في الشاشة التالية إذن الوصول إلى الملفات مطلوب تحذير بحث %1$s @@ -920,22 +780,6 @@ السلوك المبدئيُّ استخدم التنقُّل الجانبيَّ المظهر - - لم تُحدَّث أيُّ إضافة - حُدِّثت إضافة - حُدِّثت إضافتان - حُدِّثت %d إضافات - حُدِّثت %d إضافةً - حُدِّثت %d إضافة - - - لا يُتخطَّى أيُّ فصل - يُتخطَّى فصل، وذلك إما لأن المصدر مفقود أو لأنه مصفًّى - يُتخطَّى فصلان، وذلك إما لأن المصدر مفقود أو لأنهما مصفَّان - تُتخطَّى %d فصول، وذلك إما لأن المصدر مفقود أو لأنهم مصفَّون - يُتخطَّى %d فصلًا، وذلك إما لأن المصدر مفقود أو لأنهم مصفَّون - يُتخطَّى %d فصل، وذلك إما لأن المصدر مفقود أو لأنهم مصفَّون - دليل البدء لا يوجد تطابق للتصفية أظهر الفئات الفارغة أثناء التصفية @@ -943,14 +787,6 @@ مسح المرشحات غسق ياقوتي محيط أزرق مخضرٌّ - - تم تنظيف الملفات المؤقتة. تم حذف %d من الملفات - تم تنظيف الملفات المؤقتة. تم حذف %d من الملفات - تم تنظيف الملفات المؤقتة. تم حذف %d من الملفات - تم تنظيف الملفات المؤقتة. تم حذف %d من الملفات - تم تنظيف الملفات المؤقتة. تم حذف %d من الملفات - تم تنظيف الملفات المؤقتة. تم حذف %d من الملفات - روابط مساعدة للترجمة ساعد بالترجمة قد تؤدي التحديثات الكبيرة إلى زيادة استخدام البطارية، وقد تبطِّئ المصادر. اضغط هنا للمزيد من المعلومات. @@ -1006,13 +842,13 @@ %1$d مدخلةً في قاعدة البيانات وليست في المكتبة قاعدة البيانات نظيفة لديك مدخلة في مكتبتك بنفس السم و لكن من مصدر مختلف (%1$s). -\n -\nألا زلت تريد أن تكمل؟ + \n + \nألا زلت تريد أن تكمل؟ حدِّد المعكوس أظهر %1$s عليك تفقُّد تفاصيل هذه المدخلة قبل ترحيلها يمكنك الغاء التنزيل عبر سحب هذا الإشعار -\nاسحب هذا التلميح بسحبه + \nاسحب هذا التلميح بسحبه إختار المصادر الغير مثبتة عدد المجلات تُخُطِّيت لأنها تمِّت @@ -1045,14 +881,6 @@ الأسئلة الشائعة والشروحات يعمل فقط على الإدخالات في المكتبة وإذا كان الفصل الحالي بالإضافة إلى الفصل التالي قد تم تنزيلهم بالفعل التنزيل المسبق - - لا يوجد فصل تالٍ لم يُقرأ - الفصل غير المقروء التالي - الفصلان غير المقروءين التاليان - %d فصول تالية لم تُقرأ - %d فصلًا تاليًا لم يُقرؤوا - %d فصل تالٍ لم يُقرؤوا - لماذا تُخفي الشاشة الآمنة محتوى التطبيق عند التبديل بين التطبيقات، وتمنع التقاط الشاشة كذلك افتح في التطبيق @@ -1099,38 +927,6 @@ العناوين في التحديث العالمي متعقب الطول - - %d انواع المسلسلات - %d انواع المسلسلات - %d نوعين من المسلسلات - %d انواع قليلة من السلسلات - %d عدة انواع من المسلسلات - %d انواع من المسلسلات - - - %d مصدر - %d مصدر - %d مصدران - %d مصادر - %d مصادر - %d مصادر - - - %d لغة - %d لغة - %d لغتان - %d لغات - %d لغات - %d لغات - - - %d وضع - %d وضع - %d وضعان - %d اوضاع - %d اوضاع - %d اوضاع - إحصائيات مفصله عناوين في المكتبه الفصول المقروء @@ -1167,4 +963,4 @@ معلومات التنقيح الأنشطة التي تعمل في الخلفية شارك الغلاف - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/az/plurals.xml b/i18n/src/commonMain/moko-resources/az/plurals.xml new file mode 100644 index 0000000000..31d3381bad --- /dev/null +++ b/i18n/src/commonMain/moko-resources/az/plurals.xml @@ -0,0 +1,17 @@ + + + + Endirilmiş %1$d bölüm silinsin\? + Endirilmiş %1$d bölüm silinsin\? + + + + %1$s bölüm + %1$s bölüm + + + + %1$d səhifə qaldı + %1$d səhifə qaldı + + diff --git a/app/src/main/res/values-az/strings.xml b/i18n/src/commonMain/moko-resources/az/strings.xml similarity index 85% rename from app/src/main/res/values-az/strings.xml rename to i18n/src/commonMain/moko-resources/az/strings.xml index 5a7fe12cf3..1558940540 100644 --- a/app/src/main/res/values-az/strings.xml +++ b/i18n/src/commonMain/moko-resources/az/strings.xml @@ -2,14 +2,6 @@ Ad Daha çox - - Endirilmiş %1$d bölüm silinsin\? - Endirilmiş %1$d bölüm silinsin\? - - - %1$s bölüm - %1$s bölüm - TachiyomiJ2K bölümləri yükləmək üçün bütün fayllara giriş tələb edir. Bura klikləyin, sonra \"Bütün faylları idarə etmək üçün girişə icazə verin\" funksiyasını aktivləşdirin. Manga Komiks @@ -48,14 +40,10 @@ Sırala Bölümlər tapılmadı Səhifələr tapılmadı - - %1$d səhifə qaldı - %1$d səhifə qaldı - Fayl icazələri tələb olunur TachiyomiJ2K bölümləri yükləmək, avtomatik ehtiyat nüsxələri yaratmaq və lokal manqa oxumaq üçün Android 11-də bütün fayllara giriş icazəsi olmalıdır. -\n -\nNövbəti ekranda \"Bütün faylları idarə etmək üçün girişə icazə verin\" seçimini aktivləşdirin. + \n + \nNövbəti ekranda \"Bütün faylları idarə etmək üçün girişə icazə verin\" seçimini aktivləşdirin. Manhwa Manhua Boş olduqda kilidlə @@ -71,4 +59,4 @@ Skanlyatorlar Kateqoriya Kateqoriyalar - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/base/plurals.xml b/i18n/src/commonMain/moko-resources/base/plurals.xml new file mode 100644 index 0000000000..4891762329 --- /dev/null +++ b/i18n/src/commonMain/moko-resources/base/plurals.xml @@ -0,0 +1,120 @@ + + + + Remove %1$d downloaded chapter? + Remove %1$d downloaded chapters? + + + + %1$s chapter + %1$s chapters + + + + %1$d page left + %1$d pages left + + + + %d category + %d categories + + + + For %d title + For %d titles + + + + and %1$d more chapter + and %1$d more chapters + + + + %d update pending + %d updates pending + + + + Extension updated + %d extensions updated + + + + Extension update available + %d extension updates available + + + + %1$d page + %1$d pages + + + + Skipping %d chapter, either the source is missing it or it has been filtered out + Skipping %d chapters, either the source is missing them or they have been filtered out + + + + Next unread chapter + Next %d unread chapters + + + + A chapter has been removed from the source:\n%2$s\nDelete + its download? + %1$s chapters have been removed from the source:\n%2$s\n\nDelete + their downloads? + + + + Migrate %1$d%2$s series? + Migrate %1$d%2$s series? + + + + Copy %1$d%2$s series? + Copy %1$d%2$s series? + + + + %d series migrated + %d series migrated + + + + Done in %1$s with %2$s error + Done in %1$s with %2$s errors + + + + Cache cleared. %d file has been deleted + Cache cleared. %d files have been deleted + + + + Cleanup done. Removed %d folder + Cleanup done. Removed %d folders + + + + %d series types + + + + %d sources + + + + %d statuses + + + + %d languages + + + + After %1$s minute + After %1$s minutes + + diff --git a/i18n/src/commonMain/moko-resources/base/strings.xml b/i18n/src/commonMain/moko-resources/base/strings.xml index b26e436567..7abfabfe97 100644 --- a/i18n/src/commonMain/moko-resources/base/strings.xml +++ b/i18n/src/commonMain/moko-resources/base/strings.xml @@ -1,17 +1,1173 @@ - No recently read or updated series + Yōkai + Yōkai + Yokai + + File permissions required + TachiyomiJ2K requires access to all files in Android 11 to download chapters, create automatic backups, and read local series. \n\nOn the next screen, enable \"Allow access to manage all files.\" + TachiyomiJ2K requires access to all files to download chapters. Tap here, then enable \"Allow access to manage all files.\" + + Welcome! + Let\'s pick some defaults. You can always change these things later in the settings. + Get started + Select a folder where %1$s will store chapter downloads, backups, and more.\n\nA dedicated folder is recommended.\n\nSelected folder: %2$s + Select a folder + Updating from an older version and not sure what to select? Refer to the Tachiyomi upgrade section on the Mihon storage guide for more information. + Storage guide + Required + Optional but recommended + Install apps permission + To install the app on updates. + Notification permission + Get notified for library updates and more. + Background battery usage + Avoid interruptions to long-running library updates, downloads, and backup restores. + Grant + + No storage location set + Invalid location: %s + Invalid location + + + + + Manga + Manhwa + Manhua + Comic + + + Library entries + Not started + In progress + Read + Title + Author + Artist + Description + Move %1$s to… + Add %1$s to… + + + Ongoing + Unknown + Unknown Status + Licensed + Completed + Publishing finished + Cancelled + On hiatus + + + Unlock to access Library + Unlock + Require unlock + Lock when idle + + + Chapters + New chapters + Unread + Last read Chapter %1$s + Chapter %1$s + Chapter %1$d of %2$d + All chapters read + Bookmarked + Not bookmarked + Marked as read + Marked as unread + Removed bookmark + Chapters removed. + Chapter not found + Invalid chapter format + Order by + No chapters found + No pages found + RARv5 format is not supported + Remove all downloads? + No chapters to delete + By source\'s order + By chapter number + By upload date + Scanlators + + + Category + Categories + Adding %1$s to update queue + %1$s is already in queue + Create new category + New category + Category is empty + Show empty categories while filtering + No matches for your filters + Default category + Delete category? + Entries in this category will moved into the + default category. + Entry already in category + Add categories + Add/Edit categories + Edit categories + Manage category + Move to categories + A category with that name already exists! + Category name cannot be blank + Category deleted + Press and hold to edit a category + Jump to category + + + Update + Updating %1$s + Update available + New version available! + New beta version available! + No new updates available + Searching for updates… + Release page + Could not install update + Update completed + + + + + Library + Your library + Updating library + Not selected + Selected + Selected: %1$d + Local + Search title, tags, source + Your library is empty, add series to your + library from the browse tab. + No matches found for your current filters + Getting started guide + Show all categories + Move collapsed dynamic categories to bottom + Show number of items + When grouping library by sources, status, etc. + Always show current category + Category hopper long-press action + Expand/collapse all categories + Open a random series + Expand all categories + Collapse all categories + Reorder filters + %d unread + Search \"%1$s\" globally + + Read progress + Series type + Series + Group library by… + Tracking status + Ungrouped + + + Sort by + Total chapters + Date added + Last read + Date fetched + Latest chapter + Drag & Drop + + + Display options + Can also be found by expanding library filters + List + Comfortable Grid + Cover-only grid + Compact Grid + Download badges + Language badges + Hide start reading button + Badges + Uniform grid covers + Use staggered grid + Show outline around covers + Grid size + %d per row + Hide unread badges + Show unread badges + Show unread count + Tap the Library icon to show filters + Display as + Hide category hopper + More library settings + Shift one page over + Shift double pages + + + Allowing notifications is recommended to keep your library and app up to date. + New chapters found + Large updates may lead to increased battery usage and sources becoming slower. Tap to learn more. + Warning: large bulk downloads may lead to sources becoming slower and/or blocking Tachiyomi. Tap to learn more. + %1$d update(s) failed + %1$d update(s) skipped + Skipped because series is complete + Skipped because there are unread chapters + Skipped because no chapters are read + Skipped because series does not require updates + Errors + Skipped + + + Library update frequency + Skip updating titles + With unread chapter(s) + With \"Completed\" status + That haven\'t been started + Only update series if there is no unread chapter (completely read) + Device restrictions + Update only when the conditions are met + Restrictions: %1$s + Sort by ignoring articles + When sorting alphabetically, sort ignoring + articles (a, an, the) at the start of a series\' title + Categories to include in global update + Include in global update + Automatically refresh covers + Refresh covers in library as well + when updating library + Global updates + Buttons at bottom of reader + Certain buttons can be found in other places if disabled here + Search suggestions + Search tips will show up periodically. Long press the suggestion to search it. + Recents + Updates & history + Updates + Newly added + History + Reset chapter history + Recent updates Updates + This will remove the read date of + \"%1$s\". Are you sure? + Reset all chapters for this %1$s + Last read %1$s + Read %1$s + Updated %1$s + Added %1$s + Fetched %1$s + Library last updated: %s + View history + View all updates + Show more chapters + Collapse grouped chapters + Search recents… + No recently read or updated series + No recent chapters + No recently read series + Grouped + Reset chapter? + Press and hold can also reset chapter history + Show download button + History deleted + Are you sure? All history will be lost. - - See your recently updated library entries - Widget not available when app lock is enabled + + Show reset history button + Show read chapters in Grouped and All + Show title first + A while ago + Show updated time + Sort by fetched time + Group chapters together + By series + By week + By day + Uniform covers + Affects library grid covers + Only unread + Only downloaded + Unread or downloaded + Clear history + Show download queue + Open last read chapter + Long tap Recents behaviour + + + Search filters + No more results + No results found + Local source + Other + Global search… + Global search + Latest + Popular + Browse + In Library + Search extensions… + All sources + Sources + Source hidden + Last used + Local source guide + Check website in WebView + Open extensions / migration menu + Open global search + Long tap Browse behaviour + + + + + Extensions + Extension updates + Extension updates pending + Extension info + Filter Languages + Obsolete + Pending + Installing + Installed + Trust + Untrusted + Uninstall + Shizuku is not running + Install and start Shizuku to use Shizuku as extension installer. + Installer + Shizuku + Private + Default + Legacy + Allows extensions to be installed without user prompts and enables automatic updates for devices under Android 12 + Untrusted extension + Malicious extensions can read any stored login credentials or execute arbitrary code.\n\nBy trusting this extension you accept these risks. + This extension is no longer available. + This extension is not from the official Tachiyomi extensions list. + Version: %1$s + Language: %1$s + 18+ + Installed %1$s + Unofficial + MIUI Optimization must be disabled to install extensions. + May contain NSFW (18+) content + App info + %1$s must be enabled first + Could not install extension + Update all + Some extensions may still prompt to be installed first. + Updating extensions + Extensions updated + Revoke all trusted extensions + Revoke all trusted extensions? + + + Set as cover + Reader settings + Set as default for all + Cover updated + Page %1$d + Pages %1$s + Next chapter not found + The image couldn\'t be loaded + Use this image as cover art? + Reading mode + Changing this will reset the reading mode for this series + Finished: + Current: + Next: + Previous: + There\'s no next chapter + There\'s no previous chapter + Loading pages… + Failed to load pages: %1$s + Reading %1$s + Long strip + Next page + Previous page + Next chapter + Previous chapter + + Set first page as cover + Share first page + Save first page + + Set second page as cover + Share second page + Save second page + + Share combined pages + Save combined pages + + + Fullscreen + Animate page transitions + Enable zoom out + Double tap animation speed + Show page number + 32-bit color + Page preload amount + The amount of pages to preload when reading. Higher values will result in a smoother reading experience, at the cost of higher cache and network usage. + Reduces banding, but may impact + performance + Invert double pages + Zoom into double page spreads + Navigate to pan + Split double pages in portrait + Crop borders + Crop borders (Paged) + Crop borders (Long strip) + Remove crop + Use custom brightness + Grayscale + Inverted + Use custom color filter + Color filter blend mode + Overlay + Multiply + Screen + Dodge / Lighten + Burn / Darken + Keep screen on + Skip chapters marked read + Skip filtered chapters + Skip duplicate chapters + Navigation + Volume keys + Invert volume keys + Background color + White + Gray + Black + Smart (by page) + Smart (by theme) + Default reading mode + Left to right + Right to left + Vertical + Continuous vertical + Paged + Scale type + Tap zones + Fit screen + Stretch + Fit width + Fit height + Original size + Smart fit + Zoom start position + Split double pages + Double pages + Single page + Switch to double pages + Switch to single page + Portrait + Landscape + Locked portrait + Locked landscape + R + G + B + A + Smart (based on page) + Smart (based on page and theme) + Always show chapter transition + If disabled, the transition page will be + skipped if the next chapter is loaded + Side padding + None + 5% + 10% + 15% + 20% + 25% + L shaped + Kindle-ish + Edge + Right and Left + Invert tap zones + None + Horizontally + Vertically + Both Axes + Cutout area behavior + Pad cutout areas + Start past cutout + Cutout area behavior only applies in portrait mode with certain scale types + Open legacy cutout settings + On devices older than Android 9.0, there\'s no way to modify cutout setting other than setting it manually through to your system settings + Show content in cutout area + Ignore cutout areas + Page layout + While using automatic page layout, you can still switch between layouts while reading without overriding this setting + Automatic (based on orientation) + Actions + Show on long press + Save pages in separate folders + Creates folders according to manga title + Sensitivity for hiding menu on scroll + Highest + High + Low + Lowest + Custom display profile + + + About this %1$s + Start reading + Start reading Chapter %1$s + Continue reading Chapter %1$s + Continue reading + Chapters %1$s + Volume %1$d + Season %1$d + Added to library + Add to Library + Removed from library + Show %1$s + This entry\'s details page must be viewed before being able to migrate + You have an entry in your library with the same name but from a different source (%1$s).\n\nDo you still wish to continue? + %1$s copied to clipboard + Source not installed: %1$s + No description + Mark all chapters as read? + Mark all chapters as unread? + Remove from library + Select starting chapter + Select ending chapter + Search chapters + Custom range + All chapters + All unread chapters + All read chapters + All but bookmarked chapters + Add %1$s to library? + Show All + Show bookmarked chapters + Show downloaded chapters + Show unread chapters + Show read chapters + Hide chapter titles + Sort by source\'s order + Sort by chapter number + Newest to oldest + Oldest to newest + Add tag + Clear tags + Reset tags + Reset cover + Failed to update cover + Series must be in your library to edit + Remember this choice + Source not installed + Cover saved + Share cover + Error saving cover + Error sharing cover + App settings + Source settings + Custom series info + All read series + Set as default + Filter scanlator groups - + + Tracking + Tracked + Not tracked + Services + One-way sync to update the chapter progress in tracking services. Set up tracking for individual entries from their tracking button. + Enhanced services + Services that provide enhanced features for specific sources. Entries are automatically tracked when added to your library. + Update tracking after reading + Update tracking when marked as read + Reading + Currently Reading + Dropped + On hold + Plan to read + Want to Read + Paused + Rereading + Reading List + Wish List + Complete List + On Hold List + Unfinished List + Score + Status + Started + Type + Refresh tracking + Add tracking + Select an entry + Source is not supported + No match found + Remove tracking from app + Tracker cannot be removed from %1$s while offline + Also remove from %1$s + Remove previous tracker? + Remove %1$s from %2$s and add %3$s + Keep both on %1$s and only replace locally + AniList + MyAnimeList + Kitsu + Bangumi + Shikimori + MangaUpdates + Komga + Kavita + Suwayomi + Update %1$s\'s scoring type + Scoring type updated + Could not update scoring type: %1$s + Started reading date + Finished reading date + Please log in to MAL again + Use suggested date + Failed to update %1$s + + + Select sources + Source migration + Migration + Skip pre-migration + Select a source, then select an item to + migrate + Data to include in migration + Search parameter (e.g. language:english) + Include extra search parameter when searching + Use source with the most chapters (slower) + Use first source with alternative + Skip this step next time + To show this screen again, go to Settings -> + Sources. + Latest: %1$s + migrating to + Don\'t migrate + Search manually + Migrate now + Copy now + Migrate + Migrate %1$s + Copy + No chapters found, this series cannot be used for + migration + No Alternatives Found + Stop migrating? + (skipping %1$d) + + + Settings + General + Reader + Appearance + Advanced + About + Help + Search settings + + Turn on %s + Turn off %s + Incognito mode + Pauses reading history + + + App theme + Light theme + Dark theme + Dark + AMOLED Black + Classic Blue + Midnight Dusk + Spring Blossom + Strawberry Daiquiri + A Brighter You (Dynamic) + A Calmer You (Dynamic) + Yotsuba + Tako + Yin + Yang + Chocolate Strawberries + Teal Ocean + Sapphire Dusk + Lavender + Violet + Hot Pink + Lime Time + Flat Lime + Pure White + Doki + Locale + Last used (Library or Recents) + System default + Date format + Check for updates + App updates + Updated to v%1$s + Secure screen + Secure screen hides app contents when switching apps and block screenshots + Auto-hide bottom navigation + Side navigation icon alignment + Use side navigation + Default behavior + By default, side navigation is used for certain phones and small tablets when in landscape, and always shows on larger tablets + Follow system theme + Pure black dark mode + Details page + Theme buttons based on cover + Expanded toolbar + Show a larger, expanded toolbar at the top of most pages (does not show on smaller devices regardless of setting) + Hides when scrolling + Hide notification content + Security + Starting screen + Back to start + Manage notifications + Pressing back to starting screen + Auto-updates + Auto-update app + Over Wi-Fi only + Over any network + Don\'t auto-update + Some languages may require an app relaunch to display correctly + + App shortcuts + Show recently used sources + Show recent series + Includes recently read, updated, and added series + Series shortcuts opens new chapters + When there\'s no new chapters, the series\' details will open instead + + + Data and storage + Storage location + Storage usage + Available: %1$s / Total: %2$s + + + Backup + Backup and restore + Create backup + Can be used to restore current library + Restore backup + Restore library from backup file + Restore already in progress + Backup already in progress + Backup location + Automatic backups + Backup frequency + Max automatic backups + Invalid backup file + Invalid backup file type: %1$s\nIt should end with ".proto.gz" or ".json". + Backup does not contain any entries. + Backup failed + No library entries to back up + Backup created + Restore completed + Failed to restore backup + Missing sources: + Trackers not logged into: + Data from the backup file will be restored.\n\nYou will need to install any missing extensions and log in to tracking services afterwards to use them. + Canceled restore + Error: empty URI + Creating backup + Automatic backups are highly recommended. You should keep copies in other places as well. + What do you want to backup? + Restoring backup + %02d min, %02d sec + Backup/restore may not function properly if MIUI Optimization is disabled. + Progress + Complete + Not logged into %1$s + Include sensitive settings (e.g. tracker login tokens) + Last automatically backed up: %s + + + Clear chapter cache + Refresh the download cache + This will force the download cache to recalculate. Useful if you modified downloads outside of this app and want the app to pick them up + + Data Management + Check for beta releases + Try new features before they\'re officially released. Beta releases may be unstable and are provided to give feedback to the developer. + Rolling back to the previous production version may cause issues and could require clearing app data. + Beta releases may be unstable and could require clearing app data. + Crash logs + Dump crash logs + Saves error logs to a file for sharing with the developers + Some manufacturers have additional app restrictions that kill background services. This website has more info on how to fix it. + Crash logs saved + Network + DNS over HTTPS + Default user agent string + Invalid user agent string + Disabled + Cloudflare + Google + AdGuard + Quad9 + AliDNS + DNSPod + 360 + Quad 101 + Requires app restart to take effect + Used: %1$s + Error occurred while clearing + Clear cookies + Cookies cleared + Clear WebView data + WebView data cleared + Clear database + %1$d non-library entries in database + Delete history for entries that are not saved in your library + Are you sure? Read chapters and progress of non-library entries will be lost + Keep entries with read chapters + Entries deleted + Database clean + Refresh library metadata + Updates covers, genres, description and entries status information + Refresh tracking metadata + Updates status, score and last chapter read from the tracking services + Clean up downloaded chapters + Delete non-existent, partially downloaded, + and read chapter folders + Clean orphaned + Clean read + Clean entries not in library + Starting cleanup + No folders to cleanup + Disable battery optimization + Disable this if you are experiencing issues + with updating or restoring your library + Battery optimization is already disabled + Clean up cached covers + Delete old and unused cached covers of + entries in your library that has been updated.\nCurrently using: %1$s + Clear cached covers not in library + Delete all covers cached that are + not in your library \nCurrently using: %1$s + Most entries + Select uninstalled sources + Debug info + Background activity + + + Global search + Check for extension updates + Auto-update extensions + Notify extension has been updated + Some extensions may not be auto-updated if they were installed outside this app + Only search pinned sources + Hide entries already in library + Match pinned sources + Match enabled sources + Only enable your pinned sources for + migration + Only enable your currently enabled sources for + migration + Use last saved pre-migration preferences + and sources to mass migrate + Migration sources changed + You can also migrate by selecting entries in your + library + Source migration guide + NSFW (18+) sources + Show in sources and extensions lists + This does not prevent unofficial or potentially incorrectly flagged extensions from surfacing NSFW (18+) content within the app. + + + Extension Repos + Add new repo + Add repo + Invalid repo url + Repo already exists! + You haven\'t added any repos yet. + Delete repo? + Are you sure you wish to delete the repo \"%s\"? + Replace + Signing Key Fingerprint Already Exists + Repository %1$s has the same Signing Key Fingerprint as %2$s.\nIf this is expected, %2$s will be replaced, otherwise contact your repo maintainer. + + + Version + Build time + Send crash reports + Helps fix any bugs. No sensitive data will be sent + What\'s new + FAQ and Guides + What\'s new in this release + Help translate + Helpful translation links + Website + Open source licenses + Open source repo + Unable to open url + + + Log in to %1$s + Username + Email address + Password + Log in + Log out + Log out from %1$s? + + Successfully logged in + Username or password cannot be blank + + You are now logged out + + + Downloads + Download queue + Downloading: %1$s + Cancel all + Move series to top + Move series to bottom + Downloads can be cancelled by swiping them away\nSwipe this tip to dismiss it + Cancel all for this series + Downloaded + Not downloaded + Downloading + Download + Start downloading now + Remove download + Remove downloads + Downloading (%1$d/%2$d) + Invalid download location + Download paused + Nothing is currently downloading + Download complete + Download error + Manage what\'s downloading + Visit the recents tab to access the download + queue. You can also double tap or press and hold for quicker access + Couldn\'t download chapters due to low disk space + Page %d not found while splitting + Couldn\'t split downloaded image + Auto-append ID + May fix issue with downloaded chapters conflicts with one another when they have the same name + + + Could not download chapter due to unexpected error + No Wi-Fi connection available + No network connection available + + + Download location + Only download over Wi-Fi + Remove when marked as read + Allow deleting bookmarked chapters + Remove after read + Excluded categories + Custom location + Last read chapter + Second to last chapter + Third to last chapter + Fourth to last chapter + Fifth to last chapter + Download ahead + Auto download while reading + Only works on entries in library and if the current chapter plus the next one are already downloaded + Download new chapters + Categories to include in download + Delete removed chapters + Delete downloaded chapters if the source + has removed the chapter online + Delete during global updates, ask on chapters page + Always keep + Always delete + Automatic removal + Save as CBZ archive + Split tall images + Improves reader performance + + + Stat + Stats + Statistics + Statistics details + Titles in library + Read chapters + Mean tracking score + Tracked titles + Downloaded chapters + Tags + Local titles + Titles in global update + Trackers + Read duration + Time spent in the reader, based on chapter history + Status distribution + Score distribution + View detailed statistics + Count + Not rated + Source + Tracker + Length + Start year + No data found for your current filters + + + Manual + Every 6 hours + Every 12 hours + Daily + Every 2 days + Every 3 days + Weekly + + + Select cover image + Select backup file + No file picker app found + Failed to acquire persistent folder access. The app may behave unexpectedly. + + Failed to bypass Cloudflare - Please update the WebView app for better compatibility + WebView is required for Tachiyomi + + + See your recently updated library entries + Widget not available when app lock is enabled + + + Add + Apply + Add to %1$s + Added to %1$s + All + Alphabetically + Always + Always ask + Ascending + Automatic + Back + BETA + Bottom + Cancel + Center + Change + Charging + Battery not low + Clear + Clear filters + Close + Common + Cover of series + Create + Date + Descending + Default + Delete + Deleted: %1$s + Display + Download unread + Drag handle + Edit + Enable + Enabled + Exclude: %s + Fast + Filter + Forward + Free + Hide + Ignore + Include: %s + Install + Keep + Keep in %1$s + Learn why + Left + Less + Loading… + Lock + Mark all as read + Mark all as unread + Mark as read + Mark as unread + Mark a range of chapters as read + Mark a range of chapters as unread + Mark previous chapters as read + Mark previous chapters as unread + menu + More + Move to bottom + Move to top + Move to %1$s + Moved to %1$s + Name + Recently updated + Recently installed + Language + Never + Just now + Newest + Next + No animation + Normal + Oldest + Open + Open in app + Open in browser + Open log + Open in WebView + Options + Pause + Picture saved + Pin + Pinned + Preview + Previous + Remove + Remove from %1$s + Reorder + Reset + Restore + Resume + Retry + Right + Rotation + Default orientation + Orientation + Save + Search + Search %1$s + Select all + Select none + Select inverse + Selection + Share + Sort + Sort & Filter + Start + Stop + Tag + Tap to see details + Tap to learn more + Top + Undo + Unknown error + Unpin + Use default + View all + View chapters + Warning + Wi-Fi + Webtoon + Internal error: %s + SFW + NSFW + Content type + + + An Unexpected Error Occurred + %s ran into an unexpected error. We suggest you screenshot this message, dump the crash logs, and then share it to a GitHub Issue. + Restart the application + + Refresh diff --git a/i18n/src/commonMain/moko-resources/bg/plurals.xml b/i18n/src/commonMain/moko-resources/bg/plurals.xml new file mode 100644 index 0000000000..92490a53d9 --- /dev/null +++ b/i18n/src/commonMain/moko-resources/bg/plurals.xml @@ -0,0 +1,107 @@ + + + + 1 наличен ъпдейт за разширение + %d налични ъпдейта за разширения + + + + Направено за %1$s с %2$s грешка + Направено за %1$s с %2$s грешки + + + + %d категория + %d категории + + + + %1$d страница останала + %1$d страници останали + + + + %1$s глава + %1$s глави + + + + Изтри %1$d изтеглената глава\? + Изтри %1$d изтеглените глави\? + + + + Има 1 липсваща глава, източникът липса или е филтриран + Има %d липсващи глави, източникът липса или е филтриран + + + + Копирайте %1$d%2$s манга\? + Копирайте %1$d%2$sманги\? + + + + Разширението е актуализирано + %d разширения са актуализирани + + + + %d преместена манга + %d преместени манги + + + + Миграция на %1$d%2$s манга\? + Миграция на %1$d%2$s манги\? + + + + За %d заглавие + За %d заглавия + + + + %d чакаща актуализация + %d чакаща актуализации + + + + %1$d страница + %1$d страници + + + + и %1$d повече глава + и %1$d повече глави + + + + Една глава е премахната от източника: + \n%2$s + \nИзтриване на изтеглянето ѝ\? + %1$s Няколко глави са премахнати от източника: + \n%2$s + \n + \nИзтриване на изтеглянето им\? + + + + Почистването е завършено. Премахната е папката %d + Почистването е завършено. Премахнати са папките %d + + + + След %1$s минута + След %1$s минути + + + + Кешът е изчистен. %d файлът е изтрит + Кешът е изчистен. %d файловете са изтрити + + + + Следващата непрочетена глава + Следващите %d непрочетени глави + + diff --git a/app/src/main/res/values-bg/strings.xml b/i18n/src/commonMain/moko-resources/bg/strings.xml similarity index 94% rename from app/src/main/res/values-bg/strings.xml rename to i18n/src/commonMain/moko-resources/bg/strings.xml index ba6e6454b4..e656aeb267 100644 --- a/app/src/main/res/values-bg/strings.xml +++ b/i18n/src/commonMain/moko-resources/bg/strings.xml @@ -308,10 +308,6 @@ Виж уебсайта в WebView Остарял Това разширение вече не е достъпно. - - 1 наличен ъпдейт за разширение - %d налични ъпдейта за разширения - Намалява бандинга, но се отразява на производителността Пропускай филтрирани глави Безкраен вертикален изглед @@ -380,15 +376,7 @@ Не сте влезли като потребител в: Отменено възстановяване %02d мин, %02d сек - - Направено за %1$s с %2$s грешка - Направено за %1$s с %2$s грешки - Отвори лога - - %d категория - %d категории - Резервно копие и възстановяване Прогрес Готово @@ -400,18 +388,6 @@ %1$s вече е на опашка Добавяне на %1$s за актуализация на опашката Категория - - %1$d страница останала - %1$d страници останали - - - %1$s глава - %1$s глави - - - Изтри %1$d изтеглената глава\? - Изтри %1$d изтеглените глави\? - Главата не е намерена Глава премахната. Премахната отметка @@ -442,14 +418,10 @@ Грешка при запазването на корицата Източникът не се поддържа Премахни всичко от тази серия - - Има 1 липсваща глава, източникът липса или е филтриран - Има %d липсващи глави, източникът липса или е филтриран - L-образно Kindle-подобно Невалиден тип на файла: %1$s -\nТрябва да завършва на .proto.gz или .json. + \nТрябва да завършва на .proto.gz или .json. Изисква рестартиране, за да влезе в сила Някои производители ограничават приложенията, за да убият задноплановите услуги. Следният уебсайт съдържа информация за разрешаването на проблема. Грешка при споделянето на корицата @@ -493,8 +465,8 @@ Подравняване на страничната навигационна икона Скривай съдържанието на уведомленията Ще бъдат възстановени данните от резервното копие. -\n -\nТрябва да инсталирате липсващи разширения, ако има такива, и да се впишете в услугите за тракинг, за да ги ползвате. + \n + \nТрябва да инсталирате липсващи разширения, ако има такива, и да се впишете в услугите за тракинг, за да ги ползвате. Разтовари записите от сривовете Запазва записи от сривове, които може да бъдат споделени с разработчиците DNS пред HTTPS @@ -574,8 +546,8 @@ Необходими са разрешения за файлове Изтрита категория TachiyomiJ2K изисква достъп до всички файлове в Android 11, за да изтегля глави, да създава автоматични резервни копия и да чете локална манга. -\n -\nНа следващия екран разрешете \"Разрешаване на достъп за управление на всички файлове.\" + \n + \nНа следващия екран разрешете \"Разрешаване на достъп за управление на всички файлове.\" Добавете категории Няма намерени съвпадения за текущите ви филтри Покажи всички категории @@ -599,10 +571,6 @@ Задайте втората страница като корица При използване на автоматична подредба на страницата можете да превключвате между подредбите по време на четене, без да променяте тази настройка Количеството страници, които да се зареждат предварително при четене. По-високите стойности ще доведат до по-плавно четене за сметка на по-голямо използване на кеша и мрежата. - - Копирайте %1$d%2$s манга\? - Копирайте %1$d%2$sманги\? - Шоколадови ягоди По-спокойно ти (Dynamic) Янг @@ -623,10 +591,6 @@ Не може да се инсталира разширение Актуализиране на разширенията Разширенията са актуализирани - - Разширението е актуализирано - %d разширения са актуализирани - Задаване като по подразбиране за всички Споделяне на втора страница Запазване на втора страница @@ -692,16 +656,8 @@ Мигрирай %1$s Няма намерени глави, тази манга не може да се използва за миграция (пропускане на %1$d) - - %d преместена манга - %d преместени манги - Не са намерени алтернативи Спрете мигрирането\? - - Миграция на %1$d%2$s манга\? - Миграция на %1$d%2$s манги\? - Включване на %s Изключване на %s Класическо синьо @@ -761,18 +717,6 @@ Глобални актуализации %1$s първо трябва да се активира Персонализирана информация за манга - - За %d заглавие - За %d заглавия - - - %d чакаща актуализация - %d чакаща актуализации - - - %1$d страница - %1$d страници - Горещо розово Чисто бяло Добавяне/Редактиране на категории @@ -801,25 +745,12 @@ Хоризонтално Вертикално Двете оси - - и %1$d повече глава - и %1$d повече глави - Обновяване на всички Разделяне на двойни страници в портрет Изрязване на граници (страници) Обръщане на двойни страници Премахване на изрязване Интелигентен (по страница) - - Една глава е премахната от източника: -\n%2$s -\nИзтриване на изтеглянето ѝ\? - %1$s Няколко глави са премахнати от източника: -\n%2$s -\n -\nИзтриване на изтеглянето им\? - Не се проследява Светла тема Тъмна тема @@ -841,15 +772,11 @@ Това ще принуди кеша за изтегляне да се преизчисли. Полезно, ако сте променили изтеглянията извън това приложение и искате приложението да ги вземе Стартиране на почистването Няма папки за почистване - - Почистването е завършено. Премахната е папката %d - Почистването е завършено. Премахнати са папките %d - Почистване на кеширани корици Изтрийте старите и неизползвани кеширани корици на манга в библиотеката си, които са били актуализирани. -\nВ момента използвате: %1$s + \nВ момента използвате: %1$s Изтриване на всички корици в кеша, които не са в библиотеката ви -\nВ момента използвани: %1$s + \nВ момента използвани: %1$s Съвпадение на фиксирани източници Съвпадение на разрешени източници Разрешете само текущо разрешените източници за миграция @@ -875,10 +802,6 @@ Разширението за уведомяване е актуализирано Не е изтеглен Винаги пазете - - След %1$s минута - След %1$s минути - На всеки 3 дена Маркирайте всички като прочетени Чистенето е изоставено @@ -888,10 +811,6 @@ Изтрийте премахнатите глави Изтриване на изтеглени глави, ако източникът е премахнал главата онлайн Показване на последните серии - - Кешът е изчистен. %d файлът е изтрит - Кешът е изчистен. %d файловете са изтрити - Ориентация Търсене %1$s Без избиране @@ -972,17 +891,13 @@ Форматът RARv5 не се поддържа Грешка: празен URI Подобрява производителността на четеца - - Следващата непрочетена глава - Следващите %d непрочетени глави - Данните на WebView изчистени Няма заглавия в библиотеката за резервно копие Пропуснати Незапочнати Имате заглавие в библиотеката със същото име, но от различен източник (%1$s). -\n -\nИскате ли да продължите\? + \n + \nИскате ли да продължите\? Списък с желания Списък със завършени Списък със спрени @@ -1006,4 +921,4 @@ Изключени категории Инсталатор Работа на заден план - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/bn/plurals.xml b/i18n/src/commonMain/moko-resources/bn/plurals.xml new file mode 100644 index 0000000000..fd06eb40fb --- /dev/null +++ b/i18n/src/commonMain/moko-resources/bn/plurals.xml @@ -0,0 +1,107 @@ + + + + এক্সটেনশন আপডেট পাওয়া গেছে + %dটি এক্সটেনশন আপডেট পাওয়া গেছে + + + + %d বিভাগ + %d বিভাগসমূহ + + + + %1$d পৃষ্ঠা বাকি + %1$d গুলি পৃষ্ঠা বাকি + + + + %1$s সময়ে %2$s ত্রুটি সম্পন্ন + %1$s সময়ে %2$sটি ত্রুটি সম্পন্ন + + + + %1$dটি ডাউনলোড করা অধ্যায় সরাবেন\? + ডাউনলোড করা %1$dটি অধ্যায় সরাবেন\? + + + + %1$sটি অধ্যায় + %1$s গুলি অধ্যায় + + + + 1 অধ্যায় এড়িয়ে জাছি, হয় উৎসটি অনুপস্থিত বা এটি ফিল্টার করা হয়েছে + %d অধ্যায় কিপ করা হচ্ছে, হয় উৎসটি তাদের অনুপস্থিত অথবা সেগুলি ফিল্টার করা হয়েছে + + + + উৎস থেকে একটি অধ্যায় সরানো হয়েছে: + \n%2$s + \nএর ডাউনলোড মুছে ফেলবেন\? + উৎস থেকে %1$sটি অধ্যায় সরানো হয়েছে: + \n%2$s + \n + \nতাদের ডাউনলোড মুছে ফেলবেন\? + + + + %d টি মাঙ্গা স্থানান্তরিত হয়েছে + %d টা মাঙ্গা স্থানান্তরিত হয়েছে + + + + %1$d%2$s মাঙ্গা কপি করবেন\? + %1$d%2$s টা মাঙ্গা কপি করবেন\? + + + + ক্যাশে সাফ করা হয়েছে। %d ফাইল মুছে ফেলা হয়েছে + ক্যাশে সাফ করা হয়েছে। %d টা ফাইল মুছে ফেলা হয়েছে + + + + পরিষ্কার করা হয়েছে। %d ফোল্ডার সরানো হয়েছে + পরিষ্কার করা হয়েছে। %d টা ফোল্ডার সরানো হয়েছে + + + + %d শিরোনামের জন্য + %d গুল শিরোনামের জন্য + + + + এবং আরো %1$d টি অধ্যায় + এবং আরো %1$d গুল অধ্যায় + + + + %d আপডেট মুলতুবি আছে + %d গুলো আপডেট মুলতুবি আছে + + + + এক্সটেনশন আপডেট করা হয়েছে + %d টি এক্সটেনশন আপডেট করা হয়েছে + + + + %1$dটা পৃষ্ঠা + %1$dটি পৃষ্ঠা + + + + %1$d%2$s মাঙ্গা মাইগ্রেট করবেন\? + %1$d%2$s টা মাঙ্গা মাইগ্রেট করবেন\? + + + + %1$s মিনিট পরে + %1$s টা মিনিট পরে + + + + পরবর্তী অপঠিত অধ্যায় + পরবর্তী %d টি অপঠিত অধ্যায় + + diff --git a/app/src/main/res/values-bn/strings.xml b/i18n/src/commonMain/moko-resources/bn/strings.xml similarity index 94% rename from app/src/main/res/values-bn/strings.xml rename to i18n/src/commonMain/moko-resources/bn/strings.xml index 6942813684..b132c9ec29 100644 --- a/app/src/main/res/values-bn/strings.xml +++ b/i18n/src/commonMain/moko-resources/bn/strings.xml @@ -281,10 +281,6 @@ ওয়েবসাইটটি ওয়েবভিউতে পরীক্ষা করুন অচল এই এক্সটেনশন আর উপলব্ধ নয়। - - এক্সটেনশন আপডেট পাওয়া গেছে - %dটি এক্সটেনশন আপডেট পাওয়া গেছে - ব্যানডিং কমায়, কিন্তু কর্মক্ষমতায় প্রভাভ ফেলে ফিলটারড অধ্যায় গুলো এড়িয়ে যান একটানা উল্লম্ব @@ -331,14 +327,6 @@ বিভাগটি খালি নতুন বিভাগ তৈরি করুন %1$s আগে থেকেই সারিতে আছে - - %d বিভাগ - %d বিভাগসমূহ - - - %1$d পৃষ্ঠা বাকি - %1$d গুলি পৃষ্ঠা বাকি - অধ্যায় পাওয়া যায় নি অধ্যায়গুলো মুছা হলো। বুকমার্ক মুছা হলো @@ -522,10 +510,6 @@ ট্র্যাকারগুলিতে প্রবেশ হয়নি: পুনরুদ্ধার বাতিল করা হয়েছে %02d মিনিট, %02d সেকেন্ড - - %1$s সময়ে %2$s ত্রুটি সম্পন্ন - %1$s সময়ে %2$sটি ত্রুটি সম্পন্ন - লগ খুলুন ব্যাকআপ এবং পুনঃস্থাপন অগ্রগতি @@ -592,10 +576,6 @@ বিভাগ যোগ করুন/সম্পাদনা করুন %1$s কে এতে সরান… এতে %1$s যোগ করুন… - - %1$dটি ডাউনলোড করা অধ্যায় সরাবেন\? - ডাউনলোড করা %1$dটি অধ্যায় সরাবেন\? - ফাইল অনুমতি প্রয়োজন TachiyomiJ2K-এর জন্য অধ্যায়গুলি ডাউনলোড করতে, স্বয়ংক্রিয় ব্যাকআপ তৈরি করতে এবং স্থানীয় মাঙ্গা পড়তে Android 11-এর সমস্ত ফাইল অ্যাক্সেস করতে হবে। \n @@ -607,10 +587,6 @@ আপনার ফিল্টার জন্য কোন মিল আপডেট ইনস্টল করা যায়নি উত্স, স্থিতি, ইত্যাদি দ্বারা লাইব্রেরি গ্রুপ করার সময়। - - %1$sটি অধ্যায় - %1$s গুলি অধ্যায় - শুরু হওয়ার গাইড স্ক্যানলেটর ফিল্টার করার সময় খালি বিভাগ দেখাও @@ -619,10 +595,6 @@ আপনার লাইব্রেরি ক্যাটাগরি হপার লং-প্রেস অ্যাকশন এটি পরিবর্তন করলে এই সিরিজের রিডিং মোড রিসেট হবে - - 1 অধ্যায় এড়িয়ে জাছি, হয় উৎসটি অনুপস্থিত বা এটি ফিল্টার করা হয়েছে - %d অধ্যায় কিপ করা হচ্ছে, হয় উৎসটি তাদের অনুপস্থিত অথবা সেগুলি ফিল্টার করা হয়েছে - ব্যাকআপ ইতিমধ্যেই চলছে অনুবাদে সাহায্য করুন লাইব্রেরি ফিল্টার প্রসারিত করেও পাওয়া যাবে @@ -700,34 +672,13 @@ ট্যাগ যোগ কর স্ক্যানলেটরের গ্রুপ ফিল্টার কর একটি এন্ট্রি নির্বাচন কর - - উৎস থেকে একটি অধ্যায় সরানো হয়েছে: -\n%2$s -\nএর ডাউনলোড মুছে ফেলবেন\? - উৎস থেকে %1$sটি অধ্যায় সরানো হয়েছে: -\n%2$s -\n -\nতাদের ডাউনলোড মুছে ফেলবেন\? - আগের ট্র্যাকার সরাবেন\? - - %d টি মাঙ্গা স্থানান্তরিত হয়েছে - %d টা মাঙ্গা স্থানান্তরিত হয়েছে - সম্প্রতি পঠিত, আপডেট করা এবং যোগ করা সিরিজ অন্তর্ভুক্ত একটি উত্স নির্বাচন করুন, তারপর স্থানান্তর করতে একটি আইটেম নির্বাচন করুন বিকল্পের সাথে প্রথম উৎস ব্যবহার কর - - %1$d%2$s মাঙ্গা কপি করবেন\? - %1$d%2$s টা মাঙ্গা কপি করবেন\? - এ কামার ইউ (ডাইন্যামিক) সাম্প্রতিক সিরিজ দেখাও সিরিজ শর্টকাট নতুন অধ্যায় খোলে - - ক্যাশে সাফ করা হয়েছে। %d ফাইল মুছে ফেলা হয়েছে - ক্যাশে সাফ করা হয়েছে। %d টা ফাইল মুছে ফেলা হয়েছে - আপনার লাইব্রেরিতে মাঙ্গার পুরানো এবং অব্যবহৃত ক্যাশে করা কভারগুলি মুছুন যা আপডেট করা হয়েছে। \nবর্তমানে ব্যবহার করছে: %1$s ডিফল্ট আচরণ @@ -735,10 +686,6 @@ ডাউনলোড করা অধ্যায়গুলি পরিষ্কার কর পরিচ্ছন্ন অরফান পরিচ্ছন্ন পঠিত - - পরিষ্কার করা হয়েছে। %d ফোল্ডার সরানো হয়েছে - পরিষ্কার করা হয়েছে। %d টা ফোল্ডার সরানো হয়েছে - আপনার লাইব্রেরিতে না থাকা ক্যাশে থাকা সমস্ত কভার মুছুন \nবর্তমানে ব্যবহার করছে: %1$s ওরিয়েন্টেশন @@ -750,27 +697,11 @@ লাইব্রেরি গ্রুপ কর… কম্ফরতাবেল গ্রিড ইউনিফর্ম গ্রিড কভার - - %d শিরোনামের জন্য - %d গুল শিরোনামের জন্য - - - এবং আরো %1$d টি অধ্যায় - এবং আরো %1$d গুল অধ্যায় - %1$s ইনস্টল করা হয়েছে %1$s কে প্রথমে সক্রিয় করতে হবে এক্সটেনশন ইনস্টল করা যায়নি এক্সটেনশন আপডেট করা হচ্ছে - - %d আপডেট মুলতুবি আছে - %d গুলো আপডেট মুলতুবি আছে - এক্সটেনশন আপডেট করা হয়েছে - - এক্সটেনশন আপডেট করা হয়েছে - %d টি এক্সটেনশন আপডেট করা হয়েছে - পৃষ্ঠা %1$s কভার হিসাবে প্রথম পৃষ্ঠা সেট করুন প্রথম পাতা শেয়ার কর @@ -799,10 +730,6 @@ কাটআউট এলাকার আচরণ শুধুমাত্র নির্দিষ্ট স্কেলের প্রকারের সাথে প্রতিকৃতি মোডে প্রযোজ্য স্বয়ংক্রিয় পৃষ্ঠা বিন্যাস ব্যবহার করার সময়, আপনি এখনও এই সেটিং ওভাররাইড না করে পড়ার সময় লেআউটগুলির মধ্যে স্যুইচ করতে পারেন দীর্ঘ প্রেসে দেখও - - %1$dটা পৃষ্ঠা - %1$dটি পৃষ্ঠা - সমস্ত অধ্যায় অপঠিত হিসাবে চিহ্নিত করবেন\? নতুন থেকে পুরাতন পুরাতন থেকে নতুন @@ -816,10 +743,6 @@ অনুসন্ধান করার সময় অতিরিক্ত অনুসন্ধান পরামিতি অন্তর্ভুক্ত কর সর্বাধিক অধ্যায় এর উত্স ব্যবহার কর (ধীরে) ম্যানুয়ালি অনুসন্ধান কর - - %1$d%2$s মাঙ্গা মাইগ্রেট করবেন\? - %1$d%2$s টা মাঙ্গা মাইগ্রেট করবেন\? - বন্ধ কর %s লাইট থিম ডার্ক থিম @@ -860,10 +783,6 @@ লগ ইন ডাউনলোড করা অধ্যায়গুলি মুছো যদি উত্স অনলাইনে অধ্যায়টি সরিয়ে দেয় বিশ্বব্যাপী আপডেটের সময় মুছো , অধ্যায় পৃষ্ঠায় জিজ্ঞাসা কর - - %1$s মিনিট পরে - %1$s টা মিনিট পরে - %1$s এ যোগ করুন %1$s এ যোগ করা হয়েছে ফিল্টার সাফ কর @@ -930,10 +849,6 @@ অ্যাপ পাল্টানোর সময় অ্যাপের কন্টেন্ট লুকান ও স্ক্রিনসট ব্লক করুন দৈর্ঘ্য শুরুর বছর - - পরবর্তী অপঠিত অধ্যায় - পরবর্তী %d টি অপঠিত অধ্যায় - পড়ার সময় সয়ংক্রিয়ভাবে ডাউনলোড পরিসংখ্যান পরিসংখ্যান @@ -987,4 +902,4 @@ পুস্তক সংগ্রহ ডিবাগ তথ্য পটভূমি কার্যকলাপ - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/ca/plurals.xml b/i18n/src/commonMain/moko-resources/ca/plurals.xml new file mode 100644 index 0000000000..31ea29be14 --- /dev/null +++ b/i18n/src/commonMain/moko-resources/ca/plurals.xml @@ -0,0 +1,72 @@ + + + + Hi ha una actualització d’una extensió + Hi ha actualitzacions de %d extensions + + + + Voleu eliminar %1$d capítol baixat\? + Voleu eliminar %1$d capítols baixats\? + + + + %d categoria + %d categories + + + + Fet en %1$s amb %2$s error + Fet en %1$s amb %2$s errors + + + + %1$s capítol + %1$s capítols + + + + S’ha omès %d capítol. És possible que manqui a la font o que hagi estat filtrat + S’han omès %d capítols. És possible que manquin a la font o que hagin estat filtrats + + + + Per a %d títol + Per a %d títols + + + + i %1$d capítol més + i %1$d capítols més + + + + El següent capítol no llegit + Els següents %d capítols no llegits + + + + %1$d pàgina + %1$d pàgines + + + + S’ha suprimit un capítol d’aquesta font: + \n%2$s + \nVoleu eliminar-ne la baixada\? + S’han suprimit %1$s capítols d’aquesta font: + \n%2$s + \n + \nVoleu eliminar-ne les baixades\? + + + + %1$d pàgina restant + %1$d pàgines restants + + + + Després d’%1$s minut + Després de %1$s minuts + + diff --git a/app/src/main/res/values-ca/strings.xml b/i18n/src/commonMain/moko-resources/ca/strings.xml similarity index 95% rename from app/src/main/res/values-ca/strings.xml rename to i18n/src/commonMain/moko-resources/ca/strings.xml index b2539ce9c6..70e4ce6afa 100644 --- a/app/src/main/res/values-ca/strings.xml +++ b/i18n/src/commonMain/moko-resources/ca/strings.xml @@ -274,10 +274,6 @@ Comproveu el lloc web en una visualització web Obsoleta Aquesta extensió ja no està disponible. - - Hi ha una actualització d’una extensió - Hi ha actualitzacions de %d extensions - Redueix les bandes de colors, però pot afectar el rendiment Omet els capítols filtrats Continu en vertical @@ -338,10 +334,6 @@ La categoria és buida %1$s ja és a la cua d’actualitzacions S’està afegint %1$s a la cua d’actualitzacions - - Voleu eliminar %1$d capítol baixat\? - Voleu eliminar %1$d capítols baixats\? - No s’ha trobat el capítol S’han eliminat els capítols. S’ha esborrat de marcats @@ -353,14 +345,6 @@ Capítols nous Desbloca Desbloqueu per a accedir a la biblioteca - - %d categoria - %d categories - - - %1$d pàgina restant - %1$d pàgines restants - Crea una categoria nova Inclou a l’actualització global Més opcions de la biblioteca @@ -379,10 +363,6 @@ No s’ha trobat cap capítol S’ha cancel·lat la restauració %02d min i %02d s - - Fet en %1$s amb %2$s error - Fet en %1$s amb %2$s errors - Icones Utilitzada per darrer cop Aquesta extensió no pertany a la llista d’extensions oficials del Tachiyomi. @@ -472,10 +452,6 @@ Categoria Mou %1$s a… Afegeix %1$s a… - - %1$s capítol - %1$s capítols - Calen permisos de fitxers Categoria suprimida Vés a la categoria @@ -498,10 +474,6 @@ És possible que la còpia de seguretat i la restauració no funcionin correctament si l’Optimització del MIUI està desactivada. Alguns fabricants tenen restriccions addicionals per a les aplicacions que finalitzen els serveis en segon pla. Aquest lloc web té més informació de com solucionar-ho. Advertència: Les baixades massa grosses poden fer que les fonts es tornin més lentes i/o bloquin el Tachiyomi. Premeu per a obtenir-ne més informació. - - S’ha omès %d capítol. És possible que manqui a la font o que hagi estat filtrat - S’han omès %d capítols. És possible que manquin a la font o que hagin estat filtrats - No s’ha trobat cap coincidència amb els vostres filtres actuals Ja s’està fent una còpia de seguretat Ajudeu a traduir @@ -517,14 +489,6 @@ Sincronització unidireccional per a actualitzar el progrés dels capítols als serveis de seguiment. Configureu el seguiment d’entrades individuals de manga al seu botó de seguiment. Serveis millorats Serveix que proporcionen funcionalitats millorades per a fonts específiques. El manga se segueix automàticament en afegir-lo a la vostra biblioteca. - - Per a %d títol - Per a %d títols - - - Després d’%1$s minut - Després de %1$s minuts - %d no llegits Només no llegits El format del capítol no és vàlid @@ -567,10 +531,6 @@ Ordena ignorant els articles Actualitza les portades automàticament Premeu la icona de Biblioteca per a mostrar els filtres - - i %1$d capítol més - i %1$d capítols més - Amaga el botó de començar a llegir Arrossega i deixa anar Ordena per @@ -613,10 +573,6 @@ Baixa automàticament mentre es llegeix Baixa per avançat Només funciona en elements de la biblioteca i si el capítol actual i el següent ja estan baixats - - El següent capítol no llegit - Els següents %d capítols no llegits - El TachiyomiJ2K requereix l’accés a tots els fitxers per a poder baixar capítols. Premeu aquí i activeu «Permet l’accés a tots els fitxers». No s’ha pogut instal·lar l’actualització Pàgina del llançament @@ -710,10 +666,6 @@ Comparteix la segona pàgina Desa la segona pàgina Defineix la segona pàgina com a portada - - %1$d pàgina - %1$d pàgines - Voleu afegir %1$s a la biblioteca\? Pàgina única Divideix les pàgines dobles @@ -764,15 +716,6 @@ Temporada %1$d Esborra les etiquetes Restableix la portada - - S’ha suprimit un capítol d’aquesta font: -\n%2$s -\nVoleu eliminar-ne la baixada\? - S’han suprimit %1$s capítols d’aquesta font: -\n%2$s -\n -\nVoleu eliminar-ne les baixades\? - No seguit Actualitza el seguiment després de llegir Actualitzacions globals @@ -792,4 +735,4 @@ Configuració de l’aplicació Informació de depuració Activitat en segon pla - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/ceb/plurals.xml b/i18n/src/commonMain/moko-resources/ceb/plurals.xml new file mode 100644 index 0000000000..2acd85a5e9 --- /dev/null +++ b/i18n/src/commonMain/moko-resources/ceb/plurals.xml @@ -0,0 +1,17 @@ + + + + %d Kategoriya%d Mga kategoriya + + + + + Human sa %1$s ka minutoHuman sa %1$s ka minuto + + + + + Nabuhat sa %1$s nga adunay %2$s nga sayup + Nabuhat sa %1$s nga adunay %2$s nga mga sayop + + diff --git a/app/src/main/res/values-ceb/strings.xml b/i18n/src/commonMain/moko-resources/ceb/strings.xml similarity index 97% rename from app/src/main/res/values-ceb/strings.xml rename to i18n/src/commonMain/moko-resources/ceb/strings.xml index b1e81b5a31..e910d89d3e 100644 --- a/app/src/main/res/values-ceb/strings.xml +++ b/i18n/src/commonMain/moko-resources/ceb/strings.xml @@ -39,10 +39,6 @@ Pagsala Markahi nga gibasa Markahi nga wala pa mabasa - - %d Kategoriya%d Mga kategoriya - - Pilia ang tanan I-lock kung walay trabaho Default nga kategorya @@ -173,10 +169,6 @@ Kada 2 ka adlaw Kada 3 ka adlaw Kada semana - - Human sa %1$s ka minutoHuman sa %1$s ka minuto - - Idugang Kanunay Ubos @@ -241,10 +233,6 @@ Nakompleto ang pag-uli Walay mga entri sa library nga i-back up Gikansela ang pagpasig-uli - - Nabuhat sa %1$s nga adunay %2$s nga sayup - Nabuhat sa %1$s nga adunay %2$s nga mga sayop - Pag-download sa bag-ong mga kapitulo Mode sa pagbasa Padayon nga bertikal @@ -344,4 +332,4 @@ Installer Mga entri sa basahonan Kalihokan sa background - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/cs/plurals.xml b/i18n/src/commonMain/moko-resources/cs/plurals.xml new file mode 100644 index 0000000000..eb9035c525 --- /dev/null +++ b/i18n/src/commonMain/moko-resources/cs/plurals.xml @@ -0,0 +1,154 @@ + + + + Dokončeno za %1$s s %2$s chybou + Dokončeno za %1$s s %2$s chybami + Dokončeno za %1$s s %2$s chybami + + + + %d kategorie + %d kategorie + %d kategorií + + + + Zbývá %1$d stránka + Zbývají %1$d stránky + Zbývá %1$d stránek + + + + %1$s kapitola + %1$s kapitoly + %1$s kapitol + + + + Odstranit %1$d staženou kapitolu\? + Odstranit %1$d stažené kapitoly\? + Odstranit %1$d stažených kapitol\? + + + + a %1$d další kapitolu + a %1$d další kapitoly + a %1$d dalších kapitol + + + + Je dostupná aktualizace rozšíření + Jsou dostupné %d aktualizace rozšíření + Je dostupných %d aktualizací rozšíření + + + + Jedna kapitola byla z tohoto zdroje odstraněna: + \n%2$s + \nChcete ji smazat\? + %1$s kapitoly byly z tohoto zdroje odstraněny: + \n%2$s + \n + \nChcete je smazat\? + %1$s kapitol bylo z tohoto zdroje odstraněno: + \n%2$s + \n + \nChcete je smazat\? + + + + %1$d stránka + %1$d stránky + %1$d stránek + + + + %d aktualizace čeká + %d aktualizace čekají + %d aktualizací čeká + + + + Přeskočena %d kapitola, buď chybí ve zdroji nebo byla vyfiltrována + Přeskočeny %d kapitoly, buď chybí ve zdroji nebo byly vyfiltrovány + Přeskočeno %d kapitol, buď chybí ve zdroji nebo byly vyfiltrovány + + + + Rozšíření bylo aktualizováno + %d rozšíření byla aktualizována + %d rozšíření bylo aktualizováno + + + + Po %1$s minutě + Po %1$s minutách + Po %1$s minutách + + + + Migrovat %1$d%2$s mangu\? + Migrovat %1$d%2$s mangy\? + Migrovat %1$d%2$s mang\? + + + + Vyčištění dokončeno. %d odstraněná složka + Vyčištění dokončeno. %d odstraněné složky + Vyčištění dokončeno. %d odstraněných složek + + + + Další nepřečtená kapitola + Další %d nepřečtené kapitoly + Dalších %d nepřečtených kapitol + + + + Kopírovat %1$d%2$s mangu\? + Kopírovat %1$d%2$s mangy\? + Kopírovat %1$d%2$s mang\? + + + + Mezipaměť vymazána. %d soubor byl odstraněn + Mezipaměť vymazána. %d soubory byly odstraněny + Mezipaměť vymazána. %d souborů bylo odstraněno + + + + %d zdroj + %d zdroje + %d zdrojů + + + + %d druh sérií + %d druhy sérií + %d druhů sérií + + + + Pro %d titul + Pro %d tituly + Pro %d titulů + + + + %d manga migrována + %d manga migrovány + %d manga migrováno + + + + %d jazyk + %d jazyky + %d jazyků + + + + %d status + %d statusy + %d statusů + + diff --git a/app/src/main/res/values-cs/strings.xml b/i18n/src/commonMain/moko-resources/cs/strings.xml similarity index 92% rename from app/src/main/res/values-cs/strings.xml rename to i18n/src/commonMain/moko-resources/cs/strings.xml index e7a3f5c064..60fadafcb3 100644 --- a/app/src/main/res/values-cs/strings.xml +++ b/i18n/src/commonMain/moko-resources/cs/strings.xml @@ -293,11 +293,6 @@ Chybový protokol uložen Pro projevení je nutný restart aplikace Obnova zrušena - - Dokončeno za %1$s s %2$s chybou - Dokončeno za %1$s s %2$s chybami - Dokončeno za %1$s s %2$s chybami - %02d minut, %02d sekund Neplatný typ souboru se zálohou: %1$s \nSoubor by měl končit na .proto.gz nebo .json. @@ -327,11 +322,6 @@ Přejít na kategorii Stiskněte a podržte pro upravení kategorie Kategorie smazána - - %d kategorie - %d kategorie - %d kategorií - Spravovat kategorie Přidat/Upravit kategorie Přidat kategorie @@ -343,21 +333,6 @@ %1$s již je ve frontě Přidávám %1$s do fronty aktualizací Kategorie - - Zbývá %1$d stránka - Zbývají %1$d stránky - Zbývá %1$d stránek - - - %1$s kapitola - %1$s kapitoly - %1$s kapitol - - - Odstranit %1$d staženou kapitolu\? - Odstranit %1$d stažené kapitoly\? - Odstranit %1$d stažených kapitol\? - Kapitola nenalezena Kapitoly odstraněny. Záložka odstraněna @@ -379,16 +354,6 @@ Obnovit přebaly v knihovně i při aktualizaci knihovny Automaticky obnovovat přebaly Při řazení dle abecedy, zahrnovat i ignorované členy (a, an, the) na začátku názvů mang - - a %1$d další kapitolu - a %1$d další kapitoly - a %1$d dalších kapitol - - - Pro %d titul - Pro %d tituly - Pro %d titulů - Další nastavení knihovny Zobrazit jako Klepnutím na ikonu Knihovna zobrazíte filtry @@ -434,11 +399,6 @@ 18+ Neoficiální Může obsahovat obsah pro dospělé (18+) - - Je dostupná aktualizace rozšíření - Jsou dostupné %d aktualizace rozšíření - Je dostupných %d aktualizací rozšíření - Prosím aktualizujte aplikaci WebView pro lepší kompatibilitu Méně Následující stránka @@ -577,19 +537,6 @@ Podle pořadí zdroje Nezaloženo Je vyžadováno oprávnění k souborům - - Jedna kapitola byla z tohoto zdroje odstraněna: -\n%2$s -\nChcete ji smazat\? - %1$s kapitoly byly z tohoto zdroje odstraněny: -\n%2$s -\n -\nChcete je smazat\? - %1$s kapitol bylo z tohoto zdroje odstraněno: -\n%2$s -\n -\nChcete je smazat\? - Nastavit jako výchozí Vlastní info o manze Zdroj není nainstalován @@ -618,18 +565,8 @@ Svazek %1$d Začít číst Kapitolu %1$s Začít číst - - %1$d stránka - %1$d stránky - %1$d stránek - Zobrazit při dlouhém stisknutí Akce - - %d aktualizace čeká - %d aktualizace čekají - %d aktualizací čeká - Aktualizuji rozšíření Některá rozšíření můžou nejdřív žádat o instalaci. Aktualizovat vše @@ -644,11 +581,6 @@ Nepodařilo se nainstalovat aktualizaci Příručka Začínáme Pomozte s překladem - - Přeskočena %d kapitola, buď chybí ve zdroji nebo byla vyfiltrována - Přeskočeny %d kapitoly, buď chybí ve zdroji nebo byly vyfiltrovány - Přeskočeno %d kapitol, buď chybí ve zdroji nebo byly vyfiltrovány - DNS přes HTTPS Zakázáno Zobrazovat v seznamu zdrojů a rozšíření @@ -696,11 +628,6 @@ Uniformní obaly Nainstalováno %1$s Rozšíření aktualizována - - Rozšíření bylo aktualizováno - %d rozšíření byla aktualizována - %d rozšíření bylo aktualizováno - Uložit kombinované strany Invertovat dvojité strany Rozdělit dvojité strany na portrét @@ -713,11 +640,6 @@ Chytře (podle strany) Chytře (podle tématu) Ovlivňuje mřížku obalů v knihovně - - Po %1$s minutě - Po %1$s minutách - Po %1$s minutách - Zveřejnění dokončeno Zrušeno Má pauzu @@ -899,11 +821,6 @@ Chování oblasti výřezu platí pouze v režimu na výšku s určitými typy měřítek Správa dat Zkontrolovat pro nové beta verze - - Vyčištění dokončeno. %d odstraněná složka - Vyčištění dokončeno. %d odstraněné složky - Vyčištění dokončeno. %d odstraněných složek - Automaticky aktualizovat rozšíření Není staženo Kapitoly nelze stáhnout z důvodu nedostatku místa na disku @@ -911,11 +828,6 @@ Vyčištění přečtených Odstranění stažených kapitol, pokud zdroj odstranil tuto kapitolu online Odstranění během globálních aktualizací, dotázat se na stránce kapitol - - Migrovat %1$d%2$s mangu\? - Migrovat %1$d%2$s mangy\? - Migrovat %1$d%2$s mang\? - Nepodařilo se obnovit zálohu Beta verze mohou být nestabilní a mohou vyžadovat vymazání dat aplikace. Návrat k předchozí produkční verzi může způsobit problémy a může vyžadovat vymazání dat aplikace. @@ -935,11 +847,6 @@ Změna Přetáhněte rukojeť Odstraněno: %1$s - - Další nepřečtená kapitola - Další %d nepřečtené kapitoly - Dalších %d nepřečtených kapitol - Přes jakoukoli síť Zástupci aplikace Zálohování již probíhá @@ -950,16 +857,6 @@ Přesunuto do %1$s Nedávno aktualizované Stránka s podrobnostmi o této položce musí být zobrazena před tím, než bude možné migrovat - - Kopírovat %1$d%2$s mangu\? - Kopírovat %1$d%2$s mangy\? - Kopírovat %1$d%2$s mang\? - - - %d manga migrována - %d manga migrovány - %d manga migrováno - Odstraňte neexistující, částečně stažené a přečtené složky kapitol Vyčištění obalů uložených v mezipaměti Vymazání obalů v mezipaměti, které nejsou v knihovně @@ -984,11 +881,6 @@ Výběr Třídit & Filtrovat Ponechte oba na %1$s a vyměňte je pouze lokálně - - Mezipaměť vymazána. %d soubor byl odstraněn - Mezipaměť vymazána. %d soubory byly odstraněny - Mezipaměť vymazána. %d souborů bylo odstraněno - Většina záznamů Orientace Rovnoměrná mřížka obalů @@ -1033,31 +925,11 @@ Zdroj Sledovač Pro aktuální filtry nebyla nalezena žádná data - - %d zdroj - %d zdroje - %d zdrojů - - - %d jazyk - %d jazyky - %d jazyků - Tituly v globální aktualizaci Sledovače Délka Počáteční rok Zobrazit podrobné statistiky - - %d druh sérií - %d druhy sérií - %d druhů sérií - - - %d status - %d statusy - %d statusů - Statistika Statistiky Čas strávený ve čtečce na základě historie kapitol @@ -1089,4 +961,4 @@ Nastavení aplikace Ladící informace Činnost na pozadí - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/cv/plurals.xml b/i18n/src/commonMain/moko-resources/cv/plurals.xml new file mode 100644 index 0000000000..8a2d53ddea --- /dev/null +++ b/i18n/src/commonMain/moko-resources/cv/plurals.xml @@ -0,0 +1,47 @@ + + + + Хушма валли ҫӗнетӳ пур + %d хушма валли ҫӗнетӳ пур + + + + %1$s сыпӑк + %1$s сыпӑк + + + + %d пухмӑш + %d пухмӑш + + + + %1$d эл юлчӗ + %1$d эл юлчӗ + + + + %1$d тиенӗ сыпӑка катертмелле-и\? + %1$d тиенӗ сыпӑксене катертмелле-и\? + + + + %1$s,%2$s йӑнӑшпа тӑвӑннӑ%1$s, %2$s йӑнӑшпа тӑвӑннӑ + + + + + 1 минут хыҫҫӑн%1$s минут хыҫҫӑн + + + + + Ҫӗнӗ сыпӑксем 1 хайлав валли тупӑннӑҪӗнӗ сыпӑксем %d хайлав валли тупӑннӑ + + + + + 1 сыпӑк ҫук + %d сыпӑк ҫук + + diff --git a/app/src/main/res/values-cv/strings.xml b/i18n/src/commonMain/moko-resources/cv/strings.xml similarity index 95% rename from app/src/main/res/values-cv/strings.xml rename to i18n/src/commonMain/moko-resources/cv/strings.xml index 31b5807ed5..e9b4bf29a5 100644 --- a/app/src/main/res/values-cv/strings.xml +++ b/i18n/src/commonMain/moko-resources/cv/strings.xml @@ -66,10 +66,6 @@ Катерт %1$s верссийӗ Чӗлхе: %1$s - - Хушма валли ҫӗнетӳ пур - %d хушма валли ҫӗнетӳ пур - Малалли сыпӑк тупӑнман Ҫак ӳкерчĕке хуплашка пек усӑ курмалла-и\? Малалли @@ -288,10 +284,6 @@ Вулавӑша ҫӗнетни Йаланхилле пухмӑш Пухмӑшсем - - %1$s сыпӑк - %1$s сыпӑк - Ним туман чух ҫаклатни Ҫаклатӑва уҫма пӳрне йӗрӗ ыйтни Вӗҫленӗ @@ -317,18 +309,6 @@ Кумӑкс Киттай манкӑ Карей манкӑ - - %d пухмӑш - %d пухмӑш - - - %1$d эл юлчӗ - %1$d эл юлчӗ - - - %1$d тиенӗ сыпӑка катертмелле-и\? - %1$d тиенӗ сыпӑксене катертмелле-и\? - Сыпӑк тупӑнман Сыпӑксене катертнӗ. Карт катертнӗ @@ -365,10 +345,6 @@ Кӗмен сӑнанусем: Тавӑрнине пӑрахӑҫланӑ %02d минут та %02d ҫеккунт - - %1$s,%2$s йӑнӑшпа тӑвӑннӑ%1$s, %2$s йӑнӑшпа тӑвӑннӑ - - Ҫӑл куҫ куҫарассипе пулӑшу NSFW (18+) шалаш Ҫакӑ хушӑмра официаллӑ мар е тӗрӗс мар палӑртнӑ хушмасен NSFW (18+) шалашне кӑтартма чӑрмантармасть. @@ -456,16 +432,8 @@ Чӑнах катертесшӗн-и\? Веҫ кун-ҫулӗ ҫухалӗ. Систерӳсене ӗнер Тиесе илнӗ сыпӑксем - - 1 минут хыҫҫӑн%1$s минут хыҫҫӑн - - Куҫӑм палли Ҫӑл куҫсен ят-йышӗнче кӑтарт - - Ҫӗнӗ сыпӑксем 1 хайлав валли тупӑннӑҪӗнӗ сыпӑксем %d хайлав валли тупӑннӑ - - Ыкран сыхлавӗ тепӗр апсем ҫине куҫнӑ чух ку апӑн мӗн пуррине пытарать тата ыкрана сӑн ҫапма чарать Йӑнӑшсене кӑтарт Серилӗх вӗҫленнӗ @@ -490,10 +458,6 @@ Вулӑшӑн тухӑҫа лайӑхлатать Shizuku ӗҫлемест Shizuku-н хушма ларткӑча усӑ курма Shizuku ларт тата ҫут. - - 1 сыпӑк ҫук - %d сыпӑк ҫук - Пурне те ҫӗнет Ретре %d Ап ҫинчен @@ -502,4 +466,4 @@ Сӑрӑ Ларткӑч Вулавӑшри серилӗхсем - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/de/plurals.xml b/i18n/src/commonMain/moko-resources/de/plurals.xml new file mode 100644 index 0000000000..460dd138be --- /dev/null +++ b/i18n/src/commonMain/moko-resources/de/plurals.xml @@ -0,0 +1,127 @@ + + + + Entferne %1$d heruntergeladenes Kapitel? + Entferne %1$d heruntergeladene Kapitel? + + + + %1$s Kapitel + %1$s Kapitel + + + + %1$d Seite übrig + %1$d Seiten übrig + + + + %d Kategorie + %d Kategorien + + + + Für %d Titel + Für %d Titel + + + + und %1$d weiteres Kapitel + und %1$d weitere Kapitel + + + + Erweiterungsaktualisierung verfügbar + %d Erweiterungsaktualisierungen verfügbar + + + + Ein Kapitel wurde von der Quelle entfernt: + \n%2$s + \nDiese heruntergeladene Datei löschen\? + %1$s Kapitel wurden von der Quelle entfernt: + \n%2$s + \n + \nDiese heruntergeladenen Dateien löschen\? + + + + %1$d%2$s Manga migrieren? + %1$d%2$s Manga migrieren? + + + + %1$d%2$s Manga kopieren? + %1$d%2$s Manga kopieren? + + + + %d Manga migriert + %d Manga migriert + + + + Zwischenspeicher geleert. %d Datei wurde gelöscht + Zwischenspeicher geleert. %d Dateien wurde gelöscht + + + + Aufräumen abgeschlossen. %d Ordner entfernt + Aufräumen abgeschlossen. %d Ordner entfernt + + + + Nach %1$s Minute + Nach %1$s Minuten + + + + Erledigt in %1$s mit %2$s Fehler + Erledigt in %1$s mit %2$s Fehlern + + + + %1$d Seite + %1$d Seiten + + + + %d Aktualisierung ausstehend + %d Aktualisierungen ausstehend + + + + Erweiterung aktualisiert + %d Erweiterungen aktualisiert + + + + %d Kapitel wird übersprungen, da die Quelle dieses entweder nicht besitzt, oder weil es rausgefiltert wurde + %d Kapitel werden übersprungen, da die Quelle diese entweder nicht besitzt, oder weil sie rausgefiltert wurden + + + + Nächstes ungelesenes Kapitel + Nächste %d ungelesene Kapitel + + + + %d Sprache + %d Sprachen + + + + %d Quelle + %d Quellen + + + + %d Status + %d Status + + + + %d Serientyp + %d Serientypen + + diff --git a/app/src/main/res/values-de/strings.xml b/i18n/src/commonMain/moko-resources/de/strings.xml similarity index 93% rename from app/src/main/res/values-de/strings.xml rename to i18n/src/commonMain/moko-resources/de/strings.xml index 6d2ce0c44a..69d56fed17 100644 --- a/app/src/main/res/values-de/strings.xml +++ b/i18n/src/commonMain/moko-resources/de/strings.xml @@ -39,18 +39,6 @@ Lesezeichen entfernt Kapitel entfernt. Kapitel nicht gefunden - - Entferne %1$d heruntergeladenes Kapitel? - Entferne %1$d heruntergeladene Kapitel? - - - %1$s Kapitel - %1$s Kapitel - - - %1$d Seite übrig - %1$d Seiten übrig - Kategorie Kategorien @@ -66,10 +54,6 @@ Kategorien bearbeiten Kategorie verwalten Zu Kategorien hinzufügen - - %d Kategorie - %d Kategorien - Eine Kategorie mit diesem Namen existiert bereits! Kategorie gelöscht Drücken und halten um Kategorie zu bearbeiten @@ -123,14 +107,6 @@ Weitere Bibliothekseinstellungen Neue Kapitel gefunden - - Für %d Titel - Für %d Titel - - - und %1$d weiteres Kapitel - und %1$d weitere Kapitel - Häufigkeit der Bibliotheksaktualisierung Gerätebeschränkungen @@ -192,10 +168,6 @@ Diese Erweiterung ist nicht länger verfügbar. Version: %1$s Sprache: %1$s - - Erweiterungsaktualisierung verfügbar - %d Erweiterungsaktualisierungen verfügbar - Als Vorschaubild festlegen Als Standard für alle setzen @@ -309,15 +281,6 @@ Zum Bearbeiten muss der Manga in Ihrer Bibliothek sein Diese Auswahl merken Quelle nicht installiert - - Ein Kapitel wurde von der Quelle entfernt: -\n%2$s -\nDiese heruntergeladene Datei löschen\? - %1$s Kapitel wurden von der Quelle entfernt: -\n%2$s -\n -\nDiese heruntergeladenen Dateien löschen\? - Tracking Synchronisiert @@ -364,19 +327,7 @@ Keine Kapitel gefunden. Dieser Manga kann nicht für das Migrieren genutzt werden Keine alternative gefunden Migration stoppen? - - %1$d%2$s Manga migrieren? - %1$d%2$s Manga migrieren? - - - %1$d%2$s Manga kopieren? - %1$d%2$s Manga kopieren? - (überspringe %1$d) - - %d Manga migriert - %d Manga migriert - Einstellungen Allgemein @@ -418,10 +369,6 @@ Netzwerk Erfordert einen Neustart der App, um wirksam zu werden Belegt: %1$s - - Zwischenspeicher geleert. %d Datei wurde gelöscht - Zwischenspeicher geleert. %d Dateien wurde gelöscht - Fehler während dem Leeren aufgetreten Cookies löschen Cookies gelöscht @@ -443,10 +390,6 @@ Optimierung des Akkuverbrauchs beenden Deaktivieren wenn Sie Probleme mit der Aktualisierung oder dem Wiederherstellen der Bibliothek haben Akkuverbrauch-Optimierung ist bereits deaktiviert - - Aufräumen abgeschlossen. %d Ordner entfernt - Aufräumen abgeschlossen. %d Ordner entfernt - Zwischengespeicherte Vorschaubilder aufräumen Alte und ungenutzte zwischengespeicherte Vorschaubilder von Manga in deiner Bibliothek welche aktualisiert wurden löschen.\nAktuell genutzt: %1$s Zwischengespeicherte Vorschaubilder welche nicht in der Bibliothek sind bereinigen @@ -527,10 +470,6 @@ Täglich Alle 2 Tage Wöchentlich - - Nach %1$s Minute - Nach %1$s Minuten - Wähle Vorschaubild Wähle eine Sicherungsdatei @@ -643,10 +582,6 @@ \nDu musst jegliche fehlende Erweiterungen installieren und dich anschließend bei den Tracking-Anbietern einloggen, um sie zu benutzen. Wiederherstellung abgebrochen %02d min, %02d s - - Erledigt in %1$s mit %2$s Fehler - Erledigt in %1$s mit %2$s Fehlern - Quellenmigration NSFW/Ü18-Quellen Dies verhindert nicht, dass inoffizielle oder möglicherweise falsch gekennzeichnete Erweiterungen NSFW/Ü18-Inhalte in der App anzeigen. @@ -742,10 +677,6 @@ Inkognito-Modus %s ausschalten %s einschalten - - %1$d Seite - %1$d Seiten - Automatisch (basierend auf Ausrichtung) Bei Verwendung des automatischen Seitenlayouts kann man beim Lesen immer noch zwischen Layouts wechseln, ohne diese Einstellung zu überschreiben Seitenlayout @@ -827,10 +758,6 @@ Dunkelmodus Hellmodus Keine Übereinstimmung gefunden - - %d Aktualisierung ausstehend - %d Aktualisierungen ausstehend - Erweiterung konnte nicht installiert werden Globale Aktualisierungen Eine beliebige Serie öffnen @@ -877,10 +804,6 @@ Erweiterungen automatisch aktualisieren Doppelseiten aufteilen Doppelseiten im Hochformat aufteilen - - Erweiterung aktualisiert - %d Erweiterungen aktualisiert - Erweiterungen aktualisiert Installiert %1$s Erweiterungsaktualisierungen ausstehend @@ -899,10 +822,6 @@ Standardmäßig wird die Seitennavigation bei bestimmten Mobiltelefonen und kleinen Tablets im Querformat verwendet und bei größeren Tablets immer angezeigt Standardverhalten Seitennavigation verwenden - - %d Kapitel wird übersprungen, da die Quelle dieses entweder nicht besitzt, oder weil es rausgefiltert wurde - %d Kapitel werden übersprungen, da die Quelle diese entweder nicht besitzt, oder weil sie rausgefiltert wurden - Hilfreiche Übersetzungslinks Beim Übersetzen mithelfen Scanlator-Gruppen filtern @@ -992,10 +911,6 @@ Vor der Migration müssen die Details des Eintrags geprüft werden Nach dem Lesen den Tracker aktualisieren Markieren als gelesen aktualisiert den Tracker - - Nächstes ungelesenes Kapitel - Nächste %d ungelesene Kapitel - Funktioniert nur bei Werken in der Bibliothek und wenn das aktuelle Kapitel sowie das darauf folgende bereits heruntergeladen sind Im Voraus herunterladen Benachrichtigungen verwalten @@ -1047,27 +962,11 @@ Detaillierte Statistiken ansehen Anzahl Nicht bewertet - - %d Sprache - %d Sprachen - - - %d Quelle - %d Quellen - - - %d Status - %d Status - Startjahr Lokale Titel Titel im globalen Update Statusverteilung Punkteverteilung - - %d Serientyp - %d Serientypen - Mit Lesen verbrachte Zeit, basiert auf Kapitel-Verlauf Übersprungen, da die Serie keine Aktualisierung benötigt Ungültiger User-Agent-Text @@ -1098,4 +997,4 @@ App-Einstellungen Debug-Info Hintergrundaktivität - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/el/plurals.xml b/i18n/src/commonMain/moko-resources/el/plurals.xml new file mode 100644 index 0000000000..72b3e20cd0 --- /dev/null +++ b/i18n/src/commonMain/moko-resources/el/plurals.xml @@ -0,0 +1,127 @@ + + + + Διαθέσιμη ενημέρωση επέκτασης + %d διαθέσιμες ενημερώσεις επεκτάσεων + + + + και %1$d περισσότερο κεφάλαιο + και %1$d περισσότερα κεφάλαια + + + + Για %d τίτλο + Για %d τίτλους + + + + %d κατηγορία + %d κατηγορίες + + + + Απομένει %1$d σελίδα + Απομένουν %1$d σελίδες + + + + Διαγραφή %1$d κατεβασμένου κεφαλαίου; + Διαγραφή %1$d κατεβασμένων κεφαλαίων; + + + + Έγινε σε %1$s με %2$s σφάλμα + Έγινε σε %1$s με %2$s σφάλματα + + + + Μετά από %1$s λεπτό + Μετά από %1$s λεπτά + + + + Ο καθαρισμός ολοκληρώθηκε. Αφαιρέθηκε %d φάκελος + Ο καθαρισμός ολοκληρώθηκε. Αφαιρέθηκαν %d φάκελοι + + + + Η προσωρινή μνήμη διαγράφηκε. %d αρχείο διαγράφηκε + Η προσωρινή μνήμη διαγράφηκε. %d αρχεία διαγράφηκαν + + + + %d σειρά μετεγκαταστήθηκε + %d σειρές μετεγκαταστήθηκαν + + + + Αντιγραφή %1$d%2$s σειρά; + Αντιγραφή %1$d%2$s σειρών; + + + + Μετεγκατάσταση %1$d%2$s σειρά; + Μετεγκατάσταση %1$d%2$s σειρών; + + + + Ένα κεφάλαιο καταργήθηκε από την πηγή: +\n%2$s +\nΔιαγραφή της λήψης του; + %1$s κεφάλαια καταργήθηκαν από την πηγή: +\n%2$s +\n +\nΔιαγραφή των λήψεων τους; + + + + %1$d σελίδα + %1$d σελίδες + + + + %1$s κεφάλαιο + %1$s κεφάλαια + + + + %d εκκρεμεί ενημέρωση + %d εκκρεμούν ενημερώσεις + + + + Η επέκταση ενημερώθηκε + %d επεκτάσεις ενημερώθηκαν + + + + Παραλείπεται %d κεφάλαιο, είτε λείπει από την πηγή είτε έχει φιλτραριστεί + Παραλείπονται %d κεφάλαια, είτε λείπουν από την πηγή είτε έχουν φιλτραριστεί + + + + Επόμενο αδιάβαστο κεφάλαιο + Επόμενα %d αδιάβαστα κεφάλαια + + + + Τύπος σειράς + %d τύποι σειρών + + + + Πηγή + %d Πηγές + + + + Κατάσταση + %d καταστάσεις + + + + Γλώσσα + %d γλώσσες + + diff --git a/app/src/main/res/values-el/strings.xml b/i18n/src/commonMain/moko-resources/el/strings.xml similarity index 94% rename from app/src/main/res/values-el/strings.xml rename to i18n/src/commonMain/moko-resources/el/strings.xml index b7ab824bb3..2f890850bc 100644 --- a/app/src/main/res/values-el/strings.xml +++ b/i18n/src/commonMain/moko-resources/el/strings.xml @@ -270,10 +270,6 @@ Ελέγξτε τον ιστότοπο στο WebView Απαρχαιωμένο Αυτή η επέκταση δεν είναι πλέον διαθέσιμη. - - Διαθέσιμη ενημέρωση επέκτασης - %d διαθέσιμες ενημερώσεις επεκτάσεων - Μειώνει το banding, αλλά μπορεί να επηρεάσει την απόδοση Μέθοδος μίξης χρωματικού φίλτρου Dodge / Φώτισε @@ -360,14 +356,6 @@ Συμπερίληψη σε καθολική ενημέρωση Κατά την αλφαβητική ταξινόμηση, ταξινομήστε αγνοώντας τα άρθρα (a, an, the) στην αρχή των τίτλων από τις σειρές Ταξινόμηση αγνοώντας άρθρα - - και %1$d περισσότερο κεφάλαιο - και %1$d περισσότερα κεφάλαια - - - Για %d τίτλο - Για %d τίτλους - Περισσότερες ρυθμίσεις βιβλιοθήκης Εμφάνιση ως Πατήστε το εικονίδιο Βιβλιοθήκη για εμφάνιση φίλτρων @@ -403,18 +391,6 @@ Δημιουργία νέας κατηγορίας %1$s είναι ήδη στην ουρά Προσθήκη %1$s στην ουρά ενημέρωσης - - %d κατηγορία - %d κατηγορίες - - - Απομένει %1$d σελίδα - Απομένουν %1$d σελίδες - - - Διαγραφή %1$d κατεβασμένου κεφαλαίου; - Διαγραφή %1$d κατεβασμένων κεφαλαίων; - Το κεφάλαιο δε βρέθηκε Κεφάλαια αφαιρέθηκαν. Καταργήθηκε ο σελιδοδείκτης @@ -469,10 +445,6 @@ \nΘα χρειαστεί να εγκαταστήσετε τυχόν επεκτάσεις που λείπουν και στη συνέχεια να συνδεθείτε στις υπηρεσίες παρακολούθησης για να τις χρησιμοποιήσετε. Η επαναφορά ακυρώθηκε %02d λεπτά, %02d δευτερόλεπτα - - Έγινε σε %1$s με %2$s σφάλμα - Έγινε σε %1$s με %2$s σφάλματα - Οδηγός μετεγκατάστασης πηγής Πηγές NSFW (18+) Αυτό δεν εμποδίζει τις ανεπίσημες ή ενδεχομένως εσφαλμένα επισημασμένες επεκτάσεις να εμφανίζουν περιεχόμενο NSFW (18+) μέσα στην εφαρμογή. @@ -517,10 +489,6 @@ BETA Προστέθηκε στο %1$s Προσθήκη στο %1$s - - Μετά από %1$s λεπτό - Μετά από %1$s λεπτά - Να διαγράφεται πάντα Να διατηρείτε πάντα Διαγραφή κατά τη διάρκεια καθολικών ενημερώσεων, ερώτηση στη σελίδα κεφαλαίων @@ -546,10 +514,6 @@ \nΧρησιμοποιούνται επί του παρόντος: \n%1$s Καθαρισμός προσωρινά αποθηκευμένων εξώφυλλων - - Ο καθαρισμός ολοκληρώθηκε. Αφαιρέθηκε %d φάκελος - Ο καθαρισμός ολοκληρώθηκε. Αφαιρέθηκαν %d φάκελοι - Απενεργοποιήστε το εάν αντιμετωπίζετε προβλήματα με την ενημέρωση ή την επαναφορά της βιβλιοθήκης σας Δεν υπάρχουν φάκελοι για καθαρισμό Έναρξη καθαρισμού @@ -558,10 +522,6 @@ Καθαρισμός ορφανών Διαγραφή μη υπαρκτών, μερικώς κατεβασμένων και διαβασμένων φακέλων κεφαλαίων Καθαρισμός ληφθέντων κεφαλαίων - - Η προσωρινή μνήμη διαγράφηκε. %d αρχείο διαγράφηκε - Η προσωρινή μνήμη διαγράφηκε. %d αρχεία διαγράφηκαν - DNS μέσω HTTPS Διαχείριση δεδομένων Απέτυχε η επαναφορά αντιγράφου ασφαλείας @@ -580,19 +540,7 @@ Λειτουργία ανώνυμης περιήγησης Απενεργοποίηση %s Ενεργοποίηση %s - - %d σειρά μετεγκαταστήθηκε - %d σειρές μετεγκαταστήθηκαν - (παράλειψη %1$d) - - Αντιγραφή %1$d%2$s σειρά; - Αντιγραφή %1$d%2$s σειρών; - - - Μετεγκατάσταση %1$d%2$s σειρά; - Μετεγκατάσταση %1$d%2$s σειρών; - Διακοπή μετεγκατάστασης; Δε βρέθηκαν εναλλακτικές Μετεγκατάσταση %1$s @@ -621,15 +569,6 @@ Κατάργηση επίσης από %1$s Κατάργηση παρακολούθησης από την εφαρμογή Δεν παρακολουθείται - - Ένα κεφάλαιο καταργήθηκε από την πηγή: -\n%2$s -\nΔιαγραφή της λήψης του; - %1$s κεφάλαια καταργήθηκαν από την πηγή: -\n%2$s -\n -\nΔιαγραφή των λήψεων τους; - Προσαρμοσμένες πληροφορίες σειρών Σφάλμα κοινής χρήσης του εξωφύλλου Σφάλμα αποθήκευσης εξωφύλλου @@ -664,10 +603,6 @@ Έναρξη ανάγνωσης κεφαλαίου %1$s Έναρξη ανάγνωσης Σχετικά με αυτό %1$s - - %1$d σελίδα - %1$d σελίδες - Αυτόματη (βάση προσανατολισμού) Διάταξη σελίδας Η συμπεριφορά της περιοχής αποκοπής ισχύει μόνο σε λειτουργία πορτραίτου με ορισμένους τύπους κλίμακας @@ -744,10 +679,6 @@ Προσθήκη/Επεξεργασία κατηγοριών Νέα κατηγορία Κατηγορία - - %1$s κεφάλαιο - %1$s κεφάλαια - Δεν βρέθηκαν σελίδες Προσθήκη %1$s σε… Μετακίνηση %1$s σε… @@ -801,10 +732,6 @@ Σκοτεινό θέμα Φωτεινό θέμα Ορισμός ως προεπιλογή - - %d εκκρεμεί ενημέρωση - %d εκκρεμούν ενημερώσεις - Δεν ήταν δυνατή η εγκατάσταση της επέκτασης Η βελτιστοποίηση MIUI πρέπει να απενεργοποιηθεί για την εγκατάσταση επεκτάσεων. Παγκόσμιες ενημερώσεις @@ -836,10 +763,6 @@ Δεν ήταν δυνατή η εγκατάσταση της ενημέρωσης Ορισμένοι κατασκευαστές έχουν πρόσθετους περιορισμούς εφαρμογών που εξουδετερώνουν τις υπηρεσίες παρασκηνίου. Αυτός ο ιστότοπος έχει περισσότερες πληροφορίες για το πώς να το διορθώσετε. Ειδοποίησή ενημέρωσής επέκτασης - - Η επέκταση ενημερώθηκε - %d επεκτάσεις ενημερώθηκαν - Εγκαταστάθηκε %1$s Εκκρεμούν ενημερώσεις επέκτασης Πρόσφατα εγκατεστημένο @@ -865,10 +788,6 @@ Δεν υπάρχουν αντιστοιχίσεις για τα φίλτρα σας Εμφάνιση κενών κατηγοριών κατά το φιλτράρισμα Οδηγός για τα πρώτα βήματα - - Παραλείπεται %d κεφάλαιο, είτε λείπει από την πηγή είτε έχει φιλτραριστεί - Παραλείπονται %d κεφάλαια, είτε λείπουν από την πηγή είτε έχουν φιλτραριστεί - Χρήσιμοι σύνδεσμοι μετάφρασης Βοηθήστε στη μετάφραση Φιλτράρισμα ομάδων scanlator @@ -961,10 +880,6 @@ Η μπαταρία δεν είναι χαμηλή Διαχείριση ειδοποιήσεων Συχνές ερωτήσεις και οδηγοί - - Επόμενο αδιάβαστο κεφάλαιο - Επόμενα %d αδιάβαστα κεφάλαια - Μάθετε γιατί Λήψη εκ των προτέρων Λειτουργεί μόνο σε καταχωρήσεις στη βιβλιοθήκη και αν το τρέχον κεφάλαιο και το επόμενο έχουν ήδη ληφθεί @@ -1016,22 +931,6 @@ Δεν έχει βαθμολογηθεί Ιχνηλάτης Έτος έναρξης - - Τύπος σειράς - %d τύποι σειρών - - - Πηγή - %d Πηγές - - - Κατάσταση - %d καταστάσεις - - - Γλώσσα - %d γλώσσες - Τίτλοι σε καθολική ενημέρωση Τοπικοί τίτλοι Χρόνος παραμονής στον αναγνώστη, με βάση το ιστορικό του κεφαλαίου @@ -1065,4 +964,4 @@ Εφαρμογή Συνιστάται να επιτρέψετε τις ειδοποιήσεις για να διατηρείται την βιβλιοθήκη σας και την εφαρμογή σας ενημερωμένες. Κοινοποίηση εξωφύλλου - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/eo/plurals.xml b/i18n/src/commonMain/moko-resources/eo/plurals.xml new file mode 100644 index 0000000000..8ff7da8010 --- /dev/null +++ b/i18n/src/commonMain/moko-resources/eo/plurals.xml @@ -0,0 +1,42 @@ + + + + Cetere %1$d paĝo + Cetere %1$d paĝoj + + + + Forigi %1$d elŝutitan ĉapitron\? + Forigi %1$d elŝutitajn ĉapitrojn\? + + + + 1 ĉapitro + %1$s ĉapitroj + + + + %d kategorio%d kategorioj + + + + + Farita en %1$s kun %2$s eraro + Farita en %1$s kun %2$s eraroj + + + + Mankas 1 ĉapitron + Mankas %d ĉapitrojn + + + + Post 1 minutoPost %1$s minutoj + + + + + Por 1 titoloPor %d titoloj + + + diff --git a/app/src/main/res/values-eo/strings.xml b/i18n/src/commonMain/moko-resources/eo/strings.xml similarity index 93% rename from app/src/main/res/values-eo/strings.xml rename to i18n/src/commonMain/moko-resources/eo/strings.xml index 00f9356ac4..446eef6ec5 100644 --- a/app/src/main/res/values-eo/strings.xml +++ b/i18n/src/commonMain/moko-resources/eo/strings.xml @@ -2,14 +2,6 @@ Elektitaj: %1$d Biblioteko - - Cetere %1$d paĝo - Cetere %1$d paĝoj - - - Forigi %1$d elŝutitan ĉapitron\? - Forigi %1$d elŝutitajn ĉapitrojn\? - Ĉapitro netrovita Marki kiel nelegita Marki kiel legita @@ -19,10 +11,6 @@ Lastatempe legis ĉapitro %1$s Nelegita Novaj ĉapitroj - - 1 ĉapitro - %1$s ĉapitroj - Priskribo Desegnisto Aŭtoro @@ -54,10 +42,6 @@ Redakti kategoriojn Ĝisdatigi Listo - - %d kategorio%d kategorioj - - Malmoderna Instalata Instalita @@ -158,10 +142,6 @@ Eraro okazis dum viŝado de kaŝmemoro Kuketoj viŝitis Kreas savkopion - - Farita en %1$s kun %2$s eraro - Farita en %1$s kun %2$s eraroj - %02d min, %02d sek Laste legita ĉapitro Dekstre maldekstren @@ -188,10 +168,6 @@ Rezignita restaŭro Servoj Ĉi tiu kromaĵo ne estas de la oficiala Tachiyomi kromaĵlisto. - - Mankas 1 ĉapitron - Mankas %d ĉapitrojn - Sekura ekrano Agordi kiel kovrilo @@ -378,14 +354,6 @@ Administri sciigojn Elŝutitaj ĉapitroj Nur ĝisdatigi okazantaj mangaojn - - Post 1 minutoPost %1$s minutoj - - - - Por 1 titoloPor %d titoloj - - Navigaranĝo Montri erarojn Kaŝi aplikaĵan enhavon kiam ŝaltumas aplikaĵojn kaj malebligi ekrankopion @@ -394,4 +362,4 @@ Devigi malŝlosi Griza Biblioteka kontribuoj - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/es/plurals.xml b/i18n/src/commonMain/moko-resources/es/plurals.xml new file mode 100644 index 0000000000..7ca91a260c --- /dev/null +++ b/i18n/src/commonMain/moko-resources/es/plurals.xml @@ -0,0 +1,154 @@ + + + + Actualización de extensión disponible + %d actualizaciones de extensiónes disponibles + %d actualizaciones de extensiones disponibles + + + + %d categoría + %d categorías + %d categorías + + + + %1$d página restante + %1$d páginas restantes + %1$d páginas restantes + + + + ¿Eliminar %1$d capítulo descargado\? + ¿Eliminar %1$d capítulos descargados\? + ¿Eliminar %1$d capítulos descargados\? + + + + y %1$d capítulo más + y %1$d capítulos más + y %1$d capítulos más + + + + Para %d título + Para %d títulos + Para %d títulos + + + + Un capítulo ha sido eliminado de la fuente: +\n%2$s +\n¿Eliminar capítulo descargado\? + Se han eliminado %1$s capítulos de la fuente: +\n%2$s +\n +\n¿Borrar sus descargas\? + %1$s capítulos han sido eliminados de la fuente: +\n%2$s +\n +\n¿Eliminar capítulos descargados\? + + + + Después de %1$s minuto + Después de %1$s minutos + Después de %1$s minutos + + + + Limpieza realizada. Carpeta %d eliminada + Limpieza realizada. Carpetas %d eliminadas + Limpieza realizada. Carpetas %d eliminadas + + + + Completada en %1$s con %2$s error + Completada en %1$s con %2$s errores + Completada en %1$s con %2$s errores + + + + %d serie migrada + %d series migradas + %d series migradas + + + + ¿Copiar la serie %1$d%2$s\? + ¿Copiar las series %1$d%2$s\? + ¿Copiar las series %1$d%2$s\? + + + + ¿Migrar la serie %1$d%2$s\? + ¿Migrar las series %1$d%2$s\? + ¿Migrar las series %1$d%2$s\? + + + + %1$s capítulo + %1$s capítulos + %1$s capítulos + + + + Caché borrada. Se ha eliminado el archivo %d + Caché borrada. Se han eliminado archivos %d + Caché borrada. Se han eliminado archivos %d + + + + %1$d página + %1$d páginas + %1$d páginas + + + + %d actualización pendiente + %d actualizaciones pendientes + %d actualizaciones pendientes + + + + Extensión actualizada + %d extensiones actualizadas + %d extensiones actualizadas + + + + Se omite %d capítulo, o bien falta en la fuente o ha sido filtrado + Se omiten %d capítulos, o bien faltan en la fuente o han sido filtrados + Se omiten %d capítulos, o bien faltan en la fuente o han sido filtrados + + + + El siguiente capítulo sin leer + Los siguientes %d capítulos sin leer + Los siguientes %d capítulos sin leer + + + + %d fuente + %d fuentes + %d fuentes + + + + %d Lenguaje + %d lenguajes + %d Otros lenguajes + + + + %d estado + %d estados + %d estados + + + + %d tipos de serie + %d tipos de series + %d tipos de series + + diff --git a/app/src/main/res/values-es/strings.xml b/i18n/src/commonMain/moko-resources/es/strings.xml similarity index 92% rename from app/src/main/res/values-es/strings.xml rename to i18n/src/commonMain/moko-resources/es/strings.xml index add0891ba3..11efa99f35 100644 --- a/app/src/main/res/values-es/strings.xml +++ b/i18n/src/commonMain/moko-resources/es/strings.xml @@ -321,11 +321,6 @@ Abrir sitio en WebView Obsoleto Esta extensión ya no está disponible. - - Actualización de extensión disponible - %d actualizaciones de extensiónes disponibles - %d actualizaciones de extensiones disponibles - Reduce el efecto anillado en los degradados y mejora la calidad de los grises, algo más lento Saltar capítulos filtrados Vertical continuo @@ -362,21 +357,6 @@ Ver capítulos Manhua Manhwa - - %d categoría - %d categorías - %d categorías - - - %1$d página restante - %1$d páginas restantes - %1$d páginas restantes - - - ¿Eliminar %1$d capítulo descargado\? - ¿Eliminar %1$d capítulos descargados\? - ¿Eliminar %1$d capítulos descargados\? - No se ha encontrado el capítulo Capítulos eliminados. Marcador eliminado @@ -451,16 +431,6 @@ Incluir en actualización global Al ordenar alfabéticamente, ordena ignorando los artículos (a, an, the) al principio del título de una serie Ordenar ignorando artículos - - y %1$d capítulo más - y %1$d capítulos más - y %1$d capítulos más - - - Para %d título - Para %d títulos - Para %d títulos - Más configuraciones de biblioteca Ocultar tolva de categoría Mostrar como @@ -498,19 +468,6 @@ Crear nueva categoría %1$s ya está en la cola Agregando %1$s a la cola de actualización - - Un capítulo ha sido eliminado de la fuente: -\n%2$s -\n¿Eliminar capítulo descargado\? - Se han eliminado %1$s capítulos de la fuente: -\n%2$s -\n -\n¿Borrar sus descargas\? - %1$s capítulos han sido eliminados de la fuente: -\n%2$s -\n -\n¿Eliminar capítulos descargados\? - Error al compartir portada Error al guardar portada Portada guardada @@ -527,11 +484,6 @@ Ocultar Descargar no leídos Removido: %1$s - - Después de %1$s minuto - Después de %1$s minutos - Después de %1$s minutos - Remover siempre Mantener siempre Remover capítulos eliminados @@ -547,11 +499,6 @@ Eliminar las portadas en caché que no estén en la biblioteca \nEn uso: %1$s Borrar portadas en caché - - Limpieza realizada. Carpeta %d eliminada - Limpieza realizada. Carpetas %d eliminadas - Limpieza realizada. Carpetas %d eliminadas - Desactivar si presentas problemas al actualizar o restaurar la biblioteca No hay carpetas para borrar Borrar leídos @@ -610,11 +557,6 @@ Rastreadores no conectados: Se ha cancelado la restauración %02d min, %02d seg - - Completada en %1$s con %2$s error - Completada en %1$s con %2$s errores - Completada en %1$s con %2$s errores - Guía de migración de fuentes Fuentes NSFW (18+) Esto no evita que las extensiones no oficiales o potencialmente marcadas incorrectamente muestren contenido para mayores de 18 años dentro de la aplicación. @@ -635,22 +577,7 @@ Ocultar automáticamente la barra de navegación Última utilización (Biblioteca o Recientes) Blanco puro - - %d serie migrada - %d series migradas - %d series migradas - (omitiendo %1$d) - - ¿Copiar la serie %1$d%2$s\? - ¿Copiar las series %1$d%2$s\? - ¿Copiar las series %1$d%2$s\? - - - ¿Migrar la serie %1$d%2$s\? - ¿Migrar las series %1$d%2$s\? - ¿Migrar las series %1$d%2$s\? - No se encontraron alternativas No migrar Último: %1$s @@ -673,11 +600,6 @@ Ocultar insignias por leer Agregar/Editar categorías Categoría - - %1$s capítulo - %1$s capítulos - %1$s capítulos - Añadir %1$s a… Mover %1$s a… Mostrar el título primero @@ -696,22 +618,12 @@ Añadido a %1$s Elimina las portadas en la caché y no utilizadas de las entradas de la biblioteca que se han actualizado. \nActualmente estás usando: %1$s - - Caché borrada. Se ha eliminado el archivo %d - Caché borrada. Se han eliminado archivos %d - Caché borrada. Se han eliminado archivos %d - Sin iniciar sesion en %1$s Rosa chicle Florecer de primavera Crepúsculo de medianoche Desactivar %s Activar %s - - %1$d página - %1$d páginas - %1$d páginas - Eliminar recorte Páginas %1$s %d por fila @@ -844,11 +756,6 @@ Tema claro No se han encontrado resultados iguales Fuente no soportada - - %d actualización pendiente - %d actualizaciones pendientes - %d actualizaciones pendientes - No se pudo instalar la extensión correctamente Actualizaciones globales Abrir una serie aleatoria @@ -900,11 +807,6 @@ Selecciona una entrada Dividir páginas dobles Separar páginas dobles en formato vertical - - Extensión actualizada - %d extensiones actualizadas - %d extensiones actualizadas - Extensiones actualizadas Instalado %1$s Actualizaciones de la extensión pendientes @@ -916,11 +818,6 @@ De manera predeterminada, la navegación lateral se utiliza en ciertos teléfonos y tabletas pequeñas cuando están en horizontal, y siempre se muestra en tabletas más grandes Comportamiento predeterminado Usar la navegación lateral - - Se omite %d capítulo, o bien falta en la fuente o ha sido filtrado - Se omiten %d capítulos, o bien faltan en la fuente o han sido filtrados - Se omiten %d capítulos, o bien faltan en la fuente o han sido filtrados - Enlaces útiles para la traducción Ayudar a traducir Filtrar grupos de scanlations @@ -1011,11 +908,6 @@ Las descargas pueden ser canceladas deslizándolas hacia fuera \nDesliza esto para descartarlo Descargar por adelantado - - El siguiente capítulo sin leer - Los siguientes %d capítulos sin leer - Los siguientes %d capítulos sin leer - Solo funciona con manga que ya esté en tu biblioteca y cuando el capítulo actual y el que va después ya estén descargados Gestionar notificaciones Batería cargada @@ -1066,31 +958,11 @@ Distribución de estado Distribución de puntuación Sin clasificar - - %d fuente - %d fuentes - %d fuentes - - - %d Lenguaje - %d lenguajes - %d Otros lenguajes - Detalles de estadísticas Ver estadísticas detalladas Fuente Cuenta Rastreador - - %d estado - %d estados - %d estados - - - %d tipos de serie - %d tipos de series - %d tipos de series - Tiempo usado por el lector, basado en el historial del capítulo Omitido, ya que no es necesario actualizarse Puntuación media de seguimiento @@ -1122,4 +994,4 @@ Información sobre la depuración Actividad en segundo plano Compartir la portada - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/eu/plurals.xml b/i18n/src/commonMain/moko-resources/eu/plurals.xml new file mode 100644 index 0000000000..afc55abfd9 --- /dev/null +++ b/i18n/src/commonMain/moko-resources/eu/plurals.xml @@ -0,0 +1,102 @@ + + + + Kendu kapitulu %1$d\? + Kendu %1$d kapitulu\? + + + + Kapitulu bat saltatzen, iturria falta da edo iragazia izan da + %d kapitulu saltatzen, iturria falta da edo iragaziak izan dira + + + + %d kategoria + %d kategoriak + + + + %1$d orrialdea + %1$d orrialdeak + + + + %d manga migratu da + %d manga migratu dira + + + + Kapitulu bat iturritik kendua izan da: +\n%2$s +\nBere deskarga ezabatu\? + %1$s kapitulu iturritik kenduak izan dira: +\n%2$s +\n +\nHaien deskargak ezabatu\? + + + + Migratu manga %1$d%2$s\? + Migratu %1$d%2$s manga\? + + + + Kopiatu manga %1$d%2$s\? + Kopiatu %1$d%2$s manga\? + + + + Garbiketa egina. Karpeta %d kendu da + Garbiketa egina. %d karpeta kendu dira + + + + Cachea garbitu da. Fitxategi %d ezabatu da + Cachea garbitu da. %d fitxategi ezabatu dira + + + + Minutu %1$s-en ondoren + %1$s minuturen ondoren + + + + Luzapena eguneratu da + %d Luzapen eguneratu dira + + + + %d tituluarentzako + %d tituluentzako + + + + eta kapitulu %1$d gehiago + eta %1$d kapitulu gehiago + + + + eguneraketa %d egiteke + %d eguneraketa egiteke + + + + Luzapenaren eguneraketa eskuragarri + %d Luzapenen eguneraketak eskuragarri + + + + %1$s-n egin da errore %2$s-ekin + %1$s-n egin da %2$s errorerekin + + + + %1$s kapitulu + %1$s kapituluak + + + + Orri %1$d geratzen da + %1$d orri geratzen dira + + diff --git a/app/src/main/res/values-eu/strings.xml b/i18n/src/commonMain/moko-resources/eu/strings.xml similarity index 94% rename from app/src/main/res/values-eu/strings.xml rename to i18n/src/commonMain/moko-resources/eu/strings.xml index 453caf19e4..1ab5ee28b1 100644 --- a/app/src/main/res/values-eu/strings.xml +++ b/i18n/src/commonMain/moko-resources/eu/strings.xml @@ -115,10 +115,6 @@ Erabili lehenetsia Ikusi kapituluak Oharra - - Kendu kapitulu %1$d\? - Kendu %1$d kapitulu\? - Ezabatu Ezabatua: %1$s Bistaratu @@ -239,17 +235,9 @@ Luzapenen eguneraketak geratzen dira Orrialde bikoitzak Betetu mozturiko eremuak - - Kapitulu bat saltatzen, iturria falta da edo iragazia izan da - %d kapitulu saltatzen, iturria falta da edo iragaziak izan dira - Ez da saioa hasi %1$s-n Garbitu cacheko azalak Saioa hasi - - %d kategoria - %d kategoriak - Erakutsi gisa Abisua: deskarga handiek iturriak motelagoak izatea eta/edo Tachiyomi blokeatzea ekar dezakete Berrezarri %1$s honen kapitulu guztiak @@ -380,10 +368,6 @@ Gaitu ainguratutako iturriak migratzeko bakarrik Baimendu une honetan gaituak dauden iturriak bakarrik migraziorako Honek ez du eragozten ofizialak ez diren edo oker markatutako luzapenek NSFW (18+) edukia aplikazioan erakustea. - - %1$d orrialdea - %1$d orrialdeak - Hasi irakurtzen Jarraitu irakurtzen %1$s Kapituluak @@ -399,33 +383,12 @@ Ez da kapitulurik aurkitu, manga hau ezin da migraziorako erabili Migratzea gelditu\? (%1$d saltatzen) - - %d manga migratu da - %d manga migratu dira - Urdin Klasikoa Gauerdiko ilunabarra Tako Lima Unea Eguneratze automatikoak Wi-Fi bidez soilik - - Kapitulu bat iturritik kendua izan da: -\n%2$s -\nBere deskarga ezabatu\? - %1$s kapitulu iturritik kenduak izan dira: -\n%2$s -\n -\nHaien deskargak ezabatu\? - - - Migratu manga %1$d%2$s\? - Migratu %1$d%2$s manga\? - - - Kopiatu manga %1$d%2$s\? - Kopiatu %1$d%2$s manga\? - Edozein saretan Babeskopia Babeskopia egin eta leheneratu @@ -439,10 +402,6 @@ Berreskuratzea bertan behera utzi da Argitalpenen lasterbideek kapitulu berriak irekitzen dituzte Desgaitua - - Garbiketa egina. Karpeta %d kendu da - Garbiketa egina. %d karpeta kendu dira - Iturrien migrazio gida Erakutsi iturrien eta luzapenen zerrendetan Itzulpen-esteka lagungarriak @@ -457,10 +416,6 @@ Ez dago sare-konexiorik erabilgarri Deskarga kokapena Kendu irakurri ondoren - - Cachea garbitu da. Fitxategi %d ezabatu da - Cachea garbitu da. %d fitxategi ezabatu dira - Kokapen pertsonalizatua Azkenik irakurritako kapitulua Deskargan sartuko diren kategoriak @@ -476,10 +431,6 @@ Egunero 2 egunean behin 3 egunean behin - - Minutu %1$s-en ondoren - %1$s minuturen ondoren - Ezeztatu Aurrera Doan @@ -644,10 +595,6 @@ Taldekatu kapituluak elkarrekin Azal uniformeak Besteak - - Luzapena eguneratu da - %d Luzapen eguneratu dira - %1$s orrialdeak Ez da hurrengo kapitulua aurkitu Erabili distira pertsonalizatua @@ -671,29 +618,13 @@ Doitu zabalera Doitu altuera %1$d Liburukia - - %d tituluarentzako - %d tituluentzako - - - eta kapitulu %1$d gehiago - eta %1$d kapitulu gehiago - Shizuku ez dago martxan Luzapen hau jada ez dago eskuragarri. Luzapen hau ez da Tachiyomi-ren luzapenen zerrenda ofizialekoa. Bertsioa: %1$s Hizkuntza: %1$s Aplikazioaren informazioa - - eguneraketa %d egiteke - %d eguneraketa egiteke - Luzapenak eguneratu dira - - Luzapenaren eguneraketa eskuragarri - %d Luzapenen eguneraketak eskuragarri - Ezarri azal gisa Irakurgailuaren ezarpenak Ezarri lehenetsia bezala denarentzat @@ -822,10 +753,6 @@ Erroreen erregistroak fitxategi batean gordetzen ditu garatzaileekin partekatzeko Sortu erroreen erregistroak Gorde dira erroreen erregistroak - - %1$s-n egin da errore %2$s-ekin - %1$s-n egin da %2$s errorerekin - Sarea DNS HTTPS bidez Ezabatu zure liburutegian ez dauden manga eta kapituluak @@ -864,14 +791,6 @@ Atzetik hasita bosgarren kapitulua Ireki erregistroa Goian - - %1$s kapitulu - %1$s kapituluak - - - Orri %1$d geratzen da - %1$d orri geratzen dira - Liburutegia iturrien, egoeraren eta abarren arabera taldekatzean Bertsio orria Kategoria-hautatzaileko sakaketa luzearen ekintza @@ -942,4 +861,4 @@ Baztertutako kategoriak Instalatzailea Atzeko planoko ekintzak - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/fa/plurals.xml b/i18n/src/commonMain/moko-resources/fa/plurals.xml new file mode 100644 index 0000000000..f36cfd3297 --- /dev/null +++ b/i18n/src/commonMain/moko-resources/fa/plurals.xml @@ -0,0 +1,42 @@ + + + + آپدیت برای یک افرونه موجود استآپدیت برای %d افرونه موجود است + + + + + قسمت%1$s + قسمت ها%1$s + + + + در %1$s با %2$s خطا انجام شددر %1$s با %2$s خطا انجام شد + + + + + %d دسته%d دسته + + + + + بعد از %1$s دقیقهبعد از %1$s دقیقه + + + + + برای ۱ مانگابرای %d مانگا + + + + + قسمت خوانده نشده بعدی + %d قسمت خوانده نشده بعدی + + + + 1 قسمت جا افتاده است + %d قسمت جا افتاده است + + diff --git a/app/src/main/res/values-fa/strings.xml b/i18n/src/commonMain/moko-resources/fa/strings.xml similarity index 96% rename from app/src/main/res/values-fa/strings.xml rename to i18n/src/commonMain/moko-resources/fa/strings.xml index 668e11f5d8..a0bc89601d 100644 --- a/app/src/main/res/values-fa/strings.xml +++ b/i18n/src/commonMain/moko-resources/fa/strings.xml @@ -126,10 +126,6 @@ حذف نصب نگارش %1$s زبان: %1$s - - آپدیت برای یک افرونه موجود استآپدیت برای %d افرونه موجود است - - فصل بعدی یافت نشد این عکس، به عنوان عکس روی جلد تنظیم شود؟ بعدی @@ -291,10 +287,6 @@ درحال آپدیت کتابخانه دسته بندی پیشفرض دسته بندی ها - - قسمت%1$s - قسمت ها%1$s - قفل صفحه هنگام بیکاری نیاز به باز کردن قفل تکمیل شده(Completed) @@ -340,19 +332,11 @@ جست و جوی تنضیمات بازیابی لغو شده %02d دقیقه, %02d ثانیه - - در %1$s با %2$s خطا انجام شددر %1$s با %2$s خطا انجام شد - - راهنمای تعویض منبع منابع محتوای جنسی (+18) هیچ نرم افزار انتخاب فایلی یافت نشد بازکردن log قسمت ها - - %d دسته%d دسته - - پیشرفت تکمیل شده پشتیبان گیری و بازیابی @@ -505,10 +489,6 @@ یوتسوبا حالت تاریک مشکی خالص ذخیره به عنوان فایل آرشیو CBZ - - بعد از %1$s دقیقهبعد از %1$s دقیقه - - بدون: %s برای دیدن جزئیات لمس کنید الگوی فقط جلد @@ -542,20 +522,12 @@ 5% قسمت‌های دانلود شده هدایت به پن - - برای ۱ مانگابرای %d مانگا - - دانلود خودکار در حین خواندن بارگیری شود ارغوانی بهبود کارکرد ابزار خواندن اجازه‌ی پاک‌کردن قسمت‌های نشانک‌گذاری شده را بده چپتر های تکراری را رد کن - - قسمت خوانده نشده بعدی - %d قسمت خوانده نشده بعدی - هیچ داده کتابخانه ای نیست که پشتیبانی شود داده ها از فایل پشتیبان برگردانده میشوند. \n @@ -563,14 +535,10 @@ پشتیبانی/بازگردانی ممکن است کار نکند اگر بهینه‌سازی MIUI غیر فعال باشد اگر قسمت فعلی و بعدی دانلود شده باشند، تنها برای ورودی‌های کتابخانه کار می‌کند آمار - - 1 قسمت جا افتاده است - %d قسمت جا افتاده است - خاکستری بروزرسانی برنامه دسته‌بندی‌های محذوف نصب کننده کتابخانه ورودی‌ها فعالیت در پس زمینه - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/fi/plurals.xml b/i18n/src/commonMain/moko-resources/fi/plurals.xml new file mode 100644 index 0000000000..7cd1316e99 --- /dev/null +++ b/i18n/src/commonMain/moko-resources/fi/plurals.xml @@ -0,0 +1,98 @@ + + + + + Laajennospäivitys saatavilla + %d laajennospäivitystä saatavilla + + + + %d kategoria + %d kategoriaa + + + + %1$d sivu jäljellä + %1$d sivua jäljellä + + + + Poistetaanko %1$d ladattu luku\? + Poistetaanko %1$d ladattua lukua\? + + + + Nimikkeelle %d + Nimikkeille %d + + + + Valmistui %1$s virheitä löytyi %2$s + Valmistui %1$s virheitä löytyi %2$s + + + + Välimuisti tyhjennetty. %d tiedosto on poistettu + Välimuisti tyhjennetty. %d tiedostoa on poistettu + + + + %d manga siirretty + %d mangaa siirretty + + + + Kopioi %1$d%2$s manga\? + Kopioi %1$d%2$s mangasta\? + + + + Siirrä %1$d%2$s manga\? + Siirrä %1$d%2$s mangaa\? + + + + Luku on poistettu lähteestä: +\n%2$s +\nPoistetaanko sen lataus\? + %1$s lukua on poistettu lähteestä: +\n%2$s +\n +\nPoistetaanko niiden lataukset\? + + + + ja %1$d lisää luku + ja %1$d lisää lukua + + + + %1$s luku + %1$s lukua + + + + Siivous tehty. Poistettu %d kansio + Siivous tehty. Poistettu %d kansiota + + + + %1$s minuutin jälkeen + %1$s minuutin jälkeen + + + + %1$d sivu + %1$d sivua + + + + Seuraava lukematon luku + Seuraavat %d lukematonta lukua + + + + 1 puuttuva luku + %d puuttuvaa lukua + + diff --git a/app/src/main/res/values-fi/strings.xml b/i18n/src/commonMain/moko-resources/fi/strings.xml similarity index 94% rename from app/src/main/res/values-fi/strings.xml rename to i18n/src/commonMain/moko-resources/fi/strings.xml index 7bea55e04e..27a23de06d 100644 --- a/app/src/main/res/values-fi/strings.xml +++ b/i18n/src/commonMain/moko-resources/fi/strings.xml @@ -283,10 +283,6 @@ Katso sivu WebViewissä Vanhentunut Tämä laajennus ei ole enää saatavilla. - - Laajennospäivitys saatavilla - %d laajennospäivitystä saatavilla - Vähentää juovia, mutta vaikuttaa suorituskykyyn Ohita suodatetut luvut Jatkuva pystysuora @@ -328,18 +324,6 @@ Päivitä WebView-sovellus yhteensopivuuden parantamiseksi Aina Takaisin - - %d kategoria - %d kategoriaa - - - %1$d sivu jäljellä - %1$d sivua jäljellä - - - Poistetaanko %1$d ladattu luku\? - Poistetaanko %1$d ladattua lukua\? - Lukua ei löytynyt Luvut poistettu. Poistettu kirjanmerkki @@ -392,10 +376,6 @@ Luo uusi kategoria %1$s on jo jonossa Lisätään %1$s päivitysjonoon - - Nimikkeelle %d - Nimikkeille %d - Lisää kirjaston asetuksia Piilota kategoriavalikko Seuratut @@ -412,10 +392,6 @@ \nSinun on asennattava puuttuvat laajennukset ja kirjauduttava seurantapalveluihin jälkeenpäin käyttääksesi niitä. Palautus peruttu %02d min, %02d sek - - Valmistui %1$s virheitä löytyi %2$s - Valmistui %1$s virheitä löytyi %2$s - Animoi sivusiirtymät Oletuslukutila L-muotoinen @@ -448,10 +424,6 @@ Avaa loki Poista olemattomat, osittain ladatut ja luettujen lukujen kansiot Poista ladatut luvut - - Välimuisti tyhjennetty. %d tiedosto on poistettu - Välimuisti tyhjennetty. %d tiedostoa on poistettu - Tiedonhallinta Et ole kirjautunut sisään: %1$s Varmuuskopion palauttaminen epäonnistui @@ -464,19 +436,7 @@ Piilota alareunan navigointi automaattisesti Viimeksi käytetty (kirjasto tai viimeisimmät) Puhtaan valkoinen - - %d manga siirretty - %d mangaa siirretty - (ohitetaan %1$d) - - Kopioi %1$d%2$s manga\? - Kopioi %1$d%2$s mangasta\? - - - Siirrä %1$d%2$s manga\? - Siirrä %1$d%2$s mangaa\? - Lopetetaanko siirtyminen\? Vaihtoehtoja ei löytynyt Lukuja ei löytynyt, tätä mangaa ei voida käyttää siirtämiseen @@ -503,15 +463,6 @@ Halu lukea Tällä hetkellä luettavana Ei seurattu - - Luku on poistettu lähteestä: -\n%2$s -\nPoistetaanko sen lataus\? - %1$s lukua on poistettu lähteestä: -\n%2$s -\n -\nPoistetaanko niiden lataukset\? - Mukautettu manga info Virhe jakaessa kansikuvaa Virhe tallentaessa kansikuvaa @@ -584,18 +535,10 @@ Sisällytä globaaliin päivitykseen Kun lajittelet aakkosjärjestyksessä, lajittele jättämällä huomioimatta artikkelit (a, an, the) manganimikkeiden alussa Lajittele jättämällä artikkelit huomiotta - - ja %1$d lisää luku - ja %1$d lisää lukua - Näytä lukemattomien määrä Näytä lukemattomien merkit Piilota lukemattomien merkit Kategoria - - %1$s luku - %1$s lukua - Edistyminen Valmis Kaatumislokit @@ -618,10 +561,6 @@ Aloitetaan siivous Poista manga, jota ei ole kirjastossa Poista luetut - - Siivous tehty. Poistettu %d kansio - Siivous tehty. Poistettu %d kansiota - Poista tämä käytöstä, jos kirjaston päivittämisessä tai palauttamisessa on ongelmia Merkitse kaikki luvut lukemattomiksi\? Leikkausalueen käyttäytyminen @@ -650,10 +589,6 @@ BETA Lisätty %1$s lisää %1$s - - %1$s minuutin jälkeen - %1$s minuutin jälkeen - Poista aina Säilytä aina Poista globaalin päivityksen aikana, kysy luvut-sivulla @@ -674,10 +609,6 @@ Käytä viimeksi tallennettuja siirtoa edeltäviä asetuksia ja lähteitä massasiirtoon Ota vain tällä hetkellä käytössä olevat lähteet käyttöön siirtoa varten Ota vain kiinnitetyt lähteet käyttöön siirtoa varten - - %1$d sivu - %1$d sivua - Automaattinen (suuntautumisen perusteella) Kun käytät automaattista sivun asettelua, voit silti siirtyä asettelusta toiseen lukemisen aikana ohittamatta tätä asetusta Sivun asettelu @@ -849,10 +780,6 @@ Ei varmuuskopioitavia sarjoja kirjastossa Tauolla Automaattinen lataus luetessa - - Seuraava lukematon luku - Seuraavat %d lukematonta lukua - %1$d sarjaa joita ei olla lisätty kirjastoon tietokanassa Parannetut palvelut RARv5-muoto ei ole tuettu @@ -885,13 +812,9 @@ Ohitettu, koska sarja ei vaadi päivityksiä Poista kirjanmerkityt luvut Suositut - - 1 puuttuva luku - %d puuttuvaa lukua - Sovelluspäivitykset Harmaa Poissuljetut kategoriat Asentaja Taustatoiminta - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/fil/plurals.xml b/i18n/src/commonMain/moko-resources/fil/plurals.xml new file mode 100644 index 0000000000..4911fc8ee5 --- /dev/null +++ b/i18n/src/commonMain/moko-resources/fil/plurals.xml @@ -0,0 +1,128 @@ + + + + + %1$s kabanata + %1$s (na) kabanata + + + + Available na ang pag-update ng extension + Available na ang %d na mga update sa extension + + + + %d kategorya + %d (na) kategorya + + + + %1$d pahina na lang + %1$d (na) pahina na lang + + + + Tanggalin ang %1$d na-download na kabanata\? + Tanggalin ang %1$d (na) na-download na kabanata\? + + + + Na-restore sa loob ng %1$s na may %2$s error + Na-restore sa loob ng %1$s na may %2$s (na) error + + + + Nalinis na ang cache. Binura ang %d file + Nalinis na ang cache. Binura ang %d (na) file + + + + %d nakabinbing update + %d (na) nakabinbing update + + + + Para sa %d serye + Para sa %d (na) serye + + + + at %1$d pang kabanata + at %1$d pang mga kabanata + + + + Na-update na ang extension + Na-update na ang %d na mga extension + + + + %1$d pahina + %1$d (na) pahina + + + + Nilaktawan ang %d na kabanata, maaaring ito ay wala sa source o na-filter ang mga ito + Nilaktawan ang %d na mga kabanata, maaaring wala sa source o na-filter ang mga ito + + + + Pagkatapos ng %1$s minuto + Pagkatapos ng %1$s (na) minuto + + + + Ilipat ang %1$d manga %2$s\? + Ilipat ang %1$d (na) manga %2$s\? + + + + Tinanggal sa source ang kabanata: +\n%2$s +\nBurahin ang na-download\? + %1$s (na) kabanata ang tinanggal sa source: +\n%2$s +\n +\nBurahin ang mga na-download\? + + + + Nailipat na ang %d manga + Nailipat na ang %d (na) manga + + + + Kopyahin ang %1$d manga %2$s\? + Kopyahin ang %1$d (na) manga %2$s\? + + + + Tapos na ang paglilinis. Inalis ang %d folder + Tapos na ang paglilinis. Inalis ang %d (na) folder + + + + Susunod na hindi pa nababasa na kabanata + Susunod na %d di pa nababasa na kabanata + + + + %d uri ng serye + %d mga uri ng serye + + + + %d na pinagkukunan + %d na mga pinagmumulan + + + + %d na katayuan + %d mga katayuan + + + + %d wika + %d na mga wika + + diff --git a/app/src/main/res/values-fil/strings.xml b/i18n/src/commonMain/moko-resources/fil/strings.xml similarity index 93% rename from app/src/main/res/values-fil/strings.xml rename to i18n/src/commonMain/moko-resources/fil/strings.xml index 49b2eab848..d1549c8222 100644 --- a/app/src/main/res/values-fil/strings.xml +++ b/i18n/src/commonMain/moko-resources/fil/strings.xml @@ -10,10 +10,6 @@ Kumpleto Nangangailangang i-unlock Isara kung nakatambay - - %1$s kabanata - %1$s (na) kabanata - Di pa nabasa Kabanata %1$s Tinandaan @@ -165,10 +161,6 @@ Wala na\'ng ganitong extension. Bersyon: %1$s Wika: %1$s - - Available na ang pag-update ng extension - Available na ang %d na mga update sa extension - Gawing cover Napalitan na ang cover Di makita ang susunod na kabanata @@ -295,18 +287,6 @@ Mga kabanata Naka-wifi Tina-track - - %d kategorya - %d (na) kategorya - - - %1$d pahina na lang - %1$d (na) pahina na lang - - - Tanggalin ang %1$d na-download na kabanata\? - Tanggalin ang %1$d (na) na-download na kabanata\? - Hindi makita ang kabanata Natanggal na ang mga kabanata. Tanggalin ang pananda @@ -370,10 +350,6 @@ \nKakailanganin mo na ma-install ang mga nawawalang dugtong at mag-login sa mga tracking service pagkatapos para magamit mo sila. Kinansela ang pag-restore %02d (na) min, %02d (na) seg - - Na-restore sa loob ng %1$s na may %2$s error - Na-restore sa loob ng %1$s na may %2$s (na) error - Walang nakitang app para makapili Buksan ang log Mga Kabanata @@ -513,10 +489,6 @@ Isang pahina Dobleng pahina Nakatago ang source - - Nalinis na ang cache. Binura ang %d file - Nalinis na ang cache. Binura ang %d (na) file - Pamamahala sa data Pipilitin nito na muling ikalkula ang download cache. May gamit ito kung binago mo ang mga download sa labas ng app na ito at gusto mong kunin sila ng app I-refresh ang download cache @@ -558,10 +530,6 @@ Di mai-load ang larawan Mga pahina: %1$s Pahina: %1$d - - %d nakabinbing update - %d (na) nakabinbing update - Ina-update ang mga dugtong May mga dugtong na kakailanganin pa rin munang i-install. I-update lahat @@ -602,10 +570,6 @@ Panlahatang pag-update Rine-refresh ang mga pabalat sa Aklatan at habang nag-a-update Kusang i-refresh ang mga pabalat - - Para sa %d serye - Para sa %d (na) serye - Kailangan ng TachiyomiJ2K ng access sa lahat ng mga file para maka-download ng mga kabanata. Pakipindot ito, tapos pakibuksan ang \"Payagan ang pamamahala ng lahat ng file.\" Ang TachiyomiJ2K ay nangangailangan ng access sa lahat ng mga file sa Android 11 upang mag-download ng mga kabanata, gumawa ng mga awtomatikong pag-backup, at magbasa ng lokal na manga. \n @@ -613,10 +577,6 @@ Kailangan ng permiso sa file Kapag paalpabetong mag-aayos, ayusin nang binabalewala ang mga article (a, an, the) sa simula ng mga pamagat Ayusin nang binabalewala ang mga article - - at %1$d pang kabanata - at %1$d pang mga kabanata - Lumipat nang dalawahang pahina Lumipat nang isahang pahina Itago ang kategorya @@ -649,22 +609,10 @@ Piliin ang simulang kabanata Maghanap ng mga kabanata Mga error - - Na-update na ang extension - Na-update na ang %d na mga extension - Na-install na ang %1$s Patayo Walang paglalarawan Ipakita kapag mahabang pinindot - - %1$d pahina - %1$d (na) pahina - - - Nilaktawan ang %d na kabanata, maaaring ito ay wala sa source o na-filter ang mga ito - Nilaktawan ang %d na mga kabanata, maaaring wala sa source o na-filter ang mga ito - Tungkol sa %1$s na ito Simulang basahin Season %1$d @@ -700,10 +648,6 @@ Ipakita ang outline sa paligid ng pabalat Babala: maaaring humantong sa pagbagal at/o pagharang ng mga source sa Tachiyomi ang mga malalaking maramihang pag-download. I-tap para matuto pa. Kada 3 araw - - Pagkatapos ng %1$s minuto - Pagkatapos ng %1$s (na) minuto - Tapos na\'ng mailathala Pinahusay na serbisyo Kinansela @@ -745,10 +689,6 @@ Ayusin base sa ayos ng source I-reset ang mga tag lilipat sa - - Ilipat ang %1$d manga %2$s\? - Ilipat ang %1$d (na) manga %2$s\? - Dapat nasa Aklatan mo ang manga para ma-edit I-filter ang mga scanlator Wika @@ -766,15 +706,6 @@ Ipakita ang mga kabanatang na-download Idagdag ang %1$s sa Aklatan\? Ipakita ang mga kabanatang may pananda - - Tinanggal sa source ang kabanata: -\n%2$s -\nBurahin ang na-download\? - %1$s (na) kabanata ang tinanggal sa source: -\n%2$s -\n -\nBurahin ang mga na-download\? - Tanggalin ang %1$s mula %2$s at idagdag ang %3$s Di magawang ma-update ang uri ng iskor: %1$s Pumili ng source @@ -824,10 +755,6 @@ I-update ang pagta-track kapag namarkahang nabasa Tanggalin din sa %1$s Gamitin ang source na may pinakamaraming kabanata (mas mabagal) - - Nailipat na ang %d manga - Nailipat na ang %d (na) manga - Isara ang %s Madilim na tema Kusang mag-update @@ -856,10 +783,6 @@ Ilipat sa %1$s Walang nakitang kabanata, hindi magagamit ang manga na ito sa paglipat Walang nakitang alternatibo - - Kopyahin ang %1$d manga %2$s\? - Kopyahin ang %1$d (na) manga %2$s\? - Gamitin ang iminungkahing petsa Paglipat ng source Paglipat @@ -885,10 +808,6 @@ Pamahalaan ang mga abiso Di pa lowbat Mga Madalas Itanong at Gabay - - Tapos na ang paglilinis. Inalis ang %d folder - Tapos na ang paglilinis. Inalis ang %d (na) folder - Linisin ang mga filter Panimulang orientation Orientation @@ -913,10 +832,6 @@ Tanggalin ang mga download I-download agad Gumagana lamang sa mga entry sa aklatan at kung ang kasalukuyang kabanata at ang susunod na kabanata ay na-download na - - Susunod na hindi pa nababasa na kabanata - Susunod na %d di pa nababasa na kabanata - Idagdag sa %1$s Idinagdag sa %1$s BETA @@ -1016,23 +931,7 @@ Pinanggalingan Tracker Haba - - %d uri ng serye - %d mga uri ng serye - - - %d na pinagkukunan - %d na mga pinagmumulan - Sinimulang taon - - %d na katayuan - %d mga katayuan - - - %d wika - %d na mga wika - Oras na ginugol sa pambasa, base sa nakaraang binasa Nilaktawan dahil hindi kailangan ang pag-update sa serye Invalid na string ng user agent @@ -1061,4 +960,4 @@ Mga setting ng app Impormasyon sa pag-debug Gawaing likuran - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/fr/plurals.xml b/i18n/src/commonMain/moko-resources/fr/plurals.xml new file mode 100644 index 0000000000..537f5e5a77 --- /dev/null +++ b/i18n/src/commonMain/moko-resources/fr/plurals.xml @@ -0,0 +1,155 @@ + + + + + Mise à jour d\'extension disponible + %d mises à jour des extensions disponibles + %d mises à jour des extensions disponibles + + + + et %1$d autre chapitre + et %1$d autres chapitres + et %1$d autres chapitres + + + + Pour le titre du %d + Pour les titres des %d + Pour les titres des %d + + + + Supprimer %1$d chapitre téléchargé \? + Supprimer %1$d chapitres téléchargés \? + Supprimer %1$d chapitres téléchargés \? + + + + %d catégorie + %d catégories + %d catégories + + + + %1$d page restante + %1$d pages restantes + %1$d pages restantes + + + + Après %1$s minute + Après %1$s minutes + Après %1$s minutes + + + + Nettoyage terminé. %d dossier supprimé + Nettoyage terminé. %d dossiers supprimés + Nettoyage terminé. %d dossiers supprimés + + + + Cache effacé. %d fichier a été supprimé + Cache effacé. %d fichiers ont été supprimés + Cache effacé. %d fichiers ont été supprimés + + + + %d manga migré + %d mangas migrés + %d mangas migrés + + + + Copier le manga %1$d%2$s \? + Copier les mangas %1$d%2$s \? + Copier les mangas %1$d%2$s \? + + + + Migrer le manga %1$d%2$s \? + Migrer les mangas %1$d%2$s \? + Migrer les mangas %1$d%2$s \? + + + + Un chapitre a été retiré de la source : +\n%2$s +\nSupprimer le téléchargement \? + %1$s chapitres ont été retirés de la source : +\n%2$s +\n +\nSupprimer les téléchargements \? + %1$s chapitres ont été retirés de la source : +\n%2$s +\n +\nSupprimer les téléchargements \? + + + + Effectuée en %1$s avec %2$s erreur + Effectuée en %1$s avec %2$s erreurs + Effectuée en %1$s avec %2$s erreurs + + + + %1$s chapitre + %1$s chapitres + %1$s chapitres + + + + %1$d page + %1$d pages + %1$d pages + + + + %d mise à jour en attente + %d mises à jour en attente + %d mises à jour en attente + + + + Extension mise à jour + %d extensions mises à jour + %d extensions mises à jour + + + + %d chapitre a été sauté, soit la source ne l\'a pas, soit il a été filtré + %d chapitres ont été sautés, soit la source ne les a pas, soit ils ont été filtrés + %d chapitres ont été sautés, soit la source ne les a pas, soit il ont été filtrés + + + + Chapitre suivant non lu + Les %d suivants non lus + Les %d suivants non lus + + + + %d type de série + %d types de série + %d types de série + + + + %d source + %d sources + %d sources + + + + %d état + %d états + %d états + + + + %d langue + %d langues + %d langues + + diff --git a/app/src/main/res/values-fr/strings.xml b/i18n/src/commonMain/moko-resources/fr/strings.xml similarity index 92% rename from app/src/main/res/values-fr/strings.xml rename to i18n/src/commonMain/moko-resources/fr/strings.xml index 6dfbc8eafb..920addd442 100644 --- a/app/src/main/res/values-fr/strings.xml +++ b/i18n/src/commonMain/moko-resources/fr/strings.xml @@ -314,11 +314,6 @@ Consultez le site Web de WebView Obsolète Cette extension n’est plus disponible. - - Mise à jour d\'extension disponible - %d mises à jour des extensions disponibles - %d mises à jour des extensions disponibles - Réduit les bandes de couleur, mais peut impacter les performances Passer les chapitres filtrés Vertical continu @@ -386,16 +381,6 @@ Inclure dans la mise à jour globale Lors du tri par ordre alphabétique, ne pas tenir compte des déterminants (un, une, le) au début des titres de manga Trier en ignorant les déterminants - - et %1$d autre chapitre - et %1$d autres chapitres - et %1$d autres chapitres - - - Pour le titre du %d - Pour les titres des %d - Pour les titres des %d - Autres paramètres de la bibliothèque Cachez la catégorie trémie Afficher en tant que @@ -429,25 +414,10 @@ Manga déjà dans la catégorie Les mangas de cette catégorie seront déplacés dans la catégorie par défaut. Supprimer la catégorie \? - - Supprimer %1$d chapitre téléchargé \? - Supprimer %1$d chapitres téléchargés \? - Supprimer %1$d chapitres téléchargés \? - La catégorie est vide Créer une nouvelle catégorie %1$s est déjà dans la file d\'attente Ajout de %1$s à la file d\'attente de mise à jour - - %d catégorie - %d catégories - %d catégories - - - %1$d page restante - %1$d pages restantes - %1$d pages restantes - Chapitre non trouvé Chapitres supprimés. Signet supprimé @@ -513,11 +483,6 @@ Télécharger les non lus Supprimé : %1$s Bas - - Après %1$s minute - Après %1$s minutes - Après %1$s minutes - Toujours supprimer Toujours conserver Supprimer pendant les mises à jour globales, demander sur la page des chapitres @@ -545,11 +510,6 @@ Supprimez les anciennes et inutilisées couvertures de manga mises en cache dans votre bibliothèque qui a été mise à jour. \nEn cours d\'utilisation : %1$s Nettoyer les couvertures mises en cache - - Nettoyage terminé. %d dossier supprimé - Nettoyage terminé. %d dossiers supprimés - Nettoyage terminé. %d dossiers supprimés - Désactivez cette option si vous rencontrez des problèmes de mise à jour ou de restauration de votre bibliothèque Aucun dossier à nettoyer Supprimer les catégories vides @@ -557,31 +517,11 @@ Supprimer les lectures Supprimer les mangas qui ne sont pas dans la bibliothèque Supprimer les catégories de chapitres inexistants, partiellement téléchargés et lus - - Cache effacé. %d fichier a été supprimé - Cache effacé. %d fichiers ont été supprimés - Cache effacé. %d fichiers ont été supprimés - Gestion des données Non connecté à %1$s Échec de la restauration de la sauvegarde Blanc pur - - %d manga migré - %d mangas migrés - %d mangas migrés - (sauter %1$d) - - Copier le manga %1$d%2$s \? - Copier les mangas %1$d%2$s \? - Copier les mangas %1$d%2$s \? - - - Migrer le manga %1$d%2$s \? - Migrer les mangas %1$d%2$s \? - Migrer les mangas %1$d%2$s \? - Arrêter de migrer \? Aucune alternatives trouvées Migrer %1$s @@ -608,19 +548,6 @@ En cours de lecture Non suivi Suivi - - Un chapitre a été retiré de la source : -\n%2$s -\nSupprimer le téléchargement \? - %1$s chapitres ont été retirés de la source : -\n%2$s -\n -\nSupprimer les téléchargements \? - %1$s chapitres ont été retirés de la source : -\n%2$s -\n -\nSupprimer les téléchargements \? - Erreur de partage de couverture Erreur lors de l\'enregistrement de la couverture Couverture enregistrée @@ -672,11 +599,6 @@ \nVous devrez installer les extensions manquantes et vous connecter ensuite aux services de suivi pour les utiliser. Restauration de sauvegarde annulée %02d min, %02d s - - Effectuée en %1$s avec %2$s erreur - Effectuée en %1$s avec %2$s erreurs - Effectuée en %1$s avec %2$s erreurs - Guide de migration des sources Contenu +18 Cela n\'empêche pas les extensions non officielles ou potentiellement mal signalées de diffuser du contenu +18 dans l\'application. @@ -716,11 +638,6 @@ Masquer les badges non lus Ajouter/Modifier des catégories Catégorie - - %1$s chapitre - %1$s chapitres - %1$s chapitres - Restauration déjà en cours Sélection Déplacer vers %1$s @@ -749,11 +666,6 @@ Seulement téléchargés Ajouter à %1$s Ajouté à %1$s - - %1$d page - %1$d pages - %1$d pages - Automatique (basé sur l\'orientation) Le nombre de pages à précharger pendant la lecture. De plus grandes valeurs rendront la lecture plus fluide au coût d\'un plus grand cache et d\'une plus grande utilisation de données. Nombre de pages à précharger @@ -851,11 +763,6 @@ Thème clair Aucun résultat trouvé La source n\'est pas prise en charge - - %d mise à jour en attente - %d mises à jour en attente - %d mises à jour en attente - Échec de l\'installation de l\'extension Mode sombre noir pur Alignement de l\'icône de navigation latérale @@ -895,11 +802,6 @@ Mettre à jour les extensions automatiquement Double page divisée Double page fractionnée en portrait - - Extension mise à jour - %d extensions mises à jour - %d extensions mises à jour - Extensions mises à jour Installés %1$s Mises à jour de l\'extension en attente @@ -919,11 +821,6 @@ Par défaut, la navigation latérale est utilisée pour certains téléphones et petites tablettes en mode paysage, et elle s\'affiche toujours sur les tablettes plus grandes Comportement par défaut Utiliser la navigation latérale - - %d chapitre a été sauté, soit la source ne l\'a pas, soit il a été filtré - %d chapitres ont été sautés, soit la source ne les a pas, soit ils ont été filtrés - %d chapitres ont été sautés, soit la source ne les a pas, soit il ont été filtrés - Liens utiles pour la traduction Aider à traduire Filtrer les groupes de scanlateurs @@ -1017,11 +914,6 @@ Notifications FAQ et guides Téléchargement anticipé - - Chapitre suivant non lu - Les %d suivants non lus - Les %d suivants non lus - Apprendre pourquoi Fonctionne seulement sur les entrées de la bibliothèque et si le chapitre actuel et le suivant sont déjà téléchargés L\'écran sécurisé cache le contenu lors du changement d\'application et bloque les captures d\'écran @@ -1074,26 +966,6 @@ Tous les mangas lus Conserver les mangas avec des chapitres lus Traqueur - - %d type de série - %d types de série - %d types de série - - - %d source - %d sources - %d sources - - - %d état - %d états - %d états - - - %d langue - %d langues - %d langues - Temps passé dans le lecteur, basé sur l\'historique des chapitres Ignorée car la série ne nécessite pas de mises à jour Note moyenne de suivi @@ -1120,4 +992,4 @@ Entrées de la bibliothèque Informations de débogage Activité en arrière-plan - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/gl/plurals.xml b/i18n/src/commonMain/moko-resources/gl/plurals.xml new file mode 100644 index 0000000000..8fc2e83222 --- /dev/null +++ b/i18n/src/commonMain/moko-resources/gl/plurals.xml @@ -0,0 +1,43 @@ + + + + + %1$s Capítulo + %1$s Capítulos + + + + %d categoría + %d categorías + + + + ¿Borrar %1$d capítulo descargado\? + ¿Borrar %1$d capítulos descargados\? + + + + Despois de 1 minutoDespois de %1$s minutos + + + + + Feito en %1$s con %2$s erro + Feito en %1$s con %2$s erros + + + + Seguinte capítulo sen ler + Seguintes %d capítulos sen ler + + + + Hai unha actualización dunha extensión + Hai actualizacións de %d extensións + + + + Saltouse %d capítulo: falta na fonte ou ignorouse + Saltáronse %d capítulos: faltan na fonte ou ignoráronse + + diff --git a/app/src/main/res/values-gl/strings.xml b/i18n/src/commonMain/moko-resources/gl/strings.xml similarity index 95% rename from app/src/main/res/values-gl/strings.xml rename to i18n/src/commonMain/moko-resources/gl/strings.xml index ce2c9b9039..a549007f45 100644 --- a/app/src/main/res/values-gl/strings.xml +++ b/i18n/src/commonMain/moko-resources/gl/strings.xml @@ -12,10 +12,6 @@ Require reiniciar a aplicación para que surxa efecto Cargando… Historial - - %1$s Capítulo - %1$s Capítulos - Categorías Explorar Manhwa @@ -190,10 +186,6 @@ Non se atopou unha aplicación para seleccionar arquivos Abrir rexistro Capítulos - - %d categoría - %d categorías - Capítulo seguinte Capítulo anterior Procura global @@ -236,10 +228,6 @@ Capítulo %1$s Todos os capítulos lidos Scanlators - - ¿Borrar %1$d capítulo descargado\? - ¿Borrar %1$d capítulos descargados\? - TachiyomiJ2K require acceso a tódolos arquivos de Android 11 para descargar capítulos, facer copias de seguridade automáticas e ler manga en local. \n \nNa seguinte pantalla, marca \"Permitir acceso á xestión de tódolos arquivos.\" @@ -256,17 +244,9 @@ Reduce o anelado pero afecta ao rendemento Forzar vertical Actualiza só manga en curso - - Despois de 1 minutoDespois de %1$s minutos - - Amosar na lista de fontes Forzar horizontal Copia de seguridade - - Feito en %1$s con %2$s erro - Feito en %1$s con %2$s erros - Actualizando a biblioteca Outros Guía de introdución @@ -377,10 +357,6 @@ Inverter as zonas de toque A máis baixa Capítulos %1$s - - Seguinte capítulo sen ler - Seguintes %d capítulos sen ler - Erro ao actualizar a portada Portada gardada Establecer por defecto @@ -475,10 +451,6 @@ Portada actualizada Produciuse un erro ao borrar Erro descoñecido - - Hai unha actualización dunha extensión - Hai actualizacións de %d extensións - Cada 3 días Elexir o ficheiro da copia de seguridade Ascendente @@ -509,10 +481,6 @@ Seguir o tema do sistema Por defecto, a navegación lateral utilízase en certos teléfonos e tabletas pequenas cando están en horizontal e sempre se mostra en tabletas máis grandes Non se puido cargar a imaxe - - Saltouse %d capítulo: falta na fonte ou ignorouse - Saltáronse %d capítulos: faltan na fonte ou ignoráronse - %d por fila Ocultar elementos que xa estén na biblioteca Tamaño da reixa @@ -526,4 +494,4 @@ Borrar o historial dos elementos que non estean gardados na túa biblioteca Información de depuración Actividade en segundo plano - \ No newline at end of file + diff --git a/app/src/main/res/values-ajp/strings.xml b/i18n/src/commonMain/moko-resources/ha/plurals.xml similarity index 60% rename from app/src/main/res/values-ajp/strings.xml rename to i18n/src/commonMain/moko-resources/ha/plurals.xml index a6b3daec93..045e125f3d 100644 --- a/app/src/main/res/values-ajp/strings.xml +++ b/i18n/src/commonMain/moko-resources/ha/plurals.xml @@ -1,2 +1,3 @@ - \ No newline at end of file + + diff --git a/app/src/main/res/values-ha/strings.xml b/i18n/src/commonMain/moko-resources/ha/strings.xml similarity index 100% rename from app/src/main/res/values-ha/strings.xml rename to i18n/src/commonMain/moko-resources/ha/strings.xml diff --git a/i18n/src/commonMain/moko-resources/hi/plurals.xml b/i18n/src/commonMain/moko-resources/hi/plurals.xml new file mode 100644 index 0000000000..837756dda0 --- /dev/null +++ b/i18n/src/commonMain/moko-resources/hi/plurals.xml @@ -0,0 +1,53 @@ + + + + + एक्सटेंशन अपडेट उपलब्ध%d एक्सटेंशन अपडेट उपलब्ध + + + + + %1$s में %2$s त्रुटि के साथ किया गया%1$s में %2$s त्रुटियों के साथ किया गया + + + + + %d श्रेणी + %d श्रेणियाँ + + + + %1$s मिनट के बाद%1$s मिनट के बाद + + + + + %d अध्याय को छोड़ा जा रहा है, या तो स्रोत में यह नहीं है या इसे फ़िल्टर कर दिया गया है + %d अध्यायों को छोड़ा जा रहा है, या तो स्रोत उन्हें याद कर रहा है या उन्हें फ़िल्टर कर दिया गया है + + + + अध्याय %1$s + अध्यायों %1$s + + + + %1$d पृष्ठ बाकि + %1$d पृष्ठ बाकि + + + + %1$d डाउनलोड अध्याय को निकालें\? + %1$d डाउनलोड अध्यायों को निकालें\? + + + + %d शीर्षक के लिए + %d शीर्षकों के लिए + + + + अगला अपठित अध्याय + अगले %d अपठित अध्याय + + diff --git a/app/src/main/res/values-hi/strings.xml b/i18n/src/commonMain/moko-resources/hi/strings.xml similarity index 95% rename from app/src/main/res/values-hi/strings.xml rename to i18n/src/commonMain/moko-resources/hi/strings.xml index 0122284d5d..2c5688ea6d 100644 --- a/app/src/main/res/values-hi/strings.xml +++ b/i18n/src/commonMain/moko-resources/hi/strings.xml @@ -281,10 +281,6 @@ वेबव्यू में वेबसाइट देखें अप्रचलित यह एक्सटेंशन अब उपलब्ध नहीं है। - - एक्सटेंशन अपडेट उपलब्ध%d एक्सटेंशन अपडेट उपलब्ध - - बैंडिंग को कम करता है, लेकिन प्रदर्शन को प्रभावित कर सकता है फ़िल्टर किए गए अध्यायों को छोड़ें लगातार लंबवत @@ -365,20 +361,12 @@ \nआपको किसी भी लापता एक्सटेंशन को इंस्टॉल करना होगा और बाद में सेवाओं को ट्रैक करने के लिए लॉग इन करना होगा ताकि उनका उपयोग किया जा सके। पुनर्स्थापना रद्द की गई %02d मिनट,%02d सेकंड - - %1$s में %2$s त्रुटि के साथ किया गया%1$s में %2$s त्रुटियों के साथ किया गया - - स्रोत माइग्रेशन गाइड NSFW (18+) स्रोत यह अनौपचारिक या संभावित रूप से फ़्लैग किए गए एक्सटेंशन को ऐप के भीतर NSFW (18+) सामग्री के सामने आने से नहीं रोकता है। नया क्या है कोई फ़ाइल पिकर ऐप नहीं मिला लॉग खोले - - %d श्रेणी - %d श्रेणियाँ - बैकअप और पुनर्स्थापना प्रगती पूर्ण @@ -392,10 +380,6 @@ परिवर्तन नीचे बेटा - - %1$s मिनट के बाद%1$s मिनट के बाद - - डाउनलोड किए गए अध्यायों को हटा दें यदि स्रोत ने अध्याय को ऑनलाइन हटा दिया है हमेशा हटाएं हमेशा रखें @@ -408,10 +392,6 @@ कवर पेज सहेजा गया कवर पेज सहेजने में त्रुटि प्रारंभिक मार्गदर्शन - - %d अध्याय को छोड़ा जा रहा है, या तो स्रोत में यह नहीं है या इसे फ़िल्टर कर दिया गया है - %d अध्यायों को छोड़ा जा रहा है, या तो स्रोत उन्हें याद कर रहा है या उन्हें फ़िल्टर कर दिया गया है - कोई पृष्ठ नहीं मिला टाको एक्सटेंशन अपडेट @@ -478,14 +458,6 @@ हर 3 दिन स्त्रोत के क्रम के अनुसार श्रेणी - - अध्याय %1$s - अध्यायों %1$s - - - %1$d पृष्ठ बाकि - %1$d पृष्ठ बाकि - अध्याय हटा दिया गया है। बुकमार्क हटा दिया गया है क्या सभी डौन्लोडस को हटाना है\? @@ -497,10 +469,6 @@ नई श्रेणी श्रेणी खाली है क्या श्रेणी को नष्ट करना है\? - - %1$d डाउनलोड अध्याय को निकालें\? - %1$d डाउनलोड अध्यायों को निकालें\? - पठित जैसा चिह्नित अपठित जैसा चिह्नित ट्रैकिंग सेवाओं में अध्याय की प्रगति को अद्यतन करने के लिए एकतरफा सिंक। अपने ट्रैकिंग बटन से व्यक्तिगत मंगा प्रविष्टियों के लिए ट्रैकिंग सेट अप करें। @@ -509,10 +477,6 @@ अंतराल पर है उन्नत सेवाएं ऐसी सेवाएँ जो विशिष्ट स्रोतों के लिए उन्नत सुविधाएँ प्रदान करती हैं। आपकी पुस्तकालय में जोड़े जाने पर पुस्तकें स्वचालित रूप से ट्रैक की जाती हैं। - - %d शीर्षक के लिए - %d शीर्षकों के लिए - श्रृंखला को शीर्ष पर ले जाएं अमान्य अध्याय प्रारूप के अनुसार ऑर्डर करें @@ -584,10 +548,6 @@ RARv5 प्रारूप समर्थित नहीं है आगे डाउनलोड करें पढ़ते समय ऑटो डाउनलोड करे - - अगला अपठित अध्याय - अगले %d अपठित अध्याय - होल्ड लिस्ट में केवल लाइब्रेरी में प्रविष्टियों पर काम करता है। और यदि वर्तमान अध्याय और अगला अध्याय पहले ही डाउनलोड हो चुका है टैप ज़ोन @@ -627,4 +587,4 @@ लाइब्रेरी के आइटम डीबग जानकारी पृष्ठभूमि गतिविधि - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/hr/plurals.xml b/i18n/src/commonMain/moko-resources/hr/plurals.xml new file mode 100644 index 0000000000..1a51514d75 --- /dev/null +++ b/i18n/src/commonMain/moko-resources/hr/plurals.xml @@ -0,0 +1,153 @@ + + + + + %1$s poglavlje + %1$s poglavlja + %1$s poglavlja + + + + Dostupna je %d nova verzija proširenja + Dostupne su %d nove verzije proširenja + Dostupoe je %d novih verzija proširenja + + + + %d kategorija + %d kategorije + %d kategorija + + + + %1$d preostala stranica + %1$d preostale stranice + %1$d preostalih stranica + + + + Ukloniti %1$d preuzeto poglavlje\? + Ukloniti %1$d preuzeta poglavlja\? + Ukloniti %1$d preuzetih poglavlja\? + + + + i još %1$d naslov + i još %1$d naslova + i još %1$d naslova + + + + Za %d naslov + Za %d naslova + Za %d naslova + + + + Brisanje je gotovo. Uklonjena je %d mapa + Brisanje je gotovo. Uklonjene su %d mape + Brisanje je gotovo. Uklonjeno je %d mapa + + + + Nakon %1$s minute + Nakon %1$s minute + Nakon %1$s minuta + + + + Obavljeno u %1$s s %2$s greškom + Obavljeno u %1$s s %2$s greške + Obavljeno u %1$s s %2$s grešaka + + + + Iz izvora je uklonjeno jedno poglavlje: +\n%2$s +\nŽeliš li izbrisati njegovo preuzimanje\? + Iz izvora su uklonjena %1$s poglavlja: +\n%2$s +\nŽeliš li izbrisati njihova preuzimanja\? + Iz izvora je uklonjeno %1$s poglavlja: +\n%2$s +\nŽeliš li izbrisati njihova preuzimanja\? + + + + Predmemorija je izbrisana. %d datoteka je izbrisana + Predmemorija je izbrisana. %d datoteke su izbrisane + Predmemorija je izbrisana. %d datoteka je izbrisano + + + + %d serija migrirana + %d serije migrirane + %d serija migrirano + + + + Kopirati %1$d%2$s seriju\? + Kopirati %1$d%2$s serije\? + Kopirati %1$d%2$s serija\? + + + + Migrati %1$d%2$s seriju\? + Migrati %1$d%2$s serije\? + Migrati %1$d%2$s serija\? + + + + %1$d stranica + %1$d stranice + %1$d stranica + + + + %d aktualiziranje na čekanju + %d aktualiziranja na čekanju + %d aktualiziranja na čekanju + + + + %d proširenje aktualizirano + %d proširenja aktualizirana + %d proširenja aktualizirano + + + + Preskače se %d poglavlje. Ne postoji u izvoru ili je filtrirano + Preskaču se %d poglavlja. Ne postoje u izvoru ili su filtrirana + Preskače se %d poglavlja. Ne postoje u izvoru ili su filtrirana + + + + Sljedeće nepročitano poglavlje + Sljedeća %d nepročitana poglavlja + Sljedećih %d nepročitanih poglavlja + + + + %d vrsta serije + %d vrste serije + %d vrsta serije + + + + %d stanje + %d stanja + %d stanja + + + + %d izvor + %d izvora + %d izvora + + + + %d jezik + %d jezika + %d jezika + + diff --git a/app/src/main/res/values-hr/strings.xml b/i18n/src/commonMain/moko-resources/hr/strings.xml similarity index 91% rename from app/src/main/res/values-hr/strings.xml rename to i18n/src/commonMain/moko-resources/hr/strings.xml index d307c5912b..c1d6ed84f4 100644 --- a/app/src/main/res/values-hr/strings.xml +++ b/i18n/src/commonMain/moko-resources/hr/strings.xml @@ -10,11 +10,6 @@ Završeno Zahtijevaj otključavanje Zaključaj prilikom mirovanja - - %1$s poglavlje - %1$s poglavlja - %1$s poglavlja - Nepročitano Poglavlje %1$s Zabilježeno @@ -87,11 +82,6 @@ Ovo proširenje više nije dostupno. Verzija: %1$s Jezik: %1$s - - Dostupna je %d nova verzija proširenja - Dostupne su %d nove verzije proširenja - Dostupoe je %d novih verzija proširenja - Postavi kao naslovnicu Naslovnica aktualizirana Sljedeće poglavlje nije pronađeno @@ -298,21 +288,6 @@ Pogledaj poglavlja Kategorija je prazna Stvori novu kategoriju - - %d kategorija - %d kategorije - %d kategorija - - - %1$d preostala stranica - %1$d preostale stranice - %1$d preostalih stranica - - - Ukloniti %1$d preuzeto poglavlje\? - Ukloniti %1$d preuzeta poglavlja\? - Ukloniti %1$d preuzetih poglavlja\? - Poglavlje nije pronađeno Poglavlja su uklonjena. Uklonjena oznaka @@ -386,16 +361,6 @@ Uključi u globalno aktualiziranje Prilikom razvrstavanja po abecedi, razvrstaj članke zanemarujući naslove serija koji počinju s (engl. a, an, the) Razvrstaj bez člana - - i još %1$d naslov - i još %1$d naslova - i još %1$d naslova - - - Za %d naslov - Za %d naslova - Za %d naslova - Daljnje postavke biblioteke Prikaži kao Dodirni ikonu biblioteke za prikazivanje filtara @@ -445,11 +410,6 @@ Aktualiziraj metapodatke praćenja Aktualiziraj metapodatke biblioteke Izbriši povijest za unose koji nisu spremljeni u biblioteci - - Brisanje je gotovo. Uklonjena je %d mapa - Brisanje je gotovo. Uklonjene su %d mape - Brisanje je gotovo. Uklonjeno je %d mapa - Deaktiviraj ovo ako imaš problema s aktualiziranjem ili obnavljanjem tvoje biblioteke Izbriši stare i nekorištene unose predmemoriranih naslovnica u tvojoj biblioteci koje su aktualizirane. \nTrenutačno se koristi: %1$s @@ -462,11 +422,6 @@ Greška tijekom spremanja naslovnice Naslovnica spremljena Obnovi naslovnicu - - Nakon %1$s minute - Nakon %1$s minute - Nakon %1$s minuta - Poredaj po broju poglavlja Poredaj po redoslijedu izvora Sakrij naslove poglavlja @@ -521,11 +476,6 @@ \nZa upotrebu podataka, morat ćeš instalirati nedostajuća proširenja i nakon toga se prijaviti na usluge praćenja. Obnavljanje prekinuto %02d min, %02d s - - Obavljeno u %1$s s %2$s greškom - Obavljeno u %1$s s %2$s greške - Obavljeno u %1$s s %2$s grešaka - Vodič za migraciju izvora Izvori neprikladnog sadržaja (18+) To ne sprečava neslužbene ili potencijalno krivo označene dodatke prikazati neprikladan sadržaj (18+) unutar aplikacije. @@ -556,17 +506,6 @@ Standard sustava Također ukloni iz %1$s Ukloni praćenje iz programa - - Iz izvora je uklonjeno jedno poglavlje: -\n%2$s -\nŽeliš li izbrisati njegovo preuzimanje\? - Iz izvora su uklonjena %1$s poglavlja: -\n%2$s -\nŽeliš li izbrisati njihova preuzimanja\? - Iz izvora je uklonjeno %1$s poglavlja: -\n%2$s -\nŽeliš li izbrisati njihova preuzimanja\? - Ne prati se Prilagođeni podaci serije Trenutačno čitam @@ -577,32 +516,12 @@ Prikaži značke nepročitanih Sakrij značke nepročitanih Dodaj/Uredi kategorije - - Predmemorija je izbrisana. %d datoteka je izbrisana - Predmemorija je izbrisana. %d datoteke su izbrisane - Predmemorija je izbrisana. %d datoteka je izbrisano - Upravljanje podacima Neprijavljeno na %1$s Neuspjelo obnavljanje sigurnosne kopije Maksimalni broj automatskih sigurnosnih kopija AMOLED crna - - %d serija migrirana - %d serije migrirane - %d serija migrirano - (%1$d se preskače) - - Kopirati %1$d%2$s seriju\? - Kopirati %1$d%2$s serije\? - Kopirati %1$d%2$s serija\? - - - Migrati %1$d%2$s seriju\? - Migrati %1$d%2$s serije\? - Migrati %1$d%2$s serija\? - Prekinuti migriranje\? Nisu pronađene alternative Nisu pronađena poglavlja. Ova se serija ne može koristiti za migraciju @@ -690,11 +609,6 @@ BETA Dodano u %1$s Dodaj u %1$s - - %1$d stranica - %1$d stranice - %1$d stranica - Automatski (ovisno o položaju) Prilikom korištenja automatskog prijeloma stranica, i dalje možeš mijenjati prijelome tijekom čitanja bez nadjačavanja ove postavke Prijelom stranice @@ -842,11 +756,6 @@ Izvor nije podržan Postavi kao standardno Dodaj oznaku - - %d aktualiziranje na čekanju - %d aktualiziranja na čekanju - %d aktualiziranja na čekanju - Aktualiziranje proširenja Neka će proširenja možda i dalje tražiti da se najprije instaliraju. Aktualiziraj sve @@ -858,11 +767,6 @@ Odaberite unos Podijeli duplerice Podijeli duplerice uspravno - - %d proširenje aktualizirano - %d proširenja aktualizirana - %d proširenja aktualizirano - Proširenja su aktualizirana Instalirano %1$s Aktualiziranja proširenja na čekanju @@ -885,11 +789,6 @@ Safirni sumrak Tirkizni ocean Izgled - - Preskače se %d poglavlje. Ne postoji u izvoru ili je filtrirano - Preskaču se %d poglavlja. Ne postoje u izvoru ili su filtrirana - Preskače se %d poglavlja. Ne postoje u izvoru ili su filtrirana - Odjava Odjaviti se iz %1$s\? Greške @@ -973,11 +872,6 @@ Radi samo na unosima u biblioteci i ako je trenutačno poglavlje plus sljedeće već preuzeto Dodirni za daljnje informacije Beta izdanja mogu biti nestabilna i mogu zahtijevati brisanje podataka aplikacije. - - Sljedeće nepročitano poglavlje - Sljedeća %d nepročitana poglavlja - Sljedećih %d nepročitanih poglavlja - Preuzmi unaprijed WebView podaci su izbrisani Stranica %d nije pronađena tijekom rastavljanja @@ -1034,30 +928,10 @@ Nema podataka za trenutačni filtar Statistike Naslovi u globalnom aktualiziranju - - %d vrsta serije - %d vrste serije - %d vrsta serije - - - %d stanje - %d stanja - %d stanja - Detalji statistike Lokalni naslovi Raspodjela rezultata Pogledaj detaljnju statistiku - - %d izvor - %d izvora - %d izvora - - - %d jezik - %d jezika - %d jezika - Provedeno vrijeme u čitaču, na temelju povijesti poglavlja Preskočeno jer serija ne zahtijeva aktualiziranja Nevažeći niz korisničkog agenta @@ -1088,4 +962,4 @@ Postavke aplikacije Informacije otklanjanja grešaka Aktivnost u pozadini - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/hu/plurals.xml b/i18n/src/commonMain/moko-resources/hu/plurals.xml new file mode 100644 index 0000000000..7888aabf78 --- /dev/null +++ b/i18n/src/commonMain/moko-resources/hu/plurals.xml @@ -0,0 +1,58 @@ + + + + + Egy új bővítményfrissítés érhető el%d bővítményfrissítés érhető el + + + + + %d kategória + %d kategóriák + + + + %1$d oldal hátra + %1$d oldalak hátra + + + + %1$s fejezet + %1$s fejezetek + + + + Eltávolítasz %1$d letöltött fejezetet\? + Eltávolítasz %1$d letöltött fejezeteket\? + + + + Befejezve %1$s alatt, %2$s hibával + Befejezve %1$s alatt, %2$s hibával + + + + 1 perc után%1$s percek után + + + + + %d-nak/nek%d-nak/nek + + + + + és még %1$d fejezet + és még %1$d fejezet + + + + Következő olvasatlan fejezet + Következő %d olvasatlan fejezet + + + + %d fejezet kihagyása, hiányzik a forrás, vagy ki lett szűrve + %d fejezet kihagyása, hiányoznak a források, vagy ki lettek szűrve + + diff --git a/app/src/main/res/values-hu/strings.xml b/i18n/src/commonMain/moko-resources/hu/strings.xml similarity index 94% rename from app/src/main/res/values-hu/strings.xml rename to i18n/src/commonMain/moko-resources/hu/strings.xml index 158ffe38b4..8f64bf7ce0 100644 --- a/app/src/main/res/values-hu/strings.xml +++ b/i18n/src/commonMain/moko-resources/hu/strings.xml @@ -125,10 +125,6 @@ Új verzió érhető el! Legújabb fejezet Letöltésszámláló - - Egy új bővítményfrissítés érhető el%d bővítményfrissítés érhető el - - Fejezetek megtekintése Dátum formátum Globális keresés @@ -167,10 +163,6 @@ Nem hivatalos NSFW (18+) források Napló megnyitása - - %d kategória - %d kategóriák - Minden forrás Keresési bővítmények… Könyvtárban @@ -242,18 +234,6 @@ %1$s már sorban van %1$s hozzáadása a frissítési sorba Kategória - - %1$d oldal hátra - %1$d oldalak hátra - - - %1$s fejezet - %1$s fejezetek - - - Eltávolítasz %1$d letöltött fejezetet\? - Eltávolítasz %1$d letöltött fejezeteket\? - Nem található fejezet A fejezet nem található Fejezetek eltávolítva. @@ -405,10 +385,6 @@ Nincs találat Útmutató helyi forráshoz Tracking hozzáadása - - Befejezve %1$s alatt, %2$s hibával - Befejezve %1$s alatt, %2$s hibával - Elemek törölve Biztos benne\? Nem könyvtári elemek olvasott fejezetei elvesznek Újdonságok @@ -484,10 +460,6 @@ Fejezet gyorsítótárának törlése Jelentkezz be %1$s-ba/be Mentés CBZ archívumkén - - 1 perc után%1$s percek után - - %1$s oldalt nem lehetett betölteni Adatok visszaállítása a biztonsági mentésből. \n @@ -495,10 +467,6 @@ Beállítás alapértelmezettként A biztonsági mentés nem tartalmaz mangát. Bővítmény frissítések keresése - - %d-nak/nek%d-nak/nek - - Ez a kép legyen a fedlap\? Befejezve: Mit tartalmazzon a biztonsági mentés\? @@ -577,25 +545,13 @@ A könyvtárad üres, adj hozzá mangát a böngészés fülön Frissítések és Előzmények Újonnan hozzáadva - - és még %1$d fejezet - és még %1$d fejezet - A nagy frissítés növelheti az akumulátor használatot és a források lassabbak lesznek.Nyomj ide további információkért. Automatikus letöltés olvasás közben - - Következő olvasatlan fejezet - Következő %d olvasatlan fejezet - Csak a könyvtár bejegyzéseinél működik, és ha az aktuális és a következő fejezet már letöltött Letöltés előre Könyvjelzőzött fejezetek törlésének engedélyezése Widget nem elérhető amikor az alkalmazás zárolva van Statisztika - - %d fejezet kihagyása, hiányzik a forrás, vagy ki lett szűrve - %d fejezet kihagyása, hiányoznak a források, vagy ki lettek szűrve - A képet nem lehetett betölteni Felkapott Mutasd mindet @@ -613,4 +569,4 @@ Könyvtár bejegyzések Debug információ Háttér aktivitás - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/in/plurals.xml b/i18n/src/commonMain/moko-resources/in/plurals.xml new file mode 100644 index 0000000000..3f8834211e --- /dev/null +++ b/i18n/src/commonMain/moko-resources/in/plurals.xml @@ -0,0 +1,102 @@ + + + + + Terdapat %d perbaharuan ekstensi + + + + dan %1$d bab lain + + + + Untuk %d judul + + + + %d kategori + + + + %1$d halaman tersisa + + + + Hapus %1$d bab yang diunduh\? + + + + Selesai dalam %1$s dengan %2$s kesalahan + + + + %1$s bab + + + + %1$s bab telah dihapus dari sumber: +\n%2$s +\n +\nHapus unduhan\? + + + + %d manga dimigrasi + + + + Salin manga %1$d%2$s\? + + + + Pembersihan selesai. %d folder telah dihapus + + + + Cache telah dibersihkan. %d berkas telah dihapus + + + + %1$d halaman + + + + Setelah %1$s menit + + + + Migrasi %1$d%2$s manga\? + + + + Pembaruan %d ditunda + + + + %d + + + + Melewati %d bab, entah sumbernya hilang atau telah difilter + + + + Selanjutnya chapter %d yang belum dibaca + + + + %d jenis seri + + + + %d sumber + + + + %d status + + + + %d bahasa + + diff --git a/app/src/main/res/values-in/strings.xml b/i18n/src/commonMain/moko-resources/in/strings.xml similarity index 95% rename from app/src/main/res/values-in/strings.xml rename to i18n/src/commonMain/moko-resources/in/strings.xml index d4ef5de1e9..1a12821c17 100644 --- a/app/src/main/res/values-in/strings.xml +++ b/i18n/src/commonMain/moko-resources/in/strings.xml @@ -276,9 +276,6 @@ Cek halaman web dalam tampilan web Usang Ekstensi ini sudah tidak tersedia. - - Terdapat %d perbaharuan ekstensi - Mengurangi banding, namun berdampak pada performa Lewati bab yang terfilter Vertikal terus-menerus @@ -372,12 +369,6 @@ Sertakan pembaharuan global Ketika mengurutkan berdasarkan alfabet, urutan mengabaikan artikel (a,an,the) di awal judul komik Urutkan dengan mengabaikan artikel - - dan %1$d bab lain - - - Untuk %d judul - Pengaturan lanjut pustaka Sembunyikan kategori lompat Tampilkan sebagai @@ -416,15 +407,6 @@ Manhua %1$s sudah ada dalam antrian Menambahkan %1$s ke antrian pembaharuan - - %d kategori - - - %1$d halaman tersisa - - - Hapus %1$d bab yang diunduh\? - Bab tak ditemukan Bab dihapus. Hapus tanda @@ -488,9 +470,6 @@ Pelacakan tidak tersinkronisasi di: Pemulihan dibatalkan %02d menit, %02d detik - - Selesai dalam %1$s dengan %2$s kesalahan - Buka log Cadangkan dan pulihkan Kemajuan @@ -507,9 +486,6 @@ Mohon isi nama kategori Tambah kategori baru Kategori - - %1$s bab - Pindah %1$s ke… Tambah %1$s ke … Unduh yang belum dibaca @@ -517,12 +493,6 @@ Pemulihan masih dalam proses Ingin dibaca Sedang Dibaca - - %1$s bab telah dihapus dari sumber: -\n%2$s -\n -\nHapus unduhan\? - Geser satu halaman ke atas Beralih ke satu halaman Beralih ke dua halaman @@ -553,13 +523,7 @@ Urut & Saring Pilih sumber Pilihan - - %d manga dimigrasi - (melewatkan %1$d) - - Salin manga %1$d%2$s\? - Kunjungi tab terbaru untuk mengakses antrean unduhan. Anda juga dapat mengetuk atau menekan dan menahan dua kali untuk akses yang lebih cepat Atur apa yang diunduh Tidak ada unduhan @@ -599,15 +563,9 @@ Tandai semua sebagai telah dibaca Simpan Bersihkan sampul yang di-cache - - Pembersihan selesai. %d folder telah dihapus - Memulai pembersihan Bersihkan manga yang tidak terdapat di pustaka Bersihkan unduhan yatim - - Cache telah dibersihkan. %d berkas telah dihapus - Kembali ke mulai Ikuti tema sistem Jangan lakukan migrasi @@ -630,9 +588,6 @@ Semua kecuali bab yang dimarkahkan Semua bab yang telah dibaca Tandai semua bab sebagai belum dibaca\? - - %1$d halaman - Tampilkan pada tekan lama Otomatis (berdasarkan orientasi) Ketika menggunakan tata letak halaman secara otomatis, Anda masih dapat menukar tata letak ketika sedang membaca tanpa menimpa pengaturan ini @@ -702,9 +657,6 @@ BETA Ditambahkan ke %1$s Tambahkan ke %1$s - - Setelah %1$s menit - Penghapusan otomatis Selalu hapus Selalu simpan @@ -752,9 +704,6 @@ Mode incognito (rahasia) Nonaktifkan %s Aktifkan %s - - Migrasi %1$d%2$s manga\? - Tidak ada Alternatif Ditemukan Tidak ada bab yang ditemukan, manga ini tidak dapat digunakan untuk migrasi Perizinan berkas diperlukan @@ -798,9 +747,6 @@ Sumber tidak didukung Setel sebagai default Tambahkan tag - - Pembaruan %d ditunda - Memperbarui ekstensi Perbarui semua Pembaruan global @@ -830,9 +776,6 @@ Pilih entri Pisahkan halaman ganda Pisahkan halaman ganda di potret - - %d - Ekstensi diperbarui Dipasang %1$s Pembaruan ekstensi ditunda @@ -841,9 +784,6 @@ Tampilkan kategori kosong saat menyaring Nama Panduan awal mulai - - Melewati %d bab, entah sumbernya hilang atau telah difilter - Bantu terjemahkan Tautan terjemahan yang membantu Secara default, navigasi samping digunakan untuk handphone dan tablet tertentu saat landscape, dan selalu ditampilkan di tablet yang lebih besar @@ -936,9 +876,6 @@ Pencadangan otomatis sangat disarankan. Anda juga harus menyimpan duplikat di tempat lain. Gunakan grid jatuh Zoom pada halaman ganda - - Selanjutnya chapter %d yang belum dibaca - Unduh di depan Hanya berfungsi pada entri di perpustakaan dan jika bab saat ini ditambah yang berikutnya sudah diunduh Kelola notifikasi @@ -979,9 +916,6 @@ Judul yang dilacak Tag Panjang - - %d jenis seri - Detail statistik Status Statusnya @@ -998,15 +932,6 @@ Tidak dinilai Sumber Pelacak - - %d sumber - - - %d status - - - %d bahasa - Waktu yang dihabiskan di pembaca, berdasarkan sejarah bab Dilewati karena seri ini tidak memerlukan pembaruan String agen pengguna tidak valid @@ -1034,4 +959,4 @@ Entri pustaka Info debug Aktivitas dibelakang layar - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/it/plurals.xml b/i18n/src/commonMain/moko-resources/it/plurals.xml new file mode 100644 index 0000000000..377f9a40b8 --- /dev/null +++ b/i18n/src/commonMain/moko-resources/it/plurals.xml @@ -0,0 +1,155 @@ + + + + + Aggiornamento estensione disponibile + %d estensioni hanno aggiornamenti disponibili + %d estensioni hanno aggiornamenti disponibili + + + + %d categoria + %d categorie + %d categorie + + + + %1$d pagina rimasta + %1$d pagine rimaste + %1$d pagine rimaste + + + + Rimuovere %1$d capitolo scaricato\? + Rimuovere %1$d capitoli scaricati\? + Rimuovere %1$d capitoli scaricati\? + + + + Dopo un minuto + Dopo %1$s minuti + Dopo %1$s minuti + + + + Eliminazione completata. Rimossa la cartella %d + Eliminazione completata. Rimosse le cartelle %d + Eliminazione completata. Rimosse le cartelle %d + + + + Cache libera. Il file %d è stato rimosso + Cache libera. I file %d sono stati rimossi + Cache libera. I file %d sono stati rimossi + + + + Una serie migrata + %d serie migrate + %d serie migrate + + + + Copiare la serie %1$d%2$s\? + Copiare le serie %1$d%2$s\? + Copiare le serie %1$d%2$s\? + + + + Migrare la serie %2$s\? + Migrare le serie %1$d%2$s\? + Migrare le serie %1$d%2$s\? + + + + Un capitolo è stato rimosso dalla sorgente: +\n%2$s +\nEliminare il suo download\? + %1$s capitoli sono stati rimossi dalla sorgente: +\n%2$s +\n +\nEliminare i loro download\? + %1$s capitoli sono stati rimossi dalla sorgente: +\n%2$s +\n +\nEliminare i loro download\? + + + + e un altro capitolo + e %1$d altri capitoli + e %1$d altri capitoli + + + + Per un titolo + Per %d titoli + Per %d titoli + + + + Completato in %1$s con %2$s errore + Completato in %1$s con %2$s errori + Completato in %1$s con %2$s errori + + + + %1$s capitolo + %1$s capitoli + + + + + %1$d pagina + %1$d pagine + %1$d pagine + + + + %d aggiornamento in attesa + %d aggiornamenti in attesa + %d aggiornamenti in attesa + + + + Estensione aggiornata + %d estensioni aggiornate + %d estensioni aggiornate + + + + %d capitolo saltato, la fonte non ce l\'ha o è stato filtrato + %d capitoli saltati, la fonte non li ha o sono stati filtrati + %d capitoli saltati, la fonte non li ha o sono stati filtrati + + + + Il prossimo capitolo non letto + I prossimi %d capitoli non letti + I prossimi %d capitoli non letti + + + + Un tipo di serie + %d tipi di serie + %d tipi di serie + + + + Fonte + %d fonti + %d fonti + + + + Status + %d stati + %d stati + + + + Una lingua + %d lingue + %d lingue + + diff --git a/app/src/main/res/values-it/strings.xml b/i18n/src/commonMain/moko-resources/it/strings.xml similarity index 92% rename from app/src/main/res/values-it/strings.xml rename to i18n/src/commonMain/moko-resources/it/strings.xml index 56eeb5b576..1240577768 100644 --- a/app/src/main/res/values-it/strings.xml +++ b/i18n/src/commonMain/moko-resources/it/strings.xml @@ -317,11 +317,6 @@ Controlla il sito in WebView Obsoleta Questa estensione non è più disponibile. - - Aggiornamento estensione disponibile - %d estensioni hanno aggiornamenti disponibili - %d estensioni hanno aggiornamenti disponibili - Riduce il banding, ma potrebbe influire sulle prestazioni Salta capitoli filtrati Verticale continuo @@ -367,16 +362,6 @@ Crea una nuova categoria %1$s è già nella coda Aggiungendo %1$s alla coda di aggiornamento - - %d categoria - %d categorie - %d categorie - - - %1$d pagina rimasta - %1$d pagine rimaste - %1$d pagine rimaste - Capitolo non trovato Capitoli rimossi. Segnalibro rimosso @@ -393,11 +378,6 @@ Fumetto Manhua Manhwa - - Rimuovere %1$d capitolo scaricato\? - Rimuovere %1$d capitoli scaricati\? - Rimuovere %1$d capitoli scaricati\? - Ordina per Espandi tutte le categorie Mostra sempre la categoria corrente @@ -457,11 +437,6 @@ Scarica non letti Eliminato: %1$s Fondo - - Dopo un minuto - Dopo %1$s minuti - Dopo %1$s minuti - Elimina sempre Mantieni sempre Elimina negli aggiornamenti globali, chiedi per la pagina del capitolo @@ -484,11 +459,6 @@ Elimina dalla cache le vecchie copertine delle voci presenti nella tua libreria, le cui copertine sono state aggiornate. \nIn uso: %1$s Elimina le copertine in cache - - Eliminazione completata. Rimossa la cartella %d - Eliminazione completata. Rimosse le cartelle %d - Eliminazione completata. Rimosse le cartelle %d - Disabilita questo se hai problemi ad aggiornare o recuperare la tua libreria Nessuna cartella da eliminare Inizio eliminazione @@ -497,31 +467,11 @@ Elimina gli orfani Cancella le cartelle dei capitoli letti, non esistenti, o scaricati parzialmente Elimina i capitoli scaricati - - Cache libera. Il file %d è stato rimosso - Cache libera. I file %d sono stati rimossi - Cache libera. I file %d sono stati rimossi - Gestione dei dati Non connesso in %1$s Impossibile ripristinare il backup Bianco puro - - Una serie migrata - %d serie migrate - %d serie migrate - (saltare %1$d) - - Copiare la serie %1$d%2$s\? - Copiare le serie %1$d%2$s\? - Copiare le serie %1$d%2$s\? - - - Migrare la serie %2$s\? - Migrare le serie %1$d%2$s\? - Migrare le serie %1$d%2$s\? - Interrompere la migrazione\? Nessun Alternativa Trovata Nessun capitolo trovato, questa serie non può essere usata per la migrazione @@ -550,19 +500,6 @@ Voglio leggere In lettura Non tracciati - - Un capitolo è stato rimosso dalla sorgente: -\n%2$s -\nEliminare il suo download\? - %1$s capitoli sono stati rimossi dalla sorgente: -\n%2$s -\n -\nEliminare i loro download\? - %1$s capitoli sono stati rimossi dalla sorgente: -\n%2$s -\n -\nEliminare i loro download\? - Errore nella condivisione della copertina Errore nel salvataggio della copertina Copertina salvata @@ -621,16 +558,6 @@ Includi nell\'aggiornamento globale Quando ordini alfabeticamente, ordina ignorando gli articoli (il, lo, la, i, gli, le) posti all\'inizio dei nomi di una serie Ordina ignorando gli articoli - - e un altro capitolo - e %1$d altri capitoli - e %1$d altri capitoli - - - Per un titolo - Per %d titoli - Per %d titoli - Impostazioni libreria aggiuntive Visualizza come Premi sull\'icona «Libreria» per vedere i filtri @@ -641,11 +568,6 @@ Anima le transazioni di pagina Nessun capitolo trovato %02d min, %02d sec - - Completato in %1$s con %2$s errore - Completato in %1$s con %2$s errori - Completato in %1$s con %2$s errori - Guida alla migrazione di origine Fonti NSFW (18+) Questo non impedisce a estensioni non ufficiali o potenzialmente segnalate in modo errato mostrare contenuti 18+ all\'interno dell\'applicazione. @@ -690,11 +612,6 @@ Ripristino già in corso Aggiungi/Modifica categorie Categoria - - %1$s capitolo - %1$s capitoli - - Il backup è già in corso Successivo Disabilitato @@ -760,11 +677,6 @@ Sospendi cronologia di lettura Modalità incognito Segna tutti i capitoli come non letti\? - - %1$d pagina - %1$d pagine - %1$d pagine - Impaginazione Passa a pagina singola Passa a doppia pagina @@ -827,11 +739,6 @@ Informazioni serie personalizzate Ignora aree ritagliate Riempi aree ritagliate - - %d aggiornamento in attesa - %d aggiornamenti in attesa - %d aggiornamenti in attesa - Nascondi contenuto notifiche Il comportamento dell\'area ritagliata si applica solo in modalità verticale con determinati tipi di scala Inizia dopo il ritaglio @@ -895,11 +802,6 @@ Aggiorna estensioni automaticamente Dividi doppie pagine Dividi doppie pagine in modalità ritratto - - Estensione aggiornata - %d estensioni aggiornate - %d estensioni aggiornate - Estensioni aggiornate Installati %1$s Aggiornamenti estensioni in attesa @@ -917,11 +819,6 @@ Mostra categorie vuote nel filtro Comportamento predefinito Usa navigazione laterale - - %d capitolo saltato, la fonte non ce l\'ha o è stato filtrato - %d capitoli saltati, la fonte non li ha o sono stati filtrati - %d capitoli saltati, la fonte non li ha o sono stati filtrati - Per impostazione predefinita, la navigazione laterale viene utilizzata per alcuni telefoni e piccoli tablet quando sono in orizzontale, e viene sempre mostrata sui tablet più grandi Collegamenti utili per la traduzione Aiuta a tradurre @@ -1007,11 +904,6 @@ Mostra una barra degli strumenti più grande nella parte superiore della maggior parte delle pagine (non mostrata su dispositivi più piccoli a prescindere dalle impostazioni) Tornare alla versione precedente potrebbe causare problemi e richiedere la pulizia dei dati dell\'applicazione. Scarica i prossimi - - Il prossimo capitolo non letto - I prossimi %d capitoli non letti - I prossimi %d capitoli non letti - Funziona solo sui manga nella libreria e se il capitolo corrente e quello successivo sono già stati scaricati Usa griglia scaglionata Aggiorna serie solo se non ci sono capitoli non letti (letto completamente) @@ -1059,16 +951,6 @@ Durata lettura Non valutato Fonte - - Un tipo di serie - %d tipi di serie - %d tipi di serie - - - Fonte - %d fonti - %d fonti - Dettaglio statistiche Titoli nella libreria Titoli tracciati @@ -1082,16 +964,6 @@ Tracker Lunghezza Anno di inizio - - Status - %d stati - %d stati - - - Una lingua - %d lingue - %d lingue - Nessun dato trovato con il filtro corrente Saltato perché la serie non richiede aggiornamenti Stringa «user agent» non valida @@ -1124,4 +996,4 @@ Attività in background Consente l\'installazione delle estensioni senza richieste da parte dell\'utente e abilita gli aggiornamenti automatici per i dispositivi con Android 12 Condividi copertina - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/iw/plurals.xml b/i18n/src/commonMain/moko-resources/iw/plurals.xml new file mode 100644 index 0000000000..786dab276e --- /dev/null +++ b/i18n/src/commonMain/moko-resources/iw/plurals.xml @@ -0,0 +1,73 @@ + + + + + קטגורייה אחת + שתי קטגוריות + %d קטגוריות + + + + + זמין עדכון לתוסף + זמינים עדכונים ל-%d תוספים + זמינים עדכונים ל-%d תוספים + + + + + הושלם ב %1$s עם שגיאה אחת + הושלם ב %1$s עם שתי שגיאות + הושלם ב %1$s עם %2$s שגיאות + + + + + לאחר דקה אחת + לאחר שתי דקות + לאחר %1$s דקות + + + + + הסר %1$d פרק מההורדות\? + הסר %1$d פרקים מההורדות\? + הסר %1$d פרקים מההורדות\? + הסר %1$d פרקים מההורדות\? + + + + %1$s פרק + %1$s פרקים + %1$s פרקים + %1$s פרקים + + + + דף %1$d נותר + %1$d דפים נותרו + %1$d דפים נותרו + %1$d דפים נותרו + + + + עבור כותר אחד + עבור שני כותרים + עבור %d כותרים + + + + + דולג פרק אחד, המקור חסר או שהוא סונן החוצה + דולגו שני פרקים, המקור חסר או שהם סוננו החוצה + דולגו %d פרקים, המקור חסר או שהם סוננו החוצה + + + + + הפרק הבא שלא נקרא + שני הפרקים הבאים שלא נקראו + %d הפרקים הבאים שלא נקראו + + + diff --git a/app/src/main/res/values-iw/strings.xml b/i18n/src/commonMain/moko-resources/iw/strings.xml similarity index 92% rename from app/src/main/res/values-iw/strings.xml rename to i18n/src/commonMain/moko-resources/iw/strings.xml index 2c7c119e2e..eb364ef8be 100644 --- a/app/src/main/res/values-iw/strings.xml +++ b/i18n/src/commonMain/moko-resources/iw/strings.xml @@ -37,12 +37,6 @@ קטגוריות קטגוריית ברירת המחדל ערוך קטגוריות - - קטגורייה אחת - שתי קטגוריות - %d קטגוריות - - עדכון גרסה חדשה זמינה! אין עדכונים חדשים זמינים @@ -104,12 +98,6 @@ בלתי רשמי פרטי האפליקצייה עדכן הכל - - זמין עדכון לתוסף - זמינים עדכונים ל-%d תוספים - זמינים עדכונים ל-%d תוספים - - הגדר ככריכה הכריכה עודכנה הפרק הבא לא נמצא @@ -261,12 +249,6 @@ יכול להיות שהגיבוי/השחזור לא יעבדו כמו שצריך אם אופטמיזציית MIUI מנועה. התקדמות הושלם - - הושלם ב %1$s עם שגיאה אחת - הושלם ב %1$s עם שתי שגיאות - הושלם ב %1$s עם %2$s שגיאות - - נקה את זיכרון המטמון של הפרקים רשת מנוע @@ -330,12 +312,6 @@ פעם ביומיים כל 3 ימים פעם בשבוע - - לאחר דקה אחת - לאחר שתי דקות - לאחר %1$s דקות - - בחר תמונת כריכה בחר קובץ גיבוי עקיפה של Cloudflare נכשלה @@ -434,24 +410,6 @@ לפי מקור סקנרים אין פרקים למחיקה - - הסר %1$d פרק מההורדות\? - הסר %1$d פרקים מההורדות\? - הסר %1$d פרקים מההורדות\? - הסר %1$d פרקים מההורדות\? - - - %1$s פרק - %1$s פרקים - %1$s פרקים - %1$s פרקים - - - דף %1$d נותר - %1$d דפים נותרו - %1$d דפים נותרו - %1$d דפים נותרו - קטגוריה מפחית פסים, אך עשוי להשפיע על הביצועים כמו ספר אלקטרוני @@ -467,12 +425,6 @@ תות דאיקירי מדריך נדידת מקורות החרגה: %s - - עבור כותר אחד - עבור שני כותרים - עבור %d כותרים - - %1$d עדכונים נכשלו הפורמט RARv5 לא נתמך מוסיף %1$s לעדכון @@ -527,21 +479,9 @@ צפה בפריטי הספריה העדכניים ביותר לא ניתן היה לפענח את התמונה עמוד %d לא נמצא בעת פיצול - - דולג פרק אחד, המקור חסר או שהוא סונן החוצה - דולגו שני פרקים, המקור חסר או שהם סוננו החוצה - דולגו %d פרקים, המקור חסר או שהם סוננו החוצה - - מידע של WebView נוקה בהצלחה הורד אוטומטית בזמן קריאה ספריה עודכנה לאחרונה ב: %s - - הפרק הבא שלא נקרא - שני הפרקים הבאים שלא נקראו - %d הפרקים הבאים שלא נקראו - - רשימת פריטים שהושלמו רשימת תכנונים המקור לא נתמך @@ -585,4 +525,4 @@ מחק את היסטוריית הפריטים שאינם שמורים בספריה שלך מידע דיבוג פעילות רקע - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/ja/plurals.xml b/i18n/src/commonMain/moko-resources/ja/plurals.xml new file mode 100644 index 0000000000..dfbcdc245d --- /dev/null +++ b/i18n/src/commonMain/moko-resources/ja/plurals.xml @@ -0,0 +1,101 @@ + + + + + %1$d件のダウンロードした章を削除してもよろしいですか? + + + + %1$s章 + + + + 残り%1$dページ + + + + %d カテゴリー + + + + %d件のタイトル + + + + とさらに%1$d章 + + + + %d件のアップデートが待機中 + + + + %d件の拡張機能をアップデートしました + + + + %d件の拡張機能の更新が利用可能 + + + + %1$dページ + + + + ソースには存在しないか、フィルターによって排除されたため、%d章がスキップされました + + + + 次の未読の%d章 + + + + 第%1$s章はソースから消去されています: +\n%2$s +\nダウンロードを削除しますか? + + + + %1$d%2$sのシリーズを移行しますか? + + + + %1$d%2$sのシリーズをコピーしますか? + + + + %dのシリーズを移行しました + + + + %1$sで完成済み %2$s件のエラーが発生しました + + + + キャッシュをクリアしました。%dファイルが削除されました + + + + クリーンアップ完了。%dフォルダーが消去されました + + + + %d件のシリーズ タイプ + + + + %d件のソース + + + + %d件のステータス + + + + %d件の言語 + + + + %1$s分後 + + diff --git a/app/src/main/res/values-ja/strings.xml b/i18n/src/commonMain/moko-resources/ja/strings.xml similarity index 96% rename from app/src/main/res/values-ja/strings.xml rename to i18n/src/commonMain/moko-resources/ja/strings.xml index 828bb1d89c..0f96aeb4e4 100644 --- a/app/src/main/res/values-ja/strings.xml +++ b/i18n/src/commonMain/moko-resources/ja/strings.xml @@ -81,15 +81,6 @@ 章の数に基づく アップロード日付に基づく スキャナー&翻訳者 - - %1$d件のダウンロードした章を削除してもよろしいですか? - - - %1$s章 - - - 残り%1$dページ - カテゴリー カテゴリー @@ -109,9 +100,6 @@ カテゴリーを編集 カテゴリーを管理 カテゴリーに移動 - - %d カテゴリー - 同じ名前のカテゴリーが既に存在します! カテゴリー名を空白にすることはできません カテゴリーが削除されました @@ -196,12 +184,6 @@ 新しい章が見つかりました 大規模なアップデートは電池を急激に消耗し、ソースを遅くする可能性があります。タップして詳細をご確認ください。 警告:大量の一括ダウンロードにより、ソースは遅くなったり、Tachiyomiを接続禁止したりする恐れがあります。詳しくはタップでご覧ください。 - - %d件のタイトル - - - とさらに%1$d章 - %1$d件の更新に失敗しました %1$d件の更新がスキップされました 完結済みの為スキップしました @@ -340,16 +322,7 @@ 全てアップデート 一部の拡張機能はそれでも先にインストールするよう表示する場合があります。 拡張機能をアップデートしています - - %d件のアップデートが待機中 - 拡張機能をアップデートしました - - %d件の拡張機能をアップデートしました - - - %d件の拡張機能の更新が利用可能 - 信頼できる全ての拡張機能を取り消す 信頼できる全ての拡張機能を取り消しますか? @@ -495,12 +468,6 @@ 高い 低い 最低 - - %1$dページ - - - ソースには存在しないか、フィルターによって排除されたため、%d章がスキップされました - カスタム表示プロファイル この%1$sについて @@ -528,9 +495,6 @@ 最初の章を選択します 最後の章を選択します 章を検索 - - 次の未読の%d章 - カスタム範囲 全ての章 全ての未読の章 @@ -565,11 +529,6 @@ 全ての既読シリーズ 既定として設定 スキャナー&翻訳者グループを絞り込む - - 第%1$s章はソースから消去されています: -\n%2$s -\nダウンロードを削除しますか? - 追跡 追跡済み @@ -641,16 +600,7 @@ 章が見つかりません。このシリーズは移行に使用できません 代替が見つかりません 移行を停止しますか? - - %1$d%2$sのシリーズを移行しますか? - - - %1$d%2$sのシリーズをコピーしますか? - (スキップ %1$d) - - %dのシリーズを移行しました - 設定 全般 @@ -771,9 +721,6 @@ MIUI最適化が有効な場合はバックアップ・復元が正常に機能しない恐れがあります。 プログレス 完了 - - %1$sで完成済み %2$s件のエラーが発生しました - %1$sにログインしていません 機密設定を含める (例: トラッカーログイントークン) 最後の自動バックアップ: %s @@ -798,9 +745,6 @@ 無効 変更を適用するには再起動してください サイズ:%1$s - - キャッシュをクリアしました。%dファイルが削除されました - 消去中にエラーが発生しました Cookiesを削除 Cookiesを削除しました @@ -827,9 +771,6 @@ バッテリー最適化を無効にする ライブラリの復元や更新に不具合が発生した場合無効にしてください バッテリー最適化は既に無効です - - クリーンアップ完了。%dフォルダーが消去されました - キャッシュされたカバーをクリーンアップ ライブラリの更新後に不要になった項目の古いカバーを削除します。 \n現在使用中:%1$s @@ -984,18 +925,6 @@ 長さ 開始年 現在のフィルターのデータが見つかりません - - %d件のシリーズ タイプ - - - %d件のソース - - - %d件のステータス - - - %d件の言語 - マニュアル 6時間ごと @@ -1004,9 +933,6 @@ 2日ごと 3日ごと 毎週 - - %1$s分後 - カバー画像を選択 バックアップファイルを選択 diff --git a/i18n/src/commonMain/moko-resources/jv/plurals.xml b/i18n/src/commonMain/moko-resources/jv/plurals.xml new file mode 100644 index 0000000000..be244abb45 --- /dev/null +++ b/i18n/src/commonMain/moko-resources/jv/plurals.xml @@ -0,0 +1,11 @@ + + + + + %d kategori + + + + Sawise %1$s menit + + diff --git a/app/src/main/res/values-jv/strings.xml b/i18n/src/commonMain/moko-resources/jv/strings.xml similarity index 98% rename from app/src/main/res/values-jv/strings.xml rename to i18n/src/commonMain/moko-resources/jv/strings.xml index bc06fb2672..2729483bfb 100644 --- a/app/src/main/res/values-jv/strings.xml +++ b/i18n/src/commonMain/moko-resources/jv/strings.xml @@ -48,9 +48,6 @@ Kategori kategori gawan Sunting kategori - - %d kategori - Nganyari Koleksi Tampilaken jumlah item @@ -169,9 +166,6 @@ Saben 2 dina Saben 3 dinten Saben minggu - - Sawise %1$s menit - Tambah Kabeh Miturut abjad @@ -220,4 +214,4 @@ Awas Pemasang Entri perpustakaan - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/ka/plurals.xml b/i18n/src/commonMain/moko-resources/ka/plurals.xml new file mode 100644 index 0000000000..6bb83172d9 --- /dev/null +++ b/i18n/src/commonMain/moko-resources/ka/plurals.xml @@ -0,0 +1,33 @@ + + + + + %d კატეგორია + %d კატეგორია + + + + ხელმისაწვდომია გაფართოების განახლება + ხელმისაწვდომია %d გაფართოების განახლება + + + + დასრულების დრო %1$s. %2$s შეცდომა + დასრულების დრო %1$s. %2$s შეცდომა + + + + %d ნაწარმოებისთვის + %d ნაწარმოებისთვის + + + + %1$s წუთის შემდეგ + %1$s წუთის შემდეგ + + + + 1 თავი + %1$s თავი + + diff --git a/app/src/main/res/values-ka/strings.xml b/i18n/src/commonMain/moko-resources/ka/strings.xml similarity index 95% rename from app/src/main/res/values-ka/strings.xml rename to i18n/src/commonMain/moko-resources/ka/strings.xml index 74fe1d2a2b..180dc383f5 100644 --- a/app/src/main/res/values-ka/strings.xml +++ b/i18n/src/commonMain/moko-resources/ka/strings.xml @@ -6,10 +6,6 @@ მარჯვენა და მარცხენა დაჭერის ინვერსია ქსელი - - %d კატეგორია - %d კატეგორია - განახლების ძებნა… საგნების რაოდენობის ჩვენება დამატების თარიღი @@ -18,10 +14,6 @@ დამატება არ არის Tachiyomi-ს ოფიციალური დამატებების სიიდან. 18+ შეიძლება შეიჩაცდეს უცენზურო(18+) კონტენტს - - ხელმისაწვდომია გაფართოების განახლება - ხელმისაწვდომია %d გაფართოების განახლება - ვერტიკალური არცერთი არცერთი @@ -29,10 +21,6 @@ განახლებულია v%1$s-მდე რეზერვი არ შეიცავს არცერთ მანგას. რას გსურს რომ შეუქმნა რეზერვი\? - - დასრულების დრო %1$s. %2$s შეცდომა - დასრულების დრო %1$s. %2$s შეცდომა - ეს არ აღმოფხვრავს პროგრამაში NSFW (18+) შიგთავსის არაოფიციალურ, ან შესაძლო არასწორად მონიშნული გაფართოებებოიდან გამოჩენას. რა არის ახალი გადმოწერის რიგი @@ -148,10 +136,6 @@ პაუზა სურათი შენახულია ბოლო თავი - - %d ნაწარმოებისთვის - %d ნაწარმოებისთვის - განახლებები გლობალური ძებნა უკანასკნელი @@ -270,10 +254,6 @@ რეზერვის შექმნის სიხშირე ყოველ 2 დღეში ერთხელ ყოველ კვირა - - %1$s წუთის შემდეგ - %1$s წუთის შემდეგ - თავში ატანა უძველესი ბრაუზერში გახსნა @@ -335,10 +315,6 @@ წაშლილია ბიბლიოთეკიდან წყარო არ არის დაინსტალირებული: %1$s თავის ნომრის მიხედვით - - 1 თავი - %1$s თავი - მონიშნული თავების წაშლა განბლოკვის მოთხოვნა გამოსახულებსი ჩატვირთვის შეცდომა @@ -348,4 +324,4 @@ ნაცრისფერი ბიბლიოთეკის ჩანაწერები ისტორიიდან წაიშლება ჩანაწერები, რომლებიც თქვენს ბიბლიოთეკაში არაა შენახული - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/kk/plurals.xml b/i18n/src/commonMain/moko-resources/kk/plurals.xml new file mode 100644 index 0000000000..0682967128 --- /dev/null +++ b/i18n/src/commonMain/moko-resources/kk/plurals.xml @@ -0,0 +1,48 @@ + + + + + %d санат + %d санат + + + + %1$s минуттан кейін%1$s минуттан кейін + + + + + %1$s дегеннен кейін %2$s қателікпен орындалды + %1$s дегеннен кейін %2$s қателікпен орындалды + + + + Келесі оқылмаған тарау + Келесі %d оқылмаған тарау + + + + %1$s тарау + %1$s тарау + + + + %1$d жүктелген тарауды жою керек пе\? + %1$d жүктеген тарауды жою керек пе\? + + + + %1$d бет қалды + %1$d бет қалды + + + + Кеңейту үшін жаңарту бар%d кеңейту үшін жаңарту бар + + + + + Дереккөзі жоқ немесе сүзілген %d тарау өткізіліп жіберілді + Дереккөзі жоқ немесе сүзілген %d тарау өткізіліп жіберілді + + diff --git a/app/src/main/res/values-kk/strings.xml b/i18n/src/commonMain/moko-resources/kk/strings.xml similarity index 95% rename from app/src/main/res/values-kk/strings.xml rename to i18n/src/commonMain/moko-resources/kk/strings.xml index 26a6d6e1a6..86bfede22b 100644 --- a/app/src/main/res/values-kk/strings.xml +++ b/i18n/src/commonMain/moko-resources/kk/strings.xml @@ -30,10 +30,6 @@ Әдепкі санат Санат жөндеу Жаңарту - - %d санат - %d санат - Кітапхана Заттардың санын көрсету Бөлімдер саны @@ -129,10 +125,6 @@ Әр 2 күн сайын Әр 3 күн сайын Апта сайын - - %1$s минуттан кейін%1$s минуттан кейін - - Қосу Барлығы Әліппе бойынша @@ -200,10 +192,6 @@ Қызметтер Күшейтілген қызметтер %02d мин, %02d сек - - %1$s дегеннен кейін %2$s қателікпен орындалды - %1$s дегеннен кейін %2$s қателікпен орындалды - Куки тазартылды Желі Жаңа тарауларды жүктеу @@ -262,10 +250,6 @@ Алдын ала жүктеу Оқыманың өнімділігін жақсартады Бақылау қызметтеріндегі прогрессті жаңарту үшін бір жақты үйлестіру. Бақылау батырмасын пайдаланып бақылауды орнатыңыз. - - Келесі оқылмаған тарау - Келесі %d оқылмаған тарау - Айналдырғандағы мәзірді жасыру сезгіштігі Тарау табылмады Манхва @@ -432,18 +416,6 @@ Тараулар жойылды. Еш бет табылмады Барлық жүктеп алғандарды жою керек пе\? - - %1$s тарау - %1$s тарау - - - %1$d жүктелген тарауды жою керек пе\? - %1$d жүктеген тарауды жою керек пе\? - - - %1$d бет қалды - %1$d бет қалды - Жаңа санат Жаңарту қолжетімді Жаңа нұсқа бар! @@ -487,10 +459,6 @@ Сақтық көшірме файлын таңдау Tachiyomi-ны қолдану үшін WebView керек Ортақ - - Кеңейту үшін жаңарту бар%d кеңейту үшін жаңарту бар - - Ұқсастық табылмады Осы суретті мұқаба ретінде қолданайық па\? Кітапханаға қосылды @@ -512,10 +480,6 @@ Кітапханада бар туындыларды жасыру Кітапхананың ақырғы жаңаруы: %s Дереккөздің бұйрығы бойынша - - Дереккөзі жоқ немесе сүзілген %d тарау өткізіліп жіберілді - Дереккөзі жоқ немесе сүзілген %d тарау өткізіліп жіберілді - Сурет жүктелінбеді Қолданба жаңартулары Сұр @@ -525,4 +489,4 @@ Кітапханада жоқ жазбалардың тарихын жою Дебаг туралы ақпарат Аялық белсенділік - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/km/plurals.xml b/i18n/src/commonMain/moko-resources/km/plurals.xml new file mode 100644 index 0000000000..8cbe16f088 --- /dev/null +++ b/i18n/src/commonMain/moko-resources/km/plurals.xml @@ -0,0 +1,23 @@ + + + + + %d ថ្នាក់ + + + + លុបភាគ %1$d ដែលបានទាញយកចោល\? + + + + %1$s ភាគ + + + + នៅសល់%1$d ទំព័រទៀត + + + + %d ភាគបន្ទាប់ដែលមិនទាន់អាន + + diff --git a/app/src/main/res/values-km/strings.xml b/i18n/src/commonMain/moko-resources/km/strings.xml similarity index 96% rename from app/src/main/res/values-km/strings.xml rename to i18n/src/commonMain/moko-resources/km/strings.xml index 476f176cc1..841aeefe13 100644 --- a/app/src/main/res/values-km/strings.xml +++ b/i18n/src/commonMain/moko-resources/km/strings.xml @@ -186,9 +186,6 @@ ថ្នាក់ធម្មតា ម៊េងហ្គាមាននៅក្នុងថ្នាក់ហើយ គ្រប់គ្រងថ្នាក់ - - %d ថ្នាក់ - ឈ្មោះនេះមានហើយ! ថ្នាក់ត្រូវបានលុប មានវើសិនបេតាថ្មី! @@ -196,20 +193,11 @@ មិនអាចធ្វើបច្ចុប្បន្នភាពបាន មានក្នុងLocal ស្វែងរក, ថេក(tags), ប្រភព - - លុបភាគ %1$d ដែលបានទាញយកចោល\? - ចេញផ្សាយចប់ហើយ ត្រូវបានបញ្ឈប់ការចេញផ្សាយ ត្រូវបានផ្អាកការចេញផ្សាយ ភាគទី %1$s - - %1$s ភាគ - ភាគទី %1$d នៃ %2$d ភាគ - - នៅសល់%1$d ទំព័រទៀត - បានអានភាគទាំងអស់ តម្រង់ដោយប្រភព អ្នកស្កេន/ក្រុមស្កេន @@ -249,12 +237,9 @@ ត្រូវបានប្រើចុងក្រោយ (បណ្ណាល័យ ឬ ប្រវត្តិ) ផ្លាស់ប្ដូរប្រភព ប្រភពផ្លាស់ប្ដូរ - - %d ភាគបន្ទាប់ដែលមិនទាន់អាន - ស្ថិតិ បរាជ័យក្នុងការឆ្លងកាត់Cloudflare តម្រៀបតម្រងឡើងវិញ មាន %d មិនទាន់អាន មើលរឿងណាមួយ - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/ko/plurals.xml b/i18n/src/commonMain/moko-resources/ko/plurals.xml new file mode 100644 index 0000000000..1c5e70bd8d --- /dev/null +++ b/i18n/src/commonMain/moko-resources/ko/plurals.xml @@ -0,0 +1,102 @@ + + + + + 소요 시간: %1$s, 발생한 오류: %2$s + + + + %1$s분 후 + + + + %d 카테고리 + + + + %d개의 확장 앱 업데이트가 있습니다 + + + + %d개의 제목 + + + + %1$s장 + + + + 다운로드한 챕터 %1$d개를 제거하시겠습니까\? + + + + %1$d페이지 남음 + + + + 그리고 %1$d개 화 남았다 + + + + %d 확장 앱이 업데이트됨 + + + + %d 업데이트 보류 중 + + + + 읽지 않은 다음 %d 회차 + + + + 소스에 존재하지 않거나 필터링되어 있는 %d개의 회차를 건너뛰었습니다 + + + + %1$d 페이지 + + + + %1$s 회차가 원본에서 제거되었습소스: +\n%2$s +\n +\n다운로드를 삭제하시겠습니까\? + + + + %d 만화가 마이그레이션됨 + + + + %1$d%2$s 만화를 마이그레이션하시겠습니까\? + + + + %1$d%2$s 만화를 복사하시겠습니까\? + + + + 캐시가 지워졌습니다. %d 파일이 삭제되었습니다 + + + + 정리가 완료되었습니다. 제거된 %d 폴더 + + + + %d 언어 + + + + "%d 시리즈 형식" + + + + %d 소스 + + + + %d 상태 + + diff --git a/app/src/main/res/values-ko/strings.xml b/i18n/src/commonMain/moko-resources/ko/strings.xml similarity index 95% rename from app/src/main/res/values-ko/strings.xml rename to i18n/src/commonMain/moko-resources/ko/strings.xml index 30a77582d5..2a88e51313 100644 --- a/app/src/main/res/values-ko/strings.xml +++ b/i18n/src/commonMain/moko-resources/ko/strings.xml @@ -323,9 +323,6 @@ 없음 초기 설정 도움말 없음 - - 소요 시간: %1$s, 발생한 오류: %2$s - 자동 잠금 화면 보안 알림 내용 숨기기 @@ -334,9 +331,6 @@ 밴딩을 줄이지만 성능에 영향을 줄 수 있음 회차 변경 항상 표시 기본값으로 설정 - - %1$s분 후 - 항상 끄기 탭 영역 반전 @@ -345,9 +339,6 @@ 마지막으로 사용 회차 목록 보기 경고 - - %d 카테고리 - 확장 앱 업데이트 앱 정보 읽기 모드 @@ -389,9 +380,6 @@ 파일 선택 어플리케이션이 없습니다 지금 다운로드 시작 뒤로가기 - - %d개의 확장 앱 업데이트가 있습니다 - 세로로 고정 가로로 고정 트래커 사용 @@ -413,9 +401,6 @@ 페이지를 찾을 수 없습니다 없어진 소스: Cloudflare를 통과하지 못했습니다 - - %d개의 제목 - %1$s화 트래커 동기화 새로고침 백업 파일에서 데이터가 복구됩니다. @@ -480,9 +465,6 @@ 터치하여 자세히 알아보기 %1$s 추가… 이동 %1$s위치… - - %1$s장 - 개그 읽지 않은 작품 진행 중 @@ -510,9 +492,6 @@ 챕터가 제거되었습니다. 다운로드된 모든 챕터를 제거할까요\? 출처 순서별 - - 다운로드한 챕터 %1$d개를 제거하시겠습니까\? - 범주 이름은 비워 둘 수 없습니다 새 범주 만들기 새 베타 버전을 사용할 수 있습니다! @@ -523,9 +502,6 @@ 모든 범주 표시 범주 업데이트 대기열에 %1$s 추가 - - %1$d페이지 남음 - %1$s이(가) 이미 큐에 있습니다 새 범주 범주가 비어 있습니다 @@ -590,9 +566,6 @@ 표지 둘레에 윤곽 보기 제한 사항: %1$s 카테고리 깡충 뜀 숨기기 - - 그리고 %1$d개 화 남았다 - 미완성된 목록 대규모 업데이트는 배터리 사용량이 증가하고 느려됨 소스를 일으킬 수 있습니다. 탭하여 자세히 알아보기. 읽지 않은 화 없을 때만 업데이트하기 (완전히 읽기) @@ -651,9 +624,6 @@ 챕터 그룹화 리더 설정 모두에 대해 기본값으로 설정 - - %d 확장 앱이 업데이트됨 - 세로로 두 페이지 분할 두 페이지 분할 단일 페이지 @@ -685,9 +655,6 @@ 읽을 때 미리 로드할 페이지의 양입니다. 값이 높을수록 더 부드러운 읽기 환경이 만들어지며 캐시 및 네트워크 사용량이 높아집니다. 이중 페이지 반전 가져온 시간별로 정렬 - - %d 업데이트 보류 중 - 확장 앱 업데이트됨 첫 번째 페이지를 표지로 설정 첫 페이지 공유 @@ -709,9 +676,6 @@ 단일 페이지로 전환 스마트(페이지 기반) 모든 챕터를 읽은 것으로 표시하시겠습니까\? - - 읽지 않은 다음 %d 회차 - 모든 읽기 챕터 라이브러리에 %1$s를 추가하시겠습니까\? 마이그레이션하지 않음 @@ -729,9 +693,6 @@ 비활성화된 경우 다음 장이 로드되면 전환 페이지를 건너뜁니다 컷아웃 영역 동작 패드 컷아웃 영역 - - 소스에 존재하지 않거나 필터링되어 있는 %d개의 회차를 건너뛰었습니다 - %1$s 정보 읽기 시작 라이브러리에 추가 @@ -764,9 +725,6 @@ 최신: %1$s 수동 검색 보라색 - - %1$d 페이지 - 장 번호별로 정렬 최신 버전에서 가장 오래된 것까지 가장 오래된 것부터 가장 새로운 것까지 @@ -802,16 +760,7 @@ 장 제목 숨기기 소스의 순서에 따라 정렬 소스가 설치되지 않았습니다 - - %1$s 회차가 원본에서 제거되었습소스: -\n%2$s -\n -\n다운로드를 삭제하시겠습니까\? - 제안된 날짜 사용 - - %d 만화가 마이그레이션됨 - 마이그레이션 대상 측면 탐색 사용 읽고 싶어 @@ -821,12 +770,6 @@ 표지를 기반으로 한 테마 버튼 대부분의 페이지 맨 위에 더 크고 확장된 도구 모음 표시(설정에 관계없이 작은 장치에는 표시되지 않음) 모든 챕터를 읽지 않은 것으로 표시하시겠습니까\? - - %1$d%2$s 만화를 마이그레이션하시겠습니까\? - - - %1$d%2$s 만화를 복사하시겠습니까\? - (%1$d 건너뛰기) 스마트(페이지 및 테마 기준) 과거 컷아웃 시작 @@ -860,9 +803,6 @@ 이렇게 하면 다운로드 캐시가 강제로 다시 계산됩니다. 이 앱 외부에서 다운로드를 수정하고 앱에서 다운로드를 선택하려는 경우에 유용합니다 베타 릴리스는 불안정할 수 있으며 앱 데이터를 지워야 할 수 있습니다. 시작 화면으로 다시 누르기 - - 캐시가 지워졌습니다. %d 파일이 삭제되었습니다 - 복원이 이미 진행 중입니다 존재하지 않는 삭제, 부분적으로 다운로드된 항목 및 챕터 폴더 읽기 시작 화면 @@ -964,9 +904,6 @@ 다양한 챕터를 읽은 것으로 표시 방향 사용 - - 정리가 완료되었습니다. 제거된 %d 폴더 - 일부 확장 앱은 외부에서 설치된 경우 자동으로 업데이트되지 않을 수 있습니다 현재 사용 가능한 원본만 마이그레이션에 사용하도록 설정합니다 디스크 공간 부족으로 인해 챕터를 다운로드할 수 없습니다 @@ -1003,20 +940,8 @@ 최근에 업데이트된 항목 보기 앱 잠금 사용 중에는 위젯을 이용할 수 없습니다 이미 서재에 있는 항목 숨기기 - - %d 언어 - 평균 추적 점수 챕터 기록을 기준으로 한 로딩에 걸린 시간 - - "%d 시리즈 형식" - - - %d 소스 - - - %d 상태 - %1$s의 업데이트에 실패했습니다. 현재 필터 상태에서 아무런 정보를 찾지 못 함. 마지막 서재 업데이트: %s @@ -1035,4 +960,4 @@ 서재 항목 디버그 정보 백그라운드 활동 - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/lt/plurals.xml b/i18n/src/commonMain/moko-resources/lt/plurals.xml new file mode 100644 index 0000000000..7c38acac6b --- /dev/null +++ b/i18n/src/commonMain/moko-resources/lt/plurals.xml @@ -0,0 +1,51 @@ + + + + + %d plėtinio atnaujinimas pasiekiamas + %d plėtinių atnaujinimai pasiekiami + %d plėtinių atnaujinimai pasiekiami + + + + %d kategorija + %d kategorijos + %d kategorijos + + + + Dėl %d pavadinimo + Dėl %d pavadinimų + Dėl %d pavadinimo + + + + Atlikta %1$s su %2$s klaida + Atlikta %1$s su %2$s klaidomis + Atlikta %1$s su %2$s klaidomis + + + + Po %1$s minutės + Po %1$s minučių + Po %1$s minučių + + + + Kitas neskaitytas skyrius + Kiti %d neskaityti skyriai + Kiti %d neskaitytų skyrių + + + + %1$s skyrius + %1$s skyriai + %1$s skyriai + + + + Praleidžiamas %d skyrius, arba jo nėra šaltinyje, arba jis buvo nepasirinktas + Praleidžiami %d skyriai, arba jų nėra šaltinyje, arba jie buvo nepasirinkti + Praleidžiamia %d skyrių, arba jų nėra šaltinyje, arba jie buvo nepasirinkti + + diff --git a/app/src/main/res/values-lt/strings.xml b/i18n/src/commonMain/moko-resources/lt/strings.xml similarity index 93% rename from app/src/main/res/values-lt/strings.xml rename to i18n/src/commonMain/moko-resources/lt/strings.xml index b9ad6228ff..5808acad7e 100644 --- a/app/src/main/res/values-lt/strings.xml +++ b/i18n/src/commonMain/moko-resources/lt/strings.xml @@ -21,11 +21,6 @@ Ar tu tuo tikras\? Visa istorija bus prarasta. Šaltiniai Nepatikimas plėtinys - - %d plėtinio atnaujinimas pasiekiamas - %d plėtinių atnaujinimai pasiekiami - %d plėtinių atnaujinimai pasiekiami - Nustatyti kaip viršelį Kitas skyrius nerastas Naudoti šį paveiksliuką kaip viršelį\? @@ -90,21 +85,11 @@ Atsegti Kategorijos Redaguoti kategorijas - - %d kategorija - %d kategorijos - %d kategorijos - Naujinti Nauja versija pasiekiama! Vietinis Skyrių skaičius Įspėjimas: dėl didelių masinių atsisiuntimų šaltiniai gali tapti lėtesni ir (arba) jie blokuoti \"Tachiyomi\". Bakstelėkite , jei norite sužinoti daugiau. - - Dėl %d pavadinimo - Dėl %d pavadinimų - Dėl %d pavadinimo - Nepavyko atnaujinti %1$d Praleistas %1$d naujinys (-iai) Praleista, nes leidinys nebeleidžiamas @@ -151,11 +136,6 @@ Atsarginės kopijos kūrimas / atkūrimas gali veikti netinkamai, jei \"MIUI Optimization\" yra išjungtas. Progresas Baigtas - - Atlikta %1$s su %2$s klaida - Atlikta %1$s su %2$s klaidomis - Atlikta %1$s su %2$s klaidomis - Išvalyti skyriaus talpyklą Išmeskite strigčių žurnalus Įrašyti strigčių žurnalus į failą, kad būtų galima juos bendrinti su kūrėjais @@ -227,11 +207,6 @@ Kas 2 dienas Kas 3 dienas Kas savaitę - - Po %1$s minutės - Po %1$s minučių - Po %1$s minučių - Pasirinkti viršelio vaizdą Pasirinkti atsarginės kopijos failą Nerandama failų rinkiklio programos @@ -339,11 +314,6 @@ \nAr vis dar norite tęsti\? Šaltinis neįdiegtas: %1$s Nėra aprašymo - - Kitas neskaitytas skyrius - Kiti %d neskaityti skyriai - Kiti %d neskaitytų skyrių - Sekimas Sekami Paslaugos @@ -490,22 +460,12 @@ Skaitymo trukmė Praleista, nes serijai nereikia atnaujinimų Netinkama naudotojo agento eilutė - - %1$s skyrius - %1$s skyriai - %1$s skyriai - Populiaru Praleisti pasikartojančius skyrius Leisti naikinti žymėtus skyrius Peržiūrėkite neseniai atnaujintus bibliotekos įrašus Valdiklis nepasiekiamas, kai įjungtas programėlės užraktas Biblioteka paskutinį kartą atnaujinta: %s - - Praleidžiamas %d skyrius, arba jo nėra šaltinyje, arba jis buvo nepasirinktas - Praleidžiami %d skyriai, arba jų nėra šaltinyje, arba jie buvo nepasirinkti - Praleidžiamia %d skyrių, arba jų nėra šaltinyje, arba jie buvo nepasirinkti - Nepavyko pakrauti paveikslėlio Programėlių atnaujinimai Pilka @@ -514,4 +474,4 @@ Bibliotekos įrašai Ištrinkite įrašų istoriją, kurie nėra išsaugoti jūsų bibliotekoje Fono veikla - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/lv/plurals.xml b/i18n/src/commonMain/moko-resources/lv/plurals.xml new file mode 100644 index 0000000000..5eaa15d1b0 --- /dev/null +++ b/i18n/src/commonMain/moko-resources/lv/plurals.xml @@ -0,0 +1,63 @@ + + + + + Pabeigts %1$s ar %2$s kļūdām + Pabeigts %1$s ar %2$s kļūdu + Pabeigts %1$s ar %2$s kļūdām + + + + un vēl %1$d nodaļas + un vēl %1$d nodaļa + un vēl %1$d nodaļas + + + + Palikušas %1$d lapas + Palikusi %1$d lapa + Palikušas %1$d lapas + + + + %1$s nodaļas + %1$s nodaļa + %1$s nodaļas + + + + Pēc %1$s minūtēmPēc %1$s minūtesPēc %1$s minūtēm + + + + + + %d kategoriju%d kategorija%d kategorijas + + + + + + Pieejami %d paplašinājumi atjaunināšanaiPieejams %d paplašinājums atjaunināšanaiPieejami %d paplašinājumi atjaunināšanai + + + + + + Priekš %dPriekš %dPriekš %d + + + + + + Izlaisti %d nodaļu, vai nu to nav avotā, vai arī tie ir izfiltrēti + Izlaists %d nodaļa, vai nu tā nav avotā, vai arī tā ir izfiltrēta + Izlaistas %d nodaļas, vai nu tās nav avotā, vai arī tās ir izfiltrētas + + + + Nākamā nelasītā nodaļa + Nākamā nelasītā nodaļa + Nākamās %d nelasītas nodaļas + + diff --git a/app/src/main/res/values-lv/strings.xml b/i18n/src/commonMain/moko-resources/lv/strings.xml similarity index 93% rename from app/src/main/res/values-lv/strings.xml rename to i18n/src/commonMain/moko-resources/lv/strings.xml index d35f9ec06a..500a97f5aa 100644 --- a/app/src/main/res/values-lv/strings.xml +++ b/i18n/src/commonMain/moko-resources/lv/strings.xml @@ -175,11 +175,6 @@ Dublējums nesatur nekādu mangu. Trūkst avotu: %02d min, %02d sec - - Pabeigts %1$s ar %2$s kļūdām - Pabeigts %1$s ar %2$s kļūdu - Pabeigts %1$s ar %2$s kļūdām - Atvērt žurnālfailu Nākama nodaļa Iepriekšēja nodaļa @@ -188,27 +183,12 @@ \nTam vajadzētu beigties ar .proto.gz vai .json. Ierobežojumi: %1$s Bibliotēkas atjaunināšanas ierobežojumi - - un vēl %1$d nodaļas - un vēl %1$d nodaļa - un vēl %1$d nodaļas - Atrastas jaunas nodaļas Vairāk bibliotēkas iestatījumu Atjauninājums pabeigts Kategorijas nosaukums nevar būt tukšs Pievienot/Rediģēt kategorijas Jauna kategorija - - Palikušas %1$d lapas - Palikusi %1$d lapa - Palikušas %1$d lapas - - - %1$s nodaļas - %1$s nodaļa - %1$s nodaļas - Pēc augšupielādes datuma Pēc nodaļas numura Pēc avota secības @@ -367,11 +347,6 @@ Lejupielādē Lejupielādē jaunās nodaļas Ik pēc 3 dienām - - Pēc %1$s minūtēmPēc %1$s minūtesPēc %1$s minūtēm - - - Pa kreisi Nākamais Normāls @@ -408,11 +383,6 @@ Ik pēc 6 stundām Sāna navigācijas ikonu līdzināšana Notīrīt nodaļas kešatmiņu - - %d kategoriju%d kategorija%d kategorijas - - - Neoficiāls Parklājums Atjaunina statusu, vērtējumu un pēdējo izlasīto nodaļu no sekošanas servisa @@ -494,19 +464,9 @@ Neizdevās atjaunināt vāku Uzstādīt kā noklusējuma Citi - - Pieejami %d paplašinājumi atjaunināšanaiPieejams %d paplašinājums atjaunināšanaiPieejami %d paplašinājumi atjaunināšanai - - - Pieteikties %1$s Manga vāks Izrakstīties - - Priekš %dPriekš %dPriekš %d - - - Nav nākošās nodaļas Nav iepriekšējās nodaļas Ielādē lapas… @@ -548,21 +508,11 @@ Bibliotēka pēdējo reizi atjaunināta: %s Lejupielādēt uz priekšu Logrīks nav pieejams, ja ir iespējota lietotņu bloķēšana - - Izlaisti %d nodaļu, vai nu to nav avotā, vai arī tie ir izfiltrēti - Izlaists %d nodaļa, vai nu tā nav avotā, vai arī tā ir izfiltrēta - Izlaistas %d nodaļas, vai nu tās nav avotā, vai arī tās ir izfiltrētas - RARv5 formāts netiek atbalstīts Populārs Skatiet savus nesen atjauninātos bibliotēkas ierakstus Nederīga lietotāja agent virkne Automātiska lejupielāde lasīšanas laikā - - Nākamā nelasītā nodaļa - Nākamā nelasītā nodaļa - Nākamās %d nelasītas nodaļas - Darbojas tikai ar ierakstiem bibliotēkā un tad, ja pašreizējā un nākamā nodaļa jau ir lejupielādēta Izlaists, jo sērijai nav nepieciešami atjauninājumi Attēlu nevarēja ielādēt @@ -582,4 +532,4 @@ Dzēst vēsturi ierakstiem, kas nav saglabāti jūsu bibliotēkā Atkļūdošanas informācija Fona darbība - \ No newline at end of file + diff --git a/app/src/main/res/values-ars/strings.xml b/i18n/src/commonMain/moko-resources/mn/plurals.xml similarity index 60% rename from app/src/main/res/values-ars/strings.xml rename to i18n/src/commonMain/moko-resources/mn/plurals.xml index a6b3daec93..045e125f3d 100644 --- a/app/src/main/res/values-ars/strings.xml +++ b/i18n/src/commonMain/moko-resources/mn/plurals.xml @@ -1,2 +1,3 @@ - \ No newline at end of file + + diff --git a/app/src/main/res/values-mn/strings.xml b/i18n/src/commonMain/moko-resources/mn/strings.xml similarity index 100% rename from app/src/main/res/values-mn/strings.xml rename to i18n/src/commonMain/moko-resources/mn/strings.xml diff --git a/i18n/src/commonMain/moko-resources/ms/plurals.xml b/i18n/src/commonMain/moko-resources/ms/plurals.xml new file mode 100644 index 0000000000..f76c53e464 --- /dev/null +++ b/i18n/src/commonMain/moko-resources/ms/plurals.xml @@ -0,0 +1,101 @@ + + + + + %d kemas kini sambungan tersedia + + + + dan %1$d lebih + + + + Untuk %d + + + + %1$d halaman yang tinggal + + + + Buang %1$d bab yang dimuat turun\? + + + + Selepas %1$s + + + + Pembersihan selesai. Di buang %d folder + + + + Chache di bersihkan. %d fail telah di + + + + %d manga di + + + + Salin %1$d%2$s manga\? + + + + Pindah %1$d%2$s manga\? + + + + %1$s bab telah dibuang daripada sumber: +\n%2$s +\nPadam muat turun\? + + + + %d kategori + + + + Selesai dalam %1$s dengan %2$s ralat + + + + %1$s bab + + + + %1$d halaman + + + + Melangkau %d bab, sama ada sumber tidak mempunyai bab tersebut, atau ia ditapis keluar + + + + %d kemas kini belum selesai + + + + %d sambungan dikemas kini + + + + %d bab tidak dibaca seterusnya + + + + %d jenis siri + + + + %d sumber + + + + %d status + + + + %d bahasa + + diff --git a/app/src/main/res/values-ms/strings.xml b/i18n/src/commonMain/moko-resources/ms/strings.xml similarity index 95% rename from app/src/main/res/values-ms/strings.xml rename to i18n/src/commonMain/moko-resources/ms/strings.xml index 7c73ba2a1e..3e709d78c5 100644 --- a/app/src/main/res/values-ms/strings.xml +++ b/i18n/src/commonMain/moko-resources/ms/strings.xml @@ -321,18 +321,9 @@ Semak laman web dalam WebView Usang Sambungan ini tidak lagi ada. - - %d kemas kini sambungan tersedia - Kurangkan jalinan, tapi memberi kesan kepada prestasi Lingkau bab yang ditapis Menegak berterusan - - dan %1$d lebih - - - Untuk %d - Lagi tetapan pustaka Sembunyikan corong kategori Paparkan sebagai @@ -370,12 +361,6 @@ Cipta kategori baharu %1$s sudah tersedia di barisan Menambah %1$s kepada barisan kemas kini - - %1$d halaman yang tinggal - - - Buang %1$d bab yang dimuat turun\? - Bab tidak dijumpai Bab dibuang. Penanda buku dibuang @@ -421,9 +406,6 @@ Heret Muat turun yang belum dibaca Di padam: %1$s - - Selepas %1$s - Sentiasa Sentiasa Padam ketika muat turun global, berdasarkan muka surat @@ -452,9 +434,6 @@ Padam cached covers lama dan tidak di guna di dalam pustaka yang telah di kemas kini. \nTengah digunakan: %1$s Bersihkan cached - - Pembersihan selesai. Di buang %d folder - Nyahaktif ini jikalau anda mengalaki isu dengan mengemas kini atau memulihkan pustaka anda Tiada folder untuk di Memulakan @@ -463,23 +442,11 @@ Bersihkan orphaned Padam tidak-wujud, terutama muat turun, and folder bab yang di baca Bersihkan bab yang telah di muat - - Chache di bersihkan. %d fail telah di - Pengurusan Tidak terlog masuk ke %1$s Gagal memulihkan sandaran Pure White - - %d manga di - (Melangkah %1$d) - - Salin %1$d%2$s manga\? - - - Pindah %1$d%2$s manga\? - Hentikan perpindahan\? Tiada Alternatif Di Tiada bab di jumpai, manga ini tidak boleh di gunakan untuk @@ -506,11 +473,6 @@ Sedang dibaca Tidak dijejaki Dijejaki - - %1$s bab telah dibuang daripada sumber: -\n%2$s -\nPadam muat turun\? - Ralat berkongsi muka hadapan Ralat menyimpan muka hadapan Muka hadapan disimpan @@ -565,9 +527,6 @@ Tag Bawah Pemindahan - - %d kategori - Buka kunci Sambungan ini bukan daripada senarai sambungan Tachiyomi yang rasmi. 18+ @@ -607,9 +566,6 @@ \nAnda perlu memasang sambungan yang hilang dan log masuk ke penjejakan untuk menggunakannya. Pemulih dibatalkan %02d minit, %02d saat - - Selesai dalam %1$s dengan %2$s ralat - Tiada aplikasi memilih fail Seterusnya Buka log @@ -617,9 +573,6 @@ Papar lambang belum dibaca Sembunyi Lambang belum dibaca Kategori - - %1$s bab - Selesai Log kerosakan Kumpulan log kerosakan @@ -674,9 +627,6 @@ Mod inkognito Matikan %s Hidupkan %s - - %1$d halaman - Automatik(bedasarkan susunan) Apabila menggunakan halaman automatik, anda boleh menukar antara corak ketika membaca tanpa menukar tetapan ini Corak halaman @@ -763,9 +713,6 @@ Sumber tidak disokong Sembunyikan kandungan pemberitahuan Sesetengah pengeluar ada sekatan tambahan pada aplikasi yang akan menghentikan perkidmatan latar belakang. Laman web ini ada maklumat cara membaikinya. - - Melangkau %d bab, sama ada sumber tidak mempunyai bab tersebut, atau ia ditapis keluar - Mengikut nombor bab Tetapkan sebagai lalai Yotsuba @@ -875,9 +822,6 @@ Tambah label Kemas kini jejakan selepas membaca Kemas kini jejakan selepas ditanda sebagai dibaca - - %d kemas kini belum selesai - Chocolate Strawberries Teal Ocean Sapphire Dusk @@ -893,14 +837,8 @@ Sesetengah sambungan mungkin masih memerlukan prom untuk dipasang dahulu. Mengemas kini sambungan Sambungan dikemas kini - - %d sambungan dikemas kini - Halaman maklumat entri ini perlu dilihat sebelum dibolehkan untuk migrasi Classic Blue - - %d bab tidak dibaca seterusnya - Semua manga dibaca Tema cerah A Brighter You (Dinamik) @@ -986,19 +924,7 @@ Panjang Tahun mula Tiada data dijumpai untuk tapisan semasa anda - - %d jenis siri - - - %d sumber - - - %d status - Judul tempatan - - %d bahasa - Tag Judul dalam pustaka Judul dijejak @@ -1024,4 +950,4 @@ Entri pustaka Maklumat nyahpepijat Aktiviti latar belakang - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/my/plurals.xml b/i18n/src/commonMain/moko-resources/my/plurals.xml new file mode 100644 index 0000000000..ec069b8248 --- /dev/null +++ b/i18n/src/commonMain/moko-resources/my/plurals.xml @@ -0,0 +1,19 @@ + + + + + အမျိုးအစား %d ခု + + + + စာမျက်နှာ %1$d ခုကျန်သေးသည် + + + + %1$s ပိုင်း + + + + ဒေါင်းလုဒ်ဆွဲထားတဲ့အပိုင်း %1$d ပိုင်းကိုဖျက်ပစ်မှာလား + + diff --git a/app/src/main/res/values-my/strings.xml b/i18n/src/commonMain/moko-resources/my/strings.xml similarity index 97% rename from app/src/main/res/values-my/strings.xml rename to i18n/src/commonMain/moko-resources/my/strings.xml index 796606ec7a..809228610c 100644 --- a/app/src/main/res/values-my/strings.xml +++ b/i18n/src/commonMain/moko-resources/my/strings.xml @@ -25,9 +25,6 @@ အမျိုးအစားကို ဖျက်ပစ်လိုက်သည် အမျိုးအစားအမည်ကို ကွက်လပ်ထားလို့မရပါ အဲ့ဒီနာမည်နဲ့အမျိုးအစားက ရှိပြီးသားဖြစ်ပါတယ်။ - - အမျိုးအစား %d ခု - အမျိုးအစားများသို့ရွှေ့မည် အမျိုးအစားကိုစီမံမယ် အမျိုးအစားများပြင်ဆင်မည် @@ -43,15 +40,6 @@ %1$s က စာရင်းထဲမှာရှိပြီးသားဖြစ်ပါတယ် အမျိုးအစားများ အမျိုးအစား - - စာမျက်နှာ %1$d ခုကျန်သေးသည် - - - %1$s ပိုင်း - - - ဒေါင်းလုဒ်ဆွဲထားတဲ့အပိုင်း %1$d ပိုင်းကိုဖျက်ပစ်မှာလား - မည်သည့်စာမျက်နှာမျှရှာမတွေ့ပါ မည်သည့်အပိုင်းမျှမရှိပါ ဤအပိုင်းကိုရှာမတွေ့ပါ @@ -231,4 +219,4 @@ သက်တောင့်သက်သာရှိသော လေးထောင့်ပုံစံ ကျစ်ကျစ်လစ်လစ်ရှိသော လေးထောင့်ပုံစံ အပ်ဒိတ်အများအပြားလုပ်ခြင်းအားဖြင့် ဘက်ထရီသုံးစွဲမှု ပိုမိုများပြားစေသည့်အပြင် ရင်းမြစ်များကြည့်ရှုရာတွင်လည်း ပိုမိုနှေးကွေးစေနိုင်ပါသည်။ ပိုမိုသိရှိရန် ဤနေရာကိုနှိပ်ပါ။ - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/nb-rNO/plurals.xml b/i18n/src/commonMain/moko-resources/nb-rNO/plurals.xml new file mode 100644 index 0000000000..3ff93df564 --- /dev/null +++ b/i18n/src/commonMain/moko-resources/nb-rNO/plurals.xml @@ -0,0 +1,129 @@ + + + + + Utvidelsesoppdatering tilgjengelig + %d utvidelsesoppdateringer tilgjengelige + + + + Gjort på %1$s med %2$s feil + Gjort på %1$s med %2$s feil + + + + %d kategori + %d kateogrier + + + + Fjern %1$d nedlastet kapittel\? + Fjern %1$d nedlastede kapitler\? + + + + Hopper over %d kapittel, enten så mangler kilden den eller så har den blitt filtrert ut + Hopper over %d kapitler, enten så mangler kilden de eller så har de blitt filtrert ut + + + + For én tittel + For %d titler + + + + %1$d side igjen + %1$d sider igjen + + + + %1$s kapittel + %1$s kapitler + + + + kapittel har blitt fjernet fra denne kilden +\n%2$s +\n +\nSlett nedlastningen av det\? + %1$s kapitler har blitt fjernet fra denne kilden +\n%2$s +\n +\nSlett nedlastningenene av dem\? + + + + Opprenskning ferdig. Fjernet én mappe + Opprenskning ferdig. Fjernet %d mapper + + + + og %1$d kapittel til + og %1$d kapitler til + + + + Hurtiglager tømt. %d fil har blitt slettet. + Hurtiglager tømt. %d filer har blitt slettet. + + + + Etter %1$s minutt + Etter %1$s minutter + + + + %d manga flyttet + %d manga flyttet + + + + Kopier %1$d%2$s manga\? + Kopier %1$d%2$s manga\? + + + + Flytt %1$d%2$s manga\? + Flytt %1$d%2$s manga\? + + + + %1$d side + %1$d sider + + + + Utvidelse oppdatert + %d utvidelser oppdatert + + + + %d oppdatering venter + %d oppdateringer venter + + + + Neste uleste kapittel + Neste %d uleste kapitler + + + + %d språk + %d språk + + + + %d serietype + %d serietyper + + + + %d status + %d statuser + + + + %d kilde + %d kilder + + diff --git a/app/src/main/res/values-nb-rNO/strings.xml b/i18n/src/commonMain/moko-resources/nb-rNO/strings.xml similarity index 93% rename from app/src/main/res/values-nb-rNO/strings.xml rename to i18n/src/commonMain/moko-resources/nb-rNO/strings.xml index 19525cc915..845c370d97 100644 --- a/app/src/main/res/values-nb-rNO/strings.xml +++ b/i18n/src/commonMain/moko-resources/nb-rNO/strings.xml @@ -275,10 +275,6 @@ Sjekk nettsted i nettvisning Foreldet Denne utvidelsen er ikke lenger tilgjengelig. - - Utvidelsesoppdatering tilgjengelig - %d utvidelsesoppdateringer tilgjengelige - Reduserer sjattering, men koster ytelse Hopp over filtrerte kapittel Kontinuerlig loddrett @@ -323,10 +319,6 @@ Manglende kilder: Avbrutt gjenoppretting %02d min, %02d sek - - Gjort på %1$s med %2$s feil - Gjort på %1$s med %2$s feil - Hva er nytt merker Sist brukt @@ -340,10 +332,6 @@ Søkeinnstillinger Språk Ugyldig sikkerhetskopieringsfil - - %d kategori - %d kateogrier - Sikkerhetskopier og gjenopprett Framdrift Fullført @@ -441,10 +429,6 @@ Opprett ny kategori %1$s er allerede i køen Legger til %1$s i oppdateringskø - - Fjern %1$d nedlastet kapittel\? - Fjern %1$d nedlastede kapitler\? - Etter opplastingsdato Etter kapittelnummer Etter kildens rekkefølge @@ -471,10 +455,6 @@ Leser Kilde ikke installert Legg til i bibliotek - - Hopper over %d kapittel, enten så mangler kilden den eller så har den blitt filtrert ut - Hopper over %d kapitler, enten så mangler kilden de eller så har de blitt filtrert ut - Liggende Stående I biblioteket @@ -485,10 +465,6 @@ Lås opp Nylig tillagt Sorter ved å ignorere artikler - - For én tittel - For %d titler - %d per rad Dra og slipp Dato innhentet @@ -514,14 +490,6 @@ Ingen samsvar med dine filtre Vis tomme kategorier under filtrering Kategori - - %1$d side igjen - %1$d sider igjen - - - %1$s kapittel - %1$s kapitler - Legg til luft rundt utklippsområder Manga i denne kategorien vil bli flyttet inn i den forvalgte kategorien. Seriesnarveier åpner nye kapitler @@ -536,16 +504,6 @@ Utgivelsesside Tegneserie Alle kapitler lest - - kapittel har blitt fjernet fra denne kilden -\n%2$s -\n -\nSlett nedlastningen av det\? - %1$s kapitler har blitt fjernet fra denne kilden -\n%2$s -\n -\nSlett nedlastningenene av dem\? - Marker en serie av kapitler som ulest Marker en serie av kapitler som lest Kun skru på de kildene du har satt på nå for flytting @@ -556,10 +514,6 @@ Noen utvidelser kan kanskje ikke oppdateres automatisk hvis de ble installert utenfor programmet Varsle om oppdaterte utvidelser Oppdater utvidelser automatisk - - Opprenskning ferdig. Fjernet én mappe - Opprenskning ferdig. Fjernet %d mapper - Skru av dette hvis du har problemer med oppdatering eller gjenoppretting av biblioteket ditt Ingen mapper krever opprydding Starter opprenskning @@ -601,10 +555,6 @@ Gjenoppfrisk omslag i biblioteket også ved oppdatering av bibliotek Gjenoppfrisk omslag automatisk Begrensninger: %1$s - - og %1$d kapittel til - og %1$d kapitler til - Utvid/fold sammen alle kategorier Kunne ikke installere oppdatering Slett alle omslag i hurtiglager som ikke er i biblioteket. @@ -613,10 +563,6 @@ Rydd opp i hurtigbufferede omslag som ikke er i bruk for oppdaterte manga i biblioteket ditt. \nBruker nå: %1$s Tøm hurtiglagrede omslag - - Hurtiglager tømt. %d fil har blitt slettet. - Hurtiglager tømt. %d filer har blitt slettet. - Dette påtvinger ny utregning av nedlastingshurtiglageret. Nyttig hvis du har endret nedlastninger utenfor programmet og ønsker at programmet skal plukke dem opp. Gjenopfrisk nedlastingshurtiglageret Mengden sider å forhåndsinnlaste under lesing. Høyere verdier gir glattere leseopplevelse, på bekostning av høyere hurtiglater- og nettverksbruk. @@ -653,10 +599,6 @@ Bunnen BETA Lagt til i %1$s - - Etter %1$s minutt - Etter %1$s minutter - Automatisk fjerning Alltid slett Alltid behold @@ -689,19 +631,7 @@ Skru av %s Skru på %s Utseende - - %d manga flyttet - %d manga flyttet - (hopper over %1$d) - - Kopier %1$d%2$s manga\? - Kopier %1$d%2$s manga\? - - - Flytt %1$d%2$s manga\? - Flytt %1$d%2$s manga\? - Stopp flytting\? Fant ingen alternativer Ingen kapitler funnet, denne mangaen kan ikke flyttes over @@ -749,10 +679,6 @@ Marker alle kapitler som lest\? Sesong %1$d Om denne %1$s - - %1$d side - %1$d sider - Vis ved langtrykk Automatisk (basert på sideretning) Ventende utvidelsesoppdateringer @@ -773,15 +699,7 @@ Sider %1$s Sett som forvalg for alle Leseinnstillinger - - Utvidelse oppdatert - %d utvidelser oppdatert - Utvidelser oppdatert - - %d oppdatering venter - %d oppdateringer venter - Oppdater alle Kunne ikke installere utvidelse %1$s må skrus på først @@ -961,10 +879,6 @@ Uferdig liste Forbedrer leserytelsen Leseliste - - Neste uleste kapittel - Neste %d uleste kapitler - Ønskeliste Komplett liste Standard streng for brukeragent @@ -988,10 +902,6 @@ Se de nylig oppdaterte biblotekoppføringene dine Moduler er ikke tilgjengelig når applås er aktivert Skjul oppføringer som allerede er i biblioteket - - %d språk - %d språk - Etiketter Visse språk kan kreve at appen startes på nytt for å vises riktig Titler i biblioteket @@ -1007,24 +917,12 @@ Åpne i app Zoom inn på dobbeltsideoppsett Å gå tilbake til forrige produksjonsversjon kan føre til problemer og kreve sletting av appdata. - - %d serietype - %d serietyper - Skjul grupperte kapitler Vis flere kapitler Kunne ikke oppdatere %1$s Vis en større, utvidet verktøylinje øverst på de fleste sider (vises ikke på mindre enheter uansett innstilling) Betaversjoner kan være ustabile og kreve at appdata slettes. Test nye funksjoner før de lanseres offisielt. Betaversjoner kan være ustabile og brukes for å gi tilbakemeldinger til utvikleren. - - %d status - %d statuser - - - %d kilde - %d kilder - Startår Kilde Antall @@ -1063,4 +961,4 @@ Programinnstillinger Debug info Bakgrunnsaktivitet - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/ne/plurals.xml b/i18n/src/commonMain/moko-resources/ne/plurals.xml new file mode 100644 index 0000000000..a4e8ee3263 --- /dev/null +++ b/i18n/src/commonMain/moko-resources/ne/plurals.xml @@ -0,0 +1,128 @@ + + + + + %d वर्ग + %d वर्गहरू + + + + %1$s अध्याय + %1$s अध्यायहरू + + + + एक्सटेन्शन अपडेट उपलब्ध छ + %d एक्सटेन्शन अपडेटहरू उपलब्ध छन् + + + + अर्को नपढिएको अध्याय + अर्को %d नपढिएका अध्यायहरू + + + + %2$s त्रुटिको साथ %1$s मा सम्पन्न भयो + %2$s त्रुटिहरूसँग %1$s मा सम्पन्न भयो + + + + %1$s मिनेट पछि + %1$s मिनेट पछि + + + + %d अध्याय छोड्दै, या त स्रोत सँग छैन वा यसलाई फिल्टर गरिएको छ + %d अध्यायहरू छोड्दै, या त स्रोत सँग छैन वा यसलाई फिल्टर गरिएको छ + + + + श्रृङ्खला प्रकार + %d श्रृङ्खला प्रकारहरू + + + + स्रोत + %d स्रोतहरू + + + + भाषा + %d भाषाहरू + + + + %1$d पृष्ठ बाँकी छ + %1$d पृष्ठहरू बाँकी छन् + + + + %1$d डाउनलोड गरिएको अध्याय हटाउनुहुन्छ\? + %1$d डाउनलोड गरिएका अध्यायहरू हटाउनुहुन्छ\? + + + + %d अपडेट विचाराधीन + %d अपडेटहरू विचाराधीन छन् + + + + %d शीर्षकको लागि + %d शीर्षकहरूको लागि + + + + र थप %1$d अध्याय + र थप %1$d अध्यायहरू + + + + एक्सटेन्शन अपडेट गरियो + %d एक्सटेन्शनहरू अपडेट गरियो + + + + %1$d पृष्ठ + %1$d पृष्ठहरू + + + + स्रोतबाट एउटा अध्याय हटाइयो: +\n%2$s +\nयसको डाउनलोड हटाउने हो\? + %1$s अध्यायहरू स्रोतबाट हटाइएका छन्: +\n%2$s +\n +\nतिनीहरूका डाउनलोडहरू हटाउने हो\? + + + + %d श्रृङ्खला स्थानान्तरण भयो + %d श्रृङ्खला स्थानान्तरण भयो + + + + %1$d%2$s श्रृङ्खला प्रतिलिपि गर्ने हो\? + %1$d%2$s श्रृङ्खला प्रतिलिपि गर्ने हो\? + + + + %1$d%2$s श्रृङ्खला स्थानान्तरण गर्ने हो\? + %1$d%2$s श्रृङ्खला स्थानान्तरण गर्ने हो\? + + + + सफाई सक्यो। %d फोल्डर हटाइयो + सफाई सक्यो। %d फोल्डरहरू हटाइयो + + + + स्थिति + %d स्थितिहरू + + + + क्यास खाली गरियो। %d फाइल मेटाइएको छ + क्यास खाली गरियो। %d फाइलहरू मेटिएका छन् + + diff --git a/app/src/main/res/values-ne/strings.xml b/i18n/src/commonMain/moko-resources/ne/strings.xml similarity index 94% rename from app/src/main/res/values-ne/strings.xml rename to i18n/src/commonMain/moko-resources/ne/strings.xml index 332657d3e0..1481cd0dd2 100644 --- a/app/src/main/res/values-ne/strings.xml +++ b/i18n/src/commonMain/moko-resources/ne/strings.xml @@ -3,10 +3,6 @@ पढेको कुनै पृष्ठहरू फेला परेन वर्गहरू सम्पादन गर्नुहोस् - - %d वर्ग - %d वर्गहरू - अपडेट नयाँ संस्करण उपलब्ध छ! कुनै नयाँ अपडेट उपलब्ध छैन @@ -82,10 +78,6 @@ RARv5 समर्थित छैन अध्याय संख्या द्वारा अपलोड मिति द्वारा - - %1$s अध्याय - %1$s अध्यायहरू - वर्गहरू वर्ग खाली छ पूर्वनिर्धारित वर्ग @@ -142,10 +134,6 @@ अनौपचारिक एप जानकारी सबै अपडेट गर्नुहोस् - - एक्सटेन्शन अपडेट उपलब्ध छ - %d एक्सटेन्शन अपडेटहरू उपलब्ध छन् - आवरणको रूपमा सेट गर्नुहोस् सकिएको: हालको: @@ -228,10 +216,6 @@ स्रोत स्थापना गरिएको छैन: %1$s कुनै वर्णन छैन पुस्तकालयबाट हटाउनुहोस् - - अर्को नपढिएको अध्याय - अर्को %d नपढिएका अध्यायहरू - आवरण सेभ गर्दा त्रुटि भयो आवरण साझा गर्दा त्रुटि भयो पूर्वनिर्धारित रूपमा सेट गर्नुहोस् @@ -304,10 +288,6 @@ %02d मिनेट, %02d सेकेन्ड यदि MIUI अप्टिमाइजेसन असक्षम छ भने ब्याकअप/रिस्टोरले राम्ररी काम नगर्न सक्छ। पूरा - - %2$s त्रुटिको साथ %1$s मा सम्पन्न भयो - %2$s त्रुटिहरूसँग %1$s मा सम्पन्न भयो - अध्याय क्यास खाली गर्नुहोस् क्र्यास लगहरू क्र्यास लगहरू डम्प गर्नुहोस् @@ -377,10 +357,6 @@ प्रत्येक २ दिन प्रत्येक ३ दिन साप्ताहिक - - %1$s मिनेट पछि - %1$s मिनेट पछि - आवरण छवि चयन गर्नुहोस् ब्याकअप फाइल चयन गर्नुहोस् कुनै फाइल पिकर एप फेला परेन @@ -471,10 +447,6 @@ अध्यायहरू हटाइयो। अनलक गर्न आवश्यक छ सबै डाउनलोडहरू हटाउने हो\? - - %d अध्याय छोड्दै, या त स्रोत सँग छैन वा यसलाई फिल्टर गरिएको छ - %d अध्यायहरू छोड्दै, या त स्रोत सँग छैन वा यसलाई फिल्टर गरिएको छ - ब्याकअप पहिले नै प्रगतिमा छ TachiyomiJ2K लाई अध्यायहरू डाउनलोड गर्न, स्वचालित ब्याकअपहरू सिर्जना गर्न र लोकल श्रृङ्खला पढ्नको लागि Android 11 मा सबै फाइलहरू माथि पहुँच चाहिन्छ। \n @@ -493,18 +465,6 @@ तथ्याङ्क विवरण हेर्नुहोस् सुरु गरेको वर्ष तपाईंको हालको फिल्टरहरूको लागि कुनै डेटा फेला परेन - - श्रृङ्खला प्रकार - %d श्रृङ्खला प्रकारहरू - - - स्रोत - %d स्रोतहरू - - - भाषा - %d भाषाहरू - तान्ने र छोड्ने तथ्याङ्क तथ्याङ्क @@ -515,10 +475,6 @@ पुस्तकालयमा राख्नुहोस् छवि लोड गर्न सकिएन पुस्तकचिनो लगाइएका अध्यायहरू बाहेक सबै - - %1$d पृष्ठ बाँकी छ - %1$d पृष्ठहरू बाँकी छन् - %1$sलाई अपडेट लाममा थप्दै वर्ग %1$s पहिले नै लाममा छ @@ -542,10 +498,6 @@ सधैं हालको वर्ग देखाउनुहोस् कस्टम रङ फिल्टर प्रयोग गर्नुहोस् पुस्तकचिनो लगाइएको अध्यायहरू देखाउनुहोस् - - %1$d डाउनलोड गरिएको अध्याय हटाउनुहुन्छ\? - %1$d डाउनलोड गरिएका अध्यायहरू हटाउनुहुन्छ\? - नयाँ वर्ग सिर्जना गर्नुहोस् हटाउन को लागी कुनै अध्याय छैन स्क्यानलेटरहरू @@ -603,10 +555,6 @@ एक्सटेन्शन स्थापना गर्न सकिएन केही एक्सटेन्शनहरू अझै पनि पहिले स्थापना गर्न प्रम्प्ट हुन सक्छ। एक्सटेन्शनहरू अपडेट गर्दै - - %d अपडेट विचाराधीन - %d अपडेटहरू विचाराधीन छन् - एक्सटेन्शनहरू अपडेट गरियो पढ्न सुरु गर्नुहोस् वर्ग हपर लामो प्रेस कार्य @@ -666,14 +614,6 @@ वर्ग हपर लुकाउनुहोस् डबल पृष्ठ सार्नुहोस् थप पुस्तकालय सेटिङहरू - - %d शीर्षकको लागि - %d शीर्षकहरूको लागि - - - र थप %1$d अध्याय - र थप %1$d अध्यायहरू - पुस्तकालय अपडेट गर्दा आवरणहरू पनि रिफ्रेस गर्नुहोस् शीर्षकहरू अपडेट गर्न छोड्नुहोस् नपढिएको अध्याय नभएमा मात्र श्रृङ्खला अपडेट गर्नुहोस् (पुरै पढिसकेको) @@ -687,10 +627,6 @@ %1$s पढेको अपडेट गरिएको समय देखाउनुहोस् सबै स्रोतहरू - - एक्सटेन्शन अपडेट गरियो - %d एक्सटेन्शनहरू अपडेट गरियो - यसलाई परिवर्तन गर्नाले यो श्रृङ्खलाको लागि पढ्ने मोड रिसेट हुनेछ पहिलो पृष्ठ आवरणको रूपमा सेट गर्नुहोस् पहिलो पृष्ठ साझा गर्नुहोस् @@ -704,24 +640,11 @@ पोर्ट्रेटमा डबल पृष्ठ विभाजित गर्नुहोस् तेर्सो रूपमा ठाडो रूपमा - - %1$d पृष्ठ - %1$d पृष्ठहरू - यस बारे %1$s तपाईको पुस्तकालयमा एउटै नामको इन्ट्री छ तर फरक स्रोतबाट (%1$s)। \n \nके तपाईं अझै जारी राख्न चाहनुहुन्छ\? %1$s क्लिपबोर्डमा प्रतिलिपि गरियो - - स्रोतबाट एउटा अध्याय हटाइयो: -\n%2$s -\nयसको डाउनलोड हटाउने हो\? - %1$s अध्यायहरू स्रोतबाट हटाइएका छन्: -\n%2$s -\n -\nतिनीहरूका डाउनलोडहरू हटाउने हो\? - पढिएको चिन्ह लगाउँदा ट्र्याकिङ अपडेट गर्नुहोस् सेवाहरू जसले विशिष्ट स्रोतहरूको लागि परिष्कृत सुविधाहरू प्रदान गर्दछ। तपाईंको पुस्तकालयमा श्रृङ्खला थप्दा स्वतः ट्र्याक गरिन्छ। पढिसकेपछि ट्र्याकिङ अपडेट गर्नुहोस् @@ -737,14 +660,6 @@ अर्को पटक यो स्टेप छोड्नुहोस् यो स्क्रिन फेरि देखाउन, सेटिङहरू -> स्रोतहरूमा जानुहोस्। नवीनतम: %1$s - - %d श्रृङ्खला स्थानान्तरण भयो - %d श्रृङ्खला स्थानान्तरण भयो - - - %1$d%2$s श्रृङ्खला प्रतिलिपि गर्ने हो\? - %1$d%2$s श्रृङ्खला प्रतिलिपि गर्ने हो\? - अँध्यारो एक उज्ज्वल तपाईं (डायनामिक) एक शान्त तपाईं (डायनामिक) @@ -829,10 +744,6 @@ टिल महासागर नीलमणि साँझ बैंगनी - - %1$d%2$s श्रृङ्खला स्थानान्तरण गर्ने हो\? - %1$d%2$s श्रृङ्खला स्थानान्तरण गर्ने हो\? - एप अपडेटहरू आवरणमा आधारित थीम बटनहरू हालको श्रृङ्खला देखाउनुहोस् @@ -947,10 +858,6 @@ पढिएको सफा गर्नुहोस् पुस्तकालयमा नभएको इन्ट्री सफा गर्नुहोस् सफाई सुरु गर्दैछ - - सफाई सक्यो। %d फोल्डर हटाइयो - सफाई सक्यो। %d फोल्डरहरू हटाइयो - अधिकांश इन्ट्रीहरू एक्सटेन्शन स्वत: अपडेट गर्नुहोस् एक्सटेन्शन अपडेट गरिएको छ भनि सूचना दिनुहोस् @@ -1002,10 +909,6 @@ रोटेशन औसत ट्र्याकिङ स्कोर रिडरमा बिताएको समय (अध्याय इतिहासमा आधारित) - - स्थिति - %d स्थितिहरू - अन्तिम पढिएको अध्याय भन्दा ३ अध्याय अघि अन्तिम पढिएको अध्याय भन्दा ४ अध्याय अघि गणना @@ -1015,10 +918,6 @@ अघिल्लो उत्पादन संस्करणमा रोल ब्याक गर्दा समस्याहरू हुन सक्छ र एप डेटा खाली गर्न आवश्यक हुन सक्छ। डेटा व्यवस्थापन बीटा रिलीजका लागि जाँच गर्नुहोस् - - क्यास खाली गरियो। %d फाइल मेटाइएको छ - क्यास खाली गरियो। %d फाइलहरू मेटिएका छन् - डेटाबेसमा %1$d गैर-पुस्तकालय इन्ट्रीहरू छन् पुस्तकालयमा नभएका इन्ट्रीको इतिहास हटाउनुहोस् पढिएका अध्यायहरू भएको इन्ट्री राख्नुहोस् @@ -1063,4 +962,4 @@ एप सेटिङहरू Debug जानकारी ब्याकग्राउण्ड गतिविधि - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/nl/plurals.xml b/i18n/src/commonMain/moko-resources/nl/plurals.xml new file mode 100644 index 0000000000..fca879e264 --- /dev/null +++ b/i18n/src/commonMain/moko-resources/nl/plurals.xml @@ -0,0 +1,128 @@ + + + + + Extensie-update beschikbaar + %d extensie-updates beschikbaar + + + + Na %1$s minuut + Na %1$s minuten + + + + en %1$d nog hoofdstuk + en %1$d nog hoofdstukken + + + + Voor %d titel + Voor %d titels + + + + %d categorie + %d categorieën + + + + %1$d pagina over + %1$d paginas over + + + + Verwijder %1$d gedownload hoofdstuk\? + Verwijder %1$d gedownloade hoofdstukken\? + + + + Schoonmaak klaar. %d map verwijderd + Schoonmaak klaar. %d mappen verwijderd + + + + Cache geleegd. %d bestand is verwijderd + Cache geleegd. %d bestanden zijn verwijderd + + + + %d manga gemigreerd + %d manga gemigreerd + + + + %1$d%2$s manga kopiëren\? + %1$d%2$s manga kopiëren\? + + + + %1$d%2$s manga migreren\? + %1$d%2$s manga migreren\? + + + + Een hoofdstuk is verwijderd uit de bron: +\n%2$s +\nDownload van dit hoofdstuk verwijderen\? + %1$s hoofdstukken zijn verwijderd uit de bron: +\n%2$s +\n +\nDownloads van deze hoofdstukken verwijderen\? + + + + Voltooid in %1$s met %2$s foutmelding + Voltooid in %1$s met %2$s foutmeldingen + + + + %1$s hoofdstuk + %1$s hoofdstukken + + + + %1$d pagina + %1$d pagina\'s + + + + %d wachtende update + %d wachtende updates + + + + Extensie bijgewerkt + %d extensies bijgewerkt + + + + 1 hoofdstuk is overgeslagen, de bron mist 1 hoofdstuk of het is uitgefilterd + %d hoofdstukken zijn overgeslagen, de bron mist ze of ze zijn uitgefilterd + + + + Volgende ongelezen hoofdstuk + Volgende aantal %d ongelezen hoofdstukken + + + + + %d serie types + + + + + %d bronnen + + + + + %d statussen + + + + + %d talen + + diff --git a/app/src/main/res/values-nl/strings.xml b/i18n/src/commonMain/moko-resources/nl/strings.xml similarity index 93% rename from app/src/main/res/values-nl/strings.xml rename to i18n/src/commonMain/moko-resources/nl/strings.xml index 45df81c7ad..12acadcaff 100644 --- a/app/src/main/res/values-nl/strings.xml +++ b/i18n/src/commonMain/moko-resources/nl/strings.xml @@ -275,10 +275,6 @@ Bekijk website in WebView Verouderd Deze extensie is niet meer beschikbaar. - - Extensie-update beschikbaar - %d extensie-updates beschikbaar - Vermindert banderolleren, maar kan de prestaties beïnvloeden Mengmodus kleurfilter Tegenhouden / Lichter @@ -344,10 +340,6 @@ Download ongelezen Verwijderd: %1$s Onderkant - - Na %1$s minuut - Na %1$s minuten - Altijd verwijderen Altijd behouden Verwijderen tijdens globale updates, vragen op de hoofdstukkenpagina @@ -361,14 +353,6 @@ Meenemen in globale update Bij het alfabetisch sorteren, negeer Engelse lidwoorden (a, an, the) aan het begin van mangatitels Lidwoorden negeren bij sorteren - - en %1$d nog hoofdstuk - en %1$d nog hoofdstukken - - - Voor %d titel - Voor %d titels - Meer bibliotheekinstellingen Categoriehopper verbergen Weergeven als @@ -406,18 +390,6 @@ Maak nieuwe categorie aan %1$s staat al in de wachtrij %1$s toevoegen aan updatewachtrij - - %d categorie - %d categorieën - - - %1$d pagina over - %1$d paginas over - - - Verwijder %1$d gedownload hoofdstuk\? - Verwijder %1$d gedownloade hoofdstukken\? - Hoofdstuk niet gevonden Hoofdstukken verwijderd. Bladwijzer verwijderd @@ -461,10 +433,6 @@ Verwijder oude en ongebruikte covers van manga in je bibliotheek die zijn vervangen. \nOp dit moment gebruikt: %1$s Tijdelijke covers opschonen - - Schoonmaak klaar. %d map verwijderd - Schoonmaak klaar. %d mappen verwijderd - Schakel dit uit als je problemen ervaart bij het updaten of herstellen van je bibliotheek Geen mappen om op te schonen Schoonmaak gestart @@ -473,27 +441,11 @@ Kwijtgeraakte downloads opschonen Verwijder mappen van niet-bestaande, gedeeltelijk gedownloade, en gelezen hoofdstukken Gedownloade hoofdstukken opschonen - - Cache geleegd. %d bestand is verwijderd - Cache geleegd. %d bestanden zijn verwijderd - Gegevensbeheer Niet ingelogd bij %1$s Fout bij het herstellen van de back-up Puur wit - - %d manga gemigreerd - %d manga gemigreerd - (%1$d overgeslagen) - - %1$d%2$s manga kopiëren\? - %1$d%2$s manga kopiëren\? - - - %1$d%2$s manga migreren\? - %1$d%2$s manga migreren\? - Migratie stoppen\? Geen alternatieven gevonden Geen hoofdstukken gevonden, deze manga kan niet gebruikt worden voor migratie @@ -521,15 +473,6 @@ Aan het lezen Niet getracked Getracked - - Een hoofdstuk is verwijderd uit de bron: -\n%2$s -\nDownload van dit hoofdstuk verwijderen\? - %1$s hoofdstukken zijn verwijderd uit de bron: -\n%2$s -\n -\nDownloads van deze hoofdstukken verwijderen\? - Fout bij delen van omslag Fout bij opslaan van omslag Omslag opgeslagen @@ -618,10 +561,6 @@ Niet-ingelogde trackers: Herstellen geannuleerd %02d min, %02d sec - - Voltooid in %1$s met %2$s foutmelding - Voltooid in %1$s met %2$s foutmeldingen - Bronmigratiegids NSFW-bronnen (18+) Dit voorkomt niet dat onofficiële of mogelijk incorrect gemarkeerde extensies NSFW-inhoud (18+) kunnen laten zien in de app. @@ -668,10 +607,6 @@ Ongelezen badges verbergen Categorieën toevoegen / bewerken Categorie - - %1$s hoofdstuk - %1$s hoofdstukken - Selectie Voorbeeld Verplaats naar %1$s @@ -679,10 +614,6 @@ BÈTA Toegevoegd aan %1$s Toevoegen aan %1$s - - %1$d pagina - %1$d pagina\'s - Automatisch (op basis van oriëntatie) Tijdens het gebruik van automatische pagina-indeling kunt u tijdens het lezen nog steeds schakelen tussen lay-outs zonder deze instelling te overschrijven Pagina-indeling @@ -802,10 +733,6 @@ Geen overeenkomst gevonden Bron wordt niet ondersteund Instellen als standaard - - %d wachtende update - %d wachtende updates - Kon extensie niet installeren MIUI-optimalisatie moet worden uitgeschakeld om extensies te installeren. Globale updates @@ -853,20 +780,12 @@ Verwijder %1$s van %2$s en voeg %3$s toe Dubbele pagina\'s splitsen Dubbele pagina\'s in portret splitsen - - Extensie bijgewerkt - %d extensies bijgewerkt - Extensies bijgewerkt %1$s Geïnstalleerd Extensie-updates in behandeling Beïnvloedt bibliotheekrasteromslagen Restricties: %1$s Laat lege categoriën zien tijdens het filteren - - 1 hoofdstuk is overgeslagen, de bron mist 1 hoofdstuk of het is uitgefilterd - %d hoofdstukken zijn overgeslagen, de bron mist ze of ze zijn uitgefilterd - Gids voor beginners Help met vertalen Geen resultaten voor uw filters @@ -944,10 +863,6 @@ Werk manga alleen bij als deze geen ongelezen hoofdstukken heeft (volledig gelezen) Trackers bijwerken na het markeren als gelezen Leeslijst - - Volgende ongelezen hoofdstuk - Volgende aantal %d ongelezen hoofdstukken - Sorteer op tijd opgehaald Dubbele pagina\'s inzoomen Verlanglijst @@ -1033,30 +948,14 @@ Lokale titels Statusverdeling Tracker - - - %d serie types - Niet beoordeeld - - - %d bronnen - Lengte Begin jaar Geen data gevonden voor jouw huidige filters - - - %d statussen - Open - - - %d talen - Uitgesloten categoriën Installatieprogramma Bibliotheek Foutopsporingsinformatie Achtergrond activiteit - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/nn/plurals.xml b/i18n/src/commonMain/moko-resources/nn/plurals.xml new file mode 100644 index 0000000000..860db44ecd --- /dev/null +++ b/i18n/src/commonMain/moko-resources/nn/plurals.xml @@ -0,0 +1,18 @@ + + + + + Gjort på %1$s med %2$s feil + Gjort på %1$s med %2$s feil + + + + %d kategori%d kategoriar + + + + + Etter %1$s minuttEtter %1$s minuttar + + + diff --git a/app/src/main/res/values-nn/strings.xml b/i18n/src/commonMain/moko-resources/nn/strings.xml similarity index 95% rename from app/src/main/res/values-nn/strings.xml rename to i18n/src/commonMain/moko-resources/nn/strings.xml index 2630542500..83d904abff 100644 --- a/app/src/main/res/values-nn/strings.xml +++ b/i18n/src/commonMain/moko-resources/nn/strings.xml @@ -53,10 +53,6 @@ Feil: tom URI Reservekopi oppretta Sjå etter oppdateringar - - Gjort på %1$s med %2$s feil - Gjort på %1$s med %2$s feil - Nokre produsentar har ytterlegare appavgrensingar som drep bakgrunnstenester. Denne nettstaden har meir info om korleis det kan fiksast. %1$d ikkje-bibliotek manga i databasen Nettstaden @@ -70,10 +66,6 @@ Bibliotek Kjelder Innstillingar - - %d kategori%d kategoriar - - Sorter etter Rediger kategoriar Oppdater @@ -163,10 +155,6 @@ Annankvar dag Kvar tredje dag Kvar veke - - Etter %1$s minuttEtter %1$s minuttar - - Legg til Alfabetisk Alltid @@ -227,4 +215,4 @@ Grå Utelatne kategoriar Installatør - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/om/plurals.xml b/i18n/src/commonMain/moko-resources/om/plurals.xml new file mode 100644 index 0000000000..98ccfd6a22 --- /dev/null +++ b/i18n/src/commonMain/moko-resources/om/plurals.xml @@ -0,0 +1,23 @@ + + + + + Boqonnaa %1$d buufame haquu\? + Boqonnaawwan %1$d buufaman haquu\? + + + + Boqonnaa %1$s + Boqonnaawwan %1$s + + + + fuula %1$d hafe + fuulootaa %1$d hafe + + + + Ramaddi %d + Ramaddiiwwan %d + + diff --git a/app/src/main/res/values-om/strings.xml b/i18n/src/commonMain/moko-resources/om/strings.xml similarity index 88% rename from app/src/main/res/values-om/strings.xml rename to i18n/src/commonMain/moko-resources/om/strings.xml index 77bea57569..1c04eca211 100644 --- a/app/src/main/res/values-om/strings.xml +++ b/i18n/src/commonMain/moko-resources/om/strings.xml @@ -35,18 +35,6 @@ Kan bu\'aan hunda balleessuu\? Lakkoofsa boqonnaatiin Guyyaa olkaa\'ameen - - Boqonnaa %1$d buufame haquu\? - Boqonnaawwan %1$d buufaman haquu\? - - - Boqonnaa %1$s - Boqonnaawwan %1$s - - - fuula %1$d hafe - fuulootaa %1$d hafe - Ramaddii Ramaddiiwwan TachiyomiJ2K boqonnaawwan buusuuf, ofumaan dilbeessa uumuu fi mangaa naannoo dubbisuuf, faayiloota Android 11 keessa jiran hunda argachuu barbaachisa. @@ -70,10 +58,6 @@ Mangaan ramaddii kana keessa jiru gara ramaddii durtiitti ni ce\'a. Manga duraanuu ramaddii keessa jira Ramaddiiwwan Dabaluu/Gulaaluu - - Ramaddi %d - Ramaddiiwwan %d - Ramaddiin maqaa sana qabu duruu jira! Maqaan ramaddii duwwaa ta\'uu hin danda\'u Secca\'uu @@ -91,4 +75,4 @@ Dogoggora hin beekamne Ramaddiiwwan gulaali Ramaddii bulchuu - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/or/plurals.xml b/i18n/src/commonMain/moko-resources/or/plurals.xml new file mode 100644 index 0000000000..83cc3f9077 --- /dev/null +++ b/i18n/src/commonMain/moko-resources/or/plurals.xml @@ -0,0 +1,8 @@ + + + + + %2$sଟିଏ ତ୍ରୁଟି ସହ %1$sରେ କରାଗଲା + %2$sଟି ତ୍ରୁଟି ସହିତ %1$sରେ କରାଗଲା + + diff --git a/app/src/main/res/values-or/strings.xml b/i18n/src/commonMain/moko-resources/or/strings.xml similarity index 97% rename from app/src/main/res/values-or/strings.xml rename to i18n/src/commonMain/moko-resources/or/strings.xml index 173fd92790..a67dd1e721 100644 --- a/app/src/main/res/values-or/strings.xml +++ b/i18n/src/commonMain/moko-resources/or/strings.xml @@ -56,10 +56,6 @@ ୨୫% ସେବା %02d ମି, %02d ସେ - - %2$sଟିଏ ତ୍ରୁଟି ସହ %1$sରେ କରାଗଲା - %2$sଟି ତ୍ରୁଟି ସହିତ %1$sରେ କରାଗଲା - ଅନଇନଷ୍ଟଲ୍ କରିବା ସହାୟତା WebViewରେ ଖୋଲନ୍ତୁ @@ -127,4 +123,4 @@ ଅଦ୍ୟତନ ପାଇଁ ସନ୍ଧାନ କରୁଛି… ଉପଯୋଗୀ ଅନୁଵାଦ ଲିଙ୍କ୍ କୌଣସି ନୂତନ ଅଦ୍ୟତନ ଉପଲବ୍ଧ ନାହିଁ - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/pl/plurals.xml b/i18n/src/commonMain/moko-resources/pl/plurals.xml new file mode 100644 index 0000000000..986a28ebe4 --- /dev/null +++ b/i18n/src/commonMain/moko-resources/pl/plurals.xml @@ -0,0 +1,182 @@ + + + + + Usunąć %1$d pobrany rozdział? + Usunąć %1$d pobrane rozdziały? + Usunąć %1$d pobranych rozdziałów? + Usunąć %1$d pobranych rozdziałów? + + + + %1$s rozdział + %1$s rozdziały + %1$s rozdziałów + %1$s rozdziałów + + + + Pozostała %1$d strona + Pozostały %1$d strony + Pozostało %1$d stron + Pozostało %1$d stron + + + + %d kategoria + %d kategorii + %d kategorii + %d kategorii + + + + Dla %d tytułu + Dla %d tytułów + Dla %d tytułów + Dla %d tytułów + + + + i %1$d rozdział więcej + i %1$d rozdziały więcej + i %1$d rozdziałów więcej + i %1$d rozdziałów więcej + + + + Aktualizacja rozszerzenia dostępna + %d aktualizacje rozszerzeń dostępne + %d aktualizacji rozszerzeń dostępnych + %d aktualizacji rozszerzeń dostępnych + + + + Rozdział został usunięty ze źródła: +\n%2$s +\nUsunąć pobrane\? + %1$s rozdziały zostały usunięte ze źródła: +\n%2$s +\n +\nUsunąć pobrane\? + %1$s rozdziałów zostało usuniętych ze źródła: +\n%2$s +\n +\nUsunąć pobrane\? + %1$s rozdziałów zostało usuniętych ze źródła: +\n%2$s +\n +\nUsunąć pobrane\? + + + + Migrować %1$d%2$s mangę? + Migrować %1$d%2$s mangi? + Migrować %1$d%2$s mang? + Migrate %1$d%2$s mang? + + + + Skopiować %1$d%2$s mangę? + Skopiować %1$d%2$s mangi? + Skopiować %1$d%2$s mang? + Skopiować %1$d%2$s mang? + + + + %d manga zmigrowana + %d mangi zmigrowane + %d mang zmigrowanych + %d mang zmigrowanych + + + + Pamięć podręczna wyczyszczona. %d plik został usunięty + Pamięć podręczna wyczyszczona. %d pliki zostały usunięty + Pamięć podręczna wyczyszczona. %d plików zostało usuniętych + Pamięć podręczna wyczyszczona. %d plików zostało usuniętych + + + + Czyszczenie skończone. Usunięto %d folder + Czyszczenie skończone. Usunięto %d foldery + Czyszczenie skończone. Usunięto %d folderów + Czyszczenie skończone. Usunięto %d folderów + + + + Po %1$s minucie + Po %1$s minutach + Po %1$s minutach + Po %1$s minutach + + + + Wykonano w %1$s z %2$s błędem + Wykonano w %1$s z %2$s błędami + Wykonano w %1$s z %2$s błędami + Wykonano w %1$s z %2$s błędami + + + + %1$d strona + %1$d strony + %1$d stron + %1$d stron + + + + Rozszerzenie zaktualizowane + %d rozszerzenia zaktualizowane + %d rozszerzeń zaktualizowanych + %d rozszerzeń zaktualizowanych + + + + %d oczekująca aktualizacja + %d oczekujące aktualizacje + %d oczekujących aktualizacji + %d oczekujących aktualizacji + + + + %d brakujący rozdział + %d brakujące rozdziały + %d brakujących rozdziałów + %d brakujących rozdziałów + + + + Następny nieprzeczytany rozdział + Następne %d nieprzeczytane rozdziały + Następne %d nieprzeczytanych rozdziałów + Następne %d nieprzeczytanych rozdziałów + + + + %d źródło + %d źródła + %d źródeł + %d źródeł + + + + %d status + %d statusy + %d statusów + %d statusów + + + + %d język + %d języki + %d języków + %d języków + + + + %d typ serii + %d typów serii + %d typów serii + %d typów serii + + diff --git a/app/src/main/res/values-pl/strings.xml b/i18n/src/commonMain/moko-resources/pl/strings.xml similarity index 90% rename from app/src/main/res/values-pl/strings.xml rename to i18n/src/commonMain/moko-resources/pl/strings.xml index d4b0860546..9ec922660a 100644 --- a/app/src/main/res/values-pl/strings.xml +++ b/i18n/src/commonMain/moko-resources/pl/strings.xml @@ -39,24 +39,6 @@ Usunięto z zakładek Rozdziały usunięte. Nie znaleziono rozdziału - - Usunąć %1$d pobrany rozdział? - Usunąć %1$d pobrane rozdziały? - Usunąć %1$d pobranych rozdziałów? - Usunąć %1$d pobranych rozdziałów? - - - %1$s rozdział - %1$s rozdziały - %1$s rozdziałów - %1$s rozdziałów - - - Pozostała %1$d strona - Pozostały %1$d strony - Pozostało %1$d stron - Pozostało %1$d stron - Kategoria Kategorie @@ -72,12 +54,6 @@ Edytuj kategorie Zarządzaj kategorią Przenieś do kategorii - - %d kategoria - %d kategorii - %d kategorii - %d kategorii - Kategoria o tej nazwie już istnieje! Kategoria usunięta Dotknij i przytrzymaj aby edytować kategorię @@ -131,18 +107,6 @@ Więcej ustawień biblioteki Znaleziono nowe rozdziały - - Dla %d tytułu - Dla %d tytułów - Dla %d tytułów - Dla %d tytułów - - - i %1$d rozdział więcej - i %1$d rozdziały więcej - i %1$d rozdziałów więcej - i %1$d rozdziałów więcej - Częstotliwość aktualizowania biblioteki Ograniczenia urządzenia @@ -205,12 +169,6 @@ To rozszerzenie nie jest już dostępne. Wersja: %1$s Język: %1$s - - Aktualizacja rozszerzenia dostępna - %d aktualizacje rozszerzeń dostępne - %d aktualizacji rozszerzeń dostępnych - %d aktualizacji rozszerzeń dostępnych - Ustaw jako okładkę Ustaw jako domyślne dla wszystkich @@ -325,23 +283,6 @@ Zanim to zrobisz, dodaj tę mangę do biblioteki Pamiętaj ten wybór Źródło niezainstalowane - - Rozdział został usunięty ze źródła: -\n%2$s -\nUsunąć pobrane\? - %1$s rozdziały zostały usunięte ze źródła: -\n%2$s -\n -\nUsunąć pobrane\? - %1$s rozdziałów zostało usuniętych ze źródła: -\n%2$s -\n -\nUsunąć pobrane\? - %1$s rozdziałów zostało usuniętych ze źródła: -\n%2$s -\n -\nUsunąć pobrane\? - Śledzenie Śledzone @@ -388,25 +329,7 @@ Nie znaleziono rozdziałów, ta manga nie może zostać użyta do migracji Brak znalezionych alternatyw Przerwać migrację? - - Migrować %1$d%2$s mangę? - Migrować %1$d%2$s mangi? - Migrować %1$d%2$s mang? - Migrate %1$d%2$s mang? - - - Skopiować %1$d%2$s mangę? - Skopiować %1$d%2$s mangi? - Skopiować %1$d%2$s mang? - Skopiować %1$d%2$s mang? - (pomijanie %1$d) - - %d manga zmigrowana - %d mangi zmigrowane - %d mang zmigrowanych - %d mang zmigrowanych - Ustawienia Ogólne @@ -448,12 +371,6 @@ Sieć Wymaga ponownego uruchomienia aplikacji W użyciu: %1$s - - Pamięć podręczna wyczyszczona. %d plik został usunięty - Pamięć podręczna wyczyszczona. %d pliki zostały usunięty - Pamięć podręczna wyczyszczona. %d plików zostało usuniętych - Pamięć podręczna wyczyszczona. %d plików zostało usuniętych - Podczas czyszczenia wystąpił błąd Usuń ciasteczka Ciasteczka usunięte @@ -475,12 +392,6 @@ Wyłącz optymalizację baterii Wyłącz optymalizację baterii jeżeli masz problemy z aktualizowaniem lub przywracaniem biblioteki Oszczędzanie baterii jest już wyłączone - - Czyszczenie skończone. Usunięto %d folder - Czyszczenie skończone. Usunięto %d foldery - Czyszczenie skończone. Usunięto %d folderów - Czyszczenie skończone. Usunięto %d folderów - Wyczyść okładki zapisane w pamięci podręcznej Usuń stare i nieużywane okładki mang w twojej bibliotece, które zostały zaktualizowane, z pamięci podręcznej. \nObecnie używane: %1$s @@ -563,12 +474,6 @@ Codziennie Co 2 dni Co tydzień - - Po %1$s minucie - Po %1$s minutach - Po %1$s minutach - Po %1$s minutach - Wybierz okładkę Wybierz plik kopii zapasowej @@ -695,12 +600,6 @@ Serwisy, do których nie zalogowono: Anulowano przywracanie %02d min, %02d s - - Wykonano w %1$s z %2$s błędem - Wykonano w %1$s z %2$s błędami - Wykonano w %1$s z %2$s błędami - Wykonano w %1$s z %2$s błędami - Migracja źródła - poradnik NFSW Materiały 18+ Nie zapobiega to nieoficjalnym lub potencjalnie niepoprawnie oflagowanym rozszerzeniom przed pokazywaniem zwartości NSFW(18+) w aplikacji. @@ -862,12 +761,6 @@ tryb Incognito Wyłącz %s Włącz %s - - %1$d strona - %1$d strony - %1$d stron - %1$d stron - Pokaż po przytrzymaniu Akcje Automatyczny (na podstawie orientacji) @@ -886,27 +779,9 @@ Odwróć podwójne strony Ilość stron do wstępnego załadowania podczas czytania. Większe wartości będą skutkować płynniejszym doświadczeniem z czytania, kosztem większego zużycia pamięci podręcznej i sieci. Ilość wstępnie ładowanych stron - - Rozszerzenie zaktualizowane - %d rozszerzenia zaktualizowane - %d rozszerzeń zaktualizowanych - %d rozszerzeń zaktualizowanych - Rozszerzenia zaktualizowane - - %d oczekująca aktualizacja - %d oczekujące aktualizacje - %d oczekujących aktualizacji - %d oczekujących aktualizacji - Globalne aktualizacje Pokaż liczbę elementów - - %d brakujący rozdział - %d brakujące rozdziały - %d brakujących rozdziałów - %d brakujących rozdziałów - Ustaw jako domyślne Dodaj tag Wygląd @@ -1032,12 +907,6 @@ Najniższe Sprawdź wydania beta Wypróbuj nowe funkcje zanim będą oficjalnie wydane. Wydania beta mogą być niestabilne i są dostarczane by dać feedback developerowi. - - Następny nieprzeczytany rozdział - Następne %d nieprzeczytane rozdziały - Następne %d nieprzeczytanych rozdziałów - Następne %d nieprzeczytanych rozdziałów - Sortuj przez czas pobrania Lista czytanych Lista życzeń @@ -1089,33 +958,15 @@ Popularne Zobacz ostatnio zaktualizowane wpisy Widżet nie jest dostępny kiedy blokada aplikacji jest włączona - - %d źródło - %d źródła - %d źródeł - %d źródeł - Statystyka Statystyki Status dystrybucji Zobacz szczegółowe statystyki - - %d status - %d statusy - %d statusów - %d statusów - Szczegółowe statystyki Śledzone tytuły Źródło Nie ocenione Długość - - %d język - %d języki - %d języków - %d języków - Ukryj pozycje znajdujące się już w bibliotece Czas spędzony w czytniku, na podstawie historii rozdziałów Nie udało się zaktualizować %1$s @@ -1139,16 +990,10 @@ Średni wynik śledzenia Status wyniku Element śledzący - - %d typ serii - %d typów serii - %d typów serii - %d typów serii - Zezwalanie na powiadomienia jest zalecane, aby zapewnić aktualność twojej biblioteki. Wykluczone kategorie Instalator Biblioteka Informacje debugowania Aktywność w tle - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/pt-rBR/plurals.xml b/i18n/src/commonMain/moko-resources/pt-rBR/plurals.xml new file mode 100644 index 0000000000..27d71c4da8 --- /dev/null +++ b/i18n/src/commonMain/moko-resources/pt-rBR/plurals.xml @@ -0,0 +1,155 @@ + + + + + Remover %1$d capítulo baixado\? + Remover %1$d capítulos baixados\? + Remover %1$d capítulos baixados\? + + + + %1$s capítulo + %1$s capítulos + %1$s capítulos + + + + %1$d página restante + %1$d páginas restantes + %1$d páginas restantes + + + + %d categoria + %d categorias + %d categorias + + + + Para %d título + Para %d títulos + Para %d títulos + + + + e mais %1$d capítulo + e mais %1$d capítulos + e mais %1$d capítulos + + + + Atualização de extensão disponível + %d atualizações de extensão disponíveis + %d atualizações de extensão disponíveis + + + + Um capítulo foi removido da fonte: +\n%2$s +\nExcluir seu download\? + %1$s capítulos foram removidos da fonte: +\n%2$s +\n +\nExcluir seus downloads\? + %1$s capítulos foram removidos da fonte: +\n%2$s +\n +\nExcluir seus downloads\? + + + + Migrar %1$d%2$s mangá\? + Migrar %1$d%2$s mangás\? + Migrar %1$d%2$s mangás\? + + + + Copiar %1$d%2$s mangá\? + Copiar %1$d%2$s mangás\? + Copiar %1$d%2$s mangás\? + + + + %d mangá migrado + %d mangás migrados + %d mangás migrados + + + + Cache limpo. %d arquivo foi excluído + Cache limpo. %d arquivos foram excluídos + Cache limpo. %d arquivos foram excluídos + + + + Limpeza realizada. %d pasta removida + Limpeza realizada. %d pastas removidas + Limpeza realizada. %d pastas removidas + + + + Após %1$s minuto + Após %1$s minutos + Após %1$s minutos + + + + Concluído em %1$s com %2$s erro + Concluído em %1$s com %2$s erros + Concluído em %1$s com %2$s erros + + + + %1$d página + %1$d páginas + %1$d páginas + + + + %d atualização pendente + %d atualizações pendentes + %d atualizações pendentes + + + + Extensão atualizada + %d extensões atualizadas + %d extensões atualizadas + + + + Pulando %d capítulo, ou ele está faltando na fonte, ou ele foi filtrado + Pulando %d capítulos, ou eles estão faltando na fonte, ou eles foram filtrados + Pulando %d capítulos, ou eles estão faltando na fonte, ou eles foram filtrados + + + + Próximo capítulo não lido + Próximos %d capítulos não lidos + Próximos %d capítulos não lidos + + + + %d Tipo de série + %d Tipos de séries + %d Outras séries + + + + %d Idioma + %d Idiomas + %d Outros Idiomas + + + + %d Fonte + %d Fontes + %d Outras Fontes + + + + %d estado + %d estados + %d outros estados + + diff --git a/app/src/main/res/values-pt-rBR/strings.xml b/i18n/src/commonMain/moko-resources/pt-rBR/strings.xml similarity index 92% rename from app/src/main/res/values-pt-rBR/strings.xml rename to i18n/src/commonMain/moko-resources/pt-rBR/strings.xml index 93be2b44b9..178f231dfb 100644 --- a/app/src/main/res/values-pt-rBR/strings.xml +++ b/i18n/src/commonMain/moko-resources/pt-rBR/strings.xml @@ -60,21 +60,6 @@ Marcado como não lido Removido da Biblioteca Capítulos removidos. - - Remover %1$d capítulo baixado\? - Remover %1$d capítulos baixados\? - Remover %1$d capítulos baixados\? - - - %1$s capítulo - %1$s capítulos - %1$s capítulos - - - %1$d página restante - %1$d páginas restantes - %1$d páginas restantes - Categoria Categorias @@ -89,11 +74,6 @@ Editar categorias Gerenciar categoria Mover para categorias - - %d categoria - %d categorias - %d categorias - Já existe uma categoria com este nome! Categoria excluída Pressione e segure para editar uma categoria @@ -146,16 +126,6 @@ Mais configurações da biblioteca Novos capítulos encontrados - - Para %d título - Para %d títulos - Para %d títulos - - - e mais %1$d capítulo - e mais %1$d capítulos - e mais %1$d capítulos - Frequência de atualização da biblioteca Restrições do dispositivo @@ -220,11 +190,6 @@ Esta extensão não está mais disponível. Versão: %1$s Idioma: %1$s - - Atualização de extensão disponível - %d atualizações de extensão disponíveis - %d atualizações de extensão disponíveis - Usar como capa Defina como padrão para todos @@ -337,19 +302,6 @@ O mangá deve estar em sua biblioteca para editar Lembrar esta opção Fonte não instalada - - Um capítulo foi removido da fonte: -\n%2$s -\nExcluir seu download\? - %1$s capítulos foram removidos da fonte: -\n%2$s -\n -\nExcluir seus downloads\? - %1$s capítulos foram removidos da fonte: -\n%2$s -\n -\nExcluir seus downloads\? - Monitoramento Monitorado @@ -395,22 +347,7 @@ pode ser usado para migração Nenhuma alternativa encontrada Parar de migrar? - - Migrar %1$d%2$s mangá\? - Migrar %1$d%2$s mangás\? - Migrar %1$d%2$s mangás\? - - - Copiar %1$d%2$s mangá\? - Copiar %1$d%2$s mangás\? - Copiar %1$d%2$s mangás\? - (pulando %1$d) - - %d mangá migrado - %d mangás migrados - %d mangás migrados - Configurações Geral @@ -455,11 +392,6 @@ Limpar cache de capítulo Total usado: %1$s - - Cache limpo. %d arquivo foi excluído - Cache limpo. %d arquivos foram excluídos - Cache limpo. %d arquivos foram excluídos - Ocorreu um erro ao limpar Excluir cookies Cookies limpos @@ -480,11 +412,6 @@ Desative isso se você estiver com problemas para atualizar ou restaurar sua biblioteca A otimização de bateria já está desativada - - Limpeza realizada. %d pasta removida - Limpeza realizada. %d pastas removidas - Limpeza realizada. %d pastas removidas - Limpar capas em cache Exclua capas em cache antigas e não usadas de mangás em sua biblioteca que foram atualizados. \nAtualmente usando: %1$s @@ -579,11 +506,6 @@ Diariamente A cada 2 dias Semanalmente - - Após %1$s minuto - Após %1$s minutos - Após %1$s minutos - Selecionar imagem de capa Selecionar arquivo de backup @@ -733,11 +655,6 @@ \nVocê precisará instalar quaisquer extensões que estejam faltando e depois realizar o login nos serviços de monitoramento para utilizá-los. Restauração cancelada %02d min e %02d seg - - Concluído em %1$s com %2$s erro - Concluído em %1$s com %2$s erros - Concluído em %1$s com %2$s erros - Guia de migração de fonte Fontes NSFW (+18) Isso não impede que extensões não oficiais ou potencialmente sinalizadas de maneira incorreta apresentem conteúdo NSFW (+18) no aplicativo. @@ -819,11 +736,6 @@ Ignorar as áreas de corte da tela Iniciar após o corte da tela Preencher as áreas de corte da tela - - %1$d página - %1$d páginas - %1$d páginas - Comportamento da área de corte da tela Ambos os eixos Verticalmente @@ -892,11 +804,6 @@ Tema claro Não foi encontrado resultado similar Essa fonte não é suportada - - %d atualização pendente - %d atualizações pendentes - %d atualizações pendentes - Não foi possível instalar a extensão Atualizações globais Abrir uma série aleatória @@ -940,11 +847,6 @@ Alinhamento dos ícones da navegação lateral Dividir em página dupla Dividir página dupla em retrato - - Extensão atualizada - %d extensões atualizadas - %d extensões atualizadas - Extensões atualizadas Atualizar tudo Otimização MIUI precisa ser desativada para instalar as extensões. @@ -962,11 +864,6 @@ Guia de introdução Sem resultados para os filtros escolhidos Mostrar categorias vazias enquanto filtra - - Pulando %d capítulo, ou ele está faltando na fonte, ou ele foi filtrado - Pulando %d capítulos, ou eles estão faltando na fonte, ou eles foram filtrados - Pulando %d capítulos, ou eles estão faltando na fonte, ou eles foram filtrados - Isso irá forçar o cache de download á recalcular. Útil se você modificou downloads fora do aplicativo e quer que ele seja selecionado novamente pelo aplicativo Usar navegação lateral Aparência @@ -1072,11 +969,6 @@ Erro: URI vazia Backups automáticos são altamente recomendados. Você deve manter cópias em outros locais também. Fazer download a frente - - Próximo capítulo não lido - Próximos %d capítulos não lidos - Próximos %d capítulos não lidos - Funciona somente em itens na biblioteca e se o capítulo atual e próximo já estão disponíveis offline Gerenciar notificações Bateria não fraca @@ -1108,11 +1000,6 @@ Download automático durante a leitura Capítulos disponíveis offline Status - - %d Tipo de série - %d Tipos de séries - %d Outras séries - Comprimento Ano de início Nenhum dado encontrado para seus filtros atuais @@ -1137,21 +1024,6 @@ Ver estatísticas detalhadas Não avaliado Fonte - - %d Idioma - %d Idiomas - %d Outros Idiomas - - - %d Fonte - %d Fontes - %d Outras Fontes - - - %d estado - %d estados - %d outros estados - Tempo gasto no leitor, com base no histórico do capítulo Pulado porque a série não requer atualizações Valor de user agent inválido diff --git a/i18n/src/commonMain/moko-resources/pt/plurals.xml b/i18n/src/commonMain/moko-resources/pt/plurals.xml new file mode 100644 index 0000000000..0f14a524e8 --- /dev/null +++ b/i18n/src/commonMain/moko-resources/pt/plurals.xml @@ -0,0 +1,152 @@ + + + + + Atualização de extensão disponível + %d atualizações de extensão disponíveis + %d atualizações de extensão disponíveis + + + + %d categoria + %d categorias + %d categorias + + + + %1$d página restante + %1$d páginas restantes + %1$d páginas restantes + + + + Remover %1$d capítulo transferido\? + Remover %1$d capítulos transferidos\? + Remover %1$d capítulos transferidos\? + + + + Concluído em %1$s com %2$s erro + Concluído em %1$s com %2$s erros + Concluído em %1$s com %2$s erros + + + + %1$s capítulo + %1$s capítulos + + + + e mais %1$d capítulo + e mais %1$d capítulos + e mais %1$d capítulos + + + + Para %d título + Para %d títulos + Para %d títulos + + + + Após %1$s minuto + Após %1$s minutos + Após %1$s minutos + + + + Limpeza realizada. %d pasta removida + Limpeza realizada. %d pastas removidas + Limpeza realizada. %d pastas removidas + + + + Cache limpa. %d ficheiro foi apagado + Cache limpa. %d ficheiros foram apagados + Cache limpa. %d ficheiros foram apagados + + + + %d manga migrada + %d mangas migradas + %d mangas migradas + + + + Copiar %1$d%2$s manga\? + Copiar %1$d%2$s mangas\? + Copiar %1$d%2$s mangas\? + + + + Migrar %1$d%2$s manga\? + Migrar %1$d%2$s mangas\? + Migrar %1$d%2$s mangas\? + + + + Um capítulo foi removido da fonte: +\n%2$s +\nApagar a sua transferência\? + %1$s capítulos foram removidos da fonte: +\n%2$s +\nApagar as suas transferências\? + %1$s capítulos foram removidos da fonte: +\n%2$s +\nApagar as suas transferências\? + + + + %1$d página + %1$d páginas + %1$d páginas + + + + Extensão atualizada + %d extensões atualizadas + %d extensões atualizadas + + + + %d atualização pendente + %d atualizações pendentes + %d atualizações pendentes + + + + Ignorando %d capítulo, ou a fonte está em falta ou foi filtrado + Ignorando %d capítulos, ou a fonte está em falta ou foi filtrado + Capítulos %d ignorados, ou a fonte está em falta ou foi filtrado + + + + 1 tipo de série + %d tipos de séries + %d tipos de séries + + + + 1 fonte + %d fontes + %d fontes + + + + 1 estado + %d estados + %d estados + + + + 1 idioma + %d idiomas + %d idiomas + + + + Próximo capítulo não lido + Próximos %d capítulos não lidos + Próximos %d capítulos não lidos + + diff --git a/app/src/main/res/values-pt/strings.xml b/i18n/src/commonMain/moko-resources/pt/strings.xml similarity index 92% rename from app/src/main/res/values-pt/strings.xml rename to i18n/src/commonMain/moko-resources/pt/strings.xml index 0c756c9e8c..2e5ab32a5c 100644 --- a/app/src/main/res/values-pt/strings.xml +++ b/i18n/src/commonMain/moko-resources/pt/strings.xml @@ -311,11 +311,6 @@ Verifique o site no WebView Obsoleto Esta extensão já não está disponível. - - Atualização de extensão disponível - %d atualizações de extensão disponíveis - %d atualizações de extensão disponíveis - Reduz bandas de cor, mas pode impactar a performance Saltar capítulos filtrados Vertical contínuo @@ -373,21 +368,6 @@ Criar nova categoria %1$s já está na fila Adicionando %1$s para a fila de atualizações - - %d categoria - %d categorias - %d categorias - - - %1$d página restante - %1$d páginas restantes - %1$d páginas restantes - - - Remover %1$d capítulo transferido\? - Remover %1$d capítulos transferidos\? - Remover %1$d capítulos transferidos\? - Capítulo não encontrado Capítulos removidos. Remover marcados @@ -460,11 +440,6 @@ Monitorizadores sem sessão iniciada: Restauro cancelado %02d min, %02d seg - - Concluído em %1$s com %2$s erro - Concluído em %1$s com %2$s erros - Concluído em %1$s com %2$s erros - Guia de migração de fonte Conteúdo 18+ (NSFW) Isto não impede que extensões não oficiais ou potencialmente marcadas de forma incorreta surjam com conteúdos de NSFW (18+) dentro da aplicação. @@ -486,10 +461,6 @@ Mais definições da biblioteca Esconder seletor de categorias O nome da categoria não pode ficar vazio - - %1$s capítulo - %1$s capítulos - Adicionar %1$s a… Mover %1$s para… Adicionado recentemente @@ -504,16 +475,6 @@ Incluir na atualização global Ao ordenar alfabeticamente, ordenar ignorando os artigos (a, an, the) no início dos títulos de manga Ordenar ignorando artigos - - e mais %1$d capítulo - e mais %1$d capítulos - e mais %1$d capítulos - - - Para %d título - Para %d títulos - Para %d títulos - Mostrar contagem de não lidos Mostrar distintivos não lidos Esconder distintivos não lidos @@ -570,11 +531,6 @@ Adicionado em %1$s Adicionar em %1$s A WebView é necessária para o Tachiyomi - - Após %1$s minuto - Após %1$s minutos - Após %1$s minutos - Remoção automática Sempre apagar Sempre manter @@ -606,11 +562,6 @@ Apaga capas em cache antigas e não usadas de mangás na sua biblioteca que foram atualizados. \nAtualmente a usar: %1$s Limpar capas em cache - - Limpeza realizada. %d pasta removida - Limpeza realizada. %d pastas removidas - Limpeza realizada. %d pastas removidas - Desative isso se estiver com problemas para atualizar ou restaurar a sua biblioteca Nenhuma pasta para limpar Iniciando a limpeza @@ -619,11 +570,6 @@ Limpar orfanados Apagar ficheiros inexistentes, parcialmente descarregados e lê as pastas dos capítulos Limpar capítulos descarregados - - Cache limpa. %d ficheiro foi apagado - Cache limpa. %d ficheiros foram apagados - Cache limpa. %d ficheiros foram apagados - DNS sobre HTTPS Gestão de dados Não conectado ao %1$s @@ -642,22 +588,7 @@ Modo anônimo Desativar %s Ativar %s - - %d manga migrada - %d mangas migradas - %d mangas migradas - (a pular %1$d) - - Copiar %1$d%2$s manga\? - Copiar %1$d%2$s mangas\? - Copiar %1$d%2$s mangas\? - - - Migrar %1$d%2$s manga\? - Migrar %1$d%2$s mangas\? - Migrar %1$d%2$s mangas\? - Parar de migrar\? Nenhuma alternativa encontrada Nenhum capítulo encontrado, esta manga não pode ser usada para migração @@ -682,17 +613,6 @@ Também remover de %1$s Remover monitoramento da app Não monitorado - - Um capítulo foi removido da fonte: -\n%2$s -\nApagar a sua transferência\? - %1$s capítulos foram removidos da fonte: -\n%2$s -\nApagar as suas transferências\? - %1$s capítulos foram removidos da fonte: -\n%2$s -\nApagar as suas transferências\? - Informações de manga personalizada Erro ao partilhar capa Erro ao guardar capa @@ -727,11 +647,6 @@ Começar a ler Capítulo %1$s Comece a ler Sobre isto %1$s - - %1$d página - %1$d páginas - %1$d páginas - Mostrar no toque longo Ações Automático (baseado na orientação) @@ -854,17 +769,7 @@ Adicionar tag Dividir em página dupla Dividir página dupla em retrato - - Extensão atualizada - %d extensões atualizadas - %d extensões atualizadas - Extensões atualizadas - - %d atualização pendente - %d atualizações pendentes - %d atualizações pendentes - Atualizando extensões Algumas extensões podem solicitar a instalação deles antes. Atualizar tudo @@ -904,11 +809,6 @@ Remover %1$s de %2$s e adicionar %3$s Remover o rastreador anterior\? Selecione uma entrada - - Ignorando %d capítulo, ou a fonte está em falta ou foi filtrado - Ignorando %d capítulos, ou a fonte está em falta ou foi filtrado - Capítulos %d ignorados, ou a fonte está em falta ou foi filtrado - Afeta as grades de cobertura da biblioteca Guia de introdução Sem resultados para os filtros selecionados @@ -1026,33 +926,8 @@ Ano de início Fonte Não foram encontrados dados para os seus filtros atuais - - 1 tipo de série - %d tipos de séries - %d tipos de séries - Violeta Conta - - 1 fonte - %d fontes - %d fontes - - - 1 estado - %d estados - %d estados - - - 1 idioma - %d idiomas - %d idiomas - - - Próximo capítulo não lido - Próximos %d capítulos não lidos - Próximos %d capítulos não lidos - Capítulos lidos Estatísticas Transferência em antecedência @@ -1113,4 +988,4 @@ Permitir as notificações é recomendado para manter o aplicativo e sua biblioteca atualizados. Informações de depuração Atividade em segundo plano - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/ro/plurals.xml b/i18n/src/commonMain/moko-resources/ro/plurals.xml new file mode 100644 index 0000000000..5811d9d04f --- /dev/null +++ b/i18n/src/commonMain/moko-resources/ro/plurals.xml @@ -0,0 +1,155 @@ + + + + + Actualizare de extensie disponibilă + %d actualizări de extensie disponibile + %d actualizări de extensie disponibile + + + + Gata în %1$s cu eroarea %2$s + Gata în %1$s cu %2$s erori + Gata în %1$s cu %2$s erori + + + + %d categorie + %d categorii + %d categorii + + + + %1$d pagină rămasă + %1$d pagini rămase + %1$d pagini rămase + + + + %1$s capitol + %1$s capitole + %1$s capitole + + + + Eliminați %1$d capitolul descărcat\? + Eliminați %1$d capitole descărcate\? + Eliminați %1$d capitole descărcate\? + + + + și %1$d capitol mai mult + și %1$d mai multe capitole + și %1$d mai multe capitole + + + + Pentru %d titlu + Pentru %d titluri + Pentru %d titluri + + + + Copiați %1$d%2$s manga\? + Copiați %1$d%2$s manga\? + Copiați %1$d%2$s manga\? + + + + Migrează %1$d%2$s manga\? + Migrează %1$d%2$s manga\? + Migrează %1$d%2$s manga\? + + + + Un capitol a fost eliminat din sursă: +\n%2$s +\nȘtergeți descărcarea acestuia\? + %1$s capitole au fost eliminate din sursă: +\n%2$s +\n +\nȘtergeți descărcarea acestora\? + %1$s capitole au fost eliminate din sursă: +\n%2$s +\n +\nȘtergeți descărcarea acestora\? + + + + %1$d pagină + %1$d pagini + %1$d pagini + + + + Curățenie făcută. A fost eliminat %d dosar + Curățenie făcută. Au fost eliminate %d dosare + Curățenie făcută. Au fost eliminate %d dosare + + + + %d manga a migrat + %d mangauri au migrat + %d mangauri au migrat + + + + După %1$s minut + După %1$s minute + După %1$s minute + + + + Cache curățat. %d fișierul a fost șters + Cache curățat. %d fișiere au fost șterse + Cache curățat. %d fișiere au fost șterse + + + + Următorul capitol necitit + Următoarele %d capitole necitite + Următoarele %d capitole necitite + + + + %d actualizare în așteptare + %d actualizări în așteptare + %d actualizări în așteptare + + + + Extensia a fost actualizată + Extensiile %d au fost actualizate + Extensiile %d au fost actualizate + + + + Omiterea %d capitol, fie că sursa lipsește, fie că a fost filtrată + Omiterea a %d capitole, fie că sursa nu le are, fie că au fost filtrate + Omiterea a %d capitole, fie că sursa nu le are, fie că au fost filtrate + + + + %d Tip de serii + %d Tipuri de serii + %d Tipuri de serii + + + + %d sursă + %d surse + %d surse + + + + %d Limbă + %d Limbi + %d Limbi + + + + %d status + %d statusuri + %d statusuri + + diff --git a/app/src/main/res/values-ro/strings.xml b/i18n/src/commonMain/moko-resources/ro/strings.xml similarity index 92% rename from app/src/main/res/values-ro/strings.xml rename to i18n/src/commonMain/moko-resources/ro/strings.xml index 9b265823b9..1a5bf48696 100644 --- a/app/src/main/res/values-ro/strings.xml +++ b/i18n/src/commonMain/moko-resources/ro/strings.xml @@ -273,11 +273,6 @@ Verificați site-ul în WebView Învechit Această extensie nu mai este disponibilă. - - Actualizare de extensie disponibilă - %d actualizări de extensie disponibile - %d actualizări de extensie disponibile - Reduce banding-ul, dar poate avea un impact asupra performanței Săriți peste capitolele filtrate Vertical continuu @@ -353,21 +348,11 @@ Trackerele nu sunt conectate la: Restaurare anulată %02d minute, %02d secunde - - Gata în %1$s cu eroarea %2$s - Gata în %1$s cu %2$s erori - Gata în %1$s cu %2$s erori - Ghid de migrare a sursei Conținut NSFW (18+) Ce este nou Nicio aplicație de ales fișiere nu a fost găsite Deschide jurnal - - %d categorie - %d categorii - %d categorii - Creează copie de rezervă și restaurează Progresul Terminat @@ -385,21 +370,6 @@ %1$s este deja în rând Adăugarea %1$s la rând pentru actualizare Categorie - - %1$d pagină rămasă - %1$d pagini rămase - %1$d pagini rămase - - - %1$s capitol - %1$s capitole - %1$s capitole - - - Eliminați %1$d capitolul descărcat\? - Eliminați %1$d capitole descărcate\? - Eliminați %1$d capitole descărcate\? - Capitolul nu a fost găsit Capitole eliminate. Marcaj eliminat @@ -427,16 +397,6 @@ Mutați %1$s la… În progres Neîncepute - - și %1$d capitol mai mult - și %1$d mai multe capitole - și %1$d mai multe capitole - - - Pentru %d titlu - Pentru %d titluri - Pentru %d titluri - Mutați o pagină peste Mai multe setări la bibliotecă Afișați ca @@ -574,16 +534,6 @@ Ultima utilizare (Bibliotecă sau Recente) Căutați recentele… Recente - - Copiați %1$d%2$s manga\? - Copiați %1$d%2$s manga\? - Copiați %1$d%2$s manga\? - - - Migrează %1$d%2$s manga\? - Migrează %1$d%2$s manga\? - Migrează %1$d%2$s manga\? - Opriți migrarea\? Nu s-au găsit alternative Migrați %1$s @@ -607,19 +557,6 @@ Eliminați urmărirea din aplicație Nu este urmărit Urmărit - - Un capitol a fost eliminat din sursă: -\n%2$s -\nȘtergeți descărcarea acestuia\? - %1$s capitole au fost eliminate din sursă: -\n%2$s -\n -\nȘtergeți descărcarea acestora\? - %1$s capitole au fost eliminate din sursă: -\n%2$s -\n -\nȘtergeți descărcarea acestora\? - Informații manga personalizate Eroare la distribuirea copertei Eroare la salvarea copertei @@ -652,11 +589,6 @@ Începeți să citiți Capitolul %1$s Începeți să citiți Despre aceasta %1$s - - %1$d pagină - %1$d pagini - %1$d pagini - Automat (în funcție de orientare) Cantitatea de preîncărcare a paginii Citire %1$s @@ -748,16 +680,6 @@ Apasarea continua actioneaza Saritorul de categorie Deschide o serie la intamplare Ascunde săritorul de categorii - - Curățenie făcută. A fost eliminat %d dosar - Curățenie făcută. Au fost eliminate %d dosare - Curățenie făcută. Au fost eliminate %d dosare - - - %d manga a migrat - %d mangauri au migrat - %d mangauri au migrat - Actualizări globale Peisaj blocat Nu s-a putut actualiza tipul de punctaj: %1$s @@ -790,11 +712,6 @@ Înapoi la început Ștergeți coperțile din memoria cache care nu se află în bibliotecă Loghează-te - - După %1$s minut - După %1$s minute - După %1$s minute - Filtrează grupurile de scanare Căutați în sugestii Actualizări și istoric @@ -852,11 +769,6 @@ Este posibil să nu funcționeze corect backup/restaurare dacă MIUI Optimization este dezactivată. Verificați dacă există versiuni beta Unii producători au restricții suplimentare privind aplicațiile care opresc serviciile de fundal. Acest site web conține mai multe informații despre cum să le rezolvați. - - Cache curățat. %d fișierul a fost șters - Cache curățat. %d fișiere au fost șterse - Cache curățat. %d fișiere au fost șterse - Afișați în listele de surse și extensii Salvați ca arhivă CBZ Adăugat la %1$s @@ -876,11 +788,6 @@ Orientare Ascundeți Atingeți pentru a afla mai multe - - Următorul capitol necitit - Următoarele %d capitole necitite - Următoarele %d capitole necitite - Întrebări frecvente și ghiduri La fiecare 3 zile Adăugați la %1$s @@ -889,11 +796,6 @@ S-a Instalat %1$s Optimizarea MIUI trebuie să fie dezactivată pentru a instala extensii. Nu s-a putut instala extensia - - %d actualizare în așteptare - %d actualizări în așteptare - %d actualizări în așteptare - Zoom în paginile duble Tonuri de gri Navigați la panoramare @@ -954,11 +856,6 @@ Este posibil ca unele extensii să ceară să fie instalate mai întâi. Extensiile se actualizează Extensiile au fost actualizate - - Extensia a fost actualizată - Extensiile %d au fost actualizate - Extensiile %d au fost actualizate - Divizați paginile duble în portret Actualizarea tipului de punctaj al lui %1$s Selectați o intrare @@ -997,11 +894,6 @@ Afișați la apăsare lungă Mod întunecat negru pur Afișați o bară de instrumente mai mare, extinsă, în partea de sus a majorității paginilor (nu se afișează pe dispozitivele mai mici, indiferent de setare) - - Omiterea %d capitol, fie că sursa lipsește, fie că a fost filtrată - Omiterea a %d capitole, fie că sursa nu le are, fie că au fost filtrate - Omiterea a %d capitole, fie că sursa nu le are, fie că au fost filtrate - Servicii care oferă caracteristici îmbunătățite pentru anumite surse. Manga sunt urmărite în mod automat atunci când sunt adăugate la biblioteca dumneavoastră. Actualizați urmărirea când este marcată ca fiind citită Lista completă @@ -1033,21 +925,6 @@ Distribuția scorului Vizualizați statisticile detaliate Numărate - - %d Tip de serii - %d Tipuri de serii - %d Tipuri de serii - - - %d sursă - %d surse - %d surse - - - %d Limbă - %d Limbi - %d Limbi - Tot manga citit Lungime Anul începerii @@ -1055,11 +932,6 @@ Sursă Tracker Nu s-au găsit date pentru filtrele curente - - %d status - %d statusuri - %d statusuri - Timpul petrecut în cititor, bazat pe istoricul capitolelor Ignorat deoarece seria nu necesită actualizări Șir de caractere invalid pentru agentul de utilizator @@ -1081,4 +953,4 @@ Program instalare Intrări în bibliotecă Activități în fundal - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/ru/plurals.xml b/i18n/src/commonMain/moko-resources/ru/plurals.xml new file mode 100644 index 0000000000..175ad0788a --- /dev/null +++ b/i18n/src/commonMain/moko-resources/ru/plurals.xml @@ -0,0 +1,179 @@ + + + + + Кэш очищен. %d файл был удален + Кэш очищен. %d файла было удалено + Кэш очищен. %d файлов было удалено + Кэш очищен. %d файлов было удалено + + + + Очистка завершена. %d папка удалена + Очистка завершена. %d папки удалено + Очистка завершена. %d папок удалено + Очистка завершена. %d папок удалено + + + + Копировать %1$d%2$s серию\? + Копировать %1$d%2$s серии\? + Копировать %1$d%2$s серий\? + Копировать %1$d%2$s серий\? + + + + Мигрировать %1$d%2$s серию\? + Мигрировать %1$d%2$s серии\? + Мигрировать %1$d%2$s серий\? + Мигрировать %1$d%2$s серий\? + + + + Через %1$s минуту + Через %1$s минуты + Через %1$s минут + Через %1$s минут + + + + %d серия перемещёна + %d серии перемещено + %d серий перемещено + %d серий перемещено + + + + и ещё %1$d глава + и ещё %1$d главы + и ещё %1$d глав + и ещё %1$d глав + + + + Для %d серии + Для %d серий + Для %d серий + Для %d серий + + + + Удалить %1$d загруженную главу\? + Удалить %1$d загруженных глав\? + Удалить %1$d загруженных глав\? + Удалить %1$d загруженных глав\? + + + + %1$s глава + %1$s главы + %1$s глав + %1$s глав + + + + %1$d страница осталась + %1$d страницы осталось + %1$d страниц осталось + %1$d страниц осталось + + + + %d категория + %d категории + %d категорий + %d категорий + + + + %1$s глава была удалена из источника: +\n%2$s +\nУдалить загрузку\? + %1$s главы было удалено из источника: +\n%2$s +\nУдалить загрузку\? + %1$s глав было удалено из источника: +\n%2$s +\nУдалить загрузку\? + %1$s глав было удалено из источника: +\n%2$s +\nУдалить загрузку\? + + + + Доступно %d обновление для расширения + Доступны %d обновления для расширений + Доступны %d обновлений для расширений + Доступны %d обновлений для расширений + + + + Выполнено за %1$s с %2$s ошибкой + Выполнено за %1$s с %2$s ошибками + Выполнено за %1$s с %2$s ошибками + Выполнено за %1$s с %2$s ошибками + + + + %1$d страница + %1$d страницы + %1$d страниц + %1$d страниц + + + + %d обновление ожидается + %d обновления ожидаются + %d обновлений ожидаются + %d обновлений ожидаются + + + + Обновлено %d расширение + Обновлено %d расширения + Обновлено %d расширений + Обновлено %d расширений + + + + Пропущена %d глава, так как она либо отсутствует в источнике, либо была отфильтрована + Пропущено %d главы, так как они либо отсутствуют в источнике, либо были отфильтрованы + Пропущено %d глав, так как они либо отсутствуют в источнике, либо были отфильтрованы + Пропущено %d глав, так как они либо отсутствуют в источнике, либо были отфильтрованы + + + + Следующая непрочитанная глава + Следующие %d непрочитанные главы + Следующие %d непрочитанных глав + Следующие %d непрочитанных глав + + + + %d тип серии + %d типа серии + %d типов серий + %d типов серий + + + + %d серия + %d серии + %d серий + %d серий + + + + %d статус + %d статуса + %d статусов + %d статусов + + + + %d язык + %d языка + %d языков + %d языков + + diff --git a/app/src/main/res/values-ru/strings.xml b/i18n/src/commonMain/moko-resources/ru/strings.xml similarity index 90% rename from app/src/main/res/values-ru/strings.xml rename to i18n/src/commonMain/moko-resources/ru/strings.xml index 82fa8e577d..287787a519 100644 --- a/app/src/main/res/values-ru/strings.xml +++ b/i18n/src/commonMain/moko-resources/ru/strings.xml @@ -63,12 +63,6 @@ Поисковик Дата сборки Возникла ошибка при очистке - - Кэш очищен. %d файл был удален - Кэш очищен. %d файла было удалено - Кэш очищен. %d файлов было удалено - Кэш очищен. %d файлов было удалено - Категории Общий Обновления расширения @@ -77,12 +71,6 @@ Страница %1$d Главы На зарядке - - Очистка завершена. %d папка удалена - Очистка завершена. %d папки удалено - Очистка завершена. %d папок удалено - Очистка завершена. %d папок удалено - Серии удалены Вы уверены\? Прочитанные главы и прогресс не библиотечных серий будет потерян А @@ -90,18 +78,6 @@ З К Завершено - - Копировать %1$d%2$s серию\? - Копировать %1$d%2$s серии\? - Копировать %1$d%2$s серий\? - Копировать %1$d%2$s серий\? - - - Мигрировать %1$d%2$s серию\? - Мигрировать %1$d%2$s серии\? - Мигрировать %1$d%2$s серий\? - Мигрировать %1$d%2$s серий\? - Использовать это изображение как обложку серии\? Cookies очищены %1$s скопировано в буфер обмена @@ -167,12 +143,6 @@ Загрузка… Источник пользователя Локально - - Через %1$s минуту - Через %1$s минуты - Через %1$s минут - Через %1$s минут - Всегда Никогда Блокировать при бездействии @@ -184,12 +154,6 @@ Художник Автор Статус - - %d серия перемещёна - %d серии перемещено - %d серий перемещено - %d серий перемещено - Удалено из библиотеки Мигрировать в Миграция @@ -199,21 +163,9 @@ Следующая глава не найдена Нет результатов Не выполнен вход в: %1$s - - и ещё %1$d глава - и ещё %1$d главы - и ещё %1$d глав - и ещё %1$d глав - Не удалось обновить обложку Серия должна быть в библиотеке для редактирования Новые главы найдены - - Для %d серии - Для %d серий - Для %d серий - Для %d серий - Это расширение больше недоступно. Отложено Выпускается @@ -383,24 +335,6 @@ Закладка убрана Главы удалены. Глава не найдена - - Удалить %1$d загруженную главу\? - Удалить %1$d загруженных глав\? - Удалить %1$d загруженных глав\? - Удалить %1$d загруженных глав\? - - - %1$s глава - %1$s главы - %1$s глав - %1$s глав - - - %1$d страница осталась - %1$d страницы осталось - %1$d страниц осталось - %1$d страниц осталось - Категория Добавление %1$s в очередь обновления @@ -415,12 +349,6 @@ Категория удалена Нажмите и удерживайте, чтобы изменить категорию Перейти в категорию - - %d категория - %d категории - %d категорий - %d категорий - Обновить Обновление %1$s @@ -529,20 +457,6 @@ Сбросить обложку Запомнить этот выбор Источник не установлен - - %1$s глава была удалена из источника: -\n%2$s -\nУдалить загрузку\? - %1$s главы было удалено из источника: -\n%2$s -\nУдалить загрузку\? - %1$s глав было удалено из источника: -\n%2$s -\nУдалить загрузку\? - %1$s глав было удалено из источника: -\n%2$s -\nУдалить загрузку\? - Отслеживать Отслеживается @@ -639,12 +553,6 @@ Открепить Использовать по умолчанию - - Доступно %d обновление для расширения - Доступны %d обновления для расширений - Доступны %d обновлений для расширений - Доступны %d обновлений для расширений - Отметить как «Не прочитано» Отметить предыдущие главы, как «Не прочитано» Скачать непрочитанное @@ -689,12 +597,6 @@ \nВам будет нужно установить все недостающие расширения и после этого, войти в сервисы отслеживания для их использования. Восстановление отменено %02d мин, %02d сек - - Выполнено за %1$s с %2$s ошибкой - Выполнено за %1$s с %2$s ошибками - Выполнено за %1$s с %2$s ошибками - Выполнено за %1$s с %2$s ошибками - Приложение для выбора файлов не найдено Следующее Открыть журнал @@ -746,12 +648,6 @@ БЕТА Добавлено в %1$s Добавить в %1$s - - %1$d страница - %1$d страницы - %1$d страниц - %1$d страниц - Автоматически (на основе ориентации) При использовании автоматической схемы страницы вы всё равно можете переключиться между схемами во время чтения, не переопределяя этот параметр Схема страницы @@ -862,12 +758,6 @@ Светлая тема Совпадений не найдено Источник не поддерживается - - %d обновление ожидается - %d обновления ожидаются - %d обновлений ожидаются - %d обновлений ожидаются - Не удалось установить расширение Глобальные обновления Открыть случайную серию @@ -908,12 +798,6 @@ Автообновлять расширения Разделить двойные страницы Разделить двойные страницы в портретном режиме - - Обновлено %d расширение - Обновлено %d расширения - Обновлено %d расширений - Обновлено %d расширений - Расширения обновлены Установлено %1$s Ожидается обновление для расширения @@ -933,12 +817,6 @@ По умолчанию, боковая навигация используется для определенных телефонов и небольших планшетов в альбомной ориентации и всегда используется на больших планшетах По умолчанию Использовать боковую панель навигации - - Пропущена %d глава, так как она либо отсутствует в источнике, либо была отфильтрована - Пропущено %d главы, так как они либо отсутствуют в источнике, либо были отфильтрованы - Пропущено %d глав, так как они либо отсутствуют в источнике, либо были отфильтрованы - Пропущено %d глав, так как они либо отсутствуют в источнике, либо были отфильтрованы - Полезные ссылки на перевод Помочь с переводом Фильтровать группы переводчиков @@ -1049,12 +927,6 @@ Загрузить наперёд Работает только с элементами в библиотеке, а также если текущая и следующая главы уже загружены Сортировка по времени поиска - - Следующая непрочитанная глава - Следующие %d непрочитанные главы - Следующие %d непрочитанных глав - Следующие %d непрочитанных глав - Узнайте, почему Открыть в приложении Зоны касания @@ -1086,30 +958,6 @@ Продолжительность чтения Количество Распределение статусов - - %d тип серии - %d типа серии - %d типов серий - %d типов серий - - - %d серия - %d серии - %d серий - %d серий - - - %d статус - %d статуса - %d статусов - %d статусов - - - %d язык - %d языка - %d языков - %d языков - Вся прочитанная манга Детальная статистика Распределение оценок @@ -1143,4 +991,4 @@ Настройки приложения Отладочная информация Фоновая активность - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/sc/plurals.xml b/i18n/src/commonMain/moko-resources/sc/plurals.xml new file mode 100644 index 0000000000..e120eef11c --- /dev/null +++ b/i18n/src/commonMain/moko-resources/sc/plurals.xml @@ -0,0 +1,128 @@ + + + + + B\'at un\'agiornamentu a disponimentu pro un\'estensione + B\'ant agiornamentos a disponimentu pro %d estensiones + + + + A pustis de %1$s minutu + A pustis de %1$s minutos + + + + Innetadura acabada. %d cartella iscantzellada + Innetadura acabada. %d cartellas iscantzelladas + + + + Memòria temporànea isboidada. %d documentu est istadu iscantzelladu + Memòria temporànea isboidada. %d documentos sunt istados iscantzellados + + + + %d manga tramudadu + %d manga tramudados + + + + Copiare %1$d%2$s manga\? + Copiare %1$d%2$s manga\? + + + + Tramudare %1$d%2$s manga\? + Tramudare %1$d%2$s manga\? + + + + Unu capìtulu est istadu bogadu dae sa mitza: +\n%2$s +\nCheres iscantzellare s\'iscarrigamentu suo\? + %1$s capìtulos sunt istados bogados dae sa mitza: +\n%2$s +\n +\nCheres iscantzellare sos iscarrigamentos issoro\? + + + + e %1$d àteru capìtulu + e àteros %1$d capìtulos + + + + Pro %d tìtulu + Pro %d tìtulos + + + + %d categoria + %d categorias + + + + Galu %1$d pàgina + Galu %1$d pàginas + + + + Iscantzellare %1$d capìtulu iscarrigadu\? + Iscantzellare %1$d capìtulos iscarrigados\? + + + + Fatu in %1$s cun %2$s errore + Fatu in %1$s cun %2$s errores + + + + %1$s capìtulu + %1$s capìtulos + + + + %1$d pàgina + %1$d pàginas + + + + %d agiornamentu in isetu + %d agiornamentos in isetu + + + + Estensione agiornada + %d estensiones agiornadas + + + + Brinchende %d capìtulu, sa fonte non lu tenet o est istadu bogadu cun unu filtru + Brinchende %d capìtulos, sa fonte non los tenet o sunt istados bogados cun unu filtru + + + + Su capìtulu non lèghidu imbeniente + Sos %d capìtulos non lèghidos imbenientes + + + + %d fonte + %d fontes + + + + %d istadu + %d istados + + + + %d limba + %d limbas + + + + %d casta de sèrie + %d castas de sèrie + + diff --git a/app/src/main/res/values-sc/strings.xml b/i18n/src/commonMain/moko-resources/sc/strings.xml similarity index 94% rename from app/src/main/res/values-sc/strings.xml rename to i18n/src/commonMain/moko-resources/sc/strings.xml index 86c3a01301..c4ec13b5c3 100644 --- a/app/src/main/res/values-sc/strings.xml +++ b/i18n/src/commonMain/moko-resources/sc/strings.xml @@ -275,10 +275,6 @@ Verìfica su situ web cun sa visualizatzione web Obsoleta Cust\'estensione no est prus a disponimentu. - - B\'at un\'agiornamentu a disponimentu pro un\'estensione - B\'ant agiornamentos a disponimentu pro %d estensiones - Mìnimat sa creatzione de bandas, ma diat pòdere influentzare sas prestatziones Brinca sos capìtulos filtrados Verticale sighidu @@ -344,10 +340,6 @@ Iscàrriga sos non lèghidos Iscantzelladu: %1$s In bassu - - A pustis de %1$s minutu - A pustis de %1$s minutos - Iscantzella semper Mantene semper Iscantzella durante sos agiornamentos globales, pedi in sa pàgina de sos capìtulos @@ -377,10 +369,6 @@ Iscantzella sas coberteddas betzas e no impreadas de sos manga in sa biblioteca tua chi sunt istados agiornados. \nImpreende como: %1$s Inneta sas coberteddas in sa memòria temporànea - - Innetadura acabada. %d cartella iscantzellada - Innetadura acabada. %d cartellas iscantzelladas - Disabìlita custa optzione si ses tenende problemas agiornende o ripristinende sa biblioteca tua Peruna cartella de innetare Incumintzende s\'innetadura @@ -389,27 +377,11 @@ Iscantzella sos òrfanos Iscantzella sas cartellas de sos capìtulos chi no esistint, as iscarrigadu petzi in parte, o as giai lèghidu Inneta sos capìtulos iscarrigados - - Memòria temporànea isboidada. %d documentu est istadu iscantzelladu - Memòria temporànea isboidada. %d documentos sunt istados iscantzellados - Amministratzione de sos datos Non ses intradu in %1$s Riprìstinu de sa còpia de seguresa fallidu Biancu puru - - %d manga tramudadu - %d manga tramudados - (brinchende %1$d) - - Copiare %1$d%2$s manga\? - Copiare %1$d%2$s manga\? - - - Tramudare %1$d%2$s manga\? - Tramudare %1$d%2$s manga\? - Firmare su tramudòngiu\? Peruna alternativa agatada Perunu capìtulu agatadu. Custu manga non si podet impreare pro su tramudòngiu @@ -437,15 +409,6 @@ Leghende como No arrastadu Arrastadu - - Unu capìtulu est istadu bogadu dae sa mitza: -\n%2$s -\nCheres iscantzellare s\'iscarrigamentu suo\? - %1$s capìtulos sunt istados bogados dae sa mitza: -\n%2$s -\n -\nCheres iscantzellare sos iscarrigamentos issoro\? - B\'at àpidu un\'errore cumpartende sa cobertedda B\'at àpidu un\'errore sarvende sa cobertedda Cobertedda sarvada @@ -511,14 +474,6 @@ Include in s\'agiornamentu globale Ordinende in manera alfebètica ignora sos artìculos (unu, una, su, sa) a s\'incumintzu de sos tìtulos de sos manga Òrdina ignorende sos artìculos - - e %1$d àteru capìtulu - e àteros %1$d capìtulos - - - Pro %d tìtulu - Pro %d tìtulos - Àteras impostatziones de sa biblioteca Cua s\'optzione pro brincare categoria Ammustra comente @@ -556,18 +511,6 @@ Crea una categoria noa %1$s est giai in sa lista de isetu Annanghende %1$s a sa lista de agiornamentu - - %d categoria - %d categorias - - - Galu %1$d pàgina - Galu %1$d pàginas - - - Iscantzellare %1$d capìtulu iscarrigadu\? - Iscantzellare %1$d capìtulos iscarrigados\? - Capìtulu no agatadu Capìtulos bogados. Sinnalibru bogadu @@ -608,10 +551,6 @@ \nA pustis as a dèpere installare sas estensiones chi mancant e atzèdere a sos servìtzios de arrastamentu pro los pòdere impreare. Riprìstinu annulladu %02d min e %02d seg - - Fatu in %1$s cun %2$s errore - Fatu in %1$s cun %2$s errores - Ghia a su tramudòngiu de sas mitzas Cuntenutu NSFW (18+) Custu no impedit a estensiones no ufitziales o potentzialmente non curretas de ammustrare cuntenutos NSFW (18+) in s\'aplicatzione. @@ -660,10 +599,6 @@ Cua sas iconas de sos non lèghidos Annanghe/modìfica sas categorias Categoria - - %1$s capìtulu - %1$s capìtulos - Cua automaticamente su butone de navigatzione Informatziones personalizadas de su manga Ignora sas àreas segadas @@ -680,10 +615,6 @@ Sighi su tema de su sistema Froridura de beranu Intrinada de mesanote - - %1$d pàgina - %1$d pàginas - Automàtica (basada in subra de s\'orientamentu) Cando impreas sa dispositzione automàtica de sas pàginas podes galu colare dae una dispositzione a s\'àtera durante sa leghidura chene subraiscrìere custa impostatzione Dispositzione de sas pàginas @@ -794,10 +725,6 @@ Tema craru Perunu resurtadu agatadu Fonte non suportada - - %d agiornamentu in isetu - %d agiornamentos in isetu - Installatzione de s\'estensione fallida Agiornamentos globales Aberi una sèrie a casu @@ -842,10 +769,6 @@ Agiorna in automàticu sas estensiones Partzi sas pàginas dòpias Partzi in duos sas pàginas dòpias in modalidade verticale - - Estensione agiornada - %d estensiones agiornadas - Estensiones agiornadas %1$s installados Agiornamentos de sas estensiones in suspesu @@ -864,10 +787,6 @@ Intrinada zafiru Otzèanu birde abba (teal - fògia de tè) Aparèntzia - - Brinchende %d capìtulu, sa fonte non lu tenet o est istadu bogadu cun unu filtru - Brinchende %d capìtulos, sa fonte non los tenet o sunt istados bogados cun unu filtru - Ligàmenes ùtiles pro sa tradutzione Agiuda a bortare Filtra sos grupos de iscansidores @@ -950,10 +869,6 @@ Bateria non bassa PF e ghias S\'ischermu seguru cuat sos cuntenutos de s\'aplicatzione cando mudas de aplicatzione e blocat sas ischermadas - - Su capìtulu non lèghidu imbeniente - Sos %d capìtulos non lèghidos imbenientes - Agiorna s\'arrastamentu a pustis de sa leghidura Agiorna s\'arrastamentu cando as marcadu comente lèghidu Pòmpia totu @@ -1016,23 +931,7 @@ Fonte Arrastadore Longària - - %d fonte - %d fontes - - - %d istadu - %d istados - - - %d limba - %d limbas - Annu de incumintzu - - %d casta de sèrie - %d castas de sèrie - Tempus coladu in su leghidore, basadu subra de sa cronologia de sos capìtulos Brincadu ca sa sèrie non tenet bisòngiu de agiornamentos Istringa de agente de utente non vàlida @@ -1060,4 +959,4 @@ Elementos de sa biblioteca Informatziones de depuratzione de còdighe Atividade in s\'isfundu - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/si/plurals.xml b/i18n/src/commonMain/moko-resources/si/plurals.xml new file mode 100644 index 0000000000..045e125f3d --- /dev/null +++ b/i18n/src/commonMain/moko-resources/si/plurals.xml @@ -0,0 +1,3 @@ + + + diff --git a/app/src/main/res/values-si/strings.xml b/i18n/src/commonMain/moko-resources/si/strings.xml similarity index 100% rename from app/src/main/res/values-si/strings.xml rename to i18n/src/commonMain/moko-resources/si/strings.xml diff --git a/i18n/src/commonMain/moko-resources/sk/plurals.xml b/i18n/src/commonMain/moko-resources/sk/plurals.xml new file mode 100644 index 0000000000..b739e82c7d --- /dev/null +++ b/i18n/src/commonMain/moko-resources/sk/plurals.xml @@ -0,0 +1,63 @@ + + + + + Je dostupná aktualizácia pre rozšírenie + Je dostupných %d aktualizácii pre rozšírenia + Sú dostupné %d aktualizácii pre rozšírenia + + + + %d kategória + %d kategórie + %d kategórií + + + + Dokončené za %1$s s %2$s chybou + Dokončené za %1$s s %2$s chybami + Dokončené za %1$s s %2$s chybami + + + + Ďalšia neprečítaná kapitola + Ďalšie %d neprečítané kapitoly + Ďalších %d neprečítaných kapitol + + + + %1$s kapitola + %1$s kapitoly + %1$s kapitol + + + + Odstrániť %1$d stiahnutú kapitolu\? + Odstrániť %1$d stiahnute kapitoly\? + Odstrániť %1$d stiahnutých kapitol\? + + + + Zostáva %1$d strana + Zostávú %1$d strany + Zostáva %1$d stran + + + + Po %1$s minúte + Po %1$s minútach + Po %1$s minútach + + + + Pre %d titul + Pre %d tituly + Pre %d titulov + + + + Preskočenie %d kapitoly, buď zdroj chýba, alebo bol odfiltrovaný + Preskočenie %d kapitol, buď zdroj chýba, alebo bol odfiltrovaný + Zložky %d kapitoly, buď zdroj chýba, alebo boli filtrované + + diff --git a/app/src/main/res/values-sk/strings.xml b/i18n/src/commonMain/moko-resources/sk/strings.xml similarity index 93% rename from app/src/main/res/values-sk/strings.xml rename to i18n/src/commonMain/moko-resources/sk/strings.xml index c77c8974e2..cd7e4bcb7b 100644 --- a/app/src/main/res/values-sk/strings.xml +++ b/i18n/src/commonMain/moko-resources/sk/strings.xml @@ -280,11 +280,6 @@ Dátum načítaný Podľa čísla kapitoly Dostupná nová aktualizácia! - - Je dostupná aktualizácia pre rozšírenie - Je dostupných %d aktualizácii pre rozšírenia - Sú dostupné %d aktualizácii pre rozšírenia - Prihláste sa do %1$s Prosím aktualizujte si aplikáciu WebView pre lepšiu kompatibilitu Viac @@ -349,11 +344,6 @@ Naposledy prečítaná kapitola %1$s Obal uložený Nenašli sa žiadne kapitoly - - %d kategória - %d kategórie - %d kategórií - Preskočené aktualizácie: %1$d Preskočené, pretože neboli prečítané žiadne kapitoly Chyby @@ -399,11 +389,6 @@ Stav sledovania Nezoskupené Neplatný záložný súbor - - Dokončené za %1$s s %2$s chybou - Dokončené za %1$s s %2$s chybami - Dokončené za %1$s s %2$s chybami - Kategória s týmto názvom už existuje! Názov kategórie nemôže byť prázdny K dispozícii je nová beta verzia! @@ -428,11 +413,6 @@ V databáze je manga %1$d, ktorá sa nenachádza v knižnici Stiahnuť dopredu Stiahnutý obrázok sa nepodarilo rozdeliť - - Ďalšia neprečítaná kapitola - Ďalšie %d neprečítané kapitoly - Ďalších %d neprečítaných kapitol - Strana %d sa pri rozdeľovaní nenašla Funguje iba na položkách v knižnici a ak je aktuálna kapitola a nasledujúca kapitola už stiahnutá Preskočiť aktualizáciu titulov @@ -487,25 +467,10 @@ Pomôžte s prekladom Publikovanie ukončené Zrušené - - %1$s kapitola - %1$s kapitoly - %1$s kapitol - Kapitola sa nenašla Prestávka Kapitoly odstránené. Nenašli sa žiadne stránky - - Odstrániť %1$d stiahnutú kapitolu\? - Odstrániť %1$d stiahnute kapitoly\? - Odstrániť %1$d stiahnutých kapitol\? - - - Zostáva %1$d strana - Zostávú %1$d strany - Zostáva %1$d stran - Kategória je prázdna %1$s je už vo fronte Vaša knižnica je prázdna, môžete si sem pridat niečo z karty prehľadávania. @@ -527,17 +492,7 @@ Citlivosť pre skrytie ponuky pri posúvaní Uložené logy o zlyhaní Zálohovanie/obnovenie nemusí fungovať správne, ak je vypnutá optimalizácia MIUI. - - Po %1$s minúte - Po %1$s minútach - Po %1$s minútach - Predvolený reťazec pre User-Agent - - Pre %d titul - Pre %d tituly - Pre %d titulov - 18+ Ďalšia strana Odtiene šedej @@ -606,11 +561,6 @@ Štatistiky Widget nie je k dispozícii, keď je povolený zámok aplikácie Posledná aktualizácia knižnice: %s - - Preskočenie %d kapitoly, buď zdroj chýba, alebo bol odfiltrovaný - Preskočenie %d kapitol, buď zdroj chýba, alebo bol odfiltrovaný - Zložky %d kapitoly, buď zdroj chýba, alebo boli filtrované - Šedivá Aktualizácie aplikácie Vylúčené kategórie @@ -620,4 +570,4 @@ Inštalátor Záznamy v knižnici Aktivita na pozadí - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/sq/plurals.xml b/i18n/src/commonMain/moko-resources/sq/plurals.xml new file mode 100644 index 0000000000..f3ef1dcd47 --- /dev/null +++ b/i18n/src/commonMain/moko-resources/sq/plurals.xml @@ -0,0 +1,38 @@ + + + + + Po kalon %d kapitull, ose i mungon burimi ose është filtruar + Po kalon %d kapituj, ose i mungon burimi ose është filtruar + + + + Ofrohet përditësim i shtesës + Ofrohen %d përditësime shtesë + + + + %1$s kapitull + %1$s kapituj + + + + Pas %1$s minutë + Pas %1$s minutash + + + + Kapitulli tjetër i palexuar + %d kapitujt e ardhshëm të palexuar + + + + Përfunduar në %1$s me %2$s gabim + Përfunduar në %1$s me %2$s gabime + + + + %d kategori + %d kategoritë + + diff --git a/app/src/main/res/values-sq/strings.xml b/i18n/src/commonMain/moko-resources/sq/strings.xml similarity index 95% rename from app/src/main/res/values-sq/strings.xml rename to i18n/src/commonMain/moko-resources/sq/strings.xml index 7389c89027..ebe0c9c8e3 100644 --- a/app/src/main/res/values-sq/strings.xml +++ b/i18n/src/commonMain/moko-resources/sq/strings.xml @@ -7,15 +7,7 @@ Skaji Daiquiri luleshtrydhe Në ngjitje - - Po kalon %d kapitull, ose i mungon burimi ose është filtruar - Po kalon %d kapituj, ose i mungon burimi ose është filtruar - Qendra - - Ofrohet përditësim i shtesës - Ofrohen %d përditësime shtesë - Filtri me ngjyra modaliteti i përzierjes Ekran i sigurt Kategoritë @@ -77,10 +69,6 @@ Me kapituj të palexuar Krijo kopje rezervë Duke zbritur - - %1$s kapitull - %1$s kapituj - Çelsat e volumit Gabim shkarkimi Tjetra @@ -100,10 +88,6 @@ Varg i parazgjedhur i agjentit të përdoruesit Normale Shkarko vendndodhjen - - Pas %1$s minutë - Pas %1$s minutash - Rezervimi dështoi Animoni tranzicionet e faqeve Të gjitha @@ -111,10 +95,6 @@ Fotografia u ruajt E panjohur Më të rejat - - Kapitulli tjetër i palexuar - %d kapitujt e ardhshëm të palexuar - Pastro historinë Ngarkimi i faqeve dështoi: %1$s Ndalo @@ -126,10 +106,6 @@ Gabimet Lista e plotë Shtesë pabesueshme - - Përfunduar në %1$s me %2$s gabim - Përfunduar në %1$s me %2$s gabime - Djathtas Adresa e emailit Redakto @@ -405,10 +381,6 @@ Shpërndaje Shtoni Shkarkoni përpara - - %d kategori - %d kategoritë - Nuk ka lidhje rrjeti të disponueshme Ndalon leximin e historisë Kapërceni kapitujt e kopjuar @@ -439,4 +411,4 @@ %1$d hyrje jashtë bibliotekës në bazën e të dhënave Fshi historikun për shënimet që nuk janë ruajtur në bibliotekën tënde Aktiviteti në sfond - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/sr/plurals.xml b/i18n/src/commonMain/moko-resources/sr/plurals.xml new file mode 100644 index 0000000000..3d081648d7 --- /dev/null +++ b/i18n/src/commonMain/moko-resources/sr/plurals.xml @@ -0,0 +1,155 @@ + + + + + Доступна је нова верзија екстензије + %d нове верзије екстензије су доступне + %d нових верзија екстензија су доступна + + + + %d kategorija + %d kategorije + %d kategoriji + + + + Прескаче се %d поглавље, или не постоји у извору или је филтером издвојено + Прескаче се %d поглавља, или не постоји у извору или је филтером издвојено + Прескаче се %d поглавља, или не постоји у извору или је филтером издвојено + + + + Завршено у %1$s са %2$s грешком + Завршено у %1$s са %2$s грешке + Завршено у %1$s са %2$s грешака + + + + Keš je obrisan. %d datoteka je izbrisana + Keš je obrisan. %d datoteke su izbrisane + Keš je obrisan. %d datoteke su izbrisane + + + + Kopiraj %1$d%2$s mangu\? + Kopiraj %1$d%2$s mange\? + Koporaj %1$d%2$s mangi\? + + + + Nakon %1$s minut + Nakon %1$s minuta + Nakon %1$s minuta + + + + %d ažuriranje je na čekanju + %d ažuriranja su na čekanju + %d ažuriranje je na čekanju + + + + %1$d strana + %1$d strane + %1$d Stranice + + + + Čišćenje završeno.Uklonjena %d fascikla + Čišćenje završeno.Uklonjene %d fascikle + Čišćenje završeno.Uklonjenj %d fascikli + + + + %1$d strana ostala + %1$d strana ostalo + %1$d strana ostalo + + + + Поглавље је уклоњено из извора: +\n%2$s +\nИзбрисати преузимање\? + %1$s поглавља је уклоњено из извора: +\n%2$s +\n +\nИзбрисати преузимања\? + %1$s поглавља је уклоњено из извора: +\n%2$s +\n +\nИзбрисати преузимања\? + + + + %d manga prebačena + %d mangi prebačeno + %d mangi prebačeno + + + + Premestite %1$d%2$s mangu\? + Premestine %1$d%2$s mange\? + Premestite %1$d%2$s mangi\? + + + + %1$s poglavlje + %1$s poglavlja + %1$s poglavlja + + + + Za %d naslov + Za %d naslove + Za %d naslovi + + + + Još %1$d naslov + Još %1$d naslova + Jos %1$d naslova + + + + Izbrisati %1$d preuzeto poglavlje\? + Izbrisati %1$d preuzeta poglavlja\? + Izbrisati %1$d preuzetih poglavlja\? + + + + Екстензија ажурирана + %d екстензије су ажуриране + %d екстензија је ажурирано + + + + Следеће непрочитано поглавље + Следећа %d непрочитана поглавља + Следећих %d непрочитаних поглавља + + + + %d врста серије + %d врсте серије + %d врста серија + + + + %d статус + %d статуса + %d статуса + + + + %d извор + %d извора + %d извора + + + + %d језик + %d језика + %d језика + + diff --git a/app/src/main/res/values-sr/strings.xml b/i18n/src/commonMain/moko-resources/sr/strings.xml similarity index 91% rename from app/src/main/res/values-sr/strings.xml rename to i18n/src/commonMain/moko-resources/sr/strings.xml index a9fbf5f3f7..f3dfe0d43d 100644 --- a/app/src/main/res/values-sr/strings.xml +++ b/i18n/src/commonMain/moko-resources/sr/strings.xml @@ -223,11 +223,6 @@ Proveri vebsajt u WebView Zastarjelo Овај додатак није више доступан. - - Доступна је нова верзија екстензије - %d нове верзије екстензије су доступне - %d нових верзија екстензија су доступна - Постави као омот Sledeće poglavlje nije pronađeno Koristite ovu sliku kao naslovnu\? @@ -316,28 +311,13 @@ Враћање је отказано %02d мин, %02d сек Otvori zapisnik - - %d kategorija - %d kategorije - %d kategoriji - Naredno poglavlje Prijašnje poglavlje Praćeno Pretraži globalno Prekini sve za ovaj serijal - - Прескаче се %d поглавље, или не постоји у извору или је филтером издвојено - Прескаче се %d поглавља, или не постоји у извору или је филтером издвојено - Прескаче се %d поглавља, или не постоји у извору или је филтером издвојено - Резервна копија/враћање можда неће радити исправно ако није омогућена MIUI оптимизација. Захтева поновно покретање апликације - - Завршено у %1$s са %2$s грешком - Завршено у %1$s са %2$s грешке - Завршено у %1$s са %2$s грешака - У облику слова L Neki proizvođači imaju dodatna ograničenja za aplikacije koja gase servise koji su u pozadini. Ovaj sajt sadrži više informacija o mogućim rešenjima. Неисправна датотека резервне копије @@ -451,11 +431,6 @@ Želi te li da izbrišete sva preuzimanja\? Veličina mreže Izaberite nijedan - - Keš je obrisan. %d datoteka je izbrisana - Keš je obrisan. %d datoteke su izbrisane - Keš je obrisan. %d datoteke su izbrisane - Očiatite preuzeta poglavlja Očisti mange koje nisu u biblioteci Počinje čišćenje @@ -504,11 +479,6 @@ Kopirajte sada Podglavlja nisu pronadjena, ova manga se nemože koristiti za migraciju Prestati sa migracijom\? - - Kopiraj %1$d%2$s mangu\? - Kopiraj %1$d%2$s mange\? - Koporaj %1$d%2$s mangi\? - (Preskakanje %1$d) Uključ %s Isključi %s @@ -536,11 +506,6 @@ Izbriši tokom globalnih ažuriranja, pitajte na stranici poglavlja Uvek izbriši Sačuvaj kao CBZ arhivu - - Nakon %1$s minut - Nakon %1$s minuta - Nakon %1$s minuta - Dodato u%1$s BETA Promeniti @@ -591,11 +556,6 @@ MIUI optimizacija mora biti ugašena da bi instalirali ekstenzije. Neke ekstenzije mogu idalje da raze da se prvo instaliraju. Ažuriranje ekstenzija - - %d ažuriranje je na čekanju - %d ažuriranja su na čekanju - %d ažuriranje je na čekanju - Ekstenzije su ažurirane Postavi prvu stranu kao koricu Podelite prvu stranicu @@ -679,11 +639,6 @@ Pametno (na osnovu stranice) Zanemarite područja izreza Raspored na stranici - - %1$d strana - %1$d strane - %1$d Stranice - Nastavi čitati poglavlje %1$s Deo %1$d Sezona %1$d @@ -697,11 +652,6 @@ Čokoladne jagode Zadnje korišćeno (Biblioteka ili Nedavni) Pretražujte samo zakačene izvore - - Čišćenje završeno.Uklonjena %d fascikla - Čišćenje završeno.Uklonjene %d fascikle - Čišćenje završeno.Uklonjenj %d fascikli - Uparite zakačene izvore Podudari omogućene izvore Omogućite samo trenutno omogućene izvore za migraciju @@ -725,11 +675,6 @@ \n \nNa sledećem ekranu, dozvolu \"Dozvoli pristum za upravljanje svih datoteka.\" TachiyomiJ2K traži pristum svim datotekama povodom preuzimanja ppglavlja.Pritisni ovde,a onda dozvoli \"Dozvolite pristum za upravljanje svim datotekama.\" - - %1$d strana ostala - %1$d strana ostalo - %1$d strana ostalo - Po redosledu izvora Kategorija sa tim imenom već postoji! Nije moguće instalirati ažuriranje @@ -777,19 +722,6 @@ Izaberite krajne poglavlje Koreanska manga Prilagodjene informacije o mangi - - Поглавље је уклоњено из извора: -\n%2$s -\nИзбрисати преузимање\? - %1$s поглавља је уклоњено из извора: -\n%2$s -\n -\nИзбрисати преузимања\? - %1$s поглавља је уклоњено из извора: -\n%2$s -\n -\nИзбрисати преузимања\? - Tragač se nemože ukloniti sa %1$s ako ste van mreže Migracija Sačuvaj oba na %1$s i samo zameni lokalno @@ -798,17 +730,7 @@ Sledeći put preskoči ovaj korak Jin Alternative nisu pronadjene - - %d manga prebačena - %d mangi prebačeno - %d mangi prebačeno - Svetla tema - - Premestite %1$d%2$s mangu\? - Premestine %1$d%2$s mange\? - Premestite %1$d%2$s mangi\? - Klasična plava Tamna tema Plavozeleni okean @@ -843,26 +765,6 @@ Dodaj kategoriju %d po redu Pokaži broj nepročitanih - - %1$s poglavlje - %1$s poglavlja - %1$s poglavlja - - - Za %d naslov - Za %d naslove - Za %d naslovi - - - Još %1$d naslov - Još %1$d naslova - Jos %1$d naslova - - - Izbrisati %1$d preuzeto poglavlje\? - Izbrisati %1$d preuzeta poglavlja\? - Izbrisati %1$d preuzetih poglavlja\? - %1$s je već u redosledu Napravi novu kategoriju Nova kategorija @@ -905,11 +807,6 @@ Meni Označi sve kao pročitano Označi sve kao nepročitano - - Екстензија ажурирана - %d екстензије су ажуриране - %d екстензија је ажурирано - Kada sortirate prema abecedi, sortirajte ignorišući članke (a,an, the) na početku naslova mangi Početni ekran Automatska ažuriranja @@ -991,11 +888,6 @@ 5% Preuzeta poglavlja Начин навигације - - Следеће непрочитано поглавље - Следећа %d непрочитана поглавља - Следећих %d непрочитаних поглавља - Лаванда Подразумеван низ корисничког агента Страница %d није пронађена током раздвајања @@ -1029,11 +921,6 @@ Број Неоцењено Сива - - %d врста серије - %d врсте серије - %d врста серија - Сортирај према времену преузимања По серијама По недељи @@ -1049,31 +936,16 @@ Наслови у колекцији Расподела статуса Време проведено у читачу, на основу историје поглавља - - %d статус - %d статуса - %d статуса - Нема пронађених података за тренутни филтер Расподела оцене Погледај детаљну статистику Трекер - - %d извор - %d извора - %d извора - Љубичаста Статистика Ажурирања апликације Статистике Детаљи статистика Прочитаним поглављима - - %d језик - %d језика - %d језика - Сазнај зашто Отвори Прикажи више поглавља @@ -1086,4 +958,4 @@ Наслови колекције Информације за отклањање грешака Активност у позадини - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/sv/plurals.xml b/i18n/src/commonMain/moko-resources/sv/plurals.xml new file mode 100644 index 0000000000..8828125957 --- /dev/null +++ b/i18n/src/commonMain/moko-resources/sv/plurals.xml @@ -0,0 +1,128 @@ + + + + + Tilläggsuppdatering tillgänglig + %d tilläggsuppdateringar tillgängliga + + + + Klar på %1$s med %2$s fel + Klar på %1$s med %2$s fel + + + + %d kategori + %d kategorier + + + + %1$d sida kvar + %1$d sidor kvar + + + + %1$s kapitel + %1$s kapitel + + + + Ta bort %1$d nerladdade kapitel\? + Ta bort%1$d nerladdade kapitel\? + + + + och %1$d ytterligare kapitel + och %1$d ytterligare kapitel + + + + För %d titel + För %d titlar + + + + Ett kapitel har tagits bort från källan: +\n%2$s +\nTa bort nedladdningen\? + %1$s kapitel har tagits bort från källan: +\n%2$s +\n +\nTa bort nedladdningen\? + + + + %1$d sida + %1$d sidor + + + + Rensning klar. %d mapp har tagits bort + Rensning klar. %d mappar har tagits bort + + + + Cache rensad. %d fil har tagits bort + Cache rensad. %d filer har tagits bort + + + + %d serie migrerad + %d serier migrerade + + + + Kopiera %1$d%2$s serie\? + Kopiera %1$d%2$s serier\? + + + + Migrera %1$d%2$s serie\? + Migrera %1$d%2$s serier\? + + + + Efter %1$s minut + Efter %1$s minuter + + + + %d uppdatering väntar + %d uppdateringar väntar + + + + Tillägget uppdaterat + %d tillägg uppdaterade + + + + Hoppar över %d kapitel, antingen saknar källan det eller så har det filtrerats bort + Hoppar över %d kapitel, antingen saknar källan dem eller så har de filtrerats bort + + + + Nästa olästa kapitel + Nästa %d olästa kapitel + + + + %d typ av serie + %d typer av serier + + + + %d källa + %d källor + + + + %d status + %d statusar + + + + %d språk + %d språk + + diff --git a/app/src/main/res/values-sv/strings.xml b/i18n/src/commonMain/moko-resources/sv/strings.xml similarity index 93% rename from app/src/main/res/values-sv/strings.xml rename to i18n/src/commonMain/moko-resources/sv/strings.xml index dc0169a1f0..fd76e23b28 100644 --- a/app/src/main/res/values-sv/strings.xml +++ b/i18n/src/commonMain/moko-resources/sv/strings.xml @@ -288,10 +288,6 @@ Kontrollera webbplatsen i WebView Obsolet Detta tillägg är inte längre tillgänglig. - - Tilläggsuppdatering tillgänglig - %d tilläggsuppdateringar tillgängliga - Minskar bandning, men kan påverka prestandan Skippa filtrerade kapitel Kontinuerlig vertikal @@ -351,10 +347,6 @@ \nDu måste installera eventuella tillägg som saknas och logga in på spårningstjänster efteråt för att kunna använda dem. Avbruten återställning %02d minuter, %02d sekunder - - Klar på %1$s med %2$s fel - Klar på %1$s med %2$s fel - Migreringsguide för källor NSFW (18+) källor Detta förhindrar inte inofficiella eller potentiellt felaktigt flaggade tillägg från att visa NSFW(18+) innehåll i appen. @@ -382,10 +374,6 @@ Påbörjat läsdatum Avslutat läsdatum Vänligen logga in på MAL igen - - %d kategori - %d kategorier - Säkerhetskopiering och återställning Förlopp Färdig @@ -418,18 +406,6 @@ %1$s är redan i kö Lägger till %1$s i uppdaterings kön Kategori - - %1$d sida kvar - %1$d sidor kvar - - - %1$s kapitel - %1$s kapitel - - - Ta bort %1$d nerladdade kapitel\? - Ta bort%1$d nerladdade kapitel\? - Kapitlet hittades inte Kapitel borttagna. Ta bort bokmärke @@ -445,14 +421,6 @@ Inkludera i global uppdatering När du sorterar alfabetiskt, sorterar du ignorerande artiklar (eng. a, an, the) i början av seriens titel Sortera genom att ignorera artiklar - - och %1$d ytterligare kapitel - och %1$d ytterligare kapitel - - - För %d titel - För %d titlar - Fler biblioteksinställningar Ladda ner olästa Säkerhetskopiering pågår redan @@ -526,15 +494,6 @@ Ta också bort från %1$s Ta bort spårning från appen Spåras inte - - Ett kapitel har tagits bort från källan: -\n%2$s -\nTa bort nedladdningen\? - %1$s kapitel har tagits bort från källan: -\n%2$s -\n -\nTa bort nedladdningen\? - Anpassad serieinfo Fel vid delning av omslag Det gick inte att spara omslaget @@ -569,10 +528,6 @@ Börja läsa kapitel %1$s Börja läsa Om detta %1$s - - %1$d sida - %1$d sidor - Automatiskt (baserat på orientering) När du använder automatisk sidlayout kan du ändå växla mellan layouter medan du läser utan att åsidosätta denna inställning Sidlayout @@ -617,10 +572,6 @@ Ta bort gamla och oanvända cachade omslag av poster i ditt bibliotek som har uppdaterats. \nAnvänder för närvarande: %1$s Rensa cachelagrade omslag - - Rensning klar. %d mapp har tagits bort - Rensning klar. %d mappar har tagits bort - Inaktivera detta om du har problem med att uppdatera eller återställa ditt bibliotek Inga mappar att rensa Startar rensning @@ -629,10 +580,6 @@ Rengör föräldralösa Ta bort obefintliga mappar, delvis nedladdade mappar och läs kapitel mappar Rensa nerladdade kapitel - - Cache rensad. %d fil har tagits bort - Cache rensad. %d filer har tagits bort - Datahanteing Inte inloggad mot %1$s Det gick inte att återställa säkerhetskopian @@ -646,19 +593,7 @@ Ren vit Vårblommor Midnattskymning - - %d serie migrerad - %d serier migrerade - (hoppar över %1$d) - - Kopiera %1$d%2$s serie\? - Kopiera %1$d%2$s serier\? - - - Migrera %1$d%2$s serie\? - Migrera %1$d%2$s serier\? - Sluta migrera\? Inga alternativ hittades Inga kapitel hittade, denna serie kan inte användas för migrering @@ -690,10 +625,6 @@ BETA Tillagt i %1$s Lägg till i %1$s - - Efter %1$s minut - Efter %1$s minuter - Ta alltid bort Behåll alltid Ta bort under globala uppdateringar, fråga på kapitelsidan @@ -794,10 +725,6 @@ Ljust tema Inga träffar hittades Källan stöds inte - - %d uppdatering väntar - %d uppdateringar väntar - Det gick inte att installera tillägget Globala uppdateringar Öppna en slumpmässig serie @@ -836,10 +763,6 @@ Det gick inte att installera uppdateringen Komma igång guide Dela dubbelsidor i porträtt - - Tillägget uppdaterat - %d tillägg uppdaterade - Tilläggsuppdateringar Installerat %1$s Väntande tilläggsuppdateringar @@ -848,10 +771,6 @@ Inga träffar med dina filter Visa tomma kategorier vid filtrering Hjälp till med översättning - - Hoppar över %d kapitel, antingen saknar källan det eller så har det filtrerats bort - Hoppar över %d kapitel, antingen saknar källan dem eller så har de filtrerats bort - Dela på dubbel sidor Nyligen installerad Nyligen uppdaterad @@ -960,10 +879,6 @@ Hantera aviseringar Batteriet är inte lågt Vanliga frågor och guider - - Nästa olästa kapitel - Nästa %d olästa kapitel - Ladda ner i förväg Fungerar endast för poster i biblioteket och om det aktuella kapitlet och nästa kapitel redan har laddats ner Lär dig varför @@ -1012,22 +927,6 @@ Spårare Lästid Se detaljerad statistik - - %d typ av serie - %d typer av serier - - - %d källa - %d källor - - - %d status - %d statusar - - - %d språk - %d språk - Alla lästa serier Behåll inlägg med lästa kapitel Poängfördelning @@ -1063,4 +962,4 @@ Appinställningar Felsökningsinformation Bakgrundsaktivitet - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/te/plurals.xml b/i18n/src/commonMain/moko-resources/te/plurals.xml new file mode 100644 index 0000000000..9aef7a17be --- /dev/null +++ b/i18n/src/commonMain/moko-resources/te/plurals.xml @@ -0,0 +1,8 @@ + + + + + ఒక నిమిషము తరువాత%1$s నిమిషముల తరువాత + + + diff --git a/app/src/main/res/values-te/strings.xml b/i18n/src/commonMain/moko-resources/te/strings.xml similarity index 98% rename from app/src/main/res/values-te/strings.xml rename to i18n/src/commonMain/moko-resources/te/strings.xml index b465cfb372..2baba87ede 100644 --- a/app/src/main/res/values-te/strings.xml +++ b/i18n/src/commonMain/moko-resources/te/strings.xml @@ -114,10 +114,6 @@ లోడ్ అవుతుంది… మార్గదర్శనము ఈ ధారావాహిక కొరకు అన్నిటిని రద్దు చెయ్యుము - - ఒక నిమిషము తరువాత%1$s నిమిషముల తరువాత - - పిన్ తప్పిద వివరములను చూచుటకై నొక్కుము అనువర్తనములను మారునపుడు వర్తక విషయములను దాయుము మరియు తెర యొక్క చిత్రములను తీయుటను నిరోధించుము @@ -239,4 +235,4 @@ ప్రతిరోజు తాళమును తెరుచుట ఆవశ్యకము లైబ్రరీ ఎంట్రీలు - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/th/plurals.xml b/i18n/src/commonMain/moko-resources/th/plurals.xml new file mode 100644 index 0000000000..a741c0bd1e --- /dev/null +++ b/i18n/src/commonMain/moko-resources/th/plurals.xml @@ -0,0 +1,102 @@ + + + + + ใช้เวลาไป %1$s โดยมีข้อผิดพลาด %2$s รายการ + + + + %d หมวดหมู่ + + + + มีการอัปเดตส่วนขยาย %d รายการพร้อมใช้งาน + + + + ข้ามตอนที่ %d อาจเป็นเพราะหายมาจากแหล่งที่มาหรือถูกกรองออก + + + + โยกย้าย %1$d%2$s เรื่อง\? + + + + คัดลอก %1$d%2$s เรื่อง\? + + + + ล้างเสร็จสิ้น ลบออกไป %d โฟล์เดอร์ + + + + ต้องการนำ %1$d ตอนที่ดาวน์โหลดไว้ออกหรือไม่\? + + + + %1$s ตอน + + + + %d เรื่องได้โยกย้ายแล้ว + + + + ล้างแคชแล้ว แฟ้ม %d รายการได้ถูกลบ + + + + หลังจาก %1$s นาที + + + + ของเรื่อง %d + + + + และอีก %1$d ตอน + + + + อัปเดต %d รายการที่รอดำเนินการ + + + + อัปเดตแล้ว %d ส่วนขยาย + + + + %1$d หน้า + + + + %1$s ตอนได้ถูกนำออกจากแหล่งที่มาแล้ว: +\n%2$s +\n +\nต้องการลบการดาวน์โหลด\? + + + + เหลือ %1$d หน้า + + + + %d ตอนที่ยังไม่ได้อ่านถัดไป + + + + %d ประเภทเรื่อง + + + + %d สถานะ + + + + %d ภาษา + + + + %d แหล่งที่มา + + diff --git a/app/src/main/res/values-th/strings.xml b/i18n/src/commonMain/moko-resources/th/strings.xml similarity index 96% rename from app/src/main/res/values-th/strings.xml rename to i18n/src/commonMain/moko-resources/th/strings.xml index 41e1fc94bf..a9496a499b 100644 --- a/app/src/main/res/values-th/strings.xml +++ b/i18n/src/commonMain/moko-resources/th/strings.xml @@ -286,9 +286,6 @@ บันทึกบันทึกข้อขัดข้องแล้ว ต้องรีสตาร์ทแอปจึงจะมีผล ยกเลิกการคืนค่า - - ใช้เวลาไป %1$s โดยมีข้อผิดพลาด %2$s รายการ - %02d นาที %02d วินาที ประเภทแฟ้มข้อมูลสำรองไม่ถูกต้อง: %1$s \nควรลงท้ายด้วย .proto.gz หรือ .json @@ -333,9 +330,6 @@ การสำรองข้อมูลล้มเหลว ตลอดเวลา แหล่งที่มา NSFW (18+) - - %d หมวดหมู่ - แนวตั้งต่อเนื่อง ตอนที่ %1$s การตั้งค่าการค้นหา @@ -357,9 +351,6 @@ ตอนล่าสุด เครื่องหมาย อาจมีเนื้อหา NSFW (18+) - - มีการอัปเดตส่วนขยาย %d รายการพร้อมใช้งาน - โหมดการอ่าน หน้าก่อนหน้า ลดปัญหาแถบสี แต่อาจส่งผลต่อประสิทธิภาพ @@ -408,9 +399,6 @@ ความคืบหน้า ตรวจสอบการอัปเดตส่วนขยาย การสำรอง/กู้คืนอาจทำงานไม่ถูกต้องหากปิดใช้งานการเพิ่มประสิทธิภาพ MIUI - - ข้ามตอนที่ %d อาจเป็นเพราะหายมาจากแหล่งที่มาหรือถูกกรองออก - ไม่พบตอน ไม่รองรับแหล่งที่มานี้ ผู้ผลิตบางรายมีข้อจำกัดเพิ่มเติมของแอปที่ปิดบริการพื้นหลัง เว็บไซต์นี้มีข้อมูลเพิ่มเติมเกี่ยวกับวิธีการแก้ไข @@ -464,13 +452,7 @@ ใช้แหล่งที่มาที่มีตอนมากที่สุด (ช้ากว่า) (ข้าม %1$d) ธีมสว่าง - - โยกย้าย %1$d%2$s เรื่อง\? - คลาสสิคบลู - - คัดลอก %1$d%2$s เรื่อง\? - ใช้แถบนำทางด้านข้าง ตามค่าเริ่มต้น แถบการนำทางด้านข้างจะใช้สำหรับโทรศัพท์บางรุ่นและแท็บเล็ตขนาดเล็กเมื่ออยู่ในแนวนอน และจะแสดงบนแท็บเล็ตขนาดใหญ่เสมอ อัปเดตแอปอัตโนมัติ @@ -478,9 +460,6 @@ ผ่านทุกเครือข่าย แสดงเรื่องล่าสุด ล้างรายการที่ไม่มีอยู่ในคลัง - - ล้างเสร็จสิ้น ลบออกไป %d โฟล์เดอร์ - ลบหน้าปกเก่าและไม่ได้ใช้ของรายการที่อยู่ในคลังอัปเดต \nกำลังใช้: %1$s ล้างแคชภาพปกที่ไม่ได้อยู่ในคลังทั้งหมด @@ -555,14 +534,8 @@ อัปเดตล่าสุด เพิ่งติดตั้ง ก่อนหน้า - - ต้องการนำ %1$d ตอนที่ดาวน์โหลดไว้ออกหรือไม่\? - มีอะไรใหม่ในรุ่นนี้ จำเป็นต้องเปิดใช้งาน %1$s ก่อน - - %1$s ตอน - หน้ารีลีส เรียงตามที่แหล่งที่มาจัดไว้ มังหัว @@ -598,9 +571,6 @@ โยกย้ายไปยัง คัดลอกเลย หยุดโยกย้าย\? - - %d เรื่องได้โยกย้ายแล้ว - มิดไนท์ดัสก์ ไลม์เรียบ ขาวสนิท @@ -632,9 +602,6 @@ ล้างแคชภาพปก ล้างแคชภาพปกที่ไม่ได้อยู่ในคลัง แจ้งเตือนเมื่อส่วนขยายถูกอัปเดตแล้ว - - ล้างแคชแล้ว แฟ้ม %d รายการได้ถูกลบ - ค้นหาเฉพาะแหล่งที่ตรึงไว้ แหล่งที่มาที่ตรึงไว้เท่านั้น แหล่งที่มาที่เปิดไว้เท่านั้น @@ -646,9 +613,6 @@ กำลังดาวน์โหลด: %1$s ไม่ได้ดาวน์โหลดไว้ เริ่มดาวน์โหลดเลย - - หลังจาก %1$s นาที - เบตา ล่าง เปลี่ยน @@ -667,12 +631,6 @@ การจัดเรียงและตัวกรอง บน ใช้ค่าเริ่มต้น - - ของเรื่อง %d - - - และอีก %1$d ตอน - ข้อจำกัด: %1$s เรียงแบบยกเว้นคำนำหน้าคำนาม อัปเดตทั้งหมด @@ -683,13 +641,7 @@ อัปเดตทั้งหมด ส่วนขยายบางรายการอาจยังแจ้งให้ติดตั้งก่อน กำลังอัปเดตส่วนขยาย - - อัปเดต %d รายการที่รอดำเนินการ - อัปเดตส่วนขยายแล้ว - - อัปเดตแล้ว %d ส่วนขยาย - ตั้งเป็นค่าเริ่มต้นสำหรับทั้งหมด หน้า %1$s ตั้งหน้าแรกเป็นหน้าปก @@ -703,9 +655,6 @@ เปิดใช้งานการซูมออก จำนวนหน้าโหลดล่วงหน้า ตัดขอบ (แสดงเป็นหน้า) - - %1$d หน้า - หน้าเดียว สลับเป็นสองหน้า อัตโนมัติ (ตามหน้า) @@ -805,12 +754,6 @@ อ่านต่อ ไม่ได้ติดตาม ตัวกรองกลุ่มผู้แปล - - %1$s ตอนได้ถูกนำออกจากแหล่งที่มาแล้ว: -\n%2$s -\n -\nต้องการลบการดาวน์โหลด\? - กำลังอ่านขณะนี้ อยากอ่าน ใช้ล่าสุด (คลังและล่าสุด) @@ -824,9 +767,6 @@ ใช้วันที่แนะนำ หยิน ผู้แปล - - เหลือ %1$d หน้า - แสดงเครื่องหมายยังไม่ได้อ่าน กำลังเพิ่ม %1$s ไปยังคิวอัปเดต หมวดหมู่ว่างเปล่า @@ -938,9 +878,6 @@ ขอแนะนำให้สำรองข้อมูลอัตโนมัติ คุณควรเก็บสำเนาไว้ที่อื่นด้วยเช่นกัน ใช้ได้เฉพาะกับรายการที่อยู่ในคลังและตอนปัจจุบันกับตอนถัด ๆ ไปดาวน์โหลดไว้อยู่แล้ว ดาวน์โหลดล่วงหน้า - - %d ตอนที่ยังไม่ได้อ่านถัดไป - จัดการการแจ้งเตือน แบตเตอรี่ยังไม่ต่ำ คำถามที่พบบ่อยและคู่มือ @@ -989,24 +926,12 @@ ตัวติดตาม ความยาว ไม่พบข้อมูลสำหรับการกรองนี้ - - %d ประเภทเรื่อง - - - %d สถานะ - - - %d ภาษา - สถิติ สถิติ เรื่องในคลัง เรื่องในการอัปเดตทั้งหมด ความกระจายของคะแนน ปีที่เริ่ม - - %d แหล่งที่มา - เวลาที่ใช้ไปในตัวอ่านตามประวัติของการอ่าน ถูกข้ามเนื่องจากเรื่องไม่จำเป็นต้องถูกอัปเดต สตริงตัวแทนผู้ใช้ไม่ถูกต้อง @@ -1037,4 +962,4 @@ การตั้งค่าแอป ข้อมูลดีบัก กิจกรรมเบื้องหลัง - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/ti/plurals.xml b/i18n/src/commonMain/moko-resources/ti/plurals.xml new file mode 100644 index 0000000000..045e125f3d --- /dev/null +++ b/i18n/src/commonMain/moko-resources/ti/plurals.xml @@ -0,0 +1,3 @@ + + + diff --git a/app/src/main/res/values-ti/strings.xml b/i18n/src/commonMain/moko-resources/ti/strings.xml similarity index 100% rename from app/src/main/res/values-ti/strings.xml rename to i18n/src/commonMain/moko-resources/ti/strings.xml diff --git a/i18n/src/commonMain/moko-resources/tl/plurals.xml b/i18n/src/commonMain/moko-resources/tl/plurals.xml new file mode 100644 index 0000000000..106817247b --- /dev/null +++ b/i18n/src/commonMain/moko-resources/tl/plurals.xml @@ -0,0 +1,8 @@ + + + + + Tapos na ang paglilinis. Nakapagtanggal ng %d folder. + Tapos na ang paglilinis. Nakapagtanggal ng %d na mga folder. + + diff --git a/app/src/main/res/values-tl/strings.xml b/i18n/src/commonMain/moko-resources/tl/strings.xml similarity index 98% rename from app/src/main/res/values-tl/strings.xml rename to i18n/src/commonMain/moko-resources/tl/strings.xml index f1dab9a8bd..69eab30f00 100644 --- a/app/src/main/res/values-tl/strings.xml +++ b/i18n/src/commonMain/moko-resources/tl/strings.xml @@ -291,10 +291,6 @@ Burahin ang mga luma at hindi na ginagamit na naka-cache na pabalat sa iyong library na pinalitan na. \nKasalukuyang ginagamit: %1$s Linisin ang naka-cache na pabalat - - Tapos na ang paglilinis. Nakapagtanggal ng %d folder. - Tapos na ang paglilinis. Nakapagtanggal ng %d na mga folder. - Naka-disable na ang battery optimization I-disable ito kapag ikaw ay nakararanas ng aberya sa pag-update o restore ng iyong library I-disable ang pag-optimize sa baterya @@ -309,4 +305,4 @@ Pangalan Kailangan ng pahintulot sa file Tako - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/tr/plurals.xml b/i18n/src/commonMain/moko-resources/tr/plurals.xml new file mode 100644 index 0000000000..34e1a5eb9a --- /dev/null +++ b/i18n/src/commonMain/moko-resources/tr/plurals.xml @@ -0,0 +1,128 @@ + + + + + Uzantı güncellemesi var + %d uzantı güncellemesi var + + + + %d kategori + %d kategoriler + + + + %1$d sayfa kaldı + %1$d sayfa kaldı + + + + İndirilmiş %1$d bölüm silinsin mi\? + İndirilmiş %1$d bölüm silinsin mi\? + + + + %1$s içinde %2$s hatayla tamamlandı + %1$s içinde %2$s hatayla tamamlandı + + + + %1$d sayfa + %1$d sayfa + + + + ve %1$d bölüm daha + ve %1$d bölüm daha + + + + %d başlık için + %d başlık için + + + + %1$s bölüm + %1$s bölüm + + + + Önbellek temizlendi. %d dosya silindi + Önbellek temizlendi. %d dosya silindi + + + + %1$d%2$s manga kopyala\? + %1$d%2$s manga kopyala\? + + + + %d manga geçiş yaptı + %d manga geçiş yaptı + + + + %1$d%2$s mangayı geçiş yap\? + %1$d%2$s mangayı geçiş yap\? + + + + Temizleme bitti. %d klasörü kaldırıldı + Temizleme bitti. %d klasörü kaldırıldı + + + + Kaynaktan bir bölüm kaldırıldı: +\n%2$s +\nİndirmesi silinsin mi\? + Kaynaktan %1$s bölüm kaldırıldı: +\n%2$s +\n +\nİndirmesi silinsin mi\? + + + + %1$s dakika sonra + %1$s dakika sonra + + + + 1 güncelleme beklemede + %d güncelleme beklemede + + + + Uzantı güncellendi + %d uzantı güncellendi + + + + %d bölüm atlanıyor, ya kaynakta yok ya da süzgeçlenmiş + %d bölüm atlanıyor, ya kaynakta yok ya da süzgeçlenmiş + + + + Sonraki okunmayan bölüm + Sonraki %d okunmayan bölüm + + + + %d kaynak + %d kaynak + + + + %d durum + %d durum + + + + %d dil + %d dil + + + + %d seri türü + %d seri türü + + diff --git a/app/src/main/res/values-tr/strings.xml b/i18n/src/commonMain/moko-resources/tr/strings.xml similarity index 94% rename from app/src/main/res/values-tr/strings.xml rename to i18n/src/commonMain/moko-resources/tr/strings.xml index 63d08d5aa8..8df178a605 100644 --- a/app/src/main/res/values-tr/strings.xml +++ b/i18n/src/commonMain/moko-resources/tr/strings.xml @@ -273,10 +273,6 @@ Web sitesini WebView\'de görüntüle Eski Bu uzantı artık kullanılamaz. - - Uzantı güncellemesi var - %d uzantı güncellemesi var - Renk şeritlerini azaltır, ancak performansı etkileyebilir Filtrelenmiş bölümleri geç Dikey sürekli @@ -345,18 +341,6 @@ Kategori boş Yeni kategori oluştur %1$s zaten kuyrukta - - %d kategori - %d kategoriler - - - %1$d sayfa kaldı - %1$d sayfa kaldı - - - İndirilmiş %1$d bölüm silinsin mi\? - İndirilmiş %1$d bölüm silinsin mi\? - Bölüm bulunamadı Bölümler silinmiş. Silinmiş yer imi @@ -463,10 +447,6 @@ \nEksik uzantıları yüklemeniz ve daha sonra bunları kullanmak için izleme hizmetlerinde oturum açmanız gerekecektir. Geri yükleme iptal edildi %02d dk, %02d sn - - %1$s içinde %2$s hatayla tamamlandı - %1$s içinde %2$s hatayla tamamlandı - Bölüm bulunamadı Rozetler Son kullanılan @@ -534,10 +514,6 @@ Kısım %1$d Okumaya başla %1$s hakkında - - %1$d sayfa - %1$d sayfa - Kesme alanlarını yoksay Tek Sayfa Sayfa düzeni @@ -593,14 +569,6 @@ Genel güncelleştirmeye ekle Alfabetik olarak sıralarken, manga başlıklarının başındaki makaleleri yok sayarak sırala Makaleleri yok sayarak sırala - - ve %1$d bölüm daha - ve %1$d bölüm daha - - - %d başlık için - %d başlık için - Bir sayfayı kaydır Diğer kitaplık ayarları Kategori haznesini gizle @@ -617,10 +585,6 @@ Kategorileri ekle/düzenle Yeni kategori Kategori - - %1$s bölüm - %1$s bölüm - %1$s ögesini ekle… %1$s ögesini taşı… Sürükleme kolu @@ -628,18 +592,10 @@ \nŞu anda kullanılan: %1$s Okurken önden yüklenecek sayfa sayısı. Daha yüksek değerler, daha yüksek önbellek ve ağ kullanımı pahasına daha sorunsuz bir okuma deneyimiyle sonuçlanacaktır. Artıkları temizle - - Önbellek temizlendi. %d dosya silindi - Önbellek temizlendi. %d dosya silindi - %1$s \'de oturum açılamadı Yedekleme geri yüklenemedi Başlangıç ekranına dönmek için geri düğmesine basın Başlangıç ekranına dön - - %1$d%2$s manga kopyala\? - %1$d%2$s manga kopyala\? - Otomatik sayfa düzenini kullanırken, bu ayarı geçersiz kılmadan da, okuma sırasında düzenler arasında geçiş yapabilirsiniz İndirme sırasına erişim için yakındakiler sekmesini ziyaret edin. Daha hızlı erişim için çift dokunabilir veya basılı tutabilirsiniz Son kullanılan (Kitaplık veya Yakındakiler) @@ -648,14 +604,6 @@ Toplu geçiş için son kaydedilen geçiş öncesi tercihleri ve kaynakları kullan Yalnızca etkin kaynaklarınızı geçiş için etkinleştir Yalnızca sabitlenmiş kaynaklarınızı geçiş için etkinleştir - - %d manga geçiş yaptı - %d manga geçiş yaptı - - - %1$d%2$s mangayı geçiş yap\? - %1$d%2$s mangayı geçiş yap\? - Bölüm bulunamadı, bu manga geçiş için kullanılamaz İndirmeleri kaldır İndirmeyi kaldır @@ -666,10 +614,6 @@ Etkin kaynakları eşleştir Sabitlenmiş kaynakları eşleştir Yalnızca sabitlenmiş kaynakları ara - - Temizleme bitti. %d klasörü kaldırıldı - Temizleme bitti. %d klasörü kaldırıldı - Temizliğe başlanıyor Okunanları temizle Var olmayan, kısmen indirilen ve okunan bölüm klasörlerini sil @@ -680,15 +624,6 @@ Sistem temasını takip et Alt gezinmeyi otomatik gizle (%1$d atlanıyor) - - Kaynaktan bir bölüm kaldırıldı: -\n%2$s -\nİndirmesi silinsin mi\? - Kaynaktan %1$s bölüm kaldırıldı: -\n%2$s -\n -\nİndirmesi silinsin mi\? - Otomatik (yönlendirmeye göre) Kesme alanı davranışı yalnızca belirli ölçek türlerinde portre modunda geçerlidir Kesmeden sonra başla @@ -700,10 +635,6 @@ BETA %1$s \'e eklendi %1$s \'e ekle - - %1$s dakika sonra - %1$s dakika sonra - Genel güncellemeler sırasında sil, bölümler sayfasında sor Kaynak, bölümü çevrimiçi olarak kaldırdıysa indirilen bölümleri sil Kaldırılan bölümleri sil @@ -795,10 +726,6 @@ Aydınlık tema Eşleşme bulunamadı Kaynak desteklenmiyor - - 1 güncelleme beklemede - %d güncelleme beklemede - Uzantı yüklenemedi Genel güncellemeler Öge sayısını göster @@ -842,10 +769,6 @@ Bildirim uzantısı güncellendi Uzantıları otomatik güncelle Çift sayfaları böl - - Uzantı güncellendi - %d uzantı güncellendi - Uzantılar güncellendi Yüklendi %1$s Uzantı güncellemeleri beklemede @@ -864,10 +787,6 @@ Safir Alacakaranlık Mavi Okyanus Görünüm - - %d bölüm atlanıyor, ya kaynakta yok ya da süzgeçlenmiş - %d bölüm atlanıyor, ya kaynakta yok ya da süzgeçlenmiş - Yararlı çeviri bağlantıları Çeviriye yardım edin Tarama gruplarını filtrele @@ -958,10 +877,6 @@ Hata: boş URI Otomatik yedeklemeler şiddetle tavsiye edilir. Kopyaları başka yerlerde de tutmalısınız. Önceden indir - - Sonraki okunmayan bölüm - Sonraki %d okunmayan bölüm - Yalnızca kitaplıktaki girdilerde ve geçerli bölüm ile bir sonraki bölüm zaten indirildiyse çalışır Bildirimleri yönet Pil düşük değil @@ -1008,22 +923,6 @@ İzleyici Uzunluk Başlangıç yılı - - %d kaynak - %d kaynak - - - %d durum - %d durum - - - %d dil - %d dil - - - %d seri türü - %d seri türü - Kitaplıktaki başlıklar Okunan bölümler İzlenen başlıklar @@ -1063,4 +962,4 @@ Arka plan etkinliği Kaynak ayarları Uygulama ayarları - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/uk/plurals.xml b/i18n/src/commonMain/moko-resources/uk/plurals.xml new file mode 100644 index 0000000000..d72995b822 --- /dev/null +++ b/i18n/src/commonMain/moko-resources/uk/plurals.xml @@ -0,0 +1,182 @@ + + + + + Наявне %d оновлення для розширення + %d оновлення для розширень доступні + %d оновлень для розширень доступні + %d оновлень для розширень доступні + + + + %1$d сторінка залишилась + %1$d сторінок залишилось + %1$d сторінок залишилось + %1$d сторінок залишилось + + + + Видалити %1$d завантажений розділ\? + Видалити %1$d завантажених розділів\? + Видалити %1$d завантажених розділів\? + Видалити %1$d завантажених розділів\? + + + + Для %d заголовку + Для %d заголовків + Для %d заголовків + Для %d заголовків + + + + та %1$d ще розділ + та %1$d розділів + та %1$d розділів + та %1$d розділів + + + + Кеш очищено. %d файл було видалено + Кеш очищено. %d файлів було видалено + Кеш очищено. %d файлів було видалено + Кеш очищено. %d файлів було видалено + + + + %d мангу змігровано + %d манґи змігровано + %d манґи змігровано + %d манґи змігровано + + + + Копіювати %1$d%2$s манґу\? + Копіювати %1$d%2$s манґи\? + Копіювати %1$d%2$s манґи\? + Копіювати %1$d%2$s манґи\? + + + + Мігрувати %1$d%2$s манґу\? + Мігрувати %1$d%2$s манґ\? + Мігрувати %1$d%2$s манґ\? + Мігрувати %1$d%2$s манґ\? + + + + Розділ було видалено з джерела: +\n%2$s +\nВидалити завантажене\? + %1$s розділів було видалено з джерела: +\n%2$s +\n +\nВидалити завантажене\? + %1$s розділів було видалено з джерела: +\n%2$s +\n +\nВидалити завантажене\? + %1$s розділів було видалено з джерела: +\n%2$s +\n +\nВидалити завантажене\? + + + + Очистку завершено. %d тека видалена + Очистку завершено. %d тек видалено + Очистку завершено. %d тек видалено + Очистку завершено. %d тек видалено + + + + Через %1$s хвилину + Через %1$s хвилин + Через %1$s хвилин + Через %1$s хвилин + + + + Зроблено за %1$s з %2$s помилкою + Зроблено за %1$s з %2$s помилками + Зроблено за %1$s з %2$s помилками + Зроблено за %1$s з %2$s помилками + + + + Пропускається %d розділ, тому що джерело не має його, або він був відфільтрований + Пропускаються %d розділи, тому що джерело не має їх, або вони були відфільтровані + Пропускання %d розділів, тому що джерело не має їх, або вони були відфільтровані + Пропускання %d розділів, тому що джерело не має їх, або вони були відфільтровані + + + + %d категорія + %d категорії + %d категорій + %d категорій + + + + %d Розширення оновлено + %d розширення оновлені + %d розширеннь оновлені + %d розширеннь оновлені + + + + %d оновлення в очікуванні + %d оновлення в очікуванні + %d оновлень в очікуванні + %d оновлень в очікуванні + + + + %1$s розділ + %1$s розділи + %1$s розділів + %1$s розділів + + + + %1$d сторінка + %1$d сторінки + %1$d сторінок + %1$d сторінок + + + + Наступний непрочитаний розділ + Наступні %d непрочитані розділи + Наступні %d непрочитані розділи + Наступні %d непрочитані розділи + + + + %d тип серії + %d типи серій + %d типів серій + %d типів серій + + + + %d серія + %d серій + %d серій + %d серій + + + + %d статус + %d статусів + %d статусів + %d статусів + + + + %d мова + %d мов + %d мов + %d мов + + diff --git a/app/src/main/res/values-uk/strings.xml b/i18n/src/commonMain/moko-resources/uk/strings.xml similarity index 90% rename from app/src/main/res/values-uk/strings.xml rename to i18n/src/commonMain/moko-resources/uk/strings.xml index 2d244dca6b..77b4bf2117 100644 --- a/app/src/main/res/values-uk/strings.xml +++ b/i18n/src/commonMain/moko-resources/uk/strings.xml @@ -285,12 +285,6 @@ Глянути сайт в WebView Застарілий Це розширення більше не доступне. - - Наявне %d оновлення для розширення - %d оновлення для розширень доступні - %d оновлень для розширень доступні - %d оновлень для розширень доступні - Зменшує смугастість, але може вплинути на продуктивність Пропускати відфільтровані розділи Безперервний вертикальний @@ -335,18 +329,6 @@ Створити нову категорію %1$s вже в черзі Додано %1$s до черги оновлення - - %1$d сторінка залишилась - %1$d сторінок залишилось - %1$d сторінок залишилось - %1$d сторінок залишилось - - - Видалити %1$d завантажений розділ\? - Видалити %1$d завантажених розділів\? - Видалити %1$d завантажених розділів\? - Видалити %1$d завантажених розділів\? - Розділ не знайдено Розділи видалено. Закладку видалено @@ -393,20 +375,8 @@ Оновлювати обкладинки при оновленні бібліотеки Автоматично оновлювати обкладинки Включити до глобального оновлення - - Для %d заголовку - Для %d заголовків - Для %d заголовків - Для %d заголовків - При сортуванні за алфавітом, ігнорувати артиклі (a, an, the) на початку назви манґи Сортувати ігноруючи артиклі - - та %1$d ще розділ - та %1$d розділів - та %1$d розділів - та %1$d розділів - Більше налаштувань бібліотеки Приховати перемикач категорій Показати як @@ -486,35 +456,11 @@ Про що ця %1$s Якщо вимкнено, сторінку переходу буде пропущено якщо наступний розділ завантажено Очистити завантажені розділи - - Кеш очищено. %d файл було видалено - Кеш очищено. %d файлів було видалено - Кеш очищено. %d файлів було видалено - Кеш очищено. %d файлів було видалено - Керування даними Не залогінено в %1$s Не вдалось відновити резервну копію Чисто-білий - - %d мангу змігровано - %d манґи змігровано - %d манґи змігровано - %d манґи змігровано - (пропускаємо %1$d) - - Копіювати %1$d%2$s манґу\? - Копіювати %1$d%2$s манґи\? - Копіювати %1$d%2$s манґи\? - Копіювати %1$d%2$s манґи\? - - - Мігрувати %1$d%2$s манґу\? - Мігрувати %1$d%2$s манґ\? - Мігрувати %1$d%2$s манґ\? - Мігрувати %1$d%2$s манґ\? - Припинити міграцію\? Альтернатив не знайдено Розділи не знайдено, цю манґу не можна використати для міграції @@ -530,23 +476,6 @@ Використовувати перше джерело з альтернативою Використовувати джерело з більшістю розділів (повільніше) Включити додатковий параметр для пошуку - - Розділ було видалено з джерела: -\n%2$s -\nВидалити завантажене\? - %1$s розділів було видалено з джерела: -\n%2$s -\n -\nВидалити завантажене\? - %1$s розділів було видалено з джерела: -\n%2$s -\n -\nВидалити завантажене\? - %1$s розділів було видалено з джерела: -\n%2$s -\n -\nВидалити завантажене\? - Джерела міграції змінено Використовувати останні збережені передміграційні налаштування та джерела для масової міграції Включити тільки включені джерела для міграції @@ -560,12 +489,6 @@ Видалити старі та невикористовувані чи кешовані обкладинки манґи, у вашій бібліотеці котру було оновлено. \nВикористовується: %1$s Очистити кеш обкладинок - - Очистку завершено. %d тека видалена - Очистку завершено. %d тек видалено - Очистку завершено. %d тек видалено - Очистку завершено. %d тек видалено - Вимкніть це, якщо у вас виникли проблеми з оновленням чи відновленням бібліотеки Нема тек для очищення Початок очищення @@ -590,12 +513,6 @@ Завантажити непрочитане Видалено: %1$s Знизу - - Через %1$s хвилину - Через %1$s хвилин - Через %1$s хвилин - Через %1$s хвилин - Видаляти завжди Зберігати завжди Видалити протягом глобальних оновлень, перепитати на сторінці розділів @@ -648,12 +565,6 @@ \nВам потрібно встановити розширення яких бракує та увійти в сервіси відстеження для їх використання. Відновлення відмінено %02d хв, %02d сек - - Зроблено за %1$s з %2$s помилкою - Зроблено за %1$s з %2$s помилками - Зроблено за %1$s з %2$s помилками - Зроблено за %1$s з %2$s помилками - Гайд по міграції джерел NSFW (18+) джерела Це не заважає неофіційним або потенційно неправильно позначеним розширенням розміщувати вміст NSFW (18+) у застосунку. @@ -696,12 +607,6 @@ Shizuku не запущений Встановіть і запустіть Shizuku, щоб використовувати Shizuku як інсталятор розширення. Про застосунок - - Пропускається %d розділ, тому що джерело не має його, або він був відфільтрований - Пропускаються %d розділи, тому що джерело не має їх, або вони були відфільтровані - Пропускання %d розділів, тому що джерело не має їх, або вони були відфільтровані - Пропускання %d розділів, тому що джерело не має їх, або вони були відфільтровані - Збігів не знайдено Режим інкогніто Призупиняє історію читання @@ -724,24 +629,12 @@ \nНа наступному екрані ввімкніть \"Дозволити доступ для керування всіма файлами.\" TachiyomiJ2K потребує доступу до всіх файлів для завантаження розділів. Натисніть тут, а потім увімкніть \"Дозволити доступ для керування всіма файлами.\" Нова категорія - - %d категорія - %d категорії - %d категорій - %d категорій - Потрібен дозвіл доступу до файлів Не в закладинках Підказки щодо пошуку періодично з’являтимуться. Довго натисніть на пропозицію, щоб шукати це. Немає нещодавно прочитаної чи оновленої манґи Спочатку показати назву Показати прочитані розділи в розділах Згруповані та Усі - - %d Розширення оновлено - %d розширення оновлені - %d розширеннь оновлені - %d розширеннь оновлені - Поділитися об\'єднаними сторінками Кількість сторінок, які потрібно попередньо завантажити під час читання. Вищі значення призведуть до плавнішого читання, за рахунок вищого кешу та використання мережі. Перейти до одинарної сторінки @@ -765,12 +658,6 @@ Глобальні оновлення Впливає на обкладинки сітки бібліотек Фільтрування за мовою - - %d оновлення в очікуванні - %d оновлення в очікуванні - %d оновлень в очікуванні - %d оновлень в очікуванні - Поділитися першою сторінкою Вилучити %1$s з %2$s і додати %3$s Перемістити %1$s до… @@ -872,18 +759,6 @@ Зберегти об\'єднані сторінки Кількість передзавантажених сторінок Автоматичне оновлення розширень - - %1$s розділ - %1$s розділи - %1$s розділів - %1$s розділів - - - %1$d сторінка - %1$d сторінки - %1$d сторінок - %1$d сторінок - Сканлейтори Показувати порожні категорії під час фільтрації Немає збігів за вашими фільтрами @@ -1018,12 +893,6 @@ Сторінку %d не знайдено, при розділенні Неможливо розділити завантажене зображення Відкрити в застосунку - - Наступний непрочитаний розділ - Наступні %d непрочитані розділи - Наступні %d непрочитані розділи - Наступні %d непрочитані розділи - Збільшувати масштаб для двосторінкових розворотів Перейти до панорами Оновити тип підрахунку оцінки %1$s @@ -1046,12 +915,6 @@ Тайтли в бібліотеці Теги Без рейтингу - - %d тип серії - %d типи серій - %d типів серій - %d типів серій - Деяким мовам необхідний перезапуск застосунку для правильного відображення Зберегти манґу з прочитаними розділами Тайтли що відстежуються @@ -1068,24 +931,6 @@ Довжина Рік початку Для ваших поточних фільтрів даних не знайдено - - %d серія - %d серій - %d серій - %d серій - - - %d статус - %d статусів - %d статусів - %d статусів - - - %d мова - %d мов - %d мов - %d мов - Уся прочитана манґа Час витрачений в читалці, базуючись на історії розділів Пропущено, оскільки серія не потребує оновлень @@ -1114,4 +959,4 @@ Записи бібліотеки Інформація про налагодження Фонова активність - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/ur/plurals.xml b/i18n/src/commonMain/moko-resources/ur/plurals.xml new file mode 100644 index 0000000000..045e125f3d --- /dev/null +++ b/i18n/src/commonMain/moko-resources/ur/plurals.xml @@ -0,0 +1,3 @@ + + + diff --git a/app/src/main/res/values-ur/strings.xml b/i18n/src/commonMain/moko-resources/ur/strings.xml similarity index 100% rename from app/src/main/res/values-ur/strings.xml rename to i18n/src/commonMain/moko-resources/ur/strings.xml diff --git a/i18n/src/commonMain/moko-resources/vi/plurals.xml b/i18n/src/commonMain/moko-resources/vi/plurals.xml new file mode 100644 index 0000000000..45e45c6456 --- /dev/null +++ b/i18n/src/commonMain/moko-resources/vi/plurals.xml @@ -0,0 +1,101 @@ + + + + + Có %d bản cập nhật của các tiện ích bổ sung + + + + %d danh mục + + + + còn %1$d trang + + + + Xóa %1$d chương đã tải\? + + + + Hoàn tất trong %1$s với %2$s lỗi + + + + Sau %1$s phút + + + + Bộ nhớ đệm tạm đã được làm sạch. Tập tin %d đã được xoá + + + + Làm sạch xong. Đã xoá %d thư mục + + + + Đã di chuyển %d truyện + + + + Sao chép %1$d%2$s \? + + + + Di chuyển %1$d%2$s \? + + + + %1$s chương đã bị xoá khỏi nguồn: +\n%2$s +\nXoá những gì chúng dã tải\? + + + + %1$d trang + + + + và %1$d chương + + + + Cho %d tiêu đề + + + + %1$s chương + + + + Đã bỏ qua %d chương, vì nguồn đang bị thiếu hoặc đã bị lọc ra + + + + %d tiện ích mở rộng đã được cập nhật + + + + %d bản cập nhật đang chờ + + + + %d chương chưa đọc tiếp + + + + %d loại loạt truyện + + + + %d ngôn ngữ + + + + %d trạng thái + + + + %d nguồn + + diff --git a/app/src/main/res/values-vi/strings.xml b/i18n/src/commonMain/moko-resources/vi/strings.xml similarity index 96% rename from app/src/main/res/values-vi/strings.xml rename to i18n/src/commonMain/moko-resources/vi/strings.xml index 71aa64e895..627acd1068 100644 --- a/app/src/main/res/values-vi/strings.xml +++ b/i18n/src/commonMain/moko-resources/vi/strings.xml @@ -333,9 +333,6 @@ Kiểm tra trang web bằng WebView Lỗi thời Tiện ích mở rộng này không còn tồn tại. - - Có %d bản cập nhật của các tiện ích bổ sung - Màn hình Bỏ qua các chương đã lọc Dọc @@ -345,15 +342,6 @@ 15% 20% Gỡ bỏ khỏi thư viện - - %d danh mục - - - còn %1$d trang - - - Xóa %1$d chương đã tải\? - Không tìm thấy chương Đã gỡ chương. Tất cả chương đã đọc @@ -402,9 +390,6 @@ Có gì mới Trang chủ Quá trình khôi phục đã bị ngắt - - Hoàn tất trong %1$s với %2$s lỗi - %02d phút, %02d giây Kích cỡ hai bên Không @@ -448,9 +433,6 @@ Đã thêm vào %1$s Thêm vào %1$s Tachiyomi yêu cầu phải có Webview - - Sau %1$s phút - Tự động xoá Luôn luôn xoá Luôn luôn giữ @@ -462,9 +444,6 @@ Không thể tải xuống vì thiếu dung lượng Vào mục gần đây để quản lí hàng chờ tải xuống. Bạn có thể nhấn đúp hoặc giữ để truy cập nhanh Quản lí phần tải xuống - - Bộ nhớ đệm tạm đã được làm sạch. Tập tin %d đã được xoá - Không có thứ gì đang tải Xoá tải xuống Xoá tải xuống @@ -489,9 +468,6 @@ Xoá ảnh bìa cũ hoặc không dùng đến của truyện trong thư viện sau khi được cập nhật. \nHiện tại đang sử dụng %1$s Làm sạch ảnh bìa tạm - - Làm sạch xong. Đã xoá %d thư mục - Vui lòng tắt nếu bạn gặp vấn đề khi cập nhật hoặc khôi phục lại thư viện Không có thư mục để làm sạch Làm sạch truyện không nằm trong thư viện @@ -537,16 +513,7 @@ Chế độ ẩn danh Tắt %s Bật %s - - Đã di chuyển %d truyện - (bỏ qua %1$d) - - Sao chép %1$d%2$s \? - - - Di chuyển %1$d%2$s \? - Dừng di chuyển\? Không tìm thấy nguồn thay thế Sử dụng nguồn đầu tiên cùng với nguồn thay thế @@ -575,11 +542,6 @@ Muốn đọc Đang đọc Chưa được theo dõi - - %1$s chương đã bị xoá khỏi nguồn: -\n%2$s -\nXoá những gì chúng dã tải\? - Được theo dõi Chỉnh sửa thông tin truyện Lỗi khi chia sẻ ảnh bìa @@ -616,9 +578,6 @@ Tiếp tục đọc Bắt đầu đọc Về %1$s - - %1$d trang - Hiện khi nhấn giữ Hành động Tự động (dựa trên hướng) @@ -672,12 +631,6 @@ Bao gồm trong phần cập nhật toàn bộ Khi sắp xếp theo bảng chữ cái, bỏ qua mạo từ (a, an, the) ở đầu các tiêu đề truyện Sắp xếp bằng cách bỏ qua mạo từ - - và %1$d chương - - - Cho %d tiêu đề - Chuyển hai trang Chuyển một trang qua Tuỳ chỉnh thêm về thư viện @@ -737,9 +690,6 @@ %1$s đã có trong hàng đợi Đang thêm %1$s vào hàng đợi cập nhật Danh mục - - %1$s chương - Không có chương để xóa Xoá tất cả những gì tải xuống\? Không tìm thấy trang @@ -790,9 +740,6 @@ Sử dụng gần đây Nguồn ẩn Một vài nhà sản xuất có các hạn chế về việc chạy ngầm của ứng dụng có thể gây dừng hiện thị dịch vụ nền. Xem thêm ở địa chỉ này để sửa chữa chúng. - - Đã bỏ qua %d chương, vì nguồn đang bị thiếu hoặc đã bị lọc ra - Hướng dẫn sử dụng khởi đầu Tính năng tối ưu hóa của MIUI phải được bật lên để việc sao lưu/khôi phục hoạt động tốt. Giới hạn: %1$s @@ -818,9 +765,6 @@ Cập nhật toàn bộ Lọc các nhóm dịch truyện Các tiện ích mở rộng đã được cập nhật - - %d tiện ích mở rộng đã được cập nhật - Tách trang đôi trong chế độ chân dung Căn chỉnh biểu tượng điều hướng bên cạnh Sử dụng điều hướng bên cạnh @@ -841,9 +785,6 @@ Cần phải tắt tính năng tối ưu hóa của MIUI để cài đặt các tiện ích mở rộng. Một số tiện ích mở rộng vẫn cần được cân nhắc khi cài đặt trước. Đang cập nhật các tiện ích mở rộng - - %d bản cập nhật đang chờ - Đặt làm mặc định Có gỡ bỏ bộ theo dõi cũ không \? Sử dụng ngày được đề xuất @@ -981,9 +922,6 @@ Oải Hương Cực Tím Mở trong ứng dụng - - %d chương chưa đọc tiếp - Không thể chia cắt ảnh đã tải xuống Tìm hiểu lý do Trang %d không thể được tìm thấy khi chia cắt @@ -1027,18 +965,6 @@ Bộ Theo Dõi Năm bắt đầu Không có dữ liệu được tìm thấy đáp ứng bộ lọc của bạn - - %d loại loạt truyện - - - %d ngôn ngữ - - - %d trạng thái - - - %d nguồn - Bỏ qua vì loạt truyện không cần cập nhật Chuỗi tác nhân người dùng không hợp lệ Nổi Tiếng @@ -1069,4 +995,4 @@ Cài đặt ứng dụng Thông tin Debug Hoạt động ngầm - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/zh-rCN/plurals.xml b/i18n/src/commonMain/moko-resources/zh-rCN/plurals.xml new file mode 100644 index 0000000000..59646883d2 --- /dev/null +++ b/i18n/src/commonMain/moko-resources/zh-rCN/plurals.xml @@ -0,0 +1,101 @@ + + + + + %d 个扩展插件可更新 + + + + %d 个类别 + + + + 还有 %1$d 章 + + + + 共 %d 个漫画 + + + + 剩余 %1$d 页 + + + + 移除已下载的 %1$d 章? + + + + 第%1$s章已从图源中删除: +\n%2$s +\n是否删除其下载内容? + + + + %d 漫画已迁移 + + + + 复制 %1$d%2$s 漫画? + + + + 迁移 %1$d%2$s 漫画? + + + + 在%1$s分钟之后 + + + + 清除完成,移除了 %d 个目录 + + + + 缓存已清除,%d 的文件已被删除 + + + + 耗时 %1$s,出现 %2$s 个错误 + + + + %1$s 章 + + + + %1$d页 + + + + %d 个待处理更新 + + + + 更新了 %d 个扩展 + + + + 跳过了 %d 章,可能是图源没有这些章节,或者被筛选规则排除了 + + + + 下 %d 个未读章节 + + + + %d 种连载类型 + + + + %d 个图源 + + + + %d 种状态 + + + + %d 种语言 + + diff --git a/app/src/main/res/values-zh-rCN/strings.xml b/i18n/src/commonMain/moko-resources/zh-rCN/strings.xml similarity index 95% rename from app/src/main/res/values-zh-rCN/strings.xml rename to i18n/src/commonMain/moko-resources/zh-rCN/strings.xml index ffb6267b40..f4b56102dd 100644 --- a/app/src/main/res/values-zh-rCN/strings.xml +++ b/i18n/src/commonMain/moko-resources/zh-rCN/strings.xml @@ -269,9 +269,6 @@ 在 WebView 中检查网站 失效 此插件不再可用。 - - %d 个扩展插件可更新 - 缓解色带问题,但可能会影响性能 跳过已筛选章节 禁用电池优化 @@ -365,9 +362,6 @@ 创建新分类 %1$s 已在队列中 正在将 %1$s 添加到更新队列 - - %d 个类别 - 未找到章节 书签已移除 标记为未读 @@ -379,12 +373,6 @@ 进行中 未开始 按忽略条目排序 - - 还有 %1$d 章 - - - 共 %d 个漫画 - 更多书架设置 隐藏分类漏斗 显示为 @@ -408,12 +396,6 @@ 长按以编辑分类 漫画已在该分类 此分类的漫画将移至默认分类。 - - 剩余 %1$d 页 - - - 移除已下载的 %1$d 章? - 章节已删除。 已看完 %1$d/%2$d @@ -425,22 +407,8 @@ 添加 %1$s 至书架? 最近 想读 - - 第%1$s章已从图源中删除: -\n%2$s -\n是否删除其下载内容? - 清除孤本 - - %d 漫画已迁移 - (跳过 %1$d) - - 复制 %1$d%2$s 漫画? - - - 迁移 %1$d%2$s 漫画? - 停止迁移? 找不到替代 无可用章节,此漫画无法进行迁移 @@ -498,9 +466,6 @@ 拖动手柄 下载未读 已删除:%1$s - - 在%1$s分钟之后 - 总是删除 总是保留 在全局更新期间删除,在章节页上询问 @@ -529,9 +494,6 @@ 删除书架更新过后旧的和未使用的漫画封面缓存 \n当前使用:%1$s 清理缓存的封面 - - 清除完成,移除了 %d 个目录 - 如果更新或恢复书架过程中出现问题,禁用此项 没有待清除的目录 开始清除 @@ -541,9 +503,6 @@ 删除不存在、部分下载和已读过章节目录 数据管理 尚未登录 %1$s - - 缓存已清除,%d 的文件已被删除 - 底部 正在下载: %1$s 启用缩小 @@ -604,9 +563,6 @@ \n你需要安装所有缺少的扩展,之后登录到跟踪服务以使用它们。 已取消还原 %02d 分,%02d 秒 - - 耗时 %1$s,出现 %2$s 个错误 - 图源迁移指南 NSFW (18+) 图源 这并不能防止非官方或可能被错误标记的扩展插件在应用程序中显示 NSFW (18+) 内容。 @@ -637,9 +593,6 @@ 显示未读徽章 隐藏未读徽章 类别 - - %1$s 章 - 备份和还原 进度 完成 @@ -661,9 +614,6 @@ 已添加到 %1$s 使用自动页面布局时,你仍然可以在阅读时在不同布局之间切换,而无需覆盖此设置 添加到 %1$s - - %1$d页 - 自动 (基于方向) 页面布局 转到单页 @@ -774,9 +724,6 @@ 浅色主题 未找到匹配项 图源不受支持 - - %d 个待处理更新 - 无法安装扩展 全局更新 打开一个随机系列 @@ -822,9 +769,6 @@ 通知扩展已更新 自动更新扩展 拆分双页 - - 更新了 %d 个扩展 - 扩展已更新 已安装 %1$s 待更新扩展 @@ -843,9 +787,6 @@ 侧导航默认仅用于某些手机和小型平板电脑上的横屏模式;在较大平板电脑上不论横屏或竖屏总是显示 默认行为 使用侧导航 - - 跳过了 %d 章,可能是图源没有这些章节,或者被筛选规则排除了 - 有帮助的翻译链接 协助翻译 过滤扫译群组 @@ -935,9 +876,6 @@ 你确定吗?所有的历史都将丢失。 错误:空 URI 强烈建议启用自动备份,你也应该在其他地方保存副本。 - - 下 %d 个未读章节 - 仅对书架中的作品有效,并且要求当前章节和下一章节都已下载 预先下载 通知管理 @@ -990,18 +928,6 @@ 长度 追踪源 没有找到当前筛选器的数据 - - %d 种连载类型 - - - %d 个图源 - - - %d 种状态 - - - %d 种语言 - 本地作品 阅读时长 未评分 @@ -1036,4 +962,4 @@ 应用设置 调试信息 后台活动 - \ No newline at end of file + diff --git a/i18n/src/commonMain/moko-resources/zh-rTW/plurals.xml b/i18n/src/commonMain/moko-resources/zh-rTW/plurals.xml new file mode 100644 index 0000000000..0eaa5972aa --- /dev/null +++ b/i18n/src/commonMain/moko-resources/zh-rTW/plurals.xml @@ -0,0 +1,101 @@ + + + + + %d 個擴充套件可更新 + + + + %d 個分類 + + + + 歷時 %1$s,出現 %2$s 個錯誤 + + + + 略過了 %d 章,也許是來源沒有這些章節,或其已被篩選規則排除 + + + + 共 %1$s 章 + + + + 餘 %1$d 頁 + + + + 已清除快取,%d 個檔案已被刪除 + + + + 移除 %1$d 個已下載的章節? + + + + %1$s 分鐘後 + + + + 共 %d 本漫畫 + + + + 還有 %1$d 章 + + + + 第%1$s章已從來源中刪除: +\n%2$s +\n是否刪除其下載内容? + + + + 接下來未讀的 %d 章 + + + + %d 個來源 + + + + %d 種語言 + + + + 有%d個更新正在等待 + + + + 更新了%d個擴充套件 + + + + 確定要遷移 %1$d%2$s 個漫畫系列嗎? + + + + 已成功遷移 %d 個漫畫系列 + + + + 確定要複製 %1$d%2$s 個漫畫系列嗎? + + + + %d 系列類型 + + + + %d 狀態 + + + + %1$d 頁 + + + + 清理完成。已刪除 %d 個資料夾 + + diff --git a/app/src/main/res/values-zh-rTW/strings.xml b/i18n/src/commonMain/moko-resources/zh-rTW/strings.xml similarity index 95% rename from app/src/main/res/values-zh-rTW/strings.xml rename to i18n/src/commonMain/moko-resources/zh-rTW/strings.xml index 4ddd648fc1..036ac8364a 100644 --- a/app/src/main/res/values-zh-rTW/strings.xml +++ b/i18n/src/commonMain/moko-resources/zh-rTW/strings.xml @@ -279,9 +279,6 @@ 在 WebView 中檢查網站 過舊 這個擴充套件已無法使用。 - - %d 個擴充套件可更新 - 減緩色調分離,但可能拖累效能 略過已篩選的章節 垂直連貫 @@ -334,9 +331,6 @@ 拖曳 鬆散格狀 確定要刪除分類? - - %d 個分類 - 標示為未讀 標示為已讀 美漫 @@ -356,9 +350,6 @@ 尚未登入至歷程平台: 已取消還原 %02d 分 %02d 秒 - - 歷時 %1$s,出現 %2$s 個錯誤 - 沒有章節 標籤 最近使用 @@ -468,28 +459,16 @@ Tachiyomi 需要有儲存空間存取權限才能下載漫畫。請允許\"管理儲存空間\" 入門指南 協助翻譯 - - 略過了 %d 章,也許是來源沒有這些章節,或其已被篩選規則排除 - 搜尋擴充套件… 若停用 MIUI 最佳化,備份與還原可能無法正確執行。 登出 登出 %1$s? 分類 - - 共 %1$s 章 - - - 餘 %1$d 頁 - 新分類 從「%1$s」移出 已停用 程式資訊 閱讀模式 - - 已清除快取,%d 個檔案已被刪除 - WebView 為 Tachiyomi 的必要元件 建立新分類 登入 @@ -533,9 +512,6 @@ 警告:大量批次下載可能壅塞來源並 (或) 使其封鎖 Tachiyomi。輕觸以瞭解詳情。 這些項目將會被自動移到「預設分類」。 管理分類 - - 移除 %1$d 個已下載的章節? - 已存在於分類中的項目 最新 更新與閱讀記錄 @@ -560,12 +536,6 @@ 透過「追蹤按鈕」設定,個別漫畫的閱讀進度可以單向同步到追蹤服務。 增強服務 為特定來源提供附加功能的服務。收藏到「我的收藏」的項目會自動追蹤。 - - %1$s 分鐘後 - - - 共 %d 本漫畫 - 遞增 日期 遞減 @@ -607,9 +577,6 @@ 需要檔案權限 永遠顯示目前分類 書櫃分組… - - 還有 %1$d 章 - 來源未安裝 打開%s 關閉%s @@ -637,11 +604,6 @@ 你的書櫃 對書櫃分組時,依照來源、狀態...等。 沒有要刪除的章節 - - 第%1$s章已從來源中刪除: -\n%2$s -\n是否刪除其下載内容? - 更新書櫃的同時更新封面 錯誤:URI 空白 強烈建議啟用自動備份,並在他處保留副本。 @@ -717,18 +679,9 @@ 閱讀時自動下載 已下載章數 僅適用於書櫃中的作品,並且目前章節及下一章節皆已下載 - - 接下來未讀的 %d 章 - 過濾語言 擴充套件更新擱置中 - - %d 個來源 - 閱讀歷時 - - %d 種語言 - 淺色主題 深色主題 歷程平台 @@ -772,13 +725,7 @@ 切換到雙頁 使用自動頁面佈局時,您仍然可以在閱讀時在佈局之間切換,而不會覆蓋此設置 一些擴充套件可能仍然需要先安裝。 - - 有%d個更新正在等待 - 擴充套件已更新 - - 更新了%d個擴充套件 - 閱讀器設定 反轉雙頁 裁剪邊框(分頁) @@ -800,12 +747,6 @@ 選擇一個來源,然後選擇要遷移的項目 不要遷移 無可用章節,該漫畫系列無法進行資料遷移 - - 確定要遷移 %1$d%2$s 個漫畫系列嗎? - - - 已成功遷移 %d 個漫畫系列 - 更明亮的你(動態) 經典藍 春暖花開 @@ -835,9 +776,6 @@ 過濾掃描器組 遷移到 立即遷移 - - 確定要複製 %1$d%2$s 個漫畫系列嗎? - 灰暗時光 純白 @@ -877,13 +815,7 @@ 管理正在下載的項目 長度 開始年份 - - %d 系列類型 - 更改 - - %d 狀態 - 刪除所有已快取且不在圖書館中的封面。 \n目前使用:%1$s 本地漫畫名稱 @@ -898,9 +830,6 @@ 兩個軸 忽略切割區域 切割區域行為僅適用於特定縮放類型的直向模式 - - %1$d 頁 - 卷%1$d 季%1$d 按下返回鈕返回起始頁面 @@ -940,9 +869,6 @@ 資料管理 自動更新應用程式 整理已下載的章節 - - 清理完成。已刪除 %d 個資料夾 - 切割區域行為 填充切割區域 在切割區域之後開始 @@ -1037,4 +963,4 @@ 偵錯資訊 背景活動 分享封面 - \ No newline at end of file + diff --git a/presentation/widget/src/main/java/yokai/presentation/widget/util/GlanceUtils.kt b/presentation/widget/src/main/java/yokai/presentation/widget/util/GlanceUtils.kt index e27438bda5..3e5fd46740 100644 --- a/presentation/widget/src/main/java/yokai/presentation/widget/util/GlanceUtils.kt +++ b/presentation/widget/src/main/java/yokai/presentation/widget/util/GlanceUtils.kt @@ -8,6 +8,7 @@ import androidx.glance.appwidget.cornerRadius import dev.icerock.moko.resources.StringResource import yokai.presentation.widget.R import yokai.util.lang.getString +import dev.icerock.moko.resources.compose.stringResource fun GlanceModifier.appWidgetBackgroundRadius(): GlanceModifier { return this.cornerRadius(R.dimen.appwidget_background_radius)