fix: complete the text of the module labels (#558)

- replace the string Resource ID of uninstalled & those can be updated modules
This commit is contained in:
AxelPLN(Axel Yinjia Huang)
2025-06-28 00:48:18 +08:00
committed by GitHub
parent 3d44602537
commit a9cab5ccfd

View File

@@ -412,11 +412,13 @@ private fun ModuleList(
val rebootToApply = stringResource(R.string.reboot_to_apply) val rebootToApply = stringResource(R.string.reboot_to_apply)
val moduleStr = stringResource(R.string.module) val moduleStr = stringResource(R.string.module)
val uninstall = stringResource(R.string.uninstall) val uninstall = stringResource(R.string.uninstall)
val uninstalled = stringResource(R.string.uninstalled)
val restore = stringResource(R.string.restore) val restore = stringResource(R.string.restore)
val cancel = stringResource(android.R.string.cancel) val cancel = stringResource(android.R.string.cancel)
val moduleUninstallConfirm = stringResource(R.string.module_uninstall_confirm) val moduleUninstallConfirm = stringResource(R.string.module_uninstall_confirm)
val moduleRestoreConfirm = stringResource(R.string.module_restore_confirm) val moduleRestoreConfirm = stringResource(R.string.module_restore_confirm)
val updateText = stringResource(R.string.module_update) val updateText = stringResource(R.string.module_update)
val updateLable = stringResource(R.string.module_update_available)
val changelogText = stringResource(R.string.module_changelog) val changelogText = stringResource(R.string.module_changelog)
val downloadingText = stringResource(R.string.module_downloading) val downloadingText = stringResource(R.string.module_downloading)
val startDownloadingText = stringResource(R.string.module_start_downloading) val startDownloadingText = stringResource(R.string.module_start_downloading)
@@ -821,7 +823,7 @@ fun ModuleItem(
) )
if (module.remove) { if (module.remove) {
LabelItem( LabelItem(
text = stringResource(R.string.uninstall), text = stringResource(R.string.uninstalled),
style = com.dergoogler.mmrl.ui.component.LabelItemDefaults.style.copy( style = com.dergoogler.mmrl.ui.component.LabelItemDefaults.style.copy(
containerColor = MaterialTheme.colorScheme.errorContainer, containerColor = MaterialTheme.colorScheme.errorContainer,
contentColor = MaterialTheme.colorScheme.onErrorContainer contentColor = MaterialTheme.colorScheme.onErrorContainer
@@ -839,7 +841,7 @@ fun ModuleItem(
} }
if (updateUrl.isNotEmpty() && !module.remove && !module.update) { if (updateUrl.isNotEmpty() && !module.remove && !module.update) {
LabelItem( LabelItem(
text = stringResource(R.string.module_update), text = stringResource(R.string.module_update_available),
style = com.dergoogler.mmrl.ui.component.LabelItemDefaults.style.copy( style = com.dergoogler.mmrl.ui.component.LabelItemDefaults.style.copy(
containerColor = MaterialTheme.colorScheme.tertiaryContainer, containerColor = MaterialTheme.colorScheme.tertiaryContainer,
contentColor = MaterialTheme.colorScheme.onTertiaryContainer contentColor = MaterialTheme.colorScheme.onTertiaryContainer